From a2bad78188225ee7786e7504f92e3ba4fbd28431 Mon Sep 17 00:00:00 2001 From: Build Automaion Date: Thu, 5 Dec 2024 02:45:12 +0530 Subject: [PATCH] Integrated latest changes at 12-04-2024 10:30:10 PM --- ej2-angular/heatmap-chart/bubble-heatmap.md | 8 +- ej2-angular/heatmap-chart/getting-started.md | 8 +- .../heatmap-chart/working-with-data.md | 6 +- ej2-angular/linear-gauge/axis.md | 4 + ej2-angular/linear-gauge/getting-started.md | 2 + .../diagram/commands/grouping-cs1/index.html | 2 +- .../grouping-cs1/main.41baf8de3e39b9ff.js | 1 + .../grouping-cs1/main.f636748cc9bad9cc.js | 1 - .../diagram/layers/layers-cs5/index.html | 2 +- .../layers-cs5/main.bcb24af3e7d3f91f.js | 1 + .../layers-cs5/main.d56ef44cc2253cac.js | 1 - .../diagram/layers/layers-cs6/index.html | 2 +- .../layers-cs6/main.76de9ac9d4107d88.js | 1 + .../layers-cs6/main.f823f2a09376668e.js | 1 - .../diagram/layers/layers-cs7/index.html | 2 +- .../layers-cs7/main.10ecba4e72d9d589.js | 1 + .../layers-cs7/main.5c7a28317b4bc2f4.js | 1 - .../diagram/layers/layers-cs8/index.html | 2 +- .../layers-cs8/main.1c8c09371bc3e3ce.js | 1 - .../layers-cs8/main.df0256789227b196.js | 1 + .../node-expandAndCollapse-cs1/index.html | 2 +- .../main.4c4feb775a3c1aa7.js | 1 + .../main.55bf572d1a73b49c.js | 1 - .../node-expandAndCollapse-cs2/index.html | 2 +- .../main.348fc4eaf45b08b7.js | 1 + .../main.a5263187c36c3a78.js | 1 - .../samples/diagram/ports/add-cs1/index.html | 2 +- .../ports/add-cs1/main.606f4ee7e9720645.js | 1 - .../ports/add-cs1/main.a8714d93274f2509.js | 1 + .../diagram/ports/connectionPort/index.html | 2 +- .../connectionPort/main.af1e59c52e0906ea.js | 1 - .../connectionPort/main.de0f5aa53693d70c.js | 1 + .../diagram/ports/edges-cs1/index.html | 2 +- .../ports/edges-cs1/main.023313dfd9f60d96.js | 1 - .../ports/edges-cs1/main.53ae47e68a59141c.js | 1 + .../samples/diagram/ports/node-cs1/index.html | 2 +- .../ports/node-cs1/main.5b5747e17b12a4e6.js | 1 - .../ports/node-cs1/main.7ea7dd8033e7551a.js | 1 + .../diagram/ports/remove-cs1/index.html | 2 +- .../ports/remove-cs1/main.057b645816e1cd30.js | 1 - .../ports/remove-cs1/main.89a4eb77ff6e4ae0.js | 1 + .../tab/dynamic-tab-cs1/3rdpartylicenses.txt | 313 ++++++++++++++++++ .../samples/tab/dynamic-tab-cs1/index.css | 43 +++ .../samples/tab/dynamic-tab-cs1/index.html | 47 +++ .../dynamic-tab-cs1/main.79c03e32490f7316.js | 1 + .../runtime.cf3bdadb8fd8abdc.js | 1 + .../styles.aa1e2b67243fc49b.css | 1 + ej2-angular/treemap/getting-started.md | 4 +- ej2-angular/treemap/layout.md | 8 +- 49 files changed, 462 insertions(+), 32 deletions(-) create mode 100644 ej2-angular/samples/diagram/commands/grouping-cs1/main.41baf8de3e39b9ff.js delete mode 100644 ej2-angular/samples/diagram/commands/grouping-cs1/main.f636748cc9bad9cc.js create mode 100644 ej2-angular/samples/diagram/layers/layers-cs5/main.bcb24af3e7d3f91f.js delete mode 100644 ej2-angular/samples/diagram/layers/layers-cs5/main.d56ef44cc2253cac.js create mode 100644 ej2-angular/samples/diagram/layers/layers-cs6/main.76de9ac9d4107d88.js delete mode 100644 ej2-angular/samples/diagram/layers/layers-cs6/main.f823f2a09376668e.js create mode 100644 ej2-angular/samples/diagram/layers/layers-cs7/main.10ecba4e72d9d589.js delete mode 100644 ej2-angular/samples/diagram/layers/layers-cs7/main.5c7a28317b4bc2f4.js delete mode 100644 ej2-angular/samples/diagram/layers/layers-cs8/main.1c8c09371bc3e3ce.js create mode 100644 ej2-angular/samples/diagram/layers/layers-cs8/main.df0256789227b196.js create mode 100644 ej2-angular/samples/diagram/nodes/node-expandAndCollapse-cs1/main.4c4feb775a3c1aa7.js delete mode 100644 ej2-angular/samples/diagram/nodes/node-expandAndCollapse-cs1/main.55bf572d1a73b49c.js create mode 100644 ej2-angular/samples/diagram/nodes/node-expandAndCollapse-cs2/main.348fc4eaf45b08b7.js delete mode 100644 ej2-angular/samples/diagram/nodes/node-expandAndCollapse-cs2/main.a5263187c36c3a78.js delete mode 100644 ej2-angular/samples/diagram/ports/add-cs1/main.606f4ee7e9720645.js create mode 100644 ej2-angular/samples/diagram/ports/add-cs1/main.a8714d93274f2509.js delete mode 100644 ej2-angular/samples/diagram/ports/connectionPort/main.af1e59c52e0906ea.js create mode 100644 ej2-angular/samples/diagram/ports/connectionPort/main.de0f5aa53693d70c.js delete mode 100644 ej2-angular/samples/diagram/ports/edges-cs1/main.023313dfd9f60d96.js create mode 100644 ej2-angular/samples/diagram/ports/edges-cs1/main.53ae47e68a59141c.js delete mode 100644 ej2-angular/samples/diagram/ports/node-cs1/main.5b5747e17b12a4e6.js create mode 100644 ej2-angular/samples/diagram/ports/node-cs1/main.7ea7dd8033e7551a.js delete mode 100644 ej2-angular/samples/diagram/ports/remove-cs1/main.057b645816e1cd30.js create mode 100644 ej2-angular/samples/diagram/ports/remove-cs1/main.89a4eb77ff6e4ae0.js create mode 100644 ej2-angular/samples/tab/dynamic-tab-cs1/3rdpartylicenses.txt create mode 100644 ej2-angular/samples/tab/dynamic-tab-cs1/index.css create mode 100644 ej2-angular/samples/tab/dynamic-tab-cs1/index.html create mode 100644 ej2-angular/samples/tab/dynamic-tab-cs1/main.79c03e32490f7316.js create mode 100644 ej2-angular/samples/tab/dynamic-tab-cs1/runtime.cf3bdadb8fd8abdc.js create mode 100644 ej2-angular/samples/tab/dynamic-tab-cs1/styles.aa1e2b67243fc49b.css diff --git a/ej2-angular/heatmap-chart/bubble-heatmap.md b/ej2-angular/heatmap-chart/bubble-heatmap.md index 5c5fa1f6d7..8e25e489c2 100644 --- a/ej2-angular/heatmap-chart/bubble-heatmap.md +++ b/ej2-angular/heatmap-chart/bubble-heatmap.md @@ -10,6 +10,10 @@ domainurl: ##DomainURL## # Bubble heatmap in Angular Heatmap chart component +This section explains how to customize the appearance of the HeatMap cells as bubbles. The below video demonstrates the same. + +{% youtube "https://www.youtube.com/watch?v=WTK0lubgN9E" %} + Data points represent the data source values with **gradient** or **fixed** colors in the HeatMap. You can customize the appearance of these data points by changing the `color` and `size` attributes. The data points can be represented in color fill or bubble shape by defining the [tileType](https://ej2.syncfusion.com/angular/documentation/api/heatmap/cellSettings/#tiletype) property. By default, the data points are color filled with gradient or fixed colors and this depiction of data points is defined as `Rect` in the `tileType` property. @@ -26,7 +30,7 @@ In bubble HeatMap, you can display the data points with bubble size, bubble colo In this bubble HeatMap type, the size factor of the bubble is used to denote the data variations. The radius of the bubble varies according to data values. -By default, the bubble with small size denotes the data value with small magnitude and the larger bubble size denotes the data value with larger magnitude. This behavior can be inversed by using the [isinversedbubblesize](https://ej2.syncfusion.com/angular/documentation/api/heatmap/cellSettings/#isinversedbubblesize) property. +By default, the bubble with small size denotes the data value with small magnitude and the larger bubble size denotes the data value with larger magnitude. This behavior can be inversed by using the [isInversedBubbleSize](https://ej2.syncfusion.com/angular/documentation/api/heatmap/cellSettings/#isinversedbubblesize) property. To render a bubble HeatMap with size series, set the [bubbleType](https://ej2.syncfusion.com/angular/documentation/api/heatmap/cellSettings/#bubbletype) property to **Size**. @@ -179,4 +183,4 @@ The size and color of the bubbles in the **SizeAndColor** bubble HeatMap type ca {% endhighlight %} {% endtabs %} -{% previewsample "page.domainurl/samples/heatmap/bubble-heatmap/sizeAndColorJSONCell-cs2" %} \ No newline at end of file +{% previewsample "page.domainurl/samples/heatmap/bubble-heatmap/sizeAndColorJSONCell-cs2" %} diff --git a/ej2-angular/heatmap-chart/getting-started.md b/ej2-angular/heatmap-chart/getting-started.md index 6bac20a4e3..487f121f66 100644 --- a/ej2-angular/heatmap-chart/getting-started.md +++ b/ej2-angular/heatmap-chart/getting-started.md @@ -10,7 +10,11 @@ domainurl: ##DomainURL## # Getting started with Angular Heatmap chart component -This section explains the steps required to create a heat map and demonstrates the basic usage of the heat map control. +This section explains the steps required to create a heat map and demonstrates the basic usage of the HeatMap component. + +You can explore some useful features in the HeatMap component using the following video. + +{% youtube "https://www.youtube.com/watch?v=GG3l2cAst7Y" %} ## Setup Angular Environment @@ -254,4 +258,4 @@ The tooltip is used when you cannot display information by using the data labels {% previewsample "page.domainurl/samples/heatmap/getting-started/tooltip-cs1" %} -> You can refer to our [Angular Heatmap Chart]( https://www.syncfusion.com/angular-ui-components/angular-heatmap-chart) feature tour page for its groundbreaking feature representations. You can also explore our [Angular Heatmap Chart example](https://ej2.syncfusion.com/angular/demos/#/material/heatmap-chart/default) that shows how to render the Heatmap Chart in Angular. \ No newline at end of file +> You can refer to our [Angular Heatmap Chart]( https://www.syncfusion.com/angular-ui-components/angular-heatmap-chart) feature tour page for its groundbreaking feature representations. You can also explore our [Angular Heatmap Chart example](https://ej2.syncfusion.com/angular/demos/#/material/heatmap-chart/default) that shows how to render the Heatmap Chart in Angular. diff --git a/ej2-angular/heatmap-chart/working-with-data.md b/ej2-angular/heatmap-chart/working-with-data.md index a76f13bc9d..1beb72e394 100644 --- a/ej2-angular/heatmap-chart/working-with-data.md +++ b/ej2-angular/heatmap-chart/working-with-data.md @@ -10,6 +10,10 @@ domainurl: ##DomainURL## # Working with data in Angular Heatmap chart component +This section shows how to bind data to the HeatMap component. The below video demonstrates the same. + +{% youtube "https://www.youtube.com/watch?v=oK23v5DbbLg" %} + Heat map visualizes the JSON data and two-dimensional array data. Using the data adaptor support, data can be bound to the heat map. ## Data adaptor @@ -121,4 +125,4 @@ In complex data binding, you can bind the nested JSON data to the data points in ## See Also -* [To bind data for bubble heat map with size and color attributes](./bubble-heatmap/#binding-data-for-bubble-heat-map-with-size-and-color-attributes) \ No newline at end of file +* [To bind data for bubble heat map with size and color attributes](./bubble-heatmap/#binding-data-for-bubble-heat-map-with-size-and-color-attributes) diff --git a/ej2-angular/linear-gauge/axis.md b/ej2-angular/linear-gauge/axis.md index 0e706f4e95..f60299614f 100644 --- a/ej2-angular/linear-gauge/axis.md +++ b/ej2-angular/linear-gauge/axis.md @@ -10,6 +10,10 @@ domainurl: ##DomainURL## # Axis in Angular Linear gauge component +This section explains how to customize the appearance of the axis labels, ranges, and pointers in the Linear Gauge component. The below video demonstrates the same. + +{% youtube "https://www.youtube.com/watch?v=pI9KyD74NQo" %} + Axis is used to indicate the numeric values in the linear scale. The Linear Gauge component can have any number of axes. The sub-elements of an axis are line, ticks, labels, ranges, and pointers. diff --git a/ej2-angular/linear-gauge/getting-started.md b/ej2-angular/linear-gauge/getting-started.md index bcc2d7359c..1d7459ca39 100644 --- a/ej2-angular/linear-gauge/getting-started.md +++ b/ej2-angular/linear-gauge/getting-started.md @@ -14,6 +14,8 @@ domainurl: ##DomainURL## This section explains the steps required to create a simple Linear Gauge and demonstrate the basic usage of the Linear Gauge component. +{% youtube "https://www.youtube.com/watch?v=KHAuX1TQisU" %} + ## Dependencies Below is the list of minimum dependencies required to use the Linear Gauge component. diff --git a/ej2-angular/samples/diagram/commands/grouping-cs1/index.html b/ej2-angular/samples/diagram/commands/grouping-cs1/index.html index c1ab4b5240..c36ea15f0b 100644 --- a/ej2-angular/samples/diagram/commands/grouping-cs1/index.html +++ b/ej2-angular/samples/diagram/commands/grouping-cs1/index.html @@ -19,5 +19,5 @@
Loading....
- + \ No newline at end of file diff --git a/ej2-angular/samples/diagram/commands/grouping-cs1/main.41baf8de3e39b9ff.js b/ej2-angular/samples/diagram/commands/grouping-cs1/main.41baf8de3e39b9ff.js new file mode 100644 index 0000000000..d62ce04c3d --- /dev/null +++ b/ej2-angular/samples/diagram/commands/grouping-cs1/main.41baf8de3e39b9ff.js @@ -0,0 +1 @@ +"use strict";(self.webpackChunksyncfusion_component=self.webpackChunksyncfusion_component||[]).push([[179],{51:(Wl,Wd,Yd)=>{let $r=null,jh=1;const Ts=Symbol("SIGNAL");function Wi(n){const t=$r;return $r=n,t}function gn(n){if((!Qh(n)||n.dirty)&&(n.dirty||n.lastCleanEpoch!==jh)){if(!n.producerMustRecompute(n)&&!Yh(n))return n.dirty=!1,void(n.lastCleanEpoch=jh);n.producerRecomputeValue(n),n.dirty=!1,n.lastCleanEpoch=jh}}function Yh(n){Gl(n);for(let t=0;t0}function Gl(n){n.producerNode??=[],n.producerIndexOfThis??=[],n.producerLastReadVersion??=[]}let Zd=null;function Eo(n){return"function"==typeof n}function Jd(n){const e=n(i=>{Error.call(i),i.stack=(new Error).stack});return e.prototype=Object.create(Error.prototype),e.prototype.constructor=e,e}const gp=Jd(n=>function(e){n(this),this.message=e?`${e.length} errors occurred during unsubscription:\n${e.map((i,r)=>`${r+1}) ${i.toString()}`).join("\n ")}`:"",this.name="UnsubscriptionError",this.errors=e});function vp(n,t){if(n){const e=n.indexOf(t);0<=e&&n.splice(e,1)}}class As{constructor(t){this.initialTeardown=t,this.closed=!1,this._parentage=null,this._finalizers=null}unsubscribe(){let t;if(!this.closed){this.closed=!0;const{_parentage:e}=this;if(e)if(this._parentage=null,Array.isArray(e))for(const s of e)s.remove(this);else e.remove(this);const{initialTeardown:i}=this;if(Eo(i))try{i()}catch(s){t=s instanceof gp?s.errors:[s]}const{_finalizers:r}=this;if(r){this._finalizers=null;for(const s of r)try{Dm(s)}catch(o){t=t??[],o instanceof gp?t=[...t,...o.errors]:t.push(o)}}if(t)throw new gp(t)}}add(t){var e;if(t&&t!==this)if(this.closed)Dm(t);else{if(t instanceof As){if(t.closed||t._hasParent(this))return;t._addParent(this)}(this._finalizers=null!==(e=this._finalizers)&&void 0!==e?e:[]).push(t)}}_hasParent(t){const{_parentage:e}=this;return e===t||Array.isArray(e)&&e.includes(t)}_addParent(t){const{_parentage:e}=this;this._parentage=Array.isArray(e)?(e.push(t),e):e?[e,t]:t}_removeParent(t){const{_parentage:e}=this;e===t?this._parentage=null:Array.isArray(e)&&vp(e,t)}remove(t){const{_finalizers:e}=this;e&&vp(e,t),t instanceof As&&t._removeParent(this)}}As.EMPTY=(()=>{const n=new As;return n.closed=!0,n})();const Xl=As.EMPTY;function Em(n){return n instanceof As||n&&"closed"in n&&Eo(n.remove)&&Eo(n.add)&&Eo(n.unsubscribe)}function Dm(n){Eo(n)?n():n.unsubscribe()}const ql={onUnhandledError:null,onStoppedNotification:null,Promise:void 0,useDeprecatedSynchronousErrorHandling:!1,useDeprecatedNextContext:!1},Z={setTimeout(n,t,...e){const{delegate:i}=Z;return i?.setTimeout?i.setTimeout(n,t,...e):setTimeout(n,t,...e)},clearTimeout(n){const{delegate:t}=Z;return(t?.clearTimeout||clearTimeout)(n)},delegate:void 0};function ye(){}const pe=at("C",void 0,void 0);function at(n,t,e){return{kind:n,value:t,error:e}}let tt=null;function At(n){if(ql.useDeprecatedSynchronousErrorHandling){const t=!tt;if(t&&(tt={errorThrown:!1,error:null}),n(),t){const{errorThrown:e,error:i}=tt;if(tt=null,e)throw i}}else n()}class pt extends As{constructor(t){super(),this.isStopped=!1,t?(this.destination=t,Em(t)&&t.add(this)):this.destination=Wt}static create(t,e,i){return new cr(t,e,i)}next(t){this.isStopped?Pr(function ke(n){return at("N",n,void 0)}(t),this):this._next(t)}error(t){this.isStopped?Pr(function be(n){return at("E",void 0,n)}(t),this):(this.isStopped=!0,this._error(t))}complete(){this.isStopped?Pr(pe,this):(this.isStopped=!0,this._complete())}unsubscribe(){this.closed||(this.isStopped=!0,super.unsubscribe(),this.destination=null)}_next(t){this.destination.next(t)}_error(t){try{this.destination.error(t)}finally{this.unsubscribe()}}_complete(){try{this.destination.complete()}finally{this.unsubscribe()}}}const Di=Function.prototype.bind;function ni(n,t){return Di.call(n,t)}class mi{constructor(t){this.partialObserver=t}next(t){const{partialObserver:e}=this;if(e.next)try{e.next(t)}catch(i){ki(i)}}error(t){const{partialObserver:e}=this;if(e.error)try{e.error(t)}catch(i){ki(i)}else ki(t)}complete(){const{partialObserver:t}=this;if(t.complete)try{t.complete()}catch(e){ki(e)}}}class cr extends pt{constructor(t,e,i){let r;if(super(),Eo(t)||!t)r={next:t??void 0,error:e??void 0,complete:i??void 0};else{let s;this&&ql.useDeprecatedNextContext?(s=Object.create(t),s.unsubscribe=()=>this.unsubscribe(),r={next:t.next&&ni(t.next,s),error:t.error&&ni(t.error,s),complete:t.complete&&ni(t.complete,s)}):r=t}this.destination=new mi(r)}}function ki(n){ql.useDeprecatedSynchronousErrorHandling?function Lt(n){ql.useDeprecatedSynchronousErrorHandling&&tt&&(tt.errorThrown=!0,tt.error=n)}(n):function se(n){Z.setTimeout(()=>{const{onUnhandledError:t}=ql;if(!t)throw n;t(n)})}(n)}function Pr(n,t){const{onStoppedNotification:e}=ql;e&&Z.setTimeout(()=>e(n,t))}const Wt={closed:!0,next:ye,error:function is(n){throw n},complete:ye},ct="function"==typeof Symbol&&Symbol.observable||"@@observable";function jn(n){return n}let Pi=(()=>{class n{constructor(e){e&&(this._subscribe=e)}lift(e){const i=new n;return i.source=this,i.operator=e,i}subscribe(e,i,r){const s=function et(n){return n&&n instanceof pt||function dr(n){return n&&Eo(n.next)&&Eo(n.error)&&Eo(n.complete)}(n)&&Em(n)}(e)?e:new cr(e,i,r);return At(()=>{const{operator:o,source:a}=this;s.add(o?o.call(s,a):a?this._subscribe(s):this._trySubscribe(s))}),s}_trySubscribe(e){try{return this._subscribe(e)}catch(i){e.error(i)}}forEach(e,i){return new(i=lt(i))((r,s)=>{const o=new cr({next:a=>{try{e(a)}catch(l){s(l),o.unsubscribe()}},error:s,complete:r});this.subscribe(o)})}_subscribe(e){var i;return null===(i=this.source)||void 0===i?void 0:i.subscribe(e)}[ct](){return this}pipe(...e){return function Zr(n){return 0===n.length?jn:1===n.length?n[0]:function(e){return n.reduce((i,r)=>r(i),e)}}(e)(this)}toPromise(e){return new(e=lt(e))((i,r)=>{let s;this.subscribe(o=>s=o,o=>r(o),()=>i(s))})}}return n.create=t=>new n(t),n})();function lt(n){var t;return null!==(t=n??ql.Promise)&&void 0!==t?t:Promise}const yi=Jd(n=>function(){n(this),this.name="ObjectUnsubscribedError",this.message="object unsubscribed"});let Pt=(()=>{class n extends Pi{constructor(){super(),this.closed=!1,this.currentObservers=null,this.observers=[],this.isStopped=!1,this.hasError=!1,this.thrownError=null}lift(e){const i=new rs(this,this);return i.operator=e,i}_throwIfClosed(){if(this.closed)throw new yi}next(e){At(()=>{if(this._throwIfClosed(),!this.isStopped){this.currentObservers||(this.currentObservers=Array.from(this.observers));for(const i of this.currentObservers)i.next(e)}})}error(e){At(()=>{if(this._throwIfClosed(),!this.isStopped){this.hasError=this.isStopped=!0,this.thrownError=e;const{observers:i}=this;for(;i.length;)i.shift().error(e)}})}complete(){At(()=>{if(this._throwIfClosed(),!this.isStopped){this.isStopped=!0;const{observers:e}=this;for(;e.length;)e.shift().complete()}})}unsubscribe(){this.isStopped=this.closed=!0,this.observers=this.currentObservers=null}get observed(){var e;return(null===(e=this.observers)||void 0===e?void 0:e.length)>0}_trySubscribe(e){return this._throwIfClosed(),super._trySubscribe(e)}_subscribe(e){return this._throwIfClosed(),this._checkFinalizedStatuses(e),this._innerSubscribe(e)}_innerSubscribe(e){const{hasError:i,isStopped:r,observers:s}=this;return i||r?Xl:(this.currentObservers=null,s.push(e),new As(()=>{this.currentObservers=null,vp(s,e)}))}_checkFinalizedStatuses(e){const{hasError:i,thrownError:r,isStopped:s}=this;i?e.error(r):s&&e.complete()}asObservable(){const e=new Pi;return e.source=this,e}}return n.create=(t,e)=>new rs(t,e),n})();class rs extends Pt{constructor(t,e){super(),this.destination=t,this.source=e}next(t){var e,i;null===(i=null===(e=this.destination)||void 0===e?void 0:e.next)||void 0===i||i.call(e,t)}error(t){var e,i;null===(i=null===(e=this.destination)||void 0===e?void 0:e.error)||void 0===i||i.call(e,t)}complete(){var t,e;null===(e=null===(t=this.destination)||void 0===t?void 0:t.complete)||void 0===e||e.call(t)}_subscribe(t){var e,i;return null!==(i=null===(e=this.source)||void 0===e?void 0:e.subscribe(t))&&void 0!==i?i:Xl}}class _o extends Pt{constructor(t){super(),this._value=t}get value(){return this.getValue()}_subscribe(t){const e=super._subscribe(t);return!e.closed&&t.next(this._value),e}getValue(){const{hasError:t,thrownError:e,_value:i}=this;if(t)throw e;return this._throwIfClosed(),i}next(t){super.next(this._value=t)}}class Ls extends pt{constructor(t,e,i,r,s,o){super(t),this.onFinalize=s,this.shouldUnsubscribe=o,this._next=e?function(a){try{e(a)}catch(l){t.error(l)}}:super._next,this._error=r?function(a){try{r(a)}catch(l){t.error(l)}finally{this.unsubscribe()}}:super._error,this._complete=i?function(){try{i()}catch(a){t.error(a)}finally{this.unsubscribe()}}:super._complete}unsubscribe(){var t;if(!this.shouldUnsubscribe||this.shouldUnsubscribe()){const{closed:e}=this;super.unsubscribe(),!e&&(null===(t=this.onFinalize)||void 0===t||t.call(this))}}}function jr(n,t){return function Ur(n){return t=>{if(function cn(n){return Eo(n?.lift)}(t))return t.lift(function(e){try{return n(e,this)}catch(i){this.error(i)}});throw new TypeError("Unable to lift unknown Observable type")}}((e,i)=>{let r=0;e.subscribe(function Do(n,t,e,i,r){return new Ls(n,t,e,i,r)}(i,s=>{i.next(n.call(t,s,r++))}))})}class F extends Error{constructor(t,e){super(function ae(n,t){return`NG0${Math.abs(n)}${t?": "+t:""}`}(t,e)),this.code=t}}function Xe(n){for(let t in n)if(n[t]===Xe)return t;throw Error("Could not find renamed property on target object.")}function mt(n,t){for(const e in t)t.hasOwnProperty(e)&&!n.hasOwnProperty(e)&&(n[e]=t[e])}function dt(n){if("string"==typeof n)return n;if(Array.isArray(n))return"["+n.map(dt).join(", ")+"]";if(null==n)return""+n;if(n.overriddenName)return`${n.overriddenName}`;if(n.name)return`${n.name}`;const t=n.toString();if(null==t)return""+t;const e=t.indexOf("\n");return-1===e?t:t.substring(0,e)}function qt(n,t){return null==n||""===n?null===t?"":t:null==t||""===t?n:n+" "+t}const ur=Xe({__forward_ref__:Xe});function ir(n){return n.__forward_ref__=ir,n.toString=function(){return dt(this())},n}function vt(n){return function Tn(n){return"function"==typeof n&&n.hasOwnProperty(ur)&&n.__forward_ref__===ir}(n)?n():n}function $l(n){return n&&!!n.\u0275providers}const Zl=Xe({\u0275cmp:Xe}),Kd=Xe({\u0275dir:Xe}),mp=Xe({\u0275pipe:Xe}),Uo=Xe({\u0275fac:Xe}),jo=Xe({__NG_ELEMENT_ID__:Xe}),yp=Xe({__NG_ENV_ID__:Xe});function Ri(n){return"function"==typeof n?n.name||n.toString():"object"==typeof n&&null!=n&&"function"==typeof n.type?n.type.name||n.type.toString():function Nt(n){return"string"==typeof n?n:null==n?"":String(n)}(n)}function Ob(n,t){throw new F(-201,!1)}function so(n,t){null==n&&function zt(n,t,e,i){throw new Error(`ASSERTION ERROR: ${n}`+(null==i?"":` [Expected=> ${e} ${i} ${t} <=Actual]`))}(t,n,null,"!=")}function Yi(n){return{token:n.token,providedIn:n.providedIn||null,factory:n.factory,value:void 0}}function Sp(n){return{providers:n.providers||[],imports:n.imports||[]}}function xm(n){return RT(n,Am)||RT(n,HT)}function RT(n,t){return n.hasOwnProperty(t)?n[t]:null}function Tm(n){return n&&(n.hasOwnProperty(kb)||n.hasOwnProperty(x_))?n[kb]:null}const Am=Xe({\u0275prov:Xe}),kb=Xe({\u0275inj:Xe}),HT=Xe({ngInjectableDef:Xe}),x_=Xe({ngInjectorDef:Xe});var xi=function(n){return n[n.Default=0]="Default",n[n.Host=1]="Host",n[n.Self=2]="Self",n[n.SkipSelf=4]="SkipSelf",n[n.Optional=8]="Optional",n}(xi||{});let Pb;function oo(n){const t=Pb;return Pb=n,t}function FT(n,t,e){const i=xm(n);return i&&"root"==i.providedIn?void 0===i.value?i.value=i.factory():i.value:e&xi.Optional?null:void 0!==t?t:void Ob()}const rr=globalThis;class Ht{constructor(t,e){this._desc=t,this.ngMetadataName="InjectionToken",this.\u0275prov=void 0,"number"==typeof e?this.__NG_ELEMENT_ID__=e:void 0!==e&&(this.\u0275prov=Yi({token:this,providedIn:e.providedIn||"root",factory:e.factory}))}get multi(){return this}toString(){return`InjectionToken ${this._desc}`}}const Ip={},Fb="__NG_DI_FLAG__",Lm="ngTempTokenPath",L_=/\n/gm,UT="__source";let tu;function qh(n){const t=tu;return tu=n,t}function k_(n,t=xi.Default){if(void 0===tu)throw new F(-203,!1);return null===tu?FT(n,void 0,t):tu.get(n,t&xi.Optional?null:void 0,t)}function _i(n,t=xi.Default){return(function BT(){return Pb}()||k_)(vt(n),t)}function Hi(n,t=xi.Default){return _i(n,Nm(t))}function Nm(n){return typeof n>"u"||"number"==typeof n?n:0|(n.optional&&8)|(n.host&&1)|(n.self&&2)|(n.skipSelf&&4)}function _b(n){const t=[];for(let e=0;et){o=s-1;break}}}for(;ss?"":r[d+1].toLowerCase();const f=8&i?u:null;if(f&&-1!==VT(f,h,0)||2&i&&h!==u){if(Ma(i))return!1;o=!0}}}}else{if(!o&&!Ma(i)&&!Ma(l))return!1;if(o&&Ma(l))continue;o=!1,i=l|1&i}}return Ma(i)||o}function Ma(n){return 0==(1&n)}function __(n,t,e,i){if(null===t)return-1;let r=0;if(i||!e){let s=!1;for(;r-1)for(e++;e0?'="'+a+'"':"")+"]"}else 8&i?r+="."+o:4&i&&(r+=" "+o);else""!==r&&!Ma(o)&&(t+=$T(s,r),r=""),i=o,s=s||!Ma(i);e++}return""!==r&&(t+=$T(s,r)),t}function jb(n){return Jl(()=>{const t=JT(n),e={...t,decls:n.decls,vars:n.vars,template:n.template,consts:n.consts||null,ngContentSelectors:n.ngContentSelectors,onPush:n.changeDetection===Om.OnPush,directiveDefs:null,pipeDefs:null,dependencies:t.standalone&&n.dependencies||null,getStandaloneInjector:null,signals:n.signals??!1,data:n.data||{},encapsulation:n.encapsulation||ba.Emulated,styles:n.styles||Qi,_:null,schemas:n.schemas||null,tView:null,id:""};KT(e);const i=n.dependencies;return e.directiveDefs=Pm(i,!1),e.pipeDefs=Pm(i,!0),e.id=function Z_(n){let t=0;const e=[n.selectors,n.ngContentSelectors,n.hostVars,n.hostAttrs,n.consts,n.vars,n.decls,n.encapsulation,n.standalone,n.signals,n.exportAs,JSON.stringify(n.inputs),JSON.stringify(n.outputs),Object.getOwnPropertyNames(n.type.prototype),!!n.contentQueries,!!n.viewQuery].join("|");for(const r of e)t=Math.imul(31,t)+r.charCodeAt(0)<<0;return t+=2147483648,"c"+t}(e),e})}function X_(n){return di(n)||Wn(n)}function q_(n){return null!==n}function km(n){return Jl(()=>({type:n.type,bootstrap:n.bootstrap||Qi,declarations:n.declarations||Qi,imports:n.imports||Qi,exports:n.exports||Qi,transitiveCompileScopes:null,schemas:n.schemas||null,id:n.id||null}))}function ZT(n,t){if(null==n)return rl;const e={};for(const i in n)if(n.hasOwnProperty(i)){const r=n[i];let s,o,a=$h.None;Array.isArray(r)?(a=r[0],s=r[1],o=r[2]??s):(s=r,o=r),t?(e[s]=a!==$h.None?[i,a]:i,t[s]=o):e[s]=i}return e}function nr(n){return Jl(()=>{const t=JT(n);return KT(t),t})}function di(n){return n[Zl]||null}function Wn(n){return n[Kd]||null}function gs(n){return n[mp]||null}function JT(n){const t={};return{type:n.type,providersResolver:null,factory:null,hostBindings:n.hostBindings||null,hostVars:n.hostVars||0,hostAttrs:n.hostAttrs||null,contentQueries:n.contentQueries||null,declaredInputs:t,inputTransforms:null,inputConfig:n.inputs||rl,exportAs:n.exportAs||null,standalone:!0===n.standalone,signals:!0===n.signals,selectors:n.selectors||Qi,viewQuery:n.viewQuery||null,features:n.features||null,setInput:null,findHostDirectiveDefs:null,hostDirectives:null,inputs:ZT(n.inputs,t),outputs:ZT(n.outputs),debugInfo:null}}function KT(n){n.features?.forEach(t=>t(n))}function Pm(n,t){if(!n)return null;const e=t?gs:X_;return()=>("function"==typeof n?n():n).map(i=>e(i)).filter(q_)}const Vr=0,Be=1,Ct=2,vn=3,wa=4,Os=5,Ca=6,iu=7,Er=8,Xs=9,Kl=10,Yt=11,wp=12,eA=13,ru=14,Jr=15,Cp=16,nu=17,nl=18,Ep=19,tA=20,Zh=21,zm=22,Vc=23,jt=25,Vb=1,sl=7,su=9,mn=10;var Wb=function(n){return n[n.None=0]="None",n[n.HasTransplantedViews=2]="HasTransplantedViews",n}(Wb||{});function ks(n){return Array.isArray(n)&&"object"==typeof n[Vb]}function Ps(n){return Array.isArray(n)&&!0===n[Vb]}function Yb(n){return 0!=(4&n.flags)}function Wc(n){return n.componentOffset>-1}function Hm(n){return 1==(1&n.flags)}function Ea(n){return!!n.template}function Qb(n){return 0!=(512&n[Ct])}function Yc(n,t){return n.hasOwnProperty(Uo)?n[Uo]:null}class tU{constructor(t,e,i){this.previousValue=t,this.currentValue=e,this.firstChange=i}isFirstChange(){return this.firstChange}}function sA(n,t,e,i){null!==t?t.applyValueToInputSignal(t,i):n[e]=i}function oA(n){return n.type.prototype.ngOnChanges&&(n.setInput=rU),iU}function iU(){const n=lA(this),t=n?.current;if(t){const e=n.previous;if(e===rl)n.previous=t;else for(let i in t)e[i]=t[i];n.current=null,this.ngOnChanges(t)}}function rU(n,t,e,i,r){const s=this.declaredInputs[i],o=lA(n)||function nU(n,t){return n[aA]=t}(n,{previous:rl,current:null}),a=o.current||(o.current={}),l=o.previous,h=l[s];a[s]=new tU(h&&h.currentValue,e,l===rl),sA(n,t,r,e)}const aA="__ngSimpleChanges__";function lA(n){return n[aA]||null}const ol=function(n,t,e){};let dA=!1;function fr(n){for(;Array.isArray(n);)n=n[Vr];return n}function qs(n,t){return fr(t[n.index])}function Tp(n,t){return n.data[t]}function To(n,t){const e=t[n];return ks(e)?e:e[Vr]}function Zb(n){return 128==(128&n[Ct])}function al(n,t){return null==t?null:n[t]}function uA(n){n[nu]=0}function cU(n){1024&n[Ct]||(n[Ct]|=1024,Zb(n)&&Ap(n))}function pA(n){return 9216&n[Ct]||n[Vc]?.dirty}function Jb(n){pA(n)?Ap(n):64&n[Ct]&&(function oU(){return dA}()?(n[Ct]|=1024,Ap(n)):n[Kl].changeDetectionScheduler?.notify())}function Ap(n){n[Kl].changeDetectionScheduler?.notify();let t=Qc(n);for(;null!==t&&!(8192&t[Ct])&&(t[Ct]|=8192,Zb(t));)t=Qc(t)}function Qc(n){const t=n[vn];return Ps(t)?t[vn]:t}const Rt={lFrame:CA(null),bindingsEnabled:!0,skipHydrationRootTNode:null};function vA(){return Rt.bindingsEnabled}function Se(){return Rt.lFrame.lView}function Ti(){return Rt.lFrame.tView}function pr(){let n=mA();for(;null!==n&&64===n.type;)n=n.parent;return n}function mA(){return Rt.lFrame.currentTNode}function ll(n,t){const e=Rt.lFrame;e.currentTNode=n,e.isParent=t}function e1(){return Rt.lFrame.isParent}function wU(n,t){const e=Rt.lFrame;e.bindingIndex=e.bindingRootIndex=n,i1(t)}function i1(n){Rt.lFrame.currentDirectiveIndex=n}function bA(){return Rt.lFrame.currentQueryIndex}function n1(n){Rt.lFrame.currentQueryIndex=n}function EU(n){const t=n[Be];return 2===t.type?t.declTNode:1===t.type?n[Os]:null}function MA(n,t,e){if(e&xi.SkipSelf){let r=t,s=n;for(;!(r=r.parent,null!==r||e&xi.Host||(r=EU(s),null===r||(s=s[ru],10&r.type))););if(null===r)return!1;t=r,n=s}const i=Rt.lFrame=wA();return i.currentTNode=t,i.lView=n,!0}function s1(n){const t=wA(),e=n[Be];Rt.lFrame=t,t.currentTNode=e.firstChild,t.lView=n,t.tView=e,t.contextLView=n,t.bindingIndex=e.bindingStartIndex,t.inI18n=!1}function wA(){const n=Rt.lFrame,t=null===n?null:n.child;return null===t?CA(n):t}function CA(n){const t={currentTNode:null,isParent:!0,lView:null,tView:null,selectedIndex:-1,contextLView:null,elementDepthCount:0,currentNamespace:null,currentDirectiveIndex:-1,bindingRootIndex:-1,bindingIndex:-1,currentQueryIndex:0,parent:n,child:null,inI18n:!1};return null!==n&&(n.child=t),t}function EA(){const n=Rt.lFrame;return Rt.lFrame=n.parent,n.currentTNode=null,n.lView=null,n}const DA=EA;function o1(){const n=EA();n.isParent=!0,n.tView=null,n.selectedIndex=-1,n.contextLView=null,n.elementDepthCount=0,n.currentDirectiveIndex=-1,n.currentNamespace=null,n.bindingRootIndex=-1,n.bindingIndex=-1,n.currentQueryIndex=0}function zs(){return Rt.lFrame.selectedIndex}function Gc(n){Rt.lFrame.selectedIndex=n}let TA=!0;function _m(){return TA}function Jh(n){TA=n}function Um(n,t){for(let e=t.directiveStart,i=t.directiveEnd;e=i)break}else t[l]<0&&(n[nu]+=65536),(a>14>16&&(3&n[Ct])===t&&(n[Ct]+=16384,LA(a,s)):LA(a,s)}const lu=-1;class Np{constructor(t,e,i){this.factory=t,this.resolving=!1,this.canSeeViewProviders=e,this.injectImpl=i}}function h1(n){return n!==lu}function Op(n){return 32767&n}function kp(n,t){let e=function HU(n){return n>>16}(n),i=t;for(;e>0;)i=i[ru],e--;return i}let c1=!0;function Wm(n){const t=c1;return c1=n,t}const NA=255,OA=5;let BU=0;const cl={};function Ym(n,t){const e=kA(n,t);if(-1!==e)return e;const i=t[Be];i.firstCreatePass&&(n.injectorIndex=t.length,d1(i.data,n),d1(t,null),d1(i.blueprint,null));const r=Qm(n,t),s=n.injectorIndex;if(h1(r)){const o=Op(r),a=kp(r,t),l=a[Be].data;for(let h=0;h<8;h++)t[s+h]=a[o+h]|l[o+h]}return t[s+8]=r,s}function d1(n,t){n.push(0,0,0,0,0,0,0,0,t)}function kA(n,t){return-1===n.injectorIndex||n.parent&&n.parent.injectorIndex===n.injectorIndex||null===t[n.injectorIndex+8]?-1:n.injectorIndex}function Qm(n,t){if(n.parent&&-1!==n.parent.injectorIndex)return n.parent.injectorIndex;let e=0,i=null,r=t;for(;null!==r;){if(i=_A(r),null===i)return lu;if(e++,r=r[ru],-1!==i.injectorIndex)return i.injectorIndex|e<<16}return lu}function u1(n,t,e){!function FU(n,t,e){let i;"string"==typeof e?i=e.charCodeAt(0)||0:e.hasOwnProperty(jo)&&(i=e[jo]),null==i&&(i=e[jo]=BU++);const r=i&NA;t.data[n+(r>>OA)]|=1<=0?t&NA:VU:t}(e);if("function"==typeof s){if(!MA(t,n,i))return i&xi.Host?PA(r,0,i):zA(t,e,i,r);try{let o;if(o=s(i),null!=o||i&xi.Optional)return o;Ob()}finally{DA()}}else if("number"==typeof s){let o=null,a=kA(n,t),l=lu,h=i&xi.Host?t[Jr][Os]:null;for((-1===a||i&xi.SkipSelf)&&(l=-1===a?Qm(n,t):t[a+8],l!==lu&&FA(i,!1)?(o=t[Be],a=Op(l),t=kp(l,t)):a=-1);-1!==a;){const c=t[Be];if(BA(s,a,c.data)){const d=UU(a,t,e,o,i,h);if(d!==cl)return d}l=t[a+8],l!==lu&&FA(i,t[Be].data[a+8]===h)&&BA(s,a,t)?(o=c,a=Op(l),t=kp(l,t)):a=-1}}return r}function UU(n,t,e,i,r,s){const o=t[Be],a=o.data[n+8],c=Gm(a,o,e,null==i?Wc(a)&&c1:i!=o&&0!=(3&a.type),r&xi.Host&&s===a);return null!==c?Xc(t,o,c,a):cl}function Gm(n,t,e,i,r){const s=n.providerIndexes,o=t.data,a=1048575&s,l=n.directiveStart,c=s>>20,u=r?a+c:n.directiveEnd;for(let f=i?a:a+c;f=l&&p.type===e)return f}if(r){const f=o[l];if(f&&Ea(f)&&f.type===e)return l}return null}function Xc(n,t,e,i){let r=n[e];const s=t.data;if(function kU(n){return n instanceof Np}(r)){const o=r;o.resolving&&function Vo(n,t){const e=t?`. Dependency path: ${t.join(" > ")} > ${n}`:"";throw new F(-200,`Circular dependency in DI detected for ${n}${e}`)}(Ri(s[e]));const a=Wm(o.canSeeViewProviders);o.resolving=!0;const h=o.injectImpl?oo(o.injectImpl):null;MA(n,i,xi.Default);try{r=n[e]=o.factory(void 0,s,n,i),t.firstCreatePass&&e>=i.directiveStart&&function NU(n,t,e){const{ngOnChanges:i,ngOnInit:r,ngDoCheck:s}=t.type.prototype;if(i){const o=oA(t);(e.preOrderHooks??=[]).push(n,o),(e.preOrderCheckHooks??=[]).push(n,o)}r&&(e.preOrderHooks??=[]).push(0-n,r),s&&((e.preOrderHooks??=[]).push(n,s),(e.preOrderCheckHooks??=[]).push(n,s))}(e,s[e],t)}finally{null!==h&&oo(h),Wm(a),o.resolving=!1,DA()}}return r}function BA(n,t,e){return!!(e[t+(n>>OA)]&1<Array.isArray(e)?vu(e,t):t(e))}function jA(n,t,e){t>=n.length?n.push(e):n.splice(t,0,e)}function Xm(n,t){return t>=n.length-1?n.pop():n.splice(t,1)[0]}const Su=new Ht(""),XA=new Ht("",-1),M1=new Ht("");class Jm{get(t,e=Ip){if(e===Ip){const i=new Error(`NullInjectorError: No provider for ${dt(t)}!`);throw i.name="NullInjectorError",i}return e}}function fj(...n){return{\u0275providers:qA(0,n),\u0275fromNgModule:!0}}function qA(n,...t){const e=[],i=new Set;let r;const s=o=>{e.push(o)};return vu(t,o=>{const a=o;Km(a,s,[],i)&&(r||=[],r.push(a))}),void 0!==r&&$A(r,s),e}function $A(n,t){for(let e=0;e{t(s,i)})}}function Km(n,t,e,i){if(!(n=vt(n)))return!1;let r=null,s=Tm(n);const o=!s&&di(n);if(s||o){if(o&&!o.standalone)return!1;r=n}else{const l=n.ngModule;if(s=Tm(l),!s)return!1;r=l}const a=i.has(r);if(o){if(a)return!1;if(i.add(r),o.dependencies){const l="function"==typeof o.dependencies?o.dependencies():o.dependencies;for(const h of l)Km(h,t,e,i)}}else{if(!s)return!1;{if(null!=s.imports&&!a){let h;i.add(r);try{vu(s.imports,c=>{Km(c,t,e,i)&&(h||=[],h.push(c))})}finally{}void 0!==h&&$A(h,t)}if(!a){const h=Yc(r)||(()=>new r);t({provide:r,useFactory:h,deps:Qi},r),t({provide:M1,useValue:r,multi:!0},r),t({provide:Su,useValue:()=>_i(r),multi:!0},r)}const l=s.providers;if(null!=l&&!a){const h=n;C1(l,c=>{t(c,h)})}}}return r!==n&&void 0!==n.providers}function C1(n,t){for(let e of n)$l(e)&&(e=e.\u0275providers),Array.isArray(e)?C1(e,t):t(e)}const pj=Xe({provide:String,useValue:Xe});function E1(n){return null!==n&&"object"==typeof n&&pj in n}function qc(n){return"function"==typeof n}const D1=new Ht(""),ey={},vj={};let x1;function ty(){return void 0===x1&&(x1=new Jm),x1}class ih{}class Iu extends ih{get destroyed(){return this._destroyed}constructor(t,e,i,r){super(),this.parent=e,this.source=i,this.scopes=r,this.records=new Map,this._ngOnDestroyHooks=new Set,this._onDestroyHooks=[],this._destroyed=!1,A1(t,o=>this.processProvider(o)),this.records.set(XA,bu(void 0,this)),r.has("environment")&&this.records.set(ih,bu(void 0,this));const s=this.records.get(D1);null!=s&&"string"==typeof s.value&&this.scopes.add(s.value),this.injectorDefTypes=new Set(this.get(M1,Qi,xi.Self))}destroy(){this.assertNotDestroyed(),this._destroyed=!0;try{for(const e of this._ngOnDestroyHooks)e.ngOnDestroy();const t=this._onDestroyHooks;this._onDestroyHooks=[];for(const e of t)e()}finally{this.records.clear(),this._ngOnDestroyHooks.clear(),this.injectorDefTypes.clear()}}onDestroy(t){return this.assertNotDestroyed(),this._onDestroyHooks.push(t),()=>this.removeOnDestroy(t)}runInContext(t){this.assertNotDestroyed();const e=qh(this),i=oo(void 0);try{return t()}finally{qh(e),oo(i)}}get(t,e=Ip,i=xi.Default){if(this.assertNotDestroyed(),t.hasOwnProperty(yp))return t[yp](this);i=Nm(i);const s=qh(this),o=oo(void 0);try{if(!(i&xi.SkipSelf)){let l=this.records.get(t);if(void 0===l){const h=function bj(n){return"function"==typeof n||"object"==typeof n&&n instanceof Ht}(t)&&xm(t);l=h&&this.injectableDefInScope(h)?bu(T1(t),ey):null,this.records.set(t,l)}if(null!=l)return this.hydrate(t,l)}return(i&xi.Self?ty():this.parent).get(t,e=i&xi.Optional&&e===Ip?null:e)}catch(a){if("NullInjectorError"===a.name){if((a[Lm]=a[Lm]||[]).unshift(dt(t)),s)throw a;return function z_(n,t,e,i){const r=n[Lm];throw t[UT]&&r.unshift(t[UT]),n.message=function R_(n,t,e,i=null){n=n&&"\n"===n.charAt(0)&&"\u0275"==n.charAt(1)?n.slice(2):n;let r=dt(t);if(Array.isArray(t))r=t.map(dt).join(" -> ");else if("object"==typeof t){let s=[];for(let o in t)if(t.hasOwnProperty(o)){let a=t[o];s.push(o+":"+("string"==typeof a?JSON.stringify(a):dt(a)))}r=`{${s.join(", ")}}`}return`${e}${i?"("+i+")":""}[${r}]: ${n.replace(L_,"\n ")}`}("\n"+n.message,r,e,i),n.ngTokenPath=r,n[Lm]=null,n}(a,t,"R3InjectorError",this.source)}throw a}finally{oo(o),qh(s)}}resolveInjectorInitializers(){const t=qh(this),e=oo(void 0);try{const r=this.get(Su,Qi,xi.Self);for(const s of r)s()}finally{qh(t),oo(e)}}toString(){const t=[],e=this.records;for(const i of e.keys())t.push(dt(i));return`R3Injector[${t.join(", ")}]`}assertNotDestroyed(){if(this._destroyed)throw new F(205,!1)}processProvider(t){let e=qc(t=vt(t))?t:vt(t&&t.provide);const i=function yj(n){return E1(n)?bu(void 0,n.useValue):bu(KA(n),ey)}(t);if(!qc(t)&&!0===t.multi){let r=this.records.get(e);r||(r=bu(void 0,ey,!0),r.factory=()=>_b(r.multi),this.records.set(e,r)),e=t,r.multi.push(t)}this.records.set(e,i)}hydrate(t,e){return e.value===ey&&(e.value=vj,e.value=e.factory()),"object"==typeof e.value&&e.value&&function Ij(n){return null!==n&&"object"==typeof n&&"function"==typeof n.ngOnDestroy}(e.value)&&this._ngOnDestroyHooks.add(e.value),e.value}injectableDefInScope(t){if(!t.providedIn)return!1;const e=vt(t.providedIn);return"string"==typeof e?"any"===e||this.scopes.has(e):this.injectorDefTypes.has(e)}removeOnDestroy(t){const e=this._onDestroyHooks.indexOf(t);-1!==e&&this._onDestroyHooks.splice(e,1)}}function T1(n){const t=xm(n),e=null!==t?t.factory:Yc(n);if(null!==e)return e;if(n instanceof Ht)throw new F(204,!1);if(n instanceof Function)return function mj(n){if(n.length>0)throw new F(204,!1);const e=function D_(n){return n&&(n[Am]||n[HT])||null}(n);return null!==e?()=>e.factory(n):()=>new n}(n);throw new F(204,!1)}function KA(n,t,e){let i;if(qc(n)){const r=vt(n);return Yc(r)||T1(r)}if(E1(n))i=()=>vt(n.useValue);else if(function JA(n){return!(!n||!n.useFactory)}(n))i=()=>n.useFactory(..._b(n.deps||[]));else if(function ZA(n){return!(!n||!n.useExisting)}(n))i=()=>_i(vt(n.useExisting));else{const r=vt(n&&(n.useClass||n.provide));if(!function Sj(n){return!!n.deps}(n))return Yc(r)||T1(r);i=()=>new r(..._b(n.deps))}return i}function bu(n,t,e=!1){return{factory:n,value:t,multi:e?[]:void 0}}function A1(n,t){for(const e of n)Array.isArray(e)?A1(e,t):e&&$l(e)?A1(e.\u0275providers,t):t(e)}function rL(n,t=null,e=null,i){const r=function nL(n,t=null,e=null,i,r=new Set){const s=[e||Qi,fj(n)];return i=i||("object"==typeof n?void 0:dt(n)),new Iu(s,t||ty(),i||null,r)}(n,t,e,i);return r.resolveInjectorInitializers(),r}let O1,Wo=(()=>{class n{static{this.THROW_IF_NOT_FOUND=Ip}static{this.NULL=new Jm}static create(e,i){if(Array.isArray(e))return rL({name:""},i,e,"");{const r=e.name??"";return rL({name:r},e.parent,e.providers,r)}}static{this.\u0275prov=Yi({token:n,providedIn:"any",factory:()=>_i(XA)})}static{this.__NG_ELEMENT_ID__=-1}}return n})();const k1=new Ht("",{providedIn:"root",factory:()=>Lj}),Lj="ng",oL=new Ht(""),Mu=new Ht("",{providedIn:"platform",factory:()=>"unknown"}),aL=new Ht("",{providedIn:"root",factory:()=>function Kh(){if(void 0!==O1)return O1;if(typeof document<"u")return document;throw new F(210,!1)}().body?.querySelector("[ngCspNonce]")?.getAttribute("ngCspNonce")||null});function oy(n){return 128==(128&n.flags)}var ic=function(n){return n[n.Important=1]="Important",n[n.DashCase=2]="DashCase",n}(ic||{});const B1=new Map;let Vj=0;const _1="__ngContext__";function Rs(n,t){ks(t)?(n[_1]=t[Ep],function Yj(n){B1.set(n[Ep],n)}(t)):n[_1]=t}let U1;function j1(n,t){return U1(n,t)}function Cu(n,t,e,i,r){if(null!=i){let s,o=!1;Ps(i)?s=i:ks(i)&&(o=!0,i=i[Vr]);const a=fr(i);0===n&&null!==e?null==r?AL(t,e,a):Zc(t,e,a,r||null,!0):1===n&&null!==e?Zc(t,e,a,r||null,!0):2===n?function fy(n,t,e){const i=dy(n,t);i&&function a6(n,t,e,i){n.removeChild(t,e,i)}(n,i,t,e)}(t,a,o):3===n&&t.destroyNode(a),null!=s&&function c6(n,t,e,i,r){const s=e[sl];s!==fr(e)&&Cu(t,n,i,s,r);for(let a=mn;a0&&(n[e-1][wa]=i[wa]);const s=Xm(n,mn+t);!function e6(n,t){DL(n,t),t[Vr]=null,t[Os]=null}(i[Be],i);const o=s[nl];null!==o&&o.detachView(s[Be]),i[vn]=null,i[wa]=null,i[Ct]&=-129}return i}function cy(n,t){if(!(256&t[Ct])){const e=t[Yt];e.destroyNode&&py(n,t,e,3,null,null),function i6(n){let t=n[wp];if(!t)return W1(n[Be],n);for(;t;){let e=null;if(ks(t))e=t[wp];else{const i=t[mn];i&&(e=i)}if(!e){for(;t&&!t[wa]&&t!==n;)ks(t)&&W1(t[Be],t),t=t[vn];null===t&&(t=n),ks(t)&&W1(t[Be],t),e=t&&t[wa]}t=e}}(t)}}function W1(n,t){if(!(256&t[Ct])){t[Ct]&=-129,t[Ct]|=256,t[Vc]&&function qd(n){if(Gl(n),Qh(n))for(let t=0;t=0?i[o]():i[-o].unsubscribe(),s+=2}else e[s].call(i[e[s+1]]);null!==i&&(t[iu]=null);const r=t[Zh];if(null!==r){t[Zh]=null;for(let s=0;s-1){const{encapsulation:s}=n.data[i.directiveStart+r];if(s===ba.None||s===ba.Emulated)return null}return qs(i,e)}}(n,t.parent,e)}function Zc(n,t,e,i,r){n.insertBefore(t,e,i,r)}function AL(n,t,e){n.appendChild(t,e)}function LL(n,t,e,i,r){null!==i?Zc(n,t,e,i,r):AL(n,t,e)}function dy(n,t){return n.parentNode(t)}let Q1,kL=function OL(n,t,e){return 40&n.type?qs(n,e):null};function uy(n,t,e,i){const r=Y1(n,i,t),s=t[Yt],a=function NL(n,t,e){return kL(n,t,e)}(i.parent||t[Os],i,t);if(null!=r)if(Array.isArray(e))for(let l=0;lnull;function lM(n,t,e=!1){return KL(n,t,e)}class G6{}class nN{}class q6{resolveComponentFactory(t){throw function X6(n){const t=Error(`No component factory found for ${dt(n)}.`);return t.ngComponent=n,t}(t)}}let wy=(()=>{class n{static{this.NULL=new q6}}return n})();function $6(){return Lu(pr(),Se())}function Lu(n,t){return new Jc(qs(n,t))}let Jc=(()=>{class n{constructor(e){this.nativeElement=e}static{this.__NG_ELEMENT_ID__=$6}}return n})();function Z6(n){return n instanceof Jc?n.nativeElement:n}class oN{}let uM=(()=>{class n{constructor(){this.destroyNode=null}static{this.__NG_ELEMENT_ID__=()=>function J6(){const n=Se(),e=To(pr().index,n);return(ks(e)?e:n)[Yt]}()}}return n})(),K6=(()=>{class n{static{this.\u0275prov=Yi({token:n,providedIn:"root",factory:()=>null})}}return n})();const fM={};function Xp(n,t,e,i,r=!1){for(;null!==e;){const s=t[e.index];null!==s&&i.push(fr(s)),Ps(s)&&pN(s,i);const o=e.type;if(8&o)Xp(n,t,e.child,i);else if(32&o){const a=j1(e,t);let l;for(;l=a();)i.push(l)}else if(16&o){const a=zL(t,e);if(Array.isArray(a))i.push(...a);else{const l=Qc(t[Jr]);Xp(l[Be],l,a,i,!0)}}e=r?e.projectionNext:e.next}return i}function pN(n,t){for(let e=mn;e!1,producerRecomputeValue:()=>{},consumerMarkedDirty:()=>{},consumerOnSignalRead:()=>{},consumerIsAlwaysLive:!0,consumerMarkedDirty:n=>{Ap(n.lView)},consumerOnSignalRead(){this.lView[Vc]=this}};function vN(n){return yN(n[wp])}function mN(n){return yN(n[wa])}function yN(n){for(;null!==n&&!Ps(n);)n=n[wa];return n}function vM(n){return n.ngOriginalError}class nh{constructor(){this._console=console}handleError(t){const e=this._findOriginalError(t);this._console.error("ERROR",t),e&&this._console.error("ORIGINAL ERROR",e)}_findOriginalError(t){let e=t&&vM(t);for(;e&&vM(e);)e=vM(e);return e||null}}const IN=new Ht("",{providedIn:"root",factory:()=>Hi(nh).handleError.bind(void 0)}),MN=new Ht("",{providedIn:"root",factory:()=>!1}),Qt={};function Nu(n=1){DN(Ti(),Se(),zs()+n,!1)}function DN(n,t,e,i){if(!i)if(3==(3&t[Ct])){const s=n.preOrderCheckHooks;null!==s&&jm(t,s,e)}else{const s=n.preOrderHooks;null!==s&&Vm(t,s,0,e)}Gc(e)}function Ot(n,t=xi.Default){const e=Se();return null===e?_i(n,t):RA(pr(),e,vt(n),t)}function xN(n,t,e,i,r,s){const o=Wi(null);try{let a=null;r&$h.SignalBased&&(a=t[i][Ts]),null!==a&&void 0!==a.transformFn&&(s=a.transformFn(s)),r&$h.HasDecoratorInputTransform&&(s=n.inputTransforms[i].call(t,s)),null!==n.setInput?n.setInput(t,a,s,e,i):sA(t,a,i,s)}finally{Wi(o)}}function xy(n,t,e,i,r,s,o,a,l,h,c){const d=t.blueprint.slice();return d[Vr]=r,d[Ct]=204|i,(null!==h||n&&2048&n[Ct])&&(d[Ct]|=2048),uA(d),d[vn]=d[ru]=n,d[Er]=e,d[Kl]=o||n&&n[Kl],d[Yt]=a||n&&n[Yt],d[Xs]=l||n&&n[Xs]||null,d[Os]=s,d[Ep]=function Wj(){return Vj++}(),d[Ca]=c,d[tA]=h,d[Jr]=2==t.type?n[Jr]:d,d}function Ou(n,t,e,i,r){let s=n.data[t];if(null===s)s=function mM(n,t,e,i,r){const s=mA(),o=e1(),l=n.data[t]=function LV(n,t,e,i,r,s){let o=t?t.injectorIndex:-1,a=0;return function au(){return null!==Rt.skipHydrationRootTNode}()&&(a|=128),{type:e,index:i,insertBeforeIndex:null,injectorIndex:o,directiveStart:-1,directiveEnd:-1,directiveStylingLast:-1,componentOffset:-1,propertyBindings:null,flags:a,providerIndexes:0,value:r,attrs:s,mergedAttrs:null,localNames:null,initialInputs:void 0,inputs:null,outputs:null,tView:null,next:null,prev:null,projectionNext:null,child:null,parent:t,projection:null,styles:null,stylesWithoutHost:null,residualStyles:void 0,classes:null,classesWithoutHost:null,residualClasses:void 0,classBindings:0,styleBindings:0}}(0,o?s:s&&s.parent,e,t,i,r);return null===n.firstChild&&(n.firstChild=l),null!==s&&(o?null==s.child&&null!==l.parent&&(s.child=l):null===s.next&&(s.next=l,l.prev=s)),l}(n,t,e,i,r),function MU(){return Rt.lFrame.inI18n}()&&(s.flags|=32);else if(64&s.type){s.type=e,s.value=i,s.attrs=r;const o=function Lp(){const n=Rt.lFrame,t=n.currentTNode;return n.isParent?t:t.parent}();s.injectorIndex=null===o?-1:o.injectorIndex}return ll(s,!0),s}function qp(n,t,e,i){if(0===e)return-1;const r=t.length;for(let s=0;sjt&&DN(n,t,jt,!1),ol(o?2:0,r),e(i,r)}finally{Gc(s),ol(o?3:1,r)}}function yM(n,t,e){if(Yb(t)){const i=Wi(null);try{const s=t.directiveEnd;for(let o=t.directiveStart;onull;function NN(n,t,e,i,r){for(let s in t){if(!t.hasOwnProperty(s))continue;const o=t[s];if(void 0===o)continue;i??={};let a,l=$h.None;Array.isArray(o)?(a=o[0],l=o[1]):a=o;let h=s;if(null!==r){if(!r.hasOwnProperty(s))continue;h=r[s]}0===n?ON(i,e,h,a,l):ON(i,e,h,a)}return i}function ON(n,t,e,i,r){let s;n.hasOwnProperty(e)?(s=n[e]).push(t,i):s=n[e]=[t,i],void 0!==r&&s.push(r)}function kN(n,t,e,i,r,s){for(let h=0;h0;){const e=n[--t];if("number"==typeof e&&e<0)return e}return 0})(o)!=a&&o.push(a),o.push(e,i,s)}}(n,t,i,qp(n,e,r.hostVars,Qt),r)}function YV(n,t,e,i,r,s){const o=s[t];if(null!==o)for(let a=0;an.nextProducerIndex;)n.producerNode.pop(),n.producerLastReadVersion.pop(),n.producerIndexOfThis.pop()}}(a,o),function fV(n){n.lView[Vc]!==n&&(n.lView=null,gN.push(n))}(a)),o1()}}function _N(n,t){for(let e=vN(n);null!==e;e=mN(e))for(let i=mn;i-1&&(_p(t,i),Xm(e,i))}this._attachedToViewContainer=!1}cy(this._lView[Be],this._lView)}onDestroy(t){!function Fm(n,t){if(256==(256&n[Ct]))throw new F(911,!1);null===n[Zh]&&(n[Zh]=[]),n[Zh].push(t)}(this._lView,t)}markForCheck(){$p(this._cdRefInjectingView||this._lView)}detach(){this._lView[Ct]&=-129}reattach(){Jb(this._lView),this._lView[Ct]|=128}detectChanges(){this._lView[Ct]|=1024,function xM(n,t=!0){const e=n[Kl],i=e.rendererFactory;i.begin?.();try{!function XV(n){TM(n,0);let t=0;for(;pA(n);){if(100===t)throw new F(103,!1);t++,TM(n,1)}}(n)}catch(s){throw t&&Ay(n,s),s}finally{i.end?.(),e.inlineEffectRunner?.flush()}}(this._lView,this.notifyErrorHandler)}checkNoChanges(){}attachToViewContainerRef(){if(this._appRef)throw new F(902,!1);this._attachedToViewContainer=!0}detachFromAppRef(){this._appRef=null,DL(this._lView[Be],this._lView)}attachToAppRef(t){if(this._attachedToViewContainer)throw new F(902,!1);this._appRef=t,Jb(this._lView)}}const WN=new Set;function LM(n){return t=>{setTimeout(n,void 0,t)}}const Yo=class h7 extends Pt{constructor(t=!1){super(),this.__isAsync=t}emit(t){super.next(t)}subscribe(t,e,i){let r=t,s=e||(()=>null),o=i;if(t&&"object"==typeof t){const l=t;r=l.next?.bind(l),s=l.error?.bind(l),o=l.complete?.bind(l)}this.__isAsync&&(s=LM(s),r&&(r=LM(r)),o&&(o=LM(o)));const a=super.subscribe({next:r,error:s,complete:o});return t instanceof As&&t.add(a),a}};function YN(...n){}class Rr{constructor({enableLongStackTrace:t=!1,shouldCoalesceEventChangeDetection:e=!1,shouldCoalesceRunChangeDetection:i=!1}){if(this.hasPendingMacrotasks=!1,this.hasPendingMicrotasks=!1,this.isStable=!0,this.onUnstable=new Yo(!1),this.onMicrotaskEmpty=new Yo(!1),this.onStable=new Yo(!1),this.onError=new Yo(!1),typeof Zone>"u")throw new F(908,!1);Zone.assertZonePatched();const r=this;r._nesting=0,r._outer=r._inner=Zone.current,Zone.TaskTrackingZoneSpec&&(r._inner=r._inner.fork(new Zone.TaskTrackingZoneSpec)),t&&Zone.longStackTraceZoneSpec&&(r._inner=r._inner.fork(Zone.longStackTraceZoneSpec)),r.shouldCoalesceEventChangeDetection=!i&&e,r.shouldCoalesceRunChangeDetection=i,r.lastRequestAnimationFrameId=-1,r.nativeRequestAnimationFrame=function c7(){const n="function"==typeof rr.requestAnimationFrame;let t=rr[n?"requestAnimationFrame":"setTimeout"],e=rr[n?"cancelAnimationFrame":"clearTimeout"];if(typeof Zone<"u"&&t&&e){const i=t[Zone.__symbol__("OriginalDelegate")];i&&(t=i);const r=e[Zone.__symbol__("OriginalDelegate")];r&&(e=r)}return{nativeRequestAnimationFrame:t,nativeCancelAnimationFrame:e}}().nativeRequestAnimationFrame,function f7(n){const t=()=>{!function u7(n){n.isCheckStableRunning||-1!==n.lastRequestAnimationFrameId||(n.lastRequestAnimationFrameId=n.nativeRequestAnimationFrame.call(rr,()=>{n.fakeTopEventTask||(n.fakeTopEventTask=Zone.root.scheduleEventTask("fakeTopEventTask",()=>{n.lastRequestAnimationFrameId=-1,OM(n),n.isCheckStableRunning=!0,NM(n),n.isCheckStableRunning=!1},void 0,()=>{},()=>{})),n.fakeTopEventTask.invoke()}),OM(n))}(n)};n._inner=n._inner.fork({name:"angular",properties:{isAngularZone:!0},onInvokeTask:(e,i,r,s,o,a)=>{if(function p7(n){return!(!Array.isArray(n)||1!==n.length)&&!0===n[0].data?.__ignore_ng_zone__}(a))return e.invokeTask(r,s,o,a);try{return QN(n),e.invokeTask(r,s,o,a)}finally{(n.shouldCoalesceEventChangeDetection&&"eventTask"===s.type||n.shouldCoalesceRunChangeDetection)&&t(),GN(n)}},onInvoke:(e,i,r,s,o,a,l)=>{try{return QN(n),e.invoke(r,s,o,a,l)}finally{n.shouldCoalesceRunChangeDetection&&t(),GN(n)}},onHasTask:(e,i,r,s)=>{e.hasTask(r,s),i===r&&("microTask"==s.change?(n._hasPendingMicrotasks=s.microTask,OM(n),NM(n)):"macroTask"==s.change&&(n.hasPendingMacrotasks=s.macroTask))},onHandleError:(e,i,r,s)=>(e.handleError(r,s),n.runOutsideAngular(()=>n.onError.emit(s)),!1)})}(r)}static isInAngularZone(){return typeof Zone<"u"&&!0===Zone.current.get("isAngularZone")}static assertInAngularZone(){if(!Rr.isInAngularZone())throw new F(909,!1)}static assertNotInAngularZone(){if(Rr.isInAngularZone())throw new F(909,!1)}run(t,e,i){return this._inner.run(t,e,i)}runTask(t,e,i,r){const s=this._inner,o=s.scheduleEventTask("NgZoneEvent: "+r,t,d7,YN,YN);try{return s.runTask(o,e,i)}finally{s.cancelTask(o)}}runGuarded(t,e,i){return this._inner.runGuarded(t,e,i)}runOutsideAngular(t){return this._outer.run(t)}}const d7={};function NM(n){if(0==n._nesting&&!n.hasPendingMicrotasks&&!n.isStable)try{n._nesting++,n.onMicrotaskEmpty.emit(null)}finally{if(n._nesting--,!n.hasPendingMicrotasks)try{n.runOutsideAngular(()=>n.onStable.emit(null))}finally{n.isStable=!0}}}function OM(n){n.hasPendingMicrotasks=!!(n._hasPendingMicrotasks||(n.shouldCoalesceEventChangeDetection||n.shouldCoalesceRunChangeDetection)&&-1!==n.lastRequestAnimationFrameId)}function QN(n){n._nesting++,n.isStable&&(n.isStable=!1,n.onUnstable.emit(null))}function GN(n){n._nesting--,NM(n)}let Jp=(()=>{class n{constructor(){this.handler=null,this.internalCallbacks=[]}execute(){const e=[...this.internalCallbacks];this.internalCallbacks.length=0;for(const r of e)r();return!!this.handler?.execute()||e.length>0}ngOnDestroy(){this.handler?.destroy(),this.handler=null,this.internalCallbacks.length=0}static{this.\u0275prov=Yi({token:n,providedIn:"root",factory:()=>new n})}}return n})();function y7(n,t){const e=To(t,n),i=e[Be];!function S7(n,t){for(let e=t.length;e0&&BL(n,e,s.join(" "))}}(u,w,p,i),void 0!==e&&function A7(n,t,e){const i=n.projection=[];for(let r=0;r=0;i--){const r=n[i];r.hostVars=t+=r.hostVars,r.hostAttrs=Mp(r.hostAttrs,e=Mp(e,r.hostAttrs))}}(i)}function N7(n,t){for(const e in t.inputs){if(!t.inputs.hasOwnProperty(e)||n.inputs.hasOwnProperty(e))continue;const i=t.inputs[e];if(void 0!==i&&(n.inputs[e]=i,n.declaredInputs[e]=t.declaredInputs[e],null!==t.inputTransforms)){const r=Array.isArray(i)?i[0]:i;if(!t.inputTransforms.hasOwnProperty(r))continue;n.inputTransforms??={},n.inputTransforms[r]=t.inputTransforms[r]}}}function Ny(n){return n===rl?{}:n===Qi?[]:n}function k7(n,t){const e=n.viewQuery;n.viewQuery=e?(i,r)=>{t(i,r),e(i,r)}:t}function P7(n,t){const e=n.contentQueries;n.contentQueries=e?(i,r,s)=>{t(i,r,s),e(i,r,s)}:t}function z7(n,t){const e=n.hostBindings;n.hostBindings=e?(i,r)=>{t(i,r),e(i,r)}:t}function Pu(n,t){return!t||null===t.firstChild||oy(n)}function sg(n,t,e,i=!0){const r=t[Be];if(function r6(n,t,e,i){const r=mn+i,s=e.length;i>0&&(e[r-1][wa]=t),i{class n{static{this.__NG_ELEMENT_ID__=h9}}return n})();function h9(){return pO(pr(),Se())}const c9=An,uO=class extends c9{constructor(t,e,i){super(),this._lContainer=t,this._hostTNode=e,this._hostLView=i}get element(){return Lu(this._hostTNode,this._hostLView)}get injector(){return new Yn(this._hostTNode,this._hostLView)}get parentInjector(){const t=Qm(this._hostTNode,this._hostLView);if(h1(t)){const e=kp(t,this._hostLView),i=Op(t);return new Yn(e[Be].data[i+8],e)}return new Yn(null,this._hostLView)}clear(){for(;this.length>0;)this.remove(this.length-1)}get(t){const e=fO(this._lContainer);return null!==e&&e[t]||null}get length(){return this._lContainer.length-mn}createEmbeddedView(t,e,i){let r,s;"number"==typeof i?r=i:null!=i&&(r=i.index,s=i.injector);const a=t.createEmbeddedViewImpl(e||{},s,null);return this.insertImpl(a,r,Pu(this._hostTNode,null)),a}createComponent(t,e,i,r,s){const o=t&&!function Pp(n){return"function"==typeof n}(t);let a;if(o)a=e;else{const p=e||{};a=p.index,i=p.injector,r=p.projectableNodes,s=p.environmentInjector||p.ngModuleRef}const l=o?t:new Kp(di(t)),h=i||this.parentInjector;if(!s&&null==l.ngModule){const g=(o?h:this.parentInjector).get(ih,null);g&&(s=g)}di(l.componentType??{});const f=l.create(h,r,null,s);return this.insertImpl(f.hostView,a,Pu(this._hostTNode,null)),f}insert(t,e){return this.insertImpl(t,e,!0)}insertImpl(t,e,i){const r=t._lView;if(function hU(n){return Ps(n[vn])}(r)){const a=this.indexOf(t);if(-1!==a)this.detach(a);else{const l=r[vn],h=new uO(l,l[Os],l[vn]);h.detach(h.indexOf(t))}}const s=this._adjustIndex(e),o=this._lContainer;return sg(o,r,s,i),t.attachToViewContainerRef(),jA(_M(o),s,t),t}move(t,e){return this.insert(t,e)}indexOf(t){const e=fO(this._lContainer);return null!==e?e.indexOf(t):-1}remove(t){const e=this._adjustIndex(t,-1),i=_p(this._lContainer,e);i&&(Xm(_M(this._lContainer),e),cy(i[Be],i))}detach(t){const e=this._adjustIndex(t,-1),i=_p(this._lContainer,e);return i&&null!=Xm(_M(this._lContainer),e)?new Zp(i):null}_adjustIndex(t,e=0){return t??this.length+e}};function fO(n){return n[8]}function _M(n){return n[8]||(n[8]=[])}function pO(n,t){let e;const i=t[n.index];return Ps(i)?e=i:(e=function zN(n,t,e,i){return[n,!0,0,t,null,i,null,e,null,null]}(i,t,null,n),t[n.index]=e,Ty(t,e)),gO(e,t,n,i),new uO(e,n,t)}let gO=function mO(n,t,e,i){if(n[sl])return;let r;r=8&e.type?fr(i):function d9(n,t){const e=n[Yt],i=e.createComment(""),r=qs(t,n);return Zc(e,dy(e,r),i,function l6(n,t){return n.nextSibling(t)}(e,r),!1),i}(t,e),n[sl]=r};function nd(n,t,e){const i=Se();return function Ln(n,t,e){return!Object.is(n[t],e)&&(n[t]=e,!0)}(i,function hl(){return Rt.lFrame.bindingIndex++}(),t)&&function No(n,t,e,i,r,s,o,a){const l=qs(t,e);let c,h=t.inputs;!a&&null!=h&&(c=h[i])?(DM(n,e,c,i,r),Wc(t)&&function kV(n,t){const e=To(t,n);16&e[Ct]||(e[Ct]|=64)}(e,t.index)):3&t.type&&(i=function OV(n){return"class"===n?"className":"for"===n?"htmlFor":"formaction"===n?"formAction":"innerHtml"===n?"innerHTML":"readonly"===n?"readOnly":"tabindex"===n?"tabIndex":n}(i),r=null!=o?o(r,t.value||"",i):r,s.setProperty(l,i,r))}(Ti(),function zr(){const n=Rt.lFrame;return Tp(n.tView,n.selectedIndex)}(),i,n,t,i[Yt],e,!1),nd}function KM(n,t,e,i,r){const o=r?"class":"style";DM(n,e,t.inputs[o],o,i)}function oh(n,t,e,i){const r=Se(),s=Ti(),o=jt+n,a=r[Yt],l=s.firstCreatePass?function B8(n,t,e,i,r,s){const o=t.consts,l=Ou(t,n,2,i,al(o,r));return function MM(n,t,e,i){if(vA()){const r=null===i?null:{"":-1},s=function FV(n,t){const e=n.directiveRegistry;let i=null,r=null;if(e)for(let s=0;s(Jh(!0),hy(i,r,function xA(){return Rt.lFrame.currentNamespace}()));const Ju="en-US";let wk=Ju;function hw(n){return!!n&&"function"==typeof n.then}function Xk(n){return!!n&&"function"==typeof n.subscribe}function qy(n,t,e,i){const r=Se(),s=Ti(),o=pr();return function $k(n,t,e,i,r,s,o){const a=Hm(i),h=n.firstCreatePass&&BN(n),c=t[Er],d=HN(t);let u=!0;if(3&i.type||o){const g=qs(i,t),v=o?o(g):g,y=d.length,S=o?M=>o(fr(M[i.index])):i.index;let b=null;if(!o&&a&&(b=function UW(n,t,e,i){const r=n.cleanup;if(null!=r)for(let s=0;sl?a[l]:null}"string"==typeof o&&(s+=2)}return null}(n,t,r,i.index)),null!==b)(b.__ngLastListenerFn__||b).__ngNextListenerFn__=s,b.__ngLastListenerFn__=s,u=!1;else{s=Jk(i,t,c,s,!1);const M=e.listen(v,r,s);d.push(s,M),h&&h.push(r,S,y,y+1)}}else s=Jk(i,t,c,s,!1);const f=i.outputs;let p;if(u&&null!==f&&(p=f[r])){const g=p.length;if(g)for(let v=0;v-1?To(n.index,t):t);let l=Zk(t,e,i,o),h=s.__ngNextListenerFn__;for(;h;)l=Zk(t,e,h,o)&&l,h=h.__ngNextListenerFn__;return r&&!1===l&&o.preventDefault(),l}}function QW(){return this._results[Symbol.iterator]()}class dw{get changes(){return this._changes??=new Yo}constructor(t=!1){this._emitDistinctChangesOnly=t,this.dirty=!0,this._results=[],this._changesDetected=!1,this._changes=void 0,this.length=0,this.first=void 0,this.last=void 0;const e=dw.prototype;e[Symbol.iterator]||(e[Symbol.iterator]=QW)}get(t){return this._results[t]}map(t){return this._results.map(t)}filter(t){return this._results.filter(t)}find(t){return this._results.find(t)}reduce(t,e){return this._results.reduce(t,e)}forEach(t){this._results.forEach(t)}some(t){return this._results.some(t)}toArray(){return this._results.slice()}toString(){return this._results.toString()}reset(t,e){this.dirty=!1;const i=function lo(n){return n.flat(Number.POSITIVE_INFINITY)}(t);(this._changesDetected=!function $U(n,t,e){if(n.length!==t.length)return!1;for(let i=0;i{class n{static{this.__NG_ELEMENT_ID__=qW}}return n})();const GW=lh,XW=class extends GW{constructor(t,e,i){super(),this._declarationLView=t,this._declarationTContainer=e,this.elementRef=i}get ssrId(){return this._declarationTContainer.tView?.ssrId||null}createEmbeddedView(t,e){return this.createEmbeddedViewImpl(t,e)}createEmbeddedViewImpl(t,e,i){const r=function ng(n,t,e,i){const r=t.tView,a=xy(n,r,e,4096&n[Ct]?4096:16,null,t,null,null,null,i?.injector??null,i?.dehydratedView??null);a[Cp]=n[t.index];const h=n[nl];return null!==h&&(a[nl]=h.createEmbeddedView(r)),kM(r,a,e),a}(this._declarationLView,this._declarationTContainer,t,{injector:e,dehydratedView:i});return new Zp(r)}};function qW(){return $y(pr(),Se())}function $y(n,t){return 4&n.type?new XW(t,n,Lu(n,t)):null}class uw{constructor(t){this.queryList=t,this.matches=null}clone(){return new uw(this.queryList)}setDirty(){this.queryList.setDirty()}}class fw{constructor(t=[]){this.queries=t}createEmbeddedView(t){const e=t.queries;if(null!==e){const i=null!==t.contentQueries?t.contentQueries[0]:e.length,r=[];for(let s=0;s0)i.push(o[a/2]);else{const h=s[a+1],c=t[-l];for(let d=mn;d(Jh(!0),function ly(n,t){return n.createText(t)}(t[Yt],i));function yw(n,t,e,i,r){if(n=vt(n),Array.isArray(n))for(let s=0;s>20;if(qc(n)||!n.multi){const f=new Np(h,r,Ot),p=Iw(l,t,r?c:c+u,d);-1===p?(u1(Ym(a,o),s,l),Sw(s,n,t.length),t.push(l),a.directiveStart++,a.directiveEnd++,r&&(a.providerIndexes+=1048576),e.push(f),o.push(f)):(e[p]=f,o[p]=f)}else{const f=Iw(l,t,c+u,d),p=Iw(l,t,c,c+u),v=p>=0&&e[p];if(r&&!v||!r&&!(f>=0&&e[f])){u1(Ym(a,o),s,l);const y=function yY(n,t,e,i,r){const s=new Np(n,e,Ot);return s.multi=[],s.index=t,s.componentProviders=0,kP(s,r,i&&!e),s}(r?mY:vY,e.length,r,i,h);!r&&v&&(e[p].providerFactory=y),Sw(s,n,t.length,0),t.push(l),a.directiveStart++,a.directiveEnd++,r&&(a.providerIndexes+=1048576),e.push(y),o.push(y)}else Sw(s,n,f>-1?f:p,kP(e[r?p:f],h,!r&&i));!r&&i&&v&&e[p].componentProviders++}}}function Sw(n,t,e,i){const r=qc(t),s=function gj(n){return!!n.useClass}(t);if(r||s){const l=(s?vt(t.useClass):t).prototype.ngOnDestroy;if(l){const h=n.destroyHooks||(n.destroyHooks=[]);if(!r&&t.multi){const c=h.indexOf(e);-1===c?h.push(e,[i,l]):h[c+1].push(i,l)}else h.push(e,l)}}}function kP(n,t,e){return e&&n.componentProviders++,n.multi.push(t)-1}function Iw(n,t,e,i){for(let r=e;r{e.providersResolver=(i,r)=>function gY(n,t,e){const i=Ti();if(i.firstCreatePass){const r=Ea(n);yw(e,i.data,i.blueprint,r,!0),yw(t,i.data,i.blueprint,r,!1)}}(i,r?r(n):n,t)}}class od{}class zP extends od{constructor(t){super(),this.componentFactoryResolver=new KN(this),this.instance=null;const e=new Iu([...t.providers,{provide:od,useValue:this},{provide:wy,useValue:this.componentFactoryResolver}],t.parent||ty(),t.debugName,new Set(["environment"]));this.injector=e,t.runEnvironmentInitializers&&e.resolveInjectorInitializers()}destroy(){this.injector.destroy()}onDestroy(t){this.injector.onDestroy(t)}}let wY=(()=>{class n{constructor(e){this._injector=e,this.cachedInjectors=new Map}getOrCreateStandaloneInjector(e){if(!e.standalone)return null;if(!this.cachedInjectors.has(e)){const i=qA(0,e.type),r=i.length>0?function MY(n,t,e=null){return new zP({providers:n,parent:t,debugName:e,runEnvironmentInitializers:!0}).injector}([i],this._injector,`Standalone[${e.type.name}]`):null;this.cachedInjectors.set(e,r)}return this.cachedInjectors.get(e)}ngOnDestroy(){try{for(const e of this.cachedInjectors.values())null!==e&&e.destroy()}finally{this.cachedInjectors.clear()}}static{this.\u0275prov=Yi({token:n,providedIn:"environment",factory:()=>new n(_i(ih))})}}return n})();function RP(n){(function Kc(n){WN.has(n)||(WN.add(n),performance?.mark?.("mark_feature_usage",{detail:{feature:n}}))})("NgStandalone"),n.getStandaloneInjector=t=>t.get(wY).getOrCreateStandaloneInjector(n)}let Lw=(()=>{class n{constructor(){this.taskId=0,this.pendingTasks=new Set,this.hasPendingTasks=new _o(!1)}get _hasPendingTasks(){return this.hasPendingTasks.value}add(){this._hasPendingTasks||this.hasPendingTasks.next(!0);const e=this.taskId++;return this.pendingTasks.add(e),e}remove(e){this.pendingTasks.delete(e),0===this.pendingTasks.size&&this._hasPendingTasks&&this.hasPendingTasks.next(!1)}ngOnDestroy(){this.pendingTasks.clear(),this._hasPendingTasks&&this.hasPendingTasks.next(!1)}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();const g2=new Ht(""),XQ=new Ht("");let zw=(()=>{class n{constructor(){this.initialized=!1,this.done=!1,this.donePromise=new Promise((e,i)=>{this.resolve=e,this.reject=i}),this.appInits=Hi(XQ,{optional:!0})??[]}runInitializers(){if(this.initialized)return;const e=[];for(const r of this.appInits){const s=r();if(hw(s))e.push(s);else if(Xk(s)){const o=new Promise((a,l)=>{s.subscribe({complete:a,error:l})});e.push(o)}}const i=()=>{this.done=!0,this.resolve()};Promise.all(e).then(()=>{i()}).catch(r=>{this.reject(r)}),0===e.length&&i(),this.initialized=!0}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();const v2=new Ht("");let tf=(()=>{class n{constructor(){this._bootstrapListeners=[],this._runningTick=!1,this._destroyed=!1,this._destroyListeners=[],this._views=[],this.internalErrorHandler=Hi(IN),this.afterRenderEffectManager=Hi(Jp),this.componentTypes=[],this.components=[],this.isStable=Hi(Lw).hasPendingTasks.pipe(jr(e=>!e)),this._injector=Hi(ih)}get destroyed(){return this._destroyed}get injector(){return this._injector}bootstrap(e,i){const r=e instanceof nN;if(!this._injector.get(zw).done)throw!r&&function jc(n){const t=di(n)||Wn(n)||gs(n);return null!==t&&t.standalone}(e),new F(405,!1);let o;o=r?e:this._injector.get(wy).resolveComponentFactory(e),this.componentTypes.push(o.componentType);const a=function $Q(n){return n.isBoundToModule}(o)?void 0:this._injector.get(od),h=o.create(Wo.NULL,[],i||o.selector,a),c=h.location.nativeElement,d=h.injector.get(g2,null);return d?.registerApplication(c),h.onDestroy(()=>{this.detachView(h.hostView),r0(this.components,h),d?.unregisterApplication(c)}),this._loadComponent(h),h}tick(){if(this._runningTick)throw new F(101,!1);try{this._runningTick=!0;for(let e of this._views)e.detectChanges()}catch(e){this.internalErrorHandler(e)}finally{try{this.afterRenderEffectManager.execute()}catch(e){this.internalErrorHandler(e)}this._runningTick=!1}}attachView(e){const i=e;this._views.push(i),i.attachToAppRef(this)}detachView(e){const i=e;r0(this._views,i),i.detachFromAppRef()}_loadComponent(e){this.attachView(e.hostView),this.tick(),this.components.push(e);const i=this._injector.get(v2,[]);[...this._bootstrapListeners,...i].forEach(r=>r(e))}ngOnDestroy(){if(!this._destroyed)try{this._destroyListeners.forEach(e=>e()),this._views.slice().forEach(e=>e.destroy())}finally{this._destroyed=!0,this._views=[],this._bootstrapListeners=[],this._destroyListeners=[]}}onDestroy(e){return this._destroyListeners.push(e),()=>r0(this._destroyListeners,e)}destroy(){if(this._destroyed)throw new F(406,!1);const e=this._injector;e.destroy&&!e.destroyed&&e.destroy()}get viewCount(){return this._views.length}warnIfDestroyed(){}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();function r0(n,t){const e=n.indexOf(t);e>-1&&n.splice(e,1)}let JQ=(()=>{class n{constructor(){this.zone=Hi(Rr),this.applicationRef=Hi(tf)}initialize(){this._onMicrotaskEmptySubscription||(this._onMicrotaskEmptySubscription=this.zone.onMicrotaskEmpty.subscribe({next:()=>{this.zone.run(()=>{this.applicationRef.tick()})}}))}ngOnDestroy(){this._onMicrotaskEmptySubscription?.unsubscribe()}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();function b2(n){return[{provide:Rr,useFactory:n},{provide:Su,multi:!0,useFactory:()=>{const t=Hi(JQ,{optional:!0});return()=>t.initialize()}},{provide:Su,multi:!0,useFactory:()=>{const t=Hi(tG);return()=>{t.initialize()}}},{provide:IN,useFactory:KQ}]}function KQ(){const n=Hi(Rr),t=Hi(nh);return e=>n.runOutsideAngular(()=>t.handleError(e))}function eG(n){return function w1(n){return{\u0275providers:n}}([[],b2(()=>new Rr(function M2(n){return{enableLongStackTrace:!1,shouldCoalesceEventChangeDetection:n?.eventCoalescing??!1,shouldCoalesceRunChangeDetection:n?.runCoalescing??!1}}(n)))])}let tG=(()=>{class n{constructor(){this.subscription=new As,this.initialized=!1,this.zone=Hi(Rr),this.pendingTasks=Hi(Lw)}initialize(){if(this.initialized)return;this.initialized=!0;let e=null;!this.zone.isStable&&!this.zone.hasPendingMacrotasks&&!this.zone.hasPendingMicrotasks&&(e=this.pendingTasks.add()),this.zone.runOutsideAngular(()=>{this.subscription.add(this.zone.onStable.subscribe(()=>{Rr.assertNotInAngularZone(),queueMicrotask(()=>{null!==e&&!this.zone.hasPendingMacrotasks&&!this.zone.hasPendingMicrotasks&&(this.pendingTasks.remove(e),e=null)})}))}),this.subscription.add(this.zone.onUnstable.subscribe(()=>{Rr.assertInAngularZone(),e??=this.pendingTasks.add()}))}ngOnDestroy(){this.subscription.unsubscribe()}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();const hh=new Ht("",{providedIn:"root",factory:()=>Hi(hh,xi.Optional|xi.SkipSelf)||function iG(){return typeof $localize<"u"&&$localize.locale||Ju}()}),Rw=new Ht("");let oc=null;function DG(n){try{const{rootComponent:t,appProviders:e,platformProviders:i}=n,r=function aG(n=[]){if(oc)return oc;const t=function E2(n=[],t){return Wo.create({name:t,providers:[{provide:D1,useValue:"platform"},{provide:Rw,useValue:new Set([()=>oc=null])},...n]})}(n);return oc=t,function m2(){!function Cb(n){Zd=n}(()=>{throw new F(600,!1)})}(),function D2(n){n.get(oL,null)?.forEach(e=>e())}(t),t}(i),s=[eG(),...e||[]],a=new zP({providers:s,parent:r,debugName:"",runEnvironmentInitializers:!1}).injector,l=a.get(Rr);return l.run(()=>{a.resolveInjectorInitializers();const h=a.get(nh,null);let c;l.runOutsideAngular(()=>{c=l.onError.subscribe({next:f=>{h.handleError(f)}})});const d=()=>a.destroy(),u=r.get(Rw);return u.add(d),a.onDestroy(()=>{c.unsubscribe(),u.delete(d)}),function y2(n,t,e){try{const i=e();return hw(i)?i.catch(r=>{throw t.runOutsideAngular(()=>n.handleError(r)),r}):i}catch(i){throw t.runOutsideAngular(()=>n.handleError(i)),i}}(h,l,()=>{const f=a.get(zw);return f.runInitializers(),f.donePromise.then(()=>{!function Ck(n){so(n,"Expected localeId to be defined"),"string"==typeof n&&(wk=n.toLowerCase().replace(/_/g,"-"))}(a.get(hh,Ju)||Ju);const g=a.get(tf);return void 0!==t&&g.bootstrap(t),g})})})}catch(t){return Promise.reject(t)}}let $2=null;function Ww(){return $2}class UG{}const ld=new Ht("");let sq=(()=>{class n{static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275mod=km({type:n})}static{this.\u0275inj=Sp({})}}return n})();function uz(n){return"server"===n}class kq extends UG{constructor(){super(...arguments),this.supportsDOMEvents=!0}}class aC extends kq{static makeCurrent(){!function _G(n){$2??=n}(new aC)}onAndCancel(t,e,i){return t.addEventListener(e,i),()=>{t.removeEventListener(e,i)}}dispatchEvent(t,e){t.dispatchEvent(e)}remove(t){t.parentNode&&t.parentNode.removeChild(t)}createElement(t,e){return(e=e||this.getDefaultDocument()).createElement(t)}createHtmlDocument(){return document.implementation.createHTMLDocument("fakeTitle")}getDefaultDocument(){return document}isElementNode(t){return t.nodeType===Node.ELEMENT_NODE}isShadowRoot(t){return t instanceof DocumentFragment}getGlobalEventTarget(t,e){return"window"===e?window:"document"===e?t:"body"===e?t.body:null}getBaseHref(t){const e=function Pq(){return Dg=Dg||document.querySelector("base"),Dg?Dg.getAttribute("href"):null}();return null==e?null:function zq(n){return new URL(n,document.baseURI).pathname}(e)}resetBaseElement(){Dg=null}getUserAgent(){return window.navigator.userAgent}getCookie(t){return function xX(n,t){t=encodeURIComponent(t);for(const e of n.split(";")){const i=e.indexOf("="),[r,s]=-1==i?[e,""]:[e.slice(0,i),e.slice(i+1)];if(r.trim()===t)return decodeURIComponent(s)}return null}(document.cookie,t)}}let Dg=null,Hq=(()=>{class n{build(){return new XMLHttpRequest}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();const lC=new Ht("");let vz=(()=>{class n{constructor(e,i){this._zone=i,this._eventNameToPlugin=new Map,e.forEach(r=>{r.manager=this}),this._plugins=e.slice().reverse()}addEventListener(e,i,r){return this._findPluginFor(i).addEventListener(e,i,r)}getZone(){return this._zone}_findPluginFor(e){let i=this._eventNameToPlugin.get(e);if(i)return i;if(i=this._plugins.find(s=>s.supports(e)),!i)throw new F(5101,!1);return this._eventNameToPlugin.set(e,i),i}static{this.\u0275fac=function(i){return new(i||n)(_i(lC),_i(Rr))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();class mz{constructor(t){this._doc=t}}const hC="ng-app-id";let yz=(()=>{class n{constructor(e,i,r,s={}){this.doc=e,this.appId=i,this.nonce=r,this.platformId=s,this.styleRef=new Map,this.hostNodes=new Set,this.styleNodesInDOM=this.collectServerRenderedStyles(),this.platformIsServer=uz(s),this.resetHostNodes()}addStyles(e){for(const i of e)1===this.changeUsageCount(i,1)&&this.onStyleAdded(i)}removeStyles(e){for(const i of e)this.changeUsageCount(i,-1)<=0&&this.onStyleRemoved(i)}ngOnDestroy(){const e=this.styleNodesInDOM;e&&(e.forEach(i=>i.remove()),e.clear());for(const i of this.getAllStyles())this.onStyleRemoved(i);this.resetHostNodes()}addHost(e){this.hostNodes.add(e);for(const i of this.getAllStyles())this.addStyleToHost(e,i)}removeHost(e){this.hostNodes.delete(e)}getAllStyles(){return this.styleRef.keys()}onStyleAdded(e){for(const i of this.hostNodes)this.addStyleToHost(i,e)}onStyleRemoved(e){const i=this.styleRef;i.get(e)?.elements?.forEach(r=>r.remove()),i.delete(e)}collectServerRenderedStyles(){const e=this.doc.head?.querySelectorAll(`style[${hC}="${this.appId}"]`);if(e?.length){const i=new Map;return e.forEach(r=>{null!=r.textContent&&i.set(r.textContent,r)}),i}return null}changeUsageCount(e,i){const r=this.styleRef;if(r.has(e)){const s=r.get(e);return s.usage+=i,s.usage}return r.set(e,{usage:i,elements:[]}),i}getStyleElement(e,i){const r=this.styleNodesInDOM,s=r?.get(i);if(s?.parentNode===e)return r.delete(i),s.removeAttribute(hC),s;{const o=this.doc.createElement("style");return this.nonce&&o.setAttribute("nonce",this.nonce),o.textContent=i,this.platformIsServer&&o.setAttribute(hC,this.appId),e.appendChild(o),o}}addStyleToHost(e,i){const r=this.getStyleElement(e,i),s=this.styleRef,o=s.get(i)?.elements;o?o.push(r):s.set(i,{elements:[r],usage:1})}resetHostNodes(){const e=this.hostNodes;e.clear(),e.add(this.doc.head)}static{this.\u0275fac=function(i){return new(i||n)(_i(ld),_i(k1),_i(aL,8),_i(Mu))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();const cC={svg:"http://www.w3.org/2000/svg",xhtml:"http://www.w3.org/1999/xhtml",xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/",math:"http://www.w3.org/1998/MathML/"},dC=/%COMP%/g,Uq=new Ht("",{providedIn:"root",factory:()=>!0});function Iz(n,t){return t.map(e=>e.replace(dC,n))}let bz=(()=>{class n{constructor(e,i,r,s,o,a,l,h=null){this.eventManager=e,this.sharedStylesHost=i,this.appId=r,this.removeStylesOnCompDestroy=s,this.doc=o,this.platformId=a,this.ngZone=l,this.nonce=h,this.rendererByCompId=new Map,this.platformIsServer=uz(a),this.defaultRenderer=new uC(e,o,l,this.platformIsServer)}createRenderer(e,i){if(!e||!i)return this.defaultRenderer;this.platformIsServer&&i.encapsulation===ba.ShadowDom&&(i={...i,encapsulation:ba.Emulated});const r=this.getOrCreateRenderer(e,i);return r instanceof wz?r.applyToHost(e):r instanceof fC&&r.applyStyles(),r}getOrCreateRenderer(e,i){const r=this.rendererByCompId;let s=r.get(i.id);if(!s){const o=this.doc,a=this.ngZone,l=this.eventManager,h=this.sharedStylesHost,c=this.removeStylesOnCompDestroy,d=this.platformIsServer;switch(i.encapsulation){case ba.Emulated:s=new wz(l,h,i,this.appId,c,o,a,d);break;case ba.ShadowDom:return new Yq(l,h,e,i,o,a,this.nonce,d);default:s=new fC(l,h,i,c,o,a,d)}r.set(i.id,s)}return s}ngOnDestroy(){this.rendererByCompId.clear()}static{this.\u0275fac=function(i){return new(i||n)(_i(vz),_i(yz),_i(k1),_i(Uq),_i(ld),_i(Mu),_i(Rr),_i(aL))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();class uC{constructor(t,e,i,r){this.eventManager=t,this.doc=e,this.ngZone=i,this.platformIsServer=r,this.data=Object.create(null),this.throwOnSyntheticProps=!0,this.destroyNode=null}destroy(){}createElement(t,e){return e?this.doc.createElementNS(cC[e]||e,t):this.doc.createElement(t)}createComment(t){return this.doc.createComment(t)}createText(t){return this.doc.createTextNode(t)}appendChild(t,e){(Mz(t)?t.content:t).appendChild(e)}insertBefore(t,e,i){t&&(Mz(t)?t.content:t).insertBefore(e,i)}removeChild(t,e){t&&t.removeChild(e)}selectRootElement(t,e){let i="string"==typeof t?this.doc.querySelector(t):t;if(!i)throw new F(-5104,!1);return e||(i.textContent=""),i}parentNode(t){return t.parentNode}nextSibling(t){return t.nextSibling}setAttribute(t,e,i,r){if(r){e=r+":"+e;const s=cC[r];s?t.setAttributeNS(s,e,i):t.setAttribute(e,i)}else t.setAttribute(e,i)}removeAttribute(t,e,i){if(i){const r=cC[i];r?t.removeAttributeNS(r,e):t.removeAttribute(`${i}:${e}`)}else t.removeAttribute(e)}addClass(t,e){t.classList.add(e)}removeClass(t,e){t.classList.remove(e)}setStyle(t,e,i,r){r&(ic.DashCase|ic.Important)?t.style.setProperty(e,i,r&ic.Important?"important":""):t.style[e]=i}removeStyle(t,e,i){i&ic.DashCase?t.style.removeProperty(e):t.style[e]=""}setProperty(t,e,i){null!=t&&(t[e]=i)}setValue(t,e){t.nodeValue=e}listen(t,e,i){if("string"==typeof t&&!(t=Ww().getGlobalEventTarget(this.doc,t)))throw new Error(`Unsupported event target ${t} for event ${e}`);return this.eventManager.addEventListener(t,e,this.decoratePreventDefault(i))}decoratePreventDefault(t){return e=>{if("__ngUnwrap__"===e)return t;!1===(this.platformIsServer?this.ngZone.runGuarded(()=>t(e)):t(e))&&e.preventDefault()}}}function Mz(n){return"TEMPLATE"===n.tagName&&void 0!==n.content}class Yq extends uC{constructor(t,e,i,r,s,o,a,l){super(t,s,o,l),this.sharedStylesHost=e,this.hostEl=i,this.shadowRoot=i.attachShadow({mode:"open"}),this.sharedStylesHost.addHost(this.shadowRoot);const h=Iz(r.id,r.styles);for(const c of h){const d=document.createElement("style");a&&d.setAttribute("nonce",a),d.textContent=c,this.shadowRoot.appendChild(d)}}nodeOrShadowRoot(t){return t===this.hostEl?this.shadowRoot:t}appendChild(t,e){return super.appendChild(this.nodeOrShadowRoot(t),e)}insertBefore(t,e,i){return super.insertBefore(this.nodeOrShadowRoot(t),e,i)}removeChild(t,e){return super.removeChild(this.nodeOrShadowRoot(t),e)}parentNode(t){return this.nodeOrShadowRoot(super.parentNode(this.nodeOrShadowRoot(t)))}destroy(){this.sharedStylesHost.removeHost(this.shadowRoot)}}class fC extends uC{constructor(t,e,i,r,s,o,a,l){super(t,s,o,a),this.sharedStylesHost=e,this.removeStylesOnCompDestroy=r,this.styles=l?Iz(l,i.styles):i.styles}applyStyles(){this.sharedStylesHost.addStyles(this.styles)}destroy(){this.removeStylesOnCompDestroy&&this.sharedStylesHost.removeStyles(this.styles)}}class wz extends fC{constructor(t,e,i,r,s,o,a,l){const h=r+"-"+i.id;super(t,e,i,s,o,a,l,h),this.contentAttr=function jq(n){return"_ngcontent-%COMP%".replace(dC,n)}(h),this.hostAttr=function Vq(n){return"_nghost-%COMP%".replace(dC,n)}(h)}applyToHost(t){this.applyStyles(),this.setAttribute(t,this.hostAttr,"")}createElement(t,e){const i=super.createElement(t,e);return super.setAttribute(i,this.contentAttr,""),i}}let Qq=(()=>{class n extends mz{constructor(e){super(e)}supports(e){return!0}addEventListener(e,i,r){return e.addEventListener(i,r,!1),()=>this.removeEventListener(e,i,r)}removeEventListener(e,i,r){return e.removeEventListener(i,r)}static{this.\u0275fac=function(i){return new(i||n)(_i(ld))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();const Cz=["alt","control","meta","shift"],Gq={"\b":"Backspace","\t":"Tab","\x7f":"Delete","\x1b":"Escape",Del:"Delete",Esc:"Escape",Left:"ArrowLeft",Right:"ArrowRight",Up:"ArrowUp",Down:"ArrowDown",Menu:"ContextMenu",Scroll:"ScrollLock",Win:"OS"},Xq={alt:n=>n.altKey,control:n=>n.ctrlKey,meta:n=>n.metaKey,shift:n=>n.shiftKey};let qq=(()=>{class n extends mz{constructor(e){super(e)}supports(e){return null!=n.parseEventName(e)}addEventListener(e,i,r){const s=n.parseEventName(i),o=n.eventCallback(s.fullKey,r,this.manager.getZone());return this.manager.getZone().runOutsideAngular(()=>Ww().onAndCancel(e,s.domEventName,o))}static parseEventName(e){const i=e.toLowerCase().split("."),r=i.shift();if(0===i.length||"keydown"!==r&&"keyup"!==r)return null;const s=n._normalizeKey(i.pop());let o="",a=i.indexOf("code");if(a>-1&&(i.splice(a,1),o="code."),Cz.forEach(h=>{const c=i.indexOf(h);c>-1&&(i.splice(c,1),o+=h+".")}),o+=s,0!=i.length||0===s.length)return null;const l={};return l.domEventName=r,l.fullKey=o,l}static matchEventFullKeyCode(e,i){let r=Gq[e.key]||e.key,s="";return i.indexOf("code.")>-1&&(r=e.code,s="code."),!(null==r||!r)&&(r=r.toLowerCase()," "===r?r="space":"."===r&&(r="dot"),Cz.forEach(o=>{o!==r&&(0,Xq[o])(e)&&(s+=o+".")}),s+=r,s===i)}static eventCallback(e,i,r){return s=>{n.matchEventFullKeyCode(s,e)&&r.runGuarded(()=>i(s))}}static _normalizeKey(e){return"esc"===e?"escape":e}static{this.\u0275fac=function(i){return new(i||n)(_i(ld))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();function Ez(n){return{appProviders:[...i$,...n?.providers??[]],platformProviders:e$}}const e$=[{provide:Mu,useValue:"browser"},{provide:oL,useValue:function Zq(){aC.makeCurrent()},multi:!0},{provide:ld,useFactory:function Kq(){return function Aj(n){O1=n}(document),document},deps:[]}],i$=[{provide:D1,useValue:"root"},{provide:nh,useFactory:function Jq(){return new nh},deps:[]},{provide:lC,useClass:Qq,multi:!0,deps:[ld,Rr,Mu]},{provide:lC,useClass:qq,multi:!0,deps:[ld]},bz,yz,vz,{provide:oN,useExisting:bz},{provide:class cq{},useClass:Hq,deps:[]},[]];var o$=0,pC=!1;function E0(n,t){var e=t;return e.unshift(void 0),new(Function.prototype.bind.apply(n,e))}function Y(n,t){for(var e=t,i=n.replace(/\[/g,".").replace(/\]/g,"").split("."),r=0;r"u"}function Ei(n){return n+"_"+o$++}function x0(n,t){return n===t||!(n===document||!n)&&x0(n.parentNode,t)}function Ag(n){try{throw new Error(n)}catch(t){throw new Error(t.message+"\n"+t.stack)}}function Re(n){var t=n+"";return t.match(/auto|cm|mm|in|px|pt|pc|%|em|ex|ch|rem|vw|vh|vmin|vmax/)?t:t+"px"}function ce(){return pC}var Lg,n,t,d$={latn:{_digits:"0123456789",_type:"numeric"}},Lz={decimal:".",group:",",percentSign:"%",plusSign:"+",minusSign:"-",infinity:"\u221e",nan:"NaN",exponential:"E"},Nz=[0,1,2,3,4,5,6,7,8,9],Hr=function(){function n(){}return n.getMainObject=function(t,e){return Y(ce()?e:"main."+e,t)},n.getNumberingSystem=function(t){return Y("supplemental.numberingSystems",t)||this.numberingSystems},n.reverseObject=function(t,e){for(var r={},s=0,o=e||Object.keys(t);s13&&(p+=1,o-=12),o-=1,a=p-4716;var y=u-24e5,S=10631/30,b=u-1948084,M=Math.floor(b/10631);b-=10631*M;var w=Math.floor((b-.1335)/S),C=30*M+w;b-=Math.floor(w*S+.1335);var D=Math.floor((b+28.5001)/29.5);13===D&&(D=12);for(var A=b-Math.floor(29.5001*D-29),x=0;xy);x++);var P=x+16260,L=Math.floor((P-1)/12),O=L+1,N=P-12*L,T=y-t[x-1]+1;return(T+"").length>2&&(T=A,N=D,O=C),{year:O,month:N,date:T}},n.toGregorian=function i(r,s,o){var g=Math.floor(o+t[12*(r-1)+1+(s-1)-16260-1]-1+24e5+.5),v=Math.floor((g-1867216.25)/36524.25),y=1524+(v=g+1+v-Math.floor(v/4)),S=Math.floor((y-122.1)/365.25),b=Math.floor(365.25*S),M=Math.floor((y-b)/30.6001),w=y-b-Math.floor(30.6001*M),C=M-(M>13.5?13:1),D=S-(C>2.5?4716:4715);return D<=0&&C--,new Date(D+"/"+C+"/"+w)};var ut,p$=/\/MMMMM|MMMM|MMM|a|LLLL|LLL|EEEEE|EEEE|E|K|cccc|ccc|WW|W|G+|z+/gi,Oz="stand-alone",g$=["sun","mon","tue","wed","thu","fri","sat"],kz={m:"getMinutes",h:"getHours",H:"getHours",s:"getSeconds",d:"getDate",f:"getMilliseconds"},Pz=function(){function n(){}return n.dateFormat=function(t,e,i){var r=this,s=ut.getDependables(i,t,e.calendar),o=Y("parserObject.numbers",s),a=s.dateObject,l={isIslamic:ut.islamicRegex.test(e.calendar)};ce()&&e.isServerRendered&&(e=ut.compareBlazorDateFormats(e,t));var h=e.format||ut.getResultantPattern(e.skeleton,s.dateObject,e.type,!1,ce()?t:"");if(l.dateSeperator=ce()?Y("dateSeperator",a):ut.getDateSeparator(s.dateObject),st(h))Ag("Format options or type given must be invalid");else{h=ut.ConvertDateToWeekFormat(h),ce()&&(h=h.replace(/tt/,"a")),l.pattern=h,l.numMapper=ce()?ze({},o):Hr.getNumberMapper(s.parserObject,Hr.getNumberingSystem(i));for(var d=0,u=h.match(p$)||[];d2?r+=e.month[""+u]:p=!0;break;case"E":case"c":r+=e.weekday[""+g$[t.getDay()]];break;case"H":case"h":case"m":case"s":case"d":case"f":if(p=!0,"d"===d)u=o.date;else if("f"===d){p=!1,g=!0;var y=(f=(f=t[""+kz[""+d]]().toString()).substring(0,c)).length;if(c!==y){if(c>3)continue;for(var S=0;S0?1:0],o=Math.abs(t);return s.replace(/HH?|mm/g,function(a){var l=a.length,h=-1!==a.indexOf("H");return i.checkTwodigitNumber(Math.floor(h?o/60:o%60),l)})},n}(),zz={ms:"minimumSignificantDigits",ls:"maximumSignificantDigits",mf:"minimumFractionDigits",lf:"maximumFractionDigits"},of=["infinity","nan","group","decimal","exponential"],Rz=function(){function n(){}return n.numberFormatter=function(t,e,i){var l,r=this,s=ze({},e),o={},a={},h=ut.getDependables(i,t,"",!0),c=h.numericObject;a.numberMapper=ce()?ze({},c):Hr.getNumberMapper(h.parserObject,Hr.getNumberingSystem(i),!0),a.currencySymbol=ce()?Y("currencySymbol",c):ut.getCurrencySymbol(h.numericObject,s.currency||kg,e.altSymbol,e.ignoreCurrency),a.percentSymbol=ce()?Y("numberSymbols.percentSign",c):a.numberMapper.numberSymbols.percentSign,a.minusSymbol=ce()?Y("numberSymbols.minusSign",c):a.numberMapper.numberSymbols.minusSign;var d=a.numberMapper.numberSymbols;if(e.format&&!ut.formatRegex.test(e.format))o=ut.customFormat(e.format,a,h.numericObject),!st(s.useGrouping)&&s.useGrouping&&(s.useGrouping=o.pData.useGrouping);else{if(ze(s,ut.getProperNumericSkeleton(e.format||"N")),s.isCurrency="currency"===s.type,s.isPercent="percent"===s.type,ce()||(l=ut.getSymbolPattern(s.type,a.numberMapper.numberSystem,h.numericObject,s.isAccount)),s.groupOne=this.checkValueRange(s.maximumSignificantDigits,s.minimumSignificantDigits,!0),this.checkValueRange(s.maximumFractionDigits,s.minimumFractionDigits,!1,!0),st(s.fractionDigits)||(s.minimumFractionDigits=s.maximumFractionDigits=s.fractionDigits),st(s.useGrouping)&&(s.useGrouping=!0),s.isCurrency&&!ce()&&(l=l.replace(/\u00A4/g,ut.defaultCurrency)),ce())o.nData=ze({},{},Y(s.type+"nData",c)),o.pData=ze({},{},Y(s.type+"pData",c)),"currency"===s.type&&e.currency&&ut.replaceBlazorCurrency([o.pData,o.nData],a.currencySymbol,e.currency);else{var u=l.split(";");o.nData=ut.getFormatData(u[1]||"-"+u[0],!0,a.currencySymbol),o.pData=ut.getFormatData(u[0],!1,a.currencySymbol),s.useGrouping&&(s.groupSeparator=d[of[2]],s.groupData=this.getGroupingDetails(u[0]))}if(st(s.minimumFractionDigits)&&(s.minimumFractionDigits=o.nData.minimumFraction),st(s.maximumFractionDigits)){var p=o.nData.maximumFraction;s.maximumFractionDigits=st(p)&&s.isPercent?0:p}var g=s.minimumFractionDigits,v=s.maximumFractionDigits;!st(g)&&!st(v)&&g>v&&(s.maximumFractionDigits=g)}return ze(o.nData,s),ze(o.pData,s),function(y){return isNaN(y)?d[of[1]]:isFinite(y)?r.intNumberFormatter(y,o,a,e):d[of[0]]}},n.getGroupingDetails=function(t){var e={},i=t.match(ut.negativeDataRegex);if(i&&i[4]){var r=i[4],s=r.lastIndexOf(",");if(-1!==s){var o=r.split(".")[0];e.primary=o.length-s-1;var a=r.lastIndexOf(",",s-1);-1!==a&&(e.secondary=s-1-a)}}return e},n.checkValueRange=function(t,e,i,r){var s=r?"f":"s",o=0,a=zz["l"+s],l=zz["m"+s];if(st(t)||(this.checkRange(t,a,r),o++),st(e)||(this.checkRange(e,l,r),o++),2===o){if(!(tr[1])&&Ag(e+"value must be within the range"+r[0]+"to"+r[1])},n.intNumberFormatter=function(t,e,i,r){var s;if(!st(e.nData.type)){t<0?(t*=-1,s=e.nData):s=0===t&&e.zeroData||e.pData;var o="";if(s.isPercent&&(t*=100),s.groupOne)o=this.processSignificantDigits(t,s.minimumSignificantDigits,s.maximumSignificantDigits);else if(o=this.processFraction(t,s.minimumFractionDigits,s.maximumFractionDigits,r),s.minimumIntegerDigits&&(o=this.processMinimumIntegers(o,s.minimumIntegerDigits)),i.isCustomFormat&&s.minimumFractionDigits=0&&"0"===l[parseInt(c.toString(),10)]&&c>=s.minimumFractionDigits;c--)l=l.slice(0,c);o=a[0]+"."+l}return"scientific"===s.type&&(o=(o=t.toExponential(s.maximumFractionDigits)).replace("e",i.numberMapper.numberSymbols[of[4]])),o=o.replace(".",i.numberMapper.numberSymbols[of[3]]),o="#,###,,;(#,###,,)"===s.format?this.customPivotFormat(parseInt(o,10)):o,s.useGrouping&&(o=this.groupNumbers(o,s.groupData.primary,s.groupSeparator||",",i.numberMapper.numberSymbols[of[3]]||".",s.groupData.secondary)),o=Hr.convertValueParts(o,ut.latnParseRegex,i.numberMapper.mapper),"N/A"===s.nlead?s.nlead:"0"===o&&r&&"0"===r.format?o+s.nend:s.nlead+o+s.nend}},n.processSignificantDigits=function(t,e,i){var r=t+"";return r.lengthe;)c=l.slice(h-e,h)+(c.length?i+c:""),h-=e,o&&(e=s,o=!1);return a[0]=l.slice(0,h)+(c.length?i:"")+c,a.join(r)},n.processFraction=function(t,e,i,r){var s=(t+"").split(".")[1],o=s?s.length:0;if(e&&oi||0===i))return t.toFixed(i);var h=t+"";return"0"===h[0]&&r&&"###.00"===r.format&&(h=h.slice(1)),h},n.processMinimumIntegers=function(t,e){var i=t.split("."),r=i[0],s=r.length;if(s=5e5){var r=(t/=1e6).toString().split(".")[1];return r&&+r.substring(0,1)>=5?Math.ceil(t).toString():Math.floor(t).toString()}return""},n}(),Ng=(new RegExp("^([^0-9]*)(([0-9,]*[0-9]+)(.[0-9]+)?)([Ee][+-]?[0-9]+)?([^0-9]*)$"),function(){function n(t){this.ranArray=[],this.boundedEvents={},!m(t)&&(this.context=t)}return n.prototype.on=function(t,e,i,r){if(!m(e)){var s=i||this.context;if(this.notExist(t))return void(this.boundedEvents[""+t]=[{handler:e,context:s,id:r}]);m(r)?this.isHandlerPresent(this.boundedEvents[""+t],e)||this.boundedEvents[""+t].push({handler:e,context:s}):-1===this.ranArray.indexOf(r)&&(this.ranArray.push(r),this.boundedEvents[""+t].push({handler:e,context:s,id:r}))}},n.prototype.off=function(t,e,i){if(!this.notExist(t)){var r=Y(t,this.boundedEvents);if(e){for(var s=0;s1&&(U.fractionDigits=parseInt(z[2],10)),U}function p(T,z,U,B){var j=B?{}:{nlead:"",nend:""},Q=T.match(n.customRegex);if(Q){B||(j.nlead=g(Q[1],U),j.nend=g(Q[10],U),j.groupPattern=Q[4]);var oe=Q[7];if(oe&&z){var ue=oe.match(t);j.minimumFraction=m(ue)?0:ue.length,j.maximumFraction=oe.length-1}}return j}function g(T,z){return T?(T=T.replace(n.defaultCurrency,z),""===z?T.trim():T):""}function v(T,z,U,B){return B?"$":Y("currencies."+z+(U?"."+U:".symbol"),T)||Y("currencies."+z+".symbol-alt-narrow",T)||"$"}function S(T,z,U){var B={type:"decimal",minimumFractionDigits:0,maximumFractionDigits:0},j=T.match(n.customRegex);if(m(j)||""===j[5]&&"N/A"!==T)return B.type=void 0,B;B.nlead=j[1],B.nend=j[10];var Q=j[6],oe=!!Q.match(/ $/g),ue=-1!==Q.replace(/ $/g,"").indexOf(" ");B.useGrouping=-1!==Q.indexOf(",")||ue,Q=Q.replace(/,/g,"");var fe=j[7];if(-1!==Q.indexOf("0")&&(B.minimumIntegerDigits=Q.length-Q.indexOf("0")),m(fe)||(B.minimumFractionDigits=fe.lastIndexOf("0"),B.maximumFractionDigits=fe.lastIndexOf("#"),-1===B.minimumFractionDigits&&(B.minimumFractionDigits=0),(-1===B.maximumFractionDigits||B.maximumFractionDigitsQ.lastIndexOf("'"))){B[""+a[parseInt(j.toString(),10)]]=Q.substr(0,oe)+U+Q.substr(oe+1),B[""+a[""+z]]=!0,B.type=B.isCurrency?"currency":"percent";break}}return B}function C(T,z){if(-1!==T.indexOf(",")){var U=T.split(",");T=U[0]+Y("numberMapper.numberSymbols.group",z)+U[1].replace(".",Y("numberMapper.numberSymbols.decimal",z))}else T=T.replace(".",Y("numberMapper.numberSymbols.decimal",z));return T}function A(T,z,U){T+=".";for(var B=0;B0;Q-=3)T=","+U[Q-2]+U[Q-1]+U[parseInt(Q.toString(),10)]+T;return T=T.slice(1),z[1]?T+"."+z[1]:T}n.dateParseRegex=/([a-z])\1*|'([^']|'')+'|''|./gi,n.basicPatterns=["short","medium","long","full"],n.defaultObject={dates:{calendars:{gregorian:{months:{"stand-alone":{abbreviated:{1:"Jan",2:"Feb",3:"Mar",4:"Apr",5:"May",6:"Jun",7:"Jul",8:"Aug",9:"Sep",10:"Oct",11:"Nov",12:"Dec"},narrow:{1:"J",2:"F",3:"M",4:"A",5:"M",6:"J",7:"J",8:"A",9:"S",10:"O",11:"N",12:"D"},wide:{1:"January",2:"February",3:"March",4:"April",5:"May",6:"June",7:"July",8:"August",9:"September",10:"October",11:"November",12:"December"}}},days:{"stand-alone":{abbreviated:{sun:"Sun",mon:"Mon",tue:"Tue",wed:"Wed",thu:"Thu",fri:"Fri",sat:"Sat"},narrow:{sun:"S",mon:"M",tue:"T",wed:"W",thu:"T",fri:"F",sat:"S"},short:{sun:"Su",mon:"Mo",tue:"Tu",wed:"We",thu:"Th",fri:"Fr",sat:"Sa"},wide:{sun:"Sunday",mon:"Monday",tue:"Tuesday",wed:"Wednesday",thu:"Thursday",fri:"Friday",sat:"Saturday"}}},dayPeriods:{format:{wide:{am:"AM",pm:"PM"}}},eras:{eraNames:{0:"Before Christ","0-alt-variant":"Before Common Era",1:"Anno Domini","1-alt-variant":"Common Era"},eraAbbr:{0:"BC","0-alt-variant":"BCE",1:"AD","1-alt-variant":"CE"},eraNarrow:{0:"B","0-alt-variant":"BCE",1:"A","1-alt-variant":"CE"}},dateFormats:{full:"EEEE, MMMM d, y",long:"MMMM d, y",medium:"MMM d, y",short:"M/d/yy"},timeFormats:{full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},dateTimeFormats:{full:"{1} 'at' {0}",long:"{1} 'at' {0}",medium:"{1}, {0}",short:"{1}, {0}",availableFormats:{d:"d",E:"ccc",Ed:"d E",Ehm:"E h:mm a",EHm:"E HH:mm",Ehms:"E h:mm:ss a",EHms:"E HH:mm:ss",Gy:"y G",GyMMM:"MMM y G",GyMMMd:"MMM d, y G",GyMMMEd:"E, MMM d, y G",h:"h a",H:"HH",hm:"h:mm a",Hm:"HH:mm",hms:"h:mm:ss a",Hms:"HH:mm:ss",hmsv:"h:mm:ss a v",Hmsv:"HH:mm:ss v",hmv:"h:mm a v",Hmv:"HH:mm v",M:"L",Md:"M/d",MEd:"E, M/d",MMM:"LLL",MMMd:"MMM d",MMMEd:"E, MMM d",MMMMd:"MMMM d",ms:"mm:ss",y:"y",yM:"M/y",yMd:"M/d/y",yMEd:"E, M/d/y",yMMM:"MMM y",yMMMd:"MMM d, y",yMMMEd:"E, MMM d, y",yMMMM:"MMMM y"}}},islamic:{months:{"stand-alone":{abbreviated:{1:"Muh.",2:"Saf.",3:"Rab. I",4:"Rab. II",5:"Jum. I",6:"Jum. II",7:"Raj.",8:"Sha.",9:"Ram.",10:"Shaw.",11:"Dhu\u02bbl-Q.",12:"Dhu\u02bbl-H."},narrow:{1:"1",2:"2",3:"3",4:"4",5:"5",6:"6",7:"7",8:"8",9:"9",10:"10",11:"11",12:"12"},wide:{1:"Muharram",2:"Safar",3:"Rabi\u02bb I",4:"Rabi\u02bb II",5:"Jumada I",6:"Jumada II",7:"Rajab",8:"Sha\u02bbban",9:"Ramadan",10:"Shawwal",11:"Dhu\u02bbl-Qi\u02bbdah",12:"Dhu\u02bbl-Hijjah"}}},days:{"stand-alone":{abbreviated:{sun:"Sun",mon:"Mon",tue:"Tue",wed:"Wed",thu:"Thu",fri:"Fri",sat:"Sat"},narrow:{sun:"S",mon:"M",tue:"T",wed:"W",thu:"T",fri:"F",sat:"S"},short:{sun:"Su",mon:"Mo",tue:"Tu",wed:"We",thu:"Th",fri:"Fr",sat:"Sa"},wide:{sun:"Sunday",mon:"Monday",tue:"Tuesday",wed:"Wednesday",thu:"Thursday",fri:"Friday",sat:"Saturday"}}},dayPeriods:{format:{wide:{am:"AM",pm:"PM"}}},eras:{eraNames:{0:"AH"},eraAbbr:{0:"AH"},eraNarrow:{0:"AH"}},dateFormats:{full:"EEEE, MMMM d, y G",long:"MMMM d, y G",medium:"MMM d, y G",short:"M/d/y GGGGG"},timeFormats:{full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},dateTimeFormats:{full:"{1} 'at' {0}",long:"{1} 'at' {0}",medium:"{1}, {0}",short:"{1}, {0}",availableFormats:{d:"d",E:"ccc",Ed:"d E",Ehm:"E h:mm a",EHm:"E HH:mm",Ehms:"E h:mm:ss a",EHms:"E HH:mm:ss",Gy:"y G",GyMMM:"MMM y G",GyMMMd:"MMM d, y G",GyMMMEd:"E, MMM d, y G",h:"h a",H:"HH",hm:"h:mm a",Hm:"HH:mm",hms:"h:mm:ss a",Hms:"HH:mm:ss",M:"L",Md:"M/d",MEd:"E, M/d",MMM:"LLL",MMMd:"MMM d",MMMEd:"E, MMM d",MMMMd:"MMMM d",ms:"mm:ss",y:"y G",yyyy:"y G",yyyyM:"M/y GGGGG",yyyyMd:"M/d/y GGGGG",yyyyMEd:"E, M/d/y GGGGG",yyyyMMM:"MMM y G",yyyyMMMd:"MMM d, y G",yyyyMMMEd:"E, MMM d, y G",yyyyMMMM:"MMMM y G",yyyyQQQ:"QQQ y G",yyyyQQQQ:"QQQQ y G"}}}},timeZoneNames:{hourFormat:"+HH:mm;-HH:mm",gmtFormat:"GMT{0}",gmtZeroFormat:"GMT"}},numbers:{currencies:{USD:{displayName:"US Dollar",symbol:"$","symbol-alt-narrow":"$"},EUR:{displayName:"Euro",symbol:"\u20ac","symbol-alt-narrow":"\u20ac"},GBP:{displayName:"British Pound","symbol-alt-narrow":"\xa3"}},defaultNumberingSystem:"latn",minimumGroupingDigits:"1","symbols-numberSystem-latn":{decimal:".",group:",",list:";",percentSign:"%",plusSign:"+",minusSign:"-",exponential:"E",superscriptingExponent:"\xd7",perMille:"\u2030",infinity:"\u221e",nan:"NaN",timeSeparator:":"},"decimalFormats-numberSystem-latn":{standard:"#,##0.###"},"percentFormats-numberSystem-latn":{standard:"#,##0%"},"currencyFormats-numberSystem-latn":{standard:"\xa4#,##0.00",accounting:"\xa4#,##0.00;(\xa4#,##0.00)"},"scientificFormats-numberSystem-latn":{standard:"#E0"}}},n.blazorDefaultObject={numbers:{mapper:{0:"0",1:"1",2:"2",3:"3",4:"4",5:"5",6:"6",7:"7",8:"8",9:"9"},mapperDigits:"0123456789",numberSymbols:{decimal:".",group:",",plusSign:"+",minusSign:"-",percentSign:"%",nan:"NaN",timeSeparator:":",infinity:"\u221e"},timeSeparator:":",currencySymbol:"$",currencypData:{nlead:"$",nend:"",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},percentpData:{nlead:"",nend:"%",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},percentnData:{nlead:"-",nend:"%",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},currencynData:{nlead:"($",nend:")",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},decimalnData:{nlead:"-",nend:"",groupData:{primary:3},maximumFraction:2,minimumFraction:2},decimalpData:{nlead:"",nend:"",groupData:{primary:3},maximumFraction:2,minimumFraction:2}},dates:{dayPeriods:{am:"AM",pm:"PM"},dateSeperator:"/",days:{abbreviated:{sun:"Sun",mon:"Mon",tue:"Tue",wed:"Wed",thu:"Thu",fri:"Fri",sat:"Sat"},short:{sun:"Su",mon:"Mo",tue:"Tu",wed:"We",thu:"Th",fri:"Fr",sat:"Sa"},wide:{sun:"Sunday",mon:"Monday",tue:"Tuesday",wed:"Wednesday",thu:"Thursday",fri:"Friday",sat:"Saturday"}},months:{abbreviated:{1:"Jan",2:"Feb",3:"Mar",4:"Apr",5:"May",6:"Jun",7:"Jul",8:"Aug",9:"Sep",10:"Oct",11:"Nov",12:"Dec"},wide:{1:"January",2:"February",3:"March",4:"April",5:"May",6:"June",7:"July",8:"August",9:"September",10:"October",11:"November",12:"December"}},eras:{1:"AD"}}},n.monthIndex={3:"abbreviated",4:"wide",5:"narrow",1:"abbreviated"},n.month="months",n.days="days",n.patternMatcher={C:"currency",P:"percent",N:"decimal",A:"currency",E:"scientific"},n.getResultantPattern=l,n.getDependables=h,n.getSymbolPattern=c,n.ConvertDateToWeekFormat=d,n.compareBlazorDateFormats=u,n.getProperNumericSkeleton=f,n.getFormatData=p,n.changeCurrencySymbol=g,n.getCurrencySymbol=v,n.customFormat=function y(T,z,U){for(var B={},j=T.split(";"),Q=["pData","nData","zeroData"],oe=0;oe1,fe.nData=ce()?Y(De.type+"nData",oe):p(ot[1]||"-"+ot[0],!0,Ie),fe.pData=ce()?Y(De.type+"pData",oe):p(ot[0],!1,Ie),!Me[2]&&!z.minimumFractionDigits&&!z.maximumFractionDigits&&(ue=p(Ve.split(";")[0],!0,"",!0).minimumFraction)}if(n.formatRegex.test(z.format)||!z.format){if(ze(Q,f(z.format||"N")),Q.custom=!1,$e="###0",(Q.fractionDigits||z.minimumFractionDigits||z.maximumFractionDigits||ue)&&(Q.fractionDigits&&(z.minimumFractionDigits=z.maximumFractionDigits=Q.fractionDigits),$e=A($e,ue||Q.fractionDigits||z.minimumFractionDigits||0,z.maximumFractionDigits||0)),z.minimumIntegerDigits&&($e=x($e,z.minimumIntegerDigits)),z.useGrouping&&($e=P($e)),"currency"===Q.type||Q.type&&ce()){ce()&&"currency"!==Q.type&&(fe.pData=Y(Q.type+"pData",oe),fe.nData=Y(Q.type+"nData",oe));var hr=$e;$e=fe.pData.nlead+hr+fe.pData.nend,(fe.hasNegativePattern||ce())&&($e+=";"+fe.nData.nlead+hr+fe.nData.nend)}"percent"===Q.type&&!ce()&&($e+=" %")}else $e=z.format.replace(/'/g,'"');return Object.keys(xe).length>0&&($e=B?$e:C($e,xe)),$e},n.fractionDigitsPattern=A,n.minimumIntegerPattern=x,n.groupingPattern=P,n.getWeekData=function L(T,z){var U="sun",B=Y("supplemental.weekData.firstDay",z),j=T;return/en-/.test(j)&&(j=j.slice(3)),j=j.slice(0,2).toUpperCase()+j.substr(2),B&&(U=B[""+j]||B[j.slice(0,2)]||"sun"),o[""+U]},n.replaceBlazorCurrency=function O(T,z,U){var B=function f$(n){return Y(n||"",u$)}(U);if(z!==B)for(var j=0,Q=T;j=0?U:U+7;var j=Math.floor((T.getTime()-z.getTime()-6e4*(T.getTimezoneOffset()-z.getTimezoneOffset()))/864e5)+1;if(U<4){if((B=Math.floor((j+U-1)/7)+1)>52){var oe=new Date(T.getFullYear()+1,0,1).getDay();B=(oe=oe>=0?oe:oe+7)<4?1:53}}else B=Math.floor((j+U-1)/7);return B}}(ut||(ut={}));var af=function(){function n(t,e,i){this.type="GET",this.emitError=!0,"string"==typeof t?(this.url=t,this.type=m(e)?this.type:e.toUpperCase(),this.contentType=i):La(t)&&Object.keys(t).length>0&&kn(this,t),this.contentType=m(this.contentType)?"application/json; charset=utf-8":this.contentType}return n.prototype.send=function(t){var e=this,i={"application/json":"json","multipart/form-data":"formData","application/octet-stream":"blob","application/x-www-form-urlencoded":"formData"};try{m(this.fetchRequest)&&"GET"===this.type?this.fetchRequest=new Request(this.url,{method:this.type}):m(this.fetchRequest)&&(this.data=m(t)?this.data:t,this.fetchRequest=new Request(this.url,{method:this.type,headers:{"Content-Type":this.contentType},body:this.data}));var r={cancel:!1,fetchRequest:this.fetchRequest};return this.triggerEvent(this.beforeSend,r),r.cancel?null:(this.fetchResponse=fetch(this.fetchRequest),this.fetchResponse.then(function(s){if(e.triggerEvent(e.onLoad,s),!s.ok)throw s;for(var o="text",a=0,l=Object.keys(i);a-1},n.getValue=function(t,e){var i=typeof window<"u"?window.browserDetails:{};return typeof navigator<"u"&&"MacIntel"===navigator.platform&&navigator.maxTouchPoints>1&&!0===n.isTouch&&!mC.CHROME.test(navigator.userAgent)&&(i.isIos=!0,i.isDevice=!0,i.isTouch=!0,i.isPointer=!0,i.isPointer="pointerEnabled"in window.navigator),typeof window<"u"&&window.Capacitor&&"ios"===window.Capacitor.getPlatform()&&(i.isPointer=!1),typeof i[""+t]>"u"?i[""+t]=e.test(n.userAgent):i[""+t]},Object.defineProperty(n,"userAgent",{get:function(){return n.uA},set:function(t){n.uA=t,window.browserDetails={}},enumerable:!0,configurable:!0}),Object.defineProperty(n,"info",{get:function(){return st(window.browserDetails.info)?window.browserDetails.info=n.extractBrowserDetail():window.browserDetails.info},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isIE",{get:function(){return n.getValue("isIE",A$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isTouch",{get:function(){return st(window.browserDetails.isTouch)?window.browserDetails.isTouch="ontouchstart"in window.navigator||window&&window.navigator&&window.navigator.maxTouchPoints>0||"ontouchstart"in window:window.browserDetails.isTouch},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isPointer",{get:function(){return st(window.browserDetails.isPointer)?window.browserDetails.isPointer="pointerEnabled"in window.navigator:window.browserDetails.isPointer},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isMSPointer",{get:function(){return st(window.browserDetails.isMSPointer)?window.browserDetails.isMSPointer="msPointerEnabled"in window.navigator:window.browserDetails.isMSPointer},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isDevice",{get:function(){return n.getValue("isDevice",T$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isIos",{get:function(){return n.getValue("isIos",N$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isIos7",{get:function(){return n.getValue("isIos7",O$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isAndroid",{get:function(){return n.getValue("isAndroid",k$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isWebView",{get:function(){return st(window.browserDetails.isWebView)&&(window.browserDetails.isWebView=!(st(window.cordova)&&st(window.PhoneGap)&&st(window.phonegap)&&"object"!==window.forge)),window.browserDetails.isWebView},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isWindows",{get:function(){return n.getValue("isWindows",P$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"touchStartEvent",{get:function(){return st(window.browserDetails.touchStartEvent)?window.browserDetails.touchStartEvent=n.getTouchStartEvent():window.browserDetails.touchStartEvent},enumerable:!0,configurable:!0}),Object.defineProperty(n,"touchMoveEvent",{get:function(){return st(window.browserDetails.touchMoveEvent)?window.browserDetails.touchMoveEvent=n.getTouchMoveEvent():window.browserDetails.touchMoveEvent},enumerable:!0,configurable:!0}),Object.defineProperty(n,"touchEndEvent",{get:function(){return st(window.browserDetails.touchEndEvent)?window.browserDetails.touchEndEvent=n.getTouchEndEvent():window.browserDetails.touchEndEvent},enumerable:!0,configurable:!0}),Object.defineProperty(n,"touchCancelEvent",{get:function(){return st(window.browserDetails.touchCancelEvent)?window.browserDetails.touchCancelEvent=n.getTouchCancelEvent():window.browserDetails.touchCancelEvent},enumerable:!0,configurable:!0}),n.uA=typeof navigator<"u"?navigator.userAgent:"",n}(),E=function(){function n(){}return n.addOrGetEventData=function(t){return"__eventList"in t?t.__eventList.events:(t.__eventList={},t.__eventList.events=[])},n.add=function(t,e,i,r,s){var a,o=n.addOrGetEventData(t);a=s?function l$(n,t){var e;return function(){for(var i=this,r=[],s=0;s"u"||(e.innerHTML=t.innerHTML?t.innerHTML:"",void 0!==t.className&&(e.className=t.className),void 0!==t.id&&(e.id=t.id),void 0!==t.styles&&e.setAttribute("style",t.styles),void 0!==t.attrs&&Fe(e,t.attrs)),e}function V(n,t){for(var e=Vz(t),i=RegExp,r=0,s=n;r0}function gl(n,t,e){for(var i=document.createDocumentFragment(),r=0,s=n;r0;)i.appendChild(n[0]);else for(var r=0,s=n;r-1&&!r[parseInt(s.toString(),10)].match(/\[.*\]/)){var o=r[parseInt(s.toString(),10)].split("#");if(o[1].match(/^\d/)||o[1].match(t)){var a=r[parseInt(s.toString(),10)].split(".");a[0]=a[0].replace(/#/,"[id='")+"']",r[parseInt(s.toString(),10)]=a.join(".")}}e[parseInt(i.toString(),10)]=r.join(" ")}return e.join(",")}return n}function J(n,t){var e=n;if("function"==typeof e.closest)return e.closest(t);for(;e&&1===e.nodeType;){if(yC(e,t))return e;e=e.parentNode}return null}function je(n,t){void 0!==t&&Object.keys(t).forEach(function(e){n.style[""+e]=t[""+e]})}function yC(n,t){var e=n.matches||n.msMatchesSelector||n.webkitMatchesSelector;return e?e.call(n,t):-1!==[].indexOf.call(document.querySelectorAll(t),n)}var H$=new RegExp("]"),fh=function(){function n(t,e){this.isRendered=!1,this.isComplexArraySetter=!1,this.isServerRendered=!1,this.allowServerDataBinding=!0,this.isProtectedOnChange=!0,this.properties={},this.changedProperties={},this.oldProperties={},this.bulkChanges={},this.refreshing=!1,this.ignoreCollectionWatch=!1,this.finalUpdate=function(){},this.childChangedProperties={},this.modelObserver=new Ng(this),st(e)||(this.element="string"==typeof e?document.querySelector(e):e,m(this.element)||(this.isProtectedOnChange=!1,this.addInstance())),st(t)||this.setProperties(t,!0),this.isDestroyed=!1}return n.prototype.setProperties=function(t,e){var i=this.isProtectedOnChange;this.isProtectedOnChange=!!e,kn(this,t),!0!==e?(kn(this.changedProperties,t),this.dataBind()):ce()&&this.isRendered&&this.serverDataBind(t),this.finalUpdate(),this.changedProperties={},this.oldProperties={},this.isProtectedOnChange=i},n.callChildDataBind=function(t,e){for(var r=0,s=Object.keys(t);r=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Hs=function(n){function t(i){var r=n.call(this,i,void 0)||this;return r.easing={ease:"cubic-bezier(0.250, 0.100, 0.250, 1.000)",linear:"cubic-bezier(0.250, 0.250, 0.750, 0.750)",easeIn:"cubic-bezier(0.420, 0.000, 1.000, 1.000)",easeOut:"cubic-bezier(0.000, 0.000, 0.580, 1.000)",easeInOut:"cubic-bezier(0.420, 0.000, 0.580, 1.000)",elasticInOut:"cubic-bezier(0.5,-0.58,0.38,1.81)",elasticIn:"cubic-bezier(0.17,0.67,0.59,1.81)",elasticOut:"cubic-bezier(0.7,-0.75,0.99,1.01)"},r}var e;return X$(t,n),e=t,t.prototype.animate=function(i,r){var s=this.getModel(r=r||{});if("string"==typeof i)for(var a=0,l=Array.prototype.slice.call(we(i,document));a0?r-1:0,i+=e=-1!==e?"-"+e:"-"+r}return this.controlParent!==this.parentObj&&(i=this.parentObj.getParentKey()+"."+this.propName+e),i},n}(),J$=["grid","pivotview","treegrid","spreadsheet","rangeNavigator","DocumentEditor","listbox","inplaceeditor","PdfViewer","richtexteditor","DashboardLayout","chart","stockChart","circulargauge","diagram","heatmap","lineargauge","maps","slider","smithchart","barcode","sparkline","treemap","bulletChart","kanban","daterangepicker","schedule","gantt","signature","query-builder","drop-down-tree","carousel","filemanager","uploader","accordion","tab","treeview"],tR=[115,121,110,99,102,117,115,105,111,110,46,105,115,76,105,99,86,97,108,105,100,97,116,101,100],iR=function(){function n(t){this.isValidated=!1,this.isLicensed=!0,this.version="27",this.platform=/JavaScript|ASPNET|ASPNETCORE|ASPNETMVC|FileFormats|essentialstudio/i,this.errors={noLicense:"This application was built using a trial version of Syncfusion Essential Studio. To remove the license validation message permanently, a valid license key must be included.",trailExpired:"This application was built using a trial version of Syncfusion Essential Studio. To remove the license validation message permanently, a valid license key must be included.",versionMismatched:"The included Syncfusion license key is invalid.",platformMismatched:"The included Syncfusion license key is invalid.",invalidKey:"The included Syncfusion license key is invalid."},this.manager=function(){var e=null;return{setKey:function i(s){e=s},getKey:function r(){return e}}}(),this.npxManager=function(){return{getKey:function i(){return"npxKeyReplace"}}}(),this.manager.setKey(t)}return n.prototype.validate=function(){if(!this.isValidated&&sf&&!Y(N0(tR),sf)&&!Y("Blazor",sf)){var i=void 0,r=void 0;if(this.manager&&this.manager.getKey()||this.npxManager&&"npxKeyReplace"!==this.npxManager.getKey()){var s=this.getInfoFromKey();if(s&&s.length)for(var o=0,a=s;o"+i+' Claim your FREE account\n
have a Syncfusion account? Sign In
\n \n ';if(typeof document<"u"&&!m(document)){var t=Si("div",{innerHTML:n});document.body.appendChild(t)}}(),oR=!0),this.render(),this.mount?this.accessMount():this.trigger("created")}},t.prototype.renderComplete=function(e){ce()&&window.sfBlazor.renderComplete(this.element,e),this.isRendered=!0},t.prototype.dataBind=function(){this.injectModules(),n.prototype.dataBind.call(this)},t.prototype.on=function(e,i,r){if("string"==typeof e)this.localObserver.on(e,i,r);else for(var s=0,o=e;s=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},rZ={left:0,top:0,bottom:0,right:0},wC={isDragged:!1},nZ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return aR(t,n),gr([I(0)],t.prototype,"left",void 0),gr([I(0)],t.prototype,"top",void 0),t}(Ee),cf=function(n){function t(i,r){var s=n.call(this,r,i)||this;return s.dragLimit=e.getDefaultPosition(),s.borderWidth=e.getDefaultPosition(),s.padding=e.getDefaultPosition(),s.diffX=0,s.prevLeft=0,s.prevTop=0,s.dragProcessStarted=!1,s.eleTop=0,s.tapHoldTimer=0,s.externalInitialize=!1,s.diffY=0,s.parentScrollX=0,s.parentScrollY=0,s.droppables={},s.bind(),s}var e;return aR(t,n),e=t,t.prototype.bind=function(){this.toggleEvents(),X.isIE&&V([this.element],"e-block-touch"),this.droppables[this.scope]={}},t.getDefaultPosition=function(){return ze({},rZ)},t.prototype.toggleEvents=function(i){var r;st(this.handle)||(r=_(this.handle,this.element));var s=this.enableTapHold&&X.isDevice&&X.isTouch?this.mobileInitialize:this.initialize;i?E.remove(r||this.element,X.isSafari()?"touchstart":X.touchStartEvent,s):E.add(r||this.element,X.isSafari()?"touchstart":X.touchStartEvent,s,this)},t.prototype.mobileInitialize=function(i){var r=this,s=i.currentTarget;this.tapHoldTimer=setTimeout(function(){r.externalInitialize=!0,r.removeTapholdTimer(),r.initialize(i,s)},this.tapHoldThreshold),E.add(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.removeTapholdTimer,this),E.add(document,X.isSafari()?"touchend":X.touchEndEvent,this.removeTapholdTimer,this)},t.prototype.removeTapholdTimer=function(){clearTimeout(this.tapHoldTimer),E.remove(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.removeTapholdTimer),E.remove(document,X.isSafari()?"touchend":X.touchEndEvent,this.removeTapholdTimer)},t.prototype.getScrollableParent=function(i,r){return m(i)?null:i[{vertical:"scrollHeight",horizontal:"scrollWidth"}[""+r]]>i[{vertical:"clientHeight",horizontal:"clientWidth"}[""+r]]&&("vertical"===r?i.scrollTop>0:i.scrollLeft>0)?("vertical"===r?(this.parentScrollY=this.parentScrollY+(0===this.parentScrollY?i.scrollTop:i.scrollTop-this.parentScrollY),this.tempScrollHeight=i.scrollHeight):(this.parentScrollX=this.parentScrollX+(0===this.parentScrollX?i.scrollLeft:i.scrollLeft-this.parentScrollX),this.tempScrollWidth=i.scrollWidth),m(i)?i:this.getScrollableParent(i.parentNode,r)):this.getScrollableParent(i.parentNode,r)},t.prototype.getScrollableValues=function(){this.parentScrollX=0,this.parentScrollY=0,this.element.classList.contains("e-dialog")&&this.element.classList.contains("e-dlg-modal"),this.getScrollableParent(this.element.parentNode,"vertical"),this.getScrollableParent(this.element.parentNode,"horizontal")},t.prototype.initialize=function(i,r){if(this.currentStateTarget=i.target,!this.isDragStarted()){if(this.isDragStarted(!0),this.externalInitialize=!1,this.target=i.currentTarget||r,this.dragProcessStarted=!1,this.abort){var s=this.abort;"string"==typeof s&&(s=[s]);for(var o=0;o=this.distance||this.externalInitialize){var f=this.getHelperElement(i);if(!f||m(f))return;r&&i.preventDefault();var p=this.helperElement=f;if(this.parentClientRect=this.calculateParentPosition(p.offsetParent),this.dragStart){var v={event:i,element:l,target:this.getProperTargetElement(i),bindEvents:ce()?this.bindDragEvents.bind(this):null,dragElement:p};this.trigger("dragStart",v)}this.dragArea?this.setDragArea():(this.dragLimit={left:0,right:0,bottom:0,top:0},this.borderWidth={top:0,left:0}),o={left:this.position.left-this.parentClientRect.left,top:this.position.top-this.parentClientRect.top},this.clone&&!this.enableTailMode&&(this.diffX=this.position.left-this.offset.left,this.diffY=this.position.top-this.offset.top),this.getScrollableValues();var y=getComputedStyle(l),S=parseFloat(y.marginTop);this.clone&&0!==S&&(o.top+=S),this.eleTop=isNaN(parseFloat(y.top))?0:parseFloat(y.top)-this.offset.top,this.enableScrollHandler&&!this.clone&&(o.top-=this.parentScrollY,o.left-=this.parentScrollX);var b=this.getProcessedPositionValue({top:o.top-this.diffY+"px",left:o.left-this.diffX+"px"});this.dragArea&&"string"!=typeof this.dragArea&&this.dragArea.classList.contains("e-kanban-content")&&"relative"===this.dragArea.style.position&&(o.top+=this.dragArea.scrollTop),this.dragElePosition={top:o.top,left:o.left},je(p,this.getDragPosition({position:"absolute",left:b.left,top:b.top})),E.remove(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.intDragStart),E.remove(document,X.isSafari()?"touchend":X.touchEndEvent,this.intDestroy),ce()||this.bindDragEvents(p)}}},t.prototype.bindDragEvents=function(i){Tr(i)?(E.add(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.intDrag,this),E.add(document,X.isSafari()?"touchend":X.touchEndEvent,this.intDragStop,this),this.setGlobalDroppables(!1,this.element,i)):(this.toggleEvents(),document.body.classList.remove("e-prevent-select"))},t.prototype.elementInViewport=function(i){for(this.top=i.offsetTop,this.left=i.offsetLeft,this.width=i.offsetWidth,this.height=i.offsetHeight;i.offsetParent;)this.top+=(i=i.offsetParent).offsetTop,this.left+=i.offsetLeft;return this.top>=window.pageYOffset&&this.left>=window.pageXOffset&&this.top+this.height<=window.pageYOffset+window.innerHeight&&this.left+this.width<=window.pageXOffset+window.innerWidth},t.prototype.getProcessedPositionValue=function(i){return this.queryPositionInfo?this.queryPositionInfo(i):i},t.prototype.calculateParentPosition=function(i){if(m(i))return{left:0,top:0};var r=i.getBoundingClientRect(),s=getComputedStyle(i);return{left:r.left+window.pageXOffset-parseInt(s.marginLeft,10),top:r.top+window.pageYOffset-parseInt(s.marginTop,10)}},t.prototype.intDrag=function(i){if(st(i.changedTouches)||1===i.changedTouches.length){var r,s;this.clone&&i.changedTouches&&X.isDevice&&X.isTouch&&i.preventDefault(),this.position=this.getMousePosition(i,this.isDragScroll);var o=this.getDocumentWidthHeight("Height");oy&&y>0?this.dragLimit.left:this.dragLimit.right+window.pageXOffset0?y-(y-this.dragLimit.right)+window.pageXOffset-M:y<0?this.dragLimit.left:y}if(this.pageY!==v||this.skipDistanceCheck){var w=d.offsetHeight+(parseFloat(b.marginTop)+parseFloat(b.marginBottom));s=this.dragLimit.top>S&&S>0?this.dragLimit.top:this.dragLimit.bottom+window.pageYOffset0?S-(S-this.dragLimit.bottom)+window.pageYOffset-w:S<0?this.dragLimit.top:S}}else r=y,s=S;var A,x,C=f+this.borderWidth.top,D=u+this.borderWidth.left;if(this.dragProcessStarted&&(m(s)&&(s=this.prevTop),m(r)&&(r=this.prevLeft)),this.helperElement.classList.contains("e-treeview"))this.dragArea?(this.dragLimit.top=this.clone?this.dragLimit.top:0,A=s-C<0?this.dragLimit.top:s-this.borderWidth.top,x=r-D<0?this.dragLimit.left:r-this.borderWidth.left):(A=s-this.borderWidth.top,x=r-this.borderWidth.left);else if(this.dragArea){var P=this.helperElement.classList.contains("e-dialog");this.dragLimit.top=this.clone?this.dragLimit.top:0,A=s-C<0?this.dragLimit.top:s-C,x=r-D<0?P?r-(D-this.borderWidth.left):this.dragElePosition.left:r-D}else A=s-C,x=r-D;var L=parseFloat(getComputedStyle(this.element).marginTop);if(L>0&&(this.clone&&(A+=L,S<0&&(L+S>=0?A=L+S:A-=L),this.dragArea&&(A=this.dragLimit.bottom=0){var O=this.dragLimit.top+S-C;O+L+C<0?A-=L+C:A=O}else A-=L+C;this.dragArea&&this.helperElement.classList.contains("e-treeview")&&(A=A+(w=d.offsetHeight+(parseFloat(b.marginTop)+parseFloat(b.marginBottom)))>this.dragLimit.bottom?this.dragLimit.bottom-w:A),this.enableScrollHandler&&!this.clone&&(A-=this.parentScrollY,x-=this.parentScrollX),this.dragArea&&"string"!=typeof this.dragArea&&this.dragArea.classList.contains("e-kanban-content")&&"relative"===this.dragArea.style.position&&(A+=this.dragArea.scrollTop);var N=this.getProcessedPositionValue({top:A+"px",left:x+"px"});this.isPreventScroll&&(N=this.getProcessedPositionValue({top:this.position.top-this.parentClientRect.top-2+"px",left:this.position.left-this.parentClientRect.left-2+"px"})),je(d,this.getDragPosition(N)),!this.elementInViewport(d)&&this.enableAutoScroll&&!this.helperElement.classList.contains("e-treeview")&&this.helperElement.scrollIntoView();var T=document.querySelectorAll(":hover");if(this.enableAutoScroll&&this.helperElement.classList.contains("e-treeview")){0===T.length&&(T=this.getPathElements(i));var z=this.getScrollParent(T,!1);this.elementInViewport(this.helperElement)?this.getScrollPosition(z,A):this.elementInViewport(this.helperElement)||(0===(T=[].slice.call(document.querySelectorAll(":hover"))).length&&(T=this.getPathElements(i)),z=this.getScrollParent(T,!0),this.getScrollPosition(z,A))}this.dragProcessStarted=!0,this.prevLeft=r,this.prevTop=s,this.position.left=r,this.position.top=s,this.pageX=g,this.pageY=v}},t.prototype.getScrollParent=function(i,r){for(var o,s=r?i.reverse():i,a=s.length-1;a>=0;a--)if(("auto"===(o=window.getComputedStyle(s[parseInt(a.toString(),10)])["overflow-y"])||"scroll"===o)&&s[parseInt(a.toString(),10)].scrollHeight>s[parseInt(a.toString(),10)].clientHeight)return s[parseInt(a.toString(),10)];if("visible"===(o=window.getComputedStyle(document.scrollingElement)["overflow-y"]))return document.scrollingElement.style.overflow="auto",document.scrollingElement},t.prototype.getScrollPosition=function(i,r){if(i&&i===document.scrollingElement)i.clientHeight+document.scrollingElement.scrollTop-this.helperElement.clientHeightr?i.scrollTop+=this.helperElement.clientHeight:i.scrollTop>r-this.helperElement.clientHeight&&(i.scrollTop-=this.helperElement.clientHeight);else if(i&&i!==document.scrollingElement){var s=document.scrollingElement.scrollTop,o=this.helperElement.clientHeight;i.clientHeight+i.getBoundingClientRect().top-o+sr-o-s&&(i.scrollTop-=this.helperElement.clientHeight)}},t.prototype.getPathElements=function(i){return document.elementsFromPoint(i.clientX>0?i.clientX:0,i.clientY>0?i.clientY:0)},t.prototype.triggerOutFunction=function(i,r){this.hoverObject.instance.intOut(i,r.target),this.hoverObject.instance.dragData[this.scope]=null,this.hoverObject=null},t.prototype.getDragPosition=function(i){var r=ze({},i);return this.axis&&("x"===this.axis?delete r.top:"y"===this.axis&&delete r.left),r},t.prototype.getDocumentWidthHeight=function(i){var r=document.body,s=document.documentElement;return Math.max(r["scroll"+i],s["scroll"+i],r["offset"+i],s["offset"+i],s["client"+i])},t.prototype.intDragStop=function(i){if(this.dragProcessStarted=!1,st(i.changedTouches)||1===i.changedTouches.length){if(-1!==["touchend","pointerup","mouseup"].indexOf(i.type)){if(this.dragStop){var s=this.getProperTargetElement(i);this.trigger("dragStop",{event:i,element:this.element,target:s,helper:this.helperElement})}this.intDestroy(i)}else this.element.setAttribute("aria-grabbed","false");var o=this.checkTargetElement(i);o.target&&o.instance&&(o.instance.dragStopCalled=!0,o.instance.dragData[this.scope]=this.droppables[this.scope],o.instance.intDrop(i,o.target)),this.setGlobalDroppables(!0),document.body.classList.remove("e-prevent-select")}},t.prototype.intDestroy=function(i){this.dragProcessStarted=!1,this.toggleEvents(),document.body.classList.remove("e-prevent-select"),this.element.setAttribute("aria-grabbed","false"),E.remove(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.intDragStart),E.remove(document,X.isSafari()?"touchend":X.touchEndEvent,this.intDragStop),E.remove(document,X.isSafari()?"touchend":X.touchEndEvent,this.intDestroy),E.remove(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.intDrag),this.isDragStarted()&&this.isDragStarted(!0)},t.prototype.onPropertyChanged=function(i,r){},t.prototype.getModuleName=function(){return"draggable"},t.prototype.isDragStarted=function(i){return i&&(wC.isDragged=!wC.isDragged),wC.isDragged},t.prototype.setDragArea=function(){var i,r,a,s=0,o=0;if(a="string"==typeof this.dragArea?_(this.dragArea):this.dragArea){var h=a.getBoundingClientRect();i=a.scrollWidth?a.scrollWidth:h.right-h.left,r=a.scrollHeight?this.dragArea&&!m(this.helperElement)&&this.helperElement.classList.contains("e-treeview")?a.clientHeight:a.scrollHeight:h.bottom-h.top;for(var c=["Top","Left","Bottom","Right"],d=getComputedStyle(a),u=0;u12;return x0(i.target,this.helperElement)||-1!==i.type.indexOf("touch")||a?(this.helperElement.style.pointerEvents="none",s=document.elementFromPoint(r.clientX,r.clientY),this.helperElement.style.pointerEvents=o):s=i.target,s},t.prototype.currentStateCheck=function(i,r){return m(this.currentStateTarget)||this.currentStateTarget===i?m(r)?i:r:this.currentStateTarget},t.prototype.getMousePosition=function(i,r){var a,l,s=void 0!==i.srcElement?i.srcElement:i.target,o=this.getCoordinates(i),h=m(s.offsetParent);if(r?(a=this.clone?o.pageX:o.pageX+(h?0:s.offsetParent.scrollLeft)-this.relativeXPosition,l=this.clone?o.pageY:o.pageY+(h?0:s.offsetParent.scrollTop)-this.relativeYPosition):(a=this.clone?o.pageX:o.pageX+window.pageXOffset-this.relativeXPosition,l=this.clone?o.pageY:o.pageY+window.pageYOffset-this.relativeYPosition),document.scrollingElement&&!r&&!this.clone){var c=document.scrollingElement;a=c.scrollWidth>0&&c.scrollWidth>c.clientWidth&&c.scrollLeft>0?a-c.scrollLeft:a,l=c.scrollHeight>0&&c.scrollHeight>c.clientHeight&&c.scrollTop>0?l-c.scrollTop:l}return{left:a-(this.margin.left+this.cursorAt.left),top:l-(this.margin.top+this.cursorAt.top)}},t.prototype.getCoordinates=function(i){return i.type.indexOf("touch")>-1?i.changedTouches[0]:i},t.prototype.getHelperElement=function(i){var r;return this.clone?this.helper?r=this.helper({sender:i,element:this.target}):(r=Si("div",{className:"e-drag-helper e-block-touch",innerHTML:"Draggable"}),document.body.appendChild(r)):r=this.element,r},t.prototype.setGlobalDroppables=function(i,r,s){this.droppables[this.scope]=i?null:{draggable:r,helper:s,draggedElement:this.element}},t.prototype.checkTargetElement=function(i){var r=this.getProperTargetElement(i),s=this.getDropInstance(r);if(!s&&r&&!m(r.parentNode)){var o=J(r.parentNode,".e-droppable")||r.parentElement;o&&(s=this.getDropInstance(o))}return{target:r,instance:s}},t.prototype.getDropInstance=function(i){var s,o=i&&i.ej2_instances;if(o)for(var a=0,l=o;a=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},lR=function(n){function t(e,i){var r=n.call(this,i,e)||this;return r.mouseOver=!1,r.dragData={},r.dragStopCalled=!1,r.bind(),r}return sZ(t,n),t.prototype.bind=function(){this.wireEvents()},t.prototype.wireEvents=function(){E.add(this.element,X.isSafari()?"touchend":X.touchEndEvent,this.intDrop,this)},t.prototype.onPropertyChanged=function(e,i){},t.prototype.getModuleName=function(){return"droppable"},t.prototype.intOver=function(e,i){this.mouseOver||(this.trigger("over",{event:e,target:i,dragData:this.dragData[this.scope]}),this.mouseOver=!0)},t.prototype.intOut=function(e,i){this.mouseOver&&(this.trigger("out",{evt:e,target:i}),this.mouseOver=!1)},t.prototype.intDrop=function(e,i){if(this.dragStopCalled){this.dragStopCalled=!1;var a,r=!0,s=this.dragData[this.scope],o=!!s&&s.helper&&Tr(s.helper);o&&(a=this.isDropArea(e,s.helper,i),this.accept&&(r=yC(s.helper,this.accept))),o&&this.drop&&a.canDrop&&r&&this.trigger("drop",{event:e,target:a.target,droppedElement:s.helper,dragData:s}),this.mouseOver=!1}},t.prototype.isDropArea=function(e,i,r){var s={canDrop:!0,target:r||e.target},o="touchend"===e.type;if(o||s.target===i){i.style.display="none";var a=o?e.changedTouches[0]:e,l=document.elementFromPoint(a.clientX,a.clientY);s.canDrop=!1,s.canDrop=x0(l,this.element),s.canDrop&&(s.target=l),i.style.display=""}return s},t.prototype.destroy=function(){E.remove(this.element,X.isSafari()?"touchend":X.touchEndEvent,this.intDrop),n.prototype.destroy.call(this)},df([I()],t.prototype,"accept",void 0),df([I("default")],t.prototype,"scope",void 0),df([H()],t.prototype,"drop",void 0),df([H()],t.prototype,"over",void 0),df([H()],t.prototype,"out",void 0),df([Ft],t)}(fh),uo=function(){function n(t,e,i){this.controlName=t,this.localeStrings=e,this.setLocale(i||"en-US")}return n.prototype.setLocale=function(t){var e=this.intGetControlConstant(n.locale,t);this.currentLocale=e||this.localeStrings},n.load=function(t){this.locale=ze(this.locale,t,{},!0)},n.prototype.getConstant=function(t){return m(this.currentLocale[""+t])?this.localeStrings[""+t]||"":this.currentLocale[""+t]},n.prototype.intGetControlConstant=function(t,e){return t[""+e]?t[""+e][this.controlName]:null},n.locale={},n}(),hR=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),gh=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},lZ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return hR(t,n),gh([I(50)],t.prototype,"swipeThresholdDistance",void 0),t}(Ee),hZ=/(Up|Down)/,Fs=function(n){function t(e,i){var r=n.call(this,i,e)||this;return r.touchAction=!0,r.tapCount=0,r.startEvent=function(s){if(!0===r.touchAction){var o=r.updateChangeTouches(s);void 0!==s.changedTouches&&(r.touchAction=!1),r.isTouchMoved=!1,r.movedDirection="",r.startPoint=r.lastMovedPoint={clientX:o.clientX,clientY:o.clientY},r.startEventData=o,r.hScrollLocked=r.vScrollLocked=!1,r.tStampStart=Date.now(),r.timeOutTapHold=setTimeout(function(){r.tapHoldEvent(s)},r.tapHoldThreshold),E.add(r.element,X.touchMoveEvent,r.moveEvent,r),E.add(r.element,X.touchEndEvent,r.endEvent,r),E.add(r.element,X.touchCancelEvent,r.cancelEvent,r)}},r.moveEvent=function(s){var o=r.updateChangeTouches(s);r.movedPoint=o,r.isTouchMoved=!(o.clientX===r.startPoint.clientX&&o.clientY===r.startPoint.clientY);var a={};r.isTouchMoved&&(clearTimeout(r.timeOutTapHold),r.calcScrollPoints(s),a=ze(a,{},{startEvents:r.startEventData,originalEvent:s,startX:r.startPoint.clientX,startY:r.startPoint.clientY,distanceX:r.distanceX,distanceY:r.distanceY,scrollDirection:r.scrollDirection,velocity:r.getVelocity(o)}),r.trigger("scroll",a),r.lastMovedPoint={clientX:o.clientX,clientY:o.clientY})},r.cancelEvent=function(s){clearTimeout(r.timeOutTapHold),clearTimeout(r.timeOutTap),r.tapCount=0,r.swipeFn(s),E.remove(r.element,X.touchCancelEvent,r.cancelEvent)},r.endEvent=function(s){r.swipeFn(s),r.isTouchMoved||"function"==typeof r.tap&&(r.trigger("tap",{originalEvent:s,tapCount:++r.tapCount}),r.timeOutTap=setTimeout(function(){r.tapCount=0},r.tapThreshold)),r.modeclear()},r.swipeFn=function(s){clearTimeout(r.timeOutTapHold),clearTimeout(r.timeOutTap);var o=r.updateChangeTouches(s),a=o.clientX-r.startPoint.clientX,l=o.clientY-r.startPoint.clientY;a=Math.floor(a<0?-1*a:a),l=Math.floor(l<0?-1*l:a),r.isTouchMoved=a>1||l>1,/Firefox/.test(X.userAgent)&&0===o.clientX&&0===o.clientY&&"mouseup"===s.type&&(r.isTouchMoved=!1),r.endPoint=o,r.calcPoints(s);var c={originalEvent:s,startEvents:r.startEventData,startX:r.startPoint.clientX,startY:r.startPoint.clientY,distanceX:r.distanceX,distanceY:r.distanceY,swipeDirection:r.movedDirection,velocity:r.getVelocity(o)};if(r.isTouchMoved){var d=r.swipeSettings.swipeThresholdDistance,u=ze(void 0,r.defaultArgs,c),f=!1,p=r.element,g=r.isScrollable(p),v=hZ.test(r.movedDirection);(dthis.distanceY?i.clientX>this.startPoint.clientX?"Right":"Left":i.clientYthis.distanceY||!0===this.hScrollLocked)&&!1===this.vScrollLocked?(this.scrollDirection=i.clientX>this.lastMovedPoint.clientX?"Right":"Left",this.hScrollLocked=!0):(this.scrollDirection=i.clientY=e[r[0]+s[0]]},t.prototype.updateChangeTouches=function(e){return e.changedTouches&&0!==e.changedTouches.length?e.changedTouches[0]:e},gh([H()],t.prototype,"tap",void 0),gh([H()],t.prototype,"tapHold",void 0),gh([H()],t.prototype,"swipe",void 0),gh([H()],t.prototype,"scroll",void 0),gh([I(350)],t.prototype,"tapThreshold",void 0),gh([I(750)],t.prototype,"tapHoldThreshold",void 0),gh([re({},lZ)],t.prototype,"swipeSettings",void 0),gh([Ft],t)}(fh),cZ=new RegExp("\\n|\\r|\\s\\s+","g"),dZ=new RegExp(/'|"/g),uZ=new RegExp("if ?\\("),fZ=new RegExp("else if ?\\("),cR=new RegExp("else"),pZ=new RegExp("for ?\\("),dR=new RegExp("(/if|/for)"),gZ=new RegExp("\\((.*)\\)",""),CC=new RegExp("^[0-9]+$","g"),vZ=new RegExp("[\\w\"'.\\s+]+","g"),mZ=new RegExp('"(.*?)"',"g"),yZ=new RegExp("[\\w\"'@#$.\\s-+]+","g"),uR=new RegExp("\\${([^}]*)}","g"),SZ=/^\..*/gm,EC=/\\/gi,IZ=/\\\\/gi,bZ=new RegExp("[\\w\"'@#$.\\s+]+","g"),MZ=/\window\./gm;function uf(n,t,e,i,r){return!t||CC.test(n)||-1!==i.indexOf(n.split(".")[0])||r||"true"===n||"false"===n?n:e+"."+n}function DC(n,t,e,i){return t&&!CC.test(n)&&-1===i.indexOf(n.split(".")[0])?e+'["'+n:n}function fR(n){return n.match(IZ)?n:n.replace(EC,"\\\\")}function pR(n,t,e,i){if(n=n.trim(),/\window\./gm.test(n))return n;var s=/'|"/gm;return/@|\$|#/gm.test(n)&&(n=DC(n,-1===e.indexOf(n),t,e)+'"]'),SZ.test(n)?function EZ(n,t,e,i){return!t||CC.test(n)||-1!==i.indexOf(n.split(".")[0])||/^\..*/gm.test(n)?n:e+"."+n}(n,!s.test(n)&&-1===e.indexOf(n),t,e):uf(n,!s.test(n)&&-1===e.indexOf(n),t,e,i)}var DZ=/^[\n\r.]+0&&t.forEach(function(e){he(e)})},n.removeJsEvents=function(){var t=this.wrapElement.querySelectorAll("["+vR.join("],[")+"]");t.length>0&&t.forEach(function(e){vR.forEach(function(i){e.hasAttribute(i)&&e.removeAttribute(i)})})},n.removeXssAttrs=function(){var t=this;this.removeAttrs.forEach(function(e,i){var r=t.wrapElement.querySelectorAll(e.selector);r.length>0&&r.forEach("a[href]"===e.selector?function(s){-1!==s.getAttribute(e.attribute).replace(/\t|\s|&/,"").indexOf("javascript:alert")&&s.removeAttribute(e.attribute)}:function(s){s.removeAttribute(e.attribute)})})},n}();function PZ(n){return function(t){!function kZ(n,t){t.forEach(function(e){Object.getOwnPropertyNames(e.prototype).forEach(function(i){(!Object.prototype.hasOwnProperty.call(n.prototype,i)||e.isFormBase&&"constructor"!==i)&&(n.prototype["".concat(i)]=e.prototype["".concat(i)])})})}(t,n)}}function mR(n,t,e){var i={};if(n&&n.length){for(var r=0,s=n;r"u"||(y.innerHTML=v.innerHTML?v.innerHTML:"",void 0!==v.className&&(y.className=v.className),void 0!==v.id&&(y.id=v.id),void 0!==v.styles&&y.setAttribute("style",v.styles),void 0!==e.ngAttr&&y.setAttribute(e.ngAttr,""),void 0!==v.attrs&&Fe(y,v.attrs)),y};for(var i=0,r=e.tags;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s}function jZ(n){for(var t,e=n.childNodes,i=0;i"u"&&(c["".concat(o)]=[]),c["".concat(o)].push(h),h.rootNodes}}});var Sl,cd,Sh,Wg,lc,po,YZ=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Na=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Jo_RTL=(new Ng,"e-rtl"),ys=function(n){function t(e,i){return n.call(this,e,i)||this}return YZ(t,n),t.prototype.preRender=function(){},t.prototype.render=function(){this.initialize(),this.removeRippleEffect=function ms(n,t,e){var i=function q$(n){return{selector:n&&n.selector?n.selector:null,ignore:n&&n.ignore?n.ignore:null,rippleFlag:n&&n.rippleFlag,isCenterRipple:n&&n.isCenterRipple,duration:n&&n.duration?n.duration:350}}(t);return!1===i.rippleFlag||void 0===i.rippleFlag&&!Zo?function(){}:(n.setAttribute("data-ripple","true"),E.add(n,"mousedown",Zz,{parent:n,rippleOptions:i}),E.add(n,"mouseup",Jz,{parent:n,rippleOptions:i,done:e}),E.add(n,"mouseleave",hf,{parent:n,rippleOptions:i}),X.isPointer&&E.add(n,"transitionend",hf,{parent:n,rippleOptions:i}),function(){n.removeAttribute("data-ripple"),E.remove(n,"mousedown",Zz),E.remove(n,"mouseup",Jz),E.remove(n,"mouseleave",hf),E.remove(n,"transitionend",hf)})}(this.element,{selector:".e-btn"}),this.renderComplete()},t.prototype.initialize=function(){if(this.cssClass&&V([this.element],this.cssClass.replace(/\s+/g," ").trim().split(" ")),this.isPrimary&&this.element.classList.add("e-primary"),!ce()||ce()&&"progress-btn"!==this.getModuleName()){if(this.content){var e=this.enableHtmlSanitizer?Ai.sanitize(this.content):this.content;this.element.innerHTML=e}this.setIconCss()}this.enableRtl&&this.element.classList.add(Jo_RTL),this.disabled?this.controlStatus(this.disabled):this.wireEvents()},t.prototype.controlStatus=function(e){this.element.disabled=e},t.prototype.setIconCss=function(){if(this.iconCss){var e=this.createElement("span",{className:"e-btn-icon "+this.iconCss});this.element.textContent.trim()?(e.classList.add("e-icon-"+this.iconPosition.toLowerCase()),("Top"===this.iconPosition||"Bottom"===this.iconPosition)&&this.element.classList.add("e-"+this.iconPosition.toLowerCase()+"-icon-btn")):this.element.classList.add("e-icon-btn");var i=this.element.childNodes[0];!i||"Left"!==this.iconPosition&&"Top"!==this.iconPosition?this.element.appendChild(e):this.element.insertBefore(e,i)}},t.prototype.wireEvents=function(){this.isToggle&&E.add(this.element,"click",this.btnClickHandler,this)},t.prototype.unWireEvents=function(){this.isToggle&&E.remove(this.element,"click",this.btnClickHandler)},t.prototype.btnClickHandler=function(){this.element.classList.contains("e-active")?this.element.classList.remove("e-active"):this.element.classList.add("e-active")},t.prototype.destroy=function(){var e=["e-primary",Jo_RTL,"e-icon-btn","e-success","e-info","e-danger","e-warning","e-flat","e-outline","e-small","e-bigger","e-active","e-round","e-top-icon-btn","e-bottom-icon-btn"];this.cssClass&&(e=e.concat(this.cssClass.split(" "))),n.prototype.destroy.call(this),K([this.element],e),this.element.getAttribute("class")||this.element.removeAttribute("class"),this.disabled&&this.element.removeAttribute("disabled"),this.content&&(this.element.innerHTML=this.element.innerHTML.replace(this.content,""));var i=this.element.querySelector("span.e-btn-icon");i&&he(i),this.unWireEvents(),Zo&&this.removeRippleEffect()},t.prototype.getModuleName=function(){return"btn"},t.prototype.getPersistData=function(){return this.addOnPersist([])},t.Inject=function(){},t.prototype.onPropertyChanged=function(e,i){for(var r=this.element.querySelector("span.e-btn-icon"),s=0,o=Object.keys(e);s=cd.width?cd.width:0;return Sl.right+JR()-n}function fE(){return W0()+Sl.width/2}function pE(n,t,e,i){if(void 0===t&&(t=null),void 0===e&&(e={X:!1,Y:!1}),!e.Y&&!e.X)return{left:0,top:0};var r=n.getBoundingClientRect();if(po=t,lc=n.ownerDocument,i||(i=ns(n,"left","top")),e.X){var s=po?r4():l4(),o=SE(),a=IE(),l=o-i.left,h=i.left+r.width-a;r.width>s?i.left=l>0&&h<=0?a-r.width:h>0&&l<=0?o:l>h?a-r.width:o:l>0?i.left+=l:h>0&&(i.left-=h)}if(e.Y){var c=po?n4():a4(),d=yE(),u=bE(),f=d-i.top,p=i.top+r.height-u;r.height>c?i.top=f>0&&p<=0?u-r.height:p>0&&f<=0?d:f>p?u-r.height:d:f>0?i.top+=f:p>0&&(i.top-=p)}return i}function hc(n,t,e,i){void 0===t&&(t=null);var r=ns(n,"left","top");e&&(r.left=e),i&&(r.top=i);var s=[];po=t,lc=n.ownerDocument;var o=n.getBoundingClientRect(),l=r.left,h=r.left+o.width,d=mE(r.top,r.top+o.height),u=e4(l,h);return d.topSide&&s.push("top"),u.rightSide&&s.push("right"),u.leftSide&&s.push("left"),d.bottomSide&&s.push("bottom"),s}function bJ(n,t,e,i,r,s,o,a,l){if(void 0===o&&(o=null),void 0===a&&(a={X:!0,Y:!0}),t&&n&&r&&s&&(a.X||a.Y)){var d,h={TL:null,TR:null,BL:null,BR:null},c={TL:null,TR:null,BL:null,BR:null};if("none"===window.getComputedStyle(n).display){var u=n.style.visibility;n.style.visibility="hidden",n.style.display="block",d=n.getBoundingClientRect(),n.style.removeProperty("display"),n.style.visibility=u}else d=n.getBoundingClientRect();var f={posX:r,posY:s,offsetX:e,offsetY:i,position:{left:0,top:0}};po=o,lc=t.ownerDocument,function wJ(n,t,e,i,r){e.position=ns(n,e.posX,e.posY,i,r),t.TL=ns(n,"left","top",i,r),t.TR=ns(n,"right","top",i,r),t.BR=ns(n,"left","bottom",i,r),t.BL=ns(n,"right","bottom",i,r)}(t,h,f,l,d),vE(c,f,d),a.X&&t4(t,c,h,f,d,!0),a.Y&&h.TL.top>-1&&i4(t,c,h,f,d,!0),function MJ(n,t,e){var i=0,r=0;if(null!=n.offsetParent&&("absolute"===getComputedStyle(n.offsetParent).position||"relative"===getComputedStyle(n.offsetParent).position)){var s=ns(n.offsetParent,"left","top",!1,e);i=s.left,r=s.top}var o=1,a=1,l=KR(n);if(l){var h=getComputedStyle(l).transform;if("none"!==h){var c=new DOMMatrix(h);o=c.a,a=c.d}if("none"!==getComputedStyle(l).zoom){var u=gE(document.body);o*=u,a*=u}}n.style.top=t.position.top/a+t.offsetY-r/a+"px",n.style.left=t.position.left/o+t.offsetX-i/o+"px"}(n,f,d)}}function gE(n){var t=getComputedStyle(n).zoom;return parseFloat(t)||1}function KR(n){for(;n;){var t=window.getComputedStyle(n).transform,e=gE(document.body);if(t&&"none"!==t||e&&1!==e)return n;if(n===document.body)return null;n=n.offsetParent||n.parentElement}return null}function vE(n,t,e){n.TL={top:t.position.top+t.offsetY,left:t.position.left+t.offsetX},n.TR={top:n.TL.top,left:n.TL.left+e.width},n.BL={top:n.TL.top+e.height,left:n.TL.left},n.BR={top:n.TL.top+e.height,left:n.TL.left+e.width}}function e4(n,t){var e=!1,i=!1;return n-Q0()IE()&&(i=!0),{leftSide:e,rightSide:i}}function t4(n,t,e,i,r,s){var o=e4(t.TL.left,t.TR.left),a=mE(t.TL.top,t.BL.top);e.TL.left-Q0()<=SE()&&(o.leftSide=!1),e.TR.left>IE()&&(o.rightSide=!1),(o.leftSide&&!o.rightSide||!o.leftSide&&o.rightSide)&&(i.posX="right"===i.posX?"left":"right",i.offsetX=i.offsetX+r.width,i.offsetX=-1*i.offsetX,i.position=ns(n,i.posX,i.posY,!1),vE(t,i,r),s&&t4(n,t,e,i,r,!1),!o.leftSide&&o.rightSide&&a.bottomSide&&(i.offsetX=0))}function i4(n,t,e,i,r,s){var o=mE(t.TL.top,t.BL.top);e.TL.top-Y0()<=yE()&&(o.topSide=!1),e.BL.top>=bE()&&n.getBoundingClientRect().bottombE()&&(i=!0),{topSide:e,bottomSide:i}}function r4(){return po.getBoundingClientRect().width}function n4(){return po.getBoundingClientRect().height}function s4(){return po.getBoundingClientRect().left}function o4(){return po.getBoundingClientRect().top}function yE(){return po?o4():0}function SE(){return po?s4():0}function IE(){return po?Q0()+s4()+r4():Q0()+l4()}function bE(){return po?Y0()+o4()+n4():Y0()+a4()}function Y0(){return lc.documentElement.scrollTop||lc.body.scrollTop}function Q0(){return lc.documentElement.scrollLeft||lc.body.scrollLeft}function a4(){return window.innerHeight}function l4(){var n=window.innerWidth,t=document.documentElement.getBoundingClientRect();return n-(n-(m(document.documentElement)?0:t.width))}function h4(){po=null,lc=null}var c4=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),bn=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},d4=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return c4(t,n),bn([I("left")],t.prototype,"X",void 0),bn([I("top")],t.prototype,"Y",void 0),t}(Ee),qn_OPEN="e-popup-open",qn_CLOSE="e-popup-close",cc=function(n){function t(e,i){return n.call(this,i,e)||this}return c4(t,n),t.prototype.onPropertyChanged=function(e,i){for(var r=0,s=Object.keys(e);r0&&c.left>0&&c.right>0&&c.bottom>0}var s=i.getBoundingClientRect();return!(r.bottoms.bottom||r.right>s.right||r.leftr.top?this.element.style.top="0px":s.bottomr.left&&(this.element.style.left=parseInt(this.element.style.left,10)+(s.left-r.left)+"px"))}},t.prototype.checkCollision=function(){var e=this.collision.X,i=this.collision.Y;"none"===e&&"none"===i||("flip"===e&&"flip"===i?this.callFlip({X:!0,Y:!0}):"fit"===e&&"fit"===i?this.callFit({X:!0,Y:!0}):("flip"===e?this.callFlip({X:!0,Y:!1}):"flip"===i&&this.callFlip({Y:!0,X:!1}),"fit"===e?this.callFit({X:!0,Y:!1}):"fit"===i&&this.callFit({X:!1,Y:!0})))},t.prototype.show=function(e,i){var r=this;if(this.getRelateToElement().classList.contains("e-filemanager")&&(this.fmDialogContainer=this.element.getElementsByClassName("e-file-select-wrap")[0]),this.wireEvents(),!m(this.fmDialogContainer)&&X.isIos&&(this.fmDialogContainer.style.display="block"),1e3===this.zIndex||!m(i)){var o=m(i)?this.element:i;this.zIndex=dc(o),je(this.element,{zIndex:this.zIndex})}e=m(e)||"object"!=typeof e?this.showAnimation:e,("none"!==this.collision.X||"none"!==this.collision.Y)&&(K([this.element],qn_CLOSE),V([this.element],qn_OPEN),this.checkCollision(),K([this.element],qn_OPEN),V([this.element],qn_CLOSE)),m(e)?(K([this.element],qn_CLOSE),V([this.element],qn_OPEN),this.trigger("open")):(e.begin=function(){r.isDestroyed||(K([r.element],qn_CLOSE),V([r.element],qn_OPEN))},e.end=function(){r.isDestroyed||r.trigger("open")},new Hs(e).animate(this.element))},t.prototype.hide=function(e){var i=this;e=m(e)||"object"!=typeof e?this.hideAnimation:e,m(e)?(K([this.element],qn_OPEN),V([this.element],qn_CLOSE),this.trigger("close")):(e.end=function(){i.isDestroyed||(K([i.element],qn_OPEN),V([i.element],qn_CLOSE),i.trigger("close"))},new Hs(e).animate(this.element)),this.unwireEvents()},t.prototype.getScrollableParent=function(e){return this.checkFixedParent(e),function ME(n,t){for(var e=getComputedStyle(n),i=[],r=/(auto|scroll)/,s=n.parentElement;s&&"HTML"!==s.tagName;){var o=getComputedStyle(s);!("absolute"===e.position&&"static"===o.position)&&r.test(o.overflow+o.overflowY+o.overflowX)&&i.push(s),s=s.parentElement}return t||i.push(document),i}(e,this.fixedParent)},t.prototype.checkFixedParent=function(e){for(var i=e.parentElement;i&&"HTML"!==i.tagName;){var r=getComputedStyle(i);("fixed"===r.position||"sticky"===r.position)&&!m(this.element)&&this.element.offsetParent&&"BODY"===this.element.offsetParent.tagName&&"hidden"!==getComputedStyle(this.element.offsetParent).overflow&&(this.element.style.top=window.scrollY>parseInt(this.element.style.top,10)?Re(window.scrollY-parseInt(this.element.style.top,10)):Re(parseInt(this.element.style.top,10)-window.scrollY),this.element.style.position="fixed",this.fixedParent=!0),i=i.parentElement,!m(this.element)&&m(this.element.offsetParent)&&"fixed"===r.position&&"fixed"===this.element.style.position&&(this.fixedParent=!0)}},bn([I("auto")],t.prototype,"height",void 0),bn([I("auto")],t.prototype,"width",void 0),bn([I(null)],t.prototype,"content",void 0),bn([I("container")],t.prototype,"targetType",void 0),bn([I(null)],t.prototype,"viewPortElement",void 0),bn([I({X:"none",Y:"none"})],t.prototype,"collision",void 0),bn([I("")],t.prototype,"relateTo",void 0),bn([re({},d4)],t.prototype,"position",void 0),bn([I(0)],t.prototype,"offsetX",void 0),bn([I(0)],t.prototype,"offsetY",void 0),bn([I(1e3)],t.prototype,"zIndex",void 0),bn([I(!1)],t.prototype,"enableRtl",void 0),bn([I("reposition")],t.prototype,"actionOnScroll",void 0),bn([I(null)],t.prototype,"showAnimation",void 0),bn([I(null)],t.prototype,"hideAnimation",void 0),bn([H()],t.prototype,"open",void 0),bn([H()],t.prototype,"close",void 0),bn([H()],t.prototype,"targetExitViewport",void 0),bn([Ft],t)}(Ii);function dc(n){for(var t=n.parentElement,e=[];t&&"BODY"!==t.tagName;){var i=document.defaultView.getComputedStyle(t,null).getPropertyValue("z-index"),r=document.defaultView.getComputedStyle(t,null).getPropertyValue("position");"auto"!==i&&"static"!==r&&e.push(i),t=t.parentElement}for(var s=[],o=0;o2147483647?2147483647:c}var Ui,ka,ff,Mh,DE,wh,$t,Ch,wE=["north-west","north","north-east","west","east","south-west","south","south-east"],Yg="e-resize-handle",uc="e-focused-handle",CJ="e-dlg-resizable",u4=["e-restrict-left"],f4="e-resize-viewport",EJ=["north","west","east","south"],CE=0,EE=0,p4=0,g4=0,Qg=0,Gg=0,Xg=null,xE=null,TE=null,G0=!0,v4=0,AE=!0;function xJ(n){LE();var t=Si("span",{attrs:{unselectable:"on",contenteditable:"false"}});t.setAttribute("class","e-dialog-border-resize e-"+n),"south"===n&&(t.style.height="2px",t.style.width="100%",t.style.bottom="0px",t.style.left="0px"),"north"===n&&(t.style.height="2px",t.style.width="100%",t.style.top="0px",t.style.left="0px"),"east"===n&&(t.style.height="100%",t.style.width="2px",t.style.right="0px",t.style.top="0px"),"west"===n&&(t.style.height="100%",t.style.width="2px",t.style.left="0px",t.style.top="0px"),Ui.appendChild(t)}function m4(n){var t;return m(n)||(t="string"==typeof n?document.querySelector(n):n),t}function y4(n){for(var t=n||this,e=Ui.querySelectorAll("."+Yg),i=0;i-1?"mouse":"touch"}function I4(n){if(n.preventDefault(),Ui=n.target.parentElement,LE(),Qg=n.pageX,Gg=n.pageY,n.target.classList.add(uc),m(Xg)||!0!==Xg(n,this)){this.targetEle&&Ui&&Ui.querySelector("."+CJ)&&($t="body"===this.target?null:this.targetEle,wh=this.targetEle.clientWidth,Mh=this.targetEle.clientHeight);var e=m($t)?document:$t;E.add(e,"mousemove",qg,this),E.add(document,"mouseup",X0,this);for(var i=0;i=0||s.top<0)&&(e=!0):e=!0;var a=EE+(r-Gg);a=a>ff?a:ff;var l=0;m($t)||(l=o.top);var h=m($t)?0:$t.offsetHeight-$t.clientHeight,c=s.top-l-h/2;if(c=c<0?0:c,s.top>0&&c+a>Mh){if(e=!1,Ui.classList.contains(f4))return;Ui.style.height=Mh-parseInt(c.toString(),10)+"px"}else{var d=0;if(e){s.top<0&&t+(s.height+s.top)>0&&a+(d=s.top)<=30&&(a=s.height-(s.height+s.top)+30),a+s.top>=Mh&&(Ui.style.height=s.height+(t-(s.height+s.top))+"px");var u=m($t)?d:c;a>=ff&&a+u<=Mh&&(Ui.style.height=a+"px")}}}function OE(n){var e,t=!1,i="mouse"===S4(n.type)?n.pageY:n.touches[0].pageY,r=fc(Ui),s=m($t)?0:$t.offsetHeight-$t.clientHeight;m($t)||(e=fc($t)),(!m($t)&&r.top-e.top>0||m($t)&&i>0||!m($t)&&Math.floor(r.top-e.top+r.height+(e.bottom-r.bottom))-s<=Mh)&&(t=!0);var o=EE-(i-Gg);if(t&&o>=ff&&o<=Mh){var a=0;m($t)||(a=e.top);var l=g4-a+(i-Gg);l=l>0?l:1,Ui.style.height=o+"px",Ui.style.top=l+"px"}}function kE(n){var i,t=document.documentElement.clientWidth,e=!1;m($t)||(i=fc($t));var r="mouse"===S4(n.type)?n.pageX:n.touches[0].pageX,s=fc(Ui),o=m($t)?0:$t.offsetWidth-$t.clientWidth,a=m($t)?0:i.left,l=m($t)?0:i.width;m(Ch)&&(m($t)?Ch=t:(Ch=s.left-a-o/2+s.width,Ch+=l-o-Ch)),(!m($t)&&Math.floor(s.left-i.left+s.width+(i.right-s.right))-o<=wh||m($t)&&r>=0)&&(e=!0);var h=CE-(r-Qg);if(G0&&(h=h>Ch?Ch:h),e&&h>=DE&&h<=wh){var c=0;m($t)||(c=i.left);var d=p4-c+(r-Qg);d=d>0?d:1,h!==v4&&AE&&(Ui.style.width=h+"px"),G0&&(Ui.style.left=d+"px",AE=1!==d)}v4=h}function PE(n){var i,t=document.documentElement.clientWidth,e=!1;m($t)||(i=fc($t));var s=(n.touches?n.changedTouches[0]:n).pageX,o=fc(Ui);(!m($t)&&(o.left-i.left+o.width<=wh||o.right-i.left>=o.width)||m($t)&&t-s>0)&&(e=!0);var a=CE+(s-Qg),l=0;if(m($t)||(l=i.left),o.left-l+a>wh){if(e=!1,Ui.classList.contains(f4))return;Ui.style.width=wh-(o.left-l)+"px"}e&&a>=DE&&a<=wh&&(Ui.style.width=a+"px")}function M4(){for(var n=Ui.querySelectorAll("."+Yg),t=0;t=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},OJ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return zE(t,n),Zt([I(!0)],t.prototype,"isFlat",void 0),Zt([I()],t.prototype,"buttonModel",void 0),Zt([I("Button")],t.prototype,"type",void 0),Zt([H()],t.prototype,"click",void 0),t}(Ee),kJ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return zE(t,n),Zt([I("Fade")],t.prototype,"effect",void 0),Zt([I(400)],t.prototype,"duration",void 0),Zt([I(0)],t.prototype,"delay",void 0),t}(Ee),q0="e-dialog",RE="e-rtl",HE="e-dlg-header-content",w4="e-dlg-header",$0="e-footer-content",Z0="e-dlg-modal",C4="e-icon-dlg-close",Pa="e-dlg-target",ea="e-scroll-disabled",E4="e-device",J0="e-dlg-fullscreen",D4="e-dlg-closeicon-btn",x4="e-popup-open",T4="Information",A4="e-scroll-disabled",L4="e-alert-dialog",N4="e-confirm-dialog",BE="e-dlg-resizable",pf="e-restrict-left",O4="e-resize-viewport",FE="user action",QJ=function(n){function t(e,i){var r=n.call(this,e,i)||this;return r.needsID=!0,r}return zE(t,n),t.prototype.render=function(){this.initialize(),this.initRender(),this.wireEvents(),"100%"===this.width&&(this.element.style.width=""),""!==this.minHeight&&(this.element.style.minHeight=Re(this.minHeight)),this.enableResize&&(this.setResize(),this.isModal&&(this.isModelResize=!0),"None"===this.animationSettings.effect&&this.getMinHeight()),this.renderComplete()},t.prototype.initializeValue=function(){this.dlgClosedBy=FE},t.prototype.preRender=function(){var e=this;if(this.initializeValue(),this.headerContent=null,this.allowMaxHeight=!0,this.preventVisibility=!0,this.clonedEle=this.element.cloneNode(!0),this.closeIconClickEventHandler=function(s){e.dlgClosedBy="close icon",e.hide(s)},this.dlgOverlayClickEventHandler=function(s){e.dlgClosedBy="overlayClick",s.preventFocus=!1,e.trigger("overlayClick",s,function(o){o.preventFocus||e.focusContent(),e.dlgClosedBy=FE})},this.l10n=new uo("dialog",{close:"Close"},this.locale),this.checkPositionData(),m(this.target)){var r=this.isProtectedOnChange;this.isProtectedOnChange=!0,this.target=document.body,this.isProtectedOnChange=r}},t.prototype.updatePersistData=function(){this.enablePersistence&&this.setProperties({width:parseFloat(this.element.style.width),height:parseFloat(this.element.style.height),position:{X:parseFloat(this.dragObj.element.style.left),Y:parseFloat(this.dragObj.element.style.top)}},!0)},t.prototype.isNumberValue=function(e){return/^[-+]?\d*\.?\d+$/.test(e)},t.prototype.checkPositionData=function(){if(!m(this.position)){if(!m(this.position.X)&&"number"!=typeof this.position.X&&this.isNumberValue(this.position.X)){var i=this.isProtectedOnChange;this.isProtectedOnChange=!0,this.position.X=parseFloat(this.position.X),this.isProtectedOnChange=i}m(this.position.Y)||"number"==typeof this.position.Y||this.isNumberValue(this.position.Y)&&(i=this.isProtectedOnChange,this.isProtectedOnChange=!0,this.position.Y=parseFloat(this.position.Y),this.isProtectedOnChange=i)}},t.prototype.getEle=function(e,i){for(var r=void 0,s=0;s=0&&t[e])xJ(t[e]);else if(""!==t[e].trim()){var i=Si("div",{className:"e-icons "+Yg+" e-"+t[e]});Ui.appendChild(i)}ff=n.minHeight,DE=n.minWidth,wh=n.maxWidth,Mh=n.maxHeight,n.proxy&&n.proxy.element&&n.proxy.element.classList.contains("e-dialog")?y4(n.proxy):y4()}({element:this.element,direction:r,minHeight:parseInt(e.slice(0,i.indexOf("p")),10),maxHeight:this.targetEle.clientHeight,minWidth:parseInt(i.slice(0,i.indexOf("p")),10),maxWidth:this.targetEle.clientWidth,boundary:this.target===document.body?null:this.targetEle,resizeBegin:this.onResizeStart.bind(this),resizeComplete:this.onResizeComplete.bind(this),resizing:this.onResizing.bind(this),proxy:this}),this.wireWindowResizeEvent()}else M4(),this.unWireWindowResizeEvent(),this.element.classList.remove(this.isModal?pf:O4),this.element.classList.remove(BE)},t.prototype.getFocusElement=function(e){var r=e.querySelectorAll('input,select,textarea,button:enabled,a,[contenteditable="true"],[tabindex]');return{element:r[r.length-1]}},t.prototype.keyDown=function(e){var i=this;if(9===e.keyCode&&this.isModal){var r=void 0;m(this.btnObj)||(r=this.btnObj[this.btnObj.length-1]),m(this.btnObj)&&!m(this.ftrTemplateContent)&&(r=this.getFocusElement(this.ftrTemplateContent)),m(this.btnObj)&&m(this.ftrTemplateContent)&&!m(this.contentEle)&&(r=this.getFocusElement(this.contentEle)),!m(r)&&document.activeElement===r.element&&!e.shiftKey&&(e.preventDefault(),this.focusableElements(this.element).focus()),document.activeElement===this.focusableElements(this.element)&&e.shiftKey&&(e.preventDefault(),m(r)||r.element.focus())}var h,s=document.activeElement,o=["input","textarea"].indexOf(s.tagName.toLowerCase())>-1,a=!1;if(o||(a=s.hasAttribute("contenteditable")&&"true"===s.getAttribute("contenteditable")),27===e.keyCode&&this.closeOnEscape){this.dlgClosedBy="escape";var l=document.querySelector(".e-popup-open:not(.e-dialog)");!m(l)&&!l.classList.contains("e-toolbar-pop")&&!l.classList.contains("e-slider-tooltip")||this.hide(e)}(13===e.keyCode&&!e.ctrlKey&&"textarea"!==s.tagName.toLowerCase()&&o&&!m(this.primaryButtonEle)||13===e.keyCode&&e.ctrlKey&&("textarea"===s.tagName.toLowerCase()||a)&&!m(this.primaryButtonEle))&&this.buttons.some(function(d,u){h=u;var f=d.buttonModel;return!m(f)&&!0===f.isPrimary})&&"function"==typeof this.buttons[h].click&&setTimeout(function(){i.buttons[h].click.call(i,e)})},t.prototype.initialize=function(){m(this.target)||(this.targetEle="string"==typeof this.target?document.querySelector(this.target):this.target),this.isBlazorServerRender()||V([this.element],q0),X.isDevice&&V([this.element],E4),this.isBlazorServerRender()||this.setCSSClass(),this.setMaxHeight()},t.prototype.initRender=function(){var e=this;if(this.initialRender=!0,this.isBlazorServerRender()||Fe(this.element,{role:"dialog"}),1e3===this.zIndex?(this.setzIndex(this.element,!1),this.calculatezIndex=!0):this.calculatezIndex=!1,this.setTargetContent(),""!==this.header&&!m(this.header)&&this.setHeader(),this.renderCloseIcon(),this.setContent(),""===this.footerTemplate||m(this.footerTemplate)?!m(this.buttons[0])&&!m(this.buttons[0].buttonModel)&&this.setButton():this.setFooterTemplate(),this.allowDragging&&!m(this.headerContent)&&this.setAllowDragging(),Fe(this.element,{"aria-modal":this.isModal?"true":"false"}),this.isModal&&this.setIsModal(),!0!==this.element.classList.contains(L4)&&!0!==this.element.classList.contains(N4)&&!m(this.element.parentElement)){var i=this.isModal?this.dlgContainer.parentElement:this.element.parentElement;this.refElement=this.createElement("div",{className:"e-dlg-ref-element"}),i.insertBefore(this.refElement,this.isModal?this.dlgContainer:this.element)}if(m(this.targetEle)||this.targetEle.appendChild(this.isModal?this.dlgContainer:this.element),this.popupObj=new cc(this.element,{height:this.height,width:this.width,zIndex:this.zIndex,relateTo:this.target,actionOnScroll:"none",enableRtl:this.enableRtl,open:function(o){var a={container:e.isModal?e.dlgContainer:e.element,element:e.element,target:e.target,preventFocus:!1};e.enableResize&&e.resetResizeIcon(),e.trigger("open",a,function(l){l.preventFocus||e.focusContent()})},close:function(o){e.isModal&&V([e.dlgOverlay],"e-fade"),e.unBindEvent(e.element),e.isModal&&(e.dlgContainer.style.display="none"),e.trigger("close",e.closeArgs);var a=document.activeElement;!m(a)&&!m(a.blur)&&a.blur(),!m(e.storeActiveElement)&&!m(e.storeActiveElement.focus)&&e.storeActiveElement.focus()}}),this.positionChange(),this.setEnableRTL(),this.isBlazorServerRender()||(V([this.element],"e-popup-close"),this.isModal&&this.setOverlayZindex()),this.visible){if(this.show(),this.isModal){var r=this.getTargetContainer(this.target);r instanceof Element&&"rtl"===window.getComputedStyle(r).getPropertyValue("direction")&&this.setPopupPosition()}}else this.isModal&&(this.dlgOverlay.style.display="none");this.initialRender=!1},t.prototype.getTargetContainer=function(e){var i=null;if("string"==typeof e)if(e.startsWith("#"))i=document.getElementById(e.substring(1));else if(e.startsWith(".")){var r=document.getElementsByClassName(e.substring(1));i=r.length>0?r[0]:null}else!(e instanceof HTMLElement)&&e!==document.body&&(i=document.querySelector(e));else e instanceof HTMLElement&&(i=e);return i},t.prototype.resetResizeIcon=function(){var e=this.getMinHeight();if(this.targetEle.offsetHeight0&&("function"==typeof this.buttons[e].click&&E.add(s[e],"click",this.buttons[e].click,this),"object"==typeof this.buttons[e].click&&E.add(s[e],"click",this.buttonClickHandler.bind(this,e),this)),!this.isBlazorServerRender()&&!m(this.ftrTemplateContent)&&(this.btnObj[e].appendTo(this.ftrTemplateContent.children[e]),this.buttons[e].isFlat&&this.btnObj[e].element.classList.add("e-flat"),this.primaryButtonEle=this.element.getElementsByClassName("e-primary")[0]))},t.prototype.buttonClickHandler=function(e){this.trigger("buttons["+e+"].click",{})},t.prototype.setContent=function(){this.contentEle=this.createElement("div",{className:"e-dlg-content",id:this.element.id+"_dialog-content"}),Fe(this.element,this.headerEle?{"aria-describedby":this.element.id+"_title "+this.element.id+"_dialog-content"}:{"aria-describedby":this.element.id+"_dialog-content"}),this.innerContentElement?this.contentEle.appendChild(this.innerContentElement):(!m(this.content)&&""!==this.content||!this.initialRender)&&(("string"!=typeof this.content||ce())&&this.content instanceof HTMLElement?this.contentEle.appendChild(this.content):this.setTemplate(this.content,this.contentEle,"content")),m(this.headerContent)?this.element.insertBefore(this.contentEle,this.element.children[0]):this.element.insertBefore(this.contentEle,this.element.children[1]),"auto"===this.height&&(!this.isBlazorServerRender()&&X.isIE&&""===this.element.style.width&&!m(this.width)&&(this.element.style.width=Re(this.width)),this.setMaxHeight())},t.prototype.setTemplate=function(e,i,r){var s,o,a;o=i.classList.contains(w4)?this.element.id+"header":i.classList.contains($0)?this.element.id+"footerTemplate":this.element.id+"content",m(e.outerHTML)?("string"==typeof e||"string"!=typeof e||ce()&&!this.isStringTemplate)&&("string"==typeof e&&(e=this.sanitizeHelper(e)),this.isVue||"string"!=typeof e?(s=si(e),a=e):i.innerHTML=e):i.appendChild(e);var l=[];if(!m(s)){for(var c=0,d=s({},this,r,o,!(ce()&&!this.isStringTemplate&&0===a.indexOf("
Blazor"))||this.isStringTemplate);c/g,"");(this.element.children.length>0||i)&&(this.innerContentElement=document.createDocumentFragment(),[].slice.call(this.element.childNodes).forEach(function(r){8!==r.nodeType&&e.innerContentElement.appendChild(r)}))}},t.prototype.setHeader=function(){this.headerEle?this.headerEle.innerHTML="":this.headerEle=this.createElement("div",{id:this.element.id+"_title",className:w4}),this.createHeaderContent(),this.headerContent.appendChild(this.headerEle),this.setTemplate(this.header,this.headerEle,"header"),Fe(this.element,{"aria-describedby":this.element.id+"_title"}),Fe(this.element,{"aria-labelledby":this.element.id+"_dialog-header"}),this.element.insertBefore(this.headerContent,this.element.children[0]),this.allowDragging&&!m(this.headerContent)&&this.setAllowDragging()},t.prototype.setFooterTemplate=function(){this.ftrTemplateContent?this.ftrTemplateContent.innerHTML="":this.ftrTemplateContent=this.createElement("div",{className:$0}),""===this.footerTemplate||m(this.footerTemplate)?this.ftrTemplateContent.innerHTML=this.buttonContent.join(""):this.setTemplate(this.footerTemplate,this.ftrTemplateContent,"footerTemplate"),this.element.appendChild(this.ftrTemplateContent)},t.prototype.createHeaderContent=function(){m(this.headerContent)&&(this.headerContent=this.createElement("div",{id:this.element.id+"_dialog-header",className:HE}))},t.prototype.renderCloseIcon=function(){this.showCloseIcon&&(this.closeIcon=this.createElement("button",{className:D4,attrs:{type:"button"}}),this.closeIconBtnObj=new ys({cssClass:"e-flat",iconCss:C4+" e-icons"}),this.closeIconTitle(),m(this.headerContent)?(this.createHeaderContent(),gl([this.closeIcon],this.headerContent),this.element.insertBefore(this.headerContent,this.element.children[0])):gl([this.closeIcon],this.headerContent),this.closeIconBtnObj.appendTo(this.closeIcon))},t.prototype.closeIconTitle=function(){this.l10n.setLocale(this.locale);var e=this.l10n.getConstant("close");this.closeIcon.setAttribute("title",e),this.closeIcon.setAttribute("aria-label",e)},t.prototype.setCSSClass=function(e){e&&(K([this.element],e.split(" ")),this.isModal&&!m(this.dlgContainer)&&K([this.dlgContainer],e.split(" "))),this.cssClass&&(V([this.element],this.cssClass.split(" ")),this.isModal&&!m(this.dlgContainer)&&V([this.dlgContainer],this.cssClass.split(" ")))},t.prototype.setIsModal=function(){this.dlgContainer=this.createElement("div",{className:"e-dlg-container"}),this.setCSSClass(),this.element.classList.remove(x4),this.element.parentNode.insertBefore(this.dlgContainer,this.element),this.dlgContainer.appendChild(this.element),V([this.element],Z0),this.dlgOverlay=this.createElement("div",{className:"e-dlg-overlay"}),this.dlgOverlay.style.zIndex=(this.zIndex-1).toString(),this.dlgContainer.appendChild(this.dlgOverlay)},t.prototype.getValidFocusNode=function(e){for(var i,r=0;r0||"a"===i.tagName.toLowerCase()&&i.hasAttribute("href"))&&i.tabIndex>-1&&!i.disabled&&!this.disableElement(i,'[disabled],[aria-disabled="true"],[type="hidden"]'))return i;i=null}return i},t.prototype.focusableElements=function(e){if(!m(e)){var r=e.querySelectorAll('input,select,textarea,button,a,[contenteditable="true"],[tabindex]');return this.getValidFocusNode(r)}return null},t.prototype.getAutoFocusNode=function(e){var i=e.querySelector("."+D4),s=e.querySelectorAll("[autofocus]"),o=this.getValidFocusNode(s);if(ce()&&(this.primaryButtonEle=this.element.getElementsByClassName("e-primary")[0]),m(o)){if(!m(o=this.focusableElements(this.contentEle)))return o;if(!m(this.primaryButtonEle))return this.element.querySelector(".e-primary")}else i=o;return i},t.prototype.disableElement=function(e,i){var r=e?e.matches||e.webkitMatchesSelector||e.msGetRegionContent:null;if(r)for(;e;e=e.parentNode)if(e instanceof Element&&r.call(e,i))return e;return null},t.prototype.focusContent=function(){var e=this.getAutoFocusNode(this.element),i=m(e)?this.element:e,r=X.userAgent;(r.indexOf("MSIE ")>0||r.indexOf("Trident/")>0)&&this.element.focus(),i.focus(),this.unBindEvent(this.element),this.bindEvent(this.element)},t.prototype.bindEvent=function(e){E.add(e,"keydown",this.keyDown,this)},t.prototype.unBindEvent=function(e){E.remove(e,"keydown",this.keyDown)},t.prototype.updateSanitizeContent=function(){this.isBlazorServerRender()||(this.contentEle.innerHTML=this.sanitizeHelper(this.content))},t.prototype.isBlazorServerRender=function(){return ce()&&this.isServerRendered},t.prototype.getModuleName=function(){return"dialog"},t.prototype.onPropertyChanged=function(e,i){if(this.element.classList.contains(q0))for(var r=0,s=Object.keys(e);r0?this.showCloseIcon||""!==this.header&&!m(this.header)?this.showCloseIcon||he(this.closeIcon):(he(this.headerContent),this.headerContent=null):(this.renderCloseIcon(),this.wireEvents());break;case"locale":this.showCloseIcon&&this.closeIconTitle();break;case"visible":this.visible?this.show():this.hide();break;case"isModal":this.updateIsModal();break;case"height":je(this.element,{height:Re(e.height)}),this.updatePersistData();break;case"width":je(this.element,{width:Re(e.width)}),this.updatePersistData();break;case"zIndex":this.popupObj.zIndex=this.zIndex,this.isModal&&this.setOverlayZindex(this.zIndex),this.element.style.zIndex!==this.zIndex.toString()&&(this.calculatezIndex=!1);break;case"cssClass":this.setCSSClass(i.cssClass);break;case"buttons":this.unWireButtonEvents(),this.destroyButtons(),m(this.ftrTemplateContent)||(he(this.ftrTemplateContent),this.ftrTemplateContent=null),this.footerTemplate="",this.setButton();break;case"allowDragging":this.allowDragging&&!m(this.headerContent)?this.setAllowDragging():this.dragObj.destroy();break;case"target":this.setTarget(e.target);break;case"position":if(this.checkPositionData(),this.isModal){var a=this.position.X,l=this.position.Y;m(i.position)||(m(i.position.X)||(a=i.position.X),m(i.position.Y)||(l=i.position.Y)),this.dlgContainer.classList.contains("e-dlg-"+a+"-"+l)&&this.dlgContainer.classList.remove("e-dlg-"+a+"-"+l)}this.positionChange(),this.updatePersistData();break;case"enableRtl":this.setEnableRTL();break;case"enableResize":this.setResize(),this.isModelResize=this.enableResize&&this.isModal,this.enableResize&&this.dialogOpen&&this.resetResizeIcon();break;case"minHeight":""!==this.minHeight&&(this.element.style.minHeight=Re(this.minHeight))}},t.prototype.setTarget=function(e){this.popupObj.relateTo=e,this.target=e,this.targetEle="string"==typeof this.target?document.querySelector(this.target):this.target,this.dragObj&&(this.dragObj.dragArea=this.targetEle),this.setMaxHeight(),this.isModal&&this.updateIsModal(),this.enableResize&&this.setResize(),m(this.targetEle)||(this.isModal&&!m(this.dlgContainer)?this.targetEle.appendChild(this.dlgContainer):m(this.element)||this.targetEle.appendChild(this.element))},t.prototype.updateIsModal=function(){if(this.element.setAttribute("aria-modal",this.isModal?"true":"false"),this.isModal)m(this.dlgOverlay)&&(this.setIsModal(),this.element.style.top="0px",this.element.style.left="0px",m(this.targetEle)||this.targetEle.appendChild(this.dlgContainer));else{for(K([this.element],Z0),K([document.body],[Pa,ea]),he(this.dlgOverlay);this.dlgContainer.firstChild;)this.dlgContainer.parentElement.insertBefore(this.dlgContainer.firstChild,this.dlgContainer);this.dlgContainer.parentElement.removeChild(this.dlgContainer)}this.visible&&this.show(),this.positionChange(),this.isModal&&this.dlgOverlay&&E.add(this.dlgOverlay,"click",this.dlgOverlayClickEventHandler,this)},t.prototype.setzIndex=function(e,i){var r=this.isProtectedOnChange;this.isProtectedOnChange=!0;var s=dc(e);this.zIndex=s>this.zIndex?s:this.zIndex,this.isProtectedOnChange=r,i&&(this.popupObj.zIndex=this.zIndex)},t.prototype.windowResizeHandler=function(){(function AJ(n){wh=n})(this.targetEle.clientWidth),function LJ(n){Mh=n}(this.targetEle.clientHeight),this.setMaxHeight()},t.prototype.getPersistData=function(){return this.addOnPersist(["width","height","position"])},t.prototype.removeAllChildren=function(e){for(;e.children[0];)this.removeAllChildren(e.children[0]),e.removeChild(e.children[0])},t.prototype.destroy=function(){if(!this.isDestroyed){var e=[RE,Z0,BE,pf,J0,E4],i=["role","aria-modal","aria-labelledby","aria-describedby","aria-grabbed","tabindex","style"];K([this.targetEle],[Pa,ea]),!m(this.element)&&this.element.classList.contains(J0)&&K([document.body],[Pa,ea]),this.isModal&&K([m(this.targetEle)?document.body:this.targetEle],ea),this.unWireEvents(),this.unWireButtonEvents(),this.destroyButtons(),m(this.closeIconBtnObj)||this.closeIconBtnObj.destroy(),m(this.dragObj)||this.dragObj.destroy(),!m(this.popupObj.element)&&this.popupObj.element.classList.contains("e-popup")&&this.popupObj.destroy(),K([this.element],e),!m(this.cssClass)&&""!==this.cssClass&&K([this.element],this.cssClass.split(" ")),!m(this.refElement)&&!m(this.refElement.parentElement)&&(this.refElement.parentElement.insertBefore(this.isModal?this.dlgContainer:this.element,this.refElement),he(this.refElement),this.refElement=void 0),this.isModal&&(he(this.dlgOverlay),this.dlgContainer.parentNode.insertBefore(this.element,this.dlgContainer),he(this.dlgContainer)),this.element.innerHTML=this.clonedEle.innerHTML;for(var r=0;r0&&""===this.footerTemplate&&this.ftrTemplateContent)for(var e=0;e=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},_E="e-tooltip",B4="e-icons",F4="e-tooltip-close",UE="e-tooltip-wrap",_4="e-tip-content",gf="e-arrow-tip",U4="e-arrow-tip-outer",K0="e-arrow-tip-inner",$g="e-tip-bottom",jE="e-tip-top",j4="e-tip-left",VE="e-tip-right",WE="e-popup",Zg="e-popup-open",YE="e-popup-close",eS="e-lib",V4="e-tooltip-popup-container",JJ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return P4(t,n),Gi([I({effect:"FadeIn",duration:150,delay:0})],t.prototype,"open",void 0),Gi([I({effect:"FadeOut",duration:150,delay:0})],t.prototype,"close",void 0),t}(Ee),Eh=function(n){function t(e,i){var r=n.call(this,e,i)||this;return r.mouseMoveEvent=null,r.mouseMoveTarget=null,r.containerElement=null,r.isBodyContainer=!0,r}return P4(t,n),t.prototype.initialize=function(){this.formatPosition(),V([this.element],_E)},t.prototype.formatPosition=function(){var e,i;this.position&&(0===this.position.indexOf("Top")||0===this.position.indexOf("Bottom")?(e=this.position.split(/(?=[A-Z])/),this.tooltipPositionY=e[0],this.tooltipPositionX=e[1]):(i=this.position.split(/(?=[A-Z])/),this.tooltipPositionX=i[0],this.tooltipPositionY=i[1]))},t.prototype.renderArrow=function(){this.setTipClass(this.position);var e=this.createElement("div",{className:gf+" "+this.tipClass});e.appendChild(this.createElement("div",{className:U4+" "+this.tipClass})),e.appendChild(this.createElement("div",{className:K0+" "+this.tipClass})),this.tooltipEle.appendChild(e)},t.prototype.setTipClass=function(e){this.tipClass=0===e.indexOf("Right")?j4:0===e.indexOf("Bottom")?jE:0===e.indexOf("Left")?VE:$g},t.prototype.renderPopup=function(e){var i=this.mouseTrail?{top:0,left:0}:this.getTooltipPosition(e);this.tooltipEle.classList.remove(eS),this.popupObj=new cc(this.tooltipEle,{height:this.height,width:this.width,position:{X:i.left,Y:i.top},enableRtl:this.enableRtl,open:this.openPopupHandler.bind(this),close:this.closePopupHandler.bind(this)})},t.prototype.getScalingFactor=function(e){if(!e)return{x:1,y:1};var i={x:1,y:1},r=e.closest('[style*="transform: scale"]');if(r&&r!==this.tooltipEle&&r.contains(this.tooltipEle)){var a=window.getComputedStyle(r).getPropertyValue("transform").match(/matrix\(([^)]+)\)/)[1].split(",").map(parseFloat);i.x=a[0],i.y=a[3]}return i},t.prototype.getTooltipPosition=function(e){this.tooltipEle.style.display="block";var i=this.element.closest('[style*="zoom"]');i&&(i.contains(this.tooltipEle)||(this.tooltipEle.style.zoom=getComputedStyle(i).zoom));var r=ns(e,this.tooltipPositionX,this.tooltipPositionY,!this.isBodyContainer,this.isBodyContainer?null:this.containerElement.getBoundingClientRect()),s=this.getScalingFactor(e),o=this.calculateTooltipOffset(this.position,s.x,s.y),a=this.calculateElementPosition(r,o),c=this.collisionFlipFit(e,a[0],a[1]);return c.left=c.left/s.x,c.top=c.top/s.y,this.tooltipEle.style.display="",c},t.prototype.windowResize=function(){this.reposition(this.findTarget())},t.prototype.reposition=function(e){if(this.popupObj&&e){var i=this.getTooltipPosition(e);this.popupObj.position={X:i.left,Y:i.top},this.popupObj.dataBind()}},t.prototype.openPopupHandler=function(){!this.mouseTrail&&this.needTemplateReposition()&&this.reposition(this.findTarget()),this.trigger("afterOpen",this.tooltipEventArgs),this.tooltipEventArgs=null},t.prototype.closePopupHandler=function(){this.isReact&&!("Click"===this.opensOn||"function"==typeof this.content)&&this.clearTemplate(["content"]),this.clear();var e={type:this.tooltipEventArgs.event?this.tooltipEventArgs.event.type:null,cancel:!1,target:this.tooltipEventArgs.target,event:this.tooltipEventArgs.event?this.tooltipEventArgs.event:null,element:this.tooltipEle,isInteracted:!m(this.tooltipEventArgs.event)};this.trigger("afterClose",e),e=null},t.prototype.calculateTooltipOffset=function(e,i,r){void 0===i&&(i=1),void 0===r&&(r=1);var o,a,l,h,c,d,u,f,s={top:0,left:0};if(1!==i||1!==r){var p=this.tooltipEle.getBoundingClientRect(),g=void 0;l=Math.round(p.width),h=Math.round(p.height),(c=_("."+gf,this.tooltipEle))&&(g=c.getBoundingClientRect()),o=c?Math.round(g.width):0,a=c?Math.round(g.height):0,d=this.showTipPointer?0:8,u=a/2+2+(h-this.tooltipEle.clientHeight*r),f=o/2+2+(l-this.tooltipEle.clientWidth*i)}else l=this.tooltipEle.offsetWidth,h=this.tooltipEle.offsetHeight,c=_("."+gf,this.tooltipEle),d=this.showTipPointer?0:8,u=(a=c?c.offsetHeight:0)/2+2+(this.tooltipEle.offsetHeight-this.tooltipEle.clientHeight),f=(o=c?c.offsetWidth:0)/2+2+(this.tooltipEle.offsetWidth-this.tooltipEle.clientWidth);switch(this.mouseTrail&&(d+=2),e){case"RightTop":s.left+=o+d,s.top-=h-u;break;case"RightCenter":s.left+=o+d,s.top-=h/2;break;case"RightBottom":s.left+=o+d,s.top-=u;break;case"BottomRight":s.top+=a+d,s.left-=f;break;case"BottomCenter":s.top+=a+d,s.left-=l/2;break;case"BottomLeft":s.top+=a+d,s.left-=l-f;break;case"LeftBottom":s.left-=o+l+d,s.top-=u;break;case"LeftCenter":s.left-=o+l+d,s.top-=h/2;break;case"LeftTop":s.left-=o+l+d,s.top-=h-u;break;case"TopLeft":s.top-=h+a+d,s.left-=l-f;break;case"TopRight":s.top-=h+a+d,s.left-=f;break;default:s.top-=h+a+d,s.left-=l/2}return s.left+=this.offsetX,s.top+=this.offsetY,s},t.prototype.updateTipPosition=function(e){var i=we("."+gf+",."+U4+",."+K0,this.tooltipEle);K(i,[$g,jE,j4,VE]),this.setTipClass(e),V(i,this.tipClass)},t.prototype.adjustArrow=function(e,i,r,s){var o=_("."+gf,this.tooltipEle);if(!1!==this.showTipPointer&&null!==o){var a,l;this.updateTipPosition(i),this.tooltipEle.style.display="block";var p,h=this.tooltipEle.clientWidth,c=this.tooltipEle.clientHeight,d=_("."+K0,this.tooltipEle),u=o.offsetWidth,f=o.offsetHeight;this.tooltipEle.style.display="",this.tipClass===$g||this.tipClass===jE?(this.tipClass===$g?(l="99.9%",d.style.top="-"+(f-2)+"px"):(l=-(f-1)+"px",d.style.top="-"+(f-6)+"px"),e&&(a=(p="Center"!==r||h>e.offsetWidth||this.mouseTrail)&&"Left"===r||!p&&"End"===this.tipPointerPosition?h-u-2+"px":p&&"Right"===r||!p&&"Start"===this.tipPointerPosition?"2px":!p||"End"!==this.tipPointerPosition&&"Start"!==this.tipPointerPosition?h/2-u/2+"px":"End"===this.tipPointerPosition?e.offsetWidth+(this.tooltipEle.offsetWidth-e.offsetWidth)/2-u/2-2+"px":(this.tooltipEle.offsetWidth-e.offsetWidth)/2-u/2+2+"px")):(this.tipClass===VE?(a="99.9%",d.style.left="-"+(u-2)+"px"):(a=-(u-1)+"px",d.style.left=u-2-u+"px"),l=(p="Center"!==s||c>e.offsetHeight||this.mouseTrail)&&"Top"===s||!p&&"End"===this.tipPointerPosition?c-f-2+"px":p&&"Bottom"===s||!p&&"Start"===this.tipPointerPosition?"2px":c/2-f/2+"px"),o.style.top=l,o.style.left=a}},t.prototype.renderContent=function(e){var i=this,r=_("."+_4,this.tooltipEle);if(this.cssClass&&V([this.tooltipEle],this.cssClass.split(" ")),e&&!m(e.getAttribute("title"))&&(e.setAttribute("data-content",e.getAttribute("title")),e.removeAttribute("title")),m(this.content))e&&!m(e.getAttribute("data-content"))&&(r.innerHTML=e.getAttribute("data-content"));else if(r.innerHTML="",this.content instanceof HTMLElement)r.appendChild(this.content);else if("string"==typeof this.content)this.isAngular?this.setProperties({content:Ai.sanitize(this.content)},!0):this.content=this.enableHtmlSanitizer?Ai.sanitize(this.content):this.content,this.enableHtmlParse?(o=si(this.content)({},this,"content",this.element.id+"content",void 0,void 0,r,this.root))&&Dt(o,r):r.textContent=this.content;else{var o;(o=si(this.content)({},this,"content",this.element.id+"content",void 0,void 0,r))&&(this.isAngular&&setTimeout(function(){i.reposition(e)},1),Dt(o,r)),this.renderReactTemplates()}},t.prototype.renderCloseIcon=function(){if(this.isSticky){var i=this.createElement("div",{className:B4+" "+F4});this.tooltipEle.appendChild(i),E.add(i,X.touchStartEvent,this.onStickyClose,this)}else{var e=this.tooltipEle.querySelector("."+B4+"."+F4);e&>(e)}},t.prototype.addDescribedBy=function(e,i){var r=(e.getAttribute("aria-describedby")||"").split(/\s+/);r.indexOf(i)<0&&r.push(i),Fe(e,{"aria-describedby":r.join(" ").trim(),"data-tooltip-id":i})},t.prototype.removeDescribedBy=function(e){var i=e.getAttribute("data-tooltip-id"),r=(e.getAttribute("aria-describedby")||"").split(/\s+/),s=r.indexOf(i);-1!==s&&r.splice(s,1),e.removeAttribute("data-tooltip-id");var o=r.join(" ").trim();o?e.setAttribute("aria-describedby",o):e.removeAttribute("aria-describedby")},t.prototype.tapHoldHandler=function(e){clearTimeout(this.autoCloseTimer),this.targetHover(e.originalEvent)},t.prototype.touchEndHandler=function(){var e=this;this.isSticky||(this.autoCloseTimer=setTimeout(function(){e.close()},1500))},t.prototype.targetClick=function(e){var i;!m(i=this.target?J(e.target,this.target):this.element)&&(null===i.getAttribute("data-tooltip-id")?this.targetHover(e):this.isSticky||this.hideTooltip(this.animation.close,e,i))},t.prototype.targetHover=function(e){var i;if(!(m(i=this.target?J(e.target,this.target):this.element)||null!==i.getAttribute("data-tooltip-id")&&0===this.closeDelay)){for(var s=0,o=[].slice.call(we('[data-tooltip-id= "'+this.ctrlId+'_content"]',document));s0?this.showTimer=setTimeout(function(){o.mouseTrail&&E.add(i,"mousemove touchstart mouseenter",o.onMouseMove,o),o.popupObj&&(o.popupObj.show(a,i),o.mouseMoveEvent&&o.mouseTrail&&o.onMouseMove(o.mouseMoveEvent))},this.openDelay):this.popupObj&&this.popupObj.show(a,i)}s&&this.wireMouseEvents(s,i)},t.prototype.needTemplateReposition=function(){return!m(this.viewContainerRef)&&"string"!=typeof this.viewContainerRef||this.isReact},t.prototype.checkCollision=function(e,i,r){var s={left:i,top:r,position:this.position,horizontal:this.tooltipPositionX,vertical:this.tooltipPositionY},o=hc(this.tooltipEle,this.checkCollideTarget(),i,r);return o.length>0&&(s.horizontal=o.indexOf("left")>=0?"Right":o.indexOf("right")>=0?"Left":this.tooltipPositionX,s.vertical=o.indexOf("top")>=0?"Bottom":o.indexOf("bottom")>=0?"Top":this.tooltipPositionY),s},t.prototype.calculateElementPosition=function(e,i){return[this.isBodyContainer?e.left+i.left:e.left-this.containerElement.getBoundingClientRect().left+i.left+window.pageXOffset+this.containerElement.scrollLeft,this.isBodyContainer?e.top+i.top:e.top-this.containerElement.getBoundingClientRect().top+i.top+window.pageYOffset+this.containerElement.scrollTop]},t.prototype.collisionFlipFit=function(e,i,r){var s=this.checkCollision(e,i,r),o=s.position;if(this.tooltipPositionY!==s.vertical&&(o=0===this.position.indexOf("Bottom")||0===this.position.indexOf("Top")?s.vertical+this.tooltipPositionX:this.tooltipPositionX+s.vertical),this.tooltipPositionX!==s.horizontal&&(0===o.indexOf("Left")&&(s.vertical="LeftTop"===o||"LeftCenter"===o?"Top":"Bottom",o=s.vertical+"Left"),0===o.indexOf("Right")&&(s.vertical="RightTop"===o||"RightCenter"===o?"Top":"Bottom",o=s.vertical+"Right"),s.horizontal=this.tooltipPositionX),this.tooltipEventArgs={type:null,cancel:!1,target:e,event:null,element:this.tooltipEle,collidedPosition:o},this.trigger("beforeCollision",this.tooltipEventArgs),this.tooltipEventArgs.cancel)o=this.position;else{var a=s.vertical,l=s.horizontal;if(s.position!==o){var h=ns(e,l,a,!this.isBodyContainer,this.isBodyContainer?null:this.containerElement.getBoundingClientRect());this.adjustArrow(e,o,l,a);var c=this.getScalingFactor(e),d=this.calculateTooltipOffset(o,c.x,c.y);d.top-=this.getOffSetPosition("TopBottom",o,this.offsetY),d.left-=this.getOffSetPosition("RightLeft",o,this.offsetX),s.position=o;var u=this.calculateElementPosition(h,d);s.left=u[0],s.top=u[1]}else this.adjustArrow(e,o,l,a)}var f={left:s.left,top:s.top},p=this.isBodyContainer?pE(this.tooltipEle,this.checkCollideTarget(),{X:!0,Y:this.windowCollision},f):f;this.tooltipEle.style.display="block";var g=_("."+gf,this.tooltipEle);if(this.showTipPointer&&null!=g&&(0===o.indexOf("Bottom")||0===o.indexOf("Top"))){var v=parseInt(g.style.left,10)-(p.left-s.left);v<0?v=0:v+g.offsetWidth>this.tooltipEle.clientWidth&&(v=this.tooltipEle.clientWidth-g.offsetWidth),g.style.left=v.toString()+"px"}return this.tooltipEle.style.display="",f.left=p.left,f.top=p.top,f},t.prototype.getOffSetPosition=function(e,i,r){return-1!==e.indexOf(this.position.split(/(?=[A-Z])/)[0])&&-1!==e.indexOf(i.split(/(?=[A-Z])/)[0])?2*r:0},t.prototype.checkCollideTarget=function(){return!this.windowCollision&&this.target?this.element:null},t.prototype.hideTooltip=function(e,i,r){var s=this;this.closeDelay>0?(clearTimeout(this.hideTimer),clearTimeout(this.showTimer),this.hideTimer=setTimeout(function(){s.closeDelay&&s.tooltipEle&&s.isTooltipOpen||s.tooltipHide(e,i,r)},this.closeDelay)):this.tooltipHide(e,i,r)},t.prototype.tooltipHide=function(e,i,r){var o,s=this;o=i?this.target?r||i.target:this.element:_('[data-tooltip-id= "'+this.ctrlId+'_content"]',document),this.tooltipEventArgs={type:i?i.type:null,cancel:!1,target:o,event:i||null,element:this.tooltipEle,isInteracted:!m(i)},this.trigger("beforeClose",this.tooltipEventArgs,function(a){a.cancel?s.isHidden=!1:(s.mouseMoveBeforeRemove(),s.popupHide(e,o,i))})},t.prototype.popupHide=function(e,i,r){i&&r&&this.restoreElement(i),this.isHidden=!0;var s={name:this.animation.close.effect,duration:e.duration,delay:e.delay,timingFunction:"easeIn"};"None"===e.effect&&(s=void 0),this.popupObj&&this.popupObj.hide(s)},t.prototype.restoreElement=function(e){this.unwireMouseEvents(e),m(e.getAttribute("data-content"))||(e.setAttribute("title",e.getAttribute("data-content")),e.removeAttribute("data-content")),this.removeDescribedBy(e)},t.prototype.clear=function(){var e=this.findTarget();e&&this.restoreElement(e),this.tooltipEle&&(K([this.tooltipEle],YE),V([this.tooltipEle],Zg)),this.isHidden&&(this.popupObj&&this.popupObj.destroy(),this.tooltipEle&>(this.tooltipEle),this.tooltipEle=null,this.popupObj=null)},t.prototype.tooltipHover=function(){this.tooltipEle&&(this.isTooltipOpen=!0)},t.prototype.tooltipMouseOut=function(e){this.isTooltipOpen=!1,this.hideTooltip(this.animation.close,e,this.findTarget())},t.prototype.onMouseOut=function(e){var i=e.relatedTarget;if(i&&!this.mouseTrail){var r=J(i,"."+UE+"."+eS+"."+WE);r?E.add(r,"mouseleave",this.tooltipElementMouseOut,this):(this.hideTooltip(this.animation.close,e,this.findTarget()),0===this.closeDelay&&("None"===this.animation.close.effect||this.isReact&&"string"!=typeof this.content)&&this.clear())}else this.hideTooltip(this.animation.close,e,this.findTarget()),this.clear();this.popupObj&&!this.popupObj.element.classList.contains(Zg)&&this.clear()},t.prototype.tooltipElementMouseOut=function(e){this.hideTooltip(this.animation.close,e,this.findTarget()),E.remove(this.element,"mouseleave",this.tooltipElementMouseOut),this.clear()},t.prototype.onStickyClose=function(){this.close()},t.prototype.onMouseMove=function(e){var i=0,r=0;e.type.indexOf("touch")>-1?(e.preventDefault(),i=e.touches[0].pageX,r=e.touches[0].pageY):(i=e.pageX,r=e.pageY),Hs.stop(this.tooltipEle),K([this.tooltipEle],YE),V([this.tooltipEle],Zg),this.adjustArrow(e.target,this.position,this.tooltipPositionX,this.tooltipPositionY);var s=this.getScalingFactor(e.target),o=this.calculateTooltipOffset(this.position,s.x,s.y),h=this.checkCollision(e.target,i+o.left+this.offsetX,r+o.top+this.offsetY);if(this.tooltipPositionX!==h.horizontal||this.tooltipPositionY!==h.vertical){var c=0===this.position.indexOf("Bottom")||0===this.position.indexOf("Top")?h.vertical+h.horizontal:h.horizontal+h.vertical;h.position=c,this.adjustArrow(e.target,h.position,h.horizontal,h.vertical);var d=this.calculateTooltipOffset(h.position,s.x,s.y);h.left=i+d.left-this.offsetX,h.top=r+d.top-this.offsetY}this.tooltipEle.style.left=h.left+"px",this.tooltipEle.style.top=h.top+"px"},t.prototype.keyDown=function(e){this.tooltipEle&&27===e.keyCode&&this.close()},t.prototype.touchEnd=function(e){this.tooltipEle&&null===J(e.target,"."+_E)&&!this.isSticky&&this.close()},t.prototype.scrollHandler=function(e){this.tooltipEle&&!this.isSticky&&!J(e.target,"."+UE+"."+eS+"."+WE)&&!this.isSticky&&this.close()},t.prototype.render=function(){this.initialize(),this.wireEvents(this.opensOn),this.renderComplete()},t.prototype.preRender=function(){this.tipClass=$g,this.tooltipPositionX="Center",this.tooltipPositionY="Top",this.isHidden=!0},t.prototype.wireEvents=function(e){for(var r=0,s=this.getTriggerList(e);r0)for(var i=0,r=e;i0)for(var i=0,r=e;i0&&this.condition&&-1!==this.condition.indexOf("not")&&(e[s].condition=e[s].condition?e[s].condition+"not":"not"),i=e[s].validate(t),r){if(!i)return!1}else if(i)return!0;return r},n.prototype.toJson=function(){var t,e;if(this.isComplex){t=[],e=this.predicates;for(var i=0;ie.length-3?(e=e.substring(0,e.length-1),n.endsWith(n.toLowerCase(t),n.toLowerCase(e))):(e.lastIndexOf("%")!==e.indexOf("%")&&e.lastIndexOf("%")>e.indexOf("%")+1&&(e=e.substring(e.indexOf("%")+1,e.lastIndexOf("%"))),-1!==t.indexOf(e)))},n.fnSort=function(t){return"ascending"===(t=t?n.toLowerCase(t):"ascending")?this.fnAscending:this.fnDescending},n.fnAscending=function(t,e){return m(t)&&m(e)||null==e?-1:"string"==typeof t?t.localeCompare(e):null==t?1:t-e},n.fnDescending=function(t,e){return m(t)&&m(e)?-1:null==e?1:"string"==typeof t?-1*t.localeCompare(e):null==t?-1:e-t},n.extractFields=function(t,e){for(var i={},r=0;r0||e.length>0;)o=t.length>0&&e.length>0?r?r(this.getVal(t,0,i),this.getVal(e,0,i),t[0],e[0])<=0?t:e:t[0][i]0?t:e,s.push(o.shift());return s},n.getVal=function(t,e,i){return i?this.getObject(i,t[e]):t[e]},n.toLowerCase=function(t){return t?"string"==typeof t?t.toLowerCase():t.toString():0===t||!1===t?t.toString():""},n.callAdaptorFunction=function(t,e,i,r){if(e in t){var s=t[e](i,r);m(s)||(i=s)}return i},n.getAddParams=function(t,e,i){var r={};return n.callAdaptorFunction(t,"addParams",{dm:e,query:i,params:i?i.params:[],reqParams:r}),r},n.isPlainObject=function(t){return!!t&&t.constructor===Object},n.isCors=function(){var t=null;try{t=new window.XMLHttpRequest}catch{}return!!t&&"withCredentials"in t},n.getGuid=function(t){var i;return(t||"")+"00000000-0000-4000-0000-000000000000".replace(/0/g,function(r,s){if("crypto"in window&&"getRandomValues"in crypto){var o=new Uint8Array(1);window.crypto.getRandomValues(o),i=o[0]%16|0}else i=16*Math.random()|0;return"0123456789abcdef"[19===s?3&i|8:i]})},n.isNull=function(t){return null==t},n.getItemFromComparer=function(t,e,i){var r,s,o,a=0,l="string"==typeof n.getVal(t,0,e);if(t.length)for(;m(r)&&a0&&(r=s,o=t[a]));return o},n.distinct=function(t,e,i){i=!m(i)&&i;var s,r=[],o={};return t.forEach(function(a,l){(s="object"==typeof t[l]?n.getVal(t,l,e):t[l])in o||(r.push(i?t[l]:s),o[s]=1)}),r},n.processData=function(t,e){var i=this.prepareQuery(t),r=new it(e);t.requiresCounts&&i.requiresCount();var s=r.executeLocal(i),o={result:t.requiresCounts?s.result:s,count:s.count,aggregates:JSON.stringify(s.aggregates)};return t.requiresCounts?o:s},n.prepareQuery=function(t){var e=this,i=new _t;return t.select&&i.select(t.select),t.where&&n.parse.parseJson(t.where).filter(function(o){if(m(o.condition))i.where(o.field,o.operator,o.value,o.ignoreCase,o.ignoreAccent);else{var a=[];o.field?a.push(new Ss(o.field,o.operator,o.value,o.ignoreCase,o.ignoreAccent)):a=a.concat(e.getPredicate(o.predicates)),"or"===o.condition?i.where(Ss.or(a)):"and"===o.condition&&i.where(Ss.and(a))}}),t.search&&n.parse.parseJson(t.search).filter(function(o){return i.search(o.key,o.fields,o.operator,o.ignoreCase,o.ignoreAccent)}),t.aggregates&&t.aggregates.filter(function(o){return i.aggregate(o.type,o.field)}),t.sorted&&t.sorted.filter(function(o){return i.sortBy(o.name,o.direction)}),t.skip&&i.skip(t.skip),t.take&&i.take(t.take),t.group&&t.group.filter(function(o){return i.group(o)}),i},n.getPredicate=function(t){for(var e=[],i=0;i":"greaterthan","<=":"lessthanorequal",">=":"greaterthanorequal","==":"equal","!=":"notequal","*=":"contains","$=":"endswith","^=":"startswith"},n.odBiOperator={"<":" lt ",">":" gt ","<=":" le ",">=":" ge ","==":" eq ","!=":" ne ",lessthan:" lt ",lessthanorequal:" le ",greaterthan:" gt ",greaterthanorequal:" ge ",equal:" eq ",notequal:" ne "},n.odUniOperator={"$=":"endswith","^=":"startswith","*=":"substringof",endswith:"endswith",startswith:"startswith",contains:"substringof",doesnotendwith:"not endswith",doesnotstartwith:"not startswith",doesnotcontain:"not substringof",wildcard:"wildcard",like:"like"},n.odv4UniOperator={"$=":"endswith","^=":"startswith","*=":"contains",endswith:"endswith",startswith:"startswith",contains:"contains",doesnotendwith:"not endswith",doesnotstartwith:"not startswith",doesnotcontain:"not contains",wildcard:"wildcard",like:"like"},n.diacritics={"\u24b6":"A",\uff21:"A",\u00c0:"A",\u00c1:"A",\u00c2:"A",\u1ea6:"A",\u1ea4:"A",\u1eaa:"A",\u1ea8:"A",\u00c3:"A",\u0100:"A",\u0102:"A",\u1eb0:"A",\u1eae:"A",\u1eb4:"A",\u1eb2:"A",\u0226:"A",\u01e0:"A",\u00c4:"A",\u01de:"A",\u1ea2:"A",\u00c5:"A",\u01fa:"A",\u01cd:"A",\u0200:"A",\u0202:"A",\u1ea0:"A",\u1eac:"A",\u1eb6:"A",\u1e00:"A",\u0104:"A",\u023a:"A",\u2c6f:"A",\ua732:"AA",\u00c6:"AE",\u01fc:"AE",\u01e2:"AE",\ua734:"AO",\ua736:"AU",\ua738:"AV",\ua73a:"AV",\ua73c:"AY","\u24b7":"B",\uff22:"B",\u1e02:"B",\u1e04:"B",\u1e06:"B",\u0243:"B",\u0182:"B",\u0181:"B","\u24b8":"C",\uff23:"C",\u0106:"C",\u0108:"C",\u010a:"C",\u010c:"C",\u00c7:"C",\u1e08:"C",\u0187:"C",\u023b:"C",\ua73e:"C","\u24b9":"D",\uff24:"D",\u1e0a:"D",\u010e:"D",\u1e0c:"D",\u1e10:"D",\u1e12:"D",\u1e0e:"D",\u0110:"D",\u018b:"D",\u018a:"D",\u0189:"D",\ua779:"D",\u01f1:"DZ",\u01c4:"DZ",\u01f2:"Dz",\u01c5:"Dz","\u24ba":"E",\uff25:"E",\u00c8:"E",\u00c9:"E",\u00ca:"E",\u1ec0:"E",\u1ebe:"E",\u1ec4:"E",\u1ec2:"E",\u1ebc:"E",\u0112:"E",\u1e14:"E",\u1e16:"E",\u0114:"E",\u0116:"E",\u00cb:"E",\u1eba:"E",\u011a:"E",\u0204:"E",\u0206:"E",\u1eb8:"E",\u1ec6:"E",\u0228:"E",\u1e1c:"E",\u0118:"E",\u1e18:"E",\u1e1a:"E",\u0190:"E",\u018e:"E","\u24bb":"F",\uff26:"F",\u1e1e:"F",\u0191:"F",\ua77b:"F","\u24bc":"G",\uff27:"G",\u01f4:"G",\u011c:"G",\u1e20:"G",\u011e:"G",\u0120:"G",\u01e6:"G",\u0122:"G",\u01e4:"G",\u0193:"G",\ua7a0:"G",\ua77d:"G",\ua77e:"G","\u24bd":"H",\uff28:"H",\u0124:"H",\u1e22:"H",\u1e26:"H",\u021e:"H",\u1e24:"H",\u1e28:"H",\u1e2a:"H",\u0126:"H",\u2c67:"H",\u2c75:"H",\ua78d:"H","\u24be":"I",\uff29:"I",\u00cc:"I",\u00cd:"I",\u00ce:"I",\u0128:"I",\u012a:"I",\u012c:"I",\u0130:"I",\u00cf:"I",\u1e2e:"I",\u1ec8:"I",\u01cf:"I",\u0208:"I",\u020a:"I",\u1eca:"I",\u012e:"I",\u1e2c:"I",\u0197:"I","\u24bf":"J",\uff2a:"J",\u0134:"J",\u0248:"J","\u24c0":"K",\uff2b:"K",\u1e30:"K",\u01e8:"K",\u1e32:"K",\u0136:"K",\u1e34:"K",\u0198:"K",\u2c69:"K",\ua740:"K",\ua742:"K",\ua744:"K",\ua7a2:"K","\u24c1":"L",\uff2c:"L",\u013f:"L",\u0139:"L",\u013d:"L",\u1e36:"L",\u1e38:"L",\u013b:"L",\u1e3c:"L",\u1e3a:"L",\u0141:"L",\u023d:"L",\u2c62:"L",\u2c60:"L",\ua748:"L",\ua746:"L",\ua780:"L",\u01c7:"LJ",\u01c8:"Lj","\u24c2":"M",\uff2d:"M",\u1e3e:"M",\u1e40:"M",\u1e42:"M",\u2c6e:"M",\u019c:"M","\u24c3":"N",\uff2e:"N",\u01f8:"N",\u0143:"N",\u00d1:"N",\u1e44:"N",\u0147:"N",\u1e46:"N",\u0145:"N",\u1e4a:"N",\u1e48:"N",\u0220:"N",\u019d:"N",\ua790:"N",\ua7a4:"N",\u01ca:"NJ",\u01cb:"Nj","\u24c4":"O",\uff2f:"O",\u00d2:"O",\u00d3:"O",\u00d4:"O",\u1ed2:"O",\u1ed0:"O",\u1ed6:"O",\u1ed4:"O",\u00d5:"O",\u1e4c:"O",\u022c:"O",\u1e4e:"O",\u014c:"O",\u1e50:"O",\u1e52:"O",\u014e:"O",\u022e:"O",\u0230:"O",\u00d6:"O",\u022a:"O",\u1ece:"O",\u0150:"O",\u01d1:"O",\u020c:"O",\u020e:"O",\u01a0:"O",\u1edc:"O",\u1eda:"O",\u1ee0:"O",\u1ede:"O",\u1ee2:"O",\u1ecc:"O",\u1ed8:"O",\u01ea:"O",\u01ec:"O",\u00d8:"O",\u01fe:"O",\u0186:"O",\u019f:"O",\ua74a:"O",\ua74c:"O",\u01a2:"OI",\ua74e:"OO",\u0222:"OU","\u24c5":"P",\uff30:"P",\u1e54:"P",\u1e56:"P",\u01a4:"P",\u2c63:"P",\ua750:"P",\ua752:"P",\ua754:"P","\u24c6":"Q",\uff31:"Q",\ua756:"Q",\ua758:"Q",\u024a:"Q","\u24c7":"R",\uff32:"R",\u0154:"R",\u1e58:"R",\u0158:"R",\u0210:"R",\u0212:"R",\u1e5a:"R",\u1e5c:"R",\u0156:"R",\u1e5e:"R",\u024c:"R",\u2c64:"R",\ua75a:"R",\ua7a6:"R",\ua782:"R","\u24c8":"S",\uff33:"S",\u1e9e:"S",\u015a:"S",\u1e64:"S",\u015c:"S",\u1e60:"S",\u0160:"S",\u1e66:"S",\u1e62:"S",\u1e68:"S",\u0218:"S",\u015e:"S",\u2c7e:"S",\ua7a8:"S",\ua784:"S","\u24c9":"T",\uff34:"T",\u1e6a:"T",\u0164:"T",\u1e6c:"T",\u021a:"T",\u0162:"T",\u1e70:"T",\u1e6e:"T",\u0166:"T",\u01ac:"T",\u01ae:"T",\u023e:"T",\ua786:"T",\ua728:"TZ","\u24ca":"U",\uff35:"U",\u00d9:"U",\u00da:"U",\u00db:"U",\u0168:"U",\u1e78:"U",\u016a:"U",\u1e7a:"U",\u016c:"U",\u00dc:"U",\u01db:"U",\u01d7:"U",\u01d5:"U",\u01d9:"U",\u1ee6:"U",\u016e:"U",\u0170:"U",\u01d3:"U",\u0214:"U",\u0216:"U",\u01af:"U",\u1eea:"U",\u1ee8:"U",\u1eee:"U",\u1eec:"U",\u1ef0:"U",\u1ee4:"U",\u1e72:"U",\u0172:"U",\u1e76:"U",\u1e74:"U",\u0244:"U","\u24cb":"V",\uff36:"V",\u1e7c:"V",\u1e7e:"V",\u01b2:"V",\ua75e:"V",\u0245:"V",\ua760:"VY","\u24cc":"W",\uff37:"W",\u1e80:"W",\u1e82:"W",\u0174:"W",\u1e86:"W",\u1e84:"W",\u1e88:"W",\u2c72:"W","\u24cd":"X",\uff38:"X",\u1e8a:"X",\u1e8c:"X","\u24ce":"Y",\uff39:"Y",\u1ef2:"Y",\u00dd:"Y",\u0176:"Y",\u1ef8:"Y",\u0232:"Y",\u1e8e:"Y",\u0178:"Y",\u1ef6:"Y",\u1ef4:"Y",\u01b3:"Y",\u024e:"Y",\u1efe:"Y","\u24cf":"Z",\uff3a:"Z",\u0179:"Z",\u1e90:"Z",\u017b:"Z",\u017d:"Z",\u1e92:"Z",\u1e94:"Z",\u01b5:"Z",\u0224:"Z",\u2c7f:"Z",\u2c6b:"Z",\ua762:"Z","\u24d0":"a",\uff41:"a",\u1e9a:"a",\u00e0:"a",\u00e1:"a",\u00e2:"a",\u1ea7:"a",\u1ea5:"a",\u1eab:"a",\u1ea9:"a",\u00e3:"a",\u0101:"a",\u0103:"a",\u1eb1:"a",\u1eaf:"a",\u1eb5:"a",\u1eb3:"a",\u0227:"a",\u01e1:"a",\u00e4:"a",\u01df:"a",\u1ea3:"a",\u00e5:"a",\u01fb:"a",\u01ce:"a",\u0201:"a",\u0203:"a",\u1ea1:"a",\u1ead:"a",\u1eb7:"a",\u1e01:"a",\u0105:"a",\u2c65:"a",\u0250:"a",\ua733:"aa",\u00e6:"ae",\u01fd:"ae",\u01e3:"ae",\ua735:"ao",\ua737:"au",\ua739:"av",\ua73b:"av",\ua73d:"ay","\u24d1":"b",\uff42:"b",\u1e03:"b",\u1e05:"b",\u1e07:"b",\u0180:"b",\u0183:"b",\u0253:"b","\u24d2":"c",\uff43:"c",\u0107:"c",\u0109:"c",\u010b:"c",\u010d:"c",\u00e7:"c",\u1e09:"c",\u0188:"c",\u023c:"c",\ua73f:"c",\u2184:"c","\u24d3":"d",\uff44:"d",\u1e0b:"d",\u010f:"d",\u1e0d:"d",\u1e11:"d",\u1e13:"d",\u1e0f:"d",\u0111:"d",\u018c:"d",\u0256:"d",\u0257:"d",\ua77a:"d",\u01f3:"dz",\u01c6:"dz","\u24d4":"e",\uff45:"e",\u00e8:"e",\u00e9:"e",\u00ea:"e",\u1ec1:"e",\u1ebf:"e",\u1ec5:"e",\u1ec3:"e",\u1ebd:"e",\u0113:"e",\u1e15:"e",\u1e17:"e",\u0115:"e",\u0117:"e",\u00eb:"e",\u1ebb:"e",\u011b:"e",\u0205:"e",\u0207:"e",\u1eb9:"e",\u1ec7:"e",\u0229:"e",\u1e1d:"e",\u0119:"e",\u1e19:"e",\u1e1b:"e",\u0247:"e",\u025b:"e",\u01dd:"e","\u24d5":"f",\uff46:"f",\u1e1f:"f",\u0192:"f",\ua77c:"f","\u24d6":"g",\uff47:"g",\u01f5:"g",\u011d:"g",\u1e21:"g",\u011f:"g",\u0121:"g",\u01e7:"g",\u0123:"g",\u01e5:"g",\u0260:"g",\ua7a1:"g",\u1d79:"g",\ua77f:"g","\u24d7":"h",\uff48:"h",\u0125:"h",\u1e23:"h",\u1e27:"h",\u021f:"h",\u1e25:"h",\u1e29:"h",\u1e2b:"h",\u1e96:"h",\u0127:"h",\u2c68:"h",\u2c76:"h",\u0265:"h",\u0195:"hv","\u24d8":"i",\uff49:"i",\u00ec:"i",\u00ed:"i",\u00ee:"i",\u0129:"i",\u012b:"i",\u012d:"i",\u00ef:"i",\u1e2f:"i",\u1ec9:"i",\u01d0:"i",\u0209:"i",\u020b:"i",\u1ecb:"i",\u012f:"i",\u1e2d:"i",\u0268:"i",\u0131:"i","\u24d9":"j",\uff4a:"j",\u0135:"j",\u01f0:"j",\u0249:"j","\u24da":"k",\uff4b:"k",\u1e31:"k",\u01e9:"k",\u1e33:"k",\u0137:"k",\u1e35:"k",\u0199:"k",\u2c6a:"k",\ua741:"k",\ua743:"k",\ua745:"k",\ua7a3:"k","\u24db":"l",\uff4c:"l",\u0140:"l",\u013a:"l",\u013e:"l",\u1e37:"l",\u1e39:"l",\u013c:"l",\u1e3d:"l",\u1e3b:"l",\u017f:"l",\u0142:"l",\u019a:"l",\u026b:"l",\u2c61:"l",\ua749:"l",\ua781:"l",\ua747:"l",\u01c9:"lj","\u24dc":"m",\uff4d:"m",\u1e3f:"m",\u1e41:"m",\u1e43:"m",\u0271:"m",\u026f:"m","\u24dd":"n",\uff4e:"n",\u01f9:"n",\u0144:"n",\u00f1:"n",\u1e45:"n",\u0148:"n",\u1e47:"n",\u0146:"n",\u1e4b:"n",\u1e49:"n",\u019e:"n",\u0272:"n",\u0149:"n",\ua791:"n",\ua7a5:"n",\u01cc:"nj","\u24de":"o",\uff4f:"o",\u00f2:"o",\u00f3:"o",\u00f4:"o",\u1ed3:"o",\u1ed1:"o",\u1ed7:"o",\u1ed5:"o",\u00f5:"o",\u1e4d:"o",\u022d:"o",\u1e4f:"o",\u014d:"o",\u1e51:"o",\u1e53:"o",\u014f:"o",\u022f:"o",\u0231:"o",\u00f6:"o",\u022b:"o",\u1ecf:"o",\u0151:"o",\u01d2:"o",\u020d:"o",\u020f:"o",\u01a1:"o",\u1edd:"o",\u1edb:"o",\u1ee1:"o",\u1edf:"o",\u1ee3:"o",\u1ecd:"o",\u1ed9:"o",\u01eb:"o",\u01ed:"o",\u00f8:"o",\u01ff:"o",\u0254:"o",\ua74b:"o",\ua74d:"o",\u0275:"o",\u01a3:"oi",\u0223:"ou",\ua74f:"oo","\u24df":"p",\uff50:"p",\u1e55:"p",\u1e57:"p",\u01a5:"p",\u1d7d:"p",\ua751:"p",\ua753:"p",\ua755:"p","\u24e0":"q",\uff51:"q",\u024b:"q",\ua757:"q",\ua759:"q","\u24e1":"r",\uff52:"r",\u0155:"r",\u1e59:"r",\u0159:"r",\u0211:"r",\u0213:"r",\u1e5b:"r",\u1e5d:"r",\u0157:"r",\u1e5f:"r",\u024d:"r",\u027d:"r",\ua75b:"r",\ua7a7:"r",\ua783:"r","\u24e2":"s",\uff53:"s",\u00df:"s",\u015b:"s",\u1e65:"s",\u015d:"s",\u1e61:"s",\u0161:"s",\u1e67:"s",\u1e63:"s",\u1e69:"s",\u0219:"s",\u015f:"s",\u023f:"s",\ua7a9:"s",\ua785:"s",\u1e9b:"s","\u24e3":"t",\uff54:"t",\u1e6b:"t",\u1e97:"t",\u0165:"t",\u1e6d:"t",\u021b:"t",\u0163:"t",\u1e71:"t",\u1e6f:"t",\u0167:"t",\u01ad:"t",\u0288:"t",\u2c66:"t",\ua787:"t",\ua729:"tz","\u24e4":"u",\uff55:"u",\u00f9:"u",\u00fa:"u",\u00fb:"u",\u0169:"u",\u1e79:"u",\u016b:"u",\u1e7b:"u",\u016d:"u",\u00fc:"u",\u01dc:"u",\u01d8:"u",\u01d6:"u",\u01da:"u",\u1ee7:"u",\u016f:"u",\u0171:"u",\u01d4:"u",\u0215:"u",\u0217:"u",\u01b0:"u",\u1eeb:"u",\u1ee9:"u",\u1eef:"u",\u1eed:"u",\u1ef1:"u",\u1ee5:"u",\u1e73:"u",\u0173:"u",\u1e77:"u",\u1e75:"u",\u0289:"u","\u24e5":"v",\uff56:"v",\u1e7d:"v",\u1e7f:"v",\u028b:"v",\ua75f:"v",\u028c:"v",\ua761:"vy","\u24e6":"w",\uff57:"w",\u1e81:"w",\u1e83:"w",\u0175:"w",\u1e87:"w",\u1e85:"w",\u1e98:"w",\u1e89:"w",\u2c73:"w","\u24e7":"x",\uff58:"x",\u1e8b:"x",\u1e8d:"x","\u24e8":"y",\uff59:"y",\u1ef3:"y",\u00fd:"y",\u0177:"y",\u1ef9:"y",\u0233:"y",\u1e8f:"y",\u00ff:"y",\u1ef7:"y",\u1e99:"y",\u1ef5:"y",\u01b4:"y",\u024f:"y",\u1eff:"y","\u24e9":"z",\uff5a:"z",\u017a:"z",\u1e91:"z",\u017c:"z",\u017e:"z",\u1e93:"z",\u1e95:"z",\u01b6:"z",\u0225:"z",\u0240:"z",\u2c6c:"z",\ua763:"z",\u0386:"\u0391",\u0388:"\u0395",\u0389:"\u0397",\u038a:"\u0399",\u03aa:"\u0399",\u038c:"\u039f",\u038e:"\u03a5",\u03ab:"\u03a5",\u038f:"\u03a9",\u03ac:"\u03b1",\u03ad:"\u03b5",\u03ae:"\u03b7",\u03af:"\u03b9",\u03ca:"\u03b9",\u0390:"\u03b9",\u03cc:"\u03bf",\u03cd:"\u03c5",\u03cb:"\u03c5",\u03b0:"\u03c5",\u03c9:"\u03c9",\u03c2:"\u03c3"},n.fnOperators={equal:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?n.toLowerCase(t)===n.toLowerCase(e):t===e},notequal:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),!n.fnOperators.equal(t,e,i)},lessthan:function(t,e,i){return i?n.toLowerCase(t)n.toLowerCase(e):t>e},lessthanorequal:function(t,e,i){return i?n.toLowerCase(t)<=n.toLowerCase(e):(m(t)&&(t=void 0),t<=e)},greaterthanorequal:function(t,e,i){return i?n.toLowerCase(t)>=n.toLowerCase(e):t>=e},contains:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?!m(t)&&!m(e)&&-1!==n.toLowerCase(t).indexOf(n.toLowerCase(e)):!m(t)&&!m(e)&&-1!==t.toString().indexOf(e)},doesnotcontain:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?!m(t)&&!m(e)&&-1===n.toLowerCase(t).indexOf(n.toLowerCase(e)):!m(t)&&!m(e)&&-1===t.toString().indexOf(e)},isnotnull:function(t){return null!=t},isnull:function(t){return null==t},startswith:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.startsWith(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.startsWith(t,e)},doesnotstartwith:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.notStartsWith(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.notStartsWith(t,e)},like:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.like(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.like(t,e)},isempty:function(t){return void 0===t||""===t},isnotempty:function(t){return void 0!==t&&""!==t},wildcard:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?(t||"boolean"==typeof t)&&e&&"object"!=typeof t&&n.wildCard(n.toLowerCase(t),n.toLowerCase(e)):(t||"boolean"==typeof t)&&e&&n.wildCard(t,e)},endswith:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.endsWith(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.endsWith(t,e)},doesnotendwith:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.notEndsWith(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.notEndsWith(t,e)},processSymbols:function(t){var e=n.operatorSymbols[t];return e?n.fnOperators[e]:n.throwError("Query - Process Operator : Invalid operator")},processOperator:function(t){return n.fnOperators[t]||n.fnOperators.processSymbols(t)}},n.parse={parseJson:function(t){return"string"!=typeof t||!/^[\s]*\[|^[\s]*\{(.)+:/g.test(t)&&-1!==t.indexOf('"')?t instanceof Array?n.parse.iterateAndReviveArray(t):"object"==typeof t&&null!==t&&n.parse.iterateAndReviveJson(t):t=JSON.parse(t,n.parse.jsonReviver),t},iterateAndReviveArray:function(t){for(var e=0;e-1||e.indexOf("z")>-1,o=e.split(/[^0-9.]/);if(s){if(o[5].indexOf(".")>-1){var a=o[5].split(".");o[5]=a[0],o[6]=new Date(e).getUTCMilliseconds().toString()}else o[6]="00";e=n.dateParse.toTimeZone(new Date(parseInt(o[0],10),parseInt(o[1],10)-1,parseInt(o[2],10),parseInt(o[3],10),parseInt(o[4],10),parseInt(o[5]?o[5]:"00",10),parseInt(o[6],10)),n.serverTimezoneOffset,!1)}else{var l=new Date(parseInt(o[0],10),parseInt(o[1],10)-1,parseInt(o[2],10),parseInt(o[3],10),parseInt(o[4],10),parseInt(o[5]?o[5]:"00",10)),h=parseInt(o[6],10),c=parseInt(o[7],10);if(isNaN(h)&&isNaN(c))return l;e.indexOf("+")>-1?l.setHours(l.getHours()-h,l.getMinutes()-c):l.setHours(l.getHours()+h,l.getMinutes()+c),e=n.dateParse.toTimeZone(l,n.serverTimezoneOffset,!1)}null==n.serverTimezoneOffset&&(e=n.dateParse.addSelfOffset(e))}}return e},isJson:function(t){return"string"==typeof t[0]?t:n.parse.parseJson(t)},isGuid:function(t){return null!=/[A-Fa-f0-9]{8}(?:-[A-Fa-f0-9]{4}){3}-[A-Fa-f0-9]{12}/i.exec(t)},replacer:function(t,e){return n.isPlainObject(t)?n.parse.jsonReplacer(t,e):t instanceof Array?n.parse.arrayReplacer(t):t instanceof Date?n.parse.jsonReplacer({val:t},e).val:t},jsonReplacer:function(t,e){for(var i,s=0,o=Object.keys(t);s=0?"+":"-",s=function(a){var l=Math.floor(Math.abs(a));return(l<10?"0":"")+l};return e.getFullYear()+"-"+s(e.getMonth()+1)+"-"+s(e.getDate())+"T"+s(e.getHours())+":"+s(e.getMinutes())+":"+s(e.getSeconds())+r+s(i/60)+":"+s(i%60)}},n}(),wl=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),BK={GroupGuid:"{271bbba0-1ee7}"},a5=function(){function n(t){this.options={from:"table",requestType:"json",sortBy:"sorted",select:"select",skip:"skip",group:"group",take:"take",search:"search",count:"requiresCounts",where:"where",aggregates:"aggregates",expand:"expand"},this.type=n,this.dataSource=t,this.pvt={}}return n.prototype.processResponse=function(t,e,i,r){return t},n}(),XE=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return wl(t,n),t.prototype.processQuery=function(e,i){for(var a,l,f,r=e.dataSource.json.slice(0),s=r.length,o=!0,h={},c=0,d=[],u=[],p=0;p1?e.sort.filter(function(f){return f.fieldName===c})[0]:e.sort[0];s=this.onSortBy(s,d,e.query,!0)}e.page&&(s=this.onPage(s,e.page,e.query)),this.formGroupResult(s,h)}else{for(var o=e.lazyLoad.onDemandGroupInfo,a=o.where.length-1;a>=0;a--)s=this.onWhere(s,o.where[a]);if(e.group.length!==o.level)s=le.group(s,e.group[o.level].fieldName,r,null,null,e.group[o.level].comparer,!0),e.sort.length&&(s=this.onSortBy(s,e.sort[parseInt(o.level.toString(),10)],e.query,!0));else for(a=e.sort.length-1;a>=o.level;a--)s=this.onSortBy(s,e.sort[parseInt(a.toString(),10)],e.query,!1);i=s.length,h=s,s=(s=s.slice(o.skip)).slice(0,o.take),e.group.length!==o.level&&this.formGroupResult(s,h)}return{result:s,count:i}},t.prototype.formGroupResult=function(e,i){if(e.length&&i.length){var r="GroupGuid",s="childLevels",o="level",a="records";e[r]=i[r],e[s]=i[s],e[o]=i[o],e[a]=i[a]}return e},t.prototype.getAggregate=function(e){var i=_t.filterQueries(e.queries,"onAggregates"),r=[];if(i.length)for(var s=void 0,o=0;o=0;l--)a[l]&&(o=i.comparer,le.endsWith(a[l]," desc")&&(o=le.fnSort("descending"),a[l]=a[l].replace(" desc","")),e=le.sort(e,a[l],o));return e}return le.sort(e,s?"key":a,i.comparer)},t.prototype.onGroup=function(e,i,r){if(!e||!e.length)return e;var s=this.getAggregate(r);return le.group(e,le.getValue(i.fieldName,r),s,null,null,i.comparer)},t.prototype.onPage=function(e,i,r){var s=le.getValue(i.pageSize,r),o=(le.getValue(i.pageIndex,r)-1)*s;return e&&e.length?e.slice(o,o+s):e},t.prototype.onRange=function(e,i){return e&&e.length?e.slice(le.getValue(i.start),le.getValue(i.end)):e},t.prototype.onTake=function(e,i){return e&&e.length?e.slice(0,le.getValue(i.nos)):e},t.prototype.onSkip=function(e,i){return e&&e.length?e.slice(le.getValue(i.nos)):e},t.prototype.onSelect=function(e,i){return e&&e.length?le.select(e,le.getValue(i.fieldNames)):e},t.prototype.insert=function(e,i,r,s,o){return m(o)?e.dataSource.json.push(i):e.dataSource.json.splice(o,0,i)},t.prototype.remove=function(e,i,r,s){var a,o=e.dataSource.json;for("object"==typeof r&&!(r instanceof Date)&&(r=le.getObject(i,r)),a=0;a1&&(g="("+g+")"),f.filters.push(g);for(var y=0,S="object"==typeof f.filters[p]?Object.keys(f.filters[p]):[];y-1&&this.formRemoteGroupedData(e[s].items,i+1,r-1);var o="GroupGuid",h="records";return e[o]=BK[o],e.level=i,e.childLevels=r,e[h]=e[0].items.length?this.getGroupedRecords(e,!m(e[0].items[h])):[],e},t.prototype.getGroupedRecords=function(e,i){for(var r=[],o=0;ol.length-3?(l=l.substring(0,l.length-1),o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.endswith:le.odv4UniOperator.endswith):l.lastIndexOf("%")!==l.indexOf("%")&&l.lastIndexOf("%")>l.indexOf("%")+1?(l=l.substring(l.indexOf("%")+1,l.lastIndexOf("%")),o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains):o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains),l="'"+(l=encodeURIComponent(l))+"'";else if("wildcard"===o)if(-1!==l.indexOf("*")){var d=l.split("*"),u=void 0,f=0;if(0!==l.indexOf("*")&&-1===d[0].indexOf("%3f")&&-1===d[0].indexOf("?")&&(u="'"+(u=d[0])+"'",s+=(o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.startswith:le.odv4UniOperator.startswith)+"(",s+=c+",",a&&(s+=a),s+=u+")",f++),l.lastIndexOf("*")!==l.length-1&&-1===d[d.length-1].indexOf("%3f")&&-1===d[d.length-1].indexOf("?")&&(u="'"+(u=d[d.length-1])+"'",f>0&&(s+=" and "),s+=(o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.endswith:le.odv4UniOperator.endswith)+"(",s+=c+",",a&&(s+=a),s+=u+")",f++),d.length>2)for(var p=1;p0&&(s+=" and "),"substringof"===(o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains)||"not substringof"===o){var g=u;u=c,c=g}s+=o+"(",s+=c+",",a&&(s+=a),s+=u+")",f++}0===f?(o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains,(-1!==l.indexOf("?")||-1!==l.indexOf("%3f"))&&(l=-1!==l.indexOf("?")?l.split("?").join(""):l.split("%3f").join("")),l="'"+l+"'"):o="wildcard"}else o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains,(-1!==l.indexOf("?")||-1!==l.indexOf("%3f"))&&(l=-1!==l.indexOf("?")?l.split("?").join(""):l.split("%3f").join("")),l="'"+l+"'";return"substringof"!==o&&"not substringof"!==o||(g=l,l=c,c=g),"wildcard"!==o&&(s+=o+"(",s+=c+",",a&&(s+=a),s+=l+")"),s},t.prototype.addParams=function(e){n.prototype.addParams.call(this,e),delete e.reqParams.params},t.prototype.onComplexPredicate=function(e,i,r){for(var s=[],o=0;o-1;f--)!/\bContent-ID:/i.test(c[f])||!/\bHTTP.+201/.test(c[f])||(l=parseInt(/\bContent-ID: (\d+)/i.exec(c[f])[1],10),o.addedRecords[l]&&(h=le.parse.parseJson(/^\{.+\}/m.exec(c[f])[0]),ze({},o.addedRecords[l],this.processResponse(h))));return o}return null},t.prototype.compareAndRemove=function(e,i,r){var s=this;return m(i)||Object.keys(e).forEach(function(o){o!==r&&"@odata.etag"!==o&&(le.isPlainObject(e[o])?(s.compareAndRemove(e[o],i[o]),0===Object.keys(e[o]).filter(function(l){return"@odata.etag"!==l}).length&&delete e[o]):(e[o]===i[o]||e[o]&&i[o]&&e[o].valueOf()===i[o].valueOf())&&delete e[o])}),e},t}(gc),FK=function(n){function t(){var e=n.call(this)||this;return yt("beforeSend",gc.prototype.beforeSend,e),e}return wl(t,n),t.prototype.insert=function(e,i,r,s,o){return this.pvt.position=o,this.updateType="add",{url:e.dataSource.insertUrl||e.dataSource.crudUrl||e.dataSource.url,data:JSON.stringify(ze({},{value:i,table:r,action:"insert"},le.getAddParams(this,e,s)))}},t.prototype.remove=function(e,i,r,s,o){return n.prototype.remove.call(this,e,i,r),{type:"POST",url:e.dataSource.removeUrl||e.dataSource.crudUrl||e.dataSource.url,data:JSON.stringify(ze({},{key:r,keyColumn:i,table:s,action:"remove"},le.getAddParams(this,e,o)))}},t.prototype.update=function(e,i,r,s,o){return this.updateType="update",this.updateKey=i,{type:"POST",url:e.dataSource.updateUrl||e.dataSource.crudUrl||e.dataSource.url,data:JSON.stringify(ze({},{value:r,action:"update",keyColumn:i,key:r[i],table:s},le.getAddParams(this,e,o)))}},t.prototype.processResponse=function(e,i,r,s,o,a,l){var h;if(e="batch"===(o?JSON.parse(o.data):e).action?le.parse.parseJson(e):e,"add"===this.updateType&&n.prototype.insert.call(this,i,e,null,null,this.pvt.position),"update"===this.updateType&&n.prototype.update.call(this,i,this.updateKey,e),this.updateType=void 0,e.added)for(h=0;hi&&h.push(c)}for(c=0;cthis.pageSize;)h.results.splice(0,1),h.keys.splice(0,1);return window.localStorage.setItem(this.guidId,JSON.stringify(h)),e},t.prototype.beforeSend=function(e,i,r){!m(this.cacheAdaptor.options.batch)&&le.endsWith(r.url,this.cacheAdaptor.options.batch)&&"post"===r.type.toLowerCase()&&i.headers.set("Accept",this.cacheAdaptor.options.multipartAccept),e.dataSource.crossDomain||i.headers.set("Accept",this.cacheAdaptor.options.accept)},t.prototype.update=function(e,i,r,s){return this.isCrudAction=!0,this.cacheAdaptor.update(e,i,r,s)},t.prototype.insert=function(e,i,r){return this.isInsertAction=!0,this.cacheAdaptor.insert(e,i,r)},t.prototype.remove=function(e,i,r,s){return this.isCrudAction=!0,this.cacheAdaptor.remove(e,i,r,s)},t.prototype.batchRequest=function(e,i,r){return this.cacheAdaptor.batchRequest(e,i,r)},t}(gc),it=function(){function n(t,e,i){var s,r=this;return this.dateParse=!0,this.timeZoneHandling=!0,this.persistQuery={},this.isInitialLoad=!1,this.requests=[],this.isInitialLoad=!0,!t&&!this.dataSource&&(t=[]),i=i||t.adaptor,t&&!1===t.timeZoneHandling&&(this.timeZoneHandling=t.timeZoneHandling),t instanceof Array?s={json:t,offline:!0}:"object"==typeof t?(t.json||(t.json=[]),t.enablePersistence||(t.enablePersistence=!1),t.id||(t.id=""),t.ignoreOnPersist||(t.ignoreOnPersist=[]),s={url:t.url,insertUrl:t.insertUrl,removeUrl:t.removeUrl,updateUrl:t.updateUrl,crudUrl:t.crudUrl,batchUrl:t.batchUrl,json:t.json,headers:t.headers,accept:t.accept,data:t.data,timeTillExpiration:t.timeTillExpiration,cachingPageSize:t.cachingPageSize,enableCaching:t.enableCaching,requestType:t.requestType,key:t.key,crossDomain:t.crossDomain,jsonp:t.jsonp,dataType:t.dataType,offline:void 0!==t.offline?t.offline:!(t.adaptor instanceof FK||t.adaptor instanceof _K||t.url),requiresFormat:t.requiresFormat,enablePersistence:t.enablePersistence,id:t.id,ignoreOnPersist:t.ignoreOnPersist}):le.throwError("DataManager: Invalid arguments"),void 0===s.requiresFormat&&!le.isCors()&&(s.requiresFormat=!!m(s.crossDomain)||s.crossDomain),void 0===s.dataType&&(s.dataType="json"),this.dataSource=s,this.defaultQuery=e,this.dataSource.enablePersistence&&this.dataSource.id&&window.addEventListener("unload",this.setPersistData.bind(this)),s.url&&s.offline&&!s.json.length?(this.isDataAvailable=!1,this.adaptor=i||new yf,this.dataSource.offline=!1,this.ready=this.executeQuery(e||new _t),this.ready.then(function(o){r.dataSource.offline=!0,r.isDataAvailable=!0,s.json=o.result,r.adaptor=new XE})):this.adaptor=s.offline?new XE:new yf,!s.jsonp&&this.adaptor instanceof yf&&(s.jsonp="callback"),this.adaptor=i||this.adaptor,s.enableCaching&&(this.adaptor=new UK(this.adaptor,s.timeTillExpiration,s.cachingPageSize)),this}return Object.defineProperty(n.prototype,"moduleName",{get:function(){return"datamanager"},enumerable:!0,configurable:!0}),n.prototype.getPersistedData=function(t){var e=localStorage.getItem(t||this.dataSource.id);return JSON.parse(e)},n.prototype.setPersistData=function(t,e,i){localStorage.setItem(e||this.dataSource.id,JSON.stringify(i||this.persistQuery))},n.prototype.setPersistQuery=function(t){var e=this,i=this.getPersistedData();if(this.isInitialLoad&&i&&Object.keys(i).length){this.persistQuery=i,this.persistQuery.queries=this.persistQuery.queries.filter(function(s){if(e.dataSource.ignoreOnPersist&&e.dataSource.ignoreOnPersist.length&&s.fn&&e.dataSource.ignoreOnPersist.some(function(l){return s.fn===l}))return!1;if("onWhere"===s.fn){var o=s.e;if(o&&o.isComplex&&o.predicates instanceof Array){var a=o.predicates.map(function(l){if(l.predicates&&l.predicates instanceof Array){var h=l.predicates.map(function(v){return new Ss(v.field,v.operator,v.value,v.ignoreCase,v.ignoreAccent,v.matchCase)});return"and"===l.condition?Ss.and(h):Ss.or(h)}return new Ss(l.field,l.operator,l.value,l.ignoreCase,l.ignoreAccent,l.matchCase)});s.e=new Ss(a[0],o.condition,a.slice(1))}}return!0});var r=ze(new _t,this.persistQuery);return this.isInitialLoad=!1,r}return this.persistQuery=t,this.isInitialLoad=!1,t},n.prototype.setDefaultQuery=function(t){return this.defaultQuery=t,this},n.prototype.executeLocal=function(t){!this.defaultQuery&&!(t instanceof _t)&&le.throwError("DataManager - executeLocal() : A query is required to execute"),this.dataSource.json||le.throwError("DataManager - executeLocal() : Json data is required to execute"),this.dataSource.enablePersistence&&this.dataSource.id&&(t=this.setPersistQuery(t));var e=this.adaptor.processQuery(this,t=t||this.defaultQuery);if(t.subQuery){var i=t.subQuery.fromTable,r=t.subQuery.lookups,s=t.isCountRequired?e.result:e;r&&r instanceof Array&&le.buildHierarchy(t.subQuery.fKey,i,s,r,t.subQuery.key);for(var o=0;oli");z.classList.remove("json-parent");for(var j=0;j',W=ve.children[0].placeholder}return W}function Q(k,W,ve){!m(ve)&&""!==ve&&K(W,ve.split(" ")),!m(k)&&""!==k&&V(W,k.split(" "))}function oe(k,W,ve){if("multiselect"===ve||function Mo(k){if(!k)return!1;for(var W=k;W&&W!==document.body;){if("none"===window.getComputedStyle(W).display)return!1;W=W.parentElement}return!0}(k)){var Te="multiselect"===ve?k:k.clientWidth-parseInt(getComputedStyle(k,null).getPropertyValue("padding-left"),10);!m(W)&&!m(W.getElementsByClassName("e-float-text-content")[0])&&(W.getElementsByClassName("e-float-text-content")[0].classList.contains("e-float-text-overflow")&&W.getElementsByClassName("e-float-text-content")[0].classList.remove("e-float-text-overflow"),(Te0)for(var Ye=0;Ye<_e.length;Ye++)_e[parseInt(Ye.toString(),10)].addEventListener("mousedown",wo,!1),_e[parseInt(Ye.toString(),10)].addEventListener("mouseup",Ul,!1);else if(_e.length>0)for(Ye=0;Ye<_e.length;Ye++)_e[parseInt(Ye.toString(),10)].removeEventListener("mousedown",wo,this),_e[parseInt(Ye.toString(),10)].removeEventListener("mouseup",Ul,this)}function wo(){for(var W=this.parentElement;!W.classList.contains("e-input-group");)W=W.parentElement;!function Sa(k,W){!k.classList.contains("e-disabled")&&!k.querySelector("input").readOnly&&W.classList.add("e-input-btn-ripple")}(W,this)}function Ul(){var k=this;setTimeout(function(){k.classList.remove("e-input-btn-ripple")},500)}function Ib(k,W){var ve=W("span",{className:k});return ve.classList.add("e-input-group-icon"),ve}function I_(k,W,ve,Te){var _e=m(Te)?Si:Te,Ye=Ib(k,_e);W.classList.add("e-float-icon-left");var vi=W.querySelector(".e-input-in-wrap");if(m(vi)){vi=_e("span",{className:"e-input-in-wrap"}),ve.parentNode.insertBefore(vi,ve);var Gs=W.querySelectorAll(ve.tagName+" ~ *");vi.appendChild(ve);for(var ts=0;ts-1)if("class"===_e){var Ye=this.getInputValidClassList(k[""+_e]);""!==Ye&&V([W],Ye.split(" "))}else if("style"===_e){var vi=W.getAttribute(_e);vi=m(vi)?k[""+_e]:vi+k[""+_e],W.setAttribute(_e,vi)}else W.setAttribute(_e,k[""+_e])}},n.isBlank=function Hle(k){return!k||/^\s*$/.test(k)}}(Le||(Le={})),new RegExp("^(-)?(\\d*)$"),new RegExp("^[A-Za-z0-9._%+-]{1,}@[A-Za-z0-9._%+-]{1,}([.]{1}[a-zA-Z0-9]{2,}|[.]{1}[a-zA-Z0-9]{2,4}[.]{1}[a-zA-Z0-9]{2,4})$"),new RegExp("^([0-9]{4})-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])$"),new RegExp("^[0-9]*$"),new RegExp("^[+]?[0-9]{9,13}$"),new RegExp("^\\d{13,16}$");var me=function(){function n(t,e){this.width=t,this.height=e}return n.prototype.isEmpty=function(){return 0===this.height&&0===this.width},n.prototype.clone=function(){return new n(this.width,this.height)},n}(),Rie=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),KB=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},R=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Rie(t,n),t.equals=function(e,i){return e===i||!(!e||!i)&&(!e||!i||e.x===i.x&&e.y===i.y)},t.isEmptyPoint=function(e){return!(e.x&&e.y)},t.transform=function(e,i,r){var s={x:0,y:0};return s.x=Math.round(100*(e.x+r*Math.cos(i*Math.PI/180)))/100,s.y=Math.round(100*(e.y+r*Math.sin(i*Math.PI/180)))/100,s},t.findLength=function(e,i){return Math.sqrt(Math.pow(e.x-i.x,2)+Math.pow(e.y-i.y,2))},t.findAngle=function(e,i){var r=Math.atan2(i.y-e.y,i.x-e.x);return r=180*r/Math.PI,(r%=360)<0&&(r+=360),r},t.distancePoints=function(e,i){return Math.sqrt(Math.pow(i.x-e.x,2)+Math.pow(i.y-e.y,2))},t.getLengthFromListOfPoints=function(e){for(var i=0,r=0;ri.y&&!r?o.y+=s:o.y-=s:e.y===i.y?e.xi.x&&!r?o.x+=s:o.x-=s:r?(a=this.findAngle(e,i),o=this.transform(e,a,s)):(a=this.findAngle(i,e),o=this.transform(i,a,s)),o},t.direction=function(e,i){return Math.abs(i.x-e.x)>Math.abs(i.y-e.y)?e.x0)for(var r=0;rt.right||this.top>t.bottom||this.bottom=t.right&&this.top<=t.top&&this.bottom>=t.bottom},n.prototype.containsPoint=function(t,e){return void 0===e&&(e=0),this.left-e<=t.x&&this.right+e>=t.x&&this.top-e<=t.y&&this.bottom+e>=t.y},n.toBounds=function(t){for(var e=new n,i=0,r=t;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},s3=function(n){if(n)switch(n.type){case"Linear":default:return EI;case"Radial":return Gie}return EI},Yie=function(){return function n(t,e,i,r){this.left=t,this.right=e,this.top=i,this.bottom=r}}(),Jn=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),rt([I(0)],t.prototype,"left",void 0),rt([I(0)],t.prototype,"right",void 0),rt([I(0)],t.prototype,"top",void 0),rt([I(0)],t.prototype,"bottom",void 0),t}(Ee),Qie=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),rt([I(45)],t.prototype,"angle",void 0),rt([I(5)],t.prototype,"distance",void 0),rt([I(.7)],t.prototype,"opacity",void 0),rt([I("lightgrey")],t.prototype,"color",void 0),t}(Ee),o3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),t.prototype.getClassName=function(){return"Stop"},rt([I("")],t.prototype,"color",void 0),rt([I(0)],t.prototype,"offset",void 0),rt([I(1)],t.prototype,"opacity",void 0),t}(Ee),Cx=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),rt([Bt([],o3)],t.prototype,"stops",void 0),rt([I("None")],t.prototype,"type",void 0),rt([I("")],t.prototype,"id",void 0),t}(Ee),EI=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),rt([I(0)],t.prototype,"x1",void 0),rt([I(0)],t.prototype,"x2",void 0),rt([I(0)],t.prototype,"y1",void 0),rt([I(0)],t.prototype,"y2",void 0),t}(Cx),Gie=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),rt([I(0)],t.prototype,"cx",void 0),rt([I(0)],t.prototype,"cy",void 0),rt([I(0)],t.prototype,"fx",void 0),rt([I(0)],t.prototype,"fy",void 0),rt([I(50)],t.prototype,"r",void 0),t}(Cx),Nl=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),rt([I("white")],t.prototype,"fill",void 0),rt([I("black")],t.prototype,"strokeColor",void 0),rt([I("")],t.prototype,"strokeDashArray",void 0),rt([I(1)],t.prototype,"strokeWidth",void 0),rt([I(1)],t.prototype,"opacity",void 0),rt([L0(s3)],t.prototype,"gradient",void 0),t}(Ee),a3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),rt([I("transparent")],t.prototype,"fill",void 0),t}(Nl),$f=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),rt([I("black")],t.prototype,"color",void 0),rt([I("Arial")],t.prototype,"fontFamily",void 0),rt([I(12)],t.prototype,"fontSize",void 0),rt([I(!1)],t.prototype,"italic",void 0),rt([I(!1)],t.prototype,"bold",void 0),rt([I("CollapseSpace")],t.prototype,"whiteSpace",void 0),rt([I("WrapWithOverflow")],t.prototype,"textWrapping",void 0),rt([I("Center")],t.prototype,"textAlign",void 0),rt([I("None")],t.prototype,"textDecoration",void 0),rt([I("Wrap")],t.prototype,"textOverflow",void 0),rt([I("transparent")],t.prototype,"fill",void 0),t}(Nl),on=function(n){return n[n.Default=0]="Default",n[n.expandNode=2]="expandNode",n[n.interaction=4]="interaction",n[n.GroupingInProgress=8]="GroupingInProgress",n[n.GroupClipboardInProcess=16]="GroupClipboardInProcess",n[n.ClearObject=32]="ClearObject",n}(on||{}),ci=function(n){return n[n.Visible=1]="Visible",n[n.Hidden=2]="Hidden",n[n.Hover=4]="Hover",n[n.Connect=8]="Connect",n}(ci||{}),Kt=function(n){return n[n.None=0]="None",n[n.ShowHorizontalLines=1]="ShowHorizontalLines",n[n.ShowVerticalLines=2]="ShowVerticalLines",n[n.ShowLines=3]="ShowLines",n[n.SnapToHorizontalLines=4]="SnapToHorizontalLines",n[n.SnapToVerticalLines=8]="SnapToVerticalLines",n[n.SnapToLines=12]="SnapToLines",n[n.SnapToObject=16]="SnapToObject",n[n.All=31]="All",n}(Kt||{}),mr=function(n){return n[n.None=1]="None",n[n.ConnectorSourceThumb=2]="ConnectorSourceThumb",n[n.ConnectorTargetThumb=4]="ConnectorTargetThumb",n[n.ResizeSouthEast=8]="ResizeSouthEast",n[n.ResizeSouthWest=16]="ResizeSouthWest",n[n.ResizeNorthEast=32]="ResizeNorthEast",n[n.ResizeNorthWest=64]="ResizeNorthWest",n[n.ResizeEast=128]="ResizeEast",n[n.ResizeWest=256]="ResizeWest",n[n.ResizeSouth=512]="ResizeSouth",n[n.ResizeNorth=1024]="ResizeNorth",n[n.Rotate=2048]="Rotate",n[n.UserHandle=4096]="UserHandle",n[n.ToolTip=8192]="ToolTip",n[n.ResizeAll=2046]="ResizeAll",n[n.All=16382]="All",n}(mr||{}),qe=function(n){return n[n.None=1]="None",n[n.Select=2]="Select",n[n.Delete=4]="Delete",n[n.Drag=8]="Drag",n[n.DragSourceEnd=16]="DragSourceEnd",n[n.DragTargetEnd=32]="DragTargetEnd",n[n.DragSegmentThumb=64]="DragSegmentThumb",n[n.AllowDrop=128]="AllowDrop",n[n.Bridging=256]="Bridging",n[n.BridgeObstacle=512]="BridgeObstacle",n[n.InheritBridging=1024]="InheritBridging",n[n.PointerEvents=2048]="PointerEvents",n[n.Tooltip=4096]="Tooltip",n[n.InheritTooltip=8192]="InheritTooltip",n[n.Interaction=4218]="Interaction",n[n.ReadOnly=16384]="ReadOnly",n[n.LineRouting=32768]="LineRouting",n[n.InheritLineRouting=65536]="InheritLineRouting",n[n.ConnectToNearByNode=131072]="ConnectToNearByNode",n[n.ConnectToNearByPort=262144]="ConnectToNearByPort",n[n.ConnectToNearByElement=393216]="ConnectToNearByElement",n[n.InheritSegmentThumbShape=524288]="InheritSegmentThumbShape",n[n.InheritSegmentThumbSize=1048576]="InheritSegmentThumbSize",n[n.Default=2043454]="Default",n}(qe||{}),Nr=function(n){return n[n.ReadOnly=2]="ReadOnly",n[n.InheritReadOnly=4]="InheritReadOnly",n[n.Select=8]="Select",n[n.Drag=16]="Drag",n[n.Resize=32]="Resize",n[n.Rotate=64]="Rotate",n[n.Tooltip=128]="Tooltip",n[n.Interaction=120]="Interaction",n[n.None=0]="None",n}(Nr||{}),ie=function(n){return n[n.None=0]="None",n[n.Select=2]="Select",n[n.Drag=4]="Drag",n[n.Rotate=8]="Rotate",n[n.Shadow=16]="Shadow",n[n.PointerEvents=32]="PointerEvents",n[n.Delete=64]="Delete",n[n.InConnect=128]="InConnect",n[n.OutConnect=256]="OutConnect",n[n.Individual=512]="Individual",n[n.Expandable=1024]="Expandable",n[n.AllowDrop=2048]="AllowDrop",n[n.Inherit=78]="Inherit",n[n.ResizeNorthEast=4096]="ResizeNorthEast",n[n.ResizeEast=8192]="ResizeEast",n[n.ResizeSouthEast=16384]="ResizeSouthEast",n[n.ResizeSouth=32768]="ResizeSouth",n[n.ResizeSouthWest=65536]="ResizeSouthWest",n[n.ResizeWest=131072]="ResizeWest",n[n.ResizeNorthWest=262144]="ResizeNorthWest",n[n.ResizeNorth=524288]="ResizeNorth",n[n.Resize=1044480]="Resize",n[n.AspectRatio=1048576]="AspectRatio",n[n.Tooltip=2097152]="Tooltip",n[n.InheritTooltip=4194304]="InheritTooltip",n[n.ReadOnly=8388608]="ReadOnly",n[n.HideThumbs=16777216]="HideThumbs",n[n.AllowMovingOutsideLane=33554432]="AllowMovingOutsideLane",n[n.Default=5240814]="Default",n}(ie||{}),Xr=function(n){return n[n.None=0]="None",n[n.ElementIsPort=2]="ElementIsPort",n[n.ElementIsGroup=4]="ElementIsGroup",n[n.HorizontalLaneHeader=8]="HorizontalLaneHeader",n}(Xr||{}),bt=function(n){return n[n.Rotate=2]="Rotate",n[n.ConnectorSource=4]="ConnectorSource",n[n.ConnectorTarget=8]="ConnectorTarget",n[n.ResizeNorthEast=16]="ResizeNorthEast",n[n.ResizeEast=32]="ResizeEast",n[n.ResizeSouthEast=64]="ResizeSouthEast",n[n.ResizeSouth=128]="ResizeSouth",n[n.ResizeSouthWest=256]="ResizeSouthWest",n[n.ResizeWest=512]="ResizeWest",n[n.ResizeNorthWest=1024]="ResizeNorthWest",n[n.ResizeNorth=2048]="ResizeNorth",n[n.Default=4094]="Default",n}(bt||{}),nt=function(n){return n[n.None=1]="None",n[n.Bridging=2]="Bridging",n[n.UndoRedo=4]="UndoRedo",n[n.Tooltip=8]="Tooltip",n[n.UserInteraction=16]="UserInteraction",n[n.ApiUpdate=32]="ApiUpdate",n[n.PageEditable=48]="PageEditable",n[n.Zoom=64]="Zoom",n[n.PanX=128]="PanX",n[n.PanY=256]="PanY",n[n.Pan=384]="Pan",n[n.ZoomTextEdit=512]="ZoomTextEdit",n[n.Virtualization=1024]="Virtualization",n[n.LineRouting=2048]="LineRouting",n[n.Default=500]="Default",n}(nt||{}),ri=function(n){return n[n.None=0]="None",n[n.SingleSelect=1]="SingleSelect",n[n.MultipleSelect=2]="MultipleSelect",n[n.ZoomPan=4]="ZoomPan",n[n.DrawOnce=8]="DrawOnce",n[n.ContinuousDraw=16]="ContinuousDraw",n[n.Default=3]="Default",n}(ri||{}),Qa=function(n){return n[n.Self=1]="Self",n[n.Parent=2]="Parent",n}(Qa||{}),ft=function(n){return n[n.None=0]="None",n[n.Control=1]="Control",n[n.Meta=1]="Meta",n[n.Alt=2]="Alt",n[n.Shift=4]="Shift",n}(ft||{}),Mt=function(n){return n[n.None=null]="None",n[n.Number0=0]="Number0",n[n.Number1=1]="Number1",n[n.Number2=2]="Number2",n[n.Number3=3]="Number3",n[n.Number4=4]="Number4",n[n.Number5=5]="Number5",n[n.Number6=6]="Number6",n[n.Number7=7]="Number7",n[n.Number8=8]="Number8",n[n.Number9=9]="Number9",n[n.A=65]="A",n[n.B=66]="B",n[n.C=67]="C",n[n.D=68]="D",n[n.E=69]="E",n[n.F=70]="F",n[n.G=71]="G",n[n.H=72]="H",n[n.I=73]="I",n[n.J=74]="J",n[n.K=75]="K",n[n.L=76]="L",n[n.M=77]="M",n[n.N=78]="N",n[n.O=79]="O",n[n.P=80]="P",n[n.Q=81]="Q",n[n.R=82]="R",n[n.S=83]="S",n[n.T=84]="T",n[n.U=85]="U",n[n.V=86]="V",n[n.W=87]="W",n[n.X=88]="X",n[n.Y=89]="Y",n[n.Z=90]="Z",n[n.Left=37]="Left",n[n.Up=38]="Up",n[n.Right=39]="Right",n[n.Down=40]="Down",n[n.Escape=27]="Escape",n[n.Space=32]="Space",n[n.PageUp=33]="PageUp",n[n.PageDown=34]="PageDown",n[n.End=35]="End",n[n.Home=36]="Home",n[n.Delete=46]="Delete",n[n.Tab=9]="Tab",n[n.Enter=13]="Enter",n[n.BackSpace=8]="BackSpace",n[n.F1=112]="F1",n[n.F2=113]="F2",n[n.F3=114]="F3",n[n.F4=115]="F4",n[n.F5=116]="F5",n[n.F6=117]="F6",n[n.F7=118]="F7",n[n.F8=119]="F8",n[n.F9=120]="F9",n[n.F10=121]="F10",n[n.F11=122]="F11",n[n.F12=123]="F12",n[n.Star=56]="Star",n[n.Plus=187]="Plus",n[n.Minus=189]="Minus",n[n.BracketLeft=219]="BracketLeft",n[n.BracketRight=221]="BracketRight",n}(Mt||{}),ee=function(n){return n[n.Render=2]="Render",n[n.PublicMethod=4]="PublicMethod",n[n.ToolAction=8]="ToolAction",n[n.UndoRedo=16]="UndoRedo",n[n.TextEdit=32]="TextEdit",n[n.Group=64]="Group",n[n.Clear=128]="Clear",n[n.PreventClearSelection=256]="PreventClearSelection",n[n.Interactions=512]="Interactions",n[n.PreventHistory=1024]="PreventHistory",n[n.PreventIconsUpdate=2048]="PreventIconsUpdate",n[n.PreventCollectionChangeOnDragOver=4096]="PreventCollectionChangeOnDragOver",n[n.PreventZIndexOnDragging=8192]="PreventZIndexOnDragging",n[n.isGroupDragging=16384]="isGroupDragging",n[n.DragUsingMouse=32768]="DragUsingMouse",n[n.DecoratorPropertyChange=65536]="DecoratorPropertyChange",n[n.PreventLaneContainerUpdate=131072]="PreventLaneContainerUpdate",n}(ee||{}),Ga=function(n){return n[n.None=2]="None",n[n.DrawSelectorBorder=4]="DrawSelectorBorder",n[n.PreventRenderSelector=8]="PreventRenderSelector",n}(Ga||{}),$i=function(n){return n[n.None=0]="None",n[n.PreventDrag=2]="PreventDrag",n[n.PreventScale=4]="PreventScale",n[n.PreventDataInit=8]="PreventDataInit",n[n.hScrollbarMoved=16]="hScrollbarMoved",n[n.vScrollbarMoved=32]="vScrollbarMoved",n[n.AnimationClick=64]="AnimationClick",n[n.EnableGroupAction=128]="EnableGroupAction",n[n.PanInProgress=256]="PanInProgress",n[n.OverViewAction=512]="OverViewAction",n}($i||{}),da=function(n){return n[n.None=0]="None",n[n.PropertyChange=1024]="PropertyChange",n[n.Interaction=2048]="Interaction",n}(da||{}),Ae=function(n){return n[n.Zero=0]="Zero",n[n.One=1]="One",n[n.Two=2]="Two",n[n.Three=3]="Three",n[n.Four=4]="Four",n[n.Five=5]="Five",n}(Ae||{}),Ce=function(n){return n[n.collectionChange=0]="collectionChange",n[n.rotateChange=1]="rotateChange",n[n.positionChange=2]="positionChange",n[n.propertyChange=3]="propertyChange",n[n.selectionChange=4]="selectionChange",n[n.sizeChange=5]="sizeChange",n[n.drop=6]="drop",n[n.sourcePointChange=7]="sourcePointChange",n[n.targetPointChange=8]="targetPointChange",n[n.connectionChange=9]="connectionChange",n[n.animationComplete=10]="animationComplete",n[n.click=11]="click",n[n.doubleClick=12]="doubleClick",n[n.scrollChange=13]="scrollChange",n[n.dragEnter=14]="dragEnter",n[n.dragLeave=15]="dragLeave",n[n.dragOver=16]="dragOver",n[n.textEdit=17]="textEdit",n[n.paletteSelectionChange=18]="paletteSelectionChange",n[n.historyChange=19]="historyChange",n[n.mouseEnter=20]="mouseEnter",n[n.mouseLeave=21]="mouseLeave",n[n.mouseOver=22]="mouseOver",n[n.expandStateChange=23]="expandStateChange",n[n.segmentCollectionChange=24]="segmentCollectionChange",n[n.commandExecute=25]="commandExecute",n[n.historyStateChange=26]="historyStateChange",n[n.onUserHandleMouseDown=27]="onUserHandleMouseDown",n[n.onUserHandleMouseUp=28]="onUserHandleMouseUp",n[n.onUserHandleMouseEnter=29]="onUserHandleMouseEnter",n[n.onUserHandleMouseLeave=30]="onUserHandleMouseLeave",n[n.onImageLoad=31]="onImageLoad",n[n.onDoBindingInit=32]="onDoBindingInit",n[n.keyUp=33]="keyUp",n[n.keyDown=34]="keyDown",n[n.fixedUserHandleClick=35]="fixedUserHandleClick",n[n.elementDraw=36]="elementDraw",n[n.mouseWheel=37]="mouseWheel",n[n.segmentChange=38]="segmentChange",n[n.onFixedUserHandleMouseDown=39]="onFixedUserHandleMouseDown",n[n.onFixedUserHandleMouseUp=40]="onFixedUserHandleMouseUp",n[n.onFixedUserHandleMouseEnter=41]="onFixedUserHandleMouseEnter",n[n.onFixedUserHandleMouseLeave=42]="onFixedUserHandleMouseLeave",n[n.loaded=43]="loaded",n}(Ce||{}),oi=function(n){return n[n.None=1]="None",n[n.Drag=2]="Drag",n[n.Draw=4]="Draw",n[n.InConnect=8]="InConnect",n[n.OutConnect=16]="OutConnect",n[n.ToolTip=32]="ToolTip",n[n.InheritTooltip=64]="InheritTooltip",n[n.Default=24]="Default",n}(oi||{}),Ex=function(n){return n[n.None=1]="None",n[n.Source=2]="Source",n[n.Target=4]="Target",n[n.Intermediate=8]="Intermediate",n[n.All=14]="All",n}(Ex||{}),DI=function(n){return n[n.None=0]="None",n[n.SymmetricAngle=2]="SymmetricAngle",n[n.SymmetricDistance=4]="SymmetricDistance",n[n.Default=6]="Default",n}(DI||{}),hs=function(){function n(){this.pivot={x:.5,y:.5},this.isDirt=!0,this.isExport=!1,this.exportScaleValue={x:0,y:0},this.exportScaleOffset={x:0,y:0},this.canApplyStyle=!0,this.visible=!0,this.offsetX=0,this.offsetY=0,this.cornerRadius=0,this.minHeight=void 0,this.minWidth=void 0,this.maxWidth=void 0,this.maxHeight=void 0,this.width=void 0,this.height=void 0,this.rotateAngle=0,this.margin={left:0,right:0,top:0,bottom:0},this.connectionDirection="Auto",this.horizontalAlignment="Auto",this.verticalAlignment="Auto",this.flip="None",this.flipMode="All",this.relativeMode="Point",this.transform=Qa.Self|Qa.Parent,this.style={fill:"white",strokeColor:"black",opacity:1,strokeWidth:1},this.desiredSize=new me,this.actualSize=new me,this.parentTransform=0,this.preventContainer=!1,this.isSvgRender=!1,this.bounds=new Ne(0,0,0,0),this.shadow=null,this.description="",this.staticSize=!1,this.shapeType="",this.isRectElement=!1,this.isCalculateDesiredSize=!0,this.flipOffset={x:0,y:0},this.elementActions=Xr.None,this.inversedAlignment=!0,this.position=void 0,this.unitMode=void 0,this.float=!1,this.floatingBounds=void 0}return n.prototype.setOffsetWithRespectToBounds=function(t,e,i){this.unitMode=i,this.position={x:t,y:e}},n.prototype.getAbsolutePosition=function(t){if(void 0!==this.position)return"Absolute"===this.unitMode?this.position:{x:this.position.x*t.width,y:this.position.y*t.height}},Object.defineProperty(n.prototype,"outerBounds",{get:function(){return this.floatingBounds||this.bounds},set:function(t){this.floatingBounds=t},enumerable:!0,configurable:!0}),n.prototype.measure=function(t,e,i){var s=void 0!==this.height?this.height:(t.height||0)-this.margin.top-this.margin.bottom;return this.id&&0===s&&this.elementActions&Xr.HorizontalLaneHeader&&(s=this.actualSize.height),this.desiredSize=new me(void 0!==this.width?this.width:(t.width||0)-this.margin.left-this.margin.right,s),this.isCalculateDesiredSize&&(this.desiredSize=this.validateDesiredSize(this.desiredSize,t)),this.desiredSize},n.prototype.arrange=function(t){return this.actualSize=t,this.updateBounds(),this.actualSize},n.prototype.updateBounds=function(){this.bounds=yr(this)},n.prototype.validateDesiredSize=function(t,e){return this.isRectElement&&!this.width&&!this.minWidth&&!this.maxWidth&&(t.width=50),this.isRectElement&&!this.height&&!this.minHeight&&!this.maxHeight&&(t.height=50),(void 0===t||void 0!==this.width&&void 0!==this.height)&&((t=t||new me).width=void 0===this.width?(e.width||0)-this.margin.left-this.margin.right:this.width,t.height=void 0===this.height?(e.height||0)-this.margin.top-this.margin.bottom:this.height),void 0!==this.minWidth&&(t.width=Math.max(t.width,this.minWidth)),void 0!==this.minHeight&&(t.height=Math.max(t.height,this.minHeight)),void 0!==this.maxWidth&&0!==this.maxWidth&&(t.width=Math.min(t.width,this.maxWidth)),void 0!==this.maxHeight&&0!==this.maxHeight&&(t.height=Math.min(t.height,this.maxHeight)),t},n}(),ere=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Cs=function(n){function t(){var e=null!==n&&n.apply(this,arguments)||this;return e.padding=new Yie(0,0,0,0),e.desiredBounds=void 0,e.measureChildren=!0,e.prevRotateAngle=0,e}return ere(t,n),t.prototype.hasChildren=function(){return void 0!==this.children&&this.children.length>0},t.prototype.measure=function(e,i,r){this.desiredBounds=void 0;var o,a,s=void 0;if(this.hasChildren()){for(var l=0;l=n.width&&s.length>0)i[i.length]={text:s,x:0,dy:0,width:o},s="";else{(s+=a[r+1]||"").indexOf("\n")>-1&&(i[i.length]={text:s,x:0,dy:0,width:_c(s,n)},s="");var l=_c(s,n);Math.ceil(l)+2>=n.width&&s.length>0&&(i[i.length]={text:s,x:0,dy:0,width:l},s=""),r===a.length-1&&s.length>0&&(i[i.length]={text:s,x:0,dy:0,width:l},s="")}else i=function Soe(n,t,e){var c,d,u,f,i=[],r="",s=0,o=0,a="nowrap"!==n.whiteSpace,h=(t||n.content).split("\n");for(s=0;s0?" ":"")+c[parseInt(o.toString(),10)];var p=_c(d=c[o+1]?r+" "+c[o+1]:r,n);Math.floor(p)>(e||n.width)-2&&r.length>0?(i[i.length]={text:r,x:0,dy:0,width:d===r?p:r===f?u:_c(r,n)},r=""):o===c.length-1&&(i[i.length]={text:r,x:0,dy:0,width:p},r=""),f=d,u=p}return i}(n,t,e);else i[i.length]={text:a,x:0,dy:0,width:_c(a,n)};return i}(l,r,n.isLaneOrientation?i:void 0),n.wrapBounds=a=function Ioe(n,t){var r,s,e={x:0,width:0},i=0;for(i=0;in.width&&("Ellipsis"===n.textOverflow||"Clip"===n.textOverflow)?0:-r/2:"right"===n.textAlign?-r:t.length>1?0:-r/2,t[parseInt(i.toString(),10)].dy=1.2*n.fontSize,t[parseInt(i.toString(),10)].x=r,e.x=Math.min(e.x,r),e.width=Math.max(e.width,s);return e}(l,o),s.width=a.width,n.wrapBounds.width>=i&&"Wrap"!==l.textOverflow&&(s.width=i),s.height=o.length*n.style.fontSize*1.2,s}(this,0,0,this.isLaneOrientation?e.height:this.width||e.width):this.desiredSize,this.desiredSize=void 0===this.width||void 0===this.height?new me(i.width,i.height):new me(this.width,this.height),this.desiredSize=this.validateDesiredSize(this.desiredSize,e),this.desiredSize},t.prototype.arrange=function(e){return(e.width!==this.actualSize.width||e.height!==this.actualSize.height||this.isDirt)&&(this.doWrap=!0),this.actualSize=e,this.updateBounds(),this.isDirt=!1,this.actualSize},t}(hs),ire=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Mi=function(n){function t(){var e=null!==n&&n.apply(this,arguments)||this;return e.measureChildren=void 0,e}return ire(t,n),t.prototype.measure=function(e,i,r){var s=void 0,o=void 0;if(this.hasChildren()){for(var a=0,l=this.children;a=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Ad=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return are(t,n),Rh([I("")],t.prototype,"content",void 0),Rh([I("TopLeft")],t.prototype,"position",void 0),Rh([I("Mouse")],t.prototype,"relativeMode",void 0),Rh([I(!0)],t.prototype,"showTipPointer",void 0),Rh([I("auto")],t.prototype,"width",void 0),Rh([I("auto")],t.prototype,"height",void 0),Rh([I("Auto")],t.prototype,"openOn",void 0),Rh([I()],t.prototype,"animation",void 0),Rh([I(!1)],t.prototype,"isSticky",void 0),t}(Ee);function l3(n){var t=new Eh;t=h3(n.tooltip,t);var e=new Eh(t);return e.beforeCollision=hre,e.beforeOpen=lre,e.cssClass="e-diagram-tooltip",e.opensOn="custom",e.appendTo("#"+n.element.id),e.close(),e}function lre(n){(""===this.content||void 0===this.content)&&(n.element.style.display="none")}function hre(n){n.collidedPosition&&n.collidedPosition!==this.position&&(n.element.style.display="none")}function Dx(n,t){var e=n.tooltipObject;return h3(t?t.tooltip:n.tooltip,e),e}function h3(n,t){return n.content?(t.content=n.content,"string"==typeof n.content&&(t.content=ko(function(){return n.content})),t.position=n.position,t.showTipPointer=n.showTipPointer,t.width=n.width,t.height=n.height,t.animation=n.animation?n.animation:{close:{effect:"None"}}):t.close(),t}var xx=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Bn=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Tx=function(n){function t(e,i,r,s){var o=n.call(this,e,i,r,s)||this;return o.inEdges=[],o.outEdges=[],o}return xx(t,n),Bn([I("")],t.prototype,"id",void 0),Bn([I("Center")],t.prototype,"horizontalAlignment",void 0),Bn([I("Center")],t.prototype,"verticalAlignment",void 0),Bn([re({},Jn)],t.prototype,"margin",void 0),Bn([I(12)],t.prototype,"width",void 0),Bn([I(12)],t.prototype,"height",void 0),Bn([re({},Nl)],t.prototype,"style",void 0),Bn([I("Square")],t.prototype,"shape",void 0),Bn([I("Auto")],t.prototype,"connectionDirection",void 0),Bn([I(ci.Connect)],t.prototype,"visibility",void 0),Bn([I("")],t.prototype,"pathData",void 0),Bn([I(oi.Default)],t.prototype,"constraints",void 0),Bn([I()],t.prototype,"addInfo",void 0),Bn([I()],t.prototype,"outEdges",void 0),Bn([I()],t.prototype,"inEdges",void 0),Bn([re({},Ad)],t.prototype,"tooltip",void 0),t}(Ee),Es=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return xx(t,n),t.prototype.getClassName=function(){return"PointPort"},Bn([re({x:.5,y:.5},R)],t.prototype,"offset",void 0),t}(Tx),Lc=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return xx(t,n),t.prototype.getClassName=function(){return"PathPort"},Bn([I(.5)],t.prototype,"offset",void 0),Bn([re({x:0,y:0},R)],t.prototype,"displacement",void 0),Bn([I("Center")],t.prototype,"alignment",void 0),t}(Tx),AI=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),lr=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},cre=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return AI(t,n),lr([I("blue")],t.prototype,"color",void 0),lr([I("")],t.prototype,"content",void 0),lr([I("")],t.prototype,"link",void 0),lr([I("None")],t.prototype,"textDecoration",void 0),lr([I("NewTab")],t.prototype,"hyperlinkOpenState",void 0),t}(Ee),Ax=function(n){function t(e,i,r,s){var o=n.call(this,e,i,r,s)||this;return r.id||(o.id=e.parentObj&&e.parentObj.propName&&"phases"===e.parentObj.propName?e.parentObj.id:Qe()),o}return AI(t,n),lr([I("")],t.prototype,"content",void 0),lr([I(void 0)],t.prototype,"template",void 0),lr([I("String")],t.prototype,"annotationType",void 0),lr([I(!0)],t.prototype,"visibility",void 0),lr([I(Nr.InheritReadOnly)],t.prototype,"constraints",void 0),lr([re(void 0,cre)],t.prototype,"hyperlink",void 0),lr([I("")],t.prototype,"id",void 0),lr([I()],t.prototype,"width",void 0),lr([I()],t.prototype,"height",void 0),lr([I(0)],t.prototype,"rotateAngle",void 0),lr([I("Parent")],t.prototype,"rotationReference",void 0),lr([re({strokeWidth:0,strokeColor:"transparent",fill:"transparent"},$f)],t.prototype,"style",void 0),lr([I("Center")],t.prototype,"horizontalAlignment",void 0),lr([I("Center")],t.prototype,"verticalAlignment",void 0),lr([re({},Jn)],t.prototype,"margin",void 0),lr([re({top:void 0,bottom:void 0,left:void 0,right:void 0},Jn)],t.prototype,"dragLimit",void 0),lr([I("Shape")],t.prototype,"type",void 0),lr([re({},Ad)],t.prototype,"tooltip",void 0),lr([I()],t.prototype,"addInfo",void 0),t}(Ee),Kn=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return AI(t,n),t.prototype.getClassName=function(){return"ShapeAnnotation"},lr([re({x:.5,y:.5},R)],t.prototype,"offset",void 0),t}(Ax),Or=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return AI(t,n),t.prototype.getClassName=function(){return"PathAnnotation"},lr([I(.5)],t.prototype,"offset",void 0),lr([re({x:0,y:0},R)],t.prototype,"displacement",void 0),lr([I("Center")],t.prototype,"alignment",void 0),lr([I(!1)],t.prototype,"segmentAngle",void 0),t}(Ax);function Lx(n){return pre[n.toString()]}function c3(n){return mre[""+n]}var pre={X:"M14,14 L106,106 M106,14 L14,106",Circle:"M0,50 A50,50,0 1 1 100,50 A50,50,0 1 1 0,50 Z",Square:"M0,0 L10,0 L10,10 L0,10 z"},gre={OpenArrow:"M15.9,23 L5,16 L15.9,9 L17,10.7 L8.7,16 L17,21.3Z",Square:"M0,0 L10,0 L10,10 L0,10 z",Fletch:"M14.8,10c0,0-3.5,6,0.2,12c0,0-2.5-6-10.9-6C4.1,16,11.3,16,14.8,10z",OpenFetch:"M6,17c-0.6,0-1-0.4-1-1s0.4-1,1-1c10.9,0,11-5,11-5c0-0.6,0.4-1,1-1s1,0.4,1,1C19,10.3,18.9,17,6,17C6,17,6,17,6,17z M18,23c-0.5,0-1-0.4-1-1c0-0.2-0.3-5-11-5c-0.6,0-1-0.5-1-1s0.4-1,1-1c0,0,0,0,0,0c12.9,0,13,6.7,13,7 C19,22.6,18.6,23,18,23z",IndentedArrow:"M17,10c0,0-4.5,5.5,0,12L5,16L17,10z",OutdentedArrow:"M14.6,10c0,0,5.4,6,0,12L5,16L14.6,10z",DoubleArrow:"M19,10 L19,22 L13,16Z M12,10 L12,22 L6,16Z",Arrow:"M15,10 L15,22 L5,16Z",Diamond:"M12,23l-7-7l7-7l6.9,7L12,23z",Circle:"M0,50 A50,50,0 1 1 100,50 A50,50,0 1 1 0,50 Z"},vre={Square:"M0,0 L10,0 L10,10 L0,10 z",Rhombus:"M10,5 L5,10 L0,5 L5,0 L10,5 Z ",Rectangle:"M0,0 L15,0 L15,10 L0,10 z ",OpenArrow:"M15.9,23 L5,16 L15.9,9 L17,10.7 L8.7,16 L17,21.3Z",Fletch:"M9.82,0 C9.82,0,6.61,5,10,10 C10,10,7.71,5,0,5 C0,5,6.61,5,9.82,0 Z ",OpenFetch:"M0.71,5.71 C0.29,5.71,0,5.43,0,5 C0,4.57,0.29,4.29,0.71,4.29 C8.5,4.29,8.57,0.71,8.57,0.71 C8.57,0.29,8.86,0,9.29,0 C9.719999999999999,0,10,0.29,10,0.71 C10,0.93,9.93,5.71,0.71,5.71 C0.71,5.71,0.71,5.71,0.71,5.71 Z M9.29,10 C8.93,10,8.57,9.71,8.57,9.29 C8.57,9.14,8.36,5.71,0.71,5.71 C0.29,5.71,0,5.36,0,5 C0,4.64,0.29,4.29,0.71,4.29 C0.71,4.29,0.71,4.29,0.71,4.29 C9.93,4.29,10,9.07,10,9.29 C10,9.71,9.71,10,9.29,10 Z ",IndentedArrow:"M10,0 C10,0,6.25,4.58,10,10 L0,5 L10,0 Z ",OutdentedArrow:"M8,0 C8,0,12.5,5,8,10 L0,5 L8,0 Z ",DoubleArrow:"M19,10 L19,22 L13,16Z M12,10 L12,22 L6,16Z",Arrow:"M15,10 L15,22 L5,16Z",Diamond:"M10,5 L5,10 L0,5 L5,0 L10,5 Z ",Circle:"M10,5 C10,7.76,7.76,10,5,10 C2.24,10,0,7.76,0,5 C0,2.24,2.24,0,5,0 C7.76,0,10,2.24,10,5 Z ",Ellipse:"M15,5 C15,7.76,11.64,10,7.5,10 C3.36,10,0,7.76,0,5 C0,2.24,3.36,0,7.5,0 C11.64,0,15,2.24,15,5 Z "},mre={Square:"M0,0 L10,0 L10,10 L0,10 z",Rhombus:"M10,5 L5,10 L0,5 L5,0 L10,5 Z ",Rectangle:"M0,0 L15,0 L15,10 L0,10 z",OpenArrow:"M23,15.9 L16,5 L9,15.9 L10.7,17 L16,8.7 L21,17.3Z",Fletch:"M9.82,0 C9.82,0,6.61,5,10,10 C10,10,7.71,5,0,5 C0,5,6.61,5,9.82,0 Z ",OpenFetch:"M0.71,5.71 C0.29,5.71,0,5.43,0,5 C0,4.57,0.29,4.29,0.71,4.29 C8.5,4.29,8.57,0.71,8.57,0.71 C8.57,0.29,8.86,0,9.29,0 C9.719999999999999,0,10,0.29,10,0.71 C10,0.93,9.93,5.71,0.71,5.71 C0.71,5.71,0.71,5.71,0.71,5.71 Z M9.29,10 C8.93,10,8.57,9.71,8.57,9.29 C8.57,9.14,8.36,5.71,0.71,5.71 C0.29,5.71,0,5.36,0,5 C0,4.64,0.29,4.29,0.71,4.29 C0.71,4.29,0.71,4.29,0.71,4.29 C9.93,4.29,10,9.07,10,9.29 C10,9.71,9.71,10,9.29,10 Z ",IndentedArrow:"M10,0 C10,0,6.25,4.58,10,10 L0,5 L10,0 Z ",OutdentedArrow:"M8,0 C8,0,12.5,5,8,10 L0,5 L8,0 Z ",DoubleArrow:"M10,19 L22,19 L16,13Z M10,12 L22,12 L16,6Z",Arrow:"M10,15 L22,15 L16,5Z",Diamond:"M10,5 L5,10 L0,5 L5,0 L10,5 Z ",Circle:"M10,5 C10,7.76,7.76,10,5,10 C2.24,10,0,7.76,0,5 C0,2.24,2.24,0,5,0 C7.76,0,10,2.24,10,5 Z ",Ellipse:"M15,5 C15,7.76,11.64,10,7.5,10 C3.36,10,0,7.76,0,5 C0,2.24,3.36,0,7.5,0 C11.64,0,15,2.24,15,5 Z "};function Nx(n){return yre[n.toString()]}var yre={Process:"M419.511,76.687L359.511,76.687L359.511,43.086L419.511,43.086z",Decision:"M 253.005,115.687L 200.567,146.071L 148.097,115.687L 200.534,85.304L 253.005,115.687 Z",Document:"M 60 31.9 c 0 0 -11 -7.7 -30 0 s -30 0 -30 0 V 0 h 60 V 31.9 Z",PreDefinedProcess:"M 0,0 L 50,0 L 50,50 L 0,50 Z M 8.334,0 L 8.334,50 M 41.667,0 L 41.667,50",Terminator:"M 269.711,29.33C 269.71,44.061 257.77,56 243.04,56L 158.058,56C 143.33,56 131.39,44.061 131.39,29.33L 131.39,29.33C 131.391,14.6057 143.33,2.669 158.058,2.669L 243.044,2.669C 257.772,2.669 269.711,14.6057 269.711,29.333 Z",PaperTap:"M0.0009,17.2042 L0.0009,47.165 C0.001,47.165 14.403,53.5455 25.00,47.165 C35.599,40.7852 44.403,43.5087 50.00,47.165L50.001,17.2042 M50.001,32.7987 L50.001,2.8405 C50.001,2.8405 35.599,-3.5427 25.001,2.8405C14.403,9.2237 5.599,6.494 0.0009,2.8405 L0.0009,32.7987",DirectData:"M 132.62 0 L 17.38 0 C 7.78 0 0 13.43 0 30 C 0 46.57 7.78 60 17.38 60 L 132.62 60 M 132.62 0C 123.02 0 115.24 13.43 115.24 30 C 115.24 46.57 123.02 60 132.62 60 C 142.22 60 150 46.57 150 30 C 150 13.43 142.22 0 132.62 0 z ",SequentialData:"M0.0029,24.999 C0.0029,11.1922 10.433,0.0021 23.295,0.0021 C36.159,0.00216 46.585,11.1922 46.585,24.999C46.585,38.8057 36.159,49.9979 23.295,49.9979 C10.433,49.9979 0.0029,38.8057 0.0029,24.999 z M23.294,49.999 L50.002,49.999",Sort:"M50.001,24.9971 L25.001,49.9971 L0.00097,24.9971 L25.001,-0.00286865 L50.001,24.9971 z M0.000976562,24.9971 L50.001,24.9971",MultiDocument:"M43.6826,40 C44.8746,40.6183 45.8586,41.3502 46.8366,42.1122 L46.8366,4.74487 L3.09857,4.74487 L3.09857,10.9544 M46.837,35.143 C48.027,35.765 49.025,36.604 50.003,37.369 L50.003,0.002 L6.264,0.002 L6.264,4.744 M43.682,47.113 L43.682,10.765 L0.0025,10.7652 L0.0025,47.1132 C0.0025,47.1132 12.5846,53.6101 21.8426,47.1132 C31.1006,40.6163 38.792,43.393 43.6826,47.1132 z",Collate:"M50.001,0.0028 L25.001,25.0029 L0.00097,0.0028 L50.001,0.002 z M0.0009,50.002 L25.001,25.002L50.001,50.002 L0.0009,50.0029 z",SummingJunction:"M7.3252,42.6768 L42.6772,7.3247 M42.6768,42.6768 L7.3248,7.3247 M0.0009,25.001 C0.0009,11.193 11.197,0.0009 25.001,0.0009 C38.809,0.0009 50.001,11.193 50.001,25.001 C50.001,38.809 38.809,50.001 25.001,50.001 C11.197,50.00 0.0009,38.809 0.0009,25.00 z",Or:"M 0 50 L 100 50 M 50 100 L 50 0.0 M 0 50 C 0 22.384 22.392 0 50 0 C 77.616 0 100 22.384 100 50 C 100 77.616 77.616 100 50 100 C 22.392 100 0 77.616 0 50 Z",InternalStorage:"M 0 3.81946A 2.5,3.81946 0 0,1 2.5,0L 47.5 0A 2.5,3.81946 0 0,1 50,3.81946L 50 45.836A 2.5,3.819446 0 0,1 47.5,49.652778L 2.5 49.652778A 2.5,3.819446 0 0,1 0,45.8336L 0 3.819446ZM 0 11.45834L 50 11.4583334M 12.5 0L 12.5 49.652778",Extract:"M0,35 L30,0 L60,35 Z",ManualOperation:"M46.4,28.8 L14.8,28.8 L0,0 L60,0 Z",Merge:"M60,0 L30,35 L0,0 Z",OffPageReference:"M60,33.3 L30.1,39 L0,33.3 L0,0 L60,0 Z",SequentialAccessStorage:"M 60 30 C 60 13.4 46.6 0 30 0 S 0 13.4 0 30 s 13.4 30 30 30 h 28.6 v -6.5 h -9.9C 55.5 48 60 39.5 60 30 Z",Annotation:"M49.9984,50.0029 L-0.00271199,50.0029 L-0.00271199,0.00286865 L49.9984,0.00286865",Annotation2:"M49.9977,50.0029 L25.416,50.0029 L25.416,0.00286865 L49.9977,0.00286865 M25.4166,25.0029 L-0.00227869,25.0029",Data:"M 10 0 L 40 0 L 30 40 L 0 40 Z",Card:"M275,60 L400,60 L400,110 L260,110 L260,75 Z",Delay:"M0,0 L12.029,0 C14.212999,0 16,1.7869979 16,3.9709952 C16,6.1549926 14.212999,7.9409904 12.029,7.9409904 L0,7.9409904 z",Preparation:"M 1048.17 572 C 1051.06 568.86 1055.17 567.05 1059.5 567 L 1094.51 567 C 1098.84 567.05 1102.95 568.86 1105.84 572 L 1126.43 595 C 1127.01 596.28 1127.01 597.72 1126.43 599 L 1105.84 622 C 1102.95 625.14 1098.84 626.95 1094.51 627 L 1059.5 627 C 1055.17 626.95 1051.06 625.14 1048.17 622 L 1027.58 599 C 1027 597.72 1027 596.28 1027.58 595 L 1048.17 572 Z",Display:"M47.8809,19.2914 L32.7968,-0.00594145 L11.3902,-0.00594145 C7.93166,-0.00594145 0.00124586,11.187 0.00124586,24.9968C0.00124586,38.8032 7.93166,49.9962 11.3902,49.9962 L32.7968,49.99 L47.615,31.038 C47.615,31.0388 52.798,24.9968 47.880,19.2914 z",ManualInput:"M 912 732 L 1006.85 707 C 1008.2 707 1009.5 707.53 1010.46 708.46 C 1011.41 709.4 1011.95 710.67 1011.95 712 L 1011.95 762C 1012 764.41 1010.28 766.52 1007.87 767 L 917.1 767 C 915.75 767 914.45 766.47 913.49 765.54 C 912.54 764.6 912 763.33 912 762 L 912 732 Z",LoopLimit:"M 8 9 L 27 9 L 33 15 L 33 26 C 33 27 33 27 32 27 L 4 27 C 3 27 2 27 2 26 L 2 15 L 8 9 Z",StoredData:"M 5.55 0L 50 0A 1.5,30 0 0,1 50,0A 5.555,25 0 0,0 50,50A 1.5,30 0 0,1 50,50L 5.555 50A 5.55,25 0 0,1 5.555,0Z"};function d3(n,t,e){var i;i="Straight"!==n.type&&n.sourceWrapper?n.sourceWrapper.corners.center:function Sre(n){var t;if(n.sourcePortWrapper){var e=n.sourcePortWrapper;t={x:e.offsetX,y:e.offsetY}}else t=n.sourceID&&n.sourceWrapper&&n.targetWrapper?qa(n,0,n.sourceWrapper.corners.center,n.targetWrapper.corners.center,!1):n.sourcePoint;return t}(n);var r=function bre(n,t,e,i,r){var b,M,s=n.sourceWrapper,o=n.targetWrapper,a=n.sourcePortWrapper,l=n.targetPortWrapper,d=[],p=Xa(n),y={corners:undefined,point:t,direction:undefined,margin:{left:5,right:5,bottom:5,top:5}},S={corners:undefined,point:e,direction:undefined,margin:{left:5,right:5,bottom:5,top:5}};if(void 0!==s&&void 0!==o&&(b=xn(s),M=xn(o),y.corners=s.corners,S.corners=o.corners),void 0!==a&&(y.direction="Left"===a.connectionDirection||"Top"===a.connectionDirection||"Bottom"===a.connectionDirection||"Right"===a.connectionDirection?a.connectionDirection:zo({x:a.offsetX,y:a.offsetY},b,s.bounds)),void 0!==l&&(S.direction="Left"===l.connectionDirection||"Right"===l.connectionDirection||"Bottom"===l.connectionDirection||"Top"===l.connectionDirection?l.connectionDirection:zo({x:l.offsetX,y:l.offsetY},M,o.bounds)),"Bezier"===n.type&&!n.isBezierEditing&&n.segments.length>0)for(var D=n.segments.length-1;D>=0;)n.segments[parseInt(D.toString(),10)].isInternalSegment&&n.segments.pop(),D--;if(void 0!==s&&void 0!==o)return(void 0===y.direction||void 0===S.direction)&&(i?function Ire(n,t,e){"LeftToRight"===e?(n.direction=n.direction?n.direction:"Right",t.direction=t.direction?t.direction:"Left"):"RightToLeft"===e?(n.direction=n.direction?n.direction:"Left",t.direction=t.direction?t.direction:"Right"):"TopToBottom"===e?(n.direction=n.direction?n.direction:"Bottom",t.direction=t.direction?t.direction:"Top"):"BottomToTop"===e&&(n.direction=n.direction?n.direction:"Top",t.direction=t.direction?t.direction:"Bottom")}(y,S,i):y.corners.top>S.corners.bottom&&Math.abs(y.corners.top-S.corners.bottom)>p?(y.direction=y.direction?y.direction:"Top",S.direction=S.direction?S.direction:"Bottom"):y.corners.bottomp?(y.direction=y.direction?y.direction:"Bottom",S.direction=S.direction?S.direction:"Top"):y.corners.rightp||y.corners.right+p=y.corners.left-p&&y.corners.left>S.corners.left?(y.direction=y.direction?y.direction:"Right",S.direction=S.direction?S.direction:"Left"):y.corners.left>S.corners.right&&Math.abs(y.corners.left-S.corners.right)>y.margin.left+y.margin.right||S.corners.right+p=S.corners.left-p&&y.corners.left0&&n.segments[0].direction&&(y.direction=n.segments[0].direction),y.point=Ol(b,y.direction),d=Ol(b,_n(y.direction)),y.point=qa(n,0,y.point,d,!1)):y.point=o.corners.center;if(void 0!==h){switch(S.point={x:h.offsetX,y:h.offsetY},S.direction){case"Bottom":case"Top":S.point.y=S.point.y;break;case"Left":case"Right":S.point.x=S.point.x}n.targetPadding&&!w&&(S.point=LI(n,y,S,!0))}else"Orthogonal"===n.type||"Bezier"===n.type?(S.point=Ol(M,S.direction),d=Ol(M,_n(S.direction)),S.point=qa(n,0,S.point,d,!0)):S.point=a.corners.center;if("Orthogonal"!==n.type){var C=void 0,D=void 0;if("Bezier"===n.type){if(n.bezierSettings.allowSegmentsReset||0===n.segments.length||!R.isEmptyPoint(n.segments[n.segments.length-1].point))return c=b3(n,y,S,void 0,s),Ox(n,y,S);Uv(n)}else Uv(n);if(void 0===n.sourcePortWrapper){y.point=y.corners.center,n.segments&&n.segments.length>0&&(C=R.isEmptyPoint((D=n.segments[0]).point)?void 0:D);var A=void 0!==C?C.point:S.point;if("Bezier"===n.type&&n.segments.length>0&&n.segments[0].vector1.angle&&n.segments[0].vector1.distance){var x=Math.max(y.corners.width,y.corners.height);A=R.transform(y.point,n.segments[0].vector1.angle,x/2)}y.point=w?n.sourceWrapper.bounds.center:qa(n,0,y.point,A,!1)}if(void 0===n.targetPortWrapper){S.point=S.corners.center,n.segments&&n.segments.length>1&&(C=R.isEmptyPoint((D=n.segments[n.segments.length-2]).point)?void 0:D);var P=C?C.point:y.point;"Bezier"===n.type&&n.segments.length>0&&n.segments[n.segments.length-1].vector2.angle&&n.segments[n.segments.length-1].vector2.distance&&(x=Math.max(y.corners.width,y.corners.height),P=R.transform(S.point,n.segments[0].vector2.angle,x/2)),S.point=w?n.targetWrapper.bounds.center:qa(n,0,P,S.point,!0)}c=Ox(n,y,S)}else"Orthogonal"===n.type&&n.segments&&n.segments.length>0&&null!==n.segments[0].direction?c=function Nre(n,t,e,i,r,s,o){var a,h,c,d;Uv(n);for(var u=0;u0&&n.segments[u-1].direction===h.direction?u=y3(n,u,t):h.direction?t.point=u3(t,n.segments[parseInt(u.toString(),10)]):(f=n.segments[u-1])&&f.points&&f.points.length>0&&(t.point=f.points[f.points.length-1]),u===n.segments.length-1)if(S3(n,t),v3(a=void 0===r?Lre(n,t,e):p3(n,t,e),n),h.points=[],a.length>=2)for(c=0;c2&&n.segments.length>2){var p={x:a[parseInt(c.toString(),10)].x,y:t.point.y};h.points=[],h.points.push(p),h.points.push(a[parseInt(c.toString(),10)]);var f=n.segments[u-1];n.segments.length<4&&f.points.pop(),f.points=f.points.concat(h.points)}else h.points.push(a[parseInt(c.toString(),10)]);else h.points.push(a[parseInt(c.toString(),10)]);else d=u;if(void 0!==d&&!n.selectedSegmentIndex&&(d===n.segments.length-1&&(n.segments[d-1].direction=null,n.segments[d-1].length=null),n.segments.splice(d,1)),i&&0===u){var g=g3(n,i,s);g&&(t.point=g)}}return I3(n,[])}(n,y,S,l,h,o):(n.segments[0]||(C=new wi(n,"segments",{type:"Orthogonal"},!0),n.segments.push(C)),n.segments[0].points=c=b3(n,y,S,void 0,s));return c}(n,y.direction,S.direction,y.point,S.point,r);if(Uv(n),(n.sourceWrapper||n.targetWrapper)&&function Dre(n,t,e){var i=n.sourcePortWrapper,r=n.targetPortWrapper,s=n.sourceWrapper,o=t.point,a={left:0,right:0,top:0,bottom:0},l={x:0,y:0},c="Top";if(s?(o=e.point,a=t.margin):(s=n.targetWrapper,a=e.margin),"Orthogonal"===n.type)if(n.segments&&n.segments.length>0&&n.sourceWrapper&&n.segments[0].direction)t.direction=n.segments[0].direction,l=qa(n,0,l=Ol(s.corners,t.direction),Ol(s.corners,_n(t.direction)),!1);else{var u={corners:null,direction:null,point:null,margin:null};jv(s,{corners:null,direction:null,point:o,margin:a},u,n),l=u.point,c=u.direction}else{var f=void 0;n.segments&&n.segments.length>1&&(f=s===n.sourceWrapper?n.segments[0].point:n.segments[n.segments.length-2].point),l=qa(n,0,s.bounds.center,n.segments&&n.segments.length>1?f:o,s===n.targetWrapper)}s===n.sourceWrapper?(t.direction=t.direction||c,t.point=l,n.sourcePortWrapper&&(t.point={x:i.offsetX,y:i.offsetY},n.sourcePadding&&(t.point=LI(n,t,e,!1)))):(e.direction=e.direction||c,e.point=l,n.targetPortWrapper&&(e.point={x:r.offsetX,y:r.offsetY},n.targetPadding&&(e.point=LI(n,t,e,!0))))}(n,y,S),"Straight"===n.type||"Bezier"===n.type)d=Ox(n,y,S);else if("Orthogonal"===n.type&&n.segments&&n.segments.length>0&&null!==n.segments[0].length&&null!==n.segments[0].direction)d=function Ere(n,t,e,i,r,s,o){var a,l,c,u,h=[];if(Uv(n),n.segments.length>0){for(var f=0;f0&&n.segments[f-1].direction===p.direction)f=y3(n,f,t);else{var g=n.segments[f-1];t.point=p.direction?u3(t,p):g.points[g.points.length-1]}if(f===n.segments.length-1&&(o||r?n.targetWrapper&&void 0===n.targetPortWrapper?(S3(n,t),l=wre(n,t,e)):l=p3(n,t,e):l=Mre(n,t,e),l))if(v3(l,n),p.points=[],l.length>=2)for(a=0;at.corners.top&&e.point.ye.point.x?"Left":"Right"):e.point.x>t.corners.left&&e.point.xe.point.y?"Top":"Bottom")),n.sourcePortWrapper&&s===_n(r)?(("Left"===s||"Right"===s)&&t.point.y>=t.corners.top&&t.point.y<=t.corners.center.y&&e.point.y>=t.corners.top&&e.point.y<=t.corners.center.y?(t.direction="Top",a=t.point.y-t.corners.top+20):("Left"===s||"Right"===s)&&t.point.y>t.corners.center.y&&t.point.y<=t.corners.bottom&&e.point.y>t.corners.center.y&&e.point.y<=t.corners.bottom?(t.direction="Bottom",a=t.corners.bottom-t.point.y+20):("Top"===s||"Bottom"===s)&&t.point.x>=t.corners.left&&t.point.x<=t.corners.center.x&&e.point.x>=t.corners.left&&e.point.x<=t.corners.center.x?(t.direction="Left",a=t.point.x-t.corners.left+20):("Top"===s||"Bottom"===s)&&t.point.x<=t.corners.right&&t.point.x>t.corners.center.x&&e.point.x<=t.corners.right&&e.point.xt.point.y&&t.point.y>=e.corners.top?(i="Top",r=t.point.y-e.corners.top+20):e.corners.center.y===t.point.y&&"Top"===n.segments[n.segments.length-2].direction||e.corners.center.ye.point.y?t.point.y-t.corners.top+20:t.corners.bottom-t.point.y+20):(i="Top",r=e.corners.height/2+20):e.corners.center.x!==t.point.x||e.corners.topt.point.x&&t.point.x>=e.corners.left?(i="Left",r=t.point.x-e.corners.left+20):e.corners.center.x===t.point.x&&"Left"===n.segments[n.segments.length-2].direction||e.corners.center.x<=t.point.x&&t.point.x<=e.corners.right?(i="Right",r=e.corners.right-t.point.x+20):void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&t.corners.left<=t.point.x&&t.point.x<=t.corners.right&&(i=t.direction,r=t.point.x>e.point.x?t.point.x-t.corners.left+20:t.corners.right-t.point.x+20):(i="Left",r=e.corners.width/2+20);var a=t.point;t.point=Fn(t.point,"Left"===i||"Top"===i?-r:r,"Left"===i||"Right"===i?0:90),t.direction=R.direction(t.point,e.point),void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&(t.corners.center.x===e.corners.center.x||t.corners.center.y===e.corners.center.y)&&(t.direction=e.direction);var l=Ys(n,t,e);return l.splice(0,0,a),l}function p3(n,t,e){var i,r;e.corners=n.targetWrapper.corners,void 0!==n.sourcePortWrapper&&(r=zo({x:n.sourcePortWrapper.offsetX,y:n.sourcePortWrapper.offsetY},xn(n.sourceWrapper),n.sourceWrapper.bounds));var a=function Cre(n,t,e,i){var r=!1;switch(e.direction){case"Left":void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&"Right"===i&&t.point.x>e.point.x&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom||("Bottom"===i&&t.point.y>e.point.y||"Top"===i&&t.point.y=t.corners.left&&t.point.x<=t.corners.right?(t.direction="Right"===i?t.point.y>e.point.y?"Top":"Bottom":t.point.xe.point.x&&(t.point.y>e.point.y||t.point.yt.point.y&&e.corners.bottome.point.y||t.point.x>e.point.x&&t.point.y<=e.point.y&&e.corners.top=t.point.y?t.direction="Top":t.point.xe.point.x&&t.point.y>e.point.y&&e.corners.bottomt.point.y?t.direction="Bottom":t.point.y===e.point.y&&t.point.xe.point.y||"Top"===i&&t.point.ye.point.x&&t.point.x>=t.corners.left&&t.point.x<=t.corners.right?(t.direction=t.point.x>e.point.x?"Left":"Right",r=!0):void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&"Left"===i&&t.point.x=t.corners.top&&t.point.y<=t.corners.bottom?(t.direction=t.point.y>e.point.y?"Top":"Bottom",r=!0):t.point.x=t.point.y&&t.point.y===e.point.y||t.point.y>e.point.y&&t.point.x>e.point.x?t.direction="Top":t.point.ye.point.x?t.direction="Bottom":t.point.xe.point.y||t.point.ye.point.x&&(t.direction="Left");break;case"Top":void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&"Bottom"===i&&t.point.y>e.point.y&&t.point.x>=t.corners.left&&t.point.x<=t.corners.right||("Right"===i&&t.point.x>e.point.x||"Left"===i&&e.point.y>t.point.y&&e.point.x>t.point.x)&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom?(t.direction="Bottom"===i?t.point.x>e.point.x?"Left":"Right":t.point.ye.point.y&&t.point.x>e.corners.left&&t.point.x=e.point.y?t.direction="Top":t.point.ye.point.x?t.direction="Left":t.point.yt.point.x)&&t.point.y>e.point.y&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom||"Top"===i&&t.point.y=t.corners.left&&t.point.x<=t.corners.right)?(t.direction="Right"===i||"Left"===i?t.point.y>e.point.y?"Top":"Bottom":t.point.x>e.point.x?"Left":"Right",r=!0):t.point.ye.corners.left&&e.corners.right>t.point.x?t.point.ye.corners.left&&e.corners.center.x>=t.point.x?t.direction="Left":t.point.ye.point.y&&t.point.x>e.point.x?t.direction="Left":t.point.y>e.point.y&&t.point.xe.point.x||e.point.x>t.point.x)&&(t.direction="Bottom")}return r}(n,t,e,r);return!n.selectedSegmentIndex&&void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&e.direction===_n(r)&&(("Left"===e.direction&&t.point.x>e.point.x||"Right"===e.direction&&t.point.x=t.corners.top&&t.point.y<=t.corners.bottom||"Bottom"===e.direction&&t.point.y=t.corners.left&&t.point.x<=t.corners.right)?i=f3(n,t,e):n.selectedSegmentIndex||t.direction!==e.direction?!n.selectedSegmentIndex&&("Left"===e.direction&&t.point.x>e.point.x||"Right"===e.direction&&t.point.x=t.point.y||"Top"===e.direction&&t.point.y>e.point.y||"Bottom"===e.direction&&t.point.y=t.point.x?i=n.selectedSegmentIndex?kl(t,e):f3(n,t,e):!n.selectedSegmentIndex&&void 0!==n.sourceWrapper&&void 0!==n.targetWrapper&&void 0!==n.targetPortWrapper&&("Left"===t.direction||"Right"===t.direction)&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom&&("Top"===e.direction||"Bottom"===e.direction)&&e.corners.center.x===t.corners.center.x?(t.direction="Top"===e.direction?"Bottom":"Top",i=Ys(n,t,e,"Top"===e.direction?t.corners.bottom-t.point.y+20:t.point.y-t.corners.top+20)):!n.selectedSegmentIndex&&void 0!==n.sourceWrapper&&void 0!==n.targetWrapper&&void 0!==n.targetPortWrapper&&("Top"===t.direction||"Bottom"===t.direction)&&t.point.x>=t.corners.left&&t.point.x<=t.corners.right&&("Left"===e.direction||"Right"===e.direction)&&e.corners.center.y===t.corners.center.y?(t.direction="Left"===e.direction?"Right":"Left",i=Ys(n,t,e,"Left"===e.direction?t.corners.right-t.point.x+20:t.point.x-t.corners.left+20)):i=a?Ys(n,t,e,"Left"===t.direction||"Right"===t.direction?"Left"===t.direction?t.point.x-t.corners.left+20:t.corners.right-t.point.x+20:"Top"===t.direction?t.point.y-t.corners.top+20:t.corners.bottom-t.point.y+20):kl(t,e):i=Ys(n,t,e),i}function g3(n,t,e){var r,i={x:t.offsetX,y:t.offsetY},s=xn(e),o=zo(i,s,e.bounds),a=n.segments[0];return a.direction!==o&&(function Ore(n,t,e,i,r,s){var a,h,o=13,l=[];l.push(i),i.y===r.y&&("Left"===t&&r.xi.x)||i.x===r.x&&("Top"===t&&r.yi.y)||("Top"===t||"Bottom"===t?"Top"===t&&r.yi.y-o||"Bottom"===t&&r.y>i.y&&r.yo&&("Top"===t&&r.yi.y)?l.push({x:i.x,y:r.y}):(a=r.xi.x-o||"right"===t&&r.x>i.x&&r.xo&&("Left"===t&&r.xi.x)?l.push({x:r.x,y:i.y}):(l.push({x:a="Left"===t?e.left-o:e.right+o,y:i.y}),l.push({x:a,y:r.y})),s&&(l.push(n.points[0]),l.reverse()),n.points=l)}(a,o,s,a.points[0],a.points[a.points.length-1],!1),r=a.points[a.points.length-1],a.direction=R.direction(a.points[a.points.length-2],a.points[a.points.length-1])),r}function v3(n,t,e){var s,i=t.segments[t.segments.length-2],r=i.points[i.points.length-1];(("Top"===i.direction||"Bottom"===i.direction)&&r.x===n[1].x||("Left"===i.direction||"Right"===i.direction)&&r.y===n[1].y)&&(i.points[i.points.length-1]=n[1],s=R.direction(i.points[0],i.points[i.points.length-1]),void 0!==t.sourceWrapper&&void 0===t.sourcePortWrapper&&s===_n(i.direction)&&("Left"===i.direction||"Right"===i.direction?i.points[0].x="Right"===i.direction?i.points[0].x-t.sourceWrapper.corners.width:i.points[0].x+t.sourceWrapper.corners.width:i.points[0].y="Bottom"===i.direction?i.points[0].y-t.sourceWrapper.corners.height:i.points[0].y+t.sourceWrapper.corners.height),i.direction=s,i.length=R.distancePoints(i.points[0],i.points[i.points.length-1]),n.splice(0,1))}function LI(n,t,e,i){var o=i?n.targetPadding:n.sourcePadding,a=i?n.targetPortWrapper:n.sourcePortWrapper,l=new Ne(a.bounds.x-o,a.bounds.y-o,a.actualSize.width+2*o,a.actualSize.height+2*o),h=[l.topLeft,l.topRight,l.bottomRight,l.bottomLeft];h[h.length]=h[0];var d=i?e.point:t.point;return Px({x1:t.point.x,y1:t.point.y,x2:e.point.x,y2:e.point.y},h,0,d)||d}function m3(n,t){var e=[],i=mF(0,n.corners,t);i.push(i[0]);for(var r=0;r0){var r=void 0,s=[],o=t.point;for(r=0;r1&&R.equals(a.points[0],a.points[1])&&n.segments.splice(r,1),a)for(var l=0;l0||0===r)&&i.push(a.points[parseInt(l.toString(),10)])}}return i}function kx(n,t,e){return"Top"===n||"Bottom"===n?e.x>t.x?"Right":"Left":e.y>t.y?"Bottom":"Top"}function Uv(n){if("Straight"===n.type||"Bezier"===n.type){if(0===n.segments.length||n.segments.length>0&&!R.isEmptyPoint(n.segments[n.segments.length-1].point))if("Bezier"===n.type){var t=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0},!0);n.segments.push(t)}else t=new Bl(n,"segments",{type:"Straight"},!0),n.segments.push(t)}else{if(n.segments.length>0)for(var e=!1,i=0;i=t.corners.left&&e.point.x<=t.corners.right&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom)t.direction=e.point.y>t.point.y?"Bottom":"Top",i=Ys(n,t,e,"Top"===t.direction?t.point.y-t.corners.top+20:t.corners.bottom-t.point.y+20);else if(n.sourcePortWrapper&&r===_n(o)){var h;("Left"===r||"Right"===r)&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom?(t.direction=e.point.y>t.point.y?"Bottom":"Top",h=t.corners.height/2+20):("Top"===r||"Bottom"===r)&&t.point.x>=t.corners.left&&t.point.x<=t.corners.right&&(t.direction=e.point.x>t.point.x?"Right":"Left",h=t.corners.width/2+20),t.direction&&h?i=Ys(n,t,e,h,!0):(t.direction=o,i=kl(t,e))}else if(!n.sourcePortWrapper||r!==e.direction||"Top"!==r&&"Bottom"!==r||t.corners.center.x!==e.corners.center.x)if(t.direction===e.direction)if(("Left"===t.direction||"Right"===t.direction)&&e.point.y>t.corners.top-20&&e.point.yt.corners.left-20&&e.point.xt.point.y?"Bottom":"Top",i=Ys(n,t,e,"Bottom"===t.direction?t.corners.bottom-t.point.y+20:t.point.y-t.corners.top+20);else t.direction=o,i=Ys(n,t,e,"Top"===o||"Bottom"===o?n.sourceWrapper.height/2+20:n.sourceWrapper.width/2+20),t.point=i[1],"Left"===o||"Right"===o?(e.direction=o,e.point="Left"===o?e.corners.middleLeft:e.corners.middleRight):jv(n.targetWrapper,t,e,n),i=Ys(n,t,e);return i}function S3(n,t){if(void 0!==n.targetWrapper&&void 0===n.targetPortWrapper&&xn(n.targetWrapper).containsPoint(t.point,1)){var i=n.targetWrapper,r=n.segments[n.segments.length-2],s=r.points[r.points.length-1],o=_n(r.direction);"Bottom"===o?s.yi.corners.top-1&&(r.points[r.points.length-1].y=i.corners.top-20,r.length=R.distancePoints(r.points[0],r.points[r.points.length-1])):"Left"===o?s.x>i.corners.left-1&&(r.points[r.points.length-1].x=i.corners.left-20,r.length=R.distancePoints(r.points[0],r.points[r.points.length-1])):"Right"===o&&s.x0||0===e)&&t.push(i.points[parseInt(r.toString(),10)]);return t}function jv(n,t,e,i){var r,s={x:0,y:0},o=NI(n,n.corners,n.bounds),a=t.margin,l=t.point;if(o.bottomCenter.y+a.bottoml.y)r="Top",s=o.topCenter;else if(o.middleLeft.x-a.left>l.x)r="Left",s=o.middleLeft;else if(o.middleRight.x+a.rightc&&(f=c,r="Right",s=o.middleRight),f>d&&(f=d,r="Bottom",s=o.bottomCenter),f>u&&(r="Left",s=o.middleLeft)}e.point=s,e.direction=r;var p=Ol(o,_n(e.direction));e.point=qa(i,0,e.point,p,n===i.targetWrapper)}function b3(n,t,e,i,r){var s,o,a;if(s=function Qre(n,t){var e=!1;switch(n){case"Left":switch(t){case"Right":case"Bottom":e=!0}break;case"Top":switch(t){case"Left":case"Right":case"Bottom":e=!0}break;case"Bottom":"Right"===t&&(e=!0)}return e}(t.direction,e.direction),s&&x3(t,e),"Right"===t.direction&&"Left"===e.direction)a=function kre(n,t,e,i){var o=Math.round(Math.abs(t.point.y-e.point.y)),a={x:Math.max(t.point.x,t.corners.right),y:t.point.y},l={x:Math.min(e.point.x,e.corners.left),y:e.point.y},h=Xa(n);if(i){var c=l;l=a,a=c}return t.corners.bottom+he.corners.bottom+h||("Bezier"!==n.type||e.corners.left-t.corners.right<=2*h&&e.corners.left-t.corners.right>=5)&&(h=0),t.margin={left:h,right:h,top:h,bottom:h},e.margin={left:h,right:h,top:h,bottom:h},0===o&&(t.corners.right=e.corners.right?void 0!==i&&(i.offsetYe.corners.bottom+e.margin.bottom)||void 0===i&&t.corners.middleRight.ye.corners.bottom+e.margin.bottom&&t.corners.top>e.corners.bottom||void 0===i&&t.corners.middleRight.y>e.corners.bottom||void 0!==i&&i.offsetYe.corners.top||void 0===i&&t.corners.middleRight.y>e.corners.bottom?Ae.Three:t.corners.rightr.offsetY+e.margin.right||void 0===r&&t.corners.top>e.corners.middleRight.y||void 0!==r&&(void 0!==i&&i.offsetXr.offsetX||void 0===r&&t.corners.left>e.corners.topCenter.x?Ae.Four:Ae.Two:void 0!==s&&Math.abs(t.corners.right-e.corners.left)<=5&&Math.abs(s.offsetY-e.corners.top)<=5||void 0!==r&&t.corners.right=25&&t.corners.middleRight.y+t.margin.righte.corners.bottom+e.margin.bottom||void 0===o&&t.corners.middleRight.y>e.corners.bottom+e.margin.bottom?t.corners.top>e.corners.bottom?void 0!==a&&t.corners.right+t.margin.righta.offsetX||void 0===a&&t.corners.left>e.corners.bottomCenter.x?Ae.Four:Ae.Two:void 0!==o&&Math.abs(t.corners.right-e.corners.left)<=25&&Math.abs(o.offsetY-e.corners.bottom)<=25?Ae.Two:Ae.Four}(n,t,e,s);else if("Bottom"===t.direction&&"Top"===e.direction)a=function Hre(n,t,e){var r=t.point.x-e.point.x,s=Xa(n);return t.corners.right+se.corners.right+s||("Bezier"!==n.type||e.corners.top-t.corners.bottom<=2*s&&e.corners.top-t.corners.bottom>=5)&&(s=0),t.margin={left:s,right:s,top:s,bottom:s},e.margin={left:s,right:s,top:s,bottom:s},0===r&&t.corners.bottome.corners.right+e.margin.right||void 0===i&&t.corners.bottomCenter.x>e.corners.right+e.margin.right?Ae.Three:t.corners.bottomr.offsetX||void 0===r&&t.corners.left>e.corners.left||void 0!==r&&t.corners.right+t.margin.righte.corners.bottom?Ae.Five:0===s||0===o?Ae.One:Ae.Three}(n,t,e)}else"Bottom"===t.direction&&"Left"===e.direction?a=function Bre(n,t,e,i){var r=n.sourcePortWrapper,s=n.targetPortWrapper,o=Xa(n);if(e.margin={left:o,right:o,top:o,bottom:o},t.margin={top:o,bottom:o,left:o,right:o},i){var l=r;r=s,s=l}return void 0!==r&&r.offsetXs.offsetY||void 0===s&&t.corners.top>e.corners.middleLeft.y?Ae.Four:Ae.Two:void 0!==s&&Math.abs(t.corners.right-e.corners.left)<=25&&Math.abs(s.offsetY-t.corners.bottom)<=25?Ae.Two:Ae.Four}(n,t,e,s):"Left"===t.direction&&"Left"===e.direction?a=function Ure(n,t,e){var i=n.sourcePortWrapper,r=n.targetPortWrapper,s=Xa(n);t.margin={left:s,right:s,top:s,bottom:s},e.margin={left:s,right:s,top:s,bottom:s};var o=Math.round(Math.abs(t.point.x-e.point.x)),a=Math.round(Math.abs(t.point.y-e.point.y));return t.corners.leftr.offsetY||void 0===r&&t.corners.top-t.margin.top>e.corners.middleLeft.y?Ae.Three:t.corners.righte.corners.bottom+e.margin.bottom||void 0===i&&t.corners.middleLeft.y>e.corners.bottom+e.margin.bottom?Ae.Three:t.corners.left>e.corners.right?Ae.Five:0===o||0===a?Ae.One:Ae.Three}(n,t,e):"Left"===t.direction&&"Top"===e.direction?a=function _re(n,t,e,i){var s=n.sourcePortWrapper,o=Xa(n);e.margin={left:o,right:o,top:o,bottom:o},t.margin={top:o,bottom:o,left:o,right:o};var a=n.targetPortWrapper,l={x:Math.min(t.point.x,t.corners.left),y:t.point.y},h={x:e.point.x,y:Math.min(e.point.y,e.corners.top)};if(i){var c=s;s=a,a=c;var d=l;l=h,h=d}return void 0!==s&&s.offsetYa.offsetX||void 0===a&&t.corners.left-t.margin.left>e.corners.topCenter.x?Ae.Two:Ae.Four:void 0!==a&&t.corners.rightr.offsetX||void 0===r&&t.corners.left>e.corners.left||void 0!==r&&t.corners.right+t.margin.righte.corners.right+e.margin.right||void 0===i&&t.corners.left>e.corners.right||void 0!==i&&i.offsetXe.corners.bottom?Ae.Five:0===s||0===o?Ae.One:Ae.Three}(n,t,e));return s&&x3(t,e),o=function Vre(n,t,e,i,r,s){var l,d,h=n.sourceWrapper.corners,c=n.targetWrapper.corners,u=20,f={corners:e.corners,point:e.point,direction:e.direction,margin:e.margin},p={corners:i.corners,point:i.point,direction:i.direction,margin:i.margin};if(!(f.direction===p.direction&&t!==Ae.Five||f.direction!==_n(p.direction)&&t!==Ae.Three))switch(f.direction){case"Left":h.middleLeft.x>c.middleRight.x&&(d=(h.middleLeft.x-c.middleRight.x)/2,u=s?d:Math.min(u,d));break;case"Right":h.middleRight.xc.bottomCenter.y&&(d=(h.topCenter.y-c.bottomCenter.y)/2,u=s?d:Math.min(u,d));break;case"Bottom":h.bottomCenter.yf&&hf)&&o>c&&o<=d&&e>=20&&(s=n.point.x-t.corners.left+s),i&&n.direction===t.direction&&n.corners.left>t.corners.left&&n.corners.left-t.corners.right>=20&&(s=(n.corners.left-t.corners.right)/2),p=Fn(n.point,s,180);break;case"Top":(o>c&&oc)&&h>f&&h<=u&&e>=20&&(s=n.point.y-t.corners.top+s),i&&n.direction===t.direction&&n.corners.top>t.corners.top&&n.corners.top-t.corners.bottom>=20&&(s=(n.corners.top-t.corners.bottom)/2),p=Fn(n.point,s,270);break;case"Right":(h>f&&hf)&&a=c&&e>=20&&(s=t.corners.right-n.point.x+s),i&&n.direction===t.direction&&n.corners.right=20&&(s=(t.corners.left-n.corners.right)/2),p=Fn(n.point,s,0);break;case"Bottom":(o>c&&oc)&&l=f&&e>=20&&(s=t.corners.bottom-n.point.y+s),i&&n.direction===t.direction&&n.corners.bottom=20&&(s=(t.corners.top-n.corners.bottom)/2),p=Fn(n.point,s,90)}r=[n.point,p];var g=void 0;if("Top"===n.direction||"Bottom"===n.direction){var v=n.direction;n.direction=p.x>t.point.x?"Left":"Right",n.point=p,r=OI(n,t,v,r,g=i?.5*Math.abs(p.x-t.point.x):g,i)}else v=n.direction,n.direction=p.y>t.point.y?"Top":"Bottom",n.point=p,r=OI(n,t,v,r,g=i?.5*Math.abs(p.y-t.point.y):g,i);return r}(f,p,u,g)),l}(n,a,t,e,i,r),"Bezier"===n.type&&function Yre(n,t,e){if("Bezier"===n.type)if(0===n.segments.length){var i=e[0],r=e[e.length-1];if(t===Ae.One){var s=Math.min(20,.5*R.findLength(i,r)),o={angle:Gt(i,r),distance:s},a={angle:Gt(r,i),distance:s},l=R.direction(i,r),c=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,orientation:"Left"===l||"Right"===l?"Horizontal":"Vertical"},!0);n.segments.push(c)}else if(t===Ae.Two)o={angle:Gt(i,d=e[1]),distance:.5*R.findLength(i,d)},a={angle:Gt(r,d),distance:.5*R.findLength(r,d)},l=R.direction(i,d),c=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,orientation:"Left"===l||"Right"===l?"Horizontal":"Vertical"},!0),n.segments.push(c);else if(t===Ae.Three){var d={x:.5*((u=e[1]).x+(f=e[e.length-2]).x),y:.5*(u.y+f.y)},p=(o={angle:Gt(i,u),distance:.5*R.findLength(i,u)},a={angle:Gt(d,u),distance:.5*R.findLength(d,u)},R.direction(i,u)),v=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,point:d,orientation:"Left"===p||"Right"===p?"Horizontal":"Vertical"},!0);n.segments.push(v);var y={angle:Gt(d,f),distance:.5*R.findLength(d,f)},S={angle:Gt(r,f),distance:.5*R.findLength(r,f)},b=R.direction(d,f),w=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:y,vector2:S,orientation:"Left"===b||"Right"===b?"Horizontal":"Vertical"},!0);n.segments.push(w)}else if(t===Ae.Four){var D={x:.5*((u=e[1]).x+(f=e[2]).x),y:.5*(u.y+f.y)},A={x:.5*(f.x+(C=e[3]).x),y:.5*(f.y+C.y)};o={angle:Gt(i,u),distance:.5*R.findLength(i,u)},a={angle:Gt(D,u),distance:.5*R.findLength(D,u)},p=R.direction(i,u),v=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,point:D,orientation:"Left"===p||"Right"===p?"Horizontal":"Vertical"},!0),n.segments.push(v),y={angle:Gt(D,f),distance:.5*R.findLength(D,f)},S={angle:Gt(A,f),distance:.5*R.findLength(A,f)},b=R.direction(D,f),w=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:y,vector2:S,point:A,orientation:"Left"===b||"Right"===b?"Horizontal":"Vertical"},!0),n.segments.push(w);var x={angle:Gt(A,C),distance:.5*R.findLength(A,C)},P={angle:Gt(r,C),distance:.5*R.findLength(r,C)},L=R.direction(A,C),N=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:x,vector2:P,orientation:"Left"===L||"Right"===L?"Horizontal":"Vertical"},!0);n.segments.push(N)}else if(t===Ae.Five){var u,f,C,T=e[4],z=(D={x:.5*((u=e[1]).x+(f=e[2]).x),y:.5*(u.y+f.y)},A={x:.5*(f.x+(C=e[3]).x),y:.5*(f.y+C.y)},{x:.5*(C.x+T.x),y:.5*(C.y+T.y)});o={angle:Gt(i,u),distance:.5*R.findLength(i,u)},a={angle:Gt(D,u),distance:.5*R.findLength(D,u)},p=R.direction(i,u),v=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,point:D,orientation:"Left"===p||"Right"===p?"Horizontal":"Vertical"},!0),n.segments.push(v),y={angle:Gt(D,f),distance:.5*R.findLength(D,f)},S={angle:Gt(A,f),distance:.5*R.findLength(A,f)},b=R.direction(D,f),w=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:y,vector2:S,point:A,orientation:"Left"===b||"Right"===b?"Horizontal":"Vertical"},!0),n.segments.push(w),x={angle:Gt(A,C),distance:.5*R.findLength(A,C)},P={angle:Gt(z,C),distance:.5*R.findLength(z,C)},L=R.direction(A,C),N=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:x,vector2:P,point:z,orientation:"Left"===L||"Right"===L?"Horizontal":"Vertical"},!0),n.segments.push(N);var U={angle:Gt(z,T),distance:.5*R.findLength(z,T)},B={angle:Gt(r,T),distance:.5*R.findLength(r,T)},j=R.direction(z,T),oe=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:U,vector2:B,orientation:"Left"===j||"Right"===j?"Horizontal":"Vertical"},!0);n.segments.push(oe)}else c=new fs(n,"segments",{type:"Bezier"},!0),n.segments.push(c)}else for(var ue=0;ue=13?13:n.connectorSpacing<=1?1:n.connectorSpacing}function Gt(n,t){var i=R.findLength({x:t.x,y:n.y},t),r=R.findLength(t,n),s=Math.asin(i/r);return s=180*s/Math.PI,n.xt.y&&(s=360-s):s=n.y0)for(var l=1;lc)&&(s=c,a=h),s>=0&&s<=1)break}}return a}function w3(n,t){var c,d,u,f,p,g,S,b,M,w,D,e=n.x1,i=n.y1,r=n.x2,s=n.y2,o=t.x1,a=t.y1,l=t.x2,h=t.y2;if(w=(c=s-i)*l+(u=e-r)*h+(p=r*i-e*s),0!==(M=c*o+u*a+p)&&0!==w&&C3(M,w)||(b=(d=h-a)*r+(f=o-l)*s+(g=l*a-o*h),0!==(S=d*e+f*i+g)&&0!==b&&C3(S,b)))return null;var A=c*f-d*u;return 0===A?null:(A<0?-A/2:A/2,0,{x:(D=u*g-f*p)<0?(D-0)/A:(D+0)/A,y:(D=d*p-c*g)<0?(D-0)/A:(D+0)/A})}function C3(n,t){return n*t>=0}function E3(n,t,e){switch(t.direction){case"Left":t.point.x>n.left&&(e=t.point.x-n.left>e?t.point.x-n.left+e:e);break;case"Right":t.point.xe?n.right-t.point.x+e:e);break;case"Top":t.point.y>n.top&&(e=t.point.y-n.top>e?t.point.y-n.top+e:e);break;case"Bottom":t.point.ye?n.bottom-t.point.y+e:e)}return e}function kl(n,t){var e;switch(n.direction){case"Left":case"Right":var i={x:t.point.x,y:n.point.y};e=R.equals(n.point,i)||R.equals(t.point,i)?[n.point,t.point]:[n.point,i,t.point];break;case"Top":case"Bottom":var r={x:n.point.x,y:t.point.y};e=R.equals(n.point,r)||R.equals(t.point,r)?[n.point,t.point]:[n.point,r,t.point]}return e}function Ys(n,t,e,i,r,s){void 0===s&&(s=!1),i||(i=20),s&&t.direction!==e.direction&&(i="Left"===t.direction||"Right"===t.direction?Math.floor(.5*Math.abs(t.point.x-e.point.x)):Math.floor(.5*Math.abs(t.point.y-e.point.y)));var l,h,u,o=n.sourcePortWrapper,c=e.point.x-t.point.x,d=e.point.y-t.point.y;if(!r&&(Math.abs(c)<.001||Math.abs(d)<.001)&&void 0===e.direction)return[t.point,e.point];if(void 0===n.targetWrapper&&Math.abs(c)<=31&&Math.abs(d)<=31){if("Left"===t.direction||"Right"===t.direction?Math.abs(d)<12&&(t.direction=t.point.y>e.point.y?"Top":"Bottom"):Math.abs(c)<12&&(t.direction=t.point.x>e.point.x?"Left":"Right"),Math.abs(c)>12||Math.abs(d)>12)return kl(t,e);i+=5}return"Left"===t.direction||"Right"===t.direction?("Right"===t.direction?(void 0!==e.direction&&"Right"===e.direction&&(i=Math.max(t.point.x,e.point.x)-t.point.x+i),t.point.x>e.point.x&&void 0===o&&(i=-i)):(void 0!==e.direction&&"Left"===e.direction&&(i=t.point.x-Math.min(t.point.x,e.point.x)+i),(t.point.x>e.point.x||void 0!==o||"Left"===t.direction)&&(i=-i)),u=e.point.y-t.point.y,l=Fn(t.point,i,0),0!=(u=e.point.y-l.y)&&(h=Fn(l,e.point.y-l.y,90))):("Top"===t.direction||"Bottom"===t.direction)&&("Bottom"===t.direction?void 0!==e.direction&&"Bottom"===e.direction&&(i=Math.max(t.point.y,e.point.y)-t.point.y+i):(void 0!==e.direction&&"Top"===e.direction&&(i=t.point.y-Math.min(t.point.y,e.point.y)+i),(t.point.y>e.point.y||void 0!==o||"Top"===t.direction)&&(i=-i)),u=e.point.x-t.point.x,l=Fn(t.point,i,90),0!=(u=e.point.x-l.x)&&(h=Fn(l,e.point.x-l.x,0))),0===u?[t.point,e.point]:[t.point,l,h,e.point]}function OI(n,t,e,i,r,s){var o;switch(void 0===r&&(r=20),void 0===s&&(s=!1),void 0===e?(n.margin={left:2,right:2,top:2,bottom:2},t.margin={left:0,right:5,top:0,bottom:5},s&&(n.margin={left:10,right:10,top:10,bottom:10},t.margin={left:10,right:10,top:10,bottom:10},"Left"===n.direction?(r=Rx(n,t,e,r),n.corners.left-t.corners.right>=5&&(r=Math.abs(n.point.x-n.corners.left)+.5*Math.floor(n.corners.left-t.corners.right))):"Right"===n.direction?(r=Hx(n,t,r,e),t.corners.left-n.corners.right>=5&&(r=Math.abs(n.point.x-n.corners.right)+.5*Math.floor(t.corners.left-n.corners.right))):"Top"===n.direction?(r=zx(n,t,e,r),n.corners.top-t.corners.bottom>=5&&(r=Math.abs(n.point.y-n.corners.top)+.5*Math.floor(n.corners.top-t.corners.bottom))):"Bottom"===n.direction&&(r=Bx(n,t,r,e),t.corners.top-n.corners.bottom>=5&&(r=Math.abs(n.point.y-n.corners.bottom)+.5*Math.floor(t.corners.top-n.corners.bottom))))):("Bottom"===n.direction?s?t.corners.top-n.corners.bottom<20&&(r=t.corners.bottom-n.point.y+25):t.corners.top>n.corners.bottom&&t.corners.top-n.corners.bottom<20&&(r=(t.corners.top-n.corners.bottom)/2):"Top"===n.direction?s?n.corners.top-t.corners.bottom<20&&(r=n.point.y-t.corners.top+25):t.corners.bottomn.corners.right&&t.corners.left-n.corners.right<20&&(r=(t.corners.left-n.corners.right)/2):"Left"===n.direction&&(s?n.corners.left-t.corners.right<20&&(r=n.point.x-t.corners.left+25):t.corners.rightt.point.y||"Top"===t.direction&&n.point.yt.point.x||"Left"===t.direction&&n.point.xh||e.corners.top-e.margin.top<=i.point.y&&e.corners.bottom+e.margin.bottom>=i.point.y))if(!s||"Top"!==e.direction&&"Bottom"!==e.direction)c=Math.min(Math.abs(i.corners.left-e.corners.right)/2,20),h=e.corners.right-n.x+c;else{var c=Math.abs(i.corners.left-e.corners.right)/2;h=e.corners.right-n.x+c}else h="Top"===e.direction&&n.y>i.point.y||"Bottom"===e.direction&&n.y=e.corners.left-e.margin.left&&n.x<=e.corners.right+e.margin.right?Math.min(i.corners.left,e.corners.left)-n.x-20:i.corners.left-n.x-20;break;case"Right":if(e.corners.left-e.margin.left>i.corners.right+i.margin.right&&(e.corners.left-e.margin.right-i.corners.right>h||e.corners.top-e.margin.top<=i.point.y&&e.corners.bottom+e.margin.bottom>=i.point.y))if(!s||"Top"!==e.direction&&"Bottom"!==e.direction)c=Math.min(Math.abs(e.corners.left-i.corners.right)/2,20),h=e.corners.left-n.x-c;else{c=Math.abs(e.corners.left-i.corners.right)/2;h=e.corners.left-n.x-c}else h="Top"===e.direction&&n.y>i.point.y||"Bottom"===e.direction&&n.y=e.corners.left-e.margin.left&&n.x<=e.corners.right+e.margin.right?Math.max(i.corners.right,e.corners.right)-n.x+20:i.corners.right-n.x+20}o=Fn(n,h,0),a=Fn(o,i.point.y-n.y,90),l=i.point}else if("vertical"===t){switch(i.direction){case"Top":e.corners.bottom+e.margin.bottomh||e.corners.left-e.margin.left<=i.point.x&&e.corners.right+e.margin.right>=i.point.x)?!s||"Right"!==e.direction&&"Left"!==e.direction?(c=Math.min(Math.abs(i.corners.top-e.corners.bottom)/2,20),h=e.corners.bottom-n.y+c):(c=Math.abs(i.corners.top-e.corners.bottom)/2,h=e.corners.bottom-n.y+c):h="Left"===e.direction&&n.x>i.point.x||"Right"===e.direction&&n.x=e.corners.top-e.margin.top&&n.y<=e.corners.bottom+e.margin.bottom?Math.min(i.corners.top,e.corners.top)-n.y-20:i.corners.top-n.y-20;break;case"Bottom":e.corners.top-e.margin.top>i.corners.bottom+i.margin.bottom&&(e.corners.top-e.margin.top-i.corners.bottom>h||e.corners.left-e.margin.left<=i.point.x&&e.corners.right+e.margin.right>=i.point.x)?!s||"Right"!==e.direction&&"Left"!==e.direction?(c=Math.min(Math.abs(e.corners.top-i.corners.bottom)/2,20),h=e.corners.top-n.y-c):(c=Math.abs(e.corners.top-i.corners.bottom)/2,h=e.corners.top-n.y-c):h="Left"===e.direction&&n.x>i.point.x||"Right"===e.direction&&n.x=e.corners.top-e.margin.top&&n.y<=e.corners.bottom+e.margin.bottom?Math.max(i.corners.bottom,e.corners.bottom)-n.y+20:i.corners.bottom-n.y+20}o=Fn(n,h,90),a=Fn(o,i.point.x-n.x,0),l=i.point}r.push(o),r.push(a),r.push(l)}function zx(n,t,e,i){return n.corners.top-n.margin.top>t.corners.top+t.margin.top&&n.corners.top-n.margin.top<=t.corners.bottom+t.margin.bottom?(("Right"===t.direction&&n.point.xt.point.x)&&(i+=n.corners.top-t.corners.top),i+=n.point.y-n.corners.top):i+=void 0!==e&&"Left"!==e&&"Right"===t.direction&&n.point.xt.corners.left-t.margin.left&&n.corners.left-n.margin.left<=t.corners.right+t.margin.right?(("Bottom"===t.direction&&n.point.yt.point.y)&&(i+=n.corners.left-t.corners.left),i+=n.point.x-n.corners.left):i+=void 0!==e&&"Top"!==e&&"Bottom"===t.direction&&n.point.y=t.corners.left-t.margin.left?(("Bottom"===t.direction&&n.point.yt.point.y)&&(e+=t.corners.right-n.corners.right),e+=n.corners.right-n.point.x):e+=void 0!==i&&"Top"!==i&&"Bottom"===t.direction&&n.point.y=t.corners.top-t.margin.top?(("Right"===t.direction&&n.point.xt.point.x)&&(e+=t.corners.bottom-n.corners.bottom),e+=n.corners.bottom-n.point.y):e+=void 0!==i&&"Left"!==i&&"Right"===t.direction&&n.point.xp&&d=u&&d=f&&d<=p?"Left":"Right"}function _n(n){switch(n){case"Top":return"Bottom";case"Bottom":return"Top";case"Left":return"Right";case"Right":return"Left"}return"auto"}var A3=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Nc=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},kI=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return A3(t,n),Nc([I()],t.prototype,"width",void 0),Nc([I()],t.prototype,"height",void 0),t}(Ee),Gre=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return A3(t,n),Nc([I()],t.prototype,"width",void 0),Nc([I()],t.prototype,"height",void 0),Nc([I()],t.prototype,"fit",void 0),Nc([I()],t.prototype,"description",void 0),Nc([I()],t.prototype,"template",void 0),Nc([I()],t.prototype,"tooltip",void 0),t}(Ee),Xre=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Pl=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},L3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Xre(t,n),Pl([I("")],t.prototype,"id",void 0),Pl([I(Number.MIN_VALUE)],t.prototype,"zIndex",void 0),Pl([re({},Jn)],t.prototype,"margin",void 0),Pl([I(!0)],t.prototype,"visible",void 0),Pl([re({},Ad)],t.prototype,"tooltip",void 0),Pl([I(!1)],t.prototype,"excludeFromLayout",void 0),Pl([I()],t.prototype,"addInfo",void 0),Pl([I("None")],t.prototype,"flip",void 0),Pl([I("All")],t.prototype,"flipMode",void 0),Pl([re({},Gre)],t.prototype,"symbolInfo",void 0),t}(Ee),qre=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),es=function(n){function t(e,i,r,s){var o=n.call(this)||this;return o.data="",o.nodeId="",o.annotationId="",o.diagramId="",o.diagramId=i,o.nodeId=e,o.annotationId=r,o.templateFn=GF(s),o}return qre(t,n),t.prototype.getNodeTemplate=function(){return this.templateFn},Object.defineProperty(t.prototype,"content",{get:function(){return this.data},set:function(e){this.data=e,this.canReset||(this.canReset=!0,this.isTemplate||(this.template=Uh(this,!0)),this.canReset=!1,this.isDirt=!0)},enumerable:!0,configurable:!0}),t}(hs),Fx=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),cs=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},N3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Fx(t,n),cs([I("")],t.prototype,"id",void 0),cs([I("transparent")],t.prototype,"fill",void 0),cs([I("black")],t.prototype,"iconStrokeColor",void 0),cs([I(0)],t.prototype,"iconStrokeWidth",void 0),cs([I(!0)],t.prototype,"visibility",void 0),cs([I(10)],t.prototype,"width",void 0),cs([I(10)],t.prototype,"height",void 0),cs([I("transparent")],t.prototype,"handleStrokeColor",void 0),cs([I(1)],t.prototype,"handleStrokeWidth",void 0),cs([I("")],t.prototype,"pathData",void 0),cs([I(0)],t.prototype,"cornerRadius",void 0),cs([re({left:0,right:0,top:0,bottom:0},Jn)],t.prototype,"padding",void 0),cs([re({},Ad)],t.prototype,"tooltip",void 0),t}(Ee),O3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Fx(t,n),cs([re({x:0,y:0},R)],t.prototype,"offset",void 0),cs([re({},Jn)],t.prototype,"margin",void 0),t}(N3),PI=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Fx(t,n),cs([I(.5)],t.prototype,"offset",void 0),cs([I("Center")],t.prototype,"alignment",void 0),cs([re({x:0,y:0},R)],t.prototype,"displacement",void 0),t}(N3);function Ld(n){return n?n instanceof Kn||n instanceof Or?n.constraints&Nr.Select:n instanceof de?n.constraints&qe.Select:n.constraints&ie.Select:1}function ro(n){return n?n instanceof Kn||n instanceof Or?n.constraints&Nr.Drag:n instanceof de?n.constraints&qe.Drag:n instanceof ei?1:n.constraints&ie.Drag:1}function $re(n,t){return n instanceof de?n.constraints&qe.PointerEvents:n.constraints&ie.PointerEvents}function zI(n){return n instanceof de?n.constraints&qe.Delete:n.constraints&ie.Delete}function RI(n){return n.constraints&qe.DragSourceEnd}function HI(n){return n.constraints&qe.DragTargetEnd}function BI(n){return n.constraints&qe.DragSegmentThumb}function FI(n){return n instanceof Kn||n instanceof Or?n.constraints&Nr.Rotate:n.constraints&ie.Rotate}function _I(n){return n.constraints&ie.Shadow}function ua(n){return n instanceof te&&n.constraints&ie.InConnect?n.constraints&ie.InConnect:0}function Hh(n){return n&&n.constraints&&!(n.constraints&oi.None)&&n.constraints&oi.InConnect?n.constraints&oi.InConnect:0}function Bh(n){return n instanceof te&&n.constraints&ie.OutConnect?n.constraints&ie.OutConnect:0}function Nd(n){return n&&n.constraints&&!(n.constraints&oi.None)&&n.constraints&oi.OutConnect?n.constraints&oi.OutConnect:0}function zl(n,t){var e=0;return n instanceof Kn||n instanceof Or?e=n.constraints&Nr.Resize:n&&("SouthEast"===t?e=n.constraints&ie.ResizeSouthEast:"East"===t?e=n.constraints&ie.ResizeEast:"NorthEast"===t?e=n.constraints&ie.ResizeNorthEast:"South"===t?e=n.constraints&ie.ResizeSouth:"North"===t?e=n.constraints&ie.ResizeNorth:"SouthWest"===t?e=n.constraints&ie.ResizeSouthWest:"West"===t?e=n.constraints&ie.ResizeWest:"NorthWest"===t&&(e=n.constraints&ie.ResizeNorthWest)),e}function UI(n){return n instanceof de?n.constraints&qe.AllowDrop:n.constraints&ie.AllowDrop}function Ds(n){return n.constraints&nt.Virtualization}function Vv(n){return n.tool&ri.SingleSelect}function Wv(n){return n.tool&ri.MultipleSelect}function Oc(n){return n.tool&ri.ZoomPan}function jI(n){return n.tool&ri.ContinuousDraw}function k3(n){return n.tool&ri.DrawOnce}function VI(n){return n.tool&ri.SingleSelect||n.tool&ri.MultipleSelect}function Yv(n){return n.constraints&nt.UserInteraction}function P3(n){return n.constraints&nt.ZoomTextEdit}function Qv(n){return function ine(n){return n.constraints&nt.ApiUpdate}(n)||n.diagramActions&ee.ToolAction}function _x(n,t){return n.constraints&oi.Draw}function Ux(n,t){return n.constraints&oi.Drag}function WI(n){return!(n&Ga.DrawSelectorBorder)}function z3(n){return!!(n&Ga.PreventRenderSelector)}var jx=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Gv=function(n){function t(){var e=null!==n&&n.apply(this,arguments)||this;return e.childTable=[],e.cellStyle={},e.desiredRowHeight=[],e.desiredCellWidth=[],e}return jx(t,n),t.prototype.rowDefinitions=function(){return this.rowDefns},t.prototype.columnDefinitions=function(){return this.colDefns},t.prototype.addObject=function(e,i,r,s,o){if(this.rows.length>=i){var a=this.rows[parseInt(i.toString(),10)];if(a.cells.length>r){o=o||1,s=s||1;var l=a.cells[parseInt(r.toString(),10)];l.columnSpan=Math.max(o,l.columnSpan),l.rowSpan=Math.max(s,l.rowSpan);var h=new ane;(h=e).rowId=i,h.columnId=r,h.columnSpan=o,this.childTable[h.id]=h,this.addObjectToCell(h,l)}}},t.prototype.addObjectToCell=function(e,i){i.children||(i.children=[]),e.style.strokeColor="black",e.style.strokeWidth=1,i.children.push(e)},t.prototype.updateProperties=function(e,i,r,s){this.offsetX=e,this.offsetY=i,this.width=r,this.height=s},t.prototype.setDefinitions=function(e,i){this.rowDefns=e,this.colDefns=i,this.children=[],this.rows=this.rows||[];for(var r=0;r0){for(var h=0;hi&&this.updateRowHeight(e,l,!1)}},t.prototype.setTextRefresh=function(e){if(e.children&&e.children.length)for(var i=e.children,r=0;ri&&this.updateColumnWidth(e,a,!1)}},t.prototype.calculateCellWidth=function(e){for(var i,r,s,o=0;os.bounds.width&&(0===s.children.length||void 0===s.children[0].maxWidth)?s.outerBounds.width:s.bounds.width,i=i?is.bounds.height?s.outerBounds.height:s.bounds.height,i=i?i0?e.children[0]:void 0;if(a&&1===e.columnSpan){o="Width"===i?a.bounds.right:a.bounds.bottom,s||(s="Width"===i?a.bounds.width:a.bounds.height);for(var l=0;lo){var d=c-o+("Width"===i?a.bounds.width:a.bounds.height);s&&(s=s0?this.rowDefns.splice(e,0,i):this.rowDefns.push(i);var s=new R3;s.cells=[],(new Od).width=this.width,this.addCellInRow(this.colDefns,i,s),e>this.rows.length-1?this.rows.push(s):this.rows.splice(e,0,s),r&&(this.measure(new me(this.width,this.height)),this.arrange(this.desiredSize))},t.prototype.addColumn=function(e,i,r){var s,o,a,l,h=this.rows;this.colDefns.length>0?this.colDefns.splice(e,0,i):this.colDefns.push(i),void 0!==this.width&&(this.width+=i.width);for(var c=0;cs.cells.length-1?s.cells.push(l):s.cells.splice(e,0,l),this.children.push(l);r&&(this.measure(new me(this.width,this.height)),this.arrange(this.desiredSize))},t.prototype.removeRow=function(e){var i,r,o=this.rows[parseInt(e.toString(),10)];this.height-=this.rowDefns[parseInt(e.toString(),10)].height;for(var a=0;a0){var r=0,s=0;i=new me(0,0),this.calculateSize();for(var o=0,a=this.rows;o0){for(var o=this.offsetX-e.width*this.pivot.x,a=this.offsetY-e.height*this.pivot.y,l=o,h=0,c=this.rows;h1&&this.children.splice(this.children.indexOf(p)+1,p.columnSpan-1),p.rowSpan>1)for(y=s,S=0;y+p.rowSpan-10){for(var c=0;c0?1:0,v=0;v0||a.outEdges.length>0))for(f=a.inEdges.concat(a.outEdges),s=0;s0)for(o=0;o1)for(a=1;a0))if(h=n.wrapper.children[0],"Horizontal"===e.orientation)for(o=e.header&&e.hasHeader?h.rows[1]:h.rows[0],r=0;r0){var e=void 0;t.lineRoutingModule&&t.constraints&nt.LineRouting&&t.lineRoutingModule.renderVirtualRegion(t,!0);for(var i=0;i0?o+1:o)].height=t.wrapper.height;else if(t.isPhase)for(l[t.rowIndex-o].offset=t.wrapper.height,p=0;p0?1:0)].width=t.wrapper.width}function QI(n,t){var i=n.shape,r=i.header&&i.hasHeader?1:0;return"Horizontal"===i.orientation?t.rowIndex-(r+=i.phases.length>0?1:0):t.columnIndex-(i.phaseSize&&i.phases.length>0?1:0)}function GI(n){var t=0,e=n.shape;return"Horizontal"===e.orientation&&(t=e.header&&e.hasHeader?1:0),e.phases.length>0&&e.phaseSize&&(t+=1),t}function XI(n,t,e,i){var r=n.shape;if(r.phases.length>0){var s=t.nameTable[r.phases[parseInt(i.toString(),10)].header.id];s&&s.maxWidth0?u+1:u);var w=kc(n,o),C=void 0!==i?i:l.lanes.length;if(u+=C,r={element:M,cause:n.diagramActions,diagramAction:n.getDiagramAction(n.diagramActions),state:"Changing",type:"Addition",cancel:!1,laneIndex:C},n.triggerEvent(Ce.collectionChange,r),!r.cancel){if(c){var D=new Xv;D.height=e.height,o.addRow(u,D,!1),s.height=void 0!==s.height?s.height+e.height:s.height,s.wrapper.height=o.height=s.height}else{var A=new Od;A.width=e.width,o.addColumn(C+1,A,!1),s.width&&(s.width+=e.width,s.wrapper.width=o.width=s.width),n.diagramActions&ee.UndoRedo||(o.rows[0].cells[0].columnSpan+=1)}n.diagramActions&ee.UndoRedo||(M.id=""===M.id?Qe():M.id),void 0!==i?l.lanes.splice(i,0,M):l.lanes.push(M),r={element:M,cause:n.diagramActions,diagramAction:n.getDiagramAction(n.diagramActions),state:"Changed",type:"Addition",cancel:!1,laneIndex:C},n.triggerEvent(Ce.collectionChange,r),B3(o,n,s,u,C,c),h="Horizontal"===l.orientation?n.nameTable[o.rows[parseInt(u.toString(),10)].cells[0].children[0].id]:l.header&&l.hasHeader?n.nameTable[o.rows[1].cells[parseInt(u.toString(),10)].children[0].id]:n.nameTable[o.rows[0].cells[parseInt(u.toString(),10)].children[0].id],n.diagramActions&ee.UndoRedo||(d={type:"LaneCollectionChanged",changeType:"Insert",undoObject:$(M),redoObject:$(h),category:"Internal"},n.addHistoryEntry(d)),Jf(n,s,"Horizontal"===l.orientation?u:l.header&&l.hasHeader?1:0),Zf(s),Pc(n,s);var P=!1;if((f=e.children)&&f.length>0)for(p=0;p0){var o=t.children[0],a=n.nameTable[o.id];(function vne(n,t,e){return n.left-(e.left||0)<=t.x&&n.right+(e.right||0)>=t.x&&n.top-(e.top||0)<=t.y&&n.bottom+(e.bottom||0)>=t.y})(o.bounds,e,r)&&(n.addChild(a,i),s=!0)}return s}function mne(n,t,e){if("SwimLane"===t.shape.type){var i=void 0,r=void 0,s=void 0,a=void 0,l=void 0,h=void 0,c=t.wrapper.bounds.x,d=t.wrapper.bounds.y,u=t.shape,f=u.padding,p=u.phases,g=void 0,v=t.wrapper.children[0],y="Horizontal"===u.orientation;if(i=u.header&&u.hasHeader?0:-1,u.phases.length>0&&(i+=1),e.offset>(y?u.lanes[0].header.width:u.lanes[0].header.height)){for(h=0;he.offset){if(g=h>0?e.offset-(h>0?p[h-1]:s).offset:e.offset,y){var b=v.columnDefinitions()[parseInt(h.toString(),10)];b.width-=g,(a=n.nameTable[u.phases[parseInt(h.toString(),10)].header.id]).maxWidth=a.wrapper.maxWidth=b.width,v.updateColumnWidth(h,b.width,!1);var M=new Od;M.width=g,l=h,v.addColumn(h,M,!1);break}var w=v.rowDefinitions()[h+i];w.height-=g,a=n.nameTable[u.phases[parseInt(h.toString(),10)].header.id],v.updateRowHeight(h+i,w.height,!1);var C=new Xv;C.height=g,l=h,v.addRow(h+i,C,!1);break}if(n.diagramActions&ee.UndoRedo&&void 0===l&&(D=n.historyManager.currentEntry.next).isLastPhase&&function yne(n,t,e,i,r,s){var a=t.shape.phases[n-2],l=e.previousPhase.offset;if(r){var h=i.columnDefinitions()[n-1],c=new Od;n>1?(c.width=h.width-(l-a.offset),h.width=l-a.offset):(c.width=h.width-l,h.width=l),i.updateColumnWidth(n-1,h.width,!1),i.addColumn(n,c,!1)}else{h=i.rowDefinitions()[parseInt(n.toString(),10)];var d=new Xv;n>1?(d.height=e.undoObject.offset-l,h.height=l-a.offset):(d.height=h.height-l,h.height=l),i.updateRowHeight(n,h.height,!1),i.addRow(1+n,d,!1)}}(l=p.length,t,D,v,y),l>=0){var A=new gb(t.shape,"phases",e,!0);if(n.diagramActions&ee.UndoRedo||(A.id+=Qe()),u.phases.splice(l,0,A),Vx(v,n,t,i,y,l),y){if(r=n.nameTable[v.rows[parseInt(i.toString(),10)].cells[parseInt(l.toString(),10)].children[0].id],0===l&&u.header&&u.hasHeader){v.rows[0].cells[0].children=v.rows[0].cells[1].children,v.rows[0].cells[1].children=[];for(var x=v.rows[0],P=0;Pl+1){var O=n.nameTable[v.rows[parseInt(i.toString(),10)].cells[l+1].children[0].id];v.updateColumnWidth(l+1,L[l+1].width,!0,f),O.maxWidth=O.wrapper.maxWidth=L[l+1].width}t.width=t.wrapper.width=t.wrapper.children[0].width=v.width}else{r=n.nameTable[v.rows[i+l].cells[0].children[0].id];var N=v.rowDefinitions(),T=N[i+l].height;(function Ine(n,t,e,i,r){for(var o,a,l=e.rows[parseInt(i.toString(),10)],h=e.rows[i+1],c=e.rows[i-1],d=1;di+l+1&&v.updateRowHeight(i+l+1,T=N[i+l+1].height,!0,f),t.height=t.wrapper.height=t.wrapper.children[0].height=v.actualSize.height}if(Zf(t),t.width=t.wrapper.actualSize.width,Pc(n,t),n.drag(t,c-t.wrapper.bounds.x,d-t.wrapper.bounds.y),YI(t,n),n.commandHandler.select(r),!(n.diagramActions&ee.UndoRedo)){var D={type:"PhaseCollectionChanged",changeType:"Insert",undoObject:$(A),redoObject:$(r),category:"Internal"};n.addHistoryEntry(D)}n.updateDiagramObject(t)}}}}function V3(n,t,e,i,r,s,o){var a,l,p,h=t.shape,c="Horizontal"===h.orientation,d=t.wrapper.children[0],g=c?s:o;e?(a=c?e.bounds.x+e.bounds.width:e.bounds.x,l=c?e.bounds.y:e.bounds.y+e.bounds.height):(a=d.bounds.x,l=r.bounds.y);var v=new Ne(a,l,i.desiredCellWidth,i.desiredCellHeight),S=qv(n,0,t,{id:t.id+(c?h.lanes[g-2]:h.lanes[g-1]).id+Qe()[0],rowIndex:s,columnIndex:o,width:i.minWidth,height:i.minHeight,style:(c?h.lanes[g-2]:h.lanes[g-1]).style,constraints:ie.Default|ie.AllowDrop,container:{type:"Canvas",orientation:c?"Horizontal":"Vertical"}},!1,!1,!0);if(S.children[0].isCalculateDesiredSize=!1,d.addObject(S,s,o),r&&r.children&&r.children.length)for(p=0;p1)for(var p=1;ph.margin.left&&(h.margin.left=f)):(h.margin.top-=e.desiredCellHeight,f>h.margin.top&&(h.margin.top=f)))}(n,r,i,v,S,c,e)}function W3(n,t,e){if("SwimLane"===t.shape.type&&("ResizeSouth"===e||"ResizeEast"===e)){var i=t.shape,r=t.wrapper.children[0],s=void 0,o=void 0;"ResizeSouth"===e?"Vertical"===i.orientation?s=r.rows[r.rows.length-1].cells[0]:(o=r.rows.length-1,s=r.rows[parseInt(o.toString(),10)].cells[r.rows[parseInt(o.toString(),10)].cells.length-1]):(o=i.header&&i.hasHeader?1:0,s=r.rows[parseInt(o.toString(),10)].cells[r.rows[parseInt(o.toString(),10)].cells.length-1]),n.commandHandler.select(n.nameTable[s.children[0].id])}}function qI(n,t,e,i,r,s){var o,a,l,c,u,f,p,d=Qe(),g=n.shape,v=g.phases,y=n.offsetX-n.wrapper.actualSize.width/2,S=n.offsetY-n.wrapper.actualSize.height/2;if("Vertical"===g.orientation&&(S+=g.header&&g.hasHeader?g.header.height:0),!s)for(r||(n.id+=d,g&&g.header&&g.hasHeader?g.header.id+=d:g.header=void 0),o=0;v&&o0&&s.columnIndex>0||s.isLane)?(a=function Lne(n,t,e){for(var i=new Ne,r="SwimLane"===n.shape.type?n.wrapper.children[0].rows:n.wrapper.rows,s=e?1:0;s=0;a--)i?i.id===o.children[parseInt(a.toString(),10)].id&&o.children.splice(a,1):(n.removeDependentConnector(o.children[parseInt(a.toString(),10)]),n.diagramActions&ee.UndoRedo||(n.diagramActions=n.diagramActions|ee.UndoRedo,s=!0),n.remove(o.children[parseInt(a.toString(),10)]),o.children.splice(a,1),s&&(n.diagramActions=n.diagramActions&~ee.UndoRedo))}function Mne(n){return n.children[0]}function Jv(n,t){t&&(n.nodes.splice(n.nodes.indexOf(t),1),n.removeFromAQuad(t),n.removeObjectsFromLayer(t),delete n.nameTable[t.id],n.removeElements(t))}function Q3(n,t,e,i){var r;if("SwimLane"===e.shape.type){var s=e.shape,o=void 0;if(1===s.lanes.length)n.remove(e);else{var a=e.wrapper.bounds.x,l=e.wrapper.bounds.y,h=void 0,c=void 0,d=void 0,u=void 0,p=e.wrapper.children[0];if(o=i?s.lanes.indexOf(i):QI(e,t),r={element:t,cause:n.diagramActions,diagramAction:n.getDiagramAction(n.diagramActions),state:"Changing",type:"Removal",cancel:!1,laneIndex:o},n.triggerEvent(Ce.collectionChange,r),!r.cancel){var g=s.lanes[parseInt(o.toString(),10)],v=g.children;g.children=[];for(var y=0;y0)for(u=0;u0)for(u=0;u0)for(e=0;e1){c===l.phases.length-1&&(o=!0,a=$(l.phases[c-1]));var u=$(l.phases[parseInt(c.toString(),10)]);if(l.phases.splice(c,1),!(n.diagramActions&ee.UndoRedo)){var f={type:"PhaseCollectionChanged",changeType:"Remove",undoObject:u,previousPhase:a,redoObject:$(t),category:"Internal",isLastPhase:o};n.addHistoryEntry(f)}"Horizontal"===l.orientation?function Cne(n,t,e,i){var r,s,o,a,l,h,c,d,u,f,p,g;for(i=void 0!==i?i:e.columnIndex,c=0;c1&&(s=r.cells[parseInt(i.toString(),10)],l=(o=r.cells.length-1===i?r.cells[i-1]:r.cells[i+1]).children[0],s.children.length>0))if(p=n.nameTable[(a=s.children[0]).id],0===o.children.length&&s.children.length>0)o.children=s.children,o.columnSpan=s.columnSpan-1;else{for(d=0;d0){var M=s.children[0],w=n.nameTable[M.id];if(i=e.x&&a.bounds.y<=e.y&&a.bounds.bottom>=e.y){var l=void 0,h=a.bounds.y,c=a.bounds.x,d=n.nameTable[r.parentId]||r;if("SwimLane"===d.shape.type)o=em(r,d,t,n,!0);else{var f=n.nameTable[r.parentId]||r,p=f.shape;l=f.wrapper,a.actualSize.widtha.outerBounds.x)&&(void 0!==r.rowIndex?(l.updateColumnWidth(r.columnIndex,a.outerBounds.width,!0),"Horizontal"===p.orientation&&p.phaseSize&&XI(f,n,a,r.columnIndex),Pc(n,f),n.drag(f,c-a.bounds.x,h-a.bounds.y)):n.scale(r,1+(a.outerBounds.width-a.actualSize.width)/a.actualSize.width,1,a.outerBounds.xa.outerBounds.y)&&(void 0!==r.rowIndex?(l.updateRowHeight(r.rowIndex,a.outerBounds.height,!0),n.drag(f,c-a.bounds.x,h-a.bounds.y)):n.scale(r,1,1+(a.outerBounds.height-a.actualSize.height)/a.actualSize.height,a.outerBounds.y=e.x&&a.bounds.y<=e.y&&a.bounds.bottom>=e.y)&&!(t.constraints&ie.AllowMovingOutsideLane)){var l=$(t);n.clearSelection(),$3(n,t),t.parentId="",t.parentObj=n,t.propName="nodes";var h={type:"ChildCollectionChanged",category:"Internal",undoObject:l,redoObject:$(t)};n.addHistoryEntry(h),n.commandHandler.isContainer&&(n.commandHandler.isContainer=!1,n.endGroupAction()),Z3(t,n)}n.protectPropertyChange(o)}}function $I(n,t){var e,i,r;return n.enableServerDataBinding(!1),ce()||(n.selectedObject.helperObject?r=n.selectedObject.helperObject:(n.selectedItems.nodes.length>0||n.selectedItems.connectors.length>0)&&(t instanceof ei&&t.nodes.length+t.connectors.length===1?(e=t.nodes.length>0?t.nodes[0]:t.connectors[0],i=n.selectedItems.wrapper.children[0]):(e=t,i=n.selectedItems.wrapper),n.selectedObject.actualObject=e,!n.currentSymbol&&(e.isLane&&Gx(e,n)&&Dn(n,e)||!e.isLane&&Dn(n,e)||n.constraints&nt.LineRouting&&n.selectedItems.nodes.length>0))&&(r=function Nne(n,t){for(var e,i={},r=0,s=Object.keys(t);r=t.x-e&&n.x<=t.x+e&&n.y>=t.y-e&&n.y<=t.y+e}function $a(n){return n.selectedItems.nodes.length>0||n.selectedItems.connectors.length>0}function K3(n){return 1===n.selectedItems.connectors.length&&!n.selectedItems.nodes.length}function _r(n,t,e,i){if(void 0===e&&(e=!0),t instanceof ei)return!0;if(t instanceof te)for(;t;){if(-1!==n.selectedItems.nodes.indexOf(t)&&void 0===n.selectedItems.annotation)return!0;if(e)break;t=n.nameTable[t.parentId]}else if(t instanceof de){if(-1!==n.selectedItems.connectors.indexOf(t)&&void 0===n.selectedItems.annotation)return!0}else if((t instanceof Kn||t instanceof Or)&&n.selectedItems.annotation&&n.selectedItems.wrapper.children[0].id===i.id)return!0;return!1}var Xx={None:"default",Rotate:"crosshair",Select:"default",Drag:"move",ResizeWest:"w-resize",ResizeEast:"e-resize",ResizeSouth:"s-resize",ResizeNorth:"n-resize",Draw:"crosshair",PortDraw:"crosshair",ResizeNorthEast:"ne-resize",ResizeNorthWest:"nw-resize",ResizeSouthEast:"se-resize",ResizeSouthWest:"sw-resize",ConnectorSourceEnd:"move",ConnectorTargetEnd:"move",BezierSourceThumb:"move",BezierTargetThumb:"move",OrthoThumb:"move",SegmentEnd:"move",Pan:"grab",Hyperlink:"pointer",PortDrag:"pointer",LabelSelect:"pointer",LabelDrag:"move",LabelRotate:"crosshair",LabelResizeWest:"w-resize",LabelResizeEast:"e-resize",LabelResizeSouth:"s-resize",LabelResizeNorth:"n-resize",LabelResizeNorthEast:"ne-resize",LabelResizeNorthWest:"nw-resize",LabelResizeSouthEast:"se-resize",LabelResizeSouthWest:"sw-resize"},ds=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Pd=function(n,t,e,i){return new(e||(e=Promise))(function(r,s){function o(h){try{l(i.next(h))}catch(c){s(c)}}function a(h){try{l(i.throw(h))}catch(c){s(c)}}function l(h){h.done?r(h.value):new e(function(c){c(h.value)}).then(o,a)}l((i=i.apply(n,t||[])).next())})},zd=function(n,t){var i,r,s,o,e={label:0,sent:function(){if(1&s[0])throw s[1];return s[1]},trys:[],ops:[]};return o={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function a(h){return function(c){return function l(h){if(i)throw new TypeError("Generator is already executing.");for(;e;)try{if(i=1,r&&(s=2&h[0]?r.return:h[0]?r.throw||((s=r.return)&&s.call(r),0):r.next)&&!(s=s.call(r,h[1])).done)return s;switch(r=0,s&&(h=[2&h[0],s.value]),h[0]){case 0:case 1:s=h;break;case 4:return e.label++,{value:h[1],done:!1};case 5:e.label++,r=h[1],h=[0];continue;case 7:h=e.ops.pop(),e.trys.pop();continue;default:if(!(s=(s=e.trys).length>0&&s[s.length-1])&&(6===h[0]||2===h[0])){e=0;continue}if(3===h[0]&&(!s||h[1]>s[0]&&h[1]-1&&(r=i.fixedUserHandles[parseInt(o.toString(),10)]);this.commandHandler.triggerEvent(Ce.fixedUserHandleClick,{fixedUserHandle:r,element:e.source}),n.prototype.mouseUp.call(this,e)},t}(us),Rd=function(n){function t(e,i){var r=n.call(this,e,!0)||this;return r.isConnected=!1,r.endPoint=i,r}return ds(t,n),t.prototype.mouseDown=function(e){return Pd(this,void 0,void 0,function(){var r,s,o,a,l;return zd(this,function(h){if(this.inAction=!0,this.undoElement=void 0,this instanceof pa||(this.undoElement=$(e.source)),n.prototype.mouseDown.call(this,e),e.source&&e.source.connectors&&(this.oldConnector=$(r=e.source.connectors[0])),"BezierSourceThumb"===this.endPoint||"BezierTargetThumb"===this.endPoint)for(s=0;s0))},t.prototype.endAction=function(){n.prototype.endAction.call(this),this.prevPosition=null,this.endPoint=null},t}(us),fa=function(n){function t(e,i){var r=n.call(this,e,!0)||this;return r.currentTarget=null,r.isStartAction=!1,r.canCancel=!1,r.canTrigger=!1,r.objectType=i,r}return ds(t,n),t.prototype.mouseDown=function(e){if(e.source instanceof te||e.source instanceof de){var i=this.commandHandler.getSelectedObject();this.commandHandler.selectObjects([e.source],e.info&&e.info.ctrlKey,i);var r={nodes:[],connectors:[]};e.source instanceof te?r.nodes.push($(e.source)):r.connectors.push($(e.source)),this.undoElement=$(r)}else this.undoElement=$(e.source);this.undoParentElement=this.commandHandler.getSubProcess(e.source),"Port"===this.objectType&&(this.portId=e.sourceWrapper.id),this.commandHandler.insertBlazorConnector(e.source),n.prototype.mouseDown.call(this,e),this.initialOffset={x:0,y:0}},t.prototype.mouseUp=function(e,i){return Pd(this,void 0,void 0,function(){var s,o,a,l,h,c,d,u,p,g,v,y,S,b,M;return zd(this,function(w){if(this.checkPropertyValue(),a=!1,h={nodes:[],connectors:[]},"Port"!==this.objectType){if(e.source instanceof te||e.source instanceof de?(e.source instanceof te?h.nodes.push($(e.source)):h.connectors.push($(e.source)),(o=$(h)).offsetX=(c=e.source.wrapper).offsetX,o.offsetY=c.offsetY):o=$(e.source),("helper"===(l=this.commandHandler.renderContainerHelper(e.source)||e.source||this.commandHandler.renderContainerHelper(e.source)).id||"helper"!==l.id)&&((l instanceof ei&&(Math.round(l.width)===Math.round(this.undoElement.width)&&Math.round(l.height)===Math.round(this.undoElement.height)||l.selectedObjects&&1===l.selectedObjects.length)||!(l instanceof ei))&&(l.offsetX!==this.undoElement.offsetX||l.offsetY!==this.undoElement.offsetY||l.sourcePoint!==this.undoElement.sourcePoint||l.targetPoint!==this.undoElement.targetPoint)||this.isSelectionHasConnector(l))&&(e.source&&(s={offsetX:e.source.wrapper.offsetX,offsetY:e.source.wrapper.offsetY}),g={source:e.source,state:"Completed",oldValue:this.intialValue,newValue:s,target:this.currentTarget,targetPosition:this.currentPosition,allowDrop:(g={source:e.source,state:"Completed",oldValue:this.intialValue,newValue:s,target:this.currentTarget,targetPosition:this.currentPosition,allowDrop:!0,cancel:!1}).allowDrop,cancel:g.cancel},d=!0,"helper"===l.id?this.canTrigger?(this.commandHandler.triggerEvent(Ce.positionChange,g),this.connectorEndPointChangeEvent(g),d=!0):d=!1:(this.commandHandler.triggerEvent(Ce.positionChange,g),this.connectorEndPointChangeEvent(g)),!i&&d&&(this.commandHandler.startGroupAction(),a=!0,M={type:"PositionChanged",redoObject:$(o),undoObject:$(this.undoElement),category:"Internal"},o.nodes[0]&&o.nodes[0].processId&&(u={type:"SizeChanged",category:"Internal",undoObject:this.undoParentElement,redoObject:this.commandHandler.getSubProcess(e.source)},this.commandHandler.addHistoryEntry(u)),this.commandHandler.addHistoryEntry(M))),this.commandHandler.snapPoint(this.prevPosition,this.currentPosition,0,0),this.commandHandler.removeSnap(),this.commandHandler.removeHighlighter(),e.source&&this.currentTarget&&UI(this.currentTarget)&&this.commandHandler.isDroppable(e.source,this.currentTarget)){if(p=!0,this.commandHandler.drop(this.currentElement,this.currentTarget,this.currentPosition),this.currentTarget&&this.currentTarget instanceof de&&!0===this.commandHandler.diagram.enableConnectorSplit)if(this.currentElement&&this.currentElement instanceof te){if(void 0!==this.currentElement.children)for(b=0;b0)for(var s=0;s0)for(var a=0;a0)for(a=0;a0&&e.connectors.length>0)||e.width===this.undoElement.width&&e.height===this.undoElement.height)},t.prototype.mouseMove=function(e){n.prototype.mouseMove.call(this,e);var r,s,i=!1;(r=this.commandHandler.renderContainerHelper(e.source)||e.source)instanceof te||r instanceof de?r instanceof te?r.offsetX===this.undoElement.nodes[0].offsetX&&r.offsetY===this.undoElement.nodes[0].offsetY&&(i=!0):R.equals(r.sourcePoint,this.undoElement.connectors[0].sourcePoint)&&R.equals(r.targetPoint,this.undoElement.connectors[0].targetPoint)&&(i=!0):r.wrapper.offsetX===this.undoElement.wrapper.offsetX&&r.wrapper.offsetY===this.undoElement.wrapper.offsetY&&(i=!0),r&&(s={offsetX:r.wrapper.offsetX,offsetY:r.wrapper.offsetY});var o={source:r,state:"Start",oldValue:s,newValue:s,target:e.target,targetPosition:e.position,allowDrop:!0,cancel:!1};if(o={source:r,state:"Start",oldValue:s,newValue:s,target:e.target,targetPosition:e.position,allowDrop:o.allowDrop,cancel:o.cancel},this.isStartAction||(this.intialValue={offsetX:r.wrapper.offsetX,offsetY:r.wrapper.offsetY}),i&&!ce()&&(this.commandHandler.triggerEvent(Ce.positionChange,o),this.connectorEndPointChangeEvent(o),this.isStartAction=!0),this.currentPosition=e.position,"Port"!==this.objectType){var h=this.initialOffset.x+(this.currentPosition.x-this.prevPosition.x),c=this.initialOffset.y+(this.currentPosition.y-this.prevPosition.y);this.commandHandler.dragOverElement(e,this.currentPosition),this.commandHandler.disConnect(e.source),this.commandHandler.removeSnap();var d,u=void 0,f=this.commandHandler.snapPoint(this.prevPosition,this.currentPosition,h,c);this.initialOffset.x=h-f.x,this.initialOffset.y=c-f.y,r&&(d={offsetX:r.wrapper.offsetX,offsetY:r.wrapper.offsetY},u={offsetX:r.wrapper.offsetX+f.x,offsetY:r.wrapper.offsetY+f.y}),this.currentTarget&&e.target!==this.currentTarget&&this.commandHandler.removeChildFromBPmn(e.source,e.target,this.currentTarget),this.currentTarget=e.target;var p={source:r,state:"Progress",oldValue:d,newValue:u,target:e.target,targetPosition:e.position,allowDrop:!0,cancel:!1};if(this.commandHandler.triggerEvent(Ce.positionChange,p),this.canTrigger=!0,this.connectorEndPointChangeEvent(p,f),!p.cancel&&!this.canCancel){this.blocked=!this.commandHandler.dragSelectedObjects(f.x,f.y);var g=!this.commandHandler.mouseOver(this.currentElement,this.currentTarget,this.currentPosition);this.blocked=this.blocked||g}if(this.commandHandler.removeStackHighlighter(),this.commandHandler.renderStackHighlighter(e),this.currentTarget&&e.source!==this.currentTarget&&this.commandHandler.isDroppable(e.source,this.currentTarget)&&"helper"!==e.source.id){var v=e.source instanceof ei?e.source.nodes[0]:e.source;!this.commandHandler.isParentAsContainer(v,!0)&&"SwimLane"!==v.shape.type&&!v.shape.isPhase&&(this.currentTarget.isLane?this.commandHandler.renderStackHighlighter(e,this.currentTarget):this.commandHandler.drawHighlighter(this.currentTarget))}else this.commandHandler.removeHighlighter();if(this.commandHandler.canEnableDefaultTooltip()){var y=this.getTooltipContent(e.source);this.commandHandler.showTooltip(e.source,e.position,ko(function(){return y}),"MoveTool",this.isTooltipVisible),this.isTooltipVisible=!1}}else{var b=Bi(),M=e.source;qi(b,-M.rotateAngle||-M.wrapper.rotateAngle,M.offsetX||M.wrapper.offsetX,M.offsetY||M.wrapper.offsetY);var w=Ke(b,{x:this.prevPosition.x,y:this.prevPosition.y}),C=Ke(b,{x:e.position.x,y:e.position.y});this.commandHandler.portDrag(e.source,e.sourceWrapper,C.x-w.x,C.y-w.y)}return this.prevPosition=this.currentPosition,!this.blocked},t.prototype.getTooltipContent=function(e){return"X:"+Math.round(e.wrapper.bounds.x)+" Y:"+Math.round(e.wrapper.bounds.y)},t.prototype.mouseLeave=function(e){this.mouseUp(e)},t.prototype.endAction=function(){n.prototype.endAction.call(this),this.currentTarget=null,this.prevPosition=null},t}(us),qx=function(n){function t(e){var i=n.call(this,e,!0)||this;return i.rotateStart=!1,i}return ds(t,n),t.prototype.mouseDown=function(e){if(this.undoElement=$(e.source),this.undoElement.nodes[0]&&this.undoElement.nodes[0].children)for(var r=this.commandHandler.getAllDescendants(this.undoElement.nodes[0],[]),s=0;s=2){var s=e.startTouches[0],o=e.startTouches[1],a=e.moveTouches[0],l=e.moveTouches[1],h=this.getDistance(a,l)/this.getDistance(s,o);this.commandHandler.zoom(h,0,0,e.position),this.updateTouch(s,a),this.updateTouch(o,l)}}else this.commandHandler.scroll(this.currentPosition.x-this.prevPosition.x,this.currentPosition.y-this.prevPosition.y,this.currentPosition);return this.commandHandler.dataBinding(),!this.blocked},t.prototype.mouseUp=function(e){this.commandHandler.setBlazorDiagramProps(!1),this.checkPropertyValue(),this.commandHandler.updatePanState(!1),n.prototype.mouseUp.call(this,e),this.inAction=!1},t.prototype.endAction=function(){n.prototype.endAction.call(this)},t.prototype.getDistance=function(e,i){var r=i.pageX-e.pageX,s=i.pageY-e.pageY;return Math.sqrt(r*r+s*s)},t.prototype.updateTouch=function(e,i){e.pageX=i.pageX,e.pageY=i.pageY},t}(us),Une=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseUp=function(e){this.checkPropertyValue(),this.commandHandler.initExpand(e),n.prototype.mouseUp.call(this,e)},t}(us),eF=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseUp=function(e){this.checkPropertyValue();var i="_blank",r="",s=window.innerHeight,o=window.innerWidth,a=window.screenTop,l=window.screenLeft;"CurrentTab"===e.sourceWrapper.hyperlink.hyperlinkOpenState?i="_self":"NewWindow"===e.sourceWrapper.hyperlink.hyperlinkOpenState&&(r="height="+s+",width="+o+",top="+a+",left="+l),window.open(e.sourceWrapper.hyperlink.link,i,r).focus(),n.prototype.mouseUp.call(this,e)},t}(us),Rl=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseDown=function(e){if(n.prototype.mouseDown.call(this,e),this.inAction=!0,this.drawingObject){var r=void 0,s=this.drawingObject.shape;this.drawingObject.shape.points.push(r={x:(r=s.points[s.points.length-1]).x,y:r.y})}else{this.startPoint={x:this.startPosition.x,y:this.startPosition.y};var i={offsetX:this.currentPosition.x,offsetY:this.currentPosition.y,width:5,height:5,shape:{type:"Basic",shape:"Polygon",points:[{x:this.startPoint.x,y:this.startPoint.y},{x:this.currentPosition.x,y:this.currentPosition.y}]}};this.triggerElementDrawEvent(e.source,"Start","Node",this.getShapeType(),!0),this.drawingObject=this.commandHandler.drawObject(i)}},t.prototype.mouseMove=function(e){if(n.prototype.mouseMove.call(this,e),this.inAction){var i=this.drawingObject.shape;if(i.points[i.points.length-1].x=this.currentPosition.x,i.points[i.points.length-1].y=this.currentPosition.y,this.drawingObject.wrapper.children[0].data=Ix(this.drawingObject.shape.points),this.triggerElementDrawEvent(this.drawingObject,"Progress","Node",this.getShapeType(),!1),this.inAction&&!1===R.equals(this.currentPosition,this.prevPosition)){var r=Ne.toBounds(this.drawingObject.shape.points);this.commandHandler.updateNodeDimension(this.drawingObject,r)}}return!0},t.prototype.mouseUp=function(e,i){this.checkPropertyValue(),n.prototype.mouseMove.call(this,e),this.inAction&&(this.inAction=!1,this.commandHandler.addObjectToDiagram(this.drawingObject),this.triggerElementDrawEvent(this.drawingObject,"Completed","Node",this.getShapeType(),!1)),this.endAction()},t.prototype.mouseWheel=function(e){n.prototype.mouseWheel.call(this,e),this.mouseMove(e)},t.prototype.endAction=function(){this.inAction=!1,this.drawingObject=null},t}(us),Hl=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseMove=function(e){if(n.prototype.mouseMove.call(this,e),this.inAction){var i=this.drawingObject;i.targetPoint=this.currentPosition,this.triggerElementDrawEvent(this.drawingObject,"Progress","Connector",this.drawingObject.type,!1),this.commandHandler.updateConnectorPoints(i)}return!0},t.prototype.mouseDown=function(e){if(n.prototype.mouseDown.call(this,e),this.inAction=!0,this.drawingObject){var r=this.drawingObject,s=void 0;(s=new Bl(r,"segments",{type:"Straight"},!0)).point=this.currentPosition,r.segments[r.segments.length-1]=s}else{var i={id:"Connector",type:"Straight",sourcePoint:this.currentPosition,targetPoint:this.currentPosition};this.triggerElementDrawEvent(e.source,"Start","Connector",this.commandHandler.diagram.drawingObject.type,!0),this.inAction&&(this.drawingObject=this.commandHandler.drawObject(i))}},t.prototype.mouseWheel=function(e){n.prototype.mouseWheel.call(this,e),this.mouseMove(e)},t.prototype.mouseUp=function(e){if(this.checkPropertyValue(),n.prototype.mouseMove.call(this,e),this.inAction&&this.drawingObject){var i=this.drawingObject;i.segments[i.segments.length-1].point={x:0,y:0},this.commandHandler.addObjectToDiagram(this.drawingObject),this.triggerElementDrawEvent(this.drawingObject,"Completed","Connector",this.drawingObject.type,!1)}this.endAction()},t.prototype.endAction=function(){this.drawingObject=null,this.inAction=!1},t}(us),jne=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseDown=function(e){this.inAction=!0,this.undoElement=$(e.source),this.annotationId=e.sourceWrapper.id,n.prototype.mouseDown.call(this,e)},t.prototype.mouseMove=function(e){n.prototype.mouseMove.call(this,e);var i=this.currentPosition.x-this.prevPosition.x,r=this.currentPosition.y-this.prevPosition.y,s=e.source;if(s instanceof te){var o=Bi();qi(o,-s.rotateAngle,0,0);var a=Ke(o,{x:i,y:r});i=a.x,r=a.y}return this.inAction&&(this.commandHandler.labelDrag(e.source,e.sourceWrapper,i,r),this.commandHandler.updateSelector()),this.prevPosition=this.currentPosition,!this.blocked},t.prototype.mouseUp=function(e){this.checkPropertyValue();var i=e.source;this.inAction=!1;var r={type:"AnnotationPropertyChanged",objectId:this.annotationId,undoObject:$(this.undoElement),category:"Internal",redoObject:$(i)};this.commandHandler.addHistoryEntry(r),n.prototype.mouseUp.call(this,e)},t.prototype.mouseLeave=function(e){this.mouseUp(e)},t}(us),Vne=function(n){function t(e,i){var r=n.call(this,e,!0)||this;return r.corner=i,r}return ds(t,n),t.prototype.mouseDown=function(e){this.inAction=!0;var i=e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0];this.annotationId=e.source.wrapper.children[0].id,this.undoElement=$(i);var r=e.source.wrapper.children[0];this.initialBounds={x:r.offsetX,y:r.offsetY,width:r.actualSize.width,height:r.actualSize.height},n.prototype.mouseDown.call(this,e)},t.prototype.mouseMove=function(e){return n.prototype.mouseMove.call(this,e),this.inAction&&this.resizeObject(e),!this.blocked},t.prototype.mouseUp=function(e){this.checkPropertyValue();var i=e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0];this.inAction=!1;var r={type:"AnnotationPropertyChanged",objectId:this.annotationId,redoObject:$(i),undoObject:$(this.undoElement),category:"Internal"};this.commandHandler.addHistoryEntry(r),n.prototype.mouseUp.call(this,e)},t.prototype.mouseLeave=function(e){this.mouseUp(e)},t.prototype.resizeObject=function(e){var i,s,o,r=e.source.wrapper.children[0],a={x:r.offsetX,y:r.offsetY},l=r.rotateAngle;l=((l+=(i=e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0])instanceof te?i.rotateAngle:0)+360)%360;var h=Bi();qi(h,l,a.x,a.y);var c=this.corner.slice(5),d=this.updateSize(r,this.startPosition,this.currentPosition,c,this.initialBounds,l),u=r.offsetX-r.actualSize.width*r.pivot.x,f=r.offsetY-r.actualSize.height*r.pivot.y,p=this.getPivot(c),g=Ke(h,p={x:u+r.actualSize.width*p.x,y:f+r.actualSize.height*p.y});d.x=g.x,d.y=g.y,this.commandHandler.labelResize(i,e.source.annotation,s=(s=d.width)<0?1:s,o=(o=d.height)<0?1:o,d,e.source),this.commandHandler.updateSelector()},t}(us),Wne=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseDown=function(e){this.inAction=!0,this.annotationId=e.source.wrapper.children[0].id,this.undoElement=$(e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0]),n.prototype.mouseDown.call(this,e)},t.prototype.mouseMove=function(e){return n.prototype.mouseMove.call(this,e),e.source&&this.inAction&&(this.commandHandler.labelRotate(e.source.nodes[0]?e.source.nodes[0]:e.source.connectors[0],e.source.annotation,this.currentPosition,e.source),this.commandHandler.updateSelector()),this.prevPosition=this.currentPosition,!this.blocked},t.prototype.mouseUp=function(e){this.checkPropertyValue(),this.inAction=!1;var r={type:"AnnotationPropertyChanged",objectId:this.annotationId,redoObject:$(e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0]),undoObject:$(this.undoElement),category:"Internal"};this.commandHandler.addHistoryEntry(r),n.prototype.mouseUp.call(this,e)},t.prototype.mouseLeave=function(e){this.mouseUp(e)},t}(us),Yne=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseMove=function(e){if(n.prototype.mouseMove.call(this,e),this.inAction){var i=this.drawingObject.shape;if(i.points.push(this.currentPosition),this.drawingObject.wrapper.children[0].data=bx(this.drawingObject.shape.points),i.data=bx(i.points),this.triggerElementDrawEvent(e.source,"Progress","Connector",this.drawingObject.type,!1),this.inAction&&!1===R.equals(this.currentPosition,this.prevPosition)){var s=Ne.toBounds(this.drawingObject.shape.points);this.commandHandler.updateNodeDimension(this.drawingObject,s)}}return!0},t.prototype.mouseDown=function(e){n.prototype.mouseDown.call(this,e),this.inAction=!0,this.startPoint={x:this.startPosition.x,y:this.startPosition.y};var i={offsetX:this.currentPosition.x,offsetY:this.currentPosition.y,width:5,height:5,style:{strokeColor:"black",strokeWidth:1,fill:"transparent"},shape:{type:"Path",points:[{x:this.startPoint.x,y:this.startPoint.y},{x:this.currentPosition.x,y:this.currentPosition.y}]}};this.triggerElementDrawEvent(e.source,"Start","Connector",this.commandHandler.diagram.drawingObject.type,!0),this.drawingObject=this.commandHandler.drawObject(i)},t.prototype.mouseUp=function(e){if(this.checkPropertyValue(),this.inAction){this.inAction=!1;var s=this.drawingObject.shape,o=s.points;this.commandHandler.addObjectToDiagram(this.drawingObject),this.commandHandler.diagram.remove(this.commandHandler.diagram.nameTable[""+this.drawingObject.id]),o=this.pointReduction(o,10);var h={id:"newConnector"+Qe(),type:"Bezier",sourcePoint:{x:o[0].x,y:o[0].y},targetPoint:{x:o[o.length-1].x,y:o[o.length-1].y},segments:[],bezierSettings:{allowSegmentsReset:!1}};this.drawingObject=this.commandHandler.drawObject(h),this.drawingObject=this.bezierCurveSmoothness(o,.5,this.drawingObject,s),this.commandHandler.updateConnectorPoints(this.drawingObject),this.commandHandler.addObjectToDiagram(this.drawingObject),this.triggerElementDrawEvent(this.drawingObject,"Completed","Connector",this.drawingObject.type,!1),n.prototype.mouseUp.call(this,e)}},t.prototype.pointReduction=function(e,i){if(null===e||e.length<3)return e;var s=e.length-1,o=[];for(o.push(0),o.push(s);e[parseInt((0).toString(),10)]===e[parseInt(s.toString(),10)];)s--;this.reduction(e,0,s,i,o);var a=[];return o.sort(function(l,h){return l-h}),o.forEach(function(l){a.push(e[parseInt(l.toString(),10)])}),a},t.prototype.reduction=function(e,i,r,s,o){for(var a=0,l=0,h=i;ha&&(a=c,l=h)}a>s&&0!==l&&(o.push(l),this.reduction(e,i,l,s,o),this.reduction(e,l,r,s,o))},t.prototype.perpendicularDistance=function(e,i,r){return Math.abs(.5*(e.x*i.y-i.x*e.y+(i.x*r.y-r.x*i.y)+(r.x*e.y-e.x*r.y)))/Math.sqrt(Math.pow(e.x-i.x,2)+Math.pow(e.y-i.y,2))*2},t.prototype.bezierCurveSmoothness=function(e,i,r,s){if(e.length<3)return r;for(var o=0;o=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Qne=function(n){if(n)switch(n.type){case"Bpmn":return $ne;case"UmlActivity":return qne;case"UmlClassifier":return Kne;default:return rm}return rm},Gne=function(n){if(n)switch(n.type){case"Straight":default:return Bl;case"Bezier":return fs;case"Orthogonal":return wi}},tF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I(10)],t.prototype,"width",void 0),Pe([I(10)],t.prototype,"height",void 0),Pe([I("Arrow")],t.prototype,"shape",void 0),Pe([re({fill:"black",strokeColor:"black",strokeWidth:1},Nl)],t.prototype,"style",void 0),Pe([re({x:0,y:.5},R)],t.prototype,"pivot",void 0),Pe([I("")],t.prototype,"pathData",void 0),t}(Ee),KI=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I(0)],t.prototype,"angle",void 0),Pe([I(0)],t.prototype,"distance",void 0),t}(Ee),Xne=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I(Ex.All)],t.prototype,"controlPointsVisibility",void 0),Pe([I("FreeForm")],t.prototype,"segmentEditOrientation",void 0),Pe([I(DI.Default)],t.prototype,"smoothness",void 0),Pe([I(!0)],t.prototype,"allowSegmentsReset",void 0),t}(Ee),rm=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I("None")],t.prototype,"type",void 0),t}(Ee),qne=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I("Object")],t.prototype,"flow",void 0),Pe([I(30)],t.prototype,"exceptionFlowHeight",void 0),t}(rm),$ne=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I("Sequence")],t.prototype,"flow",void 0),Pe([I("Normal")],t.prototype,"sequence",void 0),Pe([I("Default")],t.prototype,"message",void 0),Pe([I("Default")],t.prototype,"association",void 0),t}(rm),iF=function(n){function t(e,i,r,s){var o=n.call(this,e,i,r,s)||this;return o.points=[],o}return Qs(t,n),Pe([I("Straight")],t.prototype,"type",void 0),Pe([I(!0)],t.prototype,"allowDrag",void 0),t}(Ee),Bl=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),t.prototype.getClassName=function(){return"StraightSegment"},Pe([re({x:0,y:0},R)],t.prototype,"point",void 0),t}(iF),fs=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),t.prototype.getClassName=function(){return"BezierSegment"},t.prototype.getPoints=function(e,i){var r=[];if(r.length>0||null!=i){var o=this.bezireToPoly(r.length>0?r[r.length-1]:i,e);r.push.apply(r,o)}return r},t.prototype.bezireToPoly=function(e,i){var r=[];return i&&this.flattenCubicBezier(r,e,i.bezierPoint1,i.bezierPoint2,{x:i.points[1].x,y:i.points[1].y},10),r},t.prototype.flattenCubicBezier=function(e,i,r,s,o,a){var h,l=(R.findLength(i,r)+R.findLength(r,s)+R.findLength(s,o))/a;for(h=0;h<=l;h++){var c=h/l;e.push({x:(1-c)*(1-c)*(1-c)*i.x+3*c*(1-c)*(1-c)*r.x+3*c*c*(1-c)*s.x+c*c*c*o.x,y:(1-c)*(1-c)*(1-c)*i.y+3*c*(1-c)*(1-c)*r.y+3*c*c*(1-c)*s.y+c*c*c*o.y})}},Pe([I("Horizontal")],t.prototype,"orientation",void 0),Pe([re({x:0,y:0},R)],t.prototype,"point1",void 0),Pe([re({x:0,y:0},R)],t.prototype,"point2",void 0),Pe([re({angle:0,distance:0},KI)],t.prototype,"vector1",void 0),Pe([re({angle:0,distance:0},KI)],t.prototype,"vector2",void 0),t}(Bl),wi=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),t.prototype.getClassName=function(){return"OrthogonalSegment"},Pe([I(null)],t.prototype,"length",void 0),Pe([I(null)],t.prototype,"direction",void 0),t}(iF);function rF(n,t,e){var s=e?45:180/(2+2/(n.height/n.width)),o=s,a=180-s,l=a+2*s,h=360-s,c=Gt(t,n.center);return c>o&&ca&&cl&&cMath.abs(t.y-n.y)?n.x=c)return s=R.findAngle(n[parseInt(d.toString(),10)],n[d+1]),{point:r=R.transform(n[parseInt(d.toString(),10)],s,c-(a||0)),index:l=d};a=o[parseInt(d.toString(),10)]}return{point:r,index:l}}(n,t),r=R.findAngle(n[i.index],n[i.index+1]),s=function xse(n){var e=0;switch(n.alignment){case"Center":case"After":e=0;break;case"Before":e=-0}return e}(t),o=R.transform(i.point,r+45,s);return i.point=o,i.angle=r,i}(i,e),h=l.point;s.id=this.id+"_"+e.id;var c=e.style;s.style={fill:c.fill,strokeColor:c.strokeColor,gradient:null,opacity:c.opacity,strokeDashArray:c.strokeDashArray,strokeWidth:c.strokeWidth},0===r.width&&(r.width=this.style.strokeWidth),0===r.height&&(r.height=this.style.strokeWidth);var d_y=(h.y-r.y)/r.height;a.x=r.width*((h.x-r.x)/r.width),a.y=r.height*d_y;var g,v,u=SF(e,l.angle,i),f=u.hAlign,p=u.vAlign;return"left"===f?(g="Left",a.x+=e.displacement.x):"right"===f?(g="Right",a.x-=e.displacement.x):"center"===f&&(g="Center"),"top"===p?(v="Top",a.y+=e.displacement.y):"bottom"===p?(v="Bottom",a.y-=e.displacement.y):"center"===p&&(v="Center"),s.horizontalAlignment=g,s.verticalAlignment=v,(s=om(s,o&&"Label"!==o.flipMode&&"None"!==o.flipMode?this.flip:"None",e)).float=!0,s.connectionDirection=e.connectionDirection,s.setOffsetWithRespectToBounds(a.x,a.y,"Absolute"),s.relativeMode="Point",s.visible=!(!va(e,ci.Visible)||va(e,ci.Hover)||va(e,ci.Connect)),s.elementActions=s.elementActions|Xr.ElementIsPort,s},t.prototype.getConnectorRelation=function(){var e=this.shape;"Association"===e.relationship?(this.segments[0].type="Straight",this.sourceDecorator.shape="None",this.targetDecorator.shape="Arrow"):"Inheritance"===e.relationship?(this.segments[0].type="Orthogonal",this.sourceDecorator.shape="None",this.targetDecorator.shape="Arrow"):"Composition"===e.relationship||"Aggregation"===e.relationship?(this.segments[0].type="Orthogonal",this.sourceDecorator.shape="Diamond",this.targetDecorator.shape="None"):"Dependency"===e.relationship?(this.segments[0].type="Orthogonal",this.sourceDecorator.shape="None",this.targetDecorator.shape="OpenArrow"):"Realization"===e.relationship&&(this.segments[0].type="Orthogonal",this.sourceDecorator.shape="None",this.targetDecorator.shape="Arrow"),"BiDirectional"===e.associationType&&(this.sourceDecorator.shape="None",this.targetDecorator.shape="None");var i,o,r="",s="";e.multiplicity.source&&(e.multiplicity.source.lowerBounds=e.multiplicity.source.lowerBounds,e.multiplicity.source.upperBounds=e.multiplicity.source.upperBounds),e.multiplicity.target&&(e.multiplicity.target.lowerBounds=e.multiplicity.target.lowerBounds,e.multiplicity.target.upperBounds=e.multiplicity.target.upperBounds);var a=e.multiplicity.source,l=e.multiplicity.target;o=a.upperBounds?a.lowerBounds+"..."+a.upperBounds:a.lowerBounds,i=l.upperBounds?l.lowerBounds+"..."+l.upperBounds:l.lowerBounds,"ManyToOne"===e.multiplicity.type&&(e.multiplicity.target.optional=!1,r=o||"*",s="1"),"OneToMany"===e.multiplicity.type&&(e.multiplicity.source.optional=!1,s=i||"*",r="1"),"ManyToMany"===e.multiplicity.type&&(r=o||"*",s=i||"*"),"OneToOne"===e.multiplicity.type&&(e.multiplicity.target.optional=!1,e.multiplicity.source.optional=!1,r="1",s="1"),this.annotations=[{id:this.id+"sourcelabel",content:r,offset:0,alignment:"Before",margin:{right:5,bottom:5}},{id:this.id+"targetlabel",content:s,offset:1,alignment:"Before",margin:{right:5,bottom:5}}]},t.prototype.getBpmnSequenceFlow=function(){var e=new Ze,i=new Ze;return"Normal"===this.shape.sequence&&"Bezier"!==this.type&&(this.targetDecorator.shape="Arrow"),"Default"===this.shape.sequence&&(e=this.getSegmentElement(this,e),i=DF(this.intermediatePoints,this),this.targetDecorator.shape="Arrow"),"Conditional"===this.shape.sequence&&(this.targetDecorator.shape="Arrow",this.sourceDecorator.shape="Diamond",i.id=this.id+this.shape.type),i},t.prototype.getUMLObjectFlow=function(){if(this.annotations)for(var e=0;e0&&(this.sourcePoint=o[0],this.targetPoint=o[o.length-1]),o},t.prototype.clipDecorator=function(e,i,r,s){var a,l,o={x:0,y:0},h=i.length,c=R.distancePoints(a=r?i[0]:i[h-1],l=r?i[1]:i[h-2]);c=0===c?1:c;var d=1,u=r?e.sourceWrapper:e.targetWrapper;u&&(d=u.style.strokeWidth,s&&s&ee.DecoratorPropertyChange&&(d=1));var f=d-1;return o.x=Math.round(a.x+f*(l.x-a.x)/c),o.y=Math.round(a.y+f*(l.y-a.y)/c),(r&&"None"!==e.sourceDecorator.shape||!r&&"None"!==e.targetDecorator.shape)&&(o=R.adjustPoint(o,l,!0,s&ee.DecoratorPropertyChange?0:d/2)),o},t.prototype.clipDecorators=function(e,i,r){return"None"!==e.sourceDecorator.shape&&(i[0]=this.clipDecorator(e,i,!0,r)),"None"!==e.targetDecorator.shape&&(i[i.length-1]=this.clipDecorator(e,i,!1,r)),i},t.prototype.updateSegmentElement=function(e,i,r,s){var o=new Ne,a=this.getSegmentPath(e,i,s);if("Bezier"===e.type){if(this.segments.length>0)for(var l=0;l0)if("Straight"===e.type&&e.segments.length<2)for(var o=0;o1)for(o=0;o0&&"Bezier"!==this.type)for(var f=0;f0&&(a=f0&&(p<2*this.cornerRadius?(l=R.adjustPoint(h[parseInt(f.toString(),10)],h[f+1],!0,p/2),f0&&(s=this.bridgePath(e,s,f),"Orthogonal"===e.type&&(s=this.bridgePath(e,s,f+1))),s+=" L"+a.x+" "+a.y))}else if("Bezier"===this.type){var g=void 0,v=void 0;if(this.parentObj.element){var y=this.parentObj.element.ej2_instances[0].eventHandler.action;g=this.parentObj.element.ej2_instances[0].eventHandler.tool instanceof Hd,v=y.includes("PortDraw")||y.includes("Drag")}for(var S=void 0,b=this.segments,M=0;M2&&(b[parseInt(M.toString(),10)].bezierPoint1={x:0,y:0},b[parseInt(M.toString(),10)].bezierPoint2={x:0,y:0}),!R.isEmptyPoint(b[parseInt(M.toString(),10)].point1)||b[parseInt(M.toString(),10)].vector1.angle||b[parseInt(M.toString(),10)].vector1.distance?b[parseInt(M.toString(),10)].vector1.angle||b[parseInt(M.toString(),10)].vector1.distance?b[parseInt(M.toString(),10)].bezierPoint1=R.transform(h[parseInt(M.toString(),10)],b[parseInt(M.toString(),10)].vector1.angle,b[parseInt(M.toString(),10)].vector1.distance):b[parseInt(M.toString(),10)].bezierPoint1={x:b[parseInt(M.toString(),10)].point1.x||b[parseInt(M.toString(),10)].bezierPoint1.x,y:b[parseInt(M.toString(),10)].point1.y||b[parseInt(M.toString(),10)].bezierPoint1.y}:((e.sourceID||this.sourcePortID)&&this.sourceWrapper&&!v&&!g&&(S=rF(this.sourceWrapper.bounds,h[parseInt(M.toString(),10)],!0)),b[parseInt(M.toString(),10)].bezierPoint1=tb(h[parseInt(M.toString(),10)],h[M+1],S)),!R.isEmptyPoint(b[parseInt(M.toString(),10)].point2)||b[parseInt(M.toString(),10)].vector2.angle||b[parseInt(M.toString(),10)].vector2.distance?b[parseInt(M.toString(),10)].vector2.angle||b[parseInt(M.toString(),10)].vector2.distance?b[parseInt(M.toString(),10)].bezierPoint2=R.transform(h[M+1],b[parseInt(M.toString(),10)].vector2.angle,b[parseInt(M.toString(),10)].vector2.distance):b[parseInt(M.toString(),10)].bezierPoint2={x:b[parseInt(M.toString(),10)].point2.x||b[parseInt(M.toString(),10)].bezierPoint2.x,y:b[parseInt(M.toString(),10)].point2.y||b[parseInt(M.toString(),10)].bezierPoint2.y}:((e.targetID||this.targetPortID)&&this.targetWrapper&&!v&&!g&&(S=rF(this.targetWrapper.bounds,h[M+1],!0)),b[parseInt(M.toString(),10)].bezierPoint2=tb(h[M+1],h[parseInt(M.toString(),10)],S));h.splice(1,0,{x:b[0].bezierPoint1.x,y:b[0].bezierPoint1.y}),h.splice(h.length-1,0,{x:b[b.length-1].bezierPoint2.x,y:b[b.length-1].bezierPoint2.y}),h=this.clipDecorators(e,h,r);for(var w=0;w0&&(s=this.bridgePath(e,s,D),s+=" L"+o.x+" "+o.y);return s},t.prototype.updateShapeElement=function(e){var i;switch(e.shape.type){case"Bpmn":e.wrapper.children[3]instanceof Ze&&(i=e.wrapper.children[3]),"Message"===e.shape.flow&&this.updateShapePosition(e,i);break;case"UmlActivity":"Exception"===e.shape.flow&&this.getUMLExceptionFlow(e.wrapper.children[0])}},t.prototype.updateShapePosition=function(e,i){var o=xF(this.intermediatePoints,i,.5);i.offsetX=o.x,i.offsetY=o.y},t.prototype.scale=function(e,i,r,s,o){var a=0,l=0;if(this.wrapper&&this.wrapper.outerBounds){var h=function T3(n){var t=n.wrapper.children[0].bounds;return"None"!==n.sourceDecorator.shape&&t.uniteRect(n.wrapper.children[1].bounds),"None"!==n.targetDecorator.shape&&t.uniteRect(n.wrapper.children[2].bounds),t}(this),c=Math.abs((this.wrapper.bounds.width||this.style.strokeWidth||1)-2),d=Math.abs((this.wrapper.bounds.height||this.style.strokeWidth||1)-2);a=h.width-c,l=h.height-d,e=Math.abs((r-Math.max(a,l))/c),i=Math.abs((s-Math.max(a,l))/d),a=l=Math.min(a,l)}e=i=Math.min(e,i);var u=Bi();qi(u,-(o=o||this.wrapper).rotateAngle,o.offsetX,o.offsetY),qf(u,e,i,o.offsetX,o.offsetY),qi(u,o.rotateAngle,o.offsetX,o.offsetY);var f=function Uie(n,t){for(var e=[],i=0,r=t;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},tse=function(n){function t(e,i){var r=n.call(this,e,i)||this;return r.offset=0,r.scale=1,r}return ese(t,n),t.prototype.preRender=function(){this.unWireEvents(),this.wireEvents()},t.prototype.render=function(){this.updateRulerGeometry(),this.renderComplete()},t.prototype.getModuleName=function(){return"Ruler"},t.prototype.destroy=function(){this.unWireEvents(),this.notify("destroy",{}),n.prototype.destroy.call(this),this.element.classList.remove("e-ruler")},t.prototype.getPersistData=function(){return this.addOnPersist(["loaded"])},t.prototype.onPropertyChanged=function(e,i){for(var r=0,s=Object.keys(e);r100;)r/=10,s/=10;for(;s<25;)r*=10,s*=10;return s>=25&&s%25!=0&&(s=25*Math.round(s/25)),s*e/r},t.prototype.createMarkerLine=function(e,i,r){var s;return i&&((s=e.getElementById(i.id+"_marker"))&&s.parentNode.removeChild(s),s=Fi("line",r)),s},t.prototype.drawRulerMarker=function(e,i,r){var s,o,h,d,u="Horizontal"===this.orientation,f=e.getElementsByTagName("svg");for(h=0;h0)for(var a=i.childNodes.length-1;a>=0;a--)i.childNodes[parseInt(a.toString(),10)].parentNode.removeChild(i.childNodes[parseInt(a.toString(),10)]);i.appendChild(s)}return s},t.prototype.wireEvents=function(){},t.prototype.unWireEvents=function(){},zc([I(5)],t.prototype,"interval",void 0),zc([I(100)],t.prototype,"segmentWidth",void 0),zc([I("Horizontal")],t.prototype,"orientation",void 0),zc([I("RightOrBottom")],t.prototype,"tickAlignment",void 0),zc([I("red")],t.prototype,"markerColor",void 0),zc([I(25)],t.prototype,"thickness",void 0),zc([I(null)],t.prototype,"arrangeTick",void 0),zc([I(400)],t.prototype,"length",void 0),t}(Ii);function oF(n,t){var e=document.getElementById(n.element.id+(t?"_hRuler":"_vRuler")),i=Za(n),r=aF(n);e||(e=Tt("div",{id:n.element.id+(t?"_hRuler":"_vRuler"),style:"height:"+(t?i.height:r.height+100)+"px;overflow:hidden;width:"+(t?r.width+100:i.width)+"px;position:absolute;font-size:11px;"+(t?"margin-left:"+i.width+"px;":"margin-top:"+i.height+"px;")})),n.element.insertBefore(e,n.element.firstChild);var l=t?n.rulerSettings.horizontalRuler:n.rulerSettings.verticalRuler,h=new tse(l);h.orientation=t?"Horizontal":"Vertical",h.length=(t?r.width:r.height)+l.segmentWidth,h.appendTo("#"+n.element.id+(t?"_hRuler":"_vRuler")),t?n.hRuler=h:n.vRuler=h;var c=document.getElementById(n.element.id+(t?"_hRuler":"_vRuler"));t?n.hRuler.element=c:n.vRuler.element=c}function ib(n){var t=-n.scroller.horizontalOffset,e=-n.scroller.verticalOffset;n&&n.rulerSettings.showRulers?(n.hRuler.length=0,n.vRuler.length=0,void 0!==t&&n.hRuler.element&&lF(n,n.hRuler,t,!0),void 0!==e&&n.vRuler.element&&lF(n,n.vRuler,e,!1)):$x(n)}function $x(n){an(n.element.id+"_hRuler"),an(n.element.id+"_vRuler"),an(n.element.id+"_overlapRuler")}function Za(n){var t=0,e=0;return n.rulerSettings.showRulers&&(t=n.rulerSettings.horizontalRuler.thickness,e=n.rulerSettings.verticalRuler.thickness),new me(e,t)}function aF(n){var t=Za(n),e=n.scroller.viewPortHeight,i=n.scroller.viewPortWidth;return i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},hF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return ase(t,n),t.prototype.getClassName=function(){return"UserHandle"},Un([I("")],t.prototype,"name",void 0),Un([I("")],t.prototype,"pathData",void 0),Un([I("")],t.prototype,"content",void 0),Un([I("")],t.prototype,"source",void 0),Un([I("#000000")],t.prototype,"backgroundColor",void 0),Un([I("Top")],t.prototype,"side",void 0),Un([I("")],t.prototype,"borderColor",void 0),Un([I(.5)],t.prototype,"borderWidth",void 0),Un([I(25)],t.prototype,"size",void 0),Un([I("white")],t.prototype,"pathColor",void 0),Un([I(10)],t.prototype,"displacement",void 0),Un([I(!0)],t.prototype,"visible",void 0),Un([I(0)],t.prototype,"offset",void 0),Un([re({},Jn)],t.prototype,"margin",void 0),Un([I("Center")],t.prototype,"horizontalAlignment",void 0),Un([I("Center")],t.prototype,"verticalAlignment",void 0),Un([I(!1)],t.prototype,"disableNodes",void 0),Un([I(!1)],t.prototype,"disableConnectors",void 0),Un([re({},Ad)],t.prototype,"tooltip",void 0),Un([I("")],t.prototype,"template",void 0),t}(Ee);function cF(n){return lse[n.toString()]}var lse={Action:"M 90 82.895 C 90 86.819 86.776 90 82.8 90 H 7.2 C 3.224 90 0 86.819 0 82.895 V 7.105 C 0 3.181 3.224 0 7.2 0 h 75.6 C 86.776 0 90 3.181 90 7.105 V 82.895 Z",Decision:"M10,19.707L0.293,10L10,0.293L19.707,10L10,19.707z",MergeNode:"M10,19.707L0.293,10L10,0.293L19.707,10L10,19.707z",InitialNode:"M10,19.5c-5.238,0-9.5-4.262-9.5-9.5S4.762,0.5,10,0.5s9.5,4.262,9.5,9.5S15.238,19.5,10,19.5z",ForkNode:"m0.75,0.75l636.00002,0l0,290l-636.00002,0l0,-290z",JoinNode:"m0.75,0.75l636.00002,0l0,290l-636.00002,0l0,-290z",TimeEvent:"M50.001,0.00286865 L25.001,25.0029 L0.000976562,0.00286865 L50.001,0.00286865 z M0.000976562,50.0029 L25.001,25.0029 L50.001,50.0029 L0.000976562,50.0029 z",AcceptingEvent:"M17.8336 32.164 L29.64 24 L17.32 16 L48.1664 16 L48.5 32 Z",SendSignal:"M48.164 31.8336 L56 23.832 L47.836 16 L16.168 16 L16.1668 31.8336 Z",ReceiveSignal:"M48.1664 31.8336 L39.836 24 L47.836 16 L16.168 16 L16.168 31.836 Z",StructuredNode:"M0,0 L50,0 L50,50 L0,50 z",Note:"M20 12 L4 12 L4 22 L22 22 L22 14 L20 14 L20 12 L22 14 Z"},rb=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Ja=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},hse=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return rb(t,n),Ja([I()],t.prototype,"key",void 0),Ja([I()],t.prototype,"keyModifiers",void 0),t}(Ee),dF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return rb(t,n),t.prototype.getClassName=function(){return"Command"},Ja([I("")],t.prototype,"name",void 0),Ja([I()],t.prototype,"canExecute",void 0),Ja([I()],t.prototype,"execute",void 0),Ja([re({},hse)],t.prototype,"gesture",void 0),Ja([I("")],t.prototype,"parameter",void 0),t}(Ee),cse=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return rb(t,n),Ja([Bt([],dF)],t.prototype,"commands",void 0),t}(Ee),dse=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return rb(t,n),Ja([I()],t.prototype,"show",void 0),Ja([I()],t.prototype,"showCustomMenuOnly",void 0),Ja([I()],t.prototype,"items",void 0),t}(Ee),ep=function(){function n(){}return n.prototype.renderShadow=function(t,e,i,r){void 0===i&&(i=null);var l,o=R.transform({x:0,y:0},t.shadow.angle,t.shadow.distance);r&&(l=r.getElementById(e.id+"_shadow")),l||(l=document.createElementNS("http://www.w3.org/2000/svg",i?"path":"rect"),e.appendChild(l));var h={id:e.id+"_shadow",fill:t.shadow.color,stroke:t.shadow.color,opacity:t.shadow.opacity.toString(),transform:"rotate("+t.angle+","+(t.x+t.width*t.pivotX)+","+(t.y+t.height*t.pivotY)+")translate("+(t.x+o.x)+","+(t.y+o.y)+")"};if(r){var c=r.getElementById(e.id);c&&c.insertBefore(l,c.firstChild)}ti(l,h),i?i&&this.renderPath(l,t,i):ti(l,{width:t.width,height:t.height})},n.prototype.parseDashArray=function(t){return[]},n.prototype.drawRectangle=function(t,e,i,r,s,o,a,l,h){var c,d,u,f;e.shadow&&!r&&this.renderShadow(e,t,void 0,o),c=e.id===t.id?e.id+"_container":e.id,o&&(d=o.getElementById(c)),(!d||s)&&(d=document.createElementNS("http://www.w3.org/2000/svg","rect"),t.appendChild(d)),o&&!e.shadow&&(u=o.getElementById(e.id+"_groupElement_shadow"))&&u.parentNode.removeChild(u),f=l?{id:c,x:e.x.toString(),y:e.y.toString(),width:e.width.toString(),height:e.height.toString(),visibility:e.visible?"visible":"hidden",transform:"rotate("+e.angle+","+(e.x+e.width/2)+","+(e.y+e.height/2)+")",rx:e.cornerRadius||0,ry:e.cornerRadius||0,opacity:e.opacity}:{id:c,x:e.x.toString(),y:e.y.toString(),width:e.width.toString(),height:e.height.toString(),visibility:e.visible?"visible":"hidden",transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")",rx:e.cornerRadius||0,ry:e.cornerRadius||0,opacity:e.opacity},a&&(f.role="img",f["aria-label"]=a);var p=e.class||"";h||(p.includes("e-diagram-resize-handle")||p.includes("e-diagram-endpoint-handle")||p.includes("e-diagram-bezier-control-handle"))&&(p+=" e-disabled"),e.class&&(f.class=p),a||(f["pointer-events"]="none"),ti(d,f),this.setSvgStyle(d,e,i)},n.prototype.updateSelectionRegion=function(t,e){var i;i=t.parentNode.getElementById(e.id);var r={id:e.id,x:e.x.toString(),y:e.y.toString(),width:e.width.toString(),height:e.height.toString(),transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")",class:"e-diagram-selected-region"};i||(i=document.createElementNS("http://www.w3.org/2000/svg","rect"),t.appendChild(i)),this.setSvgStyle(i,e),ti(i,r)},n.prototype.createGElement=function(t,e){return Fi(t,e)},n.prototype.drawLine=function(t,e){var i=document.createElementNS("http://www.w3.org/2000/svg","line");this.setSvgStyle(i,e);var r=e.x+e.width*e.pivotX,s=e.y+e.height*e.pivotY,o={id:e.id,x1:e.startPoint.x+e.x,y1:e.startPoint.y+e.y,x2:e.endPoint.x+e.x,y2:e.endPoint.y+e.y,stroke:e.stroke,"stroke-width":e.strokeWidth.toString(),opacity:e.opacity.toString(),transform:"rotate("+e.angle+" "+r+" "+s+")",visibility:e.visible?"visible":"hidden"};e.class&&(o.class=e.class),ti(i,o),t.appendChild(i)},n.prototype.drawCircle=function(t,e,i,r){var s=document.createElementNS("http://www.w3.org/2000/svg","circle");this.setSvgStyle(s,e);var o=e.class||"";i||(o+=" e-disabled");var a={id:e.id,cx:e.centerX,cy:e.centerY,r:e.radius,visibility:e.visible?"visible":"hidden",class:o};r&&(a.role="img",a["aria-label"]=r),s.style.display=e.visible?"block":"none",ti(s,a),t.appendChild(s)},n.prototype.drawPath=function(t,e,i,r,s,o,a){var h,c,l=[];l=e3(l=Td(e.data)),e.shadow&&this.renderShadow(e,t,l,s),s&&!e.shadow&&(h=s.getElementById(e.id+"_groupElement_shadow"))&&h.parentNode.removeChild(h),s&&(c=s.getElementById(e.id)),(!c||r)&&(c=document.createElementNS("http://www.w3.org/2000/svg","path"),t.appendChild(c)),this.renderPath(c,e,l);var d={};d=a?{id:e.id,transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")translate("+e.x+","+e.y+"),scale("+a+")",visibility:e.visible?"visible":"hidden",opacity:e.opacity}:{id:e.id,transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")translate("+e.x+","+e.y+")",visibility:e.visible?"visible":"hidden",opacity:e.opacity},o&&(d.role="img",d["aria-label"]=o),e.class&&(d.class=e.class),ti(c,d),this.setSvgStyle(c,e,i)},n.prototype.renderPath=function(t,e,i){var r,s,o,a,l,h,c,d,u=i,f="";for(l=0,h=0,d=0,c=u.length;de.width&&"Wrap"!==e.textOverflow&&"NoWrap"===e.textWrapping&&(h[0].text=qF(e.content,e)),v=0;vD&&(u.text=u.text.slice(0,u.text.length-3),u.text=u.text.concat("..."),l.data=u.text),this.alignText(y,f,u,l,p,g,v,e,h),C+=u.dy}}C&&e.isHorizontalLane&&(M=e.parentOffsetX+e.pivotX,w=e.parentOffsetY+e.pivotY,e.y=e.parentOffsetY-C*e.pivotY+.5),e.textDecoration&&"LineThrough"===e.textDecoration&&(e.textDecoration=mb(e.textDecoration));var P={id:e.id+"_text",fill:e.color,visibility:e.visible?"visible":"hidden","text-decoration":e.textDecoration,transform:"rotate("+e.angle+","+M+","+w+")translate("+e.x+","+e.y+")",opacity:e.opacity};r&&(P.role="img",P["aria-label"]=r),ti(y,P)}},n.prototype.alignText=function(t,e,i,r,s,o,a,l,h){"justify"!==l.textAlign?this.setText(t,e,i,r,s,o,l):a!==h.length-1?this.setText(t,e,i,r,s,o,l,l.width,"spacing"):this.setText(t,e,i,r,s,o,l)},n.prototype.setText=function(t,e,i,r,s,o,a,l,h){ti(e,"justify"!==a.textAlign?{x:s.toString(),y:o.toString()}:{x:s.toString(),y:o.toString(),textLength:l||0,lengthAdjust:h||"spacing"}),t.setAttribute("fill",i.text),e.appendChild(r),t.appendChild(e)},n.prototype.drawImage=function(t,e,i,r){var s;i&&(s=i.getElementById(e.id+"image")),s||(s=document.createElementNS("http://www.w3.org/2000/svg","image"),t.appendChild(s));var o=new Image;o.src=e.source;var a="None"!==e.scale?e.scale:"",l=e.alignment,h=l.charAt(0).toLowerCase()+l.slice(1);"Stretch"!==a&&(h+=" "+a.charAt(0).toLowerCase()+a.slice(1)),ti(s,{id:e.id+"image",x:e.x.toString(),y:e.y.toString(),transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")",width:e.width.toString(),visibility:e.visible?"visible":"hidden",height:e.height.toString(),preserveAspectRatio:h,opacity:e.opacity.toString()}),s.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",o.src.toString())},n.prototype.drawHTMLContent=function(t,e,i,r,s){var o,a;if(e&&(o=e.querySelector("#"+t.id+"_html_element")),!o){(a=e.querySelector("#"+t.id+"_html_element")||e.querySelector("#"+t.nodeId+"_html_element"))||(a=Tt("div",{id:t.nodeId+"_html_element",class:"foreign-object"})),o=Tt("div",{id:t.id+"_html_element",class:"foreign-object"});var c=document.getElementById(t.diagramId).ej2_instances[0],d=!1;if(e.parentNode&&e.parentNode.parentNode&&e.parentNode.parentNode.parentNode&&e.parentNode.parentNode.parentNode.classList.contains("e-overview")&&(d=!0),d)c.isReact?c.renderReactTemplates(function(){o.appendChild(t.template.cloneNode(!0))}):o.appendChild(t.template.cloneNode(!0));else{if("string"==typeof t.template){var u=document.createElement("div");u.innerHTML=t.template,t.template=u,c.selectedItems.userHandles.filter(function(g){return g.name===t.id.split("_shape")[0]&&""!==g.template})[0].template=t.template}t.isTemplate&&t.template?o.appendChild(t.template):t.template&&o.appendChild(t.template.cloneNode(!0))}void 0!==s&&e.childNodes.length>s&&e.insertBefore(o,e.childNodes[parseInt(s.toString(),10)]),a.appendChild(o),e.appendChild(a)}var p=xn(t).topLeft;o.setAttribute("style","height:"+t.actualSize.height+"px; width:"+t.actualSize.width+"px;left:"+p.x+"px; top:"+p.y+"px;position:absolute;transform:rotate("+(t.rotateAngle+t.parentTransform)+"deg);pointer-events:"+(r?"all":"none")+";visibility:"+(t.visible?"visible":"hidden")+";opacity:"+t.style.opacity+";")},n.prototype.drawNativeContent=function(t,e,i,r,s){var o,a;if(s&&(o=s.getElementById(t.id+"_native_element"),a=s.getElementById(t.id+"_clip")),!o){(o=document.createElementNS("http://www.w3.org/2000/svg","g")).setAttribute("id",t.id+"_native_element"),o.appendChild(t.template.cloneNode(!0));var l=this.createGElement("g",{id:t.id+"_inner_native_element"});l.appendChild(o),e.appendChild(l)}a&&o.removeChild(a),o.setAttribute("style","visibility:"+(t.visible?"visible":"hidden")+";opacity:"+t.style.opacity+";"),this.setNativTransform(t,o,i,r),"Slice"===t.scale&&this.drawClipPath(t,o,i,r,s),ti(o,t.description?{role:"img","aria-label":t.description}:{})},n.prototype.setNativTransform=function(t,e,i,r){var s=0!==t.contentSize.width?t.contentSize.width:1,o=0!==t.contentSize.height?t.contentSize.height:1;e.setAttribute("transform","rotate("+t.parentTransform+","+t.offsetX+","+t.offsetY+") translate("+(t.offsetX-t.templatePosition.x*r/s-r*t.pivot.x)+","+(t.offsetY-t.templatePosition.y*i/o-i*t.pivot.y)+") scale("+r/s+","+i/o+")")},n.prototype.drawClipPath=function(t,e,i,r,s){var o=t.contentSize.width,a=t.contentSize.height,l=t.width/(r/o),h=t.height/(i/a),c=t.templatePosition.x+(t.width>=t.height?0:(o-l)/2),d=t.templatePosition.y+(t.height>=t.width?0:(a-h)/2),u=s.getElementById(t.id+"_clip");(u=document.createElementNS("http://www.w3.org/2000/svg","clipPath")).setAttribute("id",t.id+"_clip"),e.appendChild(u);var f=s.getElementById(t.id+"_clip_rect");return f=document.createElementNS("http://www.w3.org/2000/svg","rect"),u.appendChild(f),ti(f,{id:t.id+"_clip_rect",width:l.toString(),height:h.toString(),x:c.toString(),y:d.toString()}),lm()?e.setAttribute("clip-path","url("+location.protocol+"//"+location.host+location.pathname+"#"+t.id+"_clip)"):e.setAttribute("clip-path","url(#"+t.id+"_clip)"),e},n.prototype.renderGradient=function(t,e,i){var r,s,o,h,c,a=bT(i),l=a.getElementById(i+"gradient_pattern");if(l||(l=Fi("defs",{id:i+"gradient_pattern"}),a.insertBefore(l,a.firstChild)),bF(e.id),"None"!==t.gradient.type){for(var d=0;dt.width&&("Ellipsis"===t.textOverflow||"Clip"===t.textOverflow)&&"NoWrap"===t.textWrapping?0:.5*t.width:"right"===t.textAlign&&(c=1*t.width),s.x=0+c+(e?e.x:0),s.y=1.2+d-r.height/2,s},n}(),Rc=function(){function n(t,e,i){this.renderer=null,this.isSvgMode=!0,this.touchMove=void 0,this.transform={x:0,y:0},this.diagramId=t,this.element=xt(this.diagramId),this.svgRenderer=e,this.isSvgMode=i,this.renderer=i?new ep:new bo}return n.prototype.setCursor=function(t,e){t.style.cursor=e},n.prototype.setLayers=function(){this.iconSvgLayer=this.element.getElementsByClassName("e-ports-expand-layer")[0],this.adornerSvgLayer=this.element.getElementsByClassName("e-adorner-layer")[0],this.nativeSvgLayer=this.element.getElementsByClassName("e-native-layer")[0],this.diagramSvgLayer=this.element.getElementsByClassName("e-diagram-layer")[0]},n.prototype.getAdornerLayer=function(){return ST(this.diagramId)},n.prototype.getParentSvg=function(t,e,i){return this.diagramId&&t&&t.id?t.id.split("_icon_content").length>1||t.id.split("_nodeport").length>1||t.elementActions&Xr.ElementIsPort?this.iconSvgLayer:e&&"selector"===e?this.adornerSvgLayer:t instanceof En?this.nativeSvgLayer:this.diagramSvgLayer:i},n.prototype.getParentElement=function(t,e,i,r){var s=e;if(i&&this.diagramId&&t&&t.id){t.id.split("_icon_content").length>1?(s=i.getElementById(this.diagramId+"_diagramExpander"),e=null):t.id.split("_nodeport").length>1?s=i.getElementById(this.diagramId+"_diagramPorts"):t instanceof En?(s=i.getElementById(this.diagramId+"_nativeLayer"),e=null):t.elementActions&Xr.ElementIsPort?(s=i.getElementById(this.diagramId+"_diagramPorts"),e=null):s=i.getElementById(this.diagramId+"_diagramLayer");var o=this.getGroupElement(t,e||s,r);s=o.g,o.svg&&(i=o.svg)}return{g:s,svg:i}},n.prototype.getGroupElement=function(t,e,i){var r,o,s=this.getParentSvg(t);if(e&&s){if(s&&!(r=s.getElementById(t.id+"_groupElement"))&&s!==this.nativeSvgLayer){var a=this.nativeSvgLayer;r=a.getElementById(t.id+"_groupElement"),o=a}r||(r=this.svgRenderer.createGElement("g",{id:t.id+"_groupElement"}),void 0!==i&&e.childNodes.length>i?e.insertBefore(r,e.childNodes[parseInt(i.toString(),10)]):e.appendChild(r))}return{g:r,svg:o}},n.prototype.renderElement=function(t,e,i,r,s,o,a,l,h,c,d){t instanceof Cs?(t.id=t.id?t.id:Qe(),this.renderContainer(t,e,i,r,s,o,a,l,h,c,d)):t instanceof TI?this.renderImageElement(t,e,r,s,a):t instanceof Ze?this.renderPathElement(t,e,r,s,a,h,d):t instanceof ai?this.renderTextElement(t,e,r,s,a,c):t instanceof En?this.renderNativeElement(t,e,r,s,a):t instanceof es?this.renderHTMLElement(t,e,i,r,s,a,l):this.renderRect(t,e,r,s,h)},n.prototype.drawSelectionRectangle=function(t,e,i,r,s,o){var a={width:i*o.scale,height:r*o.scale,x:.5+(t=(t+o.tx)*o.scale),y:.5+(e=(e+o.ty)*o.scale),fill:"transparent",stroke:"gray",angle:0,pivotX:.5,pivotY:.5,strokeWidth:1,dashArray:"6 3",opacity:1,visible:!0,id:s.id+"_selected_region"},l=this.getAdornerLayer();this.svgRenderer.updateSelectionRegion(l,a)},n.prototype.renderHighlighter=function(t,e,i){var r=t.actualSize.width||2,s=t.actualSize.height||2,o=t.offsetX-r*t.pivot.x,a=t.offsetY-s*t.pivot.y;this.svgRenderer.drawRectangle(e,{width:r*i.scale,height:s*i.scale,x:o=(o+i.tx)*i.scale,y:a=(a+i.ty)*i.scale,fill:"transparent",stroke:"#8CC63F",angle:t.rotateAngle,pivotX:t.pivot.x,pivotY:t.pivot.y,strokeWidth:4,dashArray:"",opacity:1,cornerRadius:0,visible:!0,id:e.id+"_highlighter",class:"e-diagram-highlighter"},this.diagramId,void 0,void 0,e)},n.prototype.renderSelectionRectangle=function(t,e,i,r){var s=t.actualSize.width||2,o=t.actualSize.height||2,a=t.offsetX-s*t.pivot.x,l=t.offsetY-o*t.pivot.y,h={width:s*i.scale,height:o*i.scale,x:a=(a+i.tx)*i.scale,y:l=(l+i.ty)*i.scale,fill:"transparent",stroke:"#00cc00",angle:t.rotateAngle,pivotX:t.pivot.x,pivotY:t.pivot.y,strokeWidth:r?2:1,dashArray:"",opacity:1,cornerRadius:0,visible:!0,id:t.id+"_highlighter",class:r?"e-diagram-first-selection-indicator e-diagram-selection-indicator":"e-diagram-selection-indicator"},c=this.getParentSvg(t,"selector");this.svgRenderer.drawRectangle(e,h,this.diagramId,void 0,void 0,c)},n.prototype.renderSelectionLine=function(t,e,i,r){var s=this.getBaseAttributes(t,i);s.data=t.absolutePath,s.id=s.id+"_highlighter";var o=t.description?t.description:t.id;this.isSvgMode||(s.x=t.flipOffset.x?t.flipOffset.x:s.x,s.y=t.flipOffset.y?t.flipOffset.y:s.y),i&&(s.x=s.x*i.scale,s.y=s.y*i.scale),s.stroke="#00cc00",s.strokeWidth=r?2:1,s.class=r?"e-diagram-first-selection-indicator e-diagram-selection-indicator":"e-diagram-selection-indicator";var a=this.getParentSvg(t,"selector");this.svgRenderer.drawPath(e,s,this.diagramId,void 0,a,o,i.scale)},n.prototype.renderStackHighlighter=function(t,e,i,r,s,o,a){var l=t.actualSize.width||2,h=t.offsetX-l*t.pivot.x,c=t.actualSize.height||2,d=t.offsetY-c*t.pivot.y;h=(h+i.tx)*i.scale;var u,f=t.bounds,p="";if(d=(d+i.ty)*i.scale,r)if(o){var v,y;u="M 0 0 L "+(2+(g=l*i.scale))+" 0 Z",v=t.actualSize.width/Number(f.width?f.width:1)*i.scale,y=t.actualSize.height/Number(f.height?f.height:1)*i.scale,p=wI(CI(Td("M7,4 L8,4 8,7 11,7 11,8 8,8 8,11 7,11 7,8 4,8 4,7 7,7 z M7.5,0.99999994C3.9160004,1 1,3.9160004 0.99999994,7.5 1,11.084 3.9160004,14 7.5,14 11.084,14 14,11.084 14,7.5 14,3.9160004 11.084,1 7.5,0.99999994 z M7.5,0 C11.636002,0 15,3.3639984 15,7.5 15,11.636002 11.636002,15 7.5,15 3.3640003,15 0,11.636002 0,7.5 0,3.3639984 3.3640003,0 7.5,0 z")),v+g+2,y-8,!1,f.x,f.y,0,0),s.y>=t.offsetY&&(d+=c)}else{var g;a&&s.y>=t.offsetY&&(d+=c*i.scale),u="M -10 -10 L 0 0 Z M -10 10 L 0 0 Z M 0 0 L "+(g=l*i.scale)+" 0 Z M "+g+" 0 L "+(g+10)+" 10 Z L "+(g+10)+" -10 Z"}else u="M 10 -10 L 0 0 Z M -10 -10 L 0 0 Z M 0 0 L 0 "+(g=c*i.scale)+" Z M 0 "+g+" L -10 "+(g+10)+" Z L 10 "+(g+10)+" Z",s.x>=t.offsetX&&(h+=l*i.scale);this.svgRenderer.drawPath(e,{data:u+p,width:l*i.scale,height:c*i.scale,x:h,y:d,fill:"transparent",stroke:"#8CC63F",angle:t.rotateAngle,pivotX:t.pivot.x,pivotY:t.pivot.y,strokeWidth:1,dashArray:"",opacity:1,visible:!0,id:e.id+"_stack_highlighter",class:"e-diagram-highlighter"},this.diagramId)},n.prototype.drawLine=function(t,e){this.svgRenderer.drawLine(t,e)},n.prototype.drawPath=function(t,e){this.svgRenderer.drawPath(t,e,this.diagramId)},n.prototype.renderResizeHandle=function(t,e,i,r,s,o,a,l,h,c,d){var u=t.offsetX-t.actualSize.width*t.pivot.x,f=t.offsetY-t.actualSize.height*t.pivot.y,p=t.actualSize.height,g=t.actualSize.width;if(!c&&i&bt.Rotate&&WI(this.rendererActions)&&!z3(this.rendererActions))this.renderPivotLine(t,e,o,s,a),this.renderRotateThumb(t,e,o,s,a);else if(this.touchMove){var v=document.getElementById("rotateThumb");v&&v.setAttribute("visibility","hidden")}this.renderBorder(t,e,o,l,h,c);var y=t.actualSize.width*r,S=t.actualSize.height*r;!h&&WI(this.rendererActions)&&!z3(this.rendererActions)&&(t.isTextAnnotation||(y>=40&&S>=40&&(s&mr.ResizeNorthWest&&this.renderCircularHandle("resizeNorthWest",t,u,f,e,qr(s,"ResizeNorthWest"),i&bt.ResizeNorthWest,o,void 0,a,{"aria-label":"Thumb to resize the selected object on top left side direction"},void 0,"e-diagram-resize-handle e-northwest",d),s&mr.ResizeNorthEast&&this.renderCircularHandle("resizeNorthEast",t,u+g,f,e,qr(s,"ResizeNorthEast"),i&bt.ResizeNorthEast,o,void 0,a,{"aria-label":"Thumb to resize the selected object on top right side direction"},void 0,"e-diagram-resize-handle e-northeast",d),s&mr.ResizeSouthWest&&this.renderCircularHandle("resizeSouthWest",t,u,f+p,e,qr(s,"ResizeSouthWest"),i&bt.ResizeSouthWest,o,void 0,a,{"aria-label":"Thumb to resize the selected object on bottom left side direction"},void 0,"e-diagram-resize-handle e-southwest",d),s&mr.ResizeSouthEast&&this.renderCircularHandle("resizeSouthEast",t,u+g,f+p,e,qr(s,"ResizeSouthEast"),i&bt.ResizeSouthEast,o,void 0,a,{"aria-label":"Thumb to resize the selected object on bottom right side direction"},void 0,"e-diagram-resize-handle e-southeast",d)),s&mr.ResizeNorth&&this.renderCircularHandle("resizeNorth",t,u+g/2,f,e,qr(s,"ResizeNorth"),i&bt.ResizeNorth,o,void 0,a,{"aria-label":"Thumb to resize the selected object on top side direction"},void 0,"e-diagram-resize-handle e-north",d),s&mr.ResizeSouth&&this.renderCircularHandle("resizeSouth",t,u+g/2,f+p,e,qr(s,"ResizeSouth"),i&bt.ResizeSouth,o,void 0,a,{"aria-label":"Thumb to resize the selected object on bottom side direction"},void 0,"e-diagram-resize-handle e-south",d),s&mr.ResizeWest&&this.renderCircularHandle("resizeWest",t,u,f+p/2,e,qr(s,"ResizeWest"),i&bt.ResizeWest,o,void 0,a,{"aria-label":"Thumb to resize the selected object on left side direction"},void 0,"e-diagram-resize-handle e-west",d),s&mr.ResizeEast&&this.renderCircularHandle("resizeEast",t,u+g,f+p/2,e,qr(s,"ResizeEast"),i&bt.ResizeEast,o,void 0,a,{"aria-label":"Thumb to resize the selected object on right side direction"},void 0,"e-diagram-resize-handle e-east",d)))},n.prototype.renderEndPointHandle=function(t,e,i,r,s,o,a,l,h,c){var p,g,d=t.sourcePoint,u=t.targetPoint,f=t.wrapper;if(this.renderCircularHandle("connectorSourceThumb",f,d.x,d.y,e,qr(r,"ConnectorSourceThumb"),i&bt.ConnectorSource,s,o,void 0,{"aria-label":"Thumb to move the source point of the connector"},void 0,"e-diagram-endpoint-handle e-sourceend",c),this.renderCircularHandle("connectorTargetThumb",f,u.x,u.y,e,qr(r,"ConnectorTargetThumb"),i&bt.ConnectorTarget,s,a,void 0,{"aria-label":"Thumb to move the target point of the connector"},void 0,"e-diagram-endpoint-handle e-targetend",c),l)if("Straight"===t.type&&t.segments.length>0)for(p=0;p0)for(p=0;p=3&&3===t.segments.length&&(S=1,b=t.segments.length-1),S=t.segments.length>t.maxSegmentThumb+2?2:S,b=t.segments.length>t.maxSegmentThumb+2?t.segments.length-2:b,1===t.segments.length&&t.segments[0].points.length<=2&&(S=1,b=t.segments.length),p=S;p=50&&i.allowDrag),this.renderOrthogonalThumb(t+"_"+(d+1),e,(i.points[parseInt(d.toString(),10)].x+i.points[d+1].x)/2,(i.points[parseInt(d.toString(),10)].y+i.points[d+1].y)/2,r,h,l,o,a,u)}else for(d=0;d=50&&i.allowDrag),this.renderOrthogonalThumb(t+"_"+(d+1),e,(i.points[parseInt(d.toString(),10)].x+i.points[d+1].x)/2,(i.points[parseInt(d.toString(),10)].y+i.points[d+1].y)/2,r,h,l,o,a,u)},n.prototype.renderOrthogonalThumb=function(t,e,i,r,s,o,a,l,h,c){var d,g,u=0,f=document.getElementById(this.diagramId);f&&(g=f.ej2_instances[0]);var y=h.constraints&qe.InheritSegmentThumbShape?g.segmentThumbShape:h.segmentThumbShape,b=h.constraints&qe.InheritSegmentThumbSize?g.segmentThumbSize:h.segmentThumbSize;if(d="horizontal"===a?function ure(n){return vre[""+n]}(y):c3(y),"Arrow"===y||"DoubleArrow"===y||"OpenArrow"===y)switch(c){case"Bottom":case"Right":u=180;break;default:u=0}else if("Fletch"===y||"OpenFetch"===y||"IndentedArrow"===y||"OutdentedArrow"===y)switch(c){case"Bottom":u=-90;break;case"Top":u=90;break;case"Right":u=180;break;default:u=0}var M={x:(i+l.tx)*l.scale-b/2,y:(r+l.ty)*l.scale-b/2,angle:u,fill:"#e2e2e2",stroke:"black",strokeWidth:1,dashArray:"",data:d,width:b,height:b,pivotX:.5,pivotY:.5,opacity:1,visible:o,id:t,class:"e-diagram-ortho-segment-handle"},w=lp(M.data),C=new me(M.width,M.height),D=new Ze;if(M.data=D.updatePath(M.data,w,C),this.touchMove){var A=document.getElementById(t);A?this.updateSegmentPosition(A,M):this.svgRenderer.drawPath(s,M,this.diagramId)}else this.svgRenderer.drawPath(s,M,this.diagramId)},n.prototype.renderPivotLine=function(t,e,i,r,s){var o=t,l=!!(r&mr.Rotate);s&&(l=!1);var h=this.getBaseAttributes(o,i);h.fill="None",h.stroke="black",h.strokeWidth=1,h.dashArray="2,3",h.visible=l;var c=i.scale;h.x*=c,h.y*=c,h.width*=c,h.height*=c,h.id="pivotLine",h.class="e-diagram-pivot-line";var u={x:o.actualSize.width*o.pivot.x*c,y:0};h.startPoint={x:o.actualSize.width*o.pivot.x*c,y:-20},h.endPoint=u,this.svgRenderer.drawLine(e,h)},n.prototype.renderBezierLine=function(t,e,i,r,s,o){var l=this.getBaseAttributes(e,o);l.id=t,l.stroke="black",l.strokeWidth=1,l.dashArray="3,3",l.fill="None",l.class="e-diagram-bezier-control-line",l.x=0,l.y=0;var h=o.scale,g={x:(s.x+o.tx)*h,y:(s.y+o.ty)*h};l.startPoint={x:(r.x+o.tx)*h,y:(r.y+o.ty)*h},l.endPoint=g,this.svgRenderer.drawLine(i,l)},n.prototype.renderCircularHandle=function(t,e,i,r,s,o,a,l,h,c,d,u,f,p){var g=e,v={x:i,y:r};if(0!==g.rotateAngle||0!==g.parentTransform){var y=Bi();qi(y,g.rotateAngle+g.parentTransform,g.offsetX,g.offsetY),v=Ke(y,v)}var S=this.getBaseAttributes(g);if(S.stroke="black",S.strokeWidth=1,void 0!==u?(S.id="segmentEnd_"+u,S.fill="#e2e2e2"):S.fill=h?"#8CC63F":"white",S.cornerRadius=p/2,S.angle=e.rotateAngle,S.id=t,S.visible=o,S.class=f,S.width=p,S.height=p,S.x=(v.x+l.tx)*l.scale,S.y=(v.y+l.ty)*l.scale,S.x=S.x-S.width/2,S.y=S.y-S.height/2,h&&(S.class+=" e-connected"),c&&(S.visible=!1),this.touchMove){var b=document.getElementById(t);if(b)this.updateResizeHandle(b,S);else{var M=this.getParentSvg(e,"selector");this.svgRenderer.drawRectangle(s,S,this.diagramId,!0,!0,M,d,!0,a)}}else M=this.getParentSvg(e,"selector"),this.svgRenderer.drawRectangle(s,S,this.diagramId,!0,!0,M,d,!0,a)},n.prototype.updateResizeHandle=function(t,e){ti(t,{id:e.id,x:e.x.toString(),y:e.y.toString(),width:e.width.toString(),height:e.height.toString(),visibility:e.visible?"visible":"hidden",transform:"rotate("+e.angle+","+(e.x+e.width/2)+","+(e.y+e.height/2)+")",rx:e.cornerRadius||0,ry:e.cornerRadius||0,opacity:e.opacity})},n.prototype.renderBezierHandle=function(t,e,i,r,s,o,a,l,h,c,d,u,f){var v,p=document.getElementById(this.diagramId);p&&(v=p.ej2_instances[0]);var y=e,S={x:i,y:r};if(0!==y.rotateAngle||0!==y.parentTransform){var b=Bi();qi(b,y.rotateAngle+y.parentTransform,y.offsetX,y.offsetY),S=Ke(b,S)}var D=a.constraints&qe.InheritSegmentThumbSize?v.segmentThumbSize:a.segmentThumbSize,A=c3(a.constraints&qe.InheritSegmentThumbShape?v.segmentThumbShape:a.segmentThumbShape),x=this.getBaseAttributes(y);x.stroke="black",x.strokeWidth=1,void 0!==d?(x.id="segmentEnd_"+d,x.fill="#e2e2e2"):x.fill=h?"#8CC63F":"white",x.angle=e.rotateAngle,x.id=t,x.visible=o,x.class=u,x.width=D,x.height=D,x.data=A,x.x=(S.x+l.tx)*l.scale,x.y=(S.y+l.ty)*l.scale,x.x=x.x-x.width/2,x.y=x.y-x.height/2,h&&(x.class+=" e-connected"),c&&(x.visible=!1);var P=lp(x.data),L=new me(x.width,x.height),O=new Ze;if(x.data=O.updatePath(x.data,P,L),this.touchMove){var N=document.getElementById(t);if(N)this.updateSegmentPosition(N,x);else{var T=this.getParentSvg(e,"selector");this.svgRenderer.drawPath(s,x,this.diagramId,!0,T)}}else T=this.getParentSvg(e,"selector"),this.svgRenderer.drawPath(s,x,this.diagramId,!0,T)},n.prototype.updateSegmentPosition=function(t,e){ti(t,{id:e.id,transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")translate("+e.x+","+e.y+")",visibility:e.visible?"visible":"hidden",opacity:e.opacity})},n.prototype.renderBorder=function(t,e,i,r,s,o){var l=this.getBaseAttributes(t,i);l.x*=i.scale,l.y*=i.scale,l.width*=i.scale,l.height*=i.scale,l.fill="transparent",l.stroke="#097F7F",l.strokeWidth=1.2,l.gradient=null,l.dashArray="6,3",l.class="e-diagram-selector",o&&(l.class+=" e-diagram-lane"),l.id="borderRect",l.id=this.rendererActions&Ga.DrawSelectorBorder?"borderRect_symbol":"borderRect",r||(l.class+=" e-disabled"),s&&(l.class+=" e-thick-border"),l.cornerRadius=0;var h=this.getParentSvg(t,"selector");this.svgRenderer.drawRectangle(e,l,this.diagramId,void 0,!0,h)},n.prototype.renderUserHandler=function(t,e,i,r,s,o){for(var l,a=t.wrapper,h=0,c=t.userHandles;h0||d.disableNodes&&t.nodes.length>0||"Drag"===s&&o)&&(l=!1);var u=document.getElementById(d.name+"_template_hiddenUserHandle");u&&(d.template=u.childNodes[0].cloneNode(!0));var f=rT(t,d,i);if(f.x=(f.x+i.tx)*i.scale,f.y=(f.y+i.ty)*i.scale,d.visible&&(d.visible=!!(t.constraints&mr.UserHandle)),l)if(d.pathData){var p=d.pathData?d.pathData:d.content,g=this.getBaseAttributes(a);g.id=d.name+"_userhandle",g.fill=d.backgroundColor,g.stroke=d.borderColor,g.strokeWidth=d.borderWidth,g.centerX=f.x,g.centerY=f.y,g.radius=.5*d.size,g.class="e-diagram-userhandle-circle",g.angle=0,g.visible=d.visible,g.opacity=1,this.svgRenderer.drawCircle(e,g,1,{"aria-label":d.name+"user handle"});var y=[];y=CI(y=Td(p));var S=lp(p),w=wI(y,(d.size-.45*d.size)/S.width,(d.size-.45*d.size)/S.height,!0,S.x,S.y,0,0);S=lp(w),this.svgRenderer.drawPath(e,C={x:f.x-S.width/2,y:f.y-S.height/2,angle:0,id:"",class:"e-diagram-userhandle-path",fill:d.pathColor,stroke:d.backgroundColor,strokeWidth:.5,dashArray:"",data:w,width:d.size-5,height:d.size-5,pivotX:0,pivotY:0,opacity:1,visible:d.visible},this.diagramId,void 0,void 0,{"aria-label":d.name+"user handle"})}else if(d.content){var D=new En(d.name,this.diagramId);D.content=d.content,D.offsetX=f.x,D.offsetY=f.y,D.id=d.name+"_shape",D.horizontalAlignment="Center",D.verticalAlignment="Center",D.visible=d.visible,D.setOffsetWithRespectToBounds(f.x,f.y,"Fraction"),D.relativeMode="Object",D.description=d.name||"User handle",D.measure(new me(d.size,d.size)),D.arrange(D.desiredSize),this.svgRenderer.drawNativeContent(D,e,d.size,d.size,this.adornerSvgLayer)}else if(d.source){var C,A=new TI;(C=this.getBaseAttributes(A,i)).width=d.size,C.height=d.size,C.x=f.x-d.size/2,C.y=f.y-d.size/2,C.sourceWidth=d.size,C.sourceHeight=d.size,C.alignment=A.imageAlign,C.source=d.source,C.scale=A.imageScale,C.visible=d.visible,C.description=d.name||"User handle",C.id=d.name+"_",this.renderer.drawImage(e,C,this.adornerSvgLayer,!1)}else{var x=new es(d.name,this.diagramId);x.offsetX=f.x,x.offsetY=f.y,x.id=d.name+"_shape",x.visible=d.visible,x.relativeMode="Object",x.template=d.template,x.measure(new me(d.size,d.size)),x.arrange(x.desiredSize),this.svgRenderer.drawHTMLContent(x,r,void 0,!0,void 0)}}},n.prototype.renderRotateThumb=function(t,e,i,r,s){new Ze;var a,l=new me;l.width=18,l.height=16;var d=!!(r&mr.Rotate);s&&(d=!1);var f=t.offsetX-t.actualSize.width*t.pivot.x+t.pivot.x*t.actualSize.width,p=t.offsetY-t.actualSize.height*t.pivot.y;if(a={x:(f=(f+i.tx)*i.scale)-.5*l.width,y:(p=(p+i.ty)*i.scale)-30-.5*l.height},0!==t.rotateAngle||0!==t.parentTransform){var g=Bi();qi(g,t.rotateAngle+t.parentTransform,(i.tx+t.offsetX)*i.scale,(i.ty+t.offsetY)*i.scale),a=Ke(g,a)}var v={x:a.x,y:a.y,angle:t.rotateAngle+t.parentTransform,fill:"#231f20",stroke:"black",strokeWidth:.5,dashArray:"",data:"M 16.856144362449648 10.238890446662904 L 18.000144362449646 3.437890446662903L 15.811144362449646 4.254890446662903 C 14.837144362449646 2.5608904466629028 13.329144362449647 1.2598904466629026 11.485144362449645 0.5588904466629026 C 9.375144362449646 - 0.24510955333709716 7.071144362449646 - 0.18010955333709716 5.010144362449646 0.7438904466629028 C 2.942144362449646 1.6678904466629028 1.365144362449646 3.341890446662903 0.558144362449646 5.452890446662903 C - 0.244855637550354 7.567890446662903 - 0.17985563755035394 9.866890446662904 0.7431443624496461 11.930890446662904 C 1.6681443624496461 13.994890446662904 3.343144362449646 15.575890446662903 5.457144362449647 16.380890446662903 C 6.426144362449647 16.7518904466629 7.450144362449647 16.9348904466629 8.470144362449647 16.9348904466629 C 9.815144362449647 16.9348904466629 11.155144362449647 16.6178904466629 12.367144362449647 15.986890446662901 L 11.351144362449647 14.024890446662901 C 9.767144362449647 14.8468904466629 7.906144362449647 14.953890446662902 6.237144362449647 14.3178904466629 C 4.677144362449647 13.7218904466629 3.444144362449647 12.5558904466629 2.758144362449647 11.028890446662901 C 2.078144362449646 9.501890446662903 2.031144362449646 7.802890446662903 2.622144362449646 6.243890446662903 C 3.216144362449646 4.6798904466629025 4.387144362449646 3.442890446662903 5.914144362449646 2.760890446662903 C 7.437144362449646 2.078890446662903 9.137144362449646 2.0298904466629026 10.700144362449645 2.6258904466629027 C 11.946144362449646 3.100890446662903 12.971144362449646 3.9538904466629026 13.686144362449646 5.049890446662903 L 11.540144362449645 5.850890446662903 L 16.856144362449648 10.238890446662904 Z",width:20,height:20,pivotX:0,pivotY:0,opacity:1,visible:d,id:"rotateThumb",class:"e-diagram-rotate-handle"};if(this.touchMove){var y=document.getElementById("rotateThumb");y?this.updateSegmentPosition(y,v):this.svgRenderer.drawPath(e,v,this.diagramId,!0,void 0,{"aria-label":"Thumb to rotate the selected object"})}else this.svgRenderer.drawPath(e,v,this.diagramId,!0,void 0,{"aria-label":"Thumb to rotate the selected object"})},n.prototype.renderPathElement=function(t,e,i,r,s,o,a){var l=this.getBaseAttributes(t,i,o);if(l.data=t.absolutePath,l.data=t.absolutePath,t.isPathPort&&a){l.x=a[t.id]?a[t.id].cx:l.x,l.y=a[t.id]?a[t.id].cy:l.y,t.bounds.x=l.x,t.bounds.y=l.y;var h=document.getElementById(this.diagramId);h&&"PortDrag"!==h.ej2_instances[0].eventHandler.currentAction&&(t.offsetX=l.x+t.width/2,t.offsetY=l.y+t.height/2)}var u=t.description?t.description:t.id;if(this.isSvgMode||(l.x=t.flipOffset.x?t.flipOffset.x:l.x,l.y=t.flipOffset.y?t.flipOffset.y:l.y),t.isExport){var f=t.absoluteBounds,p=Td(l.data),g=this.findAndStoreArcValues(p);l.arc=g,l.data=BF(t,f,0,l)}this.renderer.drawPath(e,l,this.diagramId,void 0,r,u)},n.prototype.findAndStoreArcValues=function(t){var e=[];return t.forEach(function(i){"A"===i.command&&e.push({r1:i.r1/2,r2:i.r2/2})}),e},n.prototype.renderSvgGridlines=function(t,e,i,r,s,o){var a=document.createElementNS("http://www.w3.org/2000/svg","pattern"),l=document.createElementNS("http://www.w3.org/2000/svg","defs");l.setAttribute("id",this.diagramId+"_grid_pattern_defn"),(t.constraints&Kt.ShowHorizontalLines||t.constraints&Kt.ShowVerticalLines)&&a.setAttribute("id",this.diagramId+"_pattern");var h=0,c=0,d=0,u=0,f=1,p=!1,g="Lines"===t.gridType,v=g?t.verticalGridlines.lineIntervals:t.verticalGridlines.dotIntervals,y=g?t.horizontalGridlines.lineIntervals:t.horizontalGridlines.dotIntervals;if(r.showRulers&&r.dynamicGrid&&s&&o)d=o.updateSegmentWidth(i.scale),u=s.updateSegmentWidth(i.scale),t.horizontalGridlines.scaledIntervals=[d/s.interval],t.verticalGridlines.scaledIntervals=[u/o.interval],p=!0;else{for(var S=0;S=2)for(;e>=2;)e/=2;else if(e<=.5)for(;e<=.5;)e*=2;var i;if(t.horizontalGridlines.scaledIntervals=t.horizontalGridlines.snapIntervals,t.verticalGridlines.scaledIntervals=t.verticalGridlines.snapIntervals,1!==e){var r=t.horizontalGridlines;for(r.scaledIntervals=[],i=0;ithis.groupElement.actualSize.height&&("Clip"===t.style.textOverflow||"Ellipsis"===t.style.textOverflow)&&(a.y=a.y+(a.height-this.groupElement.actualSize.height)/2),this.renderer.drawRectangle(e,a,this.diagramId,void 0,void 0,r),this.renderer.drawText(e,a,r,l,this.diagramId,t.isExport&&Math.min(t.exportScaleValue.x||t.exportScaleValue.y),this.groupElement),this.isSvgMode&&(t.doWrap=!1)},n.prototype.renderNativeElement=function(t,e,i,r,s){var o,a,l=this.getParentSvg(t,void 0,e)||r,h=this.getParentElement(t,e,l).g||e,c=this.getBaseAttributes(t,i);switch(c.fill="transparent",c.cornerRadius=t.cornerRadius,c.stroke="transparent",this.renderer.drawRectangle(e,c,this.diagramId,void 0,void 0,r),t.scale){case"None":o=t.contentSize.width,a=t.contentSize.height;break;case"Stretch":o=t.actualSize.width,a=t.actualSize.height;break;case"Meet":o=a=t.actualSize.width<=t.actualSize.height?t.actualSize.width:t.actualSize.height;break;case"Slice":o=a=t.actualSize.width>=t.actualSize.height?t.actualSize.width:t.actualSize.height}this.svgRenderer&&this.svgRenderer.drawNativeContent(t,h,a,o,l)},n.prototype.renderHTMLElement=function(t,e,i,r,s,o,a){var l=this.getBaseAttributes(t,r);l.fill="transparent",l.cornerRadius=t.cornerRadius,l.stroke="transparent",this.renderer.drawRectangle(e,l,this.diagramId,void 0,void 0,s),this.svgRenderer&&this.svgRenderer.drawHTMLContent(t,i.children[0],r,function Sse(n){var t=n.parentElement;do{if(gm(t,"e-diagram"))return!0;t=t.parentElement}while(t);return!1}(i),a)},n.prototype.renderImageElement=function(t,e,i,r,s){var o=this.getBaseAttributes(t,i);o.cornerRadius=0,this.renderer.drawRectangle(e,o,this.diagramId,void 0,void 0,r);var a,l,h,c,g,d=t.contentSize.width,u=t.contentSize.height,f=o.width/d,p=o.height/u;if("Stretch"===t.stretch)a=d*(g=Math.min(f,p)),l=u*g;else switch(t.stretch){case"Meet":a=d*(g=Math.min(f,p)),l=u*g,o.x+=Math.abs(o.width-a)/2,o.y+=Math.abs(o.height-l)/2;break;case"Slice":g=Math.max(f,p),h=o.width/(a=d*g)*d,c=o.height/(l=u*g)*u;break;case"None":a=d,l=u}o.width=a,o.height=l,o.sourceWidth=h,o.sourceHeight=c,o.source=t.source,o.alignment=t.imageAlign,o.scale=t.imageScale,o.description=t.description?t.description:t.id,this.renderer.drawImage(e,o,r,s)},n.prototype.renderContainer=function(t,e,i,r,s,o,a,l,h,c,d){var g,u={svg:s,g:e},f=document.getElementById(this.diagramId);if(f&&(g=f.ej2_instances[0]),this.diagramId&&(s=this.getParentSvg(t)||s,this.isSvgMode)){var v=this.getParentElement(t,e,s,l).g||e;s=this.getParentSvg(this.hasNativeParent(t.children))||s;var y=this.getParentElement(this.hasNativeParent(t.children),v,s,l);u.svg=y.svg||s,u.g=y.g||v,o&&s&&(s.getElementById(u.g.id)||e.appendChild(u.g)),e=u.g}if(this.renderRect(t,e,r,s),this.groupElement=t,t.hasChildren()){for(var b,S=void 0,M=0,w=t.children;M0&&(D=g.selectedItems.nodes[0]);var L,A=void 0,x=void 0,P=!1;if(g&&g.selectedItems&&(L=g.getObject(t.id)),"None"!==t.flip&&(D=L),"None"===t.flip&&(D=L),D&&D.flipMode&&(P=!0),!(t.elementActions&Xr.ElementIsGroup)&&g instanceof _l&&g.nameTable[t.id]&&"connectors"!==g.nameTable[t.id].propName&&P&&D){if(A=t.children&&t.children[0]instanceof En?document.getElementById(D.id+"_content_inner_native_element"):document.getElementById(D.id+"_content_groupElement"),!(t.children[0]instanceof En)&&"Text"!==D.shape.type&&"None"!==D.flipMode&&"Label"!==D.flipMode&&"All"!==D.flipMode&&"PortAndLabel"!==D.flipMode&&"LabelText"!==D.flipMode&&"PortAndLabelText"!==D.flipMode&&"LabelAndLabelText"!==D.flipMode||t.children[0]instanceof En&&"Port"===D.flipMode)return void this.renderFlipElement(t,A,D.flip);if((t.children[0]instanceof En&&("All"===D.flipMode||"Label"===D.flipMode)||"Label"===D.flipMode||"PortAndLabel"===D.flipMode||"LabelText"===D.flipMode||"PortAndLabelText"===D.flipMode||"LabelAndLabelText"===D.flipMode||"Image"===D.shape.type&&"Label"===D.flipMode)&&this.renderFlipElement(t,A,t.flip),"None"!==t.flip&&"None"===D.flipMode)this.renderFlipElement(t,A,t.flip);else if("None"!==t.flip&&("Label"===D.flipMode||"PortAndLabel"===D.flipMode||"LabelText"===D.flipMode||"PortAndLabelText"===D.flipMode||"LabelAndLabelText"===D.flipMode)||t.children[0]instanceof En&&"None"!==t.flip&&D&&("None"===D.flipMode||"All"===D.flipMode)){for(var O=0;O0){var i=t[0];if(i instanceof En)return i;i.children&&i.children.length&&this.hasNativeParent(i.children,e++||0)}},n.prototype.renderRect=function(t,e,i,r,s){var o=this.getBaseAttributes(t,i,s);o.cornerRadius=t.cornerRadius||0,t.isExport&&(o.cornerRadius*=t.exportScaleValue.x),this.renderer.drawRectangle(e,o,this.diagramId,t.isExport,void 0,r,t.description?t.description:t.id)},n.prototype.drawRect=function(t,e){e.cornerRadius=0,this.svgRenderer.drawRectangle(t,e,this.diagramId)},n.prototype.getBaseAttributes=function(t,e,i){var r={width:t.actualSize.width,height:t.actualSize.height,x:t.offsetX-t.actualSize.width*t.pivot.x,y:t.offsetY-t.actualSize.height*t.pivot.y,fill:t.style.fill,stroke:t.style.strokeColor,angle:t.rotateAngle+t.parentTransform,pivotX:t.pivot.x,pivotY:t.pivot.y,strokeWidth:t.style.strokeWidth,dashArray:t.style.strokeDashArray||"",opacity:t.style.opacity,shadow:t.shadow,gradient:t.style.gradient,visible:t.visible,id:t.id,description:t.description,canApplyStyle:t.canApplyStyle,shapeType:t.shapeType};return"Page"===t.rotationReference&&(r.angle=t.rotateAngle),i&&(r.x=r.x-.5,r.y=r.y-.5),t.isExport&&(r.width*=t.exportScaleValue.x,r.height*=t.exportScaleValue.y,r.x*=t.exportScaleValue.x,r.y*=t.exportScaleValue.y,r.strokeWidth*=t.exportScaleValue.x),t.flip&&(r.flip=t.flip),e&&(r.x+=e.tx,r.y+=e.ty),r},n.renderSvgBackGroundImage=function(t,e,i,r,s,o){if(t.source){var l=bT(e.id).getElementById(e.id+"_image");if(!l){var h=function Toe(n){return xt(n).getElementsByClassName("e-background-image-layer")[0]}(e.id);(l=document.createElementNS("http://www.w3.org/2000/svg","image")).setAttribute("id",e.id+"_image"),h.appendChild(l)}var c=new Image;c.src=t.source,l.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",c.src.toString());var d="None"!==t.scale?t.scale:"",u=t.align,f=u.charAt(0).toLowerCase()+u.slice(1);d&&(f+=" "+d.charAt(0).toLowerCase()+d.slice(1)),ti(l,{id:e.id+"_image",x:i,y:r,width:s,height:o,preserveAspectRatio:f})}},n.prototype.transformLayers=function(t,e){var i=t.tx*t.scale,r=t.ty*t.scale,s="domTable";if(i!==this.transform.x||r!==this.transform.y||0===i||0===r){e&&(window[""+s][this.diagramId+"_diagramLayer"]||(window[""+s][this.diagramId+"_diagramLayer"]=this.diagramSvgLayer.getElementById(this.diagramId+"_diagramLayer")),window[""+s][this.diagramId+"_diagramLayer"].setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+"),scale("+t.scale+")"));var a=function Aoe(n){var t="domTable",e=null;return window[t][n+"_gridline"]?e=window[t][n+"_gridline"]:(e=jd(n).getElementById(n+"_gridline"),window[t][n+"_gridline"]=e),e}(this.diagramId);return a.setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+")"),window[""+s][this.diagramId+"_diagramPorts"]||(window[""+s][this.diagramId+"_diagramPorts"]=this.iconSvgLayer.getElementById(this.diagramId+"_diagramPorts")),window[""+s][this.diagramId+"_diagramPorts"].setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+"),scale("+t.scale+")"),window[""+s][this.diagramId+"_diagramExpander"]||(window[""+s][this.diagramId+"_diagramExpander"]=this.iconSvgLayer.getElementById(this.diagramId+"_diagramExpander")),window[""+s][this.diagramId+"_diagramExpander"].setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+"),scale("+t.scale+")"),window[""+s][this.diagramId+"_nativeLayer"]||(window[""+s][this.diagramId+"_nativeLayer"]=this.nativeSvgLayer.getElementById(this.diagramId+"_nativeLayer")),window[""+s][this.diagramId+"_nativeLayer"].setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+"),scale("+t.scale+")"),Io(this.diagramId).children[0].style.transform="translate("+t.tx*t.scale+"px,"+t.ty*t.scale+"px)scale("+t.scale+")",this.transform={x:t.tx*t.scale,y:t.ty*t.scale},!0}return!1},n.prototype.updateNode=function(t,e,i,r,s,o,a){this.renderElement(t,e,i,r,this.getParentSvg(t),void 0,void 0,s,null,o,a)},n}(),use=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),nb=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},uF=function(n){function t(e,i){var r=n.call(this,e,i)||this;return r.mode="Canvas",r.id="overview",r.actionName="",r.startPoint=null,r.currentPoint=null,r.prevPoint=null,r.scale=null,r.inAction=!1,r.viewPortRatio=1,r.horizontalOffset=0,r.verticalOffset=0,r.model={},r.event=!0,r.overviewid=88123,r.model={width:r.width,height:r.height},r}return use(t,n),t.prototype.onPropertyChanged=function(e,i){for(var r=0,s=Object.keys(e);r0||e.toString().indexOf("%")>0?e.toString():e.toString()+"px"},t.prototype.renderCanvas=function(e){var i=document.getElementById(this.element.id+"_canvas");i||(i=Tt("div",{}),this.element.appendChild(i)),Ho(i,{id:this.element.id+"_canvas",class:"drawing",style:"position:relative; height:"+this.getSizeValue(this.model.height)+"; width:"+this.getSizeValue(this.model.width)+";style:-ms-touch-action: none;touch-action: none;"}),this.element.setAttribute("tabindex",String(-1)),this.element.style.overflow="hidden",this.element.style.height=String(this.model.height),this.element.style.width=String(this.model.width),this.canvas=i},t.prototype.setParent=function(e){var i=document.getElementById(e);if(this.parent){var s=this.parent;this.parent=null,s.setOverview(null,this.element.id),this.removeDocument(this)}this.parent=this.getDiagram(i,"ej2_instances"),this.parent&&this.parent.setOverview(this)},t.prototype.getDiagram=function(e,i){for(var r,s=e[""+i].length,o=0;o0?f:Math.floor(window.innerWidth)}if(0===h){var p=Math.floor(window.innerHeight-u-Math.floor(c.top));h=p>0?p:Math.floor(window.innerHeight)}l>0&&(s.setAttribute("width",String(l)),this.model.height=h),h>0&&(s.setAttribute("height",String(h)),this.model.width=l),e.diagramLayerDiv||(e.diagramLayerDiv=Tt("div",{}),e.diagramLayer=bo.createCanvas(this.element.id+"_diagramLayer",this.model.width,this.model.height),e.diagramLayer.setAttribute("style","position:absolute; left:0px; top:0px "),e.diagramLayerDiv.appendChild(e.diagramLayer),e.canvas.appendChild(e.diagramLayerDiv)),Ho(e.diagramLayerDiv,{id:this.element.id+"_diagramLayer_div",style:"width:"+this.model.width+"px; height:"+this.model.height+"px;position:absolute;top:0px;left:0px"}),this.renderHtmlLayer(e.canvas),this.renderNativeLayer(e.canvas,e),this.addOverviewRectPanel(e)},t.prototype.removeDocument=function(e){var i=document.getElementById(this.canvas.id+"_svg");this.canvas.removeChild(i);var r=document.getElementById(this.element.id+"_htmlLayer");this.canvas.removeChild(r);var s=document.getElementById(this.element.id+"_diagramLayer_div");this.canvas.removeChild(s),e.diagramLayerDiv=null,e.diagramLayer=null,window.domTable[this.id+"html_layer"]=null},t.prototype.renderHtmlLayer=function(e){var i=Tt("div",{id:this.element.id+"_htmlLayer",class:"e-html-layer",style:"pointer-events:none;position:absolute;top:0px;left:0px;"}),s=Tt("div",{id:this.element.id+"_htmlLayer_div",style:"position:absolute;top:0px;left:0px;"});return i.appendChild(s),e.appendChild(i),i},t.prototype.renderNativeLayer=function(e,i){if(!document.getElementById(this.element.id+"_nativeLayer_svg")){var r=this.parent.createSvg(this.element.id+"_nativeLayer_svg",this.model.width,this.model.height),s=Fi("g",{id:this.element.id+"_nativeLayer"});r.appendChild(s),i.diagramLayerDiv.appendChild(r),ti(r,{class:"e-native-layer"})}},t.prototype.addOverviewRectPanel=function(e){var i=document.getElementById(this.canvas.id+"_overviewsvg");i&&i.parentNode.removeChild(i),i=Fi("svg",{id:this.canvas.id+"_overviewsvg",class:"overviewsvg",version:"1.1",style:"position:absolute;left:0px;top:0px; aria-label:Specifies overview",width:this.model.width,height:this.model.height}),e.canvas.appendChild(i);var s=Fi("g",{id:this.element.id+"_overviewlayer",style:"pointer-events:none"});i.appendChild(s);var o=Fi("rect",{fill:"transparent",width:"100%",height:"100%",class:"overviewbackrect",id:this.canvas.id+"overviewbackrect"});o.setAttribute("style"," pointer-events: none; "),s.appendChild(o);var a=Fi("g",{id:this.canvas.id+"overviewhandle",style:"pointer-events:all"});s.appendChild(a);var l=Fi("rect",{id:this.canvas.id+"overviewrect",fill:"transparent"});a.appendChild(l),this.renderOverviewCorner("left",a),this.renderOverviewCorner("right",a),this.renderOverviewCorner("top",a),this.renderOverviewCorner("bottom",a),this.renderOverviewCorner("topleft",a),this.renderOverviewCorner("topright",a),this.renderOverviewCorner("bottomleft",a),this.renderOverviewCorner("bottomright",a)},t.prototype.renderOverviewCorner=function(e,i){var s,o=Fi(s="top"===e||"bottom"===e||"right"===e||"left"===e?"rect":"circle",{id:this.canvas.id+"visible"+e,class:"overview-resizer"});i.appendChild(o);var a=Fi(s,{id:this.canvas.id+e,class:"overviewresizer",fill:"transparent"});i.appendChild(a)},t.prototype.updateOverviewRectangle=function(){var e=this.currentPoint.x-this.prevPoint.x,i=this.currentPoint.y-this.prevPoint.y,r=new me;r.width=0,r.height=0;var s=0,o=0;switch(this.resizeDirection){case"left":r.width-=e,r.height-=e/this.viewPortRatio,s=e,o=e/this.viewPortRatio,o/=2;break;case"right":r.width+=e,r.height+=e/this.viewPortRatio,o=e/this.viewPortRatio,o/=-2;break;case"top":r.height-=i,r.width-=i*this.viewPortRatio,o=i,s=i*this.viewPortRatio,s/=2;break;case"bottom":r.height+=i,r.width+=i*this.viewPortRatio,s=i*this.viewPortRatio,s/=-2;break;case"topleft":Math.abs(i)>Math.abs(e)?e=i*this.viewPortRatio:i=e/this.viewPortRatio,r.width-=e,r.height-=i,s=e,o=i;break;case"topright":Math.abs(i)>Math.abs(e)?e=-i*this.viewPortRatio:i=-e/this.viewPortRatio,o=i,r.width+=e,r.height-=i;break;case"bottomleft":Math.abs(i)>Math.abs(e)?e=-i*this.viewPortRatio:i=-e/this.viewPortRatio,s=e,r.width-=e,r.height+=i;break;case"bottomright":Math.abs(i)>Math.abs(e)?e=i*this.viewPortRatio:i=e/this.viewPortRatio,r.width+=e,r.height+=i}this.updateHelper(s,o,r,void 0,void 0)},t.prototype.updateHelper=function(e,i,r,s,o){var a,l,h,u,f,d=this.element.getElementsByTagName("svg")[2].getElementById("helper");r?(a=(h=d.getBBox()).x+e,l=h.y+i,s=h.width+r.width,o=h.height+r.height):(u=this.currentPoint.x>this.startPoint.x?this.currentPoint.x-this.prevPoint.x:this.prevPoint.x-this.currentPoint.x,f=this.currentPoint.y>this.startPoint.y?this.currentPoint.y-this.prevPoint.y:this.prevPoint.y-this.currentPoint.y,Math.abs(f)>Math.abs(u)?u=this.viewPortRatio*f:f=u/this.viewPortRatio,h=d.getBBox(),a=this.startPoint.x>this.currentPoint.x?h.x-u:h.x,l=this.startPoint.y>this.currentPoint.y?h.y-f:h.y,s=h.width+u,o=h.height+f),ti(this.helper,{id:this.helper.id,x:a,y:l,width:Math.max(0,s),height:Math.max(0,o)})},t.prototype.updateOverviewrect=function(e,i,r,s){Ho(document.getElementById(this.canvas.id+"overviewrect"),{x:e,y:i,width:Math.max(1,r),height:Math.max(1,s)}),this.updateOverviewCorner("top",e+8,i+1,Math.max(0,r-16),2),this.updateOverviewCorner("bottom",e+8,i+s+3,Math.max(0,r-16),2),this.updateOverviewCorner("left",e-2,i+11,2,Math.max(0,s-16)),this.updateOverviewCorner("right",e+r,i+11,2,Math.max(0,s-16)),this.updateOverviewCorner("topleft",e,i+3,5,5),this.updateOverviewCorner("topright",e+r,i+3,5,5),this.updateOverviewCorner("bottomleft",e,i+s+3,5,5),this.updateOverviewCorner("bottomright",e+r,i+s+3,5,5)},t.prototype.updateOverviewCorner=function(e,i,r,s,o){var a,l;"top"===e||"bottom"===e||"right"===e||"left"===e?(a={x:i,y:r,width:s,height:o,fill:"#ED1C24"},l={x:i-2,y:r-2,width:2===s?4:s,height:2===o?4:o}):(a={cx:i,cy:r,r:4,fill:"#ED1C24"},l={cx:i,cy:r,r:6,fill:"transparent"}),Ho(document.getElementById(this.canvas.id+"visible"+e),a),Ho(document.getElementById(this.canvas.id+e),l)},t.prototype.translateOverviewRectangle=function(){Number(this.model.width),Number(this.model.height);var r=this.currentPoint.x-this.prevPoint.x,s=this.currentPoint.y-this.prevPoint.y,l=this.element.getElementsByClassName("overviewsvg")[0].getElementById(this.canvas.id+"overviewrect").getBBox(),h=l.x+r,c=l.y+s,d=l.width,u=l.height;this.updateOverviewrect(h,c,d,u),this.updateParentView(this.parent.scroller.currentZoom,h,c,d,u,null)},t.prototype.renderOverviewRect=function(e,i,r,s){var o=Number(this.model.width),a=Number(this.model.height),c=Math.max(this.parent.scroller.viewPortWidth/(r/o*this.contentWidth),this.parent.scroller.viewPortHeight/(s/a*this.contentHeight));if(c>=.25&&c<=30){this.updateParentView(c,e,i,r,s,{x:0,y:0});var u=this.scrollOverviewRect(this.parent.scroller.horizontalOffset,this.parent.scroller.verticalOffset,this.parent.scroller.currentZoom,!0);if(this.helper){var p=this.element.getElementsByTagName("rect")[10].getBBox();u.x=p.x,u.y=p.y}"pan"===this.actionName?this.updateOverviewrect(-u.x,-u.y,u.width,u.height):this.updateOverviewrect(u.x,u.y,u.width,u.height)}},t.prototype.scrollOverviewRect=function(e,i,r,s){if(!this.actionName||s){var o=Number(this.model.width),a=Number(this.model.height),l=Math.min(this.contentWidth/o,this.contentHeight/a),h=new Ne,c=h.x=e/r/l,d=h.y=i/r/l,u=0;this.parent.rulerSettings.showRulers&&(u=25);var f=document.getElementById(this.parent.element.id+"content"),p=0,g=0;f&&(p=f.offsetWidth-f.clientWidth,g=f.offsetHeight-f.clientHeight);var v=h.width=(this.parent.scroller.viewPortWidth-u-p)/r/l,y=h.height=(this.parent.scroller.viewPortHeight-u-g)/r/l;if(s){var S=new Ne;return S.x=c,S.y=d,S.width=v,S.height=y,S}this.updateOverviewrect(-c,-d,v,y)}return null},t.prototype.updateParentView=function(e,i,r,s,o,a){var p,g,l=Number(this.model.width),h=Number(this.model.height),u=i*(this.contentWidth/l)*e,f=r*(this.contentHeight/h)*e;this.parent.scroller.getPageBounds(),(1!==e||"pan"===this.actionName)&&(p=-u-this.parent.scroller.horizontalOffset,g=-f-this.parent.scroller.verticalOffset),this.parent.setBlazorDiagramProps(!0),this.parent.realActions|=$i.OverViewAction,"scale"===this.actionName||"draw"===this.actionName?this.parent.scroller.zoom(e/this.parent.scroller.currentZoom,p,g,a):ce()?this.parent.scroller.zoom(1,p,g,a):this.parent.pan(p,g,a,!0)},t.prototype.updateHtmlLayer=function(e){var i=Io(e.element.id),r=this.parent.scroller.getPageBounds(!0),o=r.height,a=Math.max(r.width,this.parent.scroller.viewPortWidth),l=Math.max(o,this.parent.scroller.viewPortHeight/this.parent.scroller.currentZoom),h=Math.min(Number(this.model.width)/a,Number(this.model.height)/l);i.style.transform="scale("+h+") translate("+this.parent.scroller.transform.tx+"px,"+this.parent.scroller.transform.ty+"px)"},t.prototype.updateView=function(e){var i=this.parent.scroller.getPageBounds(),r=i.width,s=i.height,o=Number(this.model.width),a=Number(this.model.height),l=Math.max(r,this.parent.scroller.viewPortWidth),h=Math.max(s,this.parent.scroller.viewPortHeight);this.contentWidth=l=Math.max(l,o/a*h),this.contentHeight=h=Math.max(h,a/o*l);var c=Math.min(o/l,a/h),d=document.getElementById(this.element.id+"_htmlLayer");d.style.webkitTransform="scale("+c+") translate("+-i.x+"px,"+-i.y+"px)",d.style.transform="scale("+c+") translate("+-i.x+"px,"+-i.y+"px)",document.getElementById(this.element.id+"_overviewlayer").setAttribute("transform","translate("+-i.x*c+","+-i.y*c+")"),this.horizontalOffset=i.x*c,this.verticalOffset=i.y*c;var f=document.getElementById(this.element.id+"_diagramLayer"),p=UF(this.element.id),g=f.getContext("2d"),v=Number(this.model.width)/this.contentWidth,y=Number(this.model.height)/this.contentHeight;v=Math.min(v,y);var S=this.parent.scroller.transform;p.setAttribute("transform","translate("+S.tx*v+","+S.ty*y+"),scale("+v+")"),g.setTransform(v,0,0,v,0,0),g.fillStyle="red",this.scrollOverviewRect(this.parent.scroller.horizontalOffset,this.parent.scroller.verticalOffset,this.parent.scroller.currentZoom)},t.prototype.scrolled=function(e){if(this.event){var i=this.scrollOverviewRect(this.parent.scroller.horizontalOffset,this.parent.scroller.verticalOffset,this.parent.scroller.currentZoom,!0);this.updateOverviewrect(-i.x,-i.y,i.width,i.height),this.updateView(this)}},t.prototype.updateCursor=function(e){if(gm(e.target,"overviewresizer"))switch(e.target.id){case this.canvas.id+"left":this.canvas.style.cursor="w-resize";break;case this.canvas.id+"right":this.canvas.style.cursor="e-resize";break;case this.canvas.id+"top":this.canvas.style.cursor="n-resize";break;case this.canvas.id+"bottom":this.canvas.style.cursor="s-resize";break;case this.canvas.id+"topleft":this.canvas.style.cursor="nw-resize";break;case this.canvas.id+"topright":this.canvas.style.cursor="ne-resize";break;case this.canvas.id+"bottomleft":this.canvas.style.cursor="sw-resize";break;case this.canvas.id+"bottomright":this.canvas.style.cursor="se-resize"}else this.canvas.style.cursor="default"},t.prototype.mouseMove=function(e){if(this.event=!1,this.updateCursor(e),this.currentPoint=this.mousePosition(e),this.actionName)switch(this.actionName){case"draw":!this.inAction&&(this.startPoint.x!==this.currentPoint.x||this.startPoint.y!==this.currentPoint.y)&&(this.initHelper(),this.inAction=!0),this.inAction&&this.updateHelper();break;case"scale":this.inAction||(this.initHelper(),this.inAction=!0),this.updateOverviewRectangle();break;case"pan":(this.startPoint.x!==this.currentPoint.x||this.startPoint.y===this.currentPoint.y||this.inAction)&&(this.inAction=!0,this.translateOverviewRectangle())}this.prevPoint=this.currentPoint},t.prototype.documentMouseUp=function(e){this.inAction=!1,this.actionName="",this.helper&&(this.helper.parentNode.removeChild(this.helper),this.helper=null),this.event=!0,document.getElementById(this.canvas.id+"overviewhandle").style.pointerEvents="all"},t.prototype.windowResize=function(e){var i=this;return this.resizeTo&&clearTimeout(this.resizeTo),this.resizeTo=setTimeout(function(){var s=document.getElementById(i.element.id).getBoundingClientRect();i.model.width=s.width>0?s.width:i.model.width,i.model.height=s.height>0?s.height:i.model.height,i.renderCanvas(),i.setParent(i.sourceID)},10),!1},t.prototype.mouseDown=function(e){if(e.target.id===this.canvas.id+"_overviewsvg"&&(this.actionName="draw"),e.target.id===this.canvas.id+"overviewrect"&&(this.actionName="pan"),gm(e.target,"overviewresizer"))switch(this.actionName="scale",e.target.id){case this.canvas.id+"left":this.resizeDirection="left";break;case this.canvas.id+"right":this.resizeDirection="right";break;case this.canvas.id+"top":this.resizeDirection="top";break;case this.canvas.id+"bottom":this.resizeDirection="bottom";break;case this.canvas.id+"topleft":this.resizeDirection="topleft";break;case this.canvas.id+"topright":this.resizeDirection="topright";break;case this.canvas.id+"bottomleft":this.resizeDirection="bottomleft";break;case this.canvas.id+"bottomright":this.resizeDirection="bottomright"}this.startPoint=this.prevPoint=this.mousePosition(e),this.viewPortRatio=this.parent.scroller.viewPortWidth/this.parent.scroller.viewPortHeight,document.getElementById(this.canvas.id+"overviewhandle").style.pointerEvents="none"},t.prototype.mouseUp=function(e){if(this.currentPoint=this.mousePosition(e),this.actionName)if(this.startPoint.x!==this.currentPoint.x||this.startPoint.y!==this.currentPoint.y){if("pan"!==this.actionName&&this.helper){var i=this.element.getElementsByTagName("rect")[10].getBBox();this.resizeDirection=this.resizeDirection||"",this.renderOverviewRect(i.x,i.y,o=i.width,a=i.height)}}else if(e.target.id===this.canvas.id+"_overviewsvg"||"helper"===e.target.id){var o=(i=this.element.getElementsByTagName("svg")[2].getElementById(this.canvas.id+"overviewrect").getBBox()).width,a=i.height;this.inAction=!0,this.actionName="pan",this.renderOverviewRect(this.currentPoint.x-o/2,this.currentPoint.y-a/2,o,a),this.inAction=!1}this.helper&&(this.helper.parentNode.removeChild(this.helper),this.helper=null),this.actionName="",this.startPoint=null,this.currentPoint=null,this.prevPoint=null,this.helper=null,this.viewPortRatio=1,this.resizeDirection="",this.inAction=!1,this.event=!0,document.getElementById(this.canvas.id+"overviewhandle").style.pointerEvents="all"},t.prototype.initHelper=function(){var e=this.element.getElementsByTagName("svg")[2],i=this.startPoint.x,r=this.startPoint.y,s=1,o=1;if("scale"===this.actionName){var l=e.getElementById(this.canvas.id+"overviewrect").getBBox();i=l.x,r=l.y,s=l.width,o=l.height}var h=Fi("rect",{id:"helper",x:i,y:r,width:s,height:o,fill:"transparent",stroke:"gray","stroke-dasharray":"2 2","shape-rendering":"crispEdges"});e.getElementById(this.element.id+"_overviewlayer").appendChild(h),this.helper=h},t.prototype.mousePosition=function(e){var i,r,s;-1!==e.type.indexOf("touch")?(r=(i=e).changedTouches[0].clientX-this.element.offsetLeft,s=i.changedTouches[0].clientY-this.element.offsetTop):(r=e.clientX,s=e.clientY);var l=this.element.getBoundingClientRect();return{x:(r-=l.left)+this.horizontalOffset,y:(s-=l.top)+this.verticalOffset}},t.prototype.destroy=function(){if(this.unWireEvents(),this.notify("destroy",{}),n.prototype.destroy.call(this),document.getElementById(this.element.id)){this.element.classList.remove("e-overview");var e=document.getElementById(this.element.id+"_canvas");e&&this.element.removeChild(e)}this.parent.views.splice(this.parent.views.indexOf(this.element.id),1),this.diagramLayerDiv=null,this.canvas=null,this.parent=null},t.prototype.getModuleName=function(){return"Overview"},nb([I("100%")],t.prototype,"width",void 0),nb([I("100%")],t.prototype,"height",void 0),nb([I("")],t.prototype,"sourceID",void 0),nb([H()],t.prototype,"created",void 0),t}(Ii);function pse(n,t){for(var e=0;eR.findLength(e,n)?e:t;var o=R.findAngle(t,e),a=R.findAngle(i,n),l=R.findLength(i,n),h=a+2*(o-a);return{x:i.x+l*Math.cos(h*Math.PI/180),y:i.y+l*Math.sin(h*Math.PI/180)}}function tp(n,t,e){if(n&&n.children&&n.children.length>0)for(var r=void 0,s=0;s0&&"annotations"!==r&&"ports"!==r)if(n[""+l].length>0)for(var h=0;h<=n[""+l].length;h++)Ro(n[""+l],t?t[""+l]:void 0,e[""+l],"annotations"===l||"ports"===l?n:void 0,l);else Ro(n[""+l],t?t[""+l]:void 0,e[""+l],"annotations"===l||"ports"===l?n:void 0,l);else if(s instanceof Object&&t&&"annotations"!==r&&"ports"!==r)Ro(n[""+l],t[""+l],e[""+l]);else if("annotations"!==r&&"ports"!==r&&t&&!t[""+l]||!t&&n&&(n[""+l]||void 0!==n[""+l]))n[""+l]=e[""+l];else{var c=void 0;("annotations"===r||"ports"===r)&&("annotations"===r?(n[""+l]&&Ro(n[""+l],t[""+l],e[""+l]),n[""+l]||(ps(i)===de?(c=new Or(i,"annotations",e[""+l]),i.annotations.push(c)):(c=new Kn(i,"annotations",e[""+l]),i.annotations.push(c)))):n[""+l]?Ro(n[""+l],t[""+l],e[""+l]):(c=new Es(i,"ports",e[""+l]),i.ports.push(c)))}}}function bse(n,t){for(var e="Bezier"===n.type?function yse(n){var t=[];if("Bezier"===n.type)for(var e=0,i=0;i0||n.ports.length>0){var f=n.wrapper.children;for(i=3;i0)return{enabled:!1,intersectPt:e};var l=o/s,h=a/s;return l>=0&&l<=1&&h>=0&&h<=1?(e.x=i.x1+l*(i.x2-i.x1),e.y=i.y1+l*(i.y2-i.y1),{enabled:!0,intersectPt:e}):{enabled:!1,intersectPt:e}}function ob(n,t,e,i){var a=nm(vF(n.x,n.y,t.x,t.y),vF(e.x,e.y,i.x,i.y));return a.enabled?a.intersectPt:{x:0,y:0}}function vF(n,t,e,i){return{x1:Number(n)||0,y1:Number(t)||0,x2:Number(e)||0,y2:Number(i)||0}}function mF(n,t,e){var i=[],s={x:t.topRight.x+(e=e||0),y:t.topRight.y},o={x:t.bottomRight.x,y:t.bottomRight.y-e},a={x:t.bottomLeft.x,y:t.bottomLeft.y+e};return i.push({x:t.topLeft.x-e,y:t.topLeft.y}),i.push(s),i.push(o),i.push(a),i}function Hc(n,t,e,i,r,s){var o={},a=e.scroller.transform.scale,h=e.scroller.verticalOffset;return o.x=(i?n.x:t.x)*a+e.scroller.horizontalOffset-r,o.y=(i?n.y:t.y)*a+h-s,o}function yF(n,t){var e=new Ze;return e.data=n.pathData,e.height=n.height>10?n.height-(n.padding.bottom+n.padding.top):n.height,e.width=n.width>10?n.width-(n.padding.left+n.padding.right):n.width,e.visible=n.visibility,e.id=t.id+"_shape",e.inversedAlignment=!1,e.horizontalAlignment="Center",e.verticalAlignment="Center",e.style={fill:n.iconStrokeColor,strokeColor:n.iconStrokeColor,strokeWidth:n.iconStrokeWidth},e.setOffsetWithRespectToBounds(.5,.5,"Fraction"),e.relativeMode="Object",e.description=t.description||"",e}function Jx(n,t,e){var i=Kx(n,t),r=R.findAngle(n[i.index],n[i.index+1]),s=function Tse(n){var t;t=n instanceof PI?0:void 0===n.content?10:0;var e=0;switch(n.alignment){case"Center":e=0;break;case"Before":e=-(0+t);break;case"After":e=0+t}return e}(t),o=R.transform(i.point,r+45,s);return i.point=o,i.angle=r,i}function Kx(n,t){for(var r,s,a,l,e=0,i=t.offset,o=[],h=0;h=c)return s=R.findAngle(n[parseInt(d.toString(),10)],n[d+1]),{point:r=R.transform(n[parseInt(d.toString(),10)],s,c-(a||0)),index:l=d};a=o[parseInt(d.toString(),10)]}return{point:r,index:l}}function SF(n,t,e){t%=360;var a,l,s=225;switch(n.alignment){case"Before":t>=45&&t<=135?(l="right",a=.5===n.offset?"center":"top"):t>=s&&t<=315?(l="left",a=.5===n.offset?"center":"bottom"):t>45&&t=45&&t<=135?(l="left",a=.5===n.offset?"center":"top"):t>=s&&t<=315?(l="right",a=.5===n.offset?"center":"bottom"):t>45&&tMath.abs(t.y-n.y)?n.x0)for(var e=0;e=0;r--)("nodes"===i||"connectors"===i)&&(n[""+i][parseInt(r.toString(),10)].wrapper=null),"dataManager"!==i&&(n[""+i][parseInt(r.toString(),10)]=iT(n[""+i][parseInt(r.toString(),10)],e[""+i][parseInt(r.toString(),10)],void 0!==t[""+i]?t[""+i][parseInt(r.toString(),10)]:[]),("[]"===JSON.stringify(n[""+i][parseInt(r.toString(),10)])||"{}"===JSON.stringify(n[""+i][parseInt(r.toString(),10)])||void 0===n[""+i][parseInt(r.toString(),10)])&&n[""+i].splice(r,1));n=void 0}function Fh(n,t){var e=t.style,i=t;t.canApplyStyle=!0;for(var r=0,s=Object.keys(n);r=0&&n.splice(e,1)}function ip(n,t,e){var i;n.intermediatePoints=t,n.updateSegmentElement(n,t,n.wrapper.children[0],e);var r=n.sourceDecorator;if("Bezier"===n.type){var s=n.segments[0],o=n.segments[n.segments.length-1];i=[R.isEmptyPoint(o.point2)?o.bezierPoint2:o.point2,R.isEmptyPoint(s.point1)?s.bezierPoint1:s.point1]}else i=n.intermediatePoints;t=n.clipDecorators(n,t,e);var a=n.wrapper.children[0];a.canMeasurePath=!0,n.updateDecoratorElement(a=n.wrapper.children[1],t[0],i[1],r),n.updateDecoratorElement(a=n.wrapper.children[2],t[t.length-1],i[i.length-2],n.targetDecorator),n.updateShapeElement(n)}function rT(n,t,e){var l,i=n.wrapper,s=t.offset,o=t.size/e.scale,a=t.margin,h=i.offsetX-i.actualSize.width*i.pivot.x,c=i.offsetY-i.actualSize.height*i.pivot.y;if(l={x:0,y:0},n.nodes.length>0){switch(t.side){case"Top":l.x+=h+s*i.actualSize.width,l.y+=c-o;break;case"Bottom":l.x+=h+s*i.actualSize.width,l.y+=c+i.actualSize.height+o;break;case"Left":l.x+=h-o,l.y+=c+s*i.actualSize.height;break;case"Right":l.x+=h+i.actualSize.width+o,l.y+=c+s*i.actualSize.height}l.x+=(a.left-a.right)/e.scale+o/2*("Center"===t.horizontalAlignment?0:"Right"===t.horizontalAlignment?-1:1),l.y+=(a.top-a.bottom)/e.scale+o/2*("Center"===t.verticalAlignment?0:"Top"===t.verticalAlignment?-1:1)}else if(n.connectors.length>0){var d=n.connectors[0],u={offset:s},f=Kx(d.intermediatePoints,u),p=f.index;l=f.point;var y,v=Jx(d.intermediatePoints,u).angle;qi(y=Bi(),-v,d.intermediatePoints[parseInt(p.toString(),10)].x,d.intermediatePoints[parseInt(p.toString(),10)].y),(l=Ke(y,l)).x+=a.left-a.right+o/2*("Center"===t.horizontalAlignment?0:"Right"===t.horizontalAlignment?-1:1),l.y+=a.top-a.bottom+o/2*("Center"===t.verticalAlignment?0:"Top"===t.verticalAlignment?-1:1),qi(y=Bi(),v,d.intermediatePoints[parseInt(p.toString(),10)].x,d.intermediatePoints[parseInt(p.toString(),10)].y),l=Ke(y,l)}return 0===i.rotateAngle&&0===i.parentTransform||(qi(y=Bi(),i.rotateAngle+i.parentTransform,i.offsetX,i.offsetY),l=Ke(y,l)),l}function ga(n,t,e,i){if(i.annotation){if(zl(i.annotation))return!0}else if(mr[""+t]&n&&bt[""+t]&e)return!0;return!1}function qr(n,t){return!!(mr[""+t]&n)}function Fc(n,t){return!!(Ex[""+t]&n)}function va(n,t){return n.visibility&t}function ab(n,t){var e;if("Text"===n.shape.type)e=n.shape;else{var i=t.split("_");t=i[i.length-1];for(var r=0;rn[""+t]?e.splice(0,0,n):e.push(n);else if(e.length>1){for(var i=0,r=e.length-1,s=Math.floor((i+r)/2);s!==i;)if(e[parseInt(s.toString(),10)][""+t]n[""+t]))break;r=s,s=Math.floor((i+r)/2)}e[parseInt(r.toString(),10)][""+t]n[""+t]?e.splice(i,0,n):e[parseInt(i.toString(),10)][""+t]n[""+t]&&e.splice(r,0,n)}}function Qse(n){var t=document.getElementById(n.diagramId),e="ej2_instances",i=t[""+e][0].nodes;void 0===i&&(i=function Gse(n){for(var t=[],e=0;e30?10:o/2;for(var h=0,c=0;c=l){var u=l-h;r=Gt(n[c],n[c+1]),s=R.transform(n[c],r,u);break}h+=d}return s},cb=function(n,t){if(n instanceof te||n instanceof de)for(var e=0;e=0||navigator.platform.indexOf("iPad")>=0||navigator.platform.indexOf("iPhone")>=0||navigator.platform.indexOf("MacIntel")>=0)&&("safari"===X.info.name||"webkit"===X.info.name)}function AF(n,t,e,i){return void 0!==t.previewSize[""+i]?t.previewSize[""+i]:void 0!==n.symbolPreview[""+i]?n.symbolPreview[""+i]:t[""+i]||e.actualSize[""+i]}function hm(n,t,e){return n&&n.parentId&&(e=(n=t.nameTable[n.parentId]).parentId?hm(n,t,e):n.id),e}function cm(n,t){return n.selectedItems.connectors.length>1&&0===n.selectedItems.nodes.length&&0!==t.rotateAngle}function Zse(n){if(n.arrowType&&""!==n.arrowType.trim())switch(n.arrowType){case"single-line-arrow":default:return{targetDecorator:"Arrow",strokeWidth:1};case"double-line-arrow":return{targetDecorator:"Arrow",strokeWidth:2};case"dotted-arrow":return{targetDecorator:"Arrow",strokeDashArray:"2,2"};case"single-line":return{targetDecorator:"None",strokeWidth:1};case"double-line":return{targetDecorator:"None",strokeWidth:2};case"dotted":return{targetDecorator:"None",strokeDashArray:"2,2"};case"wiggly-arrow":return{targetDecorator:"None",strokeWidth:1,opacity:0}}return{targetDecorator:"Arrow",strokeWidth:1}}var Jse=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),no=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},LF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Jse(t,n),no([I("None")],t.prototype,"shape",void 0),no([I("white")],t.prototype,"fill",void 0),no([I("Auto")],t.prototype,"horizontalAlignment",void 0),no([I("Auto")],t.prototype,"verticalAlignment",void 0),no([I(10)],t.prototype,"width",void 0),no([I(10)],t.prototype,"height",void 0),no([re({x:.5,y:1},R)],t.prototype,"offset",void 0),no([I("#1a1a1a")],t.prototype,"borderColor",void 0),no([I(1)],t.prototype,"borderWidth",void 0),no([re({},Jn)],t.prototype,"margin",void 0),no([I("")],t.prototype,"pathData",void 0),no([I("")],t.prototype,"content",void 0),no([I(0)],t.prototype,"cornerRadius",void 0),no([re({left:2,right:2,top:2,bottom:2},Jn)],t.prototype,"padding",void 0),no([I("#1a1a1a")],t.prototype,"iconColor",void 0),t}(Ee),Kse=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),aT=function(n){function t(){var e=null!==n&&n.apply(this,arguments)||this;return e.orientation="Vertical",e.measureChildren=void 0,e.considerPadding=!0,e}return Kse(t,n),t.prototype.measure=function(e){return this.desiredSize=this.measureStackPanel(e,"Horizontal"===this.orientation?this.updateHorizontalStack:this.updateVerticalStack),this.desiredSize},t.prototype.arrange=function(e){return this.actualSize=this.arrangeStackPanel(e,"Horizontal"===this.orientation?this.arrangeHorizontalStack:this.arrangeVerticalStack),this.updateBounds(),this.actualSize},t.prototype.measureStackPanel=function(e,i){var r=void 0;if(void 0!==this.children&&this.children.length>0)for(var s=0,o=this.children;s0){var r=void 0,s=void 0;r=this.offsetX-e.width*this.pivot.x+this.padding.left,s=this.offsetY-e.height*this.pivot.y+this.padding.top;for(var o=0,a=this.children;o0)for(var i=0,r=this.children;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},aoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return ooe(t,n),_h([I("Horizontal")],t.prototype,"orientation",void 0),_h([I("Center")],t.prototype,"type",void 0),_h([I(void 0)],t.prototype,"offset",void 0),_h([I(!1)],t.prototype,"enableRouting",void 0),_h([I([])],t.prototype,"children",void 0),_h([I("")],t.prototype,"assistants",void 0),_h([I("")],t.prototype,"level",void 0),_h([I("")],t.prototype,"hasSubTree",void 0),_h([I("")],t.prototype,"rows",void 0),t}(Ee),Ni=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),q=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},loe=function(n){if(n)switch(n.type){case"Basic":default:return db;case"Flow":return PF;case"Path":return NF;case"Image":return kF;case"Text":return Bd;case"Bpmn":return fT;case"Native":return dm;case"HTML":return OF;case"UmlActivity":return zF;case"UmlClassifier":return RF;case"SwimLane":return Ud}return db},ma=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),q([I("Basic")],t.prototype,"type",void 0),t}(Ee),NF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"Path"},q([I("Path")],t.prototype,"type",void 0),q([I("")],t.prototype,"data",void 0),t}(ma),dm=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"Native"},q([I("Native")],t.prototype,"type",void 0),q([I("")],t.prototype,"content",void 0),q([I("Stretch")],t.prototype,"scale",void 0),t}(ma),OF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"Html"},q([I("HTML")],t.prototype,"type",void 0),q([I("")],t.prototype,"content",void 0),t}(ma),kF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"Image"},q([I("Image")],t.prototype,"type",void 0),q([I("")],t.prototype,"source",void 0),q([I("None")],t.prototype,"scale",void 0),q([I("None")],t.prototype,"align",void 0),t}(ma),Bd=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"Text"},q([I("Text")],t.prototype,"type",void 0),q([I("")],t.prototype,"content",void 0),q([re({},Jn)],t.prototype,"margin",void 0),t}(ma),db=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"BasicShape"},q([I("Basic")],t.prototype,"type",void 0),q([I("Rectangle")],t.prototype,"shape",void 0),q([I(0)],t.prototype,"cornerRadius",void 0),q([Bt([],R)],t.prototype,"points",void 0),t}(ma),PF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"FlowShape"},q([I("Flow")],t.prototype,"type",void 0),q([I("Terminator")],t.prototype,"shape",void 0),t}(ma),hT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"BpmnGateway"},q([I("None")],t.prototype,"type",void 0),t}(Ee),cT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"BpmnDataObject"},q([I("None")],t.prototype,"type",void 0),q([I(!1)],t.prototype,"collection",void 0),t}(Ee),hoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),q([I("None")],t.prototype,"type",void 0),q([I("None")],t.prototype,"loop",void 0),q([I(!1)],t.prototype,"call",void 0),q([I(!1)],t.prototype,"compensation",void 0),t}(Ee),dT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"BpmnEvent"},q([I("Start")],t.prototype,"event",void 0),q([I("None")],t.prototype,"trigger",void 0),t}(Ee),Fd=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"BpmnSubEvent"},q([I("None")],t.prototype,"trigger",void 0),q([I("Start")],t.prototype,"event",void 0),q([I("")],t.prototype,"id",void 0),q([re({},R)],t.prototype,"offset",void 0),q([Bt([],Kn)],t.prototype,"annotations",void 0),q([Bt([],Es)],t.prototype,"ports",void 0),q([I()],t.prototype,"width",void 0),q([I()],t.prototype,"height",void 0),q([re({},Jn)],t.prototype,"margin",void 0),q([I("Center")],t.prototype,"horizontalAlignment",void 0),q([I("Center")],t.prototype,"verticalAlignment",void 0),q([I(!0)],t.prototype,"visible",void 0),t}(Ee),coe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),q([re({id:"success",event:"End",offset:{x:1,y:.5}},Fd)],t.prototype,"success",void 0),q([re({id:"failure",event:"Intermediate",trigger:"Error",offset:{x:.25,y:1}},Fd)],t.prototype,"failure",void 0),q([re({id:"cancel",event:"Intermediate",trigger:"Cancel",offset:{x:.75,y:1}},Fd)],t.prototype,"cancel",void 0),t}(Ee),doe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),q([I("None")],t.prototype,"type",void 0),q([I(!1)],t.prototype,"adhoc",void 0),q([I("Default")],t.prototype,"boundary",void 0),q([I(!1)],t.prototype,"compensation",void 0),q([I("None")],t.prototype,"loop",void 0),q([I(!0)],t.prototype,"collapsed",void 0),q([Bt([],Fd)],t.prototype,"events",void 0),q([re({},coe)],t.prototype,"transaction",void 0),q([I(void 0)],t.prototype,"processes",void 0),t}(Ee),uT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"BpmnActivity"},q([I("Task")],t.prototype,"activity",void 0),q([re({},hoe)],t.prototype,"task",void 0),q([re({},doe)],t.prototype,"subProcess",void 0),t}(Ee),um=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return Ni(t,n),t.prototype.getClassName=function(){return"BpmnAnnotation"},q([I("")],t.prototype,"text",void 0),q([I("")],t.prototype,"id",void 0),q([I(0)],t.prototype,"angle",void 0),q([I()],t.prototype,"height",void 0),q([I()],t.prototype,"width",void 0),q([I(0)],t.prototype,"length",void 0),t}(Ee),uoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),q([I("")],t.prototype,"textAnnotationTarget",void 0),q([I("Auto")],t.prototype,"textAnnotationDirection",void 0),t}(Ee),fT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"BpmnShape"},q([I("Bpmn")],t.prototype,"type",void 0),q([I("Event")],t.prototype,"shape",void 0),q([re({},dT)],t.prototype,"event",void 0),q([re({},hT)],t.prototype,"gateway",void 0),q([re({},cT)],t.prototype,"dataObject",void 0),q([re({},uT)],t.prototype,"activity",void 0),q([re({},um)],t.prototype,"annotation",void 0),q([Bt([],um)],t.prototype,"annotations",void 0),q([re({},uoe)],t.prototype,"textAnnotation",void 0),t}(ma),zF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"UmlActivityShape"},q([I("UmlActivity")],t.prototype,"type",void 0),q([I("Action")],t.prototype,"shape",void 0),t}(ma),pT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"MethodArguments"},q([I("")],t.prototype,"name",void 0),q([I("")],t.prototype,"type",void 0),q([re({},$f)],t.prototype,"style",void 0),t}(Ee),ap=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"UmlClassAttribute"},q([I("Public")],t.prototype,"scope",void 0),q([I(!1)],t.prototype,"isSeparator",void 0),q([re({fill:"#F9F9F9",strokeColor:"#CCCCCC"},Nl)],t.prototype,"separatorStyle",void 0),t}(pT),fm=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"UmlClassMethod"},q([Bt([],pT)],t.prototype,"parameters",void 0),t}(ap),ub=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"UmlClass"},q([I("")],t.prototype,"name",void 0),q([Bt([],ap)],t.prototype,"attributes",void 0),q([Bt([],fm)],t.prototype,"methods",void 0),q([re({},$f)],t.prototype,"style",void 0),t}(Ee),gT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"UmlInterface"},q([I(!1)],t.prototype,"isSeparator",void 0),q([re({fill:"#F9F9F9",strokeColor:"#CCCCCC"},Nl)],t.prototype,"separatorStyle",void 0),t}(ub),fb=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"UmlEnumerationMember"},q([I("")],t.prototype,"name",void 0),q([I("")],t.prototype,"value",void 0),q([I(!1)],t.prototype,"isSeparator",void 0),q([re({fill:"#F9F9F9",strokeColor:"#CCCCCC"},Nl)],t.prototype,"separatorStyle",void 0),q([re({},$f)],t.prototype,"style",void 0),t}(Ee),vT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"UmlEnumeration"},q([I("")],t.prototype,"name",void 0),q([Bt([],fb)],t.prototype,"members",void 0),q([re({},$f)],t.prototype,"style",void 0),t}(Ee),RF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"UmlClassifierShape"},q([I("UmlClassifier")],t.prototype,"type",void 0),q([re({},ub)],t.prototype,"classShape",void 0),q([re({},gT)],t.prototype,"interfaceShape",void 0),q([re({},vT)],t.prototype,"enumerationShape",void 0),q([I("Class")],t.prototype,"classifier",void 0),t}(ma),te=function(n){function t(e,i,r,s){var a,o=n.call(this,e,i,r,s)||this;return o.isCanvasUpdate=!1,o.status="None",o.parentId="",o.processId="",o.umlIndex=-1,o.outEdges=[],o.inEdges=[],o.isHeader=!1,o.isLane=!1,o.isPhase=!1,o.children&&o.children.length>0&&((!(a=r).style||!a.style.fill)&&(o.style.fill="transparent"),(!a.style||!a.style.strokeColor)&&(o.style.strokeColor="transparent")),o.shape&&"UmlActivity"===o.shape.type&&sb(r,o),o.shape&&"SwimLane"===o.shape.type&&fF(r,o),o.ports&&o.ports.length&&function vse(n){for(var t=0;t>";t=n;break;case"FinalNode":t=IF(e)}return t}(new Ze,i,this);break;case"Bpmn":if(e.bpmnModule){i=e.bpmnModule.initBPMNContent(i,this,e),this.wrapper.elementActions=this.wrapper.elementActions|Xr.ElementIsGroup;var v=this.shape.activity.subProcess;if(v.processes&&v.processes.length)for(var S=0,b=this.shape.activity.subProcess.processes;S>",margin:{left:10,right:10},id:"class",style:{fontSize:i.style.fontSize,color:i.style.color,fill:i.style.fill,textWrapping:r},offset:{x:.5,y:.3},constraints:Nr.ReadOnly}],constraints:(ie.Default|ie.HideThumbs)&~(ie.Rotate|ie.Drag|ie.Resize),verticalAlignment:"Stretch",horizontalAlignment:"Stretch",style:{fill:t.style.fill,strokeColor:"black"===t.style.strokeColor?"#ffffff00":t.style.strokeColor}},!0);return e.initObject(s),e.nodes.push(s),e.UpdateBlazorDiagramModel(s,"Node"),t.children.push(s.id),function toe(n,t,e,i){if("Enumeration"===n.shape.classifier){var r=e.members;if(r&&r.length){sp(n,t);for(var s="",o=0;o0)for(var o=0;o0&&s.phaseSize&&(i+=s.phaseSize,$v(n,s.phaseSize)),s.lanes.length>0)for(o=0;o0){var a=0;for(o=0;o0&&"Horizontal"===r.orientation)for(l=0;l0&&(i+=r.phaseSize,o=Zv(r.phaseSize),n.push(o)),a=0;a0&&o.phaseSize){for(var l=0;l0)for(l=0;l0?e.nameTable[this.nodes[0].id].wrapper:e.nameTable[this.connectors[0].id].wrapper,this.annotation.id);i.children.push(s)}else if(this.nodes||this.connectors){for(var o=0;o-1}function VF(n,t,e){n=[];for(var i=0,r=e.length;i0?c.getElementsByTagName("svg")[0].outerHTML:c.getElementsByTagName("g").length>0?c.getElementsByTagName("g")[0].outerHTML:"",s.shape.content=h,n.content=h,c.parentElement.removeChild(c)}l="nodeTemplate"}else a=s,l="annotationTemplate";var p=document.getElementById(n.diagramId).ej2_instances[0];if("string"!=typeof n.content&&"function"!=typeof n.content||n.isTemplate)if(n.isTemplate){if(v=void 0,v=p.isReact?n.getNodeTemplate()($(e),p,l+"_"+("nodeTemplate"===l?e.id:n.nodeId+e.id),void 0,void 0,!1,i):p.isVue||p.isVue3?n.getNodeTemplate()?n.getNodeTemplate()($(e),p,l+"_"+("nodeTemplate"===l?e.id:n.nodeId+e.id),void 0,void 0,!1,i):(v=si("nodeTemplate"===l?p.nodeTemplate:p.annotationTemplate))($(e),p,l+"_"+("nodeTemplate"===l?e.id:n.nodeId+e.id),void 0,void 0,!1,i):n.getNodeTemplate()($(e),p,l+"_"+("nodeTemplate"===l?e.id:n.nodeId+e.id),void 0,void 0,!1))for(var M=0;M=1&&0===n.x&&("Clip"===i.textOverflow||"Ellipsis"===i.textOverflow)&&("Wrap"===i.textWrapping||"WrapWithOverflow"===i.textWrapping)&&(n.x=t[e-1]?t[e-1].x:-n.width/2),n.x}function QF(n,t,e,i){return e&&!t.template||t.template&&"function"==typeof t.template&&i.isReact?(n.isTemplate=!0,n.template=n.content=Uh(n,!0,t)):n.content=t.template,n}function Qe(){for(var e,t="",i=0;i<5;i++){if(typeof window<"u"&&"crypto"in window&&"getRandomValues"in crypto){var r=new Uint16Array(1);e=(window.msCrypto||window.crypto).getRandomValues(r)[0]%60}else e=Math.floor(61*Math.random());0===i&&e<10?i--:t+="0123456789ABCDEFGHIJKLMNOPQRSTUVWXTZabcdefghiklmnopqrstuvwxyz".substring(e,e+1)}return t}function GF(n){if(n)try{return"function"!=typeof n&&document.querySelectorAll(n).length?si(document.querySelector(n).innerHTML.trim()):si(n)}catch{return si(n)}}function xn(n){new Ne;var e=n.offsetY-n.actualSize.height*n.pivot.y,i=n.offsetY+n.actualSize.height*(1-n.pivot.y),r=n.offsetX-n.actualSize.width*n.pivot.x,s=n.offsetX+n.actualSize.width*(1-n.pivot.x);return Ne.toBounds([{x:r,y:e},{x:s,y:e},{x:r,y:i},{x:s,y:i}])}function yr(n){var t=new Ne,e=xn(n),i=e.middleLeft,r=e.topCenter,s=e.bottomCenter,o=e.middleRight,a=e.topLeft,l=e.topRight,h=e.bottomLeft,c=e.bottomRight;if(n.corners={topLeft:a,topCenter:r,topRight:l,middleLeft:i,middleRight:o,bottomLeft:h,bottomCenter:s,bottomRight:c},0!==n.rotateAngle||0!==n.parentTransform){var d=Bi();qi(d,n.rotateAngle+n.parentTransform,n.offsetX,n.offsetY),n.corners.topLeft=a=Ke(d,a),n.corners.topCenter=r=Ke(d,r),n.corners.topRight=l=Ke(d,l),n.corners.middleLeft=i=Ke(d,i),n.corners.middleRight=o=Ke(d,o),n.corners.bottomLeft=h=Ke(d,h),n.corners.bottomCenter=s=Ke(d,s),n.corners.bottomRight=c=Ke(d,c)}return t=Ne.toBounds([a,l,h,c]),n.corners.left=t.left,n.corners.right=t.right,n.corners.top=t.top,n.corners.bottom=t.bottom,n.corners.center=t.center,n.corners.width=t.width,n.corners.height=t.height,t}function $(n,t,e,i){var r={},s="properties";if(n){e=n.propName;var l=[],h=[];if((l=l.concat(Object.keys(n[""+s]||n))).push("version"),e){var c=Zi(t);h=c?c(e):[],l=l.concat(h)}for(var d=function Ooe(n){switch(n){case"nodes":case"children":return["inEdges","outEdges","parentId","processId","nodeId","umlIndex","isPhase","isLane"];case"connectors":return["parentId"];case"annotation":case"annotations":return["nodeId"];case"shape":return["hasHeader"];case"layers":return["objectZIndex"]}return[]}(e),u=0,f=l=l.concat(d);u0&&(e=r),r=Math.floor(Poe(e,i)),s=_c(o+=n.substr(e,r),t)}while(s<=t.width);for(o=o.substr(0,e),a=e;a=t.width){n=n.substr(0,o.length-1);break}return"Ellipsis"===t.textOverflow?(n=n.substr(0,n.length-3),n+="..."):n=n.substr(0,n.length),n}function wT(n,t){if("NoWrap"===t&&"PreserveAll"===n)return"pre";var e="";switch(n){case"CollapseAll":e="nowrap";break;case"CollapseSpace":e="pre-line";break;case"PreserveAll":e="pre-wrap"}return e}function CT(n,t){var e=Bi();qi(e,t,0,0);var i=Ke(e,{x:0,y:0}),r=Ke(e,{x:n.width,y:0}),s=Ke(e,{x:0,y:n.height}),o=Ke(e,{x:n.width,y:n.height}),a=Math.min(i.x,r.x,s.x,o.x),l=Math.min(i.y,r.y,s.y,o.y),h=Math.max(i.x,r.x,s.x,o.x),c=Math.max(i.y,r.y,s.y,o.y);return new me(h-a,c-l)}function xs(n,t,e,i){if(0!==n){var r=Bi();return qi(r,n,t,e),Ke(r,i)}return i}function Zi(n){return void 0!==n&&"string"==typeof n&&(n=Y(n,window)),n}var bo=function(){function n(){}return n.getContext=function(t){return t.getContext("2d")},n.setCanvasSize=function(t,e,i){t&&(t.setAttribute("width",e.toString()),t.setAttribute("height",i.toString()))},n.prototype.renderGradient=function(t,e,i,r){var s,o,a;if("None"!==t.gradient.type){for(var l=0;l0?(w=0===S.r1?e.arc[parseInt(r.toString(),10)].r1:S.r1,C=0===S.r2?e.arc[parseInt(r.toString(),10)].r2:S.r2,r++):(w=S.r1,C=S.r2);var D=S.angle*(Math.PI/180),A=S.largeArc,x=S.sweep,P={x:u,y:f},L={x:Math.cos(D)*(M.x-P.x)/2+Math.sin(D)*(M.y-P.y)/2,y:-Math.sin(D)*(M.x-P.x)/2+Math.cos(D)*(M.y-P.y)/2},O=Math.pow(L.x,2)/Math.pow(w,2)+Math.pow(L.y,2)/Math.pow(C,2);O>1&&(w*=Math.sqrt(O),C*=Math.sqrt(O));var N=Math.pow(C,2)*Math.pow(L.x,2),T=(A===x?-1:1)*Math.sqrt((Math.pow(w,2)*Math.pow(C,2)-Math.pow(w,2)*Math.pow(L.y,2)-N)/(Math.pow(w,2)*Math.pow(L.y,2)+Math.pow(C,2)*Math.pow(L.x,2)));isNaN(T)&&(T=0);var z={x:T*w*L.y/C,y:T*-C*L.x/w},U={x:(M.x+P.x)/2+Math.cos(D)*z.x-Math.sin(D)*z.y,y:(M.y+P.y)/2+Math.sin(D)*z.x+Math.cos(D)*z.y},B=this.a([1,0],[(L.x-z.x)/w,(L.y-z.y)/C]),j=[(L.x-z.x)/w,(L.y-z.y)/C],Q=[(-L.x-z.x)/w,(-L.y-z.y)/C],oe=this.a(j,Q);this.r(j,Q)<=-1&&(oe=Math.PI),this.r(j,Q)>=1&&(oe=0);var fe=B+oe/2*(x?1:-1);if(Math.cos(fe),Math.sin(fe),S.centp=U,S.xAxisRotation=D,S.rx=w,S.ry=C,S.a1=B,S.ad=oe,S.sweep=x,null!=s){var De=w>C?w:C,xe=w>C?1:w/C,Ie=w>C?C/w:1;s.save(),s.translate(U.x,U.y),s.rotate(D),s.scale(xe,Ie),s.arc(0,0,De,B,B+oe,!x),s.scale(1/xe,1/Ie),s.rotate(-D),s.translate(-U.x,-U.y),s.restore()}break;case"Z":case"z":s.closePath(),u=o,f=a}o=u,a=f}}},n.prototype.drawText=function(t,e,i,r,s,o,a){if(e.content&&!0===e.visible){var l=n.getContext(t);l.save(),this.setStyle(t,e),o&&(e.fontSize*=o),this.applyFlipAndRotate(l,e,t,e.x+e.width*e.pivotX,e.y+e.height*e.pivotY),this.setFontStyle(t,e);var u,d=0;u=e.childNodes;var f=e.wrapBounds;if(l.fillStyle=e.color,f){var p=this.labelAlign(e,f,u);for(d=0;de.width&&"Wrap"!==e.textOverflow&&"NoWrap"===e.textWrapping&&(g.text=qF(g.text,e)),"Clip"!==e.textOverflow&&"Ellipsis"!==e.textOverflow||"Wrap"!==e.textWrapping?l.fillText(g.text,v,y):ya.actualSize.height+a.bounds.y&&(g.text=g.text.slice(0,g.text.length-3),g.text=g.text.concat("...")),l.fillText(g.text,v,y)),"Underline"===e.textDecoration||"Overline"===e.textDecoration||"LineThrough"===e.textDecoration){var M=v,w=void 0,D=v+l.measureText(g.text).width,A=void 0;switch(e.textDecoration){case"Underline":w=y+2,A=y+2;break;case"Overline":w=p.y+g.dy*d,A=p.y+g.dy*d;break;case"LineThrough":w=(y+p.y+g.dy*d)/2+2,A=(y+p.y+g.dy*d)/2+2}l.beginPath(),l.moveTo(M,w),l.lineTo(D,A),l.strokeStyle=e.color,l.lineWidth=.08*e.fontSize,l.globalAlpha=e.opacity,l.stroke()}}}l.restore()}},n.prototype.applyFlipAndRotate=function(t,e,i,r,s){"Horizontal"===e.flip||"Vertical"===e.flip?(t.translate(e.x+e.width/2,e.y+e.height/2),t.rotate(-e.angle*Math.PI/180),t.translate(-e.x-e.width/2,-e.y-e.height/2)):this.rotateContext(i,e.angle,r,s),t.translate(e.x,e.y),"Horizontal"===e.flip?(t.scale(-1,1),t.translate(-1*e.width,0)):"Vertical"===e.flip?(t.scale(1,-1),t.translate(0,-1*e.height)):"Both"===e.flip&&(t.scale(-1,-1),t.translate(-1*e.width,-1*e.height)),t.translate(-e.x,-e.y)},n.prototype.loadImage=function(t,e,i,r,s){var o=new Image;o.src=e.source,this.image(t,o,e.x,e.y,e.width,e.height,e)},n.prototype.drawImage=function(t,e,i,r){var s=this;if(e.visible){var o=n.getContext(t);o.save();var a=e.x+e.width*e.pivotX,l=e.y+e.height*e.pivotY,h=new Image;h.src=e.source,this.setStyle(t,e),o.canvas.id.split("_"),this.applyFlipAndRotate(o,e,t,a,l),r?h.onload=function(){s.loadImage(o,e,t,a,l)}:this.loadImage(o,e,t,a,l),o.restore()}},n.prototype.image=function(t,e,i,r,s,o,a){t.beginPath();var l=e.width,h=e.height,c=s,d=o,u=0,f=0;if(a&&"None"!==a.alignment){var p=a.alignment.toLowerCase().substr(1,3),g=a.alignment.toLowerCase().substr(5,3);if("Slice"===a.scale){var v=function(){u=c,f=h*c/l},y=function(){u=l*d/h,f=d};c>d?(v(),d>f&&y()):c===d?l>h?y():v():(y(),c>u&&v());var S=this.getSliceOffset(p,u,c,l),b=this.getSliceOffset(g,f,d,h),M=l-S,w=h-b,C=u-S*(u/l),D=f-b*(f/h),A=Tt("canvas",{width:s.toString(),height:o.toString()});A.getContext("2d").drawImage(e,S,b,M,w,0,0,C,D),t.drawImage(A,i,r,s,o)}else if("Meet"===a.scale){var P=h/l,L=d/c;f=L>P?c*P:d,i+=this.getMeetOffset(p,u=L>P?c:d/P,c),r+=this.getMeetOffset(g,f,d),t.drawImage(e,0,0,l,h,i,r,u,f)}else t.drawImage(e,i,r,s,o)}else if("None"!==a.flip){var O=1,N=1;("Horizontal"===a.flip||"Both"===a.flip)&&(i=-i,s=-s,O=-1),("Vertical"===a.flip||"Both"===a.flip)&&(r=-r,o=-o,N=-1),t.scale(O,N),t.drawImage(e,i,r,s,o)}else t.drawImage(e,i,r,s,o);t.closePath()},n.prototype.getSliceOffset=function(t,e,i,r){switch(t){case"min":default:return 0;case"mid":return(e-i)/2*r/e;case"max":return(e-i)*r/e}},n.prototype.getMeetOffset=function(t,e,i){var r=Math.max(e,i),s=Math.min(e,i);switch(t){case"min":default:return 0;case"mid":return(r-s)/2;case"max":return r-s}},n.prototype.m=function(t){return Math.sqrt(Math.pow(t[0],2)+Math.pow(t[1],2))},n.prototype.r=function(t,e){return(t[0]*e[0]+t[1]*e[1])/(this.m(t)*this.m(e))},n.prototype.a=function(t,e){return(t[0]*e[1]t.width&&("Ellipsis"===t.textOverflow||"Clip"===t.textOverflow)&&"NoWrap"===t.textWrapping?0:.5*t.width:"right"===t.textAlign&&(c=1*t.width),s.x=t.x+c+(e?e.x:0),s.y=a+d-r.height/2,s},n}(),yb=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Vi=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Roe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return yb(t,n),Vi([I("")],t.prototype,"source",void 0),Vi([I("transparent")],t.prototype,"color",void 0),Vi([I("None")],t.prototype,"scale",void 0),Vi([I("None")],t.prototype,"align",void 0),t}(Ee),Hoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return yb(t,n),Vi([I("Page")],t.prototype,"mode",void 0),Vi([I("PageSettings")],t.prototype,"region",void 0),Vi([re({top:25,bottom:25,left:25,right:25},Jn)],t.prototype,"margin",void 0),Vi([I(!1)],t.prototype,"canZoomIn",void 0),Vi([I(void 0)],t.prototype,"customBounds",void 0),Vi([I(!1)],t.prototype,"canFit",void 0),t}(Ee),Boe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return yb(t,n),Vi([I(null)],t.prototype,"width",void 0),Vi([I(null)],t.prototype,"height",void 0),Vi([re({},Jn)],t.prototype,"margin",void 0),Vi([I("Landscape")],t.prototype,"orientation",void 0),Vi([I("Infinity")],t.prototype,"boundaryConstraints",void 0),Vi([re({},Roe)],t.prototype,"background",void 0),Vi([I(!1)],t.prototype,"multiplePage",void 0),Vi([I(!1)],t.prototype,"showPageBreaks",void 0),Vi([re({},Hoe)],t.prototype,"fitOptions",void 0),t}(Ee),Foe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return yb(t,n),Vi([I(0)],t.prototype,"horizontalOffset",void 0),Vi([I(0)],t.prototype,"verticalOffset",void 0),Vi([I(1)],t.prototype,"currentZoom",void 0),Vi([I(0)],t.prototype,"viewPortWidth",void 0),Vi([I(0)],t.prototype,"viewPortHeight",void 0),Vi([I(.2)],t.prototype,"minZoom",void 0),Vi([I(30)],t.prototype,"maxZoom",void 0),Vi([I("Diagram")],t.prototype,"scrollLimit",void 0),Vi([I()],t.prototype,"scrollableArea",void 0),Vi([I(!1)],t.prototype,"canAutoScroll",void 0),Vi([I(100)],t.prototype,"autoScrollFrequency",void 0),Vi([re({left:15,right:15,top:15,bottom:15},Jn)],t.prototype,"autoScrollBorder",void 0),Vi([re({left:0,right:0,top:0,bottom:0},Jn)],t.prototype,"padding",void 0),Vi([I(.2)],t.prototype,"zoomFactor",void 0),t}(Ee),_oe=function(){function n(){this.services={}}return n.prototype.register=function(t,e){this.services[""+t]=e},n.prototype.getService=function(t){return this.services[""+t]},n}(),$F=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),ya=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},ZF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return $F(t,n),ya([I("lightgray")],t.prototype,"lineColor",void 0),ya([I("")],t.prototype,"lineDashArray",void 0),ya([I([1.25,18.75,.25,19.75,.25,19.75,.25,19.75,.25,19.75])],t.prototype,"lineIntervals",void 0),ya([I([1,19,.5,19.5,.5,19.5,.5,19.5,.5,19.5])],t.prototype,"dotIntervals",void 0),ya([I([20])],t.prototype,"snapIntervals",void 0),t}(Ee),Uoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return $F(t,n),ya([re({},ZF)],t.prototype,"horizontalGridlines",void 0),ya([re({},ZF)],t.prototype,"verticalGridlines",void 0),ya([I(Kt.All)],t.prototype,"constraints",void 0),ya([I(5)],t.prototype,"snapAngle",void 0),ya([I("Lines")],t.prototype,"gridType",void 0),ya([I(5)],t.prototype,"snapObjectDistance",void 0),ya([I("#07EDE1")],t.prototype,"snapLineColor",void 0),t}(Ee),JF=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),el=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},KF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return JF(t,n),el([I(5)],t.prototype,"interval",void 0),el([I(100)],t.prototype,"segmentWidth",void 0),el([I("Horizontal")],t.prototype,"orientation",void 0),el([I("RightOrBottom")],t.prototype,"tickAlignment",void 0),el([I("red")],t.prototype,"markerColor",void 0),el([I(25)],t.prototype,"thickness",void 0),el([I(null)],t.prototype,"arrangeTick",void 0),t}(Ee),joe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return JF(t,n),el([I(!1)],t.prototype,"showRulers",void 0),el([I(!0)],t.prototype,"dynamicGrid",void 0),el([re({orientation:"Horizontal"},KF)],t.prototype,"horizontalRuler",void 0),el([re({orientation:"Vertical"},KF)],t.prototype,"verticalRuler",void 0),t}(Ee),Voe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),e_=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Woe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Voe(t,n),e_([I("")],t.prototype,"property",void 0),e_([I("")],t.prototype,"field",void 0),t}(Ee),ET=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),ln=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},t_=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return ET(t,n),ln([I("")],t.prototype,"read",void 0),ln([I("")],t.prototype,"create",void 0),ln([I("")],t.prototype,"update",void 0),ln([I("")],t.prototype,"destroy",void 0),ln([I()],t.prototype,"customFields",void 0),t}(Ee),Yoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return ET(t,n),ln([I("")],t.prototype,"id",void 0),ln([I("")],t.prototype,"sourceID",void 0),ln([I("")],t.prototype,"targetID",void 0),ln([I(null)],t.prototype,"sourcePointX",void 0),ln([I(null)],t.prototype,"sourcePointY",void 0),ln([I(null)],t.prototype,"targetPointX",void 0),ln([I(null)],t.prototype,"targetPointY",void 0),ln([I(null)],t.prototype,"dataManager",void 0),ln([re({},t_)],t.prototype,"crudAction",void 0),t}(Ee),Qoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return ET(t,n),ln([I("")],t.prototype,"id",void 0),ln([I(null)],t.prototype,"dataManager",void 0),ln([I(null)],t.prototype,"dataSource",void 0),ln([I("")],t.prototype,"root",void 0),ln([I("")],t.prototype,"parentId",void 0),ln([I()],t.prototype,"doBinding",void 0),ln([Bt([],Woe)],t.prototype,"dataMapSettings",void 0),ln([re({},t_)],t.prototype,"crudAction",void 0),ln([re({},Yoe)],t.prototype,"connectionDataSource",void 0),t}(Ee),i_=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Cr=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Goe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return i_(t,n),Cr([I("LeftInFlow")],t.prototype,"yesBranchDirection",void 0),Cr([I("RightInFlow")],t.prototype,"noBranchDirection",void 0),Cr([I(["Yes","True"])],t.prototype,"yesBranchValues",void 0),Cr([I(["No","False"])],t.prototype,"noBranchValues",void 0),t}(Ee),Xoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return i_(t,n),Cr([I("")],t.prototype,"fixedNode",void 0),Cr([I(30)],t.prototype,"horizontalSpacing",void 0),Cr([I("SamePoint")],t.prototype,"connectionPointOrigin",void 0),Cr([I("Nonlinear")],t.prototype,"arrangement",void 0),Cr([I(30)],t.prototype,"verticalSpacing",void 0),Cr([I(30)],t.prototype,"maxIteration",void 0),Cr([I(40)],t.prototype,"springFactor",void 0),Cr([I(50)],t.prototype,"springLength",void 0),Cr([re({left:50,top:50,right:0,bottom:0},Jn)],t.prototype,"margin",void 0),Cr([I("Auto")],t.prototype,"horizontalAlignment",void 0),Cr([I("Auto")],t.prototype,"verticalAlignment",void 0),Cr([I("TopToBottom")],t.prototype,"orientation",void 0),Cr([I("Auto")],t.prototype,"connectionDirection",void 0),Cr([I("Default")],t.prototype,"connectorSegments",void 0),Cr([I("None")],t.prototype,"type",void 0),Cr([I()],t.prototype,"getLayoutInfo",void 0),Cr([I()],t.prototype,"layoutInfo",void 0),Cr([I()],t.prototype,"getBranch",void 0),Cr([I()],t.prototype,"bounds",void 0),Cr([I(!0)],t.prototype,"enableAnimation",void 0),Cr([I(!1)],t.prototype,"enableRouting",void 0),Cr([I("")],t.prototype,"root",void 0),Cr([re({},Goe)],t.prototype,"flowchartLayoutSettings",void 0),t}(Ee),qoe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),r_=function(n){function t(e,i){var r=n.call(this,e,!0)||this;return r.oldValue=null,r.endPoint=i,r}return qoe(t,n),t.prototype.mouseDown=function(e){var i,r=!0;if(e.source&&e.source.connectors&&(i=e.source.connectors[0]),e.info&&e.actualObject&&(r=e.info.ctrlKey&&"Orthogonal"!==e.actualObject.type),i&&r){this.inAction=!0,this.undoElement=$(e.source),n.prototype.mouseDown.call(this,e);for(var s=0;s0)1!==s&&this.removePrevSegment(i,s);else if(a){var l=R.distancePoints(a.points[0],a.points[1]);Math.abs(a.length||0===a.length?a.length:l)<=5&&this.removeNextSegment(i,s)}this.commandHandler.updateEndPoint(i,r),i.selectedSegmentIndex=0}if(this.undoElement){var c=$(e.source);this.commandHandler.addHistoryEntry({type:"SegmentChanged",redoObject:c,undoObject:this.undoElement,category:"Internal"})}if(i.isBezierEditing&&(i.isBezierEditing=!1),this.prevPosition!==this.startPosition){var u={source:i,state:"Completed",oldValue:this.oldValue,newValue:$(this.selectedSegment),cancel:!1,segment:this.selectedSegment};this.commandHandler.triggerEvent(Ce.segmentChange,u)}n.prototype.mouseUp.call(this,e)},t.prototype.removePrevSegment=function(e,i){var r=e.segments[i-2],s=e.segments[i+1];if(s&&!((s.length||0===s.length?s.length:R.distancePoints(s.points[0],s.points[1]))<=5)){var a=e.segments.slice(i-1,i+1),l={element:e,removeSegments:a,type:"Removal",cancel:!1};if(this.commandHandler.triggerEvent(Ce.segmentCollectionChange,l),!l.cancel){var h=e.segments[i+1];e.segments.splice(i-1,2);var c=this.selectedSegment;"Left"===c.direction||"Right"===c.direction?(r.points[r.points.length-1].x=h.points[0].x,h.points[0].y=r.points[r.points.length-1].y):(r.points[r.points.length-1].y=h.points[0].y,h.points[0].x=r.points[r.points.length-1].x),(c.length||0===c.length)&&this.findSegmentDirection(r),this.findSegmentDirection(h)}}},t.prototype.findSegmentDirection=function(e){e.direction&&(e.length||0===e.length)&&(e.length=R.distancePoints(e.points[0],e.points[e.points.length-1]),e.direction=R.direction(e.points[0],e.points[e.points.length-1]))},t.prototype.removeNextSegment=function(e,i){var l,h,r=this.selectedSegment,s=e.segments[i-1],o=e.segments[i+2],a=e.segments[i+1];if(a.length||0===a.length?(l=e.segments.slice(i,2),h={element:e,removeSegments:l,type:"Removal",cancel:!1},this.commandHandler.triggerEvent(Ce.segmentCollectionChange,h={element:e,removeSegments:l,type:"Removal",cancel:!1}),h.cancel||(e.segments.splice(i,2),"Top"===r.direction||"Bottom"===r.direction?(o.points[0].y=r.points[0].y,s.points[s.points.length-1].x=o.points[0].x):(o.points[0].x=r.points[0].x,s.points[s.points.length-1].y=o.points[0].y))):(l=e.segments.slice(i+1,1),this.commandHandler.triggerEvent(Ce.segmentCollectionChange,h={element:e,removeSegments:l,type:"Removal",cancel:!1}),h.cancel||(e.segments.splice(i+1,1),"Top"===r.direction||"Bottom"===r.direction?s.points[s.points.length-1].x=a.points[a.points.length-1].x:s.points[s.points.length-1].y=a.points[a.points.length-1].y,this.findSegmentDirection(s),r.length=r.direction=null)),s&&o&&!h.cancel&&(s.length=R.distancePoints(s.points[0],o.points[0]),s.direction=R.direction(s.points[0],o.points[0]),o.length||0===o.length)){o.length=R.distancePoints(s.points[s.points.length-1],o.points[o.points.length-1]);var c=s.points,d=o.points;o.direction=R.direction(c[c.length-1],d[d.length-1])}},t.prototype.addOrRemoveSegment=function(e,i,r){for(var s,o,a=[],l={segments:e.segments},h=0;h0?"Bottom":"Top":r>0?"Right":"Left",length:i.points[0].x===i.points[1].x?s:r},!0)),l.push(new wi(e,"segments",{type:"Orthogonal",direction:c,length:h/2},!0));var f={element:e,addSegments:l,type:"Addition",cancel:!1};return this.commandHandler.triggerEvent(Ce.segmentCollectionChange,f),f.cancel||(e.segments=l.concat(e.segments),a=o+2),a},t.prototype.insertFirstSegment=function(e,i,r,s,o){var a,l,d,u,h=[];if(e.sourcePortID&&i.length&&e.segments[0].points.length>2)for(var f=void 0,p=0;p0?"Bottom":"Top":r>0?"Right":"Left"),f=u,h.push(u)}else h.push(new wi(e,"segments",{type:"Orthogonal",direction:i.direction,length:i.length/3},!0)),"Bottom"===i.direction||"Top"===i.direction?(l=Math.abs(r),a=r>0?"Right":"Left"):(l=Math.abs(s),a=s>0?"Bottom":"Top"),u=new wi(e,"segments",{type:"Orthogonal",direction:a,length:l},!0),h.push(u);var y={element:e,addSegments:h,type:"Addition",cancel:!1};if(this.commandHandler.triggerEvent(Ce.segmentCollectionChange,y),!y.cancel){if(e.sourcePortID&&i.length&&e.segments[0].points.length>2)e.segments.splice(0,1),d=1;else{var S=e.segments[1];S&&S.length&&(S.length=a!==S.direction?S.length+l:S.length-l),d=2,i.length=2*i.length/3}e.segments=h.concat(e.segments)}return d},t.prototype.updateAdjacentSegments=function(e,i,r,s){var o=e.segments[parseInt(i.toString(),10)],a=o.points[o.points.length-1],h=!0;"Orthogonal"===o.type&&(o.points[0]=o.points[0],o.points[o.points.length-1]=a,e.segments[i-1]&&(h=this.updatePreviousSegment(r,s,e,i)),e.segments.length-1>i&&h&&this.updateNextSegment(e,o,e.segments[i+1],r,s))},t.prototype.addTerminalSegment=function(e,i,r,s,o){var l,h,c,d,a=e.segments.indexOf(i),u=[],f=e.segments.pop(),p=e.segments[e.segments.length-1];l=p&&"Orthogonal"===p.type?p:null;for(var g=0;g0&&"Left"===o.direction?c.middleLeft:c.middleRight,o.length>c.width/2?Math.abs(a.length)0&&"Top"===o.direction?c.topCenter:c.bottomCenter,o.length>c.height/2?Math.abs(a.length)1)for(var a=0,l=this.diagram.views;a0)for(var e=t===Ce.onUserHandleMouseLeave?this.previousAction:this.action,i={element:void 0},r=0;r0)for(var r={element:void 0},s=void 0,o=void 0,a=0;a-1&&(o=s,this.previousTarget=i,this.targetItem=e),o===e.fixedUserHandles[parseInt(a.toString(),10)].id&&(r.element=e.fixedUserHandles[parseInt(a.toString(),10)],this.userHandle(t,a,r,e))},n.prototype.mouseDown=function(t){var e=this;if("touchstart"===t.type&&(this.timeOutTapHold=setTimeout(function(){("Select"===e.action||"Drag"===e.action)&&e.mouseMove(t,void 0)},500)),!0!==this.inAction||!(this.tool instanceof ZI||this.tool instanceof pa)){this.focus=!0;var i=t.touches,r=!!document.getElementsByClassName("e-dragclone")[0];if(this.isMouseOnScrollBar(t)&&!r)return this.isScrolling=!0,void t.preventDefault();if(this.checkFixedUserHandleEvent(Ce.onFixedUserHandleMouseDown,this.targetItem,this.previousTarget),this.checkUserHandleEvent(Ce.onUserHandleMouseDown),!this.checkEditBoxAsTarget(t)&&Yv(this.diagram)||Oc(this.diagram)&&!VI(this.diagram))if(("Select"===this.action||"Drag"===this.action)&&this.diagram.updatePortVisibility(this.hoverElement,ci.Hover,!0),!(this.tool instanceof Rl||this.tool instanceof Hl)||2!==t.button&&2!==t.buttons)if(!0===this.inAction&&!0===this.isMouseDown&&(this.tool instanceof Rl||this.tool instanceof Hl))this.isMouseDown=!0,this.eventArgs={},this.getMouseEventArgs(this.currentPosition,this.eventArgs),this.eventArgs.position=this.currentPosition,this.tool.mouseDown(this.eventArgs);else{this.isMouseDown=!0,this.currentPosition=this.prevPosition=this.getMousePosition(t),this.eventArgs={},this.diagram.textEditing&&!this.isMouseOnScrollBar(t)&&(this.diagram.endEdit(),this.diagram.textEditing=!1,"Canvas"===this.diagram.mode&&1!==this.diagram.scroller.currentZoom&&this.diagram.refreshDiagramLayer());var o=this.getTargetElement();this.action=this.diagram.findActionToBeDone(o.obj,o.sourceElement,this.currentPosition,o.target);var a=this.isMetaKey(t);a&&t.shiftKey&&this.diagram.connectorEditingToolModule?this.action="SegmentEnd":(a||t.shiftKey)&&(Vv(this.diagram)||Wv(this.diagram))&&(this.action="Select"),this.tool=this.diagram.getTool(this.action),this.tool||(this.action="Select",this.tool=this.diagram.getTool(this.action)),this.getMouseEventArgs(this.currentPosition,this.eventArgs),(a||t.shiftKey)&&(this.eventArgs.info=a&&t.shiftKey?{ctrlKey:a,shiftKey:t.shiftKey}:{ctrlKey:!0}),this.eventArgs.position=this.currentPosition;var h=this.diagram.selectedItems.nodes;if(this.tool.mouseDown(this.eventArgs),this.diagram.selectedItems.canToggleSelection&&h&&this.diagram.selectedItems.nodes&&this.tool instanceof fa)for(var c=0;c=2&&(this.touchStartList=VF(this.touchStartList,0,i)),i||t.preventDefault())}else this.inAction=!1,this.tool.mouseUp(this.eventArgs);!this.isForeignObject(t.target)&&!this.isForeignObject(t.target,!0)&&!i&&t.preventDefault()}},n.prototype.mouseMoveExtend=function(t,e){(this.tool instanceof Rl||this.tool instanceof Hl)&&this.tool.mouseMove(this.eventArgs),this.diagram.scrollSettings.canAutoScroll?this.checkAutoScroll(t):this.blocked||this.tool.mouseMove(this.eventArgs),this.eventArgs.target&&(this.hoverElement=this.eventArgs.target);var i=!((this.eventArgs.target instanceof te||this.eventArgs.target instanceof de)&&(e instanceof te||e instanceof de));this.tool instanceof Rd&&this.diagram.updatePortVisibility(this.hoverElement instanceof te||this.hoverElement instanceof de?this.hoverElement:this.hoverNode,ci.Connect|ci.Hover,i),this.hoverElement instanceof te&&this.hoverNode instanceof te&&this.hoverNode&&this.hoverNode.id!==this.hoverElement.id&&this.diagram.updatePortVisibility(this.hoverNode,ci.Connect|ci.Hover,!0),this.hoverElement instanceof de&&this.hoverElement.ports.length>0&&this.diagram.updatePortVisibility(this.hoverElement,ci.Connect|ci.Hover,!0),this.previousElement instanceof te&&this.hoverElement&&this.previousElement.id!==this.hoverElement.id&&this.diagram.updatePortVisibility(this.previousElement,ci.Connect|ci.Hover,!0),this.previousElement=this.hoverElement,""!==this.diagram.tooltip.content&&(this.hoverElement=null),this.hoverNode=i?null:e},n.prototype.checkAction=function(t){if("LabelSelect"===this.action&&this.eventArgs.sourceWrapper&&(this.eventArgs.sourceWrapper instanceof ai||this.eventArgs.sourceWrapper instanceof es)){var e=this.commandHandler.findTarget(this.eventArgs.sourceWrapper,this.eventArgs.source);!_r(this.diagram,e,!1,this.eventArgs.sourceWrapper)&&ro(e)&&(this.action="LabelDrag",this.tool=this.getTool(this.action),this.tool.mouseDown(this.initialEventArgs))}else ro(t)&&Ld(t)&&this.initialEventArgs&&this.initialEventArgs.source&&"Select"===this.action&&(!_r(this.diagram,this.eventArgs.source,!1)&&this.eventArgs.source instanceof ei&&this.getMouseEventArgs(this.currentPosition,this.eventArgs),(!(t instanceof de)||t instanceof de&&!(wr(this.currentPosition,t.sourcePoint,t.hitPadding)||wr(this.currentPosition,t.targetPoint,t.hitPadding)))&&(this.action="Drag"),this.tool=this.getTool(this.action),this.tool.mouseDown(this.initialEventArgs))},n.prototype.isSwimlaneElements=function(t){return!(t&&(t.isLane||t.isPhase||t.isHeader))},n.prototype.canShowTouchTooltip=function(t){return!!("touchstart"===t.type&&this.diagram.tool&ri.SingleSelect&&this.diagram.tool&ri.ZoomPan)&&(this.isMouseDown=!1,!0)},n.prototype.mouseMove=function(t,e){if(this.focus=!0,"touchmove"===t.type&&(this.touchArgs={target:t.target,type:"touchmove"}),this.isScrolling)t.preventDefault();else if(Yv(this.diagram)||Oc(this.diagram)&&!VI(this.diagram)){this.currentPosition=this.getMousePosition(t);var i=this.diagram.findObjectsUnderMouse(this.currentPosition),r=this.diagram.findObjectUnderMouse(i,this.action,this.inAction);!function nse(n,t){n.rulerSettings.showRulers&&(n.hRuler.drawRulerMarker(n.hRuler.element,t,n.scroller.horizontalOffset),n.vRuler.drawRulerMarker(n.vRuler.element,t,n.scroller.verticalOffset))}(this.diagram,this.currentPosition);var s=!1,o=void 0;if("touchmove"===t.type&&(e=t.touches)&&e.length>1&&(this.touchMoveList=VF(this.touchMoveList,0,e),"PinchZoom"!==this.action&&(s=!0)),!1===R.equals(this.currentPosition,this.prevPosition)||this.inAction||this.canShowTouchTooltip(t)){if(!1===this.isMouseDown||s){this.eventArgs={};var a=null,l=void 0;if(null!==r){if((a=this.diagram.findElementUnderMouse(r,this.currentPosition,this.diagram))&&(l=this.commandHandler.findTarget(a,r)),(l instanceof Kn||l instanceof Or)&&(l.tooltip&&""!==l.tooltip.content||(l=r)),l!==this.hoverElement){var h=this.getContent();this.hoverElement&&"Auto"===this.hoverElement.tooltip.openOn&&""!==h&&this.elementLeave(),this.diagram.updatePortVisibility(this.hoverElement,ci.Hover,!0),r instanceof te&&(this.hoverNode=r);var c=!0;!this.isSwimlaneElements(r)&&this.hoverElement&&this.isSwimlaneElements(this.hoverElement)&&(c=!1),this.hoverElement=c?r:this.hoverElement;var d,u=void 0;(d=this.diagram.findElementUnderMouse(r,this.currentPosition,this.diagram))instanceof Ze&&((u=this.commandHandler.findTarget(d,r))instanceof Es||u instanceof Lc)&&this.hoverElement.constraints&oi.ToolTip&&(this.hoverElement=u);var f=void 0;d instanceof ai&&((f=this.commandHandler.findTarget(d,r))instanceof Kn||f instanceof Or)&&f.constraints&Nr.Tooltip&&(this.hoverElement=f),c?this.elementEnter(this.currentPosition,!1):this.hoverElement=r}else this.hoverElement&&this.hoverElement===l&&this.hoverElement.tooltip.content&&void 0!==this.diagram.tooltipObject&&"Mouse"===this.hoverElement.tooltip.relativeMode&&this.setTooltipOffset(this.currentPosition);a&&(o=this.commandHandler.findTarget(a,r))}this.action=this.diagram.findActionToBeDone(r,a,this.currentPosition,o),this.checkFixedUserHandleEvent(Ce.onFixedUserHandleMouseEnter,r,a),this.checkUserHandleEvent(Ce.onUserHandleMouseEnter),this.checkPreviousAction(),this.getMouseEventArgs(this.currentPosition,this.eventArgs),this.tool=this.getTool(this.action),this.mouseEvents(),this.tool instanceof pa||this.tool instanceof Hl||this.tool instanceof Rl?this.tool.mouseMove(this.eventArgs):e&&this.tool instanceof im&&this.tool.mouseDown(this.eventArgs),this.updateCursor(),this.renderUmlHighLighter(this.eventArgs);var p=!1;this.hoverElement&&!(this.tool instanceof im)&&r instanceof te&&this.isSwimlaneElements(r)&&(0===this.diagram.selectedItems.nodes.length||!_r(this.diagram,this.hoverElement))||this.hoverElement instanceof de||(p=!0),this.hoverElement&&!(this.tool instanceof im)&&r instanceof de&&(0===this.diagram.selectedItems.connectors.length||!_r(this.diagram,this.hoverElement))||this.hoverElement instanceof te||(p=!0),this.diagram.updatePortVisibility(this.hoverElement,ci.Hover,p);var g=this.getContent();null===r&&this.hoverElement&&"Auto"===this.hoverElement.tooltip.openOn&&g&&(this.hoverElement=null,this.elementLeave()),s=!1}else{this.eventArgs.position=this.currentPosition,"Drag"===this.action&&!_r(this.diagram,this.eventArgs.source,!1)&&this.eventArgs.source instanceof ei&&this.getMouseEventArgs(this.currentPosition,this.eventArgs),this.mouseEvents(),(t.ctrlKey||t.shiftKey)&&(this.eventArgs.info=t.ctrlKey&&t.shiftKey?{ctrlKey:t.ctrlKey,shiftKey:t.shiftKey}:{ctrlKey:!0}),this.checkAction(r);var y=this.getConnectorPadding(this.eventArgs);this.getMouseEventArgs(this.currentPosition,this.eventArgs,this.eventArgs.source,y),this.updateCursor(),this.inAction=!0,this.initialEventArgs=null,("Drag"===this.action||"Rotate"===this.action)&&(this.diagram.diagramActions=this.diagram.diagramActions|ee.Interactions);var S=this.diagram.scroller.getPageBounds();this.mouseMoveExtend(t,r);var b=this.diagram.scroller.getPageBounds();if(r&&(S.width!==b.width||S.height!==b.height||S.x!==b.x||S.y!==b.y)&&this.diagram.views&&this.diagram.views.overview){var M=this.diagram.views.overview;M.updateView(M)}}this.prevPosition=this.currentPosition,this.isForeignObject(t.target,!0)||t.preventDefault()}}},n.prototype.getContent=function(){var i,t=this.hoverElement instanceof te&&this.hoverElement.constraints&ie.Tooltip||this.hoverElement instanceof de&&this.hoverElement.constraints&qe.Tooltip||(this.hoverElement instanceof Es||this.hoverElement instanceof Lc)&&this.hoverElement.constraints&oi.ToolTip||(this.hoverElement instanceof Kn||this.hoverElement instanceof Or)&&this.hoverElement.constraints&Nr.Tooltip,e=this.hoverElement;e instanceof te&&e.children&&e.children.length>0&&(i=this.findIntersectChild(e));var r=t?this.hoverElement.tooltip.content:this.diagram.tooltip.content;return i?i.tooltip.content:r},n.prototype.findIntersectChild=function(t){for(var e,i=new Ne(this.currentPosition.x,this.currentPosition.y,8,8),r=0;r1&&1===t.which&&!function one(n){return!!(n&ee.PreventClearSelection)}(this.diagram.diagramActions)&&(c=!1,this.commandHandler.clearSelection()),(!_r(this.diagram,h)||!c)&&(this.commandHandler.selectObjects([h],void 0,a),this.diagram.selectedItems.canToggleSelection)){var d=this.diagram.selectedItems.nodes;d?d[0].parentObj instanceof _d&&(s=!0):this.diagram.selectedItems.connectors.length>0&&(s=!0)}}var u=!1,f=this.updateContainerProperties(),p=void 0;if(this.addUmlNode(),this.inAction=!1,this.isMouseDown=!1,this.diagram.selectedObject.helperObject&&(p=this.updateContainerBounds()),this.tool&&(this.tool.prevPosition||this.tool instanceof eF)){this.eventArgs.position=this.currentPosition;var g=this.getConnectorPadding(this.eventArgs);this.getMouseEventArgs(this.currentPosition,this.eventArgs,this.eventArgs.source,g);var v=this.isMetaKey(t);if((v||t.shiftKey)&&(this.eventArgs.info=v&&t.shiftKey?{ctrlKey:v,shiftKey:t.shiftKey}:{ctrlKey:!0}),this.diagram.diagramActions&ee.Interactions&&(this.diagram.diagramActions=this.diagram.diagramActions&~ee.Interactions),this.eventArgs.clickCount=t.detail,this.diagram.selectedObject.helperObject&&(this.tool instanceof fa||this.tool instanceof Hd)){if(this.diagram.selectedObject.actualObject&&""!==this.diagram.selectedObject.actualObject.parentId){var S=this.diagram.getObject(this.diagram.selectedObject.actualObject.parentId);S&&S.isLane&&(this.commandHandler.isContainer=!0)}(u=this.diagram.lineRoutingModule&&this.diagram.nameTable.helper&&this.eventArgs.target&&this.eventArgs.target.isLane&&(this.eventArgs.source instanceof ei&&this.eventArgs.source.nodes.length>0&&""===this.eventArgs.source.nodes[0].parentId||""===this.eventArgs.source.parentId))&&(this.diagram.diagramActions=this.diagram.diagramActions|ee.PreventLaneContainerUpdate),this.tool.mouseUp(this.eventArgs,f.isPreventHistory)}else{if(this.diagram.selectedItems.canToggleSelection){var b=void 0,M=void 0;if(this.diagram.selectedItems.nodes.length>0)for(var w=0;w1&&D[0].id===i[parseInt(w.toString(),10)].id||r.length>0)&&(M=!0);!this.isSwimlaneSelected&&!s&&!M&&this.tool instanceof fa&&"Select"===this.currentAction&&(!b||this.diagram.selectedItems.connectors.length>0)&&this.commandHandler.clearSelection(!0)}this.isSwimlaneSelected=!1,this.tool.mouseUp(this.eventArgs),this.diagram.checkMenu&&(-1!==window.navigator.userAgent.indexOf("Linux")||-1!==window.navigator.userAgent.indexOf("X11"))&&(!t.pageY&&t instanceof TouchEvent&&t.changedTouches?(window.getSelection().removeAllRanges(),this.diagram.contextMenuModule.contextMenu.open(t.changedTouches[0].pageY,t.changedTouches[0].pageX,this.diagram.element),t.preventDefault()):this.diagram.contextMenuModule.contextMenu.open(t.pageY,t.pageX,this.diagram.element),this.diagram.checkMenu=!1)}f.hasStack&&this.diagram.endGroupAction()}if(p&&this.diagram.endGroupAction(),this.updateContainerBounds(!0),2!==this.eventArgs.clickCount&&(this.commandHandler.updateSelectedNodeProperties(this.eventArgs.source),u)){this.diagram.diagramActions=this.diagram.diagramActions&~ee.PreventLaneContainerUpdate;var A=this.eventArgs.source instanceof ei?this.eventArgs.source.nodes:[this.eventArgs.source];if(A)for(w=0;w0&&!N&&this.diagram.renderSelector(!0),!this.inAction&&!this.diagram.currentSymbol&&this.eventArgs){var T=this.getTargetElement();this.diagram.tool!==ri.ZoomPan&&this.diagram.triggerEvent(Ce.click,{element:T.target instanceof Es?T.target:this.eventArgs.source||this.diagram,position:this.eventArgs.position,count:t.detail,actualObject:this.eventArgs.actualObject,button:0===t.button?"Left":1===t.button?"Middle":"Right"})}this.eventArgs={}}this.diagram.diagramActions=this.diagram.diagramActions&~ee.PreventLaneContainerUpdate,e&&this.updateAnnotation(this.diagram.selectedItems),this.previousElement=null,this.eventArgs={},this.diagram.commandHandler.removeStackHighlighter()},n.prototype.isSwimlaneChild=function(t){if(t.shape&&"SwimLane"!==t.shape.type){var e=this.diagram.nameTable[t.parentId];if(!e)return!1;var i=e.parentId?this.diagram.nameTable[e.parentId]:e;return i&&i.shape&&"SwimLane"===i.shape.type}return!1},n.prototype.updateAnnotation=function(t){var e=t.nodes;if(e.length>0)for(var i=0;i0&&(a+=1),h.isPhase){l="Horizontal"===r.orientation?this.currentPosition.x-e.wrapper.bounds.x:this.currentPosition.y-(e.wrapper.bounds.y+r.header.height);var g={id:Qe(),offset:l,header:{annotation:{content:void 0===h.phases[0].header?"Phase":h.phases[0].header.annotation.content,style:void 0===h.phases[0].header?{}:h.phases[0].header.annotation.style}},style:void 0===h.phases[0]?{}:h.phases[0].style};this.diagram.addPhases(e,[g])}else{var v={id:Qe(),style:h.lanes[0].style,header:{annotation:{content:h.lanes[0].header.annotation.content,style:h.lanes[0].header.annotation.style},style:h.lanes[0].header.style}};if("Horizontal"===h.orientation?v.height=h.lanes[0].height:v.width=h.lanes[0].width,"Horizontal"===r.orientation?(s=i.rowIndex?i.rowIndex:this.diagram.nameTable[i.parentId].rowIndex,i.wrapper.offsetYs)v.header.width=r.lanes[parseInt(s.toString(),10)].header.width,v.header.height=r.lanes[parseInt(s.toString(),10)].header.height;else{var S=void 0;S="Horizontal"===r.orientation?i.rowIndex<3?0:s-a-1:s-1,v.header.width=r.lanes[parseInt(S.toString(),10)].header.width,v.header.height=r.lanes[parseInt(S.toString(),10)].header.height}p&&("height"===p?(v.width=v.height,delete v.height):(v.height=v.width,delete v.width)),this.diagram.addLanes(e,[v],"Horizontal"===r.orientation?s-a:s)}this.commandHandler.select(e)}else if(h.isLane){var b={id:Qe(),width:t.width,height:t.height,addInfo:t.addInfo,shape:{type:"SwimLane",header:{annotation:{content:void 0===h.header?"Header":h.header.annotation.content,style:void 0===h.header?{}:h.header.annotation.style},height:50,style:h.header?h.header.style:h.lanes[0].header.style},phases:[{id:Qe(),header:{annotation:{content:void 0===h.phases||void 0===h.phases[0].header?"Phase":h.phases[0].header.annotation.content,style:void 0===h.phases||void 0===h.phases[0].header?{}:h.phases[0].header.annotation.style},style:void 0===h.phases||void 0===h.phases[0].header?{}:h.phases[0].header.style},style:void 0===h.phases?{}:h.phases[0].style}],lanes:[{id:Qe(),height:t.height,width:t.width,style:h.lanes[0].style,header:{annotation:{content:h.lanes[0].header.annotation.content,style:h.lanes[0].header.annotation.style},style:h.lanes[0].header.style}}],orientation:h.orientation}};"Vertical"===h.orientation&&(b.width+=20),b.offsetX=this.currentPosition.x+b.width/2,b.offsetY=this.currentPosition.y+b.height/2,b.style=t.style,this.diagram.add(b)}},n.prototype.mouseLeave=function(t){this.tool&&this.inAction&&this.tool.mouseLeave(this.eventArgs),this.diagram.selectedObject.helperObject&&(this.updateContainerProperties(),this.updateContainerBounds()&&this.diagram.endGroupAction()),this.eventArgs&&this.eventArgs.source&&(this.diagram.updatePortVisibility(this.eventArgs.source,ci.Hover,!0),this.hoverElement=null),this.eventArgs&&!this.eventArgs.source&&this.hoverElement&&(this.hoverElement=null),this.tool instanceof Rd&&this.eventArgs&&this.eventArgs.target&&this.eventArgs.target instanceof te&&(this.diagram.updatePortVisibility(this.eventArgs.target,ci.Hover|ci.Connect,!0),this.hoverElement=null);var i=this.diagram.selectedItems;i&&i.wrapper&&(cm(this.diagram,i)||this.diagram.renderSelector(!0)),(this.diagram.diagramActions&ee.Interactions||this.diagram.diagramActions&ee.ToolAction)&&(this.diagram.diagramActions=this.diagram.diagramActions&~ee.ToolAction),this.isMouseDown=!1,this.focus=!1,this.touchStartList=null,this.touchMoveList=null,this.elementLeave(),this.commandHandler.removeSnap(),this.inAction=!1,this.eventArgs={},this.diagram.selectedObject&&this.diagram.selectedObject.helperObject&&(this.diagram.remove(this.diagram.selectedObject.helperObject),this.diagram.selectedObject={helperObject:void 0,actualObject:void 0}),this.tool=null,function rse(){var t,e,n=document.getElementsByClassName("e-d-ruler-marker");if(n&&n.length>0)for(e=n.length-1;e>=0;e--)(t=n[parseInt(e.toString(),10)])&&t.parentNode.removeChild(t)}(),"Rotate"===this.action&&this.diagram.diagramCanvas.classList.remove("e-diagram-rotate"),t.preventDefault()},n.prototype.mouseWheel=function(t){this.diagram.blazorActions|=on.interaction;var e={event:t,cancel:!1};if(this.diagram.triggerEvent(Ce.mouseWheel,e),!e.cancel){var i=t.wheelDelta>0||-40*t.detail>0,r=this.getMousePosition(t);if(this.diagram.tooltipObject.close(),this.isMetaKey(t)){var o=this.diagram.scrollSettings.zoomFactor;this.diagram.zoomTo(i?{type:"ZoomIn",zoomFactor:o,focusPoint:r}:{type:"ZoomOut",zoomFactor:o,focusPoint:r}),t.preventDefault()}else{var a=this.diagram.scroller.horizontalOffset,l=this.diagram.scroller.verticalOffset,h=i?10:-10;this.tool&&(this.tool instanceof Rl||this.tool instanceof Hl)&&(this.eventArgs={},this.getMouseEventArgs(r,this.eventArgs),this.eventArgs.position=r,this.tool.mouseWheel(this.eventArgs)),this.diagram.scrollActions|=da.Interaction;var c=!0;if(t.isTrusted){var d=!1;(Math.abs(t.deltaY)<100&&-0===Math.abs(t.deltaX)||Math.abs(t.deltaX)<100&&-0===Math.abs(t.deltaY))&&(d=!0);var u=!1;(0!==t.deltaX||0!==t.deltaY)&&(u=navigator.userAgent.includes("Macintosh")),u?Math.abs(t.deltaX)>Math.abs(t.deltaY)?(t.shiftKey||t.deltaX&&-0!==t.deltaX&&(d||!u))&&this.diagram.scroller.zoom(1,h,0,r,c,void 0,d):t.deltaY&&-0!==t.deltaY&&(d||!u)&&this.diagram.scroller.zoom(1,0,h,r,c,void 0,d):t.shiftKey||t.deltaX&&-0!==t.deltaX&&(d||!u)?this.diagram.scroller.zoom(1,h,0,r,c,void 0,d):t.deltaY&&-0!==t.deltaY&&(d||!u)&&this.diagram.scroller.zoom(1,0,h,r,c,void 0,d)}else t.shiftKey||t.deltaX&&-0!==t.deltaX?this.diagram.scroller.zoom(1,h,0,r,c):this.diagram.scroller.zoom(1,0,h,r,c);this.diagram.scrollActions&=~da.Interaction,(a!==this.diagram.scroller.horizontalOffset||l!==this.diagram.scroller.verticalOffset)&&t.preventDefault()}if(this.diagram.textEditing){if(this.diagram.isTriggerEvent=!0,this.diagram.activeLabel.parentId){var p=this.diagram.getObject(this.diagram.activeLabel.parentId);this.diagram.startTextEdit(p,this.diagram.activeLabel.id)}this.diagram.isTriggerEvent=!1}this.diagram.blazorActions=this.diagram.blazorActions&~on.interaction}},n.prototype.keyDown=function(t){if(t.fromMouseEvents&&(t.ctrlKey&&(this.keyArgs.keyModifiers=1),t.shiftKey&&(this.keyArgs.keyModifiers=4),t.shiftKey&&t.ctrlKey&&(this.keyArgs.keyModifiers=5)),!(this.diagram.diagramActions&ee.TextEdit)&&!this.checkEditBoxAsTarget(t)||"Escape"===t.key||27===t.keyCode){var i=void 0,r=t.keyCode?t.keyCode:t.which,s=t.key;("ArrowDown"===s||"ArrowUp"===s||"ArrowLeft"===s||"ArrowRight"===s)&&(this.isNudgeKey=!0);var o=this.isMetaKey(t);if(this.diagram.commandManager&&this.diagram.commands)for(var l=0,h=Object.keys(this.diagram.commands);l4&&(S({keyDownEventArgs:KeyboardEvent,parameter:i.parameter,type:"KEYDOWN"}),this.keyCount=0,this.keyArgs.newValue={offsetX:this.diagram.selectedItems.offsetX,offsetY:this.diagram.selectedItems.offsetY},this.diagram.triggerEvent(Ce.positionChange,this.keyArgs))),this.isKeyUp=!1):S({keyDownEventArgs:KeyboardEvent,parameter:i.parameter})}break}}}}this.keyArgs={element:this.diagram.selectedItems,key:t.key,keyCode:t.keyCode?t.keyCode:t.which},this.getKeyModifier(this.keyArgs,t),this.diagram.diagramActions&ee.TextEdit&&this.getlabel(this.keyArgs,t),this.diagram.triggerEvent(Ce.keyDown,this.keyArgs)},n.prototype.getlabel=function(t,e){var i=this.diagram.activeLabel;t.target=this.diagram.element.id+"_editBox";var r=this.diagram.nameTable[i.parentId];if(document.getElementById(this.diagram.element.id+"_editBox")){t.text=document.getElementById(this.diagram.element.id+"_editBox").value;for(var s=0;s=this.diagram.scroller.viewPortWidth-18?r="right":e.x+this.diagram.scroller.horizontalOffsetthis.diagram.scroller.viewPortHeight-18?r="bottom":e.y+this.diagram.scroller.verticalOffset0&&(s=this.findIntersectChild(this.hoverElement)),"Auto"===this.hoverElement.tooltip.openOn&&""!==r&&Dx(this.diagram,s||(i?this.hoverElement:void 0)),this.hoverElement.tooltip.content&&("Mouse"===this.hoverElement.tooltip.relativeMode?this.setTooltipOffset(t):(this.diagram.tooltipObject.offsetX=0,this.diagram.tooltipObject.offsetY=0));var o=this.diagram.findObjectsUnderMouse(this.currentPosition),a=this.diagram.findObjectUnderMouse(o,this.action,this.inAction);if(null!==a){var l=void 0;this.hoverElement.tooltip.isSticky&&(this.diagram.tooltipObject.isSticky=!0),a instanceof te&&a.children&&a.children.length>0&&(a=s||a),l=a.ports&&(this.hoverElement instanceof Es||this.hoverElement instanceof Lc)||a.annotations&&(this.hoverElement instanceof Kn||this.hoverElement instanceof Or)?document.getElementById(a.id+"_"+this.hoverElement.id):document.getElementById(a.id+(a.shape&&a.shape instanceof dm?"_content_native_element":"_groupElement")),"Auto"===this.hoverElement.tooltip.openOn&&""!==r&&(this.diagram.tooltipObject.close(),this.diagram.tooltipObject.openOn=this.hoverElement.tooltip.openOn,this.diagram.tooltipObject.dataBind()),function Kre(n,t){var e=0;return n instanceof de?n.constraints&qe.Tooltip?e=n.constraints&qe.Tooltip:n.constraints&qe.InheritTooltip&&(e=t.constraints&nt.Tooltip):n instanceof Es||n instanceof Lc?n.constraints&oi.ToolTip?e=n.constraints&oi.ToolTip:n.constraints&oi.InheritTooltip&&(e=t.constraints&nt.Tooltip):n instanceof Kn||n instanceof Or?n.constraints&Nr.Tooltip&&(e=n.constraints&Nr.Tooltip):n.constraints&ie.Tooltip?e=n.constraints&ie.Tooltip:n.constraints&ie.InheritTooltip&&(e=t.constraints&nt.Tooltip),e}(this.hoverElement,this.diagram)&&"Auto"===this.hoverElement.tooltip.openOn&&(this.diagram.tooltipObject.target=this.hoverElement.id,this.diagram.tooltipObject.open("Mouse"===this.hoverElement.tooltip.relativeMode?this.diagram.element:l))}}},n.prototype.elementLeave=function(){this.diagram.tooltipObject&&!this.diagram.tooltipObject.isSticky&&"Custom"!==this.diagram.tooltipObject.openOn&&this.diagram.tooltipObject.close()},n.prototype.setTooltipOffset=function(t){var e=function Mse(n,t,e,i){var o="Mouse"===(!(e instanceof te?e.constraints&ie.InheritTooltip:e instanceof de?e.constraints&qe.InheritTooltip:e.constraints&oi.InheritTooltip)&&(e instanceof te?e.constraints&ie.Tooltip:e instanceof de?e.constraints&qe.Tooltip:e.constraints&oi.ToolTip)?e.tooltip.relativeMode:n.tooltip.relativeMode);"Mouse"===i?o=!0:"Object"===i&&(o=!1);var a=function wse(n,t,e,i){var o,r={},s=document.getElementById(e.element.id);if(n instanceof te||n instanceof de)o=n.wrapper.bounds;else{var a=e.findObjectsUnderMouse(t),l=e.findObjectUnderMouse(a,"Select",!1);o=e.findElementUnderMouse(l,t,e).bounds}var c=s.getBoundingClientRect();switch(e.tooltipObject.position){case"BottomCenter":r=Hc(t,o.bottomCenter,e,i,c.width/2,c.height);break;case"BottomLeft":case"LeftBottom":r=Hc(t,o.bottomLeft,e,i,0,c.height);break;case"BottomRight":case"RightBottom":r=Hc(t,o.bottomRight,e,i,c.width,c.height);break;case"LeftCenter":r=Hc(t,o.middleLeft,e,i,0,c.height/2);break;case"LeftTop":case"TopLeft":r=Hc(t,o.topLeft,e,i,0,0);break;case"RightCenter":r=Hc(t,o.middleRight,e,i,c.width,c.height/2);break;case"RightTop":case"TopRight":r=Hc(t,o.topRight,e,i,c.width,0);break;case"TopCenter":r=Hc(t,o.topCenter,e,i,c.width/2,0)}return r}(e,t,n,o),l=Za(n);return{x:a.x+l.width,y:a.y+l.height}}(this.diagram,t,this.hoverElement);this.diagram.tooltipObject.offsetX=e.x,this.diagram.tooltipObject.offsetY=e.y},n.prototype.altKeyPressed=function(t){return!!(t&ft.Alt)},n.prototype.ctrlKeyPressed=function(t){return!!(t&ft.Control)},n.prototype.shiftKeyPressed=function(t){return!!(t&ft.Shift)},n.prototype.scrolled=function(t){this.diagram.updateScrollOffset()},n.prototype.isMobileOrIPadDevice=function(){var t=navigator.userAgent||navigator.vendor||window.opera;return/iPhone|iPad|iPod/.test(t)&&!window.MSStream?"iOS":/android/i.test(t)?"Android":/Mobile|Tablet/.test(t)?"Mobile":"Desktop"},n.prototype.doubleClick=function(t){if(Yv(this.diagram)){var e=this.isMobileOrIPadDevice(),i=this.diagram.tool;"Desktop"!==e&&this.tool&&(this.tool instanceof Rl||this.tool instanceof Hl)&&(this.diagram.tool=0);var r=void 0,s=this.diagram.findObjectsUnderMouse(this.currentPosition),o=this.diagram.findObjectUnderMouse(s,this.action,this.inAction);if(null!==o&&Yv(this.diagram))if(r=this.diagram.findElementUnderMouse(o,this.currentPosition,this.diagram),this.tool&&(this.tool instanceof Rl||this.tool instanceof Hl))this.diagram.tool=i,this.tool.mouseUp(this.eventArgs),this.isMouseDown=!1,this.eventArgs={},this.tool=null,t.preventDefault();else{var l=this.diagram.commandHandler.getObjectLayer(o.id);!l||l.lock||!l.visible||this.diagram.diagramActions&ee.TextEdit||this.diagram.startTextEdit(o,r instanceof ai?r.id.split(o.id+"_")[1]:void 0)}this.diagram.triggerEvent(Ce.doubleClick,{source:o||this.diagram,position:this.currentPosition,count:t.detail})}},n.prototype.itemClick=function(t,e){var i=t;return Dn(this.diagram,i,!0)?i:null},n.prototype.inputChange=function(t){var i,s,o,a,l,h,c,d,u,f=document.getElementById(this.diagram.element.id+"_editBox"),p=document.getElementById(this.diagram.element.id+"_editTextBoxDiv"),g=f.value,v=g.split("\n");(!(a=this.diagram.selectedItems.nodes[0]?this.diagram.selectedItems.nodes[0]:this.diagram.selectedItems.connectors[0])&&this.tool instanceof JI||a&&"SwimLane"===a.shape.type)&&(a=this.diagram.nameTable[this.diagram.activeLabel.parentId]),a&&("Text"!==a.shape.type&&a.annotations.length>0||"Text"===a.shape.type)&&(c=HF((o=this.diagram.getWrapper(a.wrapper,this.diagram.activeLabel.id)).style,g,void 0,void 0,i=(i=a.wrapper.bounds.width90?i:90),s=Number(f.style.fontSize.split("px")[0]),v.length>1&&""===v[v.length-1]&&(c.height=c.height+s),d=this.diagram.scroller.transform,u=P3(this.diagram)?d.scale:1,l=(12>c.height?12:c.height)*u,p.style.left=(o.bounds.center.x+d.tx)*d.scale-(h=(90>(h=c.width)?90:h)*u)/2-2.5+"px",p.style.top=(o.bounds.center.y+d.ty)*d.scale-l/2-3+"px",p.style.width=h+"px",p.style.height=l+"px",f.style.minHeight="12px",f.style.minWidth="90px",f.style.width=h+"px",f.style.height=l+"px")},n.prototype.isAddTextNode=function(t,e){return!(!(this.tool instanceof JI||e)||(this.tool=null,t&&!jI(this.diagram)&&(this.diagram.drawingObject=void 0,this.diagram.currentDrawingObject=void 0),MF(this.diagram.nodes,t.id)||MF(this.diagram.connectors,t.id)))},n.prototype.checkEditBoxAsTarget=function(t){return!(!t.target||t.target.id!==this.diagram.element.id+"_editBox")},n.prototype.getMouseEventArgs=function(t,e,i,r){var s,o,a;if(e.position=t,i?(o=this.diagram.findObjectsUnderMouse(this.currentPosition,i),s=this.diagram.findTargetObjectUnderMouse(o,this.action,this.inAction,e.position,i)):"Drag"===this.action||"ConnectorSourceEnd"===this.action||"SegmentEnd"===this.action||"OrthoThumb"===this.action||"BezierSourceThumb"===this.action||"BezierTargetThumb"===this.action||"ConnectorTargetEnd"===this.action||-1!==this.action.indexOf("Rotate")||-1!==this.action.indexOf("Resize")?(s=this.diagram.selectedItems,!this.diagram.currentSymbol&&"Drag"===this.action&&s&&this.diagram.selectedItems.nodes.length>0&&"SwimLane"===this.diagram.selectedItems.nodes[0].shape.type&&(o=this.diagram.findObjectsUnderMouse(this.currentPosition),s=this.diagram.findObjectUnderMouse(o,this.action,this.inAction))):(o=this.diagram.findObjectsUnderMouse(this.currentPosition),s=this.diagram.findObjectUnderMouse(o,this.action,this.inAction)),s&&s.isHeader&&(this.eventArgs.actualObject=s=this.diagram.nameTable[s.parentId]),s){var l=void 0,h=void 0,c=void 0;if(((a=this.diagram.findElementUnderMouse(s,this.currentPosition,this.diagram,r))&&s.ports&&s.ports.length&&!cb(s,a)||!a||!s)&&o&&o.length&&i instanceof ei)for(l=i.connectors[0],c=o.length-1;c>=0;c--)if(((h=o[parseInt(c.toString(),10)])instanceof te||h instanceof de)&&l&&l.connectionPadding){if(a=this.diagram.findElementUnderMouse(s=h,this.currentPosition,this.diagram,r),l.constraints&qe.ConnectToNearByPort&&s&&s.ports&&s.ports.length&&cb(s,a))break;if((h instanceof te||h instanceof de)&&l&&l.connectionPadding&&h.wrapper.outerBounds.containsPoint(this.currentPosition)&&l.constraints&qe.ConnectToNearByNode&&!(l.constraints&qe.ConnectToNearByPort)){a=this.diagram.findElementUnderMouse(s=h,this.currentPosition,this.diagram,0);break}}}return i?(e.target=s,e.targetWrapper=a):(e.source=s,e.sourceWrapper=a),e.actualObject=this.eventArgs.actualObject,e.source instanceof ei&&void 0===e.actualObject&&(e.source.nodes.length>0||e.source.connectors.length>0)&&(e.actualObject=e.source.nodes.length>0?this.diagram.nameTable[e.source.nodes[0].id]:this.diagram.nameTable[e.source.connectors[0].id]),e.startTouches=this.touchStartList,e.moveTouches=this.touchMoveList,e},n.prototype.resetTool=function(){this.action="Select",this.hoverElement=null,this.hoverNode=null,this.tool=this.diagram.getTool(this.action),this.updateCursor()},n.prototype.updateTool=function(){this.action=this.currentPosition&&"Pan"!==this.action?"Pan":"Select"},n.prototype.getTool=function(t){switch(t){case"Select":return new tm(this.commandHandler,!0);case"Drag":return new fa(this.commandHandler);case"Rotate":return new qx(this.commandHandler);case"LayoutAnimation":return new Une(this.commandHandler);case"FixedUserHandle":return new _ne(this.commandHandler,!0);case"Hyperlink":return new eF(this.commandHandler);case"ResizeSouthEast":case"ResizeSouthWest":case"ResizeNorthEast":case"ResizeNorthWest":case"ResizeSouth":case"ResizeNorth":case"ResizeWest":case"ResizeEast":return new Hd(this.commandHandler,t);case"ConnectorSourceEnd":case"ConnectorTargetEnd":case"BezierSourceThumb":case"BezierTargetThumb":return new Rd(this.commandHandler,t);case"SegmentEnd":case"OrthoThumb":return new r_(this.commandHandler,t);case"Draw":var e="shape",i=function gse(n){var t;return n&&(n.type?t="Connector":n.shape&&!n.type&&(t="Node")),t}(this.diagram.drawingObject);if("Node"===i&&"Text"===this.diagram.drawingObject.shape.type)return new JI(this.commandHandler);if("Connector"===i&&"Freehand"===this.diagram.drawingObject.type)return new Yne(this.commandHandler);if("Node"===i&&"Polygon"===this.diagram.drawingObject.shape[""+e]&&!this.diagram.drawingObject.shape.points)return new Rl(this.commandHandler);if("Node"===i||"Node"===i&&"Polygon"===this.diagram.drawingObject.shape[""+e]&&this.diagram.drawingObject.shape.points)return new ZI(this.commandHandler,this.diagram.drawingObject);if("Connector"===i&&"Polyline"===this.diagram.drawingObject.type)return new Hl(this.commandHandler);if("Connector"===i)return new pa(this.commandHandler,"ConnectorSourceEnd",this.diagram.drawingObject);break;case"Pan":return new im(this.commandHandler,!1);case"PinchZoom":return new im(this.commandHandler,!0);case"PortDrag":return new fa(this.commandHandler,"Port");case"PortDraw":return new pa(this.commandHandler,"ConnectorSourceEnd",this.diagram.drawingObject);case"LabelSelect":return new tm(this.commandHandler,!0,"LabelSelect");case"LabelDrag":return new jne(this.commandHandler);case"LabelResizeSouthEast":case"LabelResizeSouthWest":case"LabelResizeNorthEast":case"LabelResizeNorthWest":case"LabelResizeSouth":case"LabelResizeNorth":case"LabelResizeWest":case"LabelResizeEast":return new Vne(this.commandHandler,t);case"LabelRotate":return new Wne(this.commandHandler)}return null},n.prototype.getCursor=function(t){var e=this.diagram.selectedItems.annotation?this.diagram.selectedItems.wrapper.children[0]:this.diagram.selectedItems;return function Fne(n,t){if(t+=360,t%=360,-1===n.indexOf("Resize"))return Xx[""+n];var e=Xx[""+n];return t>=0&&t<25||t>=160&&t<=205||t>=340&&t<=360?e:t>=25&&t<=70||t>=205&&t<=250?"n-resize"===e||"s-resize"===e?"ne-resize":"nw-resize"===e||"se-resize"===e?"n-resize":"e-resize"===e||"w-resize"===e?"nw-resize":"e-resize":t>=70&&t<=115||t>=250&&t<=295?"n-resize"===e||"s-resize"===e?"e-resize":"nw-resize"===e||"se-resize"===e?"ne-resize":"e-resize"===e||"w-resize"===e?"n-resize":"nw-resize":t>=115&&t<=155||t>=295&&t<=340?"n-resize"===e||"s-resize"===e?"nw-resize":"nw-resize"===e||"se-resize"===e?"e-resize":"e-resize"===e||"w-resize"===e?"ne-resize":Xx[""+n]:"n-resize"}(t,this.diagram.selectedItems.annotation?e.rotateAngle+e.parentTransform:e.rotateAngle)},n.prototype.findElementUnderMouse=function(t,e,i,r){return this.objectFinder.findElementUnderSelectedItem(t,e,i,r)},n.prototype.findObjectsUnderMouse=function(t,e){return this.objectFinder.findObjectsUnderMouse(t,this.diagram,this.eventArgs,e)},n.prototype.findObjectUnderMouse=function(t,e,i){return this.objectFinder.findObjectUnderMouse(this.diagram,t,e,i,this.eventArgs,this.currentPosition)},n.prototype.findTargetUnderMouse=function(t,e,i,r,s){return this.objectFinder.findObjectUnderMouse(this.diagram,t,e,i,this.eventArgs,r,s)},n.prototype.findActionToBeDone=function(t,e,i,r){return function kne(n,t,e,i,r,s,o){if(s&&s.length>1&&r&&r.length>1)return"PinchZoom";if(i.currentSymbol)return"Drag";if("PortDraw"===i.eventHandler.action&&(i.tool&=~ri.DrawOnce),(k3(i)||jI(i))&&i.drawingObject)return"Draw";if($a(i)&&(l=i.selectedItems).wrapper&&qr(l.constraints,"UserHandle"))for(var h=0,c=l.userHandles;h=50&&(l.x=(a.points[parseInt(h.toString(),10)].x+a.points[h+1].x)/2,l.y=(a.points[parseInt(h.toString(),10)].y+a.points[h+1].y)/2,wr(e,l,n.hitPadding?n.hitPadding:10)))return"OrthoThumb"}else BI(n)&&console.warn('[WARNING] :: Module "ConnectorEditing" is not available in Diagram component! You either misspelled the module name or forgot to load it.');return null}(g,l,e,i);if("OrthoThumb"===S)return S;if(qr(l.constraints,"ConnectorSourceThumb")&&RI(g)&&S||qr(l.constraints,"ConnectorTargetThumb")&&HI(g)&&S)return S}}else{var b=i.selectedItems.handleSize/2/i.scroller.currentZoom,M=10/i.scroller.currentZoom,w=Bi();qi(w,f.rotateAngle+f.parentTransform,f.offsetX,f.offsetY);var C=f.offsetX-f.pivot.x*f.actualSize.width,D=f.offsetY-f.pivot.y*f.actualSize.height,A={x:C+(.5===f.pivot.x?2*f.pivot.x:f.pivot.x)*f.actualSize.width/2,y:D-30/i.scroller.currentZoom};A=Ke(w,A);var x=!!i.selectedItems.annotation,P=!(!x||!FI(i.selectedItems.annotation));if(qr(l.constraints,"Rotate")&&wr(e,A,M)&&i.selectedItems.thumbsConstraints&bt.Rotate){if(x&&P)return"LabelRotate";if(!x)return"Rotate"}if(u.Inflate(b),u.containsPoint(e)&&(S=function Pne(n,t,e,i,r,s){var o;return 1===n.selectedItems.nodes.length&&0===n.selectedItems.connectors.length&&n.selectedItems.nodes[0].container&&(o=function Hne(n,t,e,i,r){var s=10/n.scroller.currentZoom,o=n.selectedItems,a=t.actualSize.width,l=t.actualSize.height,h=new Ne(i,r,t.style.strokeWidth,l),c=new Ne(i+a,r,t.style.strokeWidth,l),d=new Ne(i,r,a,t.style.strokeWidth),u=new Ne(i,r+l,a,t.style.strokeWidth),f=Dn(n,n.selectedItems.nodes[0],!0)?n.nameTable[n.selectedItems.nodes[0].parentId]:n.selectedItems.nodes[0];if(ga(o.constraints,"ResizeEast",o.thumbsConstraints,o)&&c.containsPoint(e,s))return"ResizeEast";if(ga(o.constraints,"ResizeSouth",o.thumbsConstraints,o)&&u.containsPoint(e,s))return"ResizeSouth";if("Grid"!==f.container.type){if(ga(o.constraints,"ResizeWest",o.thumbsConstraints,o)&&h.containsPoint(e,s))return"ResizeWest";if(ga(o.constraints,"ResizeNorth",o.thumbsConstraints,o)&&d.containsPoint(e,s))return"ResizeNorth"}return null}(n,t,e,r,s)),!o&&(!n.selectedItems.nodes[0]||!n.selectedItems.nodes[0].isPhase&&!n.selectedItems.nodes[0].isLane&&"SwimLane"!==n.selectedItems.nodes[0].shape.type)&&(o=function Bne(n,t,e,i,r,s){var o=40/n.scroller.currentZoom,a=n.selectedItems.handleSize/2/n.scroller.currentZoom,l=n.selectedItems,h=!!l.annotation;if(t.actualSize.width>=o&&t.actualSize.height>=o){if(ga(l.constraints,"ResizeSouthEast",l.thumbsConstraints,l)&&wr(e,Ke(i,{x:r+t.actualSize.width,y:s+t.actualSize.height}),a))return h?"LabelResizeSouthEast":"ResizeSouthEast";if(ga(l.constraints,"ResizeSouthWest",l.thumbsConstraints,l)&&wr(e,Ke(i,{x:r,y:s+t.actualSize.height}),a))return h?"LabelResizeSouthWest":"ResizeSouthWest";if(ga(l.constraints,"ResizeNorthEast",l.thumbsConstraints,l)&&wr(e,Ke(i,{x:r+t.actualSize.width,y:s}),a))return h?"LabelResizeNorthEast":"ResizeNorthEast";if(ga(l.constraints,"ResizeNorthWest",l.thumbsConstraints,l)&&wr(e,Ke(i,{x:r,y:s}),a))return h?"LabelResizeNorthWest":"ResizeNorthWest"}return ga(l.constraints,"ResizeEast",l.thumbsConstraints,l)&&wr(e,Ke(i,{x:r+t.actualSize.width,y:s+t.actualSize.height/2}),a)?h?"LabelResizeEast":"ResizeEast":ga(l.constraints,"ResizeWest",l.thumbsConstraints,l)&&wr(e,Ke(i,{x:r,y:s+t.actualSize.height/2}),a)?h?"LabelResizeWest":"ResizeWest":ga(l.constraints,"ResizeSouth",l.thumbsConstraints,l)&&wr(e,Ke(i,{x:r+t.actualSize.width/2,y:s+t.actualSize.height}),a)?h?"LabelResizeSouth":"ResizeSouth":ga(l.constraints,"ResizeNorth",l.thumbsConstraints,l)&&wr(e,Ke(i,{x:r+t.actualSize.width/2,y:s}),a)?h?"LabelResizeNorth":"ResizeNorth":null}(n,t,e,i,r,s)),o||null}(i,f,e,w,C,D),S))return S}}if(Oc(i)&&!n)return"Pan";if((o instanceof Es||o instanceof Lc)&&(!Oc(i)||Vv(i)||Wv(i))&&(S=function Rne(n,t,e,i){if(Ux(t)&&(va(t,ci.Hover)||va(t,ci.Visible))){if(t.constraints&oi.Drag)return"PortDrag"}else if(_x(t)&&(va(t,ci.Hover)||va(t,ci.Visible))&&t.constraints&oi.Draw){n.drawingObject={};var r={type:"Orthogonal",sourcePortID:t.id};return n.drawingObject=r,n.tool|=ri.DrawOnce,n.currentDrawingObject=r,"PortDraw"}return"None"}(i,o),"None"!==S))return S;if((o instanceof Kn||o instanceof Or)&&!Oc(i)&&Ld(o))return _r(i,o,void 0,t)&&ro(o)?"LabelDrag":"LabelSelect";if(null!==n){if(!(n instanceof te||n instanceof de))return"Select";if(t&&t.id){var L=t.id.split(n.id)[1];if(L&&L.match("^_icon"))return"LayoutAnimation"}if(t&&t.id)for(var O=void 0,N=0;N-1)return"FixedUserHandle";if(t instanceof ai&&t.hyperlink.link)return"Hyperlink";if(!ro(n)||!_r(i,n,!1)||void 0!==i.selectedItems.annotation)return n&&Oc(i)&&!VI(i)?"Pan":i.selectedItems.nodes.length&&i.selectedItems.nodes[0].isLane&&i.selectedItems.wrapper&&i.selectedItems.wrapper.bounds.containsPoint(e)?"Drag":"Select";if(n instanceof de&&!wr(e,n.sourcePoint,n.hitPadding)&&!wr(e,n.targetPoint,n.hitPadding)||!(n instanceof de))return"Drag"}return"Select"}(t,e,this.currentPosition,this.diagram,this.touchStartList,this.touchMoveList,r)},n.prototype.updateContainerBounds=function(t){var e=!1;if(this.diagram.selectedObject.helperObject&&this.diagram.selectedObject.actualObject)for(var i=this.diagram.selectedObject.actualObject,r=this.diagram.selectedObject.actualObject instanceof ei?i.nodes:[i],s=0;si.y&&(h+=u>0?-1:1,u+=u>0?-1:1):i&&e.wrapper.offsetYi.x&&(h+=u>0?-1:1,u+=u>0?-1:1):i&&e.wrapper.offsetX1)for(var S=t.offsetX-this.diagram.selectedItems.offsetX,b=t.offsetY-this.diagram.selectedItems.offsetY,M=t.rotateAngle-this.diagram.selectedItems.rotateAngle,w=0;w-1){var A=c.children;A.splice(A.indexOf(o.id),1),this.diagram.nameTable[o.id].parentId="",i=!0,c.wrapper.children.splice(D,1)}}if(function One(n,t,e,i){var r=n,s=e.nameTable[r.parentId],o=e.nameTable[r.parentId];if(t&&o&&o.container&&"Stack"===o.container.type&&t.container&&"Stack"===t.container.type&&o.id!==t.parentId){var a=o.wrapper.children.indexOf(r.wrapper);a>-1&&(e.nameTable[r.id].parentId=t.id,o.wrapper.children.splice(a,1))}if(t&&t.parentId&&r.parentId&&"Drag"===i&&o.container&&"Stack"===o.container.type){var l=s.wrapper.children.indexOf(t.wrapper),h=s.wrapper.children.indexOf(r.wrapper),c={targetIndex:l,target:t,sourceIndex:h,source:n};s.wrapper.children.splice(h,1),s.wrapper.children.splice(l,0,r.wrapper),e.commandHandler.addHistoryEntry({type:"StackChildPositionChanged",redoObject:{targetIndex:h,target:t,sourceIndex:l,source:n},undoObject:c,category:"Internal"})}}(o,h,this.diagram,this.action),(c=Dn(this.diagram,o)?this.diagram.nameTable[o.parentId]:this.diagram.nameTable[o.parentId]||o)&&c.container&&"Canvas"===c.container.type&&(c.wrapper.maxWidth=c.maxWidth=c.wrapper.actualSize.width,c.wrapper.maxHeight=c.maxHeight=c.wrapper.actualSize.height,e=!0),Dn(this.diagram,o,!0)&&c&&"Canvas"===c.container.type)if(this.diagram.selectedItems.nodes.length>1)for(w=0;w0)for(var i=0;i0&&e.columnIndex>0||l&&e.isLane)){if("Horizontal"===t.container.orientation&&e.isPhase&&e.wrapper.width>e.maxWidth&&(e.maxWidth=e.wrapper.width,e.wrapper.maxWidth=e.wrapper.width),h.updateColumnWidth(e.columnIndex,r.width,!0,c),Wx(this.diagram,e,t),e.isPhase){var p=this.diagram.nameTable[""+t.shape.phases[e.columnIndex].header.id];p.maxWidth0?(r=new ap(t,"",u),t.shape.classShape.attributes.push(r)):i.id.includes("_umlMethods")&&t.shape.classShape.methods.length>0&&(s=new fm(t,"",u),t.shape.classShape.methods.push(s))),"Interface"===t.shape.classifier&&(i.id.includes("_umlProperty")&&t.shape.interfaceShape.attributes.length>0?(r=new ap(t,"",u),t.shape.classShape.attributes.push(r)):i.id.includes("_umlMethods")&&t.shape.interfaceShape.methods.length>0&&(s=new fm(t,"",u),t.shape.interfaceShape.methods.push(s))),"Enumeration"===t.shape.classifier&&i.id.includes("_umlMember")&&t.shape.enumerationShape.members.length>0){var f=new fb(t,"",u);t.shape.enumerationShape.members.push(f)}t.wrapper.children.indexOf(c.wrapper),this.diagram.enableServerDataBinding(!0),this.diagram.add(c),this.diagram.updateConnectorEdges(t),this.diagram.clearSelection(),this.diagram.select([this.diagram.nameTable[c.id]]),this.diagram.endGroupAction(),this.diagram.startTextEdit()}}},n}(),Zoe=function(){function n(){}return n.prototype.findObjectsUnderMouse=function(t,e,i,r,s){var o=[];r&&r instanceof ei&&r.nodes.length+r.connectors.length===1&&(r=r.nodes[0]||r.connectors[0]).children&&0===r.children.length&&(i.actualObject=r);for(var a,l,h,c,p,d=r&&r instanceof de&&(r.constraints&qe.ConnectToNearByNode||r.constraints&qe.ConnectToNearByPort)&&r.connectionPadding||0,f={},g=0,v=e.spatialSearch.findObjects(new Ne(t.x-50-d,t.y-50-d,100+d,100+d));g-1&&o.splice(T,1),"UmlClassifier"===y.shape.type&&y.container&&"Stack"===y.container.type&&(T=o.indexOf(e.nameTable[e.nameTable[y.id].wrapper.children[0].id]))>-1&&o.splice(T,1)}for(var z=0;zs.zIndex&&(t[parseInt(r.toString(),10)]=l),r>0&&i&&a&&(a.isLane||a.isPhase||a.isHeader)&&t[parseInt(r.toString(),10)].zIndex=2)for(var d=t.length-1;d>=0;d--)if(t[parseInt(d.toString(),10)].parentId){var u=hm(t[parseInt(d.toString(),10)],e,""),f=hm(t[d-1],e,""),g=e.nameTable[""+f];g&&u!==f&&e.nameTable[""+u].zIndex=0;p--){d=rp(e[parseInt(p.toString(),10)],!1),c=rp(e[parseInt(p.toString(),10)],!0);var g=t[""+l].tool,v=this.findTargetElement(e[parseInt(p.toString(),10)].wrapper,o,t,void 0);if("Draw"===i&&v&&(e[parseInt(p.toString(),10)]instanceof te||e[parseInt(p.toString(),10)]instanceof de)&&!cb(e[parseInt(p.toString(),10)],v)&&(g&&"ConnectorSourceEnd"===g[""+h]&&!Bh(e[parseInt(p.toString(),10)])||g&&"ConnectorTargetEnd"===g[""+h]&&!ua(e[parseInt(p.toString(),10)])))return u;if(e[parseInt(p.toString(),10)]instanceof te||e[parseInt(p.toString(),10)]instanceof de&&(Bh(e[parseInt(p.toString(),10)])||Nd(d)||ua(e[parseInt(p.toString(),10)])||Hh(c)||"PortDraw"===i&&g instanceof Rd&&"ConnectorTargetEnd"===g[""+h]&&(ua(e[parseInt(p.toString(),10)])||Hh(c))))return u=e[parseInt(p.toString(),10)],f&&(u=this.isTarget(u,t,i)),s.actualObject=u,u}else if("ConnectorTargetEnd"===i&&a){for(p=e.length-1;p>=0;p--)if(c=rp(e[parseInt(p.toString(),10)],!0),(e[parseInt(p.toString(),10)]instanceof te||e[parseInt(p.toString(),10)]instanceof de)&&(ua(e[parseInt(p.toString(),10)])||Hh(c)))return u=e[parseInt(p.toString(),10)],u=this.isTarget(u,t,i),s.actualObject=u,u}else{if(a&&("Drag"===i||t[""+l].tool instanceof fa)){var y=0;for(p=0;p=S.zIndex?u:S,y=Math.max(y,S.zIndex)):y=(u=S).zIndex)}return u&&"Bpmn"===u.shape.type&&(t.selectedItems.nodes.length>0&&"Bpmn"===t.selectedItems.nodes[0].shape.type||(u=null)),u&&(s.actualObject=u),u}if("Select"!==i&&"Pan"!==i||!t[""+l].tool)if("Pan"===i||"LayoutAnimation"===i){for(p=e.length-1;p>=0;p--)if((e[parseInt(p.toString(),10)]instanceof te||e[parseInt(p.toString(),10)]instanceof de)&&(v=this.findTargetElement(e[parseInt(p.toString(),10)].wrapper,o,t,void 0),"Pan"===i||v&&(v.id.match("_icon_content_shape$")||v.id.match("_icon_content_rect$"))))return e[parseInt(p.toString(),10)]}else u=e[e.length-1],s&&u&&(s.actualObject=u);else{for(p=e.length-1;p>=0;p--)if(e[parseInt(p.toString(),10)]instanceof de){var b=e[p-1];if(e[p-1]instanceof te&&b.ports){if((v=this.findTargetElement(b.wrapper,o,t,void 0))&&(v.id.match("_icon_content_shape$")||v.id.match("_icon_content_rect$")))return b;for(var M=0;M=0;s--){var o=t.children[parseInt(s.toString(),10)];if(o&&o.outerBounds.containsPoint(e,r||0))if(o.visible){if(o instanceof Cs){var a=this.findTargetElement(o,e,i);if(a)return a}var l="Clip"===o.style.textOverflow||"Ellipsis"===o.style.textOverflow;if(o.bounds.containsPoint(e,r||0)&&!l)return o;if(t.bounds.containsPoint(e,r||0)&&l)return o}else if(o instanceof Ze&&t&&t.id){var h=void 0;if(t.id.includes("group_container")){var c=t.id.slice(0,-15);h=i.getObject(c)}else h=i.getObject(t.id);if(lb(h,o.id))return o}}return t.bounds.containsPoint(e,r)&&"none"!==t.style.fill?t:null},n}(),Joe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),hp=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},n_=function(n){function t(e,i,r,s){var o=n.call(this,e,i,r,s)||this;return o.objectZIndex=-1,o.zIndexTable={},o.objects=[],o}return Joe(t,n),hp([I("")],t.prototype,"id",void 0),hp([I(!0)],t.prototype,"visible",void 0),hp([I(!1)],t.prototype,"lock",void 0),hp([I()],t.prototype,"objects",void 0),hp([I()],t.prototype,"addInfo",void 0),hp([I(-1)],t.prototype,"zIndex",void 0),t}(Ee),DT=function(n,t,e,i){return new(e||(e=Promise))(function(r,s){function o(h){try{l(i.next(h))}catch(c){s(c)}}function a(h){try{l(i.throw(h))}catch(c){s(c)}}function l(h){h.done?r(h.value):new e(function(c){c(h.value)}).then(o,a)}l((i=i.apply(n,t||[])).next())})},xT=function(n,t){var i,r,s,o,e={label:0,sent:function(){if(1&s[0])throw s[1];return s[1]},trys:[],ops:[]};return o={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function a(h){return function(c){return function l(h){if(i)throw new TypeError("Generator is already executing.");for(;e;)try{if(i=1,r&&(s=2&h[0]?r.return:h[0]?r.throw||((s=r.return)&&s.call(r),0):r.next)&&!(s=s.call(r,h[1])).done)return s;switch(r=0,s&&(h=[2&h[0],s.value]),h[0]){case 0:case 1:s=h;break;case 4:return e.label++,{value:h[1],done:!1};case 5:e.label++,r=h[1],h=[0];continue;case 7:h=e.ops.pop(),e.trys.pop();continue;default:if(!(s=(s=e.trys).length>0&&s[s.length-1])&&(6===h[0]||2===h[0])){e=0;continue}if(3===h[0]&&(!s||h[1]>s[0]&&h[1]1)for(var i=0;i-1)return e[parseInt(i.toString(),10)];return this.diagram.activeLayer},n.prototype.getLayer=function(t){for(var e=this.diagram.layers,i=0;i=0;o--)this.diagram.unSelect(this.diagram.nameTable[s[parseInt(o.toString(),10)]]),this.diagram.remove(this.diagram.nameTable[s[parseInt(o.toString(),10)]]),"default_layer"!==i.id&&this.diagram.activeLayer.id===t&&(this.diagram.activeLayer=this.diagram.layers[this.diagram.layers.length-1]);delete this.diagram.layerZIndexTable[i.zIndex],this.diagram.layers.splice(r,1),"SVG"!==this.diagram.mode&&this.diagram.refreshDiagramLayer()}},n.prototype.moveObjects=function(t,e){this.diagram.startGroupAction();for(var i={},r=[],s=0;s-1){if(r=[],(h=this.diagram.nameTable[""+s]).children)for(var p=0,g=h.children;p0){for(var y=void 0,S=0,b=r;S0)for(var r=0;r0)for(r=0;r0){t=t.concat(this.diagram.selectedItems.connectors);for(var i=0;i0)for(t=t.concat(this.diagram.selectedItems.nodes),i=0;i0){for(var i=0,r=t.shape.activity.subProcess.processes;i0&&this.copyProcesses(this.processTable[""+s])}this.clipboardData.processTable=this.processTable}},n.prototype.group=function(){this.oldSelectedObjects=am(this.diagram);var e=this.diagram.isProtectedOnChange;this.diagram.protectPropertyChange(!0),this.diagram.diagramActions=this.diagram.diagramActions|ee.Group;var r={};r.id="group"+Qe(),(r=new te(this.diagram,"nodes",r,!0)).children=[];for(var s=this.diagram.selectedItems.nodes.concat(this.diagram.selectedItems.connectors).sort(function(h,c){return h.zIndex-c.zIndex}),o=0;o0){var a=this.diagram.add(r);a&&this.select(a),this.addHistoryEntry({type:"Group",undoObject:r,redoObject:r,category:"Internal"}),this.diagram.diagramActions=this.diagram.diagramActions&~ee.Group,this.diagram.protectPropertyChange(e)}},n.prototype.unGroup=function(t){var i=this.diagram.isProtectedOnChange;this.diagram.protectPropertyChange(!0),this.diagram.diagramActions=this.diagram.diagramActions|ee.Group;var r=[];t?r.push(t):r=this.diagram.selectedItems.nodes,this.diagram.startGroupAction();for(var s=0;s0&&this.diagram.removePorts(o,o.ports),o.annotations&&o.annotations.length>0&&!ce()&&this.diagram.removeLabels(o,o.annotations);for(var c=this.diagram.nameTable[o.parentId],d=o.children.length-1;d>=0;d--)this.diagram.nameTable[o.children[parseInt(d.toString(),10)]].parentId="",this.diagram.deleteChild(this.diagram.nameTable[o.children[parseInt(d.toString(),10)]],o),o.parentId&&o.children[parseInt(d.toString(),10)]&&this.diagram.addChild(c,o.children[parseInt(d.toString(),10)]);this.resetDependentConnectors(o.inEdges,!0),this.resetDependentConnectors(o.outEdges,!1),this.diagram.diagramActions&ee.UndoRedo||this.addHistoryEntry({type:"UnGroup",undoObject:a,redoObject:a,category:"Internal"}),o.parentId&&this.diagram.deleteChild(o,c)}this.diagram.removeNode(o,l),this.clearSelection()}this.diagram.endGroupAction(),this.diagram.diagramActions=this.diagram.diagramActions&~ee.Group,this.diagram.protectPropertyChange(i)},n.prototype.resetDependentConnectors=function(t,e){for(var i=0;i0&&(g=!1)}if(g){var y=this.cloneConnector(f,i);c.push(y),o[h.id]=y.id}}else{var S=this.cloneNode(h,i);if(c.push(S),S){o[h.id]=S.id;var b=h.inEdges;if(b)for(var M=0,w=b;M0)for(var u=0;u0)for(r=t.segments,s=0;s0&&this.diagram.drawingObject&&"Bezier"===this.diagram.drawingObject.type&&(t.segments=[]);var e=this.diagram.add(t);"SVG"!==this.diagram.mode&&this.diagram.refreshDiagramLayer(),this.selectObjects([e]),t&&!jI(this.diagram)&&(this.diagram.tool&=~ri.DrawOnce,this.diagram.currentDrawingObject=void 0)},n.prototype.enableServerDataBinding=function(t){this.diagram.enableServerDataBinding(t)},n.prototype.addText=function(t,e){var i=this.diagram.findElementUnderMouse(t,e,this.diagram);this.diagram.startTextEdit(t,i instanceof ai?i.id.split("_")[1]:void 0)},n.prototype.isUserHandle=function(t){var e=this.diagram.selectedItems;if(e.wrapper&&qr(e.constraints,"UserHandle"))for(var i=0,r=e.userHandles;i0&&t[0]&&t[0].isLane)for(s=this.diagram.getObject(t[0].parentId),t[0].shape.header=[],a=0;a1||e&&1===t.length)){if(1!==t.length)return[2];this.clearSelection()}if(!(u||d||1!==t.length||e&&$a(this.diagram)))return this.clearSelection(),[2]}if(!r.cancel){for(f=0;f0||e)&&p.children&&!p.parentId)for(g=0;g0||e,!0)}else this.select(p,f>0||e,!0);void 0===i&&(i=c),r={oldValue:i||[],newValue:this.getSelectedObject(),cause:this.diagram.diagramActions,state:"Changed",type:"Addition",cancel:!1},this.diagram.renderSelector(e||t&&t.length>1),ce()||this.diagram.triggerEvent(Ce.selectionChange,r),this.diagram.enableServerDataBinding(!0)}return[2]})})},n.prototype.findParent=function(t){return t.parentId&&this.findParent(t=this.diagram.nameTable[t.parentId]),t},n.prototype.selectProcesses=function(t){if(this.hasProcesses(t))for(var e=t.shape.activity.subProcess.processes,i=0;i0)},n.prototype.select=function(t,e,i){var r=this.getObjectLayer(t.id);if(Ld(t)&&!(t instanceof ei)&&!_r(this.diagram,t)&&r&&!r.lock&&r.visible&&t.wrapper.visible){(e=!!$a(this.diagram)&&e)||this.clearSelection(),this.diagram.enableServerDataBinding(!1);var s=this.diagram.selectedItems;if(t instanceof te?s.nodes.push(t.isHeader?this.diagram.nameTable[t.parentId]:t):s.connectors.push(t),s.selectedObjects.push(t),e)s.wrapper.rotateAngle=s.rotateAngle=0,s.wrapper.children.push(t.wrapper);else if(s.init(this.diagram),1===s.nodes.length&&0===s.connectors.length){var l=Yx(this.diagram,s);l&&(s.wrapper.children[0]=l),s.rotateAngle=s.nodes[0].rotateAngle,s.wrapper.rotateAngle=s.nodes[0].rotateAngle,s.wrapper.pivot=s.nodes[0].pivot}i||this.diagram.renderSelector(e),this.diagram.enableServerDataBinding(!0)}},n.prototype.labelSelect=function(t,e){this.oldSelectedObjects=am(this.diagram);var i=this.diagram.selectedItems,r=this.diagram.allowServerDataBinding;this.diagram.allowServerDataBinding=!1,i.nodes=i.connectors=[],this.diagram.allowServerDataBinding=r,t instanceof te?i.nodes[0]=t:i.connectors[0]=t,i.annotation=this.findTarget(e,t),i.init(this.diagram),this.diagram.renderSelector(!1)},n.prototype.unSelect=function(t){var e=this.diagram.selectedItems.nodes.concat(this.diagram.selectedItems.connectors),i=e.filter(function(a){return a.id!==t.id}),r={oldValue:e,newValue:i,cause:this.diagram.diagramActions,state:"Changing",type:"Removal",cancel:!1};if(this.diagram.currentSymbol||ce()||this.diagram.triggerEvent(Ce.selectionChange,r),_r(this.diagram,t)){var s=this.diagram.selectedItems,o=void 0;t instanceof te?(o=s.nodes.indexOf(t,0),s.nodes.splice(o,1)):(o=s.connectors.indexOf(t,0),s.connectors.splice(o,1)),o=s.selectedObjects.indexOf(t,0),s.selectedObjects.splice(o,1),(r={oldValue:e,newValue:i,cause:this.diagram.diagramActions,state:"Changed",type:"Removal",cancel:(r={oldValue:e,newValue:i,cause:this.diagram.diagramActions,state:"Changed",type:"Removal",cancel:!1}).cancel}).cancel||(o=s.wrapper.children.indexOf(t.wrapper,0),s.wrapper.children.splice(o,1),this.diagram.updateSelector(),this.diagram.currentSymbol||this.diagram.triggerEvent(Ce.selectionChange,r))}},n.prototype.moveSvgNode=function(t,e){var i=this.diagram.nameTable[""+e];if("Native"===i.shape.type||"HTML"===i.shape.type)this.updateNativeNodeIndex(t,e);else{var r=xt(e+"_groupElement",this.diagram.element.id),s=xt(t+"_groupElement",this.diagram.element.id);r.parentNode.insertBefore(s,r)}},n.prototype.moveAfterSvgNode=function(t,e){var i=this.diagram.nameTable[""+e];if(!i||"HTML"!==i.shape.type&&"Native"!==i.shape.type)a=xt(e+"_groupElement",this.diagram.element.id),o=xt(t+"_groupElement",this.diagram.element.id),a.insertAdjacentElement("afterend",o);else for(var r=0;rd&&"SwimLane"!==p.shape.type){var S=$(p);p.zIndex=d-((-1!==i.indexOf(p)?i.indexOf(p):0)+1),p.children&&(d=this.findLowestZIndex(p,c)||d),this.triggerOrderCommand(S,p,p),p.children&&this.updateGroupZindex(p,"SendToBack",d)}else"SwimLane"===p.shape.type&&(y=this.swapZIndexObjects(a,h,r,g));if("SVG"===this.diagram.mode){for(var M="SwimLane"!==this.diagram.nameTable[""+r].shape.type?d:y,w=h[parseInt(M.toString(),10)];!w&&Md)&&(d=f.zIndex)}for(var p=JSON.parse(JSON.stringify(l)),v=Number(Object.keys(l).sort(function(wo,Ul){return Number(wo)-Number(Ul)}).reverse()[0]),y=this.diagram.nameTable[""+e].zIndex,S=[],M=0;M<=v;M++)S.push(l[parseInt(M.toString(),10)]);if("SwimLane"===this.diagram.nameTable[""+e].shape.type)for(var C=v;C>=y;C--)if(l[parseInt(C.toString(),10)]&&this.diagram.nameTable[l[parseInt(C.toString(),10)]].parentId!==e){v=C;break}var D=this.diagram.nameTable[""+e];if(D.zIndexx&&(x=L.zIndex)}}else x=d;D.zIndex=x+((-1!==r.indexOf(D)?r.indexOf(D):0)+1),this.triggerOrderCommand(A,D,D)}else if("SwimLane"===D.shape.type){for(var O=0,N=-1,T=0,z=0,U=JSON.parse(JSON.stringify(l)),B=0;B<=y;B++)if(l[parseInt(B.toString(),10)]&&this.diagram.nameTable[l[parseInt(B.toString(),10)]].parentId===e&&-1===N){N=B,T=B;break}for(var j=0;j<=v;j++)p[parseInt(j.toString(),10)]&&p[parseInt(j.toString(),10)]!==e&&this.diagram.nameTable[p[parseInt(j.toString(),10)]].parentId!==e&&this.diagram.nameTable[p[parseInt(j.toString(),10)]].zIndex>=this.diagram.nameTable[""+e].zIndex&&O++;for(var ue=N,fe=0;fe<=O;fe++){for(;!l[parseInt(ue.toString(),10)];)ue++;z=this.diagram.nameTable[l[parseInt(ue.toString(),10)]].zIndex,ue++}for(var Me=z;Me<=v;Me++){for(;!U[parseInt(N.toString(),10)];)N++;for(;!l[parseInt(Me.toString(),10)];)Me++;l[parseInt(Me.toString(),10)]=U[parseInt(N.toString(),10)],this.diagram.nameTable[l[parseInt(Me.toString(),10)]].zIndex=Me,N++}l[parseInt(v.toString(),10)]=this.diagram.nameTable[""+e].id,this.diagram.nameTable[""+e].zIndex=v,ue=y+1;for(var De=T,xe=0;xe0&&("Native"===hr[0].shape.type||"HTML"===hr[0].shape.type)){for(Ci.parentNode.removeChild(Ci),De=0;De0?r[0]:null},n.prototype.findLowestZIndex=function(t,e){var r=this.diagram.nodes.filter(function(s){return-1!==e.indexOf(s.id)}).filter(function(s){return""===s.parentId&&s.id!==t.id}).map(function(s){return s.zIndex});return r.sort(function(s,o){return s-o}),r.length>0?r[0]:null},n.prototype.triggerOrderCommand=function(t,e,i){var s={zIndex:$(t).zIndex},o={zIndex:e.zIndex},a={element:i,cause:this.diagram.diagramActions,diagramAction:this.diagram.getDiagramAction(this.diagram.diagramActions),oldValue:s,newValue:o};this.diagram.triggerEvent(Ce.propertyChange,a)},n.prototype.checkGroupNode=function(t,e,i){return i[""+e].parentId===i[""+t].parentId},n.prototype.sortByZIndex=function(t,e,i){if("BringForward"===i){var r=e||"zIndex";t=t.sort(function(o,a){return a[""+r]-o[""+r]})}else{var s=e||"zIndex";t=t.sort(function(o,a){return o[""+s]-a[""+s]})}return t},n.prototype.orderCommands=function(t,e,i){var r=this,s=e.nodes;if(s=s.concat(e.connectors),t)if("SendBackward"===i)for(var o=0;oa}),S=v.filter(function(D){return D0?Math.max.apply(Math,S):a,M=y.length>0?Math.min.apply(Math,y):a;if(a!==M){var w=c.zIndexTable[parseInt(M.toString(),10)],C=c.zIndexTable[parseInt(a.toString(),10)];this.moveSvgNode(C,w)}else"SendToBack"===i&&(w=c.zIndexTable[parseInt(a.toString(),10)],C=c.zIndexTable[parseInt(b.toString(),10)],this.moveAfterSvgNode(w,C))}}else this.diagram.refreshCanvasLayers()}},n.prototype.swapDomOrder=function(t,e){if(t){var i=this.diagram.getObject(e);if("Native"===i.shape.type||"HTML"===i.shape.type)this.updateNativeNodeIndex(e,t),this.updateNativeNodeIndex(t,e);else{var r=xt(e+"_groupElement",this.diagram.element.id),s=xt(t+"_groupElement",this.diagram.element.id);r.parentNode.insertBefore(r,s),r.parentNode.insertBefore(s,r)}}},n.prototype.sendForward=function(t){var e=this;if(this.diagram.protectPropertyChange(!0),$a(this.diagram)||t){$(t||(this.diagram.selectedItems.nodes.length?this.diagram.selectedItems.nodes[0]:this.diagram.selectedItems.connectors[0]));var s=t&&t.id,o=this.diagram.layers.indexOf(this.getObjectLayer(s=s||(this.diagram.selectedItems.nodes.length?this.diagram.selectedItems.nodes[0].id:this.diagram.selectedItems.connectors[0].id))),a=$(this.diagram.nameTable),h=(parseInt(o.toString(),10),this.diagram.nameTable[""+s]),c=[],d=this.diagram.spatialSearch.findObjects(h.wrapper.bounds);d.length>2&&(d=this.sortByZIndex(d,void 0,"BringForward"));for(var u=0,f=d;u=0;p--)this.diagram.nameTable[c[parseInt(p.toString(),10)].id].parentId===s&&c.splice(p,1);if(c.length>0){var y=this.diagram.nameTable[c[c.length-1].id];if(y.parentId){var b=hm(y,this.diagram,""),M=this.diagram.nameTable[""+b];M.id!==s&&(c[0]=M)}var w={};for(p=0;p0&&(Object.values(O).forEach(function(ue){ue>=T&&N.push(ue)}),0!==N.length&&this.updateZIndexBySendForward(h,N,o))}var z=[];if(Object.keys(this.changedNodeZIndexes).forEach(function(ue){if((a[""+ue]?a[""+ue].zIndex:null)!==e.changedNodeZIndexes[""+ue]){var De=$(a[""+ue]);z.push(De)}}),this.updateLayerZindexTable(o),L.nodes.splice(0,L.nodes.length),z.forEach(function(ue){var fe=$(ue);L.nodes.push(fe)}),"SVG"===this.diagram.mode){var U=c[c.length-1].id,B=c[c.length-1];B&&!("HTML"===B.shape.type||"Native"===B.shape.type)&&this.moveAfterSvgNode(s,U),this.updateNativeNodeIndex(U,s)}else this.diagram.refreshCanvasLayers();var j=[];Object.keys(this.changedNodeZIndexes).forEach(function(ue){if((a[""+ue]?a[""+ue].zIndex:null)!==e.changedNodeZIndexes[""+ue]){var De=$(e.diagram.nameTable[""+ue]);j.push(De)}});var Q=$(this.diagram.selectedItems);Q.nodes.splice(0,Q.nodes.length),j.forEach(function(ue){var fe=$(ue);Q.nodes.push(fe)}),this.diagram.diagramActions&ee.UndoRedo||this.addHistoryEntry({type:"SendForward",category:"Internal",undoObject:L,redoObject:Q}),this.diagram.endGroupAction()}}this.diagram.protectPropertyChange(!1)},n.prototype.updateZIndexBySendForward=function(t,e,i){var r=$(t);t.zIndex=Math.min.apply(Math,e);var a,s=Math.min.apply(Math,e),o=Math.min.apply(Math,e),l=this.diagram.layers[parseInt(i.toString(),10)].objects,h=this.diagram.nodes.filter(function(S){return-1!==l.indexOf(S.id)});t.children&&this.updateGroupZindex(t,"BringForward",t.zIndex);var c=h.filter(function(S){return S.zIndex===Math.min.apply(Math,e)&&S.id!==t.id});if(c&&c.length>0&&c[0].children){for(var d=Math.min.apply(Math,e),u=0;uo&&g!==t&&g.parentId!==t.id&&c&&c.length>0&&g.parentId!==c[0].id){var v=$(g);g.zIndex=a+1,a++,this.triggerOrderCommand(v,g,g)}var y=g.zIndex;this.changedNodeZIndexes[g.id]=(this.changedNodeZIndexes.hasOwnProperty(g.id),y)}},n.prototype.arrangeZIndexForLowerNodes=function(t,e,i){var r=i.filter(function(o){return o.zIndex<=t&&o.parentId!==e.id});r.sort(function(o,a){return a.zIndex-o.zIndex});for(var s=0;se&&(e=r.zIndex)}return e},n.prototype.sendBackward=function(t){var e=this;if(this.diagram.protectPropertyChange(!0),$a(this.diagram)||t){$(t||(this.diagram.selectedItems.nodes.length?this.diagram.selectedItems.nodes[0]:this.diagram.selectedItems.connectors[0]));var s=t&&t.id,o=this.diagram.layers.indexOf(this.getObjectLayer(s=s||(this.diagram.selectedItems.nodes.length?this.diagram.selectedItems.nodes[0].id:this.diagram.selectedItems.connectors[0].id))),a=$(this.diagram.nameTable),h=(parseInt(o.toString(),10),this.diagram.nameTable[""+s]),c=[],d=this.diagram.spatialSearch.findObjects(h.wrapper.bounds);d.length>2&&(d=this.sortByZIndex(d));for(var u=0,f=d;uNumber(p.zIndex)&&""===p.parentId&&h.wrapper.bounds.intersects(p.wrapper.bounds)&&c.push(p);for(var p=c.length-1;p>=0;p--)(v=this.diagram.nameTable[c[parseInt(p.toString(),10)].id]).parentId===s&&c.splice(p,1);if(c.length>0){var v;if((v=this.diagram.nameTable[c[c.length-1].id]).parentId){var S=hm(v,this.diagram,""),b=this.diagram.nameTable[""+S];s!==b.id&&(c[c.length-1]=b)}var M={};for(p=0;p0&&(Object.values(L).forEach(function(fe){fe<=N&&O.push(fe)}),0!==O.length&&this.updateZIndexBySendBackward(h,O,o))}var T=[];if(Object.keys(this.changedNodeZIndexes).forEach(function(fe){if((a[""+fe]?a[""+fe].zIndex:null)!==e.changedNodeZIndexes[""+fe]){var xe=$(a[""+fe]);T.push(xe)}}),this.updateLayerZindexTable(o),P.nodes.splice(0,P.nodes.length),T.forEach(function(fe){var Me=$(fe);P.nodes.push(Me)}),"SVG"===this.diagram.mode){var z=c[c.length-1].id,U=c[c.length-1];U&&"HTML"!==U.shape.type&&"Native"!==U.shape.type&&this.moveSvgNode(s,z);var B=this.diagram.nameTable[""+z];B.children&&B.children.length>0?this.updateNativeNodeIndex(s):this.updateNativeNodeIndex(s,z)}else this.diagram.refreshCanvasLayers();var j=[];Object.keys(this.changedNodeZIndexes).forEach(function(fe){if((a[""+fe]?a[""+fe].zIndex:null)!==e.changedNodeZIndexes[""+fe]){var xe=$(e.diagram.nameTable[""+fe]);j.push(xe)}});var Q=$(this.diagram.selectedItems);Q.nodes.splice(0,Q.nodes.length),j.forEach(function(fe){var Me=$(fe);Q.nodes.push(Me)}),this.diagram.diagramActions&ee.UndoRedo||this.addHistoryEntry({type:"SendBackward",category:"Internal",undoObject:P,redoObject:Q}),this.diagram.endGroupAction()}}this.diagram.protectPropertyChange(!1)},n.prototype.updateZIndexBySendBackward=function(t,e,i){var r=$(t);t.zIndex=Math.max.apply(Math,e);var f,s=t.zIndex,o=Math.max.apply(Math,e),a=this.diagram.layers[parseInt(i.toString(),10)].objects,l=this.diagram.nodes.filter(function(S){return-1!==a.indexOf(S.id)}),h=l.filter(function(S){return S.zIndex===Math.max.apply(Math,e)&&S.id!==t.id});if(h&&h.length>0&&h[0].children)for(var c=Math.max.apply(Math,e),d=0;d0&&g.parentId!==h[0].id){var v=$(g);g.zIndex=f-1,f--,this.triggerOrderCommand(v,g,g)}var y=g.zIndex;this.changedNodeZIndexes[""+g.id]=(this.changedNodeZIndexes.hasOwnProperty(g.id),y)}},n.prototype.findLowestChildZIndex=function(t){for(var e=t.zIndex,i=0;i0),this.selectObjects([t],!0))},n.prototype.clearSelection=function(t,e){return DT(this,void 0,void 0,function(){var i,r,s,o;return xT(this,function(a){return i=this.diagram.allowServerDataBinding,this.diagram.enableServerDataBinding(!1),$a(this.diagram)&&(r=this.diagram.selectedItems,s=this.getSelectedObject(),this.diagram.currentSymbol&&(this.diagram.previousSelectedObject=s),o={oldValue:s,newValue:[],cause:this.diagram.diagramActions,state:"Changing",type:"Removal",cancel:!1},t&&(ce()||this.diagram.triggerEvent(Ce.selectionChange,o)),o.cancel||(r.offsetX=0,r.offsetY=0,r.width=0,r.height=0,r.rotateAngle=0,r.nodes=[],r.connectors=[],r.wrapper=null,r.annotation=void 0,r.selectedObjects=[],this.diagram.clearSelectorLayer(),t&&(o={oldValue:s,newValue:[],cause:this.diagram.diagramActions,state:"Changed",type:"Removal",cancel:!1},ce()||this.diagram.triggerEvent(Ce.selectionChange,o))),this.diagram.enableServerDataBinding(i)),[2]})})},n.prototype.clearSelectedItems=function(){this.clearSelection((this.diagram.selectedItems.nodes?this.diagram.selectedItems.nodes.length:0)+(this.diagram.selectedItems.connectors?this.diagram.selectedItems.connectors.length:0)>0)},n.prototype.removeStackHighlighter=function(){var t=Fl(this.diagram.element.id),e=t.getElementById(t.id+"_stack_highlighter");e&&e.parentNode.removeChild(e)},n.prototype.renderStackHighlighter=function(t,e){var r,s,o,i=this.diagram.selectedItems.nodes[0];if(!e){var a=this.diagram.findObjectsUnderMouse(t.position);if((e=this.diagram.findObjectUnderMouse(a,"Drag",!0))&&!(e.isLane||e.isPhase||e.isHeader))for(var l=0;l0)for(var a=0;a1)if(i){var h=l.segments[0],c=l.segments[1],u=Ol(NI(t.wrapper,t.wrapper.corners,t.wrapper.bounds),h.direction),g=kl({corners:void 0,point:u=qa(l,0,u,{x:l.sourceWrapper.offsetX,y:l.sourceWrapper.offsetY},!1),margin:void 0,direction:h.direction},{corners:void 0,point:c.points[1],margin:void 0,direction:void 0});h.length=R.distancePoints(g[0],g[1]),c.direction&&c.length&&(c.length=R.distancePoints(g[1],g[2]))}else if(o){switch(l.segments[0].direction){case"Bottom":r=t.wrapper.bounds.bottomCenter.x-e.bottomCenter.x,s=t.wrapper.bounds.bottomCenter.y-e.bottomCenter.y;break;case"Top":r=t.wrapper.bounds.topCenter.x-e.topCenter.x,s=t.wrapper.bounds.topCenter.y-e.topCenter.y;break;case"Left":r=t.wrapper.bounds.middleLeft.x-e.middleLeft.x,s=t.wrapper.bounds.middleLeft.y-e.middleLeft.y;break;case"Right":r=t.wrapper.bounds.middleRight.x-e.middleRight.x,s=t.wrapper.bounds.middleRight.y-e.middleRight.y}this.dragSourceEnd(l,r,s,!0,null,"ConnectorSourceEnd",void 0,void 0,void 0,!(t.parentId&&this.diagram.diagramActions&ee.isGroupDragging))}}},n.prototype.updateEndPoint=function(t,e){var r={sourcePoint:t.sourcePoint,targetPoint:t.targetPoint};t.sourceID&&(r.sourceID=t.sourceID),t.targetID&&(r.targetID=t.targetID),t.sourcePortID&&(r.sourcePortID=t.sourcePortID),t.targetPortID&&(r.targetPortID=t.targetPortID),t.segments&&(r.segments=t.segments),this.diagram.connectorPropertyChange(t,e||{},r),this.diagram.updateSelector()},n.prototype.dragSourceEnd=function(t,e,i,r,s,o,a,l,h,c,d){var u=this.diagram.nameTable[t.id],f={},p=this.checkBoundaryConstraints(e,i,u.wrapper.bounds);if(RI(u)&&p&&"BezierSourceThumb"!==o&&Qv(this.diagram)&&(f=$(f={sourcePoint:u.sourcePoint}),u.sourcePoint.x+=e,u.sourcePoint.y+=i,"ConnectorSourceEnd"===o&&"Orthogonal"===u.type&&this.changeSegmentLength(u,l,h,c),"Bpmn"===u.shape.type&&"Default"===u.shape.sequence&&"Sequence"===u.shape.flow&&this.updatePathElementOffset(u)),"Bezier"===u.type)if(f={sourcePoint:u.sourcePoint},d)this.translateBezierPoints(t,""===o?"ConnectorSourceEnd":o,e,i,d,s,!a);else for(var g=0;g2){var d=R.direction((c=t.segments[2]).points[0],c.points[1]);o.direction===_n(d)?("Right"===o.direction?c.points[0].x=o.points[o.points.length-1].x=l.wrapper.corners.middleRight.x+20:"Left"===o.direction?c.points[0].x=o.points[o.points.length-1].x=l.wrapper.corners.middleLeft.x-20:c.points[0].y=o.points[o.points.length-1].y="Top"===o.direction?l.wrapper.corners.topCenter.y-20:l.wrapper.corners.bottomCenter.y+20,c.direction&&c.length&&(c.length=R.distancePoints(c.points[0],c.points[c.points.length-1])),o.length=R.distancePoints(o.points[0],o.points[o.points.length-1])):o.direction===d&&c.direction&&c.length?("Top"===o.direction||"Bottom"===o.direction?(c.points[0]=o.points[0],c.points[c.points.length-1].x=c.points[0].x):(c.points[0]=o.points[0],c.points[c.points.length-1].y=c.points[0].y),c.length=R.distancePoints(c.points[0],c.points[c.points.length-1]),t.segments.splice(0,2)):o.length=20}else o.length=20;else if(o.length<1)if(""!==t.sourceID){var c;"Right"===a.direction?a.points[a.points.length-1].y=(h=l.wrapper.corners.middleRight).y:"Left"===a.direction?a.points[a.points.length-1].y=(h=l.wrapper.corners.middleLeft).y:a.points[a.points.length-1].x="Top"===a.direction?(h=l.wrapper.corners.topCenter).x:(h=l.wrapper.corners.bottomCenter).x,a.length=R.distancePoints(h,a.points[a.points.length-1]),t.segments.length>2&&(c=t.segments[2]).direction&&c.length&&(c.length=R.distancePoints(a.points[a.points.length-1],c.points[c.points.length-1])),t.segments.splice(0,1)}else t.segments.splice(0,1)}else e&&!i&&t.sourceID!==e.id&&t.segments&&null!==t.segments[0].direction&&e&&e instanceof te&&s&&this.changeSourceEndToNode(t,e),e&&i&&t.sourcePortID!==i&&t.segments&&null!==t.segments[0].direction&&e&&e instanceof te&&s&&this.changeSourceEndToPort(t,e,i)},n.prototype.canConnect=function(t,e){return!(!ua(e)||!Bh(e))},n.prototype.changeSourceEndToPort=function(t,e,i){var r=this.diagram.getWrapper(e.wrapper,i),s={x:r.offsetX,y:r.offsetY},o=zo(s,xn(e.wrapper),e.wrapper.bounds),a=t.segments[0],l=t.segments[1];if(a.direction!==o){var h=[],c={};if(a.direction===_n(o)){c={};var d=void 0;"Top"===o||"Bottom"===o?(d="Top"===o?{type:"Orthogonal",isTerminal:!0,direction:o,length:Math.abs(a.points[0].y-s.y)}:{type:"Orthogonal",isTerminal:!0,direction:o,length:Math.abs(s.y-a.points[0].y)},c=a.points[0].x>s.x?{type:"Orthogonal",isTerminal:!0,direction:"Right",length:a.points[0].x-s.x}:{type:"Orthogonal",isTerminal:!0,direction:"Left",length:s.x-a.points[0].x}):(d="Right"===o?{type:"Orthogonal",isTerminal:!0,direction:o,length:Math.abs(a.points[0].x-s.x)}:{type:"Orthogonal",isTerminal:!0,direction:o,length:Math.abs(s.x-a.points[0].x)},c=a.points[0].y>s.y?{type:"Orthogonal",direction:"Top",isTerminal:!0,length:a.points[0].y-s.y}:{type:"Orthogonal",direction:"Bottom",isTerminal:!0,length:s.y-a.points[0].y}),h.push(new wi(t,"segments",d,!0)),h.push(new wi(t,"segments",c,!0))}else h.push(new wi(t,"segments",c={type:"Orthogonal",direction:o,length:20,isTerminal:!0},!0));a.direction!==_n(o)&&("Top"===o||"Bottom"===o?(a.points[0].x=s.x,a.points[0].y=a.points[a.points.length-1].y="Top"===o?s.y-20:s.y+20):(a.points[0].y=s.y,a.points[0].x=a.points[a.points.length-1].x="Right"===o?s.x+20:s.x-20),a.length=R.distancePoints(a.points[0],a.points[a.points.length-1]),l.length=R.distancePoints(a.points[a.points.length-1],l.points[l.points.length-1])),t.segments=h.concat(t.segments)}else a.points[0]=s,"Top"===o||"Bottom"===o?a.points[a.points.length-1].x=s.x:a.points[a.points.length-1].y=s.y,a.length=R.distancePoints(a.points[0],a.points[a.points.length-1]),l.length=R.distancePoints(a.points[a.points.length-1],l.points[l.points.length-1])},n.prototype.removeTerminalSegment=function(t,e){for(var i=0;ii.width||"Left"===o.direction&&r.x>=o.points[0].x||"Right"===o.direction&&r.x<=o.points[0].x)o.points[0].y=o.points[o.points.length-1].y=r.y,o.points[0].x=r.x,o.length=R.distancePoints(o.points[0],o.points[o.points.length-1]),a.length=R.distancePoints(o.points[o.points.length-1],a.points[a.points.length-1]);else{var h=void 0;s="Bottom"===(h=a.direction?a.direction:R.direction(a.points[0],a.points[a.points.length-1]))?i.bottomCenter:i.topCenter,a.length&&a.direction&&(a.length="Top"===h?o.points[o.points.length-1].y-(s.y+20):s.y+20-o.points[o.points.length-1].y),o.length=o.points[o.points.length-1].x-s.x,o.direction=o.length>0?"Right":"Left",l.push(new wi(t,"segments",{type:"Orthogonal",direction:h,length:20},!0)),t.segments=l.concat(t.segments)}else r="Bottom"===o.direction?i.bottomCenter:i.topCenter,o.length>i.height||"Top"===o.direction&&r.y>=o.points[0].y||"Bottom"===o.direction&&r.y<=o.points[0].y?(o.points[0].x=o.points[o.points.length-1].x=r.x,o.points[0].y=r.y,o.length=R.distancePoints(o.points[0],o.points[o.points.length-1]),a.length=R.distancePoints(o.points[o.points.length-1],a.points[a.points.length-1])):(s="Left"===a.direction?i.middleLeft:i.middleRight,h=void 0,h=a.direction?a.direction:R.direction(a.points[0],a.points[a.points.length-1]),a.length&&a.direction&&(a.length="Left"===h?o.points[o.points.length-1].x-(s.x+20):s.x+20-o.points[o.points.length-1].x),o.length=o.points[o.points.length-1].y-s.y,o.direction=o.length>0?"Bottom":"Top",l.push(new wi(t,"segments",{type:"Orthogonal",direction:h,length:20},!0)),t.segments=l.concat(t.segments))},n.prototype.translateBezierPoints=function(t,e,i,r,s,o,a){var l=t.segments.indexOf(s),h=t.segments[parseInt(l.toString(),10)],c=l>0?t.segments[l-1]:null,d=null!==c?c.point:t.sourcePoint,u=l===t.segments.length-1?t.targetPoint:h.point;if(h)if("BezierSourceThumb"===e&&(h.vector1.angle||h.vector1.distance)){var f=h.vector1.distance,p=h.vector1.angle;h.vector1={distance:t.distance(d,o),angle:R.findAngle(d,o)},this.translateSubsequentSegment(t,s,!0,h.vector1.distance-f,h.vector1.angle-p)}else"BezierTargetThumb"===e&&(h.vector2.angle||h.vector2.distance)?(f=h.vector2.distance,p=h.vector2.angle,h.vector2={distance:t.distance(u,o),angle:R.findAngle(u,o)},this.translateSubsequentSegment(t,s,!1,h.vector2.distance-f,h.vector2.angle-p)):("ConnectorSourceEnd"===e&&!t.sourceID||"ConnectorTargetEnd"===e&&!t.targetID)&&a&&eb(h.vector1)&&eb(h.vector2)?(R.isEmptyPoint(h.point1)&&(h.bezierPoint1=tb(t.sourcePoint,t.targetPoint)),R.isEmptyPoint(h.point2)&&(h.bezierPoint2=tb(t.targetPoint,t.sourcePoint))):"BezierSourceThumb"===e||"ConnectorSourceEnd"===e&&!a&&eb(h.vector1)?(h.bezierPoint1.x+=i,h.bezierPoint1.y+=r,(!R.isEmptyPoint(h.point1)||a)&&(h.point1={x:h.bezierPoint1.x,y:h.bezierPoint1.y})):("BezierTargetThumb"===e||"ConnectorTargetEnd"===e&&!a&&eb(h.vector2))&&(h.bezierPoint2.x+=i,h.bezierPoint2.y+=r,(!R.isEmptyPoint(h.point2)||a)&&(h.point2={x:h.bezierPoint2.x,y:h.bezierPoint2.y}))},n.prototype.translateSubsequentSegment=function(t,e,i,r,s){var o=t.segments.indexOf(e);parseInt(o.toString(),10),t.bezierSettings.smoothness&DI.SymmetricAngle||(s=null),t.bezierSettings.smoothness&DI.SymmetricDistance||(r=null),(null!=r||null!=s)&&(i?0!==o&&this.updatePreviousBezierSegment(t,o,r,s):o!==t.segments.length-1&&this.updateNextBezierSegment(t,o,r,s))},n.prototype.updatePreviousBezierSegment=function(t,e,i,r){var s=t.segments[e-1],a=(s.vector2.angle+r)%360;a<0&&(a+=360),s.vector2={distance:s.vector2.distance+i,angle:a}},n.prototype.updateNextBezierSegment=function(t,e,i,r){var s=t.segments[e+1],a=(s.vector1.angle+r)%360;a<0&&(a+=360),s.vector1={distance:s.vector1.distance+i,angle:a}},n.prototype.dragTargetEnd=function(t,e,i,r,s,o,a,l){var c,h=this.diagram.nameTable[t.id],d=this.checkBoundaryConstraints(e,i,h.wrapper.bounds);if(HI(h)&&"BezierTargetThumb"!==o&&d&&Qv(this.diagram)){if(c=$(c={targetPoint:h.targetPoint}),h.targetPoint.x+=e,h.targetPoint.y+=i,"ConnectorTargetEnd"===o&&"Orthogonal"===h.type&&h.segments&&h.segments.length>0){var u=h.segments[h.segments.length-2];u&&2===h.segments[h.segments.length-1].points.length&&("Left"===u.direction||"Right"===u.direction?u.points[u.points.length-1].x=h.targetPoint.x:u.points[u.points.length-1].y=h.targetPoint.y,u.length=R.distancePoints(u.points[0],u.points[u.points.length-1]),u.direction=R.direction(u.points[0],u.points[u.points.length-1]))}"Bpmn"===h.shape.type&&"Default"===h.shape.sequence&&"Sequence"===h.shape.flow&&this.updatePathElementOffset(h)}if("Bezier"===h.type)if(c={targetPoint:h.targetPoint},l)this.translateBezierPoints(t,""===o?"ConnectorTargetEnd":o,e,i,l,s,!a);else for(var f=0;f0){if(void 0!==s&&o.segments[parseInt(s.toString(),10)])if("Bezier"===o.type){var a=o.segments[parseInt(s.toString(),10)],l=a.isInternalSegment;l&&null!==o.bezierSettings&&"FreeForm"!==o.bezierSettings.segmentEditOrientation?("Horizontal"===a.orientation?a.point.x+=e:a.point.y+=i,this.updateDirectionalBezierCurve(o)):(a.point.x+=e,a.point.y+=i),l&&(o.isBezierEditing=!0)}else o.segments[parseInt(s.toString(),10)].point.x+=e,o.segments[parseInt(s.toString(),10)].point.y+=i;else for(var h=0;h1){var a=e[1],l=e[2],h={x:.5*(a.x+l.x),y:.5*(a.y+l.y)},c=t.segments[0];c.vector1.angle=Gt(s,a),c.vector1.distance=.5*R.findLength(s,a),c.vector2.angle=Gt(h,a),c.vector2.distance=.5*R.findLength(h,a),c.point=h;var d=t.segments[1];if(d.vector1.angle=Gt(h,l),d.vector1.distance=.5*R.findLength(h,l),t.segments.length>2){var u=e[3],f={x:.5*(l.x+u.x),y:.5*(l.y+u.y)};d.vector2.angle=Gt(f,l),d.vector2.distance=.5*R.findLength(f,l),d.point=f;var p=t.segments[2];if(p.vector1.angle=Gt(f,u),p.vector1.distance=.5*R.findLength(f,u),t.segments.length>3){var g=e[4],v={x:.5*(u.x+g.x),y:.5*(u.y+g.y)};p.vector2.angle=Gt(v,u),p.vector2.distance=.5*R.findLength(v,u),p.point=v;var y=t.segments[3];y.vector1.angle=Gt(v,g),y.vector1.distance=.5*R.findLength(v,g),y.vector2.angle=Gt(o,g),y.vector2.distance=.5*R.findLength(o,g)}else p.vector2.angle=Gt(o,u),p.vector2.distance=.5*R.findLength(o,u)}else d.vector2.angle=Gt(o,l),d.vector2.distance=.5*R.findLength(o,l)}},n.prototype.rotateObjects=function(t,e,i,r,s){r=r||{};var o=Bi();qi(o,i,r.x,r.y);for(var l=0,h=e;l0){this.diagram.protectPropertyChange(!0);var o=t;o.segments=[],this.diagram.connectorPropertyChange(o,{},{segments:o.segments}),this.diagram.protectPropertyChange(!1)}}},n.prototype.updateInnerParentProperties=function(t){var r=this.diagram.isProtectedOnChange;this.diagram.protectPropertyChange(!0);for(var s=this.getAllDescendants(t,[],!1,!0),o=0;o0&&(f=this.diagram.bpmnModule.getChildrenBound(d,d.id,this.diagram),u=d.wrapper.bounds.containsRect(f)),h=d.wrapper.actualSize.width*t,c=d.wrapper.actualSize.height*e,void 0!==d.maxWidth&&0!==d.maxWidth&&(h=Math.min(d.maxWidth,h)),void 0!==d.minWidth&&0!==d.minWidth&&(h=Math.max(d.minWidth,h)),void 0!==d.maxHeight&&0!==d.maxHeight&&(c=Math.min(d.maxHeight,c)),void 0!==d.minHeight&&0!==d.minHeight&&(c=Math.max(d.minHeight,c)),u&&(h=Math.max(h,f.right-d.wrapper.bounds.x),c=Math.max(c,f.bottom-d.wrapper.bounds.y)),t=h/d.actualSize.width,e=c/d.actualSize.height}var p=Bi();o||(o=r);var g=o.wrapper;if(qi(p,-g.rotateAngle,i.x,i.y),qf(p,t,e,i.x,i.y),qi(p,g.rotateAngle,i.x,i.y),r instanceof te){var d,v=Ke(p,{x:(d=r).wrapper.offsetX,y:d.wrapper.offsetY}),y=d.wrapper.offsetX-d.wrapper.actualSize.width*d.pivot.x,S=d.wrapper.offsetY-d.wrapper.actualSize.height*d.pivot.y;if(h>0)if(d.processId){var b=this.diagram.nameTable[d.processId];(!b.maxWidth||d.margin.left+h0)if(d.processId){var M=this.diagram.nameTable[d.processId];(!M.maxHeight||d.margin.top+c0){if(e.dragLimit=e.dragLimit?e.dragLimit:{},e.dragLimit.top||e.dragLimit.bottom||e.dragLimit.left||e.dragLimit.right){var b={minDistance:null};S=this.getRelativeOffset(v,d,b);var M={minDistance:null};g=this.getRelativeOffset(v,y,M),S=null!=b&&M.minDistance0){if(S=y[y.length-1]){var b=void 0;for(b=0;b=e.x-t.dragLimit.left-r.width/2&&i.x<=e.x+t.dragLimit.right+r.width/2&&(s=!0),i.y>=e.y-t.dragLimit.top-r.height/2&&i.y<=e.y+t.dragLimit.bottom+r.height/2&&(o=!0),{x:s,y:o}},n.prototype.updateLabelMargin=function(t,e,i,r,s,o,a){if(i=i||{x:e.offset,y:0},e&&i&&i.x>0&&i.x<1){var l=R.getLengthFromListOfPoints(t.intermediatePoints),h=this.getPointAtLength(l*i.x,t.intermediatePoints,0),c=this.diagram.scrollSettings.currentZoom,d=e.dragLimit?e.dragLimit:{left:0,right:0,top:0,bottom:0};if(d.top||d.bottom||d.left||d.right){this.diagram.getWrapper(t.wrapper,e.id);var f=new Ne(0,0,0,0),p=this.diagram.getWrapper(t.wrapper,e.id);f.x=p.offsetX/c+o,f.y=p.offsetY/c+a,f.width=p.bounds.width/c,f.height=p.bounds.height/c;var g=new Ne(h.x-(d.left||0)-f.width/2,h.y-(d.top||0)-f.height/2,(d.left||0)+(d.right||0)+f.width,(d.top||0)+(d.bottom||0)+f.height);if(g.containsPoint(r));else for(var S=0,b=this.boundsInterSects([h,r],g,!1);S=t){c=t-r,d=R.findAngle(s,a),u=c*Math.cos(d*Math.PI/180),f=c*Math.sin(d*Math.PI/180),o={x:s.x+u,y:s.y+f};break}r+=h,s=a}else s=a;return o},n.prototype.getInterceptWithSegment=function(t,e){for(var o,a,i=[],r=[],s=[],l=R.findLength({x:0,y:0},{x:this.diagram.scroller.viewPortWidth,y:this.diagram.scroller.viewPortHeight}),h=1;h0&&a<=90||a>180&&a<=270?90:-90;r.push(R.transform(t,a+c,l)),r.push(R.transform(t,o+c,l));var f=nm({x1:s[0].x,y1:s[0].y,x2:s[1].x,y2:s[1].y},{x1:r[0].x,y1:r[0].y,x2:r[1].x,y2:r[1].y});f.enabled&&i.push(f.intersectPt)}return i},n.prototype.getAnnotationChanges=function(t,e){var r={};return r[hb(t,e.id,!0)]={width:e.width,height:e.height,offset:t instanceof te?{x:e.offset.x,y:e.offset.y}:e.offset,rotateAngle:e.rotateAngle,margin:{left:e.margin.left,right:e.margin.right,top:e.margin.top,bottom:e.margin.bottom},horizontalAlignment:e.horizontalAlignment,verticalAlignment:e.verticalAlignment,alignment:t instanceof de?e.alignment:void 0},{annotations:r}},n.prototype.getConnectorPortChanges=function(t,e){var i=function Wse(n,t,e){for(var i=n.ports,r=0;r1&&(v.width=g,v.offset.x=1/S),p>1&&(v.height=p,v.offset.y=1/b)}}e instanceof Or&&(e.alignment="Center"),l=this.getAnnotationChanges(t,e),t instanceof te?this.diagram.nodePropertyChange(t,a,l):this.diagram.connectorPropertyChange(t,a,l),this.diagram.updateDiagramObject(t)},n.prototype.getSubProcess=function(t){var i,e={nodes:[],connectors:[]};return t instanceof te?i=t.processId:t&&t.nodes&&t.nodes.length&&t.nodes[0].processId&&(i=t.nodes[0].processId),i&&e.nodes.push($(this.diagram.nameTable[i])),e},n.prototype.checkBoundaryConstraints=function(t,e,i,r){var s=this.diagram.pageSettings,o=this.diagram.pageSettings.boundaryConstraints,a=this.diagram.scroller;if("Page"===o||"Diagram"===o){var l=i?void 0:this.diagram.selectedItems.wrapper.bounds;return!!((i?i.right:l.right)+(t||0)<=("Page"===o?s.width:a.viewPortWidth)&&(i?i.left:l.left)+(t||0)>=0&&(i?i.bottom:l.bottom)+(e||0)<=("Page"===o?s.height:a.viewPortHeight)&&(i?i.top:l.top)+(e||0)>=0||"None"!==this.diagram.layout.type&&r)}return!0},n.prototype.dragSelectedObjects=function(t,e){var i=this,r=this.diagram.selectedItems;this.state&&!this.state.backup&&(this.state.backup={},this.state.backup.offsetX=r.offsetX,this.state.backup.offsetY=r.offsetY),r=$I(this.diagram,r)||r;var s=this.diagram.selectedItems.nodes.filter(function(c){return"SwimLane"===c.shape.type});if(s.length>0&&!this.diagram.currentSymbol&&this.diagram.selectedItems.nodes.length>1){var o=this.diagram.selectedItems.nodes.filter(function(c){return""===c.parentId||"SwimLane"!==i.diagram.nameTable[c.parentId].shape.type});if(o.length>0){for(var a=0;a0||l.length>1)&&(o=o.concat(l),this.diagram.selectedItems.nodes.splice(0,this.diagram.selectedItems.nodes.length),o.forEach(function(c){i.diagram.selectedItems.nodes.push(c)}),r=this.diagram.selectedItems,this.diagram.selectedObject.helperObject=void 0)}}if(this.checkBoundaryConstraints(t,e)){this.diagram.diagramActions=this.diagram.diagramActions|ee.PreventZIndexOnDragging|ee.DragUsingMouse;var h=this.diagram.selectedObject.actualObject;return(h&&h instanceof te&&h.isLane&&Gx(h,this.diagram)||!h||!h.isLane)&&this.diagram.drag(r,t,e),this.diagram.diagramActions=this.diagram.diagramActions&~(ee.PreventZIndexOnDragging|ee.DragUsingMouse),this.diagram.refreshCanvasLayers(),this.checkHtmlObjectDrag(r),!0}return!1},n.prototype.checkHtmlObjectDrag=function(t){var e=!1;this.diagram.views&&this.diagram.views.length>1&&(t instanceof ei?e=t.nodes.some(function(i){return i.shape&&"HTML"===i.shape.type}):t.shape&&"HTML"===t.shape.type&&(e=!0),e&&this.resetOverviewCanvas())},n.prototype.resetOverviewCanvas=function(){for(var t=0,e=this.diagram.views;t0&&(this.layoutAnimateModule.stopCurrentAnimation(this.objectStore[0],e,t),this.objectStore=[]),a=this.diagram.doLayout(),this.objectStore.push(a)),this.canUpdateTemplate=!1,this.diagram.blazorActions&=~on.expandNode,this.diagram.preventNodesUpdate=r,this.diagram.layoutAnimateModule&&this.diagram.organizationalChartModule&&!i)this.diagram.allowServerDataBinding=!1,this.layoutAnimateModule.expand(this.diagram.layout.enableAnimation,a,t,this.diagram);else{var l={element:$(t),state:!!t.isExpanded};this.triggerEvent(Ce.expandStateChange,l),this.diagram.lineRoutingModule&&this.diagram.constraints&nt.LineRouting&&"ComplexHierarchicalTree"!==this.diagram.layout.type&&this.diagram.resetSegments()}return this.diagram.layout.fixedNode=""===o?"":this.diagram.layout.fixedNode,a},n.prototype.getparentexpand=function(t,e,i,r){for(var s,o=0;o0&&(this.diagram.selectedItems.wrapper.rotateAngle=this.diagram.selectedItems.rotateAngle=s.rotateAngle),!(r instanceof te&&"SwimLane"!==r.shape.type)||r.isLane||r.isPhase||r.isHeader||Dn(this.diagram,r)){if(r instanceof ei)for(var d=0;d30||g.wrapper.outerBounds.topCenter.y-p.wrapper.outerBounds.bottomCenter.y>30)&&this.diagram.lineRoutingModule.refreshConnectorSegments(this.diagram,f,!0)}}this.updateSelector(),this.diagram.protectPropertyChange(!1)}},n.prototype.drawSelectionRectangle=function(t,e,i,r){this.diagram.drawSelectionRectangle(t,e,i,r)},n.prototype.startGroupAction=function(){this.diagram.startGroupAction()},n.prototype.endGroupAction=function(){this.diagram.endGroupAction()},n.prototype.removeChildFromBPmn=function(t,e,i){var r=this.diagram.nameTable[t.id]||t.nodes[0];if(i&&r&&r.processId&&r.processId===i.wrapper.id){var s=$(r);s.processId=r.processId,this.diagram.startGroupAction();var o=this.diagram.nameTable[r.processId].shape.activity.subProcess.processes||[];o.splice(o.indexOf(r.id),1),this.diagram.bpmnModule.removeChildFromBPMN(this.diagram.nameTable[r.processId].wrapper,r.id,this.diagram),this.diagram.nameTable[r.id].processId="",r.offsetX=r.wrapper.offsetX,r.offsetY=r.wrapper.offsetY;var a=$(r);this.addHistoryEntry({type:"PositionChanged",redoObject:{nodes:[a]},undoObject:{nodes:[s]},category:"Internal"}),this.diagram.endGroupAction()}},n.prototype.isDroppable=function(t,e){var i=this.diagram.nameTable[t.id]||t.nodes[0];return i instanceof te&&(!ce()&&"TextAnnotation"===i.shape.shape||("Group"===e.shape.shape&&(e.shape.activity.subProcess.collapsed=!1),!(i&&"Bpmn"===i.shape.type&&(i.processId===e.id||i.id===e.processId||"Bpmn"===e.shape.type&&!(e instanceof de)&&e.shape.activity&&e.shape.activity.subProcess&&e.shape.activity.subProcess.collapsed))))},n.prototype.renderHighlighter=function(t,e,i){if(new Ne,t.target instanceof te||t.target instanceof de||e&&(t.source instanceof te||t.source instanceof de)){var a=this.findTarget(e?t.sourceWrapper:t.targetWrapper,e?t.source:t.target,i,!0),l=void 0;if(a instanceof Fd)for(var h=a.id,c=t.target,u=0,f=c.wrapper.children[0].children[0].children[2].children;u0){var r=0;t[0]=this.diagram.nameTable[t[0].id]||t[0];var s="Object"===i?yr(t[0].wrapper):this.diagram.selectedItems.wrapper.bounds,o={nodes:[],connectors:[]},a={nodes:[],connectors:[]};for(r="Object"===i?r+1:r;r0){var i=0,r=0,s=0,o=0,a=0,l=0,h=0,c=0,d={nodes:[],connectors:[]},u={nodes:[],connectors:[]};for(i=0;io.center.y&&(r=n[parseInt(e.toString(),10)],n[parseInt(e.toString(),10)]=n[parseInt(i.toString(),10)],n[parseInt(i.toString(),10)]=r):s.center.x>o.center.x&&(r=n[parseInt(e.toString(),10)],n[parseInt(e.toString(),10)]=n[parseInt(i.toString(),10)],n[parseInt(i.toString(),10)]=r)}}return n}(t,e),i=1;i0){var i=0,r={x:.5,y:.5};t[0]=this.diagram.nameTable[t[0].id]||t[0];var s=yr(t[0].wrapper),o={nodes:[],connectors:[]},a={nodes:[],connectors:[]};for(i=1;ii.zIndex){for(var s=this.diagram.layers.indexOf(this.diagram.getActiveLayer()),o=this.diagram.layers[parseInt(s.toString(),10)].zIndexTable,a=JSON.parse(JSON.stringify(o)),l=i.zIndex,h=r.zIndex,c=h;c>=l;c--)l!==c?o[c-1]?(o[parseInt(c.toString(),10)]=o[c-1],this.diagram.nameTable[o[parseInt(c.toString(),10)]].zIndex=c):(o[c-1]=o[parseInt(c.toString(),10)],this.diagram.nameTable[o[c-1]].zIndex=c,delete o[parseInt(c.toString(),10)]):this.swapZIndexObjects(h,o,r.id,a);"SVG"===this.diagram.mode?(this.moveSvgNode(e.parentId,i.id),this.updateNativeNodeIndex(e.parentId,i.id)):this.diagram.refreshCanvasLayers()}},n.prototype.findLeastIndexConnector=function(t,e,i){for(var r=0;rs.zIndex&&(i=s)}return i},n.prototype.findLeastIndexObject=function(t,e){var i=t;return t instanceof te&&(i=this.findLeastIndexConnector(t.inEdges,e,i),i=this.findLeastIndexConnector(t.outEdges,e,i)),i},n.prototype.checkSelection=function(t,e){var i;if(1===t.nodes.length&&0===t.connectors.length)if(Dn(this.diagram,t.nodes[0],!0)){var r=t.nodes[0];if("SwimLane"===(i="SwimLane"===t.nodes[0].shape?t.nodes[0]:this.diagram.nameTable[t.nodes[0].parentId]).shape.type){var s="Horizontal"===i.shape.orientation;(r.isPhase&&(s&&"ResizeSouth"===e||!s&&"ResizeEast"===e)||r.isLane&&(s&&"ResizeEast"===e||!s&&"ResizeSouth"===e))&&W3(this.diagram,i,e)}else if("Grid"===i.container.type)if("Horizontal"===i.container.orientation&&1===r.rowIndex||"Vertical"===i.container.orientation&&r.rowIndex>0&&r.columnIndex>0){if("ResizeSouth"===e)for(var o=0;o1&&(this.diagram.realActions=this.diagram.realActions|$i.hScrollbarMoved,this.scrolled=!0),this.diagram.scrollSettings.horizontalOffset=t},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"verticalOffset",{get:function(){return this.vOffset},set:function(t){this.vOffset=t,Math.abs(this.vOffset-this.diagram.scrollSettings.verticalOffset)>1&&(this.diagram.realActions=this.diagram.realActions|$i.vScrollbarMoved,this.scrolled=!0),this.diagram.scrollSettings.verticalOffset=t},enumerable:!0,configurable:!0}),n.prototype.getBounds=function(){var e=this.diagram.spatialSearch.getPageBounds(0,0);return(e.x<0||e.y<0)&&!this.diagram.pageSettings.multiplePage?this.getPageBounds(void 0,void 0,!0,!0):this.getPageBounds(void 0,void 0,!0)},n.prototype.updateScrollOffsets=function(t,e){var i,r,s=this.getBounds();s.x*=this.currentZoom,s.y*=this.currentZoom,s.width*=this.currentZoom,s.height*=this.currentZoom,i=Math.max(0,t-s.left),r=Math.max(0,e-s.top),void 0!==t&&void 0!==e?(this.horizontalOffset=i,this.verticalOffset=r,this.diagram.setOffset(i,r)):this.diagram.setOffset(-this.horizontalOffset-s.x,-this.verticalOffset-s.y),this.transform={tx:Math.max(this.horizontalOffset,-s.left)/this.currentZoom,ty:Math.max(this.verticalOffset,-s.top)/this.currentZoom,scale:this.currentZoom}},n.prototype.setScrollOffset=function(t,e){this.scrolled=!1;var i=this.getBounds();i.x*=this.currentZoom,i.y*=this.currentZoom,i.width*=this.currentZoom,i.height*=this.currentZoom;var r=-i.left,s=-i.top,o=!1,a=this.viewPortWidth*this.currentZoom,l=this.viewPortHeight*this.currentZoom,h=r-t;if(h!==this.horizontalOffset){rh?this.horizontalOffset-=t:this.horizontalOffset=h,o=!0);var c=Math.max(i.right+this.vScrollSize,a);if(!o&&c<-h+this.viewPortWidth){var d=-h+a-this.vScrollSize,u=-this.horizontalOffset+a-this.vScrollSize;this.horizontalOffset=dd-u?h:-(i.right+this.vScrollSize-a),o=!0}o||(this.horizontalOffset=r-t)}o=!1;var f=s-e;if(f!==this.verticalOffset){sf?this.verticalOffset-=e:this.verticalOffset=f,o=!0);var p=Math.max(i.bottom+this.hScrollSize,l);if(!o&&p<-f+l){var g=-f+l-this.hScrollSize,v=-this.verticalOffset+l-this.hScrollSize;this.verticalOffset=gg-v?f:-(i.bottom+this.hScrollSize-l),o=!0}o||(this.verticalOffset=s-e)}this.transform={tx:Math.max(this.horizontalOffset,-i.left)/this.currentZoom,ty:Math.max(this.verticalOffset,-i.top)/this.currentZoom,scale:this.currentZoom},this.setSize()},n.prototype.getObjects=function(t,e){for(var i=[],r=0;r0){for(var l=0;l0){h.push(i[parseInt(o.toString(),10)].id);for(var d=0;d=e.bottom&&(l=0),-this.horizontalOffset<=e.x&&-this.horizontalOffset+this.viewPortWidth>=e.right&&(a=0),this.hScrollSize=a,this.vScrollSize=l;var h=this.diagramWidth,c=this.diagramHeight;this.diagramWidth=Math.max(e.right,-this.horizontalOffset+this.viewPortWidth-l)-i,this.diagramHeight=Math.max(e.bottom,-this.verticalOffset+this.viewPortHeight-a)-r,(h!==this.diagramWidth||c!==this.diagramHeight)&&"Diagram"!==this.diagram.scrollSettings.scrollLimit&&this.diagram.setSize(this.diagramWidth,this.diagramHeight),"Diagram"===this.diagram.scrollSettings.scrollLimit&&(h===this.diagramWidth&&c===this.diagramHeight&&1===this.currentZoom||this.diagram.diagramActions&&t&&(!this.diagram.diagramActions||!t||0===this.verticalOffset&&this.verticalOffset!==t.y||0===this.horizontalOffset&&this.horizontalOffset!==t.x)?t&&h===this.diagramWidth&&c===this.diagramHeight&&(this.diagram.diagramCanvas.scrollHeight>this.viewPortHeight&&t.y<0&&this.horizontalOffset===t.x&&0===this.verticalOffset||this.diagram.diagramCanvas.scrollWidth>this.viewPortWidth&&t.x<0&&this.verticalOffset===t.y&&0===this.horizontalOffset)&&(this.verticalOffset=t.y,this.horizontalOffset=t.x,this.transform={tx:Math.max(t.x,-e.left)/this.currentZoom,ty:Math.max(t.y,-e.top)/this.currentZoom,scale:this.currentZoom}):(this.diagram.scrollActions&da.Interaction&&t&&(this.transform={tx:Math.max(t.x,-e.left/this.currentZoom)/this.currentZoom,ty:Math.max(t.y,-e.top/this.currentZoom)/this.currentZoom,scale:this.currentZoom},this.horizontalOffset=t.x,this.verticalOffset=t.y),this.diagram.setSize(this.diagramWidth,this.diagramHeight),!(this.diagram.scrollActions&da.PropertyChange)&&t&&(this.horizontalOffset=t.x,this.verticalOffset=t.y,this.transform={tx:Math.max(t.x,-e.left)/this.currentZoom,ty:Math.max(t.y,-e.top)/this.currentZoom,scale:this.currentZoom}))),this.diagram.transformLayers(),this.diagram.element.style.overflow="hidden"},n.prototype.setViewPortSize=function(t,e){this.viewPortWidth=t,this.viewPortHeight=e},n.prototype.getPageBounds=function(t,e,i,r){var o,s=new Ne;if("Content"===e||r||null===this.diagram.pageSettings.width||null===this.diagram.pageSettings.height){var u=t?void 0:0;o=this.diagram.spatialSearch.getPageBounds(u,u)}else{var a=this.diagram.pageSettings.width,l=this.diagram.pageSettings.height,h=0,c=0;if(this.diagram.pageSettings.multiplePage){if((s=this.diagram.spatialSearch.getPageBounds(0,0)).right>a&&(a*=d=Math.ceil(s.right/a)),s.bottom>l&&(l*=d=Math.ceil(s.bottom/l)),s.left<0&&Math.abs(s.left)>h){var d=Math.ceil(Math.abs(s.left)/this.diagram.pageSettings.width);h=this.diagram.pageSettings.width*d}s.top<0&&Math.abs(s.top)>c&&(d=Math.ceil(Math.abs(s.top)/this.diagram.pageSettings.height),c=this.diagram.pageSettings.height*d)}o=new Ne(-h,-c,a+h,l+c)}if(i){var f=this.diagram.scrollSettings.padding;o.x-=f.left,o.y-=f.top,o.width+=f.left+f.right,o.height+=f.top+f.bottom}return o},n.prototype.getPageBreak=function(t){for(var e=0,i=0,r=-1,s=[],c=this.diagram.pageSettings.margin.left,d=this.diagram.pageSettings.margin.right,u=this.diagram.pageSettings.margin.top,f=this.diagram.pageSettings.margin.bottom,p=1,g=1;t.width>e;)(e+=this.diagram.pageSettings.width?this.diagram.pageSettings.width:t.width)===this.diagram.pageSettings.width&&(s[++r]={x1:t.left+c,y1:t.top+u,x2:t.left+c,y2:t.bottom-f}),ei;)(i+=this.diagram.pageSettings.height?this.diagram.pageSettings.height:t.height)===this.diagram.pageSettings.height&&(s[++r]={x1:t.left+c,y1:t.top+u,x2:t.right-d,y2:t.top+u}),i=this.diagram.scrollSettings.minZoom||l||t>=1)){this.currentZoom*=t;var c=this.getPageBounds(void 0,void 0,!0);c.x*=this.currentZoom,c.y*=this.currentZoom;var d=Bi();qf(d,t,t,r.x,r.y),r3(d,e||0,i||0),Mx(h,d);var u=Ke(h,{x:0,y:0});if(1===t&&(u=this.applyScrollLimit(u.x,u.y,s,o,a)),a=-c.y>=u.y&&-c.x>=u.x&&a,(this.diagram.scrollActions&da.PropertyChange||!(this.diagram.scrollActions&da.Interaction)||"Diagram"!==this.diagram.scrollSettings.scrollLimit||a)&&(this.transform={tx:Math.max(u.x,-c.left)/this.currentZoom,ty:Math.max(u.y,-c.top)/this.currentZoom,scale:this.currentZoom},this.horizontalOffset=u.x,this.verticalOffset=u.y),this.setSize(u),"SVG"!==this.diagram.mode&&Ds(this.diagram)&&this.diagram.scroller.virtualizeElements(),"SVG"!==this.diagram.mode&&!Ds(this.diagram)&&this.diagram.refreshDiagramLayer(),this.diagram.setOffset(-this.horizontalOffset-c.x,-this.verticalOffset-c.y),ib(this.diagram),this.diagram.views&&this.diagram.views.overview){var f=this.diagram.views.overview,p=f.scrollOverviewRect(f.parent.scroller.horizontalOffset,f.parent.scroller.verticalOffset,f.parent.scroller.currentZoom,!0);f.updateOverviewrect(-p.x,-p.y,p.width,p.height),f.updateView(f)}}}},n.prototype.fitToPage=function(t){var e=(t=t||{}).mode,i=t.region,r=t.margin||{},s=t.canZoomIn,o=t.customBounds,a=t.canZoomOut;r.bottom=r.bottom||25,r.top=r.top||25,r.left=r.left||25,r.right=r.right||25;var h,l=o,c=-this.horizontalOffset,d=-this.verticalOffset;if("PageSettings"===(i=i||"PageSettings")&&this.diagram.pageSettings.width&&this.diagram.pageSettings.height||this.diagram.nodes.length>0||this.diagram.connectors.length>0){e=e||"Page","CustomBounds"!==i&&(l=this.getPageBounds(!0,i,!0));var u={x:0,y:0};r.left+r.right>this.viewPortWidth&&(this.viewPortWidth<=100?(r.left=5,r.right=5):(r.left=25,r.right=25)),r.top+r.bottom>this.viewPortHeight&&(this.viewPortHeight<=100?(r.top=5,r.bottom=5):(r.top=25,r.bottom=25)),u.x=(this.viewPortWidth-(r.left+r.right))/l.width,u.y=(this.viewPortHeight-(r.top+r.bottom))/l.height,!s&&l.width-this.horizontalOffset-a+this.viewPortWidth&&(i=o.right-this.viewPortWidth,i+=20),o.x<-a&&(i=o.x),o.bottom>-l+this.viewPortHeight&&(r=o.bottom-this.viewPortHeight,r+=20),o.y<-l&&(r=o.y),this.zoom(1,-this.horizontalOffset-i,-this.verticalOffset-r,null,void 0,e))},n.prototype.bringToCenter=function(t){var e=this.currentZoom,i=new Ne(t.x*e,t.y*e,t.width*e,t.height*e),r=i.x+i.width/2-this.viewPortWidth/2,s=i.y+i.height/2-this.viewPortHeight/2;this.zoom(1,-this.horizontalOffset-(r*=-1),-this.verticalOffset-(s*=-1),null)},n.prototype.applyScrollLimit=function(t,e,i,r,s){if("Infinity"===this.diagram.scrollSettings.scrollLimit&&void 0===i&&!r&&(t=-t,e=-e),"Infinity"!==this.diagram.scrollSettings.scrollLimit){var o=void 0;if("Limited"===this.diagram.scrollSettings.scrollLimit){var a=this.diagram.scrollSettings.scrollableArea;o=new Ne(a.x,a.y,a.width,a.height)}(o=o||(s?this.getPageBounds():this.getPageBounds(!0))).x*=this.currentZoom,o.y*=this.currentZoom,o.width*=this.currentZoom,o.height*=this.currentZoom,void 0!==i&&(t*=-1,e*=-1),r&&(t*=-1,e*=-1);var l=Math.max(o.right,this.viewPortWidth);if(!r&&!(t<=o.x&&(t+this.viewPortWidth>=o.right||t>=o.right-this.viewPortWidth)||t>=o.x&&t+this.viewPortWidth<=l))if(t>=o.x)t=Math.max(o.x,Math.min(t,t-(t+this.viewPortWidth-this.vScrollSize-l)));else{var h=o.right-this.viewPortWidth;t=Math.min(h,o.x)}var c=Math.max(o.bottom,this.viewPortHeight);r||e<=o.y&&e+this.viewPortHeight>=o.bottom||e>=o.y&&e+this.viewPortHeight<=c||(e>=o.y?e=Math.max(o.y,Math.min(e,e-(e+this.viewPortHeight-this.hScrollSize-c))):(h=o.bottom-this.viewPortHeight,e=Math.min(o.y,h))),t*=-1,e*=-1}return{x:t,y:e}},n}(),tae=function(){function n(t,e,i,r,s){this.objects=[],this.left=t,this.top=e,this.width=i,this.height=r,this.spatialSearch=s}return n.prototype.findQuads=function(t,e){null!=this.first&&this.first.isIntersect(t)&&this.first.findQuads(t,e),null!=this.second&&this.second.isIntersect(t)&&this.second.findQuads(t,e),null!=this.third&&this.third.isIntersect(t)&&this.third.findQuads(t,e),null!=this.fourth&&this.fourth.isIntersect(t)&&this.fourth.findQuads(t,e),this.objects.length>0&&e.push(this)},n.prototype.isIntersect=function(t){return!(this.left+this.widtht.right||this.top>t.bottom)},n.prototype.selectQuad=function(){for(var i,t=null,e=this;null!=e;)i=e.getQuad(t),e=i.source,t=i.target||t;return t},n.prototype.getQuad=function(t){var e=this.width/2,i=this.height/2;if(e>=1e3&&i>=1e3){var r=this.left+e,s=this.top+i;if(this.spatialSearch.childRight<=r){if(this.spatialSearch.childBottom<=s)return this.first||((o=new n(this.left,this.top,e,i,this.spatialSearch)).parent=this,this.first=o),{source:this.first};if(this.spatialSearch.childTop>=s)return this.third||((o=new n(this.left,s,e,i,this.spatialSearch)).parent=this,this.third=o),{source:this.third}}else if(this.spatialSearch.childLeft>=r){if(this.spatialSearch.childBottom<=s)return this.second||((o=new n(r,this.top,e,i,this.spatialSearch)).parent=this,this.second=o),{source:this.second};var o;if(this.spatialSearch.childTop>=s)return this.fourth||((o=new n(r,s,e,i,this.spatialSearch)).parent=this,this.fourth=o),{source:this.fourth}}}return this.objects.push(this.spatialSearch.childNode),{target:this}},n.prototype.isContained=function(){return this.spatialSearch.childLeft>=this.left&&this.spatialSearch.childRight<=this.left+this.width&&this.spatialSearch.childTop>=this.top&&this.spatialSearch.childBottom<=this.top+this.height},n.prototype.addIntoAQuad=function(t){var e={};this.spatialSearch.setCurrentNode(t);for(var i=null;!e.isAdded;)i=(e=this.spatialSearch.parentQuad.add(i)).quad;return i},n.prototype.add=function(t){if(t=null,this.isContained())return{isAdded:!0,quad:t=this.selectQuad()};var e=void 0,i=!(0!==this.objects.length||this.first||this.second||this.third||this.fourth),r=2*this.width,s=2*this.height;return this.spatialSearch.childLeft=this.childLeft?(this.pageLeft=this.childLeft,this.leftElement=t,r=!0):t===this.leftElement&&(this.pageLeft=Number.MAX_VALUE,this.findLeft(this.parentQuad),r=!0)),(this.pageTop!==this.childTop||t!==this.topElement)&&(this.pageTop>=this.childTop?(this.pageTop=this.childTop,this.topElement=t,r=!0):t===this.topElement&&(this.pageTop=Number.MAX_VALUE,this.findTop(this.parentQuad),r=!0)),(this.pageBottom!==this.childBottom||t!==this.bottomElement)&&(this.pageBottom<=this.childBottom?(r=!0,this.pageBottom=this.childBottom,this.bottomElement=t):t===this.bottomElement&&(this.pageBottom=-Number.MAX_VALUE,this.findBottom(this.parentQuad),r=!0)),(this.pageRight!==this.childRight||t!==this.rightElement)&&(this.pageRight<=this.childRight?(this.pageRight=this.childRight,this.rightElement=t,r=!0):t===this.rightElement&&(this.pageRight=-Number.MAX_VALUE,this.findRight(this.parentQuad),r=!0)),r}return this.setCurrentNode(null),!1},n.prototype.isWithinPageBounds=function(t){return t.left>=this.pageLeft&&t.right<=this.pageRight&&t.top>=this.pageTop&&t.bottom<=this.pageBottom},n.prototype.findQuads=function(t){var e=[];return this.parentQuad.findQuads(t,e),e},n.prototype.findObjects=function(t){for(var i=[],r=0,s=this.findQuads(t);r=r.outerBounds.left&&(this.pageLeft=r.outerBounds.left,this.leftElement=r)}},n.prototype.findTop=function(t){t.first||t.second?(t.first&&this.findTop(t.first),t.second&&this.findTop(t.second)):(t.third&&this.findTop(t.third),t.fourth&&this.findTop(t.fourth));for(var e=0,i=t.objects;e=r.outerBounds.top&&(this.pageTop=r.outerBounds.top,this.topElement=r)}},n.prototype.setCurrentNode=function(t){if(this.childNode=t,t){var e=t.outerBounds;this.childLeft=Number(e.left),this.childTop=Number(e.top),this.childRight=Number(e.right),this.childBottom=Number(e.bottom)}else this.childLeft=Number.MAX_VALUE,this.childTop=Number.MAX_VALUE,this.childRight=-Number.MAX_VALUE,this.childBottom=-Number.MAX_VALUE},n.prototype.getPageBounds=function(t,e){if(this.pageLeft===Number.MAX_VALUE)return new Ne(0,0,0,0);var i=void 0!==t?Math.min(this.pageLeft,0):this.pageLeft,r=void 0!==e?Math.min(this.pageTop,0):this.pageTop;return new Ne(Math.round(i),Math.round(r),Math.round(this.pageRight-i),Math.round(this.pageBottom-r))},n.prototype.getQuad=function(t){return this.quadTable[t.id]},n}(),iae=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),nae=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return iae(t,n),function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);r>3&&s&&Object.defineProperty(t,e,s)}([I(!1)],t.prototype,"preventDefaults",void 0),t}(Ee),sae=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),o_=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},oae=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return sae(t,n),o_([I("")],t.prototype,"action",void 0),o_([I("")],t.prototype,"cursor",void 0),t}(Ee),a_=function(){function n(){this.size=20,this.intermediatePoints=[],this.gridCollection=[],this.startArray=[],this.targetGridCollection=[],this.sourceGridCollection=[],this.considerWalkable=[]}return n.prototype.lineRouting=function(t){var e=t.connectors.length;if(this.renderVirtualRegion(t),e>0)for(var i=0;i=t.right||e.right<=t.left||e.top>=t.bottom||e.bottom<=t.top)},n.prototype.findEndPoint=function(t,e,i){var r,s;if(e&&""!==t.sourcePortID&&t.sourcePortWrapper||!e&&""!==t.targetPortID&&t.targetPortWrapper){s=zo(r=e?{x:t.sourcePortWrapper.offsetX,y:t.sourcePortWrapper.offsetY}:{x:t.targetPortWrapper.offsetX,y:t.targetPortWrapper.offsetY},void 0,e?t.sourceWrapper.bounds:t.targetWrapper.bounds);var o=e?t.sourcePortWrapper.bounds:t.targetPortWrapper.bounds;r=i?"Top"===s?{x:o.topCenter.x,y:o.topCenter.y}:"Left"===s?{x:o.middleLeft.x,y:o.middleLeft.y}:"Right"===s?{x:o.middleRight.x,y:o.middleRight.y}:{x:o.bottomCenter.x,y:o.bottomCenter.y}:{x:o.center.x,y:o.center.y}}else r=e&&this.startNode||!e&&this.targetNode?e?{x:this.startNode.wrapper.offsetX,y:this.startNode.wrapper.offsetY}:{x:this.targetNode.wrapper.offsetX,y:this.targetNode.wrapper.offsetY}:e?{x:t.sourcePoint.x,y:t.sourcePoint.y}:{x:t.targetPoint.x,y:t.targetPoint.y};return r},n.prototype.refreshConnectorSegments=function(t,e,i,r){var h,c,f,p,g,y,S,b,M,w,C,s=e.sourceID,o=e.targetID,a=e.sourcePortID,l=e.targetPortID;if(function Jre(n,t){var e=0;return n.constraints&qe.LineRouting?e=n.constraints&qe.LineRouting:n.constraints&qe.InheritLineRouting&&(e=t.constraints&nt.LineRouting),e}(e,t)||r){this.startNode=t.nameTable[""+s],this.targetNode=t.nameTable[""+o],this.intermediatePoints=[],this.startArray=[],this.targetGridCollection=[],this.sourceGridCollection=[],this.startGrid=void 0,this.targetGrid=void 0;for(var D=0;D0;){var L=this.startArray.pop();if(L){for(D=0;D1&&(e.segments=[]),this.updateConnectorSegments(t,this.intermediatePoints,this.gridCollection,e,i)){this.considerWalkable=[];break e}this.targetGridCollection.splice(this.targetGridCollection.indexOf(O),1),L=this.startArray.pop()}}L&&this.findPath(L)}}}},n.prototype.checkChildNodes=function(t,e){var i=!1,r=!1;if(t.nodeId.length>=1&&!e)for(var s=0;s1&&this.targetGridCollection[0].nodeId.length>1)for(var c=0;c<=1;c++){for(var d=this.targetGridCollection[parseInt(c.toString(),10)].gridX,u=this.targetGridCollection[parseInt(c.toString(),10)].gridY,f=this.targetGridCollection[parseInt(c.toString(),10)].nodeId,p=void 0,g=0;g=e.right&&t.top<=e.top&&t.bottom>=e.bottom},n.prototype.getEndvalue=function(t,e){return this.gridCollection[t.gridX][t.gridY].walkable?t:"left"===e?this.getEndvalue(this.gridCollection[t.gridX-1][t.gridY],e):"right"===e?this.getEndvalue(this.gridCollection[t.gridX+1][t.gridY],e):"top"===e?this.getEndvalue(this.gridCollection[t.gridX][t.gridY-1],e):"bottom"===e?this.getEndvalue(this.gridCollection[t.gridX][t.gridY+1],e):t},n.prototype.changeValue=function(t,e,i){t.walkable||this.considerWalkable.push(t);for(var r,s=0;s<=e;s++)"left"===i?r=this.gridCollection[t.gridX-s][t.gridY]:"right"===i?r=this.gridCollection[t.gridX+s][t.gridY]:"top"===i?r=this.gridCollection[t.gridX][t.gridY-s]:"bottom"===i&&(r=this.gridCollection[t.gridX][t.gridY+s]),r.walkable||this.considerWalkable.push(r)},n.prototype.getIntermediatePoints=function(t){var e;for(this.intermediatePoints=[];t;)this.intermediatePoints.push({x:t.gridX,y:t.gridY}),t=t.parent;this.intermediatePoints.reverse(),this.intermediatePoints.length>=1&&void 0!==this.intermediatePoints[0]&&void 0!==this.intermediatePoints[1]&&(this.intermediatePoints[0].x===this.intermediatePoints[1].x?this.intermediatePoints[0].yi.y&&o.y>s.y){for(var a=i.xi.x&&o.x>s.x)){for(var u=i.y=1&&u.length>1&&(g=u[u.length-2].x!==u[u.length-1].x?u[u.length-2].x>u[u.length-1].x?"Left":"Right":u[u.length-2].y>u[u.length-1].y?"Top":"Bottom"),M>=2&&v===g&&u.length>1&&u.splice(u.length-2,1),v=g);if(u&&u.length>1){for(var w=0;wD.x?S.bounds.middleLeft:S.bounds.middleRight),w===u.length-2&&""===r.targetPortID&&y&&(l=C.x>D.x?y.bounds.middleRight:y.bounds.middleLeft),0===w&&b&&(C.x=b.x,C.y=D.y=b.y,b=qa(r,0,b,Ol(S.bounds,_n(C.x>D.x?"Left":"Right")),!1),C.x=b.x),w===u.length-2&&l&&(w>0&&r.targetDecorator&&l.x-D.x<0&&Math.abs(l.x-C.x)0&&r.targetDecorator&&l.x-D.x>0&&Math.abs(l.x-C.x)D.y?S.bounds.topCenter:S.bounds.bottomCenter),w===u.length-2&&""===r.targetPortID&&y&&(l=C.y>D.y?y.bounds.bottomCenter:y.bounds.topCenter),0===w&&b&&(C.y=b.y,C.x=D.x=b.x,b=qa(r,0,b,Ol(S.bounds,_n(C.y>D.y?"Top":"Bottom")),!1),C.y=b.y),w===u.length-2&&l&&(w>0&&r.targetDecorator&&l.y-D.y<0&&Math.abs(l.y-C.y)0&&r.targetDecorator&&l.y-D.y>0&&Math.abs(l.y-C.y)D.x?(f="Left",p=C.x-D.x):(f="Right",p=D.x-C.x):C.y>D.y?(f="Top",p=C.y-D.y):(f="Bottom",p=D.y-C.y),o.push({type:"Orthogonal",length:p,direction:f})}}if(o&&o.length>0){var L=o[o.length-1];if(1===o.length&&(L.length-=20),L.length<10&&2===o.length&&(o.pop(),o.length>0&&(o[0].length-=20,L=o[0])),r.targetDecorator&&("Top"===L.direction||"Bottom"===L.direction)&&L.length>r.targetDecorator.height+1||("Right"===L.direction||"Left"===L.direction)&&L.length>r.targetDecorator.width+1)return r.segments=o,s&&t.connectorPropertyChange(r,{},{type:"Orthogonal",segments:o}),!0}return!1},n.prototype.findPath=function(t){for(var e,i=[],r=this.findNearestNeigbours(t,this.gridCollection,!0),s=0;sl)&&(e.x!==t.gridX||e.y!==t.gridY)&&(i.push(e),o.previousDistance=l,o.afterDistance=o.afterDistance||this.manhattan(Math.abs(e.x-this.targetGrid.gridX),Math.abs(e.y-this.targetGrid.gridY)),o.totalDistance=o.previousDistance+o.afterDistance,o.parent=t)}if(i.length>0)for(s=0;st?i*t+e:i*e+t},n.prototype.manhattan=function(t,e){return t+e},n.prototype.findNearestNeigbours=function(t,e,i){var r=[],s=t.parent;if(s){var o=(t.gridX-s.gridX)/Math.max(Math.abs(t.gridX-s.gridX),1),a=(t.gridY-s.gridY)/Math.max(Math.abs(t.gridY-s.gridY),1);0!==o?(this.isWalkable(t.gridX,t.gridY-1,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX][t.gridY-1])&&r.push(e[t.gridX][t.gridY-1]),this.isWalkable(t.gridX,t.gridY+1,!0)&&this.sourceGridCollection.indexOf(e[t.gridX][t.gridY+1])&&r.push(e[t.gridX][t.gridY+1]),this.isWalkable(t.gridX+o,t.gridY,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX+o][t.gridY])&&r.push(e[t.gridX+o][t.gridY])):0!==a&&(this.isWalkable(t.gridX-1,t.gridY,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX-1][t.gridY])&&r.push(e[t.gridX-1][t.gridY]),this.isWalkable(t.gridX+1,t.gridY,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX+1][t.gridY])&&r.push(e[t.gridX+1][t.gridY]),this.isWalkable(t.gridX,t.gridY+a,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX][t.gridY+a])&&r.push(e[t.gridX][t.gridY+a]))}else this.neigbour(t,"top",r,i),this.neigbour(t,"right",r,i),this.neigbour(t,"bottom",r,i),this.neigbour(t,"left",r,i);return r},n.prototype.neigbour=function(t,e,i,r){for(var o,s=1;s>0;){var a="top"===e||"bottom"===e?t.gridX:"left"===e?t.gridX-s:t.gridX+s,l="right"===e||"left"===e?t.gridY:"top"===e?t.gridY-s:t.gridY+s;if((o=this.gridCollection[parseInt(a.toString(),10)][parseInt(l.toString(),10)])&&(r&&-1===this.sourceGridCollection.indexOf(o)||!r&&-1===this.targetGridCollection.indexOf(o)))return i&&this.isWalkable(a,l)&&i.push(o),s;if(!(a>0&&l>0))break;s++}return null},n.prototype.resetGridColl=function(t,e,i){for(var s,r=1;r>0;){var o="top"===e||"bottom"===e?t.gridX:"left"===e?t.gridX-r:t.gridX+r,a="right"===e||"left"===e?t.gridY:"top"===e?t.gridY-r:t.gridY+r;if((s=this.gridCollection[parseInt(o.toString(),10)][parseInt(a.toString(),10)])&&(i&&-1===this.sourceGridCollection.indexOf(s)||!i&&-1===this.targetGridCollection.indexOf(s))){if(this.isWalkable(o,a))break;var l=this.gridCollection[parseInt(o.toString(),10)][parseInt(a.toString(),10)];this.considerWalkable.push(l)}if(!(o>0&&a>0))break;"top"===e||"left"===e?r--:r++}return null},n.prototype.isWalkable=function(t,e,i){if(t>=0&&t=0&&e0?1:-1,this.isWalkable(h,c-1)&&!this.isWalkable(h-a,c-1)||this.isWalkable(h,c+1)&&!this.isWalkable(h-a,c+1)))return{x:t,y:e};if(0!==l){if(l=l>0?1:-1,this.isWalkable(h-1,c)&&!this.isWalkable(h-1,c-l)||this.isWalkable(h+1,c)&&!this.isWalkable(h+1,c-l))return{x:t,y:e};if(this.findIntermediatePoints(h+1,c,h,c,s,o)||this.findIntermediatePoints(h-1,c,h,c,s,o))return{x:t,y:e}}return this.findIntermediatePoints(h+a,c+l,h,c,s,o)},n.prototype.destroy=function(){},n.prototype.getModuleName=function(){return"LineRouting"},n}(),aae=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),hae=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return aae(t,n),function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);r>3&&s&&Object.defineProperty(t,e,s)}([I(!0)],t.prototype,"inversedAlignment",void 0),t}(Ee),cae=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Oe=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},TT=function(n,t,e,i){return new(e||(e=Promise))(function(r,s){function o(h){try{l(i.next(h))}catch(c){s(c)}}function a(h){try{l(i.throw(h))}catch(c){s(c)}}function l(h){h.done?r(h.value):new e(function(c){c(h.value)}).then(o,a)}l((i=i.apply(n,t||[])).next())})},AT=function(n,t){var i,r,s,o,e={label:0,sent:function(){if(1&s[0])throw s[1];return s[1]},trys:[],ops:[]};return o={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function a(h){return function(c){return function l(h){if(i)throw new TypeError("Generator is already executing.");for(;e;)try{if(i=1,r&&(s=2&h[0]?r.return:h[0]?r.throw||((s=r.return)&&s.call(r),0):r.next)&&!(s=s.call(r,h[1])).done)return s;switch(r=0,s&&(h=[2&h[0],s.value]),h[0]){case 0:case 1:s=h;break;case 4:return e.label++,{value:h[1],done:!1};case 5:e.label++,r=h[1],h=[0];continue;case 7:h=e.ops.pop(),e.trys.pop();continue;default:if(!(s=(s=e.trys).length>0&&s[s.length-1])&&(6===h[0]||2===h[0])){e=0;continue}if(3===h[0]&&(!s||h[1]>s[0]&&h[1]0&&((!s.style||!s.style.fill)&&(o.style.fill="transparent"),(!s.style||!s.style.strokeColor)&&(o.style.strokeColor="transparent")),s.shape&&"UmlActivity"===s.shape.type&&sb(s,o),s.shape&&"SwimLane"===s.shape.type&&fF(s,o),r.nodeDefaults&&Ro(o,s,r.nodeDefaults),r.updateAnnotationText(o.annotations);if(e&&e.connectors)for(a=0;e&&e.connectors&&a0&&0===i.nodes.length)this.clearCollection(),a=!0;else{for(var g=0,v=Object.keys(e.nodes);g0&&0===i.connectors.length)this.clearCollection(!0),a=!0;else{for(var C=0,D=Object.keys(e.connectors);C0){this.renderSelector(!0);break}if(e.selectedItems.constraints){this.renderSelector(!0);break}break;case"snapSettings":this.updateSnapSettings(e);break;case"commandManager":this.initCommands();break;case"layout":o=!0;break;case"segmentThumbShape":this.updateSelector();break;case"dataSourceSettings":this.clear(),"None"===this.layout.type?a=!0:(this.initObjects(),o=!0);break;case"tooltip":l3(this);break;case"rulerSettings":this.updateRulerSettings(e);break;case"layers":this.updateLayer(e);break;case"scrollSettings":this.scrollActions|=da.PropertyChange,this.updateScrollSettings(e),this.scrollActions&=~da.PropertyChange,this.scrollSettings.horizontalOffset=-this.scroller.horizontalOffset||0,this.scrollSettings.verticalOffset=-this.scroller.verticalOffset||0;break;case"locale":e.locale!==i.locale&&(this.realActions|=$i.PreventDataInit,n.prototype.refresh.call(this),this.realActions&=~$i.PreventDataInit);break;case"contextMenuSettings":if(void 0!==e.contextMenuSettings.showCustomMenuOnly&&(this.contextMenuSettings.showCustomMenuOnly=e.contextMenuSettings.showCustomMenuOnly),void 0!==e.contextMenuSettings.show&&(this.contextMenuSettings.show=e.contextMenuSettings.show),e.contextMenuSettings.items){for(var A=e.contextMenuSettings.items,x=0,P=Object.keys(A);x0){for(var N=[],T=O.ports.length-1;T>=0;T--)"LineDistribution"===O.ports[parseInt(T.toString(),10)].id.split("_")[1]&&N.push(O.ports[parseInt(T.toString(),10)]);this.removePorts(O,N)}}for(T=0;T0)for(var ue=0,fe=Object.keys(e.nodes);ue0)for(var De=0,xe=Object.keys(e.connectors);De=0;o--)this.commandHandler.expandNode(r[parseInt(o.toString(),10)],this,0!==o);this.canLayout&&this.doLayout(),this.lineRoutingModule?this.connectors.sourceID!==this.connectors.targetID&&this.lineRoutingModule.lineRouting(this):this.constraints&nt.LineRouting&&console.warn('[WARNING] :: Module "LineRouting" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),this.validatePageSize(),this.renderPageBreaks(),this.diagramRenderer.renderSvgGridlines(this.snapSettings,jd(this.element.id),this.scroller.transform,this.rulerSettings,this.hRuler,this.vRuler),this.commandHandler.initSelectorWrapper(),this.notify("initial-load",{}),this.trigger("load"),this.scroller.setSize(),this.scroller.updateScrollOffsets(),this.isRefreshed||this.refreshDiagramLayer(),(this.scrollSettings.verticalOffset>0||this.scrollSettings.horizontalOffset>0)&&this.updateScrollOffset(),X.isDevice&&(this.tool=ri.ZoomPan|ri.SingleSelect),this.notify("initial-end",{}),this.isProtectedOnChange=!1,this.tooltipObject=l3(this),this.diagramActions=ee.Render,this.initCommands();var a=document.getElementsByClassName(this.element.id+"_hiddenUserHandleTemplate");(function Noe(n,t,e,i){var r,s,o,a,l,d=document.getElementById(i).ej2_instances[0];if(n&&t){r=GF(n);for(var u=0,f=e.userHandles;u0;)e[0].parentNode.removeChild(e[0]);var i=document.getElementById(this.element.id+"content");i&&this.element.removeChild(i);var r="measureElement";if(window[""+r]){window[""+r].usageCount-=1;var s="measureElementCount";window[""+s]--,0===window[""+s]&&(window[""+r].parentNode.removeChild(window[""+r]),window[""+r]=null)}}window.domTable={};for(var a=0;a1&&(this.callBlazorModel=!1,this.insertBlazorDiagramObjects(this.selectedItems),this.commandHandler.group(),this.callBlazorModel=!0,this.commandHandler.getBlazorOldValues())},t.prototype.unGroup=function(){this.callBlazorModel=!1,this.insertBlazorDiagramObjects(this.selectedItems),this.commandHandler.unGroup(),this.callBlazorModel=!0,this.commandHandler.getBlazorOldValues()},t.prototype.sendToBack=function(){this.commandHandler.sendToBack()},t.prototype.setActiveLayer=function(e){var i=this.commandHandler.getLayer(e);this.activeLayer=i},t.prototype.addLayer=function(e,i){this.commandHandler.addLayer(e,i)},t.prototype.removeLayer=function(e){this.commandHandler.removeLayer(e,ce())},t.prototype.moveObjects=function(e,i){$(this.layers),this.enableServerDataBinding(!1),this.commandHandler.moveObjects(e,i)},t.prototype.layerObjectUpdate=function(){},t.prototype.sendLayerBackward=function(e){this.layerObjectUpdate(),this.commandHandler.sendLayerBackward(e)},t.prototype.bringLayerForward=function(e){this.layerObjectUpdate(),this.commandHandler.bringLayerForward(e)},t.prototype.cloneLayer=function(e){this.commandHandler.cloneLayer(e)},t.prototype.bringToFront=function(){this.commandHandler.bringToFront()},t.prototype.moveForward=function(){this.commandHandler.sendForward()},t.prototype.sendBackward=function(){this.commandHandler.sendBackward()},t.prototype.getObject=function(e){return this.nameTable[""+e]},t.prototype.getNodeObject=function(e){return $(this.nameTable[""+e])},t.prototype.getConnectorObject=function(e){return $(this.nameTable[""+e])},t.prototype.getActiveLayer=function(){return this.activeLayer},t.prototype.nudgeCommand=function(e,i,r){if("object"!=typeof e&&(this.selectedItems.nodes.length||this.selectedItems.connectors.length)>0){var s=void 0;i.type&&"KEYDOWN"===i.type&&(s=i.type),this.nudge(e,void 0,void 0,s)}},t.prototype.nudge=function(e,i,r,s){var o=0,a=0;"Left"===e||"Right"===e?o=("Left"===e?-1:1)*(i||1):a=("Up"===e?-1:1)*(r||1),"KEYDOWN"===s&&(o*=5,a*=5);var h=this.selectedItems,c=this.selectedItems.wrapper.children[0];if(c instanceof ai)this.commandHandler.labelDrag(h.nodes[0],c,o,a);else{var d=$(this.selectedItems);this.protectPropertyChange(!0),this.drag(h,o,a),this.protectPropertyChange(!1);var u={type:"PositionChanged",redoObject:$(this.selectedItems),undoObject:d,category:"Internal"};this.addHistoryEntry(u)}this.refreshCanvasLayers()},t.prototype.insertBlazorDiagramObjects=function(e){},t.prototype.drag=function(e,i,r){if(this.insertBlazorDiagramObjects(e),!(this.bpmnModule&&e instanceof te&&this.bpmnModule.updateAnnotationDrag(e,this,i,r))){if(e instanceof ei){if(this.preventConnectorsUpdate=!0,e.nodes&&e.nodes.length){for(var o=0,a=e.nodes;o0&&o.nodes[0].children){this.fromUndo||(this.rotateUsingButton=!0);for(var h=this.commandHandler.getAllDescendants(o.nodes[0],[]),c=0;c0&&o.nodes[0].children){var g={type:"RotationChanged",redoObject:$(e),undoObject:$(o),category:"Internal",childTable:a};this.commandHandler.addHistoryEntry(g),this.commandHandler.updateSelector()}return u},t.prototype.dragSourceEnd=function(e,i,r){this.insertBlazorDiagramObjects(e),this.commandHandler.dragSourceEnd(e,i,r),this.callBlazorModel&&this.commandHandler.getBlazorOldValues()},t.prototype.dragTargetEnd=function(e,i,r){this.insertBlazorDiagramObjects(e),this.commandHandler.dragTargetEnd(e,i,r),this.callBlazorModel&&this.commandHandler.getBlazorOldValues()},t.prototype.findObjectsUnderMouse=function(e,i){return this.eventHandler.findObjectsUnderMouse(e,i)},t.prototype.findObjectUnderMouse=function(e,i,r){return this.eventHandler.findObjectUnderMouse(e,i,r)},t.prototype.findTargetObjectUnderMouse=function(e,i,r,s,o){return this.eventHandler.findTargetUnderMouse(e,i,r,s,o)},t.prototype.findElementUnderMouse=function(e,i,r,s){return this.eventHandler.findElementUnderMouse(e,i,r,s)},t.prototype.findActionToBeDone=function(e,i,r,s){return this.eventHandler.findActionToBeDone(e,i,r,s)},t.prototype.updateConnectorPort=function(e){if(e.ports.length)for(var i=void 0,r=0,s=e.ports;r=0;s--)if(i.push(r[parseInt(s.toString(),10)]),i.length>this.historyManager.stackLimit)return i}else i=r;return i},t.prototype.getEdges=function(e){return e.outEdge?this.nameTable[e.id].outEdges:this.nameTable[e.id].inEdges},t.prototype.getParentId=function(e){return this.nameTable[""+e].parentId},t.prototype.addConnector=function(e){return this.add(e)},t.prototype.UpdateBlazorDiagramModelCollection=function(e,i,r,s){},t.prototype.UpdateBlazorDiagramModel=function(e,i,r,s){},t.prototype.UpdateBlazorLabelOrPortObjects=function(e,i,r,s){},t.prototype.addBlazorDiagramObjects=function(){},t.prototype.removeNodeEdges=function(e,i,r){var s=this.nameTable[""+e],o=r?s.outEdges:s.inEdges;if(o.length>0)for(var a=0;a0)){for(var c=0;c0))}this.removePortEdges(l,a.element.sourcePortID,a.element.id,h)}a.element.targetID&&this.removeNodeEdges(a.element.targetID,a.element.id,!1)}}this.diagramActions=this.diagramActions|ee.PublicMethod,e.id=e.id||Qe();var u=this.activeLayer;if(!a.cancel&&u&&!u.lock){if(u.objects.indexOf(e.id)<0&&!u.lock&&(u.visible||(u.visible=!0,this.dataBind()),u.objects.push(e.id)),ps(e)===de)(r=new de(this,"connectors",e,!0)).status="New",this.nameTable[r.targetID]&&"TextAnnotation"===this.nameTable[r.targetID].shape.shape&&(r.isBpmnAnnotationConnector=!0,r.constraints=r.constraints&~qe.Delete),Ro(r,e,this.connectorDefaults),this.connectors.push(r),this.initObject(r),!1===e.visible&&this.updateElementVisibility(r.wrapper,r,e.visible),this.updateEdges(r),this.insertBlazorConnector(r);else{if(Ro(r=new te(this,"nodes",e,!0),e,this.nodeDefaults),r.parentId=e.parentId?e.parentId:r.parentId,r.umlIndex=e.umlIndex,r.status="New",(o="TextAnnotation"===r.shape.shape)&&!e.isTextAnnotationCopied&&(r.inEdges=e.inEdges?e.inEdges:r.inEdges),this.nodes.push(r),this.initObject(r,u,void 0,i),o&&this.bpmnModule)for(c=0;c-1&&e.parentId&&this.nameTable[e.parentId]&&"UmlClassifier"===this.nameTable[e.parentId].shape.type){var g=this.nameTable[e.parentId];g.children.splice(r.umlIndex,0,r.id),g.wrapper.children.splice(r.umlIndex,0,r.wrapper),g.wrapper.measure(new me),g.wrapper.arrange(g.wrapper.desiredSize),this.updateDiagramObject(g)}}if(a={element:r,cause:this.diagramActions,diagramAction:this.getDiagramAction(this.diagramActions),state:"Changed",type:"Addition",cancel:!1},this.parentObject&&(a.parentId=this.parentObject.id),"helper"!==e.id&&!(this.diagramActions&ee.PreventCollectionChangeOnDragOver)&&this.triggerEvent(Ce.collectionChange,a),!(this.diagramActions&ee.UndoRedo||this.diagramActions&ee.Group||this.diagramActions&ee.PreventHistory)){var v={type:"CollectionChanged",changeType:"Insert",undoObject:$(e),redoObject:$(e),category:"Internal"};this.addHistoryEntry(v)}this.parentObject=void 0,"SVG"===this.mode&&(this.updateSvgNodes(r),this.updateTextElementValue(r),this.updateDiagramObject(r),o&&this.updateDiagramObject(this.nameTable[r.inEdges[0]]),r.shape.activity&&r.shape.activity.subProcess.processes&&r.shape.activity.subProcess.processes.length&&this.updateProcesses(r),this.updateBridging())}}if(this.protectPropertyChange(s),this.resetDiagramActions(ee.PublicMethod),r&&this.layers.length>1&&this.moveNode(r),this.views)for(var S=0,b=this.views;S=0;l--)this.moveSvgNode(a[parseInt(l.toString(),10)])}for(var h=0,c=i;h=0;o--)r[parseInt(o.toString(),10)]===e.id&&r.splice(o,1);for(var a=0;s.ports&&a=0;s--)if(i=this.nameTable[r[parseInt(s.toString(),10)]])if(this.connectorTable[i.id]=$(i),i.isBpmnAnnotationConnector){var o=this.nameTable[i.targetID];this.removeObjectsFromLayer(i);var a=this.connectors.indexOf(i);-1!==a&&this.connectors.splice(a,1),this.removeElements(i),this.removeFromAQuad(i),delete this.nameTable[i.id];var l=this.nameTable[i.sourceID];if(l){var h=l.outEdges.indexOf(i.id);-1!==h&&l.outEdges.splice(h,1)}e.id!==i.targetID&&this.remove(o)}else this.remove(i)},t.prototype.removeObjectsFromLayer=function(e){if(e.children)for(var i=0;i-1&&(_r(this,e)&&this.unSelect(e),this.layers[parseInt(s.toString(),10)].objects.splice(a,1),delete this.layers[parseInt(s.toString(),10)].zIndexTable[this.nameTable[e.id].zIndex])},t.prototype.removeElements=function(e){if("SVG"===this.mode||"Canvas"===this.mode&&"Native"===e.shape.type){var i=xt(e.id+"_groupElement",this.element.id),r=e;if(r.ports&&r.ports.length>0)for(var s=0;s0){l[parseInt(s.toString(),10)].id.indexOf("icon_content")>0&&"SVG"===this.mode&&((h=xt(l[parseInt(s.toString(),10)].id+"_shape_groupElement",this.element.id))&&h.parentNode.removeChild(h),(h=xt(l[parseInt(s.toString(),10)].id+"_rect_groupElement",this.element.id))&&h.parentNode.removeChild(h));for(var c=0,d=this.views;c=0;o--)a.children[parseInt(o.toString(),10)].children&&(l=n.nameTable[a.children[parseInt(o.toString(),10)].id])&&(l.isLane?Jv(n,l):(n.removeDependentConnector(l),n.diagramActions|=ee.PreventHistory,l.constraints&ie.Delete?n.remove(l):q3(n,l,{},!1),n.diagramActions&=~ee.PreventHistory));a&&(i=n.nameTable[a.id])&&Jv(n,i)}}(this,e),!(this.diagramActions&ee.UndoRedo||this.diagramActions&ee.PreventHistory)&&(e instanceof te||e instanceof de)){var o={type:"CollectionChanged",changeType:"Remove",undoObject:$(e),redoObject:$(e),category:"Internal"};this.diagramActions&ee.Clear||e.children&&!e.isLane&&!e.isPhase&&e.children.length>0&&this.undoRedoModule&&"None"===this.layout.type&&(this.historyManager.startGroupAction(),s=!0),(e instanceof te||e instanceof de)&&this.deleteDependentConnector&&this.removeDependentConnector(e),!e.isLane&&!e.isPhase&&!(this.diagramActions&ee.Clear)&&!this.isStackChild(e)&&this.addHistoryEntry(o)}"TextAnnotation"===e.shape.shape&&this.removeDependentConnector(e),e.children&&!e.isLane&&!e.isPhase&&(!(this.diagramActions&ee.UndoRedo)||!ce())&&this.deleteGroup(e),e.parentId&&(this.deleteChild(e,void 0,!0),this.nameTable[e.parentId]&&"UmlClassifier"===this.nameTable[e.parentId].shape.type&&(this.updateDiagramObject(this.nameTable[e.parentId]),this.updateConnectorEdges(this.nameTable[e.parentId])));var a=void 0;this.diagramActions=this.diagramActions|ee.PublicMethod;var l=this.nameTable[e.id];if(l instanceof te?("Bpmn"===l.shape.type&&this.bpmnModule&&this.bpmnModule.removeBpmnProcesses(l,this),(l.isLane||l.isPhase||"SwimLane"===l.shape.type)&&(h=l.isLane||l.isPhase?this.nameTable[l.parentId]:this.nameTable[l.id],l.isLane?Q3(this,l,h):l.isPhase&&G3(this,l,h)),-1!==(a=this.nodes.indexOf(l))&&(this.crudDeleteNodes.push(this.nameTable[l.id]),this.nodes.splice(a,1),this.updateNodeEdges(l))):(-1!==(a=this.connectors.indexOf(l))&&(this.crudDeleteNodes.push(this.nameTable[l.id]),this.connectors.splice(a,1)),this.updateEdges(l),this.spliceConnectorEdges(e,!0),this.spliceConnectorEdges(e,!1)),!this.isServerUpdate&&!(this.blazorActions&on.GroupClipboardInProcess)&&this.commandHandler.getBlazorOldValues(),s&&this.historyManager.endGroupAction(),_r(this,l)&&this.unSelect(l),!l.isPhase){if(this.removeObjectsFromLayer(e),this.currentDrawingObject&&(this.currentDrawingObject.wrapper=void 0),delete this.nameTable[e.id],i.length>0&&i[0].id===l.id&&l.parentId){var h,d=this.nameTable[l.parentId];d&&d.isLane&&"SwimLane"===this.nameTable[d.parentId].shape.type&&Y3(this,h=this.nameTable[d.parentId],d,l)}this.removeElements(l),this.updateBridging(),"SVG"!==this.mode&&this.refreshDiagramLayer(),this.diagramActions&ee.Clear||(this.removeFromAQuad(l),r={element:e,cause:this.diagramActions,diagramAction:this.getDiagramAction(this.diagramActions),state:"Changed",type:"Removal",cancel:!1},"helper"!==e.id&&this.triggerEvent(Ce.collectionChange,r),this.resetTool())}}}else if(i.length>0){this.undoRedoModule&&(this.historyManager.startGroupAction(),this.blazorActions|=on.GroupingInProgress,s=!0);for(var u=0;u=p.wrapper.bounds.width&&"Horizontal"===p.shape.orientation||this.selectedItems.wrapper.bounds.y<=p.wrapper.bounds.y+g&&this.selectedItems.wrapper.bounds.height>=p.wrapper.bounds.height-g&&"Vertical"===p.shape.orientation)&&(zI(p)||p.shape.lanes.length>1)&&this.remove(i[parseInt(u.toString(),10)])}}else this.remove(i[parseInt(u.toString(),10)])}s&&(this.blazorActions&=~on.GroupingInProgress,this.isServerUpdate=!0,this.commandHandler.getBlazorOldValues(),this.UpdateBlazorDiagramModelCollection(void 0,void 0,void 0,!0),this.historyManager.endGroupAction(),this.isServerUpdate=!1),this.clearSelection()}e&&(zI(e)||this.diagramActions&ee.Clear)||this.diagramActions&ee.UndoRedo||this.diagramActions&ee.PreventHistory||!(e instanceof te||e instanceof de)||(o={type:"ConnectionChanged",undoObject:$(e),redoObject:$(e),category:"Internal"},!e.isLane&&!e.isPhase&&!(this.diagramActions&ee.Clear)&&!this.isStackChild(e)&&this.addHistoryEntry(o)),this.tooltipObject.close()},t.prototype.isStackChild=function(e){var i,r=this.nameTable[e.parentId];if(e&&e.parentId&&r.container&&"Stack"===r.container.type&&"UmlClassifier"!==this.nameTable[e.parentId].shape.type){i=!0;var s={sourceIndex:r.wrapper.children.indexOf(e.wrapper),source:e,target:void 0,targetIndex:void 0};this.diagramActions&ee.UndoRedo||this.addHistoryEntry({type:"StackChildPositionChanged",redoObject:{sourceIndex:void 0,source:e,target:void 0,targetIndex:void 0},undoObject:s,category:"Internal"})}return i},t.prototype.deleteChild=function(e,i,r){var s;if(s="string"==typeof e?e:e.id,(i=i?this.nameTable[i.id]:this.nameTable[e.parentId])&&i.children){for(var o=0;o=0;i--)this.removeLayer(this.layers[parseInt(i.toString(),10)].id);this.commandHandler.addLayer({id:"default_layer",visible:!0,lock:!1,objects:[],zIndex:0,objectZIndex:-1,zIndexTable:{}},null,!0),this.setActiveLayer(this.layers[this.layers.length-1].id)},t.prototype.clearObjects=function(e){var i=[];i=e||(i=i.concat(this.nodes)).concat(this.connectors),this.diagramActions=this.diagramActions|ee.Clear;for(var r=0,s=i;r0||"Text"===e.shape.type))if("Text"===e.shape.type)i=e.wrapper.children[0].id.split("_")[1];else for(var p=e.annotations.length-1;p>=0;p--)e.annotations[parseInt(p.toString(),10)].visibility&&(i=e.annotations[parseInt(p.toString(),10)].id);i&&(u=this.getWrapper(e.wrapper,i))}if(e&&u&&!(u instanceof es)&&(!function sne(n,t){return"Text"===t.shape.type?t.constraints&ie.ReadOnly:t.constraints&(t instanceof de?qe.ReadOnly:ie.ReadOnly)?n.constraints&Nr.InheritReadOnly?1:0:n.constraints&Nr.ReadOnly?1:0}(u,e)||f)){var g=u.style,v=void 0;v=90>(v=u.bounds.width50?50:e.width,u.style.fontSize)),e.parentId&&"UmlClassifier"===this.nameTable[e.parentId].shape.type?(l.width=e.wrapper.bounds.width-20,c=(e.wrapper.bounds.center.x+r.tx)*r.scale-l.width/2*s-2.5,d=(e.wrapper.bounds.center.y+r.ty)*r.scale-l.height/2*s-3,u.style.textAlign="Left"):(l.width=Math.max(l.width,50),c=(u.bounds.center.x+r.tx)*r.scale-l.width/2*s-2.5,d=(u.bounds.center.y+r.ty)*r.scale-l.height/2*s-3),Ho(y,{id:this.element.id+"_editTextBoxDiv",style:"position: absolute;left:"+c+"px;top:"+d+"px;width:"+(l.width+1)*s+"px;height:"+l.height*s+"px; containerName:"+e.id+";"}),Ho(S,{"aria-label":a,id:this.element.id+"_editBox",style:"width:"+(l.width+1)*s+"px;height:"+l.height*s+"px;resize: none;outline: none;overflow: hidden;;font-family:"+g.fontFamily+";font-size:"+g.fontSize*s+"px;text-align:"+u.style.textAlign.toLocaleLowerCase()+";",class:"e-diagram-text-edit"}),S.style.fontWeight=g.bold?"bold":"",S.style.fontStyle=g.italic?"italic":"",S.style.lineHeight=(1.2*g.fontSize+"px;").toString(),S.style.textDecoration=g.textDecoration?g.textDecoration:"",this.activeLabel.parentId=e.id,this.activeLabel.id=i,u.visible=!1,this.updateDiagramObject(e),this.diagramActions=this.diagramActions|ee.TextEdit,this.isTriggerEvent||(E.add(S,"input",this.eventHandler.inputChange,this.eventHandler),E.add(S,"focusout",this.focusOutEdit,this),S.select())}}}},t.prototype.updateConnectorfixedUserHandles=function(e){if(e.fixedUserHandles.length)for(var i=void 0,r=0,s=e.fixedUserHandles;r0&&this.mindMapChartModule.updateLayout(o,this.nameTable,this.layout,l,this.dataSourceSettings.id,this.dataSourceSettings.root),e=!0;else if(this.radialTreeModule)this.radialTreeModule.updateLayout(o,this.nameTable,this.layout,l),e=!0;else if(this.symmetricalLayoutModule)this.symmetricalLayoutModule.maxIteration=this.layout.maxIteration,this.symmetricalLayoutModule.springLength=this.layout.springLength,this.symmetricalLayoutModule.springFactor=this.layout.springFactor,this.symmetricalLayoutModule.updateLayout(o,this.connectors,this.symmetricalLayoutModule,this.nameTable,this.layout,l),e=!0;else if(this.complexHierarchicalTreeModule){this.canDistribute(a,r)&&(this.lineDistributionModule.diagram=this,this.connectors.forEach(function(P){P.obstaclePointCollection=[]}));var c=this.complexHierarchicalTreeModule.getLayoutNodesCollection(this.nodes);c.length>0&&this.complexHierarchicalTreeModule.doLayout(c,this.nameTable,this.layout,l,this),e=!0,this.canDistribute(a,r)&&this.lineDistributionModule.initLineDistribution(this.layout,this)}else this.flowchartLayoutModule?(this.flowchartLayoutModule.updateLayout(this.nodes,this),e=!0):console.warn("[WARNING] :: Module "+("OrganizationalChart"===this.layout.type?"HierarchicalTree":this.layout.type)+" is not available in Diagram component! You either misspelled the module name or forgot to load it.");if(e){this.preventDiagramUpdate=!0;for(var u={},p=0,g=o;p0)for(var S=0;S0)for(var M=0;M0)for(var s=0,o=r.ports;s0&&function Rse(n){var t,e,i,r=[];for(t=0;t0&&y.connectors[w].bezierSettings&&y.connectors[w].bezierSettings.allowSegmentsReset&&(y.connectors[w].segments=[]);if(t.connectors=y.connectors||[],t.dataSourceSettings=y.dataSourceSettings||{},t.dataSourceSettings.doBinding=i,t.height=y.height||"100%",t.setNodeTemplate=r,t.getConnectorDefaults=v,t.getNodeDefaults=g,t.getCustomProperty=o,t.mode=y.mode||"SVG",y.nodes)for(w=0;w0)){var r=this.nodes.filter(function(a){return 0===a.inEdges.length})[0],s=this.convertMindmapToMermaid(r,0);i.push(s),this.updateTextDataSource(i,r.outEdges,1),e=(i=i.filter(function(a){return""!==a.trim()})).join("\n")}return e},t.prototype.updateTextDataSource=function(e,i,r){for(var s=0;s0&&this.updateTextDataSource(e,h,r+1),s++}},t.prototype.convertMindmapToMermaid=function(e,i){var r=e.id,o=" ".repeat(2*(i+1)),a=e.annotations.length>0?e.annotations[0].content.replace(/\n/g," "):"",l=o+a,h=o+r;if(e.shape&&"Basic"===e.shape.type){var c=e.shape;"Rectangle"===c.shape?l=h+"["+a+"]":"Ellipse"===c.shape?l=h+"(("+a+"))":"Hexagon"===c.shape&&(l=h+"{{"+a+"}}")}else if(e.shape&&"Flow"===e.shape.type)"Terminator"===e.shape.shape&&(l=h+"("+a+")");else if(e.shape&&"Path"===e.shape.type){var u=e.shape;u.data===this.bangShape?l=h+"))"+a+"((":u.data===this.cloudShape&&(l=h+")"+a+"(")}return l},t.prototype.saveFlowDiagramInMermaidFormat=function(){var e=this,i=[],r="graph TD\n",s={nodes:this.nodes,edges:this.connectors};return s.nodes.reduce(function(a,l){return a[l.id]=l.annotations.length?l.annotations[0].content:"",a},{}),s.edges.forEach(function(a){var l=a.sourceID,h=a.targetID,f=e.nameTable[""+h],p=e.getNodeShape(e.nameTable[""+l]),g=e.getNodeShape(f),v=a.annotations[0]&&""!==a.annotations[0].content?"|"+a.annotations[0].content+"|":"";-1===i.indexOf(l)?i.push(l):p="",-1===i.indexOf(h)?i.push(h):g="";var y=e.arrowType(a);r+=" "+l+p+" "+y+v+" "+h+g+"\n"}),s.nodes.forEach(function(a){r+=" style "+a.id+" fill:"+a.style.fill+",stroke:"+a.style.strokeColor+",stroke-width:"+a.style.strokeWidth+"px;\n"}),r},t.prototype.arrowType=function(e){var i=e.targetDecorator.shape;return e.style.opacity<1?"~~~":""!==e.style.strokeDashArray?"-.->":"Arrow"===i?e.style.strokeWidth>1?"==>":"--\x3e":"None"===i?"---":"--\x3e"},t.prototype.getNodeShape=function(e){var i=e.annotations.length>0?e.annotations[0].content:"",r=e.shape.shape;if(!r){var s=e.shape.data;return"M 0 0 A 1 1 0 0 0 7 0 A 1 1 0 0 0 0 0 M -1 0 A 1 1 0 0 0 8 0 A 1 1 0 0 0 -1 0"===s?"((("+i+")))":"M 0 0 L 1 -1 L 5 -1 L 6 0 L 0 0"===s?"[/"+i+"\\]":"M 0 1 L 0 6 C 2 7 4 7 6 6 L 6 1 C 5 0 1 0 0 1 C 1 2 5 2 6 1"===s?"[("+i+")]":"M 0 0 L 12 0 L 14 2 L 2 2 L 0 0"===s?"[\\"+i+"\\]":"M 0 0 L 5 0 L 4 1 L 1 1 L 0 0"===s?"[\\"+i+"/]":"M 0 0 L 2 -2 L 11 -2 L 13 0 L 11 2 L 2 2 L 0 0"===s?"{{"+i+"}}":">"+i+"]"}switch(r){case"Terminator":return"(["+i+"])";case"Process":default:return"["+i+"]";case"Decision":return"{"+i+"}";case"Parallelogram":return"[/"+i+"/]";case"Ellipse":return"(("+i+"))";case"PreDefinedProcess":return"[["+i+"]]"}},t.prototype.loadDiagramFromMermaid=function(e){this.layout&&"Flowchart"===this.layout.type&&this.flowchartLayoutModule?this.convertMermaidToFlowChart(e):this.layout&&"MindMap"===this.layout.type&&this.mindMapChartModule?this.convertMermaidToMindmap(e):console.warn('[WARNING] :: Module "FlowchartLayout" or "MindMap" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.countLeadingSpaces=function(e){for(var i=0,r=e.length;i0});this.clear(),this.mermaidNodeBaseCollection=[];var r=[],s={text:"",children:[],currentLevel:0,branch:"Left"},o=[],l=!1,h=!1,c=!1;if(i.length>0){for(var d=function(M){var w=i[parseInt(M.toString(),10)],C=0,D="",A=u.countLeadingSpaces(w),x=w.includes('"`');if(h=w.includes('`"'),c=(l=!!x||l)||c?c:0===A&&M>0,l&&h&&!x)return s.text+="\n"+w,l=!1,"continue";if(!x&&l)return s.text+="\n"+w,"continue";if(l=!h&&l,w.length>0&&(/\s/.test(w[0])&&M>0||0===A)){if(-1!==o.findIndex(function(B){return B.space===A.toString()}))for(var L=o.length-1;L>=0;L--){var O=o[parseInt(L.toString(),10)];if((N=parseFloat(O.space))>A)o.splice(L,1);else{if(N=0;L--){var N,T=o[parseInt(L.toString(),10)];if(!((N=parseFloat(T.space))>A)){var z=o[o.length-1];o.push({space:A.toString(),level:z.level+1});break}o.splice(L,1)}C=o[o.length-1].level}D=w.trim().replace(/^[+-]/,"")}var U={text:D,branch:void 0,children:[],currentLevel:0===M?0:C-1};if(r.length>0){for(;r.length>=C&&0!==r.length;)r.pop();r.length>0&&r[r.length-1].children.push(U)}r.push(U),s=U},u=this,f=0;f0){var c=h[h.length-1];c.arrowType=a[2],""!==a[3]&&(c.label&&c.label.some(function(d){return d.trim().length>0})?c.label.push(a[3]):(c.label=[],c.label[c.parentId.length-1]=a[3]))}h.filter(function(d){return d.parentId&&0===d.parentId.length}).forEach(function(d){d.parentId=null}),i=i.concat(h)}}this.createFlowChart(i),this.doLayout(),this.clearHistory()},t.prototype.createFlowChart=function(e){for(var i=[],r=0;r1)for(var h=0;h|---|--\s*.*?\s*-->|~~~|==>|===|==\s*.*?\s*==>|\s*-\.\s*->|\s*-\.\s*-|\s*-\.\s*.*?\s*\.\s*->|\s*-\..*?\.\s*->)(.*)$/);if(l){i=l[1].trim();var h=l[2].trim();r=l[3].trim();var d=h.match(/(-\.|\\-\\-|==|--|~~)(.*?)(\1>|\.->|==>|\\->|~~>)/),u=void 0,f="";o=null!==(u=d?{text:d[2].trim()||null,arrowType:d[1]+d[3]}:{text:null,arrowType:h}).text?u.text:"",s=(f=u.arrowType).includes("--\x3e")?"single-line-arrow":f.includes("---")?"single-line":f.includes("==>")?"double-line-arrow":f.includes("==")?"double-line":f.includes("~~~")?"wiggly-arrow":f.includes("-.->")||f.includes(".->")?"dotted-arrow":f.includes("-.-")||f.includes(".-")?"dotted":"single-line-arrow"}return[i,r,s,o]},t.prototype.parseStyle=function(e,i){if(e.startsWith("style")){var s=e.match(/^style\s+(\w+)\s+fill:([^,]+),stroke:([^,]+),stroke-width:(\d+)px;/);if(s){var c={id:s[1],fill:s[2],stroke:s[3],strokeWidth:parseInt(s[4],10)},d=i.filter(function(u){return u.id===c.id});d[0].color=c.fill,d[0].stroke=c.stroke,d[0].strokeWidth=c.strokeWidth}}},t.prototype.getNodeData=function(e,i,r){for(var s=[],o=null,a=null,l=0,h="",c=function(v){var y=e[parseInt(v.toString(),10)],S=d.splitNested(y);if(S[0].includes("|")){var b=S[0].match(/\|([^|]*)\|/);b&&(h=b[1]);var M=S[0].split("|");M.length>=3&&(S[0]=M[2].trim())}var w=S[0].trim();if(0===v?o=w:a=w,i.find(function(L){return L.id===w}))l++;else{var D=S.length>1?S[1]:S[0],A=d.getShape(D),x=D.replace(/[\\[\]\\(\\)\\{\\}\\{\\}\\/>]/g,"");s.push({id:w,name:x,shape:A,color:"white",parentId:[]})}},d=this,u=0;u"===h?0===s?(r.trim().length>0&&i.push(r.trim()),r=h,o=h,s++):(r+=h,s++):"]"===h||"}"===h||")"===h?1===s&&h===o?(i.push((r+=h).trim()),r="",s--):s>1?(r+=h,s--):r+=h:r+=h}return r.trim().length>0&&i.push(r.trim()),i},t.prototype.getShape=function(e){var i={};return e.startsWith("(((")?i={type:"Path",data:"M 0 0 A 1 1 0 0 0 7 0 A 1 1 0 0 0 0 0 M -1 0 A 1 1 0 0 0 8 0 A 1 1 0 0 0 -1 0"}:e.startsWith("((")?i={shape:"Ellipse",type:"Basic"}:e.startsWith("([")?i={type:"Flow",shape:"Terminator"}:e.startsWith("(")?i={type:"Flow",shape:"Process"}:e.startsWith("[[")?i={type:"Flow",shape:"PreDefinedProcess"}:e.startsWith("[/")?i=e.endsWith("/]")?{type:"Basic",shape:"Parallelogram"}:{type:"Path",data:"M 0 0 L 1 -1 L 5 -1 L 6 0 L 0 0"}:e.startsWith("[(")?i={type:"Path",data:"M 0 1 L 0 6 C 2 7 4 7 6 6 L 6 1 C 5 0 1 0 0 1 C 1 2 5 2 6 1"}:e.startsWith("[\\")?i=e.endsWith("\\]")?{type:"Path",data:"M 0 0 L 12 0 L 14 2 L 2 2 L 0 0"}:{type:"Path",data:"M 0 0 L 5 0 L 4 1 L 1 1 L 0 0"}:e.startsWith("[")?i={type:"Basic",shape:"Rectangle"}:e.startsWith("{{")?i={type:"Path",data:"M 0 0 L 2 -2 L 11 -2 L 13 0 L 11 2 L 2 2 L 0 0"}:e.startsWith("{")?i={type:"Flow",shape:"Decision"}:e.startsWith(">")&&(i={type:"Path",data:"M 0 0 L 8 0 L 8 2 L 0 2 L 2 1 L 0 0"}),i},t.prototype.getDiagramContent=function(e){return this.printandExportModule?this.printandExportModule.getDiagramContent(e):(console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),"")},t.prototype.exportImage=function(e,i){this.printandExportModule?this.printandExportModule.exportImages(e,i):console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.printImage=function(e,i){this.printandExportModule?(i.printOptions=!0,this.printandExportModule.exportImages(e,i)):console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.setStackLimit=function(e){this.undoRedoModule&&e&&(this.historyManager.stackLimit=e,this.undoRedoModule.applyLimit(this.historyManager.currentEntry,e,this,!0))},t.prototype.clearHistory=function(){this.undoRedoModule&&this.undoRedoModule.clearHistory(this)},t.prototype.getDiagramBounds=function(){if(this.printandExportModule){var e=this.printandExportModule.getDiagramBounds("",{});return e.width=e.width>this.scrollSettings.viewPortWidth?e.width+(e.x>0?e.x:0):this.scrollSettings.viewPortWidth,e.height=e.height>this.scrollSettings.viewPortHeight?e.height+(e.y>0?e.y:0):this.scrollSettings.viewPortHeight,e.x=e.x>0?0:e.x,e.y=e.y>0?0:e.y,e}return console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),new Ne},t.prototype.exportDiagram=function(e){return this.printandExportModule?this.printandExportModule.exportDiagram(e):(console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),"")},t.prototype.print=function(e){this.printandExportModule?this.printandExportModule.print(e):console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.addPorts=function(e,i){var s;this.protectPropertyChange(!0),e=this.nameTable[e.id]||e,i.length>1&&this.startGroupAction();for(var o=function(h){if(e.ports.some(function(y){return y.id===i[parseInt(h.toString(),10)].id}))return"continue";if(e instanceof te?(s=new Es(e,"ports",i[parseInt(h.toString(),10)],!0),e.ports.push(s)):e instanceof de&&(s=new Lc(e,"ports",i[parseInt(h.toString(),10)],!0),e.ports.push(s)),e.children)for(var c=e.wrapper,d=0;d1&&this.endGroupAction(),e.wrapper.measure(new me(e.width,e.height)),e.wrapper.arrange(e.wrapper.desiredSize),this.updateDiagramObject(e),this.protectPropertyChange(!1)},t.prototype.addConstraints=function(e,i){return e|i},t.prototype.removeConstraints=function(e,i){return e&~i},t.prototype.addNodeLabels=function(e,i){this.addLabels(e,i)},t.prototype.addConnectorLabels=function(e,i){this.addLabels(e,i)},t.prototype.addLabels=function(e,i){this.protectPropertyChange(!0);var s,r=(e=this.nameTable[e.id]||e).wrapper;i.length>1&&this.startGroupAction();for(var o=0;o1&&this.endGroupAction(),e.wrapper.measure(new me(r.width,r.height)),e.wrapper.arrange(r.desiredSize),this.updateDiagramObject(e),this.protectPropertyChange(!1),this.refreshCanvasLayers()},t.prototype.addChildToUmlNode=function(e,i,r){var s,o,a,l,h="NoWrap";"Class"===e.shape.classifier||"Interface"===e.shape.classifier?"Method"===r?(o=new fm(e,"",i),"Class"===e.shape.classifier?(e.shape.classShape.methods.push(o),s=e.shape.classShape):"Interface"===e.shape.classifier&&(e.shape.interfaceShape.methods.push(o),s=e.shape.interfaceShape),function soe(n,t,e,i){if(e.methods&&e.methods.length){var r=e.methods,s="",o="",a=void 0,l=1,h=void 0,c=0,d=0,u=n.shape,g="Class"===u.classifier?u.classShape:u.interfaceShape;1===r.length?g.attributes.length>0?(c=g.attributes.filter(function(w){return w.isSeparator}).length,h=(l=2+g.attributes.length+c)+1,lT(n,t,l)):h=l+1:(c=g.attributes.filter(function(w){return w.isSeparator}).length,d=g.methods.filter(function(w){return w.isSeparator}).length,h=(l=2+g.attributes.length+c+g.methods.length+d)+1);for(var v=0;v1&&this.startGroupAction();for(var r=i.length-1;r>=0;r--)if(e.children&&e.children.length>0){var s=e.wrapper.children.filter(function(o){return o.id===e.id+"group_container"});s&&s.length>0&&this.removelabelExtension(e,i,r,s[0])}else this.removelabelExtension(e,i,r,e.wrapper);i.length>1&&this.endGroupAction(),this.refreshCanvasLayers()},t.prototype.removePortsExtenion=function(e,i,r,s){for(var o=0;o1&&this.startGroupAction();for(var r=i.length-1;r>=0;r--)if(e.children&&e.children.length>0)for(var s=0;s1&&this.endGroupAction()},t.prototype.getSizeValue=function(e,i){var r;return r=e.toString().indexOf("px")>0?e.toString():e.toString().indexOf("%")>0?void 0!==i?"100%":e.toString():e.toString()+"px",i&&(Za(this),r="calc("+r+" - "+i+"px)"),r},t.prototype.renderRulers=function(){this.rulerSettings.showRulers?(function ise(n){var t=Za(n),i=Tt("div",{id:n.element.id+"_overlapRuler",style:"height:"+t.height+"px;width:"+t.width+"px;position:absolute;left:0;top:0",class:"e-ruler-overlap"});n.element.insertBefore(i,n.element.firstChild)}(this),oF(this,!0),oF(this,!1)):$x(this)},t.prototype.intOffPageBackground=function(){var e=new me;e=Za(this);var i=document.getElementById(this.element.id+"content"),r=this.getSizeValue(this.width,e.width),s=this.getSizeValue(this.height,e.height),o=this.rulerSettings.showRulers?"width:"+r+"; height:"+s+";top:"+e.height+"px;left:"+e.width+"px;overflow: scroll;position:absolute;overflow:auto;":"width:"+r+"; height:"+s+";position:absolute; left:0px; top:0px;overflow: auto;",a={id:this.element.id+"content",tabindex:"0",style:o};i?(this.diagramCanvas=i,Ka(this.diagramCanvas,o)):(this.diagramCanvas=Tt("div",a),this.element.appendChild(this.diagramCanvas)),this.diagramCanvas.style.background=this.backgroundColor},t.prototype.initDiagram=function(){this.intOffPageBackground(),Ho(this.element,{style:"width:"+this.getSizeValue(this.width)+"; height:"+this.getSizeValue(this.height)+";position:relative;overflow:hidden;"})},t.prototype.renderHiddenUserHandleTemplateLayer=function(e){var r=Tt("div",{class:this.element.id+"_hiddenUserHandleTemplate",style:"width:"+e.width+"px; height:"+e.height+"px;visibility:hidden ; overflow: hidden;"});this.element.appendChild(r)},t.prototype.renderBackgroundLayer=function(e,i){var r=this.createSvg(this.element.id+"_backgroundLayer_svg",e.width,e.height);Ka(r,i);var s=Fi("g",{id:this.element.id+"_backgroundImageLayer",class:"e-background-image-layer"});r.appendChild(s);var a=Fi("g",{id:this.element.id+"_backgroundLayer",class:"e-background-layer"});r.appendChild(a),this.diagramCanvas.appendChild(r)},t.prototype.renderGridLayer=function(e,i){var r=this.createSvg(this.element.id+"_gridline_svg",e.width,e.height);r.setAttribute("class","e-grid-layer");var s=Fi("g",{id:this.element.id+"_gridline"}),o=Fi("rect",{id:this.element.id+"_grid_rect",x:"0",y:"0",width:"100%",height:"100%"});if(lm()){var a=new URL(window.location.href);o.setAttribute("fill",""!==a.search?"url(#"+this.element.id+"_pattern)":"url("+location.protocol+"//"+location.host+location.pathname+"#"+this.element.id+"_pattern)")}else o.setAttribute("fill","url(#"+this.element.id+"_pattern)");s.appendChild(o),r.appendChild(s),this.diagramCanvas.appendChild(r),ti(r,{style:i})},t.prototype.renderDiagramLayer=function(e,i){if(this.diagramLayerDiv=Tt("div",{id:this.element.id+"_diagramLayer_div",style:"width:"+e.width+"px; height:"+e.height+"px;"+i}),"SVG"===this.mode){var s=this.createSvg(this.element.id+"_diagramLayer_svg",e.width,e.height);s.style["pointer-events"]="none",s.setAttribute("class","e-diagram-layer");var o=Fi("g",{id:this.element.id+"_diagramLayer"}),a=Fi("g",{});this.diagramLayer=o,s.style["pointer-events"]="all",a.appendChild(o),s.appendChild(a),this.diagramLayerDiv.appendChild(s)}else this.diagramLayer=bo.createCanvas(this.element.id+"_diagram",e.width,e.height),Ka(this.diagramLayer,"position:absolute;left:0px;top:0px;"),this.diagramLayerDiv.appendChild(this.diagramLayer);this.diagramCanvas.appendChild(this.diagramLayerDiv)},t.prototype.initLayers=function(){var e="position:absolute;top:0px;left:0px;overflow:hidden;pointer-events:none;",r=document.getElementById(this.element.id).getBoundingClientRect(),s=function Loe(){var n=Tt("div",{style:"visibility:hidden; width: 100px"});document.body.appendChild(n);var t=n.getBoundingClientRect().width;n.style.overflow="scroll";var e=Tt("div",{style:"width:100%"});n.appendChild(e);var i=e.getBoundingClientRect().width;return n.parentNode.removeChild(n),t-i}();this.scroller.scrollerWidth=s,this.scroller.setViewPortSize(r.width,r.height),this.renderRulers();var o="measureElement";window[""+o]&&(window[""+o]=null,document.getElementById("measureElement").remove()),function WF(){var n="measureElement";if(window[""+n])window[""+n].usageCount+=1;else{var t=Tt("div",{id:"measureElement",style:"visibility:hidden ; height: 0px ; width: 0px; overflow: hidden;"}),e=Tt("span",{style:"display:inline-block ; line-height: normal"});t.appendChild(e);var i=Tt("img",{alt:"measureElementImage",src:"data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7"});t.appendChild(i);var r=document.createElementNS("http://www.w3.org/2000/svg","svg");r.setAttribute("xmlns:xlink","http://www.w3.org/1999/xlink"),t.appendChild(r);var s=document.createElementNS("http://www.w3.org/2000/svg","path");s.setAttribute("d",""),r.appendChild(s),document.createTextNode("");var a=document.createElementNS("http://www.w3.org/2000/svg","text");a.setAttributeNS("http://www.w3.org/XML/1998/namespace","xml:space","preserve"),r.appendChild(a),window[""+n]=t,window[""+n].usageCount=1,document.body.appendChild(t);var l="measureElementCount";window[""+l]?window[""+l]++:window[""+l]=1}}(),this.renderBackgroundLayer(r,e),this.renderGridLayer(r,e),this.renderDiagramLayer(r,e),this.renderHTMLLayer(r,e),this.renderPortsExpandLayer(r,e),this.renderNativeLayer(r,e),this.renderAdornerLayer(r,e),this.renderHiddenUserHandleTemplateLayer(r)},t.prototype.renderAdornerLayer=function(e,i){var r=Tt("div",{id:this.element.id+"_diagramAdornerLayer",style:"width:"+e.width+"px;height:"+e.height+"px;"+i}),s=Tt("div",{id:this.element.id+"_diagramUserHandleLayer",style:"width:"+e.width+"px;height:"+e.height+"px;"+i});s.setAttribute("class","e-userHandle-layer"),r.appendChild(s);var o=this.createSvg(this.element.id+"_diagramAdorner_svg",e.width,e.height);o.setAttribute("class","e-adorner-layer"),o.style["pointer-events"]="none",this.adornerLayer=Fi("g",{id:this.element.id+"_diagramAdorner"}),this.adornerLayer.style[" pointer-events"]="all",o.appendChild(this.adornerLayer),r.appendChild(o),this.diagramCanvas.appendChild(r);var a=Fi("g",{id:this.element.id+"_SelectorElement"});this.adornerLayer.appendChild(a),ti(o,{style:"pointer-events:none;"})},t.prototype.renderPortsExpandLayer=function(e,i){var r=this.createSvg(this.element.id+"_diagramPorts_svg",e.width,e.height);r.setAttribute("class","e-ports-expand-layer");var s=Fi("g",{id:this.element.id+"_diagramPorts",class:"e-ports-layer",style:"pointer-events: all;"});r.appendChild(s);var o=Fi("g",{id:this.element.id+"_diagramExpander",class:"e-expand-layer",style:"pointer-events: all;"});r.appendChild(o),this.diagramCanvas.appendChild(r),ti(r,{style:i})},t.prototype.renderHTMLLayer=function(e,i){this.htmlLayer=Tt("div",{id:this.element.id+"_htmlLayer",style:"width:"+e.width+"px; height:"+e.height+"px;position:absolute;top:0px;left:0px;overflow:hidden;pointer-events:none;",class:"e-html-layer"});var r=Tt("div",{id:this.element.id+"_htmlLayer_div",style:"position:absolute;top:0px;left:0px;pointer-events:all;"});this.htmlLayer.appendChild(r),this.diagramCanvas.appendChild(this.htmlLayer)},t.prototype.renderNativeLayer=function(e,i){var r=this.createSvg(this.element.id+"_nativeLayer_svg",e.width,e.height),s=Fi("g",{id:this.element.id+"_nativeLayer",style:"pointer-events:all;"});r.appendChild(s),this.diagramLayerDiv.appendChild(r),ti(r,{class:"e-native-layer",style:i})},t.prototype.createSvg=function(e,i,r){var s=document.createElementNS("http://www.w3.org/2000/svg","svg");return ti(s,{id:e,width:i,height:r}),s},t.prototype.updateBazorShape=function(){for(var e=0;e1,i=[],r={},s={},o=[],a=0,l=this.nodes;a0||b&&b.children&&b.children.length>0)&&(M=!1),S&&S.wrapper&&b&&b.wrapper&&M?this.initConnectors(r[""+h],p):i.push(r[""+h])}else b=r[y.targetID],(S=r[y.sourceID])&&S.children&&S.children.length>0||b&&b.children&&b.children.length>0?i.push(r[""+h]):this.initConnectors(r[""+h],p);else r[""+h].children?o.push(h):r[""+h].shape instanceof fT&&r[""+h].shape.activity.subProcess.processes&&r[""+h].shape.activity.subProcess.processes.length>0?s[r[""+h].id]=h:this.initNodes(r[""+h],p);if(this.bpmnModule)for(var w=0,C=this.bpmnModule.bpmnTextAnnotationConnector;w-1&&-1===r.indexOf(c)&&-1===s.indexOf(c)&&r.splice(0,0,c);-1===r.indexOf(o)&&s.push(o)}return r.concat(s)},t.prototype.addToLayer=function(e,i){var r;if(i&&(r=this.commandHandler.getObjectLayer(e.id)),(!i||!r)&&-1===this.activeLayer.objects.indexOf(e.id)&&this.activeLayer.objects.push(e.id),(e instanceof te||e instanceof de)&&("SwimLane"!==e.shape.type||e.children&&e.children.length>0)){if(e.parentId){var s=this.swimlaneZIndexTable[e.parentId],o=this.swimlaneChildTable[e.id];(s&&-1!==s||o&&-1!==o)&&(e.zIndex=this.swimlaneChildTable[e.id])}e instanceof de&&e.sourceID&&e.targetID?-1!==this.activeLayer.objects.indexOf(e.sourceID)&&-1!==this.activeLayer.objects.indexOf(e.targetID)&&this.setZIndex(r||this.activeLayer,e):this.setZIndex(r||this.activeLayer,e)}},t.prototype.updateLayer=function(e){for(var i=0,r=Object.keys(e.layers);i0)for(r=0;rs;l--)r.zIndexTable[parseInt(l.toString(),10)]=r.zIndexTable[l-1],this.nameTable[r.zIndexTable[parseInt(l.toString(),10)]]&&(this.nameTable[r.zIndexTable[parseInt(l.toString(),10)]].zIndex=l);r.zIndexTable[parseInt(a.toString(),10)]=i.id}}},t.prototype.initializeDiagramLayers=function(){for(var e=0;ethis.layers[parseInt(a.toString(),10)].zIndex&&(i=this.layers[parseInt(e.toString(),10)],this.layers[parseInt(e.toString(),10)]=this.layers[parseInt(a.toString(),10)],this.layers[parseInt(a.toString(),10)]=i);0===this.layers.length&&this.commandHandler.addLayer({id:"default_layer",visible:!0,lock:!1,objects:[],zIndex:0,objectZIndex:-1,zIndexTable:{}},null,!0),this.setActiveLayer(this.layers[this.layers.length-1].id)},t.prototype.resetTool=function(){this.eventHandler.resetTool()},t.prototype.initObjectExtend=function(e,i,r){if(r){var s=this.commandHandler.checkBoundaryConstraints(void 0,void 0,e.wrapper.bounds,!0);if("SwimLane"===e.shape.type)for(var o=0,a=Object.keys(i.zIndexTable);o0)&&this.setZIndex(i,e)),e instanceof te){if(r){if("helper"!==e.id&&(o=Zi(this.getNodeDefaults))){if((a=o(e,this))&&a.ports)for(var l=0;l0)for(l=0;l0&&!e.container||e.processId){var r=this.nameTable[e.id];if(!(this.realActions&$i.PreventScale||this.realActions&$i.PreventDrag)){if(r.offsetX&&(this.realActions&$i.EnableGroupAction||!(this.diagramActions&ee.UndoRedo||this.diagramActions&ee.ToolAction||this.diagramActions&ee.PublicMethod))){this.realActions|=$i.PreventScale;var s=r.offsetX-e.wrapper.offsetX;r.offsetX=e.wrapper.offsetX;var o=r.offsetY-e.wrapper.offsetY;r.offsetY=e.wrapper.offsetY,s+o!==0&&this.drag(r,s,o),this.realActions&=~$i.PreventScale}else r.offsetX=e.wrapper.offsetX;r.offsetY&&(this.realActions&$i.EnableGroupAction||!(this.diagramActions&ee.UndoRedo||this.diagramActions&ee.ToolAction||this.diagramActions&ee.PublicMethod))?(this.realActions|=$i.PreventScale,o=r.offsetY-e.wrapper.offsetY,r.offsetY=e.wrapper.offsetY,this.drag(r,0,o),this.realActions&=~$i.PreventScale):r.offsetY=e.wrapper.offsetY,this.diagramActions&&(r.width=e.wrapper.actualSize.width,r.height=e.wrapper.actualSize.height)}}i&&e.children&&e.children.length>0&&(void 0!==this.nameTable[e.id].width?this.scaleObject(e,this.nameTable[e.id].width,!0):this.nameTable[e.id].width=e.wrapper.actualSize.width,void 0!==this.nameTable[e.id].height?this.scaleObject(e,this.nameTable[e.id].height,!1):this.nameTable[e.id].height=e.wrapper.actualSize.height)},t.prototype.initNode=function(e,i,r){var a,f,s=e.initContainer(),o=new Mi;if(this.diagramSettings.inversedAlignment||(s.inversedAlignment=!1),s.children||(s.children=[]),e.children){s.measureChildren=!1,o.id=e.id+"group_container",o.style.fill=e.shape&&"SwimLane"===e.shape.type?e.style.fill:"none",o.style.strokeColor="none",o.horizontalAlignment="Stretch",o.verticalAlignment="Stretch",o.pivot=e.pivot,s.style=e.style,s.padding.left=e.padding.left,s.padding.right=e.padding.right,s.padding.top=e.padding.top,s.padding.bottom=e.padding.bottom,o.children=[],o.preventContainer=!0,e.container&&(o.relativeMode="Object");var l=!!(e.ports&&e.ports.length>0);if(m(e.container)&&!l&&s.children.push(o),e.container&&"Grid"===e.container.type)for(var h=0;h0&&e.wrapper.children[0]instanceof Gv){if(this.setZIndex(this.activeLayer,e),this.connectors.length>0)for(h=0;h0?i.phases.length:0,v="Horizontal"===i.orientation,y=v?i.phases.length||1:s.length+1,S=v?(i.header&&i.hasHeader?1:0)+(i.phases.length>0?1:0)+i.lanes.length:(i.header&&i.hasHeader?1:0)+i.phases.length;if(0===h&&!v&&i.lanes.length&&(S+=1),v?(a=(i.header&&i.hasHeader?1:0)+(h>0?1:0),l=0):(a=i.header&&i.hasHeader?1:0,l=h>0?1:0),s.length>0)for(o+=i.header&&i.hasHeader?i.header.height:0,f=0;fl?d.margin.left=d.margin.left-(u.bounds.left-e.bounds.left):u.children[0].children[1].actualSize.width+r>=d.margin.left&&(d.margin.left=u.children[0].children[1].actualSize.width+r),d.margin.lefta?d.margin.top=d.margin.top-(u.bounds.top-o):u.children[0].children[1].actualSize.height+r>=d.margin.top&&(d.margin.top=u.children[0].children[1].actualSize.height+r),d.margin.left0)for(o=0;o0&&this.updateChildPosition(e)},t.prototype.addBpmnAnnotationConnector=function(e,i){if(e.parentObj instanceof t||e.parentObj instanceof _d){var r=e.shape,o=""!==r.textAnnotation.textAnnotationTarget&&this.nameTable[r.textAnnotation.textAnnotationTarget],a=o?this.nameTable[r.textAnnotation.textAnnotationTarget]:null,l=null!=a?a.wrapper:null,h=e.ports[0],c={x:0,y:0};switch(r.textAnnotation.textAnnotationDirection){case"Left":h.offset={x:0,y:.5},c.x=i.bounds.left-40,c.y=i.bounds.bottom+30;break;case"Right":h.offset={x:1,y:.5},c.x=i.bounds.right+40,c.y=i.bounds.bottom+30;break;case"Top":h.offset={x:.5,y:0},c.x=i.bounds.right+30,c.y=i.bounds.top-40;break;case"Bottom":h.offset={x:.5,y:1},c.x=i.bounds.right+30,c.y=i.bounds.bottom+40;break;default:h.offset={x:0,y:.5},c.x=i.bounds.left-40,c.y=i.bounds.bottom+30,o&&null!=i&&null!=l&&(i.bounds.left>l.bounds.right?h.offset={x:0,y:.5}:i.bounds.rightl.bounds.top?h.offset={x:.5,y:0}:i.bounds.top0&&this.updateChildPosition(r)}},t.prototype.canExecute=function(){return!0},t.prototype.updateStackProperty=function(e,i,r){e.container&&"Stack"===e.container.type&&(i.width||(i.wrapper.horizontalAlignment="Stretch",i.horizontalAlignment="Stretch"),i.height||(i.verticalAlignment="Stretch",i.wrapper.verticalAlignment="Stretch"),r&&"UmlClassifier"===e.shape.type&&(i.umlIndex=r))},t.prototype.initViews=function(){this.isLoading||(this.views.push(this.element.id),this.views[this.element.id]=this)},t.prototype.initCommands=function(){var e=this.commandManager.commands,i={copy:{execute:this.copyCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.C,keyModifiers:ft.Control}},paste:{execute:this.pasteCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.V,keyModifiers:ft.Control}},cut:{execute:this.cutCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.X,keyModifiers:ft.Control}},delete:{execute:this.removeCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Delete}},selectAll:{execute:this.selectAll.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.A,keyModifiers:ft.Control}},undo:{execute:this.undo.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Z,keyModifiers:ft.Control}},redo:{execute:this.redo.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Y,keyModifiers:ft.Control}},nudgeUp:{execute:this.nudgeCommand.bind(this,"Up"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Up},parameter:"up"},nudgeRight:{execute:this.nudgeCommand.bind(this,"Right"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Right},parameter:"right"},nudgeDown:{execute:this.nudgeCommand.bind(this,"Down"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Down},parameter:"down"},nudgeLeft:{execute:this.nudgeCommand.bind(this,"Left"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Left},parameter:"left"},startEdit:{execute:this.startEditCommad.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.F2}},endEdit:{execute:this.endEditCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Escape}},focusToNextItem:{execute:this.navigateItems.bind(this,!0),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Tab}},focusToPreviousItem:{execute:this.navigateItems.bind(this,!1),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Tab,keyModifiers:ft.Shift}},selectFocusedItem:{execute:this.startEditCommad.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Enter}},bold:{execute:this.fontStyleCommand.bind(this,"bold"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.B,keyModifiers:ft.Control}},italic:{execute:this.fontStyleCommand.bind(this,"italic"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.I,keyModifiers:ft.Control}},underline:{execute:this.fontStyleCommand.bind(this,"underline"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.U,keyModifiers:ft.Control}},duplicate:{execute:this.duplicateCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.D,keyModifiers:ft.Control}},group:{execute:this.groupCommand.bind(this,"group"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.G,keyModifiers:ft.Control}},ungroup:{execute:this.groupCommand.bind(this,"ungroup"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.U,keyModifiers:ft.Control|ft.Shift}},rotateClockwise:{execute:this.rotateCommand.bind(this,"clockwise"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.R,keyModifiers:ft.Control}},rotateAntiClockwise:{execute:this.rotateCommand.bind(this,"antiClockwise"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.L,keyModifiers:ft.Control}},flipHorizontal:{execute:this.flipCommand.bind(this,"horizontal"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.H,keyModifiers:ft.Control}},flipVertical:{execute:this.flipCommand.bind(this,"vertical"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.J,keyModifiers:ft.Control}},pointerTool:{execute:this.toolCommand.bind(this,"pointer"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number1,keyModifiers:ft.Control}},textTool:{execute:this.toolCommand.bind(this,"text"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number2,keyModifiers:ft.Control}},connectTool:{execute:this.toolCommand.bind(this,"connect"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number3,keyModifiers:ft.Control}},freeForm:{execute:this.toolCommand.bind(this,"freeForm"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number5,keyModifiers:ft.Control}},lineTool:{execute:this.toolCommand.bind(this,"line"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number6,keyModifiers:ft.Control}},rectangleTool:{execute:this.toolCommand.bind(this,"rectangle"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number8,keyModifiers:ft.Control}},ellipseTool:{execute:this.toolCommand.bind(this,"ellipse"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number9,keyModifiers:ft.Control}},zoomIn:{execute:this.zoomCommand.bind(this,"zoomIn"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Plus,keyModifiers:ft.Control}},zoomOut:{execute:this.zoomCommand.bind(this,"zoomOut"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Minus,keyModifiers:ft.Control}},shiftUp:{execute:this.shiftCommand.bind(this,"Up"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Up,keyModifiers:ft.Shift}},shiftDown:{execute:this.shiftCommand.bind(this,"Down"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Down,keyModifiers:ft.Shift}},shiftLeft:{execute:this.shiftCommand.bind(this,"Left"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Left,keyModifiers:ft.Shift}},shiftRight:{execute:this.shiftCommand.bind(this,"Right"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Right,keyModifiers:ft.Shift}},alignTextCenter:{execute:this.alignCommand.bind(this,"center"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.C,keyModifiers:ft.Control|ft.Shift}},alignTextLeft:{execute:this.alignCommand.bind(this,"right"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.L,keyModifiers:ft.Control|ft.Shift}},alignTextRight:{execute:this.alignCommand.bind(this,"left"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.R,keyModifiers:ft.Control|ft.Shift}},alignTextTop:{execute:this.alignCommand.bind(this,"top"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.E,keyModifiers:ft.Control|ft.Shift}},alignTextCenterVertical:{execute:this.alignCommand.bind(this,"centerVertical"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.M,keyModifiers:ft.Control|ft.Shift}},alignTextBottom:{execute:this.alignCommand.bind(this,"bottom"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.V,keyModifiers:ft.Control|ft.Shift}},alignJustify:{execute:this.alignCommand.bind(this,"justify"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.J,keyModifiers:ft.Control|ft.Shift}},sendToBack:{execute:this.orderCommand.bind(this,"sendToBack"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.B,keyModifiers:ft.Control|ft.Shift}},bringToFront:{execute:this.orderCommand.bind(this,"bringToFront"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.F,keyModifiers:ft.Control|ft.Shift}},sendBackward:{execute:this.orderCommand.bind(this,"sendBackward"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.BracketLeft,keyModifiers:ft.Control}},bringForward:{execute:this.orderCommand.bind(this,"bringForward"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.BracketRight,keyModifiers:ft.Control}}};this.initCommandManager(e,i)},t.prototype.overrideCommands=function(e,i){for(var r,s=0,o=Object.keys(i);se.zIndex){("HTML"===e.shape.type||"Native"===e.shape.type)&&(o="HTML"===e.shape.type?"html":"native"),s=Eoe(i,r[parseInt(a.toString(),10)].id,o);break}return s},t.prototype.updateDiagramObject=function(e,i,r){for(var s,o="domTable",a=0,l=this.views;a1&&(d=this.commandHandler.getObjectLayer(e.id)),void 0===d||d&&d.visible||r){var u=Io(this.element.id);window[""+o][s.element.id+"_diagramLayer"]||(window[""+o][s.element.id+"_diagramLayer"]=document.getElementById(s.element.id+"_diagramLayer"));var f=window[""+o][s.element.id+"_diagramLayer"];this.diagramActions&ee.Interactions&&this.updateCanupdateStyle(e.wrapper.children,!0);var p=this.getMidPoint(e);this.diagramRenderer.updateNode(e.wrapper,f,u,void 0,i?void 0:this.getZindexPosition(e,s.element.id),p,this.portCenterPoint),this.updateCanupdateStyle(e.wrapper.children,!0)}}},t.prototype.applyMarginBezier=function(e,i){i.cx=i.cx+e.margin.left,i.cx=i.cx-e.margin.right,i.cy=i.cy+e.margin.top,i.cy=i.cy-e.margin.bottom},t.prototype.getMidPoint=function(e){var i;if(e instanceof de&&"Bezier"===e.type){i=[];for(var r=this.getBezierPoints(e),s=R.getLengthFromListOfPoints(r),o=0;o0&&e.updateView(e));var s=Io(e.element.id);this.renderDiagramElements(e.diagramLayer,e.diagramRenderer,s,void 0,void 0,i);for(var o=0;o0&&this.renderBasicElement(e),!this.diagramActions||!(this.diagramActions&ee.Render)||ee.ToolAction&this.diagramActions||Ds(this)||1!==this.scroller.currentZoom?this.refreshElements(e):this.renderTimer||(this.renderTimer=setTimeout(function(){i.refreshElements(e)},40)))},t.prototype.updatePortVisibility=function(e,i,r){var s;if((e instanceof te||e instanceof de)&&(!this.drawingObject||!this.drawingObject.shape)&&ro(e)){for(var a=e.ports,l=!1,h=0;h=0&&this.scroller.removeCollection.splice(l,1);var h=this.nameTable[e[parseInt(a.toString(),10)]];this.updateTextElementValue(h),this.diagramRenderer.renderElement(h.wrapper,s,o,void 0,void 0,void 0,void 0,h.zIndex)}for(var c=0;c0?this.scroller.oldCollectionObjects:void 0,b=Object.keys(S||g.zIndexTable);b.sort(function(N,T){return parseInt(""+N,10)-parseInt(""+T,10)});for(var M=0,w=b;M0?h:0)+"px",y=(this.realActions&$i.vScrollbarMoved?0:-(this.scroller.verticalOffset<0?this.scroller.verticalOffset:0))+"px"):(v="0px",y="0px"),this.realActions&$i.hScrollbarMoved&&(this.realActions=this.realActions&~$i.hScrollbarMoved),this.realActions&$i.vScrollbarMoved&&(this.realActions=this.realActions&~$i.vScrollbarMoved)):(v=(l.x<0?h:-this.scroller.horizontalOffset)+"px",y=(l.y<0?c:-this.scroller.verticalOffset)+"px"),this.diagramLayer.style.left=v,this.diagramLayer.style.top=y,A.tx=-l.x/A.scale,A.ty=-l.y/A.scale);var P=!0;if(o&&(P=!1),this.updateTextElementValue(D),this.refreshing&&D.shape.activity&&D.shape.activity.subProcess&&D.shape.activity.subProcess.processes){for(var L=0;L0){var o=s.children[0],a=o.data;(r.isBezierEditing&&this.selectedItems.connectors[0].id===r.id||"Bezier"!==r.type)&&r.getSegmentElement(r,o,"ComplexHierarchicalTree"===this.layout.type||"HierarchicalTree"===this.layout.type?this.layout.orientation:void 0,void 0,!1),o.data!==a&&(s.measure(new me),s.arrange(s.desiredSize),"SVG"===this.mode&&!e&&this.updateDiagramObject(r))}}else this.constraints&nt.Bridging&&console.warn('[WARNING] :: Module "ConnectorBridging" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.setCursor=function(e){this.diagramRenderer.setCursor(this.diagramCanvas,e)},t.prototype.clearCanvas=function(e){var i=e.contentWidth||e.diagramLayer.width/this.scroller.currentZoom,r=e.contentHeight||e.diagramLayer.height/this.scroller.currentZoom;"SVG"!==e.mode&&bo.getContext(e.diagramLayer).clearRect(0,0,i,r)},t.prototype.updateScrollOffset=function(){this.scroller.setScrollOffset(this.diagramCanvas.scrollLeft,this.diagramCanvas.scrollTop),ib(this),Ds(this)&&this.scroller.virtualizeElements()},t.prototype.setOffset=function(e,i){var r="domTable";window[""+r][this.element.id+"content"]||(window[""+r][this.element.id+"content"]=document.getElementById(this.element.id+"content"));var s=window[""+r][this.element.id+"content"];s&&(s.scrollLeft=e,s.scrollTop=i)},t.prototype.setSize=function(e,i){if(this.diagramLayer&&!this.preventDiagramUpdate){var r=Za(this);e-=r.width,i-=r.height;var s=this.spatialSearch.getPageBounds();s.x*=this.scroller.currentZoom,s.y*=this.scroller.currentZoom,s.width*=this.scroller.currentZoom,s.height*=this.scroller.currentZoom;var o="SVG"===this.mode?1:1.5,a="SVG"===this.mode?yT(this.element.id):this.diagramLayer,h="Canvas"===this.mode&&this.constraints&nt.Virtualization?this.scroller.viewPortHeight:i;a.setAttribute("width",(o*("Canvas"===this.mode&&this.constraints&nt.Virtualization?this.scroller.viewPortWidth:e)).toString()),a.setAttribute("height",(o*h).toString());var c=document.getElementById(this.element.id+"_diagramUserHandleLayer");c&&(c.style.width=e+"px",c.style.height=i+"px");var d={width:e.toString(),height:i.toString()};this.diagramLayerDiv.style.width=e+"px",this.diagramLayerDiv.style.height=i+"px",ti(FF(this.element.id),d),ti(function xoe(n){return xt(n).getElementsByClassName("e-ports-expand-layer")[0]}(this.element.id),d);var u=Fl(this.element.id);ti(u,d),u.parentNode.style.width=e+"px",u.parentNode.style.height=i+"px";var f=jd(this.element.id);ti(f,d),this.diagramRenderer.updateGrid(this.snapSettings,f,this.scroller.transform,this.rulerSettings,this.hRuler,this.vRuler),ti(bT(this.element.id),d),this.htmlLayer.style.width=e+"px",this.htmlLayer.style.height=i+"px","SVG"!==this.mode&&!Ds(this)&&this.refreshDiagramLayer(),"SVG"===this.mode&&Ds(this)&&this.scroller.virtualizeElements()}},t.prototype.transformLayers=function(){var e=this.spatialSearch.getPageBounds();e.x*=this.scroller.currentZoom,e.y*=this.scroller.currentZoom,e.width*=this.scroller.currentZoom,e.height*=this.scroller.currentZoom,this.diagramRenderer.updateGrid(this.snapSettings,jd(this.element.id),this.scroller.transform,this.rulerSettings,this.hRuler,this.vRuler),this.diagramRenderer.transformLayers(this.scroller.transform,"SVG"===this.mode),this.diagramActions&ee.DragUsingMouse||this.updateSelector(),this.renderPageBreaks(e)},t.prototype.removePageBreaks=function(){if(this.diagramLayer){var e=_F(this.element.id);if(e&&e.childNodes)for(var i=e.childNodes.length,r=0;rthis.pageSettings.height&&(e=this.pageSettings.height,this.pageSettings.height=this.pageSettings.width,this.pageSettings.width=e):this.pageSettings.height>this.pageSettings.width&&(e=this.pageSettings.width,this.pageSettings.width=this.pageSettings.height,this.pageSettings.height=e)},t.prototype.setOverview=function(e,i){if(e)e&&(this.views.push(e.id),this.views[e.id]=e,e.renderDocument(e),e.diagramRenderer.setLayers(),e.updateView(e),this.renderNodes(e));else{for(var r=0;r1&&this.updateSelectionRectangle(),this.isProtectedOnChange=s},t.prototype.updateSelectionRectangle=function(){for(var e=pm(this.element.id),i=!1,r=0;r1&&this.updateSelectionRectangle(),this.enableServerDataBinding(e)},t.prototype.renderSelectorForAnnotation=function(e,i){this.diagramRenderer.renderResizeHandle(e.wrapper.children[0],i,e.thumbsConstraints,this.scroller.currentZoom,e.constraints,this.scroller.transform,void 0,ro(e.annotation),void 0,void 0,e.handleSize)},t.prototype.drawSelectionRectangle=function(e,i,r,s){this.clearSelectorLayer(),this.diagramRenderer.drawSelectionRectangle(e,i,r,s,this.adornerLayer,this.scroller.transform)},t.prototype.renderHighlighter=function(e){var i=Fl(this.element.id);this.diagramRenderer.renderHighlighter(e,i,this.scroller.transform)},t.prototype.clearHighlighter=function(){var e=Fl(this.element.id),i=e.getElementById(e.id+"_highlighter");i&&i.parentNode.removeChild(i)},t.prototype.getNodesConnectors=function(e){for(var i=0;i0;h--)this.eventHandler&&this.eventHandler.touchArgs&&"touchmove"===this.eventHandler.touchArgs.type?(this.diagramRenderer.touchMove=!0,l&&l===o[h-1].id||(a=o[h-1]).parentNode.removeChild(a)):(a=o[h-1]).parentNode.removeChild(a);if(!ce()){var c=IT(this.element.id).childNodes;for(r=c.length;r>0;r--)c[r-1].parentNode.removeChild(c[r-1])}}},t.prototype.getWrapper=function(e,i){var r;i=e.id+"_"+i;for(var s=e instanceof Mi?e:this.getPortContainer(this.nameTable[e.id]),o=0;o0&&this.applyStyle(e,a=r.annotations)}for(i=0;i0){var a=this.selectedItems.connectors[parseInt(i.toString(),10)].annotations;this.applyStyle(e,a)}},t.prototype.applyStyle=function(e,i){for(var r=0;r0)for(var i=0;i0?r[0].zIndex+(e?1:-1):e?0:this.nodes.length+this.connectors.length-1)<0?i=this.nodes.length+this.connectors.length-1:i===this.nodes.length+this.connectors.length&&(i=0);for(var s=0;s0)for(var s=void 0,o=r.children.length-1;o>=0;o--){var a=r.children[parseInt(o.toString(),10)];i.length>0&&-1!==i.indexOf(a.id.split("_groupElement")[0])&&(r.parentNode.insertBefore(a,s||r),s=a)}r&&r.parentNode.removeChild(r)},t.prototype.deleteGroup=function(e){var r=[];e.children&&(r=this.commandHandler.getChildren(e,[])),this.UpdateBlazorDiagramModelCollection(e);for(var s=0,o=r;s0)for(var xe=0;xe0)if("Path"===t.shape.type&&void 0!==n.shape.data)t.wrapper.children[0].data=n.shape.data;else if("Text"===t.shape.type&&void 0!==n.shape.content)t.wrapper.children[0].content=n.shape.content;else if("Image"===t.shape.type&&void 0!==n.shape.source)t.wrapper.children[0].source=n.shape.source;else if("Native"===t.shape.type){for(var r=void 0,s=0;s-1)&&(this.diagramActions&ee.PreventZIndexOnDragging?this.updateDiagramObject(e,!0):this.updateDiagramObject(e)),!s&&d&&(this.lineRoutingModule&&this.diagramActions&&this.constraints&nt.LineRouting&&"helper"!==e.id?this.diagramActions&ee.ToolAction||this.lineRoutingModule.renderVirtualRegion(this,!0):this.diagramActions&&this.constraints&nt.LineRouting&&"helper"!==e.id&&console.warn('[WARNING] :: Module "LineRouting" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),this.updateConnectorEdges(e),"helper"!==e.id&&!(this.diagramActions&ee.ToolAction))))for(var Sa=this.spatialSearch.findObjects(e.wrapper.outerBounds),Mo=0;Moe?Math.abs(r-e):Math.abs(e-r),d=s>i?Math.abs(s-i):Math.abs(i-s);(0===c&&0===d||Number.isNaN(c)&&Number.isNaN(d))&&o.laneMargin&&(u=o.margin.left-o.laneMargin.left,f=o.margin.top-o.laneMargin.top);var p=o.width,g=o.height,v=new Ne(0,0,0,0);if(0!==p&&0!==g&&(v=new Ne((0!==r?r:o.offsetX)-p/2,(0!==s?s:o.offsetY)-g/2,p,g)),h){var y=l,b=this.selectedItems.nodes?this.selectedItems.nodes[0]:void 0;if(""!==y.textAnnotation.textAnnotationTarget&&this.nameTable[y.textAnnotation.textAnnotationTarget])if(""===o.parentId||b&&b.shape&&"TextAnnotation"===b.shape.shape){if("Auto"===y.textAnnotation.textAnnotationDirection&&a.children[0]instanceof Mi&&a.children[0].children[0]instanceof Ze){var w=a.children[0],C=document.getElementById(w.id+"_groupElement"),D=document.getElementById(w.children[0].id+"_groupElement");C.removeChild(D),w.children.splice(0,1),this.isProtectedOnChange=!0,this.bpmnModule.setAnnotationPath(v,w,o,y,y.textAnnotation.textAnnotationDirection,this),this.isProtectedOnChange=!1}}else this.isPositionUndo=!0,this.updateTextAnnotationInSwimlane(o,o),this.isPositionUndo=!1;else o.inEdges.length>0&&(x=this.nameTable[""+o.inEdges[0]])&&x.isBpmnAnnotationConnector&&(x.sourcePoint={x:r>e?x.sourcePoint.x+c:x.sourcePoint.x-c,y:s>i?x.sourcePoint.y+d:x.sourcePoint.y-d});this.nodePropertyChange(o,{},P={ports:[{offset:o.ports[0].offset}]})}else for(var L=0,O=o.outEdges;Le?T.offsetX+c:T.offsetX-c,T.offsetY=s>i?T.offsetY+d:T.offsetY-d,P={offsetX:T.offsetX,offsetY:T.offsetY}),this.nodePropertyChange(T,z,P)}}}},t.prototype.updatePorts=function(e,i){if(e&&e.ports.length>0)for(var r=0,s=Object.keys(e.ports);r0)for(var i=0;i0)for(var r=0;r0&&void 0===r.segments&&(e.segments=[]),void 0!==r.shape&&void 0!==e.shape&&e.shape&&"Bpmn"===e.shape.type&&this.bpmnModule&&this.bpmnModule.updateBPMNConnector(e,i,r,this),void 0!==e.constraints?(this.updateThumbConstraints(this.selectedItems.connectors,this.selectedItems),s=!0):s},t.prototype.connectorPropertyChange=function(e,i,r,s,o){if(this.canEnableBlazorObject){var a=$(e);this.insertValue(a,!1)}var d,u,f,p,l=e.wrapper.bounds,h=!1,c=[];if(h=this.connectorProprtyChangeExtend(e,i,r,h),void 0!==r.visible&&this.updateElementVisibility(e.wrapper,e,e.visible),void 0!==r.sourcePoint||void 0!==r.targetPoint||void 0!==r.sourceID||void 0!==r.targetID||void 0!==r.targetPadding||void 0!==r.sourcePortID||void 0!==r.targetPortID||void 0!==r.sourcePadding||void 0!==r.type||void 0!==r.segments||void 0!==r.flip){if(void 0!==r.sourceID&&r.sourceID!==i.sourceID||r.sourcePortID){if(u=this.findInOutConnectPorts(g=this.nameTable[e.sourceID],!1),(!g||Bh(g)||""!==e.sourcePortID&&Nd(u))&&(e.sourceWrapper=g?this.getEndNodeWrapper(g,e,!0):void 0,e.sourcePortID&&void 0===r.sourcePortID&&(e.sourcePortWrapper=g?this.getWrapper(g.wrapper,e.sourcePortID):void 0),this.removePortEdges(this.nameTable[i.sourceID]||g,i.sourcePortID||e.sourcePortID,e.id,!1)),void 0!==r.sourceID&&void 0!==i.sourceID&&""!==i.sourceID){var v=this.nameTable[i.sourceID];void 0!==v&&v.outEdges&&-1!==v.outEdges.indexOf(e.id)&&sm(v.outEdges,e.id)}this.updateEdges(e)}if(void 0!==r.targetID&&r.targetID!==i.targetID){if(d=this.findInOutConnectPorts(y=this.nameTable[r.targetID],!0),(!y||ua(y)||""!==e.targetPortID&&Hh(d))&&(e.targetWrapper=y?this.getEndNodeWrapper(y,e,!1):void 0,e.targetPortID&&void 0===r.targetPortID&&(e.targetPortWrapper=y?this.getWrapper(y.wrapper,e.targetPortID):void 0),this.removePortEdges(this.nameTable[i.targetID]||y,i.targetPortID||e.targetPortID,e.id,!0)),void 0!==i&&void 0!==i.targetID&&""!==i.targetID){var S=this.nameTable[i.targetID];void 0!==S&&S.inEdges&&-1!==S.inEdges.indexOf(e.id)&&sm(S.inEdges,e.id)}this.updateEdges(e)}var g,y;void 0!==r.sourcePortID&&r.sourcePortID!==i.sourcePortID&&(e.sourceID&&this.nameTable[e.sourceID]&&(f=this.nameTable[e.sourceID].wrapper),!(g=this.nameTable[e.sourceID])||Bh(g)||""!==e.sourcePortID&&Nd(u)?e.sourcePortWrapper=f?this.getWrapper(f,r.sourcePortID):void 0:""===e.sourcePortID&&!Bh(g)&&(e.sourcePortWrapper=void 0)),void 0!==r.targetPortID&&r.targetPortID!==i.targetPortID&&(e.targetID&&this.nameTable[e.targetID]&&(p=this.nameTable[e.targetID].wrapper),!(y=this.nameTable[e.targetID])||ua(y)||""!==e.targetPortID&&Hh(d)?e.targetPortWrapper=p?this.getWrapper(p,r.targetPortID):void 0:""===e.targetPortID&&!ua(y)&&(e.targetPortWrapper=void 0)),void 0!==r.flip&&(e.flip=r.flip,EF(e)),"Orthogonal"===e.type&&this.lineRoutingModule&&this.diagramActions&&this.constraints&nt.LineRouting&&!(this.diagramActions&ee.ToolAction)&&"ComplexHierarchicalTree"!==this.layout.type&&(this.lineRoutingModule.renderVirtualRegion(this,!0),e.sourceID!==e.targetID&&e.segments.length>1&&this.lineRoutingModule.refreshConnectorSegments(this,e,!1)),c=this.getPoints(e)}void 0!==r.style&&Fh(r.style,e.wrapper.children[0]),(c.length>0||void 0!==r.sourceDecorator||void 0!==r.targetDecorator&&function qse(n){return-1!==n.indexOf("shape")||-1!==n.indexOf("pathData")||-1!==n.indexOf("width")||-1!==n.indexOf("height")}(Object.keys(r.targetDecorator))||void 0!==r.cornerRadius)&&(ip(e,c.length>0?c:e.intermediatePoints,this.diagramActions),void 0!==r.type&&(h=!0),c.length>0&&(e.wrapper.measure(new me(e.wrapper.width,e.wrapper.height)),e.wrapper.arrange(e.wrapper.desiredSize),this.updateConnectorAnnotation(e),this.updateConnectorPort(e),this.updateConnectorfixedUserHandles(e),this.updateObject(e,i,r))),(r.sourcePoint||r.targetPoint||r.segments)&&this.diagramActions===ee.Render&&(h=!0),"Bpmn"===e.shape.type&&"Default"===e.shape.sequence&&"Sequence"===e.shape.flow&&this.commandHandler.updatePathElementOffset(e),s||this.updateBridging(),this.updateAnnotations(r,e),this.updateConnectorPorts(r,e),this.updatefixedUserHandle(r,e),e.wrapper.measure(new me(e.wrapper.width,e.wrapper.height)),e.wrapper.arrange(e.wrapper.desiredSize),!1===l.equals(l,e.wrapper.bounds)&&(this.updateQuad(e),"Drag"!==this.eventHandler.currentAction&&this.updateGroupSize(e)),!0===h&&this.checkSelectedItem(e)&&(!(this.diagramActions&ee.ToolAction)||this.diagramActions&ee.UndoRedo)&&this.updateSelector(),this.preventConnectorsUpdate||(!Ds(this)||Ds(this)&&this.scroller.oldCollectionObjects.indexOf(e.id)>-1)&&(this.diagramActions&ee.PreventZIndexOnDragging?this.updateDiagramObject(e,!0):this.updateDiagramObject(e)),this.updateConnectorEdges(e),this.diagramActions&&"New"!==e.status&&(e.status="Update"),this.triggerPropertyChange(o,e,i,r)},t.prototype.removePortEdges=function(e,i,r,s){if(e)for(var o=0;o0&&e.id===s[s.length-1].id&&(r=!0),r},t.prototype.updateDiagramContainerVisibility=function(e,i){if(e instanceof Cs)for(var r=0;r>"),r instanceof es&&this.updateAnnotationWrapper(r,s,o,a)),void 0!==e.template&&(r.content=e.template,this.updateAnnotationWrapper(r,s,o,a))},t.prototype.updateAnnotationWrapper=function(e,i,r,s){for(var o=0,a=this.views;o=0&&this.nodes.splice(s,1),delete this.nameTable[""+r]}var o=this.nodes.indexOf(this.nameTable[this.currentSymbol.id]);o>=0&&this.nodes.splice(o,1)}},t.prototype.selectDragedNode=function(e,i,r){this.currentSymbol=e,"SVG"!==this.mode&&this.refreshDiagramLayer(),this.commandHandler.oldSelectedObjects=am(this),this.commandHandler.select(e),this.eventHandler.mouseDown(i.event),this.eventHandler.mouseMove(i.event,i),this.preventDiagramUpdate=!1,this.updatePage(),r.style.opacity="0"},t.prototype.initDroppables=function(){var s,o,e=this,i={},r={},a="selectedSymbols";this.droppable=new lR(this.element);var l=5;this.droppable.over=function(h){if(e.rulerSettings.showRulers){var c=document.getElementById(e.element.id+"_vRuler"),d=parseFloat(c.style.width);l=d+1}if(0===e.previousSelectedObjects.length&&!e.currentSymbol&&(e.previousSelectedObjects=e.commandHandler.getSelectedObject()),e.commandHandler.PreventConnectorSplit=!0,e.currentSymbol)h.event.touches&&h.event.touches.length&&e.eventHandler.mouseMove(h.event,h.event.touches);else{var u=null;if(!h.dragData&&"drag"===h.name){var f=document.getElementsByClassName("e-dragclone")[0];f&&(u=f)}if(h.dragData||u){var p=void 0,g=void 0;document.getElementById(e.element.id+"content").focus();var v=e.eventHandler.getMousePosition(h.event),y=void 0,S=u||h.dragData.helper,b=S.getAttribute("paletteId"),M=void 0,w=void 0,C=void 0,D=void 0;if(!b&&h.dragData){e.triggerEvent(Ce.dragEnter,A={source:null,element:p,cancel:!1,diagram:e,dragData:h.dragData.draggedElement.ej2_instances[0].dragData,dragItem:p});var x=void 0,P=void 0;if(A.dragItem){if(A.dragItem.sourcePoint&&A.dragItem.targetPoint?P=new de(e,"connectors",A.dragItem,!0):x=new te(e,"nodes",A.dragItem,!0),e.initObject(p=x||P,void 0,void 0,!0),e.enterObject=p,e.enterTable=r,p instanceof te)x.offsetX=v.x+5+x.width*x.pivot.x,x.offsetY=v.y+x.height*x.pivot.y;else if(p instanceof de){var L=Ne.toBounds([p.sourcePoint,p.targetPoint]),O=v.x-L.left,N=v.y-L.top;p.sourcePoint.x+=O,p.sourcePoint.y+=N,p.targetPoint.x+=O,p.targetPoint.y+=N}e.preventDiagramUpdate=!0,e.currentSymbol=p,"SVG"!==e.mode&&e.refreshDiagramLayer(),e.selectDragedNode(p,h,S),delete e.enterObject,delete e.enterTable,e.droppable[""+a]=S,e.allowServerDataBinding=!0}}if(b){var T=document.getElementById(b).ej2_instances[0];if(e.droppable.sourceElement=T,T){var B=T[""+a];e.allowServerDataBinding=!1,y=$(T[""+a]),i=T.childTable;var j=B.wrapper.children[0].children[0];if(D=function $se(n,t,e){var i=AF(n,t,e,"width"),r=AF(n,t,e,"height");return new me(i,r)}(T,y,j),T[""+a]instanceof te){"TextAnnotation"===B.shape.shape?(y.offsetX=v.x+11+D.width*y.pivot.x,y.offsetY=v.y+11+D.height*y.pivot.y):(y.offsetX=v.x+5+D.width*y.pivot.x,y.offsetY=v.y+D.height*y.pivot.y),"Bpmn"===(x=new te(e,"nodes",y,!0)).shape.type&&x.shape.activity.subProcess.processes&&x.shape.activity.subProcess.processes.length&&(x.shape.activity.subProcess.processes=[]),w=x.previewSize,C=T.symbolDragSize;var Q=T.symbolPreview;if(x.width=(M=x.dragSize).width||C.width||w.width||Q.width||x.width,x.height=M.height||C.height||w.height||Q.height||x.height,"SwimLane"===x.shape.type){if(e.diagramActions|=ee.PreventHistory,x.shape.isLane){x.children=[],s={id:"header"+Qe()},"Horizontal"===x.shape.orientation?(s.width=x.shape.lanes[0].header.width,s.height=x.shape.lanes[0].height):(s.width=x.shape.lanes[0].width,s.height=x.shape.lanes[0].header.height),s.style=x.shape.lanes[0].header.style,s.offsetX=v.x+l+s.width/2,s.offsetY=v.y+s.height/2,e.diagramActions|=ee.PreventCollectionChangeOnDragOver,s=e.add(s),o={id:"body"+Qe()},"Horizontal"===x.shape.orientation?(o.width=x.shape.lanes[0].width-s.width,o.height=x.shape.lanes[0].height,o.offsetX=v.x+l+(x.shape.lanes[0].header.width+o.width/2),o.offsetY=v.y+o.height/2):(o.width=x.shape.lanes[0].width,o.height=x.shape.lanes[0].height-s.height,o.offsetX=v.x+l+o.width/2,o.offsetY=v.y+(x.shape.lanes[0].header.height+o.height/2)),o.style=x.shape.lanes[0].style,o=e.add(o);var oe={id:"group"+Qe(),children:[s.id,o.id]};oe.shape=x.shape,oe.width=x.shape.lanes[0].width,oe.height=x.shape.lanes[0].height,oe.previewSize=x.previewSize,oe.dragSize=x.dragSize,oe.addInfo=x.addInfo,x=e.add(oe),e.diagramActions&=~ee.PreventCollectionChangeOnDragOver}e.diagramActions&=~ee.PreventHistory}if(x.shape.isPhase&&((g="Horizontal"===x.shape.orientation)?(x.offsetX=v.x+l+(x.width||j.actualSize.width)/2,x.offsetY=v.y,x.shape.data="M20,"+x.height/2+" L"+(x.width-20)+","+x.height/2+"z",x.height=1):(x.offsetX=v.x+5,x.offsetY=v.y+(x.height||j.actualSize.height)/2,x.shape.data="M"+x.width/2+",20 L"+x.width/2+","+(x.height-20)+"z",x.width=1)),"UmlClassifier"===x.shape.type&&(x.children=x.width=x.height=void 0,y.children=void 0,"Class"===x.shape.classifier&&x.shape.classShape.methods.length<=0&&x.shape.classShape.attributes.length<=0&&(x.shape.classShape.attributes=[{name:"Name",type:"Type",style:{}}]),"Enumeration"===x.shape.classifier&&x.shape.enumerationShape.members.length<=0&&(x.shape.enumerationShape.members=[{name:"Name"}]),"Interface"===x.shape.classifier&&x.shape.interfaceShape.methods.length<=0&&x.shape.interfaceShape.attributes.length<=0&&(x.shape.interfaceShape.attributes=[{name:"Name",type:"Type",style:{}}])),p=x,y.children){var ue=y;r=e.getChildren(ue,{},i),nT(ue,-ue.offsetX,-ue.offsetY,r,!0,e)}}else if(T[""+a]instanceof de){p=new de(e,"connectors",y,!0);var Me=Ne.toBounds([p.sourcePoint,p.targetPoint]),De=v.x-Me.left,xe=v.y-Me.top;p.sourcePoint.x+=De,p.sourcePoint.y+=xe,p.targetPoint.x+=De,p.targetPoint.y+=xe}p.shape.isLane||(p.id+=Qe());var A={source:T,element:p,cancel:!1,diagram:e,dragData:null,dragItem:p};if(e.enterObject=p,e.enterTable=r,e.triggerEvent(Ce.dragEnter,A),p instanceof te&&"SwimLane"===p.shape.type&&p.shape.isLane){var Ie=A.element,Ve=Ie.shape.lanes[0];g="Horizontal"===Ie.shape.orientation;var ot=e.nameTable[p.children[0]],$e=e.nameTable[p.children[1]];w=p.previewSize,C=T.symbolDragSize,Ve.width=(M=p.dragSize).width||C.width||w.width||Ve.width,Ve.height=M.height||C.height||w.height||Ve.height,g?(s.width=Ve.header.width,s.height=Ve.height,o.width=Ve.width-s.width,o.height=Ve.height,o.offsetX=v.x+l+(Ve.header.width+$e.width/2),o.offsetY=v.y+$e.height/2):(s.width=Ve.width,s.height=Ve.header.height,o.width=Ve.width,o.height=Ve.height-s.height,o.offsetX=v.x+l+$e.width/2,o.offsetY=v.y+(Ve.header.height+$e.height/2)),s.offsetX=v.x+l+ot.width/2,s.offsetY=v.y+ot.height/2,p.width=Ve.width,p.height=Ve.height}if(p instanceof te&&p.shape.isPhase&&(g?p.height=1:p.width=1),!e.activeLayer.lock&&!A.cancel){if(e.preventDiagramUpdate=!0,p.children&&e.findChild(p,r),e.preventDiagramUpdate=!0,p.zIndex!==Number.MIN_VALUE&&(p.zIndex=Number.MIN_VALUE),e.initObject(p,void 0,void 0,!0),e.bpmnModule)for(var Ci=0;Ci0&&(S.segments=[]),d=this.add(S,!0)),(S||d)&&(Vv(this)||Wv(this))&&this.select([this.nameTable[S[""+b]]],!1,this.previousSelectedObjects),y.target&&y.target instanceof de&&!0===this.enableConnectorSplit&&this.nameTable[S[""+b]]instanceof te&&(this.commandHandler.connectorSplit(this.nameTable[S[""+b]],y.target),this.commandHandler.PreventConnectorSplit=!1))),this.protectPropertyChange(!1),v=this.nameTable[S[""+b]],S.hasTarget&&(S.nodeId=S.hasTarget,this.remove(S)),this.bpmnModule&&v instanceof te&&S.processId&&(v.processId=S.processId,this.bpmnModule.dropBPMNchild(this.nameTable[v.processId],v,this)),y.cancel||this.endGroupAction(),"SVG"!==this.mode&&this.refreshDiagramLayer(),delete this.droppable[""+c]):(this.triggerEvent(Ce.drop,y={source:h.droppedElement,element:void 0,target:this.eventHandler.hoverNode||this.eventHandler.lastObjectUnderMouse||this,cancel:!1,position:void 0}),S=void 0,b="id"),this.droppable[M="selectedSymbols"]&&this.droppable[""+M].parentNode)gt(this.droppable[""+M]);else for(w=document.getElementsByClassName("e-dragclone"),C=0;C0)for(var f=0;f1),e.previousSelectedObject=null}}},t.prototype.getDropEventArgs=function(e){if(this.eventHandler.lastObjectUnderMouse||this.eventHandler.hoverNode){var i=this.eventHandler.lastObjectUnderMouse||this.eventHandler.hoverNode;e.target=ps(i)===de?{connector:i}:{node:i}}else e.target.diagramId=this.element.id},t.prototype.removeChildInNodes=function(e){if(e){if(e.children)for(var i=0;i1){var l=2;if(e.children&&e.children.length>0)for(;e.children.indexOf(i.objects[s-l])>-1;)l++;this.commandHandler.moveSvgNode(e.id,i.objects[s-l]),this.commandHandler.moveSvgNode(i.objects[s-l],e.id)}else if(o){var h=this.commandHandler.getLayer(this.layerZIndexTable[o.zIndex]).objects[0];h?(this.commandHandler.moveSvgNode(e.id,h),this.commandHandler.updateNativeNodeIndex(e.id,h)):this.moveObjectsUp(e,i)}else this.moveObjectsUp(e,i)},t.prototype.moveObjectsUp=function(e,i){for(var r,s=this.layers.length-1;s>=0;s--)if(r=this.layers[parseInt(s.toString(),10)],i.id!==r.id){var o=this.commandHandler.getLayer(this.layerZIndexTable[r.zIndex]).objects[r.objects.length-1];if(o){this.commandHandler.moveSvgNode(e.id,o),this.commandHandler.moveSvgNode(o,e.id);break}}},t.prototype.insertData=function(e){return this.crudOperation(e,"create",this.getNewUpdateNodes("New"))},t.prototype.updateData=function(e){return this.crudOperation(e,"update",this.getNewUpdateNodes("Update"))},t.prototype.removeData=function(e){return this.crudOperation(e,"destroy",this.getDeletedNodes())},t.prototype.crudOperation=function(e,i,r){if(e){var s=this.parameterMap(e,!(e instanceof de));if(s){var o=e instanceof de?this.dataSourceSettings.connectionDataSource.crudAction[""+i]:this.dataSourceSettings.crudAction[""+i];this.raiseAjaxPost(JSON.stringify(s),o)}return s}var a=r;return this.processCrudCollection(a,this.dataSourceSettings.crudAction[""+i],this.dataSourceSettings.connectionDataSource.crudAction[""+i]),a},t.prototype.processCrudCollection=function(e,i,r){if(e.nodes){var s=[],o=void 0;for(o=0;o0&&this.raiseAjaxPost(JSON.stringify(s),i)}if(e.connectors){for(s=[],o=void 0,o=0;o0&&this.raiseAjaxPost(JSON.stringify(s),r)}},t.prototype.parameterMap=function(e,i){var s,r={},o=i?this.dataSourceSettings:this.dataSourceSettings.connectionDataSource;if(o.id&&(r[o.id]=e.id),o.sourcePointX&&o.sourcePointY&&(r[o.sourcePointX]=e.sourcePoint.x,r[o.sourcePointY]=e.sourcePoint.y),o.targetPointX&&o.targetPointY&&(r[o.targetPointX]=e.targetPoint.x,r[o.targetPointY]=e.targetPoint.y),o.sourceID&&(r[o.sourceID]=e.sourceID),o.targetID&&(r[o.targetID]=e.targetID),o.crudAction&&o.crudAction.customFields&&o.crudAction.customFields.length>0)for(s=0;s{class n extends vh{constructor(e){super(),this.viewContainerRef=e,ml("currentInstance",this,this.viewContainerRef),this.registerEvents($ae),this.directivePropList=qae}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-layer"]],inputs:{addInfo:"addInfo",id:"id",lock:"lock",objects:"objects",visible:"visible",zIndex:"zIndex"},features:[yn]}),n})(),Jae=(()=>{class n extends mh{constructor(){super("layers")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-layers"]],contentQueries:function(e,i,r){if(1&e&&dn(r,Zae,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),Kae=["action","cursor"],ele=[],tle=(()=>{class n extends vh{constructor(e){super(),this.viewContainerRef=e,ml("currentInstance",this,this.viewContainerRef),this.registerEvents(ele),this.directivePropList=Kae}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-cursormap"]],inputs:{action:"action",cursor:"cursor"},features:[yn]}),n})(),ile=(()=>{class n extends mh{constructor(){super("customcursor")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-cursormaps"]],contentQueries:function(e,i,r){if(1&e&&dn(r,tle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),rle=["alignment","cornerRadius","displacement","fill","handleStrokeColor","handleStrokeWidth","height","iconStrokeColor","iconStrokeWidth","id","offset","padding","pathData","tooltip","visibility","width"],nle=[],sle=(()=>{class n extends vh{constructor(e){super(),this.viewContainerRef=e,ml("currentInstance",this,this.viewContainerRef),this.registerEvents(nle),this.directivePropList=rle}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-connector-fixeduserhandle"]],inputs:{alignment:"alignment",cornerRadius:"cornerRadius",displacement:"displacement",fill:"fill",handleStrokeColor:"handleStrokeColor",handleStrokeWidth:"handleStrokeWidth",height:"height",iconStrokeColor:"iconStrokeColor",iconStrokeWidth:"iconStrokeWidth",id:"id",offset:"offset",padding:"padding",pathData:"pathData",tooltip:"tooltip",visibility:"visibility",width:"width"},features:[yn]}),n})(),ole=(()=>{class n extends mh{constructor(){super("fixeduserhandles")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-connector-fixeduserhandles"]],contentQueries:function(e,i,r){if(1&e&&dn(r,sle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),ale=["addInfo","alignment","annotationType","constraints","content","displacement","dragLimit","height","horizontalAlignment","hyperlink","id","margin","offset","rotateAngle","rotationReference","segmentAngle","style","template","tooltip","type","verticalAlignment","visibility","width"],lle=[],hle=(()=>{class n extends vh{constructor(e){super(),this.viewContainerRef=e,ml("currentInstance",this,this.viewContainerRef),this.registerEvents(lle),this.directivePropList=ale}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-connector-annotation"]],inputs:{addInfo:"addInfo",alignment:"alignment",annotationType:"annotationType",constraints:"constraints",content:"content",displacement:"displacement",dragLimit:"dragLimit",height:"height",horizontalAlignment:"horizontalAlignment",hyperlink:"hyperlink",id:"id",margin:"margin",offset:"offset",rotateAngle:"rotateAngle",rotationReference:"rotationReference",segmentAngle:"segmentAngle",style:"style",template:"template",tooltip:"tooltip",type:"type",verticalAlignment:"verticalAlignment",visibility:"visibility",width:"width"},features:[yn]}),n})(),cle=(()=>{class n extends mh{constructor(){super("annotations")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-connector-annotations"]],contentQueries:function(e,i,r){if(1&e&&dn(r,hle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),dle=["addInfo","allowNodeOverlap","annotations","bezierSettings","bridgeSpace","connectionPadding","connectorSpacing","constraints","cornerRadius","dragSize","excludeFromLayout","fixedUserHandles","flip","flipMode","hitPadding","id","margin","maxSegmentThumb","ports","previewSize","segmentThumbShape","segmentThumbSize","segments","shape","sourceDecorator","sourceID","sourcePadding","sourcePoint","sourcePortID","style","symbolInfo","targetDecorator","targetID","targetPadding","targetPoint","targetPortID","tooltip","type","visible","wrapper","zIndex"],ule=[],v_=(()=>{class n extends vh{constructor(e){super(),this.viewContainerRef=e,this.tags=["fixedUserHandles","annotations"],ml("currentInstance",this,this.viewContainerRef),this.registerEvents(ule),this.directivePropList=dle}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-connector"]],contentQueries:function(e,i,r){if(1&e&&(dn(r,ole,5),dn(r,cle,5)),2&e){let s;Kr(s=en())&&(i.childFixedUserHandles=s.first),Kr(s=en())&&(i.childAnnotations=s.first)}},inputs:{addInfo:"addInfo",allowNodeOverlap:"allowNodeOverlap",annotations:"annotations",bezierSettings:"bezierSettings",bridgeSpace:"bridgeSpace",connectionPadding:"connectionPadding",connectorSpacing:"connectorSpacing",constraints:"constraints",cornerRadius:"cornerRadius",dragSize:"dragSize",excludeFromLayout:"excludeFromLayout",fixedUserHandles:"fixedUserHandles",flip:"flip",flipMode:"flipMode",hitPadding:"hitPadding",id:"id",margin:"margin",maxSegmentThumb:"maxSegmentThumb",ports:"ports",previewSize:"previewSize",segmentThumbShape:"segmentThumbShape",segmentThumbSize:"segmentThumbSize",segments:"segments",shape:"shape",sourceDecorator:"sourceDecorator",sourceID:"sourceID",sourcePadding:"sourcePadding",sourcePoint:"sourcePoint",sourcePortID:"sourcePortID",style:"style",symbolInfo:"symbolInfo",targetDecorator:"targetDecorator",targetID:"targetID",targetPadding:"targetPadding",targetPoint:"targetPoint",targetPortID:"targetPortID",tooltip:"tooltip",type:"type",visible:"visible",wrapper:"wrapper",zIndex:"zIndex"},features:[yn]}),n})(),m_=(()=>{class n extends mh{constructor(){super("connectors")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-connectors"]],contentQueries:function(e,i,r){if(1&e&&dn(r,v_,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),fle=["cornerRadius","fill","handleStrokeColor","handleStrokeWidth","height","iconStrokeColor","iconStrokeWidth","id","margin","offset","padding","pathData","tooltip","visibility","width"],ple=[],gle=(()=>{class n extends vh{constructor(e){super(),this.viewContainerRef=e,ml("currentInstance",this,this.viewContainerRef),this.registerEvents(ple),this.directivePropList=fle}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-node-fixeduserhandle"]],inputs:{cornerRadius:"cornerRadius",fill:"fill",handleStrokeColor:"handleStrokeColor",handleStrokeWidth:"handleStrokeWidth",height:"height",iconStrokeColor:"iconStrokeColor",iconStrokeWidth:"iconStrokeWidth",id:"id",margin:"margin",offset:"offset",padding:"padding",pathData:"pathData",tooltip:"tooltip",visibility:"visibility",width:"width"},features:[yn]}),n})(),vle=(()=>{class n extends mh{constructor(){super("fixeduserhandles")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-node-fixeduserhandles"]],contentQueries:function(e,i,r){if(1&e&&dn(r,gle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),mle=["addInfo","annotationType","constraints","content","dragLimit","height","horizontalAlignment","hyperlink","id","margin","offset","rotateAngle","rotationReference","style","template","tooltip","type","verticalAlignment","visibility","width"],yle=[],Sle=(()=>{class n extends vh{constructor(e){super(),this.viewContainerRef=e,ml("currentInstance",this,this.viewContainerRef),this.registerEvents(yle),this.directivePropList=mle}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-node-annotation"]],inputs:{addInfo:"addInfo",annotationType:"annotationType",constraints:"constraints",content:"content",dragLimit:"dragLimit",height:"height",horizontalAlignment:"horizontalAlignment",hyperlink:"hyperlink",id:"id",margin:"margin",offset:"offset",rotateAngle:"rotateAngle",rotationReference:"rotationReference",style:"style",template:"template",tooltip:"tooltip",type:"type",verticalAlignment:"verticalAlignment",visibility:"visibility",width:"width"},features:[yn]}),n})(),Ile=(()=>{class n extends mh{constructor(){super("annotations")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-node-annotations"]],contentQueries:function(e,i,r){if(1&e&&dn(r,Sle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),ble=["addInfo","connectionDirection","constraints","height","horizontalAlignment","id","inEdges","margin","offset","outEdges","pathData","shape","style","tooltip","verticalAlignment","visibility","width"],Mle=[],wle=(()=>{class n extends vh{constructor(e){super(),this.viewContainerRef=e,ml("currentInstance",this,this.viewContainerRef),this.registerEvents(Mle),this.directivePropList=ble}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-node-port"]],inputs:{addInfo:"addInfo",connectionDirection:"connectionDirection",constraints:"constraints",height:"height",horizontalAlignment:"horizontalAlignment",id:"id",inEdges:"inEdges",margin:"margin",offset:"offset",outEdges:"outEdges",pathData:"pathData",shape:"shape",style:"style",tooltip:"tooltip",verticalAlignment:"verticalAlignment",visibility:"visibility",width:"width"},features:[yn]}),n})(),Cle=(()=>{class n extends mh{constructor(){super("ports")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-node-ports"]],contentQueries:function(e,i,r){if(1&e&&dn(r,wle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),Ele=["addInfo","annotations","backgroundColor","borderColor","borderWidth","branch","children","collapseIcon","columnIndex","columnSpan","columns","constraints","container","data","dragSize","excludeFromLayout","expandIcon","fixedUserHandles","flip","flipMode","height","horizontalAlignment","id","isExpanded","layoutInfo","margin","maxHeight","maxWidth","minHeight","minWidth","offsetX","offsetY","padding","pivot","ports","previewSize","rotateAngle","rowIndex","rowSpan","rows","shadow","shape","style","symbolInfo","tooltip","verticalAlignment","visible","width","wrapper","zIndex"],Dle=[],y_=(()=>{class n extends vh{constructor(e){super(),this.viewContainerRef=e,this.tags=["fixedUserHandles","annotations","ports"],ml("currentInstance",this,this.viewContainerRef),this.registerEvents(Dle),this.directivePropList=Ele}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-node"]],contentQueries:function(e,i,r){if(1&e&&(dn(r,vle,5),dn(r,Ile,5),dn(r,Cle,5)),2&e){let s;Kr(s=en())&&(i.childFixedUserHandles=s.first),Kr(s=en())&&(i.childAnnotations=s.first),Kr(s=en())&&(i.childPorts=s.first)}},inputs:{addInfo:"addInfo",annotations:"annotations",backgroundColor:"backgroundColor",borderColor:"borderColor",borderWidth:"borderWidth",branch:"branch",children:"children",collapseIcon:"collapseIcon",columnIndex:"columnIndex",columnSpan:"columnSpan",columns:"columns",constraints:"constraints",container:"container",data:"data",dragSize:"dragSize",excludeFromLayout:"excludeFromLayout",expandIcon:"expandIcon",fixedUserHandles:"fixedUserHandles",flip:"flip",flipMode:"flipMode",height:"height",horizontalAlignment:"horizontalAlignment",id:"id",isExpanded:"isExpanded",layoutInfo:"layoutInfo",margin:"margin",maxHeight:"maxHeight",maxWidth:"maxWidth",minHeight:"minHeight",minWidth:"minWidth",offsetX:"offsetX",offsetY:"offsetY",padding:"padding",pivot:"pivot",ports:"ports",previewSize:"previewSize",rotateAngle:"rotateAngle",rowIndex:"rowIndex",rowSpan:"rowSpan",rows:"rows",shadow:"shadow",shape:"shape",style:"style",symbolInfo:"symbolInfo",tooltip:"tooltip",verticalAlignment:"verticalAlignment",visible:"visible",width:"width",wrapper:"wrapper",zIndex:"zIndex"},features:[yn]}),n})(),S_=(()=>{class n extends mh{constructor(){super("nodes")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-nodes"]],contentQueries:function(e,i,r){if(1&e&&dn(r,y_,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})();const xle=["animationComplete","click","collectionChange","commandExecute","connectionChange","contextMenuBeforeItemRender","contextMenuClick","contextMenuOpen","created","dataLoaded","doubleClick","dragEnter","dragLeave","dragOver","drop","elementDraw","expandStateChange","fixedUserHandleClick","historyChange","historyStateChange","keyDown","keyUp","load","loaded","mouseEnter","mouseLeave","mouseOver","mouseWheel","onFixedUserHandleMouseDown","onFixedUserHandleMouseEnter","onFixedUserHandleMouseLeave","onFixedUserHandleMouseUp","onImageLoad","onUserHandleMouseDown","onUserHandleMouseEnter","onUserHandleMouseLeave","onUserHandleMouseUp","positionChange","propertyChange","rotateChange","scrollChange","segmentChange","segmentCollectionChange","selectionChange","sizeChange","sourcePointChange","targetPointChange","textEdit"],Tle=[""];let Ale=(()=>{let n=class extends _l{constructor(e,i,r,s){super(),this.ngEle=e,this.srenderer=i,this.viewContainerRef=r,this.injector=s,this.tags=["layers","customCursor","connectors","nodes"],this.element=this.ngEle.nativeElement,this.injectedModules=this.injectedModules||[];try{let o=this.injector.get("DiagramsHierarchicalTree");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsMindMap");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsRadialTree");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsComplexHierarchicalTree");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsDataBinding");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsSnapping");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsPrintAndExport");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsBpmnDiagrams");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsSymmetricLayout");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsConnectorBridging");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsUndoRedo");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsLayoutAnimation");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsDiagramContextMenu");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsLineRouting");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsConnectorEditing");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsLineDistribution");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsEj1Serialization");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsFlowchartLayout");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}this.registerEvents(xle),this.addTwoWay.call(this,Tle),ml("currentInstance",this,this.viewContainerRef),this.context=new SR}ngOnInit(){this.context.ngOnInit(this)}ngAfterViewInit(){this.context.ngAfterViewInit(this)}ngOnDestroy(){this.context.ngOnDestroy(this)}ngAfterContentChecked(){this.tagObjects[0].instance=this.childLayers,this.childCustomCursor&&(this.tagObjects[1].instance=this.childCustomCursor),this.childConnectors&&(this.tagObjects[2].instance=this.childConnectors),this.childNodes&&(this.tagObjects[3].instance=this.childNodes),this.context.ngAfterContentChecked(this)}};return n.\u0275fac=function(e){return new(e||n)(Ot(Jc),Ot(uM),Ot(An),Ot(Wo))},n.\u0275cmp=jb({type:n,selectors:[["ejs-diagram"]],contentQueries:function(e,i,r){if(1&e&&(dn(r,Qae,5),dn(r,Gae,5),dn(r,Xae,5),dn(r,Jae,5),dn(r,ile,5),dn(r,m_,5),dn(r,S_,5)),2&e){let s;Kr(s=en())&&(i.annotationTemplate=s.first),Kr(s=en())&&(i.nodeTemplate=s.first),Kr(s=en())&&(i.userHandleTemplate=s.first),Kr(s=en())&&(i.childLayers=s.first),Kr(s=en())&&(i.childCustomCursor=s.first),Kr(s=en())&&(i.childConnectors=s.first),Kr(s=en())&&(i.childNodes=s.first)}},inputs:{addInfo:"addInfo",annotationTemplate:"annotationTemplate",backgroundColor:"backgroundColor",bridgeDirection:"bridgeDirection",commandManager:"commandManager",connectorDefaults:"connectorDefaults",connectors:"connectors",constraints:"constraints",contextMenuSettings:"contextMenuSettings",customCursor:"customCursor",dataSourceSettings:"dataSourceSettings",diagramSettings:"diagramSettings",drawingObject:"drawingObject",enableConnectorSplit:"enableConnectorSplit",enablePersistence:"enablePersistence",enableRtl:"enableRtl",fixedUserHandleTemplate:"fixedUserHandleTemplate",getConnectorDefaults:"getConnectorDefaults",getCustomCursor:"getCustomCursor",getCustomProperty:"getCustomProperty",getCustomTool:"getCustomTool",getDescription:"getDescription",getNodeDefaults:"getNodeDefaults",height:"height",historyManager:"historyManager",layers:"layers",layout:"layout",locale:"locale",mode:"mode",nodeDefaults:"nodeDefaults",nodeTemplate:"nodeTemplate",nodes:"nodes",pageSettings:"pageSettings",rulerSettings:"rulerSettings",scrollSettings:"scrollSettings",segmentThumbShape:"segmentThumbShape",segmentThumbSize:"segmentThumbSize",selectedItems:"selectedItems",serializationSettings:"serializationSettings",setNodeTemplate:"setNodeTemplate",snapSettings:"snapSettings",tool:"tool",tooltip:"tooltip",updateSelection:"updateSelection",userHandleTemplate:"userHandleTemplate",width:"width"},outputs:{animationComplete:"animationComplete",click:"click",collectionChange:"collectionChange",commandExecute:"commandExecute",connectionChange:"connectionChange",contextMenuBeforeItemRender:"contextMenuBeforeItemRender",contextMenuClick:"contextMenuClick",contextMenuOpen:"contextMenuOpen",created:"created",dataLoaded:"dataLoaded",doubleClick:"doubleClick",dragEnter:"dragEnter",dragLeave:"dragLeave",dragOver:"dragOver",drop:"drop",elementDraw:"elementDraw",expandStateChange:"expandStateChange",fixedUserHandleClick:"fixedUserHandleClick",historyChange:"historyChange",historyStateChange:"historyStateChange",keyDown:"keyDown",keyUp:"keyUp",load:"load",loaded:"loaded",mouseEnter:"mouseEnter",mouseLeave:"mouseLeave",mouseOver:"mouseOver",mouseWheel:"mouseWheel",onFixedUserHandleMouseDown:"onFixedUserHandleMouseDown",onFixedUserHandleMouseEnter:"onFixedUserHandleMouseEnter",onFixedUserHandleMouseLeave:"onFixedUserHandleMouseLeave",onFixedUserHandleMouseUp:"onFixedUserHandleMouseUp",onImageLoad:"onImageLoad",onUserHandleMouseDown:"onUserHandleMouseDown",onUserHandleMouseEnter:"onUserHandleMouseEnter",onUserHandleMouseLeave:"onUserHandleMouseLeave",onUserHandleMouseUp:"onUserHandleMouseUp",positionChange:"positionChange",propertyChange:"propertyChange",rotateChange:"rotateChange",scrollChange:"scrollChange",segmentChange:"segmentChange",segmentCollectionChange:"segmentCollectionChange",selectionChange:"selectionChange",sizeChange:"sizeChange",sourcePointChange:"sourcePointChange",targetPointChange:"targetPointChange",textEdit:"textEdit"},features:[yn],decls:0,vars:0,template:function(e,i){},encapsulation:2,changeDetection:0}),z0([TC()],n.prototype,"annotationTemplate",void 0),z0([TC()],n.prototype,"nodeTemplate",void 0),z0([TC()],n.prototype,"userHandleTemplate",void 0),n=z0([PZ([SR])],n),n})(),Lle=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=km({type:n}),n.\u0275inj=Sp({imports:[[sq]]}),n})();const Nle=["diagram"];let Ole=(()=>{class n{constructor(){this.sourcePoint1="node1",this.targetPoint1="node2"}getNodeDefaults(e){return e.height=70,e.width=100,e}group(){this.diagram.selectAll(),this.diagram.group()}unGroup(){this.diagram.unGroup()}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275cmp=jb({type:n,selectors:[["app-container"]],viewQuery:function(i,r){if(1&i&&function fP(n,t,e){const i=Ti();i.firstCreatePass&&(dP(i,new lP(n,t,e),-1),2==(2&t)&&(i.staticViewQueries=!0)),cP(i,Se(),t)}(Nle,5),2&i){let s;Kr(s=en())&&(r.diagram=s.first)}},standalone:!0,features:[PP([]),RP],decls:16,vars:9,consts:[[3,"click"],["id","diagram","width","100%","height","580px",3,"getNodeDefaults"],["diagram",""],["id","node1",3,"offsetX","offsetY"],["id","node2",3,"offsetX","offsetY"],["id","node3",3,"offsetX","offsetY"],["id","connector","type","Orthogonal",3,"sourceID","targetID"]],template:function(i,r){1&i&&(oh(0,"label"),mg(1,"( CTRL + G ) "),ah(),oh(2,"button",0),qy("click",function(){return r.group()}),mg(3,"Group"),ah(),oh(4,"label"),mg(5,"( CTRL + Shift + U) "),ah(),oh(6,"button",0),qy("click",function(){return r.unGroup()}),mg(7,"Un Group"),ah(),oh(8,"ejs-diagram",1,2)(10,"e-nodes"),Wy(11,"e-node",3)(12,"e-node",4)(13,"e-node",5),ah(),oh(14,"e-connectors"),Wy(15,"e-connector",6),ah()()),2&i&&(Nu(8),nd("getNodeDefaults",r.getNodeDefaults),Nu(3),nd("offsetX",100)("offsetY",100),Nu(),nd("offsetX",300)("offsetY",100),Nu(),nd("offsetX",200)("offsetY",200),Nu(2),nd("sourceID",r.sourcePoint1)("targetID",r.targetPoint1))},dependencies:[Lle,Ale,v_,m_,y_,S_],encapsulation:2})}}return n})();Yd(332),function $q(n,t){return DG({rootComponent:n,...Ez(t)})}(Ole).catch(n=>console.error(n))},332:()=>{!function(Z){const se=Z.performance;function ye(zi){se&&se.mark&&se.mark(zi)}function pe(zi,ht){se&&se.measure&&se.measure(zi,ht)}ye("Zone");const be=Z.__Zone_symbol_prefix||"__zone_symbol__";function ke(zi){return be+zi}const at=!0===Z[ke("forceDuplicateZoneCheck")];if(Z.Zone){if(at||"function"!=typeof Z.Zone.__symbol__)throw new Error("Zone already loaded.");return Z.Zone}let tt=(()=>{class zi{static{this.__symbol__=ke}static assertZonePatched(){if(Z.Promise!==_o.ZoneAwarePromise)throw new Error("Zone.js has detected that ZoneAwarePromise `(window|global).Promise` has been overwritten.\nMost likely cause is that a Promise polyfill has been loaded after Zone.js (Polyfilling Promise api is not necessary when zone.js is loaded. If you must load one, do so before loading zone.js.)")}static get root(){let F=zi.current;for(;F.parent;)F=F.parent;return F}static get current(){return Ur.zone}static get currentTask(){return Do}static __load_patch(F,ae,Et=!1){if(_o.hasOwnProperty(F)){if(!Et&&at)throw Error("Already loaded patch: "+F)}else if(!Z["__Zone_disable_"+F]){const Xt="Zone:"+F;ye(Xt),_o[F]=ae(Z,zi,cn),pe(Xt,Xt)}}get parent(){return this._parent}get name(){return this._name}constructor(F,ae){this._parent=F,this._name=ae?ae.name||"unnamed":"",this._properties=ae&&ae.properties||{},this._zoneDelegate=new Lt(this,this._parent&&this._parent._zoneDelegate,ae)}get(F){const ae=this.getZoneWith(F);if(ae)return ae._properties[F]}getZoneWith(F){let ae=this;for(;ae;){if(ae._properties.hasOwnProperty(F))return ae;ae=ae._parent}return null}fork(F){if(!F)throw new Error("ZoneSpec required!");return this._zoneDelegate.fork(this,F)}wrap(F,ae){if("function"!=typeof F)throw new Error("Expecting function got: "+F);const Et=this._zoneDelegate.intercept(this,F,ae),Xt=this;return function(){return Xt.runGuarded(Et,this,arguments,ae)}}run(F,ae,Et,Xt){Ur={parent:Ur,zone:this};try{return this._zoneDelegate.invoke(this,F,ae,Et,Xt)}finally{Ur=Ur.parent}}runGuarded(F,ae=null,Et,Xt){Ur={parent:Ur,zone:this};try{try{return this._zoneDelegate.invoke(this,F,ae,Et,Xt)}catch(Vn){if(this._zoneDelegate.handleError(this,Vn))throw Vn}}finally{Ur=Ur.parent}}runTask(F,ae,Et){if(F.zone!=this)throw new Error("A task can only be run in the zone of creation! (Creation: "+(F.zone||jn).name+"; Execution: "+this.name+")");if(F.state===sr&&(F.type===rs||F.type===Pt))return;const Xt=F.state!=lt;Xt&&F._transitionTo(lt,Pi),F.runCount++;const Vn=Do;Do=F,Ur={parent:Ur,zone:this};try{F.type==Pt&&F.data&&!F.data.isPeriodic&&(F.cancelFn=void 0);try{return this._zoneDelegate.invokeTask(this,F,ae,Et)}catch(Ue){if(this._zoneDelegate.handleError(this,Ue))throw Ue}}finally{F.state!==sr&&F.state!==et&&(F.type==rs||F.data&&F.data.isPeriodic?Xt&&F._transitionTo(Pi,lt):(F.runCount=0,this._updateTaskCount(F,-1),Xt&&F._transitionTo(sr,lt,sr))),Ur=Ur.parent,Do=Vn}}scheduleTask(F){if(F.zone&&F.zone!==this){let Et=this;for(;Et;){if(Et===F.zone)throw Error(`can not reschedule task to ${this.name} which is descendants of the original zone ${F.zone.name}`);Et=Et.parent}}F._transitionTo(Zr,sr);const ae=[];F._zoneDelegates=ae,F._zone=this;try{F=this._zoneDelegate.scheduleTask(this,F)}catch(Et){throw F._transitionTo(et,Zr,sr),this._zoneDelegate.handleError(this,Et),Et}return F._zoneDelegates===ae&&this._updateTaskCount(F,1),F.state==Zr&&F._transitionTo(Pi,Zr),F}scheduleMicroTask(F,ae,Et,Xt){return this.scheduleTask(new pt(yi,F,ae,Et,Xt,void 0))}scheduleMacroTask(F,ae,Et,Xt,Vn){return this.scheduleTask(new pt(Pt,F,ae,Et,Xt,Vn))}scheduleEventTask(F,ae,Et,Xt,Vn){return this.scheduleTask(new pt(rs,F,ae,Et,Xt,Vn))}cancelTask(F){if(F.zone!=this)throw new Error("A task can only be cancelled in the zone of creation! (Creation: "+(F.zone||jn).name+"; Execution: "+this.name+")");if(F.state===Pi||F.state===lt){F._transitionTo(dr,Pi,lt);try{this._zoneDelegate.cancelTask(this,F)}catch(ae){throw F._transitionTo(et,dr),this._zoneDelegate.handleError(this,ae),ae}return this._updateTaskCount(F,-1),F._transitionTo(sr,dr),F.runCount=0,F}}_updateTaskCount(F,ae){const Et=F._zoneDelegates;-1==ae&&(F._zoneDelegates=null);for(let Xt=0;Xtzi.hasTask(F,ae),onScheduleTask:(zi,ht,F,ae)=>zi.scheduleTask(F,ae),onInvokeTask:(zi,ht,F,ae,Et,Xt)=>zi.invokeTask(F,ae,Et,Xt),onCancelTask:(zi,ht,F,ae)=>zi.cancelTask(F,ae)};class Lt{constructor(ht,F,ae){this._taskCounts={microTask:0,macroTask:0,eventTask:0},this.zone=ht,this._parentDelegate=F,this._forkZS=ae&&(ae&&ae.onFork?ae:F._forkZS),this._forkDlgt=ae&&(ae.onFork?F:F._forkDlgt),this._forkCurrZone=ae&&(ae.onFork?this.zone:F._forkCurrZone),this._interceptZS=ae&&(ae.onIntercept?ae:F._interceptZS),this._interceptDlgt=ae&&(ae.onIntercept?F:F._interceptDlgt),this._interceptCurrZone=ae&&(ae.onIntercept?this.zone:F._interceptCurrZone),this._invokeZS=ae&&(ae.onInvoke?ae:F._invokeZS),this._invokeDlgt=ae&&(ae.onInvoke?F:F._invokeDlgt),this._invokeCurrZone=ae&&(ae.onInvoke?this.zone:F._invokeCurrZone),this._handleErrorZS=ae&&(ae.onHandleError?ae:F._handleErrorZS),this._handleErrorDlgt=ae&&(ae.onHandleError?F:F._handleErrorDlgt),this._handleErrorCurrZone=ae&&(ae.onHandleError?this.zone:F._handleErrorCurrZone),this._scheduleTaskZS=ae&&(ae.onScheduleTask?ae:F._scheduleTaskZS),this._scheduleTaskDlgt=ae&&(ae.onScheduleTask?F:F._scheduleTaskDlgt),this._scheduleTaskCurrZone=ae&&(ae.onScheduleTask?this.zone:F._scheduleTaskCurrZone),this._invokeTaskZS=ae&&(ae.onInvokeTask?ae:F._invokeTaskZS),this._invokeTaskDlgt=ae&&(ae.onInvokeTask?F:F._invokeTaskDlgt),this._invokeTaskCurrZone=ae&&(ae.onInvokeTask?this.zone:F._invokeTaskCurrZone),this._cancelTaskZS=ae&&(ae.onCancelTask?ae:F._cancelTaskZS),this._cancelTaskDlgt=ae&&(ae.onCancelTask?F:F._cancelTaskDlgt),this._cancelTaskCurrZone=ae&&(ae.onCancelTask?this.zone:F._cancelTaskCurrZone),this._hasTaskZS=null,this._hasTaskDlgt=null,this._hasTaskDlgtOwner=null,this._hasTaskCurrZone=null;const Et=ae&&ae.onHasTask;(Et||F&&F._hasTaskZS)&&(this._hasTaskZS=Et?ae:At,this._hasTaskDlgt=F,this._hasTaskDlgtOwner=this,this._hasTaskCurrZone=ht,ae.onScheduleTask||(this._scheduleTaskZS=At,this._scheduleTaskDlgt=F,this._scheduleTaskCurrZone=this.zone),ae.onInvokeTask||(this._invokeTaskZS=At,this._invokeTaskDlgt=F,this._invokeTaskCurrZone=this.zone),ae.onCancelTask||(this._cancelTaskZS=At,this._cancelTaskDlgt=F,this._cancelTaskCurrZone=this.zone))}fork(ht,F){return this._forkZS?this._forkZS.onFork(this._forkDlgt,this.zone,ht,F):new tt(ht,F)}intercept(ht,F,ae){return this._interceptZS?this._interceptZS.onIntercept(this._interceptDlgt,this._interceptCurrZone,ht,F,ae):F}invoke(ht,F,ae,Et,Xt){return this._invokeZS?this._invokeZS.onInvoke(this._invokeDlgt,this._invokeCurrZone,ht,F,ae,Et,Xt):F.apply(ae,Et)}handleError(ht,F){return!this._handleErrorZS||this._handleErrorZS.onHandleError(this._handleErrorDlgt,this._handleErrorCurrZone,ht,F)}scheduleTask(ht,F){let ae=F;if(this._scheduleTaskZS)this._hasTaskZS&&ae._zoneDelegates.push(this._hasTaskDlgtOwner),ae=this._scheduleTaskZS.onScheduleTask(this._scheduleTaskDlgt,this._scheduleTaskCurrZone,ht,F),ae||(ae=F);else if(F.scheduleFn)F.scheduleFn(F);else{if(F.type!=yi)throw new Error("Task is missing scheduleFn.");Wt(F)}return ae}invokeTask(ht,F,ae,Et){return this._invokeTaskZS?this._invokeTaskZS.onInvokeTask(this._invokeTaskDlgt,this._invokeTaskCurrZone,ht,F,ae,Et):F.callback.apply(ae,Et)}cancelTask(ht,F){let ae;if(this._cancelTaskZS)ae=this._cancelTaskZS.onCancelTask(this._cancelTaskDlgt,this._cancelTaskCurrZone,ht,F);else{if(!F.cancelFn)throw Error("Task is not cancelable");ae=F.cancelFn(F)}return ae}hasTask(ht,F){try{this._hasTaskZS&&this._hasTaskZS.onHasTask(this._hasTaskDlgt,this._hasTaskCurrZone,ht,F)}catch(ae){this.handleError(ht,ae)}}_updateTaskCount(ht,F){const ae=this._taskCounts,Et=ae[ht],Xt=ae[ht]=Et+F;if(Xt<0)throw new Error("More tasks executed then were scheduled.");0!=Et&&0!=Xt||this.hasTask(this.zone,{microTask:ae.microTask>0,macroTask:ae.macroTask>0,eventTask:ae.eventTask>0,change:ht})}}class pt{constructor(ht,F,ae,Et,Xt,Vn){if(this._zone=null,this.runCount=0,this._zoneDelegates=null,this._state="notScheduled",this.type=ht,this.source=F,this.data=Et,this.scheduleFn=Xt,this.cancelFn=Vn,!ae)throw new Error("callback is not defined");this.callback=ae;const Ue=this;this.invoke=ht===rs&&Et&&Et.useG?pt.invokeTask:function(){return pt.invokeTask.call(Z,Ue,this,arguments)}}static invokeTask(ht,F,ae){ht||(ht=this),Ls++;try{return ht.runCount++,ht.zone.runTask(ht,F,ae)}finally{1==Ls&&ct(),Ls--}}get zone(){return this._zone}get state(){return this._state}cancelScheduleRequest(){this._transitionTo(sr,Zr)}_transitionTo(ht,F,ae){if(this._state!==F&&this._state!==ae)throw new Error(`${this.type} '${this.source}': can not transition to '${ht}', expecting state '${F}'${ae?" or '"+ae+"'":""}, was '${this._state}'.`);this._state=ht,ht==sr&&(this._zoneDelegates=null)}toString(){return this.data&&typeof this.data.handleId<"u"?this.data.handleId.toString():Object.prototype.toString.call(this)}toJSON(){return{type:this.type,state:this.state,source:this.source,zone:this.zone.name,runCount:this.runCount}}}const Di=ke("setTimeout"),ni=ke("Promise"),mi=ke("then");let is,cr=[],ki=!1;function Pr(zi){if(is||Z[ni]&&(is=Z[ni].resolve(0)),is){let ht=is[mi];ht||(ht=is.then),ht.call(is,zi)}else Z[Di](zi,0)}function Wt(zi){0===Ls&&0===cr.length&&Pr(ct),zi&&cr.push(zi)}function ct(){if(!ki){for(ki=!0;cr.length;){const zi=cr;cr=[];for(let ht=0;htUr,onUnhandledError:jr,microtaskDrainDone:jr,scheduleMicroTask:Wt,showUncaughtError:()=>!tt[ke("ignoreConsoleErrorUncaughtError")],patchEventTarget:()=>[],patchOnProperties:jr,patchMethod:()=>jr,bindArguments:()=>[],patchThen:()=>jr,patchMacroTask:()=>jr,patchEventPrototype:()=>jr,isIEOrEdge:()=>!1,getGlobalObjects:()=>{},ObjectDefineProperty:()=>jr,ObjectGetOwnPropertyDescriptor:()=>{},ObjectCreate:()=>{},ArraySlice:()=>[],patchClass:()=>jr,wrapWithCurrentZone:()=>jr,filterProperties:()=>[],attachOriginToPatched:()=>jr,_redefineProperty:()=>jr,patchCallbacks:()=>jr,nativeScheduleMicroTask:Pr};let Ur={parent:null,zone:new tt(null,null)},Do=null,Ls=0;function jr(){}pe("Zone","Zone"),Z.Zone=tt}(globalThis);const Wl=Object.getOwnPropertyDescriptor,Wd=Object.defineProperty,Yd=Object.getPrototypeOf,Qd=Object.create,bb=Array.prototype.slice,mm="addEventListener",$r="removeEventListener",Yl=Zone.__symbol__(mm),jh=Zone.__symbol__($r),Ts="true",Wi="false",Gd=Zone.__symbol__("");function cp(Z,se){return Zone.current.wrap(Z,se)}function ym(Z,se,ye,pe,be){return Zone.current.scheduleMacroTask(Z,se,ye,pe,be)}const Ji=Zone.__symbol__,Vh=typeof window<"u",Wh=Vh?window:void 0,gn=Vh&&Wh||globalThis,Sm="removeAttribute";function Xd(Z,se){for(let ye=Z.length-1;ye>=0;ye--)"function"==typeof Z[ye]&&(Z[ye]=cp(Z[ye],se+"_"+ye));return Z}function dp(Z){return!Z||!1!==Z.writable&&!("function"==typeof Z.get&&typeof Z.set>"u")}const up=typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope,Yh=!("nw"in gn)&&typeof gn.process<"u"&&"[object process]"==={}.toString.call(gn.process),qd=!Yh&&!up&&!(!Vh||!Wh.HTMLElement),fp=typeof gn.process<"u"&&"[object process]"==={}.toString.call(gn.process)&&!up&&!(!Vh||!Wh.HTMLElement),Ql={},Qh=function(Z){if(!(Z=Z||gn.event))return;let se=Ql[Z.type];se||(se=Ql[Z.type]=Ji("ON_PROPERTY"+Z.type));const ye=this||Z.target||gn,pe=ye[se];let be;return qd&&ye===Wh&&"error"===Z.type?(be=pe&&pe.call(this,Z.message,Z.filename,Z.lineno,Z.colno,Z.error),!0===be&&Z.preventDefault()):(be=pe&&pe.apply(this,arguments),null!=be&&!be&&Z.preventDefault()),be};function Gl(Z,se,ye){let pe=Wl(Z,se);if(!pe&&ye&&Wl(ye,se)&&(pe={enumerable:!0,configurable:!0}),!pe||!pe.configurable)return;const be=Ji("on"+se+"patched");if(Z.hasOwnProperty(be)&&Z[be])return;delete pe.writable,delete pe.value;const ke=pe.get,at=pe.set,tt=se.slice(2);let At=Ql[tt];At||(At=Ql[tt]=Ji("ON_PROPERTY"+tt)),pe.set=function(Lt){let pt=this;!pt&&Z===gn&&(pt=gn),pt&&("function"==typeof pt[At]&&pt.removeEventListener(tt,Qh),at&&at.call(pt,null),pt[At]=Lt,"function"==typeof Lt&&pt.addEventListener(tt,Qh,!1))},pe.get=function(){let Lt=this;if(!Lt&&Z===gn&&(Lt=gn),!Lt)return null;const pt=Lt[At];if(pt)return pt;if(ke){let Di=ke.call(this);if(Di)return pe.set.call(this,Di),"function"==typeof Lt[Sm]&&Lt.removeAttribute(se),Di}return null},Wd(Z,se,pe),Z[be]=!0}function pp(Z,se,ye){if(se)for(let pe=0;pefunction(at,tt){const At=ye(at,tt);return At.cbIdx>=0&&"function"==typeof tt[At.cbIdx]?ym(At.name,tt[At.cbIdx],At,be):ke.apply(at,tt)})}function Ia(Z,se){Z[Ji("OriginalDelegate")]=se}let wb=!1,Zd=!1;function Cb(){if(wb)return Zd;wb=!0;try{const Z=Wh.navigator.userAgent;(-1!==Z.indexOf("MSIE ")||-1!==Z.indexOf("Trident/")||-1!==Z.indexOf("Edge/"))&&(Zd=!0)}catch{}return Zd}Zone.__load_patch("ZoneAwarePromise",(Z,se,ye)=>{const pe=Object.getOwnPropertyDescriptor,be=Object.defineProperty,at=ye.symbol,tt=[],At=!1!==Z[at("DISABLE_WRAPPING_UNCAUGHT_PROMISE_REJECTION")],Lt=at("Promise"),pt=at("then"),Di="__creationTrace__";ye.onUnhandledError=Ue=>{if(ye.showUncaughtError()){const He=Ue&&Ue.rejection;He?console.error("Unhandled Promise rejection:",He instanceof Error?He.message:He,"; Zone:",Ue.zone.name,"; Task:",Ue.task&&Ue.task.source,"; Value:",He,He instanceof Error?He.stack:void 0):console.error(Ue)}},ye.microtaskDrainDone=()=>{for(;tt.length;){const Ue=tt.shift();try{Ue.zone.runGuarded(()=>{throw Ue.throwOriginal?Ue.rejection:Ue})}catch(He){mi(He)}}};const ni=at("unhandledPromiseRejectionHandler");function mi(Ue){ye.onUnhandledError(Ue);try{const He=se[ni];"function"==typeof He&&He.call(this,Ue)}catch{}}function cr(Ue){return Ue&&Ue.then}function ki(Ue){return Ue}function is(Ue){return F.reject(Ue)}const Pr=at("state"),Wt=at("value"),ct=at("finally"),jn=at("parentPromiseValue"),sr=at("parentPromiseState"),Zr="Promise.then",Pi=null,lt=!0,dr=!1,et=0;function yi(Ue,He){return ge=>{try{cn(Ue,He,ge)}catch(We){cn(Ue,!1,We)}}}const Pt=function(){let Ue=!1;return function(ge){return function(){Ue||(Ue=!0,ge.apply(null,arguments))}}},rs="Promise resolved with itself",_o=at("currentTaskTrace");function cn(Ue,He,ge){const We=Pt();if(Ue===ge)throw new TypeError(rs);if(Ue[Pr]===Pi){let wt=null;try{("object"==typeof ge||"function"==typeof ge)&&(wt=ge&&ge.then)}catch(Xe){return We(()=>{cn(Ue,!1,Xe)})(),Ue}if(He!==dr&&ge instanceof F&&ge.hasOwnProperty(Pr)&&ge.hasOwnProperty(Wt)&&ge[Pr]!==Pi)Do(ge),cn(Ue,ge[Pr],ge[Wt]);else if(He!==dr&&"function"==typeof wt)try{wt.call(ge,We(yi(Ue,He)),We(yi(Ue,!1)))}catch(Xe){We(()=>{cn(Ue,!1,Xe)})()}else{Ue[Pr]=He;const Xe=Ue[Wt];if(Ue[Wt]=ge,Ue[ct]===ct&&He===lt&&(Ue[Pr]=Ue[sr],Ue[Wt]=Ue[jn]),He===dr&&ge instanceof Error){const mt=se.currentTask&&se.currentTask.data&&se.currentTask.data[Di];mt&&be(ge,_o,{configurable:!0,enumerable:!1,writable:!0,value:mt})}for(let mt=0;mt{try{const dt=Ue[Wt],qt=!!ge&&ct===ge[ct];qt&&(ge[jn]=dt,ge[sr]=Xe);const li=He.run(mt,void 0,qt&&mt!==is&&mt!==ki?[]:[dt]);cn(ge,!0,li)}catch(dt){cn(ge,!1,dt)}},ge)}const zi=function(){},ht=Z.AggregateError;class F{static toString(){return"function ZoneAwarePromise() { [native code] }"}static resolve(He){return He instanceof F?He:cn(new this(null),lt,He)}static reject(He){return cn(new this(null),dr,He)}static withResolvers(){const He={};return He.promise=new F((ge,We)=>{He.resolve=ge,He.reject=We}),He}static any(He){if(!He||"function"!=typeof He[Symbol.iterator])return Promise.reject(new ht([],"All promises were rejected"));const ge=[];let We=0;try{for(let mt of He)We++,ge.push(F.resolve(mt))}catch{return Promise.reject(new ht([],"All promises were rejected"))}if(0===We)return Promise.reject(new ht([],"All promises were rejected"));let wt=!1;const Xe=[];return new F((mt,dt)=>{for(let qt=0;qt{wt||(wt=!0,mt(li))},li=>{Xe.push(li),We--,0===We&&(wt=!0,dt(new ht(Xe,"All promises were rejected")))})})}static race(He){let ge,We,wt=new this((dt,qt)=>{ge=dt,We=qt});function Xe(dt){ge(dt)}function mt(dt){We(dt)}for(let dt of He)cr(dt)||(dt=this.resolve(dt)),dt.then(Xe,mt);return wt}static all(He){return F.allWithCallback(He)}static allSettled(He){return(this&&this.prototype instanceof F?this:F).allWithCallback(He,{thenCallback:We=>({status:"fulfilled",value:We}),errorCallback:We=>({status:"rejected",reason:We})})}static allWithCallback(He,ge){let We,wt,Xe=new this((li,ur)=>{We=li,wt=ur}),mt=2,dt=0;const qt=[];for(let li of He){cr(li)||(li=this.resolve(li));const ur=dt;try{li.then(ir=>{qt[ur]=ge?ge.thenCallback(ir):ir,mt--,0===mt&&We(qt)},ir=>{ge?(qt[ur]=ge.errorCallback(ir),mt--,0===mt&&We(qt)):wt(ir)})}catch(ir){wt(ir)}mt++,dt++}return mt-=2,0===mt&&We(qt),Xe}constructor(He){const ge=this;if(!(ge instanceof F))throw new Error("Must be an instanceof Promise.");ge[Pr]=Pi,ge[Wt]=[];try{const We=Pt();He&&He(We(yi(ge,lt)),We(yi(ge,dr)))}catch(We){cn(ge,!1,We)}}get[Symbol.toStringTag](){return"Promise"}get[Symbol.species](){return F}then(He,ge){let We=this.constructor?.[Symbol.species];(!We||"function"!=typeof We)&&(We=this.constructor||F);const wt=new We(zi),Xe=se.current;return this[Pr]==Pi?this[Wt].push(Xe,wt,He,ge):Ls(this,Xe,wt,He,ge),wt}catch(He){return this.then(null,He)}finally(He){let ge=this.constructor?.[Symbol.species];(!ge||"function"!=typeof ge)&&(ge=F);const We=new ge(zi);We[ct]=ct;const wt=se.current;return this[Pr]==Pi?this[Wt].push(wt,We,He,He):Ls(this,wt,We,He,He),We}}F.resolve=F.resolve,F.reject=F.reject,F.race=F.race,F.all=F.all;const ae=Z[Lt]=Z.Promise;Z.Promise=F;const Et=at("thenPatched");function Xt(Ue){const He=Ue.prototype,ge=pe(He,"then");if(ge&&(!1===ge.writable||!ge.configurable))return;const We=He.then;He[pt]=We,Ue.prototype.then=function(wt,Xe){return new F((dt,qt)=>{We.call(this,dt,qt)}).then(wt,Xe)},Ue[Et]=!0}return ye.patchThen=Xt,ae&&(Xt(ae),tl(Z,"fetch",Ue=>function Vn(Ue){return function(He,ge){let We=Ue.apply(He,ge);if(We instanceof F)return We;let wt=We.constructor;return wt[Et]||Xt(wt),We}}(Ue))),Promise[se.__symbol__("uncaughtPromiseErrors")]=tt,F}),Zone.__load_patch("toString",Z=>{const se=Function.prototype.toString,ye=Ji("OriginalDelegate"),pe=Ji("Promise"),be=Ji("Error"),ke=function(){if("function"==typeof this){const Lt=this[ye];if(Lt)return"function"==typeof Lt?se.call(Lt):Object.prototype.toString.call(Lt);if(this===Promise){const pt=Z[pe];if(pt)return se.call(pt)}if(this===Error){const pt=Z[be];if(pt)return se.call(pt)}}return se.call(this)};ke[ye]=se,Function.prototype.toString=ke;const at=Object.prototype.toString;Object.prototype.toString=function(){return"function"==typeof Promise&&this instanceof Promise?"[object Promise]":at.call(this)}});let il=!1;if(typeof window<"u")try{const Z=Object.defineProperty({},"passive",{get:function(){il=!0}});window.addEventListener("test",Z,Z),window.removeEventListener("test",Z,Z)}catch{il=!1}const zT={useG:!0},Co={},Eb={},Mm=new RegExp("^"+Gd+"(\\w+)(true|false)$"),Db=Ji("propagationStopped");function wm(Z,se){const ye=(se?se(Z):Z)+Wi,pe=(se?se(Z):Z)+Ts,be=Gd+ye,ke=Gd+pe;Co[Z]={},Co[Z][Wi]=be,Co[Z][Ts]=ke}function xb(Z,se,ye,pe){const be=pe&&pe.add||mm,ke=pe&&pe.rm||$r,at=pe&&pe.listeners||"eventListeners",tt=pe&&pe.rmAll||"removeAllListeners",At=Ji(be),Lt="."+be+":",pt="prependListener",Di="."+pt+":",ni=function(Wt,ct,jn){if(Wt.isRemoved)return;const sr=Wt.callback;let Zr;"object"==typeof sr&&sr.handleEvent&&(Wt.callback=lt=>sr.handleEvent(lt),Wt.originalDelegate=sr);try{Wt.invoke(Wt,ct,[jn])}catch(lt){Zr=lt}const Pi=Wt.options;return Pi&&"object"==typeof Pi&&Pi.once&&ct[ke].call(ct,jn.type,Wt.originalDelegate?Wt.originalDelegate:Wt.callback,Pi),Zr};function mi(Wt,ct,jn){if(!(ct=ct||Z.event))return;const sr=Wt||ct.target||Z,Zr=sr[Co[ct.type][jn?Ts:Wi]];if(Zr){const Pi=[];if(1===Zr.length){const lt=ni(Zr[0],sr,ct);lt&&Pi.push(lt)}else{const lt=Zr.slice();for(let dr=0;dr{throw dr})}}}const cr=function(Wt){return mi(this,Wt,!1)},ki=function(Wt){return mi(this,Wt,!0)};function is(Wt,ct){if(!Wt)return!1;let jn=!0;ct&&void 0!==ct.useG&&(jn=ct.useG);const sr=ct&&ct.vh;let Zr=!0;ct&&void 0!==ct.chkDup&&(Zr=ct.chkDup);let Pi=!1;ct&&void 0!==ct.rt&&(Pi=ct.rt);let lt=Wt;for(;lt&&!lt.hasOwnProperty(be);)lt=Yd(lt);if(!lt&&Wt[be]&&(lt=Wt),!lt||lt[At])return!1;const dr=ct&&ct.eventNameToString,et={},yi=lt[At]=lt[be],Pt=lt[Ji(ke)]=lt[ke],rs=lt[Ji(at)]=lt[at],_o=lt[Ji(tt)]=lt[tt];let cn;ct&&ct.prepend&&(cn=lt[Ji(ct.prepend)]=lt[ct.prepend]);const F=jn?function(ge){if(!et.isExisting)return yi.call(et.target,et.eventName,et.capture?ki:cr,et.options)}:function(ge){return yi.call(et.target,et.eventName,ge.invoke,et.options)},ae=jn?function(ge){if(!ge.isRemoved){const We=Co[ge.eventName];let wt;We&&(wt=We[ge.capture?Ts:Wi]);const Xe=wt&&ge.target[wt];if(Xe)for(let mt=0;mt{Vo.zone.cancelTask(Vo)},{once:!0})),et.target=null,Uc&&(Uc.taskData=null),Kd&&(Tn.once=!0),!il&&"boolean"==typeof Vo.options||(Vo.options=Tn),Vo.target=qt,Vo.capture=Zl,Vo.eventName=li,ir&&(Vo.originalDelegate=ur),dt?jo.unshift(Vo):jo.push(Vo),mt?qt:void 0}};return lt[be]=He(yi,Lt,F,ae,Pi),cn&&(lt[pt]=He(cn,Di,function(ge){return cn.call(et.target,et.eventName,ge.invoke,et.options)},ae,Pi,!0)),lt[ke]=function(){const ge=this||Z;let We=arguments[0];ct&&ct.transferEventName&&(We=ct.transferEventName(We));const wt=arguments[2],Xe=!!wt&&("boolean"==typeof wt||wt.capture),mt=arguments[1];if(!mt)return Pt.apply(this,arguments);if(sr&&!sr(Pt,mt,ge,arguments))return;const dt=Co[We];let qt;dt&&(qt=dt[Xe?Ts:Wi]);const li=qt&&ge[qt];if(li)for(let ur=0;urfunction(be,ke){be[Db]=!0,pe&&pe.apply(be,ke)})}function Ab(Z,se,ye,pe,be){const ke=Zone.__symbol__(pe);if(se[ke])return;const at=se[ke]=se[pe];se[pe]=function(tt,At,Lt){return At&&At.prototype&&be.forEach(function(pt){const Di=`${ye}.${pe}::`+pt,ni=At.prototype;try{if(ni.hasOwnProperty(pt)){const mi=Z.ObjectGetOwnPropertyDescriptor(ni,pt);mi&&mi.value?(mi.value=Z.wrapWithCurrentZone(mi.value,Di),Z._redefineProperty(At.prototype,pt,mi)):ni[pt]&&(ni[pt]=Z.wrapWithCurrentZone(ni[pt],Di))}else ni[pt]&&(ni[pt]=Z.wrapWithCurrentZone(ni[pt],Di))}catch{}}),at.call(se,tt,At,Lt)},Z.attachOriginToPatched(se[pe],at)}function Lb(Z,se,ye){if(!ye||0===ye.length)return se;const pe=ye.filter(ke=>ke.target===Z);if(!pe||0===pe.length)return se;const be=pe[0].ignoreProperties;return se.filter(ke=>-1===be.indexOf(ke))}function Eo(Z,se,ye,pe){Z&&pp(Z,Lb(Z,se,ye),pe)}function Jd(Z){return Object.getOwnPropertyNames(Z).filter(se=>se.startsWith("on")&&se.length>2).map(se=>se.substring(2))}Zone.__load_patch("util",(Z,se,ye)=>{const pe=Jd(Z);ye.patchOnProperties=pp,ye.patchMethod=tl,ye.bindArguments=Xd,ye.patchMacroTask=Mb;const be=se.__symbol__("BLACK_LISTED_EVENTS"),ke=se.__symbol__("UNPATCHED_EVENTS");Z[ke]&&(Z[be]=Z[ke]),Z[be]&&(se[be]=se[ke]=Z[be]),ye.patchEventPrototype=Cm,ye.patchEventTarget=xb,ye.isIEOrEdge=Cb,ye.ObjectDefineProperty=Wd,ye.ObjectGetOwnPropertyDescriptor=Wl,ye.ObjectCreate=Qd,ye.ArraySlice=bb,ye.patchClass=$d,ye.wrapWithCurrentZone=cp,ye.filterProperties=Lb,ye.attachOriginToPatched=Ia,ye._redefineProperty=Object.defineProperty,ye.patchCallbacks=Ab,ye.getGlobalObjects=()=>({globalSources:Eb,zoneSymbolEventNames:Co,eventNames:pe,isBrowser:qd,isMix:fp,isNode:Yh,TRUE_STR:Ts,FALSE_STR:Wi,ZONE_SYMBOL_PREFIX:Gd,ADD_EVENT_LISTENER_STR:mm,REMOVE_EVENT_LISTENER_STR:$r})});const As=Ji("zoneTask");function Xl(Z,se,ye,pe){let be=null,ke=null;ye+=pe;const at={};function tt(Lt){const pt=Lt.data;return pt.args[0]=function(){return Lt.invoke.apply(this,arguments)},pt.handleId=be.apply(Z,pt.args),Lt}function At(Lt){return ke.call(Z,Lt.data.handleId)}be=tl(Z,se+=pe,Lt=>function(pt,Di){if("function"==typeof Di[0]){const ni={isPeriodic:"Interval"===pe,delay:"Timeout"===pe||"Interval"===pe?Di[1]||0:void 0,args:Di},mi=Di[0];Di[0]=function(){try{return mi.apply(this,arguments)}finally{ni.isPeriodic||("number"==typeof ni.handleId?delete at[ni.handleId]:ni.handleId&&(ni.handleId[As]=null))}};const cr=ym(se,Di[0],ni,tt,At);if(!cr)return cr;const ki=cr.data.handleId;return"number"==typeof ki?at[ki]=cr:ki&&(ki[As]=cr),ki&&ki.ref&&ki.unref&&"function"==typeof ki.ref&&"function"==typeof ki.unref&&(cr.ref=ki.ref.bind(ki),cr.unref=ki.unref.bind(ki)),"number"==typeof ki||ki?ki:cr}return Lt.apply(Z,Di)}),ke=tl(Z,ye,Lt=>function(pt,Di){const ni=Di[0];let mi;"number"==typeof ni?mi=at[ni]:(mi=ni&&ni[As],mi||(mi=ni)),mi&&"string"==typeof mi.type?"notScheduled"!==mi.state&&(mi.cancelFn&&mi.data.isPeriodic||0===mi.runCount)&&("number"==typeof ni?delete at[ni]:ni&&(ni[As]=null),mi.zone.cancelTask(mi)):Lt.apply(Z,Di)})}Zone.__load_patch("legacy",Z=>{const se=Z[Zone.__symbol__("legacyPatch")];se&&se()}),Zone.__load_patch("timers",Z=>{const ye="clear";Xl(Z,"set",ye,"Timeout"),Xl(Z,"set",ye,"Interval"),Xl(Z,"set",ye,"Immediate")}),Zone.__load_patch("requestAnimationFrame",Z=>{Xl(Z,"request","cancel","AnimationFrame"),Xl(Z,"mozRequest","mozCancel","AnimationFrame"),Xl(Z,"webkitRequest","webkitCancel","AnimationFrame")}),Zone.__load_patch("blocking",(Z,se)=>{const ye=["alert","prompt","confirm"];for(let pe=0;pefunction(At,Lt){return se.current.run(ke,Z,Lt,tt)})}),Zone.__load_patch("EventTarget",(Z,se,ye)=>{(function ql(Z,se){se.patchEventPrototype(Z,se)})(Z,ye),function Dm(Z,se){if(Zone[se.symbol("patchEventTarget")])return;const{eventNames:ye,zoneSymbolEventNames:pe,TRUE_STR:be,FALSE_STR:ke,ZONE_SYMBOL_PREFIX:at}=se.getGlobalObjects();for(let At=0;At{$d("MutationObserver"),$d("WebKitMutationObserver")}),Zone.__load_patch("IntersectionObserver",(Z,se,ye)=>{$d("IntersectionObserver")}),Zone.__load_patch("FileReader",(Z,se,ye)=>{$d("FileReader")}),Zone.__load_patch("on_property",(Z,se,ye)=>{!function gp(Z,se){if(Yh&&!fp||Zone[Z.symbol("patchEvents")])return;const ye=se.__Zone_ignore_on_properties;let pe=[];if(qd){const be=window;pe=pe.concat(["Document","SVGElement","Element","HTMLElement","HTMLBodyElement","HTMLMediaElement","HTMLFrameSetElement","HTMLFrameElement","HTMLIFrameElement","HTMLMarqueeElement","Worker"]);const ke=function bm(){try{const Z=Wh.navigator.userAgent;if(-1!==Z.indexOf("MSIE ")||-1!==Z.indexOf("Trident/"))return!0}catch{}return!1}()?[{target:be,ignoreProperties:["error"]}]:[];Eo(be,Jd(be),ye&&ye.concat(ke),Yd(be))}pe=pe.concat(["XMLHttpRequest","XMLHttpRequestEventTarget","IDBIndex","IDBRequest","IDBOpenDBRequest","IDBDatabase","IDBTransaction","IDBCursor","WebSocket"]);for(let be=0;be{!function Em(Z,se){const{isBrowser:ye,isMix:pe}=se.getGlobalObjects();(ye||pe)&&Z.customElements&&"customElements"in Z&&se.patchCallbacks(se,Z.customElements,"customElements","define",["connectedCallback","disconnectedCallback","adoptedCallback","attributeChangedCallback"])}(Z,ye)}),Zone.__load_patch("XHR",(Z,se)=>{!function At(Lt){const pt=Lt.XMLHttpRequest;if(!pt)return;const Di=pt.prototype;let mi=Di[Yl],cr=Di[jh];if(!mi){const et=Lt.XMLHttpRequestEventTarget;if(et){const yi=et.prototype;mi=yi[Yl],cr=yi[jh]}}const ki="readystatechange",is="scheduled";function Pr(et){const yi=et.data,Pt=yi.target;Pt[ke]=!1,Pt[tt]=!1;const rs=Pt[be];mi||(mi=Pt[Yl],cr=Pt[jh]),rs&&cr.call(Pt,ki,rs);const _o=Pt[be]=()=>{if(Pt.readyState===Pt.DONE)if(!yi.aborted&&Pt[ke]&&et.state===is){const Ur=Pt[se.__symbol__("loadfalse")];if(0!==Pt.status&&Ur&&Ur.length>0){const Do=et.invoke;et.invoke=function(){const Ls=Pt[se.__symbol__("loadfalse")];for(let jr=0;jrfunction(et,yi){return et[pe]=0==yi[2],et[at]=yi[1],jn.apply(et,yi)}),Zr=Ji("fetchTaskAborting"),Pi=Ji("fetchTaskScheduling"),lt=tl(Di,"send",()=>function(et,yi){if(!0===se.current[Pi]||et[pe])return lt.apply(et,yi);{const Pt={target:et,url:et[at],isPeriodic:!1,args:yi,aborted:!1},rs=ym("XMLHttpRequest.send",Wt,Pt,Pr,ct);et&&!0===et[tt]&&!Pt.aborted&&rs.state===is&&rs.invoke()}}),dr=tl(Di,"abort",()=>function(et,yi){const Pt=function ni(et){return et[ye]}(et);if(Pt&&"string"==typeof Pt.type){if(null==Pt.cancelFn||Pt.data&&Pt.data.aborted)return;Pt.zone.cancelTask(Pt)}else if(!0===se.current[Zr])return dr.apply(et,yi)})}(Z);const ye=Ji("xhrTask"),pe=Ji("xhrSync"),be=Ji("xhrListener"),ke=Ji("xhrScheduled"),at=Ji("xhrURL"),tt=Ji("xhrErrorBeforeScheduled")}),Zone.__load_patch("geolocation",Z=>{Z.navigator&&Z.navigator.geolocation&&function Im(Z,se){const ye=Z.constructor.name;for(let pe=0;pe{const At=function(){return tt.apply(this,Xd(arguments,ye+"."+be))};return Ia(At,tt),At})(ke)}}}(Z.navigator.geolocation,["getCurrentPosition","watchPosition"])}),Zone.__load_patch("PromiseRejectionEvent",(Z,se)=>{function ye(pe){return function(be){Tb(Z,pe).forEach(at=>{const tt=Z.PromiseRejectionEvent;if(tt){const At=new tt(pe,{promise:be.promise,reason:be.rejection});at.invoke(At)}})}}Z.PromiseRejectionEvent&&(se[Ji("unhandledPromiseRejectionHandler")]=ye("unhandledrejection"),se[Ji("rejectionHandledHandler")]=ye("rejectionhandled"))}),Zone.__load_patch("queueMicrotask",(Z,se,ye)=>{!function vp(Z,se){se.patchMethod(Z,"queueMicrotask",ye=>function(pe,be){Zone.current.scheduleMicroTask("queueMicrotask",be[0])})}(Z,ye)})}},Wl=>{Wl(Wl.s=51)}]); \ No newline at end of file diff --git a/ej2-angular/samples/diagram/commands/grouping-cs1/main.f636748cc9bad9cc.js b/ej2-angular/samples/diagram/commands/grouping-cs1/main.f636748cc9bad9cc.js deleted file mode 100644 index 46e2718c43..0000000000 --- a/ej2-angular/samples/diagram/commands/grouping-cs1/main.f636748cc9bad9cc.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";(self.webpackChunksyncfusion_component=self.webpackChunksyncfusion_component||[]).push([[179],{51:(_l,Vd,Wd)=>{let $r=null,Uh=1;const Ts=Symbol("SIGNAL");function Wi(n){const t=$r;return $r=n,t}function gn(n){if((!Yh(n)||n.dirty)&&(n.dirty||n.lastCleanEpoch!==Uh)){if(!n.producerMustRecompute(n)&&!Wh(n))return n.dirty=!1,void(n.lastCleanEpoch=Uh);n.producerRecomputeValue(n),n.dirty=!1,n.lastCleanEpoch=Uh}}function Wh(n){Vl(n);for(let t=0;t0}function Vl(n){n.producerNode??=[],n.producerIndexOfThis??=[],n.producerLastReadVersion??=[]}let $d=null;function Eo(n){return"function"==typeof n}function Zd(n){const e=n(i=>{Error.call(i),i.stack=(new Error).stack});return e.prototype=Object.create(Error.prototype),e.prototype.constructor=e,e}const gf=Zd(n=>function(e){n(this),this.message=e?`${e.length} errors occurred during unsubscription:\n${e.map((i,r)=>`${r+1}) ${i.toString()}`).join("\n ")}`:"",this.name="UnsubscriptionError",this.errors=e});function vf(n,t){if(n){const e=n.indexOf(t);0<=e&&n.splice(e,1)}}class As{constructor(t){this.initialTeardown=t,this.closed=!1,this._parentage=null,this._finalizers=null}unsubscribe(){let t;if(!this.closed){this.closed=!0;const{_parentage:e}=this;if(e)if(this._parentage=null,Array.isArray(e))for(const s of e)s.remove(this);else e.remove(this);const{initialTeardown:i}=this;if(Eo(i))try{i()}catch(s){t=s instanceof gf?s.errors:[s]}const{_finalizers:r}=this;if(r){this._finalizers=null;for(const s of r)try{Em(s)}catch(o){t=t??[],o instanceof gf?t=[...t,...o.errors]:t.push(o)}}if(t)throw new gf(t)}}add(t){var e;if(t&&t!==this)if(this.closed)Em(t);else{if(t instanceof As){if(t.closed||t._hasParent(this))return;t._addParent(this)}(this._finalizers=null!==(e=this._finalizers)&&void 0!==e?e:[]).push(t)}}_hasParent(t){const{_parentage:e}=this;return e===t||Array.isArray(e)&&e.includes(t)}_addParent(t){const{_parentage:e}=this;this._parentage=Array.isArray(e)?(e.push(t),e):e?[e,t]:t}_removeParent(t){const{_parentage:e}=this;e===t?this._parentage=null:Array.isArray(e)&&vf(e,t)}remove(t){const{_finalizers:e}=this;e&&vf(e,t),t instanceof As&&t._removeParent(this)}}As.EMPTY=(()=>{const n=new As;return n.closed=!0,n})();const Wl=As.EMPTY;function Cm(n){return n instanceof As||n&&"closed"in n&&Eo(n.remove)&&Eo(n.add)&&Eo(n.unsubscribe)}function Em(n){Eo(n)?n():n.unsubscribe()}const Yl={onUnhandledError:null,onStoppedNotification:null,Promise:void 0,useDeprecatedSynchronousErrorHandling:!1,useDeprecatedNextContext:!1},Z={setTimeout(n,t,...e){const{delegate:i}=Z;return i?.setTimeout?i.setTimeout(n,t,...e):setTimeout(n,t,...e)},clearTimeout(n){const{delegate:t}=Z;return(t?.clearTimeout||clearTimeout)(n)},delegate:void 0};function ye(){}const fe=at("C",void 0,void 0);function at(n,t,e){return{kind:n,value:t,error:e}}let tt=null;function At(n){if(Yl.useDeprecatedSynchronousErrorHandling){const t=!tt;if(t&&(tt={errorThrown:!1,error:null}),n(),t){const{errorThrown:e,error:i}=tt;if(tt=null,e)throw i}}else n()}class ft extends As{constructor(t){super(),this.isStopped=!1,t?(this.destination=t,Cm(t)&&t.add(this)):this.destination=Wt}static create(t,e,i){return new cr(t,e,i)}next(t){this.isStopped?kr(function ke(n){return at("N",n,void 0)}(t),this):this._next(t)}error(t){this.isStopped?kr(function be(n){return at("E",void 0,n)}(t),this):(this.isStopped=!0,this._error(t))}complete(){this.isStopped?kr(fe,this):(this.isStopped=!0,this._complete())}unsubscribe(){this.closed||(this.isStopped=!0,super.unsubscribe(),this.destination=null)}_next(t){this.destination.next(t)}_error(t){try{this.destination.error(t)}finally{this.unsubscribe()}}_complete(){try{this.destination.complete()}finally{this.unsubscribe()}}}const Ei=Function.prototype.bind;function ti(n,t){return Ei.call(n,t)}class gi{constructor(t){this.partialObserver=t}next(t){const{partialObserver:e}=this;if(e.next)try{e.next(t)}catch(i){Oi(i)}}error(t){const{partialObserver:e}=this;if(e.error)try{e.error(t)}catch(i){Oi(i)}else Oi(t)}complete(){const{partialObserver:t}=this;if(t.complete)try{t.complete()}catch(e){Oi(e)}}}class cr extends ft{constructor(t,e,i){let r;if(super(),Eo(t)||!t)r={next:t??void 0,error:e??void 0,complete:i??void 0};else{let s;this&&Yl.useDeprecatedNextContext?(s=Object.create(t),s.unsubscribe=()=>this.unsubscribe(),r={next:t.next&&ti(t.next,s),error:t.error&&ti(t.error,s),complete:t.complete&&ti(t.complete,s)}):r=t}this.destination=new gi(r)}}function Oi(n){Yl.useDeprecatedSynchronousErrorHandling?function Lt(n){Yl.useDeprecatedSynchronousErrorHandling&&tt&&(tt.errorThrown=!0,tt.error=n)}(n):function se(n){Z.setTimeout(()=>{const{onUnhandledError:t}=Yl;if(!t)throw n;t(n)})}(n)}function kr(n,t){const{onStoppedNotification:e}=Yl;e&&Z.setTimeout(()=>e(n,t))}const Wt={closed:!0,next:ye,error:function es(n){throw n},complete:ye},ct="function"==typeof Symbol&&Symbol.observable||"@@observable";function _n(n){return n}let ki=(()=>{class n{constructor(e){e&&(this._subscribe=e)}lift(e){const i=new n;return i.source=this,i.operator=e,i}subscribe(e,i,r){const s=function et(n){return n&&n instanceof ft||function dr(n){return n&&Eo(n.next)&&Eo(n.error)&&Eo(n.complete)}(n)&&Cm(n)}(e)?e:new cr(e,i,r);return At(()=>{const{operator:o,source:a}=this;s.add(o?o.call(s,a):a?this._subscribe(s):this._trySubscribe(s))}),s}_trySubscribe(e){try{return this._subscribe(e)}catch(i){e.error(i)}}forEach(e,i){return new(i=lt(i))((r,s)=>{const o=new cr({next:a=>{try{e(a)}catch(l){s(l),o.unsubscribe()}},error:s,complete:r});this.subscribe(o)})}_subscribe(e){var i;return null===(i=this.source)||void 0===i?void 0:i.subscribe(e)}[ct](){return this}pipe(...e){return function Zr(n){return 0===n.length?_n:1===n.length?n[0]:function(e){return n.reduce((i,r)=>r(i),e)}}(e)(this)}toPromise(e){return new(e=lt(e))((i,r)=>{let s;this.subscribe(o=>s=o,o=>r(o),()=>i(s))})}}return n.create=t=>new n(t),n})();function lt(n){var t;return null!==(t=n??Yl.Promise)&&void 0!==t?t:Promise}const vi=Zd(n=>function(){n(this),this.name="ObjectUnsubscribedError",this.message="object unsubscribed"});let Pt=(()=>{class n extends ki{constructor(){super(),this.closed=!1,this.currentObservers=null,this.observers=[],this.isStopped=!1,this.hasError=!1,this.thrownError=null}lift(e){const i=new ts(this,this);return i.operator=e,i}_throwIfClosed(){if(this.closed)throw new vi}next(e){At(()=>{if(this._throwIfClosed(),!this.isStopped){this.currentObservers||(this.currentObservers=Array.from(this.observers));for(const i of this.currentObservers)i.next(e)}})}error(e){At(()=>{if(this._throwIfClosed(),!this.isStopped){this.hasError=this.isStopped=!0,this.thrownError=e;const{observers:i}=this;for(;i.length;)i.shift().error(e)}})}complete(){At(()=>{if(this._throwIfClosed(),!this.isStopped){this.isStopped=!0;const{observers:e}=this;for(;e.length;)e.shift().complete()}})}unsubscribe(){this.isStopped=this.closed=!0,this.observers=this.currentObservers=null}get observed(){var e;return(null===(e=this.observers)||void 0===e?void 0:e.length)>0}_trySubscribe(e){return this._throwIfClosed(),super._trySubscribe(e)}_subscribe(e){return this._throwIfClosed(),this._checkFinalizedStatuses(e),this._innerSubscribe(e)}_innerSubscribe(e){const{hasError:i,isStopped:r,observers:s}=this;return i||r?Wl:(this.currentObservers=null,s.push(e),new As(()=>{this.currentObservers=null,vf(s,e)}))}_checkFinalizedStatuses(e){const{hasError:i,thrownError:r,isStopped:s}=this;i?e.error(r):s&&e.complete()}asObservable(){const e=new ki;return e.source=this,e}}return n.create=(t,e)=>new ts(t,e),n})();class ts extends Pt{constructor(t,e){super(),this.destination=t,this.source=e}next(t){var e,i;null===(i=null===(e=this.destination)||void 0===e?void 0:e.next)||void 0===i||i.call(e,t)}error(t){var e,i;null===(i=null===(e=this.destination)||void 0===e?void 0:e.error)||void 0===i||i.call(e,t)}complete(){var t,e;null===(e=null===(t=this.destination)||void 0===t?void 0:t.complete)||void 0===e||e.call(t)}_subscribe(t){var e,i;return null!==(i=null===(e=this.source)||void 0===e?void 0:e.subscribe(t))&&void 0!==i?i:Wl}}class _o extends Pt{constructor(t){super(),this._value=t}get value(){return this.getValue()}_subscribe(t){const e=super._subscribe(t);return!e.closed&&t.next(this._value),e}getValue(){const{hasError:t,thrownError:e,_value:i}=this;if(t)throw e;return this._throwIfClosed(),i}next(t){super.next(this._value=t)}}class Ls extends ft{constructor(t,e,i,r,s,o){super(t),this.onFinalize=s,this.shouldUnsubscribe=o,this._next=e?function(a){try{e(a)}catch(l){t.error(l)}}:super._next,this._error=r?function(a){try{r(a)}catch(l){t.error(l)}finally{this.unsubscribe()}}:super._error,this._complete=i?function(){try{i()}catch(a){t.error(a)}finally{this.unsubscribe()}}:super._complete}unsubscribe(){var t;if(!this.shouldUnsubscribe||this.shouldUnsubscribe()){const{closed:e}=this;super.unsubscribe(),!e&&(null===(t=this.onFinalize)||void 0===t||t.call(this))}}}function jr(n,t){return function Ur(n){return t=>{if(function cn(n){return Eo(n?.lift)}(t))return t.lift(function(e){try{return n(e,this)}catch(i){this.error(i)}});throw new TypeError("Unable to lift unknown Observable type")}}((e,i)=>{let r=0;e.subscribe(function Do(n,t,e,i,r){return new Ls(n,t,e,i,r)}(i,s=>{i.next(n.call(t,s,r++))}))})}class F extends Error{constructor(t,e){super(function ae(n,t){return`NG0${Math.abs(n)}${t?": "+t:""}`}(t,e)),this.code=t}}function Xe(n){for(let t in n)if(n[t]===Xe)return t;throw Error("Could not find renamed property on target object.")}function mt(n,t){for(const e in t)t.hasOwnProperty(e)&&!n.hasOwnProperty(e)&&(n[e]=t[e])}function dt(n){if("string"==typeof n)return n;if(Array.isArray(n))return"["+n.map(dt).join(", ")+"]";if(null==n)return""+n;if(n.overriddenName)return`${n.overriddenName}`;if(n.name)return`${n.name}`;const t=n.toString();if(null==t)return""+t;const e=t.indexOf("\n");return-1===e?t:t.substring(0,e)}function qt(n,t){return null==n||""===n?null===t?"":t:null==t||""===t?n:n+" "+t}const ur=Xe({__forward_ref__:Xe});function ir(n){return n.__forward_ref__=ir,n.toString=function(){return dt(this())},n}function vt(n){return function Dn(n){return"function"==typeof n&&n.hasOwnProperty(ur)&&n.__forward_ref__===ir}(n)?n():n}function Ql(n){return n&&!!n.\u0275providers}const Gl=Xe({\u0275cmp:Xe}),Jd=Xe({\u0275dir:Xe}),mf=Xe({\u0275pipe:Xe}),Uo=Xe({\u0275fac:Xe}),jo=Xe({__NG_ELEMENT_ID__:Xe}),yf=Xe({__NG_ENV_ID__:Xe});function zi(n){return"function"==typeof n?n.name||n.toString():"object"==typeof n&&null!=n&&"function"==typeof n.type?n.type.name||n.type.toString():function Nt(n){return"string"==typeof n?n:null==n?"":String(n)}(n)}function Nb(n,t){throw new F(-201,!1)}function ro(n,t){null==n&&function zt(n,t,e,i){throw new Error(`ASSERTION ERROR: ${n}`+(null==i?"":` [Expected=> ${e} ${i} ${t} <=Actual]`))}(t,n,null,"!=")}function Yi(n){return{token:n.token,providedIn:n.providedIn||null,factory:n.factory,value:void 0}}function Sf(n){return{providers:n.providers||[],imports:n.imports||[]}}function Dm(n){return RT(n,Tm)||RT(n,HT)}function RT(n,t){return n.hasOwnProperty(t)?n[t]:null}function xm(n){return n&&(n.hasOwnProperty(Ob)||n.hasOwnProperty(x_))?n[Ob]:null}const Tm=Xe({\u0275prov:Xe}),Ob=Xe({\u0275inj:Xe}),HT=Xe({ngInjectableDef:Xe}),x_=Xe({ngInjectorDef:Xe});var Di=function(n){return n[n.Default=0]="Default",n[n.Host=1]="Host",n[n.Self=2]="Self",n[n.SkipSelf=4]="SkipSelf",n[n.Optional=8]="Optional",n}(Di||{});let kb;function no(n){const t=kb;return kb=n,t}function FT(n,t,e){const i=Dm(n);return i&&"root"==i.providedIn?void 0===i.value?i.value=i.factory():i.value:e&Di.Optional?null:void 0!==t?t:void Nb()}const rr=globalThis;class Ht{constructor(t,e){this._desc=t,this.ngMetadataName="InjectionToken",this.\u0275prov=void 0,"number"==typeof e?this.__NG_ELEMENT_ID__=e:void 0!==e&&(this.\u0275prov=Yi({token:this,providedIn:e.providedIn||"root",factory:e.factory}))}get multi(){return this}toString(){return`InjectionToken ${this._desc}`}}const If={},Bb="__NG_DI_FLAG__",Am="ngTempTokenPath",L_=/\n/gm,UT="__source";let eu;function Xh(n){const t=eu;return eu=n,t}function k_(n,t=Di.Default){if(void 0===eu)throw new F(-203,!1);return null===eu?FT(n,void 0,t):eu.get(n,t&Di.Optional?null:void 0,t)}function Fi(n,t=Di.Default){return(function BT(){return kb}()||k_)(vt(n),t)}function Ri(n,t=Di.Default){return Fi(n,Lm(t))}function Lm(n){return typeof n>"u"||"number"==typeof n?n:0|(n.optional&&8)|(n.host&&1)|(n.self&&2)|(n.skipSelf&&4)}function Fb(n){const t=[];for(let e=0;et){o=s-1;break}}}for(;ss?"":r[d+1].toLowerCase();const p=8&i?u:null;if(p&&-1!==VT(p,h,0)||2&i&&h!==u){if(ba(i))return!1;o=!0}}}}else{if(!o&&!ba(i)&&!ba(l))return!1;if(o&&ba(l))continue;o=!1,i=l|1&i}}return ba(i)||o}function ba(n){return 0==(1&n)}function __(n,t,e,i){if(null===t)return-1;let r=0;if(i||!e){let s=!1;for(;r-1)for(e++;e0?'="'+a+'"':"")+"]"}else 8&i?r+="."+o:4&i&&(r+=" "+o);else""!==r&&!ba(o)&&(t+=$T(s,r),r=""),i=o,s=s||!ba(i);e++}return""!==r&&(t+=$T(s,r)),t}function Ub(n){return Xl(()=>{const t=JT(n),e={...t,decls:n.decls,vars:n.vars,template:n.template,consts:n.consts||null,ngContentSelectors:n.ngContentSelectors,onPush:n.changeDetection===Nm.OnPush,directiveDefs:null,pipeDefs:null,dependencies:t.standalone&&n.dependencies||null,getStandaloneInjector:null,signals:n.signals??!1,data:n.data||{},encapsulation:n.encapsulation||Ia.Emulated,styles:n.styles||Qi,_:null,schemas:n.schemas||null,tView:null,id:""};KT(e);const i=n.dependencies;return e.directiveDefs=km(i,!1),e.pipeDefs=km(i,!0),e.id=function Z_(n){let t=0;const e=[n.selectors,n.ngContentSelectors,n.hostVars,n.hostAttrs,n.consts,n.vars,n.decls,n.encapsulation,n.standalone,n.signals,n.exportAs,JSON.stringify(n.inputs),JSON.stringify(n.outputs),Object.getOwnPropertyNames(n.type.prototype),!!n.contentQueries,!!n.viewQuery].join("|");for(const r of e)t=Math.imul(31,t)+r.charCodeAt(0)<<0;return t+=2147483648,"c"+t}(e),e})}function X_(n){return ci(n)||jn(n)}function q_(n){return null!==n}function Om(n){return Xl(()=>({type:n.type,bootstrap:n.bootstrap||Qi,declarations:n.declarations||Qi,imports:n.imports||Qi,exports:n.exports||Qi,transitiveCompileScopes:null,schemas:n.schemas||null,id:n.id||null}))}function ZT(n,t){if(null==n)return tl;const e={};for(const i in n)if(n.hasOwnProperty(i)){const r=n[i];let s,o,a=qh.None;Array.isArray(r)?(a=r[0],s=r[1],o=r[2]??s):(s=r,o=r),t?(e[s]=a!==qh.None?[i,a]:i,t[s]=o):e[s]=i}return e}function nr(n){return Xl(()=>{const t=JT(n);return KT(t),t})}function ci(n){return n[Gl]||null}function jn(n){return n[Jd]||null}function gs(n){return n[mf]||null}function JT(n){const t={};return{type:n.type,providersResolver:null,factory:null,hostBindings:n.hostBindings||null,hostVars:n.hostVars||0,hostAttrs:n.hostAttrs||null,contentQueries:n.contentQueries||null,declaredInputs:t,inputTransforms:null,inputConfig:n.inputs||tl,exportAs:n.exportAs||null,standalone:!0===n.standalone,signals:!0===n.signals,selectors:n.selectors||Qi,viewQuery:n.viewQuery||null,features:n.features||null,setInput:null,findHostDirectiveDefs:null,hostDirectives:null,inputs:ZT(n.inputs,t),outputs:ZT(n.outputs),debugInfo:null}}function KT(n){n.features?.forEach(t=>t(n))}function km(n,t){if(!n)return null;const e=t?gs:X_;return()=>("function"==typeof n?n():n).map(i=>e(i)).filter(q_)}const Vr=0,Be=1,Ct=2,vn=3,Ma=4,Os=5,wa=6,tu=7,Er=8,Xs=9,ql=10,Yt=11,wf=12,eA=13,iu=14,Jr=15,Cf=16,ru=17,il=18,Ef=19,tA=20,$h=21,Pm=22,Vc=23,Ut=25,jb=1,rl=7,nu=9,mn=10;var Vb=function(n){return n[n.None=0]="None",n[n.HasTransplantedViews=2]="HasTransplantedViews",n}(Vb||{});function ks(n){return Array.isArray(n)&&"object"==typeof n[jb]}function Ps(n){return Array.isArray(n)&&!0===n[jb]}function Wb(n){return 0!=(4&n.flags)}function Wc(n){return n.componentOffset>-1}function Rm(n){return 1==(1&n.flags)}function Ca(n){return!!n.template}function Yb(n){return 0!=(512&n[Ct])}function Yc(n,t){return n.hasOwnProperty(Uo)?n[Uo]:null}class tU{constructor(t,e,i){this.previousValue=t,this.currentValue=e,this.firstChange=i}isFirstChange(){return this.firstChange}}function sA(n,t,e,i){null!==t?t.applyValueToInputSignal(t,i):n[e]=i}function oA(n){return n.type.prototype.ngOnChanges&&(n.setInput=rU),iU}function iU(){const n=lA(this),t=n?.current;if(t){const e=n.previous;if(e===tl)n.previous=t;else for(let i in t)e[i]=t[i];n.current=null,this.ngOnChanges(t)}}function rU(n,t,e,i,r){const s=this.declaredInputs[i],o=lA(n)||function nU(n,t){return n[aA]=t}(n,{previous:tl,current:null}),a=o.current||(o.current={}),l=o.previous,h=l[s];a[s]=new tU(h&&h.currentValue,e,l===tl),sA(n,t,r,e)}const aA="__ngSimpleChanges__";function lA(n){return n[aA]||null}const nl=function(n,t,e){};let dA=!1;function pr(n){for(;Array.isArray(n);)n=n[Vr];return n}function qs(n,t){return pr(t[n.index])}function Tf(n,t){return n.data[t]}function To(n,t){const e=t[n];return ks(e)?e:e[Vr]}function $b(n){return 128==(128&n[Ct])}function sl(n,t){return null==t?null:n[t]}function uA(n){n[ru]=0}function cU(n){1024&n[Ct]||(n[Ct]|=1024,$b(n)&&Af(n))}function fA(n){return 9216&n[Ct]||n[Vc]?.dirty}function Zb(n){fA(n)?Af(n):64&n[Ct]&&(function oU(){return dA}()?(n[Ct]|=1024,Af(n)):n[ql].changeDetectionScheduler?.notify())}function Af(n){n[ql].changeDetectionScheduler?.notify();let t=Qc(n);for(;null!==t&&!(8192&t[Ct])&&(t[Ct]|=8192,$b(t));)t=Qc(t)}function Qc(n){const t=n[vn];return Ps(t)?t[vn]:t}const Rt={lFrame:CA(null),bindingsEnabled:!0,skipHydrationRootTNode:null};function vA(){return Rt.bindingsEnabled}function Se(){return Rt.lFrame.lView}function xi(){return Rt.lFrame.tView}function fr(){let n=mA();for(;null!==n&&64===n.type;)n=n.parent;return n}function mA(){return Rt.lFrame.currentTNode}function ol(n,t){const e=Rt.lFrame;e.currentTNode=n,e.isParent=t}function Kb(){return Rt.lFrame.isParent}function wU(n,t){const e=Rt.lFrame;e.bindingIndex=e.bindingRootIndex=n,t1(t)}function t1(n){Rt.lFrame.currentDirectiveIndex=n}function bA(){return Rt.lFrame.currentQueryIndex}function r1(n){Rt.lFrame.currentQueryIndex=n}function EU(n){const t=n[Be];return 2===t.type?t.declTNode:1===t.type?n[Os]:null}function MA(n,t,e){if(e&Di.SkipSelf){let r=t,s=n;for(;!(r=r.parent,null!==r||e&Di.Host||(r=EU(s),null===r||(s=s[iu],10&r.type))););if(null===r)return!1;t=r,n=s}const i=Rt.lFrame=wA();return i.currentTNode=t,i.lView=n,!0}function n1(n){const t=wA(),e=n[Be];Rt.lFrame=t,t.currentTNode=e.firstChild,t.lView=n,t.tView=e,t.contextLView=n,t.bindingIndex=e.bindingStartIndex,t.inI18n=!1}function wA(){const n=Rt.lFrame,t=null===n?null:n.child;return null===t?CA(n):t}function CA(n){const t={currentTNode:null,isParent:!0,lView:null,tView:null,selectedIndex:-1,contextLView:null,elementDepthCount:0,currentNamespace:null,currentDirectiveIndex:-1,bindingRootIndex:-1,bindingIndex:-1,currentQueryIndex:0,parent:n,child:null,inI18n:!1};return null!==n&&(n.child=t),t}function EA(){const n=Rt.lFrame;return Rt.lFrame=n.parent,n.currentTNode=null,n.lView=null,n}const DA=EA;function s1(){const n=EA();n.isParent=!0,n.tView=null,n.selectedIndex=-1,n.contextLView=null,n.elementDepthCount=0,n.currentDirectiveIndex=-1,n.currentNamespace=null,n.bindingRootIndex=-1,n.bindingIndex=-1,n.currentQueryIndex=0}function zs(){return Rt.lFrame.selectedIndex}function Gc(n){Rt.lFrame.selectedIndex=n}let TA=!0;function Fm(){return TA}function Zh(n){TA=n}function _m(n,t){for(let e=t.directiveStart,i=t.directiveEnd;e=i)break}else t[l]<0&&(n[ru]+=65536),(a>14>16&&(3&n[Ct])===t&&(n[Ct]+=16384,LA(a,s)):LA(a,s)}const au=-1;class Nf{constructor(t,e,i){this.factory=t,this.resolving=!1,this.canSeeViewProviders=e,this.injectImpl=i}}function l1(n){return n!==au}function Of(n){return 32767&n}function kf(n,t){let e=function HU(n){return n>>16}(n),i=t;for(;e>0;)i=i[iu],e--;return i}let h1=!0;function Vm(n){const t=h1;return h1=n,t}const NA=255,OA=5;let BU=0;const ll={};function Wm(n,t){const e=kA(n,t);if(-1!==e)return e;const i=t[Be];i.firstCreatePass&&(n.injectorIndex=t.length,c1(i.data,n),c1(t,null),c1(i.blueprint,null));const r=Ym(n,t),s=n.injectorIndex;if(l1(r)){const o=Of(r),a=kf(r,t),l=a[Be].data;for(let h=0;h<8;h++)t[s+h]=a[o+h]|l[o+h]}return t[s+8]=r,s}function c1(n,t){n.push(0,0,0,0,0,0,0,0,t)}function kA(n,t){return-1===n.injectorIndex||n.parent&&n.parent.injectorIndex===n.injectorIndex||null===t[n.injectorIndex+8]?-1:n.injectorIndex}function Ym(n,t){if(n.parent&&-1!==n.parent.injectorIndex)return n.parent.injectorIndex;let e=0,i=null,r=t;for(;null!==r;){if(i=_A(r),null===i)return au;if(e++,r=r[iu],-1!==i.injectorIndex)return i.injectorIndex|e<<16}return au}function d1(n,t,e){!function FU(n,t,e){let i;"string"==typeof e?i=e.charCodeAt(0)||0:e.hasOwnProperty(jo)&&(i=e[jo]),null==i&&(i=e[jo]=BU++);const r=i&NA;t.data[n+(r>>OA)]|=1<=0?t&NA:VU:t}(e);if("function"==typeof s){if(!MA(t,n,i))return i&Di.Host?PA(r,0,i):zA(t,e,i,r);try{let o;if(o=s(i),null!=o||i&Di.Optional)return o;Nb()}finally{DA()}}else if("number"==typeof s){let o=null,a=kA(n,t),l=au,h=i&Di.Host?t[Jr][Os]:null;for((-1===a||i&Di.SkipSelf)&&(l=-1===a?Ym(n,t):t[a+8],l!==au&&FA(i,!1)?(o=t[Be],a=Of(l),t=kf(l,t)):a=-1);-1!==a;){const c=t[Be];if(BA(s,a,c.data)){const d=UU(a,t,e,o,i,h);if(d!==ll)return d}l=t[a+8],l!==au&&FA(i,t[Be].data[a+8]===h)&&BA(s,a,t)?(o=c,a=Of(l),t=kf(l,t)):a=-1}}return r}function UU(n,t,e,i,r,s){const o=t[Be],a=o.data[n+8],c=Qm(a,o,e,null==i?Wc(a)&&h1:i!=o&&0!=(3&a.type),r&Di.Host&&s===a);return null!==c?Xc(t,o,c,a):ll}function Qm(n,t,e,i,r){const s=n.providerIndexes,o=t.data,a=1048575&s,l=n.directiveStart,c=s>>20,u=r?a+c:n.directiveEnd;for(let p=i?a:a+c;p=l&&f.type===e)return p}if(r){const p=o[l];if(p&&Ca(p)&&p.type===e)return l}return null}function Xc(n,t,e,i){let r=n[e];const s=t.data;if(function kU(n){return n instanceof Nf}(r)){const o=r;o.resolving&&function Vo(n,t){const e=t?`. Dependency path: ${t.join(" > ")} > ${n}`:"";throw new F(-200,`Circular dependency in DI detected for ${n}${e}`)}(zi(s[e]));const a=Vm(o.canSeeViewProviders);o.resolving=!0;const h=o.injectImpl?no(o.injectImpl):null;MA(n,i,Di.Default);try{r=n[e]=o.factory(void 0,s,n,i),t.firstCreatePass&&e>=i.directiveStart&&function NU(n,t,e){const{ngOnChanges:i,ngOnInit:r,ngDoCheck:s}=t.type.prototype;if(i){const o=oA(t);(e.preOrderHooks??=[]).push(n,o),(e.preOrderCheckHooks??=[]).push(n,o)}r&&(e.preOrderHooks??=[]).push(0-n,r),s&&((e.preOrderHooks??=[]).push(n,s),(e.preOrderCheckHooks??=[]).push(n,s))}(e,s[e],t)}finally{null!==h&&no(h),Vm(a),o.resolving=!1,DA()}}return r}function BA(n,t,e){return!!(e[t+(n>>OA)]&1<Array.isArray(e)?gu(e,t):t(e))}function jA(n,t,e){t>=n.length?n.push(e):n.splice(t,0,e)}function Gm(n,t){return t>=n.length-1?n.pop():n.splice(t,1)[0]}const yu=new Ht(""),XA=new Ht("",-1),b1=new Ht("");class Zm{get(t,e=If){if(e===If){const i=new Error(`NullInjectorError: No provider for ${dt(t)}!`);throw i.name="NullInjectorError",i}return e}}function pj(...n){return{\u0275providers:qA(0,n),\u0275fromNgModule:!0}}function qA(n,...t){const e=[],i=new Set;let r;const s=o=>{e.push(o)};return gu(t,o=>{const a=o;Jm(a,s,[],i)&&(r||=[],r.push(a))}),void 0!==r&&$A(r,s),e}function $A(n,t){for(let e=0;e{t(s,i)})}}function Jm(n,t,e,i){if(!(n=vt(n)))return!1;let r=null,s=xm(n);const o=!s&&ci(n);if(s||o){if(o&&!o.standalone)return!1;r=n}else{const l=n.ngModule;if(s=xm(l),!s)return!1;r=l}const a=i.has(r);if(o){if(a)return!1;if(i.add(r),o.dependencies){const l="function"==typeof o.dependencies?o.dependencies():o.dependencies;for(const h of l)Jm(h,t,e,i)}}else{if(!s)return!1;{if(null!=s.imports&&!a){let h;i.add(r);try{gu(s.imports,c=>{Jm(c,t,e,i)&&(h||=[],h.push(c))})}finally{}void 0!==h&&$A(h,t)}if(!a){const h=Yc(r)||(()=>new r);t({provide:r,useFactory:h,deps:Qi},r),t({provide:b1,useValue:r,multi:!0},r),t({provide:yu,useValue:()=>Fi(r),multi:!0},r)}const l=s.providers;if(null!=l&&!a){const h=n;w1(l,c=>{t(c,h)})}}}return r!==n&&void 0!==n.providers}function w1(n,t){for(let e of n)Ql(e)&&(e=e.\u0275providers),Array.isArray(e)?w1(e,t):t(e)}const fj=Xe({provide:String,useValue:Xe});function C1(n){return null!==n&&"object"==typeof n&&fj in n}function qc(n){return"function"==typeof n}const E1=new Ht(""),Km={},vj={};let D1;function ey(){return void 0===D1&&(D1=new Zm),D1}class Jl{}class Su extends Jl{get destroyed(){return this._destroyed}constructor(t,e,i,r){super(),this.parent=e,this.source=i,this.scopes=r,this.records=new Map,this._ngOnDestroyHooks=new Set,this._onDestroyHooks=[],this._destroyed=!1,T1(t,o=>this.processProvider(o)),this.records.set(XA,Iu(void 0,this)),r.has("environment")&&this.records.set(Jl,Iu(void 0,this));const s=this.records.get(E1);null!=s&&"string"==typeof s.value&&this.scopes.add(s.value),this.injectorDefTypes=new Set(this.get(b1,Qi,Di.Self))}destroy(){this.assertNotDestroyed(),this._destroyed=!0;try{for(const e of this._ngOnDestroyHooks)e.ngOnDestroy();const t=this._onDestroyHooks;this._onDestroyHooks=[];for(const e of t)e()}finally{this.records.clear(),this._ngOnDestroyHooks.clear(),this.injectorDefTypes.clear()}}onDestroy(t){return this.assertNotDestroyed(),this._onDestroyHooks.push(t),()=>this.removeOnDestroy(t)}runInContext(t){this.assertNotDestroyed();const e=Xh(this),i=no(void 0);try{return t()}finally{Xh(e),no(i)}}get(t,e=If,i=Di.Default){if(this.assertNotDestroyed(),t.hasOwnProperty(yf))return t[yf](this);i=Lm(i);const s=Xh(this),o=no(void 0);try{if(!(i&Di.SkipSelf)){let l=this.records.get(t);if(void 0===l){const h=function bj(n){return"function"==typeof n||"object"==typeof n&&n instanceof Ht}(t)&&Dm(t);l=h&&this.injectableDefInScope(h)?Iu(x1(t),Km):null,this.records.set(t,l)}if(null!=l)return this.hydrate(t,l)}return(i&Di.Self?ey():this.parent).get(t,e=i&Di.Optional&&e===If?null:e)}catch(a){if("NullInjectorError"===a.name){if((a[Am]=a[Am]||[]).unshift(dt(t)),s)throw a;return function z_(n,t,e,i){const r=n[Am];throw t[UT]&&r.unshift(t[UT]),n.message=function R_(n,t,e,i=null){n=n&&"\n"===n.charAt(0)&&"\u0275"==n.charAt(1)?n.slice(2):n;let r=dt(t);if(Array.isArray(t))r=t.map(dt).join(" -> ");else if("object"==typeof t){let s=[];for(let o in t)if(t.hasOwnProperty(o)){let a=t[o];s.push(o+":"+("string"==typeof a?JSON.stringify(a):dt(a)))}r=`{${s.join(", ")}}`}return`${e}${i?"("+i+")":""}[${r}]: ${n.replace(L_,"\n ")}`}("\n"+n.message,r,e,i),n.ngTokenPath=r,n[Am]=null,n}(a,t,"R3InjectorError",this.source)}throw a}finally{no(o),Xh(s)}}resolveInjectorInitializers(){const t=Xh(this),e=no(void 0);try{const r=this.get(yu,Qi,Di.Self);for(const s of r)s()}finally{Xh(t),no(e)}}toString(){const t=[],e=this.records;for(const i of e.keys())t.push(dt(i));return`R3Injector[${t.join(", ")}]`}assertNotDestroyed(){if(this._destroyed)throw new F(205,!1)}processProvider(t){let e=qc(t=vt(t))?t:vt(t&&t.provide);const i=function yj(n){return C1(n)?Iu(void 0,n.useValue):Iu(KA(n),Km)}(t);if(!qc(t)&&!0===t.multi){let r=this.records.get(e);r||(r=Iu(void 0,Km,!0),r.factory=()=>Fb(r.multi),this.records.set(e,r)),e=t,r.multi.push(t)}this.records.set(e,i)}hydrate(t,e){return e.value===Km&&(e.value=vj,e.value=e.factory()),"object"==typeof e.value&&e.value&&function Ij(n){return null!==n&&"object"==typeof n&&"function"==typeof n.ngOnDestroy}(e.value)&&this._ngOnDestroyHooks.add(e.value),e.value}injectableDefInScope(t){if(!t.providedIn)return!1;const e=vt(t.providedIn);return"string"==typeof e?"any"===e||this.scopes.has(e):this.injectorDefTypes.has(e)}removeOnDestroy(t){const e=this._onDestroyHooks.indexOf(t);-1!==e&&this._onDestroyHooks.splice(e,1)}}function x1(n){const t=Dm(n),e=null!==t?t.factory:Yc(n);if(null!==e)return e;if(n instanceof Ht)throw new F(204,!1);if(n instanceof Function)return function mj(n){if(n.length>0)throw new F(204,!1);const e=function D_(n){return n&&(n[Tm]||n[HT])||null}(n);return null!==e?()=>e.factory(n):()=>new n}(n);throw new F(204,!1)}function KA(n,t,e){let i;if(qc(n)){const r=vt(n);return Yc(r)||x1(r)}if(C1(n))i=()=>vt(n.useValue);else if(function JA(n){return!(!n||!n.useFactory)}(n))i=()=>n.useFactory(...Fb(n.deps||[]));else if(function ZA(n){return!(!n||!n.useExisting)}(n))i=()=>Fi(vt(n.useExisting));else{const r=vt(n&&(n.useClass||n.provide));if(!function Sj(n){return!!n.deps}(n))return Yc(r)||x1(r);i=()=>new r(...Fb(n.deps))}return i}function Iu(n,t,e=!1){return{factory:n,value:t,multi:e?[]:void 0}}function T1(n,t){for(const e of n)Array.isArray(e)?T1(e,t):e&&Ql(e)?T1(e.\u0275providers,t):t(e)}function rL(n,t=null,e=null,i){const r=function nL(n,t=null,e=null,i,r=new Set){const s=[e||Qi,pj(n)];return i=i||("object"==typeof n?void 0:dt(n)),new Su(s,t||ey(),i||null,r)}(n,t,e,i);return r.resolveInjectorInitializers(),r}let N1,Wo=(()=>{class n{static{this.THROW_IF_NOT_FOUND=If}static{this.NULL=new Zm}static create(e,i){if(Array.isArray(e))return rL({name:""},i,e,"");{const r=e.name??"";return rL({name:r},e.parent,e.providers,r)}}static{this.\u0275prov=Yi({token:n,providedIn:"any",factory:()=>Fi(XA)})}static{this.__NG_ELEMENT_ID__=-1}}return n})();const O1=new Ht("",{providedIn:"root",factory:()=>Lj}),Lj="ng",oL=new Ht(""),bu=new Ht("",{providedIn:"platform",factory:()=>"unknown"}),aL=new Ht("",{providedIn:"root",factory:()=>function Jh(){if(void 0!==N1)return N1;if(typeof document<"u")return document;throw new F(210,!1)}().body?.querySelector("[ngCspNonce]")?.getAttribute("ngCspNonce")||null});function sy(n){return 128==(128&n.flags)}var tc=function(n){return n[n.Important=1]="Important",n[n.DashCase=2]="DashCase",n}(tc||{});const H1=new Map;let Vj=0;const F1="__ngContext__";function Rs(n,t){ks(t)?(n[F1]=t[Ef],function Yj(n){H1.set(n[Ef],n)}(t)):n[F1]=t}let _1;function U1(n,t){return _1(n,t)}function wu(n,t,e,i,r){if(null!=i){let s,o=!1;Ps(i)?s=i:ks(i)&&(o=!0,i=i[Vr]);const a=pr(i);0===n&&null!==e?null==r?AL(t,e,a):Zc(t,e,a,r||null,!0):1===n&&null!==e?Zc(t,e,a,r||null,!0):2===n?function uy(n,t,e){const i=cy(n,t);i&&function a6(n,t,e,i){n.removeChild(t,e,i)}(n,i,t,e)}(t,a,o):3===n&&t.destroyNode(a),null!=s&&function c6(n,t,e,i,r){const s=e[rl];s!==pr(e)&&wu(t,n,i,s,r);for(let a=mn;a0&&(n[e-1][Ma]=i[Ma]);const s=Gm(n,mn+t);!function e6(n,t){DL(n,t),t[Vr]=null,t[Os]=null}(i[Be],i);const o=s[il];null!==o&&o.detachView(s[Be]),i[vn]=null,i[Ma]=null,i[Ct]&=-129}return i}function hy(n,t){if(!(256&t[Ct])){const e=t[Yt];e.destroyNode&&py(n,t,e,3,null,null),function i6(n){let t=n[wf];if(!t)return V1(n[Be],n);for(;t;){let e=null;if(ks(t))e=t[wf];else{const i=t[mn];i&&(e=i)}if(!e){for(;t&&!t[Ma]&&t!==n;)ks(t)&&V1(t[Be],t),t=t[vn];null===t&&(t=n),ks(t)&&V1(t[Be],t),e=t&&t[Ma]}t=e}}(t)}}function V1(n,t){if(!(256&t[Ct])){t[Ct]&=-129,t[Ct]|=256,t[Vc]&&function Xd(n){if(Vl(n),Yh(n))for(let t=0;t=0?i[o]():i[-o].unsubscribe(),s+=2}else e[s].call(i[e[s+1]]);null!==i&&(t[tu]=null);const r=t[$h];if(null!==r){t[$h]=null;for(let s=0;s-1){const{encapsulation:s}=n.data[i.directiveStart+r];if(s===Ia.None||s===Ia.Emulated)return null}return qs(i,e)}}(n,t.parent,e)}function Zc(n,t,e,i,r){n.insertBefore(t,e,i,r)}function AL(n,t,e){n.appendChild(t,e)}function LL(n,t,e,i,r){null!==i?Zc(n,t,e,i,r):AL(n,t,e)}function cy(n,t){return n.parentNode(t)}let Y1,kL=function OL(n,t,e){return 40&n.type?qs(n,e):null};function dy(n,t,e,i){const r=W1(n,i,t),s=t[Yt],a=function NL(n,t,e){return kL(n,t,e)}(i.parent||t[Os],i,t);if(null!=r)if(Array.isArray(e))for(let l=0;lnull;function aM(n,t,e=!1){return KL(n,t,e)}class G6{}class nN{}class q6{resolveComponentFactory(t){throw function X6(n){const t=Error(`No component factory found for ${dt(n)}.`);return t.ngComponent=n,t}(t)}}let My=(()=>{class n{static{this.NULL=new q6}}return n})();function $6(){return Au(fr(),Se())}function Au(n,t){return new Jc(qs(n,t))}let Jc=(()=>{class n{constructor(e){this.nativeElement=e}static{this.__NG_ELEMENT_ID__=$6}}return n})();function Z6(n){return n instanceof Jc?n.nativeElement:n}class oN{}let dM=(()=>{class n{constructor(){this.destroyNode=null}static{this.__NG_ELEMENT_ID__=()=>function J6(){const n=Se(),e=To(fr().index,n);return(ks(e)?e:n)[Yt]}()}}return n})(),K6=(()=>{class n{static{this.\u0275prov=Yi({token:n,providedIn:"root",factory:()=>null})}}return n})();const uM={};function Xf(n,t,e,i,r=!1){for(;null!==e;){const s=t[e.index];null!==s&&i.push(pr(s)),Ps(s)&&fN(s,i);const o=e.type;if(8&o)Xf(n,t,e.child,i);else if(32&o){const a=U1(e,t);let l;for(;l=a();)i.push(l)}else if(16&o){const a=zL(t,e);if(Array.isArray(a))i.push(...a);else{const l=Qc(t[Jr]);Xf(l[Be],l,a,i,!0)}}e=r?e.projectionNext:e.next}return i}function fN(n,t){for(let e=mn;e!1,producerRecomputeValue:()=>{},consumerMarkedDirty:()=>{},consumerOnSignalRead:()=>{},consumerIsAlwaysLive:!0,consumerMarkedDirty:n=>{Af(n.lView)},consumerOnSignalRead(){this.lView[Vc]=this}};function vN(n){return yN(n[wf])}function mN(n){return yN(n[Ma])}function yN(n){for(;null!==n&&!Ps(n);)n=n[Ma];return n}function gM(n){return n.ngOriginalError}class eh{constructor(){this._console=console}handleError(t){const e=this._findOriginalError(t);this._console.error("ERROR",t),e&&this._console.error("ORIGINAL ERROR",e)}_findOriginalError(t){let e=t&&gM(t);for(;e&&gM(e);)e=gM(e);return e||null}}const IN=new Ht("",{providedIn:"root",factory:()=>Ri(eh).handleError.bind(void 0)}),MN=new Ht("",{providedIn:"root",factory:()=>!1}),Qt={};function Lu(n=1){DN(xi(),Se(),zs()+n,!1)}function DN(n,t,e,i){if(!i)if(3==(3&t[Ct])){const s=n.preOrderCheckHooks;null!==s&&Um(t,s,e)}else{const s=n.preOrderHooks;null!==s&&jm(t,s,0,e)}Gc(e)}function Ot(n,t=Di.Default){const e=Se();return null===e?Fi(n,t):RA(fr(),e,vt(n),t)}function xN(n,t,e,i,r,s){const o=Wi(null);try{let a=null;r&qh.SignalBased&&(a=t[i][Ts]),null!==a&&void 0!==a.transformFn&&(s=a.transformFn(s)),r&qh.HasDecoratorInputTransform&&(s=n.inputTransforms[i].call(t,s)),null!==n.setInput?n.setInput(t,a,s,e,i):sA(t,a,i,s)}finally{Wi(o)}}function Dy(n,t,e,i,r,s,o,a,l,h,c){const d=t.blueprint.slice();return d[Vr]=r,d[Ct]=204|i,(null!==h||n&&2048&n[Ct])&&(d[Ct]|=2048),uA(d),d[vn]=d[iu]=n,d[Er]=e,d[ql]=o||n&&n[ql],d[Yt]=a||n&&n[Yt],d[Xs]=l||n&&n[Xs]||null,d[Os]=s,d[Ef]=function Wj(){return Vj++}(),d[wa]=c,d[tA]=h,d[Jr]=2==t.type?n[Jr]:d,d}function Nu(n,t,e,i,r){let s=n.data[t];if(null===s)s=function vM(n,t,e,i,r){const s=mA(),o=Kb(),l=n.data[t]=function LV(n,t,e,i,r,s){let o=t?t.injectorIndex:-1,a=0;return function ou(){return null!==Rt.skipHydrationRootTNode}()&&(a|=128),{type:e,index:i,insertBeforeIndex:null,injectorIndex:o,directiveStart:-1,directiveEnd:-1,directiveStylingLast:-1,componentOffset:-1,propertyBindings:null,flags:a,providerIndexes:0,value:r,attrs:s,mergedAttrs:null,localNames:null,initialInputs:void 0,inputs:null,outputs:null,tView:null,next:null,prev:null,projectionNext:null,child:null,parent:t,projection:null,styles:null,stylesWithoutHost:null,residualStyles:void 0,classes:null,classesWithoutHost:null,residualClasses:void 0,classBindings:0,styleBindings:0}}(0,o?s:s&&s.parent,e,t,i,r);return null===n.firstChild&&(n.firstChild=l),null!==s&&(o?null==s.child&&null!==l.parent&&(s.child=l):null===s.next&&(s.next=l,l.prev=s)),l}(n,t,e,i,r),function MU(){return Rt.lFrame.inI18n}()&&(s.flags|=32);else if(64&s.type){s.type=e,s.value=i,s.attrs=r;const o=function Lf(){const n=Rt.lFrame,t=n.currentTNode;return n.isParent?t:t.parent}();s.injectorIndex=null===o?-1:o.injectorIndex}return ol(s,!0),s}function qf(n,t,e,i){if(0===e)return-1;const r=t.length;for(let s=0;sUt&&DN(n,t,Ut,!1),nl(o?2:0,r),e(i,r)}finally{Gc(s),nl(o?3:1,r)}}function mM(n,t,e){if(Wb(t)){const i=Wi(null);try{const s=t.directiveEnd;for(let o=t.directiveStart;onull;function NN(n,t,e,i,r){for(let s in t){if(!t.hasOwnProperty(s))continue;const o=t[s];if(void 0===o)continue;i??={};let a,l=qh.None;Array.isArray(o)?(a=o[0],l=o[1]):a=o;let h=s;if(null!==r){if(!r.hasOwnProperty(s))continue;h=r[s]}0===n?ON(i,e,h,a,l):ON(i,e,h,a)}return i}function ON(n,t,e,i,r){let s;n.hasOwnProperty(e)?(s=n[e]).push(t,i):s=n[e]=[t,i],void 0!==r&&s.push(r)}function kN(n,t,e,i,r,s){for(let h=0;h0;){const e=n[--t];if("number"==typeof e&&e<0)return e}return 0})(o)!=a&&o.push(a),o.push(e,i,s)}}(n,t,i,qf(n,e,r.hostVars,Qt),r)}function YV(n,t,e,i,r,s){const o=s[t];if(null!==o)for(let a=0;an.nextProducerIndex;)n.producerNode.pop(),n.producerLastReadVersion.pop(),n.producerIndexOfThis.pop()}}(a,o),function pV(n){n.lView[Vc]!==n&&(n.lView=null,gN.push(n))}(a)),s1()}}function _N(n,t){for(let e=vN(n);null!==e;e=mN(e))for(let i=mn;i-1&&(_f(t,i),Gm(e,i))}this._attachedToViewContainer=!1}hy(this._lView[Be],this._lView)}onDestroy(t){!function Bm(n,t){if(256==(256&n[Ct]))throw new F(911,!1);null===n[$h]&&(n[$h]=[]),n[$h].push(t)}(this._lView,t)}markForCheck(){$f(this._cdRefInjectingView||this._lView)}detach(){this._lView[Ct]&=-129}reattach(){Zb(this._lView),this._lView[Ct]|=128}detectChanges(){this._lView[Ct]|=1024,function DM(n,t=!0){const e=n[ql],i=e.rendererFactory;i.begin?.();try{!function XV(n){xM(n,0);let t=0;for(;fA(n);){if(100===t)throw new F(103,!1);t++,xM(n,1)}}(n)}catch(s){throw t&&Ty(n,s),s}finally{i.end?.(),e.inlineEffectRunner?.flush()}}(this._lView,this.notifyErrorHandler)}checkNoChanges(){}attachToViewContainerRef(){if(this._appRef)throw new F(902,!1);this._attachedToViewContainer=!0}detachFromAppRef(){this._appRef=null,DL(this._lView[Be],this._lView)}attachToAppRef(t){if(this._attachedToViewContainer)throw new F(902,!1);this._appRef=t,Zb(this._lView)}}const WN=new Set;function AM(n){return t=>{setTimeout(n,void 0,t)}}const Yo=class h7 extends Pt{constructor(t=!1){super(),this.__isAsync=t}emit(t){super.next(t)}subscribe(t,e,i){let r=t,s=e||(()=>null),o=i;if(t&&"object"==typeof t){const l=t;r=l.next?.bind(l),s=l.error?.bind(l),o=l.complete?.bind(l)}this.__isAsync&&(s=AM(s),r&&(r=AM(r)),o&&(o=AM(o)));const a=super.subscribe({next:r,error:s,complete:o});return t instanceof As&&t.add(a),a}};function YN(...n){}class zr{constructor({enableLongStackTrace:t=!1,shouldCoalesceEventChangeDetection:e=!1,shouldCoalesceRunChangeDetection:i=!1}){if(this.hasPendingMacrotasks=!1,this.hasPendingMicrotasks=!1,this.isStable=!0,this.onUnstable=new Yo(!1),this.onMicrotaskEmpty=new Yo(!1),this.onStable=new Yo(!1),this.onError=new Yo(!1),typeof Zone>"u")throw new F(908,!1);Zone.assertZonePatched();const r=this;r._nesting=0,r._outer=r._inner=Zone.current,Zone.TaskTrackingZoneSpec&&(r._inner=r._inner.fork(new Zone.TaskTrackingZoneSpec)),t&&Zone.longStackTraceZoneSpec&&(r._inner=r._inner.fork(Zone.longStackTraceZoneSpec)),r.shouldCoalesceEventChangeDetection=!i&&e,r.shouldCoalesceRunChangeDetection=i,r.lastRequestAnimationFrameId=-1,r.nativeRequestAnimationFrame=function c7(){const n="function"==typeof rr.requestAnimationFrame;let t=rr[n?"requestAnimationFrame":"setTimeout"],e=rr[n?"cancelAnimationFrame":"clearTimeout"];if(typeof Zone<"u"&&t&&e){const i=t[Zone.__symbol__("OriginalDelegate")];i&&(t=i);const r=e[Zone.__symbol__("OriginalDelegate")];r&&(e=r)}return{nativeRequestAnimationFrame:t,nativeCancelAnimationFrame:e}}().nativeRequestAnimationFrame,function p7(n){const t=()=>{!function u7(n){n.isCheckStableRunning||-1!==n.lastRequestAnimationFrameId||(n.lastRequestAnimationFrameId=n.nativeRequestAnimationFrame.call(rr,()=>{n.fakeTopEventTask||(n.fakeTopEventTask=Zone.root.scheduleEventTask("fakeTopEventTask",()=>{n.lastRequestAnimationFrameId=-1,NM(n),n.isCheckStableRunning=!0,LM(n),n.isCheckStableRunning=!1},void 0,()=>{},()=>{})),n.fakeTopEventTask.invoke()}),NM(n))}(n)};n._inner=n._inner.fork({name:"angular",properties:{isAngularZone:!0},onInvokeTask:(e,i,r,s,o,a)=>{if(function f7(n){return!(!Array.isArray(n)||1!==n.length)&&!0===n[0].data?.__ignore_ng_zone__}(a))return e.invokeTask(r,s,o,a);try{return QN(n),e.invokeTask(r,s,o,a)}finally{(n.shouldCoalesceEventChangeDetection&&"eventTask"===s.type||n.shouldCoalesceRunChangeDetection)&&t(),GN(n)}},onInvoke:(e,i,r,s,o,a,l)=>{try{return QN(n),e.invoke(r,s,o,a,l)}finally{n.shouldCoalesceRunChangeDetection&&t(),GN(n)}},onHasTask:(e,i,r,s)=>{e.hasTask(r,s),i===r&&("microTask"==s.change?(n._hasPendingMicrotasks=s.microTask,NM(n),LM(n)):"macroTask"==s.change&&(n.hasPendingMacrotasks=s.macroTask))},onHandleError:(e,i,r,s)=>(e.handleError(r,s),n.runOutsideAngular(()=>n.onError.emit(s)),!1)})}(r)}static isInAngularZone(){return typeof Zone<"u"&&!0===Zone.current.get("isAngularZone")}static assertInAngularZone(){if(!zr.isInAngularZone())throw new F(909,!1)}static assertNotInAngularZone(){if(zr.isInAngularZone())throw new F(909,!1)}run(t,e,i){return this._inner.run(t,e,i)}runTask(t,e,i,r){const s=this._inner,o=s.scheduleEventTask("NgZoneEvent: "+r,t,d7,YN,YN);try{return s.runTask(o,e,i)}finally{s.cancelTask(o)}}runGuarded(t,e,i){return this._inner.runGuarded(t,e,i)}runOutsideAngular(t){return this._outer.run(t)}}const d7={};function LM(n){if(0==n._nesting&&!n.hasPendingMicrotasks&&!n.isStable)try{n._nesting++,n.onMicrotaskEmpty.emit(null)}finally{if(n._nesting--,!n.hasPendingMicrotasks)try{n.runOutsideAngular(()=>n.onStable.emit(null))}finally{n.isStable=!0}}}function NM(n){n.hasPendingMicrotasks=!!(n._hasPendingMicrotasks||(n.shouldCoalesceEventChangeDetection||n.shouldCoalesceRunChangeDetection)&&-1!==n.lastRequestAnimationFrameId)}function QN(n){n._nesting++,n.isStable&&(n.isStable=!1,n.onUnstable.emit(null))}function GN(n){n._nesting--,LM(n)}let Jf=(()=>{class n{constructor(){this.handler=null,this.internalCallbacks=[]}execute(){const e=[...this.internalCallbacks];this.internalCallbacks.length=0;for(const r of e)r();return!!this.handler?.execute()||e.length>0}ngOnDestroy(){this.handler?.destroy(),this.handler=null,this.internalCallbacks.length=0}static{this.\u0275prov=Yi({token:n,providedIn:"root",factory:()=>new n})}}return n})();function y7(n,t){const e=To(t,n),i=e[Be];!function S7(n,t){for(let e=t.length;e0&&BL(n,e,s.join(" "))}}(u,w,f,i),void 0!==e&&function A7(n,t,e){const i=n.projection=[];for(let r=0;r=0;i--){const r=n[i];r.hostVars=t+=r.hostVars,r.hostAttrs=Mf(r.hostAttrs,e=Mf(e,r.hostAttrs))}}(i)}function N7(n,t){for(const e in t.inputs){if(!t.inputs.hasOwnProperty(e)||n.inputs.hasOwnProperty(e))continue;const i=t.inputs[e];if(void 0!==i&&(n.inputs[e]=i,n.declaredInputs[e]=t.declaredInputs[e],null!==t.inputTransforms)){const r=Array.isArray(i)?i[0]:i;if(!t.inputTransforms.hasOwnProperty(r))continue;n.inputTransforms??={},n.inputTransforms[r]=t.inputTransforms[r]}}}function Ly(n){return n===tl?{}:n===Qi?[]:n}function k7(n,t){const e=n.viewQuery;n.viewQuery=e?(i,r)=>{t(i,r),e(i,r)}:t}function P7(n,t){const e=n.contentQueries;n.contentQueries=e?(i,r,s)=>{t(i,r,s),e(i,r,s)}:t}function z7(n,t){const e=n.hostBindings;n.hostBindings=e?(i,r)=>{t(i,r),e(i,r)}:t}function ku(n,t){return!t||null===t.firstChild||sy(n)}function sg(n,t,e,i=!0){const r=t[Be];if(function r6(n,t,e,i){const r=mn+i,s=e.length;i>0&&(e[r-1][Ma]=t),i{class n{static{this.__NG_ELEMENT_ID__=h9}}return n})();function h9(){return fO(fr(),Se())}const c9=xn,uO=class extends c9{constructor(t,e,i){super(),this._lContainer=t,this._hostTNode=e,this._hostLView=i}get element(){return Au(this._hostTNode,this._hostLView)}get injector(){return new Vn(this._hostTNode,this._hostLView)}get parentInjector(){const t=Ym(this._hostTNode,this._hostLView);if(l1(t)){const e=kf(t,this._hostLView),i=Of(t);return new Vn(e[Be].data[i+8],e)}return new Vn(null,this._hostLView)}clear(){for(;this.length>0;)this.remove(this.length-1)}get(t){const e=pO(this._lContainer);return null!==e&&e[t]||null}get length(){return this._lContainer.length-mn}createEmbeddedView(t,e,i){let r,s;"number"==typeof i?r=i:null!=i&&(r=i.index,s=i.injector);const a=t.createEmbeddedViewImpl(e||{},s,null);return this.insertImpl(a,r,ku(this._hostTNode,null)),a}createComponent(t,e,i,r,s){const o=t&&!function Pf(n){return"function"==typeof n}(t);let a;if(o)a=e;else{const f=e||{};a=f.index,i=f.injector,r=f.projectableNodes,s=f.environmentInjector||f.ngModuleRef}const l=o?t:new Kf(ci(t)),h=i||this.parentInjector;if(!s&&null==l.ngModule){const g=(o?h:this.parentInjector).get(Jl,null);g&&(s=g)}ci(l.componentType??{});const p=l.create(h,r,null,s);return this.insertImpl(p.hostView,a,ku(this._hostTNode,null)),p}insert(t,e){return this.insertImpl(t,e,!0)}insertImpl(t,e,i){const r=t._lView;if(function hU(n){return Ps(n[vn])}(r)){const a=this.indexOf(t);if(-1!==a)this.detach(a);else{const l=r[vn],h=new uO(l,l[Os],l[vn]);h.detach(h.indexOf(t))}}const s=this._adjustIndex(e),o=this._lContainer;return sg(o,r,s,i),t.attachToViewContainerRef(),jA(FM(o),s,t),t}move(t,e){return this.insert(t,e)}indexOf(t){const e=pO(this._lContainer);return null!==e?e.indexOf(t):-1}remove(t){const e=this._adjustIndex(t,-1),i=_f(this._lContainer,e);i&&(Gm(FM(this._lContainer),e),hy(i[Be],i))}detach(t){const e=this._adjustIndex(t,-1),i=_f(this._lContainer,e);return i&&null!=Gm(FM(this._lContainer),e)?new Zf(i):null}_adjustIndex(t,e=0){return t??this.length+e}};function pO(n){return n[8]}function FM(n){return n[8]||(n[8]=[])}function fO(n,t){let e;const i=t[n.index];return Ps(i)?e=i:(e=function zN(n,t,e,i){return[n,!0,0,t,null,i,null,e,null,null]}(i,t,null,n),t[n.index]=e,xy(t,e)),gO(e,t,n,i),new uO(e,n,t)}let gO=function mO(n,t,e,i){if(n[rl])return;let r;r=8&e.type?pr(i):function d9(n,t){const e=n[Yt],i=e.createComment(""),r=qs(t,n);return Zc(e,cy(e,r),i,function l6(n,t){return n.nextSibling(t)}(e,r),!1),i}(t,e),n[rl]=r};function nd(n,t,e){const i=Se();return function Tn(n,t,e){return!Object.is(n[t],e)&&(n[t]=e,!0)}(i,function al(){return Rt.lFrame.bindingIndex++}(),t)&&function No(n,t,e,i,r,s,o,a){const l=qs(t,e);let c,h=t.inputs;!a&&null!=h&&(c=h[i])?(EM(n,e,c,i,r),Wc(t)&&function kV(n,t){const e=To(t,n);16&e[Ct]||(e[Ct]|=64)}(e,t.index)):3&t.type&&(i=function OV(n){return"class"===n?"className":"for"===n?"htmlFor":"formaction"===n?"formAction":"innerHtml"===n?"innerHTML":"readonly"===n?"readOnly":"tabindex"===n?"tabIndex":n}(i),r=null!=o?o(r,t.value||"",i):r,s.setProperty(l,i,r))}(xi(),function Pr(){const n=Rt.lFrame;return Tf(n.tView,n.selectedIndex)}(),i,n,t,i[Yt],e,!1),nd}function JM(n,t,e,i,r){const o=r?"class":"style";EM(n,e,t.inputs[o],o,i)}function ih(n,t,e,i){const r=Se(),s=xi(),o=Ut+n,a=r[Yt],l=s.firstCreatePass?function B8(n,t,e,i,r,s){const o=t.consts,l=Nu(t,n,2,i,sl(o,r));return function bM(n,t,e,i){if(vA()){const r=null===i?null:{"":-1},s=function FV(n,t){const e=n.directiveRegistry;let i=null,r=null;if(e)for(let s=0;s(Zh(!0),ly(i,r,function xA(){return Rt.lFrame.currentNamespace}()));const Zu="en-US";let wk=Zu;function lw(n){return!!n&&"function"==typeof n.then}function Xk(n){return!!n&&"function"==typeof n.subscribe}function Xy(n,t,e,i){const r=Se(),s=xi(),o=fr();return function $k(n,t,e,i,r,s,o){const a=Rm(i),h=n.firstCreatePass&&BN(n),c=t[Er],d=HN(t);let u=!0;if(3&i.type||o){const g=qs(i,t),v=o?o(g):g,y=d.length,S=o?M=>o(pr(M[i.index])):i.index;let b=null;if(!o&&a&&(b=function UW(n,t,e,i){const r=n.cleanup;if(null!=r)for(let s=0;sl?a[l]:null}"string"==typeof o&&(s+=2)}return null}(n,t,r,i.index)),null!==b)(b.__ngLastListenerFn__||b).__ngNextListenerFn__=s,b.__ngLastListenerFn__=s,u=!1;else{s=Jk(i,t,c,s,!1);const M=e.listen(v,r,s);d.push(s,M),h&&h.push(r,S,y,y+1)}}else s=Jk(i,t,c,s,!1);const p=i.outputs;let f;if(u&&null!==p&&(f=p[r])){const g=f.length;if(g)for(let v=0;v-1?To(n.index,t):t);let l=Zk(t,e,i,o),h=s.__ngNextListenerFn__;for(;h;)l=Zk(t,e,h,o)&&l,h=h.__ngNextListenerFn__;return r&&!1===l&&o.preventDefault(),l}}function QW(){return this._results[Symbol.iterator]()}class cw{get changes(){return this._changes??=new Yo}constructor(t=!1){this._emitDistinctChangesOnly=t,this.dirty=!0,this._results=[],this._changesDetected=!1,this._changes=void 0,this.length=0,this.first=void 0,this.last=void 0;const e=cw.prototype;e[Symbol.iterator]||(e[Symbol.iterator]=QW)}get(t){return this._results[t]}map(t){return this._results.map(t)}filter(t){return this._results.filter(t)}find(t){return this._results.find(t)}reduce(t,e){return this._results.reduce(t,e)}forEach(t){this._results.forEach(t)}some(t){return this._results.some(t)}toArray(){return this._results.slice()}toString(){return this._results.toString()}reset(t,e){this.dirty=!1;const i=function oo(n){return n.flat(Number.POSITIVE_INFINITY)}(t);(this._changesDetected=!function $U(n,t,e){if(n.length!==t.length)return!1;for(let i=0;i{class n{static{this.__NG_ELEMENT_ID__=qW}}return n})();const GW=nh,XW=class extends GW{constructor(t,e,i){super(),this._declarationLView=t,this._declarationTContainer=e,this.elementRef=i}get ssrId(){return this._declarationTContainer.tView?.ssrId||null}createEmbeddedView(t,e){return this.createEmbeddedViewImpl(t,e)}createEmbeddedViewImpl(t,e,i){const r=function ng(n,t,e,i){const r=t.tView,a=Dy(n,r,e,4096&n[Ct]?4096:16,null,t,null,null,null,i?.injector??null,i?.dehydratedView??null);a[Cf]=n[t.index];const h=n[il];return null!==h&&(a[il]=h.createEmbeddedView(r)),OM(r,a,e),a}(this._declarationLView,this._declarationTContainer,t,{injector:e,dehydratedView:i});return new Zf(r)}};function qW(){return qy(fr(),Se())}function qy(n,t){return 4&n.type?new XW(t,n,Au(n,t)):null}class dw{constructor(t){this.queryList=t,this.matches=null}clone(){return new dw(this.queryList)}setDirty(){this.queryList.setDirty()}}class uw{constructor(t=[]){this.queries=t}createEmbeddedView(t){const e=t.queries;if(null!==e){const i=null!==t.contentQueries?t.contentQueries[0]:e.length,r=[];for(let s=0;s0)i.push(o[a/2]);else{const h=s[a+1],c=t[-l];for(let d=mn;d(Zh(!0),function ay(n,t){return n.createText(t)}(t[Yt],i));function mw(n,t,e,i,r){if(n=vt(n),Array.isArray(n))for(let s=0;s>20;if(qc(n)||!n.multi){const p=new Nf(h,r,Ot),f=Sw(l,t,r?c:c+u,d);-1===f?(d1(Wm(a,o),s,l),yw(s,n,t.length),t.push(l),a.directiveStart++,a.directiveEnd++,r&&(a.providerIndexes+=1048576),e.push(p),o.push(p)):(e[f]=p,o[f]=p)}else{const p=Sw(l,t,c+u,d),f=Sw(l,t,c,c+u),v=f>=0&&e[f];if(r&&!v||!r&&!(p>=0&&e[p])){d1(Wm(a,o),s,l);const y=function yY(n,t,e,i,r){const s=new Nf(n,e,Ot);return s.multi=[],s.index=t,s.componentProviders=0,kP(s,r,i&&!e),s}(r?mY:vY,e.length,r,i,h);!r&&v&&(e[f].providerFactory=y),yw(s,n,t.length,0),t.push(l),a.directiveStart++,a.directiveEnd++,r&&(a.providerIndexes+=1048576),e.push(y),o.push(y)}else yw(s,n,p>-1?p:f,kP(e[r?f:p],h,!r&&i));!r&&i&&v&&e[f].componentProviders++}}}function yw(n,t,e,i){const r=qc(t),s=function gj(n){return!!n.useClass}(t);if(r||s){const l=(s?vt(t.useClass):t).prototype.ngOnDestroy;if(l){const h=n.destroyHooks||(n.destroyHooks=[]);if(!r&&t.multi){const c=h.indexOf(e);-1===c?h.push(e,[i,l]):h[c+1].push(i,l)}else h.push(e,l)}}}function kP(n,t,e){return e&&n.componentProviders++,n.multi.push(t)-1}function Sw(n,t,e,i){for(let r=e;r{e.providersResolver=(i,r)=>function gY(n,t,e){const i=xi();if(i.firstCreatePass){const r=Ca(n);mw(e,i.data,i.blueprint,r,!0),mw(t,i.data,i.blueprint,r,!1)}}(i,r?r(n):n,t)}}class od{}class zP extends od{constructor(t){super(),this.componentFactoryResolver=new KN(this),this.instance=null;const e=new Su([...t.providers,{provide:od,useValue:this},{provide:My,useValue:this.componentFactoryResolver}],t.parent||ey(),t.debugName,new Set(["environment"]));this.injector=e,t.runEnvironmentInitializers&&e.resolveInjectorInitializers()}destroy(){this.injector.destroy()}onDestroy(t){this.injector.onDestroy(t)}}let wY=(()=>{class n{constructor(e){this._injector=e,this.cachedInjectors=new Map}getOrCreateStandaloneInjector(e){if(!e.standalone)return null;if(!this.cachedInjectors.has(e)){const i=qA(0,e.type),r=i.length>0?function MY(n,t,e=null){return new zP({providers:n,parent:t,debugName:e,runEnvironmentInitializers:!0}).injector}([i],this._injector,`Standalone[${e.type.name}]`):null;this.cachedInjectors.set(e,r)}return this.cachedInjectors.get(e)}ngOnDestroy(){try{for(const e of this.cachedInjectors.values())null!==e&&e.destroy()}finally{this.cachedInjectors.clear()}}static{this.\u0275prov=Yi({token:n,providedIn:"environment",factory:()=>new n(Fi(Jl))})}}return n})();function RP(n){(function Kc(n){WN.has(n)||(WN.add(n),performance?.mark?.("mark_feature_usage",{detail:{feature:n}}))})("NgStandalone"),n.getStandaloneInjector=t=>t.get(wY).getOrCreateStandaloneInjector(n)}let Aw=(()=>{class n{constructor(){this.taskId=0,this.pendingTasks=new Set,this.hasPendingTasks=new _o(!1)}get _hasPendingTasks(){return this.hasPendingTasks.value}add(){this._hasPendingTasks||this.hasPendingTasks.next(!0);const e=this.taskId++;return this.pendingTasks.add(e),e}remove(e){this.pendingTasks.delete(e),0===this.pendingTasks.size&&this._hasPendingTasks&&this.hasPendingTasks.next(!1)}ngOnDestroy(){this.pendingTasks.clear(),this._hasPendingTasks&&this.hasPendingTasks.next(!1)}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();const g2=new Ht(""),XQ=new Ht("");let Pw=(()=>{class n{constructor(){this.initialized=!1,this.done=!1,this.donePromise=new Promise((e,i)=>{this.resolve=e,this.reject=i}),this.appInits=Ri(XQ,{optional:!0})??[]}runInitializers(){if(this.initialized)return;const e=[];for(const r of this.appInits){const s=r();if(lw(s))e.push(s);else if(Xk(s)){const o=new Promise((a,l)=>{s.subscribe({complete:a,error:l})});e.push(o)}}const i=()=>{this.done=!0,this.resolve()};Promise.all(e).then(()=>{i()}).catch(r=>{this.reject(r)}),0===e.length&&i(),this.initialized=!0}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();const v2=new Ht("");let ep=(()=>{class n{constructor(){this._bootstrapListeners=[],this._runningTick=!1,this._destroyed=!1,this._destroyListeners=[],this._views=[],this.internalErrorHandler=Ri(IN),this.afterRenderEffectManager=Ri(Jf),this.componentTypes=[],this.components=[],this.isStable=Ri(Aw).hasPendingTasks.pipe(jr(e=>!e)),this._injector=Ri(Jl)}get destroyed(){return this._destroyed}get injector(){return this._injector}bootstrap(e,i){const r=e instanceof nN;if(!this._injector.get(Pw).done)throw!r&&function jc(n){const t=ci(n)||jn(n)||gs(n);return null!==t&&t.standalone}(e),new F(405,!1);let o;o=r?e:this._injector.get(My).resolveComponentFactory(e),this.componentTypes.push(o.componentType);const a=function $Q(n){return n.isBoundToModule}(o)?void 0:this._injector.get(od),h=o.create(Wo.NULL,[],i||o.selector,a),c=h.location.nativeElement,d=h.injector.get(g2,null);return d?.registerApplication(c),h.onDestroy(()=>{this.detachView(h.hostView),t0(this.components,h),d?.unregisterApplication(c)}),this._loadComponent(h),h}tick(){if(this._runningTick)throw new F(101,!1);try{this._runningTick=!0;for(let e of this._views)e.detectChanges()}catch(e){this.internalErrorHandler(e)}finally{try{this.afterRenderEffectManager.execute()}catch(e){this.internalErrorHandler(e)}this._runningTick=!1}}attachView(e){const i=e;this._views.push(i),i.attachToAppRef(this)}detachView(e){const i=e;t0(this._views,i),i.detachFromAppRef()}_loadComponent(e){this.attachView(e.hostView),this.tick(),this.components.push(e);const i=this._injector.get(v2,[]);[...this._bootstrapListeners,...i].forEach(r=>r(e))}ngOnDestroy(){if(!this._destroyed)try{this._destroyListeners.forEach(e=>e()),this._views.slice().forEach(e=>e.destroy())}finally{this._destroyed=!0,this._views=[],this._bootstrapListeners=[],this._destroyListeners=[]}}onDestroy(e){return this._destroyListeners.push(e),()=>t0(this._destroyListeners,e)}destroy(){if(this._destroyed)throw new F(406,!1);const e=this._injector;e.destroy&&!e.destroyed&&e.destroy()}get viewCount(){return this._views.length}warnIfDestroyed(){}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();function t0(n,t){const e=n.indexOf(t);e>-1&&n.splice(e,1)}let JQ=(()=>{class n{constructor(){this.zone=Ri(zr),this.applicationRef=Ri(ep)}initialize(){this._onMicrotaskEmptySubscription||(this._onMicrotaskEmptySubscription=this.zone.onMicrotaskEmpty.subscribe({next:()=>{this.zone.run(()=>{this.applicationRef.tick()})}}))}ngOnDestroy(){this._onMicrotaskEmptySubscription?.unsubscribe()}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();function b2(n){return[{provide:zr,useFactory:n},{provide:yu,multi:!0,useFactory:()=>{const t=Ri(JQ,{optional:!0});return()=>t.initialize()}},{provide:yu,multi:!0,useFactory:()=>{const t=Ri(tG);return()=>{t.initialize()}}},{provide:IN,useFactory:KQ}]}function KQ(){const n=Ri(zr),t=Ri(eh);return e=>n.runOutsideAngular(()=>t.handleError(e))}function eG(n){return function M1(n){return{\u0275providers:n}}([[],b2(()=>new zr(function M2(n){return{enableLongStackTrace:!1,shouldCoalesceEventChangeDetection:n?.eventCoalescing??!1,shouldCoalesceRunChangeDetection:n?.runCoalescing??!1}}(n)))])}let tG=(()=>{class n{constructor(){this.subscription=new As,this.initialized=!1,this.zone=Ri(zr),this.pendingTasks=Ri(Aw)}initialize(){if(this.initialized)return;this.initialized=!0;let e=null;!this.zone.isStable&&!this.zone.hasPendingMacrotasks&&!this.zone.hasPendingMicrotasks&&(e=this.pendingTasks.add()),this.zone.runOutsideAngular(()=>{this.subscription.add(this.zone.onStable.subscribe(()=>{zr.assertNotInAngularZone(),queueMicrotask(()=>{null!==e&&!this.zone.hasPendingMacrotasks&&!this.zone.hasPendingMicrotasks&&(this.pendingTasks.remove(e),e=null)})}))}),this.subscription.add(this.zone.onUnstable.subscribe(()=>{zr.assertInAngularZone(),e??=this.pendingTasks.add()}))}ngOnDestroy(){this.subscription.unsubscribe()}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();const sh=new Ht("",{providedIn:"root",factory:()=>Ri(sh,Di.Optional|Di.SkipSelf)||function iG(){return typeof $localize<"u"&&$localize.locale||Zu}()}),zw=new Ht("");let sc=null;function DG(n){try{const{rootComponent:t,appProviders:e,platformProviders:i}=n,r=function aG(n=[]){if(sc)return sc;const t=function E2(n=[],t){return Wo.create({name:t,providers:[{provide:E1,useValue:"platform"},{provide:zw,useValue:new Set([()=>sc=null])},...n]})}(n);return sc=t,function m2(){!function wb(n){$d=n}(()=>{throw new F(600,!1)})}(),function D2(n){n.get(oL,null)?.forEach(e=>e())}(t),t}(i),s=[eG(),...e||[]],a=new zP({providers:s,parent:r,debugName:"",runEnvironmentInitializers:!1}).injector,l=a.get(zr);return l.run(()=>{a.resolveInjectorInitializers();const h=a.get(eh,null);let c;l.runOutsideAngular(()=>{c=l.onError.subscribe({next:p=>{h.handleError(p)}})});const d=()=>a.destroy(),u=r.get(zw);return u.add(d),a.onDestroy(()=>{c.unsubscribe(),u.delete(d)}),function y2(n,t,e){try{const i=e();return lw(i)?i.catch(r=>{throw t.runOutsideAngular(()=>n.handleError(r)),r}):i}catch(i){throw t.runOutsideAngular(()=>n.handleError(i)),i}}(h,l,()=>{const p=a.get(Pw);return p.runInitializers(),p.donePromise.then(()=>{!function Ck(n){ro(n,"Expected localeId to be defined"),"string"==typeof n&&(wk=n.toLowerCase().replace(/_/g,"-"))}(a.get(sh,Zu)||Zu);const g=a.get(ep);return void 0!==t&&g.bootstrap(t),g})})})}catch(t){return Promise.reject(t)}}let $2=null;function Vw(){return $2}class UG{}const ld=new Ht("");let sq=(()=>{class n{static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275mod=Om({type:n})}static{this.\u0275inj=Sf({})}}return n})();function uz(n){return"server"===n}class kq extends UG{constructor(){super(...arguments),this.supportsDOMEvents=!0}}class oC extends kq{static makeCurrent(){!function _G(n){$2??=n}(new oC)}onAndCancel(t,e,i){return t.addEventListener(e,i),()=>{t.removeEventListener(e,i)}}dispatchEvent(t,e){t.dispatchEvent(e)}remove(t){t.parentNode&&t.parentNode.removeChild(t)}createElement(t,e){return(e=e||this.getDefaultDocument()).createElement(t)}createHtmlDocument(){return document.implementation.createHTMLDocument("fakeTitle")}getDefaultDocument(){return document}isElementNode(t){return t.nodeType===Node.ELEMENT_NODE}isShadowRoot(t){return t instanceof DocumentFragment}getGlobalEventTarget(t,e){return"window"===e?window:"document"===e?t:"body"===e?t.body:null}getBaseHref(t){const e=function Pq(){return Dg=Dg||document.querySelector("base"),Dg?Dg.getAttribute("href"):null}();return null==e?null:function zq(n){return new URL(n,document.baseURI).pathname}(e)}resetBaseElement(){Dg=null}getUserAgent(){return window.navigator.userAgent}getCookie(t){return function xX(n,t){t=encodeURIComponent(t);for(const e of n.split(";")){const i=e.indexOf("="),[r,s]=-1==i?[e,""]:[e.slice(0,i),e.slice(i+1)];if(r.trim()===t)return decodeURIComponent(s)}return null}(document.cookie,t)}}let Dg=null,Hq=(()=>{class n{build(){return new XMLHttpRequest}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();const aC=new Ht("");let vz=(()=>{class n{constructor(e,i){this._zone=i,this._eventNameToPlugin=new Map,e.forEach(r=>{r.manager=this}),this._plugins=e.slice().reverse()}addEventListener(e,i,r){return this._findPluginFor(i).addEventListener(e,i,r)}getZone(){return this._zone}_findPluginFor(e){let i=this._eventNameToPlugin.get(e);if(i)return i;if(i=this._plugins.find(s=>s.supports(e)),!i)throw new F(5101,!1);return this._eventNameToPlugin.set(e,i),i}static{this.\u0275fac=function(i){return new(i||n)(Fi(aC),Fi(zr))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();class mz{constructor(t){this._doc=t}}const lC="ng-app-id";let yz=(()=>{class n{constructor(e,i,r,s={}){this.doc=e,this.appId=i,this.nonce=r,this.platformId=s,this.styleRef=new Map,this.hostNodes=new Set,this.styleNodesInDOM=this.collectServerRenderedStyles(),this.platformIsServer=uz(s),this.resetHostNodes()}addStyles(e){for(const i of e)1===this.changeUsageCount(i,1)&&this.onStyleAdded(i)}removeStyles(e){for(const i of e)this.changeUsageCount(i,-1)<=0&&this.onStyleRemoved(i)}ngOnDestroy(){const e=this.styleNodesInDOM;e&&(e.forEach(i=>i.remove()),e.clear());for(const i of this.getAllStyles())this.onStyleRemoved(i);this.resetHostNodes()}addHost(e){this.hostNodes.add(e);for(const i of this.getAllStyles())this.addStyleToHost(e,i)}removeHost(e){this.hostNodes.delete(e)}getAllStyles(){return this.styleRef.keys()}onStyleAdded(e){for(const i of this.hostNodes)this.addStyleToHost(i,e)}onStyleRemoved(e){const i=this.styleRef;i.get(e)?.elements?.forEach(r=>r.remove()),i.delete(e)}collectServerRenderedStyles(){const e=this.doc.head?.querySelectorAll(`style[${lC}="${this.appId}"]`);if(e?.length){const i=new Map;return e.forEach(r=>{null!=r.textContent&&i.set(r.textContent,r)}),i}return null}changeUsageCount(e,i){const r=this.styleRef;if(r.has(e)){const s=r.get(e);return s.usage+=i,s.usage}return r.set(e,{usage:i,elements:[]}),i}getStyleElement(e,i){const r=this.styleNodesInDOM,s=r?.get(i);if(s?.parentNode===e)return r.delete(i),s.removeAttribute(lC),s;{const o=this.doc.createElement("style");return this.nonce&&o.setAttribute("nonce",this.nonce),o.textContent=i,this.platformIsServer&&o.setAttribute(lC,this.appId),e.appendChild(o),o}}addStyleToHost(e,i){const r=this.getStyleElement(e,i),s=this.styleRef,o=s.get(i)?.elements;o?o.push(r):s.set(i,{elements:[r],usage:1})}resetHostNodes(){const e=this.hostNodes;e.clear(),e.add(this.doc.head)}static{this.\u0275fac=function(i){return new(i||n)(Fi(ld),Fi(O1),Fi(aL,8),Fi(bu))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();const hC={svg:"http://www.w3.org/2000/svg",xhtml:"http://www.w3.org/1999/xhtml",xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/",math:"http://www.w3.org/1998/MathML/"},cC=/%COMP%/g,Uq=new Ht("",{providedIn:"root",factory:()=>!0});function Iz(n,t){return t.map(e=>e.replace(cC,n))}let bz=(()=>{class n{constructor(e,i,r,s,o,a,l,h=null){this.eventManager=e,this.sharedStylesHost=i,this.appId=r,this.removeStylesOnCompDestroy=s,this.doc=o,this.platformId=a,this.ngZone=l,this.nonce=h,this.rendererByCompId=new Map,this.platformIsServer=uz(a),this.defaultRenderer=new dC(e,o,l,this.platformIsServer)}createRenderer(e,i){if(!e||!i)return this.defaultRenderer;this.platformIsServer&&i.encapsulation===Ia.ShadowDom&&(i={...i,encapsulation:Ia.Emulated});const r=this.getOrCreateRenderer(e,i);return r instanceof wz?r.applyToHost(e):r instanceof uC&&r.applyStyles(),r}getOrCreateRenderer(e,i){const r=this.rendererByCompId;let s=r.get(i.id);if(!s){const o=this.doc,a=this.ngZone,l=this.eventManager,h=this.sharedStylesHost,c=this.removeStylesOnCompDestroy,d=this.platformIsServer;switch(i.encapsulation){case Ia.Emulated:s=new wz(l,h,i,this.appId,c,o,a,d);break;case Ia.ShadowDom:return new Yq(l,h,e,i,o,a,this.nonce,d);default:s=new uC(l,h,i,c,o,a,d)}r.set(i.id,s)}return s}ngOnDestroy(){this.rendererByCompId.clear()}static{this.\u0275fac=function(i){return new(i||n)(Fi(vz),Fi(yz),Fi(O1),Fi(Uq),Fi(ld),Fi(bu),Fi(zr),Fi(aL))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();class dC{constructor(t,e,i,r){this.eventManager=t,this.doc=e,this.ngZone=i,this.platformIsServer=r,this.data=Object.create(null),this.throwOnSyntheticProps=!0,this.destroyNode=null}destroy(){}createElement(t,e){return e?this.doc.createElementNS(hC[e]||e,t):this.doc.createElement(t)}createComment(t){return this.doc.createComment(t)}createText(t){return this.doc.createTextNode(t)}appendChild(t,e){(Mz(t)?t.content:t).appendChild(e)}insertBefore(t,e,i){t&&(Mz(t)?t.content:t).insertBefore(e,i)}removeChild(t,e){t&&t.removeChild(e)}selectRootElement(t,e){let i="string"==typeof t?this.doc.querySelector(t):t;if(!i)throw new F(-5104,!1);return e||(i.textContent=""),i}parentNode(t){return t.parentNode}nextSibling(t){return t.nextSibling}setAttribute(t,e,i,r){if(r){e=r+":"+e;const s=hC[r];s?t.setAttributeNS(s,e,i):t.setAttribute(e,i)}else t.setAttribute(e,i)}removeAttribute(t,e,i){if(i){const r=hC[i];r?t.removeAttributeNS(r,e):t.removeAttribute(`${i}:${e}`)}else t.removeAttribute(e)}addClass(t,e){t.classList.add(e)}removeClass(t,e){t.classList.remove(e)}setStyle(t,e,i,r){r&(tc.DashCase|tc.Important)?t.style.setProperty(e,i,r&tc.Important?"important":""):t.style[e]=i}removeStyle(t,e,i){i&tc.DashCase?t.style.removeProperty(e):t.style[e]=""}setProperty(t,e,i){null!=t&&(t[e]=i)}setValue(t,e){t.nodeValue=e}listen(t,e,i){if("string"==typeof t&&!(t=Vw().getGlobalEventTarget(this.doc,t)))throw new Error(`Unsupported event target ${t} for event ${e}`);return this.eventManager.addEventListener(t,e,this.decoratePreventDefault(i))}decoratePreventDefault(t){return e=>{if("__ngUnwrap__"===e)return t;!1===(this.platformIsServer?this.ngZone.runGuarded(()=>t(e)):t(e))&&e.preventDefault()}}}function Mz(n){return"TEMPLATE"===n.tagName&&void 0!==n.content}class Yq extends dC{constructor(t,e,i,r,s,o,a,l){super(t,s,o,l),this.sharedStylesHost=e,this.hostEl=i,this.shadowRoot=i.attachShadow({mode:"open"}),this.sharedStylesHost.addHost(this.shadowRoot);const h=Iz(r.id,r.styles);for(const c of h){const d=document.createElement("style");a&&d.setAttribute("nonce",a),d.textContent=c,this.shadowRoot.appendChild(d)}}nodeOrShadowRoot(t){return t===this.hostEl?this.shadowRoot:t}appendChild(t,e){return super.appendChild(this.nodeOrShadowRoot(t),e)}insertBefore(t,e,i){return super.insertBefore(this.nodeOrShadowRoot(t),e,i)}removeChild(t,e){return super.removeChild(this.nodeOrShadowRoot(t),e)}parentNode(t){return this.nodeOrShadowRoot(super.parentNode(this.nodeOrShadowRoot(t)))}destroy(){this.sharedStylesHost.removeHost(this.shadowRoot)}}class uC extends dC{constructor(t,e,i,r,s,o,a,l){super(t,s,o,a),this.sharedStylesHost=e,this.removeStylesOnCompDestroy=r,this.styles=l?Iz(l,i.styles):i.styles}applyStyles(){this.sharedStylesHost.addStyles(this.styles)}destroy(){this.removeStylesOnCompDestroy&&this.sharedStylesHost.removeStyles(this.styles)}}class wz extends uC{constructor(t,e,i,r,s,o,a,l){const h=r+"-"+i.id;super(t,e,i,s,o,a,l,h),this.contentAttr=function jq(n){return"_ngcontent-%COMP%".replace(cC,n)}(h),this.hostAttr=function Vq(n){return"_nghost-%COMP%".replace(cC,n)}(h)}applyToHost(t){this.applyStyles(),this.setAttribute(t,this.hostAttr,"")}createElement(t,e){const i=super.createElement(t,e);return super.setAttribute(i,this.contentAttr,""),i}}let Qq=(()=>{class n extends mz{constructor(e){super(e)}supports(e){return!0}addEventListener(e,i,r){return e.addEventListener(i,r,!1),()=>this.removeEventListener(e,i,r)}removeEventListener(e,i,r){return e.removeEventListener(i,r)}static{this.\u0275fac=function(i){return new(i||n)(Fi(ld))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();const Cz=["alt","control","meta","shift"],Gq={"\b":"Backspace","\t":"Tab","\x7f":"Delete","\x1b":"Escape",Del:"Delete",Esc:"Escape",Left:"ArrowLeft",Right:"ArrowRight",Up:"ArrowUp",Down:"ArrowDown",Menu:"ContextMenu",Scroll:"ScrollLock",Win:"OS"},Xq={alt:n=>n.altKey,control:n=>n.ctrlKey,meta:n=>n.metaKey,shift:n=>n.shiftKey};let qq=(()=>{class n extends mz{constructor(e){super(e)}supports(e){return null!=n.parseEventName(e)}addEventListener(e,i,r){const s=n.parseEventName(i),o=n.eventCallback(s.fullKey,r,this.manager.getZone());return this.manager.getZone().runOutsideAngular(()=>Vw().onAndCancel(e,s.domEventName,o))}static parseEventName(e){const i=e.toLowerCase().split("."),r=i.shift();if(0===i.length||"keydown"!==r&&"keyup"!==r)return null;const s=n._normalizeKey(i.pop());let o="",a=i.indexOf("code");if(a>-1&&(i.splice(a,1),o="code."),Cz.forEach(h=>{const c=i.indexOf(h);c>-1&&(i.splice(c,1),o+=h+".")}),o+=s,0!=i.length||0===s.length)return null;const l={};return l.domEventName=r,l.fullKey=o,l}static matchEventFullKeyCode(e,i){let r=Gq[e.key]||e.key,s="";return i.indexOf("code.")>-1&&(r=e.code,s="code."),!(null==r||!r)&&(r=r.toLowerCase()," "===r?r="space":"."===r&&(r="dot"),Cz.forEach(o=>{o!==r&&(0,Xq[o])(e)&&(s+=o+".")}),s+=r,s===i)}static eventCallback(e,i,r){return s=>{n.matchEventFullKeyCode(s,e)&&r.runGuarded(()=>i(s))}}static _normalizeKey(e){return"esc"===e?"escape":e}static{this.\u0275fac=function(i){return new(i||n)(Fi(ld))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();function Ez(n){return{appProviders:[...i$,...n?.providers??[]],platformProviders:e$}}const e$=[{provide:bu,useValue:"browser"},{provide:oL,useValue:function Zq(){oC.makeCurrent()},multi:!0},{provide:ld,useFactory:function Kq(){return function Aj(n){N1=n}(document),document},deps:[]}],i$=[{provide:E1,useValue:"root"},{provide:eh,useFactory:function Jq(){return new eh},deps:[]},{provide:aC,useClass:Qq,multi:!0,deps:[ld,zr,bu]},{provide:aC,useClass:qq,multi:!0,deps:[ld]},bz,yz,vz,{provide:oN,useExisting:bz},{provide:class cq{},useClass:Hq,deps:[]},[]];var o$=0,pC=!1;function C0(n,t){var e=t;return e.unshift(void 0),new(Function.prototype.bind.apply(n,e))}function Y(n,t){for(var e=t,i=n.replace(/\[/g,".").replace(/\]/g,"").split("."),r=0;r"u"}function wi(n){return n+"_"+o$++}function D0(n,t){return n===t||!(n===document||!n)&&D0(n.parentNode,t)}function Ag(n){try{throw new Error(n)}catch(t){throw new Error(t.message+"\n"+t.stack)}}function Re(n){var t=n+"";return t.match(/auto|cm|mm|in|px|pt|pc|%|em|ex|ch|rem|vw|vh|vmin|vmax/)?t:t+"px"}function ce(){return pC}var Lg,n,t,d$={latn:{_digits:"0123456789",_type:"numeric"}},Lz={decimal:".",group:",",percentSign:"%",plusSign:"+",minusSign:"-",infinity:"\u221e",nan:"NaN",exponential:"E"},Nz=[0,1,2,3,4,5,6,7,8,9],Rr=function(){function n(){}return n.getMainObject=function(t,e){return Y(ce()?e:"main."+e,t)},n.getNumberingSystem=function(t){return Y("supplemental.numberingSystems",t)||this.numberingSystems},n.reverseObject=function(t,e){for(var r={},s=0,o=e||Object.keys(t);s13&&(f+=1,o-=12),o-=1,a=f-4716;var y=u-24e5,S=10631/30,b=u-1948084,M=Math.floor(b/10631);b-=10631*M;var w=Math.floor((b-.1335)/S),C=30*M+w;b-=Math.floor(w*S+.1335);var D=Math.floor((b+28.5001)/29.5);13===D&&(D=12);for(var A=b-Math.floor(29.5001*D-29),x=0;xy);x++);var R=x+16260,L=Math.floor((R-1)/12),O=L+1,N=R-12*L,T=y-t[x-1]+1;return(T+"").length>2&&(T=A,N=D,O=C),{year:O,month:N,date:T}},n.toGregorian=function i(r,s,o){var g=Math.floor(o+t[12*(r-1)+1+(s-1)-16260-1]-1+24e5+.5),v=Math.floor((g-1867216.25)/36524.25),y=1524+(v=g+1+v-Math.floor(v/4)),S=Math.floor((y-122.1)/365.25),b=Math.floor(365.25*S),M=Math.floor((y-b)/30.6001),w=y-b-Math.floor(30.6001*M),C=M-(M>13.5?13:1),D=S-(C>2.5?4716:4715);return D<=0&&C--,new Date(D+"/"+C+"/"+w)};var ut,f$=/\/MMMMM|MMMM|MMM|a|LLLL|LLL|EEEEE|EEEE|E|K|cccc|ccc|WW|W|G+|z+/gi,Oz="stand-alone",g$=["sun","mon","tue","wed","thu","fri","sat"],kz={m:"getMinutes",h:"getHours",H:"getHours",s:"getSeconds",d:"getDate",f:"getMilliseconds"},Pz=function(){function n(){}return n.dateFormat=function(t,e,i){var r=this,s=ut.getDependables(i,t,e.calendar),o=Y("parserObject.numbers",s),a=s.dateObject,l={isIslamic:ut.islamicRegex.test(e.calendar)};ce()&&e.isServerRendered&&(e=ut.compareBlazorDateFormats(e,t));var h=e.format||ut.getResultantPattern(e.skeleton,s.dateObject,e.type,!1,ce()?t:"");if(l.dateSeperator=ce()?Y("dateSeperator",a):ut.getDateSeparator(s.dateObject),st(h))Ag("Format options or type given must be invalid");else{h=ut.ConvertDateToWeekFormat(h),ce()&&(h=h.replace(/tt/,"a")),l.pattern=h,l.numMapper=ce()?ze({},o):Rr.getNumberMapper(s.parserObject,Rr.getNumberingSystem(i));for(var d=0,u=h.match(f$)||[];d2?r+=e.month[""+u]:f=!0;break;case"E":case"c":r+=e.weekday[""+g$[t.getDay()]];break;case"H":case"h":case"m":case"s":case"d":case"f":if(f=!0,"d"===d)u=o.date;else if("f"===d){f=!1,g=!0;var y=(p=(p=t[""+kz[""+d]]().toString()).substring(0,c)).length;if(c!==y){if(c>3)continue;for(var S=0;S0?1:0],o=Math.abs(t);return s.replace(/HH?|mm/g,function(a){var l=a.length,h=-1!==a.indexOf("H");return i.checkTwodigitNumber(Math.floor(h?o/60:o%60),l)})},n}(),zz={ms:"minimumSignificantDigits",ls:"maximumSignificantDigits",mf:"minimumFractionDigits",lf:"maximumFractionDigits"},np=["infinity","nan","group","decimal","exponential"],Rz=function(){function n(){}return n.numberFormatter=function(t,e,i){var l,r=this,s=ze({},e),o={},a={},h=ut.getDependables(i,t,"",!0),c=h.numericObject;a.numberMapper=ce()?ze({},c):Rr.getNumberMapper(h.parserObject,Rr.getNumberingSystem(i),!0),a.currencySymbol=ce()?Y("currencySymbol",c):ut.getCurrencySymbol(h.numericObject,s.currency||kg,e.altSymbol,e.ignoreCurrency),a.percentSymbol=ce()?Y("numberSymbols.percentSign",c):a.numberMapper.numberSymbols.percentSign,a.minusSymbol=ce()?Y("numberSymbols.minusSign",c):a.numberMapper.numberSymbols.minusSign;var d=a.numberMapper.numberSymbols;if(e.format&&!ut.formatRegex.test(e.format))o=ut.customFormat(e.format,a,h.numericObject),!st(s.useGrouping)&&s.useGrouping&&(s.useGrouping=o.pData.useGrouping);else{if(ze(s,ut.getProperNumericSkeleton(e.format||"N")),s.isCurrency="currency"===s.type,s.isPercent="percent"===s.type,ce()||(l=ut.getSymbolPattern(s.type,a.numberMapper.numberSystem,h.numericObject,s.isAccount)),s.groupOne=this.checkValueRange(s.maximumSignificantDigits,s.minimumSignificantDigits,!0),this.checkValueRange(s.maximumFractionDigits,s.minimumFractionDigits,!1,!0),st(s.fractionDigits)||(s.minimumFractionDigits=s.maximumFractionDigits=s.fractionDigits),st(s.useGrouping)&&(s.useGrouping=!0),s.isCurrency&&!ce()&&(l=l.replace(/\u00A4/g,ut.defaultCurrency)),ce())o.nData=ze({},{},Y(s.type+"nData",c)),o.pData=ze({},{},Y(s.type+"pData",c)),"currency"===s.type&&e.currency&&ut.replaceBlazorCurrency([o.pData,o.nData],a.currencySymbol,e.currency);else{var u=l.split(";");o.nData=ut.getFormatData(u[1]||"-"+u[0],!0,a.currencySymbol),o.pData=ut.getFormatData(u[0],!1,a.currencySymbol),s.useGrouping&&(s.groupSeparator=d[np[2]],s.groupData=this.getGroupingDetails(u[0]))}if(st(s.minimumFractionDigits)&&(s.minimumFractionDigits=o.nData.minimumFraction),st(s.maximumFractionDigits)){var f=o.nData.maximumFraction;s.maximumFractionDigits=st(f)&&s.isPercent?0:f}var g=s.minimumFractionDigits,v=s.maximumFractionDigits;!st(g)&&!st(v)&&g>v&&(s.maximumFractionDigits=g)}return ze(o.nData,s),ze(o.pData,s),function(y){return isNaN(y)?d[np[1]]:isFinite(y)?r.intNumberFormatter(y,o,a,e):d[np[0]]}},n.getGroupingDetails=function(t){var e={},i=t.match(ut.negativeDataRegex);if(i&&i[4]){var r=i[4],s=r.lastIndexOf(",");if(-1!==s){var o=r.split(".")[0];e.primary=o.length-s-1;var a=r.lastIndexOf(",",s-1);-1!==a&&(e.secondary=s-1-a)}}return e},n.checkValueRange=function(t,e,i,r){var s=r?"f":"s",o=0,a=zz["l"+s],l=zz["m"+s];if(st(t)||(this.checkRange(t,a,r),o++),st(e)||(this.checkRange(e,l,r),o++),2===o){if(!(tr[1])&&Ag(e+"value must be within the range"+r[0]+"to"+r[1])},n.intNumberFormatter=function(t,e,i,r){var s;if(!st(e.nData.type)){t<0?(t*=-1,s=e.nData):s=0===t&&e.zeroData||e.pData;var o="";if(s.isPercent&&(t*=100),s.groupOne)o=this.processSignificantDigits(t,s.minimumSignificantDigits,s.maximumSignificantDigits);else if(o=this.processFraction(t,s.minimumFractionDigits,s.maximumFractionDigits,r),s.minimumIntegerDigits&&(o=this.processMinimumIntegers(o,s.minimumIntegerDigits)),i.isCustomFormat&&s.minimumFractionDigits=0&&"0"===l[parseInt(c.toString(),10)]&&c>=s.minimumFractionDigits;c--)l=l.slice(0,c);o=a[0]+"."+l}return"scientific"===s.type&&(o=(o=t.toExponential(s.maximumFractionDigits)).replace("e",i.numberMapper.numberSymbols[np[4]])),o=o.replace(".",i.numberMapper.numberSymbols[np[3]]),o="#,###,,;(#,###,,)"===s.format?this.customPivotFormat(parseInt(o,10)):o,s.useGrouping&&(o=this.groupNumbers(o,s.groupData.primary,s.groupSeparator||",",i.numberMapper.numberSymbols[np[3]]||".",s.groupData.secondary)),o=Rr.convertValueParts(o,ut.latnParseRegex,i.numberMapper.mapper),"N/A"===s.nlead?s.nlead:"0"===o&&r&&"0"===r.format?o+s.nend:s.nlead+o+s.nend}},n.processSignificantDigits=function(t,e,i){var r=t+"";return r.lengthe;)c=l.slice(h-e,h)+(c.length?i+c:""),h-=e,o&&(e=s,o=!1);return a[0]=l.slice(0,h)+(c.length?i:"")+c,a.join(r)},n.processFraction=function(t,e,i,r){var s=(t+"").split(".")[1],o=s?s.length:0;if(e&&oi||0===i))return t.toFixed(i);var h=t+"";return"0"===h[0]&&r&&"###.00"===r.format&&(h=h.slice(1)),h},n.processMinimumIntegers=function(t,e){var i=t.split("."),r=i[0],s=r.length;if(s=5e5){var r=(t/=1e6).toString().split(".")[1];return r&&+r.substring(0,1)>=5?Math.ceil(t).toString():Math.floor(t).toString()}return""},n}(),Ng=(new RegExp("^([^0-9]*)(([0-9,]*[0-9]+)(.[0-9]+)?)([Ee][+-]?[0-9]+)?([^0-9]*)$"),function(){function n(t){this.ranArray=[],this.boundedEvents={},!m(t)&&(this.context=t)}return n.prototype.on=function(t,e,i,r){if(!m(e)){var s=i||this.context;if(this.notExist(t))return void(this.boundedEvents[""+t]=[{handler:e,context:s,id:r}]);m(r)?this.isHandlerPresent(this.boundedEvents[""+t],e)||this.boundedEvents[""+t].push({handler:e,context:s}):-1===this.ranArray.indexOf(r)&&(this.ranArray.push(r),this.boundedEvents[""+t].push({handler:e,context:s,id:r}))}},n.prototype.off=function(t,e,i){if(!this.notExist(t)){var r=Y(t,this.boundedEvents);if(e){for(var s=0;s1&&(_.fractionDigits=parseInt(P[2],10)),_}function f(T,P,_,B){var j=B?{}:{nlead:"",nend:""},Q=T.match(n.customRegex);if(Q){B||(j.nlead=g(Q[1],_),j.nend=g(Q[10],_),j.groupPattern=Q[4]);var oe=Q[7];if(oe&&P){var ue=oe.match(t);j.minimumFraction=m(ue)?0:ue.length,j.maximumFraction=oe.length-1}}return j}function g(T,P){return T?(T=T.replace(n.defaultCurrency,P),""===P?T.trim():T):""}function v(T,P,_,B){return B?"$":Y("currencies."+P+(_?"."+_:".symbol"),T)||Y("currencies."+P+".symbol-alt-narrow",T)||"$"}function S(T,P,_){var B={type:"decimal",minimumFractionDigits:0,maximumFractionDigits:0},j=T.match(n.customRegex);if(m(j)||""===j[5]&&"N/A"!==T)return B.type=void 0,B;B.nlead=j[1],B.nend=j[10];var Q=j[6],oe=!!Q.match(/ $/g),ue=-1!==Q.replace(/ $/g,"").indexOf(" ");B.useGrouping=-1!==Q.indexOf(",")||ue,Q=Q.replace(/,/g,"");var pe=j[7];if(-1!==Q.indexOf("0")&&(B.minimumIntegerDigits=Q.length-Q.indexOf("0")),m(pe)||(B.minimumFractionDigits=pe.lastIndexOf("0"),B.maximumFractionDigits=pe.lastIndexOf("#"),-1===B.minimumFractionDigits&&(B.minimumFractionDigits=0),(-1===B.maximumFractionDigits||B.maximumFractionDigitsQ.lastIndexOf("'"))){B[""+a[parseInt(j.toString(),10)]]=Q.substr(0,oe)+_+Q.substr(oe+1),B[""+a[""+P]]=!0,B.type=B.isCurrency?"currency":"percent";break}}return B}function C(T,P){if(-1!==T.indexOf(",")){var _=T.split(",");T=_[0]+Y("numberMapper.numberSymbols.group",P)+_[1].replace(".",Y("numberMapper.numberSymbols.decimal",P))}else T=T.replace(".",Y("numberMapper.numberSymbols.decimal",P));return T}function A(T,P,_){T+=".";for(var B=0;B0;Q-=3)T=","+_[Q-2]+_[Q-1]+_[parseInt(Q.toString(),10)]+T;return T=T.slice(1),P[1]?T+"."+P[1]:T}n.dateParseRegex=/([a-z])\1*|'([^']|'')+'|''|./gi,n.basicPatterns=["short","medium","long","full"],n.defaultObject={dates:{calendars:{gregorian:{months:{"stand-alone":{abbreviated:{1:"Jan",2:"Feb",3:"Mar",4:"Apr",5:"May",6:"Jun",7:"Jul",8:"Aug",9:"Sep",10:"Oct",11:"Nov",12:"Dec"},narrow:{1:"J",2:"F",3:"M",4:"A",5:"M",6:"J",7:"J",8:"A",9:"S",10:"O",11:"N",12:"D"},wide:{1:"January",2:"February",3:"March",4:"April",5:"May",6:"June",7:"July",8:"August",9:"September",10:"October",11:"November",12:"December"}}},days:{"stand-alone":{abbreviated:{sun:"Sun",mon:"Mon",tue:"Tue",wed:"Wed",thu:"Thu",fri:"Fri",sat:"Sat"},narrow:{sun:"S",mon:"M",tue:"T",wed:"W",thu:"T",fri:"F",sat:"S"},short:{sun:"Su",mon:"Mo",tue:"Tu",wed:"We",thu:"Th",fri:"Fr",sat:"Sa"},wide:{sun:"Sunday",mon:"Monday",tue:"Tuesday",wed:"Wednesday",thu:"Thursday",fri:"Friday",sat:"Saturday"}}},dayPeriods:{format:{wide:{am:"AM",pm:"PM"}}},eras:{eraNames:{0:"Before Christ","0-alt-variant":"Before Common Era",1:"Anno Domini","1-alt-variant":"Common Era"},eraAbbr:{0:"BC","0-alt-variant":"BCE",1:"AD","1-alt-variant":"CE"},eraNarrow:{0:"B","0-alt-variant":"BCE",1:"A","1-alt-variant":"CE"}},dateFormats:{full:"EEEE, MMMM d, y",long:"MMMM d, y",medium:"MMM d, y",short:"M/d/yy"},timeFormats:{full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},dateTimeFormats:{full:"{1} 'at' {0}",long:"{1} 'at' {0}",medium:"{1}, {0}",short:"{1}, {0}",availableFormats:{d:"d",E:"ccc",Ed:"d E",Ehm:"E h:mm a",EHm:"E HH:mm",Ehms:"E h:mm:ss a",EHms:"E HH:mm:ss",Gy:"y G",GyMMM:"MMM y G",GyMMMd:"MMM d, y G",GyMMMEd:"E, MMM d, y G",h:"h a",H:"HH",hm:"h:mm a",Hm:"HH:mm",hms:"h:mm:ss a",Hms:"HH:mm:ss",hmsv:"h:mm:ss a v",Hmsv:"HH:mm:ss v",hmv:"h:mm a v",Hmv:"HH:mm v",M:"L",Md:"M/d",MEd:"E, M/d",MMM:"LLL",MMMd:"MMM d",MMMEd:"E, MMM d",MMMMd:"MMMM d",ms:"mm:ss",y:"y",yM:"M/y",yMd:"M/d/y",yMEd:"E, M/d/y",yMMM:"MMM y",yMMMd:"MMM d, y",yMMMEd:"E, MMM d, y",yMMMM:"MMMM y"}}},islamic:{months:{"stand-alone":{abbreviated:{1:"Muh.",2:"Saf.",3:"Rab. I",4:"Rab. II",5:"Jum. I",6:"Jum. II",7:"Raj.",8:"Sha.",9:"Ram.",10:"Shaw.",11:"Dhu\u02bbl-Q.",12:"Dhu\u02bbl-H."},narrow:{1:"1",2:"2",3:"3",4:"4",5:"5",6:"6",7:"7",8:"8",9:"9",10:"10",11:"11",12:"12"},wide:{1:"Muharram",2:"Safar",3:"Rabi\u02bb I",4:"Rabi\u02bb II",5:"Jumada I",6:"Jumada II",7:"Rajab",8:"Sha\u02bbban",9:"Ramadan",10:"Shawwal",11:"Dhu\u02bbl-Qi\u02bbdah",12:"Dhu\u02bbl-Hijjah"}}},days:{"stand-alone":{abbreviated:{sun:"Sun",mon:"Mon",tue:"Tue",wed:"Wed",thu:"Thu",fri:"Fri",sat:"Sat"},narrow:{sun:"S",mon:"M",tue:"T",wed:"W",thu:"T",fri:"F",sat:"S"},short:{sun:"Su",mon:"Mo",tue:"Tu",wed:"We",thu:"Th",fri:"Fr",sat:"Sa"},wide:{sun:"Sunday",mon:"Monday",tue:"Tuesday",wed:"Wednesday",thu:"Thursday",fri:"Friday",sat:"Saturday"}}},dayPeriods:{format:{wide:{am:"AM",pm:"PM"}}},eras:{eraNames:{0:"AH"},eraAbbr:{0:"AH"},eraNarrow:{0:"AH"}},dateFormats:{full:"EEEE, MMMM d, y G",long:"MMMM d, y G",medium:"MMM d, y G",short:"M/d/y GGGGG"},timeFormats:{full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},dateTimeFormats:{full:"{1} 'at' {0}",long:"{1} 'at' {0}",medium:"{1}, {0}",short:"{1}, {0}",availableFormats:{d:"d",E:"ccc",Ed:"d E",Ehm:"E h:mm a",EHm:"E HH:mm",Ehms:"E h:mm:ss a",EHms:"E HH:mm:ss",Gy:"y G",GyMMM:"MMM y G",GyMMMd:"MMM d, y G",GyMMMEd:"E, MMM d, y G",h:"h a",H:"HH",hm:"h:mm a",Hm:"HH:mm",hms:"h:mm:ss a",Hms:"HH:mm:ss",M:"L",Md:"M/d",MEd:"E, M/d",MMM:"LLL",MMMd:"MMM d",MMMEd:"E, MMM d",MMMMd:"MMMM d",ms:"mm:ss",y:"y G",yyyy:"y G",yyyyM:"M/y GGGGG",yyyyMd:"M/d/y GGGGG",yyyyMEd:"E, M/d/y GGGGG",yyyyMMM:"MMM y G",yyyyMMMd:"MMM d, y G",yyyyMMMEd:"E, MMM d, y G",yyyyMMMM:"MMMM y G",yyyyQQQ:"QQQ y G",yyyyQQQQ:"QQQQ y G"}}}},timeZoneNames:{hourFormat:"+HH:mm;-HH:mm",gmtFormat:"GMT{0}",gmtZeroFormat:"GMT"}},numbers:{currencies:{USD:{displayName:"US Dollar",symbol:"$","symbol-alt-narrow":"$"},EUR:{displayName:"Euro",symbol:"\u20ac","symbol-alt-narrow":"\u20ac"},GBP:{displayName:"British Pound","symbol-alt-narrow":"\xa3"}},defaultNumberingSystem:"latn",minimumGroupingDigits:"1","symbols-numberSystem-latn":{decimal:".",group:",",list:";",percentSign:"%",plusSign:"+",minusSign:"-",exponential:"E",superscriptingExponent:"\xd7",perMille:"\u2030",infinity:"\u221e",nan:"NaN",timeSeparator:":"},"decimalFormats-numberSystem-latn":{standard:"#,##0.###"},"percentFormats-numberSystem-latn":{standard:"#,##0%"},"currencyFormats-numberSystem-latn":{standard:"\xa4#,##0.00",accounting:"\xa4#,##0.00;(\xa4#,##0.00)"},"scientificFormats-numberSystem-latn":{standard:"#E0"}}},n.blazorDefaultObject={numbers:{mapper:{0:"0",1:"1",2:"2",3:"3",4:"4",5:"5",6:"6",7:"7",8:"8",9:"9"},mapperDigits:"0123456789",numberSymbols:{decimal:".",group:",",plusSign:"+",minusSign:"-",percentSign:"%",nan:"NaN",timeSeparator:":",infinity:"\u221e"},timeSeparator:":",currencySymbol:"$",currencypData:{nlead:"$",nend:"",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},percentpData:{nlead:"",nend:"%",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},percentnData:{nlead:"-",nend:"%",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},currencynData:{nlead:"($",nend:")",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},decimalnData:{nlead:"-",nend:"",groupData:{primary:3},maximumFraction:2,minimumFraction:2},decimalpData:{nlead:"",nend:"",groupData:{primary:3},maximumFraction:2,minimumFraction:2}},dates:{dayPeriods:{am:"AM",pm:"PM"},dateSeperator:"/",days:{abbreviated:{sun:"Sun",mon:"Mon",tue:"Tue",wed:"Wed",thu:"Thu",fri:"Fri",sat:"Sat"},short:{sun:"Su",mon:"Mo",tue:"Tu",wed:"We",thu:"Th",fri:"Fr",sat:"Sa"},wide:{sun:"Sunday",mon:"Monday",tue:"Tuesday",wed:"Wednesday",thu:"Thursday",fri:"Friday",sat:"Saturday"}},months:{abbreviated:{1:"Jan",2:"Feb",3:"Mar",4:"Apr",5:"May",6:"Jun",7:"Jul",8:"Aug",9:"Sep",10:"Oct",11:"Nov",12:"Dec"},wide:{1:"January",2:"February",3:"March",4:"April",5:"May",6:"June",7:"July",8:"August",9:"September",10:"October",11:"November",12:"December"}},eras:{1:"AD"}}},n.monthIndex={3:"abbreviated",4:"wide",5:"narrow",1:"abbreviated"},n.month="months",n.days="days",n.patternMatcher={C:"currency",P:"percent",N:"decimal",A:"currency",E:"scientific"},n.getResultantPattern=l,n.getDependables=h,n.getSymbolPattern=c,n.ConvertDateToWeekFormat=d,n.compareBlazorDateFormats=u,n.getProperNumericSkeleton=p,n.getFormatData=f,n.changeCurrencySymbol=g,n.getCurrencySymbol=v,n.customFormat=function y(T,P,_){for(var B={},j=T.split(";"),Q=["pData","nData","zeroData"],oe=0;oe1,pe.nData=ce()?Y(De.type+"nData",oe):f(ot[1]||"-"+ot[0],!0,Ie),pe.pData=ce()?Y(De.type+"pData",oe):f(ot[0],!1,Ie),!Me[2]&&!P.minimumFractionDigits&&!P.maximumFractionDigits&&(ue=f(Ve.split(";")[0],!0,"",!0).minimumFraction)}if(n.formatRegex.test(P.format)||!P.format){if(ze(Q,p(P.format||"N")),Q.custom=!1,$e="###0",(Q.fractionDigits||P.minimumFractionDigits||P.maximumFractionDigits||ue)&&(Q.fractionDigits&&(P.minimumFractionDigits=P.maximumFractionDigits=Q.fractionDigits),$e=A($e,ue||Q.fractionDigits||P.minimumFractionDigits||0,P.maximumFractionDigits||0)),P.minimumIntegerDigits&&($e=x($e,P.minimumIntegerDigits)),P.useGrouping&&($e=R($e)),"currency"===Q.type||Q.type&&ce()){ce()&&"currency"!==Q.type&&(pe.pData=Y(Q.type+"pData",oe),pe.nData=Y(Q.type+"nData",oe));var hr=$e;$e=pe.pData.nlead+hr+pe.pData.nend,(pe.hasNegativePattern||ce())&&($e+=";"+pe.nData.nlead+hr+pe.nData.nend)}"percent"===Q.type&&!ce()&&($e+=" %")}else $e=P.format.replace(/'/g,'"');return Object.keys(xe).length>0&&($e=B?$e:C($e,xe)),$e},n.fractionDigitsPattern=A,n.minimumIntegerPattern=x,n.groupingPattern=R,n.getWeekData=function L(T,P){var _="sun",B=Y("supplemental.weekData.firstDay",P),j=T;return/en-/.test(j)&&(j=j.slice(3)),j=j.slice(0,2).toUpperCase()+j.substr(2),B&&(_=B[""+j]||B[j.slice(0,2)]||"sun"),o[""+_]},n.replaceBlazorCurrency=function O(T,P,_){var B=function p$(n){return Y(n||"",u$)}(_);if(P!==B)for(var j=0,Q=T;j=0?_:_+7;var j=Math.floor((T.getTime()-P.getTime()-6e4*(T.getTimezoneOffset()-P.getTimezoneOffset()))/864e5)+1;if(_<4){if((B=Math.floor((j+_-1)/7)+1)>52){var oe=new Date(T.getFullYear()+1,0,1).getDay();B=(oe=oe>=0?oe:oe+7)<4?1:53}}else B=Math.floor((j+_-1)/7);return B}}(ut||(ut={}));var sp=function(){function n(t,e,i){this.type="GET",this.emitError=!0,"string"==typeof t?(this.url=t,this.type=m(e)?this.type:e.toUpperCase(),this.contentType=i):Aa(t)&&Object.keys(t).length>0&&Nn(this,t),this.contentType=m(this.contentType)?"application/json; charset=utf-8":this.contentType}return n.prototype.send=function(t){var e=this,i={"application/json":"json","multipart/form-data":"formData","application/octet-stream":"blob","application/x-www-form-urlencoded":"formData"};try{m(this.fetchRequest)&&"GET"===this.type?this.fetchRequest=new Request(this.url,{method:this.type}):m(this.fetchRequest)&&(this.data=m(t)?this.data:t,this.fetchRequest=new Request(this.url,{method:this.type,headers:{"Content-Type":this.contentType},body:this.data}));var r={cancel:!1,fetchRequest:this.fetchRequest};return this.triggerEvent(this.beforeSend,r),r.cancel?null:(this.fetchResponse=fetch(this.fetchRequest),this.fetchResponse.then(function(s){if(e.triggerEvent(e.onLoad,s),!s.ok)throw s;for(var o="text",a=0,l=Object.keys(i);a-1},n.getValue=function(t,e){var i=typeof window<"u"?window.browserDetails:{};return typeof navigator<"u"&&"MacIntel"===navigator.platform&&navigator.maxTouchPoints>1&&!0===n.isTouch&&!vC.CHROME.test(navigator.userAgent)&&(i.isIos=!0,i.isDevice=!0,i.isTouch=!0,i.isPointer=!0),typeof window<"u"&&window.Capacitor&&"ios"===window.Capacitor.getPlatform()&&(i.isPointer=!1),typeof i[""+t]>"u"?i[""+t]=e.test(n.userAgent):i[""+t]},Object.defineProperty(n,"userAgent",{get:function(){return n.uA},set:function(t){n.uA=t,window.browserDetails={}},enumerable:!0,configurable:!0}),Object.defineProperty(n,"info",{get:function(){return st(window.browserDetails.info)?window.browserDetails.info=n.extractBrowserDetail():window.browserDetails.info},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isIE",{get:function(){return n.getValue("isIE",A$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isTouch",{get:function(){return st(window.browserDetails.isTouch)?window.browserDetails.isTouch="ontouchstart"in window.navigator||window&&window.navigator&&window.navigator.maxTouchPoints>0||"ontouchstart"in window:window.browserDetails.isTouch},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isPointer",{get:function(){return st(window.browserDetails.isPointer)?window.browserDetails.isPointer="pointerEnabled"in window.navigator:window.browserDetails.isPointer},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isMSPointer",{get:function(){return st(window.browserDetails.isMSPointer)?window.browserDetails.isMSPointer="msPointerEnabled"in window.navigator:window.browserDetails.isMSPointer},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isDevice",{get:function(){return n.getValue("isDevice",T$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isIos",{get:function(){return n.getValue("isIos",N$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isIos7",{get:function(){return n.getValue("isIos7",O$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isAndroid",{get:function(){return n.getValue("isAndroid",k$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isWebView",{get:function(){return st(window.browserDetails.isWebView)&&(window.browserDetails.isWebView=!(st(window.cordova)&&st(window.PhoneGap)&&st(window.phonegap)&&"object"!==window.forge)),window.browserDetails.isWebView},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isWindows",{get:function(){return n.getValue("isWindows",P$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"touchStartEvent",{get:function(){return st(window.browserDetails.touchStartEvent)?window.browserDetails.touchStartEvent=n.getTouchStartEvent():window.browserDetails.touchStartEvent},enumerable:!0,configurable:!0}),Object.defineProperty(n,"touchMoveEvent",{get:function(){return st(window.browserDetails.touchMoveEvent)?window.browserDetails.touchMoveEvent=n.getTouchMoveEvent():window.browserDetails.touchMoveEvent},enumerable:!0,configurable:!0}),Object.defineProperty(n,"touchEndEvent",{get:function(){return st(window.browserDetails.touchEndEvent)?window.browserDetails.touchEndEvent=n.getTouchEndEvent():window.browserDetails.touchEndEvent},enumerable:!0,configurable:!0}),Object.defineProperty(n,"touchCancelEvent",{get:function(){return st(window.browserDetails.touchCancelEvent)?window.browserDetails.touchCancelEvent=n.getTouchCancelEvent():window.browserDetails.touchCancelEvent},enumerable:!0,configurable:!0}),n.uA=typeof navigator<"u"?navigator.userAgent:"",n}(),E=function(){function n(){}return n.addOrGetEventData=function(t){return"__eventList"in t?t.__eventList.events:(t.__eventList={},t.__eventList.events=[])},n.add=function(t,e,i,r,s){var a,o=n.addOrGetEventData(t);a=s?function l$(n,t){var e;return function(){for(var i=this,r=[],s=0;s"u"||(e.innerHTML=t.innerHTML?t.innerHTML:"",void 0!==t.className&&(e.className=t.className),void 0!==t.id&&(e.id=t.id),void 0!==t.styles&&e.setAttribute("style",t.styles),void 0!==t.attrs&&Fe(e,t.attrs)),e}function V(n,t){for(var e=Vz(t),i=RegExp,r=0,s=n;r0}function pl(n,t,e){for(var i=document.createDocumentFragment(),r=0,s=n;r0;)i.appendChild(n[0]);else for(var r=0,s=n;r-1&&!r[parseInt(s.toString(),10)].match(/\[.*\]/)){var o=r[parseInt(s.toString(),10)].split("#");if(o[1].match(/^\d/)||o[1].match(t)){var a=r[parseInt(s.toString(),10)].split(".");a[0]=a[0].replace(/#/,"[id='")+"']",r[parseInt(s.toString(),10)]=a.join(".")}}e[parseInt(i.toString(),10)]=r.join(" ")}return e.join(",")}return n}function J(n,t){var e=n;if("function"==typeof e.closest)return e.closest(t);for(;e&&1===e.nodeType;){if(mC(e,t))return e;e=e.parentNode}return null}function je(n,t){void 0!==t&&Object.keys(t).forEach(function(e){n.style[""+e]=t[""+e]})}function mC(n,t){var e=n.matches||n.msMatchesSelector||n.webkitMatchesSelector;return e?e.call(n,t):-1!==[].indexOf.call(document.querySelectorAll(t),n)}var H$=new RegExp("]"),hh=function(){function n(t,e){this.isRendered=!1,this.isComplexArraySetter=!1,this.isServerRendered=!1,this.allowServerDataBinding=!0,this.isProtectedOnChange=!0,this.properties={},this.changedProperties={},this.oldProperties={},this.bulkChanges={},this.refreshing=!1,this.ignoreCollectionWatch=!1,this.finalUpdate=function(){},this.childChangedProperties={},this.modelObserver=new Ng(this),st(e)||(this.element="string"==typeof e?document.querySelector(e):e,m(this.element)||(this.isProtectedOnChange=!1,this.addInstance())),st(t)||this.setProperties(t,!0),this.isDestroyed=!1}return n.prototype.setProperties=function(t,e){var i=this.isProtectedOnChange;this.isProtectedOnChange=!!e,Nn(this,t),!0!==e?(Nn(this.changedProperties,t),this.dataBind()):ce()&&this.isRendered&&this.serverDataBind(t),this.finalUpdate(),this.changedProperties={},this.oldProperties={},this.isProtectedOnChange=i},n.callChildDataBind=function(t,e){for(var r=0,s=Object.keys(t);r=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Hs=function(n){function t(i){var r=n.call(this,i,void 0)||this;return r.easing={ease:"cubic-bezier(0.250, 0.100, 0.250, 1.000)",linear:"cubic-bezier(0.250, 0.250, 0.750, 0.750)",easeIn:"cubic-bezier(0.420, 0.000, 1.000, 1.000)",easeOut:"cubic-bezier(0.000, 0.000, 0.580, 1.000)",easeInOut:"cubic-bezier(0.420, 0.000, 0.580, 1.000)",elasticInOut:"cubic-bezier(0.5,-0.58,0.38,1.81)",elasticIn:"cubic-bezier(0.17,0.67,0.59,1.81)",elasticOut:"cubic-bezier(0.7,-0.75,0.99,1.01)"},r}var e;return X$(t,n),e=t,t.prototype.animate=function(i,r){var s=this.getModel(r=r||{});if("string"==typeof i)for(var a=0,l=Array.prototype.slice.call(we(i,document));a0?r-1:0,i+=e=-1!==e?"-"+e:"-"+r}return this.controlParent!==this.parentObj&&(i=this.parentObj.getParentKey()+"."+this.propName+e),i},n}(),J$=["grid","pivotview","treegrid","spreadsheet","rangeNavigator","DocumentEditor","listbox","inplaceeditor","PdfViewer","richtexteditor","DashboardLayout","chart","stockChart","circulargauge","diagram","heatmap","lineargauge","maps","slider","smithchart","barcode","sparkline","treemap","bulletChart","kanban","daterangepicker","schedule","gantt","signature","query-builder","drop-down-tree","carousel","filemanager","uploader","accordion","tab","treeview"],tR=[115,121,110,99,102,117,115,105,111,110,46,105,115,76,105,99,86,97,108,105,100,97,116,101,100],iR=function(){function n(t){this.isValidated=!1,this.isLicensed=!0,this.version="27",this.platform=/JavaScript|ASPNET|ASPNETCORE|ASPNETMVC|FileFormats|essentialstudio/i,this.errors={noLicense:"This application was built using a trial version of Syncfusion Essential Studio. To remove the license validation message permanently, a valid license key must be included.",trailExpired:"This application was built using a trial version of Syncfusion Essential Studio. To remove the license validation message permanently, a valid license key must be included.",versionMismatched:"The included Syncfusion license key is invalid.",platformMismatched:"The included Syncfusion license key is invalid.",invalidKey:"The included Syncfusion license key is invalid."},this.manager=function(){var e=null;return{setKey:function i(s){e=s},getKey:function r(){return e}}}(),this.npxManager=function(){return{getKey:function i(){return"npxKeyReplace"}}}(),this.manager.setKey(t)}return n.prototype.validate=function(){if(!this.isValidated&&rp&&!Y(L0(tR),rp)&&!Y("Blazor",rp)){var i=void 0,r=void 0;if(this.manager&&this.manager.getKey()||this.npxManager&&"npxKeyReplace"!==this.npxManager.getKey()){var s=this.getInfoFromKey();if(s&&s.length)for(var o=0,a=s;o"+i+' Claim your FREE account\n
have a Syncfusion account? Sign In
\n
\n ';if(typeof document<"u"&&!m(document)){var t=mi("div",{innerHTML:n});document.body.appendChild(t)}}(),oR=!0),this.render(),this.mount?this.accessMount():this.trigger("created")}},t.prototype.renderComplete=function(e){ce()&&window.sfBlazor.renderComplete(this.element,e),this.isRendered=!0},t.prototype.dataBind=function(){this.injectModules(),n.prototype.dataBind.call(this)},t.prototype.on=function(e,i,r){if("string"==typeof e)this.localObserver.on(e,i,r);else for(var s=0,o=e;s=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},rZ={left:0,top:0,bottom:0,right:0},MC={isDragged:!1},nZ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return aR(t,n),gr([I(0)],t.prototype,"left",void 0),gr([I(0)],t.prototype,"top",void 0),t}(Ee),lp=function(n){function t(i,r){var s=n.call(this,r,i)||this;return s.dragLimit=e.getDefaultPosition(),s.borderWidth=e.getDefaultPosition(),s.padding=e.getDefaultPosition(),s.diffX=0,s.prevLeft=0,s.prevTop=0,s.dragProcessStarted=!1,s.eleTop=0,s.tapHoldTimer=0,s.externalInitialize=!1,s.diffY=0,s.parentScrollX=0,s.parentScrollY=0,s.droppables={},s.bind(),s}var e;return aR(t,n),e=t,t.prototype.bind=function(){this.toggleEvents(),X.isIE&&V([this.element],"e-block-touch"),this.droppables[this.scope]={}},t.getDefaultPosition=function(){return ze({},rZ)},t.prototype.toggleEvents=function(i){var r;st(this.handle)||(r=U(this.handle,this.element));var s=this.enableTapHold&&X.isDevice&&X.isTouch?this.mobileInitialize:this.initialize;i?E.remove(r||this.element,X.isSafari()?"touchstart":X.touchStartEvent,s):E.add(r||this.element,X.isSafari()?"touchstart":X.touchStartEvent,s,this)},t.prototype.mobileInitialize=function(i){var r=this,s=i.currentTarget;this.tapHoldTimer=setTimeout(function(){r.externalInitialize=!0,r.removeTapholdTimer(),r.initialize(i,s)},this.tapHoldThreshold),E.add(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.removeTapholdTimer,this),E.add(document,X.isSafari()?"touchend":X.touchEndEvent,this.removeTapholdTimer,this)},t.prototype.removeTapholdTimer=function(){clearTimeout(this.tapHoldTimer),E.remove(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.removeTapholdTimer),E.remove(document,X.isSafari()?"touchend":X.touchEndEvent,this.removeTapholdTimer)},t.prototype.getScrollableParent=function(i,r){return m(i)?null:i[{vertical:"scrollHeight",horizontal:"scrollWidth"}[""+r]]>i[{vertical:"clientHeight",horizontal:"clientWidth"}[""+r]]&&("vertical"===r?i.scrollTop>0:i.scrollLeft>0)?("vertical"===r?(this.parentScrollY=this.parentScrollY+(0===this.parentScrollY?i.scrollTop:i.scrollTop-this.parentScrollY),this.tempScrollHeight=i.scrollHeight):(this.parentScrollX=this.parentScrollX+(0===this.parentScrollX?i.scrollLeft:i.scrollLeft-this.parentScrollX),this.tempScrollWidth=i.scrollWidth),m(i)?i:this.getScrollableParent(i.parentNode,r)):this.getScrollableParent(i.parentNode,r)},t.prototype.getScrollableValues=function(){this.parentScrollX=0,this.parentScrollY=0,this.element.classList.contains("e-dialog")&&this.element.classList.contains("e-dlg-modal"),this.getScrollableParent(this.element.parentNode,"vertical"),this.getScrollableParent(this.element.parentNode,"horizontal")},t.prototype.initialize=function(i,r){if(this.currentStateTarget=i.target,!this.isDragStarted()){if(this.isDragStarted(!0),this.externalInitialize=!1,this.target=i.currentTarget||r,this.dragProcessStarted=!1,this.abort){var s=this.abort;"string"==typeof s&&(s=[s]);for(var o=0;o=this.distance||this.externalInitialize){var p=this.getHelperElement(i);if(!p||m(p))return;r&&i.preventDefault();var f=this.helperElement=p;if(this.parentClientRect=this.calculateParentPosition(f.offsetParent),this.dragStart){var v={event:i,element:l,target:this.getProperTargetElement(i),bindEvents:ce()?this.bindDragEvents.bind(this):null,dragElement:f};this.trigger("dragStart",v)}this.dragArea?this.setDragArea():(this.dragLimit={left:0,right:0,bottom:0,top:0},this.borderWidth={top:0,left:0}),o={left:this.position.left-this.parentClientRect.left,top:this.position.top-this.parentClientRect.top},this.clone&&!this.enableTailMode&&(this.diffX=this.position.left-this.offset.left,this.diffY=this.position.top-this.offset.top),this.getScrollableValues();var y=getComputedStyle(l),S=parseFloat(y.marginTop);this.clone&&0!==S&&(o.top+=S),this.eleTop=isNaN(parseFloat(y.top))?0:parseFloat(y.top)-this.offset.top,this.enableScrollHandler&&!this.clone&&(o.top-=this.parentScrollY,o.left-=this.parentScrollX);var b=this.getProcessedPositionValue({top:o.top-this.diffY+"px",left:o.left-this.diffX+"px"});this.dragArea&&"string"!=typeof this.dragArea&&this.dragArea.classList.contains("e-kanban-content")&&"relative"===this.dragArea.style.position&&(o.top+=this.dragArea.scrollTop),this.dragElePosition={top:o.top,left:o.left},je(f,this.getDragPosition({position:"absolute",left:b.left,top:b.top})),E.remove(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.intDragStart),E.remove(document,X.isSafari()?"touchend":X.touchEndEvent,this.intDestroy),ce()||this.bindDragEvents(f)}}},t.prototype.bindDragEvents=function(i){Tr(i)?(E.add(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.intDrag,this),E.add(document,X.isSafari()?"touchend":X.touchEndEvent,this.intDragStop,this),this.setGlobalDroppables(!1,this.element,i)):(this.toggleEvents(),document.body.classList.remove("e-prevent-select"))},t.prototype.elementInViewport=function(i){for(this.top=i.offsetTop,this.left=i.offsetLeft,this.width=i.offsetWidth,this.height=i.offsetHeight;i.offsetParent;)this.top+=(i=i.offsetParent).offsetTop,this.left+=i.offsetLeft;return this.top>=window.pageYOffset&&this.left>=window.pageXOffset&&this.top+this.height<=window.pageYOffset+window.innerHeight&&this.left+this.width<=window.pageXOffset+window.innerWidth},t.prototype.getProcessedPositionValue=function(i){return this.queryPositionInfo?this.queryPositionInfo(i):i},t.prototype.calculateParentPosition=function(i){if(m(i))return{left:0,top:0};var r=i.getBoundingClientRect(),s=getComputedStyle(i);return{left:r.left+window.pageXOffset-parseInt(s.marginLeft,10),top:r.top+window.pageYOffset-parseInt(s.marginTop,10)}},t.prototype.intDrag=function(i){if(st(i.changedTouches)||1===i.changedTouches.length){var r,s;this.clone&&i.changedTouches&&X.isDevice&&X.isTouch&&i.preventDefault(),this.position=this.getMousePosition(i,this.isDragScroll);var o=this.getDocumentWidthHeight("Height");oy&&y>0?this.dragLimit.left:this.dragLimit.right+window.pageXOffset0?y-(y-this.dragLimit.right)+window.pageXOffset-M:y<0?this.dragLimit.left:y}if(this.pageY!==v||this.skipDistanceCheck){var w=d.offsetHeight+(parseFloat(b.marginTop)+parseFloat(b.marginBottom));s=this.dragLimit.top>S&&S>0?this.dragLimit.top:this.dragLimit.bottom+window.pageYOffset0?S-(S-this.dragLimit.bottom)+window.pageYOffset-w:S<0?this.dragLimit.top:S}}else r=y,s=S;var A,x,C=p+this.borderWidth.top,D=u+this.borderWidth.left;if(this.dragProcessStarted&&(m(s)&&(s=this.prevTop),m(r)&&(r=this.prevLeft)),this.helperElement.classList.contains("e-treeview"))this.dragArea?(this.dragLimit.top=this.clone?this.dragLimit.top:0,A=s-C<0?this.dragLimit.top:s-this.borderWidth.top,x=r-D<0?this.dragLimit.left:r-this.borderWidth.left):(A=s-this.borderWidth.top,x=r-this.borderWidth.left);else if(this.dragArea){var R=this.helperElement.classList.contains("e-dialog");this.dragLimit.top=this.clone?this.dragLimit.top:0,A=s-C<0?this.dragLimit.top:s-C,x=r-D<0?R?r-(D-this.borderWidth.left):this.dragElePosition.left:r-D}else A=s-C,x=r-D;var L=parseFloat(getComputedStyle(this.element).marginTop);if(L>0&&(this.clone&&(A+=L,S<0&&(L+S>=0?A=L+S:A-=L),this.dragArea&&(A=this.dragLimit.bottom=0){var O=this.dragLimit.top+S-C;O+L+C<0?A-=L+C:A=O}else A-=L+C;this.dragArea&&this.helperElement.classList.contains("e-treeview")&&(A=A+(w=d.offsetHeight+(parseFloat(b.marginTop)+parseFloat(b.marginBottom)))>this.dragLimit.bottom?this.dragLimit.bottom-w:A),this.enableScrollHandler&&!this.clone&&(A-=this.parentScrollY,x-=this.parentScrollX),this.dragArea&&"string"!=typeof this.dragArea&&this.dragArea.classList.contains("e-kanban-content")&&"relative"===this.dragArea.style.position&&(A+=this.dragArea.scrollTop);var N=this.getProcessedPositionValue({top:A+"px",left:x+"px"});this.isPreventScroll&&(N=this.getProcessedPositionValue({top:this.position.top-this.parentClientRect.top-2+"px",left:this.position.left-this.parentClientRect.left-2+"px"})),je(d,this.getDragPosition(N)),!this.elementInViewport(d)&&this.enableAutoScroll&&!this.helperElement.classList.contains("e-treeview")&&this.helperElement.scrollIntoView();var T=document.querySelectorAll(":hover");if(this.enableAutoScroll&&this.helperElement.classList.contains("e-treeview")){0===T.length&&(T=this.getPathElements(i));var P=this.getScrollParent(T,!1);this.elementInViewport(this.helperElement)?this.getScrollPosition(P,A):this.elementInViewport(this.helperElement)||(0===(T=[].slice.call(document.querySelectorAll(":hover"))).length&&(T=this.getPathElements(i)),P=this.getScrollParent(T,!0),this.getScrollPosition(P,A))}this.dragProcessStarted=!0,this.prevLeft=r,this.prevTop=s,this.position.left=r,this.position.top=s,this.pageX=g,this.pageY=v}},t.prototype.getScrollParent=function(i,r){for(var o,s=r?i.reverse():i,a=s.length-1;a>=0;a--)if(("auto"===(o=window.getComputedStyle(s[parseInt(a.toString(),10)])["overflow-y"])||"scroll"===o)&&s[parseInt(a.toString(),10)].scrollHeight>s[parseInt(a.toString(),10)].clientHeight)return s[parseInt(a.toString(),10)];if("visible"===(o=window.getComputedStyle(document.scrollingElement)["overflow-y"]))return document.scrollingElement.style.overflow="auto",document.scrollingElement},t.prototype.getScrollPosition=function(i,r){if(i&&i===document.scrollingElement)i.clientHeight+document.scrollingElement.scrollTop-this.helperElement.clientHeightr?i.scrollTop+=this.helperElement.clientHeight:i.scrollTop>r-this.helperElement.clientHeight&&(i.scrollTop-=this.helperElement.clientHeight);else if(i&&i!==document.scrollingElement){var s=document.scrollingElement.scrollTop,o=this.helperElement.clientHeight;i.clientHeight+i.getBoundingClientRect().top-o+sr-o-s&&(i.scrollTop-=this.helperElement.clientHeight)}},t.prototype.getPathElements=function(i){return document.elementsFromPoint(i.clientX>0?i.clientX:0,i.clientY>0?i.clientY:0)},t.prototype.triggerOutFunction=function(i,r){this.hoverObject.instance.intOut(i,r.target),this.hoverObject.instance.dragData[this.scope]=null,this.hoverObject=null},t.prototype.getDragPosition=function(i){var r=ze({},i);return this.axis&&("x"===this.axis?delete r.top:"y"===this.axis&&delete r.left),r},t.prototype.getDocumentWidthHeight=function(i){var r=document.body,s=document.documentElement;return Math.max(r["scroll"+i],s["scroll"+i],r["offset"+i],s["offset"+i],s["client"+i])},t.prototype.intDragStop=function(i){if(this.dragProcessStarted=!1,st(i.changedTouches)||1===i.changedTouches.length){if(-1!==["touchend","pointerup","mouseup"].indexOf(i.type)){if(this.dragStop){var s=this.getProperTargetElement(i);this.trigger("dragStop",{event:i,element:this.element,target:s,helper:this.helperElement})}this.intDestroy(i)}else this.element.setAttribute("aria-grabbed","false");var o=this.checkTargetElement(i);o.target&&o.instance&&(o.instance.dragStopCalled=!0,o.instance.dragData[this.scope]=this.droppables[this.scope],o.instance.intDrop(i,o.target)),this.setGlobalDroppables(!0),document.body.classList.remove("e-prevent-select")}},t.prototype.intDestroy=function(i){this.dragProcessStarted=!1,this.toggleEvents(),document.body.classList.remove("e-prevent-select"),this.element.setAttribute("aria-grabbed","false"),E.remove(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.intDragStart),E.remove(document,X.isSafari()?"touchend":X.touchEndEvent,this.intDragStop),E.remove(document,X.isSafari()?"touchend":X.touchEndEvent,this.intDestroy),E.remove(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.intDrag),this.isDragStarted()&&this.isDragStarted(!0)},t.prototype.onPropertyChanged=function(i,r){},t.prototype.getModuleName=function(){return"draggable"},t.prototype.isDragStarted=function(i){return i&&(MC.isDragged=!MC.isDragged),MC.isDragged},t.prototype.setDragArea=function(){var i,r,a,s=0,o=0;if(a="string"==typeof this.dragArea?U(this.dragArea):this.dragArea){var h=a.getBoundingClientRect();i=a.scrollWidth?a.scrollWidth:h.right-h.left,r=a.scrollHeight?this.dragArea&&!m(this.helperElement)&&this.helperElement.classList.contains("e-treeview")?a.clientHeight:a.scrollHeight:h.bottom-h.top;for(var c=["Top","Left","Bottom","Right"],d=getComputedStyle(a),u=0;u12;return D0(i.target,this.helperElement)||-1!==i.type.indexOf("touch")||a?(this.helperElement.style.pointerEvents="none",s=document.elementFromPoint(r.clientX,r.clientY),this.helperElement.style.pointerEvents=o):s=i.target,s},t.prototype.currentStateCheck=function(i,r){return m(this.currentStateTarget)||this.currentStateTarget===i?m(r)?i:r:this.currentStateTarget},t.prototype.getMousePosition=function(i,r){var a,l,s=void 0!==i.srcElement?i.srcElement:i.target,o=this.getCoordinates(i),h=m(s.offsetParent);if(r?(a=this.clone?o.pageX:o.pageX+(h?0:s.offsetParent.scrollLeft)-this.relativeXPosition,l=this.clone?o.pageY:o.pageY+(h?0:s.offsetParent.scrollTop)-this.relativeYPosition):(a=this.clone?o.pageX:o.pageX+window.pageXOffset-this.relativeXPosition,l=this.clone?o.pageY:o.pageY+window.pageYOffset-this.relativeYPosition),document.scrollingElement&&!r&&!this.clone){var c=document.scrollingElement;a=c.scrollWidth>0&&c.scrollWidth>c.clientWidth&&c.scrollLeft>0?a-c.scrollLeft:a,l=c.scrollHeight>0&&c.scrollHeight>c.clientHeight&&c.scrollTop>0?l-c.scrollTop:l}return{left:a-(this.margin.left+this.cursorAt.left),top:l-(this.margin.top+this.cursorAt.top)}},t.prototype.getCoordinates=function(i){return i.type.indexOf("touch")>-1?i.changedTouches[0]:i},t.prototype.getHelperElement=function(i){var r;return this.clone?this.helper?r=this.helper({sender:i,element:this.target}):(r=mi("div",{className:"e-drag-helper e-block-touch",innerHTML:"Draggable"}),document.body.appendChild(r)):r=this.element,r},t.prototype.setGlobalDroppables=function(i,r,s){this.droppables[this.scope]=i?null:{draggable:r,helper:s,draggedElement:this.element}},t.prototype.checkTargetElement=function(i){var r=this.getProperTargetElement(i),s=this.getDropInstance(r);if(!s&&r&&!m(r.parentNode)){var o=J(r.parentNode,".e-droppable")||r.parentElement;o&&(s=this.getDropInstance(o))}return{target:r,instance:s}},t.prototype.getDropInstance=function(i){var s,o=i&&i.ej2_instances;if(o)for(var a=0,l=o;a=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},lR=function(n){function t(e,i){var r=n.call(this,i,e)||this;return r.mouseOver=!1,r.dragData={},r.dragStopCalled=!1,r.bind(),r}return sZ(t,n),t.prototype.bind=function(){this.wireEvents()},t.prototype.wireEvents=function(){E.add(this.element,X.isSafari()?"touchend":X.touchEndEvent,this.intDrop,this)},t.prototype.onPropertyChanged=function(e,i){},t.prototype.getModuleName=function(){return"droppable"},t.prototype.intOver=function(e,i){this.mouseOver||(this.trigger("over",{event:e,target:i,dragData:this.dragData[this.scope]}),this.mouseOver=!0)},t.prototype.intOut=function(e,i){this.mouseOver&&(this.trigger("out",{evt:e,target:i}),this.mouseOver=!1)},t.prototype.intDrop=function(e,i){if(this.dragStopCalled){this.dragStopCalled=!1;var a,r=!0,s=this.dragData[this.scope],o=!!s&&s.helper&&Tr(s.helper);o&&(a=this.isDropArea(e,s.helper,i),this.accept&&(r=mC(s.helper,this.accept))),o&&this.drop&&a.canDrop&&r&&this.trigger("drop",{event:e,target:a.target,droppedElement:s.helper,dragData:s}),this.mouseOver=!1}},t.prototype.isDropArea=function(e,i,r){var s={canDrop:!0,target:r||e.target},o="touchend"===e.type;if(o||s.target===i){i.style.display="none";var a=o?e.changedTouches[0]:e,l=document.elementFromPoint(a.clientX,a.clientY);s.canDrop=!1,s.canDrop=D0(l,this.element),s.canDrop&&(s.target=l),i.style.display=""}return s},t.prototype.destroy=function(){E.remove(this.element,X.isSafari()?"touchend":X.touchEndEvent,this.intDrop),n.prototype.destroy.call(this)},hp([I()],t.prototype,"accept",void 0),hp([I("default")],t.prototype,"scope",void 0),hp([H()],t.prototype,"drop",void 0),hp([H()],t.prototype,"over",void 0),hp([H()],t.prototype,"out",void 0),hp([Ft],t)}(hh),ho=function(){function n(t,e,i){this.controlName=t,this.localeStrings=e,this.setLocale(i||"en-US")}return n.prototype.setLocale=function(t){var e=this.intGetControlConstant(n.locale,t);this.currentLocale=e||this.localeStrings},n.load=function(t){this.locale=ze(this.locale,t,{},!0)},n.prototype.getConstant=function(t){return m(this.currentLocale[""+t])?this.localeStrings[""+t]||"":this.currentLocale[""+t]},n.prototype.intGetControlConstant=function(t,e){return t[""+e]?t[""+e][this.controlName]:null},n.locale={},n}(),hR=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),dh=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},lZ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return hR(t,n),dh([I(50)],t.prototype,"swipeThresholdDistance",void 0),t}(Ee),hZ=/(Up|Down)/,Fs=function(n){function t(e,i){var r=n.call(this,i,e)||this;return r.touchAction=!0,r.tapCount=0,r.startEvent=function(s){if(!0===r.touchAction){var o=r.updateChangeTouches(s);void 0!==s.changedTouches&&(r.touchAction=!1),r.isTouchMoved=!1,r.movedDirection="",r.startPoint=r.lastMovedPoint={clientX:o.clientX,clientY:o.clientY},r.startEventData=o,r.hScrollLocked=r.vScrollLocked=!1,r.tStampStart=Date.now(),r.timeOutTapHold=setTimeout(function(){r.tapHoldEvent(s)},r.tapHoldThreshold),E.add(r.element,X.touchMoveEvent,r.moveEvent,r),E.add(r.element,X.touchEndEvent,r.endEvent,r),E.add(r.element,X.touchCancelEvent,r.cancelEvent,r)}},r.moveEvent=function(s){var o=r.updateChangeTouches(s);r.movedPoint=o,r.isTouchMoved=!(o.clientX===r.startPoint.clientX&&o.clientY===r.startPoint.clientY);var a={};r.isTouchMoved&&(clearTimeout(r.timeOutTapHold),r.calcScrollPoints(s),a=ze(a,{},{startEvents:r.startEventData,originalEvent:s,startX:r.startPoint.clientX,startY:r.startPoint.clientY,distanceX:r.distanceX,distanceY:r.distanceY,scrollDirection:r.scrollDirection,velocity:r.getVelocity(o)}),r.trigger("scroll",a),r.lastMovedPoint={clientX:o.clientX,clientY:o.clientY})},r.cancelEvent=function(s){clearTimeout(r.timeOutTapHold),clearTimeout(r.timeOutTap),r.tapCount=0,r.swipeFn(s),E.remove(r.element,X.touchCancelEvent,r.cancelEvent)},r.endEvent=function(s){r.swipeFn(s),r.isTouchMoved||"function"==typeof r.tap&&(r.trigger("tap",{originalEvent:s,tapCount:++r.tapCount}),r.timeOutTap=setTimeout(function(){r.tapCount=0},r.tapThreshold)),r.modeclear()},r.swipeFn=function(s){clearTimeout(r.timeOutTapHold),clearTimeout(r.timeOutTap);var o=r.updateChangeTouches(s),a=o.clientX-r.startPoint.clientX,l=o.clientY-r.startPoint.clientY;a=Math.floor(a<0?-1*a:a),l=Math.floor(l<0?-1*l:a),r.isTouchMoved=a>1||l>1,/Firefox/.test(X.userAgent)&&0===o.clientX&&0===o.clientY&&"mouseup"===s.type&&(r.isTouchMoved=!1),r.endPoint=o,r.calcPoints(s);var c={originalEvent:s,startEvents:r.startEventData,startX:r.startPoint.clientX,startY:r.startPoint.clientY,distanceX:r.distanceX,distanceY:r.distanceY,swipeDirection:r.movedDirection,velocity:r.getVelocity(o)};if(r.isTouchMoved){var d=r.swipeSettings.swipeThresholdDistance,u=ze(void 0,r.defaultArgs,c),p=!1,f=r.element,g=r.isScrollable(f),v=hZ.test(r.movedDirection);(dthis.distanceY?i.clientX>this.startPoint.clientX?"Right":"Left":i.clientYthis.distanceY||!0===this.hScrollLocked)&&!1===this.vScrollLocked?(this.scrollDirection=i.clientX>this.lastMovedPoint.clientX?"Right":"Left",this.hScrollLocked=!0):(this.scrollDirection=i.clientY=e[r[0]+s[0]]},t.prototype.updateChangeTouches=function(e){return e.changedTouches&&0!==e.changedTouches.length?e.changedTouches[0]:e},dh([H()],t.prototype,"tap",void 0),dh([H()],t.prototype,"tapHold",void 0),dh([H()],t.prototype,"swipe",void 0),dh([H()],t.prototype,"scroll",void 0),dh([I(350)],t.prototype,"tapThreshold",void 0),dh([I(750)],t.prototype,"tapHoldThreshold",void 0),dh([re({},lZ)],t.prototype,"swipeSettings",void 0),dh([Ft],t)}(hh),cZ=new RegExp("\\n|\\r|\\s\\s+","g"),dZ=new RegExp(/'|"/g),uZ=new RegExp("if ?\\("),pZ=new RegExp("else if ?\\("),cR=new RegExp("else"),fZ=new RegExp("for ?\\("),dR=new RegExp("(/if|/for)"),gZ=new RegExp("\\((.*)\\)",""),wC=new RegExp("^[0-9]+$","g"),vZ=new RegExp("[\\w\"'.\\s+]+","g"),mZ=new RegExp('"(.*?)"',"g"),yZ=new RegExp("[\\w\"'@#$.\\s-+]+","g"),uR=new RegExp("\\${([^}]*)}","g"),SZ=/^\..*/gm,CC=/\\/gi,IZ=/\\\\/gi,bZ=new RegExp("[\\w\"'@#$.\\s+]+","g"),MZ=/\window\./gm;function cp(n,t,e,i,r){return!t||wC.test(n)||-1!==i.indexOf(n.split(".")[0])||r||"true"===n||"false"===n?n:e+"."+n}function EC(n,t,e,i){return t&&!wC.test(n)&&-1===i.indexOf(n.split(".")[0])?e+'["'+n:n}function pR(n){return n.match(IZ)?n:n.replace(CC,"\\\\")}function fR(n,t,e,i){if(n=n.trim(),/\window\./gm.test(n))return n;var s=/'|"/gm;return/@|\$|#/gm.test(n)&&(n=EC(n,-1===e.indexOf(n),t,e)+'"]'),SZ.test(n)?function EZ(n,t,e,i){return!t||wC.test(n)||-1!==i.indexOf(n.split(".")[0])||/^\..*/gm.test(n)?n:e+"."+n}(n,!s.test(n)&&-1===e.indexOf(n),t,e):cp(n,!s.test(n)&&-1===e.indexOf(n),t,e,i)}var DZ=/^[\n\r.]+0&&t.forEach(function(e){he(e)})},n.removeJsEvents=function(){var t=this.wrapElement.querySelectorAll("["+vR.join("],[")+"]");t.length>0&&t.forEach(function(e){vR.forEach(function(i){e.hasAttribute(i)&&e.removeAttribute(i)})})},n.removeXssAttrs=function(){var t=this;this.removeAttrs.forEach(function(e,i){var r=t.wrapElement.querySelectorAll(e.selector);r.length>0&&r.forEach("a[href]"===e.selector?function(s){-1!==s.getAttribute(e.attribute).replace(/\t|\s|&/,"").indexOf("javascript:alert")&&s.removeAttribute(e.attribute)}:function(s){s.removeAttribute(e.attribute)})})},n}();function PZ(n){return function(t){!function kZ(n,t){t.forEach(function(e){Object.getOwnPropertyNames(e.prototype).forEach(function(i){(!Object.prototype.hasOwnProperty.call(n.prototype,i)||e.isFormBase&&"constructor"!==i)&&(n.prototype["".concat(i)]=e.prototype["".concat(i)])})})}(t,n)}}function mR(n,t,e){var i={};if(n&&n.length){for(var r=0,s=n;r"u"||(y.innerHTML=v.innerHTML?v.innerHTML:"",void 0!==v.className&&(y.className=v.className),void 0!==v.id&&(y.id=v.id),void 0!==v.styles&&y.setAttribute("style",v.styles),void 0!==e.ngAttr&&y.setAttribute(e.ngAttr,""),void 0!==v.attrs&&Fe(y,v.attrs)),y};for(var i=0,r=e.tags;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s}function jZ(n){for(var t,e=n.childNodes,i=0;i"u"&&(c["".concat(o)]=[]),c["".concat(o)].push(h),h.rootNodes}}});var ml,cd,gh,Wg,ac,uo,YZ=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),La=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Jo_RTL=(new Ng,"e-rtl"),ys=function(n){function t(e,i){return n.call(this,e,i)||this}return YZ(t,n),t.prototype.preRender=function(){},t.prototype.render=function(){this.initialize(),this.removeRippleEffect=function ms(n,t,e){var i=function q$(n){return{selector:n&&n.selector?n.selector:null,ignore:n&&n.ignore?n.ignore:null,rippleFlag:n&&n.rippleFlag,isCenterRipple:n&&n.isCenterRipple,duration:n&&n.duration?n.duration:350}}(t);return!1===i.rippleFlag||void 0===i.rippleFlag&&!Zo?function(){}:(n.setAttribute("data-ripple","true"),E.add(n,"mousedown",Zz,{parent:n,rippleOptions:i}),E.add(n,"mouseup",Jz,{parent:n,rippleOptions:i,done:e}),E.add(n,"mouseleave",ap,{parent:n,rippleOptions:i}),X.isPointer&&E.add(n,"transitionend",ap,{parent:n,rippleOptions:i}),function(){n.removeAttribute("data-ripple"),E.remove(n,"mousedown",Zz),E.remove(n,"mouseup",Jz),E.remove(n,"mouseleave",ap),E.remove(n,"transitionend",ap)})}(this.element,{selector:".e-btn"}),this.renderComplete()},t.prototype.initialize=function(){if(this.cssClass&&V([this.element],this.cssClass.replace(/\s+/g," ").trim().split(" ")),this.isPrimary&&this.element.classList.add("e-primary"),!ce()||ce()&&"progress-btn"!==this.getModuleName()){if(this.content){var e=this.enableHtmlSanitizer?Ti.sanitize(this.content):this.content;this.element.innerHTML=e}this.setIconCss()}this.enableRtl&&this.element.classList.add(Jo_RTL),this.disabled?this.controlStatus(this.disabled):this.wireEvents()},t.prototype.controlStatus=function(e){this.element.disabled=e},t.prototype.setIconCss=function(){if(this.iconCss){var e=this.createElement("span",{className:"e-btn-icon "+this.iconCss});this.element.textContent.trim()?(e.classList.add("e-icon-"+this.iconPosition.toLowerCase()),("Top"===this.iconPosition||"Bottom"===this.iconPosition)&&this.element.classList.add("e-"+this.iconPosition.toLowerCase()+"-icon-btn")):this.element.classList.add("e-icon-btn");var i=this.element.childNodes[0];!i||"Left"!==this.iconPosition&&"Top"!==this.iconPosition?this.element.appendChild(e):this.element.insertBefore(e,i)}},t.prototype.wireEvents=function(){this.isToggle&&E.add(this.element,"click",this.btnClickHandler,this)},t.prototype.unWireEvents=function(){this.isToggle&&E.remove(this.element,"click",this.btnClickHandler)},t.prototype.btnClickHandler=function(){this.element.classList.contains("e-active")?this.element.classList.remove("e-active"):this.element.classList.add("e-active")},t.prototype.destroy=function(){var e=["e-primary",Jo_RTL,"e-icon-btn","e-success","e-info","e-danger","e-warning","e-flat","e-outline","e-small","e-bigger","e-active","e-round","e-top-icon-btn","e-bottom-icon-btn"];this.cssClass&&(e=e.concat(this.cssClass.split(" "))),n.prototype.destroy.call(this),K([this.element],e),this.element.getAttribute("class")||this.element.removeAttribute("class"),this.disabled&&this.element.removeAttribute("disabled"),this.content&&(this.element.innerHTML=this.element.innerHTML.replace(this.content,""));var i=this.element.querySelector("span.e-btn-icon");i&&he(i),this.unWireEvents(),Zo&&this.removeRippleEffect()},t.prototype.getModuleName=function(){return"btn"},t.prototype.getPersistData=function(){return this.addOnPersist([])},t.Inject=function(){},t.prototype.onPropertyChanged=function(e,i){for(var r=this.element.querySelector("span.e-btn-icon"),s=0,o=Object.keys(e);s=cd.width?cd.width:0;return ml.right+JR()-n}function uE(){return V0()+ml.width/2}function pE(n,t,e,i){if(void 0===t&&(t=null),void 0===e&&(e={X:!1,Y:!1}),!e.Y&&!e.X)return{left:0,top:0};var r=n.getBoundingClientRect();if(uo=t,ac=n.ownerDocument,i||(i=is(n,"left","top")),e.X){var s=uo?r4():l4(),o=yE(),a=SE(),l=o-i.left,h=i.left+r.width-a;r.width>s?i.left=l>0&&h<=0?a-r.width:h>0&&l<=0?o:l>h?a-r.width:o:l>0?i.left+=l:h>0&&(i.left-=h)}if(e.Y){var c=uo?n4():a4(),d=mE(),u=IE(),p=d-i.top,f=i.top+r.height-u;r.height>c?i.top=p>0&&f<=0?u-r.height:f>0&&p<=0?d:p>f?u-r.height:d:p>0?i.top+=p:f>0&&(i.top-=f)}return i}function lc(n,t,e,i){void 0===t&&(t=null);var r=is(n,"left","top");e&&(r.left=e),i&&(r.top=i);var s=[];uo=t,ac=n.ownerDocument;var o=n.getBoundingClientRect(),l=r.left,h=r.left+o.width,d=vE(r.top,r.top+o.height),u=e4(l,h);return d.topSide&&s.push("top"),u.rightSide&&s.push("right"),u.leftSide&&s.push("left"),d.bottomSide&&s.push("bottom"),s}function bJ(n,t,e,i,r,s,o,a,l){if(void 0===o&&(o=null),void 0===a&&(a={X:!0,Y:!0}),t&&n&&r&&s&&(a.X||a.Y)){var d,h={TL:null,TR:null,BL:null,BR:null},c={TL:null,TR:null,BL:null,BR:null};if("none"===window.getComputedStyle(n).display){var u=n.style.visibility;n.style.visibility="hidden",n.style.display="block",d=n.getBoundingClientRect(),n.style.removeProperty("display"),n.style.visibility=u}else d=n.getBoundingClientRect();var p={posX:r,posY:s,offsetX:e,offsetY:i,position:{left:0,top:0}};uo=o,ac=t.ownerDocument,function wJ(n,t,e,i,r){e.position=is(n,e.posX,e.posY,i,r),t.TL=is(n,"left","top",i,r),t.TR=is(n,"right","top",i,r),t.BR=is(n,"left","bottom",i,r),t.BL=is(n,"right","bottom",i,r)}(t,h,p,l,d),gE(c,p,d),a.X&&t4(t,c,h,p,d,!0),a.Y&&h.TL.top>-1&&i4(t,c,h,p,d,!0),function MJ(n,t,e){var i=0,r=0;if(null!=n.offsetParent&&("absolute"===getComputedStyle(n.offsetParent).position||"relative"===getComputedStyle(n.offsetParent).position)){var s=is(n.offsetParent,"left","top",!1,e);i=s.left,r=s.top}var o=1,a=1,l=KR(n);if(l){var h=getComputedStyle(l).transform;if("none"!==h){var c=new DOMMatrix(h);o=c.a,a=c.d}if("none"!==getComputedStyle(l).zoom){var u=fE(document.body);o*=u,a*=u}}n.style.top=t.position.top/a+t.offsetY-r/a+"px",n.style.left=t.position.left/o+t.offsetX-i/o+"px"}(n,p,d)}}function fE(n){var t=getComputedStyle(n).zoom;return parseFloat(t)||1}function KR(n){for(;n;){var t=window.getComputedStyle(n).transform,e=fE(document.body);if(t&&"none"!==t||e&&1!==e)return n;if(n===document.body)return null;n=n.offsetParent||n.parentElement}return null}function gE(n,t,e){n.TL={top:t.position.top+t.offsetY,left:t.position.left+t.offsetX},n.TR={top:n.TL.top,left:n.TL.left+e.width},n.BL={top:n.TL.top+e.height,left:n.TL.left},n.BR={top:n.TL.top+e.height,left:n.TL.left+e.width}}function e4(n,t){var e=!1,i=!1;return n-Y0()SE()&&(i=!0),{leftSide:e,rightSide:i}}function t4(n,t,e,i,r,s){var o=e4(t.TL.left,t.TR.left),a=vE(t.TL.top,t.BL.top);e.TL.left-Y0()<=yE()&&(o.leftSide=!1),e.TR.left>SE()&&(o.rightSide=!1),(o.leftSide&&!o.rightSide||!o.leftSide&&o.rightSide)&&(i.posX="right"===i.posX?"left":"right",i.offsetX=i.offsetX+r.width,i.offsetX=-1*i.offsetX,i.position=is(n,i.posX,i.posY,!1),gE(t,i,r),s&&t4(n,t,e,i,r,!1),!o.leftSide&&o.rightSide&&a.bottomSide&&(i.offsetX=0))}function i4(n,t,e,i,r,s){var o=vE(t.TL.top,t.BL.top);e.TL.top-W0()<=mE()&&(o.topSide=!1),e.BL.top>=IE()&&n.getBoundingClientRect().bottomIE()&&(i=!0),{topSide:e,bottomSide:i}}function r4(){return uo.getBoundingClientRect().width}function n4(){return uo.getBoundingClientRect().height}function s4(){return uo.getBoundingClientRect().left}function o4(){return uo.getBoundingClientRect().top}function mE(){return uo?o4():0}function yE(){return uo?s4():0}function SE(){return uo?Y0()+s4()+r4():Y0()+l4()}function IE(){return uo?W0()+o4()+n4():W0()+a4()}function W0(){return ac.documentElement.scrollTop||ac.body.scrollTop}function Y0(){return ac.documentElement.scrollLeft||ac.body.scrollLeft}function a4(){return window.innerHeight}function l4(){var n=window.innerWidth,t=document.documentElement.getBoundingClientRect();return n-(n-(m(document.documentElement)?0:t.width))}function h4(){uo=null,ac=null}var c4=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),bn=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},d4=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return c4(t,n),bn([I("left")],t.prototype,"X",void 0),bn([I("top")],t.prototype,"Y",void 0),t}(Ee),Gn_OPEN="e-popup-open",Gn_CLOSE="e-popup-close",hc=function(n){function t(e,i){return n.call(this,i,e)||this}return c4(t,n),t.prototype.onPropertyChanged=function(e,i){for(var r=0,s=Object.keys(e);r0&&c.left>0&&c.right>0&&c.bottom>0}var s=i.getBoundingClientRect();return!(r.bottoms.bottom||r.right>s.right||r.leftr.top?this.element.style.top="0px":s.bottomr.left&&(this.element.style.left=parseInt(this.element.style.left,10)+(s.left-r.left)+"px"))}},t.prototype.checkCollision=function(){var e=this.collision.X,i=this.collision.Y;"none"===e&&"none"===i||("flip"===e&&"flip"===i?this.callFlip({X:!0,Y:!0}):"fit"===e&&"fit"===i?this.callFit({X:!0,Y:!0}):("flip"===e?this.callFlip({X:!0,Y:!1}):"flip"===i&&this.callFlip({Y:!0,X:!1}),"fit"===e?this.callFit({X:!0,Y:!1}):"fit"===i&&this.callFit({X:!1,Y:!0})))},t.prototype.show=function(e,i){var r=this;if(this.getRelateToElement().classList.contains("e-filemanager")&&(this.fmDialogContainer=this.element.getElementsByClassName("e-file-select-wrap")[0]),this.wireEvents(),!m(this.fmDialogContainer)&&X.isIos&&(this.fmDialogContainer.style.display="block"),1e3===this.zIndex||!m(i)){var o=m(i)?this.element:i;this.zIndex=cc(o),je(this.element,{zIndex:this.zIndex})}e=m(e)||"object"!=typeof e?this.showAnimation:e,("none"!==this.collision.X||"none"!==this.collision.Y)&&(K([this.element],Gn_CLOSE),V([this.element],Gn_OPEN),this.checkCollision(),K([this.element],Gn_OPEN),V([this.element],Gn_CLOSE)),m(e)?(K([this.element],Gn_CLOSE),V([this.element],Gn_OPEN),this.trigger("open")):(e.begin=function(){r.isDestroyed||(K([r.element],Gn_CLOSE),V([r.element],Gn_OPEN))},e.end=function(){r.isDestroyed||r.trigger("open")},new Hs(e).animate(this.element))},t.prototype.hide=function(e){var i=this;e=m(e)||"object"!=typeof e?this.hideAnimation:e,m(e)?(K([this.element],Gn_OPEN),V([this.element],Gn_CLOSE),this.trigger("close")):(e.end=function(){i.isDestroyed||(K([i.element],Gn_OPEN),V([i.element],Gn_CLOSE),i.trigger("close"))},new Hs(e).animate(this.element)),this.unwireEvents()},t.prototype.getScrollableParent=function(e){return this.checkFixedParent(e),function bE(n,t){for(var e=getComputedStyle(n),i=[],r=/(auto|scroll)/,s=n.parentElement;s&&"HTML"!==s.tagName;){var o=getComputedStyle(s);!("absolute"===e.position&&"static"===o.position)&&r.test(o.overflow+o.overflowY+o.overflowX)&&i.push(s),s=s.parentElement}return t||i.push(document),i}(e,this.fixedParent)},t.prototype.checkFixedParent=function(e){for(var i=e.parentElement;i&&"HTML"!==i.tagName;){var r=getComputedStyle(i);("fixed"===r.position||"sticky"===r.position)&&!m(this.element)&&this.element.offsetParent&&"BODY"===this.element.offsetParent.tagName&&"hidden"!==getComputedStyle(this.element.offsetParent).overflow&&(this.element.style.top=window.scrollY>parseInt(this.element.style.top,10)?Re(window.scrollY-parseInt(this.element.style.top,10)):Re(parseInt(this.element.style.top,10)-window.scrollY),this.element.style.position="fixed",this.fixedParent=!0),i=i.parentElement,!m(this.element)&&m(this.element.offsetParent)&&"fixed"===r.position&&"fixed"===this.element.style.position&&(this.fixedParent=!0)}},bn([I("auto")],t.prototype,"height",void 0),bn([I("auto")],t.prototype,"width",void 0),bn([I(null)],t.prototype,"content",void 0),bn([I("container")],t.prototype,"targetType",void 0),bn([I(null)],t.prototype,"viewPortElement",void 0),bn([I({X:"none",Y:"none"})],t.prototype,"collision",void 0),bn([I("")],t.prototype,"relateTo",void 0),bn([re({},d4)],t.prototype,"position",void 0),bn([I(0)],t.prototype,"offsetX",void 0),bn([I(0)],t.prototype,"offsetY",void 0),bn([I(1e3)],t.prototype,"zIndex",void 0),bn([I(!1)],t.prototype,"enableRtl",void 0),bn([I("reposition")],t.prototype,"actionOnScroll",void 0),bn([I(null)],t.prototype,"showAnimation",void 0),bn([I(null)],t.prototype,"hideAnimation",void 0),bn([H()],t.prototype,"open",void 0),bn([H()],t.prototype,"close",void 0),bn([H()],t.prototype,"targetExitViewport",void 0),bn([Ft],t)}(yi);function cc(n){for(var t=n.parentElement,e=[];t&&"BODY"!==t.tagName;){var i=document.defaultView.getComputedStyle(t,null).getPropertyValue("z-index"),r=document.defaultView.getComputedStyle(t,null).getPropertyValue("position");"auto"!==i&&"static"!==r&&e.push(i),t=t.parentElement}for(var s=[],o=0;o2147483647?2147483647:c}var _i,Oa,dp,yh,EE,Sh,$t,Ih,ME=["north-west","north","north-east","west","east","south-west","south","south-east"],Yg="e-resize-handle",dc="e-focused-handle",CJ="e-dlg-resizable",u4=["e-restrict-left"],p4="e-resize-viewport",EJ=["north","west","east","south"],wE=0,CE=0,f4=0,g4=0,Qg=0,Gg=0,Xg=null,DE=null,xE=null,Q0=!0,v4=0,TE=!0;function xJ(n){AE();var t=mi("span",{attrs:{unselectable:"on",contenteditable:"false"}});t.setAttribute("class","e-dialog-border-resize e-"+n),"south"===n&&(t.style.height="2px",t.style.width="100%",t.style.bottom="0px",t.style.left="0px"),"north"===n&&(t.style.height="2px",t.style.width="100%",t.style.top="0px",t.style.left="0px"),"east"===n&&(t.style.height="100%",t.style.width="2px",t.style.right="0px",t.style.top="0px"),"west"===n&&(t.style.height="100%",t.style.width="2px",t.style.left="0px",t.style.top="0px"),_i.appendChild(t)}function m4(n){var t;return m(n)||(t="string"==typeof n?document.querySelector(n):n),t}function y4(n){for(var t=n||this,e=_i.querySelectorAll("."+Yg),i=0;i-1?"mouse":"touch"}function I4(n){if(n.preventDefault(),_i=n.target.parentElement,AE(),Qg=n.pageX,Gg=n.pageY,n.target.classList.add(dc),m(Xg)||!0!==Xg(n,this)){this.targetEle&&_i&&_i.querySelector("."+CJ)&&($t="body"===this.target?null:this.targetEle,Sh=this.targetEle.clientWidth,yh=this.targetEle.clientHeight);var e=m($t)?document:$t;E.add(e,"mousemove",qg,this),E.add(document,"mouseup",G0,this);for(var i=0;i=0||s.top<0)&&(e=!0):e=!0;var a=CE+(r-Gg);a=a>dp?a:dp;var l=0;m($t)||(l=o.top);var h=m($t)?0:$t.offsetHeight-$t.clientHeight,c=s.top-l-h/2;if(c=c<0?0:c,s.top>0&&c+a>yh){if(e=!1,_i.classList.contains(p4))return;_i.style.height=yh-parseInt(c.toString(),10)+"px"}else{var d=0;if(e){s.top<0&&t+(s.height+s.top)>0&&a+(d=s.top)<=30&&(a=s.height-(s.height+s.top)+30),a+s.top>=yh&&(_i.style.height=s.height+(t-(s.height+s.top))+"px");var u=m($t)?d:c;a>=dp&&a+u<=yh&&(_i.style.height=a+"px")}}}function NE(n){var e,t=!1,i="mouse"===S4(n.type)?n.pageY:n.touches[0].pageY,r=uc(_i),s=m($t)?0:$t.offsetHeight-$t.clientHeight;m($t)||(e=uc($t)),(!m($t)&&r.top-e.top>0||m($t)&&i>0||!m($t)&&Math.floor(r.top-e.top+r.height+(e.bottom-r.bottom))-s<=yh)&&(t=!0);var o=CE-(i-Gg);if(t&&o>=dp&&o<=yh){var a=0;m($t)||(a=e.top);var l=g4-a+(i-Gg);l=l>0?l:1,_i.style.height=o+"px",_i.style.top=l+"px"}}function OE(n){var i,t=document.documentElement.clientWidth,e=!1;m($t)||(i=uc($t));var r="mouse"===S4(n.type)?n.pageX:n.touches[0].pageX,s=uc(_i),o=m($t)?0:$t.offsetWidth-$t.clientWidth,a=m($t)?0:i.left,l=m($t)?0:i.width;m(Ih)&&(m($t)?Ih=t:(Ih=s.left-a-o/2+s.width,Ih+=l-o-Ih)),(!m($t)&&Math.floor(s.left-i.left+s.width+(i.right-s.right))-o<=Sh||m($t)&&r>=0)&&(e=!0);var h=wE-(r-Qg);if(Q0&&(h=h>Ih?Ih:h),e&&h>=EE&&h<=Sh){var c=0;m($t)||(c=i.left);var d=f4-c+(r-Qg);d=d>0?d:1,h!==v4&&TE&&(_i.style.width=h+"px"),Q0&&(_i.style.left=d+"px",TE=1!==d)}v4=h}function kE(n){var i,t=document.documentElement.clientWidth,e=!1;m($t)||(i=uc($t));var s=(n.touches?n.changedTouches[0]:n).pageX,o=uc(_i);(!m($t)&&(o.left-i.left+o.width<=Sh||o.right-i.left>=o.width)||m($t)&&t-s>0)&&(e=!0);var a=wE+(s-Qg),l=0;if(m($t)||(l=i.left),o.left-l+a>Sh){if(e=!1,_i.classList.contains(p4))return;_i.style.width=Sh-(o.left-l)+"px"}e&&a>=EE&&a<=Sh&&(_i.style.width=a+"px")}function M4(){for(var n=_i.querySelectorAll("."+Yg),t=0;t=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},OJ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return PE(t,n),Zt([I(!0)],t.prototype,"isFlat",void 0),Zt([I()],t.prototype,"buttonModel",void 0),Zt([I("Button")],t.prototype,"type",void 0),Zt([H()],t.prototype,"click",void 0),t}(Ee),kJ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return PE(t,n),Zt([I("Fade")],t.prototype,"effect",void 0),Zt([I(400)],t.prototype,"duration",void 0),Zt([I(0)],t.prototype,"delay",void 0),t}(Ee),X0="e-dialog",zE="e-rtl",RE="e-dlg-header-content",w4="e-dlg-header",q0="e-footer-content",$0="e-dlg-modal",C4="e-icon-dlg-close",yl="e-dlg-target",ka="e-scroll-disabled",E4="e-device",Z0="e-dlg-fullscreen",D4="e-dlg-closeicon-btn",x4="e-popup-open",T4="Information",A4="e-scroll-disabled",L4="e-alert-dialog",N4="e-confirm-dialog",HE="e-dlg-resizable",up="e-restrict-left",O4="e-resize-viewport",BE="user action",QJ=function(n){function t(e,i){var r=n.call(this,e,i)||this;return r.needsID=!0,r}return PE(t,n),t.prototype.render=function(){this.initialize(),this.initRender(),this.wireEvents(),"100%"===this.width&&(this.element.style.width=""),""!==this.minHeight&&(this.element.style.minHeight=Re(this.minHeight)),this.enableResize&&(this.setResize(),this.isModal&&(this.isModelResize=!0),"None"===this.animationSettings.effect&&this.getMinHeight()),this.renderComplete()},t.prototype.initializeValue=function(){this.dlgClosedBy=BE},t.prototype.preRender=function(){var e=this;if(this.initializeValue(),this.headerContent=null,this.allowMaxHeight=!0,this.preventVisibility=!0,this.clonedEle=this.element.cloneNode(!0),this.closeIconClickEventHandler=function(s){e.dlgClosedBy="close icon",e.hide(s)},this.dlgOverlayClickEventHandler=function(s){e.dlgClosedBy="overlayClick",s.preventFocus=!1,e.trigger("overlayClick",s,function(o){o.preventFocus||e.focusContent(),e.dlgClosedBy=BE})},this.l10n=new ho("dialog",{close:"Close"},this.locale),this.checkPositionData(),m(this.target)){var r=this.isProtectedOnChange;this.isProtectedOnChange=!0,this.target=document.body,this.isProtectedOnChange=r}},t.prototype.updatePersistData=function(){this.enablePersistence&&this.setProperties({width:parseFloat(this.element.style.width),height:parseFloat(this.element.style.height),position:{X:parseFloat(this.dragObj.element.style.left),Y:parseFloat(this.dragObj.element.style.top)}},!0)},t.prototype.isNumberValue=function(e){return/^[-+]?\d*\.?\d+$/.test(e)},t.prototype.checkPositionData=function(){if(!m(this.position)){if(!m(this.position.X)&&"number"!=typeof this.position.X&&this.isNumberValue(this.position.X)){var i=this.isProtectedOnChange;this.isProtectedOnChange=!0,this.position.X=parseFloat(this.position.X),this.isProtectedOnChange=i}m(this.position.Y)||"number"==typeof this.position.Y||this.isNumberValue(this.position.Y)&&(i=this.isProtectedOnChange,this.isProtectedOnChange=!0,this.position.Y=parseFloat(this.position.Y),this.isProtectedOnChange=i)}},t.prototype.getEle=function(e,i){for(var r=void 0,s=0;s=0&&t[e])xJ(t[e]);else if(""!==t[e].trim()){var i=mi("div",{className:"e-icons "+Yg+" e-"+t[e]});_i.appendChild(i)}dp=n.minHeight,EE=n.minWidth,Sh=n.maxWidth,yh=n.maxHeight,n.proxy&&n.proxy.element&&n.proxy.element.classList.contains("e-dialog")?y4(n.proxy):y4()}({element:this.element,direction:r,minHeight:parseInt(e.slice(0,i.indexOf("p")),10),maxHeight:this.targetEle.clientHeight,minWidth:parseInt(i.slice(0,i.indexOf("p")),10),maxWidth:this.targetEle.clientWidth,boundary:this.target===document.body?null:this.targetEle,resizeBegin:this.onResizeStart.bind(this),resizeComplete:this.onResizeComplete.bind(this),resizing:this.onResizing.bind(this),proxy:this}),this.wireWindowResizeEvent()}else M4(),this.unWireWindowResizeEvent(),this.element.classList.remove(this.isModal?up:O4),this.element.classList.remove(HE)},t.prototype.getFocusElement=function(e){var r=e.querySelectorAll('input,select,textarea,button:enabled,a,[contenteditable="true"],[tabindex]');return{element:r[r.length-1]}},t.prototype.keyDown=function(e){var i=this;if(9===e.keyCode&&this.isModal){var r=void 0;m(this.btnObj)||(r=this.btnObj[this.btnObj.length-1]),m(this.btnObj)&&!m(this.ftrTemplateContent)&&(r=this.getFocusElement(this.ftrTemplateContent)),m(this.btnObj)&&m(this.ftrTemplateContent)&&!m(this.contentEle)&&(r=this.getFocusElement(this.contentEle)),!m(r)&&document.activeElement===r.element&&!e.shiftKey&&(e.preventDefault(),this.focusableElements(this.element).focus()),document.activeElement===this.focusableElements(this.element)&&e.shiftKey&&(e.preventDefault(),m(r)||r.element.focus())}var h,s=document.activeElement,o=["input","textarea"].indexOf(s.tagName.toLowerCase())>-1,a=!1;if(o||(a=s.hasAttribute("contenteditable")&&"true"===s.getAttribute("contenteditable")),27===e.keyCode&&this.closeOnEscape){this.dlgClosedBy="escape";var l=document.querySelector(".e-popup-open:not(.e-dialog)");!m(l)&&!l.classList.contains("e-toolbar-pop")||this.hide(e)}(13===e.keyCode&&!e.ctrlKey&&"textarea"!==s.tagName.toLowerCase()&&o&&!m(this.primaryButtonEle)||13===e.keyCode&&e.ctrlKey&&("textarea"===s.tagName.toLowerCase()||a)&&!m(this.primaryButtonEle))&&this.buttons.some(function(d,u){h=u;var p=d.buttonModel;return!m(p)&&!0===p.isPrimary})&&"function"==typeof this.buttons[h].click&&setTimeout(function(){i.buttons[h].click.call(i,e)})},t.prototype.initialize=function(){m(this.target)||(this.targetEle="string"==typeof this.target?document.querySelector(this.target):this.target),this.isBlazorServerRender()||V([this.element],X0),X.isDevice&&V([this.element],E4),this.isBlazorServerRender()||this.setCSSClass(),this.setMaxHeight()},t.prototype.initRender=function(){var e=this;if(this.initialRender=!0,this.isBlazorServerRender()||Fe(this.element,{role:"dialog"}),1e3===this.zIndex?(this.setzIndex(this.element,!1),this.calculatezIndex=!0):this.calculatezIndex=!1,this.setTargetContent(),""!==this.header&&!m(this.header)&&this.setHeader(),this.renderCloseIcon(),this.setContent(),""===this.footerTemplate||m(this.footerTemplate)?!m(this.buttons[0])&&!m(this.buttons[0].buttonModel)&&this.setButton():this.setFooterTemplate(),this.allowDragging&&!m(this.headerContent)&&this.setAllowDragging(),Fe(this.element,{"aria-modal":this.isModal?"true":"false"}),this.isModal&&this.setIsModal(),!0!==this.element.classList.contains(L4)&&!0!==this.element.classList.contains(N4)&&!m(this.element.parentElement)){var i=this.isModal?this.dlgContainer.parentElement:this.element.parentElement;this.refElement=this.createElement("div",{className:"e-dlg-ref-element"}),i.insertBefore(this.refElement,this.isModal?this.dlgContainer:this.element)}if(m(this.targetEle)||this.targetEle.appendChild(this.isModal?this.dlgContainer:this.element),this.popupObj=new hc(this.element,{height:this.height,width:this.width,zIndex:this.zIndex,relateTo:this.target,actionOnScroll:"none",enableRtl:this.enableRtl,open:function(o){var a={container:e.isModal?e.dlgContainer:e.element,element:e.element,target:e.target,preventFocus:!1};e.enableResize&&e.resetResizeIcon(),e.trigger("open",a,function(l){l.preventFocus||e.focusContent()})},close:function(o){e.isModal&&V([e.dlgOverlay],"e-fade"),e.unBindEvent(e.element),e.isModal&&(e.dlgContainer.style.display="none"),e.trigger("close",e.closeArgs);var a=document.activeElement;!m(a)&&!m(a.blur)&&a.blur(),!m(e.storeActiveElement)&&!m(e.storeActiveElement.focus)&&e.storeActiveElement.focus()}}),this.positionChange(),this.setEnableRTL(),this.isBlazorServerRender()||(V([this.element],"e-popup-close"),this.isModal&&this.setOverlayZindex()),this.visible){if(this.show(),this.isModal){var r=this.getTargetContainer(this.target);r instanceof Element&&"rtl"===window.getComputedStyle(r).getPropertyValue("direction")&&this.setPopupPosition()}}else this.isModal&&(this.dlgOverlay.style.display="none");this.initialRender=!1},t.prototype.getTargetContainer=function(e){var i=null;if("string"==typeof e)if(e.startsWith("#"))i=document.getElementById(e.substring(1));else if(e.startsWith(".")){var r=document.getElementsByClassName(e.substring(1));i=r.length>0?r[0]:null}else!(e instanceof HTMLElement)&&e!==document.body&&(i=document.querySelector(e));else e instanceof HTMLElement&&(i=e);return i},t.prototype.resetResizeIcon=function(){var e=this.getMinHeight();if(this.targetEle.offsetHeight0&&("function"==typeof this.buttons[e].click&&E.add(s[e],"click",this.buttons[e].click,this),"object"==typeof this.buttons[e].click&&E.add(s[e],"click",this.buttonClickHandler.bind(this,e),this)),!this.isBlazorServerRender()&&!m(this.ftrTemplateContent)&&(this.btnObj[e].appendTo(this.ftrTemplateContent.children[e]),this.buttons[e].isFlat&&this.btnObj[e].element.classList.add("e-flat"),this.primaryButtonEle=this.element.getElementsByClassName("e-primary")[0]))},t.prototype.buttonClickHandler=function(e){this.trigger("buttons["+e+"].click",{})},t.prototype.setContent=function(){this.contentEle=this.createElement("div",{className:"e-dlg-content",id:this.element.id+"_dialog-content"}),Fe(this.element,this.headerEle?{"aria-describedby":this.element.id+"_title "+this.element.id+"_dialog-content"}:{"aria-describedby":this.element.id+"_dialog-content"}),this.innerContentElement?this.contentEle.appendChild(this.innerContentElement):(!m(this.content)&&""!==this.content||!this.initialRender)&&(("string"!=typeof this.content||ce())&&this.content instanceof HTMLElement?this.contentEle.appendChild(this.content):this.setTemplate(this.content,this.contentEle,"content")),m(this.headerContent)?this.element.insertBefore(this.contentEle,this.element.children[0]):this.element.insertBefore(this.contentEle,this.element.children[1]),"auto"===this.height&&(!this.isBlazorServerRender()&&X.isIE&&""===this.element.style.width&&!m(this.width)&&(this.element.style.width=Re(this.width)),this.setMaxHeight())},t.prototype.setTemplate=function(e,i,r){var s,o,a;o=i.classList.contains(w4)?this.element.id+"header":i.classList.contains(q0)?this.element.id+"footerTemplate":this.element.id+"content",m(e.outerHTML)?("string"==typeof e||"string"!=typeof e||ce()&&!this.isStringTemplate)&&("string"==typeof e&&(e=this.sanitizeHelper(e)),this.isVue||"string"!=typeof e?(s=ii(e),a=e):i.innerHTML=e):i.appendChild(e);var l=[];if(!m(s)){for(var c=0,d=s({},this,r,o,!(ce()&&!this.isStringTemplate&&0===a.indexOf("
Blazor"))||this.isStringTemplate);c/g,"");(this.element.children.length>0||i)&&(this.innerContentElement=document.createDocumentFragment(),[].slice.call(this.element.childNodes).forEach(function(r){8!==r.nodeType&&e.innerContentElement.appendChild(r)}))}},t.prototype.setHeader=function(){this.headerEle?this.headerEle.innerHTML="":this.headerEle=this.createElement("div",{id:this.element.id+"_title",className:w4}),this.createHeaderContent(),this.headerContent.appendChild(this.headerEle),this.setTemplate(this.header,this.headerEle,"header"),Fe(this.element,{"aria-describedby":this.element.id+"_title"}),Fe(this.element,{"aria-labelledby":this.element.id+"_dialog-header"}),this.element.insertBefore(this.headerContent,this.element.children[0]),this.allowDragging&&!m(this.headerContent)&&this.setAllowDragging()},t.prototype.setFooterTemplate=function(){this.ftrTemplateContent?this.ftrTemplateContent.innerHTML="":this.ftrTemplateContent=this.createElement("div",{className:q0}),""===this.footerTemplate||m(this.footerTemplate)?this.ftrTemplateContent.innerHTML=this.buttonContent.join(""):this.setTemplate(this.footerTemplate,this.ftrTemplateContent,"footerTemplate"),this.element.appendChild(this.ftrTemplateContent)},t.prototype.createHeaderContent=function(){m(this.headerContent)&&(this.headerContent=this.createElement("div",{id:this.element.id+"_dialog-header",className:RE}))},t.prototype.renderCloseIcon=function(){this.showCloseIcon&&(this.closeIcon=this.createElement("button",{className:D4,attrs:{type:"button"}}),this.closeIconBtnObj=new ys({cssClass:"e-flat",iconCss:C4+" e-icons"}),this.closeIconTitle(),m(this.headerContent)?(this.createHeaderContent(),pl([this.closeIcon],this.headerContent),this.element.insertBefore(this.headerContent,this.element.children[0])):pl([this.closeIcon],this.headerContent),this.closeIconBtnObj.appendTo(this.closeIcon))},t.prototype.closeIconTitle=function(){this.l10n.setLocale(this.locale);var e=this.l10n.getConstant("close");this.closeIcon.setAttribute("title",e),this.closeIcon.setAttribute("aria-label",e)},t.prototype.setCSSClass=function(e){e&&(K([this.element],e.split(" ")),this.isModal&&!m(this.dlgContainer)&&K([this.dlgContainer],e.split(" "))),this.cssClass&&(V([this.element],this.cssClass.split(" ")),this.isModal&&!m(this.dlgContainer)&&V([this.dlgContainer],this.cssClass.split(" ")))},t.prototype.setIsModal=function(){this.dlgContainer=this.createElement("div",{className:"e-dlg-container"}),this.setCSSClass(),this.element.classList.remove(x4),this.element.parentNode.insertBefore(this.dlgContainer,this.element),this.dlgContainer.appendChild(this.element),V([this.element],$0),this.dlgOverlay=this.createElement("div",{className:"e-dlg-overlay"}),this.dlgOverlay.style.zIndex=(this.zIndex-1).toString(),this.dlgContainer.appendChild(this.dlgOverlay)},t.prototype.getValidFocusNode=function(e){for(var i,r=0;r0||"a"===i.tagName.toLowerCase()&&i.hasAttribute("href"))&&i.tabIndex>-1&&!i.disabled&&!this.disableElement(i,'[disabled],[aria-disabled="true"],[type="hidden"]'))return i;i=null}return i},t.prototype.focusableElements=function(e){if(!m(e)){var r=e.querySelectorAll('input,select,textarea,button,a,[contenteditable="true"],[tabindex]');return this.getValidFocusNode(r)}return null},t.prototype.getAutoFocusNode=function(e){var i=e.querySelector("."+D4),s=e.querySelectorAll("[autofocus]"),o=this.getValidFocusNode(s);if(ce()&&(this.primaryButtonEle=this.element.getElementsByClassName("e-primary")[0]),m(o)){if(!m(o=this.focusableElements(this.contentEle)))return o;if(!m(this.primaryButtonEle))return this.element.querySelector(".e-primary")}else i=o;return i},t.prototype.disableElement=function(e,i){var r=e?e.matches||e.webkitMatchesSelector||e.msGetRegionContent:null;if(r)for(;e;e=e.parentNode)if(e instanceof Element&&r.call(e,i))return e;return null},t.prototype.focusContent=function(){var e=this.getAutoFocusNode(this.element),i=m(e)?this.element:e,r=X.userAgent;(r.indexOf("MSIE ")>0||r.indexOf("Trident/")>0)&&this.element.focus(),i.focus(),this.unBindEvent(this.element),this.bindEvent(this.element)},t.prototype.bindEvent=function(e){E.add(e,"keydown",this.keyDown,this)},t.prototype.unBindEvent=function(e){E.remove(e,"keydown",this.keyDown)},t.prototype.updateSanitizeContent=function(){this.isBlazorServerRender()||(this.contentEle.innerHTML=this.sanitizeHelper(this.content))},t.prototype.isBlazorServerRender=function(){return ce()&&this.isServerRendered},t.prototype.getModuleName=function(){return"dialog"},t.prototype.onPropertyChanged=function(e,i){if(this.element.classList.contains(X0))for(var r=0,s=Object.keys(e);r0?this.showCloseIcon||""!==this.header&&!m(this.header)?this.showCloseIcon||he(this.closeIcon):(he(this.headerContent),this.headerContent=null):(this.renderCloseIcon(),this.wireEvents());break;case"locale":this.showCloseIcon&&this.closeIconTitle();break;case"visible":this.visible?this.show():this.hide();break;case"isModal":this.updateIsModal();break;case"height":je(this.element,{height:Re(e.height)}),this.updatePersistData();break;case"width":je(this.element,{width:Re(e.width)}),this.updatePersistData();break;case"zIndex":this.popupObj.zIndex=this.zIndex,this.isModal&&this.setOverlayZindex(this.zIndex),this.element.style.zIndex!==this.zIndex.toString()&&(this.calculatezIndex=!1);break;case"cssClass":this.setCSSClass(i.cssClass);break;case"buttons":this.unWireButtonEvents(),this.destroyButtons(),m(this.ftrTemplateContent)||(he(this.ftrTemplateContent),this.ftrTemplateContent=null),this.footerTemplate="",this.setButton();break;case"allowDragging":this.allowDragging&&!m(this.headerContent)?this.setAllowDragging():this.dragObj.destroy();break;case"target":this.setTarget(e.target);break;case"position":if(this.checkPositionData(),this.isModal){var a=this.position.X,l=this.position.Y;m(i.position)||(m(i.position.X)||(a=i.position.X),m(i.position.Y)||(l=i.position.Y)),this.dlgContainer.classList.contains("e-dlg-"+a+"-"+l)&&this.dlgContainer.classList.remove("e-dlg-"+a+"-"+l)}this.positionChange(),this.updatePersistData();break;case"enableRtl":this.setEnableRTL();break;case"enableResize":this.setResize();break;case"minHeight":""!==this.minHeight&&(this.element.style.minHeight=Re(this.minHeight))}},t.prototype.setTarget=function(e){this.popupObj.relateTo=e,this.target=e,this.targetEle="string"==typeof this.target?document.querySelector(this.target):this.target,this.dragObj&&(this.dragObj.dragArea=this.targetEle),this.setMaxHeight(),this.isModal&&this.updateIsModal(),this.enableResize&&this.setResize()},t.prototype.updateIsModal=function(){if(this.element.setAttribute("aria-modal",this.isModal?"true":"false"),this.isModal)m(this.dlgOverlay)&&(this.setIsModal(),this.element.style.top="0px",this.element.style.left="0px",m(this.targetEle)||this.targetEle.appendChild(this.dlgContainer));else{for(K([this.element],$0),K([document.body],[yl,ka]),he(this.dlgOverlay);this.dlgContainer.firstChild;)this.dlgContainer.parentElement.insertBefore(this.dlgContainer.firstChild,this.dlgContainer);this.dlgContainer.parentElement.removeChild(this.dlgContainer)}this.visible&&this.show(),this.positionChange(),this.isModal&&this.dlgOverlay&&E.add(this.dlgOverlay,"click",this.dlgOverlayClickEventHandler,this)},t.prototype.setzIndex=function(e,i){var r=this.isProtectedOnChange;this.isProtectedOnChange=!0;var s=cc(e);this.zIndex=s>this.zIndex?s:this.zIndex,this.isProtectedOnChange=r,i&&(this.popupObj.zIndex=this.zIndex)},t.prototype.windowResizeHandler=function(){(function AJ(n){Sh=n})(this.targetEle.clientWidth),function LJ(n){yh=n}(this.targetEle.clientHeight),this.setMaxHeight()},t.prototype.getPersistData=function(){return this.addOnPersist(["width","height","position"])},t.prototype.removeAllChildren=function(e){for(;e.children[0];)this.removeAllChildren(e.children[0]),e.removeChild(e.children[0])},t.prototype.destroy=function(){if(!this.isDestroyed){var e=[zE,$0,HE,up,Z0,E4],i=["role","aria-modal","aria-labelledby","aria-describedby","aria-grabbed","tabindex","style"];K([this.targetEle],[yl,ka]),!m(this.element)&&this.element.classList.contains(Z0)&&K([document.body],[yl,ka]),this.isModal&&K([m(this.targetEle)?document.body:this.targetEle],ka),this.unWireEvents(),this.unWireButtonEvents(),this.destroyButtons(),m(this.closeIconBtnObj)||this.closeIconBtnObj.destroy(),m(this.dragObj)||this.dragObj.destroy(),!m(this.popupObj.element)&&this.popupObj.element.classList.contains("e-popup")&&this.popupObj.destroy(),K([this.element],e),!m(this.cssClass)&&""!==this.cssClass&&K([this.element],this.cssClass.split(" ")),!m(this.refElement)&&!m(this.refElement.parentElement)&&(this.refElement.parentElement.insertBefore(this.isModal?this.dlgContainer:this.element,this.refElement),he(this.refElement),this.refElement=void 0),this.isModal&&(he(this.dlgOverlay),this.dlgContainer.parentNode.insertBefore(this.element,this.dlgContainer),he(this.dlgContainer)),this.element.innerHTML=this.clonedEle.innerHTML;for(var r=0;r0&&""===this.footerTemplate&&this.ftrTemplateContent)for(var e=0;e=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},FE="e-tooltip",B4="e-icons",F4="e-tooltip-close",_E="e-tooltip-wrap",_4="e-tip-content",pp="e-arrow-tip",U4="e-arrow-tip-outer",J0="e-arrow-tip-inner",$g="e-tip-bottom",UE="e-tip-top",j4="e-tip-left",jE="e-tip-right",VE="e-popup",Zg="e-popup-open",WE="e-popup-close",K0="e-lib",V4="e-tooltip-popup-container",JJ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return P4(t,n),Gi([I({effect:"FadeIn",duration:150,delay:0})],t.prototype,"open",void 0),Gi([I({effect:"FadeOut",duration:150,delay:0})],t.prototype,"close",void 0),t}(Ee),bh=function(n){function t(e,i){var r=n.call(this,e,i)||this;return r.mouseMoveEvent=null,r.mouseMoveTarget=null,r.containerElement=null,r.isBodyContainer=!0,r}return P4(t,n),t.prototype.initialize=function(){this.formatPosition(),V([this.element],FE)},t.prototype.formatPosition=function(){var e,i;this.position&&(0===this.position.indexOf("Top")||0===this.position.indexOf("Bottom")?(e=this.position.split(/(?=[A-Z])/),this.tooltipPositionY=e[0],this.tooltipPositionX=e[1]):(i=this.position.split(/(?=[A-Z])/),this.tooltipPositionX=i[0],this.tooltipPositionY=i[1]))},t.prototype.renderArrow=function(){this.setTipClass(this.position);var e=this.createElement("div",{className:pp+" "+this.tipClass});e.appendChild(this.createElement("div",{className:U4+" "+this.tipClass})),e.appendChild(this.createElement("div",{className:J0+" "+this.tipClass})),this.tooltipEle.appendChild(e)},t.prototype.setTipClass=function(e){this.tipClass=0===e.indexOf("Right")?j4:0===e.indexOf("Bottom")?UE:0===e.indexOf("Left")?jE:$g},t.prototype.renderPopup=function(e){var i=this.mouseTrail?{top:0,left:0}:this.getTooltipPosition(e);this.tooltipEle.classList.remove(K0),this.popupObj=new hc(this.tooltipEle,{height:this.height,width:this.width,position:{X:i.left,Y:i.top},enableRtl:this.enableRtl,open:this.openPopupHandler.bind(this),close:this.closePopupHandler.bind(this)})},t.prototype.getScalingFactor=function(e){if(!e)return{x:1,y:1};var i={x:1,y:1},r=e.closest('[style*="transform: scale"]');if(r&&r!==this.tooltipEle&&r.contains(this.tooltipEle)){var a=window.getComputedStyle(r).getPropertyValue("transform").match(/matrix\(([^)]+)\)/)[1].split(",").map(parseFloat);i.x=a[0],i.y=a[3]}return i},t.prototype.getTooltipPosition=function(e){this.tooltipEle.style.display="block";var i=this.element.closest('[style*="zoom"]');i&&(i.contains(this.tooltipEle)||(this.tooltipEle.style.zoom=getComputedStyle(i).zoom));var r=is(e,this.tooltipPositionX,this.tooltipPositionY,!this.isBodyContainer,this.isBodyContainer?null:this.containerElement.getBoundingClientRect()),s=this.getScalingFactor(e),o=this.calculateTooltipOffset(this.position,s.x,s.y),a=this.calculateElementPosition(r,o),c=this.collisionFlipFit(e,a[0],a[1]);return c.left=c.left/s.x,c.top=c.top/s.y,this.tooltipEle.style.display="",c},t.prototype.windowResize=function(){this.reposition(this.findTarget())},t.prototype.reposition=function(e){if(this.popupObj&&e){var i=this.getTooltipPosition(e);this.popupObj.position={X:i.left,Y:i.top},this.popupObj.dataBind()}},t.prototype.openPopupHandler=function(){!this.mouseTrail&&this.needTemplateReposition()&&this.reposition(this.findTarget()),this.trigger("afterOpen",this.tooltipEventArgs),this.tooltipEventArgs=null},t.prototype.closePopupHandler=function(){this.isReact&&!("Click"===this.opensOn||"function"==typeof this.content)&&this.clearTemplate(["content"]),this.clear();var e={type:this.tooltipEventArgs.event?this.tooltipEventArgs.event.type:null,cancel:!1,target:this.tooltipEventArgs.target,event:this.tooltipEventArgs.event?this.tooltipEventArgs.event:null,element:this.tooltipEle,isInteracted:!m(this.tooltipEventArgs.event)};this.trigger("afterClose",e),e=null},t.prototype.calculateTooltipOffset=function(e,i,r){void 0===i&&(i=1),void 0===r&&(r=1);var o,a,l,h,c,d,u,p,s={top:0,left:0};if(1!==i||1!==r){var f=this.tooltipEle.getBoundingClientRect(),g=void 0;l=Math.round(f.width),h=Math.round(f.height),(c=U("."+pp,this.tooltipEle))&&(g=c.getBoundingClientRect()),o=c?Math.round(g.width):0,a=c?Math.round(g.height):0,d=this.showTipPointer?0:8,u=a/2+2+(h-this.tooltipEle.clientHeight*r),p=o/2+2+(l-this.tooltipEle.clientWidth*i)}else l=this.tooltipEle.offsetWidth,h=this.tooltipEle.offsetHeight,c=U("."+pp,this.tooltipEle),d=this.showTipPointer?0:8,u=(a=c?c.offsetHeight:0)/2+2+(this.tooltipEle.offsetHeight-this.tooltipEle.clientHeight),p=(o=c?c.offsetWidth:0)/2+2+(this.tooltipEle.offsetWidth-this.tooltipEle.clientWidth);switch(this.mouseTrail&&(d+=2),e){case"RightTop":s.left+=o+d,s.top-=h-u;break;case"RightCenter":s.left+=o+d,s.top-=h/2;break;case"RightBottom":s.left+=o+d,s.top-=u;break;case"BottomRight":s.top+=a+d,s.left-=p;break;case"BottomCenter":s.top+=a+d,s.left-=l/2;break;case"BottomLeft":s.top+=a+d,s.left-=l-p;break;case"LeftBottom":s.left-=o+l+d,s.top-=u;break;case"LeftCenter":s.left-=o+l+d,s.top-=h/2;break;case"LeftTop":s.left-=o+l+d,s.top-=h-u;break;case"TopLeft":s.top-=h+a+d,s.left-=l-p;break;case"TopRight":s.top-=h+a+d,s.left-=p;break;default:s.top-=h+a+d,s.left-=l/2}return s.left+=this.offsetX,s.top+=this.offsetY,s},t.prototype.updateTipPosition=function(e){var i=we("."+pp+",."+U4+",."+J0,this.tooltipEle);K(i,[$g,UE,j4,jE]),this.setTipClass(e),V(i,this.tipClass)},t.prototype.adjustArrow=function(e,i,r,s){var o=U("."+pp,this.tooltipEle);if(!1!==this.showTipPointer&&null!==o){var a,l;this.updateTipPosition(i),this.tooltipEle.style.display="block";var f,h=this.tooltipEle.clientWidth,c=this.tooltipEle.clientHeight,d=U("."+J0,this.tooltipEle),u=o.offsetWidth,p=o.offsetHeight;this.tooltipEle.style.display="",this.tipClass===$g||this.tipClass===UE?(this.tipClass===$g?(l="99.9%",d.style.top="-"+(p-2)+"px"):(l=-(p-1)+"px",d.style.top="-"+(p-6)+"px"),e&&(a=(f="Center"!==r||h>e.offsetWidth||this.mouseTrail)&&"Left"===r||!f&&"End"===this.tipPointerPosition?h-u-2+"px":f&&"Right"===r||!f&&"Start"===this.tipPointerPosition?"2px":!f||"End"!==this.tipPointerPosition&&"Start"!==this.tipPointerPosition?h/2-u/2+"px":"End"===this.tipPointerPosition?e.offsetWidth+(this.tooltipEle.offsetWidth-e.offsetWidth)/2-u/2-2+"px":(this.tooltipEle.offsetWidth-e.offsetWidth)/2-u/2+2+"px")):(this.tipClass===jE?(a="99.9%",d.style.left="-"+(u-2)+"px"):(a=-(u-1)+"px",d.style.left=u-2-u+"px"),l=(f="Center"!==s||c>e.offsetHeight||this.mouseTrail)&&"Top"===s||!f&&"End"===this.tipPointerPosition?c-p-2+"px":f&&"Bottom"===s||!f&&"Start"===this.tipPointerPosition?"2px":c/2-p/2+"px"),o.style.top=l,o.style.left=a}},t.prototype.renderContent=function(e){var i=this,r=U("."+_4,this.tooltipEle);if(this.cssClass&&V([this.tooltipEle],this.cssClass.split(" ")),e&&!m(e.getAttribute("title"))&&(e.setAttribute("data-content",e.getAttribute("title")),e.removeAttribute("title")),m(this.content))e&&!m(e.getAttribute("data-content"))&&(r.innerHTML=e.getAttribute("data-content"));else if(r.innerHTML="",this.content instanceof HTMLElement)r.appendChild(this.content);else if("string"==typeof this.content)this.isAngular?this.setProperties({content:Ti.sanitize(this.content)},!0):this.content=this.enableHtmlSanitizer?Ti.sanitize(this.content):this.content,this.enableHtmlParse?(o=ii(this.content)({},this,"content",this.element.id+"content",void 0,void 0,r,this.root))&&Dt(o,r):r.textContent=this.content;else{var o;(o=ii(this.content)({},this,"content",this.element.id+"content",void 0,void 0,r))&&(this.isAngular&&setTimeout(function(){i.reposition(e)},1),Dt(o,r)),this.renderReactTemplates()}},t.prototype.renderCloseIcon=function(){if(this.isSticky){var i=this.createElement("div",{className:B4+" "+F4});this.tooltipEle.appendChild(i),E.add(i,X.touchStartEvent,this.onStickyClose,this)}else{var e=this.tooltipEle.querySelector("."+B4+"."+F4);e&>(e)}},t.prototype.addDescribedBy=function(e,i){var r=(e.getAttribute("aria-describedby")||"").split(/\s+/);r.indexOf(i)<0&&r.push(i),Fe(e,{"aria-describedby":r.join(" ").trim(),"data-tooltip-id":i})},t.prototype.removeDescribedBy=function(e){var i=e.getAttribute("data-tooltip-id"),r=(e.getAttribute("aria-describedby")||"").split(/\s+/),s=r.indexOf(i);-1!==s&&r.splice(s,1),e.removeAttribute("data-tooltip-id");var o=r.join(" ").trim();o?e.setAttribute("aria-describedby",o):e.removeAttribute("aria-describedby")},t.prototype.tapHoldHandler=function(e){clearTimeout(this.autoCloseTimer),this.targetHover(e.originalEvent)},t.prototype.touchEndHandler=function(){var e=this;this.isSticky||(this.autoCloseTimer=setTimeout(function(){e.close()},1500))},t.prototype.targetClick=function(e){var i;!m(i=this.target?J(e.target,this.target):this.element)&&(null===i.getAttribute("data-tooltip-id")?this.targetHover(e):this.isSticky||this.hideTooltip(this.animation.close,e,i))},t.prototype.targetHover=function(e){var i;if(!(m(i=this.target?J(e.target,this.target):this.element)||null!==i.getAttribute("data-tooltip-id")&&0===this.closeDelay)){for(var s=0,o=[].slice.call(we('[data-tooltip-id= "'+this.ctrlId+'_content"]',document));s0?this.showTimer=setTimeout(function(){o.mouseTrail&&E.add(i,"mousemove touchstart mouseenter",o.onMouseMove,o),o.popupObj&&(o.popupObj.show(a,i),o.mouseMoveEvent&&o.mouseTrail&&o.onMouseMove(o.mouseMoveEvent))},this.openDelay):this.popupObj&&this.popupObj.show(a,i)}s&&this.wireMouseEvents(s,i)},t.prototype.needTemplateReposition=function(){return!m(this.viewContainerRef)&&"string"!=typeof this.viewContainerRef||this.isReact},t.prototype.checkCollision=function(e,i,r){var s={left:i,top:r,position:this.position,horizontal:this.tooltipPositionX,vertical:this.tooltipPositionY},o=lc(this.tooltipEle,this.checkCollideTarget(),i,r);return o.length>0&&(s.horizontal=o.indexOf("left")>=0?"Right":o.indexOf("right")>=0?"Left":this.tooltipPositionX,s.vertical=o.indexOf("top")>=0?"Bottom":o.indexOf("bottom")>=0?"Top":this.tooltipPositionY),s},t.prototype.calculateElementPosition=function(e,i){return[this.isBodyContainer?e.left+i.left:e.left-this.containerElement.getBoundingClientRect().left+i.left+window.pageXOffset+this.containerElement.scrollLeft,this.isBodyContainer?e.top+i.top:e.top-this.containerElement.getBoundingClientRect().top+i.top+window.pageYOffset+this.containerElement.scrollTop]},t.prototype.collisionFlipFit=function(e,i,r){var s=this.checkCollision(e,i,r),o=s.position;if(this.tooltipPositionY!==s.vertical&&(o=0===this.position.indexOf("Bottom")||0===this.position.indexOf("Top")?s.vertical+this.tooltipPositionX:this.tooltipPositionX+s.vertical),this.tooltipPositionX!==s.horizontal&&(0===o.indexOf("Left")&&(s.vertical="LeftTop"===o||"LeftCenter"===o?"Top":"Bottom",o=s.vertical+"Left"),0===o.indexOf("Right")&&(s.vertical="RightTop"===o||"RightCenter"===o?"Top":"Bottom",o=s.vertical+"Right"),s.horizontal=this.tooltipPositionX),this.tooltipEventArgs={type:null,cancel:!1,target:e,event:null,element:this.tooltipEle,collidedPosition:o},this.trigger("beforeCollision",this.tooltipEventArgs),this.tooltipEventArgs.cancel)o=this.position;else{var a=s.vertical,l=s.horizontal;if(s.position!==o){var h=is(e,l,a,!this.isBodyContainer,this.isBodyContainer?null:this.containerElement.getBoundingClientRect());this.adjustArrow(e,o,l,a);var c=this.getScalingFactor(e),d=this.calculateTooltipOffset(o,c.x,c.y);d.top-=this.getOffSetPosition("TopBottom",o,this.offsetY),d.left-=this.getOffSetPosition("RightLeft",o,this.offsetX),s.position=o;var u=this.calculateElementPosition(h,d);s.left=u[0],s.top=u[1]}else this.adjustArrow(e,o,l,a)}var p={left:s.left,top:s.top},f=this.isBodyContainer?pE(this.tooltipEle,this.checkCollideTarget(),{X:!0,Y:this.windowCollision},p):p;this.tooltipEle.style.display="block";var g=U("."+pp,this.tooltipEle);if(this.showTipPointer&&null!=g&&(0===o.indexOf("Bottom")||0===o.indexOf("Top"))){var v=parseInt(g.style.left,10)-(f.left-s.left);v<0?v=0:v+g.offsetWidth>this.tooltipEle.clientWidth&&(v=this.tooltipEle.clientWidth-g.offsetWidth),g.style.left=v.toString()+"px"}return this.tooltipEle.style.display="",p.left=f.left,p.top=f.top,p},t.prototype.getOffSetPosition=function(e,i,r){return-1!==e.indexOf(this.position.split(/(?=[A-Z])/)[0])&&-1!==e.indexOf(i.split(/(?=[A-Z])/)[0])?2*r:0},t.prototype.checkCollideTarget=function(){return!this.windowCollision&&this.target?this.element:null},t.prototype.hideTooltip=function(e,i,r){var s=this;this.closeDelay>0?(clearTimeout(this.hideTimer),clearTimeout(this.showTimer),this.hideTimer=setTimeout(function(){s.closeDelay&&s.tooltipEle&&s.isTooltipOpen||s.tooltipHide(e,i,r)},this.closeDelay)):this.tooltipHide(e,i,r)},t.prototype.tooltipHide=function(e,i,r){var o,s=this;o=i?this.target?r||i.target:this.element:U('[data-tooltip-id= "'+this.ctrlId+'_content"]',document),this.tooltipEventArgs={type:i?i.type:null,cancel:!1,target:o,event:i||null,element:this.tooltipEle,isInteracted:!m(i)},this.trigger("beforeClose",this.tooltipEventArgs,function(a){a.cancel?s.isHidden=!1:(s.mouseMoveBeforeRemove(),s.popupHide(e,o,i))})},t.prototype.popupHide=function(e,i,r){i&&r&&this.restoreElement(i),this.isHidden=!0;var s={name:this.animation.close.effect,duration:e.duration,delay:e.delay,timingFunction:"easeIn"};"None"===e.effect&&(s=void 0),this.popupObj&&this.popupObj.hide(s)},t.prototype.restoreElement=function(e){this.unwireMouseEvents(e),m(e.getAttribute("data-content"))||(e.setAttribute("title",e.getAttribute("data-content")),e.removeAttribute("data-content")),this.removeDescribedBy(e)},t.prototype.clear=function(){var e=this.findTarget();e&&this.restoreElement(e),this.tooltipEle&&(K([this.tooltipEle],WE),V([this.tooltipEle],Zg)),this.isHidden&&(this.popupObj&&this.popupObj.destroy(),this.tooltipEle&>(this.tooltipEle),this.tooltipEle=null,this.popupObj=null)},t.prototype.tooltipHover=function(){this.tooltipEle&&(this.isTooltipOpen=!0)},t.prototype.tooltipMouseOut=function(e){this.isTooltipOpen=!1,this.hideTooltip(this.animation.close,e,this.findTarget())},t.prototype.onMouseOut=function(e){var i=e.relatedTarget;if(i&&!this.mouseTrail){var r=J(i,"."+_E+"."+K0+"."+VE);r?E.add(r,"mouseleave",this.tooltipElementMouseOut,this):(this.hideTooltip(this.animation.close,e,this.findTarget()),0===this.closeDelay&&("None"===this.animation.close.effect||this.isReact&&"string"!=typeof this.content)&&this.clear())}else this.hideTooltip(this.animation.close,e,this.findTarget()),this.clear();this.popupObj&&!this.popupObj.element.classList.contains(Zg)&&this.clear()},t.prototype.tooltipElementMouseOut=function(e){this.hideTooltip(this.animation.close,e,this.findTarget()),E.remove(this.element,"mouseleave",this.tooltipElementMouseOut),this.clear()},t.prototype.onStickyClose=function(){this.close()},t.prototype.onMouseMove=function(e){var i=0,r=0;e.type.indexOf("touch")>-1?(e.preventDefault(),i=e.touches[0].pageX,r=e.touches[0].pageY):(i=e.pageX,r=e.pageY),Hs.stop(this.tooltipEle),K([this.tooltipEle],WE),V([this.tooltipEle],Zg),this.adjustArrow(e.target,this.position,this.tooltipPositionX,this.tooltipPositionY);var s=this.getScalingFactor(e.target),o=this.calculateTooltipOffset(this.position,s.x,s.y),h=this.checkCollision(e.target,i+o.left+this.offsetX,r+o.top+this.offsetY);if(this.tooltipPositionX!==h.horizontal||this.tooltipPositionY!==h.vertical){var c=0===this.position.indexOf("Bottom")||0===this.position.indexOf("Top")?h.vertical+h.horizontal:h.horizontal+h.vertical;h.position=c,this.adjustArrow(e.target,h.position,h.horizontal,h.vertical);var d=this.calculateTooltipOffset(h.position,s.x,s.y);h.left=i+d.left-this.offsetX,h.top=r+d.top-this.offsetY}this.tooltipEle.style.left=h.left+"px",this.tooltipEle.style.top=h.top+"px"},t.prototype.keyDown=function(e){this.tooltipEle&&27===e.keyCode&&this.close()},t.prototype.touchEnd=function(e){this.tooltipEle&&null===J(e.target,"."+FE)&&!this.isSticky&&this.close()},t.prototype.scrollHandler=function(e){this.tooltipEle&&!this.isSticky&&!J(e.target,"."+_E+"."+K0+"."+VE)&&!this.isSticky&&this.close()},t.prototype.render=function(){this.initialize(),this.wireEvents(this.opensOn),this.renderComplete()},t.prototype.preRender=function(){this.tipClass=$g,this.tooltipPositionX="Center",this.tooltipPositionY="Top",this.isHidden=!0},t.prototype.wireEvents=function(e){for(var r=0,s=this.getTriggerList(e);r0)for(var i=0,r=e;i0)for(var i=0,r=e;i0&&this.condition&&-1!==this.condition.indexOf("not")&&(e[s].condition=e[s].condition?e[s].condition+"not":"not"),i=e[s].validate(t),r){if(!i)return!1}else if(i)return!0;return r},n.prototype.toJson=function(){var t,e;if(this.isComplex){t=[],e=this.predicates;for(var i=0;ie.length-3?(e=e.substring(0,e.length-1),n.endsWith(n.toLowerCase(t),n.toLowerCase(e))):(e.lastIndexOf("%")!==e.indexOf("%")&&e.lastIndexOf("%")>e.indexOf("%")+1&&(e=e.substring(e.indexOf("%")+1,e.lastIndexOf("%"))),-1!==t.indexOf(e)))},n.fnSort=function(t){return"ascending"===(t=t?n.toLowerCase(t):"ascending")?this.fnAscending:this.fnDescending},n.fnAscending=function(t,e){return m(t)&&m(e)||null==e?-1:"string"==typeof t?t.localeCompare(e):null==t?1:t-e},n.fnDescending=function(t,e){return m(t)&&m(e)?-1:null==e?1:"string"==typeof t?-1*t.localeCompare(e):null==t?-1:e-t},n.extractFields=function(t,e){for(var i={},r=0;r0||e.length>0;)o=t.length>0&&e.length>0?r?r(this.getVal(t,0,i),this.getVal(e,0,i),t[0],e[0])<=0?t:e:t[0][i]0?t:e,s.push(o.shift());return s},n.getVal=function(t,e,i){return i?this.getObject(i,t[e]):t[e]},n.toLowerCase=function(t){return t?"string"==typeof t?t.toLowerCase():t.toString():0===t||!1===t?t.toString():""},n.callAdaptorFunction=function(t,e,i,r){if(e in t){var s=t[e](i,r);m(s)||(i=s)}return i},n.getAddParams=function(t,e,i){var r={};return n.callAdaptorFunction(t,"addParams",{dm:e,query:i,params:i?i.params:[],reqParams:r}),r},n.isPlainObject=function(t){return!!t&&t.constructor===Object},n.isCors=function(){var t=null;try{t=new window.XMLHttpRequest}catch{}return!!t&&"withCredentials"in t},n.getGuid=function(t){var i;return(t||"")+"00000000-0000-4000-0000-000000000000".replace(/0/g,function(r,s){if("crypto"in window&&"getRandomValues"in crypto){var o=new Uint8Array(1);window.crypto.getRandomValues(o),i=o[0]%16|0}else i=16*Math.random()|0;return"0123456789abcdef"[19===s?3&i|8:i]})},n.isNull=function(t){return null==t},n.getItemFromComparer=function(t,e,i){var r,s,o,a=0,l="string"==typeof n.getVal(t,0,e);if(t.length)for(;m(r)&&a0&&(r=s,o=t[a]));return o},n.distinct=function(t,e,i){i=!m(i)&&i;var s,r=[],o={};return t.forEach(function(a,l){(s="object"==typeof t[l]?n.getVal(t,l,e):t[l])in o||(r.push(i?t[l]:s),o[s]=1)}),r},n.processData=function(t,e){var i=this.prepareQuery(t),r=new nt(e);t.requiresCounts&&i.requiresCount();var s=r.executeLocal(i),o={result:t.requiresCounts?s.result:s,count:s.count,aggregates:JSON.stringify(s.aggregates)};return t.requiresCounts?o:s},n.prepareQuery=function(t){var e=this,i=new jt;return t.select&&i.select(t.select),t.where&&n.parse.parseJson(t.where).filter(function(o){if(m(o.condition))i.where(o.field,o.operator,o.value,o.ignoreCase,o.ignoreAccent);else{var a=[];o.field?a.push(new Ss(o.field,o.operator,o.value,o.ignoreCase,o.ignoreAccent)):a=a.concat(e.getPredicate(o.predicates)),"or"===o.condition?i.where(Ss.or(a)):"and"===o.condition&&i.where(Ss.and(a))}}),t.search&&n.parse.parseJson(t.search).filter(function(o){return i.search(o.key,o.fields,o.operator,o.ignoreCase,o.ignoreAccent)}),t.aggregates&&t.aggregates.filter(function(o){return i.aggregate(o.type,o.field)}),t.sorted&&t.sorted.filter(function(o){return i.sortBy(o.name,o.direction)}),t.skip&&i.skip(t.skip),t.take&&i.take(t.take),t.group&&t.group.filter(function(o){return i.group(o)}),i},n.getPredicate=function(t){for(var e=[],i=0;i":"greaterthan","<=":"lessthanorequal",">=":"greaterthanorequal","==":"equal","!=":"notequal","*=":"contains","$=":"endswith","^=":"startswith"},n.odBiOperator={"<":" lt ",">":" gt ","<=":" le ",">=":" ge ","==":" eq ","!=":" ne ",lessthan:" lt ",lessthanorequal:" le ",greaterthan:" gt ",greaterthanorequal:" ge ",equal:" eq ",notequal:" ne "},n.odUniOperator={"$=":"endswith","^=":"startswith","*=":"substringof",endswith:"endswith",startswith:"startswith",contains:"substringof",doesnotendwith:"not endswith",doesnotstartwith:"not startswith",doesnotcontain:"not substringof",wildcard:"wildcard",like:"like"},n.odv4UniOperator={"$=":"endswith","^=":"startswith","*=":"contains",endswith:"endswith",startswith:"startswith",contains:"contains",doesnotendwith:"not endswith",doesnotstartwith:"not startswith",doesnotcontain:"not contains",wildcard:"wildcard",like:"like"},n.diacritics={"\u24b6":"A",\uff21:"A",\u00c0:"A",\u00c1:"A",\u00c2:"A",\u1ea6:"A",\u1ea4:"A",\u1eaa:"A",\u1ea8:"A",\u00c3:"A",\u0100:"A",\u0102:"A",\u1eb0:"A",\u1eae:"A",\u1eb4:"A",\u1eb2:"A",\u0226:"A",\u01e0:"A",\u00c4:"A",\u01de:"A",\u1ea2:"A",\u00c5:"A",\u01fa:"A",\u01cd:"A",\u0200:"A",\u0202:"A",\u1ea0:"A",\u1eac:"A",\u1eb6:"A",\u1e00:"A",\u0104:"A",\u023a:"A",\u2c6f:"A",\ua732:"AA",\u00c6:"AE",\u01fc:"AE",\u01e2:"AE",\ua734:"AO",\ua736:"AU",\ua738:"AV",\ua73a:"AV",\ua73c:"AY","\u24b7":"B",\uff22:"B",\u1e02:"B",\u1e04:"B",\u1e06:"B",\u0243:"B",\u0182:"B",\u0181:"B","\u24b8":"C",\uff23:"C",\u0106:"C",\u0108:"C",\u010a:"C",\u010c:"C",\u00c7:"C",\u1e08:"C",\u0187:"C",\u023b:"C",\ua73e:"C","\u24b9":"D",\uff24:"D",\u1e0a:"D",\u010e:"D",\u1e0c:"D",\u1e10:"D",\u1e12:"D",\u1e0e:"D",\u0110:"D",\u018b:"D",\u018a:"D",\u0189:"D",\ua779:"D",\u01f1:"DZ",\u01c4:"DZ",\u01f2:"Dz",\u01c5:"Dz","\u24ba":"E",\uff25:"E",\u00c8:"E",\u00c9:"E",\u00ca:"E",\u1ec0:"E",\u1ebe:"E",\u1ec4:"E",\u1ec2:"E",\u1ebc:"E",\u0112:"E",\u1e14:"E",\u1e16:"E",\u0114:"E",\u0116:"E",\u00cb:"E",\u1eba:"E",\u011a:"E",\u0204:"E",\u0206:"E",\u1eb8:"E",\u1ec6:"E",\u0228:"E",\u1e1c:"E",\u0118:"E",\u1e18:"E",\u1e1a:"E",\u0190:"E",\u018e:"E","\u24bb":"F",\uff26:"F",\u1e1e:"F",\u0191:"F",\ua77b:"F","\u24bc":"G",\uff27:"G",\u01f4:"G",\u011c:"G",\u1e20:"G",\u011e:"G",\u0120:"G",\u01e6:"G",\u0122:"G",\u01e4:"G",\u0193:"G",\ua7a0:"G",\ua77d:"G",\ua77e:"G","\u24bd":"H",\uff28:"H",\u0124:"H",\u1e22:"H",\u1e26:"H",\u021e:"H",\u1e24:"H",\u1e28:"H",\u1e2a:"H",\u0126:"H",\u2c67:"H",\u2c75:"H",\ua78d:"H","\u24be":"I",\uff29:"I",\u00cc:"I",\u00cd:"I",\u00ce:"I",\u0128:"I",\u012a:"I",\u012c:"I",\u0130:"I",\u00cf:"I",\u1e2e:"I",\u1ec8:"I",\u01cf:"I",\u0208:"I",\u020a:"I",\u1eca:"I",\u012e:"I",\u1e2c:"I",\u0197:"I","\u24bf":"J",\uff2a:"J",\u0134:"J",\u0248:"J","\u24c0":"K",\uff2b:"K",\u1e30:"K",\u01e8:"K",\u1e32:"K",\u0136:"K",\u1e34:"K",\u0198:"K",\u2c69:"K",\ua740:"K",\ua742:"K",\ua744:"K",\ua7a2:"K","\u24c1":"L",\uff2c:"L",\u013f:"L",\u0139:"L",\u013d:"L",\u1e36:"L",\u1e38:"L",\u013b:"L",\u1e3c:"L",\u1e3a:"L",\u0141:"L",\u023d:"L",\u2c62:"L",\u2c60:"L",\ua748:"L",\ua746:"L",\ua780:"L",\u01c7:"LJ",\u01c8:"Lj","\u24c2":"M",\uff2d:"M",\u1e3e:"M",\u1e40:"M",\u1e42:"M",\u2c6e:"M",\u019c:"M","\u24c3":"N",\uff2e:"N",\u01f8:"N",\u0143:"N",\u00d1:"N",\u1e44:"N",\u0147:"N",\u1e46:"N",\u0145:"N",\u1e4a:"N",\u1e48:"N",\u0220:"N",\u019d:"N",\ua790:"N",\ua7a4:"N",\u01ca:"NJ",\u01cb:"Nj","\u24c4":"O",\uff2f:"O",\u00d2:"O",\u00d3:"O",\u00d4:"O",\u1ed2:"O",\u1ed0:"O",\u1ed6:"O",\u1ed4:"O",\u00d5:"O",\u1e4c:"O",\u022c:"O",\u1e4e:"O",\u014c:"O",\u1e50:"O",\u1e52:"O",\u014e:"O",\u022e:"O",\u0230:"O",\u00d6:"O",\u022a:"O",\u1ece:"O",\u0150:"O",\u01d1:"O",\u020c:"O",\u020e:"O",\u01a0:"O",\u1edc:"O",\u1eda:"O",\u1ee0:"O",\u1ede:"O",\u1ee2:"O",\u1ecc:"O",\u1ed8:"O",\u01ea:"O",\u01ec:"O",\u00d8:"O",\u01fe:"O",\u0186:"O",\u019f:"O",\ua74a:"O",\ua74c:"O",\u01a2:"OI",\ua74e:"OO",\u0222:"OU","\u24c5":"P",\uff30:"P",\u1e54:"P",\u1e56:"P",\u01a4:"P",\u2c63:"P",\ua750:"P",\ua752:"P",\ua754:"P","\u24c6":"Q",\uff31:"Q",\ua756:"Q",\ua758:"Q",\u024a:"Q","\u24c7":"R",\uff32:"R",\u0154:"R",\u1e58:"R",\u0158:"R",\u0210:"R",\u0212:"R",\u1e5a:"R",\u1e5c:"R",\u0156:"R",\u1e5e:"R",\u024c:"R",\u2c64:"R",\ua75a:"R",\ua7a6:"R",\ua782:"R","\u24c8":"S",\uff33:"S",\u1e9e:"S",\u015a:"S",\u1e64:"S",\u015c:"S",\u1e60:"S",\u0160:"S",\u1e66:"S",\u1e62:"S",\u1e68:"S",\u0218:"S",\u015e:"S",\u2c7e:"S",\ua7a8:"S",\ua784:"S","\u24c9":"T",\uff34:"T",\u1e6a:"T",\u0164:"T",\u1e6c:"T",\u021a:"T",\u0162:"T",\u1e70:"T",\u1e6e:"T",\u0166:"T",\u01ac:"T",\u01ae:"T",\u023e:"T",\ua786:"T",\ua728:"TZ","\u24ca":"U",\uff35:"U",\u00d9:"U",\u00da:"U",\u00db:"U",\u0168:"U",\u1e78:"U",\u016a:"U",\u1e7a:"U",\u016c:"U",\u00dc:"U",\u01db:"U",\u01d7:"U",\u01d5:"U",\u01d9:"U",\u1ee6:"U",\u016e:"U",\u0170:"U",\u01d3:"U",\u0214:"U",\u0216:"U",\u01af:"U",\u1eea:"U",\u1ee8:"U",\u1eee:"U",\u1eec:"U",\u1ef0:"U",\u1ee4:"U",\u1e72:"U",\u0172:"U",\u1e76:"U",\u1e74:"U",\u0244:"U","\u24cb":"V",\uff36:"V",\u1e7c:"V",\u1e7e:"V",\u01b2:"V",\ua75e:"V",\u0245:"V",\ua760:"VY","\u24cc":"W",\uff37:"W",\u1e80:"W",\u1e82:"W",\u0174:"W",\u1e86:"W",\u1e84:"W",\u1e88:"W",\u2c72:"W","\u24cd":"X",\uff38:"X",\u1e8a:"X",\u1e8c:"X","\u24ce":"Y",\uff39:"Y",\u1ef2:"Y",\u00dd:"Y",\u0176:"Y",\u1ef8:"Y",\u0232:"Y",\u1e8e:"Y",\u0178:"Y",\u1ef6:"Y",\u1ef4:"Y",\u01b3:"Y",\u024e:"Y",\u1efe:"Y","\u24cf":"Z",\uff3a:"Z",\u0179:"Z",\u1e90:"Z",\u017b:"Z",\u017d:"Z",\u1e92:"Z",\u1e94:"Z",\u01b5:"Z",\u0224:"Z",\u2c7f:"Z",\u2c6b:"Z",\ua762:"Z","\u24d0":"a",\uff41:"a",\u1e9a:"a",\u00e0:"a",\u00e1:"a",\u00e2:"a",\u1ea7:"a",\u1ea5:"a",\u1eab:"a",\u1ea9:"a",\u00e3:"a",\u0101:"a",\u0103:"a",\u1eb1:"a",\u1eaf:"a",\u1eb5:"a",\u1eb3:"a",\u0227:"a",\u01e1:"a",\u00e4:"a",\u01df:"a",\u1ea3:"a",\u00e5:"a",\u01fb:"a",\u01ce:"a",\u0201:"a",\u0203:"a",\u1ea1:"a",\u1ead:"a",\u1eb7:"a",\u1e01:"a",\u0105:"a",\u2c65:"a",\u0250:"a",\ua733:"aa",\u00e6:"ae",\u01fd:"ae",\u01e3:"ae",\ua735:"ao",\ua737:"au",\ua739:"av",\ua73b:"av",\ua73d:"ay","\u24d1":"b",\uff42:"b",\u1e03:"b",\u1e05:"b",\u1e07:"b",\u0180:"b",\u0183:"b",\u0253:"b","\u24d2":"c",\uff43:"c",\u0107:"c",\u0109:"c",\u010b:"c",\u010d:"c",\u00e7:"c",\u1e09:"c",\u0188:"c",\u023c:"c",\ua73f:"c",\u2184:"c","\u24d3":"d",\uff44:"d",\u1e0b:"d",\u010f:"d",\u1e0d:"d",\u1e11:"d",\u1e13:"d",\u1e0f:"d",\u0111:"d",\u018c:"d",\u0256:"d",\u0257:"d",\ua77a:"d",\u01f3:"dz",\u01c6:"dz","\u24d4":"e",\uff45:"e",\u00e8:"e",\u00e9:"e",\u00ea:"e",\u1ec1:"e",\u1ebf:"e",\u1ec5:"e",\u1ec3:"e",\u1ebd:"e",\u0113:"e",\u1e15:"e",\u1e17:"e",\u0115:"e",\u0117:"e",\u00eb:"e",\u1ebb:"e",\u011b:"e",\u0205:"e",\u0207:"e",\u1eb9:"e",\u1ec7:"e",\u0229:"e",\u1e1d:"e",\u0119:"e",\u1e19:"e",\u1e1b:"e",\u0247:"e",\u025b:"e",\u01dd:"e","\u24d5":"f",\uff46:"f",\u1e1f:"f",\u0192:"f",\ua77c:"f","\u24d6":"g",\uff47:"g",\u01f5:"g",\u011d:"g",\u1e21:"g",\u011f:"g",\u0121:"g",\u01e7:"g",\u0123:"g",\u01e5:"g",\u0260:"g",\ua7a1:"g",\u1d79:"g",\ua77f:"g","\u24d7":"h",\uff48:"h",\u0125:"h",\u1e23:"h",\u1e27:"h",\u021f:"h",\u1e25:"h",\u1e29:"h",\u1e2b:"h",\u1e96:"h",\u0127:"h",\u2c68:"h",\u2c76:"h",\u0265:"h",\u0195:"hv","\u24d8":"i",\uff49:"i",\u00ec:"i",\u00ed:"i",\u00ee:"i",\u0129:"i",\u012b:"i",\u012d:"i",\u00ef:"i",\u1e2f:"i",\u1ec9:"i",\u01d0:"i",\u0209:"i",\u020b:"i",\u1ecb:"i",\u012f:"i",\u1e2d:"i",\u0268:"i",\u0131:"i","\u24d9":"j",\uff4a:"j",\u0135:"j",\u01f0:"j",\u0249:"j","\u24da":"k",\uff4b:"k",\u1e31:"k",\u01e9:"k",\u1e33:"k",\u0137:"k",\u1e35:"k",\u0199:"k",\u2c6a:"k",\ua741:"k",\ua743:"k",\ua745:"k",\ua7a3:"k","\u24db":"l",\uff4c:"l",\u0140:"l",\u013a:"l",\u013e:"l",\u1e37:"l",\u1e39:"l",\u013c:"l",\u1e3d:"l",\u1e3b:"l",\u017f:"l",\u0142:"l",\u019a:"l",\u026b:"l",\u2c61:"l",\ua749:"l",\ua781:"l",\ua747:"l",\u01c9:"lj","\u24dc":"m",\uff4d:"m",\u1e3f:"m",\u1e41:"m",\u1e43:"m",\u0271:"m",\u026f:"m","\u24dd":"n",\uff4e:"n",\u01f9:"n",\u0144:"n",\u00f1:"n",\u1e45:"n",\u0148:"n",\u1e47:"n",\u0146:"n",\u1e4b:"n",\u1e49:"n",\u019e:"n",\u0272:"n",\u0149:"n",\ua791:"n",\ua7a5:"n",\u01cc:"nj","\u24de":"o",\uff4f:"o",\u00f2:"o",\u00f3:"o",\u00f4:"o",\u1ed3:"o",\u1ed1:"o",\u1ed7:"o",\u1ed5:"o",\u00f5:"o",\u1e4d:"o",\u022d:"o",\u1e4f:"o",\u014d:"o",\u1e51:"o",\u1e53:"o",\u014f:"o",\u022f:"o",\u0231:"o",\u00f6:"o",\u022b:"o",\u1ecf:"o",\u0151:"o",\u01d2:"o",\u020d:"o",\u020f:"o",\u01a1:"o",\u1edd:"o",\u1edb:"o",\u1ee1:"o",\u1edf:"o",\u1ee3:"o",\u1ecd:"o",\u1ed9:"o",\u01eb:"o",\u01ed:"o",\u00f8:"o",\u01ff:"o",\u0254:"o",\ua74b:"o",\ua74d:"o",\u0275:"o",\u01a3:"oi",\u0223:"ou",\ua74f:"oo","\u24df":"p",\uff50:"p",\u1e55:"p",\u1e57:"p",\u01a5:"p",\u1d7d:"p",\ua751:"p",\ua753:"p",\ua755:"p","\u24e0":"q",\uff51:"q",\u024b:"q",\ua757:"q",\ua759:"q","\u24e1":"r",\uff52:"r",\u0155:"r",\u1e59:"r",\u0159:"r",\u0211:"r",\u0213:"r",\u1e5b:"r",\u1e5d:"r",\u0157:"r",\u1e5f:"r",\u024d:"r",\u027d:"r",\ua75b:"r",\ua7a7:"r",\ua783:"r","\u24e2":"s",\uff53:"s",\u00df:"s",\u015b:"s",\u1e65:"s",\u015d:"s",\u1e61:"s",\u0161:"s",\u1e67:"s",\u1e63:"s",\u1e69:"s",\u0219:"s",\u015f:"s",\u023f:"s",\ua7a9:"s",\ua785:"s",\u1e9b:"s","\u24e3":"t",\uff54:"t",\u1e6b:"t",\u1e97:"t",\u0165:"t",\u1e6d:"t",\u021b:"t",\u0163:"t",\u1e71:"t",\u1e6f:"t",\u0167:"t",\u01ad:"t",\u0288:"t",\u2c66:"t",\ua787:"t",\ua729:"tz","\u24e4":"u",\uff55:"u",\u00f9:"u",\u00fa:"u",\u00fb:"u",\u0169:"u",\u1e79:"u",\u016b:"u",\u1e7b:"u",\u016d:"u",\u00fc:"u",\u01dc:"u",\u01d8:"u",\u01d6:"u",\u01da:"u",\u1ee7:"u",\u016f:"u",\u0171:"u",\u01d4:"u",\u0215:"u",\u0217:"u",\u01b0:"u",\u1eeb:"u",\u1ee9:"u",\u1eef:"u",\u1eed:"u",\u1ef1:"u",\u1ee5:"u",\u1e73:"u",\u0173:"u",\u1e77:"u",\u1e75:"u",\u0289:"u","\u24e5":"v",\uff56:"v",\u1e7d:"v",\u1e7f:"v",\u028b:"v",\ua75f:"v",\u028c:"v",\ua761:"vy","\u24e6":"w",\uff57:"w",\u1e81:"w",\u1e83:"w",\u0175:"w",\u1e87:"w",\u1e85:"w",\u1e98:"w",\u1e89:"w",\u2c73:"w","\u24e7":"x",\uff58:"x",\u1e8b:"x",\u1e8d:"x","\u24e8":"y",\uff59:"y",\u1ef3:"y",\u00fd:"y",\u0177:"y",\u1ef9:"y",\u0233:"y",\u1e8f:"y",\u00ff:"y",\u1ef7:"y",\u1e99:"y",\u1ef5:"y",\u01b4:"y",\u024f:"y",\u1eff:"y","\u24e9":"z",\uff5a:"z",\u017a:"z",\u1e91:"z",\u017c:"z",\u017e:"z",\u1e93:"z",\u1e95:"z",\u01b6:"z",\u0225:"z",\u0240:"z",\u2c6c:"z",\ua763:"z",\u0386:"\u0391",\u0388:"\u0395",\u0389:"\u0397",\u038a:"\u0399",\u03aa:"\u0399",\u038c:"\u039f",\u038e:"\u03a5",\u03ab:"\u03a5",\u038f:"\u03a9",\u03ac:"\u03b1",\u03ad:"\u03b5",\u03ae:"\u03b7",\u03af:"\u03b9",\u03ca:"\u03b9",\u0390:"\u03b9",\u03cc:"\u03bf",\u03cd:"\u03c5",\u03cb:"\u03c5",\u03b0:"\u03c5",\u03c9:"\u03c9",\u03c2:"\u03c3"},n.fnOperators={equal:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?n.toLowerCase(t)===n.toLowerCase(e):t===e},notequal:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),!n.fnOperators.equal(t,e,i)},lessthan:function(t,e,i){return i?n.toLowerCase(t)n.toLowerCase(e):t>e},lessthanorequal:function(t,e,i){return i?n.toLowerCase(t)<=n.toLowerCase(e):(m(t)&&(t=void 0),t<=e)},greaterthanorequal:function(t,e,i){return i?n.toLowerCase(t)>=n.toLowerCase(e):t>=e},contains:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?!m(t)&&!m(e)&&-1!==n.toLowerCase(t).indexOf(n.toLowerCase(e)):!m(t)&&!m(e)&&-1!==t.toString().indexOf(e)},doesnotcontain:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?!m(t)&&!m(e)&&-1===n.toLowerCase(t).indexOf(n.toLowerCase(e)):!m(t)&&!m(e)&&-1===t.toString().indexOf(e)},isnotnull:function(t){return null!=t},isnull:function(t){return null==t},startswith:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.startsWith(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.startsWith(t,e)},doesnotstartwith:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.notStartsWith(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.notStartsWith(t,e)},like:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.like(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.like(t,e)},isempty:function(t){return void 0===t||""===t},isnotempty:function(t){return void 0!==t&&""!==t},wildcard:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?(t||"boolean"==typeof t)&&e&&"object"!=typeof t&&n.wildCard(n.toLowerCase(t),n.toLowerCase(e)):(t||"boolean"==typeof t)&&e&&n.wildCard(t,e)},endswith:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.endsWith(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.endsWith(t,e)},doesnotendwith:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.notEndsWith(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.notEndsWith(t,e)},processSymbols:function(t){var e=n.operatorSymbols[t];return e?n.fnOperators[e]:n.throwError("Query - Process Operator : Invalid operator")},processOperator:function(t){return n.fnOperators[t]||n.fnOperators.processSymbols(t)}},n.parse={parseJson:function(t){return"string"!=typeof t||!/^[\s]*\[|^[\s]*\{(.)+:/g.test(t)&&-1!==t.indexOf('"')?t instanceof Array?n.parse.iterateAndReviveArray(t):"object"==typeof t&&null!==t&&n.parse.iterateAndReviveJson(t):t=JSON.parse(t,n.parse.jsonReviver),t},iterateAndReviveArray:function(t){for(var e=0;e-1||e.indexOf("z")>-1,o=e.split(/[^0-9.]/);if(s){if(o[5].indexOf(".")>-1){var a=o[5].split(".");o[5]=a[0],o[6]=new Date(e).getUTCMilliseconds().toString()}else o[6]="00";e=n.dateParse.toTimeZone(new Date(parseInt(o[0],10),parseInt(o[1],10)-1,parseInt(o[2],10),parseInt(o[3],10),parseInt(o[4],10),parseInt(o[5]?o[5]:"00",10),parseInt(o[6],10)),n.serverTimezoneOffset,!1)}else{var l=new Date(parseInt(o[0],10),parseInt(o[1],10)-1,parseInt(o[2],10),parseInt(o[3],10),parseInt(o[4],10),parseInt(o[5]?o[5]:"00",10)),h=parseInt(o[6],10),c=parseInt(o[7],10);if(isNaN(h)&&isNaN(c))return l;e.indexOf("+")>-1?l.setHours(l.getHours()-h,l.getMinutes()-c):l.setHours(l.getHours()+h,l.getMinutes()+c),e=n.dateParse.toTimeZone(l,n.serverTimezoneOffset,!1)}null==n.serverTimezoneOffset&&(e=n.dateParse.addSelfOffset(e))}}return e},isJson:function(t){return"string"==typeof t[0]?t:n.parse.parseJson(t)},isGuid:function(t){return null!=/[A-Fa-f0-9]{8}(?:-[A-Fa-f0-9]{4}){3}-[A-Fa-f0-9]{12}/i.exec(t)},replacer:function(t,e){return n.isPlainObject(t)?n.parse.jsonReplacer(t,e):t instanceof Array?n.parse.arrayReplacer(t):t instanceof Date?n.parse.jsonReplacer({val:t},e).val:t},jsonReplacer:function(t,e){for(var i,s=0,o=Object.keys(t);s=0?"+":"-",s=function(a){var l=Math.floor(Math.abs(a));return(l<10?"0":"")+l};return e.getFullYear()+"-"+s(e.getMonth()+1)+"-"+s(e.getDate())+"T"+s(e.getHours())+":"+s(e.getMinutes())+":"+s(e.getSeconds())+r+s(i/60)+":"+s(i%60)}},n}(),Ml=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),BK={GroupGuid:"{271bbba0-1ee7}"},a5=function(){function n(t){this.options={from:"table",requestType:"json",sortBy:"sorted",select:"select",skip:"skip",group:"group",take:"take",search:"search",count:"requiresCounts",where:"where",aggregates:"aggregates",expand:"expand"},this.type=n,this.dataSource=t,this.pvt={}}return n.prototype.processResponse=function(t,e,i,r){return t},n}(),GE=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ml(t,n),t.prototype.processQuery=function(e,i){for(var a,l,p,r=e.dataSource.json.slice(0),s=r.length,o=!0,h={},c=0,d=[],u=[],f=0;f1?e.sort.filter(function(p){return p.fieldName===c})[0]:e.sort[0];s=this.onSortBy(s,d,e.query,!0)}e.page&&(s=this.onPage(s,e.page,e.query)),this.formGroupResult(s,h)}else{for(var o=e.lazyLoad.onDemandGroupInfo,a=o.where.length-1;a>=0;a--)s=this.onWhere(s,o.where[a]);if(e.group.length!==o.level)s=le.group(s,e.group[o.level].fieldName,r,null,null,e.group[o.level].comparer,!0),e.sort.length&&(s=this.onSortBy(s,e.sort[parseInt(o.level.toString(),10)],e.query,!0));else for(a=e.sort.length-1;a>=o.level;a--)s=this.onSortBy(s,e.sort[parseInt(a.toString(),10)],e.query,!1);i=s.length,h=s,s=(s=s.slice(o.skip)).slice(0,o.take),e.group.length!==o.level&&this.formGroupResult(s,h)}return{result:s,count:i}},t.prototype.formGroupResult=function(e,i){if(e.length&&i.length){var r="GroupGuid",s="childLevels",o="level",a="records";e[r]=i[r],e[s]=i[s],e[o]=i[o],e[a]=i[a]}return e},t.prototype.getAggregate=function(e){var i=jt.filterQueries(e.queries,"onAggregates"),r=[];if(i.length)for(var s=void 0,o=0;o=0;l--)a[l]&&(o=i.comparer,le.endsWith(a[l]," desc")&&(o=le.fnSort("descending"),a[l]=a[l].replace(" desc","")),e=le.sort(e,a[l],o));return e}return le.sort(e,s?"key":a,i.comparer)},t.prototype.onGroup=function(e,i,r){if(!e||!e.length)return e;var s=this.getAggregate(r);return le.group(e,le.getValue(i.fieldName,r),s,null,null,i.comparer)},t.prototype.onPage=function(e,i,r){var s=le.getValue(i.pageSize,r),o=(le.getValue(i.pageIndex,r)-1)*s;return e&&e.length?e.slice(o,o+s):e},t.prototype.onRange=function(e,i){return e&&e.length?e.slice(le.getValue(i.start),le.getValue(i.end)):e},t.prototype.onTake=function(e,i){return e&&e.length?e.slice(0,le.getValue(i.nos)):e},t.prototype.onSkip=function(e,i){return e&&e.length?e.slice(le.getValue(i.nos)):e},t.prototype.onSelect=function(e,i){return e&&e.length?le.select(e,le.getValue(i.fieldNames)):e},t.prototype.insert=function(e,i,r,s,o){return m(o)?e.dataSource.json.push(i):e.dataSource.json.splice(o,0,i)},t.prototype.remove=function(e,i,r,s){var a,o=e.dataSource.json;for("object"==typeof r&&!(r instanceof Date)&&(r=le.getObject(i,r)),a=0;a1&&(g="("+g+")"),p.filters.push(g);for(var y=0,S="object"==typeof p.filters[f]?Object.keys(p.filters[f]):[];y-1&&this.formRemoteGroupedData(e[s].items,i+1,r-1);var o="GroupGuid",h="records";return e[o]=BK[o],e.level=i,e.childLevels=r,e[h]=e[0].items.length?this.getGroupedRecords(e,!m(e[0].items[h])):[],e},t.prototype.getGroupedRecords=function(e,i){for(var r=[],o=0;ol.length-3?(l=l.substring(0,l.length-1),o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.endswith:le.odv4UniOperator.endswith):l.lastIndexOf("%")!==l.indexOf("%")&&l.lastIndexOf("%")>l.indexOf("%")+1?(l=l.substring(l.indexOf("%")+1,l.lastIndexOf("%")),o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains):o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains),l="'"+(l=encodeURIComponent(l))+"'";else if("wildcard"===o)if(-1!==l.indexOf("*")){var d=l.split("*"),u=void 0,p=0;if(0!==l.indexOf("*")&&-1===d[0].indexOf("%3f")&&-1===d[0].indexOf("?")&&(u="'"+(u=d[0])+"'",s+=(o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.startswith:le.odv4UniOperator.startswith)+"(",s+=c+",",a&&(s+=a),s+=u+")",p++),l.lastIndexOf("*")!==l.length-1&&-1===d[d.length-1].indexOf("%3f")&&-1===d[d.length-1].indexOf("?")&&(u="'"+(u=d[d.length-1])+"'",p>0&&(s+=" and "),s+=(o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.endswith:le.odv4UniOperator.endswith)+"(",s+=c+",",a&&(s+=a),s+=u+")",p++),d.length>2)for(var f=1;f0&&(s+=" and "),"substringof"===(o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains)||"not substringof"===o){var g=u;u=c,c=g}s+=o+"(",s+=c+",",a&&(s+=a),s+=u+")",p++}0===p?(o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains,(-1!==l.indexOf("?")||-1!==l.indexOf("%3f"))&&(l=-1!==l.indexOf("?")?l.split("?").join(""):l.split("%3f").join("")),l="'"+l+"'"):o="wildcard"}else o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains,(-1!==l.indexOf("?")||-1!==l.indexOf("%3f"))&&(l=-1!==l.indexOf("?")?l.split("?").join(""):l.split("%3f").join("")),l="'"+l+"'";return"substringof"!==o&&"not substringof"!==o||(g=l,l=c,c=g),"wildcard"!==o&&(s+=o+"(",s+=c+",",a&&(s+=a),s+=l+")"),s},t.prototype.addParams=function(e){n.prototype.addParams.call(this,e),delete e.reqParams.params},t.prototype.onComplexPredicate=function(e,i,r){for(var s=[],o=0;o-1;p--)!/\bContent-ID:/i.test(c[p])||!/\bHTTP.+201/.test(c[p])||(l=parseInt(/\bContent-ID: (\d+)/i.exec(c[p])[1],10),o.addedRecords[l]&&(h=le.parse.parseJson(/^\{.+\}/m.exec(c[p])[0]),ze({},o.addedRecords[l],this.processResponse(h))));return o}return null},t.prototype.compareAndRemove=function(e,i,r){var s=this;return m(i)||Object.keys(e).forEach(function(o){o!==r&&"@odata.etag"!==o&&(le.isPlainObject(e[o])?(s.compareAndRemove(e[o],i[o]),0===Object.keys(e[o]).filter(function(l){return"@odata.etag"!==l}).length&&delete e[o]):(e[o]===i[o]||e[o]&&i[o]&&e[o].valueOf()===i[o].valueOf())&&delete e[o])}),e},t}(fc),FK=function(n){function t(){var e=n.call(this)||this;return yt("beforeSend",fc.prototype.beforeSend,e),e}return Ml(t,n),t.prototype.insert=function(e,i,r,s,o){return this.pvt.position=o,this.updateType="add",{url:e.dataSource.insertUrl||e.dataSource.crudUrl||e.dataSource.url,data:JSON.stringify(ze({},{value:i,table:r,action:"insert"},le.getAddParams(this,e,s)))}},t.prototype.remove=function(e,i,r,s,o){return n.prototype.remove.call(this,e,i,r),{type:"POST",url:e.dataSource.removeUrl||e.dataSource.crudUrl||e.dataSource.url,data:JSON.stringify(ze({},{key:r,keyColumn:i,table:s,action:"remove"},le.getAddParams(this,e,o)))}},t.prototype.update=function(e,i,r,s,o){return this.updateType="update",this.updateKey=i,{type:"POST",url:e.dataSource.updateUrl||e.dataSource.crudUrl||e.dataSource.url,data:JSON.stringify(ze({},{value:r,action:"update",keyColumn:i,key:r[i],table:s},le.getAddParams(this,e,o)))}},t.prototype.processResponse=function(e,i,r,s,o,a,l){var h;if(e="batch"===(o?JSON.parse(o.data):e).action?le.parse.parseJson(e):e,"add"===this.updateType&&n.prototype.insert.call(this,i,e,null,null,this.pvt.position),"update"===this.updateType&&n.prototype.update.call(this,i,this.updateKey,e),this.updateType=void 0,e.added)for(h=0;hi&&h.push(c)}for(c=0;cthis.pageSize;)h.results.splice(0,1),h.keys.splice(0,1);return window.localStorage.setItem(this.guidId,JSON.stringify(h)),e},t.prototype.beforeSend=function(e,i,r){!m(this.cacheAdaptor.options.batch)&&le.endsWith(r.url,this.cacheAdaptor.options.batch)&&"post"===r.type.toLowerCase()&&i.headers.set("Accept",this.cacheAdaptor.options.multipartAccept),e.dataSource.crossDomain||i.headers.set("Accept",this.cacheAdaptor.options.accept)},t.prototype.update=function(e,i,r,s){return this.isCrudAction=!0,this.cacheAdaptor.update(e,i,r,s)},t.prototype.insert=function(e,i,r){return this.isInsertAction=!0,this.cacheAdaptor.insert(e,i,r)},t.prototype.remove=function(e,i,r,s){return this.isCrudAction=!0,this.cacheAdaptor.remove(e,i,r,s)},t.prototype.batchRequest=function(e,i,r){return this.cacheAdaptor.batchRequest(e,i,r)},t}(fc),nt=function(){function n(t,e,i){var s,r=this;return this.dateParse=!0,this.timeZoneHandling=!0,this.persistQuery={},this.isInitialLoad=!1,this.requests=[],this.isInitialLoad=!0,!t&&!this.dataSource&&(t=[]),i=i||t.adaptor,t&&!1===t.timeZoneHandling&&(this.timeZoneHandling=t.timeZoneHandling),t instanceof Array?s={json:t,offline:!0}:"object"==typeof t?(t.json||(t.json=[]),t.enablePersistence||(t.enablePersistence=!1),t.id||(t.id=""),t.ignoreOnPersist||(t.ignoreOnPersist=[]),s={url:t.url,insertUrl:t.insertUrl,removeUrl:t.removeUrl,updateUrl:t.updateUrl,crudUrl:t.crudUrl,batchUrl:t.batchUrl,json:t.json,headers:t.headers,accept:t.accept,data:t.data,timeTillExpiration:t.timeTillExpiration,cachingPageSize:t.cachingPageSize,enableCaching:t.enableCaching,requestType:t.requestType,key:t.key,crossDomain:t.crossDomain,jsonp:t.jsonp,dataType:t.dataType,offline:void 0!==t.offline?t.offline:!(t.adaptor instanceof FK||t.adaptor instanceof _K||t.url),requiresFormat:t.requiresFormat,enablePersistence:t.enablePersistence,id:t.id,ignoreOnPersist:t.ignoreOnPersist}):le.throwError("DataManager: Invalid arguments"),void 0===s.requiresFormat&&!le.isCors()&&(s.requiresFormat=!!m(s.crossDomain)||s.crossDomain),void 0===s.dataType&&(s.dataType="json"),this.dataSource=s,this.defaultQuery=e,this.dataSource.enablePersistence&&this.dataSource.id&&window.addEventListener("unload",this.setPersistData.bind(this)),s.url&&s.offline&&!s.json.length?(this.isDataAvailable=!1,this.adaptor=i||new vp,this.dataSource.offline=!1,this.ready=this.executeQuery(e||new jt),this.ready.then(function(o){r.dataSource.offline=!0,r.isDataAvailable=!0,s.json=o.result,r.adaptor=new GE})):this.adaptor=s.offline?new GE:new vp,!s.jsonp&&this.adaptor instanceof vp&&(s.jsonp="callback"),this.adaptor=i||this.adaptor,s.enableCaching&&(this.adaptor=new UK(this.adaptor,s.timeTillExpiration,s.cachingPageSize)),this}return Object.defineProperty(n.prototype,"moduleName",{get:function(){return"datamanager"},enumerable:!0,configurable:!0}),n.prototype.getPersistedData=function(t){var e=localStorage.getItem(t||this.dataSource.id);return JSON.parse(e)},n.prototype.setPersistData=function(t,e,i){localStorage.setItem(e||this.dataSource.id,JSON.stringify(i||this.persistQuery))},n.prototype.setPersistQuery=function(t){var e=this,i=this.getPersistedData();if(this.isInitialLoad&&i&&Object.keys(i).length){this.persistQuery=i,this.persistQuery.queries=this.persistQuery.queries.filter(function(s){if(e.dataSource.ignoreOnPersist&&e.dataSource.ignoreOnPersist.length&&s.fn&&e.dataSource.ignoreOnPersist.some(function(l){return s.fn===l}))return!1;if("onWhere"===s.fn){var o=s.e;if(o&&o.isComplex&&o.predicates instanceof Array){var a=o.predicates.map(function(l){if(l.predicates&&l.predicates instanceof Array){var h=l.predicates.map(function(v){return new Ss(v.field,v.operator,v.value,v.ignoreCase,v.ignoreAccent,v.matchCase)});return"and"===l.condition?Ss.and(h):Ss.or(h)}return new Ss(l.field,l.operator,l.value,l.ignoreCase,l.ignoreAccent,l.matchCase)});s.e=new Ss(a[0],o.condition,a.slice(1))}}return!0});var r=ze(new jt,this.persistQuery);return this.isInitialLoad=!1,r}return this.persistQuery=t,this.isInitialLoad=!1,t},n.prototype.setDefaultQuery=function(t){return this.defaultQuery=t,this},n.prototype.executeLocal=function(t){!this.defaultQuery&&!(t instanceof jt)&&le.throwError("DataManager - executeLocal() : A query is required to execute"),this.dataSource.json||le.throwError("DataManager - executeLocal() : Json data is required to execute"),this.dataSource.enablePersistence&&this.dataSource.id&&(t=this.setPersistQuery(t));var e=this.adaptor.processQuery(this,t=t||this.defaultQuery);if(t.subQuery){var i=t.subQuery.fromTable,r=t.subQuery.lookups,s=t.isCountRequired?e.result:e;r&&r instanceof Array&&le.buildHierarchy(t.subQuery.fKey,i,s,r,t.subQuery.key);for(var o=0;oli");P.classList.remove("json-parent");for(var j=0;j',W=ve.children[0].placeholder}return W}function Q(k,W,ve){!m(ve)&&""!==ve&&K(W,ve.split(" ")),!m(k)&&""!==k&&V(W,k.split(" "))}function oe(k,W,ve){if("multiselect"===ve||function Mo(k){if(!k)return!1;for(var W=k;W&&W!==document.body;){if("none"===window.getComputedStyle(W).display)return!1;W=W.parentElement}return!0}(k)){var Te="multiselect"===ve?k:k.clientWidth-parseInt(getComputedStyle(k,null).getPropertyValue("padding-left"),10);!m(W)&&!m(W.getElementsByClassName("e-float-text-content")[0])&&(W.getElementsByClassName("e-float-text-content")[0].classList.contains("e-float-text-overflow")&&W.getElementsByClassName("e-float-text-content")[0].classList.remove("e-float-text-overflow"),(Te0)for(var Ye=0;Ye<_e.length;Ye++)_e[parseInt(Ye.toString(),10)].addEventListener("mousedown",wo,!1),_e[parseInt(Ye.toString(),10)].addEventListener("mouseup",Hl,!1);else if(_e.length>0)for(Ye=0;Ye<_e.length;Ye++)_e[parseInt(Ye.toString(),10)].removeEventListener("mousedown",wo,this),_e[parseInt(Ye.toString(),10)].removeEventListener("mouseup",Hl,this)}function wo(){for(var W=this.parentElement;!W.classList.contains("e-input-group");)W=W.parentElement;!function ya(k,W){!k.classList.contains("e-disabled")&&!k.querySelector("input").readOnly&&W.classList.add("e-input-btn-ripple")}(W,this)}function Hl(){var k=this;setTimeout(function(){k.classList.remove("e-input-btn-ripple")},500)}function Sb(k,W){var ve=W("span",{className:k});return ve.classList.add("e-input-group-icon"),ve}function I_(k,W,ve,Te){var _e=m(Te)?mi:Te,Ye=Sb(k,_e);W.classList.add("e-float-icon-left");var fi=W.querySelector(".e-input-in-wrap");if(m(fi)){fi=_e("span",{className:"e-input-in-wrap"}),ve.parentNode.insertBefore(fi,ve);var Gs=W.querySelectorAll(ve.tagName+" ~ *");fi.appendChild(ve);for(var Kn=0;Kn-1)if("class"===_e){var Ye=this.getInputValidClassList(k[""+_e]);""!==Ye&&V([W],Ye.split(" "))}else if("style"===_e){var fi=W.getAttribute(_e);fi=m(fi)?k[""+_e]:fi+k[""+_e],W.setAttribute(_e,fi)}else W.setAttribute(_e,k[""+_e])}},n.isBlank=function Hle(k){return!k||/^\s*$/.test(k)}}(Le||(Le={})),new RegExp("^(-)?(\\d*)$"),new RegExp("^[A-Za-z0-9._%+-]{1,}@[A-Za-z0-9._%+-]{1,}([.]{1}[a-zA-Z0-9]{2,}|[.]{1}[a-zA-Z0-9]{2,4}[.]{1}[a-zA-Z0-9]{2,4})$"),new RegExp("^([0-9]{4})-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])$"),new RegExp("^[0-9]*$"),new RegExp("^[+]?[0-9]{9,13}$"),new RegExp("^\\d{13,16}$");var me=function(){function n(t,e){this.width=t,this.height=e}return n.prototype.isEmpty=function(){return 0===this.height&&0===this.width},n.prototype.clone=function(){return new n(this.width,this.height)},n}(),Rie=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),KB=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},z=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Rie(t,n),t.equals=function(e,i){return e===i||!(!e||!i)&&(!e||!i||e.x===i.x&&e.y===i.y)},t.isEmptyPoint=function(e){return!(e.x&&e.y)},t.transform=function(e,i,r){var s={x:0,y:0};return s.x=Math.round(100*(e.x+r*Math.cos(i*Math.PI/180)))/100,s.y=Math.round(100*(e.y+r*Math.sin(i*Math.PI/180)))/100,s},t.findLength=function(e,i){return Math.sqrt(Math.pow(e.x-i.x,2)+Math.pow(e.y-i.y,2))},t.findAngle=function(e,i){var r=Math.atan2(i.y-e.y,i.x-e.x);return r=180*r/Math.PI,(r%=360)<0&&(r+=360),r},t.distancePoints=function(e,i){return Math.sqrt(Math.pow(i.x-e.x,2)+Math.pow(i.y-e.y,2))},t.getLengthFromListOfPoints=function(e){for(var i=0,r=0;ri.y&&!r?o.y+=s:o.y-=s:e.y===i.y?e.xi.x&&!r?o.x+=s:o.x-=s:r?(a=this.findAngle(e,i),o=this.transform(e,a,s)):(a=this.findAngle(i,e),o=this.transform(i,a,s)),o},t.direction=function(e,i){return Math.abs(i.x-e.x)>Math.abs(i.y-e.y)?e.x0)for(var r=0;rt.right||this.top>t.bottom||this.bottom=t.right&&this.top<=t.top&&this.bottom>=t.bottom},n.prototype.containsPoint=function(t,e){return void 0===e&&(e=0),this.left-e<=t.x&&this.right+e>=t.x&&this.top-e<=t.y&&this.bottom+e>=t.y},n.toBounds=function(t){for(var e=new n,i=0,r=t;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},s3=function(n){if(n)switch(n.type){case"Linear":default:return wI;case"Radial":return Gie}return wI},Yie=function(){return function n(t,e,i,r){this.left=t,this.right=e,this.top=i,this.bottom=r}}(),$n=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),it([I(0)],t.prototype,"left",void 0),it([I(0)],t.prototype,"right",void 0),it([I(0)],t.prototype,"top",void 0),it([I(0)],t.prototype,"bottom",void 0),t}(Ee),Qie=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),it([I(45)],t.prototype,"angle",void 0),it([I(5)],t.prototype,"distance",void 0),it([I(.7)],t.prototype,"opacity",void 0),it([I("lightgrey")],t.prototype,"color",void 0),t}(Ee),o3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),t.prototype.getClassName=function(){return"Stop"},it([I("")],t.prototype,"color",void 0),it([I(0)],t.prototype,"offset",void 0),it([I(1)],t.prototype,"opacity",void 0),t}(Ee),Cx=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),it([Bt([],o3)],t.prototype,"stops",void 0),it([I("None")],t.prototype,"type",void 0),it([I("")],t.prototype,"id",void 0),t}(Ee),wI=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),it([I(0)],t.prototype,"x1",void 0),it([I(0)],t.prototype,"x2",void 0),it([I(0)],t.prototype,"y1",void 0),it([I(0)],t.prototype,"y2",void 0),t}(Cx),Gie=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),it([I(0)],t.prototype,"cx",void 0),it([I(0)],t.prototype,"cy",void 0),it([I(0)],t.prototype,"fx",void 0),it([I(0)],t.prototype,"fy",void 0),it([I(50)],t.prototype,"r",void 0),t}(Cx),Ll=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),it([I("white")],t.prototype,"fill",void 0),it([I("black")],t.prototype,"strokeColor",void 0),it([I("")],t.prototype,"strokeDashArray",void 0),it([I(1)],t.prototype,"strokeWidth",void 0),it([I(1)],t.prototype,"opacity",void 0),it([A0(s3)],t.prototype,"gradient",void 0),t}(Ee),a3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),it([I("transparent")],t.prototype,"fill",void 0),t}(Ll),qp=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),it([I("black")],t.prototype,"color",void 0),it([I("Arial")],t.prototype,"fontFamily",void 0),it([I(12)],t.prototype,"fontSize",void 0),it([I(!1)],t.prototype,"italic",void 0),it([I(!1)],t.prototype,"bold",void 0),it([I("CollapseSpace")],t.prototype,"whiteSpace",void 0),it([I("WrapWithOverflow")],t.prototype,"textWrapping",void 0),it([I("Center")],t.prototype,"textAlign",void 0),it([I("None")],t.prototype,"textDecoration",void 0),it([I("Wrap")],t.prototype,"textOverflow",void 0),it([I("transparent")],t.prototype,"fill",void 0),t}(Ll),on=function(n){return n[n.Default=0]="Default",n[n.expandNode=2]="expandNode",n[n.interaction=4]="interaction",n[n.GroupingInProgress=8]="GroupingInProgress",n[n.GroupClipboardInProcess=16]="GroupClipboardInProcess",n[n.ClearObject=32]="ClearObject",n}(on||{}),hi=function(n){return n[n.Visible=1]="Visible",n[n.Hidden=2]="Hidden",n[n.Hover=4]="Hover",n[n.Connect=8]="Connect",n}(hi||{}),Kt=function(n){return n[n.None=0]="None",n[n.ShowHorizontalLines=1]="ShowHorizontalLines",n[n.ShowVerticalLines=2]="ShowVerticalLines",n[n.ShowLines=3]="ShowLines",n[n.SnapToHorizontalLines=4]="SnapToHorizontalLines",n[n.SnapToVerticalLines=8]="SnapToVerticalLines",n[n.SnapToLines=12]="SnapToLines",n[n.SnapToObject=16]="SnapToObject",n[n.All=31]="All",n}(Kt||{}),mr=function(n){return n[n.None=1]="None",n[n.ConnectorSourceThumb=2]="ConnectorSourceThumb",n[n.ConnectorTargetThumb=4]="ConnectorTargetThumb",n[n.ResizeSouthEast=8]="ResizeSouthEast",n[n.ResizeSouthWest=16]="ResizeSouthWest",n[n.ResizeNorthEast=32]="ResizeNorthEast",n[n.ResizeNorthWest=64]="ResizeNorthWest",n[n.ResizeEast=128]="ResizeEast",n[n.ResizeWest=256]="ResizeWest",n[n.ResizeSouth=512]="ResizeSouth",n[n.ResizeNorth=1024]="ResizeNorth",n[n.Rotate=2048]="Rotate",n[n.UserHandle=4096]="UserHandle",n[n.ToolTip=8192]="ToolTip",n[n.ResizeAll=2046]="ResizeAll",n[n.All=16382]="All",n}(mr||{}),qe=function(n){return n[n.None=1]="None",n[n.Select=2]="Select",n[n.Delete=4]="Delete",n[n.Drag=8]="Drag",n[n.DragSourceEnd=16]="DragSourceEnd",n[n.DragTargetEnd=32]="DragTargetEnd",n[n.DragSegmentThumb=64]="DragSegmentThumb",n[n.AllowDrop=128]="AllowDrop",n[n.Bridging=256]="Bridging",n[n.BridgeObstacle=512]="BridgeObstacle",n[n.InheritBridging=1024]="InheritBridging",n[n.PointerEvents=2048]="PointerEvents",n[n.Tooltip=4096]="Tooltip",n[n.InheritTooltip=8192]="InheritTooltip",n[n.Interaction=4218]="Interaction",n[n.ReadOnly=16384]="ReadOnly",n[n.LineRouting=32768]="LineRouting",n[n.InheritLineRouting=65536]="InheritLineRouting",n[n.ConnectToNearByNode=131072]="ConnectToNearByNode",n[n.ConnectToNearByPort=262144]="ConnectToNearByPort",n[n.ConnectToNearByElement=393216]="ConnectToNearByElement",n[n.InheritSegmentThumbShape=524288]="InheritSegmentThumbShape",n[n.InheritSegmentThumbSize=1048576]="InheritSegmentThumbSize",n[n.Default=2043454]="Default",n}(qe||{}),Lr=function(n){return n[n.ReadOnly=2]="ReadOnly",n[n.InheritReadOnly=4]="InheritReadOnly",n[n.Select=8]="Select",n[n.Drag=16]="Drag",n[n.Resize=32]="Resize",n[n.Rotate=64]="Rotate",n[n.Tooltip=128]="Tooltip",n[n.Interaction=120]="Interaction",n[n.None=0]="None",n}(Lr||{}),ie=function(n){return n[n.None=0]="None",n[n.Select=2]="Select",n[n.Drag=4]="Drag",n[n.Rotate=8]="Rotate",n[n.Shadow=16]="Shadow",n[n.PointerEvents=32]="PointerEvents",n[n.Delete=64]="Delete",n[n.InConnect=128]="InConnect",n[n.OutConnect=256]="OutConnect",n[n.Individual=512]="Individual",n[n.Expandable=1024]="Expandable",n[n.AllowDrop=2048]="AllowDrop",n[n.Inherit=78]="Inherit",n[n.ResizeNorthEast=4096]="ResizeNorthEast",n[n.ResizeEast=8192]="ResizeEast",n[n.ResizeSouthEast=16384]="ResizeSouthEast",n[n.ResizeSouth=32768]="ResizeSouth",n[n.ResizeSouthWest=65536]="ResizeSouthWest",n[n.ResizeWest=131072]="ResizeWest",n[n.ResizeNorthWest=262144]="ResizeNorthWest",n[n.ResizeNorth=524288]="ResizeNorth",n[n.Resize=1044480]="Resize",n[n.AspectRatio=1048576]="AspectRatio",n[n.Tooltip=2097152]="Tooltip",n[n.InheritTooltip=4194304]="InheritTooltip",n[n.ReadOnly=8388608]="ReadOnly",n[n.HideThumbs=16777216]="HideThumbs",n[n.AllowMovingOutsideLane=33554432]="AllowMovingOutsideLane",n[n.Default=5240814]="Default",n}(ie||{}),Xr=function(n){return n[n.None=0]="None",n[n.ElementIsPort=2]="ElementIsPort",n[n.ElementIsGroup=4]="ElementIsGroup",n[n.HorizontalLaneHeader=8]="HorizontalLaneHeader",n}(Xr||{}),bt=function(n){return n[n.Rotate=2]="Rotate",n[n.ConnectorSource=4]="ConnectorSource",n[n.ConnectorTarget=8]="ConnectorTarget",n[n.ResizeNorthEast=16]="ResizeNorthEast",n[n.ResizeEast=32]="ResizeEast",n[n.ResizeSouthEast=64]="ResizeSouthEast",n[n.ResizeSouth=128]="ResizeSouth",n[n.ResizeSouthWest=256]="ResizeSouthWest",n[n.ResizeWest=512]="ResizeWest",n[n.ResizeNorthWest=1024]="ResizeNorthWest",n[n.ResizeNorth=2048]="ResizeNorth",n[n.Default=4094]="Default",n}(bt||{}),rt=function(n){return n[n.None=1]="None",n[n.Bridging=2]="Bridging",n[n.UndoRedo=4]="UndoRedo",n[n.Tooltip=8]="Tooltip",n[n.UserInteraction=16]="UserInteraction",n[n.ApiUpdate=32]="ApiUpdate",n[n.PageEditable=48]="PageEditable",n[n.Zoom=64]="Zoom",n[n.PanX=128]="PanX",n[n.PanY=256]="PanY",n[n.Pan=384]="Pan",n[n.ZoomTextEdit=512]="ZoomTextEdit",n[n.Virtualization=1024]="Virtualization",n[n.LineRouting=2048]="LineRouting",n[n.Default=500]="Default",n}(rt||{}),Ci=function(n){return n[n.None=0]="None",n[n.SingleSelect=1]="SingleSelect",n[n.MultipleSelect=2]="MultipleSelect",n[n.ZoomPan=4]="ZoomPan",n[n.DrawOnce=8]="DrawOnce",n[n.ContinuousDraw=16]="ContinuousDraw",n[n.Default=3]="Default",n}(Ci||{}),Ya=function(n){return n[n.Self=1]="Self",n[n.Parent=2]="Parent",n}(Ya||{}),pt=function(n){return n[n.None=0]="None",n[n.Control=1]="Control",n[n.Meta=1]="Meta",n[n.Alt=2]="Alt",n[n.Shift=4]="Shift",n}(pt||{}),Mt=function(n){return n[n.None=null]="None",n[n.Number0=0]="Number0",n[n.Number1=1]="Number1",n[n.Number2=2]="Number2",n[n.Number3=3]="Number3",n[n.Number4=4]="Number4",n[n.Number5=5]="Number5",n[n.Number6=6]="Number6",n[n.Number7=7]="Number7",n[n.Number8=8]="Number8",n[n.Number9=9]="Number9",n[n.A=65]="A",n[n.B=66]="B",n[n.C=67]="C",n[n.D=68]="D",n[n.E=69]="E",n[n.F=70]="F",n[n.G=71]="G",n[n.H=72]="H",n[n.I=73]="I",n[n.J=74]="J",n[n.K=75]="K",n[n.L=76]="L",n[n.M=77]="M",n[n.N=78]="N",n[n.O=79]="O",n[n.P=80]="P",n[n.Q=81]="Q",n[n.R=82]="R",n[n.S=83]="S",n[n.T=84]="T",n[n.U=85]="U",n[n.V=86]="V",n[n.W=87]="W",n[n.X=88]="X",n[n.Y=89]="Y",n[n.Z=90]="Z",n[n.Left=37]="Left",n[n.Up=38]="Up",n[n.Right=39]="Right",n[n.Down=40]="Down",n[n.Escape=27]="Escape",n[n.Space=32]="Space",n[n.PageUp=33]="PageUp",n[n.PageDown=34]="PageDown",n[n.End=35]="End",n[n.Home=36]="Home",n[n.Delete=46]="Delete",n[n.Tab=9]="Tab",n[n.Enter=13]="Enter",n[n.BackSpace=8]="BackSpace",n[n.F1=112]="F1",n[n.F2=113]="F2",n[n.F3=114]="F3",n[n.F4=115]="F4",n[n.F5=116]="F5",n[n.F6=117]="F6",n[n.F7=118]="F7",n[n.F8=119]="F8",n[n.F9=120]="F9",n[n.F10=121]="F10",n[n.F11=122]="F11",n[n.F12=123]="F12",n[n.Star=56]="Star",n[n.Plus=187]="Plus",n[n.Minus=189]="Minus",n[n.BracketLeft=219]="BracketLeft",n[n.BracketRight=221]="BracketRight",n}(Mt||{}),ee=function(n){return n[n.Render=2]="Render",n[n.PublicMethod=4]="PublicMethod",n[n.ToolAction=8]="ToolAction",n[n.UndoRedo=16]="UndoRedo",n[n.TextEdit=32]="TextEdit",n[n.Group=64]="Group",n[n.Clear=128]="Clear",n[n.PreventClearSelection=256]="PreventClearSelection",n[n.Interactions=512]="Interactions",n[n.PreventHistory=1024]="PreventHistory",n[n.PreventIconsUpdate=2048]="PreventIconsUpdate",n[n.PreventCollectionChangeOnDragOver=4096]="PreventCollectionChangeOnDragOver",n[n.PreventZIndexOnDragging=8192]="PreventZIndexOnDragging",n[n.isGroupDragging=16384]="isGroupDragging",n[n.DragUsingMouse=32768]="DragUsingMouse",n[n.DecoratorPropertyChange=65536]="DecoratorPropertyChange",n[n.PreventLaneContainerUpdate=131072]="PreventLaneContainerUpdate",n}(ee||{}),Qa=function(n){return n[n.None=2]="None",n[n.DrawSelectorBorder=4]="DrawSelectorBorder",n[n.PreventRenderSelector=8]="PreventRenderSelector",n}(Qa||{}),$i=function(n){return n[n.None=0]="None",n[n.PreventDrag=2]="PreventDrag",n[n.PreventScale=4]="PreventScale",n[n.PreventDataInit=8]="PreventDataInit",n[n.hScrollbarMoved=16]="hScrollbarMoved",n[n.vScrollbarMoved=32]="vScrollbarMoved",n[n.AnimationClick=64]="AnimationClick",n[n.EnableGroupAction=128]="EnableGroupAction",n[n.PanInProgress=256]="PanInProgress",n[n.OverViewAction=512]="OverViewAction",n}($i||{}),ca=function(n){return n[n.None=0]="None",n[n.PropertyChange=1024]="PropertyChange",n[n.Interaction=2048]="Interaction",n}(ca||{}),Ae=function(n){return n[n.Zero=0]="Zero",n[n.One=1]="One",n[n.Two=2]="Two",n[n.Three=3]="Three",n[n.Four=4]="Four",n[n.Five=5]="Five",n}(Ae||{}),Ce=function(n){return n[n.collectionChange=0]="collectionChange",n[n.rotateChange=1]="rotateChange",n[n.positionChange=2]="positionChange",n[n.propertyChange=3]="propertyChange",n[n.selectionChange=4]="selectionChange",n[n.sizeChange=5]="sizeChange",n[n.drop=6]="drop",n[n.sourcePointChange=7]="sourcePointChange",n[n.targetPointChange=8]="targetPointChange",n[n.connectionChange=9]="connectionChange",n[n.animationComplete=10]="animationComplete",n[n.click=11]="click",n[n.doubleClick=12]="doubleClick",n[n.scrollChange=13]="scrollChange",n[n.dragEnter=14]="dragEnter",n[n.dragLeave=15]="dragLeave",n[n.dragOver=16]="dragOver",n[n.textEdit=17]="textEdit",n[n.paletteSelectionChange=18]="paletteSelectionChange",n[n.historyChange=19]="historyChange",n[n.mouseEnter=20]="mouseEnter",n[n.mouseLeave=21]="mouseLeave",n[n.mouseOver=22]="mouseOver",n[n.expandStateChange=23]="expandStateChange",n[n.segmentCollectionChange=24]="segmentCollectionChange",n[n.commandExecute=25]="commandExecute",n[n.historyStateChange=26]="historyStateChange",n[n.onUserHandleMouseDown=27]="onUserHandleMouseDown",n[n.onUserHandleMouseUp=28]="onUserHandleMouseUp",n[n.onUserHandleMouseEnter=29]="onUserHandleMouseEnter",n[n.onUserHandleMouseLeave=30]="onUserHandleMouseLeave",n[n.onImageLoad=31]="onImageLoad",n[n.onDoBindingInit=32]="onDoBindingInit",n[n.keyUp=33]="keyUp",n[n.keyDown=34]="keyDown",n[n.fixedUserHandleClick=35]="fixedUserHandleClick",n[n.elementDraw=36]="elementDraw",n[n.mouseWheel=37]="mouseWheel",n[n.segmentChange=38]="segmentChange",n[n.onFixedUserHandleMouseDown=39]="onFixedUserHandleMouseDown",n[n.onFixedUserHandleMouseUp=40]="onFixedUserHandleMouseUp",n[n.onFixedUserHandleMouseEnter=41]="onFixedUserHandleMouseEnter",n[n.onFixedUserHandleMouseLeave=42]="onFixedUserHandleMouseLeave",n[n.loaded=43]="loaded",n}(Ce||{}),ri=function(n){return n[n.None=1]="None",n[n.Drag=2]="Drag",n[n.Draw=4]="Draw",n[n.InConnect=8]="InConnect",n[n.OutConnect=16]="OutConnect",n[n.ToolTip=32]="ToolTip",n[n.InheritTooltip=64]="InheritTooltip",n[n.Default=24]="Default",n}(ri||{}),Ex=function(n){return n[n.None=1]="None",n[n.Source=2]="Source",n[n.Target=4]="Target",n[n.Intermediate=8]="Intermediate",n[n.All=14]="All",n}(Ex||{}),CI=function(n){return n[n.None=0]="None",n[n.SymmetricAngle=2]="SymmetricAngle",n[n.SymmetricDistance=4]="SymmetricDistance",n[n.Default=6]="Default",n}(CI||{}),as=function(){function n(){this.pivot={x:.5,y:.5},this.isDirt=!0,this.isExport=!1,this.exportScaleValue={x:0,y:0},this.exportScaleOffset={x:0,y:0},this.canApplyStyle=!0,this.visible=!0,this.offsetX=0,this.offsetY=0,this.cornerRadius=0,this.minHeight=void 0,this.minWidth=void 0,this.maxWidth=void 0,this.maxHeight=void 0,this.width=void 0,this.height=void 0,this.rotateAngle=0,this.margin={left:0,right:0,top:0,bottom:0},this.connectionDirection="Auto",this.horizontalAlignment="Auto",this.verticalAlignment="Auto",this.flip="None",this.flipMode="All",this.relativeMode="Point",this.transform=Ya.Self|Ya.Parent,this.style={fill:"white",strokeColor:"black",opacity:1,strokeWidth:1},this.desiredSize=new me,this.actualSize=new me,this.parentTransform=0,this.preventContainer=!1,this.isSvgRender=!1,this.bounds=new Ne(0,0,0,0),this.shadow=null,this.description="",this.staticSize=!1,this.shapeType="",this.isRectElement=!1,this.isCalculateDesiredSize=!0,this.flipOffset={x:0,y:0},this.elementActions=Xr.None,this.inversedAlignment=!0,this.position=void 0,this.unitMode=void 0,this.float=!1,this.floatingBounds=void 0}return n.prototype.setOffsetWithRespectToBounds=function(t,e,i){this.unitMode=i,this.position={x:t,y:e}},n.prototype.getAbsolutePosition=function(t){if(void 0!==this.position)return"Absolute"===this.unitMode?this.position:{x:this.position.x*t.width,y:this.position.y*t.height}},Object.defineProperty(n.prototype,"outerBounds",{get:function(){return this.floatingBounds||this.bounds},set:function(t){this.floatingBounds=t},enumerable:!0,configurable:!0}),n.prototype.measure=function(t,e,i){var s=void 0!==this.height?this.height:(t.height||0)-this.margin.top-this.margin.bottom;return this.id&&0===s&&this.elementActions&Xr.HorizontalLaneHeader&&(s=this.actualSize.height),this.desiredSize=new me(void 0!==this.width?this.width:(t.width||0)-this.margin.left-this.margin.right,s),this.isCalculateDesiredSize&&(this.desiredSize=this.validateDesiredSize(this.desiredSize,t)),this.desiredSize},n.prototype.arrange=function(t){return this.actualSize=t,this.updateBounds(),this.actualSize},n.prototype.updateBounds=function(){this.bounds=yr(this)},n.prototype.validateDesiredSize=function(t,e){return this.isRectElement&&!this.width&&!this.minWidth&&!this.maxWidth&&(t.width=50),this.isRectElement&&!this.height&&!this.minHeight&&!this.maxHeight&&(t.height=50),(void 0===t||void 0!==this.width&&void 0!==this.height)&&((t=t||new me).width=void 0===this.width?(e.width||0)-this.margin.left-this.margin.right:this.width,t.height=void 0===this.height?(e.height||0)-this.margin.top-this.margin.bottom:this.height),void 0!==this.minWidth&&(t.width=Math.max(t.width,this.minWidth)),void 0!==this.minHeight&&(t.height=Math.max(t.height,this.minHeight)),void 0!==this.maxWidth&&0!==this.maxWidth&&(t.width=Math.min(t.width,this.maxWidth)),void 0!==this.maxHeight&&0!==this.maxHeight&&(t.height=Math.min(t.height,this.maxHeight)),t},n}(),ere=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Cs=function(n){function t(){var e=null!==n&&n.apply(this,arguments)||this;return e.padding=new Yie(0,0,0,0),e.desiredBounds=void 0,e.measureChildren=!0,e.prevRotateAngle=0,e}return ere(t,n),t.prototype.hasChildren=function(){return void 0!==this.children&&this.children.length>0},t.prototype.measure=function(e,i,r){this.desiredBounds=void 0;var o,a,s=void 0;if(this.hasChildren()){for(var l=0;l=n.width&&s.length>0)i[i.length]={text:s,x:0,dy:0,width:o},s="";else{(s+=a[r+1]||"").indexOf("\n")>-1&&(i[i.length]={text:s,x:0,dy:0,width:_c(s,n)},s="");var l=_c(s,n);Math.ceil(l)+2>=n.width&&s.length>0&&(i[i.length]={text:s,x:0,dy:0,width:l},s=""),r===a.length-1&&s.length>0&&(i[i.length]={text:s,x:0,dy:0,width:l},s="")}else i=function Soe(n,t,e){var c,d,u,p,i=[],r="",s=0,o=0,a="nowrap"!==n.whiteSpace,h=(t||n.content).split("\n");for(s=0;s0?" ":"")+c[parseInt(o.toString(),10)];var f=_c(d=c[o+1]?r+" "+c[o+1]:r,n);Math.floor(f)>(e||n.width)-2&&r.length>0?(i[i.length]={text:r,x:0,dy:0,width:d===r?f:r===p?u:_c(r,n)},r=""):o===c.length-1&&(i[i.length]={text:r,x:0,dy:0,width:f},r=""),p=d,u=f}return i}(n,t,e);else i[i.length]={text:a,x:0,dy:0,width:_c(a,n)};return i}(l,r,n.isLaneOrientation?i:void 0),n.wrapBounds=a=function Ioe(n,t){var r,s,e={x:0,width:0},i=0;for(i=0;in.width&&("Ellipsis"===n.textOverflow||"Clip"===n.textOverflow)?0:-r/2:"right"===n.textAlign?-r:t.length>1?0:-r/2,t[parseInt(i.toString(),10)].dy=1.2*n.fontSize,t[parseInt(i.toString(),10)].x=r,e.x=Math.min(e.x,r),e.width=Math.max(e.width,s);return e}(l,o),s.width=a.width,n.wrapBounds.width>=i&&"Wrap"!==l.textOverflow&&(s.width=i),s.height=o.length*n.style.fontSize*1.2,s}(this,0,0,this.isLaneOrientation?e.height:this.width||e.width):this.desiredSize,this.desiredSize=void 0===this.width||void 0===this.height?new me(i.width,i.height):new me(this.width,this.height),this.desiredSize=this.validateDesiredSize(this.desiredSize,e),this.desiredSize},t.prototype.arrange=function(e){return(e.width!==this.actualSize.width||e.height!==this.actualSize.height||this.isDirt)&&(this.doWrap=!0),this.actualSize=e,this.updateBounds(),this.isDirt=!1,this.actualSize},t}(as),ire=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Ii=function(n){function t(){var e=null!==n&&n.apply(this,arguments)||this;return e.measureChildren=void 0,e}return ire(t,n),t.prototype.measure=function(e,i,r){var s=void 0,o=void 0;if(this.hasChildren()){for(var a=0,l=this.children;a=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Td=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return are(t,n),Oh([I("")],t.prototype,"content",void 0),Oh([I("TopLeft")],t.prototype,"position",void 0),Oh([I("Mouse")],t.prototype,"relativeMode",void 0),Oh([I(!0)],t.prototype,"showTipPointer",void 0),Oh([I("auto")],t.prototype,"width",void 0),Oh([I("auto")],t.prototype,"height",void 0),Oh([I("Auto")],t.prototype,"openOn",void 0),Oh([I()],t.prototype,"animation",void 0),Oh([I(!1)],t.prototype,"isSticky",void 0),t}(Ee);function l3(n){var t=new bh;t=h3(n.tooltip,t);var e=new bh(t);return e.beforeCollision=hre,e.beforeOpen=lre,e.cssClass="e-diagram-tooltip",e.opensOn="custom",e.appendTo("#"+n.element.id),e.close(),e}function lre(n){(""===this.content||void 0===this.content)&&(n.element.style.display="none")}function hre(n){n.collidedPosition&&n.collidedPosition!==this.position&&(n.element.style.display="none")}function Dx(n,t){var e=n.tooltipObject;return h3(t?t.tooltip:n.tooltip,e),e}function h3(n,t){return n.content?(t.content=n.content,"string"==typeof n.content&&(t.content=ko(function(){return n.content})),t.position=n.position,t.showTipPointer=n.showTipPointer,t.width=n.width,t.height=n.height,t.animation=n.animation?n.animation:{close:{effect:"None"}}):t.close(),t}var xx=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Hn=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Tx=function(n){function t(e,i,r,s){var o=n.call(this,e,i,r,s)||this;return o.inEdges=[],o.outEdges=[],o}return xx(t,n),Hn([I("")],t.prototype,"id",void 0),Hn([I("Center")],t.prototype,"horizontalAlignment",void 0),Hn([I("Center")],t.prototype,"verticalAlignment",void 0),Hn([re({},$n)],t.prototype,"margin",void 0),Hn([I(12)],t.prototype,"width",void 0),Hn([I(12)],t.prototype,"height",void 0),Hn([re({},Ll)],t.prototype,"style",void 0),Hn([I("Square")],t.prototype,"shape",void 0),Hn([I("Auto")],t.prototype,"connectionDirection",void 0),Hn([I(hi.Connect)],t.prototype,"visibility",void 0),Hn([I("")],t.prototype,"pathData",void 0),Hn([I(ri.Default)],t.prototype,"constraints",void 0),Hn([I()],t.prototype,"addInfo",void 0),Hn([I()],t.prototype,"outEdges",void 0),Hn([I()],t.prototype,"inEdges",void 0),Hn([re({},Td)],t.prototype,"tooltip",void 0),t}(Ee),Es=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return xx(t,n),t.prototype.getClassName=function(){return"PointPort"},Hn([re({x:.5,y:.5},z)],t.prototype,"offset",void 0),t}(Tx),Ac=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return xx(t,n),t.prototype.getClassName=function(){return"PathPort"},Hn([I(.5)],t.prototype,"offset",void 0),Hn([re({x:0,y:0},z)],t.prototype,"displacement",void 0),Hn([I("Center")],t.prototype,"alignment",void 0),t}(Tx),xI=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),lr=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},cre=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return xI(t,n),lr([I("blue")],t.prototype,"color",void 0),lr([I("")],t.prototype,"content",void 0),lr([I("")],t.prototype,"link",void 0),lr([I("None")],t.prototype,"textDecoration",void 0),lr([I("NewTab")],t.prototype,"hyperlinkOpenState",void 0),t}(Ee),Ax=function(n){function t(e,i,r,s){var o=n.call(this,e,i,r,s)||this;return r.id||(o.id=e.parentObj&&e.parentObj.propName&&"phases"===e.parentObj.propName?e.parentObj.id:Qe()),o}return xI(t,n),lr([I("")],t.prototype,"content",void 0),lr([I(void 0)],t.prototype,"template",void 0),lr([I("String")],t.prototype,"annotationType",void 0),lr([I(!0)],t.prototype,"visibility",void 0),lr([I(Lr.InheritReadOnly)],t.prototype,"constraints",void 0),lr([re(void 0,cre)],t.prototype,"hyperlink",void 0),lr([I("")],t.prototype,"id",void 0),lr([I()],t.prototype,"width",void 0),lr([I()],t.prototype,"height",void 0),lr([I(0)],t.prototype,"rotateAngle",void 0),lr([I("Parent")],t.prototype,"rotationReference",void 0),lr([re({strokeWidth:0,strokeColor:"transparent",fill:"transparent"},qp)],t.prototype,"style",void 0),lr([I("Center")],t.prototype,"horizontalAlignment",void 0),lr([I("Center")],t.prototype,"verticalAlignment",void 0),lr([re({},$n)],t.prototype,"margin",void 0),lr([re({top:void 0,bottom:void 0,left:void 0,right:void 0},$n)],t.prototype,"dragLimit",void 0),lr([I("Shape")],t.prototype,"type",void 0),lr([re({},Td)],t.prototype,"tooltip",void 0),lr([I()],t.prototype,"addInfo",void 0),t}(Ee),Zn=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return xI(t,n),t.prototype.getClassName=function(){return"ShapeAnnotation"},lr([re({x:.5,y:.5},z)],t.prototype,"offset",void 0),t}(Ax),Nr=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return xI(t,n),t.prototype.getClassName=function(){return"PathAnnotation"},lr([I(.5)],t.prototype,"offset",void 0),lr([re({x:0,y:0},z)],t.prototype,"displacement",void 0),lr([I("Center")],t.prototype,"alignment",void 0),lr([I(!1)],t.prototype,"segmentAngle",void 0),t}(Ax);function Lx(n){return fre[n.toString()]}function c3(n){return mre[""+n]}var fre={X:"M14,14 L106,106 M106,14 L14,106",Circle:"M0,50 A50,50,0 1 1 100,50 A50,50,0 1 1 0,50 Z",Square:"M0,0 L10,0 L10,10 L0,10 z"},gre={OpenArrow:"M15.9,23 L5,16 L15.9,9 L17,10.7 L8.7,16 L17,21.3Z",Square:"M0,0 L10,0 L10,10 L0,10 z",Fletch:"M14.8,10c0,0-3.5,6,0.2,12c0,0-2.5-6-10.9-6C4.1,16,11.3,16,14.8,10z",OpenFetch:"M6,17c-0.6,0-1-0.4-1-1s0.4-1,1-1c10.9,0,11-5,11-5c0-0.6,0.4-1,1-1s1,0.4,1,1C19,10.3,18.9,17,6,17C6,17,6,17,6,17z M18,23c-0.5,0-1-0.4-1-1c0-0.2-0.3-5-11-5c-0.6,0-1-0.5-1-1s0.4-1,1-1c0,0,0,0,0,0c12.9,0,13,6.7,13,7 C19,22.6,18.6,23,18,23z",IndentedArrow:"M17,10c0,0-4.5,5.5,0,12L5,16L17,10z",OutdentedArrow:"M14.6,10c0,0,5.4,6,0,12L5,16L14.6,10z",DoubleArrow:"M19,10 L19,22 L13,16Z M12,10 L12,22 L6,16Z",Arrow:"M15,10 L15,22 L5,16Z",Diamond:"M12,23l-7-7l7-7l6.9,7L12,23z",Circle:"M0,50 A50,50,0 1 1 100,50 A50,50,0 1 1 0,50 Z"},vre={Square:"M0,0 L10,0 L10,10 L0,10 z",Rhombus:"M10,5 L5,10 L0,5 L5,0 L10,5 Z ",Rectangle:"M0,0 L15,0 L15,10 L0,10 z ",OpenArrow:"M15.9,23 L5,16 L15.9,9 L17,10.7 L8.7,16 L17,21.3Z",Fletch:"M9.82,0 C9.82,0,6.61,5,10,10 C10,10,7.71,5,0,5 C0,5,6.61,5,9.82,0 Z ",OpenFetch:"M0.71,5.71 C0.29,5.71,0,5.43,0,5 C0,4.57,0.29,4.29,0.71,4.29 C8.5,4.29,8.57,0.71,8.57,0.71 C8.57,0.29,8.86,0,9.29,0 C9.719999999999999,0,10,0.29,10,0.71 C10,0.93,9.93,5.71,0.71,5.71 C0.71,5.71,0.71,5.71,0.71,5.71 Z M9.29,10 C8.93,10,8.57,9.71,8.57,9.29 C8.57,9.14,8.36,5.71,0.71,5.71 C0.29,5.71,0,5.36,0,5 C0,4.64,0.29,4.29,0.71,4.29 C0.71,4.29,0.71,4.29,0.71,4.29 C9.93,4.29,10,9.07,10,9.29 C10,9.71,9.71,10,9.29,10 Z ",IndentedArrow:"M10,0 C10,0,6.25,4.58,10,10 L0,5 L10,0 Z ",OutdentedArrow:"M8,0 C8,0,12.5,5,8,10 L0,5 L8,0 Z ",DoubleArrow:"M19,10 L19,22 L13,16Z M12,10 L12,22 L6,16Z",Arrow:"M15,10 L15,22 L5,16Z",Diamond:"M10,5 L5,10 L0,5 L5,0 L10,5 Z ",Circle:"M10,5 C10,7.76,7.76,10,5,10 C2.24,10,0,7.76,0,5 C0,2.24,2.24,0,5,0 C7.76,0,10,2.24,10,5 Z ",Ellipse:"M15,5 C15,7.76,11.64,10,7.5,10 C3.36,10,0,7.76,0,5 C0,2.24,3.36,0,7.5,0 C11.64,0,15,2.24,15,5 Z "},mre={Square:"M0,0 L10,0 L10,10 L0,10 z",Rhombus:"M10,5 L5,10 L0,5 L5,0 L10,5 Z ",Rectangle:"M0,0 L15,0 L15,10 L0,10 z",OpenArrow:"M23,15.9 L16,5 L9,15.9 L10.7,17 L16,8.7 L21,17.3Z",Fletch:"M9.82,0 C9.82,0,6.61,5,10,10 C10,10,7.71,5,0,5 C0,5,6.61,5,9.82,0 Z ",OpenFetch:"M0.71,5.71 C0.29,5.71,0,5.43,0,5 C0,4.57,0.29,4.29,0.71,4.29 C8.5,4.29,8.57,0.71,8.57,0.71 C8.57,0.29,8.86,0,9.29,0 C9.719999999999999,0,10,0.29,10,0.71 C10,0.93,9.93,5.71,0.71,5.71 C0.71,5.71,0.71,5.71,0.71,5.71 Z M9.29,10 C8.93,10,8.57,9.71,8.57,9.29 C8.57,9.14,8.36,5.71,0.71,5.71 C0.29,5.71,0,5.36,0,5 C0,4.64,0.29,4.29,0.71,4.29 C0.71,4.29,0.71,4.29,0.71,4.29 C9.93,4.29,10,9.07,10,9.29 C10,9.71,9.71,10,9.29,10 Z ",IndentedArrow:"M10,0 C10,0,6.25,4.58,10,10 L0,5 L10,0 Z ",OutdentedArrow:"M8,0 C8,0,12.5,5,8,10 L0,5 L8,0 Z ",DoubleArrow:"M10,19 L22,19 L16,13Z M10,12 L22,12 L16,6Z",Arrow:"M10,15 L22,15 L16,5Z",Diamond:"M10,5 L5,10 L0,5 L5,0 L10,5 Z ",Circle:"M10,5 C10,7.76,7.76,10,5,10 C2.24,10,0,7.76,0,5 C0,2.24,2.24,0,5,0 C7.76,0,10,2.24,10,5 Z ",Ellipse:"M15,5 C15,7.76,11.64,10,7.5,10 C3.36,10,0,7.76,0,5 C0,2.24,3.36,0,7.5,0 C11.64,0,15,2.24,15,5 Z "};function Nx(n){return yre[n.toString()]}var yre={Process:"M419.511,76.687L359.511,76.687L359.511,43.086L419.511,43.086z",Decision:"M 253.005,115.687L 200.567,146.071L 148.097,115.687L 200.534,85.304L 253.005,115.687 Z",Document:"M 60 31.9 c 0 0 -11 -7.7 -30 0 s -30 0 -30 0 V 0 h 60 V 31.9 Z",PreDefinedProcess:"M 0,0 L 50,0 L 50,50 L 0,50 Z M 8.334,0 L 8.334,50 M 41.667,0 L 41.667,50",Terminator:"M 269.711,29.33C 269.71,44.061 257.77,56 243.04,56L 158.058,56C 143.33,56 131.39,44.061 131.39,29.33L 131.39,29.33C 131.391,14.6057 143.33,2.669 158.058,2.669L 243.044,2.669C 257.772,2.669 269.711,14.6057 269.711,29.333 Z",PaperTap:"M0.0009,17.2042 L0.0009,47.165 C0.001,47.165 14.403,53.5455 25.00,47.165 C35.599,40.7852 44.403,43.5087 50.00,47.165L50.001,17.2042 M50.001,32.7987 L50.001,2.8405 C50.001,2.8405 35.599,-3.5427 25.001,2.8405C14.403,9.2237 5.599,6.494 0.0009,2.8405 L0.0009,32.7987",DirectData:"M 132.62 0 L 17.38 0 C 7.78 0 0 13.43 0 30 C 0 46.57 7.78 60 17.38 60 L 132.62 60 M 132.62 0C 123.02 0 115.24 13.43 115.24 30 C 115.24 46.57 123.02 60 132.62 60 C 142.22 60 150 46.57 150 30 C 150 13.43 142.22 0 132.62 0 z ",SequentialData:"M0.0029,24.999 C0.0029,11.1922 10.433,0.0021 23.295,0.0021 C36.159,0.00216 46.585,11.1922 46.585,24.999C46.585,38.8057 36.159,49.9979 23.295,49.9979 C10.433,49.9979 0.0029,38.8057 0.0029,24.999 z M23.294,49.999 L50.002,49.999",Sort:"M50.001,24.9971 L25.001,49.9971 L0.00097,24.9971 L25.001,-0.00286865 L50.001,24.9971 z M0.000976562,24.9971 L50.001,24.9971",MultiDocument:"M43.6826,40 C44.8746,40.6183 45.8586,41.3502 46.8366,42.1122 L46.8366,4.74487 L3.09857,4.74487 L3.09857,10.9544 M46.837,35.143 C48.027,35.765 49.025,36.604 50.003,37.369 L50.003,0.002 L6.264,0.002 L6.264,4.744 M43.682,47.113 L43.682,10.765 L0.0025,10.7652 L0.0025,47.1132 C0.0025,47.1132 12.5846,53.6101 21.8426,47.1132 C31.1006,40.6163 38.792,43.393 43.6826,47.1132 z",Collate:"M50.001,0.0028 L25.001,25.0029 L0.00097,0.0028 L50.001,0.002 z M0.0009,50.002 L25.001,25.002L50.001,50.002 L0.0009,50.0029 z",SummingJunction:"M7.3252,42.6768 L42.6772,7.3247 M42.6768,42.6768 L7.3248,7.3247 M0.0009,25.001 C0.0009,11.193 11.197,0.0009 25.001,0.0009 C38.809,0.0009 50.001,11.193 50.001,25.001 C50.001,38.809 38.809,50.001 25.001,50.001 C11.197,50.00 0.0009,38.809 0.0009,25.00 z",Or:"M 0 50 L 100 50 M 50 100 L 50 0.0 M 0 50 C 0 22.384 22.392 0 50 0 C 77.616 0 100 22.384 100 50 C 100 77.616 77.616 100 50 100 C 22.392 100 0 77.616 0 50 Z",InternalStorage:"M 0 3.81946A 2.5,3.81946 0 0,1 2.5,0L 47.5 0A 2.5,3.81946 0 0,1 50,3.81946L 50 45.836A 2.5,3.819446 0 0,1 47.5,49.652778L 2.5 49.652778A 2.5,3.819446 0 0,1 0,45.8336L 0 3.819446ZM 0 11.45834L 50 11.4583334M 12.5 0L 12.5 49.652778",Extract:"M0,35 L30,0 L60,35 Z",ManualOperation:"M46.4,28.8 L14.8,28.8 L0,0 L60,0 Z",Merge:"M60,0 L30,35 L0,0 Z",OffPageReference:"M60,33.3 L30.1,39 L0,33.3 L0,0 L60,0 Z",SequentialAccessStorage:"M 60 30 C 60 13.4 46.6 0 30 0 S 0 13.4 0 30 s 13.4 30 30 30 h 28.6 v -6.5 h -9.9C 55.5 48 60 39.5 60 30 Z",Annotation:"M49.9984,50.0029 L-0.00271199,50.0029 L-0.00271199,0.00286865 L49.9984,0.00286865",Annotation2:"M49.9977,50.0029 L25.416,50.0029 L25.416,0.00286865 L49.9977,0.00286865 M25.4166,25.0029 L-0.00227869,25.0029",Data:"M 10 0 L 40 0 L 30 40 L 0 40 Z",Card:"M275,60 L400,60 L400,110 L260,110 L260,75 Z",Delay:"M0,0 L12.029,0 C14.212999,0 16,1.7869979 16,3.9709952 C16,6.1549926 14.212999,7.9409904 12.029,7.9409904 L0,7.9409904 z",Preparation:"M 1048.17 572 C 1051.06 568.86 1055.17 567.05 1059.5 567 L 1094.51 567 C 1098.84 567.05 1102.95 568.86 1105.84 572 L 1126.43 595 C 1127.01 596.28 1127.01 597.72 1126.43 599 L 1105.84 622 C 1102.95 625.14 1098.84 626.95 1094.51 627 L 1059.5 627 C 1055.17 626.95 1051.06 625.14 1048.17 622 L 1027.58 599 C 1027 597.72 1027 596.28 1027.58 595 L 1048.17 572 Z",Display:"M47.8809,19.2914 L32.7968,-0.00594145 L11.3902,-0.00594145 C7.93166,-0.00594145 0.00124586,11.187 0.00124586,24.9968C0.00124586,38.8032 7.93166,49.9962 11.3902,49.9962 L32.7968,49.99 L47.615,31.038 C47.615,31.0388 52.798,24.9968 47.880,19.2914 z",ManualInput:"M 912 732 L 1006.85 707 C 1008.2 707 1009.5 707.53 1010.46 708.46 C 1011.41 709.4 1011.95 710.67 1011.95 712 L 1011.95 762C 1012 764.41 1010.28 766.52 1007.87 767 L 917.1 767 C 915.75 767 914.45 766.47 913.49 765.54 C 912.54 764.6 912 763.33 912 762 L 912 732 Z",LoopLimit:"M 8 9 L 27 9 L 33 15 L 33 26 C 33 27 33 27 32 27 L 4 27 C 3 27 2 27 2 26 L 2 15 L 8 9 Z",StoredData:"M 5.55 0L 50 0A 1.5,30 0 0,1 50,0A 5.555,25 0 0,0 50,50A 1.5,30 0 0,1 50,50L 5.555 50A 5.55,25 0 0,1 5.555,0Z"};function d3(n,t,e){var i;i="Straight"!==n.type&&n.sourceWrapper?n.sourceWrapper.corners.center:function Sre(n){var t;if(n.sourcePortWrapper){var e=n.sourcePortWrapper;t={x:e.offsetX,y:e.offsetY}}else t=n.sourceID&&n.sourceWrapper&&n.targetWrapper?kh(n,0,n.sourceWrapper.corners.center,n.targetWrapper.corners.center,!1):n.sourcePoint;return t}(n);var r=function bre(n,t,e,i,r){var b,M,s=n.sourceWrapper,o=n.targetWrapper,a=n.sourcePortWrapper,l=n.targetPortWrapper,d=[],f=Ga(n),y={corners:undefined,point:t,direction:undefined,margin:{left:5,right:5,bottom:5,top:5}},S={corners:undefined,point:e,direction:undefined,margin:{left:5,right:5,bottom:5,top:5}};if(void 0!==s&&void 0!==o&&(b=En(s),M=En(o),y.corners=s.corners,S.corners=o.corners),void 0!==a&&(y.direction="Left"===a.connectionDirection||"Top"===a.connectionDirection||"Bottom"===a.connectionDirection||"Right"===a.connectionDirection?a.connectionDirection:zo({x:a.offsetX,y:a.offsetY},b,s.bounds)),void 0!==l&&(S.direction="Left"===l.connectionDirection||"Right"===l.connectionDirection||"Bottom"===l.connectionDirection||"Top"===l.connectionDirection?l.connectionDirection:zo({x:l.offsetX,y:l.offsetY},M,o.bounds)),"Bezier"===n.type&&!n.isBezierEditing&&n.segments.length>0)for(var D=n.segments.length-1;D>=0;)n.segments[parseInt(D.toString(),10)].isInternalSegment&&n.segments.pop(),D--;if(void 0!==s&&void 0!==o)return(void 0===y.direction||void 0===S.direction)&&(i?function Ire(n,t,e){"LeftToRight"===e?(n.direction=n.direction?n.direction:"Right",t.direction=t.direction?t.direction:"Left"):"RightToLeft"===e?(n.direction=n.direction?n.direction:"Left",t.direction=t.direction?t.direction:"Right"):"TopToBottom"===e?(n.direction=n.direction?n.direction:"Bottom",t.direction=t.direction?t.direction:"Top"):"BottomToTop"===e&&(n.direction=n.direction?n.direction:"Top",t.direction=t.direction?t.direction:"Bottom")}(y,S,i):y.corners.top>S.corners.bottom&&Math.abs(y.corners.top-S.corners.bottom)>f?(y.direction=y.direction?y.direction:"Top",S.direction=S.direction?S.direction:"Bottom"):y.corners.bottomf?(y.direction=y.direction?y.direction:"Bottom",S.direction=S.direction?S.direction:"Top"):y.corners.rightf||y.corners.right+f=y.corners.left-f&&y.corners.left>S.corners.left?(y.direction=y.direction?y.direction:"Right",S.direction=S.direction?S.direction:"Left"):y.corners.left>S.corners.right&&Math.abs(y.corners.left-S.corners.right)>y.margin.left+y.margin.right||S.corners.right+f=S.corners.left-f&&y.corners.left0&&n.segments[0].direction&&(y.direction=n.segments[0].direction),y.point=Lc(b,y.direction),d=Lc(b,ls(y.direction)),y.point=kh(n,0,y.point,d,!1)):y.point=o.corners.center;if(void 0!==h){switch(S.point={x:h.offsetX,y:h.offsetY},S.direction){case"Bottom":case"Top":S.point.y=S.point.y;break;case"Left":case"Right":S.point.x=S.point.x}n.targetPadding&&!w&&(S.point=TI(n,y,S,!0))}else"Orthogonal"===n.type||"Bezier"===n.type?(S.point=Lc(M,S.direction),d=Lc(M,ls(S.direction)),S.point=kh(n,0,S.point,d,!0)):S.point=a.corners.center;if("Orthogonal"!==n.type){var C=void 0,D=void 0;if("Bezier"===n.type){if(n.bezierSettings.allowSegmentsReset||0===n.segments.length||!z.isEmptyPoint(n.segments[n.segments.length-1].point))return c=b3(n,y,S,void 0,s),Ox(n,y,S);Uv(n)}else Uv(n);if(void 0===n.sourcePortWrapper){y.point=y.corners.center,n.segments&&n.segments.length>0&&(C=z.isEmptyPoint((D=n.segments[0]).point)?void 0:D);var A=void 0!==C?C.point:S.point;if("Bezier"===n.type&&n.segments.length>0&&n.segments[0].vector1.angle&&n.segments[0].vector1.distance){var x=Math.max(y.corners.width,y.corners.height);A=z.transform(y.point,n.segments[0].vector1.angle,x/2)}y.point=w?n.sourceWrapper.bounds.center:kh(n,0,y.point,A,!1)}if(void 0===n.targetPortWrapper){S.point=S.corners.center,n.segments&&n.segments.length>1&&(C=z.isEmptyPoint((D=n.segments[n.segments.length-2]).point)?void 0:D);var R=C?C.point:y.point;"Bezier"===n.type&&n.segments.length>0&&n.segments[n.segments.length-1].vector2.angle&&n.segments[n.segments.length-1].vector2.distance&&(x=Math.max(y.corners.width,y.corners.height),R=z.transform(S.point,n.segments[0].vector2.angle,x/2)),S.point=w?n.targetWrapper.bounds.center:kh(n,0,R,S.point,!0)}c=Ox(n,y,S)}else"Orthogonal"===n.type&&n.segments&&n.segments.length>0&&null!==n.segments[0].direction?c=function Nre(n,t,e,i,r,s,o){var a,h,c,d;Uv(n);for(var u=0;u0&&n.segments[u-1].direction===h.direction?u=y3(n,u,t):h.direction?t.point=u3(t,n.segments[parseInt(u.toString(),10)]):(p=n.segments[u-1])&&p.points&&(t.point=p.points[p.points.length-1]),u===n.segments.length-1)if(S3(n,t),v3(a=void 0===r?Lre(n,t,e):f3(n,t,e),n),h.points=[],a.length>=2)for(c=0;c2&&n.segments.length>2){var f={x:a[parseInt(c.toString(),10)].x,y:t.point.y};h.points=[],h.points.push(f),h.points.push(a[parseInt(c.toString(),10)]);var p=n.segments[u-1];n.segments.length<4&&p.points.pop(),p.points=p.points.concat(h.points)}else h.points.push(a[parseInt(c.toString(),10)]);else h.points.push(a[parseInt(c.toString(),10)]);else d=u;if(void 0!==d&&!n.selectedSegmentIndex&&(d===n.segments.length-1&&(n.segments[d-1].direction=null,n.segments[d-1].length=null),n.segments.splice(d,1)),i&&0===u){var g=g3(n,i,s);g&&(t.point=g)}}return I3(n,[])}(n,y,S,l,h,o):(n.segments[0]||(C=new bi(n,"segments",{type:"Orthogonal"},!0),n.segments.push(C)),n.segments[0].points=c=b3(n,y,S,void 0,s));return c}(n,y.direction,S.direction,y.point,S.point,r);if(Uv(n),(n.sourceWrapper||n.targetWrapper)&&function Dre(n,t,e){var i=n.sourcePortWrapper,r=n.targetPortWrapper,s=n.sourceWrapper,o=t.point,a={left:0,right:0,top:0,bottom:0},l={x:0,y:0},c="Top";if(s?(o=e.point,a=t.margin):(s=n.targetWrapper,a=e.margin),"Orthogonal"===n.type)if(n.segments&&n.segments.length>0&&n.sourceWrapper&&n.segments[0].direction)t.direction=n.segments[0].direction,l=kh(n,0,l=Lc(s.corners,t.direction),Lc(s.corners,ls(t.direction)),!1);else{var u={corners:null,direction:null,point:null,margin:null};jv(s,{corners:null,direction:null,point:o,margin:a},u,n),l=u.point,c=u.direction}else{var p=void 0;n.segments&&n.segments.length>1&&(p=s===n.sourceWrapper?n.segments[0].point:n.segments[n.segments.length-2].point),l=kh(n,0,s.bounds.center,n.segments&&n.segments.length>1?p:o,s===n.targetWrapper)}s===n.sourceWrapper?(t.direction=t.direction||c,t.point=l,n.sourcePortWrapper&&(t.point={x:i.offsetX,y:i.offsetY},n.sourcePadding&&(t.point=TI(n,t,e,!1)))):(e.direction=e.direction||c,e.point=l,n.targetPortWrapper&&(e.point={x:r.offsetX,y:r.offsetY},n.targetPadding&&(e.point=TI(n,t,e,!0))))}(n,y,S),"Straight"===n.type||"Bezier"===n.type)d=Ox(n,y,S);else if("Orthogonal"===n.type&&n.segments&&n.segments.length>0&&null!==n.segments[0].length&&null!==n.segments[0].direction)d=function Ere(n,t,e,i,r,s,o){var a,l,c,u,h=[];if(Uv(n),n.segments.length>0){for(var p=0;p0&&n.segments[p-1].direction===f.direction)p=y3(n,p,t);else{var g=n.segments[p-1];t.point=f.direction?u3(t,f):g.points[g.points.length-1]}if(p===n.segments.length-1&&(o||r?n.targetWrapper&&void 0===n.targetPortWrapper?(S3(n,t),l=wre(n,t,e)):l=f3(n,t,e):l=Mre(n,t,e),l))if(v3(l,n),f.points=[],l.length>=2)for(a=0;at.corners.top&&e.point.ye.point.x?"Left":"Right"):e.point.x>t.corners.left&&e.point.xe.point.y?"Top":"Bottom")),n.sourcePortWrapper&&s===ls(r)?(("Left"===s||"Right"===s)&&t.point.y>=t.corners.top&&t.point.y<=t.corners.center.y&&e.point.y>=t.corners.top&&e.point.y<=t.corners.center.y?(t.direction="Top",a=t.point.y-t.corners.top+20):("Left"===s||"Right"===s)&&t.point.y>t.corners.center.y&&t.point.y<=t.corners.bottom&&e.point.y>t.corners.center.y&&e.point.y<=t.corners.bottom?(t.direction="Bottom",a=t.corners.bottom-t.point.y+20):("Top"===s||"Bottom"===s)&&t.point.x>=t.corners.left&&t.point.x<=t.corners.center.x&&e.point.x>=t.corners.left&&e.point.x<=t.corners.center.x?(t.direction="Left",a=t.point.x-t.corners.left+20):("Top"===s||"Bottom"===s)&&t.point.x<=t.corners.right&&t.point.x>t.corners.center.x&&e.point.x<=t.corners.right&&e.point.xt.point.y&&t.point.y>=e.corners.top?(i="Top",r=t.point.y-e.corners.top+20):e.corners.center.y===t.point.y&&"Top"===n.segments[n.segments.length-2].direction||e.corners.center.ye.point.y?t.point.y-t.corners.top+20:t.corners.bottom-t.point.y+20):(i="Top",r=e.corners.height/2+20):e.corners.center.x!==t.point.x||e.corners.topt.point.x&&t.point.x>=e.corners.left?(i="Left",r=t.point.x-e.corners.left+20):e.corners.center.x===t.point.x&&"Left"===n.segments[n.segments.length-2].direction||e.corners.center.x<=t.point.x&&t.point.x<=e.corners.right?(i="Right",r=e.corners.right-t.point.x+20):void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&t.corners.left<=t.point.x&&t.point.x<=t.corners.right&&(i=t.direction,r=t.point.x>e.point.x?t.point.x-t.corners.left+20:t.corners.right-t.point.x+20):(i="Left",r=e.corners.width/2+20);var a=t.point;t.point=Bn(t.point,"Left"===i||"Top"===i?-r:r,"Left"===i||"Right"===i?0:90),t.direction=z.direction(t.point,e.point),void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&(t.corners.center.x===e.corners.center.x||t.corners.center.y===e.corners.center.y)&&(t.direction=e.direction);var l=Ys(n,t,e);return l.splice(0,0,a),l}function f3(n,t,e){var i,r;e.corners=n.targetWrapper.corners,void 0!==n.sourcePortWrapper&&(r=zo({x:n.sourcePortWrapper.offsetX,y:n.sourcePortWrapper.offsetY},En(n.sourceWrapper),n.sourceWrapper.bounds));var a=function Cre(n,t,e,i){var r=!1;switch(e.direction){case"Left":void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&"Right"===i&&t.point.x>e.point.x&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom||("Bottom"===i&&t.point.y>e.point.y||"Top"===i&&t.point.y=t.corners.left&&t.point.x<=t.corners.right?(t.direction="Right"===i?t.point.y>e.point.y?"Top":"Bottom":t.point.xe.point.x&&(t.point.y>e.point.y||t.point.yt.point.y&&e.corners.bottome.point.y||t.point.x>e.point.x&&t.point.y<=e.point.y&&e.corners.top=t.point.y?t.direction="Top":t.point.xe.point.x&&t.point.y>e.point.y&&e.corners.bottomt.point.y?t.direction="Bottom":t.point.y===e.point.y&&t.point.xe.point.y||"Top"===i&&t.point.ye.point.x&&t.point.x>=t.corners.left&&t.point.x<=t.corners.right?(t.direction=t.point.x>e.point.x?"Left":"Right",r=!0):void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&"Left"===i&&t.point.x=t.corners.top&&t.point.y<=t.corners.bottom?(t.direction=t.point.y>e.point.y?"Top":"Bottom",r=!0):t.point.x=t.point.y&&t.point.y===e.point.y||t.point.y>e.point.y&&t.point.x>e.point.x?t.direction="Top":t.point.ye.point.x?t.direction="Bottom":t.point.xe.point.y||t.point.ye.point.x&&(t.direction="Left");break;case"Top":void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&"Bottom"===i&&t.point.y>e.point.y&&t.point.x>=t.corners.left&&t.point.x<=t.corners.right||("Right"===i&&t.point.x>e.point.x||"Left"===i&&e.point.y>t.point.y&&e.point.x>t.point.x)&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom?(t.direction="Bottom"===i?t.point.x>e.point.x?"Left":"Right":t.point.ye.point.y&&t.point.x>e.corners.left&&t.point.x=e.point.y?t.direction="Top":t.point.ye.point.x?t.direction="Left":t.point.yt.point.x)&&t.point.y>e.point.y&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom||"Top"===i&&t.point.y=t.corners.left&&t.point.x<=t.corners.right)?(t.direction="Right"===i||"Left"===i?t.point.y>e.point.y?"Top":"Bottom":t.point.x>e.point.x?"Left":"Right",r=!0):t.point.ye.corners.left&&e.corners.right>t.point.x?t.point.ye.corners.left&&e.corners.center.x>=t.point.x?t.direction="Left":t.point.ye.point.y&&t.point.x>e.point.x?t.direction="Left":t.point.y>e.point.y&&t.point.xe.point.x||e.point.x>t.point.x)&&(t.direction="Bottom")}return r}(n,t,e,r);return!n.selectedSegmentIndex&&void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&e.direction===ls(r)&&(("Left"===e.direction&&t.point.x>e.point.x||"Right"===e.direction&&t.point.x=t.corners.top&&t.point.y<=t.corners.bottom||"Bottom"===e.direction&&t.point.y=t.corners.left&&t.point.x<=t.corners.right)?i=p3(n,t,e):n.selectedSegmentIndex||t.direction!==e.direction?!n.selectedSegmentIndex&&("Left"===e.direction&&t.point.x>e.point.x||"Right"===e.direction&&t.point.x=t.point.y||"Top"===e.direction&&t.point.y>e.point.y||"Bottom"===e.direction&&t.point.y=t.point.x?i=n.selectedSegmentIndex?Nl(t,e):p3(n,t,e):!n.selectedSegmentIndex&&void 0!==n.sourceWrapper&&void 0!==n.targetWrapper&&void 0!==n.targetPortWrapper&&("Left"===t.direction||"Right"===t.direction)&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom&&("Top"===e.direction||"Bottom"===e.direction)&&e.corners.center.x===t.corners.center.x?(t.direction="Top"===e.direction?"Bottom":"Top",i=Ys(n,t,e,"Top"===e.direction?t.corners.bottom-t.point.y+20:t.point.y-t.corners.top+20)):!n.selectedSegmentIndex&&void 0!==n.sourceWrapper&&void 0!==n.targetWrapper&&void 0!==n.targetPortWrapper&&("Top"===t.direction||"Bottom"===t.direction)&&t.point.x>=t.corners.left&&t.point.x<=t.corners.right&&("Left"===e.direction||"Right"===e.direction)&&e.corners.center.y===t.corners.center.y?(t.direction="Left"===e.direction?"Right":"Left",i=Ys(n,t,e,"Left"===e.direction?t.corners.right-t.point.x+20:t.point.x-t.corners.left+20)):i=a?Ys(n,t,e,"Left"===t.direction||"Right"===t.direction?"Left"===t.direction?t.point.x-t.corners.left+20:t.corners.right-t.point.x+20:"Top"===t.direction?t.point.y-t.corners.top+20:t.corners.bottom-t.point.y+20):Nl(t,e):i=Ys(n,t,e),i}function g3(n,t,e){var r,i={x:t.offsetX,y:t.offsetY},s=En(e),o=zo(i,s,e.bounds),a=n.segments[0];return a.direction!==o&&(function Ore(n,t,e,i,r,s){var a,h,o=13,l=[];l.push(i),i.y===r.y&&("Left"===t&&r.xi.x)||i.x===r.x&&("Top"===t&&r.yi.y)||("Top"===t||"Bottom"===t?"Top"===t&&r.yi.y-o||"Bottom"===t&&r.y>i.y&&r.yo&&("Top"===t&&r.yi.y)?l.push({x:i.x,y:r.y}):(a=r.xi.x-o||"right"===t&&r.x>i.x&&r.xo&&("Left"===t&&r.xi.x)?l.push({x:r.x,y:i.y}):(l.push({x:a="Left"===t?e.left-o:e.right+o,y:i.y}),l.push({x:a,y:r.y})),s&&(l.push(n.points[0]),l.reverse()),n.points=l)}(a,o,s,a.points[0],a.points[a.points.length-1],!1),r=a.points[a.points.length-1],a.direction=z.direction(a.points[a.points.length-2],a.points[a.points.length-1])),r}function v3(n,t,e){var s,i=t.segments[t.segments.length-2],r=i.points[i.points.length-1];(("Top"===i.direction||"Bottom"===i.direction)&&r.x===n[1].x||("Left"===i.direction||"Right"===i.direction)&&r.y===n[1].y)&&(i.points[i.points.length-1]=n[1],s=z.direction(i.points[0],i.points[i.points.length-1]),void 0!==t.sourceWrapper&&void 0===t.sourcePortWrapper&&s===ls(i.direction)&&("Left"===i.direction||"Right"===i.direction?i.points[0].x="Right"===i.direction?i.points[0].x-t.sourceWrapper.corners.width:i.points[0].x+t.sourceWrapper.corners.width:i.points[0].y="Bottom"===i.direction?i.points[0].y-t.sourceWrapper.corners.height:i.points[0].y+t.sourceWrapper.corners.height),i.direction=s,i.length=z.distancePoints(i.points[0],i.points[i.points.length-1]),n.splice(0,1))}function TI(n,t,e,i){var o=i?n.targetPadding:n.sourcePadding,a=i?n.targetPortWrapper:n.sourcePortWrapper,l=new Ne(a.bounds.x-o,a.bounds.y-o,a.actualSize.width+2*o,a.actualSize.height+2*o),h=[l.topLeft,l.topRight,l.bottomRight,l.bottomLeft];h[h.length]=h[0];var d=i?e.point:t.point;return Px({x1:t.point.x,y1:t.point.y,x2:e.point.x,y2:e.point.y},h,0,d)||d}function m3(n,t){var e=[],i=mF(0,n.corners,t);i.push(i[0]);for(var r=0;r0){var r=void 0,s=[],o=t.point;for(r=0;r1&&z.equals(a.points[0],a.points[1])&&n.segments.splice(r,1),a)for(var l=0;l0||0===r)&&i.push(a.points[parseInt(l.toString(),10)])}}return i}function kx(n,t,e){return"Top"===n||"Bottom"===n?e.x>t.x?"Right":"Left":e.y>t.y?"Bottom":"Top"}function Uv(n){if("Straight"===n.type||"Bezier"===n.type){if(0===n.segments.length||n.segments.length>0&&!z.isEmptyPoint(n.segments[n.segments.length-1].point))if("Bezier"===n.type){var t=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0},!0);n.segments.push(t)}else t=new Pl(n,"segments",{type:"Straight"},!0),n.segments.push(t)}else{if(n.segments.length>0)for(var e=!1,i=0;i=t.corners.left&&e.point.x<=t.corners.right&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom)t.direction=e.point.y>t.point.y?"Bottom":"Top",i=Ys(n,t,e,"Top"===t.direction?t.point.y-t.corners.top+20:t.corners.bottom-t.point.y+20);else if(n.sourcePortWrapper&&r===ls(o)){var h;("Left"===r||"Right"===r)&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom?(t.direction=e.point.y>t.point.y?"Bottom":"Top",h=t.corners.height/2+20):("Top"===r||"Bottom"===r)&&t.point.x>=t.corners.left&&t.point.x<=t.corners.right&&(t.direction=e.point.x>t.point.x?"Right":"Left",h=t.corners.width/2+20),t.direction&&h?i=Ys(n,t,e,h,!0):(t.direction=o,i=Nl(t,e))}else if(!n.sourcePortWrapper||r!==e.direction||"Top"!==r&&"Bottom"!==r||t.corners.center.x!==e.corners.center.x)if(t.direction===e.direction)if(("Left"===t.direction||"Right"===t.direction)&&e.point.y>t.corners.top-20&&e.point.yt.corners.left-20&&e.point.xt.point.y?"Bottom":"Top",i=Ys(n,t,e,"Bottom"===t.direction?t.corners.bottom-t.point.y+20:t.point.y-t.corners.top+20);else t.direction=o,i=Ys(n,t,e,"Top"===o||"Bottom"===o?n.sourceWrapper.height/2+20:n.sourceWrapper.width/2+20),t.point=i[1],"Left"===o||"Right"===o?(e.direction=o,e.point="Left"===o?e.corners.middleLeft:e.corners.middleRight):jv(n.targetWrapper,t,e,n),i=Ys(n,t,e);return i}function S3(n,t){if(void 0!==n.targetWrapper&&void 0===n.targetPortWrapper&&En(n.targetWrapper).containsPoint(t.point,1)){var i=n.targetWrapper,r=n.segments[n.segments.length-2],s=r.points[r.points.length-1],o=ls(r.direction);"Bottom"===o?s.yi.corners.top-1&&(r.points[r.points.length-1].y=i.corners.top-20,r.length=z.distancePoints(r.points[0],r.points[r.points.length-1])):"Left"===o?s.x>i.corners.left-1&&(r.points[r.points.length-1].x=i.corners.left-20,r.length=z.distancePoints(r.points[0],r.points[r.points.length-1])):"Right"===o&&s.x0||0===e)&&t.push(i.points[parseInt(r.toString(),10)]);return t}function jv(n,t,e,i){var r,s={x:0,y:0},o=AI(n,n.corners,n.bounds),a=t.margin,l=t.point;if(o.bottomCenter.y+a.bottoml.y)r="Top",s=o.topCenter;else if(o.middleLeft.x-a.left>l.x)r="Left",s=o.middleLeft;else if(o.middleRight.x+a.rightc&&(p=c,r="Right",s=o.middleRight),p>d&&(p=d,r="Bottom",s=o.bottomCenter),p>u&&(r="Left",s=o.middleLeft)}e.point=s,e.direction=r;var f=Lc(o,ls(e.direction));e.point=kh(i,0,e.point,f,n===i.targetWrapper)}function b3(n,t,e,i,r){var s,o,a;if(s=function Qre(n,t){var e=!1;switch(n){case"Left":switch(t){case"Right":case"Bottom":e=!0}break;case"Top":switch(t){case"Left":case"Right":case"Bottom":e=!0}break;case"Bottom":"Right"===t&&(e=!0)}return e}(t.direction,e.direction),s&&x3(t,e),"Right"===t.direction&&"Left"===e.direction)a=function kre(n,t,e,i){var o=Math.round(Math.abs(t.point.y-e.point.y)),a={x:Math.max(t.point.x,t.corners.right),y:t.point.y},l={x:Math.min(e.point.x,e.corners.left),y:e.point.y},h=Ga(n);if(i){var c=l;l=a,a=c}return t.corners.bottom+he.corners.bottom+h||("Bezier"!==n.type||e.corners.left-t.corners.right<=2*h&&e.corners.left-t.corners.right>=5)&&(h=0),t.margin={left:h,right:h,top:h,bottom:h},e.margin={left:h,right:h,top:h,bottom:h},0===o&&(t.corners.right=e.corners.right?void 0!==i&&(i.offsetYe.corners.bottom+e.margin.bottom)||void 0===i&&t.corners.middleRight.ye.corners.bottom+e.margin.bottom&&t.corners.top>e.corners.bottom||void 0===i&&t.corners.middleRight.y>e.corners.bottom||void 0!==i&&i.offsetYe.corners.top||void 0===i&&t.corners.middleRight.y>e.corners.bottom?Ae.Three:t.corners.rightr.offsetY+e.margin.right||void 0===r&&t.corners.top>e.corners.middleRight.y||void 0!==r&&(void 0!==i&&i.offsetXr.offsetX||void 0===r&&t.corners.left>e.corners.topCenter.x?Ae.Four:Ae.Two:void 0!==s&&Math.abs(t.corners.right-e.corners.left)<=5&&Math.abs(s.offsetY-e.corners.top)<=5||void 0!==r&&t.corners.right=25&&t.corners.middleRight.y+t.margin.righte.corners.bottom+e.margin.bottom||void 0===o&&t.corners.middleRight.y>e.corners.bottom+e.margin.bottom?t.corners.top>e.corners.bottom?void 0!==a&&t.corners.right+t.margin.righta.offsetX||void 0===a&&t.corners.left>e.corners.bottomCenter.x?Ae.Four:Ae.Two:void 0!==o&&Math.abs(t.corners.right-e.corners.left)<=25&&Math.abs(o.offsetY-e.corners.bottom)<=25?Ae.Two:Ae.Four}(n,t,e,s);else if("Bottom"===t.direction&&"Top"===e.direction)a=function Hre(n,t,e){var r=t.point.x-e.point.x,s=Ga(n);return t.corners.right+se.corners.right+s||("Bezier"!==n.type||e.corners.top-t.corners.bottom<=2*s&&e.corners.top-t.corners.bottom>=5)&&(s=0),t.margin={left:s,right:s,top:s,bottom:s},e.margin={left:s,right:s,top:s,bottom:s},0===r&&t.corners.bottome.corners.right+e.margin.right||void 0===i&&t.corners.bottomCenter.x>e.corners.right+e.margin.right?Ae.Three:t.corners.bottomr.offsetX||void 0===r&&t.corners.left>e.corners.left||void 0!==r&&t.corners.right+t.margin.righte.corners.bottom?Ae.Five:0===s||0===o?Ae.One:Ae.Three}(n,t,e)}else"Bottom"===t.direction&&"Left"===e.direction?a=function Bre(n,t,e,i){var r=n.sourcePortWrapper,s=n.targetPortWrapper,o=Ga(n);if(e.margin={left:o,right:o,top:o,bottom:o},t.margin={top:o,bottom:o,left:o,right:o},i){var l=r;r=s,s=l}return void 0!==r&&r.offsetXs.offsetY||void 0===s&&t.corners.top>e.corners.middleLeft.y?Ae.Four:Ae.Two:void 0!==s&&Math.abs(t.corners.right-e.corners.left)<=25&&Math.abs(s.offsetY-t.corners.bottom)<=25?Ae.Two:Ae.Four}(n,t,e,s):"Left"===t.direction&&"Left"===e.direction?a=function Ure(n,t,e){var i=n.sourcePortWrapper,r=n.targetPortWrapper,s=Ga(n);t.margin={left:s,right:s,top:s,bottom:s},e.margin={left:s,right:s,top:s,bottom:s};var o=Math.round(Math.abs(t.point.x-e.point.x)),a=Math.round(Math.abs(t.point.y-e.point.y));return t.corners.leftr.offsetY||void 0===r&&t.corners.top-t.margin.top>e.corners.middleLeft.y?Ae.Three:t.corners.righte.corners.bottom+e.margin.bottom||void 0===i&&t.corners.middleLeft.y>e.corners.bottom+e.margin.bottom?Ae.Three:t.corners.left>e.corners.right?Ae.Five:0===o||0===a?Ae.One:Ae.Three}(n,t,e):"Left"===t.direction&&"Top"===e.direction?a=function _re(n,t,e,i){var s=n.sourcePortWrapper,o=Ga(n);e.margin={left:o,right:o,top:o,bottom:o},t.margin={top:o,bottom:o,left:o,right:o};var a=n.targetPortWrapper,l={x:Math.min(t.point.x,t.corners.left),y:t.point.y},h={x:e.point.x,y:Math.min(e.point.y,e.corners.top)};if(i){var c=s;s=a,a=c;var d=l;l=h,h=d}return void 0!==s&&s.offsetYa.offsetX||void 0===a&&t.corners.left-t.margin.left>e.corners.topCenter.x?Ae.Two:Ae.Four:void 0!==a&&t.corners.rightr.offsetX||void 0===r&&t.corners.left>e.corners.left||void 0!==r&&t.corners.right+t.margin.righte.corners.right+e.margin.right||void 0===i&&t.corners.left>e.corners.right||void 0!==i&&i.offsetXe.corners.bottom?Ae.Five:0===s||0===o?Ae.One:Ae.Three}(n,t,e));return s&&x3(t,e),o=function Vre(n,t,e,i,r,s){var l,d,h=n.sourceWrapper.corners,c=n.targetWrapper.corners,u=20,p={corners:e.corners,point:e.point,direction:e.direction,margin:e.margin},f={corners:i.corners,point:i.point,direction:i.direction,margin:i.margin};if(!(p.direction===f.direction&&t!==Ae.Five||p.direction!==ls(f.direction)&&t!==Ae.Three))switch(p.direction){case"Left":h.middleLeft.x>c.middleRight.x&&(d=(h.middleLeft.x-c.middleRight.x)/2,u=s?d:Math.min(u,d));break;case"Right":h.middleRight.xc.bottomCenter.y&&(d=(h.topCenter.y-c.bottomCenter.y)/2,u=s?d:Math.min(u,d));break;case"Bottom":h.bottomCenter.yp&&hp)&&o>c&&o<=d&&e>=20&&(s=n.point.x-t.corners.left+s),i&&n.direction===t.direction&&n.corners.left>t.corners.left&&n.corners.left-t.corners.right>=20&&(s=(n.corners.left-t.corners.right)/2),f=Bn(n.point,s,180);break;case"Top":(o>c&&oc)&&h>p&&h<=u&&e>=20&&(s=n.point.y-t.corners.top+s),i&&n.direction===t.direction&&n.corners.top>t.corners.top&&n.corners.top-t.corners.bottom>=20&&(s=(n.corners.top-t.corners.bottom)/2),f=Bn(n.point,s,270);break;case"Right":(h>p&&hp)&&a=c&&e>=20&&(s=t.corners.right-n.point.x+s),i&&n.direction===t.direction&&n.corners.right=20&&(s=(t.corners.left-n.corners.right)/2),f=Bn(n.point,s,0);break;case"Bottom":(o>c&&oc)&&l=p&&e>=20&&(s=t.corners.bottom-n.point.y+s),i&&n.direction===t.direction&&n.corners.bottom=20&&(s=(t.corners.top-n.corners.bottom)/2),f=Bn(n.point,s,90)}r=[n.point,f];var g=void 0;if("Top"===n.direction||"Bottom"===n.direction){var v=n.direction;n.direction=f.x>t.point.x?"Left":"Right",n.point=f,r=LI(n,t,v,r,g=i?.5*Math.abs(f.x-t.point.x):g,i)}else v=n.direction,n.direction=f.y>t.point.y?"Top":"Bottom",n.point=f,r=LI(n,t,v,r,g=i?.5*Math.abs(f.y-t.point.y):g,i);return r}(p,f,u,g)),l}(n,a,t,e,i,r),"Bezier"===n.type&&function Yre(n,t,e){if("Bezier"===n.type)if(0===n.segments.length){var i=e[0],r=e[e.length-1];if(t===Ae.One){var s=Math.min(20,.5*z.findLength(i,r)),o={angle:Gt(i,r),distance:s},a={angle:Gt(r,i),distance:s},l=z.direction(i,r),c=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,orientation:"Left"===l||"Right"===l?"Horizontal":"Vertical"},!0);n.segments.push(c)}else if(t===Ae.Two)o={angle:Gt(i,d=e[1]),distance:.5*z.findLength(i,d)},a={angle:Gt(r,d),distance:.5*z.findLength(r,d)},l=z.direction(i,d),c=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,orientation:"Left"===l||"Right"===l?"Horizontal":"Vertical"},!0),n.segments.push(c);else if(t===Ae.Three){var d={x:.5*((u=e[1]).x+(p=e[e.length-2]).x),y:.5*(u.y+p.y)},f=(o={angle:Gt(i,u),distance:.5*z.findLength(i,u)},a={angle:Gt(d,u),distance:.5*z.findLength(d,u)},z.direction(i,u)),v=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,point:d,orientation:"Left"===f||"Right"===f?"Horizontal":"Vertical"},!0);n.segments.push(v);var y={angle:Gt(d,p),distance:.5*z.findLength(d,p)},S={angle:Gt(r,p),distance:.5*z.findLength(r,p)},b=z.direction(d,p),w=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:y,vector2:S,orientation:"Left"===b||"Right"===b?"Horizontal":"Vertical"},!0);n.segments.push(w)}else if(t===Ae.Four){var D={x:.5*((u=e[1]).x+(p=e[2]).x),y:.5*(u.y+p.y)},A={x:.5*(p.x+(C=e[3]).x),y:.5*(p.y+C.y)};o={angle:Gt(i,u),distance:.5*z.findLength(i,u)},a={angle:Gt(D,u),distance:.5*z.findLength(D,u)},f=z.direction(i,u),v=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,point:D,orientation:"Left"===f||"Right"===f?"Horizontal":"Vertical"},!0),n.segments.push(v),y={angle:Gt(D,p),distance:.5*z.findLength(D,p)},S={angle:Gt(A,p),distance:.5*z.findLength(A,p)},b=z.direction(D,p),w=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:y,vector2:S,point:A,orientation:"Left"===b||"Right"===b?"Horizontal":"Vertical"},!0),n.segments.push(w);var x={angle:Gt(A,C),distance:.5*z.findLength(A,C)},R={angle:Gt(r,C),distance:.5*z.findLength(r,C)},L=z.direction(A,C),N=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:x,vector2:R,orientation:"Left"===L||"Right"===L?"Horizontal":"Vertical"},!0);n.segments.push(N)}else if(t===Ae.Five){var u,p,C,T=e[4],P=(D={x:.5*((u=e[1]).x+(p=e[2]).x),y:.5*(u.y+p.y)},A={x:.5*(p.x+(C=e[3]).x),y:.5*(p.y+C.y)},{x:.5*(C.x+T.x),y:.5*(C.y+T.y)});o={angle:Gt(i,u),distance:.5*z.findLength(i,u)},a={angle:Gt(D,u),distance:.5*z.findLength(D,u)},f=z.direction(i,u),v=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,point:D,orientation:"Left"===f||"Right"===f?"Horizontal":"Vertical"},!0),n.segments.push(v),y={angle:Gt(D,p),distance:.5*z.findLength(D,p)},S={angle:Gt(A,p),distance:.5*z.findLength(A,p)},b=z.direction(D,p),w=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:y,vector2:S,point:A,orientation:"Left"===b||"Right"===b?"Horizontal":"Vertical"},!0),n.segments.push(w),x={angle:Gt(A,C),distance:.5*z.findLength(A,C)},R={angle:Gt(P,C),distance:.5*z.findLength(P,C)},L=z.direction(A,C),N=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:x,vector2:R,point:P,orientation:"Left"===L||"Right"===L?"Horizontal":"Vertical"},!0),n.segments.push(N);var _={angle:Gt(P,T),distance:.5*z.findLength(P,T)},B={angle:Gt(r,T),distance:.5*z.findLength(r,T)},j=z.direction(P,T),oe=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:_,vector2:B,orientation:"Left"===j||"Right"===j?"Horizontal":"Vertical"},!0);n.segments.push(oe)}else c=new ps(n,"segments",{type:"Bezier"},!0),n.segments.push(c)}else for(var ue=0;ue=13?13:n.connectorSpacing<=1?1:n.connectorSpacing}function Gt(n,t){var i=z.findLength({x:t.x,y:n.y},t),r=z.findLength(t,n),s=Math.asin(i/r);return s=180*s/Math.PI,n.xt.y&&(s=360-s):s=n.y0)for(var l=1;lc)&&(s=c,a=h),s>=0&&s<=1)break}}return a}function w3(n,t){var c,d,u,p,f,g,S,b,M,w,D,e=n.x1,i=n.y1,r=n.x2,s=n.y2,o=t.x1,a=t.y1,l=t.x2,h=t.y2;if(w=(c=s-i)*l+(u=e-r)*h+(f=r*i-e*s),0!==(M=c*o+u*a+f)&&0!==w&&C3(M,w)||(b=(d=h-a)*r+(p=o-l)*s+(g=l*a-o*h),0!==(S=d*e+p*i+g)&&0!==b&&C3(S,b)))return null;var A=c*p-d*u;return 0===A?null:(A<0?-A/2:A/2,0,{x:(D=u*g-p*f)<0?(D-0)/A:(D+0)/A,y:(D=d*f-c*g)<0?(D-0)/A:(D+0)/A})}function C3(n,t){return n*t>=0}function E3(n,t,e){switch(t.direction){case"Left":t.point.x>n.left&&(e=t.point.x-n.left>e?t.point.x-n.left+e:e);break;case"Right":t.point.xe?n.right-t.point.x+e:e);break;case"Top":t.point.y>n.top&&(e=t.point.y-n.top>e?t.point.y-n.top+e:e);break;case"Bottom":t.point.ye?n.bottom-t.point.y+e:e)}return e}function Nl(n,t){var e;switch(n.direction){case"Left":case"Right":var i={x:t.point.x,y:n.point.y};e=z.equals(n.point,i)||z.equals(t.point,i)?[n.point,t.point]:[n.point,i,t.point];break;case"Top":case"Bottom":var r={x:n.point.x,y:t.point.y};e=z.equals(n.point,r)||z.equals(t.point,r)?[n.point,t.point]:[n.point,r,t.point]}return e}function Ys(n,t,e,i,r,s){void 0===s&&(s=!1),i||(i=20),s&&t.direction!==e.direction&&(i="Left"===t.direction||"Right"===t.direction?Math.floor(.5*Math.abs(t.point.x-e.point.x)):Math.floor(.5*Math.abs(t.point.y-e.point.y)));var l,h,u,o=n.sourcePortWrapper,c=e.point.x-t.point.x,d=e.point.y-t.point.y;if(!r&&(Math.abs(c)<.001||Math.abs(d)<.001)&&void 0===e.direction)return[t.point,e.point];if(void 0===n.targetWrapper&&Math.abs(c)<=31&&Math.abs(d)<=31){if("Left"===t.direction||"Right"===t.direction?Math.abs(d)<12&&(t.direction=t.point.y>e.point.y?"Top":"Bottom"):Math.abs(c)<12&&(t.direction=t.point.x>e.point.x?"Left":"Right"),Math.abs(c)>12||Math.abs(d)>12)return Nl(t,e);i+=5}return"Left"===t.direction||"Right"===t.direction?("Right"===t.direction?(void 0!==e.direction&&"Right"===e.direction&&(i=Math.max(t.point.x,e.point.x)-t.point.x+i),t.point.x>e.point.x&&void 0===o&&(i=-i)):(void 0!==e.direction&&"Left"===e.direction&&(i=t.point.x-Math.min(t.point.x,e.point.x)+i),(t.point.x>e.point.x||void 0!==o||"Left"===t.direction)&&(i=-i)),u=e.point.y-t.point.y,l=Bn(t.point,i,0),0!=(u=e.point.y-l.y)&&(h=Bn(l,e.point.y-l.y,90))):("Top"===t.direction||"Bottom"===t.direction)&&("Bottom"===t.direction?void 0!==e.direction&&"Bottom"===e.direction&&(i=Math.max(t.point.y,e.point.y)-t.point.y+i):(void 0!==e.direction&&"Top"===e.direction&&(i=t.point.y-Math.min(t.point.y,e.point.y)+i),(t.point.y>e.point.y||void 0!==o||"Top"===t.direction)&&(i=-i)),u=e.point.x-t.point.x,l=Bn(t.point,i,90),0!=(u=e.point.x-l.x)&&(h=Bn(l,e.point.x-l.x,0))),0===u?[t.point,e.point]:[t.point,l,h,e.point]}function LI(n,t,e,i,r,s){var o;switch(void 0===r&&(r=20),void 0===s&&(s=!1),void 0===e?(n.margin={left:2,right:2,top:2,bottom:2},t.margin={left:0,right:5,top:0,bottom:5},s&&(n.margin={left:10,right:10,top:10,bottom:10},t.margin={left:10,right:10,top:10,bottom:10},"Left"===n.direction?(r=Rx(n,t,e,r),n.corners.left-t.corners.right>=5&&(r=Math.abs(n.point.x-n.corners.left)+.5*Math.floor(n.corners.left-t.corners.right))):"Right"===n.direction?(r=Hx(n,t,r,e),t.corners.left-n.corners.right>=5&&(r=Math.abs(n.point.x-n.corners.right)+.5*Math.floor(t.corners.left-n.corners.right))):"Top"===n.direction?(r=zx(n,t,e,r),n.corners.top-t.corners.bottom>=5&&(r=Math.abs(n.point.y-n.corners.top)+.5*Math.floor(n.corners.top-t.corners.bottom))):"Bottom"===n.direction&&(r=Bx(n,t,r,e),t.corners.top-n.corners.bottom>=5&&(r=Math.abs(n.point.y-n.corners.bottom)+.5*Math.floor(t.corners.top-n.corners.bottom))))):("Bottom"===n.direction?s?t.corners.top-n.corners.bottom<20&&(r=t.corners.bottom-n.point.y+25):t.corners.top>n.corners.bottom&&t.corners.top-n.corners.bottom<20&&(r=(t.corners.top-n.corners.bottom)/2):"Top"===n.direction?s?n.corners.top-t.corners.bottom<20&&(r=n.point.y-t.corners.top+25):t.corners.bottomn.corners.right&&t.corners.left-n.corners.right<20&&(r=(t.corners.left-n.corners.right)/2):"Left"===n.direction&&(s?n.corners.left-t.corners.right<20&&(r=n.point.x-t.corners.left+25):t.corners.rightt.point.y||"Top"===t.direction&&n.point.yt.point.x||"Left"===t.direction&&n.point.xh||e.corners.top-e.margin.top<=i.point.y&&e.corners.bottom+e.margin.bottom>=i.point.y))if(!s||"Top"!==e.direction&&"Bottom"!==e.direction)c=Math.min(Math.abs(i.corners.left-e.corners.right)/2,20),h=e.corners.right-n.x+c;else{var c=Math.abs(i.corners.left-e.corners.right)/2;h=e.corners.right-n.x+c}else h="Top"===e.direction&&n.y>i.point.y||"Bottom"===e.direction&&n.y=e.corners.left-e.margin.left&&n.x<=e.corners.right+e.margin.right?Math.min(i.corners.left,e.corners.left)-n.x-20:i.corners.left-n.x-20;break;case"Right":if(e.corners.left-e.margin.left>i.corners.right+i.margin.right&&(e.corners.left-e.margin.right-i.corners.right>h||e.corners.top-e.margin.top<=i.point.y&&e.corners.bottom+e.margin.bottom>=i.point.y))if(!s||"Top"!==e.direction&&"Bottom"!==e.direction)c=Math.min(Math.abs(e.corners.left-i.corners.right)/2,20),h=e.corners.left-n.x-c;else{c=Math.abs(e.corners.left-i.corners.right)/2;h=e.corners.left-n.x-c}else h="Top"===e.direction&&n.y>i.point.y||"Bottom"===e.direction&&n.y=e.corners.left-e.margin.left&&n.x<=e.corners.right+e.margin.right?Math.max(i.corners.right,e.corners.right)-n.x+20:i.corners.right-n.x+20}o=Bn(n,h,0),a=Bn(o,i.point.y-n.y,90),l=i.point}else if("vertical"===t){switch(i.direction){case"Top":e.corners.bottom+e.margin.bottomh||e.corners.left-e.margin.left<=i.point.x&&e.corners.right+e.margin.right>=i.point.x)?!s||"Right"!==e.direction&&"Left"!==e.direction?(c=Math.min(Math.abs(i.corners.top-e.corners.bottom)/2,20),h=e.corners.bottom-n.y+c):(c=Math.abs(i.corners.top-e.corners.bottom)/2,h=e.corners.bottom-n.y+c):h="Left"===e.direction&&n.x>i.point.x||"Right"===e.direction&&n.x=e.corners.top-e.margin.top&&n.y<=e.corners.bottom+e.margin.bottom?Math.min(i.corners.top,e.corners.top)-n.y-20:i.corners.top-n.y-20;break;case"Bottom":e.corners.top-e.margin.top>i.corners.bottom+i.margin.bottom&&(e.corners.top-e.margin.top-i.corners.bottom>h||e.corners.left-e.margin.left<=i.point.x&&e.corners.right+e.margin.right>=i.point.x)?!s||"Right"!==e.direction&&"Left"!==e.direction?(c=Math.min(Math.abs(e.corners.top-i.corners.bottom)/2,20),h=e.corners.top-n.y-c):(c=Math.abs(e.corners.top-i.corners.bottom)/2,h=e.corners.top-n.y-c):h="Left"===e.direction&&n.x>i.point.x||"Right"===e.direction&&n.x=e.corners.top-e.margin.top&&n.y<=e.corners.bottom+e.margin.bottom?Math.max(i.corners.bottom,e.corners.bottom)-n.y+20:i.corners.bottom-n.y+20}o=Bn(n,h,90),a=Bn(o,i.point.x-n.x,0),l=i.point}r.push(o),r.push(a),r.push(l)}function zx(n,t,e,i){return n.corners.top-n.margin.top>t.corners.top+t.margin.top&&n.corners.top-n.margin.top<=t.corners.bottom+t.margin.bottom?(("Right"===t.direction&&n.point.xt.point.x)&&(i+=n.corners.top-t.corners.top),i+=n.point.y-n.corners.top):i+=void 0!==e&&"Left"!==e&&"Right"===t.direction&&n.point.xt.corners.left-t.margin.left&&n.corners.left-n.margin.left<=t.corners.right+t.margin.right?(("Bottom"===t.direction&&n.point.yt.point.y)&&(i+=n.corners.left-t.corners.left),i+=n.point.x-n.corners.left):i+=void 0!==e&&"Top"!==e&&"Bottom"===t.direction&&n.point.y=t.corners.left-t.margin.left?(("Bottom"===t.direction&&n.point.yt.point.y)&&(e+=t.corners.right-n.corners.right),e+=n.corners.right-n.point.x):e+=void 0!==i&&"Top"!==i&&"Bottom"===t.direction&&n.point.y=t.corners.top-t.margin.top?(("Right"===t.direction&&n.point.xt.point.x)&&(e+=t.corners.bottom-n.corners.bottom),e+=n.corners.bottom-n.point.y):e+=void 0!==i&&"Left"!==i&&"Right"===t.direction&&n.point.xf&&d=u&&d=p&&d<=f?"Left":"Right"}function ls(n){switch(n){case"Top":return"Bottom";case"Bottom":return"Top";case"Left":return"Right";case"Right":return"Left"}return"auto"}var A3=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Nc=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},NI=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return A3(t,n),Nc([I()],t.prototype,"width",void 0),Nc([I()],t.prototype,"height",void 0),t}(Ee),Gre=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return A3(t,n),Nc([I()],t.prototype,"width",void 0),Nc([I()],t.prototype,"height",void 0),Nc([I()],t.prototype,"fit",void 0),Nc([I()],t.prototype,"description",void 0),Nc([I()],t.prototype,"template",void 0),Nc([I()],t.prototype,"tooltip",void 0),t}(Ee),Xre=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Ol=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},L3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Xre(t,n),Ol([I("")],t.prototype,"id",void 0),Ol([I(Number.MIN_VALUE)],t.prototype,"zIndex",void 0),Ol([re({},$n)],t.prototype,"margin",void 0),Ol([I(!0)],t.prototype,"visible",void 0),Ol([re({},Td)],t.prototype,"tooltip",void 0),Ol([I(!1)],t.prototype,"excludeFromLayout",void 0),Ol([I()],t.prototype,"addInfo",void 0),Ol([I("None")],t.prototype,"flip",void 0),Ol([I("All")],t.prototype,"flipMode",void 0),Ol([re({},Gre)],t.prototype,"symbolInfo",void 0),t}(Ee),qre=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Jn=function(n){function t(e,i,r,s){var o=n.call(this)||this;return o.data="",o.nodeId="",o.annotationId="",o.diagramId="",o.diagramId=i,o.nodeId=e,o.annotationId=r,o.templateFn=GF(s),o}return qre(t,n),t.prototype.getNodeTemplate=function(){return this.templateFn},Object.defineProperty(t.prototype,"content",{get:function(){return this.data},set:function(e){this.data=e,this.canReset||(this.canReset=!0,this.isTemplate||(this.template=_h(this,!0)),this.canReset=!1,this.isDirt=!0)},enumerable:!0,configurable:!0}),t}(as),Fx=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),hs=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},N3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Fx(t,n),hs([I("")],t.prototype,"id",void 0),hs([I("transparent")],t.prototype,"fill",void 0),hs([I("black")],t.prototype,"iconStrokeColor",void 0),hs([I(0)],t.prototype,"iconStrokeWidth",void 0),hs([I(!0)],t.prototype,"visibility",void 0),hs([I(10)],t.prototype,"width",void 0),hs([I(10)],t.prototype,"height",void 0),hs([I("transparent")],t.prototype,"handleStrokeColor",void 0),hs([I(1)],t.prototype,"handleStrokeWidth",void 0),hs([I("")],t.prototype,"pathData",void 0),hs([I(0)],t.prototype,"cornerRadius",void 0),hs([re({left:0,right:0,top:0,bottom:0},$n)],t.prototype,"padding",void 0),hs([re({},Td)],t.prototype,"tooltip",void 0),t}(Ee),O3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Fx(t,n),hs([re({x:0,y:0},z)],t.prototype,"offset",void 0),hs([re({},$n)],t.prototype,"margin",void 0),t}(N3),OI=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Fx(t,n),hs([I(.5)],t.prototype,"offset",void 0),hs([I("Center")],t.prototype,"alignment",void 0),hs([re({x:0,y:0},z)],t.prototype,"displacement",void 0),t}(N3);function Ad(n){return n?n instanceof Zn||n instanceof Nr?n.constraints&Lr.Select:n instanceof de?n.constraints&qe.Select:n.constraints&ie.Select:1}function to(n){return n?n instanceof Zn||n instanceof Nr?n.constraints&Lr.Drag:n instanceof de?n.constraints&qe.Drag:n instanceof si?1:n.constraints&ie.Drag:1}function $re(n,t){return n instanceof de?n.constraints&qe.PointerEvents:n.constraints&ie.PointerEvents}function kI(n){return n instanceof de?n.constraints&qe.Delete:n.constraints&ie.Delete}function PI(n){return n.constraints&qe.DragSourceEnd}function zI(n){return n.constraints&qe.DragTargetEnd}function RI(n){return n.constraints&qe.DragSegmentThumb}function HI(n){return n instanceof Zn||n instanceof Nr?n.constraints&Lr.Rotate:n.constraints&ie.Rotate}function BI(n){return n.constraints&ie.Shadow}function da(n){return n instanceof te&&n.constraints&ie.InConnect?n.constraints&ie.InConnect:0}function Ph(n){return n&&n.constraints&&!(n.constraints&ri.None)&&n.constraints&ri.InConnect?n.constraints&ri.InConnect:0}function zh(n){return n instanceof te&&n.constraints&ie.OutConnect?n.constraints&ie.OutConnect:0}function Ld(n){return n&&n.constraints&&!(n.constraints&ri.None)&&n.constraints&ri.OutConnect?n.constraints&ri.OutConnect:0}function kl(n,t){var e=0;return n instanceof Zn||n instanceof Nr?e=n.constraints&Lr.Resize:n&&("SouthEast"===t?e=n.constraints&ie.ResizeSouthEast:"East"===t?e=n.constraints&ie.ResizeEast:"NorthEast"===t?e=n.constraints&ie.ResizeNorthEast:"South"===t?e=n.constraints&ie.ResizeSouth:"North"===t?e=n.constraints&ie.ResizeNorth:"SouthWest"===t?e=n.constraints&ie.ResizeSouthWest:"West"===t?e=n.constraints&ie.ResizeWest:"NorthWest"===t&&(e=n.constraints&ie.ResizeNorthWest)),e}function FI(n){return n instanceof de?n.constraints&qe.AllowDrop:n.constraints&ie.AllowDrop}function Ds(n){return n.constraints&rt.Virtualization}function Vv(n){return n.tool&Ci.SingleSelect}function Wv(n){return n.tool&Ci.MultipleSelect}function Oc(n){return n.tool&Ci.ZoomPan}function _I(n){return n.tool&Ci.ContinuousDraw}function k3(n){return n.tool&Ci.DrawOnce}function UI(n){return n.tool&Ci.SingleSelect||n.tool&Ci.MultipleSelect}function Yv(n){return n.constraints&rt.UserInteraction}function P3(n){return n.constraints&rt.ZoomTextEdit}function Qv(n){return function ine(n){return n.constraints&rt.ApiUpdate}(n)||n.diagramActions&ee.ToolAction}function _x(n,t){return n.constraints&ri.Draw}function Ux(n,t){return n.constraints&ri.Drag}function jI(n){return!(n&Qa.DrawSelectorBorder)}function z3(n){return!!(n&Qa.PreventRenderSelector)}var jx=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Gv=function(n){function t(){var e=null!==n&&n.apply(this,arguments)||this;return e.childTable=[],e.cellStyle={},e.desiredRowHeight=[],e.desiredCellWidth=[],e}return jx(t,n),t.prototype.rowDefinitions=function(){return this.rowDefns},t.prototype.columnDefinitions=function(){return this.colDefns},t.prototype.addObject=function(e,i,r,s,o){if(this.rows.length>=i){var a=this.rows[parseInt(i.toString(),10)];if(a.cells.length>r){o=o||1,s=s||1;var l=a.cells[parseInt(r.toString(),10)];l.columnSpan=Math.max(o,l.columnSpan),l.rowSpan=Math.max(s,l.rowSpan);var h=new ane;(h=e).rowId=i,h.columnId=r,h.columnSpan=o,this.childTable[h.id]=h,this.addObjectToCell(h,l)}}},t.prototype.addObjectToCell=function(e,i){i.children||(i.children=[]),e.style.strokeColor="black",e.style.strokeWidth=1,i.children.push(e)},t.prototype.updateProperties=function(e,i,r,s){this.offsetX=e,this.offsetY=i,this.width=r,this.height=s},t.prototype.setDefinitions=function(e,i){this.rowDefns=e,this.colDefns=i,this.children=[],this.rows=this.rows||[];for(var r=0;r0){for(var h=0;hi&&this.updateRowHeight(e,l,!1)}},t.prototype.setTextRefresh=function(e){if(e.children&&e.children.length)for(var i=e.children,r=0;ri&&this.updateColumnWidth(e,a,!1)}},t.prototype.calculateCellWidth=function(e){for(var i,r,s,o=0;os.bounds.width&&(0===s.children.length||void 0===s.children[0].maxWidth)?s.outerBounds.width:s.bounds.width,i=i?is.bounds.height?s.outerBounds.height:s.bounds.height,i=i?i0?e.children[0]:void 0;if(a&&1===e.columnSpan){o="Width"===i?a.bounds.right:a.bounds.bottom,s||(s="Width"===i?a.bounds.width:a.bounds.height);for(var l=0;lo){var d=c-o+("Width"===i?a.bounds.width:a.bounds.height);s&&(s=s0?this.rowDefns.splice(e,0,i):this.rowDefns.push(i);var s=new R3;s.cells=[],(new Nd).width=this.width,this.addCellInRow(this.colDefns,i,s),e>this.rows.length-1?this.rows.push(s):this.rows.splice(e,0,s),r&&(this.measure(new me(this.width,this.height)),this.arrange(this.desiredSize))},t.prototype.addColumn=function(e,i,r){var s,o,a,l,h=this.rows;this.colDefns.length>0?this.colDefns.splice(e,0,i):this.colDefns.push(i),void 0!==this.width&&(this.width+=i.width);for(var c=0;cs.cells.length-1?s.cells.push(l):s.cells.splice(e,0,l),this.children.push(l);r&&(this.measure(new me(this.width,this.height)),this.arrange(this.desiredSize))},t.prototype.removeRow=function(e){var i,r,o=this.rows[parseInt(e.toString(),10)];this.height-=this.rowDefns[parseInt(e.toString(),10)].height;for(var a=0;a0){var r=0,s=0;i=new me(0,0),this.calculateSize();for(var o=0,a=this.rows;o0){for(var o=this.offsetX-e.width*this.pivot.x,a=this.offsetY-e.height*this.pivot.y,l=o,h=0,c=this.rows;h1&&this.children.splice(this.children.indexOf(f)+1,f.columnSpan-1),f.rowSpan>1)for(y=s,S=0;y+f.rowSpan-10){for(var c=0;c0?1:0,v=0;v0||a.outEdges.length>0))for(p=a.inEdges.concat(a.outEdges),s=0;s0)for(o=0;o1)for(a=1;a0))if(h=n.wrapper.children[0],"Horizontal"===e.orientation)for(o=e.header&&e.hasHeader?h.rows[1]:h.rows[0],r=0;r0){var e=void 0;t.lineRoutingModule&&t.constraints&rt.LineRouting&&t.lineRoutingModule.renderVirtualRegion(t,!0);for(var i=0;i0?o+1:o)].height=t.wrapper.height;else if(t.isPhase)for(l[t.rowIndex-o].offset=t.wrapper.height,f=0;f0?1:0)].width=t.wrapper.width}function WI(n,t){var i=n.shape,r=i.header&&i.hasHeader?1:0;return"Horizontal"===i.orientation?t.rowIndex-(r+=i.phases.length>0?1:0):t.columnIndex-(i.phaseSize&&i.phases.length>0?1:0)}function YI(n){var t=0,e=n.shape;return"Horizontal"===e.orientation&&(t=e.header&&e.hasHeader?1:0),e.phases.length>0&&e.phaseSize&&(t+=1),t}function QI(n,t,e,i){var r=n.shape;if(r.phases.length>0){var s=t.nameTable[r.phases[parseInt(i.toString(),10)].header.id];s&&s.maxWidth0?u+1:u);var w=kc(n,o),C=void 0!==i?i:l.lanes.length;if(u+=C,r={element:M,cause:n.diagramActions,diagramAction:n.getDiagramAction(n.diagramActions),state:"Changing",type:"Addition",cancel:!1,laneIndex:C},n.triggerEvent(Ce.collectionChange,r),!r.cancel){if(c){var D=new Xv;D.height=e.height,o.addRow(u,D,!1),s.height=void 0!==s.height?s.height+e.height:s.height,s.wrapper.height=o.height=s.height}else{var A=new Nd;A.width=e.width,o.addColumn(C+1,A,!1),s.width&&(s.width+=e.width,s.wrapper.width=o.width=s.width),n.diagramActions&ee.UndoRedo||(o.rows[0].cells[0].columnSpan+=1)}n.diagramActions&ee.UndoRedo||(M.id=""===M.id?Qe():M.id),void 0!==i?l.lanes.splice(i,0,M):l.lanes.push(M),r={element:M,cause:n.diagramActions,diagramAction:n.getDiagramAction(n.diagramActions),state:"Changed",type:"Addition",cancel:!1,laneIndex:C},n.triggerEvent(Ce.collectionChange,r),B3(o,n,s,u,C,c),h="Horizontal"===l.orientation?n.nameTable[o.rows[parseInt(u.toString(),10)].cells[0].children[0].id]:l.header&&l.hasHeader?n.nameTable[o.rows[1].cells[parseInt(u.toString(),10)].children[0].id]:n.nameTable[o.rows[0].cells[parseInt(u.toString(),10)].children[0].id],n.diagramActions&ee.UndoRedo||(d={type:"LaneCollectionChanged",changeType:"Insert",undoObject:$(M),redoObject:$(h),category:"Internal"},n.addHistoryEntry(d)),Zp(n,s,"Horizontal"===l.orientation?u:l.header&&l.hasHeader?1:0),$p(s),Pc(n,s);var R=!1;if((p=e.children)&&p.length>0)for(f=0;f0){var o=t.children[0],a=n.nameTable[o.id];(function vne(n,t,e){return n.left-(e.left||0)<=t.x&&n.right+(e.right||0)>=t.x&&n.top-(e.top||0)<=t.y&&n.bottom+(e.bottom||0)>=t.y})(o.bounds,e,r)&&(n.addChild(a,i),s=!0)}return s}function mne(n,t,e){if("SwimLane"===t.shape.type){var i=void 0,r=void 0,s=void 0,a=void 0,l=void 0,h=void 0,c=t.wrapper.bounds.x,d=t.wrapper.bounds.y,u=t.shape,p=u.padding,f=u.phases,g=void 0,v=t.wrapper.children[0],y="Horizontal"===u.orientation;if(i=u.header&&u.hasHeader?0:-1,u.phases.length>0&&(i+=1),e.offset>(y?u.lanes[0].header.width:u.lanes[0].header.height)){for(h=0;he.offset){if(g=h>0?e.offset-(h>0?f[h-1]:s).offset:e.offset,y){var b=v.columnDefinitions()[parseInt(h.toString(),10)];b.width-=g,(a=n.nameTable[u.phases[parseInt(h.toString(),10)].header.id]).maxWidth=a.wrapper.maxWidth=b.width,v.updateColumnWidth(h,b.width,!1);var M=new Nd;M.width=g,l=h,v.addColumn(h,M,!1);break}var w=v.rowDefinitions()[h+i];w.height-=g,a=n.nameTable[u.phases[parseInt(h.toString(),10)].header.id],v.updateRowHeight(h+i,w.height,!1);var C=new Xv;C.height=g,l=h,v.addRow(h+i,C,!1);break}if(n.diagramActions&ee.UndoRedo&&void 0===l&&(D=n.historyManager.currentEntry.next).isLastPhase&&function yne(n,t,e,i,r,s){var a=t.shape.phases[n-2],l=e.previousPhase.offset;if(r){var h=i.columnDefinitions()[n-1],c=new Nd;n>1?(c.width=h.width-(l-a.offset),h.width=l-a.offset):(c.width=h.width-l,h.width=l),i.updateColumnWidth(n-1,h.width,!1),i.addColumn(n,c,!1)}else{h=i.rowDefinitions()[parseInt(n.toString(),10)];var d=new Xv;n>1?(d.height=e.undoObject.offset-l,h.height=l-a.offset):(d.height=h.height-l,h.height=l),i.updateRowHeight(n,h.height,!1),i.addRow(1+n,d,!1)}}(l=f.length,t,D,v,y),l>=0){var A=new fb(t.shape,"phases",e,!0);if(n.diagramActions&ee.UndoRedo||(A.id+=Qe()),u.phases.splice(l,0,A),Vx(v,n,t,i,y,l),y){if(r=n.nameTable[v.rows[parseInt(i.toString(),10)].cells[parseInt(l.toString(),10)].children[0].id],0===l&&u.header&&u.hasHeader){v.rows[0].cells[0].children=v.rows[0].cells[1].children,v.rows[0].cells[1].children=[];for(var x=v.rows[0],R=0;Rl+1){var O=n.nameTable[v.rows[parseInt(i.toString(),10)].cells[l+1].children[0].id];v.updateColumnWidth(l+1,L[l+1].width,!0,p),O.maxWidth=O.wrapper.maxWidth=L[l+1].width}t.width=t.wrapper.width=t.wrapper.children[0].width=v.width}else{r=n.nameTable[v.rows[i+l].cells[0].children[0].id];var N=v.rowDefinitions(),T=N[i+l].height;(function Ine(n,t,e,i,r){for(var o,a,l=e.rows[parseInt(i.toString(),10)],h=e.rows[i+1],c=e.rows[i-1],d=1;di+l+1&&v.updateRowHeight(i+l+1,T=N[i+l+1].height,!0,p),t.height=t.wrapper.height=t.wrapper.children[0].height=v.actualSize.height}if($p(t),t.width=t.wrapper.actualSize.width,Pc(n,t),n.drag(t,c-t.wrapper.bounds.x,d-t.wrapper.bounds.y),VI(t,n),n.commandHandler.select(r),!(n.diagramActions&ee.UndoRedo)){var D={type:"PhaseCollectionChanged",changeType:"Insert",undoObject:$(A),redoObject:$(r),category:"Internal"};n.addHistoryEntry(D)}n.updateDiagramObject(t)}}}}function V3(n,t,e,i,r,s,o){var a,l,f,h=t.shape,c="Horizontal"===h.orientation,d=t.wrapper.children[0],g=c?s:o;e?(a=c?e.bounds.x+e.bounds.width:e.bounds.x,l=c?e.bounds.y:e.bounds.y+e.bounds.height):(a=d.bounds.x,l=r.bounds.y);var v=new Ne(a,l,i.desiredCellWidth,i.desiredCellHeight),S=qv(n,0,t,{id:t.id+(c?h.lanes[g-2]:h.lanes[g-1]).id+Qe()[0],rowIndex:s,columnIndex:o,width:i.minWidth,height:i.minHeight,style:(c?h.lanes[g-2]:h.lanes[g-1]).style,constraints:ie.Default|ie.AllowDrop,container:{type:"Canvas",orientation:c?"Horizontal":"Vertical"}},!1,!1,!0);if(S.children[0].isCalculateDesiredSize=!1,d.addObject(S,s,o),r&&r.children&&r.children.length)for(f=0;f1)for(var f=1;fh.margin.left&&(h.margin.left=p)):(h.margin.top-=e.desiredCellHeight,p>h.margin.top&&(h.margin.top=p)))}(n,r,i,v,S,c,e)}function W3(n,t,e){if("SwimLane"===t.shape.type&&("ResizeSouth"===e||"ResizeEast"===e)){var i=t.shape,r=t.wrapper.children[0],s=void 0,o=void 0;"ResizeSouth"===e?"Vertical"===i.orientation?s=r.rows[r.rows.length-1].cells[0]:(o=r.rows.length-1,s=r.rows[parseInt(o.toString(),10)].cells[r.rows[parseInt(o.toString(),10)].cells.length-1]):(o=i.header&&i.hasHeader?1:0,s=r.rows[parseInt(o.toString(),10)].cells[r.rows[parseInt(o.toString(),10)].cells.length-1]),n.commandHandler.select(n.nameTable[s.children[0].id])}}function GI(n,t,e,i,r,s){var o,a,l,c,u,p,f,d=Qe(),g=n.shape,v=g.phases,y=n.offsetX-n.wrapper.actualSize.width/2,S=n.offsetY-n.wrapper.actualSize.height/2;if("Vertical"===g.orientation&&(S+=g.header&&g.hasHeader?g.header.height:0),!s)for(r||(n.id+=d,g&&g.header&&g.hasHeader?g.header.id+=d:g.header=void 0),o=0;v&&o0&&s.columnIndex>0||s.isLane)?(a=function Lne(n,t,e){for(var i=new Ne,r="SwimLane"===n.shape.type?n.wrapper.children[0].rows:n.wrapper.rows,s=e?1:0;s=0;a--)i?i.id===o.children[parseInt(a.toString(),10)].id&&o.children.splice(a,1):(n.removeDependentConnector(o.children[parseInt(a.toString(),10)]),n.diagramActions&ee.UndoRedo||(n.diagramActions=n.diagramActions|ee.UndoRedo,s=!0),n.remove(o.children[parseInt(a.toString(),10)]),o.children.splice(a,1),s&&(n.diagramActions=n.diagramActions&~ee.UndoRedo))}function Mne(n){return n.children[0]}function Jv(n,t){t&&(n.nodes.splice(n.nodes.indexOf(t),1),n.removeFromAQuad(t),n.removeObjectsFromLayer(t),delete n.nameTable[t.id],n.removeElements(t))}function Q3(n,t,e,i){var r;if("SwimLane"===e.shape.type){var s=e.shape,o=void 0;if(1===s.lanes.length)n.remove(e);else{var a=e.wrapper.bounds.x,l=e.wrapper.bounds.y,h=void 0,c=void 0,d=void 0,u=void 0,f=e.wrapper.children[0];if(o=i?s.lanes.indexOf(i):WI(e,t),r={element:t,cause:n.diagramActions,diagramAction:n.getDiagramAction(n.diagramActions),state:"Changing",type:"Removal",cancel:!1,laneIndex:o},n.triggerEvent(Ce.collectionChange,r),!r.cancel){var g=s.lanes[parseInt(o.toString(),10)],v=g.children;g.children=[];for(var y=0;y0)for(u=0;u0)for(u=0;u0)for(e=0;e1){c===l.phases.length-1&&(o=!0,a=$(l.phases[c-1]));var u=$(l.phases[parseInt(c.toString(),10)]);if(l.phases.splice(c,1),!(n.diagramActions&ee.UndoRedo)){var p={type:"PhaseCollectionChanged",changeType:"Remove",undoObject:u,previousPhase:a,redoObject:$(t),category:"Internal",isLastPhase:o};n.addHistoryEntry(p)}"Horizontal"===l.orientation?function Cne(n,t,e,i){var r,s,o,a,l,h,c,d,u,p,f,g;for(i=void 0!==i?i:e.columnIndex,c=0;c1&&(s=r.cells[parseInt(i.toString(),10)],l=(o=r.cells.length-1===i?r.cells[i-1]:r.cells[i+1]).children[0],s.children.length>0))if(f=n.nameTable[(a=s.children[0]).id],0===o.children.length&&s.children.length>0)o.children=s.children,o.columnSpan=s.columnSpan-1;else{for(d=0;d0){var M=s.children[0],w=n.nameTable[M.id];if(i=e.x&&a.bounds.y<=e.y&&a.bounds.bottom>=e.y)&&!(t.constraints&ie.AllowMovingOutsideLane)){var l=$(t);n.clearSelection(),$3(n,t),t.parentId="",t.parentObj=n,t.propName="nodes";var h={type:"ChildCollectionChanged",category:"Internal",undoObject:l,redoObject:$(t)};n.addHistoryEntry(h),n.commandHandler.isContainer&&(n.commandHandler.isContainer=!1,n.endGroupAction()),Z3(t,n)}n.protectPropertyChange(o)}}function XI(n,t){var e,i,r;return n.enableServerDataBinding(!1),ce()||(n.selectedObject.helperObject?r=n.selectedObject.helperObject:(n.selectedItems.nodes.length>0||n.selectedItems.connectors.length>0)&&(t instanceof si&&t.nodes.length+t.connectors.length===1?(e=t.nodes.length>0?t.nodes[0]:t.connectors[0],i=n.selectedItems.wrapper.children[0]):(e=t,i=n.selectedItems.wrapper),n.selectedObject.actualObject=e,!n.currentSymbol&&(e.isLane&&Gx(e,n)&&cs(n,e)||!e.isLane&&cs(n,e)||n.constraints&rt.LineRouting&&n.selectedItems.nodes.length>0))&&(r=function Nne(n,t){for(var e,i={},r=0,s=Object.keys(t);r=t.x-e&&n.x<=t.x+e&&n.y>=t.y-e&&n.y<=t.y+e}function Xa(n){return n.selectedItems.nodes.length>0||n.selectedItems.connectors.length>0}function K3(n){return 1===n.selectedItems.connectors.length&&!n.selectedItems.nodes.length}function _r(n,t,e,i){if(void 0===e&&(e=!0),t instanceof si)return!0;if(t instanceof te)for(;t;){if(-1!==n.selectedItems.nodes.indexOf(t)&&void 0===n.selectedItems.annotation)return!0;if(e)break;t=n.nameTable[t.parentId]}else if(t instanceof de){if(-1!==n.selectedItems.connectors.indexOf(t)&&void 0===n.selectedItems.annotation)return!0}else if((t instanceof Zn||t instanceof Nr)&&n.selectedItems.annotation&&n.selectedItems.wrapper.children[0].id===i.id)return!0;return!1}var Xx={None:"default",Rotate:"crosshair",Select:"default",Drag:"move",ResizeWest:"w-resize",ResizeEast:"e-resize",ResizeSouth:"s-resize",ResizeNorth:"n-resize",Draw:"crosshair",PortDraw:"crosshair",ResizeNorthEast:"ne-resize",ResizeNorthWest:"nw-resize",ResizeSouthEast:"se-resize",ResizeSouthWest:"sw-resize",ConnectorSourceEnd:"move",ConnectorTargetEnd:"move",BezierSourceThumb:"move",BezierTargetThumb:"move",OrthoThumb:"move",SegmentEnd:"move",Pan:"grab",Hyperlink:"pointer",PortDrag:"pointer",LabelSelect:"pointer",LabelDrag:"move",LabelRotate:"crosshair",LabelResizeWest:"w-resize",LabelResizeEast:"e-resize",LabelResizeSouth:"s-resize",LabelResizeNorth:"n-resize",LabelResizeNorthEast:"ne-resize",LabelResizeNorthWest:"nw-resize",LabelResizeSouthEast:"se-resize",LabelResizeSouthWest:"sw-resize"},ds=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),kd=function(n,t,e,i){return new(e||(e=Promise))(function(r,s){function o(h){try{l(i.next(h))}catch(c){s(c)}}function a(h){try{l(i.throw(h))}catch(c){s(c)}}function l(h){h.done?r(h.value):new e(function(c){c(h.value)}).then(o,a)}l((i=i.apply(n,t||[])).next())})},Pd=function(n,t){var i,r,s,o,e={label:0,sent:function(){if(1&s[0])throw s[1];return s[1]},trys:[],ops:[]};return o={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function a(h){return function(c){return function l(h){if(i)throw new TypeError("Generator is already executing.");for(;e;)try{if(i=1,r&&(s=2&h[0]?r.return:h[0]?r.throw||((s=r.return)&&s.call(r),0):r.next)&&!(s=s.call(r,h[1])).done)return s;switch(r=0,s&&(h=[2&h[0],s.value]),h[0]){case 0:case 1:s=h;break;case 4:return e.label++,{value:h[1],done:!1};case 5:e.label++,r=h[1],h=[0];continue;case 7:h=e.ops.pop(),e.trys.pop();continue;default:if(!(s=(s=e.trys).length>0&&s[s.length-1])&&(6===h[0]||2===h[0])){e=0;continue}if(3===h[0]&&(!s||h[1]>s[0]&&h[1]-1&&(r=i.fixedUserHandles[parseInt(o.toString(),10)]);this.commandHandler.triggerEvent(Ce.fixedUserHandleClick,{fixedUserHandle:r,element:e.source}),n.prototype.mouseUp.call(this,e)},t}(us),zd=function(n){function t(e,i){var r=n.call(this,e,!0)||this;return r.isConnected=!1,r.endPoint=i,r}return ds(t,n),t.prototype.mouseDown=function(e){return kd(this,void 0,void 0,function(){var r,s,o,a,l;return Pd(this,function(h){if(this.inAction=!0,this.undoElement=void 0,this instanceof pa||(this.undoElement=$(e.source)),n.prototype.mouseDown.call(this,e),e.source&&e.source.connectors&&(this.oldConnector=$(r=e.source.connectors[0])),"BezierSourceThumb"===this.endPoint||"BezierTargetThumb"===this.endPoint)for(s=0;s0))},t.prototype.endAction=function(){n.prototype.endAction.call(this),this.prevPosition=null,this.endPoint=null},t}(us),ua=function(n){function t(e,i){var r=n.call(this,e,!0)||this;return r.currentTarget=null,r.isStartAction=!1,r.canCancel=!1,r.canTrigger=!1,r.objectType=i,r}return ds(t,n),t.prototype.mouseDown=function(e){if(e.source instanceof te||e.source instanceof de){var i=this.commandHandler.getSelectedObject();this.commandHandler.selectObjects([e.source],e.info&&e.info.ctrlKey,i);var r={nodes:[],connectors:[]};e.source instanceof te?r.nodes.push($(e.source)):r.connectors.push($(e.source)),this.undoElement=$(r)}else this.undoElement=$(e.source);this.undoParentElement=this.commandHandler.getSubProcess(e.source),"Port"===this.objectType&&(this.portId=e.sourceWrapper.id),this.commandHandler.insertBlazorConnector(e.source),n.prototype.mouseDown.call(this,e),this.initialOffset={x:0,y:0}},t.prototype.mouseUp=function(e,i){return kd(this,void 0,void 0,function(){var s,o,a,l,h,c,d,u,f,g,v,y,S,b,M;return Pd(this,function(w){if(this.checkPropertyValue(),a=!1,h={nodes:[],connectors:[]},"Port"!==this.objectType){if(e.source instanceof te||e.source instanceof de?(e.source instanceof te?h.nodes.push($(e.source)):h.connectors.push($(e.source)),(o=$(h)).offsetX=(c=e.source.wrapper).offsetX,o.offsetY=c.offsetY):o=$(e.source),("helper"===(l=this.commandHandler.renderContainerHelper(e.source)||e.source||this.commandHandler.renderContainerHelper(e.source)).id||"helper"!==l.id)&&((l instanceof si&&(Math.round(l.width)===Math.round(this.undoElement.width)&&Math.round(l.height)===Math.round(this.undoElement.height)||l.selectedObjects&&1===l.selectedObjects.length)||!(l instanceof si))&&(l.offsetX!==this.undoElement.offsetX||l.offsetY!==this.undoElement.offsetY||l.sourcePoint!==this.undoElement.sourcePoint||l.targetPoint!==this.undoElement.targetPoint)||this.isSelectionHasConnector(l))&&(e.source&&(s={offsetX:e.source.wrapper.offsetX,offsetY:e.source.wrapper.offsetY}),g={source:e.source,state:"Completed",oldValue:this.intialValue,newValue:s,target:this.currentTarget,targetPosition:this.currentPosition,allowDrop:(g={source:e.source,state:"Completed",oldValue:this.intialValue,newValue:s,target:this.currentTarget,targetPosition:this.currentPosition,allowDrop:!0,cancel:!1}).allowDrop,cancel:g.cancel},d=!0,"helper"===l.id?this.canTrigger?(this.commandHandler.triggerEvent(Ce.positionChange,g),this.connectorEndPointChangeEvent(g),d=!0):d=!1:(this.commandHandler.triggerEvent(Ce.positionChange,g),this.connectorEndPointChangeEvent(g)),!i&&d&&(this.commandHandler.startGroupAction(),a=!0,M={type:"PositionChanged",redoObject:$(o),undoObject:$(this.undoElement),category:"Internal"},o.nodes[0]&&o.nodes[0].processId&&(u={type:"SizeChanged",category:"Internal",undoObject:this.undoParentElement,redoObject:this.commandHandler.getSubProcess(e.source)},this.commandHandler.addHistoryEntry(u)),this.commandHandler.addHistoryEntry(M))),this.commandHandler.snapPoint(this.prevPosition,this.currentPosition,0,0),this.commandHandler.removeSnap(),this.commandHandler.removeHighlighter(),e.source&&this.currentTarget&&FI(this.currentTarget)&&this.commandHandler.isDroppable(e.source,this.currentTarget)){if(f=!0,this.commandHandler.drop(this.currentElement,this.currentTarget,this.currentPosition),this.currentTarget&&this.currentTarget instanceof de&&!0===this.commandHandler.diagram.enableConnectorSplit)if(this.currentElement&&this.currentElement instanceof te){if(void 0!==this.currentElement.children)for(b=0;b0)for(var s=0;s0)for(var a=0;a0)for(a=0;a0&&e.connectors.length>0)||e.width===this.undoElement.width&&e.height===this.undoElement.height)},t.prototype.mouseMove=function(e){n.prototype.mouseMove.call(this,e);var r,s,i=!1;(r=this.commandHandler.renderContainerHelper(e.source)||e.source)instanceof te||r instanceof de?r instanceof te?r.offsetX===this.undoElement.nodes[0].offsetX&&r.offsetY===this.undoElement.nodes[0].offsetY&&(i=!0):z.equals(r.sourcePoint,this.undoElement.connectors[0].sourcePoint)&&z.equals(r.targetPoint,this.undoElement.connectors[0].targetPoint)&&(i=!0):r.wrapper.offsetX===this.undoElement.wrapper.offsetX&&r.wrapper.offsetY===this.undoElement.wrapper.offsetY&&(i=!0),r&&(s={offsetX:r.wrapper.offsetX,offsetY:r.wrapper.offsetY});var o={source:r,state:"Start",oldValue:s,newValue:s,target:e.target,targetPosition:e.position,allowDrop:!0,cancel:!1};if(o={source:r,state:"Start",oldValue:s,newValue:s,target:e.target,targetPosition:e.position,allowDrop:o.allowDrop,cancel:o.cancel},this.isStartAction||(this.intialValue={offsetX:r.wrapper.offsetX,offsetY:r.wrapper.offsetY}),i&&!ce()&&(this.commandHandler.triggerEvent(Ce.positionChange,o),this.connectorEndPointChangeEvent(o),this.isStartAction=!0),this.currentPosition=e.position,"Port"!==this.objectType){var h=this.initialOffset.x+(this.currentPosition.x-this.prevPosition.x),c=this.initialOffset.y+(this.currentPosition.y-this.prevPosition.y);this.commandHandler.dragOverElement(e,this.currentPosition),this.commandHandler.disConnect(e.source),this.commandHandler.removeSnap();var d,u=void 0,p=this.commandHandler.snapPoint(this.prevPosition,this.currentPosition,h,c);this.initialOffset.x=h-p.x,this.initialOffset.y=c-p.y,r&&(d={offsetX:r.wrapper.offsetX,offsetY:r.wrapper.offsetY},u={offsetX:r.wrapper.offsetX+p.x,offsetY:r.wrapper.offsetY+p.y}),this.currentTarget&&e.target!==this.currentTarget&&this.commandHandler.removeChildFromBPmn(e.source,e.target,this.currentTarget),this.currentTarget=e.target;var f={source:r,state:"Progress",oldValue:d,newValue:u,target:e.target,targetPosition:e.position,allowDrop:!0,cancel:!1};if(this.commandHandler.triggerEvent(Ce.positionChange,f),this.canTrigger=!0,this.connectorEndPointChangeEvent(f,p),!f.cancel&&!this.canCancel){this.blocked=!this.commandHandler.dragSelectedObjects(p.x,p.y);var g=!this.commandHandler.mouseOver(this.currentElement,this.currentTarget,this.currentPosition);this.blocked=this.blocked||g}if(this.commandHandler.removeStackHighlighter(),this.commandHandler.renderStackHighlighter(e),this.currentTarget&&e.source!==this.currentTarget&&this.commandHandler.isDroppable(e.source,this.currentTarget)&&"helper"!==e.source.id){var v=e.source instanceof si?e.source.nodes[0]:e.source;!this.commandHandler.isParentAsContainer(v,!0)&&"SwimLane"!==v.shape.type&&!v.shape.isPhase&&(this.currentTarget.isLane?this.commandHandler.renderStackHighlighter(e,this.currentTarget):this.commandHandler.drawHighlighter(this.currentTarget))}else this.commandHandler.removeHighlighter();if(this.commandHandler.canEnableDefaultTooltip()){var y=this.getTooltipContent(e.source);this.commandHandler.showTooltip(e.source,e.position,ko(function(){return y}),"MoveTool",this.isTooltipVisible),this.isTooltipVisible=!1}}else{var b=Hi(),M=e.source;qi(b,-M.rotateAngle||-M.wrapper.rotateAngle,M.offsetX||M.wrapper.offsetX,M.offsetY||M.wrapper.offsetY);var w=Je(b,{x:this.prevPosition.x,y:this.prevPosition.y}),C=Je(b,{x:e.position.x,y:e.position.y});this.commandHandler.portDrag(e.source,e.sourceWrapper,C.x-w.x,C.y-w.y)}return this.prevPosition=this.currentPosition,!this.blocked},t.prototype.getTooltipContent=function(e){return"X:"+Math.round(e.wrapper.bounds.x)+" Y:"+Math.round(e.wrapper.bounds.y)},t.prototype.mouseLeave=function(e){this.mouseUp(e)},t.prototype.endAction=function(){n.prototype.endAction.call(this),this.currentTarget=null,this.prevPosition=null},t}(us),qx=function(n){function t(e){var i=n.call(this,e,!0)||this;return i.rotateStart=!1,i}return ds(t,n),t.prototype.mouseDown=function(e){if(this.undoElement=$(e.source),this.undoElement.nodes[0]&&this.undoElement.nodes[0].children)for(var r=this.commandHandler.getAllDescendants(this.undoElement.nodes[0],[]),s=0;s=2){var s=e.startTouches[0],o=e.startTouches[1],a=e.moveTouches[0],l=e.moveTouches[1],h=this.getDistance(a,l)/this.getDistance(s,o);this.commandHandler.zoom(h,0,0,e.position),this.updateTouch(s,a),this.updateTouch(o,l)}}else this.commandHandler.scroll(this.currentPosition.x-this.prevPosition.x,this.currentPosition.y-this.prevPosition.y,this.currentPosition);return this.commandHandler.dataBinding(),!this.blocked},t.prototype.mouseUp=function(e){this.commandHandler.setBlazorDiagramProps(!1),this.checkPropertyValue(),this.commandHandler.updatePanState(!1),n.prototype.mouseUp.call(this,e),this.inAction=!1},t.prototype.endAction=function(){n.prototype.endAction.call(this)},t.prototype.getDistance=function(e,i){var r=i.pageX-e.pageX,s=i.pageY-e.pageY;return Math.sqrt(r*r+s*s)},t.prototype.updateTouch=function(e,i){e.pageX=i.pageX,e.pageY=i.pageY},t}(us),Une=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseUp=function(e){this.checkPropertyValue(),this.commandHandler.initExpand(e),n.prototype.mouseUp.call(this,e)},t}(us),eF=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseUp=function(e){this.checkPropertyValue();var i="_blank",r="",s=window.innerHeight,o=window.innerWidth,a=window.screenTop,l=window.screenLeft;"CurrentTab"===e.sourceWrapper.hyperlink.hyperlinkOpenState?i="_self":"NewWindow"===e.sourceWrapper.hyperlink.hyperlinkOpenState&&(r="height="+s+",width="+o+",top="+a+",left="+l),window.open(e.sourceWrapper.hyperlink.link,i,r).focus(),n.prototype.mouseUp.call(this,e)},t}(us),Rh=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseDown=function(e){if(n.prototype.mouseDown.call(this,e),this.inAction=!0,this.drawingObject){var r=void 0,s=this.drawingObject.shape;this.drawingObject.shape.points.push(r={x:(r=s.points[s.points.length-1]).x,y:r.y})}else this.startPoint={x:this.startPosition.x,y:this.startPosition.y},this.drawingObject=this.commandHandler.drawObject({offsetX:this.currentPosition.x,offsetY:this.currentPosition.y,width:5,height:5,style:{strokeColor:"black",strokeWidth:1},shape:{type:"Basic",shape:"Polygon",points:[{x:this.startPoint.x,y:this.startPoint.y},{x:this.currentPosition.x,y:this.currentPosition.y}]}})},t.prototype.mouseMove=function(e){if(n.prototype.mouseMove.call(this,e),this.inAction){var i=this.drawingObject.shape;if(i.points[i.points.length-1].x=this.currentPosition.x,i.points[i.points.length-1].y=this.currentPosition.y,this.drawingObject.wrapper.children[0].data=Ix(this.drawingObject.shape.points),this.inAction&&!1===z.equals(this.currentPosition,this.prevPosition)){var r=Ne.toBounds(this.drawingObject.shape.points);this.commandHandler.updateNodeDimension(this.drawingObject,r)}}return!0},t.prototype.mouseUp=function(e,i){this.checkPropertyValue(),n.prototype.mouseMove.call(this,e),this.inAction&&(this.inAction=!1,this.commandHandler.addObjectToDiagram(this.drawingObject)),this.endAction()},t.prototype.mouseWheel=function(e){n.prototype.mouseWheel.call(this,e),this.mouseMove(e)},t.prototype.endAction=function(){this.inAction=!1,this.drawingObject=null},t}(us),Hh=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseMove=function(e){if(n.prototype.mouseMove.call(this,e),this.inAction){var i=this.drawingObject;i.targetPoint=this.currentPosition,this.commandHandler.updateConnectorPoints(i)}return!0},t.prototype.mouseDown=function(e){if(n.prototype.mouseDown.call(this,e),this.inAction=!0,this.drawingObject){var r=this.drawingObject,s=void 0;(s=new Pl(r,"segments",{type:"Straight"},!0)).point=this.currentPosition,r.segments[r.segments.length-1]=s}else this.drawingObject=this.commandHandler.drawObject({id:"Connector",type:"Straight",sourcePoint:this.currentPosition,targetPoint:this.currentPosition})},t.prototype.mouseWheel=function(e){n.prototype.mouseWheel.call(this,e),this.mouseMove(e)},t.prototype.mouseUp=function(e){if(this.checkPropertyValue(),n.prototype.mouseMove.call(this,e),this.inAction&&this.drawingObject){var i=this.drawingObject;i.segments[i.segments.length-1].point={x:0,y:0},this.commandHandler.addObjectToDiagram(this.drawingObject)}this.endAction()},t.prototype.endAction=function(){this.drawingObject=null,this.inAction=!1},t}(us),jne=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseDown=function(e){this.inAction=!0,this.undoElement=$(e.source),this.annotationId=e.sourceWrapper.id,n.prototype.mouseDown.call(this,e)},t.prototype.mouseMove=function(e){n.prototype.mouseMove.call(this,e);var i=this.currentPosition.x-this.prevPosition.x,r=this.currentPosition.y-this.prevPosition.y,s=e.source;if(s instanceof te){var o=Hi();qi(o,-s.rotateAngle,0,0);var a=Je(o,{x:i,y:r});i=a.x,r=a.y}return this.inAction&&(this.commandHandler.labelDrag(e.source,e.sourceWrapper,i,r),this.commandHandler.updateSelector()),this.prevPosition=this.currentPosition,!this.blocked},t.prototype.mouseUp=function(e){this.checkPropertyValue();var i=e.source;this.inAction=!1;var r={type:"AnnotationPropertyChanged",objectId:this.annotationId,undoObject:$(this.undoElement),category:"Internal",redoObject:$(i)};this.commandHandler.addHistoryEntry(r),n.prototype.mouseUp.call(this,e)},t.prototype.mouseLeave=function(e){this.mouseUp(e)},t}(us),Vne=function(n){function t(e,i){var r=n.call(this,e,!0)||this;return r.corner=i,r}return ds(t,n),t.prototype.mouseDown=function(e){this.inAction=!0;var i=e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0];this.annotationId=e.source.wrapper.children[0].id,this.undoElement=$(i);var r=e.source.wrapper.children[0];this.initialBounds={x:r.offsetX,y:r.offsetY,width:r.actualSize.width,height:r.actualSize.height},n.prototype.mouseDown.call(this,e)},t.prototype.mouseMove=function(e){return n.prototype.mouseMove.call(this,e),this.inAction&&this.resizeObject(e),!this.blocked},t.prototype.mouseUp=function(e){this.checkPropertyValue();var i=e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0];this.inAction=!1;var r={type:"AnnotationPropertyChanged",objectId:this.annotationId,redoObject:$(i),undoObject:$(this.undoElement),category:"Internal"};this.commandHandler.addHistoryEntry(r),n.prototype.mouseUp.call(this,e)},t.prototype.mouseLeave=function(e){this.mouseUp(e)},t.prototype.resizeObject=function(e){var i,s,o,r=e.source.wrapper.children[0],a={x:r.offsetX,y:r.offsetY},l=r.rotateAngle;l=((l+=(i=e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0])instanceof te?i.rotateAngle:0)+360)%360;var h=Hi();qi(h,l,a.x,a.y);var c=this.corner.slice(5),d=this.updateSize(r,this.startPosition,this.currentPosition,c,this.initialBounds,l),u=r.offsetX-r.actualSize.width*r.pivot.x,p=r.offsetY-r.actualSize.height*r.pivot.y,f=this.getPivot(c),g=Je(h,f={x:u+r.actualSize.width*f.x,y:p+r.actualSize.height*f.y});d.x=g.x,d.y=g.y,this.commandHandler.labelResize(i,e.source.annotation,s=(s=d.width)<0?1:s,o=(o=d.height)<0?1:o,d,e.source),this.commandHandler.updateSelector()},t}(us),Wne=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseDown=function(e){this.inAction=!0,this.annotationId=e.source.wrapper.children[0].id,this.undoElement=$(e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0]),n.prototype.mouseDown.call(this,e)},t.prototype.mouseMove=function(e){return n.prototype.mouseMove.call(this,e),e.source&&this.inAction&&(this.commandHandler.labelRotate(e.source.nodes[0]?e.source.nodes[0]:e.source.connectors[0],e.source.annotation,this.currentPosition,e.source),this.commandHandler.updateSelector()),this.prevPosition=this.currentPosition,!this.blocked},t.prototype.mouseUp=function(e){this.checkPropertyValue(),this.inAction=!1;var r={type:"AnnotationPropertyChanged",objectId:this.annotationId,redoObject:$(e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0]),undoObject:$(this.undoElement),category:"Internal"};this.commandHandler.addHistoryEntry(r),n.prototype.mouseUp.call(this,e)},t.prototype.mouseLeave=function(e){this.mouseUp(e)},t}(us),Yne=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseMove=function(e){if(n.prototype.mouseMove.call(this,e),this.inAction){var i=this.drawingObject.shape;if(i.points.push(this.currentPosition),this.drawingObject.wrapper.children[0].data=bx(this.drawingObject.shape.points),i.data=bx(i.points),this.inAction&&!1===z.equals(this.currentPosition,this.prevPosition)){var s=Ne.toBounds(this.drawingObject.shape.points);this.commandHandler.updateNodeDimension(this.drawingObject,s)}}return!0},t.prototype.mouseDown=function(e){n.prototype.mouseDown.call(this,e),this.inAction=!0,this.startPoint={x:this.startPosition.x,y:this.startPosition.y},this.drawingObject=this.commandHandler.drawObject({offsetX:this.currentPosition.x,offsetY:this.currentPosition.y,width:5,height:5,style:{strokeColor:"black",strokeWidth:1,fill:"transparent"},shape:{type:"Path",points:[{x:this.startPoint.x,y:this.startPoint.y},{x:this.currentPosition.x,y:this.currentPosition.y}]}})},t.prototype.mouseUp=function(e){if(this.checkPropertyValue(),this.inAction){this.inAction=!1;var s=this.drawingObject.shape,o=s.points;this.commandHandler.addObjectToDiagram(this.drawingObject),this.commandHandler.diagram.remove(this.commandHandler.diagram.nameTable[""+this.drawingObject.id]),o=this.pointReduction(o,10);var h={id:"newConnector"+Qe(),type:"Bezier",sourcePoint:{x:o[0].x,y:o[0].y},targetPoint:{x:o[o.length-1].x,y:o[o.length-1].y},segments:[],bezierSettings:{allowSegmentsReset:!1}};this.drawingObject=this.commandHandler.drawObject(h),this.drawingObject=this.bezierCurveSmoothness(o,.5,this.drawingObject,s),this.commandHandler.updateConnectorPoints(this.drawingObject),this.commandHandler.addObjectToDiagram(this.drawingObject),n.prototype.mouseUp.call(this,e)}},t.prototype.pointReduction=function(e,i){if(null===e||e.length<3)return e;var s=e.length-1,o=[];for(o.push(0),o.push(s);e[parseInt((0).toString(),10)]===e[parseInt(s.toString(),10)];)s--;this.reduction(e,0,s,i,o);var a=[];return o.sort(function(l,h){return l-h}),o.forEach(function(l){a.push(e[parseInt(l.toString(),10)])}),a},t.prototype.reduction=function(e,i,r,s,o){for(var a=0,l=0,h=i;ha&&(a=c,l=h)}a>s&&0!==l&&(o.push(l),this.reduction(e,i,l,s,o),this.reduction(e,l,r,s,o))},t.prototype.perpendicularDistance=function(e,i,r){return Math.abs(.5*(e.x*i.y-i.x*e.y+(i.x*r.y-r.x*i.y)+(r.x*e.y-e.x*r.y)))/Math.sqrt(Math.pow(e.x-i.x,2)+Math.pow(e.y-i.y,2))*2},t.prototype.bezierCurveSmoothness=function(e,i,r,s){if(e.length<3)return r;for(var o=0;o=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Qne=function(n){if(n)switch(n.type){case"Bpmn":return $ne;case"UmlActivity":return qne;case"UmlClassifier":return Kne;default:return im}return im},Gne=function(n){if(n)switch(n.type){case"Straight":default:return Pl;case"Bezier":return ps;case"Orthogonal":return bi}},tF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I(10)],t.prototype,"width",void 0),Pe([I(10)],t.prototype,"height",void 0),Pe([I("Arrow")],t.prototype,"shape",void 0),Pe([re({fill:"black",strokeColor:"black",strokeWidth:1},Ll)],t.prototype,"style",void 0),Pe([re({x:0,y:.5},z)],t.prototype,"pivot",void 0),Pe([I("")],t.prototype,"pathData",void 0),t}(Ee),JI=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I(0)],t.prototype,"angle",void 0),Pe([I(0)],t.prototype,"distance",void 0),t}(Ee),Xne=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I(Ex.All)],t.prototype,"controlPointsVisibility",void 0),Pe([I("FreeForm")],t.prototype,"segmentEditOrientation",void 0),Pe([I(CI.Default)],t.prototype,"smoothness",void 0),Pe([I(!0)],t.prototype,"allowSegmentsReset",void 0),t}(Ee),im=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I("None")],t.prototype,"type",void 0),t}(Ee),qne=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I("Object")],t.prototype,"flow",void 0),Pe([I(30)],t.prototype,"exceptionFlowHeight",void 0),t}(im),$ne=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I("Sequence")],t.prototype,"flow",void 0),Pe([I("Normal")],t.prototype,"sequence",void 0),Pe([I("Default")],t.prototype,"message",void 0),Pe([I("Default")],t.prototype,"association",void 0),t}(im),iF=function(n){function t(e,i,r,s){var o=n.call(this,e,i,r,s)||this;return o.points=[],o}return Qs(t,n),Pe([I("Straight")],t.prototype,"type",void 0),Pe([I(!0)],t.prototype,"allowDrag",void 0),t}(Ee),Pl=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),t.prototype.getClassName=function(){return"StraightSegment"},Pe([re({x:0,y:0},z)],t.prototype,"point",void 0),t}(iF),ps=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),t.prototype.getClassName=function(){return"BezierSegment"},t.prototype.getPoints=function(e,i){var r=[];if(r.length>0||null!=i){var o=this.bezireToPoly(r.length>0?r[r.length-1]:i,e);r.push.apply(r,o)}return r},t.prototype.bezireToPoly=function(e,i){var r=[];return i&&this.flattenCubicBezier(r,e,i.bezierPoint1,i.bezierPoint2,{x:i.points[1].x,y:i.points[1].y},10),r},t.prototype.flattenCubicBezier=function(e,i,r,s,o,a){var h,l=(z.findLength(i,r)+z.findLength(r,s)+z.findLength(s,o))/a;for(h=0;h<=l;h++){var c=h/l;e.push({x:(1-c)*(1-c)*(1-c)*i.x+3*c*(1-c)*(1-c)*r.x+3*c*c*(1-c)*s.x+c*c*c*o.x,y:(1-c)*(1-c)*(1-c)*i.y+3*c*(1-c)*(1-c)*r.y+3*c*c*(1-c)*s.y+c*c*c*o.y})}},Pe([I("Horizontal")],t.prototype,"orientation",void 0),Pe([re({x:0,y:0},z)],t.prototype,"point1",void 0),Pe([re({x:0,y:0},z)],t.prototype,"point2",void 0),Pe([re({angle:0,distance:0},JI)],t.prototype,"vector1",void 0),Pe([re({angle:0,distance:0},JI)],t.prototype,"vector2",void 0),t}(Pl),bi=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),t.prototype.getClassName=function(){return"OrthogonalSegment"},Pe([I(null)],t.prototype,"length",void 0),Pe([I(null)],t.prototype,"direction",void 0),t}(iF);function rF(n,t,e){var s=e?45:180/(2+2/(n.height/n.width)),o=s,a=180-s,l=a+2*s,h=360-s,c=Gt(t,n.center);return c>o&&ca&&cl&&cMath.abs(t.y-n.y)?n.x=c)return s=z.findAngle(n[parseInt(d.toString(),10)],n[d+1]),{point:r=z.transform(n[parseInt(d.toString(),10)],s,c-(a||0)),index:l=d};a=o[parseInt(d.toString(),10)]}return{point:r,index:l}}(n,t),r=z.findAngle(n[i.index],n[i.index+1]),s=function xse(n){var e=0;switch(n.alignment){case"Center":case"After":e=0;break;case"Before":e=-0}return e}(t),o=z.transform(i.point,r+45,s);return i.point=o,i.angle=r,i}(i,e),h=l.point;s.id=this.id+"_"+e.id;var c=e.style;s.style={fill:c.fill,strokeColor:c.strokeColor,gradient:null,opacity:c.opacity,strokeDashArray:c.strokeDashArray,strokeWidth:c.strokeWidth},0===r.width&&(r.width=this.style.strokeWidth),0===r.height&&(r.height=this.style.strokeWidth);var d_y=(h.y-r.y)/r.height;a.x=r.width*((h.x-r.x)/r.width),a.y=r.height*d_y;var g,v,u=SF(e,l.angle,i),p=u.hAlign,f=u.vAlign;return"left"===p?(g="Left",a.x+=e.displacement.x):"right"===p?(g="Right",a.x-=e.displacement.x):"center"===p&&(g="Center"),"top"===f?(v="Top",a.y+=e.displacement.y):"bottom"===f?(v="Bottom",a.y-=e.displacement.y):"center"===f&&(v="Center"),s.horizontalAlignment=g,s.verticalAlignment=v,(s=sm(s,o&&"Label"!==o.flipMode&&"None"!==o.flipMode?this.flip:"None",e)).float=!0,s.connectionDirection=e.connectionDirection,s.setOffsetWithRespectToBounds(a.x,a.y,"Absolute"),s.relativeMode="Point",s.visible=!(!ga(e,hi.Visible)||ga(e,hi.Hover)||ga(e,hi.Connect)),s.elementActions=s.elementActions|Xr.ElementIsPort,s},t.prototype.getConnectorRelation=function(){var e=this.shape;"Association"===e.relationship?(this.segments[0].type="Straight",this.sourceDecorator.shape="None",this.targetDecorator.shape="Arrow"):"Inheritance"===e.relationship?(this.segments[0].type="Orthogonal",this.sourceDecorator.shape="None",this.targetDecorator.shape="Arrow"):"Composition"===e.relationship||"Aggregation"===e.relationship?(this.segments[0].type="Orthogonal",this.sourceDecorator.shape="Diamond",this.targetDecorator.shape="None"):"Dependency"===e.relationship?(this.segments[0].type="Orthogonal",this.sourceDecorator.shape="None",this.targetDecorator.shape="OpenArrow"):"Realization"===e.relationship&&(this.segments[0].type="Orthogonal",this.sourceDecorator.shape="None",this.targetDecorator.shape="Arrow"),"BiDirectional"===e.associationType&&(this.sourceDecorator.shape="None",this.targetDecorator.shape="None");var i,o,r="",s="";e.multiplicity.source&&(e.multiplicity.source.lowerBounds=e.multiplicity.source.lowerBounds,e.multiplicity.source.upperBounds=e.multiplicity.source.upperBounds),e.multiplicity.target&&(e.multiplicity.target.lowerBounds=e.multiplicity.target.lowerBounds,e.multiplicity.target.upperBounds=e.multiplicity.target.upperBounds);var a=e.multiplicity.source,l=e.multiplicity.target;o=a.upperBounds?a.lowerBounds+"..."+a.upperBounds:a.lowerBounds,i=l.upperBounds?l.lowerBounds+"..."+l.upperBounds:l.lowerBounds,"ManyToOne"===e.multiplicity.type&&(e.multiplicity.target.optional=!1,r=o||"*",s="1"),"OneToMany"===e.multiplicity.type&&(e.multiplicity.source.optional=!1,s=i||"*",r="1"),"ManyToMany"===e.multiplicity.type&&(r=o||"*",s=i||"*"),"OneToOne"===e.multiplicity.type&&(e.multiplicity.target.optional=!1,e.multiplicity.source.optional=!1,r="1",s="1"),this.annotations=[{id:this.id+"sourcelabel",content:r,offset:0,alignment:"Before",margin:{right:5,bottom:5}},{id:this.id+"targetlabel",content:s,offset:1,alignment:"Before",margin:{right:5,bottom:5}}]},t.prototype.getBpmnSequenceFlow=function(){var e=new Ke,i=new Ke;return"Normal"===this.shape.sequence&&"Bezier"!==this.type&&(this.targetDecorator.shape="Arrow"),"Default"===this.shape.sequence&&(e=this.getSegmentElement(this,e),i=DF(this.intermediatePoints,this),this.targetDecorator.shape="Arrow"),"Conditional"===this.shape.sequence&&(this.targetDecorator.shape="Arrow",this.sourceDecorator.shape="Diamond",i.id=this.id+this.shape.type),i},t.prototype.getUMLObjectFlow=function(){if(this.annotations)for(var e=0;e0&&(this.sourcePoint=o[0],this.targetPoint=o[o.length-1]),o},t.prototype.clipDecorator=function(e,i,r,s){var a,l,o={x:0,y:0},h=i.length,c=z.distancePoints(a=r?i[0]:i[h-1],l=r?i[1]:i[h-2]);c=0===c?1:c;var d=1,u=r?e.sourceWrapper:e.targetWrapper;u&&(d=u.style.strokeWidth,s&&s&ee.DecoratorPropertyChange&&(d=1));var p=d-1;return o.x=Math.round(a.x+p*(l.x-a.x)/c),o.y=Math.round(a.y+p*(l.y-a.y)/c),(r&&"None"!==e.sourceDecorator.shape||!r&&"None"!==e.targetDecorator.shape)&&(o=z.adjustPoint(o,l,!0,s&ee.DecoratorPropertyChange?0:d/2)),o},t.prototype.clipDecorators=function(e,i,r){return"None"!==e.sourceDecorator.shape&&(i[0]=this.clipDecorator(e,i,!0,r)),"None"!==e.targetDecorator.shape&&(i[i.length-1]=this.clipDecorator(e,i,!1,r)),i},t.prototype.updateSegmentElement=function(e,i,r,s){var o=new Ne,a=this.getSegmentPath(e,i,s);if("Bezier"===e.type){if(this.segments.length>0)for(var l=0;l0)if("Straight"===e.type&&e.segments.length<2)for(var o=0;o1)for(o=0;o0&&"Bezier"!==this.type)for(var p=0;p0&&(a=p0&&(f<2*this.cornerRadius?(l=z.adjustPoint(h[parseInt(p.toString(),10)],h[p+1],!0,f/2),p0&&(s=this.bridgePath(e,s,p),"Orthogonal"===e.type&&(s=this.bridgePath(e,s,p+1))),s+=" L"+a.x+" "+a.y))}else if("Bezier"===this.type){var g=void 0,v=void 0;if(this.parentObj.element){var y=this.parentObj.element.ej2_instances[0].eventHandler.action;g=this.parentObj.element.ej2_instances[0].eventHandler.tool instanceof Rd,v=y.includes("PortDraw")||y.includes("Drag")}for(var S=void 0,b=this.segments,M=0;M2&&(b[parseInt(M.toString(),10)].bezierPoint1={x:0,y:0},b[parseInt(M.toString(),10)].bezierPoint2={x:0,y:0}),!z.isEmptyPoint(b[parseInt(M.toString(),10)].point1)||b[parseInt(M.toString(),10)].vector1.angle||b[parseInt(M.toString(),10)].vector1.distance?b[parseInt(M.toString(),10)].vector1.angle||b[parseInt(M.toString(),10)].vector1.distance?b[parseInt(M.toString(),10)].bezierPoint1=z.transform(h[parseInt(M.toString(),10)],b[parseInt(M.toString(),10)].vector1.angle,b[parseInt(M.toString(),10)].vector1.distance):b[parseInt(M.toString(),10)].bezierPoint1={x:b[parseInt(M.toString(),10)].point1.x||b[parseInt(M.toString(),10)].bezierPoint1.x,y:b[parseInt(M.toString(),10)].point1.y||b[parseInt(M.toString(),10)].bezierPoint1.y}:((e.sourceID||this.sourcePortID)&&this.sourceWrapper&&!v&&!g&&(S=rF(this.sourceWrapper.bounds,h[parseInt(M.toString(),10)],!0)),b[parseInt(M.toString(),10)].bezierPoint1=eb(h[parseInt(M.toString(),10)],h[M+1],S)),!z.isEmptyPoint(b[parseInt(M.toString(),10)].point2)||b[parseInt(M.toString(),10)].vector2.angle||b[parseInt(M.toString(),10)].vector2.distance?b[parseInt(M.toString(),10)].vector2.angle||b[parseInt(M.toString(),10)].vector2.distance?b[parseInt(M.toString(),10)].bezierPoint2=z.transform(h[M+1],b[parseInt(M.toString(),10)].vector2.angle,b[parseInt(M.toString(),10)].vector2.distance):b[parseInt(M.toString(),10)].bezierPoint2={x:b[parseInt(M.toString(),10)].point2.x||b[parseInt(M.toString(),10)].bezierPoint2.x,y:b[parseInt(M.toString(),10)].point2.y||b[parseInt(M.toString(),10)].bezierPoint2.y}:((e.targetID||this.targetPortID)&&this.targetWrapper&&!v&&!g&&(S=rF(this.targetWrapper.bounds,h[M+1],!0)),b[parseInt(M.toString(),10)].bezierPoint2=eb(h[M+1],h[parseInt(M.toString(),10)],S));h.splice(1,0,{x:b[0].bezierPoint1.x,y:b[0].bezierPoint1.y}),h.splice(h.length-1,0,{x:b[b.length-1].bezierPoint2.x,y:b[b.length-1].bezierPoint2.y}),h=this.clipDecorators(e,h,r);for(var w=0;w0&&(s=this.bridgePath(e,s,D),s+=" L"+o.x+" "+o.y);return s},t.prototype.updateShapeElement=function(e){var i;switch(e.shape.type){case"Bpmn":e.wrapper.children[3]instanceof Ke&&(i=e.wrapper.children[3]),"Message"===e.shape.flow&&this.updateShapePosition(e,i);break;case"UmlActivity":"Exception"===e.shape.flow&&this.getUMLExceptionFlow(e.wrapper.children[0])}},t.prototype.updateShapePosition=function(e,i){var o=xF(this.intermediatePoints,i,.5);i.offsetX=o.x,i.offsetY=o.y},t.prototype.scale=function(e,i,r,s,o){var a=0,l=0;if(this.wrapper&&this.wrapper.outerBounds){var h=function T3(n){var t=n.wrapper.children[0].bounds;return"None"!==n.sourceDecorator.shape&&t.uniteRect(n.wrapper.children[1].bounds),"None"!==n.targetDecorator.shape&&t.uniteRect(n.wrapper.children[2].bounds),t}(this),c=Math.abs((this.wrapper.bounds.width||this.style.strokeWidth||1)-2),d=Math.abs((this.wrapper.bounds.height||this.style.strokeWidth||1)-2);a=h.width-c,l=h.height-d,e=Math.abs((r-Math.max(a,l))/c),i=Math.abs((s-Math.max(a,l))/d),a=l=Math.min(a,l)}e=i=Math.min(e,i);var u=Hi();qi(u,-(o=o||this.wrapper).rotateAngle,o.offsetX,o.offsetY),Xp(u,e,i,o.offsetX,o.offsetY),qi(u,o.rotateAngle,o.offsetX,o.offsetY);var p=function Uie(n,t){for(var e=[],i=0,r=t;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},tse=function(n){function t(e,i){var r=n.call(this,e,i)||this;return r.offset=0,r.scale=1,r}return ese(t,n),t.prototype.preRender=function(){this.unWireEvents(),this.wireEvents()},t.prototype.render=function(){this.updateRulerGeometry(),this.renderComplete()},t.prototype.getModuleName=function(){return"Ruler"},t.prototype.destroy=function(){this.unWireEvents(),this.notify("destroy",{}),n.prototype.destroy.call(this),this.element.classList.remove("e-ruler")},t.prototype.getPersistData=function(){return this.addOnPersist(["loaded"])},t.prototype.onPropertyChanged=function(e,i){for(var r=0,s=Object.keys(e);r100;)r/=10,s/=10;for(;s<25;)r*=10,s*=10;return s>=25&&s%25!=0&&(s=25*Math.round(s/25)),s*e/r},t.prototype.createMarkerLine=function(e,i,r){var s;return i&&((s=e.getElementById(i.id+"_marker"))&&s.parentNode.removeChild(s),s=Bi("line",r)),s},t.prototype.drawRulerMarker=function(e,i,r){var s,o,h,d,u="Horizontal"===this.orientation,p=e.getElementsByTagName("svg");for(h=0;h0)for(var a=i.childNodes.length-1;a>=0;a--)i.childNodes[parseInt(a.toString(),10)].parentNode.removeChild(i.childNodes[parseInt(a.toString(),10)]);i.appendChild(s)}return s},t.prototype.wireEvents=function(){},t.prototype.unWireEvents=function(){},zc([I(5)],t.prototype,"interval",void 0),zc([I(100)],t.prototype,"segmentWidth",void 0),zc([I("Horizontal")],t.prototype,"orientation",void 0),zc([I("RightOrBottom")],t.prototype,"tickAlignment",void 0),zc([I("red")],t.prototype,"markerColor",void 0),zc([I(25)],t.prototype,"thickness",void 0),zc([I(null)],t.prototype,"arrangeTick",void 0),zc([I(400)],t.prototype,"length",void 0),t}(yi);function oF(n,t){var e=document.getElementById(n.element.id+(t?"_hRuler":"_vRuler")),i=qa(n),r=aF(n);e||(e=Tt("div",{id:n.element.id+(t?"_hRuler":"_vRuler"),style:"height:"+(t?i.height:r.height+100)+"px;overflow:hidden;width:"+(t?r.width+100:i.width)+"px;position:absolute;font-size:11px;"+(t?"margin-left:"+i.width+"px;":"margin-top:"+i.height+"px;")})),n.element.insertBefore(e,n.element.firstChild);var l=t?n.rulerSettings.horizontalRuler:n.rulerSettings.verticalRuler,h=new tse(l);h.orientation=t?"Horizontal":"Vertical",h.length=(t?r.width:r.height)+l.segmentWidth,h.appendTo("#"+n.element.id+(t?"_hRuler":"_vRuler")),t?n.hRuler=h:n.vRuler=h;var c=document.getElementById(n.element.id+(t?"_hRuler":"_vRuler"));t?n.hRuler.element=c:n.vRuler.element=c}function tb(n){var t=-n.scroller.horizontalOffset,e=-n.scroller.verticalOffset;n&&n.rulerSettings.showRulers?(n.hRuler.length=0,n.vRuler.length=0,void 0!==t&&n.hRuler.element&&lF(n,n.hRuler,t,!0),void 0!==e&&n.vRuler.element&&lF(n,n.vRuler,e,!1)):$x(n)}function $x(n){an(n.element.id+"_hRuler"),an(n.element.id+"_vRuler"),an(n.element.id+"_overlapRuler")}function qa(n){var t=0,e=0;return n.rulerSettings.showRulers&&(t=n.rulerSettings.horizontalRuler.thickness,e=n.rulerSettings.verticalRuler.thickness),new me(e,t)}function aF(n){var t=qa(n),e=n.scroller.viewPortHeight,i=n.scroller.viewPortWidth;return i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},hF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return ase(t,n),t.prototype.getClassName=function(){return"UserHandle"},Fn([I("")],t.prototype,"name",void 0),Fn([I("")],t.prototype,"pathData",void 0),Fn([I("")],t.prototype,"content",void 0),Fn([I("")],t.prototype,"source",void 0),Fn([I("#000000")],t.prototype,"backgroundColor",void 0),Fn([I("Top")],t.prototype,"side",void 0),Fn([I("")],t.prototype,"borderColor",void 0),Fn([I(.5)],t.prototype,"borderWidth",void 0),Fn([I(25)],t.prototype,"size",void 0),Fn([I("white")],t.prototype,"pathColor",void 0),Fn([I(10)],t.prototype,"displacement",void 0),Fn([I(!0)],t.prototype,"visible",void 0),Fn([I(0)],t.prototype,"offset",void 0),Fn([re({},$n)],t.prototype,"margin",void 0),Fn([I("Center")],t.prototype,"horizontalAlignment",void 0),Fn([I("Center")],t.prototype,"verticalAlignment",void 0),Fn([I(!1)],t.prototype,"disableNodes",void 0),Fn([I(!1)],t.prototype,"disableConnectors",void 0),Fn([re({},Td)],t.prototype,"tooltip",void 0),Fn([I("")],t.prototype,"template",void 0),t}(Ee);function cF(n){return lse[n.toString()]}var lse={Action:"M 90 82.895 C 90 86.819 86.776 90 82.8 90 H 7.2 C 3.224 90 0 86.819 0 82.895 V 7.105 C 0 3.181 3.224 0 7.2 0 h 75.6 C 86.776 0 90 3.181 90 7.105 V 82.895 Z",Decision:"M10,19.707L0.293,10L10,0.293L19.707,10L10,19.707z",MergeNode:"M10,19.707L0.293,10L10,0.293L19.707,10L10,19.707z",InitialNode:"M10,19.5c-5.238,0-9.5-4.262-9.5-9.5S4.762,0.5,10,0.5s9.5,4.262,9.5,9.5S15.238,19.5,10,19.5z",ForkNode:"m0.75,0.75l636.00002,0l0,290l-636.00002,0l0,-290z",JoinNode:"m0.75,0.75l636.00002,0l0,290l-636.00002,0l0,-290z",TimeEvent:"M50.001,0.00286865 L25.001,25.0029 L0.000976562,0.00286865 L50.001,0.00286865 z M0.000976562,50.0029 L25.001,25.0029 L50.001,50.0029 L0.000976562,50.0029 z",AcceptingEvent:"M17.8336 32.164 L29.64 24 L17.32 16 L48.1664 16 L48.5 32 Z",SendSignal:"M48.164 31.8336 L56 23.832 L47.836 16 L16.168 16 L16.1668 31.8336 Z",ReceiveSignal:"M48.1664 31.8336 L39.836 24 L47.836 16 L16.168 16 L16.168 31.836 Z",StructuredNode:"M0,0 L50,0 L50,50 L0,50 z",Note:"M20 12 L4 12 L4 22 L22 22 L22 14 L20 14 L20 12 L22 14 Z"},ib=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),$a=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},hse=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return ib(t,n),$a([I()],t.prototype,"key",void 0),$a([I()],t.prototype,"keyModifiers",void 0),t}(Ee),dF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return ib(t,n),t.prototype.getClassName=function(){return"Command"},$a([I("")],t.prototype,"name",void 0),$a([I()],t.prototype,"canExecute",void 0),$a([I()],t.prototype,"execute",void 0),$a([re({},hse)],t.prototype,"gesture",void 0),$a([I("")],t.prototype,"parameter",void 0),t}(Ee),cse=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return ib(t,n),$a([Bt([],dF)],t.prototype,"commands",void 0),t}(Ee),dse=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return ib(t,n),$a([I()],t.prototype,"show",void 0),$a([I()],t.prototype,"showCustomMenuOnly",void 0),$a([I()],t.prototype,"items",void 0),t}(Ee),Kp=function(){function n(){}return n.prototype.renderShadow=function(t,e,i,r){void 0===i&&(i=null);var l,o=z.transform({x:0,y:0},t.shadow.angle,t.shadow.distance);r&&(l=r.getElementById(e.id+"_shadow")),l||(l=document.createElementNS("http://www.w3.org/2000/svg",i?"path":"rect"),e.appendChild(l));var h={id:e.id+"_shadow",fill:t.shadow.color,stroke:t.shadow.color,opacity:t.shadow.opacity.toString(),transform:"rotate("+t.angle+","+(t.x+t.width*t.pivotX)+","+(t.y+t.height*t.pivotY)+")translate("+(t.x+o.x)+","+(t.y+o.y)+")"};if(r){var c=r.getElementById(e.id);c&&c.insertBefore(l,c.firstChild)}oi(l,h),i?i&&this.renderPath(l,t,i):oi(l,{width:t.width,height:t.height})},n.prototype.parseDashArray=function(t){return[]},n.prototype.drawRectangle=function(t,e,i,r,s,o,a,l,h){var c,d,u,p;e.shadow&&!r&&this.renderShadow(e,t,void 0,o),c=e.id===t.id?e.id+"_container":e.id,o&&(d=o.getElementById(c)),(!d||s)&&(d=document.createElementNS("http://www.w3.org/2000/svg","rect"),t.appendChild(d)),o&&!e.shadow&&(u=o.getElementById(e.id+"_groupElement_shadow"))&&u.parentNode.removeChild(u),p=l?{id:c,x:e.x.toString(),y:e.y.toString(),width:e.width.toString(),height:e.height.toString(),visibility:e.visible?"visible":"hidden",transform:"rotate("+e.angle+","+(e.x+e.width/2)+","+(e.y+e.height/2)+")",rx:e.cornerRadius||0,ry:e.cornerRadius||0,opacity:e.opacity}:{id:c,x:e.x.toString(),y:e.y.toString(),width:e.width.toString(),height:e.height.toString(),visibility:e.visible?"visible":"hidden",transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")",rx:e.cornerRadius||0,ry:e.cornerRadius||0,opacity:e.opacity},a&&(p.role="img",p["aria-label"]=a);var f=e.class||"";h||(f.includes("e-diagram-resize-handle")||f.includes("e-diagram-endpoint-handle")||f.includes("e-diagram-bezier-control-handle"))&&(f+=" e-disabled"),e.class&&(p.class=f),a||(p["pointer-events"]="none"),oi(d,p),this.setSvgStyle(d,e,i)},n.prototype.updateSelectionRegion=function(t,e){var i;i=t.parentNode.getElementById(e.id);var r={id:e.id,x:e.x.toString(),y:e.y.toString(),width:e.width.toString(),height:e.height.toString(),transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")",class:"e-diagram-selected-region"};i||(i=document.createElementNS("http://www.w3.org/2000/svg","rect"),t.appendChild(i)),this.setSvgStyle(i,e),oi(i,r)},n.prototype.createGElement=function(t,e){return Bi(t,e)},n.prototype.drawLine=function(t,e){var i=document.createElementNS("http://www.w3.org/2000/svg","line");this.setSvgStyle(i,e);var r=e.x+e.width*e.pivotX,s=e.y+e.height*e.pivotY,o={id:e.id,x1:e.startPoint.x+e.x,y1:e.startPoint.y+e.y,x2:e.endPoint.x+e.x,y2:e.endPoint.y+e.y,stroke:e.stroke,"stroke-width":e.strokeWidth.toString(),opacity:e.opacity.toString(),transform:"rotate("+e.angle+" "+r+" "+s+")",visibility:e.visible?"visible":"hidden"};e.class&&(o.class=e.class),oi(i,o),t.appendChild(i)},n.prototype.drawCircle=function(t,e,i,r){var s=document.createElementNS("http://www.w3.org/2000/svg","circle");this.setSvgStyle(s,e);var o=e.class||"";i||(o+=" e-disabled");var a={id:e.id,cx:e.centerX,cy:e.centerY,r:e.radius,visibility:e.visible?"visible":"hidden",class:o};r&&(a.role="img",a["aria-label"]=r),s.style.display=e.visible?"block":"none",oi(s,a),t.appendChild(s)},n.prototype.drawPath=function(t,e,i,r,s,o,a){var h,c,l=[];l=e3(l=xd(e.data)),e.shadow&&this.renderShadow(e,t,l,s),s&&!e.shadow&&(h=s.getElementById(e.id+"_groupElement_shadow"))&&h.parentNode.removeChild(h),s&&(c=s.getElementById(e.id)),(!c||r)&&(c=document.createElementNS("http://www.w3.org/2000/svg","path"),t.appendChild(c)),this.renderPath(c,e,l);var d={};d=a?{id:e.id,transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")translate("+e.x+","+e.y+"),scale("+a+")",visibility:e.visible?"visible":"hidden",opacity:e.opacity}:{id:e.id,transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")translate("+e.x+","+e.y+")",visibility:e.visible?"visible":"hidden",opacity:e.opacity},o&&(d.role="img",d["aria-label"]=o),e.class&&(d.class=e.class),oi(c,d),this.setSvgStyle(c,e,i)},n.prototype.renderPath=function(t,e,i){var r,s,o,a,l,h,c,d,u=i,p="";for(l=0,h=0,d=0,c=u.length;de.width&&"Wrap"!==e.textOverflow&&"NoWrap"===e.textWrapping&&(h[0].text=qF(e.content,e)),v=0;vD&&(u.text=u.text.slice(0,u.text.length-3),u.text=u.text.concat("..."),l.data=u.text),this.alignText(y,p,u,l,f,g,v,e,h),C+=u.dy}}C&&e.isHorizontalLane&&(M=e.parentOffsetX+e.pivotX,w=e.parentOffsetY+e.pivotY,e.y=e.parentOffsetY-C*e.pivotY+.5),e.textDecoration&&"LineThrough"===e.textDecoration&&(e.textDecoration=vb(e.textDecoration));var R={id:e.id+"_text",fill:e.color,visibility:e.visible?"visible":"hidden","text-decoration":e.textDecoration,transform:"rotate("+e.angle+","+M+","+w+")translate("+e.x+","+e.y+")",opacity:e.opacity};r&&(R.role="img",R["aria-label"]=r),oi(y,R)}},n.prototype.alignText=function(t,e,i,r,s,o,a,l,h){"justify"!==l.textAlign?this.setText(t,e,i,r,s,o,l):a!==h.length-1?this.setText(t,e,i,r,s,o,l,l.width,"spacing"):this.setText(t,e,i,r,s,o,l)},n.prototype.setText=function(t,e,i,r,s,o,a,l,h){oi(e,"justify"!==a.textAlign?{x:s.toString(),y:o.toString()}:{x:s.toString(),y:o.toString(),textLength:l||0,lengthAdjust:h||"spacing"}),t.setAttribute("fill",i.text),e.appendChild(r),t.appendChild(e)},n.prototype.drawImage=function(t,e,i,r){var s;i&&(s=i.getElementById(e.id+"image")),s||(s=document.createElementNS("http://www.w3.org/2000/svg","image"),t.appendChild(s));var o=new Image;o.src=e.source;var a="None"!==e.scale?e.scale:"",l=e.alignment,h=l.charAt(0).toLowerCase()+l.slice(1);"Stretch"!==a&&(h+=" "+a.charAt(0).toLowerCase()+a.slice(1)),oi(s,{id:e.id+"image",x:e.x.toString(),y:e.y.toString(),transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")",width:e.width.toString(),visibility:e.visible?"visible":"hidden",height:e.height.toString(),preserveAspectRatio:h,opacity:e.opacity.toString()}),s.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",o.src.toString())},n.prototype.drawHTMLContent=function(t,e,i,r,s){var o,a;if(e&&(o=e.querySelector("#"+t.id+"_html_element")),!o){(a=e.querySelector("#"+t.id+"_html_element")||e.querySelector("#"+t.nodeId+"_html_element"))||(a=Tt("div",{id:t.nodeId+"_html_element",class:"foreign-object"})),o=Tt("div",{id:t.id+"_html_element",class:"foreign-object"});var c=document.getElementById(t.diagramId).ej2_instances[0],d=!1;if(e.parentNode&&e.parentNode.parentNode&&e.parentNode.parentNode.parentNode&&e.parentNode.parentNode.parentNode.classList.contains("e-overview")&&(d=!0),d)c.isReact?c.renderReactTemplates(function(){o.appendChild(t.template.cloneNode(!0))}):o.appendChild(t.template.cloneNode(!0));else{if("string"==typeof t.template){var u=document.createElement("div");u.innerHTML=t.template,t.template=u,c.selectedItems.userHandles.filter(function(g){return g.name===t.id.split("_shape")[0]&&""!==g.template})[0].template=t.template}t.isTemplate&&t.template?o.appendChild(t.template):t.template&&o.appendChild(t.template.cloneNode(!0))}void 0!==s&&e.childNodes.length>s&&e.insertBefore(o,e.childNodes[parseInt(s.toString(),10)]),a.appendChild(o),e.appendChild(a)}var f=En(t).topLeft;o.setAttribute("style","height:"+t.actualSize.height+"px; width:"+t.actualSize.width+"px;left:"+f.x+"px; top:"+f.y+"px;position:absolute;transform:rotate("+(t.rotateAngle+t.parentTransform)+"deg);pointer-events:"+(r?"all":"none")+";visibility:"+(t.visible?"visible":"hidden")+";opacity:"+t.style.opacity+";")},n.prototype.drawNativeContent=function(t,e,i,r,s){var o,a;if(s&&(o=s.getElementById(t.id+"_native_element"),a=s.getElementById(t.id+"_clip")),!o){(o=document.createElementNS("http://www.w3.org/2000/svg","g")).setAttribute("id",t.id+"_native_element"),o.appendChild(t.template.cloneNode(!0));var l=this.createGElement("g",{id:t.id+"_inner_native_element"});l.appendChild(o),e.appendChild(l)}a&&o.removeChild(a),o.setAttribute("style","visibility:"+(t.visible?"visible":"hidden")+";opacity:"+t.style.opacity+";"),this.setNativTransform(t,o,i,r),"Slice"===t.scale&&this.drawClipPath(t,o,i,r,s),oi(o,t.description?{role:"img","aria-label":t.description}:{})},n.prototype.setNativTransform=function(t,e,i,r){var s=0!==t.contentSize.width?t.contentSize.width:1,o=0!==t.contentSize.height?t.contentSize.height:1;e.setAttribute("transform","rotate("+t.parentTransform+","+t.offsetX+","+t.offsetY+") translate("+(t.offsetX-t.templatePosition.x*r/s-r*t.pivot.x)+","+(t.offsetY-t.templatePosition.y*i/o-i*t.pivot.y)+") scale("+r/s+","+i/o+")")},n.prototype.drawClipPath=function(t,e,i,r,s){var o=t.contentSize.width,a=t.contentSize.height,l=t.width/(r/o),h=t.height/(i/a),c=t.templatePosition.x+(t.width>=t.height?0:(o-l)/2),d=t.templatePosition.y+(t.height>=t.width?0:(a-h)/2),u=s.getElementById(t.id+"_clip");(u=document.createElementNS("http://www.w3.org/2000/svg","clipPath")).setAttribute("id",t.id+"_clip"),e.appendChild(u);var p=s.getElementById(t.id+"_clip_rect");return p=document.createElementNS("http://www.w3.org/2000/svg","rect"),u.appendChild(p),oi(p,{id:t.id+"_clip_rect",width:l.toString(),height:h.toString(),x:c.toString(),y:d.toString()}),am()?e.setAttribute("clip-path","url("+location.protocol+"//"+location.host+location.pathname+"#"+t.id+"_clip)"):e.setAttribute("clip-path","url(#"+t.id+"_clip)"),e},n.prototype.renderGradient=function(t,e,i){var r,s,o,h,c,a=bT(i),l=a.getElementById(i+"gradient_pattern");if(l||(l=Bi("defs",{id:i+"gradient_pattern"}),a.insertBefore(l,a.firstChild)),bF(e.id),"None"!==t.gradient.type){for(var d=0;dt.width&&("Ellipsis"===t.textOverflow||"Clip"===t.textOverflow)&&"NoWrap"===t.textWrapping?0:.5*t.width:"right"===t.textAlign&&(c=1*t.width),s.x=0+c+(e?e.x:0),s.y=1.2+d-r.height/2,s},n}(),Rc=function(){function n(t,e,i){this.renderer=null,this.isSvgMode=!0,this.transform={x:0,y:0},this.diagramId=t,this.element=xt(this.diagramId),this.svgRenderer=e,this.isSvgMode=i,this.renderer=i?new Kp:new bo}return n.prototype.setCursor=function(t,e){t.style.cursor=e},n.prototype.setLayers=function(){this.iconSvgLayer=this.element.getElementsByClassName("e-ports-expand-layer")[0],this.adornerSvgLayer=this.element.getElementsByClassName("e-adorner-layer")[0],this.nativeSvgLayer=this.element.getElementsByClassName("e-native-layer")[0],this.diagramSvgLayer=this.element.getElementsByClassName("e-diagram-layer")[0]},n.prototype.getAdornerLayer=function(){return ST(this.diagramId)},n.prototype.getParentSvg=function(t,e,i){return this.diagramId&&t&&t.id?t.id.split("_icon_content").length>1||t.id.split("_nodeport").length>1||t.elementActions&Xr.ElementIsPort?this.iconSvgLayer:e&&"selector"===e?this.adornerSvgLayer:t instanceof Cn?this.nativeSvgLayer:this.diagramSvgLayer:i},n.prototype.getParentElement=function(t,e,i,r){var s=e;if(i&&this.diagramId&&t&&t.id){t.id.split("_icon_content").length>1?(s=i.getElementById(this.diagramId+"_diagramExpander"),e=null):t.id.split("_nodeport").length>1?s=i.getElementById(this.diagramId+"_diagramPorts"):t instanceof Cn?(s=i.getElementById(this.diagramId+"_nativeLayer"),e=null):t.elementActions&Xr.ElementIsPort?(s=i.getElementById(this.diagramId+"_diagramPorts"),e=null):s=i.getElementById(this.diagramId+"_diagramLayer");var o=this.getGroupElement(t,e||s,r);s=o.g,o.svg&&(i=o.svg)}return{g:s,svg:i}},n.prototype.getGroupElement=function(t,e,i){var r,o,s=this.getParentSvg(t);if(e&&s){if(s&&!(r=s.getElementById(t.id+"_groupElement"))&&s!==this.nativeSvgLayer){var a=this.nativeSvgLayer;r=a.getElementById(t.id+"_groupElement"),o=a}r||(r=this.svgRenderer.createGElement("g",{id:t.id+"_groupElement"}),void 0!==i&&e.childNodes.length>i?e.insertBefore(r,e.childNodes[parseInt(i.toString(),10)]):e.appendChild(r))}return{g:r,svg:o}},n.prototype.renderElement=function(t,e,i,r,s,o,a,l,h,c,d){t instanceof Cs?(t.id=t.id?t.id:Qe(),this.renderContainer(t,e,i,r,s,o,a,l,h,c,d)):t instanceof DI?this.renderImageElement(t,e,r,s,a):t instanceof Ke?this.renderPathElement(t,e,r,s,a,h,d):t instanceof ni?this.renderTextElement(t,e,r,s,a,c):t instanceof Cn?this.renderNativeElement(t,e,r,s,a):t instanceof Jn?this.renderHTMLElement(t,e,i,r,s,a,l):this.renderRect(t,e,r,s,h)},n.prototype.drawSelectionRectangle=function(t,e,i,r,s,o){var a={width:i*o.scale,height:r*o.scale,x:.5+(t=(t+o.tx)*o.scale),y:.5+(e=(e+o.ty)*o.scale),fill:"transparent",stroke:"gray",angle:0,pivotX:.5,pivotY:.5,strokeWidth:1,dashArray:"6 3",opacity:1,visible:!0,id:s.id+"_selected_region"},l=this.getAdornerLayer();this.svgRenderer.updateSelectionRegion(l,a)},n.prototype.renderHighlighter=function(t,e,i){var r=t.actualSize.width||2,s=t.actualSize.height||2,o=t.offsetX-r*t.pivot.x,a=t.offsetY-s*t.pivot.y;this.svgRenderer.drawRectangle(e,{width:r*i.scale,height:s*i.scale,x:o=(o+i.tx)*i.scale,y:a=(a+i.ty)*i.scale,fill:"transparent",stroke:"#8CC63F",angle:t.rotateAngle,pivotX:t.pivot.x,pivotY:t.pivot.y,strokeWidth:4,dashArray:"",opacity:1,cornerRadius:0,visible:!0,id:e.id+"_highlighter",class:"e-diagram-highlighter"},this.diagramId,void 0,void 0,e)},n.prototype.renderSelectionRectangle=function(t,e,i,r){var s=t.actualSize.width||2,o=t.actualSize.height||2,a=t.offsetX-s*t.pivot.x,l=t.offsetY-o*t.pivot.y,h={width:s*i.scale,height:o*i.scale,x:a=(a+i.tx)*i.scale,y:l=(l+i.ty)*i.scale,fill:"transparent",stroke:"#00cc00",angle:t.rotateAngle,pivotX:t.pivot.x,pivotY:t.pivot.y,strokeWidth:r?2:1,dashArray:"",opacity:1,cornerRadius:0,visible:!0,id:t.id+"_highlighter",class:r?"e-diagram-first-selection-indicator e-diagram-selection-indicator":"e-diagram-selection-indicator"},c=this.getParentSvg(t,"selector");this.svgRenderer.drawRectangle(e,h,this.diagramId,void 0,void 0,c)},n.prototype.renderSelectionLine=function(t,e,i,r){var s=this.getBaseAttributes(t,i);s.data=t.absolutePath,s.id=s.id+"_highlighter";var o=t.description?t.description:t.id;this.isSvgMode||(s.x=t.flipOffset.x?t.flipOffset.x:s.x,s.y=t.flipOffset.y?t.flipOffset.y:s.y),i&&(s.x=s.x*i.scale,s.y=s.y*i.scale),s.stroke="#00cc00",s.strokeWidth=r?2:1,s.class=r?"e-diagram-first-selection-indicator e-diagram-selection-indicator":"e-diagram-selection-indicator";var a=this.getParentSvg(t,"selector");this.svgRenderer.drawPath(e,s,this.diagramId,void 0,a,o,i.scale)},n.prototype.renderStackHighlighter=function(t,e,i,r,s,o,a){var l=t.actualSize.width||2,h=t.offsetX-l*t.pivot.x,c=t.actualSize.height||2,d=t.offsetY-c*t.pivot.y;h=(h+i.tx)*i.scale;var u,p=t.bounds,f="";if(d=(d+i.ty)*i.scale,r)if(o){var v,y;u="M 0 0 L "+(2+(g=l*i.scale))+" 0 Z",v=t.actualSize.width/Number(p.width?p.width:1)*i.scale,y=t.actualSize.height/Number(p.height?p.height:1)*i.scale,f=bI(MI(xd("M7,4 L8,4 8,7 11,7 11,8 8,8 8,11 7,11 7,8 4,8 4,7 7,7 z M7.5,0.99999994C3.9160004,1 1,3.9160004 0.99999994,7.5 1,11.084 3.9160004,14 7.5,14 11.084,14 14,11.084 14,7.5 14,3.9160004 11.084,1 7.5,0.99999994 z M7.5,0 C11.636002,0 15,3.3639984 15,7.5 15,11.636002 11.636002,15 7.5,15 3.3640003,15 0,11.636002 0,7.5 0,3.3639984 3.3640003,0 7.5,0 z")),v+g+2,y-8,!1,p.x,p.y,0,0),s.y>=t.offsetY&&(d+=c)}else{var g;a&&s.y>=t.offsetY&&(d+=c*i.scale),u="M -10 -10 L 0 0 Z M -10 10 L 0 0 Z M 0 0 L "+(g=l*i.scale)+" 0 Z M "+g+" 0 L "+(g+10)+" 10 Z L "+(g+10)+" -10 Z"}else u="M 10 -10 L 0 0 Z M -10 -10 L 0 0 Z M 0 0 L 0 "+(g=c*i.scale)+" Z M 0 "+g+" L -10 "+(g+10)+" Z L 10 "+(g+10)+" Z",s.x>=t.offsetX&&(h+=l*i.scale);this.svgRenderer.drawPath(e,{data:u+f,width:l*i.scale,height:c*i.scale,x:h,y:d,fill:"transparent",stroke:"#8CC63F",angle:t.rotateAngle,pivotX:t.pivot.x,pivotY:t.pivot.y,strokeWidth:1,dashArray:"",opacity:1,visible:!0,id:e.id+"_stack_highlighter",class:"e-diagram-highlighter"},this.diagramId)},n.prototype.drawLine=function(t,e){this.svgRenderer.drawLine(t,e)},n.prototype.drawPath=function(t,e){this.svgRenderer.drawPath(t,e,this.diagramId)},n.prototype.renderResizeHandle=function(t,e,i,r,s,o,a,l,h,c,d){var u=t.offsetX-t.actualSize.width*t.pivot.x,p=t.offsetY-t.actualSize.height*t.pivot.y,f=t.actualSize.height,g=t.actualSize.width;!c&&i&bt.Rotate&&jI(this.rendererActions)&&!z3(this.rendererActions)&&(this.renderPivotLine(t,e,o,s,a),this.renderRotateThumb(t,e,o,s,a)),this.renderBorder(t,e,o,l,h,c);var v=t.actualSize.width*r,y=t.actualSize.height*r;!h&&jI(this.rendererActions)&&!z3(this.rendererActions)&&(t.isTextAnnotation||(v>=40&&y>=40&&(s&mr.ResizeNorthWest&&this.renderCircularHandle("resizeNorthWest",t,u,p,e,qr(s,"ResizeNorthWest"),i&bt.ResizeNorthWest,o,void 0,a,{"aria-label":"Thumb to resize the selected object on top left side direction"},void 0,"e-diagram-resize-handle e-northwest",d),s&mr.ResizeNorthEast&&this.renderCircularHandle("resizeNorthEast",t,u+g,p,e,qr(s,"ResizeNorthEast"),i&bt.ResizeNorthEast,o,void 0,a,{"aria-label":"Thumb to resize the selected object on top right side direction"},void 0,"e-diagram-resize-handle e-northeast",d),s&mr.ResizeSouthWest&&this.renderCircularHandle("resizeSouthWest",t,u,p+f,e,qr(s,"ResizeSouthWest"),i&bt.ResizeSouthWest,o,void 0,a,{"aria-label":"Thumb to resize the selected object on bottom left side direction"},void 0,"e-diagram-resize-handle e-southwest",d),s&mr.ResizeSouthEast&&this.renderCircularHandle("resizeSouthEast",t,u+g,p+f,e,qr(s,"ResizeSouthEast"),i&bt.ResizeSouthEast,o,void 0,a,{"aria-label":"Thumb to resize the selected object on bottom right side direction"},void 0,"e-diagram-resize-handle e-southeast",d)),s&mr.ResizeNorth&&this.renderCircularHandle("resizeNorth",t,u+g/2,p,e,qr(s,"ResizeNorth"),i&bt.ResizeNorth,o,void 0,a,{"aria-label":"Thumb to resize the selected object on top side direction"},void 0,"e-diagram-resize-handle e-north",d),s&mr.ResizeSouth&&this.renderCircularHandle("resizeSouth",t,u+g/2,p+f,e,qr(s,"ResizeSouth"),i&bt.ResizeSouth,o,void 0,a,{"aria-label":"Thumb to resize the selected object on bottom side direction"},void 0,"e-diagram-resize-handle e-south",d),s&mr.ResizeWest&&this.renderCircularHandle("resizeWest",t,u,p+f/2,e,qr(s,"ResizeWest"),i&bt.ResizeWest,o,void 0,a,{"aria-label":"Thumb to resize the selected object on left side direction"},void 0,"e-diagram-resize-handle e-west",d),s&mr.ResizeEast&&this.renderCircularHandle("resizeEast",t,u+g,p+f/2,e,qr(s,"ResizeEast"),i&bt.ResizeEast,o,void 0,a,{"aria-label":"Thumb to resize the selected object on right side direction"},void 0,"e-diagram-resize-handle e-east",d)))},n.prototype.renderEndPointHandle=function(t,e,i,r,s,o,a,l,h,c){var f,g,d=t.sourcePoint,u=t.targetPoint,p=t.wrapper;if(this.renderCircularHandle("connectorSourceThumb",p,d.x,d.y,e,qr(r,"ConnectorSourceThumb"),i&bt.ConnectorSource,s,o,void 0,{"aria-label":"Thumb to move the source point of the connector"},void 0,"e-diagram-endpoint-handle e-sourceend",c),this.renderCircularHandle("connectorTargetThumb",p,u.x,u.y,e,qr(r,"ConnectorTargetThumb"),i&bt.ConnectorTarget,s,a,void 0,{"aria-label":"Thumb to move the target point of the connector"},void 0,"e-diagram-endpoint-handle e-targetend",c),l)if("Straight"===t.type&&t.segments.length>0)for(f=0;f0)for(f=0;f=3&&3===t.segments.length&&(S=1,b=t.segments.length-1),S=t.segments.length>t.maxSegmentThumb+2?2:S,b=t.segments.length>t.maxSegmentThumb+2?t.segments.length-2:b,1===t.segments.length&&t.segments[0].points.length<=2&&(S=1,b=t.segments.length),f=S;f=50&&i.allowDrag),this.renderOrthogonalThumb(t+"_"+(d+1),e,(i.points[parseInt(d.toString(),10)].x+i.points[d+1].x)/2,(i.points[parseInt(d.toString(),10)].y+i.points[d+1].y)/2,r,h,l,o,a,u)}else for(d=0;d=50&&i.allowDrag),this.renderOrthogonalThumb(t+"_"+(d+1),e,(i.points[parseInt(d.toString(),10)].x+i.points[d+1].x)/2,(i.points[parseInt(d.toString(),10)].y+i.points[d+1].y)/2,r,h,l,o,a,u)},n.prototype.renderOrthogonalThumb=function(t,e,i,r,s,o,a,l,h,c){var d,g,u=0,p=document.getElementById(this.diagramId);p&&(g=p.ej2_instances[0]);var y=h.constraints&qe.InheritSegmentThumbShape?g.segmentThumbShape:h.segmentThumbShape,b=h.constraints&qe.InheritSegmentThumbSize?g.segmentThumbSize:h.segmentThumbSize;if(d="horizontal"===a?function ure(n){return vre[""+n]}(y):c3(y),"Arrow"===y||"DoubleArrow"===y||"OpenArrow"===y)switch(c){case"Bottom":case"Right":u=180;break;default:u=0}else if("Fletch"===y||"OpenFetch"===y||"IndentedArrow"===y||"OutdentedArrow"===y)switch(c){case"Bottom":u=-90;break;case"Top":u=90;break;case"Right":u=180;break;default:u=0}var M={x:(i+l.tx)*l.scale-b/2,y:(r+l.ty)*l.scale-b/2,angle:u,fill:"#e2e2e2",stroke:"black",strokeWidth:1,dashArray:"",data:d,width:b,height:b,pivotX:.5,pivotY:.5,opacity:1,visible:o,id:t,class:"e-diagram-ortho-segment-handle"},w=lf(M.data),C=new me(M.width,M.height),D=new Ke;M.data=D.updatePath(M.data,w,C),this.svgRenderer.drawPath(s,M,this.diagramId)},n.prototype.renderPivotLine=function(t,e,i,r,s){var o=t,l=!!(r&mr.Rotate);s&&(l=!1);var h=this.getBaseAttributes(o,i);h.fill="None",h.stroke="black",h.strokeWidth=1,h.dashArray="2,3",h.visible=l;var c=i.scale;h.x*=c,h.y*=c,h.width*=c,h.height*=c,h.id="pivotLine",h.class="e-diagram-pivot-line";var u={x:o.actualSize.width*o.pivot.x*c,y:0};h.startPoint={x:o.actualSize.width*o.pivot.x*c,y:-20},h.endPoint=u,this.svgRenderer.drawLine(e,h)},n.prototype.renderBezierLine=function(t,e,i,r,s,o){var l=this.getBaseAttributes(e,o);l.id=t,l.stroke="black",l.strokeWidth=1,l.dashArray="3,3",l.fill="None",l.class="e-diagram-bezier-control-line",l.x=0,l.y=0;var h=o.scale,g={x:(s.x+o.tx)*h,y:(s.y+o.ty)*h};l.startPoint={x:(r.x+o.tx)*h,y:(r.y+o.ty)*h},l.endPoint=g,this.svgRenderer.drawLine(i,l)},n.prototype.renderCircularHandle=function(t,e,i,r,s,o,a,l,h,c,d,u,p,f){var g=e,v={x:i,y:r};if(0!==g.rotateAngle||0!==g.parentTransform){var y=Hi();qi(y,g.rotateAngle+g.parentTransform,g.offsetX,g.offsetY),v=Je(y,v)}var S=this.getBaseAttributes(g);S.stroke="black",S.strokeWidth=1,void 0!==u?(S.id="segmentEnd_"+u,S.fill="#e2e2e2"):S.fill=h?"#8CC63F":"white",S.cornerRadius=f/2,S.angle=e.rotateAngle,S.id=t,S.visible=o,S.class=p,S.width=f,S.height=f,S.x=(v.x+l.tx)*l.scale,S.y=(v.y+l.ty)*l.scale,S.x=S.x-S.width/2,S.y=S.y-S.height/2,h&&(S.class+=" e-connected"),c&&(S.visible=!1);var b=this.getParentSvg(e,"selector");this.svgRenderer.drawRectangle(s,S,this.diagramId,!0,!0,b,d,!0,a)},n.prototype.renderBezierHandle=function(t,e,i,r,s,o,a,l,h,c,d,u,p){var v,f=document.getElementById(this.diagramId);f&&(v=f.ej2_instances[0]);var y=e,S={x:i,y:r};if(0!==y.rotateAngle||0!==y.parentTransform){var b=Hi();qi(b,y.rotateAngle+y.parentTransform,y.offsetX,y.offsetY),S=Je(b,S)}var D=a.constraints&qe.InheritSegmentThumbSize?v.segmentThumbSize:a.segmentThumbSize,A=c3(a.constraints&qe.InheritSegmentThumbShape?v.segmentThumbShape:a.segmentThumbShape),x=this.getBaseAttributes(y);x.stroke="black",x.strokeWidth=1,void 0!==d?(x.id="segmentEnd_"+d,x.fill="#e2e2e2"):x.fill=h?"#8CC63F":"white",x.angle=e.rotateAngle,x.id=t,x.visible=o,x.class=u,x.width=D,x.height=D,x.data=A,x.x=(S.x+l.tx)*l.scale,x.y=(S.y+l.ty)*l.scale,x.x=x.x-x.width/2,x.y=x.y-x.height/2,h&&(x.class+=" e-connected"),c&&(x.visible=!1);var R=lf(x.data),L=new me(x.width,x.height),O=new Ke;x.data=O.updatePath(x.data,R,L);var N=this.getParentSvg(e,"selector");this.svgRenderer.drawPath(s,x,this.diagramId,!0,N)},n.prototype.renderBorder=function(t,e,i,r,s,o){var l=this.getBaseAttributes(t,i);l.x*=i.scale,l.y*=i.scale,l.width*=i.scale,l.height*=i.scale,l.fill="transparent",l.stroke="#097F7F",l.strokeWidth=1.2,l.gradient=null,l.dashArray="6,3",l.class="e-diagram-selector",o&&(l.class+=" e-diagram-lane"),l.id="borderRect",l.id=this.rendererActions&Qa.DrawSelectorBorder?"borderRect_symbol":"borderRect",r||(l.class+=" e-disabled"),s&&(l.class+=" e-thick-border"),l.cornerRadius=0;var h=this.getParentSvg(t,"selector");this.svgRenderer.drawRectangle(e,l,this.diagramId,void 0,!0,h)},n.prototype.renderUserHandler=function(t,e,i,r,s,o){for(var l,a=t.wrapper,h=0,c=t.userHandles;h0||d.disableNodes&&t.nodes.length>0||"Drag"===s&&o)&&(l=!1);var u=document.getElementById(d.name+"_template_hiddenUserHandle");u&&(d.template=u.childNodes[0].cloneNode(!0));var p=rT(t,d,i);if(p.x=(p.x+i.tx)*i.scale,p.y=(p.y+i.ty)*i.scale,d.visible&&(d.visible=!!(t.constraints&mr.UserHandle)),l)if(d.pathData){var f=d.pathData?d.pathData:d.content,g=this.getBaseAttributes(a);g.id=d.name+"_userhandle",g.fill=d.backgroundColor,g.stroke=d.borderColor,g.strokeWidth=d.borderWidth,g.centerX=p.x,g.centerY=p.y,g.radius=.5*d.size,g.class="e-diagram-userhandle-circle",g.angle=0,g.visible=d.visible,g.opacity=1,this.svgRenderer.drawCircle(e,g,1,{"aria-label":d.name+"user handle"});var y=[];y=MI(y=xd(f));var S=lf(f),w=bI(y,(d.size-.45*d.size)/S.width,(d.size-.45*d.size)/S.height,!0,S.x,S.y,0,0);S=lf(w),this.svgRenderer.drawPath(e,C={x:p.x-S.width/2,y:p.y-S.height/2,angle:0,id:"",class:"e-diagram-userhandle-path",fill:d.pathColor,stroke:d.backgroundColor,strokeWidth:.5,dashArray:"",data:w,width:d.size-5,height:d.size-5,pivotX:0,pivotY:0,opacity:1,visible:d.visible},this.diagramId,void 0,void 0,{"aria-label":d.name+"user handle"})}else if(d.content){var D=new Cn(d.name,this.diagramId);D.content=d.content,D.offsetX=p.x,D.offsetY=p.y,D.id=d.name+"_shape",D.horizontalAlignment="Center",D.verticalAlignment="Center",D.visible=d.visible,D.setOffsetWithRespectToBounds(p.x,p.y,"Fraction"),D.relativeMode="Object",D.description=d.name||"User handle",D.measure(new me(d.size,d.size)),D.arrange(D.desiredSize),this.svgRenderer.drawNativeContent(D,e,d.size,d.size,this.adornerSvgLayer)}else if(d.source){var C,A=new DI;(C=this.getBaseAttributes(A,i)).width=d.size,C.height=d.size,C.x=p.x-d.size/2,C.y=p.y-d.size/2,C.sourceWidth=d.size,C.sourceHeight=d.size,C.alignment=A.imageAlign,C.source=d.source,C.scale=A.imageScale,C.visible=d.visible,C.description=d.name||"User handle",C.id=d.name+"_",this.renderer.drawImage(e,C,this.adornerSvgLayer,!1)}else{var x=new Jn(d.name,this.diagramId);x.offsetX=p.x,x.offsetY=p.y,x.id=d.name+"_shape",x.visible=d.visible,x.relativeMode="Object",x.template=d.template,x.measure(new me(d.size,d.size)),x.arrange(x.desiredSize),this.svgRenderer.drawHTMLContent(x,r,void 0,!0,void 0)}}},n.prototype.renderRotateThumb=function(t,e,i,r,s){new Ke;var a,l=new me;l.width=18,l.height=16;var d=!!(r&mr.Rotate);s&&(d=!1);var p=t.offsetX-t.actualSize.width*t.pivot.x+t.pivot.x*t.actualSize.width,f=t.offsetY-t.actualSize.height*t.pivot.y;if(a={x:(p=(p+i.tx)*i.scale)-.5*l.width,y:(f=(f+i.ty)*i.scale)-30-.5*l.height},0!==t.rotateAngle||0!==t.parentTransform){var g=Hi();qi(g,t.rotateAngle+t.parentTransform,(i.tx+t.offsetX)*i.scale,(i.ty+t.offsetY)*i.scale),a=Je(g,a)}this.svgRenderer.drawPath(e,{x:a.x,y:a.y,angle:t.rotateAngle+t.parentTransform,fill:"#231f20",stroke:"black",strokeWidth:.5,dashArray:"",data:"M 16.856144362449648 10.238890446662904 L 18.000144362449646 3.437890446662903L 15.811144362449646 4.254890446662903 C 14.837144362449646 2.5608904466629028 13.329144362449647 1.2598904466629026 11.485144362449645 0.5588904466629026 C 9.375144362449646 - 0.24510955333709716 7.071144362449646 - 0.18010955333709716 5.010144362449646 0.7438904466629028 C 2.942144362449646 1.6678904466629028 1.365144362449646 3.341890446662903 0.558144362449646 5.452890446662903 C - 0.244855637550354 7.567890446662903 - 0.17985563755035394 9.866890446662904 0.7431443624496461 11.930890446662904 C 1.6681443624496461 13.994890446662904 3.343144362449646 15.575890446662903 5.457144362449647 16.380890446662903 C 6.426144362449647 16.7518904466629 7.450144362449647 16.9348904466629 8.470144362449647 16.9348904466629 C 9.815144362449647 16.9348904466629 11.155144362449647 16.6178904466629 12.367144362449647 15.986890446662901 L 11.351144362449647 14.024890446662901 C 9.767144362449647 14.8468904466629 7.906144362449647 14.953890446662902 6.237144362449647 14.3178904466629 C 4.677144362449647 13.7218904466629 3.444144362449647 12.5558904466629 2.758144362449647 11.028890446662901 C 2.078144362449646 9.501890446662903 2.031144362449646 7.802890446662903 2.622144362449646 6.243890446662903 C 3.216144362449646 4.6798904466629025 4.387144362449646 3.442890446662903 5.914144362449646 2.760890446662903 C 7.437144362449646 2.078890446662903 9.137144362449646 2.0298904466629026 10.700144362449645 2.6258904466629027 C 11.946144362449646 3.100890446662903 12.971144362449646 3.9538904466629026 13.686144362449646 5.049890446662903 L 11.540144362449645 5.850890446662903 L 16.856144362449648 10.238890446662904 Z",width:20,height:20,pivotX:0,pivotY:0,opacity:1,visible:d,id:"rotateThumb",class:"e-diagram-rotate-handle"},this.diagramId,!0,void 0,{"aria-label":"Thumb to rotate the selected object"})},n.prototype.renderPathElement=function(t,e,i,r,s,o,a){var l=this.getBaseAttributes(t,i,o);if(l.data=t.absolutePath,l.data=t.absolutePath,t.isPathPort&&a){l.x=a[t.id]?a[t.id].cx:l.x,l.y=a[t.id]?a[t.id].cy:l.y,t.bounds.x=l.x,t.bounds.y=l.y;var h=document.getElementById(this.diagramId);h&&"PortDrag"!==h.ej2_instances[0].eventHandler.currentAction&&(t.offsetX=l.x+t.width/2,t.offsetY=l.y+t.height/2)}var u=t.description?t.description:t.id;if(this.isSvgMode||(l.x=t.flipOffset.x?t.flipOffset.x:l.x,l.y=t.flipOffset.y?t.flipOffset.y:l.y),t.isExport){var p=t.absoluteBounds,f=xd(l.data),g=this.findAndStoreArcValues(f);l.arc=g,l.data=BF(t,p,0,l)}this.renderer.drawPath(e,l,this.diagramId,void 0,r,u)},n.prototype.findAndStoreArcValues=function(t){var e=[];return t.forEach(function(i){"A"===i.command&&e.push({r1:i.r1/2,r2:i.r2/2})}),e},n.prototype.renderSvgGridlines=function(t,e,i,r,s,o){var a=document.createElementNS("http://www.w3.org/2000/svg","pattern"),l=document.createElementNS("http://www.w3.org/2000/svg","defs");l.setAttribute("id",this.diagramId+"_grid_pattern_defn"),(t.constraints&Kt.ShowHorizontalLines||t.constraints&Kt.ShowVerticalLines)&&a.setAttribute("id",this.diagramId+"_pattern");var h=0,c=0,d=0,u=0,p=1,f=!1,g="Lines"===t.gridType,v=g?t.verticalGridlines.lineIntervals:t.verticalGridlines.dotIntervals,y=g?t.horizontalGridlines.lineIntervals:t.horizontalGridlines.dotIntervals;if(r.showRulers&&r.dynamicGrid&&s&&o)d=o.updateSegmentWidth(i.scale),u=s.updateSegmentWidth(i.scale),t.horizontalGridlines.scaledIntervals=[d/s.interval],t.verticalGridlines.scaledIntervals=[u/o.interval],f=!0;else{for(var S=0;S=2)for(;e>=2;)e/=2;else if(e<=.5)for(;e<=.5;)e*=2;var i;if(t.horizontalGridlines.scaledIntervals=t.horizontalGridlines.snapIntervals,t.verticalGridlines.scaledIntervals=t.verticalGridlines.snapIntervals,1!==e){var r=t.horizontalGridlines;for(r.scaledIntervals=[],i=0;ithis.groupElement.actualSize.height&&("Clip"===t.style.textOverflow||"Ellipsis"===t.style.textOverflow)&&(a.y=a.y+(a.height-this.groupElement.actualSize.height)/2),this.renderer.drawRectangle(e,a,this.diagramId,void 0,void 0,r),this.renderer.drawText(e,a,r,l,this.diagramId,t.isExport&&Math.min(t.exportScaleValue.x||t.exportScaleValue.y),this.groupElement),this.isSvgMode&&(t.doWrap=!1)},n.prototype.renderNativeElement=function(t,e,i,r,s){var o,a,l=this.getParentSvg(t,void 0,e)||r,h=this.getParentElement(t,e,l).g||e,c=this.getBaseAttributes(t,i);switch(c.fill="transparent",c.cornerRadius=t.cornerRadius,c.stroke="transparent",this.renderer.drawRectangle(e,c,this.diagramId,void 0,void 0,r),t.scale){case"None":o=t.contentSize.width,a=t.contentSize.height;break;case"Stretch":o=t.actualSize.width,a=t.actualSize.height;break;case"Meet":o=a=t.actualSize.width<=t.actualSize.height?t.actualSize.width:t.actualSize.height;break;case"Slice":o=a=t.actualSize.width>=t.actualSize.height?t.actualSize.width:t.actualSize.height}this.svgRenderer&&this.svgRenderer.drawNativeContent(t,h,a,o,l)},n.prototype.renderHTMLElement=function(t,e,i,r,s,o,a){var l=this.getBaseAttributes(t,r);l.fill="transparent",l.cornerRadius=t.cornerRadius,l.stroke="transparent",this.renderer.drawRectangle(e,l,this.diagramId,void 0,void 0,s),this.svgRenderer&&this.svgRenderer.drawHTMLContent(t,i.children[0],r,function Sse(n){var t=n.parentElement;do{if(fm(t,"e-diagram"))return!0;t=t.parentElement}while(t);return!1}(i),a)},n.prototype.renderImageElement=function(t,e,i,r,s){var o=this.getBaseAttributes(t,i);o.cornerRadius=0,this.renderer.drawRectangle(e,o,this.diagramId,void 0,void 0,r);var a,l,h,c,g,d=t.contentSize.width,u=t.contentSize.height,p=o.width/d,f=o.height/u;if("Stretch"===t.stretch)a=d*(g=Math.min(p,f)),l=u*g;else switch(t.stretch){case"Meet":a=d*(g=Math.min(p,f)),l=u*g,o.x+=Math.abs(o.width-a)/2,o.y+=Math.abs(o.height-l)/2;break;case"Slice":g=Math.max(p,f),h=o.width/(a=d*g)*d,c=o.height/(l=u*g)*u;break;case"None":a=d,l=u}o.width=a,o.height=l,o.sourceWidth=h,o.sourceHeight=c,o.source=t.source,o.alignment=t.imageAlign,o.scale=t.imageScale,o.description=t.description?t.description:t.id,this.renderer.drawImage(e,o,r,s)},n.prototype.renderContainer=function(t,e,i,r,s,o,a,l,h,c,d){var g,u={svg:s,g:e},p=document.getElementById(this.diagramId);if(p&&(g=p.ej2_instances[0]),this.diagramId&&(s=this.getParentSvg(t)||s,this.isSvgMode)){var v=this.getParentElement(t,e,s,l).g||e;s=this.getParentSvg(this.hasNativeParent(t.children))||s;var y=this.getParentElement(this.hasNativeParent(t.children),v,s,l);u.svg=y.svg||s,u.g=y.g||v,o&&s&&(s.getElementById(u.g.id)||e.appendChild(u.g)),e=u.g}if(this.renderRect(t,e,r,s),this.groupElement=t,t.hasChildren()){for(var b,S=void 0,M=0,w=t.children;M0&&(D=g.selectedItems.nodes[0]);var L,A=void 0,x=void 0,R=!1;if(g&&g.selectedItems&&(L=g.getObject(t.id)),"None"!==t.flip&&(D=L),"None"===t.flip&&(D=L),D&&D.flipMode&&(R=!0),!(t.elementActions&Xr.ElementIsGroup)&&g instanceof Rl&&g.nameTable[t.id]&&"connectors"!==g.nameTable[t.id].propName&&R&&D){if(A=t.children&&t.children[0]instanceof Cn?document.getElementById(D.id+"_content_inner_native_element"):document.getElementById(D.id+"_content_groupElement"),!(t.children[0]instanceof Cn)&&"Text"!==D.shape.type&&"None"!==D.flipMode&&"Label"!==D.flipMode&&"All"!==D.flipMode&&"PortAndLabel"!==D.flipMode&&"LabelText"!==D.flipMode&&"PortAndLabelText"!==D.flipMode&&"LabelAndLabelText"!==D.flipMode||t.children[0]instanceof Cn&&"Port"===D.flipMode)return void this.renderFlipElement(t,A,D.flip);if((t.children[0]instanceof Cn&&("All"===D.flipMode||"Label"===D.flipMode)||"Label"===D.flipMode||"PortAndLabel"===D.flipMode||"LabelText"===D.flipMode||"PortAndLabelText"===D.flipMode||"LabelAndLabelText"===D.flipMode||"Image"===D.shape.type&&"Label"===D.flipMode)&&this.renderFlipElement(t,A,t.flip),"None"!==t.flip&&"None"===D.flipMode)this.renderFlipElement(t,A,t.flip);else if("None"!==t.flip&&("Label"===D.flipMode||"PortAndLabel"===D.flipMode||"LabelText"===D.flipMode||"PortAndLabelText"===D.flipMode||"LabelAndLabelText"===D.flipMode)||t.children[0]instanceof Cn&&"None"!==t.flip&&D&&("None"===D.flipMode||"All"===D.flipMode)){for(var O=0;O0){var i=t[0];if(i instanceof Cn)return i;i.children&&i.children.length&&this.hasNativeParent(i.children,e++||0)}},n.prototype.renderRect=function(t,e,i,r,s){var o=this.getBaseAttributes(t,i,s);o.cornerRadius=t.cornerRadius||0,t.isExport&&(o.cornerRadius*=t.exportScaleValue.x),this.renderer.drawRectangle(e,o,this.diagramId,t.isExport,void 0,r,t.description?t.description:t.id)},n.prototype.drawRect=function(t,e){e.cornerRadius=0,this.svgRenderer.drawRectangle(t,e,this.diagramId)},n.prototype.getBaseAttributes=function(t,e,i){var r={width:t.actualSize.width,height:t.actualSize.height,x:t.offsetX-t.actualSize.width*t.pivot.x,y:t.offsetY-t.actualSize.height*t.pivot.y,fill:t.style.fill,stroke:t.style.strokeColor,angle:t.rotateAngle+t.parentTransform,pivotX:t.pivot.x,pivotY:t.pivot.y,strokeWidth:t.style.strokeWidth,dashArray:t.style.strokeDashArray||"",opacity:t.style.opacity,shadow:t.shadow,gradient:t.style.gradient,visible:t.visible,id:t.id,description:t.description,canApplyStyle:t.canApplyStyle,shapeType:t.shapeType};return"Page"===t.rotationReference&&(r.angle=t.rotateAngle),i&&(r.x=r.x-.5,r.y=r.y-.5),t.isExport&&(r.width*=t.exportScaleValue.x,r.height*=t.exportScaleValue.y,r.x*=t.exportScaleValue.x,r.y*=t.exportScaleValue.y,r.strokeWidth*=t.exportScaleValue.x),t.flip&&(r.flip=t.flip),e&&(r.x+=e.tx,r.y+=e.ty),r},n.renderSvgBackGroundImage=function(t,e,i,r,s,o){if(t.source){var l=bT(e.id).getElementById(e.id+"_image");if(!l){var h=function Toe(n){return xt(n).getElementsByClassName("e-background-image-layer")[0]}(e.id);(l=document.createElementNS("http://www.w3.org/2000/svg","image")).setAttribute("id",e.id+"_image"),h.appendChild(l)}var c=new Image;c.src=t.source,l.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",c.src.toString());var d="None"!==t.scale?t.scale:"",u=t.align,p=u.charAt(0).toLowerCase()+u.slice(1);d&&(p+=" "+d.charAt(0).toLowerCase()+d.slice(1)),oi(l,{id:e.id+"_image",x:i,y:r,width:s,height:o,preserveAspectRatio:p})}},n.prototype.transformLayers=function(t,e){var i=t.tx*t.scale,r=t.ty*t.scale,s="domTable";if(i!==this.transform.x||r!==this.transform.y||0===i||0===r){e&&(window[""+s][this.diagramId+"_diagramLayer"]||(window[""+s][this.diagramId+"_diagramLayer"]=this.diagramSvgLayer.getElementById(this.diagramId+"_diagramLayer")),window[""+s][this.diagramId+"_diagramLayer"].setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+"),scale("+t.scale+")"));var a=function Aoe(n){var t="domTable",e=null;return window[t][n+"_gridline"]?e=window[t][n+"_gridline"]:(e=Ud(n).getElementById(n+"_gridline"),window[t][n+"_gridline"]=e),e}(this.diagramId);return a.setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+")"),window[""+s][this.diagramId+"_diagramPorts"]||(window[""+s][this.diagramId+"_diagramPorts"]=this.iconSvgLayer.getElementById(this.diagramId+"_diagramPorts")),window[""+s][this.diagramId+"_diagramPorts"].setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+"),scale("+t.scale+")"),window[""+s][this.diagramId+"_diagramExpander"]||(window[""+s][this.diagramId+"_diagramExpander"]=this.iconSvgLayer.getElementById(this.diagramId+"_diagramExpander")),window[""+s][this.diagramId+"_diagramExpander"].setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+"),scale("+t.scale+")"),window[""+s][this.diagramId+"_nativeLayer"]||(window[""+s][this.diagramId+"_nativeLayer"]=this.nativeSvgLayer.getElementById(this.diagramId+"_nativeLayer")),window[""+s][this.diagramId+"_nativeLayer"].setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+"),scale("+t.scale+")"),Io(this.diagramId).children[0].style.transform="translate("+t.tx*t.scale+"px,"+t.ty*t.scale+"px)scale("+t.scale+")",this.transform={x:t.tx*t.scale,y:t.ty*t.scale},!0}return!1},n.prototype.updateNode=function(t,e,i,r,s,o,a){this.renderElement(t,e,i,r,this.getParentSvg(t),void 0,void 0,s,null,o,a)},n}(),use=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),rb=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},uF=function(n){function t(e,i){var r=n.call(this,e,i)||this;return r.mode="Canvas",r.id="overview",r.actionName="",r.startPoint=null,r.currentPoint=null,r.prevPoint=null,r.scale=null,r.inAction=!1,r.viewPortRatio=1,r.horizontalOffset=0,r.verticalOffset=0,r.model={},r.event=!0,r.overviewid=88123,r.model={width:r.width,height:r.height},r}return use(t,n),t.prototype.onPropertyChanged=function(e,i){for(var r=0,s=Object.keys(e);r0||e.toString().indexOf("%")>0?e.toString():e.toString()+"px"},t.prototype.renderCanvas=function(e){var i=document.getElementById(this.element.id+"_canvas");i||(i=Tt("div",{}),this.element.appendChild(i)),Ho(i,{id:this.element.id+"_canvas",class:"drawing",style:"position:relative; height:"+this.getSizeValue(this.model.height)+"; width:"+this.getSizeValue(this.model.width)+";style:-ms-touch-action: none;touch-action: none;"}),this.element.setAttribute("tabindex",String(-1)),this.element.style.overflow="hidden",this.element.style.height=String(this.model.height),this.element.style.width=String(this.model.width),this.canvas=i},t.prototype.setParent=function(e){var i=document.getElementById(e);if(this.parent){var s=this.parent;this.parent=null,s.setOverview(null,this.element.id),this.removeDocument(this)}this.parent=this.getDiagram(i,"ej2_instances"),this.parent&&this.parent.setOverview(this)},t.prototype.getDiagram=function(e,i){for(var r,s=e[""+i].length,o=0;o0?p:Math.floor(window.innerWidth)}if(0===h){var f=Math.floor(window.innerHeight-u-Math.floor(c.top));h=f>0?f:Math.floor(window.innerHeight)}l>0&&(s.setAttribute("width",String(l)),this.model.height=h),h>0&&(s.setAttribute("height",String(h)),this.model.width=l),e.diagramLayerDiv||(e.diagramLayerDiv=Tt("div",{}),e.diagramLayer=bo.createCanvas(this.element.id+"_diagramLayer",this.model.width,this.model.height),e.diagramLayer.setAttribute("style","position:absolute; left:0px; top:0px "),e.diagramLayerDiv.appendChild(e.diagramLayer),e.canvas.appendChild(e.diagramLayerDiv)),Ho(e.diagramLayerDiv,{id:this.element.id+"_diagramLayer_div",style:"width:"+this.model.width+"px; height:"+this.model.height+"px;position:absolute;top:0px;left:0px"}),this.renderHtmlLayer(e.canvas),this.renderNativeLayer(e.canvas,e),this.addOverviewRectPanel(e)},t.prototype.removeDocument=function(e){var i=document.getElementById(this.canvas.id+"_svg");this.canvas.removeChild(i);var r=document.getElementById(this.element.id+"_htmlLayer");this.canvas.removeChild(r);var s=document.getElementById(this.element.id+"_diagramLayer_div");this.canvas.removeChild(s),e.diagramLayerDiv=null,e.diagramLayer=null,window.domTable[this.id+"html_layer"]=null},t.prototype.renderHtmlLayer=function(e){var i=Tt("div",{id:this.element.id+"_htmlLayer",class:"e-html-layer",style:"pointer-events:none;position:absolute;top:0px;left:0px;"}),s=Tt("div",{id:this.element.id+"_htmlLayer_div",style:"position:absolute;top:0px;left:0px;"});return i.appendChild(s),e.appendChild(i),i},t.prototype.renderNativeLayer=function(e,i){if(!document.getElementById(this.element.id+"_nativeLayer_svg")){var r=this.parent.createSvg(this.element.id+"_nativeLayer_svg",this.model.width,this.model.height),s=Bi("g",{id:this.element.id+"_nativeLayer"});r.appendChild(s),i.diagramLayerDiv.appendChild(r),oi(r,{class:"e-native-layer"})}},t.prototype.addOverviewRectPanel=function(e){var i=document.getElementById(this.canvas.id+"_overviewsvg");i&&i.parentNode.removeChild(i),i=Bi("svg",{id:this.canvas.id+"_overviewsvg",class:"overviewsvg",version:"1.1",style:"position:absolute;left:0px;top:0px; aria-label:Specifies overview",width:this.model.width,height:this.model.height}),e.canvas.appendChild(i);var s=Bi("g",{id:this.element.id+"_overviewlayer",style:"pointer-events:none"});i.appendChild(s);var o=Bi("rect",{fill:"transparent",width:"100%",height:"100%",class:"overviewbackrect",id:this.canvas.id+"overviewbackrect"});o.setAttribute("style"," pointer-events: none; "),s.appendChild(o);var a=Bi("g",{id:this.canvas.id+"overviewhandle",style:"pointer-events:all"});s.appendChild(a);var l=Bi("rect",{id:this.canvas.id+"overviewrect",fill:"transparent"});a.appendChild(l),this.renderOverviewCorner("left",a),this.renderOverviewCorner("right",a),this.renderOverviewCorner("top",a),this.renderOverviewCorner("bottom",a),this.renderOverviewCorner("topleft",a),this.renderOverviewCorner("topright",a),this.renderOverviewCorner("bottomleft",a),this.renderOverviewCorner("bottomright",a)},t.prototype.renderOverviewCorner=function(e,i){var s,o=Bi(s="top"===e||"bottom"===e||"right"===e||"left"===e?"rect":"circle",{id:this.canvas.id+"visible"+e,class:"overview-resizer"});i.appendChild(o);var a=Bi(s,{id:this.canvas.id+e,class:"overviewresizer",fill:"transparent"});i.appendChild(a)},t.prototype.updateOverviewRectangle=function(){var e=this.currentPoint.x-this.prevPoint.x,i=this.currentPoint.y-this.prevPoint.y,r=new me;r.width=0,r.height=0;var s=0,o=0;switch(this.resizeDirection){case"left":r.width-=e,r.height-=e/this.viewPortRatio,s=e,o=e/this.viewPortRatio,o/=2;break;case"right":r.width+=e,r.height+=e/this.viewPortRatio,o=e/this.viewPortRatio,o/=-2;break;case"top":r.height-=i,r.width-=i*this.viewPortRatio,o=i,s=i*this.viewPortRatio,s/=2;break;case"bottom":r.height+=i,r.width+=i*this.viewPortRatio,s=i*this.viewPortRatio,s/=-2;break;case"topleft":Math.abs(i)>Math.abs(e)?e=i*this.viewPortRatio:i=e/this.viewPortRatio,r.width-=e,r.height-=i,s=e,o=i;break;case"topright":Math.abs(i)>Math.abs(e)?e=-i*this.viewPortRatio:i=-e/this.viewPortRatio,o=i,r.width+=e,r.height-=i;break;case"bottomleft":Math.abs(i)>Math.abs(e)?e=-i*this.viewPortRatio:i=-e/this.viewPortRatio,s=e,r.width-=e,r.height+=i;break;case"bottomright":Math.abs(i)>Math.abs(e)?e=i*this.viewPortRatio:i=e/this.viewPortRatio,r.width+=e,r.height+=i}this.updateHelper(s,o,r,void 0,void 0)},t.prototype.updateHelper=function(e,i,r,s,o){var a,l,h,u,p,d=this.element.getElementsByTagName("svg")[2].getElementById("helper");r?(a=(h=d.getBBox()).x+e,l=h.y+i,s=h.width+r.width,o=h.height+r.height):(u=this.currentPoint.x>this.startPoint.x?this.currentPoint.x-this.prevPoint.x:this.prevPoint.x-this.currentPoint.x,p=this.currentPoint.y>this.startPoint.y?this.currentPoint.y-this.prevPoint.y:this.prevPoint.y-this.currentPoint.y,Math.abs(p)>Math.abs(u)?u=this.viewPortRatio*p:p=u/this.viewPortRatio,h=d.getBBox(),a=this.startPoint.x>this.currentPoint.x?h.x-u:h.x,l=this.startPoint.y>this.currentPoint.y?h.y-p:h.y,s=h.width+u,o=h.height+p),oi(this.helper,{id:this.helper.id,x:a,y:l,width:Math.max(0,s),height:Math.max(0,o)})},t.prototype.updateOverviewrect=function(e,i,r,s){Ho(document.getElementById(this.canvas.id+"overviewrect"),{x:e,y:i,width:Math.max(1,r),height:Math.max(1,s)}),this.updateOverviewCorner("top",e+8,i+1,Math.max(0,r-16),2),this.updateOverviewCorner("bottom",e+8,i+s+3,Math.max(0,r-16),2),this.updateOverviewCorner("left",e-2,i+11,2,Math.max(0,s-16)),this.updateOverviewCorner("right",e+r,i+11,2,Math.max(0,s-16)),this.updateOverviewCorner("topleft",e,i+3,5,5),this.updateOverviewCorner("topright",e+r,i+3,5,5),this.updateOverviewCorner("bottomleft",e,i+s+3,5,5),this.updateOverviewCorner("bottomright",e+r,i+s+3,5,5)},t.prototype.updateOverviewCorner=function(e,i,r,s,o){var a,l;"top"===e||"bottom"===e||"right"===e||"left"===e?(a={x:i,y:r,width:s,height:o,fill:"#ED1C24"},l={x:i-2,y:r-2,width:2===s?4:s,height:2===o?4:o}):(a={cx:i,cy:r,r:4,fill:"#ED1C24"},l={cx:i,cy:r,r:6,fill:"transparent"}),Ho(document.getElementById(this.canvas.id+"visible"+e),a),Ho(document.getElementById(this.canvas.id+e),l)},t.prototype.translateOverviewRectangle=function(){Number(this.model.width),Number(this.model.height);var r=this.currentPoint.x-this.prevPoint.x,s=this.currentPoint.y-this.prevPoint.y,l=this.element.getElementsByClassName("overviewsvg")[0].getElementById(this.canvas.id+"overviewrect").getBBox(),h=l.x+r,c=l.y+s,d=l.width,u=l.height;this.updateOverviewrect(h,c,d,u),this.updateParentView(this.parent.scroller.currentZoom,h,c,d,u,null)},t.prototype.renderOverviewRect=function(e,i,r,s){var o=Number(this.model.width),a=Number(this.model.height),c=Math.max(this.parent.scroller.viewPortWidth/(r/o*this.contentWidth),this.parent.scroller.viewPortHeight/(s/a*this.contentHeight));if(c>=.25&&c<=30){this.updateParentView(c,e,i,r,s,{x:0,y:0});var u=this.scrollOverviewRect(this.parent.scroller.horizontalOffset,this.parent.scroller.verticalOffset,this.parent.scroller.currentZoom,!0);if(this.helper){var f=this.element.getElementsByTagName("rect")[10].getBBox();u.x=f.x,u.y=f.y}"pan"===this.actionName?this.updateOverviewrect(-u.x,-u.y,u.width,u.height):this.updateOverviewrect(u.x,u.y,u.width,u.height)}},t.prototype.scrollOverviewRect=function(e,i,r,s){if(!this.actionName||s){var o=Number(this.model.width),a=Number(this.model.height),l=Math.min(this.contentWidth/o,this.contentHeight/a),h=new Ne,c=h.x=e/r/l,d=h.y=i/r/l,u=0;this.parent.rulerSettings.showRulers&&(u=25);var p=document.getElementById(this.parent.element.id+"content"),f=0,g=0;p&&(f=p.offsetWidth-p.clientWidth,g=p.offsetHeight-p.clientHeight);var v=h.width=(this.parent.scroller.viewPortWidth-u-f)/r/l,y=h.height=(this.parent.scroller.viewPortHeight-u-g)/r/l;if(s){var S=new Ne;return S.x=c,S.y=d,S.width=v,S.height=y,S}this.updateOverviewrect(-c,-d,v,y)}return null},t.prototype.updateParentView=function(e,i,r,s,o,a){var f,g,l=Number(this.model.width),h=Number(this.model.height),u=i*(this.contentWidth/l)*e,p=r*(this.contentHeight/h)*e;this.parent.scroller.getPageBounds(),(1!==e||"pan"===this.actionName)&&(f=-u-this.parent.scroller.horizontalOffset,g=-p-this.parent.scroller.verticalOffset),this.parent.setBlazorDiagramProps(!0),this.parent.realActions|=$i.OverViewAction,"scale"===this.actionName||"draw"===this.actionName?this.parent.scroller.zoom(e/this.parent.scroller.currentZoom,f,g,a):ce()?this.parent.scroller.zoom(1,f,g,a):this.parent.pan(f,g,a,!0)},t.prototype.updateHtmlLayer=function(e){var i=Io(e.element.id),r=this.parent.scroller.getPageBounds(!0),o=r.height,a=Math.max(r.width,this.parent.scroller.viewPortWidth),l=Math.max(o,this.parent.scroller.viewPortHeight/this.parent.scroller.currentZoom),h=Math.min(Number(this.model.width)/a,Number(this.model.height)/l);i.style.transform="scale("+h+") translate("+this.parent.scroller.transform.tx+"px,"+this.parent.scroller.transform.ty+"px)"},t.prototype.updateView=function(e){var i=this.parent.scroller.getPageBounds(),r=i.width,s=i.height,o=Number(this.model.width),a=Number(this.model.height),l=Math.max(r,this.parent.scroller.viewPortWidth),h=Math.max(s,this.parent.scroller.viewPortHeight);this.contentWidth=l=Math.max(l,o/a*h),this.contentHeight=h=Math.max(h,a/o*l);var c=Math.min(o/l,a/h),d=document.getElementById(this.element.id+"_htmlLayer");d.style.webkitTransform="scale("+c+") translate("+-i.x+"px,"+-i.y+"px)",d.style.transform="scale("+c+") translate("+-i.x+"px,"+-i.y+"px)",document.getElementById(this.element.id+"_overviewlayer").setAttribute("transform","translate("+-i.x*c+","+-i.y*c+")"),this.horizontalOffset=i.x*c,this.verticalOffset=i.y*c;var p=document.getElementById(this.element.id+"_diagramLayer"),f=UF(this.element.id),g=p.getContext("2d"),v=Number(this.model.width)/this.contentWidth,y=Number(this.model.height)/this.contentHeight;v=Math.min(v,y);var S=this.parent.scroller.transform;f.setAttribute("transform","translate("+S.tx*v+","+S.ty*y+"),scale("+v+")"),g.setTransform(v,0,0,v,0,0),g.fillStyle="red",this.scrollOverviewRect(this.parent.scroller.horizontalOffset,this.parent.scroller.verticalOffset,this.parent.scroller.currentZoom)},t.prototype.scrolled=function(e){if(this.event){var i=this.scrollOverviewRect(this.parent.scroller.horizontalOffset,this.parent.scroller.verticalOffset,this.parent.scroller.currentZoom,!0);this.updateOverviewrect(-i.x,-i.y,i.width,i.height),this.updateView(this)}},t.prototype.updateCursor=function(e){if(fm(e.target,"overviewresizer"))switch(e.target.id){case this.canvas.id+"left":this.canvas.style.cursor="w-resize";break;case this.canvas.id+"right":this.canvas.style.cursor="e-resize";break;case this.canvas.id+"top":this.canvas.style.cursor="n-resize";break;case this.canvas.id+"bottom":this.canvas.style.cursor="s-resize";break;case this.canvas.id+"topleft":this.canvas.style.cursor="nw-resize";break;case this.canvas.id+"topright":this.canvas.style.cursor="ne-resize";break;case this.canvas.id+"bottomleft":this.canvas.style.cursor="sw-resize";break;case this.canvas.id+"bottomright":this.canvas.style.cursor="se-resize"}else this.canvas.style.cursor="default"},t.prototype.mouseMove=function(e){if(this.event=!1,this.updateCursor(e),this.currentPoint=this.mousePosition(e),this.actionName)switch(this.actionName){case"draw":!this.inAction&&(this.startPoint.x!==this.currentPoint.x||this.startPoint.y!==this.currentPoint.y)&&(this.initHelper(),this.inAction=!0),this.inAction&&this.updateHelper();break;case"scale":this.inAction||(this.initHelper(),this.inAction=!0),this.updateOverviewRectangle();break;case"pan":(this.startPoint.x!==this.currentPoint.x||this.startPoint.y===this.currentPoint.y||this.inAction)&&(this.inAction=!0,this.translateOverviewRectangle())}this.prevPoint=this.currentPoint},t.prototype.documentMouseUp=function(e){this.inAction=!1,this.actionName="",this.helper&&(this.helper.parentNode.removeChild(this.helper),this.helper=null),this.event=!0,document.getElementById(this.canvas.id+"overviewhandle").style.pointerEvents="all"},t.prototype.windowResize=function(e){var i=this;return this.resizeTo&&clearTimeout(this.resizeTo),this.resizeTo=setTimeout(function(){var s=document.getElementById(i.element.id).getBoundingClientRect();i.model.width=s.width>0?s.width:i.model.width,i.model.height=s.height>0?s.height:i.model.height,i.renderCanvas(),i.setParent(i.sourceID)},10),!1},t.prototype.mouseDown=function(e){if(e.target.id===this.canvas.id+"_overviewsvg"&&(this.actionName="draw"),e.target.id===this.canvas.id+"overviewrect"&&(this.actionName="pan"),fm(e.target,"overviewresizer"))switch(this.actionName="scale",e.target.id){case this.canvas.id+"left":this.resizeDirection="left";break;case this.canvas.id+"right":this.resizeDirection="right";break;case this.canvas.id+"top":this.resizeDirection="top";break;case this.canvas.id+"bottom":this.resizeDirection="bottom";break;case this.canvas.id+"topleft":this.resizeDirection="topleft";break;case this.canvas.id+"topright":this.resizeDirection="topright";break;case this.canvas.id+"bottomleft":this.resizeDirection="bottomleft";break;case this.canvas.id+"bottomright":this.resizeDirection="bottomright"}this.startPoint=this.prevPoint=this.mousePosition(e),this.viewPortRatio=this.parent.scroller.viewPortWidth/this.parent.scroller.viewPortHeight,document.getElementById(this.canvas.id+"overviewhandle").style.pointerEvents="none"},t.prototype.mouseUp=function(e){if(this.currentPoint=this.mousePosition(e),this.actionName)if(this.startPoint.x!==this.currentPoint.x||this.startPoint.y!==this.currentPoint.y){if("pan"!==this.actionName&&this.helper){var i=this.element.getElementsByTagName("rect")[10].getBBox();this.resizeDirection=this.resizeDirection||"",this.renderOverviewRect(i.x,i.y,o=i.width,a=i.height)}}else if(e.target.id===this.canvas.id+"_overviewsvg"||"helper"===e.target.id){var o=(i=this.element.getElementsByTagName("svg")[2].getElementById(this.canvas.id+"overviewrect").getBBox()).width,a=i.height;this.inAction=!0,this.actionName="pan",this.renderOverviewRect(this.currentPoint.x-o/2,this.currentPoint.y-a/2,o,a),this.inAction=!1}this.helper&&(this.helper.parentNode.removeChild(this.helper),this.helper=null),this.actionName="",this.startPoint=null,this.currentPoint=null,this.prevPoint=null,this.helper=null,this.viewPortRatio=1,this.resizeDirection="",this.inAction=!1,this.event=!0,document.getElementById(this.canvas.id+"overviewhandle").style.pointerEvents="all"},t.prototype.initHelper=function(){var e=this.element.getElementsByTagName("svg")[2],i=this.startPoint.x,r=this.startPoint.y,s=1,o=1;if("scale"===this.actionName){var l=e.getElementById(this.canvas.id+"overviewrect").getBBox();i=l.x,r=l.y,s=l.width,o=l.height}var h=Bi("rect",{id:"helper",x:i,y:r,width:s,height:o,fill:"transparent",stroke:"gray","stroke-dasharray":"2 2","shape-rendering":"crispEdges"});e.getElementById(this.element.id+"_overviewlayer").appendChild(h),this.helper=h},t.prototype.mousePosition=function(e){var i,r,s;-1!==e.type.indexOf("touch")?(r=(i=e).changedTouches[0].clientX-this.element.offsetLeft,s=i.changedTouches[0].clientY-this.element.offsetTop):(r=e.clientX,s=e.clientY);var l=this.element.getBoundingClientRect();return{x:(r-=l.left)+this.horizontalOffset,y:(s-=l.top)+this.verticalOffset}},t.prototype.destroy=function(){if(this.unWireEvents(),this.notify("destroy",{}),n.prototype.destroy.call(this),document.getElementById(this.element.id)){this.element.classList.remove("e-overview");var e=document.getElementById(this.element.id+"_canvas");e&&this.element.removeChild(e)}this.parent.views.splice(this.parent.views.indexOf(this.element.id),1),this.diagramLayerDiv=null,this.canvas=null,this.parent=null},t.prototype.getModuleName=function(){return"Overview"},rb([I("100%")],t.prototype,"width",void 0),rb([I("100%")],t.prototype,"height",void 0),rb([I("")],t.prototype,"sourceID",void 0),rb([H()],t.prototype,"created",void 0),t}(yi);function fse(n,t){for(var e=0;ez.findLength(e,n)?e:t;var o=z.findAngle(t,e),a=z.findAngle(i,n),l=z.findLength(i,n),h=a+2*(o-a);return{x:i.x+l*Math.cos(h*Math.PI/180),y:i.y+l*Math.sin(h*Math.PI/180)}}function ef(n,t,e){if(n&&n.children&&n.children.length>0)for(var r=void 0,s=0;s0&&"annotations"!==r&&"ports"!==r)if(n[""+l].length>0)for(var h=0;h<=n[""+l].length;h++)Ro(n[""+l],t?t[""+l]:void 0,e[""+l],"annotations"===l||"ports"===l?n:void 0,l);else Ro(n[""+l],t?t[""+l]:void 0,e[""+l],"annotations"===l||"ports"===l?n:void 0,l);else if(s instanceof Object&&t&&"annotations"!==r&&"ports"!==r)Ro(n[""+l],t[""+l],e[""+l]);else if("annotations"!==r&&"ports"!==r&&t&&!t[""+l]||!t&&n&&(n[""+l]||void 0!==n[""+l]))n[""+l]=e[""+l];else{var c=void 0;("annotations"===r||"ports"===r)&&("annotations"===r?(n[""+l]&&Ro(n[""+l],t[""+l],e[""+l]),n[""+l]||(fs(i)===de?(c=new Nr(i,"annotations",e[""+l]),i.annotations.push(c)):(c=new Zn(i,"annotations",e[""+l]),i.annotations.push(c)))):n[""+l]?Ro(n[""+l],t[""+l],e[""+l]):(c=new Es(i,"ports",e[""+l]),i.ports.push(c)))}}}function bse(n,t){for(var e="Bezier"===n.type?function yse(n){var t=[];if("Bezier"===n.type)for(var e=0,i=0;i0||n.ports.length>0){var p=n.wrapper.children;for(i=3;i0)return{enabled:!1,intersectPt:e};var l=o/s,h=a/s;return l>=0&&l<=1&&h>=0&&h<=1?(e.x=i.x1+l*(i.x2-i.x1),e.y=i.y1+l*(i.y2-i.y1),{enabled:!0,intersectPt:e}):{enabled:!1,intersectPt:e}}function sb(n,t,e,i){var a=rm(vF(n.x,n.y,t.x,t.y),vF(e.x,e.y,i.x,i.y));return a.enabled?a.intersectPt:{x:0,y:0}}function vF(n,t,e,i){return{x1:Number(n)||0,y1:Number(t)||0,x2:Number(e)||0,y2:Number(i)||0}}function mF(n,t,e){var i=[],s={x:t.topRight.x+(e=e||0),y:t.topRight.y},o={x:t.bottomRight.x,y:t.bottomRight.y-e},a={x:t.bottomLeft.x,y:t.bottomLeft.y+e};return i.push({x:t.topLeft.x-e,y:t.topLeft.y}),i.push(s),i.push(o),i.push(a),i}function Hc(n,t,e,i,r,s){var o={},a=e.scroller.transform.scale,h=e.scroller.verticalOffset;return o.x=(i?n.x:t.x)*a+e.scroller.horizontalOffset-r,o.y=(i?n.y:t.y)*a+h-s,o}function yF(n,t){var e=new Ke;return e.data=n.pathData,e.height=n.height>10?n.height-(n.padding.bottom+n.padding.top):n.height,e.width=n.width>10?n.width-(n.padding.left+n.padding.right):n.width,e.visible=n.visibility,e.id=t.id+"_shape",e.inversedAlignment=!1,e.horizontalAlignment="Center",e.verticalAlignment="Center",e.style={fill:n.iconStrokeColor,strokeColor:n.iconStrokeColor,strokeWidth:n.iconStrokeWidth},e.setOffsetWithRespectToBounds(.5,.5,"Fraction"),e.relativeMode="Object",e.description=t.description||"",e}function Jx(n,t,e){var i=Kx(n,t),r=z.findAngle(n[i.index],n[i.index+1]),s=function Tse(n){var t;t=n instanceof OI?0:void 0===n.content?10:0;var e=0;switch(n.alignment){case"Center":e=0;break;case"Before":e=-(0+t);break;case"After":e=0+t}return e}(t),o=z.transform(i.point,r+45,s);return i.point=o,i.angle=r,i}function Kx(n,t){for(var r,s,a,l,e=0,i=t.offset,o=[],h=0;h=c)return s=z.findAngle(n[parseInt(d.toString(),10)],n[d+1]),{point:r=z.transform(n[parseInt(d.toString(),10)],s,c-(a||0)),index:l=d};a=o[parseInt(d.toString(),10)]}return{point:r,index:l}}function SF(n,t,e){t%=360;var a,l,s=225;switch(n.alignment){case"Before":t>=45&&t<=135?(l="right",a=.5===n.offset?"center":"top"):t>=s&&t<=315?(l="left",a=.5===n.offset?"center":"bottom"):t>45&&t=45&&t<=135?(l="left",a=.5===n.offset?"center":"top"):t>=s&&t<=315?(l="right",a=.5===n.offset?"center":"bottom"):t>45&&tMath.abs(t.y-n.y)?n.x0)for(var e=0;e=0;r--)("nodes"===i||"connectors"===i)&&(n[""+i][parseInt(r.toString(),10)].wrapper=null),"dataManager"!==i&&(n[""+i][parseInt(r.toString(),10)]=iT(n[""+i][parseInt(r.toString(),10)],e[""+i][parseInt(r.toString(),10)],void 0!==t[""+i]?t[""+i][parseInt(r.toString(),10)]:[]),("[]"===JSON.stringify(n[""+i][parseInt(r.toString(),10)])||"{}"===JSON.stringify(n[""+i][parseInt(r.toString(),10)])||void 0===n[""+i][parseInt(r.toString(),10)])&&n[""+i].splice(r,1));n=void 0}function Bh(n,t){var e=t.style,i=t;t.canApplyStyle=!0;for(var r=0,s=Object.keys(n);r=0&&n.splice(e,1)}function tf(n,t,e){var i;n.intermediatePoints=t,n.updateSegmentElement(n,t,n.wrapper.children[0],e);var r=n.sourceDecorator;if("Bezier"===n.type){var s=n.segments[0],o=n.segments[n.segments.length-1];i=[z.isEmptyPoint(o.point2)?o.bezierPoint2:o.point2,z.isEmptyPoint(s.point1)?s.bezierPoint1:s.point1]}else i=n.intermediatePoints;t=n.clipDecorators(n,t,e);var a=n.wrapper.children[0];a.canMeasurePath=!0,n.updateDecoratorElement(a=n.wrapper.children[1],t[0],i[1],r),n.updateDecoratorElement(a=n.wrapper.children[2],t[t.length-1],i[i.length-2],n.targetDecorator),n.updateShapeElement(n)}function rT(n,t,e){var l,i=n.wrapper,s=t.offset,o=t.size/e.scale,a=t.margin,h=i.offsetX-i.actualSize.width*i.pivot.x,c=i.offsetY-i.actualSize.height*i.pivot.y;if(l={x:0,y:0},n.nodes.length>0){switch(t.side){case"Top":l.x+=h+s*i.actualSize.width,l.y+=c-o;break;case"Bottom":l.x+=h+s*i.actualSize.width,l.y+=c+i.actualSize.height+o;break;case"Left":l.x+=h-o,l.y+=c+s*i.actualSize.height;break;case"Right":l.x+=h+i.actualSize.width+o,l.y+=c+s*i.actualSize.height}l.x+=(a.left-a.right)/e.scale+o/2*("Center"===t.horizontalAlignment?0:"Right"===t.horizontalAlignment?-1:1),l.y+=(a.top-a.bottom)/e.scale+o/2*("Center"===t.verticalAlignment?0:"Top"===t.verticalAlignment?-1:1)}else if(n.connectors.length>0){var d=n.connectors[0],u={offset:s},p=Kx(d.intermediatePoints,u),f=p.index;l=p.point;var y,v=Jx(d.intermediatePoints,u).angle;qi(y=Hi(),-v,d.intermediatePoints[parseInt(f.toString(),10)].x,d.intermediatePoints[parseInt(f.toString(),10)].y),(l=Je(y,l)).x+=a.left-a.right+o/2*("Center"===t.horizontalAlignment?0:"Right"===t.horizontalAlignment?-1:1),l.y+=a.top-a.bottom+o/2*("Center"===t.verticalAlignment?0:"Top"===t.verticalAlignment?-1:1),qi(y=Hi(),v,d.intermediatePoints[parseInt(f.toString(),10)].x,d.intermediatePoints[parseInt(f.toString(),10)].y),l=Je(y,l)}return 0===i.rotateAngle&&0===i.parentTransform||(qi(y=Hi(),i.rotateAngle+i.parentTransform,i.offsetX,i.offsetY),l=Je(y,l)),l}function fa(n,t,e,i){if(i.annotation){if(kl(i.annotation))return!0}else if(mr[""+t]&n&&bt[""+t]&e)return!0;return!1}function qr(n,t){return!!(mr[""+t]&n)}function Fc(n,t){return!!(Ex[""+t]&n)}function ga(n,t){return n.visibility&t}function ob(n,t){var e;if("Text"===n.shape.type)e=n.shape;else{var i=t.split("_");t=i[i.length-1];for(var r=0;rn[""+t]?e.splice(0,0,n):e.push(n);else if(e.length>1){for(var i=0,r=e.length-1,s=Math.floor((i+r)/2);s!==i;)if(e[parseInt(s.toString(),10)][""+t]n[""+t]))break;r=s,s=Math.floor((i+r)/2)}e[parseInt(r.toString(),10)][""+t]n[""+t]?e.splice(i,0,n):e[parseInt(i.toString(),10)][""+t]n[""+t]&&e.splice(r,0,n)}}function Qse(n){var t=document.getElementById(n.diagramId),e="ej2_instances",i=t[""+e][0].nodes;void 0===i&&(i=function Gse(n){for(var t=[],e=0;e30?10:o/2;for(var h=0,c=0;c=l){var u=l-h;r=Gt(n[c],n[c+1]),s=z.transform(n[c],r,u);break}h+=d}return s},hb=function(n,t){if(n instanceof te||n instanceof de)for(var e=0;e=0||navigator.platform.indexOf("iPad")>=0||navigator.platform.indexOf("iPhone")>=0||navigator.platform.indexOf("MacIntel")>=0)&&("safari"===X.info.name||"webkit"===X.info.name)}function AF(n,t,e,i){return void 0!==t.previewSize[""+i]?t.previewSize[""+i]:void 0!==n.symbolPreview[""+i]?n.symbolPreview[""+i]:t[""+i]||e.actualSize[""+i]}function lm(n,t,e){return n&&n.parentId&&(e=(n=t.nameTable[n.parentId]).parentId?lm(n,t,e):n.id),e}function hm(n,t){return n.selectedItems.connectors.length>1&&0===n.selectedItems.nodes.length&&0!==t.rotateAngle}function Zse(n){if(n.arrowType&&""!==n.arrowType.trim())switch(n.arrowType){case"single-line-arrow":default:return{targetDecorator:"Arrow",strokeWidth:1};case"double-line-arrow":return{targetDecorator:"Arrow",strokeWidth:2};case"dotted-arrow":return{targetDecorator:"Arrow",strokeDashArray:"2,2"};case"single-line":return{targetDecorator:"None",strokeWidth:1};case"double-line":return{targetDecorator:"None",strokeWidth:2};case"dotted":return{targetDecorator:"None",strokeDashArray:"2,2"};case"wiggly-arrow":return{targetDecorator:"None",strokeWidth:1,opacity:0}}return{targetDecorator:"Arrow",strokeWidth:1}}var Jse=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),io=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},LF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Jse(t,n),io([I("None")],t.prototype,"shape",void 0),io([I("white")],t.prototype,"fill",void 0),io([I("Auto")],t.prototype,"horizontalAlignment",void 0),io([I("Auto")],t.prototype,"verticalAlignment",void 0),io([I(10)],t.prototype,"width",void 0),io([I(10)],t.prototype,"height",void 0),io([re({x:.5,y:1},z)],t.prototype,"offset",void 0),io([I("#1a1a1a")],t.prototype,"borderColor",void 0),io([I(1)],t.prototype,"borderWidth",void 0),io([re({},$n)],t.prototype,"margin",void 0),io([I("")],t.prototype,"pathData",void 0),io([I("")],t.prototype,"content",void 0),io([I(0)],t.prototype,"cornerRadius",void 0),io([re({left:2,right:2,top:2,bottom:2},$n)],t.prototype,"padding",void 0),io([I("#1a1a1a")],t.prototype,"iconColor",void 0),t}(Ee),Kse=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),aT=function(n){function t(){var e=null!==n&&n.apply(this,arguments)||this;return e.orientation="Vertical",e.measureChildren=void 0,e.considerPadding=!0,e}return Kse(t,n),t.prototype.measure=function(e){return this.desiredSize=this.measureStackPanel(e,"Horizontal"===this.orientation?this.updateHorizontalStack:this.updateVerticalStack),this.desiredSize},t.prototype.arrange=function(e){return this.actualSize=this.arrangeStackPanel(e,"Horizontal"===this.orientation?this.arrangeHorizontalStack:this.arrangeVerticalStack),this.updateBounds(),this.actualSize},t.prototype.measureStackPanel=function(e,i){var r=void 0;if(void 0!==this.children&&this.children.length>0)for(var s=0,o=this.children;s0){var r=void 0,s=void 0;r=this.offsetX-e.width*this.pivot.x+this.padding.left,s=this.offsetY-e.height*this.pivot.y+this.padding.top;for(var o=0,a=this.children;o0)for(var i=0,r=this.children;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},aoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return ooe(t,n),Fh([I("Horizontal")],t.prototype,"orientation",void 0),Fh([I("Center")],t.prototype,"type",void 0),Fh([I(void 0)],t.prototype,"offset",void 0),Fh([I(!1)],t.prototype,"enableRouting",void 0),Fh([I([])],t.prototype,"children",void 0),Fh([I("")],t.prototype,"assistants",void 0),Fh([I("")],t.prototype,"level",void 0),Fh([I("")],t.prototype,"hasSubTree",void 0),Fh([I("")],t.prototype,"rows",void 0),t}(Ee),Li=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),q=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},loe=function(n){if(n)switch(n.type){case"Basic":default:return cb;case"Flow":return PF;case"Path":return NF;case"Image":return kF;case"Text":return Hd;case"Bpmn":return pT;case"Native":return cm;case"HTML":return OF;case"UmlActivity":return zF;case"UmlClassifier":return RF;case"SwimLane":return _d}return cb},va=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),q([I("Basic")],t.prototype,"type",void 0),t}(Ee),NF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"Path"},q([I("Path")],t.prototype,"type",void 0),q([I("")],t.prototype,"data",void 0),t}(va),cm=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"Native"},q([I("Native")],t.prototype,"type",void 0),q([I("")],t.prototype,"content",void 0),q([I("Stretch")],t.prototype,"scale",void 0),t}(va),OF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"Html"},q([I("HTML")],t.prototype,"type",void 0),q([I("")],t.prototype,"content",void 0),t}(va),kF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"Image"},q([I("Image")],t.prototype,"type",void 0),q([I("")],t.prototype,"source",void 0),q([I("None")],t.prototype,"scale",void 0),q([I("None")],t.prototype,"align",void 0),t}(va),Hd=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"Text"},q([I("Text")],t.prototype,"type",void 0),q([I("")],t.prototype,"content",void 0),q([re({},$n)],t.prototype,"margin",void 0),t}(va),cb=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"BasicShape"},q([I("Basic")],t.prototype,"type",void 0),q([I("Rectangle")],t.prototype,"shape",void 0),q([I(0)],t.prototype,"cornerRadius",void 0),q([Bt([],z)],t.prototype,"points",void 0),t}(va),PF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"FlowShape"},q([I("Flow")],t.prototype,"type",void 0),q([I("Terminator")],t.prototype,"shape",void 0),t}(va),hT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"BpmnGateway"},q([I("None")],t.prototype,"type",void 0),t}(Ee),cT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"BpmnDataObject"},q([I("None")],t.prototype,"type",void 0),q([I(!1)],t.prototype,"collection",void 0),t}(Ee),hoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),q([I("None")],t.prototype,"type",void 0),q([I("None")],t.prototype,"loop",void 0),q([I(!1)],t.prototype,"call",void 0),q([I(!1)],t.prototype,"compensation",void 0),t}(Ee),dT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"BpmnEvent"},q([I("Start")],t.prototype,"event",void 0),q([I("None")],t.prototype,"trigger",void 0),t}(Ee),Bd=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"BpmnSubEvent"},q([I("None")],t.prototype,"trigger",void 0),q([I("Start")],t.prototype,"event",void 0),q([I("")],t.prototype,"id",void 0),q([re({},z)],t.prototype,"offset",void 0),q([Bt([],Zn)],t.prototype,"annotations",void 0),q([Bt([],Es)],t.prototype,"ports",void 0),q([I()],t.prototype,"width",void 0),q([I()],t.prototype,"height",void 0),q([re({},$n)],t.prototype,"margin",void 0),q([I("Center")],t.prototype,"horizontalAlignment",void 0),q([I("Center")],t.prototype,"verticalAlignment",void 0),q([I(!0)],t.prototype,"visible",void 0),t}(Ee),coe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),q([re({id:"success",event:"End",offset:{x:1,y:.5}},Bd)],t.prototype,"success",void 0),q([re({id:"failure",event:"Intermediate",trigger:"Error",offset:{x:.25,y:1}},Bd)],t.prototype,"failure",void 0),q([re({id:"cancel",event:"Intermediate",trigger:"Cancel",offset:{x:.75,y:1}},Bd)],t.prototype,"cancel",void 0),t}(Ee),doe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),q([I("None")],t.prototype,"type",void 0),q([I(!1)],t.prototype,"adhoc",void 0),q([I("Default")],t.prototype,"boundary",void 0),q([I(!1)],t.prototype,"compensation",void 0),q([I("None")],t.prototype,"loop",void 0),q([I(!0)],t.prototype,"collapsed",void 0),q([Bt([],Bd)],t.prototype,"events",void 0),q([re({},coe)],t.prototype,"transaction",void 0),q([I(void 0)],t.prototype,"processes",void 0),t}(Ee),uT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"BpmnActivity"},q([I("Task")],t.prototype,"activity",void 0),q([re({},hoe)],t.prototype,"task",void 0),q([re({},doe)],t.prototype,"subProcess",void 0),t}(Ee),dm=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return Li(t,n),t.prototype.getClassName=function(){return"BpmnAnnotation"},q([I("")],t.prototype,"text",void 0),q([I("")],t.prototype,"id",void 0),q([I(0)],t.prototype,"angle",void 0),q([I()],t.prototype,"height",void 0),q([I()],t.prototype,"width",void 0),q([I(0)],t.prototype,"length",void 0),t}(Ee),uoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),q([I("")],t.prototype,"textAnnotationTarget",void 0),q([I("Auto")],t.prototype,"textAnnotationDirection",void 0),t}(Ee),pT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"BpmnShape"},q([I("Bpmn")],t.prototype,"type",void 0),q([I("Event")],t.prototype,"shape",void 0),q([re({},dT)],t.prototype,"event",void 0),q([re({},hT)],t.prototype,"gateway",void 0),q([re({},cT)],t.prototype,"dataObject",void 0),q([re({},uT)],t.prototype,"activity",void 0),q([re({},dm)],t.prototype,"annotation",void 0),q([Bt([],dm)],t.prototype,"annotations",void 0),q([re({},uoe)],t.prototype,"textAnnotation",void 0),t}(va),zF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"UmlActivityShape"},q([I("UmlActivity")],t.prototype,"type",void 0),q([I("Action")],t.prototype,"shape",void 0),t}(va),fT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"MethodArguments"},q([I("")],t.prototype,"name",void 0),q([I("")],t.prototype,"type",void 0),q([re({},qp)],t.prototype,"style",void 0),t}(Ee),af=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"UmlClassAttribute"},q([I("Public")],t.prototype,"scope",void 0),q([I(!1)],t.prototype,"isSeparator",void 0),q([re({fill:"#F9F9F9",strokeColor:"#CCCCCC"},Ll)],t.prototype,"separatorStyle",void 0),t}(fT),um=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"UmlClassMethod"},q([Bt([],fT)],t.prototype,"parameters",void 0),t}(af),db=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"UmlClass"},q([I("")],t.prototype,"name",void 0),q([Bt([],af)],t.prototype,"attributes",void 0),q([Bt([],um)],t.prototype,"methods",void 0),q([re({},qp)],t.prototype,"style",void 0),t}(Ee),gT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"UmlInterface"},q([I(!1)],t.prototype,"isSeparator",void 0),q([re({fill:"#F9F9F9",strokeColor:"#CCCCCC"},Ll)],t.prototype,"separatorStyle",void 0),t}(db),ub=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"UmlEnumerationMember"},q([I("")],t.prototype,"name",void 0),q([I("")],t.prototype,"value",void 0),q([I(!1)],t.prototype,"isSeparator",void 0),q([re({fill:"#F9F9F9",strokeColor:"#CCCCCC"},Ll)],t.prototype,"separatorStyle",void 0),q([re({},qp)],t.prototype,"style",void 0),t}(Ee),vT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"UmlEnumeration"},q([I("")],t.prototype,"name",void 0),q([Bt([],ub)],t.prototype,"members",void 0),q([re({},qp)],t.prototype,"style",void 0),t}(Ee),RF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"UmlClassifierShape"},q([I("UmlClassifier")],t.prototype,"type",void 0),q([re({},db)],t.prototype,"classShape",void 0),q([re({},gT)],t.prototype,"interfaceShape",void 0),q([re({},vT)],t.prototype,"enumerationShape",void 0),q([I("Class")],t.prototype,"classifier",void 0),t}(va),te=function(n){function t(e,i,r,s){var a,o=n.call(this,e,i,r,s)||this;return o.isCanvasUpdate=!1,o.status="None",o.parentId="",o.processId="",o.umlIndex=-1,o.outEdges=[],o.inEdges=[],o.isHeader=!1,o.isLane=!1,o.isPhase=!1,o.children&&o.children.length>0&&((!(a=r).style||!a.style.fill)&&(o.style.fill="transparent"),(!a.style||!a.style.strokeColor)&&(o.style.strokeColor="transparent")),o.shape&&"UmlActivity"===o.shape.type&&nb(r,o),o.shape&&"SwimLane"===o.shape.type&&pF(r,o),o.ports&&o.ports.length&&function vse(n){for(var t=0;t>";t=n;break;case"FinalNode":t=IF(e)}return t}(new Ke,i,this);break;case"Bpmn":if(e.bpmnModule){i=e.bpmnModule.initBPMNContent(i,this,e),this.wrapper.elementActions=this.wrapper.elementActions|Xr.ElementIsGroup;var v=this.shape.activity.subProcess;if(v.processes&&v.processes.length)for(var S=0,b=this.shape.activity.subProcess.processes;S>",margin:{left:10,right:10},id:"class",style:{fontSize:i.style.fontSize,color:i.style.color,fill:i.style.fill,textWrapping:r},offset:{x:.5,y:.3},constraints:Lr.ReadOnly}],constraints:(ie.Default|ie.HideThumbs)&~(ie.Rotate|ie.Drag|ie.Resize),verticalAlignment:"Stretch",horizontalAlignment:"Stretch",style:{fill:t.style.fill,strokeColor:"black"===t.style.strokeColor?"#ffffff00":t.style.strokeColor}},!0);return e.initObject(s),e.nodes.push(s),e.UpdateBlazorDiagramModel(s,"Node"),t.children.push(s.id),function toe(n,t,e,i){if("Enumeration"===n.shape.classifier){var r=e.members;if(r&&r.length){sf(n,t);for(var s="",o=0;o0)for(var o=0;o0&&s.phaseSize&&(i+=s.phaseSize,$v(n,s.phaseSize)),s.lanes.length>0)for(o=0;o0){var a=0;for(o=0;o0&&"Horizontal"===r.orientation)for(l=0;l0&&(i+=r.phaseSize,o=Zv(r.phaseSize),n.push(o)),a=0;a0&&o.phaseSize){for(var l=0;l0)for(l=0;l0?e.nameTable[this.nodes[0].id].wrapper:e.nameTable[this.connectors[0].id].wrapper,this.annotation.id);i.children.push(s)}else if(this.nodes||this.connectors){for(var o=0;o-1}function VF(n,t,e){n=[];for(var i=0,r=e.length;i0?c.getElementsByTagName("svg")[0].outerHTML:c.getElementsByTagName("g").length>0?c.getElementsByTagName("g")[0].outerHTML:"",s.shape.content=h,n.content=h,c.parentElement.removeChild(c)}l="nodeTemplate"}else a=s,l="annotationTemplate";var f=document.getElementById(n.diagramId).ej2_instances[0];if("string"!=typeof n.content&&"function"!=typeof n.content||n.isTemplate)if(n.isTemplate){if(v=void 0,v=f.isReact?n.getNodeTemplate()($(e),f,l+"_"+("nodeTemplate"===l?e.id:n.nodeId+e.id),void 0,void 0,!1,i):f.isVue||f.isVue3?n.getNodeTemplate()?n.getNodeTemplate()($(e),f,l+"_"+("nodeTemplate"===l?e.id:n.nodeId+e.id),void 0,void 0,!1,i):(v=ii("nodeTemplate"===l?f.nodeTemplate:f.annotationTemplate))($(e),f,l+"_"+("nodeTemplate"===l?e.id:n.nodeId+e.id),void 0,void 0,!1,i):n.getNodeTemplate()($(e),f,l+"_"+("nodeTemplate"===l?e.id:n.nodeId+e.id),void 0,void 0,!1))for(var M=0;M=1&&0===n.x&&("Clip"===i.textOverflow||"Ellipsis"===i.textOverflow)&&("Wrap"===i.textWrapping||"WrapWithOverflow"===i.textWrapping)&&(n.x=t[e-1]?t[e-1].x:-n.width/2),n.x}function QF(n,t,e,i){return e&&!t.template||t.template&&"function"==typeof t.template&&i.isReact?(n.isTemplate=!0,n.template=n.content=_h(n,!0,t)):n.content=t.template,n}function Qe(){for(var e,t="",i=0;i<5;i++){if(typeof window<"u"&&"crypto"in window&&"getRandomValues"in crypto){var r=new Uint16Array(1);e=(window.msCrypto||window.crypto).getRandomValues(r)[0]%60}else e=Math.floor(61*Math.random());0===i&&e<10?i--:t+="0123456789ABCDEFGHIJKLMNOPQRSTUVWXTZabcdefghiklmnopqrstuvwxyz".substring(e,e+1)}return t}function GF(n){if(n)try{return"function"!=typeof n&&document.querySelectorAll(n).length?ii(document.querySelector(n).innerHTML.trim()):ii(n)}catch{return ii(n)}}function En(n){new Ne;var e=n.offsetY-n.actualSize.height*n.pivot.y,i=n.offsetY+n.actualSize.height*(1-n.pivot.y),r=n.offsetX-n.actualSize.width*n.pivot.x,s=n.offsetX+n.actualSize.width*(1-n.pivot.x);return Ne.toBounds([{x:r,y:e},{x:s,y:e},{x:r,y:i},{x:s,y:i}])}function yr(n){var t=new Ne,e=En(n),i=e.middleLeft,r=e.topCenter,s=e.bottomCenter,o=e.middleRight,a=e.topLeft,l=e.topRight,h=e.bottomLeft,c=e.bottomRight;if(n.corners={topLeft:a,topCenter:r,topRight:l,middleLeft:i,middleRight:o,bottomLeft:h,bottomCenter:s,bottomRight:c},0!==n.rotateAngle||0!==n.parentTransform){var d=Hi();qi(d,n.rotateAngle+n.parentTransform,n.offsetX,n.offsetY),n.corners.topLeft=a=Je(d,a),n.corners.topCenter=r=Je(d,r),n.corners.topRight=l=Je(d,l),n.corners.middleLeft=i=Je(d,i),n.corners.middleRight=o=Je(d,o),n.corners.bottomLeft=h=Je(d,h),n.corners.bottomCenter=s=Je(d,s),n.corners.bottomRight=c=Je(d,c)}return t=Ne.toBounds([a,l,h,c]),n.corners.left=t.left,n.corners.right=t.right,n.corners.top=t.top,n.corners.bottom=t.bottom,n.corners.center=t.center,n.corners.width=t.width,n.corners.height=t.height,t}function $(n,t,e,i){var r={},s="properties";if(n){e=n.propName;var l=[],h=[];if((l=l.concat(Object.keys(n[""+s]||n))).push("version"),e){var c=Zi(t);h=c?c(e):[],l=l.concat(h)}for(var d=function Ooe(n){switch(n){case"nodes":case"children":return["inEdges","outEdges","parentId","processId","nodeId","umlIndex","isPhase","isLane"];case"connectors":return["parentId"];case"annotation":case"annotations":return["nodeId"];case"shape":return["hasHeader"];case"layers":return["objectZIndex"]}return[]}(e),u=0,p=l=l.concat(d);u0&&(e=r),r=Math.floor(Poe(e,i)),s=_c(o+=n.substr(e,r),t)}while(s<=t.width);for(o=o.substr(0,e),a=e;a=t.width){n=n.substr(0,o.length-1);break}return"Ellipsis"===t.textOverflow?(n=n.substr(0,n.length-3),n+="..."):n=n.substr(0,n.length),n}function wT(n,t){if("NoWrap"===t&&"PreserveAll"===n)return"pre";var e="";switch(n){case"CollapseAll":e="nowrap";break;case"CollapseSpace":e="pre-line";break;case"PreserveAll":e="pre-wrap"}return e}function CT(n,t){var e=Hi();qi(e,t,0,0);var i=Je(e,{x:0,y:0}),r=Je(e,{x:n.width,y:0}),s=Je(e,{x:0,y:n.height}),o=Je(e,{x:n.width,y:n.height}),a=Math.min(i.x,r.x,s.x,o.x),l=Math.min(i.y,r.y,s.y,o.y),h=Math.max(i.x,r.x,s.x,o.x),c=Math.max(i.y,r.y,s.y,o.y);return new me(h-a,c-l)}function xs(n,t,e,i){if(0!==n){var r=Hi();return qi(r,n,t,e),Je(r,i)}return i}function Zi(n){return void 0!==n&&"string"==typeof n&&(n=Y(n,window)),n}var bo=function(){function n(){}return n.getContext=function(t){return t.getContext("2d")},n.setCanvasSize=function(t,e,i){t&&(t.setAttribute("width",e.toString()),t.setAttribute("height",i.toString()))},n.prototype.renderGradient=function(t,e,i,r){var s,o,a;if("None"!==t.gradient.type){for(var l=0;l0?(w=0===S.r1?e.arc[parseInt(r.toString(),10)].r1:S.r1,C=0===S.r2?e.arc[parseInt(r.toString(),10)].r2:S.r2,r++):(w=S.r1,C=S.r2);var D=S.angle*(Math.PI/180),A=S.largeArc,x=S.sweep,R={x:u,y:p},L={x:Math.cos(D)*(M.x-R.x)/2+Math.sin(D)*(M.y-R.y)/2,y:-Math.sin(D)*(M.x-R.x)/2+Math.cos(D)*(M.y-R.y)/2},O=Math.pow(L.x,2)/Math.pow(w,2)+Math.pow(L.y,2)/Math.pow(C,2);O>1&&(w*=Math.sqrt(O),C*=Math.sqrt(O));var N=Math.pow(C,2)*Math.pow(L.x,2),T=(A===x?-1:1)*Math.sqrt((Math.pow(w,2)*Math.pow(C,2)-Math.pow(w,2)*Math.pow(L.y,2)-N)/(Math.pow(w,2)*Math.pow(L.y,2)+Math.pow(C,2)*Math.pow(L.x,2)));isNaN(T)&&(T=0);var P={x:T*w*L.y/C,y:T*-C*L.x/w},_={x:(M.x+R.x)/2+Math.cos(D)*P.x-Math.sin(D)*P.y,y:(M.y+R.y)/2+Math.sin(D)*P.x+Math.cos(D)*P.y},B=this.a([1,0],[(L.x-P.x)/w,(L.y-P.y)/C]),j=[(L.x-P.x)/w,(L.y-P.y)/C],Q=[(-L.x-P.x)/w,(-L.y-P.y)/C],oe=this.a(j,Q);this.r(j,Q)<=-1&&(oe=Math.PI),this.r(j,Q)>=1&&(oe=0);var pe=B+oe/2*(x?1:-1);if(Math.cos(pe),Math.sin(pe),S.centp=_,S.xAxisRotation=D,S.rx=w,S.ry=C,S.a1=B,S.ad=oe,S.sweep=x,null!=s){var De=w>C?w:C,xe=w>C?1:w/C,Ie=w>C?C/w:1;s.save(),s.translate(_.x,_.y),s.rotate(D),s.scale(xe,Ie),s.arc(0,0,De,B,B+oe,!x),s.scale(1/xe,1/Ie),s.rotate(-D),s.translate(-_.x,-_.y),s.restore()}break;case"Z":case"z":s.closePath(),u=o,p=a}o=u,a=p}}},n.prototype.drawText=function(t,e,i,r,s,o,a){if(e.content&&!0===e.visible){var l=n.getContext(t);l.save(),this.setStyle(t,e),o&&(e.fontSize*=o),this.rotateContext(t,e.angle,e.x+e.width*e.pivotX,e.y+e.height*e.pivotY),this.setFontStyle(t,e);var u,d=0;u=e.childNodes;var p=e.wrapBounds;if(l.fillStyle=e.color,p){var f=this.labelAlign(e,p,u);for(d=0;de.width&&"Wrap"!==e.textOverflow&&"NoWrap"===e.textWrapping&&(g.text=qF(g.text,e)),"Clip"!==e.textOverflow&&"Ellipsis"!==e.textOverflow||"Wrap"!==e.textWrapping?l.fillText(g.text,v,y):ya.actualSize.height+a.bounds.y&&(g.text=g.text.slice(0,g.text.length-3),g.text=g.text.concat("...")),l.fillText(g.text,v,y)),"Underline"===e.textDecoration||"Overline"===e.textDecoration||"LineThrough"===e.textDecoration){var M=v,w=void 0,D=v+l.measureText(g.text).width,A=void 0;switch(e.textDecoration){case"Underline":w=y+2,A=y+2;break;case"Overline":w=f.y+g.dy*d,A=f.y+g.dy*d;break;case"LineThrough":w=(y+f.y+g.dy*d)/2+2,A=(y+f.y+g.dy*d)/2+2}l.beginPath(),l.moveTo(M,w),l.lineTo(D,A),l.strokeStyle=e.color,l.lineWidth=.08*e.fontSize,l.globalAlpha=e.opacity,l.stroke()}}}l.restore()}},n.prototype.loadImage=function(t,e,i,r,s){this.rotateContext(i,e.angle,r,s);var o=new Image;o.src=e.source,this.image(t,o,e.x,e.y,e.width,e.height,e)},n.prototype.drawImage=function(t,e,i,r){var s=this;if(e.visible){var o=n.getContext(t);o.save();var a=e.x+e.width*e.pivotX,l=e.y+e.height*e.pivotY,h=new Image;h.src=e.source,o.canvas.id.split("_"),r?h.onload=function(){s.loadImage(o,e,t,a,l)}:this.loadImage(o,e,t,a,l),o.restore()}},n.prototype.image=function(t,e,i,r,s,o,a){t.beginPath();var l=e.width,h=e.height,c=s,d=o,u=0,p=0;if(a&&"None"!==a.alignment){var f=a.alignment.toLowerCase().substr(1,3),g=a.alignment.toLowerCase().substr(5,3);if("Slice"===a.scale){var v=function(){u=c,p=h*c/l},y=function(){u=l*d/h,p=d};c>d?(v(),d>p&&y()):c===d?l>h?y():v():(y(),c>u&&v());var S=this.getSliceOffset(f,u,c,l),b=this.getSliceOffset(g,p,d,h),M=l-S,w=h-b,C=u-S*(u/l),D=p-b*(p/h),A=Tt("canvas",{width:s.toString(),height:o.toString()});A.getContext("2d").drawImage(e,S,b,M,w,0,0,C,D),t.drawImage(A,i,r,s,o)}else if("Meet"===a.scale){var R=h/l,L=d/c;p=L>R?c*R:d,i+=this.getMeetOffset(f,u=L>R?c:d/R,c),r+=this.getMeetOffset(g,p,d),t.drawImage(e,0,0,l,h,i,r,u,p)}else t.drawImage(e,i,r,s,o)}else if("None"!==a.flip){var O=1,N=1;("Horizontal"===a.flip||"Both"===a.flip)&&(i=-i,s=-s,O=-1),("Vertical"===a.flip||"Both"===a.flip)&&(r=-r,o=-o,N=-1),t.scale(O,N),t.drawImage(e,i,r,s,o)}else t.drawImage(e,i,r,s,o);t.closePath()},n.prototype.getSliceOffset=function(t,e,i,r){switch(t){case"min":default:return 0;case"mid":return(e-i)/2*r/e;case"max":return(e-i)*r/e}},n.prototype.getMeetOffset=function(t,e,i){var r=Math.max(e,i),s=Math.min(e,i);switch(t){case"min":default:return 0;case"mid":return(r-s)/2;case"max":return r-s}},n.prototype.m=function(t){return Math.sqrt(Math.pow(t[0],2)+Math.pow(t[1],2))},n.prototype.r=function(t,e){return(t[0]*e[0]+t[1]*e[1])/(this.m(t)*this.m(e))},n.prototype.a=function(t,e){return(t[0]*e[1]t.width&&("Ellipsis"===t.textOverflow||"Clip"===t.textOverflow)&&"NoWrap"===t.textWrapping?0:.5*t.width:"right"===t.textAlign&&(c=1*t.width),s.x=t.x+c+(e?e.x:0),s.y=a+d-r.height/2,s},n}(),mb=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Vi=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Roe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return mb(t,n),Vi([I("")],t.prototype,"source",void 0),Vi([I("transparent")],t.prototype,"color",void 0),Vi([I("None")],t.prototype,"scale",void 0),Vi([I("None")],t.prototype,"align",void 0),t}(Ee),Hoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return mb(t,n),Vi([I("Page")],t.prototype,"mode",void 0),Vi([I("PageSettings")],t.prototype,"region",void 0),Vi([re({top:25,bottom:25,left:25,right:25},$n)],t.prototype,"margin",void 0),Vi([I(!1)],t.prototype,"canZoomIn",void 0),Vi([I(void 0)],t.prototype,"customBounds",void 0),Vi([I(!1)],t.prototype,"canFit",void 0),t}(Ee),Boe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return mb(t,n),Vi([I(null)],t.prototype,"width",void 0),Vi([I(null)],t.prototype,"height",void 0),Vi([re({},$n)],t.prototype,"margin",void 0),Vi([I("Landscape")],t.prototype,"orientation",void 0),Vi([I("Infinity")],t.prototype,"boundaryConstraints",void 0),Vi([re({},Roe)],t.prototype,"background",void 0),Vi([I(!1)],t.prototype,"multiplePage",void 0),Vi([I(!1)],t.prototype,"showPageBreaks",void 0),Vi([re({},Hoe)],t.prototype,"fitOptions",void 0),t}(Ee),Foe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return mb(t,n),Vi([I(0)],t.prototype,"horizontalOffset",void 0),Vi([I(0)],t.prototype,"verticalOffset",void 0),Vi([I(1)],t.prototype,"currentZoom",void 0),Vi([I(0)],t.prototype,"viewPortWidth",void 0),Vi([I(0)],t.prototype,"viewPortHeight",void 0),Vi([I(.2)],t.prototype,"minZoom",void 0),Vi([I(30)],t.prototype,"maxZoom",void 0),Vi([I("Diagram")],t.prototype,"scrollLimit",void 0),Vi([I()],t.prototype,"scrollableArea",void 0),Vi([I(!1)],t.prototype,"canAutoScroll",void 0),Vi([I(100)],t.prototype,"autoScrollFrequency",void 0),Vi([re({left:15,right:15,top:15,bottom:15},$n)],t.prototype,"autoScrollBorder",void 0),Vi([re({left:0,right:0,top:0,bottom:0},$n)],t.prototype,"padding",void 0),Vi([I(.2)],t.prototype,"zoomFactor",void 0),t}(Ee),_oe=function(){function n(){this.services={}}return n.prototype.register=function(t,e){this.services[""+t]=e},n.prototype.getService=function(t){return this.services[""+t]},n}(),$F=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),ma=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},ZF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return $F(t,n),ma([I("lightgray")],t.prototype,"lineColor",void 0),ma([I("")],t.prototype,"lineDashArray",void 0),ma([I([1.25,18.75,.25,19.75,.25,19.75,.25,19.75,.25,19.75])],t.prototype,"lineIntervals",void 0),ma([I([1,19,.5,19.5,.5,19.5,.5,19.5,.5,19.5])],t.prototype,"dotIntervals",void 0),ma([I([20])],t.prototype,"snapIntervals",void 0),t}(Ee),Uoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return $F(t,n),ma([re({},ZF)],t.prototype,"horizontalGridlines",void 0),ma([re({},ZF)],t.prototype,"verticalGridlines",void 0),ma([I(Kt.All)],t.prototype,"constraints",void 0),ma([I(5)],t.prototype,"snapAngle",void 0),ma([I("Lines")],t.prototype,"gridType",void 0),ma([I(5)],t.prototype,"snapObjectDistance",void 0),ma([I("#07EDE1")],t.prototype,"snapLineColor",void 0),t}(Ee),JF=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Ja=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},KF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return JF(t,n),Ja([I(5)],t.prototype,"interval",void 0),Ja([I(100)],t.prototype,"segmentWidth",void 0),Ja([I("Horizontal")],t.prototype,"orientation",void 0),Ja([I("RightOrBottom")],t.prototype,"tickAlignment",void 0),Ja([I("red")],t.prototype,"markerColor",void 0),Ja([I(25)],t.prototype,"thickness",void 0),Ja([I(null)],t.prototype,"arrangeTick",void 0),t}(Ee),joe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return JF(t,n),Ja([I(!1)],t.prototype,"showRulers",void 0),Ja([I(!0)],t.prototype,"dynamicGrid",void 0),Ja([re({orientation:"Horizontal"},KF)],t.prototype,"horizontalRuler",void 0),Ja([re({orientation:"Vertical"},KF)],t.prototype,"verticalRuler",void 0),t}(Ee),Voe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),e_=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Woe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Voe(t,n),e_([I("")],t.prototype,"property",void 0),e_([I("")],t.prototype,"field",void 0),t}(Ee),ET=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),ln=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},t_=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return ET(t,n),ln([I("")],t.prototype,"read",void 0),ln([I("")],t.prototype,"create",void 0),ln([I("")],t.prototype,"update",void 0),ln([I("")],t.prototype,"destroy",void 0),ln([I()],t.prototype,"customFields",void 0),t}(Ee),Yoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return ET(t,n),ln([I("")],t.prototype,"id",void 0),ln([I("")],t.prototype,"sourceID",void 0),ln([I("")],t.prototype,"targetID",void 0),ln([I(null)],t.prototype,"sourcePointX",void 0),ln([I(null)],t.prototype,"sourcePointY",void 0),ln([I(null)],t.prototype,"targetPointX",void 0),ln([I(null)],t.prototype,"targetPointY",void 0),ln([I(null)],t.prototype,"dataManager",void 0),ln([re({},t_)],t.prototype,"crudAction",void 0),t}(Ee),Qoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return ET(t,n),ln([I("")],t.prototype,"id",void 0),ln([I(null)],t.prototype,"dataManager",void 0),ln([I(null)],t.prototype,"dataSource",void 0),ln([I("")],t.prototype,"root",void 0),ln([I("")],t.prototype,"parentId",void 0),ln([I()],t.prototype,"doBinding",void 0),ln([Bt([],Woe)],t.prototype,"dataMapSettings",void 0),ln([re({},t_)],t.prototype,"crudAction",void 0),ln([re({},Yoe)],t.prototype,"connectionDataSource",void 0),t}(Ee),i_=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Cr=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Goe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return i_(t,n),Cr([I("LeftInFlow")],t.prototype,"yesBranchDirection",void 0),Cr([I("RightInFlow")],t.prototype,"noBranchDirection",void 0),Cr([I(["Yes","True"])],t.prototype,"yesBranchValues",void 0),Cr([I(["No","False"])],t.prototype,"noBranchValues",void 0),t}(Ee),Xoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return i_(t,n),Cr([I("")],t.prototype,"fixedNode",void 0),Cr([I(30)],t.prototype,"horizontalSpacing",void 0),Cr([I("SamePoint")],t.prototype,"connectionPointOrigin",void 0),Cr([I("Nonlinear")],t.prototype,"arrangement",void 0),Cr([I(30)],t.prototype,"verticalSpacing",void 0),Cr([I(30)],t.prototype,"maxIteration",void 0),Cr([I(40)],t.prototype,"springFactor",void 0),Cr([I(50)],t.prototype,"springLength",void 0),Cr([re({left:50,top:50,right:0,bottom:0},$n)],t.prototype,"margin",void 0),Cr([I("Auto")],t.prototype,"horizontalAlignment",void 0),Cr([I("Auto")],t.prototype,"verticalAlignment",void 0),Cr([I("TopToBottom")],t.prototype,"orientation",void 0),Cr([I("Auto")],t.prototype,"connectionDirection",void 0),Cr([I("Default")],t.prototype,"connectorSegments",void 0),Cr([I("None")],t.prototype,"type",void 0),Cr([I()],t.prototype,"getLayoutInfo",void 0),Cr([I()],t.prototype,"layoutInfo",void 0),Cr([I()],t.prototype,"getBranch",void 0),Cr([I()],t.prototype,"bounds",void 0),Cr([I(!0)],t.prototype,"enableAnimation",void 0),Cr([I(!1)],t.prototype,"enableRouting",void 0),Cr([I("")],t.prototype,"root",void 0),Cr([re({},Goe)],t.prototype,"flowchartLayoutSettings",void 0),t}(Ee),qoe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),r_=function(n){function t(e,i){var r=n.call(this,e,!0)||this;return r.oldValue=null,r.endPoint=i,r}return qoe(t,n),t.prototype.mouseDown=function(e){var i,r=!0;if(e.source&&e.source.connectors&&(i=e.source.connectors[0]),e.info&&e.actualObject&&(r=e.info.ctrlKey&&"Orthogonal"!==e.actualObject.type),i&&r){this.inAction=!0,this.undoElement=$(e.source),n.prototype.mouseDown.call(this,e);for(var s=0;s0)1!==s&&this.removePrevSegment(i,s);else if(a){var l=z.distancePoints(a.points[0],a.points[1]);Math.abs(a.length||0===a.length?a.length:l)<=5&&this.removeNextSegment(i,s)}this.commandHandler.updateEndPoint(i,r),i.selectedSegmentIndex=0}if(this.undoElement){var c=$(e.source);this.commandHandler.addHistoryEntry({type:"SegmentChanged",redoObject:c,undoObject:this.undoElement,category:"Internal"})}if(i.isBezierEditing&&(i.isBezierEditing=!1),this.prevPosition!==this.startPosition){var u={source:i,state:"Completed",oldValue:this.oldValue,newValue:$(this.selectedSegment),cancel:!1,segment:this.selectedSegment};this.commandHandler.triggerEvent(Ce.segmentChange,u)}n.prototype.mouseUp.call(this,e)},t.prototype.removePrevSegment=function(e,i){var r=e.segments[i-2],s=e.segments[i+1];if(s&&!((s.length||0===s.length?s.length:z.distancePoints(s.points[0],s.points[1]))<=5)){var a=e.segments.slice(i-1,i+1),l={element:e,removeSegments:a,type:"Removal",cancel:!1};if(this.commandHandler.triggerEvent(Ce.segmentCollectionChange,l),!l.cancel){var h=e.segments[i+1];e.segments.splice(i-1,2);var c=this.selectedSegment;"Left"===c.direction||"Right"===c.direction?(r.points[r.points.length-1].x=h.points[0].x,h.points[0].y=r.points[r.points.length-1].y):(r.points[r.points.length-1].y=h.points[0].y,h.points[0].x=r.points[r.points.length-1].x),(c.length||0===c.length)&&this.findSegmentDirection(r),this.findSegmentDirection(h)}}},t.prototype.findSegmentDirection=function(e){e.direction&&(e.length||0===e.length)&&(e.length=z.distancePoints(e.points[0],e.points[e.points.length-1]),e.direction=z.direction(e.points[0],e.points[e.points.length-1]))},t.prototype.removeNextSegment=function(e,i){var l,h,r=this.selectedSegment,s=e.segments[i-1],o=e.segments[i+2],a=e.segments[i+1];if(a.length||0===a.length?(l=e.segments.slice(i,2),h={element:e,removeSegments:l,type:"Removal",cancel:!1},this.commandHandler.triggerEvent(Ce.segmentCollectionChange,h={element:e,removeSegments:l,type:"Removal",cancel:!1}),h.cancel||(e.segments.splice(i,2),"Top"===r.direction||"Bottom"===r.direction?(o.points[0].y=r.points[0].y,s.points[s.points.length-1].x=o.points[0].x):(o.points[0].x=r.points[0].x,s.points[s.points.length-1].y=o.points[0].y))):(l=e.segments.slice(i+1,1),this.commandHandler.triggerEvent(Ce.segmentCollectionChange,h={element:e,removeSegments:l,type:"Removal",cancel:!1}),h.cancel||(e.segments.splice(i+1,1),"Top"===r.direction||"Bottom"===r.direction?s.points[s.points.length-1].x=a.points[a.points.length-1].x:s.points[s.points.length-1].y=a.points[a.points.length-1].y,this.findSegmentDirection(s),r.length=r.direction=null)),s&&o&&!h.cancel&&(s.length=z.distancePoints(s.points[0],o.points[0]),s.direction=z.direction(s.points[0],o.points[0]),o.length||0===o.length)){o.length=z.distancePoints(s.points[s.points.length-1],o.points[o.points.length-1]);var c=s.points,d=o.points;o.direction=z.direction(c[c.length-1],d[d.length-1])}},t.prototype.addOrRemoveSegment=function(e,i,r){for(var s,o,a=[],l={segments:e.segments},h=0;h0?"Bottom":"Top":r>0?"Right":"Left",length:i.points[0].x===i.points[1].x?s:r},!0)),l.push(new bi(e,"segments",{type:"Orthogonal",direction:c,length:h/2},!0));var p={element:e,addSegments:l,type:"Addition",cancel:!1};return this.commandHandler.triggerEvent(Ce.segmentCollectionChange,p),p.cancel||(e.segments=l.concat(e.segments),a=o+2),a},t.prototype.insertFirstSegment=function(e,i,r,s,o){var a,l,d,u,h=[];if(e.sourcePortID&&i.length&&e.segments[0].points.length>2)for(var p=void 0,f=0;f0?"Bottom":"Top":r>0?"Right":"Left"),p=u,h.push(u)}else h.push(new bi(e,"segments",{type:"Orthogonal",direction:i.direction,length:i.length/3},!0)),"Bottom"===i.direction||"Top"===i.direction?(l=Math.abs(r),a=r>0?"Right":"Left"):(l=Math.abs(s),a=s>0?"Bottom":"Top"),u=new bi(e,"segments",{type:"Orthogonal",direction:a,length:l},!0),h.push(u);var y={element:e,addSegments:h,type:"Addition",cancel:!1};if(this.commandHandler.triggerEvent(Ce.segmentCollectionChange,y),!y.cancel){if(e.sourcePortID&&i.length&&e.segments[0].points.length>2)e.segments.splice(0,1),d=1;else{var S=e.segments[1];S&&S.length&&(S.length=a!==S.direction?S.length+l:S.length-l),d=2,i.length=2*i.length/3}e.segments=h.concat(e.segments)}return d},t.prototype.updateAdjacentSegments=function(e,i,r,s){var o=e.segments[parseInt(i.toString(),10)],a=o.points[o.points.length-1],h=!0;"Orthogonal"===o.type&&(o.points[0]=o.points[0],o.points[o.points.length-1]=a,e.segments[i-1]&&(h=this.updatePreviousSegment(r,s,e,i)),e.segments.length-1>i&&h&&this.updateNextSegment(e,o,e.segments[i+1],r,s))},t.prototype.addTerminalSegment=function(e,i,r,s,o){var l,h,c,d,a=e.segments.indexOf(i),u=[],p=e.segments.pop(),f=e.segments[e.segments.length-1];l=f&&"Orthogonal"===f.type?f:null;for(var g=0;g0&&"Left"===o.direction?c.middleLeft:c.middleRight,o.length>c.width/2?Math.abs(a.length)0&&"Top"===o.direction?c.topCenter:c.bottomCenter,o.length>c.height/2?Math.abs(a.length)1)for(var a=0,l=this.diagram.views;a0)for(var e=t===Ce.onUserHandleMouseLeave?this.previousAction:this.action,i={element:void 0},r=0;r0)for(var r={element:void 0},s=void 0,o=void 0,a=0;a-1&&(o=s,this.previousTarget=i,this.targetItem=e),o===e.fixedUserHandles[parseInt(a.toString(),10)].id&&(r.element=e.fixedUserHandles[parseInt(a.toString(),10)],this.userHandle(t,a,r,e))},n.prototype.mouseDown=function(t){if(!0!==this.inAction||!(this.tool instanceof $I||this.tool instanceof pa)){this.focus=!0;var e=t.touches,i=!!document.getElementsByClassName("e-dragclone")[0];if(this.isMouseOnScrollBar(t)&&!i)return this.isScrolling=!0,void t.preventDefault();if(this.checkFixedUserHandleEvent(Ce.onFixedUserHandleMouseDown,this.targetItem,this.previousTarget),this.checkUserHandleEvent(Ce.onUserHandleMouseDown),!this.checkEditBoxAsTarget(t)&&Yv(this.diagram)||Oc(this.diagram)&&!UI(this.diagram))if(("Select"===this.action||"Drag"===this.action)&&this.diagram.updatePortVisibility(this.hoverElement,hi.Hover,!0),!(this.tool instanceof Rh||this.tool instanceof Hh)||2!==t.button&&2!==t.buttons)if(!0===this.inAction&&!0===this.isMouseDown&&(this.tool instanceof Rh||this.tool instanceof Hh))this.isMouseDown=!0,this.eventArgs={},this.getMouseEventArgs(this.currentPosition,this.eventArgs),this.eventArgs.position=this.currentPosition,this.tool.mouseDown(this.eventArgs);else{this.isMouseDown=!0,this.currentPosition=this.prevPosition=this.getMousePosition(t),this.eventArgs={},this.diagram.textEditing&&!this.isMouseOnScrollBar(t)&&(this.diagram.endEdit(),this.diagram.textEditing=!1,"Canvas"===this.diagram.mode&&1!==this.diagram.scroller.currentZoom&&this.diagram.refreshDiagramLayer());var s=this.getTargetElement();this.action=this.diagram.findActionToBeDone(s.obj,s.sourceElement,this.currentPosition,s.target);var o=this.isMetaKey(t);o&&t.shiftKey&&this.diagram.connectorEditingToolModule?this.action="SegmentEnd":(o||t.shiftKey)&&(Vv(this.diagram)||Wv(this.diagram))&&(this.action="Select"),this.tool=this.diagram.getTool(this.action),this.tool||(this.action="Select",this.tool=this.diagram.getTool(this.action)),this.getMouseEventArgs(this.currentPosition,this.eventArgs),(o||t.shiftKey)&&(this.eventArgs.info=o&&t.shiftKey?{ctrlKey:o,shiftKey:t.shiftKey}:{ctrlKey:!0}),this.eventArgs.position=this.currentPosition;var l=this.diagram.selectedItems.nodes;if(this.tool.mouseDown(this.eventArgs),this.diagram.selectedItems.canToggleSelection&&l&&this.diagram.selectedItems.nodes&&this.tool instanceof ua)for(var h=0;h=2&&(this.touchStartList=VF(this.touchStartList,0,e)),e||t.preventDefault())}else this.inAction=!1,this.tool.mouseUp(this.eventArgs);!this.isForeignObject(t.target)&&!this.isForeignObject(t.target,!0)&&!e&&t.preventDefault()}},n.prototype.mouseMoveExtend=function(t,e){(this.tool instanceof Rh||this.tool instanceof Hh)&&this.tool.mouseMove(this.eventArgs),this.diagram.scrollSettings.canAutoScroll?this.checkAutoScroll(t):this.blocked||this.tool.mouseMove(this.eventArgs),this.eventArgs.target&&(this.hoverElement=this.eventArgs.target);var i=!((this.eventArgs.target instanceof te||this.eventArgs.target instanceof de)&&(e instanceof te||e instanceof de));this.tool instanceof zd&&this.diagram.updatePortVisibility(this.hoverElement instanceof te||this.hoverElement instanceof de?this.hoverElement:this.hoverNode,hi.Connect|hi.Hover,i),this.hoverElement instanceof te&&this.hoverNode instanceof te&&this.hoverNode&&this.hoverNode.id!==this.hoverElement.id&&this.diagram.updatePortVisibility(this.hoverNode,hi.Connect|hi.Hover,!0),this.hoverElement instanceof de&&this.hoverElement.ports.length>0&&this.diagram.updatePortVisibility(this.hoverElement,hi.Connect|hi.Hover,!0),this.previousElement instanceof te&&this.hoverElement&&this.previousElement.id!==this.hoverElement.id&&this.diagram.updatePortVisibility(this.previousElement,hi.Connect|hi.Hover,!0),this.previousElement=this.hoverElement,""!==this.diagram.tooltip.content&&(this.hoverElement=null),this.hoverNode=i?null:e},n.prototype.checkAction=function(t){if("LabelSelect"===this.action&&this.eventArgs.sourceWrapper&&(this.eventArgs.sourceWrapper instanceof ni||this.eventArgs.sourceWrapper instanceof Jn)){var e=this.commandHandler.findTarget(this.eventArgs.sourceWrapper,this.eventArgs.source);!_r(this.diagram,e,!1,this.eventArgs.sourceWrapper)&&to(e)&&(this.action="LabelDrag",this.tool=this.getTool(this.action),this.tool.mouseDown(this.initialEventArgs))}else to(t)&&Ad(t)&&this.initialEventArgs&&this.initialEventArgs.source&&"Select"===this.action&&(!_r(this.diagram,this.eventArgs.source,!1)&&this.eventArgs.source instanceof si&&this.getMouseEventArgs(this.currentPosition,this.eventArgs),(!(t instanceof de)||t instanceof de&&!(wr(this.currentPosition,t.sourcePoint,t.hitPadding)||wr(this.currentPosition,t.targetPoint,t.hitPadding)))&&(this.action="Drag"),this.tool=this.getTool(this.action),this.tool.mouseDown(this.initialEventArgs))},n.prototype.isSwimlaneElements=function(t){return!(t&&(t.isLane||t.isPhase||t.isHeader))},n.prototype.mouseMove=function(t,e){if(this.focus=!0,this.isScrolling)t.preventDefault();else if(Yv(this.diagram)||Oc(this.diagram)&&!UI(this.diagram)){this.currentPosition=this.getMousePosition(t);var i=this.diagram.findObjectsUnderMouse(this.currentPosition),r=this.diagram.findObjectUnderMouse(i,this.action,this.inAction);!function nse(n,t){n.rulerSettings.showRulers&&(n.hRuler.drawRulerMarker(n.hRuler.element,t,n.scroller.horizontalOffset),n.vRuler.drawRulerMarker(n.vRuler.element,t,n.scroller.verticalOffset))}(this.diagram,this.currentPosition);var s=!1,o=void 0;if("touchmove"===t.type&&(e=t.touches)&&e.length>1&&(this.touchMoveList=VF(this.touchMoveList,0,e),"PinchZoom"!==this.action&&(s=!0)),!1===z.equals(this.currentPosition,this.prevPosition)||this.inAction){if(!1===this.isMouseDown||s){this.eventArgs={};var a=null,l=void 0;if(null!==r){if((a=this.diagram.findElementUnderMouse(r,this.currentPosition,this.diagram))&&(l=this.commandHandler.findTarget(a,r)),(l instanceof Zn||l instanceof Nr)&&(l.tooltip&&""!==l.tooltip.content||(l=r)),l!==this.hoverElement){var h=this.getContent();this.hoverElement&&"Auto"===this.hoverElement.tooltip.openOn&&""!==h&&this.elementLeave(),this.diagram.updatePortVisibility(this.hoverElement,hi.Hover,!0),r instanceof te&&(this.hoverNode=r);var c=!0;!this.isSwimlaneElements(r)&&this.hoverElement&&this.isSwimlaneElements(this.hoverElement)&&(c=!1),this.hoverElement=c?r:this.hoverElement;var d,u=void 0;(d=this.diagram.findElementUnderMouse(r,this.currentPosition,this.diagram))instanceof Ke&&((u=this.commandHandler.findTarget(d,r))instanceof Es||u instanceof Ac)&&this.hoverElement.constraints&ri.ToolTip&&(this.hoverElement=u);var p=void 0;d instanceof ni&&((p=this.commandHandler.findTarget(d,r))instanceof Zn||p instanceof Nr)&&p.constraints&Lr.Tooltip&&(this.hoverElement=p),c?this.elementEnter(this.currentPosition,!1):this.hoverElement=r}else this.hoverElement&&this.hoverElement===l&&this.hoverElement.tooltip.content&&void 0!==this.diagram.tooltipObject&&"Mouse"===this.hoverElement.tooltip.relativeMode&&this.setTooltipOffset(this.currentPosition);a&&(o=this.commandHandler.findTarget(a,r))}this.action=this.diagram.findActionToBeDone(r,a,this.currentPosition,o),this.checkFixedUserHandleEvent(Ce.onFixedUserHandleMouseEnter,r,a),this.checkUserHandleEvent(Ce.onUserHandleMouseEnter),this.checkPreviousAction(),this.getMouseEventArgs(this.currentPosition,this.eventArgs),this.tool=this.getTool(this.action),this.mouseEvents(),this.tool instanceof pa||this.tool instanceof Hh||this.tool instanceof Rh?this.tool.mouseMove(this.eventArgs):e&&this.tool instanceof tm&&this.tool.mouseDown(this.eventArgs),this.updateCursor(),this.renderUmlHighLighter(this.eventArgs);var f=!1;this.hoverElement&&!(this.tool instanceof tm)&&r instanceof te&&this.isSwimlaneElements(r)&&(0===this.diagram.selectedItems.nodes.length||!_r(this.diagram,this.hoverElement))||this.hoverElement instanceof de||(f=!0),this.hoverElement&&!(this.tool instanceof tm)&&r instanceof de&&(0===this.diagram.selectedItems.connectors.length||!_r(this.diagram,this.hoverElement))||this.hoverElement instanceof te||(f=!0),this.diagram.updatePortVisibility(this.hoverElement,hi.Hover,f);var g=this.getContent();null===r&&this.hoverElement&&"Auto"===this.hoverElement.tooltip.openOn&&g&&(this.hoverElement=null,this.elementLeave()),s=!1}else{this.eventArgs.position=this.currentPosition,"Drag"===this.action&&!_r(this.diagram,this.eventArgs.source,!1)&&this.eventArgs.source instanceof si&&this.getMouseEventArgs(this.currentPosition,this.eventArgs),this.mouseEvents(),(t.ctrlKey||t.shiftKey)&&(this.eventArgs.info=t.ctrlKey&&t.shiftKey?{ctrlKey:t.ctrlKey,shiftKey:t.shiftKey}:{ctrlKey:!0}),this.checkAction(r);var y=this.getConnectorPadding(this.eventArgs);this.getMouseEventArgs(this.currentPosition,this.eventArgs,this.eventArgs.source,y),this.updateCursor(),this.inAction=!0,this.initialEventArgs=null,("Drag"===this.action||"Rotate"===this.action)&&(this.diagram.diagramActions=this.diagram.diagramActions|ee.Interactions);var S=this.diagram.scroller.getPageBounds();this.mouseMoveExtend(t,r);var b=this.diagram.scroller.getPageBounds();if(r&&(S.width!==b.width||S.height!==b.height||S.x!==b.x||S.y!==b.y)&&this.diagram.views&&this.diagram.views.overview){var M=this.diagram.views.overview;M.updateView(M)}}this.prevPosition=this.currentPosition,this.isForeignObject(t.target,!0)||t.preventDefault()}}},n.prototype.getContent=function(){var i,t=this.hoverElement instanceof te&&this.hoverElement.constraints&ie.Tooltip||this.hoverElement instanceof de&&this.hoverElement.constraints&qe.Tooltip||(this.hoverElement instanceof Es||this.hoverElement instanceof Ac)&&this.hoverElement.constraints&ri.ToolTip||(this.hoverElement instanceof Zn||this.hoverElement instanceof Nr)&&this.hoverElement.constraints&Lr.Tooltip,e=this.hoverElement;e instanceof te&&e.children&&e.children.length>0&&(i=this.findIntersectChild(e));var r=t?this.hoverElement.tooltip.content:this.diagram.tooltip.content;return i?i.tooltip.content:r},n.prototype.findIntersectChild=function(t){for(var e,i=new Ne(this.currentPosition.x,this.currentPosition.y,8,8),r=0;r1&&1===t.which&&!function one(n){return!!(n&ee.PreventClearSelection)}(this.diagram.diagramActions)&&(c=!1,this.commandHandler.clearSelection()),(!_r(this.diagram,h)||!c)&&(this.commandHandler.selectObjects([h],void 0,a),this.diagram.selectedItems.canToggleSelection)){var d=this.diagram.selectedItems.nodes;d?d[0].parentObj instanceof Fd&&(s=!0):this.diagram.selectedItems.connectors.length>0&&(s=!0)}}var u=!1,p=this.updateContainerProperties(),f=void 0;if(this.addUmlNode(),this.inAction=!1,this.isMouseDown=!1,this.diagram.selectedObject.helperObject&&(f=this.updateContainerBounds()),this.tool&&(this.tool.prevPosition||this.tool instanceof eF)){this.eventArgs.position=this.currentPosition;var g=this.getConnectorPadding(this.eventArgs);this.getMouseEventArgs(this.currentPosition,this.eventArgs,this.eventArgs.source,g);var v=this.isMetaKey(t);if((v||t.shiftKey)&&(this.eventArgs.info=v&&t.shiftKey?{ctrlKey:v,shiftKey:t.shiftKey}:{ctrlKey:!0}),this.diagram.diagramActions&ee.Interactions&&(this.diagram.diagramActions=this.diagram.diagramActions&~ee.Interactions),this.eventArgs.clickCount=t.detail,this.diagram.selectedObject.helperObject&&(this.tool instanceof ua||this.tool instanceof Rd)){if(this.diagram.selectedObject.actualObject&&""!==this.diagram.selectedObject.actualObject.parentId){var S=this.diagram.getObject(this.diagram.selectedObject.actualObject.parentId);S&&S.isLane&&(this.commandHandler.isContainer=!0)}(u=this.diagram.lineRoutingModule&&this.diagram.nameTable.helper&&this.eventArgs.target&&this.eventArgs.target.isLane&&(this.eventArgs.source instanceof si&&this.eventArgs.source.nodes.length>0&&""===this.eventArgs.source.nodes[0].parentId||""===this.eventArgs.source.parentId))&&(this.diagram.diagramActions=this.diagram.diagramActions|ee.PreventLaneContainerUpdate),this.tool.mouseUp(this.eventArgs,p.isPreventHistory)}else{if(this.diagram.selectedItems.canToggleSelection){var b=void 0,M=void 0;if(this.diagram.selectedItems.nodes.length>0)for(var w=0;w1&&D[0].id===i[parseInt(w.toString(),10)].id||r.length>0)&&(M=!0);!this.isSwimlaneSelected&&!s&&!M&&this.tool instanceof ua&&"Select"===this.currentAction&&(!b||this.diagram.selectedItems.connectors.length>0)&&this.commandHandler.clearSelection(!0)}this.isSwimlaneSelected=!1,this.tool.mouseUp(this.eventArgs),this.diagram.checkMenu&&(-1!==window.navigator.userAgent.indexOf("Linux")||-1!==window.navigator.userAgent.indexOf("X11"))&&(!t.pageY&&t instanceof TouchEvent&&t.changedTouches?(window.getSelection().removeAllRanges(),this.diagram.contextMenuModule.contextMenu.open(t.changedTouches[0].pageY,t.changedTouches[0].pageX,this.diagram.element),t.preventDefault()):this.diagram.contextMenuModule.contextMenu.open(t.pageY,t.pageX,this.diagram.element),this.diagram.checkMenu=!1)}p.hasStack&&this.diagram.endGroupAction()}if(f&&this.diagram.endGroupAction(),this.updateContainerBounds(!0),2!==this.eventArgs.clickCount&&(this.commandHandler.updateSelectedNodeProperties(this.eventArgs.source),u)){this.diagram.diagramActions=this.diagram.diagramActions&~ee.PreventLaneContainerUpdate;var A=this.eventArgs.source instanceof si?this.eventArgs.source.nodes:[this.eventArgs.source];if(A)for(w=0;w0&&!N&&this.diagram.renderSelector(!0),!this.inAction&&!this.diagram.currentSymbol&&this.eventArgs){var T=this.getTargetElement();this.diagram.tool!==Ci.ZoomPan&&this.diagram.triggerEvent(Ce.click,{element:T.target instanceof Es?T.target:this.eventArgs.source||this.diagram,position:this.eventArgs.position,count:t.detail,actualObject:this.eventArgs.actualObject,button:0===t.button?"Left":1===t.button?"Middle":"Right"})}this.eventArgs={}}this.diagram.diagramActions=this.diagram.diagramActions&~ee.PreventLaneContainerUpdate,e&&this.updateAnnotation(this.diagram.selectedItems),this.eventArgs={},this.diagram.commandHandler.removeStackHighlighter()},n.prototype.isSwimlaneChild=function(t){if(t.shape&&"SwimLane"!==t.shape.type){var e=this.diagram.nameTable[t.parentId];if(!e)return!1;var i=e.parentId?this.diagram.nameTable[e.parentId]:e;return i&&i.shape&&"SwimLane"===i.shape.type}return!1},n.prototype.updateAnnotation=function(t){var e=t.nodes;if(e.length>0)for(var i=0;i0&&(a+=1),h.isPhase){l="Horizontal"===r.orientation?this.currentPosition.x-e.wrapper.bounds.x:this.currentPosition.y-(e.wrapper.bounds.y+r.header.height);var g={id:Qe(),offset:l,header:{annotation:{content:void 0===h.phases[0].header?"Phase":h.phases[0].header.annotation.content,style:void 0===h.phases[0].header?{}:h.phases[0].header.annotation.style}},style:void 0===h.phases[0]?{}:h.phases[0].style};this.diagram.addPhases(e,[g])}else{var v={id:Qe(),style:h.lanes[0].style,header:{annotation:{content:h.lanes[0].header.annotation.content,style:h.lanes[0].header.annotation.style},style:h.lanes[0].header.style}};if("Horizontal"===h.orientation?v.height=h.lanes[0].height:v.width=h.lanes[0].width,"Horizontal"===r.orientation?(s=i.rowIndex?i.rowIndex:this.diagram.nameTable[i.parentId].rowIndex,i.wrapper.offsetYs)v.header.width=r.lanes[parseInt(s.toString(),10)].header.width,v.header.height=r.lanes[parseInt(s.toString(),10)].header.height;else{var S=void 0;S="Horizontal"===r.orientation?i.rowIndex<3?0:s-a-1:s-1,v.header.width=r.lanes[parseInt(S.toString(),10)].header.width,v.header.height=r.lanes[parseInt(S.toString(),10)].header.height}f&&("height"===f?(v.width=v.height,delete v.height):(v.height=v.width,delete v.width)),this.diagram.addLanes(e,[v],"Horizontal"===r.orientation?s-a:s)}this.commandHandler.select(e)}else if(h.isLane){var b={id:Qe(),width:t.width,height:t.height,addInfo:t.addInfo,shape:{type:"SwimLane",header:{annotation:{content:void 0===h.header?"Header":h.header.annotation.content,style:void 0===h.header?{}:h.header.annotation.style},height:50,style:h.header?h.header.style:h.lanes[0].header.style},phases:[{id:Qe(),header:{annotation:{content:void 0===h.phases||void 0===h.phases[0].header?"Phase":h.phases[0].header.annotation.content,style:void 0===h.phases||void 0===h.phases[0].header?{}:h.phases[0].header.annotation.style},style:void 0===h.phases||void 0===h.phases[0].header?{}:h.phases[0].header.style},style:void 0===h.phases?{}:h.phases[0].style}],lanes:[{id:Qe(),height:t.height,width:t.width,style:h.lanes[0].style,header:{annotation:{content:h.lanes[0].header.annotation.content,style:h.lanes[0].header.annotation.style},style:h.lanes[0].header.style}}],orientation:h.orientation}};"Vertical"===h.orientation&&(b.width+=20),b.offsetX=this.currentPosition.x+b.width/2,b.offsetY=this.currentPosition.y+b.height/2,b.style=t.style,this.diagram.add(b)}},n.prototype.mouseLeave=function(t){this.tool&&this.inAction&&this.tool.mouseLeave(this.eventArgs),this.diagram.selectedObject.helperObject&&(this.updateContainerProperties(),this.updateContainerBounds()&&this.diagram.endGroupAction()),this.eventArgs&&this.eventArgs.source&&(this.diagram.updatePortVisibility(this.eventArgs.source,hi.Hover,!0),this.hoverElement=null),this.eventArgs&&!this.eventArgs.source&&this.hoverElement&&(this.hoverElement=null),this.tool instanceof zd&&this.eventArgs&&this.eventArgs.target&&this.eventArgs.target instanceof te&&(this.diagram.updatePortVisibility(this.eventArgs.target,hi.Hover|hi.Connect,!0),this.hoverElement=null);var i=this.diagram.selectedItems;i&&i.wrapper&&(hm(this.diagram,i)||this.diagram.renderSelector(!0)),(this.diagram.diagramActions&ee.Interactions||this.diagram.diagramActions&ee.ToolAction)&&(this.diagram.diagramActions=this.diagram.diagramActions&~ee.ToolAction),this.isMouseDown=!1,this.focus=!1,this.touchStartList=null,this.touchMoveList=null,this.elementLeave(),this.commandHandler.removeSnap(),this.inAction=!1,this.eventArgs={},this.diagram.selectedObject&&this.diagram.selectedObject.helperObject&&(this.diagram.remove(this.diagram.selectedObject.helperObject),this.diagram.selectedObject={helperObject:void 0,actualObject:void 0}),this.tool=null,function rse(){var t,e,n=document.getElementsByClassName("e-d-ruler-marker");if(n&&n.length>0)for(e=n.length-1;e>=0;e--)(t=n[parseInt(e.toString(),10)])&&t.parentNode.removeChild(t)}(),"Rotate"===this.action&&this.diagram.diagramCanvas.classList.remove("e-diagram-rotate"),t.preventDefault()},n.prototype.mouseWheel=function(t){this.diagram.blazorActions|=on.interaction;var e={event:t,cancel:!1};if(this.diagram.triggerEvent(Ce.mouseWheel,e),!e.cancel){var i=t.wheelDelta>0||-40*t.detail>0,r=this.getMousePosition(t);if(this.diagram.tooltipObject.close(),this.isMetaKey(t)){var o=this.diagram.scrollSettings.zoomFactor;this.diagram.zoomTo(i?{type:"ZoomIn",zoomFactor:o,focusPoint:r}:{type:"ZoomOut",zoomFactor:o,focusPoint:r}),t.preventDefault()}else{var a=this.diagram.scroller.horizontalOffset,l=this.diagram.scroller.verticalOffset,h=i?10:-10;this.tool&&(this.tool instanceof Rh||this.tool instanceof Hh)&&(this.eventArgs={},this.getMouseEventArgs(r,this.eventArgs),this.eventArgs.position=r,this.tool.mouseWheel(this.eventArgs)),this.diagram.scrollActions|=ca.Interaction;var c=!0;if(t.isTrusted){var d=!1;(Math.abs(t.deltaY)<100&&-0===Math.abs(t.deltaX)||Math.abs(t.deltaX)<100&&-0===Math.abs(t.deltaY))&&(d=!0);var u=!1;(0!==t.deltaX||0!==t.deltaY)&&(u=navigator.userAgent.includes("Macintosh")),u?Math.abs(t.deltaX)>Math.abs(t.deltaY)?(t.shiftKey||t.deltaX&&-0!==t.deltaX&&(d||!u))&&this.diagram.scroller.zoom(1,h,0,r,c,void 0,d):t.deltaY&&-0!==t.deltaY&&(d||!u)&&this.diagram.scroller.zoom(1,0,h,r,c,void 0,d):t.shiftKey||t.deltaX&&-0!==t.deltaX&&(d||!u)?this.diagram.scroller.zoom(1,h,0,r,c,void 0,d):t.deltaY&&-0!==t.deltaY&&(d||!u)&&this.diagram.scroller.zoom(1,0,h,r,c,void 0,d)}else t.shiftKey||t.deltaX&&-0!==t.deltaX?this.diagram.scroller.zoom(1,h,0,r,c):this.diagram.scroller.zoom(1,0,h,r,c);this.diagram.scrollActions&=~ca.Interaction,(a!==this.diagram.scroller.horizontalOffset||l!==this.diagram.scroller.verticalOffset)&&t.preventDefault()}if(this.diagram.textEditing){if(this.diagram.isTriggerEvent=!0,this.diagram.activeLabel.parentId){var f=this.diagram.getObject(this.diagram.activeLabel.parentId);this.diagram.startTextEdit(f,this.diagram.activeLabel.id)}this.diagram.isTriggerEvent=!1}this.diagram.blazorActions=this.diagram.blazorActions&~on.interaction}},n.prototype.keyDown=function(t){if(t.fromMouseEvents&&(t.ctrlKey&&(this.keyArgs.keyModifiers=1),t.shiftKey&&(this.keyArgs.keyModifiers=4),t.shiftKey&&t.ctrlKey&&(this.keyArgs.keyModifiers=5)),!(this.diagram.diagramActions&ee.TextEdit)&&!this.checkEditBoxAsTarget(t)||"Escape"===t.key||27===t.keyCode){var i=void 0,r=t.keyCode?t.keyCode:t.which,s=t.key;("ArrowDown"===s||"ArrowUp"===s||"ArrowLeft"===s||"ArrowRight"===s)&&(this.isNudgeKey=!0);var o=this.isMetaKey(t);if(this.diagram.commandManager&&this.diagram.commands)for(var l=0,h=Object.keys(this.diagram.commands);l4&&(S({keyDownEventArgs:KeyboardEvent,parameter:i.parameter,type:"KEYDOWN"}),this.keyCount=0)),this.isKeyUp=!1):S({keyDownEventArgs:KeyboardEvent,parameter:i.parameter})}break}}}}this.keyArgs={element:this.diagram.selectedItems,key:t.key,keyCode:t.keyCode?t.keyCode:t.which},this.getKeyModifier(this.keyArgs,t),this.diagram.diagramActions&ee.TextEdit&&this.getlabel(this.keyArgs,t),this.diagram.triggerEvent(Ce.keyDown,this.keyArgs)},n.prototype.getlabel=function(t,e){var i=this.diagram.activeLabel;t.target=this.diagram.element.id+"_editBox";var r=this.diagram.nameTable[i.parentId];if(document.getElementById(this.diagram.element.id+"_editBox")){t.text=document.getElementById(this.diagram.element.id+"_editBox").value;for(var s=0;s=this.diagram.scroller.viewPortWidth-18?r="right":e.x+this.diagram.scroller.horizontalOffsetthis.diagram.scroller.viewPortHeight-18?r="bottom":e.y+this.diagram.scroller.verticalOffset0&&(s=this.findIntersectChild(this.hoverElement)),"Auto"===this.hoverElement.tooltip.openOn&&""!==r&&Dx(this.diagram,s||(i?this.hoverElement:void 0)),this.hoverElement.tooltip.content&&("Mouse"===this.hoverElement.tooltip.relativeMode?this.setTooltipOffset(t):(this.diagram.tooltipObject.offsetX=0,this.diagram.tooltipObject.offsetY=0));var o=this.diagram.findObjectsUnderMouse(this.currentPosition),a=this.diagram.findObjectUnderMouse(o,this.action,this.inAction);if(null!==a){var l=void 0;this.hoverElement.tooltip.isSticky&&(this.diagram.tooltipObject.isSticky=!0),a instanceof te&&a.children&&a.children.length>0&&(a=s||a),l=a.ports&&(this.hoverElement instanceof Es||this.hoverElement instanceof Ac)||a.annotations&&(this.hoverElement instanceof Zn||this.hoverElement instanceof Nr)?document.getElementById(a.id+"_"+this.hoverElement.id):document.getElementById(a.id+(a.shape&&a.shape instanceof cm?"_content_native_element":"_groupElement")),"Auto"===this.hoverElement.tooltip.openOn&&""!==r&&(this.diagram.tooltipObject.close(),this.diagram.tooltipObject.openOn=this.hoverElement.tooltip.openOn,this.diagram.tooltipObject.dataBind()),function Kre(n,t){var e=0;return n instanceof de?n.constraints&qe.Tooltip?e=n.constraints&qe.Tooltip:n.constraints&qe.InheritTooltip&&(e=t.constraints&rt.Tooltip):n instanceof Es||n instanceof Ac?n.constraints&ri.ToolTip?e=n.constraints&ri.ToolTip:n.constraints&ri.InheritTooltip&&(e=t.constraints&rt.Tooltip):n instanceof Zn||n instanceof Nr?n.constraints&Lr.Tooltip&&(e=n.constraints&Lr.Tooltip):n.constraints&ie.Tooltip?e=n.constraints&ie.Tooltip:n.constraints&ie.InheritTooltip&&(e=t.constraints&rt.Tooltip),e}(this.hoverElement,this.diagram)&&"Auto"===this.hoverElement.tooltip.openOn&&(this.diagram.tooltipObject.target=this.hoverElement.id,this.diagram.tooltipObject.open("Mouse"===this.hoverElement.tooltip.relativeMode?this.diagram.element:l))}}},n.prototype.elementLeave=function(){this.diagram.tooltipObject&&!this.diagram.tooltipObject.isSticky&&"Custom"!==this.diagram.tooltipObject.openOn&&this.diagram.tooltipObject.close()},n.prototype.setTooltipOffset=function(t){var e=function Mse(n,t,e,i){var o="Mouse"===(!(e instanceof te?e.constraints&ie.InheritTooltip:e instanceof de?e.constraints&qe.InheritTooltip:e.constraints&ri.InheritTooltip)&&(e instanceof te?e.constraints&ie.Tooltip:e instanceof de?e.constraints&qe.Tooltip:e.constraints&ri.ToolTip)?e.tooltip.relativeMode:n.tooltip.relativeMode);"Mouse"===i?o=!0:"Object"===i&&(o=!1);var a=function wse(n,t,e,i){var o,r={},s=document.getElementById(e.element.id);if(n instanceof te||n instanceof de)o=n.wrapper.bounds;else{var a=e.findObjectsUnderMouse(t),l=e.findObjectUnderMouse(a,"Select",!1);o=e.findElementUnderMouse(l,t,e).bounds}var c=s.getBoundingClientRect();switch(e.tooltipObject.position){case"BottomCenter":r=Hc(t,o.bottomCenter,e,i,c.width/2,c.height);break;case"BottomLeft":case"LeftBottom":r=Hc(t,o.bottomLeft,e,i,0,c.height);break;case"BottomRight":case"RightBottom":r=Hc(t,o.bottomRight,e,i,c.width,c.height);break;case"LeftCenter":r=Hc(t,o.middleLeft,e,i,0,c.height/2);break;case"LeftTop":case"TopLeft":r=Hc(t,o.topLeft,e,i,0,0);break;case"RightCenter":r=Hc(t,o.middleRight,e,i,c.width,c.height/2);break;case"RightTop":case"TopRight":r=Hc(t,o.topRight,e,i,c.width,0);break;case"TopCenter":r=Hc(t,o.topCenter,e,i,c.width/2,0)}return r}(e,t,n,o),l=qa(n);return{x:a.x+l.width,y:a.y+l.height}}(this.diagram,t,this.hoverElement);this.diagram.tooltipObject.offsetX=e.x,this.diagram.tooltipObject.offsetY=e.y},n.prototype.altKeyPressed=function(t){return!!(t&pt.Alt)},n.prototype.ctrlKeyPressed=function(t){return!!(t&pt.Control)},n.prototype.shiftKeyPressed=function(t){return!!(t&pt.Shift)},n.prototype.scrolled=function(t){this.diagram.updateScrollOffset()},n.prototype.doubleClick=function(t){if(Yv(this.diagram)){var e=void 0,i=this.diagram.findObjectsUnderMouse(this.currentPosition),r=this.diagram.findObjectUnderMouse(i,this.action,this.inAction);if(null!==r&&Yv(this.diagram))if(e=this.diagram.findElementUnderMouse(r,this.currentPosition,this.diagram),this.tool&&(this.tool instanceof Rh||this.tool instanceof Hh))this.tool.mouseUp(this.eventArgs),this.isMouseDown=!1,this.eventArgs={},this.tool=null,t.preventDefault();else{var o=this.diagram.commandHandler.getObjectLayer(r.id);!o||o.lock||!o.visible||this.diagram.diagramActions&ee.TextEdit||this.diagram.startTextEdit(r,e instanceof ni?e.id.split(r.id+"_")[1]:void 0)}this.diagram.triggerEvent(Ce.doubleClick,{source:r||this.diagram,position:this.currentPosition,count:t.detail})}},n.prototype.itemClick=function(t,e){var i=t;return cs(this.diagram,i,!0)?i:null},n.prototype.inputChange=function(t){var i,s,o,a,l,h,c,d,u,p=document.getElementById(this.diagram.element.id+"_editBox"),f=document.getElementById(this.diagram.element.id+"_editTextBoxDiv"),g=p.value,v=g.split("\n");(!(a=this.diagram.selectedItems.nodes[0]?this.diagram.selectedItems.nodes[0]:this.diagram.selectedItems.connectors[0])&&this.tool instanceof ZI||a&&"SwimLane"===a.shape.type)&&(a=this.diagram.nameTable[this.diagram.activeLabel.parentId]),a&&("Text"!==a.shape.type&&a.annotations.length>0||"Text"===a.shape.type)&&(c=HF((o=this.diagram.getWrapper(a.wrapper,this.diagram.activeLabel.id)).style,g,void 0,void 0,i=(i=a.wrapper.bounds.width90?i:90),s=Number(p.style.fontSize.split("px")[0]),v.length>1&&""===v[v.length-1]&&(c.height=c.height+s),d=this.diagram.scroller.transform,u=P3(this.diagram)?d.scale:1,l=(12>c.height?12:c.height)*u,f.style.left=(o.bounds.center.x+d.tx)*d.scale-(h=(90>(h=c.width)?90:h)*u)/2-2.5+"px",f.style.top=(o.bounds.center.y+d.ty)*d.scale-l/2-3+"px",f.style.width=h+"px",f.style.height=l+"px",p.style.minHeight="12px",p.style.minWidth="90px",p.style.width=h+"px",p.style.height=l+"px")},n.prototype.isAddTextNode=function(t,e){return!(!(this.tool instanceof ZI||e)||(this.tool=null,t&&!_I(this.diagram)&&(this.diagram.drawingObject=void 0,this.diagram.currentDrawingObject=void 0),MF(this.diagram.nodes,t.id)||MF(this.diagram.connectors,t.id)))},n.prototype.checkEditBoxAsTarget=function(t){return!(!t.target||t.target.id!==this.diagram.element.id+"_editBox")},n.prototype.getMouseEventArgs=function(t,e,i,r){var s,o,a;if(e.position=t,i?(o=this.diagram.findObjectsUnderMouse(this.currentPosition,i),s=this.diagram.findTargetObjectUnderMouse(o,this.action,this.inAction,e.position,i)):"Drag"===this.action||"ConnectorSourceEnd"===this.action||"SegmentEnd"===this.action||"OrthoThumb"===this.action||"BezierSourceThumb"===this.action||"BezierTargetThumb"===this.action||"ConnectorTargetEnd"===this.action||-1!==this.action.indexOf("Rotate")||-1!==this.action.indexOf("Resize")?(s=this.diagram.selectedItems,!this.diagram.currentSymbol&&"Drag"===this.action&&s&&this.diagram.selectedItems.nodes.length>0&&"SwimLane"===this.diagram.selectedItems.nodes[0].shape.type&&(o=this.diagram.findObjectsUnderMouse(this.currentPosition),s=this.diagram.findObjectUnderMouse(o,this.action,this.inAction))):(o=this.diagram.findObjectsUnderMouse(this.currentPosition),s=this.diagram.findObjectUnderMouse(o,this.action,this.inAction)),s&&s.isHeader&&(this.eventArgs.actualObject=s=this.diagram.nameTable[s.parentId]),s){var l=void 0,h=void 0,c=void 0;if(((a=this.diagram.findElementUnderMouse(s,this.currentPosition,this.diagram,r))&&s.ports&&s.ports.length&&!hb(s,a)||!a||!s)&&o&&o.length&&i instanceof si)for(l=i.connectors[0],c=o.length-1;c>=0;c--)if(((h=o[parseInt(c.toString(),10)])instanceof te||h instanceof de)&&l&&l.connectionPadding){if(a=this.diagram.findElementUnderMouse(s=h,this.currentPosition,this.diagram,r),l.constraints&qe.ConnectToNearByPort&&s&&s.ports&&s.ports.length&&hb(s,a))break;if((h instanceof te||h instanceof de)&&l&&l.connectionPadding&&h.wrapper.outerBounds.containsPoint(this.currentPosition)&&l.constraints&qe.ConnectToNearByNode&&!(l.constraints&qe.ConnectToNearByPort)){a=this.diagram.findElementUnderMouse(s=h,this.currentPosition,this.diagram,0);break}}}return i?(e.target=s,e.targetWrapper=a):(e.source=s,e.sourceWrapper=a),e.actualObject=this.eventArgs.actualObject,e.source instanceof si&&void 0===e.actualObject&&(e.source.nodes.length>0||e.source.connectors.length>0)&&(e.actualObject=e.source.nodes.length>0?this.diagram.nameTable[e.source.nodes[0].id]:this.diagram.nameTable[e.source.connectors[0].id]),e.startTouches=this.touchStartList,e.moveTouches=this.touchMoveList,e},n.prototype.resetTool=function(){this.action="Select",this.hoverElement=null,this.hoverNode=null,this.tool=this.diagram.getTool(this.action),this.updateCursor()},n.prototype.updateTool=function(){this.eventArgs&&!this.eventArgs.position&&(this.action="Select")},n.prototype.getTool=function(t){switch(t){case"Select":return new em(this.commandHandler,!0);case"Drag":return new ua(this.commandHandler);case"Rotate":return new qx(this.commandHandler);case"LayoutAnimation":return new Une(this.commandHandler);case"FixedUserHandle":return new _ne(this.commandHandler,!0);case"Hyperlink":return new eF(this.commandHandler);case"ResizeSouthEast":case"ResizeSouthWest":case"ResizeNorthEast":case"ResizeNorthWest":case"ResizeSouth":case"ResizeNorth":case"ResizeWest":case"ResizeEast":return new Rd(this.commandHandler,t);case"ConnectorSourceEnd":case"ConnectorTargetEnd":case"BezierSourceThumb":case"BezierTargetThumb":return new zd(this.commandHandler,t);case"SegmentEnd":case"OrthoThumb":return new r_(this.commandHandler,t);case"Draw":var e="shape",i=function gse(n){var t;return n&&(n.type?t="Connector":n.shape&&!n.type&&(t="Node")),t}(this.diagram.drawingObject);if("Node"===i&&"Text"===this.diagram.drawingObject.shape.type)return new ZI(this.commandHandler);if("Connector"===i&&"Freehand"===this.diagram.drawingObject.type)return new Yne(this.commandHandler);if("Node"===i&&"Polygon"===this.diagram.drawingObject.shape[""+e]&&!this.diagram.drawingObject.shape.points)return new Rh(this.commandHandler);if("Node"===i||"Node"===i&&"Polygon"===this.diagram.drawingObject.shape[""+e]&&this.diagram.drawingObject.shape.points)return new $I(this.commandHandler,this.diagram.drawingObject);if("Connector"===i&&"Polyline"===this.diagram.drawingObject.type)return new Hh(this.commandHandler);if("Connector"===i)return new pa(this.commandHandler,"ConnectorSourceEnd",this.diagram.drawingObject);break;case"Pan":return new tm(this.commandHandler,!1);case"PinchZoom":return new tm(this.commandHandler,!0);case"PortDrag":return new ua(this.commandHandler,"Port");case"PortDraw":return new pa(this.commandHandler,"ConnectorSourceEnd",this.diagram.drawingObject);case"LabelSelect":return new em(this.commandHandler,!0,"LabelSelect");case"LabelDrag":return new jne(this.commandHandler);case"LabelResizeSouthEast":case"LabelResizeSouthWest":case"LabelResizeNorthEast":case"LabelResizeNorthWest":case"LabelResizeSouth":case"LabelResizeNorth":case"LabelResizeWest":case"LabelResizeEast":return new Vne(this.commandHandler,t);case"LabelRotate":return new Wne(this.commandHandler)}return null},n.prototype.getCursor=function(t){var e=this.diagram.selectedItems.annotation?this.diagram.selectedItems.wrapper.children[0]:this.diagram.selectedItems;return function Fne(n,t){if(t+=360,t%=360,-1===n.indexOf("Resize"))return Xx[""+n];var e=Xx[""+n];return t>=0&&t<25||t>=160&&t<=205||t>=340&&t<=360?e:t>=25&&t<=70||t>=205&&t<=250?"n-resize"===e||"s-resize"===e?"ne-resize":"nw-resize"===e||"se-resize"===e?"n-resize":"e-resize"===e||"w-resize"===e?"nw-resize":"e-resize":t>=70&&t<=115||t>=250&&t<=295?"n-resize"===e||"s-resize"===e?"e-resize":"nw-resize"===e||"se-resize"===e?"ne-resize":"e-resize"===e||"w-resize"===e?"n-resize":"nw-resize":t>=115&&t<=155||t>=295&&t<=340?"n-resize"===e||"s-resize"===e?"nw-resize":"nw-resize"===e||"se-resize"===e?"e-resize":"e-resize"===e||"w-resize"===e?"ne-resize":Xx[""+n]:"n-resize"}(t,this.diagram.selectedItems.annotation?e.rotateAngle+e.parentTransform:e.rotateAngle)},n.prototype.findElementUnderMouse=function(t,e,i,r){return this.objectFinder.findElementUnderSelectedItem(t,e,i,r)},n.prototype.findObjectsUnderMouse=function(t,e){return this.objectFinder.findObjectsUnderMouse(t,this.diagram,this.eventArgs,e)},n.prototype.findObjectUnderMouse=function(t,e,i){return this.objectFinder.findObjectUnderMouse(this.diagram,t,e,i,this.eventArgs,this.currentPosition)},n.prototype.findTargetUnderMouse=function(t,e,i,r,s){return this.objectFinder.findObjectUnderMouse(this.diagram,t,e,i,this.eventArgs,r,s)},n.prototype.findActionToBeDone=function(t,e,i,r){return function kne(n,t,e,i,r,s,o){if(s&&s.length>1&&r&&r.length>1)return"PinchZoom";if(i.currentSymbol)return"Drag";if("PortDraw"===i.eventHandler.action&&(i.tool&=~Ci.DrawOnce),(k3(i)||_I(i))&&i.drawingObject)return"Draw";if(Xa(i)&&(l=i.selectedItems).wrapper&&qr(l.constraints,"UserHandle"))for(var h=0,c=l.userHandles;h=50&&(l.x=(a.points[parseInt(h.toString(),10)].x+a.points[h+1].x)/2,l.y=(a.points[parseInt(h.toString(),10)].y+a.points[h+1].y)/2,wr(e,l,n.hitPadding?n.hitPadding:10)))return"OrthoThumb"}else RI(n)&&console.warn('[WARNING] :: Module "ConnectorEditing" is not available in Diagram component! You either misspelled the module name or forgot to load it.');return null}(g,l,e,i);if("OrthoThumb"===S)return S;if(qr(l.constraints,"ConnectorSourceThumb")&&PI(g)&&S||qr(l.constraints,"ConnectorTargetThumb")&&zI(g)&&S)return S}}else{var b=i.selectedItems.handleSize/2/i.scroller.currentZoom,M=10/i.scroller.currentZoom,w=Hi();qi(w,p.rotateAngle+p.parentTransform,p.offsetX,p.offsetY);var C=p.offsetX-p.pivot.x*p.actualSize.width,D=p.offsetY-p.pivot.y*p.actualSize.height,A={x:C+(.5===p.pivot.x?2*p.pivot.x:p.pivot.x)*p.actualSize.width/2,y:D-30/i.scroller.currentZoom};A=Je(w,A);var x=!!i.selectedItems.annotation,R=!(!x||!HI(i.selectedItems.annotation));if(qr(l.constraints,"Rotate")&&wr(e,A,M)&&i.selectedItems.thumbsConstraints&bt.Rotate){if(x&&R)return"LabelRotate";if(!x)return"Rotate"}if(u.Inflate(b),u.containsPoint(e)&&(S=function Pne(n,t,e,i,r,s){var o;return 1===n.selectedItems.nodes.length&&0===n.selectedItems.connectors.length&&n.selectedItems.nodes[0].container&&(o=function Hne(n,t,e,i,r){var s=10/n.scroller.currentZoom,o=40/n.scroller.currentZoom,a=n.selectedItems,l=t.actualSize.width,h=t.actualSize.height,c=new Ne(i,r,t.style.strokeWidth,h),d=new Ne(i+l,r,t.style.strokeWidth,h),u=new Ne(i,r,l,t.style.strokeWidth),p=new Ne(i,r+h,l,t.style.strokeWidth),f=cs(n,n.selectedItems.nodes[0],!0)?n.nameTable[n.selectedItems.nodes[0].parentId]:n.selectedItems.nodes[0];if(l>=o&&h>=o){if(fa(a.constraints,"ResizeEast",a.thumbsConstraints,a)&&d.containsPoint(e,s))return"ResizeEast";if(fa(a.constraints,"ResizeSouth",a.thumbsConstraints,a)&&p.containsPoint(e,s))return"ResizeSouth";if("Grid"!==f.container.type){if(fa(a.constraints,"ResizeWest",a.thumbsConstraints,a)&&c.containsPoint(e,s))return"ResizeWest";if(fa(a.constraints,"ResizeNorth",a.thumbsConstraints,a)&&u.containsPoint(e,s))return"ResizeNorth"}}return null}(n,t,e,r,s)),!o&&(!n.selectedItems.nodes[0]||!n.selectedItems.nodes[0].isPhase&&!n.selectedItems.nodes[0].isLane&&"SwimLane"!==n.selectedItems.nodes[0].shape.type)&&(o=function Bne(n,t,e,i,r,s){var o=40/n.scroller.currentZoom,a=n.selectedItems.handleSize/2/n.scroller.currentZoom,l=n.selectedItems,h=!!l.annotation;if(t.actualSize.width>=o&&t.actualSize.height>=o){if(fa(l.constraints,"ResizeSouthEast",l.thumbsConstraints,l)&&wr(e,Je(i,{x:r+t.actualSize.width,y:s+t.actualSize.height}),a))return h?"LabelResizeSouthEast":"ResizeSouthEast";if(fa(l.constraints,"ResizeSouthWest",l.thumbsConstraints,l)&&wr(e,Je(i,{x:r,y:s+t.actualSize.height}),a))return h?"LabelResizeSouthWest":"ResizeSouthWest";if(fa(l.constraints,"ResizeNorthEast",l.thumbsConstraints,l)&&wr(e,Je(i,{x:r+t.actualSize.width,y:s}),a))return h?"LabelResizeNorthEast":"ResizeNorthEast";if(fa(l.constraints,"ResizeNorthWest",l.thumbsConstraints,l)&&wr(e,Je(i,{x:r,y:s}),a))return h?"LabelResizeNorthWest":"ResizeNorthWest"}return fa(l.constraints,"ResizeEast",l.thumbsConstraints,l)&&wr(e,Je(i,{x:r+t.actualSize.width,y:s+t.actualSize.height/2}),a)?h?"LabelResizeEast":"ResizeEast":fa(l.constraints,"ResizeWest",l.thumbsConstraints,l)&&wr(e,Je(i,{x:r,y:s+t.actualSize.height/2}),a)?h?"LabelResizeWest":"ResizeWest":fa(l.constraints,"ResizeSouth",l.thumbsConstraints,l)&&wr(e,Je(i,{x:r+t.actualSize.width/2,y:s+t.actualSize.height}),a)?h?"LabelResizeSouth":"ResizeSouth":fa(l.constraints,"ResizeNorth",l.thumbsConstraints,l)&&wr(e,Je(i,{x:r+t.actualSize.width/2,y:s}),a)?h?"LabelResizeNorth":"ResizeNorth":null}(n,t,e,i,r,s)),o||null}(i,p,e,w,C,D),S))return S}}if(Oc(i)&&!n)return"Pan";if((o instanceof Es||o instanceof Ac)&&(!Oc(i)||Vv(i)||Wv(i))&&(S=function Rne(n,t,e,i){if(Ux(t)&&(ga(t,hi.Hover)||ga(t,hi.Visible))){if(t.constraints&ri.Drag)return"PortDrag"}else if(_x(t)&&(ga(t,hi.Hover)||ga(t,hi.Visible))&&t.constraints&ri.Draw){n.drawingObject={};var r={type:"Orthogonal",sourcePortID:t.id};return n.drawingObject=r,n.tool|=Ci.DrawOnce,n.currentDrawingObject=r,"PortDraw"}return"None"}(i,o),"None"!==S))return S;if((o instanceof Zn||o instanceof Nr)&&!Oc(i)&&Ad(o))return _r(i,o,void 0,t)&&to(o)?"LabelDrag":"LabelSelect";if(null!==n){if(!(n instanceof te||n instanceof de))return"Select";if(t&&t.id){var L=t.id.split(n.id)[1];if(L&&L.match("^_icon"))return"LayoutAnimation"}if(t&&t.id)for(var O=void 0,N=0;N-1)return"FixedUserHandle";if(t instanceof ni&&t.hyperlink.link)return"Hyperlink";if(!to(n)||!_r(i,n,!1)||void 0!==i.selectedItems.annotation)return n&&Oc(i)&&!UI(i)?"Pan":i.selectedItems.nodes.length&&i.selectedItems.nodes[0].isLane&&i.selectedItems.wrapper&&i.selectedItems.wrapper.bounds.containsPoint(e)?"Drag":"Select";if(n instanceof de&&!wr(e,n.sourcePoint,n.hitPadding)&&!wr(e,n.targetPoint,n.hitPadding)||!(n instanceof de))return"Drag"}return"Select"}(t,e,this.currentPosition,this.diagram,this.touchStartList,this.touchMoveList,r)},n.prototype.updateContainerBounds=function(t){var e=!1;if(this.diagram.selectedObject.helperObject&&this.diagram.selectedObject.actualObject instanceof te){var i=this.tool instanceof Rd,r=this.diagram.selectedObject.actualObject,s=this.diagram.nameTable[r.parentId];t?q3(this.diagram,r,this.currentPosition,i):((!s||s&&"SwimLane"!==s.shape.type)&&this.diagram.updateDiagramObject(r),e=function Ane(n,t,e,i){var r,o=!1;if(cs(n,t,!0)){n.protectPropertyChange(!0);var a=(r=n.nameTable[t.parentId]).wrapper;if(r&&"Canvas"===r.container.type){if(i||a.bounds.x<=e.x&&a.bounds.right>=e.x&&a.bounds.y<=e.y&&a.bounds.bottom>=e.y){var l=void 0,h=a.bounds.y,c=a.bounds.x,d=n.nameTable[r.parentId]||r;if("SwimLane"===d.shape.type)o=Kv(r,d,t,n,!0);else{var p=n.nameTable[r.parentId]||r,f=p.shape;l=p.wrapper,a.actualSize.widtha.outerBounds.x)&&(void 0!==r.rowIndex?(l.updateColumnWidth(r.columnIndex,a.outerBounds.width,!0),"Horizontal"===f.orientation&&f.phaseSize&&QI(p,n,a,r.columnIndex),Pc(n,p),n.drag(p,c-a.bounds.x,h-a.bounds.y)):n.scale(r,1+(a.outerBounds.width-a.actualSize.width)/a.actualSize.width,1,a.outerBounds.xa.outerBounds.y)&&(void 0!==r.rowIndex?(l.updateRowHeight(r.rowIndex,a.outerBounds.height,!0),n.drag(p,c-a.bounds.x,h-a.bounds.y)):n.scale(r,1,1+(a.outerBounds.height-a.actualSize.height)/a.actualSize.height,a.outerBounds.yi.y&&(h+=u>0?-1:1,u+=u>0?-1:1):i&&e.wrapper.offsetYi.x&&(h+=u>0?-1:1,u+=u>0?-1:1):i&&e.wrapper.offsetX1&&!(this.diagram.lineRoutingModule&&this.diagram.constraints&rt.LineRouting))for(var b=t.offsetX-this.diagram.selectedItems.offsetX,M=t.offsetY-this.diagram.selectedItems.offsetY,w=t.rotateAngle-this.diagram.selectedItems.rotateAngle,C=0;C-1){var x=c.children;x.splice(x.indexOf(o.id),1),this.diagram.nameTable[o.id].parentId="",i=!0,c.wrapper.children.splice(A,1)}}if(function One(n,t,e,i){var r=n,s=e.nameTable[r.parentId],o=e.nameTable[r.parentId];if(t&&o&&o.container&&"Stack"===o.container.type&&t.container&&"Stack"===t.container.type&&o.id!==t.parentId){var a=o.wrapper.children.indexOf(r.wrapper);a>-1&&(e.nameTable[r.id].parentId=t.id,o.wrapper.children.splice(a,1))}if(t&&t.parentId&&r.parentId&&"Drag"===i&&o.container&&"Stack"===o.container.type){var l=s.wrapper.children.indexOf(t.wrapper),h=s.wrapper.children.indexOf(r.wrapper),c={targetIndex:l,target:t,sourceIndex:h,source:n};s.wrapper.children.splice(h,1),s.wrapper.children.splice(l,0,r.wrapper),e.commandHandler.addHistoryEntry({type:"StackChildPositionChanged",redoObject:{targetIndex:h,target:t,sourceIndex:l,source:n},undoObject:c,category:"Internal"})}}(o,h,this.diagram,this.action),(c=cs(this.diagram,o)?this.diagram.nameTable[o.parentId]:this.diagram.nameTable[o.parentId]||o)&&c.container&&"Canvas"===c.container.type&&(c.wrapper.maxWidth=c.maxWidth=c.wrapper.actualSize.width,c.wrapper.maxHeight=c.maxHeight=c.wrapper.actualSize.height,e=!0),cs(this.diagram,o,!0)&&c&&"Canvas"===c.container.type)if(this.diagram.selectedItems.nodes.length>1)for(C=0;C0)for(var i=0;i0&&e.columnIndex>0||l&&e.isLane)){if("Horizontal"===t.container.orientation&&e.isPhase&&e.wrapper.width>e.maxWidth&&(e.maxWidth=e.wrapper.width,e.wrapper.maxWidth=e.wrapper.width),h.updateColumnWidth(e.columnIndex,r.width,!0,c),Wx(this.diagram,e,t),e.isPhase){var f=this.diagram.nameTable[""+t.shape.phases[e.columnIndex].header.id];f.maxWidth0?(r=new af(t,"",u),t.shape.classShape.attributes.push(r)):i.id.includes("_umlMethods")&&t.shape.classShape.methods.length>0&&(s=new um(t,"",u),t.shape.classShape.methods.push(s))),"Interface"===t.shape.classifier&&(i.id.includes("_umlProperty")&&t.shape.interfaceShape.attributes.length>0?(r=new af(t,"",u),t.shape.classShape.attributes.push(r)):i.id.includes("_umlMethods")&&t.shape.interfaceShape.methods.length>0&&(s=new um(t,"",u),t.shape.interfaceShape.methods.push(s))),"Enumeration"===t.shape.classifier&&i.id.includes("_umlMember")&&t.shape.enumerationShape.members.length>0){var p=new ub(t,"",u);t.shape.enumerationShape.members.push(p)}t.wrapper.children.indexOf(c.wrapper),this.diagram.enableServerDataBinding(!0),this.diagram.add(c),this.diagram.updateConnectorEdges(t),this.diagram.clearSelection(),this.diagram.select([this.diagram.nameTable[c.id]]),this.diagram.endGroupAction(),this.diagram.startTextEdit()}}},n}(),Zoe=function(){function n(){}return n.prototype.findObjectsUnderMouse=function(t,e,i,r,s){var o=[];r&&r instanceof si&&r.nodes.length+r.connectors.length===1&&(r=r.nodes[0]||r.connectors[0]).children&&0===r.children.length&&(i.actualObject=r);for(var a,l,h,c,f,d=r&&r instanceof de&&(r.constraints&qe.ConnectToNearByNode||r.constraints&qe.ConnectToNearByPort)&&r.connectionPadding||0,p={},g=0,v=e.spatialSearch.findObjects(new Ne(t.x-50-d,t.y-50-d,100+d,100+d));g-1&&o.splice(T,1),"UmlClassifier"===y.shape.type&&y.container&&"Stack"===y.container.type&&(T=o.indexOf(e.nameTable[e.nameTable[y.id].wrapper.children[0].id]))>-1&&o.splice(T,1)}for(var P=0;Ps.zIndex&&(t[parseInt(r.toString(),10)]=l),r>0&&i&&a&&(a.isLane||a.isPhase||a.isHeader)&&t[parseInt(r.toString(),10)].zIndex=2)for(var d=t.length-1;d>=0;d--)if(t[parseInt(d.toString(),10)].parentId){var u=lm(t[parseInt(d.toString(),10)],e,""),p=lm(t[d-1],e,""),g=e.nameTable[""+p];g&&u!==p&&e.nameTable[""+u].zIndex=0;f--){d=rf(e[parseInt(f.toString(),10)],!1),c=rf(e[parseInt(f.toString(),10)],!0);var g=t[""+l].tool,v=this.findTargetElement(e[parseInt(f.toString(),10)].wrapper,o,t,void 0);if("Draw"===i&&v&&(e[parseInt(f.toString(),10)]instanceof te||e[parseInt(f.toString(),10)]instanceof de)&&!hb(e[parseInt(f.toString(),10)],v)&&(g&&"ConnectorSourceEnd"===g[""+h]&&!zh(e[parseInt(f.toString(),10)])||g&&"ConnectorTargetEnd"===g[""+h]&&!da(e[parseInt(f.toString(),10)])))return u;if(e[parseInt(f.toString(),10)]instanceof te||e[parseInt(f.toString(),10)]instanceof de&&(zh(e[parseInt(f.toString(),10)])||Ld(d)||da(e[parseInt(f.toString(),10)])||Ph(c)||"PortDraw"===i&&g instanceof zd&&"ConnectorTargetEnd"===g[""+h]&&(da(e[parseInt(f.toString(),10)])||Ph(c))))return u=e[parseInt(f.toString(),10)],p&&(u=this.isTarget(u,t,i)),s.actualObject=u,u}else if("ConnectorTargetEnd"===i&&a){for(f=e.length-1;f>=0;f--)if(c=rf(e[parseInt(f.toString(),10)],!0),(e[parseInt(f.toString(),10)]instanceof te||e[parseInt(f.toString(),10)]instanceof de)&&(da(e[parseInt(f.toString(),10)])||Ph(c)))return u=e[parseInt(f.toString(),10)],u=this.isTarget(u,t,i),s.actualObject=u,u}else{if(a&&("Drag"===i||t[""+l].tool instanceof ua)){var y=0;for(f=0;f=S.zIndex?u:S,y=Math.max(y,S.zIndex)):y=(u=S).zIndex)}return u&&"Bpmn"===u.shape.type&&(t.selectedItems.nodes.length>0&&"Bpmn"===t.selectedItems.nodes[0].shape.type||(u=null)),u&&(s.actualObject=u),u}if("Select"!==i&&"Pan"!==i||!t[""+l].tool)if("Pan"===i||"LayoutAnimation"===i){for(f=e.length-1;f>=0;f--)if((e[parseInt(f.toString(),10)]instanceof te||e[parseInt(f.toString(),10)]instanceof de)&&(v=this.findTargetElement(e[parseInt(f.toString(),10)].wrapper,o,t,void 0),"Pan"===i||v&&(v.id.match("_icon_content_shape$")||v.id.match("_icon_content_rect$"))))return e[parseInt(f.toString(),10)]}else u=e[e.length-1],s&&u&&(s.actualObject=u);else{for(f=e.length-1;f>=0;f--)if(e[parseInt(f.toString(),10)]instanceof de){var b=e[f-1];if(e[f-1]instanceof te&&b.ports){if((v=this.findTargetElement(b.wrapper,o,t,void 0))&&(v.id.match("_icon_content_shape$")||v.id.match("_icon_content_rect$")))return b;for(var M=0;M=0;s--){var o=t.children[parseInt(s.toString(),10)];if(o&&o.outerBounds.containsPoint(e,r||0))if(o.visible){if(o instanceof Cs){var a=this.findTargetElement(o,e,i);if(a)return a}var l="Clip"===o.style.textOverflow||"Ellipsis"===o.style.textOverflow;if(o.bounds.containsPoint(e,r||0)&&!l)return o;if(t.bounds.containsPoint(e,r||0)&&l)return o}else if(o instanceof Ke&&t&&t.id){var h=void 0;if(t.id.includes("group_container")){var c=t.id.slice(0,-15);h=i.getObject(c)}else h=i.getObject(t.id);if(ab(h,o.id))return o}}return t.bounds.containsPoint(e,r)&&"none"!==t.style.fill?t:null},n}(),Joe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),hf=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},n_=function(n){function t(e,i,r,s){var o=n.call(this,e,i,r,s)||this;return o.objectZIndex=-1,o.zIndexTable={},o.objects=[],o}return Joe(t,n),hf([I("")],t.prototype,"id",void 0),hf([I(!0)],t.prototype,"visible",void 0),hf([I(!1)],t.prototype,"lock",void 0),hf([I()],t.prototype,"objects",void 0),hf([I()],t.prototype,"addInfo",void 0),hf([I(-1)],t.prototype,"zIndex",void 0),t}(Ee),DT=function(n,t,e,i){return new(e||(e=Promise))(function(r,s){function o(h){try{l(i.next(h))}catch(c){s(c)}}function a(h){try{l(i.throw(h))}catch(c){s(c)}}function l(h){h.done?r(h.value):new e(function(c){c(h.value)}).then(o,a)}l((i=i.apply(n,t||[])).next())})},xT=function(n,t){var i,r,s,o,e={label:0,sent:function(){if(1&s[0])throw s[1];return s[1]},trys:[],ops:[]};return o={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function a(h){return function(c){return function l(h){if(i)throw new TypeError("Generator is already executing.");for(;e;)try{if(i=1,r&&(s=2&h[0]?r.return:h[0]?r.throw||((s=r.return)&&s.call(r),0):r.next)&&!(s=s.call(r,h[1])).done)return s;switch(r=0,s&&(h=[2&h[0],s.value]),h[0]){case 0:case 1:s=h;break;case 4:return e.label++,{value:h[1],done:!1};case 5:e.label++,r=h[1],h=[0];continue;case 7:h=e.ops.pop(),e.trys.pop();continue;default:if(!(s=(s=e.trys).length>0&&s[s.length-1])&&(6===h[0]||2===h[0])){e=0;continue}if(3===h[0]&&(!s||h[1]>s[0]&&h[1]1)for(var i=0;i-1)return e[parseInt(i.toString(),10)];return this.diagram.activeLayer},n.prototype.getLayer=function(t){for(var e=this.diagram.layers,i=0;i=0;o--)this.diagram.unSelect(this.diagram.nameTable[s[parseInt(o.toString(),10)]]),this.diagram.remove(this.diagram.nameTable[s[parseInt(o.toString(),10)]]),"default_layer"!==i.id&&this.diagram.activeLayer.id===t&&(this.diagram.activeLayer=this.diagram.layers[this.diagram.layers.length-1]);delete this.diagram.layerZIndexTable[i.zIndex],this.diagram.layers.splice(r,1),"SVG"!==this.diagram.mode&&this.diagram.refreshDiagramLayer()}},n.prototype.moveObjects=function(t,e){this.diagram.startGroupAction();for(var i={},r=[],s=0;s-1){if(r=[],(h=this.diagram.nameTable[""+s]).children)for(var f=0,g=h.children;f0){for(var y=void 0,S=0,b=r;S0)for(var r=0;r0)for(r=0;r0){t=t.concat(this.diagram.selectedItems.connectors);for(var i=0;i0)for(t=t.concat(this.diagram.selectedItems.nodes),i=0;i0){for(var i=0,r=t.shape.activity.subProcess.processes;i0&&this.copyProcesses(this.processTable[""+s])}this.clipboardData.processTable=this.processTable}},n.prototype.group=function(){this.oldSelectedObjects=om(this.diagram);var e=this.diagram.isProtectedOnChange;this.diagram.protectPropertyChange(!0),this.diagram.diagramActions=this.diagram.diagramActions|ee.Group;var r={};r.id="group"+Qe(),(r=new te(this.diagram,"nodes",r,!0)).children=[];for(var s=this.diagram.selectedItems.nodes.concat(this.diagram.selectedItems.connectors).sort(function(h,c){return h.zIndex-c.zIndex}),o=0;o0){var a=this.diagram.add(r);a&&this.select(a),this.addHistoryEntry({type:"Group",undoObject:r,redoObject:r,category:"Internal"}),this.diagram.diagramActions=this.diagram.diagramActions&~ee.Group,this.diagram.protectPropertyChange(e)}},n.prototype.unGroup=function(t){var i=this.diagram.isProtectedOnChange;this.diagram.protectPropertyChange(!0),this.diagram.diagramActions=this.diagram.diagramActions|ee.Group;var r=[];t?r.push(t):r=this.diagram.selectedItems.nodes,this.diagram.startGroupAction();for(var s=0;s0&&this.diagram.removePorts(o,o.ports),o.annotations&&o.annotations.length>0&&!ce()&&this.diagram.removeLabels(o,o.annotations);for(var c=this.diagram.nameTable[o.parentId],d=o.children.length-1;d>=0;d--)this.diagram.nameTable[o.children[parseInt(d.toString(),10)]].parentId="",this.diagram.deleteChild(this.diagram.nameTable[o.children[parseInt(d.toString(),10)]],o),o.parentId&&o.children[parseInt(d.toString(),10)]&&this.diagram.addChild(c,o.children[parseInt(d.toString(),10)]);this.resetDependentConnectors(o.inEdges,!0),this.resetDependentConnectors(o.outEdges,!1),this.diagram.diagramActions&ee.UndoRedo||this.addHistoryEntry({type:"UnGroup",undoObject:a,redoObject:a,category:"Internal"}),o.parentId&&this.diagram.deleteChild(o,c)}this.diagram.removeNode(o,l),this.clearSelection()}this.diagram.endGroupAction(),this.diagram.diagramActions=this.diagram.diagramActions&~ee.Group,this.diagram.protectPropertyChange(i)},n.prototype.resetDependentConnectors=function(t,e){for(var i=0;i0&&(g=!1)}if(g){var y=this.cloneConnector(p,i);c.push(y),o[h.id]=y.id}}else{var S=this.cloneNode(h,i);if(c.push(S),S){o[h.id]=S.id;var b=h.inEdges;if(b)for(var M=0,w=b;M0)for(var u=0;u0)for(r=t.segments,s=0;s0&&this.diagram.drawingObject&&"Bezier"===this.diagram.drawingObject.type&&(t.segments=[]);var e=this.diagram.add(t);"SVG"!==this.diagram.mode&&this.diagram.refreshDiagramLayer(),this.selectObjects([e]),t&&!_I(this.diagram)&&(this.diagram.tool&=~Ci.DrawOnce,this.diagram.currentDrawingObject=void 0)},n.prototype.enableServerDataBinding=function(t){this.diagram.enableServerDataBinding(t)},n.prototype.addText=function(t,e){var i=this.diagram.findElementUnderMouse(t,e,this.diagram);this.diagram.startTextEdit(t,i instanceof ni?i.id.split("_")[1]:void 0)},n.prototype.isUserHandle=function(t){var e=this.diagram.selectedItems;if(e.wrapper&&qr(e.constraints,"UserHandle"))for(var i=0,r=e.userHandles;i0&&t[0]&&t[0].isLane)for(s=this.diagram.getObject(t[0].parentId),t[0].shape.header=[],a=0;a1||e&&1===t.length)){if(1!==t.length)return[2];this.clearSelection()}if(!(u||d||1!==t.length||e&&Xa(this.diagram)))return this.clearSelection(),[2]}if(!r.cancel){for(p=0;p0||e)&&f.children&&!f.parentId)for(g=0;g0||e,!0)}else this.select(f,p>0||e,!0);void 0===i&&(i=c),r={oldValue:i||[],newValue:this.getSelectedObject(),cause:this.diagram.diagramActions,state:"Changed",type:"Addition",cancel:!1},this.diagram.renderSelector(e||t&&t.length>1),ce()||this.diagram.triggerEvent(Ce.selectionChange,r),this.diagram.enableServerDataBinding(!0)}return[2]})})},n.prototype.findParent=function(t){return t.parentId&&this.findParent(t=this.diagram.nameTable[t.parentId]),t},n.prototype.selectProcesses=function(t){if(this.hasProcesses(t))for(var e=t.shape.activity.subProcess.processes,i=0;i0)},n.prototype.select=function(t,e,i){var r=this.getObjectLayer(t.id);if(Ad(t)&&!(t instanceof si)&&!_r(this.diagram,t)&&r&&!r.lock&&r.visible&&t.wrapper.visible){(e=!!Xa(this.diagram)&&e)||this.clearSelection(),this.diagram.enableServerDataBinding(!1);var s=this.diagram.selectedItems;if(t instanceof te?s.nodes.push(t.isHeader?this.diagram.nameTable[t.parentId]:t):s.connectors.push(t),s.selectedObjects.push(t),e)s.wrapper.rotateAngle=s.rotateAngle=0,s.wrapper.children.push(t.wrapper);else if(s.init(this.diagram),1===s.nodes.length&&0===s.connectors.length){var l=Yx(this.diagram,s);l&&(s.wrapper.children[0]=l),s.rotateAngle=s.nodes[0].rotateAngle,s.wrapper.rotateAngle=s.nodes[0].rotateAngle,s.wrapper.pivot=s.nodes[0].pivot}i||this.diagram.renderSelector(e),this.diagram.enableServerDataBinding(!0)}},n.prototype.labelSelect=function(t,e){this.oldSelectedObjects=om(this.diagram);var i=this.diagram.selectedItems,r=this.diagram.allowServerDataBinding;this.diagram.allowServerDataBinding=!1,i.nodes=i.connectors=[],this.diagram.allowServerDataBinding=r,t instanceof te?i.nodes[0]=t:i.connectors[0]=t,i.annotation=this.findTarget(e,t),i.init(this.diagram),this.diagram.renderSelector(!1)},n.prototype.unSelect=function(t){var e=this.diagram.selectedItems.nodes.concat(this.diagram.selectedItems.connectors),i=e.filter(function(a){return a.id!==t.id}),r={oldValue:e,newValue:i,cause:this.diagram.diagramActions,state:"Changing",type:"Removal",cancel:!1};if(this.diagram.currentSymbol||ce()||this.diagram.triggerEvent(Ce.selectionChange,r),_r(this.diagram,t)){var s=this.diagram.selectedItems,o=void 0;t instanceof te?(o=s.nodes.indexOf(t,0),s.nodes.splice(o,1)):(o=s.connectors.indexOf(t,0),s.connectors.splice(o,1)),o=s.selectedObjects.indexOf(t,0),s.selectedObjects.splice(o,1),(r={oldValue:e,newValue:i,cause:this.diagram.diagramActions,state:"Changed",type:"Removal",cancel:(r={oldValue:e,newValue:i,cause:this.diagram.diagramActions,state:"Changed",type:"Removal",cancel:!1}).cancel}).cancel||(o=s.wrapper.children.indexOf(t.wrapper,0),s.wrapper.children.splice(o,1),this.diagram.updateSelector(),this.diagram.currentSymbol||this.diagram.triggerEvent(Ce.selectionChange,r))}},n.prototype.moveSvgNode=function(t,e){var i=xt(e+"_groupElement",this.diagram.element.id),r=xt(t+"_groupElement",this.diagram.element.id);i.parentNode.insertBefore(r,i)},n.prototype.moveAfterSvgNode=function(t,e){var i=xt(e+"_groupElement",this.diagram.element.id),r=xt(t+"_groupElement",this.diagram.element.id);i.insertAdjacentElement("afterend",r)},n.prototype.sendLayerBackward=function(t){var e=this.getLayer(t);if(e&&0!==e.zIndex){var i=e.zIndex;if("SVG"===this.diagram.mode){var r=e.objects,s=this.getLayer(this.diagram.layerZIndexTable[i-1]).objects[0];if(s)for(var o=0,a=r;od&&"SwimLane"!==f.shape.type){var S=$(f);f.zIndex=d-((-1!==i.indexOf(f)?i.indexOf(f):0)+1),f.children&&(d=this.findLowestZIndex(f,c)||d),this.triggerOrderCommand(S,f,f),f.children&&this.updateGroupZindex(f,"SendToBack",d)}else"SwimLane"===f.shape.type&&(y=this.swapZIndexObjects(a,h,r,g));if("SVG"===this.diagram.mode){for(var M="SwimLane"!==this.diagram.nameTable[""+r].shape.type?d:y,w=h[parseInt(M.toString(),10)];!w&&Md)&&(d=p.zIndex)}for(var f=JSON.parse(JSON.stringify(l)),v=Number(Object.keys(l).sort(function(wo,Hl){return Number(wo)-Number(Hl)}).reverse()[0]),y=this.diagram.nameTable[""+e].zIndex,S=[],M=0;M<=v;M++)S.push(l[parseInt(M.toString(),10)]);if("SwimLane"===this.diagram.nameTable[""+e].shape.type)for(var C=v;C>=y;C--)if(l[parseInt(C.toString(),10)]&&this.diagram.nameTable[l[parseInt(C.toString(),10)]].parentId!==e){v=C;break}var D=this.diagram.nameTable[""+e];if(D.zIndexx&&(x=L.zIndex)}}else x=d;D.zIndex=x+((-1!==r.indexOf(D)?r.indexOf(D):0)+1),this.triggerOrderCommand(A,D,D)}else if("SwimLane"===D.shape.type){for(var O=0,N=-1,T=0,P=0,_=JSON.parse(JSON.stringify(l)),B=0;B<=y;B++)if(l[parseInt(B.toString(),10)]&&this.diagram.nameTable[l[parseInt(B.toString(),10)]].parentId===e&&-1===N){N=B,T=B;break}for(var j=0;j<=v;j++)f[parseInt(j.toString(),10)]&&f[parseInt(j.toString(),10)]!==e&&this.diagram.nameTable[f[parseInt(j.toString(),10)]].parentId!==e&&this.diagram.nameTable[f[parseInt(j.toString(),10)]].zIndex>=this.diagram.nameTable[""+e].zIndex&&O++;for(var ue=N,pe=0;pe<=O;pe++){for(;!l[parseInt(ue.toString(),10)];)ue++;P=this.diagram.nameTable[l[parseInt(ue.toString(),10)]].zIndex,ue++}for(var Me=P;Me<=v;Me++){for(;!_[parseInt(N.toString(),10)];)N++;for(;!l[parseInt(Me.toString(),10)];)Me++;l[parseInt(Me.toString(),10)]=_[parseInt(N.toString(),10)],this.diagram.nameTable[l[parseInt(Me.toString(),10)]].zIndex=Me,N++}l[parseInt(v.toString(),10)]=this.diagram.nameTable[""+e].id,this.diagram.nameTable[""+e].zIndex=v,ue=y+1;for(var De=T,xe=0;xe0&&("Native"===hr[0].shape.type||"HTML"===hr[0].shape.type)){for(Mi.parentNode.removeChild(Mi),De=0;De0?r[0]:null},n.prototype.findLowestZIndex=function(t,e){var r=this.diagram.nodes.filter(function(s){return-1!==e.indexOf(s.id)}).filter(function(s){return""===s.parentId&&s.id!==t.id}).map(function(s){return s.zIndex});return r.sort(function(s,o){return s-o}),r.length>0?r[0]:null},n.prototype.triggerOrderCommand=function(t,e,i){var s={zIndex:$(t).zIndex},o={zIndex:e.zIndex},a={element:i,cause:this.diagram.diagramActions,diagramAction:this.diagram.getDiagramAction(this.diagram.diagramActions),oldValue:s,newValue:o};this.diagram.triggerEvent(Ce.propertyChange,a)},n.prototype.checkGroupNode=function(t,e,i){return i[""+e].parentId===i[""+t].parentId},n.prototype.sortByZIndex=function(t,e,i){if("BringForward"===i){var r=e||"zIndex";t=t.sort(function(o,a){return a[""+r]-o[""+r]})}else{var s=e||"zIndex";t=t.sort(function(o,a){return o[""+s]-a[""+s]})}return t},n.prototype.orderCommands=function(t,e,i){var r=this,s=e.nodes;if(s=s.concat(e.connectors),t)if("SendBackward"===i)for(var o=0;oa}),S=v.filter(function(D){return D0?Math.max.apply(Math,S):a,M=y.length>0?Math.min.apply(Math,y):a;if(a!==M){var w=c.zIndexTable[parseInt(M.toString(),10)],C=c.zIndexTable[parseInt(a.toString(),10)];this.moveSvgNode(C,w)}else"SendToBack"===i&&(w=c.zIndexTable[parseInt(a.toString(),10)],C=c.zIndexTable[parseInt(b.toString(),10)],this.moveAfterSvgNode(w,C))}}else this.diagram.refreshCanvasLayers()}},n.prototype.sendForward=function(t){var e=this;if(this.diagram.protectPropertyChange(!0),Xa(this.diagram)||t){$(t||(this.diagram.selectedItems.nodes.length?this.diagram.selectedItems.nodes[0]:this.diagram.selectedItems.connectors[0]));var s=t&&t.id,o=this.diagram.layers.indexOf(this.getObjectLayer(s=s||(this.diagram.selectedItems.nodes.length?this.diagram.selectedItems.nodes[0].id:this.diagram.selectedItems.connectors[0].id))),a=$(this.diagram.nameTable),h=(parseInt(o.toString(),10),this.diagram.nameTable[""+s]),c=[],d=this.diagram.spatialSearch.findObjects(h.wrapper.bounds);d.length>2&&(d=this.sortByZIndex(d,void 0,"BringForward"));for(var u=0,p=d;u=0;f--)this.diagram.nameTable[c[parseInt(f.toString(),10)].id].parentId===s&&c.splice(f,1);if(c.length>0){var y=this.diagram.nameTable[c[c.length-1].id];if(y.parentId){var b=lm(y,this.diagram,""),M=this.diagram.nameTable[""+b];M.id!==s&&(c[0]=M)}var w={};for(f=0;f0&&(Object.values(O).forEach(function(ue){ue>=T&&N.push(ue)}),0!==N.length&&this.updateZIndexBySendForward(h,N,o))}var P=[];if(Object.keys(this.changedNodeZIndexes).forEach(function(ue){if((a[""+ue]?a[""+ue].zIndex:null)!==e.changedNodeZIndexes[""+ue]){var De=$(a[""+ue]);P.push(De)}}),this.updateLayerZindexTable(o),L.nodes.splice(0,L.nodes.length),P.forEach(function(ue){var pe=$(ue);L.nodes.push(pe)}),"SVG"===this.diagram.mode){var _=c[c.length-1].id,B=c[c.length-1];B&&!("HTML"===B.shape.type||"Native"===B.shape.type)&&this.moveAfterSvgNode(s,_),this.updateNativeNodeIndex(_,s)}else this.diagram.refreshCanvasLayers();var j=[];Object.keys(this.changedNodeZIndexes).forEach(function(ue){if((a[""+ue]?a[""+ue].zIndex:null)!==e.changedNodeZIndexes[""+ue]){var De=$(e.diagram.nameTable[""+ue]);j.push(De)}});var Q=$(this.diagram.selectedItems);Q.nodes.splice(0,Q.nodes.length),j.forEach(function(ue){var pe=$(ue);Q.nodes.push(pe)}),this.diagram.diagramActions&ee.UndoRedo||this.addHistoryEntry({type:"SendForward",category:"Internal",undoObject:L,redoObject:Q}),this.diagram.endGroupAction()}}this.diagram.protectPropertyChange(!1)},n.prototype.updateZIndexBySendForward=function(t,e,i){var r=$(t);t.zIndex=Math.min.apply(Math,e);var a,s=Math.min.apply(Math,e),o=Math.min.apply(Math,e),l=this.diagram.layers[parseInt(i.toString(),10)].objects,h=this.diagram.nodes.filter(function(S){return-1!==l.indexOf(S.id)});t.children&&this.updateGroupZindex(t,"BringForward",t.zIndex);var c=h.filter(function(S){return S.zIndex===Math.min.apply(Math,e)&&S.id!==t.id});if(c&&c.length>0&&c[0].children){for(var d=Math.min.apply(Math,e),u=0;uo&&g!==t&&g.parentId!==t.id&&c&&c.length>0&&g.parentId!==c[0].id){var v=$(g);g.zIndex=a+1,a++,this.triggerOrderCommand(v,g,g)}var y=g.zIndex;this.changedNodeZIndexes[g.id]=(this.changedNodeZIndexes.hasOwnProperty(g.id),y)}},n.prototype.arrangeZIndexForLowerNodes=function(t,e,i){var r=i.filter(function(o){return o.zIndex<=t&&o.parentId!==e.id});r.sort(function(o,a){return a.zIndex-o.zIndex});for(var s=0;se&&(e=r.zIndex)}return e},n.prototype.sendBackward=function(t){var e=this;if(this.diagram.protectPropertyChange(!0),Xa(this.diagram)||t){$(t||(this.diagram.selectedItems.nodes.length?this.diagram.selectedItems.nodes[0]:this.diagram.selectedItems.connectors[0]));var s=t&&t.id,o=this.diagram.layers.indexOf(this.getObjectLayer(s=s||(this.diagram.selectedItems.nodes.length?this.diagram.selectedItems.nodes[0].id:this.diagram.selectedItems.connectors[0].id))),a=$(this.diagram.nameTable),h=(parseInt(o.toString(),10),this.diagram.nameTable[""+s]),c=[],d=this.diagram.spatialSearch.findObjects(h.wrapper.bounds);d.length>2&&(d=this.sortByZIndex(d));for(var u=0,p=d;uNumber(f.zIndex)&&""===f.parentId&&h.wrapper.bounds.intersects(f.wrapper.bounds)&&c.push(f);for(var f=c.length-1;f>=0;f--)(v=this.diagram.nameTable[c[parseInt(f.toString(),10)].id]).parentId===s&&c.splice(f,1);if(c.length>0){var v;if((v=this.diagram.nameTable[c[c.length-1].id]).parentId){var S=lm(v,this.diagram,""),b=this.diagram.nameTable[""+S];s!==b.id&&(c[c.length-1]=b)}var M={};for(f=0;f0&&(Object.values(L).forEach(function(pe){pe<=N&&O.push(pe)}),0!==O.length&&this.updateZIndexBySendBackward(h,O,o))}var T=[];if(Object.keys(this.changedNodeZIndexes).forEach(function(pe){if((a[""+pe]?a[""+pe].zIndex:null)!==e.changedNodeZIndexes[""+pe]){var xe=$(a[""+pe]);T.push(xe)}}),this.updateLayerZindexTable(o),R.nodes.splice(0,R.nodes.length),T.forEach(function(pe){var Me=$(pe);R.nodes.push(Me)}),"SVG"===this.diagram.mode){var P=c[c.length-1].id,_=c[c.length-1];_&&"HTML"!==_.shape.type&&"Native"!==_.shape.type&&this.moveSvgNode(s,P);var B=this.diagram.nameTable[""+P];B.children&&B.children.length>0?this.updateNativeNodeIndex(s):this.updateNativeNodeIndex(s,P)}else this.diagram.refreshCanvasLayers();var j=[];Object.keys(this.changedNodeZIndexes).forEach(function(pe){if((a[""+pe]?a[""+pe].zIndex:null)!==e.changedNodeZIndexes[""+pe]){var xe=$(e.diagram.nameTable[""+pe]);j.push(xe)}});var Q=$(this.diagram.selectedItems);Q.nodes.splice(0,Q.nodes.length),j.forEach(function(pe){var Me=$(pe);Q.nodes.push(Me)}),this.diagram.diagramActions&ee.UndoRedo||this.addHistoryEntry({type:"SendBackward",category:"Internal",undoObject:R,redoObject:Q}),this.diagram.endGroupAction()}}this.diagram.protectPropertyChange(!1)},n.prototype.updateZIndexBySendBackward=function(t,e,i){var r=$(t);t.zIndex=Math.max.apply(Math,e);var p,s=t.zIndex,o=Math.max.apply(Math,e),a=this.diagram.layers[parseInt(i.toString(),10)].objects,l=this.diagram.nodes.filter(function(S){return-1!==a.indexOf(S.id)}),h=l.filter(function(S){return S.zIndex===Math.max.apply(Math,e)&&S.id!==t.id});if(h&&h.length>0&&h[0].children)for(var c=Math.max.apply(Math,e),d=0;d0&&g.parentId!==h[0].id){var v=$(g);g.zIndex=p-1,p--,this.triggerOrderCommand(v,g,g)}var y=g.zIndex;this.changedNodeZIndexes[""+g.id]=(this.changedNodeZIndexes.hasOwnProperty(g.id),y)}},n.prototype.findLowestChildZIndex=function(t){for(var e=t.zIndex,i=0;i0),this.selectObjects([t],!0))},n.prototype.clearSelection=function(t,e){return DT(this,void 0,void 0,function(){var i,r,s,o;return xT(this,function(a){return i=this.diagram.allowServerDataBinding,this.diagram.enableServerDataBinding(!1),Xa(this.diagram)&&(r=this.diagram.selectedItems,s=this.getSelectedObject(),this.diagram.currentSymbol&&(this.diagram.previousSelectedObject=s),o={oldValue:s,newValue:[],cause:this.diagram.diagramActions,state:"Changing",type:"Removal",cancel:!1},t&&(ce()||this.diagram.triggerEvent(Ce.selectionChange,o)),o.cancel||(r.offsetX=0,r.offsetY=0,r.width=0,r.height=0,r.rotateAngle=0,r.nodes=[],r.connectors=[],r.wrapper=null,r.annotation=void 0,r.selectedObjects=[],this.diagram.clearSelectorLayer(),t&&(o={oldValue:s,newValue:[],cause:this.diagram.diagramActions,state:"Changed",type:"Removal",cancel:!1},ce()||this.diagram.triggerEvent(Ce.selectionChange,o))),this.diagram.enableServerDataBinding(i)),[2]})})},n.prototype.clearSelectedItems=function(){this.clearSelection((this.diagram.selectedItems.nodes?this.diagram.selectedItems.nodes.length:0)+(this.diagram.selectedItems.connectors?this.diagram.selectedItems.connectors.length:0)>0)},n.prototype.removeStackHighlighter=function(){var t=zl(this.diagram.element.id),e=t.getElementById(t.id+"_stack_highlighter");e&&e.parentNode.removeChild(e)},n.prototype.renderStackHighlighter=function(t,e){var r,s,o,i=this.diagram.selectedItems.nodes[0];if(!e){var a=this.diagram.findObjectsUnderMouse(t.position);if((e=this.diagram.findObjectUnderMouse(a,"Drag",!0))&&!(e.isLane||e.isPhase||e.isHeader))for(var l=0;l0)for(var a=0;a1)if(i){var h=l.segments[0],c=l.segments[1],u=Lc(AI(t.wrapper,t.wrapper.corners,t.wrapper.bounds),h.direction),g=Nl({corners:void 0,point:u=kh(l,0,u,{x:l.sourceWrapper.offsetX,y:l.sourceWrapper.offsetY},!1),margin:void 0,direction:h.direction},{corners:void 0,point:c.points[1],margin:void 0,direction:void 0});h.length=z.distancePoints(g[0],g[1]),c.direction&&c.length&&(c.length=z.distancePoints(g[1],g[2]))}else if(o){switch(l.segments[0].direction){case"Bottom":r=t.wrapper.bounds.bottomCenter.x-e.bottomCenter.x,s=t.wrapper.bounds.bottomCenter.y-e.bottomCenter.y;break;case"Top":r=t.wrapper.bounds.topCenter.x-e.topCenter.x,s=t.wrapper.bounds.topCenter.y-e.topCenter.y;break;case"Left":r=t.wrapper.bounds.middleLeft.x-e.middleLeft.x,s=t.wrapper.bounds.middleLeft.y-e.middleLeft.y;break;case"Right":r=t.wrapper.bounds.middleRight.x-e.middleRight.x,s=t.wrapper.bounds.middleRight.y-e.middleRight.y}this.dragSourceEnd(l,r,s,!0,null,"ConnectorSourceEnd",void 0,void 0,void 0,!(t.parentId&&this.diagram.diagramActions&ee.isGroupDragging))}}},n.prototype.updateEndPoint=function(t,e){var r={sourcePoint:t.sourcePoint,targetPoint:t.targetPoint};t.sourceID&&(r.sourceID=t.sourceID),t.targetID&&(r.targetID=t.targetID),t.sourcePortID&&(r.sourcePortID=t.sourcePortID),t.targetPortID&&(r.targetPortID=t.targetPortID),t.segments&&(r.segments=t.segments),this.diagram.connectorPropertyChange(t,e||{},r),this.diagram.updateSelector()},n.prototype.dragSourceEnd=function(t,e,i,r,s,o,a,l,h,c,d){var u=this.diagram.nameTable[t.id],p={},f=this.checkBoundaryConstraints(e,i,u.wrapper.bounds);if(PI(u)&&f&&"BezierSourceThumb"!==o&&Qv(this.diagram)&&(p=$(p={sourcePoint:u.sourcePoint}),u.sourcePoint.x+=e,u.sourcePoint.y+=i,"ConnectorSourceEnd"===o&&"Orthogonal"===u.type&&this.changeSegmentLength(u,l,h,c),"Bpmn"===u.shape.type&&"Default"===u.shape.sequence&&"Sequence"===u.shape.flow&&this.updatePathElementOffset(u)),"Bezier"===u.type)if(p={sourcePoint:u.sourcePoint},d)this.translateBezierPoints(t,""===o?"ConnectorSourceEnd":o,e,i,d,s,!a);else for(var g=0;g2){var d=z.direction((c=t.segments[2]).points[0],c.points[1]);o.direction===ls(d)?("Right"===o.direction?c.points[0].x=o.points[o.points.length-1].x=l.wrapper.corners.middleRight.x+20:"Left"===o.direction?c.points[0].x=o.points[o.points.length-1].x=l.wrapper.corners.middleLeft.x-20:c.points[0].y=o.points[o.points.length-1].y="Top"===o.direction?l.wrapper.corners.topCenter.y-20:l.wrapper.corners.bottomCenter.y+20,c.direction&&c.length&&(c.length=z.distancePoints(c.points[0],c.points[c.points.length-1])),o.length=z.distancePoints(o.points[0],o.points[o.points.length-1])):o.direction===d&&c.direction&&c.length?("Top"===o.direction||"Bottom"===o.direction?(c.points[0]=o.points[0],c.points[c.points.length-1].x=c.points[0].x):(c.points[0]=o.points[0],c.points[c.points.length-1].y=c.points[0].y),c.length=z.distancePoints(c.points[0],c.points[c.points.length-1]),t.segments.splice(0,2)):o.length=20}else o.length=20;else if(o.length<1)if(""!==t.sourceID){var c;"Right"===a.direction?a.points[a.points.length-1].y=(h=l.wrapper.corners.middleRight).y:"Left"===a.direction?a.points[a.points.length-1].y=(h=l.wrapper.corners.middleLeft).y:a.points[a.points.length-1].x="Top"===a.direction?(h=l.wrapper.corners.topCenter).x:(h=l.wrapper.corners.bottomCenter).x,a.length=z.distancePoints(h,a.points[a.points.length-1]),t.segments.length>2&&(c=t.segments[2]).direction&&c.length&&(c.length=z.distancePoints(a.points[a.points.length-1],c.points[c.points.length-1])),t.segments.splice(0,1)}else t.segments.splice(0,1)}else e&&!i&&t.sourceID!==e.id&&t.segments&&null!==t.segments[0].direction&&e&&e instanceof te&&s&&this.changeSourceEndToNode(t,e),e&&i&&t.sourcePortID!==i&&t.segments&&null!==t.segments[0].direction&&e&&e instanceof te&&s&&this.changeSourceEndToPort(t,e,i)},n.prototype.canConnect=function(t,e){return!(!da(e)||!zh(e))},n.prototype.changeSourceEndToPort=function(t,e,i){var r=this.diagram.getWrapper(e.wrapper,i),s={x:r.offsetX,y:r.offsetY},o=zo(s,En(e.wrapper),e.wrapper.bounds),a=t.segments[0],l=t.segments[1];if(a.direction!==o){var h=[],c={};if(a.direction===ls(o)){c={};var d=void 0;"Top"===o||"Bottom"===o?(d="Top"===o?{type:"Orthogonal",isTerminal:!0,direction:o,length:Math.abs(a.points[0].y-s.y)}:{type:"Orthogonal",isTerminal:!0,direction:o,length:Math.abs(s.y-a.points[0].y)},c=a.points[0].x>s.x?{type:"Orthogonal",isTerminal:!0,direction:"Right",length:a.points[0].x-s.x}:{type:"Orthogonal",isTerminal:!0,direction:"Left",length:s.x-a.points[0].x}):(d="Right"===o?{type:"Orthogonal",isTerminal:!0,direction:o,length:Math.abs(a.points[0].x-s.x)}:{type:"Orthogonal",isTerminal:!0,direction:o,length:Math.abs(s.x-a.points[0].x)},c=a.points[0].y>s.y?{type:"Orthogonal",direction:"Top",isTerminal:!0,length:a.points[0].y-s.y}:{type:"Orthogonal",direction:"Bottom",isTerminal:!0,length:s.y-a.points[0].y}),h.push(new bi(t,"segments",d,!0)),h.push(new bi(t,"segments",c,!0))}else h.push(new bi(t,"segments",c={type:"Orthogonal",direction:o,length:20,isTerminal:!0},!0));a.direction!==ls(o)&&("Top"===o||"Bottom"===o?(a.points[0].x=s.x,a.points[0].y=a.points[a.points.length-1].y="Top"===o?s.y-20:s.y+20):(a.points[0].y=s.y,a.points[0].x=a.points[a.points.length-1].x="Right"===o?s.x+20:s.x-20),a.length=z.distancePoints(a.points[0],a.points[a.points.length-1]),l.length=z.distancePoints(a.points[a.points.length-1],l.points[l.points.length-1])),t.segments=h.concat(t.segments)}else a.points[0]=s,"Top"===o||"Bottom"===o?a.points[a.points.length-1].x=s.x:a.points[a.points.length-1].y=s.y,a.length=z.distancePoints(a.points[0],a.points[a.points.length-1]),l.length=z.distancePoints(a.points[a.points.length-1],l.points[l.points.length-1])},n.prototype.removeTerminalSegment=function(t,e){for(var i=0;ii.width||"Left"===o.direction&&r.x>=o.points[0].x||"Right"===o.direction&&r.x<=o.points[0].x)o.points[0].y=o.points[o.points.length-1].y=r.y,o.points[0].x=r.x,o.length=z.distancePoints(o.points[0],o.points[o.points.length-1]),a.length=z.distancePoints(o.points[o.points.length-1],a.points[a.points.length-1]);else{var h=void 0;s="Bottom"===(h=a.direction?a.direction:z.direction(a.points[0],a.points[a.points.length-1]))?i.bottomCenter:i.topCenter,a.length&&a.direction&&(a.length="Top"===h?o.points[o.points.length-1].y-(s.y+20):s.y+20-o.points[o.points.length-1].y),o.length=o.points[o.points.length-1].x-s.x,o.direction=o.length>0?"Right":"Left",l.push(new bi(t,"segments",{type:"Orthogonal",direction:h,length:20},!0)),t.segments=l.concat(t.segments)}else r="Bottom"===o.direction?i.bottomCenter:i.topCenter,o.length>i.height||"Top"===o.direction&&r.y>=o.points[0].y||"Bottom"===o.direction&&r.y<=o.points[0].y?(o.points[0].x=o.points[o.points.length-1].x=r.x,o.points[0].y=r.y,o.length=z.distancePoints(o.points[0],o.points[o.points.length-1]),a.length=z.distancePoints(o.points[o.points.length-1],a.points[a.points.length-1])):(s="Left"===a.direction?i.middleLeft:i.middleRight,h=void 0,h=a.direction?a.direction:z.direction(a.points[0],a.points[a.points.length-1]),a.length&&a.direction&&(a.length="Left"===h?o.points[o.points.length-1].x-(s.x+20):s.x+20-o.points[o.points.length-1].x),o.length=o.points[o.points.length-1].y-s.y,o.direction=o.length>0?"Bottom":"Top",l.push(new bi(t,"segments",{type:"Orthogonal",direction:h,length:20},!0)),t.segments=l.concat(t.segments))},n.prototype.translateBezierPoints=function(t,e,i,r,s,o,a){var l=t.segments.indexOf(s),h=t.segments[parseInt(l.toString(),10)],c=l>0?t.segments[l-1]:null,d=null!==c?c.point:t.sourcePoint,u=l===t.segments.length-1?t.targetPoint:h.point;if(h)if("BezierSourceThumb"===e&&(h.vector1.angle||h.vector1.distance)){var p=h.vector1.distance,f=h.vector1.angle;h.vector1={distance:t.distance(d,o),angle:z.findAngle(d,o)},this.translateSubsequentSegment(t,s,!0,h.vector1.distance-p,h.vector1.angle-f)}else"BezierTargetThumb"===e&&(h.vector2.angle||h.vector2.distance)?(p=h.vector2.distance,f=h.vector2.angle,h.vector2={distance:t.distance(u,o),angle:z.findAngle(u,o)},this.translateSubsequentSegment(t,s,!1,h.vector2.distance-p,h.vector2.angle-f)):("ConnectorSourceEnd"===e&&!t.sourceID||"ConnectorTargetEnd"===e&&!t.targetID)&&a&&KI(h.vector1)&&KI(h.vector2)?(z.isEmptyPoint(h.point1)&&(h.bezierPoint1=eb(t.sourcePoint,t.targetPoint)),z.isEmptyPoint(h.point2)&&(h.bezierPoint2=eb(t.targetPoint,t.sourcePoint))):"BezierSourceThumb"===e||"ConnectorSourceEnd"===e&&!a&&KI(h.vector1)?(h.bezierPoint1.x+=i,h.bezierPoint1.y+=r,(!z.isEmptyPoint(h.point1)||a)&&(h.point1={x:h.bezierPoint1.x,y:h.bezierPoint1.y})):("BezierTargetThumb"===e||"ConnectorTargetEnd"===e&&!a&&KI(h.vector2))&&(h.bezierPoint2.x+=i,h.bezierPoint2.y+=r,(!z.isEmptyPoint(h.point2)||a)&&(h.point2={x:h.bezierPoint2.x,y:h.bezierPoint2.y}))},n.prototype.translateSubsequentSegment=function(t,e,i,r,s){var o=t.segments.indexOf(e);parseInt(o.toString(),10),t.bezierSettings.smoothness&CI.SymmetricAngle||(s=null),t.bezierSettings.smoothness&CI.SymmetricDistance||(r=null),(null!=r||null!=s)&&(i?0!==o&&this.updatePreviousBezierSegment(t,o,r,s):o!==t.segments.length-1&&this.updateNextBezierSegment(t,o,r,s))},n.prototype.updatePreviousBezierSegment=function(t,e,i,r){var s=t.segments[e-1],a=(s.vector2.angle+r)%360;a<0&&(a+=360),s.vector2={distance:s.vector2.distance+i,angle:a}},n.prototype.updateNextBezierSegment=function(t,e,i,r){var s=t.segments[e+1],a=(s.vector1.angle+r)%360;a<0&&(a+=360),s.vector1={distance:s.vector1.distance+i,angle:a}},n.prototype.dragTargetEnd=function(t,e,i,r,s,o,a,l){var c,h=this.diagram.nameTable[t.id],d=this.checkBoundaryConstraints(e,i,h.wrapper.bounds);if(zI(h)&&"BezierTargetThumb"!==o&&d&&Qv(this.diagram)){if(c=$(c={targetPoint:h.targetPoint}),h.targetPoint.x+=e,h.targetPoint.y+=i,"ConnectorTargetEnd"===o&&"Orthogonal"===h.type&&h.segments&&h.segments.length>0){var u=h.segments[h.segments.length-2];u&&2===h.segments[h.segments.length-1].points.length&&("Left"===u.direction||"Right"===u.direction?u.points[u.points.length-1].x=h.targetPoint.x:u.points[u.points.length-1].y=h.targetPoint.y,u.length=z.distancePoints(u.points[0],u.points[u.points.length-1]),u.direction=z.direction(u.points[0],u.points[u.points.length-1]))}"Bpmn"===h.shape.type&&"Default"===h.shape.sequence&&"Sequence"===h.shape.flow&&this.updatePathElementOffset(h)}if("Bezier"===h.type)if(c={targetPoint:h.targetPoint},l)this.translateBezierPoints(t,""===o?"ConnectorTargetEnd":o,e,i,l,s,!a);else for(var p=0;p0){if(void 0!==s&&o.segments[parseInt(s.toString(),10)])if("Bezier"===o.type){var a=o.segments[parseInt(s.toString(),10)],l=a.isInternalSegment;l&&null!==o.bezierSettings&&"FreeForm"!==o.bezierSettings.segmentEditOrientation?("Horizontal"===a.orientation?a.point.x+=e:a.point.y+=i,this.updateDirectionalBezierCurve(o)):(a.point.x+=e,a.point.y+=i),l&&(o.isBezierEditing=!0)}else o.segments[parseInt(s.toString(),10)].point.x+=e,o.segments[parseInt(s.toString(),10)].point.y+=i;else for(var h=0;h1){var a=e[1],l=e[2],h={x:.5*(a.x+l.x),y:.5*(a.y+l.y)},c=t.segments[0];c.vector1.angle=Gt(s,a),c.vector1.distance=.5*z.findLength(s,a),c.vector2.angle=Gt(h,a),c.vector2.distance=.5*z.findLength(h,a),c.point=h;var d=t.segments[1];if(d.vector1.angle=Gt(h,l),d.vector1.distance=.5*z.findLength(h,l),t.segments.length>2){var u=e[3],p={x:.5*(l.x+u.x),y:.5*(l.y+u.y)};d.vector2.angle=Gt(p,l),d.vector2.distance=.5*z.findLength(p,l),d.point=p;var f=t.segments[2];if(f.vector1.angle=Gt(p,u),f.vector1.distance=.5*z.findLength(p,u),t.segments.length>3){var g=e[4],v={x:.5*(u.x+g.x),y:.5*(u.y+g.y)};f.vector2.angle=Gt(v,u),f.vector2.distance=.5*z.findLength(v,u),f.point=v;var y=t.segments[3];y.vector1.angle=Gt(v,g),y.vector1.distance=.5*z.findLength(v,g),y.vector2.angle=Gt(o,g),y.vector2.distance=.5*z.findLength(o,g)}else f.vector2.angle=Gt(o,u),f.vector2.distance=.5*z.findLength(o,u)}else d.vector2.angle=Gt(o,l),d.vector2.distance=.5*z.findLength(o,l)}},n.prototype.rotateObjects=function(t,e,i,r,s){r=r||{};var o=Hi();qi(o,i,r.x,r.y);for(var l=0,h=e;l0){this.diagram.protectPropertyChange(!0);var o=t;o.segments=[],this.diagram.connectorPropertyChange(o,{},{segments:o.segments}),this.diagram.protectPropertyChange(!1)}}},n.prototype.updateInnerParentProperties=function(t){var r=this.diagram.isProtectedOnChange;this.diagram.protectPropertyChange(!0);for(var s=this.getAllDescendants(t,[],!1,!0),o=0;o0&&(p=this.diagram.bpmnModule.getChildrenBound(d,d.id,this.diagram),u=d.wrapper.bounds.containsRect(p)),h=d.wrapper.actualSize.width*t,c=d.wrapper.actualSize.height*e,void 0!==d.maxWidth&&0!==d.maxWidth&&(h=Math.min(d.maxWidth,h)),void 0!==d.minWidth&&0!==d.minWidth&&(h=Math.max(d.minWidth,h)),void 0!==d.maxHeight&&0!==d.maxHeight&&(c=Math.min(d.maxHeight,c)),void 0!==d.minHeight&&0!==d.minHeight&&(c=Math.max(d.minHeight,c)),u&&(h=Math.max(h,p.right-d.wrapper.bounds.x),c=Math.max(c,p.bottom-d.wrapper.bounds.y)),t=h/d.actualSize.width,e=c/d.actualSize.height}var f=Hi();o||(o=r);var g=o.wrapper;if(qi(f,-g.rotateAngle,i.x,i.y),Xp(f,t,e,i.x,i.y),qi(f,g.rotateAngle,i.x,i.y),r instanceof te){var d,v=Je(f,{x:(d=r).wrapper.offsetX,y:d.wrapper.offsetY}),y=d.wrapper.offsetX-d.wrapper.actualSize.width*d.pivot.x,S=d.wrapper.offsetY-d.wrapper.actualSize.height*d.pivot.y;if(h>0)if(d.processId){var b=this.diagram.nameTable[d.processId];(!b.maxWidth||d.margin.left+h0)if(d.processId){var M=this.diagram.nameTable[d.processId];(!M.maxHeight||d.margin.top+c0){if(e.dragLimit=e.dragLimit?e.dragLimit:{},e.dragLimit.top||e.dragLimit.bottom||e.dragLimit.left||e.dragLimit.right){var b={minDistance:null};S=this.getRelativeOffset(v,d,b);var M={minDistance:null};g=this.getRelativeOffset(v,y,M),S=null!=b&&M.minDistance0){if(S=y[y.length-1]){var b=void 0;for(b=0;b=e.x-t.dragLimit.left-r.width/2&&i.x<=e.x+t.dragLimit.right+r.width/2&&(s=!0),i.y>=e.y-t.dragLimit.top-r.height/2&&i.y<=e.y+t.dragLimit.bottom+r.height/2&&(o=!0),{x:s,y:o}},n.prototype.updateLabelMargin=function(t,e,i,r,s,o,a){if(i=i||{x:e.offset,y:0},e&&i&&i.x>0&&i.x<1){var l=z.getLengthFromListOfPoints(t.intermediatePoints),h=this.getPointAtLength(l*i.x,t.intermediatePoints,0),c=this.diagram.scrollSettings.currentZoom,d=e.dragLimit?e.dragLimit:{left:0,right:0,top:0,bottom:0};if(d.top||d.bottom||d.left||d.right){this.diagram.getWrapper(t.wrapper,e.id);var p=new Ne(0,0,0,0),f=this.diagram.getWrapper(t.wrapper,e.id);p.x=f.offsetX/c+o,p.y=f.offsetY/c+a,p.width=f.bounds.width/c,p.height=f.bounds.height/c;var g=new Ne(h.x-(d.left||0)-p.width/2,h.y-(d.top||0)-p.height/2,(d.left||0)+(d.right||0)+p.width,(d.top||0)+(d.bottom||0)+p.height);if(g.containsPoint(r));else for(var S=0,b=this.boundsInterSects([h,r],g,!1);S=t){c=t-r,d=z.findAngle(s,a),u=c*Math.cos(d*Math.PI/180),p=c*Math.sin(d*Math.PI/180),o={x:s.x+u,y:s.y+p};break}r+=h,s=a}else s=a;return o},n.prototype.getInterceptWithSegment=function(t,e){for(var o,a,i=[],r=[],s=[],l=z.findLength({x:0,y:0},{x:this.diagram.scroller.viewPortWidth,y:this.diagram.scroller.viewPortHeight}),h=1;h0&&a<=90||a>180&&a<=270?90:-90;r.push(z.transform(t,a+c,l)),r.push(z.transform(t,o+c,l));var p=rm({x1:s[0].x,y1:s[0].y,x2:s[1].x,y2:s[1].y},{x1:r[0].x,y1:r[0].y,x2:r[1].x,y2:r[1].y});p.enabled&&i.push(p.intersectPt)}return i},n.prototype.getAnnotationChanges=function(t,e){var r={};return r[lb(t,e.id,!0)]={width:e.width,height:e.height,offset:t instanceof te?{x:e.offset.x,y:e.offset.y}:e.offset,rotateAngle:e.rotateAngle,margin:{left:e.margin.left,right:e.margin.right,top:e.margin.top,bottom:e.margin.bottom},horizontalAlignment:e.horizontalAlignment,verticalAlignment:e.verticalAlignment,alignment:t instanceof de?e.alignment:void 0},{annotations:r}},n.prototype.getConnectorPortChanges=function(t,e){var i=function Wse(n,t,e){for(var i=n.ports,r=0;r1&&(v.width=g,v.offset.x=1/S),f>1&&(v.height=f,v.offset.y=1/b)}}e instanceof Nr&&(e.alignment="Center"),l=this.getAnnotationChanges(t,e),t instanceof te?this.diagram.nodePropertyChange(t,a,l):this.diagram.connectorPropertyChange(t,a,l),this.diagram.updateDiagramObject(t)},n.prototype.getSubProcess=function(t){var i,e={nodes:[],connectors:[]};return t instanceof te?i=t.processId:t&&t.nodes&&t.nodes.length&&t.nodes[0].processId&&(i=t.nodes[0].processId),i&&e.nodes.push($(this.diagram.nameTable[i])),e},n.prototype.checkBoundaryConstraints=function(t,e,i,r){var s=this.diagram.pageSettings,o=this.diagram.pageSettings.boundaryConstraints,a=this.diagram.scroller;if("Page"===o||"Diagram"===o){var l=i?void 0:this.diagram.selectedItems.wrapper.bounds;return!!((i?i.right:l.right)+(t||0)<=("Page"===o?s.width:a.viewPortWidth)&&(i?i.left:l.left)+(t||0)>=0&&(i?i.bottom:l.bottom)+(e||0)<=("Page"===o?s.height:a.viewPortHeight)&&(i?i.top:l.top)+(e||0)>=0||"None"!==this.diagram.layout.type&&r)}return!0},n.prototype.dragSelectedObjects=function(t,e){var i=this,r=this.diagram.selectedItems;this.state&&!this.state.backup&&(this.state.backup={},this.state.backup.offsetX=r.offsetX,this.state.backup.offsetY=r.offsetY),r=XI(this.diagram,r)||r;var s=this.diagram.selectedItems.nodes.filter(function(c){return"SwimLane"===c.shape.type});if(s.length>0&&!this.diagram.currentSymbol&&this.diagram.selectedItems.nodes.length>1){var o=this.diagram.selectedItems.nodes.filter(function(c){return""===c.parentId||"SwimLane"!==i.diagram.nameTable[c.parentId].shape.type});if(o.length>0){for(var a=0;a0||l.length>1)&&(o=o.concat(l),this.diagram.selectedItems.nodes.splice(0,this.diagram.selectedItems.nodes.length),o.forEach(function(c){i.diagram.selectedItems.nodes.push(c)}),r=this.diagram.selectedItems,this.diagram.selectedObject.helperObject=void 0)}}if(this.checkBoundaryConstraints(t,e)){this.diagram.diagramActions=this.diagram.diagramActions|ee.PreventZIndexOnDragging|ee.DragUsingMouse;var h=this.diagram.selectedObject.actualObject;return(h&&h instanceof te&&h.isLane&&Gx(h,this.diagram)||!h||!h.isLane)&&this.diagram.drag(r,t,e),this.diagram.diagramActions=this.diagram.diagramActions&~(ee.PreventZIndexOnDragging|ee.DragUsingMouse),this.diagram.refreshCanvasLayers(),this.checkHtmlObjectDrag(r),!0}return!1},n.prototype.checkHtmlObjectDrag=function(t){var e=!1;this.diagram.views&&this.diagram.views.length>1&&(t instanceof si?e=t.nodes.some(function(i){return i.shape&&"HTML"===i.shape.type}):t.shape&&"HTML"===t.shape.type&&(e=!0),e&&this.resetOverviewCanvas())},n.prototype.resetOverviewCanvas=function(){for(var t=0,e=this.diagram.views;t0&&(this.layoutAnimateModule.stopCurrentAnimation(this.objectStore[0],e,t),this.objectStore=[]),a=this.diagram.doLayout(),this.objectStore.push(a)),this.canUpdateTemplate=!1,this.diagram.blazorActions&=~on.expandNode,this.diagram.preventNodesUpdate=r,this.diagram.layoutAnimateModule&&this.diagram.organizationalChartModule&&!i)this.diagram.allowServerDataBinding=!1,this.layoutAnimateModule.expand(this.diagram.layout.enableAnimation,a,t,this.diagram);else{var l={element:$(t),state:!!t.isExpanded};this.triggerEvent(Ce.expandStateChange,l),this.diagram.lineRoutingModule&&this.diagram.constraints&rt.LineRouting&&"ComplexHierarchicalTree"!==this.diagram.layout.type&&this.diagram.resetSegments()}return this.diagram.layout.fixedNode=""===o?"":this.diagram.layout.fixedNode,a},n.prototype.getparentexpand=function(t,e,i,r){for(var s,o=0;o0&&(this.diagram.selectedItems.wrapper.rotateAngle=this.diagram.selectedItems.rotateAngle=s.rotateAngle),r instanceof te&&"SwimLane"!==r.shape.type&&!r.isLane&&!r.isPhase&&!r.isHeader)(r.offsetX!==r.wrapper.offsetX||r.offsetY!==r.wrapper.offsetY||r.width!==r.wrapper.width||r.height!==r.wrapper.height||r.rotateAngle!==r.wrapper.rotateAngle)&&(r.offsetX+=o,r.offsetY+=a,r.width+=l,r.height+=h,r.rotateAngle+=c,this.diagram.nodePropertyChange(r,{},{offsetX:r.offsetX,offsetY:r.offsetY,width:r.width,height:r.height,rotateAngle:r.rotateAngle})),e=this.diagram.spatialSearch.findObjects(r.wrapper.outerBounds);else if(r instanceof si)for(var d=0;d30||g.wrapper.outerBounds.topCenter.y-f.wrapper.outerBounds.bottomCenter.y>30)&&this.diagram.lineRoutingModule.refreshConnectorSegments(this.diagram,p,!0)}}this.updateSelector(),this.diagram.protectPropertyChange(!1)}},n.prototype.drawSelectionRectangle=function(t,e,i,r){this.diagram.drawSelectionRectangle(t,e,i,r)},n.prototype.startGroupAction=function(){this.diagram.startGroupAction()},n.prototype.endGroupAction=function(){this.diagram.endGroupAction()},n.prototype.removeChildFromBPmn=function(t,e,i){var r=this.diagram.nameTable[t.id]||t.nodes[0];if(i&&r&&r.processId&&r.processId===i.wrapper.id){var s=$(r);s.processId=r.processId,this.diagram.startGroupAction();var o=this.diagram.nameTable[r.processId].shape.activity.subProcess.processes||[];o.splice(o.indexOf(r.id),1),this.diagram.bpmnModule.removeChildFromBPMN(this.diagram.nameTable[r.processId].wrapper,r.id,this.diagram),this.diagram.nameTable[r.id].processId="",r.offsetX=r.wrapper.offsetX,r.offsetY=r.wrapper.offsetY;var a=$(r);this.addHistoryEntry({type:"PositionChanged",redoObject:{nodes:[a]},undoObject:{nodes:[s]},category:"Internal"}),this.diagram.endGroupAction()}},n.prototype.isDroppable=function(t,e){var i=this.diagram.nameTable[t.id]||t.nodes[0];return i instanceof te&&(!ce()&&"TextAnnotation"===i.shape.shape||("Group"===e.shape.shape&&(e.shape.activity.subProcess.collapsed=!1),!(i&&"Bpmn"===i.shape.type&&(i.processId===e.id||i.id===e.processId||"Bpmn"===e.shape.type&&!(e instanceof de)&&e.shape.activity&&e.shape.activity.subProcess&&e.shape.activity.subProcess.collapsed))))},n.prototype.renderHighlighter=function(t,e,i){if(new Ne,t.target instanceof te||t.target instanceof de||e&&(t.source instanceof te||t.source instanceof de)){var a=this.findTarget(e?t.sourceWrapper:t.targetWrapper,e?t.source:t.target,i,!0),l=void 0;if(a instanceof Bd)for(var h=a.id,c=t.target,u=0,p=c.wrapper.children[0].children[0].children[2].children;u0){var r=0;t[0]=this.diagram.nameTable[t[0].id]||t[0];var s="Object"===i?yr(t[0].wrapper):this.diagram.selectedItems.wrapper.bounds,o={nodes:[],connectors:[]},a={nodes:[],connectors:[]};for(r="Object"===i?r+1:r;r0){var i=0,r=0,s=0,o=0,a=0,l=0,h=0,c=0,d={nodes:[],connectors:[]},u={nodes:[],connectors:[]};for(i=0;io.center.y&&(r=n[parseInt(e.toString(),10)],n[parseInt(e.toString(),10)]=n[parseInt(i.toString(),10)],n[parseInt(i.toString(),10)]=r):s.center.x>o.center.x&&(r=n[parseInt(e.toString(),10)],n[parseInt(e.toString(),10)]=n[parseInt(i.toString(),10)],n[parseInt(i.toString(),10)]=r)}}return n}(t,e),i=1;i0){var i=0,r={x:.5,y:.5};t[0]=this.diagram.nameTable[t[0].id]||t[0];var s=yr(t[0].wrapper),o={nodes:[],connectors:[]},a={nodes:[],connectors:[]};for(i=1;ii.zIndex){for(var s=this.diagram.layers.indexOf(this.diagram.getActiveLayer()),o=this.diagram.layers[parseInt(s.toString(),10)].zIndexTable,a=JSON.parse(JSON.stringify(o)),l=i.zIndex,h=r.zIndex,c=h;c>=l;c--)l!==c?o[c-1]?(o[parseInt(c.toString(),10)]=o[c-1],this.diagram.nameTable[o[parseInt(c.toString(),10)]].zIndex=c):(o[c-1]=o[parseInt(c.toString(),10)],this.diagram.nameTable[o[c-1]].zIndex=c,delete o[parseInt(c.toString(),10)]):this.swapZIndexObjects(h,o,r.id,a);"SVG"===this.diagram.mode?(this.moveSvgNode(e.parentId,i.id),this.updateNativeNodeIndex(e.parentId,i.id)):this.diagram.refreshCanvasLayers()}},n.prototype.findLeastIndexConnector=function(t,e,i){for(var r=0;rs.zIndex&&(i=s)}return i},n.prototype.findLeastIndexObject=function(t,e){var i=t;return t instanceof te&&(i=this.findLeastIndexConnector(t.inEdges,e,i),i=this.findLeastIndexConnector(t.outEdges,e,i)),i},n.prototype.checkSelection=function(t,e){var i;if(1===t.nodes.length&&0===t.connectors.length)if(cs(this.diagram,t.nodes[0],!0)){var r=t.nodes[0];if("SwimLane"===(i="SwimLane"===t.nodes[0].shape?t.nodes[0]:this.diagram.nameTable[t.nodes[0].parentId]).shape.type){var s="Horizontal"===i.shape.orientation;(r.isPhase&&(s&&"ResizeSouth"===e||!s&&"ResizeEast"===e)||r.isLane&&(s&&"ResizeEast"===e||!s&&"ResizeSouth"===e))&&W3(this.diagram,i,e)}else if("Grid"===i.container.type)if("Horizontal"===i.container.orientation&&1===r.rowIndex||"Vertical"===i.container.orientation&&r.rowIndex>0&&r.columnIndex>0){if("ResizeSouth"===e)for(var o=0;o1&&(this.diagram.realActions=this.diagram.realActions|$i.hScrollbarMoved,this.scrolled=!0),this.diagram.scrollSettings.horizontalOffset=t},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"verticalOffset",{get:function(){return this.vOffset},set:function(t){this.vOffset=t,Math.abs(this.vOffset-this.diagram.scrollSettings.verticalOffset)>1&&(this.diagram.realActions=this.diagram.realActions|$i.vScrollbarMoved,this.scrolled=!0),this.diagram.scrollSettings.verticalOffset=t},enumerable:!0,configurable:!0}),n.prototype.getBounds=function(){var e=this.diagram.spatialSearch.getPageBounds(0,0);return(e.x<0||e.y<0)&&!this.diagram.pageSettings.multiplePage?this.getPageBounds(void 0,void 0,!0,!0):this.getPageBounds(void 0,void 0,!0)},n.prototype.updateScrollOffsets=function(t,e){var i,r,s=this.getBounds();s.x*=this.currentZoom,s.y*=this.currentZoom,s.width*=this.currentZoom,s.height*=this.currentZoom,i=Math.max(0,t-s.left),r=Math.max(0,e-s.top),void 0!==t&&void 0!==e?(this.horizontalOffset=i,this.verticalOffset=r,this.diagram.setOffset(i,r)):this.diagram.setOffset(-this.horizontalOffset-s.x,-this.verticalOffset-s.y),this.transform={tx:Math.max(this.horizontalOffset,-s.left)/this.currentZoom,ty:Math.max(this.verticalOffset,-s.top)/this.currentZoom,scale:this.currentZoom}},n.prototype.setScrollOffset=function(t,e){this.scrolled=!1;var i=this.getBounds();i.x*=this.currentZoom,i.y*=this.currentZoom,i.width*=this.currentZoom,i.height*=this.currentZoom;var r=-i.left,s=-i.top,o=!1,a=this.viewPortWidth*this.currentZoom,l=this.viewPortHeight*this.currentZoom,h=r-t;if(h!==this.horizontalOffset){rh?this.horizontalOffset-=t:this.horizontalOffset=h,o=!0);var c=Math.max(i.right+this.vScrollSize,a);if(!o&&c<-h+this.viewPortWidth){var d=-h+a-this.vScrollSize,u=-this.horizontalOffset+a-this.vScrollSize;this.horizontalOffset=dd-u?h:-(i.right+this.vScrollSize-a),o=!0}o||(this.horizontalOffset=r-t)}o=!1;var p=s-e;if(p!==this.verticalOffset){sp?this.verticalOffset-=e:this.verticalOffset=p,o=!0);var f=Math.max(i.bottom+this.hScrollSize,l);if(!o&&f<-p+l){var g=-p+l-this.hScrollSize,v=-this.verticalOffset+l-this.hScrollSize;this.verticalOffset=gg-v?p:-(i.bottom+this.hScrollSize-l),o=!0}o||(this.verticalOffset=s-e)}this.transform={tx:Math.max(this.horizontalOffset,-i.left)/this.currentZoom,ty:Math.max(this.verticalOffset,-i.top)/this.currentZoom,scale:this.currentZoom},this.setSize()},n.prototype.getObjects=function(t,e){for(var i=[],r=0;r0){for(var l=0;l0){h.push(i[parseInt(o.toString(),10)].id);for(var d=0;d=e.bottom&&(l=0),-this.horizontalOffset<=e.x&&-this.horizontalOffset+this.viewPortWidth>=e.right&&(a=0),this.hScrollSize=a,this.vScrollSize=l;var h=this.diagramWidth,c=this.diagramHeight;this.diagramWidth=Math.max(e.right,-this.horizontalOffset+this.viewPortWidth-l)-i,this.diagramHeight=Math.max(e.bottom,-this.verticalOffset+this.viewPortHeight-a)-r,(h!==this.diagramWidth||c!==this.diagramHeight)&&"Diagram"!==this.diagram.scrollSettings.scrollLimit&&this.diagram.setSize(this.diagramWidth,this.diagramHeight),"Diagram"===this.diagram.scrollSettings.scrollLimit&&(h===this.diagramWidth&&c===this.diagramHeight&&1===this.currentZoom||this.diagram.diagramActions&&t&&(!this.diagram.diagramActions||!t||0===this.verticalOffset&&this.verticalOffset!==t.y||0===this.horizontalOffset&&this.horizontalOffset!==t.x)?t&&h===this.diagramWidth&&c===this.diagramHeight&&(this.diagram.diagramCanvas.scrollHeight>this.viewPortHeight&&t.y<0&&this.horizontalOffset===t.x&&0===this.verticalOffset||this.diagram.diagramCanvas.scrollWidth>this.viewPortWidth&&t.x<0&&this.verticalOffset===t.y&&0===this.horizontalOffset)&&(this.verticalOffset=t.y,this.horizontalOffset=t.x,this.transform={tx:Math.max(t.x,-e.left)/this.currentZoom,ty:Math.max(t.y,-e.top)/this.currentZoom,scale:this.currentZoom}):(this.diagram.scrollActions&ca.Interaction&&t&&(this.transform={tx:Math.max(t.x,-e.left/this.currentZoom)/this.currentZoom,ty:Math.max(t.y,-e.top/this.currentZoom)/this.currentZoom,scale:this.currentZoom},this.horizontalOffset=t.x,this.verticalOffset=t.y),this.diagram.setSize(this.diagramWidth,this.diagramHeight),!(this.diagram.scrollActions&ca.PropertyChange)&&t&&(this.horizontalOffset=t.x,this.verticalOffset=t.y,this.transform={tx:Math.max(t.x,-e.left)/this.currentZoom,ty:Math.max(t.y,-e.top)/this.currentZoom,scale:this.currentZoom}))),this.diagram.transformLayers(),this.diagram.element.style.overflow="hidden"},n.prototype.setViewPortSize=function(t,e){this.viewPortWidth=t,this.viewPortHeight=e},n.prototype.getPageBounds=function(t,e,i,r){var o,s=new Ne;if("Content"===e||r||null===this.diagram.pageSettings.width||null===this.diagram.pageSettings.height){var u=t?void 0:0;o=this.diagram.spatialSearch.getPageBounds(u,u)}else{var a=this.diagram.pageSettings.width,l=this.diagram.pageSettings.height,h=0,c=0;if(this.diagram.pageSettings.multiplePage){if((s=this.diagram.spatialSearch.getPageBounds(0,0)).right>a&&(a*=d=Math.ceil(s.right/a)),s.bottom>l&&(l*=d=Math.ceil(s.bottom/l)),s.left<0&&Math.abs(s.left)>h){var d=Math.ceil(Math.abs(s.left)/this.diagram.pageSettings.width);h=this.diagram.pageSettings.width*d}s.top<0&&Math.abs(s.top)>c&&(d=Math.ceil(Math.abs(s.top)/this.diagram.pageSettings.height),c=this.diagram.pageSettings.height*d)}o=new Ne(-h,-c,a+h,l+c)}if(i){var p=this.diagram.scrollSettings.padding;o.x-=p.left,o.y-=p.top,o.width+=p.left+p.right,o.height+=p.top+p.bottom}return o},n.prototype.getPageBreak=function(t){for(var e=0,i=0,r=-1,s=[],c=this.diagram.pageSettings.margin.left,d=this.diagram.pageSettings.margin.right,u=this.diagram.pageSettings.margin.top,p=this.diagram.pageSettings.margin.bottom,f=1,g=1;t.width>e;)(e+=this.diagram.pageSettings.width?this.diagram.pageSettings.width:t.width)===this.diagram.pageSettings.width&&(s[++r]={x1:t.left+c,y1:t.top+u,x2:t.left+c,y2:t.bottom-p}),ei;)(i+=this.diagram.pageSettings.height?this.diagram.pageSettings.height:t.height)===this.diagram.pageSettings.height&&(s[++r]={x1:t.left+c,y1:t.top+u,x2:t.right-d,y2:t.top+u}),i=this.diagram.scrollSettings.minZoom||l||t>=1)){this.currentZoom*=t;var c=this.getPageBounds(void 0,void 0,!0);c.x*=this.currentZoom,c.y*=this.currentZoom;var d=Hi();Xp(d,t,t,r.x,r.y),r3(d,e||0,i||0),Mx(h,d);var u=Je(h,{x:0,y:0});if(1===t&&(u=this.applyScrollLimit(u.x,u.y,s,o,a)),a=-c.y>=u.y&&-c.x>=u.x&&a,(this.diagram.scrollActions&ca.PropertyChange||!(this.diagram.scrollActions&ca.Interaction)||"Diagram"!==this.diagram.scrollSettings.scrollLimit||a)&&(this.transform={tx:Math.max(u.x,-c.left)/this.currentZoom,ty:Math.max(u.y,-c.top)/this.currentZoom,scale:this.currentZoom},this.horizontalOffset=u.x,this.verticalOffset=u.y),this.setSize(u),"SVG"!==this.diagram.mode&&Ds(this.diagram)&&this.diagram.scroller.virtualizeElements(),"SVG"!==this.diagram.mode&&!Ds(this.diagram)&&this.diagram.refreshDiagramLayer(),this.diagram.setOffset(-this.horizontalOffset-c.x,-this.verticalOffset-c.y),tb(this.diagram),this.diagram.views&&this.diagram.views.overview){var p=this.diagram.views.overview,f=p.scrollOverviewRect(p.parent.scroller.horizontalOffset,p.parent.scroller.verticalOffset,p.parent.scroller.currentZoom,!0);p.updateOverviewrect(-f.x,-f.y,f.width,f.height),p.updateView(p)}}}},n.prototype.fitToPage=function(t){var e=(t=t||{}).mode,i=t.region,r=t.margin||{},s=t.canZoomIn,o=t.customBounds,a=t.canZoomOut;r.bottom=r.bottom||25,r.top=r.top||25,r.left=r.left||25,r.right=r.right||25;var h,l=o,c=-this.horizontalOffset,d=-this.verticalOffset;if("PageSettings"===(i=i||"PageSettings")&&this.diagram.pageSettings.width&&this.diagram.pageSettings.height||this.diagram.nodes.length>0||this.diagram.connectors.length>0){e=e||"Page","CustomBounds"!==i&&(l=this.getPageBounds(!0,i,!0));var u={x:0,y:0};r.left+r.right>this.viewPortWidth&&(this.viewPortWidth<=100?(r.left=5,r.right=5):(r.left=25,r.right=25)),r.top+r.bottom>this.viewPortHeight&&(this.viewPortHeight<=100?(r.top=5,r.bottom=5):(r.top=25,r.bottom=25)),u.x=(this.viewPortWidth-(r.left+r.right))/l.width,u.y=(this.viewPortHeight-(r.top+r.bottom))/l.height,!s&&l.width-this.horizontalOffset-a+this.viewPortWidth&&(i=o.right-this.viewPortWidth,i+=20),o.x<-a&&(i=o.x),o.bottom>-l+this.viewPortHeight&&(r=o.bottom-this.viewPortHeight,r+=20),o.y<-l&&(r=o.y),this.zoom(1,-this.horizontalOffset-i,-this.verticalOffset-r,null,void 0,e))},n.prototype.bringToCenter=function(t){var e=this.currentZoom,i=new Ne(t.x*e,t.y*e,t.width*e,t.height*e),r=i.x+i.width/2-this.viewPortWidth/2,s=i.y+i.height/2-this.viewPortHeight/2;this.zoom(1,-this.horizontalOffset-(r*=-1),-this.verticalOffset-(s*=-1),null)},n.prototype.applyScrollLimit=function(t,e,i,r,s){if("Infinity"===this.diagram.scrollSettings.scrollLimit&&void 0===i&&!r&&(t=-t,e=-e),"Infinity"!==this.diagram.scrollSettings.scrollLimit){var o=void 0;if("Limited"===this.diagram.scrollSettings.scrollLimit){var a=this.diagram.scrollSettings.scrollableArea;o=new Ne(a.x,a.y,a.width,a.height)}(o=o||(s?this.getPageBounds():this.getPageBounds(!0))).x*=this.currentZoom,o.y*=this.currentZoom,o.width*=this.currentZoom,o.height*=this.currentZoom,void 0!==i&&(t*=-1,e*=-1),r&&(t*=-1,e*=-1);var l=Math.max(o.right,this.viewPortWidth);if(!r&&!(t<=o.x&&(t+this.viewPortWidth>=o.right||t>=o.right-this.viewPortWidth)||t>=o.x&&t+this.viewPortWidth<=l))if(t>=o.x)t=Math.max(o.x,Math.min(t,t-(t+this.viewPortWidth-this.vScrollSize-l)));else{var h=o.right-this.viewPortWidth;t=Math.min(h,o.x)}var c=Math.max(o.bottom,this.viewPortHeight);r||e<=o.y&&e+this.viewPortHeight>=o.bottom||e>=o.y&&e+this.viewPortHeight<=c||(e>=o.y?e=Math.max(o.y,Math.min(e,e-(e+this.viewPortHeight-this.hScrollSize-c))):(h=o.bottom-this.viewPortHeight,e=Math.min(o.y,h))),t*=-1,e*=-1}return{x:t,y:e}},n}(),tae=function(){function n(t,e,i,r,s){this.objects=[],this.left=t,this.top=e,this.width=i,this.height=r,this.spatialSearch=s}return n.prototype.findQuads=function(t,e){null!=this.first&&this.first.isIntersect(t)&&this.first.findQuads(t,e),null!=this.second&&this.second.isIntersect(t)&&this.second.findQuads(t,e),null!=this.third&&this.third.isIntersect(t)&&this.third.findQuads(t,e),null!=this.fourth&&this.fourth.isIntersect(t)&&this.fourth.findQuads(t,e),this.objects.length>0&&e.push(this)},n.prototype.isIntersect=function(t){return!(this.left+this.widtht.right||this.top>t.bottom)},n.prototype.selectQuad=function(){for(var i,t=null,e=this;null!=e;)i=e.getQuad(t),e=i.source,t=i.target||t;return t},n.prototype.getQuad=function(t){var e=this.width/2,i=this.height/2;if(e>=1e3&&i>=1e3){var r=this.left+e,s=this.top+i;if(this.spatialSearch.childRight<=r){if(this.spatialSearch.childBottom<=s)return this.first||((o=new n(this.left,this.top,e,i,this.spatialSearch)).parent=this,this.first=o),{source:this.first};if(this.spatialSearch.childTop>=s)return this.third||((o=new n(this.left,s,e,i,this.spatialSearch)).parent=this,this.third=o),{source:this.third}}else if(this.spatialSearch.childLeft>=r){if(this.spatialSearch.childBottom<=s)return this.second||((o=new n(r,this.top,e,i,this.spatialSearch)).parent=this,this.second=o),{source:this.second};var o;if(this.spatialSearch.childTop>=s)return this.fourth||((o=new n(r,s,e,i,this.spatialSearch)).parent=this,this.fourth=o),{source:this.fourth}}}return this.objects.push(this.spatialSearch.childNode),{target:this}},n.prototype.isContained=function(){return this.spatialSearch.childLeft>=this.left&&this.spatialSearch.childRight<=this.left+this.width&&this.spatialSearch.childTop>=this.top&&this.spatialSearch.childBottom<=this.top+this.height},n.prototype.addIntoAQuad=function(t){var e={};this.spatialSearch.setCurrentNode(t);for(var i=null;!e.isAdded;)i=(e=this.spatialSearch.parentQuad.add(i)).quad;return i},n.prototype.add=function(t){if(t=null,this.isContained())return{isAdded:!0,quad:t=this.selectQuad()};var e=void 0,i=!(0!==this.objects.length||this.first||this.second||this.third||this.fourth),r=2*this.width,s=2*this.height;return this.spatialSearch.childLeft=this.childLeft?(this.pageLeft=this.childLeft,this.leftElement=t,r=!0):t===this.leftElement&&(this.pageLeft=Number.MAX_VALUE,this.findLeft(this.parentQuad),r=!0)),(this.pageTop!==this.childTop||t!==this.topElement)&&(this.pageTop>=this.childTop?(this.pageTop=this.childTop,this.topElement=t,r=!0):t===this.topElement&&(this.pageTop=Number.MAX_VALUE,this.findTop(this.parentQuad),r=!0)),(this.pageBottom!==this.childBottom||t!==this.bottomElement)&&(this.pageBottom<=this.childBottom?(r=!0,this.pageBottom=this.childBottom,this.bottomElement=t):t===this.bottomElement&&(this.pageBottom=-Number.MAX_VALUE,this.findBottom(this.parentQuad),r=!0)),(this.pageRight!==this.childRight||t!==this.rightElement)&&(this.pageRight<=this.childRight?(this.pageRight=this.childRight,this.rightElement=t,r=!0):t===this.rightElement&&(this.pageRight=-Number.MAX_VALUE,this.findRight(this.parentQuad),r=!0)),r}return this.setCurrentNode(null),!1},n.prototype.isWithinPageBounds=function(t){return t.left>=this.pageLeft&&t.right<=this.pageRight&&t.top>=this.pageTop&&t.bottom<=this.pageBottom},n.prototype.findQuads=function(t){var e=[];return this.parentQuad.findQuads(t,e),e},n.prototype.findObjects=function(t){for(var i=[],r=0,s=this.findQuads(t);r=r.outerBounds.left&&(this.pageLeft=r.outerBounds.left,this.leftElement=r)}},n.prototype.findTop=function(t){t.first||t.second?(t.first&&this.findTop(t.first),t.second&&this.findTop(t.second)):(t.third&&this.findTop(t.third),t.fourth&&this.findTop(t.fourth));for(var e=0,i=t.objects;e=r.outerBounds.top&&(this.pageTop=r.outerBounds.top,this.topElement=r)}},n.prototype.setCurrentNode=function(t){if(this.childNode=t,t){var e=t.outerBounds;this.childLeft=Number(e.left),this.childTop=Number(e.top),this.childRight=Number(e.right),this.childBottom=Number(e.bottom)}else this.childLeft=Number.MAX_VALUE,this.childTop=Number.MAX_VALUE,this.childRight=-Number.MAX_VALUE,this.childBottom=-Number.MAX_VALUE},n.prototype.getPageBounds=function(t,e){if(this.pageLeft===Number.MAX_VALUE)return new Ne(0,0,0,0);var i=void 0!==t?Math.min(this.pageLeft,0):this.pageLeft,r=void 0!==e?Math.min(this.pageTop,0):this.pageTop;return new Ne(Math.round(i),Math.round(r),Math.round(this.pageRight-i),Math.round(this.pageBottom-r))},n.prototype.getQuad=function(t){return this.quadTable[t.id]},n}(),iae=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),nae=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return iae(t,n),function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);r>3&&s&&Object.defineProperty(t,e,s)}([I(!1)],t.prototype,"preventDefaults",void 0),t}(Ee),sae=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),o_=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},oae=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return sae(t,n),o_([I("")],t.prototype,"action",void 0),o_([I("")],t.prototype,"cursor",void 0),t}(Ee),a_=function(){function n(){this.size=20,this.intermediatePoints=[],this.gridCollection=[],this.startArray=[],this.targetGridCollection=[],this.sourceGridCollection=[],this.considerWalkable=[]}return n.prototype.lineRouting=function(t){var e=t.connectors.length;if(this.renderVirtualRegion(t),e>0)for(var i=0;i=t.right||e.right<=t.left||e.top>=t.bottom||e.bottom<=t.top)},n.prototype.findEndPoint=function(t,e,i){var r,s;if(e&&""!==t.sourcePortID&&t.sourcePortWrapper||!e&&""!==t.targetPortID&&t.targetPortWrapper){s=zo(r=e?{x:t.sourcePortWrapper.offsetX,y:t.sourcePortWrapper.offsetY}:{x:t.targetPortWrapper.offsetX,y:t.targetPortWrapper.offsetY},void 0,e?t.sourceWrapper.bounds:t.targetWrapper.bounds);var o=e?t.sourcePortWrapper.bounds:t.targetPortWrapper.bounds;r=i?"Top"===s?{x:o.topCenter.x,y:o.topCenter.y}:"Left"===s?{x:o.middleLeft.x,y:o.middleLeft.y}:"Right"===s?{x:o.middleRight.x,y:o.middleRight.y}:{x:o.bottomCenter.x,y:o.bottomCenter.y}:{x:o.center.x,y:o.center.y}}else r=e&&this.startNode||!e&&this.targetNode?e?{x:this.startNode.wrapper.offsetX,y:this.startNode.wrapper.offsetY}:{x:this.targetNode.wrapper.offsetX,y:this.targetNode.wrapper.offsetY}:e?{x:t.sourcePoint.x,y:t.sourcePoint.y}:{x:t.targetPoint.x,y:t.targetPoint.y};return r},n.prototype.refreshConnectorSegments=function(t,e,i,r){var h,c,p,f,g,y,S,b,M,w,C,s=e.sourceID,o=e.targetID,a=e.sourcePortID,l=e.targetPortID;if(function Jre(n,t){var e=0;return n.constraints&qe.LineRouting?e=n.constraints&qe.LineRouting:n.constraints&qe.InheritLineRouting&&(e=t.constraints&rt.LineRouting),e}(e,t)||r){this.startNode=t.nameTable[""+s],this.targetNode=t.nameTable[""+o],this.intermediatePoints=[],this.startArray=[],this.targetGridCollection=[],this.sourceGridCollection=[],this.startGrid=void 0,this.targetGrid=void 0;for(var D=0;D0;){var L=this.startArray.pop();if(L){for(D=0;D1&&(e.segments=[]),this.updateConnectorSegments(t,this.intermediatePoints,this.gridCollection,e,i)){this.considerWalkable=[];break e}this.targetGridCollection.splice(this.targetGridCollection.indexOf(O),1),L=this.startArray.pop()}}L&&this.findPath(L)}}}},n.prototype.checkChildNodes=function(t,e){var i=!1,r=!1;if(t.nodeId.length>=1&&!e)for(var s=0;s1&&this.targetGridCollection[0].nodeId.length>1)for(var c=0;c<=1;c++){for(var d=this.targetGridCollection[parseInt(c.toString(),10)].gridX,u=this.targetGridCollection[parseInt(c.toString(),10)].gridY,p=this.targetGridCollection[parseInt(c.toString(),10)].nodeId,f=void 0,g=0;g=e.right&&t.top<=e.top&&t.bottom>=e.bottom},n.prototype.getEndvalue=function(t,e){return this.gridCollection[t.gridX][t.gridY].walkable?t:"left"===e?this.getEndvalue(this.gridCollection[t.gridX-1][t.gridY],e):"right"===e?this.getEndvalue(this.gridCollection[t.gridX+1][t.gridY],e):"top"===e?this.getEndvalue(this.gridCollection[t.gridX][t.gridY-1],e):"bottom"===e?this.getEndvalue(this.gridCollection[t.gridX][t.gridY+1],e):t},n.prototype.changeValue=function(t,e,i){t.walkable||this.considerWalkable.push(t);for(var r,s=0;s<=e;s++)"left"===i?r=this.gridCollection[t.gridX-s][t.gridY]:"right"===i?r=this.gridCollection[t.gridX+s][t.gridY]:"top"===i?r=this.gridCollection[t.gridX][t.gridY-s]:"bottom"===i&&(r=this.gridCollection[t.gridX][t.gridY+s]),r.walkable||this.considerWalkable.push(r)},n.prototype.getIntermediatePoints=function(t){var e;for(this.intermediatePoints=[];t;)this.intermediatePoints.push({x:t.gridX,y:t.gridY}),t=t.parent;this.intermediatePoints.reverse(),this.intermediatePoints.length>=1&&void 0!==this.intermediatePoints[0]&&void 0!==this.intermediatePoints[1]&&(this.intermediatePoints[0].x===this.intermediatePoints[1].x?this.intermediatePoints[0].y=1&&u.length>1&&(g=u[u.length-2].x!==u[u.length-1].x?u[u.length-2].x>u[u.length-1].x?"Left":"Right":u[u.length-2].y>u[u.length-1].y?"Top":"Bottom"),M>=2&&v===g&&u.length>1&&u.splice(u.length-2,1),v=g);if(u&&u.length>1){for(var w=0;wD.x?S.bounds.middleLeft:S.bounds.middleRight),w===u.length-2&&""===r.targetPortID&&y&&(l=C.x>D.x?y.bounds.middleRight:y.bounds.middleLeft),0===w&&b&&(C.x=b.x,C.y=D.y=b.y),w===u.length-2&&l&&(w>0&&r.targetDecorator&&l.x-D.x<0&&Math.abs(l.x-C.x)0&&r.targetDecorator&&l.x-D.x>0&&Math.abs(l.x-C.x)D.y?S.bounds.topCenter:S.bounds.bottomCenter),w===u.length-2&&""===r.targetPortID&&y&&(l=C.y>D.y?y.bounds.bottomCenter:y.bounds.topCenter),0===w&&b&&(C.y=b.y,C.x=D.x=b.x),w===u.length-2&&l&&(w>0&&r.targetDecorator&&l.y-D.y<0&&Math.abs(l.y-C.y)0&&r.targetDecorator&&l.y-D.y>0&&Math.abs(l.y-C.y)D.x?(p="Left",f=C.x-D.x):(p="Right",f=D.x-C.x):C.y>D.y?(p="Top",f=C.y-D.y):(p="Bottom",f=D.y-C.y),o.push({type:"Orthogonal",length:f,direction:p})}}if(o&&o.length>0){var A=o[o.length-1];if(1===o.length&&(A.length-=20),A.length<10&&2===o.length&&(o.pop(),o.length>0&&(o[0].length-=20,A=o[0])),r.targetDecorator&&("Top"===A.direction||"Bottom"===A.direction)&&A.length>r.targetDecorator.height+1||("Right"===A.direction||"Left"===A.direction)&&A.length>r.targetDecorator.width+1)return r.segments=o,s&&t.connectorPropertyChange(r,{},{type:"Orthogonal",segments:o}),!0}return!1},n.prototype.findPath=function(t){for(var e,i=[],r=this.findNearestNeigbours(t,this.gridCollection,!0),s=0;sl)&&(e.x!==t.gridX||e.y!==t.gridY)&&(i.push(e),o.previousDistance=l,o.afterDistance=o.afterDistance||this.manhattan(Math.abs(e.x-this.targetGrid.gridX),Math.abs(e.y-this.targetGrid.gridY)),o.totalDistance=o.previousDistance+o.afterDistance,o.parent=t)}if(i.length>0)for(s=0;st?i*t+e:i*e+t},n.prototype.manhattan=function(t,e){return t+e},n.prototype.findNearestNeigbours=function(t,e,i){var r=[],s=t.parent;if(s){var o=(t.gridX-s.gridX)/Math.max(Math.abs(t.gridX-s.gridX),1),a=(t.gridY-s.gridY)/Math.max(Math.abs(t.gridY-s.gridY),1);0!==o?(this.isWalkable(t.gridX,t.gridY-1,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX][t.gridY-1])&&r.push(e[t.gridX][t.gridY-1]),this.isWalkable(t.gridX,t.gridY+1,!0)&&this.sourceGridCollection.indexOf(e[t.gridX][t.gridY+1])&&r.push(e[t.gridX][t.gridY+1]),this.isWalkable(t.gridX+o,t.gridY,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX+o][t.gridY])&&r.push(e[t.gridX+o][t.gridY])):0!==a&&(this.isWalkable(t.gridX-1,t.gridY,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX-1][t.gridY])&&r.push(e[t.gridX-1][t.gridY]),this.isWalkable(t.gridX+1,t.gridY,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX+1][t.gridY])&&r.push(e[t.gridX+1][t.gridY]),this.isWalkable(t.gridX,t.gridY+a,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX][t.gridY+a])&&r.push(e[t.gridX][t.gridY+a]))}else this.neigbour(t,"top",r,i),this.neigbour(t,"right",r,i),this.neigbour(t,"bottom",r,i),this.neigbour(t,"left",r,i);return r},n.prototype.neigbour=function(t,e,i,r){for(var o,s=1;s>0;){var a="top"===e||"bottom"===e?t.gridX:"left"===e?t.gridX-s:t.gridX+s,l="right"===e||"left"===e?t.gridY:"top"===e?t.gridY-s:t.gridY+s;if((o=this.gridCollection[parseInt(a.toString(),10)][parseInt(l.toString(),10)])&&(r&&-1===this.sourceGridCollection.indexOf(o)||!r&&-1===this.targetGridCollection.indexOf(o)))return i&&this.isWalkable(a,l)&&i.push(o),s;if(!(a>0&&l>0))break;s++}return null},n.prototype.resetGridColl=function(t,e,i){for(var s,r=1;r>0;){var o="top"===e||"bottom"===e?t.gridX:"left"===e?t.gridX-r:t.gridX+r,a="right"===e||"left"===e?t.gridY:"top"===e?t.gridY-r:t.gridY+r;if((s=this.gridCollection[parseInt(o.toString(),10)][parseInt(a.toString(),10)])&&(i&&-1===this.sourceGridCollection.indexOf(s)||!i&&-1===this.targetGridCollection.indexOf(s))){if(this.isWalkable(o,a))break;var l=this.gridCollection[parseInt(o.toString(),10)][parseInt(a.toString(),10)];this.considerWalkable.push(l)}if(!(o>0&&a>0))break;"top"===e||"left"===e?r--:r++}return null},n.prototype.isWalkable=function(t,e,i){if(t>=0&&t=0&&e0?1:-1,this.isWalkable(h,c-1)&&!this.isWalkable(h-a,c-1)||this.isWalkable(h,c+1)&&!this.isWalkable(h-a,c+1)))return{x:t,y:e};if(0!==l){if(l=l>0?1:-1,this.isWalkable(h-1,c)&&!this.isWalkable(h-1,c-l)||this.isWalkable(h+1,c)&&!this.isWalkable(h+1,c-l))return{x:t,y:e};if(this.findIntermediatePoints(h+1,c,h,c,s,o)||this.findIntermediatePoints(h-1,c,h,c,s,o))return{x:t,y:e}}return this.findIntermediatePoints(h+a,c+l,h,c,s,o)},n.prototype.destroy=function(){},n.prototype.getModuleName=function(){return"LineRouting"},n}(),aae=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),hae=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return aae(t,n),function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);r>3&&s&&Object.defineProperty(t,e,s)}([I(!0)],t.prototype,"inversedAlignment",void 0),t}(Ee),cae=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Oe=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},TT=function(n,t,e,i){return new(e||(e=Promise))(function(r,s){function o(h){try{l(i.next(h))}catch(c){s(c)}}function a(h){try{l(i.throw(h))}catch(c){s(c)}}function l(h){h.done?r(h.value):new e(function(c){c(h.value)}).then(o,a)}l((i=i.apply(n,t||[])).next())})},AT=function(n,t){var i,r,s,o,e={label:0,sent:function(){if(1&s[0])throw s[1];return s[1]},trys:[],ops:[]};return o={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function a(h){return function(c){return function l(h){if(i)throw new TypeError("Generator is already executing.");for(;e;)try{if(i=1,r&&(s=2&h[0]?r.return:h[0]?r.throw||((s=r.return)&&s.call(r),0):r.next)&&!(s=s.call(r,h[1])).done)return s;switch(r=0,s&&(h=[2&h[0],s.value]),h[0]){case 0:case 1:s=h;break;case 4:return e.label++,{value:h[1],done:!1};case 5:e.label++,r=h[1],h=[0];continue;case 7:h=e.ops.pop(),e.trys.pop();continue;default:if(!(s=(s=e.trys).length>0&&s[s.length-1])&&(6===h[0]||2===h[0])){e=0;continue}if(3===h[0]&&(!s||h[1]>s[0]&&h[1]0&&((!s.style||!s.style.fill)&&(o.style.fill="transparent"),(!s.style||!s.style.strokeColor)&&(o.style.strokeColor="transparent")),s.shape&&"UmlActivity"===s.shape.type&&nb(s,o),s.shape&&"SwimLane"===s.shape.type&&pF(s,o),r.nodeDefaults&&Ro(o,s,r.nodeDefaults),r.updateAnnotationText(o.annotations);if(e&&e.connectors)for(a=0;e&&e.connectors&&a0&&0===i.nodes.length)this.clearCollection(),a=!0;else{for(var g=0,v=Object.keys(e.nodes);g0&&0===i.connectors.length)this.clearCollection(!0),a=!0;else{for(var C=0,D=Object.keys(e.connectors);C0){this.renderSelector(!0);break}if(e.selectedItems.constraints){this.renderSelector(!0);break}break;case"snapSettings":this.updateSnapSettings(e);break;case"commandManager":this.initCommands();break;case"layout":o=!0;break;case"segmentThumbShape":this.updateSelector();break;case"dataSourceSettings":this.clear(),"None"===this.layout.type?a=!0:(this.initObjects(),o=!0);break;case"tooltip":l3(this);break;case"rulerSettings":this.updateRulerSettings(e);break;case"layers":this.updateLayer(e);break;case"scrollSettings":this.scrollActions|=ca.PropertyChange,this.updateScrollSettings(e),this.scrollActions&=~ca.PropertyChange,this.scrollSettings.horizontalOffset=-this.scroller.horizontalOffset||0,this.scrollSettings.verticalOffset=-this.scroller.verticalOffset||0;break;case"locale":e.locale!==i.locale&&(this.realActions|=$i.PreventDataInit,n.prototype.refresh.call(this),this.realActions&=~$i.PreventDataInit);break;case"contextMenuSettings":if(void 0!==e.contextMenuSettings.showCustomMenuOnly&&(this.contextMenuSettings.showCustomMenuOnly=e.contextMenuSettings.showCustomMenuOnly),void 0!==e.contextMenuSettings.show&&(this.contextMenuSettings.show=e.contextMenuSettings.show),e.contextMenuSettings.items){for(var A=e.contextMenuSettings.items,x=0,R=Object.keys(A);x0){for(var N=[],T=O.ports.length-1;T>=0;T--)"LineDistribution"===O.ports[parseInt(T.toString(),10)].id.split("_")[1]&&N.push(O.ports[parseInt(T.toString(),10)]);this.removePorts(O,N)}}for(T=0;T0)for(var ue=0,pe=Object.keys(e.nodes);ue0)for(var De=0,xe=Object.keys(e.connectors);De=0;o--)this.commandHandler.expandNode(r[parseInt(o.toString(),10)],this,0!==o);this.canLayout&&this.doLayout(),this.lineRoutingModule?this.connectors.sourceID!==this.connectors.targetID&&this.lineRoutingModule.lineRouting(this):this.constraints&rt.LineRouting&&console.warn('[WARNING] :: Module "LineRouting" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),this.validatePageSize(),this.renderPageBreaks(),this.diagramRenderer.renderSvgGridlines(this.snapSettings,Ud(this.element.id),this.scroller.transform,this.rulerSettings,this.hRuler,this.vRuler),this.commandHandler.initSelectorWrapper(),this.notify("initial-load",{}),this.trigger("load"),this.scroller.setSize(),this.scroller.updateScrollOffsets(),this.isRefreshed||this.refreshDiagramLayer(),(this.scrollSettings.verticalOffset>0||this.scrollSettings.horizontalOffset>0)&&this.updateScrollOffset(),X.isDevice&&(this.tool=Ci.ZoomPan|Ci.SingleSelect),this.notify("initial-end",{}),this.isProtectedOnChange=!1,this.tooltipObject=l3(this),this.diagramActions=ee.Render,this.initCommands();var a=document.getElementsByClassName(this.element.id+"_hiddenUserHandleTemplate");(function Noe(n,t,e,i){var r,s,o,a,l,d=document.getElementById(i).ej2_instances[0];if(n&&t){r=GF(n);for(var u=0,p=e.userHandles;u0;)e[0].parentNode.removeChild(e[0]);var i=document.getElementById(this.element.id+"content");i&&this.element.removeChild(i);var r="measureElement";if(window[""+r]){window[""+r].usageCount-=1;var s="measureElementCount";window[""+s]--,0===window[""+s]&&(window[""+r].parentNode.removeChild(window[""+r]),window[""+r]=null)}}window.domTable={};for(var a=0;a1&&(this.callBlazorModel=!1,this.insertBlazorDiagramObjects(this.selectedItems),this.commandHandler.group(),this.callBlazorModel=!0,this.commandHandler.getBlazorOldValues())},t.prototype.unGroup=function(){this.callBlazorModel=!1,this.insertBlazorDiagramObjects(this.selectedItems),this.commandHandler.unGroup(),this.callBlazorModel=!0,this.commandHandler.getBlazorOldValues()},t.prototype.sendToBack=function(){this.commandHandler.sendToBack()},t.prototype.setActiveLayer=function(e){var i=this.commandHandler.getLayer(e);this.activeLayer=i},t.prototype.addLayer=function(e,i){this.commandHandler.addLayer(e,i)},t.prototype.removeLayer=function(e){this.commandHandler.removeLayer(e,ce())},t.prototype.moveObjects=function(e,i){$(this.layers),this.enableServerDataBinding(!1),this.commandHandler.moveObjects(e,i)},t.prototype.layerObjectUpdate=function(){},t.prototype.sendLayerBackward=function(e){this.layerObjectUpdate(),this.commandHandler.sendLayerBackward(e)},t.prototype.bringLayerForward=function(e){this.layerObjectUpdate(),this.commandHandler.bringLayerForward(e)},t.prototype.cloneLayer=function(e){this.commandHandler.cloneLayer(e)},t.prototype.bringToFront=function(){this.commandHandler.bringToFront()},t.prototype.moveForward=function(){this.commandHandler.sendForward()},t.prototype.sendBackward=function(){this.commandHandler.sendBackward()},t.prototype.getObject=function(e){return this.nameTable[""+e]},t.prototype.getNodeObject=function(e){return $(this.nameTable[""+e])},t.prototype.getConnectorObject=function(e){return $(this.nameTable[""+e])},t.prototype.getActiveLayer=function(){return this.activeLayer},t.prototype.nudgeCommand=function(e,i,r){if("object"!=typeof e&&(this.selectedItems.nodes.length||this.selectedItems.connectors.length)>0){var s=void 0;i.type&&"KEYDOWN"===i.type&&(s=i.type),this.nudge(e,void 0,void 0,s)}},t.prototype.nudge=function(e,i,r,s){var o=0,a=0;"Left"===e||"Right"===e?o=("Left"===e?-1:1)*(i||1):a=("Up"===e?-1:1)*(r||1),"KEYDOWN"===s&&(o*=5,a*=5);var h=this.selectedItems,c=this.selectedItems.wrapper.children[0];if(c instanceof ni)this.commandHandler.labelDrag(h.nodes[0],c,o,a);else{var d=$(this.selectedItems);this.protectPropertyChange(!0),this.drag(h,o,a),this.protectPropertyChange(!1);var u={type:"PositionChanged",redoObject:$(this.selectedItems),undoObject:d,category:"Internal"};this.addHistoryEntry(u)}this.refreshCanvasLayers()},t.prototype.insertBlazorDiagramObjects=function(e){},t.prototype.drag=function(e,i,r){if(this.insertBlazorDiagramObjects(e),!(this.bpmnModule&&e instanceof te&&this.bpmnModule.updateAnnotationDrag(e,this,i,r))){if(e instanceof si){if(this.preventConnectorsUpdate=!0,e.nodes&&e.nodes.length){for(var o=0,a=e.nodes;o0&&o.nodes[0].children){this.fromUndo||(this.rotateUsingButton=!0);for(var h=this.commandHandler.getAllDescendants(o.nodes[0],[]),c=0;c0&&o.nodes[0].children){var g={type:"RotationChanged",redoObject:$(e),undoObject:$(o),category:"Internal",childTable:a};this.commandHandler.addHistoryEntry(g),this.commandHandler.updateSelector()}return u},t.prototype.dragSourceEnd=function(e,i,r){this.insertBlazorDiagramObjects(e),this.commandHandler.dragSourceEnd(e,i,r),this.callBlazorModel&&this.commandHandler.getBlazorOldValues()},t.prototype.dragTargetEnd=function(e,i,r){this.insertBlazorDiagramObjects(e),this.commandHandler.dragTargetEnd(e,i,r),this.callBlazorModel&&this.commandHandler.getBlazorOldValues()},t.prototype.findObjectsUnderMouse=function(e,i){return this.eventHandler.findObjectsUnderMouse(e,i)},t.prototype.findObjectUnderMouse=function(e,i,r){return this.eventHandler.findObjectUnderMouse(e,i,r)},t.prototype.findTargetObjectUnderMouse=function(e,i,r,s,o){return this.eventHandler.findTargetUnderMouse(e,i,r,s,o)},t.prototype.findElementUnderMouse=function(e,i,r,s){return this.eventHandler.findElementUnderMouse(e,i,r,s)},t.prototype.findActionToBeDone=function(e,i,r,s){return this.eventHandler.findActionToBeDone(e,i,r,s)},t.prototype.updateConnectorPort=function(e){if(e.ports.length)for(var i=void 0,r=0,s=e.ports;r=0;s--)if(i.push(r[parseInt(s.toString(),10)]),i.length>this.historyManager.stackLimit)return i}else i=r;return i},t.prototype.getEdges=function(e){return e.outEdge?this.nameTable[e.id].outEdges:this.nameTable[e.id].inEdges},t.prototype.getParentId=function(e){return this.nameTable[""+e].parentId},t.prototype.addConnector=function(e){return this.add(e)},t.prototype.UpdateBlazorDiagramModelCollection=function(e,i,r,s){},t.prototype.UpdateBlazorDiagramModel=function(e,i,r,s){},t.prototype.UpdateBlazorLabelOrPortObjects=function(e,i,r,s){},t.prototype.addBlazorDiagramObjects=function(){},t.prototype.removeNodeEdges=function(e,i,r){var s=this.nameTable[""+e],o=r?s.outEdges:s.inEdges;if(o.length>0)for(var a=0;a0)){for(var c=0;c0))}this.removePortEdges(l,a.element.sourcePortID,a.element.id,h)}a.element.targetID&&this.removeNodeEdges(a.element.targetID,a.element.id,!1)}}this.diagramActions=this.diagramActions|ee.PublicMethod,e.id=e.id||Qe();var u=this.activeLayer;if(!a.cancel&&u&&!u.lock){if(u.objects.indexOf(e.id)<0&&!u.lock&&(u.visible||(u.visible=!0,this.dataBind()),u.objects.push(e.id)),fs(e)===de)(r=new de(this,"connectors",e,!0)).status="New",this.nameTable[r.targetID]&&"TextAnnotation"===this.nameTable[r.targetID].shape.shape&&(r.isBpmnAnnotationConnector=!0,r.constraints=r.constraints&~qe.Delete),Ro(r,e,this.connectorDefaults),this.connectors.push(r),this.initObject(r),!1===e.visible&&this.updateElementVisibility(r.wrapper,r,e.visible),this.updateEdges(r),this.insertBlazorConnector(r);else{if(Ro(r=new te(this,"nodes",e,!0),e,this.nodeDefaults),r.parentId=e.parentId?e.parentId:r.parentId,r.umlIndex=e.umlIndex,r.status="New",(o="TextAnnotation"===r.shape.shape)&&!e.isTextAnnotationCopied&&(r.inEdges=e.inEdges?e.inEdges:r.inEdges),this.nodes.push(r),this.initObject(r,u,void 0,i),o&&this.bpmnModule)for(c=0;c-1&&e.parentId&&this.nameTable[e.parentId]&&"UmlClassifier"===this.nameTable[e.parentId].shape.type){var g=this.nameTable[e.parentId];g.children.splice(r.umlIndex,0,r.id),g.wrapper.children.splice(r.umlIndex,0,r.wrapper),g.wrapper.measure(new me),g.wrapper.arrange(g.wrapper.desiredSize),this.updateDiagramObject(g)}}if(a={element:r,cause:this.diagramActions,diagramAction:this.getDiagramAction(this.diagramActions),state:"Changed",type:"Addition",cancel:!1},this.parentObject&&(a.parentId=this.parentObject.id),"helper"!==e.id&&!(this.diagramActions&ee.PreventCollectionChangeOnDragOver)&&this.triggerEvent(Ce.collectionChange,a),!(this.diagramActions&ee.UndoRedo||this.diagramActions&ee.Group||this.diagramActions&ee.PreventHistory)){var v={type:"CollectionChanged",changeType:"Insert",undoObject:$(e),redoObject:$(e),category:"Internal"};this.addHistoryEntry(v)}this.parentObject=void 0,"SVG"===this.mode&&(this.updateSvgNodes(r),this.updateTextElementValue(r),this.updateDiagramObject(r),o&&this.updateDiagramObject(this.nameTable[r.inEdges[0]]),r.shape.activity&&r.shape.activity.subProcess.processes&&r.shape.activity.subProcess.processes.length&&this.updateProcesses(r),this.updateBridging())}}if(this.protectPropertyChange(s),this.resetDiagramActions(ee.PublicMethod),r&&this.layers.length>1&&this.moveNode(r),this.views)for(var S=0,b=this.views;S=0;l--)this.moveSvgNode(a[parseInt(l.toString(),10)])}for(var h=0,c=i;h=0;o--)r[parseInt(o.toString(),10)]===e.id&&r.splice(o,1);for(var a=0;s.ports&&a=0;s--)if(i=this.nameTable[r[parseInt(s.toString(),10)]])if(this.connectorTable[i.id]=$(i),i.isBpmnAnnotationConnector){var o=this.nameTable[i.targetID];this.removeObjectsFromLayer(i);var a=this.connectors.indexOf(i);-1!==a&&this.connectors.splice(a,1),this.removeElements(i),this.removeFromAQuad(i),delete this.nameTable[i.id];var l=this.nameTable[i.sourceID];if(l){var h=l.outEdges.indexOf(i.id);-1!==h&&l.outEdges.splice(h,1)}e.id!==i.targetID&&this.remove(o)}else this.remove(i)},t.prototype.removeObjectsFromLayer=function(e){if(e.children)for(var i=0;i-1&&(_r(this,e)&&this.unSelect(e),this.layers[parseInt(s.toString(),10)].objects.splice(a,1),delete this.layers[parseInt(s.toString(),10)].zIndexTable[this.nameTable[e.id].zIndex])},t.prototype.removeElements=function(e){if("SVG"===this.mode||"Canvas"===this.mode&&"Native"===e.shape.type){var i=xt(e.id+"_groupElement",this.element.id),r=e;if(r.ports&&r.ports.length>0)for(var s=0;s0){l[parseInt(s.toString(),10)].id.indexOf("icon_content")>0&&"SVG"===this.mode&&((h=xt(l[parseInt(s.toString(),10)].id+"_shape_groupElement",this.element.id))&&h.parentNode.removeChild(h),(h=xt(l[parseInt(s.toString(),10)].id+"_rect_groupElement",this.element.id))&&h.parentNode.removeChild(h));for(var c=0,d=this.views;c=0;o--)a.children[parseInt(o.toString(),10)].children&&(l=n.nameTable[a.children[parseInt(o.toString(),10)].id])&&(l.isLane?Jv(n,l):(n.removeDependentConnector(l),n.diagramActions|=ee.PreventHistory,l.constraints&ie.Delete?n.remove(l):q3(n,l,{},!1),n.diagramActions&=~ee.PreventHistory));a&&(i=n.nameTable[a.id])&&Jv(n,i)}}(this,e),!(this.diagramActions&ee.UndoRedo||this.diagramActions&ee.PreventHistory)&&(e instanceof te||e instanceof de)){var o={type:"CollectionChanged",changeType:"Remove",undoObject:$(e),redoObject:$(e),category:"Internal"};this.diagramActions&ee.Clear||e.children&&!e.isLane&&!e.isPhase&&e.children.length>0&&this.undoRedoModule&&"None"===this.layout.type&&(this.historyManager.startGroupAction(),s=!0),(e instanceof te||e instanceof de)&&this.deleteDependentConnector&&this.removeDependentConnector(e),!e.isLane&&!e.isPhase&&!(this.diagramActions&ee.Clear)&&!this.isStackChild(e)&&this.addHistoryEntry(o)}"TextAnnotation"===e.shape.shape&&this.removeDependentConnector(e),e.children&&!e.isLane&&!e.isPhase&&(!(this.diagramActions&ee.UndoRedo)||!ce())&&this.deleteGroup(e),e.parentId&&(this.deleteChild(e,void 0,!0),this.nameTable[e.parentId]&&"UmlClassifier"===this.nameTable[e.parentId].shape.type&&(this.updateDiagramObject(this.nameTable[e.parentId]),this.updateConnectorEdges(this.nameTable[e.parentId])));var a=void 0;this.diagramActions=this.diagramActions|ee.PublicMethod;var l=this.nameTable[e.id];if(l instanceof te?("Bpmn"===l.shape.type&&this.bpmnModule&&this.bpmnModule.removeBpmnProcesses(l,this),(l.isLane||l.isPhase||"SwimLane"===l.shape.type)&&(h=l.isLane||l.isPhase?this.nameTable[l.parentId]:this.nameTable[l.id],l.isLane?Q3(this,l,h):l.isPhase&&G3(this,l,h)),-1!==(a=this.nodes.indexOf(l))&&(this.crudDeleteNodes.push(this.nameTable[l.id]),this.nodes.splice(a,1),this.updateNodeEdges(l))):(-1!==(a=this.connectors.indexOf(l))&&(this.crudDeleteNodes.push(this.nameTable[l.id]),this.connectors.splice(a,1)),this.updateEdges(l),this.spliceConnectorEdges(e,!0),this.spliceConnectorEdges(e,!1)),!this.isServerUpdate&&!(this.blazorActions&on.GroupClipboardInProcess)&&this.commandHandler.getBlazorOldValues(),s&&this.historyManager.endGroupAction(),_r(this,l)&&this.unSelect(l),!l.isPhase){if(this.removeObjectsFromLayer(e),this.currentDrawingObject&&(this.currentDrawingObject.wrapper=void 0),delete this.nameTable[e.id],i.length>0&&i[0].id===l.id&&l.parentId){var h,d=this.nameTable[l.parentId];d&&d.isLane&&"SwimLane"===this.nameTable[d.parentId].shape.type&&Y3(this,h=this.nameTable[d.parentId],d,l)}this.removeElements(l),this.updateBridging(),"SVG"!==this.mode&&this.refreshDiagramLayer(),this.diagramActions&ee.Clear||(this.removeFromAQuad(l),r={element:e,cause:this.diagramActions,diagramAction:this.getDiagramAction(this.diagramActions),state:"Changed",type:"Removal",cancel:!1},"helper"!==e.id&&this.triggerEvent(Ce.collectionChange,r),this.resetTool())}}}else if(i.length>0){this.undoRedoModule&&(this.historyManager.startGroupAction(),this.blazorActions|=on.GroupingInProgress,s=!0);for(var u=0;u=f.wrapper.bounds.width&&"Horizontal"===f.shape.orientation||this.selectedItems.wrapper.bounds.y<=f.wrapper.bounds.y+g&&this.selectedItems.wrapper.bounds.height>=f.wrapper.bounds.height-g&&"Vertical"===f.shape.orientation)&&(kI(f)||f.shape.lanes.length>1)&&this.remove(i[parseInt(u.toString(),10)])}}else this.remove(i[parseInt(u.toString(),10)])}s&&(this.blazorActions&=~on.GroupingInProgress,this.isServerUpdate=!0,this.commandHandler.getBlazorOldValues(),this.UpdateBlazorDiagramModelCollection(void 0,void 0,void 0,!0),this.historyManager.endGroupAction(),this.isServerUpdate=!1),this.clearSelection()}e&&(kI(e)||this.diagramActions&ee.Clear)||this.diagramActions&ee.UndoRedo||this.diagramActions&ee.PreventHistory||!(e instanceof te||e instanceof de)||(o={type:"ConnectionChanged",undoObject:$(e),redoObject:$(e),category:"Internal"},!e.isLane&&!e.isPhase&&!(this.diagramActions&ee.Clear)&&!this.isStackChild(e)&&this.addHistoryEntry(o)),this.tooltipObject.close()},t.prototype.isStackChild=function(e){var i,r=this.nameTable[e.parentId];if(e&&e.parentId&&r.container&&"Stack"===r.container.type&&"UmlClassifier"!==this.nameTable[e.parentId].shape.type){i=!0;var s={sourceIndex:r.wrapper.children.indexOf(e.wrapper),source:e,target:void 0,targetIndex:void 0};this.diagramActions&ee.UndoRedo||this.addHistoryEntry({type:"StackChildPositionChanged",redoObject:{sourceIndex:void 0,source:e,target:void 0,targetIndex:void 0},undoObject:s,category:"Internal"})}return i},t.prototype.deleteChild=function(e,i,r){var s;if(s="string"==typeof e?e:e.id,(i=i?this.nameTable[i.id]:this.nameTable[e.parentId])&&i.children){for(var o=0;o=0;i--)this.removeLayer(this.layers[parseInt(i.toString(),10)].id);this.commandHandler.addLayer({id:"default_layer",visible:!0,lock:!1,objects:[],zIndex:0,objectZIndex:-1,zIndexTable:{}},null,!0),this.setActiveLayer(this.layers[this.layers.length-1].id)},t.prototype.clearObjects=function(e){var i=[];i=e||(i=i.concat(this.nodes)).concat(this.connectors),this.diagramActions=this.diagramActions|ee.Clear;for(var r=0,s=i;r0||"Text"===e.shape.type))if("Text"===e.shape.type)i=e.wrapper.children[0].id.split("_")[1];else for(var f=e.annotations.length-1;f>=0;f--)e.annotations[parseInt(f.toString(),10)].visibility&&(i=e.annotations[parseInt(f.toString(),10)].id);i&&(u=this.getWrapper(e.wrapper,i))}if(e&&u&&!(u instanceof Jn)&&(!function sne(n,t){return"Text"===t.shape.type?t.constraints&ie.ReadOnly:t.constraints&(t instanceof de?qe.ReadOnly:ie.ReadOnly)?n.constraints&Lr.InheritReadOnly?1:0:n.constraints&Lr.ReadOnly?1:0}(u,e)||p)){var g=u.style,v=void 0;v=90>(v=u.bounds.width50?50:e.width,u.style.fontSize)),e.parentId&&"UmlClassifier"===this.nameTable[e.parentId].shape.type?(l.width=e.wrapper.bounds.width-20,c=(e.wrapper.bounds.center.x+r.tx)*r.scale-l.width/2*s-2.5,d=(e.wrapper.bounds.center.y+r.ty)*r.scale-l.height/2*s-3,u.style.textAlign="Left"):(l.width=Math.max(l.width,50),c=(u.bounds.center.x+r.tx)*r.scale-l.width/2*s-2.5,d=(u.bounds.center.y+r.ty)*r.scale-l.height/2*s-3),Ho(y,{id:this.element.id+"_editTextBoxDiv",style:"position: absolute;left:"+c+"px;top:"+d+"px;width:"+(l.width+1)*s+"px;height:"+l.height*s+"px; containerName:"+e.id+";"}),Ho(S,{"aria-label":a,id:this.element.id+"_editBox",style:"width:"+(l.width+1)*s+"px;height:"+l.height*s+"px;resize: none;outline: none;overflow: hidden;;font-family:"+g.fontFamily+";font-size:"+g.fontSize*s+"px;text-align:"+u.style.textAlign.toLocaleLowerCase()+";",class:"e-diagram-text-edit"}),S.style.fontWeight=g.bold?"bold":"",S.style.fontStyle=g.italic?"italic":"",S.style.lineHeight=(1.2*g.fontSize+"px;").toString(),S.style.textDecoration=g.textDecoration?g.textDecoration:"",this.activeLabel.parentId=e.id,this.activeLabel.id=i,u.visible=!1,this.updateDiagramObject(e),this.diagramActions=this.diagramActions|ee.TextEdit,this.isTriggerEvent||(E.add(S,"input",this.eventHandler.inputChange,this.eventHandler),E.add(S,"focusout",this.focusOutEdit,this),S.select())}}}},t.prototype.updateConnectorfixedUserHandles=function(e){if(e.fixedUserHandles.length)for(var i=void 0,r=0,s=e.fixedUserHandles;r0&&this.mindMapChartModule.updateLayout(o,this.nameTable,this.layout,l,this.dataSourceSettings.id,this.dataSourceSettings.root),e=!0;else if(this.radialTreeModule)this.radialTreeModule.updateLayout(o,this.nameTable,this.layout,l),e=!0;else if(this.symmetricalLayoutModule)this.symmetricalLayoutModule.maxIteration=this.layout.maxIteration,this.symmetricalLayoutModule.springLength=this.layout.springLength,this.symmetricalLayoutModule.springFactor=this.layout.springFactor,this.symmetricalLayoutModule.updateLayout(o,this.connectors,this.symmetricalLayoutModule,this.nameTable,this.layout,l),e=!0;else if(this.complexHierarchicalTreeModule){this.canDistribute(a,r)&&(this.lineDistributionModule.diagram=this,this.connectors.forEach(function(R){R.obstaclePointCollection=[]}));var c=this.complexHierarchicalTreeModule.getLayoutNodesCollection(this.nodes);c.length>0&&this.complexHierarchicalTreeModule.doLayout(c,this.nameTable,this.layout,l,this),e=!0,this.canDistribute(a,r)&&this.lineDistributionModule.initLineDistribution(this.layout,this)}else this.flowchartLayoutModule?(this.flowchartLayoutModule.updateLayout(this.nodes,this),e=!0):console.warn("[WARNING] :: Module "+("OrganizationalChart"===this.layout.type?"HierarchicalTree":this.layout.type)+" is not available in Diagram component! You either misspelled the module name or forgot to load it.");if(e){this.preventDiagramUpdate=!0;for(var u={},f=0,g=o;f0)for(var S=0;S0)for(var M=0;M0)for(var s=0,o=r.ports;s0&&function Rse(n){var t,e,i,r=[];for(t=0;t0&&y.connectors[w].bezierSettings&&y.connectors[w].bezierSettings.allowSegmentsReset&&(y.connectors[w].segments=[]);if(t.connectors=y.connectors||[],t.dataSourceSettings=y.dataSourceSettings||{},t.dataSourceSettings.doBinding=i,t.height=y.height||"100%",t.setNodeTemplate=r,t.getConnectorDefaults=v,t.getNodeDefaults=g,t.getCustomProperty=o,t.mode=y.mode||"SVG",y.nodes)for(w=0;w0)){var r=this.nodes.filter(function(a){return 0===a.inEdges.length})[0],s=this.convertMindmapToMermaid(r,0);i.push(s),this.updateTextDataSource(i,r.outEdges,1),e=(i=i.filter(function(a){return""!==a.trim()})).join("\n")}return e},t.prototype.updateTextDataSource=function(e,i,r){for(var s=0;s0&&this.updateTextDataSource(e,h,r+1),s++}},t.prototype.convertMindmapToMermaid=function(e,i){var r=e.id,o=" ".repeat(2*(i+1)),a=e.annotations.length>0?e.annotations[0].content.replace(/\n/g," "):"",l=o+a,h=o+r;if(e.shape&&"Basic"===e.shape.type){var c=e.shape;"Rectangle"===c.shape?l=h+"["+a+"]":"Ellipse"===c.shape?l=h+"(("+a+"))":"Hexagon"===c.shape&&(l=h+"{{"+a+"}}")}else if(e.shape&&"Flow"===e.shape.type)"Terminator"===e.shape.shape&&(l=h+"("+a+")");else if(e.shape&&"Path"===e.shape.type){var u=e.shape;u.data===this.bangShape?l=h+"))"+a+"((":u.data===this.cloudShape&&(l=h+")"+a+"(")}return l},t.prototype.saveFlowDiagramInMermaidFormat=function(){var e=this,i=[],r="graph TD\n",s={nodes:this.nodes,edges:this.connectors};return s.nodes.reduce(function(a,l){return a[l.id]=l.annotations.length?l.annotations[0].content:"",a},{}),s.edges.forEach(function(a){var l=a.sourceID,h=a.targetID,p=e.nameTable[""+h],f=e.getNodeShape(e.nameTable[""+l]),g=e.getNodeShape(p),v=a.annotations[0]&&""!==a.annotations[0].content?"|"+a.annotations[0].content+"|":"";-1===i.indexOf(l)?i.push(l):f="",-1===i.indexOf(h)?i.push(h):g="";var y=e.arrowType(a);r+=" "+l+f+" "+y+v+" "+h+g+"\n"}),s.nodes.forEach(function(a){r+=" style "+a.id+" fill:"+a.style.fill+",stroke:"+a.style.strokeColor+",stroke-width:"+a.style.strokeWidth+"px;\n"}),r},t.prototype.arrowType=function(e){var i=e.targetDecorator.shape;return e.style.opacity<1?"~~~":""!==e.style.strokeDashArray?"-.->":"Arrow"===i?e.style.strokeWidth>1?"==>":"--\x3e":"None"===i?"---":"--\x3e"},t.prototype.getNodeShape=function(e){var i=e.annotations.length>0?e.annotations[0].content:"",r=e.shape.shape;if(!r){var s=e.shape.data;return"M 0 0 A 1 1 0 0 0 7 0 A 1 1 0 0 0 0 0 M -1 0 A 1 1 0 0 0 8 0 A 1 1 0 0 0 -1 0"===s?"((("+i+")))":"M 0 0 L 1 -1 L 5 -1 L 6 0 L 0 0"===s?"[/"+i+"\\]":"M 0 1 L 0 6 C 2 7 4 7 6 6 L 6 1 C 5 0 1 0 0 1 C 1 2 5 2 6 1"===s?"[("+i+")]":"M 0 0 L 12 0 L 14 2 L 2 2 L 0 0"===s?"[\\"+i+"\\]":"M 0 0 L 5 0 L 4 1 L 1 1 L 0 0"===s?"[\\"+i+"/]":"M 0 0 L 2 -2 L 11 -2 L 13 0 L 11 2 L 2 2 L 0 0"===s?"{{"+i+"}}":">"+i+"]"}switch(r){case"Terminator":return"(["+i+"])";case"Process":default:return"["+i+"]";case"Decision":return"{"+i+"}";case"Parallelogram":return"[/"+i+"/]";case"Ellipse":return"(("+i+"))";case"PreDefinedProcess":return"[["+i+"]]"}},t.prototype.loadDiagramFromMermaid=function(e){this.layout&&"Flowchart"===this.layout.type&&this.flowchartLayoutModule?this.convertMermaidToFlowChart(e):this.layout&&"MindMap"===this.layout.type&&this.mindMapChartModule?this.convertMermaidToMindmap(e):console.warn('[WARNING] :: Module "FlowchartLayout" or "MindMap" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.countLeadingSpaces=function(e){for(var i=0,r=e.length;i0});this.clear(),this.mermaidNodeBaseCollection=[];var r=[],s={text:"",children:[],currentLevel:0,branch:"Left"},o=[],l=!1,h=!1,c=!1;if(i.length>0){for(var d=function(M){var w=i[parseInt(M.toString(),10)],C=0,D="",A=u.countLeadingSpaces(w),x=w.includes('"`');if(h=w.includes('`"'),c=(l=!!x||l)||c?c:0===A&&M>0,l&&h&&!x)return s.text+="\n"+w,l=!1,"continue";if(!x&&l)return s.text+="\n"+w,"continue";if(l=!h&&l,w.length>0&&(/\s/.test(w[0])&&M>0||0===A)){if(-1!==o.findIndex(function(B){return B.space===A.toString()}))for(var L=o.length-1;L>=0;L--){var O=o[parseInt(L.toString(),10)];if((N=parseFloat(O.space))>A)o.splice(L,1);else{if(N=0;L--){var N,T=o[parseInt(L.toString(),10)];if(!((N=parseFloat(T.space))>A)){var P=o[o.length-1];o.push({space:A.toString(),level:P.level+1});break}o.splice(L,1)}C=o[o.length-1].level}D=w.trim().replace(/^[+-]/,"")}var _={text:D,branch:void 0,children:[],currentLevel:0===M?0:C-1};if(r.length>0){for(;r.length>=C&&0!==r.length;)r.pop();r.length>0&&r[r.length-1].children.push(_)}r.push(_),s=_},u=this,p=0;p0){var c=h[h.length-1];c.arrowType=a[2],""!==a[3]&&(c.label&&c.label.some(function(d){return d.trim().length>0})?c.label.push(a[3]):(c.label=[],c.label[c.parentId.length-1]=a[3]))}h.filter(function(d){return d.parentId&&0===d.parentId.length}).forEach(function(d){d.parentId=null}),i=i.concat(h)}}this.createFlowChart(i),this.doLayout(),this.clearHistory()},t.prototype.createFlowChart=function(e){for(var i=[],r=0;r1)for(var h=0;h|---|--\s*.*?\s*-->|~~~|==>|===|==\s*.*?\s*==>|\s*-\.\s*->|\s*-\.\s*-|\s*-\.\s*.*?\s*\.\s*->|\s*-\..*?\.\s*->)(.*)$/);if(l){i=l[1].trim();var h=l[2].trim();r=l[3].trim();var d=h.match(/(-\.|\\-\\-|==|--|~~)(.*?)(\1>|\.->|==>|\\->|~~>)/),u=void 0,p="";o=null!==(u=d?{text:d[2].trim()||null,arrowType:d[1]+d[3]}:{text:null,arrowType:h}).text?u.text:"",s=(p=u.arrowType).includes("--\x3e")?"single-line-arrow":p.includes("---")?"single-line":p.includes("==>")?"double-line-arrow":p.includes("==")?"double-line":p.includes("~~~")?"wiggly-arrow":p.includes("-.->")||p.includes(".->")?"dotted-arrow":p.includes("-.-")||p.includes(".-")?"dotted":"single-line-arrow"}return[i,r,s,o]},t.prototype.parseStyle=function(e,i){if(e.startsWith("style")){var s=e.match(/^style\s+(\w+)\s+fill:([^,]+),stroke:([^,]+),stroke-width:(\d+)px;/);if(s){var c={id:s[1],fill:s[2],stroke:s[3],strokeWidth:parseInt(s[4],10)},d=i.filter(function(u){return u.id===c.id});d[0].color=c.fill,d[0].stroke=c.stroke,d[0].strokeWidth=c.strokeWidth}}},t.prototype.getNodeData=function(e,i,r){for(var s=[],o=null,a=null,l=0,h="",c=function(v){var y=e[parseInt(v.toString(),10)],S=d.splitNested(y);if(S[0].includes("|")){var b=S[0].match(/\|([^|]*)\|/);b&&(h=b[1]);var M=S[0].split("|");M.length>=3&&(S[0]=M[2].trim())}var w=S[0].trim();if(0===v?o=w:a=w,i.find(function(L){return L.id===w}))l++;else{var D=S.length>1?S[1]:S[0],A=d.getShape(D),x=D.replace(/[\\[\]\\(\\)\\{\\}\\{\\}\\/>]/g,"");s.push({id:w,name:x,shape:A,color:"white",parentId:[]})}},d=this,u=0;u"===h?0===s?(r.trim().length>0&&i.push(r.trim()),r=h,o=h,s++):(r+=h,s++):"]"===h||"}"===h||")"===h?1===s&&h===o?(i.push((r+=h).trim()),r="",s--):s>1?(r+=h,s--):r+=h:r+=h}return r.trim().length>0&&i.push(r.trim()),i},t.prototype.getShape=function(e){var i={};return e.startsWith("(((")?i={type:"Path",data:"M 0 0 A 1 1 0 0 0 7 0 A 1 1 0 0 0 0 0 M -1 0 A 1 1 0 0 0 8 0 A 1 1 0 0 0 -1 0"}:e.startsWith("((")?i={shape:"Ellipse",type:"Basic"}:e.startsWith("([")?i={type:"Flow",shape:"Terminator"}:e.startsWith("(")?i={type:"Flow",shape:"Process"}:e.startsWith("[[")?i={type:"Flow",shape:"PreDefinedProcess"}:e.startsWith("[/")?i=e.endsWith("/]")?{type:"Basic",shape:"Parallelogram"}:{type:"Path",data:"M 0 0 L 1 -1 L 5 -1 L 6 0 L 0 0"}:e.startsWith("[(")?i={type:"Path",data:"M 0 1 L 0 6 C 2 7 4 7 6 6 L 6 1 C 5 0 1 0 0 1 C 1 2 5 2 6 1"}:e.startsWith("[\\")?i=e.endsWith("\\]")?{type:"Path",data:"M 0 0 L 12 0 L 14 2 L 2 2 L 0 0"}:{type:"Path",data:"M 0 0 L 5 0 L 4 1 L 1 1 L 0 0"}:e.startsWith("[")?i={type:"Basic",shape:"Rectangle"}:e.startsWith("{{")?i={type:"Path",data:"M 0 0 L 2 -2 L 11 -2 L 13 0 L 11 2 L 2 2 L 0 0"}:e.startsWith("{")?i={type:"Flow",shape:"Decision"}:e.startsWith(">")&&(i={type:"Path",data:"M 0 0 L 8 0 L 8 2 L 0 2 L 2 1 L 0 0"}),i},t.prototype.getDiagramContent=function(e){return this.printandExportModule?this.printandExportModule.getDiagramContent(e):(console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),"")},t.prototype.exportImage=function(e,i){this.printandExportModule?this.printandExportModule.exportImages(e,i):console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.printImage=function(e,i){this.printandExportModule?(i.printOptions=!0,this.printandExportModule.exportImages(e,i)):console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.setStackLimit=function(e){this.undoRedoModule&&e&&(this.historyManager.stackLimit=e,this.undoRedoModule.applyLimit(this.historyManager.currentEntry,e,this,!0))},t.prototype.clearHistory=function(){this.undoRedoModule&&this.undoRedoModule.clearHistory(this)},t.prototype.getDiagramBounds=function(){if(this.printandExportModule){var e=this.printandExportModule.getDiagramBounds("",{});return e.width=e.width>this.scrollSettings.viewPortWidth?e.width+(e.x>0?e.x:0):this.scrollSettings.viewPortWidth,e.height=e.height>this.scrollSettings.viewPortHeight?e.height+(e.y>0?e.y:0):this.scrollSettings.viewPortHeight,e.x=e.x>0?0:e.x,e.y=e.y>0?0:e.y,e}return console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),new Ne},t.prototype.exportDiagram=function(e){return this.printandExportModule?this.printandExportModule.exportDiagram(e):(console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),"")},t.prototype.print=function(e){this.printandExportModule?this.printandExportModule.print(e):console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.addPorts=function(e,i){var s;this.protectPropertyChange(!0),e=this.nameTable[e.id]||e,i.length>1&&this.startGroupAction();for(var o=function(h){if(e.ports.some(function(y){return y.id===i[parseInt(h.toString(),10)].id}))return"continue";if(e instanceof te?(s=new Es(e,"ports",i[parseInt(h.toString(),10)],!0),e.ports.push(s)):e instanceof de&&(s=new Ac(e,"ports",i[parseInt(h.toString(),10)],!0),e.ports.push(s)),e.children)for(var c=e.wrapper,d=0;d1&&this.endGroupAction(),e.wrapper.measure(new me(e.width,e.height)),e.wrapper.arrange(e.wrapper.desiredSize),this.updateDiagramObject(e),this.protectPropertyChange(!1)},t.prototype.addConstraints=function(e,i){return e|i},t.prototype.removeConstraints=function(e,i){return e&~i},t.prototype.addNodeLabels=function(e,i){this.addLabels(e,i)},t.prototype.addConnectorLabels=function(e,i){this.addLabels(e,i)},t.prototype.addLabels=function(e,i){this.protectPropertyChange(!0);var s,r=(e=this.nameTable[e.id]||e).wrapper;i.length>1&&this.startGroupAction();for(var o=0;o1&&this.endGroupAction(),e.wrapper.measure(new me(r.width,r.height)),e.wrapper.arrange(r.desiredSize),this.updateDiagramObject(e),this.protectPropertyChange(!1),this.refreshCanvasLayers()},t.prototype.addChildToUmlNode=function(e,i,r){var s,o,a,l,h="NoWrap";"Class"===e.shape.classifier||"Interface"===e.shape.classifier?"Method"===r?(o=new um(e,"",i),"Class"===e.shape.classifier?(e.shape.classShape.methods.push(o),s=e.shape.classShape):"Interface"===e.shape.classifier&&(e.shape.interfaceShape.methods.push(o),s=e.shape.interfaceShape),function soe(n,t,e,i){if(e.methods&&e.methods.length){var r=e.methods,s="",o="",a=void 0,l=1,h=void 0,c=0,d=0,u=n.shape,g="Class"===u.classifier?u.classShape:u.interfaceShape;1===r.length?g.attributes.length>0?(c=g.attributes.filter(function(w){return w.isSeparator}).length,h=(l=2+g.attributes.length+c)+1,lT(n,t,l)):h=l+1:(c=g.attributes.filter(function(w){return w.isSeparator}).length,d=g.methods.filter(function(w){return w.isSeparator}).length,h=(l=2+g.attributes.length+c+g.methods.length+d)+1);for(var v=0;v1&&this.startGroupAction();for(var r=i.length-1;r>=0;r--)if(e.children&&e.children.length>0){var s=e.wrapper.children.filter(function(o){return o.id===e.id+"group_container"});s&&s.length>0&&this.removelabelExtension(e,i,r,s[0])}else this.removelabelExtension(e,i,r,e.wrapper);i.length>1&&this.endGroupAction(),this.refreshCanvasLayers()},t.prototype.removePortsExtenion=function(e,i,r,s){for(var o=0;o1&&this.startGroupAction();for(var r=i.length-1;r>=0;r--)if(e.children&&e.children.length>0)for(var s=0;s1&&this.endGroupAction()},t.prototype.getSizeValue=function(e,i){var r;return r=e.toString().indexOf("px")>0?e.toString():e.toString().indexOf("%")>0?void 0!==i?"100%":e.toString():e.toString()+"px",i&&(qa(this),r="calc("+r+" - "+i+"px)"),r},t.prototype.renderRulers=function(){this.rulerSettings.showRulers?(function ise(n){var t=qa(n),i=Tt("div",{id:n.element.id+"_overlapRuler",style:"height:"+t.height+"px;width:"+t.width+"px;position:absolute;left:0;top:0",class:"e-ruler-overlap"});n.element.insertBefore(i,n.element.firstChild)}(this),oF(this,!0),oF(this,!1)):$x(this)},t.prototype.intOffPageBackground=function(){var e=new me;e=qa(this);var i=document.getElementById(this.element.id+"content"),r=this.getSizeValue(this.width,e.width),s=this.getSizeValue(this.height,e.height),o=this.rulerSettings.showRulers?"width:"+r+"; height:"+s+";top:"+e.height+"px;left:"+e.width+"px;overflow: scroll;position:absolute;overflow:auto;":"width:"+r+"; height:"+s+";position:absolute; left:0px; top:0px;overflow: auto;",a={id:this.element.id+"content",tabindex:"0",style:o};i?(this.diagramCanvas=i,Za(this.diagramCanvas,o)):(this.diagramCanvas=Tt("div",a),this.element.appendChild(this.diagramCanvas)),this.diagramCanvas.style.background=this.backgroundColor},t.prototype.initDiagram=function(){this.intOffPageBackground(),Ho(this.element,{style:"width:"+this.getSizeValue(this.width)+"; height:"+this.getSizeValue(this.height)+";position:relative;overflow:hidden;"})},t.prototype.renderHiddenUserHandleTemplateLayer=function(e){var r=Tt("div",{class:this.element.id+"_hiddenUserHandleTemplate",style:"width:"+e.width+"px; height:"+e.height+"px;visibility:hidden ; overflow: hidden;"});this.element.appendChild(r)},t.prototype.renderBackgroundLayer=function(e,i){var r=this.createSvg(this.element.id+"_backgroundLayer_svg",e.width,e.height);Za(r,i);var s=Bi("g",{id:this.element.id+"_backgroundImageLayer",class:"e-background-image-layer"});r.appendChild(s);var a=Bi("g",{id:this.element.id+"_backgroundLayer",class:"e-background-layer"});r.appendChild(a),this.diagramCanvas.appendChild(r)},t.prototype.renderGridLayer=function(e,i){var r=this.createSvg(this.element.id+"_gridline_svg",e.width,e.height);r.setAttribute("class","e-grid-layer");var s=Bi("g",{id:this.element.id+"_gridline"}),o=Bi("rect",{id:this.element.id+"_grid_rect",x:"0",y:"0",width:"100%",height:"100%"});if(am()){var a=new URL(window.location.href);o.setAttribute("fill",""!==a.search?"url(#"+this.element.id+"_pattern)":"url("+location.protocol+"//"+location.host+location.pathname+"#"+this.element.id+"_pattern)")}else o.setAttribute("fill","url(#"+this.element.id+"_pattern)");s.appendChild(o),r.appendChild(s),this.diagramCanvas.appendChild(r),oi(r,{style:i})},t.prototype.renderDiagramLayer=function(e,i){if(this.diagramLayerDiv=Tt("div",{id:this.element.id+"_diagramLayer_div",style:"width:"+e.width+"px; height:"+e.height+"px;"+i}),"SVG"===this.mode){var s=this.createSvg(this.element.id+"_diagramLayer_svg",e.width,e.height);s.style["pointer-events"]="none",s.setAttribute("class","e-diagram-layer");var o=Bi("g",{id:this.element.id+"_diagramLayer"}),a=Bi("g",{});this.diagramLayer=o,s.style["pointer-events"]="all",a.appendChild(o),s.appendChild(a),this.diagramLayerDiv.appendChild(s)}else this.diagramLayer=bo.createCanvas(this.element.id+"_diagram",e.width,e.height),Za(this.diagramLayer,"position:absolute;left:0px;top:0px;"),this.diagramLayerDiv.appendChild(this.diagramLayer);this.diagramCanvas.appendChild(this.diagramLayerDiv)},t.prototype.initLayers=function(){var e="position:absolute;top:0px;left:0px;overflow:hidden;pointer-events:none;",r=document.getElementById(this.element.id).getBoundingClientRect(),s=function Loe(){var n=Tt("div",{style:"visibility:hidden; width: 100px"});document.body.appendChild(n);var t=n.getBoundingClientRect().width;n.style.overflow="scroll";var e=Tt("div",{style:"width:100%"});n.appendChild(e);var i=e.getBoundingClientRect().width;return n.parentNode.removeChild(n),t-i}();this.scroller.scrollerWidth=s,this.scroller.setViewPortSize(r.width,r.height),this.renderRulers();var o="measureElement";window[""+o]&&(window[""+o]=null,document.getElementById("measureElement").remove()),function WF(){var n="measureElement";if(window[""+n])window[""+n].usageCount+=1;else{var t=Tt("div",{id:"measureElement",style:"visibility:hidden ; height: 0px ; width: 0px; overflow: hidden;"}),e=Tt("span",{style:"display:inline-block ; line-height: normal"});t.appendChild(e);var i=Tt("img",{alt:"measureElementImage",src:"data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7"});t.appendChild(i);var r=document.createElementNS("http://www.w3.org/2000/svg","svg");r.setAttribute("xmlns:xlink","http://www.w3.org/1999/xlink"),t.appendChild(r);var s=document.createElementNS("http://www.w3.org/2000/svg","path");s.setAttribute("d",""),r.appendChild(s),document.createTextNode("");var a=document.createElementNS("http://www.w3.org/2000/svg","text");a.setAttributeNS("http://www.w3.org/XML/1998/namespace","xml:space","preserve"),r.appendChild(a),window[""+n]=t,window[""+n].usageCount=1,document.body.appendChild(t);var l="measureElementCount";window[""+l]?window[""+l]++:window[""+l]=1}}(),this.renderBackgroundLayer(r,e),this.renderGridLayer(r,e),this.renderDiagramLayer(r,e),this.renderHTMLLayer(r,e),this.renderPortsExpandLayer(r,e),this.renderNativeLayer(r,e),this.renderAdornerLayer(r,e),this.renderHiddenUserHandleTemplateLayer(r)},t.prototype.renderAdornerLayer=function(e,i){var r=Tt("div",{id:this.element.id+"_diagramAdornerLayer",style:"width:"+e.width+"px;height:"+e.height+"px;"+i}),s=Tt("div",{id:this.element.id+"_diagramUserHandleLayer",style:"width:"+e.width+"px;height:"+e.height+"px;"+i});s.setAttribute("class","e-userHandle-layer"),r.appendChild(s);var o=this.createSvg(this.element.id+"_diagramAdorner_svg",e.width,e.height);o.setAttribute("class","e-adorner-layer"),o.style["pointer-events"]="none",this.adornerLayer=Bi("g",{id:this.element.id+"_diagramAdorner"}),this.adornerLayer.style[" pointer-events"]="all",o.appendChild(this.adornerLayer),r.appendChild(o),this.diagramCanvas.appendChild(r);var a=Bi("g",{id:this.element.id+"_SelectorElement"});this.adornerLayer.appendChild(a),oi(o,{style:"pointer-events:none;"})},t.prototype.renderPortsExpandLayer=function(e,i){var r=this.createSvg(this.element.id+"_diagramPorts_svg",e.width,e.height);r.setAttribute("class","e-ports-expand-layer");var s=Bi("g",{id:this.element.id+"_diagramPorts",class:"e-ports-layer",style:"pointer-events: all;"});r.appendChild(s);var o=Bi("g",{id:this.element.id+"_diagramExpander",class:"e-expand-layer",style:"pointer-events: all;"});r.appendChild(o),this.diagramCanvas.appendChild(r),oi(r,{style:i})},t.prototype.renderHTMLLayer=function(e,i){this.htmlLayer=Tt("div",{id:this.element.id+"_htmlLayer",style:"width:"+e.width+"px; height:"+e.height+"px;position:absolute;top:0px;left:0px;overflow:hidden;pointer-events:none;",class:"e-html-layer"});var r=Tt("div",{id:this.element.id+"_htmlLayer_div",style:"position:absolute;top:0px;left:0px;pointer-events:all;"});this.htmlLayer.appendChild(r),this.diagramCanvas.appendChild(this.htmlLayer)},t.prototype.renderNativeLayer=function(e,i){var r=this.createSvg(this.element.id+"_nativeLayer_svg",e.width,e.height),s=Bi("g",{id:this.element.id+"_nativeLayer",style:"pointer-events:all;"});r.appendChild(s),this.diagramLayerDiv.appendChild(r),oi(r,{class:"e-native-layer",style:i})},t.prototype.createSvg=function(e,i,r){var s=document.createElementNS("http://www.w3.org/2000/svg","svg");return oi(s,{id:e,width:i,height:r}),s},t.prototype.updateBazorShape=function(){for(var e=0;e1,i=[],r={},s={},o=[],a=0,l=this.nodes;a0||b&&b.children&&b.children.length>0)&&(M=!1),S&&S.wrapper&&b&&b.wrapper&&M?this.initConnectors(r[""+h],f):i.push(r[""+h])}else b=r[y.targetID],(S=r[y.sourceID])&&S.children&&S.children.length>0||b&&b.children&&b.children.length>0?i.push(r[""+h]):this.initConnectors(r[""+h],f);else r[""+h].children?o.push(h):r[""+h].shape instanceof pT&&r[""+h].shape.activity.subProcess.processes&&r[""+h].shape.activity.subProcess.processes.length>0?s[r[""+h].id]=h:this.initNodes(r[""+h],f);if(this.bpmnModule)for(var w=0,C=this.bpmnModule.bpmnTextAnnotationConnector;w-1&&-1===r.indexOf(c)&&-1===s.indexOf(c)&&r.splice(0,0,c);-1===r.indexOf(o)&&s.push(o)}return r.concat(s)},t.prototype.addToLayer=function(e,i){var r;if(i&&(r=this.commandHandler.getObjectLayer(e.id)),(!i||!r)&&-1===this.activeLayer.objects.indexOf(e.id)&&this.activeLayer.objects.push(e.id),(e instanceof te||e instanceof de)&&("SwimLane"!==e.shape.type||e.children&&e.children.length>0)){if(e.parentId){var s=this.swimlaneZIndexTable[e.parentId],o=this.swimlaneChildTable[e.id];(s&&-1!==s||o&&-1!==o)&&(e.zIndex=this.swimlaneChildTable[e.id])}e instanceof de&&e.sourceID&&e.targetID?-1!==this.activeLayer.objects.indexOf(e.sourceID)&&-1!==this.activeLayer.objects.indexOf(e.targetID)&&this.setZIndex(r||this.activeLayer,e):this.setZIndex(r||this.activeLayer,e)}},t.prototype.updateLayer=function(e){for(var i=0,r=Object.keys(e.layers);i0)for(r=0;rs;l--)r.zIndexTable[parseInt(l.toString(),10)]=r.zIndexTable[l-1],this.nameTable[r.zIndexTable[parseInt(l.toString(),10)]]&&(this.nameTable[r.zIndexTable[parseInt(l.toString(),10)]].zIndex=l);r.zIndexTable[parseInt(a.toString(),10)]=i.id}}},t.prototype.initializeDiagramLayers=function(){for(var e=0;ethis.layers[parseInt(a.toString(),10)].zIndex&&(i=this.layers[parseInt(e.toString(),10)],this.layers[parseInt(e.toString(),10)]=this.layers[parseInt(a.toString(),10)],this.layers[parseInt(a.toString(),10)]=i);0===this.layers.length&&this.commandHandler.addLayer({id:"default_layer",visible:!0,lock:!1,objects:[],zIndex:0,objectZIndex:-1,zIndexTable:{}},null,!0),this.setActiveLayer(this.layers[this.layers.length-1].id)},t.prototype.resetTool=function(){this.eventHandler.resetTool()},t.prototype.initObjectExtend=function(e,i,r){if(r){var s=this.commandHandler.checkBoundaryConstraints(void 0,void 0,e.wrapper.bounds,!0);if("SwimLane"===e.shape.type)for(var o=0,a=Object.keys(i.zIndexTable);o0)&&this.setZIndex(i,e)),e instanceof te){if(r){if("helper"!==e.id&&(o=Zi(this.getNodeDefaults))){if((a=o(e,this))&&a.ports)for(var l=0;l0)for(l=0;l0&&!e.container||e.processId){var r=this.nameTable[e.id];if(!(this.realActions&$i.PreventScale||this.realActions&$i.PreventDrag)){if(r.offsetX&&(this.realActions&$i.EnableGroupAction||!(this.diagramActions&ee.UndoRedo||this.diagramActions&ee.ToolAction||this.diagramActions&ee.PublicMethod))){this.realActions|=$i.PreventScale;var s=r.offsetX-e.wrapper.offsetX;r.offsetX=e.wrapper.offsetX;var o=r.offsetY-e.wrapper.offsetY;r.offsetY=e.wrapper.offsetY,s+o!==0&&this.drag(r,s,o),this.realActions&=~$i.PreventScale}else r.offsetX=e.wrapper.offsetX;r.offsetY&&(this.realActions&$i.EnableGroupAction||!(this.diagramActions&ee.UndoRedo||this.diagramActions&ee.ToolAction||this.diagramActions&ee.PublicMethod))?(this.realActions|=$i.PreventScale,o=r.offsetY-e.wrapper.offsetY,r.offsetY=e.wrapper.offsetY,this.drag(r,0,o),this.realActions&=~$i.PreventScale):r.offsetY=e.wrapper.offsetY,this.diagramActions&&(r.width=e.wrapper.actualSize.width,r.height=e.wrapper.actualSize.height)}}i&&e.children&&e.children.length>0&&(void 0!==this.nameTable[e.id].width?this.scaleObject(e,this.nameTable[e.id].width,!0):this.nameTable[e.id].width=e.wrapper.actualSize.width,void 0!==this.nameTable[e.id].height?this.scaleObject(e,this.nameTable[e.id].height,!1):this.nameTable[e.id].height=e.wrapper.actualSize.height)},t.prototype.initNode=function(e,i,r){var a,p,s=e.initContainer(),o=new Ii;if(this.diagramSettings.inversedAlignment||(s.inversedAlignment=!1),s.children||(s.children=[]),e.children){s.measureChildren=!1,o.id=e.id+"group_container",o.style.fill=e.shape&&"SwimLane"===e.shape.type?e.style.fill:"none",o.style.strokeColor="none",o.horizontalAlignment="Stretch",o.verticalAlignment="Stretch",o.pivot=e.pivot,s.style=e.style,s.padding.left=e.padding.left,s.padding.right=e.padding.right,s.padding.top=e.padding.top,s.padding.bottom=e.padding.bottom,o.children=[],o.preventContainer=!0,e.container&&(o.relativeMode="Object");var l=!!(e.ports&&e.ports.length>0);if(m(e.container)&&!l&&s.children.push(o),e.container&&"Grid"===e.container.type)for(var h=0;h0&&e.wrapper.children[0]instanceof Gv){if(this.setZIndex(this.activeLayer,e),this.connectors.length>0)for(h=0;h0?i.phases.length:0,v="Horizontal"===i.orientation,y=v?i.phases.length||1:s.length+1,S=v?(i.header&&i.hasHeader?1:0)+(i.phases.length>0?1:0)+i.lanes.length:(i.header&&i.hasHeader?1:0)+i.phases.length;if(0===h&&!v&&i.lanes.length&&(S+=1),v?(a=(i.header&&i.hasHeader?1:0)+(h>0?1:0),l=0):(a=i.header&&i.hasHeader?1:0,l=h>0?1:0),s.length>0)for(o+=i.header&&i.hasHeader?i.header.height:0,p=0;pl?d.margin.left=d.margin.left-(u.bounds.left-e.bounds.left):u.children[0].children[1].actualSize.width+r>=d.margin.left&&(d.margin.left=u.children[0].children[1].actualSize.width+r),d.margin.lefta?d.margin.top=d.margin.top-(u.bounds.top-o):u.children[0].children[1].actualSize.height+r>=d.margin.top&&(d.margin.top=u.children[0].children[1].actualSize.height+r),d.margin.left0)for(o=0;o0&&this.updateChildPosition(e)},t.prototype.addBpmnAnnotationConnector=function(e,i){if(e.parentObj instanceof t||e.parentObj instanceof Fd){var r=e.shape,o=""!==r.textAnnotation.textAnnotationTarget&&this.nameTable[r.textAnnotation.textAnnotationTarget],a=o?this.nameTable[r.textAnnotation.textAnnotationTarget]:null,l=null!=a?a.wrapper:null,h=e.ports[0],c={x:0,y:0};switch(r.textAnnotation.textAnnotationDirection){case"Left":h.offset={x:0,y:.5},c.x=i.bounds.left-40,c.y=i.bounds.bottom+30;break;case"Right":h.offset={x:1,y:.5},c.x=i.bounds.right+40,c.y=i.bounds.bottom+30;break;case"Top":h.offset={x:.5,y:0},c.x=i.bounds.right+30,c.y=i.bounds.top-40;break;case"Bottom":h.offset={x:.5,y:1},c.x=i.bounds.right+30,c.y=i.bounds.bottom+40;break;default:h.offset={x:0,y:.5},c.x=i.bounds.left-40,c.y=i.bounds.bottom+30,o&&null!=i&&null!=l&&(i.bounds.left>l.bounds.right?h.offset={x:0,y:.5}:i.bounds.rightl.bounds.top?h.offset={x:.5,y:0}:i.bounds.top0&&this.updateChildPosition(r)}},t.prototype.canExecute=function(){return!0},t.prototype.updateStackProperty=function(e,i,r){e.container&&"Stack"===e.container.type&&(i.width||(i.wrapper.horizontalAlignment="Stretch",i.horizontalAlignment="Stretch"),i.height||(i.verticalAlignment="Stretch",i.wrapper.verticalAlignment="Stretch"),r&&"UmlClassifier"===e.shape.type&&(i.umlIndex=r))},t.prototype.initViews=function(){this.isLoading||(this.views.push(this.element.id),this.views[this.element.id]=this)},t.prototype.initCommands=function(){var e=this.commandManager.commands,i={copy:{execute:this.copyCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.C,keyModifiers:pt.Control}},paste:{execute:this.pasteCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.V,keyModifiers:pt.Control}},cut:{execute:this.cutCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.X,keyModifiers:pt.Control}},delete:{execute:this.removeCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Delete}},selectAll:{execute:this.selectAll.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.A,keyModifiers:pt.Control}},undo:{execute:this.undo.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Z,keyModifiers:pt.Control}},redo:{execute:this.redo.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Y,keyModifiers:pt.Control}},nudgeUp:{execute:this.nudgeCommand.bind(this,"Up"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Up},parameter:"up"},nudgeRight:{execute:this.nudgeCommand.bind(this,"Right"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Right},parameter:"right"},nudgeDown:{execute:this.nudgeCommand.bind(this,"Down"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Down},parameter:"down"},nudgeLeft:{execute:this.nudgeCommand.bind(this,"Left"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Left},parameter:"left"},startEdit:{execute:this.startEditCommad.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.F2}},endEdit:{execute:this.endEditCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Escape}},focusToNextItem:{execute:this.navigateItems.bind(this,!0),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Tab}},focusToPreviousItem:{execute:this.navigateItems.bind(this,!1),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Tab,keyModifiers:pt.Shift}},selectFocusedItem:{execute:this.startEditCommad.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Enter}},bold:{execute:this.fontStyleCommand.bind(this,"bold"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.B,keyModifiers:pt.Control}},italic:{execute:this.fontStyleCommand.bind(this,"italic"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.I,keyModifiers:pt.Control}},underline:{execute:this.fontStyleCommand.bind(this,"underline"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.U,keyModifiers:pt.Control}},duplicate:{execute:this.duplicateCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.D,keyModifiers:pt.Control}},group:{execute:this.groupCommand.bind(this,"group"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.G,keyModifiers:pt.Control}},ungroup:{execute:this.groupCommand.bind(this,"ungroup"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.U,keyModifiers:pt.Control|pt.Shift}},rotateClockwise:{execute:this.rotateCommand.bind(this,"clockwise"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.R,keyModifiers:pt.Control}},rotateAntiClockwise:{execute:this.rotateCommand.bind(this,"antiClockwise"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.L,keyModifiers:pt.Control}},flipHorizontal:{execute:this.flipCommand.bind(this,"horizontal"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.H,keyModifiers:pt.Control}},flipVertical:{execute:this.flipCommand.bind(this,"vertical"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.J,keyModifiers:pt.Control}},pointerTool:{execute:this.toolCommand.bind(this,"pointer"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number1,keyModifiers:pt.Control}},textTool:{execute:this.toolCommand.bind(this,"text"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number2,keyModifiers:pt.Control}},connectTool:{execute:this.toolCommand.bind(this,"connect"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number3,keyModifiers:pt.Control}},freeForm:{execute:this.toolCommand.bind(this,"freeForm"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number5,keyModifiers:pt.Control}},lineTool:{execute:this.toolCommand.bind(this,"line"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number6,keyModifiers:pt.Control}},rectangleTool:{execute:this.toolCommand.bind(this,"rectangle"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number8,keyModifiers:pt.Control}},ellipseTool:{execute:this.toolCommand.bind(this,"ellipse"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number9,keyModifiers:pt.Control}},zoomIn:{execute:this.zoomCommand.bind(this,"zoomIn"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Plus,keyModifiers:pt.Control}},zoomOut:{execute:this.zoomCommand.bind(this,"zoomOut"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Minus,keyModifiers:pt.Control}},shiftUp:{execute:this.shiftCommand.bind(this,"Up"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Up,keyModifiers:pt.Shift}},shiftDown:{execute:this.shiftCommand.bind(this,"Down"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Down,keyModifiers:pt.Shift}},shiftLeft:{execute:this.shiftCommand.bind(this,"Left"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Left,keyModifiers:pt.Shift}},shiftRight:{execute:this.shiftCommand.bind(this,"Right"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Right,keyModifiers:pt.Shift}},alignTextCenter:{execute:this.alignCommand.bind(this,"center"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.C,keyModifiers:pt.Control|pt.Shift}},alignTextLeft:{execute:this.alignCommand.bind(this,"right"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.L,keyModifiers:pt.Control|pt.Shift}},alignTextRight:{execute:this.alignCommand.bind(this,"left"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.R,keyModifiers:pt.Control|pt.Shift}},alignTextTop:{execute:this.alignCommand.bind(this,"top"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.E,keyModifiers:pt.Control|pt.Shift}},alignTextCenterVertical:{execute:this.alignCommand.bind(this,"centerVertical"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.M,keyModifiers:pt.Control|pt.Shift}},alignTextBottom:{execute:this.alignCommand.bind(this,"bottom"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.V,keyModifiers:pt.Control|pt.Shift}},alignJustify:{execute:this.alignCommand.bind(this,"justify"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.J,keyModifiers:pt.Control|pt.Shift}},sendToBack:{execute:this.orderCommand.bind(this,"sendToBack"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.B,keyModifiers:pt.Control|pt.Shift}},bringToFront:{execute:this.orderCommand.bind(this,"bringToFront"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.F,keyModifiers:pt.Control|pt.Shift}},sendBackward:{execute:this.orderCommand.bind(this,"sendBackward"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.BracketLeft,keyModifiers:pt.Control}},bringForward:{execute:this.orderCommand.bind(this,"bringForward"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.BracketRight,keyModifiers:pt.Control}}};this.initCommandManager(e,i)},t.prototype.overrideCommands=function(e,i){for(var r,s=0,o=Object.keys(i);se.zIndex){("HTML"===e.shape.type||"Native"===e.shape.type)&&(o="HTML"===e.shape.type?"html":"native"),s=Eoe(i,r[parseInt(a.toString(),10)].id,o);break}return s},t.prototype.updateDiagramObject=function(e,i,r){for(var s,o="domTable",a=0,l=this.views;a1&&(d=this.commandHandler.getObjectLayer(e.id)),void 0===d||d&&d.visible||r){var u=Io(this.element.id);window[""+o][s.element.id+"_diagramLayer"]||(window[""+o][s.element.id+"_diagramLayer"]=document.getElementById(s.element.id+"_diagramLayer"));var p=window[""+o][s.element.id+"_diagramLayer"];this.diagramActions&ee.Interactions&&this.updateCanupdateStyle(e.wrapper.children,!0);var f=this.getMidPoint(e);this.diagramRenderer.updateNode(e.wrapper,p,u,void 0,i?void 0:this.getZindexPosition(e,s.element.id),f,this.portCenterPoint),this.updateCanupdateStyle(e.wrapper.children,!0)}}},t.prototype.applyMarginBezier=function(e,i){i.cx=i.cx+e.margin.left,i.cx=i.cx-e.margin.right,i.cy=i.cy+e.margin.top,i.cy=i.cy-e.margin.bottom},t.prototype.getMidPoint=function(e){var i;if(e instanceof de&&"Bezier"===e.type){i=[];for(var r=this.getBezierPoints(e),s=z.getLengthFromListOfPoints(r),o=0;o0&&e.updateView(e));var s=Io(e.element.id);this.renderDiagramElements(e.diagramLayer,e.diagramRenderer,s,void 0,void 0,i);for(var o=0;o0&&this.renderBasicElement(e),!this.diagramActions||!(this.diagramActions&ee.Render)||ee.ToolAction&this.diagramActions||Ds(this)||1!==this.scroller.currentZoom?this.refreshElements(e):this.renderTimer||(this.renderTimer=setTimeout(function(){i.refreshElements(e)},40)))},t.prototype.updatePortVisibility=function(e,i,r){var s;if((e instanceof te||e instanceof de)&&(!this.drawingObject||!this.drawingObject.shape)&&to(e)){for(var a=e.ports,l=!1,h=0;h=0&&this.scroller.removeCollection.splice(l,1);var h=this.nameTable[e[parseInt(a.toString(),10)]];this.updateTextElementValue(h),this.diagramRenderer.renderElement(h.wrapper,s,o,void 0,void 0,void 0,void 0,h.zIndex)}for(var c=0;c0?this.scroller.oldCollectionObjects:void 0,b=Object.keys(S||g.zIndexTable);b.sort(function(N,T){return parseInt(""+N,10)-parseInt(""+T,10)});for(var M=0,w=b;M0?h:0)+"px",y=(this.realActions&$i.vScrollbarMoved?0:-(this.scroller.verticalOffset<0?this.scroller.verticalOffset:0))+"px"):(v="0px",y="0px"),this.realActions&$i.hScrollbarMoved&&(this.realActions=this.realActions&~$i.hScrollbarMoved),this.realActions&$i.vScrollbarMoved&&(this.realActions=this.realActions&~$i.vScrollbarMoved)):(v=(l.x<0?h:-this.scroller.horizontalOffset)+"px",y=(l.y<0?c:-this.scroller.verticalOffset)+"px"),this.diagramLayer.style.left=v,this.diagramLayer.style.top=y,A.tx=-l.x/A.scale,A.ty=-l.y/A.scale);var R=!0;if(o&&(R=!1),this.updateTextElementValue(D),this.refreshing&&D.shape.activity&&D.shape.activity.subProcess&&D.shape.activity.subProcess.processes){for(var L=0;L0){var o=s.children[0],a=o.data;(r.isBezierEditing&&this.selectedItems.connectors[0].id===r.id||"Bezier"!==r.type)&&r.getSegmentElement(r,o,"ComplexHierarchicalTree"===this.layout.type||"HierarchicalTree"===this.layout.type?this.layout.orientation:void 0,void 0,!1),o.data!==a&&(s.measure(new me),s.arrange(s.desiredSize),"SVG"===this.mode&&!e&&this.updateDiagramObject(r))}}else this.constraints&rt.Bridging&&console.warn('[WARNING] :: Module "ConnectorBridging" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.setCursor=function(e){this.diagramRenderer.setCursor(this.diagramCanvas,e)},t.prototype.clearCanvas=function(e){var i=e.contentWidth||e.diagramLayer.width/this.scroller.currentZoom,r=e.contentHeight||e.diagramLayer.height/this.scroller.currentZoom;"SVG"!==e.mode&&bo.getContext(e.diagramLayer).clearRect(0,0,i,r)},t.prototype.updateScrollOffset=function(){this.scroller.setScrollOffset(this.diagramCanvas.scrollLeft,this.diagramCanvas.scrollTop),tb(this),Ds(this)&&this.scroller.virtualizeElements()},t.prototype.setOffset=function(e,i){var r="domTable";window[""+r][this.element.id+"content"]||(window[""+r][this.element.id+"content"]=document.getElementById(this.element.id+"content"));var s=window[""+r][this.element.id+"content"];s&&(s.scrollLeft=e,s.scrollTop=i)},t.prototype.setSize=function(e,i){if(this.diagramLayer&&!this.preventDiagramUpdate){var r=qa(this);e-=r.width,i-=r.height;var s=this.spatialSearch.getPageBounds();s.x*=this.scroller.currentZoom,s.y*=this.scroller.currentZoom,s.width*=this.scroller.currentZoom,s.height*=this.scroller.currentZoom;var o="SVG"===this.mode?1:1.5,a="SVG"===this.mode?yT(this.element.id):this.diagramLayer,h="Canvas"===this.mode&&this.constraints&rt.Virtualization?this.scroller.viewPortHeight:i;a.setAttribute("width",(o*("Canvas"===this.mode&&this.constraints&rt.Virtualization?this.scroller.viewPortWidth:e)).toString()),a.setAttribute("height",(o*h).toString());var c=document.getElementById(this.element.id+"_diagramUserHandleLayer");c&&(c.style.width=e+"px",c.style.height=i+"px");var d={width:e.toString(),height:i.toString()};this.diagramLayerDiv.style.width=e+"px",this.diagramLayerDiv.style.height=i+"px",oi(FF(this.element.id),d),oi(function xoe(n){return xt(n).getElementsByClassName("e-ports-expand-layer")[0]}(this.element.id),d);var u=zl(this.element.id);oi(u,d),u.parentNode.style.width=e+"px",u.parentNode.style.height=i+"px";var p=Ud(this.element.id);oi(p,d),this.diagramRenderer.updateGrid(this.snapSettings,p,this.scroller.transform,this.rulerSettings,this.hRuler,this.vRuler),oi(bT(this.element.id),d),this.htmlLayer.style.width=e+"px",this.htmlLayer.style.height=i+"px","SVG"!==this.mode&&!Ds(this)&&this.refreshDiagramLayer(),"SVG"===this.mode&&Ds(this)&&this.scroller.virtualizeElements()}},t.prototype.transformLayers=function(){var e=this.spatialSearch.getPageBounds();e.x*=this.scroller.currentZoom,e.y*=this.scroller.currentZoom,e.width*=this.scroller.currentZoom,e.height*=this.scroller.currentZoom,this.diagramRenderer.updateGrid(this.snapSettings,Ud(this.element.id),this.scroller.transform,this.rulerSettings,this.hRuler,this.vRuler),this.diagramRenderer.transformLayers(this.scroller.transform,"SVG"===this.mode),this.diagramActions&ee.DragUsingMouse||this.updateSelector(),this.renderPageBreaks(e)},t.prototype.removePageBreaks=function(){if(this.diagramLayer){var e=_F(this.element.id);if(e&&e.childNodes)for(var i=e.childNodes.length,r=0;rthis.pageSettings.height&&(e=this.pageSettings.height,this.pageSettings.height=this.pageSettings.width,this.pageSettings.width=e):this.pageSettings.height>this.pageSettings.width&&(e=this.pageSettings.width,this.pageSettings.width=this.pageSettings.height,this.pageSettings.height=e)},t.prototype.setOverview=function(e,i){if(e)e&&(this.views.push(e.id),this.views[e.id]=e,e.renderDocument(e),e.diagramRenderer.setLayers(),e.updateView(e),this.renderNodes(e));else{for(var r=0;r1&&this.updateSelectionRectangle(),this.isProtectedOnChange=s},t.prototype.updateSelectionRectangle=function(){for(var e=pm(this.element.id),i=!1,r=0;r1&&this.updateSelectionRectangle(),this.enableServerDataBinding(e)},t.prototype.renderSelectorForAnnotation=function(e,i){this.diagramRenderer.renderResizeHandle(e.wrapper.children[0],i,e.thumbsConstraints,this.scroller.currentZoom,e.constraints,this.scroller.transform,void 0,to(e.annotation),void 0,void 0,e.handleSize)},t.prototype.drawSelectionRectangle=function(e,i,r,s){this.clearSelectorLayer(),this.diagramRenderer.drawSelectionRectangle(e,i,r,s,this.adornerLayer,this.scroller.transform)},t.prototype.renderHighlighter=function(e){var i=zl(this.element.id);this.diagramRenderer.renderHighlighter(e,i,this.scroller.transform)},t.prototype.clearHighlighter=function(){var e=zl(this.element.id),i=e.getElementById(e.id+"_highlighter");i&&i.parentNode.removeChild(i)},t.prototype.getNodesConnectors=function(e){for(var i=0;i0;l--)(a=o[l-1]).parentNode.removeChild(a);if(!ce()){var h=IT(this.element.id).childNodes;for(r=h.length;r>0;r--)h[r-1].parentNode.removeChild(h[r-1])}}},t.prototype.getWrapper=function(e,i){var r;i=e.id+"_"+i;for(var s=e instanceof Ii?e:this.getPortContainer(this.nameTable[e.id]),o=0;o0&&this.applyStyle(e,a=r.annotations)}for(i=0;i0){var a=this.selectedItems.connectors[parseInt(i.toString(),10)].annotations;this.applyStyle(e,a)}},t.prototype.applyStyle=function(e,i){for(var r=0;r0)for(var i=0;i0?r[0].zIndex+(e?1:-1):e?0:this.nodes.length+this.connectors.length-1)<0?i=this.nodes.length+this.connectors.length-1:i===this.nodes.length+this.connectors.length&&(i=0);for(var s=0;s0)for(var s=void 0,o=r.children.length-1;o>=0;o--){var a=r.children[parseInt(o.toString(),10)];i.length>0&&-1!==i.indexOf(a.id.split("_groupElement")[0])&&(r.parentNode.insertBefore(a,s||r),s=a)}r&&r.parentNode.removeChild(r)},t.prototype.deleteGroup=function(e){var r=[];e.children&&(r=this.commandHandler.getChildren(e,[])),this.UpdateBlazorDiagramModelCollection(e);for(var s=0,o=r;s0)for(var xe=0;xe0)if("Path"===t.shape.type&&void 0!==n.shape.data)t.wrapper.children[0].data=n.shape.data;else if("Text"===t.shape.type&&void 0!==n.shape.content)t.wrapper.children[0].content=n.shape.content;else if("Image"===t.shape.type&&void 0!==n.shape.source)t.wrapper.children[0].source=n.shape.source;else if("Native"===t.shape.type){for(var r=void 0,s=0;s-1)&&(this.diagramActions&ee.PreventZIndexOnDragging?this.updateDiagramObject(e,!0):this.updateDiagramObject(e)),!s&&d&&(this.lineRoutingModule&&this.diagramActions&&this.constraints&rt.LineRouting&&"helper"!==e.id?this.diagramActions&ee.ToolAction||this.lineRoutingModule.renderVirtualRegion(this,!0):this.diagramActions&&this.constraints&rt.LineRouting&&"helper"!==e.id&&console.warn('[WARNING] :: Module "LineRouting" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),this.updateConnectorEdges(e),"helper"!==e.id&&!(this.diagramActions&ee.ToolAction))))for(var ya=this.spatialSearch.findObjects(e.wrapper.outerBounds),Mo=0;Moe?Math.abs(r-e):Math.abs(e-r),d=s>i?Math.abs(s-i):Math.abs(i-s);(0===c&&0===d||Number.isNaN(c)&&Number.isNaN(d))&&o.laneMargin&&(u=o.margin.left-o.laneMargin.left,p=o.margin.top-o.laneMargin.top);var f=o.width,g=o.height,v=new Ne(0,0,0,0);if(0!==f&&0!==g&&(v=new Ne((0!==r?r:o.offsetX)-f/2,(0!==s?s:o.offsetY)-g/2,f,g)),h){var y=l,b=this.selectedItems.nodes?this.selectedItems.nodes[0]:void 0;if(""!==y.textAnnotation.textAnnotationTarget&&this.nameTable[y.textAnnotation.textAnnotationTarget])if(""===o.parentId||b&&b.shape&&"TextAnnotation"===b.shape.shape){if("Auto"===y.textAnnotation.textAnnotationDirection&&a.children[0]instanceof Ii&&a.children[0].children[0]instanceof Ke){var w=a.children[0],C=document.getElementById(w.id+"_groupElement"),D=document.getElementById(w.children[0].id+"_groupElement");C.removeChild(D),w.children.splice(0,1),this.isProtectedOnChange=!0,this.bpmnModule.setAnnotationPath(v,w,o,y,y.textAnnotation.textAnnotationDirection,this),this.isProtectedOnChange=!1}}else this.isPositionUndo=!0,this.updateTextAnnotationInSwimlane(o,o),this.isPositionUndo=!1;else o.inEdges.length>0&&(x=this.nameTable[""+o.inEdges[0]])&&x.isBpmnAnnotationConnector&&(x.sourcePoint={x:r>e?x.sourcePoint.x+c:x.sourcePoint.x-c,y:s>i?x.sourcePoint.y+d:x.sourcePoint.y-d});this.nodePropertyChange(o,{},R={ports:[{offset:o.ports[0].offset}]})}else for(var L=0,O=o.outEdges;Le?T.offsetX+c:T.offsetX-c,T.offsetY=s>i?T.offsetY+d:T.offsetY-d,R={offsetX:T.offsetX,offsetY:T.offsetY}),this.nodePropertyChange(T,P,R)}}}},t.prototype.updatePorts=function(e,i){if(e&&e.ports.length>0)for(var r=0,s=Object.keys(e.ports);r0)for(var i=0;i0)for(var r=0;r0&&void 0===r.segments&&(e.segments=[]),void 0!==r.shape&&void 0!==e.shape&&e.shape&&"Bpmn"===e.shape.type&&this.bpmnModule&&this.bpmnModule.updateBPMNConnector(e,i,r,this),void 0!==e.constraints?(this.updateThumbConstraints(this.selectedItems.connectors,this.selectedItems),s=!0):s},t.prototype.connectorPropertyChange=function(e,i,r,s,o){if(this.canEnableBlazorObject){var a=$(e);this.insertValue(a,!1)}var d,u,p,f,l=e.wrapper.bounds,h=!1,c=[];if(h=this.connectorProprtyChangeExtend(e,i,r,h),void 0!==r.visible&&this.updateElementVisibility(e.wrapper,e,e.visible),void 0!==r.sourcePoint||void 0!==r.targetPoint||void 0!==r.sourceID||void 0!==r.targetID||void 0!==r.targetPadding||void 0!==r.sourcePortID||void 0!==r.targetPortID||void 0!==r.sourcePadding||void 0!==r.type||void 0!==r.segments||void 0!==r.flip){if(void 0!==r.sourceID&&r.sourceID!==i.sourceID||r.sourcePortID){if(u=this.findInOutConnectPorts(g=this.nameTable[e.sourceID],!1),(!g||zh(g)||""!==e.sourcePortID&&Ld(u))&&(e.sourceWrapper=g?this.getEndNodeWrapper(g,e,!0):void 0,e.sourcePortID&&void 0===r.sourcePortID&&(e.sourcePortWrapper=g?this.getWrapper(g.wrapper,e.sourcePortID):void 0),this.removePortEdges(this.nameTable[i.sourceID]||g,i.sourcePortID||e.sourcePortID,e.id,!1)),void 0!==r.sourceID&&void 0!==i.sourceID&&""!==i.sourceID){var v=this.nameTable[i.sourceID];void 0!==v&&v.outEdges&&-1!==v.outEdges.indexOf(e.id)&&nm(v.outEdges,e.id)}this.updateEdges(e)}if(void 0!==r.targetID&&r.targetID!==i.targetID){if(d=this.findInOutConnectPorts(y=this.nameTable[r.targetID],!0),(!y||da(y)||""!==e.targetPortID&&Ph(d))&&(e.targetWrapper=y?this.getEndNodeWrapper(y,e,!1):void 0,e.targetPortID&&void 0===r.targetPortID&&(e.targetPortWrapper=y?this.getWrapper(y.wrapper,e.targetPortID):void 0),this.removePortEdges(this.nameTable[i.targetID]||y,i.targetPortID||e.targetPortID,e.id,!0)),void 0!==i&&void 0!==i.targetID&&""!==i.targetID){var S=this.nameTable[i.targetID];void 0!==S&&S.inEdges&&-1!==S.inEdges.indexOf(e.id)&&nm(S.inEdges,e.id)}this.updateEdges(e)}var g,y;void 0!==r.sourcePortID&&r.sourcePortID!==i.sourcePortID&&(e.sourceID&&this.nameTable[e.sourceID]&&(p=this.nameTable[e.sourceID].wrapper),!(g=this.nameTable[e.sourceID])||zh(g)||""!==e.sourcePortID&&Ld(u)?e.sourcePortWrapper=p?this.getWrapper(p,r.sourcePortID):void 0:""===e.sourcePortID&&!zh(g)&&(e.sourcePortWrapper=void 0)),void 0!==r.targetPortID&&r.targetPortID!==i.targetPortID&&(e.targetID&&this.nameTable[e.targetID]&&(f=this.nameTable[e.targetID].wrapper),!(y=this.nameTable[e.targetID])||da(y)||""!==e.targetPortID&&Ph(d)?e.targetPortWrapper=f?this.getWrapper(f,r.targetPortID):void 0:""===e.targetPortID&&!da(y)&&(e.targetPortWrapper=void 0)),void 0!==r.flip&&(e.flip=r.flip,EF(e)),"Orthogonal"===e.type&&this.lineRoutingModule&&this.diagramActions&&this.constraints&rt.LineRouting&&!(this.diagramActions&ee.ToolAction)&&"ComplexHierarchicalTree"!==this.layout.type&&(this.lineRoutingModule.renderVirtualRegion(this,!0),e.sourceID!==e.targetID&&e.segments.length>1&&this.lineRoutingModule.refreshConnectorSegments(this,e,!1)),c=this.getPoints(e)}void 0!==r.style&&Bh(r.style,e.wrapper.children[0]),(c.length>0||void 0!==r.sourceDecorator||void 0!==r.targetDecorator&&function qse(n){return-1!==n.indexOf("shape")||-1!==n.indexOf("pathData")||-1!==n.indexOf("width")||-1!==n.indexOf("height")}(Object.keys(r.targetDecorator))||void 0!==r.cornerRadius)&&(tf(e,c.length>0?c:e.intermediatePoints,this.diagramActions),void 0!==r.type&&(h=!0),c.length>0&&(e.wrapper.measure(new me(e.wrapper.width,e.wrapper.height)),e.wrapper.arrange(e.wrapper.desiredSize),this.updateConnectorAnnotation(e),this.updateConnectorPort(e),this.updateConnectorfixedUserHandles(e),this.updateObject(e,i,r))),(r.sourcePoint||r.targetPoint||r.segments)&&this.diagramActions===ee.Render&&(h=!0),"Bpmn"===e.shape.type&&"Default"===e.shape.sequence&&"Sequence"===e.shape.flow&&this.commandHandler.updatePathElementOffset(e),s||this.updateBridging(),this.updateAnnotations(r,e),this.updateConnectorPorts(r,e),this.updatefixedUserHandle(r,e),e.wrapper.measure(new me(e.wrapper.width,e.wrapper.height)),e.wrapper.arrange(e.wrapper.desiredSize),!1===l.equals(l,e.wrapper.bounds)&&(this.updateQuad(e),"Drag"!==this.eventHandler.currentAction&&this.updateGroupSize(e)),!0===h&&this.checkSelectedItem(e)&&(!(this.diagramActions&ee.ToolAction)||this.diagramActions&ee.UndoRedo)&&this.updateSelector(),this.preventConnectorsUpdate||(!Ds(this)||Ds(this)&&this.scroller.oldCollectionObjects.indexOf(e.id)>-1)&&(this.diagramActions&ee.PreventZIndexOnDragging?this.updateDiagramObject(e,!0):this.updateDiagramObject(e)),this.updateConnectorEdges(e),this.diagramActions&&"New"!==e.status&&(e.status="Update"),this.triggerPropertyChange(o,e,i,r)},t.prototype.removePortEdges=function(e,i,r,s){if(e)for(var o=0;o0&&e.id===s[s.length-1].id&&(r=!0),r},t.prototype.updateDiagramContainerVisibility=function(e,i){if(e instanceof Cs)for(var r=0;r>"),r instanceof Jn&&this.updateAnnotationWrapper(r,s,o,a)),void 0!==e.template&&(r.content=e.template,this.updateAnnotationWrapper(r,s,o,a))},t.prototype.updateAnnotationWrapper=function(e,i,r,s){for(var o=0,a=this.views;o=0&&this.nodes.splice(s,1),delete this.nameTable[""+r]}var o=this.nodes.indexOf(this.nameTable[this.currentSymbol.id]);o>=0&&this.nodes.splice(o,1)}},t.prototype.selectDragedNode=function(e,i,r){this.currentSymbol=e,"SVG"!==this.mode&&this.refreshDiagramLayer(),this.commandHandler.oldSelectedObjects=om(this),this.commandHandler.select(e),this.eventHandler.mouseDown(i.event),this.eventHandler.mouseMove(i.event,i),this.preventDiagramUpdate=!1,this.updatePage(),r.style.opacity="0"},t.prototype.initDroppables=function(){var s,o,e=this,i={},r={},a="selectedSymbols";this.droppable=new lR(this.element);var l=5;this.droppable.over=function(h){if(e.rulerSettings.showRulers){var c=document.getElementById(e.element.id+"_vRuler"),d=parseFloat(c.style.width);l=d+1}if(0===e.previousSelectedObjects.length&&!e.currentSymbol&&(e.previousSelectedObjects=e.commandHandler.getSelectedObject()),e.commandHandler.PreventConnectorSplit=!0,e.currentSymbol)h.event.touches&&h.event.touches.length&&e.eventHandler.mouseMove(h.event,h.event.touches);else{var u=null;if(!h.dragData&&"drag"===h.name){var p=document.getElementsByClassName("e-dragclone")[0];p&&(u=p)}if(h.dragData||u){var f=void 0,g=void 0;document.getElementById(e.element.id+"content").focus();var v=e.eventHandler.getMousePosition(h.event),y=void 0,S=u||h.dragData.helper,b=S.getAttribute("paletteId"),M=void 0,w=void 0,C=void 0,D=void 0;if(!b&&h.dragData){e.triggerEvent(Ce.dragEnter,A={source:null,element:f,cancel:!1,diagram:e,dragData:h.dragData.draggedElement.ej2_instances[0].dragData,dragItem:f});var x=void 0,R=void 0;if(A.dragItem){if(A.dragItem.sourcePoint&&A.dragItem.targetPoint?R=new de(e,"connectors",A.dragItem,!0):x=new te(e,"nodes",A.dragItem,!0),e.initObject(f=x||R,void 0,void 0,!0),e.enterObject=f,e.enterTable=r,f instanceof te)x.offsetX=v.x+5+x.width*x.pivot.x,x.offsetY=v.y+x.height*x.pivot.y;else if(f instanceof de){var L=Ne.toBounds([f.sourcePoint,f.targetPoint]),O=v.x-L.left,N=v.y-L.top;f.sourcePoint.x+=O,f.sourcePoint.y+=N,f.targetPoint.x+=O,f.targetPoint.y+=N}e.preventDiagramUpdate=!0,e.currentSymbol=f,"SVG"!==e.mode&&e.refreshDiagramLayer(),e.selectDragedNode(f,h,S),delete e.enterObject,delete e.enterTable,e.droppable[""+a]=S,e.allowServerDataBinding=!0}}if(b){var T=document.getElementById(b).ej2_instances[0];if(e.droppable.sourceElement=T,T){var B=T[""+a];e.allowServerDataBinding=!1,y=$(T[""+a]),i=T.childTable;var j=B.wrapper.children[0].children[0];if(D=function $se(n,t,e){var i=AF(n,t,e,"width"),r=AF(n,t,e,"height");return new me(i,r)}(T,y,j),T[""+a]instanceof te){"TextAnnotation"===B.shape.shape?(y.offsetX=v.x+11+D.width*y.pivot.x,y.offsetY=v.y+11+D.height*y.pivot.y):(y.offsetX=v.x+5+D.width*y.pivot.x,y.offsetY=v.y+D.height*y.pivot.y),"Bpmn"===(x=new te(e,"nodes",y,!0)).shape.type&&x.shape.activity.subProcess.processes&&x.shape.activity.subProcess.processes.length&&(x.shape.activity.subProcess.processes=[]),w=x.previewSize,C=T.symbolDragSize;var Q=T.symbolPreview;if(x.width=(M=x.dragSize).width||C.width||w.width||Q.width||x.width,x.height=M.height||C.height||w.height||Q.height||x.height,"SwimLane"===x.shape.type){if(e.diagramActions|=ee.PreventHistory,x.shape.isLane){x.children=[],s={id:"header"+Qe()},"Horizontal"===x.shape.orientation?(s.width=x.shape.lanes[0].header.width,s.height=x.shape.lanes[0].height):(s.width=x.shape.lanes[0].width,s.height=x.shape.lanes[0].header.height),s.style=x.shape.lanes[0].header.style,s.offsetX=v.x+l+s.width/2,s.offsetY=v.y+s.height/2,e.diagramActions|=ee.PreventCollectionChangeOnDragOver,s=e.add(s),o={id:"body"+Qe()},"Horizontal"===x.shape.orientation?(o.width=x.shape.lanes[0].width-s.width,o.height=x.shape.lanes[0].height,o.offsetX=v.x+l+(x.shape.lanes[0].header.width+o.width/2),o.offsetY=v.y+o.height/2):(o.width=x.shape.lanes[0].width,o.height=x.shape.lanes[0].height-s.height,o.offsetX=v.x+l+o.width/2,o.offsetY=v.y+(x.shape.lanes[0].header.height+o.height/2)),o.style=x.shape.lanes[0].style,o=e.add(o);var oe={id:"group"+Qe(),children:[s.id,o.id]};oe.shape=x.shape,oe.width=x.shape.lanes[0].width,oe.height=x.shape.lanes[0].height,oe.previewSize=x.previewSize,oe.dragSize=x.dragSize,oe.addInfo=x.addInfo,x=e.add(oe),e.diagramActions&=~ee.PreventCollectionChangeOnDragOver}e.diagramActions&=~ee.PreventHistory}if(x.shape.isPhase&&((g="Horizontal"===x.shape.orientation)?(x.offsetX=v.x+l+(x.width||j.actualSize.width)/2,x.offsetY=v.y,x.shape.data="M20,"+x.height/2+" L"+(x.width-20)+","+x.height/2+"z",x.height=1):(x.offsetX=v.x+5,x.offsetY=v.y+(x.height||j.actualSize.height)/2,x.shape.data="M"+x.width/2+",20 L"+x.width/2+","+(x.height-20)+"z",x.width=1)),"UmlClassifier"===x.shape.type&&(x.children=x.width=x.height=void 0,y.children=void 0,"Class"===x.shape.classifier&&x.shape.classShape.methods.length<=0&&x.shape.classShape.attributes.length<=0&&(x.shape.classShape.attributes=[{name:"Name",type:"Type",style:{}}]),"Enumeration"===x.shape.classifier&&x.shape.enumerationShape.members.length<=0&&(x.shape.enumerationShape.members=[{name:"Name"}]),"Interface"===x.shape.classifier&&x.shape.interfaceShape.methods.length<=0&&x.shape.interfaceShape.attributes.length<=0&&(x.shape.interfaceShape.attributes=[{name:"Name",type:"Type",style:{}}])),f=x,y.children){var ue=y;r=e.getChildren(ue,{},i),nT(ue,-ue.offsetX,-ue.offsetY,r,!0,e)}}else if(T[""+a]instanceof de){f=new de(e,"connectors",y,!0);var Me=Ne.toBounds([f.sourcePoint,f.targetPoint]),De=v.x-Me.left,xe=v.y-Me.top;f.sourcePoint.x+=De,f.sourcePoint.y+=xe,f.targetPoint.x+=De,f.targetPoint.y+=xe}f.shape.isLane||(f.id+=Qe());var A={source:T,element:f,cancel:!1,diagram:e,dragData:null,dragItem:f};if(e.enterObject=f,e.enterTable=r,e.triggerEvent(Ce.dragEnter,A),f instanceof te&&"SwimLane"===f.shape.type&&f.shape.isLane){var Ie=A.element,Ve=Ie.shape.lanes[0];g="Horizontal"===Ie.shape.orientation;var ot=e.nameTable[f.children[0]],$e=e.nameTable[f.children[1]];w=f.previewSize,C=T.symbolDragSize,Ve.width=(M=f.dragSize).width||C.width||w.width||Ve.width,Ve.height=M.height||C.height||w.height||Ve.height,g?(s.width=Ve.header.width,s.height=Ve.height,o.width=Ve.width-s.width,o.height=Ve.height,o.offsetX=v.x+l+(Ve.header.width+$e.width/2),o.offsetY=v.y+$e.height/2):(s.width=Ve.width,s.height=Ve.header.height,o.width=Ve.width,o.height=Ve.height-s.height,o.offsetX=v.x+l+$e.width/2,o.offsetY=v.y+(Ve.header.height+$e.height/2)),s.offsetX=v.x+l+ot.width/2,s.offsetY=v.y+ot.height/2,f.width=Ve.width,f.height=Ve.height}if(f instanceof te&&f.shape.isPhase&&(g?f.height=1:f.width=1),!e.activeLayer.lock&&!A.cancel){if(e.preventDiagramUpdate=!0,f.children&&e.findChild(f,r),e.preventDiagramUpdate=!0,f.zIndex!==Number.MIN_VALUE&&(f.zIndex=Number.MIN_VALUE),e.initObject(f,void 0,void 0,!0),e.bpmnModule)for(var Mi=0;Mi0&&(S.segments=[]),d=this.add(S,!0)),(S||d)&&(Vv(this)||Wv(this))&&this.select([this.nameTable[S[""+b]]],!1,this.previousSelectedObjects),y.target&&y.target instanceof de&&!0===this.enableConnectorSplit&&this.nameTable[S[""+b]]instanceof te&&(this.commandHandler.connectorSplit(this.nameTable[S[""+b]],y.target),this.commandHandler.PreventConnectorSplit=!1))),this.protectPropertyChange(!1),v=this.nameTable[S[""+b]],S.hasTarget&&(S.nodeId=S.hasTarget,this.remove(S)),this.bpmnModule&&v instanceof te&&S.processId&&(v.processId=S.processId,this.bpmnModule.dropBPMNchild(this.nameTable[v.processId],v,this)),y.cancel||this.endGroupAction(),"SVG"!==this.mode&&this.refreshDiagramLayer(),delete this.droppable[""+c]):(this.triggerEvent(Ce.drop,y={source:h.droppedElement,element:void 0,target:this.eventHandler.hoverNode||this.eventHandler.lastObjectUnderMouse||this,cancel:!1,position:void 0}),S=void 0,b="id"),this.droppable[M="selectedSymbols"]&&this.droppable[""+M].parentNode)gt(this.droppable[""+M]);else for(w=document.getElementsByClassName("e-dragclone"),C=0;C0)for(var p=0;p1),e.previousSelectedObject=null}}},t.prototype.getDropEventArgs=function(e){if(this.eventHandler.lastObjectUnderMouse||this.eventHandler.hoverNode){var i=this.eventHandler.lastObjectUnderMouse||this.eventHandler.hoverNode;e.target=fs(i)===de?{connector:i}:{node:i}}else e.target.diagramId=this.element.id},t.prototype.removeChildInNodes=function(e){if(e){if(e.children)for(var i=0;i1){var l=2;if(e.children&&e.children.length>0)for(;e.children.indexOf(i.objects[s-l])>-1;)l++;this.commandHandler.moveSvgNode(e.id,i.objects[s-l]),this.commandHandler.moveSvgNode(i.objects[s-l],e.id)}else if(o){var h=this.commandHandler.getLayer(this.layerZIndexTable[o.zIndex]).objects[0];h?(this.commandHandler.moveSvgNode(e.id,h),this.commandHandler.updateNativeNodeIndex(e.id,h)):this.moveObjectsUp(e,i)}else this.moveObjectsUp(e,i)},t.prototype.moveObjectsUp=function(e,i){for(var r,s=this.layers.length-1;s>=0;s--)if(r=this.layers[parseInt(s.toString(),10)],i.id!==r.id){var o=this.commandHandler.getLayer(this.layerZIndexTable[r.zIndex]).objects[r.objects.length-1];if(o){this.commandHandler.moveSvgNode(e.id,o),this.commandHandler.moveSvgNode(o,e.id);break}}},t.prototype.insertData=function(e){return this.crudOperation(e,"create",this.getNewUpdateNodes("New"))},t.prototype.updateData=function(e){return this.crudOperation(e,"update",this.getNewUpdateNodes("Update"))},t.prototype.removeData=function(e){return this.crudOperation(e,"destroy",this.getDeletedNodes())},t.prototype.crudOperation=function(e,i,r){if(e){var s=this.parameterMap(e,!(e instanceof de));if(s){var o=e instanceof de?this.dataSourceSettings.connectionDataSource.crudAction[""+i]:this.dataSourceSettings.crudAction[""+i];this.raiseAjaxPost(JSON.stringify(s),o)}return s}var a=r;return this.processCrudCollection(a,this.dataSourceSettings.crudAction[""+i],this.dataSourceSettings.connectionDataSource.crudAction[""+i]),a},t.prototype.processCrudCollection=function(e,i,r){if(e.nodes){var s=[],o=void 0;for(o=0;o0&&this.raiseAjaxPost(JSON.stringify(s),i)}if(e.connectors){for(s=[],o=void 0,o=0;o0&&this.raiseAjaxPost(JSON.stringify(s),r)}},t.prototype.parameterMap=function(e,i){var s,r={},o=i?this.dataSourceSettings:this.dataSourceSettings.connectionDataSource;if(o.id&&(r[o.id]=e.id),o.sourcePointX&&o.sourcePointY&&(r[o.sourcePointX]=e.sourcePoint.x,r[o.sourcePointY]=e.sourcePoint.y),o.targetPointX&&o.targetPointY&&(r[o.targetPointX]=e.targetPoint.x,r[o.targetPointY]=e.targetPoint.y),o.sourceID&&(r[o.sourceID]=e.sourceID),o.targetID&&(r[o.targetID]=e.targetID),o.crudAction&&o.crudAction.customFields&&o.crudAction.customFields.length>0)for(s=0;s{class n extends uh{constructor(e){super(),this.viewContainerRef=e,gl("currentInstance",this,this.viewContainerRef),this.registerEvents($ae),this.directivePropList=qae}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-layer"]],inputs:{addInfo:"addInfo",id:"id",lock:"lock",objects:"objects",visible:"visible",zIndex:"zIndex"},features:[yn]}),n})(),Jae=(()=>{class n extends ph{constructor(){super("layers")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-layers"]],contentQueries:function(e,i,r){if(1&e&&dn(r,Zae,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),Kae=["action","cursor"],ele=[],tle=(()=>{class n extends uh{constructor(e){super(),this.viewContainerRef=e,gl("currentInstance",this,this.viewContainerRef),this.registerEvents(ele),this.directivePropList=Kae}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-cursormap"]],inputs:{action:"action",cursor:"cursor"},features:[yn]}),n})(),ile=(()=>{class n extends ph{constructor(){super("customcursor")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-cursormaps"]],contentQueries:function(e,i,r){if(1&e&&dn(r,tle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),rle=["alignment","cornerRadius","displacement","fill","handleStrokeColor","handleStrokeWidth","height","iconStrokeColor","iconStrokeWidth","id","offset","padding","pathData","tooltip","visibility","width"],nle=[],sle=(()=>{class n extends uh{constructor(e){super(),this.viewContainerRef=e,gl("currentInstance",this,this.viewContainerRef),this.registerEvents(nle),this.directivePropList=rle}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-connector-fixeduserhandle"]],inputs:{alignment:"alignment",cornerRadius:"cornerRadius",displacement:"displacement",fill:"fill",handleStrokeColor:"handleStrokeColor",handleStrokeWidth:"handleStrokeWidth",height:"height",iconStrokeColor:"iconStrokeColor",iconStrokeWidth:"iconStrokeWidth",id:"id",offset:"offset",padding:"padding",pathData:"pathData",tooltip:"tooltip",visibility:"visibility",width:"width"},features:[yn]}),n})(),ole=(()=>{class n extends ph{constructor(){super("fixeduserhandles")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-connector-fixeduserhandles"]],contentQueries:function(e,i,r){if(1&e&&dn(r,sle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),ale=["addInfo","alignment","annotationType","constraints","content","displacement","dragLimit","height","horizontalAlignment","hyperlink","id","margin","offset","rotateAngle","rotationReference","segmentAngle","style","template","tooltip","type","verticalAlignment","visibility","width"],lle=[],hle=(()=>{class n extends uh{constructor(e){super(),this.viewContainerRef=e,gl("currentInstance",this,this.viewContainerRef),this.registerEvents(lle),this.directivePropList=ale}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-connector-annotation"]],inputs:{addInfo:"addInfo",alignment:"alignment",annotationType:"annotationType",constraints:"constraints",content:"content",displacement:"displacement",dragLimit:"dragLimit",height:"height",horizontalAlignment:"horizontalAlignment",hyperlink:"hyperlink",id:"id",margin:"margin",offset:"offset",rotateAngle:"rotateAngle",rotationReference:"rotationReference",segmentAngle:"segmentAngle",style:"style",template:"template",tooltip:"tooltip",type:"type",verticalAlignment:"verticalAlignment",visibility:"visibility",width:"width"},features:[yn]}),n})(),cle=(()=>{class n extends ph{constructor(){super("annotations")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-connector-annotations"]],contentQueries:function(e,i,r){if(1&e&&dn(r,hle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),dle=["addInfo","allowNodeOverlap","annotations","bezierSettings","bridgeSpace","connectionPadding","connectorSpacing","constraints","cornerRadius","dragSize","excludeFromLayout","fixedUserHandles","flip","flipMode","hitPadding","id","margin","maxSegmentThumb","ports","previewSize","segmentThumbShape","segmentThumbSize","segments","shape","sourceDecorator","sourceID","sourcePadding","sourcePoint","sourcePortID","style","symbolInfo","targetDecorator","targetID","targetPadding","targetPoint","targetPortID","tooltip","type","visible","wrapper","zIndex"],ule=[],v_=(()=>{class n extends uh{constructor(e){super(),this.viewContainerRef=e,this.tags=["fixedUserHandles","annotations"],gl("currentInstance",this,this.viewContainerRef),this.registerEvents(ule),this.directivePropList=dle}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-connector"]],contentQueries:function(e,i,r){if(1&e&&(dn(r,ole,5),dn(r,cle,5)),2&e){let s;Kr(s=en())&&(i.childFixedUserHandles=s.first),Kr(s=en())&&(i.childAnnotations=s.first)}},inputs:{addInfo:"addInfo",allowNodeOverlap:"allowNodeOverlap",annotations:"annotations",bezierSettings:"bezierSettings",bridgeSpace:"bridgeSpace",connectionPadding:"connectionPadding",connectorSpacing:"connectorSpacing",constraints:"constraints",cornerRadius:"cornerRadius",dragSize:"dragSize",excludeFromLayout:"excludeFromLayout",fixedUserHandles:"fixedUserHandles",flip:"flip",flipMode:"flipMode",hitPadding:"hitPadding",id:"id",margin:"margin",maxSegmentThumb:"maxSegmentThumb",ports:"ports",previewSize:"previewSize",segmentThumbShape:"segmentThumbShape",segmentThumbSize:"segmentThumbSize",segments:"segments",shape:"shape",sourceDecorator:"sourceDecorator",sourceID:"sourceID",sourcePadding:"sourcePadding",sourcePoint:"sourcePoint",sourcePortID:"sourcePortID",style:"style",symbolInfo:"symbolInfo",targetDecorator:"targetDecorator",targetID:"targetID",targetPadding:"targetPadding",targetPoint:"targetPoint",targetPortID:"targetPortID",tooltip:"tooltip",type:"type",visible:"visible",wrapper:"wrapper",zIndex:"zIndex"},features:[yn]}),n})(),m_=(()=>{class n extends ph{constructor(){super("connectors")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-connectors"]],contentQueries:function(e,i,r){if(1&e&&dn(r,v_,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),ple=["cornerRadius","fill","handleStrokeColor","handleStrokeWidth","height","iconStrokeColor","iconStrokeWidth","id","margin","offset","padding","pathData","tooltip","visibility","width"],fle=[],gle=(()=>{class n extends uh{constructor(e){super(),this.viewContainerRef=e,gl("currentInstance",this,this.viewContainerRef),this.registerEvents(fle),this.directivePropList=ple}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-node-fixeduserhandle"]],inputs:{cornerRadius:"cornerRadius",fill:"fill",handleStrokeColor:"handleStrokeColor",handleStrokeWidth:"handleStrokeWidth",height:"height",iconStrokeColor:"iconStrokeColor",iconStrokeWidth:"iconStrokeWidth",id:"id",margin:"margin",offset:"offset",padding:"padding",pathData:"pathData",tooltip:"tooltip",visibility:"visibility",width:"width"},features:[yn]}),n})(),vle=(()=>{class n extends ph{constructor(){super("fixeduserhandles")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-node-fixeduserhandles"]],contentQueries:function(e,i,r){if(1&e&&dn(r,gle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),mle=["addInfo","annotationType","constraints","content","dragLimit","height","horizontalAlignment","hyperlink","id","margin","offset","rotateAngle","rotationReference","style","template","tooltip","type","verticalAlignment","visibility","width"],yle=[],Sle=(()=>{class n extends uh{constructor(e){super(),this.viewContainerRef=e,gl("currentInstance",this,this.viewContainerRef),this.registerEvents(yle),this.directivePropList=mle}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-node-annotation"]],inputs:{addInfo:"addInfo",annotationType:"annotationType",constraints:"constraints",content:"content",dragLimit:"dragLimit",height:"height",horizontalAlignment:"horizontalAlignment",hyperlink:"hyperlink",id:"id",margin:"margin",offset:"offset",rotateAngle:"rotateAngle",rotationReference:"rotationReference",style:"style",template:"template",tooltip:"tooltip",type:"type",verticalAlignment:"verticalAlignment",visibility:"visibility",width:"width"},features:[yn]}),n})(),Ile=(()=>{class n extends ph{constructor(){super("annotations")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-node-annotations"]],contentQueries:function(e,i,r){if(1&e&&dn(r,Sle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),ble=["addInfo","connectionDirection","constraints","height","horizontalAlignment","id","inEdges","margin","offset","outEdges","pathData","shape","style","tooltip","verticalAlignment","visibility","width"],Mle=[],wle=(()=>{class n extends uh{constructor(e){super(),this.viewContainerRef=e,gl("currentInstance",this,this.viewContainerRef),this.registerEvents(Mle),this.directivePropList=ble}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-node-port"]],inputs:{addInfo:"addInfo",connectionDirection:"connectionDirection",constraints:"constraints",height:"height",horizontalAlignment:"horizontalAlignment",id:"id",inEdges:"inEdges",margin:"margin",offset:"offset",outEdges:"outEdges",pathData:"pathData",shape:"shape",style:"style",tooltip:"tooltip",verticalAlignment:"verticalAlignment",visibility:"visibility",width:"width"},features:[yn]}),n})(),Cle=(()=>{class n extends ph{constructor(){super("ports")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-node-ports"]],contentQueries:function(e,i,r){if(1&e&&dn(r,wle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),Ele=["addInfo","annotations","backgroundColor","borderColor","borderWidth","branch","children","collapseIcon","columnIndex","columnSpan","columns","constraints","container","data","dragSize","excludeFromLayout","expandIcon","fixedUserHandles","flip","flipMode","height","horizontalAlignment","id","isExpanded","layoutInfo","margin","maxHeight","maxWidth","minHeight","minWidth","offsetX","offsetY","padding","pivot","ports","previewSize","rotateAngle","rowIndex","rowSpan","rows","shadow","shape","style","symbolInfo","tooltip","verticalAlignment","visible","width","wrapper","zIndex"],Dle=[],y_=(()=>{class n extends uh{constructor(e){super(),this.viewContainerRef=e,this.tags=["fixedUserHandles","annotations","ports"],gl("currentInstance",this,this.viewContainerRef),this.registerEvents(Dle),this.directivePropList=Ele}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-node"]],contentQueries:function(e,i,r){if(1&e&&(dn(r,vle,5),dn(r,Ile,5),dn(r,Cle,5)),2&e){let s;Kr(s=en())&&(i.childFixedUserHandles=s.first),Kr(s=en())&&(i.childAnnotations=s.first),Kr(s=en())&&(i.childPorts=s.first)}},inputs:{addInfo:"addInfo",annotations:"annotations",backgroundColor:"backgroundColor",borderColor:"borderColor",borderWidth:"borderWidth",branch:"branch",children:"children",collapseIcon:"collapseIcon",columnIndex:"columnIndex",columnSpan:"columnSpan",columns:"columns",constraints:"constraints",container:"container",data:"data",dragSize:"dragSize",excludeFromLayout:"excludeFromLayout",expandIcon:"expandIcon",fixedUserHandles:"fixedUserHandles",flip:"flip",flipMode:"flipMode",height:"height",horizontalAlignment:"horizontalAlignment",id:"id",isExpanded:"isExpanded",layoutInfo:"layoutInfo",margin:"margin",maxHeight:"maxHeight",maxWidth:"maxWidth",minHeight:"minHeight",minWidth:"minWidth",offsetX:"offsetX",offsetY:"offsetY",padding:"padding",pivot:"pivot",ports:"ports",previewSize:"previewSize",rotateAngle:"rotateAngle",rowIndex:"rowIndex",rowSpan:"rowSpan",rows:"rows",shadow:"shadow",shape:"shape",style:"style",symbolInfo:"symbolInfo",tooltip:"tooltip",verticalAlignment:"verticalAlignment",visible:"visible",width:"width",wrapper:"wrapper",zIndex:"zIndex"},features:[yn]}),n})(),S_=(()=>{class n extends ph{constructor(){super("nodes")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-nodes"]],contentQueries:function(e,i,r){if(1&e&&dn(r,y_,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})();const xle=["animationComplete","click","collectionChange","commandExecute","connectionChange","contextMenuBeforeItemRender","contextMenuClick","contextMenuOpen","created","dataLoaded","doubleClick","dragEnter","dragLeave","dragOver","drop","elementDraw","expandStateChange","fixedUserHandleClick","historyChange","historyStateChange","keyDown","keyUp","load","loaded","mouseEnter","mouseLeave","mouseOver","mouseWheel","onFixedUserHandleMouseDown","onFixedUserHandleMouseEnter","onFixedUserHandleMouseLeave","onFixedUserHandleMouseUp","onImageLoad","onUserHandleMouseDown","onUserHandleMouseEnter","onUserHandleMouseLeave","onUserHandleMouseUp","positionChange","propertyChange","rotateChange","scrollChange","segmentChange","segmentCollectionChange","selectionChange","sizeChange","sourcePointChange","targetPointChange","textEdit"],Tle=[""];let Ale=(()=>{let n=class extends Rl{constructor(e,i,r,s){super(),this.ngEle=e,this.srenderer=i,this.viewContainerRef=r,this.injector=s,this.tags=["layers","customCursor","connectors","nodes"],this.element=this.ngEle.nativeElement,this.injectedModules=this.injectedModules||[];try{let o=this.injector.get("DiagramsHierarchicalTree");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsMindMap");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsRadialTree");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsComplexHierarchicalTree");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsDataBinding");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsSnapping");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsPrintAndExport");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsBpmnDiagrams");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsSymmetricLayout");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsConnectorBridging");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsUndoRedo");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsLayoutAnimation");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsDiagramContextMenu");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsLineRouting");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsConnectorEditing");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsLineDistribution");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsEj1Serialization");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsFlowchartLayout");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}this.registerEvents(xle),this.addTwoWay.call(this,Tle),gl("currentInstance",this,this.viewContainerRef),this.context=new SR}ngOnInit(){this.context.ngOnInit(this)}ngAfterViewInit(){this.context.ngAfterViewInit(this)}ngOnDestroy(){this.context.ngOnDestroy(this)}ngAfterContentChecked(){this.tagObjects[0].instance=this.childLayers,this.childCustomCursor&&(this.tagObjects[1].instance=this.childCustomCursor),this.childConnectors&&(this.tagObjects[2].instance=this.childConnectors),this.childNodes&&(this.tagObjects[3].instance=this.childNodes),this.context.ngAfterContentChecked(this)}};return n.\u0275fac=function(e){return new(e||n)(Ot(Jc),Ot(dM),Ot(xn),Ot(Wo))},n.\u0275cmp=Ub({type:n,selectors:[["ejs-diagram"]],contentQueries:function(e,i,r){if(1&e&&(dn(r,Qae,5),dn(r,Gae,5),dn(r,Xae,5),dn(r,Jae,5),dn(r,ile,5),dn(r,m_,5),dn(r,S_,5)),2&e){let s;Kr(s=en())&&(i.annotationTemplate=s.first),Kr(s=en())&&(i.nodeTemplate=s.first),Kr(s=en())&&(i.userHandleTemplate=s.first),Kr(s=en())&&(i.childLayers=s.first),Kr(s=en())&&(i.childCustomCursor=s.first),Kr(s=en())&&(i.childConnectors=s.first),Kr(s=en())&&(i.childNodes=s.first)}},inputs:{addInfo:"addInfo",annotationTemplate:"annotationTemplate",backgroundColor:"backgroundColor",bridgeDirection:"bridgeDirection",commandManager:"commandManager",connectorDefaults:"connectorDefaults",connectors:"connectors",constraints:"constraints",contextMenuSettings:"contextMenuSettings",customCursor:"customCursor",dataSourceSettings:"dataSourceSettings",diagramSettings:"diagramSettings",drawingObject:"drawingObject",enableConnectorSplit:"enableConnectorSplit",enablePersistence:"enablePersistence",enableRtl:"enableRtl",fixedUserHandleTemplate:"fixedUserHandleTemplate",getConnectorDefaults:"getConnectorDefaults",getCustomCursor:"getCustomCursor",getCustomProperty:"getCustomProperty",getCustomTool:"getCustomTool",getDescription:"getDescription",getNodeDefaults:"getNodeDefaults",height:"height",historyManager:"historyManager",layers:"layers",layout:"layout",locale:"locale",mode:"mode",nodeDefaults:"nodeDefaults",nodeTemplate:"nodeTemplate",nodes:"nodes",pageSettings:"pageSettings",rulerSettings:"rulerSettings",scrollSettings:"scrollSettings",segmentThumbShape:"segmentThumbShape",segmentThumbSize:"segmentThumbSize",selectedItems:"selectedItems",serializationSettings:"serializationSettings",setNodeTemplate:"setNodeTemplate",snapSettings:"snapSettings",tool:"tool",tooltip:"tooltip",updateSelection:"updateSelection",userHandleTemplate:"userHandleTemplate",width:"width"},outputs:{animationComplete:"animationComplete",click:"click",collectionChange:"collectionChange",commandExecute:"commandExecute",connectionChange:"connectionChange",contextMenuBeforeItemRender:"contextMenuBeforeItemRender",contextMenuClick:"contextMenuClick",contextMenuOpen:"contextMenuOpen",created:"created",dataLoaded:"dataLoaded",doubleClick:"doubleClick",dragEnter:"dragEnter",dragLeave:"dragLeave",dragOver:"dragOver",drop:"drop",elementDraw:"elementDraw",expandStateChange:"expandStateChange",fixedUserHandleClick:"fixedUserHandleClick",historyChange:"historyChange",historyStateChange:"historyStateChange",keyDown:"keyDown",keyUp:"keyUp",load:"load",loaded:"loaded",mouseEnter:"mouseEnter",mouseLeave:"mouseLeave",mouseOver:"mouseOver",mouseWheel:"mouseWheel",onFixedUserHandleMouseDown:"onFixedUserHandleMouseDown",onFixedUserHandleMouseEnter:"onFixedUserHandleMouseEnter",onFixedUserHandleMouseLeave:"onFixedUserHandleMouseLeave",onFixedUserHandleMouseUp:"onFixedUserHandleMouseUp",onImageLoad:"onImageLoad",onUserHandleMouseDown:"onUserHandleMouseDown",onUserHandleMouseEnter:"onUserHandleMouseEnter",onUserHandleMouseLeave:"onUserHandleMouseLeave",onUserHandleMouseUp:"onUserHandleMouseUp",positionChange:"positionChange",propertyChange:"propertyChange",rotateChange:"rotateChange",scrollChange:"scrollChange",segmentChange:"segmentChange",segmentCollectionChange:"segmentCollectionChange",selectionChange:"selectionChange",sizeChange:"sizeChange",sourcePointChange:"sourcePointChange",targetPointChange:"targetPointChange",textEdit:"textEdit"},features:[yn],decls:0,vars:0,template:function(e,i){},encapsulation:2,changeDetection:0}),P0([xC()],n.prototype,"annotationTemplate",void 0),P0([xC()],n.prototype,"nodeTemplate",void 0),P0([xC()],n.prototype,"userHandleTemplate",void 0),n=P0([PZ([SR])],n),n})(),Lle=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Om({type:n}),n.\u0275inj=Sf({imports:[[sq]]}),n})();const Nle=["diagram"];let Ole=(()=>{class n{constructor(){this.sourcePoint1="node1",this.targetPoint1="node2"}getNodeDefaults(e){return e.height=70,e.width=100,e}group(){this.diagram.selectAll(),this.diagram.group()}unGroup(){this.diagram.unGroup()}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275cmp=Ub({type:n,selectors:[["app-container"]],viewQuery:function(i,r){if(1&i&&function pP(n,t,e){const i=xi();i.firstCreatePass&&(dP(i,new lP(n,t,e),-1),2==(2&t)&&(i.staticViewQueries=!0)),cP(i,Se(),t)}(Nle,5),2&i){let s;Kr(s=en())&&(r.diagram=s.first)}},standalone:!0,features:[PP([]),RP],decls:16,vars:9,consts:[[3,"click"],["id","diagram","width","100%","height","580px",3,"getNodeDefaults"],["diagram",""],["id","node1",3,"offsetX","offsetY"],["id","node2",3,"offsetX","offsetY"],["id","node3",3,"offsetX","offsetY"],["id","connector","type","Orthogonal",3,"sourceID","targetID"]],template:function(i,r){1&i&&(ih(0,"label"),mg(1,"( CTRL + G ) "),rh(),ih(2,"button",0),Xy("click",function(){return r.group()}),mg(3,"Group"),rh(),ih(4,"label"),mg(5,"( CTRL + Shift + G) "),rh(),ih(6,"button",0),Xy("click",function(){return r.unGroup()}),mg(7,"Un Group"),rh(),ih(8,"ejs-diagram",1,2)(10,"e-nodes"),Vy(11,"e-node",3)(12,"e-node",4)(13,"e-node",5),rh(),ih(14,"e-connectors"),Vy(15,"e-connector",6),rh()()),2&i&&(Lu(8),nd("getNodeDefaults",r.getNodeDefaults),Lu(3),nd("offsetX",100)("offsetY",100),Lu(),nd("offsetX",300)("offsetY",100),Lu(),nd("offsetX",200)("offsetY",200),Lu(2),nd("sourceID",r.sourcePoint1)("targetID",r.targetPoint1))},dependencies:[Lle,Ale,v_,m_,y_,S_],encapsulation:2})}}return n})();Wd(332),function $q(n,t){return DG({rootComponent:n,...Ez(t)})}(Ole).catch(n=>console.error(n))},332:()=>{!function(Z){const se=Z.performance;function ye(Pi){se&&se.mark&&se.mark(Pi)}function fe(Pi,ht){se&&se.measure&&se.measure(Pi,ht)}ye("Zone");const be=Z.__Zone_symbol_prefix||"__zone_symbol__";function ke(Pi){return be+Pi}const at=!0===Z[ke("forceDuplicateZoneCheck")];if(Z.Zone){if(at||"function"!=typeof Z.Zone.__symbol__)throw new Error("Zone already loaded.");return Z.Zone}let tt=(()=>{class Pi{static{this.__symbol__=ke}static assertZonePatched(){if(Z.Promise!==_o.ZoneAwarePromise)throw new Error("Zone.js has detected that ZoneAwarePromise `(window|global).Promise` has been overwritten.\nMost likely cause is that a Promise polyfill has been loaded after Zone.js (Polyfilling Promise api is not necessary when zone.js is loaded. If you must load one, do so before loading zone.js.)")}static get root(){let F=Pi.current;for(;F.parent;)F=F.parent;return F}static get current(){return Ur.zone}static get currentTask(){return Do}static __load_patch(F,ae,Et=!1){if(_o.hasOwnProperty(F)){if(!Et&&at)throw Error("Already loaded patch: "+F)}else if(!Z["__Zone_disable_"+F]){const Xt="Zone:"+F;ye(Xt),_o[F]=ae(Z,Pi,cn),fe(Xt,Xt)}}get parent(){return this._parent}get name(){return this._name}constructor(F,ae){this._parent=F,this._name=ae?ae.name||"unnamed":"",this._properties=ae&&ae.properties||{},this._zoneDelegate=new Lt(this,this._parent&&this._parent._zoneDelegate,ae)}get(F){const ae=this.getZoneWith(F);if(ae)return ae._properties[F]}getZoneWith(F){let ae=this;for(;ae;){if(ae._properties.hasOwnProperty(F))return ae;ae=ae._parent}return null}fork(F){if(!F)throw new Error("ZoneSpec required!");return this._zoneDelegate.fork(this,F)}wrap(F,ae){if("function"!=typeof F)throw new Error("Expecting function got: "+F);const Et=this._zoneDelegate.intercept(this,F,ae),Xt=this;return function(){return Xt.runGuarded(Et,this,arguments,ae)}}run(F,ae,Et,Xt){Ur={parent:Ur,zone:this};try{return this._zoneDelegate.invoke(this,F,ae,Et,Xt)}finally{Ur=Ur.parent}}runGuarded(F,ae=null,Et,Xt){Ur={parent:Ur,zone:this};try{try{return this._zoneDelegate.invoke(this,F,ae,Et,Xt)}catch(Un){if(this._zoneDelegate.handleError(this,Un))throw Un}}finally{Ur=Ur.parent}}runTask(F,ae,Et){if(F.zone!=this)throw new Error("A task can only be run in the zone of creation! (Creation: "+(F.zone||_n).name+"; Execution: "+this.name+")");if(F.state===sr&&(F.type===ts||F.type===Pt))return;const Xt=F.state!=lt;Xt&&F._transitionTo(lt,ki),F.runCount++;const Un=Do;Do=F,Ur={parent:Ur,zone:this};try{F.type==Pt&&F.data&&!F.data.isPeriodic&&(F.cancelFn=void 0);try{return this._zoneDelegate.invokeTask(this,F,ae,Et)}catch(Ue){if(this._zoneDelegate.handleError(this,Ue))throw Ue}}finally{F.state!==sr&&F.state!==et&&(F.type==ts||F.data&&F.data.isPeriodic?Xt&&F._transitionTo(ki,lt):(F.runCount=0,this._updateTaskCount(F,-1),Xt&&F._transitionTo(sr,lt,sr))),Ur=Ur.parent,Do=Un}}scheduleTask(F){if(F.zone&&F.zone!==this){let Et=this;for(;Et;){if(Et===F.zone)throw Error(`can not reschedule task to ${this.name} which is descendants of the original zone ${F.zone.name}`);Et=Et.parent}}F._transitionTo(Zr,sr);const ae=[];F._zoneDelegates=ae,F._zone=this;try{F=this._zoneDelegate.scheduleTask(this,F)}catch(Et){throw F._transitionTo(et,Zr,sr),this._zoneDelegate.handleError(this,Et),Et}return F._zoneDelegates===ae&&this._updateTaskCount(F,1),F.state==Zr&&F._transitionTo(ki,Zr),F}scheduleMicroTask(F,ae,Et,Xt){return this.scheduleTask(new ft(vi,F,ae,Et,Xt,void 0))}scheduleMacroTask(F,ae,Et,Xt,Un){return this.scheduleTask(new ft(Pt,F,ae,Et,Xt,Un))}scheduleEventTask(F,ae,Et,Xt,Un){return this.scheduleTask(new ft(ts,F,ae,Et,Xt,Un))}cancelTask(F){if(F.zone!=this)throw new Error("A task can only be cancelled in the zone of creation! (Creation: "+(F.zone||_n).name+"; Execution: "+this.name+")");if(F.state===ki||F.state===lt){F._transitionTo(dr,ki,lt);try{this._zoneDelegate.cancelTask(this,F)}catch(ae){throw F._transitionTo(et,dr),this._zoneDelegate.handleError(this,ae),ae}return this._updateTaskCount(F,-1),F._transitionTo(sr,dr),F.runCount=0,F}}_updateTaskCount(F,ae){const Et=F._zoneDelegates;-1==ae&&(F._zoneDelegates=null);for(let Xt=0;XtPi.hasTask(F,ae),onScheduleTask:(Pi,ht,F,ae)=>Pi.scheduleTask(F,ae),onInvokeTask:(Pi,ht,F,ae,Et,Xt)=>Pi.invokeTask(F,ae,Et,Xt),onCancelTask:(Pi,ht,F,ae)=>Pi.cancelTask(F,ae)};class Lt{constructor(ht,F,ae){this._taskCounts={microTask:0,macroTask:0,eventTask:0},this.zone=ht,this._parentDelegate=F,this._forkZS=ae&&(ae&&ae.onFork?ae:F._forkZS),this._forkDlgt=ae&&(ae.onFork?F:F._forkDlgt),this._forkCurrZone=ae&&(ae.onFork?this.zone:F._forkCurrZone),this._interceptZS=ae&&(ae.onIntercept?ae:F._interceptZS),this._interceptDlgt=ae&&(ae.onIntercept?F:F._interceptDlgt),this._interceptCurrZone=ae&&(ae.onIntercept?this.zone:F._interceptCurrZone),this._invokeZS=ae&&(ae.onInvoke?ae:F._invokeZS),this._invokeDlgt=ae&&(ae.onInvoke?F:F._invokeDlgt),this._invokeCurrZone=ae&&(ae.onInvoke?this.zone:F._invokeCurrZone),this._handleErrorZS=ae&&(ae.onHandleError?ae:F._handleErrorZS),this._handleErrorDlgt=ae&&(ae.onHandleError?F:F._handleErrorDlgt),this._handleErrorCurrZone=ae&&(ae.onHandleError?this.zone:F._handleErrorCurrZone),this._scheduleTaskZS=ae&&(ae.onScheduleTask?ae:F._scheduleTaskZS),this._scheduleTaskDlgt=ae&&(ae.onScheduleTask?F:F._scheduleTaskDlgt),this._scheduleTaskCurrZone=ae&&(ae.onScheduleTask?this.zone:F._scheduleTaskCurrZone),this._invokeTaskZS=ae&&(ae.onInvokeTask?ae:F._invokeTaskZS),this._invokeTaskDlgt=ae&&(ae.onInvokeTask?F:F._invokeTaskDlgt),this._invokeTaskCurrZone=ae&&(ae.onInvokeTask?this.zone:F._invokeTaskCurrZone),this._cancelTaskZS=ae&&(ae.onCancelTask?ae:F._cancelTaskZS),this._cancelTaskDlgt=ae&&(ae.onCancelTask?F:F._cancelTaskDlgt),this._cancelTaskCurrZone=ae&&(ae.onCancelTask?this.zone:F._cancelTaskCurrZone),this._hasTaskZS=null,this._hasTaskDlgt=null,this._hasTaskDlgtOwner=null,this._hasTaskCurrZone=null;const Et=ae&&ae.onHasTask;(Et||F&&F._hasTaskZS)&&(this._hasTaskZS=Et?ae:At,this._hasTaskDlgt=F,this._hasTaskDlgtOwner=this,this._hasTaskCurrZone=ht,ae.onScheduleTask||(this._scheduleTaskZS=At,this._scheduleTaskDlgt=F,this._scheduleTaskCurrZone=this.zone),ae.onInvokeTask||(this._invokeTaskZS=At,this._invokeTaskDlgt=F,this._invokeTaskCurrZone=this.zone),ae.onCancelTask||(this._cancelTaskZS=At,this._cancelTaskDlgt=F,this._cancelTaskCurrZone=this.zone))}fork(ht,F){return this._forkZS?this._forkZS.onFork(this._forkDlgt,this.zone,ht,F):new tt(ht,F)}intercept(ht,F,ae){return this._interceptZS?this._interceptZS.onIntercept(this._interceptDlgt,this._interceptCurrZone,ht,F,ae):F}invoke(ht,F,ae,Et,Xt){return this._invokeZS?this._invokeZS.onInvoke(this._invokeDlgt,this._invokeCurrZone,ht,F,ae,Et,Xt):F.apply(ae,Et)}handleError(ht,F){return!this._handleErrorZS||this._handleErrorZS.onHandleError(this._handleErrorDlgt,this._handleErrorCurrZone,ht,F)}scheduleTask(ht,F){let ae=F;if(this._scheduleTaskZS)this._hasTaskZS&&ae._zoneDelegates.push(this._hasTaskDlgtOwner),ae=this._scheduleTaskZS.onScheduleTask(this._scheduleTaskDlgt,this._scheduleTaskCurrZone,ht,F),ae||(ae=F);else if(F.scheduleFn)F.scheduleFn(F);else{if(F.type!=vi)throw new Error("Task is missing scheduleFn.");Wt(F)}return ae}invokeTask(ht,F,ae,Et){return this._invokeTaskZS?this._invokeTaskZS.onInvokeTask(this._invokeTaskDlgt,this._invokeTaskCurrZone,ht,F,ae,Et):F.callback.apply(ae,Et)}cancelTask(ht,F){let ae;if(this._cancelTaskZS)ae=this._cancelTaskZS.onCancelTask(this._cancelTaskDlgt,this._cancelTaskCurrZone,ht,F);else{if(!F.cancelFn)throw Error("Task is not cancelable");ae=F.cancelFn(F)}return ae}hasTask(ht,F){try{this._hasTaskZS&&this._hasTaskZS.onHasTask(this._hasTaskDlgt,this._hasTaskCurrZone,ht,F)}catch(ae){this.handleError(ht,ae)}}_updateTaskCount(ht,F){const ae=this._taskCounts,Et=ae[ht],Xt=ae[ht]=Et+F;if(Xt<0)throw new Error("More tasks executed then were scheduled.");0!=Et&&0!=Xt||this.hasTask(this.zone,{microTask:ae.microTask>0,macroTask:ae.macroTask>0,eventTask:ae.eventTask>0,change:ht})}}class ft{constructor(ht,F,ae,Et,Xt,Un){if(this._zone=null,this.runCount=0,this._zoneDelegates=null,this._state="notScheduled",this.type=ht,this.source=F,this.data=Et,this.scheduleFn=Xt,this.cancelFn=Un,!ae)throw new Error("callback is not defined");this.callback=ae;const Ue=this;this.invoke=ht===ts&&Et&&Et.useG?ft.invokeTask:function(){return ft.invokeTask.call(Z,Ue,this,arguments)}}static invokeTask(ht,F,ae){ht||(ht=this),Ls++;try{return ht.runCount++,ht.zone.runTask(ht,F,ae)}finally{1==Ls&&ct(),Ls--}}get zone(){return this._zone}get state(){return this._state}cancelScheduleRequest(){this._transitionTo(sr,Zr)}_transitionTo(ht,F,ae){if(this._state!==F&&this._state!==ae)throw new Error(`${this.type} '${this.source}': can not transition to '${ht}', expecting state '${F}'${ae?" or '"+ae+"'":""}, was '${this._state}'.`);this._state=ht,ht==sr&&(this._zoneDelegates=null)}toString(){return this.data&&typeof this.data.handleId<"u"?this.data.handleId.toString():Object.prototype.toString.call(this)}toJSON(){return{type:this.type,state:this.state,source:this.source,zone:this.zone.name,runCount:this.runCount}}}const Ei=ke("setTimeout"),ti=ke("Promise"),gi=ke("then");let es,cr=[],Oi=!1;function kr(Pi){if(es||Z[ti]&&(es=Z[ti].resolve(0)),es){let ht=es[gi];ht||(ht=es.then),ht.call(es,Pi)}else Z[Ei](Pi,0)}function Wt(Pi){0===Ls&&0===cr.length&&kr(ct),Pi&&cr.push(Pi)}function ct(){if(!Oi){for(Oi=!0;cr.length;){const Pi=cr;cr=[];for(let ht=0;htUr,onUnhandledError:jr,microtaskDrainDone:jr,scheduleMicroTask:Wt,showUncaughtError:()=>!tt[ke("ignoreConsoleErrorUncaughtError")],patchEventTarget:()=>[],patchOnProperties:jr,patchMethod:()=>jr,bindArguments:()=>[],patchThen:()=>jr,patchMacroTask:()=>jr,patchEventPrototype:()=>jr,isIEOrEdge:()=>!1,getGlobalObjects:()=>{},ObjectDefineProperty:()=>jr,ObjectGetOwnPropertyDescriptor:()=>{},ObjectCreate:()=>{},ArraySlice:()=>[],patchClass:()=>jr,wrapWithCurrentZone:()=>jr,filterProperties:()=>[],attachOriginToPatched:()=>jr,_redefineProperty:()=>jr,patchCallbacks:()=>jr,nativeScheduleMicroTask:kr};let Ur={parent:null,zone:new tt(null,null)},Do=null,Ls=0;function jr(){}fe("Zone","Zone"),Z.Zone=tt}(globalThis);const _l=Object.getOwnPropertyDescriptor,Vd=Object.defineProperty,Wd=Object.getPrototypeOf,Yd=Object.create,Ib=Array.prototype.slice,vm="addEventListener",$r="removeEventListener",Ul=Zone.__symbol__(vm),Uh=Zone.__symbol__($r),Ts="true",Wi="false",Qd=Zone.__symbol__("");function cf(Z,se){return Zone.current.wrap(Z,se)}function mm(Z,se,ye,fe,be){return Zone.current.scheduleMacroTask(Z,se,ye,fe,be)}const Ji=Zone.__symbol__,jh=typeof window<"u",Vh=jh?window:void 0,gn=jh&&Vh||globalThis,ym="removeAttribute";function Gd(Z,se){for(let ye=Z.length-1;ye>=0;ye--)"function"==typeof Z[ye]&&(Z[ye]=cf(Z[ye],se+"_"+ye));return Z}function df(Z){return!Z||!1!==Z.writable&&!("function"==typeof Z.get&&typeof Z.set>"u")}const uf=typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope,Wh=!("nw"in gn)&&typeof gn.process<"u"&&"[object process]"==={}.toString.call(gn.process),Xd=!Wh&&!uf&&!(!jh||!Vh.HTMLElement),pf=typeof gn.process<"u"&&"[object process]"==={}.toString.call(gn.process)&&!uf&&!(!jh||!Vh.HTMLElement),jl={},Yh=function(Z){if(!(Z=Z||gn.event))return;let se=jl[Z.type];se||(se=jl[Z.type]=Ji("ON_PROPERTY"+Z.type));const ye=this||Z.target||gn,fe=ye[se];let be;return Xd&&ye===Vh&&"error"===Z.type?(be=fe&&fe.call(this,Z.message,Z.filename,Z.lineno,Z.colno,Z.error),!0===be&&Z.preventDefault()):(be=fe&&fe.apply(this,arguments),null!=be&&!be&&Z.preventDefault()),be};function Vl(Z,se,ye){let fe=_l(Z,se);if(!fe&&ye&&_l(ye,se)&&(fe={enumerable:!0,configurable:!0}),!fe||!fe.configurable)return;const be=Ji("on"+se+"patched");if(Z.hasOwnProperty(be)&&Z[be])return;delete fe.writable,delete fe.value;const ke=fe.get,at=fe.set,tt=se.slice(2);let At=jl[tt];At||(At=jl[tt]=Ji("ON_PROPERTY"+tt)),fe.set=function(Lt){let ft=this;!ft&&Z===gn&&(ft=gn),ft&&("function"==typeof ft[At]&&ft.removeEventListener(tt,Yh),at&&at.call(ft,null),ft[At]=Lt,"function"==typeof Lt&&ft.addEventListener(tt,Yh,!1))},fe.get=function(){let Lt=this;if(!Lt&&Z===gn&&(Lt=gn),!Lt)return null;const ft=Lt[At];if(ft)return ft;if(ke){let Ei=ke.call(this);if(Ei)return fe.set.call(this,Ei),"function"==typeof Lt[ym]&&Lt.removeAttribute(se),Ei}return null},Vd(Z,se,fe),Z[be]=!0}function ff(Z,se,ye){if(se)for(let fe=0;fefunction(at,tt){const At=ye(at,tt);return At.cbIdx>=0&&"function"==typeof tt[At.cbIdx]?mm(At.name,tt[At.cbIdx],At,be):ke.apply(at,tt)})}function Sa(Z,se){Z[Ji("OriginalDelegate")]=se}let Mb=!1,$d=!1;function wb(){if(Mb)return $d;Mb=!0;try{const Z=Vh.navigator.userAgent;(-1!==Z.indexOf("MSIE ")||-1!==Z.indexOf("Trident/")||-1!==Z.indexOf("Edge/"))&&($d=!0)}catch{}return $d}Zone.__load_patch("ZoneAwarePromise",(Z,se,ye)=>{const fe=Object.getOwnPropertyDescriptor,be=Object.defineProperty,at=ye.symbol,tt=[],At=!1!==Z[at("DISABLE_WRAPPING_UNCAUGHT_PROMISE_REJECTION")],Lt=at("Promise"),ft=at("then"),Ei="__creationTrace__";ye.onUnhandledError=Ue=>{if(ye.showUncaughtError()){const He=Ue&&Ue.rejection;He?console.error("Unhandled Promise rejection:",He instanceof Error?He.message:He,"; Zone:",Ue.zone.name,"; Task:",Ue.task&&Ue.task.source,"; Value:",He,He instanceof Error?He.stack:void 0):console.error(Ue)}},ye.microtaskDrainDone=()=>{for(;tt.length;){const Ue=tt.shift();try{Ue.zone.runGuarded(()=>{throw Ue.throwOriginal?Ue.rejection:Ue})}catch(He){gi(He)}}};const ti=at("unhandledPromiseRejectionHandler");function gi(Ue){ye.onUnhandledError(Ue);try{const He=se[ti];"function"==typeof He&&He.call(this,Ue)}catch{}}function cr(Ue){return Ue&&Ue.then}function Oi(Ue){return Ue}function es(Ue){return F.reject(Ue)}const kr=at("state"),Wt=at("value"),ct=at("finally"),_n=at("parentPromiseValue"),sr=at("parentPromiseState"),Zr="Promise.then",ki=null,lt=!0,dr=!1,et=0;function vi(Ue,He){return ge=>{try{cn(Ue,He,ge)}catch(We){cn(Ue,!1,We)}}}const Pt=function(){let Ue=!1;return function(ge){return function(){Ue||(Ue=!0,ge.apply(null,arguments))}}},ts="Promise resolved with itself",_o=at("currentTaskTrace");function cn(Ue,He,ge){const We=Pt();if(Ue===ge)throw new TypeError(ts);if(Ue[kr]===ki){let wt=null;try{("object"==typeof ge||"function"==typeof ge)&&(wt=ge&&ge.then)}catch(Xe){return We(()=>{cn(Ue,!1,Xe)})(),Ue}if(He!==dr&&ge instanceof F&&ge.hasOwnProperty(kr)&&ge.hasOwnProperty(Wt)&&ge[kr]!==ki)Do(ge),cn(Ue,ge[kr],ge[Wt]);else if(He!==dr&&"function"==typeof wt)try{wt.call(ge,We(vi(Ue,He)),We(vi(Ue,!1)))}catch(Xe){We(()=>{cn(Ue,!1,Xe)})()}else{Ue[kr]=He;const Xe=Ue[Wt];if(Ue[Wt]=ge,Ue[ct]===ct&&He===lt&&(Ue[kr]=Ue[sr],Ue[Wt]=Ue[_n]),He===dr&&ge instanceof Error){const mt=se.currentTask&&se.currentTask.data&&se.currentTask.data[Ei];mt&&be(ge,_o,{configurable:!0,enumerable:!1,writable:!0,value:mt})}for(let mt=0;mt{try{const dt=Ue[Wt],qt=!!ge&&ct===ge[ct];qt&&(ge[_n]=dt,ge[sr]=Xe);const ai=He.run(mt,void 0,qt&&mt!==es&&mt!==Oi?[]:[dt]);cn(ge,!0,ai)}catch(dt){cn(ge,!1,dt)}},ge)}const Pi=function(){},ht=Z.AggregateError;class F{static toString(){return"function ZoneAwarePromise() { [native code] }"}static resolve(He){return He instanceof F?He:cn(new this(null),lt,He)}static reject(He){return cn(new this(null),dr,He)}static withResolvers(){const He={};return He.promise=new F((ge,We)=>{He.resolve=ge,He.reject=We}),He}static any(He){if(!He||"function"!=typeof He[Symbol.iterator])return Promise.reject(new ht([],"All promises were rejected"));const ge=[];let We=0;try{for(let mt of He)We++,ge.push(F.resolve(mt))}catch{return Promise.reject(new ht([],"All promises were rejected"))}if(0===We)return Promise.reject(new ht([],"All promises were rejected"));let wt=!1;const Xe=[];return new F((mt,dt)=>{for(let qt=0;qt{wt||(wt=!0,mt(ai))},ai=>{Xe.push(ai),We--,0===We&&(wt=!0,dt(new ht(Xe,"All promises were rejected")))})})}static race(He){let ge,We,wt=new this((dt,qt)=>{ge=dt,We=qt});function Xe(dt){ge(dt)}function mt(dt){We(dt)}for(let dt of He)cr(dt)||(dt=this.resolve(dt)),dt.then(Xe,mt);return wt}static all(He){return F.allWithCallback(He)}static allSettled(He){return(this&&this.prototype instanceof F?this:F).allWithCallback(He,{thenCallback:We=>({status:"fulfilled",value:We}),errorCallback:We=>({status:"rejected",reason:We})})}static allWithCallback(He,ge){let We,wt,Xe=new this((ai,ur)=>{We=ai,wt=ur}),mt=2,dt=0;const qt=[];for(let ai of He){cr(ai)||(ai=this.resolve(ai));const ur=dt;try{ai.then(ir=>{qt[ur]=ge?ge.thenCallback(ir):ir,mt--,0===mt&&We(qt)},ir=>{ge?(qt[ur]=ge.errorCallback(ir),mt--,0===mt&&We(qt)):wt(ir)})}catch(ir){wt(ir)}mt++,dt++}return mt-=2,0===mt&&We(qt),Xe}constructor(He){const ge=this;if(!(ge instanceof F))throw new Error("Must be an instanceof Promise.");ge[kr]=ki,ge[Wt]=[];try{const We=Pt();He&&He(We(vi(ge,lt)),We(vi(ge,dr)))}catch(We){cn(ge,!1,We)}}get[Symbol.toStringTag](){return"Promise"}get[Symbol.species](){return F}then(He,ge){let We=this.constructor?.[Symbol.species];(!We||"function"!=typeof We)&&(We=this.constructor||F);const wt=new We(Pi),Xe=se.current;return this[kr]==ki?this[Wt].push(Xe,wt,He,ge):Ls(this,Xe,wt,He,ge),wt}catch(He){return this.then(null,He)}finally(He){let ge=this.constructor?.[Symbol.species];(!ge||"function"!=typeof ge)&&(ge=F);const We=new ge(Pi);We[ct]=ct;const wt=se.current;return this[kr]==ki?this[Wt].push(wt,We,He,He):Ls(this,wt,We,He,He),We}}F.resolve=F.resolve,F.reject=F.reject,F.race=F.race,F.all=F.all;const ae=Z[Lt]=Z.Promise;Z.Promise=F;const Et=at("thenPatched");function Xt(Ue){const He=Ue.prototype,ge=fe(He,"then");if(ge&&(!1===ge.writable||!ge.configurable))return;const We=He.then;He[ft]=We,Ue.prototype.then=function(wt,Xe){return new F((dt,qt)=>{We.call(this,dt,qt)}).then(wt,Xe)},Ue[Et]=!0}return ye.patchThen=Xt,ae&&(Xt(ae),Ka(Z,"fetch",Ue=>function Un(Ue){return function(He,ge){let We=Ue.apply(He,ge);if(We instanceof F)return We;let wt=We.constructor;return wt[Et]||Xt(wt),We}}(Ue))),Promise[se.__symbol__("uncaughtPromiseErrors")]=tt,F}),Zone.__load_patch("toString",Z=>{const se=Function.prototype.toString,ye=Ji("OriginalDelegate"),fe=Ji("Promise"),be=Ji("Error"),ke=function(){if("function"==typeof this){const Lt=this[ye];if(Lt)return"function"==typeof Lt?se.call(Lt):Object.prototype.toString.call(Lt);if(this===Promise){const ft=Z[fe];if(ft)return se.call(ft)}if(this===Error){const ft=Z[be];if(ft)return se.call(ft)}}return se.call(this)};ke[ye]=se,Function.prototype.toString=ke;const at=Object.prototype.toString;Object.prototype.toString=function(){return"function"==typeof Promise&&this instanceof Promise?"[object Promise]":at.call(this)}});let el=!1;if(typeof window<"u")try{const Z=Object.defineProperty({},"passive",{get:function(){el=!0}});window.addEventListener("test",Z,Z),window.removeEventListener("test",Z,Z)}catch{el=!1}const zT={useG:!0},Co={},Cb={},bm=new RegExp("^"+Qd+"(\\w+)(true|false)$"),Eb=Ji("propagationStopped");function Mm(Z,se){const ye=(se?se(Z):Z)+Wi,fe=(se?se(Z):Z)+Ts,be=Qd+ye,ke=Qd+fe;Co[Z]={},Co[Z][Wi]=be,Co[Z][Ts]=ke}function Db(Z,se,ye,fe){const be=fe&&fe.add||vm,ke=fe&&fe.rm||$r,at=fe&&fe.listeners||"eventListeners",tt=fe&&fe.rmAll||"removeAllListeners",At=Ji(be),Lt="."+be+":",ft="prependListener",Ei="."+ft+":",ti=function(Wt,ct,_n){if(Wt.isRemoved)return;const sr=Wt.callback;let Zr;"object"==typeof sr&&sr.handleEvent&&(Wt.callback=lt=>sr.handleEvent(lt),Wt.originalDelegate=sr);try{Wt.invoke(Wt,ct,[_n])}catch(lt){Zr=lt}const ki=Wt.options;return ki&&"object"==typeof ki&&ki.once&&ct[ke].call(ct,_n.type,Wt.originalDelegate?Wt.originalDelegate:Wt.callback,ki),Zr};function gi(Wt,ct,_n){if(!(ct=ct||Z.event))return;const sr=Wt||ct.target||Z,Zr=sr[Co[ct.type][_n?Ts:Wi]];if(Zr){const ki=[];if(1===Zr.length){const lt=ti(Zr[0],sr,ct);lt&&ki.push(lt)}else{const lt=Zr.slice();for(let dr=0;dr{throw dr})}}}const cr=function(Wt){return gi(this,Wt,!1)},Oi=function(Wt){return gi(this,Wt,!0)};function es(Wt,ct){if(!Wt)return!1;let _n=!0;ct&&void 0!==ct.useG&&(_n=ct.useG);const sr=ct&&ct.vh;let Zr=!0;ct&&void 0!==ct.chkDup&&(Zr=ct.chkDup);let ki=!1;ct&&void 0!==ct.rt&&(ki=ct.rt);let lt=Wt;for(;lt&&!lt.hasOwnProperty(be);)lt=Wd(lt);if(!lt&&Wt[be]&&(lt=Wt),!lt||lt[At])return!1;const dr=ct&&ct.eventNameToString,et={},vi=lt[At]=lt[be],Pt=lt[Ji(ke)]=lt[ke],ts=lt[Ji(at)]=lt[at],_o=lt[Ji(tt)]=lt[tt];let cn;ct&&ct.prepend&&(cn=lt[Ji(ct.prepend)]=lt[ct.prepend]);const F=_n?function(ge){if(!et.isExisting)return vi.call(et.target,et.eventName,et.capture?Oi:cr,et.options)}:function(ge){return vi.call(et.target,et.eventName,ge.invoke,et.options)},ae=_n?function(ge){if(!ge.isRemoved){const We=Co[ge.eventName];let wt;We&&(wt=We[ge.capture?Ts:Wi]);const Xe=wt&&ge.target[wt];if(Xe)for(let mt=0;mt{Vo.zone.cancelTask(Vo)},{once:!0})),et.target=null,Uc&&(Uc.taskData=null),Jd&&(Dn.once=!0),!el&&"boolean"==typeof Vo.options||(Vo.options=Dn),Vo.target=qt,Vo.capture=Gl,Vo.eventName=ai,ir&&(Vo.originalDelegate=ur),dt?jo.unshift(Vo):jo.push(Vo),mt?qt:void 0}};return lt[be]=He(vi,Lt,F,ae,ki),cn&&(lt[ft]=He(cn,Ei,function(ge){return cn.call(et.target,et.eventName,ge.invoke,et.options)},ae,ki,!0)),lt[ke]=function(){const ge=this||Z;let We=arguments[0];ct&&ct.transferEventName&&(We=ct.transferEventName(We));const wt=arguments[2],Xe=!!wt&&("boolean"==typeof wt||wt.capture),mt=arguments[1];if(!mt)return Pt.apply(this,arguments);if(sr&&!sr(Pt,mt,ge,arguments))return;const dt=Co[We];let qt;dt&&(qt=dt[Xe?Ts:Wi]);const ai=qt&&ge[qt];if(ai)for(let ur=0;urfunction(be,ke){be[Eb]=!0,fe&&fe.apply(be,ke)})}function Tb(Z,se,ye,fe,be){const ke=Zone.__symbol__(fe);if(se[ke])return;const at=se[ke]=se[fe];se[fe]=function(tt,At,Lt){return At&&At.prototype&&be.forEach(function(ft){const Ei=`${ye}.${fe}::`+ft,ti=At.prototype;try{if(ti.hasOwnProperty(ft)){const gi=Z.ObjectGetOwnPropertyDescriptor(ti,ft);gi&&gi.value?(gi.value=Z.wrapWithCurrentZone(gi.value,Ei),Z._redefineProperty(At.prototype,ft,gi)):ti[ft]&&(ti[ft]=Z.wrapWithCurrentZone(ti[ft],Ei))}else ti[ft]&&(ti[ft]=Z.wrapWithCurrentZone(ti[ft],Ei))}catch{}}),at.call(se,tt,At,Lt)},Z.attachOriginToPatched(se[fe],at)}function Ab(Z,se,ye){if(!ye||0===ye.length)return se;const fe=ye.filter(ke=>ke.target===Z);if(!fe||0===fe.length)return se;const be=fe[0].ignoreProperties;return se.filter(ke=>-1===be.indexOf(ke))}function Eo(Z,se,ye,fe){Z&&ff(Z,Ab(Z,se,ye),fe)}function Zd(Z){return Object.getOwnPropertyNames(Z).filter(se=>se.startsWith("on")&&se.length>2).map(se=>se.substring(2))}Zone.__load_patch("util",(Z,se,ye)=>{const fe=Zd(Z);ye.patchOnProperties=ff,ye.patchMethod=Ka,ye.bindArguments=Gd,ye.patchMacroTask=bb;const be=se.__symbol__("BLACK_LISTED_EVENTS"),ke=se.__symbol__("UNPATCHED_EVENTS");Z[ke]&&(Z[be]=Z[ke]),Z[be]&&(se[be]=se[ke]=Z[be]),ye.patchEventPrototype=wm,ye.patchEventTarget=Db,ye.isIEOrEdge=wb,ye.ObjectDefineProperty=Vd,ye.ObjectGetOwnPropertyDescriptor=_l,ye.ObjectCreate=Yd,ye.ArraySlice=Ib,ye.patchClass=qd,ye.wrapWithCurrentZone=cf,ye.filterProperties=Ab,ye.attachOriginToPatched=Sa,ye._redefineProperty=Object.defineProperty,ye.patchCallbacks=Tb,ye.getGlobalObjects=()=>({globalSources:Cb,zoneSymbolEventNames:Co,eventNames:fe,isBrowser:Xd,isMix:pf,isNode:Wh,TRUE_STR:Ts,FALSE_STR:Wi,ZONE_SYMBOL_PREFIX:Qd,ADD_EVENT_LISTENER_STR:vm,REMOVE_EVENT_LISTENER_STR:$r})});const As=Ji("zoneTask");function Wl(Z,se,ye,fe){let be=null,ke=null;ye+=fe;const at={};function tt(Lt){const ft=Lt.data;return ft.args[0]=function(){return Lt.invoke.apply(this,arguments)},ft.handleId=be.apply(Z,ft.args),Lt}function At(Lt){return ke.call(Z,Lt.data.handleId)}be=Ka(Z,se+=fe,Lt=>function(ft,Ei){if("function"==typeof Ei[0]){const ti={isPeriodic:"Interval"===fe,delay:"Timeout"===fe||"Interval"===fe?Ei[1]||0:void 0,args:Ei},gi=Ei[0];Ei[0]=function(){try{return gi.apply(this,arguments)}finally{ti.isPeriodic||("number"==typeof ti.handleId?delete at[ti.handleId]:ti.handleId&&(ti.handleId[As]=null))}};const cr=mm(se,Ei[0],ti,tt,At);if(!cr)return cr;const Oi=cr.data.handleId;return"number"==typeof Oi?at[Oi]=cr:Oi&&(Oi[As]=cr),Oi&&Oi.ref&&Oi.unref&&"function"==typeof Oi.ref&&"function"==typeof Oi.unref&&(cr.ref=Oi.ref.bind(Oi),cr.unref=Oi.unref.bind(Oi)),"number"==typeof Oi||Oi?Oi:cr}return Lt.apply(Z,Ei)}),ke=Ka(Z,ye,Lt=>function(ft,Ei){const ti=Ei[0];let gi;"number"==typeof ti?gi=at[ti]:(gi=ti&&ti[As],gi||(gi=ti)),gi&&"string"==typeof gi.type?"notScheduled"!==gi.state&&(gi.cancelFn&&gi.data.isPeriodic||0===gi.runCount)&&("number"==typeof ti?delete at[ti]:ti&&(ti[As]=null),gi.zone.cancelTask(gi)):Lt.apply(Z,Ei)})}Zone.__load_patch("legacy",Z=>{const se=Z[Zone.__symbol__("legacyPatch")];se&&se()}),Zone.__load_patch("timers",Z=>{const ye="clear";Wl(Z,"set",ye,"Timeout"),Wl(Z,"set",ye,"Interval"),Wl(Z,"set",ye,"Immediate")}),Zone.__load_patch("requestAnimationFrame",Z=>{Wl(Z,"request","cancel","AnimationFrame"),Wl(Z,"mozRequest","mozCancel","AnimationFrame"),Wl(Z,"webkitRequest","webkitCancel","AnimationFrame")}),Zone.__load_patch("blocking",(Z,se)=>{const ye=["alert","prompt","confirm"];for(let fe=0;fefunction(At,Lt){return se.current.run(ke,Z,Lt,tt)})}),Zone.__load_patch("EventTarget",(Z,se,ye)=>{(function Yl(Z,se){se.patchEventPrototype(Z,se)})(Z,ye),function Em(Z,se){if(Zone[se.symbol("patchEventTarget")])return;const{eventNames:ye,zoneSymbolEventNames:fe,TRUE_STR:be,FALSE_STR:ke,ZONE_SYMBOL_PREFIX:at}=se.getGlobalObjects();for(let At=0;At{qd("MutationObserver"),qd("WebKitMutationObserver")}),Zone.__load_patch("IntersectionObserver",(Z,se,ye)=>{qd("IntersectionObserver")}),Zone.__load_patch("FileReader",(Z,se,ye)=>{qd("FileReader")}),Zone.__load_patch("on_property",(Z,se,ye)=>{!function gf(Z,se){if(Wh&&!pf||Zone[Z.symbol("patchEvents")])return;const ye=se.__Zone_ignore_on_properties;let fe=[];if(Xd){const be=window;fe=fe.concat(["Document","SVGElement","Element","HTMLElement","HTMLBodyElement","HTMLMediaElement","HTMLFrameSetElement","HTMLFrameElement","HTMLIFrameElement","HTMLMarqueeElement","Worker"]);const ke=function Im(){try{const Z=Vh.navigator.userAgent;if(-1!==Z.indexOf("MSIE ")||-1!==Z.indexOf("Trident/"))return!0}catch{}return!1}()?[{target:be,ignoreProperties:["error"]}]:[];Eo(be,Zd(be),ye&&ye.concat(ke),Wd(be))}fe=fe.concat(["XMLHttpRequest","XMLHttpRequestEventTarget","IDBIndex","IDBRequest","IDBOpenDBRequest","IDBDatabase","IDBTransaction","IDBCursor","WebSocket"]);for(let be=0;be{!function Cm(Z,se){const{isBrowser:ye,isMix:fe}=se.getGlobalObjects();(ye||fe)&&Z.customElements&&"customElements"in Z&&se.patchCallbacks(se,Z.customElements,"customElements","define",["connectedCallback","disconnectedCallback","adoptedCallback","attributeChangedCallback"])}(Z,ye)}),Zone.__load_patch("XHR",(Z,se)=>{!function At(Lt){const ft=Lt.XMLHttpRequest;if(!ft)return;const Ei=ft.prototype;let gi=Ei[Ul],cr=Ei[Uh];if(!gi){const et=Lt.XMLHttpRequestEventTarget;if(et){const vi=et.prototype;gi=vi[Ul],cr=vi[Uh]}}const Oi="readystatechange",es="scheduled";function kr(et){const vi=et.data,Pt=vi.target;Pt[ke]=!1,Pt[tt]=!1;const ts=Pt[be];gi||(gi=Pt[Ul],cr=Pt[Uh]),ts&&cr.call(Pt,Oi,ts);const _o=Pt[be]=()=>{if(Pt.readyState===Pt.DONE)if(!vi.aborted&&Pt[ke]&&et.state===es){const Ur=Pt[se.__symbol__("loadfalse")];if(0!==Pt.status&&Ur&&Ur.length>0){const Do=et.invoke;et.invoke=function(){const Ls=Pt[se.__symbol__("loadfalse")];for(let jr=0;jrfunction(et,vi){return et[fe]=0==vi[2],et[at]=vi[1],_n.apply(et,vi)}),Zr=Ji("fetchTaskAborting"),ki=Ji("fetchTaskScheduling"),lt=Ka(Ei,"send",()=>function(et,vi){if(!0===se.current[ki]||et[fe])return lt.apply(et,vi);{const Pt={target:et,url:et[at],isPeriodic:!1,args:vi,aborted:!1},ts=mm("XMLHttpRequest.send",Wt,Pt,kr,ct);et&&!0===et[tt]&&!Pt.aborted&&ts.state===es&&ts.invoke()}}),dr=Ka(Ei,"abort",()=>function(et,vi){const Pt=function ti(et){return et[ye]}(et);if(Pt&&"string"==typeof Pt.type){if(null==Pt.cancelFn||Pt.data&&Pt.data.aborted)return;Pt.zone.cancelTask(Pt)}else if(!0===se.current[Zr])return dr.apply(et,vi)})}(Z);const ye=Ji("xhrTask"),fe=Ji("xhrSync"),be=Ji("xhrListener"),ke=Ji("xhrScheduled"),at=Ji("xhrURL"),tt=Ji("xhrErrorBeforeScheduled")}),Zone.__load_patch("geolocation",Z=>{Z.navigator&&Z.navigator.geolocation&&function Sm(Z,se){const ye=Z.constructor.name;for(let fe=0;fe{const At=function(){return tt.apply(this,Gd(arguments,ye+"."+be))};return Sa(At,tt),At})(ke)}}}(Z.navigator.geolocation,["getCurrentPosition","watchPosition"])}),Zone.__load_patch("PromiseRejectionEvent",(Z,se)=>{function ye(fe){return function(be){xb(Z,fe).forEach(at=>{const tt=Z.PromiseRejectionEvent;if(tt){const At=new tt(fe,{promise:be.promise,reason:be.rejection});at.invoke(At)}})}}Z.PromiseRejectionEvent&&(se[Ji("unhandledPromiseRejectionHandler")]=ye("unhandledrejection"),se[Ji("rejectionHandledHandler")]=ye("rejectionhandled"))}),Zone.__load_patch("queueMicrotask",(Z,se,ye)=>{!function vf(Z,se){se.patchMethod(Z,"queueMicrotask",ye=>function(fe,be){Zone.current.scheduleMicroTask("queueMicrotask",be[0])})}(Z,ye)})}},_l=>{_l(_l.s=51)}]); \ No newline at end of file diff --git a/ej2-angular/samples/diagram/layers/layers-cs5/index.html b/ej2-angular/samples/diagram/layers/layers-cs5/index.html index 265ebe8f29..9f557c8303 100644 --- a/ej2-angular/samples/diagram/layers/layers-cs5/index.html +++ b/ej2-angular/samples/diagram/layers/layers-cs5/index.html @@ -19,5 +19,5 @@
Loading....
- + \ No newline at end of file diff --git a/ej2-angular/samples/diagram/layers/layers-cs5/main.bcb24af3e7d3f91f.js b/ej2-angular/samples/diagram/layers/layers-cs5/main.bcb24af3e7d3f91f.js new file mode 100644 index 0000000000..0027be54b2 --- /dev/null +++ b/ej2-angular/samples/diagram/layers/layers-cs5/main.bcb24af3e7d3f91f.js @@ -0,0 +1 @@ +"use strict";(self.webpackChunksyncfusion_component=self.webpackChunksyncfusion_component||[]).push([[179],{51:(Wl,Ud,jd)=>{let $r=null,_h=1;const Ts=Symbol("SIGNAL");function Wi(n){const t=$r;return $r=n,t}function gn(n){if((!Wh(n)||n.dirty)&&(n.dirty||n.lastCleanEpoch!==_h)){if(!n.producerMustRecompute(n)&&!Vh(n))return n.dirty=!1,void(n.lastCleanEpoch=_h);n.producerRecomputeValue(n),n.dirty=!1,n.lastCleanEpoch=_h}}function Vh(n){Gl(n);for(let t=0;t0}function Gl(n){n.producerNode??=[],n.producerIndexOfThis??=[],n.producerLastReadVersion??=[]}let Xd=null;function Eo(n){return"function"==typeof n}function qd(n){const e=n(i=>{Error.call(i),i.stack=(new Error).stack});return e.prototype=Object.create(Error.prototype),e.prototype.constructor=e,e}const fp=qd(n=>function(e){n(this),this.message=e?`${e.length} errors occurred during unsubscription:\n${e.map((i,r)=>`${r+1}) ${i.toString()}`).join("\n ")}`:"",this.name="UnsubscriptionError",this.errors=e});function pp(n,t){if(n){const e=n.indexOf(t);0<=e&&n.splice(e,1)}}class As{constructor(t){this.initialTeardown=t,this.closed=!1,this._parentage=null,this._finalizers=null}unsubscribe(){let t;if(!this.closed){this.closed=!0;const{_parentage:e}=this;if(e)if(this._parentage=null,Array.isArray(e))for(const s of e)s.remove(this);else e.remove(this);const{initialTeardown:i}=this;if(Eo(i))try{i()}catch(s){t=s instanceof fp?s.errors:[s]}const{_finalizers:r}=this;if(r){this._finalizers=null;for(const s of r)try{Cm(s)}catch(o){t=t??[],o instanceof fp?t=[...t,...o.errors]:t.push(o)}}if(t)throw new fp(t)}}add(t){var e;if(t&&t!==this)if(this.closed)Cm(t);else{if(t instanceof As){if(t.closed||t._hasParent(this))return;t._addParent(this)}(this._finalizers=null!==(e=this._finalizers)&&void 0!==e?e:[]).push(t)}}_hasParent(t){const{_parentage:e}=this;return e===t||Array.isArray(e)&&e.includes(t)}_addParent(t){const{_parentage:e}=this;this._parentage=Array.isArray(e)?(e.push(t),e):e?[e,t]:t}_removeParent(t){const{_parentage:e}=this;e===t?this._parentage=null:Array.isArray(e)&&pp(e,t)}remove(t){const{_finalizers:e}=this;e&&pp(e,t),t instanceof As&&t._removeParent(this)}}As.EMPTY=(()=>{const n=new As;return n.closed=!0,n})();const Xl=As.EMPTY;function wm(n){return n instanceof As||n&&"closed"in n&&Eo(n.remove)&&Eo(n.add)&&Eo(n.unsubscribe)}function Cm(n){Eo(n)?n():n.unsubscribe()}const ql={onUnhandledError:null,onStoppedNotification:null,Promise:void 0,useDeprecatedSynchronousErrorHandling:!1,useDeprecatedNextContext:!1},Z={setTimeout(n,t,...e){const{delegate:i}=Z;return i?.setTimeout?i.setTimeout(n,t,...e):setTimeout(n,t,...e)},clearTimeout(n){const{delegate:t}=Z;return(t?.clearTimeout||clearTimeout)(n)},delegate:void 0};function ye(){}const pe=at("C",void 0,void 0);function at(n,t,e){return{kind:n,value:t,error:e}}let tt=null;function At(n){if(ql.useDeprecatedSynchronousErrorHandling){const t=!tt;if(t&&(tt={errorThrown:!1,error:null}),n(),t){const{errorThrown:e,error:i}=tt;if(tt=null,e)throw i}}else n()}class pt extends As{constructor(t){super(),this.isStopped=!1,t?(this.destination=t,wm(t)&&t.add(this)):this.destination=Wt}static create(t,e,i){return new cr(t,e,i)}next(t){this.isStopped?Pr(function ke(n){return at("N",n,void 0)}(t),this):this._next(t)}error(t){this.isStopped?Pr(function be(n){return at("E",void 0,n)}(t),this):(this.isStopped=!0,this._error(t))}complete(){this.isStopped?Pr(pe,this):(this.isStopped=!0,this._complete())}unsubscribe(){this.closed||(this.isStopped=!0,super.unsubscribe(),this.destination=null)}_next(t){this.destination.next(t)}_error(t){try{this.destination.error(t)}finally{this.unsubscribe()}}_complete(){try{this.destination.complete()}finally{this.unsubscribe()}}}const Di=Function.prototype.bind;function ni(n,t){return Di.call(n,t)}class mi{constructor(t){this.partialObserver=t}next(t){const{partialObserver:e}=this;if(e.next)try{e.next(t)}catch(i){ki(i)}}error(t){const{partialObserver:e}=this;if(e.error)try{e.error(t)}catch(i){ki(i)}else ki(t)}complete(){const{partialObserver:t}=this;if(t.complete)try{t.complete()}catch(e){ki(e)}}}class cr extends pt{constructor(t,e,i){let r;if(super(),Eo(t)||!t)r={next:t??void 0,error:e??void 0,complete:i??void 0};else{let s;this&&ql.useDeprecatedNextContext?(s=Object.create(t),s.unsubscribe=()=>this.unsubscribe(),r={next:t.next&&ni(t.next,s),error:t.error&&ni(t.error,s),complete:t.complete&&ni(t.complete,s)}):r=t}this.destination=new mi(r)}}function ki(n){ql.useDeprecatedSynchronousErrorHandling?function Lt(n){ql.useDeprecatedSynchronousErrorHandling&&tt&&(tt.errorThrown=!0,tt.error=n)}(n):function se(n){Z.setTimeout(()=>{const{onUnhandledError:t}=ql;if(!t)throw n;t(n)})}(n)}function Pr(n,t){const{onStoppedNotification:e}=ql;e&&Z.setTimeout(()=>e(n,t))}const Wt={closed:!0,next:ye,error:function is(n){throw n},complete:ye},ct="function"==typeof Symbol&&Symbol.observable||"@@observable";function jn(n){return n}let Pi=(()=>{class n{constructor(e){e&&(this._subscribe=e)}lift(e){const i=new n;return i.source=this,i.operator=e,i}subscribe(e,i,r){const s=function et(n){return n&&n instanceof pt||function dr(n){return n&&Eo(n.next)&&Eo(n.error)&&Eo(n.complete)}(n)&&wm(n)}(e)?e:new cr(e,i,r);return At(()=>{const{operator:o,source:a}=this;s.add(o?o.call(s,a):a?this._subscribe(s):this._trySubscribe(s))}),s}_trySubscribe(e){try{return this._subscribe(e)}catch(i){e.error(i)}}forEach(e,i){return new(i=lt(i))((r,s)=>{const o=new cr({next:a=>{try{e(a)}catch(l){s(l),o.unsubscribe()}},error:s,complete:r});this.subscribe(o)})}_subscribe(e){var i;return null===(i=this.source)||void 0===i?void 0:i.subscribe(e)}[ct](){return this}pipe(...e){return function Zr(n){return 0===n.length?jn:1===n.length?n[0]:function(e){return n.reduce((i,r)=>r(i),e)}}(e)(this)}toPromise(e){return new(e=lt(e))((i,r)=>{let s;this.subscribe(o=>s=o,o=>r(o),()=>i(s))})}}return n.create=t=>new n(t),n})();function lt(n){var t;return null!==(t=n??ql.Promise)&&void 0!==t?t:Promise}const yi=qd(n=>function(){n(this),this.name="ObjectUnsubscribedError",this.message="object unsubscribed"});let Pt=(()=>{class n extends Pi{constructor(){super(),this.closed=!1,this.currentObservers=null,this.observers=[],this.isStopped=!1,this.hasError=!1,this.thrownError=null}lift(e){const i=new rs(this,this);return i.operator=e,i}_throwIfClosed(){if(this.closed)throw new yi}next(e){At(()=>{if(this._throwIfClosed(),!this.isStopped){this.currentObservers||(this.currentObservers=Array.from(this.observers));for(const i of this.currentObservers)i.next(e)}})}error(e){At(()=>{if(this._throwIfClosed(),!this.isStopped){this.hasError=this.isStopped=!0,this.thrownError=e;const{observers:i}=this;for(;i.length;)i.shift().error(e)}})}complete(){At(()=>{if(this._throwIfClosed(),!this.isStopped){this.isStopped=!0;const{observers:e}=this;for(;e.length;)e.shift().complete()}})}unsubscribe(){this.isStopped=this.closed=!0,this.observers=this.currentObservers=null}get observed(){var e;return(null===(e=this.observers)||void 0===e?void 0:e.length)>0}_trySubscribe(e){return this._throwIfClosed(),super._trySubscribe(e)}_subscribe(e){return this._throwIfClosed(),this._checkFinalizedStatuses(e),this._innerSubscribe(e)}_innerSubscribe(e){const{hasError:i,isStopped:r,observers:s}=this;return i||r?Xl:(this.currentObservers=null,s.push(e),new As(()=>{this.currentObservers=null,pp(s,e)}))}_checkFinalizedStatuses(e){const{hasError:i,thrownError:r,isStopped:s}=this;i?e.error(r):s&&e.complete()}asObservable(){const e=new Pi;return e.source=this,e}}return n.create=(t,e)=>new rs(t,e),n})();class rs extends Pt{constructor(t,e){super(),this.destination=t,this.source=e}next(t){var e,i;null===(i=null===(e=this.destination)||void 0===e?void 0:e.next)||void 0===i||i.call(e,t)}error(t){var e,i;null===(i=null===(e=this.destination)||void 0===e?void 0:e.error)||void 0===i||i.call(e,t)}complete(){var t,e;null===(e=null===(t=this.destination)||void 0===t?void 0:t.complete)||void 0===e||e.call(t)}_subscribe(t){var e,i;return null!==(i=null===(e=this.source)||void 0===e?void 0:e.subscribe(t))&&void 0!==i?i:Xl}}class _o extends Pt{constructor(t){super(),this._value=t}get value(){return this.getValue()}_subscribe(t){const e=super._subscribe(t);return!e.closed&&t.next(this._value),e}getValue(){const{hasError:t,thrownError:e,_value:i}=this;if(t)throw e;return this._throwIfClosed(),i}next(t){super.next(this._value=t)}}class Ls extends pt{constructor(t,e,i,r,s,o){super(t),this.onFinalize=s,this.shouldUnsubscribe=o,this._next=e?function(a){try{e(a)}catch(l){t.error(l)}}:super._next,this._error=r?function(a){try{r(a)}catch(l){t.error(l)}finally{this.unsubscribe()}}:super._error,this._complete=i?function(){try{i()}catch(a){t.error(a)}finally{this.unsubscribe()}}:super._complete}unsubscribe(){var t;if(!this.shouldUnsubscribe||this.shouldUnsubscribe()){const{closed:e}=this;super.unsubscribe(),!e&&(null===(t=this.onFinalize)||void 0===t||t.call(this))}}}function jr(n,t){return function Ur(n){return t=>{if(function cn(n){return Eo(n?.lift)}(t))return t.lift(function(e){try{return n(e,this)}catch(i){this.error(i)}});throw new TypeError("Unable to lift unknown Observable type")}}((e,i)=>{let r=0;e.subscribe(function Do(n,t,e,i,r){return new Ls(n,t,e,i,r)}(i,s=>{i.next(n.call(t,s,r++))}))})}class F extends Error{constructor(t,e){super(function ae(n,t){return`NG0${Math.abs(n)}${t?": "+t:""}`}(t,e)),this.code=t}}function Xe(n){for(let t in n)if(n[t]===Xe)return t;throw Error("Could not find renamed property on target object.")}function mt(n,t){for(const e in t)t.hasOwnProperty(e)&&!n.hasOwnProperty(e)&&(n[e]=t[e])}function dt(n){if("string"==typeof n)return n;if(Array.isArray(n))return"["+n.map(dt).join(", ")+"]";if(null==n)return""+n;if(n.overriddenName)return`${n.overriddenName}`;if(n.name)return`${n.name}`;const t=n.toString();if(null==t)return""+t;const e=t.indexOf("\n");return-1===e?t:t.substring(0,e)}function qt(n,t){return null==n||""===n?null===t?"":t:null==t||""===t?n:n+" "+t}const ur=Xe({__forward_ref__:Xe});function ir(n){return n.__forward_ref__=ir,n.toString=function(){return dt(this())},n}function vt(n){return function Tn(n){return"function"==typeof n&&n.hasOwnProperty(ur)&&n.__forward_ref__===ir}(n)?n():n}function $l(n){return n&&!!n.\u0275providers}const Zl=Xe({\u0275cmp:Xe}),$d=Xe({\u0275dir:Xe}),gp=Xe({\u0275pipe:Xe}),Uo=Xe({\u0275fac:Xe}),jo=Xe({__NG_ELEMENT_ID__:Xe}),vp=Xe({__NG_ENV_ID__:Xe});function Ri(n){return"function"==typeof n?n.name||n.toString():"object"==typeof n&&null!=n&&"function"==typeof n.type?n.type.name||n.type.toString():function Nt(n){return"string"==typeof n?n:null==n?"":String(n)}(n)}function Lb(n,t){throw new F(-201,!1)}function so(n,t){null==n&&function zt(n,t,e,i){throw new Error(`ASSERTION ERROR: ${n}`+(null==i?"":` [Expected=> ${e} ${i} ${t} <=Actual]`))}(t,n,null,"!=")}function Yi(n){return{token:n.token,providedIn:n.providedIn||null,factory:n.factory,value:void 0}}function mp(n){return{providers:n.providers||[],imports:n.imports||[]}}function Em(n){return zT(n,xm)||zT(n,RT)}function zT(n,t){return n.hasOwnProperty(t)?n[t]:null}function Dm(n){return n&&(n.hasOwnProperty(Nb)||n.hasOwnProperty(x_))?n[Nb]:null}const xm=Xe({\u0275prov:Xe}),Nb=Xe({\u0275inj:Xe}),RT=Xe({ngInjectableDef:Xe}),x_=Xe({ngInjectorDef:Xe});var xi=function(n){return n[n.Default=0]="Default",n[n.Host=1]="Host",n[n.Self=2]="Self",n[n.SkipSelf=4]="SkipSelf",n[n.Optional=8]="Optional",n}(xi||{});let Ob;function oo(n){const t=Ob;return Ob=n,t}function BT(n,t,e){const i=Em(n);return i&&"root"==i.providedIn?void 0===i.value?i.value=i.factory():i.value:e&xi.Optional?null:void 0!==t?t:void Lb()}const rr=globalThis;class Ht{constructor(t,e){this._desc=t,this.ngMetadataName="InjectionToken",this.\u0275prov=void 0,"number"==typeof e?this.__NG_ELEMENT_ID__=e:void 0!==e&&(this.\u0275prov=Yi({token:this,providedIn:e.providedIn||"root",factory:e.factory}))}get multi(){return this}toString(){return`InjectionToken ${this._desc}`}}const yp={},Hb="__NG_DI_FLAG__",Tm="ngTempTokenPath",L_=/\n/gm,_T="__source";let Jd;function Gh(n){const t=Jd;return Jd=n,t}function k_(n,t=xi.Default){if(void 0===Jd)throw new F(-203,!1);return null===Jd?BT(n,void 0,t):Jd.get(n,t&xi.Optional?null:void 0,t)}function _i(n,t=xi.Default){return(function HT(){return Ob}()||k_)(vt(n),t)}function Hi(n,t=xi.Default){return _i(n,Am(t))}function Am(n){return typeof n>"u"||"number"==typeof n?n:0|(n.optional&&8)|(n.host&&1)|(n.self&&2)|(n.skipSelf&&4)}function Bb(n){const t=[];for(let e=0;et){o=s-1;break}}}for(;ss?"":r[d+1].toLowerCase();const f=8&i?u:null;if(f&&-1!==jT(f,h,0)||2&i&&h!==u){if(Ma(i))return!1;o=!0}}}}else{if(!o&&!Ma(i)&&!Ma(l))return!1;if(o&&Ma(l))continue;o=!1,i=l|1&i}}return Ma(i)||o}function Ma(n){return 0==(1&n)}function __(n,t,e,i){if(null===t)return-1;let r=0;if(i||!e){let s=!1;for(;r-1)for(e++;e0?'="'+a+'"':"")+"]"}else 8&i?r+="."+o:4&i&&(r+=" "+o);else""!==r&&!Ma(o)&&(t+=qT(s,r),r=""),i=o,s=s||!Ma(i);e++}return""!==r&&(t+=qT(s,r)),t}function _b(n){return Jl(()=>{const t=ZT(n),e={...t,decls:n.decls,vars:n.vars,template:n.template,consts:n.consts||null,ngContentSelectors:n.ngContentSelectors,onPush:n.changeDetection===Lm.OnPush,directiveDefs:null,pipeDefs:null,dependencies:t.standalone&&n.dependencies||null,getStandaloneInjector:null,signals:n.signals??!1,data:n.data||{},encapsulation:n.encapsulation||ba.Emulated,styles:n.styles||Qi,_:null,schemas:n.schemas||null,tView:null,id:""};JT(e);const i=n.dependencies;return e.directiveDefs=Om(i,!1),e.pipeDefs=Om(i,!0),e.id=function Z_(n){let t=0;const e=[n.selectors,n.ngContentSelectors,n.hostVars,n.hostAttrs,n.consts,n.vars,n.decls,n.encapsulation,n.standalone,n.signals,n.exportAs,JSON.stringify(n.inputs),JSON.stringify(n.outputs),Object.getOwnPropertyNames(n.type.prototype),!!n.contentQueries,!!n.viewQuery].join("|");for(const r of e)t=Math.imul(31,t)+r.charCodeAt(0)<<0;return t+=2147483648,"c"+t}(e),e})}function X_(n){return di(n)||Wn(n)}function q_(n){return null!==n}function Nm(n){return Jl(()=>({type:n.type,bootstrap:n.bootstrap||Qi,declarations:n.declarations||Qi,imports:n.imports||Qi,exports:n.exports||Qi,transitiveCompileScopes:null,schemas:n.schemas||null,id:n.id||null}))}function $T(n,t){if(null==n)return rl;const e={};for(const i in n)if(n.hasOwnProperty(i)){const r=n[i];let s,o,a=Xh.None;Array.isArray(r)?(a=r[0],s=r[1],o=r[2]??s):(s=r,o=r),t?(e[s]=a!==Xh.None?[i,a]:i,t[s]=o):e[s]=i}return e}function nr(n){return Jl(()=>{const t=ZT(n);return JT(t),t})}function di(n){return n[Zl]||null}function Wn(n){return n[$d]||null}function gs(n){return n[gp]||null}function ZT(n){const t={};return{type:n.type,providersResolver:null,factory:null,hostBindings:n.hostBindings||null,hostVars:n.hostVars||0,hostAttrs:n.hostAttrs||null,contentQueries:n.contentQueries||null,declaredInputs:t,inputTransforms:null,inputConfig:n.inputs||rl,exportAs:n.exportAs||null,standalone:!0===n.standalone,signals:!0===n.signals,selectors:n.selectors||Qi,viewQuery:n.viewQuery||null,features:n.features||null,setInput:null,findHostDirectiveDefs:null,hostDirectives:null,inputs:$T(n.inputs,t),outputs:$T(n.outputs),debugInfo:null}}function JT(n){n.features?.forEach(t=>t(n))}function Om(n,t){if(!n)return null;const e=t?gs:X_;return()=>("function"==typeof n?n():n).map(i=>e(i)).filter(q_)}const Vr=0,Be=1,Ct=2,vn=3,wa=4,Os=5,Ca=6,Kd=7,Er=8,Xs=9,Kl=10,Yt=11,bp=12,KT=13,eu=14,Jr=15,Mp=16,tu=17,nl=18,wp=19,eA=20,qh=21,km=22,Uc=23,jt=25,Ub=1,sl=7,iu=9,mn=10;var jb=function(n){return n[n.None=0]="None",n[n.HasTransplantedViews=2]="HasTransplantedViews",n}(jb||{});function ks(n){return Array.isArray(n)&&"object"==typeof n[Ub]}function Ps(n){return Array.isArray(n)&&!0===n[Ub]}function Vb(n){return 0!=(4&n.flags)}function jc(n){return n.componentOffset>-1}function zm(n){return 1==(1&n.flags)}function Ea(n){return!!n.template}function Wb(n){return 0!=(512&n[Ct])}function Vc(n,t){return n.hasOwnProperty(Uo)?n[Uo]:null}class tU{constructor(t,e,i){this.previousValue=t,this.currentValue=e,this.firstChange=i}isFirstChange(){return this.firstChange}}function nA(n,t,e,i){null!==t?t.applyValueToInputSignal(t,i):n[e]=i}function sA(n){return n.type.prototype.ngOnChanges&&(n.setInput=rU),iU}function iU(){const n=aA(this),t=n?.current;if(t){const e=n.previous;if(e===rl)n.previous=t;else for(let i in t)e[i]=t[i];n.current=null,this.ngOnChanges(t)}}function rU(n,t,e,i,r){const s=this.declaredInputs[i],o=aA(n)||function nU(n,t){return n[oA]=t}(n,{previous:rl,current:null}),a=o.current||(o.current={}),l=o.previous,h=l[s];a[s]=new tU(h&&h.currentValue,e,l===rl),nA(n,t,r,e)}const oA="__ngSimpleChanges__";function aA(n){return n[oA]||null}const ol=function(n,t,e){};let cA=!1;function fr(n){for(;Array.isArray(n);)n=n[Vr];return n}function qs(n,t){return fr(t[n.index])}function Dp(n,t){return n.data[t]}function To(n,t){const e=t[n];return ks(e)?e:e[Vr]}function qb(n){return 128==(128&n[Ct])}function al(n,t){return null==t?null:n[t]}function dA(n){n[tu]=0}function cU(n){1024&n[Ct]||(n[Ct]|=1024,qb(n)&&xp(n))}function fA(n){return 9216&n[Ct]||n[Uc]?.dirty}function $b(n){fA(n)?xp(n):64&n[Ct]&&(function oU(){return cA}()?(n[Ct]|=1024,xp(n)):n[Kl].changeDetectionScheduler?.notify())}function xp(n){n[Kl].changeDetectionScheduler?.notify();let t=Wc(n);for(;null!==t&&!(8192&t[Ct])&&(t[Ct]|=8192,qb(t));)t=Wc(t)}function Wc(n){const t=n[vn];return Ps(t)?t[vn]:t}const Rt={lFrame:wA(null),bindingsEnabled:!0,skipHydrationRootTNode:null};function gA(){return Rt.bindingsEnabled}function Se(){return Rt.lFrame.lView}function Ti(){return Rt.lFrame.tView}function pr(){let n=vA();for(;null!==n&&64===n.type;)n=n.parent;return n}function vA(){return Rt.lFrame.currentTNode}function ll(n,t){const e=Rt.lFrame;e.currentTNode=n,e.isParent=t}function Jb(){return Rt.lFrame.isParent}function wU(n,t){const e=Rt.lFrame;e.bindingIndex=e.bindingRootIndex=n,e1(t)}function e1(n){Rt.lFrame.currentDirectiveIndex=n}function IA(){return Rt.lFrame.currentQueryIndex}function i1(n){Rt.lFrame.currentQueryIndex=n}function EU(n){const t=n[Be];return 2===t.type?t.declTNode:1===t.type?n[Os]:null}function bA(n,t,e){if(e&xi.SkipSelf){let r=t,s=n;for(;!(r=r.parent,null!==r||e&xi.Host||(r=EU(s),null===r||(s=s[eu],10&r.type))););if(null===r)return!1;t=r,n=s}const i=Rt.lFrame=MA();return i.currentTNode=t,i.lView=n,!0}function r1(n){const t=MA(),e=n[Be];Rt.lFrame=t,t.currentTNode=e.firstChild,t.lView=n,t.tView=e,t.contextLView=n,t.bindingIndex=e.bindingStartIndex,t.inI18n=!1}function MA(){const n=Rt.lFrame,t=null===n?null:n.child;return null===t?wA(n):t}function wA(n){const t={currentTNode:null,isParent:!0,lView:null,tView:null,selectedIndex:-1,contextLView:null,elementDepthCount:0,currentNamespace:null,currentDirectiveIndex:-1,bindingRootIndex:-1,bindingIndex:-1,currentQueryIndex:0,parent:n,child:null,inI18n:!1};return null!==n&&(n.child=t),t}function CA(){const n=Rt.lFrame;return Rt.lFrame=n.parent,n.currentTNode=null,n.lView=null,n}const EA=CA;function n1(){const n=CA();n.isParent=!0,n.tView=null,n.selectedIndex=-1,n.contextLView=null,n.elementDepthCount=0,n.currentDirectiveIndex=-1,n.currentNamespace=null,n.bindingRootIndex=-1,n.bindingIndex=-1,n.currentQueryIndex=0}function zs(){return Rt.lFrame.selectedIndex}function Yc(n){Rt.lFrame.selectedIndex=n}let xA=!0;function Bm(){return xA}function $h(n){xA=n}function Fm(n,t){for(let e=t.directiveStart,i=t.directiveEnd;e=i)break}else t[l]<0&&(n[tu]+=65536),(a>14>16&&(3&n[Ct])===t&&(n[Ct]+=16384,AA(a,s)):AA(a,s)}const su=-1;class Ap{constructor(t,e,i){this.factory=t,this.resolving=!1,this.canSeeViewProviders=e,this.injectImpl=i}}function a1(n){return n!==su}function Lp(n){return 32767&n}function Np(n,t){let e=function HU(n){return n>>16}(n),i=t;for(;e>0;)i=i[eu],e--;return i}let l1=!0;function jm(n){const t=l1;return l1=n,t}const LA=255,NA=5;let BU=0;const cl={};function Vm(n,t){const e=OA(n,t);if(-1!==e)return e;const i=t[Be];i.firstCreatePass&&(n.injectorIndex=t.length,h1(i.data,n),h1(t,null),h1(i.blueprint,null));const r=Wm(n,t),s=n.injectorIndex;if(a1(r)){const o=Lp(r),a=Np(r,t),l=a[Be].data;for(let h=0;h<8;h++)t[s+h]=a[o+h]|l[o+h]}return t[s+8]=r,s}function h1(n,t){n.push(0,0,0,0,0,0,0,0,t)}function OA(n,t){return-1===n.injectorIndex||n.parent&&n.parent.injectorIndex===n.injectorIndex||null===t[n.injectorIndex+8]?-1:n.injectorIndex}function Wm(n,t){if(n.parent&&-1!==n.parent.injectorIndex)return n.parent.injectorIndex;let e=0,i=null,r=t;for(;null!==r;){if(i=FA(r),null===i)return su;if(e++,r=r[eu],-1!==i.injectorIndex)return i.injectorIndex|e<<16}return su}function c1(n,t,e){!function FU(n,t,e){let i;"string"==typeof e?i=e.charCodeAt(0)||0:e.hasOwnProperty(jo)&&(i=e[jo]),null==i&&(i=e[jo]=BU++);const r=i&LA;t.data[n+(r>>NA)]|=1<=0?t&LA:VU:t}(e);if("function"==typeof s){if(!bA(t,n,i))return i&xi.Host?kA(r,0,i):PA(t,e,i,r);try{let o;if(o=s(i),null!=o||i&xi.Optional)return o;Lb()}finally{EA()}}else if("number"==typeof s){let o=null,a=OA(n,t),l=su,h=i&xi.Host?t[Jr][Os]:null;for((-1===a||i&xi.SkipSelf)&&(l=-1===a?Wm(n,t):t[a+8],l!==su&&BA(i,!1)?(o=t[Be],a=Lp(l),t=Np(l,t)):a=-1);-1!==a;){const c=t[Be];if(HA(s,a,c.data)){const d=UU(a,t,e,o,i,h);if(d!==cl)return d}l=t[a+8],l!==su&&BA(i,t[Be].data[a+8]===h)&&HA(s,a,t)?(o=c,a=Lp(l),t=Np(l,t)):a=-1}}return r}function UU(n,t,e,i,r,s){const o=t[Be],a=o.data[n+8],c=Ym(a,o,e,null==i?jc(a)&&l1:i!=o&&0!=(3&a.type),r&xi.Host&&s===a);return null!==c?Qc(t,o,c,a):cl}function Ym(n,t,e,i,r){const s=n.providerIndexes,o=t.data,a=1048575&s,l=n.directiveStart,c=s>>20,u=r?a+c:n.directiveEnd;for(let f=i?a:a+c;f=l&&p.type===e)return f}if(r){const f=o[l];if(f&&Ea(f)&&f.type===e)return l}return null}function Qc(n,t,e,i){let r=n[e];const s=t.data;if(function kU(n){return n instanceof Ap}(r)){const o=r;o.resolving&&function Vo(n,t){const e=t?`. Dependency path: ${t.join(" > ")} > ${n}`:"";throw new F(-200,`Circular dependency in DI detected for ${n}${e}`)}(Ri(s[e]));const a=jm(o.canSeeViewProviders);o.resolving=!0;const h=o.injectImpl?oo(o.injectImpl):null;bA(n,i,xi.Default);try{r=n[e]=o.factory(void 0,s,n,i),t.firstCreatePass&&e>=i.directiveStart&&function NU(n,t,e){const{ngOnChanges:i,ngOnInit:r,ngDoCheck:s}=t.type.prototype;if(i){const o=sA(t);(e.preOrderHooks??=[]).push(n,o),(e.preOrderCheckHooks??=[]).push(n,o)}r&&(e.preOrderHooks??=[]).push(0-n,r),s&&((e.preOrderHooks??=[]).push(n,s),(e.preOrderCheckHooks??=[]).push(n,s))}(e,s[e],t)}finally{null!==h&&oo(h),jm(a),o.resolving=!1,EA()}}return r}function HA(n,t,e){return!!(e[t+(n>>NA)]&1<Array.isArray(e)?fu(e,t):t(e))}function UA(n,t,e){t>=n.length?n.push(e):n.splice(t,0,e)}function Qm(n,t){return t>=n.length-1?n.pop():n.splice(t,1)[0]}const vu=new Ht(""),GA=new Ht("",-1),I1=new Ht("");class $m{get(t,e=yp){if(e===yp){const i=new Error(`NullInjectorError: No provider for ${dt(t)}!`);throw i.name="NullInjectorError",i}return e}}function fj(...n){return{\u0275providers:XA(0,n),\u0275fromNgModule:!0}}function XA(n,...t){const e=[],i=new Set;let r;const s=o=>{e.push(o)};return fu(t,o=>{const a=o;Zm(a,s,[],i)&&(r||=[],r.push(a))}),void 0!==r&&qA(r,s),e}function qA(n,t){for(let e=0;e{t(s,i)})}}function Zm(n,t,e,i){if(!(n=vt(n)))return!1;let r=null,s=Dm(n);const o=!s&&di(n);if(s||o){if(o&&!o.standalone)return!1;r=n}else{const l=n.ngModule;if(s=Dm(l),!s)return!1;r=l}const a=i.has(r);if(o){if(a)return!1;if(i.add(r),o.dependencies){const l="function"==typeof o.dependencies?o.dependencies():o.dependencies;for(const h of l)Zm(h,t,e,i)}}else{if(!s)return!1;{if(null!=s.imports&&!a){let h;i.add(r);try{fu(s.imports,c=>{Zm(c,t,e,i)&&(h||=[],h.push(c))})}finally{}void 0!==h&&qA(h,t)}if(!a){const h=Vc(r)||(()=>new r);t({provide:r,useFactory:h,deps:Qi},r),t({provide:I1,useValue:r,multi:!0},r),t({provide:vu,useValue:()=>_i(r),multi:!0},r)}const l=s.providers;if(null!=l&&!a){const h=n;M1(l,c=>{t(c,h)})}}}return r!==n&&void 0!==n.providers}function M1(n,t){for(let e of n)$l(e)&&(e=e.\u0275providers),Array.isArray(e)?M1(e,t):t(e)}const pj=Xe({provide:String,useValue:Xe});function w1(n){return null!==n&&"object"==typeof n&&pj in n}function Gc(n){return"function"==typeof n}const C1=new Ht(""),Jm={},vj={};let E1;function Km(){return void 0===E1&&(E1=new $m),E1}class ih{}class mu extends ih{get destroyed(){return this._destroyed}constructor(t,e,i,r){super(),this.parent=e,this.source=i,this.scopes=r,this.records=new Map,this._ngOnDestroyHooks=new Set,this._onDestroyHooks=[],this._destroyed=!1,x1(t,o=>this.processProvider(o)),this.records.set(GA,yu(void 0,this)),r.has("environment")&&this.records.set(ih,yu(void 0,this));const s=this.records.get(C1);null!=s&&"string"==typeof s.value&&this.scopes.add(s.value),this.injectorDefTypes=new Set(this.get(I1,Qi,xi.Self))}destroy(){this.assertNotDestroyed(),this._destroyed=!0;try{for(const e of this._ngOnDestroyHooks)e.ngOnDestroy();const t=this._onDestroyHooks;this._onDestroyHooks=[];for(const e of t)e()}finally{this.records.clear(),this._ngOnDestroyHooks.clear(),this.injectorDefTypes.clear()}}onDestroy(t){return this.assertNotDestroyed(),this._onDestroyHooks.push(t),()=>this.removeOnDestroy(t)}runInContext(t){this.assertNotDestroyed();const e=Gh(this),i=oo(void 0);try{return t()}finally{Gh(e),oo(i)}}get(t,e=yp,i=xi.Default){if(this.assertNotDestroyed(),t.hasOwnProperty(vp))return t[vp](this);i=Am(i);const s=Gh(this),o=oo(void 0);try{if(!(i&xi.SkipSelf)){let l=this.records.get(t);if(void 0===l){const h=function bj(n){return"function"==typeof n||"object"==typeof n&&n instanceof Ht}(t)&&Em(t);l=h&&this.injectableDefInScope(h)?yu(D1(t),Jm):null,this.records.set(t,l)}if(null!=l)return this.hydrate(t,l)}return(i&xi.Self?Km():this.parent).get(t,e=i&xi.Optional&&e===yp?null:e)}catch(a){if("NullInjectorError"===a.name){if((a[Tm]=a[Tm]||[]).unshift(dt(t)),s)throw a;return function z_(n,t,e,i){const r=n[Tm];throw t[_T]&&r.unshift(t[_T]),n.message=function R_(n,t,e,i=null){n=n&&"\n"===n.charAt(0)&&"\u0275"==n.charAt(1)?n.slice(2):n;let r=dt(t);if(Array.isArray(t))r=t.map(dt).join(" -> ");else if("object"==typeof t){let s=[];for(let o in t)if(t.hasOwnProperty(o)){let a=t[o];s.push(o+":"+("string"==typeof a?JSON.stringify(a):dt(a)))}r=`{${s.join(", ")}}`}return`${e}${i?"("+i+")":""}[${r}]: ${n.replace(L_,"\n ")}`}("\n"+n.message,r,e,i),n.ngTokenPath=r,n[Tm]=null,n}(a,t,"R3InjectorError",this.source)}throw a}finally{oo(o),Gh(s)}}resolveInjectorInitializers(){const t=Gh(this),e=oo(void 0);try{const r=this.get(vu,Qi,xi.Self);for(const s of r)s()}finally{Gh(t),oo(e)}}toString(){const t=[],e=this.records;for(const i of e.keys())t.push(dt(i));return`R3Injector[${t.join(", ")}]`}assertNotDestroyed(){if(this._destroyed)throw new F(205,!1)}processProvider(t){let e=Gc(t=vt(t))?t:vt(t&&t.provide);const i=function yj(n){return w1(n)?yu(void 0,n.useValue):yu(JA(n),Jm)}(t);if(!Gc(t)&&!0===t.multi){let r=this.records.get(e);r||(r=yu(void 0,Jm,!0),r.factory=()=>Bb(r.multi),this.records.set(e,r)),e=t,r.multi.push(t)}this.records.set(e,i)}hydrate(t,e){return e.value===Jm&&(e.value=vj,e.value=e.factory()),"object"==typeof e.value&&e.value&&function Ij(n){return null!==n&&"object"==typeof n&&"function"==typeof n.ngOnDestroy}(e.value)&&this._ngOnDestroyHooks.add(e.value),e.value}injectableDefInScope(t){if(!t.providedIn)return!1;const e=vt(t.providedIn);return"string"==typeof e?"any"===e||this.scopes.has(e):this.injectorDefTypes.has(e)}removeOnDestroy(t){const e=this._onDestroyHooks.indexOf(t);-1!==e&&this._onDestroyHooks.splice(e,1)}}function D1(n){const t=Em(n),e=null!==t?t.factory:Vc(n);if(null!==e)return e;if(n instanceof Ht)throw new F(204,!1);if(n instanceof Function)return function mj(n){if(n.length>0)throw new F(204,!1);const e=function D_(n){return n&&(n[xm]||n[RT])||null}(n);return null!==e?()=>e.factory(n):()=>new n}(n);throw new F(204,!1)}function JA(n,t,e){let i;if(Gc(n)){const r=vt(n);return Vc(r)||D1(r)}if(w1(n))i=()=>vt(n.useValue);else if(function ZA(n){return!(!n||!n.useFactory)}(n))i=()=>n.useFactory(...Bb(n.deps||[]));else if(function $A(n){return!(!n||!n.useExisting)}(n))i=()=>_i(vt(n.useExisting));else{const r=vt(n&&(n.useClass||n.provide));if(!function Sj(n){return!!n.deps}(n))return Vc(r)||D1(r);i=()=>new r(...Bb(n.deps))}return i}function yu(n,t,e=!1){return{factory:n,value:t,multi:e?[]:void 0}}function x1(n,t){for(const e of n)Array.isArray(e)?x1(e,t):e&&$l(e)?x1(e.\u0275providers,t):t(e)}function iL(n,t=null,e=null,i){const r=function rL(n,t=null,e=null,i,r=new Set){const s=[e||Qi,fj(n)];return i=i||("object"==typeof n?void 0:dt(n)),new mu(s,t||Km(),i||null,r)}(n,t,e,i);return r.resolveInjectorInitializers(),r}let L1,Wo=(()=>{class n{static{this.THROW_IF_NOT_FOUND=yp}static{this.NULL=new $m}static create(e,i){if(Array.isArray(e))return iL({name:""},i,e,"");{const r=e.name??"";return iL({name:r},e.parent,e.providers,r)}}static{this.\u0275prov=Yi({token:n,providedIn:"any",factory:()=>_i(GA)})}static{this.__NG_ELEMENT_ID__=-1}}return n})();const N1=new Ht("",{providedIn:"root",factory:()=>Lj}),Lj="ng",sL=new Ht(""),Su=new Ht("",{providedIn:"platform",factory:()=>"unknown"}),oL=new Ht("",{providedIn:"root",factory:()=>function Zh(){if(void 0!==L1)return L1;if(typeof document<"u")return document;throw new F(210,!1)}().body?.querySelector("[ngCspNonce]")?.getAttribute("ngCspNonce")||null});function ny(n){return 128==(128&n.flags)}var ec=function(n){return n[n.Important=1]="Important",n[n.DashCase=2]="DashCase",n}(ec||{});const R1=new Map;let Vj=0;const B1="__ngContext__";function Rs(n,t){ks(t)?(n[B1]=t[wp],function Yj(n){R1.set(n[wp],n)}(t)):n[B1]=t}let F1;function _1(n,t){return F1(n,t)}function bu(n,t,e,i,r){if(null!=i){let s,o=!1;Ps(i)?s=i:ks(i)&&(o=!0,i=i[Vr]);const a=fr(i);0===n&&null!==e?null==r?TL(t,e,a):qc(t,e,a,r||null,!0):1===n&&null!==e?qc(t,e,a,r||null,!0):2===n?function dy(n,t,e){const i=hy(n,t);i&&function a6(n,t,e,i){n.removeChild(t,e,i)}(n,i,t,e)}(t,a,o):3===n&&t.destroyNode(a),null!=s&&function c6(n,t,e,i,r){const s=e[sl];s!==fr(e)&&bu(t,n,i,s,r);for(let a=mn;a0&&(n[e-1][wa]=i[wa]);const s=Qm(n,mn+t);!function e6(n,t){EL(n,t),t[Vr]=null,t[Os]=null}(i[Be],i);const o=s[nl];null!==o&&o.detachView(s[Be]),i[vn]=null,i[wa]=null,i[Ct]&=-129}return i}function ly(n,t){if(!(256&t[Ct])){const e=t[Yt];e.destroyNode&&uy(n,t,e,3,null,null),function i6(n){let t=n[bp];if(!t)return j1(n[Be],n);for(;t;){let e=null;if(ks(t))e=t[bp];else{const i=t[mn];i&&(e=i)}if(!e){for(;t&&!t[wa]&&t!==n;)ks(t)&&j1(t[Be],t),t=t[vn];null===t&&(t=n),ks(t)&&j1(t[Be],t),e=t&&t[wa]}t=e}}(t)}}function j1(n,t){if(!(256&t[Ct])){t[Ct]&=-129,t[Ct]|=256,t[Uc]&&function Qd(n){if(Gl(n),Wh(n))for(let t=0;t=0?i[o]():i[-o].unsubscribe(),s+=2}else e[s].call(i[e[s+1]]);null!==i&&(t[Kd]=null);const r=t[qh];if(null!==r){t[qh]=null;for(let s=0;s-1){const{encapsulation:s}=n.data[i.directiveStart+r];if(s===ba.None||s===ba.Emulated)return null}return qs(i,e)}}(n,t.parent,e)}function qc(n,t,e,i,r){n.insertBefore(t,e,i,r)}function TL(n,t,e){n.appendChild(t,e)}function AL(n,t,e,i,r){null!==i?qc(n,t,e,i,r):TL(n,t,e)}function hy(n,t){return n.parentNode(t)}let W1,OL=function NL(n,t,e){return 40&n.type?qs(n,e):null};function cy(n,t,e,i){const r=V1(n,i,t),s=t[Yt],a=function LL(n,t,e){return OL(n,t,e)}(i.parent||t[Os],i,t);if(null!=r)if(Array.isArray(e))for(let l=0;lnull;function oM(n,t,e=!1){return JL(n,t,e)}class G6{}class rN{}class q6{resolveComponentFactory(t){throw function X6(n){const t=Error(`No component factory found for ${dt(n)}.`);return t.ngComponent=n,t}(t)}}let by=(()=>{class n{static{this.NULL=new q6}}return n})();function $6(){return xu(pr(),Se())}function xu(n,t){return new $c(qs(n,t))}let $c=(()=>{class n{constructor(e){this.nativeElement=e}static{this.__NG_ELEMENT_ID__=$6}}return n})();function Z6(n){return n instanceof $c?n.nativeElement:n}class sN{}let cM=(()=>{class n{constructor(){this.destroyNode=null}static{this.__NG_ELEMENT_ID__=()=>function J6(){const n=Se(),e=To(pr().index,n);return(ks(e)?e:n)[Yt]}()}}return n})(),K6=(()=>{class n{static{this.\u0275prov=Yi({token:n,providedIn:"root",factory:()=>null})}}return n})();const dM={};function Qp(n,t,e,i,r=!1){for(;null!==e;){const s=t[e.index];null!==s&&i.push(fr(s)),Ps(s)&&fN(s,i);const o=e.type;if(8&o)Qp(n,t,e.child,i);else if(32&o){const a=_1(e,t);let l;for(;l=a();)i.push(l)}else if(16&o){const a=PL(t,e);if(Array.isArray(a))i.push(...a);else{const l=Wc(t[Jr]);Qp(l[Be],l,a,i,!0)}}e=r?e.projectionNext:e.next}return i}function fN(n,t){for(let e=mn;e!1,producerRecomputeValue:()=>{},consumerMarkedDirty:()=>{},consumerOnSignalRead:()=>{},consumerIsAlwaysLive:!0,consumerMarkedDirty:n=>{xp(n.lView)},consumerOnSignalRead(){this.lView[Uc]=this}};function gN(n){return mN(n[bp])}function vN(n){return mN(n[wa])}function mN(n){for(;null!==n&&!Ps(n);)n=n[wa];return n}function pM(n){return n.ngOriginalError}class nh{constructor(){this._console=console}handleError(t){const e=this._findOriginalError(t);this._console.error("ERROR",t),e&&this._console.error("ORIGINAL ERROR",e)}_findOriginalError(t){let e=t&&pM(t);for(;e&&pM(e);)e=pM(e);return e||null}}const SN=new Ht("",{providedIn:"root",factory:()=>Hi(nh).handleError.bind(void 0)}),bN=new Ht("",{providedIn:"root",factory:()=>!1}),Qt={};function Ey(n=1){EN(Ti(),Se(),zs()+n,!1)}function EN(n,t,e,i){if(!i)if(3==(3&t[Ct])){const s=n.preOrderCheckHooks;null!==s&&_m(t,s,e)}else{const s=n.preOrderHooks;null!==s&&Um(t,s,0,e)}Yc(e)}function Ot(n,t=xi.Default){const e=Se();return null===e?_i(n,t):zA(pr(),e,vt(n),t)}function DN(n,t,e,i,r,s){const o=Wi(null);try{let a=null;r&Xh.SignalBased&&(a=t[i][Ts]),null!==a&&void 0!==a.transformFn&&(s=a.transformFn(s)),r&Xh.HasDecoratorInputTransform&&(s=n.inputTransforms[i].call(t,s)),null!==n.setInput?n.setInput(t,a,s,e,i):nA(t,a,i,s)}finally{Wi(o)}}function Dy(n,t,e,i,r,s,o,a,l,h,c){const d=t.blueprint.slice();return d[Vr]=r,d[Ct]=204|i,(null!==h||n&&2048&n[Ct])&&(d[Ct]|=2048),dA(d),d[vn]=d[eu]=n,d[Er]=e,d[Kl]=o||n&&n[Kl],d[Yt]=a||n&&n[Yt],d[Xs]=l||n&&n[Xs]||null,d[Os]=s,d[wp]=function Wj(){return Vj++}(),d[Ca]=c,d[eA]=h,d[Jr]=2==t.type?n[Jr]:d,d}function Tu(n,t,e,i,r){let s=n.data[t];if(null===s)s=function gM(n,t,e,i,r){const s=vA(),o=Jb(),l=n.data[t]=function LV(n,t,e,i,r,s){let o=t?t.injectorIndex:-1,a=0;return function nu(){return null!==Rt.skipHydrationRootTNode}()&&(a|=128),{type:e,index:i,insertBeforeIndex:null,injectorIndex:o,directiveStart:-1,directiveEnd:-1,directiveStylingLast:-1,componentOffset:-1,propertyBindings:null,flags:a,providerIndexes:0,value:r,attrs:s,mergedAttrs:null,localNames:null,initialInputs:void 0,inputs:null,outputs:null,tView:null,next:null,prev:null,projectionNext:null,child:null,parent:t,projection:null,styles:null,stylesWithoutHost:null,residualStyles:void 0,classes:null,classesWithoutHost:null,residualClasses:void 0,classBindings:0,styleBindings:0}}(0,o?s:s&&s.parent,e,t,i,r);return null===n.firstChild&&(n.firstChild=l),null!==s&&(o?null==s.child&&null!==l.parent&&(s.child=l):null===s.next&&(s.next=l,l.prev=s)),l}(n,t,e,i,r),function MU(){return Rt.lFrame.inI18n}()&&(s.flags|=32);else if(64&s.type){s.type=e,s.value=i,s.attrs=r;const o=function Tp(){const n=Rt.lFrame,t=n.currentTNode;return n.isParent?t:t.parent}();s.injectorIndex=null===o?-1:o.injectorIndex}return ll(s,!0),s}function Gp(n,t,e,i){if(0===e)return-1;const r=t.length;for(let s=0;sjt&&EN(n,t,jt,!1),ol(o?2:0,r),e(i,r)}finally{Yc(s),ol(o?3:1,r)}}function vM(n,t,e){if(Vb(t)){const i=Wi(null);try{const s=t.directiveEnd;for(let o=t.directiveStart;onull;function LN(n,t,e,i,r){for(let s in t){if(!t.hasOwnProperty(s))continue;const o=t[s];if(void 0===o)continue;i??={};let a,l=Xh.None;Array.isArray(o)?(a=o[0],l=o[1]):a=o;let h=s;if(null!==r){if(!r.hasOwnProperty(s))continue;h=r[s]}0===n?NN(i,e,h,a,l):NN(i,e,h,a)}return i}function NN(n,t,e,i,r){let s;n.hasOwnProperty(e)?(s=n[e]).push(t,i):s=n[e]=[t,i],void 0!==r&&s.push(r)}function ON(n,t,e,i,r,s){for(let h=0;h0;){const e=n[--t];if("number"==typeof e&&e<0)return e}return 0})(o)!=a&&o.push(a),o.push(e,i,s)}}(n,t,i,Gp(n,e,r.hostVars,Qt),r)}function YV(n,t,e,i,r,s){const o=s[t];if(null!==o)for(let a=0;an.nextProducerIndex;)n.producerNode.pop(),n.producerLastReadVersion.pop(),n.producerIndexOfThis.pop()}}(a,o),function fV(n){n.lView[Uc]!==n&&(n.lView=null,pN.push(n))}(a)),n1()}}function FN(n,t){for(let e=gN(n);null!==e;e=vN(e))for(let i=mn;i-1&&(Bp(t,i),Qm(e,i))}this._attachedToViewContainer=!1}ly(this._lView[Be],this._lView)}onDestroy(t){!function Hm(n,t){if(256==(256&n[Ct]))throw new F(911,!1);null===n[qh]&&(n[qh]=[]),n[qh].push(t)}(this._lView,t)}markForCheck(){Xp(this._cdRefInjectingView||this._lView)}detach(){this._lView[Ct]&=-129}reattach(){$b(this._lView),this._lView[Ct]|=128}detectChanges(){this._lView[Ct]|=1024,function EM(n,t=!0){const e=n[Kl],i=e.rendererFactory;i.begin?.();try{!function XV(n){DM(n,0);let t=0;for(;fA(n);){if(100===t)throw new F(103,!1);t++,DM(n,1)}}(n)}catch(s){throw t&&Ty(n,s),s}finally{i.end?.(),e.inlineEffectRunner?.flush()}}(this._lView,this.notifyErrorHandler)}checkNoChanges(){}attachToViewContainerRef(){if(this._appRef)throw new F(902,!1);this._attachedToViewContainer=!0}detachFromAppRef(){this._appRef=null,EL(this._lView[Be],this._lView)}attachToAppRef(t){if(this._attachedToViewContainer)throw new F(902,!1);this._appRef=t,$b(this._lView)}}const VN=new Set;function TM(n){return t=>{setTimeout(n,void 0,t)}}const Yo=class h7 extends Pt{constructor(t=!1){super(),this.__isAsync=t}emit(t){super.next(t)}subscribe(t,e,i){let r=t,s=e||(()=>null),o=i;if(t&&"object"==typeof t){const l=t;r=l.next?.bind(l),s=l.error?.bind(l),o=l.complete?.bind(l)}this.__isAsync&&(s=TM(s),r&&(r=TM(r)),o&&(o=TM(o)));const a=super.subscribe({next:r,error:s,complete:o});return t instanceof As&&t.add(a),a}};function WN(...n){}class Rr{constructor({enableLongStackTrace:t=!1,shouldCoalesceEventChangeDetection:e=!1,shouldCoalesceRunChangeDetection:i=!1}){if(this.hasPendingMacrotasks=!1,this.hasPendingMicrotasks=!1,this.isStable=!0,this.onUnstable=new Yo(!1),this.onMicrotaskEmpty=new Yo(!1),this.onStable=new Yo(!1),this.onError=new Yo(!1),typeof Zone>"u")throw new F(908,!1);Zone.assertZonePatched();const r=this;r._nesting=0,r._outer=r._inner=Zone.current,Zone.TaskTrackingZoneSpec&&(r._inner=r._inner.fork(new Zone.TaskTrackingZoneSpec)),t&&Zone.longStackTraceZoneSpec&&(r._inner=r._inner.fork(Zone.longStackTraceZoneSpec)),r.shouldCoalesceEventChangeDetection=!i&&e,r.shouldCoalesceRunChangeDetection=i,r.lastRequestAnimationFrameId=-1,r.nativeRequestAnimationFrame=function c7(){const n="function"==typeof rr.requestAnimationFrame;let t=rr[n?"requestAnimationFrame":"setTimeout"],e=rr[n?"cancelAnimationFrame":"clearTimeout"];if(typeof Zone<"u"&&t&&e){const i=t[Zone.__symbol__("OriginalDelegate")];i&&(t=i);const r=e[Zone.__symbol__("OriginalDelegate")];r&&(e=r)}return{nativeRequestAnimationFrame:t,nativeCancelAnimationFrame:e}}().nativeRequestAnimationFrame,function f7(n){const t=()=>{!function u7(n){n.isCheckStableRunning||-1!==n.lastRequestAnimationFrameId||(n.lastRequestAnimationFrameId=n.nativeRequestAnimationFrame.call(rr,()=>{n.fakeTopEventTask||(n.fakeTopEventTask=Zone.root.scheduleEventTask("fakeTopEventTask",()=>{n.lastRequestAnimationFrameId=-1,LM(n),n.isCheckStableRunning=!0,AM(n),n.isCheckStableRunning=!1},void 0,()=>{},()=>{})),n.fakeTopEventTask.invoke()}),LM(n))}(n)};n._inner=n._inner.fork({name:"angular",properties:{isAngularZone:!0},onInvokeTask:(e,i,r,s,o,a)=>{if(function p7(n){return!(!Array.isArray(n)||1!==n.length)&&!0===n[0].data?.__ignore_ng_zone__}(a))return e.invokeTask(r,s,o,a);try{return YN(n),e.invokeTask(r,s,o,a)}finally{(n.shouldCoalesceEventChangeDetection&&"eventTask"===s.type||n.shouldCoalesceRunChangeDetection)&&t(),QN(n)}},onInvoke:(e,i,r,s,o,a,l)=>{try{return YN(n),e.invoke(r,s,o,a,l)}finally{n.shouldCoalesceRunChangeDetection&&t(),QN(n)}},onHasTask:(e,i,r,s)=>{e.hasTask(r,s),i===r&&("microTask"==s.change?(n._hasPendingMicrotasks=s.microTask,LM(n),AM(n)):"macroTask"==s.change&&(n.hasPendingMacrotasks=s.macroTask))},onHandleError:(e,i,r,s)=>(e.handleError(r,s),n.runOutsideAngular(()=>n.onError.emit(s)),!1)})}(r)}static isInAngularZone(){return typeof Zone<"u"&&!0===Zone.current.get("isAngularZone")}static assertInAngularZone(){if(!Rr.isInAngularZone())throw new F(909,!1)}static assertNotInAngularZone(){if(Rr.isInAngularZone())throw new F(909,!1)}run(t,e,i){return this._inner.run(t,e,i)}runTask(t,e,i,r){const s=this._inner,o=s.scheduleEventTask("NgZoneEvent: "+r,t,d7,WN,WN);try{return s.runTask(o,e,i)}finally{s.cancelTask(o)}}runGuarded(t,e,i){return this._inner.runGuarded(t,e,i)}runOutsideAngular(t){return this._outer.run(t)}}const d7={};function AM(n){if(0==n._nesting&&!n.hasPendingMicrotasks&&!n.isStable)try{n._nesting++,n.onMicrotaskEmpty.emit(null)}finally{if(n._nesting--,!n.hasPendingMicrotasks)try{n.runOutsideAngular(()=>n.onStable.emit(null))}finally{n.isStable=!0}}}function LM(n){n.hasPendingMicrotasks=!!(n._hasPendingMicrotasks||(n.shouldCoalesceEventChangeDetection||n.shouldCoalesceRunChangeDetection)&&-1!==n.lastRequestAnimationFrameId)}function YN(n){n._nesting++,n.isStable&&(n.isStable=!1,n.onUnstable.emit(null))}function QN(n){n._nesting--,AM(n)}let $p=(()=>{class n{constructor(){this.handler=null,this.internalCallbacks=[]}execute(){const e=[...this.internalCallbacks];this.internalCallbacks.length=0;for(const r of e)r();return!!this.handler?.execute()||e.length>0}ngOnDestroy(){this.handler?.destroy(),this.handler=null,this.internalCallbacks.length=0}static{this.\u0275prov=Yi({token:n,providedIn:"root",factory:()=>new n})}}return n})();function y7(n,t){const e=To(t,n),i=e[Be];!function S7(n,t){for(let e=t.length;e0&&HL(n,e,s.join(" "))}}(u,w,p,i),void 0!==e&&function A7(n,t,e){const i=n.projection=[];for(let r=0;r=0;i--){const r=n[i];r.hostVars=t+=r.hostVars,r.hostAttrs=Ip(r.hostAttrs,e=Ip(e,r.hostAttrs))}}(i)}function N7(n,t){for(const e in t.inputs){if(!t.inputs.hasOwnProperty(e)||n.inputs.hasOwnProperty(e))continue;const i=t.inputs[e];if(void 0!==i&&(n.inputs[e]=i,n.declaredInputs[e]=t.declaredInputs[e],null!==t.inputTransforms)){const r=Array.isArray(i)?i[0]:i;if(!t.inputTransforms.hasOwnProperty(r))continue;n.inputTransforms??={},n.inputTransforms[r]=t.inputTransforms[r]}}}function Ly(n){return n===rl?{}:n===Qi?[]:n}function k7(n,t){const e=n.viewQuery;n.viewQuery=e?(i,r)=>{t(i,r),e(i,r)}:t}function P7(n,t){const e=n.contentQueries;n.contentQueries=e?(i,r,s)=>{t(i,r,s),e(i,r,s)}:t}function z7(n,t){const e=n.hostBindings;n.hostBindings=e?(i,r)=>{t(i,r),e(i,r)}:t}function Lu(n,t){return!t||null===t.firstChild||ny(n)}function rg(n,t,e,i=!0){const r=t[Be];if(function r6(n,t,e,i){const r=mn+i,s=e.length;i>0&&(e[r-1][wa]=t),i{class n{static{this.__NG_ELEMENT_ID__=h9}}return n})();function h9(){return fO(pr(),Se())}const c9=An,dO=class extends c9{constructor(t,e,i){super(),this._lContainer=t,this._hostTNode=e,this._hostLView=i}get element(){return xu(this._hostTNode,this._hostLView)}get injector(){return new Yn(this._hostTNode,this._hostLView)}get parentInjector(){const t=Wm(this._hostTNode,this._hostLView);if(a1(t)){const e=Np(t,this._hostLView),i=Lp(t);return new Yn(e[Be].data[i+8],e)}return new Yn(null,this._hostLView)}clear(){for(;this.length>0;)this.remove(this.length-1)}get(t){const e=uO(this._lContainer);return null!==e&&e[t]||null}get length(){return this._lContainer.length-mn}createEmbeddedView(t,e,i){let r,s;"number"==typeof i?r=i:null!=i&&(r=i.index,s=i.injector);const a=t.createEmbeddedViewImpl(e||{},s,null);return this.insertImpl(a,r,Lu(this._hostTNode,null)),a}createComponent(t,e,i,r,s){const o=t&&!function Op(n){return"function"==typeof n}(t);let a;if(o)a=e;else{const p=e||{};a=p.index,i=p.injector,r=p.projectableNodes,s=p.environmentInjector||p.ngModuleRef}const l=o?t:new Zp(di(t)),h=i||this.parentInjector;if(!s&&null==l.ngModule){const g=(o?h:this.parentInjector).get(ih,null);g&&(s=g)}di(l.componentType??{});const f=l.create(h,r,null,s);return this.insertImpl(f.hostView,a,Lu(this._hostTNode,null)),f}insert(t,e){return this.insertImpl(t,e,!0)}insertImpl(t,e,i){const r=t._lView;if(function hU(n){return Ps(n[vn])}(r)){const a=this.indexOf(t);if(-1!==a)this.detach(a);else{const l=r[vn],h=new dO(l,l[Os],l[vn]);h.detach(h.indexOf(t))}}const s=this._adjustIndex(e),o=this._lContainer;return rg(o,r,s,i),t.attachToViewContainerRef(),UA(BM(o),s,t),t}move(t,e){return this.insert(t,e)}indexOf(t){const e=uO(this._lContainer);return null!==e?e.indexOf(t):-1}remove(t){const e=this._adjustIndex(t,-1),i=Bp(this._lContainer,e);i&&(Qm(BM(this._lContainer),e),ly(i[Be],i))}detach(t){const e=this._adjustIndex(t,-1),i=Bp(this._lContainer,e);return i&&null!=Qm(BM(this._lContainer),e)?new qp(i):null}_adjustIndex(t,e=0){return t??this.length+e}};function uO(n){return n[8]}function BM(n){return n[8]||(n[8]=[])}function fO(n,t){let e;const i=t[n.index];return Ps(i)?e=i:(e=function PN(n,t,e,i){return[n,!0,0,t,null,i,null,e,null,null]}(i,t,null,n),t[n.index]=e,xy(t,e)),pO(e,t,n,i),new dO(e,n,t)}let pO=function vO(n,t,e,i){if(n[sl])return;let r;r=8&e.type?fr(i):function d9(n,t){const e=n[Yt],i=e.createComment(""),r=qs(t,n);return qc(e,hy(e,r),i,function l6(n,t){return n.nextSibling(t)}(e,r),!1),i}(t,e),n[sl]=r};function hg(n,t,e){const i=Se();return function Ln(n,t,e){return!Object.is(n[t],e)&&(n[t]=e,!0)}(i,function hl(){return Rt.lFrame.bindingIndex++}(),t)&&function No(n,t,e,i,r,s,o,a){const l=qs(t,e);let c,h=t.inputs;!a&&null!=h&&(c=h[i])?(CM(n,e,c,i,r),jc(t)&&function kV(n,t){const e=To(t,n);16&e[Ct]||(e[Ct]|=64)}(e,t.index)):3&t.type&&(i=function OV(n){return"class"===n?"className":"for"===n?"htmlFor":"formaction"===n?"formAction":"innerHtml"===n?"innerHTML":"readonly"===n?"readOnly":"tabindex"===n?"tabIndex":n}(i),r=null!=o?o(r,t.value||"",i):r,s.setProperty(l,i,r))}(Ti(),function zr(){const n=Rt.lFrame;return Dp(n.tView,n.selectedIndex)}(),i,n,t,i[Yt],e,!1),hg}function ZM(n,t,e,i,r){const o=r?"class":"style";CM(n,e,t.inputs[o],o,i)}function Gu(n,t,e,i){const r=Se(),s=Ti(),o=jt+n,a=r[Yt],l=s.firstCreatePass?function B8(n,t,e,i,r,s){const o=t.consts,l=Tu(t,n,2,i,al(o,r));return function IM(n,t,e,i){if(gA()){const r=null===i?null:{"":-1},s=function FV(n,t){const e=n.directiveRegistry;let i=null,r=null;if(e)for(let s=0;s($h(!0),ay(i,r,function DA(){return Rt.lFrame.currentNamespace}()));const $u="en-US";let Mk=$u;function aw(n){return!!n&&"function"==typeof n.then}function Gk(n){return!!n&&"function"==typeof n.subscribe}function lw(n,t,e,i){const r=Se(),s=Ti(),o=pr();return function qk(n,t,e,i,r,s,o){const a=zm(i),h=n.firstCreatePass&&HN(n),c=t[Er],d=RN(t);let u=!0;if(3&i.type||o){const g=qs(i,t),v=o?o(g):g,y=d.length,S=o?M=>o(fr(M[i.index])):i.index;let b=null;if(!o&&a&&(b=function UW(n,t,e,i){const r=n.cleanup;if(null!=r)for(let s=0;sl?a[l]:null}"string"==typeof o&&(s+=2)}return null}(n,t,r,i.index)),null!==b)(b.__ngLastListenerFn__||b).__ngNextListenerFn__=s,b.__ngLastListenerFn__=s,u=!1;else{s=Zk(i,t,c,s,!1);const M=e.listen(v,r,s);d.push(s,M),h&&h.push(r,S,y,y+1)}}else s=Zk(i,t,c,s,!1);const f=i.outputs;let p;if(u&&null!==f&&(p=f[r])){const g=p.length;if(g)for(let v=0;v-1?To(n.index,t):t);let l=$k(t,e,i,o),h=s.__ngNextListenerFn__;for(;h;)l=$k(t,e,h,o)&&l,h=h.__ngNextListenerFn__;return r&&!1===l&&o.preventDefault(),l}}function QW(){return this._results[Symbol.iterator]()}class cw{get changes(){return this._changes??=new Yo}constructor(t=!1){this._emitDistinctChangesOnly=t,this.dirty=!0,this._results=[],this._changesDetected=!1,this._changes=void 0,this.length=0,this.first=void 0,this.last=void 0;const e=cw.prototype;e[Symbol.iterator]||(e[Symbol.iterator]=QW)}get(t){return this._results[t]}map(t){return this._results.map(t)}filter(t){return this._results.filter(t)}find(t){return this._results.find(t)}reduce(t,e){return this._results.reduce(t,e)}forEach(t){this._results.forEach(t)}some(t){return this._results.some(t)}toArray(){return this._results.slice()}toString(){return this._results.toString()}reset(t,e){this.dirty=!1;const i=function lo(n){return n.flat(Number.POSITIVE_INFINITY)}(t);(this._changesDetected=!function $U(n,t,e){if(n.length!==t.length)return!1;for(let i=0;i{class n{static{this.__NG_ELEMENT_ID__=qW}}return n})();const GW=oh,XW=class extends GW{constructor(t,e,i){super(),this._declarationLView=t,this._declarationTContainer=e,this.elementRef=i}get ssrId(){return this._declarationTContainer.tView?.ssrId||null}createEmbeddedView(t,e){return this.createEmbeddedViewImpl(t,e)}createEmbeddedViewImpl(t,e,i){const r=function ig(n,t,e,i){const r=t.tView,a=Dy(n,r,e,4096&n[Ct]?4096:16,null,t,null,null,null,i?.injector??null,i?.dehydratedView??null);a[Mp]=n[t.index];const h=n[nl];return null!==h&&(a[nl]=h.createEmbeddedView(r)),NM(r,a,e),a}(this._declarationLView,this._declarationTContainer,t,{injector:e,dehydratedView:i});return new qp(r)}};function qW(){return Xy(pr(),Se())}function Xy(n,t){return 4&n.type?new XW(t,n,xu(n,t)):null}class dw{constructor(t){this.queryList=t,this.matches=null}clone(){return new dw(this.queryList)}setDirty(){this.queryList.setDirty()}}class uw{constructor(t=[]){this.queries=t}createEmbeddedView(t){const e=t.queries;if(null!==e){const i=null!==t.contentQueries?t.contentQueries[0]:e.length,r=[];for(let s=0;s0)i.push(o[a/2]);else{const h=s[a+1],c=t[-l];for(let d=mn;d($h(!0),function oy(n,t){return n.createText(t)}(t[Yt],i));function mw(n,t,e,i,r){if(n=vt(n),Array.isArray(n))for(let s=0;s>20;if(Gc(n)||!n.multi){const f=new Ap(h,r,Ot),p=Sw(l,t,r?c:c+u,d);-1===p?(c1(Vm(a,o),s,l),yw(s,n,t.length),t.push(l),a.directiveStart++,a.directiveEnd++,r&&(a.providerIndexes+=1048576),e.push(f),o.push(f)):(e[p]=f,o[p]=f)}else{const f=Sw(l,t,c+u,d),p=Sw(l,t,c,c+u),v=p>=0&&e[p];if(r&&!v||!r&&!(f>=0&&e[f])){c1(Vm(a,o),s,l);const y=function yY(n,t,e,i,r){const s=new Ap(n,e,Ot);return s.multi=[],s.index=t,s.componentProviders=0,kP(s,r,i&&!e),s}(r?mY:vY,e.length,r,i,h);!r&&v&&(e[p].providerFactory=y),yw(s,n,t.length,0),t.push(l),a.directiveStart++,a.directiveEnd++,r&&(a.providerIndexes+=1048576),e.push(y),o.push(y)}else yw(s,n,f>-1?f:p,kP(e[r?p:f],h,!r&&i));!r&&i&&v&&e[p].componentProviders++}}}function yw(n,t,e,i){const r=Gc(t),s=function gj(n){return!!n.useClass}(t);if(r||s){const l=(s?vt(t.useClass):t).prototype.ngOnDestroy;if(l){const h=n.destroyHooks||(n.destroyHooks=[]);if(!r&&t.multi){const c=h.indexOf(e);-1===c?h.push(e,[i,l]):h[c+1].push(i,l)}else h.push(e,l)}}}function kP(n,t,e){return e&&n.componentProviders++,n.multi.push(t)-1}function Sw(n,t,e,i){for(let r=e;r{e.providersResolver=(i,r)=>function gY(n,t,e){const i=Ti();if(i.firstCreatePass){const r=Ea(n);mw(e,i.data,i.blueprint,r,!0),mw(t,i.data,i.blueprint,r,!1)}}(i,r?r(n):n,t)}}class rd{}class zP extends rd{constructor(t){super(),this.componentFactoryResolver=new JN(this),this.instance=null;const e=new mu([...t.providers,{provide:rd,useValue:this},{provide:by,useValue:this.componentFactoryResolver}],t.parent||Km(),t.debugName,new Set(["environment"]));this.injector=e,t.runEnvironmentInitializers&&e.resolveInjectorInitializers()}destroy(){this.injector.destroy()}onDestroy(t){this.injector.onDestroy(t)}}let wY=(()=>{class n{constructor(e){this._injector=e,this.cachedInjectors=new Map}getOrCreateStandaloneInjector(e){if(!e.standalone)return null;if(!this.cachedInjectors.has(e)){const i=XA(0,e.type),r=i.length>0?function MY(n,t,e=null){return new zP({providers:n,parent:t,debugName:e,runEnvironmentInitializers:!0}).injector}([i],this._injector,`Standalone[${e.type.name}]`):null;this.cachedInjectors.set(e,r)}return this.cachedInjectors.get(e)}ngOnDestroy(){try{for(const e of this.cachedInjectors.values())null!==e&&e.destroy()}finally{this.cachedInjectors.clear()}}static{this.\u0275prov=Yi({token:n,providedIn:"environment",factory:()=>new n(_i(ih))})}}return n})();function RP(n){(function Zc(n){VN.has(n)||(VN.add(n),performance?.mark?.("mark_feature_usage",{detail:{feature:n}}))})("NgStandalone"),n.getStandaloneInjector=t=>t.get(wY).getOrCreateStandaloneInjector(n)}let Aw=(()=>{class n{constructor(){this.taskId=0,this.pendingTasks=new Set,this.hasPendingTasks=new _o(!1)}get _hasPendingTasks(){return this.hasPendingTasks.value}add(){this._hasPendingTasks||this.hasPendingTasks.next(!0);const e=this.taskId++;return this.pendingTasks.add(e),e}remove(e){this.pendingTasks.delete(e),0===this.pendingTasks.size&&this._hasPendingTasks&&this.hasPendingTasks.next(!1)}ngOnDestroy(){this.pendingTasks.clear(),this._hasPendingTasks&&this.hasPendingTasks.next(!1)}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();const g2=new Ht(""),XQ=new Ht("");let Pw=(()=>{class n{constructor(){this.initialized=!1,this.done=!1,this.donePromise=new Promise((e,i)=>{this.resolve=e,this.reject=i}),this.appInits=Hi(XQ,{optional:!0})??[]}runInitializers(){if(this.initialized)return;const e=[];for(const r of this.appInits){const s=r();if(aw(s))e.push(s);else if(Gk(s)){const o=new Promise((a,l)=>{s.subscribe({complete:a,error:l})});e.push(o)}}const i=()=>{this.done=!0,this.resolve()};Promise.all(e).then(()=>{i()}).catch(r=>{this.reject(r)}),0===e.length&&i(),this.initialized=!0}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();const v2=new Ht("");let Ku=(()=>{class n{constructor(){this._bootstrapListeners=[],this._runningTick=!1,this._destroyed=!1,this._destroyListeners=[],this._views=[],this.internalErrorHandler=Hi(SN),this.afterRenderEffectManager=Hi($p),this.componentTypes=[],this.components=[],this.isStable=Hi(Aw).hasPendingTasks.pipe(jr(e=>!e)),this._injector=Hi(ih)}get destroyed(){return this._destroyed}get injector(){return this._injector}bootstrap(e,i){const r=e instanceof rN;if(!this._injector.get(Pw).done)throw!r&&function _c(n){const t=di(n)||Wn(n)||gs(n);return null!==t&&t.standalone}(e),new F(405,!1);let o;o=r?e:this._injector.get(by).resolveComponentFactory(e),this.componentTypes.push(o.componentType);const a=function $Q(n){return n.isBoundToModule}(o)?void 0:this._injector.get(rd),h=o.create(Wo.NULL,[],i||o.selector,a),c=h.location.nativeElement,d=h.injector.get(g2,null);return d?.registerApplication(c),h.onDestroy(()=>{this.detachView(h.hostView),e0(this.components,h),d?.unregisterApplication(c)}),this._loadComponent(h),h}tick(){if(this._runningTick)throw new F(101,!1);try{this._runningTick=!0;for(let e of this._views)e.detectChanges()}catch(e){this.internalErrorHandler(e)}finally{try{this.afterRenderEffectManager.execute()}catch(e){this.internalErrorHandler(e)}this._runningTick=!1}}attachView(e){const i=e;this._views.push(i),i.attachToAppRef(this)}detachView(e){const i=e;e0(this._views,i),i.detachFromAppRef()}_loadComponent(e){this.attachView(e.hostView),this.tick(),this.components.push(e);const i=this._injector.get(v2,[]);[...this._bootstrapListeners,...i].forEach(r=>r(e))}ngOnDestroy(){if(!this._destroyed)try{this._destroyListeners.forEach(e=>e()),this._views.slice().forEach(e=>e.destroy())}finally{this._destroyed=!0,this._views=[],this._bootstrapListeners=[],this._destroyListeners=[]}}onDestroy(e){return this._destroyListeners.push(e),()=>e0(this._destroyListeners,e)}destroy(){if(this._destroyed)throw new F(406,!1);const e=this._injector;e.destroy&&!e.destroyed&&e.destroy()}get viewCount(){return this._views.length}warnIfDestroyed(){}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();function e0(n,t){const e=n.indexOf(t);e>-1&&n.splice(e,1)}let JQ=(()=>{class n{constructor(){this.zone=Hi(Rr),this.applicationRef=Hi(Ku)}initialize(){this._onMicrotaskEmptySubscription||(this._onMicrotaskEmptySubscription=this.zone.onMicrotaskEmpty.subscribe({next:()=>{this.zone.run(()=>{this.applicationRef.tick()})}}))}ngOnDestroy(){this._onMicrotaskEmptySubscription?.unsubscribe()}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();function b2(n){return[{provide:Rr,useFactory:n},{provide:vu,multi:!0,useFactory:()=>{const t=Hi(JQ,{optional:!0});return()=>t.initialize()}},{provide:vu,multi:!0,useFactory:()=>{const t=Hi(tG);return()=>{t.initialize()}}},{provide:SN,useFactory:KQ}]}function KQ(){const n=Hi(Rr),t=Hi(nh);return e=>n.runOutsideAngular(()=>t.handleError(e))}function eG(n){return function b1(n){return{\u0275providers:n}}([[],b2(()=>new Rr(function M2(n){return{enableLongStackTrace:!1,shouldCoalesceEventChangeDetection:n?.eventCoalescing??!1,shouldCoalesceRunChangeDetection:n?.runCoalescing??!1}}(n)))])}let tG=(()=>{class n{constructor(){this.subscription=new As,this.initialized=!1,this.zone=Hi(Rr),this.pendingTasks=Hi(Aw)}initialize(){if(this.initialized)return;this.initialized=!0;let e=null;!this.zone.isStable&&!this.zone.hasPendingMacrotasks&&!this.zone.hasPendingMicrotasks&&(e=this.pendingTasks.add()),this.zone.runOutsideAngular(()=>{this.subscription.add(this.zone.onStable.subscribe(()=>{Rr.assertNotInAngularZone(),queueMicrotask(()=>{null!==e&&!this.zone.hasPendingMacrotasks&&!this.zone.hasPendingMicrotasks&&(this.pendingTasks.remove(e),e=null)})}))}),this.subscription.add(this.zone.onUnstable.subscribe(()=>{Rr.assertInAngularZone(),e??=this.pendingTasks.add()}))}ngOnDestroy(){this.subscription.unsubscribe()}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();const ah=new Ht("",{providedIn:"root",factory:()=>Hi(ah,xi.Optional|xi.SkipSelf)||function iG(){return typeof $localize<"u"&&$localize.locale||$u}()}),zw=new Ht("");let nc=null;function DG(n){try{const{rootComponent:t,appProviders:e,platformProviders:i}=n,r=function aG(n=[]){if(nc)return nc;const t=function E2(n=[],t){return Wo.create({name:t,providers:[{provide:C1,useValue:"platform"},{provide:zw,useValue:new Set([()=>nc=null])},...n]})}(n);return nc=t,function m2(){!function Mb(n){Xd=n}(()=>{throw new F(600,!1)})}(),function D2(n){n.get(sL,null)?.forEach(e=>e())}(t),t}(i),s=[eG(),...e||[]],a=new zP({providers:s,parent:r,debugName:"",runEnvironmentInitializers:!1}).injector,l=a.get(Rr);return l.run(()=>{a.resolveInjectorInitializers();const h=a.get(nh,null);let c;l.runOutsideAngular(()=>{c=l.onError.subscribe({next:f=>{h.handleError(f)}})});const d=()=>a.destroy(),u=r.get(zw);return u.add(d),a.onDestroy(()=>{c.unsubscribe(),u.delete(d)}),function y2(n,t,e){try{const i=e();return aw(i)?i.catch(r=>{throw t.runOutsideAngular(()=>n.handleError(r)),r}):i}catch(i){throw t.runOutsideAngular(()=>n.handleError(i)),i}}(h,l,()=>{const f=a.get(Pw);return f.runInitializers(),f.donePromise.then(()=>{!function wk(n){so(n,"Expected localeId to be defined"),"string"==typeof n&&(Mk=n.toLowerCase().replace(/_/g,"-"))}(a.get(ah,$u)||$u);const g=a.get(Ku);return void 0!==t&&g.bootstrap(t),g})})})}catch(t){return Promise.reject(t)}}let $2=null;function Vw(){return $2}class UG{}const sd=new Ht("");let sq=(()=>{class n{static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275mod=Nm({type:n})}static{this.\u0275inj=mp({})}}return n})();function uz(n){return"server"===n}class kq extends UG{constructor(){super(...arguments),this.supportsDOMEvents=!0}}class oC extends kq{static makeCurrent(){!function _G(n){$2??=n}(new oC)}onAndCancel(t,e,i){return t.addEventListener(e,i),()=>{t.removeEventListener(e,i)}}dispatchEvent(t,e){t.dispatchEvent(e)}remove(t){t.parentNode&&t.parentNode.removeChild(t)}createElement(t,e){return(e=e||this.getDefaultDocument()).createElement(t)}createHtmlDocument(){return document.implementation.createHTMLDocument("fakeTitle")}getDefaultDocument(){return document}isElementNode(t){return t.nodeType===Node.ELEMENT_NODE}isShadowRoot(t){return t instanceof DocumentFragment}getGlobalEventTarget(t,e){return"window"===e?window:"document"===e?t:"body"===e?t.body:null}getBaseHref(t){const e=function Pq(){return Cg=Cg||document.querySelector("base"),Cg?Cg.getAttribute("href"):null}();return null==e?null:function zq(n){return new URL(n,document.baseURI).pathname}(e)}resetBaseElement(){Cg=null}getUserAgent(){return window.navigator.userAgent}getCookie(t){return function xX(n,t){t=encodeURIComponent(t);for(const e of n.split(";")){const i=e.indexOf("="),[r,s]=-1==i?[e,""]:[e.slice(0,i),e.slice(i+1)];if(r.trim()===t)return decodeURIComponent(s)}return null}(document.cookie,t)}}let Cg=null,Hq=(()=>{class n{build(){return new XMLHttpRequest}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();const aC=new Ht("");let vz=(()=>{class n{constructor(e,i){this._zone=i,this._eventNameToPlugin=new Map,e.forEach(r=>{r.manager=this}),this._plugins=e.slice().reverse()}addEventListener(e,i,r){return this._findPluginFor(i).addEventListener(e,i,r)}getZone(){return this._zone}_findPluginFor(e){let i=this._eventNameToPlugin.get(e);if(i)return i;if(i=this._plugins.find(s=>s.supports(e)),!i)throw new F(5101,!1);return this._eventNameToPlugin.set(e,i),i}static{this.\u0275fac=function(i){return new(i||n)(_i(aC),_i(Rr))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();class mz{constructor(t){this._doc=t}}const lC="ng-app-id";let yz=(()=>{class n{constructor(e,i,r,s={}){this.doc=e,this.appId=i,this.nonce=r,this.platformId=s,this.styleRef=new Map,this.hostNodes=new Set,this.styleNodesInDOM=this.collectServerRenderedStyles(),this.platformIsServer=uz(s),this.resetHostNodes()}addStyles(e){for(const i of e)1===this.changeUsageCount(i,1)&&this.onStyleAdded(i)}removeStyles(e){for(const i of e)this.changeUsageCount(i,-1)<=0&&this.onStyleRemoved(i)}ngOnDestroy(){const e=this.styleNodesInDOM;e&&(e.forEach(i=>i.remove()),e.clear());for(const i of this.getAllStyles())this.onStyleRemoved(i);this.resetHostNodes()}addHost(e){this.hostNodes.add(e);for(const i of this.getAllStyles())this.addStyleToHost(e,i)}removeHost(e){this.hostNodes.delete(e)}getAllStyles(){return this.styleRef.keys()}onStyleAdded(e){for(const i of this.hostNodes)this.addStyleToHost(i,e)}onStyleRemoved(e){const i=this.styleRef;i.get(e)?.elements?.forEach(r=>r.remove()),i.delete(e)}collectServerRenderedStyles(){const e=this.doc.head?.querySelectorAll(`style[${lC}="${this.appId}"]`);if(e?.length){const i=new Map;return e.forEach(r=>{null!=r.textContent&&i.set(r.textContent,r)}),i}return null}changeUsageCount(e,i){const r=this.styleRef;if(r.has(e)){const s=r.get(e);return s.usage+=i,s.usage}return r.set(e,{usage:i,elements:[]}),i}getStyleElement(e,i){const r=this.styleNodesInDOM,s=r?.get(i);if(s?.parentNode===e)return r.delete(i),s.removeAttribute(lC),s;{const o=this.doc.createElement("style");return this.nonce&&o.setAttribute("nonce",this.nonce),o.textContent=i,this.platformIsServer&&o.setAttribute(lC,this.appId),e.appendChild(o),o}}addStyleToHost(e,i){const r=this.getStyleElement(e,i),s=this.styleRef,o=s.get(i)?.elements;o?o.push(r):s.set(i,{elements:[r],usage:1})}resetHostNodes(){const e=this.hostNodes;e.clear(),e.add(this.doc.head)}static{this.\u0275fac=function(i){return new(i||n)(_i(sd),_i(N1),_i(oL,8),_i(Su))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();const hC={svg:"http://www.w3.org/2000/svg",xhtml:"http://www.w3.org/1999/xhtml",xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/",math:"http://www.w3.org/1998/MathML/"},cC=/%COMP%/g,Uq=new Ht("",{providedIn:"root",factory:()=>!0});function Iz(n,t){return t.map(e=>e.replace(cC,n))}let bz=(()=>{class n{constructor(e,i,r,s,o,a,l,h=null){this.eventManager=e,this.sharedStylesHost=i,this.appId=r,this.removeStylesOnCompDestroy=s,this.doc=o,this.platformId=a,this.ngZone=l,this.nonce=h,this.rendererByCompId=new Map,this.platformIsServer=uz(a),this.defaultRenderer=new dC(e,o,l,this.platformIsServer)}createRenderer(e,i){if(!e||!i)return this.defaultRenderer;this.platformIsServer&&i.encapsulation===ba.ShadowDom&&(i={...i,encapsulation:ba.Emulated});const r=this.getOrCreateRenderer(e,i);return r instanceof wz?r.applyToHost(e):r instanceof uC&&r.applyStyles(),r}getOrCreateRenderer(e,i){const r=this.rendererByCompId;let s=r.get(i.id);if(!s){const o=this.doc,a=this.ngZone,l=this.eventManager,h=this.sharedStylesHost,c=this.removeStylesOnCompDestroy,d=this.platformIsServer;switch(i.encapsulation){case ba.Emulated:s=new wz(l,h,i,this.appId,c,o,a,d);break;case ba.ShadowDom:return new Yq(l,h,e,i,o,a,this.nonce,d);default:s=new uC(l,h,i,c,o,a,d)}r.set(i.id,s)}return s}ngOnDestroy(){this.rendererByCompId.clear()}static{this.\u0275fac=function(i){return new(i||n)(_i(vz),_i(yz),_i(N1),_i(Uq),_i(sd),_i(Su),_i(Rr),_i(oL))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();class dC{constructor(t,e,i,r){this.eventManager=t,this.doc=e,this.ngZone=i,this.platformIsServer=r,this.data=Object.create(null),this.throwOnSyntheticProps=!0,this.destroyNode=null}destroy(){}createElement(t,e){return e?this.doc.createElementNS(hC[e]||e,t):this.doc.createElement(t)}createComment(t){return this.doc.createComment(t)}createText(t){return this.doc.createTextNode(t)}appendChild(t,e){(Mz(t)?t.content:t).appendChild(e)}insertBefore(t,e,i){t&&(Mz(t)?t.content:t).insertBefore(e,i)}removeChild(t,e){t&&t.removeChild(e)}selectRootElement(t,e){let i="string"==typeof t?this.doc.querySelector(t):t;if(!i)throw new F(-5104,!1);return e||(i.textContent=""),i}parentNode(t){return t.parentNode}nextSibling(t){return t.nextSibling}setAttribute(t,e,i,r){if(r){e=r+":"+e;const s=hC[r];s?t.setAttributeNS(s,e,i):t.setAttribute(e,i)}else t.setAttribute(e,i)}removeAttribute(t,e,i){if(i){const r=hC[i];r?t.removeAttributeNS(r,e):t.removeAttribute(`${i}:${e}`)}else t.removeAttribute(e)}addClass(t,e){t.classList.add(e)}removeClass(t,e){t.classList.remove(e)}setStyle(t,e,i,r){r&(ec.DashCase|ec.Important)?t.style.setProperty(e,i,r&ec.Important?"important":""):t.style[e]=i}removeStyle(t,e,i){i&ec.DashCase?t.style.removeProperty(e):t.style[e]=""}setProperty(t,e,i){null!=t&&(t[e]=i)}setValue(t,e){t.nodeValue=e}listen(t,e,i){if("string"==typeof t&&!(t=Vw().getGlobalEventTarget(this.doc,t)))throw new Error(`Unsupported event target ${t} for event ${e}`);return this.eventManager.addEventListener(t,e,this.decoratePreventDefault(i))}decoratePreventDefault(t){return e=>{if("__ngUnwrap__"===e)return t;!1===(this.platformIsServer?this.ngZone.runGuarded(()=>t(e)):t(e))&&e.preventDefault()}}}function Mz(n){return"TEMPLATE"===n.tagName&&void 0!==n.content}class Yq extends dC{constructor(t,e,i,r,s,o,a,l){super(t,s,o,l),this.sharedStylesHost=e,this.hostEl=i,this.shadowRoot=i.attachShadow({mode:"open"}),this.sharedStylesHost.addHost(this.shadowRoot);const h=Iz(r.id,r.styles);for(const c of h){const d=document.createElement("style");a&&d.setAttribute("nonce",a),d.textContent=c,this.shadowRoot.appendChild(d)}}nodeOrShadowRoot(t){return t===this.hostEl?this.shadowRoot:t}appendChild(t,e){return super.appendChild(this.nodeOrShadowRoot(t),e)}insertBefore(t,e,i){return super.insertBefore(this.nodeOrShadowRoot(t),e,i)}removeChild(t,e){return super.removeChild(this.nodeOrShadowRoot(t),e)}parentNode(t){return this.nodeOrShadowRoot(super.parentNode(this.nodeOrShadowRoot(t)))}destroy(){this.sharedStylesHost.removeHost(this.shadowRoot)}}class uC extends dC{constructor(t,e,i,r,s,o,a,l){super(t,s,o,a),this.sharedStylesHost=e,this.removeStylesOnCompDestroy=r,this.styles=l?Iz(l,i.styles):i.styles}applyStyles(){this.sharedStylesHost.addStyles(this.styles)}destroy(){this.removeStylesOnCompDestroy&&this.sharedStylesHost.removeStyles(this.styles)}}class wz extends uC{constructor(t,e,i,r,s,o,a,l){const h=r+"-"+i.id;super(t,e,i,s,o,a,l,h),this.contentAttr=function jq(n){return"_ngcontent-%COMP%".replace(cC,n)}(h),this.hostAttr=function Vq(n){return"_nghost-%COMP%".replace(cC,n)}(h)}applyToHost(t){this.applyStyles(),this.setAttribute(t,this.hostAttr,"")}createElement(t,e){const i=super.createElement(t,e);return super.setAttribute(i,this.contentAttr,""),i}}let Qq=(()=>{class n extends mz{constructor(e){super(e)}supports(e){return!0}addEventListener(e,i,r){return e.addEventListener(i,r,!1),()=>this.removeEventListener(e,i,r)}removeEventListener(e,i,r){return e.removeEventListener(i,r)}static{this.\u0275fac=function(i){return new(i||n)(_i(sd))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();const Cz=["alt","control","meta","shift"],Gq={"\b":"Backspace","\t":"Tab","\x7f":"Delete","\x1b":"Escape",Del:"Delete",Esc:"Escape",Left:"ArrowLeft",Right:"ArrowRight",Up:"ArrowUp",Down:"ArrowDown",Menu:"ContextMenu",Scroll:"ScrollLock",Win:"OS"},Xq={alt:n=>n.altKey,control:n=>n.ctrlKey,meta:n=>n.metaKey,shift:n=>n.shiftKey};let qq=(()=>{class n extends mz{constructor(e){super(e)}supports(e){return null!=n.parseEventName(e)}addEventListener(e,i,r){const s=n.parseEventName(i),o=n.eventCallback(s.fullKey,r,this.manager.getZone());return this.manager.getZone().runOutsideAngular(()=>Vw().onAndCancel(e,s.domEventName,o))}static parseEventName(e){const i=e.toLowerCase().split("."),r=i.shift();if(0===i.length||"keydown"!==r&&"keyup"!==r)return null;const s=n._normalizeKey(i.pop());let o="",a=i.indexOf("code");if(a>-1&&(i.splice(a,1),o="code."),Cz.forEach(h=>{const c=i.indexOf(h);c>-1&&(i.splice(c,1),o+=h+".")}),o+=s,0!=i.length||0===s.length)return null;const l={};return l.domEventName=r,l.fullKey=o,l}static matchEventFullKeyCode(e,i){let r=Gq[e.key]||e.key,s="";return i.indexOf("code.")>-1&&(r=e.code,s="code."),!(null==r||!r)&&(r=r.toLowerCase()," "===r?r="space":"."===r&&(r="dot"),Cz.forEach(o=>{o!==r&&(0,Xq[o])(e)&&(s+=o+".")}),s+=r,s===i)}static eventCallback(e,i,r){return s=>{n.matchEventFullKeyCode(s,e)&&r.runGuarded(()=>i(s))}}static _normalizeKey(e){return"esc"===e?"escape":e}static{this.\u0275fac=function(i){return new(i||n)(_i(sd))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();function Ez(n){return{appProviders:[...i$,...n?.providers??[]],platformProviders:e$}}const e$=[{provide:Su,useValue:"browser"},{provide:sL,useValue:function Zq(){oC.makeCurrent()},multi:!0},{provide:sd,useFactory:function Kq(){return function Aj(n){L1=n}(document),document},deps:[]}],i$=[{provide:C1,useValue:"root"},{provide:nh,useFactory:function Jq(){return new nh},deps:[]},{provide:aC,useClass:Qq,multi:!0,deps:[sd,Rr,Su]},{provide:aC,useClass:qq,multi:!0,deps:[sd]},bz,yz,vz,{provide:sN,useExisting:bz},{provide:class cq{},useClass:Hq,deps:[]},[]];var o$=0,fC=!1;function w0(n,t){var e=t;return e.unshift(void 0),new(Function.prototype.bind.apply(n,e))}function Y(n,t){for(var e=t,i=n.replace(/\[/g,".").replace(/\]/g,"").split("."),r=0;r"u"}function Ei(n){return n+"_"+o$++}function E0(n,t){return n===t||!(n===document||!n)&&E0(n.parentNode,t)}function xg(n){try{throw new Error(n)}catch(t){throw new Error(t.message+"\n"+t.stack)}}function Re(n){var t=n+"";return t.match(/auto|cm|mm|in|px|pt|pc|%|em|ex|ch|rem|vw|vh|vmin|vmax/)?t:t+"px"}function ce(){return fC}var Tg,n,t,d$={latn:{_digits:"0123456789",_type:"numeric"}},Lz={decimal:".",group:",",percentSign:"%",plusSign:"+",minusSign:"-",infinity:"\u221e",nan:"NaN",exponential:"E"},Nz=[0,1,2,3,4,5,6,7,8,9],Hr=function(){function n(){}return n.getMainObject=function(t,e){return Y(ce()?e:"main."+e,t)},n.getNumberingSystem=function(t){return Y("supplemental.numberingSystems",t)||this.numberingSystems},n.reverseObject=function(t,e){for(var r={},s=0,o=e||Object.keys(t);s13&&(p+=1,o-=12),o-=1,a=p-4716;var y=u-24e5,S=10631/30,b=u-1948084,M=Math.floor(b/10631);b-=10631*M;var w=Math.floor((b-.1335)/S),C=30*M+w;b-=Math.floor(w*S+.1335);var D=Math.floor((b+28.5001)/29.5);13===D&&(D=12);for(var A=b-Math.floor(29.5001*D-29),x=0;xy);x++);var P=x+16260,L=Math.floor((P-1)/12),O=L+1,N=P-12*L,T=y-t[x-1]+1;return(T+"").length>2&&(T=A,N=D,O=C),{year:O,month:N,date:T}},n.toGregorian=function i(r,s,o){var g=Math.floor(o+t[12*(r-1)+1+(s-1)-16260-1]-1+24e5+.5),v=Math.floor((g-1867216.25)/36524.25),y=1524+(v=g+1+v-Math.floor(v/4)),S=Math.floor((y-122.1)/365.25),b=Math.floor(365.25*S),M=Math.floor((y-b)/30.6001),w=y-b-Math.floor(30.6001*M),C=M-(M>13.5?13:1),D=S-(C>2.5?4716:4715);return D<=0&&C--,new Date(D+"/"+C+"/"+w)};var ut,p$=/\/MMMMM|MMMM|MMM|a|LLLL|LLL|EEEEE|EEEE|E|K|cccc|ccc|WW|W|G+|z+/gi,Oz="stand-alone",g$=["sun","mon","tue","wed","thu","fri","sat"],kz={m:"getMinutes",h:"getHours",H:"getHours",s:"getSeconds",d:"getDate",f:"getMilliseconds"},Pz=function(){function n(){}return n.dateFormat=function(t,e,i){var r=this,s=ut.getDependables(i,t,e.calendar),o=Y("parserObject.numbers",s),a=s.dateObject,l={isIslamic:ut.islamicRegex.test(e.calendar)};ce()&&e.isServerRendered&&(e=ut.compareBlazorDateFormats(e,t));var h=e.format||ut.getResultantPattern(e.skeleton,s.dateObject,e.type,!1,ce()?t:"");if(l.dateSeperator=ce()?Y("dateSeperator",a):ut.getDateSeparator(s.dateObject),st(h))xg("Format options or type given must be invalid");else{h=ut.ConvertDateToWeekFormat(h),ce()&&(h=h.replace(/tt/,"a")),l.pattern=h,l.numMapper=ce()?ze({},o):Hr.getNumberMapper(s.parserObject,Hr.getNumberingSystem(i));for(var d=0,u=h.match(p$)||[];d2?r+=e.month[""+u]:p=!0;break;case"E":case"c":r+=e.weekday[""+g$[t.getDay()]];break;case"H":case"h":case"m":case"s":case"d":case"f":if(p=!0,"d"===d)u=o.date;else if("f"===d){p=!1,g=!0;var y=(f=(f=t[""+kz[""+d]]().toString()).substring(0,c)).length;if(c!==y){if(c>3)continue;for(var S=0;S0?1:0],o=Math.abs(t);return s.replace(/HH?|mm/g,function(a){var l=a.length,h=-1!==a.indexOf("H");return i.checkTwodigitNumber(Math.floor(h?o/60:o%60),l)})},n}(),zz={ms:"minimumSignificantDigits",ls:"maximumSignificantDigits",mf:"minimumFractionDigits",lf:"maximumFractionDigits"},nf=["infinity","nan","group","decimal","exponential"],Rz=function(){function n(){}return n.numberFormatter=function(t,e,i){var l,r=this,s=ze({},e),o={},a={},h=ut.getDependables(i,t,"",!0),c=h.numericObject;a.numberMapper=ce()?ze({},c):Hr.getNumberMapper(h.parserObject,Hr.getNumberingSystem(i),!0),a.currencySymbol=ce()?Y("currencySymbol",c):ut.getCurrencySymbol(h.numericObject,s.currency||Ng,e.altSymbol,e.ignoreCurrency),a.percentSymbol=ce()?Y("numberSymbols.percentSign",c):a.numberMapper.numberSymbols.percentSign,a.minusSymbol=ce()?Y("numberSymbols.minusSign",c):a.numberMapper.numberSymbols.minusSign;var d=a.numberMapper.numberSymbols;if(e.format&&!ut.formatRegex.test(e.format))o=ut.customFormat(e.format,a,h.numericObject),!st(s.useGrouping)&&s.useGrouping&&(s.useGrouping=o.pData.useGrouping);else{if(ze(s,ut.getProperNumericSkeleton(e.format||"N")),s.isCurrency="currency"===s.type,s.isPercent="percent"===s.type,ce()||(l=ut.getSymbolPattern(s.type,a.numberMapper.numberSystem,h.numericObject,s.isAccount)),s.groupOne=this.checkValueRange(s.maximumSignificantDigits,s.minimumSignificantDigits,!0),this.checkValueRange(s.maximumFractionDigits,s.minimumFractionDigits,!1,!0),st(s.fractionDigits)||(s.minimumFractionDigits=s.maximumFractionDigits=s.fractionDigits),st(s.useGrouping)&&(s.useGrouping=!0),s.isCurrency&&!ce()&&(l=l.replace(/\u00A4/g,ut.defaultCurrency)),ce())o.nData=ze({},{},Y(s.type+"nData",c)),o.pData=ze({},{},Y(s.type+"pData",c)),"currency"===s.type&&e.currency&&ut.replaceBlazorCurrency([o.pData,o.nData],a.currencySymbol,e.currency);else{var u=l.split(";");o.nData=ut.getFormatData(u[1]||"-"+u[0],!0,a.currencySymbol),o.pData=ut.getFormatData(u[0],!1,a.currencySymbol),s.useGrouping&&(s.groupSeparator=d[nf[2]],s.groupData=this.getGroupingDetails(u[0]))}if(st(s.minimumFractionDigits)&&(s.minimumFractionDigits=o.nData.minimumFraction),st(s.maximumFractionDigits)){var p=o.nData.maximumFraction;s.maximumFractionDigits=st(p)&&s.isPercent?0:p}var g=s.minimumFractionDigits,v=s.maximumFractionDigits;!st(g)&&!st(v)&&g>v&&(s.maximumFractionDigits=g)}return ze(o.nData,s),ze(o.pData,s),function(y){return isNaN(y)?d[nf[1]]:isFinite(y)?r.intNumberFormatter(y,o,a,e):d[nf[0]]}},n.getGroupingDetails=function(t){var e={},i=t.match(ut.negativeDataRegex);if(i&&i[4]){var r=i[4],s=r.lastIndexOf(",");if(-1!==s){var o=r.split(".")[0];e.primary=o.length-s-1;var a=r.lastIndexOf(",",s-1);-1!==a&&(e.secondary=s-1-a)}}return e},n.checkValueRange=function(t,e,i,r){var s=r?"f":"s",o=0,a=zz["l"+s],l=zz["m"+s];if(st(t)||(this.checkRange(t,a,r),o++),st(e)||(this.checkRange(e,l,r),o++),2===o){if(!(tr[1])&&xg(e+"value must be within the range"+r[0]+"to"+r[1])},n.intNumberFormatter=function(t,e,i,r){var s;if(!st(e.nData.type)){t<0?(t*=-1,s=e.nData):s=0===t&&e.zeroData||e.pData;var o="";if(s.isPercent&&(t*=100),s.groupOne)o=this.processSignificantDigits(t,s.minimumSignificantDigits,s.maximumSignificantDigits);else if(o=this.processFraction(t,s.minimumFractionDigits,s.maximumFractionDigits,r),s.minimumIntegerDigits&&(o=this.processMinimumIntegers(o,s.minimumIntegerDigits)),i.isCustomFormat&&s.minimumFractionDigits=0&&"0"===l[parseInt(c.toString(),10)]&&c>=s.minimumFractionDigits;c--)l=l.slice(0,c);o=a[0]+"."+l}return"scientific"===s.type&&(o=(o=t.toExponential(s.maximumFractionDigits)).replace("e",i.numberMapper.numberSymbols[nf[4]])),o=o.replace(".",i.numberMapper.numberSymbols[nf[3]]),o="#,###,,;(#,###,,)"===s.format?this.customPivotFormat(parseInt(o,10)):o,s.useGrouping&&(o=this.groupNumbers(o,s.groupData.primary,s.groupSeparator||",",i.numberMapper.numberSymbols[nf[3]]||".",s.groupData.secondary)),o=Hr.convertValueParts(o,ut.latnParseRegex,i.numberMapper.mapper),"N/A"===s.nlead?s.nlead:"0"===o&&r&&"0"===r.format?o+s.nend:s.nlead+o+s.nend}},n.processSignificantDigits=function(t,e,i){var r=t+"";return r.lengthe;)c=l.slice(h-e,h)+(c.length?i+c:""),h-=e,o&&(e=s,o=!1);return a[0]=l.slice(0,h)+(c.length?i:"")+c,a.join(r)},n.processFraction=function(t,e,i,r){var s=(t+"").split(".")[1],o=s?s.length:0;if(e&&oi||0===i))return t.toFixed(i);var h=t+"";return"0"===h[0]&&r&&"###.00"===r.format&&(h=h.slice(1)),h},n.processMinimumIntegers=function(t,e){var i=t.split("."),r=i[0],s=r.length;if(s=5e5){var r=(t/=1e6).toString().split(".")[1];return r&&+r.substring(0,1)>=5?Math.ceil(t).toString():Math.floor(t).toString()}return""},n}(),Ag=(new RegExp("^([^0-9]*)(([0-9,]*[0-9]+)(.[0-9]+)?)([Ee][+-]?[0-9]+)?([^0-9]*)$"),function(){function n(t){this.ranArray=[],this.boundedEvents={},!m(t)&&(this.context=t)}return n.prototype.on=function(t,e,i,r){if(!m(e)){var s=i||this.context;if(this.notExist(t))return void(this.boundedEvents[""+t]=[{handler:e,context:s,id:r}]);m(r)?this.isHandlerPresent(this.boundedEvents[""+t],e)||this.boundedEvents[""+t].push({handler:e,context:s}):-1===this.ranArray.indexOf(r)&&(this.ranArray.push(r),this.boundedEvents[""+t].push({handler:e,context:s,id:r}))}},n.prototype.off=function(t,e,i){if(!this.notExist(t)){var r=Y(t,this.boundedEvents);if(e){for(var s=0;s1&&(U.fractionDigits=parseInt(z[2],10)),U}function p(T,z,U,B){var j=B?{}:{nlead:"",nend:""},Q=T.match(n.customRegex);if(Q){B||(j.nlead=g(Q[1],U),j.nend=g(Q[10],U),j.groupPattern=Q[4]);var oe=Q[7];if(oe&&z){var ue=oe.match(t);j.minimumFraction=m(ue)?0:ue.length,j.maximumFraction=oe.length-1}}return j}function g(T,z){return T?(T=T.replace(n.defaultCurrency,z),""===z?T.trim():T):""}function v(T,z,U,B){return B?"$":Y("currencies."+z+(U?"."+U:".symbol"),T)||Y("currencies."+z+".symbol-alt-narrow",T)||"$"}function S(T,z,U){var B={type:"decimal",minimumFractionDigits:0,maximumFractionDigits:0},j=T.match(n.customRegex);if(m(j)||""===j[5]&&"N/A"!==T)return B.type=void 0,B;B.nlead=j[1],B.nend=j[10];var Q=j[6],oe=!!Q.match(/ $/g),ue=-1!==Q.replace(/ $/g,"").indexOf(" ");B.useGrouping=-1!==Q.indexOf(",")||ue,Q=Q.replace(/,/g,"");var fe=j[7];if(-1!==Q.indexOf("0")&&(B.minimumIntegerDigits=Q.length-Q.indexOf("0")),m(fe)||(B.minimumFractionDigits=fe.lastIndexOf("0"),B.maximumFractionDigits=fe.lastIndexOf("#"),-1===B.minimumFractionDigits&&(B.minimumFractionDigits=0),(-1===B.maximumFractionDigits||B.maximumFractionDigitsQ.lastIndexOf("'"))){B[""+a[parseInt(j.toString(),10)]]=Q.substr(0,oe)+U+Q.substr(oe+1),B[""+a[""+z]]=!0,B.type=B.isCurrency?"currency":"percent";break}}return B}function C(T,z){if(-1!==T.indexOf(",")){var U=T.split(",");T=U[0]+Y("numberMapper.numberSymbols.group",z)+U[1].replace(".",Y("numberMapper.numberSymbols.decimal",z))}else T=T.replace(".",Y("numberMapper.numberSymbols.decimal",z));return T}function A(T,z,U){T+=".";for(var B=0;B0;Q-=3)T=","+U[Q-2]+U[Q-1]+U[parseInt(Q.toString(),10)]+T;return T=T.slice(1),z[1]?T+"."+z[1]:T}n.dateParseRegex=/([a-z])\1*|'([^']|'')+'|''|./gi,n.basicPatterns=["short","medium","long","full"],n.defaultObject={dates:{calendars:{gregorian:{months:{"stand-alone":{abbreviated:{1:"Jan",2:"Feb",3:"Mar",4:"Apr",5:"May",6:"Jun",7:"Jul",8:"Aug",9:"Sep",10:"Oct",11:"Nov",12:"Dec"},narrow:{1:"J",2:"F",3:"M",4:"A",5:"M",6:"J",7:"J",8:"A",9:"S",10:"O",11:"N",12:"D"},wide:{1:"January",2:"February",3:"March",4:"April",5:"May",6:"June",7:"July",8:"August",9:"September",10:"October",11:"November",12:"December"}}},days:{"stand-alone":{abbreviated:{sun:"Sun",mon:"Mon",tue:"Tue",wed:"Wed",thu:"Thu",fri:"Fri",sat:"Sat"},narrow:{sun:"S",mon:"M",tue:"T",wed:"W",thu:"T",fri:"F",sat:"S"},short:{sun:"Su",mon:"Mo",tue:"Tu",wed:"We",thu:"Th",fri:"Fr",sat:"Sa"},wide:{sun:"Sunday",mon:"Monday",tue:"Tuesday",wed:"Wednesday",thu:"Thursday",fri:"Friday",sat:"Saturday"}}},dayPeriods:{format:{wide:{am:"AM",pm:"PM"}}},eras:{eraNames:{0:"Before Christ","0-alt-variant":"Before Common Era",1:"Anno Domini","1-alt-variant":"Common Era"},eraAbbr:{0:"BC","0-alt-variant":"BCE",1:"AD","1-alt-variant":"CE"},eraNarrow:{0:"B","0-alt-variant":"BCE",1:"A","1-alt-variant":"CE"}},dateFormats:{full:"EEEE, MMMM d, y",long:"MMMM d, y",medium:"MMM d, y",short:"M/d/yy"},timeFormats:{full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},dateTimeFormats:{full:"{1} 'at' {0}",long:"{1} 'at' {0}",medium:"{1}, {0}",short:"{1}, {0}",availableFormats:{d:"d",E:"ccc",Ed:"d E",Ehm:"E h:mm a",EHm:"E HH:mm",Ehms:"E h:mm:ss a",EHms:"E HH:mm:ss",Gy:"y G",GyMMM:"MMM y G",GyMMMd:"MMM d, y G",GyMMMEd:"E, MMM d, y G",h:"h a",H:"HH",hm:"h:mm a",Hm:"HH:mm",hms:"h:mm:ss a",Hms:"HH:mm:ss",hmsv:"h:mm:ss a v",Hmsv:"HH:mm:ss v",hmv:"h:mm a v",Hmv:"HH:mm v",M:"L",Md:"M/d",MEd:"E, M/d",MMM:"LLL",MMMd:"MMM d",MMMEd:"E, MMM d",MMMMd:"MMMM d",ms:"mm:ss",y:"y",yM:"M/y",yMd:"M/d/y",yMEd:"E, M/d/y",yMMM:"MMM y",yMMMd:"MMM d, y",yMMMEd:"E, MMM d, y",yMMMM:"MMMM y"}}},islamic:{months:{"stand-alone":{abbreviated:{1:"Muh.",2:"Saf.",3:"Rab. I",4:"Rab. II",5:"Jum. I",6:"Jum. II",7:"Raj.",8:"Sha.",9:"Ram.",10:"Shaw.",11:"Dhu\u02bbl-Q.",12:"Dhu\u02bbl-H."},narrow:{1:"1",2:"2",3:"3",4:"4",5:"5",6:"6",7:"7",8:"8",9:"9",10:"10",11:"11",12:"12"},wide:{1:"Muharram",2:"Safar",3:"Rabi\u02bb I",4:"Rabi\u02bb II",5:"Jumada I",6:"Jumada II",7:"Rajab",8:"Sha\u02bbban",9:"Ramadan",10:"Shawwal",11:"Dhu\u02bbl-Qi\u02bbdah",12:"Dhu\u02bbl-Hijjah"}}},days:{"stand-alone":{abbreviated:{sun:"Sun",mon:"Mon",tue:"Tue",wed:"Wed",thu:"Thu",fri:"Fri",sat:"Sat"},narrow:{sun:"S",mon:"M",tue:"T",wed:"W",thu:"T",fri:"F",sat:"S"},short:{sun:"Su",mon:"Mo",tue:"Tu",wed:"We",thu:"Th",fri:"Fr",sat:"Sa"},wide:{sun:"Sunday",mon:"Monday",tue:"Tuesday",wed:"Wednesday",thu:"Thursday",fri:"Friday",sat:"Saturday"}}},dayPeriods:{format:{wide:{am:"AM",pm:"PM"}}},eras:{eraNames:{0:"AH"},eraAbbr:{0:"AH"},eraNarrow:{0:"AH"}},dateFormats:{full:"EEEE, MMMM d, y G",long:"MMMM d, y G",medium:"MMM d, y G",short:"M/d/y GGGGG"},timeFormats:{full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},dateTimeFormats:{full:"{1} 'at' {0}",long:"{1} 'at' {0}",medium:"{1}, {0}",short:"{1}, {0}",availableFormats:{d:"d",E:"ccc",Ed:"d E",Ehm:"E h:mm a",EHm:"E HH:mm",Ehms:"E h:mm:ss a",EHms:"E HH:mm:ss",Gy:"y G",GyMMM:"MMM y G",GyMMMd:"MMM d, y G",GyMMMEd:"E, MMM d, y G",h:"h a",H:"HH",hm:"h:mm a",Hm:"HH:mm",hms:"h:mm:ss a",Hms:"HH:mm:ss",M:"L",Md:"M/d",MEd:"E, M/d",MMM:"LLL",MMMd:"MMM d",MMMEd:"E, MMM d",MMMMd:"MMMM d",ms:"mm:ss",y:"y G",yyyy:"y G",yyyyM:"M/y GGGGG",yyyyMd:"M/d/y GGGGG",yyyyMEd:"E, M/d/y GGGGG",yyyyMMM:"MMM y G",yyyyMMMd:"MMM d, y G",yyyyMMMEd:"E, MMM d, y G",yyyyMMMM:"MMMM y G",yyyyQQQ:"QQQ y G",yyyyQQQQ:"QQQQ y G"}}}},timeZoneNames:{hourFormat:"+HH:mm;-HH:mm",gmtFormat:"GMT{0}",gmtZeroFormat:"GMT"}},numbers:{currencies:{USD:{displayName:"US Dollar",symbol:"$","symbol-alt-narrow":"$"},EUR:{displayName:"Euro",symbol:"\u20ac","symbol-alt-narrow":"\u20ac"},GBP:{displayName:"British Pound","symbol-alt-narrow":"\xa3"}},defaultNumberingSystem:"latn",minimumGroupingDigits:"1","symbols-numberSystem-latn":{decimal:".",group:",",list:";",percentSign:"%",plusSign:"+",minusSign:"-",exponential:"E",superscriptingExponent:"\xd7",perMille:"\u2030",infinity:"\u221e",nan:"NaN",timeSeparator:":"},"decimalFormats-numberSystem-latn":{standard:"#,##0.###"},"percentFormats-numberSystem-latn":{standard:"#,##0%"},"currencyFormats-numberSystem-latn":{standard:"\xa4#,##0.00",accounting:"\xa4#,##0.00;(\xa4#,##0.00)"},"scientificFormats-numberSystem-latn":{standard:"#E0"}}},n.blazorDefaultObject={numbers:{mapper:{0:"0",1:"1",2:"2",3:"3",4:"4",5:"5",6:"6",7:"7",8:"8",9:"9"},mapperDigits:"0123456789",numberSymbols:{decimal:".",group:",",plusSign:"+",minusSign:"-",percentSign:"%",nan:"NaN",timeSeparator:":",infinity:"\u221e"},timeSeparator:":",currencySymbol:"$",currencypData:{nlead:"$",nend:"",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},percentpData:{nlead:"",nend:"%",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},percentnData:{nlead:"-",nend:"%",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},currencynData:{nlead:"($",nend:")",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},decimalnData:{nlead:"-",nend:"",groupData:{primary:3},maximumFraction:2,minimumFraction:2},decimalpData:{nlead:"",nend:"",groupData:{primary:3},maximumFraction:2,minimumFraction:2}},dates:{dayPeriods:{am:"AM",pm:"PM"},dateSeperator:"/",days:{abbreviated:{sun:"Sun",mon:"Mon",tue:"Tue",wed:"Wed",thu:"Thu",fri:"Fri",sat:"Sat"},short:{sun:"Su",mon:"Mo",tue:"Tu",wed:"We",thu:"Th",fri:"Fr",sat:"Sa"},wide:{sun:"Sunday",mon:"Monday",tue:"Tuesday",wed:"Wednesday",thu:"Thursday",fri:"Friday",sat:"Saturday"}},months:{abbreviated:{1:"Jan",2:"Feb",3:"Mar",4:"Apr",5:"May",6:"Jun",7:"Jul",8:"Aug",9:"Sep",10:"Oct",11:"Nov",12:"Dec"},wide:{1:"January",2:"February",3:"March",4:"April",5:"May",6:"June",7:"July",8:"August",9:"September",10:"October",11:"November",12:"December"}},eras:{1:"AD"}}},n.monthIndex={3:"abbreviated",4:"wide",5:"narrow",1:"abbreviated"},n.month="months",n.days="days",n.patternMatcher={C:"currency",P:"percent",N:"decimal",A:"currency",E:"scientific"},n.getResultantPattern=l,n.getDependables=h,n.getSymbolPattern=c,n.ConvertDateToWeekFormat=d,n.compareBlazorDateFormats=u,n.getProperNumericSkeleton=f,n.getFormatData=p,n.changeCurrencySymbol=g,n.getCurrencySymbol=v,n.customFormat=function y(T,z,U){for(var B={},j=T.split(";"),Q=["pData","nData","zeroData"],oe=0;oe1,fe.nData=ce()?Y(De.type+"nData",oe):p(ot[1]||"-"+ot[0],!0,Ie),fe.pData=ce()?Y(De.type+"pData",oe):p(ot[0],!1,Ie),!Me[2]&&!z.minimumFractionDigits&&!z.maximumFractionDigits&&(ue=p(Ve.split(";")[0],!0,"",!0).minimumFraction)}if(n.formatRegex.test(z.format)||!z.format){if(ze(Q,f(z.format||"N")),Q.custom=!1,$e="###0",(Q.fractionDigits||z.minimumFractionDigits||z.maximumFractionDigits||ue)&&(Q.fractionDigits&&(z.minimumFractionDigits=z.maximumFractionDigits=Q.fractionDigits),$e=A($e,ue||Q.fractionDigits||z.minimumFractionDigits||0,z.maximumFractionDigits||0)),z.minimumIntegerDigits&&($e=x($e,z.minimumIntegerDigits)),z.useGrouping&&($e=P($e)),"currency"===Q.type||Q.type&&ce()){ce()&&"currency"!==Q.type&&(fe.pData=Y(Q.type+"pData",oe),fe.nData=Y(Q.type+"nData",oe));var hr=$e;$e=fe.pData.nlead+hr+fe.pData.nend,(fe.hasNegativePattern||ce())&&($e+=";"+fe.nData.nlead+hr+fe.nData.nend)}"percent"===Q.type&&!ce()&&($e+=" %")}else $e=z.format.replace(/'/g,'"');return Object.keys(xe).length>0&&($e=B?$e:C($e,xe)),$e},n.fractionDigitsPattern=A,n.minimumIntegerPattern=x,n.groupingPattern=P,n.getWeekData=function L(T,z){var U="sun",B=Y("supplemental.weekData.firstDay",z),j=T;return/en-/.test(j)&&(j=j.slice(3)),j=j.slice(0,2).toUpperCase()+j.substr(2),B&&(U=B[""+j]||B[j.slice(0,2)]||"sun"),o[""+U]},n.replaceBlazorCurrency=function O(T,z,U){var B=function f$(n){return Y(n||"",u$)}(U);if(z!==B)for(var j=0,Q=T;j=0?U:U+7;var j=Math.floor((T.getTime()-z.getTime()-6e4*(T.getTimezoneOffset()-z.getTimezoneOffset()))/864e5)+1;if(U<4){if((B=Math.floor((j+U-1)/7)+1)>52){var oe=new Date(T.getFullYear()+1,0,1).getDay();B=(oe=oe>=0?oe:oe+7)<4?1:53}}else B=Math.floor((j+U-1)/7);return B}}(ut||(ut={}));var sf=function(){function n(t,e,i){this.type="GET",this.emitError=!0,"string"==typeof t?(this.url=t,this.type=m(e)?this.type:e.toUpperCase(),this.contentType=i):La(t)&&Object.keys(t).length>0&&kn(this,t),this.contentType=m(this.contentType)?"application/json; charset=utf-8":this.contentType}return n.prototype.send=function(t){var e=this,i={"application/json":"json","multipart/form-data":"formData","application/octet-stream":"blob","application/x-www-form-urlencoded":"formData"};try{m(this.fetchRequest)&&"GET"===this.type?this.fetchRequest=new Request(this.url,{method:this.type}):m(this.fetchRequest)&&(this.data=m(t)?this.data:t,this.fetchRequest=new Request(this.url,{method:this.type,headers:{"Content-Type":this.contentType},body:this.data}));var r={cancel:!1,fetchRequest:this.fetchRequest};return this.triggerEvent(this.beforeSend,r),r.cancel?null:(this.fetchResponse=fetch(this.fetchRequest),this.fetchResponse.then(function(s){if(e.triggerEvent(e.onLoad,s),!s.ok)throw s;for(var o="text",a=0,l=Object.keys(i);a-1},n.getValue=function(t,e){var i=typeof window<"u"?window.browserDetails:{};return typeof navigator<"u"&&"MacIntel"===navigator.platform&&navigator.maxTouchPoints>1&&!0===n.isTouch&&!vC.CHROME.test(navigator.userAgent)&&(i.isIos=!0,i.isDevice=!0,i.isTouch=!0,i.isPointer=!0,i.isPointer="pointerEnabled"in window.navigator),typeof window<"u"&&window.Capacitor&&"ios"===window.Capacitor.getPlatform()&&(i.isPointer=!1),typeof i[""+t]>"u"?i[""+t]=e.test(n.userAgent):i[""+t]},Object.defineProperty(n,"userAgent",{get:function(){return n.uA},set:function(t){n.uA=t,window.browserDetails={}},enumerable:!0,configurable:!0}),Object.defineProperty(n,"info",{get:function(){return st(window.browserDetails.info)?window.browserDetails.info=n.extractBrowserDetail():window.browserDetails.info},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isIE",{get:function(){return n.getValue("isIE",A$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isTouch",{get:function(){return st(window.browserDetails.isTouch)?window.browserDetails.isTouch="ontouchstart"in window.navigator||window&&window.navigator&&window.navigator.maxTouchPoints>0||"ontouchstart"in window:window.browserDetails.isTouch},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isPointer",{get:function(){return st(window.browserDetails.isPointer)?window.browserDetails.isPointer="pointerEnabled"in window.navigator:window.browserDetails.isPointer},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isMSPointer",{get:function(){return st(window.browserDetails.isMSPointer)?window.browserDetails.isMSPointer="msPointerEnabled"in window.navigator:window.browserDetails.isMSPointer},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isDevice",{get:function(){return n.getValue("isDevice",T$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isIos",{get:function(){return n.getValue("isIos",N$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isIos7",{get:function(){return n.getValue("isIos7",O$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isAndroid",{get:function(){return n.getValue("isAndroid",k$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isWebView",{get:function(){return st(window.browserDetails.isWebView)&&(window.browserDetails.isWebView=!(st(window.cordova)&&st(window.PhoneGap)&&st(window.phonegap)&&"object"!==window.forge)),window.browserDetails.isWebView},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isWindows",{get:function(){return n.getValue("isWindows",P$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"touchStartEvent",{get:function(){return st(window.browserDetails.touchStartEvent)?window.browserDetails.touchStartEvent=n.getTouchStartEvent():window.browserDetails.touchStartEvent},enumerable:!0,configurable:!0}),Object.defineProperty(n,"touchMoveEvent",{get:function(){return st(window.browserDetails.touchMoveEvent)?window.browserDetails.touchMoveEvent=n.getTouchMoveEvent():window.browserDetails.touchMoveEvent},enumerable:!0,configurable:!0}),Object.defineProperty(n,"touchEndEvent",{get:function(){return st(window.browserDetails.touchEndEvent)?window.browserDetails.touchEndEvent=n.getTouchEndEvent():window.browserDetails.touchEndEvent},enumerable:!0,configurable:!0}),Object.defineProperty(n,"touchCancelEvent",{get:function(){return st(window.browserDetails.touchCancelEvent)?window.browserDetails.touchCancelEvent=n.getTouchCancelEvent():window.browserDetails.touchCancelEvent},enumerable:!0,configurable:!0}),n.uA=typeof navigator<"u"?navigator.userAgent:"",n}(),E=function(){function n(){}return n.addOrGetEventData=function(t){return"__eventList"in t?t.__eventList.events:(t.__eventList={},t.__eventList.events=[])},n.add=function(t,e,i,r,s){var a,o=n.addOrGetEventData(t);a=s?function l$(n,t){var e;return function(){for(var i=this,r=[],s=0;s"u"||(e.innerHTML=t.innerHTML?t.innerHTML:"",void 0!==t.className&&(e.className=t.className),void 0!==t.id&&(e.id=t.id),void 0!==t.styles&&e.setAttribute("style",t.styles),void 0!==t.attrs&&Fe(e,t.attrs)),e}function V(n,t){for(var e=Vz(t),i=RegExp,r=0,s=n;r0}function gl(n,t,e){for(var i=document.createDocumentFragment(),r=0,s=n;r0;)i.appendChild(n[0]);else for(var r=0,s=n;r-1&&!r[parseInt(s.toString(),10)].match(/\[.*\]/)){var o=r[parseInt(s.toString(),10)].split("#");if(o[1].match(/^\d/)||o[1].match(t)){var a=r[parseInt(s.toString(),10)].split(".");a[0]=a[0].replace(/#/,"[id='")+"']",r[parseInt(s.toString(),10)]=a.join(".")}}e[parseInt(i.toString(),10)]=r.join(" ")}return e.join(",")}return n}function J(n,t){var e=n;if("function"==typeof e.closest)return e.closest(t);for(;e&&1===e.nodeType;){if(mC(e,t))return e;e=e.parentNode}return null}function je(n,t){void 0!==t&&Object.keys(t).forEach(function(e){n.style[""+e]=t[""+e]})}function mC(n,t){var e=n.matches||n.msMatchesSelector||n.webkitMatchesSelector;return e?e.call(n,t):-1!==[].indexOf.call(document.querySelectorAll(t),n)}var H$=new RegExp("]"),dh=function(){function n(t,e){this.isRendered=!1,this.isComplexArraySetter=!1,this.isServerRendered=!1,this.allowServerDataBinding=!0,this.isProtectedOnChange=!0,this.properties={},this.changedProperties={},this.oldProperties={},this.bulkChanges={},this.refreshing=!1,this.ignoreCollectionWatch=!1,this.finalUpdate=function(){},this.childChangedProperties={},this.modelObserver=new Ag(this),st(e)||(this.element="string"==typeof e?document.querySelector(e):e,m(this.element)||(this.isProtectedOnChange=!1,this.addInstance())),st(t)||this.setProperties(t,!0),this.isDestroyed=!1}return n.prototype.setProperties=function(t,e){var i=this.isProtectedOnChange;this.isProtectedOnChange=!!e,kn(this,t),!0!==e?(kn(this.changedProperties,t),this.dataBind()):ce()&&this.isRendered&&this.serverDataBind(t),this.finalUpdate(),this.changedProperties={},this.oldProperties={},this.isProtectedOnChange=i},n.callChildDataBind=function(t,e){for(var r=0,s=Object.keys(t);r=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Hs=function(n){function t(i){var r=n.call(this,i,void 0)||this;return r.easing={ease:"cubic-bezier(0.250, 0.100, 0.250, 1.000)",linear:"cubic-bezier(0.250, 0.250, 0.750, 0.750)",easeIn:"cubic-bezier(0.420, 0.000, 1.000, 1.000)",easeOut:"cubic-bezier(0.000, 0.000, 0.580, 1.000)",easeInOut:"cubic-bezier(0.420, 0.000, 0.580, 1.000)",elasticInOut:"cubic-bezier(0.5,-0.58,0.38,1.81)",elasticIn:"cubic-bezier(0.17,0.67,0.59,1.81)",elasticOut:"cubic-bezier(0.7,-0.75,0.99,1.01)"},r}var e;return X$(t,n),e=t,t.prototype.animate=function(i,r){var s=this.getModel(r=r||{});if("string"==typeof i)for(var a=0,l=Array.prototype.slice.call(we(i,document));a0?r-1:0,i+=e=-1!==e?"-"+e:"-"+r}return this.controlParent!==this.parentObj&&(i=this.parentObj.getParentKey()+"."+this.propName+e),i},n}(),J$=["grid","pivotview","treegrid","spreadsheet","rangeNavigator","DocumentEditor","listbox","inplaceeditor","PdfViewer","richtexteditor","DashboardLayout","chart","stockChart","circulargauge","diagram","heatmap","lineargauge","maps","slider","smithchart","barcode","sparkline","treemap","bulletChart","kanban","daterangepicker","schedule","gantt","signature","query-builder","drop-down-tree","carousel","filemanager","uploader","accordion","tab","treeview"],tR=[115,121,110,99,102,117,115,105,111,110,46,105,115,76,105,99,86,97,108,105,100,97,116,101,100],iR=function(){function n(t){this.isValidated=!1,this.isLicensed=!0,this.version="27",this.platform=/JavaScript|ASPNET|ASPNETCORE|ASPNETMVC|FileFormats|essentialstudio/i,this.errors={noLicense:"This application was built using a trial version of Syncfusion Essential Studio. To remove the license validation message permanently, a valid license key must be included.",trailExpired:"This application was built using a trial version of Syncfusion Essential Studio. To remove the license validation message permanently, a valid license key must be included.",versionMismatched:"The included Syncfusion license key is invalid.",platformMismatched:"The included Syncfusion license key is invalid.",invalidKey:"The included Syncfusion license key is invalid."},this.manager=function(){var e=null;return{setKey:function i(s){e=s},getKey:function r(){return e}}}(),this.npxManager=function(){return{getKey:function i(){return"npxKeyReplace"}}}(),this.manager.setKey(t)}return n.prototype.validate=function(){if(!this.isValidated&&rf&&!Y(A0(tR),rf)&&!Y("Blazor",rf)){var i=void 0,r=void 0;if(this.manager&&this.manager.getKey()||this.npxManager&&"npxKeyReplace"!==this.npxManager.getKey()){var s=this.getInfoFromKey();if(s&&s.length)for(var o=0,a=s;o"+i+' Claim your FREE account\n
have a Syncfusion account? Sign In
\n
\n ';if(typeof document<"u"&&!m(document)){var t=Si("div",{innerHTML:n});document.body.appendChild(t)}}(),oR=!0),this.render(),this.mount?this.accessMount():this.trigger("created")}},t.prototype.renderComplete=function(e){ce()&&window.sfBlazor.renderComplete(this.element,e),this.isRendered=!0},t.prototype.dataBind=function(){this.injectModules(),n.prototype.dataBind.call(this)},t.prototype.on=function(e,i,r){if("string"==typeof e)this.localObserver.on(e,i,r);else for(var s=0,o=e;s=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},rZ={left:0,top:0,bottom:0,right:0},MC={isDragged:!1},nZ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return aR(t,n),gr([I(0)],t.prototype,"left",void 0),gr([I(0)],t.prototype,"top",void 0),t}(Ee),lf=function(n){function t(i,r){var s=n.call(this,r,i)||this;return s.dragLimit=e.getDefaultPosition(),s.borderWidth=e.getDefaultPosition(),s.padding=e.getDefaultPosition(),s.diffX=0,s.prevLeft=0,s.prevTop=0,s.dragProcessStarted=!1,s.eleTop=0,s.tapHoldTimer=0,s.externalInitialize=!1,s.diffY=0,s.parentScrollX=0,s.parentScrollY=0,s.droppables={},s.bind(),s}var e;return aR(t,n),e=t,t.prototype.bind=function(){this.toggleEvents(),X.isIE&&V([this.element],"e-block-touch"),this.droppables[this.scope]={}},t.getDefaultPosition=function(){return ze({},rZ)},t.prototype.toggleEvents=function(i){var r;st(this.handle)||(r=_(this.handle,this.element));var s=this.enableTapHold&&X.isDevice&&X.isTouch?this.mobileInitialize:this.initialize;i?E.remove(r||this.element,X.isSafari()?"touchstart":X.touchStartEvent,s):E.add(r||this.element,X.isSafari()?"touchstart":X.touchStartEvent,s,this)},t.prototype.mobileInitialize=function(i){var r=this,s=i.currentTarget;this.tapHoldTimer=setTimeout(function(){r.externalInitialize=!0,r.removeTapholdTimer(),r.initialize(i,s)},this.tapHoldThreshold),E.add(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.removeTapholdTimer,this),E.add(document,X.isSafari()?"touchend":X.touchEndEvent,this.removeTapholdTimer,this)},t.prototype.removeTapholdTimer=function(){clearTimeout(this.tapHoldTimer),E.remove(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.removeTapholdTimer),E.remove(document,X.isSafari()?"touchend":X.touchEndEvent,this.removeTapholdTimer)},t.prototype.getScrollableParent=function(i,r){return m(i)?null:i[{vertical:"scrollHeight",horizontal:"scrollWidth"}[""+r]]>i[{vertical:"clientHeight",horizontal:"clientWidth"}[""+r]]&&("vertical"===r?i.scrollTop>0:i.scrollLeft>0)?("vertical"===r?(this.parentScrollY=this.parentScrollY+(0===this.parentScrollY?i.scrollTop:i.scrollTop-this.parentScrollY),this.tempScrollHeight=i.scrollHeight):(this.parentScrollX=this.parentScrollX+(0===this.parentScrollX?i.scrollLeft:i.scrollLeft-this.parentScrollX),this.tempScrollWidth=i.scrollWidth),m(i)?i:this.getScrollableParent(i.parentNode,r)):this.getScrollableParent(i.parentNode,r)},t.prototype.getScrollableValues=function(){this.parentScrollX=0,this.parentScrollY=0,this.element.classList.contains("e-dialog")&&this.element.classList.contains("e-dlg-modal"),this.getScrollableParent(this.element.parentNode,"vertical"),this.getScrollableParent(this.element.parentNode,"horizontal")},t.prototype.initialize=function(i,r){if(this.currentStateTarget=i.target,!this.isDragStarted()){if(this.isDragStarted(!0),this.externalInitialize=!1,this.target=i.currentTarget||r,this.dragProcessStarted=!1,this.abort){var s=this.abort;"string"==typeof s&&(s=[s]);for(var o=0;o=this.distance||this.externalInitialize){var f=this.getHelperElement(i);if(!f||m(f))return;r&&i.preventDefault();var p=this.helperElement=f;if(this.parentClientRect=this.calculateParentPosition(p.offsetParent),this.dragStart){var v={event:i,element:l,target:this.getProperTargetElement(i),bindEvents:ce()?this.bindDragEvents.bind(this):null,dragElement:p};this.trigger("dragStart",v)}this.dragArea?this.setDragArea():(this.dragLimit={left:0,right:0,bottom:0,top:0},this.borderWidth={top:0,left:0}),o={left:this.position.left-this.parentClientRect.left,top:this.position.top-this.parentClientRect.top},this.clone&&!this.enableTailMode&&(this.diffX=this.position.left-this.offset.left,this.diffY=this.position.top-this.offset.top),this.getScrollableValues();var y=getComputedStyle(l),S=parseFloat(y.marginTop);this.clone&&0!==S&&(o.top+=S),this.eleTop=isNaN(parseFloat(y.top))?0:parseFloat(y.top)-this.offset.top,this.enableScrollHandler&&!this.clone&&(o.top-=this.parentScrollY,o.left-=this.parentScrollX);var b=this.getProcessedPositionValue({top:o.top-this.diffY+"px",left:o.left-this.diffX+"px"});this.dragArea&&"string"!=typeof this.dragArea&&this.dragArea.classList.contains("e-kanban-content")&&"relative"===this.dragArea.style.position&&(o.top+=this.dragArea.scrollTop),this.dragElePosition={top:o.top,left:o.left},je(p,this.getDragPosition({position:"absolute",left:b.left,top:b.top})),E.remove(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.intDragStart),E.remove(document,X.isSafari()?"touchend":X.touchEndEvent,this.intDestroy),ce()||this.bindDragEvents(p)}}},t.prototype.bindDragEvents=function(i){Tr(i)?(E.add(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.intDrag,this),E.add(document,X.isSafari()?"touchend":X.touchEndEvent,this.intDragStop,this),this.setGlobalDroppables(!1,this.element,i)):(this.toggleEvents(),document.body.classList.remove("e-prevent-select"))},t.prototype.elementInViewport=function(i){for(this.top=i.offsetTop,this.left=i.offsetLeft,this.width=i.offsetWidth,this.height=i.offsetHeight;i.offsetParent;)this.top+=(i=i.offsetParent).offsetTop,this.left+=i.offsetLeft;return this.top>=window.pageYOffset&&this.left>=window.pageXOffset&&this.top+this.height<=window.pageYOffset+window.innerHeight&&this.left+this.width<=window.pageXOffset+window.innerWidth},t.prototype.getProcessedPositionValue=function(i){return this.queryPositionInfo?this.queryPositionInfo(i):i},t.prototype.calculateParentPosition=function(i){if(m(i))return{left:0,top:0};var r=i.getBoundingClientRect(),s=getComputedStyle(i);return{left:r.left+window.pageXOffset-parseInt(s.marginLeft,10),top:r.top+window.pageYOffset-parseInt(s.marginTop,10)}},t.prototype.intDrag=function(i){if(st(i.changedTouches)||1===i.changedTouches.length){var r,s;this.clone&&i.changedTouches&&X.isDevice&&X.isTouch&&i.preventDefault(),this.position=this.getMousePosition(i,this.isDragScroll);var o=this.getDocumentWidthHeight("Height");oy&&y>0?this.dragLimit.left:this.dragLimit.right+window.pageXOffset0?y-(y-this.dragLimit.right)+window.pageXOffset-M:y<0?this.dragLimit.left:y}if(this.pageY!==v||this.skipDistanceCheck){var w=d.offsetHeight+(parseFloat(b.marginTop)+parseFloat(b.marginBottom));s=this.dragLimit.top>S&&S>0?this.dragLimit.top:this.dragLimit.bottom+window.pageYOffset0?S-(S-this.dragLimit.bottom)+window.pageYOffset-w:S<0?this.dragLimit.top:S}}else r=y,s=S;var A,x,C=f+this.borderWidth.top,D=u+this.borderWidth.left;if(this.dragProcessStarted&&(m(s)&&(s=this.prevTop),m(r)&&(r=this.prevLeft)),this.helperElement.classList.contains("e-treeview"))this.dragArea?(this.dragLimit.top=this.clone?this.dragLimit.top:0,A=s-C<0?this.dragLimit.top:s-this.borderWidth.top,x=r-D<0?this.dragLimit.left:r-this.borderWidth.left):(A=s-this.borderWidth.top,x=r-this.borderWidth.left);else if(this.dragArea){var P=this.helperElement.classList.contains("e-dialog");this.dragLimit.top=this.clone?this.dragLimit.top:0,A=s-C<0?this.dragLimit.top:s-C,x=r-D<0?P?r-(D-this.borderWidth.left):this.dragElePosition.left:r-D}else A=s-C,x=r-D;var L=parseFloat(getComputedStyle(this.element).marginTop);if(L>0&&(this.clone&&(A+=L,S<0&&(L+S>=0?A=L+S:A-=L),this.dragArea&&(A=this.dragLimit.bottom=0){var O=this.dragLimit.top+S-C;O+L+C<0?A-=L+C:A=O}else A-=L+C;this.dragArea&&this.helperElement.classList.contains("e-treeview")&&(A=A+(w=d.offsetHeight+(parseFloat(b.marginTop)+parseFloat(b.marginBottom)))>this.dragLimit.bottom?this.dragLimit.bottom-w:A),this.enableScrollHandler&&!this.clone&&(A-=this.parentScrollY,x-=this.parentScrollX),this.dragArea&&"string"!=typeof this.dragArea&&this.dragArea.classList.contains("e-kanban-content")&&"relative"===this.dragArea.style.position&&(A+=this.dragArea.scrollTop);var N=this.getProcessedPositionValue({top:A+"px",left:x+"px"});this.isPreventScroll&&(N=this.getProcessedPositionValue({top:this.position.top-this.parentClientRect.top-2+"px",left:this.position.left-this.parentClientRect.left-2+"px"})),je(d,this.getDragPosition(N)),!this.elementInViewport(d)&&this.enableAutoScroll&&!this.helperElement.classList.contains("e-treeview")&&this.helperElement.scrollIntoView();var T=document.querySelectorAll(":hover");if(this.enableAutoScroll&&this.helperElement.classList.contains("e-treeview")){0===T.length&&(T=this.getPathElements(i));var z=this.getScrollParent(T,!1);this.elementInViewport(this.helperElement)?this.getScrollPosition(z,A):this.elementInViewport(this.helperElement)||(0===(T=[].slice.call(document.querySelectorAll(":hover"))).length&&(T=this.getPathElements(i)),z=this.getScrollParent(T,!0),this.getScrollPosition(z,A))}this.dragProcessStarted=!0,this.prevLeft=r,this.prevTop=s,this.position.left=r,this.position.top=s,this.pageX=g,this.pageY=v}},t.prototype.getScrollParent=function(i,r){for(var o,s=r?i.reverse():i,a=s.length-1;a>=0;a--)if(("auto"===(o=window.getComputedStyle(s[parseInt(a.toString(),10)])["overflow-y"])||"scroll"===o)&&s[parseInt(a.toString(),10)].scrollHeight>s[parseInt(a.toString(),10)].clientHeight)return s[parseInt(a.toString(),10)];if("visible"===(o=window.getComputedStyle(document.scrollingElement)["overflow-y"]))return document.scrollingElement.style.overflow="auto",document.scrollingElement},t.prototype.getScrollPosition=function(i,r){if(i&&i===document.scrollingElement)i.clientHeight+document.scrollingElement.scrollTop-this.helperElement.clientHeightr?i.scrollTop+=this.helperElement.clientHeight:i.scrollTop>r-this.helperElement.clientHeight&&(i.scrollTop-=this.helperElement.clientHeight);else if(i&&i!==document.scrollingElement){var s=document.scrollingElement.scrollTop,o=this.helperElement.clientHeight;i.clientHeight+i.getBoundingClientRect().top-o+sr-o-s&&(i.scrollTop-=this.helperElement.clientHeight)}},t.prototype.getPathElements=function(i){return document.elementsFromPoint(i.clientX>0?i.clientX:0,i.clientY>0?i.clientY:0)},t.prototype.triggerOutFunction=function(i,r){this.hoverObject.instance.intOut(i,r.target),this.hoverObject.instance.dragData[this.scope]=null,this.hoverObject=null},t.prototype.getDragPosition=function(i){var r=ze({},i);return this.axis&&("x"===this.axis?delete r.top:"y"===this.axis&&delete r.left),r},t.prototype.getDocumentWidthHeight=function(i){var r=document.body,s=document.documentElement;return Math.max(r["scroll"+i],s["scroll"+i],r["offset"+i],s["offset"+i],s["client"+i])},t.prototype.intDragStop=function(i){if(this.dragProcessStarted=!1,st(i.changedTouches)||1===i.changedTouches.length){if(-1!==["touchend","pointerup","mouseup"].indexOf(i.type)){if(this.dragStop){var s=this.getProperTargetElement(i);this.trigger("dragStop",{event:i,element:this.element,target:s,helper:this.helperElement})}this.intDestroy(i)}else this.element.setAttribute("aria-grabbed","false");var o=this.checkTargetElement(i);o.target&&o.instance&&(o.instance.dragStopCalled=!0,o.instance.dragData[this.scope]=this.droppables[this.scope],o.instance.intDrop(i,o.target)),this.setGlobalDroppables(!0),document.body.classList.remove("e-prevent-select")}},t.prototype.intDestroy=function(i){this.dragProcessStarted=!1,this.toggleEvents(),document.body.classList.remove("e-prevent-select"),this.element.setAttribute("aria-grabbed","false"),E.remove(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.intDragStart),E.remove(document,X.isSafari()?"touchend":X.touchEndEvent,this.intDragStop),E.remove(document,X.isSafari()?"touchend":X.touchEndEvent,this.intDestroy),E.remove(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.intDrag),this.isDragStarted()&&this.isDragStarted(!0)},t.prototype.onPropertyChanged=function(i,r){},t.prototype.getModuleName=function(){return"draggable"},t.prototype.isDragStarted=function(i){return i&&(MC.isDragged=!MC.isDragged),MC.isDragged},t.prototype.setDragArea=function(){var i,r,a,s=0,o=0;if(a="string"==typeof this.dragArea?_(this.dragArea):this.dragArea){var h=a.getBoundingClientRect();i=a.scrollWidth?a.scrollWidth:h.right-h.left,r=a.scrollHeight?this.dragArea&&!m(this.helperElement)&&this.helperElement.classList.contains("e-treeview")?a.clientHeight:a.scrollHeight:h.bottom-h.top;for(var c=["Top","Left","Bottom","Right"],d=getComputedStyle(a),u=0;u12;return E0(i.target,this.helperElement)||-1!==i.type.indexOf("touch")||a?(this.helperElement.style.pointerEvents="none",s=document.elementFromPoint(r.clientX,r.clientY),this.helperElement.style.pointerEvents=o):s=i.target,s},t.prototype.currentStateCheck=function(i,r){return m(this.currentStateTarget)||this.currentStateTarget===i?m(r)?i:r:this.currentStateTarget},t.prototype.getMousePosition=function(i,r){var a,l,s=void 0!==i.srcElement?i.srcElement:i.target,o=this.getCoordinates(i),h=m(s.offsetParent);if(r?(a=this.clone?o.pageX:o.pageX+(h?0:s.offsetParent.scrollLeft)-this.relativeXPosition,l=this.clone?o.pageY:o.pageY+(h?0:s.offsetParent.scrollTop)-this.relativeYPosition):(a=this.clone?o.pageX:o.pageX+window.pageXOffset-this.relativeXPosition,l=this.clone?o.pageY:o.pageY+window.pageYOffset-this.relativeYPosition),document.scrollingElement&&!r&&!this.clone){var c=document.scrollingElement;a=c.scrollWidth>0&&c.scrollWidth>c.clientWidth&&c.scrollLeft>0?a-c.scrollLeft:a,l=c.scrollHeight>0&&c.scrollHeight>c.clientHeight&&c.scrollTop>0?l-c.scrollTop:l}return{left:a-(this.margin.left+this.cursorAt.left),top:l-(this.margin.top+this.cursorAt.top)}},t.prototype.getCoordinates=function(i){return i.type.indexOf("touch")>-1?i.changedTouches[0]:i},t.prototype.getHelperElement=function(i){var r;return this.clone?this.helper?r=this.helper({sender:i,element:this.target}):(r=Si("div",{className:"e-drag-helper e-block-touch",innerHTML:"Draggable"}),document.body.appendChild(r)):r=this.element,r},t.prototype.setGlobalDroppables=function(i,r,s){this.droppables[this.scope]=i?null:{draggable:r,helper:s,draggedElement:this.element}},t.prototype.checkTargetElement=function(i){var r=this.getProperTargetElement(i),s=this.getDropInstance(r);if(!s&&r&&!m(r.parentNode)){var o=J(r.parentNode,".e-droppable")||r.parentElement;o&&(s=this.getDropInstance(o))}return{target:r,instance:s}},t.prototype.getDropInstance=function(i){var s,o=i&&i.ej2_instances;if(o)for(var a=0,l=o;a=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},lR=function(n){function t(e,i){var r=n.call(this,i,e)||this;return r.mouseOver=!1,r.dragData={},r.dragStopCalled=!1,r.bind(),r}return sZ(t,n),t.prototype.bind=function(){this.wireEvents()},t.prototype.wireEvents=function(){E.add(this.element,X.isSafari()?"touchend":X.touchEndEvent,this.intDrop,this)},t.prototype.onPropertyChanged=function(e,i){},t.prototype.getModuleName=function(){return"droppable"},t.prototype.intOver=function(e,i){this.mouseOver||(this.trigger("over",{event:e,target:i,dragData:this.dragData[this.scope]}),this.mouseOver=!0)},t.prototype.intOut=function(e,i){this.mouseOver&&(this.trigger("out",{evt:e,target:i}),this.mouseOver=!1)},t.prototype.intDrop=function(e,i){if(this.dragStopCalled){this.dragStopCalled=!1;var a,r=!0,s=this.dragData[this.scope],o=!!s&&s.helper&&Tr(s.helper);o&&(a=this.isDropArea(e,s.helper,i),this.accept&&(r=mC(s.helper,this.accept))),o&&this.drop&&a.canDrop&&r&&this.trigger("drop",{event:e,target:a.target,droppedElement:s.helper,dragData:s}),this.mouseOver=!1}},t.prototype.isDropArea=function(e,i,r){var s={canDrop:!0,target:r||e.target},o="touchend"===e.type;if(o||s.target===i){i.style.display="none";var a=o?e.changedTouches[0]:e,l=document.elementFromPoint(a.clientX,a.clientY);s.canDrop=!1,s.canDrop=E0(l,this.element),s.canDrop&&(s.target=l),i.style.display=""}return s},t.prototype.destroy=function(){E.remove(this.element,X.isSafari()?"touchend":X.touchEndEvent,this.intDrop),n.prototype.destroy.call(this)},hf([I()],t.prototype,"accept",void 0),hf([I("default")],t.prototype,"scope",void 0),hf([H()],t.prototype,"drop",void 0),hf([H()],t.prototype,"over",void 0),hf([H()],t.prototype,"out",void 0),hf([Ft],t)}(dh),uo=function(){function n(t,e,i){this.controlName=t,this.localeStrings=e,this.setLocale(i||"en-US")}return n.prototype.setLocale=function(t){var e=this.intGetControlConstant(n.locale,t);this.currentLocale=e||this.localeStrings},n.load=function(t){this.locale=ze(this.locale,t,{},!0)},n.prototype.getConstant=function(t){return m(this.currentLocale[""+t])?this.localeStrings[""+t]||"":this.currentLocale[""+t]},n.prototype.intGetControlConstant=function(t,e){return t[""+e]?t[""+e][this.controlName]:null},n.locale={},n}(),hR=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),fh=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},lZ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return hR(t,n),fh([I(50)],t.prototype,"swipeThresholdDistance",void 0),t}(Ee),hZ=/(Up|Down)/,Fs=function(n){function t(e,i){var r=n.call(this,i,e)||this;return r.touchAction=!0,r.tapCount=0,r.startEvent=function(s){if(!0===r.touchAction){var o=r.updateChangeTouches(s);void 0!==s.changedTouches&&(r.touchAction=!1),r.isTouchMoved=!1,r.movedDirection="",r.startPoint=r.lastMovedPoint={clientX:o.clientX,clientY:o.clientY},r.startEventData=o,r.hScrollLocked=r.vScrollLocked=!1,r.tStampStart=Date.now(),r.timeOutTapHold=setTimeout(function(){r.tapHoldEvent(s)},r.tapHoldThreshold),E.add(r.element,X.touchMoveEvent,r.moveEvent,r),E.add(r.element,X.touchEndEvent,r.endEvent,r),E.add(r.element,X.touchCancelEvent,r.cancelEvent,r)}},r.moveEvent=function(s){var o=r.updateChangeTouches(s);r.movedPoint=o,r.isTouchMoved=!(o.clientX===r.startPoint.clientX&&o.clientY===r.startPoint.clientY);var a={};r.isTouchMoved&&(clearTimeout(r.timeOutTapHold),r.calcScrollPoints(s),a=ze(a,{},{startEvents:r.startEventData,originalEvent:s,startX:r.startPoint.clientX,startY:r.startPoint.clientY,distanceX:r.distanceX,distanceY:r.distanceY,scrollDirection:r.scrollDirection,velocity:r.getVelocity(o)}),r.trigger("scroll",a),r.lastMovedPoint={clientX:o.clientX,clientY:o.clientY})},r.cancelEvent=function(s){clearTimeout(r.timeOutTapHold),clearTimeout(r.timeOutTap),r.tapCount=0,r.swipeFn(s),E.remove(r.element,X.touchCancelEvent,r.cancelEvent)},r.endEvent=function(s){r.swipeFn(s),r.isTouchMoved||"function"==typeof r.tap&&(r.trigger("tap",{originalEvent:s,tapCount:++r.tapCount}),r.timeOutTap=setTimeout(function(){r.tapCount=0},r.tapThreshold)),r.modeclear()},r.swipeFn=function(s){clearTimeout(r.timeOutTapHold),clearTimeout(r.timeOutTap);var o=r.updateChangeTouches(s),a=o.clientX-r.startPoint.clientX,l=o.clientY-r.startPoint.clientY;a=Math.floor(a<0?-1*a:a),l=Math.floor(l<0?-1*l:a),r.isTouchMoved=a>1||l>1,/Firefox/.test(X.userAgent)&&0===o.clientX&&0===o.clientY&&"mouseup"===s.type&&(r.isTouchMoved=!1),r.endPoint=o,r.calcPoints(s);var c={originalEvent:s,startEvents:r.startEventData,startX:r.startPoint.clientX,startY:r.startPoint.clientY,distanceX:r.distanceX,distanceY:r.distanceY,swipeDirection:r.movedDirection,velocity:r.getVelocity(o)};if(r.isTouchMoved){var d=r.swipeSettings.swipeThresholdDistance,u=ze(void 0,r.defaultArgs,c),f=!1,p=r.element,g=r.isScrollable(p),v=hZ.test(r.movedDirection);(dthis.distanceY?i.clientX>this.startPoint.clientX?"Right":"Left":i.clientYthis.distanceY||!0===this.hScrollLocked)&&!1===this.vScrollLocked?(this.scrollDirection=i.clientX>this.lastMovedPoint.clientX?"Right":"Left",this.hScrollLocked=!0):(this.scrollDirection=i.clientY=e[r[0]+s[0]]},t.prototype.updateChangeTouches=function(e){return e.changedTouches&&0!==e.changedTouches.length?e.changedTouches[0]:e},fh([H()],t.prototype,"tap",void 0),fh([H()],t.prototype,"tapHold",void 0),fh([H()],t.prototype,"swipe",void 0),fh([H()],t.prototype,"scroll",void 0),fh([I(350)],t.prototype,"tapThreshold",void 0),fh([I(750)],t.prototype,"tapHoldThreshold",void 0),fh([re({},lZ)],t.prototype,"swipeSettings",void 0),fh([Ft],t)}(dh),cZ=new RegExp("\\n|\\r|\\s\\s+","g"),dZ=new RegExp(/'|"/g),uZ=new RegExp("if ?\\("),fZ=new RegExp("else if ?\\("),cR=new RegExp("else"),pZ=new RegExp("for ?\\("),dR=new RegExp("(/if|/for)"),gZ=new RegExp("\\((.*)\\)",""),wC=new RegExp("^[0-9]+$","g"),vZ=new RegExp("[\\w\"'.\\s+]+","g"),mZ=new RegExp('"(.*?)"',"g"),yZ=new RegExp("[\\w\"'@#$.\\s-+]+","g"),uR=new RegExp("\\${([^}]*)}","g"),SZ=/^\..*/gm,CC=/\\/gi,IZ=/\\\\/gi,bZ=new RegExp("[\\w\"'@#$.\\s+]+","g"),MZ=/\window\./gm;function cf(n,t,e,i,r){return!t||wC.test(n)||-1!==i.indexOf(n.split(".")[0])||r||"true"===n||"false"===n?n:e+"."+n}function EC(n,t,e,i){return t&&!wC.test(n)&&-1===i.indexOf(n.split(".")[0])?e+'["'+n:n}function fR(n){return n.match(IZ)?n:n.replace(CC,"\\\\")}function pR(n,t,e,i){if(n=n.trim(),/\window\./gm.test(n))return n;var s=/'|"/gm;return/@|\$|#/gm.test(n)&&(n=EC(n,-1===e.indexOf(n),t,e)+'"]'),SZ.test(n)?function EZ(n,t,e,i){return!t||wC.test(n)||-1!==i.indexOf(n.split(".")[0])||/^\..*/gm.test(n)?n:e+"."+n}(n,!s.test(n)&&-1===e.indexOf(n),t,e):cf(n,!s.test(n)&&-1===e.indexOf(n),t,e,i)}var DZ=/^[\n\r.]+0&&t.forEach(function(e){he(e)})},n.removeJsEvents=function(){var t=this.wrapElement.querySelectorAll("["+vR.join("],[")+"]");t.length>0&&t.forEach(function(e){vR.forEach(function(i){e.hasAttribute(i)&&e.removeAttribute(i)})})},n.removeXssAttrs=function(){var t=this;this.removeAttrs.forEach(function(e,i){var r=t.wrapElement.querySelectorAll(e.selector);r.length>0&&r.forEach("a[href]"===e.selector?function(s){-1!==s.getAttribute(e.attribute).replace(/\t|\s|&/,"").indexOf("javascript:alert")&&s.removeAttribute(e.attribute)}:function(s){s.removeAttribute(e.attribute)})})},n}();function PZ(n){return function(t){!function kZ(n,t){t.forEach(function(e){Object.getOwnPropertyNames(e.prototype).forEach(function(i){(!Object.prototype.hasOwnProperty.call(n.prototype,i)||e.isFormBase&&"constructor"!==i)&&(n.prototype["".concat(i)]=e.prototype["".concat(i)])})})}(t,n)}}function mR(n,t,e){var i={};if(n&&n.length){for(var r=0,s=n;r"u"||(y.innerHTML=v.innerHTML?v.innerHTML:"",void 0!==v.className&&(y.className=v.className),void 0!==v.id&&(y.id=v.id),void 0!==v.styles&&y.setAttribute("style",v.styles),void 0!==e.ngAttr&&y.setAttribute(e.ngAttr,""),void 0!==v.attrs&&Fe(y,v.attrs)),y};for(var i=0,r=e.tags;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s}function jZ(n){for(var t,e=n.childNodes,i=0;i"u"&&(c["".concat(o)]=[]),c["".concat(o)].push(h),h.rootNodes}}});var Sl,ad,mh,jg,oc,po,YZ=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Na=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Jo_RTL=(new Ag,"e-rtl"),ys=function(n){function t(e,i){return n.call(this,e,i)||this}return YZ(t,n),t.prototype.preRender=function(){},t.prototype.render=function(){this.initialize(),this.removeRippleEffect=function ms(n,t,e){var i=function q$(n){return{selector:n&&n.selector?n.selector:null,ignore:n&&n.ignore?n.ignore:null,rippleFlag:n&&n.rippleFlag,isCenterRipple:n&&n.isCenterRipple,duration:n&&n.duration?n.duration:350}}(t);return!1===i.rippleFlag||void 0===i.rippleFlag&&!Zo?function(){}:(n.setAttribute("data-ripple","true"),E.add(n,"mousedown",Zz,{parent:n,rippleOptions:i}),E.add(n,"mouseup",Jz,{parent:n,rippleOptions:i,done:e}),E.add(n,"mouseleave",af,{parent:n,rippleOptions:i}),X.isPointer&&E.add(n,"transitionend",af,{parent:n,rippleOptions:i}),function(){n.removeAttribute("data-ripple"),E.remove(n,"mousedown",Zz),E.remove(n,"mouseup",Jz),E.remove(n,"mouseleave",af),E.remove(n,"transitionend",af)})}(this.element,{selector:".e-btn"}),this.renderComplete()},t.prototype.initialize=function(){if(this.cssClass&&V([this.element],this.cssClass.replace(/\s+/g," ").trim().split(" ")),this.isPrimary&&this.element.classList.add("e-primary"),!ce()||ce()&&"progress-btn"!==this.getModuleName()){if(this.content){var e=this.enableHtmlSanitizer?Ai.sanitize(this.content):this.content;this.element.innerHTML=e}this.setIconCss()}this.enableRtl&&this.element.classList.add(Jo_RTL),this.disabled?this.controlStatus(this.disabled):this.wireEvents()},t.prototype.controlStatus=function(e){this.element.disabled=e},t.prototype.setIconCss=function(){if(this.iconCss){var e=this.createElement("span",{className:"e-btn-icon "+this.iconCss});this.element.textContent.trim()?(e.classList.add("e-icon-"+this.iconPosition.toLowerCase()),("Top"===this.iconPosition||"Bottom"===this.iconPosition)&&this.element.classList.add("e-"+this.iconPosition.toLowerCase()+"-icon-btn")):this.element.classList.add("e-icon-btn");var i=this.element.childNodes[0];!i||"Left"!==this.iconPosition&&"Top"!==this.iconPosition?this.element.appendChild(e):this.element.insertBefore(e,i)}},t.prototype.wireEvents=function(){this.isToggle&&E.add(this.element,"click",this.btnClickHandler,this)},t.prototype.unWireEvents=function(){this.isToggle&&E.remove(this.element,"click",this.btnClickHandler)},t.prototype.btnClickHandler=function(){this.element.classList.contains("e-active")?this.element.classList.remove("e-active"):this.element.classList.add("e-active")},t.prototype.destroy=function(){var e=["e-primary",Jo_RTL,"e-icon-btn","e-success","e-info","e-danger","e-warning","e-flat","e-outline","e-small","e-bigger","e-active","e-round","e-top-icon-btn","e-bottom-icon-btn"];this.cssClass&&(e=e.concat(this.cssClass.split(" "))),n.prototype.destroy.call(this),K([this.element],e),this.element.getAttribute("class")||this.element.removeAttribute("class"),this.disabled&&this.element.removeAttribute("disabled"),this.content&&(this.element.innerHTML=this.element.innerHTML.replace(this.content,""));var i=this.element.querySelector("span.e-btn-icon");i&&he(i),this.unWireEvents(),Zo&&this.removeRippleEffect()},t.prototype.getModuleName=function(){return"btn"},t.prototype.getPersistData=function(){return this.addOnPersist([])},t.Inject=function(){},t.prototype.onPropertyChanged=function(e,i){for(var r=this.element.querySelector("span.e-btn-icon"),s=0,o=Object.keys(e);s=ad.width?ad.width:0;return Sl.right+JR()-n}function uE(){return j0()+Sl.width/2}function fE(n,t,e,i){if(void 0===t&&(t=null),void 0===e&&(e={X:!1,Y:!1}),!e.Y&&!e.X)return{left:0,top:0};var r=n.getBoundingClientRect();if(po=t,oc=n.ownerDocument,i||(i=ns(n,"left","top")),e.X){var s=po?r4():l4(),o=yE(),a=SE(),l=o-i.left,h=i.left+r.width-a;r.width>s?i.left=l>0&&h<=0?a-r.width:h>0&&l<=0?o:l>h?a-r.width:o:l>0?i.left+=l:h>0&&(i.left-=h)}if(e.Y){var c=po?n4():a4(),d=mE(),u=IE(),f=d-i.top,p=i.top+r.height-u;r.height>c?i.top=f>0&&p<=0?u-r.height:p>0&&f<=0?d:f>p?u-r.height:d:f>0?i.top+=f:p>0&&(i.top-=p)}return i}function ac(n,t,e,i){void 0===t&&(t=null);var r=ns(n,"left","top");e&&(r.left=e),i&&(r.top=i);var s=[];po=t,oc=n.ownerDocument;var o=n.getBoundingClientRect(),l=r.left,h=r.left+o.width,d=vE(r.top,r.top+o.height),u=e4(l,h);return d.topSide&&s.push("top"),u.rightSide&&s.push("right"),u.leftSide&&s.push("left"),d.bottomSide&&s.push("bottom"),s}function bJ(n,t,e,i,r,s,o,a,l){if(void 0===o&&(o=null),void 0===a&&(a={X:!0,Y:!0}),t&&n&&r&&s&&(a.X||a.Y)){var d,h={TL:null,TR:null,BL:null,BR:null},c={TL:null,TR:null,BL:null,BR:null};if("none"===window.getComputedStyle(n).display){var u=n.style.visibility;n.style.visibility="hidden",n.style.display="block",d=n.getBoundingClientRect(),n.style.removeProperty("display"),n.style.visibility=u}else d=n.getBoundingClientRect();var f={posX:r,posY:s,offsetX:e,offsetY:i,position:{left:0,top:0}};po=o,oc=t.ownerDocument,function wJ(n,t,e,i,r){e.position=ns(n,e.posX,e.posY,i,r),t.TL=ns(n,"left","top",i,r),t.TR=ns(n,"right","top",i,r),t.BR=ns(n,"left","bottom",i,r),t.BL=ns(n,"right","bottom",i,r)}(t,h,f,l,d),gE(c,f,d),a.X&&t4(t,c,h,f,d,!0),a.Y&&h.TL.top>-1&&i4(t,c,h,f,d,!0),function MJ(n,t,e){var i=0,r=0;if(null!=n.offsetParent&&("absolute"===getComputedStyle(n.offsetParent).position||"relative"===getComputedStyle(n.offsetParent).position)){var s=ns(n.offsetParent,"left","top",!1,e);i=s.left,r=s.top}var o=1,a=1,l=KR(n);if(l){var h=getComputedStyle(l).transform;if("none"!==h){var c=new DOMMatrix(h);o=c.a,a=c.d}if("none"!==getComputedStyle(l).zoom){var u=pE(document.body);o*=u,a*=u}}n.style.top=t.position.top/a+t.offsetY-r/a+"px",n.style.left=t.position.left/o+t.offsetX-i/o+"px"}(n,f,d)}}function pE(n){var t=getComputedStyle(n).zoom;return parseFloat(t)||1}function KR(n){for(;n;){var t=window.getComputedStyle(n).transform,e=pE(document.body);if(t&&"none"!==t||e&&1!==e)return n;if(n===document.body)return null;n=n.offsetParent||n.parentElement}return null}function gE(n,t,e){n.TL={top:t.position.top+t.offsetY,left:t.position.left+t.offsetX},n.TR={top:n.TL.top,left:n.TL.left+e.width},n.BL={top:n.TL.top+e.height,left:n.TL.left},n.BR={top:n.TL.top+e.height,left:n.TL.left+e.width}}function e4(n,t){var e=!1,i=!1;return n-W0()SE()&&(i=!0),{leftSide:e,rightSide:i}}function t4(n,t,e,i,r,s){var o=e4(t.TL.left,t.TR.left),a=vE(t.TL.top,t.BL.top);e.TL.left-W0()<=yE()&&(o.leftSide=!1),e.TR.left>SE()&&(o.rightSide=!1),(o.leftSide&&!o.rightSide||!o.leftSide&&o.rightSide)&&(i.posX="right"===i.posX?"left":"right",i.offsetX=i.offsetX+r.width,i.offsetX=-1*i.offsetX,i.position=ns(n,i.posX,i.posY,!1),gE(t,i,r),s&&t4(n,t,e,i,r,!1),!o.leftSide&&o.rightSide&&a.bottomSide&&(i.offsetX=0))}function i4(n,t,e,i,r,s){var o=vE(t.TL.top,t.BL.top);e.TL.top-V0()<=mE()&&(o.topSide=!1),e.BL.top>=IE()&&n.getBoundingClientRect().bottomIE()&&(i=!0),{topSide:e,bottomSide:i}}function r4(){return po.getBoundingClientRect().width}function n4(){return po.getBoundingClientRect().height}function s4(){return po.getBoundingClientRect().left}function o4(){return po.getBoundingClientRect().top}function mE(){return po?o4():0}function yE(){return po?s4():0}function SE(){return po?W0()+s4()+r4():W0()+l4()}function IE(){return po?V0()+o4()+n4():V0()+a4()}function V0(){return oc.documentElement.scrollTop||oc.body.scrollTop}function W0(){return oc.documentElement.scrollLeft||oc.body.scrollLeft}function a4(){return window.innerHeight}function l4(){var n=window.innerWidth,t=document.documentElement.getBoundingClientRect();return n-(n-(m(document.documentElement)?0:t.width))}function h4(){po=null,oc=null}var c4=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),bn=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},d4=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return c4(t,n),bn([I("left")],t.prototype,"X",void 0),bn([I("top")],t.prototype,"Y",void 0),t}(Ee),qn_OPEN="e-popup-open",qn_CLOSE="e-popup-close",lc=function(n){function t(e,i){return n.call(this,i,e)||this}return c4(t,n),t.prototype.onPropertyChanged=function(e,i){for(var r=0,s=Object.keys(e);r0&&c.left>0&&c.right>0&&c.bottom>0}var s=i.getBoundingClientRect();return!(r.bottoms.bottom||r.right>s.right||r.leftr.top?this.element.style.top="0px":s.bottomr.left&&(this.element.style.left=parseInt(this.element.style.left,10)+(s.left-r.left)+"px"))}},t.prototype.checkCollision=function(){var e=this.collision.X,i=this.collision.Y;"none"===e&&"none"===i||("flip"===e&&"flip"===i?this.callFlip({X:!0,Y:!0}):"fit"===e&&"fit"===i?this.callFit({X:!0,Y:!0}):("flip"===e?this.callFlip({X:!0,Y:!1}):"flip"===i&&this.callFlip({Y:!0,X:!1}),"fit"===e?this.callFit({X:!0,Y:!1}):"fit"===i&&this.callFit({X:!1,Y:!0})))},t.prototype.show=function(e,i){var r=this;if(this.getRelateToElement().classList.contains("e-filemanager")&&(this.fmDialogContainer=this.element.getElementsByClassName("e-file-select-wrap")[0]),this.wireEvents(),!m(this.fmDialogContainer)&&X.isIos&&(this.fmDialogContainer.style.display="block"),1e3===this.zIndex||!m(i)){var o=m(i)?this.element:i;this.zIndex=hc(o),je(this.element,{zIndex:this.zIndex})}e=m(e)||"object"!=typeof e?this.showAnimation:e,("none"!==this.collision.X||"none"!==this.collision.Y)&&(K([this.element],qn_CLOSE),V([this.element],qn_OPEN),this.checkCollision(),K([this.element],qn_OPEN),V([this.element],qn_CLOSE)),m(e)?(K([this.element],qn_CLOSE),V([this.element],qn_OPEN),this.trigger("open")):(e.begin=function(){r.isDestroyed||(K([r.element],qn_CLOSE),V([r.element],qn_OPEN))},e.end=function(){r.isDestroyed||r.trigger("open")},new Hs(e).animate(this.element))},t.prototype.hide=function(e){var i=this;e=m(e)||"object"!=typeof e?this.hideAnimation:e,m(e)?(K([this.element],qn_OPEN),V([this.element],qn_CLOSE),this.trigger("close")):(e.end=function(){i.isDestroyed||(K([i.element],qn_OPEN),V([i.element],qn_CLOSE),i.trigger("close"))},new Hs(e).animate(this.element)),this.unwireEvents()},t.prototype.getScrollableParent=function(e){return this.checkFixedParent(e),function bE(n,t){for(var e=getComputedStyle(n),i=[],r=/(auto|scroll)/,s=n.parentElement;s&&"HTML"!==s.tagName;){var o=getComputedStyle(s);!("absolute"===e.position&&"static"===o.position)&&r.test(o.overflow+o.overflowY+o.overflowX)&&i.push(s),s=s.parentElement}return t||i.push(document),i}(e,this.fixedParent)},t.prototype.checkFixedParent=function(e){for(var i=e.parentElement;i&&"HTML"!==i.tagName;){var r=getComputedStyle(i);("fixed"===r.position||"sticky"===r.position)&&!m(this.element)&&this.element.offsetParent&&"BODY"===this.element.offsetParent.tagName&&"hidden"!==getComputedStyle(this.element.offsetParent).overflow&&(this.element.style.top=window.scrollY>parseInt(this.element.style.top,10)?Re(window.scrollY-parseInt(this.element.style.top,10)):Re(parseInt(this.element.style.top,10)-window.scrollY),this.element.style.position="fixed",this.fixedParent=!0),i=i.parentElement,!m(this.element)&&m(this.element.offsetParent)&&"fixed"===r.position&&"fixed"===this.element.style.position&&(this.fixedParent=!0)}},bn([I("auto")],t.prototype,"height",void 0),bn([I("auto")],t.prototype,"width",void 0),bn([I(null)],t.prototype,"content",void 0),bn([I("container")],t.prototype,"targetType",void 0),bn([I(null)],t.prototype,"viewPortElement",void 0),bn([I({X:"none",Y:"none"})],t.prototype,"collision",void 0),bn([I("")],t.prototype,"relateTo",void 0),bn([re({},d4)],t.prototype,"position",void 0),bn([I(0)],t.prototype,"offsetX",void 0),bn([I(0)],t.prototype,"offsetY",void 0),bn([I(1e3)],t.prototype,"zIndex",void 0),bn([I(!1)],t.prototype,"enableRtl",void 0),bn([I("reposition")],t.prototype,"actionOnScroll",void 0),bn([I(null)],t.prototype,"showAnimation",void 0),bn([I(null)],t.prototype,"hideAnimation",void 0),bn([H()],t.prototype,"open",void 0),bn([H()],t.prototype,"close",void 0),bn([H()],t.prototype,"targetExitViewport",void 0),bn([Ft],t)}(Ii);function hc(n){for(var t=n.parentElement,e=[];t&&"BODY"!==t.tagName;){var i=document.defaultView.getComputedStyle(t,null).getPropertyValue("z-index"),r=document.defaultView.getComputedStyle(t,null).getPropertyValue("position");"auto"!==i&&"static"!==r&&e.push(i),t=t.parentElement}for(var s=[],o=0;o2147483647?2147483647:c}var Ui,ka,df,Ih,EE,bh,$t,Mh,ME=["north-west","north","north-east","west","east","south-west","south","south-east"],Vg="e-resize-handle",cc="e-focused-handle",CJ="e-dlg-resizable",u4=["e-restrict-left"],f4="e-resize-viewport",EJ=["north","west","east","south"],wE=0,CE=0,p4=0,g4=0,Wg=0,Yg=0,Qg=null,DE=null,xE=null,Y0=!0,v4=0,TE=!0;function xJ(n){AE();var t=Si("span",{attrs:{unselectable:"on",contenteditable:"false"}});t.setAttribute("class","e-dialog-border-resize e-"+n),"south"===n&&(t.style.height="2px",t.style.width="100%",t.style.bottom="0px",t.style.left="0px"),"north"===n&&(t.style.height="2px",t.style.width="100%",t.style.top="0px",t.style.left="0px"),"east"===n&&(t.style.height="100%",t.style.width="2px",t.style.right="0px",t.style.top="0px"),"west"===n&&(t.style.height="100%",t.style.width="2px",t.style.left="0px",t.style.top="0px"),Ui.appendChild(t)}function m4(n){var t;return m(n)||(t="string"==typeof n?document.querySelector(n):n),t}function y4(n){for(var t=n||this,e=Ui.querySelectorAll("."+Vg),i=0;i-1?"mouse":"touch"}function I4(n){if(n.preventDefault(),Ui=n.target.parentElement,AE(),Wg=n.pageX,Yg=n.pageY,n.target.classList.add(cc),m(Qg)||!0!==Qg(n,this)){this.targetEle&&Ui&&Ui.querySelector("."+CJ)&&($t="body"===this.target?null:this.targetEle,bh=this.targetEle.clientWidth,Ih=this.targetEle.clientHeight);var e=m($t)?document:$t;E.add(e,"mousemove",Gg,this),E.add(document,"mouseup",Q0,this);for(var i=0;i=0||s.top<0)&&(e=!0):e=!0;var a=CE+(r-Yg);a=a>df?a:df;var l=0;m($t)||(l=o.top);var h=m($t)?0:$t.offsetHeight-$t.clientHeight,c=s.top-l-h/2;if(c=c<0?0:c,s.top>0&&c+a>Ih){if(e=!1,Ui.classList.contains(f4))return;Ui.style.height=Ih-parseInt(c.toString(),10)+"px"}else{var d=0;if(e){s.top<0&&t+(s.height+s.top)>0&&a+(d=s.top)<=30&&(a=s.height-(s.height+s.top)+30),a+s.top>=Ih&&(Ui.style.height=s.height+(t-(s.height+s.top))+"px");var u=m($t)?d:c;a>=df&&a+u<=Ih&&(Ui.style.height=a+"px")}}}function NE(n){var e,t=!1,i="mouse"===S4(n.type)?n.pageY:n.touches[0].pageY,r=dc(Ui),s=m($t)?0:$t.offsetHeight-$t.clientHeight;m($t)||(e=dc($t)),(!m($t)&&r.top-e.top>0||m($t)&&i>0||!m($t)&&Math.floor(r.top-e.top+r.height+(e.bottom-r.bottom))-s<=Ih)&&(t=!0);var o=CE-(i-Yg);if(t&&o>=df&&o<=Ih){var a=0;m($t)||(a=e.top);var l=g4-a+(i-Yg);l=l>0?l:1,Ui.style.height=o+"px",Ui.style.top=l+"px"}}function OE(n){var i,t=document.documentElement.clientWidth,e=!1;m($t)||(i=dc($t));var r="mouse"===S4(n.type)?n.pageX:n.touches[0].pageX,s=dc(Ui),o=m($t)?0:$t.offsetWidth-$t.clientWidth,a=m($t)?0:i.left,l=m($t)?0:i.width;m(Mh)&&(m($t)?Mh=t:(Mh=s.left-a-o/2+s.width,Mh+=l-o-Mh)),(!m($t)&&Math.floor(s.left-i.left+s.width+(i.right-s.right))-o<=bh||m($t)&&r>=0)&&(e=!0);var h=wE-(r-Wg);if(Y0&&(h=h>Mh?Mh:h),e&&h>=EE&&h<=bh){var c=0;m($t)||(c=i.left);var d=p4-c+(r-Wg);d=d>0?d:1,h!==v4&&TE&&(Ui.style.width=h+"px"),Y0&&(Ui.style.left=d+"px",TE=1!==d)}v4=h}function kE(n){var i,t=document.documentElement.clientWidth,e=!1;m($t)||(i=dc($t));var s=(n.touches?n.changedTouches[0]:n).pageX,o=dc(Ui);(!m($t)&&(o.left-i.left+o.width<=bh||o.right-i.left>=o.width)||m($t)&&t-s>0)&&(e=!0);var a=wE+(s-Wg),l=0;if(m($t)||(l=i.left),o.left-l+a>bh){if(e=!1,Ui.classList.contains(f4))return;Ui.style.width=bh-(o.left-l)+"px"}e&&a>=EE&&a<=bh&&(Ui.style.width=a+"px")}function M4(){for(var n=Ui.querySelectorAll("."+Vg),t=0;t=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},OJ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return PE(t,n),Zt([I(!0)],t.prototype,"isFlat",void 0),Zt([I()],t.prototype,"buttonModel",void 0),Zt([I("Button")],t.prototype,"type",void 0),Zt([H()],t.prototype,"click",void 0),t}(Ee),kJ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return PE(t,n),Zt([I("Fade")],t.prototype,"effect",void 0),Zt([I(400)],t.prototype,"duration",void 0),Zt([I(0)],t.prototype,"delay",void 0),t}(Ee),G0="e-dialog",zE="e-rtl",RE="e-dlg-header-content",w4="e-dlg-header",X0="e-footer-content",q0="e-dlg-modal",C4="e-icon-dlg-close",Pa="e-dlg-target",ea="e-scroll-disabled",E4="e-device",$0="e-dlg-fullscreen",D4="e-dlg-closeicon-btn",x4="e-popup-open",T4="Information",A4="e-scroll-disabled",L4="e-alert-dialog",N4="e-confirm-dialog",HE="e-dlg-resizable",uf="e-restrict-left",O4="e-resize-viewport",BE="user action",QJ=function(n){function t(e,i){var r=n.call(this,e,i)||this;return r.needsID=!0,r}return PE(t,n),t.prototype.render=function(){this.initialize(),this.initRender(),this.wireEvents(),"100%"===this.width&&(this.element.style.width=""),""!==this.minHeight&&(this.element.style.minHeight=Re(this.minHeight)),this.enableResize&&(this.setResize(),this.isModal&&(this.isModelResize=!0),"None"===this.animationSettings.effect&&this.getMinHeight()),this.renderComplete()},t.prototype.initializeValue=function(){this.dlgClosedBy=BE},t.prototype.preRender=function(){var e=this;if(this.initializeValue(),this.headerContent=null,this.allowMaxHeight=!0,this.preventVisibility=!0,this.clonedEle=this.element.cloneNode(!0),this.closeIconClickEventHandler=function(s){e.dlgClosedBy="close icon",e.hide(s)},this.dlgOverlayClickEventHandler=function(s){e.dlgClosedBy="overlayClick",s.preventFocus=!1,e.trigger("overlayClick",s,function(o){o.preventFocus||e.focusContent(),e.dlgClosedBy=BE})},this.l10n=new uo("dialog",{close:"Close"},this.locale),this.checkPositionData(),m(this.target)){var r=this.isProtectedOnChange;this.isProtectedOnChange=!0,this.target=document.body,this.isProtectedOnChange=r}},t.prototype.updatePersistData=function(){this.enablePersistence&&this.setProperties({width:parseFloat(this.element.style.width),height:parseFloat(this.element.style.height),position:{X:parseFloat(this.dragObj.element.style.left),Y:parseFloat(this.dragObj.element.style.top)}},!0)},t.prototype.isNumberValue=function(e){return/^[-+]?\d*\.?\d+$/.test(e)},t.prototype.checkPositionData=function(){if(!m(this.position)){if(!m(this.position.X)&&"number"!=typeof this.position.X&&this.isNumberValue(this.position.X)){var i=this.isProtectedOnChange;this.isProtectedOnChange=!0,this.position.X=parseFloat(this.position.X),this.isProtectedOnChange=i}m(this.position.Y)||"number"==typeof this.position.Y||this.isNumberValue(this.position.Y)&&(i=this.isProtectedOnChange,this.isProtectedOnChange=!0,this.position.Y=parseFloat(this.position.Y),this.isProtectedOnChange=i)}},t.prototype.getEle=function(e,i){for(var r=void 0,s=0;s=0&&t[e])xJ(t[e]);else if(""!==t[e].trim()){var i=Si("div",{className:"e-icons "+Vg+" e-"+t[e]});Ui.appendChild(i)}df=n.minHeight,EE=n.minWidth,bh=n.maxWidth,Ih=n.maxHeight,n.proxy&&n.proxy.element&&n.proxy.element.classList.contains("e-dialog")?y4(n.proxy):y4()}({element:this.element,direction:r,minHeight:parseInt(e.slice(0,i.indexOf("p")),10),maxHeight:this.targetEle.clientHeight,minWidth:parseInt(i.slice(0,i.indexOf("p")),10),maxWidth:this.targetEle.clientWidth,boundary:this.target===document.body?null:this.targetEle,resizeBegin:this.onResizeStart.bind(this),resizeComplete:this.onResizeComplete.bind(this),resizing:this.onResizing.bind(this),proxy:this}),this.wireWindowResizeEvent()}else M4(),this.unWireWindowResizeEvent(),this.element.classList.remove(this.isModal?uf:O4),this.element.classList.remove(HE)},t.prototype.getFocusElement=function(e){var r=e.querySelectorAll('input,select,textarea,button:enabled,a,[contenteditable="true"],[tabindex]');return{element:r[r.length-1]}},t.prototype.keyDown=function(e){var i=this;if(9===e.keyCode&&this.isModal){var r=void 0;m(this.btnObj)||(r=this.btnObj[this.btnObj.length-1]),m(this.btnObj)&&!m(this.ftrTemplateContent)&&(r=this.getFocusElement(this.ftrTemplateContent)),m(this.btnObj)&&m(this.ftrTemplateContent)&&!m(this.contentEle)&&(r=this.getFocusElement(this.contentEle)),!m(r)&&document.activeElement===r.element&&!e.shiftKey&&(e.preventDefault(),this.focusableElements(this.element).focus()),document.activeElement===this.focusableElements(this.element)&&e.shiftKey&&(e.preventDefault(),m(r)||r.element.focus())}var h,s=document.activeElement,o=["input","textarea"].indexOf(s.tagName.toLowerCase())>-1,a=!1;if(o||(a=s.hasAttribute("contenteditable")&&"true"===s.getAttribute("contenteditable")),27===e.keyCode&&this.closeOnEscape){this.dlgClosedBy="escape";var l=document.querySelector(".e-popup-open:not(.e-dialog)");!m(l)&&!l.classList.contains("e-toolbar-pop")&&!l.classList.contains("e-slider-tooltip")||this.hide(e)}(13===e.keyCode&&!e.ctrlKey&&"textarea"!==s.tagName.toLowerCase()&&o&&!m(this.primaryButtonEle)||13===e.keyCode&&e.ctrlKey&&("textarea"===s.tagName.toLowerCase()||a)&&!m(this.primaryButtonEle))&&this.buttons.some(function(d,u){h=u;var f=d.buttonModel;return!m(f)&&!0===f.isPrimary})&&"function"==typeof this.buttons[h].click&&setTimeout(function(){i.buttons[h].click.call(i,e)})},t.prototype.initialize=function(){m(this.target)||(this.targetEle="string"==typeof this.target?document.querySelector(this.target):this.target),this.isBlazorServerRender()||V([this.element],G0),X.isDevice&&V([this.element],E4),this.isBlazorServerRender()||this.setCSSClass(),this.setMaxHeight()},t.prototype.initRender=function(){var e=this;if(this.initialRender=!0,this.isBlazorServerRender()||Fe(this.element,{role:"dialog"}),1e3===this.zIndex?(this.setzIndex(this.element,!1),this.calculatezIndex=!0):this.calculatezIndex=!1,this.setTargetContent(),""!==this.header&&!m(this.header)&&this.setHeader(),this.renderCloseIcon(),this.setContent(),""===this.footerTemplate||m(this.footerTemplate)?!m(this.buttons[0])&&!m(this.buttons[0].buttonModel)&&this.setButton():this.setFooterTemplate(),this.allowDragging&&!m(this.headerContent)&&this.setAllowDragging(),Fe(this.element,{"aria-modal":this.isModal?"true":"false"}),this.isModal&&this.setIsModal(),!0!==this.element.classList.contains(L4)&&!0!==this.element.classList.contains(N4)&&!m(this.element.parentElement)){var i=this.isModal?this.dlgContainer.parentElement:this.element.parentElement;this.refElement=this.createElement("div",{className:"e-dlg-ref-element"}),i.insertBefore(this.refElement,this.isModal?this.dlgContainer:this.element)}if(m(this.targetEle)||this.targetEle.appendChild(this.isModal?this.dlgContainer:this.element),this.popupObj=new lc(this.element,{height:this.height,width:this.width,zIndex:this.zIndex,relateTo:this.target,actionOnScroll:"none",enableRtl:this.enableRtl,open:function(o){var a={container:e.isModal?e.dlgContainer:e.element,element:e.element,target:e.target,preventFocus:!1};e.enableResize&&e.resetResizeIcon(),e.trigger("open",a,function(l){l.preventFocus||e.focusContent()})},close:function(o){e.isModal&&V([e.dlgOverlay],"e-fade"),e.unBindEvent(e.element),e.isModal&&(e.dlgContainer.style.display="none"),e.trigger("close",e.closeArgs);var a=document.activeElement;!m(a)&&!m(a.blur)&&a.blur(),!m(e.storeActiveElement)&&!m(e.storeActiveElement.focus)&&e.storeActiveElement.focus()}}),this.positionChange(),this.setEnableRTL(),this.isBlazorServerRender()||(V([this.element],"e-popup-close"),this.isModal&&this.setOverlayZindex()),this.visible){if(this.show(),this.isModal){var r=this.getTargetContainer(this.target);r instanceof Element&&"rtl"===window.getComputedStyle(r).getPropertyValue("direction")&&this.setPopupPosition()}}else this.isModal&&(this.dlgOverlay.style.display="none");this.initialRender=!1},t.prototype.getTargetContainer=function(e){var i=null;if("string"==typeof e)if(e.startsWith("#"))i=document.getElementById(e.substring(1));else if(e.startsWith(".")){var r=document.getElementsByClassName(e.substring(1));i=r.length>0?r[0]:null}else!(e instanceof HTMLElement)&&e!==document.body&&(i=document.querySelector(e));else e instanceof HTMLElement&&(i=e);return i},t.prototype.resetResizeIcon=function(){var e=this.getMinHeight();if(this.targetEle.offsetHeight0&&("function"==typeof this.buttons[e].click&&E.add(s[e],"click",this.buttons[e].click,this),"object"==typeof this.buttons[e].click&&E.add(s[e],"click",this.buttonClickHandler.bind(this,e),this)),!this.isBlazorServerRender()&&!m(this.ftrTemplateContent)&&(this.btnObj[e].appendTo(this.ftrTemplateContent.children[e]),this.buttons[e].isFlat&&this.btnObj[e].element.classList.add("e-flat"),this.primaryButtonEle=this.element.getElementsByClassName("e-primary")[0]))},t.prototype.buttonClickHandler=function(e){this.trigger("buttons["+e+"].click",{})},t.prototype.setContent=function(){this.contentEle=this.createElement("div",{className:"e-dlg-content",id:this.element.id+"_dialog-content"}),Fe(this.element,this.headerEle?{"aria-describedby":this.element.id+"_title "+this.element.id+"_dialog-content"}:{"aria-describedby":this.element.id+"_dialog-content"}),this.innerContentElement?this.contentEle.appendChild(this.innerContentElement):(!m(this.content)&&""!==this.content||!this.initialRender)&&(("string"!=typeof this.content||ce())&&this.content instanceof HTMLElement?this.contentEle.appendChild(this.content):this.setTemplate(this.content,this.contentEle,"content")),m(this.headerContent)?this.element.insertBefore(this.contentEle,this.element.children[0]):this.element.insertBefore(this.contentEle,this.element.children[1]),"auto"===this.height&&(!this.isBlazorServerRender()&&X.isIE&&""===this.element.style.width&&!m(this.width)&&(this.element.style.width=Re(this.width)),this.setMaxHeight())},t.prototype.setTemplate=function(e,i,r){var s,o,a;o=i.classList.contains(w4)?this.element.id+"header":i.classList.contains(X0)?this.element.id+"footerTemplate":this.element.id+"content",m(e.outerHTML)?("string"==typeof e||"string"!=typeof e||ce()&&!this.isStringTemplate)&&("string"==typeof e&&(e=this.sanitizeHelper(e)),this.isVue||"string"!=typeof e?(s=si(e),a=e):i.innerHTML=e):i.appendChild(e);var l=[];if(!m(s)){for(var c=0,d=s({},this,r,o,!(ce()&&!this.isStringTemplate&&0===a.indexOf("
Blazor"))||this.isStringTemplate);c/g,"");(this.element.children.length>0||i)&&(this.innerContentElement=document.createDocumentFragment(),[].slice.call(this.element.childNodes).forEach(function(r){8!==r.nodeType&&e.innerContentElement.appendChild(r)}))}},t.prototype.setHeader=function(){this.headerEle?this.headerEle.innerHTML="":this.headerEle=this.createElement("div",{id:this.element.id+"_title",className:w4}),this.createHeaderContent(),this.headerContent.appendChild(this.headerEle),this.setTemplate(this.header,this.headerEle,"header"),Fe(this.element,{"aria-describedby":this.element.id+"_title"}),Fe(this.element,{"aria-labelledby":this.element.id+"_dialog-header"}),this.element.insertBefore(this.headerContent,this.element.children[0]),this.allowDragging&&!m(this.headerContent)&&this.setAllowDragging()},t.prototype.setFooterTemplate=function(){this.ftrTemplateContent?this.ftrTemplateContent.innerHTML="":this.ftrTemplateContent=this.createElement("div",{className:X0}),""===this.footerTemplate||m(this.footerTemplate)?this.ftrTemplateContent.innerHTML=this.buttonContent.join(""):this.setTemplate(this.footerTemplate,this.ftrTemplateContent,"footerTemplate"),this.element.appendChild(this.ftrTemplateContent)},t.prototype.createHeaderContent=function(){m(this.headerContent)&&(this.headerContent=this.createElement("div",{id:this.element.id+"_dialog-header",className:RE}))},t.prototype.renderCloseIcon=function(){this.showCloseIcon&&(this.closeIcon=this.createElement("button",{className:D4,attrs:{type:"button"}}),this.closeIconBtnObj=new ys({cssClass:"e-flat",iconCss:C4+" e-icons"}),this.closeIconTitle(),m(this.headerContent)?(this.createHeaderContent(),gl([this.closeIcon],this.headerContent),this.element.insertBefore(this.headerContent,this.element.children[0])):gl([this.closeIcon],this.headerContent),this.closeIconBtnObj.appendTo(this.closeIcon))},t.prototype.closeIconTitle=function(){this.l10n.setLocale(this.locale);var e=this.l10n.getConstant("close");this.closeIcon.setAttribute("title",e),this.closeIcon.setAttribute("aria-label",e)},t.prototype.setCSSClass=function(e){e&&(K([this.element],e.split(" ")),this.isModal&&!m(this.dlgContainer)&&K([this.dlgContainer],e.split(" "))),this.cssClass&&(V([this.element],this.cssClass.split(" ")),this.isModal&&!m(this.dlgContainer)&&V([this.dlgContainer],this.cssClass.split(" ")))},t.prototype.setIsModal=function(){this.dlgContainer=this.createElement("div",{className:"e-dlg-container"}),this.setCSSClass(),this.element.classList.remove(x4),this.element.parentNode.insertBefore(this.dlgContainer,this.element),this.dlgContainer.appendChild(this.element),V([this.element],q0),this.dlgOverlay=this.createElement("div",{className:"e-dlg-overlay"}),this.dlgOverlay.style.zIndex=(this.zIndex-1).toString(),this.dlgContainer.appendChild(this.dlgOverlay)},t.prototype.getValidFocusNode=function(e){for(var i,r=0;r0||"a"===i.tagName.toLowerCase()&&i.hasAttribute("href"))&&i.tabIndex>-1&&!i.disabled&&!this.disableElement(i,'[disabled],[aria-disabled="true"],[type="hidden"]'))return i;i=null}return i},t.prototype.focusableElements=function(e){if(!m(e)){var r=e.querySelectorAll('input,select,textarea,button,a,[contenteditable="true"],[tabindex]');return this.getValidFocusNode(r)}return null},t.prototype.getAutoFocusNode=function(e){var i=e.querySelector("."+D4),s=e.querySelectorAll("[autofocus]"),o=this.getValidFocusNode(s);if(ce()&&(this.primaryButtonEle=this.element.getElementsByClassName("e-primary")[0]),m(o)){if(!m(o=this.focusableElements(this.contentEle)))return o;if(!m(this.primaryButtonEle))return this.element.querySelector(".e-primary")}else i=o;return i},t.prototype.disableElement=function(e,i){var r=e?e.matches||e.webkitMatchesSelector||e.msGetRegionContent:null;if(r)for(;e;e=e.parentNode)if(e instanceof Element&&r.call(e,i))return e;return null},t.prototype.focusContent=function(){var e=this.getAutoFocusNode(this.element),i=m(e)?this.element:e,r=X.userAgent;(r.indexOf("MSIE ")>0||r.indexOf("Trident/")>0)&&this.element.focus(),i.focus(),this.unBindEvent(this.element),this.bindEvent(this.element)},t.prototype.bindEvent=function(e){E.add(e,"keydown",this.keyDown,this)},t.prototype.unBindEvent=function(e){E.remove(e,"keydown",this.keyDown)},t.prototype.updateSanitizeContent=function(){this.isBlazorServerRender()||(this.contentEle.innerHTML=this.sanitizeHelper(this.content))},t.prototype.isBlazorServerRender=function(){return ce()&&this.isServerRendered},t.prototype.getModuleName=function(){return"dialog"},t.prototype.onPropertyChanged=function(e,i){if(this.element.classList.contains(G0))for(var r=0,s=Object.keys(e);r0?this.showCloseIcon||""!==this.header&&!m(this.header)?this.showCloseIcon||he(this.closeIcon):(he(this.headerContent),this.headerContent=null):(this.renderCloseIcon(),this.wireEvents());break;case"locale":this.showCloseIcon&&this.closeIconTitle();break;case"visible":this.visible?this.show():this.hide();break;case"isModal":this.updateIsModal();break;case"height":je(this.element,{height:Re(e.height)}),this.updatePersistData();break;case"width":je(this.element,{width:Re(e.width)}),this.updatePersistData();break;case"zIndex":this.popupObj.zIndex=this.zIndex,this.isModal&&this.setOverlayZindex(this.zIndex),this.element.style.zIndex!==this.zIndex.toString()&&(this.calculatezIndex=!1);break;case"cssClass":this.setCSSClass(i.cssClass);break;case"buttons":this.unWireButtonEvents(),this.destroyButtons(),m(this.ftrTemplateContent)||(he(this.ftrTemplateContent),this.ftrTemplateContent=null),this.footerTemplate="",this.setButton();break;case"allowDragging":this.allowDragging&&!m(this.headerContent)?this.setAllowDragging():this.dragObj.destroy();break;case"target":this.setTarget(e.target);break;case"position":if(this.checkPositionData(),this.isModal){var a=this.position.X,l=this.position.Y;m(i.position)||(m(i.position.X)||(a=i.position.X),m(i.position.Y)||(l=i.position.Y)),this.dlgContainer.classList.contains("e-dlg-"+a+"-"+l)&&this.dlgContainer.classList.remove("e-dlg-"+a+"-"+l)}this.positionChange(),this.updatePersistData();break;case"enableRtl":this.setEnableRTL();break;case"enableResize":this.setResize(),this.isModelResize=this.enableResize&&this.isModal,this.enableResize&&this.dialogOpen&&this.resetResizeIcon();break;case"minHeight":""!==this.minHeight&&(this.element.style.minHeight=Re(this.minHeight))}},t.prototype.setTarget=function(e){this.popupObj.relateTo=e,this.target=e,this.targetEle="string"==typeof this.target?document.querySelector(this.target):this.target,this.dragObj&&(this.dragObj.dragArea=this.targetEle),this.setMaxHeight(),this.isModal&&this.updateIsModal(),this.enableResize&&this.setResize(),m(this.targetEle)||(this.isModal&&!m(this.dlgContainer)?this.targetEle.appendChild(this.dlgContainer):m(this.element)||this.targetEle.appendChild(this.element))},t.prototype.updateIsModal=function(){if(this.element.setAttribute("aria-modal",this.isModal?"true":"false"),this.isModal)m(this.dlgOverlay)&&(this.setIsModal(),this.element.style.top="0px",this.element.style.left="0px",m(this.targetEle)||this.targetEle.appendChild(this.dlgContainer));else{for(K([this.element],q0),K([document.body],[Pa,ea]),he(this.dlgOverlay);this.dlgContainer.firstChild;)this.dlgContainer.parentElement.insertBefore(this.dlgContainer.firstChild,this.dlgContainer);this.dlgContainer.parentElement.removeChild(this.dlgContainer)}this.visible&&this.show(),this.positionChange(),this.isModal&&this.dlgOverlay&&E.add(this.dlgOverlay,"click",this.dlgOverlayClickEventHandler,this)},t.prototype.setzIndex=function(e,i){var r=this.isProtectedOnChange;this.isProtectedOnChange=!0;var s=hc(e);this.zIndex=s>this.zIndex?s:this.zIndex,this.isProtectedOnChange=r,i&&(this.popupObj.zIndex=this.zIndex)},t.prototype.windowResizeHandler=function(){(function AJ(n){bh=n})(this.targetEle.clientWidth),function LJ(n){Ih=n}(this.targetEle.clientHeight),this.setMaxHeight()},t.prototype.getPersistData=function(){return this.addOnPersist(["width","height","position"])},t.prototype.removeAllChildren=function(e){for(;e.children[0];)this.removeAllChildren(e.children[0]),e.removeChild(e.children[0])},t.prototype.destroy=function(){if(!this.isDestroyed){var e=[zE,q0,HE,uf,$0,E4],i=["role","aria-modal","aria-labelledby","aria-describedby","aria-grabbed","tabindex","style"];K([this.targetEle],[Pa,ea]),!m(this.element)&&this.element.classList.contains($0)&&K([document.body],[Pa,ea]),this.isModal&&K([m(this.targetEle)?document.body:this.targetEle],ea),this.unWireEvents(),this.unWireButtonEvents(),this.destroyButtons(),m(this.closeIconBtnObj)||this.closeIconBtnObj.destroy(),m(this.dragObj)||this.dragObj.destroy(),!m(this.popupObj.element)&&this.popupObj.element.classList.contains("e-popup")&&this.popupObj.destroy(),K([this.element],e),!m(this.cssClass)&&""!==this.cssClass&&K([this.element],this.cssClass.split(" ")),!m(this.refElement)&&!m(this.refElement.parentElement)&&(this.refElement.parentElement.insertBefore(this.isModal?this.dlgContainer:this.element,this.refElement),he(this.refElement),this.refElement=void 0),this.isModal&&(he(this.dlgOverlay),this.dlgContainer.parentNode.insertBefore(this.element,this.dlgContainer),he(this.dlgContainer)),this.element.innerHTML=this.clonedEle.innerHTML;for(var r=0;r0&&""===this.footerTemplate&&this.ftrTemplateContent)for(var e=0;e=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},FE="e-tooltip",B4="e-icons",F4="e-tooltip-close",_E="e-tooltip-wrap",_4="e-tip-content",ff="e-arrow-tip",U4="e-arrow-tip-outer",Z0="e-arrow-tip-inner",Xg="e-tip-bottom",UE="e-tip-top",j4="e-tip-left",jE="e-tip-right",VE="e-popup",qg="e-popup-open",WE="e-popup-close",J0="e-lib",V4="e-tooltip-popup-container",JJ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return P4(t,n),Gi([I({effect:"FadeIn",duration:150,delay:0})],t.prototype,"open",void 0),Gi([I({effect:"FadeOut",duration:150,delay:0})],t.prototype,"close",void 0),t}(Ee),wh=function(n){function t(e,i){var r=n.call(this,e,i)||this;return r.mouseMoveEvent=null,r.mouseMoveTarget=null,r.containerElement=null,r.isBodyContainer=!0,r}return P4(t,n),t.prototype.initialize=function(){this.formatPosition(),V([this.element],FE)},t.prototype.formatPosition=function(){var e,i;this.position&&(0===this.position.indexOf("Top")||0===this.position.indexOf("Bottom")?(e=this.position.split(/(?=[A-Z])/),this.tooltipPositionY=e[0],this.tooltipPositionX=e[1]):(i=this.position.split(/(?=[A-Z])/),this.tooltipPositionX=i[0],this.tooltipPositionY=i[1]))},t.prototype.renderArrow=function(){this.setTipClass(this.position);var e=this.createElement("div",{className:ff+" "+this.tipClass});e.appendChild(this.createElement("div",{className:U4+" "+this.tipClass})),e.appendChild(this.createElement("div",{className:Z0+" "+this.tipClass})),this.tooltipEle.appendChild(e)},t.prototype.setTipClass=function(e){this.tipClass=0===e.indexOf("Right")?j4:0===e.indexOf("Bottom")?UE:0===e.indexOf("Left")?jE:Xg},t.prototype.renderPopup=function(e){var i=this.mouseTrail?{top:0,left:0}:this.getTooltipPosition(e);this.tooltipEle.classList.remove(J0),this.popupObj=new lc(this.tooltipEle,{height:this.height,width:this.width,position:{X:i.left,Y:i.top},enableRtl:this.enableRtl,open:this.openPopupHandler.bind(this),close:this.closePopupHandler.bind(this)})},t.prototype.getScalingFactor=function(e){if(!e)return{x:1,y:1};var i={x:1,y:1},r=e.closest('[style*="transform: scale"]');if(r&&r!==this.tooltipEle&&r.contains(this.tooltipEle)){var a=window.getComputedStyle(r).getPropertyValue("transform").match(/matrix\(([^)]+)\)/)[1].split(",").map(parseFloat);i.x=a[0],i.y=a[3]}return i},t.prototype.getTooltipPosition=function(e){this.tooltipEle.style.display="block";var i=this.element.closest('[style*="zoom"]');i&&(i.contains(this.tooltipEle)||(this.tooltipEle.style.zoom=getComputedStyle(i).zoom));var r=ns(e,this.tooltipPositionX,this.tooltipPositionY,!this.isBodyContainer,this.isBodyContainer?null:this.containerElement.getBoundingClientRect()),s=this.getScalingFactor(e),o=this.calculateTooltipOffset(this.position,s.x,s.y),a=this.calculateElementPosition(r,o),c=this.collisionFlipFit(e,a[0],a[1]);return c.left=c.left/s.x,c.top=c.top/s.y,this.tooltipEle.style.display="",c},t.prototype.windowResize=function(){this.reposition(this.findTarget())},t.prototype.reposition=function(e){if(this.popupObj&&e){var i=this.getTooltipPosition(e);this.popupObj.position={X:i.left,Y:i.top},this.popupObj.dataBind()}},t.prototype.openPopupHandler=function(){!this.mouseTrail&&this.needTemplateReposition()&&this.reposition(this.findTarget()),this.trigger("afterOpen",this.tooltipEventArgs),this.tooltipEventArgs=null},t.prototype.closePopupHandler=function(){this.isReact&&!("Click"===this.opensOn||"function"==typeof this.content)&&this.clearTemplate(["content"]),this.clear();var e={type:this.tooltipEventArgs.event?this.tooltipEventArgs.event.type:null,cancel:!1,target:this.tooltipEventArgs.target,event:this.tooltipEventArgs.event?this.tooltipEventArgs.event:null,element:this.tooltipEle,isInteracted:!m(this.tooltipEventArgs.event)};this.trigger("afterClose",e),e=null},t.prototype.calculateTooltipOffset=function(e,i,r){void 0===i&&(i=1),void 0===r&&(r=1);var o,a,l,h,c,d,u,f,s={top:0,left:0};if(1!==i||1!==r){var p=this.tooltipEle.getBoundingClientRect(),g=void 0;l=Math.round(p.width),h=Math.round(p.height),(c=_("."+ff,this.tooltipEle))&&(g=c.getBoundingClientRect()),o=c?Math.round(g.width):0,a=c?Math.round(g.height):0,d=this.showTipPointer?0:8,u=a/2+2+(h-this.tooltipEle.clientHeight*r),f=o/2+2+(l-this.tooltipEle.clientWidth*i)}else l=this.tooltipEle.offsetWidth,h=this.tooltipEle.offsetHeight,c=_("."+ff,this.tooltipEle),d=this.showTipPointer?0:8,u=(a=c?c.offsetHeight:0)/2+2+(this.tooltipEle.offsetHeight-this.tooltipEle.clientHeight),f=(o=c?c.offsetWidth:0)/2+2+(this.tooltipEle.offsetWidth-this.tooltipEle.clientWidth);switch(this.mouseTrail&&(d+=2),e){case"RightTop":s.left+=o+d,s.top-=h-u;break;case"RightCenter":s.left+=o+d,s.top-=h/2;break;case"RightBottom":s.left+=o+d,s.top-=u;break;case"BottomRight":s.top+=a+d,s.left-=f;break;case"BottomCenter":s.top+=a+d,s.left-=l/2;break;case"BottomLeft":s.top+=a+d,s.left-=l-f;break;case"LeftBottom":s.left-=o+l+d,s.top-=u;break;case"LeftCenter":s.left-=o+l+d,s.top-=h/2;break;case"LeftTop":s.left-=o+l+d,s.top-=h-u;break;case"TopLeft":s.top-=h+a+d,s.left-=l-f;break;case"TopRight":s.top-=h+a+d,s.left-=f;break;default:s.top-=h+a+d,s.left-=l/2}return s.left+=this.offsetX,s.top+=this.offsetY,s},t.prototype.updateTipPosition=function(e){var i=we("."+ff+",."+U4+",."+Z0,this.tooltipEle);K(i,[Xg,UE,j4,jE]),this.setTipClass(e),V(i,this.tipClass)},t.prototype.adjustArrow=function(e,i,r,s){var o=_("."+ff,this.tooltipEle);if(!1!==this.showTipPointer&&null!==o){var a,l;this.updateTipPosition(i),this.tooltipEle.style.display="block";var p,h=this.tooltipEle.clientWidth,c=this.tooltipEle.clientHeight,d=_("."+Z0,this.tooltipEle),u=o.offsetWidth,f=o.offsetHeight;this.tooltipEle.style.display="",this.tipClass===Xg||this.tipClass===UE?(this.tipClass===Xg?(l="99.9%",d.style.top="-"+(f-2)+"px"):(l=-(f-1)+"px",d.style.top="-"+(f-6)+"px"),e&&(a=(p="Center"!==r||h>e.offsetWidth||this.mouseTrail)&&"Left"===r||!p&&"End"===this.tipPointerPosition?h-u-2+"px":p&&"Right"===r||!p&&"Start"===this.tipPointerPosition?"2px":!p||"End"!==this.tipPointerPosition&&"Start"!==this.tipPointerPosition?h/2-u/2+"px":"End"===this.tipPointerPosition?e.offsetWidth+(this.tooltipEle.offsetWidth-e.offsetWidth)/2-u/2-2+"px":(this.tooltipEle.offsetWidth-e.offsetWidth)/2-u/2+2+"px")):(this.tipClass===jE?(a="99.9%",d.style.left="-"+(u-2)+"px"):(a=-(u-1)+"px",d.style.left=u-2-u+"px"),l=(p="Center"!==s||c>e.offsetHeight||this.mouseTrail)&&"Top"===s||!p&&"End"===this.tipPointerPosition?c-f-2+"px":p&&"Bottom"===s||!p&&"Start"===this.tipPointerPosition?"2px":c/2-f/2+"px"),o.style.top=l,o.style.left=a}},t.prototype.renderContent=function(e){var i=this,r=_("."+_4,this.tooltipEle);if(this.cssClass&&V([this.tooltipEle],this.cssClass.split(" ")),e&&!m(e.getAttribute("title"))&&(e.setAttribute("data-content",e.getAttribute("title")),e.removeAttribute("title")),m(this.content))e&&!m(e.getAttribute("data-content"))&&(r.innerHTML=e.getAttribute("data-content"));else if(r.innerHTML="",this.content instanceof HTMLElement)r.appendChild(this.content);else if("string"==typeof this.content)this.isAngular?this.setProperties({content:Ai.sanitize(this.content)},!0):this.content=this.enableHtmlSanitizer?Ai.sanitize(this.content):this.content,this.enableHtmlParse?(o=si(this.content)({},this,"content",this.element.id+"content",void 0,void 0,r,this.root))&&Dt(o,r):r.textContent=this.content;else{var o;(o=si(this.content)({},this,"content",this.element.id+"content",void 0,void 0,r))&&(this.isAngular&&setTimeout(function(){i.reposition(e)},1),Dt(o,r)),this.renderReactTemplates()}},t.prototype.renderCloseIcon=function(){if(this.isSticky){var i=this.createElement("div",{className:B4+" "+F4});this.tooltipEle.appendChild(i),E.add(i,X.touchStartEvent,this.onStickyClose,this)}else{var e=this.tooltipEle.querySelector("."+B4+"."+F4);e&>(e)}},t.prototype.addDescribedBy=function(e,i){var r=(e.getAttribute("aria-describedby")||"").split(/\s+/);r.indexOf(i)<0&&r.push(i),Fe(e,{"aria-describedby":r.join(" ").trim(),"data-tooltip-id":i})},t.prototype.removeDescribedBy=function(e){var i=e.getAttribute("data-tooltip-id"),r=(e.getAttribute("aria-describedby")||"").split(/\s+/),s=r.indexOf(i);-1!==s&&r.splice(s,1),e.removeAttribute("data-tooltip-id");var o=r.join(" ").trim();o?e.setAttribute("aria-describedby",o):e.removeAttribute("aria-describedby")},t.prototype.tapHoldHandler=function(e){clearTimeout(this.autoCloseTimer),this.targetHover(e.originalEvent)},t.prototype.touchEndHandler=function(){var e=this;this.isSticky||(this.autoCloseTimer=setTimeout(function(){e.close()},1500))},t.prototype.targetClick=function(e){var i;!m(i=this.target?J(e.target,this.target):this.element)&&(null===i.getAttribute("data-tooltip-id")?this.targetHover(e):this.isSticky||this.hideTooltip(this.animation.close,e,i))},t.prototype.targetHover=function(e){var i;if(!(m(i=this.target?J(e.target,this.target):this.element)||null!==i.getAttribute("data-tooltip-id")&&0===this.closeDelay)){for(var s=0,o=[].slice.call(we('[data-tooltip-id= "'+this.ctrlId+'_content"]',document));s0?this.showTimer=setTimeout(function(){o.mouseTrail&&E.add(i,"mousemove touchstart mouseenter",o.onMouseMove,o),o.popupObj&&(o.popupObj.show(a,i),o.mouseMoveEvent&&o.mouseTrail&&o.onMouseMove(o.mouseMoveEvent))},this.openDelay):this.popupObj&&this.popupObj.show(a,i)}s&&this.wireMouseEvents(s,i)},t.prototype.needTemplateReposition=function(){return!m(this.viewContainerRef)&&"string"!=typeof this.viewContainerRef||this.isReact},t.prototype.checkCollision=function(e,i,r){var s={left:i,top:r,position:this.position,horizontal:this.tooltipPositionX,vertical:this.tooltipPositionY},o=ac(this.tooltipEle,this.checkCollideTarget(),i,r);return o.length>0&&(s.horizontal=o.indexOf("left")>=0?"Right":o.indexOf("right")>=0?"Left":this.tooltipPositionX,s.vertical=o.indexOf("top")>=0?"Bottom":o.indexOf("bottom")>=0?"Top":this.tooltipPositionY),s},t.prototype.calculateElementPosition=function(e,i){return[this.isBodyContainer?e.left+i.left:e.left-this.containerElement.getBoundingClientRect().left+i.left+window.pageXOffset+this.containerElement.scrollLeft,this.isBodyContainer?e.top+i.top:e.top-this.containerElement.getBoundingClientRect().top+i.top+window.pageYOffset+this.containerElement.scrollTop]},t.prototype.collisionFlipFit=function(e,i,r){var s=this.checkCollision(e,i,r),o=s.position;if(this.tooltipPositionY!==s.vertical&&(o=0===this.position.indexOf("Bottom")||0===this.position.indexOf("Top")?s.vertical+this.tooltipPositionX:this.tooltipPositionX+s.vertical),this.tooltipPositionX!==s.horizontal&&(0===o.indexOf("Left")&&(s.vertical="LeftTop"===o||"LeftCenter"===o?"Top":"Bottom",o=s.vertical+"Left"),0===o.indexOf("Right")&&(s.vertical="RightTop"===o||"RightCenter"===o?"Top":"Bottom",o=s.vertical+"Right"),s.horizontal=this.tooltipPositionX),this.tooltipEventArgs={type:null,cancel:!1,target:e,event:null,element:this.tooltipEle,collidedPosition:o},this.trigger("beforeCollision",this.tooltipEventArgs),this.tooltipEventArgs.cancel)o=this.position;else{var a=s.vertical,l=s.horizontal;if(s.position!==o){var h=ns(e,l,a,!this.isBodyContainer,this.isBodyContainer?null:this.containerElement.getBoundingClientRect());this.adjustArrow(e,o,l,a);var c=this.getScalingFactor(e),d=this.calculateTooltipOffset(o,c.x,c.y);d.top-=this.getOffSetPosition("TopBottom",o,this.offsetY),d.left-=this.getOffSetPosition("RightLeft",o,this.offsetX),s.position=o;var u=this.calculateElementPosition(h,d);s.left=u[0],s.top=u[1]}else this.adjustArrow(e,o,l,a)}var f={left:s.left,top:s.top},p=this.isBodyContainer?fE(this.tooltipEle,this.checkCollideTarget(),{X:!0,Y:this.windowCollision},f):f;this.tooltipEle.style.display="block";var g=_("."+ff,this.tooltipEle);if(this.showTipPointer&&null!=g&&(0===o.indexOf("Bottom")||0===o.indexOf("Top"))){var v=parseInt(g.style.left,10)-(p.left-s.left);v<0?v=0:v+g.offsetWidth>this.tooltipEle.clientWidth&&(v=this.tooltipEle.clientWidth-g.offsetWidth),g.style.left=v.toString()+"px"}return this.tooltipEle.style.display="",f.left=p.left,f.top=p.top,f},t.prototype.getOffSetPosition=function(e,i,r){return-1!==e.indexOf(this.position.split(/(?=[A-Z])/)[0])&&-1!==e.indexOf(i.split(/(?=[A-Z])/)[0])?2*r:0},t.prototype.checkCollideTarget=function(){return!this.windowCollision&&this.target?this.element:null},t.prototype.hideTooltip=function(e,i,r){var s=this;this.closeDelay>0?(clearTimeout(this.hideTimer),clearTimeout(this.showTimer),this.hideTimer=setTimeout(function(){s.closeDelay&&s.tooltipEle&&s.isTooltipOpen||s.tooltipHide(e,i,r)},this.closeDelay)):this.tooltipHide(e,i,r)},t.prototype.tooltipHide=function(e,i,r){var o,s=this;o=i?this.target?r||i.target:this.element:_('[data-tooltip-id= "'+this.ctrlId+'_content"]',document),this.tooltipEventArgs={type:i?i.type:null,cancel:!1,target:o,event:i||null,element:this.tooltipEle,isInteracted:!m(i)},this.trigger("beforeClose",this.tooltipEventArgs,function(a){a.cancel?s.isHidden=!1:(s.mouseMoveBeforeRemove(),s.popupHide(e,o,i))})},t.prototype.popupHide=function(e,i,r){i&&r&&this.restoreElement(i),this.isHidden=!0;var s={name:this.animation.close.effect,duration:e.duration,delay:e.delay,timingFunction:"easeIn"};"None"===e.effect&&(s=void 0),this.popupObj&&this.popupObj.hide(s)},t.prototype.restoreElement=function(e){this.unwireMouseEvents(e),m(e.getAttribute("data-content"))||(e.setAttribute("title",e.getAttribute("data-content")),e.removeAttribute("data-content")),this.removeDescribedBy(e)},t.prototype.clear=function(){var e=this.findTarget();e&&this.restoreElement(e),this.tooltipEle&&(K([this.tooltipEle],WE),V([this.tooltipEle],qg)),this.isHidden&&(this.popupObj&&this.popupObj.destroy(),this.tooltipEle&>(this.tooltipEle),this.tooltipEle=null,this.popupObj=null)},t.prototype.tooltipHover=function(){this.tooltipEle&&(this.isTooltipOpen=!0)},t.prototype.tooltipMouseOut=function(e){this.isTooltipOpen=!1,this.hideTooltip(this.animation.close,e,this.findTarget())},t.prototype.onMouseOut=function(e){var i=e.relatedTarget;if(i&&!this.mouseTrail){var r=J(i,"."+_E+"."+J0+"."+VE);r?E.add(r,"mouseleave",this.tooltipElementMouseOut,this):(this.hideTooltip(this.animation.close,e,this.findTarget()),0===this.closeDelay&&("None"===this.animation.close.effect||this.isReact&&"string"!=typeof this.content)&&this.clear())}else this.hideTooltip(this.animation.close,e,this.findTarget()),this.clear();this.popupObj&&!this.popupObj.element.classList.contains(qg)&&this.clear()},t.prototype.tooltipElementMouseOut=function(e){this.hideTooltip(this.animation.close,e,this.findTarget()),E.remove(this.element,"mouseleave",this.tooltipElementMouseOut),this.clear()},t.prototype.onStickyClose=function(){this.close()},t.prototype.onMouseMove=function(e){var i=0,r=0;e.type.indexOf("touch")>-1?(e.preventDefault(),i=e.touches[0].pageX,r=e.touches[0].pageY):(i=e.pageX,r=e.pageY),Hs.stop(this.tooltipEle),K([this.tooltipEle],WE),V([this.tooltipEle],qg),this.adjustArrow(e.target,this.position,this.tooltipPositionX,this.tooltipPositionY);var s=this.getScalingFactor(e.target),o=this.calculateTooltipOffset(this.position,s.x,s.y),h=this.checkCollision(e.target,i+o.left+this.offsetX,r+o.top+this.offsetY);if(this.tooltipPositionX!==h.horizontal||this.tooltipPositionY!==h.vertical){var c=0===this.position.indexOf("Bottom")||0===this.position.indexOf("Top")?h.vertical+h.horizontal:h.horizontal+h.vertical;h.position=c,this.adjustArrow(e.target,h.position,h.horizontal,h.vertical);var d=this.calculateTooltipOffset(h.position,s.x,s.y);h.left=i+d.left-this.offsetX,h.top=r+d.top-this.offsetY}this.tooltipEle.style.left=h.left+"px",this.tooltipEle.style.top=h.top+"px"},t.prototype.keyDown=function(e){this.tooltipEle&&27===e.keyCode&&this.close()},t.prototype.touchEnd=function(e){this.tooltipEle&&null===J(e.target,"."+FE)&&!this.isSticky&&this.close()},t.prototype.scrollHandler=function(e){this.tooltipEle&&!this.isSticky&&!J(e.target,"."+_E+"."+J0+"."+VE)&&!this.isSticky&&this.close()},t.prototype.render=function(){this.initialize(),this.wireEvents(this.opensOn),this.renderComplete()},t.prototype.preRender=function(){this.tipClass=Xg,this.tooltipPositionX="Center",this.tooltipPositionY="Top",this.isHidden=!0},t.prototype.wireEvents=function(e){for(var r=0,s=this.getTriggerList(e);r0)for(var i=0,r=e;i0)for(var i=0,r=e;i0&&this.condition&&-1!==this.condition.indexOf("not")&&(e[s].condition=e[s].condition?e[s].condition+"not":"not"),i=e[s].validate(t),r){if(!i)return!1}else if(i)return!0;return r},n.prototype.toJson=function(){var t,e;if(this.isComplex){t=[],e=this.predicates;for(var i=0;ie.length-3?(e=e.substring(0,e.length-1),n.endsWith(n.toLowerCase(t),n.toLowerCase(e))):(e.lastIndexOf("%")!==e.indexOf("%")&&e.lastIndexOf("%")>e.indexOf("%")+1&&(e=e.substring(e.indexOf("%")+1,e.lastIndexOf("%"))),-1!==t.indexOf(e)))},n.fnSort=function(t){return"ascending"===(t=t?n.toLowerCase(t):"ascending")?this.fnAscending:this.fnDescending},n.fnAscending=function(t,e){return m(t)&&m(e)||null==e?-1:"string"==typeof t?t.localeCompare(e):null==t?1:t-e},n.fnDescending=function(t,e){return m(t)&&m(e)?-1:null==e?1:"string"==typeof t?-1*t.localeCompare(e):null==t?-1:e-t},n.extractFields=function(t,e){for(var i={},r=0;r0||e.length>0;)o=t.length>0&&e.length>0?r?r(this.getVal(t,0,i),this.getVal(e,0,i),t[0],e[0])<=0?t:e:t[0][i]0?t:e,s.push(o.shift());return s},n.getVal=function(t,e,i){return i?this.getObject(i,t[e]):t[e]},n.toLowerCase=function(t){return t?"string"==typeof t?t.toLowerCase():t.toString():0===t||!1===t?t.toString():""},n.callAdaptorFunction=function(t,e,i,r){if(e in t){var s=t[e](i,r);m(s)||(i=s)}return i},n.getAddParams=function(t,e,i){var r={};return n.callAdaptorFunction(t,"addParams",{dm:e,query:i,params:i?i.params:[],reqParams:r}),r},n.isPlainObject=function(t){return!!t&&t.constructor===Object},n.isCors=function(){var t=null;try{t=new window.XMLHttpRequest}catch{}return!!t&&"withCredentials"in t},n.getGuid=function(t){var i;return(t||"")+"00000000-0000-4000-0000-000000000000".replace(/0/g,function(r,s){if("crypto"in window&&"getRandomValues"in crypto){var o=new Uint8Array(1);window.crypto.getRandomValues(o),i=o[0]%16|0}else i=16*Math.random()|0;return"0123456789abcdef"[19===s?3&i|8:i]})},n.isNull=function(t){return null==t},n.getItemFromComparer=function(t,e,i){var r,s,o,a=0,l="string"==typeof n.getVal(t,0,e);if(t.length)for(;m(r)&&a0&&(r=s,o=t[a]));return o},n.distinct=function(t,e,i){i=!m(i)&&i;var s,r=[],o={};return t.forEach(function(a,l){(s="object"==typeof t[l]?n.getVal(t,l,e):t[l])in o||(r.push(i?t[l]:s),o[s]=1)}),r},n.processData=function(t,e){var i=this.prepareQuery(t),r=new it(e);t.requiresCounts&&i.requiresCount();var s=r.executeLocal(i),o={result:t.requiresCounts?s.result:s,count:s.count,aggregates:JSON.stringify(s.aggregates)};return t.requiresCounts?o:s},n.prepareQuery=function(t){var e=this,i=new _t;return t.select&&i.select(t.select),t.where&&n.parse.parseJson(t.where).filter(function(o){if(m(o.condition))i.where(o.field,o.operator,o.value,o.ignoreCase,o.ignoreAccent);else{var a=[];o.field?a.push(new Ss(o.field,o.operator,o.value,o.ignoreCase,o.ignoreAccent)):a=a.concat(e.getPredicate(o.predicates)),"or"===o.condition?i.where(Ss.or(a)):"and"===o.condition&&i.where(Ss.and(a))}}),t.search&&n.parse.parseJson(t.search).filter(function(o){return i.search(o.key,o.fields,o.operator,o.ignoreCase,o.ignoreAccent)}),t.aggregates&&t.aggregates.filter(function(o){return i.aggregate(o.type,o.field)}),t.sorted&&t.sorted.filter(function(o){return i.sortBy(o.name,o.direction)}),t.skip&&i.skip(t.skip),t.take&&i.take(t.take),t.group&&t.group.filter(function(o){return i.group(o)}),i},n.getPredicate=function(t){for(var e=[],i=0;i":"greaterthan","<=":"lessthanorequal",">=":"greaterthanorequal","==":"equal","!=":"notequal","*=":"contains","$=":"endswith","^=":"startswith"},n.odBiOperator={"<":" lt ",">":" gt ","<=":" le ",">=":" ge ","==":" eq ","!=":" ne ",lessthan:" lt ",lessthanorequal:" le ",greaterthan:" gt ",greaterthanorequal:" ge ",equal:" eq ",notequal:" ne "},n.odUniOperator={"$=":"endswith","^=":"startswith","*=":"substringof",endswith:"endswith",startswith:"startswith",contains:"substringof",doesnotendwith:"not endswith",doesnotstartwith:"not startswith",doesnotcontain:"not substringof",wildcard:"wildcard",like:"like"},n.odv4UniOperator={"$=":"endswith","^=":"startswith","*=":"contains",endswith:"endswith",startswith:"startswith",contains:"contains",doesnotendwith:"not endswith",doesnotstartwith:"not startswith",doesnotcontain:"not contains",wildcard:"wildcard",like:"like"},n.diacritics={"\u24b6":"A",\uff21:"A",\u00c0:"A",\u00c1:"A",\u00c2:"A",\u1ea6:"A",\u1ea4:"A",\u1eaa:"A",\u1ea8:"A",\u00c3:"A",\u0100:"A",\u0102:"A",\u1eb0:"A",\u1eae:"A",\u1eb4:"A",\u1eb2:"A",\u0226:"A",\u01e0:"A",\u00c4:"A",\u01de:"A",\u1ea2:"A",\u00c5:"A",\u01fa:"A",\u01cd:"A",\u0200:"A",\u0202:"A",\u1ea0:"A",\u1eac:"A",\u1eb6:"A",\u1e00:"A",\u0104:"A",\u023a:"A",\u2c6f:"A",\ua732:"AA",\u00c6:"AE",\u01fc:"AE",\u01e2:"AE",\ua734:"AO",\ua736:"AU",\ua738:"AV",\ua73a:"AV",\ua73c:"AY","\u24b7":"B",\uff22:"B",\u1e02:"B",\u1e04:"B",\u1e06:"B",\u0243:"B",\u0182:"B",\u0181:"B","\u24b8":"C",\uff23:"C",\u0106:"C",\u0108:"C",\u010a:"C",\u010c:"C",\u00c7:"C",\u1e08:"C",\u0187:"C",\u023b:"C",\ua73e:"C","\u24b9":"D",\uff24:"D",\u1e0a:"D",\u010e:"D",\u1e0c:"D",\u1e10:"D",\u1e12:"D",\u1e0e:"D",\u0110:"D",\u018b:"D",\u018a:"D",\u0189:"D",\ua779:"D",\u01f1:"DZ",\u01c4:"DZ",\u01f2:"Dz",\u01c5:"Dz","\u24ba":"E",\uff25:"E",\u00c8:"E",\u00c9:"E",\u00ca:"E",\u1ec0:"E",\u1ebe:"E",\u1ec4:"E",\u1ec2:"E",\u1ebc:"E",\u0112:"E",\u1e14:"E",\u1e16:"E",\u0114:"E",\u0116:"E",\u00cb:"E",\u1eba:"E",\u011a:"E",\u0204:"E",\u0206:"E",\u1eb8:"E",\u1ec6:"E",\u0228:"E",\u1e1c:"E",\u0118:"E",\u1e18:"E",\u1e1a:"E",\u0190:"E",\u018e:"E","\u24bb":"F",\uff26:"F",\u1e1e:"F",\u0191:"F",\ua77b:"F","\u24bc":"G",\uff27:"G",\u01f4:"G",\u011c:"G",\u1e20:"G",\u011e:"G",\u0120:"G",\u01e6:"G",\u0122:"G",\u01e4:"G",\u0193:"G",\ua7a0:"G",\ua77d:"G",\ua77e:"G","\u24bd":"H",\uff28:"H",\u0124:"H",\u1e22:"H",\u1e26:"H",\u021e:"H",\u1e24:"H",\u1e28:"H",\u1e2a:"H",\u0126:"H",\u2c67:"H",\u2c75:"H",\ua78d:"H","\u24be":"I",\uff29:"I",\u00cc:"I",\u00cd:"I",\u00ce:"I",\u0128:"I",\u012a:"I",\u012c:"I",\u0130:"I",\u00cf:"I",\u1e2e:"I",\u1ec8:"I",\u01cf:"I",\u0208:"I",\u020a:"I",\u1eca:"I",\u012e:"I",\u1e2c:"I",\u0197:"I","\u24bf":"J",\uff2a:"J",\u0134:"J",\u0248:"J","\u24c0":"K",\uff2b:"K",\u1e30:"K",\u01e8:"K",\u1e32:"K",\u0136:"K",\u1e34:"K",\u0198:"K",\u2c69:"K",\ua740:"K",\ua742:"K",\ua744:"K",\ua7a2:"K","\u24c1":"L",\uff2c:"L",\u013f:"L",\u0139:"L",\u013d:"L",\u1e36:"L",\u1e38:"L",\u013b:"L",\u1e3c:"L",\u1e3a:"L",\u0141:"L",\u023d:"L",\u2c62:"L",\u2c60:"L",\ua748:"L",\ua746:"L",\ua780:"L",\u01c7:"LJ",\u01c8:"Lj","\u24c2":"M",\uff2d:"M",\u1e3e:"M",\u1e40:"M",\u1e42:"M",\u2c6e:"M",\u019c:"M","\u24c3":"N",\uff2e:"N",\u01f8:"N",\u0143:"N",\u00d1:"N",\u1e44:"N",\u0147:"N",\u1e46:"N",\u0145:"N",\u1e4a:"N",\u1e48:"N",\u0220:"N",\u019d:"N",\ua790:"N",\ua7a4:"N",\u01ca:"NJ",\u01cb:"Nj","\u24c4":"O",\uff2f:"O",\u00d2:"O",\u00d3:"O",\u00d4:"O",\u1ed2:"O",\u1ed0:"O",\u1ed6:"O",\u1ed4:"O",\u00d5:"O",\u1e4c:"O",\u022c:"O",\u1e4e:"O",\u014c:"O",\u1e50:"O",\u1e52:"O",\u014e:"O",\u022e:"O",\u0230:"O",\u00d6:"O",\u022a:"O",\u1ece:"O",\u0150:"O",\u01d1:"O",\u020c:"O",\u020e:"O",\u01a0:"O",\u1edc:"O",\u1eda:"O",\u1ee0:"O",\u1ede:"O",\u1ee2:"O",\u1ecc:"O",\u1ed8:"O",\u01ea:"O",\u01ec:"O",\u00d8:"O",\u01fe:"O",\u0186:"O",\u019f:"O",\ua74a:"O",\ua74c:"O",\u01a2:"OI",\ua74e:"OO",\u0222:"OU","\u24c5":"P",\uff30:"P",\u1e54:"P",\u1e56:"P",\u01a4:"P",\u2c63:"P",\ua750:"P",\ua752:"P",\ua754:"P","\u24c6":"Q",\uff31:"Q",\ua756:"Q",\ua758:"Q",\u024a:"Q","\u24c7":"R",\uff32:"R",\u0154:"R",\u1e58:"R",\u0158:"R",\u0210:"R",\u0212:"R",\u1e5a:"R",\u1e5c:"R",\u0156:"R",\u1e5e:"R",\u024c:"R",\u2c64:"R",\ua75a:"R",\ua7a6:"R",\ua782:"R","\u24c8":"S",\uff33:"S",\u1e9e:"S",\u015a:"S",\u1e64:"S",\u015c:"S",\u1e60:"S",\u0160:"S",\u1e66:"S",\u1e62:"S",\u1e68:"S",\u0218:"S",\u015e:"S",\u2c7e:"S",\ua7a8:"S",\ua784:"S","\u24c9":"T",\uff34:"T",\u1e6a:"T",\u0164:"T",\u1e6c:"T",\u021a:"T",\u0162:"T",\u1e70:"T",\u1e6e:"T",\u0166:"T",\u01ac:"T",\u01ae:"T",\u023e:"T",\ua786:"T",\ua728:"TZ","\u24ca":"U",\uff35:"U",\u00d9:"U",\u00da:"U",\u00db:"U",\u0168:"U",\u1e78:"U",\u016a:"U",\u1e7a:"U",\u016c:"U",\u00dc:"U",\u01db:"U",\u01d7:"U",\u01d5:"U",\u01d9:"U",\u1ee6:"U",\u016e:"U",\u0170:"U",\u01d3:"U",\u0214:"U",\u0216:"U",\u01af:"U",\u1eea:"U",\u1ee8:"U",\u1eee:"U",\u1eec:"U",\u1ef0:"U",\u1ee4:"U",\u1e72:"U",\u0172:"U",\u1e76:"U",\u1e74:"U",\u0244:"U","\u24cb":"V",\uff36:"V",\u1e7c:"V",\u1e7e:"V",\u01b2:"V",\ua75e:"V",\u0245:"V",\ua760:"VY","\u24cc":"W",\uff37:"W",\u1e80:"W",\u1e82:"W",\u0174:"W",\u1e86:"W",\u1e84:"W",\u1e88:"W",\u2c72:"W","\u24cd":"X",\uff38:"X",\u1e8a:"X",\u1e8c:"X","\u24ce":"Y",\uff39:"Y",\u1ef2:"Y",\u00dd:"Y",\u0176:"Y",\u1ef8:"Y",\u0232:"Y",\u1e8e:"Y",\u0178:"Y",\u1ef6:"Y",\u1ef4:"Y",\u01b3:"Y",\u024e:"Y",\u1efe:"Y","\u24cf":"Z",\uff3a:"Z",\u0179:"Z",\u1e90:"Z",\u017b:"Z",\u017d:"Z",\u1e92:"Z",\u1e94:"Z",\u01b5:"Z",\u0224:"Z",\u2c7f:"Z",\u2c6b:"Z",\ua762:"Z","\u24d0":"a",\uff41:"a",\u1e9a:"a",\u00e0:"a",\u00e1:"a",\u00e2:"a",\u1ea7:"a",\u1ea5:"a",\u1eab:"a",\u1ea9:"a",\u00e3:"a",\u0101:"a",\u0103:"a",\u1eb1:"a",\u1eaf:"a",\u1eb5:"a",\u1eb3:"a",\u0227:"a",\u01e1:"a",\u00e4:"a",\u01df:"a",\u1ea3:"a",\u00e5:"a",\u01fb:"a",\u01ce:"a",\u0201:"a",\u0203:"a",\u1ea1:"a",\u1ead:"a",\u1eb7:"a",\u1e01:"a",\u0105:"a",\u2c65:"a",\u0250:"a",\ua733:"aa",\u00e6:"ae",\u01fd:"ae",\u01e3:"ae",\ua735:"ao",\ua737:"au",\ua739:"av",\ua73b:"av",\ua73d:"ay","\u24d1":"b",\uff42:"b",\u1e03:"b",\u1e05:"b",\u1e07:"b",\u0180:"b",\u0183:"b",\u0253:"b","\u24d2":"c",\uff43:"c",\u0107:"c",\u0109:"c",\u010b:"c",\u010d:"c",\u00e7:"c",\u1e09:"c",\u0188:"c",\u023c:"c",\ua73f:"c",\u2184:"c","\u24d3":"d",\uff44:"d",\u1e0b:"d",\u010f:"d",\u1e0d:"d",\u1e11:"d",\u1e13:"d",\u1e0f:"d",\u0111:"d",\u018c:"d",\u0256:"d",\u0257:"d",\ua77a:"d",\u01f3:"dz",\u01c6:"dz","\u24d4":"e",\uff45:"e",\u00e8:"e",\u00e9:"e",\u00ea:"e",\u1ec1:"e",\u1ebf:"e",\u1ec5:"e",\u1ec3:"e",\u1ebd:"e",\u0113:"e",\u1e15:"e",\u1e17:"e",\u0115:"e",\u0117:"e",\u00eb:"e",\u1ebb:"e",\u011b:"e",\u0205:"e",\u0207:"e",\u1eb9:"e",\u1ec7:"e",\u0229:"e",\u1e1d:"e",\u0119:"e",\u1e19:"e",\u1e1b:"e",\u0247:"e",\u025b:"e",\u01dd:"e","\u24d5":"f",\uff46:"f",\u1e1f:"f",\u0192:"f",\ua77c:"f","\u24d6":"g",\uff47:"g",\u01f5:"g",\u011d:"g",\u1e21:"g",\u011f:"g",\u0121:"g",\u01e7:"g",\u0123:"g",\u01e5:"g",\u0260:"g",\ua7a1:"g",\u1d79:"g",\ua77f:"g","\u24d7":"h",\uff48:"h",\u0125:"h",\u1e23:"h",\u1e27:"h",\u021f:"h",\u1e25:"h",\u1e29:"h",\u1e2b:"h",\u1e96:"h",\u0127:"h",\u2c68:"h",\u2c76:"h",\u0265:"h",\u0195:"hv","\u24d8":"i",\uff49:"i",\u00ec:"i",\u00ed:"i",\u00ee:"i",\u0129:"i",\u012b:"i",\u012d:"i",\u00ef:"i",\u1e2f:"i",\u1ec9:"i",\u01d0:"i",\u0209:"i",\u020b:"i",\u1ecb:"i",\u012f:"i",\u1e2d:"i",\u0268:"i",\u0131:"i","\u24d9":"j",\uff4a:"j",\u0135:"j",\u01f0:"j",\u0249:"j","\u24da":"k",\uff4b:"k",\u1e31:"k",\u01e9:"k",\u1e33:"k",\u0137:"k",\u1e35:"k",\u0199:"k",\u2c6a:"k",\ua741:"k",\ua743:"k",\ua745:"k",\ua7a3:"k","\u24db":"l",\uff4c:"l",\u0140:"l",\u013a:"l",\u013e:"l",\u1e37:"l",\u1e39:"l",\u013c:"l",\u1e3d:"l",\u1e3b:"l",\u017f:"l",\u0142:"l",\u019a:"l",\u026b:"l",\u2c61:"l",\ua749:"l",\ua781:"l",\ua747:"l",\u01c9:"lj","\u24dc":"m",\uff4d:"m",\u1e3f:"m",\u1e41:"m",\u1e43:"m",\u0271:"m",\u026f:"m","\u24dd":"n",\uff4e:"n",\u01f9:"n",\u0144:"n",\u00f1:"n",\u1e45:"n",\u0148:"n",\u1e47:"n",\u0146:"n",\u1e4b:"n",\u1e49:"n",\u019e:"n",\u0272:"n",\u0149:"n",\ua791:"n",\ua7a5:"n",\u01cc:"nj","\u24de":"o",\uff4f:"o",\u00f2:"o",\u00f3:"o",\u00f4:"o",\u1ed3:"o",\u1ed1:"o",\u1ed7:"o",\u1ed5:"o",\u00f5:"o",\u1e4d:"o",\u022d:"o",\u1e4f:"o",\u014d:"o",\u1e51:"o",\u1e53:"o",\u014f:"o",\u022f:"o",\u0231:"o",\u00f6:"o",\u022b:"o",\u1ecf:"o",\u0151:"o",\u01d2:"o",\u020d:"o",\u020f:"o",\u01a1:"o",\u1edd:"o",\u1edb:"o",\u1ee1:"o",\u1edf:"o",\u1ee3:"o",\u1ecd:"o",\u1ed9:"o",\u01eb:"o",\u01ed:"o",\u00f8:"o",\u01ff:"o",\u0254:"o",\ua74b:"o",\ua74d:"o",\u0275:"o",\u01a3:"oi",\u0223:"ou",\ua74f:"oo","\u24df":"p",\uff50:"p",\u1e55:"p",\u1e57:"p",\u01a5:"p",\u1d7d:"p",\ua751:"p",\ua753:"p",\ua755:"p","\u24e0":"q",\uff51:"q",\u024b:"q",\ua757:"q",\ua759:"q","\u24e1":"r",\uff52:"r",\u0155:"r",\u1e59:"r",\u0159:"r",\u0211:"r",\u0213:"r",\u1e5b:"r",\u1e5d:"r",\u0157:"r",\u1e5f:"r",\u024d:"r",\u027d:"r",\ua75b:"r",\ua7a7:"r",\ua783:"r","\u24e2":"s",\uff53:"s",\u00df:"s",\u015b:"s",\u1e65:"s",\u015d:"s",\u1e61:"s",\u0161:"s",\u1e67:"s",\u1e63:"s",\u1e69:"s",\u0219:"s",\u015f:"s",\u023f:"s",\ua7a9:"s",\ua785:"s",\u1e9b:"s","\u24e3":"t",\uff54:"t",\u1e6b:"t",\u1e97:"t",\u0165:"t",\u1e6d:"t",\u021b:"t",\u0163:"t",\u1e71:"t",\u1e6f:"t",\u0167:"t",\u01ad:"t",\u0288:"t",\u2c66:"t",\ua787:"t",\ua729:"tz","\u24e4":"u",\uff55:"u",\u00f9:"u",\u00fa:"u",\u00fb:"u",\u0169:"u",\u1e79:"u",\u016b:"u",\u1e7b:"u",\u016d:"u",\u00fc:"u",\u01dc:"u",\u01d8:"u",\u01d6:"u",\u01da:"u",\u1ee7:"u",\u016f:"u",\u0171:"u",\u01d4:"u",\u0215:"u",\u0217:"u",\u01b0:"u",\u1eeb:"u",\u1ee9:"u",\u1eef:"u",\u1eed:"u",\u1ef1:"u",\u1ee5:"u",\u1e73:"u",\u0173:"u",\u1e77:"u",\u1e75:"u",\u0289:"u","\u24e5":"v",\uff56:"v",\u1e7d:"v",\u1e7f:"v",\u028b:"v",\ua75f:"v",\u028c:"v",\ua761:"vy","\u24e6":"w",\uff57:"w",\u1e81:"w",\u1e83:"w",\u0175:"w",\u1e87:"w",\u1e85:"w",\u1e98:"w",\u1e89:"w",\u2c73:"w","\u24e7":"x",\uff58:"x",\u1e8b:"x",\u1e8d:"x","\u24e8":"y",\uff59:"y",\u1ef3:"y",\u00fd:"y",\u0177:"y",\u1ef9:"y",\u0233:"y",\u1e8f:"y",\u00ff:"y",\u1ef7:"y",\u1e99:"y",\u1ef5:"y",\u01b4:"y",\u024f:"y",\u1eff:"y","\u24e9":"z",\uff5a:"z",\u017a:"z",\u1e91:"z",\u017c:"z",\u017e:"z",\u1e93:"z",\u1e95:"z",\u01b6:"z",\u0225:"z",\u0240:"z",\u2c6c:"z",\ua763:"z",\u0386:"\u0391",\u0388:"\u0395",\u0389:"\u0397",\u038a:"\u0399",\u03aa:"\u0399",\u038c:"\u039f",\u038e:"\u03a5",\u03ab:"\u03a5",\u038f:"\u03a9",\u03ac:"\u03b1",\u03ad:"\u03b5",\u03ae:"\u03b7",\u03af:"\u03b9",\u03ca:"\u03b9",\u0390:"\u03b9",\u03cc:"\u03bf",\u03cd:"\u03c5",\u03cb:"\u03c5",\u03b0:"\u03c5",\u03c9:"\u03c9",\u03c2:"\u03c3"},n.fnOperators={equal:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?n.toLowerCase(t)===n.toLowerCase(e):t===e},notequal:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),!n.fnOperators.equal(t,e,i)},lessthan:function(t,e,i){return i?n.toLowerCase(t)n.toLowerCase(e):t>e},lessthanorequal:function(t,e,i){return i?n.toLowerCase(t)<=n.toLowerCase(e):(m(t)&&(t=void 0),t<=e)},greaterthanorequal:function(t,e,i){return i?n.toLowerCase(t)>=n.toLowerCase(e):t>=e},contains:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?!m(t)&&!m(e)&&-1!==n.toLowerCase(t).indexOf(n.toLowerCase(e)):!m(t)&&!m(e)&&-1!==t.toString().indexOf(e)},doesnotcontain:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?!m(t)&&!m(e)&&-1===n.toLowerCase(t).indexOf(n.toLowerCase(e)):!m(t)&&!m(e)&&-1===t.toString().indexOf(e)},isnotnull:function(t){return null!=t},isnull:function(t){return null==t},startswith:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.startsWith(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.startsWith(t,e)},doesnotstartwith:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.notStartsWith(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.notStartsWith(t,e)},like:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.like(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.like(t,e)},isempty:function(t){return void 0===t||""===t},isnotempty:function(t){return void 0!==t&&""!==t},wildcard:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?(t||"boolean"==typeof t)&&e&&"object"!=typeof t&&n.wildCard(n.toLowerCase(t),n.toLowerCase(e)):(t||"boolean"==typeof t)&&e&&n.wildCard(t,e)},endswith:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.endsWith(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.endsWith(t,e)},doesnotendwith:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.notEndsWith(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.notEndsWith(t,e)},processSymbols:function(t){var e=n.operatorSymbols[t];return e?n.fnOperators[e]:n.throwError("Query - Process Operator : Invalid operator")},processOperator:function(t){return n.fnOperators[t]||n.fnOperators.processSymbols(t)}},n.parse={parseJson:function(t){return"string"!=typeof t||!/^[\s]*\[|^[\s]*\{(.)+:/g.test(t)&&-1!==t.indexOf('"')?t instanceof Array?n.parse.iterateAndReviveArray(t):"object"==typeof t&&null!==t&&n.parse.iterateAndReviveJson(t):t=JSON.parse(t,n.parse.jsonReviver),t},iterateAndReviveArray:function(t){for(var e=0;e-1||e.indexOf("z")>-1,o=e.split(/[^0-9.]/);if(s){if(o[5].indexOf(".")>-1){var a=o[5].split(".");o[5]=a[0],o[6]=new Date(e).getUTCMilliseconds().toString()}else o[6]="00";e=n.dateParse.toTimeZone(new Date(parseInt(o[0],10),parseInt(o[1],10)-1,parseInt(o[2],10),parseInt(o[3],10),parseInt(o[4],10),parseInt(o[5]?o[5]:"00",10),parseInt(o[6],10)),n.serverTimezoneOffset,!1)}else{var l=new Date(parseInt(o[0],10),parseInt(o[1],10)-1,parseInt(o[2],10),parseInt(o[3],10),parseInt(o[4],10),parseInt(o[5]?o[5]:"00",10)),h=parseInt(o[6],10),c=parseInt(o[7],10);if(isNaN(h)&&isNaN(c))return l;e.indexOf("+")>-1?l.setHours(l.getHours()-h,l.getMinutes()-c):l.setHours(l.getHours()+h,l.getMinutes()+c),e=n.dateParse.toTimeZone(l,n.serverTimezoneOffset,!1)}null==n.serverTimezoneOffset&&(e=n.dateParse.addSelfOffset(e))}}return e},isJson:function(t){return"string"==typeof t[0]?t:n.parse.parseJson(t)},isGuid:function(t){return null!=/[A-Fa-f0-9]{8}(?:-[A-Fa-f0-9]{4}){3}-[A-Fa-f0-9]{12}/i.exec(t)},replacer:function(t,e){return n.isPlainObject(t)?n.parse.jsonReplacer(t,e):t instanceof Array?n.parse.arrayReplacer(t):t instanceof Date?n.parse.jsonReplacer({val:t},e).val:t},jsonReplacer:function(t,e){for(var i,s=0,o=Object.keys(t);s=0?"+":"-",s=function(a){var l=Math.floor(Math.abs(a));return(l<10?"0":"")+l};return e.getFullYear()+"-"+s(e.getMonth()+1)+"-"+s(e.getDate())+"T"+s(e.getHours())+":"+s(e.getMinutes())+":"+s(e.getSeconds())+r+s(i/60)+":"+s(i%60)}},n}(),wl=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),BK={GroupGuid:"{271bbba0-1ee7}"},a5=function(){function n(t){this.options={from:"table",requestType:"json",sortBy:"sorted",select:"select",skip:"skip",group:"group",take:"take",search:"search",count:"requiresCounts",where:"where",aggregates:"aggregates",expand:"expand"},this.type=n,this.dataSource=t,this.pvt={}}return n.prototype.processResponse=function(t,e,i,r){return t},n}(),GE=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return wl(t,n),t.prototype.processQuery=function(e,i){for(var a,l,f,r=e.dataSource.json.slice(0),s=r.length,o=!0,h={},c=0,d=[],u=[],p=0;p1?e.sort.filter(function(f){return f.fieldName===c})[0]:e.sort[0];s=this.onSortBy(s,d,e.query,!0)}e.page&&(s=this.onPage(s,e.page,e.query)),this.formGroupResult(s,h)}else{for(var o=e.lazyLoad.onDemandGroupInfo,a=o.where.length-1;a>=0;a--)s=this.onWhere(s,o.where[a]);if(e.group.length!==o.level)s=le.group(s,e.group[o.level].fieldName,r,null,null,e.group[o.level].comparer,!0),e.sort.length&&(s=this.onSortBy(s,e.sort[parseInt(o.level.toString(),10)],e.query,!0));else for(a=e.sort.length-1;a>=o.level;a--)s=this.onSortBy(s,e.sort[parseInt(a.toString(),10)],e.query,!1);i=s.length,h=s,s=(s=s.slice(o.skip)).slice(0,o.take),e.group.length!==o.level&&this.formGroupResult(s,h)}return{result:s,count:i}},t.prototype.formGroupResult=function(e,i){if(e.length&&i.length){var r="GroupGuid",s="childLevels",o="level",a="records";e[r]=i[r],e[s]=i[s],e[o]=i[o],e[a]=i[a]}return e},t.prototype.getAggregate=function(e){var i=_t.filterQueries(e.queries,"onAggregates"),r=[];if(i.length)for(var s=void 0,o=0;o=0;l--)a[l]&&(o=i.comparer,le.endsWith(a[l]," desc")&&(o=le.fnSort("descending"),a[l]=a[l].replace(" desc","")),e=le.sort(e,a[l],o));return e}return le.sort(e,s?"key":a,i.comparer)},t.prototype.onGroup=function(e,i,r){if(!e||!e.length)return e;var s=this.getAggregate(r);return le.group(e,le.getValue(i.fieldName,r),s,null,null,i.comparer)},t.prototype.onPage=function(e,i,r){var s=le.getValue(i.pageSize,r),o=(le.getValue(i.pageIndex,r)-1)*s;return e&&e.length?e.slice(o,o+s):e},t.prototype.onRange=function(e,i){return e&&e.length?e.slice(le.getValue(i.start),le.getValue(i.end)):e},t.prototype.onTake=function(e,i){return e&&e.length?e.slice(0,le.getValue(i.nos)):e},t.prototype.onSkip=function(e,i){return e&&e.length?e.slice(le.getValue(i.nos)):e},t.prototype.onSelect=function(e,i){return e&&e.length?le.select(e,le.getValue(i.fieldNames)):e},t.prototype.insert=function(e,i,r,s,o){return m(o)?e.dataSource.json.push(i):e.dataSource.json.splice(o,0,i)},t.prototype.remove=function(e,i,r,s){var a,o=e.dataSource.json;for("object"==typeof r&&!(r instanceof Date)&&(r=le.getObject(i,r)),a=0;a1&&(g="("+g+")"),f.filters.push(g);for(var y=0,S="object"==typeof f.filters[p]?Object.keys(f.filters[p]):[];y-1&&this.formRemoteGroupedData(e[s].items,i+1,r-1);var o="GroupGuid",h="records";return e[o]=BK[o],e.level=i,e.childLevels=r,e[h]=e[0].items.length?this.getGroupedRecords(e,!m(e[0].items[h])):[],e},t.prototype.getGroupedRecords=function(e,i){for(var r=[],o=0;ol.length-3?(l=l.substring(0,l.length-1),o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.endswith:le.odv4UniOperator.endswith):l.lastIndexOf("%")!==l.indexOf("%")&&l.lastIndexOf("%")>l.indexOf("%")+1?(l=l.substring(l.indexOf("%")+1,l.lastIndexOf("%")),o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains):o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains),l="'"+(l=encodeURIComponent(l))+"'";else if("wildcard"===o)if(-1!==l.indexOf("*")){var d=l.split("*"),u=void 0,f=0;if(0!==l.indexOf("*")&&-1===d[0].indexOf("%3f")&&-1===d[0].indexOf("?")&&(u="'"+(u=d[0])+"'",s+=(o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.startswith:le.odv4UniOperator.startswith)+"(",s+=c+",",a&&(s+=a),s+=u+")",f++),l.lastIndexOf("*")!==l.length-1&&-1===d[d.length-1].indexOf("%3f")&&-1===d[d.length-1].indexOf("?")&&(u="'"+(u=d[d.length-1])+"'",f>0&&(s+=" and "),s+=(o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.endswith:le.odv4UniOperator.endswith)+"(",s+=c+",",a&&(s+=a),s+=u+")",f++),d.length>2)for(var p=1;p0&&(s+=" and "),"substringof"===(o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains)||"not substringof"===o){var g=u;u=c,c=g}s+=o+"(",s+=c+",",a&&(s+=a),s+=u+")",f++}0===f?(o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains,(-1!==l.indexOf("?")||-1!==l.indexOf("%3f"))&&(l=-1!==l.indexOf("?")?l.split("?").join(""):l.split("%3f").join("")),l="'"+l+"'"):o="wildcard"}else o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains,(-1!==l.indexOf("?")||-1!==l.indexOf("%3f"))&&(l=-1!==l.indexOf("?")?l.split("?").join(""):l.split("%3f").join("")),l="'"+l+"'";return"substringof"!==o&&"not substringof"!==o||(g=l,l=c,c=g),"wildcard"!==o&&(s+=o+"(",s+=c+",",a&&(s+=a),s+=l+")"),s},t.prototype.addParams=function(e){n.prototype.addParams.call(this,e),delete e.reqParams.params},t.prototype.onComplexPredicate=function(e,i,r){for(var s=[],o=0;o-1;f--)!/\bContent-ID:/i.test(c[f])||!/\bHTTP.+201/.test(c[f])||(l=parseInt(/\bContent-ID: (\d+)/i.exec(c[f])[1],10),o.addedRecords[l]&&(h=le.parse.parseJson(/^\{.+\}/m.exec(c[f])[0]),ze({},o.addedRecords[l],this.processResponse(h))));return o}return null},t.prototype.compareAndRemove=function(e,i,r){var s=this;return m(i)||Object.keys(e).forEach(function(o){o!==r&&"@odata.etag"!==o&&(le.isPlainObject(e[o])?(s.compareAndRemove(e[o],i[o]),0===Object.keys(e[o]).filter(function(l){return"@odata.etag"!==l}).length&&delete e[o]):(e[o]===i[o]||e[o]&&i[o]&&e[o].valueOf()===i[o].valueOf())&&delete e[o])}),e},t}(fc),FK=function(n){function t(){var e=n.call(this)||this;return yt("beforeSend",fc.prototype.beforeSend,e),e}return wl(t,n),t.prototype.insert=function(e,i,r,s,o){return this.pvt.position=o,this.updateType="add",{url:e.dataSource.insertUrl||e.dataSource.crudUrl||e.dataSource.url,data:JSON.stringify(ze({},{value:i,table:r,action:"insert"},le.getAddParams(this,e,s)))}},t.prototype.remove=function(e,i,r,s,o){return n.prototype.remove.call(this,e,i,r),{type:"POST",url:e.dataSource.removeUrl||e.dataSource.crudUrl||e.dataSource.url,data:JSON.stringify(ze({},{key:r,keyColumn:i,table:s,action:"remove"},le.getAddParams(this,e,o)))}},t.prototype.update=function(e,i,r,s,o){return this.updateType="update",this.updateKey=i,{type:"POST",url:e.dataSource.updateUrl||e.dataSource.crudUrl||e.dataSource.url,data:JSON.stringify(ze({},{value:r,action:"update",keyColumn:i,key:r[i],table:s},le.getAddParams(this,e,o)))}},t.prototype.processResponse=function(e,i,r,s,o,a,l){var h;if(e="batch"===(o?JSON.parse(o.data):e).action?le.parse.parseJson(e):e,"add"===this.updateType&&n.prototype.insert.call(this,i,e,null,null,this.pvt.position),"update"===this.updateType&&n.prototype.update.call(this,i,this.updateKey,e),this.updateType=void 0,e.added)for(h=0;hi&&h.push(c)}for(c=0;cthis.pageSize;)h.results.splice(0,1),h.keys.splice(0,1);return window.localStorage.setItem(this.guidId,JSON.stringify(h)),e},t.prototype.beforeSend=function(e,i,r){!m(this.cacheAdaptor.options.batch)&&le.endsWith(r.url,this.cacheAdaptor.options.batch)&&"post"===r.type.toLowerCase()&&i.headers.set("Accept",this.cacheAdaptor.options.multipartAccept),e.dataSource.crossDomain||i.headers.set("Accept",this.cacheAdaptor.options.accept)},t.prototype.update=function(e,i,r,s){return this.isCrudAction=!0,this.cacheAdaptor.update(e,i,r,s)},t.prototype.insert=function(e,i,r){return this.isInsertAction=!0,this.cacheAdaptor.insert(e,i,r)},t.prototype.remove=function(e,i,r,s){return this.isCrudAction=!0,this.cacheAdaptor.remove(e,i,r,s)},t.prototype.batchRequest=function(e,i,r){return this.cacheAdaptor.batchRequest(e,i,r)},t}(fc),it=function(){function n(t,e,i){var s,r=this;return this.dateParse=!0,this.timeZoneHandling=!0,this.persistQuery={},this.isInitialLoad=!1,this.requests=[],this.isInitialLoad=!0,!t&&!this.dataSource&&(t=[]),i=i||t.adaptor,t&&!1===t.timeZoneHandling&&(this.timeZoneHandling=t.timeZoneHandling),t instanceof Array?s={json:t,offline:!0}:"object"==typeof t?(t.json||(t.json=[]),t.enablePersistence||(t.enablePersistence=!1),t.id||(t.id=""),t.ignoreOnPersist||(t.ignoreOnPersist=[]),s={url:t.url,insertUrl:t.insertUrl,removeUrl:t.removeUrl,updateUrl:t.updateUrl,crudUrl:t.crudUrl,batchUrl:t.batchUrl,json:t.json,headers:t.headers,accept:t.accept,data:t.data,timeTillExpiration:t.timeTillExpiration,cachingPageSize:t.cachingPageSize,enableCaching:t.enableCaching,requestType:t.requestType,key:t.key,crossDomain:t.crossDomain,jsonp:t.jsonp,dataType:t.dataType,offline:void 0!==t.offline?t.offline:!(t.adaptor instanceof FK||t.adaptor instanceof _K||t.url),requiresFormat:t.requiresFormat,enablePersistence:t.enablePersistence,id:t.id,ignoreOnPersist:t.ignoreOnPersist}):le.throwError("DataManager: Invalid arguments"),void 0===s.requiresFormat&&!le.isCors()&&(s.requiresFormat=!!m(s.crossDomain)||s.crossDomain),void 0===s.dataType&&(s.dataType="json"),this.dataSource=s,this.defaultQuery=e,this.dataSource.enablePersistence&&this.dataSource.id&&window.addEventListener("unload",this.setPersistData.bind(this)),s.url&&s.offline&&!s.json.length?(this.isDataAvailable=!1,this.adaptor=i||new vf,this.dataSource.offline=!1,this.ready=this.executeQuery(e||new _t),this.ready.then(function(o){r.dataSource.offline=!0,r.isDataAvailable=!0,s.json=o.result,r.adaptor=new GE})):this.adaptor=s.offline?new GE:new vf,!s.jsonp&&this.adaptor instanceof vf&&(s.jsonp="callback"),this.adaptor=i||this.adaptor,s.enableCaching&&(this.adaptor=new UK(this.adaptor,s.timeTillExpiration,s.cachingPageSize)),this}return Object.defineProperty(n.prototype,"moduleName",{get:function(){return"datamanager"},enumerable:!0,configurable:!0}),n.prototype.getPersistedData=function(t){var e=localStorage.getItem(t||this.dataSource.id);return JSON.parse(e)},n.prototype.setPersistData=function(t,e,i){localStorage.setItem(e||this.dataSource.id,JSON.stringify(i||this.persistQuery))},n.prototype.setPersistQuery=function(t){var e=this,i=this.getPersistedData();if(this.isInitialLoad&&i&&Object.keys(i).length){this.persistQuery=i,this.persistQuery.queries=this.persistQuery.queries.filter(function(s){if(e.dataSource.ignoreOnPersist&&e.dataSource.ignoreOnPersist.length&&s.fn&&e.dataSource.ignoreOnPersist.some(function(l){return s.fn===l}))return!1;if("onWhere"===s.fn){var o=s.e;if(o&&o.isComplex&&o.predicates instanceof Array){var a=o.predicates.map(function(l){if(l.predicates&&l.predicates instanceof Array){var h=l.predicates.map(function(v){return new Ss(v.field,v.operator,v.value,v.ignoreCase,v.ignoreAccent,v.matchCase)});return"and"===l.condition?Ss.and(h):Ss.or(h)}return new Ss(l.field,l.operator,l.value,l.ignoreCase,l.ignoreAccent,l.matchCase)});s.e=new Ss(a[0],o.condition,a.slice(1))}}return!0});var r=ze(new _t,this.persistQuery);return this.isInitialLoad=!1,r}return this.persistQuery=t,this.isInitialLoad=!1,t},n.prototype.setDefaultQuery=function(t){return this.defaultQuery=t,this},n.prototype.executeLocal=function(t){!this.defaultQuery&&!(t instanceof _t)&&le.throwError("DataManager - executeLocal() : A query is required to execute"),this.dataSource.json||le.throwError("DataManager - executeLocal() : Json data is required to execute"),this.dataSource.enablePersistence&&this.dataSource.id&&(t=this.setPersistQuery(t));var e=this.adaptor.processQuery(this,t=t||this.defaultQuery);if(t.subQuery){var i=t.subQuery.fromTable,r=t.subQuery.lookups,s=t.isCountRequired?e.result:e;r&&r instanceof Array&&le.buildHierarchy(t.subQuery.fKey,i,s,r,t.subQuery.key);for(var o=0;oli");z.classList.remove("json-parent");for(var j=0;j',W=ve.children[0].placeholder}return W}function Q(k,W,ve){!m(ve)&&""!==ve&&K(W,ve.split(" ")),!m(k)&&""!==k&&V(W,k.split(" "))}function oe(k,W,ve){if("multiselect"===ve||function Mo(k){if(!k)return!1;for(var W=k;W&&W!==document.body;){if("none"===window.getComputedStyle(W).display)return!1;W=W.parentElement}return!0}(k)){var Te="multiselect"===ve?k:k.clientWidth-parseInt(getComputedStyle(k,null).getPropertyValue("padding-left"),10);!m(W)&&!m(W.getElementsByClassName("e-float-text-content")[0])&&(W.getElementsByClassName("e-float-text-content")[0].classList.contains("e-float-text-overflow")&&W.getElementsByClassName("e-float-text-content")[0].classList.remove("e-float-text-overflow"),(Te0)for(var Ye=0;Ye<_e.length;Ye++)_e[parseInt(Ye.toString(),10)].addEventListener("mousedown",wo,!1),_e[parseInt(Ye.toString(),10)].addEventListener("mouseup",Ul,!1);else if(_e.length>0)for(Ye=0;Ye<_e.length;Ye++)_e[parseInt(Ye.toString(),10)].removeEventListener("mousedown",wo,this),_e[parseInt(Ye.toString(),10)].removeEventListener("mouseup",Ul,this)}function wo(){for(var W=this.parentElement;!W.classList.contains("e-input-group");)W=W.parentElement;!function Sa(k,W){!k.classList.contains("e-disabled")&&!k.querySelector("input").readOnly&&W.classList.add("e-input-btn-ripple")}(W,this)}function Ul(){var k=this;setTimeout(function(){k.classList.remove("e-input-btn-ripple")},500)}function yb(k,W){var ve=W("span",{className:k});return ve.classList.add("e-input-group-icon"),ve}function I_(k,W,ve,Te){var _e=m(Te)?Si:Te,Ye=yb(k,_e);W.classList.add("e-float-icon-left");var vi=W.querySelector(".e-input-in-wrap");if(m(vi)){vi=_e("span",{className:"e-input-in-wrap"}),ve.parentNode.insertBefore(vi,ve);var Gs=W.querySelectorAll(ve.tagName+" ~ *");vi.appendChild(ve);for(var ts=0;ts-1)if("class"===_e){var Ye=this.getInputValidClassList(k[""+_e]);""!==Ye&&V([W],Ye.split(" "))}else if("style"===_e){var vi=W.getAttribute(_e);vi=m(vi)?k[""+_e]:vi+k[""+_e],W.setAttribute(_e,vi)}else W.setAttribute(_e,k[""+_e])}},n.isBlank=function Hle(k){return!k||/^\s*$/.test(k)}}(Le||(Le={})),new RegExp("^(-)?(\\d*)$"),new RegExp("^[A-Za-z0-9._%+-]{1,}@[A-Za-z0-9._%+-]{1,}([.]{1}[a-zA-Z0-9]{2,}|[.]{1}[a-zA-Z0-9]{2,4}[.]{1}[a-zA-Z0-9]{2,4})$"),new RegExp("^([0-9]{4})-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])$"),new RegExp("^[0-9]*$"),new RegExp("^[+]?[0-9]{9,13}$"),new RegExp("^\\d{13,16}$");var me=function(){function n(t,e){this.width=t,this.height=e}return n.prototype.isEmpty=function(){return 0===this.height&&0===this.width},n.prototype.clone=function(){return new n(this.width,this.height)},n}(),Rie=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),KB=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},R=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Rie(t,n),t.equals=function(e,i){return e===i||!(!e||!i)&&(!e||!i||e.x===i.x&&e.y===i.y)},t.isEmptyPoint=function(e){return!(e.x&&e.y)},t.transform=function(e,i,r){var s={x:0,y:0};return s.x=Math.round(100*(e.x+r*Math.cos(i*Math.PI/180)))/100,s.y=Math.round(100*(e.y+r*Math.sin(i*Math.PI/180)))/100,s},t.findLength=function(e,i){return Math.sqrt(Math.pow(e.x-i.x,2)+Math.pow(e.y-i.y,2))},t.findAngle=function(e,i){var r=Math.atan2(i.y-e.y,i.x-e.x);return r=180*r/Math.PI,(r%=360)<0&&(r+=360),r},t.distancePoints=function(e,i){return Math.sqrt(Math.pow(i.x-e.x,2)+Math.pow(i.y-e.y,2))},t.getLengthFromListOfPoints=function(e){for(var i=0,r=0;ri.y&&!r?o.y+=s:o.y-=s:e.y===i.y?e.xi.x&&!r?o.x+=s:o.x-=s:r?(a=this.findAngle(e,i),o=this.transform(e,a,s)):(a=this.findAngle(i,e),o=this.transform(i,a,s)),o},t.direction=function(e,i){return Math.abs(i.x-e.x)>Math.abs(i.y-e.y)?e.x0)for(var r=0;rt.right||this.top>t.bottom||this.bottom=t.right&&this.top<=t.top&&this.bottom>=t.bottom},n.prototype.containsPoint=function(t,e){return void 0===e&&(e=0),this.left-e<=t.x&&this.right+e>=t.x&&this.top-e<=t.y&&this.bottom+e>=t.y},n.toBounds=function(t){for(var e=new n,i=0,r=t;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},s3=function(n){if(n)switch(n.type){case"Linear":default:return wI;case"Radial":return Gie}return wI},Yie=function(){return function n(t,e,i,r){this.left=t,this.right=e,this.top=i,this.bottom=r}}(),Jn=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),rt([I(0)],t.prototype,"left",void 0),rt([I(0)],t.prototype,"right",void 0),rt([I(0)],t.prototype,"top",void 0),rt([I(0)],t.prototype,"bottom",void 0),t}(Ee),Qie=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),rt([I(45)],t.prototype,"angle",void 0),rt([I(5)],t.prototype,"distance",void 0),rt([I(.7)],t.prototype,"opacity",void 0),rt([I("lightgrey")],t.prototype,"color",void 0),t}(Ee),o3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),t.prototype.getClassName=function(){return"Stop"},rt([I("")],t.prototype,"color",void 0),rt([I(0)],t.prototype,"offset",void 0),rt([I(1)],t.prototype,"opacity",void 0),t}(Ee),wx=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),rt([Bt([],o3)],t.prototype,"stops",void 0),rt([I("None")],t.prototype,"type",void 0),rt([I("")],t.prototype,"id",void 0),t}(Ee),wI=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),rt([I(0)],t.prototype,"x1",void 0),rt([I(0)],t.prototype,"x2",void 0),rt([I(0)],t.prototype,"y1",void 0),rt([I(0)],t.prototype,"y2",void 0),t}(wx),Gie=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),rt([I(0)],t.prototype,"cx",void 0),rt([I(0)],t.prototype,"cy",void 0),rt([I(0)],t.prototype,"fx",void 0),rt([I(0)],t.prototype,"fy",void 0),rt([I(50)],t.prototype,"r",void 0),t}(wx),Nl=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),rt([I("white")],t.prototype,"fill",void 0),rt([I("black")],t.prototype,"strokeColor",void 0),rt([I("")],t.prototype,"strokeDashArray",void 0),rt([I(1)],t.prototype,"strokeWidth",void 0),rt([I(1)],t.prototype,"opacity",void 0),rt([T0(s3)],t.prototype,"gradient",void 0),t}(Ee),a3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),rt([I("transparent")],t.prototype,"fill",void 0),t}(Nl),Xf=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),rt([I("black")],t.prototype,"color",void 0),rt([I("Arial")],t.prototype,"fontFamily",void 0),rt([I(12)],t.prototype,"fontSize",void 0),rt([I(!1)],t.prototype,"italic",void 0),rt([I(!1)],t.prototype,"bold",void 0),rt([I("CollapseSpace")],t.prototype,"whiteSpace",void 0),rt([I("WrapWithOverflow")],t.prototype,"textWrapping",void 0),rt([I("Center")],t.prototype,"textAlign",void 0),rt([I("None")],t.prototype,"textDecoration",void 0),rt([I("Wrap")],t.prototype,"textOverflow",void 0),rt([I("transparent")],t.prototype,"fill",void 0),t}(Nl),on=function(n){return n[n.Default=0]="Default",n[n.expandNode=2]="expandNode",n[n.interaction=4]="interaction",n[n.GroupingInProgress=8]="GroupingInProgress",n[n.GroupClipboardInProcess=16]="GroupClipboardInProcess",n[n.ClearObject=32]="ClearObject",n}(on||{}),ci=function(n){return n[n.Visible=1]="Visible",n[n.Hidden=2]="Hidden",n[n.Hover=4]="Hover",n[n.Connect=8]="Connect",n}(ci||{}),Kt=function(n){return n[n.None=0]="None",n[n.ShowHorizontalLines=1]="ShowHorizontalLines",n[n.ShowVerticalLines=2]="ShowVerticalLines",n[n.ShowLines=3]="ShowLines",n[n.SnapToHorizontalLines=4]="SnapToHorizontalLines",n[n.SnapToVerticalLines=8]="SnapToVerticalLines",n[n.SnapToLines=12]="SnapToLines",n[n.SnapToObject=16]="SnapToObject",n[n.All=31]="All",n}(Kt||{}),mr=function(n){return n[n.None=1]="None",n[n.ConnectorSourceThumb=2]="ConnectorSourceThumb",n[n.ConnectorTargetThumb=4]="ConnectorTargetThumb",n[n.ResizeSouthEast=8]="ResizeSouthEast",n[n.ResizeSouthWest=16]="ResizeSouthWest",n[n.ResizeNorthEast=32]="ResizeNorthEast",n[n.ResizeNorthWest=64]="ResizeNorthWest",n[n.ResizeEast=128]="ResizeEast",n[n.ResizeWest=256]="ResizeWest",n[n.ResizeSouth=512]="ResizeSouth",n[n.ResizeNorth=1024]="ResizeNorth",n[n.Rotate=2048]="Rotate",n[n.UserHandle=4096]="UserHandle",n[n.ToolTip=8192]="ToolTip",n[n.ResizeAll=2046]="ResizeAll",n[n.All=16382]="All",n}(mr||{}),qe=function(n){return n[n.None=1]="None",n[n.Select=2]="Select",n[n.Delete=4]="Delete",n[n.Drag=8]="Drag",n[n.DragSourceEnd=16]="DragSourceEnd",n[n.DragTargetEnd=32]="DragTargetEnd",n[n.DragSegmentThumb=64]="DragSegmentThumb",n[n.AllowDrop=128]="AllowDrop",n[n.Bridging=256]="Bridging",n[n.BridgeObstacle=512]="BridgeObstacle",n[n.InheritBridging=1024]="InheritBridging",n[n.PointerEvents=2048]="PointerEvents",n[n.Tooltip=4096]="Tooltip",n[n.InheritTooltip=8192]="InheritTooltip",n[n.Interaction=4218]="Interaction",n[n.ReadOnly=16384]="ReadOnly",n[n.LineRouting=32768]="LineRouting",n[n.InheritLineRouting=65536]="InheritLineRouting",n[n.ConnectToNearByNode=131072]="ConnectToNearByNode",n[n.ConnectToNearByPort=262144]="ConnectToNearByPort",n[n.ConnectToNearByElement=393216]="ConnectToNearByElement",n[n.InheritSegmentThumbShape=524288]="InheritSegmentThumbShape",n[n.InheritSegmentThumbSize=1048576]="InheritSegmentThumbSize",n[n.Default=2043454]="Default",n}(qe||{}),Nr=function(n){return n[n.ReadOnly=2]="ReadOnly",n[n.InheritReadOnly=4]="InheritReadOnly",n[n.Select=8]="Select",n[n.Drag=16]="Drag",n[n.Resize=32]="Resize",n[n.Rotate=64]="Rotate",n[n.Tooltip=128]="Tooltip",n[n.Interaction=120]="Interaction",n[n.None=0]="None",n}(Nr||{}),ie=function(n){return n[n.None=0]="None",n[n.Select=2]="Select",n[n.Drag=4]="Drag",n[n.Rotate=8]="Rotate",n[n.Shadow=16]="Shadow",n[n.PointerEvents=32]="PointerEvents",n[n.Delete=64]="Delete",n[n.InConnect=128]="InConnect",n[n.OutConnect=256]="OutConnect",n[n.Individual=512]="Individual",n[n.Expandable=1024]="Expandable",n[n.AllowDrop=2048]="AllowDrop",n[n.Inherit=78]="Inherit",n[n.ResizeNorthEast=4096]="ResizeNorthEast",n[n.ResizeEast=8192]="ResizeEast",n[n.ResizeSouthEast=16384]="ResizeSouthEast",n[n.ResizeSouth=32768]="ResizeSouth",n[n.ResizeSouthWest=65536]="ResizeSouthWest",n[n.ResizeWest=131072]="ResizeWest",n[n.ResizeNorthWest=262144]="ResizeNorthWest",n[n.ResizeNorth=524288]="ResizeNorth",n[n.Resize=1044480]="Resize",n[n.AspectRatio=1048576]="AspectRatio",n[n.Tooltip=2097152]="Tooltip",n[n.InheritTooltip=4194304]="InheritTooltip",n[n.ReadOnly=8388608]="ReadOnly",n[n.HideThumbs=16777216]="HideThumbs",n[n.AllowMovingOutsideLane=33554432]="AllowMovingOutsideLane",n[n.Default=5240814]="Default",n}(ie||{}),Xr=function(n){return n[n.None=0]="None",n[n.ElementIsPort=2]="ElementIsPort",n[n.ElementIsGroup=4]="ElementIsGroup",n[n.HorizontalLaneHeader=8]="HorizontalLaneHeader",n}(Xr||{}),bt=function(n){return n[n.Rotate=2]="Rotate",n[n.ConnectorSource=4]="ConnectorSource",n[n.ConnectorTarget=8]="ConnectorTarget",n[n.ResizeNorthEast=16]="ResizeNorthEast",n[n.ResizeEast=32]="ResizeEast",n[n.ResizeSouthEast=64]="ResizeSouthEast",n[n.ResizeSouth=128]="ResizeSouth",n[n.ResizeSouthWest=256]="ResizeSouthWest",n[n.ResizeWest=512]="ResizeWest",n[n.ResizeNorthWest=1024]="ResizeNorthWest",n[n.ResizeNorth=2048]="ResizeNorth",n[n.Default=4094]="Default",n}(bt||{}),nt=function(n){return n[n.None=1]="None",n[n.Bridging=2]="Bridging",n[n.UndoRedo=4]="UndoRedo",n[n.Tooltip=8]="Tooltip",n[n.UserInteraction=16]="UserInteraction",n[n.ApiUpdate=32]="ApiUpdate",n[n.PageEditable=48]="PageEditable",n[n.Zoom=64]="Zoom",n[n.PanX=128]="PanX",n[n.PanY=256]="PanY",n[n.Pan=384]="Pan",n[n.ZoomTextEdit=512]="ZoomTextEdit",n[n.Virtualization=1024]="Virtualization",n[n.LineRouting=2048]="LineRouting",n[n.Default=500]="Default",n}(nt||{}),ri=function(n){return n[n.None=0]="None",n[n.SingleSelect=1]="SingleSelect",n[n.MultipleSelect=2]="MultipleSelect",n[n.ZoomPan=4]="ZoomPan",n[n.DrawOnce=8]="DrawOnce",n[n.ContinuousDraw=16]="ContinuousDraw",n[n.Default=3]="Default",n}(ri||{}),Qa=function(n){return n[n.Self=1]="Self",n[n.Parent=2]="Parent",n}(Qa||{}),ft=function(n){return n[n.None=0]="None",n[n.Control=1]="Control",n[n.Meta=1]="Meta",n[n.Alt=2]="Alt",n[n.Shift=4]="Shift",n}(ft||{}),Mt=function(n){return n[n.None=null]="None",n[n.Number0=0]="Number0",n[n.Number1=1]="Number1",n[n.Number2=2]="Number2",n[n.Number3=3]="Number3",n[n.Number4=4]="Number4",n[n.Number5=5]="Number5",n[n.Number6=6]="Number6",n[n.Number7=7]="Number7",n[n.Number8=8]="Number8",n[n.Number9=9]="Number9",n[n.A=65]="A",n[n.B=66]="B",n[n.C=67]="C",n[n.D=68]="D",n[n.E=69]="E",n[n.F=70]="F",n[n.G=71]="G",n[n.H=72]="H",n[n.I=73]="I",n[n.J=74]="J",n[n.K=75]="K",n[n.L=76]="L",n[n.M=77]="M",n[n.N=78]="N",n[n.O=79]="O",n[n.P=80]="P",n[n.Q=81]="Q",n[n.R=82]="R",n[n.S=83]="S",n[n.T=84]="T",n[n.U=85]="U",n[n.V=86]="V",n[n.W=87]="W",n[n.X=88]="X",n[n.Y=89]="Y",n[n.Z=90]="Z",n[n.Left=37]="Left",n[n.Up=38]="Up",n[n.Right=39]="Right",n[n.Down=40]="Down",n[n.Escape=27]="Escape",n[n.Space=32]="Space",n[n.PageUp=33]="PageUp",n[n.PageDown=34]="PageDown",n[n.End=35]="End",n[n.Home=36]="Home",n[n.Delete=46]="Delete",n[n.Tab=9]="Tab",n[n.Enter=13]="Enter",n[n.BackSpace=8]="BackSpace",n[n.F1=112]="F1",n[n.F2=113]="F2",n[n.F3=114]="F3",n[n.F4=115]="F4",n[n.F5=116]="F5",n[n.F6=117]="F6",n[n.F7=118]="F7",n[n.F8=119]="F8",n[n.F9=120]="F9",n[n.F10=121]="F10",n[n.F11=122]="F11",n[n.F12=123]="F12",n[n.Star=56]="Star",n[n.Plus=187]="Plus",n[n.Minus=189]="Minus",n[n.BracketLeft=219]="BracketLeft",n[n.BracketRight=221]="BracketRight",n}(Mt||{}),ee=function(n){return n[n.Render=2]="Render",n[n.PublicMethod=4]="PublicMethod",n[n.ToolAction=8]="ToolAction",n[n.UndoRedo=16]="UndoRedo",n[n.TextEdit=32]="TextEdit",n[n.Group=64]="Group",n[n.Clear=128]="Clear",n[n.PreventClearSelection=256]="PreventClearSelection",n[n.Interactions=512]="Interactions",n[n.PreventHistory=1024]="PreventHistory",n[n.PreventIconsUpdate=2048]="PreventIconsUpdate",n[n.PreventCollectionChangeOnDragOver=4096]="PreventCollectionChangeOnDragOver",n[n.PreventZIndexOnDragging=8192]="PreventZIndexOnDragging",n[n.isGroupDragging=16384]="isGroupDragging",n[n.DragUsingMouse=32768]="DragUsingMouse",n[n.DecoratorPropertyChange=65536]="DecoratorPropertyChange",n[n.PreventLaneContainerUpdate=131072]="PreventLaneContainerUpdate",n}(ee||{}),Ga=function(n){return n[n.None=2]="None",n[n.DrawSelectorBorder=4]="DrawSelectorBorder",n[n.PreventRenderSelector=8]="PreventRenderSelector",n}(Ga||{}),$i=function(n){return n[n.None=0]="None",n[n.PreventDrag=2]="PreventDrag",n[n.PreventScale=4]="PreventScale",n[n.PreventDataInit=8]="PreventDataInit",n[n.hScrollbarMoved=16]="hScrollbarMoved",n[n.vScrollbarMoved=32]="vScrollbarMoved",n[n.AnimationClick=64]="AnimationClick",n[n.EnableGroupAction=128]="EnableGroupAction",n[n.PanInProgress=256]="PanInProgress",n[n.OverViewAction=512]="OverViewAction",n}($i||{}),da=function(n){return n[n.None=0]="None",n[n.PropertyChange=1024]="PropertyChange",n[n.Interaction=2048]="Interaction",n}(da||{}),Ae=function(n){return n[n.Zero=0]="Zero",n[n.One=1]="One",n[n.Two=2]="Two",n[n.Three=3]="Three",n[n.Four=4]="Four",n[n.Five=5]="Five",n}(Ae||{}),Ce=function(n){return n[n.collectionChange=0]="collectionChange",n[n.rotateChange=1]="rotateChange",n[n.positionChange=2]="positionChange",n[n.propertyChange=3]="propertyChange",n[n.selectionChange=4]="selectionChange",n[n.sizeChange=5]="sizeChange",n[n.drop=6]="drop",n[n.sourcePointChange=7]="sourcePointChange",n[n.targetPointChange=8]="targetPointChange",n[n.connectionChange=9]="connectionChange",n[n.animationComplete=10]="animationComplete",n[n.click=11]="click",n[n.doubleClick=12]="doubleClick",n[n.scrollChange=13]="scrollChange",n[n.dragEnter=14]="dragEnter",n[n.dragLeave=15]="dragLeave",n[n.dragOver=16]="dragOver",n[n.textEdit=17]="textEdit",n[n.paletteSelectionChange=18]="paletteSelectionChange",n[n.historyChange=19]="historyChange",n[n.mouseEnter=20]="mouseEnter",n[n.mouseLeave=21]="mouseLeave",n[n.mouseOver=22]="mouseOver",n[n.expandStateChange=23]="expandStateChange",n[n.segmentCollectionChange=24]="segmentCollectionChange",n[n.commandExecute=25]="commandExecute",n[n.historyStateChange=26]="historyStateChange",n[n.onUserHandleMouseDown=27]="onUserHandleMouseDown",n[n.onUserHandleMouseUp=28]="onUserHandleMouseUp",n[n.onUserHandleMouseEnter=29]="onUserHandleMouseEnter",n[n.onUserHandleMouseLeave=30]="onUserHandleMouseLeave",n[n.onImageLoad=31]="onImageLoad",n[n.onDoBindingInit=32]="onDoBindingInit",n[n.keyUp=33]="keyUp",n[n.keyDown=34]="keyDown",n[n.fixedUserHandleClick=35]="fixedUserHandleClick",n[n.elementDraw=36]="elementDraw",n[n.mouseWheel=37]="mouseWheel",n[n.segmentChange=38]="segmentChange",n[n.onFixedUserHandleMouseDown=39]="onFixedUserHandleMouseDown",n[n.onFixedUserHandleMouseUp=40]="onFixedUserHandleMouseUp",n[n.onFixedUserHandleMouseEnter=41]="onFixedUserHandleMouseEnter",n[n.onFixedUserHandleMouseLeave=42]="onFixedUserHandleMouseLeave",n[n.loaded=43]="loaded",n}(Ce||{}),oi=function(n){return n[n.None=1]="None",n[n.Drag=2]="Drag",n[n.Draw=4]="Draw",n[n.InConnect=8]="InConnect",n[n.OutConnect=16]="OutConnect",n[n.ToolTip=32]="ToolTip",n[n.InheritTooltip=64]="InheritTooltip",n[n.Default=24]="Default",n}(oi||{}),Cx=function(n){return n[n.None=1]="None",n[n.Source=2]="Source",n[n.Target=4]="Target",n[n.Intermediate=8]="Intermediate",n[n.All=14]="All",n}(Cx||{}),CI=function(n){return n[n.None=0]="None",n[n.SymmetricAngle=2]="SymmetricAngle",n[n.SymmetricDistance=4]="SymmetricDistance",n[n.Default=6]="Default",n}(CI||{}),hs=function(){function n(){this.pivot={x:.5,y:.5},this.isDirt=!0,this.isExport=!1,this.exportScaleValue={x:0,y:0},this.exportScaleOffset={x:0,y:0},this.canApplyStyle=!0,this.visible=!0,this.offsetX=0,this.offsetY=0,this.cornerRadius=0,this.minHeight=void 0,this.minWidth=void 0,this.maxWidth=void 0,this.maxHeight=void 0,this.width=void 0,this.height=void 0,this.rotateAngle=0,this.margin={left:0,right:0,top:0,bottom:0},this.connectionDirection="Auto",this.horizontalAlignment="Auto",this.verticalAlignment="Auto",this.flip="None",this.flipMode="All",this.relativeMode="Point",this.transform=Qa.Self|Qa.Parent,this.style={fill:"white",strokeColor:"black",opacity:1,strokeWidth:1},this.desiredSize=new me,this.actualSize=new me,this.parentTransform=0,this.preventContainer=!1,this.isSvgRender=!1,this.bounds=new Ne(0,0,0,0),this.shadow=null,this.description="",this.staticSize=!1,this.shapeType="",this.isRectElement=!1,this.isCalculateDesiredSize=!0,this.flipOffset={x:0,y:0},this.elementActions=Xr.None,this.inversedAlignment=!0,this.position=void 0,this.unitMode=void 0,this.float=!1,this.floatingBounds=void 0}return n.prototype.setOffsetWithRespectToBounds=function(t,e,i){this.unitMode=i,this.position={x:t,y:e}},n.prototype.getAbsolutePosition=function(t){if(void 0!==this.position)return"Absolute"===this.unitMode?this.position:{x:this.position.x*t.width,y:this.position.y*t.height}},Object.defineProperty(n.prototype,"outerBounds",{get:function(){return this.floatingBounds||this.bounds},set:function(t){this.floatingBounds=t},enumerable:!0,configurable:!0}),n.prototype.measure=function(t,e,i){var s=void 0!==this.height?this.height:(t.height||0)-this.margin.top-this.margin.bottom;return this.id&&0===s&&this.elementActions&Xr.HorizontalLaneHeader&&(s=this.actualSize.height),this.desiredSize=new me(void 0!==this.width?this.width:(t.width||0)-this.margin.left-this.margin.right,s),this.isCalculateDesiredSize&&(this.desiredSize=this.validateDesiredSize(this.desiredSize,t)),this.desiredSize},n.prototype.arrange=function(t){return this.actualSize=t,this.updateBounds(),this.actualSize},n.prototype.updateBounds=function(){this.bounds=yr(this)},n.prototype.validateDesiredSize=function(t,e){return this.isRectElement&&!this.width&&!this.minWidth&&!this.maxWidth&&(t.width=50),this.isRectElement&&!this.height&&!this.minHeight&&!this.maxHeight&&(t.height=50),(void 0===t||void 0!==this.width&&void 0!==this.height)&&((t=t||new me).width=void 0===this.width?(e.width||0)-this.margin.left-this.margin.right:this.width,t.height=void 0===this.height?(e.height||0)-this.margin.top-this.margin.bottom:this.height),void 0!==this.minWidth&&(t.width=Math.max(t.width,this.minWidth)),void 0!==this.minHeight&&(t.height=Math.max(t.height,this.minHeight)),void 0!==this.maxWidth&&0!==this.maxWidth&&(t.width=Math.min(t.width,this.maxWidth)),void 0!==this.maxHeight&&0!==this.maxHeight&&(t.height=Math.min(t.height,this.maxHeight)),t},n}(),ere=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Cs=function(n){function t(){var e=null!==n&&n.apply(this,arguments)||this;return e.padding=new Yie(0,0,0,0),e.desiredBounds=void 0,e.measureChildren=!0,e.prevRotateAngle=0,e}return ere(t,n),t.prototype.hasChildren=function(){return void 0!==this.children&&this.children.length>0},t.prototype.measure=function(e,i,r){this.desiredBounds=void 0;var o,a,s=void 0;if(this.hasChildren()){for(var l=0;l=n.width&&s.length>0)i[i.length]={text:s,x:0,dy:0,width:o},s="";else{(s+=a[r+1]||"").indexOf("\n")>-1&&(i[i.length]={text:s,x:0,dy:0,width:Bc(s,n)},s="");var l=Bc(s,n);Math.ceil(l)+2>=n.width&&s.length>0&&(i[i.length]={text:s,x:0,dy:0,width:l},s=""),r===a.length-1&&s.length>0&&(i[i.length]={text:s,x:0,dy:0,width:l},s="")}else i=function Soe(n,t,e){var c,d,u,f,i=[],r="",s=0,o=0,a="nowrap"!==n.whiteSpace,h=(t||n.content).split("\n");for(s=0;s0?" ":"")+c[parseInt(o.toString(),10)];var p=Bc(d=c[o+1]?r+" "+c[o+1]:r,n);Math.floor(p)>(e||n.width)-2&&r.length>0?(i[i.length]={text:r,x:0,dy:0,width:d===r?p:r===f?u:Bc(r,n)},r=""):o===c.length-1&&(i[i.length]={text:r,x:0,dy:0,width:p},r=""),f=d,u=p}return i}(n,t,e);else i[i.length]={text:a,x:0,dy:0,width:Bc(a,n)};return i}(l,r,n.isLaneOrientation?i:void 0),n.wrapBounds=a=function Ioe(n,t){var r,s,e={x:0,width:0},i=0;for(i=0;in.width&&("Ellipsis"===n.textOverflow||"Clip"===n.textOverflow)?0:-r/2:"right"===n.textAlign?-r:t.length>1?0:-r/2,t[parseInt(i.toString(),10)].dy=1.2*n.fontSize,t[parseInt(i.toString(),10)].x=r,e.x=Math.min(e.x,r),e.width=Math.max(e.width,s);return e}(l,o),s.width=a.width,n.wrapBounds.width>=i&&"Wrap"!==l.textOverflow&&(s.width=i),s.height=o.length*n.style.fontSize*1.2,s}(this,0,0,this.isLaneOrientation?e.height:this.width||e.width):this.desiredSize,this.desiredSize=void 0===this.width||void 0===this.height?new me(i.width,i.height):new me(this.width,this.height),this.desiredSize=this.validateDesiredSize(this.desiredSize,e),this.desiredSize},t.prototype.arrange=function(e){return(e.width!==this.actualSize.width||e.height!==this.actualSize.height||this.isDirt)&&(this.doWrap=!0),this.actualSize=e,this.updateBounds(),this.isDirt=!1,this.actualSize},t}(hs),ire=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Mi=function(n){function t(){var e=null!==n&&n.apply(this,arguments)||this;return e.measureChildren=void 0,e}return ire(t,n),t.prototype.measure=function(e,i,r){var s=void 0,o=void 0;if(this.hasChildren()){for(var a=0,l=this.children;a=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Dd=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return are(t,n),Ph([I("")],t.prototype,"content",void 0),Ph([I("TopLeft")],t.prototype,"position",void 0),Ph([I("Mouse")],t.prototype,"relativeMode",void 0),Ph([I(!0)],t.prototype,"showTipPointer",void 0),Ph([I("auto")],t.prototype,"width",void 0),Ph([I("auto")],t.prototype,"height",void 0),Ph([I("Auto")],t.prototype,"openOn",void 0),Ph([I()],t.prototype,"animation",void 0),Ph([I(!1)],t.prototype,"isSticky",void 0),t}(Ee);function l3(n){var t=new wh;t=h3(n.tooltip,t);var e=new wh(t);return e.beforeCollision=hre,e.beforeOpen=lre,e.cssClass="e-diagram-tooltip",e.opensOn="custom",e.appendTo("#"+n.element.id),e.close(),e}function lre(n){(""===this.content||void 0===this.content)&&(n.element.style.display="none")}function hre(n){n.collidedPosition&&n.collidedPosition!==this.position&&(n.element.style.display="none")}function Ex(n,t){var e=n.tooltipObject;return h3(t?t.tooltip:n.tooltip,e),e}function h3(n,t){return n.content?(t.content=n.content,"string"==typeof n.content&&(t.content=ko(function(){return n.content})),t.position=n.position,t.showTipPointer=n.showTipPointer,t.width=n.width,t.height=n.height,t.animation=n.animation?n.animation:{close:{effect:"None"}}):t.close(),t}var Dx=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Bn=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},xx=function(n){function t(e,i,r,s){var o=n.call(this,e,i,r,s)||this;return o.inEdges=[],o.outEdges=[],o}return Dx(t,n),Bn([I("")],t.prototype,"id",void 0),Bn([I("Center")],t.prototype,"horizontalAlignment",void 0),Bn([I("Center")],t.prototype,"verticalAlignment",void 0),Bn([re({},Jn)],t.prototype,"margin",void 0),Bn([I(12)],t.prototype,"width",void 0),Bn([I(12)],t.prototype,"height",void 0),Bn([re({},Nl)],t.prototype,"style",void 0),Bn([I("Square")],t.prototype,"shape",void 0),Bn([I("Auto")],t.prototype,"connectionDirection",void 0),Bn([I(ci.Connect)],t.prototype,"visibility",void 0),Bn([I("")],t.prototype,"pathData",void 0),Bn([I(oi.Default)],t.prototype,"constraints",void 0),Bn([I()],t.prototype,"addInfo",void 0),Bn([I()],t.prototype,"outEdges",void 0),Bn([I()],t.prototype,"inEdges",void 0),Bn([re({},Dd)],t.prototype,"tooltip",void 0),t}(Ee),Es=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return Dx(t,n),t.prototype.getClassName=function(){return"PointPort"},Bn([re({x:.5,y:.5},R)],t.prototype,"offset",void 0),t}(xx),Tc=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return Dx(t,n),t.prototype.getClassName=function(){return"PathPort"},Bn([I(.5)],t.prototype,"offset",void 0),Bn([re({x:0,y:0},R)],t.prototype,"displacement",void 0),Bn([I("Center")],t.prototype,"alignment",void 0),t}(xx),xI=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),lr=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},cre=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return xI(t,n),lr([I("blue")],t.prototype,"color",void 0),lr([I("")],t.prototype,"content",void 0),lr([I("")],t.prototype,"link",void 0),lr([I("None")],t.prototype,"textDecoration",void 0),lr([I("NewTab")],t.prototype,"hyperlinkOpenState",void 0),t}(Ee),Tx=function(n){function t(e,i,r,s){var o=n.call(this,e,i,r,s)||this;return r.id||(o.id=e.parentObj&&e.parentObj.propName&&"phases"===e.parentObj.propName?e.parentObj.id:Qe()),o}return xI(t,n),lr([I("")],t.prototype,"content",void 0),lr([I(void 0)],t.prototype,"template",void 0),lr([I("String")],t.prototype,"annotationType",void 0),lr([I(!0)],t.prototype,"visibility",void 0),lr([I(Nr.InheritReadOnly)],t.prototype,"constraints",void 0),lr([re(void 0,cre)],t.prototype,"hyperlink",void 0),lr([I("")],t.prototype,"id",void 0),lr([I()],t.prototype,"width",void 0),lr([I()],t.prototype,"height",void 0),lr([I(0)],t.prototype,"rotateAngle",void 0),lr([I("Parent")],t.prototype,"rotationReference",void 0),lr([re({strokeWidth:0,strokeColor:"transparent",fill:"transparent"},Xf)],t.prototype,"style",void 0),lr([I("Center")],t.prototype,"horizontalAlignment",void 0),lr([I("Center")],t.prototype,"verticalAlignment",void 0),lr([re({},Jn)],t.prototype,"margin",void 0),lr([re({top:void 0,bottom:void 0,left:void 0,right:void 0},Jn)],t.prototype,"dragLimit",void 0),lr([I("Shape")],t.prototype,"type",void 0),lr([re({},Dd)],t.prototype,"tooltip",void 0),lr([I()],t.prototype,"addInfo",void 0),t}(Ee),Kn=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return xI(t,n),t.prototype.getClassName=function(){return"ShapeAnnotation"},lr([re({x:.5,y:.5},R)],t.prototype,"offset",void 0),t}(Tx),Or=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return xI(t,n),t.prototype.getClassName=function(){return"PathAnnotation"},lr([I(.5)],t.prototype,"offset",void 0),lr([re({x:0,y:0},R)],t.prototype,"displacement",void 0),lr([I("Center")],t.prototype,"alignment",void 0),lr([I(!1)],t.prototype,"segmentAngle",void 0),t}(Tx);function Ax(n){return pre[n.toString()]}function c3(n){return mre[""+n]}var pre={X:"M14,14 L106,106 M106,14 L14,106",Circle:"M0,50 A50,50,0 1 1 100,50 A50,50,0 1 1 0,50 Z",Square:"M0,0 L10,0 L10,10 L0,10 z"},gre={OpenArrow:"M15.9,23 L5,16 L15.9,9 L17,10.7 L8.7,16 L17,21.3Z",Square:"M0,0 L10,0 L10,10 L0,10 z",Fletch:"M14.8,10c0,0-3.5,6,0.2,12c0,0-2.5-6-10.9-6C4.1,16,11.3,16,14.8,10z",OpenFetch:"M6,17c-0.6,0-1-0.4-1-1s0.4-1,1-1c10.9,0,11-5,11-5c0-0.6,0.4-1,1-1s1,0.4,1,1C19,10.3,18.9,17,6,17C6,17,6,17,6,17z M18,23c-0.5,0-1-0.4-1-1c0-0.2-0.3-5-11-5c-0.6,0-1-0.5-1-1s0.4-1,1-1c0,0,0,0,0,0c12.9,0,13,6.7,13,7 C19,22.6,18.6,23,18,23z",IndentedArrow:"M17,10c0,0-4.5,5.5,0,12L5,16L17,10z",OutdentedArrow:"M14.6,10c0,0,5.4,6,0,12L5,16L14.6,10z",DoubleArrow:"M19,10 L19,22 L13,16Z M12,10 L12,22 L6,16Z",Arrow:"M15,10 L15,22 L5,16Z",Diamond:"M12,23l-7-7l7-7l6.9,7L12,23z",Circle:"M0,50 A50,50,0 1 1 100,50 A50,50,0 1 1 0,50 Z"},vre={Square:"M0,0 L10,0 L10,10 L0,10 z",Rhombus:"M10,5 L5,10 L0,5 L5,0 L10,5 Z ",Rectangle:"M0,0 L15,0 L15,10 L0,10 z ",OpenArrow:"M15.9,23 L5,16 L15.9,9 L17,10.7 L8.7,16 L17,21.3Z",Fletch:"M9.82,0 C9.82,0,6.61,5,10,10 C10,10,7.71,5,0,5 C0,5,6.61,5,9.82,0 Z ",OpenFetch:"M0.71,5.71 C0.29,5.71,0,5.43,0,5 C0,4.57,0.29,4.29,0.71,4.29 C8.5,4.29,8.57,0.71,8.57,0.71 C8.57,0.29,8.86,0,9.29,0 C9.719999999999999,0,10,0.29,10,0.71 C10,0.93,9.93,5.71,0.71,5.71 C0.71,5.71,0.71,5.71,0.71,5.71 Z M9.29,10 C8.93,10,8.57,9.71,8.57,9.29 C8.57,9.14,8.36,5.71,0.71,5.71 C0.29,5.71,0,5.36,0,5 C0,4.64,0.29,4.29,0.71,4.29 C0.71,4.29,0.71,4.29,0.71,4.29 C9.93,4.29,10,9.07,10,9.29 C10,9.71,9.71,10,9.29,10 Z ",IndentedArrow:"M10,0 C10,0,6.25,4.58,10,10 L0,5 L10,0 Z ",OutdentedArrow:"M8,0 C8,0,12.5,5,8,10 L0,5 L8,0 Z ",DoubleArrow:"M19,10 L19,22 L13,16Z M12,10 L12,22 L6,16Z",Arrow:"M15,10 L15,22 L5,16Z",Diamond:"M10,5 L5,10 L0,5 L5,0 L10,5 Z ",Circle:"M10,5 C10,7.76,7.76,10,5,10 C2.24,10,0,7.76,0,5 C0,2.24,2.24,0,5,0 C7.76,0,10,2.24,10,5 Z ",Ellipse:"M15,5 C15,7.76,11.64,10,7.5,10 C3.36,10,0,7.76,0,5 C0,2.24,3.36,0,7.5,0 C11.64,0,15,2.24,15,5 Z "},mre={Square:"M0,0 L10,0 L10,10 L0,10 z",Rhombus:"M10,5 L5,10 L0,5 L5,0 L10,5 Z ",Rectangle:"M0,0 L15,0 L15,10 L0,10 z",OpenArrow:"M23,15.9 L16,5 L9,15.9 L10.7,17 L16,8.7 L21,17.3Z",Fletch:"M9.82,0 C9.82,0,6.61,5,10,10 C10,10,7.71,5,0,5 C0,5,6.61,5,9.82,0 Z ",OpenFetch:"M0.71,5.71 C0.29,5.71,0,5.43,0,5 C0,4.57,0.29,4.29,0.71,4.29 C8.5,4.29,8.57,0.71,8.57,0.71 C8.57,0.29,8.86,0,9.29,0 C9.719999999999999,0,10,0.29,10,0.71 C10,0.93,9.93,5.71,0.71,5.71 C0.71,5.71,0.71,5.71,0.71,5.71 Z M9.29,10 C8.93,10,8.57,9.71,8.57,9.29 C8.57,9.14,8.36,5.71,0.71,5.71 C0.29,5.71,0,5.36,0,5 C0,4.64,0.29,4.29,0.71,4.29 C0.71,4.29,0.71,4.29,0.71,4.29 C9.93,4.29,10,9.07,10,9.29 C10,9.71,9.71,10,9.29,10 Z ",IndentedArrow:"M10,0 C10,0,6.25,4.58,10,10 L0,5 L10,0 Z ",OutdentedArrow:"M8,0 C8,0,12.5,5,8,10 L0,5 L8,0 Z ",DoubleArrow:"M10,19 L22,19 L16,13Z M10,12 L22,12 L16,6Z",Arrow:"M10,15 L22,15 L16,5Z",Diamond:"M10,5 L5,10 L0,5 L5,0 L10,5 Z ",Circle:"M10,5 C10,7.76,7.76,10,5,10 C2.24,10,0,7.76,0,5 C0,2.24,2.24,0,5,0 C7.76,0,10,2.24,10,5 Z ",Ellipse:"M15,5 C15,7.76,11.64,10,7.5,10 C3.36,10,0,7.76,0,5 C0,2.24,3.36,0,7.5,0 C11.64,0,15,2.24,15,5 Z "};function Lx(n){return yre[n.toString()]}var yre={Process:"M419.511,76.687L359.511,76.687L359.511,43.086L419.511,43.086z",Decision:"M 253.005,115.687L 200.567,146.071L 148.097,115.687L 200.534,85.304L 253.005,115.687 Z",Document:"M 60 31.9 c 0 0 -11 -7.7 -30 0 s -30 0 -30 0 V 0 h 60 V 31.9 Z",PreDefinedProcess:"M 0,0 L 50,0 L 50,50 L 0,50 Z M 8.334,0 L 8.334,50 M 41.667,0 L 41.667,50",Terminator:"M 269.711,29.33C 269.71,44.061 257.77,56 243.04,56L 158.058,56C 143.33,56 131.39,44.061 131.39,29.33L 131.39,29.33C 131.391,14.6057 143.33,2.669 158.058,2.669L 243.044,2.669C 257.772,2.669 269.711,14.6057 269.711,29.333 Z",PaperTap:"M0.0009,17.2042 L0.0009,47.165 C0.001,47.165 14.403,53.5455 25.00,47.165 C35.599,40.7852 44.403,43.5087 50.00,47.165L50.001,17.2042 M50.001,32.7987 L50.001,2.8405 C50.001,2.8405 35.599,-3.5427 25.001,2.8405C14.403,9.2237 5.599,6.494 0.0009,2.8405 L0.0009,32.7987",DirectData:"M 132.62 0 L 17.38 0 C 7.78 0 0 13.43 0 30 C 0 46.57 7.78 60 17.38 60 L 132.62 60 M 132.62 0C 123.02 0 115.24 13.43 115.24 30 C 115.24 46.57 123.02 60 132.62 60 C 142.22 60 150 46.57 150 30 C 150 13.43 142.22 0 132.62 0 z ",SequentialData:"M0.0029,24.999 C0.0029,11.1922 10.433,0.0021 23.295,0.0021 C36.159,0.00216 46.585,11.1922 46.585,24.999C46.585,38.8057 36.159,49.9979 23.295,49.9979 C10.433,49.9979 0.0029,38.8057 0.0029,24.999 z M23.294,49.999 L50.002,49.999",Sort:"M50.001,24.9971 L25.001,49.9971 L0.00097,24.9971 L25.001,-0.00286865 L50.001,24.9971 z M0.000976562,24.9971 L50.001,24.9971",MultiDocument:"M43.6826,40 C44.8746,40.6183 45.8586,41.3502 46.8366,42.1122 L46.8366,4.74487 L3.09857,4.74487 L3.09857,10.9544 M46.837,35.143 C48.027,35.765 49.025,36.604 50.003,37.369 L50.003,0.002 L6.264,0.002 L6.264,4.744 M43.682,47.113 L43.682,10.765 L0.0025,10.7652 L0.0025,47.1132 C0.0025,47.1132 12.5846,53.6101 21.8426,47.1132 C31.1006,40.6163 38.792,43.393 43.6826,47.1132 z",Collate:"M50.001,0.0028 L25.001,25.0029 L0.00097,0.0028 L50.001,0.002 z M0.0009,50.002 L25.001,25.002L50.001,50.002 L0.0009,50.0029 z",SummingJunction:"M7.3252,42.6768 L42.6772,7.3247 M42.6768,42.6768 L7.3248,7.3247 M0.0009,25.001 C0.0009,11.193 11.197,0.0009 25.001,0.0009 C38.809,0.0009 50.001,11.193 50.001,25.001 C50.001,38.809 38.809,50.001 25.001,50.001 C11.197,50.00 0.0009,38.809 0.0009,25.00 z",Or:"M 0 50 L 100 50 M 50 100 L 50 0.0 M 0 50 C 0 22.384 22.392 0 50 0 C 77.616 0 100 22.384 100 50 C 100 77.616 77.616 100 50 100 C 22.392 100 0 77.616 0 50 Z",InternalStorage:"M 0 3.81946A 2.5,3.81946 0 0,1 2.5,0L 47.5 0A 2.5,3.81946 0 0,1 50,3.81946L 50 45.836A 2.5,3.819446 0 0,1 47.5,49.652778L 2.5 49.652778A 2.5,3.819446 0 0,1 0,45.8336L 0 3.819446ZM 0 11.45834L 50 11.4583334M 12.5 0L 12.5 49.652778",Extract:"M0,35 L30,0 L60,35 Z",ManualOperation:"M46.4,28.8 L14.8,28.8 L0,0 L60,0 Z",Merge:"M60,0 L30,35 L0,0 Z",OffPageReference:"M60,33.3 L30.1,39 L0,33.3 L0,0 L60,0 Z",SequentialAccessStorage:"M 60 30 C 60 13.4 46.6 0 30 0 S 0 13.4 0 30 s 13.4 30 30 30 h 28.6 v -6.5 h -9.9C 55.5 48 60 39.5 60 30 Z",Annotation:"M49.9984,50.0029 L-0.00271199,50.0029 L-0.00271199,0.00286865 L49.9984,0.00286865",Annotation2:"M49.9977,50.0029 L25.416,50.0029 L25.416,0.00286865 L49.9977,0.00286865 M25.4166,25.0029 L-0.00227869,25.0029",Data:"M 10 0 L 40 0 L 30 40 L 0 40 Z",Card:"M275,60 L400,60 L400,110 L260,110 L260,75 Z",Delay:"M0,0 L12.029,0 C14.212999,0 16,1.7869979 16,3.9709952 C16,6.1549926 14.212999,7.9409904 12.029,7.9409904 L0,7.9409904 z",Preparation:"M 1048.17 572 C 1051.06 568.86 1055.17 567.05 1059.5 567 L 1094.51 567 C 1098.84 567.05 1102.95 568.86 1105.84 572 L 1126.43 595 C 1127.01 596.28 1127.01 597.72 1126.43 599 L 1105.84 622 C 1102.95 625.14 1098.84 626.95 1094.51 627 L 1059.5 627 C 1055.17 626.95 1051.06 625.14 1048.17 622 L 1027.58 599 C 1027 597.72 1027 596.28 1027.58 595 L 1048.17 572 Z",Display:"M47.8809,19.2914 L32.7968,-0.00594145 L11.3902,-0.00594145 C7.93166,-0.00594145 0.00124586,11.187 0.00124586,24.9968C0.00124586,38.8032 7.93166,49.9962 11.3902,49.9962 L32.7968,49.99 L47.615,31.038 C47.615,31.0388 52.798,24.9968 47.880,19.2914 z",ManualInput:"M 912 732 L 1006.85 707 C 1008.2 707 1009.5 707.53 1010.46 708.46 C 1011.41 709.4 1011.95 710.67 1011.95 712 L 1011.95 762C 1012 764.41 1010.28 766.52 1007.87 767 L 917.1 767 C 915.75 767 914.45 766.47 913.49 765.54 C 912.54 764.6 912 763.33 912 762 L 912 732 Z",LoopLimit:"M 8 9 L 27 9 L 33 15 L 33 26 C 33 27 33 27 32 27 L 4 27 C 3 27 2 27 2 26 L 2 15 L 8 9 Z",StoredData:"M 5.55 0L 50 0A 1.5,30 0 0,1 50,0A 5.555,25 0 0,0 50,50A 1.5,30 0 0,1 50,50L 5.555 50A 5.55,25 0 0,1 5.555,0Z"};function d3(n,t,e){var i;i="Straight"!==n.type&&n.sourceWrapper?n.sourceWrapper.corners.center:function Sre(n){var t;if(n.sourcePortWrapper){var e=n.sourcePortWrapper;t={x:e.offsetX,y:e.offsetY}}else t=n.sourceID&&n.sourceWrapper&&n.targetWrapper?qa(n,0,n.sourceWrapper.corners.center,n.targetWrapper.corners.center,!1):n.sourcePoint;return t}(n);var r=function bre(n,t,e,i,r){var b,M,s=n.sourceWrapper,o=n.targetWrapper,a=n.sourcePortWrapper,l=n.targetPortWrapper,d=[],p=Xa(n),y={corners:undefined,point:t,direction:undefined,margin:{left:5,right:5,bottom:5,top:5}},S={corners:undefined,point:e,direction:undefined,margin:{left:5,right:5,bottom:5,top:5}};if(void 0!==s&&void 0!==o&&(b=xn(s),M=xn(o),y.corners=s.corners,S.corners=o.corners),void 0!==a&&(y.direction="Left"===a.connectionDirection||"Top"===a.connectionDirection||"Bottom"===a.connectionDirection||"Right"===a.connectionDirection?a.connectionDirection:zo({x:a.offsetX,y:a.offsetY},b,s.bounds)),void 0!==l&&(S.direction="Left"===l.connectionDirection||"Right"===l.connectionDirection||"Bottom"===l.connectionDirection||"Top"===l.connectionDirection?l.connectionDirection:zo({x:l.offsetX,y:l.offsetY},M,o.bounds)),"Bezier"===n.type&&!n.isBezierEditing&&n.segments.length>0)for(var D=n.segments.length-1;D>=0;)n.segments[parseInt(D.toString(),10)].isInternalSegment&&n.segments.pop(),D--;if(void 0!==s&&void 0!==o)return(void 0===y.direction||void 0===S.direction)&&(i?function Ire(n,t,e){"LeftToRight"===e?(n.direction=n.direction?n.direction:"Right",t.direction=t.direction?t.direction:"Left"):"RightToLeft"===e?(n.direction=n.direction?n.direction:"Left",t.direction=t.direction?t.direction:"Right"):"TopToBottom"===e?(n.direction=n.direction?n.direction:"Bottom",t.direction=t.direction?t.direction:"Top"):"BottomToTop"===e&&(n.direction=n.direction?n.direction:"Top",t.direction=t.direction?t.direction:"Bottom")}(y,S,i):y.corners.top>S.corners.bottom&&Math.abs(y.corners.top-S.corners.bottom)>p?(y.direction=y.direction?y.direction:"Top",S.direction=S.direction?S.direction:"Bottom"):y.corners.bottomp?(y.direction=y.direction?y.direction:"Bottom",S.direction=S.direction?S.direction:"Top"):y.corners.rightp||y.corners.right+p=y.corners.left-p&&y.corners.left>S.corners.left?(y.direction=y.direction?y.direction:"Right",S.direction=S.direction?S.direction:"Left"):y.corners.left>S.corners.right&&Math.abs(y.corners.left-S.corners.right)>y.margin.left+y.margin.right||S.corners.right+p=S.corners.left-p&&y.corners.left0&&n.segments[0].direction&&(y.direction=n.segments[0].direction),y.point=Ol(b,y.direction),d=Ol(b,_n(y.direction)),y.point=qa(n,0,y.point,d,!1)):y.point=o.corners.center;if(void 0!==h){switch(S.point={x:h.offsetX,y:h.offsetY},S.direction){case"Bottom":case"Top":S.point.y=S.point.y;break;case"Left":case"Right":S.point.x=S.point.x}n.targetPadding&&!w&&(S.point=TI(n,y,S,!0))}else"Orthogonal"===n.type||"Bezier"===n.type?(S.point=Ol(M,S.direction),d=Ol(M,_n(S.direction)),S.point=qa(n,0,S.point,d,!0)):S.point=a.corners.center;if("Orthogonal"!==n.type){var C=void 0,D=void 0;if("Bezier"===n.type){if(n.bezierSettings.allowSegmentsReset||0===n.segments.length||!R.isEmptyPoint(n.segments[n.segments.length-1].point))return c=b3(n,y,S,void 0,s),Nx(n,y,S);Fv(n)}else Fv(n);if(void 0===n.sourcePortWrapper){y.point=y.corners.center,n.segments&&n.segments.length>0&&(C=R.isEmptyPoint((D=n.segments[0]).point)?void 0:D);var A=void 0!==C?C.point:S.point;if("Bezier"===n.type&&n.segments.length>0&&n.segments[0].vector1.angle&&n.segments[0].vector1.distance){var x=Math.max(y.corners.width,y.corners.height);A=R.transform(y.point,n.segments[0].vector1.angle,x/2)}y.point=w?n.sourceWrapper.bounds.center:qa(n,0,y.point,A,!1)}if(void 0===n.targetPortWrapper){S.point=S.corners.center,n.segments&&n.segments.length>1&&(C=R.isEmptyPoint((D=n.segments[n.segments.length-2]).point)?void 0:D);var P=C?C.point:y.point;"Bezier"===n.type&&n.segments.length>0&&n.segments[n.segments.length-1].vector2.angle&&n.segments[n.segments.length-1].vector2.distance&&(x=Math.max(y.corners.width,y.corners.height),P=R.transform(S.point,n.segments[0].vector2.angle,x/2)),S.point=w?n.targetWrapper.bounds.center:qa(n,0,P,S.point,!0)}c=Nx(n,y,S)}else"Orthogonal"===n.type&&n.segments&&n.segments.length>0&&null!==n.segments[0].direction?c=function Nre(n,t,e,i,r,s,o){var a,h,c,d;Fv(n);for(var u=0;u0&&n.segments[u-1].direction===h.direction?u=y3(n,u,t):h.direction?t.point=u3(t,n.segments[parseInt(u.toString(),10)]):(f=n.segments[u-1])&&f.points&&f.points.length>0&&(t.point=f.points[f.points.length-1]),u===n.segments.length-1)if(S3(n,t),v3(a=void 0===r?Lre(n,t,e):p3(n,t,e),n),h.points=[],a.length>=2)for(c=0;c2&&n.segments.length>2){var p={x:a[parseInt(c.toString(),10)].x,y:t.point.y};h.points=[],h.points.push(p),h.points.push(a[parseInt(c.toString(),10)]);var f=n.segments[u-1];n.segments.length<4&&f.points.pop(),f.points=f.points.concat(h.points)}else h.points.push(a[parseInt(c.toString(),10)]);else h.points.push(a[parseInt(c.toString(),10)]);else d=u;if(void 0!==d&&!n.selectedSegmentIndex&&(d===n.segments.length-1&&(n.segments[d-1].direction=null,n.segments[d-1].length=null),n.segments.splice(d,1)),i&&0===u){var g=g3(n,i,s);g&&(t.point=g)}}return I3(n,[])}(n,y,S,l,h,o):(n.segments[0]||(C=new wi(n,"segments",{type:"Orthogonal"},!0),n.segments.push(C)),n.segments[0].points=c=b3(n,y,S,void 0,s));return c}(n,y.direction,S.direction,y.point,S.point,r);if(Fv(n),(n.sourceWrapper||n.targetWrapper)&&function Dre(n,t,e){var i=n.sourcePortWrapper,r=n.targetPortWrapper,s=n.sourceWrapper,o=t.point,a={left:0,right:0,top:0,bottom:0},l={x:0,y:0},c="Top";if(s?(o=e.point,a=t.margin):(s=n.targetWrapper,a=e.margin),"Orthogonal"===n.type)if(n.segments&&n.segments.length>0&&n.sourceWrapper&&n.segments[0].direction)t.direction=n.segments[0].direction,l=qa(n,0,l=Ol(s.corners,t.direction),Ol(s.corners,_n(t.direction)),!1);else{var u={corners:null,direction:null,point:null,margin:null};_v(s,{corners:null,direction:null,point:o,margin:a},u,n),l=u.point,c=u.direction}else{var f=void 0;n.segments&&n.segments.length>1&&(f=s===n.sourceWrapper?n.segments[0].point:n.segments[n.segments.length-2].point),l=qa(n,0,s.bounds.center,n.segments&&n.segments.length>1?f:o,s===n.targetWrapper)}s===n.sourceWrapper?(t.direction=t.direction||c,t.point=l,n.sourcePortWrapper&&(t.point={x:i.offsetX,y:i.offsetY},n.sourcePadding&&(t.point=TI(n,t,e,!1)))):(e.direction=e.direction||c,e.point=l,n.targetPortWrapper&&(e.point={x:r.offsetX,y:r.offsetY},n.targetPadding&&(e.point=TI(n,t,e,!0))))}(n,y,S),"Straight"===n.type||"Bezier"===n.type)d=Nx(n,y,S);else if("Orthogonal"===n.type&&n.segments&&n.segments.length>0&&null!==n.segments[0].length&&null!==n.segments[0].direction)d=function Ere(n,t,e,i,r,s,o){var a,l,c,u,h=[];if(Fv(n),n.segments.length>0){for(var f=0;f0&&n.segments[f-1].direction===p.direction)f=y3(n,f,t);else{var g=n.segments[f-1];t.point=p.direction?u3(t,p):g.points[g.points.length-1]}if(f===n.segments.length-1&&(o||r?n.targetWrapper&&void 0===n.targetPortWrapper?(S3(n,t),l=wre(n,t,e)):l=p3(n,t,e):l=Mre(n,t,e),l))if(v3(l,n),p.points=[],l.length>=2)for(a=0;at.corners.top&&e.point.ye.point.x?"Left":"Right"):e.point.x>t.corners.left&&e.point.xe.point.y?"Top":"Bottom")),n.sourcePortWrapper&&s===_n(r)?(("Left"===s||"Right"===s)&&t.point.y>=t.corners.top&&t.point.y<=t.corners.center.y&&e.point.y>=t.corners.top&&e.point.y<=t.corners.center.y?(t.direction="Top",a=t.point.y-t.corners.top+20):("Left"===s||"Right"===s)&&t.point.y>t.corners.center.y&&t.point.y<=t.corners.bottom&&e.point.y>t.corners.center.y&&e.point.y<=t.corners.bottom?(t.direction="Bottom",a=t.corners.bottom-t.point.y+20):("Top"===s||"Bottom"===s)&&t.point.x>=t.corners.left&&t.point.x<=t.corners.center.x&&e.point.x>=t.corners.left&&e.point.x<=t.corners.center.x?(t.direction="Left",a=t.point.x-t.corners.left+20):("Top"===s||"Bottom"===s)&&t.point.x<=t.corners.right&&t.point.x>t.corners.center.x&&e.point.x<=t.corners.right&&e.point.xt.point.y&&t.point.y>=e.corners.top?(i="Top",r=t.point.y-e.corners.top+20):e.corners.center.y===t.point.y&&"Top"===n.segments[n.segments.length-2].direction||e.corners.center.ye.point.y?t.point.y-t.corners.top+20:t.corners.bottom-t.point.y+20):(i="Top",r=e.corners.height/2+20):e.corners.center.x!==t.point.x||e.corners.topt.point.x&&t.point.x>=e.corners.left?(i="Left",r=t.point.x-e.corners.left+20):e.corners.center.x===t.point.x&&"Left"===n.segments[n.segments.length-2].direction||e.corners.center.x<=t.point.x&&t.point.x<=e.corners.right?(i="Right",r=e.corners.right-t.point.x+20):void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&t.corners.left<=t.point.x&&t.point.x<=t.corners.right&&(i=t.direction,r=t.point.x>e.point.x?t.point.x-t.corners.left+20:t.corners.right-t.point.x+20):(i="Left",r=e.corners.width/2+20);var a=t.point;t.point=Fn(t.point,"Left"===i||"Top"===i?-r:r,"Left"===i||"Right"===i?0:90),t.direction=R.direction(t.point,e.point),void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&(t.corners.center.x===e.corners.center.x||t.corners.center.y===e.corners.center.y)&&(t.direction=e.direction);var l=Ys(n,t,e);return l.splice(0,0,a),l}function p3(n,t,e){var i,r;e.corners=n.targetWrapper.corners,void 0!==n.sourcePortWrapper&&(r=zo({x:n.sourcePortWrapper.offsetX,y:n.sourcePortWrapper.offsetY},xn(n.sourceWrapper),n.sourceWrapper.bounds));var a=function Cre(n,t,e,i){var r=!1;switch(e.direction){case"Left":void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&"Right"===i&&t.point.x>e.point.x&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom||("Bottom"===i&&t.point.y>e.point.y||"Top"===i&&t.point.y=t.corners.left&&t.point.x<=t.corners.right?(t.direction="Right"===i?t.point.y>e.point.y?"Top":"Bottom":t.point.xe.point.x&&(t.point.y>e.point.y||t.point.yt.point.y&&e.corners.bottome.point.y||t.point.x>e.point.x&&t.point.y<=e.point.y&&e.corners.top=t.point.y?t.direction="Top":t.point.xe.point.x&&t.point.y>e.point.y&&e.corners.bottomt.point.y?t.direction="Bottom":t.point.y===e.point.y&&t.point.xe.point.y||"Top"===i&&t.point.ye.point.x&&t.point.x>=t.corners.left&&t.point.x<=t.corners.right?(t.direction=t.point.x>e.point.x?"Left":"Right",r=!0):void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&"Left"===i&&t.point.x=t.corners.top&&t.point.y<=t.corners.bottom?(t.direction=t.point.y>e.point.y?"Top":"Bottom",r=!0):t.point.x=t.point.y&&t.point.y===e.point.y||t.point.y>e.point.y&&t.point.x>e.point.x?t.direction="Top":t.point.ye.point.x?t.direction="Bottom":t.point.xe.point.y||t.point.ye.point.x&&(t.direction="Left");break;case"Top":void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&"Bottom"===i&&t.point.y>e.point.y&&t.point.x>=t.corners.left&&t.point.x<=t.corners.right||("Right"===i&&t.point.x>e.point.x||"Left"===i&&e.point.y>t.point.y&&e.point.x>t.point.x)&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom?(t.direction="Bottom"===i?t.point.x>e.point.x?"Left":"Right":t.point.ye.point.y&&t.point.x>e.corners.left&&t.point.x=e.point.y?t.direction="Top":t.point.ye.point.x?t.direction="Left":t.point.yt.point.x)&&t.point.y>e.point.y&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom||"Top"===i&&t.point.y=t.corners.left&&t.point.x<=t.corners.right)?(t.direction="Right"===i||"Left"===i?t.point.y>e.point.y?"Top":"Bottom":t.point.x>e.point.x?"Left":"Right",r=!0):t.point.ye.corners.left&&e.corners.right>t.point.x?t.point.ye.corners.left&&e.corners.center.x>=t.point.x?t.direction="Left":t.point.ye.point.y&&t.point.x>e.point.x?t.direction="Left":t.point.y>e.point.y&&t.point.xe.point.x||e.point.x>t.point.x)&&(t.direction="Bottom")}return r}(n,t,e,r);return!n.selectedSegmentIndex&&void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&e.direction===_n(r)&&(("Left"===e.direction&&t.point.x>e.point.x||"Right"===e.direction&&t.point.x=t.corners.top&&t.point.y<=t.corners.bottom||"Bottom"===e.direction&&t.point.y=t.corners.left&&t.point.x<=t.corners.right)?i=f3(n,t,e):n.selectedSegmentIndex||t.direction!==e.direction?!n.selectedSegmentIndex&&("Left"===e.direction&&t.point.x>e.point.x||"Right"===e.direction&&t.point.x=t.point.y||"Top"===e.direction&&t.point.y>e.point.y||"Bottom"===e.direction&&t.point.y=t.point.x?i=n.selectedSegmentIndex?kl(t,e):f3(n,t,e):!n.selectedSegmentIndex&&void 0!==n.sourceWrapper&&void 0!==n.targetWrapper&&void 0!==n.targetPortWrapper&&("Left"===t.direction||"Right"===t.direction)&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom&&("Top"===e.direction||"Bottom"===e.direction)&&e.corners.center.x===t.corners.center.x?(t.direction="Top"===e.direction?"Bottom":"Top",i=Ys(n,t,e,"Top"===e.direction?t.corners.bottom-t.point.y+20:t.point.y-t.corners.top+20)):!n.selectedSegmentIndex&&void 0!==n.sourceWrapper&&void 0!==n.targetWrapper&&void 0!==n.targetPortWrapper&&("Top"===t.direction||"Bottom"===t.direction)&&t.point.x>=t.corners.left&&t.point.x<=t.corners.right&&("Left"===e.direction||"Right"===e.direction)&&e.corners.center.y===t.corners.center.y?(t.direction="Left"===e.direction?"Right":"Left",i=Ys(n,t,e,"Left"===e.direction?t.corners.right-t.point.x+20:t.point.x-t.corners.left+20)):i=a?Ys(n,t,e,"Left"===t.direction||"Right"===t.direction?"Left"===t.direction?t.point.x-t.corners.left+20:t.corners.right-t.point.x+20:"Top"===t.direction?t.point.y-t.corners.top+20:t.corners.bottom-t.point.y+20):kl(t,e):i=Ys(n,t,e),i}function g3(n,t,e){var r,i={x:t.offsetX,y:t.offsetY},s=xn(e),o=zo(i,s,e.bounds),a=n.segments[0];return a.direction!==o&&(function Ore(n,t,e,i,r,s){var a,h,o=13,l=[];l.push(i),i.y===r.y&&("Left"===t&&r.xi.x)||i.x===r.x&&("Top"===t&&r.yi.y)||("Top"===t||"Bottom"===t?"Top"===t&&r.yi.y-o||"Bottom"===t&&r.y>i.y&&r.yo&&("Top"===t&&r.yi.y)?l.push({x:i.x,y:r.y}):(a=r.xi.x-o||"right"===t&&r.x>i.x&&r.xo&&("Left"===t&&r.xi.x)?l.push({x:r.x,y:i.y}):(l.push({x:a="Left"===t?e.left-o:e.right+o,y:i.y}),l.push({x:a,y:r.y})),s&&(l.push(n.points[0]),l.reverse()),n.points=l)}(a,o,s,a.points[0],a.points[a.points.length-1],!1),r=a.points[a.points.length-1],a.direction=R.direction(a.points[a.points.length-2],a.points[a.points.length-1])),r}function v3(n,t,e){var s,i=t.segments[t.segments.length-2],r=i.points[i.points.length-1];(("Top"===i.direction||"Bottom"===i.direction)&&r.x===n[1].x||("Left"===i.direction||"Right"===i.direction)&&r.y===n[1].y)&&(i.points[i.points.length-1]=n[1],s=R.direction(i.points[0],i.points[i.points.length-1]),void 0!==t.sourceWrapper&&void 0===t.sourcePortWrapper&&s===_n(i.direction)&&("Left"===i.direction||"Right"===i.direction?i.points[0].x="Right"===i.direction?i.points[0].x-t.sourceWrapper.corners.width:i.points[0].x+t.sourceWrapper.corners.width:i.points[0].y="Bottom"===i.direction?i.points[0].y-t.sourceWrapper.corners.height:i.points[0].y+t.sourceWrapper.corners.height),i.direction=s,i.length=R.distancePoints(i.points[0],i.points[i.points.length-1]),n.splice(0,1))}function TI(n,t,e,i){var o=i?n.targetPadding:n.sourcePadding,a=i?n.targetPortWrapper:n.sourcePortWrapper,l=new Ne(a.bounds.x-o,a.bounds.y-o,a.actualSize.width+2*o,a.actualSize.height+2*o),h=[l.topLeft,l.topRight,l.bottomRight,l.bottomLeft];h[h.length]=h[0];var d=i?e.point:t.point;return kx({x1:t.point.x,y1:t.point.y,x2:e.point.x,y2:e.point.y},h,0,d)||d}function m3(n,t){var e=[],i=mF(0,n.corners,t);i.push(i[0]);for(var r=0;r0){var r=void 0,s=[],o=t.point;for(r=0;r1&&R.equals(a.points[0],a.points[1])&&n.segments.splice(r,1),a)for(var l=0;l0||0===r)&&i.push(a.points[parseInt(l.toString(),10)])}}return i}function Ox(n,t,e){return"Top"===n||"Bottom"===n?e.x>t.x?"Right":"Left":e.y>t.y?"Bottom":"Top"}function Fv(n){if("Straight"===n.type||"Bezier"===n.type){if(0===n.segments.length||n.segments.length>0&&!R.isEmptyPoint(n.segments[n.segments.length-1].point))if("Bezier"===n.type){var t=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0},!0);n.segments.push(t)}else t=new Bl(n,"segments",{type:"Straight"},!0),n.segments.push(t)}else{if(n.segments.length>0)for(var e=!1,i=0;i=t.corners.left&&e.point.x<=t.corners.right&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom)t.direction=e.point.y>t.point.y?"Bottom":"Top",i=Ys(n,t,e,"Top"===t.direction?t.point.y-t.corners.top+20:t.corners.bottom-t.point.y+20);else if(n.sourcePortWrapper&&r===_n(o)){var h;("Left"===r||"Right"===r)&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom?(t.direction=e.point.y>t.point.y?"Bottom":"Top",h=t.corners.height/2+20):("Top"===r||"Bottom"===r)&&t.point.x>=t.corners.left&&t.point.x<=t.corners.right&&(t.direction=e.point.x>t.point.x?"Right":"Left",h=t.corners.width/2+20),t.direction&&h?i=Ys(n,t,e,h,!0):(t.direction=o,i=kl(t,e))}else if(!n.sourcePortWrapper||r!==e.direction||"Top"!==r&&"Bottom"!==r||t.corners.center.x!==e.corners.center.x)if(t.direction===e.direction)if(("Left"===t.direction||"Right"===t.direction)&&e.point.y>t.corners.top-20&&e.point.yt.corners.left-20&&e.point.xt.point.y?"Bottom":"Top",i=Ys(n,t,e,"Bottom"===t.direction?t.corners.bottom-t.point.y+20:t.point.y-t.corners.top+20);else t.direction=o,i=Ys(n,t,e,"Top"===o||"Bottom"===o?n.sourceWrapper.height/2+20:n.sourceWrapper.width/2+20),t.point=i[1],"Left"===o||"Right"===o?(e.direction=o,e.point="Left"===o?e.corners.middleLeft:e.corners.middleRight):_v(n.targetWrapper,t,e,n),i=Ys(n,t,e);return i}function S3(n,t){if(void 0!==n.targetWrapper&&void 0===n.targetPortWrapper&&xn(n.targetWrapper).containsPoint(t.point,1)){var i=n.targetWrapper,r=n.segments[n.segments.length-2],s=r.points[r.points.length-1],o=_n(r.direction);"Bottom"===o?s.yi.corners.top-1&&(r.points[r.points.length-1].y=i.corners.top-20,r.length=R.distancePoints(r.points[0],r.points[r.points.length-1])):"Left"===o?s.x>i.corners.left-1&&(r.points[r.points.length-1].x=i.corners.left-20,r.length=R.distancePoints(r.points[0],r.points[r.points.length-1])):"Right"===o&&s.x0||0===e)&&t.push(i.points[parseInt(r.toString(),10)]);return t}function _v(n,t,e,i){var r,s={x:0,y:0},o=AI(n,n.corners,n.bounds),a=t.margin,l=t.point;if(o.bottomCenter.y+a.bottoml.y)r="Top",s=o.topCenter;else if(o.middleLeft.x-a.left>l.x)r="Left",s=o.middleLeft;else if(o.middleRight.x+a.rightc&&(f=c,r="Right",s=o.middleRight),f>d&&(f=d,r="Bottom",s=o.bottomCenter),f>u&&(r="Left",s=o.middleLeft)}e.point=s,e.direction=r;var p=Ol(o,_n(e.direction));e.point=qa(i,0,e.point,p,n===i.targetWrapper)}function b3(n,t,e,i,r){var s,o,a;if(s=function Qre(n,t){var e=!1;switch(n){case"Left":switch(t){case"Right":case"Bottom":e=!0}break;case"Top":switch(t){case"Left":case"Right":case"Bottom":e=!0}break;case"Bottom":"Right"===t&&(e=!0)}return e}(t.direction,e.direction),s&&x3(t,e),"Right"===t.direction&&"Left"===e.direction)a=function kre(n,t,e,i){var o=Math.round(Math.abs(t.point.y-e.point.y)),a={x:Math.max(t.point.x,t.corners.right),y:t.point.y},l={x:Math.min(e.point.x,e.corners.left),y:e.point.y},h=Xa(n);if(i){var c=l;l=a,a=c}return t.corners.bottom+he.corners.bottom+h||("Bezier"!==n.type||e.corners.left-t.corners.right<=2*h&&e.corners.left-t.corners.right>=5)&&(h=0),t.margin={left:h,right:h,top:h,bottom:h},e.margin={left:h,right:h,top:h,bottom:h},0===o&&(t.corners.right=e.corners.right?void 0!==i&&(i.offsetYe.corners.bottom+e.margin.bottom)||void 0===i&&t.corners.middleRight.ye.corners.bottom+e.margin.bottom&&t.corners.top>e.corners.bottom||void 0===i&&t.corners.middleRight.y>e.corners.bottom||void 0!==i&&i.offsetYe.corners.top||void 0===i&&t.corners.middleRight.y>e.corners.bottom?Ae.Three:t.corners.rightr.offsetY+e.margin.right||void 0===r&&t.corners.top>e.corners.middleRight.y||void 0!==r&&(void 0!==i&&i.offsetXr.offsetX||void 0===r&&t.corners.left>e.corners.topCenter.x?Ae.Four:Ae.Two:void 0!==s&&Math.abs(t.corners.right-e.corners.left)<=5&&Math.abs(s.offsetY-e.corners.top)<=5||void 0!==r&&t.corners.right=25&&t.corners.middleRight.y+t.margin.righte.corners.bottom+e.margin.bottom||void 0===o&&t.corners.middleRight.y>e.corners.bottom+e.margin.bottom?t.corners.top>e.corners.bottom?void 0!==a&&t.corners.right+t.margin.righta.offsetX||void 0===a&&t.corners.left>e.corners.bottomCenter.x?Ae.Four:Ae.Two:void 0!==o&&Math.abs(t.corners.right-e.corners.left)<=25&&Math.abs(o.offsetY-e.corners.bottom)<=25?Ae.Two:Ae.Four}(n,t,e,s);else if("Bottom"===t.direction&&"Top"===e.direction)a=function Hre(n,t,e){var r=t.point.x-e.point.x,s=Xa(n);return t.corners.right+se.corners.right+s||("Bezier"!==n.type||e.corners.top-t.corners.bottom<=2*s&&e.corners.top-t.corners.bottom>=5)&&(s=0),t.margin={left:s,right:s,top:s,bottom:s},e.margin={left:s,right:s,top:s,bottom:s},0===r&&t.corners.bottome.corners.right+e.margin.right||void 0===i&&t.corners.bottomCenter.x>e.corners.right+e.margin.right?Ae.Three:t.corners.bottomr.offsetX||void 0===r&&t.corners.left>e.corners.left||void 0!==r&&t.corners.right+t.margin.righte.corners.bottom?Ae.Five:0===s||0===o?Ae.One:Ae.Three}(n,t,e)}else"Bottom"===t.direction&&"Left"===e.direction?a=function Bre(n,t,e,i){var r=n.sourcePortWrapper,s=n.targetPortWrapper,o=Xa(n);if(e.margin={left:o,right:o,top:o,bottom:o},t.margin={top:o,bottom:o,left:o,right:o},i){var l=r;r=s,s=l}return void 0!==r&&r.offsetXs.offsetY||void 0===s&&t.corners.top>e.corners.middleLeft.y?Ae.Four:Ae.Two:void 0!==s&&Math.abs(t.corners.right-e.corners.left)<=25&&Math.abs(s.offsetY-t.corners.bottom)<=25?Ae.Two:Ae.Four}(n,t,e,s):"Left"===t.direction&&"Left"===e.direction?a=function Ure(n,t,e){var i=n.sourcePortWrapper,r=n.targetPortWrapper,s=Xa(n);t.margin={left:s,right:s,top:s,bottom:s},e.margin={left:s,right:s,top:s,bottom:s};var o=Math.round(Math.abs(t.point.x-e.point.x)),a=Math.round(Math.abs(t.point.y-e.point.y));return t.corners.leftr.offsetY||void 0===r&&t.corners.top-t.margin.top>e.corners.middleLeft.y?Ae.Three:t.corners.righte.corners.bottom+e.margin.bottom||void 0===i&&t.corners.middleLeft.y>e.corners.bottom+e.margin.bottom?Ae.Three:t.corners.left>e.corners.right?Ae.Five:0===o||0===a?Ae.One:Ae.Three}(n,t,e):"Left"===t.direction&&"Top"===e.direction?a=function _re(n,t,e,i){var s=n.sourcePortWrapper,o=Xa(n);e.margin={left:o,right:o,top:o,bottom:o},t.margin={top:o,bottom:o,left:o,right:o};var a=n.targetPortWrapper,l={x:Math.min(t.point.x,t.corners.left),y:t.point.y},h={x:e.point.x,y:Math.min(e.point.y,e.corners.top)};if(i){var c=s;s=a,a=c;var d=l;l=h,h=d}return void 0!==s&&s.offsetYa.offsetX||void 0===a&&t.corners.left-t.margin.left>e.corners.topCenter.x?Ae.Two:Ae.Four:void 0!==a&&t.corners.rightr.offsetX||void 0===r&&t.corners.left>e.corners.left||void 0!==r&&t.corners.right+t.margin.righte.corners.right+e.margin.right||void 0===i&&t.corners.left>e.corners.right||void 0!==i&&i.offsetXe.corners.bottom?Ae.Five:0===s||0===o?Ae.One:Ae.Three}(n,t,e));return s&&x3(t,e),o=function Vre(n,t,e,i,r,s){var l,d,h=n.sourceWrapper.corners,c=n.targetWrapper.corners,u=20,f={corners:e.corners,point:e.point,direction:e.direction,margin:e.margin},p={corners:i.corners,point:i.point,direction:i.direction,margin:i.margin};if(!(f.direction===p.direction&&t!==Ae.Five||f.direction!==_n(p.direction)&&t!==Ae.Three))switch(f.direction){case"Left":h.middleLeft.x>c.middleRight.x&&(d=(h.middleLeft.x-c.middleRight.x)/2,u=s?d:Math.min(u,d));break;case"Right":h.middleRight.xc.bottomCenter.y&&(d=(h.topCenter.y-c.bottomCenter.y)/2,u=s?d:Math.min(u,d));break;case"Bottom":h.bottomCenter.yf&&hf)&&o>c&&o<=d&&e>=20&&(s=n.point.x-t.corners.left+s),i&&n.direction===t.direction&&n.corners.left>t.corners.left&&n.corners.left-t.corners.right>=20&&(s=(n.corners.left-t.corners.right)/2),p=Fn(n.point,s,180);break;case"Top":(o>c&&oc)&&h>f&&h<=u&&e>=20&&(s=n.point.y-t.corners.top+s),i&&n.direction===t.direction&&n.corners.top>t.corners.top&&n.corners.top-t.corners.bottom>=20&&(s=(n.corners.top-t.corners.bottom)/2),p=Fn(n.point,s,270);break;case"Right":(h>f&&hf)&&a=c&&e>=20&&(s=t.corners.right-n.point.x+s),i&&n.direction===t.direction&&n.corners.right=20&&(s=(t.corners.left-n.corners.right)/2),p=Fn(n.point,s,0);break;case"Bottom":(o>c&&oc)&&l=f&&e>=20&&(s=t.corners.bottom-n.point.y+s),i&&n.direction===t.direction&&n.corners.bottom=20&&(s=(t.corners.top-n.corners.bottom)/2),p=Fn(n.point,s,90)}r=[n.point,p];var g=void 0;if("Top"===n.direction||"Bottom"===n.direction){var v=n.direction;n.direction=p.x>t.point.x?"Left":"Right",n.point=p,r=LI(n,t,v,r,g=i?.5*Math.abs(p.x-t.point.x):g,i)}else v=n.direction,n.direction=p.y>t.point.y?"Top":"Bottom",n.point=p,r=LI(n,t,v,r,g=i?.5*Math.abs(p.y-t.point.y):g,i);return r}(f,p,u,g)),l}(n,a,t,e,i,r),"Bezier"===n.type&&function Yre(n,t,e){if("Bezier"===n.type)if(0===n.segments.length){var i=e[0],r=e[e.length-1];if(t===Ae.One){var s=Math.min(20,.5*R.findLength(i,r)),o={angle:Gt(i,r),distance:s},a={angle:Gt(r,i),distance:s},l=R.direction(i,r),c=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,orientation:"Left"===l||"Right"===l?"Horizontal":"Vertical"},!0);n.segments.push(c)}else if(t===Ae.Two)o={angle:Gt(i,d=e[1]),distance:.5*R.findLength(i,d)},a={angle:Gt(r,d),distance:.5*R.findLength(r,d)},l=R.direction(i,d),c=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,orientation:"Left"===l||"Right"===l?"Horizontal":"Vertical"},!0),n.segments.push(c);else if(t===Ae.Three){var d={x:.5*((u=e[1]).x+(f=e[e.length-2]).x),y:.5*(u.y+f.y)},p=(o={angle:Gt(i,u),distance:.5*R.findLength(i,u)},a={angle:Gt(d,u),distance:.5*R.findLength(d,u)},R.direction(i,u)),v=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,point:d,orientation:"Left"===p||"Right"===p?"Horizontal":"Vertical"},!0);n.segments.push(v);var y={angle:Gt(d,f),distance:.5*R.findLength(d,f)},S={angle:Gt(r,f),distance:.5*R.findLength(r,f)},b=R.direction(d,f),w=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:y,vector2:S,orientation:"Left"===b||"Right"===b?"Horizontal":"Vertical"},!0);n.segments.push(w)}else if(t===Ae.Four){var D={x:.5*((u=e[1]).x+(f=e[2]).x),y:.5*(u.y+f.y)},A={x:.5*(f.x+(C=e[3]).x),y:.5*(f.y+C.y)};o={angle:Gt(i,u),distance:.5*R.findLength(i,u)},a={angle:Gt(D,u),distance:.5*R.findLength(D,u)},p=R.direction(i,u),v=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,point:D,orientation:"Left"===p||"Right"===p?"Horizontal":"Vertical"},!0),n.segments.push(v),y={angle:Gt(D,f),distance:.5*R.findLength(D,f)},S={angle:Gt(A,f),distance:.5*R.findLength(A,f)},b=R.direction(D,f),w=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:y,vector2:S,point:A,orientation:"Left"===b||"Right"===b?"Horizontal":"Vertical"},!0),n.segments.push(w);var x={angle:Gt(A,C),distance:.5*R.findLength(A,C)},P={angle:Gt(r,C),distance:.5*R.findLength(r,C)},L=R.direction(A,C),N=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:x,vector2:P,orientation:"Left"===L||"Right"===L?"Horizontal":"Vertical"},!0);n.segments.push(N)}else if(t===Ae.Five){var u,f,C,T=e[4],z=(D={x:.5*((u=e[1]).x+(f=e[2]).x),y:.5*(u.y+f.y)},A={x:.5*(f.x+(C=e[3]).x),y:.5*(f.y+C.y)},{x:.5*(C.x+T.x),y:.5*(C.y+T.y)});o={angle:Gt(i,u),distance:.5*R.findLength(i,u)},a={angle:Gt(D,u),distance:.5*R.findLength(D,u)},p=R.direction(i,u),v=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,point:D,orientation:"Left"===p||"Right"===p?"Horizontal":"Vertical"},!0),n.segments.push(v),y={angle:Gt(D,f),distance:.5*R.findLength(D,f)},S={angle:Gt(A,f),distance:.5*R.findLength(A,f)},b=R.direction(D,f),w=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:y,vector2:S,point:A,orientation:"Left"===b||"Right"===b?"Horizontal":"Vertical"},!0),n.segments.push(w),x={angle:Gt(A,C),distance:.5*R.findLength(A,C)},P={angle:Gt(z,C),distance:.5*R.findLength(z,C)},L=R.direction(A,C),N=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:x,vector2:P,point:z,orientation:"Left"===L||"Right"===L?"Horizontal":"Vertical"},!0),n.segments.push(N);var U={angle:Gt(z,T),distance:.5*R.findLength(z,T)},B={angle:Gt(r,T),distance:.5*R.findLength(r,T)},j=R.direction(z,T),oe=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:U,vector2:B,orientation:"Left"===j||"Right"===j?"Horizontal":"Vertical"},!0);n.segments.push(oe)}else c=new fs(n,"segments",{type:"Bezier"},!0),n.segments.push(c)}else for(var ue=0;ue=13?13:n.connectorSpacing<=1?1:n.connectorSpacing}function Gt(n,t){var i=R.findLength({x:t.x,y:n.y},t),r=R.findLength(t,n),s=Math.asin(i/r);return s=180*s/Math.PI,n.xt.y&&(s=360-s):s=n.y0)for(var l=1;lc)&&(s=c,a=h),s>=0&&s<=1)break}}return a}function w3(n,t){var c,d,u,f,p,g,S,b,M,w,D,e=n.x1,i=n.y1,r=n.x2,s=n.y2,o=t.x1,a=t.y1,l=t.x2,h=t.y2;if(w=(c=s-i)*l+(u=e-r)*h+(p=r*i-e*s),0!==(M=c*o+u*a+p)&&0!==w&&C3(M,w)||(b=(d=h-a)*r+(f=o-l)*s+(g=l*a-o*h),0!==(S=d*e+f*i+g)&&0!==b&&C3(S,b)))return null;var A=c*f-d*u;return 0===A?null:(A<0?-A/2:A/2,0,{x:(D=u*g-f*p)<0?(D-0)/A:(D+0)/A,y:(D=d*p-c*g)<0?(D-0)/A:(D+0)/A})}function C3(n,t){return n*t>=0}function E3(n,t,e){switch(t.direction){case"Left":t.point.x>n.left&&(e=t.point.x-n.left>e?t.point.x-n.left+e:e);break;case"Right":t.point.xe?n.right-t.point.x+e:e);break;case"Top":t.point.y>n.top&&(e=t.point.y-n.top>e?t.point.y-n.top+e:e);break;case"Bottom":t.point.ye?n.bottom-t.point.y+e:e)}return e}function kl(n,t){var e;switch(n.direction){case"Left":case"Right":var i={x:t.point.x,y:n.point.y};e=R.equals(n.point,i)||R.equals(t.point,i)?[n.point,t.point]:[n.point,i,t.point];break;case"Top":case"Bottom":var r={x:n.point.x,y:t.point.y};e=R.equals(n.point,r)||R.equals(t.point,r)?[n.point,t.point]:[n.point,r,t.point]}return e}function Ys(n,t,e,i,r,s){void 0===s&&(s=!1),i||(i=20),s&&t.direction!==e.direction&&(i="Left"===t.direction||"Right"===t.direction?Math.floor(.5*Math.abs(t.point.x-e.point.x)):Math.floor(.5*Math.abs(t.point.y-e.point.y)));var l,h,u,o=n.sourcePortWrapper,c=e.point.x-t.point.x,d=e.point.y-t.point.y;if(!r&&(Math.abs(c)<.001||Math.abs(d)<.001)&&void 0===e.direction)return[t.point,e.point];if(void 0===n.targetWrapper&&Math.abs(c)<=31&&Math.abs(d)<=31){if("Left"===t.direction||"Right"===t.direction?Math.abs(d)<12&&(t.direction=t.point.y>e.point.y?"Top":"Bottom"):Math.abs(c)<12&&(t.direction=t.point.x>e.point.x?"Left":"Right"),Math.abs(c)>12||Math.abs(d)>12)return kl(t,e);i+=5}return"Left"===t.direction||"Right"===t.direction?("Right"===t.direction?(void 0!==e.direction&&"Right"===e.direction&&(i=Math.max(t.point.x,e.point.x)-t.point.x+i),t.point.x>e.point.x&&void 0===o&&(i=-i)):(void 0!==e.direction&&"Left"===e.direction&&(i=t.point.x-Math.min(t.point.x,e.point.x)+i),(t.point.x>e.point.x||void 0!==o||"Left"===t.direction)&&(i=-i)),u=e.point.y-t.point.y,l=Fn(t.point,i,0),0!=(u=e.point.y-l.y)&&(h=Fn(l,e.point.y-l.y,90))):("Top"===t.direction||"Bottom"===t.direction)&&("Bottom"===t.direction?void 0!==e.direction&&"Bottom"===e.direction&&(i=Math.max(t.point.y,e.point.y)-t.point.y+i):(void 0!==e.direction&&"Top"===e.direction&&(i=t.point.y-Math.min(t.point.y,e.point.y)+i),(t.point.y>e.point.y||void 0!==o||"Top"===t.direction)&&(i=-i)),u=e.point.x-t.point.x,l=Fn(t.point,i,90),0!=(u=e.point.x-l.x)&&(h=Fn(l,e.point.x-l.x,0))),0===u?[t.point,e.point]:[t.point,l,h,e.point]}function LI(n,t,e,i,r,s){var o;switch(void 0===r&&(r=20),void 0===s&&(s=!1),void 0===e?(n.margin={left:2,right:2,top:2,bottom:2},t.margin={left:0,right:5,top:0,bottom:5},s&&(n.margin={left:10,right:10,top:10,bottom:10},t.margin={left:10,right:10,top:10,bottom:10},"Left"===n.direction?(r=zx(n,t,e,r),n.corners.left-t.corners.right>=5&&(r=Math.abs(n.point.x-n.corners.left)+.5*Math.floor(n.corners.left-t.corners.right))):"Right"===n.direction?(r=Rx(n,t,r,e),t.corners.left-n.corners.right>=5&&(r=Math.abs(n.point.x-n.corners.right)+.5*Math.floor(t.corners.left-n.corners.right))):"Top"===n.direction?(r=Px(n,t,e,r),n.corners.top-t.corners.bottom>=5&&(r=Math.abs(n.point.y-n.corners.top)+.5*Math.floor(n.corners.top-t.corners.bottom))):"Bottom"===n.direction&&(r=Hx(n,t,r,e),t.corners.top-n.corners.bottom>=5&&(r=Math.abs(n.point.y-n.corners.bottom)+.5*Math.floor(t.corners.top-n.corners.bottom))))):("Bottom"===n.direction?s?t.corners.top-n.corners.bottom<20&&(r=t.corners.bottom-n.point.y+25):t.corners.top>n.corners.bottom&&t.corners.top-n.corners.bottom<20&&(r=(t.corners.top-n.corners.bottom)/2):"Top"===n.direction?s?n.corners.top-t.corners.bottom<20&&(r=n.point.y-t.corners.top+25):t.corners.bottomn.corners.right&&t.corners.left-n.corners.right<20&&(r=(t.corners.left-n.corners.right)/2):"Left"===n.direction&&(s?n.corners.left-t.corners.right<20&&(r=n.point.x-t.corners.left+25):t.corners.rightt.point.y||"Top"===t.direction&&n.point.yt.point.x||"Left"===t.direction&&n.point.xh||e.corners.top-e.margin.top<=i.point.y&&e.corners.bottom+e.margin.bottom>=i.point.y))if(!s||"Top"!==e.direction&&"Bottom"!==e.direction)c=Math.min(Math.abs(i.corners.left-e.corners.right)/2,20),h=e.corners.right-n.x+c;else{var c=Math.abs(i.corners.left-e.corners.right)/2;h=e.corners.right-n.x+c}else h="Top"===e.direction&&n.y>i.point.y||"Bottom"===e.direction&&n.y=e.corners.left-e.margin.left&&n.x<=e.corners.right+e.margin.right?Math.min(i.corners.left,e.corners.left)-n.x-20:i.corners.left-n.x-20;break;case"Right":if(e.corners.left-e.margin.left>i.corners.right+i.margin.right&&(e.corners.left-e.margin.right-i.corners.right>h||e.corners.top-e.margin.top<=i.point.y&&e.corners.bottom+e.margin.bottom>=i.point.y))if(!s||"Top"!==e.direction&&"Bottom"!==e.direction)c=Math.min(Math.abs(e.corners.left-i.corners.right)/2,20),h=e.corners.left-n.x-c;else{c=Math.abs(e.corners.left-i.corners.right)/2;h=e.corners.left-n.x-c}else h="Top"===e.direction&&n.y>i.point.y||"Bottom"===e.direction&&n.y=e.corners.left-e.margin.left&&n.x<=e.corners.right+e.margin.right?Math.max(i.corners.right,e.corners.right)-n.x+20:i.corners.right-n.x+20}o=Fn(n,h,0),a=Fn(o,i.point.y-n.y,90),l=i.point}else if("vertical"===t){switch(i.direction){case"Top":e.corners.bottom+e.margin.bottomh||e.corners.left-e.margin.left<=i.point.x&&e.corners.right+e.margin.right>=i.point.x)?!s||"Right"!==e.direction&&"Left"!==e.direction?(c=Math.min(Math.abs(i.corners.top-e.corners.bottom)/2,20),h=e.corners.bottom-n.y+c):(c=Math.abs(i.corners.top-e.corners.bottom)/2,h=e.corners.bottom-n.y+c):h="Left"===e.direction&&n.x>i.point.x||"Right"===e.direction&&n.x=e.corners.top-e.margin.top&&n.y<=e.corners.bottom+e.margin.bottom?Math.min(i.corners.top,e.corners.top)-n.y-20:i.corners.top-n.y-20;break;case"Bottom":e.corners.top-e.margin.top>i.corners.bottom+i.margin.bottom&&(e.corners.top-e.margin.top-i.corners.bottom>h||e.corners.left-e.margin.left<=i.point.x&&e.corners.right+e.margin.right>=i.point.x)?!s||"Right"!==e.direction&&"Left"!==e.direction?(c=Math.min(Math.abs(e.corners.top-i.corners.bottom)/2,20),h=e.corners.top-n.y-c):(c=Math.abs(e.corners.top-i.corners.bottom)/2,h=e.corners.top-n.y-c):h="Left"===e.direction&&n.x>i.point.x||"Right"===e.direction&&n.x=e.corners.top-e.margin.top&&n.y<=e.corners.bottom+e.margin.bottom?Math.max(i.corners.bottom,e.corners.bottom)-n.y+20:i.corners.bottom-n.y+20}o=Fn(n,h,90),a=Fn(o,i.point.x-n.x,0),l=i.point}r.push(o),r.push(a),r.push(l)}function Px(n,t,e,i){return n.corners.top-n.margin.top>t.corners.top+t.margin.top&&n.corners.top-n.margin.top<=t.corners.bottom+t.margin.bottom?(("Right"===t.direction&&n.point.xt.point.x)&&(i+=n.corners.top-t.corners.top),i+=n.point.y-n.corners.top):i+=void 0!==e&&"Left"!==e&&"Right"===t.direction&&n.point.xt.corners.left-t.margin.left&&n.corners.left-n.margin.left<=t.corners.right+t.margin.right?(("Bottom"===t.direction&&n.point.yt.point.y)&&(i+=n.corners.left-t.corners.left),i+=n.point.x-n.corners.left):i+=void 0!==e&&"Top"!==e&&"Bottom"===t.direction&&n.point.y=t.corners.left-t.margin.left?(("Bottom"===t.direction&&n.point.yt.point.y)&&(e+=t.corners.right-n.corners.right),e+=n.corners.right-n.point.x):e+=void 0!==i&&"Top"!==i&&"Bottom"===t.direction&&n.point.y=t.corners.top-t.margin.top?(("Right"===t.direction&&n.point.xt.point.x)&&(e+=t.corners.bottom-n.corners.bottom),e+=n.corners.bottom-n.point.y):e+=void 0!==i&&"Left"!==i&&"Right"===t.direction&&n.point.xp&&d=u&&d=f&&d<=p?"Left":"Right"}function _n(n){switch(n){case"Top":return"Bottom";case"Bottom":return"Top";case"Left":return"Right";case"Right":return"Left"}return"auto"}var A3=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Ac=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},NI=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return A3(t,n),Ac([I()],t.prototype,"width",void 0),Ac([I()],t.prototype,"height",void 0),t}(Ee),Gre=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return A3(t,n),Ac([I()],t.prototype,"width",void 0),Ac([I()],t.prototype,"height",void 0),Ac([I()],t.prototype,"fit",void 0),Ac([I()],t.prototype,"description",void 0),Ac([I()],t.prototype,"template",void 0),Ac([I()],t.prototype,"tooltip",void 0),t}(Ee),Xre=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Pl=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},L3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Xre(t,n),Pl([I("")],t.prototype,"id",void 0),Pl([I(Number.MIN_VALUE)],t.prototype,"zIndex",void 0),Pl([re({},Jn)],t.prototype,"margin",void 0),Pl([I(!0)],t.prototype,"visible",void 0),Pl([re({},Dd)],t.prototype,"tooltip",void 0),Pl([I(!1)],t.prototype,"excludeFromLayout",void 0),Pl([I()],t.prototype,"addInfo",void 0),Pl([I("None")],t.prototype,"flip",void 0),Pl([I("All")],t.prototype,"flipMode",void 0),Pl([re({},Gre)],t.prototype,"symbolInfo",void 0),t}(Ee),qre=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),es=function(n){function t(e,i,r,s){var o=n.call(this)||this;return o.data="",o.nodeId="",o.annotationId="",o.diagramId="",o.diagramId=i,o.nodeId=e,o.annotationId=r,o.templateFn=GF(s),o}return qre(t,n),t.prototype.getNodeTemplate=function(){return this.templateFn},Object.defineProperty(t.prototype,"content",{get:function(){return this.data},set:function(e){this.data=e,this.canReset||(this.canReset=!0,this.isTemplate||(this.template=Fh(this,!0)),this.canReset=!1,this.isDirt=!0)},enumerable:!0,configurable:!0}),t}(hs),Bx=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),cs=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},N3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Bx(t,n),cs([I("")],t.prototype,"id",void 0),cs([I("transparent")],t.prototype,"fill",void 0),cs([I("black")],t.prototype,"iconStrokeColor",void 0),cs([I(0)],t.prototype,"iconStrokeWidth",void 0),cs([I(!0)],t.prototype,"visibility",void 0),cs([I(10)],t.prototype,"width",void 0),cs([I(10)],t.prototype,"height",void 0),cs([I("transparent")],t.prototype,"handleStrokeColor",void 0),cs([I(1)],t.prototype,"handleStrokeWidth",void 0),cs([I("")],t.prototype,"pathData",void 0),cs([I(0)],t.prototype,"cornerRadius",void 0),cs([re({left:0,right:0,top:0,bottom:0},Jn)],t.prototype,"padding",void 0),cs([re({},Dd)],t.prototype,"tooltip",void 0),t}(Ee),O3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Bx(t,n),cs([re({x:0,y:0},R)],t.prototype,"offset",void 0),cs([re({},Jn)],t.prototype,"margin",void 0),t}(N3),OI=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Bx(t,n),cs([I(.5)],t.prototype,"offset",void 0),cs([I("Center")],t.prototype,"alignment",void 0),cs([re({x:0,y:0},R)],t.prototype,"displacement",void 0),t}(N3);function xd(n){return n?n instanceof Kn||n instanceof Or?n.constraints&Nr.Select:n instanceof de?n.constraints&qe.Select:n.constraints&ie.Select:1}function ro(n){return n?n instanceof Kn||n instanceof Or?n.constraints&Nr.Drag:n instanceof de?n.constraints&qe.Drag:n instanceof ei?1:n.constraints&ie.Drag:1}function $re(n,t){return n instanceof de?n.constraints&qe.PointerEvents:n.constraints&ie.PointerEvents}function kI(n){return n instanceof de?n.constraints&qe.Delete:n.constraints&ie.Delete}function PI(n){return n.constraints&qe.DragSourceEnd}function zI(n){return n.constraints&qe.DragTargetEnd}function RI(n){return n.constraints&qe.DragSegmentThumb}function HI(n){return n instanceof Kn||n instanceof Or?n.constraints&Nr.Rotate:n.constraints&ie.Rotate}function BI(n){return n.constraints&ie.Shadow}function ua(n){return n instanceof te&&n.constraints&ie.InConnect?n.constraints&ie.InConnect:0}function zh(n){return n&&n.constraints&&!(n.constraints&oi.None)&&n.constraints&oi.InConnect?n.constraints&oi.InConnect:0}function Rh(n){return n instanceof te&&n.constraints&ie.OutConnect?n.constraints&ie.OutConnect:0}function Td(n){return n&&n.constraints&&!(n.constraints&oi.None)&&n.constraints&oi.OutConnect?n.constraints&oi.OutConnect:0}function zl(n,t){var e=0;return n instanceof Kn||n instanceof Or?e=n.constraints&Nr.Resize:n&&("SouthEast"===t?e=n.constraints&ie.ResizeSouthEast:"East"===t?e=n.constraints&ie.ResizeEast:"NorthEast"===t?e=n.constraints&ie.ResizeNorthEast:"South"===t?e=n.constraints&ie.ResizeSouth:"North"===t?e=n.constraints&ie.ResizeNorth:"SouthWest"===t?e=n.constraints&ie.ResizeSouthWest:"West"===t?e=n.constraints&ie.ResizeWest:"NorthWest"===t&&(e=n.constraints&ie.ResizeNorthWest)),e}function FI(n){return n instanceof de?n.constraints&qe.AllowDrop:n.constraints&ie.AllowDrop}function Ds(n){return n.constraints&nt.Virtualization}function Uv(n){return n.tool&ri.SingleSelect}function jv(n){return n.tool&ri.MultipleSelect}function Lc(n){return n.tool&ri.ZoomPan}function _I(n){return n.tool&ri.ContinuousDraw}function k3(n){return n.tool&ri.DrawOnce}function UI(n){return n.tool&ri.SingleSelect||n.tool&ri.MultipleSelect}function Vv(n){return n.constraints&nt.UserInteraction}function P3(n){return n.constraints&nt.ZoomTextEdit}function Wv(n){return function ine(n){return n.constraints&nt.ApiUpdate}(n)||n.diagramActions&ee.ToolAction}function Fx(n,t){return n.constraints&oi.Draw}function _x(n,t){return n.constraints&oi.Drag}function jI(n){return!(n&Ga.DrawSelectorBorder)}function z3(n){return!!(n&Ga.PreventRenderSelector)}var Ux=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Yv=function(n){function t(){var e=null!==n&&n.apply(this,arguments)||this;return e.childTable=[],e.cellStyle={},e.desiredRowHeight=[],e.desiredCellWidth=[],e}return Ux(t,n),t.prototype.rowDefinitions=function(){return this.rowDefns},t.prototype.columnDefinitions=function(){return this.colDefns},t.prototype.addObject=function(e,i,r,s,o){if(this.rows.length>=i){var a=this.rows[parseInt(i.toString(),10)];if(a.cells.length>r){o=o||1,s=s||1;var l=a.cells[parseInt(r.toString(),10)];l.columnSpan=Math.max(o,l.columnSpan),l.rowSpan=Math.max(s,l.rowSpan);var h=new ane;(h=e).rowId=i,h.columnId=r,h.columnSpan=o,this.childTable[h.id]=h,this.addObjectToCell(h,l)}}},t.prototype.addObjectToCell=function(e,i){i.children||(i.children=[]),e.style.strokeColor="black",e.style.strokeWidth=1,i.children.push(e)},t.prototype.updateProperties=function(e,i,r,s){this.offsetX=e,this.offsetY=i,this.width=r,this.height=s},t.prototype.setDefinitions=function(e,i){this.rowDefns=e,this.colDefns=i,this.children=[],this.rows=this.rows||[];for(var r=0;r0){for(var h=0;hi&&this.updateRowHeight(e,l,!1)}},t.prototype.setTextRefresh=function(e){if(e.children&&e.children.length)for(var i=e.children,r=0;ri&&this.updateColumnWidth(e,a,!1)}},t.prototype.calculateCellWidth=function(e){for(var i,r,s,o=0;os.bounds.width&&(0===s.children.length||void 0===s.children[0].maxWidth)?s.outerBounds.width:s.bounds.width,i=i?is.bounds.height?s.outerBounds.height:s.bounds.height,i=i?i0?e.children[0]:void 0;if(a&&1===e.columnSpan){o="Width"===i?a.bounds.right:a.bounds.bottom,s||(s="Width"===i?a.bounds.width:a.bounds.height);for(var l=0;lo){var d=c-o+("Width"===i?a.bounds.width:a.bounds.height);s&&(s=s0?this.rowDefns.splice(e,0,i):this.rowDefns.push(i);var s=new R3;s.cells=[],(new Ad).width=this.width,this.addCellInRow(this.colDefns,i,s),e>this.rows.length-1?this.rows.push(s):this.rows.splice(e,0,s),r&&(this.measure(new me(this.width,this.height)),this.arrange(this.desiredSize))},t.prototype.addColumn=function(e,i,r){var s,o,a,l,h=this.rows;this.colDefns.length>0?this.colDefns.splice(e,0,i):this.colDefns.push(i),void 0!==this.width&&(this.width+=i.width);for(var c=0;cs.cells.length-1?s.cells.push(l):s.cells.splice(e,0,l),this.children.push(l);r&&(this.measure(new me(this.width,this.height)),this.arrange(this.desiredSize))},t.prototype.removeRow=function(e){var i,r,o=this.rows[parseInt(e.toString(),10)];this.height-=this.rowDefns[parseInt(e.toString(),10)].height;for(var a=0;a0){var r=0,s=0;i=new me(0,0),this.calculateSize();for(var o=0,a=this.rows;o0){for(var o=this.offsetX-e.width*this.pivot.x,a=this.offsetY-e.height*this.pivot.y,l=o,h=0,c=this.rows;h1&&this.children.splice(this.children.indexOf(p)+1,p.columnSpan-1),p.rowSpan>1)for(y=s,S=0;y+p.rowSpan-10){for(var c=0;c0?1:0,v=0;v0||a.outEdges.length>0))for(f=a.inEdges.concat(a.outEdges),s=0;s0)for(o=0;o1)for(a=1;a0))if(h=n.wrapper.children[0],"Horizontal"===e.orientation)for(o=e.header&&e.hasHeader?h.rows[1]:h.rows[0],r=0;r0){var e=void 0;t.lineRoutingModule&&t.constraints&nt.LineRouting&&t.lineRoutingModule.renderVirtualRegion(t,!0);for(var i=0;i0?o+1:o)].height=t.wrapper.height;else if(t.isPhase)for(l[t.rowIndex-o].offset=t.wrapper.height,p=0;p0?1:0)].width=t.wrapper.width}function WI(n,t){var i=n.shape,r=i.header&&i.hasHeader?1:0;return"Horizontal"===i.orientation?t.rowIndex-(r+=i.phases.length>0?1:0):t.columnIndex-(i.phaseSize&&i.phases.length>0?1:0)}function YI(n){var t=0,e=n.shape;return"Horizontal"===e.orientation&&(t=e.header&&e.hasHeader?1:0),e.phases.length>0&&e.phaseSize&&(t+=1),t}function QI(n,t,e,i){var r=n.shape;if(r.phases.length>0){var s=t.nameTable[r.phases[parseInt(i.toString(),10)].header.id];s&&s.maxWidth0?u+1:u);var w=Nc(n,o),C=void 0!==i?i:l.lanes.length;if(u+=C,r={element:M,cause:n.diagramActions,diagramAction:n.getDiagramAction(n.diagramActions),state:"Changing",type:"Addition",cancel:!1,laneIndex:C},n.triggerEvent(Ce.collectionChange,r),!r.cancel){if(c){var D=new Qv;D.height=e.height,o.addRow(u,D,!1),s.height=void 0!==s.height?s.height+e.height:s.height,s.wrapper.height=o.height=s.height}else{var A=new Ad;A.width=e.width,o.addColumn(C+1,A,!1),s.width&&(s.width+=e.width,s.wrapper.width=o.width=s.width),n.diagramActions&ee.UndoRedo||(o.rows[0].cells[0].columnSpan+=1)}n.diagramActions&ee.UndoRedo||(M.id=""===M.id?Qe():M.id),void 0!==i?l.lanes.splice(i,0,M):l.lanes.push(M),r={element:M,cause:n.diagramActions,diagramAction:n.getDiagramAction(n.diagramActions),state:"Changed",type:"Addition",cancel:!1,laneIndex:C},n.triggerEvent(Ce.collectionChange,r),B3(o,n,s,u,C,c),h="Horizontal"===l.orientation?n.nameTable[o.rows[parseInt(u.toString(),10)].cells[0].children[0].id]:l.header&&l.hasHeader?n.nameTable[o.rows[1].cells[parseInt(u.toString(),10)].children[0].id]:n.nameTable[o.rows[0].cells[parseInt(u.toString(),10)].children[0].id],n.diagramActions&ee.UndoRedo||(d={type:"LaneCollectionChanged",changeType:"Insert",undoObject:$(M),redoObject:$(h),category:"Internal"},n.addHistoryEntry(d)),$f(n,s,"Horizontal"===l.orientation?u:l.header&&l.hasHeader?1:0),qf(s),Oc(n,s);var P=!1;if((f=e.children)&&f.length>0)for(p=0;p0){var o=t.children[0],a=n.nameTable[o.id];(function vne(n,t,e){return n.left-(e.left||0)<=t.x&&n.right+(e.right||0)>=t.x&&n.top-(e.top||0)<=t.y&&n.bottom+(e.bottom||0)>=t.y})(o.bounds,e,r)&&(n.addChild(a,i),s=!0)}return s}function mne(n,t,e){if("SwimLane"===t.shape.type){var i=void 0,r=void 0,s=void 0,a=void 0,l=void 0,h=void 0,c=t.wrapper.bounds.x,d=t.wrapper.bounds.y,u=t.shape,f=u.padding,p=u.phases,g=void 0,v=t.wrapper.children[0],y="Horizontal"===u.orientation;if(i=u.header&&u.hasHeader?0:-1,u.phases.length>0&&(i+=1),e.offset>(y?u.lanes[0].header.width:u.lanes[0].header.height)){for(h=0;he.offset){if(g=h>0?e.offset-(h>0?p[h-1]:s).offset:e.offset,y){var b=v.columnDefinitions()[parseInt(h.toString(),10)];b.width-=g,(a=n.nameTable[u.phases[parseInt(h.toString(),10)].header.id]).maxWidth=a.wrapper.maxWidth=b.width,v.updateColumnWidth(h,b.width,!1);var M=new Ad;M.width=g,l=h,v.addColumn(h,M,!1);break}var w=v.rowDefinitions()[h+i];w.height-=g,a=n.nameTable[u.phases[parseInt(h.toString(),10)].header.id],v.updateRowHeight(h+i,w.height,!1);var C=new Qv;C.height=g,l=h,v.addRow(h+i,C,!1);break}if(n.diagramActions&ee.UndoRedo&&void 0===l&&(D=n.historyManager.currentEntry.next).isLastPhase&&function yne(n,t,e,i,r,s){var a=t.shape.phases[n-2],l=e.previousPhase.offset;if(r){var h=i.columnDefinitions()[n-1],c=new Ad;n>1?(c.width=h.width-(l-a.offset),h.width=l-a.offset):(c.width=h.width-l,h.width=l),i.updateColumnWidth(n-1,h.width,!1),i.addColumn(n,c,!1)}else{h=i.rowDefinitions()[parseInt(n.toString(),10)];var d=new Qv;n>1?(d.height=e.undoObject.offset-l,h.height=l-a.offset):(d.height=h.height-l,h.height=l),i.updateRowHeight(n,h.height,!1),i.addRow(1+n,d,!1)}}(l=p.length,t,D,v,y),l>=0){var A=new fb(t.shape,"phases",e,!0);if(n.diagramActions&ee.UndoRedo||(A.id+=Qe()),u.phases.splice(l,0,A),jx(v,n,t,i,y,l),y){if(r=n.nameTable[v.rows[parseInt(i.toString(),10)].cells[parseInt(l.toString(),10)].children[0].id],0===l&&u.header&&u.hasHeader){v.rows[0].cells[0].children=v.rows[0].cells[1].children,v.rows[0].cells[1].children=[];for(var x=v.rows[0],P=0;Pl+1){var O=n.nameTable[v.rows[parseInt(i.toString(),10)].cells[l+1].children[0].id];v.updateColumnWidth(l+1,L[l+1].width,!0,f),O.maxWidth=O.wrapper.maxWidth=L[l+1].width}t.width=t.wrapper.width=t.wrapper.children[0].width=v.width}else{r=n.nameTable[v.rows[i+l].cells[0].children[0].id];var N=v.rowDefinitions(),T=N[i+l].height;(function Ine(n,t,e,i,r){for(var o,a,l=e.rows[parseInt(i.toString(),10)],h=e.rows[i+1],c=e.rows[i-1],d=1;di+l+1&&v.updateRowHeight(i+l+1,T=N[i+l+1].height,!0,f),t.height=t.wrapper.height=t.wrapper.children[0].height=v.actualSize.height}if(qf(t),t.width=t.wrapper.actualSize.width,Oc(n,t),n.drag(t,c-t.wrapper.bounds.x,d-t.wrapper.bounds.y),VI(t,n),n.commandHandler.select(r),!(n.diagramActions&ee.UndoRedo)){var D={type:"PhaseCollectionChanged",changeType:"Insert",undoObject:$(A),redoObject:$(r),category:"Internal"};n.addHistoryEntry(D)}n.updateDiagramObject(t)}}}}function V3(n,t,e,i,r,s,o){var a,l,p,h=t.shape,c="Horizontal"===h.orientation,d=t.wrapper.children[0],g=c?s:o;e?(a=c?e.bounds.x+e.bounds.width:e.bounds.x,l=c?e.bounds.y:e.bounds.y+e.bounds.height):(a=d.bounds.x,l=r.bounds.y);var v=new Ne(a,l,i.desiredCellWidth,i.desiredCellHeight),S=Gv(n,0,t,{id:t.id+(c?h.lanes[g-2]:h.lanes[g-1]).id+Qe()[0],rowIndex:s,columnIndex:o,width:i.minWidth,height:i.minHeight,style:(c?h.lanes[g-2]:h.lanes[g-1]).style,constraints:ie.Default|ie.AllowDrop,container:{type:"Canvas",orientation:c?"Horizontal":"Vertical"}},!1,!1,!0);if(S.children[0].isCalculateDesiredSize=!1,d.addObject(S,s,o),r&&r.children&&r.children.length)for(p=0;p1)for(var p=1;ph.margin.left&&(h.margin.left=f)):(h.margin.top-=e.desiredCellHeight,f>h.margin.top&&(h.margin.top=f)))}(n,r,i,v,S,c,e)}function W3(n,t,e){if("SwimLane"===t.shape.type&&("ResizeSouth"===e||"ResizeEast"===e)){var i=t.shape,r=t.wrapper.children[0],s=void 0,o=void 0;"ResizeSouth"===e?"Vertical"===i.orientation?s=r.rows[r.rows.length-1].cells[0]:(o=r.rows.length-1,s=r.rows[parseInt(o.toString(),10)].cells[r.rows[parseInt(o.toString(),10)].cells.length-1]):(o=i.header&&i.hasHeader?1:0,s=r.rows[parseInt(o.toString(),10)].cells[r.rows[parseInt(o.toString(),10)].cells.length-1]),n.commandHandler.select(n.nameTable[s.children[0].id])}}function GI(n,t,e,i,r,s){var o,a,l,c,u,f,p,d=Qe(),g=n.shape,v=g.phases,y=n.offsetX-n.wrapper.actualSize.width/2,S=n.offsetY-n.wrapper.actualSize.height/2;if("Vertical"===g.orientation&&(S+=g.header&&g.hasHeader?g.header.height:0),!s)for(r||(n.id+=d,g&&g.header&&g.hasHeader?g.header.id+=d:g.header=void 0),o=0;v&&o0&&s.columnIndex>0||s.isLane)?(a=function Lne(n,t,e){for(var i=new Ne,r="SwimLane"===n.shape.type?n.wrapper.children[0].rows:n.wrapper.rows,s=e?1:0;s=0;a--)i?i.id===o.children[parseInt(a.toString(),10)].id&&o.children.splice(a,1):(n.removeDependentConnector(o.children[parseInt(a.toString(),10)]),n.diagramActions&ee.UndoRedo||(n.diagramActions=n.diagramActions|ee.UndoRedo,s=!0),n.remove(o.children[parseInt(a.toString(),10)]),o.children.splice(a,1),s&&(n.diagramActions=n.diagramActions&~ee.UndoRedo))}function Mne(n){return n.children[0]}function $v(n,t){t&&(n.nodes.splice(n.nodes.indexOf(t),1),n.removeFromAQuad(t),n.removeObjectsFromLayer(t),delete n.nameTable[t.id],n.removeElements(t))}function Q3(n,t,e,i){var r;if("SwimLane"===e.shape.type){var s=e.shape,o=void 0;if(1===s.lanes.length)n.remove(e);else{var a=e.wrapper.bounds.x,l=e.wrapper.bounds.y,h=void 0,c=void 0,d=void 0,u=void 0,p=e.wrapper.children[0];if(o=i?s.lanes.indexOf(i):WI(e,t),r={element:t,cause:n.diagramActions,diagramAction:n.getDiagramAction(n.diagramActions),state:"Changing",type:"Removal",cancel:!1,laneIndex:o},n.triggerEvent(Ce.collectionChange,r),!r.cancel){var g=s.lanes[parseInt(o.toString(),10)],v=g.children;g.children=[];for(var y=0;y0)for(u=0;u0)for(u=0;u0)for(e=0;e1){c===l.phases.length-1&&(o=!0,a=$(l.phases[c-1]));var u=$(l.phases[parseInt(c.toString(),10)]);if(l.phases.splice(c,1),!(n.diagramActions&ee.UndoRedo)){var f={type:"PhaseCollectionChanged",changeType:"Remove",undoObject:u,previousPhase:a,redoObject:$(t),category:"Internal",isLastPhase:o};n.addHistoryEntry(f)}"Horizontal"===l.orientation?function Cne(n,t,e,i){var r,s,o,a,l,h,c,d,u,f,p,g;for(i=void 0!==i?i:e.columnIndex,c=0;c1&&(s=r.cells[parseInt(i.toString(),10)],l=(o=r.cells.length-1===i?r.cells[i-1]:r.cells[i+1]).children[0],s.children.length>0))if(p=n.nameTable[(a=s.children[0]).id],0===o.children.length&&s.children.length>0)o.children=s.children,o.columnSpan=s.columnSpan-1;else{for(d=0;d0){var M=s.children[0],w=n.nameTable[M.id];if(i=e.x&&a.bounds.y<=e.y&&a.bounds.bottom>=e.y){var l=void 0,h=a.bounds.y,c=a.bounds.x,d=n.nameTable[r.parentId]||r;if("SwimLane"===d.shape.type)o=Jv(r,d,t,n,!0);else{var f=n.nameTable[r.parentId]||r,p=f.shape;l=f.wrapper,a.actualSize.widtha.outerBounds.x)&&(void 0!==r.rowIndex?(l.updateColumnWidth(r.columnIndex,a.outerBounds.width,!0),"Horizontal"===p.orientation&&p.phaseSize&&QI(f,n,a,r.columnIndex),Oc(n,f),n.drag(f,c-a.bounds.x,h-a.bounds.y)):n.scale(r,1+(a.outerBounds.width-a.actualSize.width)/a.actualSize.width,1,a.outerBounds.xa.outerBounds.y)&&(void 0!==r.rowIndex?(l.updateRowHeight(r.rowIndex,a.outerBounds.height,!0),n.drag(f,c-a.bounds.x,h-a.bounds.y)):n.scale(r,1,1+(a.outerBounds.height-a.actualSize.height)/a.actualSize.height,a.outerBounds.y=e.x&&a.bounds.y<=e.y&&a.bounds.bottom>=e.y)&&!(t.constraints&ie.AllowMovingOutsideLane)){var l=$(t);n.clearSelection(),$3(n,t),t.parentId="",t.parentObj=n,t.propName="nodes";var h={type:"ChildCollectionChanged",category:"Internal",undoObject:l,redoObject:$(t)};n.addHistoryEntry(h),n.commandHandler.isContainer&&(n.commandHandler.isContainer=!1,n.endGroupAction()),Z3(t,n)}n.protectPropertyChange(o)}}function XI(n,t){var e,i,r;return n.enableServerDataBinding(!1),ce()||(n.selectedObject.helperObject?r=n.selectedObject.helperObject:(n.selectedItems.nodes.length>0||n.selectedItems.connectors.length>0)&&(t instanceof ei&&t.nodes.length+t.connectors.length===1?(e=t.nodes.length>0?t.nodes[0]:t.connectors[0],i=n.selectedItems.wrapper.children[0]):(e=t,i=n.selectedItems.wrapper),n.selectedObject.actualObject=e,!n.currentSymbol&&(e.isLane&&Qx(e,n)&&Dn(n,e)||!e.isLane&&Dn(n,e)||n.constraints&nt.LineRouting&&n.selectedItems.nodes.length>0))&&(r=function Nne(n,t){for(var e,i={},r=0,s=Object.keys(t);r=t.x-e&&n.x<=t.x+e&&n.y>=t.y-e&&n.y<=t.y+e}function $a(n){return n.selectedItems.nodes.length>0||n.selectedItems.connectors.length>0}function K3(n){return 1===n.selectedItems.connectors.length&&!n.selectedItems.nodes.length}function _r(n,t,e,i){if(void 0===e&&(e=!0),t instanceof ei)return!0;if(t instanceof te)for(;t;){if(-1!==n.selectedItems.nodes.indexOf(t)&&void 0===n.selectedItems.annotation)return!0;if(e)break;t=n.nameTable[t.parentId]}else if(t instanceof de){if(-1!==n.selectedItems.connectors.indexOf(t)&&void 0===n.selectedItems.annotation)return!0}else if((t instanceof Kn||t instanceof Or)&&n.selectedItems.annotation&&n.selectedItems.wrapper.children[0].id===i.id)return!0;return!1}var Gx={None:"default",Rotate:"crosshair",Select:"default",Drag:"move",ResizeWest:"w-resize",ResizeEast:"e-resize",ResizeSouth:"s-resize",ResizeNorth:"n-resize",Draw:"crosshair",PortDraw:"crosshair",ResizeNorthEast:"ne-resize",ResizeNorthWest:"nw-resize",ResizeSouthEast:"se-resize",ResizeSouthWest:"sw-resize",ConnectorSourceEnd:"move",ConnectorTargetEnd:"move",BezierSourceThumb:"move",BezierTargetThumb:"move",OrthoThumb:"move",SegmentEnd:"move",Pan:"grab",Hyperlink:"pointer",PortDrag:"pointer",LabelSelect:"pointer",LabelDrag:"move",LabelRotate:"crosshair",LabelResizeWest:"w-resize",LabelResizeEast:"e-resize",LabelResizeSouth:"s-resize",LabelResizeNorth:"n-resize",LabelResizeNorthEast:"ne-resize",LabelResizeNorthWest:"nw-resize",LabelResizeSouthEast:"se-resize",LabelResizeSouthWest:"sw-resize"},ds=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Nd=function(n,t,e,i){return new(e||(e=Promise))(function(r,s){function o(h){try{l(i.next(h))}catch(c){s(c)}}function a(h){try{l(i.throw(h))}catch(c){s(c)}}function l(h){h.done?r(h.value):new e(function(c){c(h.value)}).then(o,a)}l((i=i.apply(n,t||[])).next())})},Od=function(n,t){var i,r,s,o,e={label:0,sent:function(){if(1&s[0])throw s[1];return s[1]},trys:[],ops:[]};return o={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function a(h){return function(c){return function l(h){if(i)throw new TypeError("Generator is already executing.");for(;e;)try{if(i=1,r&&(s=2&h[0]?r.return:h[0]?r.throw||((s=r.return)&&s.call(r),0):r.next)&&!(s=s.call(r,h[1])).done)return s;switch(r=0,s&&(h=[2&h[0],s.value]),h[0]){case 0:case 1:s=h;break;case 4:return e.label++,{value:h[1],done:!1};case 5:e.label++,r=h[1],h=[0];continue;case 7:h=e.ops.pop(),e.trys.pop();continue;default:if(!(s=(s=e.trys).length>0&&s[s.length-1])&&(6===h[0]||2===h[0])){e=0;continue}if(3===h[0]&&(!s||h[1]>s[0]&&h[1]-1&&(r=i.fixedUserHandles[parseInt(o.toString(),10)]);this.commandHandler.triggerEvent(Ce.fixedUserHandleClick,{fixedUserHandle:r,element:e.source}),n.prototype.mouseUp.call(this,e)},t}(us),kd=function(n){function t(e,i){var r=n.call(this,e,!0)||this;return r.isConnected=!1,r.endPoint=i,r}return ds(t,n),t.prototype.mouseDown=function(e){return Nd(this,void 0,void 0,function(){var r,s,o,a,l;return Od(this,function(h){if(this.inAction=!0,this.undoElement=void 0,this instanceof pa||(this.undoElement=$(e.source)),n.prototype.mouseDown.call(this,e),e.source&&e.source.connectors&&(this.oldConnector=$(r=e.source.connectors[0])),"BezierSourceThumb"===this.endPoint||"BezierTargetThumb"===this.endPoint)for(s=0;s0))},t.prototype.endAction=function(){n.prototype.endAction.call(this),this.prevPosition=null,this.endPoint=null},t}(us),fa=function(n){function t(e,i){var r=n.call(this,e,!0)||this;return r.currentTarget=null,r.isStartAction=!1,r.canCancel=!1,r.canTrigger=!1,r.objectType=i,r}return ds(t,n),t.prototype.mouseDown=function(e){if(e.source instanceof te||e.source instanceof de){var i=this.commandHandler.getSelectedObject();this.commandHandler.selectObjects([e.source],e.info&&e.info.ctrlKey,i);var r={nodes:[],connectors:[]};e.source instanceof te?r.nodes.push($(e.source)):r.connectors.push($(e.source)),this.undoElement=$(r)}else this.undoElement=$(e.source);this.undoParentElement=this.commandHandler.getSubProcess(e.source),"Port"===this.objectType&&(this.portId=e.sourceWrapper.id),this.commandHandler.insertBlazorConnector(e.source),n.prototype.mouseDown.call(this,e),this.initialOffset={x:0,y:0}},t.prototype.mouseUp=function(e,i){return Nd(this,void 0,void 0,function(){var s,o,a,l,h,c,d,u,p,g,v,y,S,b,M;return Od(this,function(w){if(this.checkPropertyValue(),a=!1,h={nodes:[],connectors:[]},"Port"!==this.objectType){if(e.source instanceof te||e.source instanceof de?(e.source instanceof te?h.nodes.push($(e.source)):h.connectors.push($(e.source)),(o=$(h)).offsetX=(c=e.source.wrapper).offsetX,o.offsetY=c.offsetY):o=$(e.source),("helper"===(l=this.commandHandler.renderContainerHelper(e.source)||e.source||this.commandHandler.renderContainerHelper(e.source)).id||"helper"!==l.id)&&((l instanceof ei&&(Math.round(l.width)===Math.round(this.undoElement.width)&&Math.round(l.height)===Math.round(this.undoElement.height)||l.selectedObjects&&1===l.selectedObjects.length)||!(l instanceof ei))&&(l.offsetX!==this.undoElement.offsetX||l.offsetY!==this.undoElement.offsetY||l.sourcePoint!==this.undoElement.sourcePoint||l.targetPoint!==this.undoElement.targetPoint)||this.isSelectionHasConnector(l))&&(e.source&&(s={offsetX:e.source.wrapper.offsetX,offsetY:e.source.wrapper.offsetY}),g={source:e.source,state:"Completed",oldValue:this.intialValue,newValue:s,target:this.currentTarget,targetPosition:this.currentPosition,allowDrop:(g={source:e.source,state:"Completed",oldValue:this.intialValue,newValue:s,target:this.currentTarget,targetPosition:this.currentPosition,allowDrop:!0,cancel:!1}).allowDrop,cancel:g.cancel},d=!0,"helper"===l.id?this.canTrigger?(this.commandHandler.triggerEvent(Ce.positionChange,g),this.connectorEndPointChangeEvent(g),d=!0):d=!1:(this.commandHandler.triggerEvent(Ce.positionChange,g),this.connectorEndPointChangeEvent(g)),!i&&d&&(this.commandHandler.startGroupAction(),a=!0,M={type:"PositionChanged",redoObject:$(o),undoObject:$(this.undoElement),category:"Internal"},o.nodes[0]&&o.nodes[0].processId&&(u={type:"SizeChanged",category:"Internal",undoObject:this.undoParentElement,redoObject:this.commandHandler.getSubProcess(e.source)},this.commandHandler.addHistoryEntry(u)),this.commandHandler.addHistoryEntry(M))),this.commandHandler.snapPoint(this.prevPosition,this.currentPosition,0,0),this.commandHandler.removeSnap(),this.commandHandler.removeHighlighter(),e.source&&this.currentTarget&&FI(this.currentTarget)&&this.commandHandler.isDroppable(e.source,this.currentTarget)){if(p=!0,this.commandHandler.drop(this.currentElement,this.currentTarget,this.currentPosition),this.currentTarget&&this.currentTarget instanceof de&&!0===this.commandHandler.diagram.enableConnectorSplit)if(this.currentElement&&this.currentElement instanceof te){if(void 0!==this.currentElement.children)for(b=0;b0)for(var s=0;s0)for(var a=0;a0)for(a=0;a0&&e.connectors.length>0)||e.width===this.undoElement.width&&e.height===this.undoElement.height)},t.prototype.mouseMove=function(e){n.prototype.mouseMove.call(this,e);var r,s,i=!1;(r=this.commandHandler.renderContainerHelper(e.source)||e.source)instanceof te||r instanceof de?r instanceof te?r.offsetX===this.undoElement.nodes[0].offsetX&&r.offsetY===this.undoElement.nodes[0].offsetY&&(i=!0):R.equals(r.sourcePoint,this.undoElement.connectors[0].sourcePoint)&&R.equals(r.targetPoint,this.undoElement.connectors[0].targetPoint)&&(i=!0):r.wrapper.offsetX===this.undoElement.wrapper.offsetX&&r.wrapper.offsetY===this.undoElement.wrapper.offsetY&&(i=!0),r&&(s={offsetX:r.wrapper.offsetX,offsetY:r.wrapper.offsetY});var o={source:r,state:"Start",oldValue:s,newValue:s,target:e.target,targetPosition:e.position,allowDrop:!0,cancel:!1};if(o={source:r,state:"Start",oldValue:s,newValue:s,target:e.target,targetPosition:e.position,allowDrop:o.allowDrop,cancel:o.cancel},this.isStartAction||(this.intialValue={offsetX:r.wrapper.offsetX,offsetY:r.wrapper.offsetY}),i&&!ce()&&(this.commandHandler.triggerEvent(Ce.positionChange,o),this.connectorEndPointChangeEvent(o),this.isStartAction=!0),this.currentPosition=e.position,"Port"!==this.objectType){var h=this.initialOffset.x+(this.currentPosition.x-this.prevPosition.x),c=this.initialOffset.y+(this.currentPosition.y-this.prevPosition.y);this.commandHandler.dragOverElement(e,this.currentPosition),this.commandHandler.disConnect(e.source),this.commandHandler.removeSnap();var d,u=void 0,f=this.commandHandler.snapPoint(this.prevPosition,this.currentPosition,h,c);this.initialOffset.x=h-f.x,this.initialOffset.y=c-f.y,r&&(d={offsetX:r.wrapper.offsetX,offsetY:r.wrapper.offsetY},u={offsetX:r.wrapper.offsetX+f.x,offsetY:r.wrapper.offsetY+f.y}),this.currentTarget&&e.target!==this.currentTarget&&this.commandHandler.removeChildFromBPmn(e.source,e.target,this.currentTarget),this.currentTarget=e.target;var p={source:r,state:"Progress",oldValue:d,newValue:u,target:e.target,targetPosition:e.position,allowDrop:!0,cancel:!1};if(this.commandHandler.triggerEvent(Ce.positionChange,p),this.canTrigger=!0,this.connectorEndPointChangeEvent(p,f),!p.cancel&&!this.canCancel){this.blocked=!this.commandHandler.dragSelectedObjects(f.x,f.y);var g=!this.commandHandler.mouseOver(this.currentElement,this.currentTarget,this.currentPosition);this.blocked=this.blocked||g}if(this.commandHandler.removeStackHighlighter(),this.commandHandler.renderStackHighlighter(e),this.currentTarget&&e.source!==this.currentTarget&&this.commandHandler.isDroppable(e.source,this.currentTarget)&&"helper"!==e.source.id){var v=e.source instanceof ei?e.source.nodes[0]:e.source;!this.commandHandler.isParentAsContainer(v,!0)&&"SwimLane"!==v.shape.type&&!v.shape.isPhase&&(this.currentTarget.isLane?this.commandHandler.renderStackHighlighter(e,this.currentTarget):this.commandHandler.drawHighlighter(this.currentTarget))}else this.commandHandler.removeHighlighter();if(this.commandHandler.canEnableDefaultTooltip()){var y=this.getTooltipContent(e.source);this.commandHandler.showTooltip(e.source,e.position,ko(function(){return y}),"MoveTool",this.isTooltipVisible),this.isTooltipVisible=!1}}else{var b=Bi(),M=e.source;qi(b,-M.rotateAngle||-M.wrapper.rotateAngle,M.offsetX||M.wrapper.offsetX,M.offsetY||M.wrapper.offsetY);var w=Ke(b,{x:this.prevPosition.x,y:this.prevPosition.y}),C=Ke(b,{x:e.position.x,y:e.position.y});this.commandHandler.portDrag(e.source,e.sourceWrapper,C.x-w.x,C.y-w.y)}return this.prevPosition=this.currentPosition,!this.blocked},t.prototype.getTooltipContent=function(e){return"X:"+Math.round(e.wrapper.bounds.x)+" Y:"+Math.round(e.wrapper.bounds.y)},t.prototype.mouseLeave=function(e){this.mouseUp(e)},t.prototype.endAction=function(){n.prototype.endAction.call(this),this.currentTarget=null,this.prevPosition=null},t}(us),Xx=function(n){function t(e){var i=n.call(this,e,!0)||this;return i.rotateStart=!1,i}return ds(t,n),t.prototype.mouseDown=function(e){if(this.undoElement=$(e.source),this.undoElement.nodes[0]&&this.undoElement.nodes[0].children)for(var r=this.commandHandler.getAllDescendants(this.undoElement.nodes[0],[]),s=0;s=2){var s=e.startTouches[0],o=e.startTouches[1],a=e.moveTouches[0],l=e.moveTouches[1],h=this.getDistance(a,l)/this.getDistance(s,o);this.commandHandler.zoom(h,0,0,e.position),this.updateTouch(s,a),this.updateTouch(o,l)}}else this.commandHandler.scroll(this.currentPosition.x-this.prevPosition.x,this.currentPosition.y-this.prevPosition.y,this.currentPosition);return this.commandHandler.dataBinding(),!this.blocked},t.prototype.mouseUp=function(e){this.commandHandler.setBlazorDiagramProps(!1),this.checkPropertyValue(),this.commandHandler.updatePanState(!1),n.prototype.mouseUp.call(this,e),this.inAction=!1},t.prototype.endAction=function(){n.prototype.endAction.call(this)},t.prototype.getDistance=function(e,i){var r=i.pageX-e.pageX,s=i.pageY-e.pageY;return Math.sqrt(r*r+s*s)},t.prototype.updateTouch=function(e,i){e.pageX=i.pageX,e.pageY=i.pageY},t}(us),Une=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseUp=function(e){this.checkPropertyValue(),this.commandHandler.initExpand(e),n.prototype.mouseUp.call(this,e)},t}(us),eF=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseUp=function(e){this.checkPropertyValue();var i="_blank",r="",s=window.innerHeight,o=window.innerWidth,a=window.screenTop,l=window.screenLeft;"CurrentTab"===e.sourceWrapper.hyperlink.hyperlinkOpenState?i="_self":"NewWindow"===e.sourceWrapper.hyperlink.hyperlinkOpenState&&(r="height="+s+",width="+o+",top="+a+",left="+l),window.open(e.sourceWrapper.hyperlink.link,i,r).focus(),n.prototype.mouseUp.call(this,e)},t}(us),Rl=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseDown=function(e){if(n.prototype.mouseDown.call(this,e),this.inAction=!0,this.drawingObject){var r=void 0,s=this.drawingObject.shape;this.drawingObject.shape.points.push(r={x:(r=s.points[s.points.length-1]).x,y:r.y})}else{this.startPoint={x:this.startPosition.x,y:this.startPosition.y};var i={offsetX:this.currentPosition.x,offsetY:this.currentPosition.y,width:5,height:5,shape:{type:"Basic",shape:"Polygon",points:[{x:this.startPoint.x,y:this.startPoint.y},{x:this.currentPosition.x,y:this.currentPosition.y}]}};this.triggerElementDrawEvent(e.source,"Start","Node",this.getShapeType(),!0),this.drawingObject=this.commandHandler.drawObject(i)}},t.prototype.mouseMove=function(e){if(n.prototype.mouseMove.call(this,e),this.inAction){var i=this.drawingObject.shape;if(i.points[i.points.length-1].x=this.currentPosition.x,i.points[i.points.length-1].y=this.currentPosition.y,this.drawingObject.wrapper.children[0].data=Sx(this.drawingObject.shape.points),this.triggerElementDrawEvent(this.drawingObject,"Progress","Node",this.getShapeType(),!1),this.inAction&&!1===R.equals(this.currentPosition,this.prevPosition)){var r=Ne.toBounds(this.drawingObject.shape.points);this.commandHandler.updateNodeDimension(this.drawingObject,r)}}return!0},t.prototype.mouseUp=function(e,i){this.checkPropertyValue(),n.prototype.mouseMove.call(this,e),this.inAction&&(this.inAction=!1,this.commandHandler.addObjectToDiagram(this.drawingObject),this.triggerElementDrawEvent(this.drawingObject,"Completed","Node",this.getShapeType(),!1)),this.endAction()},t.prototype.mouseWheel=function(e){n.prototype.mouseWheel.call(this,e),this.mouseMove(e)},t.prototype.endAction=function(){this.inAction=!1,this.drawingObject=null},t}(us),Hl=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseMove=function(e){if(n.prototype.mouseMove.call(this,e),this.inAction){var i=this.drawingObject;i.targetPoint=this.currentPosition,this.triggerElementDrawEvent(this.drawingObject,"Progress","Connector",this.drawingObject.type,!1),this.commandHandler.updateConnectorPoints(i)}return!0},t.prototype.mouseDown=function(e){if(n.prototype.mouseDown.call(this,e),this.inAction=!0,this.drawingObject){var r=this.drawingObject,s=void 0;(s=new Bl(r,"segments",{type:"Straight"},!0)).point=this.currentPosition,r.segments[r.segments.length-1]=s}else{var i={id:"Connector",type:"Straight",sourcePoint:this.currentPosition,targetPoint:this.currentPosition};this.triggerElementDrawEvent(e.source,"Start","Connector",this.commandHandler.diagram.drawingObject.type,!0),this.inAction&&(this.drawingObject=this.commandHandler.drawObject(i))}},t.prototype.mouseWheel=function(e){n.prototype.mouseWheel.call(this,e),this.mouseMove(e)},t.prototype.mouseUp=function(e){if(this.checkPropertyValue(),n.prototype.mouseMove.call(this,e),this.inAction&&this.drawingObject){var i=this.drawingObject;i.segments[i.segments.length-1].point={x:0,y:0},this.commandHandler.addObjectToDiagram(this.drawingObject),this.triggerElementDrawEvent(this.drawingObject,"Completed","Connector",this.drawingObject.type,!1)}this.endAction()},t.prototype.endAction=function(){this.drawingObject=null,this.inAction=!1},t}(us),jne=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseDown=function(e){this.inAction=!0,this.undoElement=$(e.source),this.annotationId=e.sourceWrapper.id,n.prototype.mouseDown.call(this,e)},t.prototype.mouseMove=function(e){n.prototype.mouseMove.call(this,e);var i=this.currentPosition.x-this.prevPosition.x,r=this.currentPosition.y-this.prevPosition.y,s=e.source;if(s instanceof te){var o=Bi();qi(o,-s.rotateAngle,0,0);var a=Ke(o,{x:i,y:r});i=a.x,r=a.y}return this.inAction&&(this.commandHandler.labelDrag(e.source,e.sourceWrapper,i,r),this.commandHandler.updateSelector()),this.prevPosition=this.currentPosition,!this.blocked},t.prototype.mouseUp=function(e){this.checkPropertyValue();var i=e.source;this.inAction=!1;var r={type:"AnnotationPropertyChanged",objectId:this.annotationId,undoObject:$(this.undoElement),category:"Internal",redoObject:$(i)};this.commandHandler.addHistoryEntry(r),n.prototype.mouseUp.call(this,e)},t.prototype.mouseLeave=function(e){this.mouseUp(e)},t}(us),Vne=function(n){function t(e,i){var r=n.call(this,e,!0)||this;return r.corner=i,r}return ds(t,n),t.prototype.mouseDown=function(e){this.inAction=!0;var i=e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0];this.annotationId=e.source.wrapper.children[0].id,this.undoElement=$(i);var r=e.source.wrapper.children[0];this.initialBounds={x:r.offsetX,y:r.offsetY,width:r.actualSize.width,height:r.actualSize.height},n.prototype.mouseDown.call(this,e)},t.prototype.mouseMove=function(e){return n.prototype.mouseMove.call(this,e),this.inAction&&this.resizeObject(e),!this.blocked},t.prototype.mouseUp=function(e){this.checkPropertyValue();var i=e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0];this.inAction=!1;var r={type:"AnnotationPropertyChanged",objectId:this.annotationId,redoObject:$(i),undoObject:$(this.undoElement),category:"Internal"};this.commandHandler.addHistoryEntry(r),n.prototype.mouseUp.call(this,e)},t.prototype.mouseLeave=function(e){this.mouseUp(e)},t.prototype.resizeObject=function(e){var i,s,o,r=e.source.wrapper.children[0],a={x:r.offsetX,y:r.offsetY},l=r.rotateAngle;l=((l+=(i=e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0])instanceof te?i.rotateAngle:0)+360)%360;var h=Bi();qi(h,l,a.x,a.y);var c=this.corner.slice(5),d=this.updateSize(r,this.startPosition,this.currentPosition,c,this.initialBounds,l),u=r.offsetX-r.actualSize.width*r.pivot.x,f=r.offsetY-r.actualSize.height*r.pivot.y,p=this.getPivot(c),g=Ke(h,p={x:u+r.actualSize.width*p.x,y:f+r.actualSize.height*p.y});d.x=g.x,d.y=g.y,this.commandHandler.labelResize(i,e.source.annotation,s=(s=d.width)<0?1:s,o=(o=d.height)<0?1:o,d,e.source),this.commandHandler.updateSelector()},t}(us),Wne=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseDown=function(e){this.inAction=!0,this.annotationId=e.source.wrapper.children[0].id,this.undoElement=$(e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0]),n.prototype.mouseDown.call(this,e)},t.prototype.mouseMove=function(e){return n.prototype.mouseMove.call(this,e),e.source&&this.inAction&&(this.commandHandler.labelRotate(e.source.nodes[0]?e.source.nodes[0]:e.source.connectors[0],e.source.annotation,this.currentPosition,e.source),this.commandHandler.updateSelector()),this.prevPosition=this.currentPosition,!this.blocked},t.prototype.mouseUp=function(e){this.checkPropertyValue(),this.inAction=!1;var r={type:"AnnotationPropertyChanged",objectId:this.annotationId,redoObject:$(e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0]),undoObject:$(this.undoElement),category:"Internal"};this.commandHandler.addHistoryEntry(r),n.prototype.mouseUp.call(this,e)},t.prototype.mouseLeave=function(e){this.mouseUp(e)},t}(us),Yne=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseMove=function(e){if(n.prototype.mouseMove.call(this,e),this.inAction){var i=this.drawingObject.shape;if(i.points.push(this.currentPosition),this.drawingObject.wrapper.children[0].data=Ix(this.drawingObject.shape.points),i.data=Ix(i.points),this.triggerElementDrawEvent(e.source,"Progress","Connector",this.drawingObject.type,!1),this.inAction&&!1===R.equals(this.currentPosition,this.prevPosition)){var s=Ne.toBounds(this.drawingObject.shape.points);this.commandHandler.updateNodeDimension(this.drawingObject,s)}}return!0},t.prototype.mouseDown=function(e){n.prototype.mouseDown.call(this,e),this.inAction=!0,this.startPoint={x:this.startPosition.x,y:this.startPosition.y};var i={offsetX:this.currentPosition.x,offsetY:this.currentPosition.y,width:5,height:5,style:{strokeColor:"black",strokeWidth:1,fill:"transparent"},shape:{type:"Path",points:[{x:this.startPoint.x,y:this.startPoint.y},{x:this.currentPosition.x,y:this.currentPosition.y}]}};this.triggerElementDrawEvent(e.source,"Start","Connector",this.commandHandler.diagram.drawingObject.type,!0),this.drawingObject=this.commandHandler.drawObject(i)},t.prototype.mouseUp=function(e){if(this.checkPropertyValue(),this.inAction){this.inAction=!1;var s=this.drawingObject.shape,o=s.points;this.commandHandler.addObjectToDiagram(this.drawingObject),this.commandHandler.diagram.remove(this.commandHandler.diagram.nameTable[""+this.drawingObject.id]),o=this.pointReduction(o,10);var h={id:"newConnector"+Qe(),type:"Bezier",sourcePoint:{x:o[0].x,y:o[0].y},targetPoint:{x:o[o.length-1].x,y:o[o.length-1].y},segments:[],bezierSettings:{allowSegmentsReset:!1}};this.drawingObject=this.commandHandler.drawObject(h),this.drawingObject=this.bezierCurveSmoothness(o,.5,this.drawingObject,s),this.commandHandler.updateConnectorPoints(this.drawingObject),this.commandHandler.addObjectToDiagram(this.drawingObject),this.triggerElementDrawEvent(this.drawingObject,"Completed","Connector",this.drawingObject.type,!1),n.prototype.mouseUp.call(this,e)}},t.prototype.pointReduction=function(e,i){if(null===e||e.length<3)return e;var s=e.length-1,o=[];for(o.push(0),o.push(s);e[parseInt((0).toString(),10)]===e[parseInt(s.toString(),10)];)s--;this.reduction(e,0,s,i,o);var a=[];return o.sort(function(l,h){return l-h}),o.forEach(function(l){a.push(e[parseInt(l.toString(),10)])}),a},t.prototype.reduction=function(e,i,r,s,o){for(var a=0,l=0,h=i;ha&&(a=c,l=h)}a>s&&0!==l&&(o.push(l),this.reduction(e,i,l,s,o),this.reduction(e,l,r,s,o))},t.prototype.perpendicularDistance=function(e,i,r){return Math.abs(.5*(e.x*i.y-i.x*e.y+(i.x*r.y-r.x*i.y)+(r.x*e.y-e.x*r.y)))/Math.sqrt(Math.pow(e.x-i.x,2)+Math.pow(e.y-i.y,2))*2},t.prototype.bezierCurveSmoothness=function(e,i,r,s){if(e.length<3)return r;for(var o=0;o=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Qne=function(n){if(n)switch(n.type){case"Bpmn":return $ne;case"UmlActivity":return qne;case"UmlClassifier":return Kne;default:return tm}return tm},Gne=function(n){if(n)switch(n.type){case"Straight":default:return Bl;case"Bezier":return fs;case"Orthogonal":return wi}},tF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I(10)],t.prototype,"width",void 0),Pe([I(10)],t.prototype,"height",void 0),Pe([I("Arrow")],t.prototype,"shape",void 0),Pe([re({fill:"black",strokeColor:"black",strokeWidth:1},Nl)],t.prototype,"style",void 0),Pe([re({x:0,y:.5},R)],t.prototype,"pivot",void 0),Pe([I("")],t.prototype,"pathData",void 0),t}(Ee),ZI=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I(0)],t.prototype,"angle",void 0),Pe([I(0)],t.prototype,"distance",void 0),t}(Ee),Xne=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I(Cx.All)],t.prototype,"controlPointsVisibility",void 0),Pe([I("FreeForm")],t.prototype,"segmentEditOrientation",void 0),Pe([I(CI.Default)],t.prototype,"smoothness",void 0),Pe([I(!0)],t.prototype,"allowSegmentsReset",void 0),t}(Ee),tm=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I("None")],t.prototype,"type",void 0),t}(Ee),qne=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I("Object")],t.prototype,"flow",void 0),Pe([I(30)],t.prototype,"exceptionFlowHeight",void 0),t}(tm),$ne=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I("Sequence")],t.prototype,"flow",void 0),Pe([I("Normal")],t.prototype,"sequence",void 0),Pe([I("Default")],t.prototype,"message",void 0),Pe([I("Default")],t.prototype,"association",void 0),t}(tm),iF=function(n){function t(e,i,r,s){var o=n.call(this,e,i,r,s)||this;return o.points=[],o}return Qs(t,n),Pe([I("Straight")],t.prototype,"type",void 0),Pe([I(!0)],t.prototype,"allowDrag",void 0),t}(Ee),Bl=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),t.prototype.getClassName=function(){return"StraightSegment"},Pe([re({x:0,y:0},R)],t.prototype,"point",void 0),t}(iF),fs=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),t.prototype.getClassName=function(){return"BezierSegment"},t.prototype.getPoints=function(e,i){var r=[];if(r.length>0||null!=i){var o=this.bezireToPoly(r.length>0?r[r.length-1]:i,e);r.push.apply(r,o)}return r},t.prototype.bezireToPoly=function(e,i){var r=[];return i&&this.flattenCubicBezier(r,e,i.bezierPoint1,i.bezierPoint2,{x:i.points[1].x,y:i.points[1].y},10),r},t.prototype.flattenCubicBezier=function(e,i,r,s,o,a){var h,l=(R.findLength(i,r)+R.findLength(r,s)+R.findLength(s,o))/a;for(h=0;h<=l;h++){var c=h/l;e.push({x:(1-c)*(1-c)*(1-c)*i.x+3*c*(1-c)*(1-c)*r.x+3*c*c*(1-c)*s.x+c*c*c*o.x,y:(1-c)*(1-c)*(1-c)*i.y+3*c*(1-c)*(1-c)*r.y+3*c*c*(1-c)*s.y+c*c*c*o.y})}},Pe([I("Horizontal")],t.prototype,"orientation",void 0),Pe([re({x:0,y:0},R)],t.prototype,"point1",void 0),Pe([re({x:0,y:0},R)],t.prototype,"point2",void 0),Pe([re({angle:0,distance:0},ZI)],t.prototype,"vector1",void 0),Pe([re({angle:0,distance:0},ZI)],t.prototype,"vector2",void 0),t}(Bl),wi=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),t.prototype.getClassName=function(){return"OrthogonalSegment"},Pe([I(null)],t.prototype,"length",void 0),Pe([I(null)],t.prototype,"direction",void 0),t}(iF);function rF(n,t,e){var s=e?45:180/(2+2/(n.height/n.width)),o=s,a=180-s,l=a+2*s,h=360-s,c=Gt(t,n.center);return c>o&&ca&&cl&&cMath.abs(t.y-n.y)?n.x=c)return s=R.findAngle(n[parseInt(d.toString(),10)],n[d+1]),{point:r=R.transform(n[parseInt(d.toString(),10)],s,c-(a||0)),index:l=d};a=o[parseInt(d.toString(),10)]}return{point:r,index:l}}(n,t),r=R.findAngle(n[i.index],n[i.index+1]),s=function xse(n){var e=0;switch(n.alignment){case"Center":case"After":e=0;break;case"Before":e=-0}return e}(t),o=R.transform(i.point,r+45,s);return i.point=o,i.angle=r,i}(i,e),h=l.point;s.id=this.id+"_"+e.id;var c=e.style;s.style={fill:c.fill,strokeColor:c.strokeColor,gradient:null,opacity:c.opacity,strokeDashArray:c.strokeDashArray,strokeWidth:c.strokeWidth},0===r.width&&(r.width=this.style.strokeWidth),0===r.height&&(r.height=this.style.strokeWidth);var d_y=(h.y-r.y)/r.height;a.x=r.width*((h.x-r.x)/r.width),a.y=r.height*d_y;var g,v,u=SF(e,l.angle,i),f=u.hAlign,p=u.vAlign;return"left"===f?(g="Left",a.x+=e.displacement.x):"right"===f?(g="Right",a.x-=e.displacement.x):"center"===f&&(g="Center"),"top"===p?(v="Top",a.y+=e.displacement.y):"bottom"===p?(v="Bottom",a.y-=e.displacement.y):"center"===p&&(v="Center"),s.horizontalAlignment=g,s.verticalAlignment=v,(s=nm(s,o&&"Label"!==o.flipMode&&"None"!==o.flipMode?this.flip:"None",e)).float=!0,s.connectionDirection=e.connectionDirection,s.setOffsetWithRespectToBounds(a.x,a.y,"Absolute"),s.relativeMode="Point",s.visible=!(!va(e,ci.Visible)||va(e,ci.Hover)||va(e,ci.Connect)),s.elementActions=s.elementActions|Xr.ElementIsPort,s},t.prototype.getConnectorRelation=function(){var e=this.shape;"Association"===e.relationship?(this.segments[0].type="Straight",this.sourceDecorator.shape="None",this.targetDecorator.shape="Arrow"):"Inheritance"===e.relationship?(this.segments[0].type="Orthogonal",this.sourceDecorator.shape="None",this.targetDecorator.shape="Arrow"):"Composition"===e.relationship||"Aggregation"===e.relationship?(this.segments[0].type="Orthogonal",this.sourceDecorator.shape="Diamond",this.targetDecorator.shape="None"):"Dependency"===e.relationship?(this.segments[0].type="Orthogonal",this.sourceDecorator.shape="None",this.targetDecorator.shape="OpenArrow"):"Realization"===e.relationship&&(this.segments[0].type="Orthogonal",this.sourceDecorator.shape="None",this.targetDecorator.shape="Arrow"),"BiDirectional"===e.associationType&&(this.sourceDecorator.shape="None",this.targetDecorator.shape="None");var i,o,r="",s="";e.multiplicity.source&&(e.multiplicity.source.lowerBounds=e.multiplicity.source.lowerBounds,e.multiplicity.source.upperBounds=e.multiplicity.source.upperBounds),e.multiplicity.target&&(e.multiplicity.target.lowerBounds=e.multiplicity.target.lowerBounds,e.multiplicity.target.upperBounds=e.multiplicity.target.upperBounds);var a=e.multiplicity.source,l=e.multiplicity.target;o=a.upperBounds?a.lowerBounds+"..."+a.upperBounds:a.lowerBounds,i=l.upperBounds?l.lowerBounds+"..."+l.upperBounds:l.lowerBounds,"ManyToOne"===e.multiplicity.type&&(e.multiplicity.target.optional=!1,r=o||"*",s="1"),"OneToMany"===e.multiplicity.type&&(e.multiplicity.source.optional=!1,s=i||"*",r="1"),"ManyToMany"===e.multiplicity.type&&(r=o||"*",s=i||"*"),"OneToOne"===e.multiplicity.type&&(e.multiplicity.target.optional=!1,e.multiplicity.source.optional=!1,r="1",s="1"),this.annotations=[{id:this.id+"sourcelabel",content:r,offset:0,alignment:"Before",margin:{right:5,bottom:5}},{id:this.id+"targetlabel",content:s,offset:1,alignment:"Before",margin:{right:5,bottom:5}}]},t.prototype.getBpmnSequenceFlow=function(){var e=new Ze,i=new Ze;return"Normal"===this.shape.sequence&&"Bezier"!==this.type&&(this.targetDecorator.shape="Arrow"),"Default"===this.shape.sequence&&(e=this.getSegmentElement(this,e),i=DF(this.intermediatePoints,this),this.targetDecorator.shape="Arrow"),"Conditional"===this.shape.sequence&&(this.targetDecorator.shape="Arrow",this.sourceDecorator.shape="Diamond",i.id=this.id+this.shape.type),i},t.prototype.getUMLObjectFlow=function(){if(this.annotations)for(var e=0;e0&&(this.sourcePoint=o[0],this.targetPoint=o[o.length-1]),o},t.prototype.clipDecorator=function(e,i,r,s){var a,l,o={x:0,y:0},h=i.length,c=R.distancePoints(a=r?i[0]:i[h-1],l=r?i[1]:i[h-2]);c=0===c?1:c;var d=1,u=r?e.sourceWrapper:e.targetWrapper;u&&(d=u.style.strokeWidth,s&&s&ee.DecoratorPropertyChange&&(d=1));var f=d-1;return o.x=Math.round(a.x+f*(l.x-a.x)/c),o.y=Math.round(a.y+f*(l.y-a.y)/c),(r&&"None"!==e.sourceDecorator.shape||!r&&"None"!==e.targetDecorator.shape)&&(o=R.adjustPoint(o,l,!0,s&ee.DecoratorPropertyChange?0:d/2)),o},t.prototype.clipDecorators=function(e,i,r){return"None"!==e.sourceDecorator.shape&&(i[0]=this.clipDecorator(e,i,!0,r)),"None"!==e.targetDecorator.shape&&(i[i.length-1]=this.clipDecorator(e,i,!1,r)),i},t.prototype.updateSegmentElement=function(e,i,r,s){var o=new Ne,a=this.getSegmentPath(e,i,s);if("Bezier"===e.type){if(this.segments.length>0)for(var l=0;l0)if("Straight"===e.type&&e.segments.length<2)for(var o=0;o1)for(o=0;o0&&"Bezier"!==this.type)for(var f=0;f0&&(a=f0&&(p<2*this.cornerRadius?(l=R.adjustPoint(h[parseInt(f.toString(),10)],h[f+1],!0,p/2),f0&&(s=this.bridgePath(e,s,f),"Orthogonal"===e.type&&(s=this.bridgePath(e,s,f+1))),s+=" L"+a.x+" "+a.y))}else if("Bezier"===this.type){var g=void 0,v=void 0;if(this.parentObj.element){var y=this.parentObj.element.ej2_instances[0].eventHandler.action;g=this.parentObj.element.ej2_instances[0].eventHandler.tool instanceof Pd,v=y.includes("PortDraw")||y.includes("Drag")}for(var S=void 0,b=this.segments,M=0;M2&&(b[parseInt(M.toString(),10)].bezierPoint1={x:0,y:0},b[parseInt(M.toString(),10)].bezierPoint2={x:0,y:0}),!R.isEmptyPoint(b[parseInt(M.toString(),10)].point1)||b[parseInt(M.toString(),10)].vector1.angle||b[parseInt(M.toString(),10)].vector1.distance?b[parseInt(M.toString(),10)].vector1.angle||b[parseInt(M.toString(),10)].vector1.distance?b[parseInt(M.toString(),10)].bezierPoint1=R.transform(h[parseInt(M.toString(),10)],b[parseInt(M.toString(),10)].vector1.angle,b[parseInt(M.toString(),10)].vector1.distance):b[parseInt(M.toString(),10)].bezierPoint1={x:b[parseInt(M.toString(),10)].point1.x||b[parseInt(M.toString(),10)].bezierPoint1.x,y:b[parseInt(M.toString(),10)].point1.y||b[parseInt(M.toString(),10)].bezierPoint1.y}:((e.sourceID||this.sourcePortID)&&this.sourceWrapper&&!v&&!g&&(S=rF(this.sourceWrapper.bounds,h[parseInt(M.toString(),10)],!0)),b[parseInt(M.toString(),10)].bezierPoint1=KI(h[parseInt(M.toString(),10)],h[M+1],S)),!R.isEmptyPoint(b[parseInt(M.toString(),10)].point2)||b[parseInt(M.toString(),10)].vector2.angle||b[parseInt(M.toString(),10)].vector2.distance?b[parseInt(M.toString(),10)].vector2.angle||b[parseInt(M.toString(),10)].vector2.distance?b[parseInt(M.toString(),10)].bezierPoint2=R.transform(h[M+1],b[parseInt(M.toString(),10)].vector2.angle,b[parseInt(M.toString(),10)].vector2.distance):b[parseInt(M.toString(),10)].bezierPoint2={x:b[parseInt(M.toString(),10)].point2.x||b[parseInt(M.toString(),10)].bezierPoint2.x,y:b[parseInt(M.toString(),10)].point2.y||b[parseInt(M.toString(),10)].bezierPoint2.y}:((e.targetID||this.targetPortID)&&this.targetWrapper&&!v&&!g&&(S=rF(this.targetWrapper.bounds,h[M+1],!0)),b[parseInt(M.toString(),10)].bezierPoint2=KI(h[M+1],h[parseInt(M.toString(),10)],S));h.splice(1,0,{x:b[0].bezierPoint1.x,y:b[0].bezierPoint1.y}),h.splice(h.length-1,0,{x:b[b.length-1].bezierPoint2.x,y:b[b.length-1].bezierPoint2.y}),h=this.clipDecorators(e,h,r);for(var w=0;w0&&(s=this.bridgePath(e,s,D),s+=" L"+o.x+" "+o.y);return s},t.prototype.updateShapeElement=function(e){var i;switch(e.shape.type){case"Bpmn":e.wrapper.children[3]instanceof Ze&&(i=e.wrapper.children[3]),"Message"===e.shape.flow&&this.updateShapePosition(e,i);break;case"UmlActivity":"Exception"===e.shape.flow&&this.getUMLExceptionFlow(e.wrapper.children[0])}},t.prototype.updateShapePosition=function(e,i){var o=xF(this.intermediatePoints,i,.5);i.offsetX=o.x,i.offsetY=o.y},t.prototype.scale=function(e,i,r,s,o){var a=0,l=0;if(this.wrapper&&this.wrapper.outerBounds){var h=function T3(n){var t=n.wrapper.children[0].bounds;return"None"!==n.sourceDecorator.shape&&t.uniteRect(n.wrapper.children[1].bounds),"None"!==n.targetDecorator.shape&&t.uniteRect(n.wrapper.children[2].bounds),t}(this),c=Math.abs((this.wrapper.bounds.width||this.style.strokeWidth||1)-2),d=Math.abs((this.wrapper.bounds.height||this.style.strokeWidth||1)-2);a=h.width-c,l=h.height-d,e=Math.abs((r-Math.max(a,l))/c),i=Math.abs((s-Math.max(a,l))/d),a=l=Math.min(a,l)}e=i=Math.min(e,i);var u=Bi();qi(u,-(o=o||this.wrapper).rotateAngle,o.offsetX,o.offsetY),Gf(u,e,i,o.offsetX,o.offsetY),qi(u,o.rotateAngle,o.offsetX,o.offsetY);var f=function Uie(n,t){for(var e=[],i=0,r=t;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},tse=function(n){function t(e,i){var r=n.call(this,e,i)||this;return r.offset=0,r.scale=1,r}return ese(t,n),t.prototype.preRender=function(){this.unWireEvents(),this.wireEvents()},t.prototype.render=function(){this.updateRulerGeometry(),this.renderComplete()},t.prototype.getModuleName=function(){return"Ruler"},t.prototype.destroy=function(){this.unWireEvents(),this.notify("destroy",{}),n.prototype.destroy.call(this),this.element.classList.remove("e-ruler")},t.prototype.getPersistData=function(){return this.addOnPersist(["loaded"])},t.prototype.onPropertyChanged=function(e,i){for(var r=0,s=Object.keys(e);r100;)r/=10,s/=10;for(;s<25;)r*=10,s*=10;return s>=25&&s%25!=0&&(s=25*Math.round(s/25)),s*e/r},t.prototype.createMarkerLine=function(e,i,r){var s;return i&&((s=e.getElementById(i.id+"_marker"))&&s.parentNode.removeChild(s),s=Fi("line",r)),s},t.prototype.drawRulerMarker=function(e,i,r){var s,o,h,d,u="Horizontal"===this.orientation,f=e.getElementsByTagName("svg");for(h=0;h0)for(var a=i.childNodes.length-1;a>=0;a--)i.childNodes[parseInt(a.toString(),10)].parentNode.removeChild(i.childNodes[parseInt(a.toString(),10)]);i.appendChild(s)}return s},t.prototype.wireEvents=function(){},t.prototype.unWireEvents=function(){},kc([I(5)],t.prototype,"interval",void 0),kc([I(100)],t.prototype,"segmentWidth",void 0),kc([I("Horizontal")],t.prototype,"orientation",void 0),kc([I("RightOrBottom")],t.prototype,"tickAlignment",void 0),kc([I("red")],t.prototype,"markerColor",void 0),kc([I(25)],t.prototype,"thickness",void 0),kc([I(null)],t.prototype,"arrangeTick",void 0),kc([I(400)],t.prototype,"length",void 0),t}(Ii);function oF(n,t){var e=document.getElementById(n.element.id+(t?"_hRuler":"_vRuler")),i=Za(n),r=aF(n);e||(e=Tt("div",{id:n.element.id+(t?"_hRuler":"_vRuler"),style:"height:"+(t?i.height:r.height+100)+"px;overflow:hidden;width:"+(t?r.width+100:i.width)+"px;position:absolute;font-size:11px;"+(t?"margin-left:"+i.width+"px;":"margin-top:"+i.height+"px;")})),n.element.insertBefore(e,n.element.firstChild);var l=t?n.rulerSettings.horizontalRuler:n.rulerSettings.verticalRuler,h=new tse(l);h.orientation=t?"Horizontal":"Vertical",h.length=(t?r.width:r.height)+l.segmentWidth,h.appendTo("#"+n.element.id+(t?"_hRuler":"_vRuler")),t?n.hRuler=h:n.vRuler=h;var c=document.getElementById(n.element.id+(t?"_hRuler":"_vRuler"));t?n.hRuler.element=c:n.vRuler.element=c}function eb(n){var t=-n.scroller.horizontalOffset,e=-n.scroller.verticalOffset;n&&n.rulerSettings.showRulers?(n.hRuler.length=0,n.vRuler.length=0,void 0!==t&&n.hRuler.element&&lF(n,n.hRuler,t,!0),void 0!==e&&n.vRuler.element&&lF(n,n.vRuler,e,!1)):qx(n)}function qx(n){an(n.element.id+"_hRuler"),an(n.element.id+"_vRuler"),an(n.element.id+"_overlapRuler")}function Za(n){var t=0,e=0;return n.rulerSettings.showRulers&&(t=n.rulerSettings.horizontalRuler.thickness,e=n.rulerSettings.verticalRuler.thickness),new me(e,t)}function aF(n){var t=Za(n),e=n.scroller.viewPortHeight,i=n.scroller.viewPortWidth;return i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},hF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return ase(t,n),t.prototype.getClassName=function(){return"UserHandle"},Un([I("")],t.prototype,"name",void 0),Un([I("")],t.prototype,"pathData",void 0),Un([I("")],t.prototype,"content",void 0),Un([I("")],t.prototype,"source",void 0),Un([I("#000000")],t.prototype,"backgroundColor",void 0),Un([I("Top")],t.prototype,"side",void 0),Un([I("")],t.prototype,"borderColor",void 0),Un([I(.5)],t.prototype,"borderWidth",void 0),Un([I(25)],t.prototype,"size",void 0),Un([I("white")],t.prototype,"pathColor",void 0),Un([I(10)],t.prototype,"displacement",void 0),Un([I(!0)],t.prototype,"visible",void 0),Un([I(0)],t.prototype,"offset",void 0),Un([re({},Jn)],t.prototype,"margin",void 0),Un([I("Center")],t.prototype,"horizontalAlignment",void 0),Un([I("Center")],t.prototype,"verticalAlignment",void 0),Un([I(!1)],t.prototype,"disableNodes",void 0),Un([I(!1)],t.prototype,"disableConnectors",void 0),Un([re({},Dd)],t.prototype,"tooltip",void 0),Un([I("")],t.prototype,"template",void 0),t}(Ee);function cF(n){return lse[n.toString()]}var lse={Action:"M 90 82.895 C 90 86.819 86.776 90 82.8 90 H 7.2 C 3.224 90 0 86.819 0 82.895 V 7.105 C 0 3.181 3.224 0 7.2 0 h 75.6 C 86.776 0 90 3.181 90 7.105 V 82.895 Z",Decision:"M10,19.707L0.293,10L10,0.293L19.707,10L10,19.707z",MergeNode:"M10,19.707L0.293,10L10,0.293L19.707,10L10,19.707z",InitialNode:"M10,19.5c-5.238,0-9.5-4.262-9.5-9.5S4.762,0.5,10,0.5s9.5,4.262,9.5,9.5S15.238,19.5,10,19.5z",ForkNode:"m0.75,0.75l636.00002,0l0,290l-636.00002,0l0,-290z",JoinNode:"m0.75,0.75l636.00002,0l0,290l-636.00002,0l0,-290z",TimeEvent:"M50.001,0.00286865 L25.001,25.0029 L0.000976562,0.00286865 L50.001,0.00286865 z M0.000976562,50.0029 L25.001,25.0029 L50.001,50.0029 L0.000976562,50.0029 z",AcceptingEvent:"M17.8336 32.164 L29.64 24 L17.32 16 L48.1664 16 L48.5 32 Z",SendSignal:"M48.164 31.8336 L56 23.832 L47.836 16 L16.168 16 L16.1668 31.8336 Z",ReceiveSignal:"M48.1664 31.8336 L39.836 24 L47.836 16 L16.168 16 L16.168 31.836 Z",StructuredNode:"M0,0 L50,0 L50,50 L0,50 z",Note:"M20 12 L4 12 L4 22 L22 22 L22 14 L20 14 L20 12 L22 14 Z"},tb=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Ja=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},hse=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return tb(t,n),Ja([I()],t.prototype,"key",void 0),Ja([I()],t.prototype,"keyModifiers",void 0),t}(Ee),dF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return tb(t,n),t.prototype.getClassName=function(){return"Command"},Ja([I("")],t.prototype,"name",void 0),Ja([I()],t.prototype,"canExecute",void 0),Ja([I()],t.prototype,"execute",void 0),Ja([re({},hse)],t.prototype,"gesture",void 0),Ja([I("")],t.prototype,"parameter",void 0),t}(Ee),cse=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return tb(t,n),Ja([Bt([],dF)],t.prototype,"commands",void 0),t}(Ee),dse=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return tb(t,n),Ja([I()],t.prototype,"show",void 0),Ja([I()],t.prototype,"showCustomMenuOnly",void 0),Ja([I()],t.prototype,"items",void 0),t}(Ee),Jf=function(){function n(){}return n.prototype.renderShadow=function(t,e,i,r){void 0===i&&(i=null);var l,o=R.transform({x:0,y:0},t.shadow.angle,t.shadow.distance);r&&(l=r.getElementById(e.id+"_shadow")),l||(l=document.createElementNS("http://www.w3.org/2000/svg",i?"path":"rect"),e.appendChild(l));var h={id:e.id+"_shadow",fill:t.shadow.color,stroke:t.shadow.color,opacity:t.shadow.opacity.toString(),transform:"rotate("+t.angle+","+(t.x+t.width*t.pivotX)+","+(t.y+t.height*t.pivotY)+")translate("+(t.x+o.x)+","+(t.y+o.y)+")"};if(r){var c=r.getElementById(e.id);c&&c.insertBefore(l,c.firstChild)}ti(l,h),i?i&&this.renderPath(l,t,i):ti(l,{width:t.width,height:t.height})},n.prototype.parseDashArray=function(t){return[]},n.prototype.drawRectangle=function(t,e,i,r,s,o,a,l,h){var c,d,u,f;e.shadow&&!r&&this.renderShadow(e,t,void 0,o),c=e.id===t.id?e.id+"_container":e.id,o&&(d=o.getElementById(c)),(!d||s)&&(d=document.createElementNS("http://www.w3.org/2000/svg","rect"),t.appendChild(d)),o&&!e.shadow&&(u=o.getElementById(e.id+"_groupElement_shadow"))&&u.parentNode.removeChild(u),f=l?{id:c,x:e.x.toString(),y:e.y.toString(),width:e.width.toString(),height:e.height.toString(),visibility:e.visible?"visible":"hidden",transform:"rotate("+e.angle+","+(e.x+e.width/2)+","+(e.y+e.height/2)+")",rx:e.cornerRadius||0,ry:e.cornerRadius||0,opacity:e.opacity}:{id:c,x:e.x.toString(),y:e.y.toString(),width:e.width.toString(),height:e.height.toString(),visibility:e.visible?"visible":"hidden",transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")",rx:e.cornerRadius||0,ry:e.cornerRadius||0,opacity:e.opacity},a&&(f.role="img",f["aria-label"]=a);var p=e.class||"";h||(p.includes("e-diagram-resize-handle")||p.includes("e-diagram-endpoint-handle")||p.includes("e-diagram-bezier-control-handle"))&&(p+=" e-disabled"),e.class&&(f.class=p),a||(f["pointer-events"]="none"),ti(d,f),this.setSvgStyle(d,e,i)},n.prototype.updateSelectionRegion=function(t,e){var i;i=t.parentNode.getElementById(e.id);var r={id:e.id,x:e.x.toString(),y:e.y.toString(),width:e.width.toString(),height:e.height.toString(),transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")",class:"e-diagram-selected-region"};i||(i=document.createElementNS("http://www.w3.org/2000/svg","rect"),t.appendChild(i)),this.setSvgStyle(i,e),ti(i,r)},n.prototype.createGElement=function(t,e){return Fi(t,e)},n.prototype.drawLine=function(t,e){var i=document.createElementNS("http://www.w3.org/2000/svg","line");this.setSvgStyle(i,e);var r=e.x+e.width*e.pivotX,s=e.y+e.height*e.pivotY,o={id:e.id,x1:e.startPoint.x+e.x,y1:e.startPoint.y+e.y,x2:e.endPoint.x+e.x,y2:e.endPoint.y+e.y,stroke:e.stroke,"stroke-width":e.strokeWidth.toString(),opacity:e.opacity.toString(),transform:"rotate("+e.angle+" "+r+" "+s+")",visibility:e.visible?"visible":"hidden"};e.class&&(o.class=e.class),ti(i,o),t.appendChild(i)},n.prototype.drawCircle=function(t,e,i,r){var s=document.createElementNS("http://www.w3.org/2000/svg","circle");this.setSvgStyle(s,e);var o=e.class||"";i||(o+=" e-disabled");var a={id:e.id,cx:e.centerX,cy:e.centerY,r:e.radius,visibility:e.visible?"visible":"hidden",class:o};r&&(a.role="img",a["aria-label"]=r),s.style.display=e.visible?"block":"none",ti(s,a),t.appendChild(s)},n.prototype.drawPath=function(t,e,i,r,s,o,a){var h,c,l=[];l=e3(l=Ed(e.data)),e.shadow&&this.renderShadow(e,t,l,s),s&&!e.shadow&&(h=s.getElementById(e.id+"_groupElement_shadow"))&&h.parentNode.removeChild(h),s&&(c=s.getElementById(e.id)),(!c||r)&&(c=document.createElementNS("http://www.w3.org/2000/svg","path"),t.appendChild(c)),this.renderPath(c,e,l);var d={};d=a?{id:e.id,transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")translate("+e.x+","+e.y+"),scale("+a+")",visibility:e.visible?"visible":"hidden",opacity:e.opacity}:{id:e.id,transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")translate("+e.x+","+e.y+")",visibility:e.visible?"visible":"hidden",opacity:e.opacity},o&&(d.role="img",d["aria-label"]=o),e.class&&(d.class=e.class),ti(c,d),this.setSvgStyle(c,e,i)},n.prototype.renderPath=function(t,e,i){var r,s,o,a,l,h,c,d,u=i,f="";for(l=0,h=0,d=0,c=u.length;de.width&&"Wrap"!==e.textOverflow&&"NoWrap"===e.textWrapping&&(h[0].text=qF(e.content,e)),v=0;vD&&(u.text=u.text.slice(0,u.text.length-3),u.text=u.text.concat("..."),l.data=u.text),this.alignText(y,f,u,l,p,g,v,e,h),C+=u.dy}}C&&e.isHorizontalLane&&(M=e.parentOffsetX+e.pivotX,w=e.parentOffsetY+e.pivotY,e.y=e.parentOffsetY-C*e.pivotY+.5),e.textDecoration&&"LineThrough"===e.textDecoration&&(e.textDecoration=gb(e.textDecoration));var P={id:e.id+"_text",fill:e.color,visibility:e.visible?"visible":"hidden","text-decoration":e.textDecoration,transform:"rotate("+e.angle+","+M+","+w+")translate("+e.x+","+e.y+")",opacity:e.opacity};r&&(P.role="img",P["aria-label"]=r),ti(y,P)}},n.prototype.alignText=function(t,e,i,r,s,o,a,l,h){"justify"!==l.textAlign?this.setText(t,e,i,r,s,o,l):a!==h.length-1?this.setText(t,e,i,r,s,o,l,l.width,"spacing"):this.setText(t,e,i,r,s,o,l)},n.prototype.setText=function(t,e,i,r,s,o,a,l,h){ti(e,"justify"!==a.textAlign?{x:s.toString(),y:o.toString()}:{x:s.toString(),y:o.toString(),textLength:l||0,lengthAdjust:h||"spacing"}),t.setAttribute("fill",i.text),e.appendChild(r),t.appendChild(e)},n.prototype.drawImage=function(t,e,i,r){var s;i&&(s=i.getElementById(e.id+"image")),s||(s=document.createElementNS("http://www.w3.org/2000/svg","image"),t.appendChild(s));var o=new Image;o.src=e.source;var a="None"!==e.scale?e.scale:"",l=e.alignment,h=l.charAt(0).toLowerCase()+l.slice(1);"Stretch"!==a&&(h+=" "+a.charAt(0).toLowerCase()+a.slice(1)),ti(s,{id:e.id+"image",x:e.x.toString(),y:e.y.toString(),transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")",width:e.width.toString(),visibility:e.visible?"visible":"hidden",height:e.height.toString(),preserveAspectRatio:h,opacity:e.opacity.toString()}),s.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",o.src.toString())},n.prototype.drawHTMLContent=function(t,e,i,r,s){var o,a;if(e&&(o=e.querySelector("#"+t.id+"_html_element")),!o){(a=e.querySelector("#"+t.id+"_html_element")||e.querySelector("#"+t.nodeId+"_html_element"))||(a=Tt("div",{id:t.nodeId+"_html_element",class:"foreign-object"})),o=Tt("div",{id:t.id+"_html_element",class:"foreign-object"});var c=document.getElementById(t.diagramId).ej2_instances[0],d=!1;if(e.parentNode&&e.parentNode.parentNode&&e.parentNode.parentNode.parentNode&&e.parentNode.parentNode.parentNode.classList.contains("e-overview")&&(d=!0),d)c.isReact?c.renderReactTemplates(function(){o.appendChild(t.template.cloneNode(!0))}):o.appendChild(t.template.cloneNode(!0));else{if("string"==typeof t.template){var u=document.createElement("div");u.innerHTML=t.template,t.template=u,c.selectedItems.userHandles.filter(function(g){return g.name===t.id.split("_shape")[0]&&""!==g.template})[0].template=t.template}t.isTemplate&&t.template?o.appendChild(t.template):t.template&&o.appendChild(t.template.cloneNode(!0))}void 0!==s&&e.childNodes.length>s&&e.insertBefore(o,e.childNodes[parseInt(s.toString(),10)]),a.appendChild(o),e.appendChild(a)}var p=xn(t).topLeft;o.setAttribute("style","height:"+t.actualSize.height+"px; width:"+t.actualSize.width+"px;left:"+p.x+"px; top:"+p.y+"px;position:absolute;transform:rotate("+(t.rotateAngle+t.parentTransform)+"deg);pointer-events:"+(r?"all":"none")+";visibility:"+(t.visible?"visible":"hidden")+";opacity:"+t.style.opacity+";")},n.prototype.drawNativeContent=function(t,e,i,r,s){var o,a;if(s&&(o=s.getElementById(t.id+"_native_element"),a=s.getElementById(t.id+"_clip")),!o){(o=document.createElementNS("http://www.w3.org/2000/svg","g")).setAttribute("id",t.id+"_native_element"),o.appendChild(t.template.cloneNode(!0));var l=this.createGElement("g",{id:t.id+"_inner_native_element"});l.appendChild(o),e.appendChild(l)}a&&o.removeChild(a),o.setAttribute("style","visibility:"+(t.visible?"visible":"hidden")+";opacity:"+t.style.opacity+";"),this.setNativTransform(t,o,i,r),"Slice"===t.scale&&this.drawClipPath(t,o,i,r,s),ti(o,t.description?{role:"img","aria-label":t.description}:{})},n.prototype.setNativTransform=function(t,e,i,r){var s=0!==t.contentSize.width?t.contentSize.width:1,o=0!==t.contentSize.height?t.contentSize.height:1;e.setAttribute("transform","rotate("+t.parentTransform+","+t.offsetX+","+t.offsetY+") translate("+(t.offsetX-t.templatePosition.x*r/s-r*t.pivot.x)+","+(t.offsetY-t.templatePosition.y*i/o-i*t.pivot.y)+") scale("+r/s+","+i/o+")")},n.prototype.drawClipPath=function(t,e,i,r,s){var o=t.contentSize.width,a=t.contentSize.height,l=t.width/(r/o),h=t.height/(i/a),c=t.templatePosition.x+(t.width>=t.height?0:(o-l)/2),d=t.templatePosition.y+(t.height>=t.width?0:(a-h)/2),u=s.getElementById(t.id+"_clip");(u=document.createElementNS("http://www.w3.org/2000/svg","clipPath")).setAttribute("id",t.id+"_clip"),e.appendChild(u);var f=s.getElementById(t.id+"_clip_rect");return f=document.createElementNS("http://www.w3.org/2000/svg","rect"),u.appendChild(f),ti(f,{id:t.id+"_clip_rect",width:l.toString(),height:h.toString(),x:c.toString(),y:d.toString()}),om()?e.setAttribute("clip-path","url("+location.protocol+"//"+location.host+location.pathname+"#"+t.id+"_clip)"):e.setAttribute("clip-path","url(#"+t.id+"_clip)"),e},n.prototype.renderGradient=function(t,e,i){var r,s,o,h,c,a=IT(i),l=a.getElementById(i+"gradient_pattern");if(l||(l=Fi("defs",{id:i+"gradient_pattern"}),a.insertBefore(l,a.firstChild)),bF(e.id),"None"!==t.gradient.type){for(var d=0;dt.width&&("Ellipsis"===t.textOverflow||"Clip"===t.textOverflow)&&"NoWrap"===t.textWrapping?0:.5*t.width:"right"===t.textAlign&&(c=1*t.width),s.x=0+c+(e?e.x:0),s.y=1.2+d-r.height/2,s},n}(),Pc=function(){function n(t,e,i){this.renderer=null,this.isSvgMode=!0,this.touchMove=void 0,this.transform={x:0,y:0},this.diagramId=t,this.element=xt(this.diagramId),this.svgRenderer=e,this.isSvgMode=i,this.renderer=i?new Jf:new bo}return n.prototype.setCursor=function(t,e){t.style.cursor=e},n.prototype.setLayers=function(){this.iconSvgLayer=this.element.getElementsByClassName("e-ports-expand-layer")[0],this.adornerSvgLayer=this.element.getElementsByClassName("e-adorner-layer")[0],this.nativeSvgLayer=this.element.getElementsByClassName("e-native-layer")[0],this.diagramSvgLayer=this.element.getElementsByClassName("e-diagram-layer")[0]},n.prototype.getAdornerLayer=function(){return yT(this.diagramId)},n.prototype.getParentSvg=function(t,e,i){return this.diagramId&&t&&t.id?t.id.split("_icon_content").length>1||t.id.split("_nodeport").length>1||t.elementActions&Xr.ElementIsPort?this.iconSvgLayer:e&&"selector"===e?this.adornerSvgLayer:t instanceof En?this.nativeSvgLayer:this.diagramSvgLayer:i},n.prototype.getParentElement=function(t,e,i,r){var s=e;if(i&&this.diagramId&&t&&t.id){t.id.split("_icon_content").length>1?(s=i.getElementById(this.diagramId+"_diagramExpander"),e=null):t.id.split("_nodeport").length>1?s=i.getElementById(this.diagramId+"_diagramPorts"):t instanceof En?(s=i.getElementById(this.diagramId+"_nativeLayer"),e=null):t.elementActions&Xr.ElementIsPort?(s=i.getElementById(this.diagramId+"_diagramPorts"),e=null):s=i.getElementById(this.diagramId+"_diagramLayer");var o=this.getGroupElement(t,e||s,r);s=o.g,o.svg&&(i=o.svg)}return{g:s,svg:i}},n.prototype.getGroupElement=function(t,e,i){var r,o,s=this.getParentSvg(t);if(e&&s){if(s&&!(r=s.getElementById(t.id+"_groupElement"))&&s!==this.nativeSvgLayer){var a=this.nativeSvgLayer;r=a.getElementById(t.id+"_groupElement"),o=a}r||(r=this.svgRenderer.createGElement("g",{id:t.id+"_groupElement"}),void 0!==i&&e.childNodes.length>i?e.insertBefore(r,e.childNodes[parseInt(i.toString(),10)]):e.appendChild(r))}return{g:r,svg:o}},n.prototype.renderElement=function(t,e,i,r,s,o,a,l,h,c,d){t instanceof Cs?(t.id=t.id?t.id:Qe(),this.renderContainer(t,e,i,r,s,o,a,l,h,c,d)):t instanceof DI?this.renderImageElement(t,e,r,s,a):t instanceof Ze?this.renderPathElement(t,e,r,s,a,h,d):t instanceof ai?this.renderTextElement(t,e,r,s,a,c):t instanceof En?this.renderNativeElement(t,e,r,s,a):t instanceof es?this.renderHTMLElement(t,e,i,r,s,a,l):this.renderRect(t,e,r,s,h)},n.prototype.drawSelectionRectangle=function(t,e,i,r,s,o){var a={width:i*o.scale,height:r*o.scale,x:.5+(t=(t+o.tx)*o.scale),y:.5+(e=(e+o.ty)*o.scale),fill:"transparent",stroke:"gray",angle:0,pivotX:.5,pivotY:.5,strokeWidth:1,dashArray:"6 3",opacity:1,visible:!0,id:s.id+"_selected_region"},l=this.getAdornerLayer();this.svgRenderer.updateSelectionRegion(l,a)},n.prototype.renderHighlighter=function(t,e,i){var r=t.actualSize.width||2,s=t.actualSize.height||2,o=t.offsetX-r*t.pivot.x,a=t.offsetY-s*t.pivot.y;this.svgRenderer.drawRectangle(e,{width:r*i.scale,height:s*i.scale,x:o=(o+i.tx)*i.scale,y:a=(a+i.ty)*i.scale,fill:"transparent",stroke:"#8CC63F",angle:t.rotateAngle,pivotX:t.pivot.x,pivotY:t.pivot.y,strokeWidth:4,dashArray:"",opacity:1,cornerRadius:0,visible:!0,id:e.id+"_highlighter",class:"e-diagram-highlighter"},this.diagramId,void 0,void 0,e)},n.prototype.renderSelectionRectangle=function(t,e,i,r){var s=t.actualSize.width||2,o=t.actualSize.height||2,a=t.offsetX-s*t.pivot.x,l=t.offsetY-o*t.pivot.y,h={width:s*i.scale,height:o*i.scale,x:a=(a+i.tx)*i.scale,y:l=(l+i.ty)*i.scale,fill:"transparent",stroke:"#00cc00",angle:t.rotateAngle,pivotX:t.pivot.x,pivotY:t.pivot.y,strokeWidth:r?2:1,dashArray:"",opacity:1,cornerRadius:0,visible:!0,id:t.id+"_highlighter",class:r?"e-diagram-first-selection-indicator e-diagram-selection-indicator":"e-diagram-selection-indicator"},c=this.getParentSvg(t,"selector");this.svgRenderer.drawRectangle(e,h,this.diagramId,void 0,void 0,c)},n.prototype.renderSelectionLine=function(t,e,i,r){var s=this.getBaseAttributes(t,i);s.data=t.absolutePath,s.id=s.id+"_highlighter";var o=t.description?t.description:t.id;this.isSvgMode||(s.x=t.flipOffset.x?t.flipOffset.x:s.x,s.y=t.flipOffset.y?t.flipOffset.y:s.y),i&&(s.x=s.x*i.scale,s.y=s.y*i.scale),s.stroke="#00cc00",s.strokeWidth=r?2:1,s.class=r?"e-diagram-first-selection-indicator e-diagram-selection-indicator":"e-diagram-selection-indicator";var a=this.getParentSvg(t,"selector");this.svgRenderer.drawPath(e,s,this.diagramId,void 0,a,o,i.scale)},n.prototype.renderStackHighlighter=function(t,e,i,r,s,o,a){var l=t.actualSize.width||2,h=t.offsetX-l*t.pivot.x,c=t.actualSize.height||2,d=t.offsetY-c*t.pivot.y;h=(h+i.tx)*i.scale;var u,f=t.bounds,p="";if(d=(d+i.ty)*i.scale,r)if(o){var v,y;u="M 0 0 L "+(2+(g=l*i.scale))+" 0 Z",v=t.actualSize.width/Number(f.width?f.width:1)*i.scale,y=t.actualSize.height/Number(f.height?f.height:1)*i.scale,p=bI(MI(Ed("M7,4 L8,4 8,7 11,7 11,8 8,8 8,11 7,11 7,8 4,8 4,7 7,7 z M7.5,0.99999994C3.9160004,1 1,3.9160004 0.99999994,7.5 1,11.084 3.9160004,14 7.5,14 11.084,14 14,11.084 14,7.5 14,3.9160004 11.084,1 7.5,0.99999994 z M7.5,0 C11.636002,0 15,3.3639984 15,7.5 15,11.636002 11.636002,15 7.5,15 3.3640003,15 0,11.636002 0,7.5 0,3.3639984 3.3640003,0 7.5,0 z")),v+g+2,y-8,!1,f.x,f.y,0,0),s.y>=t.offsetY&&(d+=c)}else{var g;a&&s.y>=t.offsetY&&(d+=c*i.scale),u="M -10 -10 L 0 0 Z M -10 10 L 0 0 Z M 0 0 L "+(g=l*i.scale)+" 0 Z M "+g+" 0 L "+(g+10)+" 10 Z L "+(g+10)+" -10 Z"}else u="M 10 -10 L 0 0 Z M -10 -10 L 0 0 Z M 0 0 L 0 "+(g=c*i.scale)+" Z M 0 "+g+" L -10 "+(g+10)+" Z L 10 "+(g+10)+" Z",s.x>=t.offsetX&&(h+=l*i.scale);this.svgRenderer.drawPath(e,{data:u+p,width:l*i.scale,height:c*i.scale,x:h,y:d,fill:"transparent",stroke:"#8CC63F",angle:t.rotateAngle,pivotX:t.pivot.x,pivotY:t.pivot.y,strokeWidth:1,dashArray:"",opacity:1,visible:!0,id:e.id+"_stack_highlighter",class:"e-diagram-highlighter"},this.diagramId)},n.prototype.drawLine=function(t,e){this.svgRenderer.drawLine(t,e)},n.prototype.drawPath=function(t,e){this.svgRenderer.drawPath(t,e,this.diagramId)},n.prototype.renderResizeHandle=function(t,e,i,r,s,o,a,l,h,c,d){var u=t.offsetX-t.actualSize.width*t.pivot.x,f=t.offsetY-t.actualSize.height*t.pivot.y,p=t.actualSize.height,g=t.actualSize.width;if(!c&&i&bt.Rotate&&jI(this.rendererActions)&&!z3(this.rendererActions))this.renderPivotLine(t,e,o,s,a),this.renderRotateThumb(t,e,o,s,a);else if(this.touchMove){var v=document.getElementById("rotateThumb");v&&v.setAttribute("visibility","hidden")}this.renderBorder(t,e,o,l,h,c);var y=t.actualSize.width*r,S=t.actualSize.height*r;!h&&jI(this.rendererActions)&&!z3(this.rendererActions)&&(t.isTextAnnotation||(y>=40&&S>=40&&(s&mr.ResizeNorthWest&&this.renderCircularHandle("resizeNorthWest",t,u,f,e,qr(s,"ResizeNorthWest"),i&bt.ResizeNorthWest,o,void 0,a,{"aria-label":"Thumb to resize the selected object on top left side direction"},void 0,"e-diagram-resize-handle e-northwest",d),s&mr.ResizeNorthEast&&this.renderCircularHandle("resizeNorthEast",t,u+g,f,e,qr(s,"ResizeNorthEast"),i&bt.ResizeNorthEast,o,void 0,a,{"aria-label":"Thumb to resize the selected object on top right side direction"},void 0,"e-diagram-resize-handle e-northeast",d),s&mr.ResizeSouthWest&&this.renderCircularHandle("resizeSouthWest",t,u,f+p,e,qr(s,"ResizeSouthWest"),i&bt.ResizeSouthWest,o,void 0,a,{"aria-label":"Thumb to resize the selected object on bottom left side direction"},void 0,"e-diagram-resize-handle e-southwest",d),s&mr.ResizeSouthEast&&this.renderCircularHandle("resizeSouthEast",t,u+g,f+p,e,qr(s,"ResizeSouthEast"),i&bt.ResizeSouthEast,o,void 0,a,{"aria-label":"Thumb to resize the selected object on bottom right side direction"},void 0,"e-diagram-resize-handle e-southeast",d)),s&mr.ResizeNorth&&this.renderCircularHandle("resizeNorth",t,u+g/2,f,e,qr(s,"ResizeNorth"),i&bt.ResizeNorth,o,void 0,a,{"aria-label":"Thumb to resize the selected object on top side direction"},void 0,"e-diagram-resize-handle e-north",d),s&mr.ResizeSouth&&this.renderCircularHandle("resizeSouth",t,u+g/2,f+p,e,qr(s,"ResizeSouth"),i&bt.ResizeSouth,o,void 0,a,{"aria-label":"Thumb to resize the selected object on bottom side direction"},void 0,"e-diagram-resize-handle e-south",d),s&mr.ResizeWest&&this.renderCircularHandle("resizeWest",t,u,f+p/2,e,qr(s,"ResizeWest"),i&bt.ResizeWest,o,void 0,a,{"aria-label":"Thumb to resize the selected object on left side direction"},void 0,"e-diagram-resize-handle e-west",d),s&mr.ResizeEast&&this.renderCircularHandle("resizeEast",t,u+g,f+p/2,e,qr(s,"ResizeEast"),i&bt.ResizeEast,o,void 0,a,{"aria-label":"Thumb to resize the selected object on right side direction"},void 0,"e-diagram-resize-handle e-east",d)))},n.prototype.renderEndPointHandle=function(t,e,i,r,s,o,a,l,h,c){var p,g,d=t.sourcePoint,u=t.targetPoint,f=t.wrapper;if(this.renderCircularHandle("connectorSourceThumb",f,d.x,d.y,e,qr(r,"ConnectorSourceThumb"),i&bt.ConnectorSource,s,o,void 0,{"aria-label":"Thumb to move the source point of the connector"},void 0,"e-diagram-endpoint-handle e-sourceend",c),this.renderCircularHandle("connectorTargetThumb",f,u.x,u.y,e,qr(r,"ConnectorTargetThumb"),i&bt.ConnectorTarget,s,a,void 0,{"aria-label":"Thumb to move the target point of the connector"},void 0,"e-diagram-endpoint-handle e-targetend",c),l)if("Straight"===t.type&&t.segments.length>0)for(p=0;p0)for(p=0;p=3&&3===t.segments.length&&(S=1,b=t.segments.length-1),S=t.segments.length>t.maxSegmentThumb+2?2:S,b=t.segments.length>t.maxSegmentThumb+2?t.segments.length-2:b,1===t.segments.length&&t.segments[0].points.length<=2&&(S=1,b=t.segments.length),p=S;p=50&&i.allowDrag),this.renderOrthogonalThumb(t+"_"+(d+1),e,(i.points[parseInt(d.toString(),10)].x+i.points[d+1].x)/2,(i.points[parseInt(d.toString(),10)].y+i.points[d+1].y)/2,r,h,l,o,a,u)}else for(d=0;d=50&&i.allowDrag),this.renderOrthogonalThumb(t+"_"+(d+1),e,(i.points[parseInt(d.toString(),10)].x+i.points[d+1].x)/2,(i.points[parseInt(d.toString(),10)].y+i.points[d+1].y)/2,r,h,l,o,a,u)},n.prototype.renderOrthogonalThumb=function(t,e,i,r,s,o,a,l,h,c){var d,g,u=0,f=document.getElementById(this.diagramId);f&&(g=f.ej2_instances[0]);var y=h.constraints&qe.InheritSegmentThumbShape?g.segmentThumbShape:h.segmentThumbShape,b=h.constraints&qe.InheritSegmentThumbSize?g.segmentThumbSize:h.segmentThumbSize;if(d="horizontal"===a?function ure(n){return vre[""+n]}(y):c3(y),"Arrow"===y||"DoubleArrow"===y||"OpenArrow"===y)switch(c){case"Bottom":case"Right":u=180;break;default:u=0}else if("Fletch"===y||"OpenFetch"===y||"IndentedArrow"===y||"OutdentedArrow"===y)switch(c){case"Bottom":u=-90;break;case"Top":u=90;break;case"Right":u=180;break;default:u=0}var M={x:(i+l.tx)*l.scale-b/2,y:(r+l.ty)*l.scale-b/2,angle:u,fill:"#e2e2e2",stroke:"black",strokeWidth:1,dashArray:"",data:d,width:b,height:b,pivotX:.5,pivotY:.5,opacity:1,visible:o,id:t,class:"e-diagram-ortho-segment-handle"},w=op(M.data),C=new me(M.width,M.height),D=new Ze;if(M.data=D.updatePath(M.data,w,C),this.touchMove){var A=document.getElementById(t);A?this.updateSegmentPosition(A,M):this.svgRenderer.drawPath(s,M,this.diagramId)}else this.svgRenderer.drawPath(s,M,this.diagramId)},n.prototype.renderPivotLine=function(t,e,i,r,s){var o=t,l=!!(r&mr.Rotate);s&&(l=!1);var h=this.getBaseAttributes(o,i);h.fill="None",h.stroke="black",h.strokeWidth=1,h.dashArray="2,3",h.visible=l;var c=i.scale;h.x*=c,h.y*=c,h.width*=c,h.height*=c,h.id="pivotLine",h.class="e-diagram-pivot-line";var u={x:o.actualSize.width*o.pivot.x*c,y:0};h.startPoint={x:o.actualSize.width*o.pivot.x*c,y:-20},h.endPoint=u,this.svgRenderer.drawLine(e,h)},n.prototype.renderBezierLine=function(t,e,i,r,s,o){var l=this.getBaseAttributes(e,o);l.id=t,l.stroke="black",l.strokeWidth=1,l.dashArray="3,3",l.fill="None",l.class="e-diagram-bezier-control-line",l.x=0,l.y=0;var h=o.scale,g={x:(s.x+o.tx)*h,y:(s.y+o.ty)*h};l.startPoint={x:(r.x+o.tx)*h,y:(r.y+o.ty)*h},l.endPoint=g,this.svgRenderer.drawLine(i,l)},n.prototype.renderCircularHandle=function(t,e,i,r,s,o,a,l,h,c,d,u,f,p){var g=e,v={x:i,y:r};if(0!==g.rotateAngle||0!==g.parentTransform){var y=Bi();qi(y,g.rotateAngle+g.parentTransform,g.offsetX,g.offsetY),v=Ke(y,v)}var S=this.getBaseAttributes(g);if(S.stroke="black",S.strokeWidth=1,void 0!==u?(S.id="segmentEnd_"+u,S.fill="#e2e2e2"):S.fill=h?"#8CC63F":"white",S.cornerRadius=p/2,S.angle=e.rotateAngle,S.id=t,S.visible=o,S.class=f,S.width=p,S.height=p,S.x=(v.x+l.tx)*l.scale,S.y=(v.y+l.ty)*l.scale,S.x=S.x-S.width/2,S.y=S.y-S.height/2,h&&(S.class+=" e-connected"),c&&(S.visible=!1),this.touchMove){var b=document.getElementById(t);if(b)this.updateResizeHandle(b,S);else{var M=this.getParentSvg(e,"selector");this.svgRenderer.drawRectangle(s,S,this.diagramId,!0,!0,M,d,!0,a)}}else M=this.getParentSvg(e,"selector"),this.svgRenderer.drawRectangle(s,S,this.diagramId,!0,!0,M,d,!0,a)},n.prototype.updateResizeHandle=function(t,e){ti(t,{id:e.id,x:e.x.toString(),y:e.y.toString(),width:e.width.toString(),height:e.height.toString(),visibility:e.visible?"visible":"hidden",transform:"rotate("+e.angle+","+(e.x+e.width/2)+","+(e.y+e.height/2)+")",rx:e.cornerRadius||0,ry:e.cornerRadius||0,opacity:e.opacity})},n.prototype.renderBezierHandle=function(t,e,i,r,s,o,a,l,h,c,d,u,f){var v,p=document.getElementById(this.diagramId);p&&(v=p.ej2_instances[0]);var y=e,S={x:i,y:r};if(0!==y.rotateAngle||0!==y.parentTransform){var b=Bi();qi(b,y.rotateAngle+y.parentTransform,y.offsetX,y.offsetY),S=Ke(b,S)}var D=a.constraints&qe.InheritSegmentThumbSize?v.segmentThumbSize:a.segmentThumbSize,A=c3(a.constraints&qe.InheritSegmentThumbShape?v.segmentThumbShape:a.segmentThumbShape),x=this.getBaseAttributes(y);x.stroke="black",x.strokeWidth=1,void 0!==d?(x.id="segmentEnd_"+d,x.fill="#e2e2e2"):x.fill=h?"#8CC63F":"white",x.angle=e.rotateAngle,x.id=t,x.visible=o,x.class=u,x.width=D,x.height=D,x.data=A,x.x=(S.x+l.tx)*l.scale,x.y=(S.y+l.ty)*l.scale,x.x=x.x-x.width/2,x.y=x.y-x.height/2,h&&(x.class+=" e-connected"),c&&(x.visible=!1);var P=op(x.data),L=new me(x.width,x.height),O=new Ze;if(x.data=O.updatePath(x.data,P,L),this.touchMove){var N=document.getElementById(t);if(N)this.updateSegmentPosition(N,x);else{var T=this.getParentSvg(e,"selector");this.svgRenderer.drawPath(s,x,this.diagramId,!0,T)}}else T=this.getParentSvg(e,"selector"),this.svgRenderer.drawPath(s,x,this.diagramId,!0,T)},n.prototype.updateSegmentPosition=function(t,e){ti(t,{id:e.id,transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")translate("+e.x+","+e.y+")",visibility:e.visible?"visible":"hidden",opacity:e.opacity})},n.prototype.renderBorder=function(t,e,i,r,s,o){var l=this.getBaseAttributes(t,i);l.x*=i.scale,l.y*=i.scale,l.width*=i.scale,l.height*=i.scale,l.fill="transparent",l.stroke="#097F7F",l.strokeWidth=1.2,l.gradient=null,l.dashArray="6,3",l.class="e-diagram-selector",o&&(l.class+=" e-diagram-lane"),l.id="borderRect",l.id=this.rendererActions&Ga.DrawSelectorBorder?"borderRect_symbol":"borderRect",r||(l.class+=" e-disabled"),s&&(l.class+=" e-thick-border"),l.cornerRadius=0;var h=this.getParentSvg(t,"selector");this.svgRenderer.drawRectangle(e,l,this.diagramId,void 0,!0,h)},n.prototype.renderUserHandler=function(t,e,i,r,s,o){for(var l,a=t.wrapper,h=0,c=t.userHandles;h0||d.disableNodes&&t.nodes.length>0||"Drag"===s&&o)&&(l=!1);var u=document.getElementById(d.name+"_template_hiddenUserHandle");u&&(d.template=u.childNodes[0].cloneNode(!0));var f=iT(t,d,i);if(f.x=(f.x+i.tx)*i.scale,f.y=(f.y+i.ty)*i.scale,d.visible&&(d.visible=!!(t.constraints&mr.UserHandle)),l)if(d.pathData){var p=d.pathData?d.pathData:d.content,g=this.getBaseAttributes(a);g.id=d.name+"_userhandle",g.fill=d.backgroundColor,g.stroke=d.borderColor,g.strokeWidth=d.borderWidth,g.centerX=f.x,g.centerY=f.y,g.radius=.5*d.size,g.class="e-diagram-userhandle-circle",g.angle=0,g.visible=d.visible,g.opacity=1,this.svgRenderer.drawCircle(e,g,1,{"aria-label":d.name+"user handle"});var y=[];y=MI(y=Ed(p));var S=op(p),w=bI(y,(d.size-.45*d.size)/S.width,(d.size-.45*d.size)/S.height,!0,S.x,S.y,0,0);S=op(w),this.svgRenderer.drawPath(e,C={x:f.x-S.width/2,y:f.y-S.height/2,angle:0,id:"",class:"e-diagram-userhandle-path",fill:d.pathColor,stroke:d.backgroundColor,strokeWidth:.5,dashArray:"",data:w,width:d.size-5,height:d.size-5,pivotX:0,pivotY:0,opacity:1,visible:d.visible},this.diagramId,void 0,void 0,{"aria-label":d.name+"user handle"})}else if(d.content){var D=new En(d.name,this.diagramId);D.content=d.content,D.offsetX=f.x,D.offsetY=f.y,D.id=d.name+"_shape",D.horizontalAlignment="Center",D.verticalAlignment="Center",D.visible=d.visible,D.setOffsetWithRespectToBounds(f.x,f.y,"Fraction"),D.relativeMode="Object",D.description=d.name||"User handle",D.measure(new me(d.size,d.size)),D.arrange(D.desiredSize),this.svgRenderer.drawNativeContent(D,e,d.size,d.size,this.adornerSvgLayer)}else if(d.source){var C,A=new DI;(C=this.getBaseAttributes(A,i)).width=d.size,C.height=d.size,C.x=f.x-d.size/2,C.y=f.y-d.size/2,C.sourceWidth=d.size,C.sourceHeight=d.size,C.alignment=A.imageAlign,C.source=d.source,C.scale=A.imageScale,C.visible=d.visible,C.description=d.name||"User handle",C.id=d.name+"_",this.renderer.drawImage(e,C,this.adornerSvgLayer,!1)}else{var x=new es(d.name,this.diagramId);x.offsetX=f.x,x.offsetY=f.y,x.id=d.name+"_shape",x.visible=d.visible,x.relativeMode="Object",x.template=d.template,x.measure(new me(d.size,d.size)),x.arrange(x.desiredSize),this.svgRenderer.drawHTMLContent(x,r,void 0,!0,void 0)}}},n.prototype.renderRotateThumb=function(t,e,i,r,s){new Ze;var a,l=new me;l.width=18,l.height=16;var d=!!(r&mr.Rotate);s&&(d=!1);var f=t.offsetX-t.actualSize.width*t.pivot.x+t.pivot.x*t.actualSize.width,p=t.offsetY-t.actualSize.height*t.pivot.y;if(a={x:(f=(f+i.tx)*i.scale)-.5*l.width,y:(p=(p+i.ty)*i.scale)-30-.5*l.height},0!==t.rotateAngle||0!==t.parentTransform){var g=Bi();qi(g,t.rotateAngle+t.parentTransform,(i.tx+t.offsetX)*i.scale,(i.ty+t.offsetY)*i.scale),a=Ke(g,a)}var v={x:a.x,y:a.y,angle:t.rotateAngle+t.parentTransform,fill:"#231f20",stroke:"black",strokeWidth:.5,dashArray:"",data:"M 16.856144362449648 10.238890446662904 L 18.000144362449646 3.437890446662903L 15.811144362449646 4.254890446662903 C 14.837144362449646 2.5608904466629028 13.329144362449647 1.2598904466629026 11.485144362449645 0.5588904466629026 C 9.375144362449646 - 0.24510955333709716 7.071144362449646 - 0.18010955333709716 5.010144362449646 0.7438904466629028 C 2.942144362449646 1.6678904466629028 1.365144362449646 3.341890446662903 0.558144362449646 5.452890446662903 C - 0.244855637550354 7.567890446662903 - 0.17985563755035394 9.866890446662904 0.7431443624496461 11.930890446662904 C 1.6681443624496461 13.994890446662904 3.343144362449646 15.575890446662903 5.457144362449647 16.380890446662903 C 6.426144362449647 16.7518904466629 7.450144362449647 16.9348904466629 8.470144362449647 16.9348904466629 C 9.815144362449647 16.9348904466629 11.155144362449647 16.6178904466629 12.367144362449647 15.986890446662901 L 11.351144362449647 14.024890446662901 C 9.767144362449647 14.8468904466629 7.906144362449647 14.953890446662902 6.237144362449647 14.3178904466629 C 4.677144362449647 13.7218904466629 3.444144362449647 12.5558904466629 2.758144362449647 11.028890446662901 C 2.078144362449646 9.501890446662903 2.031144362449646 7.802890446662903 2.622144362449646 6.243890446662903 C 3.216144362449646 4.6798904466629025 4.387144362449646 3.442890446662903 5.914144362449646 2.760890446662903 C 7.437144362449646 2.078890446662903 9.137144362449646 2.0298904466629026 10.700144362449645 2.6258904466629027 C 11.946144362449646 3.100890446662903 12.971144362449646 3.9538904466629026 13.686144362449646 5.049890446662903 L 11.540144362449645 5.850890446662903 L 16.856144362449648 10.238890446662904 Z",width:20,height:20,pivotX:0,pivotY:0,opacity:1,visible:d,id:"rotateThumb",class:"e-diagram-rotate-handle"};if(this.touchMove){var y=document.getElementById("rotateThumb");y?this.updateSegmentPosition(y,v):this.svgRenderer.drawPath(e,v,this.diagramId,!0,void 0,{"aria-label":"Thumb to rotate the selected object"})}else this.svgRenderer.drawPath(e,v,this.diagramId,!0,void 0,{"aria-label":"Thumb to rotate the selected object"})},n.prototype.renderPathElement=function(t,e,i,r,s,o,a){var l=this.getBaseAttributes(t,i,o);if(l.data=t.absolutePath,l.data=t.absolutePath,t.isPathPort&&a){l.x=a[t.id]?a[t.id].cx:l.x,l.y=a[t.id]?a[t.id].cy:l.y,t.bounds.x=l.x,t.bounds.y=l.y;var h=document.getElementById(this.diagramId);h&&"PortDrag"!==h.ej2_instances[0].eventHandler.currentAction&&(t.offsetX=l.x+t.width/2,t.offsetY=l.y+t.height/2)}var u=t.description?t.description:t.id;if(this.isSvgMode||(l.x=t.flipOffset.x?t.flipOffset.x:l.x,l.y=t.flipOffset.y?t.flipOffset.y:l.y),t.isExport){var f=t.absoluteBounds,p=Ed(l.data),g=this.findAndStoreArcValues(p);l.arc=g,l.data=BF(t,f,0,l)}this.renderer.drawPath(e,l,this.diagramId,void 0,r,u)},n.prototype.findAndStoreArcValues=function(t){var e=[];return t.forEach(function(i){"A"===i.command&&e.push({r1:i.r1/2,r2:i.r2/2})}),e},n.prototype.renderSvgGridlines=function(t,e,i,r,s,o){var a=document.createElementNS("http://www.w3.org/2000/svg","pattern"),l=document.createElementNS("http://www.w3.org/2000/svg","defs");l.setAttribute("id",this.diagramId+"_grid_pattern_defn"),(t.constraints&Kt.ShowHorizontalLines||t.constraints&Kt.ShowVerticalLines)&&a.setAttribute("id",this.diagramId+"_pattern");var h=0,c=0,d=0,u=0,f=1,p=!1,g="Lines"===t.gridType,v=g?t.verticalGridlines.lineIntervals:t.verticalGridlines.dotIntervals,y=g?t.horizontalGridlines.lineIntervals:t.horizontalGridlines.dotIntervals;if(r.showRulers&&r.dynamicGrid&&s&&o)d=o.updateSegmentWidth(i.scale),u=s.updateSegmentWidth(i.scale),t.horizontalGridlines.scaledIntervals=[d/s.interval],t.verticalGridlines.scaledIntervals=[u/o.interval],p=!0;else{for(var S=0;S=2)for(;e>=2;)e/=2;else if(e<=.5)for(;e<=.5;)e*=2;var i;if(t.horizontalGridlines.scaledIntervals=t.horizontalGridlines.snapIntervals,t.verticalGridlines.scaledIntervals=t.verticalGridlines.snapIntervals,1!==e){var r=t.horizontalGridlines;for(r.scaledIntervals=[],i=0;ithis.groupElement.actualSize.height&&("Clip"===t.style.textOverflow||"Ellipsis"===t.style.textOverflow)&&(a.y=a.y+(a.height-this.groupElement.actualSize.height)/2),this.renderer.drawRectangle(e,a,this.diagramId,void 0,void 0,r),this.renderer.drawText(e,a,r,l,this.diagramId,t.isExport&&Math.min(t.exportScaleValue.x||t.exportScaleValue.y),this.groupElement),this.isSvgMode&&(t.doWrap=!1)},n.prototype.renderNativeElement=function(t,e,i,r,s){var o,a,l=this.getParentSvg(t,void 0,e)||r,h=this.getParentElement(t,e,l).g||e,c=this.getBaseAttributes(t,i);switch(c.fill="transparent",c.cornerRadius=t.cornerRadius,c.stroke="transparent",this.renderer.drawRectangle(e,c,this.diagramId,void 0,void 0,r),t.scale){case"None":o=t.contentSize.width,a=t.contentSize.height;break;case"Stretch":o=t.actualSize.width,a=t.actualSize.height;break;case"Meet":o=a=t.actualSize.width<=t.actualSize.height?t.actualSize.width:t.actualSize.height;break;case"Slice":o=a=t.actualSize.width>=t.actualSize.height?t.actualSize.width:t.actualSize.height}this.svgRenderer&&this.svgRenderer.drawNativeContent(t,h,a,o,l)},n.prototype.renderHTMLElement=function(t,e,i,r,s,o,a){var l=this.getBaseAttributes(t,r);l.fill="transparent",l.cornerRadius=t.cornerRadius,l.stroke="transparent",this.renderer.drawRectangle(e,l,this.diagramId,void 0,void 0,s),this.svgRenderer&&this.svgRenderer.drawHTMLContent(t,i.children[0],r,function Sse(n){var t=n.parentElement;do{if(fm(t,"e-diagram"))return!0;t=t.parentElement}while(t);return!1}(i),a)},n.prototype.renderImageElement=function(t,e,i,r,s){var o=this.getBaseAttributes(t,i);o.cornerRadius=0,this.renderer.drawRectangle(e,o,this.diagramId,void 0,void 0,r);var a,l,h,c,g,d=t.contentSize.width,u=t.contentSize.height,f=o.width/d,p=o.height/u;if("Stretch"===t.stretch)a=d*(g=Math.min(f,p)),l=u*g;else switch(t.stretch){case"Meet":a=d*(g=Math.min(f,p)),l=u*g,o.x+=Math.abs(o.width-a)/2,o.y+=Math.abs(o.height-l)/2;break;case"Slice":g=Math.max(f,p),h=o.width/(a=d*g)*d,c=o.height/(l=u*g)*u;break;case"None":a=d,l=u}o.width=a,o.height=l,o.sourceWidth=h,o.sourceHeight=c,o.source=t.source,o.alignment=t.imageAlign,o.scale=t.imageScale,o.description=t.description?t.description:t.id,this.renderer.drawImage(e,o,r,s)},n.prototype.renderContainer=function(t,e,i,r,s,o,a,l,h,c,d){var g,u={svg:s,g:e},f=document.getElementById(this.diagramId);if(f&&(g=f.ej2_instances[0]),this.diagramId&&(s=this.getParentSvg(t)||s,this.isSvgMode)){var v=this.getParentElement(t,e,s,l).g||e;s=this.getParentSvg(this.hasNativeParent(t.children))||s;var y=this.getParentElement(this.hasNativeParent(t.children),v,s,l);u.svg=y.svg||s,u.g=y.g||v,o&&s&&(s.getElementById(u.g.id)||e.appendChild(u.g)),e=u.g}if(this.renderRect(t,e,r,s),this.groupElement=t,t.hasChildren()){for(var b,S=void 0,M=0,w=t.children;M0&&(D=g.selectedItems.nodes[0]);var L,A=void 0,x=void 0,P=!1;if(g&&g.selectedItems&&(L=g.getObject(t.id)),"None"!==t.flip&&(D=L),"None"===t.flip&&(D=L),D&&D.flipMode&&(P=!0),!(t.elementActions&Xr.ElementIsGroup)&&g instanceof _l&&g.nameTable[t.id]&&"connectors"!==g.nameTable[t.id].propName&&P&&D){if(A=t.children&&t.children[0]instanceof En?document.getElementById(D.id+"_content_inner_native_element"):document.getElementById(D.id+"_content_groupElement"),!(t.children[0]instanceof En)&&"Text"!==D.shape.type&&"None"!==D.flipMode&&"Label"!==D.flipMode&&"All"!==D.flipMode&&"PortAndLabel"!==D.flipMode&&"LabelText"!==D.flipMode&&"PortAndLabelText"!==D.flipMode&&"LabelAndLabelText"!==D.flipMode||t.children[0]instanceof En&&"Port"===D.flipMode)return void this.renderFlipElement(t,A,D.flip);if((t.children[0]instanceof En&&("All"===D.flipMode||"Label"===D.flipMode)||"Label"===D.flipMode||"PortAndLabel"===D.flipMode||"LabelText"===D.flipMode||"PortAndLabelText"===D.flipMode||"LabelAndLabelText"===D.flipMode||"Image"===D.shape.type&&"Label"===D.flipMode)&&this.renderFlipElement(t,A,t.flip),"None"!==t.flip&&"None"===D.flipMode)this.renderFlipElement(t,A,t.flip);else if("None"!==t.flip&&("Label"===D.flipMode||"PortAndLabel"===D.flipMode||"LabelText"===D.flipMode||"PortAndLabelText"===D.flipMode||"LabelAndLabelText"===D.flipMode)||t.children[0]instanceof En&&"None"!==t.flip&&D&&("None"===D.flipMode||"All"===D.flipMode)){for(var O=0;O0){var i=t[0];if(i instanceof En)return i;i.children&&i.children.length&&this.hasNativeParent(i.children,e++||0)}},n.prototype.renderRect=function(t,e,i,r,s){var o=this.getBaseAttributes(t,i,s);o.cornerRadius=t.cornerRadius||0,t.isExport&&(o.cornerRadius*=t.exportScaleValue.x),this.renderer.drawRectangle(e,o,this.diagramId,t.isExport,void 0,r,t.description?t.description:t.id)},n.prototype.drawRect=function(t,e){e.cornerRadius=0,this.svgRenderer.drawRectangle(t,e,this.diagramId)},n.prototype.getBaseAttributes=function(t,e,i){var r={width:t.actualSize.width,height:t.actualSize.height,x:t.offsetX-t.actualSize.width*t.pivot.x,y:t.offsetY-t.actualSize.height*t.pivot.y,fill:t.style.fill,stroke:t.style.strokeColor,angle:t.rotateAngle+t.parentTransform,pivotX:t.pivot.x,pivotY:t.pivot.y,strokeWidth:t.style.strokeWidth,dashArray:t.style.strokeDashArray||"",opacity:t.style.opacity,shadow:t.shadow,gradient:t.style.gradient,visible:t.visible,id:t.id,description:t.description,canApplyStyle:t.canApplyStyle,shapeType:t.shapeType};return"Page"===t.rotationReference&&(r.angle=t.rotateAngle),i&&(r.x=r.x-.5,r.y=r.y-.5),t.isExport&&(r.width*=t.exportScaleValue.x,r.height*=t.exportScaleValue.y,r.x*=t.exportScaleValue.x,r.y*=t.exportScaleValue.y,r.strokeWidth*=t.exportScaleValue.x),t.flip&&(r.flip=t.flip),e&&(r.x+=e.tx,r.y+=e.ty),r},n.renderSvgBackGroundImage=function(t,e,i,r,s,o){if(t.source){var l=IT(e.id).getElementById(e.id+"_image");if(!l){var h=function Toe(n){return xt(n).getElementsByClassName("e-background-image-layer")[0]}(e.id);(l=document.createElementNS("http://www.w3.org/2000/svg","image")).setAttribute("id",e.id+"_image"),h.appendChild(l)}var c=new Image;c.src=t.source,l.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",c.src.toString());var d="None"!==t.scale?t.scale:"",u=t.align,f=u.charAt(0).toLowerCase()+u.slice(1);d&&(f+=" "+d.charAt(0).toLowerCase()+d.slice(1)),ti(l,{id:e.id+"_image",x:i,y:r,width:s,height:o,preserveAspectRatio:f})}},n.prototype.transformLayers=function(t,e){var i=t.tx*t.scale,r=t.ty*t.scale,s="domTable";if(i!==this.transform.x||r!==this.transform.y||0===i||0===r){e&&(window[""+s][this.diagramId+"_diagramLayer"]||(window[""+s][this.diagramId+"_diagramLayer"]=this.diagramSvgLayer.getElementById(this.diagramId+"_diagramLayer")),window[""+s][this.diagramId+"_diagramLayer"].setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+"),scale("+t.scale+")"));var a=function Aoe(n){var t="domTable",e=null;return window[t][n+"_gridline"]?e=window[t][n+"_gridline"]:(e=Fd(n).getElementById(n+"_gridline"),window[t][n+"_gridline"]=e),e}(this.diagramId);return a.setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+")"),window[""+s][this.diagramId+"_diagramPorts"]||(window[""+s][this.diagramId+"_diagramPorts"]=this.iconSvgLayer.getElementById(this.diagramId+"_diagramPorts")),window[""+s][this.diagramId+"_diagramPorts"].setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+"),scale("+t.scale+")"),window[""+s][this.diagramId+"_diagramExpander"]||(window[""+s][this.diagramId+"_diagramExpander"]=this.iconSvgLayer.getElementById(this.diagramId+"_diagramExpander")),window[""+s][this.diagramId+"_diagramExpander"].setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+"),scale("+t.scale+")"),window[""+s][this.diagramId+"_nativeLayer"]||(window[""+s][this.diagramId+"_nativeLayer"]=this.nativeSvgLayer.getElementById(this.diagramId+"_nativeLayer")),window[""+s][this.diagramId+"_nativeLayer"].setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+"),scale("+t.scale+")"),Io(this.diagramId).children[0].style.transform="translate("+t.tx*t.scale+"px,"+t.ty*t.scale+"px)scale("+t.scale+")",this.transform={x:t.tx*t.scale,y:t.ty*t.scale},!0}return!1},n.prototype.updateNode=function(t,e,i,r,s,o,a){this.renderElement(t,e,i,r,this.getParentSvg(t),void 0,void 0,s,null,o,a)},n}(),use=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),ib=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},uF=function(n){function t(e,i){var r=n.call(this,e,i)||this;return r.mode="Canvas",r.id="overview",r.actionName="",r.startPoint=null,r.currentPoint=null,r.prevPoint=null,r.scale=null,r.inAction=!1,r.viewPortRatio=1,r.horizontalOffset=0,r.verticalOffset=0,r.model={},r.event=!0,r.overviewid=88123,r.model={width:r.width,height:r.height},r}return use(t,n),t.prototype.onPropertyChanged=function(e,i){for(var r=0,s=Object.keys(e);r0||e.toString().indexOf("%")>0?e.toString():e.toString()+"px"},t.prototype.renderCanvas=function(e){var i=document.getElementById(this.element.id+"_canvas");i||(i=Tt("div",{}),this.element.appendChild(i)),Ho(i,{id:this.element.id+"_canvas",class:"drawing",style:"position:relative; height:"+this.getSizeValue(this.model.height)+"; width:"+this.getSizeValue(this.model.width)+";style:-ms-touch-action: none;touch-action: none;"}),this.element.setAttribute("tabindex",String(-1)),this.element.style.overflow="hidden",this.element.style.height=String(this.model.height),this.element.style.width=String(this.model.width),this.canvas=i},t.prototype.setParent=function(e){var i=document.getElementById(e);if(this.parent){var s=this.parent;this.parent=null,s.setOverview(null,this.element.id),this.removeDocument(this)}this.parent=this.getDiagram(i,"ej2_instances"),this.parent&&this.parent.setOverview(this)},t.prototype.getDiagram=function(e,i){for(var r,s=e[""+i].length,o=0;o0?f:Math.floor(window.innerWidth)}if(0===h){var p=Math.floor(window.innerHeight-u-Math.floor(c.top));h=p>0?p:Math.floor(window.innerHeight)}l>0&&(s.setAttribute("width",String(l)),this.model.height=h),h>0&&(s.setAttribute("height",String(h)),this.model.width=l),e.diagramLayerDiv||(e.diagramLayerDiv=Tt("div",{}),e.diagramLayer=bo.createCanvas(this.element.id+"_diagramLayer",this.model.width,this.model.height),e.diagramLayer.setAttribute("style","position:absolute; left:0px; top:0px "),e.diagramLayerDiv.appendChild(e.diagramLayer),e.canvas.appendChild(e.diagramLayerDiv)),Ho(e.diagramLayerDiv,{id:this.element.id+"_diagramLayer_div",style:"width:"+this.model.width+"px; height:"+this.model.height+"px;position:absolute;top:0px;left:0px"}),this.renderHtmlLayer(e.canvas),this.renderNativeLayer(e.canvas,e),this.addOverviewRectPanel(e)},t.prototype.removeDocument=function(e){var i=document.getElementById(this.canvas.id+"_svg");this.canvas.removeChild(i);var r=document.getElementById(this.element.id+"_htmlLayer");this.canvas.removeChild(r);var s=document.getElementById(this.element.id+"_diagramLayer_div");this.canvas.removeChild(s),e.diagramLayerDiv=null,e.diagramLayer=null,window.domTable[this.id+"html_layer"]=null},t.prototype.renderHtmlLayer=function(e){var i=Tt("div",{id:this.element.id+"_htmlLayer",class:"e-html-layer",style:"pointer-events:none;position:absolute;top:0px;left:0px;"}),s=Tt("div",{id:this.element.id+"_htmlLayer_div",style:"position:absolute;top:0px;left:0px;"});return i.appendChild(s),e.appendChild(i),i},t.prototype.renderNativeLayer=function(e,i){if(!document.getElementById(this.element.id+"_nativeLayer_svg")){var r=this.parent.createSvg(this.element.id+"_nativeLayer_svg",this.model.width,this.model.height),s=Fi("g",{id:this.element.id+"_nativeLayer"});r.appendChild(s),i.diagramLayerDiv.appendChild(r),ti(r,{class:"e-native-layer"})}},t.prototype.addOverviewRectPanel=function(e){var i=document.getElementById(this.canvas.id+"_overviewsvg");i&&i.parentNode.removeChild(i),i=Fi("svg",{id:this.canvas.id+"_overviewsvg",class:"overviewsvg",version:"1.1",style:"position:absolute;left:0px;top:0px; aria-label:Specifies overview",width:this.model.width,height:this.model.height}),e.canvas.appendChild(i);var s=Fi("g",{id:this.element.id+"_overviewlayer",style:"pointer-events:none"});i.appendChild(s);var o=Fi("rect",{fill:"transparent",width:"100%",height:"100%",class:"overviewbackrect",id:this.canvas.id+"overviewbackrect"});o.setAttribute("style"," pointer-events: none; "),s.appendChild(o);var a=Fi("g",{id:this.canvas.id+"overviewhandle",style:"pointer-events:all"});s.appendChild(a);var l=Fi("rect",{id:this.canvas.id+"overviewrect",fill:"transparent"});a.appendChild(l),this.renderOverviewCorner("left",a),this.renderOverviewCorner("right",a),this.renderOverviewCorner("top",a),this.renderOverviewCorner("bottom",a),this.renderOverviewCorner("topleft",a),this.renderOverviewCorner("topright",a),this.renderOverviewCorner("bottomleft",a),this.renderOverviewCorner("bottomright",a)},t.prototype.renderOverviewCorner=function(e,i){var s,o=Fi(s="top"===e||"bottom"===e||"right"===e||"left"===e?"rect":"circle",{id:this.canvas.id+"visible"+e,class:"overview-resizer"});i.appendChild(o);var a=Fi(s,{id:this.canvas.id+e,class:"overviewresizer",fill:"transparent"});i.appendChild(a)},t.prototype.updateOverviewRectangle=function(){var e=this.currentPoint.x-this.prevPoint.x,i=this.currentPoint.y-this.prevPoint.y,r=new me;r.width=0,r.height=0;var s=0,o=0;switch(this.resizeDirection){case"left":r.width-=e,r.height-=e/this.viewPortRatio,s=e,o=e/this.viewPortRatio,o/=2;break;case"right":r.width+=e,r.height+=e/this.viewPortRatio,o=e/this.viewPortRatio,o/=-2;break;case"top":r.height-=i,r.width-=i*this.viewPortRatio,o=i,s=i*this.viewPortRatio,s/=2;break;case"bottom":r.height+=i,r.width+=i*this.viewPortRatio,s=i*this.viewPortRatio,s/=-2;break;case"topleft":Math.abs(i)>Math.abs(e)?e=i*this.viewPortRatio:i=e/this.viewPortRatio,r.width-=e,r.height-=i,s=e,o=i;break;case"topright":Math.abs(i)>Math.abs(e)?e=-i*this.viewPortRatio:i=-e/this.viewPortRatio,o=i,r.width+=e,r.height-=i;break;case"bottomleft":Math.abs(i)>Math.abs(e)?e=-i*this.viewPortRatio:i=-e/this.viewPortRatio,s=e,r.width-=e,r.height+=i;break;case"bottomright":Math.abs(i)>Math.abs(e)?e=i*this.viewPortRatio:i=e/this.viewPortRatio,r.width+=e,r.height+=i}this.updateHelper(s,o,r,void 0,void 0)},t.prototype.updateHelper=function(e,i,r,s,o){var a,l,h,u,f,d=this.element.getElementsByTagName("svg")[2].getElementById("helper");r?(a=(h=d.getBBox()).x+e,l=h.y+i,s=h.width+r.width,o=h.height+r.height):(u=this.currentPoint.x>this.startPoint.x?this.currentPoint.x-this.prevPoint.x:this.prevPoint.x-this.currentPoint.x,f=this.currentPoint.y>this.startPoint.y?this.currentPoint.y-this.prevPoint.y:this.prevPoint.y-this.currentPoint.y,Math.abs(f)>Math.abs(u)?u=this.viewPortRatio*f:f=u/this.viewPortRatio,h=d.getBBox(),a=this.startPoint.x>this.currentPoint.x?h.x-u:h.x,l=this.startPoint.y>this.currentPoint.y?h.y-f:h.y,s=h.width+u,o=h.height+f),ti(this.helper,{id:this.helper.id,x:a,y:l,width:Math.max(0,s),height:Math.max(0,o)})},t.prototype.updateOverviewrect=function(e,i,r,s){Ho(document.getElementById(this.canvas.id+"overviewrect"),{x:e,y:i,width:Math.max(1,r),height:Math.max(1,s)}),this.updateOverviewCorner("top",e+8,i+1,Math.max(0,r-16),2),this.updateOverviewCorner("bottom",e+8,i+s+3,Math.max(0,r-16),2),this.updateOverviewCorner("left",e-2,i+11,2,Math.max(0,s-16)),this.updateOverviewCorner("right",e+r,i+11,2,Math.max(0,s-16)),this.updateOverviewCorner("topleft",e,i+3,5,5),this.updateOverviewCorner("topright",e+r,i+3,5,5),this.updateOverviewCorner("bottomleft",e,i+s+3,5,5),this.updateOverviewCorner("bottomright",e+r,i+s+3,5,5)},t.prototype.updateOverviewCorner=function(e,i,r,s,o){var a,l;"top"===e||"bottom"===e||"right"===e||"left"===e?(a={x:i,y:r,width:s,height:o,fill:"#ED1C24"},l={x:i-2,y:r-2,width:2===s?4:s,height:2===o?4:o}):(a={cx:i,cy:r,r:4,fill:"#ED1C24"},l={cx:i,cy:r,r:6,fill:"transparent"}),Ho(document.getElementById(this.canvas.id+"visible"+e),a),Ho(document.getElementById(this.canvas.id+e),l)},t.prototype.translateOverviewRectangle=function(){Number(this.model.width),Number(this.model.height);var r=this.currentPoint.x-this.prevPoint.x,s=this.currentPoint.y-this.prevPoint.y,l=this.element.getElementsByClassName("overviewsvg")[0].getElementById(this.canvas.id+"overviewrect").getBBox(),h=l.x+r,c=l.y+s,d=l.width,u=l.height;this.updateOverviewrect(h,c,d,u),this.updateParentView(this.parent.scroller.currentZoom,h,c,d,u,null)},t.prototype.renderOverviewRect=function(e,i,r,s){var o=Number(this.model.width),a=Number(this.model.height),c=Math.max(this.parent.scroller.viewPortWidth/(r/o*this.contentWidth),this.parent.scroller.viewPortHeight/(s/a*this.contentHeight));if(c>=.25&&c<=30){this.updateParentView(c,e,i,r,s,{x:0,y:0});var u=this.scrollOverviewRect(this.parent.scroller.horizontalOffset,this.parent.scroller.verticalOffset,this.parent.scroller.currentZoom,!0);if(this.helper){var p=this.element.getElementsByTagName("rect")[10].getBBox();u.x=p.x,u.y=p.y}"pan"===this.actionName?this.updateOverviewrect(-u.x,-u.y,u.width,u.height):this.updateOverviewrect(u.x,u.y,u.width,u.height)}},t.prototype.scrollOverviewRect=function(e,i,r,s){if(!this.actionName||s){var o=Number(this.model.width),a=Number(this.model.height),l=Math.min(this.contentWidth/o,this.contentHeight/a),h=new Ne,c=h.x=e/r/l,d=h.y=i/r/l,u=0;this.parent.rulerSettings.showRulers&&(u=25);var f=document.getElementById(this.parent.element.id+"content"),p=0,g=0;f&&(p=f.offsetWidth-f.clientWidth,g=f.offsetHeight-f.clientHeight);var v=h.width=(this.parent.scroller.viewPortWidth-u-p)/r/l,y=h.height=(this.parent.scroller.viewPortHeight-u-g)/r/l;if(s){var S=new Ne;return S.x=c,S.y=d,S.width=v,S.height=y,S}this.updateOverviewrect(-c,-d,v,y)}return null},t.prototype.updateParentView=function(e,i,r,s,o,a){var p,g,l=Number(this.model.width),h=Number(this.model.height),u=i*(this.contentWidth/l)*e,f=r*(this.contentHeight/h)*e;this.parent.scroller.getPageBounds(),(1!==e||"pan"===this.actionName)&&(p=-u-this.parent.scroller.horizontalOffset,g=-f-this.parent.scroller.verticalOffset),this.parent.setBlazorDiagramProps(!0),this.parent.realActions|=$i.OverViewAction,"scale"===this.actionName||"draw"===this.actionName?this.parent.scroller.zoom(e/this.parent.scroller.currentZoom,p,g,a):ce()?this.parent.scroller.zoom(1,p,g,a):this.parent.pan(p,g,a,!0)},t.prototype.updateHtmlLayer=function(e){var i=Io(e.element.id),r=this.parent.scroller.getPageBounds(!0),o=r.height,a=Math.max(r.width,this.parent.scroller.viewPortWidth),l=Math.max(o,this.parent.scroller.viewPortHeight/this.parent.scroller.currentZoom),h=Math.min(Number(this.model.width)/a,Number(this.model.height)/l);i.style.transform="scale("+h+") translate("+this.parent.scroller.transform.tx+"px,"+this.parent.scroller.transform.ty+"px)"},t.prototype.updateView=function(e){var i=this.parent.scroller.getPageBounds(),r=i.width,s=i.height,o=Number(this.model.width),a=Number(this.model.height),l=Math.max(r,this.parent.scroller.viewPortWidth),h=Math.max(s,this.parent.scroller.viewPortHeight);this.contentWidth=l=Math.max(l,o/a*h),this.contentHeight=h=Math.max(h,a/o*l);var c=Math.min(o/l,a/h),d=document.getElementById(this.element.id+"_htmlLayer");d.style.webkitTransform="scale("+c+") translate("+-i.x+"px,"+-i.y+"px)",d.style.transform="scale("+c+") translate("+-i.x+"px,"+-i.y+"px)",document.getElementById(this.element.id+"_overviewlayer").setAttribute("transform","translate("+-i.x*c+","+-i.y*c+")"),this.horizontalOffset=i.x*c,this.verticalOffset=i.y*c;var f=document.getElementById(this.element.id+"_diagramLayer"),p=UF(this.element.id),g=f.getContext("2d"),v=Number(this.model.width)/this.contentWidth,y=Number(this.model.height)/this.contentHeight;v=Math.min(v,y);var S=this.parent.scroller.transform;p.setAttribute("transform","translate("+S.tx*v+","+S.ty*y+"),scale("+v+")"),g.setTransform(v,0,0,v,0,0),g.fillStyle="red",this.scrollOverviewRect(this.parent.scroller.horizontalOffset,this.parent.scroller.verticalOffset,this.parent.scroller.currentZoom)},t.prototype.scrolled=function(e){if(this.event){var i=this.scrollOverviewRect(this.parent.scroller.horizontalOffset,this.parent.scroller.verticalOffset,this.parent.scroller.currentZoom,!0);this.updateOverviewrect(-i.x,-i.y,i.width,i.height),this.updateView(this)}},t.prototype.updateCursor=function(e){if(fm(e.target,"overviewresizer"))switch(e.target.id){case this.canvas.id+"left":this.canvas.style.cursor="w-resize";break;case this.canvas.id+"right":this.canvas.style.cursor="e-resize";break;case this.canvas.id+"top":this.canvas.style.cursor="n-resize";break;case this.canvas.id+"bottom":this.canvas.style.cursor="s-resize";break;case this.canvas.id+"topleft":this.canvas.style.cursor="nw-resize";break;case this.canvas.id+"topright":this.canvas.style.cursor="ne-resize";break;case this.canvas.id+"bottomleft":this.canvas.style.cursor="sw-resize";break;case this.canvas.id+"bottomright":this.canvas.style.cursor="se-resize"}else this.canvas.style.cursor="default"},t.prototype.mouseMove=function(e){if(this.event=!1,this.updateCursor(e),this.currentPoint=this.mousePosition(e),this.actionName)switch(this.actionName){case"draw":!this.inAction&&(this.startPoint.x!==this.currentPoint.x||this.startPoint.y!==this.currentPoint.y)&&(this.initHelper(),this.inAction=!0),this.inAction&&this.updateHelper();break;case"scale":this.inAction||(this.initHelper(),this.inAction=!0),this.updateOverviewRectangle();break;case"pan":(this.startPoint.x!==this.currentPoint.x||this.startPoint.y===this.currentPoint.y||this.inAction)&&(this.inAction=!0,this.translateOverviewRectangle())}this.prevPoint=this.currentPoint},t.prototype.documentMouseUp=function(e){this.inAction=!1,this.actionName="",this.helper&&(this.helper.parentNode.removeChild(this.helper),this.helper=null),this.event=!0,document.getElementById(this.canvas.id+"overviewhandle").style.pointerEvents="all"},t.prototype.windowResize=function(e){var i=this;return this.resizeTo&&clearTimeout(this.resizeTo),this.resizeTo=setTimeout(function(){var s=document.getElementById(i.element.id).getBoundingClientRect();i.model.width=s.width>0?s.width:i.model.width,i.model.height=s.height>0?s.height:i.model.height,i.renderCanvas(),i.setParent(i.sourceID)},10),!1},t.prototype.mouseDown=function(e){if(e.target.id===this.canvas.id+"_overviewsvg"&&(this.actionName="draw"),e.target.id===this.canvas.id+"overviewrect"&&(this.actionName="pan"),fm(e.target,"overviewresizer"))switch(this.actionName="scale",e.target.id){case this.canvas.id+"left":this.resizeDirection="left";break;case this.canvas.id+"right":this.resizeDirection="right";break;case this.canvas.id+"top":this.resizeDirection="top";break;case this.canvas.id+"bottom":this.resizeDirection="bottom";break;case this.canvas.id+"topleft":this.resizeDirection="topleft";break;case this.canvas.id+"topright":this.resizeDirection="topright";break;case this.canvas.id+"bottomleft":this.resizeDirection="bottomleft";break;case this.canvas.id+"bottomright":this.resizeDirection="bottomright"}this.startPoint=this.prevPoint=this.mousePosition(e),this.viewPortRatio=this.parent.scroller.viewPortWidth/this.parent.scroller.viewPortHeight,document.getElementById(this.canvas.id+"overviewhandle").style.pointerEvents="none"},t.prototype.mouseUp=function(e){if(this.currentPoint=this.mousePosition(e),this.actionName)if(this.startPoint.x!==this.currentPoint.x||this.startPoint.y!==this.currentPoint.y){if("pan"!==this.actionName&&this.helper){var i=this.element.getElementsByTagName("rect")[10].getBBox();this.resizeDirection=this.resizeDirection||"",this.renderOverviewRect(i.x,i.y,o=i.width,a=i.height)}}else if(e.target.id===this.canvas.id+"_overviewsvg"||"helper"===e.target.id){var o=(i=this.element.getElementsByTagName("svg")[2].getElementById(this.canvas.id+"overviewrect").getBBox()).width,a=i.height;this.inAction=!0,this.actionName="pan",this.renderOverviewRect(this.currentPoint.x-o/2,this.currentPoint.y-a/2,o,a),this.inAction=!1}this.helper&&(this.helper.parentNode.removeChild(this.helper),this.helper=null),this.actionName="",this.startPoint=null,this.currentPoint=null,this.prevPoint=null,this.helper=null,this.viewPortRatio=1,this.resizeDirection="",this.inAction=!1,this.event=!0,document.getElementById(this.canvas.id+"overviewhandle").style.pointerEvents="all"},t.prototype.initHelper=function(){var e=this.element.getElementsByTagName("svg")[2],i=this.startPoint.x,r=this.startPoint.y,s=1,o=1;if("scale"===this.actionName){var l=e.getElementById(this.canvas.id+"overviewrect").getBBox();i=l.x,r=l.y,s=l.width,o=l.height}var h=Fi("rect",{id:"helper",x:i,y:r,width:s,height:o,fill:"transparent",stroke:"gray","stroke-dasharray":"2 2","shape-rendering":"crispEdges"});e.getElementById(this.element.id+"_overviewlayer").appendChild(h),this.helper=h},t.prototype.mousePosition=function(e){var i,r,s;-1!==e.type.indexOf("touch")?(r=(i=e).changedTouches[0].clientX-this.element.offsetLeft,s=i.changedTouches[0].clientY-this.element.offsetTop):(r=e.clientX,s=e.clientY);var l=this.element.getBoundingClientRect();return{x:(r-=l.left)+this.horizontalOffset,y:(s-=l.top)+this.verticalOffset}},t.prototype.destroy=function(){if(this.unWireEvents(),this.notify("destroy",{}),n.prototype.destroy.call(this),document.getElementById(this.element.id)){this.element.classList.remove("e-overview");var e=document.getElementById(this.element.id+"_canvas");e&&this.element.removeChild(e)}this.parent.views.splice(this.parent.views.indexOf(this.element.id),1),this.diagramLayerDiv=null,this.canvas=null,this.parent=null},t.prototype.getModuleName=function(){return"Overview"},ib([I("100%")],t.prototype,"width",void 0),ib([I("100%")],t.prototype,"height",void 0),ib([I("")],t.prototype,"sourceID",void 0),ib([H()],t.prototype,"created",void 0),t}(Ii);function pse(n,t){for(var e=0;eR.findLength(e,n)?e:t;var o=R.findAngle(t,e),a=R.findAngle(i,n),l=R.findLength(i,n),h=a+2*(o-a);return{x:i.x+l*Math.cos(h*Math.PI/180),y:i.y+l*Math.sin(h*Math.PI/180)}}function Kf(n,t,e){if(n&&n.children&&n.children.length>0)for(var r=void 0,s=0;s0&&"annotations"!==r&&"ports"!==r)if(n[""+l].length>0)for(var h=0;h<=n[""+l].length;h++)Ro(n[""+l],t?t[""+l]:void 0,e[""+l],"annotations"===l||"ports"===l?n:void 0,l);else Ro(n[""+l],t?t[""+l]:void 0,e[""+l],"annotations"===l||"ports"===l?n:void 0,l);else if(s instanceof Object&&t&&"annotations"!==r&&"ports"!==r)Ro(n[""+l],t[""+l],e[""+l]);else if("annotations"!==r&&"ports"!==r&&t&&!t[""+l]||!t&&n&&(n[""+l]||void 0!==n[""+l]))n[""+l]=e[""+l];else{var c=void 0;("annotations"===r||"ports"===r)&&("annotations"===r?(n[""+l]&&Ro(n[""+l],t[""+l],e[""+l]),n[""+l]||(ps(i)===de?(c=new Or(i,"annotations",e[""+l]),i.annotations.push(c)):(c=new Kn(i,"annotations",e[""+l]),i.annotations.push(c)))):n[""+l]?Ro(n[""+l],t[""+l],e[""+l]):(c=new Es(i,"ports",e[""+l]),i.ports.push(c)))}}}function bse(n,t){for(var e="Bezier"===n.type?function yse(n){var t=[];if("Bezier"===n.type)for(var e=0,i=0;i0||n.ports.length>0){var f=n.wrapper.children;for(i=3;i0)return{enabled:!1,intersectPt:e};var l=o/s,h=a/s;return l>=0&&l<=1&&h>=0&&h<=1?(e.x=i.x1+l*(i.x2-i.x1),e.y=i.y1+l*(i.y2-i.y1),{enabled:!0,intersectPt:e}):{enabled:!1,intersectPt:e}}function nb(n,t,e,i){var a=im(vF(n.x,n.y,t.x,t.y),vF(e.x,e.y,i.x,i.y));return a.enabled?a.intersectPt:{x:0,y:0}}function vF(n,t,e,i){return{x1:Number(n)||0,y1:Number(t)||0,x2:Number(e)||0,y2:Number(i)||0}}function mF(n,t,e){var i=[],s={x:t.topRight.x+(e=e||0),y:t.topRight.y},o={x:t.bottomRight.x,y:t.bottomRight.y-e},a={x:t.bottomLeft.x,y:t.bottomLeft.y+e};return i.push({x:t.topLeft.x-e,y:t.topLeft.y}),i.push(s),i.push(o),i.push(a),i}function zc(n,t,e,i,r,s){var o={},a=e.scroller.transform.scale,h=e.scroller.verticalOffset;return o.x=(i?n.x:t.x)*a+e.scroller.horizontalOffset-r,o.y=(i?n.y:t.y)*a+h-s,o}function yF(n,t){var e=new Ze;return e.data=n.pathData,e.height=n.height>10?n.height-(n.padding.bottom+n.padding.top):n.height,e.width=n.width>10?n.width-(n.padding.left+n.padding.right):n.width,e.visible=n.visibility,e.id=t.id+"_shape",e.inversedAlignment=!1,e.horizontalAlignment="Center",e.verticalAlignment="Center",e.style={fill:n.iconStrokeColor,strokeColor:n.iconStrokeColor,strokeWidth:n.iconStrokeWidth},e.setOffsetWithRespectToBounds(.5,.5,"Fraction"),e.relativeMode="Object",e.description=t.description||"",e}function Zx(n,t,e){var i=Jx(n,t),r=R.findAngle(n[i.index],n[i.index+1]),s=function Tse(n){var t;t=n instanceof OI?0:void 0===n.content?10:0;var e=0;switch(n.alignment){case"Center":e=0;break;case"Before":e=-(0+t);break;case"After":e=0+t}return e}(t),o=R.transform(i.point,r+45,s);return i.point=o,i.angle=r,i}function Jx(n,t){for(var r,s,a,l,e=0,i=t.offset,o=[],h=0;h=c)return s=R.findAngle(n[parseInt(d.toString(),10)],n[d+1]),{point:r=R.transform(n[parseInt(d.toString(),10)],s,c-(a||0)),index:l=d};a=o[parseInt(d.toString(),10)]}return{point:r,index:l}}function SF(n,t,e){t%=360;var a,l,s=225;switch(n.alignment){case"Before":t>=45&&t<=135?(l="right",a=.5===n.offset?"center":"top"):t>=s&&t<=315?(l="left",a=.5===n.offset?"center":"bottom"):t>45&&t=45&&t<=135?(l="left",a=.5===n.offset?"center":"top"):t>=s&&t<=315?(l="right",a=.5===n.offset?"center":"bottom"):t>45&&tMath.abs(t.y-n.y)?n.x0)for(var e=0;e=0;r--)("nodes"===i||"connectors"===i)&&(n[""+i][parseInt(r.toString(),10)].wrapper=null),"dataManager"!==i&&(n[""+i][parseInt(r.toString(),10)]=tT(n[""+i][parseInt(r.toString(),10)],e[""+i][parseInt(r.toString(),10)],void 0!==t[""+i]?t[""+i][parseInt(r.toString(),10)]:[]),("[]"===JSON.stringify(n[""+i][parseInt(r.toString(),10)])||"{}"===JSON.stringify(n[""+i][parseInt(r.toString(),10)])||void 0===n[""+i][parseInt(r.toString(),10)])&&n[""+i].splice(r,1));n=void 0}function Hh(n,t){var e=t.style,i=t;t.canApplyStyle=!0;for(var r=0,s=Object.keys(n);r=0&&n.splice(e,1)}function ep(n,t,e){var i;n.intermediatePoints=t,n.updateSegmentElement(n,t,n.wrapper.children[0],e);var r=n.sourceDecorator;if("Bezier"===n.type){var s=n.segments[0],o=n.segments[n.segments.length-1];i=[R.isEmptyPoint(o.point2)?o.bezierPoint2:o.point2,R.isEmptyPoint(s.point1)?s.bezierPoint1:s.point1]}else i=n.intermediatePoints;t=n.clipDecorators(n,t,e);var a=n.wrapper.children[0];a.canMeasurePath=!0,n.updateDecoratorElement(a=n.wrapper.children[1],t[0],i[1],r),n.updateDecoratorElement(a=n.wrapper.children[2],t[t.length-1],i[i.length-2],n.targetDecorator),n.updateShapeElement(n)}function iT(n,t,e){var l,i=n.wrapper,s=t.offset,o=t.size/e.scale,a=t.margin,h=i.offsetX-i.actualSize.width*i.pivot.x,c=i.offsetY-i.actualSize.height*i.pivot.y;if(l={x:0,y:0},n.nodes.length>0){switch(t.side){case"Top":l.x+=h+s*i.actualSize.width,l.y+=c-o;break;case"Bottom":l.x+=h+s*i.actualSize.width,l.y+=c+i.actualSize.height+o;break;case"Left":l.x+=h-o,l.y+=c+s*i.actualSize.height;break;case"Right":l.x+=h+i.actualSize.width+o,l.y+=c+s*i.actualSize.height}l.x+=(a.left-a.right)/e.scale+o/2*("Center"===t.horizontalAlignment?0:"Right"===t.horizontalAlignment?-1:1),l.y+=(a.top-a.bottom)/e.scale+o/2*("Center"===t.verticalAlignment?0:"Top"===t.verticalAlignment?-1:1)}else if(n.connectors.length>0){var d=n.connectors[0],u={offset:s},f=Jx(d.intermediatePoints,u),p=f.index;l=f.point;var y,v=Zx(d.intermediatePoints,u).angle;qi(y=Bi(),-v,d.intermediatePoints[parseInt(p.toString(),10)].x,d.intermediatePoints[parseInt(p.toString(),10)].y),(l=Ke(y,l)).x+=a.left-a.right+o/2*("Center"===t.horizontalAlignment?0:"Right"===t.horizontalAlignment?-1:1),l.y+=a.top-a.bottom+o/2*("Center"===t.verticalAlignment?0:"Top"===t.verticalAlignment?-1:1),qi(y=Bi(),v,d.intermediatePoints[parseInt(p.toString(),10)].x,d.intermediatePoints[parseInt(p.toString(),10)].y),l=Ke(y,l)}return 0===i.rotateAngle&&0===i.parentTransform||(qi(y=Bi(),i.rotateAngle+i.parentTransform,i.offsetX,i.offsetY),l=Ke(y,l)),l}function ga(n,t,e,i){if(i.annotation){if(zl(i.annotation))return!0}else if(mr[""+t]&n&&bt[""+t]&e)return!0;return!1}function qr(n,t){return!!(mr[""+t]&n)}function Hc(n,t){return!!(Cx[""+t]&n)}function va(n,t){return n.visibility&t}function sb(n,t){var e;if("Text"===n.shape.type)e=n.shape;else{var i=t.split("_");t=i[i.length-1];for(var r=0;rn[""+t]?e.splice(0,0,n):e.push(n);else if(e.length>1){for(var i=0,r=e.length-1,s=Math.floor((i+r)/2);s!==i;)if(e[parseInt(s.toString(),10)][""+t]n[""+t]))break;r=s,s=Math.floor((i+r)/2)}e[parseInt(r.toString(),10)][""+t]n[""+t]?e.splice(i,0,n):e[parseInt(i.toString(),10)][""+t]n[""+t]&&e.splice(r,0,n)}}function Qse(n){var t=document.getElementById(n.diagramId),e="ej2_instances",i=t[""+e][0].nodes;void 0===i&&(i=function Gse(n){for(var t=[],e=0;e30?10:o/2;for(var h=0,c=0;c=l){var u=l-h;r=Gt(n[c],n[c+1]),s=R.transform(n[c],r,u);break}h+=d}return s},lb=function(n,t){if(n instanceof te||n instanceof de)for(var e=0;e=0||navigator.platform.indexOf("iPad")>=0||navigator.platform.indexOf("iPhone")>=0||navigator.platform.indexOf("MacIntel")>=0)&&("safari"===X.info.name||"webkit"===X.info.name)}function AF(n,t,e,i){return void 0!==t.previewSize[""+i]?t.previewSize[""+i]:void 0!==n.symbolPreview[""+i]?n.symbolPreview[""+i]:t[""+i]||e.actualSize[""+i]}function am(n,t,e){return n&&n.parentId&&(e=(n=t.nameTable[n.parentId]).parentId?am(n,t,e):n.id),e}function lm(n,t){return n.selectedItems.connectors.length>1&&0===n.selectedItems.nodes.length&&0!==t.rotateAngle}function Zse(n){if(n.arrowType&&""!==n.arrowType.trim())switch(n.arrowType){case"single-line-arrow":default:return{targetDecorator:"Arrow",strokeWidth:1};case"double-line-arrow":return{targetDecorator:"Arrow",strokeWidth:2};case"dotted-arrow":return{targetDecorator:"Arrow",strokeDashArray:"2,2"};case"single-line":return{targetDecorator:"None",strokeWidth:1};case"double-line":return{targetDecorator:"None",strokeWidth:2};case"dotted":return{targetDecorator:"None",strokeDashArray:"2,2"};case"wiggly-arrow":return{targetDecorator:"None",strokeWidth:1,opacity:0}}return{targetDecorator:"Arrow",strokeWidth:1}}var Jse=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),no=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},LF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Jse(t,n),no([I("None")],t.prototype,"shape",void 0),no([I("white")],t.prototype,"fill",void 0),no([I("Auto")],t.prototype,"horizontalAlignment",void 0),no([I("Auto")],t.prototype,"verticalAlignment",void 0),no([I(10)],t.prototype,"width",void 0),no([I(10)],t.prototype,"height",void 0),no([re({x:.5,y:1},R)],t.prototype,"offset",void 0),no([I("#1a1a1a")],t.prototype,"borderColor",void 0),no([I(1)],t.prototype,"borderWidth",void 0),no([re({},Jn)],t.prototype,"margin",void 0),no([I("")],t.prototype,"pathData",void 0),no([I("")],t.prototype,"content",void 0),no([I(0)],t.prototype,"cornerRadius",void 0),no([re({left:2,right:2,top:2,bottom:2},Jn)],t.prototype,"padding",void 0),no([I("#1a1a1a")],t.prototype,"iconColor",void 0),t}(Ee),Kse=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),oT=function(n){function t(){var e=null!==n&&n.apply(this,arguments)||this;return e.orientation="Vertical",e.measureChildren=void 0,e.considerPadding=!0,e}return Kse(t,n),t.prototype.measure=function(e){return this.desiredSize=this.measureStackPanel(e,"Horizontal"===this.orientation?this.updateHorizontalStack:this.updateVerticalStack),this.desiredSize},t.prototype.arrange=function(e){return this.actualSize=this.arrangeStackPanel(e,"Horizontal"===this.orientation?this.arrangeHorizontalStack:this.arrangeVerticalStack),this.updateBounds(),this.actualSize},t.prototype.measureStackPanel=function(e,i){var r=void 0;if(void 0!==this.children&&this.children.length>0)for(var s=0,o=this.children;s0){var r=void 0,s=void 0;r=this.offsetX-e.width*this.pivot.x+this.padding.left,s=this.offsetY-e.height*this.pivot.y+this.padding.top;for(var o=0,a=this.children;o0)for(var i=0,r=this.children;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},aoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return ooe(t,n),Bh([I("Horizontal")],t.prototype,"orientation",void 0),Bh([I("Center")],t.prototype,"type",void 0),Bh([I(void 0)],t.prototype,"offset",void 0),Bh([I(!1)],t.prototype,"enableRouting",void 0),Bh([I([])],t.prototype,"children",void 0),Bh([I("")],t.prototype,"assistants",void 0),Bh([I("")],t.prototype,"level",void 0),Bh([I("")],t.prototype,"hasSubTree",void 0),Bh([I("")],t.prototype,"rows",void 0),t}(Ee),Ni=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),q=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},loe=function(n){if(n)switch(n.type){case"Basic":default:return hb;case"Flow":return PF;case"Path":return NF;case"Image":return kF;case"Text":return zd;case"Bpmn":return uT;case"Native":return hm;case"HTML":return OF;case"UmlActivity":return zF;case"UmlClassifier":return RF;case"SwimLane":return Bd}return hb},ma=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),q([I("Basic")],t.prototype,"type",void 0),t}(Ee),NF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"Path"},q([I("Path")],t.prototype,"type",void 0),q([I("")],t.prototype,"data",void 0),t}(ma),hm=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"Native"},q([I("Native")],t.prototype,"type",void 0),q([I("")],t.prototype,"content",void 0),q([I("Stretch")],t.prototype,"scale",void 0),t}(ma),OF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"Html"},q([I("HTML")],t.prototype,"type",void 0),q([I("")],t.prototype,"content",void 0),t}(ma),kF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"Image"},q([I("Image")],t.prototype,"type",void 0),q([I("")],t.prototype,"source",void 0),q([I("None")],t.prototype,"scale",void 0),q([I("None")],t.prototype,"align",void 0),t}(ma),zd=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"Text"},q([I("Text")],t.prototype,"type",void 0),q([I("")],t.prototype,"content",void 0),q([re({},Jn)],t.prototype,"margin",void 0),t}(ma),hb=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"BasicShape"},q([I("Basic")],t.prototype,"type",void 0),q([I("Rectangle")],t.prototype,"shape",void 0),q([I(0)],t.prototype,"cornerRadius",void 0),q([Bt([],R)],t.prototype,"points",void 0),t}(ma),PF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"FlowShape"},q([I("Flow")],t.prototype,"type",void 0),q([I("Terminator")],t.prototype,"shape",void 0),t}(ma),lT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"BpmnGateway"},q([I("None")],t.prototype,"type",void 0),t}(Ee),hT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"BpmnDataObject"},q([I("None")],t.prototype,"type",void 0),q([I(!1)],t.prototype,"collection",void 0),t}(Ee),hoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),q([I("None")],t.prototype,"type",void 0),q([I("None")],t.prototype,"loop",void 0),q([I(!1)],t.prototype,"call",void 0),q([I(!1)],t.prototype,"compensation",void 0),t}(Ee),cT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"BpmnEvent"},q([I("Start")],t.prototype,"event",void 0),q([I("None")],t.prototype,"trigger",void 0),t}(Ee),Rd=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"BpmnSubEvent"},q([I("None")],t.prototype,"trigger",void 0),q([I("Start")],t.prototype,"event",void 0),q([I("")],t.prototype,"id",void 0),q([re({},R)],t.prototype,"offset",void 0),q([Bt([],Kn)],t.prototype,"annotations",void 0),q([Bt([],Es)],t.prototype,"ports",void 0),q([I()],t.prototype,"width",void 0),q([I()],t.prototype,"height",void 0),q([re({},Jn)],t.prototype,"margin",void 0),q([I("Center")],t.prototype,"horizontalAlignment",void 0),q([I("Center")],t.prototype,"verticalAlignment",void 0),q([I(!0)],t.prototype,"visible",void 0),t}(Ee),coe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),q([re({id:"success",event:"End",offset:{x:1,y:.5}},Rd)],t.prototype,"success",void 0),q([re({id:"failure",event:"Intermediate",trigger:"Error",offset:{x:.25,y:1}},Rd)],t.prototype,"failure",void 0),q([re({id:"cancel",event:"Intermediate",trigger:"Cancel",offset:{x:.75,y:1}},Rd)],t.prototype,"cancel",void 0),t}(Ee),doe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),q([I("None")],t.prototype,"type",void 0),q([I(!1)],t.prototype,"adhoc",void 0),q([I("Default")],t.prototype,"boundary",void 0),q([I(!1)],t.prototype,"compensation",void 0),q([I("None")],t.prototype,"loop",void 0),q([I(!0)],t.prototype,"collapsed",void 0),q([Bt([],Rd)],t.prototype,"events",void 0),q([re({},coe)],t.prototype,"transaction",void 0),q([I(void 0)],t.prototype,"processes",void 0),t}(Ee),dT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"BpmnActivity"},q([I("Task")],t.prototype,"activity",void 0),q([re({},hoe)],t.prototype,"task",void 0),q([re({},doe)],t.prototype,"subProcess",void 0),t}(Ee),cm=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return Ni(t,n),t.prototype.getClassName=function(){return"BpmnAnnotation"},q([I("")],t.prototype,"text",void 0),q([I("")],t.prototype,"id",void 0),q([I(0)],t.prototype,"angle",void 0),q([I()],t.prototype,"height",void 0),q([I()],t.prototype,"width",void 0),q([I(0)],t.prototype,"length",void 0),t}(Ee),uoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),q([I("")],t.prototype,"textAnnotationTarget",void 0),q([I("Auto")],t.prototype,"textAnnotationDirection",void 0),t}(Ee),uT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"BpmnShape"},q([I("Bpmn")],t.prototype,"type",void 0),q([I("Event")],t.prototype,"shape",void 0),q([re({},cT)],t.prototype,"event",void 0),q([re({},lT)],t.prototype,"gateway",void 0),q([re({},hT)],t.prototype,"dataObject",void 0),q([re({},dT)],t.prototype,"activity",void 0),q([re({},cm)],t.prototype,"annotation",void 0),q([Bt([],cm)],t.prototype,"annotations",void 0),q([re({},uoe)],t.prototype,"textAnnotation",void 0),t}(ma),zF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"UmlActivityShape"},q([I("UmlActivity")],t.prototype,"type",void 0),q([I("Action")],t.prototype,"shape",void 0),t}(ma),fT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"MethodArguments"},q([I("")],t.prototype,"name",void 0),q([I("")],t.prototype,"type",void 0),q([re({},Xf)],t.prototype,"style",void 0),t}(Ee),sp=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"UmlClassAttribute"},q([I("Public")],t.prototype,"scope",void 0),q([I(!1)],t.prototype,"isSeparator",void 0),q([re({fill:"#F9F9F9",strokeColor:"#CCCCCC"},Nl)],t.prototype,"separatorStyle",void 0),t}(fT),dm=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"UmlClassMethod"},q([Bt([],fT)],t.prototype,"parameters",void 0),t}(sp),cb=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"UmlClass"},q([I("")],t.prototype,"name",void 0),q([Bt([],sp)],t.prototype,"attributes",void 0),q([Bt([],dm)],t.prototype,"methods",void 0),q([re({},Xf)],t.prototype,"style",void 0),t}(Ee),pT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"UmlInterface"},q([I(!1)],t.prototype,"isSeparator",void 0),q([re({fill:"#F9F9F9",strokeColor:"#CCCCCC"},Nl)],t.prototype,"separatorStyle",void 0),t}(cb),db=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"UmlEnumerationMember"},q([I("")],t.prototype,"name",void 0),q([I("")],t.prototype,"value",void 0),q([I(!1)],t.prototype,"isSeparator",void 0),q([re({fill:"#F9F9F9",strokeColor:"#CCCCCC"},Nl)],t.prototype,"separatorStyle",void 0),q([re({},Xf)],t.prototype,"style",void 0),t}(Ee),gT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"UmlEnumeration"},q([I("")],t.prototype,"name",void 0),q([Bt([],db)],t.prototype,"members",void 0),q([re({},Xf)],t.prototype,"style",void 0),t}(Ee),RF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"UmlClassifierShape"},q([I("UmlClassifier")],t.prototype,"type",void 0),q([re({},cb)],t.prototype,"classShape",void 0),q([re({},pT)],t.prototype,"interfaceShape",void 0),q([re({},gT)],t.prototype,"enumerationShape",void 0),q([I("Class")],t.prototype,"classifier",void 0),t}(ma),te=function(n){function t(e,i,r,s){var a,o=n.call(this,e,i,r,s)||this;return o.isCanvasUpdate=!1,o.status="None",o.parentId="",o.processId="",o.umlIndex=-1,o.outEdges=[],o.inEdges=[],o.isHeader=!1,o.isLane=!1,o.isPhase=!1,o.children&&o.children.length>0&&((!(a=r).style||!a.style.fill)&&(o.style.fill="transparent"),(!a.style||!a.style.strokeColor)&&(o.style.strokeColor="transparent")),o.shape&&"UmlActivity"===o.shape.type&&rb(r,o),o.shape&&"SwimLane"===o.shape.type&&fF(r,o),o.ports&&o.ports.length&&function vse(n){for(var t=0;t>";t=n;break;case"FinalNode":t=IF(e)}return t}(new Ze,i,this);break;case"Bpmn":if(e.bpmnModule){i=e.bpmnModule.initBPMNContent(i,this,e),this.wrapper.elementActions=this.wrapper.elementActions|Xr.ElementIsGroup;var v=this.shape.activity.subProcess;if(v.processes&&v.processes.length)for(var S=0,b=this.shape.activity.subProcess.processes;S>",margin:{left:10,right:10},id:"class",style:{fontSize:i.style.fontSize,color:i.style.color,fill:i.style.fill,textWrapping:r},offset:{x:.5,y:.3},constraints:Nr.ReadOnly}],constraints:(ie.Default|ie.HideThumbs)&~(ie.Rotate|ie.Drag|ie.Resize),verticalAlignment:"Stretch",horizontalAlignment:"Stretch",style:{fill:t.style.fill,strokeColor:"black"===t.style.strokeColor?"#ffffff00":t.style.strokeColor}},!0);return e.initObject(s),e.nodes.push(s),e.UpdateBlazorDiagramModel(s,"Node"),t.children.push(s.id),function toe(n,t,e,i){if("Enumeration"===n.shape.classifier){var r=e.members;if(r&&r.length){rp(n,t);for(var s="",o=0;o0)for(var o=0;o0&&s.phaseSize&&(i+=s.phaseSize,Xv(n,s.phaseSize)),s.lanes.length>0)for(o=0;o0){var a=0;for(o=0;o0&&"Horizontal"===r.orientation)for(l=0;l0&&(i+=r.phaseSize,o=qv(r.phaseSize),n.push(o)),a=0;a0&&o.phaseSize){for(var l=0;l0)for(l=0;l0?e.nameTable[this.nodes[0].id].wrapper:e.nameTable[this.connectors[0].id].wrapper,this.annotation.id);i.children.push(s)}else if(this.nodes||this.connectors){for(var o=0;o-1}function VF(n,t,e){n=[];for(var i=0,r=e.length;i0?c.getElementsByTagName("svg")[0].outerHTML:c.getElementsByTagName("g").length>0?c.getElementsByTagName("g")[0].outerHTML:"",s.shape.content=h,n.content=h,c.parentElement.removeChild(c)}l="nodeTemplate"}else a=s,l="annotationTemplate";var p=document.getElementById(n.diagramId).ej2_instances[0];if("string"!=typeof n.content&&"function"!=typeof n.content||n.isTemplate)if(n.isTemplate){if(v=void 0,v=p.isReact?n.getNodeTemplate()($(e),p,l+"_"+("nodeTemplate"===l?e.id:n.nodeId+e.id),void 0,void 0,!1,i):p.isVue||p.isVue3?n.getNodeTemplate()?n.getNodeTemplate()($(e),p,l+"_"+("nodeTemplate"===l?e.id:n.nodeId+e.id),void 0,void 0,!1,i):(v=si("nodeTemplate"===l?p.nodeTemplate:p.annotationTemplate))($(e),p,l+"_"+("nodeTemplate"===l?e.id:n.nodeId+e.id),void 0,void 0,!1,i):n.getNodeTemplate()($(e),p,l+"_"+("nodeTemplate"===l?e.id:n.nodeId+e.id),void 0,void 0,!1))for(var M=0;M=1&&0===n.x&&("Clip"===i.textOverflow||"Ellipsis"===i.textOverflow)&&("Wrap"===i.textWrapping||"WrapWithOverflow"===i.textWrapping)&&(n.x=t[e-1]?t[e-1].x:-n.width/2),n.x}function QF(n,t,e,i){return e&&!t.template||t.template&&"function"==typeof t.template&&i.isReact?(n.isTemplate=!0,n.template=n.content=Fh(n,!0,t)):n.content=t.template,n}function Qe(){for(var e,t="",i=0;i<5;i++){if(typeof window<"u"&&"crypto"in window&&"getRandomValues"in crypto){var r=new Uint16Array(1);e=(window.msCrypto||window.crypto).getRandomValues(r)[0]%60}else e=Math.floor(61*Math.random());0===i&&e<10?i--:t+="0123456789ABCDEFGHIJKLMNOPQRSTUVWXTZabcdefghiklmnopqrstuvwxyz".substring(e,e+1)}return t}function GF(n){if(n)try{return"function"!=typeof n&&document.querySelectorAll(n).length?si(document.querySelector(n).innerHTML.trim()):si(n)}catch{return si(n)}}function xn(n){new Ne;var e=n.offsetY-n.actualSize.height*n.pivot.y,i=n.offsetY+n.actualSize.height*(1-n.pivot.y),r=n.offsetX-n.actualSize.width*n.pivot.x,s=n.offsetX+n.actualSize.width*(1-n.pivot.x);return Ne.toBounds([{x:r,y:e},{x:s,y:e},{x:r,y:i},{x:s,y:i}])}function yr(n){var t=new Ne,e=xn(n),i=e.middleLeft,r=e.topCenter,s=e.bottomCenter,o=e.middleRight,a=e.topLeft,l=e.topRight,h=e.bottomLeft,c=e.bottomRight;if(n.corners={topLeft:a,topCenter:r,topRight:l,middleLeft:i,middleRight:o,bottomLeft:h,bottomCenter:s,bottomRight:c},0!==n.rotateAngle||0!==n.parentTransform){var d=Bi();qi(d,n.rotateAngle+n.parentTransform,n.offsetX,n.offsetY),n.corners.topLeft=a=Ke(d,a),n.corners.topCenter=r=Ke(d,r),n.corners.topRight=l=Ke(d,l),n.corners.middleLeft=i=Ke(d,i),n.corners.middleRight=o=Ke(d,o),n.corners.bottomLeft=h=Ke(d,h),n.corners.bottomCenter=s=Ke(d,s),n.corners.bottomRight=c=Ke(d,c)}return t=Ne.toBounds([a,l,h,c]),n.corners.left=t.left,n.corners.right=t.right,n.corners.top=t.top,n.corners.bottom=t.bottom,n.corners.center=t.center,n.corners.width=t.width,n.corners.height=t.height,t}function $(n,t,e,i){var r={},s="properties";if(n){e=n.propName;var l=[],h=[];if((l=l.concat(Object.keys(n[""+s]||n))).push("version"),e){var c=Zi(t);h=c?c(e):[],l=l.concat(h)}for(var d=function Ooe(n){switch(n){case"nodes":case"children":return["inEdges","outEdges","parentId","processId","nodeId","umlIndex","isPhase","isLane"];case"connectors":return["parentId"];case"annotation":case"annotations":return["nodeId"];case"shape":return["hasHeader"];case"layers":return["objectZIndex"]}return[]}(e),u=0,f=l=l.concat(d);u0&&(e=r),r=Math.floor(Poe(e,i)),s=Bc(o+=n.substr(e,r),t)}while(s<=t.width);for(o=o.substr(0,e),a=e;a=t.width){n=n.substr(0,o.length-1);break}return"Ellipsis"===t.textOverflow?(n=n.substr(0,n.length-3),n+="..."):n=n.substr(0,n.length),n}function MT(n,t){if("NoWrap"===t&&"PreserveAll"===n)return"pre";var e="";switch(n){case"CollapseAll":e="nowrap";break;case"CollapseSpace":e="pre-line";break;case"PreserveAll":e="pre-wrap"}return e}function wT(n,t){var e=Bi();qi(e,t,0,0);var i=Ke(e,{x:0,y:0}),r=Ke(e,{x:n.width,y:0}),s=Ke(e,{x:0,y:n.height}),o=Ke(e,{x:n.width,y:n.height}),a=Math.min(i.x,r.x,s.x,o.x),l=Math.min(i.y,r.y,s.y,o.y),h=Math.max(i.x,r.x,s.x,o.x),c=Math.max(i.y,r.y,s.y,o.y);return new me(h-a,c-l)}function xs(n,t,e,i){if(0!==n){var r=Bi();return qi(r,n,t,e),Ke(r,i)}return i}function Zi(n){return void 0!==n&&"string"==typeof n&&(n=Y(n,window)),n}var bo=function(){function n(){}return n.getContext=function(t){return t.getContext("2d")},n.setCanvasSize=function(t,e,i){t&&(t.setAttribute("width",e.toString()),t.setAttribute("height",i.toString()))},n.prototype.renderGradient=function(t,e,i,r){var s,o,a;if("None"!==t.gradient.type){for(var l=0;l0?(w=0===S.r1?e.arc[parseInt(r.toString(),10)].r1:S.r1,C=0===S.r2?e.arc[parseInt(r.toString(),10)].r2:S.r2,r++):(w=S.r1,C=S.r2);var D=S.angle*(Math.PI/180),A=S.largeArc,x=S.sweep,P={x:u,y:f},L={x:Math.cos(D)*(M.x-P.x)/2+Math.sin(D)*(M.y-P.y)/2,y:-Math.sin(D)*(M.x-P.x)/2+Math.cos(D)*(M.y-P.y)/2},O=Math.pow(L.x,2)/Math.pow(w,2)+Math.pow(L.y,2)/Math.pow(C,2);O>1&&(w*=Math.sqrt(O),C*=Math.sqrt(O));var N=Math.pow(C,2)*Math.pow(L.x,2),T=(A===x?-1:1)*Math.sqrt((Math.pow(w,2)*Math.pow(C,2)-Math.pow(w,2)*Math.pow(L.y,2)-N)/(Math.pow(w,2)*Math.pow(L.y,2)+Math.pow(C,2)*Math.pow(L.x,2)));isNaN(T)&&(T=0);var z={x:T*w*L.y/C,y:T*-C*L.x/w},U={x:(M.x+P.x)/2+Math.cos(D)*z.x-Math.sin(D)*z.y,y:(M.y+P.y)/2+Math.sin(D)*z.x+Math.cos(D)*z.y},B=this.a([1,0],[(L.x-z.x)/w,(L.y-z.y)/C]),j=[(L.x-z.x)/w,(L.y-z.y)/C],Q=[(-L.x-z.x)/w,(-L.y-z.y)/C],oe=this.a(j,Q);this.r(j,Q)<=-1&&(oe=Math.PI),this.r(j,Q)>=1&&(oe=0);var fe=B+oe/2*(x?1:-1);if(Math.cos(fe),Math.sin(fe),S.centp=U,S.xAxisRotation=D,S.rx=w,S.ry=C,S.a1=B,S.ad=oe,S.sweep=x,null!=s){var De=w>C?w:C,xe=w>C?1:w/C,Ie=w>C?C/w:1;s.save(),s.translate(U.x,U.y),s.rotate(D),s.scale(xe,Ie),s.arc(0,0,De,B,B+oe,!x),s.scale(1/xe,1/Ie),s.rotate(-D),s.translate(-U.x,-U.y),s.restore()}break;case"Z":case"z":s.closePath(),u=o,f=a}o=u,a=f}}},n.prototype.drawText=function(t,e,i,r,s,o,a){if(e.content&&!0===e.visible){var l=n.getContext(t);l.save(),this.setStyle(t,e),o&&(e.fontSize*=o),this.applyFlipAndRotate(l,e,t,e.x+e.width*e.pivotX,e.y+e.height*e.pivotY),this.setFontStyle(t,e);var u,d=0;u=e.childNodes;var f=e.wrapBounds;if(l.fillStyle=e.color,f){var p=this.labelAlign(e,f,u);for(d=0;de.width&&"Wrap"!==e.textOverflow&&"NoWrap"===e.textWrapping&&(g.text=qF(g.text,e)),"Clip"!==e.textOverflow&&"Ellipsis"!==e.textOverflow||"Wrap"!==e.textWrapping?l.fillText(g.text,v,y):ya.actualSize.height+a.bounds.y&&(g.text=g.text.slice(0,g.text.length-3),g.text=g.text.concat("...")),l.fillText(g.text,v,y)),"Underline"===e.textDecoration||"Overline"===e.textDecoration||"LineThrough"===e.textDecoration){var M=v,w=void 0,D=v+l.measureText(g.text).width,A=void 0;switch(e.textDecoration){case"Underline":w=y+2,A=y+2;break;case"Overline":w=p.y+g.dy*d,A=p.y+g.dy*d;break;case"LineThrough":w=(y+p.y+g.dy*d)/2+2,A=(y+p.y+g.dy*d)/2+2}l.beginPath(),l.moveTo(M,w),l.lineTo(D,A),l.strokeStyle=e.color,l.lineWidth=.08*e.fontSize,l.globalAlpha=e.opacity,l.stroke()}}}l.restore()}},n.prototype.applyFlipAndRotate=function(t,e,i,r,s){"Horizontal"===e.flip||"Vertical"===e.flip?(t.translate(e.x+e.width/2,e.y+e.height/2),t.rotate(-e.angle*Math.PI/180),t.translate(-e.x-e.width/2,-e.y-e.height/2)):this.rotateContext(i,e.angle,r,s),t.translate(e.x,e.y),"Horizontal"===e.flip?(t.scale(-1,1),t.translate(-1*e.width,0)):"Vertical"===e.flip?(t.scale(1,-1),t.translate(0,-1*e.height)):"Both"===e.flip&&(t.scale(-1,-1),t.translate(-1*e.width,-1*e.height)),t.translate(-e.x,-e.y)},n.prototype.loadImage=function(t,e,i,r,s){var o=new Image;o.src=e.source,this.image(t,o,e.x,e.y,e.width,e.height,e)},n.prototype.drawImage=function(t,e,i,r){var s=this;if(e.visible){var o=n.getContext(t);o.save();var a=e.x+e.width*e.pivotX,l=e.y+e.height*e.pivotY,h=new Image;h.src=e.source,this.setStyle(t,e),o.canvas.id.split("_"),this.applyFlipAndRotate(o,e,t,a,l),r?h.onload=function(){s.loadImage(o,e,t,a,l)}:this.loadImage(o,e,t,a,l),o.restore()}},n.prototype.image=function(t,e,i,r,s,o,a){t.beginPath();var l=e.width,h=e.height,c=s,d=o,u=0,f=0;if(a&&"None"!==a.alignment){var p=a.alignment.toLowerCase().substr(1,3),g=a.alignment.toLowerCase().substr(5,3);if("Slice"===a.scale){var v=function(){u=c,f=h*c/l},y=function(){u=l*d/h,f=d};c>d?(v(),d>f&&y()):c===d?l>h?y():v():(y(),c>u&&v());var S=this.getSliceOffset(p,u,c,l),b=this.getSliceOffset(g,f,d,h),M=l-S,w=h-b,C=u-S*(u/l),D=f-b*(f/h),A=Tt("canvas",{width:s.toString(),height:o.toString()});A.getContext("2d").drawImage(e,S,b,M,w,0,0,C,D),t.drawImage(A,i,r,s,o)}else if("Meet"===a.scale){var P=h/l,L=d/c;f=L>P?c*P:d,i+=this.getMeetOffset(p,u=L>P?c:d/P,c),r+=this.getMeetOffset(g,f,d),t.drawImage(e,0,0,l,h,i,r,u,f)}else t.drawImage(e,i,r,s,o)}else if("None"!==a.flip){var O=1,N=1;("Horizontal"===a.flip||"Both"===a.flip)&&(i=-i,s=-s,O=-1),("Vertical"===a.flip||"Both"===a.flip)&&(r=-r,o=-o,N=-1),t.scale(O,N),t.drawImage(e,i,r,s,o)}else t.drawImage(e,i,r,s,o);t.closePath()},n.prototype.getSliceOffset=function(t,e,i,r){switch(t){case"min":default:return 0;case"mid":return(e-i)/2*r/e;case"max":return(e-i)*r/e}},n.prototype.getMeetOffset=function(t,e,i){var r=Math.max(e,i),s=Math.min(e,i);switch(t){case"min":default:return 0;case"mid":return(r-s)/2;case"max":return r-s}},n.prototype.m=function(t){return Math.sqrt(Math.pow(t[0],2)+Math.pow(t[1],2))},n.prototype.r=function(t,e){return(t[0]*e[0]+t[1]*e[1])/(this.m(t)*this.m(e))},n.prototype.a=function(t,e){return(t[0]*e[1]t.width&&("Ellipsis"===t.textOverflow||"Clip"===t.textOverflow)&&"NoWrap"===t.textWrapping?0:.5*t.width:"right"===t.textAlign&&(c=1*t.width),s.x=t.x+c+(e?e.x:0),s.y=a+d-r.height/2,s},n}(),vb=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Vi=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Roe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return vb(t,n),Vi([I("")],t.prototype,"source",void 0),Vi([I("transparent")],t.prototype,"color",void 0),Vi([I("None")],t.prototype,"scale",void 0),Vi([I("None")],t.prototype,"align",void 0),t}(Ee),Hoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return vb(t,n),Vi([I("Page")],t.prototype,"mode",void 0),Vi([I("PageSettings")],t.prototype,"region",void 0),Vi([re({top:25,bottom:25,left:25,right:25},Jn)],t.prototype,"margin",void 0),Vi([I(!1)],t.prototype,"canZoomIn",void 0),Vi([I(void 0)],t.prototype,"customBounds",void 0),Vi([I(!1)],t.prototype,"canFit",void 0),t}(Ee),Boe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return vb(t,n),Vi([I(null)],t.prototype,"width",void 0),Vi([I(null)],t.prototype,"height",void 0),Vi([re({},Jn)],t.prototype,"margin",void 0),Vi([I("Landscape")],t.prototype,"orientation",void 0),Vi([I("Infinity")],t.prototype,"boundaryConstraints",void 0),Vi([re({},Roe)],t.prototype,"background",void 0),Vi([I(!1)],t.prototype,"multiplePage",void 0),Vi([I(!1)],t.prototype,"showPageBreaks",void 0),Vi([re({},Hoe)],t.prototype,"fitOptions",void 0),t}(Ee),Foe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return vb(t,n),Vi([I(0)],t.prototype,"horizontalOffset",void 0),Vi([I(0)],t.prototype,"verticalOffset",void 0),Vi([I(1)],t.prototype,"currentZoom",void 0),Vi([I(0)],t.prototype,"viewPortWidth",void 0),Vi([I(0)],t.prototype,"viewPortHeight",void 0),Vi([I(.2)],t.prototype,"minZoom",void 0),Vi([I(30)],t.prototype,"maxZoom",void 0),Vi([I("Diagram")],t.prototype,"scrollLimit",void 0),Vi([I()],t.prototype,"scrollableArea",void 0),Vi([I(!1)],t.prototype,"canAutoScroll",void 0),Vi([I(100)],t.prototype,"autoScrollFrequency",void 0),Vi([re({left:15,right:15,top:15,bottom:15},Jn)],t.prototype,"autoScrollBorder",void 0),Vi([re({left:0,right:0,top:0,bottom:0},Jn)],t.prototype,"padding",void 0),Vi([I(.2)],t.prototype,"zoomFactor",void 0),t}(Ee),_oe=function(){function n(){this.services={}}return n.prototype.register=function(t,e){this.services[""+t]=e},n.prototype.getService=function(t){return this.services[""+t]},n}(),$F=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),ya=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},ZF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return $F(t,n),ya([I("lightgray")],t.prototype,"lineColor",void 0),ya([I("")],t.prototype,"lineDashArray",void 0),ya([I([1.25,18.75,.25,19.75,.25,19.75,.25,19.75,.25,19.75])],t.prototype,"lineIntervals",void 0),ya([I([1,19,.5,19.5,.5,19.5,.5,19.5,.5,19.5])],t.prototype,"dotIntervals",void 0),ya([I([20])],t.prototype,"snapIntervals",void 0),t}(Ee),Uoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return $F(t,n),ya([re({},ZF)],t.prototype,"horizontalGridlines",void 0),ya([re({},ZF)],t.prototype,"verticalGridlines",void 0),ya([I(Kt.All)],t.prototype,"constraints",void 0),ya([I(5)],t.prototype,"snapAngle",void 0),ya([I("Lines")],t.prototype,"gridType",void 0),ya([I(5)],t.prototype,"snapObjectDistance",void 0),ya([I("#07EDE1")],t.prototype,"snapLineColor",void 0),t}(Ee),JF=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),el=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},KF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return JF(t,n),el([I(5)],t.prototype,"interval",void 0),el([I(100)],t.prototype,"segmentWidth",void 0),el([I("Horizontal")],t.prototype,"orientation",void 0),el([I("RightOrBottom")],t.prototype,"tickAlignment",void 0),el([I("red")],t.prototype,"markerColor",void 0),el([I(25)],t.prototype,"thickness",void 0),el([I(null)],t.prototype,"arrangeTick",void 0),t}(Ee),joe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return JF(t,n),el([I(!1)],t.prototype,"showRulers",void 0),el([I(!0)],t.prototype,"dynamicGrid",void 0),el([re({orientation:"Horizontal"},KF)],t.prototype,"horizontalRuler",void 0),el([re({orientation:"Vertical"},KF)],t.prototype,"verticalRuler",void 0),t}(Ee),Voe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),e_=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Woe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Voe(t,n),e_([I("")],t.prototype,"property",void 0),e_([I("")],t.prototype,"field",void 0),t}(Ee),CT=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),ln=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},t_=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return CT(t,n),ln([I("")],t.prototype,"read",void 0),ln([I("")],t.prototype,"create",void 0),ln([I("")],t.prototype,"update",void 0),ln([I("")],t.prototype,"destroy",void 0),ln([I()],t.prototype,"customFields",void 0),t}(Ee),Yoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return CT(t,n),ln([I("")],t.prototype,"id",void 0),ln([I("")],t.prototype,"sourceID",void 0),ln([I("")],t.prototype,"targetID",void 0),ln([I(null)],t.prototype,"sourcePointX",void 0),ln([I(null)],t.prototype,"sourcePointY",void 0),ln([I(null)],t.prototype,"targetPointX",void 0),ln([I(null)],t.prototype,"targetPointY",void 0),ln([I(null)],t.prototype,"dataManager",void 0),ln([re({},t_)],t.prototype,"crudAction",void 0),t}(Ee),Qoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return CT(t,n),ln([I("")],t.prototype,"id",void 0),ln([I(null)],t.prototype,"dataManager",void 0),ln([I(null)],t.prototype,"dataSource",void 0),ln([I("")],t.prototype,"root",void 0),ln([I("")],t.prototype,"parentId",void 0),ln([I()],t.prototype,"doBinding",void 0),ln([Bt([],Woe)],t.prototype,"dataMapSettings",void 0),ln([re({},t_)],t.prototype,"crudAction",void 0),ln([re({},Yoe)],t.prototype,"connectionDataSource",void 0),t}(Ee),i_=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Cr=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Goe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return i_(t,n),Cr([I("LeftInFlow")],t.prototype,"yesBranchDirection",void 0),Cr([I("RightInFlow")],t.prototype,"noBranchDirection",void 0),Cr([I(["Yes","True"])],t.prototype,"yesBranchValues",void 0),Cr([I(["No","False"])],t.prototype,"noBranchValues",void 0),t}(Ee),Xoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return i_(t,n),Cr([I("")],t.prototype,"fixedNode",void 0),Cr([I(30)],t.prototype,"horizontalSpacing",void 0),Cr([I("SamePoint")],t.prototype,"connectionPointOrigin",void 0),Cr([I("Nonlinear")],t.prototype,"arrangement",void 0),Cr([I(30)],t.prototype,"verticalSpacing",void 0),Cr([I(30)],t.prototype,"maxIteration",void 0),Cr([I(40)],t.prototype,"springFactor",void 0),Cr([I(50)],t.prototype,"springLength",void 0),Cr([re({left:50,top:50,right:0,bottom:0},Jn)],t.prototype,"margin",void 0),Cr([I("Auto")],t.prototype,"horizontalAlignment",void 0),Cr([I("Auto")],t.prototype,"verticalAlignment",void 0),Cr([I("TopToBottom")],t.prototype,"orientation",void 0),Cr([I("Auto")],t.prototype,"connectionDirection",void 0),Cr([I("Default")],t.prototype,"connectorSegments",void 0),Cr([I("None")],t.prototype,"type",void 0),Cr([I()],t.prototype,"getLayoutInfo",void 0),Cr([I()],t.prototype,"layoutInfo",void 0),Cr([I()],t.prototype,"getBranch",void 0),Cr([I()],t.prototype,"bounds",void 0),Cr([I(!0)],t.prototype,"enableAnimation",void 0),Cr([I(!1)],t.prototype,"enableRouting",void 0),Cr([I("")],t.prototype,"root",void 0),Cr([re({},Goe)],t.prototype,"flowchartLayoutSettings",void 0),t}(Ee),qoe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),r_=function(n){function t(e,i){var r=n.call(this,e,!0)||this;return r.oldValue=null,r.endPoint=i,r}return qoe(t,n),t.prototype.mouseDown=function(e){var i,r=!0;if(e.source&&e.source.connectors&&(i=e.source.connectors[0]),e.info&&e.actualObject&&(r=e.info.ctrlKey&&"Orthogonal"!==e.actualObject.type),i&&r){this.inAction=!0,this.undoElement=$(e.source),n.prototype.mouseDown.call(this,e);for(var s=0;s0)1!==s&&this.removePrevSegment(i,s);else if(a){var l=R.distancePoints(a.points[0],a.points[1]);Math.abs(a.length||0===a.length?a.length:l)<=5&&this.removeNextSegment(i,s)}this.commandHandler.updateEndPoint(i,r),i.selectedSegmentIndex=0}if(this.undoElement){var c=$(e.source);this.commandHandler.addHistoryEntry({type:"SegmentChanged",redoObject:c,undoObject:this.undoElement,category:"Internal"})}if(i.isBezierEditing&&(i.isBezierEditing=!1),this.prevPosition!==this.startPosition){var u={source:i,state:"Completed",oldValue:this.oldValue,newValue:$(this.selectedSegment),cancel:!1,segment:this.selectedSegment};this.commandHandler.triggerEvent(Ce.segmentChange,u)}n.prototype.mouseUp.call(this,e)},t.prototype.removePrevSegment=function(e,i){var r=e.segments[i-2],s=e.segments[i+1];if(s&&!((s.length||0===s.length?s.length:R.distancePoints(s.points[0],s.points[1]))<=5)){var a=e.segments.slice(i-1,i+1),l={element:e,removeSegments:a,type:"Removal",cancel:!1};if(this.commandHandler.triggerEvent(Ce.segmentCollectionChange,l),!l.cancel){var h=e.segments[i+1];e.segments.splice(i-1,2);var c=this.selectedSegment;"Left"===c.direction||"Right"===c.direction?(r.points[r.points.length-1].x=h.points[0].x,h.points[0].y=r.points[r.points.length-1].y):(r.points[r.points.length-1].y=h.points[0].y,h.points[0].x=r.points[r.points.length-1].x),(c.length||0===c.length)&&this.findSegmentDirection(r),this.findSegmentDirection(h)}}},t.prototype.findSegmentDirection=function(e){e.direction&&(e.length||0===e.length)&&(e.length=R.distancePoints(e.points[0],e.points[e.points.length-1]),e.direction=R.direction(e.points[0],e.points[e.points.length-1]))},t.prototype.removeNextSegment=function(e,i){var l,h,r=this.selectedSegment,s=e.segments[i-1],o=e.segments[i+2],a=e.segments[i+1];if(a.length||0===a.length?(l=e.segments.slice(i,2),h={element:e,removeSegments:l,type:"Removal",cancel:!1},this.commandHandler.triggerEvent(Ce.segmentCollectionChange,h={element:e,removeSegments:l,type:"Removal",cancel:!1}),h.cancel||(e.segments.splice(i,2),"Top"===r.direction||"Bottom"===r.direction?(o.points[0].y=r.points[0].y,s.points[s.points.length-1].x=o.points[0].x):(o.points[0].x=r.points[0].x,s.points[s.points.length-1].y=o.points[0].y))):(l=e.segments.slice(i+1,1),this.commandHandler.triggerEvent(Ce.segmentCollectionChange,h={element:e,removeSegments:l,type:"Removal",cancel:!1}),h.cancel||(e.segments.splice(i+1,1),"Top"===r.direction||"Bottom"===r.direction?s.points[s.points.length-1].x=a.points[a.points.length-1].x:s.points[s.points.length-1].y=a.points[a.points.length-1].y,this.findSegmentDirection(s),r.length=r.direction=null)),s&&o&&!h.cancel&&(s.length=R.distancePoints(s.points[0],o.points[0]),s.direction=R.direction(s.points[0],o.points[0]),o.length||0===o.length)){o.length=R.distancePoints(s.points[s.points.length-1],o.points[o.points.length-1]);var c=s.points,d=o.points;o.direction=R.direction(c[c.length-1],d[d.length-1])}},t.prototype.addOrRemoveSegment=function(e,i,r){for(var s,o,a=[],l={segments:e.segments},h=0;h0?"Bottom":"Top":r>0?"Right":"Left",length:i.points[0].x===i.points[1].x?s:r},!0)),l.push(new wi(e,"segments",{type:"Orthogonal",direction:c,length:h/2},!0));var f={element:e,addSegments:l,type:"Addition",cancel:!1};return this.commandHandler.triggerEvent(Ce.segmentCollectionChange,f),f.cancel||(e.segments=l.concat(e.segments),a=o+2),a},t.prototype.insertFirstSegment=function(e,i,r,s,o){var a,l,d,u,h=[];if(e.sourcePortID&&i.length&&e.segments[0].points.length>2)for(var f=void 0,p=0;p0?"Bottom":"Top":r>0?"Right":"Left"),f=u,h.push(u)}else h.push(new wi(e,"segments",{type:"Orthogonal",direction:i.direction,length:i.length/3},!0)),"Bottom"===i.direction||"Top"===i.direction?(l=Math.abs(r),a=r>0?"Right":"Left"):(l=Math.abs(s),a=s>0?"Bottom":"Top"),u=new wi(e,"segments",{type:"Orthogonal",direction:a,length:l},!0),h.push(u);var y={element:e,addSegments:h,type:"Addition",cancel:!1};if(this.commandHandler.triggerEvent(Ce.segmentCollectionChange,y),!y.cancel){if(e.sourcePortID&&i.length&&e.segments[0].points.length>2)e.segments.splice(0,1),d=1;else{var S=e.segments[1];S&&S.length&&(S.length=a!==S.direction?S.length+l:S.length-l),d=2,i.length=2*i.length/3}e.segments=h.concat(e.segments)}return d},t.prototype.updateAdjacentSegments=function(e,i,r,s){var o=e.segments[parseInt(i.toString(),10)],a=o.points[o.points.length-1],h=!0;"Orthogonal"===o.type&&(o.points[0]=o.points[0],o.points[o.points.length-1]=a,e.segments[i-1]&&(h=this.updatePreviousSegment(r,s,e,i)),e.segments.length-1>i&&h&&this.updateNextSegment(e,o,e.segments[i+1],r,s))},t.prototype.addTerminalSegment=function(e,i,r,s,o){var l,h,c,d,a=e.segments.indexOf(i),u=[],f=e.segments.pop(),p=e.segments[e.segments.length-1];l=p&&"Orthogonal"===p.type?p:null;for(var g=0;g0&&"Left"===o.direction?c.middleLeft:c.middleRight,o.length>c.width/2?Math.abs(a.length)0&&"Top"===o.direction?c.topCenter:c.bottomCenter,o.length>c.height/2?Math.abs(a.length)1)for(var a=0,l=this.diagram.views;a0)for(var e=t===Ce.onUserHandleMouseLeave?this.previousAction:this.action,i={element:void 0},r=0;r0)for(var r={element:void 0},s=void 0,o=void 0,a=0;a-1&&(o=s,this.previousTarget=i,this.targetItem=e),o===e.fixedUserHandles[parseInt(a.toString(),10)].id&&(r.element=e.fixedUserHandles[parseInt(a.toString(),10)],this.userHandle(t,a,r,e))},n.prototype.mouseDown=function(t){var e=this;if("touchstart"===t.type&&(this.timeOutTapHold=setTimeout(function(){("Select"===e.action||"Drag"===e.action)&&e.mouseMove(t,void 0)},500)),!0!==this.inAction||!(this.tool instanceof qI||this.tool instanceof pa)){this.focus=!0;var i=t.touches,r=!!document.getElementsByClassName("e-dragclone")[0];if(this.isMouseOnScrollBar(t)&&!r)return this.isScrolling=!0,void t.preventDefault();if(this.checkFixedUserHandleEvent(Ce.onFixedUserHandleMouseDown,this.targetItem,this.previousTarget),this.checkUserHandleEvent(Ce.onUserHandleMouseDown),!this.checkEditBoxAsTarget(t)&&Vv(this.diagram)||Lc(this.diagram)&&!UI(this.diagram))if(("Select"===this.action||"Drag"===this.action)&&this.diagram.updatePortVisibility(this.hoverElement,ci.Hover,!0),!(this.tool instanceof Rl||this.tool instanceof Hl)||2!==t.button&&2!==t.buttons)if(!0===this.inAction&&!0===this.isMouseDown&&(this.tool instanceof Rl||this.tool instanceof Hl))this.isMouseDown=!0,this.eventArgs={},this.getMouseEventArgs(this.currentPosition,this.eventArgs),this.eventArgs.position=this.currentPosition,this.tool.mouseDown(this.eventArgs);else{this.isMouseDown=!0,this.currentPosition=this.prevPosition=this.getMousePosition(t),this.eventArgs={},this.diagram.textEditing&&!this.isMouseOnScrollBar(t)&&(this.diagram.endEdit(),this.diagram.textEditing=!1,"Canvas"===this.diagram.mode&&1!==this.diagram.scroller.currentZoom&&this.diagram.refreshDiagramLayer());var o=this.getTargetElement();this.action=this.diagram.findActionToBeDone(o.obj,o.sourceElement,this.currentPosition,o.target);var a=this.isMetaKey(t);a&&t.shiftKey&&this.diagram.connectorEditingToolModule?this.action="SegmentEnd":(a||t.shiftKey)&&(Uv(this.diagram)||jv(this.diagram))&&(this.action="Select"),this.tool=this.diagram.getTool(this.action),this.tool||(this.action="Select",this.tool=this.diagram.getTool(this.action)),this.getMouseEventArgs(this.currentPosition,this.eventArgs),(a||t.shiftKey)&&(this.eventArgs.info=a&&t.shiftKey?{ctrlKey:a,shiftKey:t.shiftKey}:{ctrlKey:!0}),this.eventArgs.position=this.currentPosition;var h=this.diagram.selectedItems.nodes;if(this.tool.mouseDown(this.eventArgs),this.diagram.selectedItems.canToggleSelection&&h&&this.diagram.selectedItems.nodes&&this.tool instanceof fa)for(var c=0;c=2&&(this.touchStartList=VF(this.touchStartList,0,i)),i||t.preventDefault())}else this.inAction=!1,this.tool.mouseUp(this.eventArgs);!this.isForeignObject(t.target)&&!this.isForeignObject(t.target,!0)&&!i&&t.preventDefault()}},n.prototype.mouseMoveExtend=function(t,e){(this.tool instanceof Rl||this.tool instanceof Hl)&&this.tool.mouseMove(this.eventArgs),this.diagram.scrollSettings.canAutoScroll?this.checkAutoScroll(t):this.blocked||this.tool.mouseMove(this.eventArgs),this.eventArgs.target&&(this.hoverElement=this.eventArgs.target);var i=!((this.eventArgs.target instanceof te||this.eventArgs.target instanceof de)&&(e instanceof te||e instanceof de));this.tool instanceof kd&&this.diagram.updatePortVisibility(this.hoverElement instanceof te||this.hoverElement instanceof de?this.hoverElement:this.hoverNode,ci.Connect|ci.Hover,i),this.hoverElement instanceof te&&this.hoverNode instanceof te&&this.hoverNode&&this.hoverNode.id!==this.hoverElement.id&&this.diagram.updatePortVisibility(this.hoverNode,ci.Connect|ci.Hover,!0),this.hoverElement instanceof de&&this.hoverElement.ports.length>0&&this.diagram.updatePortVisibility(this.hoverElement,ci.Connect|ci.Hover,!0),this.previousElement instanceof te&&this.hoverElement&&this.previousElement.id!==this.hoverElement.id&&this.diagram.updatePortVisibility(this.previousElement,ci.Connect|ci.Hover,!0),this.previousElement=this.hoverElement,""!==this.diagram.tooltip.content&&(this.hoverElement=null),this.hoverNode=i?null:e},n.prototype.checkAction=function(t){if("LabelSelect"===this.action&&this.eventArgs.sourceWrapper&&(this.eventArgs.sourceWrapper instanceof ai||this.eventArgs.sourceWrapper instanceof es)){var e=this.commandHandler.findTarget(this.eventArgs.sourceWrapper,this.eventArgs.source);!_r(this.diagram,e,!1,this.eventArgs.sourceWrapper)&&ro(e)&&(this.action="LabelDrag",this.tool=this.getTool(this.action),this.tool.mouseDown(this.initialEventArgs))}else ro(t)&&xd(t)&&this.initialEventArgs&&this.initialEventArgs.source&&"Select"===this.action&&(!_r(this.diagram,this.eventArgs.source,!1)&&this.eventArgs.source instanceof ei&&this.getMouseEventArgs(this.currentPosition,this.eventArgs),(!(t instanceof de)||t instanceof de&&!(wr(this.currentPosition,t.sourcePoint,t.hitPadding)||wr(this.currentPosition,t.targetPoint,t.hitPadding)))&&(this.action="Drag"),this.tool=this.getTool(this.action),this.tool.mouseDown(this.initialEventArgs))},n.prototype.isSwimlaneElements=function(t){return!(t&&(t.isLane||t.isPhase||t.isHeader))},n.prototype.canShowTouchTooltip=function(t){return!!("touchstart"===t.type&&this.diagram.tool&ri.SingleSelect&&this.diagram.tool&ri.ZoomPan)&&(this.isMouseDown=!1,!0)},n.prototype.mouseMove=function(t,e){if(this.focus=!0,"touchmove"===t.type&&(this.touchArgs={target:t.target,type:"touchmove"}),this.isScrolling)t.preventDefault();else if(Vv(this.diagram)||Lc(this.diagram)&&!UI(this.diagram)){this.currentPosition=this.getMousePosition(t);var i=this.diagram.findObjectsUnderMouse(this.currentPosition),r=this.diagram.findObjectUnderMouse(i,this.action,this.inAction);!function nse(n,t){n.rulerSettings.showRulers&&(n.hRuler.drawRulerMarker(n.hRuler.element,t,n.scroller.horizontalOffset),n.vRuler.drawRulerMarker(n.vRuler.element,t,n.scroller.verticalOffset))}(this.diagram,this.currentPosition);var s=!1,o=void 0;if("touchmove"===t.type&&(e=t.touches)&&e.length>1&&(this.touchMoveList=VF(this.touchMoveList,0,e),"PinchZoom"!==this.action&&(s=!0)),!1===R.equals(this.currentPosition,this.prevPosition)||this.inAction||this.canShowTouchTooltip(t)){if(!1===this.isMouseDown||s){this.eventArgs={};var a=null,l=void 0;if(null!==r){if((a=this.diagram.findElementUnderMouse(r,this.currentPosition,this.diagram))&&(l=this.commandHandler.findTarget(a,r)),(l instanceof Kn||l instanceof Or)&&(l.tooltip&&""!==l.tooltip.content||(l=r)),l!==this.hoverElement){var h=this.getContent();this.hoverElement&&"Auto"===this.hoverElement.tooltip.openOn&&""!==h&&this.elementLeave(),this.diagram.updatePortVisibility(this.hoverElement,ci.Hover,!0),r instanceof te&&(this.hoverNode=r);var c=!0;!this.isSwimlaneElements(r)&&this.hoverElement&&this.isSwimlaneElements(this.hoverElement)&&(c=!1),this.hoverElement=c?r:this.hoverElement;var d,u=void 0;(d=this.diagram.findElementUnderMouse(r,this.currentPosition,this.diagram))instanceof Ze&&((u=this.commandHandler.findTarget(d,r))instanceof Es||u instanceof Tc)&&this.hoverElement.constraints&oi.ToolTip&&(this.hoverElement=u);var f=void 0;d instanceof ai&&((f=this.commandHandler.findTarget(d,r))instanceof Kn||f instanceof Or)&&f.constraints&Nr.Tooltip&&(this.hoverElement=f),c?this.elementEnter(this.currentPosition,!1):this.hoverElement=r}else this.hoverElement&&this.hoverElement===l&&this.hoverElement.tooltip.content&&void 0!==this.diagram.tooltipObject&&"Mouse"===this.hoverElement.tooltip.relativeMode&&this.setTooltipOffset(this.currentPosition);a&&(o=this.commandHandler.findTarget(a,r))}this.action=this.diagram.findActionToBeDone(r,a,this.currentPosition,o),this.checkFixedUserHandleEvent(Ce.onFixedUserHandleMouseEnter,r,a),this.checkUserHandleEvent(Ce.onUserHandleMouseEnter),this.checkPreviousAction(),this.getMouseEventArgs(this.currentPosition,this.eventArgs),this.tool=this.getTool(this.action),this.mouseEvents(),this.tool instanceof pa||this.tool instanceof Hl||this.tool instanceof Rl?this.tool.mouseMove(this.eventArgs):e&&this.tool instanceof em&&this.tool.mouseDown(this.eventArgs),this.updateCursor(),this.renderUmlHighLighter(this.eventArgs);var p=!1;this.hoverElement&&!(this.tool instanceof em)&&r instanceof te&&this.isSwimlaneElements(r)&&(0===this.diagram.selectedItems.nodes.length||!_r(this.diagram,this.hoverElement))||this.hoverElement instanceof de||(p=!0),this.hoverElement&&!(this.tool instanceof em)&&r instanceof de&&(0===this.diagram.selectedItems.connectors.length||!_r(this.diagram,this.hoverElement))||this.hoverElement instanceof te||(p=!0),this.diagram.updatePortVisibility(this.hoverElement,ci.Hover,p);var g=this.getContent();null===r&&this.hoverElement&&"Auto"===this.hoverElement.tooltip.openOn&&g&&(this.hoverElement=null,this.elementLeave()),s=!1}else{this.eventArgs.position=this.currentPosition,"Drag"===this.action&&!_r(this.diagram,this.eventArgs.source,!1)&&this.eventArgs.source instanceof ei&&this.getMouseEventArgs(this.currentPosition,this.eventArgs),this.mouseEvents(),(t.ctrlKey||t.shiftKey)&&(this.eventArgs.info=t.ctrlKey&&t.shiftKey?{ctrlKey:t.ctrlKey,shiftKey:t.shiftKey}:{ctrlKey:!0}),this.checkAction(r);var y=this.getConnectorPadding(this.eventArgs);this.getMouseEventArgs(this.currentPosition,this.eventArgs,this.eventArgs.source,y),this.updateCursor(),this.inAction=!0,this.initialEventArgs=null,("Drag"===this.action||"Rotate"===this.action)&&(this.diagram.diagramActions=this.diagram.diagramActions|ee.Interactions);var S=this.diagram.scroller.getPageBounds();this.mouseMoveExtend(t,r);var b=this.diagram.scroller.getPageBounds();if(r&&(S.width!==b.width||S.height!==b.height||S.x!==b.x||S.y!==b.y)&&this.diagram.views&&this.diagram.views.overview){var M=this.diagram.views.overview;M.updateView(M)}}this.prevPosition=this.currentPosition,this.isForeignObject(t.target,!0)||t.preventDefault()}}},n.prototype.getContent=function(){var i,t=this.hoverElement instanceof te&&this.hoverElement.constraints&ie.Tooltip||this.hoverElement instanceof de&&this.hoverElement.constraints&qe.Tooltip||(this.hoverElement instanceof Es||this.hoverElement instanceof Tc)&&this.hoverElement.constraints&oi.ToolTip||(this.hoverElement instanceof Kn||this.hoverElement instanceof Or)&&this.hoverElement.constraints&Nr.Tooltip,e=this.hoverElement;e instanceof te&&e.children&&e.children.length>0&&(i=this.findIntersectChild(e));var r=t?this.hoverElement.tooltip.content:this.diagram.tooltip.content;return i?i.tooltip.content:r},n.prototype.findIntersectChild=function(t){for(var e,i=new Ne(this.currentPosition.x,this.currentPosition.y,8,8),r=0;r1&&1===t.which&&!function one(n){return!!(n&ee.PreventClearSelection)}(this.diagram.diagramActions)&&(c=!1,this.commandHandler.clearSelection()),(!_r(this.diagram,h)||!c)&&(this.commandHandler.selectObjects([h],void 0,a),this.diagram.selectedItems.canToggleSelection)){var d=this.diagram.selectedItems.nodes;d?d[0].parentObj instanceof Hd&&(s=!0):this.diagram.selectedItems.connectors.length>0&&(s=!0)}}var u=!1,f=this.updateContainerProperties(),p=void 0;if(this.addUmlNode(),this.inAction=!1,this.isMouseDown=!1,this.diagram.selectedObject.helperObject&&(p=this.updateContainerBounds()),this.tool&&(this.tool.prevPosition||this.tool instanceof eF)){this.eventArgs.position=this.currentPosition;var g=this.getConnectorPadding(this.eventArgs);this.getMouseEventArgs(this.currentPosition,this.eventArgs,this.eventArgs.source,g);var v=this.isMetaKey(t);if((v||t.shiftKey)&&(this.eventArgs.info=v&&t.shiftKey?{ctrlKey:v,shiftKey:t.shiftKey}:{ctrlKey:!0}),this.diagram.diagramActions&ee.Interactions&&(this.diagram.diagramActions=this.diagram.diagramActions&~ee.Interactions),this.eventArgs.clickCount=t.detail,this.diagram.selectedObject.helperObject&&(this.tool instanceof fa||this.tool instanceof Pd)){if(this.diagram.selectedObject.actualObject&&""!==this.diagram.selectedObject.actualObject.parentId){var S=this.diagram.getObject(this.diagram.selectedObject.actualObject.parentId);S&&S.isLane&&(this.commandHandler.isContainer=!0)}(u=this.diagram.lineRoutingModule&&this.diagram.nameTable.helper&&this.eventArgs.target&&this.eventArgs.target.isLane&&(this.eventArgs.source instanceof ei&&this.eventArgs.source.nodes.length>0&&""===this.eventArgs.source.nodes[0].parentId||""===this.eventArgs.source.parentId))&&(this.diagram.diagramActions=this.diagram.diagramActions|ee.PreventLaneContainerUpdate),this.tool.mouseUp(this.eventArgs,f.isPreventHistory)}else{if(this.diagram.selectedItems.canToggleSelection){var b=void 0,M=void 0;if(this.diagram.selectedItems.nodes.length>0)for(var w=0;w1&&D[0].id===i[parseInt(w.toString(),10)].id||r.length>0)&&(M=!0);!this.isSwimlaneSelected&&!s&&!M&&this.tool instanceof fa&&"Select"===this.currentAction&&(!b||this.diagram.selectedItems.connectors.length>0)&&this.commandHandler.clearSelection(!0)}this.isSwimlaneSelected=!1,this.tool.mouseUp(this.eventArgs),this.diagram.checkMenu&&(-1!==window.navigator.userAgent.indexOf("Linux")||-1!==window.navigator.userAgent.indexOf("X11"))&&(!t.pageY&&t instanceof TouchEvent&&t.changedTouches?(window.getSelection().removeAllRanges(),this.diagram.contextMenuModule.contextMenu.open(t.changedTouches[0].pageY,t.changedTouches[0].pageX,this.diagram.element),t.preventDefault()):this.diagram.contextMenuModule.contextMenu.open(t.pageY,t.pageX,this.diagram.element),this.diagram.checkMenu=!1)}f.hasStack&&this.diagram.endGroupAction()}if(p&&this.diagram.endGroupAction(),this.updateContainerBounds(!0),2!==this.eventArgs.clickCount&&(this.commandHandler.updateSelectedNodeProperties(this.eventArgs.source),u)){this.diagram.diagramActions=this.diagram.diagramActions&~ee.PreventLaneContainerUpdate;var A=this.eventArgs.source instanceof ei?this.eventArgs.source.nodes:[this.eventArgs.source];if(A)for(w=0;w0&&!N&&this.diagram.renderSelector(!0),!this.inAction&&!this.diagram.currentSymbol&&this.eventArgs){var T=this.getTargetElement();this.diagram.tool!==ri.ZoomPan&&this.diagram.triggerEvent(Ce.click,{element:T.target instanceof Es?T.target:this.eventArgs.source||this.diagram,position:this.eventArgs.position,count:t.detail,actualObject:this.eventArgs.actualObject,button:0===t.button?"Left":1===t.button?"Middle":"Right"})}this.eventArgs={}}this.diagram.diagramActions=this.diagram.diagramActions&~ee.PreventLaneContainerUpdate,e&&this.updateAnnotation(this.diagram.selectedItems),this.previousElement=null,this.eventArgs={},this.diagram.commandHandler.removeStackHighlighter()},n.prototype.isSwimlaneChild=function(t){if(t.shape&&"SwimLane"!==t.shape.type){var e=this.diagram.nameTable[t.parentId];if(!e)return!1;var i=e.parentId?this.diagram.nameTable[e.parentId]:e;return i&&i.shape&&"SwimLane"===i.shape.type}return!1},n.prototype.updateAnnotation=function(t){var e=t.nodes;if(e.length>0)for(var i=0;i0&&(a+=1),h.isPhase){l="Horizontal"===r.orientation?this.currentPosition.x-e.wrapper.bounds.x:this.currentPosition.y-(e.wrapper.bounds.y+r.header.height);var g={id:Qe(),offset:l,header:{annotation:{content:void 0===h.phases[0].header?"Phase":h.phases[0].header.annotation.content,style:void 0===h.phases[0].header?{}:h.phases[0].header.annotation.style}},style:void 0===h.phases[0]?{}:h.phases[0].style};this.diagram.addPhases(e,[g])}else{var v={id:Qe(),style:h.lanes[0].style,header:{annotation:{content:h.lanes[0].header.annotation.content,style:h.lanes[0].header.annotation.style},style:h.lanes[0].header.style}};if("Horizontal"===h.orientation?v.height=h.lanes[0].height:v.width=h.lanes[0].width,"Horizontal"===r.orientation?(s=i.rowIndex?i.rowIndex:this.diagram.nameTable[i.parentId].rowIndex,i.wrapper.offsetYs)v.header.width=r.lanes[parseInt(s.toString(),10)].header.width,v.header.height=r.lanes[parseInt(s.toString(),10)].header.height;else{var S=void 0;S="Horizontal"===r.orientation?i.rowIndex<3?0:s-a-1:s-1,v.header.width=r.lanes[parseInt(S.toString(),10)].header.width,v.header.height=r.lanes[parseInt(S.toString(),10)].header.height}p&&("height"===p?(v.width=v.height,delete v.height):(v.height=v.width,delete v.width)),this.diagram.addLanes(e,[v],"Horizontal"===r.orientation?s-a:s)}this.commandHandler.select(e)}else if(h.isLane){var b={id:Qe(),width:t.width,height:t.height,addInfo:t.addInfo,shape:{type:"SwimLane",header:{annotation:{content:void 0===h.header?"Header":h.header.annotation.content,style:void 0===h.header?{}:h.header.annotation.style},height:50,style:h.header?h.header.style:h.lanes[0].header.style},phases:[{id:Qe(),header:{annotation:{content:void 0===h.phases||void 0===h.phases[0].header?"Phase":h.phases[0].header.annotation.content,style:void 0===h.phases||void 0===h.phases[0].header?{}:h.phases[0].header.annotation.style},style:void 0===h.phases||void 0===h.phases[0].header?{}:h.phases[0].header.style},style:void 0===h.phases?{}:h.phases[0].style}],lanes:[{id:Qe(),height:t.height,width:t.width,style:h.lanes[0].style,header:{annotation:{content:h.lanes[0].header.annotation.content,style:h.lanes[0].header.annotation.style},style:h.lanes[0].header.style}}],orientation:h.orientation}};"Vertical"===h.orientation&&(b.width+=20),b.offsetX=this.currentPosition.x+b.width/2,b.offsetY=this.currentPosition.y+b.height/2,b.style=t.style,this.diagram.add(b)}},n.prototype.mouseLeave=function(t){this.tool&&this.inAction&&this.tool.mouseLeave(this.eventArgs),this.diagram.selectedObject.helperObject&&(this.updateContainerProperties(),this.updateContainerBounds()&&this.diagram.endGroupAction()),this.eventArgs&&this.eventArgs.source&&(this.diagram.updatePortVisibility(this.eventArgs.source,ci.Hover,!0),this.hoverElement=null),this.eventArgs&&!this.eventArgs.source&&this.hoverElement&&(this.hoverElement=null),this.tool instanceof kd&&this.eventArgs&&this.eventArgs.target&&this.eventArgs.target instanceof te&&(this.diagram.updatePortVisibility(this.eventArgs.target,ci.Hover|ci.Connect,!0),this.hoverElement=null);var i=this.diagram.selectedItems;i&&i.wrapper&&(lm(this.diagram,i)||this.diagram.renderSelector(!0)),(this.diagram.diagramActions&ee.Interactions||this.diagram.diagramActions&ee.ToolAction)&&(this.diagram.diagramActions=this.diagram.diagramActions&~ee.ToolAction),this.isMouseDown=!1,this.focus=!1,this.touchStartList=null,this.touchMoveList=null,this.elementLeave(),this.commandHandler.removeSnap(),this.inAction=!1,this.eventArgs={},this.diagram.selectedObject&&this.diagram.selectedObject.helperObject&&(this.diagram.remove(this.diagram.selectedObject.helperObject),this.diagram.selectedObject={helperObject:void 0,actualObject:void 0}),this.tool=null,function rse(){var t,e,n=document.getElementsByClassName("e-d-ruler-marker");if(n&&n.length>0)for(e=n.length-1;e>=0;e--)(t=n[parseInt(e.toString(),10)])&&t.parentNode.removeChild(t)}(),"Rotate"===this.action&&this.diagram.diagramCanvas.classList.remove("e-diagram-rotate"),t.preventDefault()},n.prototype.mouseWheel=function(t){this.diagram.blazorActions|=on.interaction;var e={event:t,cancel:!1};if(this.diagram.triggerEvent(Ce.mouseWheel,e),!e.cancel){var i=t.wheelDelta>0||-40*t.detail>0,r=this.getMousePosition(t);if(this.diagram.tooltipObject.close(),this.isMetaKey(t)){var o=this.diagram.scrollSettings.zoomFactor;this.diagram.zoomTo(i?{type:"ZoomIn",zoomFactor:o,focusPoint:r}:{type:"ZoomOut",zoomFactor:o,focusPoint:r}),t.preventDefault()}else{var a=this.diagram.scroller.horizontalOffset,l=this.diagram.scroller.verticalOffset,h=i?10:-10;this.tool&&(this.tool instanceof Rl||this.tool instanceof Hl)&&(this.eventArgs={},this.getMouseEventArgs(r,this.eventArgs),this.eventArgs.position=r,this.tool.mouseWheel(this.eventArgs)),this.diagram.scrollActions|=da.Interaction;var c=!0;if(t.isTrusted){var d=!1;(Math.abs(t.deltaY)<100&&-0===Math.abs(t.deltaX)||Math.abs(t.deltaX)<100&&-0===Math.abs(t.deltaY))&&(d=!0);var u=!1;(0!==t.deltaX||0!==t.deltaY)&&(u=navigator.userAgent.includes("Macintosh")),u?Math.abs(t.deltaX)>Math.abs(t.deltaY)?(t.shiftKey||t.deltaX&&-0!==t.deltaX&&(d||!u))&&this.diagram.scroller.zoom(1,h,0,r,c,void 0,d):t.deltaY&&-0!==t.deltaY&&(d||!u)&&this.diagram.scroller.zoom(1,0,h,r,c,void 0,d):t.shiftKey||t.deltaX&&-0!==t.deltaX&&(d||!u)?this.diagram.scroller.zoom(1,h,0,r,c,void 0,d):t.deltaY&&-0!==t.deltaY&&(d||!u)&&this.diagram.scroller.zoom(1,0,h,r,c,void 0,d)}else t.shiftKey||t.deltaX&&-0!==t.deltaX?this.diagram.scroller.zoom(1,h,0,r,c):this.diagram.scroller.zoom(1,0,h,r,c);this.diagram.scrollActions&=~da.Interaction,(a!==this.diagram.scroller.horizontalOffset||l!==this.diagram.scroller.verticalOffset)&&t.preventDefault()}if(this.diagram.textEditing){if(this.diagram.isTriggerEvent=!0,this.diagram.activeLabel.parentId){var p=this.diagram.getObject(this.diagram.activeLabel.parentId);this.diagram.startTextEdit(p,this.diagram.activeLabel.id)}this.diagram.isTriggerEvent=!1}this.diagram.blazorActions=this.diagram.blazorActions&~on.interaction}},n.prototype.keyDown=function(t){if(t.fromMouseEvents&&(t.ctrlKey&&(this.keyArgs.keyModifiers=1),t.shiftKey&&(this.keyArgs.keyModifiers=4),t.shiftKey&&t.ctrlKey&&(this.keyArgs.keyModifiers=5)),!(this.diagram.diagramActions&ee.TextEdit)&&!this.checkEditBoxAsTarget(t)||"Escape"===t.key||27===t.keyCode){var i=void 0,r=t.keyCode?t.keyCode:t.which,s=t.key;("ArrowDown"===s||"ArrowUp"===s||"ArrowLeft"===s||"ArrowRight"===s)&&(this.isNudgeKey=!0);var o=this.isMetaKey(t);if(this.diagram.commandManager&&this.diagram.commands)for(var l=0,h=Object.keys(this.diagram.commands);l4&&(S({keyDownEventArgs:KeyboardEvent,parameter:i.parameter,type:"KEYDOWN"}),this.keyCount=0,this.keyArgs.newValue={offsetX:this.diagram.selectedItems.offsetX,offsetY:this.diagram.selectedItems.offsetY},this.diagram.triggerEvent(Ce.positionChange,this.keyArgs))),this.isKeyUp=!1):S({keyDownEventArgs:KeyboardEvent,parameter:i.parameter})}break}}}}this.keyArgs={element:this.diagram.selectedItems,key:t.key,keyCode:t.keyCode?t.keyCode:t.which},this.getKeyModifier(this.keyArgs,t),this.diagram.diagramActions&ee.TextEdit&&this.getlabel(this.keyArgs,t),this.diagram.triggerEvent(Ce.keyDown,this.keyArgs)},n.prototype.getlabel=function(t,e){var i=this.diagram.activeLabel;t.target=this.diagram.element.id+"_editBox";var r=this.diagram.nameTable[i.parentId];if(document.getElementById(this.diagram.element.id+"_editBox")){t.text=document.getElementById(this.diagram.element.id+"_editBox").value;for(var s=0;s=this.diagram.scroller.viewPortWidth-18?r="right":e.x+this.diagram.scroller.horizontalOffsetthis.diagram.scroller.viewPortHeight-18?r="bottom":e.y+this.diagram.scroller.verticalOffset0&&(s=this.findIntersectChild(this.hoverElement)),"Auto"===this.hoverElement.tooltip.openOn&&""!==r&&Ex(this.diagram,s||(i?this.hoverElement:void 0)),this.hoverElement.tooltip.content&&("Mouse"===this.hoverElement.tooltip.relativeMode?this.setTooltipOffset(t):(this.diagram.tooltipObject.offsetX=0,this.diagram.tooltipObject.offsetY=0));var o=this.diagram.findObjectsUnderMouse(this.currentPosition),a=this.diagram.findObjectUnderMouse(o,this.action,this.inAction);if(null!==a){var l=void 0;this.hoverElement.tooltip.isSticky&&(this.diagram.tooltipObject.isSticky=!0),a instanceof te&&a.children&&a.children.length>0&&(a=s||a),l=a.ports&&(this.hoverElement instanceof Es||this.hoverElement instanceof Tc)||a.annotations&&(this.hoverElement instanceof Kn||this.hoverElement instanceof Or)?document.getElementById(a.id+"_"+this.hoverElement.id):document.getElementById(a.id+(a.shape&&a.shape instanceof hm?"_content_native_element":"_groupElement")),"Auto"===this.hoverElement.tooltip.openOn&&""!==r&&(this.diagram.tooltipObject.close(),this.diagram.tooltipObject.openOn=this.hoverElement.tooltip.openOn,this.diagram.tooltipObject.dataBind()),function Kre(n,t){var e=0;return n instanceof de?n.constraints&qe.Tooltip?e=n.constraints&qe.Tooltip:n.constraints&qe.InheritTooltip&&(e=t.constraints&nt.Tooltip):n instanceof Es||n instanceof Tc?n.constraints&oi.ToolTip?e=n.constraints&oi.ToolTip:n.constraints&oi.InheritTooltip&&(e=t.constraints&nt.Tooltip):n instanceof Kn||n instanceof Or?n.constraints&Nr.Tooltip&&(e=n.constraints&Nr.Tooltip):n.constraints&ie.Tooltip?e=n.constraints&ie.Tooltip:n.constraints&ie.InheritTooltip&&(e=t.constraints&nt.Tooltip),e}(this.hoverElement,this.diagram)&&"Auto"===this.hoverElement.tooltip.openOn&&(this.diagram.tooltipObject.target=this.hoverElement.id,this.diagram.tooltipObject.open("Mouse"===this.hoverElement.tooltip.relativeMode?this.diagram.element:l))}}},n.prototype.elementLeave=function(){this.diagram.tooltipObject&&!this.diagram.tooltipObject.isSticky&&"Custom"!==this.diagram.tooltipObject.openOn&&this.diagram.tooltipObject.close()},n.prototype.setTooltipOffset=function(t){var e=function Mse(n,t,e,i){var o="Mouse"===(!(e instanceof te?e.constraints&ie.InheritTooltip:e instanceof de?e.constraints&qe.InheritTooltip:e.constraints&oi.InheritTooltip)&&(e instanceof te?e.constraints&ie.Tooltip:e instanceof de?e.constraints&qe.Tooltip:e.constraints&oi.ToolTip)?e.tooltip.relativeMode:n.tooltip.relativeMode);"Mouse"===i?o=!0:"Object"===i&&(o=!1);var a=function wse(n,t,e,i){var o,r={},s=document.getElementById(e.element.id);if(n instanceof te||n instanceof de)o=n.wrapper.bounds;else{var a=e.findObjectsUnderMouse(t),l=e.findObjectUnderMouse(a,"Select",!1);o=e.findElementUnderMouse(l,t,e).bounds}var c=s.getBoundingClientRect();switch(e.tooltipObject.position){case"BottomCenter":r=zc(t,o.bottomCenter,e,i,c.width/2,c.height);break;case"BottomLeft":case"LeftBottom":r=zc(t,o.bottomLeft,e,i,0,c.height);break;case"BottomRight":case"RightBottom":r=zc(t,o.bottomRight,e,i,c.width,c.height);break;case"LeftCenter":r=zc(t,o.middleLeft,e,i,0,c.height/2);break;case"LeftTop":case"TopLeft":r=zc(t,o.topLeft,e,i,0,0);break;case"RightCenter":r=zc(t,o.middleRight,e,i,c.width,c.height/2);break;case"RightTop":case"TopRight":r=zc(t,o.topRight,e,i,c.width,0);break;case"TopCenter":r=zc(t,o.topCenter,e,i,c.width/2,0)}return r}(e,t,n,o),l=Za(n);return{x:a.x+l.width,y:a.y+l.height}}(this.diagram,t,this.hoverElement);this.diagram.tooltipObject.offsetX=e.x,this.diagram.tooltipObject.offsetY=e.y},n.prototype.altKeyPressed=function(t){return!!(t&ft.Alt)},n.prototype.ctrlKeyPressed=function(t){return!!(t&ft.Control)},n.prototype.shiftKeyPressed=function(t){return!!(t&ft.Shift)},n.prototype.scrolled=function(t){this.diagram.updateScrollOffset()},n.prototype.isMobileOrIPadDevice=function(){var t=navigator.userAgent||navigator.vendor||window.opera;return/iPhone|iPad|iPod/.test(t)&&!window.MSStream?"iOS":/android/i.test(t)?"Android":/Mobile|Tablet/.test(t)?"Mobile":"Desktop"},n.prototype.doubleClick=function(t){if(Vv(this.diagram)){var e=this.isMobileOrIPadDevice(),i=this.diagram.tool;"Desktop"!==e&&this.tool&&(this.tool instanceof Rl||this.tool instanceof Hl)&&(this.diagram.tool=0);var r=void 0,s=this.diagram.findObjectsUnderMouse(this.currentPosition),o=this.diagram.findObjectUnderMouse(s,this.action,this.inAction);if(null!==o&&Vv(this.diagram))if(r=this.diagram.findElementUnderMouse(o,this.currentPosition,this.diagram),this.tool&&(this.tool instanceof Rl||this.tool instanceof Hl))this.diagram.tool=i,this.tool.mouseUp(this.eventArgs),this.isMouseDown=!1,this.eventArgs={},this.tool=null,t.preventDefault();else{var l=this.diagram.commandHandler.getObjectLayer(o.id);!l||l.lock||!l.visible||this.diagram.diagramActions&ee.TextEdit||this.diagram.startTextEdit(o,r instanceof ai?r.id.split(o.id+"_")[1]:void 0)}this.diagram.triggerEvent(Ce.doubleClick,{source:o||this.diagram,position:this.currentPosition,count:t.detail})}},n.prototype.itemClick=function(t,e){var i=t;return Dn(this.diagram,i,!0)?i:null},n.prototype.inputChange=function(t){var i,s,o,a,l,h,c,d,u,f=document.getElementById(this.diagram.element.id+"_editBox"),p=document.getElementById(this.diagram.element.id+"_editTextBoxDiv"),g=f.value,v=g.split("\n");(!(a=this.diagram.selectedItems.nodes[0]?this.diagram.selectedItems.nodes[0]:this.diagram.selectedItems.connectors[0])&&this.tool instanceof $I||a&&"SwimLane"===a.shape.type)&&(a=this.diagram.nameTable[this.diagram.activeLabel.parentId]),a&&("Text"!==a.shape.type&&a.annotations.length>0||"Text"===a.shape.type)&&(c=HF((o=this.diagram.getWrapper(a.wrapper,this.diagram.activeLabel.id)).style,g,void 0,void 0,i=(i=a.wrapper.bounds.width90?i:90),s=Number(f.style.fontSize.split("px")[0]),v.length>1&&""===v[v.length-1]&&(c.height=c.height+s),d=this.diagram.scroller.transform,u=P3(this.diagram)?d.scale:1,l=(12>c.height?12:c.height)*u,p.style.left=(o.bounds.center.x+d.tx)*d.scale-(h=(90>(h=c.width)?90:h)*u)/2-2.5+"px",p.style.top=(o.bounds.center.y+d.ty)*d.scale-l/2-3+"px",p.style.width=h+"px",p.style.height=l+"px",f.style.minHeight="12px",f.style.minWidth="90px",f.style.width=h+"px",f.style.height=l+"px")},n.prototype.isAddTextNode=function(t,e){return!(!(this.tool instanceof $I||e)||(this.tool=null,t&&!_I(this.diagram)&&(this.diagram.drawingObject=void 0,this.diagram.currentDrawingObject=void 0),MF(this.diagram.nodes,t.id)||MF(this.diagram.connectors,t.id)))},n.prototype.checkEditBoxAsTarget=function(t){return!(!t.target||t.target.id!==this.diagram.element.id+"_editBox")},n.prototype.getMouseEventArgs=function(t,e,i,r){var s,o,a;if(e.position=t,i?(o=this.diagram.findObjectsUnderMouse(this.currentPosition,i),s=this.diagram.findTargetObjectUnderMouse(o,this.action,this.inAction,e.position,i)):"Drag"===this.action||"ConnectorSourceEnd"===this.action||"SegmentEnd"===this.action||"OrthoThumb"===this.action||"BezierSourceThumb"===this.action||"BezierTargetThumb"===this.action||"ConnectorTargetEnd"===this.action||-1!==this.action.indexOf("Rotate")||-1!==this.action.indexOf("Resize")?(s=this.diagram.selectedItems,!this.diagram.currentSymbol&&"Drag"===this.action&&s&&this.diagram.selectedItems.nodes.length>0&&"SwimLane"===this.diagram.selectedItems.nodes[0].shape.type&&(o=this.diagram.findObjectsUnderMouse(this.currentPosition),s=this.diagram.findObjectUnderMouse(o,this.action,this.inAction))):(o=this.diagram.findObjectsUnderMouse(this.currentPosition),s=this.diagram.findObjectUnderMouse(o,this.action,this.inAction)),s&&s.isHeader&&(this.eventArgs.actualObject=s=this.diagram.nameTable[s.parentId]),s){var l=void 0,h=void 0,c=void 0;if(((a=this.diagram.findElementUnderMouse(s,this.currentPosition,this.diagram,r))&&s.ports&&s.ports.length&&!lb(s,a)||!a||!s)&&o&&o.length&&i instanceof ei)for(l=i.connectors[0],c=o.length-1;c>=0;c--)if(((h=o[parseInt(c.toString(),10)])instanceof te||h instanceof de)&&l&&l.connectionPadding){if(a=this.diagram.findElementUnderMouse(s=h,this.currentPosition,this.diagram,r),l.constraints&qe.ConnectToNearByPort&&s&&s.ports&&s.ports.length&&lb(s,a))break;if((h instanceof te||h instanceof de)&&l&&l.connectionPadding&&h.wrapper.outerBounds.containsPoint(this.currentPosition)&&l.constraints&qe.ConnectToNearByNode&&!(l.constraints&qe.ConnectToNearByPort)){a=this.diagram.findElementUnderMouse(s=h,this.currentPosition,this.diagram,0);break}}}return i?(e.target=s,e.targetWrapper=a):(e.source=s,e.sourceWrapper=a),e.actualObject=this.eventArgs.actualObject,e.source instanceof ei&&void 0===e.actualObject&&(e.source.nodes.length>0||e.source.connectors.length>0)&&(e.actualObject=e.source.nodes.length>0?this.diagram.nameTable[e.source.nodes[0].id]:this.diagram.nameTable[e.source.connectors[0].id]),e.startTouches=this.touchStartList,e.moveTouches=this.touchMoveList,e},n.prototype.resetTool=function(){this.action="Select",this.hoverElement=null,this.hoverNode=null,this.tool=this.diagram.getTool(this.action),this.updateCursor()},n.prototype.updateTool=function(){this.action=this.currentPosition&&"Pan"!==this.action?"Pan":"Select"},n.prototype.getTool=function(t){switch(t){case"Select":return new Kv(this.commandHandler,!0);case"Drag":return new fa(this.commandHandler);case"Rotate":return new Xx(this.commandHandler);case"LayoutAnimation":return new Une(this.commandHandler);case"FixedUserHandle":return new _ne(this.commandHandler,!0);case"Hyperlink":return new eF(this.commandHandler);case"ResizeSouthEast":case"ResizeSouthWest":case"ResizeNorthEast":case"ResizeNorthWest":case"ResizeSouth":case"ResizeNorth":case"ResizeWest":case"ResizeEast":return new Pd(this.commandHandler,t);case"ConnectorSourceEnd":case"ConnectorTargetEnd":case"BezierSourceThumb":case"BezierTargetThumb":return new kd(this.commandHandler,t);case"SegmentEnd":case"OrthoThumb":return new r_(this.commandHandler,t);case"Draw":var e="shape",i=function gse(n){var t;return n&&(n.type?t="Connector":n.shape&&!n.type&&(t="Node")),t}(this.diagram.drawingObject);if("Node"===i&&"Text"===this.diagram.drawingObject.shape.type)return new $I(this.commandHandler);if("Connector"===i&&"Freehand"===this.diagram.drawingObject.type)return new Yne(this.commandHandler);if("Node"===i&&"Polygon"===this.diagram.drawingObject.shape[""+e]&&!this.diagram.drawingObject.shape.points)return new Rl(this.commandHandler);if("Node"===i||"Node"===i&&"Polygon"===this.diagram.drawingObject.shape[""+e]&&this.diagram.drawingObject.shape.points)return new qI(this.commandHandler,this.diagram.drawingObject);if("Connector"===i&&"Polyline"===this.diagram.drawingObject.type)return new Hl(this.commandHandler);if("Connector"===i)return new pa(this.commandHandler,"ConnectorSourceEnd",this.diagram.drawingObject);break;case"Pan":return new em(this.commandHandler,!1);case"PinchZoom":return new em(this.commandHandler,!0);case"PortDrag":return new fa(this.commandHandler,"Port");case"PortDraw":return new pa(this.commandHandler,"ConnectorSourceEnd",this.diagram.drawingObject);case"LabelSelect":return new Kv(this.commandHandler,!0,"LabelSelect");case"LabelDrag":return new jne(this.commandHandler);case"LabelResizeSouthEast":case"LabelResizeSouthWest":case"LabelResizeNorthEast":case"LabelResizeNorthWest":case"LabelResizeSouth":case"LabelResizeNorth":case"LabelResizeWest":case"LabelResizeEast":return new Vne(this.commandHandler,t);case"LabelRotate":return new Wne(this.commandHandler)}return null},n.prototype.getCursor=function(t){var e=this.diagram.selectedItems.annotation?this.diagram.selectedItems.wrapper.children[0]:this.diagram.selectedItems;return function Fne(n,t){if(t+=360,t%=360,-1===n.indexOf("Resize"))return Gx[""+n];var e=Gx[""+n];return t>=0&&t<25||t>=160&&t<=205||t>=340&&t<=360?e:t>=25&&t<=70||t>=205&&t<=250?"n-resize"===e||"s-resize"===e?"ne-resize":"nw-resize"===e||"se-resize"===e?"n-resize":"e-resize"===e||"w-resize"===e?"nw-resize":"e-resize":t>=70&&t<=115||t>=250&&t<=295?"n-resize"===e||"s-resize"===e?"e-resize":"nw-resize"===e||"se-resize"===e?"ne-resize":"e-resize"===e||"w-resize"===e?"n-resize":"nw-resize":t>=115&&t<=155||t>=295&&t<=340?"n-resize"===e||"s-resize"===e?"nw-resize":"nw-resize"===e||"se-resize"===e?"e-resize":"e-resize"===e||"w-resize"===e?"ne-resize":Gx[""+n]:"n-resize"}(t,this.diagram.selectedItems.annotation?e.rotateAngle+e.parentTransform:e.rotateAngle)},n.prototype.findElementUnderMouse=function(t,e,i,r){return this.objectFinder.findElementUnderSelectedItem(t,e,i,r)},n.prototype.findObjectsUnderMouse=function(t,e){return this.objectFinder.findObjectsUnderMouse(t,this.diagram,this.eventArgs,e)},n.prototype.findObjectUnderMouse=function(t,e,i){return this.objectFinder.findObjectUnderMouse(this.diagram,t,e,i,this.eventArgs,this.currentPosition)},n.prototype.findTargetUnderMouse=function(t,e,i,r,s){return this.objectFinder.findObjectUnderMouse(this.diagram,t,e,i,this.eventArgs,r,s)},n.prototype.findActionToBeDone=function(t,e,i,r){return function kne(n,t,e,i,r,s,o){if(s&&s.length>1&&r&&r.length>1)return"PinchZoom";if(i.currentSymbol)return"Drag";if("PortDraw"===i.eventHandler.action&&(i.tool&=~ri.DrawOnce),(k3(i)||_I(i))&&i.drawingObject)return"Draw";if($a(i)&&(l=i.selectedItems).wrapper&&qr(l.constraints,"UserHandle"))for(var h=0,c=l.userHandles;h=50&&(l.x=(a.points[parseInt(h.toString(),10)].x+a.points[h+1].x)/2,l.y=(a.points[parseInt(h.toString(),10)].y+a.points[h+1].y)/2,wr(e,l,n.hitPadding?n.hitPadding:10)))return"OrthoThumb"}else RI(n)&&console.warn('[WARNING] :: Module "ConnectorEditing" is not available in Diagram component! You either misspelled the module name or forgot to load it.');return null}(g,l,e,i);if("OrthoThumb"===S)return S;if(qr(l.constraints,"ConnectorSourceThumb")&&PI(g)&&S||qr(l.constraints,"ConnectorTargetThumb")&&zI(g)&&S)return S}}else{var b=i.selectedItems.handleSize/2/i.scroller.currentZoom,M=10/i.scroller.currentZoom,w=Bi();qi(w,f.rotateAngle+f.parentTransform,f.offsetX,f.offsetY);var C=f.offsetX-f.pivot.x*f.actualSize.width,D=f.offsetY-f.pivot.y*f.actualSize.height,A={x:C+(.5===f.pivot.x?2*f.pivot.x:f.pivot.x)*f.actualSize.width/2,y:D-30/i.scroller.currentZoom};A=Ke(w,A);var x=!!i.selectedItems.annotation,P=!(!x||!HI(i.selectedItems.annotation));if(qr(l.constraints,"Rotate")&&wr(e,A,M)&&i.selectedItems.thumbsConstraints&bt.Rotate){if(x&&P)return"LabelRotate";if(!x)return"Rotate"}if(u.Inflate(b),u.containsPoint(e)&&(S=function Pne(n,t,e,i,r,s){var o;return 1===n.selectedItems.nodes.length&&0===n.selectedItems.connectors.length&&n.selectedItems.nodes[0].container&&(o=function Hne(n,t,e,i,r){var s=10/n.scroller.currentZoom,o=n.selectedItems,a=t.actualSize.width,l=t.actualSize.height,h=new Ne(i,r,t.style.strokeWidth,l),c=new Ne(i+a,r,t.style.strokeWidth,l),d=new Ne(i,r,a,t.style.strokeWidth),u=new Ne(i,r+l,a,t.style.strokeWidth),f=Dn(n,n.selectedItems.nodes[0],!0)?n.nameTable[n.selectedItems.nodes[0].parentId]:n.selectedItems.nodes[0];if(ga(o.constraints,"ResizeEast",o.thumbsConstraints,o)&&c.containsPoint(e,s))return"ResizeEast";if(ga(o.constraints,"ResizeSouth",o.thumbsConstraints,o)&&u.containsPoint(e,s))return"ResizeSouth";if("Grid"!==f.container.type){if(ga(o.constraints,"ResizeWest",o.thumbsConstraints,o)&&h.containsPoint(e,s))return"ResizeWest";if(ga(o.constraints,"ResizeNorth",o.thumbsConstraints,o)&&d.containsPoint(e,s))return"ResizeNorth"}return null}(n,t,e,r,s)),!o&&(!n.selectedItems.nodes[0]||!n.selectedItems.nodes[0].isPhase&&!n.selectedItems.nodes[0].isLane&&"SwimLane"!==n.selectedItems.nodes[0].shape.type)&&(o=function Bne(n,t,e,i,r,s){var o=40/n.scroller.currentZoom,a=n.selectedItems.handleSize/2/n.scroller.currentZoom,l=n.selectedItems,h=!!l.annotation;if(t.actualSize.width>=o&&t.actualSize.height>=o){if(ga(l.constraints,"ResizeSouthEast",l.thumbsConstraints,l)&&wr(e,Ke(i,{x:r+t.actualSize.width,y:s+t.actualSize.height}),a))return h?"LabelResizeSouthEast":"ResizeSouthEast";if(ga(l.constraints,"ResizeSouthWest",l.thumbsConstraints,l)&&wr(e,Ke(i,{x:r,y:s+t.actualSize.height}),a))return h?"LabelResizeSouthWest":"ResizeSouthWest";if(ga(l.constraints,"ResizeNorthEast",l.thumbsConstraints,l)&&wr(e,Ke(i,{x:r+t.actualSize.width,y:s}),a))return h?"LabelResizeNorthEast":"ResizeNorthEast";if(ga(l.constraints,"ResizeNorthWest",l.thumbsConstraints,l)&&wr(e,Ke(i,{x:r,y:s}),a))return h?"LabelResizeNorthWest":"ResizeNorthWest"}return ga(l.constraints,"ResizeEast",l.thumbsConstraints,l)&&wr(e,Ke(i,{x:r+t.actualSize.width,y:s+t.actualSize.height/2}),a)?h?"LabelResizeEast":"ResizeEast":ga(l.constraints,"ResizeWest",l.thumbsConstraints,l)&&wr(e,Ke(i,{x:r,y:s+t.actualSize.height/2}),a)?h?"LabelResizeWest":"ResizeWest":ga(l.constraints,"ResizeSouth",l.thumbsConstraints,l)&&wr(e,Ke(i,{x:r+t.actualSize.width/2,y:s+t.actualSize.height}),a)?h?"LabelResizeSouth":"ResizeSouth":ga(l.constraints,"ResizeNorth",l.thumbsConstraints,l)&&wr(e,Ke(i,{x:r+t.actualSize.width/2,y:s}),a)?h?"LabelResizeNorth":"ResizeNorth":null}(n,t,e,i,r,s)),o||null}(i,f,e,w,C,D),S))return S}}if(Lc(i)&&!n)return"Pan";if((o instanceof Es||o instanceof Tc)&&(!Lc(i)||Uv(i)||jv(i))&&(S=function Rne(n,t,e,i){if(_x(t)&&(va(t,ci.Hover)||va(t,ci.Visible))){if(t.constraints&oi.Drag)return"PortDrag"}else if(Fx(t)&&(va(t,ci.Hover)||va(t,ci.Visible))&&t.constraints&oi.Draw){n.drawingObject={};var r={type:"Orthogonal",sourcePortID:t.id};return n.drawingObject=r,n.tool|=ri.DrawOnce,n.currentDrawingObject=r,"PortDraw"}return"None"}(i,o),"None"!==S))return S;if((o instanceof Kn||o instanceof Or)&&!Lc(i)&&xd(o))return _r(i,o,void 0,t)&&ro(o)?"LabelDrag":"LabelSelect";if(null!==n){if(!(n instanceof te||n instanceof de))return"Select";if(t&&t.id){var L=t.id.split(n.id)[1];if(L&&L.match("^_icon"))return"LayoutAnimation"}if(t&&t.id)for(var O=void 0,N=0;N-1)return"FixedUserHandle";if(t instanceof ai&&t.hyperlink.link)return"Hyperlink";if(!ro(n)||!_r(i,n,!1)||void 0!==i.selectedItems.annotation)return n&&Lc(i)&&!UI(i)?"Pan":i.selectedItems.nodes.length&&i.selectedItems.nodes[0].isLane&&i.selectedItems.wrapper&&i.selectedItems.wrapper.bounds.containsPoint(e)?"Drag":"Select";if(n instanceof de&&!wr(e,n.sourcePoint,n.hitPadding)&&!wr(e,n.targetPoint,n.hitPadding)||!(n instanceof de))return"Drag"}return"Select"}(t,e,this.currentPosition,this.diagram,this.touchStartList,this.touchMoveList,r)},n.prototype.updateContainerBounds=function(t){var e=!1;if(this.diagram.selectedObject.helperObject&&this.diagram.selectedObject.actualObject)for(var i=this.diagram.selectedObject.actualObject,r=this.diagram.selectedObject.actualObject instanceof ei?i.nodes:[i],s=0;si.y&&(h+=u>0?-1:1,u+=u>0?-1:1):i&&e.wrapper.offsetYi.x&&(h+=u>0?-1:1,u+=u>0?-1:1):i&&e.wrapper.offsetX1)for(var S=t.offsetX-this.diagram.selectedItems.offsetX,b=t.offsetY-this.diagram.selectedItems.offsetY,M=t.rotateAngle-this.diagram.selectedItems.rotateAngle,w=0;w-1){var A=c.children;A.splice(A.indexOf(o.id),1),this.diagram.nameTable[o.id].parentId="",i=!0,c.wrapper.children.splice(D,1)}}if(function One(n,t,e,i){var r=n,s=e.nameTable[r.parentId],o=e.nameTable[r.parentId];if(t&&o&&o.container&&"Stack"===o.container.type&&t.container&&"Stack"===t.container.type&&o.id!==t.parentId){var a=o.wrapper.children.indexOf(r.wrapper);a>-1&&(e.nameTable[r.id].parentId=t.id,o.wrapper.children.splice(a,1))}if(t&&t.parentId&&r.parentId&&"Drag"===i&&o.container&&"Stack"===o.container.type){var l=s.wrapper.children.indexOf(t.wrapper),h=s.wrapper.children.indexOf(r.wrapper),c={targetIndex:l,target:t,sourceIndex:h,source:n};s.wrapper.children.splice(h,1),s.wrapper.children.splice(l,0,r.wrapper),e.commandHandler.addHistoryEntry({type:"StackChildPositionChanged",redoObject:{targetIndex:h,target:t,sourceIndex:l,source:n},undoObject:c,category:"Internal"})}}(o,h,this.diagram,this.action),(c=Dn(this.diagram,o)?this.diagram.nameTable[o.parentId]:this.diagram.nameTable[o.parentId]||o)&&c.container&&"Canvas"===c.container.type&&(c.wrapper.maxWidth=c.maxWidth=c.wrapper.actualSize.width,c.wrapper.maxHeight=c.maxHeight=c.wrapper.actualSize.height,e=!0),Dn(this.diagram,o,!0)&&c&&"Canvas"===c.container.type)if(this.diagram.selectedItems.nodes.length>1)for(w=0;w0)for(var i=0;i0&&e.columnIndex>0||l&&e.isLane)){if("Horizontal"===t.container.orientation&&e.isPhase&&e.wrapper.width>e.maxWidth&&(e.maxWidth=e.wrapper.width,e.wrapper.maxWidth=e.wrapper.width),h.updateColumnWidth(e.columnIndex,r.width,!0,c),Vx(this.diagram,e,t),e.isPhase){var p=this.diagram.nameTable[""+t.shape.phases[e.columnIndex].header.id];p.maxWidth0?(r=new sp(t,"",u),t.shape.classShape.attributes.push(r)):i.id.includes("_umlMethods")&&t.shape.classShape.methods.length>0&&(s=new dm(t,"",u),t.shape.classShape.methods.push(s))),"Interface"===t.shape.classifier&&(i.id.includes("_umlProperty")&&t.shape.interfaceShape.attributes.length>0?(r=new sp(t,"",u),t.shape.classShape.attributes.push(r)):i.id.includes("_umlMethods")&&t.shape.interfaceShape.methods.length>0&&(s=new dm(t,"",u),t.shape.interfaceShape.methods.push(s))),"Enumeration"===t.shape.classifier&&i.id.includes("_umlMember")&&t.shape.enumerationShape.members.length>0){var f=new db(t,"",u);t.shape.enumerationShape.members.push(f)}t.wrapper.children.indexOf(c.wrapper),this.diagram.enableServerDataBinding(!0),this.diagram.add(c),this.diagram.updateConnectorEdges(t),this.diagram.clearSelection(),this.diagram.select([this.diagram.nameTable[c.id]]),this.diagram.endGroupAction(),this.diagram.startTextEdit()}}},n}(),Zoe=function(){function n(){}return n.prototype.findObjectsUnderMouse=function(t,e,i,r,s){var o=[];r&&r instanceof ei&&r.nodes.length+r.connectors.length===1&&(r=r.nodes[0]||r.connectors[0]).children&&0===r.children.length&&(i.actualObject=r);for(var a,l,h,c,p,d=r&&r instanceof de&&(r.constraints&qe.ConnectToNearByNode||r.constraints&qe.ConnectToNearByPort)&&r.connectionPadding||0,f={},g=0,v=e.spatialSearch.findObjects(new Ne(t.x-50-d,t.y-50-d,100+d,100+d));g-1&&o.splice(T,1),"UmlClassifier"===y.shape.type&&y.container&&"Stack"===y.container.type&&(T=o.indexOf(e.nameTable[e.nameTable[y.id].wrapper.children[0].id]))>-1&&o.splice(T,1)}for(var z=0;zs.zIndex&&(t[parseInt(r.toString(),10)]=l),r>0&&i&&a&&(a.isLane||a.isPhase||a.isHeader)&&t[parseInt(r.toString(),10)].zIndex=2)for(var d=t.length-1;d>=0;d--)if(t[parseInt(d.toString(),10)].parentId){var u=am(t[parseInt(d.toString(),10)],e,""),f=am(t[d-1],e,""),g=e.nameTable[""+f];g&&u!==f&&e.nameTable[""+u].zIndex=0;p--){d=tp(e[parseInt(p.toString(),10)],!1),c=tp(e[parseInt(p.toString(),10)],!0);var g=t[""+l].tool,v=this.findTargetElement(e[parseInt(p.toString(),10)].wrapper,o,t,void 0);if("Draw"===i&&v&&(e[parseInt(p.toString(),10)]instanceof te||e[parseInt(p.toString(),10)]instanceof de)&&!lb(e[parseInt(p.toString(),10)],v)&&(g&&"ConnectorSourceEnd"===g[""+h]&&!Rh(e[parseInt(p.toString(),10)])||g&&"ConnectorTargetEnd"===g[""+h]&&!ua(e[parseInt(p.toString(),10)])))return u;if(e[parseInt(p.toString(),10)]instanceof te||e[parseInt(p.toString(),10)]instanceof de&&(Rh(e[parseInt(p.toString(),10)])||Td(d)||ua(e[parseInt(p.toString(),10)])||zh(c)||"PortDraw"===i&&g instanceof kd&&"ConnectorTargetEnd"===g[""+h]&&(ua(e[parseInt(p.toString(),10)])||zh(c))))return u=e[parseInt(p.toString(),10)],f&&(u=this.isTarget(u,t,i)),s.actualObject=u,u}else if("ConnectorTargetEnd"===i&&a){for(p=e.length-1;p>=0;p--)if(c=tp(e[parseInt(p.toString(),10)],!0),(e[parseInt(p.toString(),10)]instanceof te||e[parseInt(p.toString(),10)]instanceof de)&&(ua(e[parseInt(p.toString(),10)])||zh(c)))return u=e[parseInt(p.toString(),10)],u=this.isTarget(u,t,i),s.actualObject=u,u}else{if(a&&("Drag"===i||t[""+l].tool instanceof fa)){var y=0;for(p=0;p=S.zIndex?u:S,y=Math.max(y,S.zIndex)):y=(u=S).zIndex)}return u&&"Bpmn"===u.shape.type&&(t.selectedItems.nodes.length>0&&"Bpmn"===t.selectedItems.nodes[0].shape.type||(u=null)),u&&(s.actualObject=u),u}if("Select"!==i&&"Pan"!==i||!t[""+l].tool)if("Pan"===i||"LayoutAnimation"===i){for(p=e.length-1;p>=0;p--)if((e[parseInt(p.toString(),10)]instanceof te||e[parseInt(p.toString(),10)]instanceof de)&&(v=this.findTargetElement(e[parseInt(p.toString(),10)].wrapper,o,t,void 0),"Pan"===i||v&&(v.id.match("_icon_content_shape$")||v.id.match("_icon_content_rect$"))))return e[parseInt(p.toString(),10)]}else u=e[e.length-1],s&&u&&(s.actualObject=u);else{for(p=e.length-1;p>=0;p--)if(e[parseInt(p.toString(),10)]instanceof de){var b=e[p-1];if(e[p-1]instanceof te&&b.ports){if((v=this.findTargetElement(b.wrapper,o,t,void 0))&&(v.id.match("_icon_content_shape$")||v.id.match("_icon_content_rect$")))return b;for(var M=0;M=0;s--){var o=t.children[parseInt(s.toString(),10)];if(o&&o.outerBounds.containsPoint(e,r||0))if(o.visible){if(o instanceof Cs){var a=this.findTargetElement(o,e,i);if(a)return a}var l="Clip"===o.style.textOverflow||"Ellipsis"===o.style.textOverflow;if(o.bounds.containsPoint(e,r||0)&&!l)return o;if(t.bounds.containsPoint(e,r||0)&&l)return o}else if(o instanceof Ze&&t&&t.id){var h=void 0;if(t.id.includes("group_container")){var c=t.id.slice(0,-15);h=i.getObject(c)}else h=i.getObject(t.id);if(ob(h,o.id))return o}}return t.bounds.containsPoint(e,r)&&"none"!==t.style.fill?t:null},n}(),Joe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),ap=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},n_=function(n){function t(e,i,r,s){var o=n.call(this,e,i,r,s)||this;return o.objectZIndex=-1,o.zIndexTable={},o.objects=[],o}return Joe(t,n),ap([I("")],t.prototype,"id",void 0),ap([I(!0)],t.prototype,"visible",void 0),ap([I(!1)],t.prototype,"lock",void 0),ap([I()],t.prototype,"objects",void 0),ap([I()],t.prototype,"addInfo",void 0),ap([I(-1)],t.prototype,"zIndex",void 0),t}(Ee),ET=function(n,t,e,i){return new(e||(e=Promise))(function(r,s){function o(h){try{l(i.next(h))}catch(c){s(c)}}function a(h){try{l(i.throw(h))}catch(c){s(c)}}function l(h){h.done?r(h.value):new e(function(c){c(h.value)}).then(o,a)}l((i=i.apply(n,t||[])).next())})},DT=function(n,t){var i,r,s,o,e={label:0,sent:function(){if(1&s[0])throw s[1];return s[1]},trys:[],ops:[]};return o={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function a(h){return function(c){return function l(h){if(i)throw new TypeError("Generator is already executing.");for(;e;)try{if(i=1,r&&(s=2&h[0]?r.return:h[0]?r.throw||((s=r.return)&&s.call(r),0):r.next)&&!(s=s.call(r,h[1])).done)return s;switch(r=0,s&&(h=[2&h[0],s.value]),h[0]){case 0:case 1:s=h;break;case 4:return e.label++,{value:h[1],done:!1};case 5:e.label++,r=h[1],h=[0];continue;case 7:h=e.ops.pop(),e.trys.pop();continue;default:if(!(s=(s=e.trys).length>0&&s[s.length-1])&&(6===h[0]||2===h[0])){e=0;continue}if(3===h[0]&&(!s||h[1]>s[0]&&h[1]1)for(var i=0;i-1)return e[parseInt(i.toString(),10)];return this.diagram.activeLayer},n.prototype.getLayer=function(t){for(var e=this.diagram.layers,i=0;i=0;o--)this.diagram.unSelect(this.diagram.nameTable[s[parseInt(o.toString(),10)]]),this.diagram.remove(this.diagram.nameTable[s[parseInt(o.toString(),10)]]),"default_layer"!==i.id&&this.diagram.activeLayer.id===t&&(this.diagram.activeLayer=this.diagram.layers[this.diagram.layers.length-1]);delete this.diagram.layerZIndexTable[i.zIndex],this.diagram.layers.splice(r,1),"SVG"!==this.diagram.mode&&this.diagram.refreshDiagramLayer()}},n.prototype.moveObjects=function(t,e){this.diagram.startGroupAction();for(var i={},r=[],s=0;s-1){if(r=[],(h=this.diagram.nameTable[""+s]).children)for(var p=0,g=h.children;p0){for(var y=void 0,S=0,b=r;S0)for(var r=0;r0)for(r=0;r0){t=t.concat(this.diagram.selectedItems.connectors);for(var i=0;i0)for(t=t.concat(this.diagram.selectedItems.nodes),i=0;i0){for(var i=0,r=t.shape.activity.subProcess.processes;i0&&this.copyProcesses(this.processTable[""+s])}this.clipboardData.processTable=this.processTable}},n.prototype.group=function(){this.oldSelectedObjects=sm(this.diagram);var e=this.diagram.isProtectedOnChange;this.diagram.protectPropertyChange(!0),this.diagram.diagramActions=this.diagram.diagramActions|ee.Group;var r={};r.id="group"+Qe(),(r=new te(this.diagram,"nodes",r,!0)).children=[];for(var s=this.diagram.selectedItems.nodes.concat(this.diagram.selectedItems.connectors).sort(function(h,c){return h.zIndex-c.zIndex}),o=0;o0){var a=this.diagram.add(r);a&&this.select(a),this.addHistoryEntry({type:"Group",undoObject:r,redoObject:r,category:"Internal"}),this.diagram.diagramActions=this.diagram.diagramActions&~ee.Group,this.diagram.protectPropertyChange(e)}},n.prototype.unGroup=function(t){var i=this.diagram.isProtectedOnChange;this.diagram.protectPropertyChange(!0),this.diagram.diagramActions=this.diagram.diagramActions|ee.Group;var r=[];t?r.push(t):r=this.diagram.selectedItems.nodes,this.diagram.startGroupAction();for(var s=0;s0&&this.diagram.removePorts(o,o.ports),o.annotations&&o.annotations.length>0&&!ce()&&this.diagram.removeLabels(o,o.annotations);for(var c=this.diagram.nameTable[o.parentId],d=o.children.length-1;d>=0;d--)this.diagram.nameTable[o.children[parseInt(d.toString(),10)]].parentId="",this.diagram.deleteChild(this.diagram.nameTable[o.children[parseInt(d.toString(),10)]],o),o.parentId&&o.children[parseInt(d.toString(),10)]&&this.diagram.addChild(c,o.children[parseInt(d.toString(),10)]);this.resetDependentConnectors(o.inEdges,!0),this.resetDependentConnectors(o.outEdges,!1),this.diagram.diagramActions&ee.UndoRedo||this.addHistoryEntry({type:"UnGroup",undoObject:a,redoObject:a,category:"Internal"}),o.parentId&&this.diagram.deleteChild(o,c)}this.diagram.removeNode(o,l),this.clearSelection()}this.diagram.endGroupAction(),this.diagram.diagramActions=this.diagram.diagramActions&~ee.Group,this.diagram.protectPropertyChange(i)},n.prototype.resetDependentConnectors=function(t,e){for(var i=0;i0&&(g=!1)}if(g){var y=this.cloneConnector(f,i);c.push(y),o[h.id]=y.id}}else{var S=this.cloneNode(h,i);if(c.push(S),S){o[h.id]=S.id;var b=h.inEdges;if(b)for(var M=0,w=b;M0)for(var u=0;u0)for(r=t.segments,s=0;s0&&this.diagram.drawingObject&&"Bezier"===this.diagram.drawingObject.type&&(t.segments=[]);var e=this.diagram.add(t);"SVG"!==this.diagram.mode&&this.diagram.refreshDiagramLayer(),this.selectObjects([e]),t&&!_I(this.diagram)&&(this.diagram.tool&=~ri.DrawOnce,this.diagram.currentDrawingObject=void 0)},n.prototype.enableServerDataBinding=function(t){this.diagram.enableServerDataBinding(t)},n.prototype.addText=function(t,e){var i=this.diagram.findElementUnderMouse(t,e,this.diagram);this.diagram.startTextEdit(t,i instanceof ai?i.id.split("_")[1]:void 0)},n.prototype.isUserHandle=function(t){var e=this.diagram.selectedItems;if(e.wrapper&&qr(e.constraints,"UserHandle"))for(var i=0,r=e.userHandles;i0&&t[0]&&t[0].isLane)for(s=this.diagram.getObject(t[0].parentId),t[0].shape.header=[],a=0;a1||e&&1===t.length)){if(1!==t.length)return[2];this.clearSelection()}if(!(u||d||1!==t.length||e&&$a(this.diagram)))return this.clearSelection(),[2]}if(!r.cancel){for(f=0;f0||e)&&p.children&&!p.parentId)for(g=0;g0||e,!0)}else this.select(p,f>0||e,!0);void 0===i&&(i=c),r={oldValue:i||[],newValue:this.getSelectedObject(),cause:this.diagram.diagramActions,state:"Changed",type:"Addition",cancel:!1},this.diagram.renderSelector(e||t&&t.length>1),ce()||this.diagram.triggerEvent(Ce.selectionChange,r),this.diagram.enableServerDataBinding(!0)}return[2]})})},n.prototype.findParent=function(t){return t.parentId&&this.findParent(t=this.diagram.nameTable[t.parentId]),t},n.prototype.selectProcesses=function(t){if(this.hasProcesses(t))for(var e=t.shape.activity.subProcess.processes,i=0;i0)},n.prototype.select=function(t,e,i){var r=this.getObjectLayer(t.id);if(xd(t)&&!(t instanceof ei)&&!_r(this.diagram,t)&&r&&!r.lock&&r.visible&&t.wrapper.visible){(e=!!$a(this.diagram)&&e)||this.clearSelection(),this.diagram.enableServerDataBinding(!1);var s=this.diagram.selectedItems;if(t instanceof te?s.nodes.push(t.isHeader?this.diagram.nameTable[t.parentId]:t):s.connectors.push(t),s.selectedObjects.push(t),e)s.wrapper.rotateAngle=s.rotateAngle=0,s.wrapper.children.push(t.wrapper);else if(s.init(this.diagram),1===s.nodes.length&&0===s.connectors.length){var l=Wx(this.diagram,s);l&&(s.wrapper.children[0]=l),s.rotateAngle=s.nodes[0].rotateAngle,s.wrapper.rotateAngle=s.nodes[0].rotateAngle,s.wrapper.pivot=s.nodes[0].pivot}i||this.diagram.renderSelector(e),this.diagram.enableServerDataBinding(!0)}},n.prototype.labelSelect=function(t,e){this.oldSelectedObjects=sm(this.diagram);var i=this.diagram.selectedItems,r=this.diagram.allowServerDataBinding;this.diagram.allowServerDataBinding=!1,i.nodes=i.connectors=[],this.diagram.allowServerDataBinding=r,t instanceof te?i.nodes[0]=t:i.connectors[0]=t,i.annotation=this.findTarget(e,t),i.init(this.diagram),this.diagram.renderSelector(!1)},n.prototype.unSelect=function(t){var e=this.diagram.selectedItems.nodes.concat(this.diagram.selectedItems.connectors),i=e.filter(function(a){return a.id!==t.id}),r={oldValue:e,newValue:i,cause:this.diagram.diagramActions,state:"Changing",type:"Removal",cancel:!1};if(this.diagram.currentSymbol||ce()||this.diagram.triggerEvent(Ce.selectionChange,r),_r(this.diagram,t)){var s=this.diagram.selectedItems,o=void 0;t instanceof te?(o=s.nodes.indexOf(t,0),s.nodes.splice(o,1)):(o=s.connectors.indexOf(t,0),s.connectors.splice(o,1)),o=s.selectedObjects.indexOf(t,0),s.selectedObjects.splice(o,1),(r={oldValue:e,newValue:i,cause:this.diagram.diagramActions,state:"Changed",type:"Removal",cancel:(r={oldValue:e,newValue:i,cause:this.diagram.diagramActions,state:"Changed",type:"Removal",cancel:!1}).cancel}).cancel||(o=s.wrapper.children.indexOf(t.wrapper,0),s.wrapper.children.splice(o,1),this.diagram.updateSelector(),this.diagram.currentSymbol||this.diagram.triggerEvent(Ce.selectionChange,r))}},n.prototype.moveSvgNode=function(t,e){var i=this.diagram.nameTable[""+e];if("Native"===i.shape.type||"HTML"===i.shape.type)this.updateNativeNodeIndex(t,e);else{var r=xt(e+"_groupElement",this.diagram.element.id),s=xt(t+"_groupElement",this.diagram.element.id);r.parentNode.insertBefore(s,r)}},n.prototype.moveAfterSvgNode=function(t,e){var i=this.diagram.nameTable[""+e];if(!i||"HTML"!==i.shape.type&&"Native"!==i.shape.type)a=xt(e+"_groupElement",this.diagram.element.id),o=xt(t+"_groupElement",this.diagram.element.id),a.insertAdjacentElement("afterend",o);else for(var r=0;rd&&"SwimLane"!==p.shape.type){var S=$(p);p.zIndex=d-((-1!==i.indexOf(p)?i.indexOf(p):0)+1),p.children&&(d=this.findLowestZIndex(p,c)||d),this.triggerOrderCommand(S,p,p),p.children&&this.updateGroupZindex(p,"SendToBack",d)}else"SwimLane"===p.shape.type&&(y=this.swapZIndexObjects(a,h,r,g));if("SVG"===this.diagram.mode){for(var M="SwimLane"!==this.diagram.nameTable[""+r].shape.type?d:y,w=h[parseInt(M.toString(),10)];!w&&Md)&&(d=f.zIndex)}for(var p=JSON.parse(JSON.stringify(l)),v=Number(Object.keys(l).sort(function(wo,Ul){return Number(wo)-Number(Ul)}).reverse()[0]),y=this.diagram.nameTable[""+e].zIndex,S=[],M=0;M<=v;M++)S.push(l[parseInt(M.toString(),10)]);if("SwimLane"===this.diagram.nameTable[""+e].shape.type)for(var C=v;C>=y;C--)if(l[parseInt(C.toString(),10)]&&this.diagram.nameTable[l[parseInt(C.toString(),10)]].parentId!==e){v=C;break}var D=this.diagram.nameTable[""+e];if(D.zIndexx&&(x=L.zIndex)}}else x=d;D.zIndex=x+((-1!==r.indexOf(D)?r.indexOf(D):0)+1),this.triggerOrderCommand(A,D,D)}else if("SwimLane"===D.shape.type){for(var O=0,N=-1,T=0,z=0,U=JSON.parse(JSON.stringify(l)),B=0;B<=y;B++)if(l[parseInt(B.toString(),10)]&&this.diagram.nameTable[l[parseInt(B.toString(),10)]].parentId===e&&-1===N){N=B,T=B;break}for(var j=0;j<=v;j++)p[parseInt(j.toString(),10)]&&p[parseInt(j.toString(),10)]!==e&&this.diagram.nameTable[p[parseInt(j.toString(),10)]].parentId!==e&&this.diagram.nameTable[p[parseInt(j.toString(),10)]].zIndex>=this.diagram.nameTable[""+e].zIndex&&O++;for(var ue=N,fe=0;fe<=O;fe++){for(;!l[parseInt(ue.toString(),10)];)ue++;z=this.diagram.nameTable[l[parseInt(ue.toString(),10)]].zIndex,ue++}for(var Me=z;Me<=v;Me++){for(;!U[parseInt(N.toString(),10)];)N++;for(;!l[parseInt(Me.toString(),10)];)Me++;l[parseInt(Me.toString(),10)]=U[parseInt(N.toString(),10)],this.diagram.nameTable[l[parseInt(Me.toString(),10)]].zIndex=Me,N++}l[parseInt(v.toString(),10)]=this.diagram.nameTable[""+e].id,this.diagram.nameTable[""+e].zIndex=v,ue=y+1;for(var De=T,xe=0;xe0&&("Native"===hr[0].shape.type||"HTML"===hr[0].shape.type)){for(Ci.parentNode.removeChild(Ci),De=0;De0?r[0]:null},n.prototype.findLowestZIndex=function(t,e){var r=this.diagram.nodes.filter(function(s){return-1!==e.indexOf(s.id)}).filter(function(s){return""===s.parentId&&s.id!==t.id}).map(function(s){return s.zIndex});return r.sort(function(s,o){return s-o}),r.length>0?r[0]:null},n.prototype.triggerOrderCommand=function(t,e,i){var s={zIndex:$(t).zIndex},o={zIndex:e.zIndex},a={element:i,cause:this.diagram.diagramActions,diagramAction:this.diagram.getDiagramAction(this.diagram.diagramActions),oldValue:s,newValue:o};this.diagram.triggerEvent(Ce.propertyChange,a)},n.prototype.checkGroupNode=function(t,e,i){return i[""+e].parentId===i[""+t].parentId},n.prototype.sortByZIndex=function(t,e,i){if("BringForward"===i){var r=e||"zIndex";t=t.sort(function(o,a){return a[""+r]-o[""+r]})}else{var s=e||"zIndex";t=t.sort(function(o,a){return o[""+s]-a[""+s]})}return t},n.prototype.orderCommands=function(t,e,i){var r=this,s=e.nodes;if(s=s.concat(e.connectors),t)if("SendBackward"===i)for(var o=0;oa}),S=v.filter(function(D){return D0?Math.max.apply(Math,S):a,M=y.length>0?Math.min.apply(Math,y):a;if(a!==M){var w=c.zIndexTable[parseInt(M.toString(),10)],C=c.zIndexTable[parseInt(a.toString(),10)];this.moveSvgNode(C,w)}else"SendToBack"===i&&(w=c.zIndexTable[parseInt(a.toString(),10)],C=c.zIndexTable[parseInt(b.toString(),10)],this.moveAfterSvgNode(w,C))}}else this.diagram.refreshCanvasLayers()}},n.prototype.swapDomOrder=function(t,e){if(t){var i=this.diagram.getObject(e);if("Native"===i.shape.type||"HTML"===i.shape.type)this.updateNativeNodeIndex(e,t),this.updateNativeNodeIndex(t,e);else{var r=xt(e+"_groupElement",this.diagram.element.id),s=xt(t+"_groupElement",this.diagram.element.id);r.parentNode.insertBefore(r,s),r.parentNode.insertBefore(s,r)}}},n.prototype.sendForward=function(t){var e=this;if(this.diagram.protectPropertyChange(!0),$a(this.diagram)||t){$(t||(this.diagram.selectedItems.nodes.length?this.diagram.selectedItems.nodes[0]:this.diagram.selectedItems.connectors[0]));var s=t&&t.id,o=this.diagram.layers.indexOf(this.getObjectLayer(s=s||(this.diagram.selectedItems.nodes.length?this.diagram.selectedItems.nodes[0].id:this.diagram.selectedItems.connectors[0].id))),a=$(this.diagram.nameTable),h=(parseInt(o.toString(),10),this.diagram.nameTable[""+s]),c=[],d=this.diagram.spatialSearch.findObjects(h.wrapper.bounds);d.length>2&&(d=this.sortByZIndex(d,void 0,"BringForward"));for(var u=0,f=d;u=0;p--)this.diagram.nameTable[c[parseInt(p.toString(),10)].id].parentId===s&&c.splice(p,1);if(c.length>0){var y=this.diagram.nameTable[c[c.length-1].id];if(y.parentId){var b=am(y,this.diagram,""),M=this.diagram.nameTable[""+b];M.id!==s&&(c[0]=M)}var w={};for(p=0;p0&&(Object.values(O).forEach(function(ue){ue>=T&&N.push(ue)}),0!==N.length&&this.updateZIndexBySendForward(h,N,o))}var z=[];if(Object.keys(this.changedNodeZIndexes).forEach(function(ue){if((a[""+ue]?a[""+ue].zIndex:null)!==e.changedNodeZIndexes[""+ue]){var De=$(a[""+ue]);z.push(De)}}),this.updateLayerZindexTable(o),L.nodes.splice(0,L.nodes.length),z.forEach(function(ue){var fe=$(ue);L.nodes.push(fe)}),"SVG"===this.diagram.mode){var U=c[c.length-1].id,B=c[c.length-1];B&&!("HTML"===B.shape.type||"Native"===B.shape.type)&&this.moveAfterSvgNode(s,U),this.updateNativeNodeIndex(U,s)}else this.diagram.refreshCanvasLayers();var j=[];Object.keys(this.changedNodeZIndexes).forEach(function(ue){if((a[""+ue]?a[""+ue].zIndex:null)!==e.changedNodeZIndexes[""+ue]){var De=$(e.diagram.nameTable[""+ue]);j.push(De)}});var Q=$(this.diagram.selectedItems);Q.nodes.splice(0,Q.nodes.length),j.forEach(function(ue){var fe=$(ue);Q.nodes.push(fe)}),this.diagram.diagramActions&ee.UndoRedo||this.addHistoryEntry({type:"SendForward",category:"Internal",undoObject:L,redoObject:Q}),this.diagram.endGroupAction()}}this.diagram.protectPropertyChange(!1)},n.prototype.updateZIndexBySendForward=function(t,e,i){var r=$(t);t.zIndex=Math.min.apply(Math,e);var a,s=Math.min.apply(Math,e),o=Math.min.apply(Math,e),l=this.diagram.layers[parseInt(i.toString(),10)].objects,h=this.diagram.nodes.filter(function(S){return-1!==l.indexOf(S.id)});t.children&&this.updateGroupZindex(t,"BringForward",t.zIndex);var c=h.filter(function(S){return S.zIndex===Math.min.apply(Math,e)&&S.id!==t.id});if(c&&c.length>0&&c[0].children){for(var d=Math.min.apply(Math,e),u=0;uo&&g!==t&&g.parentId!==t.id&&c&&c.length>0&&g.parentId!==c[0].id){var v=$(g);g.zIndex=a+1,a++,this.triggerOrderCommand(v,g,g)}var y=g.zIndex;this.changedNodeZIndexes[g.id]=(this.changedNodeZIndexes.hasOwnProperty(g.id),y)}},n.prototype.arrangeZIndexForLowerNodes=function(t,e,i){var r=i.filter(function(o){return o.zIndex<=t&&o.parentId!==e.id});r.sort(function(o,a){return a.zIndex-o.zIndex});for(var s=0;se&&(e=r.zIndex)}return e},n.prototype.sendBackward=function(t){var e=this;if(this.diagram.protectPropertyChange(!0),$a(this.diagram)||t){$(t||(this.diagram.selectedItems.nodes.length?this.diagram.selectedItems.nodes[0]:this.diagram.selectedItems.connectors[0]));var s=t&&t.id,o=this.diagram.layers.indexOf(this.getObjectLayer(s=s||(this.diagram.selectedItems.nodes.length?this.diagram.selectedItems.nodes[0].id:this.diagram.selectedItems.connectors[0].id))),a=$(this.diagram.nameTable),h=(parseInt(o.toString(),10),this.diagram.nameTable[""+s]),c=[],d=this.diagram.spatialSearch.findObjects(h.wrapper.bounds);d.length>2&&(d=this.sortByZIndex(d));for(var u=0,f=d;uNumber(p.zIndex)&&""===p.parentId&&h.wrapper.bounds.intersects(p.wrapper.bounds)&&c.push(p);for(var p=c.length-1;p>=0;p--)(v=this.diagram.nameTable[c[parseInt(p.toString(),10)].id]).parentId===s&&c.splice(p,1);if(c.length>0){var v;if((v=this.diagram.nameTable[c[c.length-1].id]).parentId){var S=am(v,this.diagram,""),b=this.diagram.nameTable[""+S];s!==b.id&&(c[c.length-1]=b)}var M={};for(p=0;p0&&(Object.values(L).forEach(function(fe){fe<=N&&O.push(fe)}),0!==O.length&&this.updateZIndexBySendBackward(h,O,o))}var T=[];if(Object.keys(this.changedNodeZIndexes).forEach(function(fe){if((a[""+fe]?a[""+fe].zIndex:null)!==e.changedNodeZIndexes[""+fe]){var xe=$(a[""+fe]);T.push(xe)}}),this.updateLayerZindexTable(o),P.nodes.splice(0,P.nodes.length),T.forEach(function(fe){var Me=$(fe);P.nodes.push(Me)}),"SVG"===this.diagram.mode){var z=c[c.length-1].id,U=c[c.length-1];U&&"HTML"!==U.shape.type&&"Native"!==U.shape.type&&this.moveSvgNode(s,z);var B=this.diagram.nameTable[""+z];B.children&&B.children.length>0?this.updateNativeNodeIndex(s):this.updateNativeNodeIndex(s,z)}else this.diagram.refreshCanvasLayers();var j=[];Object.keys(this.changedNodeZIndexes).forEach(function(fe){if((a[""+fe]?a[""+fe].zIndex:null)!==e.changedNodeZIndexes[""+fe]){var xe=$(e.diagram.nameTable[""+fe]);j.push(xe)}});var Q=$(this.diagram.selectedItems);Q.nodes.splice(0,Q.nodes.length),j.forEach(function(fe){var Me=$(fe);Q.nodes.push(Me)}),this.diagram.diagramActions&ee.UndoRedo||this.addHistoryEntry({type:"SendBackward",category:"Internal",undoObject:P,redoObject:Q}),this.diagram.endGroupAction()}}this.diagram.protectPropertyChange(!1)},n.prototype.updateZIndexBySendBackward=function(t,e,i){var r=$(t);t.zIndex=Math.max.apply(Math,e);var f,s=t.zIndex,o=Math.max.apply(Math,e),a=this.diagram.layers[parseInt(i.toString(),10)].objects,l=this.diagram.nodes.filter(function(S){return-1!==a.indexOf(S.id)}),h=l.filter(function(S){return S.zIndex===Math.max.apply(Math,e)&&S.id!==t.id});if(h&&h.length>0&&h[0].children)for(var c=Math.max.apply(Math,e),d=0;d0&&g.parentId!==h[0].id){var v=$(g);g.zIndex=f-1,f--,this.triggerOrderCommand(v,g,g)}var y=g.zIndex;this.changedNodeZIndexes[""+g.id]=(this.changedNodeZIndexes.hasOwnProperty(g.id),y)}},n.prototype.findLowestChildZIndex=function(t){for(var e=t.zIndex,i=0;i0),this.selectObjects([t],!0))},n.prototype.clearSelection=function(t,e){return ET(this,void 0,void 0,function(){var i,r,s,o;return DT(this,function(a){return i=this.diagram.allowServerDataBinding,this.diagram.enableServerDataBinding(!1),$a(this.diagram)&&(r=this.diagram.selectedItems,s=this.getSelectedObject(),this.diagram.currentSymbol&&(this.diagram.previousSelectedObject=s),o={oldValue:s,newValue:[],cause:this.diagram.diagramActions,state:"Changing",type:"Removal",cancel:!1},t&&(ce()||this.diagram.triggerEvent(Ce.selectionChange,o)),o.cancel||(r.offsetX=0,r.offsetY=0,r.width=0,r.height=0,r.rotateAngle=0,r.nodes=[],r.connectors=[],r.wrapper=null,r.annotation=void 0,r.selectedObjects=[],this.diagram.clearSelectorLayer(),t&&(o={oldValue:s,newValue:[],cause:this.diagram.diagramActions,state:"Changed",type:"Removal",cancel:!1},ce()||this.diagram.triggerEvent(Ce.selectionChange,o))),this.diagram.enableServerDataBinding(i)),[2]})})},n.prototype.clearSelectedItems=function(){this.clearSelection((this.diagram.selectedItems.nodes?this.diagram.selectedItems.nodes.length:0)+(this.diagram.selectedItems.connectors?this.diagram.selectedItems.connectors.length:0)>0)},n.prototype.removeStackHighlighter=function(){var t=Fl(this.diagram.element.id),e=t.getElementById(t.id+"_stack_highlighter");e&&e.parentNode.removeChild(e)},n.prototype.renderStackHighlighter=function(t,e){var r,s,o,i=this.diagram.selectedItems.nodes[0];if(!e){var a=this.diagram.findObjectsUnderMouse(t.position);if((e=this.diagram.findObjectUnderMouse(a,"Drag",!0))&&!(e.isLane||e.isPhase||e.isHeader))for(var l=0;l0)for(var a=0;a1)if(i){var h=l.segments[0],c=l.segments[1],u=Ol(AI(t.wrapper,t.wrapper.corners,t.wrapper.bounds),h.direction),g=kl({corners:void 0,point:u=qa(l,0,u,{x:l.sourceWrapper.offsetX,y:l.sourceWrapper.offsetY},!1),margin:void 0,direction:h.direction},{corners:void 0,point:c.points[1],margin:void 0,direction:void 0});h.length=R.distancePoints(g[0],g[1]),c.direction&&c.length&&(c.length=R.distancePoints(g[1],g[2]))}else if(o){switch(l.segments[0].direction){case"Bottom":r=t.wrapper.bounds.bottomCenter.x-e.bottomCenter.x,s=t.wrapper.bounds.bottomCenter.y-e.bottomCenter.y;break;case"Top":r=t.wrapper.bounds.topCenter.x-e.topCenter.x,s=t.wrapper.bounds.topCenter.y-e.topCenter.y;break;case"Left":r=t.wrapper.bounds.middleLeft.x-e.middleLeft.x,s=t.wrapper.bounds.middleLeft.y-e.middleLeft.y;break;case"Right":r=t.wrapper.bounds.middleRight.x-e.middleRight.x,s=t.wrapper.bounds.middleRight.y-e.middleRight.y}this.dragSourceEnd(l,r,s,!0,null,"ConnectorSourceEnd",void 0,void 0,void 0,!(t.parentId&&this.diagram.diagramActions&ee.isGroupDragging))}}},n.prototype.updateEndPoint=function(t,e){var r={sourcePoint:t.sourcePoint,targetPoint:t.targetPoint};t.sourceID&&(r.sourceID=t.sourceID),t.targetID&&(r.targetID=t.targetID),t.sourcePortID&&(r.sourcePortID=t.sourcePortID),t.targetPortID&&(r.targetPortID=t.targetPortID),t.segments&&(r.segments=t.segments),this.diagram.connectorPropertyChange(t,e||{},r),this.diagram.updateSelector()},n.prototype.dragSourceEnd=function(t,e,i,r,s,o,a,l,h,c,d){var u=this.diagram.nameTable[t.id],f={},p=this.checkBoundaryConstraints(e,i,u.wrapper.bounds);if(PI(u)&&p&&"BezierSourceThumb"!==o&&Wv(this.diagram)&&(f=$(f={sourcePoint:u.sourcePoint}),u.sourcePoint.x+=e,u.sourcePoint.y+=i,"ConnectorSourceEnd"===o&&"Orthogonal"===u.type&&this.changeSegmentLength(u,l,h,c),"Bpmn"===u.shape.type&&"Default"===u.shape.sequence&&"Sequence"===u.shape.flow&&this.updatePathElementOffset(u)),"Bezier"===u.type)if(f={sourcePoint:u.sourcePoint},d)this.translateBezierPoints(t,""===o?"ConnectorSourceEnd":o,e,i,d,s,!a);else for(var g=0;g2){var d=R.direction((c=t.segments[2]).points[0],c.points[1]);o.direction===_n(d)?("Right"===o.direction?c.points[0].x=o.points[o.points.length-1].x=l.wrapper.corners.middleRight.x+20:"Left"===o.direction?c.points[0].x=o.points[o.points.length-1].x=l.wrapper.corners.middleLeft.x-20:c.points[0].y=o.points[o.points.length-1].y="Top"===o.direction?l.wrapper.corners.topCenter.y-20:l.wrapper.corners.bottomCenter.y+20,c.direction&&c.length&&(c.length=R.distancePoints(c.points[0],c.points[c.points.length-1])),o.length=R.distancePoints(o.points[0],o.points[o.points.length-1])):o.direction===d&&c.direction&&c.length?("Top"===o.direction||"Bottom"===o.direction?(c.points[0]=o.points[0],c.points[c.points.length-1].x=c.points[0].x):(c.points[0]=o.points[0],c.points[c.points.length-1].y=c.points[0].y),c.length=R.distancePoints(c.points[0],c.points[c.points.length-1]),t.segments.splice(0,2)):o.length=20}else o.length=20;else if(o.length<1)if(""!==t.sourceID){var c;"Right"===a.direction?a.points[a.points.length-1].y=(h=l.wrapper.corners.middleRight).y:"Left"===a.direction?a.points[a.points.length-1].y=(h=l.wrapper.corners.middleLeft).y:a.points[a.points.length-1].x="Top"===a.direction?(h=l.wrapper.corners.topCenter).x:(h=l.wrapper.corners.bottomCenter).x,a.length=R.distancePoints(h,a.points[a.points.length-1]),t.segments.length>2&&(c=t.segments[2]).direction&&c.length&&(c.length=R.distancePoints(a.points[a.points.length-1],c.points[c.points.length-1])),t.segments.splice(0,1)}else t.segments.splice(0,1)}else e&&!i&&t.sourceID!==e.id&&t.segments&&null!==t.segments[0].direction&&e&&e instanceof te&&s&&this.changeSourceEndToNode(t,e),e&&i&&t.sourcePortID!==i&&t.segments&&null!==t.segments[0].direction&&e&&e instanceof te&&s&&this.changeSourceEndToPort(t,e,i)},n.prototype.canConnect=function(t,e){return!(!ua(e)||!Rh(e))},n.prototype.changeSourceEndToPort=function(t,e,i){var r=this.diagram.getWrapper(e.wrapper,i),s={x:r.offsetX,y:r.offsetY},o=zo(s,xn(e.wrapper),e.wrapper.bounds),a=t.segments[0],l=t.segments[1];if(a.direction!==o){var h=[],c={};if(a.direction===_n(o)){c={};var d=void 0;"Top"===o||"Bottom"===o?(d="Top"===o?{type:"Orthogonal",isTerminal:!0,direction:o,length:Math.abs(a.points[0].y-s.y)}:{type:"Orthogonal",isTerminal:!0,direction:o,length:Math.abs(s.y-a.points[0].y)},c=a.points[0].x>s.x?{type:"Orthogonal",isTerminal:!0,direction:"Right",length:a.points[0].x-s.x}:{type:"Orthogonal",isTerminal:!0,direction:"Left",length:s.x-a.points[0].x}):(d="Right"===o?{type:"Orthogonal",isTerminal:!0,direction:o,length:Math.abs(a.points[0].x-s.x)}:{type:"Orthogonal",isTerminal:!0,direction:o,length:Math.abs(s.x-a.points[0].x)},c=a.points[0].y>s.y?{type:"Orthogonal",direction:"Top",isTerminal:!0,length:a.points[0].y-s.y}:{type:"Orthogonal",direction:"Bottom",isTerminal:!0,length:s.y-a.points[0].y}),h.push(new wi(t,"segments",d,!0)),h.push(new wi(t,"segments",c,!0))}else h.push(new wi(t,"segments",c={type:"Orthogonal",direction:o,length:20,isTerminal:!0},!0));a.direction!==_n(o)&&("Top"===o||"Bottom"===o?(a.points[0].x=s.x,a.points[0].y=a.points[a.points.length-1].y="Top"===o?s.y-20:s.y+20):(a.points[0].y=s.y,a.points[0].x=a.points[a.points.length-1].x="Right"===o?s.x+20:s.x-20),a.length=R.distancePoints(a.points[0],a.points[a.points.length-1]),l.length=R.distancePoints(a.points[a.points.length-1],l.points[l.points.length-1])),t.segments=h.concat(t.segments)}else a.points[0]=s,"Top"===o||"Bottom"===o?a.points[a.points.length-1].x=s.x:a.points[a.points.length-1].y=s.y,a.length=R.distancePoints(a.points[0],a.points[a.points.length-1]),l.length=R.distancePoints(a.points[a.points.length-1],l.points[l.points.length-1])},n.prototype.removeTerminalSegment=function(t,e){for(var i=0;ii.width||"Left"===o.direction&&r.x>=o.points[0].x||"Right"===o.direction&&r.x<=o.points[0].x)o.points[0].y=o.points[o.points.length-1].y=r.y,o.points[0].x=r.x,o.length=R.distancePoints(o.points[0],o.points[o.points.length-1]),a.length=R.distancePoints(o.points[o.points.length-1],a.points[a.points.length-1]);else{var h=void 0;s="Bottom"===(h=a.direction?a.direction:R.direction(a.points[0],a.points[a.points.length-1]))?i.bottomCenter:i.topCenter,a.length&&a.direction&&(a.length="Top"===h?o.points[o.points.length-1].y-(s.y+20):s.y+20-o.points[o.points.length-1].y),o.length=o.points[o.points.length-1].x-s.x,o.direction=o.length>0?"Right":"Left",l.push(new wi(t,"segments",{type:"Orthogonal",direction:h,length:20},!0)),t.segments=l.concat(t.segments)}else r="Bottom"===o.direction?i.bottomCenter:i.topCenter,o.length>i.height||"Top"===o.direction&&r.y>=o.points[0].y||"Bottom"===o.direction&&r.y<=o.points[0].y?(o.points[0].x=o.points[o.points.length-1].x=r.x,o.points[0].y=r.y,o.length=R.distancePoints(o.points[0],o.points[o.points.length-1]),a.length=R.distancePoints(o.points[o.points.length-1],a.points[a.points.length-1])):(s="Left"===a.direction?i.middleLeft:i.middleRight,h=void 0,h=a.direction?a.direction:R.direction(a.points[0],a.points[a.points.length-1]),a.length&&a.direction&&(a.length="Left"===h?o.points[o.points.length-1].x-(s.x+20):s.x+20-o.points[o.points.length-1].x),o.length=o.points[o.points.length-1].y-s.y,o.direction=o.length>0?"Bottom":"Top",l.push(new wi(t,"segments",{type:"Orthogonal",direction:h,length:20},!0)),t.segments=l.concat(t.segments))},n.prototype.translateBezierPoints=function(t,e,i,r,s,o,a){var l=t.segments.indexOf(s),h=t.segments[parseInt(l.toString(),10)],c=l>0?t.segments[l-1]:null,d=null!==c?c.point:t.sourcePoint,u=l===t.segments.length-1?t.targetPoint:h.point;if(h)if("BezierSourceThumb"===e&&(h.vector1.angle||h.vector1.distance)){var f=h.vector1.distance,p=h.vector1.angle;h.vector1={distance:t.distance(d,o),angle:R.findAngle(d,o)},this.translateSubsequentSegment(t,s,!0,h.vector1.distance-f,h.vector1.angle-p)}else"BezierTargetThumb"===e&&(h.vector2.angle||h.vector2.distance)?(f=h.vector2.distance,p=h.vector2.angle,h.vector2={distance:t.distance(u,o),angle:R.findAngle(u,o)},this.translateSubsequentSegment(t,s,!1,h.vector2.distance-f,h.vector2.angle-p)):("ConnectorSourceEnd"===e&&!t.sourceID||"ConnectorTargetEnd"===e&&!t.targetID)&&a&&JI(h.vector1)&&JI(h.vector2)?(R.isEmptyPoint(h.point1)&&(h.bezierPoint1=KI(t.sourcePoint,t.targetPoint)),R.isEmptyPoint(h.point2)&&(h.bezierPoint2=KI(t.targetPoint,t.sourcePoint))):"BezierSourceThumb"===e||"ConnectorSourceEnd"===e&&!a&&JI(h.vector1)?(h.bezierPoint1.x+=i,h.bezierPoint1.y+=r,(!R.isEmptyPoint(h.point1)||a)&&(h.point1={x:h.bezierPoint1.x,y:h.bezierPoint1.y})):("BezierTargetThumb"===e||"ConnectorTargetEnd"===e&&!a&&JI(h.vector2))&&(h.bezierPoint2.x+=i,h.bezierPoint2.y+=r,(!R.isEmptyPoint(h.point2)||a)&&(h.point2={x:h.bezierPoint2.x,y:h.bezierPoint2.y}))},n.prototype.translateSubsequentSegment=function(t,e,i,r,s){var o=t.segments.indexOf(e);parseInt(o.toString(),10),t.bezierSettings.smoothness&CI.SymmetricAngle||(s=null),t.bezierSettings.smoothness&CI.SymmetricDistance||(r=null),(null!=r||null!=s)&&(i?0!==o&&this.updatePreviousBezierSegment(t,o,r,s):o!==t.segments.length-1&&this.updateNextBezierSegment(t,o,r,s))},n.prototype.updatePreviousBezierSegment=function(t,e,i,r){var s=t.segments[e-1],a=(s.vector2.angle+r)%360;a<0&&(a+=360),s.vector2={distance:s.vector2.distance+i,angle:a}},n.prototype.updateNextBezierSegment=function(t,e,i,r){var s=t.segments[e+1],a=(s.vector1.angle+r)%360;a<0&&(a+=360),s.vector1={distance:s.vector1.distance+i,angle:a}},n.prototype.dragTargetEnd=function(t,e,i,r,s,o,a,l){var c,h=this.diagram.nameTable[t.id],d=this.checkBoundaryConstraints(e,i,h.wrapper.bounds);if(zI(h)&&"BezierTargetThumb"!==o&&d&&Wv(this.diagram)){if(c=$(c={targetPoint:h.targetPoint}),h.targetPoint.x+=e,h.targetPoint.y+=i,"ConnectorTargetEnd"===o&&"Orthogonal"===h.type&&h.segments&&h.segments.length>0){var u=h.segments[h.segments.length-2];u&&2===h.segments[h.segments.length-1].points.length&&("Left"===u.direction||"Right"===u.direction?u.points[u.points.length-1].x=h.targetPoint.x:u.points[u.points.length-1].y=h.targetPoint.y,u.length=R.distancePoints(u.points[0],u.points[u.points.length-1]),u.direction=R.direction(u.points[0],u.points[u.points.length-1]))}"Bpmn"===h.shape.type&&"Default"===h.shape.sequence&&"Sequence"===h.shape.flow&&this.updatePathElementOffset(h)}if("Bezier"===h.type)if(c={targetPoint:h.targetPoint},l)this.translateBezierPoints(t,""===o?"ConnectorTargetEnd":o,e,i,l,s,!a);else for(var f=0;f0){if(void 0!==s&&o.segments[parseInt(s.toString(),10)])if("Bezier"===o.type){var a=o.segments[parseInt(s.toString(),10)],l=a.isInternalSegment;l&&null!==o.bezierSettings&&"FreeForm"!==o.bezierSettings.segmentEditOrientation?("Horizontal"===a.orientation?a.point.x+=e:a.point.y+=i,this.updateDirectionalBezierCurve(o)):(a.point.x+=e,a.point.y+=i),l&&(o.isBezierEditing=!0)}else o.segments[parseInt(s.toString(),10)].point.x+=e,o.segments[parseInt(s.toString(),10)].point.y+=i;else for(var h=0;h1){var a=e[1],l=e[2],h={x:.5*(a.x+l.x),y:.5*(a.y+l.y)},c=t.segments[0];c.vector1.angle=Gt(s,a),c.vector1.distance=.5*R.findLength(s,a),c.vector2.angle=Gt(h,a),c.vector2.distance=.5*R.findLength(h,a),c.point=h;var d=t.segments[1];if(d.vector1.angle=Gt(h,l),d.vector1.distance=.5*R.findLength(h,l),t.segments.length>2){var u=e[3],f={x:.5*(l.x+u.x),y:.5*(l.y+u.y)};d.vector2.angle=Gt(f,l),d.vector2.distance=.5*R.findLength(f,l),d.point=f;var p=t.segments[2];if(p.vector1.angle=Gt(f,u),p.vector1.distance=.5*R.findLength(f,u),t.segments.length>3){var g=e[4],v={x:.5*(u.x+g.x),y:.5*(u.y+g.y)};p.vector2.angle=Gt(v,u),p.vector2.distance=.5*R.findLength(v,u),p.point=v;var y=t.segments[3];y.vector1.angle=Gt(v,g),y.vector1.distance=.5*R.findLength(v,g),y.vector2.angle=Gt(o,g),y.vector2.distance=.5*R.findLength(o,g)}else p.vector2.angle=Gt(o,u),p.vector2.distance=.5*R.findLength(o,u)}else d.vector2.angle=Gt(o,l),d.vector2.distance=.5*R.findLength(o,l)}},n.prototype.rotateObjects=function(t,e,i,r,s){r=r||{};var o=Bi();qi(o,i,r.x,r.y);for(var l=0,h=e;l0){this.diagram.protectPropertyChange(!0);var o=t;o.segments=[],this.diagram.connectorPropertyChange(o,{},{segments:o.segments}),this.diagram.protectPropertyChange(!1)}}},n.prototype.updateInnerParentProperties=function(t){var r=this.diagram.isProtectedOnChange;this.diagram.protectPropertyChange(!0);for(var s=this.getAllDescendants(t,[],!1,!0),o=0;o0&&(f=this.diagram.bpmnModule.getChildrenBound(d,d.id,this.diagram),u=d.wrapper.bounds.containsRect(f)),h=d.wrapper.actualSize.width*t,c=d.wrapper.actualSize.height*e,void 0!==d.maxWidth&&0!==d.maxWidth&&(h=Math.min(d.maxWidth,h)),void 0!==d.minWidth&&0!==d.minWidth&&(h=Math.max(d.minWidth,h)),void 0!==d.maxHeight&&0!==d.maxHeight&&(c=Math.min(d.maxHeight,c)),void 0!==d.minHeight&&0!==d.minHeight&&(c=Math.max(d.minHeight,c)),u&&(h=Math.max(h,f.right-d.wrapper.bounds.x),c=Math.max(c,f.bottom-d.wrapper.bounds.y)),t=h/d.actualSize.width,e=c/d.actualSize.height}var p=Bi();o||(o=r);var g=o.wrapper;if(qi(p,-g.rotateAngle,i.x,i.y),Gf(p,t,e,i.x,i.y),qi(p,g.rotateAngle,i.x,i.y),r instanceof te){var d,v=Ke(p,{x:(d=r).wrapper.offsetX,y:d.wrapper.offsetY}),y=d.wrapper.offsetX-d.wrapper.actualSize.width*d.pivot.x,S=d.wrapper.offsetY-d.wrapper.actualSize.height*d.pivot.y;if(h>0)if(d.processId){var b=this.diagram.nameTable[d.processId];(!b.maxWidth||d.margin.left+h0)if(d.processId){var M=this.diagram.nameTable[d.processId];(!M.maxHeight||d.margin.top+c0){if(e.dragLimit=e.dragLimit?e.dragLimit:{},e.dragLimit.top||e.dragLimit.bottom||e.dragLimit.left||e.dragLimit.right){var b={minDistance:null};S=this.getRelativeOffset(v,d,b);var M={minDistance:null};g=this.getRelativeOffset(v,y,M),S=null!=b&&M.minDistance0){if(S=y[y.length-1]){var b=void 0;for(b=0;b=e.x-t.dragLimit.left-r.width/2&&i.x<=e.x+t.dragLimit.right+r.width/2&&(s=!0),i.y>=e.y-t.dragLimit.top-r.height/2&&i.y<=e.y+t.dragLimit.bottom+r.height/2&&(o=!0),{x:s,y:o}},n.prototype.updateLabelMargin=function(t,e,i,r,s,o,a){if(i=i||{x:e.offset,y:0},e&&i&&i.x>0&&i.x<1){var l=R.getLengthFromListOfPoints(t.intermediatePoints),h=this.getPointAtLength(l*i.x,t.intermediatePoints,0),c=this.diagram.scrollSettings.currentZoom,d=e.dragLimit?e.dragLimit:{left:0,right:0,top:0,bottom:0};if(d.top||d.bottom||d.left||d.right){this.diagram.getWrapper(t.wrapper,e.id);var f=new Ne(0,0,0,0),p=this.diagram.getWrapper(t.wrapper,e.id);f.x=p.offsetX/c+o,f.y=p.offsetY/c+a,f.width=p.bounds.width/c,f.height=p.bounds.height/c;var g=new Ne(h.x-(d.left||0)-f.width/2,h.y-(d.top||0)-f.height/2,(d.left||0)+(d.right||0)+f.width,(d.top||0)+(d.bottom||0)+f.height);if(g.containsPoint(r));else for(var S=0,b=this.boundsInterSects([h,r],g,!1);S=t){c=t-r,d=R.findAngle(s,a),u=c*Math.cos(d*Math.PI/180),f=c*Math.sin(d*Math.PI/180),o={x:s.x+u,y:s.y+f};break}r+=h,s=a}else s=a;return o},n.prototype.getInterceptWithSegment=function(t,e){for(var o,a,i=[],r=[],s=[],l=R.findLength({x:0,y:0},{x:this.diagram.scroller.viewPortWidth,y:this.diagram.scroller.viewPortHeight}),h=1;h0&&a<=90||a>180&&a<=270?90:-90;r.push(R.transform(t,a+c,l)),r.push(R.transform(t,o+c,l));var f=im({x1:s[0].x,y1:s[0].y,x2:s[1].x,y2:s[1].y},{x1:r[0].x,y1:r[0].y,x2:r[1].x,y2:r[1].y});f.enabled&&i.push(f.intersectPt)}return i},n.prototype.getAnnotationChanges=function(t,e){var r={};return r[ab(t,e.id,!0)]={width:e.width,height:e.height,offset:t instanceof te?{x:e.offset.x,y:e.offset.y}:e.offset,rotateAngle:e.rotateAngle,margin:{left:e.margin.left,right:e.margin.right,top:e.margin.top,bottom:e.margin.bottom},horizontalAlignment:e.horizontalAlignment,verticalAlignment:e.verticalAlignment,alignment:t instanceof de?e.alignment:void 0},{annotations:r}},n.prototype.getConnectorPortChanges=function(t,e){var i=function Wse(n,t,e){for(var i=n.ports,r=0;r1&&(v.width=g,v.offset.x=1/S),p>1&&(v.height=p,v.offset.y=1/b)}}e instanceof Or&&(e.alignment="Center"),l=this.getAnnotationChanges(t,e),t instanceof te?this.diagram.nodePropertyChange(t,a,l):this.diagram.connectorPropertyChange(t,a,l),this.diagram.updateDiagramObject(t)},n.prototype.getSubProcess=function(t){var i,e={nodes:[],connectors:[]};return t instanceof te?i=t.processId:t&&t.nodes&&t.nodes.length&&t.nodes[0].processId&&(i=t.nodes[0].processId),i&&e.nodes.push($(this.diagram.nameTable[i])),e},n.prototype.checkBoundaryConstraints=function(t,e,i,r){var s=this.diagram.pageSettings,o=this.diagram.pageSettings.boundaryConstraints,a=this.diagram.scroller;if("Page"===o||"Diagram"===o){var l=i?void 0:this.diagram.selectedItems.wrapper.bounds;return!!((i?i.right:l.right)+(t||0)<=("Page"===o?s.width:a.viewPortWidth)&&(i?i.left:l.left)+(t||0)>=0&&(i?i.bottom:l.bottom)+(e||0)<=("Page"===o?s.height:a.viewPortHeight)&&(i?i.top:l.top)+(e||0)>=0||"None"!==this.diagram.layout.type&&r)}return!0},n.prototype.dragSelectedObjects=function(t,e){var i=this,r=this.diagram.selectedItems;this.state&&!this.state.backup&&(this.state.backup={},this.state.backup.offsetX=r.offsetX,this.state.backup.offsetY=r.offsetY),r=XI(this.diagram,r)||r;var s=this.diagram.selectedItems.nodes.filter(function(c){return"SwimLane"===c.shape.type});if(s.length>0&&!this.diagram.currentSymbol&&this.diagram.selectedItems.nodes.length>1){var o=this.diagram.selectedItems.nodes.filter(function(c){return""===c.parentId||"SwimLane"!==i.diagram.nameTable[c.parentId].shape.type});if(o.length>0){for(var a=0;a0||l.length>1)&&(o=o.concat(l),this.diagram.selectedItems.nodes.splice(0,this.diagram.selectedItems.nodes.length),o.forEach(function(c){i.diagram.selectedItems.nodes.push(c)}),r=this.diagram.selectedItems,this.diagram.selectedObject.helperObject=void 0)}}if(this.checkBoundaryConstraints(t,e)){this.diagram.diagramActions=this.diagram.diagramActions|ee.PreventZIndexOnDragging|ee.DragUsingMouse;var h=this.diagram.selectedObject.actualObject;return(h&&h instanceof te&&h.isLane&&Qx(h,this.diagram)||!h||!h.isLane)&&this.diagram.drag(r,t,e),this.diagram.diagramActions=this.diagram.diagramActions&~(ee.PreventZIndexOnDragging|ee.DragUsingMouse),this.diagram.refreshCanvasLayers(),this.checkHtmlObjectDrag(r),!0}return!1},n.prototype.checkHtmlObjectDrag=function(t){var e=!1;this.diagram.views&&this.diagram.views.length>1&&(t instanceof ei?e=t.nodes.some(function(i){return i.shape&&"HTML"===i.shape.type}):t.shape&&"HTML"===t.shape.type&&(e=!0),e&&this.resetOverviewCanvas())},n.prototype.resetOverviewCanvas=function(){for(var t=0,e=this.diagram.views;t0&&(this.layoutAnimateModule.stopCurrentAnimation(this.objectStore[0],e,t),this.objectStore=[]),a=this.diagram.doLayout(),this.objectStore.push(a)),this.canUpdateTemplate=!1,this.diagram.blazorActions&=~on.expandNode,this.diagram.preventNodesUpdate=r,this.diagram.layoutAnimateModule&&this.diagram.organizationalChartModule&&!i)this.diagram.allowServerDataBinding=!1,this.layoutAnimateModule.expand(this.diagram.layout.enableAnimation,a,t,this.diagram);else{var l={element:$(t),state:!!t.isExpanded};this.triggerEvent(Ce.expandStateChange,l),this.diagram.lineRoutingModule&&this.diagram.constraints&nt.LineRouting&&"ComplexHierarchicalTree"!==this.diagram.layout.type&&this.diagram.resetSegments()}return this.diagram.layout.fixedNode=""===o?"":this.diagram.layout.fixedNode,a},n.prototype.getparentexpand=function(t,e,i,r){for(var s,o=0;o0&&(this.diagram.selectedItems.wrapper.rotateAngle=this.diagram.selectedItems.rotateAngle=s.rotateAngle),!(r instanceof te&&"SwimLane"!==r.shape.type)||r.isLane||r.isPhase||r.isHeader||Dn(this.diagram,r)){if(r instanceof ei)for(var d=0;d30||g.wrapper.outerBounds.topCenter.y-p.wrapper.outerBounds.bottomCenter.y>30)&&this.diagram.lineRoutingModule.refreshConnectorSegments(this.diagram,f,!0)}}this.updateSelector(),this.diagram.protectPropertyChange(!1)}},n.prototype.drawSelectionRectangle=function(t,e,i,r){this.diagram.drawSelectionRectangle(t,e,i,r)},n.prototype.startGroupAction=function(){this.diagram.startGroupAction()},n.prototype.endGroupAction=function(){this.diagram.endGroupAction()},n.prototype.removeChildFromBPmn=function(t,e,i){var r=this.diagram.nameTable[t.id]||t.nodes[0];if(i&&r&&r.processId&&r.processId===i.wrapper.id){var s=$(r);s.processId=r.processId,this.diagram.startGroupAction();var o=this.diagram.nameTable[r.processId].shape.activity.subProcess.processes||[];o.splice(o.indexOf(r.id),1),this.diagram.bpmnModule.removeChildFromBPMN(this.diagram.nameTable[r.processId].wrapper,r.id,this.diagram),this.diagram.nameTable[r.id].processId="",r.offsetX=r.wrapper.offsetX,r.offsetY=r.wrapper.offsetY;var a=$(r);this.addHistoryEntry({type:"PositionChanged",redoObject:{nodes:[a]},undoObject:{nodes:[s]},category:"Internal"}),this.diagram.endGroupAction()}},n.prototype.isDroppable=function(t,e){var i=this.diagram.nameTable[t.id]||t.nodes[0];return i instanceof te&&(!ce()&&"TextAnnotation"===i.shape.shape||("Group"===e.shape.shape&&(e.shape.activity.subProcess.collapsed=!1),!(i&&"Bpmn"===i.shape.type&&(i.processId===e.id||i.id===e.processId||"Bpmn"===e.shape.type&&!(e instanceof de)&&e.shape.activity&&e.shape.activity.subProcess&&e.shape.activity.subProcess.collapsed))))},n.prototype.renderHighlighter=function(t,e,i){if(new Ne,t.target instanceof te||t.target instanceof de||e&&(t.source instanceof te||t.source instanceof de)){var a=this.findTarget(e?t.sourceWrapper:t.targetWrapper,e?t.source:t.target,i,!0),l=void 0;if(a instanceof Rd)for(var h=a.id,c=t.target,u=0,f=c.wrapper.children[0].children[0].children[2].children;u0){var r=0;t[0]=this.diagram.nameTable[t[0].id]||t[0];var s="Object"===i?yr(t[0].wrapper):this.diagram.selectedItems.wrapper.bounds,o={nodes:[],connectors:[]},a={nodes:[],connectors:[]};for(r="Object"===i?r+1:r;r0){var i=0,r=0,s=0,o=0,a=0,l=0,h=0,c=0,d={nodes:[],connectors:[]},u={nodes:[],connectors:[]};for(i=0;io.center.y&&(r=n[parseInt(e.toString(),10)],n[parseInt(e.toString(),10)]=n[parseInt(i.toString(),10)],n[parseInt(i.toString(),10)]=r):s.center.x>o.center.x&&(r=n[parseInt(e.toString(),10)],n[parseInt(e.toString(),10)]=n[parseInt(i.toString(),10)],n[parseInt(i.toString(),10)]=r)}}return n}(t,e),i=1;i0){var i=0,r={x:.5,y:.5};t[0]=this.diagram.nameTable[t[0].id]||t[0];var s=yr(t[0].wrapper),o={nodes:[],connectors:[]},a={nodes:[],connectors:[]};for(i=1;ii.zIndex){for(var s=this.diagram.layers.indexOf(this.diagram.getActiveLayer()),o=this.diagram.layers[parseInt(s.toString(),10)].zIndexTable,a=JSON.parse(JSON.stringify(o)),l=i.zIndex,h=r.zIndex,c=h;c>=l;c--)l!==c?o[c-1]?(o[parseInt(c.toString(),10)]=o[c-1],this.diagram.nameTable[o[parseInt(c.toString(),10)]].zIndex=c):(o[c-1]=o[parseInt(c.toString(),10)],this.diagram.nameTable[o[c-1]].zIndex=c,delete o[parseInt(c.toString(),10)]):this.swapZIndexObjects(h,o,r.id,a);"SVG"===this.diagram.mode?(this.moveSvgNode(e.parentId,i.id),this.updateNativeNodeIndex(e.parentId,i.id)):this.diagram.refreshCanvasLayers()}},n.prototype.findLeastIndexConnector=function(t,e,i){for(var r=0;rs.zIndex&&(i=s)}return i},n.prototype.findLeastIndexObject=function(t,e){var i=t;return t instanceof te&&(i=this.findLeastIndexConnector(t.inEdges,e,i),i=this.findLeastIndexConnector(t.outEdges,e,i)),i},n.prototype.checkSelection=function(t,e){var i;if(1===t.nodes.length&&0===t.connectors.length)if(Dn(this.diagram,t.nodes[0],!0)){var r=t.nodes[0];if("SwimLane"===(i="SwimLane"===t.nodes[0].shape?t.nodes[0]:this.diagram.nameTable[t.nodes[0].parentId]).shape.type){var s="Horizontal"===i.shape.orientation;(r.isPhase&&(s&&"ResizeSouth"===e||!s&&"ResizeEast"===e)||r.isLane&&(s&&"ResizeEast"===e||!s&&"ResizeSouth"===e))&&W3(this.diagram,i,e)}else if("Grid"===i.container.type)if("Horizontal"===i.container.orientation&&1===r.rowIndex||"Vertical"===i.container.orientation&&r.rowIndex>0&&r.columnIndex>0){if("ResizeSouth"===e)for(var o=0;o1&&(this.diagram.realActions=this.diagram.realActions|$i.hScrollbarMoved,this.scrolled=!0),this.diagram.scrollSettings.horizontalOffset=t},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"verticalOffset",{get:function(){return this.vOffset},set:function(t){this.vOffset=t,Math.abs(this.vOffset-this.diagram.scrollSettings.verticalOffset)>1&&(this.diagram.realActions=this.diagram.realActions|$i.vScrollbarMoved,this.scrolled=!0),this.diagram.scrollSettings.verticalOffset=t},enumerable:!0,configurable:!0}),n.prototype.getBounds=function(){var e=this.diagram.spatialSearch.getPageBounds(0,0);return(e.x<0||e.y<0)&&!this.diagram.pageSettings.multiplePage?this.getPageBounds(void 0,void 0,!0,!0):this.getPageBounds(void 0,void 0,!0)},n.prototype.updateScrollOffsets=function(t,e){var i,r,s=this.getBounds();s.x*=this.currentZoom,s.y*=this.currentZoom,s.width*=this.currentZoom,s.height*=this.currentZoom,i=Math.max(0,t-s.left),r=Math.max(0,e-s.top),void 0!==t&&void 0!==e?(this.horizontalOffset=i,this.verticalOffset=r,this.diagram.setOffset(i,r)):this.diagram.setOffset(-this.horizontalOffset-s.x,-this.verticalOffset-s.y),this.transform={tx:Math.max(this.horizontalOffset,-s.left)/this.currentZoom,ty:Math.max(this.verticalOffset,-s.top)/this.currentZoom,scale:this.currentZoom}},n.prototype.setScrollOffset=function(t,e){this.scrolled=!1;var i=this.getBounds();i.x*=this.currentZoom,i.y*=this.currentZoom,i.width*=this.currentZoom,i.height*=this.currentZoom;var r=-i.left,s=-i.top,o=!1,a=this.viewPortWidth*this.currentZoom,l=this.viewPortHeight*this.currentZoom,h=r-t;if(h!==this.horizontalOffset){rh?this.horizontalOffset-=t:this.horizontalOffset=h,o=!0);var c=Math.max(i.right+this.vScrollSize,a);if(!o&&c<-h+this.viewPortWidth){var d=-h+a-this.vScrollSize,u=-this.horizontalOffset+a-this.vScrollSize;this.horizontalOffset=dd-u?h:-(i.right+this.vScrollSize-a),o=!0}o||(this.horizontalOffset=r-t)}o=!1;var f=s-e;if(f!==this.verticalOffset){sf?this.verticalOffset-=e:this.verticalOffset=f,o=!0);var p=Math.max(i.bottom+this.hScrollSize,l);if(!o&&p<-f+l){var g=-f+l-this.hScrollSize,v=-this.verticalOffset+l-this.hScrollSize;this.verticalOffset=gg-v?f:-(i.bottom+this.hScrollSize-l),o=!0}o||(this.verticalOffset=s-e)}this.transform={tx:Math.max(this.horizontalOffset,-i.left)/this.currentZoom,ty:Math.max(this.verticalOffset,-i.top)/this.currentZoom,scale:this.currentZoom},this.setSize()},n.prototype.getObjects=function(t,e){for(var i=[],r=0;r0){for(var l=0;l0){h.push(i[parseInt(o.toString(),10)].id);for(var d=0;d=e.bottom&&(l=0),-this.horizontalOffset<=e.x&&-this.horizontalOffset+this.viewPortWidth>=e.right&&(a=0),this.hScrollSize=a,this.vScrollSize=l;var h=this.diagramWidth,c=this.diagramHeight;this.diagramWidth=Math.max(e.right,-this.horizontalOffset+this.viewPortWidth-l)-i,this.diagramHeight=Math.max(e.bottom,-this.verticalOffset+this.viewPortHeight-a)-r,(h!==this.diagramWidth||c!==this.diagramHeight)&&"Diagram"!==this.diagram.scrollSettings.scrollLimit&&this.diagram.setSize(this.diagramWidth,this.diagramHeight),"Diagram"===this.diagram.scrollSettings.scrollLimit&&(h===this.diagramWidth&&c===this.diagramHeight&&1===this.currentZoom||this.diagram.diagramActions&&t&&(!this.diagram.diagramActions||!t||0===this.verticalOffset&&this.verticalOffset!==t.y||0===this.horizontalOffset&&this.horizontalOffset!==t.x)?t&&h===this.diagramWidth&&c===this.diagramHeight&&(this.diagram.diagramCanvas.scrollHeight>this.viewPortHeight&&t.y<0&&this.horizontalOffset===t.x&&0===this.verticalOffset||this.diagram.diagramCanvas.scrollWidth>this.viewPortWidth&&t.x<0&&this.verticalOffset===t.y&&0===this.horizontalOffset)&&(this.verticalOffset=t.y,this.horizontalOffset=t.x,this.transform={tx:Math.max(t.x,-e.left)/this.currentZoom,ty:Math.max(t.y,-e.top)/this.currentZoom,scale:this.currentZoom}):(this.diagram.scrollActions&da.Interaction&&t&&(this.transform={tx:Math.max(t.x,-e.left/this.currentZoom)/this.currentZoom,ty:Math.max(t.y,-e.top/this.currentZoom)/this.currentZoom,scale:this.currentZoom},this.horizontalOffset=t.x,this.verticalOffset=t.y),this.diagram.setSize(this.diagramWidth,this.diagramHeight),!(this.diagram.scrollActions&da.PropertyChange)&&t&&(this.horizontalOffset=t.x,this.verticalOffset=t.y,this.transform={tx:Math.max(t.x,-e.left)/this.currentZoom,ty:Math.max(t.y,-e.top)/this.currentZoom,scale:this.currentZoom}))),this.diagram.transformLayers(),this.diagram.element.style.overflow="hidden"},n.prototype.setViewPortSize=function(t,e){this.viewPortWidth=t,this.viewPortHeight=e},n.prototype.getPageBounds=function(t,e,i,r){var o,s=new Ne;if("Content"===e||r||null===this.diagram.pageSettings.width||null===this.diagram.pageSettings.height){var u=t?void 0:0;o=this.diagram.spatialSearch.getPageBounds(u,u)}else{var a=this.diagram.pageSettings.width,l=this.diagram.pageSettings.height,h=0,c=0;if(this.diagram.pageSettings.multiplePage){if((s=this.diagram.spatialSearch.getPageBounds(0,0)).right>a&&(a*=d=Math.ceil(s.right/a)),s.bottom>l&&(l*=d=Math.ceil(s.bottom/l)),s.left<0&&Math.abs(s.left)>h){var d=Math.ceil(Math.abs(s.left)/this.diagram.pageSettings.width);h=this.diagram.pageSettings.width*d}s.top<0&&Math.abs(s.top)>c&&(d=Math.ceil(Math.abs(s.top)/this.diagram.pageSettings.height),c=this.diagram.pageSettings.height*d)}o=new Ne(-h,-c,a+h,l+c)}if(i){var f=this.diagram.scrollSettings.padding;o.x-=f.left,o.y-=f.top,o.width+=f.left+f.right,o.height+=f.top+f.bottom}return o},n.prototype.getPageBreak=function(t){for(var e=0,i=0,r=-1,s=[],c=this.diagram.pageSettings.margin.left,d=this.diagram.pageSettings.margin.right,u=this.diagram.pageSettings.margin.top,f=this.diagram.pageSettings.margin.bottom,p=1,g=1;t.width>e;)(e+=this.diagram.pageSettings.width?this.diagram.pageSettings.width:t.width)===this.diagram.pageSettings.width&&(s[++r]={x1:t.left+c,y1:t.top+u,x2:t.left+c,y2:t.bottom-f}),ei;)(i+=this.diagram.pageSettings.height?this.diagram.pageSettings.height:t.height)===this.diagram.pageSettings.height&&(s[++r]={x1:t.left+c,y1:t.top+u,x2:t.right-d,y2:t.top+u}),i=this.diagram.scrollSettings.minZoom||l||t>=1)){this.currentZoom*=t;var c=this.getPageBounds(void 0,void 0,!0);c.x*=this.currentZoom,c.y*=this.currentZoom;var d=Bi();Gf(d,t,t,r.x,r.y),r3(d,e||0,i||0),bx(h,d);var u=Ke(h,{x:0,y:0});if(1===t&&(u=this.applyScrollLimit(u.x,u.y,s,o,a)),a=-c.y>=u.y&&-c.x>=u.x&&a,(this.diagram.scrollActions&da.PropertyChange||!(this.diagram.scrollActions&da.Interaction)||"Diagram"!==this.diagram.scrollSettings.scrollLimit||a)&&(this.transform={tx:Math.max(u.x,-c.left)/this.currentZoom,ty:Math.max(u.y,-c.top)/this.currentZoom,scale:this.currentZoom},this.horizontalOffset=u.x,this.verticalOffset=u.y),this.setSize(u),"SVG"!==this.diagram.mode&&Ds(this.diagram)&&this.diagram.scroller.virtualizeElements(),"SVG"!==this.diagram.mode&&!Ds(this.diagram)&&this.diagram.refreshDiagramLayer(),this.diagram.setOffset(-this.horizontalOffset-c.x,-this.verticalOffset-c.y),eb(this.diagram),this.diagram.views&&this.diagram.views.overview){var f=this.diagram.views.overview,p=f.scrollOverviewRect(f.parent.scroller.horizontalOffset,f.parent.scroller.verticalOffset,f.parent.scroller.currentZoom,!0);f.updateOverviewrect(-p.x,-p.y,p.width,p.height),f.updateView(f)}}}},n.prototype.fitToPage=function(t){var e=(t=t||{}).mode,i=t.region,r=t.margin||{},s=t.canZoomIn,o=t.customBounds,a=t.canZoomOut;r.bottom=r.bottom||25,r.top=r.top||25,r.left=r.left||25,r.right=r.right||25;var h,l=o,c=-this.horizontalOffset,d=-this.verticalOffset;if("PageSettings"===(i=i||"PageSettings")&&this.diagram.pageSettings.width&&this.diagram.pageSettings.height||this.diagram.nodes.length>0||this.diagram.connectors.length>0){e=e||"Page","CustomBounds"!==i&&(l=this.getPageBounds(!0,i,!0));var u={x:0,y:0};r.left+r.right>this.viewPortWidth&&(this.viewPortWidth<=100?(r.left=5,r.right=5):(r.left=25,r.right=25)),r.top+r.bottom>this.viewPortHeight&&(this.viewPortHeight<=100?(r.top=5,r.bottom=5):(r.top=25,r.bottom=25)),u.x=(this.viewPortWidth-(r.left+r.right))/l.width,u.y=(this.viewPortHeight-(r.top+r.bottom))/l.height,!s&&l.width-this.horizontalOffset-a+this.viewPortWidth&&(i=o.right-this.viewPortWidth,i+=20),o.x<-a&&(i=o.x),o.bottom>-l+this.viewPortHeight&&(r=o.bottom-this.viewPortHeight,r+=20),o.y<-l&&(r=o.y),this.zoom(1,-this.horizontalOffset-i,-this.verticalOffset-r,null,void 0,e))},n.prototype.bringToCenter=function(t){var e=this.currentZoom,i=new Ne(t.x*e,t.y*e,t.width*e,t.height*e),r=i.x+i.width/2-this.viewPortWidth/2,s=i.y+i.height/2-this.viewPortHeight/2;this.zoom(1,-this.horizontalOffset-(r*=-1),-this.verticalOffset-(s*=-1),null)},n.prototype.applyScrollLimit=function(t,e,i,r,s){if("Infinity"===this.diagram.scrollSettings.scrollLimit&&void 0===i&&!r&&(t=-t,e=-e),"Infinity"!==this.diagram.scrollSettings.scrollLimit){var o=void 0;if("Limited"===this.diagram.scrollSettings.scrollLimit){var a=this.diagram.scrollSettings.scrollableArea;o=new Ne(a.x,a.y,a.width,a.height)}(o=o||(s?this.getPageBounds():this.getPageBounds(!0))).x*=this.currentZoom,o.y*=this.currentZoom,o.width*=this.currentZoom,o.height*=this.currentZoom,void 0!==i&&(t*=-1,e*=-1),r&&(t*=-1,e*=-1);var l=Math.max(o.right,this.viewPortWidth);if(!r&&!(t<=o.x&&(t+this.viewPortWidth>=o.right||t>=o.right-this.viewPortWidth)||t>=o.x&&t+this.viewPortWidth<=l))if(t>=o.x)t=Math.max(o.x,Math.min(t,t-(t+this.viewPortWidth-this.vScrollSize-l)));else{var h=o.right-this.viewPortWidth;t=Math.min(h,o.x)}var c=Math.max(o.bottom,this.viewPortHeight);r||e<=o.y&&e+this.viewPortHeight>=o.bottom||e>=o.y&&e+this.viewPortHeight<=c||(e>=o.y?e=Math.max(o.y,Math.min(e,e-(e+this.viewPortHeight-this.hScrollSize-c))):(h=o.bottom-this.viewPortHeight,e=Math.min(o.y,h))),t*=-1,e*=-1}return{x:t,y:e}},n}(),tae=function(){function n(t,e,i,r,s){this.objects=[],this.left=t,this.top=e,this.width=i,this.height=r,this.spatialSearch=s}return n.prototype.findQuads=function(t,e){null!=this.first&&this.first.isIntersect(t)&&this.first.findQuads(t,e),null!=this.second&&this.second.isIntersect(t)&&this.second.findQuads(t,e),null!=this.third&&this.third.isIntersect(t)&&this.third.findQuads(t,e),null!=this.fourth&&this.fourth.isIntersect(t)&&this.fourth.findQuads(t,e),this.objects.length>0&&e.push(this)},n.prototype.isIntersect=function(t){return!(this.left+this.widtht.right||this.top>t.bottom)},n.prototype.selectQuad=function(){for(var i,t=null,e=this;null!=e;)i=e.getQuad(t),e=i.source,t=i.target||t;return t},n.prototype.getQuad=function(t){var e=this.width/2,i=this.height/2;if(e>=1e3&&i>=1e3){var r=this.left+e,s=this.top+i;if(this.spatialSearch.childRight<=r){if(this.spatialSearch.childBottom<=s)return this.first||((o=new n(this.left,this.top,e,i,this.spatialSearch)).parent=this,this.first=o),{source:this.first};if(this.spatialSearch.childTop>=s)return this.third||((o=new n(this.left,s,e,i,this.spatialSearch)).parent=this,this.third=o),{source:this.third}}else if(this.spatialSearch.childLeft>=r){if(this.spatialSearch.childBottom<=s)return this.second||((o=new n(r,this.top,e,i,this.spatialSearch)).parent=this,this.second=o),{source:this.second};var o;if(this.spatialSearch.childTop>=s)return this.fourth||((o=new n(r,s,e,i,this.spatialSearch)).parent=this,this.fourth=o),{source:this.fourth}}}return this.objects.push(this.spatialSearch.childNode),{target:this}},n.prototype.isContained=function(){return this.spatialSearch.childLeft>=this.left&&this.spatialSearch.childRight<=this.left+this.width&&this.spatialSearch.childTop>=this.top&&this.spatialSearch.childBottom<=this.top+this.height},n.prototype.addIntoAQuad=function(t){var e={};this.spatialSearch.setCurrentNode(t);for(var i=null;!e.isAdded;)i=(e=this.spatialSearch.parentQuad.add(i)).quad;return i},n.prototype.add=function(t){if(t=null,this.isContained())return{isAdded:!0,quad:t=this.selectQuad()};var e=void 0,i=!(0!==this.objects.length||this.first||this.second||this.third||this.fourth),r=2*this.width,s=2*this.height;return this.spatialSearch.childLeft=this.childLeft?(this.pageLeft=this.childLeft,this.leftElement=t,r=!0):t===this.leftElement&&(this.pageLeft=Number.MAX_VALUE,this.findLeft(this.parentQuad),r=!0)),(this.pageTop!==this.childTop||t!==this.topElement)&&(this.pageTop>=this.childTop?(this.pageTop=this.childTop,this.topElement=t,r=!0):t===this.topElement&&(this.pageTop=Number.MAX_VALUE,this.findTop(this.parentQuad),r=!0)),(this.pageBottom!==this.childBottom||t!==this.bottomElement)&&(this.pageBottom<=this.childBottom?(r=!0,this.pageBottom=this.childBottom,this.bottomElement=t):t===this.bottomElement&&(this.pageBottom=-Number.MAX_VALUE,this.findBottom(this.parentQuad),r=!0)),(this.pageRight!==this.childRight||t!==this.rightElement)&&(this.pageRight<=this.childRight?(this.pageRight=this.childRight,this.rightElement=t,r=!0):t===this.rightElement&&(this.pageRight=-Number.MAX_VALUE,this.findRight(this.parentQuad),r=!0)),r}return this.setCurrentNode(null),!1},n.prototype.isWithinPageBounds=function(t){return t.left>=this.pageLeft&&t.right<=this.pageRight&&t.top>=this.pageTop&&t.bottom<=this.pageBottom},n.prototype.findQuads=function(t){var e=[];return this.parentQuad.findQuads(t,e),e},n.prototype.findObjects=function(t){for(var i=[],r=0,s=this.findQuads(t);r=r.outerBounds.left&&(this.pageLeft=r.outerBounds.left,this.leftElement=r)}},n.prototype.findTop=function(t){t.first||t.second?(t.first&&this.findTop(t.first),t.second&&this.findTop(t.second)):(t.third&&this.findTop(t.third),t.fourth&&this.findTop(t.fourth));for(var e=0,i=t.objects;e=r.outerBounds.top&&(this.pageTop=r.outerBounds.top,this.topElement=r)}},n.prototype.setCurrentNode=function(t){if(this.childNode=t,t){var e=t.outerBounds;this.childLeft=Number(e.left),this.childTop=Number(e.top),this.childRight=Number(e.right),this.childBottom=Number(e.bottom)}else this.childLeft=Number.MAX_VALUE,this.childTop=Number.MAX_VALUE,this.childRight=-Number.MAX_VALUE,this.childBottom=-Number.MAX_VALUE},n.prototype.getPageBounds=function(t,e){if(this.pageLeft===Number.MAX_VALUE)return new Ne(0,0,0,0);var i=void 0!==t?Math.min(this.pageLeft,0):this.pageLeft,r=void 0!==e?Math.min(this.pageTop,0):this.pageTop;return new Ne(Math.round(i),Math.round(r),Math.round(this.pageRight-i),Math.round(this.pageBottom-r))},n.prototype.getQuad=function(t){return this.quadTable[t.id]},n}(),iae=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),nae=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return iae(t,n),function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);r>3&&s&&Object.defineProperty(t,e,s)}([I(!1)],t.prototype,"preventDefaults",void 0),t}(Ee),sae=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),o_=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},oae=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return sae(t,n),o_([I("")],t.prototype,"action",void 0),o_([I("")],t.prototype,"cursor",void 0),t}(Ee),a_=function(){function n(){this.size=20,this.intermediatePoints=[],this.gridCollection=[],this.startArray=[],this.targetGridCollection=[],this.sourceGridCollection=[],this.considerWalkable=[]}return n.prototype.lineRouting=function(t){var e=t.connectors.length;if(this.renderVirtualRegion(t),e>0)for(var i=0;i=t.right||e.right<=t.left||e.top>=t.bottom||e.bottom<=t.top)},n.prototype.findEndPoint=function(t,e,i){var r,s;if(e&&""!==t.sourcePortID&&t.sourcePortWrapper||!e&&""!==t.targetPortID&&t.targetPortWrapper){s=zo(r=e?{x:t.sourcePortWrapper.offsetX,y:t.sourcePortWrapper.offsetY}:{x:t.targetPortWrapper.offsetX,y:t.targetPortWrapper.offsetY},void 0,e?t.sourceWrapper.bounds:t.targetWrapper.bounds);var o=e?t.sourcePortWrapper.bounds:t.targetPortWrapper.bounds;r=i?"Top"===s?{x:o.topCenter.x,y:o.topCenter.y}:"Left"===s?{x:o.middleLeft.x,y:o.middleLeft.y}:"Right"===s?{x:o.middleRight.x,y:o.middleRight.y}:{x:o.bottomCenter.x,y:o.bottomCenter.y}:{x:o.center.x,y:o.center.y}}else r=e&&this.startNode||!e&&this.targetNode?e?{x:this.startNode.wrapper.offsetX,y:this.startNode.wrapper.offsetY}:{x:this.targetNode.wrapper.offsetX,y:this.targetNode.wrapper.offsetY}:e?{x:t.sourcePoint.x,y:t.sourcePoint.y}:{x:t.targetPoint.x,y:t.targetPoint.y};return r},n.prototype.refreshConnectorSegments=function(t,e,i,r){var h,c,f,p,g,y,S,b,M,w,C,s=e.sourceID,o=e.targetID,a=e.sourcePortID,l=e.targetPortID;if(function Jre(n,t){var e=0;return n.constraints&qe.LineRouting?e=n.constraints&qe.LineRouting:n.constraints&qe.InheritLineRouting&&(e=t.constraints&nt.LineRouting),e}(e,t)||r){this.startNode=t.nameTable[""+s],this.targetNode=t.nameTable[""+o],this.intermediatePoints=[],this.startArray=[],this.targetGridCollection=[],this.sourceGridCollection=[],this.startGrid=void 0,this.targetGrid=void 0;for(var D=0;D0;){var L=this.startArray.pop();if(L){for(D=0;D1&&(e.segments=[]),this.updateConnectorSegments(t,this.intermediatePoints,this.gridCollection,e,i)){this.considerWalkable=[];break e}this.targetGridCollection.splice(this.targetGridCollection.indexOf(O),1),L=this.startArray.pop()}}L&&this.findPath(L)}}}},n.prototype.checkChildNodes=function(t,e){var i=!1,r=!1;if(t.nodeId.length>=1&&!e)for(var s=0;s1&&this.targetGridCollection[0].nodeId.length>1)for(var c=0;c<=1;c++){for(var d=this.targetGridCollection[parseInt(c.toString(),10)].gridX,u=this.targetGridCollection[parseInt(c.toString(),10)].gridY,f=this.targetGridCollection[parseInt(c.toString(),10)].nodeId,p=void 0,g=0;g=e.right&&t.top<=e.top&&t.bottom>=e.bottom},n.prototype.getEndvalue=function(t,e){return this.gridCollection[t.gridX][t.gridY].walkable?t:"left"===e?this.getEndvalue(this.gridCollection[t.gridX-1][t.gridY],e):"right"===e?this.getEndvalue(this.gridCollection[t.gridX+1][t.gridY],e):"top"===e?this.getEndvalue(this.gridCollection[t.gridX][t.gridY-1],e):"bottom"===e?this.getEndvalue(this.gridCollection[t.gridX][t.gridY+1],e):t},n.prototype.changeValue=function(t,e,i){t.walkable||this.considerWalkable.push(t);for(var r,s=0;s<=e;s++)"left"===i?r=this.gridCollection[t.gridX-s][t.gridY]:"right"===i?r=this.gridCollection[t.gridX+s][t.gridY]:"top"===i?r=this.gridCollection[t.gridX][t.gridY-s]:"bottom"===i&&(r=this.gridCollection[t.gridX][t.gridY+s]),r.walkable||this.considerWalkable.push(r)},n.prototype.getIntermediatePoints=function(t){var e;for(this.intermediatePoints=[];t;)this.intermediatePoints.push({x:t.gridX,y:t.gridY}),t=t.parent;this.intermediatePoints.reverse(),this.intermediatePoints.length>=1&&void 0!==this.intermediatePoints[0]&&void 0!==this.intermediatePoints[1]&&(this.intermediatePoints[0].x===this.intermediatePoints[1].x?this.intermediatePoints[0].yi.y&&o.y>s.y){for(var a=i.xi.x&&o.x>s.x)){for(var u=i.y=1&&u.length>1&&(g=u[u.length-2].x!==u[u.length-1].x?u[u.length-2].x>u[u.length-1].x?"Left":"Right":u[u.length-2].y>u[u.length-1].y?"Top":"Bottom"),M>=2&&v===g&&u.length>1&&u.splice(u.length-2,1),v=g);if(u&&u.length>1){for(var w=0;wD.x?S.bounds.middleLeft:S.bounds.middleRight),w===u.length-2&&""===r.targetPortID&&y&&(l=C.x>D.x?y.bounds.middleRight:y.bounds.middleLeft),0===w&&b&&(C.x=b.x,C.y=D.y=b.y,b=qa(r,0,b,Ol(S.bounds,_n(C.x>D.x?"Left":"Right")),!1),C.x=b.x),w===u.length-2&&l&&(w>0&&r.targetDecorator&&l.x-D.x<0&&Math.abs(l.x-C.x)0&&r.targetDecorator&&l.x-D.x>0&&Math.abs(l.x-C.x)D.y?S.bounds.topCenter:S.bounds.bottomCenter),w===u.length-2&&""===r.targetPortID&&y&&(l=C.y>D.y?y.bounds.bottomCenter:y.bounds.topCenter),0===w&&b&&(C.y=b.y,C.x=D.x=b.x,b=qa(r,0,b,Ol(S.bounds,_n(C.y>D.y?"Top":"Bottom")),!1),C.y=b.y),w===u.length-2&&l&&(w>0&&r.targetDecorator&&l.y-D.y<0&&Math.abs(l.y-C.y)0&&r.targetDecorator&&l.y-D.y>0&&Math.abs(l.y-C.y)D.x?(f="Left",p=C.x-D.x):(f="Right",p=D.x-C.x):C.y>D.y?(f="Top",p=C.y-D.y):(f="Bottom",p=D.y-C.y),o.push({type:"Orthogonal",length:p,direction:f})}}if(o&&o.length>0){var L=o[o.length-1];if(1===o.length&&(L.length-=20),L.length<10&&2===o.length&&(o.pop(),o.length>0&&(o[0].length-=20,L=o[0])),r.targetDecorator&&("Top"===L.direction||"Bottom"===L.direction)&&L.length>r.targetDecorator.height+1||("Right"===L.direction||"Left"===L.direction)&&L.length>r.targetDecorator.width+1)return r.segments=o,s&&t.connectorPropertyChange(r,{},{type:"Orthogonal",segments:o}),!0}return!1},n.prototype.findPath=function(t){for(var e,i=[],r=this.findNearestNeigbours(t,this.gridCollection,!0),s=0;sl)&&(e.x!==t.gridX||e.y!==t.gridY)&&(i.push(e),o.previousDistance=l,o.afterDistance=o.afterDistance||this.manhattan(Math.abs(e.x-this.targetGrid.gridX),Math.abs(e.y-this.targetGrid.gridY)),o.totalDistance=o.previousDistance+o.afterDistance,o.parent=t)}if(i.length>0)for(s=0;st?i*t+e:i*e+t},n.prototype.manhattan=function(t,e){return t+e},n.prototype.findNearestNeigbours=function(t,e,i){var r=[],s=t.parent;if(s){var o=(t.gridX-s.gridX)/Math.max(Math.abs(t.gridX-s.gridX),1),a=(t.gridY-s.gridY)/Math.max(Math.abs(t.gridY-s.gridY),1);0!==o?(this.isWalkable(t.gridX,t.gridY-1,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX][t.gridY-1])&&r.push(e[t.gridX][t.gridY-1]),this.isWalkable(t.gridX,t.gridY+1,!0)&&this.sourceGridCollection.indexOf(e[t.gridX][t.gridY+1])&&r.push(e[t.gridX][t.gridY+1]),this.isWalkable(t.gridX+o,t.gridY,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX+o][t.gridY])&&r.push(e[t.gridX+o][t.gridY])):0!==a&&(this.isWalkable(t.gridX-1,t.gridY,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX-1][t.gridY])&&r.push(e[t.gridX-1][t.gridY]),this.isWalkable(t.gridX+1,t.gridY,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX+1][t.gridY])&&r.push(e[t.gridX+1][t.gridY]),this.isWalkable(t.gridX,t.gridY+a,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX][t.gridY+a])&&r.push(e[t.gridX][t.gridY+a]))}else this.neigbour(t,"top",r,i),this.neigbour(t,"right",r,i),this.neigbour(t,"bottom",r,i),this.neigbour(t,"left",r,i);return r},n.prototype.neigbour=function(t,e,i,r){for(var o,s=1;s>0;){var a="top"===e||"bottom"===e?t.gridX:"left"===e?t.gridX-s:t.gridX+s,l="right"===e||"left"===e?t.gridY:"top"===e?t.gridY-s:t.gridY+s;if((o=this.gridCollection[parseInt(a.toString(),10)][parseInt(l.toString(),10)])&&(r&&-1===this.sourceGridCollection.indexOf(o)||!r&&-1===this.targetGridCollection.indexOf(o)))return i&&this.isWalkable(a,l)&&i.push(o),s;if(!(a>0&&l>0))break;s++}return null},n.prototype.resetGridColl=function(t,e,i){for(var s,r=1;r>0;){var o="top"===e||"bottom"===e?t.gridX:"left"===e?t.gridX-r:t.gridX+r,a="right"===e||"left"===e?t.gridY:"top"===e?t.gridY-r:t.gridY+r;if((s=this.gridCollection[parseInt(o.toString(),10)][parseInt(a.toString(),10)])&&(i&&-1===this.sourceGridCollection.indexOf(s)||!i&&-1===this.targetGridCollection.indexOf(s))){if(this.isWalkable(o,a))break;var l=this.gridCollection[parseInt(o.toString(),10)][parseInt(a.toString(),10)];this.considerWalkable.push(l)}if(!(o>0&&a>0))break;"top"===e||"left"===e?r--:r++}return null},n.prototype.isWalkable=function(t,e,i){if(t>=0&&t=0&&e0?1:-1,this.isWalkable(h,c-1)&&!this.isWalkable(h-a,c-1)||this.isWalkable(h,c+1)&&!this.isWalkable(h-a,c+1)))return{x:t,y:e};if(0!==l){if(l=l>0?1:-1,this.isWalkable(h-1,c)&&!this.isWalkable(h-1,c-l)||this.isWalkable(h+1,c)&&!this.isWalkable(h+1,c-l))return{x:t,y:e};if(this.findIntermediatePoints(h+1,c,h,c,s,o)||this.findIntermediatePoints(h-1,c,h,c,s,o))return{x:t,y:e}}return this.findIntermediatePoints(h+a,c+l,h,c,s,o)},n.prototype.destroy=function(){},n.prototype.getModuleName=function(){return"LineRouting"},n}(),aae=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),hae=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return aae(t,n),function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);r>3&&s&&Object.defineProperty(t,e,s)}([I(!0)],t.prototype,"inversedAlignment",void 0),t}(Ee),cae=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Oe=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},xT=function(n,t,e,i){return new(e||(e=Promise))(function(r,s){function o(h){try{l(i.next(h))}catch(c){s(c)}}function a(h){try{l(i.throw(h))}catch(c){s(c)}}function l(h){h.done?r(h.value):new e(function(c){c(h.value)}).then(o,a)}l((i=i.apply(n,t||[])).next())})},TT=function(n,t){var i,r,s,o,e={label:0,sent:function(){if(1&s[0])throw s[1];return s[1]},trys:[],ops:[]};return o={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function a(h){return function(c){return function l(h){if(i)throw new TypeError("Generator is already executing.");for(;e;)try{if(i=1,r&&(s=2&h[0]?r.return:h[0]?r.throw||((s=r.return)&&s.call(r),0):r.next)&&!(s=s.call(r,h[1])).done)return s;switch(r=0,s&&(h=[2&h[0],s.value]),h[0]){case 0:case 1:s=h;break;case 4:return e.label++,{value:h[1],done:!1};case 5:e.label++,r=h[1],h=[0];continue;case 7:h=e.ops.pop(),e.trys.pop();continue;default:if(!(s=(s=e.trys).length>0&&s[s.length-1])&&(6===h[0]||2===h[0])){e=0;continue}if(3===h[0]&&(!s||h[1]>s[0]&&h[1]0&&((!s.style||!s.style.fill)&&(o.style.fill="transparent"),(!s.style||!s.style.strokeColor)&&(o.style.strokeColor="transparent")),s.shape&&"UmlActivity"===s.shape.type&&rb(s,o),s.shape&&"SwimLane"===s.shape.type&&fF(s,o),r.nodeDefaults&&Ro(o,s,r.nodeDefaults),r.updateAnnotationText(o.annotations);if(e&&e.connectors)for(a=0;e&&e.connectors&&a0&&0===i.nodes.length)this.clearCollection(),a=!0;else{for(var g=0,v=Object.keys(e.nodes);g0&&0===i.connectors.length)this.clearCollection(!0),a=!0;else{for(var C=0,D=Object.keys(e.connectors);C0){this.renderSelector(!0);break}if(e.selectedItems.constraints){this.renderSelector(!0);break}break;case"snapSettings":this.updateSnapSettings(e);break;case"commandManager":this.initCommands();break;case"layout":o=!0;break;case"segmentThumbShape":this.updateSelector();break;case"dataSourceSettings":this.clear(),"None"===this.layout.type?a=!0:(this.initObjects(),o=!0);break;case"tooltip":l3(this);break;case"rulerSettings":this.updateRulerSettings(e);break;case"layers":this.updateLayer(e);break;case"scrollSettings":this.scrollActions|=da.PropertyChange,this.updateScrollSettings(e),this.scrollActions&=~da.PropertyChange,this.scrollSettings.horizontalOffset=-this.scroller.horizontalOffset||0,this.scrollSettings.verticalOffset=-this.scroller.verticalOffset||0;break;case"locale":e.locale!==i.locale&&(this.realActions|=$i.PreventDataInit,n.prototype.refresh.call(this),this.realActions&=~$i.PreventDataInit);break;case"contextMenuSettings":if(void 0!==e.contextMenuSettings.showCustomMenuOnly&&(this.contextMenuSettings.showCustomMenuOnly=e.contextMenuSettings.showCustomMenuOnly),void 0!==e.contextMenuSettings.show&&(this.contextMenuSettings.show=e.contextMenuSettings.show),e.contextMenuSettings.items){for(var A=e.contextMenuSettings.items,x=0,P=Object.keys(A);x0){for(var N=[],T=O.ports.length-1;T>=0;T--)"LineDistribution"===O.ports[parseInt(T.toString(),10)].id.split("_")[1]&&N.push(O.ports[parseInt(T.toString(),10)]);this.removePorts(O,N)}}for(T=0;T0)for(var ue=0,fe=Object.keys(e.nodes);ue0)for(var De=0,xe=Object.keys(e.connectors);De=0;o--)this.commandHandler.expandNode(r[parseInt(o.toString(),10)],this,0!==o);this.canLayout&&this.doLayout(),this.lineRoutingModule?this.connectors.sourceID!==this.connectors.targetID&&this.lineRoutingModule.lineRouting(this):this.constraints&nt.LineRouting&&console.warn('[WARNING] :: Module "LineRouting" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),this.validatePageSize(),this.renderPageBreaks(),this.diagramRenderer.renderSvgGridlines(this.snapSettings,Fd(this.element.id),this.scroller.transform,this.rulerSettings,this.hRuler,this.vRuler),this.commandHandler.initSelectorWrapper(),this.notify("initial-load",{}),this.trigger("load"),this.scroller.setSize(),this.scroller.updateScrollOffsets(),this.isRefreshed||this.refreshDiagramLayer(),(this.scrollSettings.verticalOffset>0||this.scrollSettings.horizontalOffset>0)&&this.updateScrollOffset(),X.isDevice&&(this.tool=ri.ZoomPan|ri.SingleSelect),this.notify("initial-end",{}),this.isProtectedOnChange=!1,this.tooltipObject=l3(this),this.diagramActions=ee.Render,this.initCommands();var a=document.getElementsByClassName(this.element.id+"_hiddenUserHandleTemplate");(function Noe(n,t,e,i){var r,s,o,a,l,d=document.getElementById(i).ej2_instances[0];if(n&&t){r=GF(n);for(var u=0,f=e.userHandles;u0;)e[0].parentNode.removeChild(e[0]);var i=document.getElementById(this.element.id+"content");i&&this.element.removeChild(i);var r="measureElement";if(window[""+r]){window[""+r].usageCount-=1;var s="measureElementCount";window[""+s]--,0===window[""+s]&&(window[""+r].parentNode.removeChild(window[""+r]),window[""+r]=null)}}window.domTable={};for(var a=0;a1&&(this.callBlazorModel=!1,this.insertBlazorDiagramObjects(this.selectedItems),this.commandHandler.group(),this.callBlazorModel=!0,this.commandHandler.getBlazorOldValues())},t.prototype.unGroup=function(){this.callBlazorModel=!1,this.insertBlazorDiagramObjects(this.selectedItems),this.commandHandler.unGroup(),this.callBlazorModel=!0,this.commandHandler.getBlazorOldValues()},t.prototype.sendToBack=function(){this.commandHandler.sendToBack()},t.prototype.setActiveLayer=function(e){var i=this.commandHandler.getLayer(e);this.activeLayer=i},t.prototype.addLayer=function(e,i){this.commandHandler.addLayer(e,i)},t.prototype.removeLayer=function(e){this.commandHandler.removeLayer(e,ce())},t.prototype.moveObjects=function(e,i){$(this.layers),this.enableServerDataBinding(!1),this.commandHandler.moveObjects(e,i)},t.prototype.layerObjectUpdate=function(){},t.prototype.sendLayerBackward=function(e){this.layerObjectUpdate(),this.commandHandler.sendLayerBackward(e)},t.prototype.bringLayerForward=function(e){this.layerObjectUpdate(),this.commandHandler.bringLayerForward(e)},t.prototype.cloneLayer=function(e){this.commandHandler.cloneLayer(e)},t.prototype.bringToFront=function(){this.commandHandler.bringToFront()},t.prototype.moveForward=function(){this.commandHandler.sendForward()},t.prototype.sendBackward=function(){this.commandHandler.sendBackward()},t.prototype.getObject=function(e){return this.nameTable[""+e]},t.prototype.getNodeObject=function(e){return $(this.nameTable[""+e])},t.prototype.getConnectorObject=function(e){return $(this.nameTable[""+e])},t.prototype.getActiveLayer=function(){return this.activeLayer},t.prototype.nudgeCommand=function(e,i,r){if("object"!=typeof e&&(this.selectedItems.nodes.length||this.selectedItems.connectors.length)>0){var s=void 0;i.type&&"KEYDOWN"===i.type&&(s=i.type),this.nudge(e,void 0,void 0,s)}},t.prototype.nudge=function(e,i,r,s){var o=0,a=0;"Left"===e||"Right"===e?o=("Left"===e?-1:1)*(i||1):a=("Up"===e?-1:1)*(r||1),"KEYDOWN"===s&&(o*=5,a*=5);var h=this.selectedItems,c=this.selectedItems.wrapper.children[0];if(c instanceof ai)this.commandHandler.labelDrag(h.nodes[0],c,o,a);else{var d=$(this.selectedItems);this.protectPropertyChange(!0),this.drag(h,o,a),this.protectPropertyChange(!1);var u={type:"PositionChanged",redoObject:$(this.selectedItems),undoObject:d,category:"Internal"};this.addHistoryEntry(u)}this.refreshCanvasLayers()},t.prototype.insertBlazorDiagramObjects=function(e){},t.prototype.drag=function(e,i,r){if(this.insertBlazorDiagramObjects(e),!(this.bpmnModule&&e instanceof te&&this.bpmnModule.updateAnnotationDrag(e,this,i,r))){if(e instanceof ei){if(this.preventConnectorsUpdate=!0,e.nodes&&e.nodes.length){for(var o=0,a=e.nodes;o0&&o.nodes[0].children){this.fromUndo||(this.rotateUsingButton=!0);for(var h=this.commandHandler.getAllDescendants(o.nodes[0],[]),c=0;c0&&o.nodes[0].children){var g={type:"RotationChanged",redoObject:$(e),undoObject:$(o),category:"Internal",childTable:a};this.commandHandler.addHistoryEntry(g),this.commandHandler.updateSelector()}return u},t.prototype.dragSourceEnd=function(e,i,r){this.insertBlazorDiagramObjects(e),this.commandHandler.dragSourceEnd(e,i,r),this.callBlazorModel&&this.commandHandler.getBlazorOldValues()},t.prototype.dragTargetEnd=function(e,i,r){this.insertBlazorDiagramObjects(e),this.commandHandler.dragTargetEnd(e,i,r),this.callBlazorModel&&this.commandHandler.getBlazorOldValues()},t.prototype.findObjectsUnderMouse=function(e,i){return this.eventHandler.findObjectsUnderMouse(e,i)},t.prototype.findObjectUnderMouse=function(e,i,r){return this.eventHandler.findObjectUnderMouse(e,i,r)},t.prototype.findTargetObjectUnderMouse=function(e,i,r,s,o){return this.eventHandler.findTargetUnderMouse(e,i,r,s,o)},t.prototype.findElementUnderMouse=function(e,i,r,s){return this.eventHandler.findElementUnderMouse(e,i,r,s)},t.prototype.findActionToBeDone=function(e,i,r,s){return this.eventHandler.findActionToBeDone(e,i,r,s)},t.prototype.updateConnectorPort=function(e){if(e.ports.length)for(var i=void 0,r=0,s=e.ports;r=0;s--)if(i.push(r[parseInt(s.toString(),10)]),i.length>this.historyManager.stackLimit)return i}else i=r;return i},t.prototype.getEdges=function(e){return e.outEdge?this.nameTable[e.id].outEdges:this.nameTable[e.id].inEdges},t.prototype.getParentId=function(e){return this.nameTable[""+e].parentId},t.prototype.addConnector=function(e){return this.add(e)},t.prototype.UpdateBlazorDiagramModelCollection=function(e,i,r,s){},t.prototype.UpdateBlazorDiagramModel=function(e,i,r,s){},t.prototype.UpdateBlazorLabelOrPortObjects=function(e,i,r,s){},t.prototype.addBlazorDiagramObjects=function(){},t.prototype.removeNodeEdges=function(e,i,r){var s=this.nameTable[""+e],o=r?s.outEdges:s.inEdges;if(o.length>0)for(var a=0;a0)){for(var c=0;c0))}this.removePortEdges(l,a.element.sourcePortID,a.element.id,h)}a.element.targetID&&this.removeNodeEdges(a.element.targetID,a.element.id,!1)}}this.diagramActions=this.diagramActions|ee.PublicMethod,e.id=e.id||Qe();var u=this.activeLayer;if(!a.cancel&&u&&!u.lock){if(u.objects.indexOf(e.id)<0&&!u.lock&&(u.visible||(u.visible=!0,this.dataBind()),u.objects.push(e.id)),ps(e)===de)(r=new de(this,"connectors",e,!0)).status="New",this.nameTable[r.targetID]&&"TextAnnotation"===this.nameTable[r.targetID].shape.shape&&(r.isBpmnAnnotationConnector=!0,r.constraints=r.constraints&~qe.Delete),Ro(r,e,this.connectorDefaults),this.connectors.push(r),this.initObject(r),!1===e.visible&&this.updateElementVisibility(r.wrapper,r,e.visible),this.updateEdges(r),this.insertBlazorConnector(r);else{if(Ro(r=new te(this,"nodes",e,!0),e,this.nodeDefaults),r.parentId=e.parentId?e.parentId:r.parentId,r.umlIndex=e.umlIndex,r.status="New",(o="TextAnnotation"===r.shape.shape)&&!e.isTextAnnotationCopied&&(r.inEdges=e.inEdges?e.inEdges:r.inEdges),this.nodes.push(r),this.initObject(r,u,void 0,i),o&&this.bpmnModule)for(c=0;c-1&&e.parentId&&this.nameTable[e.parentId]&&"UmlClassifier"===this.nameTable[e.parentId].shape.type){var g=this.nameTable[e.parentId];g.children.splice(r.umlIndex,0,r.id),g.wrapper.children.splice(r.umlIndex,0,r.wrapper),g.wrapper.measure(new me),g.wrapper.arrange(g.wrapper.desiredSize),this.updateDiagramObject(g)}}if(a={element:r,cause:this.diagramActions,diagramAction:this.getDiagramAction(this.diagramActions),state:"Changed",type:"Addition",cancel:!1},this.parentObject&&(a.parentId=this.parentObject.id),"helper"!==e.id&&!(this.diagramActions&ee.PreventCollectionChangeOnDragOver)&&this.triggerEvent(Ce.collectionChange,a),!(this.diagramActions&ee.UndoRedo||this.diagramActions&ee.Group||this.diagramActions&ee.PreventHistory)){var v={type:"CollectionChanged",changeType:"Insert",undoObject:$(e),redoObject:$(e),category:"Internal"};this.addHistoryEntry(v)}this.parentObject=void 0,"SVG"===this.mode&&(this.updateSvgNodes(r),this.updateTextElementValue(r),this.updateDiagramObject(r),o&&this.updateDiagramObject(this.nameTable[r.inEdges[0]]),r.shape.activity&&r.shape.activity.subProcess.processes&&r.shape.activity.subProcess.processes.length&&this.updateProcesses(r),this.updateBridging())}}if(this.protectPropertyChange(s),this.resetDiagramActions(ee.PublicMethod),r&&this.layers.length>1&&this.moveNode(r),this.views)for(var S=0,b=this.views;S=0;l--)this.moveSvgNode(a[parseInt(l.toString(),10)])}for(var h=0,c=i;h=0;o--)r[parseInt(o.toString(),10)]===e.id&&r.splice(o,1);for(var a=0;s.ports&&a=0;s--)if(i=this.nameTable[r[parseInt(s.toString(),10)]])if(this.connectorTable[i.id]=$(i),i.isBpmnAnnotationConnector){var o=this.nameTable[i.targetID];this.removeObjectsFromLayer(i);var a=this.connectors.indexOf(i);-1!==a&&this.connectors.splice(a,1),this.removeElements(i),this.removeFromAQuad(i),delete this.nameTable[i.id];var l=this.nameTable[i.sourceID];if(l){var h=l.outEdges.indexOf(i.id);-1!==h&&l.outEdges.splice(h,1)}e.id!==i.targetID&&this.remove(o)}else this.remove(i)},t.prototype.removeObjectsFromLayer=function(e){if(e.children)for(var i=0;i-1&&(_r(this,e)&&this.unSelect(e),this.layers[parseInt(s.toString(),10)].objects.splice(a,1),delete this.layers[parseInt(s.toString(),10)].zIndexTable[this.nameTable[e.id].zIndex])},t.prototype.removeElements=function(e){if("SVG"===this.mode||"Canvas"===this.mode&&"Native"===e.shape.type){var i=xt(e.id+"_groupElement",this.element.id),r=e;if(r.ports&&r.ports.length>0)for(var s=0;s0){l[parseInt(s.toString(),10)].id.indexOf("icon_content")>0&&"SVG"===this.mode&&((h=xt(l[parseInt(s.toString(),10)].id+"_shape_groupElement",this.element.id))&&h.parentNode.removeChild(h),(h=xt(l[parseInt(s.toString(),10)].id+"_rect_groupElement",this.element.id))&&h.parentNode.removeChild(h));for(var c=0,d=this.views;c=0;o--)a.children[parseInt(o.toString(),10)].children&&(l=n.nameTable[a.children[parseInt(o.toString(),10)].id])&&(l.isLane?$v(n,l):(n.removeDependentConnector(l),n.diagramActions|=ee.PreventHistory,l.constraints&ie.Delete?n.remove(l):q3(n,l,{},!1),n.diagramActions&=~ee.PreventHistory));a&&(i=n.nameTable[a.id])&&$v(n,i)}}(this,e),!(this.diagramActions&ee.UndoRedo||this.diagramActions&ee.PreventHistory)&&(e instanceof te||e instanceof de)){var o={type:"CollectionChanged",changeType:"Remove",undoObject:$(e),redoObject:$(e),category:"Internal"};this.diagramActions&ee.Clear||e.children&&!e.isLane&&!e.isPhase&&e.children.length>0&&this.undoRedoModule&&"None"===this.layout.type&&(this.historyManager.startGroupAction(),s=!0),(e instanceof te||e instanceof de)&&this.deleteDependentConnector&&this.removeDependentConnector(e),!e.isLane&&!e.isPhase&&!(this.diagramActions&ee.Clear)&&!this.isStackChild(e)&&this.addHistoryEntry(o)}"TextAnnotation"===e.shape.shape&&this.removeDependentConnector(e),e.children&&!e.isLane&&!e.isPhase&&(!(this.diagramActions&ee.UndoRedo)||!ce())&&this.deleteGroup(e),e.parentId&&(this.deleteChild(e,void 0,!0),this.nameTable[e.parentId]&&"UmlClassifier"===this.nameTable[e.parentId].shape.type&&(this.updateDiagramObject(this.nameTable[e.parentId]),this.updateConnectorEdges(this.nameTable[e.parentId])));var a=void 0;this.diagramActions=this.diagramActions|ee.PublicMethod;var l=this.nameTable[e.id];if(l instanceof te?("Bpmn"===l.shape.type&&this.bpmnModule&&this.bpmnModule.removeBpmnProcesses(l,this),(l.isLane||l.isPhase||"SwimLane"===l.shape.type)&&(h=l.isLane||l.isPhase?this.nameTable[l.parentId]:this.nameTable[l.id],l.isLane?Q3(this,l,h):l.isPhase&&G3(this,l,h)),-1!==(a=this.nodes.indexOf(l))&&(this.crudDeleteNodes.push(this.nameTable[l.id]),this.nodes.splice(a,1),this.updateNodeEdges(l))):(-1!==(a=this.connectors.indexOf(l))&&(this.crudDeleteNodes.push(this.nameTable[l.id]),this.connectors.splice(a,1)),this.updateEdges(l),this.spliceConnectorEdges(e,!0),this.spliceConnectorEdges(e,!1)),!this.isServerUpdate&&!(this.blazorActions&on.GroupClipboardInProcess)&&this.commandHandler.getBlazorOldValues(),s&&this.historyManager.endGroupAction(),_r(this,l)&&this.unSelect(l),!l.isPhase){if(this.removeObjectsFromLayer(e),this.currentDrawingObject&&(this.currentDrawingObject.wrapper=void 0),delete this.nameTable[e.id],i.length>0&&i[0].id===l.id&&l.parentId){var h,d=this.nameTable[l.parentId];d&&d.isLane&&"SwimLane"===this.nameTable[d.parentId].shape.type&&Y3(this,h=this.nameTable[d.parentId],d,l)}this.removeElements(l),this.updateBridging(),"SVG"!==this.mode&&this.refreshDiagramLayer(),this.diagramActions&ee.Clear||(this.removeFromAQuad(l),r={element:e,cause:this.diagramActions,diagramAction:this.getDiagramAction(this.diagramActions),state:"Changed",type:"Removal",cancel:!1},"helper"!==e.id&&this.triggerEvent(Ce.collectionChange,r),this.resetTool())}}}else if(i.length>0){this.undoRedoModule&&(this.historyManager.startGroupAction(),this.blazorActions|=on.GroupingInProgress,s=!0);for(var u=0;u=p.wrapper.bounds.width&&"Horizontal"===p.shape.orientation||this.selectedItems.wrapper.bounds.y<=p.wrapper.bounds.y+g&&this.selectedItems.wrapper.bounds.height>=p.wrapper.bounds.height-g&&"Vertical"===p.shape.orientation)&&(kI(p)||p.shape.lanes.length>1)&&this.remove(i[parseInt(u.toString(),10)])}}else this.remove(i[parseInt(u.toString(),10)])}s&&(this.blazorActions&=~on.GroupingInProgress,this.isServerUpdate=!0,this.commandHandler.getBlazorOldValues(),this.UpdateBlazorDiagramModelCollection(void 0,void 0,void 0,!0),this.historyManager.endGroupAction(),this.isServerUpdate=!1),this.clearSelection()}e&&(kI(e)||this.diagramActions&ee.Clear)||this.diagramActions&ee.UndoRedo||this.diagramActions&ee.PreventHistory||!(e instanceof te||e instanceof de)||(o={type:"ConnectionChanged",undoObject:$(e),redoObject:$(e),category:"Internal"},!e.isLane&&!e.isPhase&&!(this.diagramActions&ee.Clear)&&!this.isStackChild(e)&&this.addHistoryEntry(o)),this.tooltipObject.close()},t.prototype.isStackChild=function(e){var i,r=this.nameTable[e.parentId];if(e&&e.parentId&&r.container&&"Stack"===r.container.type&&"UmlClassifier"!==this.nameTable[e.parentId].shape.type){i=!0;var s={sourceIndex:r.wrapper.children.indexOf(e.wrapper),source:e,target:void 0,targetIndex:void 0};this.diagramActions&ee.UndoRedo||this.addHistoryEntry({type:"StackChildPositionChanged",redoObject:{sourceIndex:void 0,source:e,target:void 0,targetIndex:void 0},undoObject:s,category:"Internal"})}return i},t.prototype.deleteChild=function(e,i,r){var s;if(s="string"==typeof e?e:e.id,(i=i?this.nameTable[i.id]:this.nameTable[e.parentId])&&i.children){for(var o=0;o=0;i--)this.removeLayer(this.layers[parseInt(i.toString(),10)].id);this.commandHandler.addLayer({id:"default_layer",visible:!0,lock:!1,objects:[],zIndex:0,objectZIndex:-1,zIndexTable:{}},null,!0),this.setActiveLayer(this.layers[this.layers.length-1].id)},t.prototype.clearObjects=function(e){var i=[];i=e||(i=i.concat(this.nodes)).concat(this.connectors),this.diagramActions=this.diagramActions|ee.Clear;for(var r=0,s=i;r0||"Text"===e.shape.type))if("Text"===e.shape.type)i=e.wrapper.children[0].id.split("_")[1];else for(var p=e.annotations.length-1;p>=0;p--)e.annotations[parseInt(p.toString(),10)].visibility&&(i=e.annotations[parseInt(p.toString(),10)].id);i&&(u=this.getWrapper(e.wrapper,i))}if(e&&u&&!(u instanceof es)&&(!function sne(n,t){return"Text"===t.shape.type?t.constraints&ie.ReadOnly:t.constraints&(t instanceof de?qe.ReadOnly:ie.ReadOnly)?n.constraints&Nr.InheritReadOnly?1:0:n.constraints&Nr.ReadOnly?1:0}(u,e)||f)){var g=u.style,v=void 0;v=90>(v=u.bounds.width50?50:e.width,u.style.fontSize)),e.parentId&&"UmlClassifier"===this.nameTable[e.parentId].shape.type?(l.width=e.wrapper.bounds.width-20,c=(e.wrapper.bounds.center.x+r.tx)*r.scale-l.width/2*s-2.5,d=(e.wrapper.bounds.center.y+r.ty)*r.scale-l.height/2*s-3,u.style.textAlign="Left"):(l.width=Math.max(l.width,50),c=(u.bounds.center.x+r.tx)*r.scale-l.width/2*s-2.5,d=(u.bounds.center.y+r.ty)*r.scale-l.height/2*s-3),Ho(y,{id:this.element.id+"_editTextBoxDiv",style:"position: absolute;left:"+c+"px;top:"+d+"px;width:"+(l.width+1)*s+"px;height:"+l.height*s+"px; containerName:"+e.id+";"}),Ho(S,{"aria-label":a,id:this.element.id+"_editBox",style:"width:"+(l.width+1)*s+"px;height:"+l.height*s+"px;resize: none;outline: none;overflow: hidden;;font-family:"+g.fontFamily+";font-size:"+g.fontSize*s+"px;text-align:"+u.style.textAlign.toLocaleLowerCase()+";",class:"e-diagram-text-edit"}),S.style.fontWeight=g.bold?"bold":"",S.style.fontStyle=g.italic?"italic":"",S.style.lineHeight=(1.2*g.fontSize+"px;").toString(),S.style.textDecoration=g.textDecoration?g.textDecoration:"",this.activeLabel.parentId=e.id,this.activeLabel.id=i,u.visible=!1,this.updateDiagramObject(e),this.diagramActions=this.diagramActions|ee.TextEdit,this.isTriggerEvent||(E.add(S,"input",this.eventHandler.inputChange,this.eventHandler),E.add(S,"focusout",this.focusOutEdit,this),S.select())}}}},t.prototype.updateConnectorfixedUserHandles=function(e){if(e.fixedUserHandles.length)for(var i=void 0,r=0,s=e.fixedUserHandles;r0&&this.mindMapChartModule.updateLayout(o,this.nameTable,this.layout,l,this.dataSourceSettings.id,this.dataSourceSettings.root),e=!0;else if(this.radialTreeModule)this.radialTreeModule.updateLayout(o,this.nameTable,this.layout,l),e=!0;else if(this.symmetricalLayoutModule)this.symmetricalLayoutModule.maxIteration=this.layout.maxIteration,this.symmetricalLayoutModule.springLength=this.layout.springLength,this.symmetricalLayoutModule.springFactor=this.layout.springFactor,this.symmetricalLayoutModule.updateLayout(o,this.connectors,this.symmetricalLayoutModule,this.nameTable,this.layout,l),e=!0;else if(this.complexHierarchicalTreeModule){this.canDistribute(a,r)&&(this.lineDistributionModule.diagram=this,this.connectors.forEach(function(P){P.obstaclePointCollection=[]}));var c=this.complexHierarchicalTreeModule.getLayoutNodesCollection(this.nodes);c.length>0&&this.complexHierarchicalTreeModule.doLayout(c,this.nameTable,this.layout,l,this),e=!0,this.canDistribute(a,r)&&this.lineDistributionModule.initLineDistribution(this.layout,this)}else this.flowchartLayoutModule?(this.flowchartLayoutModule.updateLayout(this.nodes,this),e=!0):console.warn("[WARNING] :: Module "+("OrganizationalChart"===this.layout.type?"HierarchicalTree":this.layout.type)+" is not available in Diagram component! You either misspelled the module name or forgot to load it.");if(e){this.preventDiagramUpdate=!0;for(var u={},p=0,g=o;p0)for(var S=0;S0)for(var M=0;M0)for(var s=0,o=r.ports;s0&&function Rse(n){var t,e,i,r=[];for(t=0;t0&&y.connectors[w].bezierSettings&&y.connectors[w].bezierSettings.allowSegmentsReset&&(y.connectors[w].segments=[]);if(t.connectors=y.connectors||[],t.dataSourceSettings=y.dataSourceSettings||{},t.dataSourceSettings.doBinding=i,t.height=y.height||"100%",t.setNodeTemplate=r,t.getConnectorDefaults=v,t.getNodeDefaults=g,t.getCustomProperty=o,t.mode=y.mode||"SVG",y.nodes)for(w=0;w0)){var r=this.nodes.filter(function(a){return 0===a.inEdges.length})[0],s=this.convertMindmapToMermaid(r,0);i.push(s),this.updateTextDataSource(i,r.outEdges,1),e=(i=i.filter(function(a){return""!==a.trim()})).join("\n")}return e},t.prototype.updateTextDataSource=function(e,i,r){for(var s=0;s0&&this.updateTextDataSource(e,h,r+1),s++}},t.prototype.convertMindmapToMermaid=function(e,i){var r=e.id,o=" ".repeat(2*(i+1)),a=e.annotations.length>0?e.annotations[0].content.replace(/\n/g," "):"",l=o+a,h=o+r;if(e.shape&&"Basic"===e.shape.type){var c=e.shape;"Rectangle"===c.shape?l=h+"["+a+"]":"Ellipse"===c.shape?l=h+"(("+a+"))":"Hexagon"===c.shape&&(l=h+"{{"+a+"}}")}else if(e.shape&&"Flow"===e.shape.type)"Terminator"===e.shape.shape&&(l=h+"("+a+")");else if(e.shape&&"Path"===e.shape.type){var u=e.shape;u.data===this.bangShape?l=h+"))"+a+"((":u.data===this.cloudShape&&(l=h+")"+a+"(")}return l},t.prototype.saveFlowDiagramInMermaidFormat=function(){var e=this,i=[],r="graph TD\n",s={nodes:this.nodes,edges:this.connectors};return s.nodes.reduce(function(a,l){return a[l.id]=l.annotations.length?l.annotations[0].content:"",a},{}),s.edges.forEach(function(a){var l=a.sourceID,h=a.targetID,f=e.nameTable[""+h],p=e.getNodeShape(e.nameTable[""+l]),g=e.getNodeShape(f),v=a.annotations[0]&&""!==a.annotations[0].content?"|"+a.annotations[0].content+"|":"";-1===i.indexOf(l)?i.push(l):p="",-1===i.indexOf(h)?i.push(h):g="";var y=e.arrowType(a);r+=" "+l+p+" "+y+v+" "+h+g+"\n"}),s.nodes.forEach(function(a){r+=" style "+a.id+" fill:"+a.style.fill+",stroke:"+a.style.strokeColor+",stroke-width:"+a.style.strokeWidth+"px;\n"}),r},t.prototype.arrowType=function(e){var i=e.targetDecorator.shape;return e.style.opacity<1?"~~~":""!==e.style.strokeDashArray?"-.->":"Arrow"===i?e.style.strokeWidth>1?"==>":"--\x3e":"None"===i?"---":"--\x3e"},t.prototype.getNodeShape=function(e){var i=e.annotations.length>0?e.annotations[0].content:"",r=e.shape.shape;if(!r){var s=e.shape.data;return"M 0 0 A 1 1 0 0 0 7 0 A 1 1 0 0 0 0 0 M -1 0 A 1 1 0 0 0 8 0 A 1 1 0 0 0 -1 0"===s?"((("+i+")))":"M 0 0 L 1 -1 L 5 -1 L 6 0 L 0 0"===s?"[/"+i+"\\]":"M 0 1 L 0 6 C 2 7 4 7 6 6 L 6 1 C 5 0 1 0 0 1 C 1 2 5 2 6 1"===s?"[("+i+")]":"M 0 0 L 12 0 L 14 2 L 2 2 L 0 0"===s?"[\\"+i+"\\]":"M 0 0 L 5 0 L 4 1 L 1 1 L 0 0"===s?"[\\"+i+"/]":"M 0 0 L 2 -2 L 11 -2 L 13 0 L 11 2 L 2 2 L 0 0"===s?"{{"+i+"}}":">"+i+"]"}switch(r){case"Terminator":return"(["+i+"])";case"Process":default:return"["+i+"]";case"Decision":return"{"+i+"}";case"Parallelogram":return"[/"+i+"/]";case"Ellipse":return"(("+i+"))";case"PreDefinedProcess":return"[["+i+"]]"}},t.prototype.loadDiagramFromMermaid=function(e){this.layout&&"Flowchart"===this.layout.type&&this.flowchartLayoutModule?this.convertMermaidToFlowChart(e):this.layout&&"MindMap"===this.layout.type&&this.mindMapChartModule?this.convertMermaidToMindmap(e):console.warn('[WARNING] :: Module "FlowchartLayout" or "MindMap" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.countLeadingSpaces=function(e){for(var i=0,r=e.length;i0});this.clear(),this.mermaidNodeBaseCollection=[];var r=[],s={text:"",children:[],currentLevel:0,branch:"Left"},o=[],l=!1,h=!1,c=!1;if(i.length>0){for(var d=function(M){var w=i[parseInt(M.toString(),10)],C=0,D="",A=u.countLeadingSpaces(w),x=w.includes('"`');if(h=w.includes('`"'),c=(l=!!x||l)||c?c:0===A&&M>0,l&&h&&!x)return s.text+="\n"+w,l=!1,"continue";if(!x&&l)return s.text+="\n"+w,"continue";if(l=!h&&l,w.length>0&&(/\s/.test(w[0])&&M>0||0===A)){if(-1!==o.findIndex(function(B){return B.space===A.toString()}))for(var L=o.length-1;L>=0;L--){var O=o[parseInt(L.toString(),10)];if((N=parseFloat(O.space))>A)o.splice(L,1);else{if(N=0;L--){var N,T=o[parseInt(L.toString(),10)];if(!((N=parseFloat(T.space))>A)){var z=o[o.length-1];o.push({space:A.toString(),level:z.level+1});break}o.splice(L,1)}C=o[o.length-1].level}D=w.trim().replace(/^[+-]/,"")}var U={text:D,branch:void 0,children:[],currentLevel:0===M?0:C-1};if(r.length>0){for(;r.length>=C&&0!==r.length;)r.pop();r.length>0&&r[r.length-1].children.push(U)}r.push(U),s=U},u=this,f=0;f0){var c=h[h.length-1];c.arrowType=a[2],""!==a[3]&&(c.label&&c.label.some(function(d){return d.trim().length>0})?c.label.push(a[3]):(c.label=[],c.label[c.parentId.length-1]=a[3]))}h.filter(function(d){return d.parentId&&0===d.parentId.length}).forEach(function(d){d.parentId=null}),i=i.concat(h)}}this.createFlowChart(i),this.doLayout(),this.clearHistory()},t.prototype.createFlowChart=function(e){for(var i=[],r=0;r1)for(var h=0;h|---|--\s*.*?\s*-->|~~~|==>|===|==\s*.*?\s*==>|\s*-\.\s*->|\s*-\.\s*-|\s*-\.\s*.*?\s*\.\s*->|\s*-\..*?\.\s*->)(.*)$/);if(l){i=l[1].trim();var h=l[2].trim();r=l[3].trim();var d=h.match(/(-\.|\\-\\-|==|--|~~)(.*?)(\1>|\.->|==>|\\->|~~>)/),u=void 0,f="";o=null!==(u=d?{text:d[2].trim()||null,arrowType:d[1]+d[3]}:{text:null,arrowType:h}).text?u.text:"",s=(f=u.arrowType).includes("--\x3e")?"single-line-arrow":f.includes("---")?"single-line":f.includes("==>")?"double-line-arrow":f.includes("==")?"double-line":f.includes("~~~")?"wiggly-arrow":f.includes("-.->")||f.includes(".->")?"dotted-arrow":f.includes("-.-")||f.includes(".-")?"dotted":"single-line-arrow"}return[i,r,s,o]},t.prototype.parseStyle=function(e,i){if(e.startsWith("style")){var s=e.match(/^style\s+(\w+)\s+fill:([^,]+),stroke:([^,]+),stroke-width:(\d+)px;/);if(s){var c={id:s[1],fill:s[2],stroke:s[3],strokeWidth:parseInt(s[4],10)},d=i.filter(function(u){return u.id===c.id});d[0].color=c.fill,d[0].stroke=c.stroke,d[0].strokeWidth=c.strokeWidth}}},t.prototype.getNodeData=function(e,i,r){for(var s=[],o=null,a=null,l=0,h="",c=function(v){var y=e[parseInt(v.toString(),10)],S=d.splitNested(y);if(S[0].includes("|")){var b=S[0].match(/\|([^|]*)\|/);b&&(h=b[1]);var M=S[0].split("|");M.length>=3&&(S[0]=M[2].trim())}var w=S[0].trim();if(0===v?o=w:a=w,i.find(function(L){return L.id===w}))l++;else{var D=S.length>1?S[1]:S[0],A=d.getShape(D),x=D.replace(/[\\[\]\\(\\)\\{\\}\\{\\}\\/>]/g,"");s.push({id:w,name:x,shape:A,color:"white",parentId:[]})}},d=this,u=0;u"===h?0===s?(r.trim().length>0&&i.push(r.trim()),r=h,o=h,s++):(r+=h,s++):"]"===h||"}"===h||")"===h?1===s&&h===o?(i.push((r+=h).trim()),r="",s--):s>1?(r+=h,s--):r+=h:r+=h}return r.trim().length>0&&i.push(r.trim()),i},t.prototype.getShape=function(e){var i={};return e.startsWith("(((")?i={type:"Path",data:"M 0 0 A 1 1 0 0 0 7 0 A 1 1 0 0 0 0 0 M -1 0 A 1 1 0 0 0 8 0 A 1 1 0 0 0 -1 0"}:e.startsWith("((")?i={shape:"Ellipse",type:"Basic"}:e.startsWith("([")?i={type:"Flow",shape:"Terminator"}:e.startsWith("(")?i={type:"Flow",shape:"Process"}:e.startsWith("[[")?i={type:"Flow",shape:"PreDefinedProcess"}:e.startsWith("[/")?i=e.endsWith("/]")?{type:"Basic",shape:"Parallelogram"}:{type:"Path",data:"M 0 0 L 1 -1 L 5 -1 L 6 0 L 0 0"}:e.startsWith("[(")?i={type:"Path",data:"M 0 1 L 0 6 C 2 7 4 7 6 6 L 6 1 C 5 0 1 0 0 1 C 1 2 5 2 6 1"}:e.startsWith("[\\")?i=e.endsWith("\\]")?{type:"Path",data:"M 0 0 L 12 0 L 14 2 L 2 2 L 0 0"}:{type:"Path",data:"M 0 0 L 5 0 L 4 1 L 1 1 L 0 0"}:e.startsWith("[")?i={type:"Basic",shape:"Rectangle"}:e.startsWith("{{")?i={type:"Path",data:"M 0 0 L 2 -2 L 11 -2 L 13 0 L 11 2 L 2 2 L 0 0"}:e.startsWith("{")?i={type:"Flow",shape:"Decision"}:e.startsWith(">")&&(i={type:"Path",data:"M 0 0 L 8 0 L 8 2 L 0 2 L 2 1 L 0 0"}),i},t.prototype.getDiagramContent=function(e){return this.printandExportModule?this.printandExportModule.getDiagramContent(e):(console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),"")},t.prototype.exportImage=function(e,i){this.printandExportModule?this.printandExportModule.exportImages(e,i):console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.printImage=function(e,i){this.printandExportModule?(i.printOptions=!0,this.printandExportModule.exportImages(e,i)):console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.setStackLimit=function(e){this.undoRedoModule&&e&&(this.historyManager.stackLimit=e,this.undoRedoModule.applyLimit(this.historyManager.currentEntry,e,this,!0))},t.prototype.clearHistory=function(){this.undoRedoModule&&this.undoRedoModule.clearHistory(this)},t.prototype.getDiagramBounds=function(){if(this.printandExportModule){var e=this.printandExportModule.getDiagramBounds("",{});return e.width=e.width>this.scrollSettings.viewPortWidth?e.width+(e.x>0?e.x:0):this.scrollSettings.viewPortWidth,e.height=e.height>this.scrollSettings.viewPortHeight?e.height+(e.y>0?e.y:0):this.scrollSettings.viewPortHeight,e.x=e.x>0?0:e.x,e.y=e.y>0?0:e.y,e}return console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),new Ne},t.prototype.exportDiagram=function(e){return this.printandExportModule?this.printandExportModule.exportDiagram(e):(console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),"")},t.prototype.print=function(e){this.printandExportModule?this.printandExportModule.print(e):console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.addPorts=function(e,i){var s;this.protectPropertyChange(!0),e=this.nameTable[e.id]||e,i.length>1&&this.startGroupAction();for(var o=function(h){if(e.ports.some(function(y){return y.id===i[parseInt(h.toString(),10)].id}))return"continue";if(e instanceof te?(s=new Es(e,"ports",i[parseInt(h.toString(),10)],!0),e.ports.push(s)):e instanceof de&&(s=new Tc(e,"ports",i[parseInt(h.toString(),10)],!0),e.ports.push(s)),e.children)for(var c=e.wrapper,d=0;d1&&this.endGroupAction(),e.wrapper.measure(new me(e.width,e.height)),e.wrapper.arrange(e.wrapper.desiredSize),this.updateDiagramObject(e),this.protectPropertyChange(!1)},t.prototype.addConstraints=function(e,i){return e|i},t.prototype.removeConstraints=function(e,i){return e&~i},t.prototype.addNodeLabels=function(e,i){this.addLabels(e,i)},t.prototype.addConnectorLabels=function(e,i){this.addLabels(e,i)},t.prototype.addLabels=function(e,i){this.protectPropertyChange(!0);var s,r=(e=this.nameTable[e.id]||e).wrapper;i.length>1&&this.startGroupAction();for(var o=0;o1&&this.endGroupAction(),e.wrapper.measure(new me(r.width,r.height)),e.wrapper.arrange(r.desiredSize),this.updateDiagramObject(e),this.protectPropertyChange(!1),this.refreshCanvasLayers()},t.prototype.addChildToUmlNode=function(e,i,r){var s,o,a,l,h="NoWrap";"Class"===e.shape.classifier||"Interface"===e.shape.classifier?"Method"===r?(o=new dm(e,"",i),"Class"===e.shape.classifier?(e.shape.classShape.methods.push(o),s=e.shape.classShape):"Interface"===e.shape.classifier&&(e.shape.interfaceShape.methods.push(o),s=e.shape.interfaceShape),function soe(n,t,e,i){if(e.methods&&e.methods.length){var r=e.methods,s="",o="",a=void 0,l=1,h=void 0,c=0,d=0,u=n.shape,g="Class"===u.classifier?u.classShape:u.interfaceShape;1===r.length?g.attributes.length>0?(c=g.attributes.filter(function(w){return w.isSeparator}).length,h=(l=2+g.attributes.length+c)+1,aT(n,t,l)):h=l+1:(c=g.attributes.filter(function(w){return w.isSeparator}).length,d=g.methods.filter(function(w){return w.isSeparator}).length,h=(l=2+g.attributes.length+c+g.methods.length+d)+1);for(var v=0;v1&&this.startGroupAction();for(var r=i.length-1;r>=0;r--)if(e.children&&e.children.length>0){var s=e.wrapper.children.filter(function(o){return o.id===e.id+"group_container"});s&&s.length>0&&this.removelabelExtension(e,i,r,s[0])}else this.removelabelExtension(e,i,r,e.wrapper);i.length>1&&this.endGroupAction(),this.refreshCanvasLayers()},t.prototype.removePortsExtenion=function(e,i,r,s){for(var o=0;o1&&this.startGroupAction();for(var r=i.length-1;r>=0;r--)if(e.children&&e.children.length>0)for(var s=0;s1&&this.endGroupAction()},t.prototype.getSizeValue=function(e,i){var r;return r=e.toString().indexOf("px")>0?e.toString():e.toString().indexOf("%")>0?void 0!==i?"100%":e.toString():e.toString()+"px",i&&(Za(this),r="calc("+r+" - "+i+"px)"),r},t.prototype.renderRulers=function(){this.rulerSettings.showRulers?(function ise(n){var t=Za(n),i=Tt("div",{id:n.element.id+"_overlapRuler",style:"height:"+t.height+"px;width:"+t.width+"px;position:absolute;left:0;top:0",class:"e-ruler-overlap"});n.element.insertBefore(i,n.element.firstChild)}(this),oF(this,!0),oF(this,!1)):qx(this)},t.prototype.intOffPageBackground=function(){var e=new me;e=Za(this);var i=document.getElementById(this.element.id+"content"),r=this.getSizeValue(this.width,e.width),s=this.getSizeValue(this.height,e.height),o=this.rulerSettings.showRulers?"width:"+r+"; height:"+s+";top:"+e.height+"px;left:"+e.width+"px;overflow: scroll;position:absolute;overflow:auto;":"width:"+r+"; height:"+s+";position:absolute; left:0px; top:0px;overflow: auto;",a={id:this.element.id+"content",tabindex:"0",style:o};i?(this.diagramCanvas=i,Ka(this.diagramCanvas,o)):(this.diagramCanvas=Tt("div",a),this.element.appendChild(this.diagramCanvas)),this.diagramCanvas.style.background=this.backgroundColor},t.prototype.initDiagram=function(){this.intOffPageBackground(),Ho(this.element,{style:"width:"+this.getSizeValue(this.width)+"; height:"+this.getSizeValue(this.height)+";position:relative;overflow:hidden;"})},t.prototype.renderHiddenUserHandleTemplateLayer=function(e){var r=Tt("div",{class:this.element.id+"_hiddenUserHandleTemplate",style:"width:"+e.width+"px; height:"+e.height+"px;visibility:hidden ; overflow: hidden;"});this.element.appendChild(r)},t.prototype.renderBackgroundLayer=function(e,i){var r=this.createSvg(this.element.id+"_backgroundLayer_svg",e.width,e.height);Ka(r,i);var s=Fi("g",{id:this.element.id+"_backgroundImageLayer",class:"e-background-image-layer"});r.appendChild(s);var a=Fi("g",{id:this.element.id+"_backgroundLayer",class:"e-background-layer"});r.appendChild(a),this.diagramCanvas.appendChild(r)},t.prototype.renderGridLayer=function(e,i){var r=this.createSvg(this.element.id+"_gridline_svg",e.width,e.height);r.setAttribute("class","e-grid-layer");var s=Fi("g",{id:this.element.id+"_gridline"}),o=Fi("rect",{id:this.element.id+"_grid_rect",x:"0",y:"0",width:"100%",height:"100%"});if(om()){var a=new URL(window.location.href);o.setAttribute("fill",""!==a.search?"url(#"+this.element.id+"_pattern)":"url("+location.protocol+"//"+location.host+location.pathname+"#"+this.element.id+"_pattern)")}else o.setAttribute("fill","url(#"+this.element.id+"_pattern)");s.appendChild(o),r.appendChild(s),this.diagramCanvas.appendChild(r),ti(r,{style:i})},t.prototype.renderDiagramLayer=function(e,i){if(this.diagramLayerDiv=Tt("div",{id:this.element.id+"_diagramLayer_div",style:"width:"+e.width+"px; height:"+e.height+"px;"+i}),"SVG"===this.mode){var s=this.createSvg(this.element.id+"_diagramLayer_svg",e.width,e.height);s.style["pointer-events"]="none",s.setAttribute("class","e-diagram-layer");var o=Fi("g",{id:this.element.id+"_diagramLayer"}),a=Fi("g",{});this.diagramLayer=o,s.style["pointer-events"]="all",a.appendChild(o),s.appendChild(a),this.diagramLayerDiv.appendChild(s)}else this.diagramLayer=bo.createCanvas(this.element.id+"_diagram",e.width,e.height),Ka(this.diagramLayer,"position:absolute;left:0px;top:0px;"),this.diagramLayerDiv.appendChild(this.diagramLayer);this.diagramCanvas.appendChild(this.diagramLayerDiv)},t.prototype.initLayers=function(){var e="position:absolute;top:0px;left:0px;overflow:hidden;pointer-events:none;",r=document.getElementById(this.element.id).getBoundingClientRect(),s=function Loe(){var n=Tt("div",{style:"visibility:hidden; width: 100px"});document.body.appendChild(n);var t=n.getBoundingClientRect().width;n.style.overflow="scroll";var e=Tt("div",{style:"width:100%"});n.appendChild(e);var i=e.getBoundingClientRect().width;return n.parentNode.removeChild(n),t-i}();this.scroller.scrollerWidth=s,this.scroller.setViewPortSize(r.width,r.height),this.renderRulers();var o="measureElement";window[""+o]&&(window[""+o]=null,document.getElementById("measureElement").remove()),function WF(){var n="measureElement";if(window[""+n])window[""+n].usageCount+=1;else{var t=Tt("div",{id:"measureElement",style:"visibility:hidden ; height: 0px ; width: 0px; overflow: hidden;"}),e=Tt("span",{style:"display:inline-block ; line-height: normal"});t.appendChild(e);var i=Tt("img",{alt:"measureElementImage",src:"data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7"});t.appendChild(i);var r=document.createElementNS("http://www.w3.org/2000/svg","svg");r.setAttribute("xmlns:xlink","http://www.w3.org/1999/xlink"),t.appendChild(r);var s=document.createElementNS("http://www.w3.org/2000/svg","path");s.setAttribute("d",""),r.appendChild(s),document.createTextNode("");var a=document.createElementNS("http://www.w3.org/2000/svg","text");a.setAttributeNS("http://www.w3.org/XML/1998/namespace","xml:space","preserve"),r.appendChild(a),window[""+n]=t,window[""+n].usageCount=1,document.body.appendChild(t);var l="measureElementCount";window[""+l]?window[""+l]++:window[""+l]=1}}(),this.renderBackgroundLayer(r,e),this.renderGridLayer(r,e),this.renderDiagramLayer(r,e),this.renderHTMLLayer(r,e),this.renderPortsExpandLayer(r,e),this.renderNativeLayer(r,e),this.renderAdornerLayer(r,e),this.renderHiddenUserHandleTemplateLayer(r)},t.prototype.renderAdornerLayer=function(e,i){var r=Tt("div",{id:this.element.id+"_diagramAdornerLayer",style:"width:"+e.width+"px;height:"+e.height+"px;"+i}),s=Tt("div",{id:this.element.id+"_diagramUserHandleLayer",style:"width:"+e.width+"px;height:"+e.height+"px;"+i});s.setAttribute("class","e-userHandle-layer"),r.appendChild(s);var o=this.createSvg(this.element.id+"_diagramAdorner_svg",e.width,e.height);o.setAttribute("class","e-adorner-layer"),o.style["pointer-events"]="none",this.adornerLayer=Fi("g",{id:this.element.id+"_diagramAdorner"}),this.adornerLayer.style[" pointer-events"]="all",o.appendChild(this.adornerLayer),r.appendChild(o),this.diagramCanvas.appendChild(r);var a=Fi("g",{id:this.element.id+"_SelectorElement"});this.adornerLayer.appendChild(a),ti(o,{style:"pointer-events:none;"})},t.prototype.renderPortsExpandLayer=function(e,i){var r=this.createSvg(this.element.id+"_diagramPorts_svg",e.width,e.height);r.setAttribute("class","e-ports-expand-layer");var s=Fi("g",{id:this.element.id+"_diagramPorts",class:"e-ports-layer",style:"pointer-events: all;"});r.appendChild(s);var o=Fi("g",{id:this.element.id+"_diagramExpander",class:"e-expand-layer",style:"pointer-events: all;"});r.appendChild(o),this.diagramCanvas.appendChild(r),ti(r,{style:i})},t.prototype.renderHTMLLayer=function(e,i){this.htmlLayer=Tt("div",{id:this.element.id+"_htmlLayer",style:"width:"+e.width+"px; height:"+e.height+"px;position:absolute;top:0px;left:0px;overflow:hidden;pointer-events:none;",class:"e-html-layer"});var r=Tt("div",{id:this.element.id+"_htmlLayer_div",style:"position:absolute;top:0px;left:0px;pointer-events:all;"});this.htmlLayer.appendChild(r),this.diagramCanvas.appendChild(this.htmlLayer)},t.prototype.renderNativeLayer=function(e,i){var r=this.createSvg(this.element.id+"_nativeLayer_svg",e.width,e.height),s=Fi("g",{id:this.element.id+"_nativeLayer",style:"pointer-events:all;"});r.appendChild(s),this.diagramLayerDiv.appendChild(r),ti(r,{class:"e-native-layer",style:i})},t.prototype.createSvg=function(e,i,r){var s=document.createElementNS("http://www.w3.org/2000/svg","svg");return ti(s,{id:e,width:i,height:r}),s},t.prototype.updateBazorShape=function(){for(var e=0;e1,i=[],r={},s={},o=[],a=0,l=this.nodes;a0||b&&b.children&&b.children.length>0)&&(M=!1),S&&S.wrapper&&b&&b.wrapper&&M?this.initConnectors(r[""+h],p):i.push(r[""+h])}else b=r[y.targetID],(S=r[y.sourceID])&&S.children&&S.children.length>0||b&&b.children&&b.children.length>0?i.push(r[""+h]):this.initConnectors(r[""+h],p);else r[""+h].children?o.push(h):r[""+h].shape instanceof uT&&r[""+h].shape.activity.subProcess.processes&&r[""+h].shape.activity.subProcess.processes.length>0?s[r[""+h].id]=h:this.initNodes(r[""+h],p);if(this.bpmnModule)for(var w=0,C=this.bpmnModule.bpmnTextAnnotationConnector;w-1&&-1===r.indexOf(c)&&-1===s.indexOf(c)&&r.splice(0,0,c);-1===r.indexOf(o)&&s.push(o)}return r.concat(s)},t.prototype.addToLayer=function(e,i){var r;if(i&&(r=this.commandHandler.getObjectLayer(e.id)),(!i||!r)&&-1===this.activeLayer.objects.indexOf(e.id)&&this.activeLayer.objects.push(e.id),(e instanceof te||e instanceof de)&&("SwimLane"!==e.shape.type||e.children&&e.children.length>0)){if(e.parentId){var s=this.swimlaneZIndexTable[e.parentId],o=this.swimlaneChildTable[e.id];(s&&-1!==s||o&&-1!==o)&&(e.zIndex=this.swimlaneChildTable[e.id])}e instanceof de&&e.sourceID&&e.targetID?-1!==this.activeLayer.objects.indexOf(e.sourceID)&&-1!==this.activeLayer.objects.indexOf(e.targetID)&&this.setZIndex(r||this.activeLayer,e):this.setZIndex(r||this.activeLayer,e)}},t.prototype.updateLayer=function(e){for(var i=0,r=Object.keys(e.layers);i0)for(r=0;rs;l--)r.zIndexTable[parseInt(l.toString(),10)]=r.zIndexTable[l-1],this.nameTable[r.zIndexTable[parseInt(l.toString(),10)]]&&(this.nameTable[r.zIndexTable[parseInt(l.toString(),10)]].zIndex=l);r.zIndexTable[parseInt(a.toString(),10)]=i.id}}},t.prototype.initializeDiagramLayers=function(){for(var e=0;ethis.layers[parseInt(a.toString(),10)].zIndex&&(i=this.layers[parseInt(e.toString(),10)],this.layers[parseInt(e.toString(),10)]=this.layers[parseInt(a.toString(),10)],this.layers[parseInt(a.toString(),10)]=i);0===this.layers.length&&this.commandHandler.addLayer({id:"default_layer",visible:!0,lock:!1,objects:[],zIndex:0,objectZIndex:-1,zIndexTable:{}},null,!0),this.setActiveLayer(this.layers[this.layers.length-1].id)},t.prototype.resetTool=function(){this.eventHandler.resetTool()},t.prototype.initObjectExtend=function(e,i,r){if(r){var s=this.commandHandler.checkBoundaryConstraints(void 0,void 0,e.wrapper.bounds,!0);if("SwimLane"===e.shape.type)for(var o=0,a=Object.keys(i.zIndexTable);o0)&&this.setZIndex(i,e)),e instanceof te){if(r){if("helper"!==e.id&&(o=Zi(this.getNodeDefaults))){if((a=o(e,this))&&a.ports)for(var l=0;l0)for(l=0;l0&&!e.container||e.processId){var r=this.nameTable[e.id];if(!(this.realActions&$i.PreventScale||this.realActions&$i.PreventDrag)){if(r.offsetX&&(this.realActions&$i.EnableGroupAction||!(this.diagramActions&ee.UndoRedo||this.diagramActions&ee.ToolAction||this.diagramActions&ee.PublicMethod))){this.realActions|=$i.PreventScale;var s=r.offsetX-e.wrapper.offsetX;r.offsetX=e.wrapper.offsetX;var o=r.offsetY-e.wrapper.offsetY;r.offsetY=e.wrapper.offsetY,s+o!==0&&this.drag(r,s,o),this.realActions&=~$i.PreventScale}else r.offsetX=e.wrapper.offsetX;r.offsetY&&(this.realActions&$i.EnableGroupAction||!(this.diagramActions&ee.UndoRedo||this.diagramActions&ee.ToolAction||this.diagramActions&ee.PublicMethod))?(this.realActions|=$i.PreventScale,o=r.offsetY-e.wrapper.offsetY,r.offsetY=e.wrapper.offsetY,this.drag(r,0,o),this.realActions&=~$i.PreventScale):r.offsetY=e.wrapper.offsetY,this.diagramActions&&(r.width=e.wrapper.actualSize.width,r.height=e.wrapper.actualSize.height)}}i&&e.children&&e.children.length>0&&(void 0!==this.nameTable[e.id].width?this.scaleObject(e,this.nameTable[e.id].width,!0):this.nameTable[e.id].width=e.wrapper.actualSize.width,void 0!==this.nameTable[e.id].height?this.scaleObject(e,this.nameTable[e.id].height,!1):this.nameTable[e.id].height=e.wrapper.actualSize.height)},t.prototype.initNode=function(e,i,r){var a,f,s=e.initContainer(),o=new Mi;if(this.diagramSettings.inversedAlignment||(s.inversedAlignment=!1),s.children||(s.children=[]),e.children){s.measureChildren=!1,o.id=e.id+"group_container",o.style.fill=e.shape&&"SwimLane"===e.shape.type?e.style.fill:"none",o.style.strokeColor="none",o.horizontalAlignment="Stretch",o.verticalAlignment="Stretch",o.pivot=e.pivot,s.style=e.style,s.padding.left=e.padding.left,s.padding.right=e.padding.right,s.padding.top=e.padding.top,s.padding.bottom=e.padding.bottom,o.children=[],o.preventContainer=!0,e.container&&(o.relativeMode="Object");var l=!!(e.ports&&e.ports.length>0);if(m(e.container)&&!l&&s.children.push(o),e.container&&"Grid"===e.container.type)for(var h=0;h0&&e.wrapper.children[0]instanceof Yv){if(this.setZIndex(this.activeLayer,e),this.connectors.length>0)for(h=0;h0?i.phases.length:0,v="Horizontal"===i.orientation,y=v?i.phases.length||1:s.length+1,S=v?(i.header&&i.hasHeader?1:0)+(i.phases.length>0?1:0)+i.lanes.length:(i.header&&i.hasHeader?1:0)+i.phases.length;if(0===h&&!v&&i.lanes.length&&(S+=1),v?(a=(i.header&&i.hasHeader?1:0)+(h>0?1:0),l=0):(a=i.header&&i.hasHeader?1:0,l=h>0?1:0),s.length>0)for(o+=i.header&&i.hasHeader?i.header.height:0,f=0;fl?d.margin.left=d.margin.left-(u.bounds.left-e.bounds.left):u.children[0].children[1].actualSize.width+r>=d.margin.left&&(d.margin.left=u.children[0].children[1].actualSize.width+r),d.margin.lefta?d.margin.top=d.margin.top-(u.bounds.top-o):u.children[0].children[1].actualSize.height+r>=d.margin.top&&(d.margin.top=u.children[0].children[1].actualSize.height+r),d.margin.left0)for(o=0;o0&&this.updateChildPosition(e)},t.prototype.addBpmnAnnotationConnector=function(e,i){if(e.parentObj instanceof t||e.parentObj instanceof Hd){var r=e.shape,o=""!==r.textAnnotation.textAnnotationTarget&&this.nameTable[r.textAnnotation.textAnnotationTarget],a=o?this.nameTable[r.textAnnotation.textAnnotationTarget]:null,l=null!=a?a.wrapper:null,h=e.ports[0],c={x:0,y:0};switch(r.textAnnotation.textAnnotationDirection){case"Left":h.offset={x:0,y:.5},c.x=i.bounds.left-40,c.y=i.bounds.bottom+30;break;case"Right":h.offset={x:1,y:.5},c.x=i.bounds.right+40,c.y=i.bounds.bottom+30;break;case"Top":h.offset={x:.5,y:0},c.x=i.bounds.right+30,c.y=i.bounds.top-40;break;case"Bottom":h.offset={x:.5,y:1},c.x=i.bounds.right+30,c.y=i.bounds.bottom+40;break;default:h.offset={x:0,y:.5},c.x=i.bounds.left-40,c.y=i.bounds.bottom+30,o&&null!=i&&null!=l&&(i.bounds.left>l.bounds.right?h.offset={x:0,y:.5}:i.bounds.rightl.bounds.top?h.offset={x:.5,y:0}:i.bounds.top0&&this.updateChildPosition(r)}},t.prototype.canExecute=function(){return!0},t.prototype.updateStackProperty=function(e,i,r){e.container&&"Stack"===e.container.type&&(i.width||(i.wrapper.horizontalAlignment="Stretch",i.horizontalAlignment="Stretch"),i.height||(i.verticalAlignment="Stretch",i.wrapper.verticalAlignment="Stretch"),r&&"UmlClassifier"===e.shape.type&&(i.umlIndex=r))},t.prototype.initViews=function(){this.isLoading||(this.views.push(this.element.id),this.views[this.element.id]=this)},t.prototype.initCommands=function(){var e=this.commandManager.commands,i={copy:{execute:this.copyCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.C,keyModifiers:ft.Control}},paste:{execute:this.pasteCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.V,keyModifiers:ft.Control}},cut:{execute:this.cutCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.X,keyModifiers:ft.Control}},delete:{execute:this.removeCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Delete}},selectAll:{execute:this.selectAll.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.A,keyModifiers:ft.Control}},undo:{execute:this.undo.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Z,keyModifiers:ft.Control}},redo:{execute:this.redo.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Y,keyModifiers:ft.Control}},nudgeUp:{execute:this.nudgeCommand.bind(this,"Up"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Up},parameter:"up"},nudgeRight:{execute:this.nudgeCommand.bind(this,"Right"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Right},parameter:"right"},nudgeDown:{execute:this.nudgeCommand.bind(this,"Down"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Down},parameter:"down"},nudgeLeft:{execute:this.nudgeCommand.bind(this,"Left"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Left},parameter:"left"},startEdit:{execute:this.startEditCommad.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.F2}},endEdit:{execute:this.endEditCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Escape}},focusToNextItem:{execute:this.navigateItems.bind(this,!0),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Tab}},focusToPreviousItem:{execute:this.navigateItems.bind(this,!1),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Tab,keyModifiers:ft.Shift}},selectFocusedItem:{execute:this.startEditCommad.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Enter}},bold:{execute:this.fontStyleCommand.bind(this,"bold"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.B,keyModifiers:ft.Control}},italic:{execute:this.fontStyleCommand.bind(this,"italic"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.I,keyModifiers:ft.Control}},underline:{execute:this.fontStyleCommand.bind(this,"underline"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.U,keyModifiers:ft.Control}},duplicate:{execute:this.duplicateCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.D,keyModifiers:ft.Control}},group:{execute:this.groupCommand.bind(this,"group"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.G,keyModifiers:ft.Control}},ungroup:{execute:this.groupCommand.bind(this,"ungroup"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.U,keyModifiers:ft.Control|ft.Shift}},rotateClockwise:{execute:this.rotateCommand.bind(this,"clockwise"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.R,keyModifiers:ft.Control}},rotateAntiClockwise:{execute:this.rotateCommand.bind(this,"antiClockwise"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.L,keyModifiers:ft.Control}},flipHorizontal:{execute:this.flipCommand.bind(this,"horizontal"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.H,keyModifiers:ft.Control}},flipVertical:{execute:this.flipCommand.bind(this,"vertical"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.J,keyModifiers:ft.Control}},pointerTool:{execute:this.toolCommand.bind(this,"pointer"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number1,keyModifiers:ft.Control}},textTool:{execute:this.toolCommand.bind(this,"text"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number2,keyModifiers:ft.Control}},connectTool:{execute:this.toolCommand.bind(this,"connect"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number3,keyModifiers:ft.Control}},freeForm:{execute:this.toolCommand.bind(this,"freeForm"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number5,keyModifiers:ft.Control}},lineTool:{execute:this.toolCommand.bind(this,"line"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number6,keyModifiers:ft.Control}},rectangleTool:{execute:this.toolCommand.bind(this,"rectangle"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number8,keyModifiers:ft.Control}},ellipseTool:{execute:this.toolCommand.bind(this,"ellipse"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number9,keyModifiers:ft.Control}},zoomIn:{execute:this.zoomCommand.bind(this,"zoomIn"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Plus,keyModifiers:ft.Control}},zoomOut:{execute:this.zoomCommand.bind(this,"zoomOut"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Minus,keyModifiers:ft.Control}},shiftUp:{execute:this.shiftCommand.bind(this,"Up"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Up,keyModifiers:ft.Shift}},shiftDown:{execute:this.shiftCommand.bind(this,"Down"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Down,keyModifiers:ft.Shift}},shiftLeft:{execute:this.shiftCommand.bind(this,"Left"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Left,keyModifiers:ft.Shift}},shiftRight:{execute:this.shiftCommand.bind(this,"Right"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Right,keyModifiers:ft.Shift}},alignTextCenter:{execute:this.alignCommand.bind(this,"center"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.C,keyModifiers:ft.Control|ft.Shift}},alignTextLeft:{execute:this.alignCommand.bind(this,"right"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.L,keyModifiers:ft.Control|ft.Shift}},alignTextRight:{execute:this.alignCommand.bind(this,"left"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.R,keyModifiers:ft.Control|ft.Shift}},alignTextTop:{execute:this.alignCommand.bind(this,"top"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.E,keyModifiers:ft.Control|ft.Shift}},alignTextCenterVertical:{execute:this.alignCommand.bind(this,"centerVertical"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.M,keyModifiers:ft.Control|ft.Shift}},alignTextBottom:{execute:this.alignCommand.bind(this,"bottom"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.V,keyModifiers:ft.Control|ft.Shift}},alignJustify:{execute:this.alignCommand.bind(this,"justify"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.J,keyModifiers:ft.Control|ft.Shift}},sendToBack:{execute:this.orderCommand.bind(this,"sendToBack"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.B,keyModifiers:ft.Control|ft.Shift}},bringToFront:{execute:this.orderCommand.bind(this,"bringToFront"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.F,keyModifiers:ft.Control|ft.Shift}},sendBackward:{execute:this.orderCommand.bind(this,"sendBackward"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.BracketLeft,keyModifiers:ft.Control}},bringForward:{execute:this.orderCommand.bind(this,"bringForward"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.BracketRight,keyModifiers:ft.Control}}};this.initCommandManager(e,i)},t.prototype.overrideCommands=function(e,i){for(var r,s=0,o=Object.keys(i);se.zIndex){("HTML"===e.shape.type||"Native"===e.shape.type)&&(o="HTML"===e.shape.type?"html":"native"),s=Eoe(i,r[parseInt(a.toString(),10)].id,o);break}return s},t.prototype.updateDiagramObject=function(e,i,r){for(var s,o="domTable",a=0,l=this.views;a1&&(d=this.commandHandler.getObjectLayer(e.id)),void 0===d||d&&d.visible||r){var u=Io(this.element.id);window[""+o][s.element.id+"_diagramLayer"]||(window[""+o][s.element.id+"_diagramLayer"]=document.getElementById(s.element.id+"_diagramLayer"));var f=window[""+o][s.element.id+"_diagramLayer"];this.diagramActions&ee.Interactions&&this.updateCanupdateStyle(e.wrapper.children,!0);var p=this.getMidPoint(e);this.diagramRenderer.updateNode(e.wrapper,f,u,void 0,i?void 0:this.getZindexPosition(e,s.element.id),p,this.portCenterPoint),this.updateCanupdateStyle(e.wrapper.children,!0)}}},t.prototype.applyMarginBezier=function(e,i){i.cx=i.cx+e.margin.left,i.cx=i.cx-e.margin.right,i.cy=i.cy+e.margin.top,i.cy=i.cy-e.margin.bottom},t.prototype.getMidPoint=function(e){var i;if(e instanceof de&&"Bezier"===e.type){i=[];for(var r=this.getBezierPoints(e),s=R.getLengthFromListOfPoints(r),o=0;o0&&e.updateView(e));var s=Io(e.element.id);this.renderDiagramElements(e.diagramLayer,e.diagramRenderer,s,void 0,void 0,i);for(var o=0;o0&&this.renderBasicElement(e),!this.diagramActions||!(this.diagramActions&ee.Render)||ee.ToolAction&this.diagramActions||Ds(this)||1!==this.scroller.currentZoom?this.refreshElements(e):this.renderTimer||(this.renderTimer=setTimeout(function(){i.refreshElements(e)},40)))},t.prototype.updatePortVisibility=function(e,i,r){var s;if((e instanceof te||e instanceof de)&&(!this.drawingObject||!this.drawingObject.shape)&&ro(e)){for(var a=e.ports,l=!1,h=0;h=0&&this.scroller.removeCollection.splice(l,1);var h=this.nameTable[e[parseInt(a.toString(),10)]];this.updateTextElementValue(h),this.diagramRenderer.renderElement(h.wrapper,s,o,void 0,void 0,void 0,void 0,h.zIndex)}for(var c=0;c0?this.scroller.oldCollectionObjects:void 0,b=Object.keys(S||g.zIndexTable);b.sort(function(N,T){return parseInt(""+N,10)-parseInt(""+T,10)});for(var M=0,w=b;M0?h:0)+"px",y=(this.realActions&$i.vScrollbarMoved?0:-(this.scroller.verticalOffset<0?this.scroller.verticalOffset:0))+"px"):(v="0px",y="0px"),this.realActions&$i.hScrollbarMoved&&(this.realActions=this.realActions&~$i.hScrollbarMoved),this.realActions&$i.vScrollbarMoved&&(this.realActions=this.realActions&~$i.vScrollbarMoved)):(v=(l.x<0?h:-this.scroller.horizontalOffset)+"px",y=(l.y<0?c:-this.scroller.verticalOffset)+"px"),this.diagramLayer.style.left=v,this.diagramLayer.style.top=y,A.tx=-l.x/A.scale,A.ty=-l.y/A.scale);var P=!0;if(o&&(P=!1),this.updateTextElementValue(D),this.refreshing&&D.shape.activity&&D.shape.activity.subProcess&&D.shape.activity.subProcess.processes){for(var L=0;L0){var o=s.children[0],a=o.data;(r.isBezierEditing&&this.selectedItems.connectors[0].id===r.id||"Bezier"!==r.type)&&r.getSegmentElement(r,o,"ComplexHierarchicalTree"===this.layout.type||"HierarchicalTree"===this.layout.type?this.layout.orientation:void 0,void 0,!1),o.data!==a&&(s.measure(new me),s.arrange(s.desiredSize),"SVG"===this.mode&&!e&&this.updateDiagramObject(r))}}else this.constraints&nt.Bridging&&console.warn('[WARNING] :: Module "ConnectorBridging" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.setCursor=function(e){this.diagramRenderer.setCursor(this.diagramCanvas,e)},t.prototype.clearCanvas=function(e){var i=e.contentWidth||e.diagramLayer.width/this.scroller.currentZoom,r=e.contentHeight||e.diagramLayer.height/this.scroller.currentZoom;"SVG"!==e.mode&&bo.getContext(e.diagramLayer).clearRect(0,0,i,r)},t.prototype.updateScrollOffset=function(){this.scroller.setScrollOffset(this.diagramCanvas.scrollLeft,this.diagramCanvas.scrollTop),eb(this),Ds(this)&&this.scroller.virtualizeElements()},t.prototype.setOffset=function(e,i){var r="domTable";window[""+r][this.element.id+"content"]||(window[""+r][this.element.id+"content"]=document.getElementById(this.element.id+"content"));var s=window[""+r][this.element.id+"content"];s&&(s.scrollLeft=e,s.scrollTop=i)},t.prototype.setSize=function(e,i){if(this.diagramLayer&&!this.preventDiagramUpdate){var r=Za(this);e-=r.width,i-=r.height;var s=this.spatialSearch.getPageBounds();s.x*=this.scroller.currentZoom,s.y*=this.scroller.currentZoom,s.width*=this.scroller.currentZoom,s.height*=this.scroller.currentZoom;var o="SVG"===this.mode?1:1.5,a="SVG"===this.mode?mT(this.element.id):this.diagramLayer,h="Canvas"===this.mode&&this.constraints&nt.Virtualization?this.scroller.viewPortHeight:i;a.setAttribute("width",(o*("Canvas"===this.mode&&this.constraints&nt.Virtualization?this.scroller.viewPortWidth:e)).toString()),a.setAttribute("height",(o*h).toString());var c=document.getElementById(this.element.id+"_diagramUserHandleLayer");c&&(c.style.width=e+"px",c.style.height=i+"px");var d={width:e.toString(),height:i.toString()};this.diagramLayerDiv.style.width=e+"px",this.diagramLayerDiv.style.height=i+"px",ti(FF(this.element.id),d),ti(function xoe(n){return xt(n).getElementsByClassName("e-ports-expand-layer")[0]}(this.element.id),d);var u=Fl(this.element.id);ti(u,d),u.parentNode.style.width=e+"px",u.parentNode.style.height=i+"px";var f=Fd(this.element.id);ti(f,d),this.diagramRenderer.updateGrid(this.snapSettings,f,this.scroller.transform,this.rulerSettings,this.hRuler,this.vRuler),ti(IT(this.element.id),d),this.htmlLayer.style.width=e+"px",this.htmlLayer.style.height=i+"px","SVG"!==this.mode&&!Ds(this)&&this.refreshDiagramLayer(),"SVG"===this.mode&&Ds(this)&&this.scroller.virtualizeElements()}},t.prototype.transformLayers=function(){var e=this.spatialSearch.getPageBounds();e.x*=this.scroller.currentZoom,e.y*=this.scroller.currentZoom,e.width*=this.scroller.currentZoom,e.height*=this.scroller.currentZoom,this.diagramRenderer.updateGrid(this.snapSettings,Fd(this.element.id),this.scroller.transform,this.rulerSettings,this.hRuler,this.vRuler),this.diagramRenderer.transformLayers(this.scroller.transform,"SVG"===this.mode),this.diagramActions&ee.DragUsingMouse||this.updateSelector(),this.renderPageBreaks(e)},t.prototype.removePageBreaks=function(){if(this.diagramLayer){var e=_F(this.element.id);if(e&&e.childNodes)for(var i=e.childNodes.length,r=0;rthis.pageSettings.height&&(e=this.pageSettings.height,this.pageSettings.height=this.pageSettings.width,this.pageSettings.width=e):this.pageSettings.height>this.pageSettings.width&&(e=this.pageSettings.width,this.pageSettings.width=this.pageSettings.height,this.pageSettings.height=e)},t.prototype.setOverview=function(e,i){if(e)e&&(this.views.push(e.id),this.views[e.id]=e,e.renderDocument(e),e.diagramRenderer.setLayers(),e.updateView(e),this.renderNodes(e));else{for(var r=0;r1&&this.updateSelectionRectangle(),this.isProtectedOnChange=s},t.prototype.updateSelectionRectangle=function(){for(var e=um(this.element.id),i=!1,r=0;r1&&this.updateSelectionRectangle(),this.enableServerDataBinding(e)},t.prototype.renderSelectorForAnnotation=function(e,i){this.diagramRenderer.renderResizeHandle(e.wrapper.children[0],i,e.thumbsConstraints,this.scroller.currentZoom,e.constraints,this.scroller.transform,void 0,ro(e.annotation),void 0,void 0,e.handleSize)},t.prototype.drawSelectionRectangle=function(e,i,r,s){this.clearSelectorLayer(),this.diagramRenderer.drawSelectionRectangle(e,i,r,s,this.adornerLayer,this.scroller.transform)},t.prototype.renderHighlighter=function(e){var i=Fl(this.element.id);this.diagramRenderer.renderHighlighter(e,i,this.scroller.transform)},t.prototype.clearHighlighter=function(){var e=Fl(this.element.id),i=e.getElementById(e.id+"_highlighter");i&&i.parentNode.removeChild(i)},t.prototype.getNodesConnectors=function(e){for(var i=0;i0;h--)this.eventHandler&&this.eventHandler.touchArgs&&"touchmove"===this.eventHandler.touchArgs.type?(this.diagramRenderer.touchMove=!0,l&&l===o[h-1].id||(a=o[h-1]).parentNode.removeChild(a)):(a=o[h-1]).parentNode.removeChild(a);if(!ce()){var c=ST(this.element.id).childNodes;for(r=c.length;r>0;r--)c[r-1].parentNode.removeChild(c[r-1])}}},t.prototype.getWrapper=function(e,i){var r;i=e.id+"_"+i;for(var s=e instanceof Mi?e:this.getPortContainer(this.nameTable[e.id]),o=0;o0&&this.applyStyle(e,a=r.annotations)}for(i=0;i0){var a=this.selectedItems.connectors[parseInt(i.toString(),10)].annotations;this.applyStyle(e,a)}},t.prototype.applyStyle=function(e,i){for(var r=0;r0)for(var i=0;i0?r[0].zIndex+(e?1:-1):e?0:this.nodes.length+this.connectors.length-1)<0?i=this.nodes.length+this.connectors.length-1:i===this.nodes.length+this.connectors.length&&(i=0);for(var s=0;s0)for(var s=void 0,o=r.children.length-1;o>=0;o--){var a=r.children[parseInt(o.toString(),10)];i.length>0&&-1!==i.indexOf(a.id.split("_groupElement")[0])&&(r.parentNode.insertBefore(a,s||r),s=a)}r&&r.parentNode.removeChild(r)},t.prototype.deleteGroup=function(e){var r=[];e.children&&(r=this.commandHandler.getChildren(e,[])),this.UpdateBlazorDiagramModelCollection(e);for(var s=0,o=r;s0)for(var xe=0;xe0)if("Path"===t.shape.type&&void 0!==n.shape.data)t.wrapper.children[0].data=n.shape.data;else if("Text"===t.shape.type&&void 0!==n.shape.content)t.wrapper.children[0].content=n.shape.content;else if("Image"===t.shape.type&&void 0!==n.shape.source)t.wrapper.children[0].source=n.shape.source;else if("Native"===t.shape.type){for(var r=void 0,s=0;s-1)&&(this.diagramActions&ee.PreventZIndexOnDragging?this.updateDiagramObject(e,!0):this.updateDiagramObject(e)),!s&&d&&(this.lineRoutingModule&&this.diagramActions&&this.constraints&nt.LineRouting&&"helper"!==e.id?this.diagramActions&ee.ToolAction||this.lineRoutingModule.renderVirtualRegion(this,!0):this.diagramActions&&this.constraints&nt.LineRouting&&"helper"!==e.id&&console.warn('[WARNING] :: Module "LineRouting" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),this.updateConnectorEdges(e),"helper"!==e.id&&!(this.diagramActions&ee.ToolAction))))for(var Sa=this.spatialSearch.findObjects(e.wrapper.outerBounds),Mo=0;Moe?Math.abs(r-e):Math.abs(e-r),d=s>i?Math.abs(s-i):Math.abs(i-s);(0===c&&0===d||Number.isNaN(c)&&Number.isNaN(d))&&o.laneMargin&&(u=o.margin.left-o.laneMargin.left,f=o.margin.top-o.laneMargin.top);var p=o.width,g=o.height,v=new Ne(0,0,0,0);if(0!==p&&0!==g&&(v=new Ne((0!==r?r:o.offsetX)-p/2,(0!==s?s:o.offsetY)-g/2,p,g)),h){var y=l,b=this.selectedItems.nodes?this.selectedItems.nodes[0]:void 0;if(""!==y.textAnnotation.textAnnotationTarget&&this.nameTable[y.textAnnotation.textAnnotationTarget])if(""===o.parentId||b&&b.shape&&"TextAnnotation"===b.shape.shape){if("Auto"===y.textAnnotation.textAnnotationDirection&&a.children[0]instanceof Mi&&a.children[0].children[0]instanceof Ze){var w=a.children[0],C=document.getElementById(w.id+"_groupElement"),D=document.getElementById(w.children[0].id+"_groupElement");C.removeChild(D),w.children.splice(0,1),this.isProtectedOnChange=!0,this.bpmnModule.setAnnotationPath(v,w,o,y,y.textAnnotation.textAnnotationDirection,this),this.isProtectedOnChange=!1}}else this.isPositionUndo=!0,this.updateTextAnnotationInSwimlane(o,o),this.isPositionUndo=!1;else o.inEdges.length>0&&(x=this.nameTable[""+o.inEdges[0]])&&x.isBpmnAnnotationConnector&&(x.sourcePoint={x:r>e?x.sourcePoint.x+c:x.sourcePoint.x-c,y:s>i?x.sourcePoint.y+d:x.sourcePoint.y-d});this.nodePropertyChange(o,{},P={ports:[{offset:o.ports[0].offset}]})}else for(var L=0,O=o.outEdges;Le?T.offsetX+c:T.offsetX-c,T.offsetY=s>i?T.offsetY+d:T.offsetY-d,P={offsetX:T.offsetX,offsetY:T.offsetY}),this.nodePropertyChange(T,z,P)}}}},t.prototype.updatePorts=function(e,i){if(e&&e.ports.length>0)for(var r=0,s=Object.keys(e.ports);r0)for(var i=0;i0)for(var r=0;r0&&void 0===r.segments&&(e.segments=[]),void 0!==r.shape&&void 0!==e.shape&&e.shape&&"Bpmn"===e.shape.type&&this.bpmnModule&&this.bpmnModule.updateBPMNConnector(e,i,r,this),void 0!==e.constraints?(this.updateThumbConstraints(this.selectedItems.connectors,this.selectedItems),s=!0):s},t.prototype.connectorPropertyChange=function(e,i,r,s,o){if(this.canEnableBlazorObject){var a=$(e);this.insertValue(a,!1)}var d,u,f,p,l=e.wrapper.bounds,h=!1,c=[];if(h=this.connectorProprtyChangeExtend(e,i,r,h),void 0!==r.visible&&this.updateElementVisibility(e.wrapper,e,e.visible),void 0!==r.sourcePoint||void 0!==r.targetPoint||void 0!==r.sourceID||void 0!==r.targetID||void 0!==r.targetPadding||void 0!==r.sourcePortID||void 0!==r.targetPortID||void 0!==r.sourcePadding||void 0!==r.type||void 0!==r.segments||void 0!==r.flip){if(void 0!==r.sourceID&&r.sourceID!==i.sourceID||r.sourcePortID){if(u=this.findInOutConnectPorts(g=this.nameTable[e.sourceID],!1),(!g||Rh(g)||""!==e.sourcePortID&&Td(u))&&(e.sourceWrapper=g?this.getEndNodeWrapper(g,e,!0):void 0,e.sourcePortID&&void 0===r.sourcePortID&&(e.sourcePortWrapper=g?this.getWrapper(g.wrapper,e.sourcePortID):void 0),this.removePortEdges(this.nameTable[i.sourceID]||g,i.sourcePortID||e.sourcePortID,e.id,!1)),void 0!==r.sourceID&&void 0!==i.sourceID&&""!==i.sourceID){var v=this.nameTable[i.sourceID];void 0!==v&&v.outEdges&&-1!==v.outEdges.indexOf(e.id)&&rm(v.outEdges,e.id)}this.updateEdges(e)}if(void 0!==r.targetID&&r.targetID!==i.targetID){if(d=this.findInOutConnectPorts(y=this.nameTable[r.targetID],!0),(!y||ua(y)||""!==e.targetPortID&&zh(d))&&(e.targetWrapper=y?this.getEndNodeWrapper(y,e,!1):void 0,e.targetPortID&&void 0===r.targetPortID&&(e.targetPortWrapper=y?this.getWrapper(y.wrapper,e.targetPortID):void 0),this.removePortEdges(this.nameTable[i.targetID]||y,i.targetPortID||e.targetPortID,e.id,!0)),void 0!==i&&void 0!==i.targetID&&""!==i.targetID){var S=this.nameTable[i.targetID];void 0!==S&&S.inEdges&&-1!==S.inEdges.indexOf(e.id)&&rm(S.inEdges,e.id)}this.updateEdges(e)}var g,y;void 0!==r.sourcePortID&&r.sourcePortID!==i.sourcePortID&&(e.sourceID&&this.nameTable[e.sourceID]&&(f=this.nameTable[e.sourceID].wrapper),!(g=this.nameTable[e.sourceID])||Rh(g)||""!==e.sourcePortID&&Td(u)?e.sourcePortWrapper=f?this.getWrapper(f,r.sourcePortID):void 0:""===e.sourcePortID&&!Rh(g)&&(e.sourcePortWrapper=void 0)),void 0!==r.targetPortID&&r.targetPortID!==i.targetPortID&&(e.targetID&&this.nameTable[e.targetID]&&(p=this.nameTable[e.targetID].wrapper),!(y=this.nameTable[e.targetID])||ua(y)||""!==e.targetPortID&&zh(d)?e.targetPortWrapper=p?this.getWrapper(p,r.targetPortID):void 0:""===e.targetPortID&&!ua(y)&&(e.targetPortWrapper=void 0)),void 0!==r.flip&&(e.flip=r.flip,EF(e)),"Orthogonal"===e.type&&this.lineRoutingModule&&this.diagramActions&&this.constraints&nt.LineRouting&&!(this.diagramActions&ee.ToolAction)&&"ComplexHierarchicalTree"!==this.layout.type&&(this.lineRoutingModule.renderVirtualRegion(this,!0),e.sourceID!==e.targetID&&e.segments.length>1&&this.lineRoutingModule.refreshConnectorSegments(this,e,!1)),c=this.getPoints(e)}void 0!==r.style&&Hh(r.style,e.wrapper.children[0]),(c.length>0||void 0!==r.sourceDecorator||void 0!==r.targetDecorator&&function qse(n){return-1!==n.indexOf("shape")||-1!==n.indexOf("pathData")||-1!==n.indexOf("width")||-1!==n.indexOf("height")}(Object.keys(r.targetDecorator))||void 0!==r.cornerRadius)&&(ep(e,c.length>0?c:e.intermediatePoints,this.diagramActions),void 0!==r.type&&(h=!0),c.length>0&&(e.wrapper.measure(new me(e.wrapper.width,e.wrapper.height)),e.wrapper.arrange(e.wrapper.desiredSize),this.updateConnectorAnnotation(e),this.updateConnectorPort(e),this.updateConnectorfixedUserHandles(e),this.updateObject(e,i,r))),(r.sourcePoint||r.targetPoint||r.segments)&&this.diagramActions===ee.Render&&(h=!0),"Bpmn"===e.shape.type&&"Default"===e.shape.sequence&&"Sequence"===e.shape.flow&&this.commandHandler.updatePathElementOffset(e),s||this.updateBridging(),this.updateAnnotations(r,e),this.updateConnectorPorts(r,e),this.updatefixedUserHandle(r,e),e.wrapper.measure(new me(e.wrapper.width,e.wrapper.height)),e.wrapper.arrange(e.wrapper.desiredSize),!1===l.equals(l,e.wrapper.bounds)&&(this.updateQuad(e),"Drag"!==this.eventHandler.currentAction&&this.updateGroupSize(e)),!0===h&&this.checkSelectedItem(e)&&(!(this.diagramActions&ee.ToolAction)||this.diagramActions&ee.UndoRedo)&&this.updateSelector(),this.preventConnectorsUpdate||(!Ds(this)||Ds(this)&&this.scroller.oldCollectionObjects.indexOf(e.id)>-1)&&(this.diagramActions&ee.PreventZIndexOnDragging?this.updateDiagramObject(e,!0):this.updateDiagramObject(e)),this.updateConnectorEdges(e),this.diagramActions&&"New"!==e.status&&(e.status="Update"),this.triggerPropertyChange(o,e,i,r)},t.prototype.removePortEdges=function(e,i,r,s){if(e)for(var o=0;o0&&e.id===s[s.length-1].id&&(r=!0),r},t.prototype.updateDiagramContainerVisibility=function(e,i){if(e instanceof Cs)for(var r=0;r>"),r instanceof es&&this.updateAnnotationWrapper(r,s,o,a)),void 0!==e.template&&(r.content=e.template,this.updateAnnotationWrapper(r,s,o,a))},t.prototype.updateAnnotationWrapper=function(e,i,r,s){for(var o=0,a=this.views;o=0&&this.nodes.splice(s,1),delete this.nameTable[""+r]}var o=this.nodes.indexOf(this.nameTable[this.currentSymbol.id]);o>=0&&this.nodes.splice(o,1)}},t.prototype.selectDragedNode=function(e,i,r){this.currentSymbol=e,"SVG"!==this.mode&&this.refreshDiagramLayer(),this.commandHandler.oldSelectedObjects=sm(this),this.commandHandler.select(e),this.eventHandler.mouseDown(i.event),this.eventHandler.mouseMove(i.event,i),this.preventDiagramUpdate=!1,this.updatePage(),r.style.opacity="0"},t.prototype.initDroppables=function(){var s,o,e=this,i={},r={},a="selectedSymbols";this.droppable=new lR(this.element);var l=5;this.droppable.over=function(h){if(e.rulerSettings.showRulers){var c=document.getElementById(e.element.id+"_vRuler"),d=parseFloat(c.style.width);l=d+1}if(0===e.previousSelectedObjects.length&&!e.currentSymbol&&(e.previousSelectedObjects=e.commandHandler.getSelectedObject()),e.commandHandler.PreventConnectorSplit=!0,e.currentSymbol)h.event.touches&&h.event.touches.length&&e.eventHandler.mouseMove(h.event,h.event.touches);else{var u=null;if(!h.dragData&&"drag"===h.name){var f=document.getElementsByClassName("e-dragclone")[0];f&&(u=f)}if(h.dragData||u){var p=void 0,g=void 0;document.getElementById(e.element.id+"content").focus();var v=e.eventHandler.getMousePosition(h.event),y=void 0,S=u||h.dragData.helper,b=S.getAttribute("paletteId"),M=void 0,w=void 0,C=void 0,D=void 0;if(!b&&h.dragData){e.triggerEvent(Ce.dragEnter,A={source:null,element:p,cancel:!1,diagram:e,dragData:h.dragData.draggedElement.ej2_instances[0].dragData,dragItem:p});var x=void 0,P=void 0;if(A.dragItem){if(A.dragItem.sourcePoint&&A.dragItem.targetPoint?P=new de(e,"connectors",A.dragItem,!0):x=new te(e,"nodes",A.dragItem,!0),e.initObject(p=x||P,void 0,void 0,!0),e.enterObject=p,e.enterTable=r,p instanceof te)x.offsetX=v.x+5+x.width*x.pivot.x,x.offsetY=v.y+x.height*x.pivot.y;else if(p instanceof de){var L=Ne.toBounds([p.sourcePoint,p.targetPoint]),O=v.x-L.left,N=v.y-L.top;p.sourcePoint.x+=O,p.sourcePoint.y+=N,p.targetPoint.x+=O,p.targetPoint.y+=N}e.preventDiagramUpdate=!0,e.currentSymbol=p,"SVG"!==e.mode&&e.refreshDiagramLayer(),e.selectDragedNode(p,h,S),delete e.enterObject,delete e.enterTable,e.droppable[""+a]=S,e.allowServerDataBinding=!0}}if(b){var T=document.getElementById(b).ej2_instances[0];if(e.droppable.sourceElement=T,T){var B=T[""+a];e.allowServerDataBinding=!1,y=$(T[""+a]),i=T.childTable;var j=B.wrapper.children[0].children[0];if(D=function $se(n,t,e){var i=AF(n,t,e,"width"),r=AF(n,t,e,"height");return new me(i,r)}(T,y,j),T[""+a]instanceof te){"TextAnnotation"===B.shape.shape?(y.offsetX=v.x+11+D.width*y.pivot.x,y.offsetY=v.y+11+D.height*y.pivot.y):(y.offsetX=v.x+5+D.width*y.pivot.x,y.offsetY=v.y+D.height*y.pivot.y),"Bpmn"===(x=new te(e,"nodes",y,!0)).shape.type&&x.shape.activity.subProcess.processes&&x.shape.activity.subProcess.processes.length&&(x.shape.activity.subProcess.processes=[]),w=x.previewSize,C=T.symbolDragSize;var Q=T.symbolPreview;if(x.width=(M=x.dragSize).width||C.width||w.width||Q.width||x.width,x.height=M.height||C.height||w.height||Q.height||x.height,"SwimLane"===x.shape.type){if(e.diagramActions|=ee.PreventHistory,x.shape.isLane){x.children=[],s={id:"header"+Qe()},"Horizontal"===x.shape.orientation?(s.width=x.shape.lanes[0].header.width,s.height=x.shape.lanes[0].height):(s.width=x.shape.lanes[0].width,s.height=x.shape.lanes[0].header.height),s.style=x.shape.lanes[0].header.style,s.offsetX=v.x+l+s.width/2,s.offsetY=v.y+s.height/2,e.diagramActions|=ee.PreventCollectionChangeOnDragOver,s=e.add(s),o={id:"body"+Qe()},"Horizontal"===x.shape.orientation?(o.width=x.shape.lanes[0].width-s.width,o.height=x.shape.lanes[0].height,o.offsetX=v.x+l+(x.shape.lanes[0].header.width+o.width/2),o.offsetY=v.y+o.height/2):(o.width=x.shape.lanes[0].width,o.height=x.shape.lanes[0].height-s.height,o.offsetX=v.x+l+o.width/2,o.offsetY=v.y+(x.shape.lanes[0].header.height+o.height/2)),o.style=x.shape.lanes[0].style,o=e.add(o);var oe={id:"group"+Qe(),children:[s.id,o.id]};oe.shape=x.shape,oe.width=x.shape.lanes[0].width,oe.height=x.shape.lanes[0].height,oe.previewSize=x.previewSize,oe.dragSize=x.dragSize,oe.addInfo=x.addInfo,x=e.add(oe),e.diagramActions&=~ee.PreventCollectionChangeOnDragOver}e.diagramActions&=~ee.PreventHistory}if(x.shape.isPhase&&((g="Horizontal"===x.shape.orientation)?(x.offsetX=v.x+l+(x.width||j.actualSize.width)/2,x.offsetY=v.y,x.shape.data="M20,"+x.height/2+" L"+(x.width-20)+","+x.height/2+"z",x.height=1):(x.offsetX=v.x+5,x.offsetY=v.y+(x.height||j.actualSize.height)/2,x.shape.data="M"+x.width/2+",20 L"+x.width/2+","+(x.height-20)+"z",x.width=1)),"UmlClassifier"===x.shape.type&&(x.children=x.width=x.height=void 0,y.children=void 0,"Class"===x.shape.classifier&&x.shape.classShape.methods.length<=0&&x.shape.classShape.attributes.length<=0&&(x.shape.classShape.attributes=[{name:"Name",type:"Type",style:{}}]),"Enumeration"===x.shape.classifier&&x.shape.enumerationShape.members.length<=0&&(x.shape.enumerationShape.members=[{name:"Name"}]),"Interface"===x.shape.classifier&&x.shape.interfaceShape.methods.length<=0&&x.shape.interfaceShape.attributes.length<=0&&(x.shape.interfaceShape.attributes=[{name:"Name",type:"Type",style:{}}])),p=x,y.children){var ue=y;r=e.getChildren(ue,{},i),rT(ue,-ue.offsetX,-ue.offsetY,r,!0,e)}}else if(T[""+a]instanceof de){p=new de(e,"connectors",y,!0);var Me=Ne.toBounds([p.sourcePoint,p.targetPoint]),De=v.x-Me.left,xe=v.y-Me.top;p.sourcePoint.x+=De,p.sourcePoint.y+=xe,p.targetPoint.x+=De,p.targetPoint.y+=xe}p.shape.isLane||(p.id+=Qe());var A={source:T,element:p,cancel:!1,diagram:e,dragData:null,dragItem:p};if(e.enterObject=p,e.enterTable=r,e.triggerEvent(Ce.dragEnter,A),p instanceof te&&"SwimLane"===p.shape.type&&p.shape.isLane){var Ie=A.element,Ve=Ie.shape.lanes[0];g="Horizontal"===Ie.shape.orientation;var ot=e.nameTable[p.children[0]],$e=e.nameTable[p.children[1]];w=p.previewSize,C=T.symbolDragSize,Ve.width=(M=p.dragSize).width||C.width||w.width||Ve.width,Ve.height=M.height||C.height||w.height||Ve.height,g?(s.width=Ve.header.width,s.height=Ve.height,o.width=Ve.width-s.width,o.height=Ve.height,o.offsetX=v.x+l+(Ve.header.width+$e.width/2),o.offsetY=v.y+$e.height/2):(s.width=Ve.width,s.height=Ve.header.height,o.width=Ve.width,o.height=Ve.height-s.height,o.offsetX=v.x+l+$e.width/2,o.offsetY=v.y+(Ve.header.height+$e.height/2)),s.offsetX=v.x+l+ot.width/2,s.offsetY=v.y+ot.height/2,p.width=Ve.width,p.height=Ve.height}if(p instanceof te&&p.shape.isPhase&&(g?p.height=1:p.width=1),!e.activeLayer.lock&&!A.cancel){if(e.preventDiagramUpdate=!0,p.children&&e.findChild(p,r),e.preventDiagramUpdate=!0,p.zIndex!==Number.MIN_VALUE&&(p.zIndex=Number.MIN_VALUE),e.initObject(p,void 0,void 0,!0),e.bpmnModule)for(var Ci=0;Ci0&&(S.segments=[]),d=this.add(S,!0)),(S||d)&&(Uv(this)||jv(this))&&this.select([this.nameTable[S[""+b]]],!1,this.previousSelectedObjects),y.target&&y.target instanceof de&&!0===this.enableConnectorSplit&&this.nameTable[S[""+b]]instanceof te&&(this.commandHandler.connectorSplit(this.nameTable[S[""+b]],y.target),this.commandHandler.PreventConnectorSplit=!1))),this.protectPropertyChange(!1),v=this.nameTable[S[""+b]],S.hasTarget&&(S.nodeId=S.hasTarget,this.remove(S)),this.bpmnModule&&v instanceof te&&S.processId&&(v.processId=S.processId,this.bpmnModule.dropBPMNchild(this.nameTable[v.processId],v,this)),y.cancel||this.endGroupAction(),"SVG"!==this.mode&&this.refreshDiagramLayer(),delete this.droppable[""+c]):(this.triggerEvent(Ce.drop,y={source:h.droppedElement,element:void 0,target:this.eventHandler.hoverNode||this.eventHandler.lastObjectUnderMouse||this,cancel:!1,position:void 0}),S=void 0,b="id"),this.droppable[M="selectedSymbols"]&&this.droppable[""+M].parentNode)gt(this.droppable[""+M]);else for(w=document.getElementsByClassName("e-dragclone"),C=0;C0)for(var f=0;f1),e.previousSelectedObject=null}}},t.prototype.getDropEventArgs=function(e){if(this.eventHandler.lastObjectUnderMouse||this.eventHandler.hoverNode){var i=this.eventHandler.lastObjectUnderMouse||this.eventHandler.hoverNode;e.target=ps(i)===de?{connector:i}:{node:i}}else e.target.diagramId=this.element.id},t.prototype.removeChildInNodes=function(e){if(e){if(e.children)for(var i=0;i1){var l=2;if(e.children&&e.children.length>0)for(;e.children.indexOf(i.objects[s-l])>-1;)l++;this.commandHandler.moveSvgNode(e.id,i.objects[s-l]),this.commandHandler.moveSvgNode(i.objects[s-l],e.id)}else if(o){var h=this.commandHandler.getLayer(this.layerZIndexTable[o.zIndex]).objects[0];h?(this.commandHandler.moveSvgNode(e.id,h),this.commandHandler.updateNativeNodeIndex(e.id,h)):this.moveObjectsUp(e,i)}else this.moveObjectsUp(e,i)},t.prototype.moveObjectsUp=function(e,i){for(var r,s=this.layers.length-1;s>=0;s--)if(r=this.layers[parseInt(s.toString(),10)],i.id!==r.id){var o=this.commandHandler.getLayer(this.layerZIndexTable[r.zIndex]).objects[r.objects.length-1];if(o){this.commandHandler.moveSvgNode(e.id,o),this.commandHandler.moveSvgNode(o,e.id);break}}},t.prototype.insertData=function(e){return this.crudOperation(e,"create",this.getNewUpdateNodes("New"))},t.prototype.updateData=function(e){return this.crudOperation(e,"update",this.getNewUpdateNodes("Update"))},t.prototype.removeData=function(e){return this.crudOperation(e,"destroy",this.getDeletedNodes())},t.prototype.crudOperation=function(e,i,r){if(e){var s=this.parameterMap(e,!(e instanceof de));if(s){var o=e instanceof de?this.dataSourceSettings.connectionDataSource.crudAction[""+i]:this.dataSourceSettings.crudAction[""+i];this.raiseAjaxPost(JSON.stringify(s),o)}return s}var a=r;return this.processCrudCollection(a,this.dataSourceSettings.crudAction[""+i],this.dataSourceSettings.connectionDataSource.crudAction[""+i]),a},t.prototype.processCrudCollection=function(e,i,r){if(e.nodes){var s=[],o=void 0;for(o=0;o0&&this.raiseAjaxPost(JSON.stringify(s),i)}if(e.connectors){for(s=[],o=void 0,o=0;o0&&this.raiseAjaxPost(JSON.stringify(s),r)}},t.prototype.parameterMap=function(e,i){var s,r={},o=i?this.dataSourceSettings:this.dataSourceSettings.connectionDataSource;if(o.id&&(r[o.id]=e.id),o.sourcePointX&&o.sourcePointY&&(r[o.sourcePointX]=e.sourcePoint.x,r[o.sourcePointY]=e.sourcePoint.y),o.targetPointX&&o.targetPointY&&(r[o.targetPointX]=e.targetPoint.x,r[o.targetPointY]=e.targetPoint.y),o.sourceID&&(r[o.sourceID]=e.sourceID),o.targetID&&(r[o.targetID]=e.targetID),o.crudAction&&o.crudAction.customFields&&o.crudAction.customFields.length>0)for(s=0;s{class n extends ph{constructor(e){super(),this.viewContainerRef=e,ml("currentInstance",this,this.viewContainerRef),this.registerEvents($ae),this.directivePropList=qae}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-layer"]],inputs:{addInfo:"addInfo",id:"id",lock:"lock",objects:"objects",visible:"visible",zIndex:"zIndex"},features:[yn]}),n})(),Jae=(()=>{class n extends gh{constructor(){super("layers")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-layers"]],contentQueries:function(e,i,r){if(1&e&&dn(r,Zae,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),Kae=["action","cursor"],ele=[],tle=(()=>{class n extends ph{constructor(e){super(),this.viewContainerRef=e,ml("currentInstance",this,this.viewContainerRef),this.registerEvents(ele),this.directivePropList=Kae}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-cursormap"]],inputs:{action:"action",cursor:"cursor"},features:[yn]}),n})(),ile=(()=>{class n extends gh{constructor(){super("customcursor")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-cursormaps"]],contentQueries:function(e,i,r){if(1&e&&dn(r,tle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),rle=["alignment","cornerRadius","displacement","fill","handleStrokeColor","handleStrokeWidth","height","iconStrokeColor","iconStrokeWidth","id","offset","padding","pathData","tooltip","visibility","width"],nle=[],sle=(()=>{class n extends ph{constructor(e){super(),this.viewContainerRef=e,ml("currentInstance",this,this.viewContainerRef),this.registerEvents(nle),this.directivePropList=rle}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-connector-fixeduserhandle"]],inputs:{alignment:"alignment",cornerRadius:"cornerRadius",displacement:"displacement",fill:"fill",handleStrokeColor:"handleStrokeColor",handleStrokeWidth:"handleStrokeWidth",height:"height",iconStrokeColor:"iconStrokeColor",iconStrokeWidth:"iconStrokeWidth",id:"id",offset:"offset",padding:"padding",pathData:"pathData",tooltip:"tooltip",visibility:"visibility",width:"width"},features:[yn]}),n})(),ole=(()=>{class n extends gh{constructor(){super("fixeduserhandles")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-connector-fixeduserhandles"]],contentQueries:function(e,i,r){if(1&e&&dn(r,sle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),ale=["addInfo","alignment","annotationType","constraints","content","displacement","dragLimit","height","horizontalAlignment","hyperlink","id","margin","offset","rotateAngle","rotationReference","segmentAngle","style","template","tooltip","type","verticalAlignment","visibility","width"],lle=[],hle=(()=>{class n extends ph{constructor(e){super(),this.viewContainerRef=e,ml("currentInstance",this,this.viewContainerRef),this.registerEvents(lle),this.directivePropList=ale}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-connector-annotation"]],inputs:{addInfo:"addInfo",alignment:"alignment",annotationType:"annotationType",constraints:"constraints",content:"content",displacement:"displacement",dragLimit:"dragLimit",height:"height",horizontalAlignment:"horizontalAlignment",hyperlink:"hyperlink",id:"id",margin:"margin",offset:"offset",rotateAngle:"rotateAngle",rotationReference:"rotationReference",segmentAngle:"segmentAngle",style:"style",template:"template",tooltip:"tooltip",type:"type",verticalAlignment:"verticalAlignment",visibility:"visibility",width:"width"},features:[yn]}),n})(),cle=(()=>{class n extends gh{constructor(){super("annotations")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-connector-annotations"]],contentQueries:function(e,i,r){if(1&e&&dn(r,hle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),dle=["addInfo","allowNodeOverlap","annotations","bezierSettings","bridgeSpace","connectionPadding","connectorSpacing","constraints","cornerRadius","dragSize","excludeFromLayout","fixedUserHandles","flip","flipMode","hitPadding","id","margin","maxSegmentThumb","ports","previewSize","segmentThumbShape","segmentThumbSize","segments","shape","sourceDecorator","sourceID","sourcePadding","sourcePoint","sourcePortID","style","symbolInfo","targetDecorator","targetID","targetPadding","targetPoint","targetPortID","tooltip","type","visible","wrapper","zIndex"],ule=[],fle=(()=>{class n extends ph{constructor(e){super(),this.viewContainerRef=e,this.tags=["fixedUserHandles","annotations"],ml("currentInstance",this,this.viewContainerRef),this.registerEvents(ule),this.directivePropList=dle}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-connector"]],contentQueries:function(e,i,r){if(1&e&&(dn(r,ole,5),dn(r,cle,5)),2&e){let s;Kr(s=en())&&(i.childFixedUserHandles=s.first),Kr(s=en())&&(i.childAnnotations=s.first)}},inputs:{addInfo:"addInfo",allowNodeOverlap:"allowNodeOverlap",annotations:"annotations",bezierSettings:"bezierSettings",bridgeSpace:"bridgeSpace",connectionPadding:"connectionPadding",connectorSpacing:"connectorSpacing",constraints:"constraints",cornerRadius:"cornerRadius",dragSize:"dragSize",excludeFromLayout:"excludeFromLayout",fixedUserHandles:"fixedUserHandles",flip:"flip",flipMode:"flipMode",hitPadding:"hitPadding",id:"id",margin:"margin",maxSegmentThumb:"maxSegmentThumb",ports:"ports",previewSize:"previewSize",segmentThumbShape:"segmentThumbShape",segmentThumbSize:"segmentThumbSize",segments:"segments",shape:"shape",sourceDecorator:"sourceDecorator",sourceID:"sourceID",sourcePadding:"sourcePadding",sourcePoint:"sourcePoint",sourcePortID:"sourcePortID",style:"style",symbolInfo:"symbolInfo",targetDecorator:"targetDecorator",targetID:"targetID",targetPadding:"targetPadding",targetPoint:"targetPoint",targetPortID:"targetPortID",tooltip:"tooltip",type:"type",visible:"visible",wrapper:"wrapper",zIndex:"zIndex"},features:[yn]}),n})(),ple=(()=>{class n extends gh{constructor(){super("connectors")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-connectors"]],contentQueries:function(e,i,r){if(1&e&&dn(r,fle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),gle=["cornerRadius","fill","handleStrokeColor","handleStrokeWidth","height","iconStrokeColor","iconStrokeWidth","id","margin","offset","padding","pathData","tooltip","visibility","width"],vle=[],mle=(()=>{class n extends ph{constructor(e){super(),this.viewContainerRef=e,ml("currentInstance",this,this.viewContainerRef),this.registerEvents(vle),this.directivePropList=gle}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-node-fixeduserhandle"]],inputs:{cornerRadius:"cornerRadius",fill:"fill",handleStrokeColor:"handleStrokeColor",handleStrokeWidth:"handleStrokeWidth",height:"height",iconStrokeColor:"iconStrokeColor",iconStrokeWidth:"iconStrokeWidth",id:"id",margin:"margin",offset:"offset",padding:"padding",pathData:"pathData",tooltip:"tooltip",visibility:"visibility",width:"width"},features:[yn]}),n})(),yle=(()=>{class n extends gh{constructor(){super("fixeduserhandles")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-node-fixeduserhandles"]],contentQueries:function(e,i,r){if(1&e&&dn(r,mle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),Sle=["addInfo","annotationType","constraints","content","dragLimit","height","horizontalAlignment","hyperlink","id","margin","offset","rotateAngle","rotationReference","style","template","tooltip","type","verticalAlignment","visibility","width"],Ile=[],v_=(()=>{class n extends ph{constructor(e){super(),this.viewContainerRef=e,ml("currentInstance",this,this.viewContainerRef),this.registerEvents(Ile),this.directivePropList=Sle}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-node-annotation"]],inputs:{addInfo:"addInfo",annotationType:"annotationType",constraints:"constraints",content:"content",dragLimit:"dragLimit",height:"height",horizontalAlignment:"horizontalAlignment",hyperlink:"hyperlink",id:"id",margin:"margin",offset:"offset",rotateAngle:"rotateAngle",rotationReference:"rotationReference",style:"style",template:"template",tooltip:"tooltip",type:"type",verticalAlignment:"verticalAlignment",visibility:"visibility",width:"width"},features:[yn]}),n})(),m_=(()=>{class n extends gh{constructor(){super("annotations")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-node-annotations"]],contentQueries:function(e,i,r){if(1&e&&dn(r,v_,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),ble=["addInfo","connectionDirection","constraints","height","horizontalAlignment","id","inEdges","margin","offset","outEdges","pathData","shape","style","tooltip","verticalAlignment","visibility","width"],Mle=[],wle=(()=>{class n extends ph{constructor(e){super(),this.viewContainerRef=e,ml("currentInstance",this,this.viewContainerRef),this.registerEvents(Mle),this.directivePropList=ble}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-node-port"]],inputs:{addInfo:"addInfo",connectionDirection:"connectionDirection",constraints:"constraints",height:"height",horizontalAlignment:"horizontalAlignment",id:"id",inEdges:"inEdges",margin:"margin",offset:"offset",outEdges:"outEdges",pathData:"pathData",shape:"shape",style:"style",tooltip:"tooltip",verticalAlignment:"verticalAlignment",visibility:"visibility",width:"width"},features:[yn]}),n})(),Cle=(()=>{class n extends gh{constructor(){super("ports")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-node-ports"]],contentQueries:function(e,i,r){if(1&e&&dn(r,wle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),Ele=["addInfo","annotations","backgroundColor","borderColor","borderWidth","branch","children","collapseIcon","columnIndex","columnSpan","columns","constraints","container","data","dragSize","excludeFromLayout","expandIcon","fixedUserHandles","flip","flipMode","height","horizontalAlignment","id","isExpanded","layoutInfo","margin","maxHeight","maxWidth","minHeight","minWidth","offsetX","offsetY","padding","pivot","ports","previewSize","rotateAngle","rowIndex","rowSpan","rows","shadow","shape","style","symbolInfo","tooltip","verticalAlignment","visible","width","wrapper","zIndex"],Dle=[],y_=(()=>{class n extends ph{constructor(e){super(),this.viewContainerRef=e,this.tags=["fixedUserHandles","annotations","ports"],ml("currentInstance",this,this.viewContainerRef),this.registerEvents(Dle),this.directivePropList=Ele}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-node"]],contentQueries:function(e,i,r){if(1&e&&(dn(r,yle,5),dn(r,m_,5),dn(r,Cle,5)),2&e){let s;Kr(s=en())&&(i.childFixedUserHandles=s.first),Kr(s=en())&&(i.childAnnotations=s.first),Kr(s=en())&&(i.childPorts=s.first)}},inputs:{addInfo:"addInfo",annotations:"annotations",backgroundColor:"backgroundColor",borderColor:"borderColor",borderWidth:"borderWidth",branch:"branch",children:"children",collapseIcon:"collapseIcon",columnIndex:"columnIndex",columnSpan:"columnSpan",columns:"columns",constraints:"constraints",container:"container",data:"data",dragSize:"dragSize",excludeFromLayout:"excludeFromLayout",expandIcon:"expandIcon",fixedUserHandles:"fixedUserHandles",flip:"flip",flipMode:"flipMode",height:"height",horizontalAlignment:"horizontalAlignment",id:"id",isExpanded:"isExpanded",layoutInfo:"layoutInfo",margin:"margin",maxHeight:"maxHeight",maxWidth:"maxWidth",minHeight:"minHeight",minWidth:"minWidth",offsetX:"offsetX",offsetY:"offsetY",padding:"padding",pivot:"pivot",ports:"ports",previewSize:"previewSize",rotateAngle:"rotateAngle",rowIndex:"rowIndex",rowSpan:"rowSpan",rows:"rows",shadow:"shadow",shape:"shape",style:"style",symbolInfo:"symbolInfo",tooltip:"tooltip",verticalAlignment:"verticalAlignment",visible:"visible",width:"width",wrapper:"wrapper",zIndex:"zIndex"},features:[yn]}),n})(),S_=(()=>{class n extends gh{constructor(){super("nodes")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-nodes"]],contentQueries:function(e,i,r){if(1&e&&dn(r,y_,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})();const xle=["animationComplete","click","collectionChange","commandExecute","connectionChange","contextMenuBeforeItemRender","contextMenuClick","contextMenuOpen","created","dataLoaded","doubleClick","dragEnter","dragLeave","dragOver","drop","elementDraw","expandStateChange","fixedUserHandleClick","historyChange","historyStateChange","keyDown","keyUp","load","loaded","mouseEnter","mouseLeave","mouseOver","mouseWheel","onFixedUserHandleMouseDown","onFixedUserHandleMouseEnter","onFixedUserHandleMouseLeave","onFixedUserHandleMouseUp","onImageLoad","onUserHandleMouseDown","onUserHandleMouseEnter","onUserHandleMouseLeave","onUserHandleMouseUp","positionChange","propertyChange","rotateChange","scrollChange","segmentChange","segmentCollectionChange","selectionChange","sizeChange","sourcePointChange","targetPointChange","textEdit"],Tle=[""];let Ale=(()=>{let n=class extends _l{constructor(e,i,r,s){super(),this.ngEle=e,this.srenderer=i,this.viewContainerRef=r,this.injector=s,this.tags=["layers","customCursor","connectors","nodes"],this.element=this.ngEle.nativeElement,this.injectedModules=this.injectedModules||[];try{let o=this.injector.get("DiagramsHierarchicalTree");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsMindMap");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsRadialTree");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsComplexHierarchicalTree");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsDataBinding");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsSnapping");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsPrintAndExport");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsBpmnDiagrams");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsSymmetricLayout");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsConnectorBridging");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsUndoRedo");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsLayoutAnimation");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsDiagramContextMenu");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsLineRouting");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsConnectorEditing");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsLineDistribution");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsEj1Serialization");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsFlowchartLayout");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}this.registerEvents(xle),this.addTwoWay.call(this,Tle),ml("currentInstance",this,this.viewContainerRef),this.context=new SR}ngOnInit(){this.context.ngOnInit(this)}ngAfterViewInit(){this.context.ngAfterViewInit(this)}ngOnDestroy(){this.context.ngOnDestroy(this)}ngAfterContentChecked(){this.tagObjects[0].instance=this.childLayers,this.childCustomCursor&&(this.tagObjects[1].instance=this.childCustomCursor),this.childConnectors&&(this.tagObjects[2].instance=this.childConnectors),this.childNodes&&(this.tagObjects[3].instance=this.childNodes),this.context.ngAfterContentChecked(this)}};return n.\u0275fac=function(e){return new(e||n)(Ot($c),Ot(cM),Ot(An),Ot(Wo))},n.\u0275cmp=_b({type:n,selectors:[["ejs-diagram"]],contentQueries:function(e,i,r){if(1&e&&(dn(r,Qae,5),dn(r,Gae,5),dn(r,Xae,5),dn(r,Jae,5),dn(r,ile,5),dn(r,ple,5),dn(r,S_,5)),2&e){let s;Kr(s=en())&&(i.annotationTemplate=s.first),Kr(s=en())&&(i.nodeTemplate=s.first),Kr(s=en())&&(i.userHandleTemplate=s.first),Kr(s=en())&&(i.childLayers=s.first),Kr(s=en())&&(i.childCustomCursor=s.first),Kr(s=en())&&(i.childConnectors=s.first),Kr(s=en())&&(i.childNodes=s.first)}},inputs:{addInfo:"addInfo",annotationTemplate:"annotationTemplate",backgroundColor:"backgroundColor",bridgeDirection:"bridgeDirection",commandManager:"commandManager",connectorDefaults:"connectorDefaults",connectors:"connectors",constraints:"constraints",contextMenuSettings:"contextMenuSettings",customCursor:"customCursor",dataSourceSettings:"dataSourceSettings",diagramSettings:"diagramSettings",drawingObject:"drawingObject",enableConnectorSplit:"enableConnectorSplit",enablePersistence:"enablePersistence",enableRtl:"enableRtl",fixedUserHandleTemplate:"fixedUserHandleTemplate",getConnectorDefaults:"getConnectorDefaults",getCustomCursor:"getCustomCursor",getCustomProperty:"getCustomProperty",getCustomTool:"getCustomTool",getDescription:"getDescription",getNodeDefaults:"getNodeDefaults",height:"height",historyManager:"historyManager",layers:"layers",layout:"layout",locale:"locale",mode:"mode",nodeDefaults:"nodeDefaults",nodeTemplate:"nodeTemplate",nodes:"nodes",pageSettings:"pageSettings",rulerSettings:"rulerSettings",scrollSettings:"scrollSettings",segmentThumbShape:"segmentThumbShape",segmentThumbSize:"segmentThumbSize",selectedItems:"selectedItems",serializationSettings:"serializationSettings",setNodeTemplate:"setNodeTemplate",snapSettings:"snapSettings",tool:"tool",tooltip:"tooltip",updateSelection:"updateSelection",userHandleTemplate:"userHandleTemplate",width:"width"},outputs:{animationComplete:"animationComplete",click:"click",collectionChange:"collectionChange",commandExecute:"commandExecute",connectionChange:"connectionChange",contextMenuBeforeItemRender:"contextMenuBeforeItemRender",contextMenuClick:"contextMenuClick",contextMenuOpen:"contextMenuOpen",created:"created",dataLoaded:"dataLoaded",doubleClick:"doubleClick",dragEnter:"dragEnter",dragLeave:"dragLeave",dragOver:"dragOver",drop:"drop",elementDraw:"elementDraw",expandStateChange:"expandStateChange",fixedUserHandleClick:"fixedUserHandleClick",historyChange:"historyChange",historyStateChange:"historyStateChange",keyDown:"keyDown",keyUp:"keyUp",load:"load",loaded:"loaded",mouseEnter:"mouseEnter",mouseLeave:"mouseLeave",mouseOver:"mouseOver",mouseWheel:"mouseWheel",onFixedUserHandleMouseDown:"onFixedUserHandleMouseDown",onFixedUserHandleMouseEnter:"onFixedUserHandleMouseEnter",onFixedUserHandleMouseLeave:"onFixedUserHandleMouseLeave",onFixedUserHandleMouseUp:"onFixedUserHandleMouseUp",onImageLoad:"onImageLoad",onUserHandleMouseDown:"onUserHandleMouseDown",onUserHandleMouseEnter:"onUserHandleMouseEnter",onUserHandleMouseLeave:"onUserHandleMouseLeave",onUserHandleMouseUp:"onUserHandleMouseUp",positionChange:"positionChange",propertyChange:"propertyChange",rotateChange:"rotateChange",scrollChange:"scrollChange",segmentChange:"segmentChange",segmentCollectionChange:"segmentCollectionChange",selectionChange:"selectionChange",sizeChange:"sizeChange",sourcePointChange:"sourcePointChange",targetPointChange:"targetPointChange",textEdit:"textEdit"},features:[yn],decls:0,vars:0,template:function(e,i){},encapsulation:2,changeDetection:0}),k0([xC()],n.prototype,"annotationTemplate",void 0),k0([xC()],n.prototype,"nodeTemplate",void 0),k0([xC()],n.prototype,"userHandleTemplate",void 0),n=k0([PZ([SR])],n),n})(),Lle=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Nm({type:n}),n.\u0275inj=mp({imports:[[sq]]}),n})();const Nle=["diagram"];let Ole=(()=>{class n{constructor(){this.layers=[]}ngOnInit(){this.layers=[{id:"layer1",objects:["node1"]},{id:"layer2",objects:["node2"]}]}removeLayer(){this.diagram.removeLayer("layer1")}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275cmp=_b({type:n,selectors:[["app-container"]],viewQuery:function(i,r){if(1&i&&function uP(n,t,e){const i=Ti();i.firstCreatePass&&(cP(i,new aP(n,t,e),-1),2==(2&t)&&(i.staticViewQueries=!0)),hP(i,Se(),t)}(Nle,5),2&i){let s;Kr(s=en())&&(r.diagram=s.first)}},standalone:!0,features:[PP([]),RP],decls:11,vars:9,consts:[[3,"click"],["id","diagram","width","100%","height","580px",3,"layers"],["diagram",""],["id","node1",3,"width","height","offsetX","offsetY"],["content","Layer 1 Object"],["id","node2",3,"width","height","offsetX","offsetY"],["content","Layer 2 Object"]],template:function(i,r){1&i&&(Gu(0,"button",0),lw("click",function(){return r.removeLayer()}),function MP(n,t=""){const e=Se(),i=Ti(),r=n+jt,s=i.firstCreatePass?Tu(i,r,1,t,null):i.data[r],o=wP(i,e,s,t,n);e[r]=o,Bm()&&cy(i,e,o,s),ll(s,!1)}(1,"removeLayer"),Xu(),Gu(2,"ejs-diagram",1,2)(4,"e-nodes")(5,"e-node",3)(6,"e-node-annotations"),Vy(7,"e-node-annotation",4),Xu()(),Gu(8,"e-node",5)(9,"e-node-annotations"),Vy(10,"e-node-annotation",6),Xu()()()()),2&i&&(Ey(2),hg("layers",r.layers),Ey(3),hg("width",100)("height",100)("offsetX",100)("offsetY",100),Ey(3),hg("width",100)("height",100)("offsetX",100)("offsetY",300))},dependencies:[Lle,Ale,v_,m_,y_,S_],encapsulation:2})}}return n})();jd(332),function $q(n,t){return DG({rootComponent:n,...Ez(t)})}(Ole).catch(n=>console.error(n))},332:()=>{!function(Z){const se=Z.performance;function ye(zi){se&&se.mark&&se.mark(zi)}function pe(zi,ht){se&&se.measure&&se.measure(zi,ht)}ye("Zone");const be=Z.__Zone_symbol_prefix||"__zone_symbol__";function ke(zi){return be+zi}const at=!0===Z[ke("forceDuplicateZoneCheck")];if(Z.Zone){if(at||"function"!=typeof Z.Zone.__symbol__)throw new Error("Zone already loaded.");return Z.Zone}let tt=(()=>{class zi{static{this.__symbol__=ke}static assertZonePatched(){if(Z.Promise!==_o.ZoneAwarePromise)throw new Error("Zone.js has detected that ZoneAwarePromise `(window|global).Promise` has been overwritten.\nMost likely cause is that a Promise polyfill has been loaded after Zone.js (Polyfilling Promise api is not necessary when zone.js is loaded. If you must load one, do so before loading zone.js.)")}static get root(){let F=zi.current;for(;F.parent;)F=F.parent;return F}static get current(){return Ur.zone}static get currentTask(){return Do}static __load_patch(F,ae,Et=!1){if(_o.hasOwnProperty(F)){if(!Et&&at)throw Error("Already loaded patch: "+F)}else if(!Z["__Zone_disable_"+F]){const Xt="Zone:"+F;ye(Xt),_o[F]=ae(Z,zi,cn),pe(Xt,Xt)}}get parent(){return this._parent}get name(){return this._name}constructor(F,ae){this._parent=F,this._name=ae?ae.name||"unnamed":"",this._properties=ae&&ae.properties||{},this._zoneDelegate=new Lt(this,this._parent&&this._parent._zoneDelegate,ae)}get(F){const ae=this.getZoneWith(F);if(ae)return ae._properties[F]}getZoneWith(F){let ae=this;for(;ae;){if(ae._properties.hasOwnProperty(F))return ae;ae=ae._parent}return null}fork(F){if(!F)throw new Error("ZoneSpec required!");return this._zoneDelegate.fork(this,F)}wrap(F,ae){if("function"!=typeof F)throw new Error("Expecting function got: "+F);const Et=this._zoneDelegate.intercept(this,F,ae),Xt=this;return function(){return Xt.runGuarded(Et,this,arguments,ae)}}run(F,ae,Et,Xt){Ur={parent:Ur,zone:this};try{return this._zoneDelegate.invoke(this,F,ae,Et,Xt)}finally{Ur=Ur.parent}}runGuarded(F,ae=null,Et,Xt){Ur={parent:Ur,zone:this};try{try{return this._zoneDelegate.invoke(this,F,ae,Et,Xt)}catch(Vn){if(this._zoneDelegate.handleError(this,Vn))throw Vn}}finally{Ur=Ur.parent}}runTask(F,ae,Et){if(F.zone!=this)throw new Error("A task can only be run in the zone of creation! (Creation: "+(F.zone||jn).name+"; Execution: "+this.name+")");if(F.state===sr&&(F.type===rs||F.type===Pt))return;const Xt=F.state!=lt;Xt&&F._transitionTo(lt,Pi),F.runCount++;const Vn=Do;Do=F,Ur={parent:Ur,zone:this};try{F.type==Pt&&F.data&&!F.data.isPeriodic&&(F.cancelFn=void 0);try{return this._zoneDelegate.invokeTask(this,F,ae,Et)}catch(Ue){if(this._zoneDelegate.handleError(this,Ue))throw Ue}}finally{F.state!==sr&&F.state!==et&&(F.type==rs||F.data&&F.data.isPeriodic?Xt&&F._transitionTo(Pi,lt):(F.runCount=0,this._updateTaskCount(F,-1),Xt&&F._transitionTo(sr,lt,sr))),Ur=Ur.parent,Do=Vn}}scheduleTask(F){if(F.zone&&F.zone!==this){let Et=this;for(;Et;){if(Et===F.zone)throw Error(`can not reschedule task to ${this.name} which is descendants of the original zone ${F.zone.name}`);Et=Et.parent}}F._transitionTo(Zr,sr);const ae=[];F._zoneDelegates=ae,F._zone=this;try{F=this._zoneDelegate.scheduleTask(this,F)}catch(Et){throw F._transitionTo(et,Zr,sr),this._zoneDelegate.handleError(this,Et),Et}return F._zoneDelegates===ae&&this._updateTaskCount(F,1),F.state==Zr&&F._transitionTo(Pi,Zr),F}scheduleMicroTask(F,ae,Et,Xt){return this.scheduleTask(new pt(yi,F,ae,Et,Xt,void 0))}scheduleMacroTask(F,ae,Et,Xt,Vn){return this.scheduleTask(new pt(Pt,F,ae,Et,Xt,Vn))}scheduleEventTask(F,ae,Et,Xt,Vn){return this.scheduleTask(new pt(rs,F,ae,Et,Xt,Vn))}cancelTask(F){if(F.zone!=this)throw new Error("A task can only be cancelled in the zone of creation! (Creation: "+(F.zone||jn).name+"; Execution: "+this.name+")");if(F.state===Pi||F.state===lt){F._transitionTo(dr,Pi,lt);try{this._zoneDelegate.cancelTask(this,F)}catch(ae){throw F._transitionTo(et,dr),this._zoneDelegate.handleError(this,ae),ae}return this._updateTaskCount(F,-1),F._transitionTo(sr,dr),F.runCount=0,F}}_updateTaskCount(F,ae){const Et=F._zoneDelegates;-1==ae&&(F._zoneDelegates=null);for(let Xt=0;Xtzi.hasTask(F,ae),onScheduleTask:(zi,ht,F,ae)=>zi.scheduleTask(F,ae),onInvokeTask:(zi,ht,F,ae,Et,Xt)=>zi.invokeTask(F,ae,Et,Xt),onCancelTask:(zi,ht,F,ae)=>zi.cancelTask(F,ae)};class Lt{constructor(ht,F,ae){this._taskCounts={microTask:0,macroTask:0,eventTask:0},this.zone=ht,this._parentDelegate=F,this._forkZS=ae&&(ae&&ae.onFork?ae:F._forkZS),this._forkDlgt=ae&&(ae.onFork?F:F._forkDlgt),this._forkCurrZone=ae&&(ae.onFork?this.zone:F._forkCurrZone),this._interceptZS=ae&&(ae.onIntercept?ae:F._interceptZS),this._interceptDlgt=ae&&(ae.onIntercept?F:F._interceptDlgt),this._interceptCurrZone=ae&&(ae.onIntercept?this.zone:F._interceptCurrZone),this._invokeZS=ae&&(ae.onInvoke?ae:F._invokeZS),this._invokeDlgt=ae&&(ae.onInvoke?F:F._invokeDlgt),this._invokeCurrZone=ae&&(ae.onInvoke?this.zone:F._invokeCurrZone),this._handleErrorZS=ae&&(ae.onHandleError?ae:F._handleErrorZS),this._handleErrorDlgt=ae&&(ae.onHandleError?F:F._handleErrorDlgt),this._handleErrorCurrZone=ae&&(ae.onHandleError?this.zone:F._handleErrorCurrZone),this._scheduleTaskZS=ae&&(ae.onScheduleTask?ae:F._scheduleTaskZS),this._scheduleTaskDlgt=ae&&(ae.onScheduleTask?F:F._scheduleTaskDlgt),this._scheduleTaskCurrZone=ae&&(ae.onScheduleTask?this.zone:F._scheduleTaskCurrZone),this._invokeTaskZS=ae&&(ae.onInvokeTask?ae:F._invokeTaskZS),this._invokeTaskDlgt=ae&&(ae.onInvokeTask?F:F._invokeTaskDlgt),this._invokeTaskCurrZone=ae&&(ae.onInvokeTask?this.zone:F._invokeTaskCurrZone),this._cancelTaskZS=ae&&(ae.onCancelTask?ae:F._cancelTaskZS),this._cancelTaskDlgt=ae&&(ae.onCancelTask?F:F._cancelTaskDlgt),this._cancelTaskCurrZone=ae&&(ae.onCancelTask?this.zone:F._cancelTaskCurrZone),this._hasTaskZS=null,this._hasTaskDlgt=null,this._hasTaskDlgtOwner=null,this._hasTaskCurrZone=null;const Et=ae&&ae.onHasTask;(Et||F&&F._hasTaskZS)&&(this._hasTaskZS=Et?ae:At,this._hasTaskDlgt=F,this._hasTaskDlgtOwner=this,this._hasTaskCurrZone=ht,ae.onScheduleTask||(this._scheduleTaskZS=At,this._scheduleTaskDlgt=F,this._scheduleTaskCurrZone=this.zone),ae.onInvokeTask||(this._invokeTaskZS=At,this._invokeTaskDlgt=F,this._invokeTaskCurrZone=this.zone),ae.onCancelTask||(this._cancelTaskZS=At,this._cancelTaskDlgt=F,this._cancelTaskCurrZone=this.zone))}fork(ht,F){return this._forkZS?this._forkZS.onFork(this._forkDlgt,this.zone,ht,F):new tt(ht,F)}intercept(ht,F,ae){return this._interceptZS?this._interceptZS.onIntercept(this._interceptDlgt,this._interceptCurrZone,ht,F,ae):F}invoke(ht,F,ae,Et,Xt){return this._invokeZS?this._invokeZS.onInvoke(this._invokeDlgt,this._invokeCurrZone,ht,F,ae,Et,Xt):F.apply(ae,Et)}handleError(ht,F){return!this._handleErrorZS||this._handleErrorZS.onHandleError(this._handleErrorDlgt,this._handleErrorCurrZone,ht,F)}scheduleTask(ht,F){let ae=F;if(this._scheduleTaskZS)this._hasTaskZS&&ae._zoneDelegates.push(this._hasTaskDlgtOwner),ae=this._scheduleTaskZS.onScheduleTask(this._scheduleTaskDlgt,this._scheduleTaskCurrZone,ht,F),ae||(ae=F);else if(F.scheduleFn)F.scheduleFn(F);else{if(F.type!=yi)throw new Error("Task is missing scheduleFn.");Wt(F)}return ae}invokeTask(ht,F,ae,Et){return this._invokeTaskZS?this._invokeTaskZS.onInvokeTask(this._invokeTaskDlgt,this._invokeTaskCurrZone,ht,F,ae,Et):F.callback.apply(ae,Et)}cancelTask(ht,F){let ae;if(this._cancelTaskZS)ae=this._cancelTaskZS.onCancelTask(this._cancelTaskDlgt,this._cancelTaskCurrZone,ht,F);else{if(!F.cancelFn)throw Error("Task is not cancelable");ae=F.cancelFn(F)}return ae}hasTask(ht,F){try{this._hasTaskZS&&this._hasTaskZS.onHasTask(this._hasTaskDlgt,this._hasTaskCurrZone,ht,F)}catch(ae){this.handleError(ht,ae)}}_updateTaskCount(ht,F){const ae=this._taskCounts,Et=ae[ht],Xt=ae[ht]=Et+F;if(Xt<0)throw new Error("More tasks executed then were scheduled.");0!=Et&&0!=Xt||this.hasTask(this.zone,{microTask:ae.microTask>0,macroTask:ae.macroTask>0,eventTask:ae.eventTask>0,change:ht})}}class pt{constructor(ht,F,ae,Et,Xt,Vn){if(this._zone=null,this.runCount=0,this._zoneDelegates=null,this._state="notScheduled",this.type=ht,this.source=F,this.data=Et,this.scheduleFn=Xt,this.cancelFn=Vn,!ae)throw new Error("callback is not defined");this.callback=ae;const Ue=this;this.invoke=ht===rs&&Et&&Et.useG?pt.invokeTask:function(){return pt.invokeTask.call(Z,Ue,this,arguments)}}static invokeTask(ht,F,ae){ht||(ht=this),Ls++;try{return ht.runCount++,ht.zone.runTask(ht,F,ae)}finally{1==Ls&&ct(),Ls--}}get zone(){return this._zone}get state(){return this._state}cancelScheduleRequest(){this._transitionTo(sr,Zr)}_transitionTo(ht,F,ae){if(this._state!==F&&this._state!==ae)throw new Error(`${this.type} '${this.source}': can not transition to '${ht}', expecting state '${F}'${ae?" or '"+ae+"'":""}, was '${this._state}'.`);this._state=ht,ht==sr&&(this._zoneDelegates=null)}toString(){return this.data&&typeof this.data.handleId<"u"?this.data.handleId.toString():Object.prototype.toString.call(this)}toJSON(){return{type:this.type,state:this.state,source:this.source,zone:this.zone.name,runCount:this.runCount}}}const Di=ke("setTimeout"),ni=ke("Promise"),mi=ke("then");let is,cr=[],ki=!1;function Pr(zi){if(is||Z[ni]&&(is=Z[ni].resolve(0)),is){let ht=is[mi];ht||(ht=is.then),ht.call(is,zi)}else Z[Di](zi,0)}function Wt(zi){0===Ls&&0===cr.length&&Pr(ct),zi&&cr.push(zi)}function ct(){if(!ki){for(ki=!0;cr.length;){const zi=cr;cr=[];for(let ht=0;htUr,onUnhandledError:jr,microtaskDrainDone:jr,scheduleMicroTask:Wt,showUncaughtError:()=>!tt[ke("ignoreConsoleErrorUncaughtError")],patchEventTarget:()=>[],patchOnProperties:jr,patchMethod:()=>jr,bindArguments:()=>[],patchThen:()=>jr,patchMacroTask:()=>jr,patchEventPrototype:()=>jr,isIEOrEdge:()=>!1,getGlobalObjects:()=>{},ObjectDefineProperty:()=>jr,ObjectGetOwnPropertyDescriptor:()=>{},ObjectCreate:()=>{},ArraySlice:()=>[],patchClass:()=>jr,wrapWithCurrentZone:()=>jr,filterProperties:()=>[],attachOriginToPatched:()=>jr,_redefineProperty:()=>jr,patchCallbacks:()=>jr,nativeScheduleMicroTask:Pr};let Ur={parent:null,zone:new tt(null,null)},Do=null,Ls=0;function jr(){}pe("Zone","Zone"),Z.Zone=tt}(globalThis);const Wl=Object.getOwnPropertyDescriptor,Ud=Object.defineProperty,jd=Object.getPrototypeOf,Vd=Object.create,Sb=Array.prototype.slice,gm="addEventListener",$r="removeEventListener",Yl=Zone.__symbol__(gm),_h=Zone.__symbol__($r),Ts="true",Wi="false",Wd=Zone.__symbol__("");function lp(Z,se){return Zone.current.wrap(Z,se)}function vm(Z,se,ye,pe,be){return Zone.current.scheduleMacroTask(Z,se,ye,pe,be)}const Ji=Zone.__symbol__,Uh=typeof window<"u",jh=Uh?window:void 0,gn=Uh&&jh||globalThis,mm="removeAttribute";function Yd(Z,se){for(let ye=Z.length-1;ye>=0;ye--)"function"==typeof Z[ye]&&(Z[ye]=lp(Z[ye],se+"_"+ye));return Z}function hp(Z){return!Z||!1!==Z.writable&&!("function"==typeof Z.get&&typeof Z.set>"u")}const cp=typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope,Vh=!("nw"in gn)&&typeof gn.process<"u"&&"[object process]"==={}.toString.call(gn.process),Qd=!Vh&&!cp&&!(!Uh||!jh.HTMLElement),dp=typeof gn.process<"u"&&"[object process]"==={}.toString.call(gn.process)&&!cp&&!(!Uh||!jh.HTMLElement),Ql={},Wh=function(Z){if(!(Z=Z||gn.event))return;let se=Ql[Z.type];se||(se=Ql[Z.type]=Ji("ON_PROPERTY"+Z.type));const ye=this||Z.target||gn,pe=ye[se];let be;return Qd&&ye===jh&&"error"===Z.type?(be=pe&&pe.call(this,Z.message,Z.filename,Z.lineno,Z.colno,Z.error),!0===be&&Z.preventDefault()):(be=pe&&pe.apply(this,arguments),null!=be&&!be&&Z.preventDefault()),be};function Gl(Z,se,ye){let pe=Wl(Z,se);if(!pe&&ye&&Wl(ye,se)&&(pe={enumerable:!0,configurable:!0}),!pe||!pe.configurable)return;const be=Ji("on"+se+"patched");if(Z.hasOwnProperty(be)&&Z[be])return;delete pe.writable,delete pe.value;const ke=pe.get,at=pe.set,tt=se.slice(2);let At=Ql[tt];At||(At=Ql[tt]=Ji("ON_PROPERTY"+tt)),pe.set=function(Lt){let pt=this;!pt&&Z===gn&&(pt=gn),pt&&("function"==typeof pt[At]&&pt.removeEventListener(tt,Wh),at&&at.call(pt,null),pt[At]=Lt,"function"==typeof Lt&&pt.addEventListener(tt,Wh,!1))},pe.get=function(){let Lt=this;if(!Lt&&Z===gn&&(Lt=gn),!Lt)return null;const pt=Lt[At];if(pt)return pt;if(ke){let Di=ke.call(this);if(Di)return pe.set.call(this,Di),"function"==typeof Lt[mm]&&Lt.removeAttribute(se),Di}return null},Ud(Z,se,pe),Z[be]=!0}function up(Z,se,ye){if(se)for(let pe=0;pefunction(at,tt){const At=ye(at,tt);return At.cbIdx>=0&&"function"==typeof tt[At.cbIdx]?vm(At.name,tt[At.cbIdx],At,be):ke.apply(at,tt)})}function Ia(Z,se){Z[Ji("OriginalDelegate")]=se}let bb=!1,Xd=!1;function Mb(){if(bb)return Xd;bb=!0;try{const Z=jh.navigator.userAgent;(-1!==Z.indexOf("MSIE ")||-1!==Z.indexOf("Trident/")||-1!==Z.indexOf("Edge/"))&&(Xd=!0)}catch{}return Xd}Zone.__load_patch("ZoneAwarePromise",(Z,se,ye)=>{const pe=Object.getOwnPropertyDescriptor,be=Object.defineProperty,at=ye.symbol,tt=[],At=!1!==Z[at("DISABLE_WRAPPING_UNCAUGHT_PROMISE_REJECTION")],Lt=at("Promise"),pt=at("then"),Di="__creationTrace__";ye.onUnhandledError=Ue=>{if(ye.showUncaughtError()){const He=Ue&&Ue.rejection;He?console.error("Unhandled Promise rejection:",He instanceof Error?He.message:He,"; Zone:",Ue.zone.name,"; Task:",Ue.task&&Ue.task.source,"; Value:",He,He instanceof Error?He.stack:void 0):console.error(Ue)}},ye.microtaskDrainDone=()=>{for(;tt.length;){const Ue=tt.shift();try{Ue.zone.runGuarded(()=>{throw Ue.throwOriginal?Ue.rejection:Ue})}catch(He){mi(He)}}};const ni=at("unhandledPromiseRejectionHandler");function mi(Ue){ye.onUnhandledError(Ue);try{const He=se[ni];"function"==typeof He&&He.call(this,Ue)}catch{}}function cr(Ue){return Ue&&Ue.then}function ki(Ue){return Ue}function is(Ue){return F.reject(Ue)}const Pr=at("state"),Wt=at("value"),ct=at("finally"),jn=at("parentPromiseValue"),sr=at("parentPromiseState"),Zr="Promise.then",Pi=null,lt=!0,dr=!1,et=0;function yi(Ue,He){return ge=>{try{cn(Ue,He,ge)}catch(We){cn(Ue,!1,We)}}}const Pt=function(){let Ue=!1;return function(ge){return function(){Ue||(Ue=!0,ge.apply(null,arguments))}}},rs="Promise resolved with itself",_o=at("currentTaskTrace");function cn(Ue,He,ge){const We=Pt();if(Ue===ge)throw new TypeError(rs);if(Ue[Pr]===Pi){let wt=null;try{("object"==typeof ge||"function"==typeof ge)&&(wt=ge&&ge.then)}catch(Xe){return We(()=>{cn(Ue,!1,Xe)})(),Ue}if(He!==dr&&ge instanceof F&&ge.hasOwnProperty(Pr)&&ge.hasOwnProperty(Wt)&&ge[Pr]!==Pi)Do(ge),cn(Ue,ge[Pr],ge[Wt]);else if(He!==dr&&"function"==typeof wt)try{wt.call(ge,We(yi(Ue,He)),We(yi(Ue,!1)))}catch(Xe){We(()=>{cn(Ue,!1,Xe)})()}else{Ue[Pr]=He;const Xe=Ue[Wt];if(Ue[Wt]=ge,Ue[ct]===ct&&He===lt&&(Ue[Pr]=Ue[sr],Ue[Wt]=Ue[jn]),He===dr&&ge instanceof Error){const mt=se.currentTask&&se.currentTask.data&&se.currentTask.data[Di];mt&&be(ge,_o,{configurable:!0,enumerable:!1,writable:!0,value:mt})}for(let mt=0;mt{try{const dt=Ue[Wt],qt=!!ge&&ct===ge[ct];qt&&(ge[jn]=dt,ge[sr]=Xe);const li=He.run(mt,void 0,qt&&mt!==is&&mt!==ki?[]:[dt]);cn(ge,!0,li)}catch(dt){cn(ge,!1,dt)}},ge)}const zi=function(){},ht=Z.AggregateError;class F{static toString(){return"function ZoneAwarePromise() { [native code] }"}static resolve(He){return He instanceof F?He:cn(new this(null),lt,He)}static reject(He){return cn(new this(null),dr,He)}static withResolvers(){const He={};return He.promise=new F((ge,We)=>{He.resolve=ge,He.reject=We}),He}static any(He){if(!He||"function"!=typeof He[Symbol.iterator])return Promise.reject(new ht([],"All promises were rejected"));const ge=[];let We=0;try{for(let mt of He)We++,ge.push(F.resolve(mt))}catch{return Promise.reject(new ht([],"All promises were rejected"))}if(0===We)return Promise.reject(new ht([],"All promises were rejected"));let wt=!1;const Xe=[];return new F((mt,dt)=>{for(let qt=0;qt{wt||(wt=!0,mt(li))},li=>{Xe.push(li),We--,0===We&&(wt=!0,dt(new ht(Xe,"All promises were rejected")))})})}static race(He){let ge,We,wt=new this((dt,qt)=>{ge=dt,We=qt});function Xe(dt){ge(dt)}function mt(dt){We(dt)}for(let dt of He)cr(dt)||(dt=this.resolve(dt)),dt.then(Xe,mt);return wt}static all(He){return F.allWithCallback(He)}static allSettled(He){return(this&&this.prototype instanceof F?this:F).allWithCallback(He,{thenCallback:We=>({status:"fulfilled",value:We}),errorCallback:We=>({status:"rejected",reason:We})})}static allWithCallback(He,ge){let We,wt,Xe=new this((li,ur)=>{We=li,wt=ur}),mt=2,dt=0;const qt=[];for(let li of He){cr(li)||(li=this.resolve(li));const ur=dt;try{li.then(ir=>{qt[ur]=ge?ge.thenCallback(ir):ir,mt--,0===mt&&We(qt)},ir=>{ge?(qt[ur]=ge.errorCallback(ir),mt--,0===mt&&We(qt)):wt(ir)})}catch(ir){wt(ir)}mt++,dt++}return mt-=2,0===mt&&We(qt),Xe}constructor(He){const ge=this;if(!(ge instanceof F))throw new Error("Must be an instanceof Promise.");ge[Pr]=Pi,ge[Wt]=[];try{const We=Pt();He&&He(We(yi(ge,lt)),We(yi(ge,dr)))}catch(We){cn(ge,!1,We)}}get[Symbol.toStringTag](){return"Promise"}get[Symbol.species](){return F}then(He,ge){let We=this.constructor?.[Symbol.species];(!We||"function"!=typeof We)&&(We=this.constructor||F);const wt=new We(zi),Xe=se.current;return this[Pr]==Pi?this[Wt].push(Xe,wt,He,ge):Ls(this,Xe,wt,He,ge),wt}catch(He){return this.then(null,He)}finally(He){let ge=this.constructor?.[Symbol.species];(!ge||"function"!=typeof ge)&&(ge=F);const We=new ge(zi);We[ct]=ct;const wt=se.current;return this[Pr]==Pi?this[Wt].push(wt,We,He,He):Ls(this,wt,We,He,He),We}}F.resolve=F.resolve,F.reject=F.reject,F.race=F.race,F.all=F.all;const ae=Z[Lt]=Z.Promise;Z.Promise=F;const Et=at("thenPatched");function Xt(Ue){const He=Ue.prototype,ge=pe(He,"then");if(ge&&(!1===ge.writable||!ge.configurable))return;const We=He.then;He[pt]=We,Ue.prototype.then=function(wt,Xe){return new F((dt,qt)=>{We.call(this,dt,qt)}).then(wt,Xe)},Ue[Et]=!0}return ye.patchThen=Xt,ae&&(Xt(ae),tl(Z,"fetch",Ue=>function Vn(Ue){return function(He,ge){let We=Ue.apply(He,ge);if(We instanceof F)return We;let wt=We.constructor;return wt[Et]||Xt(wt),We}}(Ue))),Promise[se.__symbol__("uncaughtPromiseErrors")]=tt,F}),Zone.__load_patch("toString",Z=>{const se=Function.prototype.toString,ye=Ji("OriginalDelegate"),pe=Ji("Promise"),be=Ji("Error"),ke=function(){if("function"==typeof this){const Lt=this[ye];if(Lt)return"function"==typeof Lt?se.call(Lt):Object.prototype.toString.call(Lt);if(this===Promise){const pt=Z[pe];if(pt)return se.call(pt)}if(this===Error){const pt=Z[be];if(pt)return se.call(pt)}}return se.call(this)};ke[ye]=se,Function.prototype.toString=ke;const at=Object.prototype.toString;Object.prototype.toString=function(){return"function"==typeof Promise&&this instanceof Promise?"[object Promise]":at.call(this)}});let il=!1;if(typeof window<"u")try{const Z=Object.defineProperty({},"passive",{get:function(){il=!0}});window.addEventListener("test",Z,Z),window.removeEventListener("test",Z,Z)}catch{il=!1}const PT={useG:!0},Co={},wb={},Im=new RegExp("^"+Wd+"(\\w+)(true|false)$"),Cb=Ji("propagationStopped");function bm(Z,se){const ye=(se?se(Z):Z)+Wi,pe=(se?se(Z):Z)+Ts,be=Wd+ye,ke=Wd+pe;Co[Z]={},Co[Z][Wi]=be,Co[Z][Ts]=ke}function Eb(Z,se,ye,pe){const be=pe&&pe.add||gm,ke=pe&&pe.rm||$r,at=pe&&pe.listeners||"eventListeners",tt=pe&&pe.rmAll||"removeAllListeners",At=Ji(be),Lt="."+be+":",pt="prependListener",Di="."+pt+":",ni=function(Wt,ct,jn){if(Wt.isRemoved)return;const sr=Wt.callback;let Zr;"object"==typeof sr&&sr.handleEvent&&(Wt.callback=lt=>sr.handleEvent(lt),Wt.originalDelegate=sr);try{Wt.invoke(Wt,ct,[jn])}catch(lt){Zr=lt}const Pi=Wt.options;return Pi&&"object"==typeof Pi&&Pi.once&&ct[ke].call(ct,jn.type,Wt.originalDelegate?Wt.originalDelegate:Wt.callback,Pi),Zr};function mi(Wt,ct,jn){if(!(ct=ct||Z.event))return;const sr=Wt||ct.target||Z,Zr=sr[Co[ct.type][jn?Ts:Wi]];if(Zr){const Pi=[];if(1===Zr.length){const lt=ni(Zr[0],sr,ct);lt&&Pi.push(lt)}else{const lt=Zr.slice();for(let dr=0;dr{throw dr})}}}const cr=function(Wt){return mi(this,Wt,!1)},ki=function(Wt){return mi(this,Wt,!0)};function is(Wt,ct){if(!Wt)return!1;let jn=!0;ct&&void 0!==ct.useG&&(jn=ct.useG);const sr=ct&&ct.vh;let Zr=!0;ct&&void 0!==ct.chkDup&&(Zr=ct.chkDup);let Pi=!1;ct&&void 0!==ct.rt&&(Pi=ct.rt);let lt=Wt;for(;lt&&!lt.hasOwnProperty(be);)lt=jd(lt);if(!lt&&Wt[be]&&(lt=Wt),!lt||lt[At])return!1;const dr=ct&&ct.eventNameToString,et={},yi=lt[At]=lt[be],Pt=lt[Ji(ke)]=lt[ke],rs=lt[Ji(at)]=lt[at],_o=lt[Ji(tt)]=lt[tt];let cn;ct&&ct.prepend&&(cn=lt[Ji(ct.prepend)]=lt[ct.prepend]);const F=jn?function(ge){if(!et.isExisting)return yi.call(et.target,et.eventName,et.capture?ki:cr,et.options)}:function(ge){return yi.call(et.target,et.eventName,ge.invoke,et.options)},ae=jn?function(ge){if(!ge.isRemoved){const We=Co[ge.eventName];let wt;We&&(wt=We[ge.capture?Ts:Wi]);const Xe=wt&&ge.target[wt];if(Xe)for(let mt=0;mt{Vo.zone.cancelTask(Vo)},{once:!0})),et.target=null,Fc&&(Fc.taskData=null),$d&&(Tn.once=!0),!il&&"boolean"==typeof Vo.options||(Vo.options=Tn),Vo.target=qt,Vo.capture=Zl,Vo.eventName=li,ir&&(Vo.originalDelegate=ur),dt?jo.unshift(Vo):jo.push(Vo),mt?qt:void 0}};return lt[be]=He(yi,Lt,F,ae,Pi),cn&&(lt[pt]=He(cn,Di,function(ge){return cn.call(et.target,et.eventName,ge.invoke,et.options)},ae,Pi,!0)),lt[ke]=function(){const ge=this||Z;let We=arguments[0];ct&&ct.transferEventName&&(We=ct.transferEventName(We));const wt=arguments[2],Xe=!!wt&&("boolean"==typeof wt||wt.capture),mt=arguments[1];if(!mt)return Pt.apply(this,arguments);if(sr&&!sr(Pt,mt,ge,arguments))return;const dt=Co[We];let qt;dt&&(qt=dt[Xe?Ts:Wi]);const li=qt&&ge[qt];if(li)for(let ur=0;urfunction(be,ke){be[Cb]=!0,pe&&pe.apply(be,ke)})}function xb(Z,se,ye,pe,be){const ke=Zone.__symbol__(pe);if(se[ke])return;const at=se[ke]=se[pe];se[pe]=function(tt,At,Lt){return At&&At.prototype&&be.forEach(function(pt){const Di=`${ye}.${pe}::`+pt,ni=At.prototype;try{if(ni.hasOwnProperty(pt)){const mi=Z.ObjectGetOwnPropertyDescriptor(ni,pt);mi&&mi.value?(mi.value=Z.wrapWithCurrentZone(mi.value,Di),Z._redefineProperty(At.prototype,pt,mi)):ni[pt]&&(ni[pt]=Z.wrapWithCurrentZone(ni[pt],Di))}else ni[pt]&&(ni[pt]=Z.wrapWithCurrentZone(ni[pt],Di))}catch{}}),at.call(se,tt,At,Lt)},Z.attachOriginToPatched(se[pe],at)}function Tb(Z,se,ye){if(!ye||0===ye.length)return se;const pe=ye.filter(ke=>ke.target===Z);if(!pe||0===pe.length)return se;const be=pe[0].ignoreProperties;return se.filter(ke=>-1===be.indexOf(ke))}function Eo(Z,se,ye,pe){Z&&up(Z,Tb(Z,se,ye),pe)}function qd(Z){return Object.getOwnPropertyNames(Z).filter(se=>se.startsWith("on")&&se.length>2).map(se=>se.substring(2))}Zone.__load_patch("util",(Z,se,ye)=>{const pe=qd(Z);ye.patchOnProperties=up,ye.patchMethod=tl,ye.bindArguments=Yd,ye.patchMacroTask=Ib;const be=se.__symbol__("BLACK_LISTED_EVENTS"),ke=se.__symbol__("UNPATCHED_EVENTS");Z[ke]&&(Z[be]=Z[ke]),Z[be]&&(se[be]=se[ke]=Z[be]),ye.patchEventPrototype=Mm,ye.patchEventTarget=Eb,ye.isIEOrEdge=Mb,ye.ObjectDefineProperty=Ud,ye.ObjectGetOwnPropertyDescriptor=Wl,ye.ObjectCreate=Vd,ye.ArraySlice=Sb,ye.patchClass=Gd,ye.wrapWithCurrentZone=lp,ye.filterProperties=Tb,ye.attachOriginToPatched=Ia,ye._redefineProperty=Object.defineProperty,ye.patchCallbacks=xb,ye.getGlobalObjects=()=>({globalSources:wb,zoneSymbolEventNames:Co,eventNames:pe,isBrowser:Qd,isMix:dp,isNode:Vh,TRUE_STR:Ts,FALSE_STR:Wi,ZONE_SYMBOL_PREFIX:Wd,ADD_EVENT_LISTENER_STR:gm,REMOVE_EVENT_LISTENER_STR:$r})});const As=Ji("zoneTask");function Xl(Z,se,ye,pe){let be=null,ke=null;ye+=pe;const at={};function tt(Lt){const pt=Lt.data;return pt.args[0]=function(){return Lt.invoke.apply(this,arguments)},pt.handleId=be.apply(Z,pt.args),Lt}function At(Lt){return ke.call(Z,Lt.data.handleId)}be=tl(Z,se+=pe,Lt=>function(pt,Di){if("function"==typeof Di[0]){const ni={isPeriodic:"Interval"===pe,delay:"Timeout"===pe||"Interval"===pe?Di[1]||0:void 0,args:Di},mi=Di[0];Di[0]=function(){try{return mi.apply(this,arguments)}finally{ni.isPeriodic||("number"==typeof ni.handleId?delete at[ni.handleId]:ni.handleId&&(ni.handleId[As]=null))}};const cr=vm(se,Di[0],ni,tt,At);if(!cr)return cr;const ki=cr.data.handleId;return"number"==typeof ki?at[ki]=cr:ki&&(ki[As]=cr),ki&&ki.ref&&ki.unref&&"function"==typeof ki.ref&&"function"==typeof ki.unref&&(cr.ref=ki.ref.bind(ki),cr.unref=ki.unref.bind(ki)),"number"==typeof ki||ki?ki:cr}return Lt.apply(Z,Di)}),ke=tl(Z,ye,Lt=>function(pt,Di){const ni=Di[0];let mi;"number"==typeof ni?mi=at[ni]:(mi=ni&&ni[As],mi||(mi=ni)),mi&&"string"==typeof mi.type?"notScheduled"!==mi.state&&(mi.cancelFn&&mi.data.isPeriodic||0===mi.runCount)&&("number"==typeof ni?delete at[ni]:ni&&(ni[As]=null),mi.zone.cancelTask(mi)):Lt.apply(Z,Di)})}Zone.__load_patch("legacy",Z=>{const se=Z[Zone.__symbol__("legacyPatch")];se&&se()}),Zone.__load_patch("timers",Z=>{const ye="clear";Xl(Z,"set",ye,"Timeout"),Xl(Z,"set",ye,"Interval"),Xl(Z,"set",ye,"Immediate")}),Zone.__load_patch("requestAnimationFrame",Z=>{Xl(Z,"request","cancel","AnimationFrame"),Xl(Z,"mozRequest","mozCancel","AnimationFrame"),Xl(Z,"webkitRequest","webkitCancel","AnimationFrame")}),Zone.__load_patch("blocking",(Z,se)=>{const ye=["alert","prompt","confirm"];for(let pe=0;pefunction(At,Lt){return se.current.run(ke,Z,Lt,tt)})}),Zone.__load_patch("EventTarget",(Z,se,ye)=>{(function ql(Z,se){se.patchEventPrototype(Z,se)})(Z,ye),function Cm(Z,se){if(Zone[se.symbol("patchEventTarget")])return;const{eventNames:ye,zoneSymbolEventNames:pe,TRUE_STR:be,FALSE_STR:ke,ZONE_SYMBOL_PREFIX:at}=se.getGlobalObjects();for(let At=0;At{Gd("MutationObserver"),Gd("WebKitMutationObserver")}),Zone.__load_patch("IntersectionObserver",(Z,se,ye)=>{Gd("IntersectionObserver")}),Zone.__load_patch("FileReader",(Z,se,ye)=>{Gd("FileReader")}),Zone.__load_patch("on_property",(Z,se,ye)=>{!function fp(Z,se){if(Vh&&!dp||Zone[Z.symbol("patchEvents")])return;const ye=se.__Zone_ignore_on_properties;let pe=[];if(Qd){const be=window;pe=pe.concat(["Document","SVGElement","Element","HTMLElement","HTMLBodyElement","HTMLMediaElement","HTMLFrameSetElement","HTMLFrameElement","HTMLIFrameElement","HTMLMarqueeElement","Worker"]);const ke=function Sm(){try{const Z=jh.navigator.userAgent;if(-1!==Z.indexOf("MSIE ")||-1!==Z.indexOf("Trident/"))return!0}catch{}return!1}()?[{target:be,ignoreProperties:["error"]}]:[];Eo(be,qd(be),ye&&ye.concat(ke),jd(be))}pe=pe.concat(["XMLHttpRequest","XMLHttpRequestEventTarget","IDBIndex","IDBRequest","IDBOpenDBRequest","IDBDatabase","IDBTransaction","IDBCursor","WebSocket"]);for(let be=0;be{!function wm(Z,se){const{isBrowser:ye,isMix:pe}=se.getGlobalObjects();(ye||pe)&&Z.customElements&&"customElements"in Z&&se.patchCallbacks(se,Z.customElements,"customElements","define",["connectedCallback","disconnectedCallback","adoptedCallback","attributeChangedCallback"])}(Z,ye)}),Zone.__load_patch("XHR",(Z,se)=>{!function At(Lt){const pt=Lt.XMLHttpRequest;if(!pt)return;const Di=pt.prototype;let mi=Di[Yl],cr=Di[_h];if(!mi){const et=Lt.XMLHttpRequestEventTarget;if(et){const yi=et.prototype;mi=yi[Yl],cr=yi[_h]}}const ki="readystatechange",is="scheduled";function Pr(et){const yi=et.data,Pt=yi.target;Pt[ke]=!1,Pt[tt]=!1;const rs=Pt[be];mi||(mi=Pt[Yl],cr=Pt[_h]),rs&&cr.call(Pt,ki,rs);const _o=Pt[be]=()=>{if(Pt.readyState===Pt.DONE)if(!yi.aborted&&Pt[ke]&&et.state===is){const Ur=Pt[se.__symbol__("loadfalse")];if(0!==Pt.status&&Ur&&Ur.length>0){const Do=et.invoke;et.invoke=function(){const Ls=Pt[se.__symbol__("loadfalse")];for(let jr=0;jrfunction(et,yi){return et[pe]=0==yi[2],et[at]=yi[1],jn.apply(et,yi)}),Zr=Ji("fetchTaskAborting"),Pi=Ji("fetchTaskScheduling"),lt=tl(Di,"send",()=>function(et,yi){if(!0===se.current[Pi]||et[pe])return lt.apply(et,yi);{const Pt={target:et,url:et[at],isPeriodic:!1,args:yi,aborted:!1},rs=vm("XMLHttpRequest.send",Wt,Pt,Pr,ct);et&&!0===et[tt]&&!Pt.aborted&&rs.state===is&&rs.invoke()}}),dr=tl(Di,"abort",()=>function(et,yi){const Pt=function ni(et){return et[ye]}(et);if(Pt&&"string"==typeof Pt.type){if(null==Pt.cancelFn||Pt.data&&Pt.data.aborted)return;Pt.zone.cancelTask(Pt)}else if(!0===se.current[Zr])return dr.apply(et,yi)})}(Z);const ye=Ji("xhrTask"),pe=Ji("xhrSync"),be=Ji("xhrListener"),ke=Ji("xhrScheduled"),at=Ji("xhrURL"),tt=Ji("xhrErrorBeforeScheduled")}),Zone.__load_patch("geolocation",Z=>{Z.navigator&&Z.navigator.geolocation&&function ym(Z,se){const ye=Z.constructor.name;for(let pe=0;pe{const At=function(){return tt.apply(this,Yd(arguments,ye+"."+be))};return Ia(At,tt),At})(ke)}}}(Z.navigator.geolocation,["getCurrentPosition","watchPosition"])}),Zone.__load_patch("PromiseRejectionEvent",(Z,se)=>{function ye(pe){return function(be){Db(Z,pe).forEach(at=>{const tt=Z.PromiseRejectionEvent;if(tt){const At=new tt(pe,{promise:be.promise,reason:be.rejection});at.invoke(At)}})}}Z.PromiseRejectionEvent&&(se[Ji("unhandledPromiseRejectionHandler")]=ye("unhandledrejection"),se[Ji("rejectionHandledHandler")]=ye("rejectionhandled"))}),Zone.__load_patch("queueMicrotask",(Z,se,ye)=>{!function pp(Z,se){se.patchMethod(Z,"queueMicrotask",ye=>function(pe,be){Zone.current.scheduleMicroTask("queueMicrotask",be[0])})}(Z,ye)})}},Wl=>{Wl(Wl.s=51)}]); \ No newline at end of file diff --git a/ej2-angular/samples/diagram/layers/layers-cs5/main.d56ef44cc2253cac.js b/ej2-angular/samples/diagram/layers/layers-cs5/main.d56ef44cc2253cac.js deleted file mode 100644 index 710382c0c3..0000000000 --- a/ej2-angular/samples/diagram/layers/layers-cs5/main.d56ef44cc2253cac.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";(self.webpackChunksyncfusion_component=self.webpackChunksyncfusion_component||[]).push([[179],{51:(_l,_d,Ud)=>{let $r=null,Fh=1;const Ts=Symbol("SIGNAL");function Wi(n){const t=$r;return $r=n,t}function gn(n){if((!Vh(n)||n.dirty)&&(n.dirty||n.lastCleanEpoch!==Fh)){if(!n.producerMustRecompute(n)&&!jh(n))return n.dirty=!1,void(n.lastCleanEpoch=Fh);n.producerRecomputeValue(n),n.dirty=!1,n.lastCleanEpoch=Fh}}function jh(n){Vl(n);for(let t=0;t0}function Vl(n){n.producerNode??=[],n.producerIndexOfThis??=[],n.producerLastReadVersion??=[]}let Gd=null;function Eo(n){return"function"==typeof n}function Xd(n){const e=n(i=>{Error.call(i),i.stack=(new Error).stack});return e.prototype=Object.create(Error.prototype),e.prototype.constructor=e,e}const pf=Xd(n=>function(e){n(this),this.message=e?`${e.length} errors occurred during unsubscription:\n${e.map((i,r)=>`${r+1}) ${i.toString()}`).join("\n ")}`:"",this.name="UnsubscriptionError",this.errors=e});function ff(n,t){if(n){const e=n.indexOf(t);0<=e&&n.splice(e,1)}}class As{constructor(t){this.initialTeardown=t,this.closed=!1,this._parentage=null,this._finalizers=null}unsubscribe(){let t;if(!this.closed){this.closed=!0;const{_parentage:e}=this;if(e)if(this._parentage=null,Array.isArray(e))for(const s of e)s.remove(this);else e.remove(this);const{initialTeardown:i}=this;if(Eo(i))try{i()}catch(s){t=s instanceof pf?s.errors:[s]}const{_finalizers:r}=this;if(r){this._finalizers=null;for(const s of r)try{wm(s)}catch(o){t=t??[],o instanceof pf?t=[...t,...o.errors]:t.push(o)}}if(t)throw new pf(t)}}add(t){var e;if(t&&t!==this)if(this.closed)wm(t);else{if(t instanceof As){if(t.closed||t._hasParent(this))return;t._addParent(this)}(this._finalizers=null!==(e=this._finalizers)&&void 0!==e?e:[]).push(t)}}_hasParent(t){const{_parentage:e}=this;return e===t||Array.isArray(e)&&e.includes(t)}_addParent(t){const{_parentage:e}=this;this._parentage=Array.isArray(e)?(e.push(t),e):e?[e,t]:t}_removeParent(t){const{_parentage:e}=this;e===t?this._parentage=null:Array.isArray(e)&&ff(e,t)}remove(t){const{_finalizers:e}=this;e&&ff(e,t),t instanceof As&&t._removeParent(this)}}As.EMPTY=(()=>{const n=new As;return n.closed=!0,n})();const Wl=As.EMPTY;function Mm(n){return n instanceof As||n&&"closed"in n&&Eo(n.remove)&&Eo(n.add)&&Eo(n.unsubscribe)}function wm(n){Eo(n)?n():n.unsubscribe()}const Yl={onUnhandledError:null,onStoppedNotification:null,Promise:void 0,useDeprecatedSynchronousErrorHandling:!1,useDeprecatedNextContext:!1},Z={setTimeout(n,t,...e){const{delegate:i}=Z;return i?.setTimeout?i.setTimeout(n,t,...e):setTimeout(n,t,...e)},clearTimeout(n){const{delegate:t}=Z;return(t?.clearTimeout||clearTimeout)(n)},delegate:void 0};function ye(){}const fe=at("C",void 0,void 0);function at(n,t,e){return{kind:n,value:t,error:e}}let tt=null;function At(n){if(Yl.useDeprecatedSynchronousErrorHandling){const t=!tt;if(t&&(tt={errorThrown:!1,error:null}),n(),t){const{errorThrown:e,error:i}=tt;if(tt=null,e)throw i}}else n()}class ft extends As{constructor(t){super(),this.isStopped=!1,t?(this.destination=t,Mm(t)&&t.add(this)):this.destination=Wt}static create(t,e,i){return new cr(t,e,i)}next(t){this.isStopped?kr(function ke(n){return at("N",n,void 0)}(t),this):this._next(t)}error(t){this.isStopped?kr(function be(n){return at("E",void 0,n)}(t),this):(this.isStopped=!0,this._error(t))}complete(){this.isStopped?kr(fe,this):(this.isStopped=!0,this._complete())}unsubscribe(){this.closed||(this.isStopped=!0,super.unsubscribe(),this.destination=null)}_next(t){this.destination.next(t)}_error(t){try{this.destination.error(t)}finally{this.unsubscribe()}}_complete(){try{this.destination.complete()}finally{this.unsubscribe()}}}const Ei=Function.prototype.bind;function ti(n,t){return Ei.call(n,t)}class gi{constructor(t){this.partialObserver=t}next(t){const{partialObserver:e}=this;if(e.next)try{e.next(t)}catch(i){Oi(i)}}error(t){const{partialObserver:e}=this;if(e.error)try{e.error(t)}catch(i){Oi(i)}else Oi(t)}complete(){const{partialObserver:t}=this;if(t.complete)try{t.complete()}catch(e){Oi(e)}}}class cr extends ft{constructor(t,e,i){let r;if(super(),Eo(t)||!t)r={next:t??void 0,error:e??void 0,complete:i??void 0};else{let s;this&&Yl.useDeprecatedNextContext?(s=Object.create(t),s.unsubscribe=()=>this.unsubscribe(),r={next:t.next&&ti(t.next,s),error:t.error&&ti(t.error,s),complete:t.complete&&ti(t.complete,s)}):r=t}this.destination=new gi(r)}}function Oi(n){Yl.useDeprecatedSynchronousErrorHandling?function Lt(n){Yl.useDeprecatedSynchronousErrorHandling&&tt&&(tt.errorThrown=!0,tt.error=n)}(n):function se(n){Z.setTimeout(()=>{const{onUnhandledError:t}=Yl;if(!t)throw n;t(n)})}(n)}function kr(n,t){const{onStoppedNotification:e}=Yl;e&&Z.setTimeout(()=>e(n,t))}const Wt={closed:!0,next:ye,error:function es(n){throw n},complete:ye},ct="function"==typeof Symbol&&Symbol.observable||"@@observable";function _n(n){return n}let ki=(()=>{class n{constructor(e){e&&(this._subscribe=e)}lift(e){const i=new n;return i.source=this,i.operator=e,i}subscribe(e,i,r){const s=function et(n){return n&&n instanceof ft||function dr(n){return n&&Eo(n.next)&&Eo(n.error)&&Eo(n.complete)}(n)&&Mm(n)}(e)?e:new cr(e,i,r);return At(()=>{const{operator:o,source:a}=this;s.add(o?o.call(s,a):a?this._subscribe(s):this._trySubscribe(s))}),s}_trySubscribe(e){try{return this._subscribe(e)}catch(i){e.error(i)}}forEach(e,i){return new(i=lt(i))((r,s)=>{const o=new cr({next:a=>{try{e(a)}catch(l){s(l),o.unsubscribe()}},error:s,complete:r});this.subscribe(o)})}_subscribe(e){var i;return null===(i=this.source)||void 0===i?void 0:i.subscribe(e)}[ct](){return this}pipe(...e){return function Zr(n){return 0===n.length?_n:1===n.length?n[0]:function(e){return n.reduce((i,r)=>r(i),e)}}(e)(this)}toPromise(e){return new(e=lt(e))((i,r)=>{let s;this.subscribe(o=>s=o,o=>r(o),()=>i(s))})}}return n.create=t=>new n(t),n})();function lt(n){var t;return null!==(t=n??Yl.Promise)&&void 0!==t?t:Promise}const vi=Xd(n=>function(){n(this),this.name="ObjectUnsubscribedError",this.message="object unsubscribed"});let Pt=(()=>{class n extends ki{constructor(){super(),this.closed=!1,this.currentObservers=null,this.observers=[],this.isStopped=!1,this.hasError=!1,this.thrownError=null}lift(e){const i=new ts(this,this);return i.operator=e,i}_throwIfClosed(){if(this.closed)throw new vi}next(e){At(()=>{if(this._throwIfClosed(),!this.isStopped){this.currentObservers||(this.currentObservers=Array.from(this.observers));for(const i of this.currentObservers)i.next(e)}})}error(e){At(()=>{if(this._throwIfClosed(),!this.isStopped){this.hasError=this.isStopped=!0,this.thrownError=e;const{observers:i}=this;for(;i.length;)i.shift().error(e)}})}complete(){At(()=>{if(this._throwIfClosed(),!this.isStopped){this.isStopped=!0;const{observers:e}=this;for(;e.length;)e.shift().complete()}})}unsubscribe(){this.isStopped=this.closed=!0,this.observers=this.currentObservers=null}get observed(){var e;return(null===(e=this.observers)||void 0===e?void 0:e.length)>0}_trySubscribe(e){return this._throwIfClosed(),super._trySubscribe(e)}_subscribe(e){return this._throwIfClosed(),this._checkFinalizedStatuses(e),this._innerSubscribe(e)}_innerSubscribe(e){const{hasError:i,isStopped:r,observers:s}=this;return i||r?Wl:(this.currentObservers=null,s.push(e),new As(()=>{this.currentObservers=null,ff(s,e)}))}_checkFinalizedStatuses(e){const{hasError:i,thrownError:r,isStopped:s}=this;i?e.error(r):s&&e.complete()}asObservable(){const e=new ki;return e.source=this,e}}return n.create=(t,e)=>new ts(t,e),n})();class ts extends Pt{constructor(t,e){super(),this.destination=t,this.source=e}next(t){var e,i;null===(i=null===(e=this.destination)||void 0===e?void 0:e.next)||void 0===i||i.call(e,t)}error(t){var e,i;null===(i=null===(e=this.destination)||void 0===e?void 0:e.error)||void 0===i||i.call(e,t)}complete(){var t,e;null===(e=null===(t=this.destination)||void 0===t?void 0:t.complete)||void 0===e||e.call(t)}_subscribe(t){var e,i;return null!==(i=null===(e=this.source)||void 0===e?void 0:e.subscribe(t))&&void 0!==i?i:Wl}}class _o extends Pt{constructor(t){super(),this._value=t}get value(){return this.getValue()}_subscribe(t){const e=super._subscribe(t);return!e.closed&&t.next(this._value),e}getValue(){const{hasError:t,thrownError:e,_value:i}=this;if(t)throw e;return this._throwIfClosed(),i}next(t){super.next(this._value=t)}}class Ls extends ft{constructor(t,e,i,r,s,o){super(t),this.onFinalize=s,this.shouldUnsubscribe=o,this._next=e?function(a){try{e(a)}catch(l){t.error(l)}}:super._next,this._error=r?function(a){try{r(a)}catch(l){t.error(l)}finally{this.unsubscribe()}}:super._error,this._complete=i?function(){try{i()}catch(a){t.error(a)}finally{this.unsubscribe()}}:super._complete}unsubscribe(){var t;if(!this.shouldUnsubscribe||this.shouldUnsubscribe()){const{closed:e}=this;super.unsubscribe(),!e&&(null===(t=this.onFinalize)||void 0===t||t.call(this))}}}function jr(n,t){return function Ur(n){return t=>{if(function cn(n){return Eo(n?.lift)}(t))return t.lift(function(e){try{return n(e,this)}catch(i){this.error(i)}});throw new TypeError("Unable to lift unknown Observable type")}}((e,i)=>{let r=0;e.subscribe(function Do(n,t,e,i,r){return new Ls(n,t,e,i,r)}(i,s=>{i.next(n.call(t,s,r++))}))})}class F extends Error{constructor(t,e){super(function ae(n,t){return`NG0${Math.abs(n)}${t?": "+t:""}`}(t,e)),this.code=t}}function Xe(n){for(let t in n)if(n[t]===Xe)return t;throw Error("Could not find renamed property on target object.")}function mt(n,t){for(const e in t)t.hasOwnProperty(e)&&!n.hasOwnProperty(e)&&(n[e]=t[e])}function dt(n){if("string"==typeof n)return n;if(Array.isArray(n))return"["+n.map(dt).join(", ")+"]";if(null==n)return""+n;if(n.overriddenName)return`${n.overriddenName}`;if(n.name)return`${n.name}`;const t=n.toString();if(null==t)return""+t;const e=t.indexOf("\n");return-1===e?t:t.substring(0,e)}function qt(n,t){return null==n||""===n?null===t?"":t:null==t||""===t?n:n+" "+t}const ur=Xe({__forward_ref__:Xe});function ir(n){return n.__forward_ref__=ir,n.toString=function(){return dt(this())},n}function vt(n){return function Dn(n){return"function"==typeof n&&n.hasOwnProperty(ur)&&n.__forward_ref__===ir}(n)?n():n}function Ql(n){return n&&!!n.\u0275providers}const Gl=Xe({\u0275cmp:Xe}),qd=Xe({\u0275dir:Xe}),gf=Xe({\u0275pipe:Xe}),Uo=Xe({\u0275fac:Xe}),jo=Xe({__NG_ELEMENT_ID__:Xe}),vf=Xe({__NG_ENV_ID__:Xe});function zi(n){return"function"==typeof n?n.name||n.toString():"object"==typeof n&&null!=n&&"function"==typeof n.type?n.type.name||n.type.toString():function Nt(n){return"string"==typeof n?n:null==n?"":String(n)}(n)}function Tb(n,t){throw new F(-201,!1)}function ro(n,t){null==n&&function zt(n,t,e,i){throw new Error(`ASSERTION ERROR: ${n}`+(null==i?"":` [Expected=> ${e} ${i} ${t} <=Actual]`))}(t,n,null,"!=")}function Yi(n){return{token:n.token,providedIn:n.providedIn||null,factory:n.factory,value:void 0}}function mf(n){return{providers:n.providers||[],imports:n.imports||[]}}function Cm(n){return zT(n,Dm)||zT(n,RT)}function zT(n,t){return n.hasOwnProperty(t)?n[t]:null}function Em(n){return n&&(n.hasOwnProperty(Ab)||n.hasOwnProperty(x_))?n[Ab]:null}const Dm=Xe({\u0275prov:Xe}),Ab=Xe({\u0275inj:Xe}),RT=Xe({ngInjectableDef:Xe}),x_=Xe({ngInjectorDef:Xe});var Di=function(n){return n[n.Default=0]="Default",n[n.Host=1]="Host",n[n.Self=2]="Self",n[n.SkipSelf=4]="SkipSelf",n[n.Optional=8]="Optional",n}(Di||{});let Lb;function no(n){const t=Lb;return Lb=n,t}function BT(n,t,e){const i=Cm(n);return i&&"root"==i.providedIn?void 0===i.value?i.value=i.factory():i.value:e&Di.Optional?null:void 0!==t?t:void Tb()}const rr=globalThis;class Ht{constructor(t,e){this._desc=t,this.ngMetadataName="InjectionToken",this.\u0275prov=void 0,"number"==typeof e?this.__NG_ELEMENT_ID__=e:void 0!==e&&(this.\u0275prov=Yi({token:this,providedIn:e.providedIn||"root",factory:e.factory}))}get multi(){return this}toString(){return`InjectionToken ${this._desc}`}}const yf={},zb="__NG_DI_FLAG__",xm="ngTempTokenPath",L_=/\n/gm,_T="__source";let Zd;function Qh(n){const t=Zd;return Zd=n,t}function k_(n,t=Di.Default){if(void 0===Zd)throw new F(-203,!1);return null===Zd?BT(n,void 0,t):Zd.get(n,t&Di.Optional?null:void 0,t)}function Fi(n,t=Di.Default){return(function HT(){return Lb}()||k_)(vt(n),t)}function Ri(n,t=Di.Default){return Fi(n,Tm(t))}function Tm(n){return typeof n>"u"||"number"==typeof n?n:0|(n.optional&&8)|(n.host&&1)|(n.self&&2)|(n.skipSelf&&4)}function Rb(n){const t=[];for(let e=0;et){o=s-1;break}}}for(;ss?"":r[d+1].toLowerCase();const p=8&i?u:null;if(p&&-1!==jT(p,h,0)||2&i&&h!==u){if(ba(i))return!1;o=!0}}}}else{if(!o&&!ba(i)&&!ba(l))return!1;if(o&&ba(l))continue;o=!1,i=l|1&i}}return ba(i)||o}function ba(n){return 0==(1&n)}function __(n,t,e,i){if(null===t)return-1;let r=0;if(i||!e){let s=!1;for(;r-1)for(e++;e0?'="'+a+'"':"")+"]"}else 8&i?r+="."+o:4&i&&(r+=" "+o);else""!==r&&!ba(o)&&(t+=qT(s,r),r=""),i=o,s=s||!ba(i);e++}return""!==r&&(t+=qT(s,r)),t}function Bb(n){return Xl(()=>{const t=ZT(n),e={...t,decls:n.decls,vars:n.vars,template:n.template,consts:n.consts||null,ngContentSelectors:n.ngContentSelectors,onPush:n.changeDetection===Am.OnPush,directiveDefs:null,pipeDefs:null,dependencies:t.standalone&&n.dependencies||null,getStandaloneInjector:null,signals:n.signals??!1,data:n.data||{},encapsulation:n.encapsulation||Ia.Emulated,styles:n.styles||Qi,_:null,schemas:n.schemas||null,tView:null,id:""};JT(e);const i=n.dependencies;return e.directiveDefs=Nm(i,!1),e.pipeDefs=Nm(i,!0),e.id=function Z_(n){let t=0;const e=[n.selectors,n.ngContentSelectors,n.hostVars,n.hostAttrs,n.consts,n.vars,n.decls,n.encapsulation,n.standalone,n.signals,n.exportAs,JSON.stringify(n.inputs),JSON.stringify(n.outputs),Object.getOwnPropertyNames(n.type.prototype),!!n.contentQueries,!!n.viewQuery].join("|");for(const r of e)t=Math.imul(31,t)+r.charCodeAt(0)<<0;return t+=2147483648,"c"+t}(e),e})}function X_(n){return ci(n)||jn(n)}function q_(n){return null!==n}function Lm(n){return Xl(()=>({type:n.type,bootstrap:n.bootstrap||Qi,declarations:n.declarations||Qi,imports:n.imports||Qi,exports:n.exports||Qi,transitiveCompileScopes:null,schemas:n.schemas||null,id:n.id||null}))}function $T(n,t){if(null==n)return tl;const e={};for(const i in n)if(n.hasOwnProperty(i)){const r=n[i];let s,o,a=Gh.None;Array.isArray(r)?(a=r[0],s=r[1],o=r[2]??s):(s=r,o=r),t?(e[s]=a!==Gh.None?[i,a]:i,t[s]=o):e[s]=i}return e}function nr(n){return Xl(()=>{const t=ZT(n);return JT(t),t})}function ci(n){return n[Gl]||null}function jn(n){return n[qd]||null}function gs(n){return n[gf]||null}function ZT(n){const t={};return{type:n.type,providersResolver:null,factory:null,hostBindings:n.hostBindings||null,hostVars:n.hostVars||0,hostAttrs:n.hostAttrs||null,contentQueries:n.contentQueries||null,declaredInputs:t,inputTransforms:null,inputConfig:n.inputs||tl,exportAs:n.exportAs||null,standalone:!0===n.standalone,signals:!0===n.signals,selectors:n.selectors||Qi,viewQuery:n.viewQuery||null,features:n.features||null,setInput:null,findHostDirectiveDefs:null,hostDirectives:null,inputs:$T(n.inputs,t),outputs:$T(n.outputs),debugInfo:null}}function JT(n){n.features?.forEach(t=>t(n))}function Nm(n,t){if(!n)return null;const e=t?gs:X_;return()=>("function"==typeof n?n():n).map(i=>e(i)).filter(q_)}const Vr=0,Be=1,Ct=2,vn=3,Ma=4,Os=5,wa=6,Jd=7,Er=8,Xs=9,ql=10,Yt=11,bf=12,KT=13,Kd=14,Jr=15,Mf=16,eu=17,il=18,wf=19,eA=20,Xh=21,Om=22,Uc=23,Ut=25,Fb=1,rl=7,tu=9,mn=10;var _b=function(n){return n[n.None=0]="None",n[n.HasTransplantedViews=2]="HasTransplantedViews",n}(_b||{});function ks(n){return Array.isArray(n)&&"object"==typeof n[Fb]}function Ps(n){return Array.isArray(n)&&!0===n[Fb]}function Ub(n){return 0!=(4&n.flags)}function jc(n){return n.componentOffset>-1}function Pm(n){return 1==(1&n.flags)}function Ca(n){return!!n.template}function jb(n){return 0!=(512&n[Ct])}function Vc(n,t){return n.hasOwnProperty(Uo)?n[Uo]:null}class tU{constructor(t,e,i){this.previousValue=t,this.currentValue=e,this.firstChange=i}isFirstChange(){return this.firstChange}}function nA(n,t,e,i){null!==t?t.applyValueToInputSignal(t,i):n[e]=i}function sA(n){return n.type.prototype.ngOnChanges&&(n.setInput=rU),iU}function iU(){const n=aA(this),t=n?.current;if(t){const e=n.previous;if(e===tl)n.previous=t;else for(let i in t)e[i]=t[i];n.current=null,this.ngOnChanges(t)}}function rU(n,t,e,i,r){const s=this.declaredInputs[i],o=aA(n)||function nU(n,t){return n[oA]=t}(n,{previous:tl,current:null}),a=o.current||(o.current={}),l=o.previous,h=l[s];a[s]=new tU(h&&h.currentValue,e,l===tl),nA(n,t,r,e)}const oA="__ngSimpleChanges__";function aA(n){return n[oA]||null}const nl=function(n,t,e){};let cA=!1;function pr(n){for(;Array.isArray(n);)n=n[Vr];return n}function qs(n,t){return pr(t[n.index])}function Df(n,t){return n.data[t]}function To(n,t){const e=t[n];return ks(e)?e:e[Vr]}function Gb(n){return 128==(128&n[Ct])}function sl(n,t){return null==t?null:n[t]}function dA(n){n[eu]=0}function cU(n){1024&n[Ct]||(n[Ct]|=1024,Gb(n)&&xf(n))}function pA(n){return 9216&n[Ct]||n[Uc]?.dirty}function Xb(n){pA(n)?xf(n):64&n[Ct]&&(function oU(){return cA}()?(n[Ct]|=1024,xf(n)):n[ql].changeDetectionScheduler?.notify())}function xf(n){n[ql].changeDetectionScheduler?.notify();let t=Wc(n);for(;null!==t&&!(8192&t[Ct])&&(t[Ct]|=8192,Gb(t));)t=Wc(t)}function Wc(n){const t=n[vn];return Ps(t)?t[vn]:t}const Rt={lFrame:wA(null),bindingsEnabled:!0,skipHydrationRootTNode:null};function gA(){return Rt.bindingsEnabled}function Se(){return Rt.lFrame.lView}function xi(){return Rt.lFrame.tView}function fr(){let n=vA();for(;null!==n&&64===n.type;)n=n.parent;return n}function vA(){return Rt.lFrame.currentTNode}function ol(n,t){const e=Rt.lFrame;e.currentTNode=n,e.isParent=t}function $b(){return Rt.lFrame.isParent}function wU(n,t){const e=Rt.lFrame;e.bindingIndex=e.bindingRootIndex=n,Jb(t)}function Jb(n){Rt.lFrame.currentDirectiveIndex=n}function IA(){return Rt.lFrame.currentQueryIndex}function e1(n){Rt.lFrame.currentQueryIndex=n}function EU(n){const t=n[Be];return 2===t.type?t.declTNode:1===t.type?n[Os]:null}function bA(n,t,e){if(e&Di.SkipSelf){let r=t,s=n;for(;!(r=r.parent,null!==r||e&Di.Host||(r=EU(s),null===r||(s=s[Kd],10&r.type))););if(null===r)return!1;t=r,n=s}const i=Rt.lFrame=MA();return i.currentTNode=t,i.lView=n,!0}function t1(n){const t=MA(),e=n[Be];Rt.lFrame=t,t.currentTNode=e.firstChild,t.lView=n,t.tView=e,t.contextLView=n,t.bindingIndex=e.bindingStartIndex,t.inI18n=!1}function MA(){const n=Rt.lFrame,t=null===n?null:n.child;return null===t?wA(n):t}function wA(n){const t={currentTNode:null,isParent:!0,lView:null,tView:null,selectedIndex:-1,contextLView:null,elementDepthCount:0,currentNamespace:null,currentDirectiveIndex:-1,bindingRootIndex:-1,bindingIndex:-1,currentQueryIndex:0,parent:n,child:null,inI18n:!1};return null!==n&&(n.child=t),t}function CA(){const n=Rt.lFrame;return Rt.lFrame=n.parent,n.currentTNode=null,n.lView=null,n}const EA=CA;function i1(){const n=CA();n.isParent=!0,n.tView=null,n.selectedIndex=-1,n.contextLView=null,n.elementDepthCount=0,n.currentDirectiveIndex=-1,n.currentNamespace=null,n.bindingRootIndex=-1,n.bindingIndex=-1,n.currentQueryIndex=0}function zs(){return Rt.lFrame.selectedIndex}function Yc(n){Rt.lFrame.selectedIndex=n}let xA=!0;function Hm(){return xA}function qh(n){xA=n}function Bm(n,t){for(let e=t.directiveStart,i=t.directiveEnd;e=i)break}else t[l]<0&&(n[eu]+=65536),(a>14>16&&(3&n[Ct])===t&&(n[Ct]+=16384,AA(a,s)):AA(a,s)}const nu=-1;class Af{constructor(t,e,i){this.factory=t,this.resolving=!1,this.canSeeViewProviders=e,this.injectImpl=i}}function s1(n){return n!==nu}function Lf(n){return 32767&n}function Nf(n,t){let e=function HU(n){return n>>16}(n),i=t;for(;e>0;)i=i[Kd],e--;return i}let o1=!0;function Um(n){const t=o1;return o1=n,t}const LA=255,NA=5;let BU=0;const ll={};function jm(n,t){const e=OA(n,t);if(-1!==e)return e;const i=t[Be];i.firstCreatePass&&(n.injectorIndex=t.length,a1(i.data,n),a1(t,null),a1(i.blueprint,null));const r=Vm(n,t),s=n.injectorIndex;if(s1(r)){const o=Lf(r),a=Nf(r,t),l=a[Be].data;for(let h=0;h<8;h++)t[s+h]=a[o+h]|l[o+h]}return t[s+8]=r,s}function a1(n,t){n.push(0,0,0,0,0,0,0,0,t)}function OA(n,t){return-1===n.injectorIndex||n.parent&&n.parent.injectorIndex===n.injectorIndex||null===t[n.injectorIndex+8]?-1:n.injectorIndex}function Vm(n,t){if(n.parent&&-1!==n.parent.injectorIndex)return n.parent.injectorIndex;let e=0,i=null,r=t;for(;null!==r;){if(i=FA(r),null===i)return nu;if(e++,r=r[Kd],-1!==i.injectorIndex)return i.injectorIndex|e<<16}return nu}function l1(n,t,e){!function FU(n,t,e){let i;"string"==typeof e?i=e.charCodeAt(0)||0:e.hasOwnProperty(jo)&&(i=e[jo]),null==i&&(i=e[jo]=BU++);const r=i&LA;t.data[n+(r>>NA)]|=1<=0?t&LA:VU:t}(e);if("function"==typeof s){if(!bA(t,n,i))return i&Di.Host?kA(r,0,i):PA(t,e,i,r);try{let o;if(o=s(i),null!=o||i&Di.Optional)return o;Tb()}finally{EA()}}else if("number"==typeof s){let o=null,a=OA(n,t),l=nu,h=i&Di.Host?t[Jr][Os]:null;for((-1===a||i&Di.SkipSelf)&&(l=-1===a?Vm(n,t):t[a+8],l!==nu&&BA(i,!1)?(o=t[Be],a=Lf(l),t=Nf(l,t)):a=-1);-1!==a;){const c=t[Be];if(HA(s,a,c.data)){const d=UU(a,t,e,o,i,h);if(d!==ll)return d}l=t[a+8],l!==nu&&BA(i,t[Be].data[a+8]===h)&&HA(s,a,t)?(o=c,a=Lf(l),t=Nf(l,t)):a=-1}}return r}function UU(n,t,e,i,r,s){const o=t[Be],a=o.data[n+8],c=Wm(a,o,e,null==i?jc(a)&&o1:i!=o&&0!=(3&a.type),r&Di.Host&&s===a);return null!==c?Qc(t,o,c,a):ll}function Wm(n,t,e,i,r){const s=n.providerIndexes,o=t.data,a=1048575&s,l=n.directiveStart,c=s>>20,u=r?a+c:n.directiveEnd;for(let p=i?a:a+c;p=l&&f.type===e)return p}if(r){const p=o[l];if(p&&Ca(p)&&p.type===e)return l}return null}function Qc(n,t,e,i){let r=n[e];const s=t.data;if(function kU(n){return n instanceof Af}(r)){const o=r;o.resolving&&function Vo(n,t){const e=t?`. Dependency path: ${t.join(" > ")} > ${n}`:"";throw new F(-200,`Circular dependency in DI detected for ${n}${e}`)}(zi(s[e]));const a=Um(o.canSeeViewProviders);o.resolving=!0;const h=o.injectImpl?no(o.injectImpl):null;bA(n,i,Di.Default);try{r=n[e]=o.factory(void 0,s,n,i),t.firstCreatePass&&e>=i.directiveStart&&function NU(n,t,e){const{ngOnChanges:i,ngOnInit:r,ngDoCheck:s}=t.type.prototype;if(i){const o=sA(t);(e.preOrderHooks??=[]).push(n,o),(e.preOrderCheckHooks??=[]).push(n,o)}r&&(e.preOrderHooks??=[]).push(0-n,r),s&&((e.preOrderHooks??=[]).push(n,s),(e.preOrderCheckHooks??=[]).push(n,s))}(e,s[e],t)}finally{null!==h&&no(h),Um(a),o.resolving=!1,EA()}}return r}function HA(n,t,e){return!!(e[t+(n>>NA)]&1<Array.isArray(e)?uu(e,t):t(e))}function UA(n,t,e){t>=n.length?n.push(e):n.splice(t,0,e)}function Ym(n,t){return t>=n.length-1?n.pop():n.splice(t,1)[0]}const gu=new Ht(""),GA=new Ht("",-1),y1=new Ht("");class qm{get(t,e=yf){if(e===yf){const i=new Error(`NullInjectorError: No provider for ${dt(t)}!`);throw i.name="NullInjectorError",i}return e}}function pj(...n){return{\u0275providers:XA(0,n),\u0275fromNgModule:!0}}function XA(n,...t){const e=[],i=new Set;let r;const s=o=>{e.push(o)};return uu(t,o=>{const a=o;$m(a,s,[],i)&&(r||=[],r.push(a))}),void 0!==r&&qA(r,s),e}function qA(n,t){for(let e=0;e{t(s,i)})}}function $m(n,t,e,i){if(!(n=vt(n)))return!1;let r=null,s=Em(n);const o=!s&&ci(n);if(s||o){if(o&&!o.standalone)return!1;r=n}else{const l=n.ngModule;if(s=Em(l),!s)return!1;r=l}const a=i.has(r);if(o){if(a)return!1;if(i.add(r),o.dependencies){const l="function"==typeof o.dependencies?o.dependencies():o.dependencies;for(const h of l)$m(h,t,e,i)}}else{if(!s)return!1;{if(null!=s.imports&&!a){let h;i.add(r);try{uu(s.imports,c=>{$m(c,t,e,i)&&(h||=[],h.push(c))})}finally{}void 0!==h&&qA(h,t)}if(!a){const h=Vc(r)||(()=>new r);t({provide:r,useFactory:h,deps:Qi},r),t({provide:y1,useValue:r,multi:!0},r),t({provide:gu,useValue:()=>Fi(r),multi:!0},r)}const l=s.providers;if(null!=l&&!a){const h=n;I1(l,c=>{t(c,h)})}}}return r!==n&&void 0!==n.providers}function I1(n,t){for(let e of n)Ql(e)&&(e=e.\u0275providers),Array.isArray(e)?I1(e,t):t(e)}const fj=Xe({provide:String,useValue:Xe});function b1(n){return null!==n&&"object"==typeof n&&fj in n}function Gc(n){return"function"==typeof n}const M1=new Ht(""),Zm={},vj={};let w1;function Jm(){return void 0===w1&&(w1=new qm),w1}class Jl{}class vu extends Jl{get destroyed(){return this._destroyed}constructor(t,e,i,r){super(),this.parent=e,this.source=i,this.scopes=r,this.records=new Map,this._ngOnDestroyHooks=new Set,this._onDestroyHooks=[],this._destroyed=!1,E1(t,o=>this.processProvider(o)),this.records.set(GA,mu(void 0,this)),r.has("environment")&&this.records.set(Jl,mu(void 0,this));const s=this.records.get(M1);null!=s&&"string"==typeof s.value&&this.scopes.add(s.value),this.injectorDefTypes=new Set(this.get(y1,Qi,Di.Self))}destroy(){this.assertNotDestroyed(),this._destroyed=!0;try{for(const e of this._ngOnDestroyHooks)e.ngOnDestroy();const t=this._onDestroyHooks;this._onDestroyHooks=[];for(const e of t)e()}finally{this.records.clear(),this._ngOnDestroyHooks.clear(),this.injectorDefTypes.clear()}}onDestroy(t){return this.assertNotDestroyed(),this._onDestroyHooks.push(t),()=>this.removeOnDestroy(t)}runInContext(t){this.assertNotDestroyed();const e=Qh(this),i=no(void 0);try{return t()}finally{Qh(e),no(i)}}get(t,e=yf,i=Di.Default){if(this.assertNotDestroyed(),t.hasOwnProperty(vf))return t[vf](this);i=Tm(i);const s=Qh(this),o=no(void 0);try{if(!(i&Di.SkipSelf)){let l=this.records.get(t);if(void 0===l){const h=function bj(n){return"function"==typeof n||"object"==typeof n&&n instanceof Ht}(t)&&Cm(t);l=h&&this.injectableDefInScope(h)?mu(C1(t),Zm):null,this.records.set(t,l)}if(null!=l)return this.hydrate(t,l)}return(i&Di.Self?Jm():this.parent).get(t,e=i&Di.Optional&&e===yf?null:e)}catch(a){if("NullInjectorError"===a.name){if((a[xm]=a[xm]||[]).unshift(dt(t)),s)throw a;return function z_(n,t,e,i){const r=n[xm];throw t[_T]&&r.unshift(t[_T]),n.message=function R_(n,t,e,i=null){n=n&&"\n"===n.charAt(0)&&"\u0275"==n.charAt(1)?n.slice(2):n;let r=dt(t);if(Array.isArray(t))r=t.map(dt).join(" -> ");else if("object"==typeof t){let s=[];for(let o in t)if(t.hasOwnProperty(o)){let a=t[o];s.push(o+":"+("string"==typeof a?JSON.stringify(a):dt(a)))}r=`{${s.join(", ")}}`}return`${e}${i?"("+i+")":""}[${r}]: ${n.replace(L_,"\n ")}`}("\n"+n.message,r,e,i),n.ngTokenPath=r,n[xm]=null,n}(a,t,"R3InjectorError",this.source)}throw a}finally{no(o),Qh(s)}}resolveInjectorInitializers(){const t=Qh(this),e=no(void 0);try{const r=this.get(gu,Qi,Di.Self);for(const s of r)s()}finally{Qh(t),no(e)}}toString(){const t=[],e=this.records;for(const i of e.keys())t.push(dt(i));return`R3Injector[${t.join(", ")}]`}assertNotDestroyed(){if(this._destroyed)throw new F(205,!1)}processProvider(t){let e=Gc(t=vt(t))?t:vt(t&&t.provide);const i=function yj(n){return b1(n)?mu(void 0,n.useValue):mu(JA(n),Zm)}(t);if(!Gc(t)&&!0===t.multi){let r=this.records.get(e);r||(r=mu(void 0,Zm,!0),r.factory=()=>Rb(r.multi),this.records.set(e,r)),e=t,r.multi.push(t)}this.records.set(e,i)}hydrate(t,e){return e.value===Zm&&(e.value=vj,e.value=e.factory()),"object"==typeof e.value&&e.value&&function Ij(n){return null!==n&&"object"==typeof n&&"function"==typeof n.ngOnDestroy}(e.value)&&this._ngOnDestroyHooks.add(e.value),e.value}injectableDefInScope(t){if(!t.providedIn)return!1;const e=vt(t.providedIn);return"string"==typeof e?"any"===e||this.scopes.has(e):this.injectorDefTypes.has(e)}removeOnDestroy(t){const e=this._onDestroyHooks.indexOf(t);-1!==e&&this._onDestroyHooks.splice(e,1)}}function C1(n){const t=Cm(n),e=null!==t?t.factory:Vc(n);if(null!==e)return e;if(n instanceof Ht)throw new F(204,!1);if(n instanceof Function)return function mj(n){if(n.length>0)throw new F(204,!1);const e=function D_(n){return n&&(n[Dm]||n[RT])||null}(n);return null!==e?()=>e.factory(n):()=>new n}(n);throw new F(204,!1)}function JA(n,t,e){let i;if(Gc(n)){const r=vt(n);return Vc(r)||C1(r)}if(b1(n))i=()=>vt(n.useValue);else if(function ZA(n){return!(!n||!n.useFactory)}(n))i=()=>n.useFactory(...Rb(n.deps||[]));else if(function $A(n){return!(!n||!n.useExisting)}(n))i=()=>Fi(vt(n.useExisting));else{const r=vt(n&&(n.useClass||n.provide));if(!function Sj(n){return!!n.deps}(n))return Vc(r)||C1(r);i=()=>new r(...Rb(n.deps))}return i}function mu(n,t,e=!1){return{factory:n,value:t,multi:e?[]:void 0}}function E1(n,t){for(const e of n)Array.isArray(e)?E1(e,t):e&&Ql(e)?E1(e.\u0275providers,t):t(e)}function iL(n,t=null,e=null,i){const r=function rL(n,t=null,e=null,i,r=new Set){const s=[e||Qi,pj(n)];return i=i||("object"==typeof n?void 0:dt(n)),new vu(s,t||Jm(),i||null,r)}(n,t,e,i);return r.resolveInjectorInitializers(),r}let T1,Wo=(()=>{class n{static{this.THROW_IF_NOT_FOUND=yf}static{this.NULL=new qm}static create(e,i){if(Array.isArray(e))return iL({name:""},i,e,"");{const r=e.name??"";return iL({name:r},e.parent,e.providers,r)}}static{this.\u0275prov=Yi({token:n,providedIn:"any",factory:()=>Fi(GA)})}static{this.__NG_ELEMENT_ID__=-1}}return n})();const A1=new Ht("",{providedIn:"root",factory:()=>Lj}),Lj="ng",sL=new Ht(""),yu=new Ht("",{providedIn:"platform",factory:()=>"unknown"}),oL=new Ht("",{providedIn:"root",factory:()=>function $h(){if(void 0!==T1)return T1;if(typeof document<"u")return document;throw new F(210,!1)}().body?.querySelector("[ngCspNonce]")?.getAttribute("ngCspNonce")||null});function ry(n){return 128==(128&n.flags)}var Kh=function(n){return n[n.Important=1]="Important",n[n.DashCase=2]="DashCase",n}(Kh||{});const P1=new Map;let Vj=0;const R1="__ngContext__";function Rs(n,t){ks(t)?(n[R1]=t[wf],function Yj(n){P1.set(n[wf],n)}(t)):n[R1]=t}let H1;function B1(n,t){return H1(n,t)}function Iu(n,t,e,i,r){if(null!=i){let s,o=!1;Ps(i)?s=i:ks(i)&&(o=!0,i=i[Vr]);const a=pr(i);0===n&&null!==e?null==r?TL(t,e,a):qc(t,e,a,r||null,!0):1===n&&null!==e?qc(t,e,a,r||null,!0):2===n?function cy(n,t,e){const i=ly(n,t);i&&function a6(n,t,e,i){n.removeChild(t,e,i)}(n,i,t,e)}(t,a,o):3===n&&t.destroyNode(a),null!=s&&function c6(n,t,e,i,r){const s=e[rl];s!==pr(e)&&Iu(t,n,i,s,r);for(let a=mn;a0&&(n[e-1][Ma]=i[Ma]);const s=Ym(n,mn+t);!function e6(n,t){EL(n,t),t[Vr]=null,t[Os]=null}(i[Be],i);const o=s[il];null!==o&&o.detachView(s[Be]),i[vn]=null,i[Ma]=null,i[Ct]&=-129}return i}function ay(n,t){if(!(256&t[Ct])){const e=t[Yt];e.destroyNode&&dy(n,t,e,3,null,null),function i6(n){let t=n[bf];if(!t)return _1(n[Be],n);for(;t;){let e=null;if(ks(t))e=t[bf];else{const i=t[mn];i&&(e=i)}if(!e){for(;t&&!t[Ma]&&t!==n;)ks(t)&&_1(t[Be],t),t=t[vn];null===t&&(t=n),ks(t)&&_1(t[Be],t),e=t&&t[Ma]}t=e}}(t)}}function _1(n,t){if(!(256&t[Ct])){t[Ct]&=-129,t[Ct]|=256,t[Uc]&&function Yd(n){if(Vl(n),Vh(n))for(let t=0;t=0?i[o]():i[-o].unsubscribe(),s+=2}else e[s].call(i[e[s+1]]);null!==i&&(t[Jd]=null);const r=t[Xh];if(null!==r){t[Xh]=null;for(let s=0;s-1){const{encapsulation:s}=n.data[i.directiveStart+r];if(s===Ia.None||s===Ia.Emulated)return null}return qs(i,e)}}(n,t.parent,e)}function qc(n,t,e,i,r){n.insertBefore(t,e,i,r)}function TL(n,t,e){n.appendChild(t,e)}function AL(n,t,e,i,r){null!==i?qc(n,t,e,i,r):TL(n,t,e)}function ly(n,t){return n.parentNode(t)}let j1,OL=function NL(n,t,e){return 40&n.type?qs(n,e):null};function hy(n,t,e,i){const r=U1(n,i,t),s=t[Yt],a=function LL(n,t,e){return OL(n,t,e)}(i.parent||t[Os],i,t);if(null!=r)if(Array.isArray(e))for(let l=0;lnull;function nM(n,t,e=!1){return JL(n,t,e)}class G6{}class rN{}class q6{resolveComponentFactory(t){throw function X6(n){const t=Error(`No component factory found for ${dt(n)}.`);return t.ngComponent=n,t}(t)}}let Iy=(()=>{class n{static{this.NULL=new q6}}return n})();function $6(){return Du(fr(),Se())}function Du(n,t){return new $c(qs(n,t))}let $c=(()=>{class n{constructor(e){this.nativeElement=e}static{this.__NG_ELEMENT_ID__=$6}}return n})();function Z6(n){return n instanceof $c?n.nativeElement:n}class sN{}let lM=(()=>{class n{constructor(){this.destroyNode=null}static{this.__NG_ELEMENT_ID__=()=>function J6(){const n=Se(),e=To(fr().index,n);return(ks(e)?e:n)[Yt]}()}}return n})(),K6=(()=>{class n{static{this.\u0275prov=Yi({token:n,providedIn:"root",factory:()=>null})}}return n})();const hM={};function Qf(n,t,e,i,r=!1){for(;null!==e;){const s=t[e.index];null!==s&&i.push(pr(s)),Ps(s)&&pN(s,i);const o=e.type;if(8&o)Qf(n,t,e.child,i);else if(32&o){const a=B1(e,t);let l;for(;l=a();)i.push(l)}else if(16&o){const a=PL(t,e);if(Array.isArray(a))i.push(...a);else{const l=Wc(t[Jr]);Qf(l[Be],l,a,i,!0)}}e=r?e.projectionNext:e.next}return i}function pN(n,t){for(let e=mn;e!1,producerRecomputeValue:()=>{},consumerMarkedDirty:()=>{},consumerOnSignalRead:()=>{},consumerIsAlwaysLive:!0,consumerMarkedDirty:n=>{xf(n.lView)},consumerOnSignalRead(){this.lView[Uc]=this}};function gN(n){return mN(n[bf])}function vN(n){return mN(n[Ma])}function mN(n){for(;null!==n&&!Ps(n);)n=n[Ma];return n}function uM(n){return n.ngOriginalError}class eh{constructor(){this._console=console}handleError(t){const e=this._findOriginalError(t);this._console.error("ERROR",t),e&&this._console.error("ORIGINAL ERROR",e)}_findOriginalError(t){let e=t&&uM(t);for(;e&&uM(e);)e=uM(e);return e||null}}const SN=new Ht("",{providedIn:"root",factory:()=>Ri(eh).handleError.bind(void 0)}),bN=new Ht("",{providedIn:"root",factory:()=>!1}),Qt={};function pM(n=1){EN(xi(),Se(),zs()+n,!1)}function EN(n,t,e,i){if(!i)if(3==(3&t[Ct])){const s=n.preOrderCheckHooks;null!==s&&Fm(t,s,e)}else{const s=n.preOrderHooks;null!==s&&_m(t,s,0,e)}Yc(e)}function Ot(n,t=Di.Default){const e=Se();return null===e?Fi(n,t):zA(fr(),e,vt(n),t)}function DN(n,t,e,i,r,s){const o=Wi(null);try{let a=null;r&Gh.SignalBased&&(a=t[i][Ts]),null!==a&&void 0!==a.transformFn&&(s=a.transformFn(s)),r&Gh.HasDecoratorInputTransform&&(s=n.inputTransforms[i].call(t,s)),null!==n.setInput?n.setInput(t,a,s,e,i):nA(t,a,i,s)}finally{Wi(o)}}function Cy(n,t,e,i,r,s,o,a,l,h,c){const d=t.blueprint.slice();return d[Vr]=r,d[Ct]=204|i,(null!==h||n&&2048&n[Ct])&&(d[Ct]|=2048),dA(d),d[vn]=d[Kd]=n,d[Er]=e,d[ql]=o||n&&n[ql],d[Yt]=a||n&&n[Yt],d[Xs]=l||n&&n[Xs]||null,d[Os]=s,d[wf]=function Wj(){return Vj++}(),d[wa]=c,d[eA]=h,d[Jr]=2==t.type?n[Jr]:d,d}function xu(n,t,e,i,r){let s=n.data[t];if(null===s)s=function fM(n,t,e,i,r){const s=vA(),o=$b(),l=n.data[t]=function LV(n,t,e,i,r,s){let o=t?t.injectorIndex:-1,a=0;return function ru(){return null!==Rt.skipHydrationRootTNode}()&&(a|=128),{type:e,index:i,insertBeforeIndex:null,injectorIndex:o,directiveStart:-1,directiveEnd:-1,directiveStylingLast:-1,componentOffset:-1,propertyBindings:null,flags:a,providerIndexes:0,value:r,attrs:s,mergedAttrs:null,localNames:null,initialInputs:void 0,inputs:null,outputs:null,tView:null,next:null,prev:null,projectionNext:null,child:null,parent:t,projection:null,styles:null,stylesWithoutHost:null,residualStyles:void 0,classes:null,classesWithoutHost:null,residualClasses:void 0,classBindings:0,styleBindings:0}}(0,o?s:s&&s.parent,e,t,i,r);return null===n.firstChild&&(n.firstChild=l),null!==s&&(o?null==s.child&&null!==l.parent&&(s.child=l):null===s.next&&(s.next=l,l.prev=s)),l}(n,t,e,i,r),function MU(){return Rt.lFrame.inI18n}()&&(s.flags|=32);else if(64&s.type){s.type=e,s.value=i,s.attrs=r;const o=function Tf(){const n=Rt.lFrame,t=n.currentTNode;return n.isParent?t:t.parent}();s.injectorIndex=null===o?-1:o.injectorIndex}return ol(s,!0),s}function Gf(n,t,e,i){if(0===e)return-1;const r=t.length;for(let s=0;sUt&&EN(n,t,Ut,!1),nl(o?2:0,r),e(i,r)}finally{Yc(s),nl(o?3:1,r)}}function gM(n,t,e){if(Ub(t)){const i=Wi(null);try{const s=t.directiveEnd;for(let o=t.directiveStart;onull;function LN(n,t,e,i,r){for(let s in t){if(!t.hasOwnProperty(s))continue;const o=t[s];if(void 0===o)continue;i??={};let a,l=Gh.None;Array.isArray(o)?(a=o[0],l=o[1]):a=o;let h=s;if(null!==r){if(!r.hasOwnProperty(s))continue;h=r[s]}0===n?NN(i,e,h,a,l):NN(i,e,h,a)}return i}function NN(n,t,e,i,r){let s;n.hasOwnProperty(e)?(s=n[e]).push(t,i):s=n[e]=[t,i],void 0!==r&&s.push(r)}function ON(n,t,e,i,r,s){for(let h=0;h0;){const e=n[--t];if("number"==typeof e&&e<0)return e}return 0})(o)!=a&&o.push(a),o.push(e,i,s)}}(n,t,i,Gf(n,e,r.hostVars,Qt),r)}function YV(n,t,e,i,r,s){const o=s[t];if(null!==o)for(let a=0;an.nextProducerIndex;)n.producerNode.pop(),n.producerLastReadVersion.pop(),n.producerIndexOfThis.pop()}}(a,o),function pV(n){n.lView[Uc]!==n&&(n.lView=null,fN.push(n))}(a)),i1()}}function FN(n,t){for(let e=gN(n);null!==e;e=vN(e))for(let i=mn;i-1&&(Bf(t,i),Ym(e,i))}this._attachedToViewContainer=!1}ay(this._lView[Be],this._lView)}onDestroy(t){!function Rm(n,t){if(256==(256&n[Ct]))throw new F(911,!1);null===n[Xh]&&(n[Xh]=[]),n[Xh].push(t)}(this._lView,t)}markForCheck(){Xf(this._cdRefInjectingView||this._lView)}detach(){this._lView[Ct]&=-129}reattach(){Xb(this._lView),this._lView[Ct]|=128}detectChanges(){this._lView[Ct]|=1024,function CM(n,t=!0){const e=n[ql],i=e.rendererFactory;i.begin?.();try{!function XV(n){EM(n,0);let t=0;for(;pA(n);){if(100===t)throw new F(103,!1);t++,EM(n,1)}}(n)}catch(s){throw t&&Dy(n,s),s}finally{i.end?.(),e.inlineEffectRunner?.flush()}}(this._lView,this.notifyErrorHandler)}checkNoChanges(){}attachToViewContainerRef(){if(this._appRef)throw new F(902,!1);this._attachedToViewContainer=!0}detachFromAppRef(){this._appRef=null,EL(this._lView[Be],this._lView)}attachToAppRef(t){if(this._attachedToViewContainer)throw new F(902,!1);this._appRef=t,Xb(this._lView)}}const VN=new Set;function xM(n){return t=>{setTimeout(n,void 0,t)}}const Yo=class h7 extends Pt{constructor(t=!1){super(),this.__isAsync=t}emit(t){super.next(t)}subscribe(t,e,i){let r=t,s=e||(()=>null),o=i;if(t&&"object"==typeof t){const l=t;r=l.next?.bind(l),s=l.error?.bind(l),o=l.complete?.bind(l)}this.__isAsync&&(s=xM(s),r&&(r=xM(r)),o&&(o=xM(o)));const a=super.subscribe({next:r,error:s,complete:o});return t instanceof As&&t.add(a),a}};function WN(...n){}class zr{constructor({enableLongStackTrace:t=!1,shouldCoalesceEventChangeDetection:e=!1,shouldCoalesceRunChangeDetection:i=!1}){if(this.hasPendingMacrotasks=!1,this.hasPendingMicrotasks=!1,this.isStable=!0,this.onUnstable=new Yo(!1),this.onMicrotaskEmpty=new Yo(!1),this.onStable=new Yo(!1),this.onError=new Yo(!1),typeof Zone>"u")throw new F(908,!1);Zone.assertZonePatched();const r=this;r._nesting=0,r._outer=r._inner=Zone.current,Zone.TaskTrackingZoneSpec&&(r._inner=r._inner.fork(new Zone.TaskTrackingZoneSpec)),t&&Zone.longStackTraceZoneSpec&&(r._inner=r._inner.fork(Zone.longStackTraceZoneSpec)),r.shouldCoalesceEventChangeDetection=!i&&e,r.shouldCoalesceRunChangeDetection=i,r.lastRequestAnimationFrameId=-1,r.nativeRequestAnimationFrame=function c7(){const n="function"==typeof rr.requestAnimationFrame;let t=rr[n?"requestAnimationFrame":"setTimeout"],e=rr[n?"cancelAnimationFrame":"clearTimeout"];if(typeof Zone<"u"&&t&&e){const i=t[Zone.__symbol__("OriginalDelegate")];i&&(t=i);const r=e[Zone.__symbol__("OriginalDelegate")];r&&(e=r)}return{nativeRequestAnimationFrame:t,nativeCancelAnimationFrame:e}}().nativeRequestAnimationFrame,function p7(n){const t=()=>{!function u7(n){n.isCheckStableRunning||-1!==n.lastRequestAnimationFrameId||(n.lastRequestAnimationFrameId=n.nativeRequestAnimationFrame.call(rr,()=>{n.fakeTopEventTask||(n.fakeTopEventTask=Zone.root.scheduleEventTask("fakeTopEventTask",()=>{n.lastRequestAnimationFrameId=-1,AM(n),n.isCheckStableRunning=!0,TM(n),n.isCheckStableRunning=!1},void 0,()=>{},()=>{})),n.fakeTopEventTask.invoke()}),AM(n))}(n)};n._inner=n._inner.fork({name:"angular",properties:{isAngularZone:!0},onInvokeTask:(e,i,r,s,o,a)=>{if(function f7(n){return!(!Array.isArray(n)||1!==n.length)&&!0===n[0].data?.__ignore_ng_zone__}(a))return e.invokeTask(r,s,o,a);try{return YN(n),e.invokeTask(r,s,o,a)}finally{(n.shouldCoalesceEventChangeDetection&&"eventTask"===s.type||n.shouldCoalesceRunChangeDetection)&&t(),QN(n)}},onInvoke:(e,i,r,s,o,a,l)=>{try{return YN(n),e.invoke(r,s,o,a,l)}finally{n.shouldCoalesceRunChangeDetection&&t(),QN(n)}},onHasTask:(e,i,r,s)=>{e.hasTask(r,s),i===r&&("microTask"==s.change?(n._hasPendingMicrotasks=s.microTask,AM(n),TM(n)):"macroTask"==s.change&&(n.hasPendingMacrotasks=s.macroTask))},onHandleError:(e,i,r,s)=>(e.handleError(r,s),n.runOutsideAngular(()=>n.onError.emit(s)),!1)})}(r)}static isInAngularZone(){return typeof Zone<"u"&&!0===Zone.current.get("isAngularZone")}static assertInAngularZone(){if(!zr.isInAngularZone())throw new F(909,!1)}static assertNotInAngularZone(){if(zr.isInAngularZone())throw new F(909,!1)}run(t,e,i){return this._inner.run(t,e,i)}runTask(t,e,i,r){const s=this._inner,o=s.scheduleEventTask("NgZoneEvent: "+r,t,d7,WN,WN);try{return s.runTask(o,e,i)}finally{s.cancelTask(o)}}runGuarded(t,e,i){return this._inner.runGuarded(t,e,i)}runOutsideAngular(t){return this._outer.run(t)}}const d7={};function TM(n){if(0==n._nesting&&!n.hasPendingMicrotasks&&!n.isStable)try{n._nesting++,n.onMicrotaskEmpty.emit(null)}finally{if(n._nesting--,!n.hasPendingMicrotasks)try{n.runOutsideAngular(()=>n.onStable.emit(null))}finally{n.isStable=!0}}}function AM(n){n.hasPendingMicrotasks=!!(n._hasPendingMicrotasks||(n.shouldCoalesceEventChangeDetection||n.shouldCoalesceRunChangeDetection)&&-1!==n.lastRequestAnimationFrameId)}function YN(n){n._nesting++,n.isStable&&(n.isStable=!1,n.onUnstable.emit(null))}function QN(n){n._nesting--,TM(n)}let $f=(()=>{class n{constructor(){this.handler=null,this.internalCallbacks=[]}execute(){const e=[...this.internalCallbacks];this.internalCallbacks.length=0;for(const r of e)r();return!!this.handler?.execute()||e.length>0}ngOnDestroy(){this.handler?.destroy(),this.handler=null,this.internalCallbacks.length=0}static{this.\u0275prov=Yi({token:n,providedIn:"root",factory:()=>new n})}}return n})();function y7(n,t){const e=To(t,n),i=e[Be];!function S7(n,t){for(let e=t.length;e0&&HL(n,e,s.join(" "))}}(u,w,f,i),void 0!==e&&function A7(n,t,e){const i=n.projection=[];for(let r=0;r=0;i--){const r=n[i];r.hostVars=t+=r.hostVars,r.hostAttrs=If(r.hostAttrs,e=If(e,r.hostAttrs))}}(i)}function N7(n,t){for(const e in t.inputs){if(!t.inputs.hasOwnProperty(e)||n.inputs.hasOwnProperty(e))continue;const i=t.inputs[e];if(void 0!==i&&(n.inputs[e]=i,n.declaredInputs[e]=t.declaredInputs[e],null!==t.inputTransforms)){const r=Array.isArray(i)?i[0]:i;if(!t.inputTransforms.hasOwnProperty(r))continue;n.inputTransforms??={},n.inputTransforms[r]=t.inputTransforms[r]}}}function Ty(n){return n===tl?{}:n===Qi?[]:n}function k7(n,t){const e=n.viewQuery;n.viewQuery=e?(i,r)=>{t(i,r),e(i,r)}:t}function P7(n,t){const e=n.contentQueries;n.contentQueries=e?(i,r,s)=>{t(i,r,s),e(i,r,s)}:t}function z7(n,t){const e=n.hostBindings;n.hostBindings=e?(i,r)=>{t(i,r),e(i,r)}:t}function Au(n,t){return!t||null===t.firstChild||ry(n)}function rg(n,t,e,i=!0){const r=t[Be];if(function r6(n,t,e,i){const r=mn+i,s=e.length;i>0&&(e[r-1][Ma]=t),i{class n{static{this.__NG_ELEMENT_ID__=h9}}return n})();function h9(){return pO(fr(),Se())}const c9=xn,dO=class extends c9{constructor(t,e,i){super(),this._lContainer=t,this._hostTNode=e,this._hostLView=i}get element(){return Du(this._hostTNode,this._hostLView)}get injector(){return new Vn(this._hostTNode,this._hostLView)}get parentInjector(){const t=Vm(this._hostTNode,this._hostLView);if(s1(t)){const e=Nf(t,this._hostLView),i=Lf(t);return new Vn(e[Be].data[i+8],e)}return new Vn(null,this._hostLView)}clear(){for(;this.length>0;)this.remove(this.length-1)}get(t){const e=uO(this._lContainer);return null!==e&&e[t]||null}get length(){return this._lContainer.length-mn}createEmbeddedView(t,e,i){let r,s;"number"==typeof i?r=i:null!=i&&(r=i.index,s=i.injector);const a=t.createEmbeddedViewImpl(e||{},s,null);return this.insertImpl(a,r,Au(this._hostTNode,null)),a}createComponent(t,e,i,r,s){const o=t&&!function Of(n){return"function"==typeof n}(t);let a;if(o)a=e;else{const f=e||{};a=f.index,i=f.injector,r=f.projectableNodes,s=f.environmentInjector||f.ngModuleRef}const l=o?t:new Zf(ci(t)),h=i||this.parentInjector;if(!s&&null==l.ngModule){const g=(o?h:this.parentInjector).get(Jl,null);g&&(s=g)}ci(l.componentType??{});const p=l.create(h,r,null,s);return this.insertImpl(p.hostView,a,Au(this._hostTNode,null)),p}insert(t,e){return this.insertImpl(t,e,!0)}insertImpl(t,e,i){const r=t._lView;if(function hU(n){return Ps(n[vn])}(r)){const a=this.indexOf(t);if(-1!==a)this.detach(a);else{const l=r[vn],h=new dO(l,l[Os],l[vn]);h.detach(h.indexOf(t))}}const s=this._adjustIndex(e),o=this._lContainer;return rg(o,r,s,i),t.attachToViewContainerRef(),UA(HM(o),s,t),t}move(t,e){return this.insert(t,e)}indexOf(t){const e=uO(this._lContainer);return null!==e?e.indexOf(t):-1}remove(t){const e=this._adjustIndex(t,-1),i=Bf(this._lContainer,e);i&&(Ym(HM(this._lContainer),e),ay(i[Be],i))}detach(t){const e=this._adjustIndex(t,-1),i=Bf(this._lContainer,e);return i&&null!=Ym(HM(this._lContainer),e)?new qf(i):null}_adjustIndex(t,e=0){return t??this.length+e}};function uO(n){return n[8]}function HM(n){return n[8]||(n[8]=[])}function pO(n,t){let e;const i=t[n.index];return Ps(i)?e=i:(e=function PN(n,t,e,i){return[n,!0,0,t,null,i,null,e,null,null]}(i,t,null,n),t[n.index]=e,Ey(t,e)),fO(e,t,n,i),new dO(e,n,t)}let fO=function vO(n,t,e,i){if(n[rl])return;let r;r=8&e.type?pr(i):function d9(n,t){const e=n[Yt],i=e.createComment(""),r=qs(t,n);return qc(e,ly(e,r),i,function l6(n,t){return n.nextSibling(t)}(e,r),!1),i}(t,e),n[rl]=r};function hg(n,t,e){const i=Se();return function Tn(n,t,e){return!Object.is(n[t],e)&&(n[t]=e,!0)}(i,function al(){return Rt.lFrame.bindingIndex++}(),t)&&function No(n,t,e,i,r,s,o,a){const l=qs(t,e);let c,h=t.inputs;!a&&null!=h&&(c=h[i])?(wM(n,e,c,i,r),jc(t)&&function kV(n,t){const e=To(t,n);16&e[Ct]||(e[Ct]|=64)}(e,t.index)):3&t.type&&(i=function OV(n){return"class"===n?"className":"for"===n?"htmlFor":"formaction"===n?"formAction":"innerHtml"===n?"innerHTML":"readonly"===n?"readOnly":"tabindex"===n?"tabIndex":n}(i),r=null!=o?o(r,t.value||"",i):r,s.setProperty(l,i,r))}(xi(),function Pr(){const n=Rt.lFrame;return Df(n.tView,n.selectedIndex)}(),i,n,t,i[Yt],e,!1),hg}function $M(n,t,e,i,r){const o=r?"class":"style";wM(n,e,t.inputs[o],o,i)}function Qu(n,t,e,i){const r=Se(),s=xi(),o=Ut+n,a=r[Yt],l=s.firstCreatePass?function B8(n,t,e,i,r,s){const o=t.consts,l=xu(t,n,2,i,sl(o,r));return function SM(n,t,e,i){if(gA()){const r=null===i?null:{"":-1},s=function FV(n,t){const e=n.directiveRegistry;let i=null,r=null;if(e)for(let s=0;s(qh(!0),oy(i,r,function DA(){return Rt.lFrame.currentNamespace}()));const qu="en-US";let Mk=qu;function ow(n){return!!n&&"function"==typeof n.then}function Gk(n){return!!n&&"function"==typeof n.subscribe}function aw(n,t,e,i){const r=Se(),s=xi(),o=fr();return function qk(n,t,e,i,r,s,o){const a=Pm(i),h=n.firstCreatePass&&HN(n),c=t[Er],d=RN(t);let u=!0;if(3&i.type||o){const g=qs(i,t),v=o?o(g):g,y=d.length,S=o?M=>o(pr(M[i.index])):i.index;let b=null;if(!o&&a&&(b=function UW(n,t,e,i){const r=n.cleanup;if(null!=r)for(let s=0;sl?a[l]:null}"string"==typeof o&&(s+=2)}return null}(n,t,r,i.index)),null!==b)(b.__ngLastListenerFn__||b).__ngNextListenerFn__=s,b.__ngLastListenerFn__=s,u=!1;else{s=Zk(i,t,c,s,!1);const M=e.listen(v,r,s);d.push(s,M),h&&h.push(r,S,y,y+1)}}else s=Zk(i,t,c,s,!1);const p=i.outputs;let f;if(u&&null!==p&&(f=p[r])){const g=f.length;if(g)for(let v=0;v-1?To(n.index,t):t);let l=$k(t,e,i,o),h=s.__ngNextListenerFn__;for(;h;)l=$k(t,e,h,o)&&l,h=h.__ngNextListenerFn__;return r&&!1===l&&o.preventDefault(),l}}function QW(){return this._results[Symbol.iterator]()}class hw{get changes(){return this._changes??=new Yo}constructor(t=!1){this._emitDistinctChangesOnly=t,this.dirty=!0,this._results=[],this._changesDetected=!1,this._changes=void 0,this.length=0,this.first=void 0,this.last=void 0;const e=hw.prototype;e[Symbol.iterator]||(e[Symbol.iterator]=QW)}get(t){return this._results[t]}map(t){return this._results.map(t)}filter(t){return this._results.filter(t)}find(t){return this._results.find(t)}reduce(t,e){return this._results.reduce(t,e)}forEach(t){this._results.forEach(t)}some(t){return this._results.some(t)}toArray(){return this._results.slice()}toString(){return this._results.toString()}reset(t,e){this.dirty=!1;const i=function oo(n){return n.flat(Number.POSITIVE_INFINITY)}(t);(this._changesDetected=!function $U(n,t,e){if(n.length!==t.length)return!1;for(let i=0;i{class n{static{this.__NG_ELEMENT_ID__=qW}}return n})();const GW=ih,XW=class extends GW{constructor(t,e,i){super(),this._declarationLView=t,this._declarationTContainer=e,this.elementRef=i}get ssrId(){return this._declarationTContainer.tView?.ssrId||null}createEmbeddedView(t,e){return this.createEmbeddedViewImpl(t,e)}createEmbeddedViewImpl(t,e,i){const r=function ig(n,t,e,i){const r=t.tView,a=Cy(n,r,e,4096&n[Ct]?4096:16,null,t,null,null,null,i?.injector??null,i?.dehydratedView??null);a[Mf]=n[t.index];const h=n[il];return null!==h&&(a[il]=h.createEmbeddedView(r)),LM(r,a,e),a}(this._declarationLView,this._declarationTContainer,t,{injector:e,dehydratedView:i});return new qf(r)}};function qW(){return Qy(fr(),Se())}function Qy(n,t){return 4&n.type?new XW(t,n,Du(n,t)):null}class cw{constructor(t){this.queryList=t,this.matches=null}clone(){return new cw(this.queryList)}setDirty(){this.queryList.setDirty()}}class dw{constructor(t=[]){this.queries=t}createEmbeddedView(t){const e=t.queries;if(null!==e){const i=null!==t.contentQueries?t.contentQueries[0]:e.length,r=[];for(let s=0;s0)i.push(o[a/2]);else{const h=s[a+1],c=t[-l];for(let d=mn;d(qh(!0),function sy(n,t){return n.createText(t)}(t[Yt],i));function vw(n,t,e,i,r){if(n=vt(n),Array.isArray(n))for(let s=0;s>20;if(Gc(n)||!n.multi){const p=new Af(h,r,Ot),f=yw(l,t,r?c:c+u,d);-1===f?(l1(jm(a,o),s,l),mw(s,n,t.length),t.push(l),a.directiveStart++,a.directiveEnd++,r&&(a.providerIndexes+=1048576),e.push(p),o.push(p)):(e[f]=p,o[f]=p)}else{const p=yw(l,t,c+u,d),f=yw(l,t,c,c+u),v=f>=0&&e[f];if(r&&!v||!r&&!(p>=0&&e[p])){l1(jm(a,o),s,l);const y=function yY(n,t,e,i,r){const s=new Af(n,e,Ot);return s.multi=[],s.index=t,s.componentProviders=0,kP(s,r,i&&!e),s}(r?mY:vY,e.length,r,i,h);!r&&v&&(e[f].providerFactory=y),mw(s,n,t.length,0),t.push(l),a.directiveStart++,a.directiveEnd++,r&&(a.providerIndexes+=1048576),e.push(y),o.push(y)}else mw(s,n,p>-1?p:f,kP(e[r?f:p],h,!r&&i));!r&&i&&v&&e[f].componentProviders++}}}function mw(n,t,e,i){const r=Gc(t),s=function gj(n){return!!n.useClass}(t);if(r||s){const l=(s?vt(t.useClass):t).prototype.ngOnDestroy;if(l){const h=n.destroyHooks||(n.destroyHooks=[]);if(!r&&t.multi){const c=h.indexOf(e);-1===c?h.push(e,[i,l]):h[c+1].push(i,l)}else h.push(e,l)}}}function kP(n,t,e){return e&&n.componentProviders++,n.multi.push(t)-1}function yw(n,t,e,i){for(let r=e;r{e.providersResolver=(i,r)=>function gY(n,t,e){const i=xi();if(i.firstCreatePass){const r=Ca(n);vw(e,i.data,i.blueprint,r,!0),vw(t,i.data,i.blueprint,r,!1)}}(i,r?r(n):n,t)}}class rd{}class zP extends rd{constructor(t){super(),this.componentFactoryResolver=new JN(this),this.instance=null;const e=new vu([...t.providers,{provide:rd,useValue:this},{provide:Iy,useValue:this.componentFactoryResolver}],t.parent||Jm(),t.debugName,new Set(["environment"]));this.injector=e,t.runEnvironmentInitializers&&e.resolveInjectorInitializers()}destroy(){this.injector.destroy()}onDestroy(t){this.injector.onDestroy(t)}}let wY=(()=>{class n{constructor(e){this._injector=e,this.cachedInjectors=new Map}getOrCreateStandaloneInjector(e){if(!e.standalone)return null;if(!this.cachedInjectors.has(e)){const i=XA(0,e.type),r=i.length>0?function MY(n,t,e=null){return new zP({providers:n,parent:t,debugName:e,runEnvironmentInitializers:!0}).injector}([i],this._injector,`Standalone[${e.type.name}]`):null;this.cachedInjectors.set(e,r)}return this.cachedInjectors.get(e)}ngOnDestroy(){try{for(const e of this.cachedInjectors.values())null!==e&&e.destroy()}finally{this.cachedInjectors.clear()}}static{this.\u0275prov=Yi({token:n,providedIn:"environment",factory:()=>new n(Fi(Jl))})}}return n})();function RP(n){(function Zc(n){VN.has(n)||(VN.add(n),performance?.mark?.("mark_feature_usage",{detail:{feature:n}}))})("NgStandalone"),n.getStandaloneInjector=t=>t.get(wY).getOrCreateStandaloneInjector(n)}let Tw=(()=>{class n{constructor(){this.taskId=0,this.pendingTasks=new Set,this.hasPendingTasks=new _o(!1)}get _hasPendingTasks(){return this.hasPendingTasks.value}add(){this._hasPendingTasks||this.hasPendingTasks.next(!0);const e=this.taskId++;return this.pendingTasks.add(e),e}remove(e){this.pendingTasks.delete(e),0===this.pendingTasks.size&&this._hasPendingTasks&&this.hasPendingTasks.next(!1)}ngOnDestroy(){this.pendingTasks.clear(),this._hasPendingTasks&&this.hasPendingTasks.next(!1)}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();const g2=new Ht(""),XQ=new Ht("");let kw=(()=>{class n{constructor(){this.initialized=!1,this.done=!1,this.donePromise=new Promise((e,i)=>{this.resolve=e,this.reject=i}),this.appInits=Ri(XQ,{optional:!0})??[]}runInitializers(){if(this.initialized)return;const e=[];for(const r of this.appInits){const s=r();if(ow(s))e.push(s);else if(Gk(s)){const o=new Promise((a,l)=>{s.subscribe({complete:a,error:l})});e.push(o)}}const i=()=>{this.done=!0,this.resolve()};Promise.all(e).then(()=>{i()}).catch(r=>{this.reject(r)}),0===e.length&&i(),this.initialized=!0}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();const v2=new Ht("");let Ju=(()=>{class n{constructor(){this._bootstrapListeners=[],this._runningTick=!1,this._destroyed=!1,this._destroyListeners=[],this._views=[],this.internalErrorHandler=Ri(SN),this.afterRenderEffectManager=Ri($f),this.componentTypes=[],this.components=[],this.isStable=Ri(Tw).hasPendingTasks.pipe(jr(e=>!e)),this._injector=Ri(Jl)}get destroyed(){return this._destroyed}get injector(){return this._injector}bootstrap(e,i){const r=e instanceof rN;if(!this._injector.get(kw).done)throw!r&&function _c(n){const t=ci(n)||jn(n)||gs(n);return null!==t&&t.standalone}(e),new F(405,!1);let o;o=r?e:this._injector.get(Iy).resolveComponentFactory(e),this.componentTypes.push(o.componentType);const a=function $Q(n){return n.isBoundToModule}(o)?void 0:this._injector.get(rd),h=o.create(Wo.NULL,[],i||o.selector,a),c=h.location.nativeElement,d=h.injector.get(g2,null);return d?.registerApplication(c),h.onDestroy(()=>{this.detachView(h.hostView),Jy(this.components,h),d?.unregisterApplication(c)}),this._loadComponent(h),h}tick(){if(this._runningTick)throw new F(101,!1);try{this._runningTick=!0;for(let e of this._views)e.detectChanges()}catch(e){this.internalErrorHandler(e)}finally{try{this.afterRenderEffectManager.execute()}catch(e){this.internalErrorHandler(e)}this._runningTick=!1}}attachView(e){const i=e;this._views.push(i),i.attachToAppRef(this)}detachView(e){const i=e;Jy(this._views,i),i.detachFromAppRef()}_loadComponent(e){this.attachView(e.hostView),this.tick(),this.components.push(e);const i=this._injector.get(v2,[]);[...this._bootstrapListeners,...i].forEach(r=>r(e))}ngOnDestroy(){if(!this._destroyed)try{this._destroyListeners.forEach(e=>e()),this._views.slice().forEach(e=>e.destroy())}finally{this._destroyed=!0,this._views=[],this._bootstrapListeners=[],this._destroyListeners=[]}}onDestroy(e){return this._destroyListeners.push(e),()=>Jy(this._destroyListeners,e)}destroy(){if(this._destroyed)throw new F(406,!1);const e=this._injector;e.destroy&&!e.destroyed&&e.destroy()}get viewCount(){return this._views.length}warnIfDestroyed(){}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();function Jy(n,t){const e=n.indexOf(t);e>-1&&n.splice(e,1)}let JQ=(()=>{class n{constructor(){this.zone=Ri(zr),this.applicationRef=Ri(Ju)}initialize(){this._onMicrotaskEmptySubscription||(this._onMicrotaskEmptySubscription=this.zone.onMicrotaskEmpty.subscribe({next:()=>{this.zone.run(()=>{this.applicationRef.tick()})}}))}ngOnDestroy(){this._onMicrotaskEmptySubscription?.unsubscribe()}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();function b2(n){return[{provide:zr,useFactory:n},{provide:gu,multi:!0,useFactory:()=>{const t=Ri(JQ,{optional:!0});return()=>t.initialize()}},{provide:gu,multi:!0,useFactory:()=>{const t=Ri(tG);return()=>{t.initialize()}}},{provide:SN,useFactory:KQ}]}function KQ(){const n=Ri(zr),t=Ri(eh);return e=>n.runOutsideAngular(()=>t.handleError(e))}function eG(n){return function S1(n){return{\u0275providers:n}}([[],b2(()=>new zr(function M2(n){return{enableLongStackTrace:!1,shouldCoalesceEventChangeDetection:n?.eventCoalescing??!1,shouldCoalesceRunChangeDetection:n?.runCoalescing??!1}}(n)))])}let tG=(()=>{class n{constructor(){this.subscription=new As,this.initialized=!1,this.zone=Ri(zr),this.pendingTasks=Ri(Tw)}initialize(){if(this.initialized)return;this.initialized=!0;let e=null;!this.zone.isStable&&!this.zone.hasPendingMacrotasks&&!this.zone.hasPendingMicrotasks&&(e=this.pendingTasks.add()),this.zone.runOutsideAngular(()=>{this.subscription.add(this.zone.onStable.subscribe(()=>{zr.assertNotInAngularZone(),queueMicrotask(()=>{null!==e&&!this.zone.hasPendingMacrotasks&&!this.zone.hasPendingMicrotasks&&(this.pendingTasks.remove(e),e=null)})}))}),this.subscription.add(this.zone.onUnstable.subscribe(()=>{zr.assertInAngularZone(),e??=this.pendingTasks.add()}))}ngOnDestroy(){this.subscription.unsubscribe()}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();const rh=new Ht("",{providedIn:"root",factory:()=>Ri(rh,Di.Optional|Di.SkipSelf)||function iG(){return typeof $localize<"u"&&$localize.locale||qu}()}),Pw=new Ht("");let rc=null;function DG(n){try{const{rootComponent:t,appProviders:e,platformProviders:i}=n,r=function aG(n=[]){if(rc)return rc;const t=function E2(n=[],t){return Wo.create({name:t,providers:[{provide:M1,useValue:"platform"},{provide:Pw,useValue:new Set([()=>rc=null])},...n]})}(n);return rc=t,function m2(){!function Ib(n){Gd=n}(()=>{throw new F(600,!1)})}(),function D2(n){n.get(sL,null)?.forEach(e=>e())}(t),t}(i),s=[eG(),...e||[]],a=new zP({providers:s,parent:r,debugName:"",runEnvironmentInitializers:!1}).injector,l=a.get(zr);return l.run(()=>{a.resolveInjectorInitializers();const h=a.get(eh,null);let c;l.runOutsideAngular(()=>{c=l.onError.subscribe({next:p=>{h.handleError(p)}})});const d=()=>a.destroy(),u=r.get(Pw);return u.add(d),a.onDestroy(()=>{c.unsubscribe(),u.delete(d)}),function y2(n,t,e){try{const i=e();return ow(i)?i.catch(r=>{throw t.runOutsideAngular(()=>n.handleError(r)),r}):i}catch(i){throw t.runOutsideAngular(()=>n.handleError(i)),i}}(h,l,()=>{const p=a.get(kw);return p.runInitializers(),p.donePromise.then(()=>{!function wk(n){ro(n,"Expected localeId to be defined"),"string"==typeof n&&(Mk=n.toLowerCase().replace(/_/g,"-"))}(a.get(rh,qu)||qu);const g=a.get(Ju);return void 0!==t&&g.bootstrap(t),g})})})}catch(t){return Promise.reject(t)}}let $2=null;function jw(){return $2}class UG{}const sd=new Ht("");let sq=(()=>{class n{static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275mod=Lm({type:n})}static{this.\u0275inj=mf({})}}return n})();function uz(n){return"server"===n}class kq extends UG{constructor(){super(...arguments),this.supportsDOMEvents=!0}}class sC extends kq{static makeCurrent(){!function _G(n){$2??=n}(new sC)}onAndCancel(t,e,i){return t.addEventListener(e,i),()=>{t.removeEventListener(e,i)}}dispatchEvent(t,e){t.dispatchEvent(e)}remove(t){t.parentNode&&t.parentNode.removeChild(t)}createElement(t,e){return(e=e||this.getDefaultDocument()).createElement(t)}createHtmlDocument(){return document.implementation.createHTMLDocument("fakeTitle")}getDefaultDocument(){return document}isElementNode(t){return t.nodeType===Node.ELEMENT_NODE}isShadowRoot(t){return t instanceof DocumentFragment}getGlobalEventTarget(t,e){return"window"===e?window:"document"===e?t:"body"===e?t.body:null}getBaseHref(t){const e=function Pq(){return Cg=Cg||document.querySelector("base"),Cg?Cg.getAttribute("href"):null}();return null==e?null:function zq(n){return new URL(n,document.baseURI).pathname}(e)}resetBaseElement(){Cg=null}getUserAgent(){return window.navigator.userAgent}getCookie(t){return function xX(n,t){t=encodeURIComponent(t);for(const e of n.split(";")){const i=e.indexOf("="),[r,s]=-1==i?[e,""]:[e.slice(0,i),e.slice(i+1)];if(r.trim()===t)return decodeURIComponent(s)}return null}(document.cookie,t)}}let Cg=null,Hq=(()=>{class n{build(){return new XMLHttpRequest}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();const oC=new Ht("");let vz=(()=>{class n{constructor(e,i){this._zone=i,this._eventNameToPlugin=new Map,e.forEach(r=>{r.manager=this}),this._plugins=e.slice().reverse()}addEventListener(e,i,r){return this._findPluginFor(i).addEventListener(e,i,r)}getZone(){return this._zone}_findPluginFor(e){let i=this._eventNameToPlugin.get(e);if(i)return i;if(i=this._plugins.find(s=>s.supports(e)),!i)throw new F(5101,!1);return this._eventNameToPlugin.set(e,i),i}static{this.\u0275fac=function(i){return new(i||n)(Fi(oC),Fi(zr))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();class mz{constructor(t){this._doc=t}}const aC="ng-app-id";let yz=(()=>{class n{constructor(e,i,r,s={}){this.doc=e,this.appId=i,this.nonce=r,this.platformId=s,this.styleRef=new Map,this.hostNodes=new Set,this.styleNodesInDOM=this.collectServerRenderedStyles(),this.platformIsServer=uz(s),this.resetHostNodes()}addStyles(e){for(const i of e)1===this.changeUsageCount(i,1)&&this.onStyleAdded(i)}removeStyles(e){for(const i of e)this.changeUsageCount(i,-1)<=0&&this.onStyleRemoved(i)}ngOnDestroy(){const e=this.styleNodesInDOM;e&&(e.forEach(i=>i.remove()),e.clear());for(const i of this.getAllStyles())this.onStyleRemoved(i);this.resetHostNodes()}addHost(e){this.hostNodes.add(e);for(const i of this.getAllStyles())this.addStyleToHost(e,i)}removeHost(e){this.hostNodes.delete(e)}getAllStyles(){return this.styleRef.keys()}onStyleAdded(e){for(const i of this.hostNodes)this.addStyleToHost(i,e)}onStyleRemoved(e){const i=this.styleRef;i.get(e)?.elements?.forEach(r=>r.remove()),i.delete(e)}collectServerRenderedStyles(){const e=this.doc.head?.querySelectorAll(`style[${aC}="${this.appId}"]`);if(e?.length){const i=new Map;return e.forEach(r=>{null!=r.textContent&&i.set(r.textContent,r)}),i}return null}changeUsageCount(e,i){const r=this.styleRef;if(r.has(e)){const s=r.get(e);return s.usage+=i,s.usage}return r.set(e,{usage:i,elements:[]}),i}getStyleElement(e,i){const r=this.styleNodesInDOM,s=r?.get(i);if(s?.parentNode===e)return r.delete(i),s.removeAttribute(aC),s;{const o=this.doc.createElement("style");return this.nonce&&o.setAttribute("nonce",this.nonce),o.textContent=i,this.platformIsServer&&o.setAttribute(aC,this.appId),e.appendChild(o),o}}addStyleToHost(e,i){const r=this.getStyleElement(e,i),s=this.styleRef,o=s.get(i)?.elements;o?o.push(r):s.set(i,{elements:[r],usage:1})}resetHostNodes(){const e=this.hostNodes;e.clear(),e.add(this.doc.head)}static{this.\u0275fac=function(i){return new(i||n)(Fi(sd),Fi(A1),Fi(oL,8),Fi(yu))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();const lC={svg:"http://www.w3.org/2000/svg",xhtml:"http://www.w3.org/1999/xhtml",xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/",math:"http://www.w3.org/1998/MathML/"},hC=/%COMP%/g,Uq=new Ht("",{providedIn:"root",factory:()=>!0});function Iz(n,t){return t.map(e=>e.replace(hC,n))}let bz=(()=>{class n{constructor(e,i,r,s,o,a,l,h=null){this.eventManager=e,this.sharedStylesHost=i,this.appId=r,this.removeStylesOnCompDestroy=s,this.doc=o,this.platformId=a,this.ngZone=l,this.nonce=h,this.rendererByCompId=new Map,this.platformIsServer=uz(a),this.defaultRenderer=new cC(e,o,l,this.platformIsServer)}createRenderer(e,i){if(!e||!i)return this.defaultRenderer;this.platformIsServer&&i.encapsulation===Ia.ShadowDom&&(i={...i,encapsulation:Ia.Emulated});const r=this.getOrCreateRenderer(e,i);return r instanceof wz?r.applyToHost(e):r instanceof dC&&r.applyStyles(),r}getOrCreateRenderer(e,i){const r=this.rendererByCompId;let s=r.get(i.id);if(!s){const o=this.doc,a=this.ngZone,l=this.eventManager,h=this.sharedStylesHost,c=this.removeStylesOnCompDestroy,d=this.platformIsServer;switch(i.encapsulation){case Ia.Emulated:s=new wz(l,h,i,this.appId,c,o,a,d);break;case Ia.ShadowDom:return new Yq(l,h,e,i,o,a,this.nonce,d);default:s=new dC(l,h,i,c,o,a,d)}r.set(i.id,s)}return s}ngOnDestroy(){this.rendererByCompId.clear()}static{this.\u0275fac=function(i){return new(i||n)(Fi(vz),Fi(yz),Fi(A1),Fi(Uq),Fi(sd),Fi(yu),Fi(zr),Fi(oL))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();class cC{constructor(t,e,i,r){this.eventManager=t,this.doc=e,this.ngZone=i,this.platformIsServer=r,this.data=Object.create(null),this.throwOnSyntheticProps=!0,this.destroyNode=null}destroy(){}createElement(t,e){return e?this.doc.createElementNS(lC[e]||e,t):this.doc.createElement(t)}createComment(t){return this.doc.createComment(t)}createText(t){return this.doc.createTextNode(t)}appendChild(t,e){(Mz(t)?t.content:t).appendChild(e)}insertBefore(t,e,i){t&&(Mz(t)?t.content:t).insertBefore(e,i)}removeChild(t,e){t&&t.removeChild(e)}selectRootElement(t,e){let i="string"==typeof t?this.doc.querySelector(t):t;if(!i)throw new F(-5104,!1);return e||(i.textContent=""),i}parentNode(t){return t.parentNode}nextSibling(t){return t.nextSibling}setAttribute(t,e,i,r){if(r){e=r+":"+e;const s=lC[r];s?t.setAttributeNS(s,e,i):t.setAttribute(e,i)}else t.setAttribute(e,i)}removeAttribute(t,e,i){if(i){const r=lC[i];r?t.removeAttributeNS(r,e):t.removeAttribute(`${i}:${e}`)}else t.removeAttribute(e)}addClass(t,e){t.classList.add(e)}removeClass(t,e){t.classList.remove(e)}setStyle(t,e,i,r){r&(Kh.DashCase|Kh.Important)?t.style.setProperty(e,i,r&Kh.Important?"important":""):t.style[e]=i}removeStyle(t,e,i){i&Kh.DashCase?t.style.removeProperty(e):t.style[e]=""}setProperty(t,e,i){null!=t&&(t[e]=i)}setValue(t,e){t.nodeValue=e}listen(t,e,i){if("string"==typeof t&&!(t=jw().getGlobalEventTarget(this.doc,t)))throw new Error(`Unsupported event target ${t} for event ${e}`);return this.eventManager.addEventListener(t,e,this.decoratePreventDefault(i))}decoratePreventDefault(t){return e=>{if("__ngUnwrap__"===e)return t;!1===(this.platformIsServer?this.ngZone.runGuarded(()=>t(e)):t(e))&&e.preventDefault()}}}function Mz(n){return"TEMPLATE"===n.tagName&&void 0!==n.content}class Yq extends cC{constructor(t,e,i,r,s,o,a,l){super(t,s,o,l),this.sharedStylesHost=e,this.hostEl=i,this.shadowRoot=i.attachShadow({mode:"open"}),this.sharedStylesHost.addHost(this.shadowRoot);const h=Iz(r.id,r.styles);for(const c of h){const d=document.createElement("style");a&&d.setAttribute("nonce",a),d.textContent=c,this.shadowRoot.appendChild(d)}}nodeOrShadowRoot(t){return t===this.hostEl?this.shadowRoot:t}appendChild(t,e){return super.appendChild(this.nodeOrShadowRoot(t),e)}insertBefore(t,e,i){return super.insertBefore(this.nodeOrShadowRoot(t),e,i)}removeChild(t,e){return super.removeChild(this.nodeOrShadowRoot(t),e)}parentNode(t){return this.nodeOrShadowRoot(super.parentNode(this.nodeOrShadowRoot(t)))}destroy(){this.sharedStylesHost.removeHost(this.shadowRoot)}}class dC extends cC{constructor(t,e,i,r,s,o,a,l){super(t,s,o,a),this.sharedStylesHost=e,this.removeStylesOnCompDestroy=r,this.styles=l?Iz(l,i.styles):i.styles}applyStyles(){this.sharedStylesHost.addStyles(this.styles)}destroy(){this.removeStylesOnCompDestroy&&this.sharedStylesHost.removeStyles(this.styles)}}class wz extends dC{constructor(t,e,i,r,s,o,a,l){const h=r+"-"+i.id;super(t,e,i,s,o,a,l,h),this.contentAttr=function jq(n){return"_ngcontent-%COMP%".replace(hC,n)}(h),this.hostAttr=function Vq(n){return"_nghost-%COMP%".replace(hC,n)}(h)}applyToHost(t){this.applyStyles(),this.setAttribute(t,this.hostAttr,"")}createElement(t,e){const i=super.createElement(t,e);return super.setAttribute(i,this.contentAttr,""),i}}let Qq=(()=>{class n extends mz{constructor(e){super(e)}supports(e){return!0}addEventListener(e,i,r){return e.addEventListener(i,r,!1),()=>this.removeEventListener(e,i,r)}removeEventListener(e,i,r){return e.removeEventListener(i,r)}static{this.\u0275fac=function(i){return new(i||n)(Fi(sd))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();const Cz=["alt","control","meta","shift"],Gq={"\b":"Backspace","\t":"Tab","\x7f":"Delete","\x1b":"Escape",Del:"Delete",Esc:"Escape",Left:"ArrowLeft",Right:"ArrowRight",Up:"ArrowUp",Down:"ArrowDown",Menu:"ContextMenu",Scroll:"ScrollLock",Win:"OS"},Xq={alt:n=>n.altKey,control:n=>n.ctrlKey,meta:n=>n.metaKey,shift:n=>n.shiftKey};let qq=(()=>{class n extends mz{constructor(e){super(e)}supports(e){return null!=n.parseEventName(e)}addEventListener(e,i,r){const s=n.parseEventName(i),o=n.eventCallback(s.fullKey,r,this.manager.getZone());return this.manager.getZone().runOutsideAngular(()=>jw().onAndCancel(e,s.domEventName,o))}static parseEventName(e){const i=e.toLowerCase().split("."),r=i.shift();if(0===i.length||"keydown"!==r&&"keyup"!==r)return null;const s=n._normalizeKey(i.pop());let o="",a=i.indexOf("code");if(a>-1&&(i.splice(a,1),o="code."),Cz.forEach(h=>{const c=i.indexOf(h);c>-1&&(i.splice(c,1),o+=h+".")}),o+=s,0!=i.length||0===s.length)return null;const l={};return l.domEventName=r,l.fullKey=o,l}static matchEventFullKeyCode(e,i){let r=Gq[e.key]||e.key,s="";return i.indexOf("code.")>-1&&(r=e.code,s="code."),!(null==r||!r)&&(r=r.toLowerCase()," "===r?r="space":"."===r&&(r="dot"),Cz.forEach(o=>{o!==r&&(0,Xq[o])(e)&&(s+=o+".")}),s+=r,s===i)}static eventCallback(e,i,r){return s=>{n.matchEventFullKeyCode(s,e)&&r.runGuarded(()=>i(s))}}static _normalizeKey(e){return"esc"===e?"escape":e}static{this.\u0275fac=function(i){return new(i||n)(Fi(sd))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();function Ez(n){return{appProviders:[...i$,...n?.providers??[]],platformProviders:e$}}const e$=[{provide:yu,useValue:"browser"},{provide:sL,useValue:function Zq(){sC.makeCurrent()},multi:!0},{provide:sd,useFactory:function Kq(){return function Aj(n){T1=n}(document),document},deps:[]}],i$=[{provide:M1,useValue:"root"},{provide:eh,useFactory:function Jq(){return new eh},deps:[]},{provide:oC,useClass:Qq,multi:!0,deps:[sd,zr,yu]},{provide:oC,useClass:qq,multi:!0,deps:[sd]},bz,yz,vz,{provide:sN,useExisting:bz},{provide:class cq{},useClass:Hq,deps:[]},[]];var o$=0,uC=!1;function b0(n,t){var e=t;return e.unshift(void 0),new(Function.prototype.bind.apply(n,e))}function Y(n,t){for(var e=t,i=n.replace(/\[/g,".").replace(/\]/g,"").split("."),r=0;r"u"}function wi(n){return n+"_"+o$++}function w0(n,t){return n===t||!(n===document||!n)&&w0(n.parentNode,t)}function xg(n){try{throw new Error(n)}catch(t){throw new Error(t.message+"\n"+t.stack)}}function Re(n){var t=n+"";return t.match(/auto|cm|mm|in|px|pt|pc|%|em|ex|ch|rem|vw|vh|vmin|vmax/)?t:t+"px"}function ce(){return uC}var Tg,n,t,d$={latn:{_digits:"0123456789",_type:"numeric"}},Lz={decimal:".",group:",",percentSign:"%",plusSign:"+",minusSign:"-",infinity:"\u221e",nan:"NaN",exponential:"E"},Nz=[0,1,2,3,4,5,6,7,8,9],Rr=function(){function n(){}return n.getMainObject=function(t,e){return Y(ce()?e:"main."+e,t)},n.getNumberingSystem=function(t){return Y("supplemental.numberingSystems",t)||this.numberingSystems},n.reverseObject=function(t,e){for(var r={},s=0,o=e||Object.keys(t);s13&&(f+=1,o-=12),o-=1,a=f-4716;var y=u-24e5,S=10631/30,b=u-1948084,M=Math.floor(b/10631);b-=10631*M;var w=Math.floor((b-.1335)/S),C=30*M+w;b-=Math.floor(w*S+.1335);var D=Math.floor((b+28.5001)/29.5);13===D&&(D=12);for(var A=b-Math.floor(29.5001*D-29),x=0;xy);x++);var R=x+16260,L=Math.floor((R-1)/12),O=L+1,N=R-12*L,T=y-t[x-1]+1;return(T+"").length>2&&(T=A,N=D,O=C),{year:O,month:N,date:T}},n.toGregorian=function i(r,s,o){var g=Math.floor(o+t[12*(r-1)+1+(s-1)-16260-1]-1+24e5+.5),v=Math.floor((g-1867216.25)/36524.25),y=1524+(v=g+1+v-Math.floor(v/4)),S=Math.floor((y-122.1)/365.25),b=Math.floor(365.25*S),M=Math.floor((y-b)/30.6001),w=y-b-Math.floor(30.6001*M),C=M-(M>13.5?13:1),D=S-(C>2.5?4716:4715);return D<=0&&C--,new Date(D+"/"+C+"/"+w)};var ut,f$=/\/MMMMM|MMMM|MMM|a|LLLL|LLL|EEEEE|EEEE|E|K|cccc|ccc|WW|W|G+|z+/gi,Oz="stand-alone",g$=["sun","mon","tue","wed","thu","fri","sat"],kz={m:"getMinutes",h:"getHours",H:"getHours",s:"getSeconds",d:"getDate",f:"getMilliseconds"},Pz=function(){function n(){}return n.dateFormat=function(t,e,i){var r=this,s=ut.getDependables(i,t,e.calendar),o=Y("parserObject.numbers",s),a=s.dateObject,l={isIslamic:ut.islamicRegex.test(e.calendar)};ce()&&e.isServerRendered&&(e=ut.compareBlazorDateFormats(e,t));var h=e.format||ut.getResultantPattern(e.skeleton,s.dateObject,e.type,!1,ce()?t:"");if(l.dateSeperator=ce()?Y("dateSeperator",a):ut.getDateSeparator(s.dateObject),st(h))xg("Format options or type given must be invalid");else{h=ut.ConvertDateToWeekFormat(h),ce()&&(h=h.replace(/tt/,"a")),l.pattern=h,l.numMapper=ce()?ze({},o):Rr.getNumberMapper(s.parserObject,Rr.getNumberingSystem(i));for(var d=0,u=h.match(f$)||[];d2?r+=e.month[""+u]:f=!0;break;case"E":case"c":r+=e.weekday[""+g$[t.getDay()]];break;case"H":case"h":case"m":case"s":case"d":case"f":if(f=!0,"d"===d)u=o.date;else if("f"===d){f=!1,g=!0;var y=(p=(p=t[""+kz[""+d]]().toString()).substring(0,c)).length;if(c!==y){if(c>3)continue;for(var S=0;S0?1:0],o=Math.abs(t);return s.replace(/HH?|mm/g,function(a){var l=a.length,h=-1!==a.indexOf("H");return i.checkTwodigitNumber(Math.floor(h?o/60:o%60),l)})},n}(),zz={ms:"minimumSignificantDigits",ls:"maximumSignificantDigits",mf:"minimumFractionDigits",lf:"maximumFractionDigits"},ip=["infinity","nan","group","decimal","exponential"],Rz=function(){function n(){}return n.numberFormatter=function(t,e,i){var l,r=this,s=ze({},e),o={},a={},h=ut.getDependables(i,t,"",!0),c=h.numericObject;a.numberMapper=ce()?ze({},c):Rr.getNumberMapper(h.parserObject,Rr.getNumberingSystem(i),!0),a.currencySymbol=ce()?Y("currencySymbol",c):ut.getCurrencySymbol(h.numericObject,s.currency||Ng,e.altSymbol,e.ignoreCurrency),a.percentSymbol=ce()?Y("numberSymbols.percentSign",c):a.numberMapper.numberSymbols.percentSign,a.minusSymbol=ce()?Y("numberSymbols.minusSign",c):a.numberMapper.numberSymbols.minusSign;var d=a.numberMapper.numberSymbols;if(e.format&&!ut.formatRegex.test(e.format))o=ut.customFormat(e.format,a,h.numericObject),!st(s.useGrouping)&&s.useGrouping&&(s.useGrouping=o.pData.useGrouping);else{if(ze(s,ut.getProperNumericSkeleton(e.format||"N")),s.isCurrency="currency"===s.type,s.isPercent="percent"===s.type,ce()||(l=ut.getSymbolPattern(s.type,a.numberMapper.numberSystem,h.numericObject,s.isAccount)),s.groupOne=this.checkValueRange(s.maximumSignificantDigits,s.minimumSignificantDigits,!0),this.checkValueRange(s.maximumFractionDigits,s.minimumFractionDigits,!1,!0),st(s.fractionDigits)||(s.minimumFractionDigits=s.maximumFractionDigits=s.fractionDigits),st(s.useGrouping)&&(s.useGrouping=!0),s.isCurrency&&!ce()&&(l=l.replace(/\u00A4/g,ut.defaultCurrency)),ce())o.nData=ze({},{},Y(s.type+"nData",c)),o.pData=ze({},{},Y(s.type+"pData",c)),"currency"===s.type&&e.currency&&ut.replaceBlazorCurrency([o.pData,o.nData],a.currencySymbol,e.currency);else{var u=l.split(";");o.nData=ut.getFormatData(u[1]||"-"+u[0],!0,a.currencySymbol),o.pData=ut.getFormatData(u[0],!1,a.currencySymbol),s.useGrouping&&(s.groupSeparator=d[ip[2]],s.groupData=this.getGroupingDetails(u[0]))}if(st(s.minimumFractionDigits)&&(s.minimumFractionDigits=o.nData.minimumFraction),st(s.maximumFractionDigits)){var f=o.nData.maximumFraction;s.maximumFractionDigits=st(f)&&s.isPercent?0:f}var g=s.minimumFractionDigits,v=s.maximumFractionDigits;!st(g)&&!st(v)&&g>v&&(s.maximumFractionDigits=g)}return ze(o.nData,s),ze(o.pData,s),function(y){return isNaN(y)?d[ip[1]]:isFinite(y)?r.intNumberFormatter(y,o,a,e):d[ip[0]]}},n.getGroupingDetails=function(t){var e={},i=t.match(ut.negativeDataRegex);if(i&&i[4]){var r=i[4],s=r.lastIndexOf(",");if(-1!==s){var o=r.split(".")[0];e.primary=o.length-s-1;var a=r.lastIndexOf(",",s-1);-1!==a&&(e.secondary=s-1-a)}}return e},n.checkValueRange=function(t,e,i,r){var s=r?"f":"s",o=0,a=zz["l"+s],l=zz["m"+s];if(st(t)||(this.checkRange(t,a,r),o++),st(e)||(this.checkRange(e,l,r),o++),2===o){if(!(tr[1])&&xg(e+"value must be within the range"+r[0]+"to"+r[1])},n.intNumberFormatter=function(t,e,i,r){var s;if(!st(e.nData.type)){t<0?(t*=-1,s=e.nData):s=0===t&&e.zeroData||e.pData;var o="";if(s.isPercent&&(t*=100),s.groupOne)o=this.processSignificantDigits(t,s.minimumSignificantDigits,s.maximumSignificantDigits);else if(o=this.processFraction(t,s.minimumFractionDigits,s.maximumFractionDigits,r),s.minimumIntegerDigits&&(o=this.processMinimumIntegers(o,s.minimumIntegerDigits)),i.isCustomFormat&&s.minimumFractionDigits=0&&"0"===l[parseInt(c.toString(),10)]&&c>=s.minimumFractionDigits;c--)l=l.slice(0,c);o=a[0]+"."+l}return"scientific"===s.type&&(o=(o=t.toExponential(s.maximumFractionDigits)).replace("e",i.numberMapper.numberSymbols[ip[4]])),o=o.replace(".",i.numberMapper.numberSymbols[ip[3]]),o="#,###,,;(#,###,,)"===s.format?this.customPivotFormat(parseInt(o,10)):o,s.useGrouping&&(o=this.groupNumbers(o,s.groupData.primary,s.groupSeparator||",",i.numberMapper.numberSymbols[ip[3]]||".",s.groupData.secondary)),o=Rr.convertValueParts(o,ut.latnParseRegex,i.numberMapper.mapper),"N/A"===s.nlead?s.nlead:"0"===o&&r&&"0"===r.format?o+s.nend:s.nlead+o+s.nend}},n.processSignificantDigits=function(t,e,i){var r=t+"";return r.lengthe;)c=l.slice(h-e,h)+(c.length?i+c:""),h-=e,o&&(e=s,o=!1);return a[0]=l.slice(0,h)+(c.length?i:"")+c,a.join(r)},n.processFraction=function(t,e,i,r){var s=(t+"").split(".")[1],o=s?s.length:0;if(e&&oi||0===i))return t.toFixed(i);var h=t+"";return"0"===h[0]&&r&&"###.00"===r.format&&(h=h.slice(1)),h},n.processMinimumIntegers=function(t,e){var i=t.split("."),r=i[0],s=r.length;if(s=5e5){var r=(t/=1e6).toString().split(".")[1];return r&&+r.substring(0,1)>=5?Math.ceil(t).toString():Math.floor(t).toString()}return""},n}(),Ag=(new RegExp("^([^0-9]*)(([0-9,]*[0-9]+)(.[0-9]+)?)([Ee][+-]?[0-9]+)?([^0-9]*)$"),function(){function n(t){this.ranArray=[],this.boundedEvents={},!m(t)&&(this.context=t)}return n.prototype.on=function(t,e,i,r){if(!m(e)){var s=i||this.context;if(this.notExist(t))return void(this.boundedEvents[""+t]=[{handler:e,context:s,id:r}]);m(r)?this.isHandlerPresent(this.boundedEvents[""+t],e)||this.boundedEvents[""+t].push({handler:e,context:s}):-1===this.ranArray.indexOf(r)&&(this.ranArray.push(r),this.boundedEvents[""+t].push({handler:e,context:s,id:r}))}},n.prototype.off=function(t,e,i){if(!this.notExist(t)){var r=Y(t,this.boundedEvents);if(e){for(var s=0;s1&&(_.fractionDigits=parseInt(P[2],10)),_}function f(T,P,_,B){var j=B?{}:{nlead:"",nend:""},Q=T.match(n.customRegex);if(Q){B||(j.nlead=g(Q[1],_),j.nend=g(Q[10],_),j.groupPattern=Q[4]);var oe=Q[7];if(oe&&P){var ue=oe.match(t);j.minimumFraction=m(ue)?0:ue.length,j.maximumFraction=oe.length-1}}return j}function g(T,P){return T?(T=T.replace(n.defaultCurrency,P),""===P?T.trim():T):""}function v(T,P,_,B){return B?"$":Y("currencies."+P+(_?"."+_:".symbol"),T)||Y("currencies."+P+".symbol-alt-narrow",T)||"$"}function S(T,P,_){var B={type:"decimal",minimumFractionDigits:0,maximumFractionDigits:0},j=T.match(n.customRegex);if(m(j)||""===j[5]&&"N/A"!==T)return B.type=void 0,B;B.nlead=j[1],B.nend=j[10];var Q=j[6],oe=!!Q.match(/ $/g),ue=-1!==Q.replace(/ $/g,"").indexOf(" ");B.useGrouping=-1!==Q.indexOf(",")||ue,Q=Q.replace(/,/g,"");var pe=j[7];if(-1!==Q.indexOf("0")&&(B.minimumIntegerDigits=Q.length-Q.indexOf("0")),m(pe)||(B.minimumFractionDigits=pe.lastIndexOf("0"),B.maximumFractionDigits=pe.lastIndexOf("#"),-1===B.minimumFractionDigits&&(B.minimumFractionDigits=0),(-1===B.maximumFractionDigits||B.maximumFractionDigitsQ.lastIndexOf("'"))){B[""+a[parseInt(j.toString(),10)]]=Q.substr(0,oe)+_+Q.substr(oe+1),B[""+a[""+P]]=!0,B.type=B.isCurrency?"currency":"percent";break}}return B}function C(T,P){if(-1!==T.indexOf(",")){var _=T.split(",");T=_[0]+Y("numberMapper.numberSymbols.group",P)+_[1].replace(".",Y("numberMapper.numberSymbols.decimal",P))}else T=T.replace(".",Y("numberMapper.numberSymbols.decimal",P));return T}function A(T,P,_){T+=".";for(var B=0;B0;Q-=3)T=","+_[Q-2]+_[Q-1]+_[parseInt(Q.toString(),10)]+T;return T=T.slice(1),P[1]?T+"."+P[1]:T}n.dateParseRegex=/([a-z])\1*|'([^']|'')+'|''|./gi,n.basicPatterns=["short","medium","long","full"],n.defaultObject={dates:{calendars:{gregorian:{months:{"stand-alone":{abbreviated:{1:"Jan",2:"Feb",3:"Mar",4:"Apr",5:"May",6:"Jun",7:"Jul",8:"Aug",9:"Sep",10:"Oct",11:"Nov",12:"Dec"},narrow:{1:"J",2:"F",3:"M",4:"A",5:"M",6:"J",7:"J",8:"A",9:"S",10:"O",11:"N",12:"D"},wide:{1:"January",2:"February",3:"March",4:"April",5:"May",6:"June",7:"July",8:"August",9:"September",10:"October",11:"November",12:"December"}}},days:{"stand-alone":{abbreviated:{sun:"Sun",mon:"Mon",tue:"Tue",wed:"Wed",thu:"Thu",fri:"Fri",sat:"Sat"},narrow:{sun:"S",mon:"M",tue:"T",wed:"W",thu:"T",fri:"F",sat:"S"},short:{sun:"Su",mon:"Mo",tue:"Tu",wed:"We",thu:"Th",fri:"Fr",sat:"Sa"},wide:{sun:"Sunday",mon:"Monday",tue:"Tuesday",wed:"Wednesday",thu:"Thursday",fri:"Friday",sat:"Saturday"}}},dayPeriods:{format:{wide:{am:"AM",pm:"PM"}}},eras:{eraNames:{0:"Before Christ","0-alt-variant":"Before Common Era",1:"Anno Domini","1-alt-variant":"Common Era"},eraAbbr:{0:"BC","0-alt-variant":"BCE",1:"AD","1-alt-variant":"CE"},eraNarrow:{0:"B","0-alt-variant":"BCE",1:"A","1-alt-variant":"CE"}},dateFormats:{full:"EEEE, MMMM d, y",long:"MMMM d, y",medium:"MMM d, y",short:"M/d/yy"},timeFormats:{full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},dateTimeFormats:{full:"{1} 'at' {0}",long:"{1} 'at' {0}",medium:"{1}, {0}",short:"{1}, {0}",availableFormats:{d:"d",E:"ccc",Ed:"d E",Ehm:"E h:mm a",EHm:"E HH:mm",Ehms:"E h:mm:ss a",EHms:"E HH:mm:ss",Gy:"y G",GyMMM:"MMM y G",GyMMMd:"MMM d, y G",GyMMMEd:"E, MMM d, y G",h:"h a",H:"HH",hm:"h:mm a",Hm:"HH:mm",hms:"h:mm:ss a",Hms:"HH:mm:ss",hmsv:"h:mm:ss a v",Hmsv:"HH:mm:ss v",hmv:"h:mm a v",Hmv:"HH:mm v",M:"L",Md:"M/d",MEd:"E, M/d",MMM:"LLL",MMMd:"MMM d",MMMEd:"E, MMM d",MMMMd:"MMMM d",ms:"mm:ss",y:"y",yM:"M/y",yMd:"M/d/y",yMEd:"E, M/d/y",yMMM:"MMM y",yMMMd:"MMM d, y",yMMMEd:"E, MMM d, y",yMMMM:"MMMM y"}}},islamic:{months:{"stand-alone":{abbreviated:{1:"Muh.",2:"Saf.",3:"Rab. I",4:"Rab. II",5:"Jum. I",6:"Jum. II",7:"Raj.",8:"Sha.",9:"Ram.",10:"Shaw.",11:"Dhu\u02bbl-Q.",12:"Dhu\u02bbl-H."},narrow:{1:"1",2:"2",3:"3",4:"4",5:"5",6:"6",7:"7",8:"8",9:"9",10:"10",11:"11",12:"12"},wide:{1:"Muharram",2:"Safar",3:"Rabi\u02bb I",4:"Rabi\u02bb II",5:"Jumada I",6:"Jumada II",7:"Rajab",8:"Sha\u02bbban",9:"Ramadan",10:"Shawwal",11:"Dhu\u02bbl-Qi\u02bbdah",12:"Dhu\u02bbl-Hijjah"}}},days:{"stand-alone":{abbreviated:{sun:"Sun",mon:"Mon",tue:"Tue",wed:"Wed",thu:"Thu",fri:"Fri",sat:"Sat"},narrow:{sun:"S",mon:"M",tue:"T",wed:"W",thu:"T",fri:"F",sat:"S"},short:{sun:"Su",mon:"Mo",tue:"Tu",wed:"We",thu:"Th",fri:"Fr",sat:"Sa"},wide:{sun:"Sunday",mon:"Monday",tue:"Tuesday",wed:"Wednesday",thu:"Thursday",fri:"Friday",sat:"Saturday"}}},dayPeriods:{format:{wide:{am:"AM",pm:"PM"}}},eras:{eraNames:{0:"AH"},eraAbbr:{0:"AH"},eraNarrow:{0:"AH"}},dateFormats:{full:"EEEE, MMMM d, y G",long:"MMMM d, y G",medium:"MMM d, y G",short:"M/d/y GGGGG"},timeFormats:{full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},dateTimeFormats:{full:"{1} 'at' {0}",long:"{1} 'at' {0}",medium:"{1}, {0}",short:"{1}, {0}",availableFormats:{d:"d",E:"ccc",Ed:"d E",Ehm:"E h:mm a",EHm:"E HH:mm",Ehms:"E h:mm:ss a",EHms:"E HH:mm:ss",Gy:"y G",GyMMM:"MMM y G",GyMMMd:"MMM d, y G",GyMMMEd:"E, MMM d, y G",h:"h a",H:"HH",hm:"h:mm a",Hm:"HH:mm",hms:"h:mm:ss a",Hms:"HH:mm:ss",M:"L",Md:"M/d",MEd:"E, M/d",MMM:"LLL",MMMd:"MMM d",MMMEd:"E, MMM d",MMMMd:"MMMM d",ms:"mm:ss",y:"y G",yyyy:"y G",yyyyM:"M/y GGGGG",yyyyMd:"M/d/y GGGGG",yyyyMEd:"E, M/d/y GGGGG",yyyyMMM:"MMM y G",yyyyMMMd:"MMM d, y G",yyyyMMMEd:"E, MMM d, y G",yyyyMMMM:"MMMM y G",yyyyQQQ:"QQQ y G",yyyyQQQQ:"QQQQ y G"}}}},timeZoneNames:{hourFormat:"+HH:mm;-HH:mm",gmtFormat:"GMT{0}",gmtZeroFormat:"GMT"}},numbers:{currencies:{USD:{displayName:"US Dollar",symbol:"$","symbol-alt-narrow":"$"},EUR:{displayName:"Euro",symbol:"\u20ac","symbol-alt-narrow":"\u20ac"},GBP:{displayName:"British Pound","symbol-alt-narrow":"\xa3"}},defaultNumberingSystem:"latn",minimumGroupingDigits:"1","symbols-numberSystem-latn":{decimal:".",group:",",list:";",percentSign:"%",plusSign:"+",minusSign:"-",exponential:"E",superscriptingExponent:"\xd7",perMille:"\u2030",infinity:"\u221e",nan:"NaN",timeSeparator:":"},"decimalFormats-numberSystem-latn":{standard:"#,##0.###"},"percentFormats-numberSystem-latn":{standard:"#,##0%"},"currencyFormats-numberSystem-latn":{standard:"\xa4#,##0.00",accounting:"\xa4#,##0.00;(\xa4#,##0.00)"},"scientificFormats-numberSystem-latn":{standard:"#E0"}}},n.blazorDefaultObject={numbers:{mapper:{0:"0",1:"1",2:"2",3:"3",4:"4",5:"5",6:"6",7:"7",8:"8",9:"9"},mapperDigits:"0123456789",numberSymbols:{decimal:".",group:",",plusSign:"+",minusSign:"-",percentSign:"%",nan:"NaN",timeSeparator:":",infinity:"\u221e"},timeSeparator:":",currencySymbol:"$",currencypData:{nlead:"$",nend:"",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},percentpData:{nlead:"",nend:"%",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},percentnData:{nlead:"-",nend:"%",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},currencynData:{nlead:"($",nend:")",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},decimalnData:{nlead:"-",nend:"",groupData:{primary:3},maximumFraction:2,minimumFraction:2},decimalpData:{nlead:"",nend:"",groupData:{primary:3},maximumFraction:2,minimumFraction:2}},dates:{dayPeriods:{am:"AM",pm:"PM"},dateSeperator:"/",days:{abbreviated:{sun:"Sun",mon:"Mon",tue:"Tue",wed:"Wed",thu:"Thu",fri:"Fri",sat:"Sat"},short:{sun:"Su",mon:"Mo",tue:"Tu",wed:"We",thu:"Th",fri:"Fr",sat:"Sa"},wide:{sun:"Sunday",mon:"Monday",tue:"Tuesday",wed:"Wednesday",thu:"Thursday",fri:"Friday",sat:"Saturday"}},months:{abbreviated:{1:"Jan",2:"Feb",3:"Mar",4:"Apr",5:"May",6:"Jun",7:"Jul",8:"Aug",9:"Sep",10:"Oct",11:"Nov",12:"Dec"},wide:{1:"January",2:"February",3:"March",4:"April",5:"May",6:"June",7:"July",8:"August",9:"September",10:"October",11:"November",12:"December"}},eras:{1:"AD"}}},n.monthIndex={3:"abbreviated",4:"wide",5:"narrow",1:"abbreviated"},n.month="months",n.days="days",n.patternMatcher={C:"currency",P:"percent",N:"decimal",A:"currency",E:"scientific"},n.getResultantPattern=l,n.getDependables=h,n.getSymbolPattern=c,n.ConvertDateToWeekFormat=d,n.compareBlazorDateFormats=u,n.getProperNumericSkeleton=p,n.getFormatData=f,n.changeCurrencySymbol=g,n.getCurrencySymbol=v,n.customFormat=function y(T,P,_){for(var B={},j=T.split(";"),Q=["pData","nData","zeroData"],oe=0;oe1,pe.nData=ce()?Y(De.type+"nData",oe):f(ot[1]||"-"+ot[0],!0,Ie),pe.pData=ce()?Y(De.type+"pData",oe):f(ot[0],!1,Ie),!Me[2]&&!P.minimumFractionDigits&&!P.maximumFractionDigits&&(ue=f(Ve.split(";")[0],!0,"",!0).minimumFraction)}if(n.formatRegex.test(P.format)||!P.format){if(ze(Q,p(P.format||"N")),Q.custom=!1,$e="###0",(Q.fractionDigits||P.minimumFractionDigits||P.maximumFractionDigits||ue)&&(Q.fractionDigits&&(P.minimumFractionDigits=P.maximumFractionDigits=Q.fractionDigits),$e=A($e,ue||Q.fractionDigits||P.minimumFractionDigits||0,P.maximumFractionDigits||0)),P.minimumIntegerDigits&&($e=x($e,P.minimumIntegerDigits)),P.useGrouping&&($e=R($e)),"currency"===Q.type||Q.type&&ce()){ce()&&"currency"!==Q.type&&(pe.pData=Y(Q.type+"pData",oe),pe.nData=Y(Q.type+"nData",oe));var hr=$e;$e=pe.pData.nlead+hr+pe.pData.nend,(pe.hasNegativePattern||ce())&&($e+=";"+pe.nData.nlead+hr+pe.nData.nend)}"percent"===Q.type&&!ce()&&($e+=" %")}else $e=P.format.replace(/'/g,'"');return Object.keys(xe).length>0&&($e=B?$e:C($e,xe)),$e},n.fractionDigitsPattern=A,n.minimumIntegerPattern=x,n.groupingPattern=R,n.getWeekData=function L(T,P){var _="sun",B=Y("supplemental.weekData.firstDay",P),j=T;return/en-/.test(j)&&(j=j.slice(3)),j=j.slice(0,2).toUpperCase()+j.substr(2),B&&(_=B[""+j]||B[j.slice(0,2)]||"sun"),o[""+_]},n.replaceBlazorCurrency=function O(T,P,_){var B=function p$(n){return Y(n||"",u$)}(_);if(P!==B)for(var j=0,Q=T;j=0?_:_+7;var j=Math.floor((T.getTime()-P.getTime()-6e4*(T.getTimezoneOffset()-P.getTimezoneOffset()))/864e5)+1;if(_<4){if((B=Math.floor((j+_-1)/7)+1)>52){var oe=new Date(T.getFullYear()+1,0,1).getDay();B=(oe=oe>=0?oe:oe+7)<4?1:53}}else B=Math.floor((j+_-1)/7);return B}}(ut||(ut={}));var rp=function(){function n(t,e,i){this.type="GET",this.emitError=!0,"string"==typeof t?(this.url=t,this.type=m(e)?this.type:e.toUpperCase(),this.contentType=i):Aa(t)&&Object.keys(t).length>0&&Nn(this,t),this.contentType=m(this.contentType)?"application/json; charset=utf-8":this.contentType}return n.prototype.send=function(t){var e=this,i={"application/json":"json","multipart/form-data":"formData","application/octet-stream":"blob","application/x-www-form-urlencoded":"formData"};try{m(this.fetchRequest)&&"GET"===this.type?this.fetchRequest=new Request(this.url,{method:this.type}):m(this.fetchRequest)&&(this.data=m(t)?this.data:t,this.fetchRequest=new Request(this.url,{method:this.type,headers:{"Content-Type":this.contentType},body:this.data}));var r={cancel:!1,fetchRequest:this.fetchRequest};return this.triggerEvent(this.beforeSend,r),r.cancel?null:(this.fetchResponse=fetch(this.fetchRequest),this.fetchResponse.then(function(s){if(e.triggerEvent(e.onLoad,s),!s.ok)throw s;for(var o="text",a=0,l=Object.keys(i);a-1},n.getValue=function(t,e){var i=typeof window<"u"?window.browserDetails:{};return typeof navigator<"u"&&"MacIntel"===navigator.platform&&navigator.maxTouchPoints>1&&!0===n.isTouch&&!gC.CHROME.test(navigator.userAgent)&&(i.isIos=!0,i.isDevice=!0,i.isTouch=!0,i.isPointer=!0),typeof window<"u"&&window.Capacitor&&"ios"===window.Capacitor.getPlatform()&&(i.isPointer=!1),typeof i[""+t]>"u"?i[""+t]=e.test(n.userAgent):i[""+t]},Object.defineProperty(n,"userAgent",{get:function(){return n.uA},set:function(t){n.uA=t,window.browserDetails={}},enumerable:!0,configurable:!0}),Object.defineProperty(n,"info",{get:function(){return st(window.browserDetails.info)?window.browserDetails.info=n.extractBrowserDetail():window.browserDetails.info},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isIE",{get:function(){return n.getValue("isIE",A$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isTouch",{get:function(){return st(window.browserDetails.isTouch)?window.browserDetails.isTouch="ontouchstart"in window.navigator||window&&window.navigator&&window.navigator.maxTouchPoints>0||"ontouchstart"in window:window.browserDetails.isTouch},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isPointer",{get:function(){return st(window.browserDetails.isPointer)?window.browserDetails.isPointer="pointerEnabled"in window.navigator:window.browserDetails.isPointer},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isMSPointer",{get:function(){return st(window.browserDetails.isMSPointer)?window.browserDetails.isMSPointer="msPointerEnabled"in window.navigator:window.browserDetails.isMSPointer},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isDevice",{get:function(){return n.getValue("isDevice",T$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isIos",{get:function(){return n.getValue("isIos",N$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isIos7",{get:function(){return n.getValue("isIos7",O$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isAndroid",{get:function(){return n.getValue("isAndroid",k$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isWebView",{get:function(){return st(window.browserDetails.isWebView)&&(window.browserDetails.isWebView=!(st(window.cordova)&&st(window.PhoneGap)&&st(window.phonegap)&&"object"!==window.forge)),window.browserDetails.isWebView},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isWindows",{get:function(){return n.getValue("isWindows",P$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"touchStartEvent",{get:function(){return st(window.browserDetails.touchStartEvent)?window.browserDetails.touchStartEvent=n.getTouchStartEvent():window.browserDetails.touchStartEvent},enumerable:!0,configurable:!0}),Object.defineProperty(n,"touchMoveEvent",{get:function(){return st(window.browserDetails.touchMoveEvent)?window.browserDetails.touchMoveEvent=n.getTouchMoveEvent():window.browserDetails.touchMoveEvent},enumerable:!0,configurable:!0}),Object.defineProperty(n,"touchEndEvent",{get:function(){return st(window.browserDetails.touchEndEvent)?window.browserDetails.touchEndEvent=n.getTouchEndEvent():window.browserDetails.touchEndEvent},enumerable:!0,configurable:!0}),Object.defineProperty(n,"touchCancelEvent",{get:function(){return st(window.browserDetails.touchCancelEvent)?window.browserDetails.touchCancelEvent=n.getTouchCancelEvent():window.browserDetails.touchCancelEvent},enumerable:!0,configurable:!0}),n.uA=typeof navigator<"u"?navigator.userAgent:"",n}(),E=function(){function n(){}return n.addOrGetEventData=function(t){return"__eventList"in t?t.__eventList.events:(t.__eventList={},t.__eventList.events=[])},n.add=function(t,e,i,r,s){var a,o=n.addOrGetEventData(t);a=s?function l$(n,t){var e;return function(){for(var i=this,r=[],s=0;s"u"||(e.innerHTML=t.innerHTML?t.innerHTML:"",void 0!==t.className&&(e.className=t.className),void 0!==t.id&&(e.id=t.id),void 0!==t.styles&&e.setAttribute("style",t.styles),void 0!==t.attrs&&Fe(e,t.attrs)),e}function V(n,t){for(var e=Vz(t),i=RegExp,r=0,s=n;r0}function pl(n,t,e){for(var i=document.createDocumentFragment(),r=0,s=n;r0;)i.appendChild(n[0]);else for(var r=0,s=n;r-1&&!r[parseInt(s.toString(),10)].match(/\[.*\]/)){var o=r[parseInt(s.toString(),10)].split("#");if(o[1].match(/^\d/)||o[1].match(t)){var a=r[parseInt(s.toString(),10)].split(".");a[0]=a[0].replace(/#/,"[id='")+"']",r[parseInt(s.toString(),10)]=a.join(".")}}e[parseInt(i.toString(),10)]=r.join(" ")}return e.join(",")}return n}function J(n,t){var e=n;if("function"==typeof e.closest)return e.closest(t);for(;e&&1===e.nodeType;){if(vC(e,t))return e;e=e.parentNode}return null}function je(n,t){void 0!==t&&Object.keys(t).forEach(function(e){n.style[""+e]=t[""+e]})}function vC(n,t){var e=n.matches||n.msMatchesSelector||n.webkitMatchesSelector;return e?e.call(n,t):-1!==[].indexOf.call(document.querySelectorAll(t),n)}var H$=new RegExp("]"),ah=function(){function n(t,e){this.isRendered=!1,this.isComplexArraySetter=!1,this.isServerRendered=!1,this.allowServerDataBinding=!0,this.isProtectedOnChange=!0,this.properties={},this.changedProperties={},this.oldProperties={},this.bulkChanges={},this.refreshing=!1,this.ignoreCollectionWatch=!1,this.finalUpdate=function(){},this.childChangedProperties={},this.modelObserver=new Ag(this),st(e)||(this.element="string"==typeof e?document.querySelector(e):e,m(this.element)||(this.isProtectedOnChange=!1,this.addInstance())),st(t)||this.setProperties(t,!0),this.isDestroyed=!1}return n.prototype.setProperties=function(t,e){var i=this.isProtectedOnChange;this.isProtectedOnChange=!!e,Nn(this,t),!0!==e?(Nn(this.changedProperties,t),this.dataBind()):ce()&&this.isRendered&&this.serverDataBind(t),this.finalUpdate(),this.changedProperties={},this.oldProperties={},this.isProtectedOnChange=i},n.callChildDataBind=function(t,e){for(var r=0,s=Object.keys(t);r=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Hs=function(n){function t(i){var r=n.call(this,i,void 0)||this;return r.easing={ease:"cubic-bezier(0.250, 0.100, 0.250, 1.000)",linear:"cubic-bezier(0.250, 0.250, 0.750, 0.750)",easeIn:"cubic-bezier(0.420, 0.000, 1.000, 1.000)",easeOut:"cubic-bezier(0.000, 0.000, 0.580, 1.000)",easeInOut:"cubic-bezier(0.420, 0.000, 0.580, 1.000)",elasticInOut:"cubic-bezier(0.5,-0.58,0.38,1.81)",elasticIn:"cubic-bezier(0.17,0.67,0.59,1.81)",elasticOut:"cubic-bezier(0.7,-0.75,0.99,1.01)"},r}var e;return X$(t,n),e=t,t.prototype.animate=function(i,r){var s=this.getModel(r=r||{});if("string"==typeof i)for(var a=0,l=Array.prototype.slice.call(we(i,document));a0?r-1:0,i+=e=-1!==e?"-"+e:"-"+r}return this.controlParent!==this.parentObj&&(i=this.parentObj.getParentKey()+"."+this.propName+e),i},n}(),J$=["grid","pivotview","treegrid","spreadsheet","rangeNavigator","DocumentEditor","listbox","inplaceeditor","PdfViewer","richtexteditor","DashboardLayout","chart","stockChart","circulargauge","diagram","heatmap","lineargauge","maps","slider","smithchart","barcode","sparkline","treemap","bulletChart","kanban","daterangepicker","schedule","gantt","signature","query-builder","drop-down-tree","carousel","filemanager","uploader","accordion","tab","treeview"],tR=[115,121,110,99,102,117,115,105,111,110,46,105,115,76,105,99,86,97,108,105,100,97,116,101,100],iR=function(){function n(t){this.isValidated=!1,this.isLicensed=!0,this.version="27",this.platform=/JavaScript|ASPNET|ASPNETCORE|ASPNETMVC|FileFormats|essentialstudio/i,this.errors={noLicense:"This application was built using a trial version of Syncfusion Essential Studio. To remove the license validation message permanently, a valid license key must be included.",trailExpired:"This application was built using a trial version of Syncfusion Essential Studio. To remove the license validation message permanently, a valid license key must be included.",versionMismatched:"The included Syncfusion license key is invalid.",platformMismatched:"The included Syncfusion license key is invalid.",invalidKey:"The included Syncfusion license key is invalid."},this.manager=function(){var e=null;return{setKey:function i(s){e=s},getKey:function r(){return e}}}(),this.npxManager=function(){return{getKey:function i(){return"npxKeyReplace"}}}(),this.manager.setKey(t)}return n.prototype.validate=function(){if(!this.isValidated&&tp&&!Y(x0(tR),tp)&&!Y("Blazor",tp)){var i=void 0,r=void 0;if(this.manager&&this.manager.getKey()||this.npxManager&&"npxKeyReplace"!==this.npxManager.getKey()){var s=this.getInfoFromKey();if(s&&s.length)for(var o=0,a=s;o"+i+' Claim your FREE account\n
have a Syncfusion account? Sign In
\n
\n ';if(typeof document<"u"&&!m(document)){var t=mi("div",{innerHTML:n});document.body.appendChild(t)}}(),oR=!0),this.render(),this.mount?this.accessMount():this.trigger("created")}},t.prototype.renderComplete=function(e){ce()&&window.sfBlazor.renderComplete(this.element,e),this.isRendered=!0},t.prototype.dataBind=function(){this.injectModules(),n.prototype.dataBind.call(this)},t.prototype.on=function(e,i,r){if("string"==typeof e)this.localObserver.on(e,i,r);else for(var s=0,o=e;s=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},rZ={left:0,top:0,bottom:0,right:0},bC={isDragged:!1},nZ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return aR(t,n),gr([I(0)],t.prototype,"left",void 0),gr([I(0)],t.prototype,"top",void 0),t}(Ee),op=function(n){function t(i,r){var s=n.call(this,r,i)||this;return s.dragLimit=e.getDefaultPosition(),s.borderWidth=e.getDefaultPosition(),s.padding=e.getDefaultPosition(),s.diffX=0,s.prevLeft=0,s.prevTop=0,s.dragProcessStarted=!1,s.eleTop=0,s.tapHoldTimer=0,s.externalInitialize=!1,s.diffY=0,s.parentScrollX=0,s.parentScrollY=0,s.droppables={},s.bind(),s}var e;return aR(t,n),e=t,t.prototype.bind=function(){this.toggleEvents(),X.isIE&&V([this.element],"e-block-touch"),this.droppables[this.scope]={}},t.getDefaultPosition=function(){return ze({},rZ)},t.prototype.toggleEvents=function(i){var r;st(this.handle)||(r=U(this.handle,this.element));var s=this.enableTapHold&&X.isDevice&&X.isTouch?this.mobileInitialize:this.initialize;i?E.remove(r||this.element,X.isSafari()?"touchstart":X.touchStartEvent,s):E.add(r||this.element,X.isSafari()?"touchstart":X.touchStartEvent,s,this)},t.prototype.mobileInitialize=function(i){var r=this,s=i.currentTarget;this.tapHoldTimer=setTimeout(function(){r.externalInitialize=!0,r.removeTapholdTimer(),r.initialize(i,s)},this.tapHoldThreshold),E.add(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.removeTapholdTimer,this),E.add(document,X.isSafari()?"touchend":X.touchEndEvent,this.removeTapholdTimer,this)},t.prototype.removeTapholdTimer=function(){clearTimeout(this.tapHoldTimer),E.remove(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.removeTapholdTimer),E.remove(document,X.isSafari()?"touchend":X.touchEndEvent,this.removeTapholdTimer)},t.prototype.getScrollableParent=function(i,r){return m(i)?null:i[{vertical:"scrollHeight",horizontal:"scrollWidth"}[""+r]]>i[{vertical:"clientHeight",horizontal:"clientWidth"}[""+r]]&&("vertical"===r?i.scrollTop>0:i.scrollLeft>0)?("vertical"===r?(this.parentScrollY=this.parentScrollY+(0===this.parentScrollY?i.scrollTop:i.scrollTop-this.parentScrollY),this.tempScrollHeight=i.scrollHeight):(this.parentScrollX=this.parentScrollX+(0===this.parentScrollX?i.scrollLeft:i.scrollLeft-this.parentScrollX),this.tempScrollWidth=i.scrollWidth),m(i)?i:this.getScrollableParent(i.parentNode,r)):this.getScrollableParent(i.parentNode,r)},t.prototype.getScrollableValues=function(){this.parentScrollX=0,this.parentScrollY=0,this.element.classList.contains("e-dialog")&&this.element.classList.contains("e-dlg-modal"),this.getScrollableParent(this.element.parentNode,"vertical"),this.getScrollableParent(this.element.parentNode,"horizontal")},t.prototype.initialize=function(i,r){if(this.currentStateTarget=i.target,!this.isDragStarted()){if(this.isDragStarted(!0),this.externalInitialize=!1,this.target=i.currentTarget||r,this.dragProcessStarted=!1,this.abort){var s=this.abort;"string"==typeof s&&(s=[s]);for(var o=0;o=this.distance||this.externalInitialize){var p=this.getHelperElement(i);if(!p||m(p))return;r&&i.preventDefault();var f=this.helperElement=p;if(this.parentClientRect=this.calculateParentPosition(f.offsetParent),this.dragStart){var v={event:i,element:l,target:this.getProperTargetElement(i),bindEvents:ce()?this.bindDragEvents.bind(this):null,dragElement:f};this.trigger("dragStart",v)}this.dragArea?this.setDragArea():(this.dragLimit={left:0,right:0,bottom:0,top:0},this.borderWidth={top:0,left:0}),o={left:this.position.left-this.parentClientRect.left,top:this.position.top-this.parentClientRect.top},this.clone&&!this.enableTailMode&&(this.diffX=this.position.left-this.offset.left,this.diffY=this.position.top-this.offset.top),this.getScrollableValues();var y=getComputedStyle(l),S=parseFloat(y.marginTop);this.clone&&0!==S&&(o.top+=S),this.eleTop=isNaN(parseFloat(y.top))?0:parseFloat(y.top)-this.offset.top,this.enableScrollHandler&&!this.clone&&(o.top-=this.parentScrollY,o.left-=this.parentScrollX);var b=this.getProcessedPositionValue({top:o.top-this.diffY+"px",left:o.left-this.diffX+"px"});this.dragArea&&"string"!=typeof this.dragArea&&this.dragArea.classList.contains("e-kanban-content")&&"relative"===this.dragArea.style.position&&(o.top+=this.dragArea.scrollTop),this.dragElePosition={top:o.top,left:o.left},je(f,this.getDragPosition({position:"absolute",left:b.left,top:b.top})),E.remove(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.intDragStart),E.remove(document,X.isSafari()?"touchend":X.touchEndEvent,this.intDestroy),ce()||this.bindDragEvents(f)}}},t.prototype.bindDragEvents=function(i){Tr(i)?(E.add(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.intDrag,this),E.add(document,X.isSafari()?"touchend":X.touchEndEvent,this.intDragStop,this),this.setGlobalDroppables(!1,this.element,i)):(this.toggleEvents(),document.body.classList.remove("e-prevent-select"))},t.prototype.elementInViewport=function(i){for(this.top=i.offsetTop,this.left=i.offsetLeft,this.width=i.offsetWidth,this.height=i.offsetHeight;i.offsetParent;)this.top+=(i=i.offsetParent).offsetTop,this.left+=i.offsetLeft;return this.top>=window.pageYOffset&&this.left>=window.pageXOffset&&this.top+this.height<=window.pageYOffset+window.innerHeight&&this.left+this.width<=window.pageXOffset+window.innerWidth},t.prototype.getProcessedPositionValue=function(i){return this.queryPositionInfo?this.queryPositionInfo(i):i},t.prototype.calculateParentPosition=function(i){if(m(i))return{left:0,top:0};var r=i.getBoundingClientRect(),s=getComputedStyle(i);return{left:r.left+window.pageXOffset-parseInt(s.marginLeft,10),top:r.top+window.pageYOffset-parseInt(s.marginTop,10)}},t.prototype.intDrag=function(i){if(st(i.changedTouches)||1===i.changedTouches.length){var r,s;this.clone&&i.changedTouches&&X.isDevice&&X.isTouch&&i.preventDefault(),this.position=this.getMousePosition(i,this.isDragScroll);var o=this.getDocumentWidthHeight("Height");oy&&y>0?this.dragLimit.left:this.dragLimit.right+window.pageXOffset0?y-(y-this.dragLimit.right)+window.pageXOffset-M:y<0?this.dragLimit.left:y}if(this.pageY!==v||this.skipDistanceCheck){var w=d.offsetHeight+(parseFloat(b.marginTop)+parseFloat(b.marginBottom));s=this.dragLimit.top>S&&S>0?this.dragLimit.top:this.dragLimit.bottom+window.pageYOffset0?S-(S-this.dragLimit.bottom)+window.pageYOffset-w:S<0?this.dragLimit.top:S}}else r=y,s=S;var A,x,C=p+this.borderWidth.top,D=u+this.borderWidth.left;if(this.dragProcessStarted&&(m(s)&&(s=this.prevTop),m(r)&&(r=this.prevLeft)),this.helperElement.classList.contains("e-treeview"))this.dragArea?(this.dragLimit.top=this.clone?this.dragLimit.top:0,A=s-C<0?this.dragLimit.top:s-this.borderWidth.top,x=r-D<0?this.dragLimit.left:r-this.borderWidth.left):(A=s-this.borderWidth.top,x=r-this.borderWidth.left);else if(this.dragArea){var R=this.helperElement.classList.contains("e-dialog");this.dragLimit.top=this.clone?this.dragLimit.top:0,A=s-C<0?this.dragLimit.top:s-C,x=r-D<0?R?r-(D-this.borderWidth.left):this.dragElePosition.left:r-D}else A=s-C,x=r-D;var L=parseFloat(getComputedStyle(this.element).marginTop);if(L>0&&(this.clone&&(A+=L,S<0&&(L+S>=0?A=L+S:A-=L),this.dragArea&&(A=this.dragLimit.bottom=0){var O=this.dragLimit.top+S-C;O+L+C<0?A-=L+C:A=O}else A-=L+C;this.dragArea&&this.helperElement.classList.contains("e-treeview")&&(A=A+(w=d.offsetHeight+(parseFloat(b.marginTop)+parseFloat(b.marginBottom)))>this.dragLimit.bottom?this.dragLimit.bottom-w:A),this.enableScrollHandler&&!this.clone&&(A-=this.parentScrollY,x-=this.parentScrollX),this.dragArea&&"string"!=typeof this.dragArea&&this.dragArea.classList.contains("e-kanban-content")&&"relative"===this.dragArea.style.position&&(A+=this.dragArea.scrollTop);var N=this.getProcessedPositionValue({top:A+"px",left:x+"px"});this.isPreventScroll&&(N=this.getProcessedPositionValue({top:this.position.top-this.parentClientRect.top-2+"px",left:this.position.left-this.parentClientRect.left-2+"px"})),je(d,this.getDragPosition(N)),!this.elementInViewport(d)&&this.enableAutoScroll&&!this.helperElement.classList.contains("e-treeview")&&this.helperElement.scrollIntoView();var T=document.querySelectorAll(":hover");if(this.enableAutoScroll&&this.helperElement.classList.contains("e-treeview")){0===T.length&&(T=this.getPathElements(i));var P=this.getScrollParent(T,!1);this.elementInViewport(this.helperElement)?this.getScrollPosition(P,A):this.elementInViewport(this.helperElement)||(0===(T=[].slice.call(document.querySelectorAll(":hover"))).length&&(T=this.getPathElements(i)),P=this.getScrollParent(T,!0),this.getScrollPosition(P,A))}this.dragProcessStarted=!0,this.prevLeft=r,this.prevTop=s,this.position.left=r,this.position.top=s,this.pageX=g,this.pageY=v}},t.prototype.getScrollParent=function(i,r){for(var o,s=r?i.reverse():i,a=s.length-1;a>=0;a--)if(("auto"===(o=window.getComputedStyle(s[parseInt(a.toString(),10)])["overflow-y"])||"scroll"===o)&&s[parseInt(a.toString(),10)].scrollHeight>s[parseInt(a.toString(),10)].clientHeight)return s[parseInt(a.toString(),10)];if("visible"===(o=window.getComputedStyle(document.scrollingElement)["overflow-y"]))return document.scrollingElement.style.overflow="auto",document.scrollingElement},t.prototype.getScrollPosition=function(i,r){if(i&&i===document.scrollingElement)i.clientHeight+document.scrollingElement.scrollTop-this.helperElement.clientHeightr?i.scrollTop+=this.helperElement.clientHeight:i.scrollTop>r-this.helperElement.clientHeight&&(i.scrollTop-=this.helperElement.clientHeight);else if(i&&i!==document.scrollingElement){var s=document.scrollingElement.scrollTop,o=this.helperElement.clientHeight;i.clientHeight+i.getBoundingClientRect().top-o+sr-o-s&&(i.scrollTop-=this.helperElement.clientHeight)}},t.prototype.getPathElements=function(i){return document.elementsFromPoint(i.clientX>0?i.clientX:0,i.clientY>0?i.clientY:0)},t.prototype.triggerOutFunction=function(i,r){this.hoverObject.instance.intOut(i,r.target),this.hoverObject.instance.dragData[this.scope]=null,this.hoverObject=null},t.prototype.getDragPosition=function(i){var r=ze({},i);return this.axis&&("x"===this.axis?delete r.top:"y"===this.axis&&delete r.left),r},t.prototype.getDocumentWidthHeight=function(i){var r=document.body,s=document.documentElement;return Math.max(r["scroll"+i],s["scroll"+i],r["offset"+i],s["offset"+i],s["client"+i])},t.prototype.intDragStop=function(i){if(this.dragProcessStarted=!1,st(i.changedTouches)||1===i.changedTouches.length){if(-1!==["touchend","pointerup","mouseup"].indexOf(i.type)){if(this.dragStop){var s=this.getProperTargetElement(i);this.trigger("dragStop",{event:i,element:this.element,target:s,helper:this.helperElement})}this.intDestroy(i)}else this.element.setAttribute("aria-grabbed","false");var o=this.checkTargetElement(i);o.target&&o.instance&&(o.instance.dragStopCalled=!0,o.instance.dragData[this.scope]=this.droppables[this.scope],o.instance.intDrop(i,o.target)),this.setGlobalDroppables(!0),document.body.classList.remove("e-prevent-select")}},t.prototype.intDestroy=function(i){this.dragProcessStarted=!1,this.toggleEvents(),document.body.classList.remove("e-prevent-select"),this.element.setAttribute("aria-grabbed","false"),E.remove(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.intDragStart),E.remove(document,X.isSafari()?"touchend":X.touchEndEvent,this.intDragStop),E.remove(document,X.isSafari()?"touchend":X.touchEndEvent,this.intDestroy),E.remove(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.intDrag),this.isDragStarted()&&this.isDragStarted(!0)},t.prototype.onPropertyChanged=function(i,r){},t.prototype.getModuleName=function(){return"draggable"},t.prototype.isDragStarted=function(i){return i&&(bC.isDragged=!bC.isDragged),bC.isDragged},t.prototype.setDragArea=function(){var i,r,a,s=0,o=0;if(a="string"==typeof this.dragArea?U(this.dragArea):this.dragArea){var h=a.getBoundingClientRect();i=a.scrollWidth?a.scrollWidth:h.right-h.left,r=a.scrollHeight?this.dragArea&&!m(this.helperElement)&&this.helperElement.classList.contains("e-treeview")?a.clientHeight:a.scrollHeight:h.bottom-h.top;for(var c=["Top","Left","Bottom","Right"],d=getComputedStyle(a),u=0;u12;return w0(i.target,this.helperElement)||-1!==i.type.indexOf("touch")||a?(this.helperElement.style.pointerEvents="none",s=document.elementFromPoint(r.clientX,r.clientY),this.helperElement.style.pointerEvents=o):s=i.target,s},t.prototype.currentStateCheck=function(i,r){return m(this.currentStateTarget)||this.currentStateTarget===i?m(r)?i:r:this.currentStateTarget},t.prototype.getMousePosition=function(i,r){var a,l,s=void 0!==i.srcElement?i.srcElement:i.target,o=this.getCoordinates(i),h=m(s.offsetParent);if(r?(a=this.clone?o.pageX:o.pageX+(h?0:s.offsetParent.scrollLeft)-this.relativeXPosition,l=this.clone?o.pageY:o.pageY+(h?0:s.offsetParent.scrollTop)-this.relativeYPosition):(a=this.clone?o.pageX:o.pageX+window.pageXOffset-this.relativeXPosition,l=this.clone?o.pageY:o.pageY+window.pageYOffset-this.relativeYPosition),document.scrollingElement&&!r&&!this.clone){var c=document.scrollingElement;a=c.scrollWidth>0&&c.scrollWidth>c.clientWidth&&c.scrollLeft>0?a-c.scrollLeft:a,l=c.scrollHeight>0&&c.scrollHeight>c.clientHeight&&c.scrollTop>0?l-c.scrollTop:l}return{left:a-(this.margin.left+this.cursorAt.left),top:l-(this.margin.top+this.cursorAt.top)}},t.prototype.getCoordinates=function(i){return i.type.indexOf("touch")>-1?i.changedTouches[0]:i},t.prototype.getHelperElement=function(i){var r;return this.clone?this.helper?r=this.helper({sender:i,element:this.target}):(r=mi("div",{className:"e-drag-helper e-block-touch",innerHTML:"Draggable"}),document.body.appendChild(r)):r=this.element,r},t.prototype.setGlobalDroppables=function(i,r,s){this.droppables[this.scope]=i?null:{draggable:r,helper:s,draggedElement:this.element}},t.prototype.checkTargetElement=function(i){var r=this.getProperTargetElement(i),s=this.getDropInstance(r);if(!s&&r&&!m(r.parentNode)){var o=J(r.parentNode,".e-droppable")||r.parentElement;o&&(s=this.getDropInstance(o))}return{target:r,instance:s}},t.prototype.getDropInstance=function(i){var s,o=i&&i.ej2_instances;if(o)for(var a=0,l=o;a=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},lR=function(n){function t(e,i){var r=n.call(this,i,e)||this;return r.mouseOver=!1,r.dragData={},r.dragStopCalled=!1,r.bind(),r}return sZ(t,n),t.prototype.bind=function(){this.wireEvents()},t.prototype.wireEvents=function(){E.add(this.element,X.isSafari()?"touchend":X.touchEndEvent,this.intDrop,this)},t.prototype.onPropertyChanged=function(e,i){},t.prototype.getModuleName=function(){return"droppable"},t.prototype.intOver=function(e,i){this.mouseOver||(this.trigger("over",{event:e,target:i,dragData:this.dragData[this.scope]}),this.mouseOver=!0)},t.prototype.intOut=function(e,i){this.mouseOver&&(this.trigger("out",{evt:e,target:i}),this.mouseOver=!1)},t.prototype.intDrop=function(e,i){if(this.dragStopCalled){this.dragStopCalled=!1;var a,r=!0,s=this.dragData[this.scope],o=!!s&&s.helper&&Tr(s.helper);o&&(a=this.isDropArea(e,s.helper,i),this.accept&&(r=vC(s.helper,this.accept))),o&&this.drop&&a.canDrop&&r&&this.trigger("drop",{event:e,target:a.target,droppedElement:s.helper,dragData:s}),this.mouseOver=!1}},t.prototype.isDropArea=function(e,i,r){var s={canDrop:!0,target:r||e.target},o="touchend"===e.type;if(o||s.target===i){i.style.display="none";var a=o?e.changedTouches[0]:e,l=document.elementFromPoint(a.clientX,a.clientY);s.canDrop=!1,s.canDrop=w0(l,this.element),s.canDrop&&(s.target=l),i.style.display=""}return s},t.prototype.destroy=function(){E.remove(this.element,X.isSafari()?"touchend":X.touchEndEvent,this.intDrop),n.prototype.destroy.call(this)},ap([I()],t.prototype,"accept",void 0),ap([I("default")],t.prototype,"scope",void 0),ap([H()],t.prototype,"drop",void 0),ap([H()],t.prototype,"over",void 0),ap([H()],t.prototype,"out",void 0),ap([Ft],t)}(ah),ho=function(){function n(t,e,i){this.controlName=t,this.localeStrings=e,this.setLocale(i||"en-US")}return n.prototype.setLocale=function(t){var e=this.intGetControlConstant(n.locale,t);this.currentLocale=e||this.localeStrings},n.load=function(t){this.locale=ze(this.locale,t,{},!0)},n.prototype.getConstant=function(t){return m(this.currentLocale[""+t])?this.localeStrings[""+t]||"":this.currentLocale[""+t]},n.prototype.intGetControlConstant=function(t,e){return t[""+e]?t[""+e][this.controlName]:null},n.locale={},n}(),hR=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),hh=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},lZ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return hR(t,n),hh([I(50)],t.prototype,"swipeThresholdDistance",void 0),t}(Ee),hZ=/(Up|Down)/,Fs=function(n){function t(e,i){var r=n.call(this,i,e)||this;return r.touchAction=!0,r.tapCount=0,r.startEvent=function(s){if(!0===r.touchAction){var o=r.updateChangeTouches(s);void 0!==s.changedTouches&&(r.touchAction=!1),r.isTouchMoved=!1,r.movedDirection="",r.startPoint=r.lastMovedPoint={clientX:o.clientX,clientY:o.clientY},r.startEventData=o,r.hScrollLocked=r.vScrollLocked=!1,r.tStampStart=Date.now(),r.timeOutTapHold=setTimeout(function(){r.tapHoldEvent(s)},r.tapHoldThreshold),E.add(r.element,X.touchMoveEvent,r.moveEvent,r),E.add(r.element,X.touchEndEvent,r.endEvent,r),E.add(r.element,X.touchCancelEvent,r.cancelEvent,r)}},r.moveEvent=function(s){var o=r.updateChangeTouches(s);r.movedPoint=o,r.isTouchMoved=!(o.clientX===r.startPoint.clientX&&o.clientY===r.startPoint.clientY);var a={};r.isTouchMoved&&(clearTimeout(r.timeOutTapHold),r.calcScrollPoints(s),a=ze(a,{},{startEvents:r.startEventData,originalEvent:s,startX:r.startPoint.clientX,startY:r.startPoint.clientY,distanceX:r.distanceX,distanceY:r.distanceY,scrollDirection:r.scrollDirection,velocity:r.getVelocity(o)}),r.trigger("scroll",a),r.lastMovedPoint={clientX:o.clientX,clientY:o.clientY})},r.cancelEvent=function(s){clearTimeout(r.timeOutTapHold),clearTimeout(r.timeOutTap),r.tapCount=0,r.swipeFn(s),E.remove(r.element,X.touchCancelEvent,r.cancelEvent)},r.endEvent=function(s){r.swipeFn(s),r.isTouchMoved||"function"==typeof r.tap&&(r.trigger("tap",{originalEvent:s,tapCount:++r.tapCount}),r.timeOutTap=setTimeout(function(){r.tapCount=0},r.tapThreshold)),r.modeclear()},r.swipeFn=function(s){clearTimeout(r.timeOutTapHold),clearTimeout(r.timeOutTap);var o=r.updateChangeTouches(s),a=o.clientX-r.startPoint.clientX,l=o.clientY-r.startPoint.clientY;a=Math.floor(a<0?-1*a:a),l=Math.floor(l<0?-1*l:a),r.isTouchMoved=a>1||l>1,/Firefox/.test(X.userAgent)&&0===o.clientX&&0===o.clientY&&"mouseup"===s.type&&(r.isTouchMoved=!1),r.endPoint=o,r.calcPoints(s);var c={originalEvent:s,startEvents:r.startEventData,startX:r.startPoint.clientX,startY:r.startPoint.clientY,distanceX:r.distanceX,distanceY:r.distanceY,swipeDirection:r.movedDirection,velocity:r.getVelocity(o)};if(r.isTouchMoved){var d=r.swipeSettings.swipeThresholdDistance,u=ze(void 0,r.defaultArgs,c),p=!1,f=r.element,g=r.isScrollable(f),v=hZ.test(r.movedDirection);(dthis.distanceY?i.clientX>this.startPoint.clientX?"Right":"Left":i.clientYthis.distanceY||!0===this.hScrollLocked)&&!1===this.vScrollLocked?(this.scrollDirection=i.clientX>this.lastMovedPoint.clientX?"Right":"Left",this.hScrollLocked=!0):(this.scrollDirection=i.clientY=e[r[0]+s[0]]},t.prototype.updateChangeTouches=function(e){return e.changedTouches&&0!==e.changedTouches.length?e.changedTouches[0]:e},hh([H()],t.prototype,"tap",void 0),hh([H()],t.prototype,"tapHold",void 0),hh([H()],t.prototype,"swipe",void 0),hh([H()],t.prototype,"scroll",void 0),hh([I(350)],t.prototype,"tapThreshold",void 0),hh([I(750)],t.prototype,"tapHoldThreshold",void 0),hh([re({},lZ)],t.prototype,"swipeSettings",void 0),hh([Ft],t)}(ah),cZ=new RegExp("\\n|\\r|\\s\\s+","g"),dZ=new RegExp(/'|"/g),uZ=new RegExp("if ?\\("),pZ=new RegExp("else if ?\\("),cR=new RegExp("else"),fZ=new RegExp("for ?\\("),dR=new RegExp("(/if|/for)"),gZ=new RegExp("\\((.*)\\)",""),MC=new RegExp("^[0-9]+$","g"),vZ=new RegExp("[\\w\"'.\\s+]+","g"),mZ=new RegExp('"(.*?)"',"g"),yZ=new RegExp("[\\w\"'@#$.\\s-+]+","g"),uR=new RegExp("\\${([^}]*)}","g"),SZ=/^\..*/gm,wC=/\\/gi,IZ=/\\\\/gi,bZ=new RegExp("[\\w\"'@#$.\\s+]+","g"),MZ=/\window\./gm;function lp(n,t,e,i,r){return!t||MC.test(n)||-1!==i.indexOf(n.split(".")[0])||r||"true"===n||"false"===n?n:e+"."+n}function CC(n,t,e,i){return t&&!MC.test(n)&&-1===i.indexOf(n.split(".")[0])?e+'["'+n:n}function pR(n){return n.match(IZ)?n:n.replace(wC,"\\\\")}function fR(n,t,e,i){if(n=n.trim(),/\window\./gm.test(n))return n;var s=/'|"/gm;return/@|\$|#/gm.test(n)&&(n=CC(n,-1===e.indexOf(n),t,e)+'"]'),SZ.test(n)?function EZ(n,t,e,i){return!t||MC.test(n)||-1!==i.indexOf(n.split(".")[0])||/^\..*/gm.test(n)?n:e+"."+n}(n,!s.test(n)&&-1===e.indexOf(n),t,e):lp(n,!s.test(n)&&-1===e.indexOf(n),t,e,i)}var DZ=/^[\n\r.]+0&&t.forEach(function(e){he(e)})},n.removeJsEvents=function(){var t=this.wrapElement.querySelectorAll("["+vR.join("],[")+"]");t.length>0&&t.forEach(function(e){vR.forEach(function(i){e.hasAttribute(i)&&e.removeAttribute(i)})})},n.removeXssAttrs=function(){var t=this;this.removeAttrs.forEach(function(e,i){var r=t.wrapElement.querySelectorAll(e.selector);r.length>0&&r.forEach("a[href]"===e.selector?function(s){-1!==s.getAttribute(e.attribute).replace(/\t|\s|&/,"").indexOf("javascript:alert")&&s.removeAttribute(e.attribute)}:function(s){s.removeAttribute(e.attribute)})})},n}();function PZ(n){return function(t){!function kZ(n,t){t.forEach(function(e){Object.getOwnPropertyNames(e.prototype).forEach(function(i){(!Object.prototype.hasOwnProperty.call(n.prototype,i)||e.isFormBase&&"constructor"!==i)&&(n.prototype["".concat(i)]=e.prototype["".concat(i)])})})}(t,n)}}function mR(n,t,e){var i={};if(n&&n.length){for(var r=0,s=n;r"u"||(y.innerHTML=v.innerHTML?v.innerHTML:"",void 0!==v.className&&(y.className=v.className),void 0!==v.id&&(y.id=v.id),void 0!==v.styles&&y.setAttribute("style",v.styles),void 0!==e.ngAttr&&y.setAttribute(e.ngAttr,""),void 0!==v.attrs&&Fe(y,v.attrs)),y};for(var i=0,r=e.tags;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s}function jZ(n){for(var t,e=n.childNodes,i=0;i"u"&&(c["".concat(o)]=[]),c["".concat(o)].push(h),h.rootNodes}}});var ml,ad,ph,jg,sc,uo,YZ=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),La=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Jo_RTL=(new Ag,"e-rtl"),ys=function(n){function t(e,i){return n.call(this,e,i)||this}return YZ(t,n),t.prototype.preRender=function(){},t.prototype.render=function(){this.initialize(),this.removeRippleEffect=function ms(n,t,e){var i=function q$(n){return{selector:n&&n.selector?n.selector:null,ignore:n&&n.ignore?n.ignore:null,rippleFlag:n&&n.rippleFlag,isCenterRipple:n&&n.isCenterRipple,duration:n&&n.duration?n.duration:350}}(t);return!1===i.rippleFlag||void 0===i.rippleFlag&&!Zo?function(){}:(n.setAttribute("data-ripple","true"),E.add(n,"mousedown",Zz,{parent:n,rippleOptions:i}),E.add(n,"mouseup",Jz,{parent:n,rippleOptions:i,done:e}),E.add(n,"mouseleave",sp,{parent:n,rippleOptions:i}),X.isPointer&&E.add(n,"transitionend",sp,{parent:n,rippleOptions:i}),function(){n.removeAttribute("data-ripple"),E.remove(n,"mousedown",Zz),E.remove(n,"mouseup",Jz),E.remove(n,"mouseleave",sp),E.remove(n,"transitionend",sp)})}(this.element,{selector:".e-btn"}),this.renderComplete()},t.prototype.initialize=function(){if(this.cssClass&&V([this.element],this.cssClass.replace(/\s+/g," ").trim().split(" ")),this.isPrimary&&this.element.classList.add("e-primary"),!ce()||ce()&&"progress-btn"!==this.getModuleName()){if(this.content){var e=this.enableHtmlSanitizer?Ti.sanitize(this.content):this.content;this.element.innerHTML=e}this.setIconCss()}this.enableRtl&&this.element.classList.add(Jo_RTL),this.disabled?this.controlStatus(this.disabled):this.wireEvents()},t.prototype.controlStatus=function(e){this.element.disabled=e},t.prototype.setIconCss=function(){if(this.iconCss){var e=this.createElement("span",{className:"e-btn-icon "+this.iconCss});this.element.textContent.trim()?(e.classList.add("e-icon-"+this.iconPosition.toLowerCase()),("Top"===this.iconPosition||"Bottom"===this.iconPosition)&&this.element.classList.add("e-"+this.iconPosition.toLowerCase()+"-icon-btn")):this.element.classList.add("e-icon-btn");var i=this.element.childNodes[0];!i||"Left"!==this.iconPosition&&"Top"!==this.iconPosition?this.element.appendChild(e):this.element.insertBefore(e,i)}},t.prototype.wireEvents=function(){this.isToggle&&E.add(this.element,"click",this.btnClickHandler,this)},t.prototype.unWireEvents=function(){this.isToggle&&E.remove(this.element,"click",this.btnClickHandler)},t.prototype.btnClickHandler=function(){this.element.classList.contains("e-active")?this.element.classList.remove("e-active"):this.element.classList.add("e-active")},t.prototype.destroy=function(){var e=["e-primary",Jo_RTL,"e-icon-btn","e-success","e-info","e-danger","e-warning","e-flat","e-outline","e-small","e-bigger","e-active","e-round","e-top-icon-btn","e-bottom-icon-btn"];this.cssClass&&(e=e.concat(this.cssClass.split(" "))),n.prototype.destroy.call(this),K([this.element],e),this.element.getAttribute("class")||this.element.removeAttribute("class"),this.disabled&&this.element.removeAttribute("disabled"),this.content&&(this.element.innerHTML=this.element.innerHTML.replace(this.content,""));var i=this.element.querySelector("span.e-btn-icon");i&&he(i),this.unWireEvents(),Zo&&this.removeRippleEffect()},t.prototype.getModuleName=function(){return"btn"},t.prototype.getPersistData=function(){return this.addOnPersist([])},t.Inject=function(){},t.prototype.onPropertyChanged=function(e,i){for(var r=this.element.querySelector("span.e-btn-icon"),s=0,o=Object.keys(e);s=ad.width?ad.width:0;return ml.right+JR()-n}function dE(){return _0()+ml.width/2}function uE(n,t,e,i){if(void 0===t&&(t=null),void 0===e&&(e={X:!1,Y:!1}),!e.Y&&!e.X)return{left:0,top:0};var r=n.getBoundingClientRect();if(uo=t,sc=n.ownerDocument,i||(i=is(n,"left","top")),e.X){var s=uo?r4():l4(),o=mE(),a=yE(),l=o-i.left,h=i.left+r.width-a;r.width>s?i.left=l>0&&h<=0?a-r.width:h>0&&l<=0?o:l>h?a-r.width:o:l>0?i.left+=l:h>0&&(i.left-=h)}if(e.Y){var c=uo?n4():a4(),d=vE(),u=SE(),p=d-i.top,f=i.top+r.height-u;r.height>c?i.top=p>0&&f<=0?u-r.height:f>0&&p<=0?d:p>f?u-r.height:d:p>0?i.top+=p:f>0&&(i.top-=f)}return i}function oc(n,t,e,i){void 0===t&&(t=null);var r=is(n,"left","top");e&&(r.left=e),i&&(r.top=i);var s=[];uo=t,sc=n.ownerDocument;var o=n.getBoundingClientRect(),l=r.left,h=r.left+o.width,d=gE(r.top,r.top+o.height),u=e4(l,h);return d.topSide&&s.push("top"),u.rightSide&&s.push("right"),u.leftSide&&s.push("left"),d.bottomSide&&s.push("bottom"),s}function bJ(n,t,e,i,r,s,o,a,l){if(void 0===o&&(o=null),void 0===a&&(a={X:!0,Y:!0}),t&&n&&r&&s&&(a.X||a.Y)){var d,h={TL:null,TR:null,BL:null,BR:null},c={TL:null,TR:null,BL:null,BR:null};if("none"===window.getComputedStyle(n).display){var u=n.style.visibility;n.style.visibility="hidden",n.style.display="block",d=n.getBoundingClientRect(),n.style.removeProperty("display"),n.style.visibility=u}else d=n.getBoundingClientRect();var p={posX:r,posY:s,offsetX:e,offsetY:i,position:{left:0,top:0}};uo=o,sc=t.ownerDocument,function wJ(n,t,e,i,r){e.position=is(n,e.posX,e.posY,i,r),t.TL=is(n,"left","top",i,r),t.TR=is(n,"right","top",i,r),t.BR=is(n,"left","bottom",i,r),t.BL=is(n,"right","bottom",i,r)}(t,h,p,l,d),fE(c,p,d),a.X&&t4(t,c,h,p,d,!0),a.Y&&h.TL.top>-1&&i4(t,c,h,p,d,!0),function MJ(n,t,e){var i=0,r=0;if(null!=n.offsetParent&&("absolute"===getComputedStyle(n.offsetParent).position||"relative"===getComputedStyle(n.offsetParent).position)){var s=is(n.offsetParent,"left","top",!1,e);i=s.left,r=s.top}var o=1,a=1,l=KR(n);if(l){var h=getComputedStyle(l).transform;if("none"!==h){var c=new DOMMatrix(h);o=c.a,a=c.d}if("none"!==getComputedStyle(l).zoom){var u=pE(document.body);o*=u,a*=u}}n.style.top=t.position.top/a+t.offsetY-r/a+"px",n.style.left=t.position.left/o+t.offsetX-i/o+"px"}(n,p,d)}}function pE(n){var t=getComputedStyle(n).zoom;return parseFloat(t)||1}function KR(n){for(;n;){var t=window.getComputedStyle(n).transform,e=pE(document.body);if(t&&"none"!==t||e&&1!==e)return n;if(n===document.body)return null;n=n.offsetParent||n.parentElement}return null}function fE(n,t,e){n.TL={top:t.position.top+t.offsetY,left:t.position.left+t.offsetX},n.TR={top:n.TL.top,left:n.TL.left+e.width},n.BL={top:n.TL.top+e.height,left:n.TL.left},n.BR={top:n.TL.top+e.height,left:n.TL.left+e.width}}function e4(n,t){var e=!1,i=!1;return n-j0()yE()&&(i=!0),{leftSide:e,rightSide:i}}function t4(n,t,e,i,r,s){var o=e4(t.TL.left,t.TR.left),a=gE(t.TL.top,t.BL.top);e.TL.left-j0()<=mE()&&(o.leftSide=!1),e.TR.left>yE()&&(o.rightSide=!1),(o.leftSide&&!o.rightSide||!o.leftSide&&o.rightSide)&&(i.posX="right"===i.posX?"left":"right",i.offsetX=i.offsetX+r.width,i.offsetX=-1*i.offsetX,i.position=is(n,i.posX,i.posY,!1),fE(t,i,r),s&&t4(n,t,e,i,r,!1),!o.leftSide&&o.rightSide&&a.bottomSide&&(i.offsetX=0))}function i4(n,t,e,i,r,s){var o=gE(t.TL.top,t.BL.top);e.TL.top-U0()<=vE()&&(o.topSide=!1),e.BL.top>=SE()&&n.getBoundingClientRect().bottomSE()&&(i=!0),{topSide:e,bottomSide:i}}function r4(){return uo.getBoundingClientRect().width}function n4(){return uo.getBoundingClientRect().height}function s4(){return uo.getBoundingClientRect().left}function o4(){return uo.getBoundingClientRect().top}function vE(){return uo?o4():0}function mE(){return uo?s4():0}function yE(){return uo?j0()+s4()+r4():j0()+l4()}function SE(){return uo?U0()+o4()+n4():U0()+a4()}function U0(){return sc.documentElement.scrollTop||sc.body.scrollTop}function j0(){return sc.documentElement.scrollLeft||sc.body.scrollLeft}function a4(){return window.innerHeight}function l4(){var n=window.innerWidth,t=document.documentElement.getBoundingClientRect();return n-(n-(m(document.documentElement)?0:t.width))}function h4(){uo=null,sc=null}var c4=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),bn=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},d4=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return c4(t,n),bn([I("left")],t.prototype,"X",void 0),bn([I("top")],t.prototype,"Y",void 0),t}(Ee),Gn_OPEN="e-popup-open",Gn_CLOSE="e-popup-close",ac=function(n){function t(e,i){return n.call(this,i,e)||this}return c4(t,n),t.prototype.onPropertyChanged=function(e,i){for(var r=0,s=Object.keys(e);r0&&c.left>0&&c.right>0&&c.bottom>0}var s=i.getBoundingClientRect();return!(r.bottoms.bottom||r.right>s.right||r.leftr.top?this.element.style.top="0px":s.bottomr.left&&(this.element.style.left=parseInt(this.element.style.left,10)+(s.left-r.left)+"px"))}},t.prototype.checkCollision=function(){var e=this.collision.X,i=this.collision.Y;"none"===e&&"none"===i||("flip"===e&&"flip"===i?this.callFlip({X:!0,Y:!0}):"fit"===e&&"fit"===i?this.callFit({X:!0,Y:!0}):("flip"===e?this.callFlip({X:!0,Y:!1}):"flip"===i&&this.callFlip({Y:!0,X:!1}),"fit"===e?this.callFit({X:!0,Y:!1}):"fit"===i&&this.callFit({X:!1,Y:!0})))},t.prototype.show=function(e,i){var r=this;if(this.getRelateToElement().classList.contains("e-filemanager")&&(this.fmDialogContainer=this.element.getElementsByClassName("e-file-select-wrap")[0]),this.wireEvents(),!m(this.fmDialogContainer)&&X.isIos&&(this.fmDialogContainer.style.display="block"),1e3===this.zIndex||!m(i)){var o=m(i)?this.element:i;this.zIndex=lc(o),je(this.element,{zIndex:this.zIndex})}e=m(e)||"object"!=typeof e?this.showAnimation:e,("none"!==this.collision.X||"none"!==this.collision.Y)&&(K([this.element],Gn_CLOSE),V([this.element],Gn_OPEN),this.checkCollision(),K([this.element],Gn_OPEN),V([this.element],Gn_CLOSE)),m(e)?(K([this.element],Gn_CLOSE),V([this.element],Gn_OPEN),this.trigger("open")):(e.begin=function(){r.isDestroyed||(K([r.element],Gn_CLOSE),V([r.element],Gn_OPEN))},e.end=function(){r.isDestroyed||r.trigger("open")},new Hs(e).animate(this.element))},t.prototype.hide=function(e){var i=this;e=m(e)||"object"!=typeof e?this.hideAnimation:e,m(e)?(K([this.element],Gn_OPEN),V([this.element],Gn_CLOSE),this.trigger("close")):(e.end=function(){i.isDestroyed||(K([i.element],Gn_OPEN),V([i.element],Gn_CLOSE),i.trigger("close"))},new Hs(e).animate(this.element)),this.unwireEvents()},t.prototype.getScrollableParent=function(e){return this.checkFixedParent(e),function IE(n,t){for(var e=getComputedStyle(n),i=[],r=/(auto|scroll)/,s=n.parentElement;s&&"HTML"!==s.tagName;){var o=getComputedStyle(s);!("absolute"===e.position&&"static"===o.position)&&r.test(o.overflow+o.overflowY+o.overflowX)&&i.push(s),s=s.parentElement}return t||i.push(document),i}(e,this.fixedParent)},t.prototype.checkFixedParent=function(e){for(var i=e.parentElement;i&&"HTML"!==i.tagName;){var r=getComputedStyle(i);("fixed"===r.position||"sticky"===r.position)&&!m(this.element)&&this.element.offsetParent&&"BODY"===this.element.offsetParent.tagName&&"hidden"!==getComputedStyle(this.element.offsetParent).overflow&&(this.element.style.top=window.scrollY>parseInt(this.element.style.top,10)?Re(window.scrollY-parseInt(this.element.style.top,10)):Re(parseInt(this.element.style.top,10)-window.scrollY),this.element.style.position="fixed",this.fixedParent=!0),i=i.parentElement,!m(this.element)&&m(this.element.offsetParent)&&"fixed"===r.position&&"fixed"===this.element.style.position&&(this.fixedParent=!0)}},bn([I("auto")],t.prototype,"height",void 0),bn([I("auto")],t.prototype,"width",void 0),bn([I(null)],t.prototype,"content",void 0),bn([I("container")],t.prototype,"targetType",void 0),bn([I(null)],t.prototype,"viewPortElement",void 0),bn([I({X:"none",Y:"none"})],t.prototype,"collision",void 0),bn([I("")],t.prototype,"relateTo",void 0),bn([re({},d4)],t.prototype,"position",void 0),bn([I(0)],t.prototype,"offsetX",void 0),bn([I(0)],t.prototype,"offsetY",void 0),bn([I(1e3)],t.prototype,"zIndex",void 0),bn([I(!1)],t.prototype,"enableRtl",void 0),bn([I("reposition")],t.prototype,"actionOnScroll",void 0),bn([I(null)],t.prototype,"showAnimation",void 0),bn([I(null)],t.prototype,"hideAnimation",void 0),bn([H()],t.prototype,"open",void 0),bn([H()],t.prototype,"close",void 0),bn([H()],t.prototype,"targetExitViewport",void 0),bn([Ft],t)}(yi);function lc(n){for(var t=n.parentElement,e=[];t&&"BODY"!==t.tagName;){var i=document.defaultView.getComputedStyle(t,null).getPropertyValue("z-index"),r=document.defaultView.getComputedStyle(t,null).getPropertyValue("position");"auto"!==i&&"static"!==r&&e.push(i),t=t.parentElement}for(var s=[],o=0;o2147483647?2147483647:c}var _i,Oa,hp,vh,CE,mh,$t,yh,bE=["north-west","north","north-east","west","east","south-west","south","south-east"],Vg="e-resize-handle",hc="e-focused-handle",CJ="e-dlg-resizable",u4=["e-restrict-left"],p4="e-resize-viewport",EJ=["north","west","east","south"],ME=0,wE=0,f4=0,g4=0,Wg=0,Yg=0,Qg=null,EE=null,DE=null,V0=!0,v4=0,xE=!0;function xJ(n){TE();var t=mi("span",{attrs:{unselectable:"on",contenteditable:"false"}});t.setAttribute("class","e-dialog-border-resize e-"+n),"south"===n&&(t.style.height="2px",t.style.width="100%",t.style.bottom="0px",t.style.left="0px"),"north"===n&&(t.style.height="2px",t.style.width="100%",t.style.top="0px",t.style.left="0px"),"east"===n&&(t.style.height="100%",t.style.width="2px",t.style.right="0px",t.style.top="0px"),"west"===n&&(t.style.height="100%",t.style.width="2px",t.style.left="0px",t.style.top="0px"),_i.appendChild(t)}function m4(n){var t;return m(n)||(t="string"==typeof n?document.querySelector(n):n),t}function y4(n){for(var t=n||this,e=_i.querySelectorAll("."+Vg),i=0;i-1?"mouse":"touch"}function I4(n){if(n.preventDefault(),_i=n.target.parentElement,TE(),Wg=n.pageX,Yg=n.pageY,n.target.classList.add(hc),m(Qg)||!0!==Qg(n,this)){this.targetEle&&_i&&_i.querySelector("."+CJ)&&($t="body"===this.target?null:this.targetEle,mh=this.targetEle.clientWidth,vh=this.targetEle.clientHeight);var e=m($t)?document:$t;E.add(e,"mousemove",Gg,this),E.add(document,"mouseup",W0,this);for(var i=0;i=0||s.top<0)&&(e=!0):e=!0;var a=wE+(r-Yg);a=a>hp?a:hp;var l=0;m($t)||(l=o.top);var h=m($t)?0:$t.offsetHeight-$t.clientHeight,c=s.top-l-h/2;if(c=c<0?0:c,s.top>0&&c+a>vh){if(e=!1,_i.classList.contains(p4))return;_i.style.height=vh-parseInt(c.toString(),10)+"px"}else{var d=0;if(e){s.top<0&&t+(s.height+s.top)>0&&a+(d=s.top)<=30&&(a=s.height-(s.height+s.top)+30),a+s.top>=vh&&(_i.style.height=s.height+(t-(s.height+s.top))+"px");var u=m($t)?d:c;a>=hp&&a+u<=vh&&(_i.style.height=a+"px")}}}function LE(n){var e,t=!1,i="mouse"===S4(n.type)?n.pageY:n.touches[0].pageY,r=cc(_i),s=m($t)?0:$t.offsetHeight-$t.clientHeight;m($t)||(e=cc($t)),(!m($t)&&r.top-e.top>0||m($t)&&i>0||!m($t)&&Math.floor(r.top-e.top+r.height+(e.bottom-r.bottom))-s<=vh)&&(t=!0);var o=wE-(i-Yg);if(t&&o>=hp&&o<=vh){var a=0;m($t)||(a=e.top);var l=g4-a+(i-Yg);l=l>0?l:1,_i.style.height=o+"px",_i.style.top=l+"px"}}function NE(n){var i,t=document.documentElement.clientWidth,e=!1;m($t)||(i=cc($t));var r="mouse"===S4(n.type)?n.pageX:n.touches[0].pageX,s=cc(_i),o=m($t)?0:$t.offsetWidth-$t.clientWidth,a=m($t)?0:i.left,l=m($t)?0:i.width;m(yh)&&(m($t)?yh=t:(yh=s.left-a-o/2+s.width,yh+=l-o-yh)),(!m($t)&&Math.floor(s.left-i.left+s.width+(i.right-s.right))-o<=mh||m($t)&&r>=0)&&(e=!0);var h=ME-(r-Wg);if(V0&&(h=h>yh?yh:h),e&&h>=CE&&h<=mh){var c=0;m($t)||(c=i.left);var d=f4-c+(r-Wg);d=d>0?d:1,h!==v4&&xE&&(_i.style.width=h+"px"),V0&&(_i.style.left=d+"px",xE=1!==d)}v4=h}function OE(n){var i,t=document.documentElement.clientWidth,e=!1;m($t)||(i=cc($t));var s=(n.touches?n.changedTouches[0]:n).pageX,o=cc(_i);(!m($t)&&(o.left-i.left+o.width<=mh||o.right-i.left>=o.width)||m($t)&&t-s>0)&&(e=!0);var a=ME+(s-Wg),l=0;if(m($t)||(l=i.left),o.left-l+a>mh){if(e=!1,_i.classList.contains(p4))return;_i.style.width=mh-(o.left-l)+"px"}e&&a>=CE&&a<=mh&&(_i.style.width=a+"px")}function M4(){for(var n=_i.querySelectorAll("."+Vg),t=0;t=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},OJ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return kE(t,n),Zt([I(!0)],t.prototype,"isFlat",void 0),Zt([I()],t.prototype,"buttonModel",void 0),Zt([I("Button")],t.prototype,"type",void 0),Zt([H()],t.prototype,"click",void 0),t}(Ee),kJ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return kE(t,n),Zt([I("Fade")],t.prototype,"effect",void 0),Zt([I(400)],t.prototype,"duration",void 0),Zt([I(0)],t.prototype,"delay",void 0),t}(Ee),Y0="e-dialog",PE="e-rtl",zE="e-dlg-header-content",w4="e-dlg-header",Q0="e-footer-content",G0="e-dlg-modal",C4="e-icon-dlg-close",yl="e-dlg-target",ka="e-scroll-disabled",E4="e-device",X0="e-dlg-fullscreen",D4="e-dlg-closeicon-btn",x4="e-popup-open",T4="Information",A4="e-scroll-disabled",L4="e-alert-dialog",N4="e-confirm-dialog",RE="e-dlg-resizable",cp="e-restrict-left",O4="e-resize-viewport",HE="user action",QJ=function(n){function t(e,i){var r=n.call(this,e,i)||this;return r.needsID=!0,r}return kE(t,n),t.prototype.render=function(){this.initialize(),this.initRender(),this.wireEvents(),"100%"===this.width&&(this.element.style.width=""),""!==this.minHeight&&(this.element.style.minHeight=Re(this.minHeight)),this.enableResize&&(this.setResize(),this.isModal&&(this.isModelResize=!0),"None"===this.animationSettings.effect&&this.getMinHeight()),this.renderComplete()},t.prototype.initializeValue=function(){this.dlgClosedBy=HE},t.prototype.preRender=function(){var e=this;if(this.initializeValue(),this.headerContent=null,this.allowMaxHeight=!0,this.preventVisibility=!0,this.clonedEle=this.element.cloneNode(!0),this.closeIconClickEventHandler=function(s){e.dlgClosedBy="close icon",e.hide(s)},this.dlgOverlayClickEventHandler=function(s){e.dlgClosedBy="overlayClick",s.preventFocus=!1,e.trigger("overlayClick",s,function(o){o.preventFocus||e.focusContent(),e.dlgClosedBy=HE})},this.l10n=new ho("dialog",{close:"Close"},this.locale),this.checkPositionData(),m(this.target)){var r=this.isProtectedOnChange;this.isProtectedOnChange=!0,this.target=document.body,this.isProtectedOnChange=r}},t.prototype.updatePersistData=function(){this.enablePersistence&&this.setProperties({width:parseFloat(this.element.style.width),height:parseFloat(this.element.style.height),position:{X:parseFloat(this.dragObj.element.style.left),Y:parseFloat(this.dragObj.element.style.top)}},!0)},t.prototype.isNumberValue=function(e){return/^[-+]?\d*\.?\d+$/.test(e)},t.prototype.checkPositionData=function(){if(!m(this.position)){if(!m(this.position.X)&&"number"!=typeof this.position.X&&this.isNumberValue(this.position.X)){var i=this.isProtectedOnChange;this.isProtectedOnChange=!0,this.position.X=parseFloat(this.position.X),this.isProtectedOnChange=i}m(this.position.Y)||"number"==typeof this.position.Y||this.isNumberValue(this.position.Y)&&(i=this.isProtectedOnChange,this.isProtectedOnChange=!0,this.position.Y=parseFloat(this.position.Y),this.isProtectedOnChange=i)}},t.prototype.getEle=function(e,i){for(var r=void 0,s=0;s=0&&t[e])xJ(t[e]);else if(""!==t[e].trim()){var i=mi("div",{className:"e-icons "+Vg+" e-"+t[e]});_i.appendChild(i)}hp=n.minHeight,CE=n.minWidth,mh=n.maxWidth,vh=n.maxHeight,n.proxy&&n.proxy.element&&n.proxy.element.classList.contains("e-dialog")?y4(n.proxy):y4()}({element:this.element,direction:r,minHeight:parseInt(e.slice(0,i.indexOf("p")),10),maxHeight:this.targetEle.clientHeight,minWidth:parseInt(i.slice(0,i.indexOf("p")),10),maxWidth:this.targetEle.clientWidth,boundary:this.target===document.body?null:this.targetEle,resizeBegin:this.onResizeStart.bind(this),resizeComplete:this.onResizeComplete.bind(this),resizing:this.onResizing.bind(this),proxy:this}),this.wireWindowResizeEvent()}else M4(),this.unWireWindowResizeEvent(),this.element.classList.remove(this.isModal?cp:O4),this.element.classList.remove(RE)},t.prototype.getFocusElement=function(e){var r=e.querySelectorAll('input,select,textarea,button:enabled,a,[contenteditable="true"],[tabindex]');return{element:r[r.length-1]}},t.prototype.keyDown=function(e){var i=this;if(9===e.keyCode&&this.isModal){var r=void 0;m(this.btnObj)||(r=this.btnObj[this.btnObj.length-1]),m(this.btnObj)&&!m(this.ftrTemplateContent)&&(r=this.getFocusElement(this.ftrTemplateContent)),m(this.btnObj)&&m(this.ftrTemplateContent)&&!m(this.contentEle)&&(r=this.getFocusElement(this.contentEle)),!m(r)&&document.activeElement===r.element&&!e.shiftKey&&(e.preventDefault(),this.focusableElements(this.element).focus()),document.activeElement===this.focusableElements(this.element)&&e.shiftKey&&(e.preventDefault(),m(r)||r.element.focus())}var h,s=document.activeElement,o=["input","textarea"].indexOf(s.tagName.toLowerCase())>-1,a=!1;if(o||(a=s.hasAttribute("contenteditable")&&"true"===s.getAttribute("contenteditable")),27===e.keyCode&&this.closeOnEscape){this.dlgClosedBy="escape";var l=document.querySelector(".e-popup-open:not(.e-dialog)");!m(l)&&!l.classList.contains("e-toolbar-pop")||this.hide(e)}(13===e.keyCode&&!e.ctrlKey&&"textarea"!==s.tagName.toLowerCase()&&o&&!m(this.primaryButtonEle)||13===e.keyCode&&e.ctrlKey&&("textarea"===s.tagName.toLowerCase()||a)&&!m(this.primaryButtonEle))&&this.buttons.some(function(d,u){h=u;var p=d.buttonModel;return!m(p)&&!0===p.isPrimary})&&"function"==typeof this.buttons[h].click&&setTimeout(function(){i.buttons[h].click.call(i,e)})},t.prototype.initialize=function(){m(this.target)||(this.targetEle="string"==typeof this.target?document.querySelector(this.target):this.target),this.isBlazorServerRender()||V([this.element],Y0),X.isDevice&&V([this.element],E4),this.isBlazorServerRender()||this.setCSSClass(),this.setMaxHeight()},t.prototype.initRender=function(){var e=this;if(this.initialRender=!0,this.isBlazorServerRender()||Fe(this.element,{role:"dialog"}),1e3===this.zIndex?(this.setzIndex(this.element,!1),this.calculatezIndex=!0):this.calculatezIndex=!1,this.setTargetContent(),""!==this.header&&!m(this.header)&&this.setHeader(),this.renderCloseIcon(),this.setContent(),""===this.footerTemplate||m(this.footerTemplate)?!m(this.buttons[0])&&!m(this.buttons[0].buttonModel)&&this.setButton():this.setFooterTemplate(),this.allowDragging&&!m(this.headerContent)&&this.setAllowDragging(),Fe(this.element,{"aria-modal":this.isModal?"true":"false"}),this.isModal&&this.setIsModal(),!0!==this.element.classList.contains(L4)&&!0!==this.element.classList.contains(N4)&&!m(this.element.parentElement)){var i=this.isModal?this.dlgContainer.parentElement:this.element.parentElement;this.refElement=this.createElement("div",{className:"e-dlg-ref-element"}),i.insertBefore(this.refElement,this.isModal?this.dlgContainer:this.element)}if(m(this.targetEle)||this.targetEle.appendChild(this.isModal?this.dlgContainer:this.element),this.popupObj=new ac(this.element,{height:this.height,width:this.width,zIndex:this.zIndex,relateTo:this.target,actionOnScroll:"none",enableRtl:this.enableRtl,open:function(o){var a={container:e.isModal?e.dlgContainer:e.element,element:e.element,target:e.target,preventFocus:!1};e.enableResize&&e.resetResizeIcon(),e.trigger("open",a,function(l){l.preventFocus||e.focusContent()})},close:function(o){e.isModal&&V([e.dlgOverlay],"e-fade"),e.unBindEvent(e.element),e.isModal&&(e.dlgContainer.style.display="none"),e.trigger("close",e.closeArgs);var a=document.activeElement;!m(a)&&!m(a.blur)&&a.blur(),!m(e.storeActiveElement)&&!m(e.storeActiveElement.focus)&&e.storeActiveElement.focus()}}),this.positionChange(),this.setEnableRTL(),this.isBlazorServerRender()||(V([this.element],"e-popup-close"),this.isModal&&this.setOverlayZindex()),this.visible){if(this.show(),this.isModal){var r=this.getTargetContainer(this.target);r instanceof Element&&"rtl"===window.getComputedStyle(r).getPropertyValue("direction")&&this.setPopupPosition()}}else this.isModal&&(this.dlgOverlay.style.display="none");this.initialRender=!1},t.prototype.getTargetContainer=function(e){var i=null;if("string"==typeof e)if(e.startsWith("#"))i=document.getElementById(e.substring(1));else if(e.startsWith(".")){var r=document.getElementsByClassName(e.substring(1));i=r.length>0?r[0]:null}else!(e instanceof HTMLElement)&&e!==document.body&&(i=document.querySelector(e));else e instanceof HTMLElement&&(i=e);return i},t.prototype.resetResizeIcon=function(){var e=this.getMinHeight();if(this.targetEle.offsetHeight0&&("function"==typeof this.buttons[e].click&&E.add(s[e],"click",this.buttons[e].click,this),"object"==typeof this.buttons[e].click&&E.add(s[e],"click",this.buttonClickHandler.bind(this,e),this)),!this.isBlazorServerRender()&&!m(this.ftrTemplateContent)&&(this.btnObj[e].appendTo(this.ftrTemplateContent.children[e]),this.buttons[e].isFlat&&this.btnObj[e].element.classList.add("e-flat"),this.primaryButtonEle=this.element.getElementsByClassName("e-primary")[0]))},t.prototype.buttonClickHandler=function(e){this.trigger("buttons["+e+"].click",{})},t.prototype.setContent=function(){this.contentEle=this.createElement("div",{className:"e-dlg-content",id:this.element.id+"_dialog-content"}),Fe(this.element,this.headerEle?{"aria-describedby":this.element.id+"_title "+this.element.id+"_dialog-content"}:{"aria-describedby":this.element.id+"_dialog-content"}),this.innerContentElement?this.contentEle.appendChild(this.innerContentElement):(!m(this.content)&&""!==this.content||!this.initialRender)&&(("string"!=typeof this.content||ce())&&this.content instanceof HTMLElement?this.contentEle.appendChild(this.content):this.setTemplate(this.content,this.contentEle,"content")),m(this.headerContent)?this.element.insertBefore(this.contentEle,this.element.children[0]):this.element.insertBefore(this.contentEle,this.element.children[1]),"auto"===this.height&&(!this.isBlazorServerRender()&&X.isIE&&""===this.element.style.width&&!m(this.width)&&(this.element.style.width=Re(this.width)),this.setMaxHeight())},t.prototype.setTemplate=function(e,i,r){var s,o,a;o=i.classList.contains(w4)?this.element.id+"header":i.classList.contains(Q0)?this.element.id+"footerTemplate":this.element.id+"content",m(e.outerHTML)?("string"==typeof e||"string"!=typeof e||ce()&&!this.isStringTemplate)&&("string"==typeof e&&(e=this.sanitizeHelper(e)),this.isVue||"string"!=typeof e?(s=ii(e),a=e):i.innerHTML=e):i.appendChild(e);var l=[];if(!m(s)){for(var c=0,d=s({},this,r,o,!(ce()&&!this.isStringTemplate&&0===a.indexOf("
Blazor"))||this.isStringTemplate);c/g,"");(this.element.children.length>0||i)&&(this.innerContentElement=document.createDocumentFragment(),[].slice.call(this.element.childNodes).forEach(function(r){8!==r.nodeType&&e.innerContentElement.appendChild(r)}))}},t.prototype.setHeader=function(){this.headerEle?this.headerEle.innerHTML="":this.headerEle=this.createElement("div",{id:this.element.id+"_title",className:w4}),this.createHeaderContent(),this.headerContent.appendChild(this.headerEle),this.setTemplate(this.header,this.headerEle,"header"),Fe(this.element,{"aria-describedby":this.element.id+"_title"}),Fe(this.element,{"aria-labelledby":this.element.id+"_dialog-header"}),this.element.insertBefore(this.headerContent,this.element.children[0]),this.allowDragging&&!m(this.headerContent)&&this.setAllowDragging()},t.prototype.setFooterTemplate=function(){this.ftrTemplateContent?this.ftrTemplateContent.innerHTML="":this.ftrTemplateContent=this.createElement("div",{className:Q0}),""===this.footerTemplate||m(this.footerTemplate)?this.ftrTemplateContent.innerHTML=this.buttonContent.join(""):this.setTemplate(this.footerTemplate,this.ftrTemplateContent,"footerTemplate"),this.element.appendChild(this.ftrTemplateContent)},t.prototype.createHeaderContent=function(){m(this.headerContent)&&(this.headerContent=this.createElement("div",{id:this.element.id+"_dialog-header",className:zE}))},t.prototype.renderCloseIcon=function(){this.showCloseIcon&&(this.closeIcon=this.createElement("button",{className:D4,attrs:{type:"button"}}),this.closeIconBtnObj=new ys({cssClass:"e-flat",iconCss:C4+" e-icons"}),this.closeIconTitle(),m(this.headerContent)?(this.createHeaderContent(),pl([this.closeIcon],this.headerContent),this.element.insertBefore(this.headerContent,this.element.children[0])):pl([this.closeIcon],this.headerContent),this.closeIconBtnObj.appendTo(this.closeIcon))},t.prototype.closeIconTitle=function(){this.l10n.setLocale(this.locale);var e=this.l10n.getConstant("close");this.closeIcon.setAttribute("title",e),this.closeIcon.setAttribute("aria-label",e)},t.prototype.setCSSClass=function(e){e&&(K([this.element],e.split(" ")),this.isModal&&!m(this.dlgContainer)&&K([this.dlgContainer],e.split(" "))),this.cssClass&&(V([this.element],this.cssClass.split(" ")),this.isModal&&!m(this.dlgContainer)&&V([this.dlgContainer],this.cssClass.split(" ")))},t.prototype.setIsModal=function(){this.dlgContainer=this.createElement("div",{className:"e-dlg-container"}),this.setCSSClass(),this.element.classList.remove(x4),this.element.parentNode.insertBefore(this.dlgContainer,this.element),this.dlgContainer.appendChild(this.element),V([this.element],G0),this.dlgOverlay=this.createElement("div",{className:"e-dlg-overlay"}),this.dlgOverlay.style.zIndex=(this.zIndex-1).toString(),this.dlgContainer.appendChild(this.dlgOverlay)},t.prototype.getValidFocusNode=function(e){for(var i,r=0;r0||"a"===i.tagName.toLowerCase()&&i.hasAttribute("href"))&&i.tabIndex>-1&&!i.disabled&&!this.disableElement(i,'[disabled],[aria-disabled="true"],[type="hidden"]'))return i;i=null}return i},t.prototype.focusableElements=function(e){if(!m(e)){var r=e.querySelectorAll('input,select,textarea,button,a,[contenteditable="true"],[tabindex]');return this.getValidFocusNode(r)}return null},t.prototype.getAutoFocusNode=function(e){var i=e.querySelector("."+D4),s=e.querySelectorAll("[autofocus]"),o=this.getValidFocusNode(s);if(ce()&&(this.primaryButtonEle=this.element.getElementsByClassName("e-primary")[0]),m(o)){if(!m(o=this.focusableElements(this.contentEle)))return o;if(!m(this.primaryButtonEle))return this.element.querySelector(".e-primary")}else i=o;return i},t.prototype.disableElement=function(e,i){var r=e?e.matches||e.webkitMatchesSelector||e.msGetRegionContent:null;if(r)for(;e;e=e.parentNode)if(e instanceof Element&&r.call(e,i))return e;return null},t.prototype.focusContent=function(){var e=this.getAutoFocusNode(this.element),i=m(e)?this.element:e,r=X.userAgent;(r.indexOf("MSIE ")>0||r.indexOf("Trident/")>0)&&this.element.focus(),i.focus(),this.unBindEvent(this.element),this.bindEvent(this.element)},t.prototype.bindEvent=function(e){E.add(e,"keydown",this.keyDown,this)},t.prototype.unBindEvent=function(e){E.remove(e,"keydown",this.keyDown)},t.prototype.updateSanitizeContent=function(){this.isBlazorServerRender()||(this.contentEle.innerHTML=this.sanitizeHelper(this.content))},t.prototype.isBlazorServerRender=function(){return ce()&&this.isServerRendered},t.prototype.getModuleName=function(){return"dialog"},t.prototype.onPropertyChanged=function(e,i){if(this.element.classList.contains(Y0))for(var r=0,s=Object.keys(e);r0?this.showCloseIcon||""!==this.header&&!m(this.header)?this.showCloseIcon||he(this.closeIcon):(he(this.headerContent),this.headerContent=null):(this.renderCloseIcon(),this.wireEvents());break;case"locale":this.showCloseIcon&&this.closeIconTitle();break;case"visible":this.visible?this.show():this.hide();break;case"isModal":this.updateIsModal();break;case"height":je(this.element,{height:Re(e.height)}),this.updatePersistData();break;case"width":je(this.element,{width:Re(e.width)}),this.updatePersistData();break;case"zIndex":this.popupObj.zIndex=this.zIndex,this.isModal&&this.setOverlayZindex(this.zIndex),this.element.style.zIndex!==this.zIndex.toString()&&(this.calculatezIndex=!1);break;case"cssClass":this.setCSSClass(i.cssClass);break;case"buttons":this.unWireButtonEvents(),this.destroyButtons(),m(this.ftrTemplateContent)||(he(this.ftrTemplateContent),this.ftrTemplateContent=null),this.footerTemplate="",this.setButton();break;case"allowDragging":this.allowDragging&&!m(this.headerContent)?this.setAllowDragging():this.dragObj.destroy();break;case"target":this.setTarget(e.target);break;case"position":if(this.checkPositionData(),this.isModal){var a=this.position.X,l=this.position.Y;m(i.position)||(m(i.position.X)||(a=i.position.X),m(i.position.Y)||(l=i.position.Y)),this.dlgContainer.classList.contains("e-dlg-"+a+"-"+l)&&this.dlgContainer.classList.remove("e-dlg-"+a+"-"+l)}this.positionChange(),this.updatePersistData();break;case"enableRtl":this.setEnableRTL();break;case"enableResize":this.setResize();break;case"minHeight":""!==this.minHeight&&(this.element.style.minHeight=Re(this.minHeight))}},t.prototype.setTarget=function(e){this.popupObj.relateTo=e,this.target=e,this.targetEle="string"==typeof this.target?document.querySelector(this.target):this.target,this.dragObj&&(this.dragObj.dragArea=this.targetEle),this.setMaxHeight(),this.isModal&&this.updateIsModal(),this.enableResize&&this.setResize()},t.prototype.updateIsModal=function(){if(this.element.setAttribute("aria-modal",this.isModal?"true":"false"),this.isModal)m(this.dlgOverlay)&&(this.setIsModal(),this.element.style.top="0px",this.element.style.left="0px",m(this.targetEle)||this.targetEle.appendChild(this.dlgContainer));else{for(K([this.element],G0),K([document.body],[yl,ka]),he(this.dlgOverlay);this.dlgContainer.firstChild;)this.dlgContainer.parentElement.insertBefore(this.dlgContainer.firstChild,this.dlgContainer);this.dlgContainer.parentElement.removeChild(this.dlgContainer)}this.visible&&this.show(),this.positionChange(),this.isModal&&this.dlgOverlay&&E.add(this.dlgOverlay,"click",this.dlgOverlayClickEventHandler,this)},t.prototype.setzIndex=function(e,i){var r=this.isProtectedOnChange;this.isProtectedOnChange=!0;var s=lc(e);this.zIndex=s>this.zIndex?s:this.zIndex,this.isProtectedOnChange=r,i&&(this.popupObj.zIndex=this.zIndex)},t.prototype.windowResizeHandler=function(){(function AJ(n){mh=n})(this.targetEle.clientWidth),function LJ(n){vh=n}(this.targetEle.clientHeight),this.setMaxHeight()},t.prototype.getPersistData=function(){return this.addOnPersist(["width","height","position"])},t.prototype.removeAllChildren=function(e){for(;e.children[0];)this.removeAllChildren(e.children[0]),e.removeChild(e.children[0])},t.prototype.destroy=function(){if(!this.isDestroyed){var e=[PE,G0,RE,cp,X0,E4],i=["role","aria-modal","aria-labelledby","aria-describedby","aria-grabbed","tabindex","style"];K([this.targetEle],[yl,ka]),!m(this.element)&&this.element.classList.contains(X0)&&K([document.body],[yl,ka]),this.isModal&&K([m(this.targetEle)?document.body:this.targetEle],ka),this.unWireEvents(),this.unWireButtonEvents(),this.destroyButtons(),m(this.closeIconBtnObj)||this.closeIconBtnObj.destroy(),m(this.dragObj)||this.dragObj.destroy(),!m(this.popupObj.element)&&this.popupObj.element.classList.contains("e-popup")&&this.popupObj.destroy(),K([this.element],e),!m(this.cssClass)&&""!==this.cssClass&&K([this.element],this.cssClass.split(" ")),!m(this.refElement)&&!m(this.refElement.parentElement)&&(this.refElement.parentElement.insertBefore(this.isModal?this.dlgContainer:this.element,this.refElement),he(this.refElement),this.refElement=void 0),this.isModal&&(he(this.dlgOverlay),this.dlgContainer.parentNode.insertBefore(this.element,this.dlgContainer),he(this.dlgContainer)),this.element.innerHTML=this.clonedEle.innerHTML;for(var r=0;r0&&""===this.footerTemplate&&this.ftrTemplateContent)for(var e=0;e=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},BE="e-tooltip",B4="e-icons",F4="e-tooltip-close",FE="e-tooltip-wrap",_4="e-tip-content",dp="e-arrow-tip",U4="e-arrow-tip-outer",q0="e-arrow-tip-inner",Xg="e-tip-bottom",_E="e-tip-top",j4="e-tip-left",UE="e-tip-right",jE="e-popup",qg="e-popup-open",VE="e-popup-close",$0="e-lib",V4="e-tooltip-popup-container",JJ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return P4(t,n),Gi([I({effect:"FadeIn",duration:150,delay:0})],t.prototype,"open",void 0),Gi([I({effect:"FadeOut",duration:150,delay:0})],t.prototype,"close",void 0),t}(Ee),Sh=function(n){function t(e,i){var r=n.call(this,e,i)||this;return r.mouseMoveEvent=null,r.mouseMoveTarget=null,r.containerElement=null,r.isBodyContainer=!0,r}return P4(t,n),t.prototype.initialize=function(){this.formatPosition(),V([this.element],BE)},t.prototype.formatPosition=function(){var e,i;this.position&&(0===this.position.indexOf("Top")||0===this.position.indexOf("Bottom")?(e=this.position.split(/(?=[A-Z])/),this.tooltipPositionY=e[0],this.tooltipPositionX=e[1]):(i=this.position.split(/(?=[A-Z])/),this.tooltipPositionX=i[0],this.tooltipPositionY=i[1]))},t.prototype.renderArrow=function(){this.setTipClass(this.position);var e=this.createElement("div",{className:dp+" "+this.tipClass});e.appendChild(this.createElement("div",{className:U4+" "+this.tipClass})),e.appendChild(this.createElement("div",{className:q0+" "+this.tipClass})),this.tooltipEle.appendChild(e)},t.prototype.setTipClass=function(e){this.tipClass=0===e.indexOf("Right")?j4:0===e.indexOf("Bottom")?_E:0===e.indexOf("Left")?UE:Xg},t.prototype.renderPopup=function(e){var i=this.mouseTrail?{top:0,left:0}:this.getTooltipPosition(e);this.tooltipEle.classList.remove($0),this.popupObj=new ac(this.tooltipEle,{height:this.height,width:this.width,position:{X:i.left,Y:i.top},enableRtl:this.enableRtl,open:this.openPopupHandler.bind(this),close:this.closePopupHandler.bind(this)})},t.prototype.getScalingFactor=function(e){if(!e)return{x:1,y:1};var i={x:1,y:1},r=e.closest('[style*="transform: scale"]');if(r&&r!==this.tooltipEle&&r.contains(this.tooltipEle)){var a=window.getComputedStyle(r).getPropertyValue("transform").match(/matrix\(([^)]+)\)/)[1].split(",").map(parseFloat);i.x=a[0],i.y=a[3]}return i},t.prototype.getTooltipPosition=function(e){this.tooltipEle.style.display="block";var i=this.element.closest('[style*="zoom"]');i&&(i.contains(this.tooltipEle)||(this.tooltipEle.style.zoom=getComputedStyle(i).zoom));var r=is(e,this.tooltipPositionX,this.tooltipPositionY,!this.isBodyContainer,this.isBodyContainer?null:this.containerElement.getBoundingClientRect()),s=this.getScalingFactor(e),o=this.calculateTooltipOffset(this.position,s.x,s.y),a=this.calculateElementPosition(r,o),c=this.collisionFlipFit(e,a[0],a[1]);return c.left=c.left/s.x,c.top=c.top/s.y,this.tooltipEle.style.display="",c},t.prototype.windowResize=function(){this.reposition(this.findTarget())},t.prototype.reposition=function(e){if(this.popupObj&&e){var i=this.getTooltipPosition(e);this.popupObj.position={X:i.left,Y:i.top},this.popupObj.dataBind()}},t.prototype.openPopupHandler=function(){!this.mouseTrail&&this.needTemplateReposition()&&this.reposition(this.findTarget()),this.trigger("afterOpen",this.tooltipEventArgs),this.tooltipEventArgs=null},t.prototype.closePopupHandler=function(){this.isReact&&!("Click"===this.opensOn||"function"==typeof this.content)&&this.clearTemplate(["content"]),this.clear();var e={type:this.tooltipEventArgs.event?this.tooltipEventArgs.event.type:null,cancel:!1,target:this.tooltipEventArgs.target,event:this.tooltipEventArgs.event?this.tooltipEventArgs.event:null,element:this.tooltipEle,isInteracted:!m(this.tooltipEventArgs.event)};this.trigger("afterClose",e),e=null},t.prototype.calculateTooltipOffset=function(e,i,r){void 0===i&&(i=1),void 0===r&&(r=1);var o,a,l,h,c,d,u,p,s={top:0,left:0};if(1!==i||1!==r){var f=this.tooltipEle.getBoundingClientRect(),g=void 0;l=Math.round(f.width),h=Math.round(f.height),(c=U("."+dp,this.tooltipEle))&&(g=c.getBoundingClientRect()),o=c?Math.round(g.width):0,a=c?Math.round(g.height):0,d=this.showTipPointer?0:8,u=a/2+2+(h-this.tooltipEle.clientHeight*r),p=o/2+2+(l-this.tooltipEle.clientWidth*i)}else l=this.tooltipEle.offsetWidth,h=this.tooltipEle.offsetHeight,c=U("."+dp,this.tooltipEle),d=this.showTipPointer?0:8,u=(a=c?c.offsetHeight:0)/2+2+(this.tooltipEle.offsetHeight-this.tooltipEle.clientHeight),p=(o=c?c.offsetWidth:0)/2+2+(this.tooltipEle.offsetWidth-this.tooltipEle.clientWidth);switch(this.mouseTrail&&(d+=2),e){case"RightTop":s.left+=o+d,s.top-=h-u;break;case"RightCenter":s.left+=o+d,s.top-=h/2;break;case"RightBottom":s.left+=o+d,s.top-=u;break;case"BottomRight":s.top+=a+d,s.left-=p;break;case"BottomCenter":s.top+=a+d,s.left-=l/2;break;case"BottomLeft":s.top+=a+d,s.left-=l-p;break;case"LeftBottom":s.left-=o+l+d,s.top-=u;break;case"LeftCenter":s.left-=o+l+d,s.top-=h/2;break;case"LeftTop":s.left-=o+l+d,s.top-=h-u;break;case"TopLeft":s.top-=h+a+d,s.left-=l-p;break;case"TopRight":s.top-=h+a+d,s.left-=p;break;default:s.top-=h+a+d,s.left-=l/2}return s.left+=this.offsetX,s.top+=this.offsetY,s},t.prototype.updateTipPosition=function(e){var i=we("."+dp+",."+U4+",."+q0,this.tooltipEle);K(i,[Xg,_E,j4,UE]),this.setTipClass(e),V(i,this.tipClass)},t.prototype.adjustArrow=function(e,i,r,s){var o=U("."+dp,this.tooltipEle);if(!1!==this.showTipPointer&&null!==o){var a,l;this.updateTipPosition(i),this.tooltipEle.style.display="block";var f,h=this.tooltipEle.clientWidth,c=this.tooltipEle.clientHeight,d=U("."+q0,this.tooltipEle),u=o.offsetWidth,p=o.offsetHeight;this.tooltipEle.style.display="",this.tipClass===Xg||this.tipClass===_E?(this.tipClass===Xg?(l="99.9%",d.style.top="-"+(p-2)+"px"):(l=-(p-1)+"px",d.style.top="-"+(p-6)+"px"),e&&(a=(f="Center"!==r||h>e.offsetWidth||this.mouseTrail)&&"Left"===r||!f&&"End"===this.tipPointerPosition?h-u-2+"px":f&&"Right"===r||!f&&"Start"===this.tipPointerPosition?"2px":!f||"End"!==this.tipPointerPosition&&"Start"!==this.tipPointerPosition?h/2-u/2+"px":"End"===this.tipPointerPosition?e.offsetWidth+(this.tooltipEle.offsetWidth-e.offsetWidth)/2-u/2-2+"px":(this.tooltipEle.offsetWidth-e.offsetWidth)/2-u/2+2+"px")):(this.tipClass===UE?(a="99.9%",d.style.left="-"+(u-2)+"px"):(a=-(u-1)+"px",d.style.left=u-2-u+"px"),l=(f="Center"!==s||c>e.offsetHeight||this.mouseTrail)&&"Top"===s||!f&&"End"===this.tipPointerPosition?c-p-2+"px":f&&"Bottom"===s||!f&&"Start"===this.tipPointerPosition?"2px":c/2-p/2+"px"),o.style.top=l,o.style.left=a}},t.prototype.renderContent=function(e){var i=this,r=U("."+_4,this.tooltipEle);if(this.cssClass&&V([this.tooltipEle],this.cssClass.split(" ")),e&&!m(e.getAttribute("title"))&&(e.setAttribute("data-content",e.getAttribute("title")),e.removeAttribute("title")),m(this.content))e&&!m(e.getAttribute("data-content"))&&(r.innerHTML=e.getAttribute("data-content"));else if(r.innerHTML="",this.content instanceof HTMLElement)r.appendChild(this.content);else if("string"==typeof this.content)this.isAngular?this.setProperties({content:Ti.sanitize(this.content)},!0):this.content=this.enableHtmlSanitizer?Ti.sanitize(this.content):this.content,this.enableHtmlParse?(o=ii(this.content)({},this,"content",this.element.id+"content",void 0,void 0,r,this.root))&&Dt(o,r):r.textContent=this.content;else{var o;(o=ii(this.content)({},this,"content",this.element.id+"content",void 0,void 0,r))&&(this.isAngular&&setTimeout(function(){i.reposition(e)},1),Dt(o,r)),this.renderReactTemplates()}},t.prototype.renderCloseIcon=function(){if(this.isSticky){var i=this.createElement("div",{className:B4+" "+F4});this.tooltipEle.appendChild(i),E.add(i,X.touchStartEvent,this.onStickyClose,this)}else{var e=this.tooltipEle.querySelector("."+B4+"."+F4);e&>(e)}},t.prototype.addDescribedBy=function(e,i){var r=(e.getAttribute("aria-describedby")||"").split(/\s+/);r.indexOf(i)<0&&r.push(i),Fe(e,{"aria-describedby":r.join(" ").trim(),"data-tooltip-id":i})},t.prototype.removeDescribedBy=function(e){var i=e.getAttribute("data-tooltip-id"),r=(e.getAttribute("aria-describedby")||"").split(/\s+/),s=r.indexOf(i);-1!==s&&r.splice(s,1),e.removeAttribute("data-tooltip-id");var o=r.join(" ").trim();o?e.setAttribute("aria-describedby",o):e.removeAttribute("aria-describedby")},t.prototype.tapHoldHandler=function(e){clearTimeout(this.autoCloseTimer),this.targetHover(e.originalEvent)},t.prototype.touchEndHandler=function(){var e=this;this.isSticky||(this.autoCloseTimer=setTimeout(function(){e.close()},1500))},t.prototype.targetClick=function(e){var i;!m(i=this.target?J(e.target,this.target):this.element)&&(null===i.getAttribute("data-tooltip-id")?this.targetHover(e):this.isSticky||this.hideTooltip(this.animation.close,e,i))},t.prototype.targetHover=function(e){var i;if(!(m(i=this.target?J(e.target,this.target):this.element)||null!==i.getAttribute("data-tooltip-id")&&0===this.closeDelay)){for(var s=0,o=[].slice.call(we('[data-tooltip-id= "'+this.ctrlId+'_content"]',document));s0?this.showTimer=setTimeout(function(){o.mouseTrail&&E.add(i,"mousemove touchstart mouseenter",o.onMouseMove,o),o.popupObj&&(o.popupObj.show(a,i),o.mouseMoveEvent&&o.mouseTrail&&o.onMouseMove(o.mouseMoveEvent))},this.openDelay):this.popupObj&&this.popupObj.show(a,i)}s&&this.wireMouseEvents(s,i)},t.prototype.needTemplateReposition=function(){return!m(this.viewContainerRef)&&"string"!=typeof this.viewContainerRef||this.isReact},t.prototype.checkCollision=function(e,i,r){var s={left:i,top:r,position:this.position,horizontal:this.tooltipPositionX,vertical:this.tooltipPositionY},o=oc(this.tooltipEle,this.checkCollideTarget(),i,r);return o.length>0&&(s.horizontal=o.indexOf("left")>=0?"Right":o.indexOf("right")>=0?"Left":this.tooltipPositionX,s.vertical=o.indexOf("top")>=0?"Bottom":o.indexOf("bottom")>=0?"Top":this.tooltipPositionY),s},t.prototype.calculateElementPosition=function(e,i){return[this.isBodyContainer?e.left+i.left:e.left-this.containerElement.getBoundingClientRect().left+i.left+window.pageXOffset+this.containerElement.scrollLeft,this.isBodyContainer?e.top+i.top:e.top-this.containerElement.getBoundingClientRect().top+i.top+window.pageYOffset+this.containerElement.scrollTop]},t.prototype.collisionFlipFit=function(e,i,r){var s=this.checkCollision(e,i,r),o=s.position;if(this.tooltipPositionY!==s.vertical&&(o=0===this.position.indexOf("Bottom")||0===this.position.indexOf("Top")?s.vertical+this.tooltipPositionX:this.tooltipPositionX+s.vertical),this.tooltipPositionX!==s.horizontal&&(0===o.indexOf("Left")&&(s.vertical="LeftTop"===o||"LeftCenter"===o?"Top":"Bottom",o=s.vertical+"Left"),0===o.indexOf("Right")&&(s.vertical="RightTop"===o||"RightCenter"===o?"Top":"Bottom",o=s.vertical+"Right"),s.horizontal=this.tooltipPositionX),this.tooltipEventArgs={type:null,cancel:!1,target:e,event:null,element:this.tooltipEle,collidedPosition:o},this.trigger("beforeCollision",this.tooltipEventArgs),this.tooltipEventArgs.cancel)o=this.position;else{var a=s.vertical,l=s.horizontal;if(s.position!==o){var h=is(e,l,a,!this.isBodyContainer,this.isBodyContainer?null:this.containerElement.getBoundingClientRect());this.adjustArrow(e,o,l,a);var c=this.getScalingFactor(e),d=this.calculateTooltipOffset(o,c.x,c.y);d.top-=this.getOffSetPosition("TopBottom",o,this.offsetY),d.left-=this.getOffSetPosition("RightLeft",o,this.offsetX),s.position=o;var u=this.calculateElementPosition(h,d);s.left=u[0],s.top=u[1]}else this.adjustArrow(e,o,l,a)}var p={left:s.left,top:s.top},f=this.isBodyContainer?uE(this.tooltipEle,this.checkCollideTarget(),{X:!0,Y:this.windowCollision},p):p;this.tooltipEle.style.display="block";var g=U("."+dp,this.tooltipEle);if(this.showTipPointer&&null!=g&&(0===o.indexOf("Bottom")||0===o.indexOf("Top"))){var v=parseInt(g.style.left,10)-(f.left-s.left);v<0?v=0:v+g.offsetWidth>this.tooltipEle.clientWidth&&(v=this.tooltipEle.clientWidth-g.offsetWidth),g.style.left=v.toString()+"px"}return this.tooltipEle.style.display="",p.left=f.left,p.top=f.top,p},t.prototype.getOffSetPosition=function(e,i,r){return-1!==e.indexOf(this.position.split(/(?=[A-Z])/)[0])&&-1!==e.indexOf(i.split(/(?=[A-Z])/)[0])?2*r:0},t.prototype.checkCollideTarget=function(){return!this.windowCollision&&this.target?this.element:null},t.prototype.hideTooltip=function(e,i,r){var s=this;this.closeDelay>0?(clearTimeout(this.hideTimer),clearTimeout(this.showTimer),this.hideTimer=setTimeout(function(){s.closeDelay&&s.tooltipEle&&s.isTooltipOpen||s.tooltipHide(e,i,r)},this.closeDelay)):this.tooltipHide(e,i,r)},t.prototype.tooltipHide=function(e,i,r){var o,s=this;o=i?this.target?r||i.target:this.element:U('[data-tooltip-id= "'+this.ctrlId+'_content"]',document),this.tooltipEventArgs={type:i?i.type:null,cancel:!1,target:o,event:i||null,element:this.tooltipEle,isInteracted:!m(i)},this.trigger("beforeClose",this.tooltipEventArgs,function(a){a.cancel?s.isHidden=!1:(s.mouseMoveBeforeRemove(),s.popupHide(e,o,i))})},t.prototype.popupHide=function(e,i,r){i&&r&&this.restoreElement(i),this.isHidden=!0;var s={name:this.animation.close.effect,duration:e.duration,delay:e.delay,timingFunction:"easeIn"};"None"===e.effect&&(s=void 0),this.popupObj&&this.popupObj.hide(s)},t.prototype.restoreElement=function(e){this.unwireMouseEvents(e),m(e.getAttribute("data-content"))||(e.setAttribute("title",e.getAttribute("data-content")),e.removeAttribute("data-content")),this.removeDescribedBy(e)},t.prototype.clear=function(){var e=this.findTarget();e&&this.restoreElement(e),this.tooltipEle&&(K([this.tooltipEle],VE),V([this.tooltipEle],qg)),this.isHidden&&(this.popupObj&&this.popupObj.destroy(),this.tooltipEle&>(this.tooltipEle),this.tooltipEle=null,this.popupObj=null)},t.prototype.tooltipHover=function(){this.tooltipEle&&(this.isTooltipOpen=!0)},t.prototype.tooltipMouseOut=function(e){this.isTooltipOpen=!1,this.hideTooltip(this.animation.close,e,this.findTarget())},t.prototype.onMouseOut=function(e){var i=e.relatedTarget;if(i&&!this.mouseTrail){var r=J(i,"."+FE+"."+$0+"."+jE);r?E.add(r,"mouseleave",this.tooltipElementMouseOut,this):(this.hideTooltip(this.animation.close,e,this.findTarget()),0===this.closeDelay&&("None"===this.animation.close.effect||this.isReact&&"string"!=typeof this.content)&&this.clear())}else this.hideTooltip(this.animation.close,e,this.findTarget()),this.clear();this.popupObj&&!this.popupObj.element.classList.contains(qg)&&this.clear()},t.prototype.tooltipElementMouseOut=function(e){this.hideTooltip(this.animation.close,e,this.findTarget()),E.remove(this.element,"mouseleave",this.tooltipElementMouseOut),this.clear()},t.prototype.onStickyClose=function(){this.close()},t.prototype.onMouseMove=function(e){var i=0,r=0;e.type.indexOf("touch")>-1?(e.preventDefault(),i=e.touches[0].pageX,r=e.touches[0].pageY):(i=e.pageX,r=e.pageY),Hs.stop(this.tooltipEle),K([this.tooltipEle],VE),V([this.tooltipEle],qg),this.adjustArrow(e.target,this.position,this.tooltipPositionX,this.tooltipPositionY);var s=this.getScalingFactor(e.target),o=this.calculateTooltipOffset(this.position,s.x,s.y),h=this.checkCollision(e.target,i+o.left+this.offsetX,r+o.top+this.offsetY);if(this.tooltipPositionX!==h.horizontal||this.tooltipPositionY!==h.vertical){var c=0===this.position.indexOf("Bottom")||0===this.position.indexOf("Top")?h.vertical+h.horizontal:h.horizontal+h.vertical;h.position=c,this.adjustArrow(e.target,h.position,h.horizontal,h.vertical);var d=this.calculateTooltipOffset(h.position,s.x,s.y);h.left=i+d.left-this.offsetX,h.top=r+d.top-this.offsetY}this.tooltipEle.style.left=h.left+"px",this.tooltipEle.style.top=h.top+"px"},t.prototype.keyDown=function(e){this.tooltipEle&&27===e.keyCode&&this.close()},t.prototype.touchEnd=function(e){this.tooltipEle&&null===J(e.target,"."+BE)&&!this.isSticky&&this.close()},t.prototype.scrollHandler=function(e){this.tooltipEle&&!this.isSticky&&!J(e.target,"."+FE+"."+$0+"."+jE)&&!this.isSticky&&this.close()},t.prototype.render=function(){this.initialize(),this.wireEvents(this.opensOn),this.renderComplete()},t.prototype.preRender=function(){this.tipClass=Xg,this.tooltipPositionX="Center",this.tooltipPositionY="Top",this.isHidden=!0},t.prototype.wireEvents=function(e){for(var r=0,s=this.getTriggerList(e);r0)for(var i=0,r=e;i0)for(var i=0,r=e;i0&&this.condition&&-1!==this.condition.indexOf("not")&&(e[s].condition=e[s].condition?e[s].condition+"not":"not"),i=e[s].validate(t),r){if(!i)return!1}else if(i)return!0;return r},n.prototype.toJson=function(){var t,e;if(this.isComplex){t=[],e=this.predicates;for(var i=0;ie.length-3?(e=e.substring(0,e.length-1),n.endsWith(n.toLowerCase(t),n.toLowerCase(e))):(e.lastIndexOf("%")!==e.indexOf("%")&&e.lastIndexOf("%")>e.indexOf("%")+1&&(e=e.substring(e.indexOf("%")+1,e.lastIndexOf("%"))),-1!==t.indexOf(e)))},n.fnSort=function(t){return"ascending"===(t=t?n.toLowerCase(t):"ascending")?this.fnAscending:this.fnDescending},n.fnAscending=function(t,e){return m(t)&&m(e)||null==e?-1:"string"==typeof t?t.localeCompare(e):null==t?1:t-e},n.fnDescending=function(t,e){return m(t)&&m(e)?-1:null==e?1:"string"==typeof t?-1*t.localeCompare(e):null==t?-1:e-t},n.extractFields=function(t,e){for(var i={},r=0;r0||e.length>0;)o=t.length>0&&e.length>0?r?r(this.getVal(t,0,i),this.getVal(e,0,i),t[0],e[0])<=0?t:e:t[0][i]0?t:e,s.push(o.shift());return s},n.getVal=function(t,e,i){return i?this.getObject(i,t[e]):t[e]},n.toLowerCase=function(t){return t?"string"==typeof t?t.toLowerCase():t.toString():0===t||!1===t?t.toString():""},n.callAdaptorFunction=function(t,e,i,r){if(e in t){var s=t[e](i,r);m(s)||(i=s)}return i},n.getAddParams=function(t,e,i){var r={};return n.callAdaptorFunction(t,"addParams",{dm:e,query:i,params:i?i.params:[],reqParams:r}),r},n.isPlainObject=function(t){return!!t&&t.constructor===Object},n.isCors=function(){var t=null;try{t=new window.XMLHttpRequest}catch{}return!!t&&"withCredentials"in t},n.getGuid=function(t){var i;return(t||"")+"00000000-0000-4000-0000-000000000000".replace(/0/g,function(r,s){if("crypto"in window&&"getRandomValues"in crypto){var o=new Uint8Array(1);window.crypto.getRandomValues(o),i=o[0]%16|0}else i=16*Math.random()|0;return"0123456789abcdef"[19===s?3&i|8:i]})},n.isNull=function(t){return null==t},n.getItemFromComparer=function(t,e,i){var r,s,o,a=0,l="string"==typeof n.getVal(t,0,e);if(t.length)for(;m(r)&&a0&&(r=s,o=t[a]));return o},n.distinct=function(t,e,i){i=!m(i)&&i;var s,r=[],o={};return t.forEach(function(a,l){(s="object"==typeof t[l]?n.getVal(t,l,e):t[l])in o||(r.push(i?t[l]:s),o[s]=1)}),r},n.processData=function(t,e){var i=this.prepareQuery(t),r=new nt(e);t.requiresCounts&&i.requiresCount();var s=r.executeLocal(i),o={result:t.requiresCounts?s.result:s,count:s.count,aggregates:JSON.stringify(s.aggregates)};return t.requiresCounts?o:s},n.prepareQuery=function(t){var e=this,i=new jt;return t.select&&i.select(t.select),t.where&&n.parse.parseJson(t.where).filter(function(o){if(m(o.condition))i.where(o.field,o.operator,o.value,o.ignoreCase,o.ignoreAccent);else{var a=[];o.field?a.push(new Ss(o.field,o.operator,o.value,o.ignoreCase,o.ignoreAccent)):a=a.concat(e.getPredicate(o.predicates)),"or"===o.condition?i.where(Ss.or(a)):"and"===o.condition&&i.where(Ss.and(a))}}),t.search&&n.parse.parseJson(t.search).filter(function(o){return i.search(o.key,o.fields,o.operator,o.ignoreCase,o.ignoreAccent)}),t.aggregates&&t.aggregates.filter(function(o){return i.aggregate(o.type,o.field)}),t.sorted&&t.sorted.filter(function(o){return i.sortBy(o.name,o.direction)}),t.skip&&i.skip(t.skip),t.take&&i.take(t.take),t.group&&t.group.filter(function(o){return i.group(o)}),i},n.getPredicate=function(t){for(var e=[],i=0;i":"greaterthan","<=":"lessthanorequal",">=":"greaterthanorequal","==":"equal","!=":"notequal","*=":"contains","$=":"endswith","^=":"startswith"},n.odBiOperator={"<":" lt ",">":" gt ","<=":" le ",">=":" ge ","==":" eq ","!=":" ne ",lessthan:" lt ",lessthanorequal:" le ",greaterthan:" gt ",greaterthanorequal:" ge ",equal:" eq ",notequal:" ne "},n.odUniOperator={"$=":"endswith","^=":"startswith","*=":"substringof",endswith:"endswith",startswith:"startswith",contains:"substringof",doesnotendwith:"not endswith",doesnotstartwith:"not startswith",doesnotcontain:"not substringof",wildcard:"wildcard",like:"like"},n.odv4UniOperator={"$=":"endswith","^=":"startswith","*=":"contains",endswith:"endswith",startswith:"startswith",contains:"contains",doesnotendwith:"not endswith",doesnotstartwith:"not startswith",doesnotcontain:"not contains",wildcard:"wildcard",like:"like"},n.diacritics={"\u24b6":"A",\uff21:"A",\u00c0:"A",\u00c1:"A",\u00c2:"A",\u1ea6:"A",\u1ea4:"A",\u1eaa:"A",\u1ea8:"A",\u00c3:"A",\u0100:"A",\u0102:"A",\u1eb0:"A",\u1eae:"A",\u1eb4:"A",\u1eb2:"A",\u0226:"A",\u01e0:"A",\u00c4:"A",\u01de:"A",\u1ea2:"A",\u00c5:"A",\u01fa:"A",\u01cd:"A",\u0200:"A",\u0202:"A",\u1ea0:"A",\u1eac:"A",\u1eb6:"A",\u1e00:"A",\u0104:"A",\u023a:"A",\u2c6f:"A",\ua732:"AA",\u00c6:"AE",\u01fc:"AE",\u01e2:"AE",\ua734:"AO",\ua736:"AU",\ua738:"AV",\ua73a:"AV",\ua73c:"AY","\u24b7":"B",\uff22:"B",\u1e02:"B",\u1e04:"B",\u1e06:"B",\u0243:"B",\u0182:"B",\u0181:"B","\u24b8":"C",\uff23:"C",\u0106:"C",\u0108:"C",\u010a:"C",\u010c:"C",\u00c7:"C",\u1e08:"C",\u0187:"C",\u023b:"C",\ua73e:"C","\u24b9":"D",\uff24:"D",\u1e0a:"D",\u010e:"D",\u1e0c:"D",\u1e10:"D",\u1e12:"D",\u1e0e:"D",\u0110:"D",\u018b:"D",\u018a:"D",\u0189:"D",\ua779:"D",\u01f1:"DZ",\u01c4:"DZ",\u01f2:"Dz",\u01c5:"Dz","\u24ba":"E",\uff25:"E",\u00c8:"E",\u00c9:"E",\u00ca:"E",\u1ec0:"E",\u1ebe:"E",\u1ec4:"E",\u1ec2:"E",\u1ebc:"E",\u0112:"E",\u1e14:"E",\u1e16:"E",\u0114:"E",\u0116:"E",\u00cb:"E",\u1eba:"E",\u011a:"E",\u0204:"E",\u0206:"E",\u1eb8:"E",\u1ec6:"E",\u0228:"E",\u1e1c:"E",\u0118:"E",\u1e18:"E",\u1e1a:"E",\u0190:"E",\u018e:"E","\u24bb":"F",\uff26:"F",\u1e1e:"F",\u0191:"F",\ua77b:"F","\u24bc":"G",\uff27:"G",\u01f4:"G",\u011c:"G",\u1e20:"G",\u011e:"G",\u0120:"G",\u01e6:"G",\u0122:"G",\u01e4:"G",\u0193:"G",\ua7a0:"G",\ua77d:"G",\ua77e:"G","\u24bd":"H",\uff28:"H",\u0124:"H",\u1e22:"H",\u1e26:"H",\u021e:"H",\u1e24:"H",\u1e28:"H",\u1e2a:"H",\u0126:"H",\u2c67:"H",\u2c75:"H",\ua78d:"H","\u24be":"I",\uff29:"I",\u00cc:"I",\u00cd:"I",\u00ce:"I",\u0128:"I",\u012a:"I",\u012c:"I",\u0130:"I",\u00cf:"I",\u1e2e:"I",\u1ec8:"I",\u01cf:"I",\u0208:"I",\u020a:"I",\u1eca:"I",\u012e:"I",\u1e2c:"I",\u0197:"I","\u24bf":"J",\uff2a:"J",\u0134:"J",\u0248:"J","\u24c0":"K",\uff2b:"K",\u1e30:"K",\u01e8:"K",\u1e32:"K",\u0136:"K",\u1e34:"K",\u0198:"K",\u2c69:"K",\ua740:"K",\ua742:"K",\ua744:"K",\ua7a2:"K","\u24c1":"L",\uff2c:"L",\u013f:"L",\u0139:"L",\u013d:"L",\u1e36:"L",\u1e38:"L",\u013b:"L",\u1e3c:"L",\u1e3a:"L",\u0141:"L",\u023d:"L",\u2c62:"L",\u2c60:"L",\ua748:"L",\ua746:"L",\ua780:"L",\u01c7:"LJ",\u01c8:"Lj","\u24c2":"M",\uff2d:"M",\u1e3e:"M",\u1e40:"M",\u1e42:"M",\u2c6e:"M",\u019c:"M","\u24c3":"N",\uff2e:"N",\u01f8:"N",\u0143:"N",\u00d1:"N",\u1e44:"N",\u0147:"N",\u1e46:"N",\u0145:"N",\u1e4a:"N",\u1e48:"N",\u0220:"N",\u019d:"N",\ua790:"N",\ua7a4:"N",\u01ca:"NJ",\u01cb:"Nj","\u24c4":"O",\uff2f:"O",\u00d2:"O",\u00d3:"O",\u00d4:"O",\u1ed2:"O",\u1ed0:"O",\u1ed6:"O",\u1ed4:"O",\u00d5:"O",\u1e4c:"O",\u022c:"O",\u1e4e:"O",\u014c:"O",\u1e50:"O",\u1e52:"O",\u014e:"O",\u022e:"O",\u0230:"O",\u00d6:"O",\u022a:"O",\u1ece:"O",\u0150:"O",\u01d1:"O",\u020c:"O",\u020e:"O",\u01a0:"O",\u1edc:"O",\u1eda:"O",\u1ee0:"O",\u1ede:"O",\u1ee2:"O",\u1ecc:"O",\u1ed8:"O",\u01ea:"O",\u01ec:"O",\u00d8:"O",\u01fe:"O",\u0186:"O",\u019f:"O",\ua74a:"O",\ua74c:"O",\u01a2:"OI",\ua74e:"OO",\u0222:"OU","\u24c5":"P",\uff30:"P",\u1e54:"P",\u1e56:"P",\u01a4:"P",\u2c63:"P",\ua750:"P",\ua752:"P",\ua754:"P","\u24c6":"Q",\uff31:"Q",\ua756:"Q",\ua758:"Q",\u024a:"Q","\u24c7":"R",\uff32:"R",\u0154:"R",\u1e58:"R",\u0158:"R",\u0210:"R",\u0212:"R",\u1e5a:"R",\u1e5c:"R",\u0156:"R",\u1e5e:"R",\u024c:"R",\u2c64:"R",\ua75a:"R",\ua7a6:"R",\ua782:"R","\u24c8":"S",\uff33:"S",\u1e9e:"S",\u015a:"S",\u1e64:"S",\u015c:"S",\u1e60:"S",\u0160:"S",\u1e66:"S",\u1e62:"S",\u1e68:"S",\u0218:"S",\u015e:"S",\u2c7e:"S",\ua7a8:"S",\ua784:"S","\u24c9":"T",\uff34:"T",\u1e6a:"T",\u0164:"T",\u1e6c:"T",\u021a:"T",\u0162:"T",\u1e70:"T",\u1e6e:"T",\u0166:"T",\u01ac:"T",\u01ae:"T",\u023e:"T",\ua786:"T",\ua728:"TZ","\u24ca":"U",\uff35:"U",\u00d9:"U",\u00da:"U",\u00db:"U",\u0168:"U",\u1e78:"U",\u016a:"U",\u1e7a:"U",\u016c:"U",\u00dc:"U",\u01db:"U",\u01d7:"U",\u01d5:"U",\u01d9:"U",\u1ee6:"U",\u016e:"U",\u0170:"U",\u01d3:"U",\u0214:"U",\u0216:"U",\u01af:"U",\u1eea:"U",\u1ee8:"U",\u1eee:"U",\u1eec:"U",\u1ef0:"U",\u1ee4:"U",\u1e72:"U",\u0172:"U",\u1e76:"U",\u1e74:"U",\u0244:"U","\u24cb":"V",\uff36:"V",\u1e7c:"V",\u1e7e:"V",\u01b2:"V",\ua75e:"V",\u0245:"V",\ua760:"VY","\u24cc":"W",\uff37:"W",\u1e80:"W",\u1e82:"W",\u0174:"W",\u1e86:"W",\u1e84:"W",\u1e88:"W",\u2c72:"W","\u24cd":"X",\uff38:"X",\u1e8a:"X",\u1e8c:"X","\u24ce":"Y",\uff39:"Y",\u1ef2:"Y",\u00dd:"Y",\u0176:"Y",\u1ef8:"Y",\u0232:"Y",\u1e8e:"Y",\u0178:"Y",\u1ef6:"Y",\u1ef4:"Y",\u01b3:"Y",\u024e:"Y",\u1efe:"Y","\u24cf":"Z",\uff3a:"Z",\u0179:"Z",\u1e90:"Z",\u017b:"Z",\u017d:"Z",\u1e92:"Z",\u1e94:"Z",\u01b5:"Z",\u0224:"Z",\u2c7f:"Z",\u2c6b:"Z",\ua762:"Z","\u24d0":"a",\uff41:"a",\u1e9a:"a",\u00e0:"a",\u00e1:"a",\u00e2:"a",\u1ea7:"a",\u1ea5:"a",\u1eab:"a",\u1ea9:"a",\u00e3:"a",\u0101:"a",\u0103:"a",\u1eb1:"a",\u1eaf:"a",\u1eb5:"a",\u1eb3:"a",\u0227:"a",\u01e1:"a",\u00e4:"a",\u01df:"a",\u1ea3:"a",\u00e5:"a",\u01fb:"a",\u01ce:"a",\u0201:"a",\u0203:"a",\u1ea1:"a",\u1ead:"a",\u1eb7:"a",\u1e01:"a",\u0105:"a",\u2c65:"a",\u0250:"a",\ua733:"aa",\u00e6:"ae",\u01fd:"ae",\u01e3:"ae",\ua735:"ao",\ua737:"au",\ua739:"av",\ua73b:"av",\ua73d:"ay","\u24d1":"b",\uff42:"b",\u1e03:"b",\u1e05:"b",\u1e07:"b",\u0180:"b",\u0183:"b",\u0253:"b","\u24d2":"c",\uff43:"c",\u0107:"c",\u0109:"c",\u010b:"c",\u010d:"c",\u00e7:"c",\u1e09:"c",\u0188:"c",\u023c:"c",\ua73f:"c",\u2184:"c","\u24d3":"d",\uff44:"d",\u1e0b:"d",\u010f:"d",\u1e0d:"d",\u1e11:"d",\u1e13:"d",\u1e0f:"d",\u0111:"d",\u018c:"d",\u0256:"d",\u0257:"d",\ua77a:"d",\u01f3:"dz",\u01c6:"dz","\u24d4":"e",\uff45:"e",\u00e8:"e",\u00e9:"e",\u00ea:"e",\u1ec1:"e",\u1ebf:"e",\u1ec5:"e",\u1ec3:"e",\u1ebd:"e",\u0113:"e",\u1e15:"e",\u1e17:"e",\u0115:"e",\u0117:"e",\u00eb:"e",\u1ebb:"e",\u011b:"e",\u0205:"e",\u0207:"e",\u1eb9:"e",\u1ec7:"e",\u0229:"e",\u1e1d:"e",\u0119:"e",\u1e19:"e",\u1e1b:"e",\u0247:"e",\u025b:"e",\u01dd:"e","\u24d5":"f",\uff46:"f",\u1e1f:"f",\u0192:"f",\ua77c:"f","\u24d6":"g",\uff47:"g",\u01f5:"g",\u011d:"g",\u1e21:"g",\u011f:"g",\u0121:"g",\u01e7:"g",\u0123:"g",\u01e5:"g",\u0260:"g",\ua7a1:"g",\u1d79:"g",\ua77f:"g","\u24d7":"h",\uff48:"h",\u0125:"h",\u1e23:"h",\u1e27:"h",\u021f:"h",\u1e25:"h",\u1e29:"h",\u1e2b:"h",\u1e96:"h",\u0127:"h",\u2c68:"h",\u2c76:"h",\u0265:"h",\u0195:"hv","\u24d8":"i",\uff49:"i",\u00ec:"i",\u00ed:"i",\u00ee:"i",\u0129:"i",\u012b:"i",\u012d:"i",\u00ef:"i",\u1e2f:"i",\u1ec9:"i",\u01d0:"i",\u0209:"i",\u020b:"i",\u1ecb:"i",\u012f:"i",\u1e2d:"i",\u0268:"i",\u0131:"i","\u24d9":"j",\uff4a:"j",\u0135:"j",\u01f0:"j",\u0249:"j","\u24da":"k",\uff4b:"k",\u1e31:"k",\u01e9:"k",\u1e33:"k",\u0137:"k",\u1e35:"k",\u0199:"k",\u2c6a:"k",\ua741:"k",\ua743:"k",\ua745:"k",\ua7a3:"k","\u24db":"l",\uff4c:"l",\u0140:"l",\u013a:"l",\u013e:"l",\u1e37:"l",\u1e39:"l",\u013c:"l",\u1e3d:"l",\u1e3b:"l",\u017f:"l",\u0142:"l",\u019a:"l",\u026b:"l",\u2c61:"l",\ua749:"l",\ua781:"l",\ua747:"l",\u01c9:"lj","\u24dc":"m",\uff4d:"m",\u1e3f:"m",\u1e41:"m",\u1e43:"m",\u0271:"m",\u026f:"m","\u24dd":"n",\uff4e:"n",\u01f9:"n",\u0144:"n",\u00f1:"n",\u1e45:"n",\u0148:"n",\u1e47:"n",\u0146:"n",\u1e4b:"n",\u1e49:"n",\u019e:"n",\u0272:"n",\u0149:"n",\ua791:"n",\ua7a5:"n",\u01cc:"nj","\u24de":"o",\uff4f:"o",\u00f2:"o",\u00f3:"o",\u00f4:"o",\u1ed3:"o",\u1ed1:"o",\u1ed7:"o",\u1ed5:"o",\u00f5:"o",\u1e4d:"o",\u022d:"o",\u1e4f:"o",\u014d:"o",\u1e51:"o",\u1e53:"o",\u014f:"o",\u022f:"o",\u0231:"o",\u00f6:"o",\u022b:"o",\u1ecf:"o",\u0151:"o",\u01d2:"o",\u020d:"o",\u020f:"o",\u01a1:"o",\u1edd:"o",\u1edb:"o",\u1ee1:"o",\u1edf:"o",\u1ee3:"o",\u1ecd:"o",\u1ed9:"o",\u01eb:"o",\u01ed:"o",\u00f8:"o",\u01ff:"o",\u0254:"o",\ua74b:"o",\ua74d:"o",\u0275:"o",\u01a3:"oi",\u0223:"ou",\ua74f:"oo","\u24df":"p",\uff50:"p",\u1e55:"p",\u1e57:"p",\u01a5:"p",\u1d7d:"p",\ua751:"p",\ua753:"p",\ua755:"p","\u24e0":"q",\uff51:"q",\u024b:"q",\ua757:"q",\ua759:"q","\u24e1":"r",\uff52:"r",\u0155:"r",\u1e59:"r",\u0159:"r",\u0211:"r",\u0213:"r",\u1e5b:"r",\u1e5d:"r",\u0157:"r",\u1e5f:"r",\u024d:"r",\u027d:"r",\ua75b:"r",\ua7a7:"r",\ua783:"r","\u24e2":"s",\uff53:"s",\u00df:"s",\u015b:"s",\u1e65:"s",\u015d:"s",\u1e61:"s",\u0161:"s",\u1e67:"s",\u1e63:"s",\u1e69:"s",\u0219:"s",\u015f:"s",\u023f:"s",\ua7a9:"s",\ua785:"s",\u1e9b:"s","\u24e3":"t",\uff54:"t",\u1e6b:"t",\u1e97:"t",\u0165:"t",\u1e6d:"t",\u021b:"t",\u0163:"t",\u1e71:"t",\u1e6f:"t",\u0167:"t",\u01ad:"t",\u0288:"t",\u2c66:"t",\ua787:"t",\ua729:"tz","\u24e4":"u",\uff55:"u",\u00f9:"u",\u00fa:"u",\u00fb:"u",\u0169:"u",\u1e79:"u",\u016b:"u",\u1e7b:"u",\u016d:"u",\u00fc:"u",\u01dc:"u",\u01d8:"u",\u01d6:"u",\u01da:"u",\u1ee7:"u",\u016f:"u",\u0171:"u",\u01d4:"u",\u0215:"u",\u0217:"u",\u01b0:"u",\u1eeb:"u",\u1ee9:"u",\u1eef:"u",\u1eed:"u",\u1ef1:"u",\u1ee5:"u",\u1e73:"u",\u0173:"u",\u1e77:"u",\u1e75:"u",\u0289:"u","\u24e5":"v",\uff56:"v",\u1e7d:"v",\u1e7f:"v",\u028b:"v",\ua75f:"v",\u028c:"v",\ua761:"vy","\u24e6":"w",\uff57:"w",\u1e81:"w",\u1e83:"w",\u0175:"w",\u1e87:"w",\u1e85:"w",\u1e98:"w",\u1e89:"w",\u2c73:"w","\u24e7":"x",\uff58:"x",\u1e8b:"x",\u1e8d:"x","\u24e8":"y",\uff59:"y",\u1ef3:"y",\u00fd:"y",\u0177:"y",\u1ef9:"y",\u0233:"y",\u1e8f:"y",\u00ff:"y",\u1ef7:"y",\u1e99:"y",\u1ef5:"y",\u01b4:"y",\u024f:"y",\u1eff:"y","\u24e9":"z",\uff5a:"z",\u017a:"z",\u1e91:"z",\u017c:"z",\u017e:"z",\u1e93:"z",\u1e95:"z",\u01b6:"z",\u0225:"z",\u0240:"z",\u2c6c:"z",\ua763:"z",\u0386:"\u0391",\u0388:"\u0395",\u0389:"\u0397",\u038a:"\u0399",\u03aa:"\u0399",\u038c:"\u039f",\u038e:"\u03a5",\u03ab:"\u03a5",\u038f:"\u03a9",\u03ac:"\u03b1",\u03ad:"\u03b5",\u03ae:"\u03b7",\u03af:"\u03b9",\u03ca:"\u03b9",\u0390:"\u03b9",\u03cc:"\u03bf",\u03cd:"\u03c5",\u03cb:"\u03c5",\u03b0:"\u03c5",\u03c9:"\u03c9",\u03c2:"\u03c3"},n.fnOperators={equal:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?n.toLowerCase(t)===n.toLowerCase(e):t===e},notequal:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),!n.fnOperators.equal(t,e,i)},lessthan:function(t,e,i){return i?n.toLowerCase(t)n.toLowerCase(e):t>e},lessthanorequal:function(t,e,i){return i?n.toLowerCase(t)<=n.toLowerCase(e):(m(t)&&(t=void 0),t<=e)},greaterthanorequal:function(t,e,i){return i?n.toLowerCase(t)>=n.toLowerCase(e):t>=e},contains:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?!m(t)&&!m(e)&&-1!==n.toLowerCase(t).indexOf(n.toLowerCase(e)):!m(t)&&!m(e)&&-1!==t.toString().indexOf(e)},doesnotcontain:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?!m(t)&&!m(e)&&-1===n.toLowerCase(t).indexOf(n.toLowerCase(e)):!m(t)&&!m(e)&&-1===t.toString().indexOf(e)},isnotnull:function(t){return null!=t},isnull:function(t){return null==t},startswith:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.startsWith(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.startsWith(t,e)},doesnotstartwith:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.notStartsWith(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.notStartsWith(t,e)},like:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.like(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.like(t,e)},isempty:function(t){return void 0===t||""===t},isnotempty:function(t){return void 0!==t&&""!==t},wildcard:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?(t||"boolean"==typeof t)&&e&&"object"!=typeof t&&n.wildCard(n.toLowerCase(t),n.toLowerCase(e)):(t||"boolean"==typeof t)&&e&&n.wildCard(t,e)},endswith:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.endsWith(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.endsWith(t,e)},doesnotendwith:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.notEndsWith(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.notEndsWith(t,e)},processSymbols:function(t){var e=n.operatorSymbols[t];return e?n.fnOperators[e]:n.throwError("Query - Process Operator : Invalid operator")},processOperator:function(t){return n.fnOperators[t]||n.fnOperators.processSymbols(t)}},n.parse={parseJson:function(t){return"string"!=typeof t||!/^[\s]*\[|^[\s]*\{(.)+:/g.test(t)&&-1!==t.indexOf('"')?t instanceof Array?n.parse.iterateAndReviveArray(t):"object"==typeof t&&null!==t&&n.parse.iterateAndReviveJson(t):t=JSON.parse(t,n.parse.jsonReviver),t},iterateAndReviveArray:function(t){for(var e=0;e-1||e.indexOf("z")>-1,o=e.split(/[^0-9.]/);if(s){if(o[5].indexOf(".")>-1){var a=o[5].split(".");o[5]=a[0],o[6]=new Date(e).getUTCMilliseconds().toString()}else o[6]="00";e=n.dateParse.toTimeZone(new Date(parseInt(o[0],10),parseInt(o[1],10)-1,parseInt(o[2],10),parseInt(o[3],10),parseInt(o[4],10),parseInt(o[5]?o[5]:"00",10),parseInt(o[6],10)),n.serverTimezoneOffset,!1)}else{var l=new Date(parseInt(o[0],10),parseInt(o[1],10)-1,parseInt(o[2],10),parseInt(o[3],10),parseInt(o[4],10),parseInt(o[5]?o[5]:"00",10)),h=parseInt(o[6],10),c=parseInt(o[7],10);if(isNaN(h)&&isNaN(c))return l;e.indexOf("+")>-1?l.setHours(l.getHours()-h,l.getMinutes()-c):l.setHours(l.getHours()+h,l.getMinutes()+c),e=n.dateParse.toTimeZone(l,n.serverTimezoneOffset,!1)}null==n.serverTimezoneOffset&&(e=n.dateParse.addSelfOffset(e))}}return e},isJson:function(t){return"string"==typeof t[0]?t:n.parse.parseJson(t)},isGuid:function(t){return null!=/[A-Fa-f0-9]{8}(?:-[A-Fa-f0-9]{4}){3}-[A-Fa-f0-9]{12}/i.exec(t)},replacer:function(t,e){return n.isPlainObject(t)?n.parse.jsonReplacer(t,e):t instanceof Array?n.parse.arrayReplacer(t):t instanceof Date?n.parse.jsonReplacer({val:t},e).val:t},jsonReplacer:function(t,e){for(var i,s=0,o=Object.keys(t);s=0?"+":"-",s=function(a){var l=Math.floor(Math.abs(a));return(l<10?"0":"")+l};return e.getFullYear()+"-"+s(e.getMonth()+1)+"-"+s(e.getDate())+"T"+s(e.getHours())+":"+s(e.getMinutes())+":"+s(e.getSeconds())+r+s(i/60)+":"+s(i%60)}},n}(),Ml=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),BK={GroupGuid:"{271bbba0-1ee7}"},a5=function(){function n(t){this.options={from:"table",requestType:"json",sortBy:"sorted",select:"select",skip:"skip",group:"group",take:"take",search:"search",count:"requiresCounts",where:"where",aggregates:"aggregates",expand:"expand"},this.type=n,this.dataSource=t,this.pvt={}}return n.prototype.processResponse=function(t,e,i,r){return t},n}(),QE=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ml(t,n),t.prototype.processQuery=function(e,i){for(var a,l,p,r=e.dataSource.json.slice(0),s=r.length,o=!0,h={},c=0,d=[],u=[],f=0;f1?e.sort.filter(function(p){return p.fieldName===c})[0]:e.sort[0];s=this.onSortBy(s,d,e.query,!0)}e.page&&(s=this.onPage(s,e.page,e.query)),this.formGroupResult(s,h)}else{for(var o=e.lazyLoad.onDemandGroupInfo,a=o.where.length-1;a>=0;a--)s=this.onWhere(s,o.where[a]);if(e.group.length!==o.level)s=le.group(s,e.group[o.level].fieldName,r,null,null,e.group[o.level].comparer,!0),e.sort.length&&(s=this.onSortBy(s,e.sort[parseInt(o.level.toString(),10)],e.query,!0));else for(a=e.sort.length-1;a>=o.level;a--)s=this.onSortBy(s,e.sort[parseInt(a.toString(),10)],e.query,!1);i=s.length,h=s,s=(s=s.slice(o.skip)).slice(0,o.take),e.group.length!==o.level&&this.formGroupResult(s,h)}return{result:s,count:i}},t.prototype.formGroupResult=function(e,i){if(e.length&&i.length){var r="GroupGuid",s="childLevels",o="level",a="records";e[r]=i[r],e[s]=i[s],e[o]=i[o],e[a]=i[a]}return e},t.prototype.getAggregate=function(e){var i=jt.filterQueries(e.queries,"onAggregates"),r=[];if(i.length)for(var s=void 0,o=0;o=0;l--)a[l]&&(o=i.comparer,le.endsWith(a[l]," desc")&&(o=le.fnSort("descending"),a[l]=a[l].replace(" desc","")),e=le.sort(e,a[l],o));return e}return le.sort(e,s?"key":a,i.comparer)},t.prototype.onGroup=function(e,i,r){if(!e||!e.length)return e;var s=this.getAggregate(r);return le.group(e,le.getValue(i.fieldName,r),s,null,null,i.comparer)},t.prototype.onPage=function(e,i,r){var s=le.getValue(i.pageSize,r),o=(le.getValue(i.pageIndex,r)-1)*s;return e&&e.length?e.slice(o,o+s):e},t.prototype.onRange=function(e,i){return e&&e.length?e.slice(le.getValue(i.start),le.getValue(i.end)):e},t.prototype.onTake=function(e,i){return e&&e.length?e.slice(0,le.getValue(i.nos)):e},t.prototype.onSkip=function(e,i){return e&&e.length?e.slice(le.getValue(i.nos)):e},t.prototype.onSelect=function(e,i){return e&&e.length?le.select(e,le.getValue(i.fieldNames)):e},t.prototype.insert=function(e,i,r,s,o){return m(o)?e.dataSource.json.push(i):e.dataSource.json.splice(o,0,i)},t.prototype.remove=function(e,i,r,s){var a,o=e.dataSource.json;for("object"==typeof r&&!(r instanceof Date)&&(r=le.getObject(i,r)),a=0;a1&&(g="("+g+")"),p.filters.push(g);for(var y=0,S="object"==typeof p.filters[f]?Object.keys(p.filters[f]):[];y-1&&this.formRemoteGroupedData(e[s].items,i+1,r-1);var o="GroupGuid",h="records";return e[o]=BK[o],e.level=i,e.childLevels=r,e[h]=e[0].items.length?this.getGroupedRecords(e,!m(e[0].items[h])):[],e},t.prototype.getGroupedRecords=function(e,i){for(var r=[],o=0;ol.length-3?(l=l.substring(0,l.length-1),o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.endswith:le.odv4UniOperator.endswith):l.lastIndexOf("%")!==l.indexOf("%")&&l.lastIndexOf("%")>l.indexOf("%")+1?(l=l.substring(l.indexOf("%")+1,l.lastIndexOf("%")),o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains):o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains),l="'"+(l=encodeURIComponent(l))+"'";else if("wildcard"===o)if(-1!==l.indexOf("*")){var d=l.split("*"),u=void 0,p=0;if(0!==l.indexOf("*")&&-1===d[0].indexOf("%3f")&&-1===d[0].indexOf("?")&&(u="'"+(u=d[0])+"'",s+=(o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.startswith:le.odv4UniOperator.startswith)+"(",s+=c+",",a&&(s+=a),s+=u+")",p++),l.lastIndexOf("*")!==l.length-1&&-1===d[d.length-1].indexOf("%3f")&&-1===d[d.length-1].indexOf("?")&&(u="'"+(u=d[d.length-1])+"'",p>0&&(s+=" and "),s+=(o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.endswith:le.odv4UniOperator.endswith)+"(",s+=c+",",a&&(s+=a),s+=u+")",p++),d.length>2)for(var f=1;f0&&(s+=" and "),"substringof"===(o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains)||"not substringof"===o){var g=u;u=c,c=g}s+=o+"(",s+=c+",",a&&(s+=a),s+=u+")",p++}0===p?(o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains,(-1!==l.indexOf("?")||-1!==l.indexOf("%3f"))&&(l=-1!==l.indexOf("?")?l.split("?").join(""):l.split("%3f").join("")),l="'"+l+"'"):o="wildcard"}else o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains,(-1!==l.indexOf("?")||-1!==l.indexOf("%3f"))&&(l=-1!==l.indexOf("?")?l.split("?").join(""):l.split("%3f").join("")),l="'"+l+"'";return"substringof"!==o&&"not substringof"!==o||(g=l,l=c,c=g),"wildcard"!==o&&(s+=o+"(",s+=c+",",a&&(s+=a),s+=l+")"),s},t.prototype.addParams=function(e){n.prototype.addParams.call(this,e),delete e.reqParams.params},t.prototype.onComplexPredicate=function(e,i,r){for(var s=[],o=0;o-1;p--)!/\bContent-ID:/i.test(c[p])||!/\bHTTP.+201/.test(c[p])||(l=parseInt(/\bContent-ID: (\d+)/i.exec(c[p])[1],10),o.addedRecords[l]&&(h=le.parse.parseJson(/^\{.+\}/m.exec(c[p])[0]),ze({},o.addedRecords[l],this.processResponse(h))));return o}return null},t.prototype.compareAndRemove=function(e,i,r){var s=this;return m(i)||Object.keys(e).forEach(function(o){o!==r&&"@odata.etag"!==o&&(le.isPlainObject(e[o])?(s.compareAndRemove(e[o],i[o]),0===Object.keys(e[o]).filter(function(l){return"@odata.etag"!==l}).length&&delete e[o]):(e[o]===i[o]||e[o]&&i[o]&&e[o].valueOf()===i[o].valueOf())&&delete e[o])}),e},t}(uc),FK=function(n){function t(){var e=n.call(this)||this;return yt("beforeSend",uc.prototype.beforeSend,e),e}return Ml(t,n),t.prototype.insert=function(e,i,r,s,o){return this.pvt.position=o,this.updateType="add",{url:e.dataSource.insertUrl||e.dataSource.crudUrl||e.dataSource.url,data:JSON.stringify(ze({},{value:i,table:r,action:"insert"},le.getAddParams(this,e,s)))}},t.prototype.remove=function(e,i,r,s,o){return n.prototype.remove.call(this,e,i,r),{type:"POST",url:e.dataSource.removeUrl||e.dataSource.crudUrl||e.dataSource.url,data:JSON.stringify(ze({},{key:r,keyColumn:i,table:s,action:"remove"},le.getAddParams(this,e,o)))}},t.prototype.update=function(e,i,r,s,o){return this.updateType="update",this.updateKey=i,{type:"POST",url:e.dataSource.updateUrl||e.dataSource.crudUrl||e.dataSource.url,data:JSON.stringify(ze({},{value:r,action:"update",keyColumn:i,key:r[i],table:s},le.getAddParams(this,e,o)))}},t.prototype.processResponse=function(e,i,r,s,o,a,l){var h;if(e="batch"===(o?JSON.parse(o.data):e).action?le.parse.parseJson(e):e,"add"===this.updateType&&n.prototype.insert.call(this,i,e,null,null,this.pvt.position),"update"===this.updateType&&n.prototype.update.call(this,i,this.updateKey,e),this.updateType=void 0,e.added)for(h=0;hi&&h.push(c)}for(c=0;cthis.pageSize;)h.results.splice(0,1),h.keys.splice(0,1);return window.localStorage.setItem(this.guidId,JSON.stringify(h)),e},t.prototype.beforeSend=function(e,i,r){!m(this.cacheAdaptor.options.batch)&&le.endsWith(r.url,this.cacheAdaptor.options.batch)&&"post"===r.type.toLowerCase()&&i.headers.set("Accept",this.cacheAdaptor.options.multipartAccept),e.dataSource.crossDomain||i.headers.set("Accept",this.cacheAdaptor.options.accept)},t.prototype.update=function(e,i,r,s){return this.isCrudAction=!0,this.cacheAdaptor.update(e,i,r,s)},t.prototype.insert=function(e,i,r){return this.isInsertAction=!0,this.cacheAdaptor.insert(e,i,r)},t.prototype.remove=function(e,i,r,s){return this.isCrudAction=!0,this.cacheAdaptor.remove(e,i,r,s)},t.prototype.batchRequest=function(e,i,r){return this.cacheAdaptor.batchRequest(e,i,r)},t}(uc),nt=function(){function n(t,e,i){var s,r=this;return this.dateParse=!0,this.timeZoneHandling=!0,this.persistQuery={},this.isInitialLoad=!1,this.requests=[],this.isInitialLoad=!0,!t&&!this.dataSource&&(t=[]),i=i||t.adaptor,t&&!1===t.timeZoneHandling&&(this.timeZoneHandling=t.timeZoneHandling),t instanceof Array?s={json:t,offline:!0}:"object"==typeof t?(t.json||(t.json=[]),t.enablePersistence||(t.enablePersistence=!1),t.id||(t.id=""),t.ignoreOnPersist||(t.ignoreOnPersist=[]),s={url:t.url,insertUrl:t.insertUrl,removeUrl:t.removeUrl,updateUrl:t.updateUrl,crudUrl:t.crudUrl,batchUrl:t.batchUrl,json:t.json,headers:t.headers,accept:t.accept,data:t.data,timeTillExpiration:t.timeTillExpiration,cachingPageSize:t.cachingPageSize,enableCaching:t.enableCaching,requestType:t.requestType,key:t.key,crossDomain:t.crossDomain,jsonp:t.jsonp,dataType:t.dataType,offline:void 0!==t.offline?t.offline:!(t.adaptor instanceof FK||t.adaptor instanceof _K||t.url),requiresFormat:t.requiresFormat,enablePersistence:t.enablePersistence,id:t.id,ignoreOnPersist:t.ignoreOnPersist}):le.throwError("DataManager: Invalid arguments"),void 0===s.requiresFormat&&!le.isCors()&&(s.requiresFormat=!!m(s.crossDomain)||s.crossDomain),void 0===s.dataType&&(s.dataType="json"),this.dataSource=s,this.defaultQuery=e,this.dataSource.enablePersistence&&this.dataSource.id&&window.addEventListener("unload",this.setPersistData.bind(this)),s.url&&s.offline&&!s.json.length?(this.isDataAvailable=!1,this.adaptor=i||new fp,this.dataSource.offline=!1,this.ready=this.executeQuery(e||new jt),this.ready.then(function(o){r.dataSource.offline=!0,r.isDataAvailable=!0,s.json=o.result,r.adaptor=new QE})):this.adaptor=s.offline?new QE:new fp,!s.jsonp&&this.adaptor instanceof fp&&(s.jsonp="callback"),this.adaptor=i||this.adaptor,s.enableCaching&&(this.adaptor=new UK(this.adaptor,s.timeTillExpiration,s.cachingPageSize)),this}return Object.defineProperty(n.prototype,"moduleName",{get:function(){return"datamanager"},enumerable:!0,configurable:!0}),n.prototype.getPersistedData=function(t){var e=localStorage.getItem(t||this.dataSource.id);return JSON.parse(e)},n.prototype.setPersistData=function(t,e,i){localStorage.setItem(e||this.dataSource.id,JSON.stringify(i||this.persistQuery))},n.prototype.setPersistQuery=function(t){var e=this,i=this.getPersistedData();if(this.isInitialLoad&&i&&Object.keys(i).length){this.persistQuery=i,this.persistQuery.queries=this.persistQuery.queries.filter(function(s){if(e.dataSource.ignoreOnPersist&&e.dataSource.ignoreOnPersist.length&&s.fn&&e.dataSource.ignoreOnPersist.some(function(l){return s.fn===l}))return!1;if("onWhere"===s.fn){var o=s.e;if(o&&o.isComplex&&o.predicates instanceof Array){var a=o.predicates.map(function(l){if(l.predicates&&l.predicates instanceof Array){var h=l.predicates.map(function(v){return new Ss(v.field,v.operator,v.value,v.ignoreCase,v.ignoreAccent,v.matchCase)});return"and"===l.condition?Ss.and(h):Ss.or(h)}return new Ss(l.field,l.operator,l.value,l.ignoreCase,l.ignoreAccent,l.matchCase)});s.e=new Ss(a[0],o.condition,a.slice(1))}}return!0});var r=ze(new jt,this.persistQuery);return this.isInitialLoad=!1,r}return this.persistQuery=t,this.isInitialLoad=!1,t},n.prototype.setDefaultQuery=function(t){return this.defaultQuery=t,this},n.prototype.executeLocal=function(t){!this.defaultQuery&&!(t instanceof jt)&&le.throwError("DataManager - executeLocal() : A query is required to execute"),this.dataSource.json||le.throwError("DataManager - executeLocal() : Json data is required to execute"),this.dataSource.enablePersistence&&this.dataSource.id&&(t=this.setPersistQuery(t));var e=this.adaptor.processQuery(this,t=t||this.defaultQuery);if(t.subQuery){var i=t.subQuery.fromTable,r=t.subQuery.lookups,s=t.isCountRequired?e.result:e;r&&r instanceof Array&&le.buildHierarchy(t.subQuery.fKey,i,s,r,t.subQuery.key);for(var o=0;oli");P.classList.remove("json-parent");for(var j=0;j',W=ve.children[0].placeholder}return W}function Q(k,W,ve){!m(ve)&&""!==ve&&K(W,ve.split(" ")),!m(k)&&""!==k&&V(W,k.split(" "))}function oe(k,W,ve){if("multiselect"===ve||function Mo(k){if(!k)return!1;for(var W=k;W&&W!==document.body;){if("none"===window.getComputedStyle(W).display)return!1;W=W.parentElement}return!0}(k)){var Te="multiselect"===ve?k:k.clientWidth-parseInt(getComputedStyle(k,null).getPropertyValue("padding-left"),10);!m(W)&&!m(W.getElementsByClassName("e-float-text-content")[0])&&(W.getElementsByClassName("e-float-text-content")[0].classList.contains("e-float-text-overflow")&&W.getElementsByClassName("e-float-text-content")[0].classList.remove("e-float-text-overflow"),(Te0)for(var Ye=0;Ye<_e.length;Ye++)_e[parseInt(Ye.toString(),10)].addEventListener("mousedown",wo,!1),_e[parseInt(Ye.toString(),10)].addEventListener("mouseup",Hl,!1);else if(_e.length>0)for(Ye=0;Ye<_e.length;Ye++)_e[parseInt(Ye.toString(),10)].removeEventListener("mousedown",wo,this),_e[parseInt(Ye.toString(),10)].removeEventListener("mouseup",Hl,this)}function wo(){for(var W=this.parentElement;!W.classList.contains("e-input-group");)W=W.parentElement;!function ya(k,W){!k.classList.contains("e-disabled")&&!k.querySelector("input").readOnly&&W.classList.add("e-input-btn-ripple")}(W,this)}function Hl(){var k=this;setTimeout(function(){k.classList.remove("e-input-btn-ripple")},500)}function vb(k,W){var ve=W("span",{className:k});return ve.classList.add("e-input-group-icon"),ve}function I_(k,W,ve,Te){var _e=m(Te)?mi:Te,Ye=vb(k,_e);W.classList.add("e-float-icon-left");var fi=W.querySelector(".e-input-in-wrap");if(m(fi)){fi=_e("span",{className:"e-input-in-wrap"}),ve.parentNode.insertBefore(fi,ve);var Gs=W.querySelectorAll(ve.tagName+" ~ *");fi.appendChild(ve);for(var Kn=0;Kn-1)if("class"===_e){var Ye=this.getInputValidClassList(k[""+_e]);""!==Ye&&V([W],Ye.split(" "))}else if("style"===_e){var fi=W.getAttribute(_e);fi=m(fi)?k[""+_e]:fi+k[""+_e],W.setAttribute(_e,fi)}else W.setAttribute(_e,k[""+_e])}},n.isBlank=function Hle(k){return!k||/^\s*$/.test(k)}}(Le||(Le={})),new RegExp("^(-)?(\\d*)$"),new RegExp("^[A-Za-z0-9._%+-]{1,}@[A-Za-z0-9._%+-]{1,}([.]{1}[a-zA-Z0-9]{2,}|[.]{1}[a-zA-Z0-9]{2,4}[.]{1}[a-zA-Z0-9]{2,4})$"),new RegExp("^([0-9]{4})-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])$"),new RegExp("^[0-9]*$"),new RegExp("^[+]?[0-9]{9,13}$"),new RegExp("^\\d{13,16}$");var me=function(){function n(t,e){this.width=t,this.height=e}return n.prototype.isEmpty=function(){return 0===this.height&&0===this.width},n.prototype.clone=function(){return new n(this.width,this.height)},n}(),Rie=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),KB=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},z=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Rie(t,n),t.equals=function(e,i){return e===i||!(!e||!i)&&(!e||!i||e.x===i.x&&e.y===i.y)},t.isEmptyPoint=function(e){return!(e.x&&e.y)},t.transform=function(e,i,r){var s={x:0,y:0};return s.x=Math.round(100*(e.x+r*Math.cos(i*Math.PI/180)))/100,s.y=Math.round(100*(e.y+r*Math.sin(i*Math.PI/180)))/100,s},t.findLength=function(e,i){return Math.sqrt(Math.pow(e.x-i.x,2)+Math.pow(e.y-i.y,2))},t.findAngle=function(e,i){var r=Math.atan2(i.y-e.y,i.x-e.x);return r=180*r/Math.PI,(r%=360)<0&&(r+=360),r},t.distancePoints=function(e,i){return Math.sqrt(Math.pow(i.x-e.x,2)+Math.pow(i.y-e.y,2))},t.getLengthFromListOfPoints=function(e){for(var i=0,r=0;ri.y&&!r?o.y+=s:o.y-=s:e.y===i.y?e.xi.x&&!r?o.x+=s:o.x-=s:r?(a=this.findAngle(e,i),o=this.transform(e,a,s)):(a=this.findAngle(i,e),o=this.transform(i,a,s)),o},t.direction=function(e,i){return Math.abs(i.x-e.x)>Math.abs(i.y-e.y)?e.x0)for(var r=0;rt.right||this.top>t.bottom||this.bottom=t.right&&this.top<=t.top&&this.bottom>=t.bottom},n.prototype.containsPoint=function(t,e){return void 0===e&&(e=0),this.left-e<=t.x&&this.right+e>=t.x&&this.top-e<=t.y&&this.bottom+e>=t.y},n.toBounds=function(t){for(var e=new n,i=0,r=t;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},s3=function(n){if(n)switch(n.type){case"Linear":default:return II;case"Radial":return Gie}return II},Yie=function(){return function n(t,e,i,r){this.left=t,this.right=e,this.top=i,this.bottom=r}}(),$n=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),it([I(0)],t.prototype,"left",void 0),it([I(0)],t.prototype,"right",void 0),it([I(0)],t.prototype,"top",void 0),it([I(0)],t.prototype,"bottom",void 0),t}(Ee),Qie=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),it([I(45)],t.prototype,"angle",void 0),it([I(5)],t.prototype,"distance",void 0),it([I(.7)],t.prototype,"opacity",void 0),it([I("lightgrey")],t.prototype,"color",void 0),t}(Ee),o3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),t.prototype.getClassName=function(){return"Stop"},it([I("")],t.prototype,"color",void 0),it([I(0)],t.prototype,"offset",void 0),it([I(1)],t.prototype,"opacity",void 0),t}(Ee),wx=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),it([Bt([],o3)],t.prototype,"stops",void 0),it([I("None")],t.prototype,"type",void 0),it([I("")],t.prototype,"id",void 0),t}(Ee),II=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),it([I(0)],t.prototype,"x1",void 0),it([I(0)],t.prototype,"x2",void 0),it([I(0)],t.prototype,"y1",void 0),it([I(0)],t.prototype,"y2",void 0),t}(wx),Gie=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),it([I(0)],t.prototype,"cx",void 0),it([I(0)],t.prototype,"cy",void 0),it([I(0)],t.prototype,"fx",void 0),it([I(0)],t.prototype,"fy",void 0),it([I(50)],t.prototype,"r",void 0),t}(wx),Ll=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),it([I("white")],t.prototype,"fill",void 0),it([I("black")],t.prototype,"strokeColor",void 0),it([I("")],t.prototype,"strokeDashArray",void 0),it([I(1)],t.prototype,"strokeWidth",void 0),it([I(1)],t.prototype,"opacity",void 0),it([D0(s3)],t.prototype,"gradient",void 0),t}(Ee),a3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),it([I("transparent")],t.prototype,"fill",void 0),t}(Ll),Gp=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),it([I("black")],t.prototype,"color",void 0),it([I("Arial")],t.prototype,"fontFamily",void 0),it([I(12)],t.prototype,"fontSize",void 0),it([I(!1)],t.prototype,"italic",void 0),it([I(!1)],t.prototype,"bold",void 0),it([I("CollapseSpace")],t.prototype,"whiteSpace",void 0),it([I("WrapWithOverflow")],t.prototype,"textWrapping",void 0),it([I("Center")],t.prototype,"textAlign",void 0),it([I("None")],t.prototype,"textDecoration",void 0),it([I("Wrap")],t.prototype,"textOverflow",void 0),it([I("transparent")],t.prototype,"fill",void 0),t}(Ll),on=function(n){return n[n.Default=0]="Default",n[n.expandNode=2]="expandNode",n[n.interaction=4]="interaction",n[n.GroupingInProgress=8]="GroupingInProgress",n[n.GroupClipboardInProcess=16]="GroupClipboardInProcess",n[n.ClearObject=32]="ClearObject",n}(on||{}),hi=function(n){return n[n.Visible=1]="Visible",n[n.Hidden=2]="Hidden",n[n.Hover=4]="Hover",n[n.Connect=8]="Connect",n}(hi||{}),Kt=function(n){return n[n.None=0]="None",n[n.ShowHorizontalLines=1]="ShowHorizontalLines",n[n.ShowVerticalLines=2]="ShowVerticalLines",n[n.ShowLines=3]="ShowLines",n[n.SnapToHorizontalLines=4]="SnapToHorizontalLines",n[n.SnapToVerticalLines=8]="SnapToVerticalLines",n[n.SnapToLines=12]="SnapToLines",n[n.SnapToObject=16]="SnapToObject",n[n.All=31]="All",n}(Kt||{}),mr=function(n){return n[n.None=1]="None",n[n.ConnectorSourceThumb=2]="ConnectorSourceThumb",n[n.ConnectorTargetThumb=4]="ConnectorTargetThumb",n[n.ResizeSouthEast=8]="ResizeSouthEast",n[n.ResizeSouthWest=16]="ResizeSouthWest",n[n.ResizeNorthEast=32]="ResizeNorthEast",n[n.ResizeNorthWest=64]="ResizeNorthWest",n[n.ResizeEast=128]="ResizeEast",n[n.ResizeWest=256]="ResizeWest",n[n.ResizeSouth=512]="ResizeSouth",n[n.ResizeNorth=1024]="ResizeNorth",n[n.Rotate=2048]="Rotate",n[n.UserHandle=4096]="UserHandle",n[n.ToolTip=8192]="ToolTip",n[n.ResizeAll=2046]="ResizeAll",n[n.All=16382]="All",n}(mr||{}),qe=function(n){return n[n.None=1]="None",n[n.Select=2]="Select",n[n.Delete=4]="Delete",n[n.Drag=8]="Drag",n[n.DragSourceEnd=16]="DragSourceEnd",n[n.DragTargetEnd=32]="DragTargetEnd",n[n.DragSegmentThumb=64]="DragSegmentThumb",n[n.AllowDrop=128]="AllowDrop",n[n.Bridging=256]="Bridging",n[n.BridgeObstacle=512]="BridgeObstacle",n[n.InheritBridging=1024]="InheritBridging",n[n.PointerEvents=2048]="PointerEvents",n[n.Tooltip=4096]="Tooltip",n[n.InheritTooltip=8192]="InheritTooltip",n[n.Interaction=4218]="Interaction",n[n.ReadOnly=16384]="ReadOnly",n[n.LineRouting=32768]="LineRouting",n[n.InheritLineRouting=65536]="InheritLineRouting",n[n.ConnectToNearByNode=131072]="ConnectToNearByNode",n[n.ConnectToNearByPort=262144]="ConnectToNearByPort",n[n.ConnectToNearByElement=393216]="ConnectToNearByElement",n[n.InheritSegmentThumbShape=524288]="InheritSegmentThumbShape",n[n.InheritSegmentThumbSize=1048576]="InheritSegmentThumbSize",n[n.Default=2043454]="Default",n}(qe||{}),Lr=function(n){return n[n.ReadOnly=2]="ReadOnly",n[n.InheritReadOnly=4]="InheritReadOnly",n[n.Select=8]="Select",n[n.Drag=16]="Drag",n[n.Resize=32]="Resize",n[n.Rotate=64]="Rotate",n[n.Tooltip=128]="Tooltip",n[n.Interaction=120]="Interaction",n[n.None=0]="None",n}(Lr||{}),ie=function(n){return n[n.None=0]="None",n[n.Select=2]="Select",n[n.Drag=4]="Drag",n[n.Rotate=8]="Rotate",n[n.Shadow=16]="Shadow",n[n.PointerEvents=32]="PointerEvents",n[n.Delete=64]="Delete",n[n.InConnect=128]="InConnect",n[n.OutConnect=256]="OutConnect",n[n.Individual=512]="Individual",n[n.Expandable=1024]="Expandable",n[n.AllowDrop=2048]="AllowDrop",n[n.Inherit=78]="Inherit",n[n.ResizeNorthEast=4096]="ResizeNorthEast",n[n.ResizeEast=8192]="ResizeEast",n[n.ResizeSouthEast=16384]="ResizeSouthEast",n[n.ResizeSouth=32768]="ResizeSouth",n[n.ResizeSouthWest=65536]="ResizeSouthWest",n[n.ResizeWest=131072]="ResizeWest",n[n.ResizeNorthWest=262144]="ResizeNorthWest",n[n.ResizeNorth=524288]="ResizeNorth",n[n.Resize=1044480]="Resize",n[n.AspectRatio=1048576]="AspectRatio",n[n.Tooltip=2097152]="Tooltip",n[n.InheritTooltip=4194304]="InheritTooltip",n[n.ReadOnly=8388608]="ReadOnly",n[n.HideThumbs=16777216]="HideThumbs",n[n.AllowMovingOutsideLane=33554432]="AllowMovingOutsideLane",n[n.Default=5240814]="Default",n}(ie||{}),Xr=function(n){return n[n.None=0]="None",n[n.ElementIsPort=2]="ElementIsPort",n[n.ElementIsGroup=4]="ElementIsGroup",n[n.HorizontalLaneHeader=8]="HorizontalLaneHeader",n}(Xr||{}),bt=function(n){return n[n.Rotate=2]="Rotate",n[n.ConnectorSource=4]="ConnectorSource",n[n.ConnectorTarget=8]="ConnectorTarget",n[n.ResizeNorthEast=16]="ResizeNorthEast",n[n.ResizeEast=32]="ResizeEast",n[n.ResizeSouthEast=64]="ResizeSouthEast",n[n.ResizeSouth=128]="ResizeSouth",n[n.ResizeSouthWest=256]="ResizeSouthWest",n[n.ResizeWest=512]="ResizeWest",n[n.ResizeNorthWest=1024]="ResizeNorthWest",n[n.ResizeNorth=2048]="ResizeNorth",n[n.Default=4094]="Default",n}(bt||{}),rt=function(n){return n[n.None=1]="None",n[n.Bridging=2]="Bridging",n[n.UndoRedo=4]="UndoRedo",n[n.Tooltip=8]="Tooltip",n[n.UserInteraction=16]="UserInteraction",n[n.ApiUpdate=32]="ApiUpdate",n[n.PageEditable=48]="PageEditable",n[n.Zoom=64]="Zoom",n[n.PanX=128]="PanX",n[n.PanY=256]="PanY",n[n.Pan=384]="Pan",n[n.ZoomTextEdit=512]="ZoomTextEdit",n[n.Virtualization=1024]="Virtualization",n[n.LineRouting=2048]="LineRouting",n[n.Default=500]="Default",n}(rt||{}),Ci=function(n){return n[n.None=0]="None",n[n.SingleSelect=1]="SingleSelect",n[n.MultipleSelect=2]="MultipleSelect",n[n.ZoomPan=4]="ZoomPan",n[n.DrawOnce=8]="DrawOnce",n[n.ContinuousDraw=16]="ContinuousDraw",n[n.Default=3]="Default",n}(Ci||{}),Ya=function(n){return n[n.Self=1]="Self",n[n.Parent=2]="Parent",n}(Ya||{}),pt=function(n){return n[n.None=0]="None",n[n.Control=1]="Control",n[n.Meta=1]="Meta",n[n.Alt=2]="Alt",n[n.Shift=4]="Shift",n}(pt||{}),Mt=function(n){return n[n.None=null]="None",n[n.Number0=0]="Number0",n[n.Number1=1]="Number1",n[n.Number2=2]="Number2",n[n.Number3=3]="Number3",n[n.Number4=4]="Number4",n[n.Number5=5]="Number5",n[n.Number6=6]="Number6",n[n.Number7=7]="Number7",n[n.Number8=8]="Number8",n[n.Number9=9]="Number9",n[n.A=65]="A",n[n.B=66]="B",n[n.C=67]="C",n[n.D=68]="D",n[n.E=69]="E",n[n.F=70]="F",n[n.G=71]="G",n[n.H=72]="H",n[n.I=73]="I",n[n.J=74]="J",n[n.K=75]="K",n[n.L=76]="L",n[n.M=77]="M",n[n.N=78]="N",n[n.O=79]="O",n[n.P=80]="P",n[n.Q=81]="Q",n[n.R=82]="R",n[n.S=83]="S",n[n.T=84]="T",n[n.U=85]="U",n[n.V=86]="V",n[n.W=87]="W",n[n.X=88]="X",n[n.Y=89]="Y",n[n.Z=90]="Z",n[n.Left=37]="Left",n[n.Up=38]="Up",n[n.Right=39]="Right",n[n.Down=40]="Down",n[n.Escape=27]="Escape",n[n.Space=32]="Space",n[n.PageUp=33]="PageUp",n[n.PageDown=34]="PageDown",n[n.End=35]="End",n[n.Home=36]="Home",n[n.Delete=46]="Delete",n[n.Tab=9]="Tab",n[n.Enter=13]="Enter",n[n.BackSpace=8]="BackSpace",n[n.F1=112]="F1",n[n.F2=113]="F2",n[n.F3=114]="F3",n[n.F4=115]="F4",n[n.F5=116]="F5",n[n.F6=117]="F6",n[n.F7=118]="F7",n[n.F8=119]="F8",n[n.F9=120]="F9",n[n.F10=121]="F10",n[n.F11=122]="F11",n[n.F12=123]="F12",n[n.Star=56]="Star",n[n.Plus=187]="Plus",n[n.Minus=189]="Minus",n[n.BracketLeft=219]="BracketLeft",n[n.BracketRight=221]="BracketRight",n}(Mt||{}),ee=function(n){return n[n.Render=2]="Render",n[n.PublicMethod=4]="PublicMethod",n[n.ToolAction=8]="ToolAction",n[n.UndoRedo=16]="UndoRedo",n[n.TextEdit=32]="TextEdit",n[n.Group=64]="Group",n[n.Clear=128]="Clear",n[n.PreventClearSelection=256]="PreventClearSelection",n[n.Interactions=512]="Interactions",n[n.PreventHistory=1024]="PreventHistory",n[n.PreventIconsUpdate=2048]="PreventIconsUpdate",n[n.PreventCollectionChangeOnDragOver=4096]="PreventCollectionChangeOnDragOver",n[n.PreventZIndexOnDragging=8192]="PreventZIndexOnDragging",n[n.isGroupDragging=16384]="isGroupDragging",n[n.DragUsingMouse=32768]="DragUsingMouse",n[n.DecoratorPropertyChange=65536]="DecoratorPropertyChange",n[n.PreventLaneContainerUpdate=131072]="PreventLaneContainerUpdate",n}(ee||{}),Qa=function(n){return n[n.None=2]="None",n[n.DrawSelectorBorder=4]="DrawSelectorBorder",n[n.PreventRenderSelector=8]="PreventRenderSelector",n}(Qa||{}),$i=function(n){return n[n.None=0]="None",n[n.PreventDrag=2]="PreventDrag",n[n.PreventScale=4]="PreventScale",n[n.PreventDataInit=8]="PreventDataInit",n[n.hScrollbarMoved=16]="hScrollbarMoved",n[n.vScrollbarMoved=32]="vScrollbarMoved",n[n.AnimationClick=64]="AnimationClick",n[n.EnableGroupAction=128]="EnableGroupAction",n[n.PanInProgress=256]="PanInProgress",n[n.OverViewAction=512]="OverViewAction",n}($i||{}),ca=function(n){return n[n.None=0]="None",n[n.PropertyChange=1024]="PropertyChange",n[n.Interaction=2048]="Interaction",n}(ca||{}),Ae=function(n){return n[n.Zero=0]="Zero",n[n.One=1]="One",n[n.Two=2]="Two",n[n.Three=3]="Three",n[n.Four=4]="Four",n[n.Five=5]="Five",n}(Ae||{}),Ce=function(n){return n[n.collectionChange=0]="collectionChange",n[n.rotateChange=1]="rotateChange",n[n.positionChange=2]="positionChange",n[n.propertyChange=3]="propertyChange",n[n.selectionChange=4]="selectionChange",n[n.sizeChange=5]="sizeChange",n[n.drop=6]="drop",n[n.sourcePointChange=7]="sourcePointChange",n[n.targetPointChange=8]="targetPointChange",n[n.connectionChange=9]="connectionChange",n[n.animationComplete=10]="animationComplete",n[n.click=11]="click",n[n.doubleClick=12]="doubleClick",n[n.scrollChange=13]="scrollChange",n[n.dragEnter=14]="dragEnter",n[n.dragLeave=15]="dragLeave",n[n.dragOver=16]="dragOver",n[n.textEdit=17]="textEdit",n[n.paletteSelectionChange=18]="paletteSelectionChange",n[n.historyChange=19]="historyChange",n[n.mouseEnter=20]="mouseEnter",n[n.mouseLeave=21]="mouseLeave",n[n.mouseOver=22]="mouseOver",n[n.expandStateChange=23]="expandStateChange",n[n.segmentCollectionChange=24]="segmentCollectionChange",n[n.commandExecute=25]="commandExecute",n[n.historyStateChange=26]="historyStateChange",n[n.onUserHandleMouseDown=27]="onUserHandleMouseDown",n[n.onUserHandleMouseUp=28]="onUserHandleMouseUp",n[n.onUserHandleMouseEnter=29]="onUserHandleMouseEnter",n[n.onUserHandleMouseLeave=30]="onUserHandleMouseLeave",n[n.onImageLoad=31]="onImageLoad",n[n.onDoBindingInit=32]="onDoBindingInit",n[n.keyUp=33]="keyUp",n[n.keyDown=34]="keyDown",n[n.fixedUserHandleClick=35]="fixedUserHandleClick",n[n.elementDraw=36]="elementDraw",n[n.mouseWheel=37]="mouseWheel",n[n.segmentChange=38]="segmentChange",n[n.onFixedUserHandleMouseDown=39]="onFixedUserHandleMouseDown",n[n.onFixedUserHandleMouseUp=40]="onFixedUserHandleMouseUp",n[n.onFixedUserHandleMouseEnter=41]="onFixedUserHandleMouseEnter",n[n.onFixedUserHandleMouseLeave=42]="onFixedUserHandleMouseLeave",n[n.loaded=43]="loaded",n}(Ce||{}),ri=function(n){return n[n.None=1]="None",n[n.Drag=2]="Drag",n[n.Draw=4]="Draw",n[n.InConnect=8]="InConnect",n[n.OutConnect=16]="OutConnect",n[n.ToolTip=32]="ToolTip",n[n.InheritTooltip=64]="InheritTooltip",n[n.Default=24]="Default",n}(ri||{}),Cx=function(n){return n[n.None=1]="None",n[n.Source=2]="Source",n[n.Target=4]="Target",n[n.Intermediate=8]="Intermediate",n[n.All=14]="All",n}(Cx||{}),bI=function(n){return n[n.None=0]="None",n[n.SymmetricAngle=2]="SymmetricAngle",n[n.SymmetricDistance=4]="SymmetricDistance",n[n.Default=6]="Default",n}(bI||{}),as=function(){function n(){this.pivot={x:.5,y:.5},this.isDirt=!0,this.isExport=!1,this.exportScaleValue={x:0,y:0},this.exportScaleOffset={x:0,y:0},this.canApplyStyle=!0,this.visible=!0,this.offsetX=0,this.offsetY=0,this.cornerRadius=0,this.minHeight=void 0,this.minWidth=void 0,this.maxWidth=void 0,this.maxHeight=void 0,this.width=void 0,this.height=void 0,this.rotateAngle=0,this.margin={left:0,right:0,top:0,bottom:0},this.connectionDirection="Auto",this.horizontalAlignment="Auto",this.verticalAlignment="Auto",this.flip="None",this.flipMode="All",this.relativeMode="Point",this.transform=Ya.Self|Ya.Parent,this.style={fill:"white",strokeColor:"black",opacity:1,strokeWidth:1},this.desiredSize=new me,this.actualSize=new me,this.parentTransform=0,this.preventContainer=!1,this.isSvgRender=!1,this.bounds=new Ne(0,0,0,0),this.shadow=null,this.description="",this.staticSize=!1,this.shapeType="",this.isRectElement=!1,this.isCalculateDesiredSize=!0,this.flipOffset={x:0,y:0},this.elementActions=Xr.None,this.inversedAlignment=!0,this.position=void 0,this.unitMode=void 0,this.float=!1,this.floatingBounds=void 0}return n.prototype.setOffsetWithRespectToBounds=function(t,e,i){this.unitMode=i,this.position={x:t,y:e}},n.prototype.getAbsolutePosition=function(t){if(void 0!==this.position)return"Absolute"===this.unitMode?this.position:{x:this.position.x*t.width,y:this.position.y*t.height}},Object.defineProperty(n.prototype,"outerBounds",{get:function(){return this.floatingBounds||this.bounds},set:function(t){this.floatingBounds=t},enumerable:!0,configurable:!0}),n.prototype.measure=function(t,e,i){var s=void 0!==this.height?this.height:(t.height||0)-this.margin.top-this.margin.bottom;return this.id&&0===s&&this.elementActions&Xr.HorizontalLaneHeader&&(s=this.actualSize.height),this.desiredSize=new me(void 0!==this.width?this.width:(t.width||0)-this.margin.left-this.margin.right,s),this.isCalculateDesiredSize&&(this.desiredSize=this.validateDesiredSize(this.desiredSize,t)),this.desiredSize},n.prototype.arrange=function(t){return this.actualSize=t,this.updateBounds(),this.actualSize},n.prototype.updateBounds=function(){this.bounds=yr(this)},n.prototype.validateDesiredSize=function(t,e){return this.isRectElement&&!this.width&&!this.minWidth&&!this.maxWidth&&(t.width=50),this.isRectElement&&!this.height&&!this.minHeight&&!this.maxHeight&&(t.height=50),(void 0===t||void 0!==this.width&&void 0!==this.height)&&((t=t||new me).width=void 0===this.width?(e.width||0)-this.margin.left-this.margin.right:this.width,t.height=void 0===this.height?(e.height||0)-this.margin.top-this.margin.bottom:this.height),void 0!==this.minWidth&&(t.width=Math.max(t.width,this.minWidth)),void 0!==this.minHeight&&(t.height=Math.max(t.height,this.minHeight)),void 0!==this.maxWidth&&0!==this.maxWidth&&(t.width=Math.min(t.width,this.maxWidth)),void 0!==this.maxHeight&&0!==this.maxHeight&&(t.height=Math.min(t.height,this.maxHeight)),t},n}(),ere=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Cs=function(n){function t(){var e=null!==n&&n.apply(this,arguments)||this;return e.padding=new Yie(0,0,0,0),e.desiredBounds=void 0,e.measureChildren=!0,e.prevRotateAngle=0,e}return ere(t,n),t.prototype.hasChildren=function(){return void 0!==this.children&&this.children.length>0},t.prototype.measure=function(e,i,r){this.desiredBounds=void 0;var o,a,s=void 0;if(this.hasChildren()){for(var l=0;l=n.width&&s.length>0)i[i.length]={text:s,x:0,dy:0,width:o},s="";else{(s+=a[r+1]||"").indexOf("\n")>-1&&(i[i.length]={text:s,x:0,dy:0,width:Bc(s,n)},s="");var l=Bc(s,n);Math.ceil(l)+2>=n.width&&s.length>0&&(i[i.length]={text:s,x:0,dy:0,width:l},s=""),r===a.length-1&&s.length>0&&(i[i.length]={text:s,x:0,dy:0,width:l},s="")}else i=function Soe(n,t,e){var c,d,u,p,i=[],r="",s=0,o=0,a="nowrap"!==n.whiteSpace,h=(t||n.content).split("\n");for(s=0;s0?" ":"")+c[parseInt(o.toString(),10)];var f=Bc(d=c[o+1]?r+" "+c[o+1]:r,n);Math.floor(f)>(e||n.width)-2&&r.length>0?(i[i.length]={text:r,x:0,dy:0,width:d===r?f:r===p?u:Bc(r,n)},r=""):o===c.length-1&&(i[i.length]={text:r,x:0,dy:0,width:f},r=""),p=d,u=f}return i}(n,t,e);else i[i.length]={text:a,x:0,dy:0,width:Bc(a,n)};return i}(l,r,n.isLaneOrientation?i:void 0),n.wrapBounds=a=function Ioe(n,t){var r,s,e={x:0,width:0},i=0;for(i=0;in.width&&("Ellipsis"===n.textOverflow||"Clip"===n.textOverflow)?0:-r/2:"right"===n.textAlign?-r:t.length>1?0:-r/2,t[parseInt(i.toString(),10)].dy=1.2*n.fontSize,t[parseInt(i.toString(),10)].x=r,e.x=Math.min(e.x,r),e.width=Math.max(e.width,s);return e}(l,o),s.width=a.width,n.wrapBounds.width>=i&&"Wrap"!==l.textOverflow&&(s.width=i),s.height=o.length*n.style.fontSize*1.2,s}(this,0,0,this.isLaneOrientation?e.height:this.width||e.width):this.desiredSize,this.desiredSize=void 0===this.width||void 0===this.height?new me(i.width,i.height):new me(this.width,this.height),this.desiredSize=this.validateDesiredSize(this.desiredSize,e),this.desiredSize},t.prototype.arrange=function(e){return(e.width!==this.actualSize.width||e.height!==this.actualSize.height||this.isDirt)&&(this.doWrap=!0),this.actualSize=e,this.updateBounds(),this.isDirt=!1,this.actualSize},t}(as),ire=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Ii=function(n){function t(){var e=null!==n&&n.apply(this,arguments)||this;return e.measureChildren=void 0,e}return ire(t,n),t.prototype.measure=function(e,i,r){var s=void 0,o=void 0;if(this.hasChildren()){for(var a=0,l=this.children;a=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Ed=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return are(t,n),Lh([I("")],t.prototype,"content",void 0),Lh([I("TopLeft")],t.prototype,"position",void 0),Lh([I("Mouse")],t.prototype,"relativeMode",void 0),Lh([I(!0)],t.prototype,"showTipPointer",void 0),Lh([I("auto")],t.prototype,"width",void 0),Lh([I("auto")],t.prototype,"height",void 0),Lh([I("Auto")],t.prototype,"openOn",void 0),Lh([I()],t.prototype,"animation",void 0),Lh([I(!1)],t.prototype,"isSticky",void 0),t}(Ee);function l3(n){var t=new Sh;t=h3(n.tooltip,t);var e=new Sh(t);return e.beforeCollision=hre,e.beforeOpen=lre,e.cssClass="e-diagram-tooltip",e.opensOn="custom",e.appendTo("#"+n.element.id),e.close(),e}function lre(n){(""===this.content||void 0===this.content)&&(n.element.style.display="none")}function hre(n){n.collidedPosition&&n.collidedPosition!==this.position&&(n.element.style.display="none")}function Ex(n,t){var e=n.tooltipObject;return h3(t?t.tooltip:n.tooltip,e),e}function h3(n,t){return n.content?(t.content=n.content,"string"==typeof n.content&&(t.content=ko(function(){return n.content})),t.position=n.position,t.showTipPointer=n.showTipPointer,t.width=n.width,t.height=n.height,t.animation=n.animation?n.animation:{close:{effect:"None"}}):t.close(),t}var Dx=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Hn=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},xx=function(n){function t(e,i,r,s){var o=n.call(this,e,i,r,s)||this;return o.inEdges=[],o.outEdges=[],o}return Dx(t,n),Hn([I("")],t.prototype,"id",void 0),Hn([I("Center")],t.prototype,"horizontalAlignment",void 0),Hn([I("Center")],t.prototype,"verticalAlignment",void 0),Hn([re({},$n)],t.prototype,"margin",void 0),Hn([I(12)],t.prototype,"width",void 0),Hn([I(12)],t.prototype,"height",void 0),Hn([re({},Ll)],t.prototype,"style",void 0),Hn([I("Square")],t.prototype,"shape",void 0),Hn([I("Auto")],t.prototype,"connectionDirection",void 0),Hn([I(hi.Connect)],t.prototype,"visibility",void 0),Hn([I("")],t.prototype,"pathData",void 0),Hn([I(ri.Default)],t.prototype,"constraints",void 0),Hn([I()],t.prototype,"addInfo",void 0),Hn([I()],t.prototype,"outEdges",void 0),Hn([I()],t.prototype,"inEdges",void 0),Hn([re({},Ed)],t.prototype,"tooltip",void 0),t}(Ee),Es=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return Dx(t,n),t.prototype.getClassName=function(){return"PointPort"},Hn([re({x:.5,y:.5},z)],t.prototype,"offset",void 0),t}(xx),xc=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return Dx(t,n),t.prototype.getClassName=function(){return"PathPort"},Hn([I(.5)],t.prototype,"offset",void 0),Hn([re({x:0,y:0},z)],t.prototype,"displacement",void 0),Hn([I("Center")],t.prototype,"alignment",void 0),t}(xx),CI=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),lr=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},cre=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return CI(t,n),lr([I("blue")],t.prototype,"color",void 0),lr([I("")],t.prototype,"content",void 0),lr([I("")],t.prototype,"link",void 0),lr([I("None")],t.prototype,"textDecoration",void 0),lr([I("NewTab")],t.prototype,"hyperlinkOpenState",void 0),t}(Ee),Tx=function(n){function t(e,i,r,s){var o=n.call(this,e,i,r,s)||this;return r.id||(o.id=e.parentObj&&e.parentObj.propName&&"phases"===e.parentObj.propName?e.parentObj.id:Qe()),o}return CI(t,n),lr([I("")],t.prototype,"content",void 0),lr([I(void 0)],t.prototype,"template",void 0),lr([I("String")],t.prototype,"annotationType",void 0),lr([I(!0)],t.prototype,"visibility",void 0),lr([I(Lr.InheritReadOnly)],t.prototype,"constraints",void 0),lr([re(void 0,cre)],t.prototype,"hyperlink",void 0),lr([I("")],t.prototype,"id",void 0),lr([I()],t.prototype,"width",void 0),lr([I()],t.prototype,"height",void 0),lr([I(0)],t.prototype,"rotateAngle",void 0),lr([I("Parent")],t.prototype,"rotationReference",void 0),lr([re({strokeWidth:0,strokeColor:"transparent",fill:"transparent"},Gp)],t.prototype,"style",void 0),lr([I("Center")],t.prototype,"horizontalAlignment",void 0),lr([I("Center")],t.prototype,"verticalAlignment",void 0),lr([re({},$n)],t.prototype,"margin",void 0),lr([re({top:void 0,bottom:void 0,left:void 0,right:void 0},$n)],t.prototype,"dragLimit",void 0),lr([I("Shape")],t.prototype,"type",void 0),lr([re({},Ed)],t.prototype,"tooltip",void 0),lr([I()],t.prototype,"addInfo",void 0),t}(Ee),Zn=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return CI(t,n),t.prototype.getClassName=function(){return"ShapeAnnotation"},lr([re({x:.5,y:.5},z)],t.prototype,"offset",void 0),t}(Tx),Nr=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return CI(t,n),t.prototype.getClassName=function(){return"PathAnnotation"},lr([I(.5)],t.prototype,"offset",void 0),lr([re({x:0,y:0},z)],t.prototype,"displacement",void 0),lr([I("Center")],t.prototype,"alignment",void 0),lr([I(!1)],t.prototype,"segmentAngle",void 0),t}(Tx);function Ax(n){return fre[n.toString()]}function c3(n){return mre[""+n]}var fre={X:"M14,14 L106,106 M106,14 L14,106",Circle:"M0,50 A50,50,0 1 1 100,50 A50,50,0 1 1 0,50 Z",Square:"M0,0 L10,0 L10,10 L0,10 z"},gre={OpenArrow:"M15.9,23 L5,16 L15.9,9 L17,10.7 L8.7,16 L17,21.3Z",Square:"M0,0 L10,0 L10,10 L0,10 z",Fletch:"M14.8,10c0,0-3.5,6,0.2,12c0,0-2.5-6-10.9-6C4.1,16,11.3,16,14.8,10z",OpenFetch:"M6,17c-0.6,0-1-0.4-1-1s0.4-1,1-1c10.9,0,11-5,11-5c0-0.6,0.4-1,1-1s1,0.4,1,1C19,10.3,18.9,17,6,17C6,17,6,17,6,17z M18,23c-0.5,0-1-0.4-1-1c0-0.2-0.3-5-11-5c-0.6,0-1-0.5-1-1s0.4-1,1-1c0,0,0,0,0,0c12.9,0,13,6.7,13,7 C19,22.6,18.6,23,18,23z",IndentedArrow:"M17,10c0,0-4.5,5.5,0,12L5,16L17,10z",OutdentedArrow:"M14.6,10c0,0,5.4,6,0,12L5,16L14.6,10z",DoubleArrow:"M19,10 L19,22 L13,16Z M12,10 L12,22 L6,16Z",Arrow:"M15,10 L15,22 L5,16Z",Diamond:"M12,23l-7-7l7-7l6.9,7L12,23z",Circle:"M0,50 A50,50,0 1 1 100,50 A50,50,0 1 1 0,50 Z"},vre={Square:"M0,0 L10,0 L10,10 L0,10 z",Rhombus:"M10,5 L5,10 L0,5 L5,0 L10,5 Z ",Rectangle:"M0,0 L15,0 L15,10 L0,10 z ",OpenArrow:"M15.9,23 L5,16 L15.9,9 L17,10.7 L8.7,16 L17,21.3Z",Fletch:"M9.82,0 C9.82,0,6.61,5,10,10 C10,10,7.71,5,0,5 C0,5,6.61,5,9.82,0 Z ",OpenFetch:"M0.71,5.71 C0.29,5.71,0,5.43,0,5 C0,4.57,0.29,4.29,0.71,4.29 C8.5,4.29,8.57,0.71,8.57,0.71 C8.57,0.29,8.86,0,9.29,0 C9.719999999999999,0,10,0.29,10,0.71 C10,0.93,9.93,5.71,0.71,5.71 C0.71,5.71,0.71,5.71,0.71,5.71 Z M9.29,10 C8.93,10,8.57,9.71,8.57,9.29 C8.57,9.14,8.36,5.71,0.71,5.71 C0.29,5.71,0,5.36,0,5 C0,4.64,0.29,4.29,0.71,4.29 C0.71,4.29,0.71,4.29,0.71,4.29 C9.93,4.29,10,9.07,10,9.29 C10,9.71,9.71,10,9.29,10 Z ",IndentedArrow:"M10,0 C10,0,6.25,4.58,10,10 L0,5 L10,0 Z ",OutdentedArrow:"M8,0 C8,0,12.5,5,8,10 L0,5 L8,0 Z ",DoubleArrow:"M19,10 L19,22 L13,16Z M12,10 L12,22 L6,16Z",Arrow:"M15,10 L15,22 L5,16Z",Diamond:"M10,5 L5,10 L0,5 L5,0 L10,5 Z ",Circle:"M10,5 C10,7.76,7.76,10,5,10 C2.24,10,0,7.76,0,5 C0,2.24,2.24,0,5,0 C7.76,0,10,2.24,10,5 Z ",Ellipse:"M15,5 C15,7.76,11.64,10,7.5,10 C3.36,10,0,7.76,0,5 C0,2.24,3.36,0,7.5,0 C11.64,0,15,2.24,15,5 Z "},mre={Square:"M0,0 L10,0 L10,10 L0,10 z",Rhombus:"M10,5 L5,10 L0,5 L5,0 L10,5 Z ",Rectangle:"M0,0 L15,0 L15,10 L0,10 z",OpenArrow:"M23,15.9 L16,5 L9,15.9 L10.7,17 L16,8.7 L21,17.3Z",Fletch:"M9.82,0 C9.82,0,6.61,5,10,10 C10,10,7.71,5,0,5 C0,5,6.61,5,9.82,0 Z ",OpenFetch:"M0.71,5.71 C0.29,5.71,0,5.43,0,5 C0,4.57,0.29,4.29,0.71,4.29 C8.5,4.29,8.57,0.71,8.57,0.71 C8.57,0.29,8.86,0,9.29,0 C9.719999999999999,0,10,0.29,10,0.71 C10,0.93,9.93,5.71,0.71,5.71 C0.71,5.71,0.71,5.71,0.71,5.71 Z M9.29,10 C8.93,10,8.57,9.71,8.57,9.29 C8.57,9.14,8.36,5.71,0.71,5.71 C0.29,5.71,0,5.36,0,5 C0,4.64,0.29,4.29,0.71,4.29 C0.71,4.29,0.71,4.29,0.71,4.29 C9.93,4.29,10,9.07,10,9.29 C10,9.71,9.71,10,9.29,10 Z ",IndentedArrow:"M10,0 C10,0,6.25,4.58,10,10 L0,5 L10,0 Z ",OutdentedArrow:"M8,0 C8,0,12.5,5,8,10 L0,5 L8,0 Z ",DoubleArrow:"M10,19 L22,19 L16,13Z M10,12 L22,12 L16,6Z",Arrow:"M10,15 L22,15 L16,5Z",Diamond:"M10,5 L5,10 L0,5 L5,0 L10,5 Z ",Circle:"M10,5 C10,7.76,7.76,10,5,10 C2.24,10,0,7.76,0,5 C0,2.24,2.24,0,5,0 C7.76,0,10,2.24,10,5 Z ",Ellipse:"M15,5 C15,7.76,11.64,10,7.5,10 C3.36,10,0,7.76,0,5 C0,2.24,3.36,0,7.5,0 C11.64,0,15,2.24,15,5 Z "};function Lx(n){return yre[n.toString()]}var yre={Process:"M419.511,76.687L359.511,76.687L359.511,43.086L419.511,43.086z",Decision:"M 253.005,115.687L 200.567,146.071L 148.097,115.687L 200.534,85.304L 253.005,115.687 Z",Document:"M 60 31.9 c 0 0 -11 -7.7 -30 0 s -30 0 -30 0 V 0 h 60 V 31.9 Z",PreDefinedProcess:"M 0,0 L 50,0 L 50,50 L 0,50 Z M 8.334,0 L 8.334,50 M 41.667,0 L 41.667,50",Terminator:"M 269.711,29.33C 269.71,44.061 257.77,56 243.04,56L 158.058,56C 143.33,56 131.39,44.061 131.39,29.33L 131.39,29.33C 131.391,14.6057 143.33,2.669 158.058,2.669L 243.044,2.669C 257.772,2.669 269.711,14.6057 269.711,29.333 Z",PaperTap:"M0.0009,17.2042 L0.0009,47.165 C0.001,47.165 14.403,53.5455 25.00,47.165 C35.599,40.7852 44.403,43.5087 50.00,47.165L50.001,17.2042 M50.001,32.7987 L50.001,2.8405 C50.001,2.8405 35.599,-3.5427 25.001,2.8405C14.403,9.2237 5.599,6.494 0.0009,2.8405 L0.0009,32.7987",DirectData:"M 132.62 0 L 17.38 0 C 7.78 0 0 13.43 0 30 C 0 46.57 7.78 60 17.38 60 L 132.62 60 M 132.62 0C 123.02 0 115.24 13.43 115.24 30 C 115.24 46.57 123.02 60 132.62 60 C 142.22 60 150 46.57 150 30 C 150 13.43 142.22 0 132.62 0 z ",SequentialData:"M0.0029,24.999 C0.0029,11.1922 10.433,0.0021 23.295,0.0021 C36.159,0.00216 46.585,11.1922 46.585,24.999C46.585,38.8057 36.159,49.9979 23.295,49.9979 C10.433,49.9979 0.0029,38.8057 0.0029,24.999 z M23.294,49.999 L50.002,49.999",Sort:"M50.001,24.9971 L25.001,49.9971 L0.00097,24.9971 L25.001,-0.00286865 L50.001,24.9971 z M0.000976562,24.9971 L50.001,24.9971",MultiDocument:"M43.6826,40 C44.8746,40.6183 45.8586,41.3502 46.8366,42.1122 L46.8366,4.74487 L3.09857,4.74487 L3.09857,10.9544 M46.837,35.143 C48.027,35.765 49.025,36.604 50.003,37.369 L50.003,0.002 L6.264,0.002 L6.264,4.744 M43.682,47.113 L43.682,10.765 L0.0025,10.7652 L0.0025,47.1132 C0.0025,47.1132 12.5846,53.6101 21.8426,47.1132 C31.1006,40.6163 38.792,43.393 43.6826,47.1132 z",Collate:"M50.001,0.0028 L25.001,25.0029 L0.00097,0.0028 L50.001,0.002 z M0.0009,50.002 L25.001,25.002L50.001,50.002 L0.0009,50.0029 z",SummingJunction:"M7.3252,42.6768 L42.6772,7.3247 M42.6768,42.6768 L7.3248,7.3247 M0.0009,25.001 C0.0009,11.193 11.197,0.0009 25.001,0.0009 C38.809,0.0009 50.001,11.193 50.001,25.001 C50.001,38.809 38.809,50.001 25.001,50.001 C11.197,50.00 0.0009,38.809 0.0009,25.00 z",Or:"M 0 50 L 100 50 M 50 100 L 50 0.0 M 0 50 C 0 22.384 22.392 0 50 0 C 77.616 0 100 22.384 100 50 C 100 77.616 77.616 100 50 100 C 22.392 100 0 77.616 0 50 Z",InternalStorage:"M 0 3.81946A 2.5,3.81946 0 0,1 2.5,0L 47.5 0A 2.5,3.81946 0 0,1 50,3.81946L 50 45.836A 2.5,3.819446 0 0,1 47.5,49.652778L 2.5 49.652778A 2.5,3.819446 0 0,1 0,45.8336L 0 3.819446ZM 0 11.45834L 50 11.4583334M 12.5 0L 12.5 49.652778",Extract:"M0,35 L30,0 L60,35 Z",ManualOperation:"M46.4,28.8 L14.8,28.8 L0,0 L60,0 Z",Merge:"M60,0 L30,35 L0,0 Z",OffPageReference:"M60,33.3 L30.1,39 L0,33.3 L0,0 L60,0 Z",SequentialAccessStorage:"M 60 30 C 60 13.4 46.6 0 30 0 S 0 13.4 0 30 s 13.4 30 30 30 h 28.6 v -6.5 h -9.9C 55.5 48 60 39.5 60 30 Z",Annotation:"M49.9984,50.0029 L-0.00271199,50.0029 L-0.00271199,0.00286865 L49.9984,0.00286865",Annotation2:"M49.9977,50.0029 L25.416,50.0029 L25.416,0.00286865 L49.9977,0.00286865 M25.4166,25.0029 L-0.00227869,25.0029",Data:"M 10 0 L 40 0 L 30 40 L 0 40 Z",Card:"M275,60 L400,60 L400,110 L260,110 L260,75 Z",Delay:"M0,0 L12.029,0 C14.212999,0 16,1.7869979 16,3.9709952 C16,6.1549926 14.212999,7.9409904 12.029,7.9409904 L0,7.9409904 z",Preparation:"M 1048.17 572 C 1051.06 568.86 1055.17 567.05 1059.5 567 L 1094.51 567 C 1098.84 567.05 1102.95 568.86 1105.84 572 L 1126.43 595 C 1127.01 596.28 1127.01 597.72 1126.43 599 L 1105.84 622 C 1102.95 625.14 1098.84 626.95 1094.51 627 L 1059.5 627 C 1055.17 626.95 1051.06 625.14 1048.17 622 L 1027.58 599 C 1027 597.72 1027 596.28 1027.58 595 L 1048.17 572 Z",Display:"M47.8809,19.2914 L32.7968,-0.00594145 L11.3902,-0.00594145 C7.93166,-0.00594145 0.00124586,11.187 0.00124586,24.9968C0.00124586,38.8032 7.93166,49.9962 11.3902,49.9962 L32.7968,49.99 L47.615,31.038 C47.615,31.0388 52.798,24.9968 47.880,19.2914 z",ManualInput:"M 912 732 L 1006.85 707 C 1008.2 707 1009.5 707.53 1010.46 708.46 C 1011.41 709.4 1011.95 710.67 1011.95 712 L 1011.95 762C 1012 764.41 1010.28 766.52 1007.87 767 L 917.1 767 C 915.75 767 914.45 766.47 913.49 765.54 C 912.54 764.6 912 763.33 912 762 L 912 732 Z",LoopLimit:"M 8 9 L 27 9 L 33 15 L 33 26 C 33 27 33 27 32 27 L 4 27 C 3 27 2 27 2 26 L 2 15 L 8 9 Z",StoredData:"M 5.55 0L 50 0A 1.5,30 0 0,1 50,0A 5.555,25 0 0,0 50,50A 1.5,30 0 0,1 50,50L 5.555 50A 5.55,25 0 0,1 5.555,0Z"};function d3(n,t,e){var i;i="Straight"!==n.type&&n.sourceWrapper?n.sourceWrapper.corners.center:function Sre(n){var t;if(n.sourcePortWrapper){var e=n.sourcePortWrapper;t={x:e.offsetX,y:e.offsetY}}else t=n.sourceID&&n.sourceWrapper&&n.targetWrapper?Nh(n,0,n.sourceWrapper.corners.center,n.targetWrapper.corners.center,!1):n.sourcePoint;return t}(n);var r=function bre(n,t,e,i,r){var b,M,s=n.sourceWrapper,o=n.targetWrapper,a=n.sourcePortWrapper,l=n.targetPortWrapper,d=[],f=Ga(n),y={corners:undefined,point:t,direction:undefined,margin:{left:5,right:5,bottom:5,top:5}},S={corners:undefined,point:e,direction:undefined,margin:{left:5,right:5,bottom:5,top:5}};if(void 0!==s&&void 0!==o&&(b=En(s),M=En(o),y.corners=s.corners,S.corners=o.corners),void 0!==a&&(y.direction="Left"===a.connectionDirection||"Top"===a.connectionDirection||"Bottom"===a.connectionDirection||"Right"===a.connectionDirection?a.connectionDirection:zo({x:a.offsetX,y:a.offsetY},b,s.bounds)),void 0!==l&&(S.direction="Left"===l.connectionDirection||"Right"===l.connectionDirection||"Bottom"===l.connectionDirection||"Top"===l.connectionDirection?l.connectionDirection:zo({x:l.offsetX,y:l.offsetY},M,o.bounds)),"Bezier"===n.type&&!n.isBezierEditing&&n.segments.length>0)for(var D=n.segments.length-1;D>=0;)n.segments[parseInt(D.toString(),10)].isInternalSegment&&n.segments.pop(),D--;if(void 0!==s&&void 0!==o)return(void 0===y.direction||void 0===S.direction)&&(i?function Ire(n,t,e){"LeftToRight"===e?(n.direction=n.direction?n.direction:"Right",t.direction=t.direction?t.direction:"Left"):"RightToLeft"===e?(n.direction=n.direction?n.direction:"Left",t.direction=t.direction?t.direction:"Right"):"TopToBottom"===e?(n.direction=n.direction?n.direction:"Bottom",t.direction=t.direction?t.direction:"Top"):"BottomToTop"===e&&(n.direction=n.direction?n.direction:"Top",t.direction=t.direction?t.direction:"Bottom")}(y,S,i):y.corners.top>S.corners.bottom&&Math.abs(y.corners.top-S.corners.bottom)>f?(y.direction=y.direction?y.direction:"Top",S.direction=S.direction?S.direction:"Bottom"):y.corners.bottomf?(y.direction=y.direction?y.direction:"Bottom",S.direction=S.direction?S.direction:"Top"):y.corners.rightf||y.corners.right+f=y.corners.left-f&&y.corners.left>S.corners.left?(y.direction=y.direction?y.direction:"Right",S.direction=S.direction?S.direction:"Left"):y.corners.left>S.corners.right&&Math.abs(y.corners.left-S.corners.right)>y.margin.left+y.margin.right||S.corners.right+f=S.corners.left-f&&y.corners.left0&&n.segments[0].direction&&(y.direction=n.segments[0].direction),y.point=Tc(b,y.direction),d=Tc(b,ls(y.direction)),y.point=Nh(n,0,y.point,d,!1)):y.point=o.corners.center;if(void 0!==h){switch(S.point={x:h.offsetX,y:h.offsetY},S.direction){case"Bottom":case"Top":S.point.y=S.point.y;break;case"Left":case"Right":S.point.x=S.point.x}n.targetPadding&&!w&&(S.point=EI(n,y,S,!0))}else"Orthogonal"===n.type||"Bezier"===n.type?(S.point=Tc(M,S.direction),d=Tc(M,ls(S.direction)),S.point=Nh(n,0,S.point,d,!0)):S.point=a.corners.center;if("Orthogonal"!==n.type){var C=void 0,D=void 0;if("Bezier"===n.type){if(n.bezierSettings.allowSegmentsReset||0===n.segments.length||!z.isEmptyPoint(n.segments[n.segments.length-1].point))return c=b3(n,y,S,void 0,s),Nx(n,y,S);Fv(n)}else Fv(n);if(void 0===n.sourcePortWrapper){y.point=y.corners.center,n.segments&&n.segments.length>0&&(C=z.isEmptyPoint((D=n.segments[0]).point)?void 0:D);var A=void 0!==C?C.point:S.point;if("Bezier"===n.type&&n.segments.length>0&&n.segments[0].vector1.angle&&n.segments[0].vector1.distance){var x=Math.max(y.corners.width,y.corners.height);A=z.transform(y.point,n.segments[0].vector1.angle,x/2)}y.point=w?n.sourceWrapper.bounds.center:Nh(n,0,y.point,A,!1)}if(void 0===n.targetPortWrapper){S.point=S.corners.center,n.segments&&n.segments.length>1&&(C=z.isEmptyPoint((D=n.segments[n.segments.length-2]).point)?void 0:D);var R=C?C.point:y.point;"Bezier"===n.type&&n.segments.length>0&&n.segments[n.segments.length-1].vector2.angle&&n.segments[n.segments.length-1].vector2.distance&&(x=Math.max(y.corners.width,y.corners.height),R=z.transform(S.point,n.segments[0].vector2.angle,x/2)),S.point=w?n.targetWrapper.bounds.center:Nh(n,0,R,S.point,!0)}c=Nx(n,y,S)}else"Orthogonal"===n.type&&n.segments&&n.segments.length>0&&null!==n.segments[0].direction?c=function Nre(n,t,e,i,r,s,o){var a,h,c,d;Fv(n);for(var u=0;u0&&n.segments[u-1].direction===h.direction?u=y3(n,u,t):h.direction?t.point=u3(t,n.segments[parseInt(u.toString(),10)]):(p=n.segments[u-1])&&p.points&&(t.point=p.points[p.points.length-1]),u===n.segments.length-1)if(S3(n,t),v3(a=void 0===r?Lre(n,t,e):f3(n,t,e),n),h.points=[],a.length>=2)for(c=0;c2&&n.segments.length>2){var f={x:a[parseInt(c.toString(),10)].x,y:t.point.y};h.points=[],h.points.push(f),h.points.push(a[parseInt(c.toString(),10)]);var p=n.segments[u-1];n.segments.length<4&&p.points.pop(),p.points=p.points.concat(h.points)}else h.points.push(a[parseInt(c.toString(),10)]);else h.points.push(a[parseInt(c.toString(),10)]);else d=u;if(void 0!==d&&!n.selectedSegmentIndex&&(d===n.segments.length-1&&(n.segments[d-1].direction=null,n.segments[d-1].length=null),n.segments.splice(d,1)),i&&0===u){var g=g3(n,i,s);g&&(t.point=g)}}return I3(n,[])}(n,y,S,l,h,o):(n.segments[0]||(C=new bi(n,"segments",{type:"Orthogonal"},!0),n.segments.push(C)),n.segments[0].points=c=b3(n,y,S,void 0,s));return c}(n,y.direction,S.direction,y.point,S.point,r);if(Fv(n),(n.sourceWrapper||n.targetWrapper)&&function Dre(n,t,e){var i=n.sourcePortWrapper,r=n.targetPortWrapper,s=n.sourceWrapper,o=t.point,a={left:0,right:0,top:0,bottom:0},l={x:0,y:0},c="Top";if(s?(o=e.point,a=t.margin):(s=n.targetWrapper,a=e.margin),"Orthogonal"===n.type)if(n.segments&&n.segments.length>0&&n.sourceWrapper&&n.segments[0].direction)t.direction=n.segments[0].direction,l=Nh(n,0,l=Tc(s.corners,t.direction),Tc(s.corners,ls(t.direction)),!1);else{var u={corners:null,direction:null,point:null,margin:null};_v(s,{corners:null,direction:null,point:o,margin:a},u,n),l=u.point,c=u.direction}else{var p=void 0;n.segments&&n.segments.length>1&&(p=s===n.sourceWrapper?n.segments[0].point:n.segments[n.segments.length-2].point),l=Nh(n,0,s.bounds.center,n.segments&&n.segments.length>1?p:o,s===n.targetWrapper)}s===n.sourceWrapper?(t.direction=t.direction||c,t.point=l,n.sourcePortWrapper&&(t.point={x:i.offsetX,y:i.offsetY},n.sourcePadding&&(t.point=EI(n,t,e,!1)))):(e.direction=e.direction||c,e.point=l,n.targetPortWrapper&&(e.point={x:r.offsetX,y:r.offsetY},n.targetPadding&&(e.point=EI(n,t,e,!0))))}(n,y,S),"Straight"===n.type||"Bezier"===n.type)d=Nx(n,y,S);else if("Orthogonal"===n.type&&n.segments&&n.segments.length>0&&null!==n.segments[0].length&&null!==n.segments[0].direction)d=function Ere(n,t,e,i,r,s,o){var a,l,c,u,h=[];if(Fv(n),n.segments.length>0){for(var p=0;p0&&n.segments[p-1].direction===f.direction)p=y3(n,p,t);else{var g=n.segments[p-1];t.point=f.direction?u3(t,f):g.points[g.points.length-1]}if(p===n.segments.length-1&&(o||r?n.targetWrapper&&void 0===n.targetPortWrapper?(S3(n,t),l=wre(n,t,e)):l=f3(n,t,e):l=Mre(n,t,e),l))if(v3(l,n),f.points=[],l.length>=2)for(a=0;at.corners.top&&e.point.ye.point.x?"Left":"Right"):e.point.x>t.corners.left&&e.point.xe.point.y?"Top":"Bottom")),n.sourcePortWrapper&&s===ls(r)?(("Left"===s||"Right"===s)&&t.point.y>=t.corners.top&&t.point.y<=t.corners.center.y&&e.point.y>=t.corners.top&&e.point.y<=t.corners.center.y?(t.direction="Top",a=t.point.y-t.corners.top+20):("Left"===s||"Right"===s)&&t.point.y>t.corners.center.y&&t.point.y<=t.corners.bottom&&e.point.y>t.corners.center.y&&e.point.y<=t.corners.bottom?(t.direction="Bottom",a=t.corners.bottom-t.point.y+20):("Top"===s||"Bottom"===s)&&t.point.x>=t.corners.left&&t.point.x<=t.corners.center.x&&e.point.x>=t.corners.left&&e.point.x<=t.corners.center.x?(t.direction="Left",a=t.point.x-t.corners.left+20):("Top"===s||"Bottom"===s)&&t.point.x<=t.corners.right&&t.point.x>t.corners.center.x&&e.point.x<=t.corners.right&&e.point.xt.point.y&&t.point.y>=e.corners.top?(i="Top",r=t.point.y-e.corners.top+20):e.corners.center.y===t.point.y&&"Top"===n.segments[n.segments.length-2].direction||e.corners.center.ye.point.y?t.point.y-t.corners.top+20:t.corners.bottom-t.point.y+20):(i="Top",r=e.corners.height/2+20):e.corners.center.x!==t.point.x||e.corners.topt.point.x&&t.point.x>=e.corners.left?(i="Left",r=t.point.x-e.corners.left+20):e.corners.center.x===t.point.x&&"Left"===n.segments[n.segments.length-2].direction||e.corners.center.x<=t.point.x&&t.point.x<=e.corners.right?(i="Right",r=e.corners.right-t.point.x+20):void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&t.corners.left<=t.point.x&&t.point.x<=t.corners.right&&(i=t.direction,r=t.point.x>e.point.x?t.point.x-t.corners.left+20:t.corners.right-t.point.x+20):(i="Left",r=e.corners.width/2+20);var a=t.point;t.point=Bn(t.point,"Left"===i||"Top"===i?-r:r,"Left"===i||"Right"===i?0:90),t.direction=z.direction(t.point,e.point),void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&(t.corners.center.x===e.corners.center.x||t.corners.center.y===e.corners.center.y)&&(t.direction=e.direction);var l=Ys(n,t,e);return l.splice(0,0,a),l}function f3(n,t,e){var i,r;e.corners=n.targetWrapper.corners,void 0!==n.sourcePortWrapper&&(r=zo({x:n.sourcePortWrapper.offsetX,y:n.sourcePortWrapper.offsetY},En(n.sourceWrapper),n.sourceWrapper.bounds));var a=function Cre(n,t,e,i){var r=!1;switch(e.direction){case"Left":void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&"Right"===i&&t.point.x>e.point.x&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom||("Bottom"===i&&t.point.y>e.point.y||"Top"===i&&t.point.y=t.corners.left&&t.point.x<=t.corners.right?(t.direction="Right"===i?t.point.y>e.point.y?"Top":"Bottom":t.point.xe.point.x&&(t.point.y>e.point.y||t.point.yt.point.y&&e.corners.bottome.point.y||t.point.x>e.point.x&&t.point.y<=e.point.y&&e.corners.top=t.point.y?t.direction="Top":t.point.xe.point.x&&t.point.y>e.point.y&&e.corners.bottomt.point.y?t.direction="Bottom":t.point.y===e.point.y&&t.point.xe.point.y||"Top"===i&&t.point.ye.point.x&&t.point.x>=t.corners.left&&t.point.x<=t.corners.right?(t.direction=t.point.x>e.point.x?"Left":"Right",r=!0):void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&"Left"===i&&t.point.x=t.corners.top&&t.point.y<=t.corners.bottom?(t.direction=t.point.y>e.point.y?"Top":"Bottom",r=!0):t.point.x=t.point.y&&t.point.y===e.point.y||t.point.y>e.point.y&&t.point.x>e.point.x?t.direction="Top":t.point.ye.point.x?t.direction="Bottom":t.point.xe.point.y||t.point.ye.point.x&&(t.direction="Left");break;case"Top":void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&"Bottom"===i&&t.point.y>e.point.y&&t.point.x>=t.corners.left&&t.point.x<=t.corners.right||("Right"===i&&t.point.x>e.point.x||"Left"===i&&e.point.y>t.point.y&&e.point.x>t.point.x)&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom?(t.direction="Bottom"===i?t.point.x>e.point.x?"Left":"Right":t.point.ye.point.y&&t.point.x>e.corners.left&&t.point.x=e.point.y?t.direction="Top":t.point.ye.point.x?t.direction="Left":t.point.yt.point.x)&&t.point.y>e.point.y&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom||"Top"===i&&t.point.y=t.corners.left&&t.point.x<=t.corners.right)?(t.direction="Right"===i||"Left"===i?t.point.y>e.point.y?"Top":"Bottom":t.point.x>e.point.x?"Left":"Right",r=!0):t.point.ye.corners.left&&e.corners.right>t.point.x?t.point.ye.corners.left&&e.corners.center.x>=t.point.x?t.direction="Left":t.point.ye.point.y&&t.point.x>e.point.x?t.direction="Left":t.point.y>e.point.y&&t.point.xe.point.x||e.point.x>t.point.x)&&(t.direction="Bottom")}return r}(n,t,e,r);return!n.selectedSegmentIndex&&void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&e.direction===ls(r)&&(("Left"===e.direction&&t.point.x>e.point.x||"Right"===e.direction&&t.point.x=t.corners.top&&t.point.y<=t.corners.bottom||"Bottom"===e.direction&&t.point.y=t.corners.left&&t.point.x<=t.corners.right)?i=p3(n,t,e):n.selectedSegmentIndex||t.direction!==e.direction?!n.selectedSegmentIndex&&("Left"===e.direction&&t.point.x>e.point.x||"Right"===e.direction&&t.point.x=t.point.y||"Top"===e.direction&&t.point.y>e.point.y||"Bottom"===e.direction&&t.point.y=t.point.x?i=n.selectedSegmentIndex?Nl(t,e):p3(n,t,e):!n.selectedSegmentIndex&&void 0!==n.sourceWrapper&&void 0!==n.targetWrapper&&void 0!==n.targetPortWrapper&&("Left"===t.direction||"Right"===t.direction)&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom&&("Top"===e.direction||"Bottom"===e.direction)&&e.corners.center.x===t.corners.center.x?(t.direction="Top"===e.direction?"Bottom":"Top",i=Ys(n,t,e,"Top"===e.direction?t.corners.bottom-t.point.y+20:t.point.y-t.corners.top+20)):!n.selectedSegmentIndex&&void 0!==n.sourceWrapper&&void 0!==n.targetWrapper&&void 0!==n.targetPortWrapper&&("Top"===t.direction||"Bottom"===t.direction)&&t.point.x>=t.corners.left&&t.point.x<=t.corners.right&&("Left"===e.direction||"Right"===e.direction)&&e.corners.center.y===t.corners.center.y?(t.direction="Left"===e.direction?"Right":"Left",i=Ys(n,t,e,"Left"===e.direction?t.corners.right-t.point.x+20:t.point.x-t.corners.left+20)):i=a?Ys(n,t,e,"Left"===t.direction||"Right"===t.direction?"Left"===t.direction?t.point.x-t.corners.left+20:t.corners.right-t.point.x+20:"Top"===t.direction?t.point.y-t.corners.top+20:t.corners.bottom-t.point.y+20):Nl(t,e):i=Ys(n,t,e),i}function g3(n,t,e){var r,i={x:t.offsetX,y:t.offsetY},s=En(e),o=zo(i,s,e.bounds),a=n.segments[0];return a.direction!==o&&(function Ore(n,t,e,i,r,s){var a,h,o=13,l=[];l.push(i),i.y===r.y&&("Left"===t&&r.xi.x)||i.x===r.x&&("Top"===t&&r.yi.y)||("Top"===t||"Bottom"===t?"Top"===t&&r.yi.y-o||"Bottom"===t&&r.y>i.y&&r.yo&&("Top"===t&&r.yi.y)?l.push({x:i.x,y:r.y}):(a=r.xi.x-o||"right"===t&&r.x>i.x&&r.xo&&("Left"===t&&r.xi.x)?l.push({x:r.x,y:i.y}):(l.push({x:a="Left"===t?e.left-o:e.right+o,y:i.y}),l.push({x:a,y:r.y})),s&&(l.push(n.points[0]),l.reverse()),n.points=l)}(a,o,s,a.points[0],a.points[a.points.length-1],!1),r=a.points[a.points.length-1],a.direction=z.direction(a.points[a.points.length-2],a.points[a.points.length-1])),r}function v3(n,t,e){var s,i=t.segments[t.segments.length-2],r=i.points[i.points.length-1];(("Top"===i.direction||"Bottom"===i.direction)&&r.x===n[1].x||("Left"===i.direction||"Right"===i.direction)&&r.y===n[1].y)&&(i.points[i.points.length-1]=n[1],s=z.direction(i.points[0],i.points[i.points.length-1]),void 0!==t.sourceWrapper&&void 0===t.sourcePortWrapper&&s===ls(i.direction)&&("Left"===i.direction||"Right"===i.direction?i.points[0].x="Right"===i.direction?i.points[0].x-t.sourceWrapper.corners.width:i.points[0].x+t.sourceWrapper.corners.width:i.points[0].y="Bottom"===i.direction?i.points[0].y-t.sourceWrapper.corners.height:i.points[0].y+t.sourceWrapper.corners.height),i.direction=s,i.length=z.distancePoints(i.points[0],i.points[i.points.length-1]),n.splice(0,1))}function EI(n,t,e,i){var o=i?n.targetPadding:n.sourcePadding,a=i?n.targetPortWrapper:n.sourcePortWrapper,l=new Ne(a.bounds.x-o,a.bounds.y-o,a.actualSize.width+2*o,a.actualSize.height+2*o),h=[l.topLeft,l.topRight,l.bottomRight,l.bottomLeft];h[h.length]=h[0];var d=i?e.point:t.point;return kx({x1:t.point.x,y1:t.point.y,x2:e.point.x,y2:e.point.y},h,0,d)||d}function m3(n,t){var e=[],i=mF(0,n.corners,t);i.push(i[0]);for(var r=0;r0){var r=void 0,s=[],o=t.point;for(r=0;r1&&z.equals(a.points[0],a.points[1])&&n.segments.splice(r,1),a)for(var l=0;l0||0===r)&&i.push(a.points[parseInt(l.toString(),10)])}}return i}function Ox(n,t,e){return"Top"===n||"Bottom"===n?e.x>t.x?"Right":"Left":e.y>t.y?"Bottom":"Top"}function Fv(n){if("Straight"===n.type||"Bezier"===n.type){if(0===n.segments.length||n.segments.length>0&&!z.isEmptyPoint(n.segments[n.segments.length-1].point))if("Bezier"===n.type){var t=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0},!0);n.segments.push(t)}else t=new Pl(n,"segments",{type:"Straight"},!0),n.segments.push(t)}else{if(n.segments.length>0)for(var e=!1,i=0;i=t.corners.left&&e.point.x<=t.corners.right&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom)t.direction=e.point.y>t.point.y?"Bottom":"Top",i=Ys(n,t,e,"Top"===t.direction?t.point.y-t.corners.top+20:t.corners.bottom-t.point.y+20);else if(n.sourcePortWrapper&&r===ls(o)){var h;("Left"===r||"Right"===r)&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom?(t.direction=e.point.y>t.point.y?"Bottom":"Top",h=t.corners.height/2+20):("Top"===r||"Bottom"===r)&&t.point.x>=t.corners.left&&t.point.x<=t.corners.right&&(t.direction=e.point.x>t.point.x?"Right":"Left",h=t.corners.width/2+20),t.direction&&h?i=Ys(n,t,e,h,!0):(t.direction=o,i=Nl(t,e))}else if(!n.sourcePortWrapper||r!==e.direction||"Top"!==r&&"Bottom"!==r||t.corners.center.x!==e.corners.center.x)if(t.direction===e.direction)if(("Left"===t.direction||"Right"===t.direction)&&e.point.y>t.corners.top-20&&e.point.yt.corners.left-20&&e.point.xt.point.y?"Bottom":"Top",i=Ys(n,t,e,"Bottom"===t.direction?t.corners.bottom-t.point.y+20:t.point.y-t.corners.top+20);else t.direction=o,i=Ys(n,t,e,"Top"===o||"Bottom"===o?n.sourceWrapper.height/2+20:n.sourceWrapper.width/2+20),t.point=i[1],"Left"===o||"Right"===o?(e.direction=o,e.point="Left"===o?e.corners.middleLeft:e.corners.middleRight):_v(n.targetWrapper,t,e,n),i=Ys(n,t,e);return i}function S3(n,t){if(void 0!==n.targetWrapper&&void 0===n.targetPortWrapper&&En(n.targetWrapper).containsPoint(t.point,1)){var i=n.targetWrapper,r=n.segments[n.segments.length-2],s=r.points[r.points.length-1],o=ls(r.direction);"Bottom"===o?s.yi.corners.top-1&&(r.points[r.points.length-1].y=i.corners.top-20,r.length=z.distancePoints(r.points[0],r.points[r.points.length-1])):"Left"===o?s.x>i.corners.left-1&&(r.points[r.points.length-1].x=i.corners.left-20,r.length=z.distancePoints(r.points[0],r.points[r.points.length-1])):"Right"===o&&s.x0||0===e)&&t.push(i.points[parseInt(r.toString(),10)]);return t}function _v(n,t,e,i){var r,s={x:0,y:0},o=DI(n,n.corners,n.bounds),a=t.margin,l=t.point;if(o.bottomCenter.y+a.bottoml.y)r="Top",s=o.topCenter;else if(o.middleLeft.x-a.left>l.x)r="Left",s=o.middleLeft;else if(o.middleRight.x+a.rightc&&(p=c,r="Right",s=o.middleRight),p>d&&(p=d,r="Bottom",s=o.bottomCenter),p>u&&(r="Left",s=o.middleLeft)}e.point=s,e.direction=r;var f=Tc(o,ls(e.direction));e.point=Nh(i,0,e.point,f,n===i.targetWrapper)}function b3(n,t,e,i,r){var s,o,a;if(s=function Qre(n,t){var e=!1;switch(n){case"Left":switch(t){case"Right":case"Bottom":e=!0}break;case"Top":switch(t){case"Left":case"Right":case"Bottom":e=!0}break;case"Bottom":"Right"===t&&(e=!0)}return e}(t.direction,e.direction),s&&x3(t,e),"Right"===t.direction&&"Left"===e.direction)a=function kre(n,t,e,i){var o=Math.round(Math.abs(t.point.y-e.point.y)),a={x:Math.max(t.point.x,t.corners.right),y:t.point.y},l={x:Math.min(e.point.x,e.corners.left),y:e.point.y},h=Ga(n);if(i){var c=l;l=a,a=c}return t.corners.bottom+he.corners.bottom+h||("Bezier"!==n.type||e.corners.left-t.corners.right<=2*h&&e.corners.left-t.corners.right>=5)&&(h=0),t.margin={left:h,right:h,top:h,bottom:h},e.margin={left:h,right:h,top:h,bottom:h},0===o&&(t.corners.right=e.corners.right?void 0!==i&&(i.offsetYe.corners.bottom+e.margin.bottom)||void 0===i&&t.corners.middleRight.ye.corners.bottom+e.margin.bottom&&t.corners.top>e.corners.bottom||void 0===i&&t.corners.middleRight.y>e.corners.bottom||void 0!==i&&i.offsetYe.corners.top||void 0===i&&t.corners.middleRight.y>e.corners.bottom?Ae.Three:t.corners.rightr.offsetY+e.margin.right||void 0===r&&t.corners.top>e.corners.middleRight.y||void 0!==r&&(void 0!==i&&i.offsetXr.offsetX||void 0===r&&t.corners.left>e.corners.topCenter.x?Ae.Four:Ae.Two:void 0!==s&&Math.abs(t.corners.right-e.corners.left)<=5&&Math.abs(s.offsetY-e.corners.top)<=5||void 0!==r&&t.corners.right=25&&t.corners.middleRight.y+t.margin.righte.corners.bottom+e.margin.bottom||void 0===o&&t.corners.middleRight.y>e.corners.bottom+e.margin.bottom?t.corners.top>e.corners.bottom?void 0!==a&&t.corners.right+t.margin.righta.offsetX||void 0===a&&t.corners.left>e.corners.bottomCenter.x?Ae.Four:Ae.Two:void 0!==o&&Math.abs(t.corners.right-e.corners.left)<=25&&Math.abs(o.offsetY-e.corners.bottom)<=25?Ae.Two:Ae.Four}(n,t,e,s);else if("Bottom"===t.direction&&"Top"===e.direction)a=function Hre(n,t,e){var r=t.point.x-e.point.x,s=Ga(n);return t.corners.right+se.corners.right+s||("Bezier"!==n.type||e.corners.top-t.corners.bottom<=2*s&&e.corners.top-t.corners.bottom>=5)&&(s=0),t.margin={left:s,right:s,top:s,bottom:s},e.margin={left:s,right:s,top:s,bottom:s},0===r&&t.corners.bottome.corners.right+e.margin.right||void 0===i&&t.corners.bottomCenter.x>e.corners.right+e.margin.right?Ae.Three:t.corners.bottomr.offsetX||void 0===r&&t.corners.left>e.corners.left||void 0!==r&&t.corners.right+t.margin.righte.corners.bottom?Ae.Five:0===s||0===o?Ae.One:Ae.Three}(n,t,e)}else"Bottom"===t.direction&&"Left"===e.direction?a=function Bre(n,t,e,i){var r=n.sourcePortWrapper,s=n.targetPortWrapper,o=Ga(n);if(e.margin={left:o,right:o,top:o,bottom:o},t.margin={top:o,bottom:o,left:o,right:o},i){var l=r;r=s,s=l}return void 0!==r&&r.offsetXs.offsetY||void 0===s&&t.corners.top>e.corners.middleLeft.y?Ae.Four:Ae.Two:void 0!==s&&Math.abs(t.corners.right-e.corners.left)<=25&&Math.abs(s.offsetY-t.corners.bottom)<=25?Ae.Two:Ae.Four}(n,t,e,s):"Left"===t.direction&&"Left"===e.direction?a=function Ure(n,t,e){var i=n.sourcePortWrapper,r=n.targetPortWrapper,s=Ga(n);t.margin={left:s,right:s,top:s,bottom:s},e.margin={left:s,right:s,top:s,bottom:s};var o=Math.round(Math.abs(t.point.x-e.point.x)),a=Math.round(Math.abs(t.point.y-e.point.y));return t.corners.leftr.offsetY||void 0===r&&t.corners.top-t.margin.top>e.corners.middleLeft.y?Ae.Three:t.corners.righte.corners.bottom+e.margin.bottom||void 0===i&&t.corners.middleLeft.y>e.corners.bottom+e.margin.bottom?Ae.Three:t.corners.left>e.corners.right?Ae.Five:0===o||0===a?Ae.One:Ae.Three}(n,t,e):"Left"===t.direction&&"Top"===e.direction?a=function _re(n,t,e,i){var s=n.sourcePortWrapper,o=Ga(n);e.margin={left:o,right:o,top:o,bottom:o},t.margin={top:o,bottom:o,left:o,right:o};var a=n.targetPortWrapper,l={x:Math.min(t.point.x,t.corners.left),y:t.point.y},h={x:e.point.x,y:Math.min(e.point.y,e.corners.top)};if(i){var c=s;s=a,a=c;var d=l;l=h,h=d}return void 0!==s&&s.offsetYa.offsetX||void 0===a&&t.corners.left-t.margin.left>e.corners.topCenter.x?Ae.Two:Ae.Four:void 0!==a&&t.corners.rightr.offsetX||void 0===r&&t.corners.left>e.corners.left||void 0!==r&&t.corners.right+t.margin.righte.corners.right+e.margin.right||void 0===i&&t.corners.left>e.corners.right||void 0!==i&&i.offsetXe.corners.bottom?Ae.Five:0===s||0===o?Ae.One:Ae.Three}(n,t,e));return s&&x3(t,e),o=function Vre(n,t,e,i,r,s){var l,d,h=n.sourceWrapper.corners,c=n.targetWrapper.corners,u=20,p={corners:e.corners,point:e.point,direction:e.direction,margin:e.margin},f={corners:i.corners,point:i.point,direction:i.direction,margin:i.margin};if(!(p.direction===f.direction&&t!==Ae.Five||p.direction!==ls(f.direction)&&t!==Ae.Three))switch(p.direction){case"Left":h.middleLeft.x>c.middleRight.x&&(d=(h.middleLeft.x-c.middleRight.x)/2,u=s?d:Math.min(u,d));break;case"Right":h.middleRight.xc.bottomCenter.y&&(d=(h.topCenter.y-c.bottomCenter.y)/2,u=s?d:Math.min(u,d));break;case"Bottom":h.bottomCenter.yp&&hp)&&o>c&&o<=d&&e>=20&&(s=n.point.x-t.corners.left+s),i&&n.direction===t.direction&&n.corners.left>t.corners.left&&n.corners.left-t.corners.right>=20&&(s=(n.corners.left-t.corners.right)/2),f=Bn(n.point,s,180);break;case"Top":(o>c&&oc)&&h>p&&h<=u&&e>=20&&(s=n.point.y-t.corners.top+s),i&&n.direction===t.direction&&n.corners.top>t.corners.top&&n.corners.top-t.corners.bottom>=20&&(s=(n.corners.top-t.corners.bottom)/2),f=Bn(n.point,s,270);break;case"Right":(h>p&&hp)&&a=c&&e>=20&&(s=t.corners.right-n.point.x+s),i&&n.direction===t.direction&&n.corners.right=20&&(s=(t.corners.left-n.corners.right)/2),f=Bn(n.point,s,0);break;case"Bottom":(o>c&&oc)&&l=p&&e>=20&&(s=t.corners.bottom-n.point.y+s),i&&n.direction===t.direction&&n.corners.bottom=20&&(s=(t.corners.top-n.corners.bottom)/2),f=Bn(n.point,s,90)}r=[n.point,f];var g=void 0;if("Top"===n.direction||"Bottom"===n.direction){var v=n.direction;n.direction=f.x>t.point.x?"Left":"Right",n.point=f,r=xI(n,t,v,r,g=i?.5*Math.abs(f.x-t.point.x):g,i)}else v=n.direction,n.direction=f.y>t.point.y?"Top":"Bottom",n.point=f,r=xI(n,t,v,r,g=i?.5*Math.abs(f.y-t.point.y):g,i);return r}(p,f,u,g)),l}(n,a,t,e,i,r),"Bezier"===n.type&&function Yre(n,t,e){if("Bezier"===n.type)if(0===n.segments.length){var i=e[0],r=e[e.length-1];if(t===Ae.One){var s=Math.min(20,.5*z.findLength(i,r)),o={angle:Gt(i,r),distance:s},a={angle:Gt(r,i),distance:s},l=z.direction(i,r),c=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,orientation:"Left"===l||"Right"===l?"Horizontal":"Vertical"},!0);n.segments.push(c)}else if(t===Ae.Two)o={angle:Gt(i,d=e[1]),distance:.5*z.findLength(i,d)},a={angle:Gt(r,d),distance:.5*z.findLength(r,d)},l=z.direction(i,d),c=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,orientation:"Left"===l||"Right"===l?"Horizontal":"Vertical"},!0),n.segments.push(c);else if(t===Ae.Three){var d={x:.5*((u=e[1]).x+(p=e[e.length-2]).x),y:.5*(u.y+p.y)},f=(o={angle:Gt(i,u),distance:.5*z.findLength(i,u)},a={angle:Gt(d,u),distance:.5*z.findLength(d,u)},z.direction(i,u)),v=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,point:d,orientation:"Left"===f||"Right"===f?"Horizontal":"Vertical"},!0);n.segments.push(v);var y={angle:Gt(d,p),distance:.5*z.findLength(d,p)},S={angle:Gt(r,p),distance:.5*z.findLength(r,p)},b=z.direction(d,p),w=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:y,vector2:S,orientation:"Left"===b||"Right"===b?"Horizontal":"Vertical"},!0);n.segments.push(w)}else if(t===Ae.Four){var D={x:.5*((u=e[1]).x+(p=e[2]).x),y:.5*(u.y+p.y)},A={x:.5*(p.x+(C=e[3]).x),y:.5*(p.y+C.y)};o={angle:Gt(i,u),distance:.5*z.findLength(i,u)},a={angle:Gt(D,u),distance:.5*z.findLength(D,u)},f=z.direction(i,u),v=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,point:D,orientation:"Left"===f||"Right"===f?"Horizontal":"Vertical"},!0),n.segments.push(v),y={angle:Gt(D,p),distance:.5*z.findLength(D,p)},S={angle:Gt(A,p),distance:.5*z.findLength(A,p)},b=z.direction(D,p),w=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:y,vector2:S,point:A,orientation:"Left"===b||"Right"===b?"Horizontal":"Vertical"},!0),n.segments.push(w);var x={angle:Gt(A,C),distance:.5*z.findLength(A,C)},R={angle:Gt(r,C),distance:.5*z.findLength(r,C)},L=z.direction(A,C),N=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:x,vector2:R,orientation:"Left"===L||"Right"===L?"Horizontal":"Vertical"},!0);n.segments.push(N)}else if(t===Ae.Five){var u,p,C,T=e[4],P=(D={x:.5*((u=e[1]).x+(p=e[2]).x),y:.5*(u.y+p.y)},A={x:.5*(p.x+(C=e[3]).x),y:.5*(p.y+C.y)},{x:.5*(C.x+T.x),y:.5*(C.y+T.y)});o={angle:Gt(i,u),distance:.5*z.findLength(i,u)},a={angle:Gt(D,u),distance:.5*z.findLength(D,u)},f=z.direction(i,u),v=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,point:D,orientation:"Left"===f||"Right"===f?"Horizontal":"Vertical"},!0),n.segments.push(v),y={angle:Gt(D,p),distance:.5*z.findLength(D,p)},S={angle:Gt(A,p),distance:.5*z.findLength(A,p)},b=z.direction(D,p),w=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:y,vector2:S,point:A,orientation:"Left"===b||"Right"===b?"Horizontal":"Vertical"},!0),n.segments.push(w),x={angle:Gt(A,C),distance:.5*z.findLength(A,C)},R={angle:Gt(P,C),distance:.5*z.findLength(P,C)},L=z.direction(A,C),N=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:x,vector2:R,point:P,orientation:"Left"===L||"Right"===L?"Horizontal":"Vertical"},!0),n.segments.push(N);var _={angle:Gt(P,T),distance:.5*z.findLength(P,T)},B={angle:Gt(r,T),distance:.5*z.findLength(r,T)},j=z.direction(P,T),oe=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:_,vector2:B,orientation:"Left"===j||"Right"===j?"Horizontal":"Vertical"},!0);n.segments.push(oe)}else c=new ps(n,"segments",{type:"Bezier"},!0),n.segments.push(c)}else for(var ue=0;ue=13?13:n.connectorSpacing<=1?1:n.connectorSpacing}function Gt(n,t){var i=z.findLength({x:t.x,y:n.y},t),r=z.findLength(t,n),s=Math.asin(i/r);return s=180*s/Math.PI,n.xt.y&&(s=360-s):s=n.y0)for(var l=1;lc)&&(s=c,a=h),s>=0&&s<=1)break}}return a}function w3(n,t){var c,d,u,p,f,g,S,b,M,w,D,e=n.x1,i=n.y1,r=n.x2,s=n.y2,o=t.x1,a=t.y1,l=t.x2,h=t.y2;if(w=(c=s-i)*l+(u=e-r)*h+(f=r*i-e*s),0!==(M=c*o+u*a+f)&&0!==w&&C3(M,w)||(b=(d=h-a)*r+(p=o-l)*s+(g=l*a-o*h),0!==(S=d*e+p*i+g)&&0!==b&&C3(S,b)))return null;var A=c*p-d*u;return 0===A?null:(A<0?-A/2:A/2,0,{x:(D=u*g-p*f)<0?(D-0)/A:(D+0)/A,y:(D=d*f-c*g)<0?(D-0)/A:(D+0)/A})}function C3(n,t){return n*t>=0}function E3(n,t,e){switch(t.direction){case"Left":t.point.x>n.left&&(e=t.point.x-n.left>e?t.point.x-n.left+e:e);break;case"Right":t.point.xe?n.right-t.point.x+e:e);break;case"Top":t.point.y>n.top&&(e=t.point.y-n.top>e?t.point.y-n.top+e:e);break;case"Bottom":t.point.ye?n.bottom-t.point.y+e:e)}return e}function Nl(n,t){var e;switch(n.direction){case"Left":case"Right":var i={x:t.point.x,y:n.point.y};e=z.equals(n.point,i)||z.equals(t.point,i)?[n.point,t.point]:[n.point,i,t.point];break;case"Top":case"Bottom":var r={x:n.point.x,y:t.point.y};e=z.equals(n.point,r)||z.equals(t.point,r)?[n.point,t.point]:[n.point,r,t.point]}return e}function Ys(n,t,e,i,r,s){void 0===s&&(s=!1),i||(i=20),s&&t.direction!==e.direction&&(i="Left"===t.direction||"Right"===t.direction?Math.floor(.5*Math.abs(t.point.x-e.point.x)):Math.floor(.5*Math.abs(t.point.y-e.point.y)));var l,h,u,o=n.sourcePortWrapper,c=e.point.x-t.point.x,d=e.point.y-t.point.y;if(!r&&(Math.abs(c)<.001||Math.abs(d)<.001)&&void 0===e.direction)return[t.point,e.point];if(void 0===n.targetWrapper&&Math.abs(c)<=31&&Math.abs(d)<=31){if("Left"===t.direction||"Right"===t.direction?Math.abs(d)<12&&(t.direction=t.point.y>e.point.y?"Top":"Bottom"):Math.abs(c)<12&&(t.direction=t.point.x>e.point.x?"Left":"Right"),Math.abs(c)>12||Math.abs(d)>12)return Nl(t,e);i+=5}return"Left"===t.direction||"Right"===t.direction?("Right"===t.direction?(void 0!==e.direction&&"Right"===e.direction&&(i=Math.max(t.point.x,e.point.x)-t.point.x+i),t.point.x>e.point.x&&void 0===o&&(i=-i)):(void 0!==e.direction&&"Left"===e.direction&&(i=t.point.x-Math.min(t.point.x,e.point.x)+i),(t.point.x>e.point.x||void 0!==o||"Left"===t.direction)&&(i=-i)),u=e.point.y-t.point.y,l=Bn(t.point,i,0),0!=(u=e.point.y-l.y)&&(h=Bn(l,e.point.y-l.y,90))):("Top"===t.direction||"Bottom"===t.direction)&&("Bottom"===t.direction?void 0!==e.direction&&"Bottom"===e.direction&&(i=Math.max(t.point.y,e.point.y)-t.point.y+i):(void 0!==e.direction&&"Top"===e.direction&&(i=t.point.y-Math.min(t.point.y,e.point.y)+i),(t.point.y>e.point.y||void 0!==o||"Top"===t.direction)&&(i=-i)),u=e.point.x-t.point.x,l=Bn(t.point,i,90),0!=(u=e.point.x-l.x)&&(h=Bn(l,e.point.x-l.x,0))),0===u?[t.point,e.point]:[t.point,l,h,e.point]}function xI(n,t,e,i,r,s){var o;switch(void 0===r&&(r=20),void 0===s&&(s=!1),void 0===e?(n.margin={left:2,right:2,top:2,bottom:2},t.margin={left:0,right:5,top:0,bottom:5},s&&(n.margin={left:10,right:10,top:10,bottom:10},t.margin={left:10,right:10,top:10,bottom:10},"Left"===n.direction?(r=zx(n,t,e,r),n.corners.left-t.corners.right>=5&&(r=Math.abs(n.point.x-n.corners.left)+.5*Math.floor(n.corners.left-t.corners.right))):"Right"===n.direction?(r=Rx(n,t,r,e),t.corners.left-n.corners.right>=5&&(r=Math.abs(n.point.x-n.corners.right)+.5*Math.floor(t.corners.left-n.corners.right))):"Top"===n.direction?(r=Px(n,t,e,r),n.corners.top-t.corners.bottom>=5&&(r=Math.abs(n.point.y-n.corners.top)+.5*Math.floor(n.corners.top-t.corners.bottom))):"Bottom"===n.direction&&(r=Hx(n,t,r,e),t.corners.top-n.corners.bottom>=5&&(r=Math.abs(n.point.y-n.corners.bottom)+.5*Math.floor(t.corners.top-n.corners.bottom))))):("Bottom"===n.direction?s?t.corners.top-n.corners.bottom<20&&(r=t.corners.bottom-n.point.y+25):t.corners.top>n.corners.bottom&&t.corners.top-n.corners.bottom<20&&(r=(t.corners.top-n.corners.bottom)/2):"Top"===n.direction?s?n.corners.top-t.corners.bottom<20&&(r=n.point.y-t.corners.top+25):t.corners.bottomn.corners.right&&t.corners.left-n.corners.right<20&&(r=(t.corners.left-n.corners.right)/2):"Left"===n.direction&&(s?n.corners.left-t.corners.right<20&&(r=n.point.x-t.corners.left+25):t.corners.rightt.point.y||"Top"===t.direction&&n.point.yt.point.x||"Left"===t.direction&&n.point.xh||e.corners.top-e.margin.top<=i.point.y&&e.corners.bottom+e.margin.bottom>=i.point.y))if(!s||"Top"!==e.direction&&"Bottom"!==e.direction)c=Math.min(Math.abs(i.corners.left-e.corners.right)/2,20),h=e.corners.right-n.x+c;else{var c=Math.abs(i.corners.left-e.corners.right)/2;h=e.corners.right-n.x+c}else h="Top"===e.direction&&n.y>i.point.y||"Bottom"===e.direction&&n.y=e.corners.left-e.margin.left&&n.x<=e.corners.right+e.margin.right?Math.min(i.corners.left,e.corners.left)-n.x-20:i.corners.left-n.x-20;break;case"Right":if(e.corners.left-e.margin.left>i.corners.right+i.margin.right&&(e.corners.left-e.margin.right-i.corners.right>h||e.corners.top-e.margin.top<=i.point.y&&e.corners.bottom+e.margin.bottom>=i.point.y))if(!s||"Top"!==e.direction&&"Bottom"!==e.direction)c=Math.min(Math.abs(e.corners.left-i.corners.right)/2,20),h=e.corners.left-n.x-c;else{c=Math.abs(e.corners.left-i.corners.right)/2;h=e.corners.left-n.x-c}else h="Top"===e.direction&&n.y>i.point.y||"Bottom"===e.direction&&n.y=e.corners.left-e.margin.left&&n.x<=e.corners.right+e.margin.right?Math.max(i.corners.right,e.corners.right)-n.x+20:i.corners.right-n.x+20}o=Bn(n,h,0),a=Bn(o,i.point.y-n.y,90),l=i.point}else if("vertical"===t){switch(i.direction){case"Top":e.corners.bottom+e.margin.bottomh||e.corners.left-e.margin.left<=i.point.x&&e.corners.right+e.margin.right>=i.point.x)?!s||"Right"!==e.direction&&"Left"!==e.direction?(c=Math.min(Math.abs(i.corners.top-e.corners.bottom)/2,20),h=e.corners.bottom-n.y+c):(c=Math.abs(i.corners.top-e.corners.bottom)/2,h=e.corners.bottom-n.y+c):h="Left"===e.direction&&n.x>i.point.x||"Right"===e.direction&&n.x=e.corners.top-e.margin.top&&n.y<=e.corners.bottom+e.margin.bottom?Math.min(i.corners.top,e.corners.top)-n.y-20:i.corners.top-n.y-20;break;case"Bottom":e.corners.top-e.margin.top>i.corners.bottom+i.margin.bottom&&(e.corners.top-e.margin.top-i.corners.bottom>h||e.corners.left-e.margin.left<=i.point.x&&e.corners.right+e.margin.right>=i.point.x)?!s||"Right"!==e.direction&&"Left"!==e.direction?(c=Math.min(Math.abs(e.corners.top-i.corners.bottom)/2,20),h=e.corners.top-n.y-c):(c=Math.abs(e.corners.top-i.corners.bottom)/2,h=e.corners.top-n.y-c):h="Left"===e.direction&&n.x>i.point.x||"Right"===e.direction&&n.x=e.corners.top-e.margin.top&&n.y<=e.corners.bottom+e.margin.bottom?Math.max(i.corners.bottom,e.corners.bottom)-n.y+20:i.corners.bottom-n.y+20}o=Bn(n,h,90),a=Bn(o,i.point.x-n.x,0),l=i.point}r.push(o),r.push(a),r.push(l)}function Px(n,t,e,i){return n.corners.top-n.margin.top>t.corners.top+t.margin.top&&n.corners.top-n.margin.top<=t.corners.bottom+t.margin.bottom?(("Right"===t.direction&&n.point.xt.point.x)&&(i+=n.corners.top-t.corners.top),i+=n.point.y-n.corners.top):i+=void 0!==e&&"Left"!==e&&"Right"===t.direction&&n.point.xt.corners.left-t.margin.left&&n.corners.left-n.margin.left<=t.corners.right+t.margin.right?(("Bottom"===t.direction&&n.point.yt.point.y)&&(i+=n.corners.left-t.corners.left),i+=n.point.x-n.corners.left):i+=void 0!==e&&"Top"!==e&&"Bottom"===t.direction&&n.point.y=t.corners.left-t.margin.left?(("Bottom"===t.direction&&n.point.yt.point.y)&&(e+=t.corners.right-n.corners.right),e+=n.corners.right-n.point.x):e+=void 0!==i&&"Top"!==i&&"Bottom"===t.direction&&n.point.y=t.corners.top-t.margin.top?(("Right"===t.direction&&n.point.xt.point.x)&&(e+=t.corners.bottom-n.corners.bottom),e+=n.corners.bottom-n.point.y):e+=void 0!==i&&"Left"!==i&&"Right"===t.direction&&n.point.xf&&d=u&&d=p&&d<=f?"Left":"Right"}function ls(n){switch(n){case"Top":return"Bottom";case"Bottom":return"Top";case"Left":return"Right";case"Right":return"Left"}return"auto"}var A3=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Ac=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},TI=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return A3(t,n),Ac([I()],t.prototype,"width",void 0),Ac([I()],t.prototype,"height",void 0),t}(Ee),Gre=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return A3(t,n),Ac([I()],t.prototype,"width",void 0),Ac([I()],t.prototype,"height",void 0),Ac([I()],t.prototype,"fit",void 0),Ac([I()],t.prototype,"description",void 0),Ac([I()],t.prototype,"template",void 0),Ac([I()],t.prototype,"tooltip",void 0),t}(Ee),Xre=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Ol=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},L3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Xre(t,n),Ol([I("")],t.prototype,"id",void 0),Ol([I(Number.MIN_VALUE)],t.prototype,"zIndex",void 0),Ol([re({},$n)],t.prototype,"margin",void 0),Ol([I(!0)],t.prototype,"visible",void 0),Ol([re({},Ed)],t.prototype,"tooltip",void 0),Ol([I(!1)],t.prototype,"excludeFromLayout",void 0),Ol([I()],t.prototype,"addInfo",void 0),Ol([I("None")],t.prototype,"flip",void 0),Ol([I("All")],t.prototype,"flipMode",void 0),Ol([re({},Gre)],t.prototype,"symbolInfo",void 0),t}(Ee),qre=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Jn=function(n){function t(e,i,r,s){var o=n.call(this)||this;return o.data="",o.nodeId="",o.annotationId="",o.diagramId="",o.diagramId=i,o.nodeId=e,o.annotationId=r,o.templateFn=GF(s),o}return qre(t,n),t.prototype.getNodeTemplate=function(){return this.templateFn},Object.defineProperty(t.prototype,"content",{get:function(){return this.data},set:function(e){this.data=e,this.canReset||(this.canReset=!0,this.isTemplate||(this.template=Bh(this,!0)),this.canReset=!1,this.isDirt=!0)},enumerable:!0,configurable:!0}),t}(as),Bx=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),hs=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},N3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Bx(t,n),hs([I("")],t.prototype,"id",void 0),hs([I("transparent")],t.prototype,"fill",void 0),hs([I("black")],t.prototype,"iconStrokeColor",void 0),hs([I(0)],t.prototype,"iconStrokeWidth",void 0),hs([I(!0)],t.prototype,"visibility",void 0),hs([I(10)],t.prototype,"width",void 0),hs([I(10)],t.prototype,"height",void 0),hs([I("transparent")],t.prototype,"handleStrokeColor",void 0),hs([I(1)],t.prototype,"handleStrokeWidth",void 0),hs([I("")],t.prototype,"pathData",void 0),hs([I(0)],t.prototype,"cornerRadius",void 0),hs([re({left:0,right:0,top:0,bottom:0},$n)],t.prototype,"padding",void 0),hs([re({},Ed)],t.prototype,"tooltip",void 0),t}(Ee),O3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Bx(t,n),hs([re({x:0,y:0},z)],t.prototype,"offset",void 0),hs([re({},$n)],t.prototype,"margin",void 0),t}(N3),AI=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Bx(t,n),hs([I(.5)],t.prototype,"offset",void 0),hs([I("Center")],t.prototype,"alignment",void 0),hs([re({x:0,y:0},z)],t.prototype,"displacement",void 0),t}(N3);function Dd(n){return n?n instanceof Zn||n instanceof Nr?n.constraints&Lr.Select:n instanceof de?n.constraints&qe.Select:n.constraints&ie.Select:1}function to(n){return n?n instanceof Zn||n instanceof Nr?n.constraints&Lr.Drag:n instanceof de?n.constraints&qe.Drag:n instanceof si?1:n.constraints&ie.Drag:1}function $re(n,t){return n instanceof de?n.constraints&qe.PointerEvents:n.constraints&ie.PointerEvents}function LI(n){return n instanceof de?n.constraints&qe.Delete:n.constraints&ie.Delete}function NI(n){return n.constraints&qe.DragSourceEnd}function OI(n){return n.constraints&qe.DragTargetEnd}function kI(n){return n.constraints&qe.DragSegmentThumb}function PI(n){return n instanceof Zn||n instanceof Nr?n.constraints&Lr.Rotate:n.constraints&ie.Rotate}function zI(n){return n.constraints&ie.Shadow}function da(n){return n instanceof te&&n.constraints&ie.InConnect?n.constraints&ie.InConnect:0}function Oh(n){return n&&n.constraints&&!(n.constraints&ri.None)&&n.constraints&ri.InConnect?n.constraints&ri.InConnect:0}function kh(n){return n instanceof te&&n.constraints&ie.OutConnect?n.constraints&ie.OutConnect:0}function xd(n){return n&&n.constraints&&!(n.constraints&ri.None)&&n.constraints&ri.OutConnect?n.constraints&ri.OutConnect:0}function kl(n,t){var e=0;return n instanceof Zn||n instanceof Nr?e=n.constraints&Lr.Resize:n&&("SouthEast"===t?e=n.constraints&ie.ResizeSouthEast:"East"===t?e=n.constraints&ie.ResizeEast:"NorthEast"===t?e=n.constraints&ie.ResizeNorthEast:"South"===t?e=n.constraints&ie.ResizeSouth:"North"===t?e=n.constraints&ie.ResizeNorth:"SouthWest"===t?e=n.constraints&ie.ResizeSouthWest:"West"===t?e=n.constraints&ie.ResizeWest:"NorthWest"===t&&(e=n.constraints&ie.ResizeNorthWest)),e}function RI(n){return n instanceof de?n.constraints&qe.AllowDrop:n.constraints&ie.AllowDrop}function Ds(n){return n.constraints&rt.Virtualization}function Uv(n){return n.tool&Ci.SingleSelect}function jv(n){return n.tool&Ci.MultipleSelect}function Lc(n){return n.tool&Ci.ZoomPan}function HI(n){return n.tool&Ci.ContinuousDraw}function k3(n){return n.tool&Ci.DrawOnce}function BI(n){return n.tool&Ci.SingleSelect||n.tool&Ci.MultipleSelect}function Vv(n){return n.constraints&rt.UserInteraction}function P3(n){return n.constraints&rt.ZoomTextEdit}function Wv(n){return function ine(n){return n.constraints&rt.ApiUpdate}(n)||n.diagramActions&ee.ToolAction}function Fx(n,t){return n.constraints&ri.Draw}function _x(n,t){return n.constraints&ri.Drag}function FI(n){return!(n&Qa.DrawSelectorBorder)}function z3(n){return!!(n&Qa.PreventRenderSelector)}var Ux=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Yv=function(n){function t(){var e=null!==n&&n.apply(this,arguments)||this;return e.childTable=[],e.cellStyle={},e.desiredRowHeight=[],e.desiredCellWidth=[],e}return Ux(t,n),t.prototype.rowDefinitions=function(){return this.rowDefns},t.prototype.columnDefinitions=function(){return this.colDefns},t.prototype.addObject=function(e,i,r,s,o){if(this.rows.length>=i){var a=this.rows[parseInt(i.toString(),10)];if(a.cells.length>r){o=o||1,s=s||1;var l=a.cells[parseInt(r.toString(),10)];l.columnSpan=Math.max(o,l.columnSpan),l.rowSpan=Math.max(s,l.rowSpan);var h=new ane;(h=e).rowId=i,h.columnId=r,h.columnSpan=o,this.childTable[h.id]=h,this.addObjectToCell(h,l)}}},t.prototype.addObjectToCell=function(e,i){i.children||(i.children=[]),e.style.strokeColor="black",e.style.strokeWidth=1,i.children.push(e)},t.prototype.updateProperties=function(e,i,r,s){this.offsetX=e,this.offsetY=i,this.width=r,this.height=s},t.prototype.setDefinitions=function(e,i){this.rowDefns=e,this.colDefns=i,this.children=[],this.rows=this.rows||[];for(var r=0;r0){for(var h=0;hi&&this.updateRowHeight(e,l,!1)}},t.prototype.setTextRefresh=function(e){if(e.children&&e.children.length)for(var i=e.children,r=0;ri&&this.updateColumnWidth(e,a,!1)}},t.prototype.calculateCellWidth=function(e){for(var i,r,s,o=0;os.bounds.width&&(0===s.children.length||void 0===s.children[0].maxWidth)?s.outerBounds.width:s.bounds.width,i=i?is.bounds.height?s.outerBounds.height:s.bounds.height,i=i?i0?e.children[0]:void 0;if(a&&1===e.columnSpan){o="Width"===i?a.bounds.right:a.bounds.bottom,s||(s="Width"===i?a.bounds.width:a.bounds.height);for(var l=0;lo){var d=c-o+("Width"===i?a.bounds.width:a.bounds.height);s&&(s=s0?this.rowDefns.splice(e,0,i):this.rowDefns.push(i);var s=new R3;s.cells=[],(new Td).width=this.width,this.addCellInRow(this.colDefns,i,s),e>this.rows.length-1?this.rows.push(s):this.rows.splice(e,0,s),r&&(this.measure(new me(this.width,this.height)),this.arrange(this.desiredSize))},t.prototype.addColumn=function(e,i,r){var s,o,a,l,h=this.rows;this.colDefns.length>0?this.colDefns.splice(e,0,i):this.colDefns.push(i),void 0!==this.width&&(this.width+=i.width);for(var c=0;cs.cells.length-1?s.cells.push(l):s.cells.splice(e,0,l),this.children.push(l);r&&(this.measure(new me(this.width,this.height)),this.arrange(this.desiredSize))},t.prototype.removeRow=function(e){var i,r,o=this.rows[parseInt(e.toString(),10)];this.height-=this.rowDefns[parseInt(e.toString(),10)].height;for(var a=0;a0){var r=0,s=0;i=new me(0,0),this.calculateSize();for(var o=0,a=this.rows;o0){for(var o=this.offsetX-e.width*this.pivot.x,a=this.offsetY-e.height*this.pivot.y,l=o,h=0,c=this.rows;h1&&this.children.splice(this.children.indexOf(f)+1,f.columnSpan-1),f.rowSpan>1)for(y=s,S=0;y+f.rowSpan-10){for(var c=0;c0?1:0,v=0;v0||a.outEdges.length>0))for(p=a.inEdges.concat(a.outEdges),s=0;s0)for(o=0;o1)for(a=1;a0))if(h=n.wrapper.children[0],"Horizontal"===e.orientation)for(o=e.header&&e.hasHeader?h.rows[1]:h.rows[0],r=0;r0){var e=void 0;t.lineRoutingModule&&t.constraints&rt.LineRouting&&t.lineRoutingModule.renderVirtualRegion(t,!0);for(var i=0;i0?o+1:o)].height=t.wrapper.height;else if(t.isPhase)for(l[t.rowIndex-o].offset=t.wrapper.height,f=0;f0?1:0)].width=t.wrapper.width}function UI(n,t){var i=n.shape,r=i.header&&i.hasHeader?1:0;return"Horizontal"===i.orientation?t.rowIndex-(r+=i.phases.length>0?1:0):t.columnIndex-(i.phaseSize&&i.phases.length>0?1:0)}function jI(n){var t=0,e=n.shape;return"Horizontal"===e.orientation&&(t=e.header&&e.hasHeader?1:0),e.phases.length>0&&e.phaseSize&&(t+=1),t}function VI(n,t,e,i){var r=n.shape;if(r.phases.length>0){var s=t.nameTable[r.phases[parseInt(i.toString(),10)].header.id];s&&s.maxWidth0?u+1:u);var w=Nc(n,o),C=void 0!==i?i:l.lanes.length;if(u+=C,r={element:M,cause:n.diagramActions,diagramAction:n.getDiagramAction(n.diagramActions),state:"Changing",type:"Addition",cancel:!1,laneIndex:C},n.triggerEvent(Ce.collectionChange,r),!r.cancel){if(c){var D=new Qv;D.height=e.height,o.addRow(u,D,!1),s.height=void 0!==s.height?s.height+e.height:s.height,s.wrapper.height=o.height=s.height}else{var A=new Td;A.width=e.width,o.addColumn(C+1,A,!1),s.width&&(s.width+=e.width,s.wrapper.width=o.width=s.width),n.diagramActions&ee.UndoRedo||(o.rows[0].cells[0].columnSpan+=1)}n.diagramActions&ee.UndoRedo||(M.id=""===M.id?Qe():M.id),void 0!==i?l.lanes.splice(i,0,M):l.lanes.push(M),r={element:M,cause:n.diagramActions,diagramAction:n.getDiagramAction(n.diagramActions),state:"Changed",type:"Addition",cancel:!1,laneIndex:C},n.triggerEvent(Ce.collectionChange,r),B3(o,n,s,u,C,c),h="Horizontal"===l.orientation?n.nameTable[o.rows[parseInt(u.toString(),10)].cells[0].children[0].id]:l.header&&l.hasHeader?n.nameTable[o.rows[1].cells[parseInt(u.toString(),10)].children[0].id]:n.nameTable[o.rows[0].cells[parseInt(u.toString(),10)].children[0].id],n.diagramActions&ee.UndoRedo||(d={type:"LaneCollectionChanged",changeType:"Insert",undoObject:$(M),redoObject:$(h),category:"Internal"},n.addHistoryEntry(d)),qp(n,s,"Horizontal"===l.orientation?u:l.header&&l.hasHeader?1:0),Xp(s),Oc(n,s);var R=!1;if((p=e.children)&&p.length>0)for(f=0;f0){var o=t.children[0],a=n.nameTable[o.id];(function vne(n,t,e){return n.left-(e.left||0)<=t.x&&n.right+(e.right||0)>=t.x&&n.top-(e.top||0)<=t.y&&n.bottom+(e.bottom||0)>=t.y})(o.bounds,e,r)&&(n.addChild(a,i),s=!0)}return s}function mne(n,t,e){if("SwimLane"===t.shape.type){var i=void 0,r=void 0,s=void 0,a=void 0,l=void 0,h=void 0,c=t.wrapper.bounds.x,d=t.wrapper.bounds.y,u=t.shape,p=u.padding,f=u.phases,g=void 0,v=t.wrapper.children[0],y="Horizontal"===u.orientation;if(i=u.header&&u.hasHeader?0:-1,u.phases.length>0&&(i+=1),e.offset>(y?u.lanes[0].header.width:u.lanes[0].header.height)){for(h=0;he.offset){if(g=h>0?e.offset-(h>0?f[h-1]:s).offset:e.offset,y){var b=v.columnDefinitions()[parseInt(h.toString(),10)];b.width-=g,(a=n.nameTable[u.phases[parseInt(h.toString(),10)].header.id]).maxWidth=a.wrapper.maxWidth=b.width,v.updateColumnWidth(h,b.width,!1);var M=new Td;M.width=g,l=h,v.addColumn(h,M,!1);break}var w=v.rowDefinitions()[h+i];w.height-=g,a=n.nameTable[u.phases[parseInt(h.toString(),10)].header.id],v.updateRowHeight(h+i,w.height,!1);var C=new Qv;C.height=g,l=h,v.addRow(h+i,C,!1);break}if(n.diagramActions&ee.UndoRedo&&void 0===l&&(D=n.historyManager.currentEntry.next).isLastPhase&&function yne(n,t,e,i,r,s){var a=t.shape.phases[n-2],l=e.previousPhase.offset;if(r){var h=i.columnDefinitions()[n-1],c=new Td;n>1?(c.width=h.width-(l-a.offset),h.width=l-a.offset):(c.width=h.width-l,h.width=l),i.updateColumnWidth(n-1,h.width,!1),i.addColumn(n,c,!1)}else{h=i.rowDefinitions()[parseInt(n.toString(),10)];var d=new Qv;n>1?(d.height=e.undoObject.offset-l,h.height=l-a.offset):(d.height=h.height-l,h.height=l),i.updateRowHeight(n,h.height,!1),i.addRow(1+n,d,!1)}}(l=f.length,t,D,v,y),l>=0){var A=new db(t.shape,"phases",e,!0);if(n.diagramActions&ee.UndoRedo||(A.id+=Qe()),u.phases.splice(l,0,A),jx(v,n,t,i,y,l),y){if(r=n.nameTable[v.rows[parseInt(i.toString(),10)].cells[parseInt(l.toString(),10)].children[0].id],0===l&&u.header&&u.hasHeader){v.rows[0].cells[0].children=v.rows[0].cells[1].children,v.rows[0].cells[1].children=[];for(var x=v.rows[0],R=0;Rl+1){var O=n.nameTable[v.rows[parseInt(i.toString(),10)].cells[l+1].children[0].id];v.updateColumnWidth(l+1,L[l+1].width,!0,p),O.maxWidth=O.wrapper.maxWidth=L[l+1].width}t.width=t.wrapper.width=t.wrapper.children[0].width=v.width}else{r=n.nameTable[v.rows[i+l].cells[0].children[0].id];var N=v.rowDefinitions(),T=N[i+l].height;(function Ine(n,t,e,i,r){for(var o,a,l=e.rows[parseInt(i.toString(),10)],h=e.rows[i+1],c=e.rows[i-1],d=1;di+l+1&&v.updateRowHeight(i+l+1,T=N[i+l+1].height,!0,p),t.height=t.wrapper.height=t.wrapper.children[0].height=v.actualSize.height}if(Xp(t),t.width=t.wrapper.actualSize.width,Oc(n,t),n.drag(t,c-t.wrapper.bounds.x,d-t.wrapper.bounds.y),_I(t,n),n.commandHandler.select(r),!(n.diagramActions&ee.UndoRedo)){var D={type:"PhaseCollectionChanged",changeType:"Insert",undoObject:$(A),redoObject:$(r),category:"Internal"};n.addHistoryEntry(D)}n.updateDiagramObject(t)}}}}function V3(n,t,e,i,r,s,o){var a,l,f,h=t.shape,c="Horizontal"===h.orientation,d=t.wrapper.children[0],g=c?s:o;e?(a=c?e.bounds.x+e.bounds.width:e.bounds.x,l=c?e.bounds.y:e.bounds.y+e.bounds.height):(a=d.bounds.x,l=r.bounds.y);var v=new Ne(a,l,i.desiredCellWidth,i.desiredCellHeight),S=Gv(n,0,t,{id:t.id+(c?h.lanes[g-2]:h.lanes[g-1]).id+Qe()[0],rowIndex:s,columnIndex:o,width:i.minWidth,height:i.minHeight,style:(c?h.lanes[g-2]:h.lanes[g-1]).style,constraints:ie.Default|ie.AllowDrop,container:{type:"Canvas",orientation:c?"Horizontal":"Vertical"}},!1,!1,!0);if(S.children[0].isCalculateDesiredSize=!1,d.addObject(S,s,o),r&&r.children&&r.children.length)for(f=0;f1)for(var f=1;fh.margin.left&&(h.margin.left=p)):(h.margin.top-=e.desiredCellHeight,p>h.margin.top&&(h.margin.top=p)))}(n,r,i,v,S,c,e)}function W3(n,t,e){if("SwimLane"===t.shape.type&&("ResizeSouth"===e||"ResizeEast"===e)){var i=t.shape,r=t.wrapper.children[0],s=void 0,o=void 0;"ResizeSouth"===e?"Vertical"===i.orientation?s=r.rows[r.rows.length-1].cells[0]:(o=r.rows.length-1,s=r.rows[parseInt(o.toString(),10)].cells[r.rows[parseInt(o.toString(),10)].cells.length-1]):(o=i.header&&i.hasHeader?1:0,s=r.rows[parseInt(o.toString(),10)].cells[r.rows[parseInt(o.toString(),10)].cells.length-1]),n.commandHandler.select(n.nameTable[s.children[0].id])}}function WI(n,t,e,i,r,s){var o,a,l,c,u,p,f,d=Qe(),g=n.shape,v=g.phases,y=n.offsetX-n.wrapper.actualSize.width/2,S=n.offsetY-n.wrapper.actualSize.height/2;if("Vertical"===g.orientation&&(S+=g.header&&g.hasHeader?g.header.height:0),!s)for(r||(n.id+=d,g&&g.header&&g.hasHeader?g.header.id+=d:g.header=void 0),o=0;v&&o0&&s.columnIndex>0||s.isLane)?(a=function Lne(n,t,e){for(var i=new Ne,r="SwimLane"===n.shape.type?n.wrapper.children[0].rows:n.wrapper.rows,s=e?1:0;s=0;a--)i?i.id===o.children[parseInt(a.toString(),10)].id&&o.children.splice(a,1):(n.removeDependentConnector(o.children[parseInt(a.toString(),10)]),n.diagramActions&ee.UndoRedo||(n.diagramActions=n.diagramActions|ee.UndoRedo,s=!0),n.remove(o.children[parseInt(a.toString(),10)]),o.children.splice(a,1),s&&(n.diagramActions=n.diagramActions&~ee.UndoRedo))}function Mne(n){return n.children[0]}function $v(n,t){t&&(n.nodes.splice(n.nodes.indexOf(t),1),n.removeFromAQuad(t),n.removeObjectsFromLayer(t),delete n.nameTable[t.id],n.removeElements(t))}function Q3(n,t,e,i){var r;if("SwimLane"===e.shape.type){var s=e.shape,o=void 0;if(1===s.lanes.length)n.remove(e);else{var a=e.wrapper.bounds.x,l=e.wrapper.bounds.y,h=void 0,c=void 0,d=void 0,u=void 0,f=e.wrapper.children[0];if(o=i?s.lanes.indexOf(i):UI(e,t),r={element:t,cause:n.diagramActions,diagramAction:n.getDiagramAction(n.diagramActions),state:"Changing",type:"Removal",cancel:!1,laneIndex:o},n.triggerEvent(Ce.collectionChange,r),!r.cancel){var g=s.lanes[parseInt(o.toString(),10)],v=g.children;g.children=[];for(var y=0;y0)for(u=0;u0)for(u=0;u0)for(e=0;e1){c===l.phases.length-1&&(o=!0,a=$(l.phases[c-1]));var u=$(l.phases[parseInt(c.toString(),10)]);if(l.phases.splice(c,1),!(n.diagramActions&ee.UndoRedo)){var p={type:"PhaseCollectionChanged",changeType:"Remove",undoObject:u,previousPhase:a,redoObject:$(t),category:"Internal",isLastPhase:o};n.addHistoryEntry(p)}"Horizontal"===l.orientation?function Cne(n,t,e,i){var r,s,o,a,l,h,c,d,u,p,f,g;for(i=void 0!==i?i:e.columnIndex,c=0;c1&&(s=r.cells[parseInt(i.toString(),10)],l=(o=r.cells.length-1===i?r.cells[i-1]:r.cells[i+1]).children[0],s.children.length>0))if(f=n.nameTable[(a=s.children[0]).id],0===o.children.length&&s.children.length>0)o.children=s.children,o.columnSpan=s.columnSpan-1;else{for(d=0;d0){var M=s.children[0],w=n.nameTable[M.id];if(i=e.x&&a.bounds.y<=e.y&&a.bounds.bottom>=e.y)&&!(t.constraints&ie.AllowMovingOutsideLane)){var l=$(t);n.clearSelection(),$3(n,t),t.parentId="",t.parentObj=n,t.propName="nodes";var h={type:"ChildCollectionChanged",category:"Internal",undoObject:l,redoObject:$(t)};n.addHistoryEntry(h),n.commandHandler.isContainer&&(n.commandHandler.isContainer=!1,n.endGroupAction()),Z3(t,n)}n.protectPropertyChange(o)}}function YI(n,t){var e,i,r;return n.enableServerDataBinding(!1),ce()||(n.selectedObject.helperObject?r=n.selectedObject.helperObject:(n.selectedItems.nodes.length>0||n.selectedItems.connectors.length>0)&&(t instanceof si&&t.nodes.length+t.connectors.length===1?(e=t.nodes.length>0?t.nodes[0]:t.connectors[0],i=n.selectedItems.wrapper.children[0]):(e=t,i=n.selectedItems.wrapper),n.selectedObject.actualObject=e,!n.currentSymbol&&(e.isLane&&Qx(e,n)&&cs(n,e)||!e.isLane&&cs(n,e)||n.constraints&rt.LineRouting&&n.selectedItems.nodes.length>0))&&(r=function Nne(n,t){for(var e,i={},r=0,s=Object.keys(t);r=t.x-e&&n.x<=t.x+e&&n.y>=t.y-e&&n.y<=t.y+e}function Xa(n){return n.selectedItems.nodes.length>0||n.selectedItems.connectors.length>0}function K3(n){return 1===n.selectedItems.connectors.length&&!n.selectedItems.nodes.length}function _r(n,t,e,i){if(void 0===e&&(e=!0),t instanceof si)return!0;if(t instanceof te)for(;t;){if(-1!==n.selectedItems.nodes.indexOf(t)&&void 0===n.selectedItems.annotation)return!0;if(e)break;t=n.nameTable[t.parentId]}else if(t instanceof de){if(-1!==n.selectedItems.connectors.indexOf(t)&&void 0===n.selectedItems.annotation)return!0}else if((t instanceof Zn||t instanceof Nr)&&n.selectedItems.annotation&&n.selectedItems.wrapper.children[0].id===i.id)return!0;return!1}var Gx={None:"default",Rotate:"crosshair",Select:"default",Drag:"move",ResizeWest:"w-resize",ResizeEast:"e-resize",ResizeSouth:"s-resize",ResizeNorth:"n-resize",Draw:"crosshair",PortDraw:"crosshair",ResizeNorthEast:"ne-resize",ResizeNorthWest:"nw-resize",ResizeSouthEast:"se-resize",ResizeSouthWest:"sw-resize",ConnectorSourceEnd:"move",ConnectorTargetEnd:"move",BezierSourceThumb:"move",BezierTargetThumb:"move",OrthoThumb:"move",SegmentEnd:"move",Pan:"grab",Hyperlink:"pointer",PortDrag:"pointer",LabelSelect:"pointer",LabelDrag:"move",LabelRotate:"crosshair",LabelResizeWest:"w-resize",LabelResizeEast:"e-resize",LabelResizeSouth:"s-resize",LabelResizeNorth:"n-resize",LabelResizeNorthEast:"ne-resize",LabelResizeNorthWest:"nw-resize",LabelResizeSouthEast:"se-resize",LabelResizeSouthWest:"sw-resize"},ds=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Ld=function(n,t,e,i){return new(e||(e=Promise))(function(r,s){function o(h){try{l(i.next(h))}catch(c){s(c)}}function a(h){try{l(i.throw(h))}catch(c){s(c)}}function l(h){h.done?r(h.value):new e(function(c){c(h.value)}).then(o,a)}l((i=i.apply(n,t||[])).next())})},Nd=function(n,t){var i,r,s,o,e={label:0,sent:function(){if(1&s[0])throw s[1];return s[1]},trys:[],ops:[]};return o={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function a(h){return function(c){return function l(h){if(i)throw new TypeError("Generator is already executing.");for(;e;)try{if(i=1,r&&(s=2&h[0]?r.return:h[0]?r.throw||((s=r.return)&&s.call(r),0):r.next)&&!(s=s.call(r,h[1])).done)return s;switch(r=0,s&&(h=[2&h[0],s.value]),h[0]){case 0:case 1:s=h;break;case 4:return e.label++,{value:h[1],done:!1};case 5:e.label++,r=h[1],h=[0];continue;case 7:h=e.ops.pop(),e.trys.pop();continue;default:if(!(s=(s=e.trys).length>0&&s[s.length-1])&&(6===h[0]||2===h[0])){e=0;continue}if(3===h[0]&&(!s||h[1]>s[0]&&h[1]-1&&(r=i.fixedUserHandles[parseInt(o.toString(),10)]);this.commandHandler.triggerEvent(Ce.fixedUserHandleClick,{fixedUserHandle:r,element:e.source}),n.prototype.mouseUp.call(this,e)},t}(us),Od=function(n){function t(e,i){var r=n.call(this,e,!0)||this;return r.isConnected=!1,r.endPoint=i,r}return ds(t,n),t.prototype.mouseDown=function(e){return Ld(this,void 0,void 0,function(){var r,s,o,a,l;return Nd(this,function(h){if(this.inAction=!0,this.undoElement=void 0,this instanceof pa||(this.undoElement=$(e.source)),n.prototype.mouseDown.call(this,e),e.source&&e.source.connectors&&(this.oldConnector=$(r=e.source.connectors[0])),"BezierSourceThumb"===this.endPoint||"BezierTargetThumb"===this.endPoint)for(s=0;s0))},t.prototype.endAction=function(){n.prototype.endAction.call(this),this.prevPosition=null,this.endPoint=null},t}(us),ua=function(n){function t(e,i){var r=n.call(this,e,!0)||this;return r.currentTarget=null,r.isStartAction=!1,r.canCancel=!1,r.canTrigger=!1,r.objectType=i,r}return ds(t,n),t.prototype.mouseDown=function(e){if(e.source instanceof te||e.source instanceof de){var i=this.commandHandler.getSelectedObject();this.commandHandler.selectObjects([e.source],e.info&&e.info.ctrlKey,i);var r={nodes:[],connectors:[]};e.source instanceof te?r.nodes.push($(e.source)):r.connectors.push($(e.source)),this.undoElement=$(r)}else this.undoElement=$(e.source);this.undoParentElement=this.commandHandler.getSubProcess(e.source),"Port"===this.objectType&&(this.portId=e.sourceWrapper.id),this.commandHandler.insertBlazorConnector(e.source),n.prototype.mouseDown.call(this,e),this.initialOffset={x:0,y:0}},t.prototype.mouseUp=function(e,i){return Ld(this,void 0,void 0,function(){var s,o,a,l,h,c,d,u,f,g,v,y,S,b,M;return Nd(this,function(w){if(this.checkPropertyValue(),a=!1,h={nodes:[],connectors:[]},"Port"!==this.objectType){if(e.source instanceof te||e.source instanceof de?(e.source instanceof te?h.nodes.push($(e.source)):h.connectors.push($(e.source)),(o=$(h)).offsetX=(c=e.source.wrapper).offsetX,o.offsetY=c.offsetY):o=$(e.source),("helper"===(l=this.commandHandler.renderContainerHelper(e.source)||e.source||this.commandHandler.renderContainerHelper(e.source)).id||"helper"!==l.id)&&((l instanceof si&&(Math.round(l.width)===Math.round(this.undoElement.width)&&Math.round(l.height)===Math.round(this.undoElement.height)||l.selectedObjects&&1===l.selectedObjects.length)||!(l instanceof si))&&(l.offsetX!==this.undoElement.offsetX||l.offsetY!==this.undoElement.offsetY||l.sourcePoint!==this.undoElement.sourcePoint||l.targetPoint!==this.undoElement.targetPoint)||this.isSelectionHasConnector(l))&&(e.source&&(s={offsetX:e.source.wrapper.offsetX,offsetY:e.source.wrapper.offsetY}),g={source:e.source,state:"Completed",oldValue:this.intialValue,newValue:s,target:this.currentTarget,targetPosition:this.currentPosition,allowDrop:(g={source:e.source,state:"Completed",oldValue:this.intialValue,newValue:s,target:this.currentTarget,targetPosition:this.currentPosition,allowDrop:!0,cancel:!1}).allowDrop,cancel:g.cancel},d=!0,"helper"===l.id?this.canTrigger?(this.commandHandler.triggerEvent(Ce.positionChange,g),this.connectorEndPointChangeEvent(g),d=!0):d=!1:(this.commandHandler.triggerEvent(Ce.positionChange,g),this.connectorEndPointChangeEvent(g)),!i&&d&&(this.commandHandler.startGroupAction(),a=!0,M={type:"PositionChanged",redoObject:$(o),undoObject:$(this.undoElement),category:"Internal"},o.nodes[0]&&o.nodes[0].processId&&(u={type:"SizeChanged",category:"Internal",undoObject:this.undoParentElement,redoObject:this.commandHandler.getSubProcess(e.source)},this.commandHandler.addHistoryEntry(u)),this.commandHandler.addHistoryEntry(M))),this.commandHandler.snapPoint(this.prevPosition,this.currentPosition,0,0),this.commandHandler.removeSnap(),this.commandHandler.removeHighlighter(),e.source&&this.currentTarget&&RI(this.currentTarget)&&this.commandHandler.isDroppable(e.source,this.currentTarget)){if(f=!0,this.commandHandler.drop(this.currentElement,this.currentTarget,this.currentPosition),this.currentTarget&&this.currentTarget instanceof de&&!0===this.commandHandler.diagram.enableConnectorSplit)if(this.currentElement&&this.currentElement instanceof te){if(void 0!==this.currentElement.children)for(b=0;b0)for(var s=0;s0)for(var a=0;a0)for(a=0;a0&&e.connectors.length>0)||e.width===this.undoElement.width&&e.height===this.undoElement.height)},t.prototype.mouseMove=function(e){n.prototype.mouseMove.call(this,e);var r,s,i=!1;(r=this.commandHandler.renderContainerHelper(e.source)||e.source)instanceof te||r instanceof de?r instanceof te?r.offsetX===this.undoElement.nodes[0].offsetX&&r.offsetY===this.undoElement.nodes[0].offsetY&&(i=!0):z.equals(r.sourcePoint,this.undoElement.connectors[0].sourcePoint)&&z.equals(r.targetPoint,this.undoElement.connectors[0].targetPoint)&&(i=!0):r.wrapper.offsetX===this.undoElement.wrapper.offsetX&&r.wrapper.offsetY===this.undoElement.wrapper.offsetY&&(i=!0),r&&(s={offsetX:r.wrapper.offsetX,offsetY:r.wrapper.offsetY});var o={source:r,state:"Start",oldValue:s,newValue:s,target:e.target,targetPosition:e.position,allowDrop:!0,cancel:!1};if(o={source:r,state:"Start",oldValue:s,newValue:s,target:e.target,targetPosition:e.position,allowDrop:o.allowDrop,cancel:o.cancel},this.isStartAction||(this.intialValue={offsetX:r.wrapper.offsetX,offsetY:r.wrapper.offsetY}),i&&!ce()&&(this.commandHandler.triggerEvent(Ce.positionChange,o),this.connectorEndPointChangeEvent(o),this.isStartAction=!0),this.currentPosition=e.position,"Port"!==this.objectType){var h=this.initialOffset.x+(this.currentPosition.x-this.prevPosition.x),c=this.initialOffset.y+(this.currentPosition.y-this.prevPosition.y);this.commandHandler.dragOverElement(e,this.currentPosition),this.commandHandler.disConnect(e.source),this.commandHandler.removeSnap();var d,u=void 0,p=this.commandHandler.snapPoint(this.prevPosition,this.currentPosition,h,c);this.initialOffset.x=h-p.x,this.initialOffset.y=c-p.y,r&&(d={offsetX:r.wrapper.offsetX,offsetY:r.wrapper.offsetY},u={offsetX:r.wrapper.offsetX+p.x,offsetY:r.wrapper.offsetY+p.y}),this.currentTarget&&e.target!==this.currentTarget&&this.commandHandler.removeChildFromBPmn(e.source,e.target,this.currentTarget),this.currentTarget=e.target;var f={source:r,state:"Progress",oldValue:d,newValue:u,target:e.target,targetPosition:e.position,allowDrop:!0,cancel:!1};if(this.commandHandler.triggerEvent(Ce.positionChange,f),this.canTrigger=!0,this.connectorEndPointChangeEvent(f,p),!f.cancel&&!this.canCancel){this.blocked=!this.commandHandler.dragSelectedObjects(p.x,p.y);var g=!this.commandHandler.mouseOver(this.currentElement,this.currentTarget,this.currentPosition);this.blocked=this.blocked||g}if(this.commandHandler.removeStackHighlighter(),this.commandHandler.renderStackHighlighter(e),this.currentTarget&&e.source!==this.currentTarget&&this.commandHandler.isDroppable(e.source,this.currentTarget)&&"helper"!==e.source.id){var v=e.source instanceof si?e.source.nodes[0]:e.source;!this.commandHandler.isParentAsContainer(v,!0)&&"SwimLane"!==v.shape.type&&!v.shape.isPhase&&(this.currentTarget.isLane?this.commandHandler.renderStackHighlighter(e,this.currentTarget):this.commandHandler.drawHighlighter(this.currentTarget))}else this.commandHandler.removeHighlighter();if(this.commandHandler.canEnableDefaultTooltip()){var y=this.getTooltipContent(e.source);this.commandHandler.showTooltip(e.source,e.position,ko(function(){return y}),"MoveTool",this.isTooltipVisible),this.isTooltipVisible=!1}}else{var b=Hi(),M=e.source;qi(b,-M.rotateAngle||-M.wrapper.rotateAngle,M.offsetX||M.wrapper.offsetX,M.offsetY||M.wrapper.offsetY);var w=Je(b,{x:this.prevPosition.x,y:this.prevPosition.y}),C=Je(b,{x:e.position.x,y:e.position.y});this.commandHandler.portDrag(e.source,e.sourceWrapper,C.x-w.x,C.y-w.y)}return this.prevPosition=this.currentPosition,!this.blocked},t.prototype.getTooltipContent=function(e){return"X:"+Math.round(e.wrapper.bounds.x)+" Y:"+Math.round(e.wrapper.bounds.y)},t.prototype.mouseLeave=function(e){this.mouseUp(e)},t.prototype.endAction=function(){n.prototype.endAction.call(this),this.currentTarget=null,this.prevPosition=null},t}(us),Xx=function(n){function t(e){var i=n.call(this,e,!0)||this;return i.rotateStart=!1,i}return ds(t,n),t.prototype.mouseDown=function(e){if(this.undoElement=$(e.source),this.undoElement.nodes[0]&&this.undoElement.nodes[0].children)for(var r=this.commandHandler.getAllDescendants(this.undoElement.nodes[0],[]),s=0;s=2){var s=e.startTouches[0],o=e.startTouches[1],a=e.moveTouches[0],l=e.moveTouches[1],h=this.getDistance(a,l)/this.getDistance(s,o);this.commandHandler.zoom(h,0,0,e.position),this.updateTouch(s,a),this.updateTouch(o,l)}}else this.commandHandler.scroll(this.currentPosition.x-this.prevPosition.x,this.currentPosition.y-this.prevPosition.y,this.currentPosition);return this.commandHandler.dataBinding(),!this.blocked},t.prototype.mouseUp=function(e){this.commandHandler.setBlazorDiagramProps(!1),this.checkPropertyValue(),this.commandHandler.updatePanState(!1),n.prototype.mouseUp.call(this,e),this.inAction=!1},t.prototype.endAction=function(){n.prototype.endAction.call(this)},t.prototype.getDistance=function(e,i){var r=i.pageX-e.pageX,s=i.pageY-e.pageY;return Math.sqrt(r*r+s*s)},t.prototype.updateTouch=function(e,i){e.pageX=i.pageX,e.pageY=i.pageY},t}(us),Une=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseUp=function(e){this.checkPropertyValue(),this.commandHandler.initExpand(e),n.prototype.mouseUp.call(this,e)},t}(us),eF=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseUp=function(e){this.checkPropertyValue();var i="_blank",r="",s=window.innerHeight,o=window.innerWidth,a=window.screenTop,l=window.screenLeft;"CurrentTab"===e.sourceWrapper.hyperlink.hyperlinkOpenState?i="_self":"NewWindow"===e.sourceWrapper.hyperlink.hyperlinkOpenState&&(r="height="+s+",width="+o+",top="+a+",left="+l),window.open(e.sourceWrapper.hyperlink.link,i,r).focus(),n.prototype.mouseUp.call(this,e)},t}(us),Ph=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseDown=function(e){if(n.prototype.mouseDown.call(this,e),this.inAction=!0,this.drawingObject){var r=void 0,s=this.drawingObject.shape;this.drawingObject.shape.points.push(r={x:(r=s.points[s.points.length-1]).x,y:r.y})}else this.startPoint={x:this.startPosition.x,y:this.startPosition.y},this.drawingObject=this.commandHandler.drawObject({offsetX:this.currentPosition.x,offsetY:this.currentPosition.y,width:5,height:5,style:{strokeColor:"black",strokeWidth:1},shape:{type:"Basic",shape:"Polygon",points:[{x:this.startPoint.x,y:this.startPoint.y},{x:this.currentPosition.x,y:this.currentPosition.y}]}})},t.prototype.mouseMove=function(e){if(n.prototype.mouseMove.call(this,e),this.inAction){var i=this.drawingObject.shape;if(i.points[i.points.length-1].x=this.currentPosition.x,i.points[i.points.length-1].y=this.currentPosition.y,this.drawingObject.wrapper.children[0].data=Sx(this.drawingObject.shape.points),this.inAction&&!1===z.equals(this.currentPosition,this.prevPosition)){var r=Ne.toBounds(this.drawingObject.shape.points);this.commandHandler.updateNodeDimension(this.drawingObject,r)}}return!0},t.prototype.mouseUp=function(e,i){this.checkPropertyValue(),n.prototype.mouseMove.call(this,e),this.inAction&&(this.inAction=!1,this.commandHandler.addObjectToDiagram(this.drawingObject)),this.endAction()},t.prototype.mouseWheel=function(e){n.prototype.mouseWheel.call(this,e),this.mouseMove(e)},t.prototype.endAction=function(){this.inAction=!1,this.drawingObject=null},t}(us),zh=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseMove=function(e){if(n.prototype.mouseMove.call(this,e),this.inAction){var i=this.drawingObject;i.targetPoint=this.currentPosition,this.commandHandler.updateConnectorPoints(i)}return!0},t.prototype.mouseDown=function(e){if(n.prototype.mouseDown.call(this,e),this.inAction=!0,this.drawingObject){var r=this.drawingObject,s=void 0;(s=new Pl(r,"segments",{type:"Straight"},!0)).point=this.currentPosition,r.segments[r.segments.length-1]=s}else this.drawingObject=this.commandHandler.drawObject({id:"Connector",type:"Straight",sourcePoint:this.currentPosition,targetPoint:this.currentPosition})},t.prototype.mouseWheel=function(e){n.prototype.mouseWheel.call(this,e),this.mouseMove(e)},t.prototype.mouseUp=function(e){if(this.checkPropertyValue(),n.prototype.mouseMove.call(this,e),this.inAction&&this.drawingObject){var i=this.drawingObject;i.segments[i.segments.length-1].point={x:0,y:0},this.commandHandler.addObjectToDiagram(this.drawingObject)}this.endAction()},t.prototype.endAction=function(){this.drawingObject=null,this.inAction=!1},t}(us),jne=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseDown=function(e){this.inAction=!0,this.undoElement=$(e.source),this.annotationId=e.sourceWrapper.id,n.prototype.mouseDown.call(this,e)},t.prototype.mouseMove=function(e){n.prototype.mouseMove.call(this,e);var i=this.currentPosition.x-this.prevPosition.x,r=this.currentPosition.y-this.prevPosition.y,s=e.source;if(s instanceof te){var o=Hi();qi(o,-s.rotateAngle,0,0);var a=Je(o,{x:i,y:r});i=a.x,r=a.y}return this.inAction&&(this.commandHandler.labelDrag(e.source,e.sourceWrapper,i,r),this.commandHandler.updateSelector()),this.prevPosition=this.currentPosition,!this.blocked},t.prototype.mouseUp=function(e){this.checkPropertyValue();var i=e.source;this.inAction=!1;var r={type:"AnnotationPropertyChanged",objectId:this.annotationId,undoObject:$(this.undoElement),category:"Internal",redoObject:$(i)};this.commandHandler.addHistoryEntry(r),n.prototype.mouseUp.call(this,e)},t.prototype.mouseLeave=function(e){this.mouseUp(e)},t}(us),Vne=function(n){function t(e,i){var r=n.call(this,e,!0)||this;return r.corner=i,r}return ds(t,n),t.prototype.mouseDown=function(e){this.inAction=!0;var i=e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0];this.annotationId=e.source.wrapper.children[0].id,this.undoElement=$(i);var r=e.source.wrapper.children[0];this.initialBounds={x:r.offsetX,y:r.offsetY,width:r.actualSize.width,height:r.actualSize.height},n.prototype.mouseDown.call(this,e)},t.prototype.mouseMove=function(e){return n.prototype.mouseMove.call(this,e),this.inAction&&this.resizeObject(e),!this.blocked},t.prototype.mouseUp=function(e){this.checkPropertyValue();var i=e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0];this.inAction=!1;var r={type:"AnnotationPropertyChanged",objectId:this.annotationId,redoObject:$(i),undoObject:$(this.undoElement),category:"Internal"};this.commandHandler.addHistoryEntry(r),n.prototype.mouseUp.call(this,e)},t.prototype.mouseLeave=function(e){this.mouseUp(e)},t.prototype.resizeObject=function(e){var i,s,o,r=e.source.wrapper.children[0],a={x:r.offsetX,y:r.offsetY},l=r.rotateAngle;l=((l+=(i=e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0])instanceof te?i.rotateAngle:0)+360)%360;var h=Hi();qi(h,l,a.x,a.y);var c=this.corner.slice(5),d=this.updateSize(r,this.startPosition,this.currentPosition,c,this.initialBounds,l),u=r.offsetX-r.actualSize.width*r.pivot.x,p=r.offsetY-r.actualSize.height*r.pivot.y,f=this.getPivot(c),g=Je(h,f={x:u+r.actualSize.width*f.x,y:p+r.actualSize.height*f.y});d.x=g.x,d.y=g.y,this.commandHandler.labelResize(i,e.source.annotation,s=(s=d.width)<0?1:s,o=(o=d.height)<0?1:o,d,e.source),this.commandHandler.updateSelector()},t}(us),Wne=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseDown=function(e){this.inAction=!0,this.annotationId=e.source.wrapper.children[0].id,this.undoElement=$(e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0]),n.prototype.mouseDown.call(this,e)},t.prototype.mouseMove=function(e){return n.prototype.mouseMove.call(this,e),e.source&&this.inAction&&(this.commandHandler.labelRotate(e.source.nodes[0]?e.source.nodes[0]:e.source.connectors[0],e.source.annotation,this.currentPosition,e.source),this.commandHandler.updateSelector()),this.prevPosition=this.currentPosition,!this.blocked},t.prototype.mouseUp=function(e){this.checkPropertyValue(),this.inAction=!1;var r={type:"AnnotationPropertyChanged",objectId:this.annotationId,redoObject:$(e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0]),undoObject:$(this.undoElement),category:"Internal"};this.commandHandler.addHistoryEntry(r),n.prototype.mouseUp.call(this,e)},t.prototype.mouseLeave=function(e){this.mouseUp(e)},t}(us),Yne=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseMove=function(e){if(n.prototype.mouseMove.call(this,e),this.inAction){var i=this.drawingObject.shape;if(i.points.push(this.currentPosition),this.drawingObject.wrapper.children[0].data=Ix(this.drawingObject.shape.points),i.data=Ix(i.points),this.inAction&&!1===z.equals(this.currentPosition,this.prevPosition)){var s=Ne.toBounds(this.drawingObject.shape.points);this.commandHandler.updateNodeDimension(this.drawingObject,s)}}return!0},t.prototype.mouseDown=function(e){n.prototype.mouseDown.call(this,e),this.inAction=!0,this.startPoint={x:this.startPosition.x,y:this.startPosition.y},this.drawingObject=this.commandHandler.drawObject({offsetX:this.currentPosition.x,offsetY:this.currentPosition.y,width:5,height:5,style:{strokeColor:"black",strokeWidth:1,fill:"transparent"},shape:{type:"Path",points:[{x:this.startPoint.x,y:this.startPoint.y},{x:this.currentPosition.x,y:this.currentPosition.y}]}})},t.prototype.mouseUp=function(e){if(this.checkPropertyValue(),this.inAction){this.inAction=!1;var s=this.drawingObject.shape,o=s.points;this.commandHandler.addObjectToDiagram(this.drawingObject),this.commandHandler.diagram.remove(this.commandHandler.diagram.nameTable[""+this.drawingObject.id]),o=this.pointReduction(o,10);var h={id:"newConnector"+Qe(),type:"Bezier",sourcePoint:{x:o[0].x,y:o[0].y},targetPoint:{x:o[o.length-1].x,y:o[o.length-1].y},segments:[],bezierSettings:{allowSegmentsReset:!1}};this.drawingObject=this.commandHandler.drawObject(h),this.drawingObject=this.bezierCurveSmoothness(o,.5,this.drawingObject,s),this.commandHandler.updateConnectorPoints(this.drawingObject),this.commandHandler.addObjectToDiagram(this.drawingObject),n.prototype.mouseUp.call(this,e)}},t.prototype.pointReduction=function(e,i){if(null===e||e.length<3)return e;var s=e.length-1,o=[];for(o.push(0),o.push(s);e[parseInt((0).toString(),10)]===e[parseInt(s.toString(),10)];)s--;this.reduction(e,0,s,i,o);var a=[];return o.sort(function(l,h){return l-h}),o.forEach(function(l){a.push(e[parseInt(l.toString(),10)])}),a},t.prototype.reduction=function(e,i,r,s,o){for(var a=0,l=0,h=i;ha&&(a=c,l=h)}a>s&&0!==l&&(o.push(l),this.reduction(e,i,l,s,o),this.reduction(e,l,r,s,o))},t.prototype.perpendicularDistance=function(e,i,r){return Math.abs(.5*(e.x*i.y-i.x*e.y+(i.x*r.y-r.x*i.y)+(r.x*e.y-e.x*r.y)))/Math.sqrt(Math.pow(e.x-i.x,2)+Math.pow(e.y-i.y,2))*2},t.prototype.bezierCurveSmoothness=function(e,i,r,s){if(e.length<3)return r;for(var o=0;o=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Qne=function(n){if(n)switch(n.type){case"Bpmn":return $ne;case"UmlActivity":return qne;case"UmlClassifier":return Kne;default:return em}return em},Gne=function(n){if(n)switch(n.type){case"Straight":default:return Pl;case"Bezier":return ps;case"Orthogonal":return bi}},tF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I(10)],t.prototype,"width",void 0),Pe([I(10)],t.prototype,"height",void 0),Pe([I("Arrow")],t.prototype,"shape",void 0),Pe([re({fill:"black",strokeColor:"black",strokeWidth:1},Ll)],t.prototype,"style",void 0),Pe([re({x:0,y:.5},z)],t.prototype,"pivot",void 0),Pe([I("")],t.prototype,"pathData",void 0),t}(Ee),qI=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I(0)],t.prototype,"angle",void 0),Pe([I(0)],t.prototype,"distance",void 0),t}(Ee),Xne=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I(Cx.All)],t.prototype,"controlPointsVisibility",void 0),Pe([I("FreeForm")],t.prototype,"segmentEditOrientation",void 0),Pe([I(bI.Default)],t.prototype,"smoothness",void 0),Pe([I(!0)],t.prototype,"allowSegmentsReset",void 0),t}(Ee),em=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I("None")],t.prototype,"type",void 0),t}(Ee),qne=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I("Object")],t.prototype,"flow",void 0),Pe([I(30)],t.prototype,"exceptionFlowHeight",void 0),t}(em),$ne=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I("Sequence")],t.prototype,"flow",void 0),Pe([I("Normal")],t.prototype,"sequence",void 0),Pe([I("Default")],t.prototype,"message",void 0),Pe([I("Default")],t.prototype,"association",void 0),t}(em),iF=function(n){function t(e,i,r,s){var o=n.call(this,e,i,r,s)||this;return o.points=[],o}return Qs(t,n),Pe([I("Straight")],t.prototype,"type",void 0),Pe([I(!0)],t.prototype,"allowDrag",void 0),t}(Ee),Pl=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),t.prototype.getClassName=function(){return"StraightSegment"},Pe([re({x:0,y:0},z)],t.prototype,"point",void 0),t}(iF),ps=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),t.prototype.getClassName=function(){return"BezierSegment"},t.prototype.getPoints=function(e,i){var r=[];if(r.length>0||null!=i){var o=this.bezireToPoly(r.length>0?r[r.length-1]:i,e);r.push.apply(r,o)}return r},t.prototype.bezireToPoly=function(e,i){var r=[];return i&&this.flattenCubicBezier(r,e,i.bezierPoint1,i.bezierPoint2,{x:i.points[1].x,y:i.points[1].y},10),r},t.prototype.flattenCubicBezier=function(e,i,r,s,o,a){var h,l=(z.findLength(i,r)+z.findLength(r,s)+z.findLength(s,o))/a;for(h=0;h<=l;h++){var c=h/l;e.push({x:(1-c)*(1-c)*(1-c)*i.x+3*c*(1-c)*(1-c)*r.x+3*c*c*(1-c)*s.x+c*c*c*o.x,y:(1-c)*(1-c)*(1-c)*i.y+3*c*(1-c)*(1-c)*r.y+3*c*c*(1-c)*s.y+c*c*c*o.y})}},Pe([I("Horizontal")],t.prototype,"orientation",void 0),Pe([re({x:0,y:0},z)],t.prototype,"point1",void 0),Pe([re({x:0,y:0},z)],t.prototype,"point2",void 0),Pe([re({angle:0,distance:0},qI)],t.prototype,"vector1",void 0),Pe([re({angle:0,distance:0},qI)],t.prototype,"vector2",void 0),t}(Pl),bi=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),t.prototype.getClassName=function(){return"OrthogonalSegment"},Pe([I(null)],t.prototype,"length",void 0),Pe([I(null)],t.prototype,"direction",void 0),t}(iF);function rF(n,t,e){var s=e?45:180/(2+2/(n.height/n.width)),o=s,a=180-s,l=a+2*s,h=360-s,c=Gt(t,n.center);return c>o&&ca&&cl&&cMath.abs(t.y-n.y)?n.x=c)return s=z.findAngle(n[parseInt(d.toString(),10)],n[d+1]),{point:r=z.transform(n[parseInt(d.toString(),10)],s,c-(a||0)),index:l=d};a=o[parseInt(d.toString(),10)]}return{point:r,index:l}}(n,t),r=z.findAngle(n[i.index],n[i.index+1]),s=function xse(n){var e=0;switch(n.alignment){case"Center":case"After":e=0;break;case"Before":e=-0}return e}(t),o=z.transform(i.point,r+45,s);return i.point=o,i.angle=r,i}(i,e),h=l.point;s.id=this.id+"_"+e.id;var c=e.style;s.style={fill:c.fill,strokeColor:c.strokeColor,gradient:null,opacity:c.opacity,strokeDashArray:c.strokeDashArray,strokeWidth:c.strokeWidth},0===r.width&&(r.width=this.style.strokeWidth),0===r.height&&(r.height=this.style.strokeWidth);var d_y=(h.y-r.y)/r.height;a.x=r.width*((h.x-r.x)/r.width),a.y=r.height*d_y;var g,v,u=SF(e,l.angle,i),p=u.hAlign,f=u.vAlign;return"left"===p?(g="Left",a.x+=e.displacement.x):"right"===p?(g="Right",a.x-=e.displacement.x):"center"===p&&(g="Center"),"top"===f?(v="Top",a.y+=e.displacement.y):"bottom"===f?(v="Bottom",a.y-=e.displacement.y):"center"===f&&(v="Center"),s.horizontalAlignment=g,s.verticalAlignment=v,(s=rm(s,o&&"Label"!==o.flipMode&&"None"!==o.flipMode?this.flip:"None",e)).float=!0,s.connectionDirection=e.connectionDirection,s.setOffsetWithRespectToBounds(a.x,a.y,"Absolute"),s.relativeMode="Point",s.visible=!(!ga(e,hi.Visible)||ga(e,hi.Hover)||ga(e,hi.Connect)),s.elementActions=s.elementActions|Xr.ElementIsPort,s},t.prototype.getConnectorRelation=function(){var e=this.shape;"Association"===e.relationship?(this.segments[0].type="Straight",this.sourceDecorator.shape="None",this.targetDecorator.shape="Arrow"):"Inheritance"===e.relationship?(this.segments[0].type="Orthogonal",this.sourceDecorator.shape="None",this.targetDecorator.shape="Arrow"):"Composition"===e.relationship||"Aggregation"===e.relationship?(this.segments[0].type="Orthogonal",this.sourceDecorator.shape="Diamond",this.targetDecorator.shape="None"):"Dependency"===e.relationship?(this.segments[0].type="Orthogonal",this.sourceDecorator.shape="None",this.targetDecorator.shape="OpenArrow"):"Realization"===e.relationship&&(this.segments[0].type="Orthogonal",this.sourceDecorator.shape="None",this.targetDecorator.shape="Arrow"),"BiDirectional"===e.associationType&&(this.sourceDecorator.shape="None",this.targetDecorator.shape="None");var i,o,r="",s="";e.multiplicity.source&&(e.multiplicity.source.lowerBounds=e.multiplicity.source.lowerBounds,e.multiplicity.source.upperBounds=e.multiplicity.source.upperBounds),e.multiplicity.target&&(e.multiplicity.target.lowerBounds=e.multiplicity.target.lowerBounds,e.multiplicity.target.upperBounds=e.multiplicity.target.upperBounds);var a=e.multiplicity.source,l=e.multiplicity.target;o=a.upperBounds?a.lowerBounds+"..."+a.upperBounds:a.lowerBounds,i=l.upperBounds?l.lowerBounds+"..."+l.upperBounds:l.lowerBounds,"ManyToOne"===e.multiplicity.type&&(e.multiplicity.target.optional=!1,r=o||"*",s="1"),"OneToMany"===e.multiplicity.type&&(e.multiplicity.source.optional=!1,s=i||"*",r="1"),"ManyToMany"===e.multiplicity.type&&(r=o||"*",s=i||"*"),"OneToOne"===e.multiplicity.type&&(e.multiplicity.target.optional=!1,e.multiplicity.source.optional=!1,r="1",s="1"),this.annotations=[{id:this.id+"sourcelabel",content:r,offset:0,alignment:"Before",margin:{right:5,bottom:5}},{id:this.id+"targetlabel",content:s,offset:1,alignment:"Before",margin:{right:5,bottom:5}}]},t.prototype.getBpmnSequenceFlow=function(){var e=new Ke,i=new Ke;return"Normal"===this.shape.sequence&&"Bezier"!==this.type&&(this.targetDecorator.shape="Arrow"),"Default"===this.shape.sequence&&(e=this.getSegmentElement(this,e),i=DF(this.intermediatePoints,this),this.targetDecorator.shape="Arrow"),"Conditional"===this.shape.sequence&&(this.targetDecorator.shape="Arrow",this.sourceDecorator.shape="Diamond",i.id=this.id+this.shape.type),i},t.prototype.getUMLObjectFlow=function(){if(this.annotations)for(var e=0;e0&&(this.sourcePoint=o[0],this.targetPoint=o[o.length-1]),o},t.prototype.clipDecorator=function(e,i,r,s){var a,l,o={x:0,y:0},h=i.length,c=z.distancePoints(a=r?i[0]:i[h-1],l=r?i[1]:i[h-2]);c=0===c?1:c;var d=1,u=r?e.sourceWrapper:e.targetWrapper;u&&(d=u.style.strokeWidth,s&&s&ee.DecoratorPropertyChange&&(d=1));var p=d-1;return o.x=Math.round(a.x+p*(l.x-a.x)/c),o.y=Math.round(a.y+p*(l.y-a.y)/c),(r&&"None"!==e.sourceDecorator.shape||!r&&"None"!==e.targetDecorator.shape)&&(o=z.adjustPoint(o,l,!0,s&ee.DecoratorPropertyChange?0:d/2)),o},t.prototype.clipDecorators=function(e,i,r){return"None"!==e.sourceDecorator.shape&&(i[0]=this.clipDecorator(e,i,!0,r)),"None"!==e.targetDecorator.shape&&(i[i.length-1]=this.clipDecorator(e,i,!1,r)),i},t.prototype.updateSegmentElement=function(e,i,r,s){var o=new Ne,a=this.getSegmentPath(e,i,s);if("Bezier"===e.type){if(this.segments.length>0)for(var l=0;l0)if("Straight"===e.type&&e.segments.length<2)for(var o=0;o1)for(o=0;o0&&"Bezier"!==this.type)for(var p=0;p0&&(a=p0&&(f<2*this.cornerRadius?(l=z.adjustPoint(h[parseInt(p.toString(),10)],h[p+1],!0,f/2),p0&&(s=this.bridgePath(e,s,p),"Orthogonal"===e.type&&(s=this.bridgePath(e,s,p+1))),s+=" L"+a.x+" "+a.y))}else if("Bezier"===this.type){var g=void 0,v=void 0;if(this.parentObj.element){var y=this.parentObj.element.ej2_instances[0].eventHandler.action;g=this.parentObj.element.ej2_instances[0].eventHandler.tool instanceof kd,v=y.includes("PortDraw")||y.includes("Drag")}for(var S=void 0,b=this.segments,M=0;M2&&(b[parseInt(M.toString(),10)].bezierPoint1={x:0,y:0},b[parseInt(M.toString(),10)].bezierPoint2={x:0,y:0}),!z.isEmptyPoint(b[parseInt(M.toString(),10)].point1)||b[parseInt(M.toString(),10)].vector1.angle||b[parseInt(M.toString(),10)].vector1.distance?b[parseInt(M.toString(),10)].vector1.angle||b[parseInt(M.toString(),10)].vector1.distance?b[parseInt(M.toString(),10)].bezierPoint1=z.transform(h[parseInt(M.toString(),10)],b[parseInt(M.toString(),10)].vector1.angle,b[parseInt(M.toString(),10)].vector1.distance):b[parseInt(M.toString(),10)].bezierPoint1={x:b[parseInt(M.toString(),10)].point1.x||b[parseInt(M.toString(),10)].bezierPoint1.x,y:b[parseInt(M.toString(),10)].point1.y||b[parseInt(M.toString(),10)].bezierPoint1.y}:((e.sourceID||this.sourcePortID)&&this.sourceWrapper&&!v&&!g&&(S=rF(this.sourceWrapper.bounds,h[parseInt(M.toString(),10)],!0)),b[parseInt(M.toString(),10)].bezierPoint1=ZI(h[parseInt(M.toString(),10)],h[M+1],S)),!z.isEmptyPoint(b[parseInt(M.toString(),10)].point2)||b[parseInt(M.toString(),10)].vector2.angle||b[parseInt(M.toString(),10)].vector2.distance?b[parseInt(M.toString(),10)].vector2.angle||b[parseInt(M.toString(),10)].vector2.distance?b[parseInt(M.toString(),10)].bezierPoint2=z.transform(h[M+1],b[parseInt(M.toString(),10)].vector2.angle,b[parseInt(M.toString(),10)].vector2.distance):b[parseInt(M.toString(),10)].bezierPoint2={x:b[parseInt(M.toString(),10)].point2.x||b[parseInt(M.toString(),10)].bezierPoint2.x,y:b[parseInt(M.toString(),10)].point2.y||b[parseInt(M.toString(),10)].bezierPoint2.y}:((e.targetID||this.targetPortID)&&this.targetWrapper&&!v&&!g&&(S=rF(this.targetWrapper.bounds,h[M+1],!0)),b[parseInt(M.toString(),10)].bezierPoint2=ZI(h[M+1],h[parseInt(M.toString(),10)],S));h.splice(1,0,{x:b[0].bezierPoint1.x,y:b[0].bezierPoint1.y}),h.splice(h.length-1,0,{x:b[b.length-1].bezierPoint2.x,y:b[b.length-1].bezierPoint2.y}),h=this.clipDecorators(e,h,r);for(var w=0;w0&&(s=this.bridgePath(e,s,D),s+=" L"+o.x+" "+o.y);return s},t.prototype.updateShapeElement=function(e){var i;switch(e.shape.type){case"Bpmn":e.wrapper.children[3]instanceof Ke&&(i=e.wrapper.children[3]),"Message"===e.shape.flow&&this.updateShapePosition(e,i);break;case"UmlActivity":"Exception"===e.shape.flow&&this.getUMLExceptionFlow(e.wrapper.children[0])}},t.prototype.updateShapePosition=function(e,i){var o=xF(this.intermediatePoints,i,.5);i.offsetX=o.x,i.offsetY=o.y},t.prototype.scale=function(e,i,r,s,o){var a=0,l=0;if(this.wrapper&&this.wrapper.outerBounds){var h=function T3(n){var t=n.wrapper.children[0].bounds;return"None"!==n.sourceDecorator.shape&&t.uniteRect(n.wrapper.children[1].bounds),"None"!==n.targetDecorator.shape&&t.uniteRect(n.wrapper.children[2].bounds),t}(this),c=Math.abs((this.wrapper.bounds.width||this.style.strokeWidth||1)-2),d=Math.abs((this.wrapper.bounds.height||this.style.strokeWidth||1)-2);a=h.width-c,l=h.height-d,e=Math.abs((r-Math.max(a,l))/c),i=Math.abs((s-Math.max(a,l))/d),a=l=Math.min(a,l)}e=i=Math.min(e,i);var u=Hi();qi(u,-(o=o||this.wrapper).rotateAngle,o.offsetX,o.offsetY),Qp(u,e,i,o.offsetX,o.offsetY),qi(u,o.rotateAngle,o.offsetX,o.offsetY);var p=function Uie(n,t){for(var e=[],i=0,r=t;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},tse=function(n){function t(e,i){var r=n.call(this,e,i)||this;return r.offset=0,r.scale=1,r}return ese(t,n),t.prototype.preRender=function(){this.unWireEvents(),this.wireEvents()},t.prototype.render=function(){this.updateRulerGeometry(),this.renderComplete()},t.prototype.getModuleName=function(){return"Ruler"},t.prototype.destroy=function(){this.unWireEvents(),this.notify("destroy",{}),n.prototype.destroy.call(this),this.element.classList.remove("e-ruler")},t.prototype.getPersistData=function(){return this.addOnPersist(["loaded"])},t.prototype.onPropertyChanged=function(e,i){for(var r=0,s=Object.keys(e);r100;)r/=10,s/=10;for(;s<25;)r*=10,s*=10;return s>=25&&s%25!=0&&(s=25*Math.round(s/25)),s*e/r},t.prototype.createMarkerLine=function(e,i,r){var s;return i&&((s=e.getElementById(i.id+"_marker"))&&s.parentNode.removeChild(s),s=Bi("line",r)),s},t.prototype.drawRulerMarker=function(e,i,r){var s,o,h,d,u="Horizontal"===this.orientation,p=e.getElementsByTagName("svg");for(h=0;h0)for(var a=i.childNodes.length-1;a>=0;a--)i.childNodes[parseInt(a.toString(),10)].parentNode.removeChild(i.childNodes[parseInt(a.toString(),10)]);i.appendChild(s)}return s},t.prototype.wireEvents=function(){},t.prototype.unWireEvents=function(){},kc([I(5)],t.prototype,"interval",void 0),kc([I(100)],t.prototype,"segmentWidth",void 0),kc([I("Horizontal")],t.prototype,"orientation",void 0),kc([I("RightOrBottom")],t.prototype,"tickAlignment",void 0),kc([I("red")],t.prototype,"markerColor",void 0),kc([I(25)],t.prototype,"thickness",void 0),kc([I(null)],t.prototype,"arrangeTick",void 0),kc([I(400)],t.prototype,"length",void 0),t}(yi);function oF(n,t){var e=document.getElementById(n.element.id+(t?"_hRuler":"_vRuler")),i=qa(n),r=aF(n);e||(e=Tt("div",{id:n.element.id+(t?"_hRuler":"_vRuler"),style:"height:"+(t?i.height:r.height+100)+"px;overflow:hidden;width:"+(t?r.width+100:i.width)+"px;position:absolute;font-size:11px;"+(t?"margin-left:"+i.width+"px;":"margin-top:"+i.height+"px;")})),n.element.insertBefore(e,n.element.firstChild);var l=t?n.rulerSettings.horizontalRuler:n.rulerSettings.verticalRuler,h=new tse(l);h.orientation=t?"Horizontal":"Vertical",h.length=(t?r.width:r.height)+l.segmentWidth,h.appendTo("#"+n.element.id+(t?"_hRuler":"_vRuler")),t?n.hRuler=h:n.vRuler=h;var c=document.getElementById(n.element.id+(t?"_hRuler":"_vRuler"));t?n.hRuler.element=c:n.vRuler.element=c}function JI(n){var t=-n.scroller.horizontalOffset,e=-n.scroller.verticalOffset;n&&n.rulerSettings.showRulers?(n.hRuler.length=0,n.vRuler.length=0,void 0!==t&&n.hRuler.element&&lF(n,n.hRuler,t,!0),void 0!==e&&n.vRuler.element&&lF(n,n.vRuler,e,!1)):qx(n)}function qx(n){an(n.element.id+"_hRuler"),an(n.element.id+"_vRuler"),an(n.element.id+"_overlapRuler")}function qa(n){var t=0,e=0;return n.rulerSettings.showRulers&&(t=n.rulerSettings.horizontalRuler.thickness,e=n.rulerSettings.verticalRuler.thickness),new me(e,t)}function aF(n){var t=qa(n),e=n.scroller.viewPortHeight,i=n.scroller.viewPortWidth;return i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},hF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return ase(t,n),t.prototype.getClassName=function(){return"UserHandle"},Fn([I("")],t.prototype,"name",void 0),Fn([I("")],t.prototype,"pathData",void 0),Fn([I("")],t.prototype,"content",void 0),Fn([I("")],t.prototype,"source",void 0),Fn([I("#000000")],t.prototype,"backgroundColor",void 0),Fn([I("Top")],t.prototype,"side",void 0),Fn([I("")],t.prototype,"borderColor",void 0),Fn([I(.5)],t.prototype,"borderWidth",void 0),Fn([I(25)],t.prototype,"size",void 0),Fn([I("white")],t.prototype,"pathColor",void 0),Fn([I(10)],t.prototype,"displacement",void 0),Fn([I(!0)],t.prototype,"visible",void 0),Fn([I(0)],t.prototype,"offset",void 0),Fn([re({},$n)],t.prototype,"margin",void 0),Fn([I("Center")],t.prototype,"horizontalAlignment",void 0),Fn([I("Center")],t.prototype,"verticalAlignment",void 0),Fn([I(!1)],t.prototype,"disableNodes",void 0),Fn([I(!1)],t.prototype,"disableConnectors",void 0),Fn([re({},Ed)],t.prototype,"tooltip",void 0),Fn([I("")],t.prototype,"template",void 0),t}(Ee);function cF(n){return lse[n.toString()]}var lse={Action:"M 90 82.895 C 90 86.819 86.776 90 82.8 90 H 7.2 C 3.224 90 0 86.819 0 82.895 V 7.105 C 0 3.181 3.224 0 7.2 0 h 75.6 C 86.776 0 90 3.181 90 7.105 V 82.895 Z",Decision:"M10,19.707L0.293,10L10,0.293L19.707,10L10,19.707z",MergeNode:"M10,19.707L0.293,10L10,0.293L19.707,10L10,19.707z",InitialNode:"M10,19.5c-5.238,0-9.5-4.262-9.5-9.5S4.762,0.5,10,0.5s9.5,4.262,9.5,9.5S15.238,19.5,10,19.5z",ForkNode:"m0.75,0.75l636.00002,0l0,290l-636.00002,0l0,-290z",JoinNode:"m0.75,0.75l636.00002,0l0,290l-636.00002,0l0,-290z",TimeEvent:"M50.001,0.00286865 L25.001,25.0029 L0.000976562,0.00286865 L50.001,0.00286865 z M0.000976562,50.0029 L25.001,25.0029 L50.001,50.0029 L0.000976562,50.0029 z",AcceptingEvent:"M17.8336 32.164 L29.64 24 L17.32 16 L48.1664 16 L48.5 32 Z",SendSignal:"M48.164 31.8336 L56 23.832 L47.836 16 L16.168 16 L16.1668 31.8336 Z",ReceiveSignal:"M48.1664 31.8336 L39.836 24 L47.836 16 L16.168 16 L16.168 31.836 Z",StructuredNode:"M0,0 L50,0 L50,50 L0,50 z",Note:"M20 12 L4 12 L4 22 L22 22 L22 14 L20 14 L20 12 L22 14 Z"},KI=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),$a=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},hse=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return KI(t,n),$a([I()],t.prototype,"key",void 0),$a([I()],t.prototype,"keyModifiers",void 0),t}(Ee),dF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return KI(t,n),t.prototype.getClassName=function(){return"Command"},$a([I("")],t.prototype,"name",void 0),$a([I()],t.prototype,"canExecute",void 0),$a([I()],t.prototype,"execute",void 0),$a([re({},hse)],t.prototype,"gesture",void 0),$a([I("")],t.prototype,"parameter",void 0),t}(Ee),cse=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return KI(t,n),$a([Bt([],dF)],t.prototype,"commands",void 0),t}(Ee),dse=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return KI(t,n),$a([I()],t.prototype,"show",void 0),$a([I()],t.prototype,"showCustomMenuOnly",void 0),$a([I()],t.prototype,"items",void 0),t}(Ee),Zp=function(){function n(){}return n.prototype.renderShadow=function(t,e,i,r){void 0===i&&(i=null);var l,o=z.transform({x:0,y:0},t.shadow.angle,t.shadow.distance);r&&(l=r.getElementById(e.id+"_shadow")),l||(l=document.createElementNS("http://www.w3.org/2000/svg",i?"path":"rect"),e.appendChild(l));var h={id:e.id+"_shadow",fill:t.shadow.color,stroke:t.shadow.color,opacity:t.shadow.opacity.toString(),transform:"rotate("+t.angle+","+(t.x+t.width*t.pivotX)+","+(t.y+t.height*t.pivotY)+")translate("+(t.x+o.x)+","+(t.y+o.y)+")"};if(r){var c=r.getElementById(e.id);c&&c.insertBefore(l,c.firstChild)}oi(l,h),i?i&&this.renderPath(l,t,i):oi(l,{width:t.width,height:t.height})},n.prototype.parseDashArray=function(t){return[]},n.prototype.drawRectangle=function(t,e,i,r,s,o,a,l,h){var c,d,u,p;e.shadow&&!r&&this.renderShadow(e,t,void 0,o),c=e.id===t.id?e.id+"_container":e.id,o&&(d=o.getElementById(c)),(!d||s)&&(d=document.createElementNS("http://www.w3.org/2000/svg","rect"),t.appendChild(d)),o&&!e.shadow&&(u=o.getElementById(e.id+"_groupElement_shadow"))&&u.parentNode.removeChild(u),p=l?{id:c,x:e.x.toString(),y:e.y.toString(),width:e.width.toString(),height:e.height.toString(),visibility:e.visible?"visible":"hidden",transform:"rotate("+e.angle+","+(e.x+e.width/2)+","+(e.y+e.height/2)+")",rx:e.cornerRadius||0,ry:e.cornerRadius||0,opacity:e.opacity}:{id:c,x:e.x.toString(),y:e.y.toString(),width:e.width.toString(),height:e.height.toString(),visibility:e.visible?"visible":"hidden",transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")",rx:e.cornerRadius||0,ry:e.cornerRadius||0,opacity:e.opacity},a&&(p.role="img",p["aria-label"]=a);var f=e.class||"";h||(f.includes("e-diagram-resize-handle")||f.includes("e-diagram-endpoint-handle")||f.includes("e-diagram-bezier-control-handle"))&&(f+=" e-disabled"),e.class&&(p.class=f),a||(p["pointer-events"]="none"),oi(d,p),this.setSvgStyle(d,e,i)},n.prototype.updateSelectionRegion=function(t,e){var i;i=t.parentNode.getElementById(e.id);var r={id:e.id,x:e.x.toString(),y:e.y.toString(),width:e.width.toString(),height:e.height.toString(),transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")",class:"e-diagram-selected-region"};i||(i=document.createElementNS("http://www.w3.org/2000/svg","rect"),t.appendChild(i)),this.setSvgStyle(i,e),oi(i,r)},n.prototype.createGElement=function(t,e){return Bi(t,e)},n.prototype.drawLine=function(t,e){var i=document.createElementNS("http://www.w3.org/2000/svg","line");this.setSvgStyle(i,e);var r=e.x+e.width*e.pivotX,s=e.y+e.height*e.pivotY,o={id:e.id,x1:e.startPoint.x+e.x,y1:e.startPoint.y+e.y,x2:e.endPoint.x+e.x,y2:e.endPoint.y+e.y,stroke:e.stroke,"stroke-width":e.strokeWidth.toString(),opacity:e.opacity.toString(),transform:"rotate("+e.angle+" "+r+" "+s+")",visibility:e.visible?"visible":"hidden"};e.class&&(o.class=e.class),oi(i,o),t.appendChild(i)},n.prototype.drawCircle=function(t,e,i,r){var s=document.createElementNS("http://www.w3.org/2000/svg","circle");this.setSvgStyle(s,e);var o=e.class||"";i||(o+=" e-disabled");var a={id:e.id,cx:e.centerX,cy:e.centerY,r:e.radius,visibility:e.visible?"visible":"hidden",class:o};r&&(a.role="img",a["aria-label"]=r),s.style.display=e.visible?"block":"none",oi(s,a),t.appendChild(s)},n.prototype.drawPath=function(t,e,i,r,s,o,a){var h,c,l=[];l=e3(l=Cd(e.data)),e.shadow&&this.renderShadow(e,t,l,s),s&&!e.shadow&&(h=s.getElementById(e.id+"_groupElement_shadow"))&&h.parentNode.removeChild(h),s&&(c=s.getElementById(e.id)),(!c||r)&&(c=document.createElementNS("http://www.w3.org/2000/svg","path"),t.appendChild(c)),this.renderPath(c,e,l);var d={};d=a?{id:e.id,transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")translate("+e.x+","+e.y+"),scale("+a+")",visibility:e.visible?"visible":"hidden",opacity:e.opacity}:{id:e.id,transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")translate("+e.x+","+e.y+")",visibility:e.visible?"visible":"hidden",opacity:e.opacity},o&&(d.role="img",d["aria-label"]=o),e.class&&(d.class=e.class),oi(c,d),this.setSvgStyle(c,e,i)},n.prototype.renderPath=function(t,e,i){var r,s,o,a,l,h,c,d,u=i,p="";for(l=0,h=0,d=0,c=u.length;de.width&&"Wrap"!==e.textOverflow&&"NoWrap"===e.textWrapping&&(h[0].text=qF(e.content,e)),v=0;vD&&(u.text=u.text.slice(0,u.text.length-3),u.text=u.text.concat("..."),l.data=u.text),this.alignText(y,p,u,l,f,g,v,e,h),C+=u.dy}}C&&e.isHorizontalLane&&(M=e.parentOffsetX+e.pivotX,w=e.parentOffsetY+e.pivotY,e.y=e.parentOffsetY-C*e.pivotY+.5),e.textDecoration&&"LineThrough"===e.textDecoration&&(e.textDecoration=pb(e.textDecoration));var R={id:e.id+"_text",fill:e.color,visibility:e.visible?"visible":"hidden","text-decoration":e.textDecoration,transform:"rotate("+e.angle+","+M+","+w+")translate("+e.x+","+e.y+")",opacity:e.opacity};r&&(R.role="img",R["aria-label"]=r),oi(y,R)}},n.prototype.alignText=function(t,e,i,r,s,o,a,l,h){"justify"!==l.textAlign?this.setText(t,e,i,r,s,o,l):a!==h.length-1?this.setText(t,e,i,r,s,o,l,l.width,"spacing"):this.setText(t,e,i,r,s,o,l)},n.prototype.setText=function(t,e,i,r,s,o,a,l,h){oi(e,"justify"!==a.textAlign?{x:s.toString(),y:o.toString()}:{x:s.toString(),y:o.toString(),textLength:l||0,lengthAdjust:h||"spacing"}),t.setAttribute("fill",i.text),e.appendChild(r),t.appendChild(e)},n.prototype.drawImage=function(t,e,i,r){var s;i&&(s=i.getElementById(e.id+"image")),s||(s=document.createElementNS("http://www.w3.org/2000/svg","image"),t.appendChild(s));var o=new Image;o.src=e.source;var a="None"!==e.scale?e.scale:"",l=e.alignment,h=l.charAt(0).toLowerCase()+l.slice(1);"Stretch"!==a&&(h+=" "+a.charAt(0).toLowerCase()+a.slice(1)),oi(s,{id:e.id+"image",x:e.x.toString(),y:e.y.toString(),transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")",width:e.width.toString(),visibility:e.visible?"visible":"hidden",height:e.height.toString(),preserveAspectRatio:h,opacity:e.opacity.toString()}),s.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",o.src.toString())},n.prototype.drawHTMLContent=function(t,e,i,r,s){var o,a;if(e&&(o=e.querySelector("#"+t.id+"_html_element")),!o){(a=e.querySelector("#"+t.id+"_html_element")||e.querySelector("#"+t.nodeId+"_html_element"))||(a=Tt("div",{id:t.nodeId+"_html_element",class:"foreign-object"})),o=Tt("div",{id:t.id+"_html_element",class:"foreign-object"});var c=document.getElementById(t.diagramId).ej2_instances[0],d=!1;if(e.parentNode&&e.parentNode.parentNode&&e.parentNode.parentNode.parentNode&&e.parentNode.parentNode.parentNode.classList.contains("e-overview")&&(d=!0),d)c.isReact?c.renderReactTemplates(function(){o.appendChild(t.template.cloneNode(!0))}):o.appendChild(t.template.cloneNode(!0));else{if("string"==typeof t.template){var u=document.createElement("div");u.innerHTML=t.template,t.template=u,c.selectedItems.userHandles.filter(function(g){return g.name===t.id.split("_shape")[0]&&""!==g.template})[0].template=t.template}t.isTemplate&&t.template?o.appendChild(t.template):t.template&&o.appendChild(t.template.cloneNode(!0))}void 0!==s&&e.childNodes.length>s&&e.insertBefore(o,e.childNodes[parseInt(s.toString(),10)]),a.appendChild(o),e.appendChild(a)}var f=En(t).topLeft;o.setAttribute("style","height:"+t.actualSize.height+"px; width:"+t.actualSize.width+"px;left:"+f.x+"px; top:"+f.y+"px;position:absolute;transform:rotate("+(t.rotateAngle+t.parentTransform)+"deg);pointer-events:"+(r?"all":"none")+";visibility:"+(t.visible?"visible":"hidden")+";opacity:"+t.style.opacity+";")},n.prototype.drawNativeContent=function(t,e,i,r,s){var o,a;if(s&&(o=s.getElementById(t.id+"_native_element"),a=s.getElementById(t.id+"_clip")),!o){(o=document.createElementNS("http://www.w3.org/2000/svg","g")).setAttribute("id",t.id+"_native_element"),o.appendChild(t.template.cloneNode(!0));var l=this.createGElement("g",{id:t.id+"_inner_native_element"});l.appendChild(o),e.appendChild(l)}a&&o.removeChild(a),o.setAttribute("style","visibility:"+(t.visible?"visible":"hidden")+";opacity:"+t.style.opacity+";"),this.setNativTransform(t,o,i,r),"Slice"===t.scale&&this.drawClipPath(t,o,i,r,s),oi(o,t.description?{role:"img","aria-label":t.description}:{})},n.prototype.setNativTransform=function(t,e,i,r){var s=0!==t.contentSize.width?t.contentSize.width:1,o=0!==t.contentSize.height?t.contentSize.height:1;e.setAttribute("transform","rotate("+t.parentTransform+","+t.offsetX+","+t.offsetY+") translate("+(t.offsetX-t.templatePosition.x*r/s-r*t.pivot.x)+","+(t.offsetY-t.templatePosition.y*i/o-i*t.pivot.y)+") scale("+r/s+","+i/o+")")},n.prototype.drawClipPath=function(t,e,i,r,s){var o=t.contentSize.width,a=t.contentSize.height,l=t.width/(r/o),h=t.height/(i/a),c=t.templatePosition.x+(t.width>=t.height?0:(o-l)/2),d=t.templatePosition.y+(t.height>=t.width?0:(a-h)/2),u=s.getElementById(t.id+"_clip");(u=document.createElementNS("http://www.w3.org/2000/svg","clipPath")).setAttribute("id",t.id+"_clip"),e.appendChild(u);var p=s.getElementById(t.id+"_clip_rect");return p=document.createElementNS("http://www.w3.org/2000/svg","rect"),u.appendChild(p),oi(p,{id:t.id+"_clip_rect",width:l.toString(),height:h.toString(),x:c.toString(),y:d.toString()}),sm()?e.setAttribute("clip-path","url("+location.protocol+"//"+location.host+location.pathname+"#"+t.id+"_clip)"):e.setAttribute("clip-path","url(#"+t.id+"_clip)"),e},n.prototype.renderGradient=function(t,e,i){var r,s,o,h,c,a=IT(i),l=a.getElementById(i+"gradient_pattern");if(l||(l=Bi("defs",{id:i+"gradient_pattern"}),a.insertBefore(l,a.firstChild)),bF(e.id),"None"!==t.gradient.type){for(var d=0;dt.width&&("Ellipsis"===t.textOverflow||"Clip"===t.textOverflow)&&"NoWrap"===t.textWrapping?0:.5*t.width:"right"===t.textAlign&&(c=1*t.width),s.x=0+c+(e?e.x:0),s.y=1.2+d-r.height/2,s},n}(),Pc=function(){function n(t,e,i){this.renderer=null,this.isSvgMode=!0,this.transform={x:0,y:0},this.diagramId=t,this.element=xt(this.diagramId),this.svgRenderer=e,this.isSvgMode=i,this.renderer=i?new Zp:new bo}return n.prototype.setCursor=function(t,e){t.style.cursor=e},n.prototype.setLayers=function(){this.iconSvgLayer=this.element.getElementsByClassName("e-ports-expand-layer")[0],this.adornerSvgLayer=this.element.getElementsByClassName("e-adorner-layer")[0],this.nativeSvgLayer=this.element.getElementsByClassName("e-native-layer")[0],this.diagramSvgLayer=this.element.getElementsByClassName("e-diagram-layer")[0]},n.prototype.getAdornerLayer=function(){return yT(this.diagramId)},n.prototype.getParentSvg=function(t,e,i){return this.diagramId&&t&&t.id?t.id.split("_icon_content").length>1||t.id.split("_nodeport").length>1||t.elementActions&Xr.ElementIsPort?this.iconSvgLayer:e&&"selector"===e?this.adornerSvgLayer:t instanceof Cn?this.nativeSvgLayer:this.diagramSvgLayer:i},n.prototype.getParentElement=function(t,e,i,r){var s=e;if(i&&this.diagramId&&t&&t.id){t.id.split("_icon_content").length>1?(s=i.getElementById(this.diagramId+"_diagramExpander"),e=null):t.id.split("_nodeport").length>1?s=i.getElementById(this.diagramId+"_diagramPorts"):t instanceof Cn?(s=i.getElementById(this.diagramId+"_nativeLayer"),e=null):t.elementActions&Xr.ElementIsPort?(s=i.getElementById(this.diagramId+"_diagramPorts"),e=null):s=i.getElementById(this.diagramId+"_diagramLayer");var o=this.getGroupElement(t,e||s,r);s=o.g,o.svg&&(i=o.svg)}return{g:s,svg:i}},n.prototype.getGroupElement=function(t,e,i){var r,o,s=this.getParentSvg(t);if(e&&s){if(s&&!(r=s.getElementById(t.id+"_groupElement"))&&s!==this.nativeSvgLayer){var a=this.nativeSvgLayer;r=a.getElementById(t.id+"_groupElement"),o=a}r||(r=this.svgRenderer.createGElement("g",{id:t.id+"_groupElement"}),void 0!==i&&e.childNodes.length>i?e.insertBefore(r,e.childNodes[parseInt(i.toString(),10)]):e.appendChild(r))}return{g:r,svg:o}},n.prototype.renderElement=function(t,e,i,r,s,o,a,l,h,c,d){t instanceof Cs?(t.id=t.id?t.id:Qe(),this.renderContainer(t,e,i,r,s,o,a,l,h,c,d)):t instanceof wI?this.renderImageElement(t,e,r,s,a):t instanceof Ke?this.renderPathElement(t,e,r,s,a,h,d):t instanceof ni?this.renderTextElement(t,e,r,s,a,c):t instanceof Cn?this.renderNativeElement(t,e,r,s,a):t instanceof Jn?this.renderHTMLElement(t,e,i,r,s,a,l):this.renderRect(t,e,r,s,h)},n.prototype.drawSelectionRectangle=function(t,e,i,r,s,o){var a={width:i*o.scale,height:r*o.scale,x:.5+(t=(t+o.tx)*o.scale),y:.5+(e=(e+o.ty)*o.scale),fill:"transparent",stroke:"gray",angle:0,pivotX:.5,pivotY:.5,strokeWidth:1,dashArray:"6 3",opacity:1,visible:!0,id:s.id+"_selected_region"},l=this.getAdornerLayer();this.svgRenderer.updateSelectionRegion(l,a)},n.prototype.renderHighlighter=function(t,e,i){var r=t.actualSize.width||2,s=t.actualSize.height||2,o=t.offsetX-r*t.pivot.x,a=t.offsetY-s*t.pivot.y;this.svgRenderer.drawRectangle(e,{width:r*i.scale,height:s*i.scale,x:o=(o+i.tx)*i.scale,y:a=(a+i.ty)*i.scale,fill:"transparent",stroke:"#8CC63F",angle:t.rotateAngle,pivotX:t.pivot.x,pivotY:t.pivot.y,strokeWidth:4,dashArray:"",opacity:1,cornerRadius:0,visible:!0,id:e.id+"_highlighter",class:"e-diagram-highlighter"},this.diagramId,void 0,void 0,e)},n.prototype.renderSelectionRectangle=function(t,e,i,r){var s=t.actualSize.width||2,o=t.actualSize.height||2,a=t.offsetX-s*t.pivot.x,l=t.offsetY-o*t.pivot.y,h={width:s*i.scale,height:o*i.scale,x:a=(a+i.tx)*i.scale,y:l=(l+i.ty)*i.scale,fill:"transparent",stroke:"#00cc00",angle:t.rotateAngle,pivotX:t.pivot.x,pivotY:t.pivot.y,strokeWidth:r?2:1,dashArray:"",opacity:1,cornerRadius:0,visible:!0,id:t.id+"_highlighter",class:r?"e-diagram-first-selection-indicator e-diagram-selection-indicator":"e-diagram-selection-indicator"},c=this.getParentSvg(t,"selector");this.svgRenderer.drawRectangle(e,h,this.diagramId,void 0,void 0,c)},n.prototype.renderSelectionLine=function(t,e,i,r){var s=this.getBaseAttributes(t,i);s.data=t.absolutePath,s.id=s.id+"_highlighter";var o=t.description?t.description:t.id;this.isSvgMode||(s.x=t.flipOffset.x?t.flipOffset.x:s.x,s.y=t.flipOffset.y?t.flipOffset.y:s.y),i&&(s.x=s.x*i.scale,s.y=s.y*i.scale),s.stroke="#00cc00",s.strokeWidth=r?2:1,s.class=r?"e-diagram-first-selection-indicator e-diagram-selection-indicator":"e-diagram-selection-indicator";var a=this.getParentSvg(t,"selector");this.svgRenderer.drawPath(e,s,this.diagramId,void 0,a,o,i.scale)},n.prototype.renderStackHighlighter=function(t,e,i,r,s,o,a){var l=t.actualSize.width||2,h=t.offsetX-l*t.pivot.x,c=t.actualSize.height||2,d=t.offsetY-c*t.pivot.y;h=(h+i.tx)*i.scale;var u,p=t.bounds,f="";if(d=(d+i.ty)*i.scale,r)if(o){var v,y;u="M 0 0 L "+(2+(g=l*i.scale))+" 0 Z",v=t.actualSize.width/Number(p.width?p.width:1)*i.scale,y=t.actualSize.height/Number(p.height?p.height:1)*i.scale,f=yI(SI(Cd("M7,4 L8,4 8,7 11,7 11,8 8,8 8,11 7,11 7,8 4,8 4,7 7,7 z M7.5,0.99999994C3.9160004,1 1,3.9160004 0.99999994,7.5 1,11.084 3.9160004,14 7.5,14 11.084,14 14,11.084 14,7.5 14,3.9160004 11.084,1 7.5,0.99999994 z M7.5,0 C11.636002,0 15,3.3639984 15,7.5 15,11.636002 11.636002,15 7.5,15 3.3640003,15 0,11.636002 0,7.5 0,3.3639984 3.3640003,0 7.5,0 z")),v+g+2,y-8,!1,p.x,p.y,0,0),s.y>=t.offsetY&&(d+=c)}else{var g;a&&s.y>=t.offsetY&&(d+=c*i.scale),u="M -10 -10 L 0 0 Z M -10 10 L 0 0 Z M 0 0 L "+(g=l*i.scale)+" 0 Z M "+g+" 0 L "+(g+10)+" 10 Z L "+(g+10)+" -10 Z"}else u="M 10 -10 L 0 0 Z M -10 -10 L 0 0 Z M 0 0 L 0 "+(g=c*i.scale)+" Z M 0 "+g+" L -10 "+(g+10)+" Z L 10 "+(g+10)+" Z",s.x>=t.offsetX&&(h+=l*i.scale);this.svgRenderer.drawPath(e,{data:u+f,width:l*i.scale,height:c*i.scale,x:h,y:d,fill:"transparent",stroke:"#8CC63F",angle:t.rotateAngle,pivotX:t.pivot.x,pivotY:t.pivot.y,strokeWidth:1,dashArray:"",opacity:1,visible:!0,id:e.id+"_stack_highlighter",class:"e-diagram-highlighter"},this.diagramId)},n.prototype.drawLine=function(t,e){this.svgRenderer.drawLine(t,e)},n.prototype.drawPath=function(t,e){this.svgRenderer.drawPath(t,e,this.diagramId)},n.prototype.renderResizeHandle=function(t,e,i,r,s,o,a,l,h,c,d){var u=t.offsetX-t.actualSize.width*t.pivot.x,p=t.offsetY-t.actualSize.height*t.pivot.y,f=t.actualSize.height,g=t.actualSize.width;!c&&i&bt.Rotate&&FI(this.rendererActions)&&!z3(this.rendererActions)&&(this.renderPivotLine(t,e,o,s,a),this.renderRotateThumb(t,e,o,s,a)),this.renderBorder(t,e,o,l,h,c);var v=t.actualSize.width*r,y=t.actualSize.height*r;!h&&FI(this.rendererActions)&&!z3(this.rendererActions)&&(t.isTextAnnotation||(v>=40&&y>=40&&(s&mr.ResizeNorthWest&&this.renderCircularHandle("resizeNorthWest",t,u,p,e,qr(s,"ResizeNorthWest"),i&bt.ResizeNorthWest,o,void 0,a,{"aria-label":"Thumb to resize the selected object on top left side direction"},void 0,"e-diagram-resize-handle e-northwest",d),s&mr.ResizeNorthEast&&this.renderCircularHandle("resizeNorthEast",t,u+g,p,e,qr(s,"ResizeNorthEast"),i&bt.ResizeNorthEast,o,void 0,a,{"aria-label":"Thumb to resize the selected object on top right side direction"},void 0,"e-diagram-resize-handle e-northeast",d),s&mr.ResizeSouthWest&&this.renderCircularHandle("resizeSouthWest",t,u,p+f,e,qr(s,"ResizeSouthWest"),i&bt.ResizeSouthWest,o,void 0,a,{"aria-label":"Thumb to resize the selected object on bottom left side direction"},void 0,"e-diagram-resize-handle e-southwest",d),s&mr.ResizeSouthEast&&this.renderCircularHandle("resizeSouthEast",t,u+g,p+f,e,qr(s,"ResizeSouthEast"),i&bt.ResizeSouthEast,o,void 0,a,{"aria-label":"Thumb to resize the selected object on bottom right side direction"},void 0,"e-diagram-resize-handle e-southeast",d)),s&mr.ResizeNorth&&this.renderCircularHandle("resizeNorth",t,u+g/2,p,e,qr(s,"ResizeNorth"),i&bt.ResizeNorth,o,void 0,a,{"aria-label":"Thumb to resize the selected object on top side direction"},void 0,"e-diagram-resize-handle e-north",d),s&mr.ResizeSouth&&this.renderCircularHandle("resizeSouth",t,u+g/2,p+f,e,qr(s,"ResizeSouth"),i&bt.ResizeSouth,o,void 0,a,{"aria-label":"Thumb to resize the selected object on bottom side direction"},void 0,"e-diagram-resize-handle e-south",d),s&mr.ResizeWest&&this.renderCircularHandle("resizeWest",t,u,p+f/2,e,qr(s,"ResizeWest"),i&bt.ResizeWest,o,void 0,a,{"aria-label":"Thumb to resize the selected object on left side direction"},void 0,"e-diagram-resize-handle e-west",d),s&mr.ResizeEast&&this.renderCircularHandle("resizeEast",t,u+g,p+f/2,e,qr(s,"ResizeEast"),i&bt.ResizeEast,o,void 0,a,{"aria-label":"Thumb to resize the selected object on right side direction"},void 0,"e-diagram-resize-handle e-east",d)))},n.prototype.renderEndPointHandle=function(t,e,i,r,s,o,a,l,h,c){var f,g,d=t.sourcePoint,u=t.targetPoint,p=t.wrapper;if(this.renderCircularHandle("connectorSourceThumb",p,d.x,d.y,e,qr(r,"ConnectorSourceThumb"),i&bt.ConnectorSource,s,o,void 0,{"aria-label":"Thumb to move the source point of the connector"},void 0,"e-diagram-endpoint-handle e-sourceend",c),this.renderCircularHandle("connectorTargetThumb",p,u.x,u.y,e,qr(r,"ConnectorTargetThumb"),i&bt.ConnectorTarget,s,a,void 0,{"aria-label":"Thumb to move the target point of the connector"},void 0,"e-diagram-endpoint-handle e-targetend",c),l)if("Straight"===t.type&&t.segments.length>0)for(f=0;f0)for(f=0;f=3&&3===t.segments.length&&(S=1,b=t.segments.length-1),S=t.segments.length>t.maxSegmentThumb+2?2:S,b=t.segments.length>t.maxSegmentThumb+2?t.segments.length-2:b,1===t.segments.length&&t.segments[0].points.length<=2&&(S=1,b=t.segments.length),f=S;f=50&&i.allowDrag),this.renderOrthogonalThumb(t+"_"+(d+1),e,(i.points[parseInt(d.toString(),10)].x+i.points[d+1].x)/2,(i.points[parseInt(d.toString(),10)].y+i.points[d+1].y)/2,r,h,l,o,a,u)}else for(d=0;d=50&&i.allowDrag),this.renderOrthogonalThumb(t+"_"+(d+1),e,(i.points[parseInt(d.toString(),10)].x+i.points[d+1].x)/2,(i.points[parseInt(d.toString(),10)].y+i.points[d+1].y)/2,r,h,l,o,a,u)},n.prototype.renderOrthogonalThumb=function(t,e,i,r,s,o,a,l,h,c){var d,g,u=0,p=document.getElementById(this.diagramId);p&&(g=p.ej2_instances[0]);var y=h.constraints&qe.InheritSegmentThumbShape?g.segmentThumbShape:h.segmentThumbShape,b=h.constraints&qe.InheritSegmentThumbSize?g.segmentThumbSize:h.segmentThumbSize;if(d="horizontal"===a?function ure(n){return vre[""+n]}(y):c3(y),"Arrow"===y||"DoubleArrow"===y||"OpenArrow"===y)switch(c){case"Bottom":case"Right":u=180;break;default:u=0}else if("Fletch"===y||"OpenFetch"===y||"IndentedArrow"===y||"OutdentedArrow"===y)switch(c){case"Bottom":u=-90;break;case"Top":u=90;break;case"Right":u=180;break;default:u=0}var M={x:(i+l.tx)*l.scale-b/2,y:(r+l.ty)*l.scale-b/2,angle:u,fill:"#e2e2e2",stroke:"black",strokeWidth:1,dashArray:"",data:d,width:b,height:b,pivotX:.5,pivotY:.5,opacity:1,visible:o,id:t,class:"e-diagram-ortho-segment-handle"},w=of(M.data),C=new me(M.width,M.height),D=new Ke;M.data=D.updatePath(M.data,w,C),this.svgRenderer.drawPath(s,M,this.diagramId)},n.prototype.renderPivotLine=function(t,e,i,r,s){var o=t,l=!!(r&mr.Rotate);s&&(l=!1);var h=this.getBaseAttributes(o,i);h.fill="None",h.stroke="black",h.strokeWidth=1,h.dashArray="2,3",h.visible=l;var c=i.scale;h.x*=c,h.y*=c,h.width*=c,h.height*=c,h.id="pivotLine",h.class="e-diagram-pivot-line";var u={x:o.actualSize.width*o.pivot.x*c,y:0};h.startPoint={x:o.actualSize.width*o.pivot.x*c,y:-20},h.endPoint=u,this.svgRenderer.drawLine(e,h)},n.prototype.renderBezierLine=function(t,e,i,r,s,o){var l=this.getBaseAttributes(e,o);l.id=t,l.stroke="black",l.strokeWidth=1,l.dashArray="3,3",l.fill="None",l.class="e-diagram-bezier-control-line",l.x=0,l.y=0;var h=o.scale,g={x:(s.x+o.tx)*h,y:(s.y+o.ty)*h};l.startPoint={x:(r.x+o.tx)*h,y:(r.y+o.ty)*h},l.endPoint=g,this.svgRenderer.drawLine(i,l)},n.prototype.renderCircularHandle=function(t,e,i,r,s,o,a,l,h,c,d,u,p,f){var g=e,v={x:i,y:r};if(0!==g.rotateAngle||0!==g.parentTransform){var y=Hi();qi(y,g.rotateAngle+g.parentTransform,g.offsetX,g.offsetY),v=Je(y,v)}var S=this.getBaseAttributes(g);S.stroke="black",S.strokeWidth=1,void 0!==u?(S.id="segmentEnd_"+u,S.fill="#e2e2e2"):S.fill=h?"#8CC63F":"white",S.cornerRadius=f/2,S.angle=e.rotateAngle,S.id=t,S.visible=o,S.class=p,S.width=f,S.height=f,S.x=(v.x+l.tx)*l.scale,S.y=(v.y+l.ty)*l.scale,S.x=S.x-S.width/2,S.y=S.y-S.height/2,h&&(S.class+=" e-connected"),c&&(S.visible=!1);var b=this.getParentSvg(e,"selector");this.svgRenderer.drawRectangle(s,S,this.diagramId,!0,!0,b,d,!0,a)},n.prototype.renderBezierHandle=function(t,e,i,r,s,o,a,l,h,c,d,u,p){var v,f=document.getElementById(this.diagramId);f&&(v=f.ej2_instances[0]);var y=e,S={x:i,y:r};if(0!==y.rotateAngle||0!==y.parentTransform){var b=Hi();qi(b,y.rotateAngle+y.parentTransform,y.offsetX,y.offsetY),S=Je(b,S)}var D=a.constraints&qe.InheritSegmentThumbSize?v.segmentThumbSize:a.segmentThumbSize,A=c3(a.constraints&qe.InheritSegmentThumbShape?v.segmentThumbShape:a.segmentThumbShape),x=this.getBaseAttributes(y);x.stroke="black",x.strokeWidth=1,void 0!==d?(x.id="segmentEnd_"+d,x.fill="#e2e2e2"):x.fill=h?"#8CC63F":"white",x.angle=e.rotateAngle,x.id=t,x.visible=o,x.class=u,x.width=D,x.height=D,x.data=A,x.x=(S.x+l.tx)*l.scale,x.y=(S.y+l.ty)*l.scale,x.x=x.x-x.width/2,x.y=x.y-x.height/2,h&&(x.class+=" e-connected"),c&&(x.visible=!1);var R=of(x.data),L=new me(x.width,x.height),O=new Ke;x.data=O.updatePath(x.data,R,L);var N=this.getParentSvg(e,"selector");this.svgRenderer.drawPath(s,x,this.diagramId,!0,N)},n.prototype.renderBorder=function(t,e,i,r,s,o){var l=this.getBaseAttributes(t,i);l.x*=i.scale,l.y*=i.scale,l.width*=i.scale,l.height*=i.scale,l.fill="transparent",l.stroke="#097F7F",l.strokeWidth=1.2,l.gradient=null,l.dashArray="6,3",l.class="e-diagram-selector",o&&(l.class+=" e-diagram-lane"),l.id="borderRect",l.id=this.rendererActions&Qa.DrawSelectorBorder?"borderRect_symbol":"borderRect",r||(l.class+=" e-disabled"),s&&(l.class+=" e-thick-border"),l.cornerRadius=0;var h=this.getParentSvg(t,"selector");this.svgRenderer.drawRectangle(e,l,this.diagramId,void 0,!0,h)},n.prototype.renderUserHandler=function(t,e,i,r,s,o){for(var l,a=t.wrapper,h=0,c=t.userHandles;h0||d.disableNodes&&t.nodes.length>0||"Drag"===s&&o)&&(l=!1);var u=document.getElementById(d.name+"_template_hiddenUserHandle");u&&(d.template=u.childNodes[0].cloneNode(!0));var p=iT(t,d,i);if(p.x=(p.x+i.tx)*i.scale,p.y=(p.y+i.ty)*i.scale,d.visible&&(d.visible=!!(t.constraints&mr.UserHandle)),l)if(d.pathData){var f=d.pathData?d.pathData:d.content,g=this.getBaseAttributes(a);g.id=d.name+"_userhandle",g.fill=d.backgroundColor,g.stroke=d.borderColor,g.strokeWidth=d.borderWidth,g.centerX=p.x,g.centerY=p.y,g.radius=.5*d.size,g.class="e-diagram-userhandle-circle",g.angle=0,g.visible=d.visible,g.opacity=1,this.svgRenderer.drawCircle(e,g,1,{"aria-label":d.name+"user handle"});var y=[];y=SI(y=Cd(f));var S=of(f),w=yI(y,(d.size-.45*d.size)/S.width,(d.size-.45*d.size)/S.height,!0,S.x,S.y,0,0);S=of(w),this.svgRenderer.drawPath(e,C={x:p.x-S.width/2,y:p.y-S.height/2,angle:0,id:"",class:"e-diagram-userhandle-path",fill:d.pathColor,stroke:d.backgroundColor,strokeWidth:.5,dashArray:"",data:w,width:d.size-5,height:d.size-5,pivotX:0,pivotY:0,opacity:1,visible:d.visible},this.diagramId,void 0,void 0,{"aria-label":d.name+"user handle"})}else if(d.content){var D=new Cn(d.name,this.diagramId);D.content=d.content,D.offsetX=p.x,D.offsetY=p.y,D.id=d.name+"_shape",D.horizontalAlignment="Center",D.verticalAlignment="Center",D.visible=d.visible,D.setOffsetWithRespectToBounds(p.x,p.y,"Fraction"),D.relativeMode="Object",D.description=d.name||"User handle",D.measure(new me(d.size,d.size)),D.arrange(D.desiredSize),this.svgRenderer.drawNativeContent(D,e,d.size,d.size,this.adornerSvgLayer)}else if(d.source){var C,A=new wI;(C=this.getBaseAttributes(A,i)).width=d.size,C.height=d.size,C.x=p.x-d.size/2,C.y=p.y-d.size/2,C.sourceWidth=d.size,C.sourceHeight=d.size,C.alignment=A.imageAlign,C.source=d.source,C.scale=A.imageScale,C.visible=d.visible,C.description=d.name||"User handle",C.id=d.name+"_",this.renderer.drawImage(e,C,this.adornerSvgLayer,!1)}else{var x=new Jn(d.name,this.diagramId);x.offsetX=p.x,x.offsetY=p.y,x.id=d.name+"_shape",x.visible=d.visible,x.relativeMode="Object",x.template=d.template,x.measure(new me(d.size,d.size)),x.arrange(x.desiredSize),this.svgRenderer.drawHTMLContent(x,r,void 0,!0,void 0)}}},n.prototype.renderRotateThumb=function(t,e,i,r,s){new Ke;var a,l=new me;l.width=18,l.height=16;var d=!!(r&mr.Rotate);s&&(d=!1);var p=t.offsetX-t.actualSize.width*t.pivot.x+t.pivot.x*t.actualSize.width,f=t.offsetY-t.actualSize.height*t.pivot.y;if(a={x:(p=(p+i.tx)*i.scale)-.5*l.width,y:(f=(f+i.ty)*i.scale)-30-.5*l.height},0!==t.rotateAngle||0!==t.parentTransform){var g=Hi();qi(g,t.rotateAngle+t.parentTransform,(i.tx+t.offsetX)*i.scale,(i.ty+t.offsetY)*i.scale),a=Je(g,a)}this.svgRenderer.drawPath(e,{x:a.x,y:a.y,angle:t.rotateAngle+t.parentTransform,fill:"#231f20",stroke:"black",strokeWidth:.5,dashArray:"",data:"M 16.856144362449648 10.238890446662904 L 18.000144362449646 3.437890446662903L 15.811144362449646 4.254890446662903 C 14.837144362449646 2.5608904466629028 13.329144362449647 1.2598904466629026 11.485144362449645 0.5588904466629026 C 9.375144362449646 - 0.24510955333709716 7.071144362449646 - 0.18010955333709716 5.010144362449646 0.7438904466629028 C 2.942144362449646 1.6678904466629028 1.365144362449646 3.341890446662903 0.558144362449646 5.452890446662903 C - 0.244855637550354 7.567890446662903 - 0.17985563755035394 9.866890446662904 0.7431443624496461 11.930890446662904 C 1.6681443624496461 13.994890446662904 3.343144362449646 15.575890446662903 5.457144362449647 16.380890446662903 C 6.426144362449647 16.7518904466629 7.450144362449647 16.9348904466629 8.470144362449647 16.9348904466629 C 9.815144362449647 16.9348904466629 11.155144362449647 16.6178904466629 12.367144362449647 15.986890446662901 L 11.351144362449647 14.024890446662901 C 9.767144362449647 14.8468904466629 7.906144362449647 14.953890446662902 6.237144362449647 14.3178904466629 C 4.677144362449647 13.7218904466629 3.444144362449647 12.5558904466629 2.758144362449647 11.028890446662901 C 2.078144362449646 9.501890446662903 2.031144362449646 7.802890446662903 2.622144362449646 6.243890446662903 C 3.216144362449646 4.6798904466629025 4.387144362449646 3.442890446662903 5.914144362449646 2.760890446662903 C 7.437144362449646 2.078890446662903 9.137144362449646 2.0298904466629026 10.700144362449645 2.6258904466629027 C 11.946144362449646 3.100890446662903 12.971144362449646 3.9538904466629026 13.686144362449646 5.049890446662903 L 11.540144362449645 5.850890446662903 L 16.856144362449648 10.238890446662904 Z",width:20,height:20,pivotX:0,pivotY:0,opacity:1,visible:d,id:"rotateThumb",class:"e-diagram-rotate-handle"},this.diagramId,!0,void 0,{"aria-label":"Thumb to rotate the selected object"})},n.prototype.renderPathElement=function(t,e,i,r,s,o,a){var l=this.getBaseAttributes(t,i,o);if(l.data=t.absolutePath,l.data=t.absolutePath,t.isPathPort&&a){l.x=a[t.id]?a[t.id].cx:l.x,l.y=a[t.id]?a[t.id].cy:l.y,t.bounds.x=l.x,t.bounds.y=l.y;var h=document.getElementById(this.diagramId);h&&"PortDrag"!==h.ej2_instances[0].eventHandler.currentAction&&(t.offsetX=l.x+t.width/2,t.offsetY=l.y+t.height/2)}var u=t.description?t.description:t.id;if(this.isSvgMode||(l.x=t.flipOffset.x?t.flipOffset.x:l.x,l.y=t.flipOffset.y?t.flipOffset.y:l.y),t.isExport){var p=t.absoluteBounds,f=Cd(l.data),g=this.findAndStoreArcValues(f);l.arc=g,l.data=BF(t,p,0,l)}this.renderer.drawPath(e,l,this.diagramId,void 0,r,u)},n.prototype.findAndStoreArcValues=function(t){var e=[];return t.forEach(function(i){"A"===i.command&&e.push({r1:i.r1/2,r2:i.r2/2})}),e},n.prototype.renderSvgGridlines=function(t,e,i,r,s,o){var a=document.createElementNS("http://www.w3.org/2000/svg","pattern"),l=document.createElementNS("http://www.w3.org/2000/svg","defs");l.setAttribute("id",this.diagramId+"_grid_pattern_defn"),(t.constraints&Kt.ShowHorizontalLines||t.constraints&Kt.ShowVerticalLines)&&a.setAttribute("id",this.diagramId+"_pattern");var h=0,c=0,d=0,u=0,p=1,f=!1,g="Lines"===t.gridType,v=g?t.verticalGridlines.lineIntervals:t.verticalGridlines.dotIntervals,y=g?t.horizontalGridlines.lineIntervals:t.horizontalGridlines.dotIntervals;if(r.showRulers&&r.dynamicGrid&&s&&o)d=o.updateSegmentWidth(i.scale),u=s.updateSegmentWidth(i.scale),t.horizontalGridlines.scaledIntervals=[d/s.interval],t.verticalGridlines.scaledIntervals=[u/o.interval],f=!0;else{for(var S=0;S=2)for(;e>=2;)e/=2;else if(e<=.5)for(;e<=.5;)e*=2;var i;if(t.horizontalGridlines.scaledIntervals=t.horizontalGridlines.snapIntervals,t.verticalGridlines.scaledIntervals=t.verticalGridlines.snapIntervals,1!==e){var r=t.horizontalGridlines;for(r.scaledIntervals=[],i=0;ithis.groupElement.actualSize.height&&("Clip"===t.style.textOverflow||"Ellipsis"===t.style.textOverflow)&&(a.y=a.y+(a.height-this.groupElement.actualSize.height)/2),this.renderer.drawRectangle(e,a,this.diagramId,void 0,void 0,r),this.renderer.drawText(e,a,r,l,this.diagramId,t.isExport&&Math.min(t.exportScaleValue.x||t.exportScaleValue.y),this.groupElement),this.isSvgMode&&(t.doWrap=!1)},n.prototype.renderNativeElement=function(t,e,i,r,s){var o,a,l=this.getParentSvg(t,void 0,e)||r,h=this.getParentElement(t,e,l).g||e,c=this.getBaseAttributes(t,i);switch(c.fill="transparent",c.cornerRadius=t.cornerRadius,c.stroke="transparent",this.renderer.drawRectangle(e,c,this.diagramId,void 0,void 0,r),t.scale){case"None":o=t.contentSize.width,a=t.contentSize.height;break;case"Stretch":o=t.actualSize.width,a=t.actualSize.height;break;case"Meet":o=a=t.actualSize.width<=t.actualSize.height?t.actualSize.width:t.actualSize.height;break;case"Slice":o=a=t.actualSize.width>=t.actualSize.height?t.actualSize.width:t.actualSize.height}this.svgRenderer&&this.svgRenderer.drawNativeContent(t,h,a,o,l)},n.prototype.renderHTMLElement=function(t,e,i,r,s,o,a){var l=this.getBaseAttributes(t,r);l.fill="transparent",l.cornerRadius=t.cornerRadius,l.stroke="transparent",this.renderer.drawRectangle(e,l,this.diagramId,void 0,void 0,s),this.svgRenderer&&this.svgRenderer.drawHTMLContent(t,i.children[0],r,function Sse(n){var t=n.parentElement;do{if(um(t,"e-diagram"))return!0;t=t.parentElement}while(t);return!1}(i),a)},n.prototype.renderImageElement=function(t,e,i,r,s){var o=this.getBaseAttributes(t,i);o.cornerRadius=0,this.renderer.drawRectangle(e,o,this.diagramId,void 0,void 0,r);var a,l,h,c,g,d=t.contentSize.width,u=t.contentSize.height,p=o.width/d,f=o.height/u;if("Stretch"===t.stretch)a=d*(g=Math.min(p,f)),l=u*g;else switch(t.stretch){case"Meet":a=d*(g=Math.min(p,f)),l=u*g,o.x+=Math.abs(o.width-a)/2,o.y+=Math.abs(o.height-l)/2;break;case"Slice":g=Math.max(p,f),h=o.width/(a=d*g)*d,c=o.height/(l=u*g)*u;break;case"None":a=d,l=u}o.width=a,o.height=l,o.sourceWidth=h,o.sourceHeight=c,o.source=t.source,o.alignment=t.imageAlign,o.scale=t.imageScale,o.description=t.description?t.description:t.id,this.renderer.drawImage(e,o,r,s)},n.prototype.renderContainer=function(t,e,i,r,s,o,a,l,h,c,d){var g,u={svg:s,g:e},p=document.getElementById(this.diagramId);if(p&&(g=p.ej2_instances[0]),this.diagramId&&(s=this.getParentSvg(t)||s,this.isSvgMode)){var v=this.getParentElement(t,e,s,l).g||e;s=this.getParentSvg(this.hasNativeParent(t.children))||s;var y=this.getParentElement(this.hasNativeParent(t.children),v,s,l);u.svg=y.svg||s,u.g=y.g||v,o&&s&&(s.getElementById(u.g.id)||e.appendChild(u.g)),e=u.g}if(this.renderRect(t,e,r,s),this.groupElement=t,t.hasChildren()){for(var b,S=void 0,M=0,w=t.children;M0&&(D=g.selectedItems.nodes[0]);var L,A=void 0,x=void 0,R=!1;if(g&&g.selectedItems&&(L=g.getObject(t.id)),"None"!==t.flip&&(D=L),"None"===t.flip&&(D=L),D&&D.flipMode&&(R=!0),!(t.elementActions&Xr.ElementIsGroup)&&g instanceof Rl&&g.nameTable[t.id]&&"connectors"!==g.nameTable[t.id].propName&&R&&D){if(A=t.children&&t.children[0]instanceof Cn?document.getElementById(D.id+"_content_inner_native_element"):document.getElementById(D.id+"_content_groupElement"),!(t.children[0]instanceof Cn)&&"Text"!==D.shape.type&&"None"!==D.flipMode&&"Label"!==D.flipMode&&"All"!==D.flipMode&&"PortAndLabel"!==D.flipMode&&"LabelText"!==D.flipMode&&"PortAndLabelText"!==D.flipMode&&"LabelAndLabelText"!==D.flipMode||t.children[0]instanceof Cn&&"Port"===D.flipMode)return void this.renderFlipElement(t,A,D.flip);if((t.children[0]instanceof Cn&&("All"===D.flipMode||"Label"===D.flipMode)||"Label"===D.flipMode||"PortAndLabel"===D.flipMode||"LabelText"===D.flipMode||"PortAndLabelText"===D.flipMode||"LabelAndLabelText"===D.flipMode||"Image"===D.shape.type&&"Label"===D.flipMode)&&this.renderFlipElement(t,A,t.flip),"None"!==t.flip&&"None"===D.flipMode)this.renderFlipElement(t,A,t.flip);else if("None"!==t.flip&&("Label"===D.flipMode||"PortAndLabel"===D.flipMode||"LabelText"===D.flipMode||"PortAndLabelText"===D.flipMode||"LabelAndLabelText"===D.flipMode)||t.children[0]instanceof Cn&&"None"!==t.flip&&D&&("None"===D.flipMode||"All"===D.flipMode)){for(var O=0;O0){var i=t[0];if(i instanceof Cn)return i;i.children&&i.children.length&&this.hasNativeParent(i.children,e++||0)}},n.prototype.renderRect=function(t,e,i,r,s){var o=this.getBaseAttributes(t,i,s);o.cornerRadius=t.cornerRadius||0,t.isExport&&(o.cornerRadius*=t.exportScaleValue.x),this.renderer.drawRectangle(e,o,this.diagramId,t.isExport,void 0,r,t.description?t.description:t.id)},n.prototype.drawRect=function(t,e){e.cornerRadius=0,this.svgRenderer.drawRectangle(t,e,this.diagramId)},n.prototype.getBaseAttributes=function(t,e,i){var r={width:t.actualSize.width,height:t.actualSize.height,x:t.offsetX-t.actualSize.width*t.pivot.x,y:t.offsetY-t.actualSize.height*t.pivot.y,fill:t.style.fill,stroke:t.style.strokeColor,angle:t.rotateAngle+t.parentTransform,pivotX:t.pivot.x,pivotY:t.pivot.y,strokeWidth:t.style.strokeWidth,dashArray:t.style.strokeDashArray||"",opacity:t.style.opacity,shadow:t.shadow,gradient:t.style.gradient,visible:t.visible,id:t.id,description:t.description,canApplyStyle:t.canApplyStyle,shapeType:t.shapeType};return"Page"===t.rotationReference&&(r.angle=t.rotateAngle),i&&(r.x=r.x-.5,r.y=r.y-.5),t.isExport&&(r.width*=t.exportScaleValue.x,r.height*=t.exportScaleValue.y,r.x*=t.exportScaleValue.x,r.y*=t.exportScaleValue.y,r.strokeWidth*=t.exportScaleValue.x),t.flip&&(r.flip=t.flip),e&&(r.x+=e.tx,r.y+=e.ty),r},n.renderSvgBackGroundImage=function(t,e,i,r,s,o){if(t.source){var l=IT(e.id).getElementById(e.id+"_image");if(!l){var h=function Toe(n){return xt(n).getElementsByClassName("e-background-image-layer")[0]}(e.id);(l=document.createElementNS("http://www.w3.org/2000/svg","image")).setAttribute("id",e.id+"_image"),h.appendChild(l)}var c=new Image;c.src=t.source,l.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",c.src.toString());var d="None"!==t.scale?t.scale:"",u=t.align,p=u.charAt(0).toLowerCase()+u.slice(1);d&&(p+=" "+d.charAt(0).toLowerCase()+d.slice(1)),oi(l,{id:e.id+"_image",x:i,y:r,width:s,height:o,preserveAspectRatio:p})}},n.prototype.transformLayers=function(t,e){var i=t.tx*t.scale,r=t.ty*t.scale,s="domTable";if(i!==this.transform.x||r!==this.transform.y||0===i||0===r){e&&(window[""+s][this.diagramId+"_diagramLayer"]||(window[""+s][this.diagramId+"_diagramLayer"]=this.diagramSvgLayer.getElementById(this.diagramId+"_diagramLayer")),window[""+s][this.diagramId+"_diagramLayer"].setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+"),scale("+t.scale+")"));var a=function Aoe(n){var t="domTable",e=null;return window[t][n+"_gridline"]?e=window[t][n+"_gridline"]:(e=Bd(n).getElementById(n+"_gridline"),window[t][n+"_gridline"]=e),e}(this.diagramId);return a.setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+")"),window[""+s][this.diagramId+"_diagramPorts"]||(window[""+s][this.diagramId+"_diagramPorts"]=this.iconSvgLayer.getElementById(this.diagramId+"_diagramPorts")),window[""+s][this.diagramId+"_diagramPorts"].setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+"),scale("+t.scale+")"),window[""+s][this.diagramId+"_diagramExpander"]||(window[""+s][this.diagramId+"_diagramExpander"]=this.iconSvgLayer.getElementById(this.diagramId+"_diagramExpander")),window[""+s][this.diagramId+"_diagramExpander"].setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+"),scale("+t.scale+")"),window[""+s][this.diagramId+"_nativeLayer"]||(window[""+s][this.diagramId+"_nativeLayer"]=this.nativeSvgLayer.getElementById(this.diagramId+"_nativeLayer")),window[""+s][this.diagramId+"_nativeLayer"].setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+"),scale("+t.scale+")"),Io(this.diagramId).children[0].style.transform="translate("+t.tx*t.scale+"px,"+t.ty*t.scale+"px)scale("+t.scale+")",this.transform={x:t.tx*t.scale,y:t.ty*t.scale},!0}return!1},n.prototype.updateNode=function(t,e,i,r,s,o,a){this.renderElement(t,e,i,r,this.getParentSvg(t),void 0,void 0,s,null,o,a)},n}(),use=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),eb=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},uF=function(n){function t(e,i){var r=n.call(this,e,i)||this;return r.mode="Canvas",r.id="overview",r.actionName="",r.startPoint=null,r.currentPoint=null,r.prevPoint=null,r.scale=null,r.inAction=!1,r.viewPortRatio=1,r.horizontalOffset=0,r.verticalOffset=0,r.model={},r.event=!0,r.overviewid=88123,r.model={width:r.width,height:r.height},r}return use(t,n),t.prototype.onPropertyChanged=function(e,i){for(var r=0,s=Object.keys(e);r0||e.toString().indexOf("%")>0?e.toString():e.toString()+"px"},t.prototype.renderCanvas=function(e){var i=document.getElementById(this.element.id+"_canvas");i||(i=Tt("div",{}),this.element.appendChild(i)),Ho(i,{id:this.element.id+"_canvas",class:"drawing",style:"position:relative; height:"+this.getSizeValue(this.model.height)+"; width:"+this.getSizeValue(this.model.width)+";style:-ms-touch-action: none;touch-action: none;"}),this.element.setAttribute("tabindex",String(-1)),this.element.style.overflow="hidden",this.element.style.height=String(this.model.height),this.element.style.width=String(this.model.width),this.canvas=i},t.prototype.setParent=function(e){var i=document.getElementById(e);if(this.parent){var s=this.parent;this.parent=null,s.setOverview(null,this.element.id),this.removeDocument(this)}this.parent=this.getDiagram(i,"ej2_instances"),this.parent&&this.parent.setOverview(this)},t.prototype.getDiagram=function(e,i){for(var r,s=e[""+i].length,o=0;o0?p:Math.floor(window.innerWidth)}if(0===h){var f=Math.floor(window.innerHeight-u-Math.floor(c.top));h=f>0?f:Math.floor(window.innerHeight)}l>0&&(s.setAttribute("width",String(l)),this.model.height=h),h>0&&(s.setAttribute("height",String(h)),this.model.width=l),e.diagramLayerDiv||(e.diagramLayerDiv=Tt("div",{}),e.diagramLayer=bo.createCanvas(this.element.id+"_diagramLayer",this.model.width,this.model.height),e.diagramLayer.setAttribute("style","position:absolute; left:0px; top:0px "),e.diagramLayerDiv.appendChild(e.diagramLayer),e.canvas.appendChild(e.diagramLayerDiv)),Ho(e.diagramLayerDiv,{id:this.element.id+"_diagramLayer_div",style:"width:"+this.model.width+"px; height:"+this.model.height+"px;position:absolute;top:0px;left:0px"}),this.renderHtmlLayer(e.canvas),this.renderNativeLayer(e.canvas,e),this.addOverviewRectPanel(e)},t.prototype.removeDocument=function(e){var i=document.getElementById(this.canvas.id+"_svg");this.canvas.removeChild(i);var r=document.getElementById(this.element.id+"_htmlLayer");this.canvas.removeChild(r);var s=document.getElementById(this.element.id+"_diagramLayer_div");this.canvas.removeChild(s),e.diagramLayerDiv=null,e.diagramLayer=null,window.domTable[this.id+"html_layer"]=null},t.prototype.renderHtmlLayer=function(e){var i=Tt("div",{id:this.element.id+"_htmlLayer",class:"e-html-layer",style:"pointer-events:none;position:absolute;top:0px;left:0px;"}),s=Tt("div",{id:this.element.id+"_htmlLayer_div",style:"position:absolute;top:0px;left:0px;"});return i.appendChild(s),e.appendChild(i),i},t.prototype.renderNativeLayer=function(e,i){if(!document.getElementById(this.element.id+"_nativeLayer_svg")){var r=this.parent.createSvg(this.element.id+"_nativeLayer_svg",this.model.width,this.model.height),s=Bi("g",{id:this.element.id+"_nativeLayer"});r.appendChild(s),i.diagramLayerDiv.appendChild(r),oi(r,{class:"e-native-layer"})}},t.prototype.addOverviewRectPanel=function(e){var i=document.getElementById(this.canvas.id+"_overviewsvg");i&&i.parentNode.removeChild(i),i=Bi("svg",{id:this.canvas.id+"_overviewsvg",class:"overviewsvg",version:"1.1",style:"position:absolute;left:0px;top:0px; aria-label:Specifies overview",width:this.model.width,height:this.model.height}),e.canvas.appendChild(i);var s=Bi("g",{id:this.element.id+"_overviewlayer",style:"pointer-events:none"});i.appendChild(s);var o=Bi("rect",{fill:"transparent",width:"100%",height:"100%",class:"overviewbackrect",id:this.canvas.id+"overviewbackrect"});o.setAttribute("style"," pointer-events: none; "),s.appendChild(o);var a=Bi("g",{id:this.canvas.id+"overviewhandle",style:"pointer-events:all"});s.appendChild(a);var l=Bi("rect",{id:this.canvas.id+"overviewrect",fill:"transparent"});a.appendChild(l),this.renderOverviewCorner("left",a),this.renderOverviewCorner("right",a),this.renderOverviewCorner("top",a),this.renderOverviewCorner("bottom",a),this.renderOverviewCorner("topleft",a),this.renderOverviewCorner("topright",a),this.renderOverviewCorner("bottomleft",a),this.renderOverviewCorner("bottomright",a)},t.prototype.renderOverviewCorner=function(e,i){var s,o=Bi(s="top"===e||"bottom"===e||"right"===e||"left"===e?"rect":"circle",{id:this.canvas.id+"visible"+e,class:"overview-resizer"});i.appendChild(o);var a=Bi(s,{id:this.canvas.id+e,class:"overviewresizer",fill:"transparent"});i.appendChild(a)},t.prototype.updateOverviewRectangle=function(){var e=this.currentPoint.x-this.prevPoint.x,i=this.currentPoint.y-this.prevPoint.y,r=new me;r.width=0,r.height=0;var s=0,o=0;switch(this.resizeDirection){case"left":r.width-=e,r.height-=e/this.viewPortRatio,s=e,o=e/this.viewPortRatio,o/=2;break;case"right":r.width+=e,r.height+=e/this.viewPortRatio,o=e/this.viewPortRatio,o/=-2;break;case"top":r.height-=i,r.width-=i*this.viewPortRatio,o=i,s=i*this.viewPortRatio,s/=2;break;case"bottom":r.height+=i,r.width+=i*this.viewPortRatio,s=i*this.viewPortRatio,s/=-2;break;case"topleft":Math.abs(i)>Math.abs(e)?e=i*this.viewPortRatio:i=e/this.viewPortRatio,r.width-=e,r.height-=i,s=e,o=i;break;case"topright":Math.abs(i)>Math.abs(e)?e=-i*this.viewPortRatio:i=-e/this.viewPortRatio,o=i,r.width+=e,r.height-=i;break;case"bottomleft":Math.abs(i)>Math.abs(e)?e=-i*this.viewPortRatio:i=-e/this.viewPortRatio,s=e,r.width-=e,r.height+=i;break;case"bottomright":Math.abs(i)>Math.abs(e)?e=i*this.viewPortRatio:i=e/this.viewPortRatio,r.width+=e,r.height+=i}this.updateHelper(s,o,r,void 0,void 0)},t.prototype.updateHelper=function(e,i,r,s,o){var a,l,h,u,p,d=this.element.getElementsByTagName("svg")[2].getElementById("helper");r?(a=(h=d.getBBox()).x+e,l=h.y+i,s=h.width+r.width,o=h.height+r.height):(u=this.currentPoint.x>this.startPoint.x?this.currentPoint.x-this.prevPoint.x:this.prevPoint.x-this.currentPoint.x,p=this.currentPoint.y>this.startPoint.y?this.currentPoint.y-this.prevPoint.y:this.prevPoint.y-this.currentPoint.y,Math.abs(p)>Math.abs(u)?u=this.viewPortRatio*p:p=u/this.viewPortRatio,h=d.getBBox(),a=this.startPoint.x>this.currentPoint.x?h.x-u:h.x,l=this.startPoint.y>this.currentPoint.y?h.y-p:h.y,s=h.width+u,o=h.height+p),oi(this.helper,{id:this.helper.id,x:a,y:l,width:Math.max(0,s),height:Math.max(0,o)})},t.prototype.updateOverviewrect=function(e,i,r,s){Ho(document.getElementById(this.canvas.id+"overviewrect"),{x:e,y:i,width:Math.max(1,r),height:Math.max(1,s)}),this.updateOverviewCorner("top",e+8,i+1,Math.max(0,r-16),2),this.updateOverviewCorner("bottom",e+8,i+s+3,Math.max(0,r-16),2),this.updateOverviewCorner("left",e-2,i+11,2,Math.max(0,s-16)),this.updateOverviewCorner("right",e+r,i+11,2,Math.max(0,s-16)),this.updateOverviewCorner("topleft",e,i+3,5,5),this.updateOverviewCorner("topright",e+r,i+3,5,5),this.updateOverviewCorner("bottomleft",e,i+s+3,5,5),this.updateOverviewCorner("bottomright",e+r,i+s+3,5,5)},t.prototype.updateOverviewCorner=function(e,i,r,s,o){var a,l;"top"===e||"bottom"===e||"right"===e||"left"===e?(a={x:i,y:r,width:s,height:o,fill:"#ED1C24"},l={x:i-2,y:r-2,width:2===s?4:s,height:2===o?4:o}):(a={cx:i,cy:r,r:4,fill:"#ED1C24"},l={cx:i,cy:r,r:6,fill:"transparent"}),Ho(document.getElementById(this.canvas.id+"visible"+e),a),Ho(document.getElementById(this.canvas.id+e),l)},t.prototype.translateOverviewRectangle=function(){Number(this.model.width),Number(this.model.height);var r=this.currentPoint.x-this.prevPoint.x,s=this.currentPoint.y-this.prevPoint.y,l=this.element.getElementsByClassName("overviewsvg")[0].getElementById(this.canvas.id+"overviewrect").getBBox(),h=l.x+r,c=l.y+s,d=l.width,u=l.height;this.updateOverviewrect(h,c,d,u),this.updateParentView(this.parent.scroller.currentZoom,h,c,d,u,null)},t.prototype.renderOverviewRect=function(e,i,r,s){var o=Number(this.model.width),a=Number(this.model.height),c=Math.max(this.parent.scroller.viewPortWidth/(r/o*this.contentWidth),this.parent.scroller.viewPortHeight/(s/a*this.contentHeight));if(c>=.25&&c<=30){this.updateParentView(c,e,i,r,s,{x:0,y:0});var u=this.scrollOverviewRect(this.parent.scroller.horizontalOffset,this.parent.scroller.verticalOffset,this.parent.scroller.currentZoom,!0);if(this.helper){var f=this.element.getElementsByTagName("rect")[10].getBBox();u.x=f.x,u.y=f.y}"pan"===this.actionName?this.updateOverviewrect(-u.x,-u.y,u.width,u.height):this.updateOverviewrect(u.x,u.y,u.width,u.height)}},t.prototype.scrollOverviewRect=function(e,i,r,s){if(!this.actionName||s){var o=Number(this.model.width),a=Number(this.model.height),l=Math.min(this.contentWidth/o,this.contentHeight/a),h=new Ne,c=h.x=e/r/l,d=h.y=i/r/l,u=0;this.parent.rulerSettings.showRulers&&(u=25);var p=document.getElementById(this.parent.element.id+"content"),f=0,g=0;p&&(f=p.offsetWidth-p.clientWidth,g=p.offsetHeight-p.clientHeight);var v=h.width=(this.parent.scroller.viewPortWidth-u-f)/r/l,y=h.height=(this.parent.scroller.viewPortHeight-u-g)/r/l;if(s){var S=new Ne;return S.x=c,S.y=d,S.width=v,S.height=y,S}this.updateOverviewrect(-c,-d,v,y)}return null},t.prototype.updateParentView=function(e,i,r,s,o,a){var f,g,l=Number(this.model.width),h=Number(this.model.height),u=i*(this.contentWidth/l)*e,p=r*(this.contentHeight/h)*e;this.parent.scroller.getPageBounds(),(1!==e||"pan"===this.actionName)&&(f=-u-this.parent.scroller.horizontalOffset,g=-p-this.parent.scroller.verticalOffset),this.parent.setBlazorDiagramProps(!0),this.parent.realActions|=$i.OverViewAction,"scale"===this.actionName||"draw"===this.actionName?this.parent.scroller.zoom(e/this.parent.scroller.currentZoom,f,g,a):ce()?this.parent.scroller.zoom(1,f,g,a):this.parent.pan(f,g,a,!0)},t.prototype.updateHtmlLayer=function(e){var i=Io(e.element.id),r=this.parent.scroller.getPageBounds(!0),o=r.height,a=Math.max(r.width,this.parent.scroller.viewPortWidth),l=Math.max(o,this.parent.scroller.viewPortHeight/this.parent.scroller.currentZoom),h=Math.min(Number(this.model.width)/a,Number(this.model.height)/l);i.style.transform="scale("+h+") translate("+this.parent.scroller.transform.tx+"px,"+this.parent.scroller.transform.ty+"px)"},t.prototype.updateView=function(e){var i=this.parent.scroller.getPageBounds(),r=i.width,s=i.height,o=Number(this.model.width),a=Number(this.model.height),l=Math.max(r,this.parent.scroller.viewPortWidth),h=Math.max(s,this.parent.scroller.viewPortHeight);this.contentWidth=l=Math.max(l,o/a*h),this.contentHeight=h=Math.max(h,a/o*l);var c=Math.min(o/l,a/h),d=document.getElementById(this.element.id+"_htmlLayer");d.style.webkitTransform="scale("+c+") translate("+-i.x+"px,"+-i.y+"px)",d.style.transform="scale("+c+") translate("+-i.x+"px,"+-i.y+"px)",document.getElementById(this.element.id+"_overviewlayer").setAttribute("transform","translate("+-i.x*c+","+-i.y*c+")"),this.horizontalOffset=i.x*c,this.verticalOffset=i.y*c;var p=document.getElementById(this.element.id+"_diagramLayer"),f=UF(this.element.id),g=p.getContext("2d"),v=Number(this.model.width)/this.contentWidth,y=Number(this.model.height)/this.contentHeight;v=Math.min(v,y);var S=this.parent.scroller.transform;f.setAttribute("transform","translate("+S.tx*v+","+S.ty*y+"),scale("+v+")"),g.setTransform(v,0,0,v,0,0),g.fillStyle="red",this.scrollOverviewRect(this.parent.scroller.horizontalOffset,this.parent.scroller.verticalOffset,this.parent.scroller.currentZoom)},t.prototype.scrolled=function(e){if(this.event){var i=this.scrollOverviewRect(this.parent.scroller.horizontalOffset,this.parent.scroller.verticalOffset,this.parent.scroller.currentZoom,!0);this.updateOverviewrect(-i.x,-i.y,i.width,i.height),this.updateView(this)}},t.prototype.updateCursor=function(e){if(um(e.target,"overviewresizer"))switch(e.target.id){case this.canvas.id+"left":this.canvas.style.cursor="w-resize";break;case this.canvas.id+"right":this.canvas.style.cursor="e-resize";break;case this.canvas.id+"top":this.canvas.style.cursor="n-resize";break;case this.canvas.id+"bottom":this.canvas.style.cursor="s-resize";break;case this.canvas.id+"topleft":this.canvas.style.cursor="nw-resize";break;case this.canvas.id+"topright":this.canvas.style.cursor="ne-resize";break;case this.canvas.id+"bottomleft":this.canvas.style.cursor="sw-resize";break;case this.canvas.id+"bottomright":this.canvas.style.cursor="se-resize"}else this.canvas.style.cursor="default"},t.prototype.mouseMove=function(e){if(this.event=!1,this.updateCursor(e),this.currentPoint=this.mousePosition(e),this.actionName)switch(this.actionName){case"draw":!this.inAction&&(this.startPoint.x!==this.currentPoint.x||this.startPoint.y!==this.currentPoint.y)&&(this.initHelper(),this.inAction=!0),this.inAction&&this.updateHelper();break;case"scale":this.inAction||(this.initHelper(),this.inAction=!0),this.updateOverviewRectangle();break;case"pan":(this.startPoint.x!==this.currentPoint.x||this.startPoint.y===this.currentPoint.y||this.inAction)&&(this.inAction=!0,this.translateOverviewRectangle())}this.prevPoint=this.currentPoint},t.prototype.documentMouseUp=function(e){this.inAction=!1,this.actionName="",this.helper&&(this.helper.parentNode.removeChild(this.helper),this.helper=null),this.event=!0,document.getElementById(this.canvas.id+"overviewhandle").style.pointerEvents="all"},t.prototype.windowResize=function(e){var i=this;return this.resizeTo&&clearTimeout(this.resizeTo),this.resizeTo=setTimeout(function(){var s=document.getElementById(i.element.id).getBoundingClientRect();i.model.width=s.width>0?s.width:i.model.width,i.model.height=s.height>0?s.height:i.model.height,i.renderCanvas(),i.setParent(i.sourceID)},10),!1},t.prototype.mouseDown=function(e){if(e.target.id===this.canvas.id+"_overviewsvg"&&(this.actionName="draw"),e.target.id===this.canvas.id+"overviewrect"&&(this.actionName="pan"),um(e.target,"overviewresizer"))switch(this.actionName="scale",e.target.id){case this.canvas.id+"left":this.resizeDirection="left";break;case this.canvas.id+"right":this.resizeDirection="right";break;case this.canvas.id+"top":this.resizeDirection="top";break;case this.canvas.id+"bottom":this.resizeDirection="bottom";break;case this.canvas.id+"topleft":this.resizeDirection="topleft";break;case this.canvas.id+"topright":this.resizeDirection="topright";break;case this.canvas.id+"bottomleft":this.resizeDirection="bottomleft";break;case this.canvas.id+"bottomright":this.resizeDirection="bottomright"}this.startPoint=this.prevPoint=this.mousePosition(e),this.viewPortRatio=this.parent.scroller.viewPortWidth/this.parent.scroller.viewPortHeight,document.getElementById(this.canvas.id+"overviewhandle").style.pointerEvents="none"},t.prototype.mouseUp=function(e){if(this.currentPoint=this.mousePosition(e),this.actionName)if(this.startPoint.x!==this.currentPoint.x||this.startPoint.y!==this.currentPoint.y){if("pan"!==this.actionName&&this.helper){var i=this.element.getElementsByTagName("rect")[10].getBBox();this.resizeDirection=this.resizeDirection||"",this.renderOverviewRect(i.x,i.y,o=i.width,a=i.height)}}else if(e.target.id===this.canvas.id+"_overviewsvg"||"helper"===e.target.id){var o=(i=this.element.getElementsByTagName("svg")[2].getElementById(this.canvas.id+"overviewrect").getBBox()).width,a=i.height;this.inAction=!0,this.actionName="pan",this.renderOverviewRect(this.currentPoint.x-o/2,this.currentPoint.y-a/2,o,a),this.inAction=!1}this.helper&&(this.helper.parentNode.removeChild(this.helper),this.helper=null),this.actionName="",this.startPoint=null,this.currentPoint=null,this.prevPoint=null,this.helper=null,this.viewPortRatio=1,this.resizeDirection="",this.inAction=!1,this.event=!0,document.getElementById(this.canvas.id+"overviewhandle").style.pointerEvents="all"},t.prototype.initHelper=function(){var e=this.element.getElementsByTagName("svg")[2],i=this.startPoint.x,r=this.startPoint.y,s=1,o=1;if("scale"===this.actionName){var l=e.getElementById(this.canvas.id+"overviewrect").getBBox();i=l.x,r=l.y,s=l.width,o=l.height}var h=Bi("rect",{id:"helper",x:i,y:r,width:s,height:o,fill:"transparent",stroke:"gray","stroke-dasharray":"2 2","shape-rendering":"crispEdges"});e.getElementById(this.element.id+"_overviewlayer").appendChild(h),this.helper=h},t.prototype.mousePosition=function(e){var i,r,s;-1!==e.type.indexOf("touch")?(r=(i=e).changedTouches[0].clientX-this.element.offsetLeft,s=i.changedTouches[0].clientY-this.element.offsetTop):(r=e.clientX,s=e.clientY);var l=this.element.getBoundingClientRect();return{x:(r-=l.left)+this.horizontalOffset,y:(s-=l.top)+this.verticalOffset}},t.prototype.destroy=function(){if(this.unWireEvents(),this.notify("destroy",{}),n.prototype.destroy.call(this),document.getElementById(this.element.id)){this.element.classList.remove("e-overview");var e=document.getElementById(this.element.id+"_canvas");e&&this.element.removeChild(e)}this.parent.views.splice(this.parent.views.indexOf(this.element.id),1),this.diagramLayerDiv=null,this.canvas=null,this.parent=null},t.prototype.getModuleName=function(){return"Overview"},eb([I("100%")],t.prototype,"width",void 0),eb([I("100%")],t.prototype,"height",void 0),eb([I("")],t.prototype,"sourceID",void 0),eb([H()],t.prototype,"created",void 0),t}(yi);function fse(n,t){for(var e=0;ez.findLength(e,n)?e:t;var o=z.findAngle(t,e),a=z.findAngle(i,n),l=z.findLength(i,n),h=a+2*(o-a);return{x:i.x+l*Math.cos(h*Math.PI/180),y:i.y+l*Math.sin(h*Math.PI/180)}}function Jp(n,t,e){if(n&&n.children&&n.children.length>0)for(var r=void 0,s=0;s0&&"annotations"!==r&&"ports"!==r)if(n[""+l].length>0)for(var h=0;h<=n[""+l].length;h++)Ro(n[""+l],t?t[""+l]:void 0,e[""+l],"annotations"===l||"ports"===l?n:void 0,l);else Ro(n[""+l],t?t[""+l]:void 0,e[""+l],"annotations"===l||"ports"===l?n:void 0,l);else if(s instanceof Object&&t&&"annotations"!==r&&"ports"!==r)Ro(n[""+l],t[""+l],e[""+l]);else if("annotations"!==r&&"ports"!==r&&t&&!t[""+l]||!t&&n&&(n[""+l]||void 0!==n[""+l]))n[""+l]=e[""+l];else{var c=void 0;("annotations"===r||"ports"===r)&&("annotations"===r?(n[""+l]&&Ro(n[""+l],t[""+l],e[""+l]),n[""+l]||(fs(i)===de?(c=new Nr(i,"annotations",e[""+l]),i.annotations.push(c)):(c=new Zn(i,"annotations",e[""+l]),i.annotations.push(c)))):n[""+l]?Ro(n[""+l],t[""+l],e[""+l]):(c=new Es(i,"ports",e[""+l]),i.ports.push(c)))}}}function bse(n,t){for(var e="Bezier"===n.type?function yse(n){var t=[];if("Bezier"===n.type)for(var e=0,i=0;i0||n.ports.length>0){var p=n.wrapper.children;for(i=3;i0)return{enabled:!1,intersectPt:e};var l=o/s,h=a/s;return l>=0&&l<=1&&h>=0&&h<=1?(e.x=i.x1+l*(i.x2-i.x1),e.y=i.y1+l*(i.y2-i.y1),{enabled:!0,intersectPt:e}):{enabled:!1,intersectPt:e}}function ib(n,t,e,i){var a=tm(vF(n.x,n.y,t.x,t.y),vF(e.x,e.y,i.x,i.y));return a.enabled?a.intersectPt:{x:0,y:0}}function vF(n,t,e,i){return{x1:Number(n)||0,y1:Number(t)||0,x2:Number(e)||0,y2:Number(i)||0}}function mF(n,t,e){var i=[],s={x:t.topRight.x+(e=e||0),y:t.topRight.y},o={x:t.bottomRight.x,y:t.bottomRight.y-e},a={x:t.bottomLeft.x,y:t.bottomLeft.y+e};return i.push({x:t.topLeft.x-e,y:t.topLeft.y}),i.push(s),i.push(o),i.push(a),i}function zc(n,t,e,i,r,s){var o={},a=e.scroller.transform.scale,h=e.scroller.verticalOffset;return o.x=(i?n.x:t.x)*a+e.scroller.horizontalOffset-r,o.y=(i?n.y:t.y)*a+h-s,o}function yF(n,t){var e=new Ke;return e.data=n.pathData,e.height=n.height>10?n.height-(n.padding.bottom+n.padding.top):n.height,e.width=n.width>10?n.width-(n.padding.left+n.padding.right):n.width,e.visible=n.visibility,e.id=t.id+"_shape",e.inversedAlignment=!1,e.horizontalAlignment="Center",e.verticalAlignment="Center",e.style={fill:n.iconStrokeColor,strokeColor:n.iconStrokeColor,strokeWidth:n.iconStrokeWidth},e.setOffsetWithRespectToBounds(.5,.5,"Fraction"),e.relativeMode="Object",e.description=t.description||"",e}function Zx(n,t,e){var i=Jx(n,t),r=z.findAngle(n[i.index],n[i.index+1]),s=function Tse(n){var t;t=n instanceof AI?0:void 0===n.content?10:0;var e=0;switch(n.alignment){case"Center":e=0;break;case"Before":e=-(0+t);break;case"After":e=0+t}return e}(t),o=z.transform(i.point,r+45,s);return i.point=o,i.angle=r,i}function Jx(n,t){for(var r,s,a,l,e=0,i=t.offset,o=[],h=0;h=c)return s=z.findAngle(n[parseInt(d.toString(),10)],n[d+1]),{point:r=z.transform(n[parseInt(d.toString(),10)],s,c-(a||0)),index:l=d};a=o[parseInt(d.toString(),10)]}return{point:r,index:l}}function SF(n,t,e){t%=360;var a,l,s=225;switch(n.alignment){case"Before":t>=45&&t<=135?(l="right",a=.5===n.offset?"center":"top"):t>=s&&t<=315?(l="left",a=.5===n.offset?"center":"bottom"):t>45&&t=45&&t<=135?(l="left",a=.5===n.offset?"center":"top"):t>=s&&t<=315?(l="right",a=.5===n.offset?"center":"bottom"):t>45&&tMath.abs(t.y-n.y)?n.x0)for(var e=0;e=0;r--)("nodes"===i||"connectors"===i)&&(n[""+i][parseInt(r.toString(),10)].wrapper=null),"dataManager"!==i&&(n[""+i][parseInt(r.toString(),10)]=tT(n[""+i][parseInt(r.toString(),10)],e[""+i][parseInt(r.toString(),10)],void 0!==t[""+i]?t[""+i][parseInt(r.toString(),10)]:[]),("[]"===JSON.stringify(n[""+i][parseInt(r.toString(),10)])||"{}"===JSON.stringify(n[""+i][parseInt(r.toString(),10)])||void 0===n[""+i][parseInt(r.toString(),10)])&&n[""+i].splice(r,1));n=void 0}function Rh(n,t){var e=t.style,i=t;t.canApplyStyle=!0;for(var r=0,s=Object.keys(n);r=0&&n.splice(e,1)}function Kp(n,t,e){var i;n.intermediatePoints=t,n.updateSegmentElement(n,t,n.wrapper.children[0],e);var r=n.sourceDecorator;if("Bezier"===n.type){var s=n.segments[0],o=n.segments[n.segments.length-1];i=[z.isEmptyPoint(o.point2)?o.bezierPoint2:o.point2,z.isEmptyPoint(s.point1)?s.bezierPoint1:s.point1]}else i=n.intermediatePoints;t=n.clipDecorators(n,t,e);var a=n.wrapper.children[0];a.canMeasurePath=!0,n.updateDecoratorElement(a=n.wrapper.children[1],t[0],i[1],r),n.updateDecoratorElement(a=n.wrapper.children[2],t[t.length-1],i[i.length-2],n.targetDecorator),n.updateShapeElement(n)}function iT(n,t,e){var l,i=n.wrapper,s=t.offset,o=t.size/e.scale,a=t.margin,h=i.offsetX-i.actualSize.width*i.pivot.x,c=i.offsetY-i.actualSize.height*i.pivot.y;if(l={x:0,y:0},n.nodes.length>0){switch(t.side){case"Top":l.x+=h+s*i.actualSize.width,l.y+=c-o;break;case"Bottom":l.x+=h+s*i.actualSize.width,l.y+=c+i.actualSize.height+o;break;case"Left":l.x+=h-o,l.y+=c+s*i.actualSize.height;break;case"Right":l.x+=h+i.actualSize.width+o,l.y+=c+s*i.actualSize.height}l.x+=(a.left-a.right)/e.scale+o/2*("Center"===t.horizontalAlignment?0:"Right"===t.horizontalAlignment?-1:1),l.y+=(a.top-a.bottom)/e.scale+o/2*("Center"===t.verticalAlignment?0:"Top"===t.verticalAlignment?-1:1)}else if(n.connectors.length>0){var d=n.connectors[0],u={offset:s},p=Jx(d.intermediatePoints,u),f=p.index;l=p.point;var y,v=Zx(d.intermediatePoints,u).angle;qi(y=Hi(),-v,d.intermediatePoints[parseInt(f.toString(),10)].x,d.intermediatePoints[parseInt(f.toString(),10)].y),(l=Je(y,l)).x+=a.left-a.right+o/2*("Center"===t.horizontalAlignment?0:"Right"===t.horizontalAlignment?-1:1),l.y+=a.top-a.bottom+o/2*("Center"===t.verticalAlignment?0:"Top"===t.verticalAlignment?-1:1),qi(y=Hi(),v,d.intermediatePoints[parseInt(f.toString(),10)].x,d.intermediatePoints[parseInt(f.toString(),10)].y),l=Je(y,l)}return 0===i.rotateAngle&&0===i.parentTransform||(qi(y=Hi(),i.rotateAngle+i.parentTransform,i.offsetX,i.offsetY),l=Je(y,l)),l}function fa(n,t,e,i){if(i.annotation){if(kl(i.annotation))return!0}else if(mr[""+t]&n&&bt[""+t]&e)return!0;return!1}function qr(n,t){return!!(mr[""+t]&n)}function Hc(n,t){return!!(Cx[""+t]&n)}function ga(n,t){return n.visibility&t}function rb(n,t){var e;if("Text"===n.shape.type)e=n.shape;else{var i=t.split("_");t=i[i.length-1];for(var r=0;rn[""+t]?e.splice(0,0,n):e.push(n);else if(e.length>1){for(var i=0,r=e.length-1,s=Math.floor((i+r)/2);s!==i;)if(e[parseInt(s.toString(),10)][""+t]n[""+t]))break;r=s,s=Math.floor((i+r)/2)}e[parseInt(r.toString(),10)][""+t]n[""+t]?e.splice(i,0,n):e[parseInt(i.toString(),10)][""+t]n[""+t]&&e.splice(r,0,n)}}function Qse(n){var t=document.getElementById(n.diagramId),e="ej2_instances",i=t[""+e][0].nodes;void 0===i&&(i=function Gse(n){for(var t=[],e=0;e30?10:o/2;for(var h=0,c=0;c=l){var u=l-h;r=Gt(n[c],n[c+1]),s=z.transform(n[c],r,u);break}h+=d}return s},ob=function(n,t){if(n instanceof te||n instanceof de)for(var e=0;e=0||navigator.platform.indexOf("iPad")>=0||navigator.platform.indexOf("iPhone")>=0||navigator.platform.indexOf("MacIntel")>=0)&&("safari"===X.info.name||"webkit"===X.info.name)}function AF(n,t,e,i){return void 0!==t.previewSize[""+i]?t.previewSize[""+i]:void 0!==n.symbolPreview[""+i]?n.symbolPreview[""+i]:t[""+i]||e.actualSize[""+i]}function om(n,t,e){return n&&n.parentId&&(e=(n=t.nameTable[n.parentId]).parentId?om(n,t,e):n.id),e}function am(n,t){return n.selectedItems.connectors.length>1&&0===n.selectedItems.nodes.length&&0!==t.rotateAngle}function Zse(n){if(n.arrowType&&""!==n.arrowType.trim())switch(n.arrowType){case"single-line-arrow":default:return{targetDecorator:"Arrow",strokeWidth:1};case"double-line-arrow":return{targetDecorator:"Arrow",strokeWidth:2};case"dotted-arrow":return{targetDecorator:"Arrow",strokeDashArray:"2,2"};case"single-line":return{targetDecorator:"None",strokeWidth:1};case"double-line":return{targetDecorator:"None",strokeWidth:2};case"dotted":return{targetDecorator:"None",strokeDashArray:"2,2"};case"wiggly-arrow":return{targetDecorator:"None",strokeWidth:1,opacity:0}}return{targetDecorator:"Arrow",strokeWidth:1}}var Jse=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),io=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},LF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Jse(t,n),io([I("None")],t.prototype,"shape",void 0),io([I("white")],t.prototype,"fill",void 0),io([I("Auto")],t.prototype,"horizontalAlignment",void 0),io([I("Auto")],t.prototype,"verticalAlignment",void 0),io([I(10)],t.prototype,"width",void 0),io([I(10)],t.prototype,"height",void 0),io([re({x:.5,y:1},z)],t.prototype,"offset",void 0),io([I("#1a1a1a")],t.prototype,"borderColor",void 0),io([I(1)],t.prototype,"borderWidth",void 0),io([re({},$n)],t.prototype,"margin",void 0),io([I("")],t.prototype,"pathData",void 0),io([I("")],t.prototype,"content",void 0),io([I(0)],t.prototype,"cornerRadius",void 0),io([re({left:2,right:2,top:2,bottom:2},$n)],t.prototype,"padding",void 0),io([I("#1a1a1a")],t.prototype,"iconColor",void 0),t}(Ee),Kse=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),oT=function(n){function t(){var e=null!==n&&n.apply(this,arguments)||this;return e.orientation="Vertical",e.measureChildren=void 0,e.considerPadding=!0,e}return Kse(t,n),t.prototype.measure=function(e){return this.desiredSize=this.measureStackPanel(e,"Horizontal"===this.orientation?this.updateHorizontalStack:this.updateVerticalStack),this.desiredSize},t.prototype.arrange=function(e){return this.actualSize=this.arrangeStackPanel(e,"Horizontal"===this.orientation?this.arrangeHorizontalStack:this.arrangeVerticalStack),this.updateBounds(),this.actualSize},t.prototype.measureStackPanel=function(e,i){var r=void 0;if(void 0!==this.children&&this.children.length>0)for(var s=0,o=this.children;s0){var r=void 0,s=void 0;r=this.offsetX-e.width*this.pivot.x+this.padding.left,s=this.offsetY-e.height*this.pivot.y+this.padding.top;for(var o=0,a=this.children;o0)for(var i=0,r=this.children;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},aoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return ooe(t,n),Hh([I("Horizontal")],t.prototype,"orientation",void 0),Hh([I("Center")],t.prototype,"type",void 0),Hh([I(void 0)],t.prototype,"offset",void 0),Hh([I(!1)],t.prototype,"enableRouting",void 0),Hh([I([])],t.prototype,"children",void 0),Hh([I("")],t.prototype,"assistants",void 0),Hh([I("")],t.prototype,"level",void 0),Hh([I("")],t.prototype,"hasSubTree",void 0),Hh([I("")],t.prototype,"rows",void 0),t}(Ee),Li=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),q=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},loe=function(n){if(n)switch(n.type){case"Basic":default:return ab;case"Flow":return PF;case"Path":return NF;case"Image":return kF;case"Text":return Pd;case"Bpmn":return uT;case"Native":return lm;case"HTML":return OF;case"UmlActivity":return zF;case"UmlClassifier":return RF;case"SwimLane":return Hd}return ab},va=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),q([I("Basic")],t.prototype,"type",void 0),t}(Ee),NF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"Path"},q([I("Path")],t.prototype,"type",void 0),q([I("")],t.prototype,"data",void 0),t}(va),lm=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"Native"},q([I("Native")],t.prototype,"type",void 0),q([I("")],t.prototype,"content",void 0),q([I("Stretch")],t.prototype,"scale",void 0),t}(va),OF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"Html"},q([I("HTML")],t.prototype,"type",void 0),q([I("")],t.prototype,"content",void 0),t}(va),kF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"Image"},q([I("Image")],t.prototype,"type",void 0),q([I("")],t.prototype,"source",void 0),q([I("None")],t.prototype,"scale",void 0),q([I("None")],t.prototype,"align",void 0),t}(va),Pd=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"Text"},q([I("Text")],t.prototype,"type",void 0),q([I("")],t.prototype,"content",void 0),q([re({},$n)],t.prototype,"margin",void 0),t}(va),ab=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"BasicShape"},q([I("Basic")],t.prototype,"type",void 0),q([I("Rectangle")],t.prototype,"shape",void 0),q([I(0)],t.prototype,"cornerRadius",void 0),q([Bt([],z)],t.prototype,"points",void 0),t}(va),PF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"FlowShape"},q([I("Flow")],t.prototype,"type",void 0),q([I("Terminator")],t.prototype,"shape",void 0),t}(va),lT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"BpmnGateway"},q([I("None")],t.prototype,"type",void 0),t}(Ee),hT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"BpmnDataObject"},q([I("None")],t.prototype,"type",void 0),q([I(!1)],t.prototype,"collection",void 0),t}(Ee),hoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),q([I("None")],t.prototype,"type",void 0),q([I("None")],t.prototype,"loop",void 0),q([I(!1)],t.prototype,"call",void 0),q([I(!1)],t.prototype,"compensation",void 0),t}(Ee),cT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"BpmnEvent"},q([I("Start")],t.prototype,"event",void 0),q([I("None")],t.prototype,"trigger",void 0),t}(Ee),zd=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"BpmnSubEvent"},q([I("None")],t.prototype,"trigger",void 0),q([I("Start")],t.prototype,"event",void 0),q([I("")],t.prototype,"id",void 0),q([re({},z)],t.prototype,"offset",void 0),q([Bt([],Zn)],t.prototype,"annotations",void 0),q([Bt([],Es)],t.prototype,"ports",void 0),q([I()],t.prototype,"width",void 0),q([I()],t.prototype,"height",void 0),q([re({},$n)],t.prototype,"margin",void 0),q([I("Center")],t.prototype,"horizontalAlignment",void 0),q([I("Center")],t.prototype,"verticalAlignment",void 0),q([I(!0)],t.prototype,"visible",void 0),t}(Ee),coe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),q([re({id:"success",event:"End",offset:{x:1,y:.5}},zd)],t.prototype,"success",void 0),q([re({id:"failure",event:"Intermediate",trigger:"Error",offset:{x:.25,y:1}},zd)],t.prototype,"failure",void 0),q([re({id:"cancel",event:"Intermediate",trigger:"Cancel",offset:{x:.75,y:1}},zd)],t.prototype,"cancel",void 0),t}(Ee),doe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),q([I("None")],t.prototype,"type",void 0),q([I(!1)],t.prototype,"adhoc",void 0),q([I("Default")],t.prototype,"boundary",void 0),q([I(!1)],t.prototype,"compensation",void 0),q([I("None")],t.prototype,"loop",void 0),q([I(!0)],t.prototype,"collapsed",void 0),q([Bt([],zd)],t.prototype,"events",void 0),q([re({},coe)],t.prototype,"transaction",void 0),q([I(void 0)],t.prototype,"processes",void 0),t}(Ee),dT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"BpmnActivity"},q([I("Task")],t.prototype,"activity",void 0),q([re({},hoe)],t.prototype,"task",void 0),q([re({},doe)],t.prototype,"subProcess",void 0),t}(Ee),hm=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return Li(t,n),t.prototype.getClassName=function(){return"BpmnAnnotation"},q([I("")],t.prototype,"text",void 0),q([I("")],t.prototype,"id",void 0),q([I(0)],t.prototype,"angle",void 0),q([I()],t.prototype,"height",void 0),q([I()],t.prototype,"width",void 0),q([I(0)],t.prototype,"length",void 0),t}(Ee),uoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),q([I("")],t.prototype,"textAnnotationTarget",void 0),q([I("Auto")],t.prototype,"textAnnotationDirection",void 0),t}(Ee),uT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"BpmnShape"},q([I("Bpmn")],t.prototype,"type",void 0),q([I("Event")],t.prototype,"shape",void 0),q([re({},cT)],t.prototype,"event",void 0),q([re({},lT)],t.prototype,"gateway",void 0),q([re({},hT)],t.prototype,"dataObject",void 0),q([re({},dT)],t.prototype,"activity",void 0),q([re({},hm)],t.prototype,"annotation",void 0),q([Bt([],hm)],t.prototype,"annotations",void 0),q([re({},uoe)],t.prototype,"textAnnotation",void 0),t}(va),zF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"UmlActivityShape"},q([I("UmlActivity")],t.prototype,"type",void 0),q([I("Action")],t.prototype,"shape",void 0),t}(va),pT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"MethodArguments"},q([I("")],t.prototype,"name",void 0),q([I("")],t.prototype,"type",void 0),q([re({},Gp)],t.prototype,"style",void 0),t}(Ee),sf=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"UmlClassAttribute"},q([I("Public")],t.prototype,"scope",void 0),q([I(!1)],t.prototype,"isSeparator",void 0),q([re({fill:"#F9F9F9",strokeColor:"#CCCCCC"},Ll)],t.prototype,"separatorStyle",void 0),t}(pT),cm=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"UmlClassMethod"},q([Bt([],pT)],t.prototype,"parameters",void 0),t}(sf),lb=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"UmlClass"},q([I("")],t.prototype,"name",void 0),q([Bt([],sf)],t.prototype,"attributes",void 0),q([Bt([],cm)],t.prototype,"methods",void 0),q([re({},Gp)],t.prototype,"style",void 0),t}(Ee),fT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"UmlInterface"},q([I(!1)],t.prototype,"isSeparator",void 0),q([re({fill:"#F9F9F9",strokeColor:"#CCCCCC"},Ll)],t.prototype,"separatorStyle",void 0),t}(lb),hb=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"UmlEnumerationMember"},q([I("")],t.prototype,"name",void 0),q([I("")],t.prototype,"value",void 0),q([I(!1)],t.prototype,"isSeparator",void 0),q([re({fill:"#F9F9F9",strokeColor:"#CCCCCC"},Ll)],t.prototype,"separatorStyle",void 0),q([re({},Gp)],t.prototype,"style",void 0),t}(Ee),gT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"UmlEnumeration"},q([I("")],t.prototype,"name",void 0),q([Bt([],hb)],t.prototype,"members",void 0),q([re({},Gp)],t.prototype,"style",void 0),t}(Ee),RF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"UmlClassifierShape"},q([I("UmlClassifier")],t.prototype,"type",void 0),q([re({},lb)],t.prototype,"classShape",void 0),q([re({},fT)],t.prototype,"interfaceShape",void 0),q([re({},gT)],t.prototype,"enumerationShape",void 0),q([I("Class")],t.prototype,"classifier",void 0),t}(va),te=function(n){function t(e,i,r,s){var a,o=n.call(this,e,i,r,s)||this;return o.isCanvasUpdate=!1,o.status="None",o.parentId="",o.processId="",o.umlIndex=-1,o.outEdges=[],o.inEdges=[],o.isHeader=!1,o.isLane=!1,o.isPhase=!1,o.children&&o.children.length>0&&((!(a=r).style||!a.style.fill)&&(o.style.fill="transparent"),(!a.style||!a.style.strokeColor)&&(o.style.strokeColor="transparent")),o.shape&&"UmlActivity"===o.shape.type&&tb(r,o),o.shape&&"SwimLane"===o.shape.type&&pF(r,o),o.ports&&o.ports.length&&function vse(n){for(var t=0;t>";t=n;break;case"FinalNode":t=IF(e)}return t}(new Ke,i,this);break;case"Bpmn":if(e.bpmnModule){i=e.bpmnModule.initBPMNContent(i,this,e),this.wrapper.elementActions=this.wrapper.elementActions|Xr.ElementIsGroup;var v=this.shape.activity.subProcess;if(v.processes&&v.processes.length)for(var S=0,b=this.shape.activity.subProcess.processes;S>",margin:{left:10,right:10},id:"class",style:{fontSize:i.style.fontSize,color:i.style.color,fill:i.style.fill,textWrapping:r},offset:{x:.5,y:.3},constraints:Lr.ReadOnly}],constraints:(ie.Default|ie.HideThumbs)&~(ie.Rotate|ie.Drag|ie.Resize),verticalAlignment:"Stretch",horizontalAlignment:"Stretch",style:{fill:t.style.fill,strokeColor:"black"===t.style.strokeColor?"#ffffff00":t.style.strokeColor}},!0);return e.initObject(s),e.nodes.push(s),e.UpdateBlazorDiagramModel(s,"Node"),t.children.push(s.id),function toe(n,t,e,i){if("Enumeration"===n.shape.classifier){var r=e.members;if(r&&r.length){rf(n,t);for(var s="",o=0;o0)for(var o=0;o0&&s.phaseSize&&(i+=s.phaseSize,Xv(n,s.phaseSize)),s.lanes.length>0)for(o=0;o0){var a=0;for(o=0;o0&&"Horizontal"===r.orientation)for(l=0;l0&&(i+=r.phaseSize,o=qv(r.phaseSize),n.push(o)),a=0;a0&&o.phaseSize){for(var l=0;l0)for(l=0;l0?e.nameTable[this.nodes[0].id].wrapper:e.nameTable[this.connectors[0].id].wrapper,this.annotation.id);i.children.push(s)}else if(this.nodes||this.connectors){for(var o=0;o-1}function VF(n,t,e){n=[];for(var i=0,r=e.length;i0?c.getElementsByTagName("svg")[0].outerHTML:c.getElementsByTagName("g").length>0?c.getElementsByTagName("g")[0].outerHTML:"",s.shape.content=h,n.content=h,c.parentElement.removeChild(c)}l="nodeTemplate"}else a=s,l="annotationTemplate";var f=document.getElementById(n.diagramId).ej2_instances[0];if("string"!=typeof n.content&&"function"!=typeof n.content||n.isTemplate)if(n.isTemplate){if(v=void 0,v=f.isReact?n.getNodeTemplate()($(e),f,l+"_"+("nodeTemplate"===l?e.id:n.nodeId+e.id),void 0,void 0,!1,i):f.isVue||f.isVue3?n.getNodeTemplate()?n.getNodeTemplate()($(e),f,l+"_"+("nodeTemplate"===l?e.id:n.nodeId+e.id),void 0,void 0,!1,i):(v=ii("nodeTemplate"===l?f.nodeTemplate:f.annotationTemplate))($(e),f,l+"_"+("nodeTemplate"===l?e.id:n.nodeId+e.id),void 0,void 0,!1,i):n.getNodeTemplate()($(e),f,l+"_"+("nodeTemplate"===l?e.id:n.nodeId+e.id),void 0,void 0,!1))for(var M=0;M=1&&0===n.x&&("Clip"===i.textOverflow||"Ellipsis"===i.textOverflow)&&("Wrap"===i.textWrapping||"WrapWithOverflow"===i.textWrapping)&&(n.x=t[e-1]?t[e-1].x:-n.width/2),n.x}function QF(n,t,e,i){return e&&!t.template||t.template&&"function"==typeof t.template&&i.isReact?(n.isTemplate=!0,n.template=n.content=Bh(n,!0,t)):n.content=t.template,n}function Qe(){for(var e,t="",i=0;i<5;i++){if(typeof window<"u"&&"crypto"in window&&"getRandomValues"in crypto){var r=new Uint16Array(1);e=(window.msCrypto||window.crypto).getRandomValues(r)[0]%60}else e=Math.floor(61*Math.random());0===i&&e<10?i--:t+="0123456789ABCDEFGHIJKLMNOPQRSTUVWXTZabcdefghiklmnopqrstuvwxyz".substring(e,e+1)}return t}function GF(n){if(n)try{return"function"!=typeof n&&document.querySelectorAll(n).length?ii(document.querySelector(n).innerHTML.trim()):ii(n)}catch{return ii(n)}}function En(n){new Ne;var e=n.offsetY-n.actualSize.height*n.pivot.y,i=n.offsetY+n.actualSize.height*(1-n.pivot.y),r=n.offsetX-n.actualSize.width*n.pivot.x,s=n.offsetX+n.actualSize.width*(1-n.pivot.x);return Ne.toBounds([{x:r,y:e},{x:s,y:e},{x:r,y:i},{x:s,y:i}])}function yr(n){var t=new Ne,e=En(n),i=e.middleLeft,r=e.topCenter,s=e.bottomCenter,o=e.middleRight,a=e.topLeft,l=e.topRight,h=e.bottomLeft,c=e.bottomRight;if(n.corners={topLeft:a,topCenter:r,topRight:l,middleLeft:i,middleRight:o,bottomLeft:h,bottomCenter:s,bottomRight:c},0!==n.rotateAngle||0!==n.parentTransform){var d=Hi();qi(d,n.rotateAngle+n.parentTransform,n.offsetX,n.offsetY),n.corners.topLeft=a=Je(d,a),n.corners.topCenter=r=Je(d,r),n.corners.topRight=l=Je(d,l),n.corners.middleLeft=i=Je(d,i),n.corners.middleRight=o=Je(d,o),n.corners.bottomLeft=h=Je(d,h),n.corners.bottomCenter=s=Je(d,s),n.corners.bottomRight=c=Je(d,c)}return t=Ne.toBounds([a,l,h,c]),n.corners.left=t.left,n.corners.right=t.right,n.corners.top=t.top,n.corners.bottom=t.bottom,n.corners.center=t.center,n.corners.width=t.width,n.corners.height=t.height,t}function $(n,t,e,i){var r={},s="properties";if(n){e=n.propName;var l=[],h=[];if((l=l.concat(Object.keys(n[""+s]||n))).push("version"),e){var c=Zi(t);h=c?c(e):[],l=l.concat(h)}for(var d=function Ooe(n){switch(n){case"nodes":case"children":return["inEdges","outEdges","parentId","processId","nodeId","umlIndex","isPhase","isLane"];case"connectors":return["parentId"];case"annotation":case"annotations":return["nodeId"];case"shape":return["hasHeader"];case"layers":return["objectZIndex"]}return[]}(e),u=0,p=l=l.concat(d);u0&&(e=r),r=Math.floor(Poe(e,i)),s=Bc(o+=n.substr(e,r),t)}while(s<=t.width);for(o=o.substr(0,e),a=e;a=t.width){n=n.substr(0,o.length-1);break}return"Ellipsis"===t.textOverflow?(n=n.substr(0,n.length-3),n+="..."):n=n.substr(0,n.length),n}function MT(n,t){if("NoWrap"===t&&"PreserveAll"===n)return"pre";var e="";switch(n){case"CollapseAll":e="nowrap";break;case"CollapseSpace":e="pre-line";break;case"PreserveAll":e="pre-wrap"}return e}function wT(n,t){var e=Hi();qi(e,t,0,0);var i=Je(e,{x:0,y:0}),r=Je(e,{x:n.width,y:0}),s=Je(e,{x:0,y:n.height}),o=Je(e,{x:n.width,y:n.height}),a=Math.min(i.x,r.x,s.x,o.x),l=Math.min(i.y,r.y,s.y,o.y),h=Math.max(i.x,r.x,s.x,o.x),c=Math.max(i.y,r.y,s.y,o.y);return new me(h-a,c-l)}function xs(n,t,e,i){if(0!==n){var r=Hi();return qi(r,n,t,e),Je(r,i)}return i}function Zi(n){return void 0!==n&&"string"==typeof n&&(n=Y(n,window)),n}var bo=function(){function n(){}return n.getContext=function(t){return t.getContext("2d")},n.setCanvasSize=function(t,e,i){t&&(t.setAttribute("width",e.toString()),t.setAttribute("height",i.toString()))},n.prototype.renderGradient=function(t,e,i,r){var s,o,a;if("None"!==t.gradient.type){for(var l=0;l0?(w=0===S.r1?e.arc[parseInt(r.toString(),10)].r1:S.r1,C=0===S.r2?e.arc[parseInt(r.toString(),10)].r2:S.r2,r++):(w=S.r1,C=S.r2);var D=S.angle*(Math.PI/180),A=S.largeArc,x=S.sweep,R={x:u,y:p},L={x:Math.cos(D)*(M.x-R.x)/2+Math.sin(D)*(M.y-R.y)/2,y:-Math.sin(D)*(M.x-R.x)/2+Math.cos(D)*(M.y-R.y)/2},O=Math.pow(L.x,2)/Math.pow(w,2)+Math.pow(L.y,2)/Math.pow(C,2);O>1&&(w*=Math.sqrt(O),C*=Math.sqrt(O));var N=Math.pow(C,2)*Math.pow(L.x,2),T=(A===x?-1:1)*Math.sqrt((Math.pow(w,2)*Math.pow(C,2)-Math.pow(w,2)*Math.pow(L.y,2)-N)/(Math.pow(w,2)*Math.pow(L.y,2)+Math.pow(C,2)*Math.pow(L.x,2)));isNaN(T)&&(T=0);var P={x:T*w*L.y/C,y:T*-C*L.x/w},_={x:(M.x+R.x)/2+Math.cos(D)*P.x-Math.sin(D)*P.y,y:(M.y+R.y)/2+Math.sin(D)*P.x+Math.cos(D)*P.y},B=this.a([1,0],[(L.x-P.x)/w,(L.y-P.y)/C]),j=[(L.x-P.x)/w,(L.y-P.y)/C],Q=[(-L.x-P.x)/w,(-L.y-P.y)/C],oe=this.a(j,Q);this.r(j,Q)<=-1&&(oe=Math.PI),this.r(j,Q)>=1&&(oe=0);var pe=B+oe/2*(x?1:-1);if(Math.cos(pe),Math.sin(pe),S.centp=_,S.xAxisRotation=D,S.rx=w,S.ry=C,S.a1=B,S.ad=oe,S.sweep=x,null!=s){var De=w>C?w:C,xe=w>C?1:w/C,Ie=w>C?C/w:1;s.save(),s.translate(_.x,_.y),s.rotate(D),s.scale(xe,Ie),s.arc(0,0,De,B,B+oe,!x),s.scale(1/xe,1/Ie),s.rotate(-D),s.translate(-_.x,-_.y),s.restore()}break;case"Z":case"z":s.closePath(),u=o,p=a}o=u,a=p}}},n.prototype.drawText=function(t,e,i,r,s,o,a){if(e.content&&!0===e.visible){var l=n.getContext(t);l.save(),this.setStyle(t,e),o&&(e.fontSize*=o),this.rotateContext(t,e.angle,e.x+e.width*e.pivotX,e.y+e.height*e.pivotY),this.setFontStyle(t,e);var u,d=0;u=e.childNodes;var p=e.wrapBounds;if(l.fillStyle=e.color,p){var f=this.labelAlign(e,p,u);for(d=0;de.width&&"Wrap"!==e.textOverflow&&"NoWrap"===e.textWrapping&&(g.text=qF(g.text,e)),"Clip"!==e.textOverflow&&"Ellipsis"!==e.textOverflow||"Wrap"!==e.textWrapping?l.fillText(g.text,v,y):ya.actualSize.height+a.bounds.y&&(g.text=g.text.slice(0,g.text.length-3),g.text=g.text.concat("...")),l.fillText(g.text,v,y)),"Underline"===e.textDecoration||"Overline"===e.textDecoration||"LineThrough"===e.textDecoration){var M=v,w=void 0,D=v+l.measureText(g.text).width,A=void 0;switch(e.textDecoration){case"Underline":w=y+2,A=y+2;break;case"Overline":w=f.y+g.dy*d,A=f.y+g.dy*d;break;case"LineThrough":w=(y+f.y+g.dy*d)/2+2,A=(y+f.y+g.dy*d)/2+2}l.beginPath(),l.moveTo(M,w),l.lineTo(D,A),l.strokeStyle=e.color,l.lineWidth=.08*e.fontSize,l.globalAlpha=e.opacity,l.stroke()}}}l.restore()}},n.prototype.loadImage=function(t,e,i,r,s){this.rotateContext(i,e.angle,r,s);var o=new Image;o.src=e.source,this.image(t,o,e.x,e.y,e.width,e.height,e)},n.prototype.drawImage=function(t,e,i,r){var s=this;if(e.visible){var o=n.getContext(t);o.save();var a=e.x+e.width*e.pivotX,l=e.y+e.height*e.pivotY,h=new Image;h.src=e.source,o.canvas.id.split("_"),r?h.onload=function(){s.loadImage(o,e,t,a,l)}:this.loadImage(o,e,t,a,l),o.restore()}},n.prototype.image=function(t,e,i,r,s,o,a){t.beginPath();var l=e.width,h=e.height,c=s,d=o,u=0,p=0;if(a&&"None"!==a.alignment){var f=a.alignment.toLowerCase().substr(1,3),g=a.alignment.toLowerCase().substr(5,3);if("Slice"===a.scale){var v=function(){u=c,p=h*c/l},y=function(){u=l*d/h,p=d};c>d?(v(),d>p&&y()):c===d?l>h?y():v():(y(),c>u&&v());var S=this.getSliceOffset(f,u,c,l),b=this.getSliceOffset(g,p,d,h),M=l-S,w=h-b,C=u-S*(u/l),D=p-b*(p/h),A=Tt("canvas",{width:s.toString(),height:o.toString()});A.getContext("2d").drawImage(e,S,b,M,w,0,0,C,D),t.drawImage(A,i,r,s,o)}else if("Meet"===a.scale){var R=h/l,L=d/c;p=L>R?c*R:d,i+=this.getMeetOffset(f,u=L>R?c:d/R,c),r+=this.getMeetOffset(g,p,d),t.drawImage(e,0,0,l,h,i,r,u,p)}else t.drawImage(e,i,r,s,o)}else if("None"!==a.flip){var O=1,N=1;("Horizontal"===a.flip||"Both"===a.flip)&&(i=-i,s=-s,O=-1),("Vertical"===a.flip||"Both"===a.flip)&&(r=-r,o=-o,N=-1),t.scale(O,N),t.drawImage(e,i,r,s,o)}else t.drawImage(e,i,r,s,o);t.closePath()},n.prototype.getSliceOffset=function(t,e,i,r){switch(t){case"min":default:return 0;case"mid":return(e-i)/2*r/e;case"max":return(e-i)*r/e}},n.prototype.getMeetOffset=function(t,e,i){var r=Math.max(e,i),s=Math.min(e,i);switch(t){case"min":default:return 0;case"mid":return(r-s)/2;case"max":return r-s}},n.prototype.m=function(t){return Math.sqrt(Math.pow(t[0],2)+Math.pow(t[1],2))},n.prototype.r=function(t,e){return(t[0]*e[0]+t[1]*e[1])/(this.m(t)*this.m(e))},n.prototype.a=function(t,e){return(t[0]*e[1]t.width&&("Ellipsis"===t.textOverflow||"Clip"===t.textOverflow)&&"NoWrap"===t.textWrapping?0:.5*t.width:"right"===t.textAlign&&(c=1*t.width),s.x=t.x+c+(e?e.x:0),s.y=a+d-r.height/2,s},n}(),fb=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Vi=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Roe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return fb(t,n),Vi([I("")],t.prototype,"source",void 0),Vi([I("transparent")],t.prototype,"color",void 0),Vi([I("None")],t.prototype,"scale",void 0),Vi([I("None")],t.prototype,"align",void 0),t}(Ee),Hoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return fb(t,n),Vi([I("Page")],t.prototype,"mode",void 0),Vi([I("PageSettings")],t.prototype,"region",void 0),Vi([re({top:25,bottom:25,left:25,right:25},$n)],t.prototype,"margin",void 0),Vi([I(!1)],t.prototype,"canZoomIn",void 0),Vi([I(void 0)],t.prototype,"customBounds",void 0),Vi([I(!1)],t.prototype,"canFit",void 0),t}(Ee),Boe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return fb(t,n),Vi([I(null)],t.prototype,"width",void 0),Vi([I(null)],t.prototype,"height",void 0),Vi([re({},$n)],t.prototype,"margin",void 0),Vi([I("Landscape")],t.prototype,"orientation",void 0),Vi([I("Infinity")],t.prototype,"boundaryConstraints",void 0),Vi([re({},Roe)],t.prototype,"background",void 0),Vi([I(!1)],t.prototype,"multiplePage",void 0),Vi([I(!1)],t.prototype,"showPageBreaks",void 0),Vi([re({},Hoe)],t.prototype,"fitOptions",void 0),t}(Ee),Foe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return fb(t,n),Vi([I(0)],t.prototype,"horizontalOffset",void 0),Vi([I(0)],t.prototype,"verticalOffset",void 0),Vi([I(1)],t.prototype,"currentZoom",void 0),Vi([I(0)],t.prototype,"viewPortWidth",void 0),Vi([I(0)],t.prototype,"viewPortHeight",void 0),Vi([I(.2)],t.prototype,"minZoom",void 0),Vi([I(30)],t.prototype,"maxZoom",void 0),Vi([I("Diagram")],t.prototype,"scrollLimit",void 0),Vi([I()],t.prototype,"scrollableArea",void 0),Vi([I(!1)],t.prototype,"canAutoScroll",void 0),Vi([I(100)],t.prototype,"autoScrollFrequency",void 0),Vi([re({left:15,right:15,top:15,bottom:15},$n)],t.prototype,"autoScrollBorder",void 0),Vi([re({left:0,right:0,top:0,bottom:0},$n)],t.prototype,"padding",void 0),Vi([I(.2)],t.prototype,"zoomFactor",void 0),t}(Ee),_oe=function(){function n(){this.services={}}return n.prototype.register=function(t,e){this.services[""+t]=e},n.prototype.getService=function(t){return this.services[""+t]},n}(),$F=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),ma=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},ZF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return $F(t,n),ma([I("lightgray")],t.prototype,"lineColor",void 0),ma([I("")],t.prototype,"lineDashArray",void 0),ma([I([1.25,18.75,.25,19.75,.25,19.75,.25,19.75,.25,19.75])],t.prototype,"lineIntervals",void 0),ma([I([1,19,.5,19.5,.5,19.5,.5,19.5,.5,19.5])],t.prototype,"dotIntervals",void 0),ma([I([20])],t.prototype,"snapIntervals",void 0),t}(Ee),Uoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return $F(t,n),ma([re({},ZF)],t.prototype,"horizontalGridlines",void 0),ma([re({},ZF)],t.prototype,"verticalGridlines",void 0),ma([I(Kt.All)],t.prototype,"constraints",void 0),ma([I(5)],t.prototype,"snapAngle",void 0),ma([I("Lines")],t.prototype,"gridType",void 0),ma([I(5)],t.prototype,"snapObjectDistance",void 0),ma([I("#07EDE1")],t.prototype,"snapLineColor",void 0),t}(Ee),JF=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Ja=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},KF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return JF(t,n),Ja([I(5)],t.prototype,"interval",void 0),Ja([I(100)],t.prototype,"segmentWidth",void 0),Ja([I("Horizontal")],t.prototype,"orientation",void 0),Ja([I("RightOrBottom")],t.prototype,"tickAlignment",void 0),Ja([I("red")],t.prototype,"markerColor",void 0),Ja([I(25)],t.prototype,"thickness",void 0),Ja([I(null)],t.prototype,"arrangeTick",void 0),t}(Ee),joe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return JF(t,n),Ja([I(!1)],t.prototype,"showRulers",void 0),Ja([I(!0)],t.prototype,"dynamicGrid",void 0),Ja([re({orientation:"Horizontal"},KF)],t.prototype,"horizontalRuler",void 0),Ja([re({orientation:"Vertical"},KF)],t.prototype,"verticalRuler",void 0),t}(Ee),Voe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),e_=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Woe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Voe(t,n),e_([I("")],t.prototype,"property",void 0),e_([I("")],t.prototype,"field",void 0),t}(Ee),CT=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),ln=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},t_=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return CT(t,n),ln([I("")],t.prototype,"read",void 0),ln([I("")],t.prototype,"create",void 0),ln([I("")],t.prototype,"update",void 0),ln([I("")],t.prototype,"destroy",void 0),ln([I()],t.prototype,"customFields",void 0),t}(Ee),Yoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return CT(t,n),ln([I("")],t.prototype,"id",void 0),ln([I("")],t.prototype,"sourceID",void 0),ln([I("")],t.prototype,"targetID",void 0),ln([I(null)],t.prototype,"sourcePointX",void 0),ln([I(null)],t.prototype,"sourcePointY",void 0),ln([I(null)],t.prototype,"targetPointX",void 0),ln([I(null)],t.prototype,"targetPointY",void 0),ln([I(null)],t.prototype,"dataManager",void 0),ln([re({},t_)],t.prototype,"crudAction",void 0),t}(Ee),Qoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return CT(t,n),ln([I("")],t.prototype,"id",void 0),ln([I(null)],t.prototype,"dataManager",void 0),ln([I(null)],t.prototype,"dataSource",void 0),ln([I("")],t.prototype,"root",void 0),ln([I("")],t.prototype,"parentId",void 0),ln([I()],t.prototype,"doBinding",void 0),ln([Bt([],Woe)],t.prototype,"dataMapSettings",void 0),ln([re({},t_)],t.prototype,"crudAction",void 0),ln([re({},Yoe)],t.prototype,"connectionDataSource",void 0),t}(Ee),i_=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Cr=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Goe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return i_(t,n),Cr([I("LeftInFlow")],t.prototype,"yesBranchDirection",void 0),Cr([I("RightInFlow")],t.prototype,"noBranchDirection",void 0),Cr([I(["Yes","True"])],t.prototype,"yesBranchValues",void 0),Cr([I(["No","False"])],t.prototype,"noBranchValues",void 0),t}(Ee),Xoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return i_(t,n),Cr([I("")],t.prototype,"fixedNode",void 0),Cr([I(30)],t.prototype,"horizontalSpacing",void 0),Cr([I("SamePoint")],t.prototype,"connectionPointOrigin",void 0),Cr([I("Nonlinear")],t.prototype,"arrangement",void 0),Cr([I(30)],t.prototype,"verticalSpacing",void 0),Cr([I(30)],t.prototype,"maxIteration",void 0),Cr([I(40)],t.prototype,"springFactor",void 0),Cr([I(50)],t.prototype,"springLength",void 0),Cr([re({left:50,top:50,right:0,bottom:0},$n)],t.prototype,"margin",void 0),Cr([I("Auto")],t.prototype,"horizontalAlignment",void 0),Cr([I("Auto")],t.prototype,"verticalAlignment",void 0),Cr([I("TopToBottom")],t.prototype,"orientation",void 0),Cr([I("Auto")],t.prototype,"connectionDirection",void 0),Cr([I("Default")],t.prototype,"connectorSegments",void 0),Cr([I("None")],t.prototype,"type",void 0),Cr([I()],t.prototype,"getLayoutInfo",void 0),Cr([I()],t.prototype,"layoutInfo",void 0),Cr([I()],t.prototype,"getBranch",void 0),Cr([I()],t.prototype,"bounds",void 0),Cr([I(!0)],t.prototype,"enableAnimation",void 0),Cr([I(!1)],t.prototype,"enableRouting",void 0),Cr([I("")],t.prototype,"root",void 0),Cr([re({},Goe)],t.prototype,"flowchartLayoutSettings",void 0),t}(Ee),qoe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),r_=function(n){function t(e,i){var r=n.call(this,e,!0)||this;return r.oldValue=null,r.endPoint=i,r}return qoe(t,n),t.prototype.mouseDown=function(e){var i,r=!0;if(e.source&&e.source.connectors&&(i=e.source.connectors[0]),e.info&&e.actualObject&&(r=e.info.ctrlKey&&"Orthogonal"!==e.actualObject.type),i&&r){this.inAction=!0,this.undoElement=$(e.source),n.prototype.mouseDown.call(this,e);for(var s=0;s0)1!==s&&this.removePrevSegment(i,s);else if(a){var l=z.distancePoints(a.points[0],a.points[1]);Math.abs(a.length||0===a.length?a.length:l)<=5&&this.removeNextSegment(i,s)}this.commandHandler.updateEndPoint(i,r),i.selectedSegmentIndex=0}if(this.undoElement){var c=$(e.source);this.commandHandler.addHistoryEntry({type:"SegmentChanged",redoObject:c,undoObject:this.undoElement,category:"Internal"})}if(i.isBezierEditing&&(i.isBezierEditing=!1),this.prevPosition!==this.startPosition){var u={source:i,state:"Completed",oldValue:this.oldValue,newValue:$(this.selectedSegment),cancel:!1,segment:this.selectedSegment};this.commandHandler.triggerEvent(Ce.segmentChange,u)}n.prototype.mouseUp.call(this,e)},t.prototype.removePrevSegment=function(e,i){var r=e.segments[i-2],s=e.segments[i+1];if(s&&!((s.length||0===s.length?s.length:z.distancePoints(s.points[0],s.points[1]))<=5)){var a=e.segments.slice(i-1,i+1),l={element:e,removeSegments:a,type:"Removal",cancel:!1};if(this.commandHandler.triggerEvent(Ce.segmentCollectionChange,l),!l.cancel){var h=e.segments[i+1];e.segments.splice(i-1,2);var c=this.selectedSegment;"Left"===c.direction||"Right"===c.direction?(r.points[r.points.length-1].x=h.points[0].x,h.points[0].y=r.points[r.points.length-1].y):(r.points[r.points.length-1].y=h.points[0].y,h.points[0].x=r.points[r.points.length-1].x),(c.length||0===c.length)&&this.findSegmentDirection(r),this.findSegmentDirection(h)}}},t.prototype.findSegmentDirection=function(e){e.direction&&(e.length||0===e.length)&&(e.length=z.distancePoints(e.points[0],e.points[e.points.length-1]),e.direction=z.direction(e.points[0],e.points[e.points.length-1]))},t.prototype.removeNextSegment=function(e,i){var l,h,r=this.selectedSegment,s=e.segments[i-1],o=e.segments[i+2],a=e.segments[i+1];if(a.length||0===a.length?(l=e.segments.slice(i,2),h={element:e,removeSegments:l,type:"Removal",cancel:!1},this.commandHandler.triggerEvent(Ce.segmentCollectionChange,h={element:e,removeSegments:l,type:"Removal",cancel:!1}),h.cancel||(e.segments.splice(i,2),"Top"===r.direction||"Bottom"===r.direction?(o.points[0].y=r.points[0].y,s.points[s.points.length-1].x=o.points[0].x):(o.points[0].x=r.points[0].x,s.points[s.points.length-1].y=o.points[0].y))):(l=e.segments.slice(i+1,1),this.commandHandler.triggerEvent(Ce.segmentCollectionChange,h={element:e,removeSegments:l,type:"Removal",cancel:!1}),h.cancel||(e.segments.splice(i+1,1),"Top"===r.direction||"Bottom"===r.direction?s.points[s.points.length-1].x=a.points[a.points.length-1].x:s.points[s.points.length-1].y=a.points[a.points.length-1].y,this.findSegmentDirection(s),r.length=r.direction=null)),s&&o&&!h.cancel&&(s.length=z.distancePoints(s.points[0],o.points[0]),s.direction=z.direction(s.points[0],o.points[0]),o.length||0===o.length)){o.length=z.distancePoints(s.points[s.points.length-1],o.points[o.points.length-1]);var c=s.points,d=o.points;o.direction=z.direction(c[c.length-1],d[d.length-1])}},t.prototype.addOrRemoveSegment=function(e,i,r){for(var s,o,a=[],l={segments:e.segments},h=0;h0?"Bottom":"Top":r>0?"Right":"Left",length:i.points[0].x===i.points[1].x?s:r},!0)),l.push(new bi(e,"segments",{type:"Orthogonal",direction:c,length:h/2},!0));var p={element:e,addSegments:l,type:"Addition",cancel:!1};return this.commandHandler.triggerEvent(Ce.segmentCollectionChange,p),p.cancel||(e.segments=l.concat(e.segments),a=o+2),a},t.prototype.insertFirstSegment=function(e,i,r,s,o){var a,l,d,u,h=[];if(e.sourcePortID&&i.length&&e.segments[0].points.length>2)for(var p=void 0,f=0;f0?"Bottom":"Top":r>0?"Right":"Left"),p=u,h.push(u)}else h.push(new bi(e,"segments",{type:"Orthogonal",direction:i.direction,length:i.length/3},!0)),"Bottom"===i.direction||"Top"===i.direction?(l=Math.abs(r),a=r>0?"Right":"Left"):(l=Math.abs(s),a=s>0?"Bottom":"Top"),u=new bi(e,"segments",{type:"Orthogonal",direction:a,length:l},!0),h.push(u);var y={element:e,addSegments:h,type:"Addition",cancel:!1};if(this.commandHandler.triggerEvent(Ce.segmentCollectionChange,y),!y.cancel){if(e.sourcePortID&&i.length&&e.segments[0].points.length>2)e.segments.splice(0,1),d=1;else{var S=e.segments[1];S&&S.length&&(S.length=a!==S.direction?S.length+l:S.length-l),d=2,i.length=2*i.length/3}e.segments=h.concat(e.segments)}return d},t.prototype.updateAdjacentSegments=function(e,i,r,s){var o=e.segments[parseInt(i.toString(),10)],a=o.points[o.points.length-1],h=!0;"Orthogonal"===o.type&&(o.points[0]=o.points[0],o.points[o.points.length-1]=a,e.segments[i-1]&&(h=this.updatePreviousSegment(r,s,e,i)),e.segments.length-1>i&&h&&this.updateNextSegment(e,o,e.segments[i+1],r,s))},t.prototype.addTerminalSegment=function(e,i,r,s,o){var l,h,c,d,a=e.segments.indexOf(i),u=[],p=e.segments.pop(),f=e.segments[e.segments.length-1];l=f&&"Orthogonal"===f.type?f:null;for(var g=0;g0&&"Left"===o.direction?c.middleLeft:c.middleRight,o.length>c.width/2?Math.abs(a.length)0&&"Top"===o.direction?c.topCenter:c.bottomCenter,o.length>c.height/2?Math.abs(a.length)1)for(var a=0,l=this.diagram.views;a0)for(var e=t===Ce.onUserHandleMouseLeave?this.previousAction:this.action,i={element:void 0},r=0;r0)for(var r={element:void 0},s=void 0,o=void 0,a=0;a-1&&(o=s,this.previousTarget=i,this.targetItem=e),o===e.fixedUserHandles[parseInt(a.toString(),10)].id&&(r.element=e.fixedUserHandles[parseInt(a.toString(),10)],this.userHandle(t,a,r,e))},n.prototype.mouseDown=function(t){if(!0!==this.inAction||!(this.tool instanceof GI||this.tool instanceof pa)){this.focus=!0;var e=t.touches,i=!!document.getElementsByClassName("e-dragclone")[0];if(this.isMouseOnScrollBar(t)&&!i)return this.isScrolling=!0,void t.preventDefault();if(this.checkFixedUserHandleEvent(Ce.onFixedUserHandleMouseDown,this.targetItem,this.previousTarget),this.checkUserHandleEvent(Ce.onUserHandleMouseDown),!this.checkEditBoxAsTarget(t)&&Vv(this.diagram)||Lc(this.diagram)&&!BI(this.diagram))if(("Select"===this.action||"Drag"===this.action)&&this.diagram.updatePortVisibility(this.hoverElement,hi.Hover,!0),!(this.tool instanceof Ph||this.tool instanceof zh)||2!==t.button&&2!==t.buttons)if(!0===this.inAction&&!0===this.isMouseDown&&(this.tool instanceof Ph||this.tool instanceof zh))this.isMouseDown=!0,this.eventArgs={},this.getMouseEventArgs(this.currentPosition,this.eventArgs),this.eventArgs.position=this.currentPosition,this.tool.mouseDown(this.eventArgs);else{this.isMouseDown=!0,this.currentPosition=this.prevPosition=this.getMousePosition(t),this.eventArgs={},this.diagram.textEditing&&!this.isMouseOnScrollBar(t)&&(this.diagram.endEdit(),this.diagram.textEditing=!1,"Canvas"===this.diagram.mode&&1!==this.diagram.scroller.currentZoom&&this.diagram.refreshDiagramLayer());var s=this.getTargetElement();this.action=this.diagram.findActionToBeDone(s.obj,s.sourceElement,this.currentPosition,s.target);var o=this.isMetaKey(t);o&&t.shiftKey&&this.diagram.connectorEditingToolModule?this.action="SegmentEnd":(o||t.shiftKey)&&(Uv(this.diagram)||jv(this.diagram))&&(this.action="Select"),this.tool=this.diagram.getTool(this.action),this.tool||(this.action="Select",this.tool=this.diagram.getTool(this.action)),this.getMouseEventArgs(this.currentPosition,this.eventArgs),(o||t.shiftKey)&&(this.eventArgs.info=o&&t.shiftKey?{ctrlKey:o,shiftKey:t.shiftKey}:{ctrlKey:!0}),this.eventArgs.position=this.currentPosition;var l=this.diagram.selectedItems.nodes;if(this.tool.mouseDown(this.eventArgs),this.diagram.selectedItems.canToggleSelection&&l&&this.diagram.selectedItems.nodes&&this.tool instanceof ua)for(var h=0;h=2&&(this.touchStartList=VF(this.touchStartList,0,e)),e||t.preventDefault())}else this.inAction=!1,this.tool.mouseUp(this.eventArgs);!this.isForeignObject(t.target)&&!this.isForeignObject(t.target,!0)&&!e&&t.preventDefault()}},n.prototype.mouseMoveExtend=function(t,e){(this.tool instanceof Ph||this.tool instanceof zh)&&this.tool.mouseMove(this.eventArgs),this.diagram.scrollSettings.canAutoScroll?this.checkAutoScroll(t):this.blocked||this.tool.mouseMove(this.eventArgs),this.eventArgs.target&&(this.hoverElement=this.eventArgs.target);var i=!((this.eventArgs.target instanceof te||this.eventArgs.target instanceof de)&&(e instanceof te||e instanceof de));this.tool instanceof Od&&this.diagram.updatePortVisibility(this.hoverElement instanceof te||this.hoverElement instanceof de?this.hoverElement:this.hoverNode,hi.Connect|hi.Hover,i),this.hoverElement instanceof te&&this.hoverNode instanceof te&&this.hoverNode&&this.hoverNode.id!==this.hoverElement.id&&this.diagram.updatePortVisibility(this.hoverNode,hi.Connect|hi.Hover,!0),this.hoverElement instanceof de&&this.hoverElement.ports.length>0&&this.diagram.updatePortVisibility(this.hoverElement,hi.Connect|hi.Hover,!0),this.previousElement instanceof te&&this.hoverElement&&this.previousElement.id!==this.hoverElement.id&&this.diagram.updatePortVisibility(this.previousElement,hi.Connect|hi.Hover,!0),this.previousElement=this.hoverElement,""!==this.diagram.tooltip.content&&(this.hoverElement=null),this.hoverNode=i?null:e},n.prototype.checkAction=function(t){if("LabelSelect"===this.action&&this.eventArgs.sourceWrapper&&(this.eventArgs.sourceWrapper instanceof ni||this.eventArgs.sourceWrapper instanceof Jn)){var e=this.commandHandler.findTarget(this.eventArgs.sourceWrapper,this.eventArgs.source);!_r(this.diagram,e,!1,this.eventArgs.sourceWrapper)&&to(e)&&(this.action="LabelDrag",this.tool=this.getTool(this.action),this.tool.mouseDown(this.initialEventArgs))}else to(t)&&Dd(t)&&this.initialEventArgs&&this.initialEventArgs.source&&"Select"===this.action&&(!_r(this.diagram,this.eventArgs.source,!1)&&this.eventArgs.source instanceof si&&this.getMouseEventArgs(this.currentPosition,this.eventArgs),(!(t instanceof de)||t instanceof de&&!(wr(this.currentPosition,t.sourcePoint,t.hitPadding)||wr(this.currentPosition,t.targetPoint,t.hitPadding)))&&(this.action="Drag"),this.tool=this.getTool(this.action),this.tool.mouseDown(this.initialEventArgs))},n.prototype.isSwimlaneElements=function(t){return!(t&&(t.isLane||t.isPhase||t.isHeader))},n.prototype.mouseMove=function(t,e){if(this.focus=!0,this.isScrolling)t.preventDefault();else if(Vv(this.diagram)||Lc(this.diagram)&&!BI(this.diagram)){this.currentPosition=this.getMousePosition(t);var i=this.diagram.findObjectsUnderMouse(this.currentPosition),r=this.diagram.findObjectUnderMouse(i,this.action,this.inAction);!function nse(n,t){n.rulerSettings.showRulers&&(n.hRuler.drawRulerMarker(n.hRuler.element,t,n.scroller.horizontalOffset),n.vRuler.drawRulerMarker(n.vRuler.element,t,n.scroller.verticalOffset))}(this.diagram,this.currentPosition);var s=!1,o=void 0;if("touchmove"===t.type&&(e=t.touches)&&e.length>1&&(this.touchMoveList=VF(this.touchMoveList,0,e),"PinchZoom"!==this.action&&(s=!0)),!1===z.equals(this.currentPosition,this.prevPosition)||this.inAction){if(!1===this.isMouseDown||s){this.eventArgs={};var a=null,l=void 0;if(null!==r){if((a=this.diagram.findElementUnderMouse(r,this.currentPosition,this.diagram))&&(l=this.commandHandler.findTarget(a,r)),(l instanceof Zn||l instanceof Nr)&&(l.tooltip&&""!==l.tooltip.content||(l=r)),l!==this.hoverElement){var h=this.getContent();this.hoverElement&&"Auto"===this.hoverElement.tooltip.openOn&&""!==h&&this.elementLeave(),this.diagram.updatePortVisibility(this.hoverElement,hi.Hover,!0),r instanceof te&&(this.hoverNode=r);var c=!0;!this.isSwimlaneElements(r)&&this.hoverElement&&this.isSwimlaneElements(this.hoverElement)&&(c=!1),this.hoverElement=c?r:this.hoverElement;var d,u=void 0;(d=this.diagram.findElementUnderMouse(r,this.currentPosition,this.diagram))instanceof Ke&&((u=this.commandHandler.findTarget(d,r))instanceof Es||u instanceof xc)&&this.hoverElement.constraints&ri.ToolTip&&(this.hoverElement=u);var p=void 0;d instanceof ni&&((p=this.commandHandler.findTarget(d,r))instanceof Zn||p instanceof Nr)&&p.constraints&Lr.Tooltip&&(this.hoverElement=p),c?this.elementEnter(this.currentPosition,!1):this.hoverElement=r}else this.hoverElement&&this.hoverElement===l&&this.hoverElement.tooltip.content&&void 0!==this.diagram.tooltipObject&&"Mouse"===this.hoverElement.tooltip.relativeMode&&this.setTooltipOffset(this.currentPosition);a&&(o=this.commandHandler.findTarget(a,r))}this.action=this.diagram.findActionToBeDone(r,a,this.currentPosition,o),this.checkFixedUserHandleEvent(Ce.onFixedUserHandleMouseEnter,r,a),this.checkUserHandleEvent(Ce.onUserHandleMouseEnter),this.checkPreviousAction(),this.getMouseEventArgs(this.currentPosition,this.eventArgs),this.tool=this.getTool(this.action),this.mouseEvents(),this.tool instanceof pa||this.tool instanceof zh||this.tool instanceof Ph?this.tool.mouseMove(this.eventArgs):e&&this.tool instanceof Kv&&this.tool.mouseDown(this.eventArgs),this.updateCursor(),this.renderUmlHighLighter(this.eventArgs);var f=!1;this.hoverElement&&!(this.tool instanceof Kv)&&r instanceof te&&this.isSwimlaneElements(r)&&(0===this.diagram.selectedItems.nodes.length||!_r(this.diagram,this.hoverElement))||this.hoverElement instanceof de||(f=!0),this.hoverElement&&!(this.tool instanceof Kv)&&r instanceof de&&(0===this.diagram.selectedItems.connectors.length||!_r(this.diagram,this.hoverElement))||this.hoverElement instanceof te||(f=!0),this.diagram.updatePortVisibility(this.hoverElement,hi.Hover,f);var g=this.getContent();null===r&&this.hoverElement&&"Auto"===this.hoverElement.tooltip.openOn&&g&&(this.hoverElement=null,this.elementLeave()),s=!1}else{this.eventArgs.position=this.currentPosition,"Drag"===this.action&&!_r(this.diagram,this.eventArgs.source,!1)&&this.eventArgs.source instanceof si&&this.getMouseEventArgs(this.currentPosition,this.eventArgs),this.mouseEvents(),(t.ctrlKey||t.shiftKey)&&(this.eventArgs.info=t.ctrlKey&&t.shiftKey?{ctrlKey:t.ctrlKey,shiftKey:t.shiftKey}:{ctrlKey:!0}),this.checkAction(r);var y=this.getConnectorPadding(this.eventArgs);this.getMouseEventArgs(this.currentPosition,this.eventArgs,this.eventArgs.source,y),this.updateCursor(),this.inAction=!0,this.initialEventArgs=null,("Drag"===this.action||"Rotate"===this.action)&&(this.diagram.diagramActions=this.diagram.diagramActions|ee.Interactions);var S=this.diagram.scroller.getPageBounds();this.mouseMoveExtend(t,r);var b=this.diagram.scroller.getPageBounds();if(r&&(S.width!==b.width||S.height!==b.height||S.x!==b.x||S.y!==b.y)&&this.diagram.views&&this.diagram.views.overview){var M=this.diagram.views.overview;M.updateView(M)}}this.prevPosition=this.currentPosition,this.isForeignObject(t.target,!0)||t.preventDefault()}}},n.prototype.getContent=function(){var i,t=this.hoverElement instanceof te&&this.hoverElement.constraints&ie.Tooltip||this.hoverElement instanceof de&&this.hoverElement.constraints&qe.Tooltip||(this.hoverElement instanceof Es||this.hoverElement instanceof xc)&&this.hoverElement.constraints&ri.ToolTip||(this.hoverElement instanceof Zn||this.hoverElement instanceof Nr)&&this.hoverElement.constraints&Lr.Tooltip,e=this.hoverElement;e instanceof te&&e.children&&e.children.length>0&&(i=this.findIntersectChild(e));var r=t?this.hoverElement.tooltip.content:this.diagram.tooltip.content;return i?i.tooltip.content:r},n.prototype.findIntersectChild=function(t){for(var e,i=new Ne(this.currentPosition.x,this.currentPosition.y,8,8),r=0;r1&&1===t.which&&!function one(n){return!!(n&ee.PreventClearSelection)}(this.diagram.diagramActions)&&(c=!1,this.commandHandler.clearSelection()),(!_r(this.diagram,h)||!c)&&(this.commandHandler.selectObjects([h],void 0,a),this.diagram.selectedItems.canToggleSelection)){var d=this.diagram.selectedItems.nodes;d?d[0].parentObj instanceof Rd&&(s=!0):this.diagram.selectedItems.connectors.length>0&&(s=!0)}}var u=!1,p=this.updateContainerProperties(),f=void 0;if(this.addUmlNode(),this.inAction=!1,this.isMouseDown=!1,this.diagram.selectedObject.helperObject&&(f=this.updateContainerBounds()),this.tool&&(this.tool.prevPosition||this.tool instanceof eF)){this.eventArgs.position=this.currentPosition;var g=this.getConnectorPadding(this.eventArgs);this.getMouseEventArgs(this.currentPosition,this.eventArgs,this.eventArgs.source,g);var v=this.isMetaKey(t);if((v||t.shiftKey)&&(this.eventArgs.info=v&&t.shiftKey?{ctrlKey:v,shiftKey:t.shiftKey}:{ctrlKey:!0}),this.diagram.diagramActions&ee.Interactions&&(this.diagram.diagramActions=this.diagram.diagramActions&~ee.Interactions),this.eventArgs.clickCount=t.detail,this.diagram.selectedObject.helperObject&&(this.tool instanceof ua||this.tool instanceof kd)){if(this.diagram.selectedObject.actualObject&&""!==this.diagram.selectedObject.actualObject.parentId){var S=this.diagram.getObject(this.diagram.selectedObject.actualObject.parentId);S&&S.isLane&&(this.commandHandler.isContainer=!0)}(u=this.diagram.lineRoutingModule&&this.diagram.nameTable.helper&&this.eventArgs.target&&this.eventArgs.target.isLane&&(this.eventArgs.source instanceof si&&this.eventArgs.source.nodes.length>0&&""===this.eventArgs.source.nodes[0].parentId||""===this.eventArgs.source.parentId))&&(this.diagram.diagramActions=this.diagram.diagramActions|ee.PreventLaneContainerUpdate),this.tool.mouseUp(this.eventArgs,p.isPreventHistory)}else{if(this.diagram.selectedItems.canToggleSelection){var b=void 0,M=void 0;if(this.diagram.selectedItems.nodes.length>0)for(var w=0;w1&&D[0].id===i[parseInt(w.toString(),10)].id||r.length>0)&&(M=!0);!this.isSwimlaneSelected&&!s&&!M&&this.tool instanceof ua&&"Select"===this.currentAction&&(!b||this.diagram.selectedItems.connectors.length>0)&&this.commandHandler.clearSelection(!0)}this.isSwimlaneSelected=!1,this.tool.mouseUp(this.eventArgs),this.diagram.checkMenu&&(-1!==window.navigator.userAgent.indexOf("Linux")||-1!==window.navigator.userAgent.indexOf("X11"))&&(!t.pageY&&t instanceof TouchEvent&&t.changedTouches?(window.getSelection().removeAllRanges(),this.diagram.contextMenuModule.contextMenu.open(t.changedTouches[0].pageY,t.changedTouches[0].pageX,this.diagram.element),t.preventDefault()):this.diagram.contextMenuModule.contextMenu.open(t.pageY,t.pageX,this.diagram.element),this.diagram.checkMenu=!1)}p.hasStack&&this.diagram.endGroupAction()}if(f&&this.diagram.endGroupAction(),this.updateContainerBounds(!0),2!==this.eventArgs.clickCount&&(this.commandHandler.updateSelectedNodeProperties(this.eventArgs.source),u)){this.diagram.diagramActions=this.diagram.diagramActions&~ee.PreventLaneContainerUpdate;var A=this.eventArgs.source instanceof si?this.eventArgs.source.nodes:[this.eventArgs.source];if(A)for(w=0;w0&&!N&&this.diagram.renderSelector(!0),!this.inAction&&!this.diagram.currentSymbol&&this.eventArgs){var T=this.getTargetElement();this.diagram.tool!==Ci.ZoomPan&&this.diagram.triggerEvent(Ce.click,{element:T.target instanceof Es?T.target:this.eventArgs.source||this.diagram,position:this.eventArgs.position,count:t.detail,actualObject:this.eventArgs.actualObject,button:0===t.button?"Left":1===t.button?"Middle":"Right"})}this.eventArgs={}}this.diagram.diagramActions=this.diagram.diagramActions&~ee.PreventLaneContainerUpdate,e&&this.updateAnnotation(this.diagram.selectedItems),this.eventArgs={},this.diagram.commandHandler.removeStackHighlighter()},n.prototype.isSwimlaneChild=function(t){if(t.shape&&"SwimLane"!==t.shape.type){var e=this.diagram.nameTable[t.parentId];if(!e)return!1;var i=e.parentId?this.diagram.nameTable[e.parentId]:e;return i&&i.shape&&"SwimLane"===i.shape.type}return!1},n.prototype.updateAnnotation=function(t){var e=t.nodes;if(e.length>0)for(var i=0;i0&&(a+=1),h.isPhase){l="Horizontal"===r.orientation?this.currentPosition.x-e.wrapper.bounds.x:this.currentPosition.y-(e.wrapper.bounds.y+r.header.height);var g={id:Qe(),offset:l,header:{annotation:{content:void 0===h.phases[0].header?"Phase":h.phases[0].header.annotation.content,style:void 0===h.phases[0].header?{}:h.phases[0].header.annotation.style}},style:void 0===h.phases[0]?{}:h.phases[0].style};this.diagram.addPhases(e,[g])}else{var v={id:Qe(),style:h.lanes[0].style,header:{annotation:{content:h.lanes[0].header.annotation.content,style:h.lanes[0].header.annotation.style},style:h.lanes[0].header.style}};if("Horizontal"===h.orientation?v.height=h.lanes[0].height:v.width=h.lanes[0].width,"Horizontal"===r.orientation?(s=i.rowIndex?i.rowIndex:this.diagram.nameTable[i.parentId].rowIndex,i.wrapper.offsetYs)v.header.width=r.lanes[parseInt(s.toString(),10)].header.width,v.header.height=r.lanes[parseInt(s.toString(),10)].header.height;else{var S=void 0;S="Horizontal"===r.orientation?i.rowIndex<3?0:s-a-1:s-1,v.header.width=r.lanes[parseInt(S.toString(),10)].header.width,v.header.height=r.lanes[parseInt(S.toString(),10)].header.height}f&&("height"===f?(v.width=v.height,delete v.height):(v.height=v.width,delete v.width)),this.diagram.addLanes(e,[v],"Horizontal"===r.orientation?s-a:s)}this.commandHandler.select(e)}else if(h.isLane){var b={id:Qe(),width:t.width,height:t.height,addInfo:t.addInfo,shape:{type:"SwimLane",header:{annotation:{content:void 0===h.header?"Header":h.header.annotation.content,style:void 0===h.header?{}:h.header.annotation.style},height:50,style:h.header?h.header.style:h.lanes[0].header.style},phases:[{id:Qe(),header:{annotation:{content:void 0===h.phases||void 0===h.phases[0].header?"Phase":h.phases[0].header.annotation.content,style:void 0===h.phases||void 0===h.phases[0].header?{}:h.phases[0].header.annotation.style},style:void 0===h.phases||void 0===h.phases[0].header?{}:h.phases[0].header.style},style:void 0===h.phases?{}:h.phases[0].style}],lanes:[{id:Qe(),height:t.height,width:t.width,style:h.lanes[0].style,header:{annotation:{content:h.lanes[0].header.annotation.content,style:h.lanes[0].header.annotation.style},style:h.lanes[0].header.style}}],orientation:h.orientation}};"Vertical"===h.orientation&&(b.width+=20),b.offsetX=this.currentPosition.x+b.width/2,b.offsetY=this.currentPosition.y+b.height/2,b.style=t.style,this.diagram.add(b)}},n.prototype.mouseLeave=function(t){this.tool&&this.inAction&&this.tool.mouseLeave(this.eventArgs),this.diagram.selectedObject.helperObject&&(this.updateContainerProperties(),this.updateContainerBounds()&&this.diagram.endGroupAction()),this.eventArgs&&this.eventArgs.source&&(this.diagram.updatePortVisibility(this.eventArgs.source,hi.Hover,!0),this.hoverElement=null),this.eventArgs&&!this.eventArgs.source&&this.hoverElement&&(this.hoverElement=null),this.tool instanceof Od&&this.eventArgs&&this.eventArgs.target&&this.eventArgs.target instanceof te&&(this.diagram.updatePortVisibility(this.eventArgs.target,hi.Hover|hi.Connect,!0),this.hoverElement=null);var i=this.diagram.selectedItems;i&&i.wrapper&&(am(this.diagram,i)||this.diagram.renderSelector(!0)),(this.diagram.diagramActions&ee.Interactions||this.diagram.diagramActions&ee.ToolAction)&&(this.diagram.diagramActions=this.diagram.diagramActions&~ee.ToolAction),this.isMouseDown=!1,this.focus=!1,this.touchStartList=null,this.touchMoveList=null,this.elementLeave(),this.commandHandler.removeSnap(),this.inAction=!1,this.eventArgs={},this.diagram.selectedObject&&this.diagram.selectedObject.helperObject&&(this.diagram.remove(this.diagram.selectedObject.helperObject),this.diagram.selectedObject={helperObject:void 0,actualObject:void 0}),this.tool=null,function rse(){var t,e,n=document.getElementsByClassName("e-d-ruler-marker");if(n&&n.length>0)for(e=n.length-1;e>=0;e--)(t=n[parseInt(e.toString(),10)])&&t.parentNode.removeChild(t)}(),"Rotate"===this.action&&this.diagram.diagramCanvas.classList.remove("e-diagram-rotate"),t.preventDefault()},n.prototype.mouseWheel=function(t){this.diagram.blazorActions|=on.interaction;var e={event:t,cancel:!1};if(this.diagram.triggerEvent(Ce.mouseWheel,e),!e.cancel){var i=t.wheelDelta>0||-40*t.detail>0,r=this.getMousePosition(t);if(this.diagram.tooltipObject.close(),this.isMetaKey(t)){var o=this.diagram.scrollSettings.zoomFactor;this.diagram.zoomTo(i?{type:"ZoomIn",zoomFactor:o,focusPoint:r}:{type:"ZoomOut",zoomFactor:o,focusPoint:r}),t.preventDefault()}else{var a=this.diagram.scroller.horizontalOffset,l=this.diagram.scroller.verticalOffset,h=i?10:-10;this.tool&&(this.tool instanceof Ph||this.tool instanceof zh)&&(this.eventArgs={},this.getMouseEventArgs(r,this.eventArgs),this.eventArgs.position=r,this.tool.mouseWheel(this.eventArgs)),this.diagram.scrollActions|=ca.Interaction;var c=!0;if(t.isTrusted){var d=!1;(Math.abs(t.deltaY)<100&&-0===Math.abs(t.deltaX)||Math.abs(t.deltaX)<100&&-0===Math.abs(t.deltaY))&&(d=!0);var u=!1;(0!==t.deltaX||0!==t.deltaY)&&(u=navigator.userAgent.includes("Macintosh")),u?Math.abs(t.deltaX)>Math.abs(t.deltaY)?(t.shiftKey||t.deltaX&&-0!==t.deltaX&&(d||!u))&&this.diagram.scroller.zoom(1,h,0,r,c,void 0,d):t.deltaY&&-0!==t.deltaY&&(d||!u)&&this.diagram.scroller.zoom(1,0,h,r,c,void 0,d):t.shiftKey||t.deltaX&&-0!==t.deltaX&&(d||!u)?this.diagram.scroller.zoom(1,h,0,r,c,void 0,d):t.deltaY&&-0!==t.deltaY&&(d||!u)&&this.diagram.scroller.zoom(1,0,h,r,c,void 0,d)}else t.shiftKey||t.deltaX&&-0!==t.deltaX?this.diagram.scroller.zoom(1,h,0,r,c):this.diagram.scroller.zoom(1,0,h,r,c);this.diagram.scrollActions&=~ca.Interaction,(a!==this.diagram.scroller.horizontalOffset||l!==this.diagram.scroller.verticalOffset)&&t.preventDefault()}if(this.diagram.textEditing){if(this.diagram.isTriggerEvent=!0,this.diagram.activeLabel.parentId){var f=this.diagram.getObject(this.diagram.activeLabel.parentId);this.diagram.startTextEdit(f,this.diagram.activeLabel.id)}this.diagram.isTriggerEvent=!1}this.diagram.blazorActions=this.diagram.blazorActions&~on.interaction}},n.prototype.keyDown=function(t){if(t.fromMouseEvents&&(t.ctrlKey&&(this.keyArgs.keyModifiers=1),t.shiftKey&&(this.keyArgs.keyModifiers=4),t.shiftKey&&t.ctrlKey&&(this.keyArgs.keyModifiers=5)),!(this.diagram.diagramActions&ee.TextEdit)&&!this.checkEditBoxAsTarget(t)||"Escape"===t.key||27===t.keyCode){var i=void 0,r=t.keyCode?t.keyCode:t.which,s=t.key;("ArrowDown"===s||"ArrowUp"===s||"ArrowLeft"===s||"ArrowRight"===s)&&(this.isNudgeKey=!0);var o=this.isMetaKey(t);if(this.diagram.commandManager&&this.diagram.commands)for(var l=0,h=Object.keys(this.diagram.commands);l4&&(S({keyDownEventArgs:KeyboardEvent,parameter:i.parameter,type:"KEYDOWN"}),this.keyCount=0)),this.isKeyUp=!1):S({keyDownEventArgs:KeyboardEvent,parameter:i.parameter})}break}}}}this.keyArgs={element:this.diagram.selectedItems,key:t.key,keyCode:t.keyCode?t.keyCode:t.which},this.getKeyModifier(this.keyArgs,t),this.diagram.diagramActions&ee.TextEdit&&this.getlabel(this.keyArgs,t),this.diagram.triggerEvent(Ce.keyDown,this.keyArgs)},n.prototype.getlabel=function(t,e){var i=this.diagram.activeLabel;t.target=this.diagram.element.id+"_editBox";var r=this.diagram.nameTable[i.parentId];if(document.getElementById(this.diagram.element.id+"_editBox")){t.text=document.getElementById(this.diagram.element.id+"_editBox").value;for(var s=0;s=this.diagram.scroller.viewPortWidth-18?r="right":e.x+this.diagram.scroller.horizontalOffsetthis.diagram.scroller.viewPortHeight-18?r="bottom":e.y+this.diagram.scroller.verticalOffset0&&(s=this.findIntersectChild(this.hoverElement)),"Auto"===this.hoverElement.tooltip.openOn&&""!==r&&Ex(this.diagram,s||(i?this.hoverElement:void 0)),this.hoverElement.tooltip.content&&("Mouse"===this.hoverElement.tooltip.relativeMode?this.setTooltipOffset(t):(this.diagram.tooltipObject.offsetX=0,this.diagram.tooltipObject.offsetY=0));var o=this.diagram.findObjectsUnderMouse(this.currentPosition),a=this.diagram.findObjectUnderMouse(o,this.action,this.inAction);if(null!==a){var l=void 0;this.hoverElement.tooltip.isSticky&&(this.diagram.tooltipObject.isSticky=!0),a instanceof te&&a.children&&a.children.length>0&&(a=s||a),l=a.ports&&(this.hoverElement instanceof Es||this.hoverElement instanceof xc)||a.annotations&&(this.hoverElement instanceof Zn||this.hoverElement instanceof Nr)?document.getElementById(a.id+"_"+this.hoverElement.id):document.getElementById(a.id+(a.shape&&a.shape instanceof lm?"_content_native_element":"_groupElement")),"Auto"===this.hoverElement.tooltip.openOn&&""!==r&&(this.diagram.tooltipObject.close(),this.diagram.tooltipObject.openOn=this.hoverElement.tooltip.openOn,this.diagram.tooltipObject.dataBind()),function Kre(n,t){var e=0;return n instanceof de?n.constraints&qe.Tooltip?e=n.constraints&qe.Tooltip:n.constraints&qe.InheritTooltip&&(e=t.constraints&rt.Tooltip):n instanceof Es||n instanceof xc?n.constraints&ri.ToolTip?e=n.constraints&ri.ToolTip:n.constraints&ri.InheritTooltip&&(e=t.constraints&rt.Tooltip):n instanceof Zn||n instanceof Nr?n.constraints&Lr.Tooltip&&(e=n.constraints&Lr.Tooltip):n.constraints&ie.Tooltip?e=n.constraints&ie.Tooltip:n.constraints&ie.InheritTooltip&&(e=t.constraints&rt.Tooltip),e}(this.hoverElement,this.diagram)&&"Auto"===this.hoverElement.tooltip.openOn&&(this.diagram.tooltipObject.target=this.hoverElement.id,this.diagram.tooltipObject.open("Mouse"===this.hoverElement.tooltip.relativeMode?this.diagram.element:l))}}},n.prototype.elementLeave=function(){this.diagram.tooltipObject&&!this.diagram.tooltipObject.isSticky&&"Custom"!==this.diagram.tooltipObject.openOn&&this.diagram.tooltipObject.close()},n.prototype.setTooltipOffset=function(t){var e=function Mse(n,t,e,i){var o="Mouse"===(!(e instanceof te?e.constraints&ie.InheritTooltip:e instanceof de?e.constraints&qe.InheritTooltip:e.constraints&ri.InheritTooltip)&&(e instanceof te?e.constraints&ie.Tooltip:e instanceof de?e.constraints&qe.Tooltip:e.constraints&ri.ToolTip)?e.tooltip.relativeMode:n.tooltip.relativeMode);"Mouse"===i?o=!0:"Object"===i&&(o=!1);var a=function wse(n,t,e,i){var o,r={},s=document.getElementById(e.element.id);if(n instanceof te||n instanceof de)o=n.wrapper.bounds;else{var a=e.findObjectsUnderMouse(t),l=e.findObjectUnderMouse(a,"Select",!1);o=e.findElementUnderMouse(l,t,e).bounds}var c=s.getBoundingClientRect();switch(e.tooltipObject.position){case"BottomCenter":r=zc(t,o.bottomCenter,e,i,c.width/2,c.height);break;case"BottomLeft":case"LeftBottom":r=zc(t,o.bottomLeft,e,i,0,c.height);break;case"BottomRight":case"RightBottom":r=zc(t,o.bottomRight,e,i,c.width,c.height);break;case"LeftCenter":r=zc(t,o.middleLeft,e,i,0,c.height/2);break;case"LeftTop":case"TopLeft":r=zc(t,o.topLeft,e,i,0,0);break;case"RightCenter":r=zc(t,o.middleRight,e,i,c.width,c.height/2);break;case"RightTop":case"TopRight":r=zc(t,o.topRight,e,i,c.width,0);break;case"TopCenter":r=zc(t,o.topCenter,e,i,c.width/2,0)}return r}(e,t,n,o),l=qa(n);return{x:a.x+l.width,y:a.y+l.height}}(this.diagram,t,this.hoverElement);this.diagram.tooltipObject.offsetX=e.x,this.diagram.tooltipObject.offsetY=e.y},n.prototype.altKeyPressed=function(t){return!!(t&pt.Alt)},n.prototype.ctrlKeyPressed=function(t){return!!(t&pt.Control)},n.prototype.shiftKeyPressed=function(t){return!!(t&pt.Shift)},n.prototype.scrolled=function(t){this.diagram.updateScrollOffset()},n.prototype.doubleClick=function(t){if(Vv(this.diagram)){var e=void 0,i=this.diagram.findObjectsUnderMouse(this.currentPosition),r=this.diagram.findObjectUnderMouse(i,this.action,this.inAction);if(null!==r&&Vv(this.diagram))if(e=this.diagram.findElementUnderMouse(r,this.currentPosition,this.diagram),this.tool&&(this.tool instanceof Ph||this.tool instanceof zh))this.tool.mouseUp(this.eventArgs),this.isMouseDown=!1,this.eventArgs={},this.tool=null,t.preventDefault();else{var o=this.diagram.commandHandler.getObjectLayer(r.id);!o||o.lock||!o.visible||this.diagram.diagramActions&ee.TextEdit||this.diagram.startTextEdit(r,e instanceof ni?e.id.split(r.id+"_")[1]:void 0)}this.diagram.triggerEvent(Ce.doubleClick,{source:r||this.diagram,position:this.currentPosition,count:t.detail})}},n.prototype.itemClick=function(t,e){var i=t;return cs(this.diagram,i,!0)?i:null},n.prototype.inputChange=function(t){var i,s,o,a,l,h,c,d,u,p=document.getElementById(this.diagram.element.id+"_editBox"),f=document.getElementById(this.diagram.element.id+"_editTextBoxDiv"),g=p.value,v=g.split("\n");(!(a=this.diagram.selectedItems.nodes[0]?this.diagram.selectedItems.nodes[0]:this.diagram.selectedItems.connectors[0])&&this.tool instanceof XI||a&&"SwimLane"===a.shape.type)&&(a=this.diagram.nameTable[this.diagram.activeLabel.parentId]),a&&("Text"!==a.shape.type&&a.annotations.length>0||"Text"===a.shape.type)&&(c=HF((o=this.diagram.getWrapper(a.wrapper,this.diagram.activeLabel.id)).style,g,void 0,void 0,i=(i=a.wrapper.bounds.width90?i:90),s=Number(p.style.fontSize.split("px")[0]),v.length>1&&""===v[v.length-1]&&(c.height=c.height+s),d=this.diagram.scroller.transform,u=P3(this.diagram)?d.scale:1,l=(12>c.height?12:c.height)*u,f.style.left=(o.bounds.center.x+d.tx)*d.scale-(h=(90>(h=c.width)?90:h)*u)/2-2.5+"px",f.style.top=(o.bounds.center.y+d.ty)*d.scale-l/2-3+"px",f.style.width=h+"px",f.style.height=l+"px",p.style.minHeight="12px",p.style.minWidth="90px",p.style.width=h+"px",p.style.height=l+"px")},n.prototype.isAddTextNode=function(t,e){return!(!(this.tool instanceof XI||e)||(this.tool=null,t&&!HI(this.diagram)&&(this.diagram.drawingObject=void 0,this.diagram.currentDrawingObject=void 0),MF(this.diagram.nodes,t.id)||MF(this.diagram.connectors,t.id)))},n.prototype.checkEditBoxAsTarget=function(t){return!(!t.target||t.target.id!==this.diagram.element.id+"_editBox")},n.prototype.getMouseEventArgs=function(t,e,i,r){var s,o,a;if(e.position=t,i?(o=this.diagram.findObjectsUnderMouse(this.currentPosition,i),s=this.diagram.findTargetObjectUnderMouse(o,this.action,this.inAction,e.position,i)):"Drag"===this.action||"ConnectorSourceEnd"===this.action||"SegmentEnd"===this.action||"OrthoThumb"===this.action||"BezierSourceThumb"===this.action||"BezierTargetThumb"===this.action||"ConnectorTargetEnd"===this.action||-1!==this.action.indexOf("Rotate")||-1!==this.action.indexOf("Resize")?(s=this.diagram.selectedItems,!this.diagram.currentSymbol&&"Drag"===this.action&&s&&this.diagram.selectedItems.nodes.length>0&&"SwimLane"===this.diagram.selectedItems.nodes[0].shape.type&&(o=this.diagram.findObjectsUnderMouse(this.currentPosition),s=this.diagram.findObjectUnderMouse(o,this.action,this.inAction))):(o=this.diagram.findObjectsUnderMouse(this.currentPosition),s=this.diagram.findObjectUnderMouse(o,this.action,this.inAction)),s&&s.isHeader&&(this.eventArgs.actualObject=s=this.diagram.nameTable[s.parentId]),s){var l=void 0,h=void 0,c=void 0;if(((a=this.diagram.findElementUnderMouse(s,this.currentPosition,this.diagram,r))&&s.ports&&s.ports.length&&!ob(s,a)||!a||!s)&&o&&o.length&&i instanceof si)for(l=i.connectors[0],c=o.length-1;c>=0;c--)if(((h=o[parseInt(c.toString(),10)])instanceof te||h instanceof de)&&l&&l.connectionPadding){if(a=this.diagram.findElementUnderMouse(s=h,this.currentPosition,this.diagram,r),l.constraints&qe.ConnectToNearByPort&&s&&s.ports&&s.ports.length&&ob(s,a))break;if((h instanceof te||h instanceof de)&&l&&l.connectionPadding&&h.wrapper.outerBounds.containsPoint(this.currentPosition)&&l.constraints&qe.ConnectToNearByNode&&!(l.constraints&qe.ConnectToNearByPort)){a=this.diagram.findElementUnderMouse(s=h,this.currentPosition,this.diagram,0);break}}}return i?(e.target=s,e.targetWrapper=a):(e.source=s,e.sourceWrapper=a),e.actualObject=this.eventArgs.actualObject,e.source instanceof si&&void 0===e.actualObject&&(e.source.nodes.length>0||e.source.connectors.length>0)&&(e.actualObject=e.source.nodes.length>0?this.diagram.nameTable[e.source.nodes[0].id]:this.diagram.nameTable[e.source.connectors[0].id]),e.startTouches=this.touchStartList,e.moveTouches=this.touchMoveList,e},n.prototype.resetTool=function(){this.action="Select",this.hoverElement=null,this.hoverNode=null,this.tool=this.diagram.getTool(this.action),this.updateCursor()},n.prototype.updateTool=function(){this.eventArgs&&!this.eventArgs.position&&(this.action="Select")},n.prototype.getTool=function(t){switch(t){case"Select":return new Jv(this.commandHandler,!0);case"Drag":return new ua(this.commandHandler);case"Rotate":return new Xx(this.commandHandler);case"LayoutAnimation":return new Une(this.commandHandler);case"FixedUserHandle":return new _ne(this.commandHandler,!0);case"Hyperlink":return new eF(this.commandHandler);case"ResizeSouthEast":case"ResizeSouthWest":case"ResizeNorthEast":case"ResizeNorthWest":case"ResizeSouth":case"ResizeNorth":case"ResizeWest":case"ResizeEast":return new kd(this.commandHandler,t);case"ConnectorSourceEnd":case"ConnectorTargetEnd":case"BezierSourceThumb":case"BezierTargetThumb":return new Od(this.commandHandler,t);case"SegmentEnd":case"OrthoThumb":return new r_(this.commandHandler,t);case"Draw":var e="shape",i=function gse(n){var t;return n&&(n.type?t="Connector":n.shape&&!n.type&&(t="Node")),t}(this.diagram.drawingObject);if("Node"===i&&"Text"===this.diagram.drawingObject.shape.type)return new XI(this.commandHandler);if("Connector"===i&&"Freehand"===this.diagram.drawingObject.type)return new Yne(this.commandHandler);if("Node"===i&&"Polygon"===this.diagram.drawingObject.shape[""+e]&&!this.diagram.drawingObject.shape.points)return new Ph(this.commandHandler);if("Node"===i||"Node"===i&&"Polygon"===this.diagram.drawingObject.shape[""+e]&&this.diagram.drawingObject.shape.points)return new GI(this.commandHandler,this.diagram.drawingObject);if("Connector"===i&&"Polyline"===this.diagram.drawingObject.type)return new zh(this.commandHandler);if("Connector"===i)return new pa(this.commandHandler,"ConnectorSourceEnd",this.diagram.drawingObject);break;case"Pan":return new Kv(this.commandHandler,!1);case"PinchZoom":return new Kv(this.commandHandler,!0);case"PortDrag":return new ua(this.commandHandler,"Port");case"PortDraw":return new pa(this.commandHandler,"ConnectorSourceEnd",this.diagram.drawingObject);case"LabelSelect":return new Jv(this.commandHandler,!0,"LabelSelect");case"LabelDrag":return new jne(this.commandHandler);case"LabelResizeSouthEast":case"LabelResizeSouthWest":case"LabelResizeNorthEast":case"LabelResizeNorthWest":case"LabelResizeSouth":case"LabelResizeNorth":case"LabelResizeWest":case"LabelResizeEast":return new Vne(this.commandHandler,t);case"LabelRotate":return new Wne(this.commandHandler)}return null},n.prototype.getCursor=function(t){var e=this.diagram.selectedItems.annotation?this.diagram.selectedItems.wrapper.children[0]:this.diagram.selectedItems;return function Fne(n,t){if(t+=360,t%=360,-1===n.indexOf("Resize"))return Gx[""+n];var e=Gx[""+n];return t>=0&&t<25||t>=160&&t<=205||t>=340&&t<=360?e:t>=25&&t<=70||t>=205&&t<=250?"n-resize"===e||"s-resize"===e?"ne-resize":"nw-resize"===e||"se-resize"===e?"n-resize":"e-resize"===e||"w-resize"===e?"nw-resize":"e-resize":t>=70&&t<=115||t>=250&&t<=295?"n-resize"===e||"s-resize"===e?"e-resize":"nw-resize"===e||"se-resize"===e?"ne-resize":"e-resize"===e||"w-resize"===e?"n-resize":"nw-resize":t>=115&&t<=155||t>=295&&t<=340?"n-resize"===e||"s-resize"===e?"nw-resize":"nw-resize"===e||"se-resize"===e?"e-resize":"e-resize"===e||"w-resize"===e?"ne-resize":Gx[""+n]:"n-resize"}(t,this.diagram.selectedItems.annotation?e.rotateAngle+e.parentTransform:e.rotateAngle)},n.prototype.findElementUnderMouse=function(t,e,i,r){return this.objectFinder.findElementUnderSelectedItem(t,e,i,r)},n.prototype.findObjectsUnderMouse=function(t,e){return this.objectFinder.findObjectsUnderMouse(t,this.diagram,this.eventArgs,e)},n.prototype.findObjectUnderMouse=function(t,e,i){return this.objectFinder.findObjectUnderMouse(this.diagram,t,e,i,this.eventArgs,this.currentPosition)},n.prototype.findTargetUnderMouse=function(t,e,i,r,s){return this.objectFinder.findObjectUnderMouse(this.diagram,t,e,i,this.eventArgs,r,s)},n.prototype.findActionToBeDone=function(t,e,i,r){return function kne(n,t,e,i,r,s,o){if(s&&s.length>1&&r&&r.length>1)return"PinchZoom";if(i.currentSymbol)return"Drag";if("PortDraw"===i.eventHandler.action&&(i.tool&=~Ci.DrawOnce),(k3(i)||HI(i))&&i.drawingObject)return"Draw";if(Xa(i)&&(l=i.selectedItems).wrapper&&qr(l.constraints,"UserHandle"))for(var h=0,c=l.userHandles;h=50&&(l.x=(a.points[parseInt(h.toString(),10)].x+a.points[h+1].x)/2,l.y=(a.points[parseInt(h.toString(),10)].y+a.points[h+1].y)/2,wr(e,l,n.hitPadding?n.hitPadding:10)))return"OrthoThumb"}else kI(n)&&console.warn('[WARNING] :: Module "ConnectorEditing" is not available in Diagram component! You either misspelled the module name or forgot to load it.');return null}(g,l,e,i);if("OrthoThumb"===S)return S;if(qr(l.constraints,"ConnectorSourceThumb")&&NI(g)&&S||qr(l.constraints,"ConnectorTargetThumb")&&OI(g)&&S)return S}}else{var b=i.selectedItems.handleSize/2/i.scroller.currentZoom,M=10/i.scroller.currentZoom,w=Hi();qi(w,p.rotateAngle+p.parentTransform,p.offsetX,p.offsetY);var C=p.offsetX-p.pivot.x*p.actualSize.width,D=p.offsetY-p.pivot.y*p.actualSize.height,A={x:C+(.5===p.pivot.x?2*p.pivot.x:p.pivot.x)*p.actualSize.width/2,y:D-30/i.scroller.currentZoom};A=Je(w,A);var x=!!i.selectedItems.annotation,R=!(!x||!PI(i.selectedItems.annotation));if(qr(l.constraints,"Rotate")&&wr(e,A,M)&&i.selectedItems.thumbsConstraints&bt.Rotate){if(x&&R)return"LabelRotate";if(!x)return"Rotate"}if(u.Inflate(b),u.containsPoint(e)&&(S=function Pne(n,t,e,i,r,s){var o;return 1===n.selectedItems.nodes.length&&0===n.selectedItems.connectors.length&&n.selectedItems.nodes[0].container&&(o=function Hne(n,t,e,i,r){var s=10/n.scroller.currentZoom,o=40/n.scroller.currentZoom,a=n.selectedItems,l=t.actualSize.width,h=t.actualSize.height,c=new Ne(i,r,t.style.strokeWidth,h),d=new Ne(i+l,r,t.style.strokeWidth,h),u=new Ne(i,r,l,t.style.strokeWidth),p=new Ne(i,r+h,l,t.style.strokeWidth),f=cs(n,n.selectedItems.nodes[0],!0)?n.nameTable[n.selectedItems.nodes[0].parentId]:n.selectedItems.nodes[0];if(l>=o&&h>=o){if(fa(a.constraints,"ResizeEast",a.thumbsConstraints,a)&&d.containsPoint(e,s))return"ResizeEast";if(fa(a.constraints,"ResizeSouth",a.thumbsConstraints,a)&&p.containsPoint(e,s))return"ResizeSouth";if("Grid"!==f.container.type){if(fa(a.constraints,"ResizeWest",a.thumbsConstraints,a)&&c.containsPoint(e,s))return"ResizeWest";if(fa(a.constraints,"ResizeNorth",a.thumbsConstraints,a)&&u.containsPoint(e,s))return"ResizeNorth"}}return null}(n,t,e,r,s)),!o&&(!n.selectedItems.nodes[0]||!n.selectedItems.nodes[0].isPhase&&!n.selectedItems.nodes[0].isLane&&"SwimLane"!==n.selectedItems.nodes[0].shape.type)&&(o=function Bne(n,t,e,i,r,s){var o=40/n.scroller.currentZoom,a=n.selectedItems.handleSize/2/n.scroller.currentZoom,l=n.selectedItems,h=!!l.annotation;if(t.actualSize.width>=o&&t.actualSize.height>=o){if(fa(l.constraints,"ResizeSouthEast",l.thumbsConstraints,l)&&wr(e,Je(i,{x:r+t.actualSize.width,y:s+t.actualSize.height}),a))return h?"LabelResizeSouthEast":"ResizeSouthEast";if(fa(l.constraints,"ResizeSouthWest",l.thumbsConstraints,l)&&wr(e,Je(i,{x:r,y:s+t.actualSize.height}),a))return h?"LabelResizeSouthWest":"ResizeSouthWest";if(fa(l.constraints,"ResizeNorthEast",l.thumbsConstraints,l)&&wr(e,Je(i,{x:r+t.actualSize.width,y:s}),a))return h?"LabelResizeNorthEast":"ResizeNorthEast";if(fa(l.constraints,"ResizeNorthWest",l.thumbsConstraints,l)&&wr(e,Je(i,{x:r,y:s}),a))return h?"LabelResizeNorthWest":"ResizeNorthWest"}return fa(l.constraints,"ResizeEast",l.thumbsConstraints,l)&&wr(e,Je(i,{x:r+t.actualSize.width,y:s+t.actualSize.height/2}),a)?h?"LabelResizeEast":"ResizeEast":fa(l.constraints,"ResizeWest",l.thumbsConstraints,l)&&wr(e,Je(i,{x:r,y:s+t.actualSize.height/2}),a)?h?"LabelResizeWest":"ResizeWest":fa(l.constraints,"ResizeSouth",l.thumbsConstraints,l)&&wr(e,Je(i,{x:r+t.actualSize.width/2,y:s+t.actualSize.height}),a)?h?"LabelResizeSouth":"ResizeSouth":fa(l.constraints,"ResizeNorth",l.thumbsConstraints,l)&&wr(e,Je(i,{x:r+t.actualSize.width/2,y:s}),a)?h?"LabelResizeNorth":"ResizeNorth":null}(n,t,e,i,r,s)),o||null}(i,p,e,w,C,D),S))return S}}if(Lc(i)&&!n)return"Pan";if((o instanceof Es||o instanceof xc)&&(!Lc(i)||Uv(i)||jv(i))&&(S=function Rne(n,t,e,i){if(_x(t)&&(ga(t,hi.Hover)||ga(t,hi.Visible))){if(t.constraints&ri.Drag)return"PortDrag"}else if(Fx(t)&&(ga(t,hi.Hover)||ga(t,hi.Visible))&&t.constraints&ri.Draw){n.drawingObject={};var r={type:"Orthogonal",sourcePortID:t.id};return n.drawingObject=r,n.tool|=Ci.DrawOnce,n.currentDrawingObject=r,"PortDraw"}return"None"}(i,o),"None"!==S))return S;if((o instanceof Zn||o instanceof Nr)&&!Lc(i)&&Dd(o))return _r(i,o,void 0,t)&&to(o)?"LabelDrag":"LabelSelect";if(null!==n){if(!(n instanceof te||n instanceof de))return"Select";if(t&&t.id){var L=t.id.split(n.id)[1];if(L&&L.match("^_icon"))return"LayoutAnimation"}if(t&&t.id)for(var O=void 0,N=0;N-1)return"FixedUserHandle";if(t instanceof ni&&t.hyperlink.link)return"Hyperlink";if(!to(n)||!_r(i,n,!1)||void 0!==i.selectedItems.annotation)return n&&Lc(i)&&!BI(i)?"Pan":i.selectedItems.nodes.length&&i.selectedItems.nodes[0].isLane&&i.selectedItems.wrapper&&i.selectedItems.wrapper.bounds.containsPoint(e)?"Drag":"Select";if(n instanceof de&&!wr(e,n.sourcePoint,n.hitPadding)&&!wr(e,n.targetPoint,n.hitPadding)||!(n instanceof de))return"Drag"}return"Select"}(t,e,this.currentPosition,this.diagram,this.touchStartList,this.touchMoveList,r)},n.prototype.updateContainerBounds=function(t){var e=!1;if(this.diagram.selectedObject.helperObject&&this.diagram.selectedObject.actualObject instanceof te){var i=this.tool instanceof kd,r=this.diagram.selectedObject.actualObject,s=this.diagram.nameTable[r.parentId];t?q3(this.diagram,r,this.currentPosition,i):((!s||s&&"SwimLane"!==s.shape.type)&&this.diagram.updateDiagramObject(r),e=function Ane(n,t,e,i){var r,o=!1;if(cs(n,t,!0)){n.protectPropertyChange(!0);var a=(r=n.nameTable[t.parentId]).wrapper;if(r&&"Canvas"===r.container.type){if(i||a.bounds.x<=e.x&&a.bounds.right>=e.x&&a.bounds.y<=e.y&&a.bounds.bottom>=e.y){var l=void 0,h=a.bounds.y,c=a.bounds.x,d=n.nameTable[r.parentId]||r;if("SwimLane"===d.shape.type)o=Zv(r,d,t,n,!0);else{var p=n.nameTable[r.parentId]||r,f=p.shape;l=p.wrapper,a.actualSize.widtha.outerBounds.x)&&(void 0!==r.rowIndex?(l.updateColumnWidth(r.columnIndex,a.outerBounds.width,!0),"Horizontal"===f.orientation&&f.phaseSize&&VI(p,n,a,r.columnIndex),Oc(n,p),n.drag(p,c-a.bounds.x,h-a.bounds.y)):n.scale(r,1+(a.outerBounds.width-a.actualSize.width)/a.actualSize.width,1,a.outerBounds.xa.outerBounds.y)&&(void 0!==r.rowIndex?(l.updateRowHeight(r.rowIndex,a.outerBounds.height,!0),n.drag(p,c-a.bounds.x,h-a.bounds.y)):n.scale(r,1,1+(a.outerBounds.height-a.actualSize.height)/a.actualSize.height,a.outerBounds.yi.y&&(h+=u>0?-1:1,u+=u>0?-1:1):i&&e.wrapper.offsetYi.x&&(h+=u>0?-1:1,u+=u>0?-1:1):i&&e.wrapper.offsetX1&&!(this.diagram.lineRoutingModule&&this.diagram.constraints&rt.LineRouting))for(var b=t.offsetX-this.diagram.selectedItems.offsetX,M=t.offsetY-this.diagram.selectedItems.offsetY,w=t.rotateAngle-this.diagram.selectedItems.rotateAngle,C=0;C-1){var x=c.children;x.splice(x.indexOf(o.id),1),this.diagram.nameTable[o.id].parentId="",i=!0,c.wrapper.children.splice(A,1)}}if(function One(n,t,e,i){var r=n,s=e.nameTable[r.parentId],o=e.nameTable[r.parentId];if(t&&o&&o.container&&"Stack"===o.container.type&&t.container&&"Stack"===t.container.type&&o.id!==t.parentId){var a=o.wrapper.children.indexOf(r.wrapper);a>-1&&(e.nameTable[r.id].parentId=t.id,o.wrapper.children.splice(a,1))}if(t&&t.parentId&&r.parentId&&"Drag"===i&&o.container&&"Stack"===o.container.type){var l=s.wrapper.children.indexOf(t.wrapper),h=s.wrapper.children.indexOf(r.wrapper),c={targetIndex:l,target:t,sourceIndex:h,source:n};s.wrapper.children.splice(h,1),s.wrapper.children.splice(l,0,r.wrapper),e.commandHandler.addHistoryEntry({type:"StackChildPositionChanged",redoObject:{targetIndex:h,target:t,sourceIndex:l,source:n},undoObject:c,category:"Internal"})}}(o,h,this.diagram,this.action),(c=cs(this.diagram,o)?this.diagram.nameTable[o.parentId]:this.diagram.nameTable[o.parentId]||o)&&c.container&&"Canvas"===c.container.type&&(c.wrapper.maxWidth=c.maxWidth=c.wrapper.actualSize.width,c.wrapper.maxHeight=c.maxHeight=c.wrapper.actualSize.height,e=!0),cs(this.diagram,o,!0)&&c&&"Canvas"===c.container.type)if(this.diagram.selectedItems.nodes.length>1)for(C=0;C0)for(var i=0;i0&&e.columnIndex>0||l&&e.isLane)){if("Horizontal"===t.container.orientation&&e.isPhase&&e.wrapper.width>e.maxWidth&&(e.maxWidth=e.wrapper.width,e.wrapper.maxWidth=e.wrapper.width),h.updateColumnWidth(e.columnIndex,r.width,!0,c),Vx(this.diagram,e,t),e.isPhase){var f=this.diagram.nameTable[""+t.shape.phases[e.columnIndex].header.id];f.maxWidth0?(r=new sf(t,"",u),t.shape.classShape.attributes.push(r)):i.id.includes("_umlMethods")&&t.shape.classShape.methods.length>0&&(s=new cm(t,"",u),t.shape.classShape.methods.push(s))),"Interface"===t.shape.classifier&&(i.id.includes("_umlProperty")&&t.shape.interfaceShape.attributes.length>0?(r=new sf(t,"",u),t.shape.classShape.attributes.push(r)):i.id.includes("_umlMethods")&&t.shape.interfaceShape.methods.length>0&&(s=new cm(t,"",u),t.shape.interfaceShape.methods.push(s))),"Enumeration"===t.shape.classifier&&i.id.includes("_umlMember")&&t.shape.enumerationShape.members.length>0){var p=new hb(t,"",u);t.shape.enumerationShape.members.push(p)}t.wrapper.children.indexOf(c.wrapper),this.diagram.enableServerDataBinding(!0),this.diagram.add(c),this.diagram.updateConnectorEdges(t),this.diagram.clearSelection(),this.diagram.select([this.diagram.nameTable[c.id]]),this.diagram.endGroupAction(),this.diagram.startTextEdit()}}},n}(),Zoe=function(){function n(){}return n.prototype.findObjectsUnderMouse=function(t,e,i,r,s){var o=[];r&&r instanceof si&&r.nodes.length+r.connectors.length===1&&(r=r.nodes[0]||r.connectors[0]).children&&0===r.children.length&&(i.actualObject=r);for(var a,l,h,c,f,d=r&&r instanceof de&&(r.constraints&qe.ConnectToNearByNode||r.constraints&qe.ConnectToNearByPort)&&r.connectionPadding||0,p={},g=0,v=e.spatialSearch.findObjects(new Ne(t.x-50-d,t.y-50-d,100+d,100+d));g-1&&o.splice(T,1),"UmlClassifier"===y.shape.type&&y.container&&"Stack"===y.container.type&&(T=o.indexOf(e.nameTable[e.nameTable[y.id].wrapper.children[0].id]))>-1&&o.splice(T,1)}for(var P=0;Ps.zIndex&&(t[parseInt(r.toString(),10)]=l),r>0&&i&&a&&(a.isLane||a.isPhase||a.isHeader)&&t[parseInt(r.toString(),10)].zIndex=2)for(var d=t.length-1;d>=0;d--)if(t[parseInt(d.toString(),10)].parentId){var u=om(t[parseInt(d.toString(),10)],e,""),p=om(t[d-1],e,""),g=e.nameTable[""+p];g&&u!==p&&e.nameTable[""+u].zIndex=0;f--){d=ef(e[parseInt(f.toString(),10)],!1),c=ef(e[parseInt(f.toString(),10)],!0);var g=t[""+l].tool,v=this.findTargetElement(e[parseInt(f.toString(),10)].wrapper,o,t,void 0);if("Draw"===i&&v&&(e[parseInt(f.toString(),10)]instanceof te||e[parseInt(f.toString(),10)]instanceof de)&&!ob(e[parseInt(f.toString(),10)],v)&&(g&&"ConnectorSourceEnd"===g[""+h]&&!kh(e[parseInt(f.toString(),10)])||g&&"ConnectorTargetEnd"===g[""+h]&&!da(e[parseInt(f.toString(),10)])))return u;if(e[parseInt(f.toString(),10)]instanceof te||e[parseInt(f.toString(),10)]instanceof de&&(kh(e[parseInt(f.toString(),10)])||xd(d)||da(e[parseInt(f.toString(),10)])||Oh(c)||"PortDraw"===i&&g instanceof Od&&"ConnectorTargetEnd"===g[""+h]&&(da(e[parseInt(f.toString(),10)])||Oh(c))))return u=e[parseInt(f.toString(),10)],p&&(u=this.isTarget(u,t,i)),s.actualObject=u,u}else if("ConnectorTargetEnd"===i&&a){for(f=e.length-1;f>=0;f--)if(c=ef(e[parseInt(f.toString(),10)],!0),(e[parseInt(f.toString(),10)]instanceof te||e[parseInt(f.toString(),10)]instanceof de)&&(da(e[parseInt(f.toString(),10)])||Oh(c)))return u=e[parseInt(f.toString(),10)],u=this.isTarget(u,t,i),s.actualObject=u,u}else{if(a&&("Drag"===i||t[""+l].tool instanceof ua)){var y=0;for(f=0;f=S.zIndex?u:S,y=Math.max(y,S.zIndex)):y=(u=S).zIndex)}return u&&"Bpmn"===u.shape.type&&(t.selectedItems.nodes.length>0&&"Bpmn"===t.selectedItems.nodes[0].shape.type||(u=null)),u&&(s.actualObject=u),u}if("Select"!==i&&"Pan"!==i||!t[""+l].tool)if("Pan"===i||"LayoutAnimation"===i){for(f=e.length-1;f>=0;f--)if((e[parseInt(f.toString(),10)]instanceof te||e[parseInt(f.toString(),10)]instanceof de)&&(v=this.findTargetElement(e[parseInt(f.toString(),10)].wrapper,o,t,void 0),"Pan"===i||v&&(v.id.match("_icon_content_shape$")||v.id.match("_icon_content_rect$"))))return e[parseInt(f.toString(),10)]}else u=e[e.length-1],s&&u&&(s.actualObject=u);else{for(f=e.length-1;f>=0;f--)if(e[parseInt(f.toString(),10)]instanceof de){var b=e[f-1];if(e[f-1]instanceof te&&b.ports){if((v=this.findTargetElement(b.wrapper,o,t,void 0))&&(v.id.match("_icon_content_shape$")||v.id.match("_icon_content_rect$")))return b;for(var M=0;M=0;s--){var o=t.children[parseInt(s.toString(),10)];if(o&&o.outerBounds.containsPoint(e,r||0))if(o.visible){if(o instanceof Cs){var a=this.findTargetElement(o,e,i);if(a)return a}var l="Clip"===o.style.textOverflow||"Ellipsis"===o.style.textOverflow;if(o.bounds.containsPoint(e,r||0)&&!l)return o;if(t.bounds.containsPoint(e,r||0)&&l)return o}else if(o instanceof Ke&&t&&t.id){var h=void 0;if(t.id.includes("group_container")){var c=t.id.slice(0,-15);h=i.getObject(c)}else h=i.getObject(t.id);if(nb(h,o.id))return o}}return t.bounds.containsPoint(e,r)&&"none"!==t.style.fill?t:null},n}(),Joe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),af=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},n_=function(n){function t(e,i,r,s){var o=n.call(this,e,i,r,s)||this;return o.objectZIndex=-1,o.zIndexTable={},o.objects=[],o}return Joe(t,n),af([I("")],t.prototype,"id",void 0),af([I(!0)],t.prototype,"visible",void 0),af([I(!1)],t.prototype,"lock",void 0),af([I()],t.prototype,"objects",void 0),af([I()],t.prototype,"addInfo",void 0),af([I(-1)],t.prototype,"zIndex",void 0),t}(Ee),ET=function(n,t,e,i){return new(e||(e=Promise))(function(r,s){function o(h){try{l(i.next(h))}catch(c){s(c)}}function a(h){try{l(i.throw(h))}catch(c){s(c)}}function l(h){h.done?r(h.value):new e(function(c){c(h.value)}).then(o,a)}l((i=i.apply(n,t||[])).next())})},DT=function(n,t){var i,r,s,o,e={label:0,sent:function(){if(1&s[0])throw s[1];return s[1]},trys:[],ops:[]};return o={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function a(h){return function(c){return function l(h){if(i)throw new TypeError("Generator is already executing.");for(;e;)try{if(i=1,r&&(s=2&h[0]?r.return:h[0]?r.throw||((s=r.return)&&s.call(r),0):r.next)&&!(s=s.call(r,h[1])).done)return s;switch(r=0,s&&(h=[2&h[0],s.value]),h[0]){case 0:case 1:s=h;break;case 4:return e.label++,{value:h[1],done:!1};case 5:e.label++,r=h[1],h=[0];continue;case 7:h=e.ops.pop(),e.trys.pop();continue;default:if(!(s=(s=e.trys).length>0&&s[s.length-1])&&(6===h[0]||2===h[0])){e=0;continue}if(3===h[0]&&(!s||h[1]>s[0]&&h[1]1)for(var i=0;i-1)return e[parseInt(i.toString(),10)];return this.diagram.activeLayer},n.prototype.getLayer=function(t){for(var e=this.diagram.layers,i=0;i=0;o--)this.diagram.unSelect(this.diagram.nameTable[s[parseInt(o.toString(),10)]]),this.diagram.remove(this.diagram.nameTable[s[parseInt(o.toString(),10)]]),"default_layer"!==i.id&&this.diagram.activeLayer.id===t&&(this.diagram.activeLayer=this.diagram.layers[this.diagram.layers.length-1]);delete this.diagram.layerZIndexTable[i.zIndex],this.diagram.layers.splice(r,1),"SVG"!==this.diagram.mode&&this.diagram.refreshDiagramLayer()}},n.prototype.moveObjects=function(t,e){this.diagram.startGroupAction();for(var i={},r=[],s=0;s-1){if(r=[],(h=this.diagram.nameTable[""+s]).children)for(var f=0,g=h.children;f0){for(var y=void 0,S=0,b=r;S0)for(var r=0;r0)for(r=0;r0){t=t.concat(this.diagram.selectedItems.connectors);for(var i=0;i0)for(t=t.concat(this.diagram.selectedItems.nodes),i=0;i0){for(var i=0,r=t.shape.activity.subProcess.processes;i0&&this.copyProcesses(this.processTable[""+s])}this.clipboardData.processTable=this.processTable}},n.prototype.group=function(){this.oldSelectedObjects=nm(this.diagram);var e=this.diagram.isProtectedOnChange;this.diagram.protectPropertyChange(!0),this.diagram.diagramActions=this.diagram.diagramActions|ee.Group;var r={};r.id="group"+Qe(),(r=new te(this.diagram,"nodes",r,!0)).children=[];for(var s=this.diagram.selectedItems.nodes.concat(this.diagram.selectedItems.connectors).sort(function(h,c){return h.zIndex-c.zIndex}),o=0;o0){var a=this.diagram.add(r);a&&this.select(a),this.addHistoryEntry({type:"Group",undoObject:r,redoObject:r,category:"Internal"}),this.diagram.diagramActions=this.diagram.diagramActions&~ee.Group,this.diagram.protectPropertyChange(e)}},n.prototype.unGroup=function(t){var i=this.diagram.isProtectedOnChange;this.diagram.protectPropertyChange(!0),this.diagram.diagramActions=this.diagram.diagramActions|ee.Group;var r=[];t?r.push(t):r=this.diagram.selectedItems.nodes,this.diagram.startGroupAction();for(var s=0;s0&&this.diagram.removePorts(o,o.ports),o.annotations&&o.annotations.length>0&&!ce()&&this.diagram.removeLabels(o,o.annotations);for(var c=this.diagram.nameTable[o.parentId],d=o.children.length-1;d>=0;d--)this.diagram.nameTable[o.children[parseInt(d.toString(),10)]].parentId="",this.diagram.deleteChild(this.diagram.nameTable[o.children[parseInt(d.toString(),10)]],o),o.parentId&&o.children[parseInt(d.toString(),10)]&&this.diagram.addChild(c,o.children[parseInt(d.toString(),10)]);this.resetDependentConnectors(o.inEdges,!0),this.resetDependentConnectors(o.outEdges,!1),this.diagram.diagramActions&ee.UndoRedo||this.addHistoryEntry({type:"UnGroup",undoObject:a,redoObject:a,category:"Internal"}),o.parentId&&this.diagram.deleteChild(o,c)}this.diagram.removeNode(o,l),this.clearSelection()}this.diagram.endGroupAction(),this.diagram.diagramActions=this.diagram.diagramActions&~ee.Group,this.diagram.protectPropertyChange(i)},n.prototype.resetDependentConnectors=function(t,e){for(var i=0;i0&&(g=!1)}if(g){var y=this.cloneConnector(p,i);c.push(y),o[h.id]=y.id}}else{var S=this.cloneNode(h,i);if(c.push(S),S){o[h.id]=S.id;var b=h.inEdges;if(b)for(var M=0,w=b;M0)for(var u=0;u0)for(r=t.segments,s=0;s0&&this.diagram.drawingObject&&"Bezier"===this.diagram.drawingObject.type&&(t.segments=[]);var e=this.diagram.add(t);"SVG"!==this.diagram.mode&&this.diagram.refreshDiagramLayer(),this.selectObjects([e]),t&&!HI(this.diagram)&&(this.diagram.tool&=~Ci.DrawOnce,this.diagram.currentDrawingObject=void 0)},n.prototype.enableServerDataBinding=function(t){this.diagram.enableServerDataBinding(t)},n.prototype.addText=function(t,e){var i=this.diagram.findElementUnderMouse(t,e,this.diagram);this.diagram.startTextEdit(t,i instanceof ni?i.id.split("_")[1]:void 0)},n.prototype.isUserHandle=function(t){var e=this.diagram.selectedItems;if(e.wrapper&&qr(e.constraints,"UserHandle"))for(var i=0,r=e.userHandles;i0&&t[0]&&t[0].isLane)for(s=this.diagram.getObject(t[0].parentId),t[0].shape.header=[],a=0;a1||e&&1===t.length)){if(1!==t.length)return[2];this.clearSelection()}if(!(u||d||1!==t.length||e&&Xa(this.diagram)))return this.clearSelection(),[2]}if(!r.cancel){for(p=0;p0||e)&&f.children&&!f.parentId)for(g=0;g0||e,!0)}else this.select(f,p>0||e,!0);void 0===i&&(i=c),r={oldValue:i||[],newValue:this.getSelectedObject(),cause:this.diagram.diagramActions,state:"Changed",type:"Addition",cancel:!1},this.diagram.renderSelector(e||t&&t.length>1),ce()||this.diagram.triggerEvent(Ce.selectionChange,r),this.diagram.enableServerDataBinding(!0)}return[2]})})},n.prototype.findParent=function(t){return t.parentId&&this.findParent(t=this.diagram.nameTable[t.parentId]),t},n.prototype.selectProcesses=function(t){if(this.hasProcesses(t))for(var e=t.shape.activity.subProcess.processes,i=0;i0)},n.prototype.select=function(t,e,i){var r=this.getObjectLayer(t.id);if(Dd(t)&&!(t instanceof si)&&!_r(this.diagram,t)&&r&&!r.lock&&r.visible&&t.wrapper.visible){(e=!!Xa(this.diagram)&&e)||this.clearSelection(),this.diagram.enableServerDataBinding(!1);var s=this.diagram.selectedItems;if(t instanceof te?s.nodes.push(t.isHeader?this.diagram.nameTable[t.parentId]:t):s.connectors.push(t),s.selectedObjects.push(t),e)s.wrapper.rotateAngle=s.rotateAngle=0,s.wrapper.children.push(t.wrapper);else if(s.init(this.diagram),1===s.nodes.length&&0===s.connectors.length){var l=Wx(this.diagram,s);l&&(s.wrapper.children[0]=l),s.rotateAngle=s.nodes[0].rotateAngle,s.wrapper.rotateAngle=s.nodes[0].rotateAngle,s.wrapper.pivot=s.nodes[0].pivot}i||this.diagram.renderSelector(e),this.diagram.enableServerDataBinding(!0)}},n.prototype.labelSelect=function(t,e){this.oldSelectedObjects=nm(this.diagram);var i=this.diagram.selectedItems,r=this.diagram.allowServerDataBinding;this.diagram.allowServerDataBinding=!1,i.nodes=i.connectors=[],this.diagram.allowServerDataBinding=r,t instanceof te?i.nodes[0]=t:i.connectors[0]=t,i.annotation=this.findTarget(e,t),i.init(this.diagram),this.diagram.renderSelector(!1)},n.prototype.unSelect=function(t){var e=this.diagram.selectedItems.nodes.concat(this.diagram.selectedItems.connectors),i=e.filter(function(a){return a.id!==t.id}),r={oldValue:e,newValue:i,cause:this.diagram.diagramActions,state:"Changing",type:"Removal",cancel:!1};if(this.diagram.currentSymbol||ce()||this.diagram.triggerEvent(Ce.selectionChange,r),_r(this.diagram,t)){var s=this.diagram.selectedItems,o=void 0;t instanceof te?(o=s.nodes.indexOf(t,0),s.nodes.splice(o,1)):(o=s.connectors.indexOf(t,0),s.connectors.splice(o,1)),o=s.selectedObjects.indexOf(t,0),s.selectedObjects.splice(o,1),(r={oldValue:e,newValue:i,cause:this.diagram.diagramActions,state:"Changed",type:"Removal",cancel:(r={oldValue:e,newValue:i,cause:this.diagram.diagramActions,state:"Changed",type:"Removal",cancel:!1}).cancel}).cancel||(o=s.wrapper.children.indexOf(t.wrapper,0),s.wrapper.children.splice(o,1),this.diagram.updateSelector(),this.diagram.currentSymbol||this.diagram.triggerEvent(Ce.selectionChange,r))}},n.prototype.moveSvgNode=function(t,e){var i=xt(e+"_groupElement",this.diagram.element.id),r=xt(t+"_groupElement",this.diagram.element.id);i.parentNode.insertBefore(r,i)},n.prototype.moveAfterSvgNode=function(t,e){var i=xt(e+"_groupElement",this.diagram.element.id),r=xt(t+"_groupElement",this.diagram.element.id);i.insertAdjacentElement("afterend",r)},n.prototype.sendLayerBackward=function(t){var e=this.getLayer(t);if(e&&0!==e.zIndex){var i=e.zIndex;if("SVG"===this.diagram.mode){var r=e.objects,s=this.getLayer(this.diagram.layerZIndexTable[i-1]).objects[0];if(s)for(var o=0,a=r;od&&"SwimLane"!==f.shape.type){var S=$(f);f.zIndex=d-((-1!==i.indexOf(f)?i.indexOf(f):0)+1),f.children&&(d=this.findLowestZIndex(f,c)||d),this.triggerOrderCommand(S,f,f),f.children&&this.updateGroupZindex(f,"SendToBack",d)}else"SwimLane"===f.shape.type&&(y=this.swapZIndexObjects(a,h,r,g));if("SVG"===this.diagram.mode){for(var M="SwimLane"!==this.diagram.nameTable[""+r].shape.type?d:y,w=h[parseInt(M.toString(),10)];!w&&Md)&&(d=p.zIndex)}for(var f=JSON.parse(JSON.stringify(l)),v=Number(Object.keys(l).sort(function(wo,Hl){return Number(wo)-Number(Hl)}).reverse()[0]),y=this.diagram.nameTable[""+e].zIndex,S=[],M=0;M<=v;M++)S.push(l[parseInt(M.toString(),10)]);if("SwimLane"===this.diagram.nameTable[""+e].shape.type)for(var C=v;C>=y;C--)if(l[parseInt(C.toString(),10)]&&this.diagram.nameTable[l[parseInt(C.toString(),10)]].parentId!==e){v=C;break}var D=this.diagram.nameTable[""+e];if(D.zIndexx&&(x=L.zIndex)}}else x=d;D.zIndex=x+((-1!==r.indexOf(D)?r.indexOf(D):0)+1),this.triggerOrderCommand(A,D,D)}else if("SwimLane"===D.shape.type){for(var O=0,N=-1,T=0,P=0,_=JSON.parse(JSON.stringify(l)),B=0;B<=y;B++)if(l[parseInt(B.toString(),10)]&&this.diagram.nameTable[l[parseInt(B.toString(),10)]].parentId===e&&-1===N){N=B,T=B;break}for(var j=0;j<=v;j++)f[parseInt(j.toString(),10)]&&f[parseInt(j.toString(),10)]!==e&&this.diagram.nameTable[f[parseInt(j.toString(),10)]].parentId!==e&&this.diagram.nameTable[f[parseInt(j.toString(),10)]].zIndex>=this.diagram.nameTable[""+e].zIndex&&O++;for(var ue=N,pe=0;pe<=O;pe++){for(;!l[parseInt(ue.toString(),10)];)ue++;P=this.diagram.nameTable[l[parseInt(ue.toString(),10)]].zIndex,ue++}for(var Me=P;Me<=v;Me++){for(;!_[parseInt(N.toString(),10)];)N++;for(;!l[parseInt(Me.toString(),10)];)Me++;l[parseInt(Me.toString(),10)]=_[parseInt(N.toString(),10)],this.diagram.nameTable[l[parseInt(Me.toString(),10)]].zIndex=Me,N++}l[parseInt(v.toString(),10)]=this.diagram.nameTable[""+e].id,this.diagram.nameTable[""+e].zIndex=v,ue=y+1;for(var De=T,xe=0;xe0&&("Native"===hr[0].shape.type||"HTML"===hr[0].shape.type)){for(Mi.parentNode.removeChild(Mi),De=0;De0?r[0]:null},n.prototype.findLowestZIndex=function(t,e){var r=this.diagram.nodes.filter(function(s){return-1!==e.indexOf(s.id)}).filter(function(s){return""===s.parentId&&s.id!==t.id}).map(function(s){return s.zIndex});return r.sort(function(s,o){return s-o}),r.length>0?r[0]:null},n.prototype.triggerOrderCommand=function(t,e,i){var s={zIndex:$(t).zIndex},o={zIndex:e.zIndex},a={element:i,cause:this.diagram.diagramActions,diagramAction:this.diagram.getDiagramAction(this.diagram.diagramActions),oldValue:s,newValue:o};this.diagram.triggerEvent(Ce.propertyChange,a)},n.prototype.checkGroupNode=function(t,e,i){return i[""+e].parentId===i[""+t].parentId},n.prototype.sortByZIndex=function(t,e,i){if("BringForward"===i){var r=e||"zIndex";t=t.sort(function(o,a){return a[""+r]-o[""+r]})}else{var s=e||"zIndex";t=t.sort(function(o,a){return o[""+s]-a[""+s]})}return t},n.prototype.orderCommands=function(t,e,i){var r=this,s=e.nodes;if(s=s.concat(e.connectors),t)if("SendBackward"===i)for(var o=0;oa}),S=v.filter(function(D){return D0?Math.max.apply(Math,S):a,M=y.length>0?Math.min.apply(Math,y):a;if(a!==M){var w=c.zIndexTable[parseInt(M.toString(),10)],C=c.zIndexTable[parseInt(a.toString(),10)];this.moveSvgNode(C,w)}else"SendToBack"===i&&(w=c.zIndexTable[parseInt(a.toString(),10)],C=c.zIndexTable[parseInt(b.toString(),10)],this.moveAfterSvgNode(w,C))}}else this.diagram.refreshCanvasLayers()}},n.prototype.sendForward=function(t){var e=this;if(this.diagram.protectPropertyChange(!0),Xa(this.diagram)||t){$(t||(this.diagram.selectedItems.nodes.length?this.diagram.selectedItems.nodes[0]:this.diagram.selectedItems.connectors[0]));var s=t&&t.id,o=this.diagram.layers.indexOf(this.getObjectLayer(s=s||(this.diagram.selectedItems.nodes.length?this.diagram.selectedItems.nodes[0].id:this.diagram.selectedItems.connectors[0].id))),a=$(this.diagram.nameTable),h=(parseInt(o.toString(),10),this.diagram.nameTable[""+s]),c=[],d=this.diagram.spatialSearch.findObjects(h.wrapper.bounds);d.length>2&&(d=this.sortByZIndex(d,void 0,"BringForward"));for(var u=0,p=d;u=0;f--)this.diagram.nameTable[c[parseInt(f.toString(),10)].id].parentId===s&&c.splice(f,1);if(c.length>0){var y=this.diagram.nameTable[c[c.length-1].id];if(y.parentId){var b=om(y,this.diagram,""),M=this.diagram.nameTable[""+b];M.id!==s&&(c[0]=M)}var w={};for(f=0;f0&&(Object.values(O).forEach(function(ue){ue>=T&&N.push(ue)}),0!==N.length&&this.updateZIndexBySendForward(h,N,o))}var P=[];if(Object.keys(this.changedNodeZIndexes).forEach(function(ue){if((a[""+ue]?a[""+ue].zIndex:null)!==e.changedNodeZIndexes[""+ue]){var De=$(a[""+ue]);P.push(De)}}),this.updateLayerZindexTable(o),L.nodes.splice(0,L.nodes.length),P.forEach(function(ue){var pe=$(ue);L.nodes.push(pe)}),"SVG"===this.diagram.mode){var _=c[c.length-1].id,B=c[c.length-1];B&&!("HTML"===B.shape.type||"Native"===B.shape.type)&&this.moveAfterSvgNode(s,_),this.updateNativeNodeIndex(_,s)}else this.diagram.refreshCanvasLayers();var j=[];Object.keys(this.changedNodeZIndexes).forEach(function(ue){if((a[""+ue]?a[""+ue].zIndex:null)!==e.changedNodeZIndexes[""+ue]){var De=$(e.diagram.nameTable[""+ue]);j.push(De)}});var Q=$(this.diagram.selectedItems);Q.nodes.splice(0,Q.nodes.length),j.forEach(function(ue){var pe=$(ue);Q.nodes.push(pe)}),this.diagram.diagramActions&ee.UndoRedo||this.addHistoryEntry({type:"SendForward",category:"Internal",undoObject:L,redoObject:Q}),this.diagram.endGroupAction()}}this.diagram.protectPropertyChange(!1)},n.prototype.updateZIndexBySendForward=function(t,e,i){var r=$(t);t.zIndex=Math.min.apply(Math,e);var a,s=Math.min.apply(Math,e),o=Math.min.apply(Math,e),l=this.diagram.layers[parseInt(i.toString(),10)].objects,h=this.diagram.nodes.filter(function(S){return-1!==l.indexOf(S.id)});t.children&&this.updateGroupZindex(t,"BringForward",t.zIndex);var c=h.filter(function(S){return S.zIndex===Math.min.apply(Math,e)&&S.id!==t.id});if(c&&c.length>0&&c[0].children){for(var d=Math.min.apply(Math,e),u=0;uo&&g!==t&&g.parentId!==t.id&&c&&c.length>0&&g.parentId!==c[0].id){var v=$(g);g.zIndex=a+1,a++,this.triggerOrderCommand(v,g,g)}var y=g.zIndex;this.changedNodeZIndexes[g.id]=(this.changedNodeZIndexes.hasOwnProperty(g.id),y)}},n.prototype.arrangeZIndexForLowerNodes=function(t,e,i){var r=i.filter(function(o){return o.zIndex<=t&&o.parentId!==e.id});r.sort(function(o,a){return a.zIndex-o.zIndex});for(var s=0;se&&(e=r.zIndex)}return e},n.prototype.sendBackward=function(t){var e=this;if(this.diagram.protectPropertyChange(!0),Xa(this.diagram)||t){$(t||(this.diagram.selectedItems.nodes.length?this.diagram.selectedItems.nodes[0]:this.diagram.selectedItems.connectors[0]));var s=t&&t.id,o=this.diagram.layers.indexOf(this.getObjectLayer(s=s||(this.diagram.selectedItems.nodes.length?this.diagram.selectedItems.nodes[0].id:this.diagram.selectedItems.connectors[0].id))),a=$(this.diagram.nameTable),h=(parseInt(o.toString(),10),this.diagram.nameTable[""+s]),c=[],d=this.diagram.spatialSearch.findObjects(h.wrapper.bounds);d.length>2&&(d=this.sortByZIndex(d));for(var u=0,p=d;uNumber(f.zIndex)&&""===f.parentId&&h.wrapper.bounds.intersects(f.wrapper.bounds)&&c.push(f);for(var f=c.length-1;f>=0;f--)(v=this.diagram.nameTable[c[parseInt(f.toString(),10)].id]).parentId===s&&c.splice(f,1);if(c.length>0){var v;if((v=this.diagram.nameTable[c[c.length-1].id]).parentId){var S=om(v,this.diagram,""),b=this.diagram.nameTable[""+S];s!==b.id&&(c[c.length-1]=b)}var M={};for(f=0;f0&&(Object.values(L).forEach(function(pe){pe<=N&&O.push(pe)}),0!==O.length&&this.updateZIndexBySendBackward(h,O,o))}var T=[];if(Object.keys(this.changedNodeZIndexes).forEach(function(pe){if((a[""+pe]?a[""+pe].zIndex:null)!==e.changedNodeZIndexes[""+pe]){var xe=$(a[""+pe]);T.push(xe)}}),this.updateLayerZindexTable(o),R.nodes.splice(0,R.nodes.length),T.forEach(function(pe){var Me=$(pe);R.nodes.push(Me)}),"SVG"===this.diagram.mode){var P=c[c.length-1].id,_=c[c.length-1];_&&"HTML"!==_.shape.type&&"Native"!==_.shape.type&&this.moveSvgNode(s,P);var B=this.diagram.nameTable[""+P];B.children&&B.children.length>0?this.updateNativeNodeIndex(s):this.updateNativeNodeIndex(s,P)}else this.diagram.refreshCanvasLayers();var j=[];Object.keys(this.changedNodeZIndexes).forEach(function(pe){if((a[""+pe]?a[""+pe].zIndex:null)!==e.changedNodeZIndexes[""+pe]){var xe=$(e.diagram.nameTable[""+pe]);j.push(xe)}});var Q=$(this.diagram.selectedItems);Q.nodes.splice(0,Q.nodes.length),j.forEach(function(pe){var Me=$(pe);Q.nodes.push(Me)}),this.diagram.diagramActions&ee.UndoRedo||this.addHistoryEntry({type:"SendBackward",category:"Internal",undoObject:R,redoObject:Q}),this.diagram.endGroupAction()}}this.diagram.protectPropertyChange(!1)},n.prototype.updateZIndexBySendBackward=function(t,e,i){var r=$(t);t.zIndex=Math.max.apply(Math,e);var p,s=t.zIndex,o=Math.max.apply(Math,e),a=this.diagram.layers[parseInt(i.toString(),10)].objects,l=this.diagram.nodes.filter(function(S){return-1!==a.indexOf(S.id)}),h=l.filter(function(S){return S.zIndex===Math.max.apply(Math,e)&&S.id!==t.id});if(h&&h.length>0&&h[0].children)for(var c=Math.max.apply(Math,e),d=0;d0&&g.parentId!==h[0].id){var v=$(g);g.zIndex=p-1,p--,this.triggerOrderCommand(v,g,g)}var y=g.zIndex;this.changedNodeZIndexes[""+g.id]=(this.changedNodeZIndexes.hasOwnProperty(g.id),y)}},n.prototype.findLowestChildZIndex=function(t){for(var e=t.zIndex,i=0;i0),this.selectObjects([t],!0))},n.prototype.clearSelection=function(t,e){return ET(this,void 0,void 0,function(){var i,r,s,o;return DT(this,function(a){return i=this.diagram.allowServerDataBinding,this.diagram.enableServerDataBinding(!1),Xa(this.diagram)&&(r=this.diagram.selectedItems,s=this.getSelectedObject(),this.diagram.currentSymbol&&(this.diagram.previousSelectedObject=s),o={oldValue:s,newValue:[],cause:this.diagram.diagramActions,state:"Changing",type:"Removal",cancel:!1},t&&(ce()||this.diagram.triggerEvent(Ce.selectionChange,o)),o.cancel||(r.offsetX=0,r.offsetY=0,r.width=0,r.height=0,r.rotateAngle=0,r.nodes=[],r.connectors=[],r.wrapper=null,r.annotation=void 0,r.selectedObjects=[],this.diagram.clearSelectorLayer(),t&&(o={oldValue:s,newValue:[],cause:this.diagram.diagramActions,state:"Changed",type:"Removal",cancel:!1},ce()||this.diagram.triggerEvent(Ce.selectionChange,o))),this.diagram.enableServerDataBinding(i)),[2]})})},n.prototype.clearSelectedItems=function(){this.clearSelection((this.diagram.selectedItems.nodes?this.diagram.selectedItems.nodes.length:0)+(this.diagram.selectedItems.connectors?this.diagram.selectedItems.connectors.length:0)>0)},n.prototype.removeStackHighlighter=function(){var t=zl(this.diagram.element.id),e=t.getElementById(t.id+"_stack_highlighter");e&&e.parentNode.removeChild(e)},n.prototype.renderStackHighlighter=function(t,e){var r,s,o,i=this.diagram.selectedItems.nodes[0];if(!e){var a=this.diagram.findObjectsUnderMouse(t.position);if((e=this.diagram.findObjectUnderMouse(a,"Drag",!0))&&!(e.isLane||e.isPhase||e.isHeader))for(var l=0;l0)for(var a=0;a1)if(i){var h=l.segments[0],c=l.segments[1],u=Tc(DI(t.wrapper,t.wrapper.corners,t.wrapper.bounds),h.direction),g=Nl({corners:void 0,point:u=Nh(l,0,u,{x:l.sourceWrapper.offsetX,y:l.sourceWrapper.offsetY},!1),margin:void 0,direction:h.direction},{corners:void 0,point:c.points[1],margin:void 0,direction:void 0});h.length=z.distancePoints(g[0],g[1]),c.direction&&c.length&&(c.length=z.distancePoints(g[1],g[2]))}else if(o){switch(l.segments[0].direction){case"Bottom":r=t.wrapper.bounds.bottomCenter.x-e.bottomCenter.x,s=t.wrapper.bounds.bottomCenter.y-e.bottomCenter.y;break;case"Top":r=t.wrapper.bounds.topCenter.x-e.topCenter.x,s=t.wrapper.bounds.topCenter.y-e.topCenter.y;break;case"Left":r=t.wrapper.bounds.middleLeft.x-e.middleLeft.x,s=t.wrapper.bounds.middleLeft.y-e.middleLeft.y;break;case"Right":r=t.wrapper.bounds.middleRight.x-e.middleRight.x,s=t.wrapper.bounds.middleRight.y-e.middleRight.y}this.dragSourceEnd(l,r,s,!0,null,"ConnectorSourceEnd",void 0,void 0,void 0,!(t.parentId&&this.diagram.diagramActions&ee.isGroupDragging))}}},n.prototype.updateEndPoint=function(t,e){var r={sourcePoint:t.sourcePoint,targetPoint:t.targetPoint};t.sourceID&&(r.sourceID=t.sourceID),t.targetID&&(r.targetID=t.targetID),t.sourcePortID&&(r.sourcePortID=t.sourcePortID),t.targetPortID&&(r.targetPortID=t.targetPortID),t.segments&&(r.segments=t.segments),this.diagram.connectorPropertyChange(t,e||{},r),this.diagram.updateSelector()},n.prototype.dragSourceEnd=function(t,e,i,r,s,o,a,l,h,c,d){var u=this.diagram.nameTable[t.id],p={},f=this.checkBoundaryConstraints(e,i,u.wrapper.bounds);if(NI(u)&&f&&"BezierSourceThumb"!==o&&Wv(this.diagram)&&(p=$(p={sourcePoint:u.sourcePoint}),u.sourcePoint.x+=e,u.sourcePoint.y+=i,"ConnectorSourceEnd"===o&&"Orthogonal"===u.type&&this.changeSegmentLength(u,l,h,c),"Bpmn"===u.shape.type&&"Default"===u.shape.sequence&&"Sequence"===u.shape.flow&&this.updatePathElementOffset(u)),"Bezier"===u.type)if(p={sourcePoint:u.sourcePoint},d)this.translateBezierPoints(t,""===o?"ConnectorSourceEnd":o,e,i,d,s,!a);else for(var g=0;g2){var d=z.direction((c=t.segments[2]).points[0],c.points[1]);o.direction===ls(d)?("Right"===o.direction?c.points[0].x=o.points[o.points.length-1].x=l.wrapper.corners.middleRight.x+20:"Left"===o.direction?c.points[0].x=o.points[o.points.length-1].x=l.wrapper.corners.middleLeft.x-20:c.points[0].y=o.points[o.points.length-1].y="Top"===o.direction?l.wrapper.corners.topCenter.y-20:l.wrapper.corners.bottomCenter.y+20,c.direction&&c.length&&(c.length=z.distancePoints(c.points[0],c.points[c.points.length-1])),o.length=z.distancePoints(o.points[0],o.points[o.points.length-1])):o.direction===d&&c.direction&&c.length?("Top"===o.direction||"Bottom"===o.direction?(c.points[0]=o.points[0],c.points[c.points.length-1].x=c.points[0].x):(c.points[0]=o.points[0],c.points[c.points.length-1].y=c.points[0].y),c.length=z.distancePoints(c.points[0],c.points[c.points.length-1]),t.segments.splice(0,2)):o.length=20}else o.length=20;else if(o.length<1)if(""!==t.sourceID){var c;"Right"===a.direction?a.points[a.points.length-1].y=(h=l.wrapper.corners.middleRight).y:"Left"===a.direction?a.points[a.points.length-1].y=(h=l.wrapper.corners.middleLeft).y:a.points[a.points.length-1].x="Top"===a.direction?(h=l.wrapper.corners.topCenter).x:(h=l.wrapper.corners.bottomCenter).x,a.length=z.distancePoints(h,a.points[a.points.length-1]),t.segments.length>2&&(c=t.segments[2]).direction&&c.length&&(c.length=z.distancePoints(a.points[a.points.length-1],c.points[c.points.length-1])),t.segments.splice(0,1)}else t.segments.splice(0,1)}else e&&!i&&t.sourceID!==e.id&&t.segments&&null!==t.segments[0].direction&&e&&e instanceof te&&s&&this.changeSourceEndToNode(t,e),e&&i&&t.sourcePortID!==i&&t.segments&&null!==t.segments[0].direction&&e&&e instanceof te&&s&&this.changeSourceEndToPort(t,e,i)},n.prototype.canConnect=function(t,e){return!(!da(e)||!kh(e))},n.prototype.changeSourceEndToPort=function(t,e,i){var r=this.diagram.getWrapper(e.wrapper,i),s={x:r.offsetX,y:r.offsetY},o=zo(s,En(e.wrapper),e.wrapper.bounds),a=t.segments[0],l=t.segments[1];if(a.direction!==o){var h=[],c={};if(a.direction===ls(o)){c={};var d=void 0;"Top"===o||"Bottom"===o?(d="Top"===o?{type:"Orthogonal",isTerminal:!0,direction:o,length:Math.abs(a.points[0].y-s.y)}:{type:"Orthogonal",isTerminal:!0,direction:o,length:Math.abs(s.y-a.points[0].y)},c=a.points[0].x>s.x?{type:"Orthogonal",isTerminal:!0,direction:"Right",length:a.points[0].x-s.x}:{type:"Orthogonal",isTerminal:!0,direction:"Left",length:s.x-a.points[0].x}):(d="Right"===o?{type:"Orthogonal",isTerminal:!0,direction:o,length:Math.abs(a.points[0].x-s.x)}:{type:"Orthogonal",isTerminal:!0,direction:o,length:Math.abs(s.x-a.points[0].x)},c=a.points[0].y>s.y?{type:"Orthogonal",direction:"Top",isTerminal:!0,length:a.points[0].y-s.y}:{type:"Orthogonal",direction:"Bottom",isTerminal:!0,length:s.y-a.points[0].y}),h.push(new bi(t,"segments",d,!0)),h.push(new bi(t,"segments",c,!0))}else h.push(new bi(t,"segments",c={type:"Orthogonal",direction:o,length:20,isTerminal:!0},!0));a.direction!==ls(o)&&("Top"===o||"Bottom"===o?(a.points[0].x=s.x,a.points[0].y=a.points[a.points.length-1].y="Top"===o?s.y-20:s.y+20):(a.points[0].y=s.y,a.points[0].x=a.points[a.points.length-1].x="Right"===o?s.x+20:s.x-20),a.length=z.distancePoints(a.points[0],a.points[a.points.length-1]),l.length=z.distancePoints(a.points[a.points.length-1],l.points[l.points.length-1])),t.segments=h.concat(t.segments)}else a.points[0]=s,"Top"===o||"Bottom"===o?a.points[a.points.length-1].x=s.x:a.points[a.points.length-1].y=s.y,a.length=z.distancePoints(a.points[0],a.points[a.points.length-1]),l.length=z.distancePoints(a.points[a.points.length-1],l.points[l.points.length-1])},n.prototype.removeTerminalSegment=function(t,e){for(var i=0;ii.width||"Left"===o.direction&&r.x>=o.points[0].x||"Right"===o.direction&&r.x<=o.points[0].x)o.points[0].y=o.points[o.points.length-1].y=r.y,o.points[0].x=r.x,o.length=z.distancePoints(o.points[0],o.points[o.points.length-1]),a.length=z.distancePoints(o.points[o.points.length-1],a.points[a.points.length-1]);else{var h=void 0;s="Bottom"===(h=a.direction?a.direction:z.direction(a.points[0],a.points[a.points.length-1]))?i.bottomCenter:i.topCenter,a.length&&a.direction&&(a.length="Top"===h?o.points[o.points.length-1].y-(s.y+20):s.y+20-o.points[o.points.length-1].y),o.length=o.points[o.points.length-1].x-s.x,o.direction=o.length>0?"Right":"Left",l.push(new bi(t,"segments",{type:"Orthogonal",direction:h,length:20},!0)),t.segments=l.concat(t.segments)}else r="Bottom"===o.direction?i.bottomCenter:i.topCenter,o.length>i.height||"Top"===o.direction&&r.y>=o.points[0].y||"Bottom"===o.direction&&r.y<=o.points[0].y?(o.points[0].x=o.points[o.points.length-1].x=r.x,o.points[0].y=r.y,o.length=z.distancePoints(o.points[0],o.points[o.points.length-1]),a.length=z.distancePoints(o.points[o.points.length-1],a.points[a.points.length-1])):(s="Left"===a.direction?i.middleLeft:i.middleRight,h=void 0,h=a.direction?a.direction:z.direction(a.points[0],a.points[a.points.length-1]),a.length&&a.direction&&(a.length="Left"===h?o.points[o.points.length-1].x-(s.x+20):s.x+20-o.points[o.points.length-1].x),o.length=o.points[o.points.length-1].y-s.y,o.direction=o.length>0?"Bottom":"Top",l.push(new bi(t,"segments",{type:"Orthogonal",direction:h,length:20},!0)),t.segments=l.concat(t.segments))},n.prototype.translateBezierPoints=function(t,e,i,r,s,o,a){var l=t.segments.indexOf(s),h=t.segments[parseInt(l.toString(),10)],c=l>0?t.segments[l-1]:null,d=null!==c?c.point:t.sourcePoint,u=l===t.segments.length-1?t.targetPoint:h.point;if(h)if("BezierSourceThumb"===e&&(h.vector1.angle||h.vector1.distance)){var p=h.vector1.distance,f=h.vector1.angle;h.vector1={distance:t.distance(d,o),angle:z.findAngle(d,o)},this.translateSubsequentSegment(t,s,!0,h.vector1.distance-p,h.vector1.angle-f)}else"BezierTargetThumb"===e&&(h.vector2.angle||h.vector2.distance)?(p=h.vector2.distance,f=h.vector2.angle,h.vector2={distance:t.distance(u,o),angle:z.findAngle(u,o)},this.translateSubsequentSegment(t,s,!1,h.vector2.distance-p,h.vector2.angle-f)):("ConnectorSourceEnd"===e&&!t.sourceID||"ConnectorTargetEnd"===e&&!t.targetID)&&a&&$I(h.vector1)&&$I(h.vector2)?(z.isEmptyPoint(h.point1)&&(h.bezierPoint1=ZI(t.sourcePoint,t.targetPoint)),z.isEmptyPoint(h.point2)&&(h.bezierPoint2=ZI(t.targetPoint,t.sourcePoint))):"BezierSourceThumb"===e||"ConnectorSourceEnd"===e&&!a&&$I(h.vector1)?(h.bezierPoint1.x+=i,h.bezierPoint1.y+=r,(!z.isEmptyPoint(h.point1)||a)&&(h.point1={x:h.bezierPoint1.x,y:h.bezierPoint1.y})):("BezierTargetThumb"===e||"ConnectorTargetEnd"===e&&!a&&$I(h.vector2))&&(h.bezierPoint2.x+=i,h.bezierPoint2.y+=r,(!z.isEmptyPoint(h.point2)||a)&&(h.point2={x:h.bezierPoint2.x,y:h.bezierPoint2.y}))},n.prototype.translateSubsequentSegment=function(t,e,i,r,s){var o=t.segments.indexOf(e);parseInt(o.toString(),10),t.bezierSettings.smoothness&bI.SymmetricAngle||(s=null),t.bezierSettings.smoothness&bI.SymmetricDistance||(r=null),(null!=r||null!=s)&&(i?0!==o&&this.updatePreviousBezierSegment(t,o,r,s):o!==t.segments.length-1&&this.updateNextBezierSegment(t,o,r,s))},n.prototype.updatePreviousBezierSegment=function(t,e,i,r){var s=t.segments[e-1],a=(s.vector2.angle+r)%360;a<0&&(a+=360),s.vector2={distance:s.vector2.distance+i,angle:a}},n.prototype.updateNextBezierSegment=function(t,e,i,r){var s=t.segments[e+1],a=(s.vector1.angle+r)%360;a<0&&(a+=360),s.vector1={distance:s.vector1.distance+i,angle:a}},n.prototype.dragTargetEnd=function(t,e,i,r,s,o,a,l){var c,h=this.diagram.nameTable[t.id],d=this.checkBoundaryConstraints(e,i,h.wrapper.bounds);if(OI(h)&&"BezierTargetThumb"!==o&&d&&Wv(this.diagram)){if(c=$(c={targetPoint:h.targetPoint}),h.targetPoint.x+=e,h.targetPoint.y+=i,"ConnectorTargetEnd"===o&&"Orthogonal"===h.type&&h.segments&&h.segments.length>0){var u=h.segments[h.segments.length-2];u&&2===h.segments[h.segments.length-1].points.length&&("Left"===u.direction||"Right"===u.direction?u.points[u.points.length-1].x=h.targetPoint.x:u.points[u.points.length-1].y=h.targetPoint.y,u.length=z.distancePoints(u.points[0],u.points[u.points.length-1]),u.direction=z.direction(u.points[0],u.points[u.points.length-1]))}"Bpmn"===h.shape.type&&"Default"===h.shape.sequence&&"Sequence"===h.shape.flow&&this.updatePathElementOffset(h)}if("Bezier"===h.type)if(c={targetPoint:h.targetPoint},l)this.translateBezierPoints(t,""===o?"ConnectorTargetEnd":o,e,i,l,s,!a);else for(var p=0;p0){if(void 0!==s&&o.segments[parseInt(s.toString(),10)])if("Bezier"===o.type){var a=o.segments[parseInt(s.toString(),10)],l=a.isInternalSegment;l&&null!==o.bezierSettings&&"FreeForm"!==o.bezierSettings.segmentEditOrientation?("Horizontal"===a.orientation?a.point.x+=e:a.point.y+=i,this.updateDirectionalBezierCurve(o)):(a.point.x+=e,a.point.y+=i),l&&(o.isBezierEditing=!0)}else o.segments[parseInt(s.toString(),10)].point.x+=e,o.segments[parseInt(s.toString(),10)].point.y+=i;else for(var h=0;h1){var a=e[1],l=e[2],h={x:.5*(a.x+l.x),y:.5*(a.y+l.y)},c=t.segments[0];c.vector1.angle=Gt(s,a),c.vector1.distance=.5*z.findLength(s,a),c.vector2.angle=Gt(h,a),c.vector2.distance=.5*z.findLength(h,a),c.point=h;var d=t.segments[1];if(d.vector1.angle=Gt(h,l),d.vector1.distance=.5*z.findLength(h,l),t.segments.length>2){var u=e[3],p={x:.5*(l.x+u.x),y:.5*(l.y+u.y)};d.vector2.angle=Gt(p,l),d.vector2.distance=.5*z.findLength(p,l),d.point=p;var f=t.segments[2];if(f.vector1.angle=Gt(p,u),f.vector1.distance=.5*z.findLength(p,u),t.segments.length>3){var g=e[4],v={x:.5*(u.x+g.x),y:.5*(u.y+g.y)};f.vector2.angle=Gt(v,u),f.vector2.distance=.5*z.findLength(v,u),f.point=v;var y=t.segments[3];y.vector1.angle=Gt(v,g),y.vector1.distance=.5*z.findLength(v,g),y.vector2.angle=Gt(o,g),y.vector2.distance=.5*z.findLength(o,g)}else f.vector2.angle=Gt(o,u),f.vector2.distance=.5*z.findLength(o,u)}else d.vector2.angle=Gt(o,l),d.vector2.distance=.5*z.findLength(o,l)}},n.prototype.rotateObjects=function(t,e,i,r,s){r=r||{};var o=Hi();qi(o,i,r.x,r.y);for(var l=0,h=e;l0){this.diagram.protectPropertyChange(!0);var o=t;o.segments=[],this.diagram.connectorPropertyChange(o,{},{segments:o.segments}),this.diagram.protectPropertyChange(!1)}}},n.prototype.updateInnerParentProperties=function(t){var r=this.diagram.isProtectedOnChange;this.diagram.protectPropertyChange(!0);for(var s=this.getAllDescendants(t,[],!1,!0),o=0;o0&&(p=this.diagram.bpmnModule.getChildrenBound(d,d.id,this.diagram),u=d.wrapper.bounds.containsRect(p)),h=d.wrapper.actualSize.width*t,c=d.wrapper.actualSize.height*e,void 0!==d.maxWidth&&0!==d.maxWidth&&(h=Math.min(d.maxWidth,h)),void 0!==d.minWidth&&0!==d.minWidth&&(h=Math.max(d.minWidth,h)),void 0!==d.maxHeight&&0!==d.maxHeight&&(c=Math.min(d.maxHeight,c)),void 0!==d.minHeight&&0!==d.minHeight&&(c=Math.max(d.minHeight,c)),u&&(h=Math.max(h,p.right-d.wrapper.bounds.x),c=Math.max(c,p.bottom-d.wrapper.bounds.y)),t=h/d.actualSize.width,e=c/d.actualSize.height}var f=Hi();o||(o=r);var g=o.wrapper;if(qi(f,-g.rotateAngle,i.x,i.y),Qp(f,t,e,i.x,i.y),qi(f,g.rotateAngle,i.x,i.y),r instanceof te){var d,v=Je(f,{x:(d=r).wrapper.offsetX,y:d.wrapper.offsetY}),y=d.wrapper.offsetX-d.wrapper.actualSize.width*d.pivot.x,S=d.wrapper.offsetY-d.wrapper.actualSize.height*d.pivot.y;if(h>0)if(d.processId){var b=this.diagram.nameTable[d.processId];(!b.maxWidth||d.margin.left+h0)if(d.processId){var M=this.diagram.nameTable[d.processId];(!M.maxHeight||d.margin.top+c0){if(e.dragLimit=e.dragLimit?e.dragLimit:{},e.dragLimit.top||e.dragLimit.bottom||e.dragLimit.left||e.dragLimit.right){var b={minDistance:null};S=this.getRelativeOffset(v,d,b);var M={minDistance:null};g=this.getRelativeOffset(v,y,M),S=null!=b&&M.minDistance0){if(S=y[y.length-1]){var b=void 0;for(b=0;b=e.x-t.dragLimit.left-r.width/2&&i.x<=e.x+t.dragLimit.right+r.width/2&&(s=!0),i.y>=e.y-t.dragLimit.top-r.height/2&&i.y<=e.y+t.dragLimit.bottom+r.height/2&&(o=!0),{x:s,y:o}},n.prototype.updateLabelMargin=function(t,e,i,r,s,o,a){if(i=i||{x:e.offset,y:0},e&&i&&i.x>0&&i.x<1){var l=z.getLengthFromListOfPoints(t.intermediatePoints),h=this.getPointAtLength(l*i.x,t.intermediatePoints,0),c=this.diagram.scrollSettings.currentZoom,d=e.dragLimit?e.dragLimit:{left:0,right:0,top:0,bottom:0};if(d.top||d.bottom||d.left||d.right){this.diagram.getWrapper(t.wrapper,e.id);var p=new Ne(0,0,0,0),f=this.diagram.getWrapper(t.wrapper,e.id);p.x=f.offsetX/c+o,p.y=f.offsetY/c+a,p.width=f.bounds.width/c,p.height=f.bounds.height/c;var g=new Ne(h.x-(d.left||0)-p.width/2,h.y-(d.top||0)-p.height/2,(d.left||0)+(d.right||0)+p.width,(d.top||0)+(d.bottom||0)+p.height);if(g.containsPoint(r));else for(var S=0,b=this.boundsInterSects([h,r],g,!1);S=t){c=t-r,d=z.findAngle(s,a),u=c*Math.cos(d*Math.PI/180),p=c*Math.sin(d*Math.PI/180),o={x:s.x+u,y:s.y+p};break}r+=h,s=a}else s=a;return o},n.prototype.getInterceptWithSegment=function(t,e){for(var o,a,i=[],r=[],s=[],l=z.findLength({x:0,y:0},{x:this.diagram.scroller.viewPortWidth,y:this.diagram.scroller.viewPortHeight}),h=1;h0&&a<=90||a>180&&a<=270?90:-90;r.push(z.transform(t,a+c,l)),r.push(z.transform(t,o+c,l));var p=tm({x1:s[0].x,y1:s[0].y,x2:s[1].x,y2:s[1].y},{x1:r[0].x,y1:r[0].y,x2:r[1].x,y2:r[1].y});p.enabled&&i.push(p.intersectPt)}return i},n.prototype.getAnnotationChanges=function(t,e){var r={};return r[sb(t,e.id,!0)]={width:e.width,height:e.height,offset:t instanceof te?{x:e.offset.x,y:e.offset.y}:e.offset,rotateAngle:e.rotateAngle,margin:{left:e.margin.left,right:e.margin.right,top:e.margin.top,bottom:e.margin.bottom},horizontalAlignment:e.horizontalAlignment,verticalAlignment:e.verticalAlignment,alignment:t instanceof de?e.alignment:void 0},{annotations:r}},n.prototype.getConnectorPortChanges=function(t,e){var i=function Wse(n,t,e){for(var i=n.ports,r=0;r1&&(v.width=g,v.offset.x=1/S),f>1&&(v.height=f,v.offset.y=1/b)}}e instanceof Nr&&(e.alignment="Center"),l=this.getAnnotationChanges(t,e),t instanceof te?this.diagram.nodePropertyChange(t,a,l):this.diagram.connectorPropertyChange(t,a,l),this.diagram.updateDiagramObject(t)},n.prototype.getSubProcess=function(t){var i,e={nodes:[],connectors:[]};return t instanceof te?i=t.processId:t&&t.nodes&&t.nodes.length&&t.nodes[0].processId&&(i=t.nodes[0].processId),i&&e.nodes.push($(this.diagram.nameTable[i])),e},n.prototype.checkBoundaryConstraints=function(t,e,i,r){var s=this.diagram.pageSettings,o=this.diagram.pageSettings.boundaryConstraints,a=this.diagram.scroller;if("Page"===o||"Diagram"===o){var l=i?void 0:this.diagram.selectedItems.wrapper.bounds;return!!((i?i.right:l.right)+(t||0)<=("Page"===o?s.width:a.viewPortWidth)&&(i?i.left:l.left)+(t||0)>=0&&(i?i.bottom:l.bottom)+(e||0)<=("Page"===o?s.height:a.viewPortHeight)&&(i?i.top:l.top)+(e||0)>=0||"None"!==this.diagram.layout.type&&r)}return!0},n.prototype.dragSelectedObjects=function(t,e){var i=this,r=this.diagram.selectedItems;this.state&&!this.state.backup&&(this.state.backup={},this.state.backup.offsetX=r.offsetX,this.state.backup.offsetY=r.offsetY),r=YI(this.diagram,r)||r;var s=this.diagram.selectedItems.nodes.filter(function(c){return"SwimLane"===c.shape.type});if(s.length>0&&!this.diagram.currentSymbol&&this.diagram.selectedItems.nodes.length>1){var o=this.diagram.selectedItems.nodes.filter(function(c){return""===c.parentId||"SwimLane"!==i.diagram.nameTable[c.parentId].shape.type});if(o.length>0){for(var a=0;a0||l.length>1)&&(o=o.concat(l),this.diagram.selectedItems.nodes.splice(0,this.diagram.selectedItems.nodes.length),o.forEach(function(c){i.diagram.selectedItems.nodes.push(c)}),r=this.diagram.selectedItems,this.diagram.selectedObject.helperObject=void 0)}}if(this.checkBoundaryConstraints(t,e)){this.diagram.diagramActions=this.diagram.diagramActions|ee.PreventZIndexOnDragging|ee.DragUsingMouse;var h=this.diagram.selectedObject.actualObject;return(h&&h instanceof te&&h.isLane&&Qx(h,this.diagram)||!h||!h.isLane)&&this.diagram.drag(r,t,e),this.diagram.diagramActions=this.diagram.diagramActions&~(ee.PreventZIndexOnDragging|ee.DragUsingMouse),this.diagram.refreshCanvasLayers(),this.checkHtmlObjectDrag(r),!0}return!1},n.prototype.checkHtmlObjectDrag=function(t){var e=!1;this.diagram.views&&this.diagram.views.length>1&&(t instanceof si?e=t.nodes.some(function(i){return i.shape&&"HTML"===i.shape.type}):t.shape&&"HTML"===t.shape.type&&(e=!0),e&&this.resetOverviewCanvas())},n.prototype.resetOverviewCanvas=function(){for(var t=0,e=this.diagram.views;t0&&(this.layoutAnimateModule.stopCurrentAnimation(this.objectStore[0],e,t),this.objectStore=[]),a=this.diagram.doLayout(),this.objectStore.push(a)),this.canUpdateTemplate=!1,this.diagram.blazorActions&=~on.expandNode,this.diagram.preventNodesUpdate=r,this.diagram.layoutAnimateModule&&this.diagram.organizationalChartModule&&!i)this.diagram.allowServerDataBinding=!1,this.layoutAnimateModule.expand(this.diagram.layout.enableAnimation,a,t,this.diagram);else{var l={element:$(t),state:!!t.isExpanded};this.triggerEvent(Ce.expandStateChange,l),this.diagram.lineRoutingModule&&this.diagram.constraints&rt.LineRouting&&"ComplexHierarchicalTree"!==this.diagram.layout.type&&this.diagram.resetSegments()}return this.diagram.layout.fixedNode=""===o?"":this.diagram.layout.fixedNode,a},n.prototype.getparentexpand=function(t,e,i,r){for(var s,o=0;o0&&(this.diagram.selectedItems.wrapper.rotateAngle=this.diagram.selectedItems.rotateAngle=s.rotateAngle),r instanceof te&&"SwimLane"!==r.shape.type&&!r.isLane&&!r.isPhase&&!r.isHeader)(r.offsetX!==r.wrapper.offsetX||r.offsetY!==r.wrapper.offsetY||r.width!==r.wrapper.width||r.height!==r.wrapper.height||r.rotateAngle!==r.wrapper.rotateAngle)&&(r.offsetX+=o,r.offsetY+=a,r.width+=l,r.height+=h,r.rotateAngle+=c,this.diagram.nodePropertyChange(r,{},{offsetX:r.offsetX,offsetY:r.offsetY,width:r.width,height:r.height,rotateAngle:r.rotateAngle})),e=this.diagram.spatialSearch.findObjects(r.wrapper.outerBounds);else if(r instanceof si)for(var d=0;d30||g.wrapper.outerBounds.topCenter.y-f.wrapper.outerBounds.bottomCenter.y>30)&&this.diagram.lineRoutingModule.refreshConnectorSegments(this.diagram,p,!0)}}this.updateSelector(),this.diagram.protectPropertyChange(!1)}},n.prototype.drawSelectionRectangle=function(t,e,i,r){this.diagram.drawSelectionRectangle(t,e,i,r)},n.prototype.startGroupAction=function(){this.diagram.startGroupAction()},n.prototype.endGroupAction=function(){this.diagram.endGroupAction()},n.prototype.removeChildFromBPmn=function(t,e,i){var r=this.diagram.nameTable[t.id]||t.nodes[0];if(i&&r&&r.processId&&r.processId===i.wrapper.id){var s=$(r);s.processId=r.processId,this.diagram.startGroupAction();var o=this.diagram.nameTable[r.processId].shape.activity.subProcess.processes||[];o.splice(o.indexOf(r.id),1),this.diagram.bpmnModule.removeChildFromBPMN(this.diagram.nameTable[r.processId].wrapper,r.id,this.diagram),this.diagram.nameTable[r.id].processId="",r.offsetX=r.wrapper.offsetX,r.offsetY=r.wrapper.offsetY;var a=$(r);this.addHistoryEntry({type:"PositionChanged",redoObject:{nodes:[a]},undoObject:{nodes:[s]},category:"Internal"}),this.diagram.endGroupAction()}},n.prototype.isDroppable=function(t,e){var i=this.diagram.nameTable[t.id]||t.nodes[0];return i instanceof te&&(!ce()&&"TextAnnotation"===i.shape.shape||("Group"===e.shape.shape&&(e.shape.activity.subProcess.collapsed=!1),!(i&&"Bpmn"===i.shape.type&&(i.processId===e.id||i.id===e.processId||"Bpmn"===e.shape.type&&!(e instanceof de)&&e.shape.activity&&e.shape.activity.subProcess&&e.shape.activity.subProcess.collapsed))))},n.prototype.renderHighlighter=function(t,e,i){if(new Ne,t.target instanceof te||t.target instanceof de||e&&(t.source instanceof te||t.source instanceof de)){var a=this.findTarget(e?t.sourceWrapper:t.targetWrapper,e?t.source:t.target,i,!0),l=void 0;if(a instanceof zd)for(var h=a.id,c=t.target,u=0,p=c.wrapper.children[0].children[0].children[2].children;u0){var r=0;t[0]=this.diagram.nameTable[t[0].id]||t[0];var s="Object"===i?yr(t[0].wrapper):this.diagram.selectedItems.wrapper.bounds,o={nodes:[],connectors:[]},a={nodes:[],connectors:[]};for(r="Object"===i?r+1:r;r0){var i=0,r=0,s=0,o=0,a=0,l=0,h=0,c=0,d={nodes:[],connectors:[]},u={nodes:[],connectors:[]};for(i=0;io.center.y&&(r=n[parseInt(e.toString(),10)],n[parseInt(e.toString(),10)]=n[parseInt(i.toString(),10)],n[parseInt(i.toString(),10)]=r):s.center.x>o.center.x&&(r=n[parseInt(e.toString(),10)],n[parseInt(e.toString(),10)]=n[parseInt(i.toString(),10)],n[parseInt(i.toString(),10)]=r)}}return n}(t,e),i=1;i0){var i=0,r={x:.5,y:.5};t[0]=this.diagram.nameTable[t[0].id]||t[0];var s=yr(t[0].wrapper),o={nodes:[],connectors:[]},a={nodes:[],connectors:[]};for(i=1;ii.zIndex){for(var s=this.diagram.layers.indexOf(this.diagram.getActiveLayer()),o=this.diagram.layers[parseInt(s.toString(),10)].zIndexTable,a=JSON.parse(JSON.stringify(o)),l=i.zIndex,h=r.zIndex,c=h;c>=l;c--)l!==c?o[c-1]?(o[parseInt(c.toString(),10)]=o[c-1],this.diagram.nameTable[o[parseInt(c.toString(),10)]].zIndex=c):(o[c-1]=o[parseInt(c.toString(),10)],this.diagram.nameTable[o[c-1]].zIndex=c,delete o[parseInt(c.toString(),10)]):this.swapZIndexObjects(h,o,r.id,a);"SVG"===this.diagram.mode?(this.moveSvgNode(e.parentId,i.id),this.updateNativeNodeIndex(e.parentId,i.id)):this.diagram.refreshCanvasLayers()}},n.prototype.findLeastIndexConnector=function(t,e,i){for(var r=0;rs.zIndex&&(i=s)}return i},n.prototype.findLeastIndexObject=function(t,e){var i=t;return t instanceof te&&(i=this.findLeastIndexConnector(t.inEdges,e,i),i=this.findLeastIndexConnector(t.outEdges,e,i)),i},n.prototype.checkSelection=function(t,e){var i;if(1===t.nodes.length&&0===t.connectors.length)if(cs(this.diagram,t.nodes[0],!0)){var r=t.nodes[0];if("SwimLane"===(i="SwimLane"===t.nodes[0].shape?t.nodes[0]:this.diagram.nameTable[t.nodes[0].parentId]).shape.type){var s="Horizontal"===i.shape.orientation;(r.isPhase&&(s&&"ResizeSouth"===e||!s&&"ResizeEast"===e)||r.isLane&&(s&&"ResizeEast"===e||!s&&"ResizeSouth"===e))&&W3(this.diagram,i,e)}else if("Grid"===i.container.type)if("Horizontal"===i.container.orientation&&1===r.rowIndex||"Vertical"===i.container.orientation&&r.rowIndex>0&&r.columnIndex>0){if("ResizeSouth"===e)for(var o=0;o1&&(this.diagram.realActions=this.diagram.realActions|$i.hScrollbarMoved,this.scrolled=!0),this.diagram.scrollSettings.horizontalOffset=t},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"verticalOffset",{get:function(){return this.vOffset},set:function(t){this.vOffset=t,Math.abs(this.vOffset-this.diagram.scrollSettings.verticalOffset)>1&&(this.diagram.realActions=this.diagram.realActions|$i.vScrollbarMoved,this.scrolled=!0),this.diagram.scrollSettings.verticalOffset=t},enumerable:!0,configurable:!0}),n.prototype.getBounds=function(){var e=this.diagram.spatialSearch.getPageBounds(0,0);return(e.x<0||e.y<0)&&!this.diagram.pageSettings.multiplePage?this.getPageBounds(void 0,void 0,!0,!0):this.getPageBounds(void 0,void 0,!0)},n.prototype.updateScrollOffsets=function(t,e){var i,r,s=this.getBounds();s.x*=this.currentZoom,s.y*=this.currentZoom,s.width*=this.currentZoom,s.height*=this.currentZoom,i=Math.max(0,t-s.left),r=Math.max(0,e-s.top),void 0!==t&&void 0!==e?(this.horizontalOffset=i,this.verticalOffset=r,this.diagram.setOffset(i,r)):this.diagram.setOffset(-this.horizontalOffset-s.x,-this.verticalOffset-s.y),this.transform={tx:Math.max(this.horizontalOffset,-s.left)/this.currentZoom,ty:Math.max(this.verticalOffset,-s.top)/this.currentZoom,scale:this.currentZoom}},n.prototype.setScrollOffset=function(t,e){this.scrolled=!1;var i=this.getBounds();i.x*=this.currentZoom,i.y*=this.currentZoom,i.width*=this.currentZoom,i.height*=this.currentZoom;var r=-i.left,s=-i.top,o=!1,a=this.viewPortWidth*this.currentZoom,l=this.viewPortHeight*this.currentZoom,h=r-t;if(h!==this.horizontalOffset){rh?this.horizontalOffset-=t:this.horizontalOffset=h,o=!0);var c=Math.max(i.right+this.vScrollSize,a);if(!o&&c<-h+this.viewPortWidth){var d=-h+a-this.vScrollSize,u=-this.horizontalOffset+a-this.vScrollSize;this.horizontalOffset=dd-u?h:-(i.right+this.vScrollSize-a),o=!0}o||(this.horizontalOffset=r-t)}o=!1;var p=s-e;if(p!==this.verticalOffset){sp?this.verticalOffset-=e:this.verticalOffset=p,o=!0);var f=Math.max(i.bottom+this.hScrollSize,l);if(!o&&f<-p+l){var g=-p+l-this.hScrollSize,v=-this.verticalOffset+l-this.hScrollSize;this.verticalOffset=gg-v?p:-(i.bottom+this.hScrollSize-l),o=!0}o||(this.verticalOffset=s-e)}this.transform={tx:Math.max(this.horizontalOffset,-i.left)/this.currentZoom,ty:Math.max(this.verticalOffset,-i.top)/this.currentZoom,scale:this.currentZoom},this.setSize()},n.prototype.getObjects=function(t,e){for(var i=[],r=0;r0){for(var l=0;l0){h.push(i[parseInt(o.toString(),10)].id);for(var d=0;d=e.bottom&&(l=0),-this.horizontalOffset<=e.x&&-this.horizontalOffset+this.viewPortWidth>=e.right&&(a=0),this.hScrollSize=a,this.vScrollSize=l;var h=this.diagramWidth,c=this.diagramHeight;this.diagramWidth=Math.max(e.right,-this.horizontalOffset+this.viewPortWidth-l)-i,this.diagramHeight=Math.max(e.bottom,-this.verticalOffset+this.viewPortHeight-a)-r,(h!==this.diagramWidth||c!==this.diagramHeight)&&"Diagram"!==this.diagram.scrollSettings.scrollLimit&&this.diagram.setSize(this.diagramWidth,this.diagramHeight),"Diagram"===this.diagram.scrollSettings.scrollLimit&&(h===this.diagramWidth&&c===this.diagramHeight&&1===this.currentZoom||this.diagram.diagramActions&&t&&(!this.diagram.diagramActions||!t||0===this.verticalOffset&&this.verticalOffset!==t.y||0===this.horizontalOffset&&this.horizontalOffset!==t.x)?t&&h===this.diagramWidth&&c===this.diagramHeight&&(this.diagram.diagramCanvas.scrollHeight>this.viewPortHeight&&t.y<0&&this.horizontalOffset===t.x&&0===this.verticalOffset||this.diagram.diagramCanvas.scrollWidth>this.viewPortWidth&&t.x<0&&this.verticalOffset===t.y&&0===this.horizontalOffset)&&(this.verticalOffset=t.y,this.horizontalOffset=t.x,this.transform={tx:Math.max(t.x,-e.left)/this.currentZoom,ty:Math.max(t.y,-e.top)/this.currentZoom,scale:this.currentZoom}):(this.diagram.scrollActions&ca.Interaction&&t&&(this.transform={tx:Math.max(t.x,-e.left/this.currentZoom)/this.currentZoom,ty:Math.max(t.y,-e.top/this.currentZoom)/this.currentZoom,scale:this.currentZoom},this.horizontalOffset=t.x,this.verticalOffset=t.y),this.diagram.setSize(this.diagramWidth,this.diagramHeight),!(this.diagram.scrollActions&ca.PropertyChange)&&t&&(this.horizontalOffset=t.x,this.verticalOffset=t.y,this.transform={tx:Math.max(t.x,-e.left)/this.currentZoom,ty:Math.max(t.y,-e.top)/this.currentZoom,scale:this.currentZoom}))),this.diagram.transformLayers(),this.diagram.element.style.overflow="hidden"},n.prototype.setViewPortSize=function(t,e){this.viewPortWidth=t,this.viewPortHeight=e},n.prototype.getPageBounds=function(t,e,i,r){var o,s=new Ne;if("Content"===e||r||null===this.diagram.pageSettings.width||null===this.diagram.pageSettings.height){var u=t?void 0:0;o=this.diagram.spatialSearch.getPageBounds(u,u)}else{var a=this.diagram.pageSettings.width,l=this.diagram.pageSettings.height,h=0,c=0;if(this.diagram.pageSettings.multiplePage){if((s=this.diagram.spatialSearch.getPageBounds(0,0)).right>a&&(a*=d=Math.ceil(s.right/a)),s.bottom>l&&(l*=d=Math.ceil(s.bottom/l)),s.left<0&&Math.abs(s.left)>h){var d=Math.ceil(Math.abs(s.left)/this.diagram.pageSettings.width);h=this.diagram.pageSettings.width*d}s.top<0&&Math.abs(s.top)>c&&(d=Math.ceil(Math.abs(s.top)/this.diagram.pageSettings.height),c=this.diagram.pageSettings.height*d)}o=new Ne(-h,-c,a+h,l+c)}if(i){var p=this.diagram.scrollSettings.padding;o.x-=p.left,o.y-=p.top,o.width+=p.left+p.right,o.height+=p.top+p.bottom}return o},n.prototype.getPageBreak=function(t){for(var e=0,i=0,r=-1,s=[],c=this.diagram.pageSettings.margin.left,d=this.diagram.pageSettings.margin.right,u=this.diagram.pageSettings.margin.top,p=this.diagram.pageSettings.margin.bottom,f=1,g=1;t.width>e;)(e+=this.diagram.pageSettings.width?this.diagram.pageSettings.width:t.width)===this.diagram.pageSettings.width&&(s[++r]={x1:t.left+c,y1:t.top+u,x2:t.left+c,y2:t.bottom-p}),ei;)(i+=this.diagram.pageSettings.height?this.diagram.pageSettings.height:t.height)===this.diagram.pageSettings.height&&(s[++r]={x1:t.left+c,y1:t.top+u,x2:t.right-d,y2:t.top+u}),i=this.diagram.scrollSettings.minZoom||l||t>=1)){this.currentZoom*=t;var c=this.getPageBounds(void 0,void 0,!0);c.x*=this.currentZoom,c.y*=this.currentZoom;var d=Hi();Qp(d,t,t,r.x,r.y),r3(d,e||0,i||0),bx(h,d);var u=Je(h,{x:0,y:0});if(1===t&&(u=this.applyScrollLimit(u.x,u.y,s,o,a)),a=-c.y>=u.y&&-c.x>=u.x&&a,(this.diagram.scrollActions&ca.PropertyChange||!(this.diagram.scrollActions&ca.Interaction)||"Diagram"!==this.diagram.scrollSettings.scrollLimit||a)&&(this.transform={tx:Math.max(u.x,-c.left)/this.currentZoom,ty:Math.max(u.y,-c.top)/this.currentZoom,scale:this.currentZoom},this.horizontalOffset=u.x,this.verticalOffset=u.y),this.setSize(u),"SVG"!==this.diagram.mode&&Ds(this.diagram)&&this.diagram.scroller.virtualizeElements(),"SVG"!==this.diagram.mode&&!Ds(this.diagram)&&this.diagram.refreshDiagramLayer(),this.diagram.setOffset(-this.horizontalOffset-c.x,-this.verticalOffset-c.y),JI(this.diagram),this.diagram.views&&this.diagram.views.overview){var p=this.diagram.views.overview,f=p.scrollOverviewRect(p.parent.scroller.horizontalOffset,p.parent.scroller.verticalOffset,p.parent.scroller.currentZoom,!0);p.updateOverviewrect(-f.x,-f.y,f.width,f.height),p.updateView(p)}}}},n.prototype.fitToPage=function(t){var e=(t=t||{}).mode,i=t.region,r=t.margin||{},s=t.canZoomIn,o=t.customBounds,a=t.canZoomOut;r.bottom=r.bottom||25,r.top=r.top||25,r.left=r.left||25,r.right=r.right||25;var h,l=o,c=-this.horizontalOffset,d=-this.verticalOffset;if("PageSettings"===(i=i||"PageSettings")&&this.diagram.pageSettings.width&&this.diagram.pageSettings.height||this.diagram.nodes.length>0||this.diagram.connectors.length>0){e=e||"Page","CustomBounds"!==i&&(l=this.getPageBounds(!0,i,!0));var u={x:0,y:0};r.left+r.right>this.viewPortWidth&&(this.viewPortWidth<=100?(r.left=5,r.right=5):(r.left=25,r.right=25)),r.top+r.bottom>this.viewPortHeight&&(this.viewPortHeight<=100?(r.top=5,r.bottom=5):(r.top=25,r.bottom=25)),u.x=(this.viewPortWidth-(r.left+r.right))/l.width,u.y=(this.viewPortHeight-(r.top+r.bottom))/l.height,!s&&l.width-this.horizontalOffset-a+this.viewPortWidth&&(i=o.right-this.viewPortWidth,i+=20),o.x<-a&&(i=o.x),o.bottom>-l+this.viewPortHeight&&(r=o.bottom-this.viewPortHeight,r+=20),o.y<-l&&(r=o.y),this.zoom(1,-this.horizontalOffset-i,-this.verticalOffset-r,null,void 0,e))},n.prototype.bringToCenter=function(t){var e=this.currentZoom,i=new Ne(t.x*e,t.y*e,t.width*e,t.height*e),r=i.x+i.width/2-this.viewPortWidth/2,s=i.y+i.height/2-this.viewPortHeight/2;this.zoom(1,-this.horizontalOffset-(r*=-1),-this.verticalOffset-(s*=-1),null)},n.prototype.applyScrollLimit=function(t,e,i,r,s){if("Infinity"===this.diagram.scrollSettings.scrollLimit&&void 0===i&&!r&&(t=-t,e=-e),"Infinity"!==this.diagram.scrollSettings.scrollLimit){var o=void 0;if("Limited"===this.diagram.scrollSettings.scrollLimit){var a=this.diagram.scrollSettings.scrollableArea;o=new Ne(a.x,a.y,a.width,a.height)}(o=o||(s?this.getPageBounds():this.getPageBounds(!0))).x*=this.currentZoom,o.y*=this.currentZoom,o.width*=this.currentZoom,o.height*=this.currentZoom,void 0!==i&&(t*=-1,e*=-1),r&&(t*=-1,e*=-1);var l=Math.max(o.right,this.viewPortWidth);if(!r&&!(t<=o.x&&(t+this.viewPortWidth>=o.right||t>=o.right-this.viewPortWidth)||t>=o.x&&t+this.viewPortWidth<=l))if(t>=o.x)t=Math.max(o.x,Math.min(t,t-(t+this.viewPortWidth-this.vScrollSize-l)));else{var h=o.right-this.viewPortWidth;t=Math.min(h,o.x)}var c=Math.max(o.bottom,this.viewPortHeight);r||e<=o.y&&e+this.viewPortHeight>=o.bottom||e>=o.y&&e+this.viewPortHeight<=c||(e>=o.y?e=Math.max(o.y,Math.min(e,e-(e+this.viewPortHeight-this.hScrollSize-c))):(h=o.bottom-this.viewPortHeight,e=Math.min(o.y,h))),t*=-1,e*=-1}return{x:t,y:e}},n}(),tae=function(){function n(t,e,i,r,s){this.objects=[],this.left=t,this.top=e,this.width=i,this.height=r,this.spatialSearch=s}return n.prototype.findQuads=function(t,e){null!=this.first&&this.first.isIntersect(t)&&this.first.findQuads(t,e),null!=this.second&&this.second.isIntersect(t)&&this.second.findQuads(t,e),null!=this.third&&this.third.isIntersect(t)&&this.third.findQuads(t,e),null!=this.fourth&&this.fourth.isIntersect(t)&&this.fourth.findQuads(t,e),this.objects.length>0&&e.push(this)},n.prototype.isIntersect=function(t){return!(this.left+this.widtht.right||this.top>t.bottom)},n.prototype.selectQuad=function(){for(var i,t=null,e=this;null!=e;)i=e.getQuad(t),e=i.source,t=i.target||t;return t},n.prototype.getQuad=function(t){var e=this.width/2,i=this.height/2;if(e>=1e3&&i>=1e3){var r=this.left+e,s=this.top+i;if(this.spatialSearch.childRight<=r){if(this.spatialSearch.childBottom<=s)return this.first||((o=new n(this.left,this.top,e,i,this.spatialSearch)).parent=this,this.first=o),{source:this.first};if(this.spatialSearch.childTop>=s)return this.third||((o=new n(this.left,s,e,i,this.spatialSearch)).parent=this,this.third=o),{source:this.third}}else if(this.spatialSearch.childLeft>=r){if(this.spatialSearch.childBottom<=s)return this.second||((o=new n(r,this.top,e,i,this.spatialSearch)).parent=this,this.second=o),{source:this.second};var o;if(this.spatialSearch.childTop>=s)return this.fourth||((o=new n(r,s,e,i,this.spatialSearch)).parent=this,this.fourth=o),{source:this.fourth}}}return this.objects.push(this.spatialSearch.childNode),{target:this}},n.prototype.isContained=function(){return this.spatialSearch.childLeft>=this.left&&this.spatialSearch.childRight<=this.left+this.width&&this.spatialSearch.childTop>=this.top&&this.spatialSearch.childBottom<=this.top+this.height},n.prototype.addIntoAQuad=function(t){var e={};this.spatialSearch.setCurrentNode(t);for(var i=null;!e.isAdded;)i=(e=this.spatialSearch.parentQuad.add(i)).quad;return i},n.prototype.add=function(t){if(t=null,this.isContained())return{isAdded:!0,quad:t=this.selectQuad()};var e=void 0,i=!(0!==this.objects.length||this.first||this.second||this.third||this.fourth),r=2*this.width,s=2*this.height;return this.spatialSearch.childLeft=this.childLeft?(this.pageLeft=this.childLeft,this.leftElement=t,r=!0):t===this.leftElement&&(this.pageLeft=Number.MAX_VALUE,this.findLeft(this.parentQuad),r=!0)),(this.pageTop!==this.childTop||t!==this.topElement)&&(this.pageTop>=this.childTop?(this.pageTop=this.childTop,this.topElement=t,r=!0):t===this.topElement&&(this.pageTop=Number.MAX_VALUE,this.findTop(this.parentQuad),r=!0)),(this.pageBottom!==this.childBottom||t!==this.bottomElement)&&(this.pageBottom<=this.childBottom?(r=!0,this.pageBottom=this.childBottom,this.bottomElement=t):t===this.bottomElement&&(this.pageBottom=-Number.MAX_VALUE,this.findBottom(this.parentQuad),r=!0)),(this.pageRight!==this.childRight||t!==this.rightElement)&&(this.pageRight<=this.childRight?(this.pageRight=this.childRight,this.rightElement=t,r=!0):t===this.rightElement&&(this.pageRight=-Number.MAX_VALUE,this.findRight(this.parentQuad),r=!0)),r}return this.setCurrentNode(null),!1},n.prototype.isWithinPageBounds=function(t){return t.left>=this.pageLeft&&t.right<=this.pageRight&&t.top>=this.pageTop&&t.bottom<=this.pageBottom},n.prototype.findQuads=function(t){var e=[];return this.parentQuad.findQuads(t,e),e},n.prototype.findObjects=function(t){for(var i=[],r=0,s=this.findQuads(t);r=r.outerBounds.left&&(this.pageLeft=r.outerBounds.left,this.leftElement=r)}},n.prototype.findTop=function(t){t.first||t.second?(t.first&&this.findTop(t.first),t.second&&this.findTop(t.second)):(t.third&&this.findTop(t.third),t.fourth&&this.findTop(t.fourth));for(var e=0,i=t.objects;e=r.outerBounds.top&&(this.pageTop=r.outerBounds.top,this.topElement=r)}},n.prototype.setCurrentNode=function(t){if(this.childNode=t,t){var e=t.outerBounds;this.childLeft=Number(e.left),this.childTop=Number(e.top),this.childRight=Number(e.right),this.childBottom=Number(e.bottom)}else this.childLeft=Number.MAX_VALUE,this.childTop=Number.MAX_VALUE,this.childRight=-Number.MAX_VALUE,this.childBottom=-Number.MAX_VALUE},n.prototype.getPageBounds=function(t,e){if(this.pageLeft===Number.MAX_VALUE)return new Ne(0,0,0,0);var i=void 0!==t?Math.min(this.pageLeft,0):this.pageLeft,r=void 0!==e?Math.min(this.pageTop,0):this.pageTop;return new Ne(Math.round(i),Math.round(r),Math.round(this.pageRight-i),Math.round(this.pageBottom-r))},n.prototype.getQuad=function(t){return this.quadTable[t.id]},n}(),iae=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),nae=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return iae(t,n),function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);r>3&&s&&Object.defineProperty(t,e,s)}([I(!1)],t.prototype,"preventDefaults",void 0),t}(Ee),sae=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),o_=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},oae=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return sae(t,n),o_([I("")],t.prototype,"action",void 0),o_([I("")],t.prototype,"cursor",void 0),t}(Ee),a_=function(){function n(){this.size=20,this.intermediatePoints=[],this.gridCollection=[],this.startArray=[],this.targetGridCollection=[],this.sourceGridCollection=[],this.considerWalkable=[]}return n.prototype.lineRouting=function(t){var e=t.connectors.length;if(this.renderVirtualRegion(t),e>0)for(var i=0;i=t.right||e.right<=t.left||e.top>=t.bottom||e.bottom<=t.top)},n.prototype.findEndPoint=function(t,e,i){var r,s;if(e&&""!==t.sourcePortID&&t.sourcePortWrapper||!e&&""!==t.targetPortID&&t.targetPortWrapper){s=zo(r=e?{x:t.sourcePortWrapper.offsetX,y:t.sourcePortWrapper.offsetY}:{x:t.targetPortWrapper.offsetX,y:t.targetPortWrapper.offsetY},void 0,e?t.sourceWrapper.bounds:t.targetWrapper.bounds);var o=e?t.sourcePortWrapper.bounds:t.targetPortWrapper.bounds;r=i?"Top"===s?{x:o.topCenter.x,y:o.topCenter.y}:"Left"===s?{x:o.middleLeft.x,y:o.middleLeft.y}:"Right"===s?{x:o.middleRight.x,y:o.middleRight.y}:{x:o.bottomCenter.x,y:o.bottomCenter.y}:{x:o.center.x,y:o.center.y}}else r=e&&this.startNode||!e&&this.targetNode?e?{x:this.startNode.wrapper.offsetX,y:this.startNode.wrapper.offsetY}:{x:this.targetNode.wrapper.offsetX,y:this.targetNode.wrapper.offsetY}:e?{x:t.sourcePoint.x,y:t.sourcePoint.y}:{x:t.targetPoint.x,y:t.targetPoint.y};return r},n.prototype.refreshConnectorSegments=function(t,e,i,r){var h,c,p,f,g,y,S,b,M,w,C,s=e.sourceID,o=e.targetID,a=e.sourcePortID,l=e.targetPortID;if(function Jre(n,t){var e=0;return n.constraints&qe.LineRouting?e=n.constraints&qe.LineRouting:n.constraints&qe.InheritLineRouting&&(e=t.constraints&rt.LineRouting),e}(e,t)||r){this.startNode=t.nameTable[""+s],this.targetNode=t.nameTable[""+o],this.intermediatePoints=[],this.startArray=[],this.targetGridCollection=[],this.sourceGridCollection=[],this.startGrid=void 0,this.targetGrid=void 0;for(var D=0;D0;){var L=this.startArray.pop();if(L){for(D=0;D1&&(e.segments=[]),this.updateConnectorSegments(t,this.intermediatePoints,this.gridCollection,e,i)){this.considerWalkable=[];break e}this.targetGridCollection.splice(this.targetGridCollection.indexOf(O),1),L=this.startArray.pop()}}L&&this.findPath(L)}}}},n.prototype.checkChildNodes=function(t,e){var i=!1,r=!1;if(t.nodeId.length>=1&&!e)for(var s=0;s1&&this.targetGridCollection[0].nodeId.length>1)for(var c=0;c<=1;c++){for(var d=this.targetGridCollection[parseInt(c.toString(),10)].gridX,u=this.targetGridCollection[parseInt(c.toString(),10)].gridY,p=this.targetGridCollection[parseInt(c.toString(),10)].nodeId,f=void 0,g=0;g=e.right&&t.top<=e.top&&t.bottom>=e.bottom},n.prototype.getEndvalue=function(t,e){return this.gridCollection[t.gridX][t.gridY].walkable?t:"left"===e?this.getEndvalue(this.gridCollection[t.gridX-1][t.gridY],e):"right"===e?this.getEndvalue(this.gridCollection[t.gridX+1][t.gridY],e):"top"===e?this.getEndvalue(this.gridCollection[t.gridX][t.gridY-1],e):"bottom"===e?this.getEndvalue(this.gridCollection[t.gridX][t.gridY+1],e):t},n.prototype.changeValue=function(t,e,i){t.walkable||this.considerWalkable.push(t);for(var r,s=0;s<=e;s++)"left"===i?r=this.gridCollection[t.gridX-s][t.gridY]:"right"===i?r=this.gridCollection[t.gridX+s][t.gridY]:"top"===i?r=this.gridCollection[t.gridX][t.gridY-s]:"bottom"===i&&(r=this.gridCollection[t.gridX][t.gridY+s]),r.walkable||this.considerWalkable.push(r)},n.prototype.getIntermediatePoints=function(t){var e;for(this.intermediatePoints=[];t;)this.intermediatePoints.push({x:t.gridX,y:t.gridY}),t=t.parent;this.intermediatePoints.reverse(),this.intermediatePoints.length>=1&&void 0!==this.intermediatePoints[0]&&void 0!==this.intermediatePoints[1]&&(this.intermediatePoints[0].x===this.intermediatePoints[1].x?this.intermediatePoints[0].y=1&&u.length>1&&(g=u[u.length-2].x!==u[u.length-1].x?u[u.length-2].x>u[u.length-1].x?"Left":"Right":u[u.length-2].y>u[u.length-1].y?"Top":"Bottom"),M>=2&&v===g&&u.length>1&&u.splice(u.length-2,1),v=g);if(u&&u.length>1){for(var w=0;wD.x?S.bounds.middleLeft:S.bounds.middleRight),w===u.length-2&&""===r.targetPortID&&y&&(l=C.x>D.x?y.bounds.middleRight:y.bounds.middleLeft),0===w&&b&&(C.x=b.x,C.y=D.y=b.y),w===u.length-2&&l&&(w>0&&r.targetDecorator&&l.x-D.x<0&&Math.abs(l.x-C.x)0&&r.targetDecorator&&l.x-D.x>0&&Math.abs(l.x-C.x)D.y?S.bounds.topCenter:S.bounds.bottomCenter),w===u.length-2&&""===r.targetPortID&&y&&(l=C.y>D.y?y.bounds.bottomCenter:y.bounds.topCenter),0===w&&b&&(C.y=b.y,C.x=D.x=b.x),w===u.length-2&&l&&(w>0&&r.targetDecorator&&l.y-D.y<0&&Math.abs(l.y-C.y)0&&r.targetDecorator&&l.y-D.y>0&&Math.abs(l.y-C.y)D.x?(p="Left",f=C.x-D.x):(p="Right",f=D.x-C.x):C.y>D.y?(p="Top",f=C.y-D.y):(p="Bottom",f=D.y-C.y),o.push({type:"Orthogonal",length:f,direction:p})}}if(o&&o.length>0){var A=o[o.length-1];if(1===o.length&&(A.length-=20),A.length<10&&2===o.length&&(o.pop(),o.length>0&&(o[0].length-=20,A=o[0])),r.targetDecorator&&("Top"===A.direction||"Bottom"===A.direction)&&A.length>r.targetDecorator.height+1||("Right"===A.direction||"Left"===A.direction)&&A.length>r.targetDecorator.width+1)return r.segments=o,s&&t.connectorPropertyChange(r,{},{type:"Orthogonal",segments:o}),!0}return!1},n.prototype.findPath=function(t){for(var e,i=[],r=this.findNearestNeigbours(t,this.gridCollection,!0),s=0;sl)&&(e.x!==t.gridX||e.y!==t.gridY)&&(i.push(e),o.previousDistance=l,o.afterDistance=o.afterDistance||this.manhattan(Math.abs(e.x-this.targetGrid.gridX),Math.abs(e.y-this.targetGrid.gridY)),o.totalDistance=o.previousDistance+o.afterDistance,o.parent=t)}if(i.length>0)for(s=0;st?i*t+e:i*e+t},n.prototype.manhattan=function(t,e){return t+e},n.prototype.findNearestNeigbours=function(t,e,i){var r=[],s=t.parent;if(s){var o=(t.gridX-s.gridX)/Math.max(Math.abs(t.gridX-s.gridX),1),a=(t.gridY-s.gridY)/Math.max(Math.abs(t.gridY-s.gridY),1);0!==o?(this.isWalkable(t.gridX,t.gridY-1,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX][t.gridY-1])&&r.push(e[t.gridX][t.gridY-1]),this.isWalkable(t.gridX,t.gridY+1,!0)&&this.sourceGridCollection.indexOf(e[t.gridX][t.gridY+1])&&r.push(e[t.gridX][t.gridY+1]),this.isWalkable(t.gridX+o,t.gridY,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX+o][t.gridY])&&r.push(e[t.gridX+o][t.gridY])):0!==a&&(this.isWalkable(t.gridX-1,t.gridY,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX-1][t.gridY])&&r.push(e[t.gridX-1][t.gridY]),this.isWalkable(t.gridX+1,t.gridY,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX+1][t.gridY])&&r.push(e[t.gridX+1][t.gridY]),this.isWalkable(t.gridX,t.gridY+a,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX][t.gridY+a])&&r.push(e[t.gridX][t.gridY+a]))}else this.neigbour(t,"top",r,i),this.neigbour(t,"right",r,i),this.neigbour(t,"bottom",r,i),this.neigbour(t,"left",r,i);return r},n.prototype.neigbour=function(t,e,i,r){for(var o,s=1;s>0;){var a="top"===e||"bottom"===e?t.gridX:"left"===e?t.gridX-s:t.gridX+s,l="right"===e||"left"===e?t.gridY:"top"===e?t.gridY-s:t.gridY+s;if((o=this.gridCollection[parseInt(a.toString(),10)][parseInt(l.toString(),10)])&&(r&&-1===this.sourceGridCollection.indexOf(o)||!r&&-1===this.targetGridCollection.indexOf(o)))return i&&this.isWalkable(a,l)&&i.push(o),s;if(!(a>0&&l>0))break;s++}return null},n.prototype.resetGridColl=function(t,e,i){for(var s,r=1;r>0;){var o="top"===e||"bottom"===e?t.gridX:"left"===e?t.gridX-r:t.gridX+r,a="right"===e||"left"===e?t.gridY:"top"===e?t.gridY-r:t.gridY+r;if((s=this.gridCollection[parseInt(o.toString(),10)][parseInt(a.toString(),10)])&&(i&&-1===this.sourceGridCollection.indexOf(s)||!i&&-1===this.targetGridCollection.indexOf(s))){if(this.isWalkable(o,a))break;var l=this.gridCollection[parseInt(o.toString(),10)][parseInt(a.toString(),10)];this.considerWalkable.push(l)}if(!(o>0&&a>0))break;"top"===e||"left"===e?r--:r++}return null},n.prototype.isWalkable=function(t,e,i){if(t>=0&&t=0&&e0?1:-1,this.isWalkable(h,c-1)&&!this.isWalkable(h-a,c-1)||this.isWalkable(h,c+1)&&!this.isWalkable(h-a,c+1)))return{x:t,y:e};if(0!==l){if(l=l>0?1:-1,this.isWalkable(h-1,c)&&!this.isWalkable(h-1,c-l)||this.isWalkable(h+1,c)&&!this.isWalkable(h+1,c-l))return{x:t,y:e};if(this.findIntermediatePoints(h+1,c,h,c,s,o)||this.findIntermediatePoints(h-1,c,h,c,s,o))return{x:t,y:e}}return this.findIntermediatePoints(h+a,c+l,h,c,s,o)},n.prototype.destroy=function(){},n.prototype.getModuleName=function(){return"LineRouting"},n}(),aae=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),hae=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return aae(t,n),function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);r>3&&s&&Object.defineProperty(t,e,s)}([I(!0)],t.prototype,"inversedAlignment",void 0),t}(Ee),cae=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Oe=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},xT=function(n,t,e,i){return new(e||(e=Promise))(function(r,s){function o(h){try{l(i.next(h))}catch(c){s(c)}}function a(h){try{l(i.throw(h))}catch(c){s(c)}}function l(h){h.done?r(h.value):new e(function(c){c(h.value)}).then(o,a)}l((i=i.apply(n,t||[])).next())})},TT=function(n,t){var i,r,s,o,e={label:0,sent:function(){if(1&s[0])throw s[1];return s[1]},trys:[],ops:[]};return o={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function a(h){return function(c){return function l(h){if(i)throw new TypeError("Generator is already executing.");for(;e;)try{if(i=1,r&&(s=2&h[0]?r.return:h[0]?r.throw||((s=r.return)&&s.call(r),0):r.next)&&!(s=s.call(r,h[1])).done)return s;switch(r=0,s&&(h=[2&h[0],s.value]),h[0]){case 0:case 1:s=h;break;case 4:return e.label++,{value:h[1],done:!1};case 5:e.label++,r=h[1],h=[0];continue;case 7:h=e.ops.pop(),e.trys.pop();continue;default:if(!(s=(s=e.trys).length>0&&s[s.length-1])&&(6===h[0]||2===h[0])){e=0;continue}if(3===h[0]&&(!s||h[1]>s[0]&&h[1]0&&((!s.style||!s.style.fill)&&(o.style.fill="transparent"),(!s.style||!s.style.strokeColor)&&(o.style.strokeColor="transparent")),s.shape&&"UmlActivity"===s.shape.type&&tb(s,o),s.shape&&"SwimLane"===s.shape.type&&pF(s,o),r.nodeDefaults&&Ro(o,s,r.nodeDefaults),r.updateAnnotationText(o.annotations);if(e&&e.connectors)for(a=0;e&&e.connectors&&a0&&0===i.nodes.length)this.clearCollection(),a=!0;else{for(var g=0,v=Object.keys(e.nodes);g0&&0===i.connectors.length)this.clearCollection(!0),a=!0;else{for(var C=0,D=Object.keys(e.connectors);C0){this.renderSelector(!0);break}if(e.selectedItems.constraints){this.renderSelector(!0);break}break;case"snapSettings":this.updateSnapSettings(e);break;case"commandManager":this.initCommands();break;case"layout":o=!0;break;case"segmentThumbShape":this.updateSelector();break;case"dataSourceSettings":this.clear(),"None"===this.layout.type?a=!0:(this.initObjects(),o=!0);break;case"tooltip":l3(this);break;case"rulerSettings":this.updateRulerSettings(e);break;case"layers":this.updateLayer(e);break;case"scrollSettings":this.scrollActions|=ca.PropertyChange,this.updateScrollSettings(e),this.scrollActions&=~ca.PropertyChange,this.scrollSettings.horizontalOffset=-this.scroller.horizontalOffset||0,this.scrollSettings.verticalOffset=-this.scroller.verticalOffset||0;break;case"locale":e.locale!==i.locale&&(this.realActions|=$i.PreventDataInit,n.prototype.refresh.call(this),this.realActions&=~$i.PreventDataInit);break;case"contextMenuSettings":if(void 0!==e.contextMenuSettings.showCustomMenuOnly&&(this.contextMenuSettings.showCustomMenuOnly=e.contextMenuSettings.showCustomMenuOnly),void 0!==e.contextMenuSettings.show&&(this.contextMenuSettings.show=e.contextMenuSettings.show),e.contextMenuSettings.items){for(var A=e.contextMenuSettings.items,x=0,R=Object.keys(A);x0){for(var N=[],T=O.ports.length-1;T>=0;T--)"LineDistribution"===O.ports[parseInt(T.toString(),10)].id.split("_")[1]&&N.push(O.ports[parseInt(T.toString(),10)]);this.removePorts(O,N)}}for(T=0;T0)for(var ue=0,pe=Object.keys(e.nodes);ue0)for(var De=0,xe=Object.keys(e.connectors);De=0;o--)this.commandHandler.expandNode(r[parseInt(o.toString(),10)],this,0!==o);this.canLayout&&this.doLayout(),this.lineRoutingModule?this.connectors.sourceID!==this.connectors.targetID&&this.lineRoutingModule.lineRouting(this):this.constraints&rt.LineRouting&&console.warn('[WARNING] :: Module "LineRouting" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),this.validatePageSize(),this.renderPageBreaks(),this.diagramRenderer.renderSvgGridlines(this.snapSettings,Bd(this.element.id),this.scroller.transform,this.rulerSettings,this.hRuler,this.vRuler),this.commandHandler.initSelectorWrapper(),this.notify("initial-load",{}),this.trigger("load"),this.scroller.setSize(),this.scroller.updateScrollOffsets(),this.isRefreshed||this.refreshDiagramLayer(),(this.scrollSettings.verticalOffset>0||this.scrollSettings.horizontalOffset>0)&&this.updateScrollOffset(),X.isDevice&&(this.tool=Ci.ZoomPan|Ci.SingleSelect),this.notify("initial-end",{}),this.isProtectedOnChange=!1,this.tooltipObject=l3(this),this.diagramActions=ee.Render,this.initCommands();var a=document.getElementsByClassName(this.element.id+"_hiddenUserHandleTemplate");(function Noe(n,t,e,i){var r,s,o,a,l,d=document.getElementById(i).ej2_instances[0];if(n&&t){r=GF(n);for(var u=0,p=e.userHandles;u0;)e[0].parentNode.removeChild(e[0]);var i=document.getElementById(this.element.id+"content");i&&this.element.removeChild(i);var r="measureElement";if(window[""+r]){window[""+r].usageCount-=1;var s="measureElementCount";window[""+s]--,0===window[""+s]&&(window[""+r].parentNode.removeChild(window[""+r]),window[""+r]=null)}}window.domTable={};for(var a=0;a1&&(this.callBlazorModel=!1,this.insertBlazorDiagramObjects(this.selectedItems),this.commandHandler.group(),this.callBlazorModel=!0,this.commandHandler.getBlazorOldValues())},t.prototype.unGroup=function(){this.callBlazorModel=!1,this.insertBlazorDiagramObjects(this.selectedItems),this.commandHandler.unGroup(),this.callBlazorModel=!0,this.commandHandler.getBlazorOldValues()},t.prototype.sendToBack=function(){this.commandHandler.sendToBack()},t.prototype.setActiveLayer=function(e){var i=this.commandHandler.getLayer(e);this.activeLayer=i},t.prototype.addLayer=function(e,i){this.commandHandler.addLayer(e,i)},t.prototype.removeLayer=function(e){this.commandHandler.removeLayer(e,ce())},t.prototype.moveObjects=function(e,i){$(this.layers),this.enableServerDataBinding(!1),this.commandHandler.moveObjects(e,i)},t.prototype.layerObjectUpdate=function(){},t.prototype.sendLayerBackward=function(e){this.layerObjectUpdate(),this.commandHandler.sendLayerBackward(e)},t.prototype.bringLayerForward=function(e){this.layerObjectUpdate(),this.commandHandler.bringLayerForward(e)},t.prototype.cloneLayer=function(e){this.commandHandler.cloneLayer(e)},t.prototype.bringToFront=function(){this.commandHandler.bringToFront()},t.prototype.moveForward=function(){this.commandHandler.sendForward()},t.prototype.sendBackward=function(){this.commandHandler.sendBackward()},t.prototype.getObject=function(e){return this.nameTable[""+e]},t.prototype.getNodeObject=function(e){return $(this.nameTable[""+e])},t.prototype.getConnectorObject=function(e){return $(this.nameTable[""+e])},t.prototype.getActiveLayer=function(){return this.activeLayer},t.prototype.nudgeCommand=function(e,i,r){if("object"!=typeof e&&(this.selectedItems.nodes.length||this.selectedItems.connectors.length)>0){var s=void 0;i.type&&"KEYDOWN"===i.type&&(s=i.type),this.nudge(e,void 0,void 0,s)}},t.prototype.nudge=function(e,i,r,s){var o=0,a=0;"Left"===e||"Right"===e?o=("Left"===e?-1:1)*(i||1):a=("Up"===e?-1:1)*(r||1),"KEYDOWN"===s&&(o*=5,a*=5);var h=this.selectedItems,c=this.selectedItems.wrapper.children[0];if(c instanceof ni)this.commandHandler.labelDrag(h.nodes[0],c,o,a);else{var d=$(this.selectedItems);this.protectPropertyChange(!0),this.drag(h,o,a),this.protectPropertyChange(!1);var u={type:"PositionChanged",redoObject:$(this.selectedItems),undoObject:d,category:"Internal"};this.addHistoryEntry(u)}this.refreshCanvasLayers()},t.prototype.insertBlazorDiagramObjects=function(e){},t.prototype.drag=function(e,i,r){if(this.insertBlazorDiagramObjects(e),!(this.bpmnModule&&e instanceof te&&this.bpmnModule.updateAnnotationDrag(e,this,i,r))){if(e instanceof si){if(this.preventConnectorsUpdate=!0,e.nodes&&e.nodes.length){for(var o=0,a=e.nodes;o0&&o.nodes[0].children){this.fromUndo||(this.rotateUsingButton=!0);for(var h=this.commandHandler.getAllDescendants(o.nodes[0],[]),c=0;c0&&o.nodes[0].children){var g={type:"RotationChanged",redoObject:$(e),undoObject:$(o),category:"Internal",childTable:a};this.commandHandler.addHistoryEntry(g),this.commandHandler.updateSelector()}return u},t.prototype.dragSourceEnd=function(e,i,r){this.insertBlazorDiagramObjects(e),this.commandHandler.dragSourceEnd(e,i,r),this.callBlazorModel&&this.commandHandler.getBlazorOldValues()},t.prototype.dragTargetEnd=function(e,i,r){this.insertBlazorDiagramObjects(e),this.commandHandler.dragTargetEnd(e,i,r),this.callBlazorModel&&this.commandHandler.getBlazorOldValues()},t.prototype.findObjectsUnderMouse=function(e,i){return this.eventHandler.findObjectsUnderMouse(e,i)},t.prototype.findObjectUnderMouse=function(e,i,r){return this.eventHandler.findObjectUnderMouse(e,i,r)},t.prototype.findTargetObjectUnderMouse=function(e,i,r,s,o){return this.eventHandler.findTargetUnderMouse(e,i,r,s,o)},t.prototype.findElementUnderMouse=function(e,i,r,s){return this.eventHandler.findElementUnderMouse(e,i,r,s)},t.prototype.findActionToBeDone=function(e,i,r,s){return this.eventHandler.findActionToBeDone(e,i,r,s)},t.prototype.updateConnectorPort=function(e){if(e.ports.length)for(var i=void 0,r=0,s=e.ports;r=0;s--)if(i.push(r[parseInt(s.toString(),10)]),i.length>this.historyManager.stackLimit)return i}else i=r;return i},t.prototype.getEdges=function(e){return e.outEdge?this.nameTable[e.id].outEdges:this.nameTable[e.id].inEdges},t.prototype.getParentId=function(e){return this.nameTable[""+e].parentId},t.prototype.addConnector=function(e){return this.add(e)},t.prototype.UpdateBlazorDiagramModelCollection=function(e,i,r,s){},t.prototype.UpdateBlazorDiagramModel=function(e,i,r,s){},t.prototype.UpdateBlazorLabelOrPortObjects=function(e,i,r,s){},t.prototype.addBlazorDiagramObjects=function(){},t.prototype.removeNodeEdges=function(e,i,r){var s=this.nameTable[""+e],o=r?s.outEdges:s.inEdges;if(o.length>0)for(var a=0;a0)){for(var c=0;c0))}this.removePortEdges(l,a.element.sourcePortID,a.element.id,h)}a.element.targetID&&this.removeNodeEdges(a.element.targetID,a.element.id,!1)}}this.diagramActions=this.diagramActions|ee.PublicMethod,e.id=e.id||Qe();var u=this.activeLayer;if(!a.cancel&&u&&!u.lock){if(u.objects.indexOf(e.id)<0&&!u.lock&&(u.visible||(u.visible=!0,this.dataBind()),u.objects.push(e.id)),fs(e)===de)(r=new de(this,"connectors",e,!0)).status="New",this.nameTable[r.targetID]&&"TextAnnotation"===this.nameTable[r.targetID].shape.shape&&(r.isBpmnAnnotationConnector=!0,r.constraints=r.constraints&~qe.Delete),Ro(r,e,this.connectorDefaults),this.connectors.push(r),this.initObject(r),!1===e.visible&&this.updateElementVisibility(r.wrapper,r,e.visible),this.updateEdges(r),this.insertBlazorConnector(r);else{if(Ro(r=new te(this,"nodes",e,!0),e,this.nodeDefaults),r.parentId=e.parentId?e.parentId:r.parentId,r.umlIndex=e.umlIndex,r.status="New",(o="TextAnnotation"===r.shape.shape)&&!e.isTextAnnotationCopied&&(r.inEdges=e.inEdges?e.inEdges:r.inEdges),this.nodes.push(r),this.initObject(r,u,void 0,i),o&&this.bpmnModule)for(c=0;c-1&&e.parentId&&this.nameTable[e.parentId]&&"UmlClassifier"===this.nameTable[e.parentId].shape.type){var g=this.nameTable[e.parentId];g.children.splice(r.umlIndex,0,r.id),g.wrapper.children.splice(r.umlIndex,0,r.wrapper),g.wrapper.measure(new me),g.wrapper.arrange(g.wrapper.desiredSize),this.updateDiagramObject(g)}}if(a={element:r,cause:this.diagramActions,diagramAction:this.getDiagramAction(this.diagramActions),state:"Changed",type:"Addition",cancel:!1},this.parentObject&&(a.parentId=this.parentObject.id),"helper"!==e.id&&!(this.diagramActions&ee.PreventCollectionChangeOnDragOver)&&this.triggerEvent(Ce.collectionChange,a),!(this.diagramActions&ee.UndoRedo||this.diagramActions&ee.Group||this.diagramActions&ee.PreventHistory)){var v={type:"CollectionChanged",changeType:"Insert",undoObject:$(e),redoObject:$(e),category:"Internal"};this.addHistoryEntry(v)}this.parentObject=void 0,"SVG"===this.mode&&(this.updateSvgNodes(r),this.updateTextElementValue(r),this.updateDiagramObject(r),o&&this.updateDiagramObject(this.nameTable[r.inEdges[0]]),r.shape.activity&&r.shape.activity.subProcess.processes&&r.shape.activity.subProcess.processes.length&&this.updateProcesses(r),this.updateBridging())}}if(this.protectPropertyChange(s),this.resetDiagramActions(ee.PublicMethod),r&&this.layers.length>1&&this.moveNode(r),this.views)for(var S=0,b=this.views;S=0;l--)this.moveSvgNode(a[parseInt(l.toString(),10)])}for(var h=0,c=i;h=0;o--)r[parseInt(o.toString(),10)]===e.id&&r.splice(o,1);for(var a=0;s.ports&&a=0;s--)if(i=this.nameTable[r[parseInt(s.toString(),10)]])if(this.connectorTable[i.id]=$(i),i.isBpmnAnnotationConnector){var o=this.nameTable[i.targetID];this.removeObjectsFromLayer(i);var a=this.connectors.indexOf(i);-1!==a&&this.connectors.splice(a,1),this.removeElements(i),this.removeFromAQuad(i),delete this.nameTable[i.id];var l=this.nameTable[i.sourceID];if(l){var h=l.outEdges.indexOf(i.id);-1!==h&&l.outEdges.splice(h,1)}e.id!==i.targetID&&this.remove(o)}else this.remove(i)},t.prototype.removeObjectsFromLayer=function(e){if(e.children)for(var i=0;i-1&&(_r(this,e)&&this.unSelect(e),this.layers[parseInt(s.toString(),10)].objects.splice(a,1),delete this.layers[parseInt(s.toString(),10)].zIndexTable[this.nameTable[e.id].zIndex])},t.prototype.removeElements=function(e){if("SVG"===this.mode||"Canvas"===this.mode&&"Native"===e.shape.type){var i=xt(e.id+"_groupElement",this.element.id),r=e;if(r.ports&&r.ports.length>0)for(var s=0;s0){l[parseInt(s.toString(),10)].id.indexOf("icon_content")>0&&"SVG"===this.mode&&((h=xt(l[parseInt(s.toString(),10)].id+"_shape_groupElement",this.element.id))&&h.parentNode.removeChild(h),(h=xt(l[parseInt(s.toString(),10)].id+"_rect_groupElement",this.element.id))&&h.parentNode.removeChild(h));for(var c=0,d=this.views;c=0;o--)a.children[parseInt(o.toString(),10)].children&&(l=n.nameTable[a.children[parseInt(o.toString(),10)].id])&&(l.isLane?$v(n,l):(n.removeDependentConnector(l),n.diagramActions|=ee.PreventHistory,l.constraints&ie.Delete?n.remove(l):q3(n,l,{},!1),n.diagramActions&=~ee.PreventHistory));a&&(i=n.nameTable[a.id])&&$v(n,i)}}(this,e),!(this.diagramActions&ee.UndoRedo||this.diagramActions&ee.PreventHistory)&&(e instanceof te||e instanceof de)){var o={type:"CollectionChanged",changeType:"Remove",undoObject:$(e),redoObject:$(e),category:"Internal"};this.diagramActions&ee.Clear||e.children&&!e.isLane&&!e.isPhase&&e.children.length>0&&this.undoRedoModule&&"None"===this.layout.type&&(this.historyManager.startGroupAction(),s=!0),(e instanceof te||e instanceof de)&&this.deleteDependentConnector&&this.removeDependentConnector(e),!e.isLane&&!e.isPhase&&!(this.diagramActions&ee.Clear)&&!this.isStackChild(e)&&this.addHistoryEntry(o)}"TextAnnotation"===e.shape.shape&&this.removeDependentConnector(e),e.children&&!e.isLane&&!e.isPhase&&(!(this.diagramActions&ee.UndoRedo)||!ce())&&this.deleteGroup(e),e.parentId&&(this.deleteChild(e,void 0,!0),this.nameTable[e.parentId]&&"UmlClassifier"===this.nameTable[e.parentId].shape.type&&(this.updateDiagramObject(this.nameTable[e.parentId]),this.updateConnectorEdges(this.nameTable[e.parentId])));var a=void 0;this.diagramActions=this.diagramActions|ee.PublicMethod;var l=this.nameTable[e.id];if(l instanceof te?("Bpmn"===l.shape.type&&this.bpmnModule&&this.bpmnModule.removeBpmnProcesses(l,this),(l.isLane||l.isPhase||"SwimLane"===l.shape.type)&&(h=l.isLane||l.isPhase?this.nameTable[l.parentId]:this.nameTable[l.id],l.isLane?Q3(this,l,h):l.isPhase&&G3(this,l,h)),-1!==(a=this.nodes.indexOf(l))&&(this.crudDeleteNodes.push(this.nameTable[l.id]),this.nodes.splice(a,1),this.updateNodeEdges(l))):(-1!==(a=this.connectors.indexOf(l))&&(this.crudDeleteNodes.push(this.nameTable[l.id]),this.connectors.splice(a,1)),this.updateEdges(l),this.spliceConnectorEdges(e,!0),this.spliceConnectorEdges(e,!1)),!this.isServerUpdate&&!(this.blazorActions&on.GroupClipboardInProcess)&&this.commandHandler.getBlazorOldValues(),s&&this.historyManager.endGroupAction(),_r(this,l)&&this.unSelect(l),!l.isPhase){if(this.removeObjectsFromLayer(e),this.currentDrawingObject&&(this.currentDrawingObject.wrapper=void 0),delete this.nameTable[e.id],i.length>0&&i[0].id===l.id&&l.parentId){var h,d=this.nameTable[l.parentId];d&&d.isLane&&"SwimLane"===this.nameTable[d.parentId].shape.type&&Y3(this,h=this.nameTable[d.parentId],d,l)}this.removeElements(l),this.updateBridging(),"SVG"!==this.mode&&this.refreshDiagramLayer(),this.diagramActions&ee.Clear||(this.removeFromAQuad(l),r={element:e,cause:this.diagramActions,diagramAction:this.getDiagramAction(this.diagramActions),state:"Changed",type:"Removal",cancel:!1},"helper"!==e.id&&this.triggerEvent(Ce.collectionChange,r),this.resetTool())}}}else if(i.length>0){this.undoRedoModule&&(this.historyManager.startGroupAction(),this.blazorActions|=on.GroupingInProgress,s=!0);for(var u=0;u=f.wrapper.bounds.width&&"Horizontal"===f.shape.orientation||this.selectedItems.wrapper.bounds.y<=f.wrapper.bounds.y+g&&this.selectedItems.wrapper.bounds.height>=f.wrapper.bounds.height-g&&"Vertical"===f.shape.orientation)&&(LI(f)||f.shape.lanes.length>1)&&this.remove(i[parseInt(u.toString(),10)])}}else this.remove(i[parseInt(u.toString(),10)])}s&&(this.blazorActions&=~on.GroupingInProgress,this.isServerUpdate=!0,this.commandHandler.getBlazorOldValues(),this.UpdateBlazorDiagramModelCollection(void 0,void 0,void 0,!0),this.historyManager.endGroupAction(),this.isServerUpdate=!1),this.clearSelection()}e&&(LI(e)||this.diagramActions&ee.Clear)||this.diagramActions&ee.UndoRedo||this.diagramActions&ee.PreventHistory||!(e instanceof te||e instanceof de)||(o={type:"ConnectionChanged",undoObject:$(e),redoObject:$(e),category:"Internal"},!e.isLane&&!e.isPhase&&!(this.diagramActions&ee.Clear)&&!this.isStackChild(e)&&this.addHistoryEntry(o)),this.tooltipObject.close()},t.prototype.isStackChild=function(e){var i,r=this.nameTable[e.parentId];if(e&&e.parentId&&r.container&&"Stack"===r.container.type&&"UmlClassifier"!==this.nameTable[e.parentId].shape.type){i=!0;var s={sourceIndex:r.wrapper.children.indexOf(e.wrapper),source:e,target:void 0,targetIndex:void 0};this.diagramActions&ee.UndoRedo||this.addHistoryEntry({type:"StackChildPositionChanged",redoObject:{sourceIndex:void 0,source:e,target:void 0,targetIndex:void 0},undoObject:s,category:"Internal"})}return i},t.prototype.deleteChild=function(e,i,r){var s;if(s="string"==typeof e?e:e.id,(i=i?this.nameTable[i.id]:this.nameTable[e.parentId])&&i.children){for(var o=0;o=0;i--)this.removeLayer(this.layers[parseInt(i.toString(),10)].id);this.commandHandler.addLayer({id:"default_layer",visible:!0,lock:!1,objects:[],zIndex:0,objectZIndex:-1,zIndexTable:{}},null,!0),this.setActiveLayer(this.layers[this.layers.length-1].id)},t.prototype.clearObjects=function(e){var i=[];i=e||(i=i.concat(this.nodes)).concat(this.connectors),this.diagramActions=this.diagramActions|ee.Clear;for(var r=0,s=i;r0||"Text"===e.shape.type))if("Text"===e.shape.type)i=e.wrapper.children[0].id.split("_")[1];else for(var f=e.annotations.length-1;f>=0;f--)e.annotations[parseInt(f.toString(),10)].visibility&&(i=e.annotations[parseInt(f.toString(),10)].id);i&&(u=this.getWrapper(e.wrapper,i))}if(e&&u&&!(u instanceof Jn)&&(!function sne(n,t){return"Text"===t.shape.type?t.constraints&ie.ReadOnly:t.constraints&(t instanceof de?qe.ReadOnly:ie.ReadOnly)?n.constraints&Lr.InheritReadOnly?1:0:n.constraints&Lr.ReadOnly?1:0}(u,e)||p)){var g=u.style,v=void 0;v=90>(v=u.bounds.width50?50:e.width,u.style.fontSize)),e.parentId&&"UmlClassifier"===this.nameTable[e.parentId].shape.type?(l.width=e.wrapper.bounds.width-20,c=(e.wrapper.bounds.center.x+r.tx)*r.scale-l.width/2*s-2.5,d=(e.wrapper.bounds.center.y+r.ty)*r.scale-l.height/2*s-3,u.style.textAlign="Left"):(l.width=Math.max(l.width,50),c=(u.bounds.center.x+r.tx)*r.scale-l.width/2*s-2.5,d=(u.bounds.center.y+r.ty)*r.scale-l.height/2*s-3),Ho(y,{id:this.element.id+"_editTextBoxDiv",style:"position: absolute;left:"+c+"px;top:"+d+"px;width:"+(l.width+1)*s+"px;height:"+l.height*s+"px; containerName:"+e.id+";"}),Ho(S,{"aria-label":a,id:this.element.id+"_editBox",style:"width:"+(l.width+1)*s+"px;height:"+l.height*s+"px;resize: none;outline: none;overflow: hidden;;font-family:"+g.fontFamily+";font-size:"+g.fontSize*s+"px;text-align:"+u.style.textAlign.toLocaleLowerCase()+";",class:"e-diagram-text-edit"}),S.style.fontWeight=g.bold?"bold":"",S.style.fontStyle=g.italic?"italic":"",S.style.lineHeight=(1.2*g.fontSize+"px;").toString(),S.style.textDecoration=g.textDecoration?g.textDecoration:"",this.activeLabel.parentId=e.id,this.activeLabel.id=i,u.visible=!1,this.updateDiagramObject(e),this.diagramActions=this.diagramActions|ee.TextEdit,this.isTriggerEvent||(E.add(S,"input",this.eventHandler.inputChange,this.eventHandler),E.add(S,"focusout",this.focusOutEdit,this),S.select())}}}},t.prototype.updateConnectorfixedUserHandles=function(e){if(e.fixedUserHandles.length)for(var i=void 0,r=0,s=e.fixedUserHandles;r0&&this.mindMapChartModule.updateLayout(o,this.nameTable,this.layout,l,this.dataSourceSettings.id,this.dataSourceSettings.root),e=!0;else if(this.radialTreeModule)this.radialTreeModule.updateLayout(o,this.nameTable,this.layout,l),e=!0;else if(this.symmetricalLayoutModule)this.symmetricalLayoutModule.maxIteration=this.layout.maxIteration,this.symmetricalLayoutModule.springLength=this.layout.springLength,this.symmetricalLayoutModule.springFactor=this.layout.springFactor,this.symmetricalLayoutModule.updateLayout(o,this.connectors,this.symmetricalLayoutModule,this.nameTable,this.layout,l),e=!0;else if(this.complexHierarchicalTreeModule){this.canDistribute(a,r)&&(this.lineDistributionModule.diagram=this,this.connectors.forEach(function(R){R.obstaclePointCollection=[]}));var c=this.complexHierarchicalTreeModule.getLayoutNodesCollection(this.nodes);c.length>0&&this.complexHierarchicalTreeModule.doLayout(c,this.nameTable,this.layout,l,this),e=!0,this.canDistribute(a,r)&&this.lineDistributionModule.initLineDistribution(this.layout,this)}else this.flowchartLayoutModule?(this.flowchartLayoutModule.updateLayout(this.nodes,this),e=!0):console.warn("[WARNING] :: Module "+("OrganizationalChart"===this.layout.type?"HierarchicalTree":this.layout.type)+" is not available in Diagram component! You either misspelled the module name or forgot to load it.");if(e){this.preventDiagramUpdate=!0;for(var u={},f=0,g=o;f0)for(var S=0;S0)for(var M=0;M0)for(var s=0,o=r.ports;s0&&function Rse(n){var t,e,i,r=[];for(t=0;t0&&y.connectors[w].bezierSettings&&y.connectors[w].bezierSettings.allowSegmentsReset&&(y.connectors[w].segments=[]);if(t.connectors=y.connectors||[],t.dataSourceSettings=y.dataSourceSettings||{},t.dataSourceSettings.doBinding=i,t.height=y.height||"100%",t.setNodeTemplate=r,t.getConnectorDefaults=v,t.getNodeDefaults=g,t.getCustomProperty=o,t.mode=y.mode||"SVG",y.nodes)for(w=0;w0)){var r=this.nodes.filter(function(a){return 0===a.inEdges.length})[0],s=this.convertMindmapToMermaid(r,0);i.push(s),this.updateTextDataSource(i,r.outEdges,1),e=(i=i.filter(function(a){return""!==a.trim()})).join("\n")}return e},t.prototype.updateTextDataSource=function(e,i,r){for(var s=0;s0&&this.updateTextDataSource(e,h,r+1),s++}},t.prototype.convertMindmapToMermaid=function(e,i){var r=e.id,o=" ".repeat(2*(i+1)),a=e.annotations.length>0?e.annotations[0].content.replace(/\n/g," "):"",l=o+a,h=o+r;if(e.shape&&"Basic"===e.shape.type){var c=e.shape;"Rectangle"===c.shape?l=h+"["+a+"]":"Ellipse"===c.shape?l=h+"(("+a+"))":"Hexagon"===c.shape&&(l=h+"{{"+a+"}}")}else if(e.shape&&"Flow"===e.shape.type)"Terminator"===e.shape.shape&&(l=h+"("+a+")");else if(e.shape&&"Path"===e.shape.type){var u=e.shape;u.data===this.bangShape?l=h+"))"+a+"((":u.data===this.cloudShape&&(l=h+")"+a+"(")}return l},t.prototype.saveFlowDiagramInMermaidFormat=function(){var e=this,i=[],r="graph TD\n",s={nodes:this.nodes,edges:this.connectors};return s.nodes.reduce(function(a,l){return a[l.id]=l.annotations.length?l.annotations[0].content:"",a},{}),s.edges.forEach(function(a){var l=a.sourceID,h=a.targetID,p=e.nameTable[""+h],f=e.getNodeShape(e.nameTable[""+l]),g=e.getNodeShape(p),v=a.annotations[0]&&""!==a.annotations[0].content?"|"+a.annotations[0].content+"|":"";-1===i.indexOf(l)?i.push(l):f="",-1===i.indexOf(h)?i.push(h):g="";var y=e.arrowType(a);r+=" "+l+f+" "+y+v+" "+h+g+"\n"}),s.nodes.forEach(function(a){r+=" style "+a.id+" fill:"+a.style.fill+",stroke:"+a.style.strokeColor+",stroke-width:"+a.style.strokeWidth+"px;\n"}),r},t.prototype.arrowType=function(e){var i=e.targetDecorator.shape;return e.style.opacity<1?"~~~":""!==e.style.strokeDashArray?"-.->":"Arrow"===i?e.style.strokeWidth>1?"==>":"--\x3e":"None"===i?"---":"--\x3e"},t.prototype.getNodeShape=function(e){var i=e.annotations.length>0?e.annotations[0].content:"",r=e.shape.shape;if(!r){var s=e.shape.data;return"M 0 0 A 1 1 0 0 0 7 0 A 1 1 0 0 0 0 0 M -1 0 A 1 1 0 0 0 8 0 A 1 1 0 0 0 -1 0"===s?"((("+i+")))":"M 0 0 L 1 -1 L 5 -1 L 6 0 L 0 0"===s?"[/"+i+"\\]":"M 0 1 L 0 6 C 2 7 4 7 6 6 L 6 1 C 5 0 1 0 0 1 C 1 2 5 2 6 1"===s?"[("+i+")]":"M 0 0 L 12 0 L 14 2 L 2 2 L 0 0"===s?"[\\"+i+"\\]":"M 0 0 L 5 0 L 4 1 L 1 1 L 0 0"===s?"[\\"+i+"/]":"M 0 0 L 2 -2 L 11 -2 L 13 0 L 11 2 L 2 2 L 0 0"===s?"{{"+i+"}}":">"+i+"]"}switch(r){case"Terminator":return"(["+i+"])";case"Process":default:return"["+i+"]";case"Decision":return"{"+i+"}";case"Parallelogram":return"[/"+i+"/]";case"Ellipse":return"(("+i+"))";case"PreDefinedProcess":return"[["+i+"]]"}},t.prototype.loadDiagramFromMermaid=function(e){this.layout&&"Flowchart"===this.layout.type&&this.flowchartLayoutModule?this.convertMermaidToFlowChart(e):this.layout&&"MindMap"===this.layout.type&&this.mindMapChartModule?this.convertMermaidToMindmap(e):console.warn('[WARNING] :: Module "FlowchartLayout" or "MindMap" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.countLeadingSpaces=function(e){for(var i=0,r=e.length;i0});this.clear(),this.mermaidNodeBaseCollection=[];var r=[],s={text:"",children:[],currentLevel:0,branch:"Left"},o=[],l=!1,h=!1,c=!1;if(i.length>0){for(var d=function(M){var w=i[parseInt(M.toString(),10)],C=0,D="",A=u.countLeadingSpaces(w),x=w.includes('"`');if(h=w.includes('`"'),c=(l=!!x||l)||c?c:0===A&&M>0,l&&h&&!x)return s.text+="\n"+w,l=!1,"continue";if(!x&&l)return s.text+="\n"+w,"continue";if(l=!h&&l,w.length>0&&(/\s/.test(w[0])&&M>0||0===A)){if(-1!==o.findIndex(function(B){return B.space===A.toString()}))for(var L=o.length-1;L>=0;L--){var O=o[parseInt(L.toString(),10)];if((N=parseFloat(O.space))>A)o.splice(L,1);else{if(N=0;L--){var N,T=o[parseInt(L.toString(),10)];if(!((N=parseFloat(T.space))>A)){var P=o[o.length-1];o.push({space:A.toString(),level:P.level+1});break}o.splice(L,1)}C=o[o.length-1].level}D=w.trim().replace(/^[+-]/,"")}var _={text:D,branch:void 0,children:[],currentLevel:0===M?0:C-1};if(r.length>0){for(;r.length>=C&&0!==r.length;)r.pop();r.length>0&&r[r.length-1].children.push(_)}r.push(_),s=_},u=this,p=0;p0){var c=h[h.length-1];c.arrowType=a[2],""!==a[3]&&(c.label&&c.label.some(function(d){return d.trim().length>0})?c.label.push(a[3]):(c.label=[],c.label[c.parentId.length-1]=a[3]))}h.filter(function(d){return d.parentId&&0===d.parentId.length}).forEach(function(d){d.parentId=null}),i=i.concat(h)}}this.createFlowChart(i),this.doLayout(),this.clearHistory()},t.prototype.createFlowChart=function(e){for(var i=[],r=0;r1)for(var h=0;h|---|--\s*.*?\s*-->|~~~|==>|===|==\s*.*?\s*==>|\s*-\.\s*->|\s*-\.\s*-|\s*-\.\s*.*?\s*\.\s*->|\s*-\..*?\.\s*->)(.*)$/);if(l){i=l[1].trim();var h=l[2].trim();r=l[3].trim();var d=h.match(/(-\.|\\-\\-|==|--|~~)(.*?)(\1>|\.->|==>|\\->|~~>)/),u=void 0,p="";o=null!==(u=d?{text:d[2].trim()||null,arrowType:d[1]+d[3]}:{text:null,arrowType:h}).text?u.text:"",s=(p=u.arrowType).includes("--\x3e")?"single-line-arrow":p.includes("---")?"single-line":p.includes("==>")?"double-line-arrow":p.includes("==")?"double-line":p.includes("~~~")?"wiggly-arrow":p.includes("-.->")||p.includes(".->")?"dotted-arrow":p.includes("-.-")||p.includes(".-")?"dotted":"single-line-arrow"}return[i,r,s,o]},t.prototype.parseStyle=function(e,i){if(e.startsWith("style")){var s=e.match(/^style\s+(\w+)\s+fill:([^,]+),stroke:([^,]+),stroke-width:(\d+)px;/);if(s){var c={id:s[1],fill:s[2],stroke:s[3],strokeWidth:parseInt(s[4],10)},d=i.filter(function(u){return u.id===c.id});d[0].color=c.fill,d[0].stroke=c.stroke,d[0].strokeWidth=c.strokeWidth}}},t.prototype.getNodeData=function(e,i,r){for(var s=[],o=null,a=null,l=0,h="",c=function(v){var y=e[parseInt(v.toString(),10)],S=d.splitNested(y);if(S[0].includes("|")){var b=S[0].match(/\|([^|]*)\|/);b&&(h=b[1]);var M=S[0].split("|");M.length>=3&&(S[0]=M[2].trim())}var w=S[0].trim();if(0===v?o=w:a=w,i.find(function(L){return L.id===w}))l++;else{var D=S.length>1?S[1]:S[0],A=d.getShape(D),x=D.replace(/[\\[\]\\(\\)\\{\\}\\{\\}\\/>]/g,"");s.push({id:w,name:x,shape:A,color:"white",parentId:[]})}},d=this,u=0;u"===h?0===s?(r.trim().length>0&&i.push(r.trim()),r=h,o=h,s++):(r+=h,s++):"]"===h||"}"===h||")"===h?1===s&&h===o?(i.push((r+=h).trim()),r="",s--):s>1?(r+=h,s--):r+=h:r+=h}return r.trim().length>0&&i.push(r.trim()),i},t.prototype.getShape=function(e){var i={};return e.startsWith("(((")?i={type:"Path",data:"M 0 0 A 1 1 0 0 0 7 0 A 1 1 0 0 0 0 0 M -1 0 A 1 1 0 0 0 8 0 A 1 1 0 0 0 -1 0"}:e.startsWith("((")?i={shape:"Ellipse",type:"Basic"}:e.startsWith("([")?i={type:"Flow",shape:"Terminator"}:e.startsWith("(")?i={type:"Flow",shape:"Process"}:e.startsWith("[[")?i={type:"Flow",shape:"PreDefinedProcess"}:e.startsWith("[/")?i=e.endsWith("/]")?{type:"Basic",shape:"Parallelogram"}:{type:"Path",data:"M 0 0 L 1 -1 L 5 -1 L 6 0 L 0 0"}:e.startsWith("[(")?i={type:"Path",data:"M 0 1 L 0 6 C 2 7 4 7 6 6 L 6 1 C 5 0 1 0 0 1 C 1 2 5 2 6 1"}:e.startsWith("[\\")?i=e.endsWith("\\]")?{type:"Path",data:"M 0 0 L 12 0 L 14 2 L 2 2 L 0 0"}:{type:"Path",data:"M 0 0 L 5 0 L 4 1 L 1 1 L 0 0"}:e.startsWith("[")?i={type:"Basic",shape:"Rectangle"}:e.startsWith("{{")?i={type:"Path",data:"M 0 0 L 2 -2 L 11 -2 L 13 0 L 11 2 L 2 2 L 0 0"}:e.startsWith("{")?i={type:"Flow",shape:"Decision"}:e.startsWith(">")&&(i={type:"Path",data:"M 0 0 L 8 0 L 8 2 L 0 2 L 2 1 L 0 0"}),i},t.prototype.getDiagramContent=function(e){return this.printandExportModule?this.printandExportModule.getDiagramContent(e):(console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),"")},t.prototype.exportImage=function(e,i){this.printandExportModule?this.printandExportModule.exportImages(e,i):console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.printImage=function(e,i){this.printandExportModule?(i.printOptions=!0,this.printandExportModule.exportImages(e,i)):console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.setStackLimit=function(e){this.undoRedoModule&&e&&(this.historyManager.stackLimit=e,this.undoRedoModule.applyLimit(this.historyManager.currentEntry,e,this,!0))},t.prototype.clearHistory=function(){this.undoRedoModule&&this.undoRedoModule.clearHistory(this)},t.prototype.getDiagramBounds=function(){if(this.printandExportModule){var e=this.printandExportModule.getDiagramBounds("",{});return e.width=e.width>this.scrollSettings.viewPortWidth?e.width+(e.x>0?e.x:0):this.scrollSettings.viewPortWidth,e.height=e.height>this.scrollSettings.viewPortHeight?e.height+(e.y>0?e.y:0):this.scrollSettings.viewPortHeight,e.x=e.x>0?0:e.x,e.y=e.y>0?0:e.y,e}return console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),new Ne},t.prototype.exportDiagram=function(e){return this.printandExportModule?this.printandExportModule.exportDiagram(e):(console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),"")},t.prototype.print=function(e){this.printandExportModule?this.printandExportModule.print(e):console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.addPorts=function(e,i){var s;this.protectPropertyChange(!0),e=this.nameTable[e.id]||e,i.length>1&&this.startGroupAction();for(var o=function(h){if(e.ports.some(function(y){return y.id===i[parseInt(h.toString(),10)].id}))return"continue";if(e instanceof te?(s=new Es(e,"ports",i[parseInt(h.toString(),10)],!0),e.ports.push(s)):e instanceof de&&(s=new xc(e,"ports",i[parseInt(h.toString(),10)],!0),e.ports.push(s)),e.children)for(var c=e.wrapper,d=0;d1&&this.endGroupAction(),e.wrapper.measure(new me(e.width,e.height)),e.wrapper.arrange(e.wrapper.desiredSize),this.updateDiagramObject(e),this.protectPropertyChange(!1)},t.prototype.addConstraints=function(e,i){return e|i},t.prototype.removeConstraints=function(e,i){return e&~i},t.prototype.addNodeLabels=function(e,i){this.addLabels(e,i)},t.prototype.addConnectorLabels=function(e,i){this.addLabels(e,i)},t.prototype.addLabels=function(e,i){this.protectPropertyChange(!0);var s,r=(e=this.nameTable[e.id]||e).wrapper;i.length>1&&this.startGroupAction();for(var o=0;o1&&this.endGroupAction(),e.wrapper.measure(new me(r.width,r.height)),e.wrapper.arrange(r.desiredSize),this.updateDiagramObject(e),this.protectPropertyChange(!1),this.refreshCanvasLayers()},t.prototype.addChildToUmlNode=function(e,i,r){var s,o,a,l,h="NoWrap";"Class"===e.shape.classifier||"Interface"===e.shape.classifier?"Method"===r?(o=new cm(e,"",i),"Class"===e.shape.classifier?(e.shape.classShape.methods.push(o),s=e.shape.classShape):"Interface"===e.shape.classifier&&(e.shape.interfaceShape.methods.push(o),s=e.shape.interfaceShape),function soe(n,t,e,i){if(e.methods&&e.methods.length){var r=e.methods,s="",o="",a=void 0,l=1,h=void 0,c=0,d=0,u=n.shape,g="Class"===u.classifier?u.classShape:u.interfaceShape;1===r.length?g.attributes.length>0?(c=g.attributes.filter(function(w){return w.isSeparator}).length,h=(l=2+g.attributes.length+c)+1,aT(n,t,l)):h=l+1:(c=g.attributes.filter(function(w){return w.isSeparator}).length,d=g.methods.filter(function(w){return w.isSeparator}).length,h=(l=2+g.attributes.length+c+g.methods.length+d)+1);for(var v=0;v1&&this.startGroupAction();for(var r=i.length-1;r>=0;r--)if(e.children&&e.children.length>0){var s=e.wrapper.children.filter(function(o){return o.id===e.id+"group_container"});s&&s.length>0&&this.removelabelExtension(e,i,r,s[0])}else this.removelabelExtension(e,i,r,e.wrapper);i.length>1&&this.endGroupAction(),this.refreshCanvasLayers()},t.prototype.removePortsExtenion=function(e,i,r,s){for(var o=0;o1&&this.startGroupAction();for(var r=i.length-1;r>=0;r--)if(e.children&&e.children.length>0)for(var s=0;s1&&this.endGroupAction()},t.prototype.getSizeValue=function(e,i){var r;return r=e.toString().indexOf("px")>0?e.toString():e.toString().indexOf("%")>0?void 0!==i?"100%":e.toString():e.toString()+"px",i&&(qa(this),r="calc("+r+" - "+i+"px)"),r},t.prototype.renderRulers=function(){this.rulerSettings.showRulers?(function ise(n){var t=qa(n),i=Tt("div",{id:n.element.id+"_overlapRuler",style:"height:"+t.height+"px;width:"+t.width+"px;position:absolute;left:0;top:0",class:"e-ruler-overlap"});n.element.insertBefore(i,n.element.firstChild)}(this),oF(this,!0),oF(this,!1)):qx(this)},t.prototype.intOffPageBackground=function(){var e=new me;e=qa(this);var i=document.getElementById(this.element.id+"content"),r=this.getSizeValue(this.width,e.width),s=this.getSizeValue(this.height,e.height),o=this.rulerSettings.showRulers?"width:"+r+"; height:"+s+";top:"+e.height+"px;left:"+e.width+"px;overflow: scroll;position:absolute;overflow:auto;":"width:"+r+"; height:"+s+";position:absolute; left:0px; top:0px;overflow: auto;",a={id:this.element.id+"content",tabindex:"0",style:o};i?(this.diagramCanvas=i,Za(this.diagramCanvas,o)):(this.diagramCanvas=Tt("div",a),this.element.appendChild(this.diagramCanvas)),this.diagramCanvas.style.background=this.backgroundColor},t.prototype.initDiagram=function(){this.intOffPageBackground(),Ho(this.element,{style:"width:"+this.getSizeValue(this.width)+"; height:"+this.getSizeValue(this.height)+";position:relative;overflow:hidden;"})},t.prototype.renderHiddenUserHandleTemplateLayer=function(e){var r=Tt("div",{class:this.element.id+"_hiddenUserHandleTemplate",style:"width:"+e.width+"px; height:"+e.height+"px;visibility:hidden ; overflow: hidden;"});this.element.appendChild(r)},t.prototype.renderBackgroundLayer=function(e,i){var r=this.createSvg(this.element.id+"_backgroundLayer_svg",e.width,e.height);Za(r,i);var s=Bi("g",{id:this.element.id+"_backgroundImageLayer",class:"e-background-image-layer"});r.appendChild(s);var a=Bi("g",{id:this.element.id+"_backgroundLayer",class:"e-background-layer"});r.appendChild(a),this.diagramCanvas.appendChild(r)},t.prototype.renderGridLayer=function(e,i){var r=this.createSvg(this.element.id+"_gridline_svg",e.width,e.height);r.setAttribute("class","e-grid-layer");var s=Bi("g",{id:this.element.id+"_gridline"}),o=Bi("rect",{id:this.element.id+"_grid_rect",x:"0",y:"0",width:"100%",height:"100%"});if(sm()){var a=new URL(window.location.href);o.setAttribute("fill",""!==a.search?"url(#"+this.element.id+"_pattern)":"url("+location.protocol+"//"+location.host+location.pathname+"#"+this.element.id+"_pattern)")}else o.setAttribute("fill","url(#"+this.element.id+"_pattern)");s.appendChild(o),r.appendChild(s),this.diagramCanvas.appendChild(r),oi(r,{style:i})},t.prototype.renderDiagramLayer=function(e,i){if(this.diagramLayerDiv=Tt("div",{id:this.element.id+"_diagramLayer_div",style:"width:"+e.width+"px; height:"+e.height+"px;"+i}),"SVG"===this.mode){var s=this.createSvg(this.element.id+"_diagramLayer_svg",e.width,e.height);s.style["pointer-events"]="none",s.setAttribute("class","e-diagram-layer");var o=Bi("g",{id:this.element.id+"_diagramLayer"}),a=Bi("g",{});this.diagramLayer=o,s.style["pointer-events"]="all",a.appendChild(o),s.appendChild(a),this.diagramLayerDiv.appendChild(s)}else this.diagramLayer=bo.createCanvas(this.element.id+"_diagram",e.width,e.height),Za(this.diagramLayer,"position:absolute;left:0px;top:0px;"),this.diagramLayerDiv.appendChild(this.diagramLayer);this.diagramCanvas.appendChild(this.diagramLayerDiv)},t.prototype.initLayers=function(){var e="position:absolute;top:0px;left:0px;overflow:hidden;pointer-events:none;",r=document.getElementById(this.element.id).getBoundingClientRect(),s=function Loe(){var n=Tt("div",{style:"visibility:hidden; width: 100px"});document.body.appendChild(n);var t=n.getBoundingClientRect().width;n.style.overflow="scroll";var e=Tt("div",{style:"width:100%"});n.appendChild(e);var i=e.getBoundingClientRect().width;return n.parentNode.removeChild(n),t-i}();this.scroller.scrollerWidth=s,this.scroller.setViewPortSize(r.width,r.height),this.renderRulers();var o="measureElement";window[""+o]&&(window[""+o]=null,document.getElementById("measureElement").remove()),function WF(){var n="measureElement";if(window[""+n])window[""+n].usageCount+=1;else{var t=Tt("div",{id:"measureElement",style:"visibility:hidden ; height: 0px ; width: 0px; overflow: hidden;"}),e=Tt("span",{style:"display:inline-block ; line-height: normal"});t.appendChild(e);var i=Tt("img",{alt:"measureElementImage",src:"data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7"});t.appendChild(i);var r=document.createElementNS("http://www.w3.org/2000/svg","svg");r.setAttribute("xmlns:xlink","http://www.w3.org/1999/xlink"),t.appendChild(r);var s=document.createElementNS("http://www.w3.org/2000/svg","path");s.setAttribute("d",""),r.appendChild(s),document.createTextNode("");var a=document.createElementNS("http://www.w3.org/2000/svg","text");a.setAttributeNS("http://www.w3.org/XML/1998/namespace","xml:space","preserve"),r.appendChild(a),window[""+n]=t,window[""+n].usageCount=1,document.body.appendChild(t);var l="measureElementCount";window[""+l]?window[""+l]++:window[""+l]=1}}(),this.renderBackgroundLayer(r,e),this.renderGridLayer(r,e),this.renderDiagramLayer(r,e),this.renderHTMLLayer(r,e),this.renderPortsExpandLayer(r,e),this.renderNativeLayer(r,e),this.renderAdornerLayer(r,e),this.renderHiddenUserHandleTemplateLayer(r)},t.prototype.renderAdornerLayer=function(e,i){var r=Tt("div",{id:this.element.id+"_diagramAdornerLayer",style:"width:"+e.width+"px;height:"+e.height+"px;"+i}),s=Tt("div",{id:this.element.id+"_diagramUserHandleLayer",style:"width:"+e.width+"px;height:"+e.height+"px;"+i});s.setAttribute("class","e-userHandle-layer"),r.appendChild(s);var o=this.createSvg(this.element.id+"_diagramAdorner_svg",e.width,e.height);o.setAttribute("class","e-adorner-layer"),o.style["pointer-events"]="none",this.adornerLayer=Bi("g",{id:this.element.id+"_diagramAdorner"}),this.adornerLayer.style[" pointer-events"]="all",o.appendChild(this.adornerLayer),r.appendChild(o),this.diagramCanvas.appendChild(r);var a=Bi("g",{id:this.element.id+"_SelectorElement"});this.adornerLayer.appendChild(a),oi(o,{style:"pointer-events:none;"})},t.prototype.renderPortsExpandLayer=function(e,i){var r=this.createSvg(this.element.id+"_diagramPorts_svg",e.width,e.height);r.setAttribute("class","e-ports-expand-layer");var s=Bi("g",{id:this.element.id+"_diagramPorts",class:"e-ports-layer",style:"pointer-events: all;"});r.appendChild(s);var o=Bi("g",{id:this.element.id+"_diagramExpander",class:"e-expand-layer",style:"pointer-events: all;"});r.appendChild(o),this.diagramCanvas.appendChild(r),oi(r,{style:i})},t.prototype.renderHTMLLayer=function(e,i){this.htmlLayer=Tt("div",{id:this.element.id+"_htmlLayer",style:"width:"+e.width+"px; height:"+e.height+"px;position:absolute;top:0px;left:0px;overflow:hidden;pointer-events:none;",class:"e-html-layer"});var r=Tt("div",{id:this.element.id+"_htmlLayer_div",style:"position:absolute;top:0px;left:0px;pointer-events:all;"});this.htmlLayer.appendChild(r),this.diagramCanvas.appendChild(this.htmlLayer)},t.prototype.renderNativeLayer=function(e,i){var r=this.createSvg(this.element.id+"_nativeLayer_svg",e.width,e.height),s=Bi("g",{id:this.element.id+"_nativeLayer",style:"pointer-events:all;"});r.appendChild(s),this.diagramLayerDiv.appendChild(r),oi(r,{class:"e-native-layer",style:i})},t.prototype.createSvg=function(e,i,r){var s=document.createElementNS("http://www.w3.org/2000/svg","svg");return oi(s,{id:e,width:i,height:r}),s},t.prototype.updateBazorShape=function(){for(var e=0;e1,i=[],r={},s={},o=[],a=0,l=this.nodes;a0||b&&b.children&&b.children.length>0)&&(M=!1),S&&S.wrapper&&b&&b.wrapper&&M?this.initConnectors(r[""+h],f):i.push(r[""+h])}else b=r[y.targetID],(S=r[y.sourceID])&&S.children&&S.children.length>0||b&&b.children&&b.children.length>0?i.push(r[""+h]):this.initConnectors(r[""+h],f);else r[""+h].children?o.push(h):r[""+h].shape instanceof uT&&r[""+h].shape.activity.subProcess.processes&&r[""+h].shape.activity.subProcess.processes.length>0?s[r[""+h].id]=h:this.initNodes(r[""+h],f);if(this.bpmnModule)for(var w=0,C=this.bpmnModule.bpmnTextAnnotationConnector;w-1&&-1===r.indexOf(c)&&-1===s.indexOf(c)&&r.splice(0,0,c);-1===r.indexOf(o)&&s.push(o)}return r.concat(s)},t.prototype.addToLayer=function(e,i){var r;if(i&&(r=this.commandHandler.getObjectLayer(e.id)),(!i||!r)&&-1===this.activeLayer.objects.indexOf(e.id)&&this.activeLayer.objects.push(e.id),(e instanceof te||e instanceof de)&&("SwimLane"!==e.shape.type||e.children&&e.children.length>0)){if(e.parentId){var s=this.swimlaneZIndexTable[e.parentId],o=this.swimlaneChildTable[e.id];(s&&-1!==s||o&&-1!==o)&&(e.zIndex=this.swimlaneChildTable[e.id])}e instanceof de&&e.sourceID&&e.targetID?-1!==this.activeLayer.objects.indexOf(e.sourceID)&&-1!==this.activeLayer.objects.indexOf(e.targetID)&&this.setZIndex(r||this.activeLayer,e):this.setZIndex(r||this.activeLayer,e)}},t.prototype.updateLayer=function(e){for(var i=0,r=Object.keys(e.layers);i0)for(r=0;rs;l--)r.zIndexTable[parseInt(l.toString(),10)]=r.zIndexTable[l-1],this.nameTable[r.zIndexTable[parseInt(l.toString(),10)]]&&(this.nameTable[r.zIndexTable[parseInt(l.toString(),10)]].zIndex=l);r.zIndexTable[parseInt(a.toString(),10)]=i.id}}},t.prototype.initializeDiagramLayers=function(){for(var e=0;ethis.layers[parseInt(a.toString(),10)].zIndex&&(i=this.layers[parseInt(e.toString(),10)],this.layers[parseInt(e.toString(),10)]=this.layers[parseInt(a.toString(),10)],this.layers[parseInt(a.toString(),10)]=i);0===this.layers.length&&this.commandHandler.addLayer({id:"default_layer",visible:!0,lock:!1,objects:[],zIndex:0,objectZIndex:-1,zIndexTable:{}},null,!0),this.setActiveLayer(this.layers[this.layers.length-1].id)},t.prototype.resetTool=function(){this.eventHandler.resetTool()},t.prototype.initObjectExtend=function(e,i,r){if(r){var s=this.commandHandler.checkBoundaryConstraints(void 0,void 0,e.wrapper.bounds,!0);if("SwimLane"===e.shape.type)for(var o=0,a=Object.keys(i.zIndexTable);o0)&&this.setZIndex(i,e)),e instanceof te){if(r){if("helper"!==e.id&&(o=Zi(this.getNodeDefaults))){if((a=o(e,this))&&a.ports)for(var l=0;l0)for(l=0;l0&&!e.container||e.processId){var r=this.nameTable[e.id];if(!(this.realActions&$i.PreventScale||this.realActions&$i.PreventDrag)){if(r.offsetX&&(this.realActions&$i.EnableGroupAction||!(this.diagramActions&ee.UndoRedo||this.diagramActions&ee.ToolAction||this.diagramActions&ee.PublicMethod))){this.realActions|=$i.PreventScale;var s=r.offsetX-e.wrapper.offsetX;r.offsetX=e.wrapper.offsetX;var o=r.offsetY-e.wrapper.offsetY;r.offsetY=e.wrapper.offsetY,s+o!==0&&this.drag(r,s,o),this.realActions&=~$i.PreventScale}else r.offsetX=e.wrapper.offsetX;r.offsetY&&(this.realActions&$i.EnableGroupAction||!(this.diagramActions&ee.UndoRedo||this.diagramActions&ee.ToolAction||this.diagramActions&ee.PublicMethod))?(this.realActions|=$i.PreventScale,o=r.offsetY-e.wrapper.offsetY,r.offsetY=e.wrapper.offsetY,this.drag(r,0,o),this.realActions&=~$i.PreventScale):r.offsetY=e.wrapper.offsetY,this.diagramActions&&(r.width=e.wrapper.actualSize.width,r.height=e.wrapper.actualSize.height)}}i&&e.children&&e.children.length>0&&(void 0!==this.nameTable[e.id].width?this.scaleObject(e,this.nameTable[e.id].width,!0):this.nameTable[e.id].width=e.wrapper.actualSize.width,void 0!==this.nameTable[e.id].height?this.scaleObject(e,this.nameTable[e.id].height,!1):this.nameTable[e.id].height=e.wrapper.actualSize.height)},t.prototype.initNode=function(e,i,r){var a,p,s=e.initContainer(),o=new Ii;if(this.diagramSettings.inversedAlignment||(s.inversedAlignment=!1),s.children||(s.children=[]),e.children){s.measureChildren=!1,o.id=e.id+"group_container",o.style.fill=e.shape&&"SwimLane"===e.shape.type?e.style.fill:"none",o.style.strokeColor="none",o.horizontalAlignment="Stretch",o.verticalAlignment="Stretch",o.pivot=e.pivot,s.style=e.style,s.padding.left=e.padding.left,s.padding.right=e.padding.right,s.padding.top=e.padding.top,s.padding.bottom=e.padding.bottom,o.children=[],o.preventContainer=!0,e.container&&(o.relativeMode="Object");var l=!!(e.ports&&e.ports.length>0);if(m(e.container)&&!l&&s.children.push(o),e.container&&"Grid"===e.container.type)for(var h=0;h0&&e.wrapper.children[0]instanceof Yv){if(this.setZIndex(this.activeLayer,e),this.connectors.length>0)for(h=0;h0?i.phases.length:0,v="Horizontal"===i.orientation,y=v?i.phases.length||1:s.length+1,S=v?(i.header&&i.hasHeader?1:0)+(i.phases.length>0?1:0)+i.lanes.length:(i.header&&i.hasHeader?1:0)+i.phases.length;if(0===h&&!v&&i.lanes.length&&(S+=1),v?(a=(i.header&&i.hasHeader?1:0)+(h>0?1:0),l=0):(a=i.header&&i.hasHeader?1:0,l=h>0?1:0),s.length>0)for(o+=i.header&&i.hasHeader?i.header.height:0,p=0;pl?d.margin.left=d.margin.left-(u.bounds.left-e.bounds.left):u.children[0].children[1].actualSize.width+r>=d.margin.left&&(d.margin.left=u.children[0].children[1].actualSize.width+r),d.margin.lefta?d.margin.top=d.margin.top-(u.bounds.top-o):u.children[0].children[1].actualSize.height+r>=d.margin.top&&(d.margin.top=u.children[0].children[1].actualSize.height+r),d.margin.left0)for(o=0;o0&&this.updateChildPosition(e)},t.prototype.addBpmnAnnotationConnector=function(e,i){if(e.parentObj instanceof t||e.parentObj instanceof Rd){var r=e.shape,o=""!==r.textAnnotation.textAnnotationTarget&&this.nameTable[r.textAnnotation.textAnnotationTarget],a=o?this.nameTable[r.textAnnotation.textAnnotationTarget]:null,l=null!=a?a.wrapper:null,h=e.ports[0],c={x:0,y:0};switch(r.textAnnotation.textAnnotationDirection){case"Left":h.offset={x:0,y:.5},c.x=i.bounds.left-40,c.y=i.bounds.bottom+30;break;case"Right":h.offset={x:1,y:.5},c.x=i.bounds.right+40,c.y=i.bounds.bottom+30;break;case"Top":h.offset={x:.5,y:0},c.x=i.bounds.right+30,c.y=i.bounds.top-40;break;case"Bottom":h.offset={x:.5,y:1},c.x=i.bounds.right+30,c.y=i.bounds.bottom+40;break;default:h.offset={x:0,y:.5},c.x=i.bounds.left-40,c.y=i.bounds.bottom+30,o&&null!=i&&null!=l&&(i.bounds.left>l.bounds.right?h.offset={x:0,y:.5}:i.bounds.rightl.bounds.top?h.offset={x:.5,y:0}:i.bounds.top0&&this.updateChildPosition(r)}},t.prototype.canExecute=function(){return!0},t.prototype.updateStackProperty=function(e,i,r){e.container&&"Stack"===e.container.type&&(i.width||(i.wrapper.horizontalAlignment="Stretch",i.horizontalAlignment="Stretch"),i.height||(i.verticalAlignment="Stretch",i.wrapper.verticalAlignment="Stretch"),r&&"UmlClassifier"===e.shape.type&&(i.umlIndex=r))},t.prototype.initViews=function(){this.isLoading||(this.views.push(this.element.id),this.views[this.element.id]=this)},t.prototype.initCommands=function(){var e=this.commandManager.commands,i={copy:{execute:this.copyCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.C,keyModifiers:pt.Control}},paste:{execute:this.pasteCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.V,keyModifiers:pt.Control}},cut:{execute:this.cutCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.X,keyModifiers:pt.Control}},delete:{execute:this.removeCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Delete}},selectAll:{execute:this.selectAll.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.A,keyModifiers:pt.Control}},undo:{execute:this.undo.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Z,keyModifiers:pt.Control}},redo:{execute:this.redo.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Y,keyModifiers:pt.Control}},nudgeUp:{execute:this.nudgeCommand.bind(this,"Up"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Up},parameter:"up"},nudgeRight:{execute:this.nudgeCommand.bind(this,"Right"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Right},parameter:"right"},nudgeDown:{execute:this.nudgeCommand.bind(this,"Down"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Down},parameter:"down"},nudgeLeft:{execute:this.nudgeCommand.bind(this,"Left"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Left},parameter:"left"},startEdit:{execute:this.startEditCommad.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.F2}},endEdit:{execute:this.endEditCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Escape}},focusToNextItem:{execute:this.navigateItems.bind(this,!0),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Tab}},focusToPreviousItem:{execute:this.navigateItems.bind(this,!1),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Tab,keyModifiers:pt.Shift}},selectFocusedItem:{execute:this.startEditCommad.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Enter}},bold:{execute:this.fontStyleCommand.bind(this,"bold"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.B,keyModifiers:pt.Control}},italic:{execute:this.fontStyleCommand.bind(this,"italic"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.I,keyModifiers:pt.Control}},underline:{execute:this.fontStyleCommand.bind(this,"underline"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.U,keyModifiers:pt.Control}},duplicate:{execute:this.duplicateCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.D,keyModifiers:pt.Control}},group:{execute:this.groupCommand.bind(this,"group"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.G,keyModifiers:pt.Control}},ungroup:{execute:this.groupCommand.bind(this,"ungroup"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.U,keyModifiers:pt.Control|pt.Shift}},rotateClockwise:{execute:this.rotateCommand.bind(this,"clockwise"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.R,keyModifiers:pt.Control}},rotateAntiClockwise:{execute:this.rotateCommand.bind(this,"antiClockwise"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.L,keyModifiers:pt.Control}},flipHorizontal:{execute:this.flipCommand.bind(this,"horizontal"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.H,keyModifiers:pt.Control}},flipVertical:{execute:this.flipCommand.bind(this,"vertical"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.J,keyModifiers:pt.Control}},pointerTool:{execute:this.toolCommand.bind(this,"pointer"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number1,keyModifiers:pt.Control}},textTool:{execute:this.toolCommand.bind(this,"text"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number2,keyModifiers:pt.Control}},connectTool:{execute:this.toolCommand.bind(this,"connect"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number3,keyModifiers:pt.Control}},freeForm:{execute:this.toolCommand.bind(this,"freeForm"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number5,keyModifiers:pt.Control}},lineTool:{execute:this.toolCommand.bind(this,"line"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number6,keyModifiers:pt.Control}},rectangleTool:{execute:this.toolCommand.bind(this,"rectangle"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number8,keyModifiers:pt.Control}},ellipseTool:{execute:this.toolCommand.bind(this,"ellipse"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number9,keyModifiers:pt.Control}},zoomIn:{execute:this.zoomCommand.bind(this,"zoomIn"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Plus,keyModifiers:pt.Control}},zoomOut:{execute:this.zoomCommand.bind(this,"zoomOut"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Minus,keyModifiers:pt.Control}},shiftUp:{execute:this.shiftCommand.bind(this,"Up"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Up,keyModifiers:pt.Shift}},shiftDown:{execute:this.shiftCommand.bind(this,"Down"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Down,keyModifiers:pt.Shift}},shiftLeft:{execute:this.shiftCommand.bind(this,"Left"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Left,keyModifiers:pt.Shift}},shiftRight:{execute:this.shiftCommand.bind(this,"Right"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Right,keyModifiers:pt.Shift}},alignTextCenter:{execute:this.alignCommand.bind(this,"center"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.C,keyModifiers:pt.Control|pt.Shift}},alignTextLeft:{execute:this.alignCommand.bind(this,"right"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.L,keyModifiers:pt.Control|pt.Shift}},alignTextRight:{execute:this.alignCommand.bind(this,"left"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.R,keyModifiers:pt.Control|pt.Shift}},alignTextTop:{execute:this.alignCommand.bind(this,"top"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.E,keyModifiers:pt.Control|pt.Shift}},alignTextCenterVertical:{execute:this.alignCommand.bind(this,"centerVertical"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.M,keyModifiers:pt.Control|pt.Shift}},alignTextBottom:{execute:this.alignCommand.bind(this,"bottom"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.V,keyModifiers:pt.Control|pt.Shift}},alignJustify:{execute:this.alignCommand.bind(this,"justify"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.J,keyModifiers:pt.Control|pt.Shift}},sendToBack:{execute:this.orderCommand.bind(this,"sendToBack"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.B,keyModifiers:pt.Control|pt.Shift}},bringToFront:{execute:this.orderCommand.bind(this,"bringToFront"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.F,keyModifiers:pt.Control|pt.Shift}},sendBackward:{execute:this.orderCommand.bind(this,"sendBackward"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.BracketLeft,keyModifiers:pt.Control}},bringForward:{execute:this.orderCommand.bind(this,"bringForward"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.BracketRight,keyModifiers:pt.Control}}};this.initCommandManager(e,i)},t.prototype.overrideCommands=function(e,i){for(var r,s=0,o=Object.keys(i);se.zIndex){("HTML"===e.shape.type||"Native"===e.shape.type)&&(o="HTML"===e.shape.type?"html":"native"),s=Eoe(i,r[parseInt(a.toString(),10)].id,o);break}return s},t.prototype.updateDiagramObject=function(e,i,r){for(var s,o="domTable",a=0,l=this.views;a1&&(d=this.commandHandler.getObjectLayer(e.id)),void 0===d||d&&d.visible||r){var u=Io(this.element.id);window[""+o][s.element.id+"_diagramLayer"]||(window[""+o][s.element.id+"_diagramLayer"]=document.getElementById(s.element.id+"_diagramLayer"));var p=window[""+o][s.element.id+"_diagramLayer"];this.diagramActions&ee.Interactions&&this.updateCanupdateStyle(e.wrapper.children,!0);var f=this.getMidPoint(e);this.diagramRenderer.updateNode(e.wrapper,p,u,void 0,i?void 0:this.getZindexPosition(e,s.element.id),f,this.portCenterPoint),this.updateCanupdateStyle(e.wrapper.children,!0)}}},t.prototype.applyMarginBezier=function(e,i){i.cx=i.cx+e.margin.left,i.cx=i.cx-e.margin.right,i.cy=i.cy+e.margin.top,i.cy=i.cy-e.margin.bottom},t.prototype.getMidPoint=function(e){var i;if(e instanceof de&&"Bezier"===e.type){i=[];for(var r=this.getBezierPoints(e),s=z.getLengthFromListOfPoints(r),o=0;o0&&e.updateView(e));var s=Io(e.element.id);this.renderDiagramElements(e.diagramLayer,e.diagramRenderer,s,void 0,void 0,i);for(var o=0;o0&&this.renderBasicElement(e),!this.diagramActions||!(this.diagramActions&ee.Render)||ee.ToolAction&this.diagramActions||Ds(this)||1!==this.scroller.currentZoom?this.refreshElements(e):this.renderTimer||(this.renderTimer=setTimeout(function(){i.refreshElements(e)},40)))},t.prototype.updatePortVisibility=function(e,i,r){var s;if((e instanceof te||e instanceof de)&&(!this.drawingObject||!this.drawingObject.shape)&&to(e)){for(var a=e.ports,l=!1,h=0;h=0&&this.scroller.removeCollection.splice(l,1);var h=this.nameTable[e[parseInt(a.toString(),10)]];this.updateTextElementValue(h),this.diagramRenderer.renderElement(h.wrapper,s,o,void 0,void 0,void 0,void 0,h.zIndex)}for(var c=0;c0?this.scroller.oldCollectionObjects:void 0,b=Object.keys(S||g.zIndexTable);b.sort(function(N,T){return parseInt(""+N,10)-parseInt(""+T,10)});for(var M=0,w=b;M0?h:0)+"px",y=(this.realActions&$i.vScrollbarMoved?0:-(this.scroller.verticalOffset<0?this.scroller.verticalOffset:0))+"px"):(v="0px",y="0px"),this.realActions&$i.hScrollbarMoved&&(this.realActions=this.realActions&~$i.hScrollbarMoved),this.realActions&$i.vScrollbarMoved&&(this.realActions=this.realActions&~$i.vScrollbarMoved)):(v=(l.x<0?h:-this.scroller.horizontalOffset)+"px",y=(l.y<0?c:-this.scroller.verticalOffset)+"px"),this.diagramLayer.style.left=v,this.diagramLayer.style.top=y,A.tx=-l.x/A.scale,A.ty=-l.y/A.scale);var R=!0;if(o&&(R=!1),this.updateTextElementValue(D),this.refreshing&&D.shape.activity&&D.shape.activity.subProcess&&D.shape.activity.subProcess.processes){for(var L=0;L0){var o=s.children[0],a=o.data;(r.isBezierEditing&&this.selectedItems.connectors[0].id===r.id||"Bezier"!==r.type)&&r.getSegmentElement(r,o,"ComplexHierarchicalTree"===this.layout.type||"HierarchicalTree"===this.layout.type?this.layout.orientation:void 0,void 0,!1),o.data!==a&&(s.measure(new me),s.arrange(s.desiredSize),"SVG"===this.mode&&!e&&this.updateDiagramObject(r))}}else this.constraints&rt.Bridging&&console.warn('[WARNING] :: Module "ConnectorBridging" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.setCursor=function(e){this.diagramRenderer.setCursor(this.diagramCanvas,e)},t.prototype.clearCanvas=function(e){var i=e.contentWidth||e.diagramLayer.width/this.scroller.currentZoom,r=e.contentHeight||e.diagramLayer.height/this.scroller.currentZoom;"SVG"!==e.mode&&bo.getContext(e.diagramLayer).clearRect(0,0,i,r)},t.prototype.updateScrollOffset=function(){this.scroller.setScrollOffset(this.diagramCanvas.scrollLeft,this.diagramCanvas.scrollTop),JI(this),Ds(this)&&this.scroller.virtualizeElements()},t.prototype.setOffset=function(e,i){var r="domTable";window[""+r][this.element.id+"content"]||(window[""+r][this.element.id+"content"]=document.getElementById(this.element.id+"content"));var s=window[""+r][this.element.id+"content"];s&&(s.scrollLeft=e,s.scrollTop=i)},t.prototype.setSize=function(e,i){if(this.diagramLayer&&!this.preventDiagramUpdate){var r=qa(this);e-=r.width,i-=r.height;var s=this.spatialSearch.getPageBounds();s.x*=this.scroller.currentZoom,s.y*=this.scroller.currentZoom,s.width*=this.scroller.currentZoom,s.height*=this.scroller.currentZoom;var o="SVG"===this.mode?1:1.5,a="SVG"===this.mode?mT(this.element.id):this.diagramLayer,h="Canvas"===this.mode&&this.constraints&rt.Virtualization?this.scroller.viewPortHeight:i;a.setAttribute("width",(o*("Canvas"===this.mode&&this.constraints&rt.Virtualization?this.scroller.viewPortWidth:e)).toString()),a.setAttribute("height",(o*h).toString());var c=document.getElementById(this.element.id+"_diagramUserHandleLayer");c&&(c.style.width=e+"px",c.style.height=i+"px");var d={width:e.toString(),height:i.toString()};this.diagramLayerDiv.style.width=e+"px",this.diagramLayerDiv.style.height=i+"px",oi(FF(this.element.id),d),oi(function xoe(n){return xt(n).getElementsByClassName("e-ports-expand-layer")[0]}(this.element.id),d);var u=zl(this.element.id);oi(u,d),u.parentNode.style.width=e+"px",u.parentNode.style.height=i+"px";var p=Bd(this.element.id);oi(p,d),this.diagramRenderer.updateGrid(this.snapSettings,p,this.scroller.transform,this.rulerSettings,this.hRuler,this.vRuler),oi(IT(this.element.id),d),this.htmlLayer.style.width=e+"px",this.htmlLayer.style.height=i+"px","SVG"!==this.mode&&!Ds(this)&&this.refreshDiagramLayer(),"SVG"===this.mode&&Ds(this)&&this.scroller.virtualizeElements()}},t.prototype.transformLayers=function(){var e=this.spatialSearch.getPageBounds();e.x*=this.scroller.currentZoom,e.y*=this.scroller.currentZoom,e.width*=this.scroller.currentZoom,e.height*=this.scroller.currentZoom,this.diagramRenderer.updateGrid(this.snapSettings,Bd(this.element.id),this.scroller.transform,this.rulerSettings,this.hRuler,this.vRuler),this.diagramRenderer.transformLayers(this.scroller.transform,"SVG"===this.mode),this.diagramActions&ee.DragUsingMouse||this.updateSelector(),this.renderPageBreaks(e)},t.prototype.removePageBreaks=function(){if(this.diagramLayer){var e=_F(this.element.id);if(e&&e.childNodes)for(var i=e.childNodes.length,r=0;rthis.pageSettings.height&&(e=this.pageSettings.height,this.pageSettings.height=this.pageSettings.width,this.pageSettings.width=e):this.pageSettings.height>this.pageSettings.width&&(e=this.pageSettings.width,this.pageSettings.width=this.pageSettings.height,this.pageSettings.height=e)},t.prototype.setOverview=function(e,i){if(e)e&&(this.views.push(e.id),this.views[e.id]=e,e.renderDocument(e),e.diagramRenderer.setLayers(),e.updateView(e),this.renderNodes(e));else{for(var r=0;r1&&this.updateSelectionRectangle(),this.isProtectedOnChange=s},t.prototype.updateSelectionRectangle=function(){for(var e=dm(this.element.id),i=!1,r=0;r1&&this.updateSelectionRectangle(),this.enableServerDataBinding(e)},t.prototype.renderSelectorForAnnotation=function(e,i){this.diagramRenderer.renderResizeHandle(e.wrapper.children[0],i,e.thumbsConstraints,this.scroller.currentZoom,e.constraints,this.scroller.transform,void 0,to(e.annotation),void 0,void 0,e.handleSize)},t.prototype.drawSelectionRectangle=function(e,i,r,s){this.clearSelectorLayer(),this.diagramRenderer.drawSelectionRectangle(e,i,r,s,this.adornerLayer,this.scroller.transform)},t.prototype.renderHighlighter=function(e){var i=zl(this.element.id);this.diagramRenderer.renderHighlighter(e,i,this.scroller.transform)},t.prototype.clearHighlighter=function(){var e=zl(this.element.id),i=e.getElementById(e.id+"_highlighter");i&&i.parentNode.removeChild(i)},t.prototype.getNodesConnectors=function(e){for(var i=0;i0;l--)(a=o[l-1]).parentNode.removeChild(a);if(!ce()){var h=ST(this.element.id).childNodes;for(r=h.length;r>0;r--)h[r-1].parentNode.removeChild(h[r-1])}}},t.prototype.getWrapper=function(e,i){var r;i=e.id+"_"+i;for(var s=e instanceof Ii?e:this.getPortContainer(this.nameTable[e.id]),o=0;o0&&this.applyStyle(e,a=r.annotations)}for(i=0;i0){var a=this.selectedItems.connectors[parseInt(i.toString(),10)].annotations;this.applyStyle(e,a)}},t.prototype.applyStyle=function(e,i){for(var r=0;r0)for(var i=0;i0?r[0].zIndex+(e?1:-1):e?0:this.nodes.length+this.connectors.length-1)<0?i=this.nodes.length+this.connectors.length-1:i===this.nodes.length+this.connectors.length&&(i=0);for(var s=0;s0)for(var s=void 0,o=r.children.length-1;o>=0;o--){var a=r.children[parseInt(o.toString(),10)];i.length>0&&-1!==i.indexOf(a.id.split("_groupElement")[0])&&(r.parentNode.insertBefore(a,s||r),s=a)}r&&r.parentNode.removeChild(r)},t.prototype.deleteGroup=function(e){var r=[];e.children&&(r=this.commandHandler.getChildren(e,[])),this.UpdateBlazorDiagramModelCollection(e);for(var s=0,o=r;s0)for(var xe=0;xe0)if("Path"===t.shape.type&&void 0!==n.shape.data)t.wrapper.children[0].data=n.shape.data;else if("Text"===t.shape.type&&void 0!==n.shape.content)t.wrapper.children[0].content=n.shape.content;else if("Image"===t.shape.type&&void 0!==n.shape.source)t.wrapper.children[0].source=n.shape.source;else if("Native"===t.shape.type){for(var r=void 0,s=0;s-1)&&(this.diagramActions&ee.PreventZIndexOnDragging?this.updateDiagramObject(e,!0):this.updateDiagramObject(e)),!s&&d&&(this.lineRoutingModule&&this.diagramActions&&this.constraints&rt.LineRouting&&"helper"!==e.id?this.diagramActions&ee.ToolAction||this.lineRoutingModule.renderVirtualRegion(this,!0):this.diagramActions&&this.constraints&rt.LineRouting&&"helper"!==e.id&&console.warn('[WARNING] :: Module "LineRouting" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),this.updateConnectorEdges(e),"helper"!==e.id&&!(this.diagramActions&ee.ToolAction))))for(var ya=this.spatialSearch.findObjects(e.wrapper.outerBounds),Mo=0;Moe?Math.abs(r-e):Math.abs(e-r),d=s>i?Math.abs(s-i):Math.abs(i-s);(0===c&&0===d||Number.isNaN(c)&&Number.isNaN(d))&&o.laneMargin&&(u=o.margin.left-o.laneMargin.left,p=o.margin.top-o.laneMargin.top);var f=o.width,g=o.height,v=new Ne(0,0,0,0);if(0!==f&&0!==g&&(v=new Ne((0!==r?r:o.offsetX)-f/2,(0!==s?s:o.offsetY)-g/2,f,g)),h){var y=l,b=this.selectedItems.nodes?this.selectedItems.nodes[0]:void 0;if(""!==y.textAnnotation.textAnnotationTarget&&this.nameTable[y.textAnnotation.textAnnotationTarget])if(""===o.parentId||b&&b.shape&&"TextAnnotation"===b.shape.shape){if("Auto"===y.textAnnotation.textAnnotationDirection&&a.children[0]instanceof Ii&&a.children[0].children[0]instanceof Ke){var w=a.children[0],C=document.getElementById(w.id+"_groupElement"),D=document.getElementById(w.children[0].id+"_groupElement");C.removeChild(D),w.children.splice(0,1),this.isProtectedOnChange=!0,this.bpmnModule.setAnnotationPath(v,w,o,y,y.textAnnotation.textAnnotationDirection,this),this.isProtectedOnChange=!1}}else this.isPositionUndo=!0,this.updateTextAnnotationInSwimlane(o,o),this.isPositionUndo=!1;else o.inEdges.length>0&&(x=this.nameTable[""+o.inEdges[0]])&&x.isBpmnAnnotationConnector&&(x.sourcePoint={x:r>e?x.sourcePoint.x+c:x.sourcePoint.x-c,y:s>i?x.sourcePoint.y+d:x.sourcePoint.y-d});this.nodePropertyChange(o,{},R={ports:[{offset:o.ports[0].offset}]})}else for(var L=0,O=o.outEdges;Le?T.offsetX+c:T.offsetX-c,T.offsetY=s>i?T.offsetY+d:T.offsetY-d,R={offsetX:T.offsetX,offsetY:T.offsetY}),this.nodePropertyChange(T,P,R)}}}},t.prototype.updatePorts=function(e,i){if(e&&e.ports.length>0)for(var r=0,s=Object.keys(e.ports);r0)for(var i=0;i0)for(var r=0;r0&&void 0===r.segments&&(e.segments=[]),void 0!==r.shape&&void 0!==e.shape&&e.shape&&"Bpmn"===e.shape.type&&this.bpmnModule&&this.bpmnModule.updateBPMNConnector(e,i,r,this),void 0!==e.constraints?(this.updateThumbConstraints(this.selectedItems.connectors,this.selectedItems),s=!0):s},t.prototype.connectorPropertyChange=function(e,i,r,s,o){if(this.canEnableBlazorObject){var a=$(e);this.insertValue(a,!1)}var d,u,p,f,l=e.wrapper.bounds,h=!1,c=[];if(h=this.connectorProprtyChangeExtend(e,i,r,h),void 0!==r.visible&&this.updateElementVisibility(e.wrapper,e,e.visible),void 0!==r.sourcePoint||void 0!==r.targetPoint||void 0!==r.sourceID||void 0!==r.targetID||void 0!==r.targetPadding||void 0!==r.sourcePortID||void 0!==r.targetPortID||void 0!==r.sourcePadding||void 0!==r.type||void 0!==r.segments||void 0!==r.flip){if(void 0!==r.sourceID&&r.sourceID!==i.sourceID||r.sourcePortID){if(u=this.findInOutConnectPorts(g=this.nameTable[e.sourceID],!1),(!g||kh(g)||""!==e.sourcePortID&&xd(u))&&(e.sourceWrapper=g?this.getEndNodeWrapper(g,e,!0):void 0,e.sourcePortID&&void 0===r.sourcePortID&&(e.sourcePortWrapper=g?this.getWrapper(g.wrapper,e.sourcePortID):void 0),this.removePortEdges(this.nameTable[i.sourceID]||g,i.sourcePortID||e.sourcePortID,e.id,!1)),void 0!==r.sourceID&&void 0!==i.sourceID&&""!==i.sourceID){var v=this.nameTable[i.sourceID];void 0!==v&&v.outEdges&&-1!==v.outEdges.indexOf(e.id)&&im(v.outEdges,e.id)}this.updateEdges(e)}if(void 0!==r.targetID&&r.targetID!==i.targetID){if(d=this.findInOutConnectPorts(y=this.nameTable[r.targetID],!0),(!y||da(y)||""!==e.targetPortID&&Oh(d))&&(e.targetWrapper=y?this.getEndNodeWrapper(y,e,!1):void 0,e.targetPortID&&void 0===r.targetPortID&&(e.targetPortWrapper=y?this.getWrapper(y.wrapper,e.targetPortID):void 0),this.removePortEdges(this.nameTable[i.targetID]||y,i.targetPortID||e.targetPortID,e.id,!0)),void 0!==i&&void 0!==i.targetID&&""!==i.targetID){var S=this.nameTable[i.targetID];void 0!==S&&S.inEdges&&-1!==S.inEdges.indexOf(e.id)&&im(S.inEdges,e.id)}this.updateEdges(e)}var g,y;void 0!==r.sourcePortID&&r.sourcePortID!==i.sourcePortID&&(e.sourceID&&this.nameTable[e.sourceID]&&(p=this.nameTable[e.sourceID].wrapper),!(g=this.nameTable[e.sourceID])||kh(g)||""!==e.sourcePortID&&xd(u)?e.sourcePortWrapper=p?this.getWrapper(p,r.sourcePortID):void 0:""===e.sourcePortID&&!kh(g)&&(e.sourcePortWrapper=void 0)),void 0!==r.targetPortID&&r.targetPortID!==i.targetPortID&&(e.targetID&&this.nameTable[e.targetID]&&(f=this.nameTable[e.targetID].wrapper),!(y=this.nameTable[e.targetID])||da(y)||""!==e.targetPortID&&Oh(d)?e.targetPortWrapper=f?this.getWrapper(f,r.targetPortID):void 0:""===e.targetPortID&&!da(y)&&(e.targetPortWrapper=void 0)),void 0!==r.flip&&(e.flip=r.flip,EF(e)),"Orthogonal"===e.type&&this.lineRoutingModule&&this.diagramActions&&this.constraints&rt.LineRouting&&!(this.diagramActions&ee.ToolAction)&&"ComplexHierarchicalTree"!==this.layout.type&&(this.lineRoutingModule.renderVirtualRegion(this,!0),e.sourceID!==e.targetID&&e.segments.length>1&&this.lineRoutingModule.refreshConnectorSegments(this,e,!1)),c=this.getPoints(e)}void 0!==r.style&&Rh(r.style,e.wrapper.children[0]),(c.length>0||void 0!==r.sourceDecorator||void 0!==r.targetDecorator&&function qse(n){return-1!==n.indexOf("shape")||-1!==n.indexOf("pathData")||-1!==n.indexOf("width")||-1!==n.indexOf("height")}(Object.keys(r.targetDecorator))||void 0!==r.cornerRadius)&&(Kp(e,c.length>0?c:e.intermediatePoints,this.diagramActions),void 0!==r.type&&(h=!0),c.length>0&&(e.wrapper.measure(new me(e.wrapper.width,e.wrapper.height)),e.wrapper.arrange(e.wrapper.desiredSize),this.updateConnectorAnnotation(e),this.updateConnectorPort(e),this.updateConnectorfixedUserHandles(e),this.updateObject(e,i,r))),(r.sourcePoint||r.targetPoint||r.segments)&&this.diagramActions===ee.Render&&(h=!0),"Bpmn"===e.shape.type&&"Default"===e.shape.sequence&&"Sequence"===e.shape.flow&&this.commandHandler.updatePathElementOffset(e),s||this.updateBridging(),this.updateAnnotations(r,e),this.updateConnectorPorts(r,e),this.updatefixedUserHandle(r,e),e.wrapper.measure(new me(e.wrapper.width,e.wrapper.height)),e.wrapper.arrange(e.wrapper.desiredSize),!1===l.equals(l,e.wrapper.bounds)&&(this.updateQuad(e),"Drag"!==this.eventHandler.currentAction&&this.updateGroupSize(e)),!0===h&&this.checkSelectedItem(e)&&(!(this.diagramActions&ee.ToolAction)||this.diagramActions&ee.UndoRedo)&&this.updateSelector(),this.preventConnectorsUpdate||(!Ds(this)||Ds(this)&&this.scroller.oldCollectionObjects.indexOf(e.id)>-1)&&(this.diagramActions&ee.PreventZIndexOnDragging?this.updateDiagramObject(e,!0):this.updateDiagramObject(e)),this.updateConnectorEdges(e),this.diagramActions&&"New"!==e.status&&(e.status="Update"),this.triggerPropertyChange(o,e,i,r)},t.prototype.removePortEdges=function(e,i,r,s){if(e)for(var o=0;o0&&e.id===s[s.length-1].id&&(r=!0),r},t.prototype.updateDiagramContainerVisibility=function(e,i){if(e instanceof Cs)for(var r=0;r>"),r instanceof Jn&&this.updateAnnotationWrapper(r,s,o,a)),void 0!==e.template&&(r.content=e.template,this.updateAnnotationWrapper(r,s,o,a))},t.prototype.updateAnnotationWrapper=function(e,i,r,s){for(var o=0,a=this.views;o=0&&this.nodes.splice(s,1),delete this.nameTable[""+r]}var o=this.nodes.indexOf(this.nameTable[this.currentSymbol.id]);o>=0&&this.nodes.splice(o,1)}},t.prototype.selectDragedNode=function(e,i,r){this.currentSymbol=e,"SVG"!==this.mode&&this.refreshDiagramLayer(),this.commandHandler.oldSelectedObjects=nm(this),this.commandHandler.select(e),this.eventHandler.mouseDown(i.event),this.eventHandler.mouseMove(i.event,i),this.preventDiagramUpdate=!1,this.updatePage(),r.style.opacity="0"},t.prototype.initDroppables=function(){var s,o,e=this,i={},r={},a="selectedSymbols";this.droppable=new lR(this.element);var l=5;this.droppable.over=function(h){if(e.rulerSettings.showRulers){var c=document.getElementById(e.element.id+"_vRuler"),d=parseFloat(c.style.width);l=d+1}if(0===e.previousSelectedObjects.length&&!e.currentSymbol&&(e.previousSelectedObjects=e.commandHandler.getSelectedObject()),e.commandHandler.PreventConnectorSplit=!0,e.currentSymbol)h.event.touches&&h.event.touches.length&&e.eventHandler.mouseMove(h.event,h.event.touches);else{var u=null;if(!h.dragData&&"drag"===h.name){var p=document.getElementsByClassName("e-dragclone")[0];p&&(u=p)}if(h.dragData||u){var f=void 0,g=void 0;document.getElementById(e.element.id+"content").focus();var v=e.eventHandler.getMousePosition(h.event),y=void 0,S=u||h.dragData.helper,b=S.getAttribute("paletteId"),M=void 0,w=void 0,C=void 0,D=void 0;if(!b&&h.dragData){e.triggerEvent(Ce.dragEnter,A={source:null,element:f,cancel:!1,diagram:e,dragData:h.dragData.draggedElement.ej2_instances[0].dragData,dragItem:f});var x=void 0,R=void 0;if(A.dragItem){if(A.dragItem.sourcePoint&&A.dragItem.targetPoint?R=new de(e,"connectors",A.dragItem,!0):x=new te(e,"nodes",A.dragItem,!0),e.initObject(f=x||R,void 0,void 0,!0),e.enterObject=f,e.enterTable=r,f instanceof te)x.offsetX=v.x+5+x.width*x.pivot.x,x.offsetY=v.y+x.height*x.pivot.y;else if(f instanceof de){var L=Ne.toBounds([f.sourcePoint,f.targetPoint]),O=v.x-L.left,N=v.y-L.top;f.sourcePoint.x+=O,f.sourcePoint.y+=N,f.targetPoint.x+=O,f.targetPoint.y+=N}e.preventDiagramUpdate=!0,e.currentSymbol=f,"SVG"!==e.mode&&e.refreshDiagramLayer(),e.selectDragedNode(f,h,S),delete e.enterObject,delete e.enterTable,e.droppable[""+a]=S,e.allowServerDataBinding=!0}}if(b){var T=document.getElementById(b).ej2_instances[0];if(e.droppable.sourceElement=T,T){var B=T[""+a];e.allowServerDataBinding=!1,y=$(T[""+a]),i=T.childTable;var j=B.wrapper.children[0].children[0];if(D=function $se(n,t,e){var i=AF(n,t,e,"width"),r=AF(n,t,e,"height");return new me(i,r)}(T,y,j),T[""+a]instanceof te){"TextAnnotation"===B.shape.shape?(y.offsetX=v.x+11+D.width*y.pivot.x,y.offsetY=v.y+11+D.height*y.pivot.y):(y.offsetX=v.x+5+D.width*y.pivot.x,y.offsetY=v.y+D.height*y.pivot.y),"Bpmn"===(x=new te(e,"nodes",y,!0)).shape.type&&x.shape.activity.subProcess.processes&&x.shape.activity.subProcess.processes.length&&(x.shape.activity.subProcess.processes=[]),w=x.previewSize,C=T.symbolDragSize;var Q=T.symbolPreview;if(x.width=(M=x.dragSize).width||C.width||w.width||Q.width||x.width,x.height=M.height||C.height||w.height||Q.height||x.height,"SwimLane"===x.shape.type){if(e.diagramActions|=ee.PreventHistory,x.shape.isLane){x.children=[],s={id:"header"+Qe()},"Horizontal"===x.shape.orientation?(s.width=x.shape.lanes[0].header.width,s.height=x.shape.lanes[0].height):(s.width=x.shape.lanes[0].width,s.height=x.shape.lanes[0].header.height),s.style=x.shape.lanes[0].header.style,s.offsetX=v.x+l+s.width/2,s.offsetY=v.y+s.height/2,e.diagramActions|=ee.PreventCollectionChangeOnDragOver,s=e.add(s),o={id:"body"+Qe()},"Horizontal"===x.shape.orientation?(o.width=x.shape.lanes[0].width-s.width,o.height=x.shape.lanes[0].height,o.offsetX=v.x+l+(x.shape.lanes[0].header.width+o.width/2),o.offsetY=v.y+o.height/2):(o.width=x.shape.lanes[0].width,o.height=x.shape.lanes[0].height-s.height,o.offsetX=v.x+l+o.width/2,o.offsetY=v.y+(x.shape.lanes[0].header.height+o.height/2)),o.style=x.shape.lanes[0].style,o=e.add(o);var oe={id:"group"+Qe(),children:[s.id,o.id]};oe.shape=x.shape,oe.width=x.shape.lanes[0].width,oe.height=x.shape.lanes[0].height,oe.previewSize=x.previewSize,oe.dragSize=x.dragSize,oe.addInfo=x.addInfo,x=e.add(oe),e.diagramActions&=~ee.PreventCollectionChangeOnDragOver}e.diagramActions&=~ee.PreventHistory}if(x.shape.isPhase&&((g="Horizontal"===x.shape.orientation)?(x.offsetX=v.x+l+(x.width||j.actualSize.width)/2,x.offsetY=v.y,x.shape.data="M20,"+x.height/2+" L"+(x.width-20)+","+x.height/2+"z",x.height=1):(x.offsetX=v.x+5,x.offsetY=v.y+(x.height||j.actualSize.height)/2,x.shape.data="M"+x.width/2+",20 L"+x.width/2+","+(x.height-20)+"z",x.width=1)),"UmlClassifier"===x.shape.type&&(x.children=x.width=x.height=void 0,y.children=void 0,"Class"===x.shape.classifier&&x.shape.classShape.methods.length<=0&&x.shape.classShape.attributes.length<=0&&(x.shape.classShape.attributes=[{name:"Name",type:"Type",style:{}}]),"Enumeration"===x.shape.classifier&&x.shape.enumerationShape.members.length<=0&&(x.shape.enumerationShape.members=[{name:"Name"}]),"Interface"===x.shape.classifier&&x.shape.interfaceShape.methods.length<=0&&x.shape.interfaceShape.attributes.length<=0&&(x.shape.interfaceShape.attributes=[{name:"Name",type:"Type",style:{}}])),f=x,y.children){var ue=y;r=e.getChildren(ue,{},i),rT(ue,-ue.offsetX,-ue.offsetY,r,!0,e)}}else if(T[""+a]instanceof de){f=new de(e,"connectors",y,!0);var Me=Ne.toBounds([f.sourcePoint,f.targetPoint]),De=v.x-Me.left,xe=v.y-Me.top;f.sourcePoint.x+=De,f.sourcePoint.y+=xe,f.targetPoint.x+=De,f.targetPoint.y+=xe}f.shape.isLane||(f.id+=Qe());var A={source:T,element:f,cancel:!1,diagram:e,dragData:null,dragItem:f};if(e.enterObject=f,e.enterTable=r,e.triggerEvent(Ce.dragEnter,A),f instanceof te&&"SwimLane"===f.shape.type&&f.shape.isLane){var Ie=A.element,Ve=Ie.shape.lanes[0];g="Horizontal"===Ie.shape.orientation;var ot=e.nameTable[f.children[0]],$e=e.nameTable[f.children[1]];w=f.previewSize,C=T.symbolDragSize,Ve.width=(M=f.dragSize).width||C.width||w.width||Ve.width,Ve.height=M.height||C.height||w.height||Ve.height,g?(s.width=Ve.header.width,s.height=Ve.height,o.width=Ve.width-s.width,o.height=Ve.height,o.offsetX=v.x+l+(Ve.header.width+$e.width/2),o.offsetY=v.y+$e.height/2):(s.width=Ve.width,s.height=Ve.header.height,o.width=Ve.width,o.height=Ve.height-s.height,o.offsetX=v.x+l+$e.width/2,o.offsetY=v.y+(Ve.header.height+$e.height/2)),s.offsetX=v.x+l+ot.width/2,s.offsetY=v.y+ot.height/2,f.width=Ve.width,f.height=Ve.height}if(f instanceof te&&f.shape.isPhase&&(g?f.height=1:f.width=1),!e.activeLayer.lock&&!A.cancel){if(e.preventDiagramUpdate=!0,f.children&&e.findChild(f,r),e.preventDiagramUpdate=!0,f.zIndex!==Number.MIN_VALUE&&(f.zIndex=Number.MIN_VALUE),e.initObject(f,void 0,void 0,!0),e.bpmnModule)for(var Mi=0;Mi0&&(S.segments=[]),d=this.add(S,!0)),(S||d)&&(Uv(this)||jv(this))&&this.select([this.nameTable[S[""+b]]],!1,this.previousSelectedObjects),y.target&&y.target instanceof de&&!0===this.enableConnectorSplit&&this.nameTable[S[""+b]]instanceof te&&(this.commandHandler.connectorSplit(this.nameTable[S[""+b]],y.target),this.commandHandler.PreventConnectorSplit=!1))),this.protectPropertyChange(!1),v=this.nameTable[S[""+b]],S.hasTarget&&(S.nodeId=S.hasTarget,this.remove(S)),this.bpmnModule&&v instanceof te&&S.processId&&(v.processId=S.processId,this.bpmnModule.dropBPMNchild(this.nameTable[v.processId],v,this)),y.cancel||this.endGroupAction(),"SVG"!==this.mode&&this.refreshDiagramLayer(),delete this.droppable[""+c]):(this.triggerEvent(Ce.drop,y={source:h.droppedElement,element:void 0,target:this.eventHandler.hoverNode||this.eventHandler.lastObjectUnderMouse||this,cancel:!1,position:void 0}),S=void 0,b="id"),this.droppable[M="selectedSymbols"]&&this.droppable[""+M].parentNode)gt(this.droppable[""+M]);else for(w=document.getElementsByClassName("e-dragclone"),C=0;C0)for(var p=0;p1),e.previousSelectedObject=null}}},t.prototype.getDropEventArgs=function(e){if(this.eventHandler.lastObjectUnderMouse||this.eventHandler.hoverNode){var i=this.eventHandler.lastObjectUnderMouse||this.eventHandler.hoverNode;e.target=fs(i)===de?{connector:i}:{node:i}}else e.target.diagramId=this.element.id},t.prototype.removeChildInNodes=function(e){if(e){if(e.children)for(var i=0;i1){var l=2;if(e.children&&e.children.length>0)for(;e.children.indexOf(i.objects[s-l])>-1;)l++;this.commandHandler.moveSvgNode(e.id,i.objects[s-l]),this.commandHandler.moveSvgNode(i.objects[s-l],e.id)}else if(o){var h=this.commandHandler.getLayer(this.layerZIndexTable[o.zIndex]).objects[0];h?(this.commandHandler.moveSvgNode(e.id,h),this.commandHandler.updateNativeNodeIndex(e.id,h)):this.moveObjectsUp(e,i)}else this.moveObjectsUp(e,i)},t.prototype.moveObjectsUp=function(e,i){for(var r,s=this.layers.length-1;s>=0;s--)if(r=this.layers[parseInt(s.toString(),10)],i.id!==r.id){var o=this.commandHandler.getLayer(this.layerZIndexTable[r.zIndex]).objects[r.objects.length-1];if(o){this.commandHandler.moveSvgNode(e.id,o),this.commandHandler.moveSvgNode(o,e.id);break}}},t.prototype.insertData=function(e){return this.crudOperation(e,"create",this.getNewUpdateNodes("New"))},t.prototype.updateData=function(e){return this.crudOperation(e,"update",this.getNewUpdateNodes("Update"))},t.prototype.removeData=function(e){return this.crudOperation(e,"destroy",this.getDeletedNodes())},t.prototype.crudOperation=function(e,i,r){if(e){var s=this.parameterMap(e,!(e instanceof de));if(s){var o=e instanceof de?this.dataSourceSettings.connectionDataSource.crudAction[""+i]:this.dataSourceSettings.crudAction[""+i];this.raiseAjaxPost(JSON.stringify(s),o)}return s}var a=r;return this.processCrudCollection(a,this.dataSourceSettings.crudAction[""+i],this.dataSourceSettings.connectionDataSource.crudAction[""+i]),a},t.prototype.processCrudCollection=function(e,i,r){if(e.nodes){var s=[],o=void 0;for(o=0;o0&&this.raiseAjaxPost(JSON.stringify(s),i)}if(e.connectors){for(s=[],o=void 0,o=0;o0&&this.raiseAjaxPost(JSON.stringify(s),r)}},t.prototype.parameterMap=function(e,i){var s,r={},o=i?this.dataSourceSettings:this.dataSourceSettings.connectionDataSource;if(o.id&&(r[o.id]=e.id),o.sourcePointX&&o.sourcePointY&&(r[o.sourcePointX]=e.sourcePoint.x,r[o.sourcePointY]=e.sourcePoint.y),o.targetPointX&&o.targetPointY&&(r[o.targetPointX]=e.targetPoint.x,r[o.targetPointY]=e.targetPoint.y),o.sourceID&&(r[o.sourceID]=e.sourceID),o.targetID&&(r[o.targetID]=e.targetID),o.crudAction&&o.crudAction.customFields&&o.crudAction.customFields.length>0)for(s=0;s{class n extends ch{constructor(e){super(),this.viewContainerRef=e,gl("currentInstance",this,this.viewContainerRef),this.registerEvents($ae),this.directivePropList=qae}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-layer"]],inputs:{addInfo:"addInfo",id:"id",lock:"lock",objects:"objects",visible:"visible",zIndex:"zIndex"},features:[yn]}),n})(),Jae=(()=>{class n extends dh{constructor(){super("layers")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-layers"]],contentQueries:function(e,i,r){if(1&e&&dn(r,Zae,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),Kae=["action","cursor"],ele=[],tle=(()=>{class n extends ch{constructor(e){super(),this.viewContainerRef=e,gl("currentInstance",this,this.viewContainerRef),this.registerEvents(ele),this.directivePropList=Kae}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-cursormap"]],inputs:{action:"action",cursor:"cursor"},features:[yn]}),n})(),ile=(()=>{class n extends dh{constructor(){super("customcursor")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-cursormaps"]],contentQueries:function(e,i,r){if(1&e&&dn(r,tle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),rle=["alignment","cornerRadius","displacement","fill","handleStrokeColor","handleStrokeWidth","height","iconStrokeColor","iconStrokeWidth","id","offset","padding","pathData","tooltip","visibility","width"],nle=[],sle=(()=>{class n extends ch{constructor(e){super(),this.viewContainerRef=e,gl("currentInstance",this,this.viewContainerRef),this.registerEvents(nle),this.directivePropList=rle}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-connector-fixeduserhandle"]],inputs:{alignment:"alignment",cornerRadius:"cornerRadius",displacement:"displacement",fill:"fill",handleStrokeColor:"handleStrokeColor",handleStrokeWidth:"handleStrokeWidth",height:"height",iconStrokeColor:"iconStrokeColor",iconStrokeWidth:"iconStrokeWidth",id:"id",offset:"offset",padding:"padding",pathData:"pathData",tooltip:"tooltip",visibility:"visibility",width:"width"},features:[yn]}),n})(),ole=(()=>{class n extends dh{constructor(){super("fixeduserhandles")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-connector-fixeduserhandles"]],contentQueries:function(e,i,r){if(1&e&&dn(r,sle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),ale=["addInfo","alignment","annotationType","constraints","content","displacement","dragLimit","height","horizontalAlignment","hyperlink","id","margin","offset","rotateAngle","rotationReference","segmentAngle","style","template","tooltip","type","verticalAlignment","visibility","width"],lle=[],hle=(()=>{class n extends ch{constructor(e){super(),this.viewContainerRef=e,gl("currentInstance",this,this.viewContainerRef),this.registerEvents(lle),this.directivePropList=ale}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-connector-annotation"]],inputs:{addInfo:"addInfo",alignment:"alignment",annotationType:"annotationType",constraints:"constraints",content:"content",displacement:"displacement",dragLimit:"dragLimit",height:"height",horizontalAlignment:"horizontalAlignment",hyperlink:"hyperlink",id:"id",margin:"margin",offset:"offset",rotateAngle:"rotateAngle",rotationReference:"rotationReference",segmentAngle:"segmentAngle",style:"style",template:"template",tooltip:"tooltip",type:"type",verticalAlignment:"verticalAlignment",visibility:"visibility",width:"width"},features:[yn]}),n})(),cle=(()=>{class n extends dh{constructor(){super("annotations")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-connector-annotations"]],contentQueries:function(e,i,r){if(1&e&&dn(r,hle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),dle=["addInfo","allowNodeOverlap","annotations","bezierSettings","bridgeSpace","connectionPadding","connectorSpacing","constraints","cornerRadius","dragSize","excludeFromLayout","fixedUserHandles","flip","flipMode","hitPadding","id","margin","maxSegmentThumb","ports","previewSize","segmentThumbShape","segmentThumbSize","segments","shape","sourceDecorator","sourceID","sourcePadding","sourcePoint","sourcePortID","style","symbolInfo","targetDecorator","targetID","targetPadding","targetPoint","targetPortID","tooltip","type","visible","wrapper","zIndex"],ule=[],ple=(()=>{class n extends ch{constructor(e){super(),this.viewContainerRef=e,this.tags=["fixedUserHandles","annotations"],gl("currentInstance",this,this.viewContainerRef),this.registerEvents(ule),this.directivePropList=dle}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-connector"]],contentQueries:function(e,i,r){if(1&e&&(dn(r,ole,5),dn(r,cle,5)),2&e){let s;Kr(s=en())&&(i.childFixedUserHandles=s.first),Kr(s=en())&&(i.childAnnotations=s.first)}},inputs:{addInfo:"addInfo",allowNodeOverlap:"allowNodeOverlap",annotations:"annotations",bezierSettings:"bezierSettings",bridgeSpace:"bridgeSpace",connectionPadding:"connectionPadding",connectorSpacing:"connectorSpacing",constraints:"constraints",cornerRadius:"cornerRadius",dragSize:"dragSize",excludeFromLayout:"excludeFromLayout",fixedUserHandles:"fixedUserHandles",flip:"flip",flipMode:"flipMode",hitPadding:"hitPadding",id:"id",margin:"margin",maxSegmentThumb:"maxSegmentThumb",ports:"ports",previewSize:"previewSize",segmentThumbShape:"segmentThumbShape",segmentThumbSize:"segmentThumbSize",segments:"segments",shape:"shape",sourceDecorator:"sourceDecorator",sourceID:"sourceID",sourcePadding:"sourcePadding",sourcePoint:"sourcePoint",sourcePortID:"sourcePortID",style:"style",symbolInfo:"symbolInfo",targetDecorator:"targetDecorator",targetID:"targetID",targetPadding:"targetPadding",targetPoint:"targetPoint",targetPortID:"targetPortID",tooltip:"tooltip",type:"type",visible:"visible",wrapper:"wrapper",zIndex:"zIndex"},features:[yn]}),n})(),fle=(()=>{class n extends dh{constructor(){super("connectors")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-connectors"]],contentQueries:function(e,i,r){if(1&e&&dn(r,ple,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),gle=["cornerRadius","fill","handleStrokeColor","handleStrokeWidth","height","iconStrokeColor","iconStrokeWidth","id","margin","offset","padding","pathData","tooltip","visibility","width"],vle=[],mle=(()=>{class n extends ch{constructor(e){super(),this.viewContainerRef=e,gl("currentInstance",this,this.viewContainerRef),this.registerEvents(vle),this.directivePropList=gle}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-node-fixeduserhandle"]],inputs:{cornerRadius:"cornerRadius",fill:"fill",handleStrokeColor:"handleStrokeColor",handleStrokeWidth:"handleStrokeWidth",height:"height",iconStrokeColor:"iconStrokeColor",iconStrokeWidth:"iconStrokeWidth",id:"id",margin:"margin",offset:"offset",padding:"padding",pathData:"pathData",tooltip:"tooltip",visibility:"visibility",width:"width"},features:[yn]}),n})(),yle=(()=>{class n extends dh{constructor(){super("fixeduserhandles")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-node-fixeduserhandles"]],contentQueries:function(e,i,r){if(1&e&&dn(r,mle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),Sle=["addInfo","annotationType","constraints","content","dragLimit","height","horizontalAlignment","hyperlink","id","margin","offset","rotateAngle","rotationReference","style","template","tooltip","type","verticalAlignment","visibility","width"],Ile=[],v_=(()=>{class n extends ch{constructor(e){super(),this.viewContainerRef=e,gl("currentInstance",this,this.viewContainerRef),this.registerEvents(Ile),this.directivePropList=Sle}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-node-annotation"]],inputs:{addInfo:"addInfo",annotationType:"annotationType",constraints:"constraints",content:"content",dragLimit:"dragLimit",height:"height",horizontalAlignment:"horizontalAlignment",hyperlink:"hyperlink",id:"id",margin:"margin",offset:"offset",rotateAngle:"rotateAngle",rotationReference:"rotationReference",style:"style",template:"template",tooltip:"tooltip",type:"type",verticalAlignment:"verticalAlignment",visibility:"visibility",width:"width"},features:[yn]}),n})(),m_=(()=>{class n extends dh{constructor(){super("annotations")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-node-annotations"]],contentQueries:function(e,i,r){if(1&e&&dn(r,v_,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),ble=["addInfo","connectionDirection","constraints","height","horizontalAlignment","id","inEdges","margin","offset","outEdges","pathData","shape","style","tooltip","verticalAlignment","visibility","width"],Mle=[],wle=(()=>{class n extends ch{constructor(e){super(),this.viewContainerRef=e,gl("currentInstance",this,this.viewContainerRef),this.registerEvents(Mle),this.directivePropList=ble}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-node-port"]],inputs:{addInfo:"addInfo",connectionDirection:"connectionDirection",constraints:"constraints",height:"height",horizontalAlignment:"horizontalAlignment",id:"id",inEdges:"inEdges",margin:"margin",offset:"offset",outEdges:"outEdges",pathData:"pathData",shape:"shape",style:"style",tooltip:"tooltip",verticalAlignment:"verticalAlignment",visibility:"visibility",width:"width"},features:[yn]}),n})(),Cle=(()=>{class n extends dh{constructor(){super("ports")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-node-ports"]],contentQueries:function(e,i,r){if(1&e&&dn(r,wle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),Ele=["addInfo","annotations","backgroundColor","borderColor","borderWidth","branch","children","collapseIcon","columnIndex","columnSpan","columns","constraints","container","data","dragSize","excludeFromLayout","expandIcon","fixedUserHandles","flip","flipMode","height","horizontalAlignment","id","isExpanded","layoutInfo","margin","maxHeight","maxWidth","minHeight","minWidth","offsetX","offsetY","padding","pivot","ports","previewSize","rotateAngle","rowIndex","rowSpan","rows","shadow","shape","style","symbolInfo","tooltip","verticalAlignment","visible","width","wrapper","zIndex"],Dle=[],y_=(()=>{class n extends ch{constructor(e){super(),this.viewContainerRef=e,this.tags=["fixedUserHandles","annotations","ports"],gl("currentInstance",this,this.viewContainerRef),this.registerEvents(Dle),this.directivePropList=Ele}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-node"]],contentQueries:function(e,i,r){if(1&e&&(dn(r,yle,5),dn(r,m_,5),dn(r,Cle,5)),2&e){let s;Kr(s=en())&&(i.childFixedUserHandles=s.first),Kr(s=en())&&(i.childAnnotations=s.first),Kr(s=en())&&(i.childPorts=s.first)}},inputs:{addInfo:"addInfo",annotations:"annotations",backgroundColor:"backgroundColor",borderColor:"borderColor",borderWidth:"borderWidth",branch:"branch",children:"children",collapseIcon:"collapseIcon",columnIndex:"columnIndex",columnSpan:"columnSpan",columns:"columns",constraints:"constraints",container:"container",data:"data",dragSize:"dragSize",excludeFromLayout:"excludeFromLayout",expandIcon:"expandIcon",fixedUserHandles:"fixedUserHandles",flip:"flip",flipMode:"flipMode",height:"height",horizontalAlignment:"horizontalAlignment",id:"id",isExpanded:"isExpanded",layoutInfo:"layoutInfo",margin:"margin",maxHeight:"maxHeight",maxWidth:"maxWidth",minHeight:"minHeight",minWidth:"minWidth",offsetX:"offsetX",offsetY:"offsetY",padding:"padding",pivot:"pivot",ports:"ports",previewSize:"previewSize",rotateAngle:"rotateAngle",rowIndex:"rowIndex",rowSpan:"rowSpan",rows:"rows",shadow:"shadow",shape:"shape",style:"style",symbolInfo:"symbolInfo",tooltip:"tooltip",verticalAlignment:"verticalAlignment",visible:"visible",width:"width",wrapper:"wrapper",zIndex:"zIndex"},features:[yn]}),n})(),S_=(()=>{class n extends dh{constructor(){super("nodes")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-nodes"]],contentQueries:function(e,i,r){if(1&e&&dn(r,y_,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})();const xle=["animationComplete","click","collectionChange","commandExecute","connectionChange","contextMenuBeforeItemRender","contextMenuClick","contextMenuOpen","created","dataLoaded","doubleClick","dragEnter","dragLeave","dragOver","drop","elementDraw","expandStateChange","fixedUserHandleClick","historyChange","historyStateChange","keyDown","keyUp","load","loaded","mouseEnter","mouseLeave","mouseOver","mouseWheel","onFixedUserHandleMouseDown","onFixedUserHandleMouseEnter","onFixedUserHandleMouseLeave","onFixedUserHandleMouseUp","onImageLoad","onUserHandleMouseDown","onUserHandleMouseEnter","onUserHandleMouseLeave","onUserHandleMouseUp","positionChange","propertyChange","rotateChange","scrollChange","segmentChange","segmentCollectionChange","selectionChange","sizeChange","sourcePointChange","targetPointChange","textEdit"],Tle=[""];let Ale=(()=>{let n=class extends Rl{constructor(e,i,r,s){super(),this.ngEle=e,this.srenderer=i,this.viewContainerRef=r,this.injector=s,this.tags=["layers","customCursor","connectors","nodes"],this.element=this.ngEle.nativeElement,this.injectedModules=this.injectedModules||[];try{let o=this.injector.get("DiagramsHierarchicalTree");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsMindMap");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsRadialTree");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsComplexHierarchicalTree");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsDataBinding");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsSnapping");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsPrintAndExport");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsBpmnDiagrams");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsSymmetricLayout");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsConnectorBridging");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsUndoRedo");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsLayoutAnimation");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsDiagramContextMenu");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsLineRouting");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsConnectorEditing");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsLineDistribution");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsEj1Serialization");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsFlowchartLayout");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}this.registerEvents(xle),this.addTwoWay.call(this,Tle),gl("currentInstance",this,this.viewContainerRef),this.context=new SR}ngOnInit(){this.context.ngOnInit(this)}ngAfterViewInit(){this.context.ngAfterViewInit(this)}ngOnDestroy(){this.context.ngOnDestroy(this)}ngAfterContentChecked(){this.tagObjects[0].instance=this.childLayers,this.childCustomCursor&&(this.tagObjects[1].instance=this.childCustomCursor),this.childConnectors&&(this.tagObjects[2].instance=this.childConnectors),this.childNodes&&(this.tagObjects[3].instance=this.childNodes),this.context.ngAfterContentChecked(this)}};return n.\u0275fac=function(e){return new(e||n)(Ot($c),Ot(lM),Ot(xn),Ot(Wo))},n.\u0275cmp=Bb({type:n,selectors:[["ejs-diagram"]],contentQueries:function(e,i,r){if(1&e&&(dn(r,Qae,5),dn(r,Gae,5),dn(r,Xae,5),dn(r,Jae,5),dn(r,ile,5),dn(r,fle,5),dn(r,S_,5)),2&e){let s;Kr(s=en())&&(i.annotationTemplate=s.first),Kr(s=en())&&(i.nodeTemplate=s.first),Kr(s=en())&&(i.userHandleTemplate=s.first),Kr(s=en())&&(i.childLayers=s.first),Kr(s=en())&&(i.childCustomCursor=s.first),Kr(s=en())&&(i.childConnectors=s.first),Kr(s=en())&&(i.childNodes=s.first)}},inputs:{addInfo:"addInfo",annotationTemplate:"annotationTemplate",backgroundColor:"backgroundColor",bridgeDirection:"bridgeDirection",commandManager:"commandManager",connectorDefaults:"connectorDefaults",connectors:"connectors",constraints:"constraints",contextMenuSettings:"contextMenuSettings",customCursor:"customCursor",dataSourceSettings:"dataSourceSettings",diagramSettings:"diagramSettings",drawingObject:"drawingObject",enableConnectorSplit:"enableConnectorSplit",enablePersistence:"enablePersistence",enableRtl:"enableRtl",fixedUserHandleTemplate:"fixedUserHandleTemplate",getConnectorDefaults:"getConnectorDefaults",getCustomCursor:"getCustomCursor",getCustomProperty:"getCustomProperty",getCustomTool:"getCustomTool",getDescription:"getDescription",getNodeDefaults:"getNodeDefaults",height:"height",historyManager:"historyManager",layers:"layers",layout:"layout",locale:"locale",mode:"mode",nodeDefaults:"nodeDefaults",nodeTemplate:"nodeTemplate",nodes:"nodes",pageSettings:"pageSettings",rulerSettings:"rulerSettings",scrollSettings:"scrollSettings",segmentThumbShape:"segmentThumbShape",segmentThumbSize:"segmentThumbSize",selectedItems:"selectedItems",serializationSettings:"serializationSettings",setNodeTemplate:"setNodeTemplate",snapSettings:"snapSettings",tool:"tool",tooltip:"tooltip",updateSelection:"updateSelection",userHandleTemplate:"userHandleTemplate",width:"width"},outputs:{animationComplete:"animationComplete",click:"click",collectionChange:"collectionChange",commandExecute:"commandExecute",connectionChange:"connectionChange",contextMenuBeforeItemRender:"contextMenuBeforeItemRender",contextMenuClick:"contextMenuClick",contextMenuOpen:"contextMenuOpen",created:"created",dataLoaded:"dataLoaded",doubleClick:"doubleClick",dragEnter:"dragEnter",dragLeave:"dragLeave",dragOver:"dragOver",drop:"drop",elementDraw:"elementDraw",expandStateChange:"expandStateChange",fixedUserHandleClick:"fixedUserHandleClick",historyChange:"historyChange",historyStateChange:"historyStateChange",keyDown:"keyDown",keyUp:"keyUp",load:"load",loaded:"loaded",mouseEnter:"mouseEnter",mouseLeave:"mouseLeave",mouseOver:"mouseOver",mouseWheel:"mouseWheel",onFixedUserHandleMouseDown:"onFixedUserHandleMouseDown",onFixedUserHandleMouseEnter:"onFixedUserHandleMouseEnter",onFixedUserHandleMouseLeave:"onFixedUserHandleMouseLeave",onFixedUserHandleMouseUp:"onFixedUserHandleMouseUp",onImageLoad:"onImageLoad",onUserHandleMouseDown:"onUserHandleMouseDown",onUserHandleMouseEnter:"onUserHandleMouseEnter",onUserHandleMouseLeave:"onUserHandleMouseLeave",onUserHandleMouseUp:"onUserHandleMouseUp",positionChange:"positionChange",propertyChange:"propertyChange",rotateChange:"rotateChange",scrollChange:"scrollChange",segmentChange:"segmentChange",segmentCollectionChange:"segmentCollectionChange",selectionChange:"selectionChange",sizeChange:"sizeChange",sourcePointChange:"sourcePointChange",targetPointChange:"targetPointChange",textEdit:"textEdit"},features:[yn],decls:0,vars:0,template:function(e,i){},encapsulation:2,changeDetection:0}),N0([DC()],n.prototype,"annotationTemplate",void 0),N0([DC()],n.prototype,"nodeTemplate",void 0),N0([DC()],n.prototype,"userHandleTemplate",void 0),n=N0([PZ([SR])],n),n})(),Lle=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Lm({type:n}),n.\u0275inj=mf({imports:[[sq]]}),n})();const Nle=["diagram"];let Ole=(()=>{class n{constructor(){this.layers=[]}ngOnInit(){this.layers=[{id:"layer1",objects:["node1"]},{id:"layer2",objects:["node2"]}]}removeLayer(){this.diagram.removeLayer("layer1")}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275cmp=Bb({type:n,selectors:[["app-container"]],viewQuery:function(i,r){if(1&i&&function uP(n,t,e){const i=xi();i.firstCreatePass&&(cP(i,new aP(n,t,e),-1),2==(2&t)&&(i.staticViewQueries=!0)),hP(i,Se(),t)}(Nle,5),2&i){let s;Kr(s=en())&&(r.diagram=s.first)}},standalone:!0,features:[PP([]),RP],decls:11,vars:9,consts:[["id","diagram","width","100%","height","580px",3,"layers"],["diagram",""],["id","node1",3,"width","height","offsetX","offsetY"],["content","Layer 1 Object"],["id","node2",3,"width","height","offsetX","offsetY"],["content","Layer 2 Object"],[3,"click"]],template:function(i,r){1&i&&(Qu(0,"ejs-diagram",0,1)(2,"e-nodes")(3,"e-node",2)(4,"e-node-annotations"),Uy(5,"e-node-annotation",3),Gu()(),Qu(6,"e-node",4)(7,"e-node-annotations"),Uy(8,"e-node-annotation",5),Gu()()()(),Qu(9,"button",6),aw("click",function(){return r.removeLayer()}),function MP(n,t=""){const e=Se(),i=xi(),r=n+Ut,s=i.firstCreatePass?xu(i,r,1,t,null):i.data[r],o=wP(i,e,s,t,n);e[r]=o,Hm()&&hy(i,e,o,s),ol(s,!1)}(10,"removeLayer"),Gu()),2&i&&(hg("layers",r.layers),pM(3),hg("width",100)("height",100)("offsetX",100)("offsetY",100),pM(3),hg("width",100)("height",100)("offsetX",100)("offsetY",300))},dependencies:[Lle,Ale,v_,m_,y_,S_],encapsulation:2})}}return n})();Ud(332),function $q(n,t){return DG({rootComponent:n,...Ez(t)})}(Ole).catch(n=>console.error(n))},332:()=>{!function(Z){const se=Z.performance;function ye(Pi){se&&se.mark&&se.mark(Pi)}function fe(Pi,ht){se&&se.measure&&se.measure(Pi,ht)}ye("Zone");const be=Z.__Zone_symbol_prefix||"__zone_symbol__";function ke(Pi){return be+Pi}const at=!0===Z[ke("forceDuplicateZoneCheck")];if(Z.Zone){if(at||"function"!=typeof Z.Zone.__symbol__)throw new Error("Zone already loaded.");return Z.Zone}let tt=(()=>{class Pi{static{this.__symbol__=ke}static assertZonePatched(){if(Z.Promise!==_o.ZoneAwarePromise)throw new Error("Zone.js has detected that ZoneAwarePromise `(window|global).Promise` has been overwritten.\nMost likely cause is that a Promise polyfill has been loaded after Zone.js (Polyfilling Promise api is not necessary when zone.js is loaded. If you must load one, do so before loading zone.js.)")}static get root(){let F=Pi.current;for(;F.parent;)F=F.parent;return F}static get current(){return Ur.zone}static get currentTask(){return Do}static __load_patch(F,ae,Et=!1){if(_o.hasOwnProperty(F)){if(!Et&&at)throw Error("Already loaded patch: "+F)}else if(!Z["__Zone_disable_"+F]){const Xt="Zone:"+F;ye(Xt),_o[F]=ae(Z,Pi,cn),fe(Xt,Xt)}}get parent(){return this._parent}get name(){return this._name}constructor(F,ae){this._parent=F,this._name=ae?ae.name||"unnamed":"",this._properties=ae&&ae.properties||{},this._zoneDelegate=new Lt(this,this._parent&&this._parent._zoneDelegate,ae)}get(F){const ae=this.getZoneWith(F);if(ae)return ae._properties[F]}getZoneWith(F){let ae=this;for(;ae;){if(ae._properties.hasOwnProperty(F))return ae;ae=ae._parent}return null}fork(F){if(!F)throw new Error("ZoneSpec required!");return this._zoneDelegate.fork(this,F)}wrap(F,ae){if("function"!=typeof F)throw new Error("Expecting function got: "+F);const Et=this._zoneDelegate.intercept(this,F,ae),Xt=this;return function(){return Xt.runGuarded(Et,this,arguments,ae)}}run(F,ae,Et,Xt){Ur={parent:Ur,zone:this};try{return this._zoneDelegate.invoke(this,F,ae,Et,Xt)}finally{Ur=Ur.parent}}runGuarded(F,ae=null,Et,Xt){Ur={parent:Ur,zone:this};try{try{return this._zoneDelegate.invoke(this,F,ae,Et,Xt)}catch(Un){if(this._zoneDelegate.handleError(this,Un))throw Un}}finally{Ur=Ur.parent}}runTask(F,ae,Et){if(F.zone!=this)throw new Error("A task can only be run in the zone of creation! (Creation: "+(F.zone||_n).name+"; Execution: "+this.name+")");if(F.state===sr&&(F.type===ts||F.type===Pt))return;const Xt=F.state!=lt;Xt&&F._transitionTo(lt,ki),F.runCount++;const Un=Do;Do=F,Ur={parent:Ur,zone:this};try{F.type==Pt&&F.data&&!F.data.isPeriodic&&(F.cancelFn=void 0);try{return this._zoneDelegate.invokeTask(this,F,ae,Et)}catch(Ue){if(this._zoneDelegate.handleError(this,Ue))throw Ue}}finally{F.state!==sr&&F.state!==et&&(F.type==ts||F.data&&F.data.isPeriodic?Xt&&F._transitionTo(ki,lt):(F.runCount=0,this._updateTaskCount(F,-1),Xt&&F._transitionTo(sr,lt,sr))),Ur=Ur.parent,Do=Un}}scheduleTask(F){if(F.zone&&F.zone!==this){let Et=this;for(;Et;){if(Et===F.zone)throw Error(`can not reschedule task to ${this.name} which is descendants of the original zone ${F.zone.name}`);Et=Et.parent}}F._transitionTo(Zr,sr);const ae=[];F._zoneDelegates=ae,F._zone=this;try{F=this._zoneDelegate.scheduleTask(this,F)}catch(Et){throw F._transitionTo(et,Zr,sr),this._zoneDelegate.handleError(this,Et),Et}return F._zoneDelegates===ae&&this._updateTaskCount(F,1),F.state==Zr&&F._transitionTo(ki,Zr),F}scheduleMicroTask(F,ae,Et,Xt){return this.scheduleTask(new ft(vi,F,ae,Et,Xt,void 0))}scheduleMacroTask(F,ae,Et,Xt,Un){return this.scheduleTask(new ft(Pt,F,ae,Et,Xt,Un))}scheduleEventTask(F,ae,Et,Xt,Un){return this.scheduleTask(new ft(ts,F,ae,Et,Xt,Un))}cancelTask(F){if(F.zone!=this)throw new Error("A task can only be cancelled in the zone of creation! (Creation: "+(F.zone||_n).name+"; Execution: "+this.name+")");if(F.state===ki||F.state===lt){F._transitionTo(dr,ki,lt);try{this._zoneDelegate.cancelTask(this,F)}catch(ae){throw F._transitionTo(et,dr),this._zoneDelegate.handleError(this,ae),ae}return this._updateTaskCount(F,-1),F._transitionTo(sr,dr),F.runCount=0,F}}_updateTaskCount(F,ae){const Et=F._zoneDelegates;-1==ae&&(F._zoneDelegates=null);for(let Xt=0;XtPi.hasTask(F,ae),onScheduleTask:(Pi,ht,F,ae)=>Pi.scheduleTask(F,ae),onInvokeTask:(Pi,ht,F,ae,Et,Xt)=>Pi.invokeTask(F,ae,Et,Xt),onCancelTask:(Pi,ht,F,ae)=>Pi.cancelTask(F,ae)};class Lt{constructor(ht,F,ae){this._taskCounts={microTask:0,macroTask:0,eventTask:0},this.zone=ht,this._parentDelegate=F,this._forkZS=ae&&(ae&&ae.onFork?ae:F._forkZS),this._forkDlgt=ae&&(ae.onFork?F:F._forkDlgt),this._forkCurrZone=ae&&(ae.onFork?this.zone:F._forkCurrZone),this._interceptZS=ae&&(ae.onIntercept?ae:F._interceptZS),this._interceptDlgt=ae&&(ae.onIntercept?F:F._interceptDlgt),this._interceptCurrZone=ae&&(ae.onIntercept?this.zone:F._interceptCurrZone),this._invokeZS=ae&&(ae.onInvoke?ae:F._invokeZS),this._invokeDlgt=ae&&(ae.onInvoke?F:F._invokeDlgt),this._invokeCurrZone=ae&&(ae.onInvoke?this.zone:F._invokeCurrZone),this._handleErrorZS=ae&&(ae.onHandleError?ae:F._handleErrorZS),this._handleErrorDlgt=ae&&(ae.onHandleError?F:F._handleErrorDlgt),this._handleErrorCurrZone=ae&&(ae.onHandleError?this.zone:F._handleErrorCurrZone),this._scheduleTaskZS=ae&&(ae.onScheduleTask?ae:F._scheduleTaskZS),this._scheduleTaskDlgt=ae&&(ae.onScheduleTask?F:F._scheduleTaskDlgt),this._scheduleTaskCurrZone=ae&&(ae.onScheduleTask?this.zone:F._scheduleTaskCurrZone),this._invokeTaskZS=ae&&(ae.onInvokeTask?ae:F._invokeTaskZS),this._invokeTaskDlgt=ae&&(ae.onInvokeTask?F:F._invokeTaskDlgt),this._invokeTaskCurrZone=ae&&(ae.onInvokeTask?this.zone:F._invokeTaskCurrZone),this._cancelTaskZS=ae&&(ae.onCancelTask?ae:F._cancelTaskZS),this._cancelTaskDlgt=ae&&(ae.onCancelTask?F:F._cancelTaskDlgt),this._cancelTaskCurrZone=ae&&(ae.onCancelTask?this.zone:F._cancelTaskCurrZone),this._hasTaskZS=null,this._hasTaskDlgt=null,this._hasTaskDlgtOwner=null,this._hasTaskCurrZone=null;const Et=ae&&ae.onHasTask;(Et||F&&F._hasTaskZS)&&(this._hasTaskZS=Et?ae:At,this._hasTaskDlgt=F,this._hasTaskDlgtOwner=this,this._hasTaskCurrZone=ht,ae.onScheduleTask||(this._scheduleTaskZS=At,this._scheduleTaskDlgt=F,this._scheduleTaskCurrZone=this.zone),ae.onInvokeTask||(this._invokeTaskZS=At,this._invokeTaskDlgt=F,this._invokeTaskCurrZone=this.zone),ae.onCancelTask||(this._cancelTaskZS=At,this._cancelTaskDlgt=F,this._cancelTaskCurrZone=this.zone))}fork(ht,F){return this._forkZS?this._forkZS.onFork(this._forkDlgt,this.zone,ht,F):new tt(ht,F)}intercept(ht,F,ae){return this._interceptZS?this._interceptZS.onIntercept(this._interceptDlgt,this._interceptCurrZone,ht,F,ae):F}invoke(ht,F,ae,Et,Xt){return this._invokeZS?this._invokeZS.onInvoke(this._invokeDlgt,this._invokeCurrZone,ht,F,ae,Et,Xt):F.apply(ae,Et)}handleError(ht,F){return!this._handleErrorZS||this._handleErrorZS.onHandleError(this._handleErrorDlgt,this._handleErrorCurrZone,ht,F)}scheduleTask(ht,F){let ae=F;if(this._scheduleTaskZS)this._hasTaskZS&&ae._zoneDelegates.push(this._hasTaskDlgtOwner),ae=this._scheduleTaskZS.onScheduleTask(this._scheduleTaskDlgt,this._scheduleTaskCurrZone,ht,F),ae||(ae=F);else if(F.scheduleFn)F.scheduleFn(F);else{if(F.type!=vi)throw new Error("Task is missing scheduleFn.");Wt(F)}return ae}invokeTask(ht,F,ae,Et){return this._invokeTaskZS?this._invokeTaskZS.onInvokeTask(this._invokeTaskDlgt,this._invokeTaskCurrZone,ht,F,ae,Et):F.callback.apply(ae,Et)}cancelTask(ht,F){let ae;if(this._cancelTaskZS)ae=this._cancelTaskZS.onCancelTask(this._cancelTaskDlgt,this._cancelTaskCurrZone,ht,F);else{if(!F.cancelFn)throw Error("Task is not cancelable");ae=F.cancelFn(F)}return ae}hasTask(ht,F){try{this._hasTaskZS&&this._hasTaskZS.onHasTask(this._hasTaskDlgt,this._hasTaskCurrZone,ht,F)}catch(ae){this.handleError(ht,ae)}}_updateTaskCount(ht,F){const ae=this._taskCounts,Et=ae[ht],Xt=ae[ht]=Et+F;if(Xt<0)throw new Error("More tasks executed then were scheduled.");0!=Et&&0!=Xt||this.hasTask(this.zone,{microTask:ae.microTask>0,macroTask:ae.macroTask>0,eventTask:ae.eventTask>0,change:ht})}}class ft{constructor(ht,F,ae,Et,Xt,Un){if(this._zone=null,this.runCount=0,this._zoneDelegates=null,this._state="notScheduled",this.type=ht,this.source=F,this.data=Et,this.scheduleFn=Xt,this.cancelFn=Un,!ae)throw new Error("callback is not defined");this.callback=ae;const Ue=this;this.invoke=ht===ts&&Et&&Et.useG?ft.invokeTask:function(){return ft.invokeTask.call(Z,Ue,this,arguments)}}static invokeTask(ht,F,ae){ht||(ht=this),Ls++;try{return ht.runCount++,ht.zone.runTask(ht,F,ae)}finally{1==Ls&&ct(),Ls--}}get zone(){return this._zone}get state(){return this._state}cancelScheduleRequest(){this._transitionTo(sr,Zr)}_transitionTo(ht,F,ae){if(this._state!==F&&this._state!==ae)throw new Error(`${this.type} '${this.source}': can not transition to '${ht}', expecting state '${F}'${ae?" or '"+ae+"'":""}, was '${this._state}'.`);this._state=ht,ht==sr&&(this._zoneDelegates=null)}toString(){return this.data&&typeof this.data.handleId<"u"?this.data.handleId.toString():Object.prototype.toString.call(this)}toJSON(){return{type:this.type,state:this.state,source:this.source,zone:this.zone.name,runCount:this.runCount}}}const Ei=ke("setTimeout"),ti=ke("Promise"),gi=ke("then");let es,cr=[],Oi=!1;function kr(Pi){if(es||Z[ti]&&(es=Z[ti].resolve(0)),es){let ht=es[gi];ht||(ht=es.then),ht.call(es,Pi)}else Z[Ei](Pi,0)}function Wt(Pi){0===Ls&&0===cr.length&&kr(ct),Pi&&cr.push(Pi)}function ct(){if(!Oi){for(Oi=!0;cr.length;){const Pi=cr;cr=[];for(let ht=0;htUr,onUnhandledError:jr,microtaskDrainDone:jr,scheduleMicroTask:Wt,showUncaughtError:()=>!tt[ke("ignoreConsoleErrorUncaughtError")],patchEventTarget:()=>[],patchOnProperties:jr,patchMethod:()=>jr,bindArguments:()=>[],patchThen:()=>jr,patchMacroTask:()=>jr,patchEventPrototype:()=>jr,isIEOrEdge:()=>!1,getGlobalObjects:()=>{},ObjectDefineProperty:()=>jr,ObjectGetOwnPropertyDescriptor:()=>{},ObjectCreate:()=>{},ArraySlice:()=>[],patchClass:()=>jr,wrapWithCurrentZone:()=>jr,filterProperties:()=>[],attachOriginToPatched:()=>jr,_redefineProperty:()=>jr,patchCallbacks:()=>jr,nativeScheduleMicroTask:kr};let Ur={parent:null,zone:new tt(null,null)},Do=null,Ls=0;function jr(){}fe("Zone","Zone"),Z.Zone=tt}(globalThis);const _l=Object.getOwnPropertyDescriptor,_d=Object.defineProperty,Ud=Object.getPrototypeOf,jd=Object.create,mb=Array.prototype.slice,fm="addEventListener",$r="removeEventListener",Ul=Zone.__symbol__(fm),Fh=Zone.__symbol__($r),Ts="true",Wi="false",Vd=Zone.__symbol__("");function lf(Z,se){return Zone.current.wrap(Z,se)}function gm(Z,se,ye,fe,be){return Zone.current.scheduleMacroTask(Z,se,ye,fe,be)}const Ji=Zone.__symbol__,_h=typeof window<"u",Uh=_h?window:void 0,gn=_h&&Uh||globalThis,vm="removeAttribute";function Wd(Z,se){for(let ye=Z.length-1;ye>=0;ye--)"function"==typeof Z[ye]&&(Z[ye]=lf(Z[ye],se+"_"+ye));return Z}function hf(Z){return!Z||!1!==Z.writable&&!("function"==typeof Z.get&&typeof Z.set>"u")}const cf=typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope,jh=!("nw"in gn)&&typeof gn.process<"u"&&"[object process]"==={}.toString.call(gn.process),Yd=!jh&&!cf&&!(!_h||!Uh.HTMLElement),df=typeof gn.process<"u"&&"[object process]"==={}.toString.call(gn.process)&&!cf&&!(!_h||!Uh.HTMLElement),jl={},Vh=function(Z){if(!(Z=Z||gn.event))return;let se=jl[Z.type];se||(se=jl[Z.type]=Ji("ON_PROPERTY"+Z.type));const ye=this||Z.target||gn,fe=ye[se];let be;return Yd&&ye===Uh&&"error"===Z.type?(be=fe&&fe.call(this,Z.message,Z.filename,Z.lineno,Z.colno,Z.error),!0===be&&Z.preventDefault()):(be=fe&&fe.apply(this,arguments),null!=be&&!be&&Z.preventDefault()),be};function Vl(Z,se,ye){let fe=_l(Z,se);if(!fe&&ye&&_l(ye,se)&&(fe={enumerable:!0,configurable:!0}),!fe||!fe.configurable)return;const be=Ji("on"+se+"patched");if(Z.hasOwnProperty(be)&&Z[be])return;delete fe.writable,delete fe.value;const ke=fe.get,at=fe.set,tt=se.slice(2);let At=jl[tt];At||(At=jl[tt]=Ji("ON_PROPERTY"+tt)),fe.set=function(Lt){let ft=this;!ft&&Z===gn&&(ft=gn),ft&&("function"==typeof ft[At]&&ft.removeEventListener(tt,Vh),at&&at.call(ft,null),ft[At]=Lt,"function"==typeof Lt&&ft.addEventListener(tt,Vh,!1))},fe.get=function(){let Lt=this;if(!Lt&&Z===gn&&(Lt=gn),!Lt)return null;const ft=Lt[At];if(ft)return ft;if(ke){let Ei=ke.call(this);if(Ei)return fe.set.call(this,Ei),"function"==typeof Lt[vm]&&Lt.removeAttribute(se),Ei}return null},_d(Z,se,fe),Z[be]=!0}function uf(Z,se,ye){if(se)for(let fe=0;fefunction(at,tt){const At=ye(at,tt);return At.cbIdx>=0&&"function"==typeof tt[At.cbIdx]?gm(At.name,tt[At.cbIdx],At,be):ke.apply(at,tt)})}function Sa(Z,se){Z[Ji("OriginalDelegate")]=se}let Sb=!1,Gd=!1;function Ib(){if(Sb)return Gd;Sb=!0;try{const Z=Uh.navigator.userAgent;(-1!==Z.indexOf("MSIE ")||-1!==Z.indexOf("Trident/")||-1!==Z.indexOf("Edge/"))&&(Gd=!0)}catch{}return Gd}Zone.__load_patch("ZoneAwarePromise",(Z,se,ye)=>{const fe=Object.getOwnPropertyDescriptor,be=Object.defineProperty,at=ye.symbol,tt=[],At=!1!==Z[at("DISABLE_WRAPPING_UNCAUGHT_PROMISE_REJECTION")],Lt=at("Promise"),ft=at("then"),Ei="__creationTrace__";ye.onUnhandledError=Ue=>{if(ye.showUncaughtError()){const He=Ue&&Ue.rejection;He?console.error("Unhandled Promise rejection:",He instanceof Error?He.message:He,"; Zone:",Ue.zone.name,"; Task:",Ue.task&&Ue.task.source,"; Value:",He,He instanceof Error?He.stack:void 0):console.error(Ue)}},ye.microtaskDrainDone=()=>{for(;tt.length;){const Ue=tt.shift();try{Ue.zone.runGuarded(()=>{throw Ue.throwOriginal?Ue.rejection:Ue})}catch(He){gi(He)}}};const ti=at("unhandledPromiseRejectionHandler");function gi(Ue){ye.onUnhandledError(Ue);try{const He=se[ti];"function"==typeof He&&He.call(this,Ue)}catch{}}function cr(Ue){return Ue&&Ue.then}function Oi(Ue){return Ue}function es(Ue){return F.reject(Ue)}const kr=at("state"),Wt=at("value"),ct=at("finally"),_n=at("parentPromiseValue"),sr=at("parentPromiseState"),Zr="Promise.then",ki=null,lt=!0,dr=!1,et=0;function vi(Ue,He){return ge=>{try{cn(Ue,He,ge)}catch(We){cn(Ue,!1,We)}}}const Pt=function(){let Ue=!1;return function(ge){return function(){Ue||(Ue=!0,ge.apply(null,arguments))}}},ts="Promise resolved with itself",_o=at("currentTaskTrace");function cn(Ue,He,ge){const We=Pt();if(Ue===ge)throw new TypeError(ts);if(Ue[kr]===ki){let wt=null;try{("object"==typeof ge||"function"==typeof ge)&&(wt=ge&&ge.then)}catch(Xe){return We(()=>{cn(Ue,!1,Xe)})(),Ue}if(He!==dr&&ge instanceof F&&ge.hasOwnProperty(kr)&&ge.hasOwnProperty(Wt)&&ge[kr]!==ki)Do(ge),cn(Ue,ge[kr],ge[Wt]);else if(He!==dr&&"function"==typeof wt)try{wt.call(ge,We(vi(Ue,He)),We(vi(Ue,!1)))}catch(Xe){We(()=>{cn(Ue,!1,Xe)})()}else{Ue[kr]=He;const Xe=Ue[Wt];if(Ue[Wt]=ge,Ue[ct]===ct&&He===lt&&(Ue[kr]=Ue[sr],Ue[Wt]=Ue[_n]),He===dr&&ge instanceof Error){const mt=se.currentTask&&se.currentTask.data&&se.currentTask.data[Ei];mt&&be(ge,_o,{configurable:!0,enumerable:!1,writable:!0,value:mt})}for(let mt=0;mt{try{const dt=Ue[Wt],qt=!!ge&&ct===ge[ct];qt&&(ge[_n]=dt,ge[sr]=Xe);const ai=He.run(mt,void 0,qt&&mt!==es&&mt!==Oi?[]:[dt]);cn(ge,!0,ai)}catch(dt){cn(ge,!1,dt)}},ge)}const Pi=function(){},ht=Z.AggregateError;class F{static toString(){return"function ZoneAwarePromise() { [native code] }"}static resolve(He){return He instanceof F?He:cn(new this(null),lt,He)}static reject(He){return cn(new this(null),dr,He)}static withResolvers(){const He={};return He.promise=new F((ge,We)=>{He.resolve=ge,He.reject=We}),He}static any(He){if(!He||"function"!=typeof He[Symbol.iterator])return Promise.reject(new ht([],"All promises were rejected"));const ge=[];let We=0;try{for(let mt of He)We++,ge.push(F.resolve(mt))}catch{return Promise.reject(new ht([],"All promises were rejected"))}if(0===We)return Promise.reject(new ht([],"All promises were rejected"));let wt=!1;const Xe=[];return new F((mt,dt)=>{for(let qt=0;qt{wt||(wt=!0,mt(ai))},ai=>{Xe.push(ai),We--,0===We&&(wt=!0,dt(new ht(Xe,"All promises were rejected")))})})}static race(He){let ge,We,wt=new this((dt,qt)=>{ge=dt,We=qt});function Xe(dt){ge(dt)}function mt(dt){We(dt)}for(let dt of He)cr(dt)||(dt=this.resolve(dt)),dt.then(Xe,mt);return wt}static all(He){return F.allWithCallback(He)}static allSettled(He){return(this&&this.prototype instanceof F?this:F).allWithCallback(He,{thenCallback:We=>({status:"fulfilled",value:We}),errorCallback:We=>({status:"rejected",reason:We})})}static allWithCallback(He,ge){let We,wt,Xe=new this((ai,ur)=>{We=ai,wt=ur}),mt=2,dt=0;const qt=[];for(let ai of He){cr(ai)||(ai=this.resolve(ai));const ur=dt;try{ai.then(ir=>{qt[ur]=ge?ge.thenCallback(ir):ir,mt--,0===mt&&We(qt)},ir=>{ge?(qt[ur]=ge.errorCallback(ir),mt--,0===mt&&We(qt)):wt(ir)})}catch(ir){wt(ir)}mt++,dt++}return mt-=2,0===mt&&We(qt),Xe}constructor(He){const ge=this;if(!(ge instanceof F))throw new Error("Must be an instanceof Promise.");ge[kr]=ki,ge[Wt]=[];try{const We=Pt();He&&He(We(vi(ge,lt)),We(vi(ge,dr)))}catch(We){cn(ge,!1,We)}}get[Symbol.toStringTag](){return"Promise"}get[Symbol.species](){return F}then(He,ge){let We=this.constructor?.[Symbol.species];(!We||"function"!=typeof We)&&(We=this.constructor||F);const wt=new We(Pi),Xe=se.current;return this[kr]==ki?this[Wt].push(Xe,wt,He,ge):Ls(this,Xe,wt,He,ge),wt}catch(He){return this.then(null,He)}finally(He){let ge=this.constructor?.[Symbol.species];(!ge||"function"!=typeof ge)&&(ge=F);const We=new ge(Pi);We[ct]=ct;const wt=se.current;return this[kr]==ki?this[Wt].push(wt,We,He,He):Ls(this,wt,We,He,He),We}}F.resolve=F.resolve,F.reject=F.reject,F.race=F.race,F.all=F.all;const ae=Z[Lt]=Z.Promise;Z.Promise=F;const Et=at("thenPatched");function Xt(Ue){const He=Ue.prototype,ge=fe(He,"then");if(ge&&(!1===ge.writable||!ge.configurable))return;const We=He.then;He[ft]=We,Ue.prototype.then=function(wt,Xe){return new F((dt,qt)=>{We.call(this,dt,qt)}).then(wt,Xe)},Ue[Et]=!0}return ye.patchThen=Xt,ae&&(Xt(ae),Ka(Z,"fetch",Ue=>function Un(Ue){return function(He,ge){let We=Ue.apply(He,ge);if(We instanceof F)return We;let wt=We.constructor;return wt[Et]||Xt(wt),We}}(Ue))),Promise[se.__symbol__("uncaughtPromiseErrors")]=tt,F}),Zone.__load_patch("toString",Z=>{const se=Function.prototype.toString,ye=Ji("OriginalDelegate"),fe=Ji("Promise"),be=Ji("Error"),ke=function(){if("function"==typeof this){const Lt=this[ye];if(Lt)return"function"==typeof Lt?se.call(Lt):Object.prototype.toString.call(Lt);if(this===Promise){const ft=Z[fe];if(ft)return se.call(ft)}if(this===Error){const ft=Z[be];if(ft)return se.call(ft)}}return se.call(this)};ke[ye]=se,Function.prototype.toString=ke;const at=Object.prototype.toString;Object.prototype.toString=function(){return"function"==typeof Promise&&this instanceof Promise?"[object Promise]":at.call(this)}});let el=!1;if(typeof window<"u")try{const Z=Object.defineProperty({},"passive",{get:function(){el=!0}});window.addEventListener("test",Z,Z),window.removeEventListener("test",Z,Z)}catch{el=!1}const PT={useG:!0},Co={},bb={},Sm=new RegExp("^"+Vd+"(\\w+)(true|false)$"),Mb=Ji("propagationStopped");function Im(Z,se){const ye=(se?se(Z):Z)+Wi,fe=(se?se(Z):Z)+Ts,be=Vd+ye,ke=Vd+fe;Co[Z]={},Co[Z][Wi]=be,Co[Z][Ts]=ke}function wb(Z,se,ye,fe){const be=fe&&fe.add||fm,ke=fe&&fe.rm||$r,at=fe&&fe.listeners||"eventListeners",tt=fe&&fe.rmAll||"removeAllListeners",At=Ji(be),Lt="."+be+":",ft="prependListener",Ei="."+ft+":",ti=function(Wt,ct,_n){if(Wt.isRemoved)return;const sr=Wt.callback;let Zr;"object"==typeof sr&&sr.handleEvent&&(Wt.callback=lt=>sr.handleEvent(lt),Wt.originalDelegate=sr);try{Wt.invoke(Wt,ct,[_n])}catch(lt){Zr=lt}const ki=Wt.options;return ki&&"object"==typeof ki&&ki.once&&ct[ke].call(ct,_n.type,Wt.originalDelegate?Wt.originalDelegate:Wt.callback,ki),Zr};function gi(Wt,ct,_n){if(!(ct=ct||Z.event))return;const sr=Wt||ct.target||Z,Zr=sr[Co[ct.type][_n?Ts:Wi]];if(Zr){const ki=[];if(1===Zr.length){const lt=ti(Zr[0],sr,ct);lt&&ki.push(lt)}else{const lt=Zr.slice();for(let dr=0;dr{throw dr})}}}const cr=function(Wt){return gi(this,Wt,!1)},Oi=function(Wt){return gi(this,Wt,!0)};function es(Wt,ct){if(!Wt)return!1;let _n=!0;ct&&void 0!==ct.useG&&(_n=ct.useG);const sr=ct&&ct.vh;let Zr=!0;ct&&void 0!==ct.chkDup&&(Zr=ct.chkDup);let ki=!1;ct&&void 0!==ct.rt&&(ki=ct.rt);let lt=Wt;for(;lt&&!lt.hasOwnProperty(be);)lt=Ud(lt);if(!lt&&Wt[be]&&(lt=Wt),!lt||lt[At])return!1;const dr=ct&&ct.eventNameToString,et={},vi=lt[At]=lt[be],Pt=lt[Ji(ke)]=lt[ke],ts=lt[Ji(at)]=lt[at],_o=lt[Ji(tt)]=lt[tt];let cn;ct&&ct.prepend&&(cn=lt[Ji(ct.prepend)]=lt[ct.prepend]);const F=_n?function(ge){if(!et.isExisting)return vi.call(et.target,et.eventName,et.capture?Oi:cr,et.options)}:function(ge){return vi.call(et.target,et.eventName,ge.invoke,et.options)},ae=_n?function(ge){if(!ge.isRemoved){const We=Co[ge.eventName];let wt;We&&(wt=We[ge.capture?Ts:Wi]);const Xe=wt&&ge.target[wt];if(Xe)for(let mt=0;mt{Vo.zone.cancelTask(Vo)},{once:!0})),et.target=null,Fc&&(Fc.taskData=null),qd&&(Dn.once=!0),!el&&"boolean"==typeof Vo.options||(Vo.options=Dn),Vo.target=qt,Vo.capture=Gl,Vo.eventName=ai,ir&&(Vo.originalDelegate=ur),dt?jo.unshift(Vo):jo.push(Vo),mt?qt:void 0}};return lt[be]=He(vi,Lt,F,ae,ki),cn&&(lt[ft]=He(cn,Ei,function(ge){return cn.call(et.target,et.eventName,ge.invoke,et.options)},ae,ki,!0)),lt[ke]=function(){const ge=this||Z;let We=arguments[0];ct&&ct.transferEventName&&(We=ct.transferEventName(We));const wt=arguments[2],Xe=!!wt&&("boolean"==typeof wt||wt.capture),mt=arguments[1];if(!mt)return Pt.apply(this,arguments);if(sr&&!sr(Pt,mt,ge,arguments))return;const dt=Co[We];let qt;dt&&(qt=dt[Xe?Ts:Wi]);const ai=qt&&ge[qt];if(ai)for(let ur=0;urfunction(be,ke){be[Mb]=!0,fe&&fe.apply(be,ke)})}function Eb(Z,se,ye,fe,be){const ke=Zone.__symbol__(fe);if(se[ke])return;const at=se[ke]=se[fe];se[fe]=function(tt,At,Lt){return At&&At.prototype&&be.forEach(function(ft){const Ei=`${ye}.${fe}::`+ft,ti=At.prototype;try{if(ti.hasOwnProperty(ft)){const gi=Z.ObjectGetOwnPropertyDescriptor(ti,ft);gi&&gi.value?(gi.value=Z.wrapWithCurrentZone(gi.value,Ei),Z._redefineProperty(At.prototype,ft,gi)):ti[ft]&&(ti[ft]=Z.wrapWithCurrentZone(ti[ft],Ei))}else ti[ft]&&(ti[ft]=Z.wrapWithCurrentZone(ti[ft],Ei))}catch{}}),at.call(se,tt,At,Lt)},Z.attachOriginToPatched(se[fe],at)}function Db(Z,se,ye){if(!ye||0===ye.length)return se;const fe=ye.filter(ke=>ke.target===Z);if(!fe||0===fe.length)return se;const be=fe[0].ignoreProperties;return se.filter(ke=>-1===be.indexOf(ke))}function Eo(Z,se,ye,fe){Z&&uf(Z,Db(Z,se,ye),fe)}function Xd(Z){return Object.getOwnPropertyNames(Z).filter(se=>se.startsWith("on")&&se.length>2).map(se=>se.substring(2))}Zone.__load_patch("util",(Z,se,ye)=>{const fe=Xd(Z);ye.patchOnProperties=uf,ye.patchMethod=Ka,ye.bindArguments=Wd,ye.patchMacroTask=yb;const be=se.__symbol__("BLACK_LISTED_EVENTS"),ke=se.__symbol__("UNPATCHED_EVENTS");Z[ke]&&(Z[be]=Z[ke]),Z[be]&&(se[be]=se[ke]=Z[be]),ye.patchEventPrototype=bm,ye.patchEventTarget=wb,ye.isIEOrEdge=Ib,ye.ObjectDefineProperty=_d,ye.ObjectGetOwnPropertyDescriptor=_l,ye.ObjectCreate=jd,ye.ArraySlice=mb,ye.patchClass=Qd,ye.wrapWithCurrentZone=lf,ye.filterProperties=Db,ye.attachOriginToPatched=Sa,ye._redefineProperty=Object.defineProperty,ye.patchCallbacks=Eb,ye.getGlobalObjects=()=>({globalSources:bb,zoneSymbolEventNames:Co,eventNames:fe,isBrowser:Yd,isMix:df,isNode:jh,TRUE_STR:Ts,FALSE_STR:Wi,ZONE_SYMBOL_PREFIX:Vd,ADD_EVENT_LISTENER_STR:fm,REMOVE_EVENT_LISTENER_STR:$r})});const As=Ji("zoneTask");function Wl(Z,se,ye,fe){let be=null,ke=null;ye+=fe;const at={};function tt(Lt){const ft=Lt.data;return ft.args[0]=function(){return Lt.invoke.apply(this,arguments)},ft.handleId=be.apply(Z,ft.args),Lt}function At(Lt){return ke.call(Z,Lt.data.handleId)}be=Ka(Z,se+=fe,Lt=>function(ft,Ei){if("function"==typeof Ei[0]){const ti={isPeriodic:"Interval"===fe,delay:"Timeout"===fe||"Interval"===fe?Ei[1]||0:void 0,args:Ei},gi=Ei[0];Ei[0]=function(){try{return gi.apply(this,arguments)}finally{ti.isPeriodic||("number"==typeof ti.handleId?delete at[ti.handleId]:ti.handleId&&(ti.handleId[As]=null))}};const cr=gm(se,Ei[0],ti,tt,At);if(!cr)return cr;const Oi=cr.data.handleId;return"number"==typeof Oi?at[Oi]=cr:Oi&&(Oi[As]=cr),Oi&&Oi.ref&&Oi.unref&&"function"==typeof Oi.ref&&"function"==typeof Oi.unref&&(cr.ref=Oi.ref.bind(Oi),cr.unref=Oi.unref.bind(Oi)),"number"==typeof Oi||Oi?Oi:cr}return Lt.apply(Z,Ei)}),ke=Ka(Z,ye,Lt=>function(ft,Ei){const ti=Ei[0];let gi;"number"==typeof ti?gi=at[ti]:(gi=ti&&ti[As],gi||(gi=ti)),gi&&"string"==typeof gi.type?"notScheduled"!==gi.state&&(gi.cancelFn&&gi.data.isPeriodic||0===gi.runCount)&&("number"==typeof ti?delete at[ti]:ti&&(ti[As]=null),gi.zone.cancelTask(gi)):Lt.apply(Z,Ei)})}Zone.__load_patch("legacy",Z=>{const se=Z[Zone.__symbol__("legacyPatch")];se&&se()}),Zone.__load_patch("timers",Z=>{const ye="clear";Wl(Z,"set",ye,"Timeout"),Wl(Z,"set",ye,"Interval"),Wl(Z,"set",ye,"Immediate")}),Zone.__load_patch("requestAnimationFrame",Z=>{Wl(Z,"request","cancel","AnimationFrame"),Wl(Z,"mozRequest","mozCancel","AnimationFrame"),Wl(Z,"webkitRequest","webkitCancel","AnimationFrame")}),Zone.__load_patch("blocking",(Z,se)=>{const ye=["alert","prompt","confirm"];for(let fe=0;fefunction(At,Lt){return se.current.run(ke,Z,Lt,tt)})}),Zone.__load_patch("EventTarget",(Z,se,ye)=>{(function Yl(Z,se){se.patchEventPrototype(Z,se)})(Z,ye),function wm(Z,se){if(Zone[se.symbol("patchEventTarget")])return;const{eventNames:ye,zoneSymbolEventNames:fe,TRUE_STR:be,FALSE_STR:ke,ZONE_SYMBOL_PREFIX:at}=se.getGlobalObjects();for(let At=0;At{Qd("MutationObserver"),Qd("WebKitMutationObserver")}),Zone.__load_patch("IntersectionObserver",(Z,se,ye)=>{Qd("IntersectionObserver")}),Zone.__load_patch("FileReader",(Z,se,ye)=>{Qd("FileReader")}),Zone.__load_patch("on_property",(Z,se,ye)=>{!function pf(Z,se){if(jh&&!df||Zone[Z.symbol("patchEvents")])return;const ye=se.__Zone_ignore_on_properties;let fe=[];if(Yd){const be=window;fe=fe.concat(["Document","SVGElement","Element","HTMLElement","HTMLBodyElement","HTMLMediaElement","HTMLFrameSetElement","HTMLFrameElement","HTMLIFrameElement","HTMLMarqueeElement","Worker"]);const ke=function ym(){try{const Z=Uh.navigator.userAgent;if(-1!==Z.indexOf("MSIE ")||-1!==Z.indexOf("Trident/"))return!0}catch{}return!1}()?[{target:be,ignoreProperties:["error"]}]:[];Eo(be,Xd(be),ye&&ye.concat(ke),Ud(be))}fe=fe.concat(["XMLHttpRequest","XMLHttpRequestEventTarget","IDBIndex","IDBRequest","IDBOpenDBRequest","IDBDatabase","IDBTransaction","IDBCursor","WebSocket"]);for(let be=0;be{!function Mm(Z,se){const{isBrowser:ye,isMix:fe}=se.getGlobalObjects();(ye||fe)&&Z.customElements&&"customElements"in Z&&se.patchCallbacks(se,Z.customElements,"customElements","define",["connectedCallback","disconnectedCallback","adoptedCallback","attributeChangedCallback"])}(Z,ye)}),Zone.__load_patch("XHR",(Z,se)=>{!function At(Lt){const ft=Lt.XMLHttpRequest;if(!ft)return;const Ei=ft.prototype;let gi=Ei[Ul],cr=Ei[Fh];if(!gi){const et=Lt.XMLHttpRequestEventTarget;if(et){const vi=et.prototype;gi=vi[Ul],cr=vi[Fh]}}const Oi="readystatechange",es="scheduled";function kr(et){const vi=et.data,Pt=vi.target;Pt[ke]=!1,Pt[tt]=!1;const ts=Pt[be];gi||(gi=Pt[Ul],cr=Pt[Fh]),ts&&cr.call(Pt,Oi,ts);const _o=Pt[be]=()=>{if(Pt.readyState===Pt.DONE)if(!vi.aborted&&Pt[ke]&&et.state===es){const Ur=Pt[se.__symbol__("loadfalse")];if(0!==Pt.status&&Ur&&Ur.length>0){const Do=et.invoke;et.invoke=function(){const Ls=Pt[se.__symbol__("loadfalse")];for(let jr=0;jrfunction(et,vi){return et[fe]=0==vi[2],et[at]=vi[1],_n.apply(et,vi)}),Zr=Ji("fetchTaskAborting"),ki=Ji("fetchTaskScheduling"),lt=Ka(Ei,"send",()=>function(et,vi){if(!0===se.current[ki]||et[fe])return lt.apply(et,vi);{const Pt={target:et,url:et[at],isPeriodic:!1,args:vi,aborted:!1},ts=gm("XMLHttpRequest.send",Wt,Pt,kr,ct);et&&!0===et[tt]&&!Pt.aborted&&ts.state===es&&ts.invoke()}}),dr=Ka(Ei,"abort",()=>function(et,vi){const Pt=function ti(et){return et[ye]}(et);if(Pt&&"string"==typeof Pt.type){if(null==Pt.cancelFn||Pt.data&&Pt.data.aborted)return;Pt.zone.cancelTask(Pt)}else if(!0===se.current[Zr])return dr.apply(et,vi)})}(Z);const ye=Ji("xhrTask"),fe=Ji("xhrSync"),be=Ji("xhrListener"),ke=Ji("xhrScheduled"),at=Ji("xhrURL"),tt=Ji("xhrErrorBeforeScheduled")}),Zone.__load_patch("geolocation",Z=>{Z.navigator&&Z.navigator.geolocation&&function mm(Z,se){const ye=Z.constructor.name;for(let fe=0;fe{const At=function(){return tt.apply(this,Wd(arguments,ye+"."+be))};return Sa(At,tt),At})(ke)}}}(Z.navigator.geolocation,["getCurrentPosition","watchPosition"])}),Zone.__load_patch("PromiseRejectionEvent",(Z,se)=>{function ye(fe){return function(be){Cb(Z,fe).forEach(at=>{const tt=Z.PromiseRejectionEvent;if(tt){const At=new tt(fe,{promise:be.promise,reason:be.rejection});at.invoke(At)}})}}Z.PromiseRejectionEvent&&(se[Ji("unhandledPromiseRejectionHandler")]=ye("unhandledrejection"),se[Ji("rejectionHandledHandler")]=ye("rejectionhandled"))}),Zone.__load_patch("queueMicrotask",(Z,se,ye)=>{!function ff(Z,se){se.patchMethod(Z,"queueMicrotask",ye=>function(fe,be){Zone.current.scheduleMicroTask("queueMicrotask",be[0])})}(Z,ye)})}},_l=>{_l(_l.s=51)}]); \ No newline at end of file diff --git a/ej2-angular/samples/diagram/layers/layers-cs6/index.html b/ej2-angular/samples/diagram/layers/layers-cs6/index.html index 6f149fded2..166d00b0dc 100644 --- a/ej2-angular/samples/diagram/layers/layers-cs6/index.html +++ b/ej2-angular/samples/diagram/layers/layers-cs6/index.html @@ -19,5 +19,5 @@
Loading....
- + \ No newline at end of file diff --git a/ej2-angular/samples/diagram/layers/layers-cs6/main.76de9ac9d4107d88.js b/ej2-angular/samples/diagram/layers/layers-cs6/main.76de9ac9d4107d88.js new file mode 100644 index 0000000000..4de8b58f29 --- /dev/null +++ b/ej2-angular/samples/diagram/layers/layers-cs6/main.76de9ac9d4107d88.js @@ -0,0 +1 @@ +"use strict";(self.webpackChunksyncfusion_component=self.webpackChunksyncfusion_component||[]).push([[179],{51:(Wl,Vd,Wd)=>{let $r=null,_h=1;const Ts=Symbol("SIGNAL");function Wi(n){const t=$r;return $r=n,t}function gn(n){if((!Wh(n)||n.dirty)&&(n.dirty||n.lastCleanEpoch!==_h)){if(!n.producerMustRecompute(n)&&!Vh(n))return n.dirty=!1,void(n.lastCleanEpoch=_h);n.producerRecomputeValue(n),n.dirty=!1,n.lastCleanEpoch=_h}}function Vh(n){Gl(n);for(let t=0;t0}function Gl(n){n.producerNode??=[],n.producerIndexOfThis??=[],n.producerLastReadVersion??=[]}let $d=null;function Eo(n){return"function"==typeof n}function Zd(n){const e=n(i=>{Error.call(i),i.stack=(new Error).stack});return e.prototype=Object.create(Error.prototype),e.prototype.constructor=e,e}const pp=Zd(n=>function(e){n(this),this.message=e?`${e.length} errors occurred during unsubscription:\n${e.map((i,r)=>`${r+1}) ${i.toString()}`).join("\n ")}`:"",this.name="UnsubscriptionError",this.errors=e});function gp(n,t){if(n){const e=n.indexOf(t);0<=e&&n.splice(e,1)}}class As{constructor(t){this.initialTeardown=t,this.closed=!1,this._parentage=null,this._finalizers=null}unsubscribe(){let t;if(!this.closed){this.closed=!0;const{_parentage:e}=this;if(e)if(this._parentage=null,Array.isArray(e))for(const s of e)s.remove(this);else e.remove(this);const{initialTeardown:i}=this;if(Eo(i))try{i()}catch(s){t=s instanceof pp?s.errors:[s]}const{_finalizers:r}=this;if(r){this._finalizers=null;for(const s of r)try{Dm(s)}catch(o){t=t??[],o instanceof pp?t=[...t,...o.errors]:t.push(o)}}if(t)throw new pp(t)}}add(t){var e;if(t&&t!==this)if(this.closed)Dm(t);else{if(t instanceof As){if(t.closed||t._hasParent(this))return;t._addParent(this)}(this._finalizers=null!==(e=this._finalizers)&&void 0!==e?e:[]).push(t)}}_hasParent(t){const{_parentage:e}=this;return e===t||Array.isArray(e)&&e.includes(t)}_addParent(t){const{_parentage:e}=this;this._parentage=Array.isArray(e)?(e.push(t),e):e?[e,t]:t}_removeParent(t){const{_parentage:e}=this;e===t?this._parentage=null:Array.isArray(e)&&gp(e,t)}remove(t){const{_finalizers:e}=this;e&&gp(e,t),t instanceof As&&t._removeParent(this)}}As.EMPTY=(()=>{const n=new As;return n.closed=!0,n})();const Xl=As.EMPTY;function Em(n){return n instanceof As||n&&"closed"in n&&Eo(n.remove)&&Eo(n.add)&&Eo(n.unsubscribe)}function Dm(n){Eo(n)?n():n.unsubscribe()}const ql={onUnhandledError:null,onStoppedNotification:null,Promise:void 0,useDeprecatedSynchronousErrorHandling:!1,useDeprecatedNextContext:!1},Z={setTimeout(n,t,...e){const{delegate:i}=Z;return i?.setTimeout?i.setTimeout(n,t,...e):setTimeout(n,t,...e)},clearTimeout(n){const{delegate:t}=Z;return(t?.clearTimeout||clearTimeout)(n)},delegate:void 0};function ye(){}const pe=at("C",void 0,void 0);function at(n,t,e){return{kind:n,value:t,error:e}}let tt=null;function At(n){if(ql.useDeprecatedSynchronousErrorHandling){const t=!tt;if(t&&(tt={errorThrown:!1,error:null}),n(),t){const{errorThrown:e,error:i}=tt;if(tt=null,e)throw i}}else n()}class pt extends As{constructor(t){super(),this.isStopped=!1,t?(this.destination=t,Em(t)&&t.add(this)):this.destination=Wt}static create(t,e,i){return new cr(t,e,i)}next(t){this.isStopped?Pr(function ke(n){return at("N",n,void 0)}(t),this):this._next(t)}error(t){this.isStopped?Pr(function be(n){return at("E",void 0,n)}(t),this):(this.isStopped=!0,this._error(t))}complete(){this.isStopped?Pr(pe,this):(this.isStopped=!0,this._complete())}unsubscribe(){this.closed||(this.isStopped=!0,super.unsubscribe(),this.destination=null)}_next(t){this.destination.next(t)}_error(t){try{this.destination.error(t)}finally{this.unsubscribe()}}_complete(){try{this.destination.complete()}finally{this.unsubscribe()}}}const Di=Function.prototype.bind;function ni(n,t){return Di.call(n,t)}class mi{constructor(t){this.partialObserver=t}next(t){const{partialObserver:e}=this;if(e.next)try{e.next(t)}catch(i){ki(i)}}error(t){const{partialObserver:e}=this;if(e.error)try{e.error(t)}catch(i){ki(i)}else ki(t)}complete(){const{partialObserver:t}=this;if(t.complete)try{t.complete()}catch(e){ki(e)}}}class cr extends pt{constructor(t,e,i){let r;if(super(),Eo(t)||!t)r={next:t??void 0,error:e??void 0,complete:i??void 0};else{let s;this&&ql.useDeprecatedNextContext?(s=Object.create(t),s.unsubscribe=()=>this.unsubscribe(),r={next:t.next&&ni(t.next,s),error:t.error&&ni(t.error,s),complete:t.complete&&ni(t.complete,s)}):r=t}this.destination=new mi(r)}}function ki(n){ql.useDeprecatedSynchronousErrorHandling?function Lt(n){ql.useDeprecatedSynchronousErrorHandling&&tt&&(tt.errorThrown=!0,tt.error=n)}(n):function se(n){Z.setTimeout(()=>{const{onUnhandledError:t}=ql;if(!t)throw n;t(n)})}(n)}function Pr(n,t){const{onStoppedNotification:e}=ql;e&&Z.setTimeout(()=>e(n,t))}const Wt={closed:!0,next:ye,error:function is(n){throw n},complete:ye},ct="function"==typeof Symbol&&Symbol.observable||"@@observable";function jn(n){return n}let Pi=(()=>{class n{constructor(e){e&&(this._subscribe=e)}lift(e){const i=new n;return i.source=this,i.operator=e,i}subscribe(e,i,r){const s=function et(n){return n&&n instanceof pt||function dr(n){return n&&Eo(n.next)&&Eo(n.error)&&Eo(n.complete)}(n)&&Em(n)}(e)?e:new cr(e,i,r);return At(()=>{const{operator:o,source:a}=this;s.add(o?o.call(s,a):a?this._subscribe(s):this._trySubscribe(s))}),s}_trySubscribe(e){try{return this._subscribe(e)}catch(i){e.error(i)}}forEach(e,i){return new(i=lt(i))((r,s)=>{const o=new cr({next:a=>{try{e(a)}catch(l){s(l),o.unsubscribe()}},error:s,complete:r});this.subscribe(o)})}_subscribe(e){var i;return null===(i=this.source)||void 0===i?void 0:i.subscribe(e)}[ct](){return this}pipe(...e){return function Zr(n){return 0===n.length?jn:1===n.length?n[0]:function(e){return n.reduce((i,r)=>r(i),e)}}(e)(this)}toPromise(e){return new(e=lt(e))((i,r)=>{let s;this.subscribe(o=>s=o,o=>r(o),()=>i(s))})}}return n.create=t=>new n(t),n})();function lt(n){var t;return null!==(t=n??ql.Promise)&&void 0!==t?t:Promise}const yi=Zd(n=>function(){n(this),this.name="ObjectUnsubscribedError",this.message="object unsubscribed"});let Pt=(()=>{class n extends Pi{constructor(){super(),this.closed=!1,this.currentObservers=null,this.observers=[],this.isStopped=!1,this.hasError=!1,this.thrownError=null}lift(e){const i=new rs(this,this);return i.operator=e,i}_throwIfClosed(){if(this.closed)throw new yi}next(e){At(()=>{if(this._throwIfClosed(),!this.isStopped){this.currentObservers||(this.currentObservers=Array.from(this.observers));for(const i of this.currentObservers)i.next(e)}})}error(e){At(()=>{if(this._throwIfClosed(),!this.isStopped){this.hasError=this.isStopped=!0,this.thrownError=e;const{observers:i}=this;for(;i.length;)i.shift().error(e)}})}complete(){At(()=>{if(this._throwIfClosed(),!this.isStopped){this.isStopped=!0;const{observers:e}=this;for(;e.length;)e.shift().complete()}})}unsubscribe(){this.isStopped=this.closed=!0,this.observers=this.currentObservers=null}get observed(){var e;return(null===(e=this.observers)||void 0===e?void 0:e.length)>0}_trySubscribe(e){return this._throwIfClosed(),super._trySubscribe(e)}_subscribe(e){return this._throwIfClosed(),this._checkFinalizedStatuses(e),this._innerSubscribe(e)}_innerSubscribe(e){const{hasError:i,isStopped:r,observers:s}=this;return i||r?Xl:(this.currentObservers=null,s.push(e),new As(()=>{this.currentObservers=null,gp(s,e)}))}_checkFinalizedStatuses(e){const{hasError:i,thrownError:r,isStopped:s}=this;i?e.error(r):s&&e.complete()}asObservable(){const e=new Pi;return e.source=this,e}}return n.create=(t,e)=>new rs(t,e),n})();class rs extends Pt{constructor(t,e){super(),this.destination=t,this.source=e}next(t){var e,i;null===(i=null===(e=this.destination)||void 0===e?void 0:e.next)||void 0===i||i.call(e,t)}error(t){var e,i;null===(i=null===(e=this.destination)||void 0===e?void 0:e.error)||void 0===i||i.call(e,t)}complete(){var t,e;null===(e=null===(t=this.destination)||void 0===t?void 0:t.complete)||void 0===e||e.call(t)}_subscribe(t){var e,i;return null!==(i=null===(e=this.source)||void 0===e?void 0:e.subscribe(t))&&void 0!==i?i:Xl}}class _o extends Pt{constructor(t){super(),this._value=t}get value(){return this.getValue()}_subscribe(t){const e=super._subscribe(t);return!e.closed&&t.next(this._value),e}getValue(){const{hasError:t,thrownError:e,_value:i}=this;if(t)throw e;return this._throwIfClosed(),i}next(t){super.next(this._value=t)}}class Ls extends pt{constructor(t,e,i,r,s,o){super(t),this.onFinalize=s,this.shouldUnsubscribe=o,this._next=e?function(a){try{e(a)}catch(l){t.error(l)}}:super._next,this._error=r?function(a){try{r(a)}catch(l){t.error(l)}finally{this.unsubscribe()}}:super._error,this._complete=i?function(){try{i()}catch(a){t.error(a)}finally{this.unsubscribe()}}:super._complete}unsubscribe(){var t;if(!this.shouldUnsubscribe||this.shouldUnsubscribe()){const{closed:e}=this;super.unsubscribe(),!e&&(null===(t=this.onFinalize)||void 0===t||t.call(this))}}}function jr(n,t){return function Ur(n){return t=>{if(function cn(n){return Eo(n?.lift)}(t))return t.lift(function(e){try{return n(e,this)}catch(i){this.error(i)}});throw new TypeError("Unable to lift unknown Observable type")}}((e,i)=>{let r=0;e.subscribe(function Do(n,t,e,i,r){return new Ls(n,t,e,i,r)}(i,s=>{i.next(n.call(t,s,r++))}))})}class F extends Error{constructor(t,e){super(function ae(n,t){return`NG0${Math.abs(n)}${t?": "+t:""}`}(t,e)),this.code=t}}function Xe(n){for(let t in n)if(n[t]===Xe)return t;throw Error("Could not find renamed property on target object.")}function mt(n,t){for(const e in t)t.hasOwnProperty(e)&&!n.hasOwnProperty(e)&&(n[e]=t[e])}function dt(n){if("string"==typeof n)return n;if(Array.isArray(n))return"["+n.map(dt).join(", ")+"]";if(null==n)return""+n;if(n.overriddenName)return`${n.overriddenName}`;if(n.name)return`${n.name}`;const t=n.toString();if(null==t)return""+t;const e=t.indexOf("\n");return-1===e?t:t.substring(0,e)}function qt(n,t){return null==n||""===n?null===t?"":t:null==t||""===t?n:n+" "+t}const ur=Xe({__forward_ref__:Xe});function ir(n){return n.__forward_ref__=ir,n.toString=function(){return dt(this())},n}function vt(n){return function Tn(n){return"function"==typeof n&&n.hasOwnProperty(ur)&&n.__forward_ref__===ir}(n)?n():n}function $l(n){return n&&!!n.\u0275providers}const Zl=Xe({\u0275cmp:Xe}),Jd=Xe({\u0275dir:Xe}),vp=Xe({\u0275pipe:Xe}),Uo=Xe({\u0275fac:Xe}),jo=Xe({__NG_ELEMENT_ID__:Xe}),mp=Xe({__NG_ENV_ID__:Xe});function Ri(n){return"function"==typeof n?n.name||n.toString():"object"==typeof n&&null!=n&&"function"==typeof n.type?n.type.name||n.type.toString():function Nt(n){return"string"==typeof n?n:null==n?"":String(n)}(n)}function Lb(n,t){throw new F(-201,!1)}function so(n,t){null==n&&function zt(n,t,e,i){throw new Error(`ASSERTION ERROR: ${n}`+(null==i?"":` [Expected=> ${e} ${i} ${t} <=Actual]`))}(t,n,null,"!=")}function Yi(n){return{token:n.token,providedIn:n.providedIn||null,factory:n.factory,value:void 0}}function yp(n){return{providers:n.providers||[],imports:n.imports||[]}}function xm(n){return zT(n,Am)||zT(n,RT)}function zT(n,t){return n.hasOwnProperty(t)?n[t]:null}function Tm(n){return n&&(n.hasOwnProperty(Nb)||n.hasOwnProperty(x_))?n[Nb]:null}const Am=Xe({\u0275prov:Xe}),Nb=Xe({\u0275inj:Xe}),RT=Xe({ngInjectableDef:Xe}),x_=Xe({ngInjectorDef:Xe});var xi=function(n){return n[n.Default=0]="Default",n[n.Host=1]="Host",n[n.Self=2]="Self",n[n.SkipSelf=4]="SkipSelf",n[n.Optional=8]="Optional",n}(xi||{});let Ob;function oo(n){const t=Ob;return Ob=n,t}function BT(n,t,e){const i=xm(n);return i&&"root"==i.providedIn?void 0===i.value?i.value=i.factory():i.value:e&xi.Optional?null:void 0!==t?t:void Lb()}const rr=globalThis;class Ht{constructor(t,e){this._desc=t,this.ngMetadataName="InjectionToken",this.\u0275prov=void 0,"number"==typeof e?this.__NG_ELEMENT_ID__=e:void 0!==e&&(this.\u0275prov=Yi({token:this,providedIn:e.providedIn||"root",factory:e.factory}))}get multi(){return this}toString(){return`InjectionToken ${this._desc}`}}const Sp={},Hb="__NG_DI_FLAG__",Lm="ngTempTokenPath",L_=/\n/gm,_T="__source";let eu;function Gh(n){const t=eu;return eu=n,t}function k_(n,t=xi.Default){if(void 0===eu)throw new F(-203,!1);return null===eu?BT(n,void 0,t):eu.get(n,t&xi.Optional?null:void 0,t)}function _i(n,t=xi.Default){return(function HT(){return Ob}()||k_)(vt(n),t)}function Hi(n,t=xi.Default){return _i(n,Nm(t))}function Nm(n){return typeof n>"u"||"number"==typeof n?n:0|(n.optional&&8)|(n.host&&1)|(n.self&&2)|(n.skipSelf&&4)}function Bb(n){const t=[];for(let e=0;et){o=s-1;break}}}for(;ss?"":r[d+1].toLowerCase();const f=8&i?u:null;if(f&&-1!==jT(f,h,0)||2&i&&h!==u){if(Ma(i))return!1;o=!0}}}}else{if(!o&&!Ma(i)&&!Ma(l))return!1;if(o&&Ma(l))continue;o=!1,i=l|1&i}}return Ma(i)||o}function Ma(n){return 0==(1&n)}function __(n,t,e,i){if(null===t)return-1;let r=0;if(i||!e){let s=!1;for(;r-1)for(e++;e0?'="'+a+'"':"")+"]"}else 8&i?r+="."+o:4&i&&(r+=" "+o);else""!==r&&!Ma(o)&&(t+=qT(s,r),r=""),i=o,s=s||!Ma(i);e++}return""!==r&&(t+=qT(s,r)),t}function _b(n){return Jl(()=>{const t=ZT(n),e={...t,decls:n.decls,vars:n.vars,template:n.template,consts:n.consts||null,ngContentSelectors:n.ngContentSelectors,onPush:n.changeDetection===Om.OnPush,directiveDefs:null,pipeDefs:null,dependencies:t.standalone&&n.dependencies||null,getStandaloneInjector:null,signals:n.signals??!1,data:n.data||{},encapsulation:n.encapsulation||ba.Emulated,styles:n.styles||Qi,_:null,schemas:n.schemas||null,tView:null,id:""};JT(e);const i=n.dependencies;return e.directiveDefs=Pm(i,!1),e.pipeDefs=Pm(i,!0),e.id=function Z_(n){let t=0;const e=[n.selectors,n.ngContentSelectors,n.hostVars,n.hostAttrs,n.consts,n.vars,n.decls,n.encapsulation,n.standalone,n.signals,n.exportAs,JSON.stringify(n.inputs),JSON.stringify(n.outputs),Object.getOwnPropertyNames(n.type.prototype),!!n.contentQueries,!!n.viewQuery].join("|");for(const r of e)t=Math.imul(31,t)+r.charCodeAt(0)<<0;return t+=2147483648,"c"+t}(e),e})}function X_(n){return di(n)||Wn(n)}function q_(n){return null!==n}function km(n){return Jl(()=>({type:n.type,bootstrap:n.bootstrap||Qi,declarations:n.declarations||Qi,imports:n.imports||Qi,exports:n.exports||Qi,transitiveCompileScopes:null,schemas:n.schemas||null,id:n.id||null}))}function $T(n,t){if(null==n)return rl;const e={};for(const i in n)if(n.hasOwnProperty(i)){const r=n[i];let s,o,a=Xh.None;Array.isArray(r)?(a=r[0],s=r[1],o=r[2]??s):(s=r,o=r),t?(e[s]=a!==Xh.None?[i,a]:i,t[s]=o):e[s]=i}return e}function nr(n){return Jl(()=>{const t=ZT(n);return JT(t),t})}function di(n){return n[Zl]||null}function Wn(n){return n[Jd]||null}function gs(n){return n[vp]||null}function ZT(n){const t={};return{type:n.type,providersResolver:null,factory:null,hostBindings:n.hostBindings||null,hostVars:n.hostVars||0,hostAttrs:n.hostAttrs||null,contentQueries:n.contentQueries||null,declaredInputs:t,inputTransforms:null,inputConfig:n.inputs||rl,exportAs:n.exportAs||null,standalone:!0===n.standalone,signals:!0===n.signals,selectors:n.selectors||Qi,viewQuery:n.viewQuery||null,features:n.features||null,setInput:null,findHostDirectiveDefs:null,hostDirectives:null,inputs:$T(n.inputs,t),outputs:$T(n.outputs),debugInfo:null}}function JT(n){n.features?.forEach(t=>t(n))}function Pm(n,t){if(!n)return null;const e=t?gs:X_;return()=>("function"==typeof n?n():n).map(i=>e(i)).filter(q_)}const Vr=0,Be=1,Ct=2,vn=3,wa=4,Os=5,Ca=6,tu=7,Er=8,Xs=9,Kl=10,Yt=11,Mp=12,KT=13,iu=14,Jr=15,wp=16,ru=17,nl=18,Cp=19,eA=20,qh=21,zm=22,Uc=23,jt=25,Ub=1,sl=7,nu=9,mn=10;var jb=function(n){return n[n.None=0]="None",n[n.HasTransplantedViews=2]="HasTransplantedViews",n}(jb||{});function ks(n){return Array.isArray(n)&&"object"==typeof n[Ub]}function Ps(n){return Array.isArray(n)&&!0===n[Ub]}function Vb(n){return 0!=(4&n.flags)}function jc(n){return n.componentOffset>-1}function Hm(n){return 1==(1&n.flags)}function Ea(n){return!!n.template}function Wb(n){return 0!=(512&n[Ct])}function Vc(n,t){return n.hasOwnProperty(Uo)?n[Uo]:null}class tU{constructor(t,e,i){this.previousValue=t,this.currentValue=e,this.firstChange=i}isFirstChange(){return this.firstChange}}function nA(n,t,e,i){null!==t?t.applyValueToInputSignal(t,i):n[e]=i}function sA(n){return n.type.prototype.ngOnChanges&&(n.setInput=rU),iU}function iU(){const n=aA(this),t=n?.current;if(t){const e=n.previous;if(e===rl)n.previous=t;else for(let i in t)e[i]=t[i];n.current=null,this.ngOnChanges(t)}}function rU(n,t,e,i,r){const s=this.declaredInputs[i],o=aA(n)||function nU(n,t){return n[oA]=t}(n,{previous:rl,current:null}),a=o.current||(o.current={}),l=o.previous,h=l[s];a[s]=new tU(h&&h.currentValue,e,l===rl),nA(n,t,r,e)}const oA="__ngSimpleChanges__";function aA(n){return n[oA]||null}const ol=function(n,t,e){};let cA=!1;function fr(n){for(;Array.isArray(n);)n=n[Vr];return n}function qs(n,t){return fr(t[n.index])}function xp(n,t){return n.data[t]}function To(n,t){const e=t[n];return ks(e)?e:e[Vr]}function qb(n){return 128==(128&n[Ct])}function al(n,t){return null==t?null:n[t]}function dA(n){n[ru]=0}function cU(n){1024&n[Ct]||(n[Ct]|=1024,qb(n)&&Tp(n))}function fA(n){return 9216&n[Ct]||n[Uc]?.dirty}function $b(n){fA(n)?Tp(n):64&n[Ct]&&(function oU(){return cA}()?(n[Ct]|=1024,Tp(n)):n[Kl].changeDetectionScheduler?.notify())}function Tp(n){n[Kl].changeDetectionScheduler?.notify();let t=Wc(n);for(;null!==t&&!(8192&t[Ct])&&(t[Ct]|=8192,qb(t));)t=Wc(t)}function Wc(n){const t=n[vn];return Ps(t)?t[vn]:t}const Rt={lFrame:wA(null),bindingsEnabled:!0,skipHydrationRootTNode:null};function gA(){return Rt.bindingsEnabled}function Se(){return Rt.lFrame.lView}function Ti(){return Rt.lFrame.tView}function pr(){let n=vA();for(;null!==n&&64===n.type;)n=n.parent;return n}function vA(){return Rt.lFrame.currentTNode}function ll(n,t){const e=Rt.lFrame;e.currentTNode=n,e.isParent=t}function Jb(){return Rt.lFrame.isParent}function wU(n,t){const e=Rt.lFrame;e.bindingIndex=e.bindingRootIndex=n,e1(t)}function e1(n){Rt.lFrame.currentDirectiveIndex=n}function IA(){return Rt.lFrame.currentQueryIndex}function i1(n){Rt.lFrame.currentQueryIndex=n}function EU(n){const t=n[Be];return 2===t.type?t.declTNode:1===t.type?n[Os]:null}function bA(n,t,e){if(e&xi.SkipSelf){let r=t,s=n;for(;!(r=r.parent,null!==r||e&xi.Host||(r=EU(s),null===r||(s=s[iu],10&r.type))););if(null===r)return!1;t=r,n=s}const i=Rt.lFrame=MA();return i.currentTNode=t,i.lView=n,!0}function r1(n){const t=MA(),e=n[Be];Rt.lFrame=t,t.currentTNode=e.firstChild,t.lView=n,t.tView=e,t.contextLView=n,t.bindingIndex=e.bindingStartIndex,t.inI18n=!1}function MA(){const n=Rt.lFrame,t=null===n?null:n.child;return null===t?wA(n):t}function wA(n){const t={currentTNode:null,isParent:!0,lView:null,tView:null,selectedIndex:-1,contextLView:null,elementDepthCount:0,currentNamespace:null,currentDirectiveIndex:-1,bindingRootIndex:-1,bindingIndex:-1,currentQueryIndex:0,parent:n,child:null,inI18n:!1};return null!==n&&(n.child=t),t}function CA(){const n=Rt.lFrame;return Rt.lFrame=n.parent,n.currentTNode=null,n.lView=null,n}const EA=CA;function n1(){const n=CA();n.isParent=!0,n.tView=null,n.selectedIndex=-1,n.contextLView=null,n.elementDepthCount=0,n.currentDirectiveIndex=-1,n.currentNamespace=null,n.bindingRootIndex=-1,n.bindingIndex=-1,n.currentQueryIndex=0}function zs(){return Rt.lFrame.selectedIndex}function Yc(n){Rt.lFrame.selectedIndex=n}let xA=!0;function _m(){return xA}function $h(n){xA=n}function Um(n,t){for(let e=t.directiveStart,i=t.directiveEnd;e=i)break}else t[l]<0&&(n[ru]+=65536),(a>14>16&&(3&n[Ct])===t&&(n[Ct]+=16384,AA(a,s)):AA(a,s)}const au=-1;class Lp{constructor(t,e,i){this.factory=t,this.resolving=!1,this.canSeeViewProviders=e,this.injectImpl=i}}function a1(n){return n!==au}function Np(n){return 32767&n}function Op(n,t){let e=function HU(n){return n>>16}(n),i=t;for(;e>0;)i=i[iu],e--;return i}let l1=!0;function Wm(n){const t=l1;return l1=n,t}const LA=255,NA=5;let BU=0;const cl={};function Ym(n,t){const e=OA(n,t);if(-1!==e)return e;const i=t[Be];i.firstCreatePass&&(n.injectorIndex=t.length,h1(i.data,n),h1(t,null),h1(i.blueprint,null));const r=Qm(n,t),s=n.injectorIndex;if(a1(r)){const o=Np(r),a=Op(r,t),l=a[Be].data;for(let h=0;h<8;h++)t[s+h]=a[o+h]|l[o+h]}return t[s+8]=r,s}function h1(n,t){n.push(0,0,0,0,0,0,0,0,t)}function OA(n,t){return-1===n.injectorIndex||n.parent&&n.parent.injectorIndex===n.injectorIndex||null===t[n.injectorIndex+8]?-1:n.injectorIndex}function Qm(n,t){if(n.parent&&-1!==n.parent.injectorIndex)return n.parent.injectorIndex;let e=0,i=null,r=t;for(;null!==r;){if(i=FA(r),null===i)return au;if(e++,r=r[iu],-1!==i.injectorIndex)return i.injectorIndex|e<<16}return au}function c1(n,t,e){!function FU(n,t,e){let i;"string"==typeof e?i=e.charCodeAt(0)||0:e.hasOwnProperty(jo)&&(i=e[jo]),null==i&&(i=e[jo]=BU++);const r=i&LA;t.data[n+(r>>NA)]|=1<=0?t&LA:VU:t}(e);if("function"==typeof s){if(!bA(t,n,i))return i&xi.Host?kA(r,0,i):PA(t,e,i,r);try{let o;if(o=s(i),null!=o||i&xi.Optional)return o;Lb()}finally{EA()}}else if("number"==typeof s){let o=null,a=OA(n,t),l=au,h=i&xi.Host?t[Jr][Os]:null;for((-1===a||i&xi.SkipSelf)&&(l=-1===a?Qm(n,t):t[a+8],l!==au&&BA(i,!1)?(o=t[Be],a=Np(l),t=Op(l,t)):a=-1);-1!==a;){const c=t[Be];if(HA(s,a,c.data)){const d=UU(a,t,e,o,i,h);if(d!==cl)return d}l=t[a+8],l!==au&&BA(i,t[Be].data[a+8]===h)&&HA(s,a,t)?(o=c,a=Np(l),t=Op(l,t)):a=-1}}return r}function UU(n,t,e,i,r,s){const o=t[Be],a=o.data[n+8],c=Gm(a,o,e,null==i?jc(a)&&l1:i!=o&&0!=(3&a.type),r&xi.Host&&s===a);return null!==c?Qc(t,o,c,a):cl}function Gm(n,t,e,i,r){const s=n.providerIndexes,o=t.data,a=1048575&s,l=n.directiveStart,c=s>>20,u=r?a+c:n.directiveEnd;for(let f=i?a:a+c;f=l&&p.type===e)return f}if(r){const f=o[l];if(f&&Ea(f)&&f.type===e)return l}return null}function Qc(n,t,e,i){let r=n[e];const s=t.data;if(function kU(n){return n instanceof Lp}(r)){const o=r;o.resolving&&function Vo(n,t){const e=t?`. Dependency path: ${t.join(" > ")} > ${n}`:"";throw new F(-200,`Circular dependency in DI detected for ${n}${e}`)}(Ri(s[e]));const a=Wm(o.canSeeViewProviders);o.resolving=!0;const h=o.injectImpl?oo(o.injectImpl):null;bA(n,i,xi.Default);try{r=n[e]=o.factory(void 0,s,n,i),t.firstCreatePass&&e>=i.directiveStart&&function NU(n,t,e){const{ngOnChanges:i,ngOnInit:r,ngDoCheck:s}=t.type.prototype;if(i){const o=sA(t);(e.preOrderHooks??=[]).push(n,o),(e.preOrderCheckHooks??=[]).push(n,o)}r&&(e.preOrderHooks??=[]).push(0-n,r),s&&((e.preOrderHooks??=[]).push(n,s),(e.preOrderCheckHooks??=[]).push(n,s))}(e,s[e],t)}finally{null!==h&&oo(h),Wm(a),o.resolving=!1,EA()}}return r}function HA(n,t,e){return!!(e[t+(n>>NA)]&1<Array.isArray(e)?gu(e,t):t(e))}function UA(n,t,e){t>=n.length?n.push(e):n.splice(t,0,e)}function Xm(n,t){return t>=n.length-1?n.pop():n.splice(t,1)[0]}const yu=new Ht(""),GA=new Ht("",-1),I1=new Ht("");class Jm{get(t,e=Sp){if(e===Sp){const i=new Error(`NullInjectorError: No provider for ${dt(t)}!`);throw i.name="NullInjectorError",i}return e}}function fj(...n){return{\u0275providers:XA(0,n),\u0275fromNgModule:!0}}function XA(n,...t){const e=[],i=new Set;let r;const s=o=>{e.push(o)};return gu(t,o=>{const a=o;Km(a,s,[],i)&&(r||=[],r.push(a))}),void 0!==r&&qA(r,s),e}function qA(n,t){for(let e=0;e{t(s,i)})}}function Km(n,t,e,i){if(!(n=vt(n)))return!1;let r=null,s=Tm(n);const o=!s&&di(n);if(s||o){if(o&&!o.standalone)return!1;r=n}else{const l=n.ngModule;if(s=Tm(l),!s)return!1;r=l}const a=i.has(r);if(o){if(a)return!1;if(i.add(r),o.dependencies){const l="function"==typeof o.dependencies?o.dependencies():o.dependencies;for(const h of l)Km(h,t,e,i)}}else{if(!s)return!1;{if(null!=s.imports&&!a){let h;i.add(r);try{gu(s.imports,c=>{Km(c,t,e,i)&&(h||=[],h.push(c))})}finally{}void 0!==h&&qA(h,t)}if(!a){const h=Vc(r)||(()=>new r);t({provide:r,useFactory:h,deps:Qi},r),t({provide:I1,useValue:r,multi:!0},r),t({provide:yu,useValue:()=>_i(r),multi:!0},r)}const l=s.providers;if(null!=l&&!a){const h=n;M1(l,c=>{t(c,h)})}}}return r!==n&&void 0!==n.providers}function M1(n,t){for(let e of n)$l(e)&&(e=e.\u0275providers),Array.isArray(e)?M1(e,t):t(e)}const pj=Xe({provide:String,useValue:Xe});function w1(n){return null!==n&&"object"==typeof n&&pj in n}function Gc(n){return"function"==typeof n}const C1=new Ht(""),ey={},vj={};let E1;function ty(){return void 0===E1&&(E1=new Jm),E1}class ih{}class Su extends ih{get destroyed(){return this._destroyed}constructor(t,e,i,r){super(),this.parent=e,this.source=i,this.scopes=r,this.records=new Map,this._ngOnDestroyHooks=new Set,this._onDestroyHooks=[],this._destroyed=!1,x1(t,o=>this.processProvider(o)),this.records.set(GA,Iu(void 0,this)),r.has("environment")&&this.records.set(ih,Iu(void 0,this));const s=this.records.get(C1);null!=s&&"string"==typeof s.value&&this.scopes.add(s.value),this.injectorDefTypes=new Set(this.get(I1,Qi,xi.Self))}destroy(){this.assertNotDestroyed(),this._destroyed=!0;try{for(const e of this._ngOnDestroyHooks)e.ngOnDestroy();const t=this._onDestroyHooks;this._onDestroyHooks=[];for(const e of t)e()}finally{this.records.clear(),this._ngOnDestroyHooks.clear(),this.injectorDefTypes.clear()}}onDestroy(t){return this.assertNotDestroyed(),this._onDestroyHooks.push(t),()=>this.removeOnDestroy(t)}runInContext(t){this.assertNotDestroyed();const e=Gh(this),i=oo(void 0);try{return t()}finally{Gh(e),oo(i)}}get(t,e=Sp,i=xi.Default){if(this.assertNotDestroyed(),t.hasOwnProperty(mp))return t[mp](this);i=Nm(i);const s=Gh(this),o=oo(void 0);try{if(!(i&xi.SkipSelf)){let l=this.records.get(t);if(void 0===l){const h=function bj(n){return"function"==typeof n||"object"==typeof n&&n instanceof Ht}(t)&&xm(t);l=h&&this.injectableDefInScope(h)?Iu(D1(t),ey):null,this.records.set(t,l)}if(null!=l)return this.hydrate(t,l)}return(i&xi.Self?ty():this.parent).get(t,e=i&xi.Optional&&e===Sp?null:e)}catch(a){if("NullInjectorError"===a.name){if((a[Lm]=a[Lm]||[]).unshift(dt(t)),s)throw a;return function z_(n,t,e,i){const r=n[Lm];throw t[_T]&&r.unshift(t[_T]),n.message=function R_(n,t,e,i=null){n=n&&"\n"===n.charAt(0)&&"\u0275"==n.charAt(1)?n.slice(2):n;let r=dt(t);if(Array.isArray(t))r=t.map(dt).join(" -> ");else if("object"==typeof t){let s=[];for(let o in t)if(t.hasOwnProperty(o)){let a=t[o];s.push(o+":"+("string"==typeof a?JSON.stringify(a):dt(a)))}r=`{${s.join(", ")}}`}return`${e}${i?"("+i+")":""}[${r}]: ${n.replace(L_,"\n ")}`}("\n"+n.message,r,e,i),n.ngTokenPath=r,n[Lm]=null,n}(a,t,"R3InjectorError",this.source)}throw a}finally{oo(o),Gh(s)}}resolveInjectorInitializers(){const t=Gh(this),e=oo(void 0);try{const r=this.get(yu,Qi,xi.Self);for(const s of r)s()}finally{Gh(t),oo(e)}}toString(){const t=[],e=this.records;for(const i of e.keys())t.push(dt(i));return`R3Injector[${t.join(", ")}]`}assertNotDestroyed(){if(this._destroyed)throw new F(205,!1)}processProvider(t){let e=Gc(t=vt(t))?t:vt(t&&t.provide);const i=function yj(n){return w1(n)?Iu(void 0,n.useValue):Iu(JA(n),ey)}(t);if(!Gc(t)&&!0===t.multi){let r=this.records.get(e);r||(r=Iu(void 0,ey,!0),r.factory=()=>Bb(r.multi),this.records.set(e,r)),e=t,r.multi.push(t)}this.records.set(e,i)}hydrate(t,e){return e.value===ey&&(e.value=vj,e.value=e.factory()),"object"==typeof e.value&&e.value&&function Ij(n){return null!==n&&"object"==typeof n&&"function"==typeof n.ngOnDestroy}(e.value)&&this._ngOnDestroyHooks.add(e.value),e.value}injectableDefInScope(t){if(!t.providedIn)return!1;const e=vt(t.providedIn);return"string"==typeof e?"any"===e||this.scopes.has(e):this.injectorDefTypes.has(e)}removeOnDestroy(t){const e=this._onDestroyHooks.indexOf(t);-1!==e&&this._onDestroyHooks.splice(e,1)}}function D1(n){const t=xm(n),e=null!==t?t.factory:Vc(n);if(null!==e)return e;if(n instanceof Ht)throw new F(204,!1);if(n instanceof Function)return function mj(n){if(n.length>0)throw new F(204,!1);const e=function D_(n){return n&&(n[Am]||n[RT])||null}(n);return null!==e?()=>e.factory(n):()=>new n}(n);throw new F(204,!1)}function JA(n,t,e){let i;if(Gc(n)){const r=vt(n);return Vc(r)||D1(r)}if(w1(n))i=()=>vt(n.useValue);else if(function ZA(n){return!(!n||!n.useFactory)}(n))i=()=>n.useFactory(...Bb(n.deps||[]));else if(function $A(n){return!(!n||!n.useExisting)}(n))i=()=>_i(vt(n.useExisting));else{const r=vt(n&&(n.useClass||n.provide));if(!function Sj(n){return!!n.deps}(n))return Vc(r)||D1(r);i=()=>new r(...Bb(n.deps))}return i}function Iu(n,t,e=!1){return{factory:n,value:t,multi:e?[]:void 0}}function x1(n,t){for(const e of n)Array.isArray(e)?x1(e,t):e&&$l(e)?x1(e.\u0275providers,t):t(e)}function iL(n,t=null,e=null,i){const r=function rL(n,t=null,e=null,i,r=new Set){const s=[e||Qi,fj(n)];return i=i||("object"==typeof n?void 0:dt(n)),new Su(s,t||ty(),i||null,r)}(n,t,e,i);return r.resolveInjectorInitializers(),r}let L1,Wo=(()=>{class n{static{this.THROW_IF_NOT_FOUND=Sp}static{this.NULL=new Jm}static create(e,i){if(Array.isArray(e))return iL({name:""},i,e,"");{const r=e.name??"";return iL({name:r},e.parent,e.providers,r)}}static{this.\u0275prov=Yi({token:n,providedIn:"any",factory:()=>_i(GA)})}static{this.__NG_ELEMENT_ID__=-1}}return n})();const N1=new Ht("",{providedIn:"root",factory:()=>Lj}),Lj="ng",sL=new Ht(""),bu=new Ht("",{providedIn:"platform",factory:()=>"unknown"}),oL=new Ht("",{providedIn:"root",factory:()=>function Zh(){if(void 0!==L1)return L1;if(typeof document<"u")return document;throw new F(210,!1)}().body?.querySelector("[ngCspNonce]")?.getAttribute("ngCspNonce")||null});function oy(n){return 128==(128&n.flags)}var ec=function(n){return n[n.Important=1]="Important",n[n.DashCase=2]="DashCase",n}(ec||{});const R1=new Map;let Vj=0;const B1="__ngContext__";function Rs(n,t){ks(t)?(n[B1]=t[Cp],function Yj(n){R1.set(n[Cp],n)}(t)):n[B1]=t}let F1;function _1(n,t){return F1(n,t)}function wu(n,t,e,i,r){if(null!=i){let s,o=!1;Ps(i)?s=i:ks(i)&&(o=!0,i=i[Vr]);const a=fr(i);0===n&&null!==e?null==r?TL(t,e,a):qc(t,e,a,r||null,!0):1===n&&null!==e?qc(t,e,a,r||null,!0):2===n?function fy(n,t,e){const i=dy(n,t);i&&function a6(n,t,e,i){n.removeChild(t,e,i)}(n,i,t,e)}(t,a,o):3===n&&t.destroyNode(a),null!=s&&function c6(n,t,e,i,r){const s=e[sl];s!==fr(e)&&wu(t,n,i,s,r);for(let a=mn;a0&&(n[e-1][wa]=i[wa]);const s=Xm(n,mn+t);!function e6(n,t){EL(n,t),t[Vr]=null,t[Os]=null}(i[Be],i);const o=s[nl];null!==o&&o.detachView(s[Be]),i[vn]=null,i[wa]=null,i[Ct]&=-129}return i}function cy(n,t){if(!(256&t[Ct])){const e=t[Yt];e.destroyNode&&py(n,t,e,3,null,null),function i6(n){let t=n[Mp];if(!t)return j1(n[Be],n);for(;t;){let e=null;if(ks(t))e=t[Mp];else{const i=t[mn];i&&(e=i)}if(!e){for(;t&&!t[wa]&&t!==n;)ks(t)&&j1(t[Be],t),t=t[vn];null===t&&(t=n),ks(t)&&j1(t[Be],t),e=t&&t[wa]}t=e}}(t)}}function j1(n,t){if(!(256&t[Ct])){t[Ct]&=-129,t[Ct]|=256,t[Uc]&&function Xd(n){if(Gl(n),Wh(n))for(let t=0;t=0?i[o]():i[-o].unsubscribe(),s+=2}else e[s].call(i[e[s+1]]);null!==i&&(t[tu]=null);const r=t[qh];if(null!==r){t[qh]=null;for(let s=0;s-1){const{encapsulation:s}=n.data[i.directiveStart+r];if(s===ba.None||s===ba.Emulated)return null}return qs(i,e)}}(n,t.parent,e)}function qc(n,t,e,i,r){n.insertBefore(t,e,i,r)}function TL(n,t,e){n.appendChild(t,e)}function AL(n,t,e,i,r){null!==i?qc(n,t,e,i,r):TL(n,t,e)}function dy(n,t){return n.parentNode(t)}let W1,OL=function NL(n,t,e){return 40&n.type?qs(n,e):null};function uy(n,t,e,i){const r=V1(n,i,t),s=t[Yt],a=function LL(n,t,e){return OL(n,t,e)}(i.parent||t[Os],i,t);if(null!=r)if(Array.isArray(e))for(let l=0;lnull;function oM(n,t,e=!1){return JL(n,t,e)}class G6{}class rN{}class q6{resolveComponentFactory(t){throw function X6(n){const t=Error(`No component factory found for ${dt(n)}.`);return t.ngComponent=n,t}(t)}}let wy=(()=>{class n{static{this.NULL=new q6}}return n})();function $6(){return Au(pr(),Se())}function Au(n,t){return new $c(qs(n,t))}let $c=(()=>{class n{constructor(e){this.nativeElement=e}static{this.__NG_ELEMENT_ID__=$6}}return n})();function Z6(n){return n instanceof $c?n.nativeElement:n}class sN{}let cM=(()=>{class n{constructor(){this.destroyNode=null}static{this.__NG_ELEMENT_ID__=()=>function J6(){const n=Se(),e=To(pr().index,n);return(ks(e)?e:n)[Yt]}()}}return n})(),K6=(()=>{class n{static{this.\u0275prov=Yi({token:n,providedIn:"root",factory:()=>null})}}return n})();const dM={};function Gp(n,t,e,i,r=!1){for(;null!==e;){const s=t[e.index];null!==s&&i.push(fr(s)),Ps(s)&&fN(s,i);const o=e.type;if(8&o)Gp(n,t,e.child,i);else if(32&o){const a=_1(e,t);let l;for(;l=a();)i.push(l)}else if(16&o){const a=PL(t,e);if(Array.isArray(a))i.push(...a);else{const l=Wc(t[Jr]);Gp(l[Be],l,a,i,!0)}}e=r?e.projectionNext:e.next}return i}function fN(n,t){for(let e=mn;e!1,producerRecomputeValue:()=>{},consumerMarkedDirty:()=>{},consumerOnSignalRead:()=>{},consumerIsAlwaysLive:!0,consumerMarkedDirty:n=>{Tp(n.lView)},consumerOnSignalRead(){this.lView[Uc]=this}};function gN(n){return mN(n[Mp])}function vN(n){return mN(n[wa])}function mN(n){for(;null!==n&&!Ps(n);)n=n[wa];return n}function pM(n){return n.ngOriginalError}class nh{constructor(){this._console=console}handleError(t){const e=this._findOriginalError(t);this._console.error("ERROR",t),e&&this._console.error("ORIGINAL ERROR",e)}_findOriginalError(t){let e=t&&pM(t);for(;e&&pM(e);)e=pM(e);return e||null}}const SN=new Ht("",{providedIn:"root",factory:()=>Hi(nh).handleError.bind(void 0)}),bN=new Ht("",{providedIn:"root",factory:()=>!1}),Qt={};function Xp(n=1){EN(Ti(),Se(),zs()+n,!1)}function EN(n,t,e,i){if(!i)if(3==(3&t[Ct])){const s=n.preOrderCheckHooks;null!==s&&jm(t,s,e)}else{const s=n.preOrderHooks;null!==s&&Vm(t,s,0,e)}Yc(e)}function Ot(n,t=xi.Default){const e=Se();return null===e?_i(n,t):zA(pr(),e,vt(n),t)}function DN(n,t,e,i,r,s){const o=Wi(null);try{let a=null;r&Xh.SignalBased&&(a=t[i][Ts]),null!==a&&void 0!==a.transformFn&&(s=a.transformFn(s)),r&Xh.HasDecoratorInputTransform&&(s=n.inputTransforms[i].call(t,s)),null!==n.setInput?n.setInput(t,a,s,e,i):nA(t,a,i,s)}finally{Wi(o)}}function xy(n,t,e,i,r,s,o,a,l,h,c){const d=t.blueprint.slice();return d[Vr]=r,d[Ct]=204|i,(null!==h||n&&2048&n[Ct])&&(d[Ct]|=2048),dA(d),d[vn]=d[iu]=n,d[Er]=e,d[Kl]=o||n&&n[Kl],d[Yt]=a||n&&n[Yt],d[Xs]=l||n&&n[Xs]||null,d[Os]=s,d[Cp]=function Wj(){return Vj++}(),d[Ca]=c,d[eA]=h,d[Jr]=2==t.type?n[Jr]:d,d}function Lu(n,t,e,i,r){let s=n.data[t];if(null===s)s=function gM(n,t,e,i,r){const s=vA(),o=Jb(),l=n.data[t]=function LV(n,t,e,i,r,s){let o=t?t.injectorIndex:-1,a=0;return function ou(){return null!==Rt.skipHydrationRootTNode}()&&(a|=128),{type:e,index:i,insertBeforeIndex:null,injectorIndex:o,directiveStart:-1,directiveEnd:-1,directiveStylingLast:-1,componentOffset:-1,propertyBindings:null,flags:a,providerIndexes:0,value:r,attrs:s,mergedAttrs:null,localNames:null,initialInputs:void 0,inputs:null,outputs:null,tView:null,next:null,prev:null,projectionNext:null,child:null,parent:t,projection:null,styles:null,stylesWithoutHost:null,residualStyles:void 0,classes:null,classesWithoutHost:null,residualClasses:void 0,classBindings:0,styleBindings:0}}(0,o?s:s&&s.parent,e,t,i,r);return null===n.firstChild&&(n.firstChild=l),null!==s&&(o?null==s.child&&null!==l.parent&&(s.child=l):null===s.next&&(s.next=l,l.prev=s)),l}(n,t,e,i,r),function MU(){return Rt.lFrame.inI18n}()&&(s.flags|=32);else if(64&s.type){s.type=e,s.value=i,s.attrs=r;const o=function Ap(){const n=Rt.lFrame,t=n.currentTNode;return n.isParent?t:t.parent}();s.injectorIndex=null===o?-1:o.injectorIndex}return ll(s,!0),s}function qp(n,t,e,i){if(0===e)return-1;const r=t.length;for(let s=0;sjt&&EN(n,t,jt,!1),ol(o?2:0,r),e(i,r)}finally{Yc(s),ol(o?3:1,r)}}function vM(n,t,e){if(Vb(t)){const i=Wi(null);try{const s=t.directiveEnd;for(let o=t.directiveStart;onull;function LN(n,t,e,i,r){for(let s in t){if(!t.hasOwnProperty(s))continue;const o=t[s];if(void 0===o)continue;i??={};let a,l=Xh.None;Array.isArray(o)?(a=o[0],l=o[1]):a=o;let h=s;if(null!==r){if(!r.hasOwnProperty(s))continue;h=r[s]}0===n?NN(i,e,h,a,l):NN(i,e,h,a)}return i}function NN(n,t,e,i,r){let s;n.hasOwnProperty(e)?(s=n[e]).push(t,i):s=n[e]=[t,i],void 0!==r&&s.push(r)}function ON(n,t,e,i,r,s){for(let h=0;h0;){const e=n[--t];if("number"==typeof e&&e<0)return e}return 0})(o)!=a&&o.push(a),o.push(e,i,s)}}(n,t,i,qp(n,e,r.hostVars,Qt),r)}function YV(n,t,e,i,r,s){const o=s[t];if(null!==o)for(let a=0;an.nextProducerIndex;)n.producerNode.pop(),n.producerLastReadVersion.pop(),n.producerIndexOfThis.pop()}}(a,o),function fV(n){n.lView[Uc]!==n&&(n.lView=null,pN.push(n))}(a)),n1()}}function FN(n,t){for(let e=gN(n);null!==e;e=vN(e))for(let i=mn;i-1&&(Fp(t,i),Xm(e,i))}this._attachedToViewContainer=!1}cy(this._lView[Be],this._lView)}onDestroy(t){!function Fm(n,t){if(256==(256&n[Ct]))throw new F(911,!1);null===n[qh]&&(n[qh]=[]),n[qh].push(t)}(this._lView,t)}markForCheck(){$p(this._cdRefInjectingView||this._lView)}detach(){this._lView[Ct]&=-129}reattach(){$b(this._lView),this._lView[Ct]|=128}detectChanges(){this._lView[Ct]|=1024,function EM(n,t=!0){const e=n[Kl],i=e.rendererFactory;i.begin?.();try{!function XV(n){DM(n,0);let t=0;for(;fA(n);){if(100===t)throw new F(103,!1);t++,DM(n,1)}}(n)}catch(s){throw t&&Ay(n,s),s}finally{i.end?.(),e.inlineEffectRunner?.flush()}}(this._lView,this.notifyErrorHandler)}checkNoChanges(){}attachToViewContainerRef(){if(this._appRef)throw new F(902,!1);this._attachedToViewContainer=!0}detachFromAppRef(){this._appRef=null,EL(this._lView[Be],this._lView)}attachToAppRef(t){if(this._attachedToViewContainer)throw new F(902,!1);this._appRef=t,$b(this._lView)}}const VN=new Set;function TM(n){return t=>{setTimeout(n,void 0,t)}}const Yo=class h7 extends Pt{constructor(t=!1){super(),this.__isAsync=t}emit(t){super.next(t)}subscribe(t,e,i){let r=t,s=e||(()=>null),o=i;if(t&&"object"==typeof t){const l=t;r=l.next?.bind(l),s=l.error?.bind(l),o=l.complete?.bind(l)}this.__isAsync&&(s=TM(s),r&&(r=TM(r)),o&&(o=TM(o)));const a=super.subscribe({next:r,error:s,complete:o});return t instanceof As&&t.add(a),a}};function WN(...n){}class Rr{constructor({enableLongStackTrace:t=!1,shouldCoalesceEventChangeDetection:e=!1,shouldCoalesceRunChangeDetection:i=!1}){if(this.hasPendingMacrotasks=!1,this.hasPendingMicrotasks=!1,this.isStable=!0,this.onUnstable=new Yo(!1),this.onMicrotaskEmpty=new Yo(!1),this.onStable=new Yo(!1),this.onError=new Yo(!1),typeof Zone>"u")throw new F(908,!1);Zone.assertZonePatched();const r=this;r._nesting=0,r._outer=r._inner=Zone.current,Zone.TaskTrackingZoneSpec&&(r._inner=r._inner.fork(new Zone.TaskTrackingZoneSpec)),t&&Zone.longStackTraceZoneSpec&&(r._inner=r._inner.fork(Zone.longStackTraceZoneSpec)),r.shouldCoalesceEventChangeDetection=!i&&e,r.shouldCoalesceRunChangeDetection=i,r.lastRequestAnimationFrameId=-1,r.nativeRequestAnimationFrame=function c7(){const n="function"==typeof rr.requestAnimationFrame;let t=rr[n?"requestAnimationFrame":"setTimeout"],e=rr[n?"cancelAnimationFrame":"clearTimeout"];if(typeof Zone<"u"&&t&&e){const i=t[Zone.__symbol__("OriginalDelegate")];i&&(t=i);const r=e[Zone.__symbol__("OriginalDelegate")];r&&(e=r)}return{nativeRequestAnimationFrame:t,nativeCancelAnimationFrame:e}}().nativeRequestAnimationFrame,function f7(n){const t=()=>{!function u7(n){n.isCheckStableRunning||-1!==n.lastRequestAnimationFrameId||(n.lastRequestAnimationFrameId=n.nativeRequestAnimationFrame.call(rr,()=>{n.fakeTopEventTask||(n.fakeTopEventTask=Zone.root.scheduleEventTask("fakeTopEventTask",()=>{n.lastRequestAnimationFrameId=-1,LM(n),n.isCheckStableRunning=!0,AM(n),n.isCheckStableRunning=!1},void 0,()=>{},()=>{})),n.fakeTopEventTask.invoke()}),LM(n))}(n)};n._inner=n._inner.fork({name:"angular",properties:{isAngularZone:!0},onInvokeTask:(e,i,r,s,o,a)=>{if(function p7(n){return!(!Array.isArray(n)||1!==n.length)&&!0===n[0].data?.__ignore_ng_zone__}(a))return e.invokeTask(r,s,o,a);try{return YN(n),e.invokeTask(r,s,o,a)}finally{(n.shouldCoalesceEventChangeDetection&&"eventTask"===s.type||n.shouldCoalesceRunChangeDetection)&&t(),QN(n)}},onInvoke:(e,i,r,s,o,a,l)=>{try{return YN(n),e.invoke(r,s,o,a,l)}finally{n.shouldCoalesceRunChangeDetection&&t(),QN(n)}},onHasTask:(e,i,r,s)=>{e.hasTask(r,s),i===r&&("microTask"==s.change?(n._hasPendingMicrotasks=s.microTask,LM(n),AM(n)):"macroTask"==s.change&&(n.hasPendingMacrotasks=s.macroTask))},onHandleError:(e,i,r,s)=>(e.handleError(r,s),n.runOutsideAngular(()=>n.onError.emit(s)),!1)})}(r)}static isInAngularZone(){return typeof Zone<"u"&&!0===Zone.current.get("isAngularZone")}static assertInAngularZone(){if(!Rr.isInAngularZone())throw new F(909,!1)}static assertNotInAngularZone(){if(Rr.isInAngularZone())throw new F(909,!1)}run(t,e,i){return this._inner.run(t,e,i)}runTask(t,e,i,r){const s=this._inner,o=s.scheduleEventTask("NgZoneEvent: "+r,t,d7,WN,WN);try{return s.runTask(o,e,i)}finally{s.cancelTask(o)}}runGuarded(t,e,i){return this._inner.runGuarded(t,e,i)}runOutsideAngular(t){return this._outer.run(t)}}const d7={};function AM(n){if(0==n._nesting&&!n.hasPendingMicrotasks&&!n.isStable)try{n._nesting++,n.onMicrotaskEmpty.emit(null)}finally{if(n._nesting--,!n.hasPendingMicrotasks)try{n.runOutsideAngular(()=>n.onStable.emit(null))}finally{n.isStable=!0}}}function LM(n){n.hasPendingMicrotasks=!!(n._hasPendingMicrotasks||(n.shouldCoalesceEventChangeDetection||n.shouldCoalesceRunChangeDetection)&&-1!==n.lastRequestAnimationFrameId)}function YN(n){n._nesting++,n.isStable&&(n.isStable=!1,n.onUnstable.emit(null))}function QN(n){n._nesting--,AM(n)}let Jp=(()=>{class n{constructor(){this.handler=null,this.internalCallbacks=[]}execute(){const e=[...this.internalCallbacks];this.internalCallbacks.length=0;for(const r of e)r();return!!this.handler?.execute()||e.length>0}ngOnDestroy(){this.handler?.destroy(),this.handler=null,this.internalCallbacks.length=0}static{this.\u0275prov=Yi({token:n,providedIn:"root",factory:()=>new n})}}return n})();function y7(n,t){const e=To(t,n),i=e[Be];!function S7(n,t){for(let e=t.length;e0&&HL(n,e,s.join(" "))}}(u,w,p,i),void 0!==e&&function A7(n,t,e){const i=n.projection=[];for(let r=0;r=0;i--){const r=n[i];r.hostVars=t+=r.hostVars,r.hostAttrs=bp(r.hostAttrs,e=bp(e,r.hostAttrs))}}(i)}function N7(n,t){for(const e in t.inputs){if(!t.inputs.hasOwnProperty(e)||n.inputs.hasOwnProperty(e))continue;const i=t.inputs[e];if(void 0!==i&&(n.inputs[e]=i,n.declaredInputs[e]=t.declaredInputs[e],null!==t.inputTransforms)){const r=Array.isArray(i)?i[0]:i;if(!t.inputTransforms.hasOwnProperty(r))continue;n.inputTransforms??={},n.inputTransforms[r]=t.inputTransforms[r]}}}function Ny(n){return n===rl?{}:n===Qi?[]:n}function k7(n,t){const e=n.viewQuery;n.viewQuery=e?(i,r)=>{t(i,r),e(i,r)}:t}function P7(n,t){const e=n.contentQueries;n.contentQueries=e?(i,r,s)=>{t(i,r,s),e(i,r,s)}:t}function z7(n,t){const e=n.hostBindings;n.hostBindings=e?(i,r)=>{t(i,r),e(i,r)}:t}function Ou(n,t){return!t||null===t.firstChild||oy(n)}function sg(n,t,e,i=!0){const r=t[Be];if(function r6(n,t,e,i){const r=mn+i,s=e.length;i>0&&(e[r-1][wa]=t),i{class n{static{this.__NG_ELEMENT_ID__=h9}}return n})();function h9(){return fO(pr(),Se())}const c9=An,dO=class extends c9{constructor(t,e,i){super(),this._lContainer=t,this._hostTNode=e,this._hostLView=i}get element(){return Au(this._hostTNode,this._hostLView)}get injector(){return new Yn(this._hostTNode,this._hostLView)}get parentInjector(){const t=Qm(this._hostTNode,this._hostLView);if(a1(t)){const e=Op(t,this._hostLView),i=Np(t);return new Yn(e[Be].data[i+8],e)}return new Yn(null,this._hostLView)}clear(){for(;this.length>0;)this.remove(this.length-1)}get(t){const e=uO(this._lContainer);return null!==e&&e[t]||null}get length(){return this._lContainer.length-mn}createEmbeddedView(t,e,i){let r,s;"number"==typeof i?r=i:null!=i&&(r=i.index,s=i.injector);const a=t.createEmbeddedViewImpl(e||{},s,null);return this.insertImpl(a,r,Ou(this._hostTNode,null)),a}createComponent(t,e,i,r,s){const o=t&&!function kp(n){return"function"==typeof n}(t);let a;if(o)a=e;else{const p=e||{};a=p.index,i=p.injector,r=p.projectableNodes,s=p.environmentInjector||p.ngModuleRef}const l=o?t:new Kp(di(t)),h=i||this.parentInjector;if(!s&&null==l.ngModule){const g=(o?h:this.parentInjector).get(ih,null);g&&(s=g)}di(l.componentType??{});const f=l.create(h,r,null,s);return this.insertImpl(f.hostView,a,Ou(this._hostTNode,null)),f}insert(t,e){return this.insertImpl(t,e,!0)}insertImpl(t,e,i){const r=t._lView;if(function hU(n){return Ps(n[vn])}(r)){const a=this.indexOf(t);if(-1!==a)this.detach(a);else{const l=r[vn],h=new dO(l,l[Os],l[vn]);h.detach(h.indexOf(t))}}const s=this._adjustIndex(e),o=this._lContainer;return sg(o,r,s,i),t.attachToViewContainerRef(),UA(BM(o),s,t),t}move(t,e){return this.insert(t,e)}indexOf(t){const e=uO(this._lContainer);return null!==e?e.indexOf(t):-1}remove(t){const e=this._adjustIndex(t,-1),i=Fp(this._lContainer,e);i&&(Xm(BM(this._lContainer),e),cy(i[Be],i))}detach(t){const e=this._adjustIndex(t,-1),i=Fp(this._lContainer,e);return i&&null!=Xm(BM(this._lContainer),e)?new Zp(i):null}_adjustIndex(t,e=0){return t??this.length+e}};function uO(n){return n[8]}function BM(n){return n[8]||(n[8]=[])}function fO(n,t){let e;const i=t[n.index];return Ps(i)?e=i:(e=function PN(n,t,e,i){return[n,!0,0,t,null,i,null,e,null,null]}(i,t,null,n),t[n.index]=e,Ty(t,e)),pO(e,t,n,i),new dO(e,n,t)}let pO=function vO(n,t,e,i){if(n[sl])return;let r;r=8&e.type?fr(i):function d9(n,t){const e=n[Yt],i=e.createComment(""),r=qs(t,n);return qc(e,dy(e,r),i,function l6(n,t){return n.nextSibling(t)}(e,r),!1),i}(t,e),n[sl]=r};function qu(n,t,e){const i=Se();return function Ln(n,t,e){return!Object.is(n[t],e)&&(n[t]=e,!0)}(i,function hl(){return Rt.lFrame.bindingIndex++}(),t)&&function No(n,t,e,i,r,s,o,a){const l=qs(t,e);let c,h=t.inputs;!a&&null!=h&&(c=h[i])?(CM(n,e,c,i,r),jc(t)&&function kV(n,t){const e=To(t,n);16&e[Ct]||(e[Ct]|=64)}(e,t.index)):3&t.type&&(i=function OV(n){return"class"===n?"className":"for"===n?"htmlFor":"formaction"===n?"formAction":"innerHtml"===n?"innerHTML":"readonly"===n?"readOnly":"tabindex"===n?"tabIndex":n}(i),r=null!=o?o(r,t.value||"",i):r,s.setProperty(l,i,r))}(Ti(),function zr(){const n=Rt.lFrame;return xp(n.tView,n.selectedIndex)}(),i,n,t,i[Yt],e,!1),qu}function ZM(n,t,e,i,r){const o=r?"class":"style";CM(n,e,t.inputs[o],o,i)}function id(n,t,e,i){const r=Se(),s=Ti(),o=jt+n,a=r[Yt],l=s.firstCreatePass?function B8(n,t,e,i,r,s){const o=t.consts,l=Lu(t,n,2,i,al(o,r));return function IM(n,t,e,i){if(gA()){const r=null===i?null:{"":-1},s=function FV(n,t){const e=n.directiveRegistry;let i=null,r=null;if(e)for(let s=0;s($h(!0),hy(i,r,function DA(){return Rt.lFrame.currentNamespace}()));const Zu="en-US";let Mk=Zu;function aw(n){return!!n&&"function"==typeof n.then}function Gk(n){return!!n&&"function"==typeof n.subscribe}function lw(n,t,e,i){const r=Se(),s=Ti(),o=pr();return function qk(n,t,e,i,r,s,o){const a=Hm(i),h=n.firstCreatePass&&HN(n),c=t[Er],d=RN(t);let u=!0;if(3&i.type||o){const g=qs(i,t),v=o?o(g):g,y=d.length,S=o?M=>o(fr(M[i.index])):i.index;let b=null;if(!o&&a&&(b=function UW(n,t,e,i){const r=n.cleanup;if(null!=r)for(let s=0;sl?a[l]:null}"string"==typeof o&&(s+=2)}return null}(n,t,r,i.index)),null!==b)(b.__ngLastListenerFn__||b).__ngNextListenerFn__=s,b.__ngLastListenerFn__=s,u=!1;else{s=Zk(i,t,c,s,!1);const M=e.listen(v,r,s);d.push(s,M),h&&h.push(r,S,y,y+1)}}else s=Zk(i,t,c,s,!1);const f=i.outputs;let p;if(u&&null!==f&&(p=f[r])){const g=p.length;if(g)for(let v=0;v-1?To(n.index,t):t);let l=$k(t,e,i,o),h=s.__ngNextListenerFn__;for(;h;)l=$k(t,e,h,o)&&l,h=h.__ngNextListenerFn__;return r&&!1===l&&o.preventDefault(),l}}function QW(){return this._results[Symbol.iterator]()}class cw{get changes(){return this._changes??=new Yo}constructor(t=!1){this._emitDistinctChangesOnly=t,this.dirty=!0,this._results=[],this._changesDetected=!1,this._changes=void 0,this.length=0,this.first=void 0,this.last=void 0;const e=cw.prototype;e[Symbol.iterator]||(e[Symbol.iterator]=QW)}get(t){return this._results[t]}map(t){return this._results.map(t)}filter(t){return this._results.filter(t)}find(t){return this._results.find(t)}reduce(t,e){return this._results.reduce(t,e)}forEach(t){this._results.forEach(t)}some(t){return this._results.some(t)}toArray(){return this._results.slice()}toString(){return this._results.toString()}reset(t,e){this.dirty=!1;const i=function lo(n){return n.flat(Number.POSITIVE_INFINITY)}(t);(this._changesDetected=!function $U(n,t,e){if(n.length!==t.length)return!1;for(let i=0;i{class n{static{this.__NG_ELEMENT_ID__=qW}}return n})();const GW=oh,XW=class extends GW{constructor(t,e,i){super(),this._declarationLView=t,this._declarationTContainer=e,this.elementRef=i}get ssrId(){return this._declarationTContainer.tView?.ssrId||null}createEmbeddedView(t,e){return this.createEmbeddedViewImpl(t,e)}createEmbeddedViewImpl(t,e,i){const r=function ng(n,t,e,i){const r=t.tView,a=xy(n,r,e,4096&n[Ct]?4096:16,null,t,null,null,null,i?.injector??null,i?.dehydratedView??null);a[wp]=n[t.index];const h=n[nl];return null!==h&&(a[nl]=h.createEmbeddedView(r)),NM(r,a,e),a}(this._declarationLView,this._declarationTContainer,t,{injector:e,dehydratedView:i});return new Zp(r)}};function qW(){return Xy(pr(),Se())}function Xy(n,t){return 4&n.type?new XW(t,n,Au(n,t)):null}class dw{constructor(t){this.queryList=t,this.matches=null}clone(){return new dw(this.queryList)}setDirty(){this.queryList.setDirty()}}class uw{constructor(t=[]){this.queries=t}createEmbeddedView(t){const e=t.queries;if(null!==e){const i=null!==t.contentQueries?t.contentQueries[0]:e.length,r=[];for(let s=0;s0)i.push(o[a/2]);else{const h=s[a+1],c=t[-l];for(let d=mn;d($h(!0),function ly(n,t){return n.createText(t)}(t[Yt],i));function mw(n,t,e,i,r){if(n=vt(n),Array.isArray(n))for(let s=0;s>20;if(Gc(n)||!n.multi){const f=new Lp(h,r,Ot),p=Sw(l,t,r?c:c+u,d);-1===p?(c1(Ym(a,o),s,l),yw(s,n,t.length),t.push(l),a.directiveStart++,a.directiveEnd++,r&&(a.providerIndexes+=1048576),e.push(f),o.push(f)):(e[p]=f,o[p]=f)}else{const f=Sw(l,t,c+u,d),p=Sw(l,t,c,c+u),v=p>=0&&e[p];if(r&&!v||!r&&!(f>=0&&e[f])){c1(Ym(a,o),s,l);const y=function yY(n,t,e,i,r){const s=new Lp(n,e,Ot);return s.multi=[],s.index=t,s.componentProviders=0,kP(s,r,i&&!e),s}(r?mY:vY,e.length,r,i,h);!r&&v&&(e[p].providerFactory=y),yw(s,n,t.length,0),t.push(l),a.directiveStart++,a.directiveEnd++,r&&(a.providerIndexes+=1048576),e.push(y),o.push(y)}else yw(s,n,f>-1?f:p,kP(e[r?p:f],h,!r&&i));!r&&i&&v&&e[p].componentProviders++}}}function yw(n,t,e,i){const r=Gc(t),s=function gj(n){return!!n.useClass}(t);if(r||s){const l=(s?vt(t.useClass):t).prototype.ngOnDestroy;if(l){const h=n.destroyHooks||(n.destroyHooks=[]);if(!r&&t.multi){const c=h.indexOf(e);-1===c?h.push(e,[i,l]):h[c+1].push(i,l)}else h.push(e,l)}}}function kP(n,t,e){return e&&n.componentProviders++,n.multi.push(t)-1}function Sw(n,t,e,i){for(let r=e;r{e.providersResolver=(i,r)=>function gY(n,t,e){const i=Ti();if(i.firstCreatePass){const r=Ea(n);mw(e,i.data,i.blueprint,r,!0),mw(t,i.data,i.blueprint,r,!1)}}(i,r?r(n):n,t)}}class sd{}class zP extends sd{constructor(t){super(),this.componentFactoryResolver=new JN(this),this.instance=null;const e=new Su([...t.providers,{provide:sd,useValue:this},{provide:wy,useValue:this.componentFactoryResolver}],t.parent||ty(),t.debugName,new Set(["environment"]));this.injector=e,t.runEnvironmentInitializers&&e.resolveInjectorInitializers()}destroy(){this.injector.destroy()}onDestroy(t){this.injector.onDestroy(t)}}let wY=(()=>{class n{constructor(e){this._injector=e,this.cachedInjectors=new Map}getOrCreateStandaloneInjector(e){if(!e.standalone)return null;if(!this.cachedInjectors.has(e)){const i=XA(0,e.type),r=i.length>0?function MY(n,t,e=null){return new zP({providers:n,parent:t,debugName:e,runEnvironmentInitializers:!0}).injector}([i],this._injector,`Standalone[${e.type.name}]`):null;this.cachedInjectors.set(e,r)}return this.cachedInjectors.get(e)}ngOnDestroy(){try{for(const e of this.cachedInjectors.values())null!==e&&e.destroy()}finally{this.cachedInjectors.clear()}}static{this.\u0275prov=Yi({token:n,providedIn:"environment",factory:()=>new n(_i(ih))})}}return n})();function RP(n){(function Zc(n){VN.has(n)||(VN.add(n),performance?.mark?.("mark_feature_usage",{detail:{feature:n}}))})("NgStandalone"),n.getStandaloneInjector=t=>t.get(wY).getOrCreateStandaloneInjector(n)}let Aw=(()=>{class n{constructor(){this.taskId=0,this.pendingTasks=new Set,this.hasPendingTasks=new _o(!1)}get _hasPendingTasks(){return this.hasPendingTasks.value}add(){this._hasPendingTasks||this.hasPendingTasks.next(!0);const e=this.taskId++;return this.pendingTasks.add(e),e}remove(e){this.pendingTasks.delete(e),0===this.pendingTasks.size&&this._hasPendingTasks&&this.hasPendingTasks.next(!1)}ngOnDestroy(){this.pendingTasks.clear(),this._hasPendingTasks&&this.hasPendingTasks.next(!1)}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();const g2=new Ht(""),XQ=new Ht("");let Pw=(()=>{class n{constructor(){this.initialized=!1,this.done=!1,this.donePromise=new Promise((e,i)=>{this.resolve=e,this.reject=i}),this.appInits=Hi(XQ,{optional:!0})??[]}runInitializers(){if(this.initialized)return;const e=[];for(const r of this.appInits){const s=r();if(aw(s))e.push(s);else if(Gk(s)){const o=new Promise((a,l)=>{s.subscribe({complete:a,error:l})});e.push(o)}}const i=()=>{this.done=!0,this.resolve()};Promise.all(e).then(()=>{i()}).catch(r=>{this.reject(r)}),0===e.length&&i(),this.initialized=!0}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();const v2=new Ht("");let ef=(()=>{class n{constructor(){this._bootstrapListeners=[],this._runningTick=!1,this._destroyed=!1,this._destroyListeners=[],this._views=[],this.internalErrorHandler=Hi(SN),this.afterRenderEffectManager=Hi(Jp),this.componentTypes=[],this.components=[],this.isStable=Hi(Aw).hasPendingTasks.pipe(jr(e=>!e)),this._injector=Hi(ih)}get destroyed(){return this._destroyed}get injector(){return this._injector}bootstrap(e,i){const r=e instanceof rN;if(!this._injector.get(Pw).done)throw!r&&function _c(n){const t=di(n)||Wn(n)||gs(n);return null!==t&&t.standalone}(e),new F(405,!1);let o;o=r?e:this._injector.get(wy).resolveComponentFactory(e),this.componentTypes.push(o.componentType);const a=function $Q(n){return n.isBoundToModule}(o)?void 0:this._injector.get(sd),h=o.create(Wo.NULL,[],i||o.selector,a),c=h.location.nativeElement,d=h.injector.get(g2,null);return d?.registerApplication(c),h.onDestroy(()=>{this.detachView(h.hostView),e0(this.components,h),d?.unregisterApplication(c)}),this._loadComponent(h),h}tick(){if(this._runningTick)throw new F(101,!1);try{this._runningTick=!0;for(let e of this._views)e.detectChanges()}catch(e){this.internalErrorHandler(e)}finally{try{this.afterRenderEffectManager.execute()}catch(e){this.internalErrorHandler(e)}this._runningTick=!1}}attachView(e){const i=e;this._views.push(i),i.attachToAppRef(this)}detachView(e){const i=e;e0(this._views,i),i.detachFromAppRef()}_loadComponent(e){this.attachView(e.hostView),this.tick(),this.components.push(e);const i=this._injector.get(v2,[]);[...this._bootstrapListeners,...i].forEach(r=>r(e))}ngOnDestroy(){if(!this._destroyed)try{this._destroyListeners.forEach(e=>e()),this._views.slice().forEach(e=>e.destroy())}finally{this._destroyed=!0,this._views=[],this._bootstrapListeners=[],this._destroyListeners=[]}}onDestroy(e){return this._destroyListeners.push(e),()=>e0(this._destroyListeners,e)}destroy(){if(this._destroyed)throw new F(406,!1);const e=this._injector;e.destroy&&!e.destroyed&&e.destroy()}get viewCount(){return this._views.length}warnIfDestroyed(){}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();function e0(n,t){const e=n.indexOf(t);e>-1&&n.splice(e,1)}let JQ=(()=>{class n{constructor(){this.zone=Hi(Rr),this.applicationRef=Hi(ef)}initialize(){this._onMicrotaskEmptySubscription||(this._onMicrotaskEmptySubscription=this.zone.onMicrotaskEmpty.subscribe({next:()=>{this.zone.run(()=>{this.applicationRef.tick()})}}))}ngOnDestroy(){this._onMicrotaskEmptySubscription?.unsubscribe()}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();function b2(n){return[{provide:Rr,useFactory:n},{provide:yu,multi:!0,useFactory:()=>{const t=Hi(JQ,{optional:!0});return()=>t.initialize()}},{provide:yu,multi:!0,useFactory:()=>{const t=Hi(tG);return()=>{t.initialize()}}},{provide:SN,useFactory:KQ}]}function KQ(){const n=Hi(Rr),t=Hi(nh);return e=>n.runOutsideAngular(()=>t.handleError(e))}function eG(n){return function b1(n){return{\u0275providers:n}}([[],b2(()=>new Rr(function M2(n){return{enableLongStackTrace:!1,shouldCoalesceEventChangeDetection:n?.eventCoalescing??!1,shouldCoalesceRunChangeDetection:n?.runCoalescing??!1}}(n)))])}let tG=(()=>{class n{constructor(){this.subscription=new As,this.initialized=!1,this.zone=Hi(Rr),this.pendingTasks=Hi(Aw)}initialize(){if(this.initialized)return;this.initialized=!0;let e=null;!this.zone.isStable&&!this.zone.hasPendingMacrotasks&&!this.zone.hasPendingMicrotasks&&(e=this.pendingTasks.add()),this.zone.runOutsideAngular(()=>{this.subscription.add(this.zone.onStable.subscribe(()=>{Rr.assertNotInAngularZone(),queueMicrotask(()=>{null!==e&&!this.zone.hasPendingMacrotasks&&!this.zone.hasPendingMicrotasks&&(this.pendingTasks.remove(e),e=null)})}))}),this.subscription.add(this.zone.onUnstable.subscribe(()=>{Rr.assertInAngularZone(),e??=this.pendingTasks.add()}))}ngOnDestroy(){this.subscription.unsubscribe()}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();const ah=new Ht("",{providedIn:"root",factory:()=>Hi(ah,xi.Optional|xi.SkipSelf)||function iG(){return typeof $localize<"u"&&$localize.locale||Zu}()}),zw=new Ht("");let nc=null;function DG(n){try{const{rootComponent:t,appProviders:e,platformProviders:i}=n,r=function aG(n=[]){if(nc)return nc;const t=function E2(n=[],t){return Wo.create({name:t,providers:[{provide:C1,useValue:"platform"},{provide:zw,useValue:new Set([()=>nc=null])},...n]})}(n);return nc=t,function m2(){!function Mb(n){$d=n}(()=>{throw new F(600,!1)})}(),function D2(n){n.get(sL,null)?.forEach(e=>e())}(t),t}(i),s=[eG(),...e||[]],a=new zP({providers:s,parent:r,debugName:"",runEnvironmentInitializers:!1}).injector,l=a.get(Rr);return l.run(()=>{a.resolveInjectorInitializers();const h=a.get(nh,null);let c;l.runOutsideAngular(()=>{c=l.onError.subscribe({next:f=>{h.handleError(f)}})});const d=()=>a.destroy(),u=r.get(zw);return u.add(d),a.onDestroy(()=>{c.unsubscribe(),u.delete(d)}),function y2(n,t,e){try{const i=e();return aw(i)?i.catch(r=>{throw t.runOutsideAngular(()=>n.handleError(r)),r}):i}catch(i){throw t.runOutsideAngular(()=>n.handleError(i)),i}}(h,l,()=>{const f=a.get(Pw);return f.runInitializers(),f.donePromise.then(()=>{!function wk(n){so(n,"Expected localeId to be defined"),"string"==typeof n&&(Mk=n.toLowerCase().replace(/_/g,"-"))}(a.get(ah,Zu)||Zu);const g=a.get(ef);return void 0!==t&&g.bootstrap(t),g})})})}catch(t){return Promise.reject(t)}}let $2=null;function Vw(){return $2}class UG{}const ad=new Ht("");let sq=(()=>{class n{static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275mod=km({type:n})}static{this.\u0275inj=yp({})}}return n})();function uz(n){return"server"===n}class kq extends UG{constructor(){super(...arguments),this.supportsDOMEvents=!0}}class oC extends kq{static makeCurrent(){!function _G(n){$2??=n}(new oC)}onAndCancel(t,e,i){return t.addEventListener(e,i),()=>{t.removeEventListener(e,i)}}dispatchEvent(t,e){t.dispatchEvent(e)}remove(t){t.parentNode&&t.parentNode.removeChild(t)}createElement(t,e){return(e=e||this.getDefaultDocument()).createElement(t)}createHtmlDocument(){return document.implementation.createHTMLDocument("fakeTitle")}getDefaultDocument(){return document}isElementNode(t){return t.nodeType===Node.ELEMENT_NODE}isShadowRoot(t){return t instanceof DocumentFragment}getGlobalEventTarget(t,e){return"window"===e?window:"document"===e?t:"body"===e?t.body:null}getBaseHref(t){const e=function Pq(){return Dg=Dg||document.querySelector("base"),Dg?Dg.getAttribute("href"):null}();return null==e?null:function zq(n){return new URL(n,document.baseURI).pathname}(e)}resetBaseElement(){Dg=null}getUserAgent(){return window.navigator.userAgent}getCookie(t){return function xX(n,t){t=encodeURIComponent(t);for(const e of n.split(";")){const i=e.indexOf("="),[r,s]=-1==i?[e,""]:[e.slice(0,i),e.slice(i+1)];if(r.trim()===t)return decodeURIComponent(s)}return null}(document.cookie,t)}}let Dg=null,Hq=(()=>{class n{build(){return new XMLHttpRequest}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();const aC=new Ht("");let vz=(()=>{class n{constructor(e,i){this._zone=i,this._eventNameToPlugin=new Map,e.forEach(r=>{r.manager=this}),this._plugins=e.slice().reverse()}addEventListener(e,i,r){return this._findPluginFor(i).addEventListener(e,i,r)}getZone(){return this._zone}_findPluginFor(e){let i=this._eventNameToPlugin.get(e);if(i)return i;if(i=this._plugins.find(s=>s.supports(e)),!i)throw new F(5101,!1);return this._eventNameToPlugin.set(e,i),i}static{this.\u0275fac=function(i){return new(i||n)(_i(aC),_i(Rr))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();class mz{constructor(t){this._doc=t}}const lC="ng-app-id";let yz=(()=>{class n{constructor(e,i,r,s={}){this.doc=e,this.appId=i,this.nonce=r,this.platformId=s,this.styleRef=new Map,this.hostNodes=new Set,this.styleNodesInDOM=this.collectServerRenderedStyles(),this.platformIsServer=uz(s),this.resetHostNodes()}addStyles(e){for(const i of e)1===this.changeUsageCount(i,1)&&this.onStyleAdded(i)}removeStyles(e){for(const i of e)this.changeUsageCount(i,-1)<=0&&this.onStyleRemoved(i)}ngOnDestroy(){const e=this.styleNodesInDOM;e&&(e.forEach(i=>i.remove()),e.clear());for(const i of this.getAllStyles())this.onStyleRemoved(i);this.resetHostNodes()}addHost(e){this.hostNodes.add(e);for(const i of this.getAllStyles())this.addStyleToHost(e,i)}removeHost(e){this.hostNodes.delete(e)}getAllStyles(){return this.styleRef.keys()}onStyleAdded(e){for(const i of this.hostNodes)this.addStyleToHost(i,e)}onStyleRemoved(e){const i=this.styleRef;i.get(e)?.elements?.forEach(r=>r.remove()),i.delete(e)}collectServerRenderedStyles(){const e=this.doc.head?.querySelectorAll(`style[${lC}="${this.appId}"]`);if(e?.length){const i=new Map;return e.forEach(r=>{null!=r.textContent&&i.set(r.textContent,r)}),i}return null}changeUsageCount(e,i){const r=this.styleRef;if(r.has(e)){const s=r.get(e);return s.usage+=i,s.usage}return r.set(e,{usage:i,elements:[]}),i}getStyleElement(e,i){const r=this.styleNodesInDOM,s=r?.get(i);if(s?.parentNode===e)return r.delete(i),s.removeAttribute(lC),s;{const o=this.doc.createElement("style");return this.nonce&&o.setAttribute("nonce",this.nonce),o.textContent=i,this.platformIsServer&&o.setAttribute(lC,this.appId),e.appendChild(o),o}}addStyleToHost(e,i){const r=this.getStyleElement(e,i),s=this.styleRef,o=s.get(i)?.elements;o?o.push(r):s.set(i,{elements:[r],usage:1})}resetHostNodes(){const e=this.hostNodes;e.clear(),e.add(this.doc.head)}static{this.\u0275fac=function(i){return new(i||n)(_i(ad),_i(N1),_i(oL,8),_i(bu))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();const hC={svg:"http://www.w3.org/2000/svg",xhtml:"http://www.w3.org/1999/xhtml",xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/",math:"http://www.w3.org/1998/MathML/"},cC=/%COMP%/g,Uq=new Ht("",{providedIn:"root",factory:()=>!0});function Iz(n,t){return t.map(e=>e.replace(cC,n))}let bz=(()=>{class n{constructor(e,i,r,s,o,a,l,h=null){this.eventManager=e,this.sharedStylesHost=i,this.appId=r,this.removeStylesOnCompDestroy=s,this.doc=o,this.platformId=a,this.ngZone=l,this.nonce=h,this.rendererByCompId=new Map,this.platformIsServer=uz(a),this.defaultRenderer=new dC(e,o,l,this.platformIsServer)}createRenderer(e,i){if(!e||!i)return this.defaultRenderer;this.platformIsServer&&i.encapsulation===ba.ShadowDom&&(i={...i,encapsulation:ba.Emulated});const r=this.getOrCreateRenderer(e,i);return r instanceof wz?r.applyToHost(e):r instanceof uC&&r.applyStyles(),r}getOrCreateRenderer(e,i){const r=this.rendererByCompId;let s=r.get(i.id);if(!s){const o=this.doc,a=this.ngZone,l=this.eventManager,h=this.sharedStylesHost,c=this.removeStylesOnCompDestroy,d=this.platformIsServer;switch(i.encapsulation){case ba.Emulated:s=new wz(l,h,i,this.appId,c,o,a,d);break;case ba.ShadowDom:return new Yq(l,h,e,i,o,a,this.nonce,d);default:s=new uC(l,h,i,c,o,a,d)}r.set(i.id,s)}return s}ngOnDestroy(){this.rendererByCompId.clear()}static{this.\u0275fac=function(i){return new(i||n)(_i(vz),_i(yz),_i(N1),_i(Uq),_i(ad),_i(bu),_i(Rr),_i(oL))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();class dC{constructor(t,e,i,r){this.eventManager=t,this.doc=e,this.ngZone=i,this.platformIsServer=r,this.data=Object.create(null),this.throwOnSyntheticProps=!0,this.destroyNode=null}destroy(){}createElement(t,e){return e?this.doc.createElementNS(hC[e]||e,t):this.doc.createElement(t)}createComment(t){return this.doc.createComment(t)}createText(t){return this.doc.createTextNode(t)}appendChild(t,e){(Mz(t)?t.content:t).appendChild(e)}insertBefore(t,e,i){t&&(Mz(t)?t.content:t).insertBefore(e,i)}removeChild(t,e){t&&t.removeChild(e)}selectRootElement(t,e){let i="string"==typeof t?this.doc.querySelector(t):t;if(!i)throw new F(-5104,!1);return e||(i.textContent=""),i}parentNode(t){return t.parentNode}nextSibling(t){return t.nextSibling}setAttribute(t,e,i,r){if(r){e=r+":"+e;const s=hC[r];s?t.setAttributeNS(s,e,i):t.setAttribute(e,i)}else t.setAttribute(e,i)}removeAttribute(t,e,i){if(i){const r=hC[i];r?t.removeAttributeNS(r,e):t.removeAttribute(`${i}:${e}`)}else t.removeAttribute(e)}addClass(t,e){t.classList.add(e)}removeClass(t,e){t.classList.remove(e)}setStyle(t,e,i,r){r&(ec.DashCase|ec.Important)?t.style.setProperty(e,i,r&ec.Important?"important":""):t.style[e]=i}removeStyle(t,e,i){i&ec.DashCase?t.style.removeProperty(e):t.style[e]=""}setProperty(t,e,i){null!=t&&(t[e]=i)}setValue(t,e){t.nodeValue=e}listen(t,e,i){if("string"==typeof t&&!(t=Vw().getGlobalEventTarget(this.doc,t)))throw new Error(`Unsupported event target ${t} for event ${e}`);return this.eventManager.addEventListener(t,e,this.decoratePreventDefault(i))}decoratePreventDefault(t){return e=>{if("__ngUnwrap__"===e)return t;!1===(this.platformIsServer?this.ngZone.runGuarded(()=>t(e)):t(e))&&e.preventDefault()}}}function Mz(n){return"TEMPLATE"===n.tagName&&void 0!==n.content}class Yq extends dC{constructor(t,e,i,r,s,o,a,l){super(t,s,o,l),this.sharedStylesHost=e,this.hostEl=i,this.shadowRoot=i.attachShadow({mode:"open"}),this.sharedStylesHost.addHost(this.shadowRoot);const h=Iz(r.id,r.styles);for(const c of h){const d=document.createElement("style");a&&d.setAttribute("nonce",a),d.textContent=c,this.shadowRoot.appendChild(d)}}nodeOrShadowRoot(t){return t===this.hostEl?this.shadowRoot:t}appendChild(t,e){return super.appendChild(this.nodeOrShadowRoot(t),e)}insertBefore(t,e,i){return super.insertBefore(this.nodeOrShadowRoot(t),e,i)}removeChild(t,e){return super.removeChild(this.nodeOrShadowRoot(t),e)}parentNode(t){return this.nodeOrShadowRoot(super.parentNode(this.nodeOrShadowRoot(t)))}destroy(){this.sharedStylesHost.removeHost(this.shadowRoot)}}class uC extends dC{constructor(t,e,i,r,s,o,a,l){super(t,s,o,a),this.sharedStylesHost=e,this.removeStylesOnCompDestroy=r,this.styles=l?Iz(l,i.styles):i.styles}applyStyles(){this.sharedStylesHost.addStyles(this.styles)}destroy(){this.removeStylesOnCompDestroy&&this.sharedStylesHost.removeStyles(this.styles)}}class wz extends uC{constructor(t,e,i,r,s,o,a,l){const h=r+"-"+i.id;super(t,e,i,s,o,a,l,h),this.contentAttr=function jq(n){return"_ngcontent-%COMP%".replace(cC,n)}(h),this.hostAttr=function Vq(n){return"_nghost-%COMP%".replace(cC,n)}(h)}applyToHost(t){this.applyStyles(),this.setAttribute(t,this.hostAttr,"")}createElement(t,e){const i=super.createElement(t,e);return super.setAttribute(i,this.contentAttr,""),i}}let Qq=(()=>{class n extends mz{constructor(e){super(e)}supports(e){return!0}addEventListener(e,i,r){return e.addEventListener(i,r,!1),()=>this.removeEventListener(e,i,r)}removeEventListener(e,i,r){return e.removeEventListener(i,r)}static{this.\u0275fac=function(i){return new(i||n)(_i(ad))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();const Cz=["alt","control","meta","shift"],Gq={"\b":"Backspace","\t":"Tab","\x7f":"Delete","\x1b":"Escape",Del:"Delete",Esc:"Escape",Left:"ArrowLeft",Right:"ArrowRight",Up:"ArrowUp",Down:"ArrowDown",Menu:"ContextMenu",Scroll:"ScrollLock",Win:"OS"},Xq={alt:n=>n.altKey,control:n=>n.ctrlKey,meta:n=>n.metaKey,shift:n=>n.shiftKey};let qq=(()=>{class n extends mz{constructor(e){super(e)}supports(e){return null!=n.parseEventName(e)}addEventListener(e,i,r){const s=n.parseEventName(i),o=n.eventCallback(s.fullKey,r,this.manager.getZone());return this.manager.getZone().runOutsideAngular(()=>Vw().onAndCancel(e,s.domEventName,o))}static parseEventName(e){const i=e.toLowerCase().split("."),r=i.shift();if(0===i.length||"keydown"!==r&&"keyup"!==r)return null;const s=n._normalizeKey(i.pop());let o="",a=i.indexOf("code");if(a>-1&&(i.splice(a,1),o="code."),Cz.forEach(h=>{const c=i.indexOf(h);c>-1&&(i.splice(c,1),o+=h+".")}),o+=s,0!=i.length||0===s.length)return null;const l={};return l.domEventName=r,l.fullKey=o,l}static matchEventFullKeyCode(e,i){let r=Gq[e.key]||e.key,s="";return i.indexOf("code.")>-1&&(r=e.code,s="code."),!(null==r||!r)&&(r=r.toLowerCase()," "===r?r="space":"."===r&&(r="dot"),Cz.forEach(o=>{o!==r&&(0,Xq[o])(e)&&(s+=o+".")}),s+=r,s===i)}static eventCallback(e,i,r){return s=>{n.matchEventFullKeyCode(s,e)&&r.runGuarded(()=>i(s))}}static _normalizeKey(e){return"esc"===e?"escape":e}static{this.\u0275fac=function(i){return new(i||n)(_i(ad))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();function Ez(n){return{appProviders:[...i$,...n?.providers??[]],platformProviders:e$}}const e$=[{provide:bu,useValue:"browser"},{provide:sL,useValue:function Zq(){oC.makeCurrent()},multi:!0},{provide:ad,useFactory:function Kq(){return function Aj(n){L1=n}(document),document},deps:[]}],i$=[{provide:C1,useValue:"root"},{provide:nh,useFactory:function Jq(){return new nh},deps:[]},{provide:aC,useClass:Qq,multi:!0,deps:[ad,Rr,bu]},{provide:aC,useClass:qq,multi:!0,deps:[ad]},bz,yz,vz,{provide:sN,useExisting:bz},{provide:class cq{},useClass:Hq,deps:[]},[]];var o$=0,fC=!1;function w0(n,t){var e=t;return e.unshift(void 0),new(Function.prototype.bind.apply(n,e))}function Y(n,t){for(var e=t,i=n.replace(/\[/g,".").replace(/\]/g,"").split("."),r=0;r"u"}function Ei(n){return n+"_"+o$++}function E0(n,t){return n===t||!(n===document||!n)&&E0(n.parentNode,t)}function Ag(n){try{throw new Error(n)}catch(t){throw new Error(t.message+"\n"+t.stack)}}function Re(n){var t=n+"";return t.match(/auto|cm|mm|in|px|pt|pc|%|em|ex|ch|rem|vw|vh|vmin|vmax/)?t:t+"px"}function ce(){return fC}var Lg,n,t,d$={latn:{_digits:"0123456789",_type:"numeric"}},Lz={decimal:".",group:",",percentSign:"%",plusSign:"+",minusSign:"-",infinity:"\u221e",nan:"NaN",exponential:"E"},Nz=[0,1,2,3,4,5,6,7,8,9],Hr=function(){function n(){}return n.getMainObject=function(t,e){return Y(ce()?e:"main."+e,t)},n.getNumberingSystem=function(t){return Y("supplemental.numberingSystems",t)||this.numberingSystems},n.reverseObject=function(t,e){for(var r={},s=0,o=e||Object.keys(t);s13&&(p+=1,o-=12),o-=1,a=p-4716;var y=u-24e5,S=10631/30,b=u-1948084,M=Math.floor(b/10631);b-=10631*M;var w=Math.floor((b-.1335)/S),C=30*M+w;b-=Math.floor(w*S+.1335);var D=Math.floor((b+28.5001)/29.5);13===D&&(D=12);for(var A=b-Math.floor(29.5001*D-29),x=0;xy);x++);var P=x+16260,L=Math.floor((P-1)/12),O=L+1,N=P-12*L,T=y-t[x-1]+1;return(T+"").length>2&&(T=A,N=D,O=C),{year:O,month:N,date:T}},n.toGregorian=function i(r,s,o){var g=Math.floor(o+t[12*(r-1)+1+(s-1)-16260-1]-1+24e5+.5),v=Math.floor((g-1867216.25)/36524.25),y=1524+(v=g+1+v-Math.floor(v/4)),S=Math.floor((y-122.1)/365.25),b=Math.floor(365.25*S),M=Math.floor((y-b)/30.6001),w=y-b-Math.floor(30.6001*M),C=M-(M>13.5?13:1),D=S-(C>2.5?4716:4715);return D<=0&&C--,new Date(D+"/"+C+"/"+w)};var ut,p$=/\/MMMMM|MMMM|MMM|a|LLLL|LLL|EEEEE|EEEE|E|K|cccc|ccc|WW|W|G+|z+/gi,Oz="stand-alone",g$=["sun","mon","tue","wed","thu","fri","sat"],kz={m:"getMinutes",h:"getHours",H:"getHours",s:"getSeconds",d:"getDate",f:"getMilliseconds"},Pz=function(){function n(){}return n.dateFormat=function(t,e,i){var r=this,s=ut.getDependables(i,t,e.calendar),o=Y("parserObject.numbers",s),a=s.dateObject,l={isIslamic:ut.islamicRegex.test(e.calendar)};ce()&&e.isServerRendered&&(e=ut.compareBlazorDateFormats(e,t));var h=e.format||ut.getResultantPattern(e.skeleton,s.dateObject,e.type,!1,ce()?t:"");if(l.dateSeperator=ce()?Y("dateSeperator",a):ut.getDateSeparator(s.dateObject),st(h))Ag("Format options or type given must be invalid");else{h=ut.ConvertDateToWeekFormat(h),ce()&&(h=h.replace(/tt/,"a")),l.pattern=h,l.numMapper=ce()?ze({},o):Hr.getNumberMapper(s.parserObject,Hr.getNumberingSystem(i));for(var d=0,u=h.match(p$)||[];d2?r+=e.month[""+u]:p=!0;break;case"E":case"c":r+=e.weekday[""+g$[t.getDay()]];break;case"H":case"h":case"m":case"s":case"d":case"f":if(p=!0,"d"===d)u=o.date;else if("f"===d){p=!1,g=!0;var y=(f=(f=t[""+kz[""+d]]().toString()).substring(0,c)).length;if(c!==y){if(c>3)continue;for(var S=0;S0?1:0],o=Math.abs(t);return s.replace(/HH?|mm/g,function(a){var l=a.length,h=-1!==a.indexOf("H");return i.checkTwodigitNumber(Math.floor(h?o/60:o%60),l)})},n}(),zz={ms:"minimumSignificantDigits",ls:"maximumSignificantDigits",mf:"minimumFractionDigits",lf:"maximumFractionDigits"},sf=["infinity","nan","group","decimal","exponential"],Rz=function(){function n(){}return n.numberFormatter=function(t,e,i){var l,r=this,s=ze({},e),o={},a={},h=ut.getDependables(i,t,"",!0),c=h.numericObject;a.numberMapper=ce()?ze({},c):Hr.getNumberMapper(h.parserObject,Hr.getNumberingSystem(i),!0),a.currencySymbol=ce()?Y("currencySymbol",c):ut.getCurrencySymbol(h.numericObject,s.currency||kg,e.altSymbol,e.ignoreCurrency),a.percentSymbol=ce()?Y("numberSymbols.percentSign",c):a.numberMapper.numberSymbols.percentSign,a.minusSymbol=ce()?Y("numberSymbols.minusSign",c):a.numberMapper.numberSymbols.minusSign;var d=a.numberMapper.numberSymbols;if(e.format&&!ut.formatRegex.test(e.format))o=ut.customFormat(e.format,a,h.numericObject),!st(s.useGrouping)&&s.useGrouping&&(s.useGrouping=o.pData.useGrouping);else{if(ze(s,ut.getProperNumericSkeleton(e.format||"N")),s.isCurrency="currency"===s.type,s.isPercent="percent"===s.type,ce()||(l=ut.getSymbolPattern(s.type,a.numberMapper.numberSystem,h.numericObject,s.isAccount)),s.groupOne=this.checkValueRange(s.maximumSignificantDigits,s.minimumSignificantDigits,!0),this.checkValueRange(s.maximumFractionDigits,s.minimumFractionDigits,!1,!0),st(s.fractionDigits)||(s.minimumFractionDigits=s.maximumFractionDigits=s.fractionDigits),st(s.useGrouping)&&(s.useGrouping=!0),s.isCurrency&&!ce()&&(l=l.replace(/\u00A4/g,ut.defaultCurrency)),ce())o.nData=ze({},{},Y(s.type+"nData",c)),o.pData=ze({},{},Y(s.type+"pData",c)),"currency"===s.type&&e.currency&&ut.replaceBlazorCurrency([o.pData,o.nData],a.currencySymbol,e.currency);else{var u=l.split(";");o.nData=ut.getFormatData(u[1]||"-"+u[0],!0,a.currencySymbol),o.pData=ut.getFormatData(u[0],!1,a.currencySymbol),s.useGrouping&&(s.groupSeparator=d[sf[2]],s.groupData=this.getGroupingDetails(u[0]))}if(st(s.minimumFractionDigits)&&(s.minimumFractionDigits=o.nData.minimumFraction),st(s.maximumFractionDigits)){var p=o.nData.maximumFraction;s.maximumFractionDigits=st(p)&&s.isPercent?0:p}var g=s.minimumFractionDigits,v=s.maximumFractionDigits;!st(g)&&!st(v)&&g>v&&(s.maximumFractionDigits=g)}return ze(o.nData,s),ze(o.pData,s),function(y){return isNaN(y)?d[sf[1]]:isFinite(y)?r.intNumberFormatter(y,o,a,e):d[sf[0]]}},n.getGroupingDetails=function(t){var e={},i=t.match(ut.negativeDataRegex);if(i&&i[4]){var r=i[4],s=r.lastIndexOf(",");if(-1!==s){var o=r.split(".")[0];e.primary=o.length-s-1;var a=r.lastIndexOf(",",s-1);-1!==a&&(e.secondary=s-1-a)}}return e},n.checkValueRange=function(t,e,i,r){var s=r?"f":"s",o=0,a=zz["l"+s],l=zz["m"+s];if(st(t)||(this.checkRange(t,a,r),o++),st(e)||(this.checkRange(e,l,r),o++),2===o){if(!(tr[1])&&Ag(e+"value must be within the range"+r[0]+"to"+r[1])},n.intNumberFormatter=function(t,e,i,r){var s;if(!st(e.nData.type)){t<0?(t*=-1,s=e.nData):s=0===t&&e.zeroData||e.pData;var o="";if(s.isPercent&&(t*=100),s.groupOne)o=this.processSignificantDigits(t,s.minimumSignificantDigits,s.maximumSignificantDigits);else if(o=this.processFraction(t,s.minimumFractionDigits,s.maximumFractionDigits,r),s.minimumIntegerDigits&&(o=this.processMinimumIntegers(o,s.minimumIntegerDigits)),i.isCustomFormat&&s.minimumFractionDigits=0&&"0"===l[parseInt(c.toString(),10)]&&c>=s.minimumFractionDigits;c--)l=l.slice(0,c);o=a[0]+"."+l}return"scientific"===s.type&&(o=(o=t.toExponential(s.maximumFractionDigits)).replace("e",i.numberMapper.numberSymbols[sf[4]])),o=o.replace(".",i.numberMapper.numberSymbols[sf[3]]),o="#,###,,;(#,###,,)"===s.format?this.customPivotFormat(parseInt(o,10)):o,s.useGrouping&&(o=this.groupNumbers(o,s.groupData.primary,s.groupSeparator||",",i.numberMapper.numberSymbols[sf[3]]||".",s.groupData.secondary)),o=Hr.convertValueParts(o,ut.latnParseRegex,i.numberMapper.mapper),"N/A"===s.nlead?s.nlead:"0"===o&&r&&"0"===r.format?o+s.nend:s.nlead+o+s.nend}},n.processSignificantDigits=function(t,e,i){var r=t+"";return r.lengthe;)c=l.slice(h-e,h)+(c.length?i+c:""),h-=e,o&&(e=s,o=!1);return a[0]=l.slice(0,h)+(c.length?i:"")+c,a.join(r)},n.processFraction=function(t,e,i,r){var s=(t+"").split(".")[1],o=s?s.length:0;if(e&&oi||0===i))return t.toFixed(i);var h=t+"";return"0"===h[0]&&r&&"###.00"===r.format&&(h=h.slice(1)),h},n.processMinimumIntegers=function(t,e){var i=t.split("."),r=i[0],s=r.length;if(s=5e5){var r=(t/=1e6).toString().split(".")[1];return r&&+r.substring(0,1)>=5?Math.ceil(t).toString():Math.floor(t).toString()}return""},n}(),Ng=(new RegExp("^([^0-9]*)(([0-9,]*[0-9]+)(.[0-9]+)?)([Ee][+-]?[0-9]+)?([^0-9]*)$"),function(){function n(t){this.ranArray=[],this.boundedEvents={},!m(t)&&(this.context=t)}return n.prototype.on=function(t,e,i,r){if(!m(e)){var s=i||this.context;if(this.notExist(t))return void(this.boundedEvents[""+t]=[{handler:e,context:s,id:r}]);m(r)?this.isHandlerPresent(this.boundedEvents[""+t],e)||this.boundedEvents[""+t].push({handler:e,context:s}):-1===this.ranArray.indexOf(r)&&(this.ranArray.push(r),this.boundedEvents[""+t].push({handler:e,context:s,id:r}))}},n.prototype.off=function(t,e,i){if(!this.notExist(t)){var r=Y(t,this.boundedEvents);if(e){for(var s=0;s1&&(U.fractionDigits=parseInt(z[2],10)),U}function p(T,z,U,B){var j=B?{}:{nlead:"",nend:""},Q=T.match(n.customRegex);if(Q){B||(j.nlead=g(Q[1],U),j.nend=g(Q[10],U),j.groupPattern=Q[4]);var oe=Q[7];if(oe&&z){var ue=oe.match(t);j.minimumFraction=m(ue)?0:ue.length,j.maximumFraction=oe.length-1}}return j}function g(T,z){return T?(T=T.replace(n.defaultCurrency,z),""===z?T.trim():T):""}function v(T,z,U,B){return B?"$":Y("currencies."+z+(U?"."+U:".symbol"),T)||Y("currencies."+z+".symbol-alt-narrow",T)||"$"}function S(T,z,U){var B={type:"decimal",minimumFractionDigits:0,maximumFractionDigits:0},j=T.match(n.customRegex);if(m(j)||""===j[5]&&"N/A"!==T)return B.type=void 0,B;B.nlead=j[1],B.nend=j[10];var Q=j[6],oe=!!Q.match(/ $/g),ue=-1!==Q.replace(/ $/g,"").indexOf(" ");B.useGrouping=-1!==Q.indexOf(",")||ue,Q=Q.replace(/,/g,"");var fe=j[7];if(-1!==Q.indexOf("0")&&(B.minimumIntegerDigits=Q.length-Q.indexOf("0")),m(fe)||(B.minimumFractionDigits=fe.lastIndexOf("0"),B.maximumFractionDigits=fe.lastIndexOf("#"),-1===B.minimumFractionDigits&&(B.minimumFractionDigits=0),(-1===B.maximumFractionDigits||B.maximumFractionDigitsQ.lastIndexOf("'"))){B[""+a[parseInt(j.toString(),10)]]=Q.substr(0,oe)+U+Q.substr(oe+1),B[""+a[""+z]]=!0,B.type=B.isCurrency?"currency":"percent";break}}return B}function C(T,z){if(-1!==T.indexOf(",")){var U=T.split(",");T=U[0]+Y("numberMapper.numberSymbols.group",z)+U[1].replace(".",Y("numberMapper.numberSymbols.decimal",z))}else T=T.replace(".",Y("numberMapper.numberSymbols.decimal",z));return T}function A(T,z,U){T+=".";for(var B=0;B0;Q-=3)T=","+U[Q-2]+U[Q-1]+U[parseInt(Q.toString(),10)]+T;return T=T.slice(1),z[1]?T+"."+z[1]:T}n.dateParseRegex=/([a-z])\1*|'([^']|'')+'|''|./gi,n.basicPatterns=["short","medium","long","full"],n.defaultObject={dates:{calendars:{gregorian:{months:{"stand-alone":{abbreviated:{1:"Jan",2:"Feb",3:"Mar",4:"Apr",5:"May",6:"Jun",7:"Jul",8:"Aug",9:"Sep",10:"Oct",11:"Nov",12:"Dec"},narrow:{1:"J",2:"F",3:"M",4:"A",5:"M",6:"J",7:"J",8:"A",9:"S",10:"O",11:"N",12:"D"},wide:{1:"January",2:"February",3:"March",4:"April",5:"May",6:"June",7:"July",8:"August",9:"September",10:"October",11:"November",12:"December"}}},days:{"stand-alone":{abbreviated:{sun:"Sun",mon:"Mon",tue:"Tue",wed:"Wed",thu:"Thu",fri:"Fri",sat:"Sat"},narrow:{sun:"S",mon:"M",tue:"T",wed:"W",thu:"T",fri:"F",sat:"S"},short:{sun:"Su",mon:"Mo",tue:"Tu",wed:"We",thu:"Th",fri:"Fr",sat:"Sa"},wide:{sun:"Sunday",mon:"Monday",tue:"Tuesday",wed:"Wednesday",thu:"Thursday",fri:"Friday",sat:"Saturday"}}},dayPeriods:{format:{wide:{am:"AM",pm:"PM"}}},eras:{eraNames:{0:"Before Christ","0-alt-variant":"Before Common Era",1:"Anno Domini","1-alt-variant":"Common Era"},eraAbbr:{0:"BC","0-alt-variant":"BCE",1:"AD","1-alt-variant":"CE"},eraNarrow:{0:"B","0-alt-variant":"BCE",1:"A","1-alt-variant":"CE"}},dateFormats:{full:"EEEE, MMMM d, y",long:"MMMM d, y",medium:"MMM d, y",short:"M/d/yy"},timeFormats:{full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},dateTimeFormats:{full:"{1} 'at' {0}",long:"{1} 'at' {0}",medium:"{1}, {0}",short:"{1}, {0}",availableFormats:{d:"d",E:"ccc",Ed:"d E",Ehm:"E h:mm a",EHm:"E HH:mm",Ehms:"E h:mm:ss a",EHms:"E HH:mm:ss",Gy:"y G",GyMMM:"MMM y G",GyMMMd:"MMM d, y G",GyMMMEd:"E, MMM d, y G",h:"h a",H:"HH",hm:"h:mm a",Hm:"HH:mm",hms:"h:mm:ss a",Hms:"HH:mm:ss",hmsv:"h:mm:ss a v",Hmsv:"HH:mm:ss v",hmv:"h:mm a v",Hmv:"HH:mm v",M:"L",Md:"M/d",MEd:"E, M/d",MMM:"LLL",MMMd:"MMM d",MMMEd:"E, MMM d",MMMMd:"MMMM d",ms:"mm:ss",y:"y",yM:"M/y",yMd:"M/d/y",yMEd:"E, M/d/y",yMMM:"MMM y",yMMMd:"MMM d, y",yMMMEd:"E, MMM d, y",yMMMM:"MMMM y"}}},islamic:{months:{"stand-alone":{abbreviated:{1:"Muh.",2:"Saf.",3:"Rab. I",4:"Rab. II",5:"Jum. I",6:"Jum. II",7:"Raj.",8:"Sha.",9:"Ram.",10:"Shaw.",11:"Dhu\u02bbl-Q.",12:"Dhu\u02bbl-H."},narrow:{1:"1",2:"2",3:"3",4:"4",5:"5",6:"6",7:"7",8:"8",9:"9",10:"10",11:"11",12:"12"},wide:{1:"Muharram",2:"Safar",3:"Rabi\u02bb I",4:"Rabi\u02bb II",5:"Jumada I",6:"Jumada II",7:"Rajab",8:"Sha\u02bbban",9:"Ramadan",10:"Shawwal",11:"Dhu\u02bbl-Qi\u02bbdah",12:"Dhu\u02bbl-Hijjah"}}},days:{"stand-alone":{abbreviated:{sun:"Sun",mon:"Mon",tue:"Tue",wed:"Wed",thu:"Thu",fri:"Fri",sat:"Sat"},narrow:{sun:"S",mon:"M",tue:"T",wed:"W",thu:"T",fri:"F",sat:"S"},short:{sun:"Su",mon:"Mo",tue:"Tu",wed:"We",thu:"Th",fri:"Fr",sat:"Sa"},wide:{sun:"Sunday",mon:"Monday",tue:"Tuesday",wed:"Wednesday",thu:"Thursday",fri:"Friday",sat:"Saturday"}}},dayPeriods:{format:{wide:{am:"AM",pm:"PM"}}},eras:{eraNames:{0:"AH"},eraAbbr:{0:"AH"},eraNarrow:{0:"AH"}},dateFormats:{full:"EEEE, MMMM d, y G",long:"MMMM d, y G",medium:"MMM d, y G",short:"M/d/y GGGGG"},timeFormats:{full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},dateTimeFormats:{full:"{1} 'at' {0}",long:"{1} 'at' {0}",medium:"{1}, {0}",short:"{1}, {0}",availableFormats:{d:"d",E:"ccc",Ed:"d E",Ehm:"E h:mm a",EHm:"E HH:mm",Ehms:"E h:mm:ss a",EHms:"E HH:mm:ss",Gy:"y G",GyMMM:"MMM y G",GyMMMd:"MMM d, y G",GyMMMEd:"E, MMM d, y G",h:"h a",H:"HH",hm:"h:mm a",Hm:"HH:mm",hms:"h:mm:ss a",Hms:"HH:mm:ss",M:"L",Md:"M/d",MEd:"E, M/d",MMM:"LLL",MMMd:"MMM d",MMMEd:"E, MMM d",MMMMd:"MMMM d",ms:"mm:ss",y:"y G",yyyy:"y G",yyyyM:"M/y GGGGG",yyyyMd:"M/d/y GGGGG",yyyyMEd:"E, M/d/y GGGGG",yyyyMMM:"MMM y G",yyyyMMMd:"MMM d, y G",yyyyMMMEd:"E, MMM d, y G",yyyyMMMM:"MMMM y G",yyyyQQQ:"QQQ y G",yyyyQQQQ:"QQQQ y G"}}}},timeZoneNames:{hourFormat:"+HH:mm;-HH:mm",gmtFormat:"GMT{0}",gmtZeroFormat:"GMT"}},numbers:{currencies:{USD:{displayName:"US Dollar",symbol:"$","symbol-alt-narrow":"$"},EUR:{displayName:"Euro",symbol:"\u20ac","symbol-alt-narrow":"\u20ac"},GBP:{displayName:"British Pound","symbol-alt-narrow":"\xa3"}},defaultNumberingSystem:"latn",minimumGroupingDigits:"1","symbols-numberSystem-latn":{decimal:".",group:",",list:";",percentSign:"%",plusSign:"+",minusSign:"-",exponential:"E",superscriptingExponent:"\xd7",perMille:"\u2030",infinity:"\u221e",nan:"NaN",timeSeparator:":"},"decimalFormats-numberSystem-latn":{standard:"#,##0.###"},"percentFormats-numberSystem-latn":{standard:"#,##0%"},"currencyFormats-numberSystem-latn":{standard:"\xa4#,##0.00",accounting:"\xa4#,##0.00;(\xa4#,##0.00)"},"scientificFormats-numberSystem-latn":{standard:"#E0"}}},n.blazorDefaultObject={numbers:{mapper:{0:"0",1:"1",2:"2",3:"3",4:"4",5:"5",6:"6",7:"7",8:"8",9:"9"},mapperDigits:"0123456789",numberSymbols:{decimal:".",group:",",plusSign:"+",minusSign:"-",percentSign:"%",nan:"NaN",timeSeparator:":",infinity:"\u221e"},timeSeparator:":",currencySymbol:"$",currencypData:{nlead:"$",nend:"",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},percentpData:{nlead:"",nend:"%",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},percentnData:{nlead:"-",nend:"%",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},currencynData:{nlead:"($",nend:")",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},decimalnData:{nlead:"-",nend:"",groupData:{primary:3},maximumFraction:2,minimumFraction:2},decimalpData:{nlead:"",nend:"",groupData:{primary:3},maximumFraction:2,minimumFraction:2}},dates:{dayPeriods:{am:"AM",pm:"PM"},dateSeperator:"/",days:{abbreviated:{sun:"Sun",mon:"Mon",tue:"Tue",wed:"Wed",thu:"Thu",fri:"Fri",sat:"Sat"},short:{sun:"Su",mon:"Mo",tue:"Tu",wed:"We",thu:"Th",fri:"Fr",sat:"Sa"},wide:{sun:"Sunday",mon:"Monday",tue:"Tuesday",wed:"Wednesday",thu:"Thursday",fri:"Friday",sat:"Saturday"}},months:{abbreviated:{1:"Jan",2:"Feb",3:"Mar",4:"Apr",5:"May",6:"Jun",7:"Jul",8:"Aug",9:"Sep",10:"Oct",11:"Nov",12:"Dec"},wide:{1:"January",2:"February",3:"March",4:"April",5:"May",6:"June",7:"July",8:"August",9:"September",10:"October",11:"November",12:"December"}},eras:{1:"AD"}}},n.monthIndex={3:"abbreviated",4:"wide",5:"narrow",1:"abbreviated"},n.month="months",n.days="days",n.patternMatcher={C:"currency",P:"percent",N:"decimal",A:"currency",E:"scientific"},n.getResultantPattern=l,n.getDependables=h,n.getSymbolPattern=c,n.ConvertDateToWeekFormat=d,n.compareBlazorDateFormats=u,n.getProperNumericSkeleton=f,n.getFormatData=p,n.changeCurrencySymbol=g,n.getCurrencySymbol=v,n.customFormat=function y(T,z,U){for(var B={},j=T.split(";"),Q=["pData","nData","zeroData"],oe=0;oe1,fe.nData=ce()?Y(De.type+"nData",oe):p(ot[1]||"-"+ot[0],!0,Ie),fe.pData=ce()?Y(De.type+"pData",oe):p(ot[0],!1,Ie),!Me[2]&&!z.minimumFractionDigits&&!z.maximumFractionDigits&&(ue=p(Ve.split(";")[0],!0,"",!0).minimumFraction)}if(n.formatRegex.test(z.format)||!z.format){if(ze(Q,f(z.format||"N")),Q.custom=!1,$e="###0",(Q.fractionDigits||z.minimumFractionDigits||z.maximumFractionDigits||ue)&&(Q.fractionDigits&&(z.minimumFractionDigits=z.maximumFractionDigits=Q.fractionDigits),$e=A($e,ue||Q.fractionDigits||z.minimumFractionDigits||0,z.maximumFractionDigits||0)),z.minimumIntegerDigits&&($e=x($e,z.minimumIntegerDigits)),z.useGrouping&&($e=P($e)),"currency"===Q.type||Q.type&&ce()){ce()&&"currency"!==Q.type&&(fe.pData=Y(Q.type+"pData",oe),fe.nData=Y(Q.type+"nData",oe));var hr=$e;$e=fe.pData.nlead+hr+fe.pData.nend,(fe.hasNegativePattern||ce())&&($e+=";"+fe.nData.nlead+hr+fe.nData.nend)}"percent"===Q.type&&!ce()&&($e+=" %")}else $e=z.format.replace(/'/g,'"');return Object.keys(xe).length>0&&($e=B?$e:C($e,xe)),$e},n.fractionDigitsPattern=A,n.minimumIntegerPattern=x,n.groupingPattern=P,n.getWeekData=function L(T,z){var U="sun",B=Y("supplemental.weekData.firstDay",z),j=T;return/en-/.test(j)&&(j=j.slice(3)),j=j.slice(0,2).toUpperCase()+j.substr(2),B&&(U=B[""+j]||B[j.slice(0,2)]||"sun"),o[""+U]},n.replaceBlazorCurrency=function O(T,z,U){var B=function f$(n){return Y(n||"",u$)}(U);if(z!==B)for(var j=0,Q=T;j=0?U:U+7;var j=Math.floor((T.getTime()-z.getTime()-6e4*(T.getTimezoneOffset()-z.getTimezoneOffset()))/864e5)+1;if(U<4){if((B=Math.floor((j+U-1)/7)+1)>52){var oe=new Date(T.getFullYear()+1,0,1).getDay();B=(oe=oe>=0?oe:oe+7)<4?1:53}}else B=Math.floor((j+U-1)/7);return B}}(ut||(ut={}));var of=function(){function n(t,e,i){this.type="GET",this.emitError=!0,"string"==typeof t?(this.url=t,this.type=m(e)?this.type:e.toUpperCase(),this.contentType=i):La(t)&&Object.keys(t).length>0&&kn(this,t),this.contentType=m(this.contentType)?"application/json; charset=utf-8":this.contentType}return n.prototype.send=function(t){var e=this,i={"application/json":"json","multipart/form-data":"formData","application/octet-stream":"blob","application/x-www-form-urlencoded":"formData"};try{m(this.fetchRequest)&&"GET"===this.type?this.fetchRequest=new Request(this.url,{method:this.type}):m(this.fetchRequest)&&(this.data=m(t)?this.data:t,this.fetchRequest=new Request(this.url,{method:this.type,headers:{"Content-Type":this.contentType},body:this.data}));var r={cancel:!1,fetchRequest:this.fetchRequest};return this.triggerEvent(this.beforeSend,r),r.cancel?null:(this.fetchResponse=fetch(this.fetchRequest),this.fetchResponse.then(function(s){if(e.triggerEvent(e.onLoad,s),!s.ok)throw s;for(var o="text",a=0,l=Object.keys(i);a-1},n.getValue=function(t,e){var i=typeof window<"u"?window.browserDetails:{};return typeof navigator<"u"&&"MacIntel"===navigator.platform&&navigator.maxTouchPoints>1&&!0===n.isTouch&&!vC.CHROME.test(navigator.userAgent)&&(i.isIos=!0,i.isDevice=!0,i.isTouch=!0,i.isPointer=!0,i.isPointer="pointerEnabled"in window.navigator),typeof window<"u"&&window.Capacitor&&"ios"===window.Capacitor.getPlatform()&&(i.isPointer=!1),typeof i[""+t]>"u"?i[""+t]=e.test(n.userAgent):i[""+t]},Object.defineProperty(n,"userAgent",{get:function(){return n.uA},set:function(t){n.uA=t,window.browserDetails={}},enumerable:!0,configurable:!0}),Object.defineProperty(n,"info",{get:function(){return st(window.browserDetails.info)?window.browserDetails.info=n.extractBrowserDetail():window.browserDetails.info},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isIE",{get:function(){return n.getValue("isIE",A$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isTouch",{get:function(){return st(window.browserDetails.isTouch)?window.browserDetails.isTouch="ontouchstart"in window.navigator||window&&window.navigator&&window.navigator.maxTouchPoints>0||"ontouchstart"in window:window.browserDetails.isTouch},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isPointer",{get:function(){return st(window.browserDetails.isPointer)?window.browserDetails.isPointer="pointerEnabled"in window.navigator:window.browserDetails.isPointer},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isMSPointer",{get:function(){return st(window.browserDetails.isMSPointer)?window.browserDetails.isMSPointer="msPointerEnabled"in window.navigator:window.browserDetails.isMSPointer},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isDevice",{get:function(){return n.getValue("isDevice",T$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isIos",{get:function(){return n.getValue("isIos",N$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isIos7",{get:function(){return n.getValue("isIos7",O$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isAndroid",{get:function(){return n.getValue("isAndroid",k$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isWebView",{get:function(){return st(window.browserDetails.isWebView)&&(window.browserDetails.isWebView=!(st(window.cordova)&&st(window.PhoneGap)&&st(window.phonegap)&&"object"!==window.forge)),window.browserDetails.isWebView},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isWindows",{get:function(){return n.getValue("isWindows",P$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"touchStartEvent",{get:function(){return st(window.browserDetails.touchStartEvent)?window.browserDetails.touchStartEvent=n.getTouchStartEvent():window.browserDetails.touchStartEvent},enumerable:!0,configurable:!0}),Object.defineProperty(n,"touchMoveEvent",{get:function(){return st(window.browserDetails.touchMoveEvent)?window.browserDetails.touchMoveEvent=n.getTouchMoveEvent():window.browserDetails.touchMoveEvent},enumerable:!0,configurable:!0}),Object.defineProperty(n,"touchEndEvent",{get:function(){return st(window.browserDetails.touchEndEvent)?window.browserDetails.touchEndEvent=n.getTouchEndEvent():window.browserDetails.touchEndEvent},enumerable:!0,configurable:!0}),Object.defineProperty(n,"touchCancelEvent",{get:function(){return st(window.browserDetails.touchCancelEvent)?window.browserDetails.touchCancelEvent=n.getTouchCancelEvent():window.browserDetails.touchCancelEvent},enumerable:!0,configurable:!0}),n.uA=typeof navigator<"u"?navigator.userAgent:"",n}(),E=function(){function n(){}return n.addOrGetEventData=function(t){return"__eventList"in t?t.__eventList.events:(t.__eventList={},t.__eventList.events=[])},n.add=function(t,e,i,r,s){var a,o=n.addOrGetEventData(t);a=s?function l$(n,t){var e;return function(){for(var i=this,r=[],s=0;s"u"||(e.innerHTML=t.innerHTML?t.innerHTML:"",void 0!==t.className&&(e.className=t.className),void 0!==t.id&&(e.id=t.id),void 0!==t.styles&&e.setAttribute("style",t.styles),void 0!==t.attrs&&Fe(e,t.attrs)),e}function V(n,t){for(var e=Vz(t),i=RegExp,r=0,s=n;r0}function gl(n,t,e){for(var i=document.createDocumentFragment(),r=0,s=n;r0;)i.appendChild(n[0]);else for(var r=0,s=n;r-1&&!r[parseInt(s.toString(),10)].match(/\[.*\]/)){var o=r[parseInt(s.toString(),10)].split("#");if(o[1].match(/^\d/)||o[1].match(t)){var a=r[parseInt(s.toString(),10)].split(".");a[0]=a[0].replace(/#/,"[id='")+"']",r[parseInt(s.toString(),10)]=a.join(".")}}e[parseInt(i.toString(),10)]=r.join(" ")}return e.join(",")}return n}function J(n,t){var e=n;if("function"==typeof e.closest)return e.closest(t);for(;e&&1===e.nodeType;){if(mC(e,t))return e;e=e.parentNode}return null}function je(n,t){void 0!==t&&Object.keys(t).forEach(function(e){n.style[""+e]=t[""+e]})}function mC(n,t){var e=n.matches||n.msMatchesSelector||n.webkitMatchesSelector;return e?e.call(n,t):-1!==[].indexOf.call(document.querySelectorAll(t),n)}var H$=new RegExp("]"),dh=function(){function n(t,e){this.isRendered=!1,this.isComplexArraySetter=!1,this.isServerRendered=!1,this.allowServerDataBinding=!0,this.isProtectedOnChange=!0,this.properties={},this.changedProperties={},this.oldProperties={},this.bulkChanges={},this.refreshing=!1,this.ignoreCollectionWatch=!1,this.finalUpdate=function(){},this.childChangedProperties={},this.modelObserver=new Ng(this),st(e)||(this.element="string"==typeof e?document.querySelector(e):e,m(this.element)||(this.isProtectedOnChange=!1,this.addInstance())),st(t)||this.setProperties(t,!0),this.isDestroyed=!1}return n.prototype.setProperties=function(t,e){var i=this.isProtectedOnChange;this.isProtectedOnChange=!!e,kn(this,t),!0!==e?(kn(this.changedProperties,t),this.dataBind()):ce()&&this.isRendered&&this.serverDataBind(t),this.finalUpdate(),this.changedProperties={},this.oldProperties={},this.isProtectedOnChange=i},n.callChildDataBind=function(t,e){for(var r=0,s=Object.keys(t);r=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Hs=function(n){function t(i){var r=n.call(this,i,void 0)||this;return r.easing={ease:"cubic-bezier(0.250, 0.100, 0.250, 1.000)",linear:"cubic-bezier(0.250, 0.250, 0.750, 0.750)",easeIn:"cubic-bezier(0.420, 0.000, 1.000, 1.000)",easeOut:"cubic-bezier(0.000, 0.000, 0.580, 1.000)",easeInOut:"cubic-bezier(0.420, 0.000, 0.580, 1.000)",elasticInOut:"cubic-bezier(0.5,-0.58,0.38,1.81)",elasticIn:"cubic-bezier(0.17,0.67,0.59,1.81)",elasticOut:"cubic-bezier(0.7,-0.75,0.99,1.01)"},r}var e;return X$(t,n),e=t,t.prototype.animate=function(i,r){var s=this.getModel(r=r||{});if("string"==typeof i)for(var a=0,l=Array.prototype.slice.call(we(i,document));a0?r-1:0,i+=e=-1!==e?"-"+e:"-"+r}return this.controlParent!==this.parentObj&&(i=this.parentObj.getParentKey()+"."+this.propName+e),i},n}(),J$=["grid","pivotview","treegrid","spreadsheet","rangeNavigator","DocumentEditor","listbox","inplaceeditor","PdfViewer","richtexteditor","DashboardLayout","chart","stockChart","circulargauge","diagram","heatmap","lineargauge","maps","slider","smithchart","barcode","sparkline","treemap","bulletChart","kanban","daterangepicker","schedule","gantt","signature","query-builder","drop-down-tree","carousel","filemanager","uploader","accordion","tab","treeview"],tR=[115,121,110,99,102,117,115,105,111,110,46,105,115,76,105,99,86,97,108,105,100,97,116,101,100],iR=function(){function n(t){this.isValidated=!1,this.isLicensed=!0,this.version="27",this.platform=/JavaScript|ASPNET|ASPNETCORE|ASPNETMVC|FileFormats|essentialstudio/i,this.errors={noLicense:"This application was built using a trial version of Syncfusion Essential Studio. To remove the license validation message permanently, a valid license key must be included.",trailExpired:"This application was built using a trial version of Syncfusion Essential Studio. To remove the license validation message permanently, a valid license key must be included.",versionMismatched:"The included Syncfusion license key is invalid.",platformMismatched:"The included Syncfusion license key is invalid.",invalidKey:"The included Syncfusion license key is invalid."},this.manager=function(){var e=null;return{setKey:function i(s){e=s},getKey:function r(){return e}}}(),this.npxManager=function(){return{getKey:function i(){return"npxKeyReplace"}}}(),this.manager.setKey(t)}return n.prototype.validate=function(){if(!this.isValidated&&nf&&!Y(A0(tR),nf)&&!Y("Blazor",nf)){var i=void 0,r=void 0;if(this.manager&&this.manager.getKey()||this.npxManager&&"npxKeyReplace"!==this.npxManager.getKey()){var s=this.getInfoFromKey();if(s&&s.length)for(var o=0,a=s;o"+i+' Claim your FREE account\n
have a Syncfusion account? Sign In
\n
\n ';if(typeof document<"u"&&!m(document)){var t=Si("div",{innerHTML:n});document.body.appendChild(t)}}(),oR=!0),this.render(),this.mount?this.accessMount():this.trigger("created")}},t.prototype.renderComplete=function(e){ce()&&window.sfBlazor.renderComplete(this.element,e),this.isRendered=!0},t.prototype.dataBind=function(){this.injectModules(),n.prototype.dataBind.call(this)},t.prototype.on=function(e,i,r){if("string"==typeof e)this.localObserver.on(e,i,r);else for(var s=0,o=e;s=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},rZ={left:0,top:0,bottom:0,right:0},MC={isDragged:!1},nZ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return aR(t,n),gr([I(0)],t.prototype,"left",void 0),gr([I(0)],t.prototype,"top",void 0),t}(Ee),hf=function(n){function t(i,r){var s=n.call(this,r,i)||this;return s.dragLimit=e.getDefaultPosition(),s.borderWidth=e.getDefaultPosition(),s.padding=e.getDefaultPosition(),s.diffX=0,s.prevLeft=0,s.prevTop=0,s.dragProcessStarted=!1,s.eleTop=0,s.tapHoldTimer=0,s.externalInitialize=!1,s.diffY=0,s.parentScrollX=0,s.parentScrollY=0,s.droppables={},s.bind(),s}var e;return aR(t,n),e=t,t.prototype.bind=function(){this.toggleEvents(),X.isIE&&V([this.element],"e-block-touch"),this.droppables[this.scope]={}},t.getDefaultPosition=function(){return ze({},rZ)},t.prototype.toggleEvents=function(i){var r;st(this.handle)||(r=_(this.handle,this.element));var s=this.enableTapHold&&X.isDevice&&X.isTouch?this.mobileInitialize:this.initialize;i?E.remove(r||this.element,X.isSafari()?"touchstart":X.touchStartEvent,s):E.add(r||this.element,X.isSafari()?"touchstart":X.touchStartEvent,s,this)},t.prototype.mobileInitialize=function(i){var r=this,s=i.currentTarget;this.tapHoldTimer=setTimeout(function(){r.externalInitialize=!0,r.removeTapholdTimer(),r.initialize(i,s)},this.tapHoldThreshold),E.add(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.removeTapholdTimer,this),E.add(document,X.isSafari()?"touchend":X.touchEndEvent,this.removeTapholdTimer,this)},t.prototype.removeTapholdTimer=function(){clearTimeout(this.tapHoldTimer),E.remove(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.removeTapholdTimer),E.remove(document,X.isSafari()?"touchend":X.touchEndEvent,this.removeTapholdTimer)},t.prototype.getScrollableParent=function(i,r){return m(i)?null:i[{vertical:"scrollHeight",horizontal:"scrollWidth"}[""+r]]>i[{vertical:"clientHeight",horizontal:"clientWidth"}[""+r]]&&("vertical"===r?i.scrollTop>0:i.scrollLeft>0)?("vertical"===r?(this.parentScrollY=this.parentScrollY+(0===this.parentScrollY?i.scrollTop:i.scrollTop-this.parentScrollY),this.tempScrollHeight=i.scrollHeight):(this.parentScrollX=this.parentScrollX+(0===this.parentScrollX?i.scrollLeft:i.scrollLeft-this.parentScrollX),this.tempScrollWidth=i.scrollWidth),m(i)?i:this.getScrollableParent(i.parentNode,r)):this.getScrollableParent(i.parentNode,r)},t.prototype.getScrollableValues=function(){this.parentScrollX=0,this.parentScrollY=0,this.element.classList.contains("e-dialog")&&this.element.classList.contains("e-dlg-modal"),this.getScrollableParent(this.element.parentNode,"vertical"),this.getScrollableParent(this.element.parentNode,"horizontal")},t.prototype.initialize=function(i,r){if(this.currentStateTarget=i.target,!this.isDragStarted()){if(this.isDragStarted(!0),this.externalInitialize=!1,this.target=i.currentTarget||r,this.dragProcessStarted=!1,this.abort){var s=this.abort;"string"==typeof s&&(s=[s]);for(var o=0;o=this.distance||this.externalInitialize){var f=this.getHelperElement(i);if(!f||m(f))return;r&&i.preventDefault();var p=this.helperElement=f;if(this.parentClientRect=this.calculateParentPosition(p.offsetParent),this.dragStart){var v={event:i,element:l,target:this.getProperTargetElement(i),bindEvents:ce()?this.bindDragEvents.bind(this):null,dragElement:p};this.trigger("dragStart",v)}this.dragArea?this.setDragArea():(this.dragLimit={left:0,right:0,bottom:0,top:0},this.borderWidth={top:0,left:0}),o={left:this.position.left-this.parentClientRect.left,top:this.position.top-this.parentClientRect.top},this.clone&&!this.enableTailMode&&(this.diffX=this.position.left-this.offset.left,this.diffY=this.position.top-this.offset.top),this.getScrollableValues();var y=getComputedStyle(l),S=parseFloat(y.marginTop);this.clone&&0!==S&&(o.top+=S),this.eleTop=isNaN(parseFloat(y.top))?0:parseFloat(y.top)-this.offset.top,this.enableScrollHandler&&!this.clone&&(o.top-=this.parentScrollY,o.left-=this.parentScrollX);var b=this.getProcessedPositionValue({top:o.top-this.diffY+"px",left:o.left-this.diffX+"px"});this.dragArea&&"string"!=typeof this.dragArea&&this.dragArea.classList.contains("e-kanban-content")&&"relative"===this.dragArea.style.position&&(o.top+=this.dragArea.scrollTop),this.dragElePosition={top:o.top,left:o.left},je(p,this.getDragPosition({position:"absolute",left:b.left,top:b.top})),E.remove(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.intDragStart),E.remove(document,X.isSafari()?"touchend":X.touchEndEvent,this.intDestroy),ce()||this.bindDragEvents(p)}}},t.prototype.bindDragEvents=function(i){Tr(i)?(E.add(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.intDrag,this),E.add(document,X.isSafari()?"touchend":X.touchEndEvent,this.intDragStop,this),this.setGlobalDroppables(!1,this.element,i)):(this.toggleEvents(),document.body.classList.remove("e-prevent-select"))},t.prototype.elementInViewport=function(i){for(this.top=i.offsetTop,this.left=i.offsetLeft,this.width=i.offsetWidth,this.height=i.offsetHeight;i.offsetParent;)this.top+=(i=i.offsetParent).offsetTop,this.left+=i.offsetLeft;return this.top>=window.pageYOffset&&this.left>=window.pageXOffset&&this.top+this.height<=window.pageYOffset+window.innerHeight&&this.left+this.width<=window.pageXOffset+window.innerWidth},t.prototype.getProcessedPositionValue=function(i){return this.queryPositionInfo?this.queryPositionInfo(i):i},t.prototype.calculateParentPosition=function(i){if(m(i))return{left:0,top:0};var r=i.getBoundingClientRect(),s=getComputedStyle(i);return{left:r.left+window.pageXOffset-parseInt(s.marginLeft,10),top:r.top+window.pageYOffset-parseInt(s.marginTop,10)}},t.prototype.intDrag=function(i){if(st(i.changedTouches)||1===i.changedTouches.length){var r,s;this.clone&&i.changedTouches&&X.isDevice&&X.isTouch&&i.preventDefault(),this.position=this.getMousePosition(i,this.isDragScroll);var o=this.getDocumentWidthHeight("Height");oy&&y>0?this.dragLimit.left:this.dragLimit.right+window.pageXOffset0?y-(y-this.dragLimit.right)+window.pageXOffset-M:y<0?this.dragLimit.left:y}if(this.pageY!==v||this.skipDistanceCheck){var w=d.offsetHeight+(parseFloat(b.marginTop)+parseFloat(b.marginBottom));s=this.dragLimit.top>S&&S>0?this.dragLimit.top:this.dragLimit.bottom+window.pageYOffset0?S-(S-this.dragLimit.bottom)+window.pageYOffset-w:S<0?this.dragLimit.top:S}}else r=y,s=S;var A,x,C=f+this.borderWidth.top,D=u+this.borderWidth.left;if(this.dragProcessStarted&&(m(s)&&(s=this.prevTop),m(r)&&(r=this.prevLeft)),this.helperElement.classList.contains("e-treeview"))this.dragArea?(this.dragLimit.top=this.clone?this.dragLimit.top:0,A=s-C<0?this.dragLimit.top:s-this.borderWidth.top,x=r-D<0?this.dragLimit.left:r-this.borderWidth.left):(A=s-this.borderWidth.top,x=r-this.borderWidth.left);else if(this.dragArea){var P=this.helperElement.classList.contains("e-dialog");this.dragLimit.top=this.clone?this.dragLimit.top:0,A=s-C<0?this.dragLimit.top:s-C,x=r-D<0?P?r-(D-this.borderWidth.left):this.dragElePosition.left:r-D}else A=s-C,x=r-D;var L=parseFloat(getComputedStyle(this.element).marginTop);if(L>0&&(this.clone&&(A+=L,S<0&&(L+S>=0?A=L+S:A-=L),this.dragArea&&(A=this.dragLimit.bottom=0){var O=this.dragLimit.top+S-C;O+L+C<0?A-=L+C:A=O}else A-=L+C;this.dragArea&&this.helperElement.classList.contains("e-treeview")&&(A=A+(w=d.offsetHeight+(parseFloat(b.marginTop)+parseFloat(b.marginBottom)))>this.dragLimit.bottom?this.dragLimit.bottom-w:A),this.enableScrollHandler&&!this.clone&&(A-=this.parentScrollY,x-=this.parentScrollX),this.dragArea&&"string"!=typeof this.dragArea&&this.dragArea.classList.contains("e-kanban-content")&&"relative"===this.dragArea.style.position&&(A+=this.dragArea.scrollTop);var N=this.getProcessedPositionValue({top:A+"px",left:x+"px"});this.isPreventScroll&&(N=this.getProcessedPositionValue({top:this.position.top-this.parentClientRect.top-2+"px",left:this.position.left-this.parentClientRect.left-2+"px"})),je(d,this.getDragPosition(N)),!this.elementInViewport(d)&&this.enableAutoScroll&&!this.helperElement.classList.contains("e-treeview")&&this.helperElement.scrollIntoView();var T=document.querySelectorAll(":hover");if(this.enableAutoScroll&&this.helperElement.classList.contains("e-treeview")){0===T.length&&(T=this.getPathElements(i));var z=this.getScrollParent(T,!1);this.elementInViewport(this.helperElement)?this.getScrollPosition(z,A):this.elementInViewport(this.helperElement)||(0===(T=[].slice.call(document.querySelectorAll(":hover"))).length&&(T=this.getPathElements(i)),z=this.getScrollParent(T,!0),this.getScrollPosition(z,A))}this.dragProcessStarted=!0,this.prevLeft=r,this.prevTop=s,this.position.left=r,this.position.top=s,this.pageX=g,this.pageY=v}},t.prototype.getScrollParent=function(i,r){for(var o,s=r?i.reverse():i,a=s.length-1;a>=0;a--)if(("auto"===(o=window.getComputedStyle(s[parseInt(a.toString(),10)])["overflow-y"])||"scroll"===o)&&s[parseInt(a.toString(),10)].scrollHeight>s[parseInt(a.toString(),10)].clientHeight)return s[parseInt(a.toString(),10)];if("visible"===(o=window.getComputedStyle(document.scrollingElement)["overflow-y"]))return document.scrollingElement.style.overflow="auto",document.scrollingElement},t.prototype.getScrollPosition=function(i,r){if(i&&i===document.scrollingElement)i.clientHeight+document.scrollingElement.scrollTop-this.helperElement.clientHeightr?i.scrollTop+=this.helperElement.clientHeight:i.scrollTop>r-this.helperElement.clientHeight&&(i.scrollTop-=this.helperElement.clientHeight);else if(i&&i!==document.scrollingElement){var s=document.scrollingElement.scrollTop,o=this.helperElement.clientHeight;i.clientHeight+i.getBoundingClientRect().top-o+sr-o-s&&(i.scrollTop-=this.helperElement.clientHeight)}},t.prototype.getPathElements=function(i){return document.elementsFromPoint(i.clientX>0?i.clientX:0,i.clientY>0?i.clientY:0)},t.prototype.triggerOutFunction=function(i,r){this.hoverObject.instance.intOut(i,r.target),this.hoverObject.instance.dragData[this.scope]=null,this.hoverObject=null},t.prototype.getDragPosition=function(i){var r=ze({},i);return this.axis&&("x"===this.axis?delete r.top:"y"===this.axis&&delete r.left),r},t.prototype.getDocumentWidthHeight=function(i){var r=document.body,s=document.documentElement;return Math.max(r["scroll"+i],s["scroll"+i],r["offset"+i],s["offset"+i],s["client"+i])},t.prototype.intDragStop=function(i){if(this.dragProcessStarted=!1,st(i.changedTouches)||1===i.changedTouches.length){if(-1!==["touchend","pointerup","mouseup"].indexOf(i.type)){if(this.dragStop){var s=this.getProperTargetElement(i);this.trigger("dragStop",{event:i,element:this.element,target:s,helper:this.helperElement})}this.intDestroy(i)}else this.element.setAttribute("aria-grabbed","false");var o=this.checkTargetElement(i);o.target&&o.instance&&(o.instance.dragStopCalled=!0,o.instance.dragData[this.scope]=this.droppables[this.scope],o.instance.intDrop(i,o.target)),this.setGlobalDroppables(!0),document.body.classList.remove("e-prevent-select")}},t.prototype.intDestroy=function(i){this.dragProcessStarted=!1,this.toggleEvents(),document.body.classList.remove("e-prevent-select"),this.element.setAttribute("aria-grabbed","false"),E.remove(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.intDragStart),E.remove(document,X.isSafari()?"touchend":X.touchEndEvent,this.intDragStop),E.remove(document,X.isSafari()?"touchend":X.touchEndEvent,this.intDestroy),E.remove(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.intDrag),this.isDragStarted()&&this.isDragStarted(!0)},t.prototype.onPropertyChanged=function(i,r){},t.prototype.getModuleName=function(){return"draggable"},t.prototype.isDragStarted=function(i){return i&&(MC.isDragged=!MC.isDragged),MC.isDragged},t.prototype.setDragArea=function(){var i,r,a,s=0,o=0;if(a="string"==typeof this.dragArea?_(this.dragArea):this.dragArea){var h=a.getBoundingClientRect();i=a.scrollWidth?a.scrollWidth:h.right-h.left,r=a.scrollHeight?this.dragArea&&!m(this.helperElement)&&this.helperElement.classList.contains("e-treeview")?a.clientHeight:a.scrollHeight:h.bottom-h.top;for(var c=["Top","Left","Bottom","Right"],d=getComputedStyle(a),u=0;u12;return E0(i.target,this.helperElement)||-1!==i.type.indexOf("touch")||a?(this.helperElement.style.pointerEvents="none",s=document.elementFromPoint(r.clientX,r.clientY),this.helperElement.style.pointerEvents=o):s=i.target,s},t.prototype.currentStateCheck=function(i,r){return m(this.currentStateTarget)||this.currentStateTarget===i?m(r)?i:r:this.currentStateTarget},t.prototype.getMousePosition=function(i,r){var a,l,s=void 0!==i.srcElement?i.srcElement:i.target,o=this.getCoordinates(i),h=m(s.offsetParent);if(r?(a=this.clone?o.pageX:o.pageX+(h?0:s.offsetParent.scrollLeft)-this.relativeXPosition,l=this.clone?o.pageY:o.pageY+(h?0:s.offsetParent.scrollTop)-this.relativeYPosition):(a=this.clone?o.pageX:o.pageX+window.pageXOffset-this.relativeXPosition,l=this.clone?o.pageY:o.pageY+window.pageYOffset-this.relativeYPosition),document.scrollingElement&&!r&&!this.clone){var c=document.scrollingElement;a=c.scrollWidth>0&&c.scrollWidth>c.clientWidth&&c.scrollLeft>0?a-c.scrollLeft:a,l=c.scrollHeight>0&&c.scrollHeight>c.clientHeight&&c.scrollTop>0?l-c.scrollTop:l}return{left:a-(this.margin.left+this.cursorAt.left),top:l-(this.margin.top+this.cursorAt.top)}},t.prototype.getCoordinates=function(i){return i.type.indexOf("touch")>-1?i.changedTouches[0]:i},t.prototype.getHelperElement=function(i){var r;return this.clone?this.helper?r=this.helper({sender:i,element:this.target}):(r=Si("div",{className:"e-drag-helper e-block-touch",innerHTML:"Draggable"}),document.body.appendChild(r)):r=this.element,r},t.prototype.setGlobalDroppables=function(i,r,s){this.droppables[this.scope]=i?null:{draggable:r,helper:s,draggedElement:this.element}},t.prototype.checkTargetElement=function(i){var r=this.getProperTargetElement(i),s=this.getDropInstance(r);if(!s&&r&&!m(r.parentNode)){var o=J(r.parentNode,".e-droppable")||r.parentElement;o&&(s=this.getDropInstance(o))}return{target:r,instance:s}},t.prototype.getDropInstance=function(i){var s,o=i&&i.ej2_instances;if(o)for(var a=0,l=o;a=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},lR=function(n){function t(e,i){var r=n.call(this,i,e)||this;return r.mouseOver=!1,r.dragData={},r.dragStopCalled=!1,r.bind(),r}return sZ(t,n),t.prototype.bind=function(){this.wireEvents()},t.prototype.wireEvents=function(){E.add(this.element,X.isSafari()?"touchend":X.touchEndEvent,this.intDrop,this)},t.prototype.onPropertyChanged=function(e,i){},t.prototype.getModuleName=function(){return"droppable"},t.prototype.intOver=function(e,i){this.mouseOver||(this.trigger("over",{event:e,target:i,dragData:this.dragData[this.scope]}),this.mouseOver=!0)},t.prototype.intOut=function(e,i){this.mouseOver&&(this.trigger("out",{evt:e,target:i}),this.mouseOver=!1)},t.prototype.intDrop=function(e,i){if(this.dragStopCalled){this.dragStopCalled=!1;var a,r=!0,s=this.dragData[this.scope],o=!!s&&s.helper&&Tr(s.helper);o&&(a=this.isDropArea(e,s.helper,i),this.accept&&(r=mC(s.helper,this.accept))),o&&this.drop&&a.canDrop&&r&&this.trigger("drop",{event:e,target:a.target,droppedElement:s.helper,dragData:s}),this.mouseOver=!1}},t.prototype.isDropArea=function(e,i,r){var s={canDrop:!0,target:r||e.target},o="touchend"===e.type;if(o||s.target===i){i.style.display="none";var a=o?e.changedTouches[0]:e,l=document.elementFromPoint(a.clientX,a.clientY);s.canDrop=!1,s.canDrop=E0(l,this.element),s.canDrop&&(s.target=l),i.style.display=""}return s},t.prototype.destroy=function(){E.remove(this.element,X.isSafari()?"touchend":X.touchEndEvent,this.intDrop),n.prototype.destroy.call(this)},cf([I()],t.prototype,"accept",void 0),cf([I("default")],t.prototype,"scope",void 0),cf([H()],t.prototype,"drop",void 0),cf([H()],t.prototype,"over",void 0),cf([H()],t.prototype,"out",void 0),cf([Ft],t)}(dh),uo=function(){function n(t,e,i){this.controlName=t,this.localeStrings=e,this.setLocale(i||"en-US")}return n.prototype.setLocale=function(t){var e=this.intGetControlConstant(n.locale,t);this.currentLocale=e||this.localeStrings},n.load=function(t){this.locale=ze(this.locale,t,{},!0)},n.prototype.getConstant=function(t){return m(this.currentLocale[""+t])?this.localeStrings[""+t]||"":this.currentLocale[""+t]},n.prototype.intGetControlConstant=function(t,e){return t[""+e]?t[""+e][this.controlName]:null},n.locale={},n}(),hR=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),fh=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},lZ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return hR(t,n),fh([I(50)],t.prototype,"swipeThresholdDistance",void 0),t}(Ee),hZ=/(Up|Down)/,Fs=function(n){function t(e,i){var r=n.call(this,i,e)||this;return r.touchAction=!0,r.tapCount=0,r.startEvent=function(s){if(!0===r.touchAction){var o=r.updateChangeTouches(s);void 0!==s.changedTouches&&(r.touchAction=!1),r.isTouchMoved=!1,r.movedDirection="",r.startPoint=r.lastMovedPoint={clientX:o.clientX,clientY:o.clientY},r.startEventData=o,r.hScrollLocked=r.vScrollLocked=!1,r.tStampStart=Date.now(),r.timeOutTapHold=setTimeout(function(){r.tapHoldEvent(s)},r.tapHoldThreshold),E.add(r.element,X.touchMoveEvent,r.moveEvent,r),E.add(r.element,X.touchEndEvent,r.endEvent,r),E.add(r.element,X.touchCancelEvent,r.cancelEvent,r)}},r.moveEvent=function(s){var o=r.updateChangeTouches(s);r.movedPoint=o,r.isTouchMoved=!(o.clientX===r.startPoint.clientX&&o.clientY===r.startPoint.clientY);var a={};r.isTouchMoved&&(clearTimeout(r.timeOutTapHold),r.calcScrollPoints(s),a=ze(a,{},{startEvents:r.startEventData,originalEvent:s,startX:r.startPoint.clientX,startY:r.startPoint.clientY,distanceX:r.distanceX,distanceY:r.distanceY,scrollDirection:r.scrollDirection,velocity:r.getVelocity(o)}),r.trigger("scroll",a),r.lastMovedPoint={clientX:o.clientX,clientY:o.clientY})},r.cancelEvent=function(s){clearTimeout(r.timeOutTapHold),clearTimeout(r.timeOutTap),r.tapCount=0,r.swipeFn(s),E.remove(r.element,X.touchCancelEvent,r.cancelEvent)},r.endEvent=function(s){r.swipeFn(s),r.isTouchMoved||"function"==typeof r.tap&&(r.trigger("tap",{originalEvent:s,tapCount:++r.tapCount}),r.timeOutTap=setTimeout(function(){r.tapCount=0},r.tapThreshold)),r.modeclear()},r.swipeFn=function(s){clearTimeout(r.timeOutTapHold),clearTimeout(r.timeOutTap);var o=r.updateChangeTouches(s),a=o.clientX-r.startPoint.clientX,l=o.clientY-r.startPoint.clientY;a=Math.floor(a<0?-1*a:a),l=Math.floor(l<0?-1*l:a),r.isTouchMoved=a>1||l>1,/Firefox/.test(X.userAgent)&&0===o.clientX&&0===o.clientY&&"mouseup"===s.type&&(r.isTouchMoved=!1),r.endPoint=o,r.calcPoints(s);var c={originalEvent:s,startEvents:r.startEventData,startX:r.startPoint.clientX,startY:r.startPoint.clientY,distanceX:r.distanceX,distanceY:r.distanceY,swipeDirection:r.movedDirection,velocity:r.getVelocity(o)};if(r.isTouchMoved){var d=r.swipeSettings.swipeThresholdDistance,u=ze(void 0,r.defaultArgs,c),f=!1,p=r.element,g=r.isScrollable(p),v=hZ.test(r.movedDirection);(dthis.distanceY?i.clientX>this.startPoint.clientX?"Right":"Left":i.clientYthis.distanceY||!0===this.hScrollLocked)&&!1===this.vScrollLocked?(this.scrollDirection=i.clientX>this.lastMovedPoint.clientX?"Right":"Left",this.hScrollLocked=!0):(this.scrollDirection=i.clientY=e[r[0]+s[0]]},t.prototype.updateChangeTouches=function(e){return e.changedTouches&&0!==e.changedTouches.length?e.changedTouches[0]:e},fh([H()],t.prototype,"tap",void 0),fh([H()],t.prototype,"tapHold",void 0),fh([H()],t.prototype,"swipe",void 0),fh([H()],t.prototype,"scroll",void 0),fh([I(350)],t.prototype,"tapThreshold",void 0),fh([I(750)],t.prototype,"tapHoldThreshold",void 0),fh([re({},lZ)],t.prototype,"swipeSettings",void 0),fh([Ft],t)}(dh),cZ=new RegExp("\\n|\\r|\\s\\s+","g"),dZ=new RegExp(/'|"/g),uZ=new RegExp("if ?\\("),fZ=new RegExp("else if ?\\("),cR=new RegExp("else"),pZ=new RegExp("for ?\\("),dR=new RegExp("(/if|/for)"),gZ=new RegExp("\\((.*)\\)",""),wC=new RegExp("^[0-9]+$","g"),vZ=new RegExp("[\\w\"'.\\s+]+","g"),mZ=new RegExp('"(.*?)"',"g"),yZ=new RegExp("[\\w\"'@#$.\\s-+]+","g"),uR=new RegExp("\\${([^}]*)}","g"),SZ=/^\..*/gm,CC=/\\/gi,IZ=/\\\\/gi,bZ=new RegExp("[\\w\"'@#$.\\s+]+","g"),MZ=/\window\./gm;function df(n,t,e,i,r){return!t||wC.test(n)||-1!==i.indexOf(n.split(".")[0])||r||"true"===n||"false"===n?n:e+"."+n}function EC(n,t,e,i){return t&&!wC.test(n)&&-1===i.indexOf(n.split(".")[0])?e+'["'+n:n}function fR(n){return n.match(IZ)?n:n.replace(CC,"\\\\")}function pR(n,t,e,i){if(n=n.trim(),/\window\./gm.test(n))return n;var s=/'|"/gm;return/@|\$|#/gm.test(n)&&(n=EC(n,-1===e.indexOf(n),t,e)+'"]'),SZ.test(n)?function EZ(n,t,e,i){return!t||wC.test(n)||-1!==i.indexOf(n.split(".")[0])||/^\..*/gm.test(n)?n:e+"."+n}(n,!s.test(n)&&-1===e.indexOf(n),t,e):df(n,!s.test(n)&&-1===e.indexOf(n),t,e,i)}var DZ=/^[\n\r.]+0&&t.forEach(function(e){he(e)})},n.removeJsEvents=function(){var t=this.wrapElement.querySelectorAll("["+vR.join("],[")+"]");t.length>0&&t.forEach(function(e){vR.forEach(function(i){e.hasAttribute(i)&&e.removeAttribute(i)})})},n.removeXssAttrs=function(){var t=this;this.removeAttrs.forEach(function(e,i){var r=t.wrapElement.querySelectorAll(e.selector);r.length>0&&r.forEach("a[href]"===e.selector?function(s){-1!==s.getAttribute(e.attribute).replace(/\t|\s|&/,"").indexOf("javascript:alert")&&s.removeAttribute(e.attribute)}:function(s){s.removeAttribute(e.attribute)})})},n}();function PZ(n){return function(t){!function kZ(n,t){t.forEach(function(e){Object.getOwnPropertyNames(e.prototype).forEach(function(i){(!Object.prototype.hasOwnProperty.call(n.prototype,i)||e.isFormBase&&"constructor"!==i)&&(n.prototype["".concat(i)]=e.prototype["".concat(i)])})})}(t,n)}}function mR(n,t,e){var i={};if(n&&n.length){for(var r=0,s=n;r"u"||(y.innerHTML=v.innerHTML?v.innerHTML:"",void 0!==v.className&&(y.className=v.className),void 0!==v.id&&(y.id=v.id),void 0!==v.styles&&y.setAttribute("style",v.styles),void 0!==e.ngAttr&&y.setAttribute(e.ngAttr,""),void 0!==v.attrs&&Fe(y,v.attrs)),y};for(var i=0,r=e.tags;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s}function jZ(n){for(var t,e=n.childNodes,i=0;i"u"&&(c["".concat(o)]=[]),c["".concat(o)].push(h),h.rootNodes}}});var Sl,hd,mh,Wg,oc,po,YZ=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Na=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Jo_RTL=(new Ng,"e-rtl"),ys=function(n){function t(e,i){return n.call(this,e,i)||this}return YZ(t,n),t.prototype.preRender=function(){},t.prototype.render=function(){this.initialize(),this.removeRippleEffect=function ms(n,t,e){var i=function q$(n){return{selector:n&&n.selector?n.selector:null,ignore:n&&n.ignore?n.ignore:null,rippleFlag:n&&n.rippleFlag,isCenterRipple:n&&n.isCenterRipple,duration:n&&n.duration?n.duration:350}}(t);return!1===i.rippleFlag||void 0===i.rippleFlag&&!Zo?function(){}:(n.setAttribute("data-ripple","true"),E.add(n,"mousedown",Zz,{parent:n,rippleOptions:i}),E.add(n,"mouseup",Jz,{parent:n,rippleOptions:i,done:e}),E.add(n,"mouseleave",lf,{parent:n,rippleOptions:i}),X.isPointer&&E.add(n,"transitionend",lf,{parent:n,rippleOptions:i}),function(){n.removeAttribute("data-ripple"),E.remove(n,"mousedown",Zz),E.remove(n,"mouseup",Jz),E.remove(n,"mouseleave",lf),E.remove(n,"transitionend",lf)})}(this.element,{selector:".e-btn"}),this.renderComplete()},t.prototype.initialize=function(){if(this.cssClass&&V([this.element],this.cssClass.replace(/\s+/g," ").trim().split(" ")),this.isPrimary&&this.element.classList.add("e-primary"),!ce()||ce()&&"progress-btn"!==this.getModuleName()){if(this.content){var e=this.enableHtmlSanitizer?Ai.sanitize(this.content):this.content;this.element.innerHTML=e}this.setIconCss()}this.enableRtl&&this.element.classList.add(Jo_RTL),this.disabled?this.controlStatus(this.disabled):this.wireEvents()},t.prototype.controlStatus=function(e){this.element.disabled=e},t.prototype.setIconCss=function(){if(this.iconCss){var e=this.createElement("span",{className:"e-btn-icon "+this.iconCss});this.element.textContent.trim()?(e.classList.add("e-icon-"+this.iconPosition.toLowerCase()),("Top"===this.iconPosition||"Bottom"===this.iconPosition)&&this.element.classList.add("e-"+this.iconPosition.toLowerCase()+"-icon-btn")):this.element.classList.add("e-icon-btn");var i=this.element.childNodes[0];!i||"Left"!==this.iconPosition&&"Top"!==this.iconPosition?this.element.appendChild(e):this.element.insertBefore(e,i)}},t.prototype.wireEvents=function(){this.isToggle&&E.add(this.element,"click",this.btnClickHandler,this)},t.prototype.unWireEvents=function(){this.isToggle&&E.remove(this.element,"click",this.btnClickHandler)},t.prototype.btnClickHandler=function(){this.element.classList.contains("e-active")?this.element.classList.remove("e-active"):this.element.classList.add("e-active")},t.prototype.destroy=function(){var e=["e-primary",Jo_RTL,"e-icon-btn","e-success","e-info","e-danger","e-warning","e-flat","e-outline","e-small","e-bigger","e-active","e-round","e-top-icon-btn","e-bottom-icon-btn"];this.cssClass&&(e=e.concat(this.cssClass.split(" "))),n.prototype.destroy.call(this),K([this.element],e),this.element.getAttribute("class")||this.element.removeAttribute("class"),this.disabled&&this.element.removeAttribute("disabled"),this.content&&(this.element.innerHTML=this.element.innerHTML.replace(this.content,""));var i=this.element.querySelector("span.e-btn-icon");i&&he(i),this.unWireEvents(),Zo&&this.removeRippleEffect()},t.prototype.getModuleName=function(){return"btn"},t.prototype.getPersistData=function(){return this.addOnPersist([])},t.Inject=function(){},t.prototype.onPropertyChanged=function(e,i){for(var r=this.element.querySelector("span.e-btn-icon"),s=0,o=Object.keys(e);s=hd.width?hd.width:0;return Sl.right+JR()-n}function uE(){return j0()+Sl.width/2}function fE(n,t,e,i){if(void 0===t&&(t=null),void 0===e&&(e={X:!1,Y:!1}),!e.Y&&!e.X)return{left:0,top:0};var r=n.getBoundingClientRect();if(po=t,oc=n.ownerDocument,i||(i=ns(n,"left","top")),e.X){var s=po?r4():l4(),o=yE(),a=SE(),l=o-i.left,h=i.left+r.width-a;r.width>s?i.left=l>0&&h<=0?a-r.width:h>0&&l<=0?o:l>h?a-r.width:o:l>0?i.left+=l:h>0&&(i.left-=h)}if(e.Y){var c=po?n4():a4(),d=mE(),u=IE(),f=d-i.top,p=i.top+r.height-u;r.height>c?i.top=f>0&&p<=0?u-r.height:p>0&&f<=0?d:f>p?u-r.height:d:f>0?i.top+=f:p>0&&(i.top-=p)}return i}function ac(n,t,e,i){void 0===t&&(t=null);var r=ns(n,"left","top");e&&(r.left=e),i&&(r.top=i);var s=[];po=t,oc=n.ownerDocument;var o=n.getBoundingClientRect(),l=r.left,h=r.left+o.width,d=vE(r.top,r.top+o.height),u=e4(l,h);return d.topSide&&s.push("top"),u.rightSide&&s.push("right"),u.leftSide&&s.push("left"),d.bottomSide&&s.push("bottom"),s}function bJ(n,t,e,i,r,s,o,a,l){if(void 0===o&&(o=null),void 0===a&&(a={X:!0,Y:!0}),t&&n&&r&&s&&(a.X||a.Y)){var d,h={TL:null,TR:null,BL:null,BR:null},c={TL:null,TR:null,BL:null,BR:null};if("none"===window.getComputedStyle(n).display){var u=n.style.visibility;n.style.visibility="hidden",n.style.display="block",d=n.getBoundingClientRect(),n.style.removeProperty("display"),n.style.visibility=u}else d=n.getBoundingClientRect();var f={posX:r,posY:s,offsetX:e,offsetY:i,position:{left:0,top:0}};po=o,oc=t.ownerDocument,function wJ(n,t,e,i,r){e.position=ns(n,e.posX,e.posY,i,r),t.TL=ns(n,"left","top",i,r),t.TR=ns(n,"right","top",i,r),t.BR=ns(n,"left","bottom",i,r),t.BL=ns(n,"right","bottom",i,r)}(t,h,f,l,d),gE(c,f,d),a.X&&t4(t,c,h,f,d,!0),a.Y&&h.TL.top>-1&&i4(t,c,h,f,d,!0),function MJ(n,t,e){var i=0,r=0;if(null!=n.offsetParent&&("absolute"===getComputedStyle(n.offsetParent).position||"relative"===getComputedStyle(n.offsetParent).position)){var s=ns(n.offsetParent,"left","top",!1,e);i=s.left,r=s.top}var o=1,a=1,l=KR(n);if(l){var h=getComputedStyle(l).transform;if("none"!==h){var c=new DOMMatrix(h);o=c.a,a=c.d}if("none"!==getComputedStyle(l).zoom){var u=pE(document.body);o*=u,a*=u}}n.style.top=t.position.top/a+t.offsetY-r/a+"px",n.style.left=t.position.left/o+t.offsetX-i/o+"px"}(n,f,d)}}function pE(n){var t=getComputedStyle(n).zoom;return parseFloat(t)||1}function KR(n){for(;n;){var t=window.getComputedStyle(n).transform,e=pE(document.body);if(t&&"none"!==t||e&&1!==e)return n;if(n===document.body)return null;n=n.offsetParent||n.parentElement}return null}function gE(n,t,e){n.TL={top:t.position.top+t.offsetY,left:t.position.left+t.offsetX},n.TR={top:n.TL.top,left:n.TL.left+e.width},n.BL={top:n.TL.top+e.height,left:n.TL.left},n.BR={top:n.TL.top+e.height,left:n.TL.left+e.width}}function e4(n,t){var e=!1,i=!1;return n-W0()SE()&&(i=!0),{leftSide:e,rightSide:i}}function t4(n,t,e,i,r,s){var o=e4(t.TL.left,t.TR.left),a=vE(t.TL.top,t.BL.top);e.TL.left-W0()<=yE()&&(o.leftSide=!1),e.TR.left>SE()&&(o.rightSide=!1),(o.leftSide&&!o.rightSide||!o.leftSide&&o.rightSide)&&(i.posX="right"===i.posX?"left":"right",i.offsetX=i.offsetX+r.width,i.offsetX=-1*i.offsetX,i.position=ns(n,i.posX,i.posY,!1),gE(t,i,r),s&&t4(n,t,e,i,r,!1),!o.leftSide&&o.rightSide&&a.bottomSide&&(i.offsetX=0))}function i4(n,t,e,i,r,s){var o=vE(t.TL.top,t.BL.top);e.TL.top-V0()<=mE()&&(o.topSide=!1),e.BL.top>=IE()&&n.getBoundingClientRect().bottomIE()&&(i=!0),{topSide:e,bottomSide:i}}function r4(){return po.getBoundingClientRect().width}function n4(){return po.getBoundingClientRect().height}function s4(){return po.getBoundingClientRect().left}function o4(){return po.getBoundingClientRect().top}function mE(){return po?o4():0}function yE(){return po?s4():0}function SE(){return po?W0()+s4()+r4():W0()+l4()}function IE(){return po?V0()+o4()+n4():V0()+a4()}function V0(){return oc.documentElement.scrollTop||oc.body.scrollTop}function W0(){return oc.documentElement.scrollLeft||oc.body.scrollLeft}function a4(){return window.innerHeight}function l4(){var n=window.innerWidth,t=document.documentElement.getBoundingClientRect();return n-(n-(m(document.documentElement)?0:t.width))}function h4(){po=null,oc=null}var c4=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),bn=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},d4=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return c4(t,n),bn([I("left")],t.prototype,"X",void 0),bn([I("top")],t.prototype,"Y",void 0),t}(Ee),qn_OPEN="e-popup-open",qn_CLOSE="e-popup-close",lc=function(n){function t(e,i){return n.call(this,i,e)||this}return c4(t,n),t.prototype.onPropertyChanged=function(e,i){for(var r=0,s=Object.keys(e);r0&&c.left>0&&c.right>0&&c.bottom>0}var s=i.getBoundingClientRect();return!(r.bottoms.bottom||r.right>s.right||r.leftr.top?this.element.style.top="0px":s.bottomr.left&&(this.element.style.left=parseInt(this.element.style.left,10)+(s.left-r.left)+"px"))}},t.prototype.checkCollision=function(){var e=this.collision.X,i=this.collision.Y;"none"===e&&"none"===i||("flip"===e&&"flip"===i?this.callFlip({X:!0,Y:!0}):"fit"===e&&"fit"===i?this.callFit({X:!0,Y:!0}):("flip"===e?this.callFlip({X:!0,Y:!1}):"flip"===i&&this.callFlip({Y:!0,X:!1}),"fit"===e?this.callFit({X:!0,Y:!1}):"fit"===i&&this.callFit({X:!1,Y:!0})))},t.prototype.show=function(e,i){var r=this;if(this.getRelateToElement().classList.contains("e-filemanager")&&(this.fmDialogContainer=this.element.getElementsByClassName("e-file-select-wrap")[0]),this.wireEvents(),!m(this.fmDialogContainer)&&X.isIos&&(this.fmDialogContainer.style.display="block"),1e3===this.zIndex||!m(i)){var o=m(i)?this.element:i;this.zIndex=hc(o),je(this.element,{zIndex:this.zIndex})}e=m(e)||"object"!=typeof e?this.showAnimation:e,("none"!==this.collision.X||"none"!==this.collision.Y)&&(K([this.element],qn_CLOSE),V([this.element],qn_OPEN),this.checkCollision(),K([this.element],qn_OPEN),V([this.element],qn_CLOSE)),m(e)?(K([this.element],qn_CLOSE),V([this.element],qn_OPEN),this.trigger("open")):(e.begin=function(){r.isDestroyed||(K([r.element],qn_CLOSE),V([r.element],qn_OPEN))},e.end=function(){r.isDestroyed||r.trigger("open")},new Hs(e).animate(this.element))},t.prototype.hide=function(e){var i=this;e=m(e)||"object"!=typeof e?this.hideAnimation:e,m(e)?(K([this.element],qn_OPEN),V([this.element],qn_CLOSE),this.trigger("close")):(e.end=function(){i.isDestroyed||(K([i.element],qn_OPEN),V([i.element],qn_CLOSE),i.trigger("close"))},new Hs(e).animate(this.element)),this.unwireEvents()},t.prototype.getScrollableParent=function(e){return this.checkFixedParent(e),function bE(n,t){for(var e=getComputedStyle(n),i=[],r=/(auto|scroll)/,s=n.parentElement;s&&"HTML"!==s.tagName;){var o=getComputedStyle(s);!("absolute"===e.position&&"static"===o.position)&&r.test(o.overflow+o.overflowY+o.overflowX)&&i.push(s),s=s.parentElement}return t||i.push(document),i}(e,this.fixedParent)},t.prototype.checkFixedParent=function(e){for(var i=e.parentElement;i&&"HTML"!==i.tagName;){var r=getComputedStyle(i);("fixed"===r.position||"sticky"===r.position)&&!m(this.element)&&this.element.offsetParent&&"BODY"===this.element.offsetParent.tagName&&"hidden"!==getComputedStyle(this.element.offsetParent).overflow&&(this.element.style.top=window.scrollY>parseInt(this.element.style.top,10)?Re(window.scrollY-parseInt(this.element.style.top,10)):Re(parseInt(this.element.style.top,10)-window.scrollY),this.element.style.position="fixed",this.fixedParent=!0),i=i.parentElement,!m(this.element)&&m(this.element.offsetParent)&&"fixed"===r.position&&"fixed"===this.element.style.position&&(this.fixedParent=!0)}},bn([I("auto")],t.prototype,"height",void 0),bn([I("auto")],t.prototype,"width",void 0),bn([I(null)],t.prototype,"content",void 0),bn([I("container")],t.prototype,"targetType",void 0),bn([I(null)],t.prototype,"viewPortElement",void 0),bn([I({X:"none",Y:"none"})],t.prototype,"collision",void 0),bn([I("")],t.prototype,"relateTo",void 0),bn([re({},d4)],t.prototype,"position",void 0),bn([I(0)],t.prototype,"offsetX",void 0),bn([I(0)],t.prototype,"offsetY",void 0),bn([I(1e3)],t.prototype,"zIndex",void 0),bn([I(!1)],t.prototype,"enableRtl",void 0),bn([I("reposition")],t.prototype,"actionOnScroll",void 0),bn([I(null)],t.prototype,"showAnimation",void 0),bn([I(null)],t.prototype,"hideAnimation",void 0),bn([H()],t.prototype,"open",void 0),bn([H()],t.prototype,"close",void 0),bn([H()],t.prototype,"targetExitViewport",void 0),bn([Ft],t)}(Ii);function hc(n){for(var t=n.parentElement,e=[];t&&"BODY"!==t.tagName;){var i=document.defaultView.getComputedStyle(t,null).getPropertyValue("z-index"),r=document.defaultView.getComputedStyle(t,null).getPropertyValue("position");"auto"!==i&&"static"!==r&&e.push(i),t=t.parentElement}for(var s=[],o=0;o2147483647?2147483647:c}var Ui,ka,uf,Ih,EE,bh,$t,Mh,ME=["north-west","north","north-east","west","east","south-west","south","south-east"],Yg="e-resize-handle",cc="e-focused-handle",CJ="e-dlg-resizable",u4=["e-restrict-left"],f4="e-resize-viewport",EJ=["north","west","east","south"],wE=0,CE=0,p4=0,g4=0,Qg=0,Gg=0,Xg=null,DE=null,xE=null,Y0=!0,v4=0,TE=!0;function xJ(n){AE();var t=Si("span",{attrs:{unselectable:"on",contenteditable:"false"}});t.setAttribute("class","e-dialog-border-resize e-"+n),"south"===n&&(t.style.height="2px",t.style.width="100%",t.style.bottom="0px",t.style.left="0px"),"north"===n&&(t.style.height="2px",t.style.width="100%",t.style.top="0px",t.style.left="0px"),"east"===n&&(t.style.height="100%",t.style.width="2px",t.style.right="0px",t.style.top="0px"),"west"===n&&(t.style.height="100%",t.style.width="2px",t.style.left="0px",t.style.top="0px"),Ui.appendChild(t)}function m4(n){var t;return m(n)||(t="string"==typeof n?document.querySelector(n):n),t}function y4(n){for(var t=n||this,e=Ui.querySelectorAll("."+Yg),i=0;i-1?"mouse":"touch"}function I4(n){if(n.preventDefault(),Ui=n.target.parentElement,AE(),Qg=n.pageX,Gg=n.pageY,n.target.classList.add(cc),m(Xg)||!0!==Xg(n,this)){this.targetEle&&Ui&&Ui.querySelector("."+CJ)&&($t="body"===this.target?null:this.targetEle,bh=this.targetEle.clientWidth,Ih=this.targetEle.clientHeight);var e=m($t)?document:$t;E.add(e,"mousemove",qg,this),E.add(document,"mouseup",Q0,this);for(var i=0;i=0||s.top<0)&&(e=!0):e=!0;var a=CE+(r-Gg);a=a>uf?a:uf;var l=0;m($t)||(l=o.top);var h=m($t)?0:$t.offsetHeight-$t.clientHeight,c=s.top-l-h/2;if(c=c<0?0:c,s.top>0&&c+a>Ih){if(e=!1,Ui.classList.contains(f4))return;Ui.style.height=Ih-parseInt(c.toString(),10)+"px"}else{var d=0;if(e){s.top<0&&t+(s.height+s.top)>0&&a+(d=s.top)<=30&&(a=s.height-(s.height+s.top)+30),a+s.top>=Ih&&(Ui.style.height=s.height+(t-(s.height+s.top))+"px");var u=m($t)?d:c;a>=uf&&a+u<=Ih&&(Ui.style.height=a+"px")}}}function NE(n){var e,t=!1,i="mouse"===S4(n.type)?n.pageY:n.touches[0].pageY,r=dc(Ui),s=m($t)?0:$t.offsetHeight-$t.clientHeight;m($t)||(e=dc($t)),(!m($t)&&r.top-e.top>0||m($t)&&i>0||!m($t)&&Math.floor(r.top-e.top+r.height+(e.bottom-r.bottom))-s<=Ih)&&(t=!0);var o=CE-(i-Gg);if(t&&o>=uf&&o<=Ih){var a=0;m($t)||(a=e.top);var l=g4-a+(i-Gg);l=l>0?l:1,Ui.style.height=o+"px",Ui.style.top=l+"px"}}function OE(n){var i,t=document.documentElement.clientWidth,e=!1;m($t)||(i=dc($t));var r="mouse"===S4(n.type)?n.pageX:n.touches[0].pageX,s=dc(Ui),o=m($t)?0:$t.offsetWidth-$t.clientWidth,a=m($t)?0:i.left,l=m($t)?0:i.width;m(Mh)&&(m($t)?Mh=t:(Mh=s.left-a-o/2+s.width,Mh+=l-o-Mh)),(!m($t)&&Math.floor(s.left-i.left+s.width+(i.right-s.right))-o<=bh||m($t)&&r>=0)&&(e=!0);var h=wE-(r-Qg);if(Y0&&(h=h>Mh?Mh:h),e&&h>=EE&&h<=bh){var c=0;m($t)||(c=i.left);var d=p4-c+(r-Qg);d=d>0?d:1,h!==v4&&TE&&(Ui.style.width=h+"px"),Y0&&(Ui.style.left=d+"px",TE=1!==d)}v4=h}function kE(n){var i,t=document.documentElement.clientWidth,e=!1;m($t)||(i=dc($t));var s=(n.touches?n.changedTouches[0]:n).pageX,o=dc(Ui);(!m($t)&&(o.left-i.left+o.width<=bh||o.right-i.left>=o.width)||m($t)&&t-s>0)&&(e=!0);var a=wE+(s-Qg),l=0;if(m($t)||(l=i.left),o.left-l+a>bh){if(e=!1,Ui.classList.contains(f4))return;Ui.style.width=bh-(o.left-l)+"px"}e&&a>=EE&&a<=bh&&(Ui.style.width=a+"px")}function M4(){for(var n=Ui.querySelectorAll("."+Yg),t=0;t=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},OJ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return PE(t,n),Zt([I(!0)],t.prototype,"isFlat",void 0),Zt([I()],t.prototype,"buttonModel",void 0),Zt([I("Button")],t.prototype,"type",void 0),Zt([H()],t.prototype,"click",void 0),t}(Ee),kJ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return PE(t,n),Zt([I("Fade")],t.prototype,"effect",void 0),Zt([I(400)],t.prototype,"duration",void 0),Zt([I(0)],t.prototype,"delay",void 0),t}(Ee),G0="e-dialog",zE="e-rtl",RE="e-dlg-header-content",w4="e-dlg-header",X0="e-footer-content",q0="e-dlg-modal",C4="e-icon-dlg-close",Pa="e-dlg-target",ea="e-scroll-disabled",E4="e-device",$0="e-dlg-fullscreen",D4="e-dlg-closeicon-btn",x4="e-popup-open",T4="Information",A4="e-scroll-disabled",L4="e-alert-dialog",N4="e-confirm-dialog",HE="e-dlg-resizable",ff="e-restrict-left",O4="e-resize-viewport",BE="user action",QJ=function(n){function t(e,i){var r=n.call(this,e,i)||this;return r.needsID=!0,r}return PE(t,n),t.prototype.render=function(){this.initialize(),this.initRender(),this.wireEvents(),"100%"===this.width&&(this.element.style.width=""),""!==this.minHeight&&(this.element.style.minHeight=Re(this.minHeight)),this.enableResize&&(this.setResize(),this.isModal&&(this.isModelResize=!0),"None"===this.animationSettings.effect&&this.getMinHeight()),this.renderComplete()},t.prototype.initializeValue=function(){this.dlgClosedBy=BE},t.prototype.preRender=function(){var e=this;if(this.initializeValue(),this.headerContent=null,this.allowMaxHeight=!0,this.preventVisibility=!0,this.clonedEle=this.element.cloneNode(!0),this.closeIconClickEventHandler=function(s){e.dlgClosedBy="close icon",e.hide(s)},this.dlgOverlayClickEventHandler=function(s){e.dlgClosedBy="overlayClick",s.preventFocus=!1,e.trigger("overlayClick",s,function(o){o.preventFocus||e.focusContent(),e.dlgClosedBy=BE})},this.l10n=new uo("dialog",{close:"Close"},this.locale),this.checkPositionData(),m(this.target)){var r=this.isProtectedOnChange;this.isProtectedOnChange=!0,this.target=document.body,this.isProtectedOnChange=r}},t.prototype.updatePersistData=function(){this.enablePersistence&&this.setProperties({width:parseFloat(this.element.style.width),height:parseFloat(this.element.style.height),position:{X:parseFloat(this.dragObj.element.style.left),Y:parseFloat(this.dragObj.element.style.top)}},!0)},t.prototype.isNumberValue=function(e){return/^[-+]?\d*\.?\d+$/.test(e)},t.prototype.checkPositionData=function(){if(!m(this.position)){if(!m(this.position.X)&&"number"!=typeof this.position.X&&this.isNumberValue(this.position.X)){var i=this.isProtectedOnChange;this.isProtectedOnChange=!0,this.position.X=parseFloat(this.position.X),this.isProtectedOnChange=i}m(this.position.Y)||"number"==typeof this.position.Y||this.isNumberValue(this.position.Y)&&(i=this.isProtectedOnChange,this.isProtectedOnChange=!0,this.position.Y=parseFloat(this.position.Y),this.isProtectedOnChange=i)}},t.prototype.getEle=function(e,i){for(var r=void 0,s=0;s=0&&t[e])xJ(t[e]);else if(""!==t[e].trim()){var i=Si("div",{className:"e-icons "+Yg+" e-"+t[e]});Ui.appendChild(i)}uf=n.minHeight,EE=n.minWidth,bh=n.maxWidth,Ih=n.maxHeight,n.proxy&&n.proxy.element&&n.proxy.element.classList.contains("e-dialog")?y4(n.proxy):y4()}({element:this.element,direction:r,minHeight:parseInt(e.slice(0,i.indexOf("p")),10),maxHeight:this.targetEle.clientHeight,minWidth:parseInt(i.slice(0,i.indexOf("p")),10),maxWidth:this.targetEle.clientWidth,boundary:this.target===document.body?null:this.targetEle,resizeBegin:this.onResizeStart.bind(this),resizeComplete:this.onResizeComplete.bind(this),resizing:this.onResizing.bind(this),proxy:this}),this.wireWindowResizeEvent()}else M4(),this.unWireWindowResizeEvent(),this.element.classList.remove(this.isModal?ff:O4),this.element.classList.remove(HE)},t.prototype.getFocusElement=function(e){var r=e.querySelectorAll('input,select,textarea,button:enabled,a,[contenteditable="true"],[tabindex]');return{element:r[r.length-1]}},t.prototype.keyDown=function(e){var i=this;if(9===e.keyCode&&this.isModal){var r=void 0;m(this.btnObj)||(r=this.btnObj[this.btnObj.length-1]),m(this.btnObj)&&!m(this.ftrTemplateContent)&&(r=this.getFocusElement(this.ftrTemplateContent)),m(this.btnObj)&&m(this.ftrTemplateContent)&&!m(this.contentEle)&&(r=this.getFocusElement(this.contentEle)),!m(r)&&document.activeElement===r.element&&!e.shiftKey&&(e.preventDefault(),this.focusableElements(this.element).focus()),document.activeElement===this.focusableElements(this.element)&&e.shiftKey&&(e.preventDefault(),m(r)||r.element.focus())}var h,s=document.activeElement,o=["input","textarea"].indexOf(s.tagName.toLowerCase())>-1,a=!1;if(o||(a=s.hasAttribute("contenteditable")&&"true"===s.getAttribute("contenteditable")),27===e.keyCode&&this.closeOnEscape){this.dlgClosedBy="escape";var l=document.querySelector(".e-popup-open:not(.e-dialog)");!m(l)&&!l.classList.contains("e-toolbar-pop")&&!l.classList.contains("e-slider-tooltip")||this.hide(e)}(13===e.keyCode&&!e.ctrlKey&&"textarea"!==s.tagName.toLowerCase()&&o&&!m(this.primaryButtonEle)||13===e.keyCode&&e.ctrlKey&&("textarea"===s.tagName.toLowerCase()||a)&&!m(this.primaryButtonEle))&&this.buttons.some(function(d,u){h=u;var f=d.buttonModel;return!m(f)&&!0===f.isPrimary})&&"function"==typeof this.buttons[h].click&&setTimeout(function(){i.buttons[h].click.call(i,e)})},t.prototype.initialize=function(){m(this.target)||(this.targetEle="string"==typeof this.target?document.querySelector(this.target):this.target),this.isBlazorServerRender()||V([this.element],G0),X.isDevice&&V([this.element],E4),this.isBlazorServerRender()||this.setCSSClass(),this.setMaxHeight()},t.prototype.initRender=function(){var e=this;if(this.initialRender=!0,this.isBlazorServerRender()||Fe(this.element,{role:"dialog"}),1e3===this.zIndex?(this.setzIndex(this.element,!1),this.calculatezIndex=!0):this.calculatezIndex=!1,this.setTargetContent(),""!==this.header&&!m(this.header)&&this.setHeader(),this.renderCloseIcon(),this.setContent(),""===this.footerTemplate||m(this.footerTemplate)?!m(this.buttons[0])&&!m(this.buttons[0].buttonModel)&&this.setButton():this.setFooterTemplate(),this.allowDragging&&!m(this.headerContent)&&this.setAllowDragging(),Fe(this.element,{"aria-modal":this.isModal?"true":"false"}),this.isModal&&this.setIsModal(),!0!==this.element.classList.contains(L4)&&!0!==this.element.classList.contains(N4)&&!m(this.element.parentElement)){var i=this.isModal?this.dlgContainer.parentElement:this.element.parentElement;this.refElement=this.createElement("div",{className:"e-dlg-ref-element"}),i.insertBefore(this.refElement,this.isModal?this.dlgContainer:this.element)}if(m(this.targetEle)||this.targetEle.appendChild(this.isModal?this.dlgContainer:this.element),this.popupObj=new lc(this.element,{height:this.height,width:this.width,zIndex:this.zIndex,relateTo:this.target,actionOnScroll:"none",enableRtl:this.enableRtl,open:function(o){var a={container:e.isModal?e.dlgContainer:e.element,element:e.element,target:e.target,preventFocus:!1};e.enableResize&&e.resetResizeIcon(),e.trigger("open",a,function(l){l.preventFocus||e.focusContent()})},close:function(o){e.isModal&&V([e.dlgOverlay],"e-fade"),e.unBindEvent(e.element),e.isModal&&(e.dlgContainer.style.display="none"),e.trigger("close",e.closeArgs);var a=document.activeElement;!m(a)&&!m(a.blur)&&a.blur(),!m(e.storeActiveElement)&&!m(e.storeActiveElement.focus)&&e.storeActiveElement.focus()}}),this.positionChange(),this.setEnableRTL(),this.isBlazorServerRender()||(V([this.element],"e-popup-close"),this.isModal&&this.setOverlayZindex()),this.visible){if(this.show(),this.isModal){var r=this.getTargetContainer(this.target);r instanceof Element&&"rtl"===window.getComputedStyle(r).getPropertyValue("direction")&&this.setPopupPosition()}}else this.isModal&&(this.dlgOverlay.style.display="none");this.initialRender=!1},t.prototype.getTargetContainer=function(e){var i=null;if("string"==typeof e)if(e.startsWith("#"))i=document.getElementById(e.substring(1));else if(e.startsWith(".")){var r=document.getElementsByClassName(e.substring(1));i=r.length>0?r[0]:null}else!(e instanceof HTMLElement)&&e!==document.body&&(i=document.querySelector(e));else e instanceof HTMLElement&&(i=e);return i},t.prototype.resetResizeIcon=function(){var e=this.getMinHeight();if(this.targetEle.offsetHeight0&&("function"==typeof this.buttons[e].click&&E.add(s[e],"click",this.buttons[e].click,this),"object"==typeof this.buttons[e].click&&E.add(s[e],"click",this.buttonClickHandler.bind(this,e),this)),!this.isBlazorServerRender()&&!m(this.ftrTemplateContent)&&(this.btnObj[e].appendTo(this.ftrTemplateContent.children[e]),this.buttons[e].isFlat&&this.btnObj[e].element.classList.add("e-flat"),this.primaryButtonEle=this.element.getElementsByClassName("e-primary")[0]))},t.prototype.buttonClickHandler=function(e){this.trigger("buttons["+e+"].click",{})},t.prototype.setContent=function(){this.contentEle=this.createElement("div",{className:"e-dlg-content",id:this.element.id+"_dialog-content"}),Fe(this.element,this.headerEle?{"aria-describedby":this.element.id+"_title "+this.element.id+"_dialog-content"}:{"aria-describedby":this.element.id+"_dialog-content"}),this.innerContentElement?this.contentEle.appendChild(this.innerContentElement):(!m(this.content)&&""!==this.content||!this.initialRender)&&(("string"!=typeof this.content||ce())&&this.content instanceof HTMLElement?this.contentEle.appendChild(this.content):this.setTemplate(this.content,this.contentEle,"content")),m(this.headerContent)?this.element.insertBefore(this.contentEle,this.element.children[0]):this.element.insertBefore(this.contentEle,this.element.children[1]),"auto"===this.height&&(!this.isBlazorServerRender()&&X.isIE&&""===this.element.style.width&&!m(this.width)&&(this.element.style.width=Re(this.width)),this.setMaxHeight())},t.prototype.setTemplate=function(e,i,r){var s,o,a;o=i.classList.contains(w4)?this.element.id+"header":i.classList.contains(X0)?this.element.id+"footerTemplate":this.element.id+"content",m(e.outerHTML)?("string"==typeof e||"string"!=typeof e||ce()&&!this.isStringTemplate)&&("string"==typeof e&&(e=this.sanitizeHelper(e)),this.isVue||"string"!=typeof e?(s=si(e),a=e):i.innerHTML=e):i.appendChild(e);var l=[];if(!m(s)){for(var c=0,d=s({},this,r,o,!(ce()&&!this.isStringTemplate&&0===a.indexOf("
Blazor"))||this.isStringTemplate);c/g,"");(this.element.children.length>0||i)&&(this.innerContentElement=document.createDocumentFragment(),[].slice.call(this.element.childNodes).forEach(function(r){8!==r.nodeType&&e.innerContentElement.appendChild(r)}))}},t.prototype.setHeader=function(){this.headerEle?this.headerEle.innerHTML="":this.headerEle=this.createElement("div",{id:this.element.id+"_title",className:w4}),this.createHeaderContent(),this.headerContent.appendChild(this.headerEle),this.setTemplate(this.header,this.headerEle,"header"),Fe(this.element,{"aria-describedby":this.element.id+"_title"}),Fe(this.element,{"aria-labelledby":this.element.id+"_dialog-header"}),this.element.insertBefore(this.headerContent,this.element.children[0]),this.allowDragging&&!m(this.headerContent)&&this.setAllowDragging()},t.prototype.setFooterTemplate=function(){this.ftrTemplateContent?this.ftrTemplateContent.innerHTML="":this.ftrTemplateContent=this.createElement("div",{className:X0}),""===this.footerTemplate||m(this.footerTemplate)?this.ftrTemplateContent.innerHTML=this.buttonContent.join(""):this.setTemplate(this.footerTemplate,this.ftrTemplateContent,"footerTemplate"),this.element.appendChild(this.ftrTemplateContent)},t.prototype.createHeaderContent=function(){m(this.headerContent)&&(this.headerContent=this.createElement("div",{id:this.element.id+"_dialog-header",className:RE}))},t.prototype.renderCloseIcon=function(){this.showCloseIcon&&(this.closeIcon=this.createElement("button",{className:D4,attrs:{type:"button"}}),this.closeIconBtnObj=new ys({cssClass:"e-flat",iconCss:C4+" e-icons"}),this.closeIconTitle(),m(this.headerContent)?(this.createHeaderContent(),gl([this.closeIcon],this.headerContent),this.element.insertBefore(this.headerContent,this.element.children[0])):gl([this.closeIcon],this.headerContent),this.closeIconBtnObj.appendTo(this.closeIcon))},t.prototype.closeIconTitle=function(){this.l10n.setLocale(this.locale);var e=this.l10n.getConstant("close");this.closeIcon.setAttribute("title",e),this.closeIcon.setAttribute("aria-label",e)},t.prototype.setCSSClass=function(e){e&&(K([this.element],e.split(" ")),this.isModal&&!m(this.dlgContainer)&&K([this.dlgContainer],e.split(" "))),this.cssClass&&(V([this.element],this.cssClass.split(" ")),this.isModal&&!m(this.dlgContainer)&&V([this.dlgContainer],this.cssClass.split(" ")))},t.prototype.setIsModal=function(){this.dlgContainer=this.createElement("div",{className:"e-dlg-container"}),this.setCSSClass(),this.element.classList.remove(x4),this.element.parentNode.insertBefore(this.dlgContainer,this.element),this.dlgContainer.appendChild(this.element),V([this.element],q0),this.dlgOverlay=this.createElement("div",{className:"e-dlg-overlay"}),this.dlgOverlay.style.zIndex=(this.zIndex-1).toString(),this.dlgContainer.appendChild(this.dlgOverlay)},t.prototype.getValidFocusNode=function(e){for(var i,r=0;r0||"a"===i.tagName.toLowerCase()&&i.hasAttribute("href"))&&i.tabIndex>-1&&!i.disabled&&!this.disableElement(i,'[disabled],[aria-disabled="true"],[type="hidden"]'))return i;i=null}return i},t.prototype.focusableElements=function(e){if(!m(e)){var r=e.querySelectorAll('input,select,textarea,button,a,[contenteditable="true"],[tabindex]');return this.getValidFocusNode(r)}return null},t.prototype.getAutoFocusNode=function(e){var i=e.querySelector("."+D4),s=e.querySelectorAll("[autofocus]"),o=this.getValidFocusNode(s);if(ce()&&(this.primaryButtonEle=this.element.getElementsByClassName("e-primary")[0]),m(o)){if(!m(o=this.focusableElements(this.contentEle)))return o;if(!m(this.primaryButtonEle))return this.element.querySelector(".e-primary")}else i=o;return i},t.prototype.disableElement=function(e,i){var r=e?e.matches||e.webkitMatchesSelector||e.msGetRegionContent:null;if(r)for(;e;e=e.parentNode)if(e instanceof Element&&r.call(e,i))return e;return null},t.prototype.focusContent=function(){var e=this.getAutoFocusNode(this.element),i=m(e)?this.element:e,r=X.userAgent;(r.indexOf("MSIE ")>0||r.indexOf("Trident/")>0)&&this.element.focus(),i.focus(),this.unBindEvent(this.element),this.bindEvent(this.element)},t.prototype.bindEvent=function(e){E.add(e,"keydown",this.keyDown,this)},t.prototype.unBindEvent=function(e){E.remove(e,"keydown",this.keyDown)},t.prototype.updateSanitizeContent=function(){this.isBlazorServerRender()||(this.contentEle.innerHTML=this.sanitizeHelper(this.content))},t.prototype.isBlazorServerRender=function(){return ce()&&this.isServerRendered},t.prototype.getModuleName=function(){return"dialog"},t.prototype.onPropertyChanged=function(e,i){if(this.element.classList.contains(G0))for(var r=0,s=Object.keys(e);r0?this.showCloseIcon||""!==this.header&&!m(this.header)?this.showCloseIcon||he(this.closeIcon):(he(this.headerContent),this.headerContent=null):(this.renderCloseIcon(),this.wireEvents());break;case"locale":this.showCloseIcon&&this.closeIconTitle();break;case"visible":this.visible?this.show():this.hide();break;case"isModal":this.updateIsModal();break;case"height":je(this.element,{height:Re(e.height)}),this.updatePersistData();break;case"width":je(this.element,{width:Re(e.width)}),this.updatePersistData();break;case"zIndex":this.popupObj.zIndex=this.zIndex,this.isModal&&this.setOverlayZindex(this.zIndex),this.element.style.zIndex!==this.zIndex.toString()&&(this.calculatezIndex=!1);break;case"cssClass":this.setCSSClass(i.cssClass);break;case"buttons":this.unWireButtonEvents(),this.destroyButtons(),m(this.ftrTemplateContent)||(he(this.ftrTemplateContent),this.ftrTemplateContent=null),this.footerTemplate="",this.setButton();break;case"allowDragging":this.allowDragging&&!m(this.headerContent)?this.setAllowDragging():this.dragObj.destroy();break;case"target":this.setTarget(e.target);break;case"position":if(this.checkPositionData(),this.isModal){var a=this.position.X,l=this.position.Y;m(i.position)||(m(i.position.X)||(a=i.position.X),m(i.position.Y)||(l=i.position.Y)),this.dlgContainer.classList.contains("e-dlg-"+a+"-"+l)&&this.dlgContainer.classList.remove("e-dlg-"+a+"-"+l)}this.positionChange(),this.updatePersistData();break;case"enableRtl":this.setEnableRTL();break;case"enableResize":this.setResize(),this.isModelResize=this.enableResize&&this.isModal,this.enableResize&&this.dialogOpen&&this.resetResizeIcon();break;case"minHeight":""!==this.minHeight&&(this.element.style.minHeight=Re(this.minHeight))}},t.prototype.setTarget=function(e){this.popupObj.relateTo=e,this.target=e,this.targetEle="string"==typeof this.target?document.querySelector(this.target):this.target,this.dragObj&&(this.dragObj.dragArea=this.targetEle),this.setMaxHeight(),this.isModal&&this.updateIsModal(),this.enableResize&&this.setResize(),m(this.targetEle)||(this.isModal&&!m(this.dlgContainer)?this.targetEle.appendChild(this.dlgContainer):m(this.element)||this.targetEle.appendChild(this.element))},t.prototype.updateIsModal=function(){if(this.element.setAttribute("aria-modal",this.isModal?"true":"false"),this.isModal)m(this.dlgOverlay)&&(this.setIsModal(),this.element.style.top="0px",this.element.style.left="0px",m(this.targetEle)||this.targetEle.appendChild(this.dlgContainer));else{for(K([this.element],q0),K([document.body],[Pa,ea]),he(this.dlgOverlay);this.dlgContainer.firstChild;)this.dlgContainer.parentElement.insertBefore(this.dlgContainer.firstChild,this.dlgContainer);this.dlgContainer.parentElement.removeChild(this.dlgContainer)}this.visible&&this.show(),this.positionChange(),this.isModal&&this.dlgOverlay&&E.add(this.dlgOverlay,"click",this.dlgOverlayClickEventHandler,this)},t.prototype.setzIndex=function(e,i){var r=this.isProtectedOnChange;this.isProtectedOnChange=!0;var s=hc(e);this.zIndex=s>this.zIndex?s:this.zIndex,this.isProtectedOnChange=r,i&&(this.popupObj.zIndex=this.zIndex)},t.prototype.windowResizeHandler=function(){(function AJ(n){bh=n})(this.targetEle.clientWidth),function LJ(n){Ih=n}(this.targetEle.clientHeight),this.setMaxHeight()},t.prototype.getPersistData=function(){return this.addOnPersist(["width","height","position"])},t.prototype.removeAllChildren=function(e){for(;e.children[0];)this.removeAllChildren(e.children[0]),e.removeChild(e.children[0])},t.prototype.destroy=function(){if(!this.isDestroyed){var e=[zE,q0,HE,ff,$0,E4],i=["role","aria-modal","aria-labelledby","aria-describedby","aria-grabbed","tabindex","style"];K([this.targetEle],[Pa,ea]),!m(this.element)&&this.element.classList.contains($0)&&K([document.body],[Pa,ea]),this.isModal&&K([m(this.targetEle)?document.body:this.targetEle],ea),this.unWireEvents(),this.unWireButtonEvents(),this.destroyButtons(),m(this.closeIconBtnObj)||this.closeIconBtnObj.destroy(),m(this.dragObj)||this.dragObj.destroy(),!m(this.popupObj.element)&&this.popupObj.element.classList.contains("e-popup")&&this.popupObj.destroy(),K([this.element],e),!m(this.cssClass)&&""!==this.cssClass&&K([this.element],this.cssClass.split(" ")),!m(this.refElement)&&!m(this.refElement.parentElement)&&(this.refElement.parentElement.insertBefore(this.isModal?this.dlgContainer:this.element,this.refElement),he(this.refElement),this.refElement=void 0),this.isModal&&(he(this.dlgOverlay),this.dlgContainer.parentNode.insertBefore(this.element,this.dlgContainer),he(this.dlgContainer)),this.element.innerHTML=this.clonedEle.innerHTML;for(var r=0;r0&&""===this.footerTemplate&&this.ftrTemplateContent)for(var e=0;e=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},FE="e-tooltip",B4="e-icons",F4="e-tooltip-close",_E="e-tooltip-wrap",_4="e-tip-content",pf="e-arrow-tip",U4="e-arrow-tip-outer",Z0="e-arrow-tip-inner",$g="e-tip-bottom",UE="e-tip-top",j4="e-tip-left",jE="e-tip-right",VE="e-popup",Zg="e-popup-open",WE="e-popup-close",J0="e-lib",V4="e-tooltip-popup-container",JJ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return P4(t,n),Gi([I({effect:"FadeIn",duration:150,delay:0})],t.prototype,"open",void 0),Gi([I({effect:"FadeOut",duration:150,delay:0})],t.prototype,"close",void 0),t}(Ee),wh=function(n){function t(e,i){var r=n.call(this,e,i)||this;return r.mouseMoveEvent=null,r.mouseMoveTarget=null,r.containerElement=null,r.isBodyContainer=!0,r}return P4(t,n),t.prototype.initialize=function(){this.formatPosition(),V([this.element],FE)},t.prototype.formatPosition=function(){var e,i;this.position&&(0===this.position.indexOf("Top")||0===this.position.indexOf("Bottom")?(e=this.position.split(/(?=[A-Z])/),this.tooltipPositionY=e[0],this.tooltipPositionX=e[1]):(i=this.position.split(/(?=[A-Z])/),this.tooltipPositionX=i[0],this.tooltipPositionY=i[1]))},t.prototype.renderArrow=function(){this.setTipClass(this.position);var e=this.createElement("div",{className:pf+" "+this.tipClass});e.appendChild(this.createElement("div",{className:U4+" "+this.tipClass})),e.appendChild(this.createElement("div",{className:Z0+" "+this.tipClass})),this.tooltipEle.appendChild(e)},t.prototype.setTipClass=function(e){this.tipClass=0===e.indexOf("Right")?j4:0===e.indexOf("Bottom")?UE:0===e.indexOf("Left")?jE:$g},t.prototype.renderPopup=function(e){var i=this.mouseTrail?{top:0,left:0}:this.getTooltipPosition(e);this.tooltipEle.classList.remove(J0),this.popupObj=new lc(this.tooltipEle,{height:this.height,width:this.width,position:{X:i.left,Y:i.top},enableRtl:this.enableRtl,open:this.openPopupHandler.bind(this),close:this.closePopupHandler.bind(this)})},t.prototype.getScalingFactor=function(e){if(!e)return{x:1,y:1};var i={x:1,y:1},r=e.closest('[style*="transform: scale"]');if(r&&r!==this.tooltipEle&&r.contains(this.tooltipEle)){var a=window.getComputedStyle(r).getPropertyValue("transform").match(/matrix\(([^)]+)\)/)[1].split(",").map(parseFloat);i.x=a[0],i.y=a[3]}return i},t.prototype.getTooltipPosition=function(e){this.tooltipEle.style.display="block";var i=this.element.closest('[style*="zoom"]');i&&(i.contains(this.tooltipEle)||(this.tooltipEle.style.zoom=getComputedStyle(i).zoom));var r=ns(e,this.tooltipPositionX,this.tooltipPositionY,!this.isBodyContainer,this.isBodyContainer?null:this.containerElement.getBoundingClientRect()),s=this.getScalingFactor(e),o=this.calculateTooltipOffset(this.position,s.x,s.y),a=this.calculateElementPosition(r,o),c=this.collisionFlipFit(e,a[0],a[1]);return c.left=c.left/s.x,c.top=c.top/s.y,this.tooltipEle.style.display="",c},t.prototype.windowResize=function(){this.reposition(this.findTarget())},t.prototype.reposition=function(e){if(this.popupObj&&e){var i=this.getTooltipPosition(e);this.popupObj.position={X:i.left,Y:i.top},this.popupObj.dataBind()}},t.prototype.openPopupHandler=function(){!this.mouseTrail&&this.needTemplateReposition()&&this.reposition(this.findTarget()),this.trigger("afterOpen",this.tooltipEventArgs),this.tooltipEventArgs=null},t.prototype.closePopupHandler=function(){this.isReact&&!("Click"===this.opensOn||"function"==typeof this.content)&&this.clearTemplate(["content"]),this.clear();var e={type:this.tooltipEventArgs.event?this.tooltipEventArgs.event.type:null,cancel:!1,target:this.tooltipEventArgs.target,event:this.tooltipEventArgs.event?this.tooltipEventArgs.event:null,element:this.tooltipEle,isInteracted:!m(this.tooltipEventArgs.event)};this.trigger("afterClose",e),e=null},t.prototype.calculateTooltipOffset=function(e,i,r){void 0===i&&(i=1),void 0===r&&(r=1);var o,a,l,h,c,d,u,f,s={top:0,left:0};if(1!==i||1!==r){var p=this.tooltipEle.getBoundingClientRect(),g=void 0;l=Math.round(p.width),h=Math.round(p.height),(c=_("."+pf,this.tooltipEle))&&(g=c.getBoundingClientRect()),o=c?Math.round(g.width):0,a=c?Math.round(g.height):0,d=this.showTipPointer?0:8,u=a/2+2+(h-this.tooltipEle.clientHeight*r),f=o/2+2+(l-this.tooltipEle.clientWidth*i)}else l=this.tooltipEle.offsetWidth,h=this.tooltipEle.offsetHeight,c=_("."+pf,this.tooltipEle),d=this.showTipPointer?0:8,u=(a=c?c.offsetHeight:0)/2+2+(this.tooltipEle.offsetHeight-this.tooltipEle.clientHeight),f=(o=c?c.offsetWidth:0)/2+2+(this.tooltipEle.offsetWidth-this.tooltipEle.clientWidth);switch(this.mouseTrail&&(d+=2),e){case"RightTop":s.left+=o+d,s.top-=h-u;break;case"RightCenter":s.left+=o+d,s.top-=h/2;break;case"RightBottom":s.left+=o+d,s.top-=u;break;case"BottomRight":s.top+=a+d,s.left-=f;break;case"BottomCenter":s.top+=a+d,s.left-=l/2;break;case"BottomLeft":s.top+=a+d,s.left-=l-f;break;case"LeftBottom":s.left-=o+l+d,s.top-=u;break;case"LeftCenter":s.left-=o+l+d,s.top-=h/2;break;case"LeftTop":s.left-=o+l+d,s.top-=h-u;break;case"TopLeft":s.top-=h+a+d,s.left-=l-f;break;case"TopRight":s.top-=h+a+d,s.left-=f;break;default:s.top-=h+a+d,s.left-=l/2}return s.left+=this.offsetX,s.top+=this.offsetY,s},t.prototype.updateTipPosition=function(e){var i=we("."+pf+",."+U4+",."+Z0,this.tooltipEle);K(i,[$g,UE,j4,jE]),this.setTipClass(e),V(i,this.tipClass)},t.prototype.adjustArrow=function(e,i,r,s){var o=_("."+pf,this.tooltipEle);if(!1!==this.showTipPointer&&null!==o){var a,l;this.updateTipPosition(i),this.tooltipEle.style.display="block";var p,h=this.tooltipEle.clientWidth,c=this.tooltipEle.clientHeight,d=_("."+Z0,this.tooltipEle),u=o.offsetWidth,f=o.offsetHeight;this.tooltipEle.style.display="",this.tipClass===$g||this.tipClass===UE?(this.tipClass===$g?(l="99.9%",d.style.top="-"+(f-2)+"px"):(l=-(f-1)+"px",d.style.top="-"+(f-6)+"px"),e&&(a=(p="Center"!==r||h>e.offsetWidth||this.mouseTrail)&&"Left"===r||!p&&"End"===this.tipPointerPosition?h-u-2+"px":p&&"Right"===r||!p&&"Start"===this.tipPointerPosition?"2px":!p||"End"!==this.tipPointerPosition&&"Start"!==this.tipPointerPosition?h/2-u/2+"px":"End"===this.tipPointerPosition?e.offsetWidth+(this.tooltipEle.offsetWidth-e.offsetWidth)/2-u/2-2+"px":(this.tooltipEle.offsetWidth-e.offsetWidth)/2-u/2+2+"px")):(this.tipClass===jE?(a="99.9%",d.style.left="-"+(u-2)+"px"):(a=-(u-1)+"px",d.style.left=u-2-u+"px"),l=(p="Center"!==s||c>e.offsetHeight||this.mouseTrail)&&"Top"===s||!p&&"End"===this.tipPointerPosition?c-f-2+"px":p&&"Bottom"===s||!p&&"Start"===this.tipPointerPosition?"2px":c/2-f/2+"px"),o.style.top=l,o.style.left=a}},t.prototype.renderContent=function(e){var i=this,r=_("."+_4,this.tooltipEle);if(this.cssClass&&V([this.tooltipEle],this.cssClass.split(" ")),e&&!m(e.getAttribute("title"))&&(e.setAttribute("data-content",e.getAttribute("title")),e.removeAttribute("title")),m(this.content))e&&!m(e.getAttribute("data-content"))&&(r.innerHTML=e.getAttribute("data-content"));else if(r.innerHTML="",this.content instanceof HTMLElement)r.appendChild(this.content);else if("string"==typeof this.content)this.isAngular?this.setProperties({content:Ai.sanitize(this.content)},!0):this.content=this.enableHtmlSanitizer?Ai.sanitize(this.content):this.content,this.enableHtmlParse?(o=si(this.content)({},this,"content",this.element.id+"content",void 0,void 0,r,this.root))&&Dt(o,r):r.textContent=this.content;else{var o;(o=si(this.content)({},this,"content",this.element.id+"content",void 0,void 0,r))&&(this.isAngular&&setTimeout(function(){i.reposition(e)},1),Dt(o,r)),this.renderReactTemplates()}},t.prototype.renderCloseIcon=function(){if(this.isSticky){var i=this.createElement("div",{className:B4+" "+F4});this.tooltipEle.appendChild(i),E.add(i,X.touchStartEvent,this.onStickyClose,this)}else{var e=this.tooltipEle.querySelector("."+B4+"."+F4);e&>(e)}},t.prototype.addDescribedBy=function(e,i){var r=(e.getAttribute("aria-describedby")||"").split(/\s+/);r.indexOf(i)<0&&r.push(i),Fe(e,{"aria-describedby":r.join(" ").trim(),"data-tooltip-id":i})},t.prototype.removeDescribedBy=function(e){var i=e.getAttribute("data-tooltip-id"),r=(e.getAttribute("aria-describedby")||"").split(/\s+/),s=r.indexOf(i);-1!==s&&r.splice(s,1),e.removeAttribute("data-tooltip-id");var o=r.join(" ").trim();o?e.setAttribute("aria-describedby",o):e.removeAttribute("aria-describedby")},t.prototype.tapHoldHandler=function(e){clearTimeout(this.autoCloseTimer),this.targetHover(e.originalEvent)},t.prototype.touchEndHandler=function(){var e=this;this.isSticky||(this.autoCloseTimer=setTimeout(function(){e.close()},1500))},t.prototype.targetClick=function(e){var i;!m(i=this.target?J(e.target,this.target):this.element)&&(null===i.getAttribute("data-tooltip-id")?this.targetHover(e):this.isSticky||this.hideTooltip(this.animation.close,e,i))},t.prototype.targetHover=function(e){var i;if(!(m(i=this.target?J(e.target,this.target):this.element)||null!==i.getAttribute("data-tooltip-id")&&0===this.closeDelay)){for(var s=0,o=[].slice.call(we('[data-tooltip-id= "'+this.ctrlId+'_content"]',document));s0?this.showTimer=setTimeout(function(){o.mouseTrail&&E.add(i,"mousemove touchstart mouseenter",o.onMouseMove,o),o.popupObj&&(o.popupObj.show(a,i),o.mouseMoveEvent&&o.mouseTrail&&o.onMouseMove(o.mouseMoveEvent))},this.openDelay):this.popupObj&&this.popupObj.show(a,i)}s&&this.wireMouseEvents(s,i)},t.prototype.needTemplateReposition=function(){return!m(this.viewContainerRef)&&"string"!=typeof this.viewContainerRef||this.isReact},t.prototype.checkCollision=function(e,i,r){var s={left:i,top:r,position:this.position,horizontal:this.tooltipPositionX,vertical:this.tooltipPositionY},o=ac(this.tooltipEle,this.checkCollideTarget(),i,r);return o.length>0&&(s.horizontal=o.indexOf("left")>=0?"Right":o.indexOf("right")>=0?"Left":this.tooltipPositionX,s.vertical=o.indexOf("top")>=0?"Bottom":o.indexOf("bottom")>=0?"Top":this.tooltipPositionY),s},t.prototype.calculateElementPosition=function(e,i){return[this.isBodyContainer?e.left+i.left:e.left-this.containerElement.getBoundingClientRect().left+i.left+window.pageXOffset+this.containerElement.scrollLeft,this.isBodyContainer?e.top+i.top:e.top-this.containerElement.getBoundingClientRect().top+i.top+window.pageYOffset+this.containerElement.scrollTop]},t.prototype.collisionFlipFit=function(e,i,r){var s=this.checkCollision(e,i,r),o=s.position;if(this.tooltipPositionY!==s.vertical&&(o=0===this.position.indexOf("Bottom")||0===this.position.indexOf("Top")?s.vertical+this.tooltipPositionX:this.tooltipPositionX+s.vertical),this.tooltipPositionX!==s.horizontal&&(0===o.indexOf("Left")&&(s.vertical="LeftTop"===o||"LeftCenter"===o?"Top":"Bottom",o=s.vertical+"Left"),0===o.indexOf("Right")&&(s.vertical="RightTop"===o||"RightCenter"===o?"Top":"Bottom",o=s.vertical+"Right"),s.horizontal=this.tooltipPositionX),this.tooltipEventArgs={type:null,cancel:!1,target:e,event:null,element:this.tooltipEle,collidedPosition:o},this.trigger("beforeCollision",this.tooltipEventArgs),this.tooltipEventArgs.cancel)o=this.position;else{var a=s.vertical,l=s.horizontal;if(s.position!==o){var h=ns(e,l,a,!this.isBodyContainer,this.isBodyContainer?null:this.containerElement.getBoundingClientRect());this.adjustArrow(e,o,l,a);var c=this.getScalingFactor(e),d=this.calculateTooltipOffset(o,c.x,c.y);d.top-=this.getOffSetPosition("TopBottom",o,this.offsetY),d.left-=this.getOffSetPosition("RightLeft",o,this.offsetX),s.position=o;var u=this.calculateElementPosition(h,d);s.left=u[0],s.top=u[1]}else this.adjustArrow(e,o,l,a)}var f={left:s.left,top:s.top},p=this.isBodyContainer?fE(this.tooltipEle,this.checkCollideTarget(),{X:!0,Y:this.windowCollision},f):f;this.tooltipEle.style.display="block";var g=_("."+pf,this.tooltipEle);if(this.showTipPointer&&null!=g&&(0===o.indexOf("Bottom")||0===o.indexOf("Top"))){var v=parseInt(g.style.left,10)-(p.left-s.left);v<0?v=0:v+g.offsetWidth>this.tooltipEle.clientWidth&&(v=this.tooltipEle.clientWidth-g.offsetWidth),g.style.left=v.toString()+"px"}return this.tooltipEle.style.display="",f.left=p.left,f.top=p.top,f},t.prototype.getOffSetPosition=function(e,i,r){return-1!==e.indexOf(this.position.split(/(?=[A-Z])/)[0])&&-1!==e.indexOf(i.split(/(?=[A-Z])/)[0])?2*r:0},t.prototype.checkCollideTarget=function(){return!this.windowCollision&&this.target?this.element:null},t.prototype.hideTooltip=function(e,i,r){var s=this;this.closeDelay>0?(clearTimeout(this.hideTimer),clearTimeout(this.showTimer),this.hideTimer=setTimeout(function(){s.closeDelay&&s.tooltipEle&&s.isTooltipOpen||s.tooltipHide(e,i,r)},this.closeDelay)):this.tooltipHide(e,i,r)},t.prototype.tooltipHide=function(e,i,r){var o,s=this;o=i?this.target?r||i.target:this.element:_('[data-tooltip-id= "'+this.ctrlId+'_content"]',document),this.tooltipEventArgs={type:i?i.type:null,cancel:!1,target:o,event:i||null,element:this.tooltipEle,isInteracted:!m(i)},this.trigger("beforeClose",this.tooltipEventArgs,function(a){a.cancel?s.isHidden=!1:(s.mouseMoveBeforeRemove(),s.popupHide(e,o,i))})},t.prototype.popupHide=function(e,i,r){i&&r&&this.restoreElement(i),this.isHidden=!0;var s={name:this.animation.close.effect,duration:e.duration,delay:e.delay,timingFunction:"easeIn"};"None"===e.effect&&(s=void 0),this.popupObj&&this.popupObj.hide(s)},t.prototype.restoreElement=function(e){this.unwireMouseEvents(e),m(e.getAttribute("data-content"))||(e.setAttribute("title",e.getAttribute("data-content")),e.removeAttribute("data-content")),this.removeDescribedBy(e)},t.prototype.clear=function(){var e=this.findTarget();e&&this.restoreElement(e),this.tooltipEle&&(K([this.tooltipEle],WE),V([this.tooltipEle],Zg)),this.isHidden&&(this.popupObj&&this.popupObj.destroy(),this.tooltipEle&>(this.tooltipEle),this.tooltipEle=null,this.popupObj=null)},t.prototype.tooltipHover=function(){this.tooltipEle&&(this.isTooltipOpen=!0)},t.prototype.tooltipMouseOut=function(e){this.isTooltipOpen=!1,this.hideTooltip(this.animation.close,e,this.findTarget())},t.prototype.onMouseOut=function(e){var i=e.relatedTarget;if(i&&!this.mouseTrail){var r=J(i,"."+_E+"."+J0+"."+VE);r?E.add(r,"mouseleave",this.tooltipElementMouseOut,this):(this.hideTooltip(this.animation.close,e,this.findTarget()),0===this.closeDelay&&("None"===this.animation.close.effect||this.isReact&&"string"!=typeof this.content)&&this.clear())}else this.hideTooltip(this.animation.close,e,this.findTarget()),this.clear();this.popupObj&&!this.popupObj.element.classList.contains(Zg)&&this.clear()},t.prototype.tooltipElementMouseOut=function(e){this.hideTooltip(this.animation.close,e,this.findTarget()),E.remove(this.element,"mouseleave",this.tooltipElementMouseOut),this.clear()},t.prototype.onStickyClose=function(){this.close()},t.prototype.onMouseMove=function(e){var i=0,r=0;e.type.indexOf("touch")>-1?(e.preventDefault(),i=e.touches[0].pageX,r=e.touches[0].pageY):(i=e.pageX,r=e.pageY),Hs.stop(this.tooltipEle),K([this.tooltipEle],WE),V([this.tooltipEle],Zg),this.adjustArrow(e.target,this.position,this.tooltipPositionX,this.tooltipPositionY);var s=this.getScalingFactor(e.target),o=this.calculateTooltipOffset(this.position,s.x,s.y),h=this.checkCollision(e.target,i+o.left+this.offsetX,r+o.top+this.offsetY);if(this.tooltipPositionX!==h.horizontal||this.tooltipPositionY!==h.vertical){var c=0===this.position.indexOf("Bottom")||0===this.position.indexOf("Top")?h.vertical+h.horizontal:h.horizontal+h.vertical;h.position=c,this.adjustArrow(e.target,h.position,h.horizontal,h.vertical);var d=this.calculateTooltipOffset(h.position,s.x,s.y);h.left=i+d.left-this.offsetX,h.top=r+d.top-this.offsetY}this.tooltipEle.style.left=h.left+"px",this.tooltipEle.style.top=h.top+"px"},t.prototype.keyDown=function(e){this.tooltipEle&&27===e.keyCode&&this.close()},t.prototype.touchEnd=function(e){this.tooltipEle&&null===J(e.target,"."+FE)&&!this.isSticky&&this.close()},t.prototype.scrollHandler=function(e){this.tooltipEle&&!this.isSticky&&!J(e.target,"."+_E+"."+J0+"."+VE)&&!this.isSticky&&this.close()},t.prototype.render=function(){this.initialize(),this.wireEvents(this.opensOn),this.renderComplete()},t.prototype.preRender=function(){this.tipClass=$g,this.tooltipPositionX="Center",this.tooltipPositionY="Top",this.isHidden=!0},t.prototype.wireEvents=function(e){for(var r=0,s=this.getTriggerList(e);r0)for(var i=0,r=e;i0)for(var i=0,r=e;i0&&this.condition&&-1!==this.condition.indexOf("not")&&(e[s].condition=e[s].condition?e[s].condition+"not":"not"),i=e[s].validate(t),r){if(!i)return!1}else if(i)return!0;return r},n.prototype.toJson=function(){var t,e;if(this.isComplex){t=[],e=this.predicates;for(var i=0;ie.length-3?(e=e.substring(0,e.length-1),n.endsWith(n.toLowerCase(t),n.toLowerCase(e))):(e.lastIndexOf("%")!==e.indexOf("%")&&e.lastIndexOf("%")>e.indexOf("%")+1&&(e=e.substring(e.indexOf("%")+1,e.lastIndexOf("%"))),-1!==t.indexOf(e)))},n.fnSort=function(t){return"ascending"===(t=t?n.toLowerCase(t):"ascending")?this.fnAscending:this.fnDescending},n.fnAscending=function(t,e){return m(t)&&m(e)||null==e?-1:"string"==typeof t?t.localeCompare(e):null==t?1:t-e},n.fnDescending=function(t,e){return m(t)&&m(e)?-1:null==e?1:"string"==typeof t?-1*t.localeCompare(e):null==t?-1:e-t},n.extractFields=function(t,e){for(var i={},r=0;r0||e.length>0;)o=t.length>0&&e.length>0?r?r(this.getVal(t,0,i),this.getVal(e,0,i),t[0],e[0])<=0?t:e:t[0][i]0?t:e,s.push(o.shift());return s},n.getVal=function(t,e,i){return i?this.getObject(i,t[e]):t[e]},n.toLowerCase=function(t){return t?"string"==typeof t?t.toLowerCase():t.toString():0===t||!1===t?t.toString():""},n.callAdaptorFunction=function(t,e,i,r){if(e in t){var s=t[e](i,r);m(s)||(i=s)}return i},n.getAddParams=function(t,e,i){var r={};return n.callAdaptorFunction(t,"addParams",{dm:e,query:i,params:i?i.params:[],reqParams:r}),r},n.isPlainObject=function(t){return!!t&&t.constructor===Object},n.isCors=function(){var t=null;try{t=new window.XMLHttpRequest}catch{}return!!t&&"withCredentials"in t},n.getGuid=function(t){var i;return(t||"")+"00000000-0000-4000-0000-000000000000".replace(/0/g,function(r,s){if("crypto"in window&&"getRandomValues"in crypto){var o=new Uint8Array(1);window.crypto.getRandomValues(o),i=o[0]%16|0}else i=16*Math.random()|0;return"0123456789abcdef"[19===s?3&i|8:i]})},n.isNull=function(t){return null==t},n.getItemFromComparer=function(t,e,i){var r,s,o,a=0,l="string"==typeof n.getVal(t,0,e);if(t.length)for(;m(r)&&a0&&(r=s,o=t[a]));return o},n.distinct=function(t,e,i){i=!m(i)&&i;var s,r=[],o={};return t.forEach(function(a,l){(s="object"==typeof t[l]?n.getVal(t,l,e):t[l])in o||(r.push(i?t[l]:s),o[s]=1)}),r},n.processData=function(t,e){var i=this.prepareQuery(t),r=new it(e);t.requiresCounts&&i.requiresCount();var s=r.executeLocal(i),o={result:t.requiresCounts?s.result:s,count:s.count,aggregates:JSON.stringify(s.aggregates)};return t.requiresCounts?o:s},n.prepareQuery=function(t){var e=this,i=new _t;return t.select&&i.select(t.select),t.where&&n.parse.parseJson(t.where).filter(function(o){if(m(o.condition))i.where(o.field,o.operator,o.value,o.ignoreCase,o.ignoreAccent);else{var a=[];o.field?a.push(new Ss(o.field,o.operator,o.value,o.ignoreCase,o.ignoreAccent)):a=a.concat(e.getPredicate(o.predicates)),"or"===o.condition?i.where(Ss.or(a)):"and"===o.condition&&i.where(Ss.and(a))}}),t.search&&n.parse.parseJson(t.search).filter(function(o){return i.search(o.key,o.fields,o.operator,o.ignoreCase,o.ignoreAccent)}),t.aggregates&&t.aggregates.filter(function(o){return i.aggregate(o.type,o.field)}),t.sorted&&t.sorted.filter(function(o){return i.sortBy(o.name,o.direction)}),t.skip&&i.skip(t.skip),t.take&&i.take(t.take),t.group&&t.group.filter(function(o){return i.group(o)}),i},n.getPredicate=function(t){for(var e=[],i=0;i":"greaterthan","<=":"lessthanorequal",">=":"greaterthanorequal","==":"equal","!=":"notequal","*=":"contains","$=":"endswith","^=":"startswith"},n.odBiOperator={"<":" lt ",">":" gt ","<=":" le ",">=":" ge ","==":" eq ","!=":" ne ",lessthan:" lt ",lessthanorequal:" le ",greaterthan:" gt ",greaterthanorequal:" ge ",equal:" eq ",notequal:" ne "},n.odUniOperator={"$=":"endswith","^=":"startswith","*=":"substringof",endswith:"endswith",startswith:"startswith",contains:"substringof",doesnotendwith:"not endswith",doesnotstartwith:"not startswith",doesnotcontain:"not substringof",wildcard:"wildcard",like:"like"},n.odv4UniOperator={"$=":"endswith","^=":"startswith","*=":"contains",endswith:"endswith",startswith:"startswith",contains:"contains",doesnotendwith:"not endswith",doesnotstartwith:"not startswith",doesnotcontain:"not contains",wildcard:"wildcard",like:"like"},n.diacritics={"\u24b6":"A",\uff21:"A",\u00c0:"A",\u00c1:"A",\u00c2:"A",\u1ea6:"A",\u1ea4:"A",\u1eaa:"A",\u1ea8:"A",\u00c3:"A",\u0100:"A",\u0102:"A",\u1eb0:"A",\u1eae:"A",\u1eb4:"A",\u1eb2:"A",\u0226:"A",\u01e0:"A",\u00c4:"A",\u01de:"A",\u1ea2:"A",\u00c5:"A",\u01fa:"A",\u01cd:"A",\u0200:"A",\u0202:"A",\u1ea0:"A",\u1eac:"A",\u1eb6:"A",\u1e00:"A",\u0104:"A",\u023a:"A",\u2c6f:"A",\ua732:"AA",\u00c6:"AE",\u01fc:"AE",\u01e2:"AE",\ua734:"AO",\ua736:"AU",\ua738:"AV",\ua73a:"AV",\ua73c:"AY","\u24b7":"B",\uff22:"B",\u1e02:"B",\u1e04:"B",\u1e06:"B",\u0243:"B",\u0182:"B",\u0181:"B","\u24b8":"C",\uff23:"C",\u0106:"C",\u0108:"C",\u010a:"C",\u010c:"C",\u00c7:"C",\u1e08:"C",\u0187:"C",\u023b:"C",\ua73e:"C","\u24b9":"D",\uff24:"D",\u1e0a:"D",\u010e:"D",\u1e0c:"D",\u1e10:"D",\u1e12:"D",\u1e0e:"D",\u0110:"D",\u018b:"D",\u018a:"D",\u0189:"D",\ua779:"D",\u01f1:"DZ",\u01c4:"DZ",\u01f2:"Dz",\u01c5:"Dz","\u24ba":"E",\uff25:"E",\u00c8:"E",\u00c9:"E",\u00ca:"E",\u1ec0:"E",\u1ebe:"E",\u1ec4:"E",\u1ec2:"E",\u1ebc:"E",\u0112:"E",\u1e14:"E",\u1e16:"E",\u0114:"E",\u0116:"E",\u00cb:"E",\u1eba:"E",\u011a:"E",\u0204:"E",\u0206:"E",\u1eb8:"E",\u1ec6:"E",\u0228:"E",\u1e1c:"E",\u0118:"E",\u1e18:"E",\u1e1a:"E",\u0190:"E",\u018e:"E","\u24bb":"F",\uff26:"F",\u1e1e:"F",\u0191:"F",\ua77b:"F","\u24bc":"G",\uff27:"G",\u01f4:"G",\u011c:"G",\u1e20:"G",\u011e:"G",\u0120:"G",\u01e6:"G",\u0122:"G",\u01e4:"G",\u0193:"G",\ua7a0:"G",\ua77d:"G",\ua77e:"G","\u24bd":"H",\uff28:"H",\u0124:"H",\u1e22:"H",\u1e26:"H",\u021e:"H",\u1e24:"H",\u1e28:"H",\u1e2a:"H",\u0126:"H",\u2c67:"H",\u2c75:"H",\ua78d:"H","\u24be":"I",\uff29:"I",\u00cc:"I",\u00cd:"I",\u00ce:"I",\u0128:"I",\u012a:"I",\u012c:"I",\u0130:"I",\u00cf:"I",\u1e2e:"I",\u1ec8:"I",\u01cf:"I",\u0208:"I",\u020a:"I",\u1eca:"I",\u012e:"I",\u1e2c:"I",\u0197:"I","\u24bf":"J",\uff2a:"J",\u0134:"J",\u0248:"J","\u24c0":"K",\uff2b:"K",\u1e30:"K",\u01e8:"K",\u1e32:"K",\u0136:"K",\u1e34:"K",\u0198:"K",\u2c69:"K",\ua740:"K",\ua742:"K",\ua744:"K",\ua7a2:"K","\u24c1":"L",\uff2c:"L",\u013f:"L",\u0139:"L",\u013d:"L",\u1e36:"L",\u1e38:"L",\u013b:"L",\u1e3c:"L",\u1e3a:"L",\u0141:"L",\u023d:"L",\u2c62:"L",\u2c60:"L",\ua748:"L",\ua746:"L",\ua780:"L",\u01c7:"LJ",\u01c8:"Lj","\u24c2":"M",\uff2d:"M",\u1e3e:"M",\u1e40:"M",\u1e42:"M",\u2c6e:"M",\u019c:"M","\u24c3":"N",\uff2e:"N",\u01f8:"N",\u0143:"N",\u00d1:"N",\u1e44:"N",\u0147:"N",\u1e46:"N",\u0145:"N",\u1e4a:"N",\u1e48:"N",\u0220:"N",\u019d:"N",\ua790:"N",\ua7a4:"N",\u01ca:"NJ",\u01cb:"Nj","\u24c4":"O",\uff2f:"O",\u00d2:"O",\u00d3:"O",\u00d4:"O",\u1ed2:"O",\u1ed0:"O",\u1ed6:"O",\u1ed4:"O",\u00d5:"O",\u1e4c:"O",\u022c:"O",\u1e4e:"O",\u014c:"O",\u1e50:"O",\u1e52:"O",\u014e:"O",\u022e:"O",\u0230:"O",\u00d6:"O",\u022a:"O",\u1ece:"O",\u0150:"O",\u01d1:"O",\u020c:"O",\u020e:"O",\u01a0:"O",\u1edc:"O",\u1eda:"O",\u1ee0:"O",\u1ede:"O",\u1ee2:"O",\u1ecc:"O",\u1ed8:"O",\u01ea:"O",\u01ec:"O",\u00d8:"O",\u01fe:"O",\u0186:"O",\u019f:"O",\ua74a:"O",\ua74c:"O",\u01a2:"OI",\ua74e:"OO",\u0222:"OU","\u24c5":"P",\uff30:"P",\u1e54:"P",\u1e56:"P",\u01a4:"P",\u2c63:"P",\ua750:"P",\ua752:"P",\ua754:"P","\u24c6":"Q",\uff31:"Q",\ua756:"Q",\ua758:"Q",\u024a:"Q","\u24c7":"R",\uff32:"R",\u0154:"R",\u1e58:"R",\u0158:"R",\u0210:"R",\u0212:"R",\u1e5a:"R",\u1e5c:"R",\u0156:"R",\u1e5e:"R",\u024c:"R",\u2c64:"R",\ua75a:"R",\ua7a6:"R",\ua782:"R","\u24c8":"S",\uff33:"S",\u1e9e:"S",\u015a:"S",\u1e64:"S",\u015c:"S",\u1e60:"S",\u0160:"S",\u1e66:"S",\u1e62:"S",\u1e68:"S",\u0218:"S",\u015e:"S",\u2c7e:"S",\ua7a8:"S",\ua784:"S","\u24c9":"T",\uff34:"T",\u1e6a:"T",\u0164:"T",\u1e6c:"T",\u021a:"T",\u0162:"T",\u1e70:"T",\u1e6e:"T",\u0166:"T",\u01ac:"T",\u01ae:"T",\u023e:"T",\ua786:"T",\ua728:"TZ","\u24ca":"U",\uff35:"U",\u00d9:"U",\u00da:"U",\u00db:"U",\u0168:"U",\u1e78:"U",\u016a:"U",\u1e7a:"U",\u016c:"U",\u00dc:"U",\u01db:"U",\u01d7:"U",\u01d5:"U",\u01d9:"U",\u1ee6:"U",\u016e:"U",\u0170:"U",\u01d3:"U",\u0214:"U",\u0216:"U",\u01af:"U",\u1eea:"U",\u1ee8:"U",\u1eee:"U",\u1eec:"U",\u1ef0:"U",\u1ee4:"U",\u1e72:"U",\u0172:"U",\u1e76:"U",\u1e74:"U",\u0244:"U","\u24cb":"V",\uff36:"V",\u1e7c:"V",\u1e7e:"V",\u01b2:"V",\ua75e:"V",\u0245:"V",\ua760:"VY","\u24cc":"W",\uff37:"W",\u1e80:"W",\u1e82:"W",\u0174:"W",\u1e86:"W",\u1e84:"W",\u1e88:"W",\u2c72:"W","\u24cd":"X",\uff38:"X",\u1e8a:"X",\u1e8c:"X","\u24ce":"Y",\uff39:"Y",\u1ef2:"Y",\u00dd:"Y",\u0176:"Y",\u1ef8:"Y",\u0232:"Y",\u1e8e:"Y",\u0178:"Y",\u1ef6:"Y",\u1ef4:"Y",\u01b3:"Y",\u024e:"Y",\u1efe:"Y","\u24cf":"Z",\uff3a:"Z",\u0179:"Z",\u1e90:"Z",\u017b:"Z",\u017d:"Z",\u1e92:"Z",\u1e94:"Z",\u01b5:"Z",\u0224:"Z",\u2c7f:"Z",\u2c6b:"Z",\ua762:"Z","\u24d0":"a",\uff41:"a",\u1e9a:"a",\u00e0:"a",\u00e1:"a",\u00e2:"a",\u1ea7:"a",\u1ea5:"a",\u1eab:"a",\u1ea9:"a",\u00e3:"a",\u0101:"a",\u0103:"a",\u1eb1:"a",\u1eaf:"a",\u1eb5:"a",\u1eb3:"a",\u0227:"a",\u01e1:"a",\u00e4:"a",\u01df:"a",\u1ea3:"a",\u00e5:"a",\u01fb:"a",\u01ce:"a",\u0201:"a",\u0203:"a",\u1ea1:"a",\u1ead:"a",\u1eb7:"a",\u1e01:"a",\u0105:"a",\u2c65:"a",\u0250:"a",\ua733:"aa",\u00e6:"ae",\u01fd:"ae",\u01e3:"ae",\ua735:"ao",\ua737:"au",\ua739:"av",\ua73b:"av",\ua73d:"ay","\u24d1":"b",\uff42:"b",\u1e03:"b",\u1e05:"b",\u1e07:"b",\u0180:"b",\u0183:"b",\u0253:"b","\u24d2":"c",\uff43:"c",\u0107:"c",\u0109:"c",\u010b:"c",\u010d:"c",\u00e7:"c",\u1e09:"c",\u0188:"c",\u023c:"c",\ua73f:"c",\u2184:"c","\u24d3":"d",\uff44:"d",\u1e0b:"d",\u010f:"d",\u1e0d:"d",\u1e11:"d",\u1e13:"d",\u1e0f:"d",\u0111:"d",\u018c:"d",\u0256:"d",\u0257:"d",\ua77a:"d",\u01f3:"dz",\u01c6:"dz","\u24d4":"e",\uff45:"e",\u00e8:"e",\u00e9:"e",\u00ea:"e",\u1ec1:"e",\u1ebf:"e",\u1ec5:"e",\u1ec3:"e",\u1ebd:"e",\u0113:"e",\u1e15:"e",\u1e17:"e",\u0115:"e",\u0117:"e",\u00eb:"e",\u1ebb:"e",\u011b:"e",\u0205:"e",\u0207:"e",\u1eb9:"e",\u1ec7:"e",\u0229:"e",\u1e1d:"e",\u0119:"e",\u1e19:"e",\u1e1b:"e",\u0247:"e",\u025b:"e",\u01dd:"e","\u24d5":"f",\uff46:"f",\u1e1f:"f",\u0192:"f",\ua77c:"f","\u24d6":"g",\uff47:"g",\u01f5:"g",\u011d:"g",\u1e21:"g",\u011f:"g",\u0121:"g",\u01e7:"g",\u0123:"g",\u01e5:"g",\u0260:"g",\ua7a1:"g",\u1d79:"g",\ua77f:"g","\u24d7":"h",\uff48:"h",\u0125:"h",\u1e23:"h",\u1e27:"h",\u021f:"h",\u1e25:"h",\u1e29:"h",\u1e2b:"h",\u1e96:"h",\u0127:"h",\u2c68:"h",\u2c76:"h",\u0265:"h",\u0195:"hv","\u24d8":"i",\uff49:"i",\u00ec:"i",\u00ed:"i",\u00ee:"i",\u0129:"i",\u012b:"i",\u012d:"i",\u00ef:"i",\u1e2f:"i",\u1ec9:"i",\u01d0:"i",\u0209:"i",\u020b:"i",\u1ecb:"i",\u012f:"i",\u1e2d:"i",\u0268:"i",\u0131:"i","\u24d9":"j",\uff4a:"j",\u0135:"j",\u01f0:"j",\u0249:"j","\u24da":"k",\uff4b:"k",\u1e31:"k",\u01e9:"k",\u1e33:"k",\u0137:"k",\u1e35:"k",\u0199:"k",\u2c6a:"k",\ua741:"k",\ua743:"k",\ua745:"k",\ua7a3:"k","\u24db":"l",\uff4c:"l",\u0140:"l",\u013a:"l",\u013e:"l",\u1e37:"l",\u1e39:"l",\u013c:"l",\u1e3d:"l",\u1e3b:"l",\u017f:"l",\u0142:"l",\u019a:"l",\u026b:"l",\u2c61:"l",\ua749:"l",\ua781:"l",\ua747:"l",\u01c9:"lj","\u24dc":"m",\uff4d:"m",\u1e3f:"m",\u1e41:"m",\u1e43:"m",\u0271:"m",\u026f:"m","\u24dd":"n",\uff4e:"n",\u01f9:"n",\u0144:"n",\u00f1:"n",\u1e45:"n",\u0148:"n",\u1e47:"n",\u0146:"n",\u1e4b:"n",\u1e49:"n",\u019e:"n",\u0272:"n",\u0149:"n",\ua791:"n",\ua7a5:"n",\u01cc:"nj","\u24de":"o",\uff4f:"o",\u00f2:"o",\u00f3:"o",\u00f4:"o",\u1ed3:"o",\u1ed1:"o",\u1ed7:"o",\u1ed5:"o",\u00f5:"o",\u1e4d:"o",\u022d:"o",\u1e4f:"o",\u014d:"o",\u1e51:"o",\u1e53:"o",\u014f:"o",\u022f:"o",\u0231:"o",\u00f6:"o",\u022b:"o",\u1ecf:"o",\u0151:"o",\u01d2:"o",\u020d:"o",\u020f:"o",\u01a1:"o",\u1edd:"o",\u1edb:"o",\u1ee1:"o",\u1edf:"o",\u1ee3:"o",\u1ecd:"o",\u1ed9:"o",\u01eb:"o",\u01ed:"o",\u00f8:"o",\u01ff:"o",\u0254:"o",\ua74b:"o",\ua74d:"o",\u0275:"o",\u01a3:"oi",\u0223:"ou",\ua74f:"oo","\u24df":"p",\uff50:"p",\u1e55:"p",\u1e57:"p",\u01a5:"p",\u1d7d:"p",\ua751:"p",\ua753:"p",\ua755:"p","\u24e0":"q",\uff51:"q",\u024b:"q",\ua757:"q",\ua759:"q","\u24e1":"r",\uff52:"r",\u0155:"r",\u1e59:"r",\u0159:"r",\u0211:"r",\u0213:"r",\u1e5b:"r",\u1e5d:"r",\u0157:"r",\u1e5f:"r",\u024d:"r",\u027d:"r",\ua75b:"r",\ua7a7:"r",\ua783:"r","\u24e2":"s",\uff53:"s",\u00df:"s",\u015b:"s",\u1e65:"s",\u015d:"s",\u1e61:"s",\u0161:"s",\u1e67:"s",\u1e63:"s",\u1e69:"s",\u0219:"s",\u015f:"s",\u023f:"s",\ua7a9:"s",\ua785:"s",\u1e9b:"s","\u24e3":"t",\uff54:"t",\u1e6b:"t",\u1e97:"t",\u0165:"t",\u1e6d:"t",\u021b:"t",\u0163:"t",\u1e71:"t",\u1e6f:"t",\u0167:"t",\u01ad:"t",\u0288:"t",\u2c66:"t",\ua787:"t",\ua729:"tz","\u24e4":"u",\uff55:"u",\u00f9:"u",\u00fa:"u",\u00fb:"u",\u0169:"u",\u1e79:"u",\u016b:"u",\u1e7b:"u",\u016d:"u",\u00fc:"u",\u01dc:"u",\u01d8:"u",\u01d6:"u",\u01da:"u",\u1ee7:"u",\u016f:"u",\u0171:"u",\u01d4:"u",\u0215:"u",\u0217:"u",\u01b0:"u",\u1eeb:"u",\u1ee9:"u",\u1eef:"u",\u1eed:"u",\u1ef1:"u",\u1ee5:"u",\u1e73:"u",\u0173:"u",\u1e77:"u",\u1e75:"u",\u0289:"u","\u24e5":"v",\uff56:"v",\u1e7d:"v",\u1e7f:"v",\u028b:"v",\ua75f:"v",\u028c:"v",\ua761:"vy","\u24e6":"w",\uff57:"w",\u1e81:"w",\u1e83:"w",\u0175:"w",\u1e87:"w",\u1e85:"w",\u1e98:"w",\u1e89:"w",\u2c73:"w","\u24e7":"x",\uff58:"x",\u1e8b:"x",\u1e8d:"x","\u24e8":"y",\uff59:"y",\u1ef3:"y",\u00fd:"y",\u0177:"y",\u1ef9:"y",\u0233:"y",\u1e8f:"y",\u00ff:"y",\u1ef7:"y",\u1e99:"y",\u1ef5:"y",\u01b4:"y",\u024f:"y",\u1eff:"y","\u24e9":"z",\uff5a:"z",\u017a:"z",\u1e91:"z",\u017c:"z",\u017e:"z",\u1e93:"z",\u1e95:"z",\u01b6:"z",\u0225:"z",\u0240:"z",\u2c6c:"z",\ua763:"z",\u0386:"\u0391",\u0388:"\u0395",\u0389:"\u0397",\u038a:"\u0399",\u03aa:"\u0399",\u038c:"\u039f",\u038e:"\u03a5",\u03ab:"\u03a5",\u038f:"\u03a9",\u03ac:"\u03b1",\u03ad:"\u03b5",\u03ae:"\u03b7",\u03af:"\u03b9",\u03ca:"\u03b9",\u0390:"\u03b9",\u03cc:"\u03bf",\u03cd:"\u03c5",\u03cb:"\u03c5",\u03b0:"\u03c5",\u03c9:"\u03c9",\u03c2:"\u03c3"},n.fnOperators={equal:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?n.toLowerCase(t)===n.toLowerCase(e):t===e},notequal:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),!n.fnOperators.equal(t,e,i)},lessthan:function(t,e,i){return i?n.toLowerCase(t)n.toLowerCase(e):t>e},lessthanorequal:function(t,e,i){return i?n.toLowerCase(t)<=n.toLowerCase(e):(m(t)&&(t=void 0),t<=e)},greaterthanorequal:function(t,e,i){return i?n.toLowerCase(t)>=n.toLowerCase(e):t>=e},contains:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?!m(t)&&!m(e)&&-1!==n.toLowerCase(t).indexOf(n.toLowerCase(e)):!m(t)&&!m(e)&&-1!==t.toString().indexOf(e)},doesnotcontain:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?!m(t)&&!m(e)&&-1===n.toLowerCase(t).indexOf(n.toLowerCase(e)):!m(t)&&!m(e)&&-1===t.toString().indexOf(e)},isnotnull:function(t){return null!=t},isnull:function(t){return null==t},startswith:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.startsWith(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.startsWith(t,e)},doesnotstartwith:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.notStartsWith(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.notStartsWith(t,e)},like:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.like(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.like(t,e)},isempty:function(t){return void 0===t||""===t},isnotempty:function(t){return void 0!==t&&""!==t},wildcard:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?(t||"boolean"==typeof t)&&e&&"object"!=typeof t&&n.wildCard(n.toLowerCase(t),n.toLowerCase(e)):(t||"boolean"==typeof t)&&e&&n.wildCard(t,e)},endswith:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.endsWith(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.endsWith(t,e)},doesnotendwith:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.notEndsWith(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.notEndsWith(t,e)},processSymbols:function(t){var e=n.operatorSymbols[t];return e?n.fnOperators[e]:n.throwError("Query - Process Operator : Invalid operator")},processOperator:function(t){return n.fnOperators[t]||n.fnOperators.processSymbols(t)}},n.parse={parseJson:function(t){return"string"!=typeof t||!/^[\s]*\[|^[\s]*\{(.)+:/g.test(t)&&-1!==t.indexOf('"')?t instanceof Array?n.parse.iterateAndReviveArray(t):"object"==typeof t&&null!==t&&n.parse.iterateAndReviveJson(t):t=JSON.parse(t,n.parse.jsonReviver),t},iterateAndReviveArray:function(t){for(var e=0;e-1||e.indexOf("z")>-1,o=e.split(/[^0-9.]/);if(s){if(o[5].indexOf(".")>-1){var a=o[5].split(".");o[5]=a[0],o[6]=new Date(e).getUTCMilliseconds().toString()}else o[6]="00";e=n.dateParse.toTimeZone(new Date(parseInt(o[0],10),parseInt(o[1],10)-1,parseInt(o[2],10),parseInt(o[3],10),parseInt(o[4],10),parseInt(o[5]?o[5]:"00",10),parseInt(o[6],10)),n.serverTimezoneOffset,!1)}else{var l=new Date(parseInt(o[0],10),parseInt(o[1],10)-1,parseInt(o[2],10),parseInt(o[3],10),parseInt(o[4],10),parseInt(o[5]?o[5]:"00",10)),h=parseInt(o[6],10),c=parseInt(o[7],10);if(isNaN(h)&&isNaN(c))return l;e.indexOf("+")>-1?l.setHours(l.getHours()-h,l.getMinutes()-c):l.setHours(l.getHours()+h,l.getMinutes()+c),e=n.dateParse.toTimeZone(l,n.serverTimezoneOffset,!1)}null==n.serverTimezoneOffset&&(e=n.dateParse.addSelfOffset(e))}}return e},isJson:function(t){return"string"==typeof t[0]?t:n.parse.parseJson(t)},isGuid:function(t){return null!=/[A-Fa-f0-9]{8}(?:-[A-Fa-f0-9]{4}){3}-[A-Fa-f0-9]{12}/i.exec(t)},replacer:function(t,e){return n.isPlainObject(t)?n.parse.jsonReplacer(t,e):t instanceof Array?n.parse.arrayReplacer(t):t instanceof Date?n.parse.jsonReplacer({val:t},e).val:t},jsonReplacer:function(t,e){for(var i,s=0,o=Object.keys(t);s=0?"+":"-",s=function(a){var l=Math.floor(Math.abs(a));return(l<10?"0":"")+l};return e.getFullYear()+"-"+s(e.getMonth()+1)+"-"+s(e.getDate())+"T"+s(e.getHours())+":"+s(e.getMinutes())+":"+s(e.getSeconds())+r+s(i/60)+":"+s(i%60)}},n}(),wl=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),BK={GroupGuid:"{271bbba0-1ee7}"},a5=function(){function n(t){this.options={from:"table",requestType:"json",sortBy:"sorted",select:"select",skip:"skip",group:"group",take:"take",search:"search",count:"requiresCounts",where:"where",aggregates:"aggregates",expand:"expand"},this.type=n,this.dataSource=t,this.pvt={}}return n.prototype.processResponse=function(t,e,i,r){return t},n}(),GE=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return wl(t,n),t.prototype.processQuery=function(e,i){for(var a,l,f,r=e.dataSource.json.slice(0),s=r.length,o=!0,h={},c=0,d=[],u=[],p=0;p1?e.sort.filter(function(f){return f.fieldName===c})[0]:e.sort[0];s=this.onSortBy(s,d,e.query,!0)}e.page&&(s=this.onPage(s,e.page,e.query)),this.formGroupResult(s,h)}else{for(var o=e.lazyLoad.onDemandGroupInfo,a=o.where.length-1;a>=0;a--)s=this.onWhere(s,o.where[a]);if(e.group.length!==o.level)s=le.group(s,e.group[o.level].fieldName,r,null,null,e.group[o.level].comparer,!0),e.sort.length&&(s=this.onSortBy(s,e.sort[parseInt(o.level.toString(),10)],e.query,!0));else for(a=e.sort.length-1;a>=o.level;a--)s=this.onSortBy(s,e.sort[parseInt(a.toString(),10)],e.query,!1);i=s.length,h=s,s=(s=s.slice(o.skip)).slice(0,o.take),e.group.length!==o.level&&this.formGroupResult(s,h)}return{result:s,count:i}},t.prototype.formGroupResult=function(e,i){if(e.length&&i.length){var r="GroupGuid",s="childLevels",o="level",a="records";e[r]=i[r],e[s]=i[s],e[o]=i[o],e[a]=i[a]}return e},t.prototype.getAggregate=function(e){var i=_t.filterQueries(e.queries,"onAggregates"),r=[];if(i.length)for(var s=void 0,o=0;o=0;l--)a[l]&&(o=i.comparer,le.endsWith(a[l]," desc")&&(o=le.fnSort("descending"),a[l]=a[l].replace(" desc","")),e=le.sort(e,a[l],o));return e}return le.sort(e,s?"key":a,i.comparer)},t.prototype.onGroup=function(e,i,r){if(!e||!e.length)return e;var s=this.getAggregate(r);return le.group(e,le.getValue(i.fieldName,r),s,null,null,i.comparer)},t.prototype.onPage=function(e,i,r){var s=le.getValue(i.pageSize,r),o=(le.getValue(i.pageIndex,r)-1)*s;return e&&e.length?e.slice(o,o+s):e},t.prototype.onRange=function(e,i){return e&&e.length?e.slice(le.getValue(i.start),le.getValue(i.end)):e},t.prototype.onTake=function(e,i){return e&&e.length?e.slice(0,le.getValue(i.nos)):e},t.prototype.onSkip=function(e,i){return e&&e.length?e.slice(le.getValue(i.nos)):e},t.prototype.onSelect=function(e,i){return e&&e.length?le.select(e,le.getValue(i.fieldNames)):e},t.prototype.insert=function(e,i,r,s,o){return m(o)?e.dataSource.json.push(i):e.dataSource.json.splice(o,0,i)},t.prototype.remove=function(e,i,r,s){var a,o=e.dataSource.json;for("object"==typeof r&&!(r instanceof Date)&&(r=le.getObject(i,r)),a=0;a1&&(g="("+g+")"),f.filters.push(g);for(var y=0,S="object"==typeof f.filters[p]?Object.keys(f.filters[p]):[];y-1&&this.formRemoteGroupedData(e[s].items,i+1,r-1);var o="GroupGuid",h="records";return e[o]=BK[o],e.level=i,e.childLevels=r,e[h]=e[0].items.length?this.getGroupedRecords(e,!m(e[0].items[h])):[],e},t.prototype.getGroupedRecords=function(e,i){for(var r=[],o=0;ol.length-3?(l=l.substring(0,l.length-1),o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.endswith:le.odv4UniOperator.endswith):l.lastIndexOf("%")!==l.indexOf("%")&&l.lastIndexOf("%")>l.indexOf("%")+1?(l=l.substring(l.indexOf("%")+1,l.lastIndexOf("%")),o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains):o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains),l="'"+(l=encodeURIComponent(l))+"'";else if("wildcard"===o)if(-1!==l.indexOf("*")){var d=l.split("*"),u=void 0,f=0;if(0!==l.indexOf("*")&&-1===d[0].indexOf("%3f")&&-1===d[0].indexOf("?")&&(u="'"+(u=d[0])+"'",s+=(o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.startswith:le.odv4UniOperator.startswith)+"(",s+=c+",",a&&(s+=a),s+=u+")",f++),l.lastIndexOf("*")!==l.length-1&&-1===d[d.length-1].indexOf("%3f")&&-1===d[d.length-1].indexOf("?")&&(u="'"+(u=d[d.length-1])+"'",f>0&&(s+=" and "),s+=(o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.endswith:le.odv4UniOperator.endswith)+"(",s+=c+",",a&&(s+=a),s+=u+")",f++),d.length>2)for(var p=1;p0&&(s+=" and "),"substringof"===(o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains)||"not substringof"===o){var g=u;u=c,c=g}s+=o+"(",s+=c+",",a&&(s+=a),s+=u+")",f++}0===f?(o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains,(-1!==l.indexOf("?")||-1!==l.indexOf("%3f"))&&(l=-1!==l.indexOf("?")?l.split("?").join(""):l.split("%3f").join("")),l="'"+l+"'"):o="wildcard"}else o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains,(-1!==l.indexOf("?")||-1!==l.indexOf("%3f"))&&(l=-1!==l.indexOf("?")?l.split("?").join(""):l.split("%3f").join("")),l="'"+l+"'";return"substringof"!==o&&"not substringof"!==o||(g=l,l=c,c=g),"wildcard"!==o&&(s+=o+"(",s+=c+",",a&&(s+=a),s+=l+")"),s},t.prototype.addParams=function(e){n.prototype.addParams.call(this,e),delete e.reqParams.params},t.prototype.onComplexPredicate=function(e,i,r){for(var s=[],o=0;o-1;f--)!/\bContent-ID:/i.test(c[f])||!/\bHTTP.+201/.test(c[f])||(l=parseInt(/\bContent-ID: (\d+)/i.exec(c[f])[1],10),o.addedRecords[l]&&(h=le.parse.parseJson(/^\{.+\}/m.exec(c[f])[0]),ze({},o.addedRecords[l],this.processResponse(h))));return o}return null},t.prototype.compareAndRemove=function(e,i,r){var s=this;return m(i)||Object.keys(e).forEach(function(o){o!==r&&"@odata.etag"!==o&&(le.isPlainObject(e[o])?(s.compareAndRemove(e[o],i[o]),0===Object.keys(e[o]).filter(function(l){return"@odata.etag"!==l}).length&&delete e[o]):(e[o]===i[o]||e[o]&&i[o]&&e[o].valueOf()===i[o].valueOf())&&delete e[o])}),e},t}(fc),FK=function(n){function t(){var e=n.call(this)||this;return yt("beforeSend",fc.prototype.beforeSend,e),e}return wl(t,n),t.prototype.insert=function(e,i,r,s,o){return this.pvt.position=o,this.updateType="add",{url:e.dataSource.insertUrl||e.dataSource.crudUrl||e.dataSource.url,data:JSON.stringify(ze({},{value:i,table:r,action:"insert"},le.getAddParams(this,e,s)))}},t.prototype.remove=function(e,i,r,s,o){return n.prototype.remove.call(this,e,i,r),{type:"POST",url:e.dataSource.removeUrl||e.dataSource.crudUrl||e.dataSource.url,data:JSON.stringify(ze({},{key:r,keyColumn:i,table:s,action:"remove"},le.getAddParams(this,e,o)))}},t.prototype.update=function(e,i,r,s,o){return this.updateType="update",this.updateKey=i,{type:"POST",url:e.dataSource.updateUrl||e.dataSource.crudUrl||e.dataSource.url,data:JSON.stringify(ze({},{value:r,action:"update",keyColumn:i,key:r[i],table:s},le.getAddParams(this,e,o)))}},t.prototype.processResponse=function(e,i,r,s,o,a,l){var h;if(e="batch"===(o?JSON.parse(o.data):e).action?le.parse.parseJson(e):e,"add"===this.updateType&&n.prototype.insert.call(this,i,e,null,null,this.pvt.position),"update"===this.updateType&&n.prototype.update.call(this,i,this.updateKey,e),this.updateType=void 0,e.added)for(h=0;hi&&h.push(c)}for(c=0;cthis.pageSize;)h.results.splice(0,1),h.keys.splice(0,1);return window.localStorage.setItem(this.guidId,JSON.stringify(h)),e},t.prototype.beforeSend=function(e,i,r){!m(this.cacheAdaptor.options.batch)&&le.endsWith(r.url,this.cacheAdaptor.options.batch)&&"post"===r.type.toLowerCase()&&i.headers.set("Accept",this.cacheAdaptor.options.multipartAccept),e.dataSource.crossDomain||i.headers.set("Accept",this.cacheAdaptor.options.accept)},t.prototype.update=function(e,i,r,s){return this.isCrudAction=!0,this.cacheAdaptor.update(e,i,r,s)},t.prototype.insert=function(e,i,r){return this.isInsertAction=!0,this.cacheAdaptor.insert(e,i,r)},t.prototype.remove=function(e,i,r,s){return this.isCrudAction=!0,this.cacheAdaptor.remove(e,i,r,s)},t.prototype.batchRequest=function(e,i,r){return this.cacheAdaptor.batchRequest(e,i,r)},t}(fc),it=function(){function n(t,e,i){var s,r=this;return this.dateParse=!0,this.timeZoneHandling=!0,this.persistQuery={},this.isInitialLoad=!1,this.requests=[],this.isInitialLoad=!0,!t&&!this.dataSource&&(t=[]),i=i||t.adaptor,t&&!1===t.timeZoneHandling&&(this.timeZoneHandling=t.timeZoneHandling),t instanceof Array?s={json:t,offline:!0}:"object"==typeof t?(t.json||(t.json=[]),t.enablePersistence||(t.enablePersistence=!1),t.id||(t.id=""),t.ignoreOnPersist||(t.ignoreOnPersist=[]),s={url:t.url,insertUrl:t.insertUrl,removeUrl:t.removeUrl,updateUrl:t.updateUrl,crudUrl:t.crudUrl,batchUrl:t.batchUrl,json:t.json,headers:t.headers,accept:t.accept,data:t.data,timeTillExpiration:t.timeTillExpiration,cachingPageSize:t.cachingPageSize,enableCaching:t.enableCaching,requestType:t.requestType,key:t.key,crossDomain:t.crossDomain,jsonp:t.jsonp,dataType:t.dataType,offline:void 0!==t.offline?t.offline:!(t.adaptor instanceof FK||t.adaptor instanceof _K||t.url),requiresFormat:t.requiresFormat,enablePersistence:t.enablePersistence,id:t.id,ignoreOnPersist:t.ignoreOnPersist}):le.throwError("DataManager: Invalid arguments"),void 0===s.requiresFormat&&!le.isCors()&&(s.requiresFormat=!!m(s.crossDomain)||s.crossDomain),void 0===s.dataType&&(s.dataType="json"),this.dataSource=s,this.defaultQuery=e,this.dataSource.enablePersistence&&this.dataSource.id&&window.addEventListener("unload",this.setPersistData.bind(this)),s.url&&s.offline&&!s.json.length?(this.isDataAvailable=!1,this.adaptor=i||new mf,this.dataSource.offline=!1,this.ready=this.executeQuery(e||new _t),this.ready.then(function(o){r.dataSource.offline=!0,r.isDataAvailable=!0,s.json=o.result,r.adaptor=new GE})):this.adaptor=s.offline?new GE:new mf,!s.jsonp&&this.adaptor instanceof mf&&(s.jsonp="callback"),this.adaptor=i||this.adaptor,s.enableCaching&&(this.adaptor=new UK(this.adaptor,s.timeTillExpiration,s.cachingPageSize)),this}return Object.defineProperty(n.prototype,"moduleName",{get:function(){return"datamanager"},enumerable:!0,configurable:!0}),n.prototype.getPersistedData=function(t){var e=localStorage.getItem(t||this.dataSource.id);return JSON.parse(e)},n.prototype.setPersistData=function(t,e,i){localStorage.setItem(e||this.dataSource.id,JSON.stringify(i||this.persistQuery))},n.prototype.setPersistQuery=function(t){var e=this,i=this.getPersistedData();if(this.isInitialLoad&&i&&Object.keys(i).length){this.persistQuery=i,this.persistQuery.queries=this.persistQuery.queries.filter(function(s){if(e.dataSource.ignoreOnPersist&&e.dataSource.ignoreOnPersist.length&&s.fn&&e.dataSource.ignoreOnPersist.some(function(l){return s.fn===l}))return!1;if("onWhere"===s.fn){var o=s.e;if(o&&o.isComplex&&o.predicates instanceof Array){var a=o.predicates.map(function(l){if(l.predicates&&l.predicates instanceof Array){var h=l.predicates.map(function(v){return new Ss(v.field,v.operator,v.value,v.ignoreCase,v.ignoreAccent,v.matchCase)});return"and"===l.condition?Ss.and(h):Ss.or(h)}return new Ss(l.field,l.operator,l.value,l.ignoreCase,l.ignoreAccent,l.matchCase)});s.e=new Ss(a[0],o.condition,a.slice(1))}}return!0});var r=ze(new _t,this.persistQuery);return this.isInitialLoad=!1,r}return this.persistQuery=t,this.isInitialLoad=!1,t},n.prototype.setDefaultQuery=function(t){return this.defaultQuery=t,this},n.prototype.executeLocal=function(t){!this.defaultQuery&&!(t instanceof _t)&&le.throwError("DataManager - executeLocal() : A query is required to execute"),this.dataSource.json||le.throwError("DataManager - executeLocal() : Json data is required to execute"),this.dataSource.enablePersistence&&this.dataSource.id&&(t=this.setPersistQuery(t));var e=this.adaptor.processQuery(this,t=t||this.defaultQuery);if(t.subQuery){var i=t.subQuery.fromTable,r=t.subQuery.lookups,s=t.isCountRequired?e.result:e;r&&r instanceof Array&&le.buildHierarchy(t.subQuery.fKey,i,s,r,t.subQuery.key);for(var o=0;oli");z.classList.remove("json-parent");for(var j=0;j',W=ve.children[0].placeholder}return W}function Q(k,W,ve){!m(ve)&&""!==ve&&K(W,ve.split(" ")),!m(k)&&""!==k&&V(W,k.split(" "))}function oe(k,W,ve){if("multiselect"===ve||function Mo(k){if(!k)return!1;for(var W=k;W&&W!==document.body;){if("none"===window.getComputedStyle(W).display)return!1;W=W.parentElement}return!0}(k)){var Te="multiselect"===ve?k:k.clientWidth-parseInt(getComputedStyle(k,null).getPropertyValue("padding-left"),10);!m(W)&&!m(W.getElementsByClassName("e-float-text-content")[0])&&(W.getElementsByClassName("e-float-text-content")[0].classList.contains("e-float-text-overflow")&&W.getElementsByClassName("e-float-text-content")[0].classList.remove("e-float-text-overflow"),(Te0)for(var Ye=0;Ye<_e.length;Ye++)_e[parseInt(Ye.toString(),10)].addEventListener("mousedown",wo,!1),_e[parseInt(Ye.toString(),10)].addEventListener("mouseup",Ul,!1);else if(_e.length>0)for(Ye=0;Ye<_e.length;Ye++)_e[parseInt(Ye.toString(),10)].removeEventListener("mousedown",wo,this),_e[parseInt(Ye.toString(),10)].removeEventListener("mouseup",Ul,this)}function wo(){for(var W=this.parentElement;!W.classList.contains("e-input-group");)W=W.parentElement;!function Sa(k,W){!k.classList.contains("e-disabled")&&!k.querySelector("input").readOnly&&W.classList.add("e-input-btn-ripple")}(W,this)}function Ul(){var k=this;setTimeout(function(){k.classList.remove("e-input-btn-ripple")},500)}function yb(k,W){var ve=W("span",{className:k});return ve.classList.add("e-input-group-icon"),ve}function I_(k,W,ve,Te){var _e=m(Te)?Si:Te,Ye=yb(k,_e);W.classList.add("e-float-icon-left");var vi=W.querySelector(".e-input-in-wrap");if(m(vi)){vi=_e("span",{className:"e-input-in-wrap"}),ve.parentNode.insertBefore(vi,ve);var Gs=W.querySelectorAll(ve.tagName+" ~ *");vi.appendChild(ve);for(var ts=0;ts-1)if("class"===_e){var Ye=this.getInputValidClassList(k[""+_e]);""!==Ye&&V([W],Ye.split(" "))}else if("style"===_e){var vi=W.getAttribute(_e);vi=m(vi)?k[""+_e]:vi+k[""+_e],W.setAttribute(_e,vi)}else W.setAttribute(_e,k[""+_e])}},n.isBlank=function Hle(k){return!k||/^\s*$/.test(k)}}(Le||(Le={})),new RegExp("^(-)?(\\d*)$"),new RegExp("^[A-Za-z0-9._%+-]{1,}@[A-Za-z0-9._%+-]{1,}([.]{1}[a-zA-Z0-9]{2,}|[.]{1}[a-zA-Z0-9]{2,4}[.]{1}[a-zA-Z0-9]{2,4})$"),new RegExp("^([0-9]{4})-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])$"),new RegExp("^[0-9]*$"),new RegExp("^[+]?[0-9]{9,13}$"),new RegExp("^\\d{13,16}$");var me=function(){function n(t,e){this.width=t,this.height=e}return n.prototype.isEmpty=function(){return 0===this.height&&0===this.width},n.prototype.clone=function(){return new n(this.width,this.height)},n}(),Rie=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),KB=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},R=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Rie(t,n),t.equals=function(e,i){return e===i||!(!e||!i)&&(!e||!i||e.x===i.x&&e.y===i.y)},t.isEmptyPoint=function(e){return!(e.x&&e.y)},t.transform=function(e,i,r){var s={x:0,y:0};return s.x=Math.round(100*(e.x+r*Math.cos(i*Math.PI/180)))/100,s.y=Math.round(100*(e.y+r*Math.sin(i*Math.PI/180)))/100,s},t.findLength=function(e,i){return Math.sqrt(Math.pow(e.x-i.x,2)+Math.pow(e.y-i.y,2))},t.findAngle=function(e,i){var r=Math.atan2(i.y-e.y,i.x-e.x);return r=180*r/Math.PI,(r%=360)<0&&(r+=360),r},t.distancePoints=function(e,i){return Math.sqrt(Math.pow(i.x-e.x,2)+Math.pow(i.y-e.y,2))},t.getLengthFromListOfPoints=function(e){for(var i=0,r=0;ri.y&&!r?o.y+=s:o.y-=s:e.y===i.y?e.xi.x&&!r?o.x+=s:o.x-=s:r?(a=this.findAngle(e,i),o=this.transform(e,a,s)):(a=this.findAngle(i,e),o=this.transform(i,a,s)),o},t.direction=function(e,i){return Math.abs(i.x-e.x)>Math.abs(i.y-e.y)?e.x0)for(var r=0;rt.right||this.top>t.bottom||this.bottom=t.right&&this.top<=t.top&&this.bottom>=t.bottom},n.prototype.containsPoint=function(t,e){return void 0===e&&(e=0),this.left-e<=t.x&&this.right+e>=t.x&&this.top-e<=t.y&&this.bottom+e>=t.y},n.toBounds=function(t){for(var e=new n,i=0,r=t;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},s3=function(n){if(n)switch(n.type){case"Linear":default:return wI;case"Radial":return Gie}return wI},Yie=function(){return function n(t,e,i,r){this.left=t,this.right=e,this.top=i,this.bottom=r}}(),Jn=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),rt([I(0)],t.prototype,"left",void 0),rt([I(0)],t.prototype,"right",void 0),rt([I(0)],t.prototype,"top",void 0),rt([I(0)],t.prototype,"bottom",void 0),t}(Ee),Qie=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),rt([I(45)],t.prototype,"angle",void 0),rt([I(5)],t.prototype,"distance",void 0),rt([I(.7)],t.prototype,"opacity",void 0),rt([I("lightgrey")],t.prototype,"color",void 0),t}(Ee),o3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),t.prototype.getClassName=function(){return"Stop"},rt([I("")],t.prototype,"color",void 0),rt([I(0)],t.prototype,"offset",void 0),rt([I(1)],t.prototype,"opacity",void 0),t}(Ee),wx=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),rt([Bt([],o3)],t.prototype,"stops",void 0),rt([I("None")],t.prototype,"type",void 0),rt([I("")],t.prototype,"id",void 0),t}(Ee),wI=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),rt([I(0)],t.prototype,"x1",void 0),rt([I(0)],t.prototype,"x2",void 0),rt([I(0)],t.prototype,"y1",void 0),rt([I(0)],t.prototype,"y2",void 0),t}(wx),Gie=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),rt([I(0)],t.prototype,"cx",void 0),rt([I(0)],t.prototype,"cy",void 0),rt([I(0)],t.prototype,"fx",void 0),rt([I(0)],t.prototype,"fy",void 0),rt([I(50)],t.prototype,"r",void 0),t}(wx),Nl=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),rt([I("white")],t.prototype,"fill",void 0),rt([I("black")],t.prototype,"strokeColor",void 0),rt([I("")],t.prototype,"strokeDashArray",void 0),rt([I(1)],t.prototype,"strokeWidth",void 0),rt([I(1)],t.prototype,"opacity",void 0),rt([T0(s3)],t.prototype,"gradient",void 0),t}(Ee),a3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),rt([I("transparent")],t.prototype,"fill",void 0),t}(Nl),qf=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),rt([I("black")],t.prototype,"color",void 0),rt([I("Arial")],t.prototype,"fontFamily",void 0),rt([I(12)],t.prototype,"fontSize",void 0),rt([I(!1)],t.prototype,"italic",void 0),rt([I(!1)],t.prototype,"bold",void 0),rt([I("CollapseSpace")],t.prototype,"whiteSpace",void 0),rt([I("WrapWithOverflow")],t.prototype,"textWrapping",void 0),rt([I("Center")],t.prototype,"textAlign",void 0),rt([I("None")],t.prototype,"textDecoration",void 0),rt([I("Wrap")],t.prototype,"textOverflow",void 0),rt([I("transparent")],t.prototype,"fill",void 0),t}(Nl),on=function(n){return n[n.Default=0]="Default",n[n.expandNode=2]="expandNode",n[n.interaction=4]="interaction",n[n.GroupingInProgress=8]="GroupingInProgress",n[n.GroupClipboardInProcess=16]="GroupClipboardInProcess",n[n.ClearObject=32]="ClearObject",n}(on||{}),ci=function(n){return n[n.Visible=1]="Visible",n[n.Hidden=2]="Hidden",n[n.Hover=4]="Hover",n[n.Connect=8]="Connect",n}(ci||{}),Kt=function(n){return n[n.None=0]="None",n[n.ShowHorizontalLines=1]="ShowHorizontalLines",n[n.ShowVerticalLines=2]="ShowVerticalLines",n[n.ShowLines=3]="ShowLines",n[n.SnapToHorizontalLines=4]="SnapToHorizontalLines",n[n.SnapToVerticalLines=8]="SnapToVerticalLines",n[n.SnapToLines=12]="SnapToLines",n[n.SnapToObject=16]="SnapToObject",n[n.All=31]="All",n}(Kt||{}),mr=function(n){return n[n.None=1]="None",n[n.ConnectorSourceThumb=2]="ConnectorSourceThumb",n[n.ConnectorTargetThumb=4]="ConnectorTargetThumb",n[n.ResizeSouthEast=8]="ResizeSouthEast",n[n.ResizeSouthWest=16]="ResizeSouthWest",n[n.ResizeNorthEast=32]="ResizeNorthEast",n[n.ResizeNorthWest=64]="ResizeNorthWest",n[n.ResizeEast=128]="ResizeEast",n[n.ResizeWest=256]="ResizeWest",n[n.ResizeSouth=512]="ResizeSouth",n[n.ResizeNorth=1024]="ResizeNorth",n[n.Rotate=2048]="Rotate",n[n.UserHandle=4096]="UserHandle",n[n.ToolTip=8192]="ToolTip",n[n.ResizeAll=2046]="ResizeAll",n[n.All=16382]="All",n}(mr||{}),qe=function(n){return n[n.None=1]="None",n[n.Select=2]="Select",n[n.Delete=4]="Delete",n[n.Drag=8]="Drag",n[n.DragSourceEnd=16]="DragSourceEnd",n[n.DragTargetEnd=32]="DragTargetEnd",n[n.DragSegmentThumb=64]="DragSegmentThumb",n[n.AllowDrop=128]="AllowDrop",n[n.Bridging=256]="Bridging",n[n.BridgeObstacle=512]="BridgeObstacle",n[n.InheritBridging=1024]="InheritBridging",n[n.PointerEvents=2048]="PointerEvents",n[n.Tooltip=4096]="Tooltip",n[n.InheritTooltip=8192]="InheritTooltip",n[n.Interaction=4218]="Interaction",n[n.ReadOnly=16384]="ReadOnly",n[n.LineRouting=32768]="LineRouting",n[n.InheritLineRouting=65536]="InheritLineRouting",n[n.ConnectToNearByNode=131072]="ConnectToNearByNode",n[n.ConnectToNearByPort=262144]="ConnectToNearByPort",n[n.ConnectToNearByElement=393216]="ConnectToNearByElement",n[n.InheritSegmentThumbShape=524288]="InheritSegmentThumbShape",n[n.InheritSegmentThumbSize=1048576]="InheritSegmentThumbSize",n[n.Default=2043454]="Default",n}(qe||{}),Nr=function(n){return n[n.ReadOnly=2]="ReadOnly",n[n.InheritReadOnly=4]="InheritReadOnly",n[n.Select=8]="Select",n[n.Drag=16]="Drag",n[n.Resize=32]="Resize",n[n.Rotate=64]="Rotate",n[n.Tooltip=128]="Tooltip",n[n.Interaction=120]="Interaction",n[n.None=0]="None",n}(Nr||{}),ie=function(n){return n[n.None=0]="None",n[n.Select=2]="Select",n[n.Drag=4]="Drag",n[n.Rotate=8]="Rotate",n[n.Shadow=16]="Shadow",n[n.PointerEvents=32]="PointerEvents",n[n.Delete=64]="Delete",n[n.InConnect=128]="InConnect",n[n.OutConnect=256]="OutConnect",n[n.Individual=512]="Individual",n[n.Expandable=1024]="Expandable",n[n.AllowDrop=2048]="AllowDrop",n[n.Inherit=78]="Inherit",n[n.ResizeNorthEast=4096]="ResizeNorthEast",n[n.ResizeEast=8192]="ResizeEast",n[n.ResizeSouthEast=16384]="ResizeSouthEast",n[n.ResizeSouth=32768]="ResizeSouth",n[n.ResizeSouthWest=65536]="ResizeSouthWest",n[n.ResizeWest=131072]="ResizeWest",n[n.ResizeNorthWest=262144]="ResizeNorthWest",n[n.ResizeNorth=524288]="ResizeNorth",n[n.Resize=1044480]="Resize",n[n.AspectRatio=1048576]="AspectRatio",n[n.Tooltip=2097152]="Tooltip",n[n.InheritTooltip=4194304]="InheritTooltip",n[n.ReadOnly=8388608]="ReadOnly",n[n.HideThumbs=16777216]="HideThumbs",n[n.AllowMovingOutsideLane=33554432]="AllowMovingOutsideLane",n[n.Default=5240814]="Default",n}(ie||{}),Xr=function(n){return n[n.None=0]="None",n[n.ElementIsPort=2]="ElementIsPort",n[n.ElementIsGroup=4]="ElementIsGroup",n[n.HorizontalLaneHeader=8]="HorizontalLaneHeader",n}(Xr||{}),bt=function(n){return n[n.Rotate=2]="Rotate",n[n.ConnectorSource=4]="ConnectorSource",n[n.ConnectorTarget=8]="ConnectorTarget",n[n.ResizeNorthEast=16]="ResizeNorthEast",n[n.ResizeEast=32]="ResizeEast",n[n.ResizeSouthEast=64]="ResizeSouthEast",n[n.ResizeSouth=128]="ResizeSouth",n[n.ResizeSouthWest=256]="ResizeSouthWest",n[n.ResizeWest=512]="ResizeWest",n[n.ResizeNorthWest=1024]="ResizeNorthWest",n[n.ResizeNorth=2048]="ResizeNorth",n[n.Default=4094]="Default",n}(bt||{}),nt=function(n){return n[n.None=1]="None",n[n.Bridging=2]="Bridging",n[n.UndoRedo=4]="UndoRedo",n[n.Tooltip=8]="Tooltip",n[n.UserInteraction=16]="UserInteraction",n[n.ApiUpdate=32]="ApiUpdate",n[n.PageEditable=48]="PageEditable",n[n.Zoom=64]="Zoom",n[n.PanX=128]="PanX",n[n.PanY=256]="PanY",n[n.Pan=384]="Pan",n[n.ZoomTextEdit=512]="ZoomTextEdit",n[n.Virtualization=1024]="Virtualization",n[n.LineRouting=2048]="LineRouting",n[n.Default=500]="Default",n}(nt||{}),ri=function(n){return n[n.None=0]="None",n[n.SingleSelect=1]="SingleSelect",n[n.MultipleSelect=2]="MultipleSelect",n[n.ZoomPan=4]="ZoomPan",n[n.DrawOnce=8]="DrawOnce",n[n.ContinuousDraw=16]="ContinuousDraw",n[n.Default=3]="Default",n}(ri||{}),Qa=function(n){return n[n.Self=1]="Self",n[n.Parent=2]="Parent",n}(Qa||{}),ft=function(n){return n[n.None=0]="None",n[n.Control=1]="Control",n[n.Meta=1]="Meta",n[n.Alt=2]="Alt",n[n.Shift=4]="Shift",n}(ft||{}),Mt=function(n){return n[n.None=null]="None",n[n.Number0=0]="Number0",n[n.Number1=1]="Number1",n[n.Number2=2]="Number2",n[n.Number3=3]="Number3",n[n.Number4=4]="Number4",n[n.Number5=5]="Number5",n[n.Number6=6]="Number6",n[n.Number7=7]="Number7",n[n.Number8=8]="Number8",n[n.Number9=9]="Number9",n[n.A=65]="A",n[n.B=66]="B",n[n.C=67]="C",n[n.D=68]="D",n[n.E=69]="E",n[n.F=70]="F",n[n.G=71]="G",n[n.H=72]="H",n[n.I=73]="I",n[n.J=74]="J",n[n.K=75]="K",n[n.L=76]="L",n[n.M=77]="M",n[n.N=78]="N",n[n.O=79]="O",n[n.P=80]="P",n[n.Q=81]="Q",n[n.R=82]="R",n[n.S=83]="S",n[n.T=84]="T",n[n.U=85]="U",n[n.V=86]="V",n[n.W=87]="W",n[n.X=88]="X",n[n.Y=89]="Y",n[n.Z=90]="Z",n[n.Left=37]="Left",n[n.Up=38]="Up",n[n.Right=39]="Right",n[n.Down=40]="Down",n[n.Escape=27]="Escape",n[n.Space=32]="Space",n[n.PageUp=33]="PageUp",n[n.PageDown=34]="PageDown",n[n.End=35]="End",n[n.Home=36]="Home",n[n.Delete=46]="Delete",n[n.Tab=9]="Tab",n[n.Enter=13]="Enter",n[n.BackSpace=8]="BackSpace",n[n.F1=112]="F1",n[n.F2=113]="F2",n[n.F3=114]="F3",n[n.F4=115]="F4",n[n.F5=116]="F5",n[n.F6=117]="F6",n[n.F7=118]="F7",n[n.F8=119]="F8",n[n.F9=120]="F9",n[n.F10=121]="F10",n[n.F11=122]="F11",n[n.F12=123]="F12",n[n.Star=56]="Star",n[n.Plus=187]="Plus",n[n.Minus=189]="Minus",n[n.BracketLeft=219]="BracketLeft",n[n.BracketRight=221]="BracketRight",n}(Mt||{}),ee=function(n){return n[n.Render=2]="Render",n[n.PublicMethod=4]="PublicMethod",n[n.ToolAction=8]="ToolAction",n[n.UndoRedo=16]="UndoRedo",n[n.TextEdit=32]="TextEdit",n[n.Group=64]="Group",n[n.Clear=128]="Clear",n[n.PreventClearSelection=256]="PreventClearSelection",n[n.Interactions=512]="Interactions",n[n.PreventHistory=1024]="PreventHistory",n[n.PreventIconsUpdate=2048]="PreventIconsUpdate",n[n.PreventCollectionChangeOnDragOver=4096]="PreventCollectionChangeOnDragOver",n[n.PreventZIndexOnDragging=8192]="PreventZIndexOnDragging",n[n.isGroupDragging=16384]="isGroupDragging",n[n.DragUsingMouse=32768]="DragUsingMouse",n[n.DecoratorPropertyChange=65536]="DecoratorPropertyChange",n[n.PreventLaneContainerUpdate=131072]="PreventLaneContainerUpdate",n}(ee||{}),Ga=function(n){return n[n.None=2]="None",n[n.DrawSelectorBorder=4]="DrawSelectorBorder",n[n.PreventRenderSelector=8]="PreventRenderSelector",n}(Ga||{}),$i=function(n){return n[n.None=0]="None",n[n.PreventDrag=2]="PreventDrag",n[n.PreventScale=4]="PreventScale",n[n.PreventDataInit=8]="PreventDataInit",n[n.hScrollbarMoved=16]="hScrollbarMoved",n[n.vScrollbarMoved=32]="vScrollbarMoved",n[n.AnimationClick=64]="AnimationClick",n[n.EnableGroupAction=128]="EnableGroupAction",n[n.PanInProgress=256]="PanInProgress",n[n.OverViewAction=512]="OverViewAction",n}($i||{}),da=function(n){return n[n.None=0]="None",n[n.PropertyChange=1024]="PropertyChange",n[n.Interaction=2048]="Interaction",n}(da||{}),Ae=function(n){return n[n.Zero=0]="Zero",n[n.One=1]="One",n[n.Two=2]="Two",n[n.Three=3]="Three",n[n.Four=4]="Four",n[n.Five=5]="Five",n}(Ae||{}),Ce=function(n){return n[n.collectionChange=0]="collectionChange",n[n.rotateChange=1]="rotateChange",n[n.positionChange=2]="positionChange",n[n.propertyChange=3]="propertyChange",n[n.selectionChange=4]="selectionChange",n[n.sizeChange=5]="sizeChange",n[n.drop=6]="drop",n[n.sourcePointChange=7]="sourcePointChange",n[n.targetPointChange=8]="targetPointChange",n[n.connectionChange=9]="connectionChange",n[n.animationComplete=10]="animationComplete",n[n.click=11]="click",n[n.doubleClick=12]="doubleClick",n[n.scrollChange=13]="scrollChange",n[n.dragEnter=14]="dragEnter",n[n.dragLeave=15]="dragLeave",n[n.dragOver=16]="dragOver",n[n.textEdit=17]="textEdit",n[n.paletteSelectionChange=18]="paletteSelectionChange",n[n.historyChange=19]="historyChange",n[n.mouseEnter=20]="mouseEnter",n[n.mouseLeave=21]="mouseLeave",n[n.mouseOver=22]="mouseOver",n[n.expandStateChange=23]="expandStateChange",n[n.segmentCollectionChange=24]="segmentCollectionChange",n[n.commandExecute=25]="commandExecute",n[n.historyStateChange=26]="historyStateChange",n[n.onUserHandleMouseDown=27]="onUserHandleMouseDown",n[n.onUserHandleMouseUp=28]="onUserHandleMouseUp",n[n.onUserHandleMouseEnter=29]="onUserHandleMouseEnter",n[n.onUserHandleMouseLeave=30]="onUserHandleMouseLeave",n[n.onImageLoad=31]="onImageLoad",n[n.onDoBindingInit=32]="onDoBindingInit",n[n.keyUp=33]="keyUp",n[n.keyDown=34]="keyDown",n[n.fixedUserHandleClick=35]="fixedUserHandleClick",n[n.elementDraw=36]="elementDraw",n[n.mouseWheel=37]="mouseWheel",n[n.segmentChange=38]="segmentChange",n[n.onFixedUserHandleMouseDown=39]="onFixedUserHandleMouseDown",n[n.onFixedUserHandleMouseUp=40]="onFixedUserHandleMouseUp",n[n.onFixedUserHandleMouseEnter=41]="onFixedUserHandleMouseEnter",n[n.onFixedUserHandleMouseLeave=42]="onFixedUserHandleMouseLeave",n[n.loaded=43]="loaded",n}(Ce||{}),oi=function(n){return n[n.None=1]="None",n[n.Drag=2]="Drag",n[n.Draw=4]="Draw",n[n.InConnect=8]="InConnect",n[n.OutConnect=16]="OutConnect",n[n.ToolTip=32]="ToolTip",n[n.InheritTooltip=64]="InheritTooltip",n[n.Default=24]="Default",n}(oi||{}),Cx=function(n){return n[n.None=1]="None",n[n.Source=2]="Source",n[n.Target=4]="Target",n[n.Intermediate=8]="Intermediate",n[n.All=14]="All",n}(Cx||{}),CI=function(n){return n[n.None=0]="None",n[n.SymmetricAngle=2]="SymmetricAngle",n[n.SymmetricDistance=4]="SymmetricDistance",n[n.Default=6]="Default",n}(CI||{}),hs=function(){function n(){this.pivot={x:.5,y:.5},this.isDirt=!0,this.isExport=!1,this.exportScaleValue={x:0,y:0},this.exportScaleOffset={x:0,y:0},this.canApplyStyle=!0,this.visible=!0,this.offsetX=0,this.offsetY=0,this.cornerRadius=0,this.minHeight=void 0,this.minWidth=void 0,this.maxWidth=void 0,this.maxHeight=void 0,this.width=void 0,this.height=void 0,this.rotateAngle=0,this.margin={left:0,right:0,top:0,bottom:0},this.connectionDirection="Auto",this.horizontalAlignment="Auto",this.verticalAlignment="Auto",this.flip="None",this.flipMode="All",this.relativeMode="Point",this.transform=Qa.Self|Qa.Parent,this.style={fill:"white",strokeColor:"black",opacity:1,strokeWidth:1},this.desiredSize=new me,this.actualSize=new me,this.parentTransform=0,this.preventContainer=!1,this.isSvgRender=!1,this.bounds=new Ne(0,0,0,0),this.shadow=null,this.description="",this.staticSize=!1,this.shapeType="",this.isRectElement=!1,this.isCalculateDesiredSize=!0,this.flipOffset={x:0,y:0},this.elementActions=Xr.None,this.inversedAlignment=!0,this.position=void 0,this.unitMode=void 0,this.float=!1,this.floatingBounds=void 0}return n.prototype.setOffsetWithRespectToBounds=function(t,e,i){this.unitMode=i,this.position={x:t,y:e}},n.prototype.getAbsolutePosition=function(t){if(void 0!==this.position)return"Absolute"===this.unitMode?this.position:{x:this.position.x*t.width,y:this.position.y*t.height}},Object.defineProperty(n.prototype,"outerBounds",{get:function(){return this.floatingBounds||this.bounds},set:function(t){this.floatingBounds=t},enumerable:!0,configurable:!0}),n.prototype.measure=function(t,e,i){var s=void 0!==this.height?this.height:(t.height||0)-this.margin.top-this.margin.bottom;return this.id&&0===s&&this.elementActions&Xr.HorizontalLaneHeader&&(s=this.actualSize.height),this.desiredSize=new me(void 0!==this.width?this.width:(t.width||0)-this.margin.left-this.margin.right,s),this.isCalculateDesiredSize&&(this.desiredSize=this.validateDesiredSize(this.desiredSize,t)),this.desiredSize},n.prototype.arrange=function(t){return this.actualSize=t,this.updateBounds(),this.actualSize},n.prototype.updateBounds=function(){this.bounds=yr(this)},n.prototype.validateDesiredSize=function(t,e){return this.isRectElement&&!this.width&&!this.minWidth&&!this.maxWidth&&(t.width=50),this.isRectElement&&!this.height&&!this.minHeight&&!this.maxHeight&&(t.height=50),(void 0===t||void 0!==this.width&&void 0!==this.height)&&((t=t||new me).width=void 0===this.width?(e.width||0)-this.margin.left-this.margin.right:this.width,t.height=void 0===this.height?(e.height||0)-this.margin.top-this.margin.bottom:this.height),void 0!==this.minWidth&&(t.width=Math.max(t.width,this.minWidth)),void 0!==this.minHeight&&(t.height=Math.max(t.height,this.minHeight)),void 0!==this.maxWidth&&0!==this.maxWidth&&(t.width=Math.min(t.width,this.maxWidth)),void 0!==this.maxHeight&&0!==this.maxHeight&&(t.height=Math.min(t.height,this.maxHeight)),t},n}(),ere=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Cs=function(n){function t(){var e=null!==n&&n.apply(this,arguments)||this;return e.padding=new Yie(0,0,0,0),e.desiredBounds=void 0,e.measureChildren=!0,e.prevRotateAngle=0,e}return ere(t,n),t.prototype.hasChildren=function(){return void 0!==this.children&&this.children.length>0},t.prototype.measure=function(e,i,r){this.desiredBounds=void 0;var o,a,s=void 0;if(this.hasChildren()){for(var l=0;l=n.width&&s.length>0)i[i.length]={text:s,x:0,dy:0,width:o},s="";else{(s+=a[r+1]||"").indexOf("\n")>-1&&(i[i.length]={text:s,x:0,dy:0,width:Bc(s,n)},s="");var l=Bc(s,n);Math.ceil(l)+2>=n.width&&s.length>0&&(i[i.length]={text:s,x:0,dy:0,width:l},s=""),r===a.length-1&&s.length>0&&(i[i.length]={text:s,x:0,dy:0,width:l},s="")}else i=function Soe(n,t,e){var c,d,u,f,i=[],r="",s=0,o=0,a="nowrap"!==n.whiteSpace,h=(t||n.content).split("\n");for(s=0;s0?" ":"")+c[parseInt(o.toString(),10)];var p=Bc(d=c[o+1]?r+" "+c[o+1]:r,n);Math.floor(p)>(e||n.width)-2&&r.length>0?(i[i.length]={text:r,x:0,dy:0,width:d===r?p:r===f?u:Bc(r,n)},r=""):o===c.length-1&&(i[i.length]={text:r,x:0,dy:0,width:p},r=""),f=d,u=p}return i}(n,t,e);else i[i.length]={text:a,x:0,dy:0,width:Bc(a,n)};return i}(l,r,n.isLaneOrientation?i:void 0),n.wrapBounds=a=function Ioe(n,t){var r,s,e={x:0,width:0},i=0;for(i=0;in.width&&("Ellipsis"===n.textOverflow||"Clip"===n.textOverflow)?0:-r/2:"right"===n.textAlign?-r:t.length>1?0:-r/2,t[parseInt(i.toString(),10)].dy=1.2*n.fontSize,t[parseInt(i.toString(),10)].x=r,e.x=Math.min(e.x,r),e.width=Math.max(e.width,s);return e}(l,o),s.width=a.width,n.wrapBounds.width>=i&&"Wrap"!==l.textOverflow&&(s.width=i),s.height=o.length*n.style.fontSize*1.2,s}(this,0,0,this.isLaneOrientation?e.height:this.width||e.width):this.desiredSize,this.desiredSize=void 0===this.width||void 0===this.height?new me(i.width,i.height):new me(this.width,this.height),this.desiredSize=this.validateDesiredSize(this.desiredSize,e),this.desiredSize},t.prototype.arrange=function(e){return(e.width!==this.actualSize.width||e.height!==this.actualSize.height||this.isDirt)&&(this.doWrap=!0),this.actualSize=e,this.updateBounds(),this.isDirt=!1,this.actualSize},t}(hs),ire=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Mi=function(n){function t(){var e=null!==n&&n.apply(this,arguments)||this;return e.measureChildren=void 0,e}return ire(t,n),t.prototype.measure=function(e,i,r){var s=void 0,o=void 0;if(this.hasChildren()){for(var a=0,l=this.children;a=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Td=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return are(t,n),Ph([I("")],t.prototype,"content",void 0),Ph([I("TopLeft")],t.prototype,"position",void 0),Ph([I("Mouse")],t.prototype,"relativeMode",void 0),Ph([I(!0)],t.prototype,"showTipPointer",void 0),Ph([I("auto")],t.prototype,"width",void 0),Ph([I("auto")],t.prototype,"height",void 0),Ph([I("Auto")],t.prototype,"openOn",void 0),Ph([I()],t.prototype,"animation",void 0),Ph([I(!1)],t.prototype,"isSticky",void 0),t}(Ee);function l3(n){var t=new wh;t=h3(n.tooltip,t);var e=new wh(t);return e.beforeCollision=hre,e.beforeOpen=lre,e.cssClass="e-diagram-tooltip",e.opensOn="custom",e.appendTo("#"+n.element.id),e.close(),e}function lre(n){(""===this.content||void 0===this.content)&&(n.element.style.display="none")}function hre(n){n.collidedPosition&&n.collidedPosition!==this.position&&(n.element.style.display="none")}function Ex(n,t){var e=n.tooltipObject;return h3(t?t.tooltip:n.tooltip,e),e}function h3(n,t){return n.content?(t.content=n.content,"string"==typeof n.content&&(t.content=ko(function(){return n.content})),t.position=n.position,t.showTipPointer=n.showTipPointer,t.width=n.width,t.height=n.height,t.animation=n.animation?n.animation:{close:{effect:"None"}}):t.close(),t}var Dx=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Bn=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},xx=function(n){function t(e,i,r,s){var o=n.call(this,e,i,r,s)||this;return o.inEdges=[],o.outEdges=[],o}return Dx(t,n),Bn([I("")],t.prototype,"id",void 0),Bn([I("Center")],t.prototype,"horizontalAlignment",void 0),Bn([I("Center")],t.prototype,"verticalAlignment",void 0),Bn([re({},Jn)],t.prototype,"margin",void 0),Bn([I(12)],t.prototype,"width",void 0),Bn([I(12)],t.prototype,"height",void 0),Bn([re({},Nl)],t.prototype,"style",void 0),Bn([I("Square")],t.prototype,"shape",void 0),Bn([I("Auto")],t.prototype,"connectionDirection",void 0),Bn([I(ci.Connect)],t.prototype,"visibility",void 0),Bn([I("")],t.prototype,"pathData",void 0),Bn([I(oi.Default)],t.prototype,"constraints",void 0),Bn([I()],t.prototype,"addInfo",void 0),Bn([I()],t.prototype,"outEdges",void 0),Bn([I()],t.prototype,"inEdges",void 0),Bn([re({},Td)],t.prototype,"tooltip",void 0),t}(Ee),Es=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return Dx(t,n),t.prototype.getClassName=function(){return"PointPort"},Bn([re({x:.5,y:.5},R)],t.prototype,"offset",void 0),t}(xx),Tc=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return Dx(t,n),t.prototype.getClassName=function(){return"PathPort"},Bn([I(.5)],t.prototype,"offset",void 0),Bn([re({x:0,y:0},R)],t.prototype,"displacement",void 0),Bn([I("Center")],t.prototype,"alignment",void 0),t}(xx),xI=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),lr=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},cre=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return xI(t,n),lr([I("blue")],t.prototype,"color",void 0),lr([I("")],t.prototype,"content",void 0),lr([I("")],t.prototype,"link",void 0),lr([I("None")],t.prototype,"textDecoration",void 0),lr([I("NewTab")],t.prototype,"hyperlinkOpenState",void 0),t}(Ee),Tx=function(n){function t(e,i,r,s){var o=n.call(this,e,i,r,s)||this;return r.id||(o.id=e.parentObj&&e.parentObj.propName&&"phases"===e.parentObj.propName?e.parentObj.id:Qe()),o}return xI(t,n),lr([I("")],t.prototype,"content",void 0),lr([I(void 0)],t.prototype,"template",void 0),lr([I("String")],t.prototype,"annotationType",void 0),lr([I(!0)],t.prototype,"visibility",void 0),lr([I(Nr.InheritReadOnly)],t.prototype,"constraints",void 0),lr([re(void 0,cre)],t.prototype,"hyperlink",void 0),lr([I("")],t.prototype,"id",void 0),lr([I()],t.prototype,"width",void 0),lr([I()],t.prototype,"height",void 0),lr([I(0)],t.prototype,"rotateAngle",void 0),lr([I("Parent")],t.prototype,"rotationReference",void 0),lr([re({strokeWidth:0,strokeColor:"transparent",fill:"transparent"},qf)],t.prototype,"style",void 0),lr([I("Center")],t.prototype,"horizontalAlignment",void 0),lr([I("Center")],t.prototype,"verticalAlignment",void 0),lr([re({},Jn)],t.prototype,"margin",void 0),lr([re({top:void 0,bottom:void 0,left:void 0,right:void 0},Jn)],t.prototype,"dragLimit",void 0),lr([I("Shape")],t.prototype,"type",void 0),lr([re({},Td)],t.prototype,"tooltip",void 0),lr([I()],t.prototype,"addInfo",void 0),t}(Ee),Kn=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return xI(t,n),t.prototype.getClassName=function(){return"ShapeAnnotation"},lr([re({x:.5,y:.5},R)],t.prototype,"offset",void 0),t}(Tx),Or=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return xI(t,n),t.prototype.getClassName=function(){return"PathAnnotation"},lr([I(.5)],t.prototype,"offset",void 0),lr([re({x:0,y:0},R)],t.prototype,"displacement",void 0),lr([I("Center")],t.prototype,"alignment",void 0),lr([I(!1)],t.prototype,"segmentAngle",void 0),t}(Tx);function Ax(n){return pre[n.toString()]}function c3(n){return mre[""+n]}var pre={X:"M14,14 L106,106 M106,14 L14,106",Circle:"M0,50 A50,50,0 1 1 100,50 A50,50,0 1 1 0,50 Z",Square:"M0,0 L10,0 L10,10 L0,10 z"},gre={OpenArrow:"M15.9,23 L5,16 L15.9,9 L17,10.7 L8.7,16 L17,21.3Z",Square:"M0,0 L10,0 L10,10 L0,10 z",Fletch:"M14.8,10c0,0-3.5,6,0.2,12c0,0-2.5-6-10.9-6C4.1,16,11.3,16,14.8,10z",OpenFetch:"M6,17c-0.6,0-1-0.4-1-1s0.4-1,1-1c10.9,0,11-5,11-5c0-0.6,0.4-1,1-1s1,0.4,1,1C19,10.3,18.9,17,6,17C6,17,6,17,6,17z M18,23c-0.5,0-1-0.4-1-1c0-0.2-0.3-5-11-5c-0.6,0-1-0.5-1-1s0.4-1,1-1c0,0,0,0,0,0c12.9,0,13,6.7,13,7 C19,22.6,18.6,23,18,23z",IndentedArrow:"M17,10c0,0-4.5,5.5,0,12L5,16L17,10z",OutdentedArrow:"M14.6,10c0,0,5.4,6,0,12L5,16L14.6,10z",DoubleArrow:"M19,10 L19,22 L13,16Z M12,10 L12,22 L6,16Z",Arrow:"M15,10 L15,22 L5,16Z",Diamond:"M12,23l-7-7l7-7l6.9,7L12,23z",Circle:"M0,50 A50,50,0 1 1 100,50 A50,50,0 1 1 0,50 Z"},vre={Square:"M0,0 L10,0 L10,10 L0,10 z",Rhombus:"M10,5 L5,10 L0,5 L5,0 L10,5 Z ",Rectangle:"M0,0 L15,0 L15,10 L0,10 z ",OpenArrow:"M15.9,23 L5,16 L15.9,9 L17,10.7 L8.7,16 L17,21.3Z",Fletch:"M9.82,0 C9.82,0,6.61,5,10,10 C10,10,7.71,5,0,5 C0,5,6.61,5,9.82,0 Z ",OpenFetch:"M0.71,5.71 C0.29,5.71,0,5.43,0,5 C0,4.57,0.29,4.29,0.71,4.29 C8.5,4.29,8.57,0.71,8.57,0.71 C8.57,0.29,8.86,0,9.29,0 C9.719999999999999,0,10,0.29,10,0.71 C10,0.93,9.93,5.71,0.71,5.71 C0.71,5.71,0.71,5.71,0.71,5.71 Z M9.29,10 C8.93,10,8.57,9.71,8.57,9.29 C8.57,9.14,8.36,5.71,0.71,5.71 C0.29,5.71,0,5.36,0,5 C0,4.64,0.29,4.29,0.71,4.29 C0.71,4.29,0.71,4.29,0.71,4.29 C9.93,4.29,10,9.07,10,9.29 C10,9.71,9.71,10,9.29,10 Z ",IndentedArrow:"M10,0 C10,0,6.25,4.58,10,10 L0,5 L10,0 Z ",OutdentedArrow:"M8,0 C8,0,12.5,5,8,10 L0,5 L8,0 Z ",DoubleArrow:"M19,10 L19,22 L13,16Z M12,10 L12,22 L6,16Z",Arrow:"M15,10 L15,22 L5,16Z",Diamond:"M10,5 L5,10 L0,5 L5,0 L10,5 Z ",Circle:"M10,5 C10,7.76,7.76,10,5,10 C2.24,10,0,7.76,0,5 C0,2.24,2.24,0,5,0 C7.76,0,10,2.24,10,5 Z ",Ellipse:"M15,5 C15,7.76,11.64,10,7.5,10 C3.36,10,0,7.76,0,5 C0,2.24,3.36,0,7.5,0 C11.64,0,15,2.24,15,5 Z "},mre={Square:"M0,0 L10,0 L10,10 L0,10 z",Rhombus:"M10,5 L5,10 L0,5 L5,0 L10,5 Z ",Rectangle:"M0,0 L15,0 L15,10 L0,10 z",OpenArrow:"M23,15.9 L16,5 L9,15.9 L10.7,17 L16,8.7 L21,17.3Z",Fletch:"M9.82,0 C9.82,0,6.61,5,10,10 C10,10,7.71,5,0,5 C0,5,6.61,5,9.82,0 Z ",OpenFetch:"M0.71,5.71 C0.29,5.71,0,5.43,0,5 C0,4.57,0.29,4.29,0.71,4.29 C8.5,4.29,8.57,0.71,8.57,0.71 C8.57,0.29,8.86,0,9.29,0 C9.719999999999999,0,10,0.29,10,0.71 C10,0.93,9.93,5.71,0.71,5.71 C0.71,5.71,0.71,5.71,0.71,5.71 Z M9.29,10 C8.93,10,8.57,9.71,8.57,9.29 C8.57,9.14,8.36,5.71,0.71,5.71 C0.29,5.71,0,5.36,0,5 C0,4.64,0.29,4.29,0.71,4.29 C0.71,4.29,0.71,4.29,0.71,4.29 C9.93,4.29,10,9.07,10,9.29 C10,9.71,9.71,10,9.29,10 Z ",IndentedArrow:"M10,0 C10,0,6.25,4.58,10,10 L0,5 L10,0 Z ",OutdentedArrow:"M8,0 C8,0,12.5,5,8,10 L0,5 L8,0 Z ",DoubleArrow:"M10,19 L22,19 L16,13Z M10,12 L22,12 L16,6Z",Arrow:"M10,15 L22,15 L16,5Z",Diamond:"M10,5 L5,10 L0,5 L5,0 L10,5 Z ",Circle:"M10,5 C10,7.76,7.76,10,5,10 C2.24,10,0,7.76,0,5 C0,2.24,2.24,0,5,0 C7.76,0,10,2.24,10,5 Z ",Ellipse:"M15,5 C15,7.76,11.64,10,7.5,10 C3.36,10,0,7.76,0,5 C0,2.24,3.36,0,7.5,0 C11.64,0,15,2.24,15,5 Z "};function Lx(n){return yre[n.toString()]}var yre={Process:"M419.511,76.687L359.511,76.687L359.511,43.086L419.511,43.086z",Decision:"M 253.005,115.687L 200.567,146.071L 148.097,115.687L 200.534,85.304L 253.005,115.687 Z",Document:"M 60 31.9 c 0 0 -11 -7.7 -30 0 s -30 0 -30 0 V 0 h 60 V 31.9 Z",PreDefinedProcess:"M 0,0 L 50,0 L 50,50 L 0,50 Z M 8.334,0 L 8.334,50 M 41.667,0 L 41.667,50",Terminator:"M 269.711,29.33C 269.71,44.061 257.77,56 243.04,56L 158.058,56C 143.33,56 131.39,44.061 131.39,29.33L 131.39,29.33C 131.391,14.6057 143.33,2.669 158.058,2.669L 243.044,2.669C 257.772,2.669 269.711,14.6057 269.711,29.333 Z",PaperTap:"M0.0009,17.2042 L0.0009,47.165 C0.001,47.165 14.403,53.5455 25.00,47.165 C35.599,40.7852 44.403,43.5087 50.00,47.165L50.001,17.2042 M50.001,32.7987 L50.001,2.8405 C50.001,2.8405 35.599,-3.5427 25.001,2.8405C14.403,9.2237 5.599,6.494 0.0009,2.8405 L0.0009,32.7987",DirectData:"M 132.62 0 L 17.38 0 C 7.78 0 0 13.43 0 30 C 0 46.57 7.78 60 17.38 60 L 132.62 60 M 132.62 0C 123.02 0 115.24 13.43 115.24 30 C 115.24 46.57 123.02 60 132.62 60 C 142.22 60 150 46.57 150 30 C 150 13.43 142.22 0 132.62 0 z ",SequentialData:"M0.0029,24.999 C0.0029,11.1922 10.433,0.0021 23.295,0.0021 C36.159,0.00216 46.585,11.1922 46.585,24.999C46.585,38.8057 36.159,49.9979 23.295,49.9979 C10.433,49.9979 0.0029,38.8057 0.0029,24.999 z M23.294,49.999 L50.002,49.999",Sort:"M50.001,24.9971 L25.001,49.9971 L0.00097,24.9971 L25.001,-0.00286865 L50.001,24.9971 z M0.000976562,24.9971 L50.001,24.9971",MultiDocument:"M43.6826,40 C44.8746,40.6183 45.8586,41.3502 46.8366,42.1122 L46.8366,4.74487 L3.09857,4.74487 L3.09857,10.9544 M46.837,35.143 C48.027,35.765 49.025,36.604 50.003,37.369 L50.003,0.002 L6.264,0.002 L6.264,4.744 M43.682,47.113 L43.682,10.765 L0.0025,10.7652 L0.0025,47.1132 C0.0025,47.1132 12.5846,53.6101 21.8426,47.1132 C31.1006,40.6163 38.792,43.393 43.6826,47.1132 z",Collate:"M50.001,0.0028 L25.001,25.0029 L0.00097,0.0028 L50.001,0.002 z M0.0009,50.002 L25.001,25.002L50.001,50.002 L0.0009,50.0029 z",SummingJunction:"M7.3252,42.6768 L42.6772,7.3247 M42.6768,42.6768 L7.3248,7.3247 M0.0009,25.001 C0.0009,11.193 11.197,0.0009 25.001,0.0009 C38.809,0.0009 50.001,11.193 50.001,25.001 C50.001,38.809 38.809,50.001 25.001,50.001 C11.197,50.00 0.0009,38.809 0.0009,25.00 z",Or:"M 0 50 L 100 50 M 50 100 L 50 0.0 M 0 50 C 0 22.384 22.392 0 50 0 C 77.616 0 100 22.384 100 50 C 100 77.616 77.616 100 50 100 C 22.392 100 0 77.616 0 50 Z",InternalStorage:"M 0 3.81946A 2.5,3.81946 0 0,1 2.5,0L 47.5 0A 2.5,3.81946 0 0,1 50,3.81946L 50 45.836A 2.5,3.819446 0 0,1 47.5,49.652778L 2.5 49.652778A 2.5,3.819446 0 0,1 0,45.8336L 0 3.819446ZM 0 11.45834L 50 11.4583334M 12.5 0L 12.5 49.652778",Extract:"M0,35 L30,0 L60,35 Z",ManualOperation:"M46.4,28.8 L14.8,28.8 L0,0 L60,0 Z",Merge:"M60,0 L30,35 L0,0 Z",OffPageReference:"M60,33.3 L30.1,39 L0,33.3 L0,0 L60,0 Z",SequentialAccessStorage:"M 60 30 C 60 13.4 46.6 0 30 0 S 0 13.4 0 30 s 13.4 30 30 30 h 28.6 v -6.5 h -9.9C 55.5 48 60 39.5 60 30 Z",Annotation:"M49.9984,50.0029 L-0.00271199,50.0029 L-0.00271199,0.00286865 L49.9984,0.00286865",Annotation2:"M49.9977,50.0029 L25.416,50.0029 L25.416,0.00286865 L49.9977,0.00286865 M25.4166,25.0029 L-0.00227869,25.0029",Data:"M 10 0 L 40 0 L 30 40 L 0 40 Z",Card:"M275,60 L400,60 L400,110 L260,110 L260,75 Z",Delay:"M0,0 L12.029,0 C14.212999,0 16,1.7869979 16,3.9709952 C16,6.1549926 14.212999,7.9409904 12.029,7.9409904 L0,7.9409904 z",Preparation:"M 1048.17 572 C 1051.06 568.86 1055.17 567.05 1059.5 567 L 1094.51 567 C 1098.84 567.05 1102.95 568.86 1105.84 572 L 1126.43 595 C 1127.01 596.28 1127.01 597.72 1126.43 599 L 1105.84 622 C 1102.95 625.14 1098.84 626.95 1094.51 627 L 1059.5 627 C 1055.17 626.95 1051.06 625.14 1048.17 622 L 1027.58 599 C 1027 597.72 1027 596.28 1027.58 595 L 1048.17 572 Z",Display:"M47.8809,19.2914 L32.7968,-0.00594145 L11.3902,-0.00594145 C7.93166,-0.00594145 0.00124586,11.187 0.00124586,24.9968C0.00124586,38.8032 7.93166,49.9962 11.3902,49.9962 L32.7968,49.99 L47.615,31.038 C47.615,31.0388 52.798,24.9968 47.880,19.2914 z",ManualInput:"M 912 732 L 1006.85 707 C 1008.2 707 1009.5 707.53 1010.46 708.46 C 1011.41 709.4 1011.95 710.67 1011.95 712 L 1011.95 762C 1012 764.41 1010.28 766.52 1007.87 767 L 917.1 767 C 915.75 767 914.45 766.47 913.49 765.54 C 912.54 764.6 912 763.33 912 762 L 912 732 Z",LoopLimit:"M 8 9 L 27 9 L 33 15 L 33 26 C 33 27 33 27 32 27 L 4 27 C 3 27 2 27 2 26 L 2 15 L 8 9 Z",StoredData:"M 5.55 0L 50 0A 1.5,30 0 0,1 50,0A 5.555,25 0 0,0 50,50A 1.5,30 0 0,1 50,50L 5.555 50A 5.55,25 0 0,1 5.555,0Z"};function d3(n,t,e){var i;i="Straight"!==n.type&&n.sourceWrapper?n.sourceWrapper.corners.center:function Sre(n){var t;if(n.sourcePortWrapper){var e=n.sourcePortWrapper;t={x:e.offsetX,y:e.offsetY}}else t=n.sourceID&&n.sourceWrapper&&n.targetWrapper?qa(n,0,n.sourceWrapper.corners.center,n.targetWrapper.corners.center,!1):n.sourcePoint;return t}(n);var r=function bre(n,t,e,i,r){var b,M,s=n.sourceWrapper,o=n.targetWrapper,a=n.sourcePortWrapper,l=n.targetPortWrapper,d=[],p=Xa(n),y={corners:undefined,point:t,direction:undefined,margin:{left:5,right:5,bottom:5,top:5}},S={corners:undefined,point:e,direction:undefined,margin:{left:5,right:5,bottom:5,top:5}};if(void 0!==s&&void 0!==o&&(b=xn(s),M=xn(o),y.corners=s.corners,S.corners=o.corners),void 0!==a&&(y.direction="Left"===a.connectionDirection||"Top"===a.connectionDirection||"Bottom"===a.connectionDirection||"Right"===a.connectionDirection?a.connectionDirection:zo({x:a.offsetX,y:a.offsetY},b,s.bounds)),void 0!==l&&(S.direction="Left"===l.connectionDirection||"Right"===l.connectionDirection||"Bottom"===l.connectionDirection||"Top"===l.connectionDirection?l.connectionDirection:zo({x:l.offsetX,y:l.offsetY},M,o.bounds)),"Bezier"===n.type&&!n.isBezierEditing&&n.segments.length>0)for(var D=n.segments.length-1;D>=0;)n.segments[parseInt(D.toString(),10)].isInternalSegment&&n.segments.pop(),D--;if(void 0!==s&&void 0!==o)return(void 0===y.direction||void 0===S.direction)&&(i?function Ire(n,t,e){"LeftToRight"===e?(n.direction=n.direction?n.direction:"Right",t.direction=t.direction?t.direction:"Left"):"RightToLeft"===e?(n.direction=n.direction?n.direction:"Left",t.direction=t.direction?t.direction:"Right"):"TopToBottom"===e?(n.direction=n.direction?n.direction:"Bottom",t.direction=t.direction?t.direction:"Top"):"BottomToTop"===e&&(n.direction=n.direction?n.direction:"Top",t.direction=t.direction?t.direction:"Bottom")}(y,S,i):y.corners.top>S.corners.bottom&&Math.abs(y.corners.top-S.corners.bottom)>p?(y.direction=y.direction?y.direction:"Top",S.direction=S.direction?S.direction:"Bottom"):y.corners.bottomp?(y.direction=y.direction?y.direction:"Bottom",S.direction=S.direction?S.direction:"Top"):y.corners.rightp||y.corners.right+p=y.corners.left-p&&y.corners.left>S.corners.left?(y.direction=y.direction?y.direction:"Right",S.direction=S.direction?S.direction:"Left"):y.corners.left>S.corners.right&&Math.abs(y.corners.left-S.corners.right)>y.margin.left+y.margin.right||S.corners.right+p=S.corners.left-p&&y.corners.left0&&n.segments[0].direction&&(y.direction=n.segments[0].direction),y.point=Ol(b,y.direction),d=Ol(b,_n(y.direction)),y.point=qa(n,0,y.point,d,!1)):y.point=o.corners.center;if(void 0!==h){switch(S.point={x:h.offsetX,y:h.offsetY},S.direction){case"Bottom":case"Top":S.point.y=S.point.y;break;case"Left":case"Right":S.point.x=S.point.x}n.targetPadding&&!w&&(S.point=TI(n,y,S,!0))}else"Orthogonal"===n.type||"Bezier"===n.type?(S.point=Ol(M,S.direction),d=Ol(M,_n(S.direction)),S.point=qa(n,0,S.point,d,!0)):S.point=a.corners.center;if("Orthogonal"!==n.type){var C=void 0,D=void 0;if("Bezier"===n.type){if(n.bezierSettings.allowSegmentsReset||0===n.segments.length||!R.isEmptyPoint(n.segments[n.segments.length-1].point))return c=b3(n,y,S,void 0,s),Nx(n,y,S);Uv(n)}else Uv(n);if(void 0===n.sourcePortWrapper){y.point=y.corners.center,n.segments&&n.segments.length>0&&(C=R.isEmptyPoint((D=n.segments[0]).point)?void 0:D);var A=void 0!==C?C.point:S.point;if("Bezier"===n.type&&n.segments.length>0&&n.segments[0].vector1.angle&&n.segments[0].vector1.distance){var x=Math.max(y.corners.width,y.corners.height);A=R.transform(y.point,n.segments[0].vector1.angle,x/2)}y.point=w?n.sourceWrapper.bounds.center:qa(n,0,y.point,A,!1)}if(void 0===n.targetPortWrapper){S.point=S.corners.center,n.segments&&n.segments.length>1&&(C=R.isEmptyPoint((D=n.segments[n.segments.length-2]).point)?void 0:D);var P=C?C.point:y.point;"Bezier"===n.type&&n.segments.length>0&&n.segments[n.segments.length-1].vector2.angle&&n.segments[n.segments.length-1].vector2.distance&&(x=Math.max(y.corners.width,y.corners.height),P=R.transform(S.point,n.segments[0].vector2.angle,x/2)),S.point=w?n.targetWrapper.bounds.center:qa(n,0,P,S.point,!0)}c=Nx(n,y,S)}else"Orthogonal"===n.type&&n.segments&&n.segments.length>0&&null!==n.segments[0].direction?c=function Nre(n,t,e,i,r,s,o){var a,h,c,d;Uv(n);for(var u=0;u0&&n.segments[u-1].direction===h.direction?u=y3(n,u,t):h.direction?t.point=u3(t,n.segments[parseInt(u.toString(),10)]):(f=n.segments[u-1])&&f.points&&f.points.length>0&&(t.point=f.points[f.points.length-1]),u===n.segments.length-1)if(S3(n,t),v3(a=void 0===r?Lre(n,t,e):p3(n,t,e),n),h.points=[],a.length>=2)for(c=0;c2&&n.segments.length>2){var p={x:a[parseInt(c.toString(),10)].x,y:t.point.y};h.points=[],h.points.push(p),h.points.push(a[parseInt(c.toString(),10)]);var f=n.segments[u-1];n.segments.length<4&&f.points.pop(),f.points=f.points.concat(h.points)}else h.points.push(a[parseInt(c.toString(),10)]);else h.points.push(a[parseInt(c.toString(),10)]);else d=u;if(void 0!==d&&!n.selectedSegmentIndex&&(d===n.segments.length-1&&(n.segments[d-1].direction=null,n.segments[d-1].length=null),n.segments.splice(d,1)),i&&0===u){var g=g3(n,i,s);g&&(t.point=g)}}return I3(n,[])}(n,y,S,l,h,o):(n.segments[0]||(C=new wi(n,"segments",{type:"Orthogonal"},!0),n.segments.push(C)),n.segments[0].points=c=b3(n,y,S,void 0,s));return c}(n,y.direction,S.direction,y.point,S.point,r);if(Uv(n),(n.sourceWrapper||n.targetWrapper)&&function Dre(n,t,e){var i=n.sourcePortWrapper,r=n.targetPortWrapper,s=n.sourceWrapper,o=t.point,a={left:0,right:0,top:0,bottom:0},l={x:0,y:0},c="Top";if(s?(o=e.point,a=t.margin):(s=n.targetWrapper,a=e.margin),"Orthogonal"===n.type)if(n.segments&&n.segments.length>0&&n.sourceWrapper&&n.segments[0].direction)t.direction=n.segments[0].direction,l=qa(n,0,l=Ol(s.corners,t.direction),Ol(s.corners,_n(t.direction)),!1);else{var u={corners:null,direction:null,point:null,margin:null};jv(s,{corners:null,direction:null,point:o,margin:a},u,n),l=u.point,c=u.direction}else{var f=void 0;n.segments&&n.segments.length>1&&(f=s===n.sourceWrapper?n.segments[0].point:n.segments[n.segments.length-2].point),l=qa(n,0,s.bounds.center,n.segments&&n.segments.length>1?f:o,s===n.targetWrapper)}s===n.sourceWrapper?(t.direction=t.direction||c,t.point=l,n.sourcePortWrapper&&(t.point={x:i.offsetX,y:i.offsetY},n.sourcePadding&&(t.point=TI(n,t,e,!1)))):(e.direction=e.direction||c,e.point=l,n.targetPortWrapper&&(e.point={x:r.offsetX,y:r.offsetY},n.targetPadding&&(e.point=TI(n,t,e,!0))))}(n,y,S),"Straight"===n.type||"Bezier"===n.type)d=Nx(n,y,S);else if("Orthogonal"===n.type&&n.segments&&n.segments.length>0&&null!==n.segments[0].length&&null!==n.segments[0].direction)d=function Ere(n,t,e,i,r,s,o){var a,l,c,u,h=[];if(Uv(n),n.segments.length>0){for(var f=0;f0&&n.segments[f-1].direction===p.direction)f=y3(n,f,t);else{var g=n.segments[f-1];t.point=p.direction?u3(t,p):g.points[g.points.length-1]}if(f===n.segments.length-1&&(o||r?n.targetWrapper&&void 0===n.targetPortWrapper?(S3(n,t),l=wre(n,t,e)):l=p3(n,t,e):l=Mre(n,t,e),l))if(v3(l,n),p.points=[],l.length>=2)for(a=0;at.corners.top&&e.point.ye.point.x?"Left":"Right"):e.point.x>t.corners.left&&e.point.xe.point.y?"Top":"Bottom")),n.sourcePortWrapper&&s===_n(r)?(("Left"===s||"Right"===s)&&t.point.y>=t.corners.top&&t.point.y<=t.corners.center.y&&e.point.y>=t.corners.top&&e.point.y<=t.corners.center.y?(t.direction="Top",a=t.point.y-t.corners.top+20):("Left"===s||"Right"===s)&&t.point.y>t.corners.center.y&&t.point.y<=t.corners.bottom&&e.point.y>t.corners.center.y&&e.point.y<=t.corners.bottom?(t.direction="Bottom",a=t.corners.bottom-t.point.y+20):("Top"===s||"Bottom"===s)&&t.point.x>=t.corners.left&&t.point.x<=t.corners.center.x&&e.point.x>=t.corners.left&&e.point.x<=t.corners.center.x?(t.direction="Left",a=t.point.x-t.corners.left+20):("Top"===s||"Bottom"===s)&&t.point.x<=t.corners.right&&t.point.x>t.corners.center.x&&e.point.x<=t.corners.right&&e.point.xt.point.y&&t.point.y>=e.corners.top?(i="Top",r=t.point.y-e.corners.top+20):e.corners.center.y===t.point.y&&"Top"===n.segments[n.segments.length-2].direction||e.corners.center.ye.point.y?t.point.y-t.corners.top+20:t.corners.bottom-t.point.y+20):(i="Top",r=e.corners.height/2+20):e.corners.center.x!==t.point.x||e.corners.topt.point.x&&t.point.x>=e.corners.left?(i="Left",r=t.point.x-e.corners.left+20):e.corners.center.x===t.point.x&&"Left"===n.segments[n.segments.length-2].direction||e.corners.center.x<=t.point.x&&t.point.x<=e.corners.right?(i="Right",r=e.corners.right-t.point.x+20):void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&t.corners.left<=t.point.x&&t.point.x<=t.corners.right&&(i=t.direction,r=t.point.x>e.point.x?t.point.x-t.corners.left+20:t.corners.right-t.point.x+20):(i="Left",r=e.corners.width/2+20);var a=t.point;t.point=Fn(t.point,"Left"===i||"Top"===i?-r:r,"Left"===i||"Right"===i?0:90),t.direction=R.direction(t.point,e.point),void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&(t.corners.center.x===e.corners.center.x||t.corners.center.y===e.corners.center.y)&&(t.direction=e.direction);var l=Ys(n,t,e);return l.splice(0,0,a),l}function p3(n,t,e){var i,r;e.corners=n.targetWrapper.corners,void 0!==n.sourcePortWrapper&&(r=zo({x:n.sourcePortWrapper.offsetX,y:n.sourcePortWrapper.offsetY},xn(n.sourceWrapper),n.sourceWrapper.bounds));var a=function Cre(n,t,e,i){var r=!1;switch(e.direction){case"Left":void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&"Right"===i&&t.point.x>e.point.x&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom||("Bottom"===i&&t.point.y>e.point.y||"Top"===i&&t.point.y=t.corners.left&&t.point.x<=t.corners.right?(t.direction="Right"===i?t.point.y>e.point.y?"Top":"Bottom":t.point.xe.point.x&&(t.point.y>e.point.y||t.point.yt.point.y&&e.corners.bottome.point.y||t.point.x>e.point.x&&t.point.y<=e.point.y&&e.corners.top=t.point.y?t.direction="Top":t.point.xe.point.x&&t.point.y>e.point.y&&e.corners.bottomt.point.y?t.direction="Bottom":t.point.y===e.point.y&&t.point.xe.point.y||"Top"===i&&t.point.ye.point.x&&t.point.x>=t.corners.left&&t.point.x<=t.corners.right?(t.direction=t.point.x>e.point.x?"Left":"Right",r=!0):void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&"Left"===i&&t.point.x=t.corners.top&&t.point.y<=t.corners.bottom?(t.direction=t.point.y>e.point.y?"Top":"Bottom",r=!0):t.point.x=t.point.y&&t.point.y===e.point.y||t.point.y>e.point.y&&t.point.x>e.point.x?t.direction="Top":t.point.ye.point.x?t.direction="Bottom":t.point.xe.point.y||t.point.ye.point.x&&(t.direction="Left");break;case"Top":void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&"Bottom"===i&&t.point.y>e.point.y&&t.point.x>=t.corners.left&&t.point.x<=t.corners.right||("Right"===i&&t.point.x>e.point.x||"Left"===i&&e.point.y>t.point.y&&e.point.x>t.point.x)&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom?(t.direction="Bottom"===i?t.point.x>e.point.x?"Left":"Right":t.point.ye.point.y&&t.point.x>e.corners.left&&t.point.x=e.point.y?t.direction="Top":t.point.ye.point.x?t.direction="Left":t.point.yt.point.x)&&t.point.y>e.point.y&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom||"Top"===i&&t.point.y=t.corners.left&&t.point.x<=t.corners.right)?(t.direction="Right"===i||"Left"===i?t.point.y>e.point.y?"Top":"Bottom":t.point.x>e.point.x?"Left":"Right",r=!0):t.point.ye.corners.left&&e.corners.right>t.point.x?t.point.ye.corners.left&&e.corners.center.x>=t.point.x?t.direction="Left":t.point.ye.point.y&&t.point.x>e.point.x?t.direction="Left":t.point.y>e.point.y&&t.point.xe.point.x||e.point.x>t.point.x)&&(t.direction="Bottom")}return r}(n,t,e,r);return!n.selectedSegmentIndex&&void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&e.direction===_n(r)&&(("Left"===e.direction&&t.point.x>e.point.x||"Right"===e.direction&&t.point.x=t.corners.top&&t.point.y<=t.corners.bottom||"Bottom"===e.direction&&t.point.y=t.corners.left&&t.point.x<=t.corners.right)?i=f3(n,t,e):n.selectedSegmentIndex||t.direction!==e.direction?!n.selectedSegmentIndex&&("Left"===e.direction&&t.point.x>e.point.x||"Right"===e.direction&&t.point.x=t.point.y||"Top"===e.direction&&t.point.y>e.point.y||"Bottom"===e.direction&&t.point.y=t.point.x?i=n.selectedSegmentIndex?kl(t,e):f3(n,t,e):!n.selectedSegmentIndex&&void 0!==n.sourceWrapper&&void 0!==n.targetWrapper&&void 0!==n.targetPortWrapper&&("Left"===t.direction||"Right"===t.direction)&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom&&("Top"===e.direction||"Bottom"===e.direction)&&e.corners.center.x===t.corners.center.x?(t.direction="Top"===e.direction?"Bottom":"Top",i=Ys(n,t,e,"Top"===e.direction?t.corners.bottom-t.point.y+20:t.point.y-t.corners.top+20)):!n.selectedSegmentIndex&&void 0!==n.sourceWrapper&&void 0!==n.targetWrapper&&void 0!==n.targetPortWrapper&&("Top"===t.direction||"Bottom"===t.direction)&&t.point.x>=t.corners.left&&t.point.x<=t.corners.right&&("Left"===e.direction||"Right"===e.direction)&&e.corners.center.y===t.corners.center.y?(t.direction="Left"===e.direction?"Right":"Left",i=Ys(n,t,e,"Left"===e.direction?t.corners.right-t.point.x+20:t.point.x-t.corners.left+20)):i=a?Ys(n,t,e,"Left"===t.direction||"Right"===t.direction?"Left"===t.direction?t.point.x-t.corners.left+20:t.corners.right-t.point.x+20:"Top"===t.direction?t.point.y-t.corners.top+20:t.corners.bottom-t.point.y+20):kl(t,e):i=Ys(n,t,e),i}function g3(n,t,e){var r,i={x:t.offsetX,y:t.offsetY},s=xn(e),o=zo(i,s,e.bounds),a=n.segments[0];return a.direction!==o&&(function Ore(n,t,e,i,r,s){var a,h,o=13,l=[];l.push(i),i.y===r.y&&("Left"===t&&r.xi.x)||i.x===r.x&&("Top"===t&&r.yi.y)||("Top"===t||"Bottom"===t?"Top"===t&&r.yi.y-o||"Bottom"===t&&r.y>i.y&&r.yo&&("Top"===t&&r.yi.y)?l.push({x:i.x,y:r.y}):(a=r.xi.x-o||"right"===t&&r.x>i.x&&r.xo&&("Left"===t&&r.xi.x)?l.push({x:r.x,y:i.y}):(l.push({x:a="Left"===t?e.left-o:e.right+o,y:i.y}),l.push({x:a,y:r.y})),s&&(l.push(n.points[0]),l.reverse()),n.points=l)}(a,o,s,a.points[0],a.points[a.points.length-1],!1),r=a.points[a.points.length-1],a.direction=R.direction(a.points[a.points.length-2],a.points[a.points.length-1])),r}function v3(n,t,e){var s,i=t.segments[t.segments.length-2],r=i.points[i.points.length-1];(("Top"===i.direction||"Bottom"===i.direction)&&r.x===n[1].x||("Left"===i.direction||"Right"===i.direction)&&r.y===n[1].y)&&(i.points[i.points.length-1]=n[1],s=R.direction(i.points[0],i.points[i.points.length-1]),void 0!==t.sourceWrapper&&void 0===t.sourcePortWrapper&&s===_n(i.direction)&&("Left"===i.direction||"Right"===i.direction?i.points[0].x="Right"===i.direction?i.points[0].x-t.sourceWrapper.corners.width:i.points[0].x+t.sourceWrapper.corners.width:i.points[0].y="Bottom"===i.direction?i.points[0].y-t.sourceWrapper.corners.height:i.points[0].y+t.sourceWrapper.corners.height),i.direction=s,i.length=R.distancePoints(i.points[0],i.points[i.points.length-1]),n.splice(0,1))}function TI(n,t,e,i){var o=i?n.targetPadding:n.sourcePadding,a=i?n.targetPortWrapper:n.sourcePortWrapper,l=new Ne(a.bounds.x-o,a.bounds.y-o,a.actualSize.width+2*o,a.actualSize.height+2*o),h=[l.topLeft,l.topRight,l.bottomRight,l.bottomLeft];h[h.length]=h[0];var d=i?e.point:t.point;return kx({x1:t.point.x,y1:t.point.y,x2:e.point.x,y2:e.point.y},h,0,d)||d}function m3(n,t){var e=[],i=mF(0,n.corners,t);i.push(i[0]);for(var r=0;r0){var r=void 0,s=[],o=t.point;for(r=0;r1&&R.equals(a.points[0],a.points[1])&&n.segments.splice(r,1),a)for(var l=0;l0||0===r)&&i.push(a.points[parseInt(l.toString(),10)])}}return i}function Ox(n,t,e){return"Top"===n||"Bottom"===n?e.x>t.x?"Right":"Left":e.y>t.y?"Bottom":"Top"}function Uv(n){if("Straight"===n.type||"Bezier"===n.type){if(0===n.segments.length||n.segments.length>0&&!R.isEmptyPoint(n.segments[n.segments.length-1].point))if("Bezier"===n.type){var t=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0},!0);n.segments.push(t)}else t=new Bl(n,"segments",{type:"Straight"},!0),n.segments.push(t)}else{if(n.segments.length>0)for(var e=!1,i=0;i=t.corners.left&&e.point.x<=t.corners.right&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom)t.direction=e.point.y>t.point.y?"Bottom":"Top",i=Ys(n,t,e,"Top"===t.direction?t.point.y-t.corners.top+20:t.corners.bottom-t.point.y+20);else if(n.sourcePortWrapper&&r===_n(o)){var h;("Left"===r||"Right"===r)&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom?(t.direction=e.point.y>t.point.y?"Bottom":"Top",h=t.corners.height/2+20):("Top"===r||"Bottom"===r)&&t.point.x>=t.corners.left&&t.point.x<=t.corners.right&&(t.direction=e.point.x>t.point.x?"Right":"Left",h=t.corners.width/2+20),t.direction&&h?i=Ys(n,t,e,h,!0):(t.direction=o,i=kl(t,e))}else if(!n.sourcePortWrapper||r!==e.direction||"Top"!==r&&"Bottom"!==r||t.corners.center.x!==e.corners.center.x)if(t.direction===e.direction)if(("Left"===t.direction||"Right"===t.direction)&&e.point.y>t.corners.top-20&&e.point.yt.corners.left-20&&e.point.xt.point.y?"Bottom":"Top",i=Ys(n,t,e,"Bottom"===t.direction?t.corners.bottom-t.point.y+20:t.point.y-t.corners.top+20);else t.direction=o,i=Ys(n,t,e,"Top"===o||"Bottom"===o?n.sourceWrapper.height/2+20:n.sourceWrapper.width/2+20),t.point=i[1],"Left"===o||"Right"===o?(e.direction=o,e.point="Left"===o?e.corners.middleLeft:e.corners.middleRight):jv(n.targetWrapper,t,e,n),i=Ys(n,t,e);return i}function S3(n,t){if(void 0!==n.targetWrapper&&void 0===n.targetPortWrapper&&xn(n.targetWrapper).containsPoint(t.point,1)){var i=n.targetWrapper,r=n.segments[n.segments.length-2],s=r.points[r.points.length-1],o=_n(r.direction);"Bottom"===o?s.yi.corners.top-1&&(r.points[r.points.length-1].y=i.corners.top-20,r.length=R.distancePoints(r.points[0],r.points[r.points.length-1])):"Left"===o?s.x>i.corners.left-1&&(r.points[r.points.length-1].x=i.corners.left-20,r.length=R.distancePoints(r.points[0],r.points[r.points.length-1])):"Right"===o&&s.x0||0===e)&&t.push(i.points[parseInt(r.toString(),10)]);return t}function jv(n,t,e,i){var r,s={x:0,y:0},o=AI(n,n.corners,n.bounds),a=t.margin,l=t.point;if(o.bottomCenter.y+a.bottoml.y)r="Top",s=o.topCenter;else if(o.middleLeft.x-a.left>l.x)r="Left",s=o.middleLeft;else if(o.middleRight.x+a.rightc&&(f=c,r="Right",s=o.middleRight),f>d&&(f=d,r="Bottom",s=o.bottomCenter),f>u&&(r="Left",s=o.middleLeft)}e.point=s,e.direction=r;var p=Ol(o,_n(e.direction));e.point=qa(i,0,e.point,p,n===i.targetWrapper)}function b3(n,t,e,i,r){var s,o,a;if(s=function Qre(n,t){var e=!1;switch(n){case"Left":switch(t){case"Right":case"Bottom":e=!0}break;case"Top":switch(t){case"Left":case"Right":case"Bottom":e=!0}break;case"Bottom":"Right"===t&&(e=!0)}return e}(t.direction,e.direction),s&&x3(t,e),"Right"===t.direction&&"Left"===e.direction)a=function kre(n,t,e,i){var o=Math.round(Math.abs(t.point.y-e.point.y)),a={x:Math.max(t.point.x,t.corners.right),y:t.point.y},l={x:Math.min(e.point.x,e.corners.left),y:e.point.y},h=Xa(n);if(i){var c=l;l=a,a=c}return t.corners.bottom+he.corners.bottom+h||("Bezier"!==n.type||e.corners.left-t.corners.right<=2*h&&e.corners.left-t.corners.right>=5)&&(h=0),t.margin={left:h,right:h,top:h,bottom:h},e.margin={left:h,right:h,top:h,bottom:h},0===o&&(t.corners.right=e.corners.right?void 0!==i&&(i.offsetYe.corners.bottom+e.margin.bottom)||void 0===i&&t.corners.middleRight.ye.corners.bottom+e.margin.bottom&&t.corners.top>e.corners.bottom||void 0===i&&t.corners.middleRight.y>e.corners.bottom||void 0!==i&&i.offsetYe.corners.top||void 0===i&&t.corners.middleRight.y>e.corners.bottom?Ae.Three:t.corners.rightr.offsetY+e.margin.right||void 0===r&&t.corners.top>e.corners.middleRight.y||void 0!==r&&(void 0!==i&&i.offsetXr.offsetX||void 0===r&&t.corners.left>e.corners.topCenter.x?Ae.Four:Ae.Two:void 0!==s&&Math.abs(t.corners.right-e.corners.left)<=5&&Math.abs(s.offsetY-e.corners.top)<=5||void 0!==r&&t.corners.right=25&&t.corners.middleRight.y+t.margin.righte.corners.bottom+e.margin.bottom||void 0===o&&t.corners.middleRight.y>e.corners.bottom+e.margin.bottom?t.corners.top>e.corners.bottom?void 0!==a&&t.corners.right+t.margin.righta.offsetX||void 0===a&&t.corners.left>e.corners.bottomCenter.x?Ae.Four:Ae.Two:void 0!==o&&Math.abs(t.corners.right-e.corners.left)<=25&&Math.abs(o.offsetY-e.corners.bottom)<=25?Ae.Two:Ae.Four}(n,t,e,s);else if("Bottom"===t.direction&&"Top"===e.direction)a=function Hre(n,t,e){var r=t.point.x-e.point.x,s=Xa(n);return t.corners.right+se.corners.right+s||("Bezier"!==n.type||e.corners.top-t.corners.bottom<=2*s&&e.corners.top-t.corners.bottom>=5)&&(s=0),t.margin={left:s,right:s,top:s,bottom:s},e.margin={left:s,right:s,top:s,bottom:s},0===r&&t.corners.bottome.corners.right+e.margin.right||void 0===i&&t.corners.bottomCenter.x>e.corners.right+e.margin.right?Ae.Three:t.corners.bottomr.offsetX||void 0===r&&t.corners.left>e.corners.left||void 0!==r&&t.corners.right+t.margin.righte.corners.bottom?Ae.Five:0===s||0===o?Ae.One:Ae.Three}(n,t,e)}else"Bottom"===t.direction&&"Left"===e.direction?a=function Bre(n,t,e,i){var r=n.sourcePortWrapper,s=n.targetPortWrapper,o=Xa(n);if(e.margin={left:o,right:o,top:o,bottom:o},t.margin={top:o,bottom:o,left:o,right:o},i){var l=r;r=s,s=l}return void 0!==r&&r.offsetXs.offsetY||void 0===s&&t.corners.top>e.corners.middleLeft.y?Ae.Four:Ae.Two:void 0!==s&&Math.abs(t.corners.right-e.corners.left)<=25&&Math.abs(s.offsetY-t.corners.bottom)<=25?Ae.Two:Ae.Four}(n,t,e,s):"Left"===t.direction&&"Left"===e.direction?a=function Ure(n,t,e){var i=n.sourcePortWrapper,r=n.targetPortWrapper,s=Xa(n);t.margin={left:s,right:s,top:s,bottom:s},e.margin={left:s,right:s,top:s,bottom:s};var o=Math.round(Math.abs(t.point.x-e.point.x)),a=Math.round(Math.abs(t.point.y-e.point.y));return t.corners.leftr.offsetY||void 0===r&&t.corners.top-t.margin.top>e.corners.middleLeft.y?Ae.Three:t.corners.righte.corners.bottom+e.margin.bottom||void 0===i&&t.corners.middleLeft.y>e.corners.bottom+e.margin.bottom?Ae.Three:t.corners.left>e.corners.right?Ae.Five:0===o||0===a?Ae.One:Ae.Three}(n,t,e):"Left"===t.direction&&"Top"===e.direction?a=function _re(n,t,e,i){var s=n.sourcePortWrapper,o=Xa(n);e.margin={left:o,right:o,top:o,bottom:o},t.margin={top:o,bottom:o,left:o,right:o};var a=n.targetPortWrapper,l={x:Math.min(t.point.x,t.corners.left),y:t.point.y},h={x:e.point.x,y:Math.min(e.point.y,e.corners.top)};if(i){var c=s;s=a,a=c;var d=l;l=h,h=d}return void 0!==s&&s.offsetYa.offsetX||void 0===a&&t.corners.left-t.margin.left>e.corners.topCenter.x?Ae.Two:Ae.Four:void 0!==a&&t.corners.rightr.offsetX||void 0===r&&t.corners.left>e.corners.left||void 0!==r&&t.corners.right+t.margin.righte.corners.right+e.margin.right||void 0===i&&t.corners.left>e.corners.right||void 0!==i&&i.offsetXe.corners.bottom?Ae.Five:0===s||0===o?Ae.One:Ae.Three}(n,t,e));return s&&x3(t,e),o=function Vre(n,t,e,i,r,s){var l,d,h=n.sourceWrapper.corners,c=n.targetWrapper.corners,u=20,f={corners:e.corners,point:e.point,direction:e.direction,margin:e.margin},p={corners:i.corners,point:i.point,direction:i.direction,margin:i.margin};if(!(f.direction===p.direction&&t!==Ae.Five||f.direction!==_n(p.direction)&&t!==Ae.Three))switch(f.direction){case"Left":h.middleLeft.x>c.middleRight.x&&(d=(h.middleLeft.x-c.middleRight.x)/2,u=s?d:Math.min(u,d));break;case"Right":h.middleRight.xc.bottomCenter.y&&(d=(h.topCenter.y-c.bottomCenter.y)/2,u=s?d:Math.min(u,d));break;case"Bottom":h.bottomCenter.yf&&hf)&&o>c&&o<=d&&e>=20&&(s=n.point.x-t.corners.left+s),i&&n.direction===t.direction&&n.corners.left>t.corners.left&&n.corners.left-t.corners.right>=20&&(s=(n.corners.left-t.corners.right)/2),p=Fn(n.point,s,180);break;case"Top":(o>c&&oc)&&h>f&&h<=u&&e>=20&&(s=n.point.y-t.corners.top+s),i&&n.direction===t.direction&&n.corners.top>t.corners.top&&n.corners.top-t.corners.bottom>=20&&(s=(n.corners.top-t.corners.bottom)/2),p=Fn(n.point,s,270);break;case"Right":(h>f&&hf)&&a=c&&e>=20&&(s=t.corners.right-n.point.x+s),i&&n.direction===t.direction&&n.corners.right=20&&(s=(t.corners.left-n.corners.right)/2),p=Fn(n.point,s,0);break;case"Bottom":(o>c&&oc)&&l=f&&e>=20&&(s=t.corners.bottom-n.point.y+s),i&&n.direction===t.direction&&n.corners.bottom=20&&(s=(t.corners.top-n.corners.bottom)/2),p=Fn(n.point,s,90)}r=[n.point,p];var g=void 0;if("Top"===n.direction||"Bottom"===n.direction){var v=n.direction;n.direction=p.x>t.point.x?"Left":"Right",n.point=p,r=LI(n,t,v,r,g=i?.5*Math.abs(p.x-t.point.x):g,i)}else v=n.direction,n.direction=p.y>t.point.y?"Top":"Bottom",n.point=p,r=LI(n,t,v,r,g=i?.5*Math.abs(p.y-t.point.y):g,i);return r}(f,p,u,g)),l}(n,a,t,e,i,r),"Bezier"===n.type&&function Yre(n,t,e){if("Bezier"===n.type)if(0===n.segments.length){var i=e[0],r=e[e.length-1];if(t===Ae.One){var s=Math.min(20,.5*R.findLength(i,r)),o={angle:Gt(i,r),distance:s},a={angle:Gt(r,i),distance:s},l=R.direction(i,r),c=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,orientation:"Left"===l||"Right"===l?"Horizontal":"Vertical"},!0);n.segments.push(c)}else if(t===Ae.Two)o={angle:Gt(i,d=e[1]),distance:.5*R.findLength(i,d)},a={angle:Gt(r,d),distance:.5*R.findLength(r,d)},l=R.direction(i,d),c=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,orientation:"Left"===l||"Right"===l?"Horizontal":"Vertical"},!0),n.segments.push(c);else if(t===Ae.Three){var d={x:.5*((u=e[1]).x+(f=e[e.length-2]).x),y:.5*(u.y+f.y)},p=(o={angle:Gt(i,u),distance:.5*R.findLength(i,u)},a={angle:Gt(d,u),distance:.5*R.findLength(d,u)},R.direction(i,u)),v=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,point:d,orientation:"Left"===p||"Right"===p?"Horizontal":"Vertical"},!0);n.segments.push(v);var y={angle:Gt(d,f),distance:.5*R.findLength(d,f)},S={angle:Gt(r,f),distance:.5*R.findLength(r,f)},b=R.direction(d,f),w=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:y,vector2:S,orientation:"Left"===b||"Right"===b?"Horizontal":"Vertical"},!0);n.segments.push(w)}else if(t===Ae.Four){var D={x:.5*((u=e[1]).x+(f=e[2]).x),y:.5*(u.y+f.y)},A={x:.5*(f.x+(C=e[3]).x),y:.5*(f.y+C.y)};o={angle:Gt(i,u),distance:.5*R.findLength(i,u)},a={angle:Gt(D,u),distance:.5*R.findLength(D,u)},p=R.direction(i,u),v=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,point:D,orientation:"Left"===p||"Right"===p?"Horizontal":"Vertical"},!0),n.segments.push(v),y={angle:Gt(D,f),distance:.5*R.findLength(D,f)},S={angle:Gt(A,f),distance:.5*R.findLength(A,f)},b=R.direction(D,f),w=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:y,vector2:S,point:A,orientation:"Left"===b||"Right"===b?"Horizontal":"Vertical"},!0),n.segments.push(w);var x={angle:Gt(A,C),distance:.5*R.findLength(A,C)},P={angle:Gt(r,C),distance:.5*R.findLength(r,C)},L=R.direction(A,C),N=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:x,vector2:P,orientation:"Left"===L||"Right"===L?"Horizontal":"Vertical"},!0);n.segments.push(N)}else if(t===Ae.Five){var u,f,C,T=e[4],z=(D={x:.5*((u=e[1]).x+(f=e[2]).x),y:.5*(u.y+f.y)},A={x:.5*(f.x+(C=e[3]).x),y:.5*(f.y+C.y)},{x:.5*(C.x+T.x),y:.5*(C.y+T.y)});o={angle:Gt(i,u),distance:.5*R.findLength(i,u)},a={angle:Gt(D,u),distance:.5*R.findLength(D,u)},p=R.direction(i,u),v=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,point:D,orientation:"Left"===p||"Right"===p?"Horizontal":"Vertical"},!0),n.segments.push(v),y={angle:Gt(D,f),distance:.5*R.findLength(D,f)},S={angle:Gt(A,f),distance:.5*R.findLength(A,f)},b=R.direction(D,f),w=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:y,vector2:S,point:A,orientation:"Left"===b||"Right"===b?"Horizontal":"Vertical"},!0),n.segments.push(w),x={angle:Gt(A,C),distance:.5*R.findLength(A,C)},P={angle:Gt(z,C),distance:.5*R.findLength(z,C)},L=R.direction(A,C),N=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:x,vector2:P,point:z,orientation:"Left"===L||"Right"===L?"Horizontal":"Vertical"},!0),n.segments.push(N);var U={angle:Gt(z,T),distance:.5*R.findLength(z,T)},B={angle:Gt(r,T),distance:.5*R.findLength(r,T)},j=R.direction(z,T),oe=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:U,vector2:B,orientation:"Left"===j||"Right"===j?"Horizontal":"Vertical"},!0);n.segments.push(oe)}else c=new fs(n,"segments",{type:"Bezier"},!0),n.segments.push(c)}else for(var ue=0;ue=13?13:n.connectorSpacing<=1?1:n.connectorSpacing}function Gt(n,t){var i=R.findLength({x:t.x,y:n.y},t),r=R.findLength(t,n),s=Math.asin(i/r);return s=180*s/Math.PI,n.xt.y&&(s=360-s):s=n.y0)for(var l=1;lc)&&(s=c,a=h),s>=0&&s<=1)break}}return a}function w3(n,t){var c,d,u,f,p,g,S,b,M,w,D,e=n.x1,i=n.y1,r=n.x2,s=n.y2,o=t.x1,a=t.y1,l=t.x2,h=t.y2;if(w=(c=s-i)*l+(u=e-r)*h+(p=r*i-e*s),0!==(M=c*o+u*a+p)&&0!==w&&C3(M,w)||(b=(d=h-a)*r+(f=o-l)*s+(g=l*a-o*h),0!==(S=d*e+f*i+g)&&0!==b&&C3(S,b)))return null;var A=c*f-d*u;return 0===A?null:(A<0?-A/2:A/2,0,{x:(D=u*g-f*p)<0?(D-0)/A:(D+0)/A,y:(D=d*p-c*g)<0?(D-0)/A:(D+0)/A})}function C3(n,t){return n*t>=0}function E3(n,t,e){switch(t.direction){case"Left":t.point.x>n.left&&(e=t.point.x-n.left>e?t.point.x-n.left+e:e);break;case"Right":t.point.xe?n.right-t.point.x+e:e);break;case"Top":t.point.y>n.top&&(e=t.point.y-n.top>e?t.point.y-n.top+e:e);break;case"Bottom":t.point.ye?n.bottom-t.point.y+e:e)}return e}function kl(n,t){var e;switch(n.direction){case"Left":case"Right":var i={x:t.point.x,y:n.point.y};e=R.equals(n.point,i)||R.equals(t.point,i)?[n.point,t.point]:[n.point,i,t.point];break;case"Top":case"Bottom":var r={x:n.point.x,y:t.point.y};e=R.equals(n.point,r)||R.equals(t.point,r)?[n.point,t.point]:[n.point,r,t.point]}return e}function Ys(n,t,e,i,r,s){void 0===s&&(s=!1),i||(i=20),s&&t.direction!==e.direction&&(i="Left"===t.direction||"Right"===t.direction?Math.floor(.5*Math.abs(t.point.x-e.point.x)):Math.floor(.5*Math.abs(t.point.y-e.point.y)));var l,h,u,o=n.sourcePortWrapper,c=e.point.x-t.point.x,d=e.point.y-t.point.y;if(!r&&(Math.abs(c)<.001||Math.abs(d)<.001)&&void 0===e.direction)return[t.point,e.point];if(void 0===n.targetWrapper&&Math.abs(c)<=31&&Math.abs(d)<=31){if("Left"===t.direction||"Right"===t.direction?Math.abs(d)<12&&(t.direction=t.point.y>e.point.y?"Top":"Bottom"):Math.abs(c)<12&&(t.direction=t.point.x>e.point.x?"Left":"Right"),Math.abs(c)>12||Math.abs(d)>12)return kl(t,e);i+=5}return"Left"===t.direction||"Right"===t.direction?("Right"===t.direction?(void 0!==e.direction&&"Right"===e.direction&&(i=Math.max(t.point.x,e.point.x)-t.point.x+i),t.point.x>e.point.x&&void 0===o&&(i=-i)):(void 0!==e.direction&&"Left"===e.direction&&(i=t.point.x-Math.min(t.point.x,e.point.x)+i),(t.point.x>e.point.x||void 0!==o||"Left"===t.direction)&&(i=-i)),u=e.point.y-t.point.y,l=Fn(t.point,i,0),0!=(u=e.point.y-l.y)&&(h=Fn(l,e.point.y-l.y,90))):("Top"===t.direction||"Bottom"===t.direction)&&("Bottom"===t.direction?void 0!==e.direction&&"Bottom"===e.direction&&(i=Math.max(t.point.y,e.point.y)-t.point.y+i):(void 0!==e.direction&&"Top"===e.direction&&(i=t.point.y-Math.min(t.point.y,e.point.y)+i),(t.point.y>e.point.y||void 0!==o||"Top"===t.direction)&&(i=-i)),u=e.point.x-t.point.x,l=Fn(t.point,i,90),0!=(u=e.point.x-l.x)&&(h=Fn(l,e.point.x-l.x,0))),0===u?[t.point,e.point]:[t.point,l,h,e.point]}function LI(n,t,e,i,r,s){var o;switch(void 0===r&&(r=20),void 0===s&&(s=!1),void 0===e?(n.margin={left:2,right:2,top:2,bottom:2},t.margin={left:0,right:5,top:0,bottom:5},s&&(n.margin={left:10,right:10,top:10,bottom:10},t.margin={left:10,right:10,top:10,bottom:10},"Left"===n.direction?(r=zx(n,t,e,r),n.corners.left-t.corners.right>=5&&(r=Math.abs(n.point.x-n.corners.left)+.5*Math.floor(n.corners.left-t.corners.right))):"Right"===n.direction?(r=Rx(n,t,r,e),t.corners.left-n.corners.right>=5&&(r=Math.abs(n.point.x-n.corners.right)+.5*Math.floor(t.corners.left-n.corners.right))):"Top"===n.direction?(r=Px(n,t,e,r),n.corners.top-t.corners.bottom>=5&&(r=Math.abs(n.point.y-n.corners.top)+.5*Math.floor(n.corners.top-t.corners.bottom))):"Bottom"===n.direction&&(r=Hx(n,t,r,e),t.corners.top-n.corners.bottom>=5&&(r=Math.abs(n.point.y-n.corners.bottom)+.5*Math.floor(t.corners.top-n.corners.bottom))))):("Bottom"===n.direction?s?t.corners.top-n.corners.bottom<20&&(r=t.corners.bottom-n.point.y+25):t.corners.top>n.corners.bottom&&t.corners.top-n.corners.bottom<20&&(r=(t.corners.top-n.corners.bottom)/2):"Top"===n.direction?s?n.corners.top-t.corners.bottom<20&&(r=n.point.y-t.corners.top+25):t.corners.bottomn.corners.right&&t.corners.left-n.corners.right<20&&(r=(t.corners.left-n.corners.right)/2):"Left"===n.direction&&(s?n.corners.left-t.corners.right<20&&(r=n.point.x-t.corners.left+25):t.corners.rightt.point.y||"Top"===t.direction&&n.point.yt.point.x||"Left"===t.direction&&n.point.xh||e.corners.top-e.margin.top<=i.point.y&&e.corners.bottom+e.margin.bottom>=i.point.y))if(!s||"Top"!==e.direction&&"Bottom"!==e.direction)c=Math.min(Math.abs(i.corners.left-e.corners.right)/2,20),h=e.corners.right-n.x+c;else{var c=Math.abs(i.corners.left-e.corners.right)/2;h=e.corners.right-n.x+c}else h="Top"===e.direction&&n.y>i.point.y||"Bottom"===e.direction&&n.y=e.corners.left-e.margin.left&&n.x<=e.corners.right+e.margin.right?Math.min(i.corners.left,e.corners.left)-n.x-20:i.corners.left-n.x-20;break;case"Right":if(e.corners.left-e.margin.left>i.corners.right+i.margin.right&&(e.corners.left-e.margin.right-i.corners.right>h||e.corners.top-e.margin.top<=i.point.y&&e.corners.bottom+e.margin.bottom>=i.point.y))if(!s||"Top"!==e.direction&&"Bottom"!==e.direction)c=Math.min(Math.abs(e.corners.left-i.corners.right)/2,20),h=e.corners.left-n.x-c;else{c=Math.abs(e.corners.left-i.corners.right)/2;h=e.corners.left-n.x-c}else h="Top"===e.direction&&n.y>i.point.y||"Bottom"===e.direction&&n.y=e.corners.left-e.margin.left&&n.x<=e.corners.right+e.margin.right?Math.max(i.corners.right,e.corners.right)-n.x+20:i.corners.right-n.x+20}o=Fn(n,h,0),a=Fn(o,i.point.y-n.y,90),l=i.point}else if("vertical"===t){switch(i.direction){case"Top":e.corners.bottom+e.margin.bottomh||e.corners.left-e.margin.left<=i.point.x&&e.corners.right+e.margin.right>=i.point.x)?!s||"Right"!==e.direction&&"Left"!==e.direction?(c=Math.min(Math.abs(i.corners.top-e.corners.bottom)/2,20),h=e.corners.bottom-n.y+c):(c=Math.abs(i.corners.top-e.corners.bottom)/2,h=e.corners.bottom-n.y+c):h="Left"===e.direction&&n.x>i.point.x||"Right"===e.direction&&n.x=e.corners.top-e.margin.top&&n.y<=e.corners.bottom+e.margin.bottom?Math.min(i.corners.top,e.corners.top)-n.y-20:i.corners.top-n.y-20;break;case"Bottom":e.corners.top-e.margin.top>i.corners.bottom+i.margin.bottom&&(e.corners.top-e.margin.top-i.corners.bottom>h||e.corners.left-e.margin.left<=i.point.x&&e.corners.right+e.margin.right>=i.point.x)?!s||"Right"!==e.direction&&"Left"!==e.direction?(c=Math.min(Math.abs(e.corners.top-i.corners.bottom)/2,20),h=e.corners.top-n.y-c):(c=Math.abs(e.corners.top-i.corners.bottom)/2,h=e.corners.top-n.y-c):h="Left"===e.direction&&n.x>i.point.x||"Right"===e.direction&&n.x=e.corners.top-e.margin.top&&n.y<=e.corners.bottom+e.margin.bottom?Math.max(i.corners.bottom,e.corners.bottom)-n.y+20:i.corners.bottom-n.y+20}o=Fn(n,h,90),a=Fn(o,i.point.x-n.x,0),l=i.point}r.push(o),r.push(a),r.push(l)}function Px(n,t,e,i){return n.corners.top-n.margin.top>t.corners.top+t.margin.top&&n.corners.top-n.margin.top<=t.corners.bottom+t.margin.bottom?(("Right"===t.direction&&n.point.xt.point.x)&&(i+=n.corners.top-t.corners.top),i+=n.point.y-n.corners.top):i+=void 0!==e&&"Left"!==e&&"Right"===t.direction&&n.point.xt.corners.left-t.margin.left&&n.corners.left-n.margin.left<=t.corners.right+t.margin.right?(("Bottom"===t.direction&&n.point.yt.point.y)&&(i+=n.corners.left-t.corners.left),i+=n.point.x-n.corners.left):i+=void 0!==e&&"Top"!==e&&"Bottom"===t.direction&&n.point.y=t.corners.left-t.margin.left?(("Bottom"===t.direction&&n.point.yt.point.y)&&(e+=t.corners.right-n.corners.right),e+=n.corners.right-n.point.x):e+=void 0!==i&&"Top"!==i&&"Bottom"===t.direction&&n.point.y=t.corners.top-t.margin.top?(("Right"===t.direction&&n.point.xt.point.x)&&(e+=t.corners.bottom-n.corners.bottom),e+=n.corners.bottom-n.point.y):e+=void 0!==i&&"Left"!==i&&"Right"===t.direction&&n.point.xp&&d=u&&d=f&&d<=p?"Left":"Right"}function _n(n){switch(n){case"Top":return"Bottom";case"Bottom":return"Top";case"Left":return"Right";case"Right":return"Left"}return"auto"}var A3=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Ac=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},NI=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return A3(t,n),Ac([I()],t.prototype,"width",void 0),Ac([I()],t.prototype,"height",void 0),t}(Ee),Gre=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return A3(t,n),Ac([I()],t.prototype,"width",void 0),Ac([I()],t.prototype,"height",void 0),Ac([I()],t.prototype,"fit",void 0),Ac([I()],t.prototype,"description",void 0),Ac([I()],t.prototype,"template",void 0),Ac([I()],t.prototype,"tooltip",void 0),t}(Ee),Xre=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Pl=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},L3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Xre(t,n),Pl([I("")],t.prototype,"id",void 0),Pl([I(Number.MIN_VALUE)],t.prototype,"zIndex",void 0),Pl([re({},Jn)],t.prototype,"margin",void 0),Pl([I(!0)],t.prototype,"visible",void 0),Pl([re({},Td)],t.prototype,"tooltip",void 0),Pl([I(!1)],t.prototype,"excludeFromLayout",void 0),Pl([I()],t.prototype,"addInfo",void 0),Pl([I("None")],t.prototype,"flip",void 0),Pl([I("All")],t.prototype,"flipMode",void 0),Pl([re({},Gre)],t.prototype,"symbolInfo",void 0),t}(Ee),qre=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),es=function(n){function t(e,i,r,s){var o=n.call(this)||this;return o.data="",o.nodeId="",o.annotationId="",o.diagramId="",o.diagramId=i,o.nodeId=e,o.annotationId=r,o.templateFn=GF(s),o}return qre(t,n),t.prototype.getNodeTemplate=function(){return this.templateFn},Object.defineProperty(t.prototype,"content",{get:function(){return this.data},set:function(e){this.data=e,this.canReset||(this.canReset=!0,this.isTemplate||(this.template=Fh(this,!0)),this.canReset=!1,this.isDirt=!0)},enumerable:!0,configurable:!0}),t}(hs),Bx=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),cs=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},N3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Bx(t,n),cs([I("")],t.prototype,"id",void 0),cs([I("transparent")],t.prototype,"fill",void 0),cs([I("black")],t.prototype,"iconStrokeColor",void 0),cs([I(0)],t.prototype,"iconStrokeWidth",void 0),cs([I(!0)],t.prototype,"visibility",void 0),cs([I(10)],t.prototype,"width",void 0),cs([I(10)],t.prototype,"height",void 0),cs([I("transparent")],t.prototype,"handleStrokeColor",void 0),cs([I(1)],t.prototype,"handleStrokeWidth",void 0),cs([I("")],t.prototype,"pathData",void 0),cs([I(0)],t.prototype,"cornerRadius",void 0),cs([re({left:0,right:0,top:0,bottom:0},Jn)],t.prototype,"padding",void 0),cs([re({},Td)],t.prototype,"tooltip",void 0),t}(Ee),O3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Bx(t,n),cs([re({x:0,y:0},R)],t.prototype,"offset",void 0),cs([re({},Jn)],t.prototype,"margin",void 0),t}(N3),OI=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Bx(t,n),cs([I(.5)],t.prototype,"offset",void 0),cs([I("Center")],t.prototype,"alignment",void 0),cs([re({x:0,y:0},R)],t.prototype,"displacement",void 0),t}(N3);function Ad(n){return n?n instanceof Kn||n instanceof Or?n.constraints&Nr.Select:n instanceof de?n.constraints&qe.Select:n.constraints&ie.Select:1}function ro(n){return n?n instanceof Kn||n instanceof Or?n.constraints&Nr.Drag:n instanceof de?n.constraints&qe.Drag:n instanceof ei?1:n.constraints&ie.Drag:1}function $re(n,t){return n instanceof de?n.constraints&qe.PointerEvents:n.constraints&ie.PointerEvents}function kI(n){return n instanceof de?n.constraints&qe.Delete:n.constraints&ie.Delete}function PI(n){return n.constraints&qe.DragSourceEnd}function zI(n){return n.constraints&qe.DragTargetEnd}function RI(n){return n.constraints&qe.DragSegmentThumb}function HI(n){return n instanceof Kn||n instanceof Or?n.constraints&Nr.Rotate:n.constraints&ie.Rotate}function BI(n){return n.constraints&ie.Shadow}function ua(n){return n instanceof te&&n.constraints&ie.InConnect?n.constraints&ie.InConnect:0}function zh(n){return n&&n.constraints&&!(n.constraints&oi.None)&&n.constraints&oi.InConnect?n.constraints&oi.InConnect:0}function Rh(n){return n instanceof te&&n.constraints&ie.OutConnect?n.constraints&ie.OutConnect:0}function Ld(n){return n&&n.constraints&&!(n.constraints&oi.None)&&n.constraints&oi.OutConnect?n.constraints&oi.OutConnect:0}function zl(n,t){var e=0;return n instanceof Kn||n instanceof Or?e=n.constraints&Nr.Resize:n&&("SouthEast"===t?e=n.constraints&ie.ResizeSouthEast:"East"===t?e=n.constraints&ie.ResizeEast:"NorthEast"===t?e=n.constraints&ie.ResizeNorthEast:"South"===t?e=n.constraints&ie.ResizeSouth:"North"===t?e=n.constraints&ie.ResizeNorth:"SouthWest"===t?e=n.constraints&ie.ResizeSouthWest:"West"===t?e=n.constraints&ie.ResizeWest:"NorthWest"===t&&(e=n.constraints&ie.ResizeNorthWest)),e}function FI(n){return n instanceof de?n.constraints&qe.AllowDrop:n.constraints&ie.AllowDrop}function Ds(n){return n.constraints&nt.Virtualization}function Vv(n){return n.tool&ri.SingleSelect}function Wv(n){return n.tool&ri.MultipleSelect}function Lc(n){return n.tool&ri.ZoomPan}function _I(n){return n.tool&ri.ContinuousDraw}function k3(n){return n.tool&ri.DrawOnce}function UI(n){return n.tool&ri.SingleSelect||n.tool&ri.MultipleSelect}function Yv(n){return n.constraints&nt.UserInteraction}function P3(n){return n.constraints&nt.ZoomTextEdit}function Qv(n){return function ine(n){return n.constraints&nt.ApiUpdate}(n)||n.diagramActions&ee.ToolAction}function Fx(n,t){return n.constraints&oi.Draw}function _x(n,t){return n.constraints&oi.Drag}function jI(n){return!(n&Ga.DrawSelectorBorder)}function z3(n){return!!(n&Ga.PreventRenderSelector)}var Ux=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Gv=function(n){function t(){var e=null!==n&&n.apply(this,arguments)||this;return e.childTable=[],e.cellStyle={},e.desiredRowHeight=[],e.desiredCellWidth=[],e}return Ux(t,n),t.prototype.rowDefinitions=function(){return this.rowDefns},t.prototype.columnDefinitions=function(){return this.colDefns},t.prototype.addObject=function(e,i,r,s,o){if(this.rows.length>=i){var a=this.rows[parseInt(i.toString(),10)];if(a.cells.length>r){o=o||1,s=s||1;var l=a.cells[parseInt(r.toString(),10)];l.columnSpan=Math.max(o,l.columnSpan),l.rowSpan=Math.max(s,l.rowSpan);var h=new ane;(h=e).rowId=i,h.columnId=r,h.columnSpan=o,this.childTable[h.id]=h,this.addObjectToCell(h,l)}}},t.prototype.addObjectToCell=function(e,i){i.children||(i.children=[]),e.style.strokeColor="black",e.style.strokeWidth=1,i.children.push(e)},t.prototype.updateProperties=function(e,i,r,s){this.offsetX=e,this.offsetY=i,this.width=r,this.height=s},t.prototype.setDefinitions=function(e,i){this.rowDefns=e,this.colDefns=i,this.children=[],this.rows=this.rows||[];for(var r=0;r0){for(var h=0;hi&&this.updateRowHeight(e,l,!1)}},t.prototype.setTextRefresh=function(e){if(e.children&&e.children.length)for(var i=e.children,r=0;ri&&this.updateColumnWidth(e,a,!1)}},t.prototype.calculateCellWidth=function(e){for(var i,r,s,o=0;os.bounds.width&&(0===s.children.length||void 0===s.children[0].maxWidth)?s.outerBounds.width:s.bounds.width,i=i?is.bounds.height?s.outerBounds.height:s.bounds.height,i=i?i0?e.children[0]:void 0;if(a&&1===e.columnSpan){o="Width"===i?a.bounds.right:a.bounds.bottom,s||(s="Width"===i?a.bounds.width:a.bounds.height);for(var l=0;lo){var d=c-o+("Width"===i?a.bounds.width:a.bounds.height);s&&(s=s0?this.rowDefns.splice(e,0,i):this.rowDefns.push(i);var s=new R3;s.cells=[],(new Nd).width=this.width,this.addCellInRow(this.colDefns,i,s),e>this.rows.length-1?this.rows.push(s):this.rows.splice(e,0,s),r&&(this.measure(new me(this.width,this.height)),this.arrange(this.desiredSize))},t.prototype.addColumn=function(e,i,r){var s,o,a,l,h=this.rows;this.colDefns.length>0?this.colDefns.splice(e,0,i):this.colDefns.push(i),void 0!==this.width&&(this.width+=i.width);for(var c=0;cs.cells.length-1?s.cells.push(l):s.cells.splice(e,0,l),this.children.push(l);r&&(this.measure(new me(this.width,this.height)),this.arrange(this.desiredSize))},t.prototype.removeRow=function(e){var i,r,o=this.rows[parseInt(e.toString(),10)];this.height-=this.rowDefns[parseInt(e.toString(),10)].height;for(var a=0;a0){var r=0,s=0;i=new me(0,0),this.calculateSize();for(var o=0,a=this.rows;o0){for(var o=this.offsetX-e.width*this.pivot.x,a=this.offsetY-e.height*this.pivot.y,l=o,h=0,c=this.rows;h1&&this.children.splice(this.children.indexOf(p)+1,p.columnSpan-1),p.rowSpan>1)for(y=s,S=0;y+p.rowSpan-10){for(var c=0;c0?1:0,v=0;v0||a.outEdges.length>0))for(f=a.inEdges.concat(a.outEdges),s=0;s0)for(o=0;o1)for(a=1;a0))if(h=n.wrapper.children[0],"Horizontal"===e.orientation)for(o=e.header&&e.hasHeader?h.rows[1]:h.rows[0],r=0;r0){var e=void 0;t.lineRoutingModule&&t.constraints&nt.LineRouting&&t.lineRoutingModule.renderVirtualRegion(t,!0);for(var i=0;i0?o+1:o)].height=t.wrapper.height;else if(t.isPhase)for(l[t.rowIndex-o].offset=t.wrapper.height,p=0;p0?1:0)].width=t.wrapper.width}function WI(n,t){var i=n.shape,r=i.header&&i.hasHeader?1:0;return"Horizontal"===i.orientation?t.rowIndex-(r+=i.phases.length>0?1:0):t.columnIndex-(i.phaseSize&&i.phases.length>0?1:0)}function YI(n){var t=0,e=n.shape;return"Horizontal"===e.orientation&&(t=e.header&&e.hasHeader?1:0),e.phases.length>0&&e.phaseSize&&(t+=1),t}function QI(n,t,e,i){var r=n.shape;if(r.phases.length>0){var s=t.nameTable[r.phases[parseInt(i.toString(),10)].header.id];s&&s.maxWidth0?u+1:u);var w=Nc(n,o),C=void 0!==i?i:l.lanes.length;if(u+=C,r={element:M,cause:n.diagramActions,diagramAction:n.getDiagramAction(n.diagramActions),state:"Changing",type:"Addition",cancel:!1,laneIndex:C},n.triggerEvent(Ce.collectionChange,r),!r.cancel){if(c){var D=new Xv;D.height=e.height,o.addRow(u,D,!1),s.height=void 0!==s.height?s.height+e.height:s.height,s.wrapper.height=o.height=s.height}else{var A=new Nd;A.width=e.width,o.addColumn(C+1,A,!1),s.width&&(s.width+=e.width,s.wrapper.width=o.width=s.width),n.diagramActions&ee.UndoRedo||(o.rows[0].cells[0].columnSpan+=1)}n.diagramActions&ee.UndoRedo||(M.id=""===M.id?Qe():M.id),void 0!==i?l.lanes.splice(i,0,M):l.lanes.push(M),r={element:M,cause:n.diagramActions,diagramAction:n.getDiagramAction(n.diagramActions),state:"Changed",type:"Addition",cancel:!1,laneIndex:C},n.triggerEvent(Ce.collectionChange,r),B3(o,n,s,u,C,c),h="Horizontal"===l.orientation?n.nameTable[o.rows[parseInt(u.toString(),10)].cells[0].children[0].id]:l.header&&l.hasHeader?n.nameTable[o.rows[1].cells[parseInt(u.toString(),10)].children[0].id]:n.nameTable[o.rows[0].cells[parseInt(u.toString(),10)].children[0].id],n.diagramActions&ee.UndoRedo||(d={type:"LaneCollectionChanged",changeType:"Insert",undoObject:$(M),redoObject:$(h),category:"Internal"},n.addHistoryEntry(d)),Zf(n,s,"Horizontal"===l.orientation?u:l.header&&l.hasHeader?1:0),$f(s),Oc(n,s);var P=!1;if((f=e.children)&&f.length>0)for(p=0;p0){var o=t.children[0],a=n.nameTable[o.id];(function vne(n,t,e){return n.left-(e.left||0)<=t.x&&n.right+(e.right||0)>=t.x&&n.top-(e.top||0)<=t.y&&n.bottom+(e.bottom||0)>=t.y})(o.bounds,e,r)&&(n.addChild(a,i),s=!0)}return s}function mne(n,t,e){if("SwimLane"===t.shape.type){var i=void 0,r=void 0,s=void 0,a=void 0,l=void 0,h=void 0,c=t.wrapper.bounds.x,d=t.wrapper.bounds.y,u=t.shape,f=u.padding,p=u.phases,g=void 0,v=t.wrapper.children[0],y="Horizontal"===u.orientation;if(i=u.header&&u.hasHeader?0:-1,u.phases.length>0&&(i+=1),e.offset>(y?u.lanes[0].header.width:u.lanes[0].header.height)){for(h=0;he.offset){if(g=h>0?e.offset-(h>0?p[h-1]:s).offset:e.offset,y){var b=v.columnDefinitions()[parseInt(h.toString(),10)];b.width-=g,(a=n.nameTable[u.phases[parseInt(h.toString(),10)].header.id]).maxWidth=a.wrapper.maxWidth=b.width,v.updateColumnWidth(h,b.width,!1);var M=new Nd;M.width=g,l=h,v.addColumn(h,M,!1);break}var w=v.rowDefinitions()[h+i];w.height-=g,a=n.nameTable[u.phases[parseInt(h.toString(),10)].header.id],v.updateRowHeight(h+i,w.height,!1);var C=new Xv;C.height=g,l=h,v.addRow(h+i,C,!1);break}if(n.diagramActions&ee.UndoRedo&&void 0===l&&(D=n.historyManager.currentEntry.next).isLastPhase&&function yne(n,t,e,i,r,s){var a=t.shape.phases[n-2],l=e.previousPhase.offset;if(r){var h=i.columnDefinitions()[n-1],c=new Nd;n>1?(c.width=h.width-(l-a.offset),h.width=l-a.offset):(c.width=h.width-l,h.width=l),i.updateColumnWidth(n-1,h.width,!1),i.addColumn(n,c,!1)}else{h=i.rowDefinitions()[parseInt(n.toString(),10)];var d=new Xv;n>1?(d.height=e.undoObject.offset-l,h.height=l-a.offset):(d.height=h.height-l,h.height=l),i.updateRowHeight(n,h.height,!1),i.addRow(1+n,d,!1)}}(l=p.length,t,D,v,y),l>=0){var A=new fb(t.shape,"phases",e,!0);if(n.diagramActions&ee.UndoRedo||(A.id+=Qe()),u.phases.splice(l,0,A),jx(v,n,t,i,y,l),y){if(r=n.nameTable[v.rows[parseInt(i.toString(),10)].cells[parseInt(l.toString(),10)].children[0].id],0===l&&u.header&&u.hasHeader){v.rows[0].cells[0].children=v.rows[0].cells[1].children,v.rows[0].cells[1].children=[];for(var x=v.rows[0],P=0;Pl+1){var O=n.nameTable[v.rows[parseInt(i.toString(),10)].cells[l+1].children[0].id];v.updateColumnWidth(l+1,L[l+1].width,!0,f),O.maxWidth=O.wrapper.maxWidth=L[l+1].width}t.width=t.wrapper.width=t.wrapper.children[0].width=v.width}else{r=n.nameTable[v.rows[i+l].cells[0].children[0].id];var N=v.rowDefinitions(),T=N[i+l].height;(function Ine(n,t,e,i,r){for(var o,a,l=e.rows[parseInt(i.toString(),10)],h=e.rows[i+1],c=e.rows[i-1],d=1;di+l+1&&v.updateRowHeight(i+l+1,T=N[i+l+1].height,!0,f),t.height=t.wrapper.height=t.wrapper.children[0].height=v.actualSize.height}if($f(t),t.width=t.wrapper.actualSize.width,Oc(n,t),n.drag(t,c-t.wrapper.bounds.x,d-t.wrapper.bounds.y),VI(t,n),n.commandHandler.select(r),!(n.diagramActions&ee.UndoRedo)){var D={type:"PhaseCollectionChanged",changeType:"Insert",undoObject:$(A),redoObject:$(r),category:"Internal"};n.addHistoryEntry(D)}n.updateDiagramObject(t)}}}}function V3(n,t,e,i,r,s,o){var a,l,p,h=t.shape,c="Horizontal"===h.orientation,d=t.wrapper.children[0],g=c?s:o;e?(a=c?e.bounds.x+e.bounds.width:e.bounds.x,l=c?e.bounds.y:e.bounds.y+e.bounds.height):(a=d.bounds.x,l=r.bounds.y);var v=new Ne(a,l,i.desiredCellWidth,i.desiredCellHeight),S=qv(n,0,t,{id:t.id+(c?h.lanes[g-2]:h.lanes[g-1]).id+Qe()[0],rowIndex:s,columnIndex:o,width:i.minWidth,height:i.minHeight,style:(c?h.lanes[g-2]:h.lanes[g-1]).style,constraints:ie.Default|ie.AllowDrop,container:{type:"Canvas",orientation:c?"Horizontal":"Vertical"}},!1,!1,!0);if(S.children[0].isCalculateDesiredSize=!1,d.addObject(S,s,o),r&&r.children&&r.children.length)for(p=0;p1)for(var p=1;ph.margin.left&&(h.margin.left=f)):(h.margin.top-=e.desiredCellHeight,f>h.margin.top&&(h.margin.top=f)))}(n,r,i,v,S,c,e)}function W3(n,t,e){if("SwimLane"===t.shape.type&&("ResizeSouth"===e||"ResizeEast"===e)){var i=t.shape,r=t.wrapper.children[0],s=void 0,o=void 0;"ResizeSouth"===e?"Vertical"===i.orientation?s=r.rows[r.rows.length-1].cells[0]:(o=r.rows.length-1,s=r.rows[parseInt(o.toString(),10)].cells[r.rows[parseInt(o.toString(),10)].cells.length-1]):(o=i.header&&i.hasHeader?1:0,s=r.rows[parseInt(o.toString(),10)].cells[r.rows[parseInt(o.toString(),10)].cells.length-1]),n.commandHandler.select(n.nameTable[s.children[0].id])}}function GI(n,t,e,i,r,s){var o,a,l,c,u,f,p,d=Qe(),g=n.shape,v=g.phases,y=n.offsetX-n.wrapper.actualSize.width/2,S=n.offsetY-n.wrapper.actualSize.height/2;if("Vertical"===g.orientation&&(S+=g.header&&g.hasHeader?g.header.height:0),!s)for(r||(n.id+=d,g&&g.header&&g.hasHeader?g.header.id+=d:g.header=void 0),o=0;v&&o0&&s.columnIndex>0||s.isLane)?(a=function Lne(n,t,e){for(var i=new Ne,r="SwimLane"===n.shape.type?n.wrapper.children[0].rows:n.wrapper.rows,s=e?1:0;s=0;a--)i?i.id===o.children[parseInt(a.toString(),10)].id&&o.children.splice(a,1):(n.removeDependentConnector(o.children[parseInt(a.toString(),10)]),n.diagramActions&ee.UndoRedo||(n.diagramActions=n.diagramActions|ee.UndoRedo,s=!0),n.remove(o.children[parseInt(a.toString(),10)]),o.children.splice(a,1),s&&(n.diagramActions=n.diagramActions&~ee.UndoRedo))}function Mne(n){return n.children[0]}function Jv(n,t){t&&(n.nodes.splice(n.nodes.indexOf(t),1),n.removeFromAQuad(t),n.removeObjectsFromLayer(t),delete n.nameTable[t.id],n.removeElements(t))}function Q3(n,t,e,i){var r;if("SwimLane"===e.shape.type){var s=e.shape,o=void 0;if(1===s.lanes.length)n.remove(e);else{var a=e.wrapper.bounds.x,l=e.wrapper.bounds.y,h=void 0,c=void 0,d=void 0,u=void 0,p=e.wrapper.children[0];if(o=i?s.lanes.indexOf(i):WI(e,t),r={element:t,cause:n.diagramActions,diagramAction:n.getDiagramAction(n.diagramActions),state:"Changing",type:"Removal",cancel:!1,laneIndex:o},n.triggerEvent(Ce.collectionChange,r),!r.cancel){var g=s.lanes[parseInt(o.toString(),10)],v=g.children;g.children=[];for(var y=0;y0)for(u=0;u0)for(u=0;u0)for(e=0;e1){c===l.phases.length-1&&(o=!0,a=$(l.phases[c-1]));var u=$(l.phases[parseInt(c.toString(),10)]);if(l.phases.splice(c,1),!(n.diagramActions&ee.UndoRedo)){var f={type:"PhaseCollectionChanged",changeType:"Remove",undoObject:u,previousPhase:a,redoObject:$(t),category:"Internal",isLastPhase:o};n.addHistoryEntry(f)}"Horizontal"===l.orientation?function Cne(n,t,e,i){var r,s,o,a,l,h,c,d,u,f,p,g;for(i=void 0!==i?i:e.columnIndex,c=0;c1&&(s=r.cells[parseInt(i.toString(),10)],l=(o=r.cells.length-1===i?r.cells[i-1]:r.cells[i+1]).children[0],s.children.length>0))if(p=n.nameTable[(a=s.children[0]).id],0===o.children.length&&s.children.length>0)o.children=s.children,o.columnSpan=s.columnSpan-1;else{for(d=0;d0){var M=s.children[0],w=n.nameTable[M.id];if(i=e.x&&a.bounds.y<=e.y&&a.bounds.bottom>=e.y){var l=void 0,h=a.bounds.y,c=a.bounds.x,d=n.nameTable[r.parentId]||r;if("SwimLane"===d.shape.type)o=em(r,d,t,n,!0);else{var f=n.nameTable[r.parentId]||r,p=f.shape;l=f.wrapper,a.actualSize.widtha.outerBounds.x)&&(void 0!==r.rowIndex?(l.updateColumnWidth(r.columnIndex,a.outerBounds.width,!0),"Horizontal"===p.orientation&&p.phaseSize&&QI(f,n,a,r.columnIndex),Oc(n,f),n.drag(f,c-a.bounds.x,h-a.bounds.y)):n.scale(r,1+(a.outerBounds.width-a.actualSize.width)/a.actualSize.width,1,a.outerBounds.xa.outerBounds.y)&&(void 0!==r.rowIndex?(l.updateRowHeight(r.rowIndex,a.outerBounds.height,!0),n.drag(f,c-a.bounds.x,h-a.bounds.y)):n.scale(r,1,1+(a.outerBounds.height-a.actualSize.height)/a.actualSize.height,a.outerBounds.y=e.x&&a.bounds.y<=e.y&&a.bounds.bottom>=e.y)&&!(t.constraints&ie.AllowMovingOutsideLane)){var l=$(t);n.clearSelection(),$3(n,t),t.parentId="",t.parentObj=n,t.propName="nodes";var h={type:"ChildCollectionChanged",category:"Internal",undoObject:l,redoObject:$(t)};n.addHistoryEntry(h),n.commandHandler.isContainer&&(n.commandHandler.isContainer=!1,n.endGroupAction()),Z3(t,n)}n.protectPropertyChange(o)}}function XI(n,t){var e,i,r;return n.enableServerDataBinding(!1),ce()||(n.selectedObject.helperObject?r=n.selectedObject.helperObject:(n.selectedItems.nodes.length>0||n.selectedItems.connectors.length>0)&&(t instanceof ei&&t.nodes.length+t.connectors.length===1?(e=t.nodes.length>0?t.nodes[0]:t.connectors[0],i=n.selectedItems.wrapper.children[0]):(e=t,i=n.selectedItems.wrapper),n.selectedObject.actualObject=e,!n.currentSymbol&&(e.isLane&&Qx(e,n)&&Dn(n,e)||!e.isLane&&Dn(n,e)||n.constraints&nt.LineRouting&&n.selectedItems.nodes.length>0))&&(r=function Nne(n,t){for(var e,i={},r=0,s=Object.keys(t);r=t.x-e&&n.x<=t.x+e&&n.y>=t.y-e&&n.y<=t.y+e}function $a(n){return n.selectedItems.nodes.length>0||n.selectedItems.connectors.length>0}function K3(n){return 1===n.selectedItems.connectors.length&&!n.selectedItems.nodes.length}function _r(n,t,e,i){if(void 0===e&&(e=!0),t instanceof ei)return!0;if(t instanceof te)for(;t;){if(-1!==n.selectedItems.nodes.indexOf(t)&&void 0===n.selectedItems.annotation)return!0;if(e)break;t=n.nameTable[t.parentId]}else if(t instanceof de){if(-1!==n.selectedItems.connectors.indexOf(t)&&void 0===n.selectedItems.annotation)return!0}else if((t instanceof Kn||t instanceof Or)&&n.selectedItems.annotation&&n.selectedItems.wrapper.children[0].id===i.id)return!0;return!1}var Gx={None:"default",Rotate:"crosshair",Select:"default",Drag:"move",ResizeWest:"w-resize",ResizeEast:"e-resize",ResizeSouth:"s-resize",ResizeNorth:"n-resize",Draw:"crosshair",PortDraw:"crosshair",ResizeNorthEast:"ne-resize",ResizeNorthWest:"nw-resize",ResizeSouthEast:"se-resize",ResizeSouthWest:"sw-resize",ConnectorSourceEnd:"move",ConnectorTargetEnd:"move",BezierSourceThumb:"move",BezierTargetThumb:"move",OrthoThumb:"move",SegmentEnd:"move",Pan:"grab",Hyperlink:"pointer",PortDrag:"pointer",LabelSelect:"pointer",LabelDrag:"move",LabelRotate:"crosshair",LabelResizeWest:"w-resize",LabelResizeEast:"e-resize",LabelResizeSouth:"s-resize",LabelResizeNorth:"n-resize",LabelResizeNorthEast:"ne-resize",LabelResizeNorthWest:"nw-resize",LabelResizeSouthEast:"se-resize",LabelResizeSouthWest:"sw-resize"},ds=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),kd=function(n,t,e,i){return new(e||(e=Promise))(function(r,s){function o(h){try{l(i.next(h))}catch(c){s(c)}}function a(h){try{l(i.throw(h))}catch(c){s(c)}}function l(h){h.done?r(h.value):new e(function(c){c(h.value)}).then(o,a)}l((i=i.apply(n,t||[])).next())})},Pd=function(n,t){var i,r,s,o,e={label:0,sent:function(){if(1&s[0])throw s[1];return s[1]},trys:[],ops:[]};return o={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function a(h){return function(c){return function l(h){if(i)throw new TypeError("Generator is already executing.");for(;e;)try{if(i=1,r&&(s=2&h[0]?r.return:h[0]?r.throw||((s=r.return)&&s.call(r),0):r.next)&&!(s=s.call(r,h[1])).done)return s;switch(r=0,s&&(h=[2&h[0],s.value]),h[0]){case 0:case 1:s=h;break;case 4:return e.label++,{value:h[1],done:!1};case 5:e.label++,r=h[1],h=[0];continue;case 7:h=e.ops.pop(),e.trys.pop();continue;default:if(!(s=(s=e.trys).length>0&&s[s.length-1])&&(6===h[0]||2===h[0])){e=0;continue}if(3===h[0]&&(!s||h[1]>s[0]&&h[1]-1&&(r=i.fixedUserHandles[parseInt(o.toString(),10)]);this.commandHandler.triggerEvent(Ce.fixedUserHandleClick,{fixedUserHandle:r,element:e.source}),n.prototype.mouseUp.call(this,e)},t}(us),zd=function(n){function t(e,i){var r=n.call(this,e,!0)||this;return r.isConnected=!1,r.endPoint=i,r}return ds(t,n),t.prototype.mouseDown=function(e){return kd(this,void 0,void 0,function(){var r,s,o,a,l;return Pd(this,function(h){if(this.inAction=!0,this.undoElement=void 0,this instanceof pa||(this.undoElement=$(e.source)),n.prototype.mouseDown.call(this,e),e.source&&e.source.connectors&&(this.oldConnector=$(r=e.source.connectors[0])),"BezierSourceThumb"===this.endPoint||"BezierTargetThumb"===this.endPoint)for(s=0;s0))},t.prototype.endAction=function(){n.prototype.endAction.call(this),this.prevPosition=null,this.endPoint=null},t}(us),fa=function(n){function t(e,i){var r=n.call(this,e,!0)||this;return r.currentTarget=null,r.isStartAction=!1,r.canCancel=!1,r.canTrigger=!1,r.objectType=i,r}return ds(t,n),t.prototype.mouseDown=function(e){if(e.source instanceof te||e.source instanceof de){var i=this.commandHandler.getSelectedObject();this.commandHandler.selectObjects([e.source],e.info&&e.info.ctrlKey,i);var r={nodes:[],connectors:[]};e.source instanceof te?r.nodes.push($(e.source)):r.connectors.push($(e.source)),this.undoElement=$(r)}else this.undoElement=$(e.source);this.undoParentElement=this.commandHandler.getSubProcess(e.source),"Port"===this.objectType&&(this.portId=e.sourceWrapper.id),this.commandHandler.insertBlazorConnector(e.source),n.prototype.mouseDown.call(this,e),this.initialOffset={x:0,y:0}},t.prototype.mouseUp=function(e,i){return kd(this,void 0,void 0,function(){var s,o,a,l,h,c,d,u,p,g,v,y,S,b,M;return Pd(this,function(w){if(this.checkPropertyValue(),a=!1,h={nodes:[],connectors:[]},"Port"!==this.objectType){if(e.source instanceof te||e.source instanceof de?(e.source instanceof te?h.nodes.push($(e.source)):h.connectors.push($(e.source)),(o=$(h)).offsetX=(c=e.source.wrapper).offsetX,o.offsetY=c.offsetY):o=$(e.source),("helper"===(l=this.commandHandler.renderContainerHelper(e.source)||e.source||this.commandHandler.renderContainerHelper(e.source)).id||"helper"!==l.id)&&((l instanceof ei&&(Math.round(l.width)===Math.round(this.undoElement.width)&&Math.round(l.height)===Math.round(this.undoElement.height)||l.selectedObjects&&1===l.selectedObjects.length)||!(l instanceof ei))&&(l.offsetX!==this.undoElement.offsetX||l.offsetY!==this.undoElement.offsetY||l.sourcePoint!==this.undoElement.sourcePoint||l.targetPoint!==this.undoElement.targetPoint)||this.isSelectionHasConnector(l))&&(e.source&&(s={offsetX:e.source.wrapper.offsetX,offsetY:e.source.wrapper.offsetY}),g={source:e.source,state:"Completed",oldValue:this.intialValue,newValue:s,target:this.currentTarget,targetPosition:this.currentPosition,allowDrop:(g={source:e.source,state:"Completed",oldValue:this.intialValue,newValue:s,target:this.currentTarget,targetPosition:this.currentPosition,allowDrop:!0,cancel:!1}).allowDrop,cancel:g.cancel},d=!0,"helper"===l.id?this.canTrigger?(this.commandHandler.triggerEvent(Ce.positionChange,g),this.connectorEndPointChangeEvent(g),d=!0):d=!1:(this.commandHandler.triggerEvent(Ce.positionChange,g),this.connectorEndPointChangeEvent(g)),!i&&d&&(this.commandHandler.startGroupAction(),a=!0,M={type:"PositionChanged",redoObject:$(o),undoObject:$(this.undoElement),category:"Internal"},o.nodes[0]&&o.nodes[0].processId&&(u={type:"SizeChanged",category:"Internal",undoObject:this.undoParentElement,redoObject:this.commandHandler.getSubProcess(e.source)},this.commandHandler.addHistoryEntry(u)),this.commandHandler.addHistoryEntry(M))),this.commandHandler.snapPoint(this.prevPosition,this.currentPosition,0,0),this.commandHandler.removeSnap(),this.commandHandler.removeHighlighter(),e.source&&this.currentTarget&&FI(this.currentTarget)&&this.commandHandler.isDroppable(e.source,this.currentTarget)){if(p=!0,this.commandHandler.drop(this.currentElement,this.currentTarget,this.currentPosition),this.currentTarget&&this.currentTarget instanceof de&&!0===this.commandHandler.diagram.enableConnectorSplit)if(this.currentElement&&this.currentElement instanceof te){if(void 0!==this.currentElement.children)for(b=0;b0)for(var s=0;s0)for(var a=0;a0)for(a=0;a0&&e.connectors.length>0)||e.width===this.undoElement.width&&e.height===this.undoElement.height)},t.prototype.mouseMove=function(e){n.prototype.mouseMove.call(this,e);var r,s,i=!1;(r=this.commandHandler.renderContainerHelper(e.source)||e.source)instanceof te||r instanceof de?r instanceof te?r.offsetX===this.undoElement.nodes[0].offsetX&&r.offsetY===this.undoElement.nodes[0].offsetY&&(i=!0):R.equals(r.sourcePoint,this.undoElement.connectors[0].sourcePoint)&&R.equals(r.targetPoint,this.undoElement.connectors[0].targetPoint)&&(i=!0):r.wrapper.offsetX===this.undoElement.wrapper.offsetX&&r.wrapper.offsetY===this.undoElement.wrapper.offsetY&&(i=!0),r&&(s={offsetX:r.wrapper.offsetX,offsetY:r.wrapper.offsetY});var o={source:r,state:"Start",oldValue:s,newValue:s,target:e.target,targetPosition:e.position,allowDrop:!0,cancel:!1};if(o={source:r,state:"Start",oldValue:s,newValue:s,target:e.target,targetPosition:e.position,allowDrop:o.allowDrop,cancel:o.cancel},this.isStartAction||(this.intialValue={offsetX:r.wrapper.offsetX,offsetY:r.wrapper.offsetY}),i&&!ce()&&(this.commandHandler.triggerEvent(Ce.positionChange,o),this.connectorEndPointChangeEvent(o),this.isStartAction=!0),this.currentPosition=e.position,"Port"!==this.objectType){var h=this.initialOffset.x+(this.currentPosition.x-this.prevPosition.x),c=this.initialOffset.y+(this.currentPosition.y-this.prevPosition.y);this.commandHandler.dragOverElement(e,this.currentPosition),this.commandHandler.disConnect(e.source),this.commandHandler.removeSnap();var d,u=void 0,f=this.commandHandler.snapPoint(this.prevPosition,this.currentPosition,h,c);this.initialOffset.x=h-f.x,this.initialOffset.y=c-f.y,r&&(d={offsetX:r.wrapper.offsetX,offsetY:r.wrapper.offsetY},u={offsetX:r.wrapper.offsetX+f.x,offsetY:r.wrapper.offsetY+f.y}),this.currentTarget&&e.target!==this.currentTarget&&this.commandHandler.removeChildFromBPmn(e.source,e.target,this.currentTarget),this.currentTarget=e.target;var p={source:r,state:"Progress",oldValue:d,newValue:u,target:e.target,targetPosition:e.position,allowDrop:!0,cancel:!1};if(this.commandHandler.triggerEvent(Ce.positionChange,p),this.canTrigger=!0,this.connectorEndPointChangeEvent(p,f),!p.cancel&&!this.canCancel){this.blocked=!this.commandHandler.dragSelectedObjects(f.x,f.y);var g=!this.commandHandler.mouseOver(this.currentElement,this.currentTarget,this.currentPosition);this.blocked=this.blocked||g}if(this.commandHandler.removeStackHighlighter(),this.commandHandler.renderStackHighlighter(e),this.currentTarget&&e.source!==this.currentTarget&&this.commandHandler.isDroppable(e.source,this.currentTarget)&&"helper"!==e.source.id){var v=e.source instanceof ei?e.source.nodes[0]:e.source;!this.commandHandler.isParentAsContainer(v,!0)&&"SwimLane"!==v.shape.type&&!v.shape.isPhase&&(this.currentTarget.isLane?this.commandHandler.renderStackHighlighter(e,this.currentTarget):this.commandHandler.drawHighlighter(this.currentTarget))}else this.commandHandler.removeHighlighter();if(this.commandHandler.canEnableDefaultTooltip()){var y=this.getTooltipContent(e.source);this.commandHandler.showTooltip(e.source,e.position,ko(function(){return y}),"MoveTool",this.isTooltipVisible),this.isTooltipVisible=!1}}else{var b=Bi(),M=e.source;qi(b,-M.rotateAngle||-M.wrapper.rotateAngle,M.offsetX||M.wrapper.offsetX,M.offsetY||M.wrapper.offsetY);var w=Ke(b,{x:this.prevPosition.x,y:this.prevPosition.y}),C=Ke(b,{x:e.position.x,y:e.position.y});this.commandHandler.portDrag(e.source,e.sourceWrapper,C.x-w.x,C.y-w.y)}return this.prevPosition=this.currentPosition,!this.blocked},t.prototype.getTooltipContent=function(e){return"X:"+Math.round(e.wrapper.bounds.x)+" Y:"+Math.round(e.wrapper.bounds.y)},t.prototype.mouseLeave=function(e){this.mouseUp(e)},t.prototype.endAction=function(){n.prototype.endAction.call(this),this.currentTarget=null,this.prevPosition=null},t}(us),Xx=function(n){function t(e){var i=n.call(this,e,!0)||this;return i.rotateStart=!1,i}return ds(t,n),t.prototype.mouseDown=function(e){if(this.undoElement=$(e.source),this.undoElement.nodes[0]&&this.undoElement.nodes[0].children)for(var r=this.commandHandler.getAllDescendants(this.undoElement.nodes[0],[]),s=0;s=2){var s=e.startTouches[0],o=e.startTouches[1],a=e.moveTouches[0],l=e.moveTouches[1],h=this.getDistance(a,l)/this.getDistance(s,o);this.commandHandler.zoom(h,0,0,e.position),this.updateTouch(s,a),this.updateTouch(o,l)}}else this.commandHandler.scroll(this.currentPosition.x-this.prevPosition.x,this.currentPosition.y-this.prevPosition.y,this.currentPosition);return this.commandHandler.dataBinding(),!this.blocked},t.prototype.mouseUp=function(e){this.commandHandler.setBlazorDiagramProps(!1),this.checkPropertyValue(),this.commandHandler.updatePanState(!1),n.prototype.mouseUp.call(this,e),this.inAction=!1},t.prototype.endAction=function(){n.prototype.endAction.call(this)},t.prototype.getDistance=function(e,i){var r=i.pageX-e.pageX,s=i.pageY-e.pageY;return Math.sqrt(r*r+s*s)},t.prototype.updateTouch=function(e,i){e.pageX=i.pageX,e.pageY=i.pageY},t}(us),Une=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseUp=function(e){this.checkPropertyValue(),this.commandHandler.initExpand(e),n.prototype.mouseUp.call(this,e)},t}(us),eF=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseUp=function(e){this.checkPropertyValue();var i="_blank",r="",s=window.innerHeight,o=window.innerWidth,a=window.screenTop,l=window.screenLeft;"CurrentTab"===e.sourceWrapper.hyperlink.hyperlinkOpenState?i="_self":"NewWindow"===e.sourceWrapper.hyperlink.hyperlinkOpenState&&(r="height="+s+",width="+o+",top="+a+",left="+l),window.open(e.sourceWrapper.hyperlink.link,i,r).focus(),n.prototype.mouseUp.call(this,e)},t}(us),Rl=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseDown=function(e){if(n.prototype.mouseDown.call(this,e),this.inAction=!0,this.drawingObject){var r=void 0,s=this.drawingObject.shape;this.drawingObject.shape.points.push(r={x:(r=s.points[s.points.length-1]).x,y:r.y})}else{this.startPoint={x:this.startPosition.x,y:this.startPosition.y};var i={offsetX:this.currentPosition.x,offsetY:this.currentPosition.y,width:5,height:5,shape:{type:"Basic",shape:"Polygon",points:[{x:this.startPoint.x,y:this.startPoint.y},{x:this.currentPosition.x,y:this.currentPosition.y}]}};this.triggerElementDrawEvent(e.source,"Start","Node",this.getShapeType(),!0),this.drawingObject=this.commandHandler.drawObject(i)}},t.prototype.mouseMove=function(e){if(n.prototype.mouseMove.call(this,e),this.inAction){var i=this.drawingObject.shape;if(i.points[i.points.length-1].x=this.currentPosition.x,i.points[i.points.length-1].y=this.currentPosition.y,this.drawingObject.wrapper.children[0].data=Sx(this.drawingObject.shape.points),this.triggerElementDrawEvent(this.drawingObject,"Progress","Node",this.getShapeType(),!1),this.inAction&&!1===R.equals(this.currentPosition,this.prevPosition)){var r=Ne.toBounds(this.drawingObject.shape.points);this.commandHandler.updateNodeDimension(this.drawingObject,r)}}return!0},t.prototype.mouseUp=function(e,i){this.checkPropertyValue(),n.prototype.mouseMove.call(this,e),this.inAction&&(this.inAction=!1,this.commandHandler.addObjectToDiagram(this.drawingObject),this.triggerElementDrawEvent(this.drawingObject,"Completed","Node",this.getShapeType(),!1)),this.endAction()},t.prototype.mouseWheel=function(e){n.prototype.mouseWheel.call(this,e),this.mouseMove(e)},t.prototype.endAction=function(){this.inAction=!1,this.drawingObject=null},t}(us),Hl=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseMove=function(e){if(n.prototype.mouseMove.call(this,e),this.inAction){var i=this.drawingObject;i.targetPoint=this.currentPosition,this.triggerElementDrawEvent(this.drawingObject,"Progress","Connector",this.drawingObject.type,!1),this.commandHandler.updateConnectorPoints(i)}return!0},t.prototype.mouseDown=function(e){if(n.prototype.mouseDown.call(this,e),this.inAction=!0,this.drawingObject){var r=this.drawingObject,s=void 0;(s=new Bl(r,"segments",{type:"Straight"},!0)).point=this.currentPosition,r.segments[r.segments.length-1]=s}else{var i={id:"Connector",type:"Straight",sourcePoint:this.currentPosition,targetPoint:this.currentPosition};this.triggerElementDrawEvent(e.source,"Start","Connector",this.commandHandler.diagram.drawingObject.type,!0),this.inAction&&(this.drawingObject=this.commandHandler.drawObject(i))}},t.prototype.mouseWheel=function(e){n.prototype.mouseWheel.call(this,e),this.mouseMove(e)},t.prototype.mouseUp=function(e){if(this.checkPropertyValue(),n.prototype.mouseMove.call(this,e),this.inAction&&this.drawingObject){var i=this.drawingObject;i.segments[i.segments.length-1].point={x:0,y:0},this.commandHandler.addObjectToDiagram(this.drawingObject),this.triggerElementDrawEvent(this.drawingObject,"Completed","Connector",this.drawingObject.type,!1)}this.endAction()},t.prototype.endAction=function(){this.drawingObject=null,this.inAction=!1},t}(us),jne=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseDown=function(e){this.inAction=!0,this.undoElement=$(e.source),this.annotationId=e.sourceWrapper.id,n.prototype.mouseDown.call(this,e)},t.prototype.mouseMove=function(e){n.prototype.mouseMove.call(this,e);var i=this.currentPosition.x-this.prevPosition.x,r=this.currentPosition.y-this.prevPosition.y,s=e.source;if(s instanceof te){var o=Bi();qi(o,-s.rotateAngle,0,0);var a=Ke(o,{x:i,y:r});i=a.x,r=a.y}return this.inAction&&(this.commandHandler.labelDrag(e.source,e.sourceWrapper,i,r),this.commandHandler.updateSelector()),this.prevPosition=this.currentPosition,!this.blocked},t.prototype.mouseUp=function(e){this.checkPropertyValue();var i=e.source;this.inAction=!1;var r={type:"AnnotationPropertyChanged",objectId:this.annotationId,undoObject:$(this.undoElement),category:"Internal",redoObject:$(i)};this.commandHandler.addHistoryEntry(r),n.prototype.mouseUp.call(this,e)},t.prototype.mouseLeave=function(e){this.mouseUp(e)},t}(us),Vne=function(n){function t(e,i){var r=n.call(this,e,!0)||this;return r.corner=i,r}return ds(t,n),t.prototype.mouseDown=function(e){this.inAction=!0;var i=e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0];this.annotationId=e.source.wrapper.children[0].id,this.undoElement=$(i);var r=e.source.wrapper.children[0];this.initialBounds={x:r.offsetX,y:r.offsetY,width:r.actualSize.width,height:r.actualSize.height},n.prototype.mouseDown.call(this,e)},t.prototype.mouseMove=function(e){return n.prototype.mouseMove.call(this,e),this.inAction&&this.resizeObject(e),!this.blocked},t.prototype.mouseUp=function(e){this.checkPropertyValue();var i=e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0];this.inAction=!1;var r={type:"AnnotationPropertyChanged",objectId:this.annotationId,redoObject:$(i),undoObject:$(this.undoElement),category:"Internal"};this.commandHandler.addHistoryEntry(r),n.prototype.mouseUp.call(this,e)},t.prototype.mouseLeave=function(e){this.mouseUp(e)},t.prototype.resizeObject=function(e){var i,s,o,r=e.source.wrapper.children[0],a={x:r.offsetX,y:r.offsetY},l=r.rotateAngle;l=((l+=(i=e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0])instanceof te?i.rotateAngle:0)+360)%360;var h=Bi();qi(h,l,a.x,a.y);var c=this.corner.slice(5),d=this.updateSize(r,this.startPosition,this.currentPosition,c,this.initialBounds,l),u=r.offsetX-r.actualSize.width*r.pivot.x,f=r.offsetY-r.actualSize.height*r.pivot.y,p=this.getPivot(c),g=Ke(h,p={x:u+r.actualSize.width*p.x,y:f+r.actualSize.height*p.y});d.x=g.x,d.y=g.y,this.commandHandler.labelResize(i,e.source.annotation,s=(s=d.width)<0?1:s,o=(o=d.height)<0?1:o,d,e.source),this.commandHandler.updateSelector()},t}(us),Wne=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseDown=function(e){this.inAction=!0,this.annotationId=e.source.wrapper.children[0].id,this.undoElement=$(e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0]),n.prototype.mouseDown.call(this,e)},t.prototype.mouseMove=function(e){return n.prototype.mouseMove.call(this,e),e.source&&this.inAction&&(this.commandHandler.labelRotate(e.source.nodes[0]?e.source.nodes[0]:e.source.connectors[0],e.source.annotation,this.currentPosition,e.source),this.commandHandler.updateSelector()),this.prevPosition=this.currentPosition,!this.blocked},t.prototype.mouseUp=function(e){this.checkPropertyValue(),this.inAction=!1;var r={type:"AnnotationPropertyChanged",objectId:this.annotationId,redoObject:$(e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0]),undoObject:$(this.undoElement),category:"Internal"};this.commandHandler.addHistoryEntry(r),n.prototype.mouseUp.call(this,e)},t.prototype.mouseLeave=function(e){this.mouseUp(e)},t}(us),Yne=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseMove=function(e){if(n.prototype.mouseMove.call(this,e),this.inAction){var i=this.drawingObject.shape;if(i.points.push(this.currentPosition),this.drawingObject.wrapper.children[0].data=Ix(this.drawingObject.shape.points),i.data=Ix(i.points),this.triggerElementDrawEvent(e.source,"Progress","Connector",this.drawingObject.type,!1),this.inAction&&!1===R.equals(this.currentPosition,this.prevPosition)){var s=Ne.toBounds(this.drawingObject.shape.points);this.commandHandler.updateNodeDimension(this.drawingObject,s)}}return!0},t.prototype.mouseDown=function(e){n.prototype.mouseDown.call(this,e),this.inAction=!0,this.startPoint={x:this.startPosition.x,y:this.startPosition.y};var i={offsetX:this.currentPosition.x,offsetY:this.currentPosition.y,width:5,height:5,style:{strokeColor:"black",strokeWidth:1,fill:"transparent"},shape:{type:"Path",points:[{x:this.startPoint.x,y:this.startPoint.y},{x:this.currentPosition.x,y:this.currentPosition.y}]}};this.triggerElementDrawEvent(e.source,"Start","Connector",this.commandHandler.diagram.drawingObject.type,!0),this.drawingObject=this.commandHandler.drawObject(i)},t.prototype.mouseUp=function(e){if(this.checkPropertyValue(),this.inAction){this.inAction=!1;var s=this.drawingObject.shape,o=s.points;this.commandHandler.addObjectToDiagram(this.drawingObject),this.commandHandler.diagram.remove(this.commandHandler.diagram.nameTable[""+this.drawingObject.id]),o=this.pointReduction(o,10);var h={id:"newConnector"+Qe(),type:"Bezier",sourcePoint:{x:o[0].x,y:o[0].y},targetPoint:{x:o[o.length-1].x,y:o[o.length-1].y},segments:[],bezierSettings:{allowSegmentsReset:!1}};this.drawingObject=this.commandHandler.drawObject(h),this.drawingObject=this.bezierCurveSmoothness(o,.5,this.drawingObject,s),this.commandHandler.updateConnectorPoints(this.drawingObject),this.commandHandler.addObjectToDiagram(this.drawingObject),this.triggerElementDrawEvent(this.drawingObject,"Completed","Connector",this.drawingObject.type,!1),n.prototype.mouseUp.call(this,e)}},t.prototype.pointReduction=function(e,i){if(null===e||e.length<3)return e;var s=e.length-1,o=[];for(o.push(0),o.push(s);e[parseInt((0).toString(),10)]===e[parseInt(s.toString(),10)];)s--;this.reduction(e,0,s,i,o);var a=[];return o.sort(function(l,h){return l-h}),o.forEach(function(l){a.push(e[parseInt(l.toString(),10)])}),a},t.prototype.reduction=function(e,i,r,s,o){for(var a=0,l=0,h=i;ha&&(a=c,l=h)}a>s&&0!==l&&(o.push(l),this.reduction(e,i,l,s,o),this.reduction(e,l,r,s,o))},t.prototype.perpendicularDistance=function(e,i,r){return Math.abs(.5*(e.x*i.y-i.x*e.y+(i.x*r.y-r.x*i.y)+(r.x*e.y-e.x*r.y)))/Math.sqrt(Math.pow(e.x-i.x,2)+Math.pow(e.y-i.y,2))*2},t.prototype.bezierCurveSmoothness=function(e,i,r,s){if(e.length<3)return r;for(var o=0;o=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Qne=function(n){if(n)switch(n.type){case"Bpmn":return $ne;case"UmlActivity":return qne;case"UmlClassifier":return Kne;default:return rm}return rm},Gne=function(n){if(n)switch(n.type){case"Straight":default:return Bl;case"Bezier":return fs;case"Orthogonal":return wi}},tF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I(10)],t.prototype,"width",void 0),Pe([I(10)],t.prototype,"height",void 0),Pe([I("Arrow")],t.prototype,"shape",void 0),Pe([re({fill:"black",strokeColor:"black",strokeWidth:1},Nl)],t.prototype,"style",void 0),Pe([re({x:0,y:.5},R)],t.prototype,"pivot",void 0),Pe([I("")],t.prototype,"pathData",void 0),t}(Ee),ZI=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I(0)],t.prototype,"angle",void 0),Pe([I(0)],t.prototype,"distance",void 0),t}(Ee),Xne=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I(Cx.All)],t.prototype,"controlPointsVisibility",void 0),Pe([I("FreeForm")],t.prototype,"segmentEditOrientation",void 0),Pe([I(CI.Default)],t.prototype,"smoothness",void 0),Pe([I(!0)],t.prototype,"allowSegmentsReset",void 0),t}(Ee),rm=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I("None")],t.prototype,"type",void 0),t}(Ee),qne=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I("Object")],t.prototype,"flow",void 0),Pe([I(30)],t.prototype,"exceptionFlowHeight",void 0),t}(rm),$ne=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I("Sequence")],t.prototype,"flow",void 0),Pe([I("Normal")],t.prototype,"sequence",void 0),Pe([I("Default")],t.prototype,"message",void 0),Pe([I("Default")],t.prototype,"association",void 0),t}(rm),iF=function(n){function t(e,i,r,s){var o=n.call(this,e,i,r,s)||this;return o.points=[],o}return Qs(t,n),Pe([I("Straight")],t.prototype,"type",void 0),Pe([I(!0)],t.prototype,"allowDrag",void 0),t}(Ee),Bl=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),t.prototype.getClassName=function(){return"StraightSegment"},Pe([re({x:0,y:0},R)],t.prototype,"point",void 0),t}(iF),fs=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),t.prototype.getClassName=function(){return"BezierSegment"},t.prototype.getPoints=function(e,i){var r=[];if(r.length>0||null!=i){var o=this.bezireToPoly(r.length>0?r[r.length-1]:i,e);r.push.apply(r,o)}return r},t.prototype.bezireToPoly=function(e,i){var r=[];return i&&this.flattenCubicBezier(r,e,i.bezierPoint1,i.bezierPoint2,{x:i.points[1].x,y:i.points[1].y},10),r},t.prototype.flattenCubicBezier=function(e,i,r,s,o,a){var h,l=(R.findLength(i,r)+R.findLength(r,s)+R.findLength(s,o))/a;for(h=0;h<=l;h++){var c=h/l;e.push({x:(1-c)*(1-c)*(1-c)*i.x+3*c*(1-c)*(1-c)*r.x+3*c*c*(1-c)*s.x+c*c*c*o.x,y:(1-c)*(1-c)*(1-c)*i.y+3*c*(1-c)*(1-c)*r.y+3*c*c*(1-c)*s.y+c*c*c*o.y})}},Pe([I("Horizontal")],t.prototype,"orientation",void 0),Pe([re({x:0,y:0},R)],t.prototype,"point1",void 0),Pe([re({x:0,y:0},R)],t.prototype,"point2",void 0),Pe([re({angle:0,distance:0},ZI)],t.prototype,"vector1",void 0),Pe([re({angle:0,distance:0},ZI)],t.prototype,"vector2",void 0),t}(Bl),wi=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),t.prototype.getClassName=function(){return"OrthogonalSegment"},Pe([I(null)],t.prototype,"length",void 0),Pe([I(null)],t.prototype,"direction",void 0),t}(iF);function rF(n,t,e){var s=e?45:180/(2+2/(n.height/n.width)),o=s,a=180-s,l=a+2*s,h=360-s,c=Gt(t,n.center);return c>o&&ca&&cl&&cMath.abs(t.y-n.y)?n.x=c)return s=R.findAngle(n[parseInt(d.toString(),10)],n[d+1]),{point:r=R.transform(n[parseInt(d.toString(),10)],s,c-(a||0)),index:l=d};a=o[parseInt(d.toString(),10)]}return{point:r,index:l}}(n,t),r=R.findAngle(n[i.index],n[i.index+1]),s=function xse(n){var e=0;switch(n.alignment){case"Center":case"After":e=0;break;case"Before":e=-0}return e}(t),o=R.transform(i.point,r+45,s);return i.point=o,i.angle=r,i}(i,e),h=l.point;s.id=this.id+"_"+e.id;var c=e.style;s.style={fill:c.fill,strokeColor:c.strokeColor,gradient:null,opacity:c.opacity,strokeDashArray:c.strokeDashArray,strokeWidth:c.strokeWidth},0===r.width&&(r.width=this.style.strokeWidth),0===r.height&&(r.height=this.style.strokeWidth);var d_y=(h.y-r.y)/r.height;a.x=r.width*((h.x-r.x)/r.width),a.y=r.height*d_y;var g,v,u=SF(e,l.angle,i),f=u.hAlign,p=u.vAlign;return"left"===f?(g="Left",a.x+=e.displacement.x):"right"===f?(g="Right",a.x-=e.displacement.x):"center"===f&&(g="Center"),"top"===p?(v="Top",a.y+=e.displacement.y):"bottom"===p?(v="Bottom",a.y-=e.displacement.y):"center"===p&&(v="Center"),s.horizontalAlignment=g,s.verticalAlignment=v,(s=om(s,o&&"Label"!==o.flipMode&&"None"!==o.flipMode?this.flip:"None",e)).float=!0,s.connectionDirection=e.connectionDirection,s.setOffsetWithRespectToBounds(a.x,a.y,"Absolute"),s.relativeMode="Point",s.visible=!(!va(e,ci.Visible)||va(e,ci.Hover)||va(e,ci.Connect)),s.elementActions=s.elementActions|Xr.ElementIsPort,s},t.prototype.getConnectorRelation=function(){var e=this.shape;"Association"===e.relationship?(this.segments[0].type="Straight",this.sourceDecorator.shape="None",this.targetDecorator.shape="Arrow"):"Inheritance"===e.relationship?(this.segments[0].type="Orthogonal",this.sourceDecorator.shape="None",this.targetDecorator.shape="Arrow"):"Composition"===e.relationship||"Aggregation"===e.relationship?(this.segments[0].type="Orthogonal",this.sourceDecorator.shape="Diamond",this.targetDecorator.shape="None"):"Dependency"===e.relationship?(this.segments[0].type="Orthogonal",this.sourceDecorator.shape="None",this.targetDecorator.shape="OpenArrow"):"Realization"===e.relationship&&(this.segments[0].type="Orthogonal",this.sourceDecorator.shape="None",this.targetDecorator.shape="Arrow"),"BiDirectional"===e.associationType&&(this.sourceDecorator.shape="None",this.targetDecorator.shape="None");var i,o,r="",s="";e.multiplicity.source&&(e.multiplicity.source.lowerBounds=e.multiplicity.source.lowerBounds,e.multiplicity.source.upperBounds=e.multiplicity.source.upperBounds),e.multiplicity.target&&(e.multiplicity.target.lowerBounds=e.multiplicity.target.lowerBounds,e.multiplicity.target.upperBounds=e.multiplicity.target.upperBounds);var a=e.multiplicity.source,l=e.multiplicity.target;o=a.upperBounds?a.lowerBounds+"..."+a.upperBounds:a.lowerBounds,i=l.upperBounds?l.lowerBounds+"..."+l.upperBounds:l.lowerBounds,"ManyToOne"===e.multiplicity.type&&(e.multiplicity.target.optional=!1,r=o||"*",s="1"),"OneToMany"===e.multiplicity.type&&(e.multiplicity.source.optional=!1,s=i||"*",r="1"),"ManyToMany"===e.multiplicity.type&&(r=o||"*",s=i||"*"),"OneToOne"===e.multiplicity.type&&(e.multiplicity.target.optional=!1,e.multiplicity.source.optional=!1,r="1",s="1"),this.annotations=[{id:this.id+"sourcelabel",content:r,offset:0,alignment:"Before",margin:{right:5,bottom:5}},{id:this.id+"targetlabel",content:s,offset:1,alignment:"Before",margin:{right:5,bottom:5}}]},t.prototype.getBpmnSequenceFlow=function(){var e=new Ze,i=new Ze;return"Normal"===this.shape.sequence&&"Bezier"!==this.type&&(this.targetDecorator.shape="Arrow"),"Default"===this.shape.sequence&&(e=this.getSegmentElement(this,e),i=DF(this.intermediatePoints,this),this.targetDecorator.shape="Arrow"),"Conditional"===this.shape.sequence&&(this.targetDecorator.shape="Arrow",this.sourceDecorator.shape="Diamond",i.id=this.id+this.shape.type),i},t.prototype.getUMLObjectFlow=function(){if(this.annotations)for(var e=0;e0&&(this.sourcePoint=o[0],this.targetPoint=o[o.length-1]),o},t.prototype.clipDecorator=function(e,i,r,s){var a,l,o={x:0,y:0},h=i.length,c=R.distancePoints(a=r?i[0]:i[h-1],l=r?i[1]:i[h-2]);c=0===c?1:c;var d=1,u=r?e.sourceWrapper:e.targetWrapper;u&&(d=u.style.strokeWidth,s&&s&ee.DecoratorPropertyChange&&(d=1));var f=d-1;return o.x=Math.round(a.x+f*(l.x-a.x)/c),o.y=Math.round(a.y+f*(l.y-a.y)/c),(r&&"None"!==e.sourceDecorator.shape||!r&&"None"!==e.targetDecorator.shape)&&(o=R.adjustPoint(o,l,!0,s&ee.DecoratorPropertyChange?0:d/2)),o},t.prototype.clipDecorators=function(e,i,r){return"None"!==e.sourceDecorator.shape&&(i[0]=this.clipDecorator(e,i,!0,r)),"None"!==e.targetDecorator.shape&&(i[i.length-1]=this.clipDecorator(e,i,!1,r)),i},t.prototype.updateSegmentElement=function(e,i,r,s){var o=new Ne,a=this.getSegmentPath(e,i,s);if("Bezier"===e.type){if(this.segments.length>0)for(var l=0;l0)if("Straight"===e.type&&e.segments.length<2)for(var o=0;o1)for(o=0;o0&&"Bezier"!==this.type)for(var f=0;f0&&(a=f0&&(p<2*this.cornerRadius?(l=R.adjustPoint(h[parseInt(f.toString(),10)],h[f+1],!0,p/2),f0&&(s=this.bridgePath(e,s,f),"Orthogonal"===e.type&&(s=this.bridgePath(e,s,f+1))),s+=" L"+a.x+" "+a.y))}else if("Bezier"===this.type){var g=void 0,v=void 0;if(this.parentObj.element){var y=this.parentObj.element.ej2_instances[0].eventHandler.action;g=this.parentObj.element.ej2_instances[0].eventHandler.tool instanceof Rd,v=y.includes("PortDraw")||y.includes("Drag")}for(var S=void 0,b=this.segments,M=0;M2&&(b[parseInt(M.toString(),10)].bezierPoint1={x:0,y:0},b[parseInt(M.toString(),10)].bezierPoint2={x:0,y:0}),!R.isEmptyPoint(b[parseInt(M.toString(),10)].point1)||b[parseInt(M.toString(),10)].vector1.angle||b[parseInt(M.toString(),10)].vector1.distance?b[parseInt(M.toString(),10)].vector1.angle||b[parseInt(M.toString(),10)].vector1.distance?b[parseInt(M.toString(),10)].bezierPoint1=R.transform(h[parseInt(M.toString(),10)],b[parseInt(M.toString(),10)].vector1.angle,b[parseInt(M.toString(),10)].vector1.distance):b[parseInt(M.toString(),10)].bezierPoint1={x:b[parseInt(M.toString(),10)].point1.x||b[parseInt(M.toString(),10)].bezierPoint1.x,y:b[parseInt(M.toString(),10)].point1.y||b[parseInt(M.toString(),10)].bezierPoint1.y}:((e.sourceID||this.sourcePortID)&&this.sourceWrapper&&!v&&!g&&(S=rF(this.sourceWrapper.bounds,h[parseInt(M.toString(),10)],!0)),b[parseInt(M.toString(),10)].bezierPoint1=KI(h[parseInt(M.toString(),10)],h[M+1],S)),!R.isEmptyPoint(b[parseInt(M.toString(),10)].point2)||b[parseInt(M.toString(),10)].vector2.angle||b[parseInt(M.toString(),10)].vector2.distance?b[parseInt(M.toString(),10)].vector2.angle||b[parseInt(M.toString(),10)].vector2.distance?b[parseInt(M.toString(),10)].bezierPoint2=R.transform(h[M+1],b[parseInt(M.toString(),10)].vector2.angle,b[parseInt(M.toString(),10)].vector2.distance):b[parseInt(M.toString(),10)].bezierPoint2={x:b[parseInt(M.toString(),10)].point2.x||b[parseInt(M.toString(),10)].bezierPoint2.x,y:b[parseInt(M.toString(),10)].point2.y||b[parseInt(M.toString(),10)].bezierPoint2.y}:((e.targetID||this.targetPortID)&&this.targetWrapper&&!v&&!g&&(S=rF(this.targetWrapper.bounds,h[M+1],!0)),b[parseInt(M.toString(),10)].bezierPoint2=KI(h[M+1],h[parseInt(M.toString(),10)],S));h.splice(1,0,{x:b[0].bezierPoint1.x,y:b[0].bezierPoint1.y}),h.splice(h.length-1,0,{x:b[b.length-1].bezierPoint2.x,y:b[b.length-1].bezierPoint2.y}),h=this.clipDecorators(e,h,r);for(var w=0;w0&&(s=this.bridgePath(e,s,D),s+=" L"+o.x+" "+o.y);return s},t.prototype.updateShapeElement=function(e){var i;switch(e.shape.type){case"Bpmn":e.wrapper.children[3]instanceof Ze&&(i=e.wrapper.children[3]),"Message"===e.shape.flow&&this.updateShapePosition(e,i);break;case"UmlActivity":"Exception"===e.shape.flow&&this.getUMLExceptionFlow(e.wrapper.children[0])}},t.prototype.updateShapePosition=function(e,i){var o=xF(this.intermediatePoints,i,.5);i.offsetX=o.x,i.offsetY=o.y},t.prototype.scale=function(e,i,r,s,o){var a=0,l=0;if(this.wrapper&&this.wrapper.outerBounds){var h=function T3(n){var t=n.wrapper.children[0].bounds;return"None"!==n.sourceDecorator.shape&&t.uniteRect(n.wrapper.children[1].bounds),"None"!==n.targetDecorator.shape&&t.uniteRect(n.wrapper.children[2].bounds),t}(this),c=Math.abs((this.wrapper.bounds.width||this.style.strokeWidth||1)-2),d=Math.abs((this.wrapper.bounds.height||this.style.strokeWidth||1)-2);a=h.width-c,l=h.height-d,e=Math.abs((r-Math.max(a,l))/c),i=Math.abs((s-Math.max(a,l))/d),a=l=Math.min(a,l)}e=i=Math.min(e,i);var u=Bi();qi(u,-(o=o||this.wrapper).rotateAngle,o.offsetX,o.offsetY),Xf(u,e,i,o.offsetX,o.offsetY),qi(u,o.rotateAngle,o.offsetX,o.offsetY);var f=function Uie(n,t){for(var e=[],i=0,r=t;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},tse=function(n){function t(e,i){var r=n.call(this,e,i)||this;return r.offset=0,r.scale=1,r}return ese(t,n),t.prototype.preRender=function(){this.unWireEvents(),this.wireEvents()},t.prototype.render=function(){this.updateRulerGeometry(),this.renderComplete()},t.prototype.getModuleName=function(){return"Ruler"},t.prototype.destroy=function(){this.unWireEvents(),this.notify("destroy",{}),n.prototype.destroy.call(this),this.element.classList.remove("e-ruler")},t.prototype.getPersistData=function(){return this.addOnPersist(["loaded"])},t.prototype.onPropertyChanged=function(e,i){for(var r=0,s=Object.keys(e);r100;)r/=10,s/=10;for(;s<25;)r*=10,s*=10;return s>=25&&s%25!=0&&(s=25*Math.round(s/25)),s*e/r},t.prototype.createMarkerLine=function(e,i,r){var s;return i&&((s=e.getElementById(i.id+"_marker"))&&s.parentNode.removeChild(s),s=Fi("line",r)),s},t.prototype.drawRulerMarker=function(e,i,r){var s,o,h,d,u="Horizontal"===this.orientation,f=e.getElementsByTagName("svg");for(h=0;h0)for(var a=i.childNodes.length-1;a>=0;a--)i.childNodes[parseInt(a.toString(),10)].parentNode.removeChild(i.childNodes[parseInt(a.toString(),10)]);i.appendChild(s)}return s},t.prototype.wireEvents=function(){},t.prototype.unWireEvents=function(){},kc([I(5)],t.prototype,"interval",void 0),kc([I(100)],t.prototype,"segmentWidth",void 0),kc([I("Horizontal")],t.prototype,"orientation",void 0),kc([I("RightOrBottom")],t.prototype,"tickAlignment",void 0),kc([I("red")],t.prototype,"markerColor",void 0),kc([I(25)],t.prototype,"thickness",void 0),kc([I(null)],t.prototype,"arrangeTick",void 0),kc([I(400)],t.prototype,"length",void 0),t}(Ii);function oF(n,t){var e=document.getElementById(n.element.id+(t?"_hRuler":"_vRuler")),i=Za(n),r=aF(n);e||(e=Tt("div",{id:n.element.id+(t?"_hRuler":"_vRuler"),style:"height:"+(t?i.height:r.height+100)+"px;overflow:hidden;width:"+(t?r.width+100:i.width)+"px;position:absolute;font-size:11px;"+(t?"margin-left:"+i.width+"px;":"margin-top:"+i.height+"px;")})),n.element.insertBefore(e,n.element.firstChild);var l=t?n.rulerSettings.horizontalRuler:n.rulerSettings.verticalRuler,h=new tse(l);h.orientation=t?"Horizontal":"Vertical",h.length=(t?r.width:r.height)+l.segmentWidth,h.appendTo("#"+n.element.id+(t?"_hRuler":"_vRuler")),t?n.hRuler=h:n.vRuler=h;var c=document.getElementById(n.element.id+(t?"_hRuler":"_vRuler"));t?n.hRuler.element=c:n.vRuler.element=c}function eb(n){var t=-n.scroller.horizontalOffset,e=-n.scroller.verticalOffset;n&&n.rulerSettings.showRulers?(n.hRuler.length=0,n.vRuler.length=0,void 0!==t&&n.hRuler.element&&lF(n,n.hRuler,t,!0),void 0!==e&&n.vRuler.element&&lF(n,n.vRuler,e,!1)):qx(n)}function qx(n){an(n.element.id+"_hRuler"),an(n.element.id+"_vRuler"),an(n.element.id+"_overlapRuler")}function Za(n){var t=0,e=0;return n.rulerSettings.showRulers&&(t=n.rulerSettings.horizontalRuler.thickness,e=n.rulerSettings.verticalRuler.thickness),new me(e,t)}function aF(n){var t=Za(n),e=n.scroller.viewPortHeight,i=n.scroller.viewPortWidth;return i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},hF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return ase(t,n),t.prototype.getClassName=function(){return"UserHandle"},Un([I("")],t.prototype,"name",void 0),Un([I("")],t.prototype,"pathData",void 0),Un([I("")],t.prototype,"content",void 0),Un([I("")],t.prototype,"source",void 0),Un([I("#000000")],t.prototype,"backgroundColor",void 0),Un([I("Top")],t.prototype,"side",void 0),Un([I("")],t.prototype,"borderColor",void 0),Un([I(.5)],t.prototype,"borderWidth",void 0),Un([I(25)],t.prototype,"size",void 0),Un([I("white")],t.prototype,"pathColor",void 0),Un([I(10)],t.prototype,"displacement",void 0),Un([I(!0)],t.prototype,"visible",void 0),Un([I(0)],t.prototype,"offset",void 0),Un([re({},Jn)],t.prototype,"margin",void 0),Un([I("Center")],t.prototype,"horizontalAlignment",void 0),Un([I("Center")],t.prototype,"verticalAlignment",void 0),Un([I(!1)],t.prototype,"disableNodes",void 0),Un([I(!1)],t.prototype,"disableConnectors",void 0),Un([re({},Td)],t.prototype,"tooltip",void 0),Un([I("")],t.prototype,"template",void 0),t}(Ee);function cF(n){return lse[n.toString()]}var lse={Action:"M 90 82.895 C 90 86.819 86.776 90 82.8 90 H 7.2 C 3.224 90 0 86.819 0 82.895 V 7.105 C 0 3.181 3.224 0 7.2 0 h 75.6 C 86.776 0 90 3.181 90 7.105 V 82.895 Z",Decision:"M10,19.707L0.293,10L10,0.293L19.707,10L10,19.707z",MergeNode:"M10,19.707L0.293,10L10,0.293L19.707,10L10,19.707z",InitialNode:"M10,19.5c-5.238,0-9.5-4.262-9.5-9.5S4.762,0.5,10,0.5s9.5,4.262,9.5,9.5S15.238,19.5,10,19.5z",ForkNode:"m0.75,0.75l636.00002,0l0,290l-636.00002,0l0,-290z",JoinNode:"m0.75,0.75l636.00002,0l0,290l-636.00002,0l0,-290z",TimeEvent:"M50.001,0.00286865 L25.001,25.0029 L0.000976562,0.00286865 L50.001,0.00286865 z M0.000976562,50.0029 L25.001,25.0029 L50.001,50.0029 L0.000976562,50.0029 z",AcceptingEvent:"M17.8336 32.164 L29.64 24 L17.32 16 L48.1664 16 L48.5 32 Z",SendSignal:"M48.164 31.8336 L56 23.832 L47.836 16 L16.168 16 L16.1668 31.8336 Z",ReceiveSignal:"M48.1664 31.8336 L39.836 24 L47.836 16 L16.168 16 L16.168 31.836 Z",StructuredNode:"M0,0 L50,0 L50,50 L0,50 z",Note:"M20 12 L4 12 L4 22 L22 22 L22 14 L20 14 L20 12 L22 14 Z"},tb=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Ja=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},hse=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return tb(t,n),Ja([I()],t.prototype,"key",void 0),Ja([I()],t.prototype,"keyModifiers",void 0),t}(Ee),dF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return tb(t,n),t.prototype.getClassName=function(){return"Command"},Ja([I("")],t.prototype,"name",void 0),Ja([I()],t.prototype,"canExecute",void 0),Ja([I()],t.prototype,"execute",void 0),Ja([re({},hse)],t.prototype,"gesture",void 0),Ja([I("")],t.prototype,"parameter",void 0),t}(Ee),cse=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return tb(t,n),Ja([Bt([],dF)],t.prototype,"commands",void 0),t}(Ee),dse=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return tb(t,n),Ja([I()],t.prototype,"show",void 0),Ja([I()],t.prototype,"showCustomMenuOnly",void 0),Ja([I()],t.prototype,"items",void 0),t}(Ee),Kf=function(){function n(){}return n.prototype.renderShadow=function(t,e,i,r){void 0===i&&(i=null);var l,o=R.transform({x:0,y:0},t.shadow.angle,t.shadow.distance);r&&(l=r.getElementById(e.id+"_shadow")),l||(l=document.createElementNS("http://www.w3.org/2000/svg",i?"path":"rect"),e.appendChild(l));var h={id:e.id+"_shadow",fill:t.shadow.color,stroke:t.shadow.color,opacity:t.shadow.opacity.toString(),transform:"rotate("+t.angle+","+(t.x+t.width*t.pivotX)+","+(t.y+t.height*t.pivotY)+")translate("+(t.x+o.x)+","+(t.y+o.y)+")"};if(r){var c=r.getElementById(e.id);c&&c.insertBefore(l,c.firstChild)}ti(l,h),i?i&&this.renderPath(l,t,i):ti(l,{width:t.width,height:t.height})},n.prototype.parseDashArray=function(t){return[]},n.prototype.drawRectangle=function(t,e,i,r,s,o,a,l,h){var c,d,u,f;e.shadow&&!r&&this.renderShadow(e,t,void 0,o),c=e.id===t.id?e.id+"_container":e.id,o&&(d=o.getElementById(c)),(!d||s)&&(d=document.createElementNS("http://www.w3.org/2000/svg","rect"),t.appendChild(d)),o&&!e.shadow&&(u=o.getElementById(e.id+"_groupElement_shadow"))&&u.parentNode.removeChild(u),f=l?{id:c,x:e.x.toString(),y:e.y.toString(),width:e.width.toString(),height:e.height.toString(),visibility:e.visible?"visible":"hidden",transform:"rotate("+e.angle+","+(e.x+e.width/2)+","+(e.y+e.height/2)+")",rx:e.cornerRadius||0,ry:e.cornerRadius||0,opacity:e.opacity}:{id:c,x:e.x.toString(),y:e.y.toString(),width:e.width.toString(),height:e.height.toString(),visibility:e.visible?"visible":"hidden",transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")",rx:e.cornerRadius||0,ry:e.cornerRadius||0,opacity:e.opacity},a&&(f.role="img",f["aria-label"]=a);var p=e.class||"";h||(p.includes("e-diagram-resize-handle")||p.includes("e-diagram-endpoint-handle")||p.includes("e-diagram-bezier-control-handle"))&&(p+=" e-disabled"),e.class&&(f.class=p),a||(f["pointer-events"]="none"),ti(d,f),this.setSvgStyle(d,e,i)},n.prototype.updateSelectionRegion=function(t,e){var i;i=t.parentNode.getElementById(e.id);var r={id:e.id,x:e.x.toString(),y:e.y.toString(),width:e.width.toString(),height:e.height.toString(),transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")",class:"e-diagram-selected-region"};i||(i=document.createElementNS("http://www.w3.org/2000/svg","rect"),t.appendChild(i)),this.setSvgStyle(i,e),ti(i,r)},n.prototype.createGElement=function(t,e){return Fi(t,e)},n.prototype.drawLine=function(t,e){var i=document.createElementNS("http://www.w3.org/2000/svg","line");this.setSvgStyle(i,e);var r=e.x+e.width*e.pivotX,s=e.y+e.height*e.pivotY,o={id:e.id,x1:e.startPoint.x+e.x,y1:e.startPoint.y+e.y,x2:e.endPoint.x+e.x,y2:e.endPoint.y+e.y,stroke:e.stroke,"stroke-width":e.strokeWidth.toString(),opacity:e.opacity.toString(),transform:"rotate("+e.angle+" "+r+" "+s+")",visibility:e.visible?"visible":"hidden"};e.class&&(o.class=e.class),ti(i,o),t.appendChild(i)},n.prototype.drawCircle=function(t,e,i,r){var s=document.createElementNS("http://www.w3.org/2000/svg","circle");this.setSvgStyle(s,e);var o=e.class||"";i||(o+=" e-disabled");var a={id:e.id,cx:e.centerX,cy:e.centerY,r:e.radius,visibility:e.visible?"visible":"hidden",class:o};r&&(a.role="img",a["aria-label"]=r),s.style.display=e.visible?"block":"none",ti(s,a),t.appendChild(s)},n.prototype.drawPath=function(t,e,i,r,s,o,a){var h,c,l=[];l=e3(l=xd(e.data)),e.shadow&&this.renderShadow(e,t,l,s),s&&!e.shadow&&(h=s.getElementById(e.id+"_groupElement_shadow"))&&h.parentNode.removeChild(h),s&&(c=s.getElementById(e.id)),(!c||r)&&(c=document.createElementNS("http://www.w3.org/2000/svg","path"),t.appendChild(c)),this.renderPath(c,e,l);var d={};d=a?{id:e.id,transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")translate("+e.x+","+e.y+"),scale("+a+")",visibility:e.visible?"visible":"hidden",opacity:e.opacity}:{id:e.id,transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")translate("+e.x+","+e.y+")",visibility:e.visible?"visible":"hidden",opacity:e.opacity},o&&(d.role="img",d["aria-label"]=o),e.class&&(d.class=e.class),ti(c,d),this.setSvgStyle(c,e,i)},n.prototype.renderPath=function(t,e,i){var r,s,o,a,l,h,c,d,u=i,f="";for(l=0,h=0,d=0,c=u.length;de.width&&"Wrap"!==e.textOverflow&&"NoWrap"===e.textWrapping&&(h[0].text=qF(e.content,e)),v=0;vD&&(u.text=u.text.slice(0,u.text.length-3),u.text=u.text.concat("..."),l.data=u.text),this.alignText(y,f,u,l,p,g,v,e,h),C+=u.dy}}C&&e.isHorizontalLane&&(M=e.parentOffsetX+e.pivotX,w=e.parentOffsetY+e.pivotY,e.y=e.parentOffsetY-C*e.pivotY+.5),e.textDecoration&&"LineThrough"===e.textDecoration&&(e.textDecoration=gb(e.textDecoration));var P={id:e.id+"_text",fill:e.color,visibility:e.visible?"visible":"hidden","text-decoration":e.textDecoration,transform:"rotate("+e.angle+","+M+","+w+")translate("+e.x+","+e.y+")",opacity:e.opacity};r&&(P.role="img",P["aria-label"]=r),ti(y,P)}},n.prototype.alignText=function(t,e,i,r,s,o,a,l,h){"justify"!==l.textAlign?this.setText(t,e,i,r,s,o,l):a!==h.length-1?this.setText(t,e,i,r,s,o,l,l.width,"spacing"):this.setText(t,e,i,r,s,o,l)},n.prototype.setText=function(t,e,i,r,s,o,a,l,h){ti(e,"justify"!==a.textAlign?{x:s.toString(),y:o.toString()}:{x:s.toString(),y:o.toString(),textLength:l||0,lengthAdjust:h||"spacing"}),t.setAttribute("fill",i.text),e.appendChild(r),t.appendChild(e)},n.prototype.drawImage=function(t,e,i,r){var s;i&&(s=i.getElementById(e.id+"image")),s||(s=document.createElementNS("http://www.w3.org/2000/svg","image"),t.appendChild(s));var o=new Image;o.src=e.source;var a="None"!==e.scale?e.scale:"",l=e.alignment,h=l.charAt(0).toLowerCase()+l.slice(1);"Stretch"!==a&&(h+=" "+a.charAt(0).toLowerCase()+a.slice(1)),ti(s,{id:e.id+"image",x:e.x.toString(),y:e.y.toString(),transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")",width:e.width.toString(),visibility:e.visible?"visible":"hidden",height:e.height.toString(),preserveAspectRatio:h,opacity:e.opacity.toString()}),s.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",o.src.toString())},n.prototype.drawHTMLContent=function(t,e,i,r,s){var o,a;if(e&&(o=e.querySelector("#"+t.id+"_html_element")),!o){(a=e.querySelector("#"+t.id+"_html_element")||e.querySelector("#"+t.nodeId+"_html_element"))||(a=Tt("div",{id:t.nodeId+"_html_element",class:"foreign-object"})),o=Tt("div",{id:t.id+"_html_element",class:"foreign-object"});var c=document.getElementById(t.diagramId).ej2_instances[0],d=!1;if(e.parentNode&&e.parentNode.parentNode&&e.parentNode.parentNode.parentNode&&e.parentNode.parentNode.parentNode.classList.contains("e-overview")&&(d=!0),d)c.isReact?c.renderReactTemplates(function(){o.appendChild(t.template.cloneNode(!0))}):o.appendChild(t.template.cloneNode(!0));else{if("string"==typeof t.template){var u=document.createElement("div");u.innerHTML=t.template,t.template=u,c.selectedItems.userHandles.filter(function(g){return g.name===t.id.split("_shape")[0]&&""!==g.template})[0].template=t.template}t.isTemplate&&t.template?o.appendChild(t.template):t.template&&o.appendChild(t.template.cloneNode(!0))}void 0!==s&&e.childNodes.length>s&&e.insertBefore(o,e.childNodes[parseInt(s.toString(),10)]),a.appendChild(o),e.appendChild(a)}var p=xn(t).topLeft;o.setAttribute("style","height:"+t.actualSize.height+"px; width:"+t.actualSize.width+"px;left:"+p.x+"px; top:"+p.y+"px;position:absolute;transform:rotate("+(t.rotateAngle+t.parentTransform)+"deg);pointer-events:"+(r?"all":"none")+";visibility:"+(t.visible?"visible":"hidden")+";opacity:"+t.style.opacity+";")},n.prototype.drawNativeContent=function(t,e,i,r,s){var o,a;if(s&&(o=s.getElementById(t.id+"_native_element"),a=s.getElementById(t.id+"_clip")),!o){(o=document.createElementNS("http://www.w3.org/2000/svg","g")).setAttribute("id",t.id+"_native_element"),o.appendChild(t.template.cloneNode(!0));var l=this.createGElement("g",{id:t.id+"_inner_native_element"});l.appendChild(o),e.appendChild(l)}a&&o.removeChild(a),o.setAttribute("style","visibility:"+(t.visible?"visible":"hidden")+";opacity:"+t.style.opacity+";"),this.setNativTransform(t,o,i,r),"Slice"===t.scale&&this.drawClipPath(t,o,i,r,s),ti(o,t.description?{role:"img","aria-label":t.description}:{})},n.prototype.setNativTransform=function(t,e,i,r){var s=0!==t.contentSize.width?t.contentSize.width:1,o=0!==t.contentSize.height?t.contentSize.height:1;e.setAttribute("transform","rotate("+t.parentTransform+","+t.offsetX+","+t.offsetY+") translate("+(t.offsetX-t.templatePosition.x*r/s-r*t.pivot.x)+","+(t.offsetY-t.templatePosition.y*i/o-i*t.pivot.y)+") scale("+r/s+","+i/o+")")},n.prototype.drawClipPath=function(t,e,i,r,s){var o=t.contentSize.width,a=t.contentSize.height,l=t.width/(r/o),h=t.height/(i/a),c=t.templatePosition.x+(t.width>=t.height?0:(o-l)/2),d=t.templatePosition.y+(t.height>=t.width?0:(a-h)/2),u=s.getElementById(t.id+"_clip");(u=document.createElementNS("http://www.w3.org/2000/svg","clipPath")).setAttribute("id",t.id+"_clip"),e.appendChild(u);var f=s.getElementById(t.id+"_clip_rect");return f=document.createElementNS("http://www.w3.org/2000/svg","rect"),u.appendChild(f),ti(f,{id:t.id+"_clip_rect",width:l.toString(),height:h.toString(),x:c.toString(),y:d.toString()}),lm()?e.setAttribute("clip-path","url("+location.protocol+"//"+location.host+location.pathname+"#"+t.id+"_clip)"):e.setAttribute("clip-path","url(#"+t.id+"_clip)"),e},n.prototype.renderGradient=function(t,e,i){var r,s,o,h,c,a=IT(i),l=a.getElementById(i+"gradient_pattern");if(l||(l=Fi("defs",{id:i+"gradient_pattern"}),a.insertBefore(l,a.firstChild)),bF(e.id),"None"!==t.gradient.type){for(var d=0;dt.width&&("Ellipsis"===t.textOverflow||"Clip"===t.textOverflow)&&"NoWrap"===t.textWrapping?0:.5*t.width:"right"===t.textAlign&&(c=1*t.width),s.x=0+c+(e?e.x:0),s.y=1.2+d-r.height/2,s},n}(),Pc=function(){function n(t,e,i){this.renderer=null,this.isSvgMode=!0,this.touchMove=void 0,this.transform={x:0,y:0},this.diagramId=t,this.element=xt(this.diagramId),this.svgRenderer=e,this.isSvgMode=i,this.renderer=i?new Kf:new bo}return n.prototype.setCursor=function(t,e){t.style.cursor=e},n.prototype.setLayers=function(){this.iconSvgLayer=this.element.getElementsByClassName("e-ports-expand-layer")[0],this.adornerSvgLayer=this.element.getElementsByClassName("e-adorner-layer")[0],this.nativeSvgLayer=this.element.getElementsByClassName("e-native-layer")[0],this.diagramSvgLayer=this.element.getElementsByClassName("e-diagram-layer")[0]},n.prototype.getAdornerLayer=function(){return yT(this.diagramId)},n.prototype.getParentSvg=function(t,e,i){return this.diagramId&&t&&t.id?t.id.split("_icon_content").length>1||t.id.split("_nodeport").length>1||t.elementActions&Xr.ElementIsPort?this.iconSvgLayer:e&&"selector"===e?this.adornerSvgLayer:t instanceof En?this.nativeSvgLayer:this.diagramSvgLayer:i},n.prototype.getParentElement=function(t,e,i,r){var s=e;if(i&&this.diagramId&&t&&t.id){t.id.split("_icon_content").length>1?(s=i.getElementById(this.diagramId+"_diagramExpander"),e=null):t.id.split("_nodeport").length>1?s=i.getElementById(this.diagramId+"_diagramPorts"):t instanceof En?(s=i.getElementById(this.diagramId+"_nativeLayer"),e=null):t.elementActions&Xr.ElementIsPort?(s=i.getElementById(this.diagramId+"_diagramPorts"),e=null):s=i.getElementById(this.diagramId+"_diagramLayer");var o=this.getGroupElement(t,e||s,r);s=o.g,o.svg&&(i=o.svg)}return{g:s,svg:i}},n.prototype.getGroupElement=function(t,e,i){var r,o,s=this.getParentSvg(t);if(e&&s){if(s&&!(r=s.getElementById(t.id+"_groupElement"))&&s!==this.nativeSvgLayer){var a=this.nativeSvgLayer;r=a.getElementById(t.id+"_groupElement"),o=a}r||(r=this.svgRenderer.createGElement("g",{id:t.id+"_groupElement"}),void 0!==i&&e.childNodes.length>i?e.insertBefore(r,e.childNodes[parseInt(i.toString(),10)]):e.appendChild(r))}return{g:r,svg:o}},n.prototype.renderElement=function(t,e,i,r,s,o,a,l,h,c,d){t instanceof Cs?(t.id=t.id?t.id:Qe(),this.renderContainer(t,e,i,r,s,o,a,l,h,c,d)):t instanceof DI?this.renderImageElement(t,e,r,s,a):t instanceof Ze?this.renderPathElement(t,e,r,s,a,h,d):t instanceof ai?this.renderTextElement(t,e,r,s,a,c):t instanceof En?this.renderNativeElement(t,e,r,s,a):t instanceof es?this.renderHTMLElement(t,e,i,r,s,a,l):this.renderRect(t,e,r,s,h)},n.prototype.drawSelectionRectangle=function(t,e,i,r,s,o){var a={width:i*o.scale,height:r*o.scale,x:.5+(t=(t+o.tx)*o.scale),y:.5+(e=(e+o.ty)*o.scale),fill:"transparent",stroke:"gray",angle:0,pivotX:.5,pivotY:.5,strokeWidth:1,dashArray:"6 3",opacity:1,visible:!0,id:s.id+"_selected_region"},l=this.getAdornerLayer();this.svgRenderer.updateSelectionRegion(l,a)},n.prototype.renderHighlighter=function(t,e,i){var r=t.actualSize.width||2,s=t.actualSize.height||2,o=t.offsetX-r*t.pivot.x,a=t.offsetY-s*t.pivot.y;this.svgRenderer.drawRectangle(e,{width:r*i.scale,height:s*i.scale,x:o=(o+i.tx)*i.scale,y:a=(a+i.ty)*i.scale,fill:"transparent",stroke:"#8CC63F",angle:t.rotateAngle,pivotX:t.pivot.x,pivotY:t.pivot.y,strokeWidth:4,dashArray:"",opacity:1,cornerRadius:0,visible:!0,id:e.id+"_highlighter",class:"e-diagram-highlighter"},this.diagramId,void 0,void 0,e)},n.prototype.renderSelectionRectangle=function(t,e,i,r){var s=t.actualSize.width||2,o=t.actualSize.height||2,a=t.offsetX-s*t.pivot.x,l=t.offsetY-o*t.pivot.y,h={width:s*i.scale,height:o*i.scale,x:a=(a+i.tx)*i.scale,y:l=(l+i.ty)*i.scale,fill:"transparent",stroke:"#00cc00",angle:t.rotateAngle,pivotX:t.pivot.x,pivotY:t.pivot.y,strokeWidth:r?2:1,dashArray:"",opacity:1,cornerRadius:0,visible:!0,id:t.id+"_highlighter",class:r?"e-diagram-first-selection-indicator e-diagram-selection-indicator":"e-diagram-selection-indicator"},c=this.getParentSvg(t,"selector");this.svgRenderer.drawRectangle(e,h,this.diagramId,void 0,void 0,c)},n.prototype.renderSelectionLine=function(t,e,i,r){var s=this.getBaseAttributes(t,i);s.data=t.absolutePath,s.id=s.id+"_highlighter";var o=t.description?t.description:t.id;this.isSvgMode||(s.x=t.flipOffset.x?t.flipOffset.x:s.x,s.y=t.flipOffset.y?t.flipOffset.y:s.y),i&&(s.x=s.x*i.scale,s.y=s.y*i.scale),s.stroke="#00cc00",s.strokeWidth=r?2:1,s.class=r?"e-diagram-first-selection-indicator e-diagram-selection-indicator":"e-diagram-selection-indicator";var a=this.getParentSvg(t,"selector");this.svgRenderer.drawPath(e,s,this.diagramId,void 0,a,o,i.scale)},n.prototype.renderStackHighlighter=function(t,e,i,r,s,o,a){var l=t.actualSize.width||2,h=t.offsetX-l*t.pivot.x,c=t.actualSize.height||2,d=t.offsetY-c*t.pivot.y;h=(h+i.tx)*i.scale;var u,f=t.bounds,p="";if(d=(d+i.ty)*i.scale,r)if(o){var v,y;u="M 0 0 L "+(2+(g=l*i.scale))+" 0 Z",v=t.actualSize.width/Number(f.width?f.width:1)*i.scale,y=t.actualSize.height/Number(f.height?f.height:1)*i.scale,p=bI(MI(xd("M7,4 L8,4 8,7 11,7 11,8 8,8 8,11 7,11 7,8 4,8 4,7 7,7 z M7.5,0.99999994C3.9160004,1 1,3.9160004 0.99999994,7.5 1,11.084 3.9160004,14 7.5,14 11.084,14 14,11.084 14,7.5 14,3.9160004 11.084,1 7.5,0.99999994 z M7.5,0 C11.636002,0 15,3.3639984 15,7.5 15,11.636002 11.636002,15 7.5,15 3.3640003,15 0,11.636002 0,7.5 0,3.3639984 3.3640003,0 7.5,0 z")),v+g+2,y-8,!1,f.x,f.y,0,0),s.y>=t.offsetY&&(d+=c)}else{var g;a&&s.y>=t.offsetY&&(d+=c*i.scale),u="M -10 -10 L 0 0 Z M -10 10 L 0 0 Z M 0 0 L "+(g=l*i.scale)+" 0 Z M "+g+" 0 L "+(g+10)+" 10 Z L "+(g+10)+" -10 Z"}else u="M 10 -10 L 0 0 Z M -10 -10 L 0 0 Z M 0 0 L 0 "+(g=c*i.scale)+" Z M 0 "+g+" L -10 "+(g+10)+" Z L 10 "+(g+10)+" Z",s.x>=t.offsetX&&(h+=l*i.scale);this.svgRenderer.drawPath(e,{data:u+p,width:l*i.scale,height:c*i.scale,x:h,y:d,fill:"transparent",stroke:"#8CC63F",angle:t.rotateAngle,pivotX:t.pivot.x,pivotY:t.pivot.y,strokeWidth:1,dashArray:"",opacity:1,visible:!0,id:e.id+"_stack_highlighter",class:"e-diagram-highlighter"},this.diagramId)},n.prototype.drawLine=function(t,e){this.svgRenderer.drawLine(t,e)},n.prototype.drawPath=function(t,e){this.svgRenderer.drawPath(t,e,this.diagramId)},n.prototype.renderResizeHandle=function(t,e,i,r,s,o,a,l,h,c,d){var u=t.offsetX-t.actualSize.width*t.pivot.x,f=t.offsetY-t.actualSize.height*t.pivot.y,p=t.actualSize.height,g=t.actualSize.width;if(!c&&i&bt.Rotate&&jI(this.rendererActions)&&!z3(this.rendererActions))this.renderPivotLine(t,e,o,s,a),this.renderRotateThumb(t,e,o,s,a);else if(this.touchMove){var v=document.getElementById("rotateThumb");v&&v.setAttribute("visibility","hidden")}this.renderBorder(t,e,o,l,h,c);var y=t.actualSize.width*r,S=t.actualSize.height*r;!h&&jI(this.rendererActions)&&!z3(this.rendererActions)&&(t.isTextAnnotation||(y>=40&&S>=40&&(s&mr.ResizeNorthWest&&this.renderCircularHandle("resizeNorthWest",t,u,f,e,qr(s,"ResizeNorthWest"),i&bt.ResizeNorthWest,o,void 0,a,{"aria-label":"Thumb to resize the selected object on top left side direction"},void 0,"e-diagram-resize-handle e-northwest",d),s&mr.ResizeNorthEast&&this.renderCircularHandle("resizeNorthEast",t,u+g,f,e,qr(s,"ResizeNorthEast"),i&bt.ResizeNorthEast,o,void 0,a,{"aria-label":"Thumb to resize the selected object on top right side direction"},void 0,"e-diagram-resize-handle e-northeast",d),s&mr.ResizeSouthWest&&this.renderCircularHandle("resizeSouthWest",t,u,f+p,e,qr(s,"ResizeSouthWest"),i&bt.ResizeSouthWest,o,void 0,a,{"aria-label":"Thumb to resize the selected object on bottom left side direction"},void 0,"e-diagram-resize-handle e-southwest",d),s&mr.ResizeSouthEast&&this.renderCircularHandle("resizeSouthEast",t,u+g,f+p,e,qr(s,"ResizeSouthEast"),i&bt.ResizeSouthEast,o,void 0,a,{"aria-label":"Thumb to resize the selected object on bottom right side direction"},void 0,"e-diagram-resize-handle e-southeast",d)),s&mr.ResizeNorth&&this.renderCircularHandle("resizeNorth",t,u+g/2,f,e,qr(s,"ResizeNorth"),i&bt.ResizeNorth,o,void 0,a,{"aria-label":"Thumb to resize the selected object on top side direction"},void 0,"e-diagram-resize-handle e-north",d),s&mr.ResizeSouth&&this.renderCircularHandle("resizeSouth",t,u+g/2,f+p,e,qr(s,"ResizeSouth"),i&bt.ResizeSouth,o,void 0,a,{"aria-label":"Thumb to resize the selected object on bottom side direction"},void 0,"e-diagram-resize-handle e-south",d),s&mr.ResizeWest&&this.renderCircularHandle("resizeWest",t,u,f+p/2,e,qr(s,"ResizeWest"),i&bt.ResizeWest,o,void 0,a,{"aria-label":"Thumb to resize the selected object on left side direction"},void 0,"e-diagram-resize-handle e-west",d),s&mr.ResizeEast&&this.renderCircularHandle("resizeEast",t,u+g,f+p/2,e,qr(s,"ResizeEast"),i&bt.ResizeEast,o,void 0,a,{"aria-label":"Thumb to resize the selected object on right side direction"},void 0,"e-diagram-resize-handle e-east",d)))},n.prototype.renderEndPointHandle=function(t,e,i,r,s,o,a,l,h,c){var p,g,d=t.sourcePoint,u=t.targetPoint,f=t.wrapper;if(this.renderCircularHandle("connectorSourceThumb",f,d.x,d.y,e,qr(r,"ConnectorSourceThumb"),i&bt.ConnectorSource,s,o,void 0,{"aria-label":"Thumb to move the source point of the connector"},void 0,"e-diagram-endpoint-handle e-sourceend",c),this.renderCircularHandle("connectorTargetThumb",f,u.x,u.y,e,qr(r,"ConnectorTargetThumb"),i&bt.ConnectorTarget,s,a,void 0,{"aria-label":"Thumb to move the target point of the connector"},void 0,"e-diagram-endpoint-handle e-targetend",c),l)if("Straight"===t.type&&t.segments.length>0)for(p=0;p0)for(p=0;p=3&&3===t.segments.length&&(S=1,b=t.segments.length-1),S=t.segments.length>t.maxSegmentThumb+2?2:S,b=t.segments.length>t.maxSegmentThumb+2?t.segments.length-2:b,1===t.segments.length&&t.segments[0].points.length<=2&&(S=1,b=t.segments.length),p=S;p=50&&i.allowDrag),this.renderOrthogonalThumb(t+"_"+(d+1),e,(i.points[parseInt(d.toString(),10)].x+i.points[d+1].x)/2,(i.points[parseInt(d.toString(),10)].y+i.points[d+1].y)/2,r,h,l,o,a,u)}else for(d=0;d=50&&i.allowDrag),this.renderOrthogonalThumb(t+"_"+(d+1),e,(i.points[parseInt(d.toString(),10)].x+i.points[d+1].x)/2,(i.points[parseInt(d.toString(),10)].y+i.points[d+1].y)/2,r,h,l,o,a,u)},n.prototype.renderOrthogonalThumb=function(t,e,i,r,s,o,a,l,h,c){var d,g,u=0,f=document.getElementById(this.diagramId);f&&(g=f.ej2_instances[0]);var y=h.constraints&qe.InheritSegmentThumbShape?g.segmentThumbShape:h.segmentThumbShape,b=h.constraints&qe.InheritSegmentThumbSize?g.segmentThumbSize:h.segmentThumbSize;if(d="horizontal"===a?function ure(n){return vre[""+n]}(y):c3(y),"Arrow"===y||"DoubleArrow"===y||"OpenArrow"===y)switch(c){case"Bottom":case"Right":u=180;break;default:u=0}else if("Fletch"===y||"OpenFetch"===y||"IndentedArrow"===y||"OutdentedArrow"===y)switch(c){case"Bottom":u=-90;break;case"Top":u=90;break;case"Right":u=180;break;default:u=0}var M={x:(i+l.tx)*l.scale-b/2,y:(r+l.ty)*l.scale-b/2,angle:u,fill:"#e2e2e2",stroke:"black",strokeWidth:1,dashArray:"",data:d,width:b,height:b,pivotX:.5,pivotY:.5,opacity:1,visible:o,id:t,class:"e-diagram-ortho-segment-handle"},w=ap(M.data),C=new me(M.width,M.height),D=new Ze;if(M.data=D.updatePath(M.data,w,C),this.touchMove){var A=document.getElementById(t);A?this.updateSegmentPosition(A,M):this.svgRenderer.drawPath(s,M,this.diagramId)}else this.svgRenderer.drawPath(s,M,this.diagramId)},n.prototype.renderPivotLine=function(t,e,i,r,s){var o=t,l=!!(r&mr.Rotate);s&&(l=!1);var h=this.getBaseAttributes(o,i);h.fill="None",h.stroke="black",h.strokeWidth=1,h.dashArray="2,3",h.visible=l;var c=i.scale;h.x*=c,h.y*=c,h.width*=c,h.height*=c,h.id="pivotLine",h.class="e-diagram-pivot-line";var u={x:o.actualSize.width*o.pivot.x*c,y:0};h.startPoint={x:o.actualSize.width*o.pivot.x*c,y:-20},h.endPoint=u,this.svgRenderer.drawLine(e,h)},n.prototype.renderBezierLine=function(t,e,i,r,s,o){var l=this.getBaseAttributes(e,o);l.id=t,l.stroke="black",l.strokeWidth=1,l.dashArray="3,3",l.fill="None",l.class="e-diagram-bezier-control-line",l.x=0,l.y=0;var h=o.scale,g={x:(s.x+o.tx)*h,y:(s.y+o.ty)*h};l.startPoint={x:(r.x+o.tx)*h,y:(r.y+o.ty)*h},l.endPoint=g,this.svgRenderer.drawLine(i,l)},n.prototype.renderCircularHandle=function(t,e,i,r,s,o,a,l,h,c,d,u,f,p){var g=e,v={x:i,y:r};if(0!==g.rotateAngle||0!==g.parentTransform){var y=Bi();qi(y,g.rotateAngle+g.parentTransform,g.offsetX,g.offsetY),v=Ke(y,v)}var S=this.getBaseAttributes(g);if(S.stroke="black",S.strokeWidth=1,void 0!==u?(S.id="segmentEnd_"+u,S.fill="#e2e2e2"):S.fill=h?"#8CC63F":"white",S.cornerRadius=p/2,S.angle=e.rotateAngle,S.id=t,S.visible=o,S.class=f,S.width=p,S.height=p,S.x=(v.x+l.tx)*l.scale,S.y=(v.y+l.ty)*l.scale,S.x=S.x-S.width/2,S.y=S.y-S.height/2,h&&(S.class+=" e-connected"),c&&(S.visible=!1),this.touchMove){var b=document.getElementById(t);if(b)this.updateResizeHandle(b,S);else{var M=this.getParentSvg(e,"selector");this.svgRenderer.drawRectangle(s,S,this.diagramId,!0,!0,M,d,!0,a)}}else M=this.getParentSvg(e,"selector"),this.svgRenderer.drawRectangle(s,S,this.diagramId,!0,!0,M,d,!0,a)},n.prototype.updateResizeHandle=function(t,e){ti(t,{id:e.id,x:e.x.toString(),y:e.y.toString(),width:e.width.toString(),height:e.height.toString(),visibility:e.visible?"visible":"hidden",transform:"rotate("+e.angle+","+(e.x+e.width/2)+","+(e.y+e.height/2)+")",rx:e.cornerRadius||0,ry:e.cornerRadius||0,opacity:e.opacity})},n.prototype.renderBezierHandle=function(t,e,i,r,s,o,a,l,h,c,d,u,f){var v,p=document.getElementById(this.diagramId);p&&(v=p.ej2_instances[0]);var y=e,S={x:i,y:r};if(0!==y.rotateAngle||0!==y.parentTransform){var b=Bi();qi(b,y.rotateAngle+y.parentTransform,y.offsetX,y.offsetY),S=Ke(b,S)}var D=a.constraints&qe.InheritSegmentThumbSize?v.segmentThumbSize:a.segmentThumbSize,A=c3(a.constraints&qe.InheritSegmentThumbShape?v.segmentThumbShape:a.segmentThumbShape),x=this.getBaseAttributes(y);x.stroke="black",x.strokeWidth=1,void 0!==d?(x.id="segmentEnd_"+d,x.fill="#e2e2e2"):x.fill=h?"#8CC63F":"white",x.angle=e.rotateAngle,x.id=t,x.visible=o,x.class=u,x.width=D,x.height=D,x.data=A,x.x=(S.x+l.tx)*l.scale,x.y=(S.y+l.ty)*l.scale,x.x=x.x-x.width/2,x.y=x.y-x.height/2,h&&(x.class+=" e-connected"),c&&(x.visible=!1);var P=ap(x.data),L=new me(x.width,x.height),O=new Ze;if(x.data=O.updatePath(x.data,P,L),this.touchMove){var N=document.getElementById(t);if(N)this.updateSegmentPosition(N,x);else{var T=this.getParentSvg(e,"selector");this.svgRenderer.drawPath(s,x,this.diagramId,!0,T)}}else T=this.getParentSvg(e,"selector"),this.svgRenderer.drawPath(s,x,this.diagramId,!0,T)},n.prototype.updateSegmentPosition=function(t,e){ti(t,{id:e.id,transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")translate("+e.x+","+e.y+")",visibility:e.visible?"visible":"hidden",opacity:e.opacity})},n.prototype.renderBorder=function(t,e,i,r,s,o){var l=this.getBaseAttributes(t,i);l.x*=i.scale,l.y*=i.scale,l.width*=i.scale,l.height*=i.scale,l.fill="transparent",l.stroke="#097F7F",l.strokeWidth=1.2,l.gradient=null,l.dashArray="6,3",l.class="e-diagram-selector",o&&(l.class+=" e-diagram-lane"),l.id="borderRect",l.id=this.rendererActions&Ga.DrawSelectorBorder?"borderRect_symbol":"borderRect",r||(l.class+=" e-disabled"),s&&(l.class+=" e-thick-border"),l.cornerRadius=0;var h=this.getParentSvg(t,"selector");this.svgRenderer.drawRectangle(e,l,this.diagramId,void 0,!0,h)},n.prototype.renderUserHandler=function(t,e,i,r,s,o){for(var l,a=t.wrapper,h=0,c=t.userHandles;h0||d.disableNodes&&t.nodes.length>0||"Drag"===s&&o)&&(l=!1);var u=document.getElementById(d.name+"_template_hiddenUserHandle");u&&(d.template=u.childNodes[0].cloneNode(!0));var f=iT(t,d,i);if(f.x=(f.x+i.tx)*i.scale,f.y=(f.y+i.ty)*i.scale,d.visible&&(d.visible=!!(t.constraints&mr.UserHandle)),l)if(d.pathData){var p=d.pathData?d.pathData:d.content,g=this.getBaseAttributes(a);g.id=d.name+"_userhandle",g.fill=d.backgroundColor,g.stroke=d.borderColor,g.strokeWidth=d.borderWidth,g.centerX=f.x,g.centerY=f.y,g.radius=.5*d.size,g.class="e-diagram-userhandle-circle",g.angle=0,g.visible=d.visible,g.opacity=1,this.svgRenderer.drawCircle(e,g,1,{"aria-label":d.name+"user handle"});var y=[];y=MI(y=xd(p));var S=ap(p),w=bI(y,(d.size-.45*d.size)/S.width,(d.size-.45*d.size)/S.height,!0,S.x,S.y,0,0);S=ap(w),this.svgRenderer.drawPath(e,C={x:f.x-S.width/2,y:f.y-S.height/2,angle:0,id:"",class:"e-diagram-userhandle-path",fill:d.pathColor,stroke:d.backgroundColor,strokeWidth:.5,dashArray:"",data:w,width:d.size-5,height:d.size-5,pivotX:0,pivotY:0,opacity:1,visible:d.visible},this.diagramId,void 0,void 0,{"aria-label":d.name+"user handle"})}else if(d.content){var D=new En(d.name,this.diagramId);D.content=d.content,D.offsetX=f.x,D.offsetY=f.y,D.id=d.name+"_shape",D.horizontalAlignment="Center",D.verticalAlignment="Center",D.visible=d.visible,D.setOffsetWithRespectToBounds(f.x,f.y,"Fraction"),D.relativeMode="Object",D.description=d.name||"User handle",D.measure(new me(d.size,d.size)),D.arrange(D.desiredSize),this.svgRenderer.drawNativeContent(D,e,d.size,d.size,this.adornerSvgLayer)}else if(d.source){var C,A=new DI;(C=this.getBaseAttributes(A,i)).width=d.size,C.height=d.size,C.x=f.x-d.size/2,C.y=f.y-d.size/2,C.sourceWidth=d.size,C.sourceHeight=d.size,C.alignment=A.imageAlign,C.source=d.source,C.scale=A.imageScale,C.visible=d.visible,C.description=d.name||"User handle",C.id=d.name+"_",this.renderer.drawImage(e,C,this.adornerSvgLayer,!1)}else{var x=new es(d.name,this.diagramId);x.offsetX=f.x,x.offsetY=f.y,x.id=d.name+"_shape",x.visible=d.visible,x.relativeMode="Object",x.template=d.template,x.measure(new me(d.size,d.size)),x.arrange(x.desiredSize),this.svgRenderer.drawHTMLContent(x,r,void 0,!0,void 0)}}},n.prototype.renderRotateThumb=function(t,e,i,r,s){new Ze;var a,l=new me;l.width=18,l.height=16;var d=!!(r&mr.Rotate);s&&(d=!1);var f=t.offsetX-t.actualSize.width*t.pivot.x+t.pivot.x*t.actualSize.width,p=t.offsetY-t.actualSize.height*t.pivot.y;if(a={x:(f=(f+i.tx)*i.scale)-.5*l.width,y:(p=(p+i.ty)*i.scale)-30-.5*l.height},0!==t.rotateAngle||0!==t.parentTransform){var g=Bi();qi(g,t.rotateAngle+t.parentTransform,(i.tx+t.offsetX)*i.scale,(i.ty+t.offsetY)*i.scale),a=Ke(g,a)}var v={x:a.x,y:a.y,angle:t.rotateAngle+t.parentTransform,fill:"#231f20",stroke:"black",strokeWidth:.5,dashArray:"",data:"M 16.856144362449648 10.238890446662904 L 18.000144362449646 3.437890446662903L 15.811144362449646 4.254890446662903 C 14.837144362449646 2.5608904466629028 13.329144362449647 1.2598904466629026 11.485144362449645 0.5588904466629026 C 9.375144362449646 - 0.24510955333709716 7.071144362449646 - 0.18010955333709716 5.010144362449646 0.7438904466629028 C 2.942144362449646 1.6678904466629028 1.365144362449646 3.341890446662903 0.558144362449646 5.452890446662903 C - 0.244855637550354 7.567890446662903 - 0.17985563755035394 9.866890446662904 0.7431443624496461 11.930890446662904 C 1.6681443624496461 13.994890446662904 3.343144362449646 15.575890446662903 5.457144362449647 16.380890446662903 C 6.426144362449647 16.7518904466629 7.450144362449647 16.9348904466629 8.470144362449647 16.9348904466629 C 9.815144362449647 16.9348904466629 11.155144362449647 16.6178904466629 12.367144362449647 15.986890446662901 L 11.351144362449647 14.024890446662901 C 9.767144362449647 14.8468904466629 7.906144362449647 14.953890446662902 6.237144362449647 14.3178904466629 C 4.677144362449647 13.7218904466629 3.444144362449647 12.5558904466629 2.758144362449647 11.028890446662901 C 2.078144362449646 9.501890446662903 2.031144362449646 7.802890446662903 2.622144362449646 6.243890446662903 C 3.216144362449646 4.6798904466629025 4.387144362449646 3.442890446662903 5.914144362449646 2.760890446662903 C 7.437144362449646 2.078890446662903 9.137144362449646 2.0298904466629026 10.700144362449645 2.6258904466629027 C 11.946144362449646 3.100890446662903 12.971144362449646 3.9538904466629026 13.686144362449646 5.049890446662903 L 11.540144362449645 5.850890446662903 L 16.856144362449648 10.238890446662904 Z",width:20,height:20,pivotX:0,pivotY:0,opacity:1,visible:d,id:"rotateThumb",class:"e-diagram-rotate-handle"};if(this.touchMove){var y=document.getElementById("rotateThumb");y?this.updateSegmentPosition(y,v):this.svgRenderer.drawPath(e,v,this.diagramId,!0,void 0,{"aria-label":"Thumb to rotate the selected object"})}else this.svgRenderer.drawPath(e,v,this.diagramId,!0,void 0,{"aria-label":"Thumb to rotate the selected object"})},n.prototype.renderPathElement=function(t,e,i,r,s,o,a){var l=this.getBaseAttributes(t,i,o);if(l.data=t.absolutePath,l.data=t.absolutePath,t.isPathPort&&a){l.x=a[t.id]?a[t.id].cx:l.x,l.y=a[t.id]?a[t.id].cy:l.y,t.bounds.x=l.x,t.bounds.y=l.y;var h=document.getElementById(this.diagramId);h&&"PortDrag"!==h.ej2_instances[0].eventHandler.currentAction&&(t.offsetX=l.x+t.width/2,t.offsetY=l.y+t.height/2)}var u=t.description?t.description:t.id;if(this.isSvgMode||(l.x=t.flipOffset.x?t.flipOffset.x:l.x,l.y=t.flipOffset.y?t.flipOffset.y:l.y),t.isExport){var f=t.absoluteBounds,p=xd(l.data),g=this.findAndStoreArcValues(p);l.arc=g,l.data=BF(t,f,0,l)}this.renderer.drawPath(e,l,this.diagramId,void 0,r,u)},n.prototype.findAndStoreArcValues=function(t){var e=[];return t.forEach(function(i){"A"===i.command&&e.push({r1:i.r1/2,r2:i.r2/2})}),e},n.prototype.renderSvgGridlines=function(t,e,i,r,s,o){var a=document.createElementNS("http://www.w3.org/2000/svg","pattern"),l=document.createElementNS("http://www.w3.org/2000/svg","defs");l.setAttribute("id",this.diagramId+"_grid_pattern_defn"),(t.constraints&Kt.ShowHorizontalLines||t.constraints&Kt.ShowVerticalLines)&&a.setAttribute("id",this.diagramId+"_pattern");var h=0,c=0,d=0,u=0,f=1,p=!1,g="Lines"===t.gridType,v=g?t.verticalGridlines.lineIntervals:t.verticalGridlines.dotIntervals,y=g?t.horizontalGridlines.lineIntervals:t.horizontalGridlines.dotIntervals;if(r.showRulers&&r.dynamicGrid&&s&&o)d=o.updateSegmentWidth(i.scale),u=s.updateSegmentWidth(i.scale),t.horizontalGridlines.scaledIntervals=[d/s.interval],t.verticalGridlines.scaledIntervals=[u/o.interval],p=!0;else{for(var S=0;S=2)for(;e>=2;)e/=2;else if(e<=.5)for(;e<=.5;)e*=2;var i;if(t.horizontalGridlines.scaledIntervals=t.horizontalGridlines.snapIntervals,t.verticalGridlines.scaledIntervals=t.verticalGridlines.snapIntervals,1!==e){var r=t.horizontalGridlines;for(r.scaledIntervals=[],i=0;ithis.groupElement.actualSize.height&&("Clip"===t.style.textOverflow||"Ellipsis"===t.style.textOverflow)&&(a.y=a.y+(a.height-this.groupElement.actualSize.height)/2),this.renderer.drawRectangle(e,a,this.diagramId,void 0,void 0,r),this.renderer.drawText(e,a,r,l,this.diagramId,t.isExport&&Math.min(t.exportScaleValue.x||t.exportScaleValue.y),this.groupElement),this.isSvgMode&&(t.doWrap=!1)},n.prototype.renderNativeElement=function(t,e,i,r,s){var o,a,l=this.getParentSvg(t,void 0,e)||r,h=this.getParentElement(t,e,l).g||e,c=this.getBaseAttributes(t,i);switch(c.fill="transparent",c.cornerRadius=t.cornerRadius,c.stroke="transparent",this.renderer.drawRectangle(e,c,this.diagramId,void 0,void 0,r),t.scale){case"None":o=t.contentSize.width,a=t.contentSize.height;break;case"Stretch":o=t.actualSize.width,a=t.actualSize.height;break;case"Meet":o=a=t.actualSize.width<=t.actualSize.height?t.actualSize.width:t.actualSize.height;break;case"Slice":o=a=t.actualSize.width>=t.actualSize.height?t.actualSize.width:t.actualSize.height}this.svgRenderer&&this.svgRenderer.drawNativeContent(t,h,a,o,l)},n.prototype.renderHTMLElement=function(t,e,i,r,s,o,a){var l=this.getBaseAttributes(t,r);l.fill="transparent",l.cornerRadius=t.cornerRadius,l.stroke="transparent",this.renderer.drawRectangle(e,l,this.diagramId,void 0,void 0,s),this.svgRenderer&&this.svgRenderer.drawHTMLContent(t,i.children[0],r,function Sse(n){var t=n.parentElement;do{if(gm(t,"e-diagram"))return!0;t=t.parentElement}while(t);return!1}(i),a)},n.prototype.renderImageElement=function(t,e,i,r,s){var o=this.getBaseAttributes(t,i);o.cornerRadius=0,this.renderer.drawRectangle(e,o,this.diagramId,void 0,void 0,r);var a,l,h,c,g,d=t.contentSize.width,u=t.contentSize.height,f=o.width/d,p=o.height/u;if("Stretch"===t.stretch)a=d*(g=Math.min(f,p)),l=u*g;else switch(t.stretch){case"Meet":a=d*(g=Math.min(f,p)),l=u*g,o.x+=Math.abs(o.width-a)/2,o.y+=Math.abs(o.height-l)/2;break;case"Slice":g=Math.max(f,p),h=o.width/(a=d*g)*d,c=o.height/(l=u*g)*u;break;case"None":a=d,l=u}o.width=a,o.height=l,o.sourceWidth=h,o.sourceHeight=c,o.source=t.source,o.alignment=t.imageAlign,o.scale=t.imageScale,o.description=t.description?t.description:t.id,this.renderer.drawImage(e,o,r,s)},n.prototype.renderContainer=function(t,e,i,r,s,o,a,l,h,c,d){var g,u={svg:s,g:e},f=document.getElementById(this.diagramId);if(f&&(g=f.ej2_instances[0]),this.diagramId&&(s=this.getParentSvg(t)||s,this.isSvgMode)){var v=this.getParentElement(t,e,s,l).g||e;s=this.getParentSvg(this.hasNativeParent(t.children))||s;var y=this.getParentElement(this.hasNativeParent(t.children),v,s,l);u.svg=y.svg||s,u.g=y.g||v,o&&s&&(s.getElementById(u.g.id)||e.appendChild(u.g)),e=u.g}if(this.renderRect(t,e,r,s),this.groupElement=t,t.hasChildren()){for(var b,S=void 0,M=0,w=t.children;M0&&(D=g.selectedItems.nodes[0]);var L,A=void 0,x=void 0,P=!1;if(g&&g.selectedItems&&(L=g.getObject(t.id)),"None"!==t.flip&&(D=L),"None"===t.flip&&(D=L),D&&D.flipMode&&(P=!0),!(t.elementActions&Xr.ElementIsGroup)&&g instanceof _l&&g.nameTable[t.id]&&"connectors"!==g.nameTable[t.id].propName&&P&&D){if(A=t.children&&t.children[0]instanceof En?document.getElementById(D.id+"_content_inner_native_element"):document.getElementById(D.id+"_content_groupElement"),!(t.children[0]instanceof En)&&"Text"!==D.shape.type&&"None"!==D.flipMode&&"Label"!==D.flipMode&&"All"!==D.flipMode&&"PortAndLabel"!==D.flipMode&&"LabelText"!==D.flipMode&&"PortAndLabelText"!==D.flipMode&&"LabelAndLabelText"!==D.flipMode||t.children[0]instanceof En&&"Port"===D.flipMode)return void this.renderFlipElement(t,A,D.flip);if((t.children[0]instanceof En&&("All"===D.flipMode||"Label"===D.flipMode)||"Label"===D.flipMode||"PortAndLabel"===D.flipMode||"LabelText"===D.flipMode||"PortAndLabelText"===D.flipMode||"LabelAndLabelText"===D.flipMode||"Image"===D.shape.type&&"Label"===D.flipMode)&&this.renderFlipElement(t,A,t.flip),"None"!==t.flip&&"None"===D.flipMode)this.renderFlipElement(t,A,t.flip);else if("None"!==t.flip&&("Label"===D.flipMode||"PortAndLabel"===D.flipMode||"LabelText"===D.flipMode||"PortAndLabelText"===D.flipMode||"LabelAndLabelText"===D.flipMode)||t.children[0]instanceof En&&"None"!==t.flip&&D&&("None"===D.flipMode||"All"===D.flipMode)){for(var O=0;O0){var i=t[0];if(i instanceof En)return i;i.children&&i.children.length&&this.hasNativeParent(i.children,e++||0)}},n.prototype.renderRect=function(t,e,i,r,s){var o=this.getBaseAttributes(t,i,s);o.cornerRadius=t.cornerRadius||0,t.isExport&&(o.cornerRadius*=t.exportScaleValue.x),this.renderer.drawRectangle(e,o,this.diagramId,t.isExport,void 0,r,t.description?t.description:t.id)},n.prototype.drawRect=function(t,e){e.cornerRadius=0,this.svgRenderer.drawRectangle(t,e,this.diagramId)},n.prototype.getBaseAttributes=function(t,e,i){var r={width:t.actualSize.width,height:t.actualSize.height,x:t.offsetX-t.actualSize.width*t.pivot.x,y:t.offsetY-t.actualSize.height*t.pivot.y,fill:t.style.fill,stroke:t.style.strokeColor,angle:t.rotateAngle+t.parentTransform,pivotX:t.pivot.x,pivotY:t.pivot.y,strokeWidth:t.style.strokeWidth,dashArray:t.style.strokeDashArray||"",opacity:t.style.opacity,shadow:t.shadow,gradient:t.style.gradient,visible:t.visible,id:t.id,description:t.description,canApplyStyle:t.canApplyStyle,shapeType:t.shapeType};return"Page"===t.rotationReference&&(r.angle=t.rotateAngle),i&&(r.x=r.x-.5,r.y=r.y-.5),t.isExport&&(r.width*=t.exportScaleValue.x,r.height*=t.exportScaleValue.y,r.x*=t.exportScaleValue.x,r.y*=t.exportScaleValue.y,r.strokeWidth*=t.exportScaleValue.x),t.flip&&(r.flip=t.flip),e&&(r.x+=e.tx,r.y+=e.ty),r},n.renderSvgBackGroundImage=function(t,e,i,r,s,o){if(t.source){var l=IT(e.id).getElementById(e.id+"_image");if(!l){var h=function Toe(n){return xt(n).getElementsByClassName("e-background-image-layer")[0]}(e.id);(l=document.createElementNS("http://www.w3.org/2000/svg","image")).setAttribute("id",e.id+"_image"),h.appendChild(l)}var c=new Image;c.src=t.source,l.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",c.src.toString());var d="None"!==t.scale?t.scale:"",u=t.align,f=u.charAt(0).toLowerCase()+u.slice(1);d&&(f+=" "+d.charAt(0).toLowerCase()+d.slice(1)),ti(l,{id:e.id+"_image",x:i,y:r,width:s,height:o,preserveAspectRatio:f})}},n.prototype.transformLayers=function(t,e){var i=t.tx*t.scale,r=t.ty*t.scale,s="domTable";if(i!==this.transform.x||r!==this.transform.y||0===i||0===r){e&&(window[""+s][this.diagramId+"_diagramLayer"]||(window[""+s][this.diagramId+"_diagramLayer"]=this.diagramSvgLayer.getElementById(this.diagramId+"_diagramLayer")),window[""+s][this.diagramId+"_diagramLayer"].setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+"),scale("+t.scale+")"));var a=function Aoe(n){var t="domTable",e=null;return window[t][n+"_gridline"]?e=window[t][n+"_gridline"]:(e=Ud(n).getElementById(n+"_gridline"),window[t][n+"_gridline"]=e),e}(this.diagramId);return a.setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+")"),window[""+s][this.diagramId+"_diagramPorts"]||(window[""+s][this.diagramId+"_diagramPorts"]=this.iconSvgLayer.getElementById(this.diagramId+"_diagramPorts")),window[""+s][this.diagramId+"_diagramPorts"].setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+"),scale("+t.scale+")"),window[""+s][this.diagramId+"_diagramExpander"]||(window[""+s][this.diagramId+"_diagramExpander"]=this.iconSvgLayer.getElementById(this.diagramId+"_diagramExpander")),window[""+s][this.diagramId+"_diagramExpander"].setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+"),scale("+t.scale+")"),window[""+s][this.diagramId+"_nativeLayer"]||(window[""+s][this.diagramId+"_nativeLayer"]=this.nativeSvgLayer.getElementById(this.diagramId+"_nativeLayer")),window[""+s][this.diagramId+"_nativeLayer"].setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+"),scale("+t.scale+")"),Io(this.diagramId).children[0].style.transform="translate("+t.tx*t.scale+"px,"+t.ty*t.scale+"px)scale("+t.scale+")",this.transform={x:t.tx*t.scale,y:t.ty*t.scale},!0}return!1},n.prototype.updateNode=function(t,e,i,r,s,o,a){this.renderElement(t,e,i,r,this.getParentSvg(t),void 0,void 0,s,null,o,a)},n}(),use=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),ib=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},uF=function(n){function t(e,i){var r=n.call(this,e,i)||this;return r.mode="Canvas",r.id="overview",r.actionName="",r.startPoint=null,r.currentPoint=null,r.prevPoint=null,r.scale=null,r.inAction=!1,r.viewPortRatio=1,r.horizontalOffset=0,r.verticalOffset=0,r.model={},r.event=!0,r.overviewid=88123,r.model={width:r.width,height:r.height},r}return use(t,n),t.prototype.onPropertyChanged=function(e,i){for(var r=0,s=Object.keys(e);r0||e.toString().indexOf("%")>0?e.toString():e.toString()+"px"},t.prototype.renderCanvas=function(e){var i=document.getElementById(this.element.id+"_canvas");i||(i=Tt("div",{}),this.element.appendChild(i)),Ho(i,{id:this.element.id+"_canvas",class:"drawing",style:"position:relative; height:"+this.getSizeValue(this.model.height)+"; width:"+this.getSizeValue(this.model.width)+";style:-ms-touch-action: none;touch-action: none;"}),this.element.setAttribute("tabindex",String(-1)),this.element.style.overflow="hidden",this.element.style.height=String(this.model.height),this.element.style.width=String(this.model.width),this.canvas=i},t.prototype.setParent=function(e){var i=document.getElementById(e);if(this.parent){var s=this.parent;this.parent=null,s.setOverview(null,this.element.id),this.removeDocument(this)}this.parent=this.getDiagram(i,"ej2_instances"),this.parent&&this.parent.setOverview(this)},t.prototype.getDiagram=function(e,i){for(var r,s=e[""+i].length,o=0;o0?f:Math.floor(window.innerWidth)}if(0===h){var p=Math.floor(window.innerHeight-u-Math.floor(c.top));h=p>0?p:Math.floor(window.innerHeight)}l>0&&(s.setAttribute("width",String(l)),this.model.height=h),h>0&&(s.setAttribute("height",String(h)),this.model.width=l),e.diagramLayerDiv||(e.diagramLayerDiv=Tt("div",{}),e.diagramLayer=bo.createCanvas(this.element.id+"_diagramLayer",this.model.width,this.model.height),e.diagramLayer.setAttribute("style","position:absolute; left:0px; top:0px "),e.diagramLayerDiv.appendChild(e.diagramLayer),e.canvas.appendChild(e.diagramLayerDiv)),Ho(e.diagramLayerDiv,{id:this.element.id+"_diagramLayer_div",style:"width:"+this.model.width+"px; height:"+this.model.height+"px;position:absolute;top:0px;left:0px"}),this.renderHtmlLayer(e.canvas),this.renderNativeLayer(e.canvas,e),this.addOverviewRectPanel(e)},t.prototype.removeDocument=function(e){var i=document.getElementById(this.canvas.id+"_svg");this.canvas.removeChild(i);var r=document.getElementById(this.element.id+"_htmlLayer");this.canvas.removeChild(r);var s=document.getElementById(this.element.id+"_diagramLayer_div");this.canvas.removeChild(s),e.diagramLayerDiv=null,e.diagramLayer=null,window.domTable[this.id+"html_layer"]=null},t.prototype.renderHtmlLayer=function(e){var i=Tt("div",{id:this.element.id+"_htmlLayer",class:"e-html-layer",style:"pointer-events:none;position:absolute;top:0px;left:0px;"}),s=Tt("div",{id:this.element.id+"_htmlLayer_div",style:"position:absolute;top:0px;left:0px;"});return i.appendChild(s),e.appendChild(i),i},t.prototype.renderNativeLayer=function(e,i){if(!document.getElementById(this.element.id+"_nativeLayer_svg")){var r=this.parent.createSvg(this.element.id+"_nativeLayer_svg",this.model.width,this.model.height),s=Fi("g",{id:this.element.id+"_nativeLayer"});r.appendChild(s),i.diagramLayerDiv.appendChild(r),ti(r,{class:"e-native-layer"})}},t.prototype.addOverviewRectPanel=function(e){var i=document.getElementById(this.canvas.id+"_overviewsvg");i&&i.parentNode.removeChild(i),i=Fi("svg",{id:this.canvas.id+"_overviewsvg",class:"overviewsvg",version:"1.1",style:"position:absolute;left:0px;top:0px; aria-label:Specifies overview",width:this.model.width,height:this.model.height}),e.canvas.appendChild(i);var s=Fi("g",{id:this.element.id+"_overviewlayer",style:"pointer-events:none"});i.appendChild(s);var o=Fi("rect",{fill:"transparent",width:"100%",height:"100%",class:"overviewbackrect",id:this.canvas.id+"overviewbackrect"});o.setAttribute("style"," pointer-events: none; "),s.appendChild(o);var a=Fi("g",{id:this.canvas.id+"overviewhandle",style:"pointer-events:all"});s.appendChild(a);var l=Fi("rect",{id:this.canvas.id+"overviewrect",fill:"transparent"});a.appendChild(l),this.renderOverviewCorner("left",a),this.renderOverviewCorner("right",a),this.renderOverviewCorner("top",a),this.renderOverviewCorner("bottom",a),this.renderOverviewCorner("topleft",a),this.renderOverviewCorner("topright",a),this.renderOverviewCorner("bottomleft",a),this.renderOverviewCorner("bottomright",a)},t.prototype.renderOverviewCorner=function(e,i){var s,o=Fi(s="top"===e||"bottom"===e||"right"===e||"left"===e?"rect":"circle",{id:this.canvas.id+"visible"+e,class:"overview-resizer"});i.appendChild(o);var a=Fi(s,{id:this.canvas.id+e,class:"overviewresizer",fill:"transparent"});i.appendChild(a)},t.prototype.updateOverviewRectangle=function(){var e=this.currentPoint.x-this.prevPoint.x,i=this.currentPoint.y-this.prevPoint.y,r=new me;r.width=0,r.height=0;var s=0,o=0;switch(this.resizeDirection){case"left":r.width-=e,r.height-=e/this.viewPortRatio,s=e,o=e/this.viewPortRatio,o/=2;break;case"right":r.width+=e,r.height+=e/this.viewPortRatio,o=e/this.viewPortRatio,o/=-2;break;case"top":r.height-=i,r.width-=i*this.viewPortRatio,o=i,s=i*this.viewPortRatio,s/=2;break;case"bottom":r.height+=i,r.width+=i*this.viewPortRatio,s=i*this.viewPortRatio,s/=-2;break;case"topleft":Math.abs(i)>Math.abs(e)?e=i*this.viewPortRatio:i=e/this.viewPortRatio,r.width-=e,r.height-=i,s=e,o=i;break;case"topright":Math.abs(i)>Math.abs(e)?e=-i*this.viewPortRatio:i=-e/this.viewPortRatio,o=i,r.width+=e,r.height-=i;break;case"bottomleft":Math.abs(i)>Math.abs(e)?e=-i*this.viewPortRatio:i=-e/this.viewPortRatio,s=e,r.width-=e,r.height+=i;break;case"bottomright":Math.abs(i)>Math.abs(e)?e=i*this.viewPortRatio:i=e/this.viewPortRatio,r.width+=e,r.height+=i}this.updateHelper(s,o,r,void 0,void 0)},t.prototype.updateHelper=function(e,i,r,s,o){var a,l,h,u,f,d=this.element.getElementsByTagName("svg")[2].getElementById("helper");r?(a=(h=d.getBBox()).x+e,l=h.y+i,s=h.width+r.width,o=h.height+r.height):(u=this.currentPoint.x>this.startPoint.x?this.currentPoint.x-this.prevPoint.x:this.prevPoint.x-this.currentPoint.x,f=this.currentPoint.y>this.startPoint.y?this.currentPoint.y-this.prevPoint.y:this.prevPoint.y-this.currentPoint.y,Math.abs(f)>Math.abs(u)?u=this.viewPortRatio*f:f=u/this.viewPortRatio,h=d.getBBox(),a=this.startPoint.x>this.currentPoint.x?h.x-u:h.x,l=this.startPoint.y>this.currentPoint.y?h.y-f:h.y,s=h.width+u,o=h.height+f),ti(this.helper,{id:this.helper.id,x:a,y:l,width:Math.max(0,s),height:Math.max(0,o)})},t.prototype.updateOverviewrect=function(e,i,r,s){Ho(document.getElementById(this.canvas.id+"overviewrect"),{x:e,y:i,width:Math.max(1,r),height:Math.max(1,s)}),this.updateOverviewCorner("top",e+8,i+1,Math.max(0,r-16),2),this.updateOverviewCorner("bottom",e+8,i+s+3,Math.max(0,r-16),2),this.updateOverviewCorner("left",e-2,i+11,2,Math.max(0,s-16)),this.updateOverviewCorner("right",e+r,i+11,2,Math.max(0,s-16)),this.updateOverviewCorner("topleft",e,i+3,5,5),this.updateOverviewCorner("topright",e+r,i+3,5,5),this.updateOverviewCorner("bottomleft",e,i+s+3,5,5),this.updateOverviewCorner("bottomright",e+r,i+s+3,5,5)},t.prototype.updateOverviewCorner=function(e,i,r,s,o){var a,l;"top"===e||"bottom"===e||"right"===e||"left"===e?(a={x:i,y:r,width:s,height:o,fill:"#ED1C24"},l={x:i-2,y:r-2,width:2===s?4:s,height:2===o?4:o}):(a={cx:i,cy:r,r:4,fill:"#ED1C24"},l={cx:i,cy:r,r:6,fill:"transparent"}),Ho(document.getElementById(this.canvas.id+"visible"+e),a),Ho(document.getElementById(this.canvas.id+e),l)},t.prototype.translateOverviewRectangle=function(){Number(this.model.width),Number(this.model.height);var r=this.currentPoint.x-this.prevPoint.x,s=this.currentPoint.y-this.prevPoint.y,l=this.element.getElementsByClassName("overviewsvg")[0].getElementById(this.canvas.id+"overviewrect").getBBox(),h=l.x+r,c=l.y+s,d=l.width,u=l.height;this.updateOverviewrect(h,c,d,u),this.updateParentView(this.parent.scroller.currentZoom,h,c,d,u,null)},t.prototype.renderOverviewRect=function(e,i,r,s){var o=Number(this.model.width),a=Number(this.model.height),c=Math.max(this.parent.scroller.viewPortWidth/(r/o*this.contentWidth),this.parent.scroller.viewPortHeight/(s/a*this.contentHeight));if(c>=.25&&c<=30){this.updateParentView(c,e,i,r,s,{x:0,y:0});var u=this.scrollOverviewRect(this.parent.scroller.horizontalOffset,this.parent.scroller.verticalOffset,this.parent.scroller.currentZoom,!0);if(this.helper){var p=this.element.getElementsByTagName("rect")[10].getBBox();u.x=p.x,u.y=p.y}"pan"===this.actionName?this.updateOverviewrect(-u.x,-u.y,u.width,u.height):this.updateOverviewrect(u.x,u.y,u.width,u.height)}},t.prototype.scrollOverviewRect=function(e,i,r,s){if(!this.actionName||s){var o=Number(this.model.width),a=Number(this.model.height),l=Math.min(this.contentWidth/o,this.contentHeight/a),h=new Ne,c=h.x=e/r/l,d=h.y=i/r/l,u=0;this.parent.rulerSettings.showRulers&&(u=25);var f=document.getElementById(this.parent.element.id+"content"),p=0,g=0;f&&(p=f.offsetWidth-f.clientWidth,g=f.offsetHeight-f.clientHeight);var v=h.width=(this.parent.scroller.viewPortWidth-u-p)/r/l,y=h.height=(this.parent.scroller.viewPortHeight-u-g)/r/l;if(s){var S=new Ne;return S.x=c,S.y=d,S.width=v,S.height=y,S}this.updateOverviewrect(-c,-d,v,y)}return null},t.prototype.updateParentView=function(e,i,r,s,o,a){var p,g,l=Number(this.model.width),h=Number(this.model.height),u=i*(this.contentWidth/l)*e,f=r*(this.contentHeight/h)*e;this.parent.scroller.getPageBounds(),(1!==e||"pan"===this.actionName)&&(p=-u-this.parent.scroller.horizontalOffset,g=-f-this.parent.scroller.verticalOffset),this.parent.setBlazorDiagramProps(!0),this.parent.realActions|=$i.OverViewAction,"scale"===this.actionName||"draw"===this.actionName?this.parent.scroller.zoom(e/this.parent.scroller.currentZoom,p,g,a):ce()?this.parent.scroller.zoom(1,p,g,a):this.parent.pan(p,g,a,!0)},t.prototype.updateHtmlLayer=function(e){var i=Io(e.element.id),r=this.parent.scroller.getPageBounds(!0),o=r.height,a=Math.max(r.width,this.parent.scroller.viewPortWidth),l=Math.max(o,this.parent.scroller.viewPortHeight/this.parent.scroller.currentZoom),h=Math.min(Number(this.model.width)/a,Number(this.model.height)/l);i.style.transform="scale("+h+") translate("+this.parent.scroller.transform.tx+"px,"+this.parent.scroller.transform.ty+"px)"},t.prototype.updateView=function(e){var i=this.parent.scroller.getPageBounds(),r=i.width,s=i.height,o=Number(this.model.width),a=Number(this.model.height),l=Math.max(r,this.parent.scroller.viewPortWidth),h=Math.max(s,this.parent.scroller.viewPortHeight);this.contentWidth=l=Math.max(l,o/a*h),this.contentHeight=h=Math.max(h,a/o*l);var c=Math.min(o/l,a/h),d=document.getElementById(this.element.id+"_htmlLayer");d.style.webkitTransform="scale("+c+") translate("+-i.x+"px,"+-i.y+"px)",d.style.transform="scale("+c+") translate("+-i.x+"px,"+-i.y+"px)",document.getElementById(this.element.id+"_overviewlayer").setAttribute("transform","translate("+-i.x*c+","+-i.y*c+")"),this.horizontalOffset=i.x*c,this.verticalOffset=i.y*c;var f=document.getElementById(this.element.id+"_diagramLayer"),p=UF(this.element.id),g=f.getContext("2d"),v=Number(this.model.width)/this.contentWidth,y=Number(this.model.height)/this.contentHeight;v=Math.min(v,y);var S=this.parent.scroller.transform;p.setAttribute("transform","translate("+S.tx*v+","+S.ty*y+"),scale("+v+")"),g.setTransform(v,0,0,v,0,0),g.fillStyle="red",this.scrollOverviewRect(this.parent.scroller.horizontalOffset,this.parent.scroller.verticalOffset,this.parent.scroller.currentZoom)},t.prototype.scrolled=function(e){if(this.event){var i=this.scrollOverviewRect(this.parent.scroller.horizontalOffset,this.parent.scroller.verticalOffset,this.parent.scroller.currentZoom,!0);this.updateOverviewrect(-i.x,-i.y,i.width,i.height),this.updateView(this)}},t.prototype.updateCursor=function(e){if(gm(e.target,"overviewresizer"))switch(e.target.id){case this.canvas.id+"left":this.canvas.style.cursor="w-resize";break;case this.canvas.id+"right":this.canvas.style.cursor="e-resize";break;case this.canvas.id+"top":this.canvas.style.cursor="n-resize";break;case this.canvas.id+"bottom":this.canvas.style.cursor="s-resize";break;case this.canvas.id+"topleft":this.canvas.style.cursor="nw-resize";break;case this.canvas.id+"topright":this.canvas.style.cursor="ne-resize";break;case this.canvas.id+"bottomleft":this.canvas.style.cursor="sw-resize";break;case this.canvas.id+"bottomright":this.canvas.style.cursor="se-resize"}else this.canvas.style.cursor="default"},t.prototype.mouseMove=function(e){if(this.event=!1,this.updateCursor(e),this.currentPoint=this.mousePosition(e),this.actionName)switch(this.actionName){case"draw":!this.inAction&&(this.startPoint.x!==this.currentPoint.x||this.startPoint.y!==this.currentPoint.y)&&(this.initHelper(),this.inAction=!0),this.inAction&&this.updateHelper();break;case"scale":this.inAction||(this.initHelper(),this.inAction=!0),this.updateOverviewRectangle();break;case"pan":(this.startPoint.x!==this.currentPoint.x||this.startPoint.y===this.currentPoint.y||this.inAction)&&(this.inAction=!0,this.translateOverviewRectangle())}this.prevPoint=this.currentPoint},t.prototype.documentMouseUp=function(e){this.inAction=!1,this.actionName="",this.helper&&(this.helper.parentNode.removeChild(this.helper),this.helper=null),this.event=!0,document.getElementById(this.canvas.id+"overviewhandle").style.pointerEvents="all"},t.prototype.windowResize=function(e){var i=this;return this.resizeTo&&clearTimeout(this.resizeTo),this.resizeTo=setTimeout(function(){var s=document.getElementById(i.element.id).getBoundingClientRect();i.model.width=s.width>0?s.width:i.model.width,i.model.height=s.height>0?s.height:i.model.height,i.renderCanvas(),i.setParent(i.sourceID)},10),!1},t.prototype.mouseDown=function(e){if(e.target.id===this.canvas.id+"_overviewsvg"&&(this.actionName="draw"),e.target.id===this.canvas.id+"overviewrect"&&(this.actionName="pan"),gm(e.target,"overviewresizer"))switch(this.actionName="scale",e.target.id){case this.canvas.id+"left":this.resizeDirection="left";break;case this.canvas.id+"right":this.resizeDirection="right";break;case this.canvas.id+"top":this.resizeDirection="top";break;case this.canvas.id+"bottom":this.resizeDirection="bottom";break;case this.canvas.id+"topleft":this.resizeDirection="topleft";break;case this.canvas.id+"topright":this.resizeDirection="topright";break;case this.canvas.id+"bottomleft":this.resizeDirection="bottomleft";break;case this.canvas.id+"bottomright":this.resizeDirection="bottomright"}this.startPoint=this.prevPoint=this.mousePosition(e),this.viewPortRatio=this.parent.scroller.viewPortWidth/this.parent.scroller.viewPortHeight,document.getElementById(this.canvas.id+"overviewhandle").style.pointerEvents="none"},t.prototype.mouseUp=function(e){if(this.currentPoint=this.mousePosition(e),this.actionName)if(this.startPoint.x!==this.currentPoint.x||this.startPoint.y!==this.currentPoint.y){if("pan"!==this.actionName&&this.helper){var i=this.element.getElementsByTagName("rect")[10].getBBox();this.resizeDirection=this.resizeDirection||"",this.renderOverviewRect(i.x,i.y,o=i.width,a=i.height)}}else if(e.target.id===this.canvas.id+"_overviewsvg"||"helper"===e.target.id){var o=(i=this.element.getElementsByTagName("svg")[2].getElementById(this.canvas.id+"overviewrect").getBBox()).width,a=i.height;this.inAction=!0,this.actionName="pan",this.renderOverviewRect(this.currentPoint.x-o/2,this.currentPoint.y-a/2,o,a),this.inAction=!1}this.helper&&(this.helper.parentNode.removeChild(this.helper),this.helper=null),this.actionName="",this.startPoint=null,this.currentPoint=null,this.prevPoint=null,this.helper=null,this.viewPortRatio=1,this.resizeDirection="",this.inAction=!1,this.event=!0,document.getElementById(this.canvas.id+"overviewhandle").style.pointerEvents="all"},t.prototype.initHelper=function(){var e=this.element.getElementsByTagName("svg")[2],i=this.startPoint.x,r=this.startPoint.y,s=1,o=1;if("scale"===this.actionName){var l=e.getElementById(this.canvas.id+"overviewrect").getBBox();i=l.x,r=l.y,s=l.width,o=l.height}var h=Fi("rect",{id:"helper",x:i,y:r,width:s,height:o,fill:"transparent",stroke:"gray","stroke-dasharray":"2 2","shape-rendering":"crispEdges"});e.getElementById(this.element.id+"_overviewlayer").appendChild(h),this.helper=h},t.prototype.mousePosition=function(e){var i,r,s;-1!==e.type.indexOf("touch")?(r=(i=e).changedTouches[0].clientX-this.element.offsetLeft,s=i.changedTouches[0].clientY-this.element.offsetTop):(r=e.clientX,s=e.clientY);var l=this.element.getBoundingClientRect();return{x:(r-=l.left)+this.horizontalOffset,y:(s-=l.top)+this.verticalOffset}},t.prototype.destroy=function(){if(this.unWireEvents(),this.notify("destroy",{}),n.prototype.destroy.call(this),document.getElementById(this.element.id)){this.element.classList.remove("e-overview");var e=document.getElementById(this.element.id+"_canvas");e&&this.element.removeChild(e)}this.parent.views.splice(this.parent.views.indexOf(this.element.id),1),this.diagramLayerDiv=null,this.canvas=null,this.parent=null},t.prototype.getModuleName=function(){return"Overview"},ib([I("100%")],t.prototype,"width",void 0),ib([I("100%")],t.prototype,"height",void 0),ib([I("")],t.prototype,"sourceID",void 0),ib([H()],t.prototype,"created",void 0),t}(Ii);function pse(n,t){for(var e=0;eR.findLength(e,n)?e:t;var o=R.findAngle(t,e),a=R.findAngle(i,n),l=R.findLength(i,n),h=a+2*(o-a);return{x:i.x+l*Math.cos(h*Math.PI/180),y:i.y+l*Math.sin(h*Math.PI/180)}}function ep(n,t,e){if(n&&n.children&&n.children.length>0)for(var r=void 0,s=0;s0&&"annotations"!==r&&"ports"!==r)if(n[""+l].length>0)for(var h=0;h<=n[""+l].length;h++)Ro(n[""+l],t?t[""+l]:void 0,e[""+l],"annotations"===l||"ports"===l?n:void 0,l);else Ro(n[""+l],t?t[""+l]:void 0,e[""+l],"annotations"===l||"ports"===l?n:void 0,l);else if(s instanceof Object&&t&&"annotations"!==r&&"ports"!==r)Ro(n[""+l],t[""+l],e[""+l]);else if("annotations"!==r&&"ports"!==r&&t&&!t[""+l]||!t&&n&&(n[""+l]||void 0!==n[""+l]))n[""+l]=e[""+l];else{var c=void 0;("annotations"===r||"ports"===r)&&("annotations"===r?(n[""+l]&&Ro(n[""+l],t[""+l],e[""+l]),n[""+l]||(ps(i)===de?(c=new Or(i,"annotations",e[""+l]),i.annotations.push(c)):(c=new Kn(i,"annotations",e[""+l]),i.annotations.push(c)))):n[""+l]?Ro(n[""+l],t[""+l],e[""+l]):(c=new Es(i,"ports",e[""+l]),i.ports.push(c)))}}}function bse(n,t){for(var e="Bezier"===n.type?function yse(n){var t=[];if("Bezier"===n.type)for(var e=0,i=0;i0||n.ports.length>0){var f=n.wrapper.children;for(i=3;i0)return{enabled:!1,intersectPt:e};var l=o/s,h=a/s;return l>=0&&l<=1&&h>=0&&h<=1?(e.x=i.x1+l*(i.x2-i.x1),e.y=i.y1+l*(i.y2-i.y1),{enabled:!0,intersectPt:e}):{enabled:!1,intersectPt:e}}function nb(n,t,e,i){var a=nm(vF(n.x,n.y,t.x,t.y),vF(e.x,e.y,i.x,i.y));return a.enabled?a.intersectPt:{x:0,y:0}}function vF(n,t,e,i){return{x1:Number(n)||0,y1:Number(t)||0,x2:Number(e)||0,y2:Number(i)||0}}function mF(n,t,e){var i=[],s={x:t.topRight.x+(e=e||0),y:t.topRight.y},o={x:t.bottomRight.x,y:t.bottomRight.y-e},a={x:t.bottomLeft.x,y:t.bottomLeft.y+e};return i.push({x:t.topLeft.x-e,y:t.topLeft.y}),i.push(s),i.push(o),i.push(a),i}function zc(n,t,e,i,r,s){var o={},a=e.scroller.transform.scale,h=e.scroller.verticalOffset;return o.x=(i?n.x:t.x)*a+e.scroller.horizontalOffset-r,o.y=(i?n.y:t.y)*a+h-s,o}function yF(n,t){var e=new Ze;return e.data=n.pathData,e.height=n.height>10?n.height-(n.padding.bottom+n.padding.top):n.height,e.width=n.width>10?n.width-(n.padding.left+n.padding.right):n.width,e.visible=n.visibility,e.id=t.id+"_shape",e.inversedAlignment=!1,e.horizontalAlignment="Center",e.verticalAlignment="Center",e.style={fill:n.iconStrokeColor,strokeColor:n.iconStrokeColor,strokeWidth:n.iconStrokeWidth},e.setOffsetWithRespectToBounds(.5,.5,"Fraction"),e.relativeMode="Object",e.description=t.description||"",e}function Zx(n,t,e){var i=Jx(n,t),r=R.findAngle(n[i.index],n[i.index+1]),s=function Tse(n){var t;t=n instanceof OI?0:void 0===n.content?10:0;var e=0;switch(n.alignment){case"Center":e=0;break;case"Before":e=-(0+t);break;case"After":e=0+t}return e}(t),o=R.transform(i.point,r+45,s);return i.point=o,i.angle=r,i}function Jx(n,t){for(var r,s,a,l,e=0,i=t.offset,o=[],h=0;h=c)return s=R.findAngle(n[parseInt(d.toString(),10)],n[d+1]),{point:r=R.transform(n[parseInt(d.toString(),10)],s,c-(a||0)),index:l=d};a=o[parseInt(d.toString(),10)]}return{point:r,index:l}}function SF(n,t,e){t%=360;var a,l,s=225;switch(n.alignment){case"Before":t>=45&&t<=135?(l="right",a=.5===n.offset?"center":"top"):t>=s&&t<=315?(l="left",a=.5===n.offset?"center":"bottom"):t>45&&t=45&&t<=135?(l="left",a=.5===n.offset?"center":"top"):t>=s&&t<=315?(l="right",a=.5===n.offset?"center":"bottom"):t>45&&tMath.abs(t.y-n.y)?n.x0)for(var e=0;e=0;r--)("nodes"===i||"connectors"===i)&&(n[""+i][parseInt(r.toString(),10)].wrapper=null),"dataManager"!==i&&(n[""+i][parseInt(r.toString(),10)]=tT(n[""+i][parseInt(r.toString(),10)],e[""+i][parseInt(r.toString(),10)],void 0!==t[""+i]?t[""+i][parseInt(r.toString(),10)]:[]),("[]"===JSON.stringify(n[""+i][parseInt(r.toString(),10)])||"{}"===JSON.stringify(n[""+i][parseInt(r.toString(),10)])||void 0===n[""+i][parseInt(r.toString(),10)])&&n[""+i].splice(r,1));n=void 0}function Hh(n,t){var e=t.style,i=t;t.canApplyStyle=!0;for(var r=0,s=Object.keys(n);r=0&&n.splice(e,1)}function tp(n,t,e){var i;n.intermediatePoints=t,n.updateSegmentElement(n,t,n.wrapper.children[0],e);var r=n.sourceDecorator;if("Bezier"===n.type){var s=n.segments[0],o=n.segments[n.segments.length-1];i=[R.isEmptyPoint(o.point2)?o.bezierPoint2:o.point2,R.isEmptyPoint(s.point1)?s.bezierPoint1:s.point1]}else i=n.intermediatePoints;t=n.clipDecorators(n,t,e);var a=n.wrapper.children[0];a.canMeasurePath=!0,n.updateDecoratorElement(a=n.wrapper.children[1],t[0],i[1],r),n.updateDecoratorElement(a=n.wrapper.children[2],t[t.length-1],i[i.length-2],n.targetDecorator),n.updateShapeElement(n)}function iT(n,t,e){var l,i=n.wrapper,s=t.offset,o=t.size/e.scale,a=t.margin,h=i.offsetX-i.actualSize.width*i.pivot.x,c=i.offsetY-i.actualSize.height*i.pivot.y;if(l={x:0,y:0},n.nodes.length>0){switch(t.side){case"Top":l.x+=h+s*i.actualSize.width,l.y+=c-o;break;case"Bottom":l.x+=h+s*i.actualSize.width,l.y+=c+i.actualSize.height+o;break;case"Left":l.x+=h-o,l.y+=c+s*i.actualSize.height;break;case"Right":l.x+=h+i.actualSize.width+o,l.y+=c+s*i.actualSize.height}l.x+=(a.left-a.right)/e.scale+o/2*("Center"===t.horizontalAlignment?0:"Right"===t.horizontalAlignment?-1:1),l.y+=(a.top-a.bottom)/e.scale+o/2*("Center"===t.verticalAlignment?0:"Top"===t.verticalAlignment?-1:1)}else if(n.connectors.length>0){var d=n.connectors[0],u={offset:s},f=Jx(d.intermediatePoints,u),p=f.index;l=f.point;var y,v=Zx(d.intermediatePoints,u).angle;qi(y=Bi(),-v,d.intermediatePoints[parseInt(p.toString(),10)].x,d.intermediatePoints[parseInt(p.toString(),10)].y),(l=Ke(y,l)).x+=a.left-a.right+o/2*("Center"===t.horizontalAlignment?0:"Right"===t.horizontalAlignment?-1:1),l.y+=a.top-a.bottom+o/2*("Center"===t.verticalAlignment?0:"Top"===t.verticalAlignment?-1:1),qi(y=Bi(),v,d.intermediatePoints[parseInt(p.toString(),10)].x,d.intermediatePoints[parseInt(p.toString(),10)].y),l=Ke(y,l)}return 0===i.rotateAngle&&0===i.parentTransform||(qi(y=Bi(),i.rotateAngle+i.parentTransform,i.offsetX,i.offsetY),l=Ke(y,l)),l}function ga(n,t,e,i){if(i.annotation){if(zl(i.annotation))return!0}else if(mr[""+t]&n&&bt[""+t]&e)return!0;return!1}function qr(n,t){return!!(mr[""+t]&n)}function Hc(n,t){return!!(Cx[""+t]&n)}function va(n,t){return n.visibility&t}function sb(n,t){var e;if("Text"===n.shape.type)e=n.shape;else{var i=t.split("_");t=i[i.length-1];for(var r=0;rn[""+t]?e.splice(0,0,n):e.push(n);else if(e.length>1){for(var i=0,r=e.length-1,s=Math.floor((i+r)/2);s!==i;)if(e[parseInt(s.toString(),10)][""+t]n[""+t]))break;r=s,s=Math.floor((i+r)/2)}e[parseInt(r.toString(),10)][""+t]n[""+t]?e.splice(i,0,n):e[parseInt(i.toString(),10)][""+t]n[""+t]&&e.splice(r,0,n)}}function Qse(n){var t=document.getElementById(n.diagramId),e="ej2_instances",i=t[""+e][0].nodes;void 0===i&&(i=function Gse(n){for(var t=[],e=0;e30?10:o/2;for(var h=0,c=0;c=l){var u=l-h;r=Gt(n[c],n[c+1]),s=R.transform(n[c],r,u);break}h+=d}return s},lb=function(n,t){if(n instanceof te||n instanceof de)for(var e=0;e=0||navigator.platform.indexOf("iPad")>=0||navigator.platform.indexOf("iPhone")>=0||navigator.platform.indexOf("MacIntel")>=0)&&("safari"===X.info.name||"webkit"===X.info.name)}function AF(n,t,e,i){return void 0!==t.previewSize[""+i]?t.previewSize[""+i]:void 0!==n.symbolPreview[""+i]?n.symbolPreview[""+i]:t[""+i]||e.actualSize[""+i]}function hm(n,t,e){return n&&n.parentId&&(e=(n=t.nameTable[n.parentId]).parentId?hm(n,t,e):n.id),e}function cm(n,t){return n.selectedItems.connectors.length>1&&0===n.selectedItems.nodes.length&&0!==t.rotateAngle}function Zse(n){if(n.arrowType&&""!==n.arrowType.trim())switch(n.arrowType){case"single-line-arrow":default:return{targetDecorator:"Arrow",strokeWidth:1};case"double-line-arrow":return{targetDecorator:"Arrow",strokeWidth:2};case"dotted-arrow":return{targetDecorator:"Arrow",strokeDashArray:"2,2"};case"single-line":return{targetDecorator:"None",strokeWidth:1};case"double-line":return{targetDecorator:"None",strokeWidth:2};case"dotted":return{targetDecorator:"None",strokeDashArray:"2,2"};case"wiggly-arrow":return{targetDecorator:"None",strokeWidth:1,opacity:0}}return{targetDecorator:"Arrow",strokeWidth:1}}var Jse=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),no=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},LF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Jse(t,n),no([I("None")],t.prototype,"shape",void 0),no([I("white")],t.prototype,"fill",void 0),no([I("Auto")],t.prototype,"horizontalAlignment",void 0),no([I("Auto")],t.prototype,"verticalAlignment",void 0),no([I(10)],t.prototype,"width",void 0),no([I(10)],t.prototype,"height",void 0),no([re({x:.5,y:1},R)],t.prototype,"offset",void 0),no([I("#1a1a1a")],t.prototype,"borderColor",void 0),no([I(1)],t.prototype,"borderWidth",void 0),no([re({},Jn)],t.prototype,"margin",void 0),no([I("")],t.prototype,"pathData",void 0),no([I("")],t.prototype,"content",void 0),no([I(0)],t.prototype,"cornerRadius",void 0),no([re({left:2,right:2,top:2,bottom:2},Jn)],t.prototype,"padding",void 0),no([I("#1a1a1a")],t.prototype,"iconColor",void 0),t}(Ee),Kse=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),oT=function(n){function t(){var e=null!==n&&n.apply(this,arguments)||this;return e.orientation="Vertical",e.measureChildren=void 0,e.considerPadding=!0,e}return Kse(t,n),t.prototype.measure=function(e){return this.desiredSize=this.measureStackPanel(e,"Horizontal"===this.orientation?this.updateHorizontalStack:this.updateVerticalStack),this.desiredSize},t.prototype.arrange=function(e){return this.actualSize=this.arrangeStackPanel(e,"Horizontal"===this.orientation?this.arrangeHorizontalStack:this.arrangeVerticalStack),this.updateBounds(),this.actualSize},t.prototype.measureStackPanel=function(e,i){var r=void 0;if(void 0!==this.children&&this.children.length>0)for(var s=0,o=this.children;s0){var r=void 0,s=void 0;r=this.offsetX-e.width*this.pivot.x+this.padding.left,s=this.offsetY-e.height*this.pivot.y+this.padding.top;for(var o=0,a=this.children;o0)for(var i=0,r=this.children;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},aoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return ooe(t,n),Bh([I("Horizontal")],t.prototype,"orientation",void 0),Bh([I("Center")],t.prototype,"type",void 0),Bh([I(void 0)],t.prototype,"offset",void 0),Bh([I(!1)],t.prototype,"enableRouting",void 0),Bh([I([])],t.prototype,"children",void 0),Bh([I("")],t.prototype,"assistants",void 0),Bh([I("")],t.prototype,"level",void 0),Bh([I("")],t.prototype,"hasSubTree",void 0),Bh([I("")],t.prototype,"rows",void 0),t}(Ee),Ni=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),q=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},loe=function(n){if(n)switch(n.type){case"Basic":default:return hb;case"Flow":return PF;case"Path":return NF;case"Image":return kF;case"Text":return Hd;case"Bpmn":return uT;case"Native":return dm;case"HTML":return OF;case"UmlActivity":return zF;case"UmlClassifier":return RF;case"SwimLane":return _d}return hb},ma=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),q([I("Basic")],t.prototype,"type",void 0),t}(Ee),NF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"Path"},q([I("Path")],t.prototype,"type",void 0),q([I("")],t.prototype,"data",void 0),t}(ma),dm=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"Native"},q([I("Native")],t.prototype,"type",void 0),q([I("")],t.prototype,"content",void 0),q([I("Stretch")],t.prototype,"scale",void 0),t}(ma),OF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"Html"},q([I("HTML")],t.prototype,"type",void 0),q([I("")],t.prototype,"content",void 0),t}(ma),kF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"Image"},q([I("Image")],t.prototype,"type",void 0),q([I("")],t.prototype,"source",void 0),q([I("None")],t.prototype,"scale",void 0),q([I("None")],t.prototype,"align",void 0),t}(ma),Hd=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"Text"},q([I("Text")],t.prototype,"type",void 0),q([I("")],t.prototype,"content",void 0),q([re({},Jn)],t.prototype,"margin",void 0),t}(ma),hb=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"BasicShape"},q([I("Basic")],t.prototype,"type",void 0),q([I("Rectangle")],t.prototype,"shape",void 0),q([I(0)],t.prototype,"cornerRadius",void 0),q([Bt([],R)],t.prototype,"points",void 0),t}(ma),PF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"FlowShape"},q([I("Flow")],t.prototype,"type",void 0),q([I("Terminator")],t.prototype,"shape",void 0),t}(ma),lT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"BpmnGateway"},q([I("None")],t.prototype,"type",void 0),t}(Ee),hT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"BpmnDataObject"},q([I("None")],t.prototype,"type",void 0),q([I(!1)],t.prototype,"collection",void 0),t}(Ee),hoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),q([I("None")],t.prototype,"type",void 0),q([I("None")],t.prototype,"loop",void 0),q([I(!1)],t.prototype,"call",void 0),q([I(!1)],t.prototype,"compensation",void 0),t}(Ee),cT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"BpmnEvent"},q([I("Start")],t.prototype,"event",void 0),q([I("None")],t.prototype,"trigger",void 0),t}(Ee),Bd=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"BpmnSubEvent"},q([I("None")],t.prototype,"trigger",void 0),q([I("Start")],t.prototype,"event",void 0),q([I("")],t.prototype,"id",void 0),q([re({},R)],t.prototype,"offset",void 0),q([Bt([],Kn)],t.prototype,"annotations",void 0),q([Bt([],Es)],t.prototype,"ports",void 0),q([I()],t.prototype,"width",void 0),q([I()],t.prototype,"height",void 0),q([re({},Jn)],t.prototype,"margin",void 0),q([I("Center")],t.prototype,"horizontalAlignment",void 0),q([I("Center")],t.prototype,"verticalAlignment",void 0),q([I(!0)],t.prototype,"visible",void 0),t}(Ee),coe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),q([re({id:"success",event:"End",offset:{x:1,y:.5}},Bd)],t.prototype,"success",void 0),q([re({id:"failure",event:"Intermediate",trigger:"Error",offset:{x:.25,y:1}},Bd)],t.prototype,"failure",void 0),q([re({id:"cancel",event:"Intermediate",trigger:"Cancel",offset:{x:.75,y:1}},Bd)],t.prototype,"cancel",void 0),t}(Ee),doe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),q([I("None")],t.prototype,"type",void 0),q([I(!1)],t.prototype,"adhoc",void 0),q([I("Default")],t.prototype,"boundary",void 0),q([I(!1)],t.prototype,"compensation",void 0),q([I("None")],t.prototype,"loop",void 0),q([I(!0)],t.prototype,"collapsed",void 0),q([Bt([],Bd)],t.prototype,"events",void 0),q([re({},coe)],t.prototype,"transaction",void 0),q([I(void 0)],t.prototype,"processes",void 0),t}(Ee),dT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"BpmnActivity"},q([I("Task")],t.prototype,"activity",void 0),q([re({},hoe)],t.prototype,"task",void 0),q([re({},doe)],t.prototype,"subProcess",void 0),t}(Ee),um=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return Ni(t,n),t.prototype.getClassName=function(){return"BpmnAnnotation"},q([I("")],t.prototype,"text",void 0),q([I("")],t.prototype,"id",void 0),q([I(0)],t.prototype,"angle",void 0),q([I()],t.prototype,"height",void 0),q([I()],t.prototype,"width",void 0),q([I(0)],t.prototype,"length",void 0),t}(Ee),uoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),q([I("")],t.prototype,"textAnnotationTarget",void 0),q([I("Auto")],t.prototype,"textAnnotationDirection",void 0),t}(Ee),uT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"BpmnShape"},q([I("Bpmn")],t.prototype,"type",void 0),q([I("Event")],t.prototype,"shape",void 0),q([re({},cT)],t.prototype,"event",void 0),q([re({},lT)],t.prototype,"gateway",void 0),q([re({},hT)],t.prototype,"dataObject",void 0),q([re({},dT)],t.prototype,"activity",void 0),q([re({},um)],t.prototype,"annotation",void 0),q([Bt([],um)],t.prototype,"annotations",void 0),q([re({},uoe)],t.prototype,"textAnnotation",void 0),t}(ma),zF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"UmlActivityShape"},q([I("UmlActivity")],t.prototype,"type",void 0),q([I("Action")],t.prototype,"shape",void 0),t}(ma),fT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"MethodArguments"},q([I("")],t.prototype,"name",void 0),q([I("")],t.prototype,"type",void 0),q([re({},qf)],t.prototype,"style",void 0),t}(Ee),op=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"UmlClassAttribute"},q([I("Public")],t.prototype,"scope",void 0),q([I(!1)],t.prototype,"isSeparator",void 0),q([re({fill:"#F9F9F9",strokeColor:"#CCCCCC"},Nl)],t.prototype,"separatorStyle",void 0),t}(fT),fm=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"UmlClassMethod"},q([Bt([],fT)],t.prototype,"parameters",void 0),t}(op),cb=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"UmlClass"},q([I("")],t.prototype,"name",void 0),q([Bt([],op)],t.prototype,"attributes",void 0),q([Bt([],fm)],t.prototype,"methods",void 0),q([re({},qf)],t.prototype,"style",void 0),t}(Ee),pT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"UmlInterface"},q([I(!1)],t.prototype,"isSeparator",void 0),q([re({fill:"#F9F9F9",strokeColor:"#CCCCCC"},Nl)],t.prototype,"separatorStyle",void 0),t}(cb),db=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"UmlEnumerationMember"},q([I("")],t.prototype,"name",void 0),q([I("")],t.prototype,"value",void 0),q([I(!1)],t.prototype,"isSeparator",void 0),q([re({fill:"#F9F9F9",strokeColor:"#CCCCCC"},Nl)],t.prototype,"separatorStyle",void 0),q([re({},qf)],t.prototype,"style",void 0),t}(Ee),gT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"UmlEnumeration"},q([I("")],t.prototype,"name",void 0),q([Bt([],db)],t.prototype,"members",void 0),q([re({},qf)],t.prototype,"style",void 0),t}(Ee),RF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"UmlClassifierShape"},q([I("UmlClassifier")],t.prototype,"type",void 0),q([re({},cb)],t.prototype,"classShape",void 0),q([re({},pT)],t.prototype,"interfaceShape",void 0),q([re({},gT)],t.prototype,"enumerationShape",void 0),q([I("Class")],t.prototype,"classifier",void 0),t}(ma),te=function(n){function t(e,i,r,s){var a,o=n.call(this,e,i,r,s)||this;return o.isCanvasUpdate=!1,o.status="None",o.parentId="",o.processId="",o.umlIndex=-1,o.outEdges=[],o.inEdges=[],o.isHeader=!1,o.isLane=!1,o.isPhase=!1,o.children&&o.children.length>0&&((!(a=r).style||!a.style.fill)&&(o.style.fill="transparent"),(!a.style||!a.style.strokeColor)&&(o.style.strokeColor="transparent")),o.shape&&"UmlActivity"===o.shape.type&&rb(r,o),o.shape&&"SwimLane"===o.shape.type&&fF(r,o),o.ports&&o.ports.length&&function vse(n){for(var t=0;t>";t=n;break;case"FinalNode":t=IF(e)}return t}(new Ze,i,this);break;case"Bpmn":if(e.bpmnModule){i=e.bpmnModule.initBPMNContent(i,this,e),this.wrapper.elementActions=this.wrapper.elementActions|Xr.ElementIsGroup;var v=this.shape.activity.subProcess;if(v.processes&&v.processes.length)for(var S=0,b=this.shape.activity.subProcess.processes;S>",margin:{left:10,right:10},id:"class",style:{fontSize:i.style.fontSize,color:i.style.color,fill:i.style.fill,textWrapping:r},offset:{x:.5,y:.3},constraints:Nr.ReadOnly}],constraints:(ie.Default|ie.HideThumbs)&~(ie.Rotate|ie.Drag|ie.Resize),verticalAlignment:"Stretch",horizontalAlignment:"Stretch",style:{fill:t.style.fill,strokeColor:"black"===t.style.strokeColor?"#ffffff00":t.style.strokeColor}},!0);return e.initObject(s),e.nodes.push(s),e.UpdateBlazorDiagramModel(s,"Node"),t.children.push(s.id),function toe(n,t,e,i){if("Enumeration"===n.shape.classifier){var r=e.members;if(r&&r.length){np(n,t);for(var s="",o=0;o0)for(var o=0;o0&&s.phaseSize&&(i+=s.phaseSize,$v(n,s.phaseSize)),s.lanes.length>0)for(o=0;o0){var a=0;for(o=0;o0&&"Horizontal"===r.orientation)for(l=0;l0&&(i+=r.phaseSize,o=Zv(r.phaseSize),n.push(o)),a=0;a0&&o.phaseSize){for(var l=0;l0)for(l=0;l0?e.nameTable[this.nodes[0].id].wrapper:e.nameTable[this.connectors[0].id].wrapper,this.annotation.id);i.children.push(s)}else if(this.nodes||this.connectors){for(var o=0;o-1}function VF(n,t,e){n=[];for(var i=0,r=e.length;i0?c.getElementsByTagName("svg")[0].outerHTML:c.getElementsByTagName("g").length>0?c.getElementsByTagName("g")[0].outerHTML:"",s.shape.content=h,n.content=h,c.parentElement.removeChild(c)}l="nodeTemplate"}else a=s,l="annotationTemplate";var p=document.getElementById(n.diagramId).ej2_instances[0];if("string"!=typeof n.content&&"function"!=typeof n.content||n.isTemplate)if(n.isTemplate){if(v=void 0,v=p.isReact?n.getNodeTemplate()($(e),p,l+"_"+("nodeTemplate"===l?e.id:n.nodeId+e.id),void 0,void 0,!1,i):p.isVue||p.isVue3?n.getNodeTemplate()?n.getNodeTemplate()($(e),p,l+"_"+("nodeTemplate"===l?e.id:n.nodeId+e.id),void 0,void 0,!1,i):(v=si("nodeTemplate"===l?p.nodeTemplate:p.annotationTemplate))($(e),p,l+"_"+("nodeTemplate"===l?e.id:n.nodeId+e.id),void 0,void 0,!1,i):n.getNodeTemplate()($(e),p,l+"_"+("nodeTemplate"===l?e.id:n.nodeId+e.id),void 0,void 0,!1))for(var M=0;M=1&&0===n.x&&("Clip"===i.textOverflow||"Ellipsis"===i.textOverflow)&&("Wrap"===i.textWrapping||"WrapWithOverflow"===i.textWrapping)&&(n.x=t[e-1]?t[e-1].x:-n.width/2),n.x}function QF(n,t,e,i){return e&&!t.template||t.template&&"function"==typeof t.template&&i.isReact?(n.isTemplate=!0,n.template=n.content=Fh(n,!0,t)):n.content=t.template,n}function Qe(){for(var e,t="",i=0;i<5;i++){if(typeof window<"u"&&"crypto"in window&&"getRandomValues"in crypto){var r=new Uint16Array(1);e=(window.msCrypto||window.crypto).getRandomValues(r)[0]%60}else e=Math.floor(61*Math.random());0===i&&e<10?i--:t+="0123456789ABCDEFGHIJKLMNOPQRSTUVWXTZabcdefghiklmnopqrstuvwxyz".substring(e,e+1)}return t}function GF(n){if(n)try{return"function"!=typeof n&&document.querySelectorAll(n).length?si(document.querySelector(n).innerHTML.trim()):si(n)}catch{return si(n)}}function xn(n){new Ne;var e=n.offsetY-n.actualSize.height*n.pivot.y,i=n.offsetY+n.actualSize.height*(1-n.pivot.y),r=n.offsetX-n.actualSize.width*n.pivot.x,s=n.offsetX+n.actualSize.width*(1-n.pivot.x);return Ne.toBounds([{x:r,y:e},{x:s,y:e},{x:r,y:i},{x:s,y:i}])}function yr(n){var t=new Ne,e=xn(n),i=e.middleLeft,r=e.topCenter,s=e.bottomCenter,o=e.middleRight,a=e.topLeft,l=e.topRight,h=e.bottomLeft,c=e.bottomRight;if(n.corners={topLeft:a,topCenter:r,topRight:l,middleLeft:i,middleRight:o,bottomLeft:h,bottomCenter:s,bottomRight:c},0!==n.rotateAngle||0!==n.parentTransform){var d=Bi();qi(d,n.rotateAngle+n.parentTransform,n.offsetX,n.offsetY),n.corners.topLeft=a=Ke(d,a),n.corners.topCenter=r=Ke(d,r),n.corners.topRight=l=Ke(d,l),n.corners.middleLeft=i=Ke(d,i),n.corners.middleRight=o=Ke(d,o),n.corners.bottomLeft=h=Ke(d,h),n.corners.bottomCenter=s=Ke(d,s),n.corners.bottomRight=c=Ke(d,c)}return t=Ne.toBounds([a,l,h,c]),n.corners.left=t.left,n.corners.right=t.right,n.corners.top=t.top,n.corners.bottom=t.bottom,n.corners.center=t.center,n.corners.width=t.width,n.corners.height=t.height,t}function $(n,t,e,i){var r={},s="properties";if(n){e=n.propName;var l=[],h=[];if((l=l.concat(Object.keys(n[""+s]||n))).push("version"),e){var c=Zi(t);h=c?c(e):[],l=l.concat(h)}for(var d=function Ooe(n){switch(n){case"nodes":case"children":return["inEdges","outEdges","parentId","processId","nodeId","umlIndex","isPhase","isLane"];case"connectors":return["parentId"];case"annotation":case"annotations":return["nodeId"];case"shape":return["hasHeader"];case"layers":return["objectZIndex"]}return[]}(e),u=0,f=l=l.concat(d);u0&&(e=r),r=Math.floor(Poe(e,i)),s=Bc(o+=n.substr(e,r),t)}while(s<=t.width);for(o=o.substr(0,e),a=e;a=t.width){n=n.substr(0,o.length-1);break}return"Ellipsis"===t.textOverflow?(n=n.substr(0,n.length-3),n+="..."):n=n.substr(0,n.length),n}function MT(n,t){if("NoWrap"===t&&"PreserveAll"===n)return"pre";var e="";switch(n){case"CollapseAll":e="nowrap";break;case"CollapseSpace":e="pre-line";break;case"PreserveAll":e="pre-wrap"}return e}function wT(n,t){var e=Bi();qi(e,t,0,0);var i=Ke(e,{x:0,y:0}),r=Ke(e,{x:n.width,y:0}),s=Ke(e,{x:0,y:n.height}),o=Ke(e,{x:n.width,y:n.height}),a=Math.min(i.x,r.x,s.x,o.x),l=Math.min(i.y,r.y,s.y,o.y),h=Math.max(i.x,r.x,s.x,o.x),c=Math.max(i.y,r.y,s.y,o.y);return new me(h-a,c-l)}function xs(n,t,e,i){if(0!==n){var r=Bi();return qi(r,n,t,e),Ke(r,i)}return i}function Zi(n){return void 0!==n&&"string"==typeof n&&(n=Y(n,window)),n}var bo=function(){function n(){}return n.getContext=function(t){return t.getContext("2d")},n.setCanvasSize=function(t,e,i){t&&(t.setAttribute("width",e.toString()),t.setAttribute("height",i.toString()))},n.prototype.renderGradient=function(t,e,i,r){var s,o,a;if("None"!==t.gradient.type){for(var l=0;l0?(w=0===S.r1?e.arc[parseInt(r.toString(),10)].r1:S.r1,C=0===S.r2?e.arc[parseInt(r.toString(),10)].r2:S.r2,r++):(w=S.r1,C=S.r2);var D=S.angle*(Math.PI/180),A=S.largeArc,x=S.sweep,P={x:u,y:f},L={x:Math.cos(D)*(M.x-P.x)/2+Math.sin(D)*(M.y-P.y)/2,y:-Math.sin(D)*(M.x-P.x)/2+Math.cos(D)*(M.y-P.y)/2},O=Math.pow(L.x,2)/Math.pow(w,2)+Math.pow(L.y,2)/Math.pow(C,2);O>1&&(w*=Math.sqrt(O),C*=Math.sqrt(O));var N=Math.pow(C,2)*Math.pow(L.x,2),T=(A===x?-1:1)*Math.sqrt((Math.pow(w,2)*Math.pow(C,2)-Math.pow(w,2)*Math.pow(L.y,2)-N)/(Math.pow(w,2)*Math.pow(L.y,2)+Math.pow(C,2)*Math.pow(L.x,2)));isNaN(T)&&(T=0);var z={x:T*w*L.y/C,y:T*-C*L.x/w},U={x:(M.x+P.x)/2+Math.cos(D)*z.x-Math.sin(D)*z.y,y:(M.y+P.y)/2+Math.sin(D)*z.x+Math.cos(D)*z.y},B=this.a([1,0],[(L.x-z.x)/w,(L.y-z.y)/C]),j=[(L.x-z.x)/w,(L.y-z.y)/C],Q=[(-L.x-z.x)/w,(-L.y-z.y)/C],oe=this.a(j,Q);this.r(j,Q)<=-1&&(oe=Math.PI),this.r(j,Q)>=1&&(oe=0);var fe=B+oe/2*(x?1:-1);if(Math.cos(fe),Math.sin(fe),S.centp=U,S.xAxisRotation=D,S.rx=w,S.ry=C,S.a1=B,S.ad=oe,S.sweep=x,null!=s){var De=w>C?w:C,xe=w>C?1:w/C,Ie=w>C?C/w:1;s.save(),s.translate(U.x,U.y),s.rotate(D),s.scale(xe,Ie),s.arc(0,0,De,B,B+oe,!x),s.scale(1/xe,1/Ie),s.rotate(-D),s.translate(-U.x,-U.y),s.restore()}break;case"Z":case"z":s.closePath(),u=o,f=a}o=u,a=f}}},n.prototype.drawText=function(t,e,i,r,s,o,a){if(e.content&&!0===e.visible){var l=n.getContext(t);l.save(),this.setStyle(t,e),o&&(e.fontSize*=o),this.applyFlipAndRotate(l,e,t,e.x+e.width*e.pivotX,e.y+e.height*e.pivotY),this.setFontStyle(t,e);var u,d=0;u=e.childNodes;var f=e.wrapBounds;if(l.fillStyle=e.color,f){var p=this.labelAlign(e,f,u);for(d=0;de.width&&"Wrap"!==e.textOverflow&&"NoWrap"===e.textWrapping&&(g.text=qF(g.text,e)),"Clip"!==e.textOverflow&&"Ellipsis"!==e.textOverflow||"Wrap"!==e.textWrapping?l.fillText(g.text,v,y):ya.actualSize.height+a.bounds.y&&(g.text=g.text.slice(0,g.text.length-3),g.text=g.text.concat("...")),l.fillText(g.text,v,y)),"Underline"===e.textDecoration||"Overline"===e.textDecoration||"LineThrough"===e.textDecoration){var M=v,w=void 0,D=v+l.measureText(g.text).width,A=void 0;switch(e.textDecoration){case"Underline":w=y+2,A=y+2;break;case"Overline":w=p.y+g.dy*d,A=p.y+g.dy*d;break;case"LineThrough":w=(y+p.y+g.dy*d)/2+2,A=(y+p.y+g.dy*d)/2+2}l.beginPath(),l.moveTo(M,w),l.lineTo(D,A),l.strokeStyle=e.color,l.lineWidth=.08*e.fontSize,l.globalAlpha=e.opacity,l.stroke()}}}l.restore()}},n.prototype.applyFlipAndRotate=function(t,e,i,r,s){"Horizontal"===e.flip||"Vertical"===e.flip?(t.translate(e.x+e.width/2,e.y+e.height/2),t.rotate(-e.angle*Math.PI/180),t.translate(-e.x-e.width/2,-e.y-e.height/2)):this.rotateContext(i,e.angle,r,s),t.translate(e.x,e.y),"Horizontal"===e.flip?(t.scale(-1,1),t.translate(-1*e.width,0)):"Vertical"===e.flip?(t.scale(1,-1),t.translate(0,-1*e.height)):"Both"===e.flip&&(t.scale(-1,-1),t.translate(-1*e.width,-1*e.height)),t.translate(-e.x,-e.y)},n.prototype.loadImage=function(t,e,i,r,s){var o=new Image;o.src=e.source,this.image(t,o,e.x,e.y,e.width,e.height,e)},n.prototype.drawImage=function(t,e,i,r){var s=this;if(e.visible){var o=n.getContext(t);o.save();var a=e.x+e.width*e.pivotX,l=e.y+e.height*e.pivotY,h=new Image;h.src=e.source,this.setStyle(t,e),o.canvas.id.split("_"),this.applyFlipAndRotate(o,e,t,a,l),r?h.onload=function(){s.loadImage(o,e,t,a,l)}:this.loadImage(o,e,t,a,l),o.restore()}},n.prototype.image=function(t,e,i,r,s,o,a){t.beginPath();var l=e.width,h=e.height,c=s,d=o,u=0,f=0;if(a&&"None"!==a.alignment){var p=a.alignment.toLowerCase().substr(1,3),g=a.alignment.toLowerCase().substr(5,3);if("Slice"===a.scale){var v=function(){u=c,f=h*c/l},y=function(){u=l*d/h,f=d};c>d?(v(),d>f&&y()):c===d?l>h?y():v():(y(),c>u&&v());var S=this.getSliceOffset(p,u,c,l),b=this.getSliceOffset(g,f,d,h),M=l-S,w=h-b,C=u-S*(u/l),D=f-b*(f/h),A=Tt("canvas",{width:s.toString(),height:o.toString()});A.getContext("2d").drawImage(e,S,b,M,w,0,0,C,D),t.drawImage(A,i,r,s,o)}else if("Meet"===a.scale){var P=h/l,L=d/c;f=L>P?c*P:d,i+=this.getMeetOffset(p,u=L>P?c:d/P,c),r+=this.getMeetOffset(g,f,d),t.drawImage(e,0,0,l,h,i,r,u,f)}else t.drawImage(e,i,r,s,o)}else if("None"!==a.flip){var O=1,N=1;("Horizontal"===a.flip||"Both"===a.flip)&&(i=-i,s=-s,O=-1),("Vertical"===a.flip||"Both"===a.flip)&&(r=-r,o=-o,N=-1),t.scale(O,N),t.drawImage(e,i,r,s,o)}else t.drawImage(e,i,r,s,o);t.closePath()},n.prototype.getSliceOffset=function(t,e,i,r){switch(t){case"min":default:return 0;case"mid":return(e-i)/2*r/e;case"max":return(e-i)*r/e}},n.prototype.getMeetOffset=function(t,e,i){var r=Math.max(e,i),s=Math.min(e,i);switch(t){case"min":default:return 0;case"mid":return(r-s)/2;case"max":return r-s}},n.prototype.m=function(t){return Math.sqrt(Math.pow(t[0],2)+Math.pow(t[1],2))},n.prototype.r=function(t,e){return(t[0]*e[0]+t[1]*e[1])/(this.m(t)*this.m(e))},n.prototype.a=function(t,e){return(t[0]*e[1]t.width&&("Ellipsis"===t.textOverflow||"Clip"===t.textOverflow)&&"NoWrap"===t.textWrapping?0:.5*t.width:"right"===t.textAlign&&(c=1*t.width),s.x=t.x+c+(e?e.x:0),s.y=a+d-r.height/2,s},n}(),vb=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Vi=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Roe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return vb(t,n),Vi([I("")],t.prototype,"source",void 0),Vi([I("transparent")],t.prototype,"color",void 0),Vi([I("None")],t.prototype,"scale",void 0),Vi([I("None")],t.prototype,"align",void 0),t}(Ee),Hoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return vb(t,n),Vi([I("Page")],t.prototype,"mode",void 0),Vi([I("PageSettings")],t.prototype,"region",void 0),Vi([re({top:25,bottom:25,left:25,right:25},Jn)],t.prototype,"margin",void 0),Vi([I(!1)],t.prototype,"canZoomIn",void 0),Vi([I(void 0)],t.prototype,"customBounds",void 0),Vi([I(!1)],t.prototype,"canFit",void 0),t}(Ee),Boe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return vb(t,n),Vi([I(null)],t.prototype,"width",void 0),Vi([I(null)],t.prototype,"height",void 0),Vi([re({},Jn)],t.prototype,"margin",void 0),Vi([I("Landscape")],t.prototype,"orientation",void 0),Vi([I("Infinity")],t.prototype,"boundaryConstraints",void 0),Vi([re({},Roe)],t.prototype,"background",void 0),Vi([I(!1)],t.prototype,"multiplePage",void 0),Vi([I(!1)],t.prototype,"showPageBreaks",void 0),Vi([re({},Hoe)],t.prototype,"fitOptions",void 0),t}(Ee),Foe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return vb(t,n),Vi([I(0)],t.prototype,"horizontalOffset",void 0),Vi([I(0)],t.prototype,"verticalOffset",void 0),Vi([I(1)],t.prototype,"currentZoom",void 0),Vi([I(0)],t.prototype,"viewPortWidth",void 0),Vi([I(0)],t.prototype,"viewPortHeight",void 0),Vi([I(.2)],t.prototype,"minZoom",void 0),Vi([I(30)],t.prototype,"maxZoom",void 0),Vi([I("Diagram")],t.prototype,"scrollLimit",void 0),Vi([I()],t.prototype,"scrollableArea",void 0),Vi([I(!1)],t.prototype,"canAutoScroll",void 0),Vi([I(100)],t.prototype,"autoScrollFrequency",void 0),Vi([re({left:15,right:15,top:15,bottom:15},Jn)],t.prototype,"autoScrollBorder",void 0),Vi([re({left:0,right:0,top:0,bottom:0},Jn)],t.prototype,"padding",void 0),Vi([I(.2)],t.prototype,"zoomFactor",void 0),t}(Ee),_oe=function(){function n(){this.services={}}return n.prototype.register=function(t,e){this.services[""+t]=e},n.prototype.getService=function(t){return this.services[""+t]},n}(),$F=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),ya=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},ZF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return $F(t,n),ya([I("lightgray")],t.prototype,"lineColor",void 0),ya([I("")],t.prototype,"lineDashArray",void 0),ya([I([1.25,18.75,.25,19.75,.25,19.75,.25,19.75,.25,19.75])],t.prototype,"lineIntervals",void 0),ya([I([1,19,.5,19.5,.5,19.5,.5,19.5,.5,19.5])],t.prototype,"dotIntervals",void 0),ya([I([20])],t.prototype,"snapIntervals",void 0),t}(Ee),Uoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return $F(t,n),ya([re({},ZF)],t.prototype,"horizontalGridlines",void 0),ya([re({},ZF)],t.prototype,"verticalGridlines",void 0),ya([I(Kt.All)],t.prototype,"constraints",void 0),ya([I(5)],t.prototype,"snapAngle",void 0),ya([I("Lines")],t.prototype,"gridType",void 0),ya([I(5)],t.prototype,"snapObjectDistance",void 0),ya([I("#07EDE1")],t.prototype,"snapLineColor",void 0),t}(Ee),JF=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),el=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},KF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return JF(t,n),el([I(5)],t.prototype,"interval",void 0),el([I(100)],t.prototype,"segmentWidth",void 0),el([I("Horizontal")],t.prototype,"orientation",void 0),el([I("RightOrBottom")],t.prototype,"tickAlignment",void 0),el([I("red")],t.prototype,"markerColor",void 0),el([I(25)],t.prototype,"thickness",void 0),el([I(null)],t.prototype,"arrangeTick",void 0),t}(Ee),joe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return JF(t,n),el([I(!1)],t.prototype,"showRulers",void 0),el([I(!0)],t.prototype,"dynamicGrid",void 0),el([re({orientation:"Horizontal"},KF)],t.prototype,"horizontalRuler",void 0),el([re({orientation:"Vertical"},KF)],t.prototype,"verticalRuler",void 0),t}(Ee),Voe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),e_=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Woe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Voe(t,n),e_([I("")],t.prototype,"property",void 0),e_([I("")],t.prototype,"field",void 0),t}(Ee),CT=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),ln=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},t_=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return CT(t,n),ln([I("")],t.prototype,"read",void 0),ln([I("")],t.prototype,"create",void 0),ln([I("")],t.prototype,"update",void 0),ln([I("")],t.prototype,"destroy",void 0),ln([I()],t.prototype,"customFields",void 0),t}(Ee),Yoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return CT(t,n),ln([I("")],t.prototype,"id",void 0),ln([I("")],t.prototype,"sourceID",void 0),ln([I("")],t.prototype,"targetID",void 0),ln([I(null)],t.prototype,"sourcePointX",void 0),ln([I(null)],t.prototype,"sourcePointY",void 0),ln([I(null)],t.prototype,"targetPointX",void 0),ln([I(null)],t.prototype,"targetPointY",void 0),ln([I(null)],t.prototype,"dataManager",void 0),ln([re({},t_)],t.prototype,"crudAction",void 0),t}(Ee),Qoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return CT(t,n),ln([I("")],t.prototype,"id",void 0),ln([I(null)],t.prototype,"dataManager",void 0),ln([I(null)],t.prototype,"dataSource",void 0),ln([I("")],t.prototype,"root",void 0),ln([I("")],t.prototype,"parentId",void 0),ln([I()],t.prototype,"doBinding",void 0),ln([Bt([],Woe)],t.prototype,"dataMapSettings",void 0),ln([re({},t_)],t.prototype,"crudAction",void 0),ln([re({},Yoe)],t.prototype,"connectionDataSource",void 0),t}(Ee),i_=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Cr=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Goe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return i_(t,n),Cr([I("LeftInFlow")],t.prototype,"yesBranchDirection",void 0),Cr([I("RightInFlow")],t.prototype,"noBranchDirection",void 0),Cr([I(["Yes","True"])],t.prototype,"yesBranchValues",void 0),Cr([I(["No","False"])],t.prototype,"noBranchValues",void 0),t}(Ee),Xoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return i_(t,n),Cr([I("")],t.prototype,"fixedNode",void 0),Cr([I(30)],t.prototype,"horizontalSpacing",void 0),Cr([I("SamePoint")],t.prototype,"connectionPointOrigin",void 0),Cr([I("Nonlinear")],t.prototype,"arrangement",void 0),Cr([I(30)],t.prototype,"verticalSpacing",void 0),Cr([I(30)],t.prototype,"maxIteration",void 0),Cr([I(40)],t.prototype,"springFactor",void 0),Cr([I(50)],t.prototype,"springLength",void 0),Cr([re({left:50,top:50,right:0,bottom:0},Jn)],t.prototype,"margin",void 0),Cr([I("Auto")],t.prototype,"horizontalAlignment",void 0),Cr([I("Auto")],t.prototype,"verticalAlignment",void 0),Cr([I("TopToBottom")],t.prototype,"orientation",void 0),Cr([I("Auto")],t.prototype,"connectionDirection",void 0),Cr([I("Default")],t.prototype,"connectorSegments",void 0),Cr([I("None")],t.prototype,"type",void 0),Cr([I()],t.prototype,"getLayoutInfo",void 0),Cr([I()],t.prototype,"layoutInfo",void 0),Cr([I()],t.prototype,"getBranch",void 0),Cr([I()],t.prototype,"bounds",void 0),Cr([I(!0)],t.prototype,"enableAnimation",void 0),Cr([I(!1)],t.prototype,"enableRouting",void 0),Cr([I("")],t.prototype,"root",void 0),Cr([re({},Goe)],t.prototype,"flowchartLayoutSettings",void 0),t}(Ee),qoe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),r_=function(n){function t(e,i){var r=n.call(this,e,!0)||this;return r.oldValue=null,r.endPoint=i,r}return qoe(t,n),t.prototype.mouseDown=function(e){var i,r=!0;if(e.source&&e.source.connectors&&(i=e.source.connectors[0]),e.info&&e.actualObject&&(r=e.info.ctrlKey&&"Orthogonal"!==e.actualObject.type),i&&r){this.inAction=!0,this.undoElement=$(e.source),n.prototype.mouseDown.call(this,e);for(var s=0;s0)1!==s&&this.removePrevSegment(i,s);else if(a){var l=R.distancePoints(a.points[0],a.points[1]);Math.abs(a.length||0===a.length?a.length:l)<=5&&this.removeNextSegment(i,s)}this.commandHandler.updateEndPoint(i,r),i.selectedSegmentIndex=0}if(this.undoElement){var c=$(e.source);this.commandHandler.addHistoryEntry({type:"SegmentChanged",redoObject:c,undoObject:this.undoElement,category:"Internal"})}if(i.isBezierEditing&&(i.isBezierEditing=!1),this.prevPosition!==this.startPosition){var u={source:i,state:"Completed",oldValue:this.oldValue,newValue:$(this.selectedSegment),cancel:!1,segment:this.selectedSegment};this.commandHandler.triggerEvent(Ce.segmentChange,u)}n.prototype.mouseUp.call(this,e)},t.prototype.removePrevSegment=function(e,i){var r=e.segments[i-2],s=e.segments[i+1];if(s&&!((s.length||0===s.length?s.length:R.distancePoints(s.points[0],s.points[1]))<=5)){var a=e.segments.slice(i-1,i+1),l={element:e,removeSegments:a,type:"Removal",cancel:!1};if(this.commandHandler.triggerEvent(Ce.segmentCollectionChange,l),!l.cancel){var h=e.segments[i+1];e.segments.splice(i-1,2);var c=this.selectedSegment;"Left"===c.direction||"Right"===c.direction?(r.points[r.points.length-1].x=h.points[0].x,h.points[0].y=r.points[r.points.length-1].y):(r.points[r.points.length-1].y=h.points[0].y,h.points[0].x=r.points[r.points.length-1].x),(c.length||0===c.length)&&this.findSegmentDirection(r),this.findSegmentDirection(h)}}},t.prototype.findSegmentDirection=function(e){e.direction&&(e.length||0===e.length)&&(e.length=R.distancePoints(e.points[0],e.points[e.points.length-1]),e.direction=R.direction(e.points[0],e.points[e.points.length-1]))},t.prototype.removeNextSegment=function(e,i){var l,h,r=this.selectedSegment,s=e.segments[i-1],o=e.segments[i+2],a=e.segments[i+1];if(a.length||0===a.length?(l=e.segments.slice(i,2),h={element:e,removeSegments:l,type:"Removal",cancel:!1},this.commandHandler.triggerEvent(Ce.segmentCollectionChange,h={element:e,removeSegments:l,type:"Removal",cancel:!1}),h.cancel||(e.segments.splice(i,2),"Top"===r.direction||"Bottom"===r.direction?(o.points[0].y=r.points[0].y,s.points[s.points.length-1].x=o.points[0].x):(o.points[0].x=r.points[0].x,s.points[s.points.length-1].y=o.points[0].y))):(l=e.segments.slice(i+1,1),this.commandHandler.triggerEvent(Ce.segmentCollectionChange,h={element:e,removeSegments:l,type:"Removal",cancel:!1}),h.cancel||(e.segments.splice(i+1,1),"Top"===r.direction||"Bottom"===r.direction?s.points[s.points.length-1].x=a.points[a.points.length-1].x:s.points[s.points.length-1].y=a.points[a.points.length-1].y,this.findSegmentDirection(s),r.length=r.direction=null)),s&&o&&!h.cancel&&(s.length=R.distancePoints(s.points[0],o.points[0]),s.direction=R.direction(s.points[0],o.points[0]),o.length||0===o.length)){o.length=R.distancePoints(s.points[s.points.length-1],o.points[o.points.length-1]);var c=s.points,d=o.points;o.direction=R.direction(c[c.length-1],d[d.length-1])}},t.prototype.addOrRemoveSegment=function(e,i,r){for(var s,o,a=[],l={segments:e.segments},h=0;h0?"Bottom":"Top":r>0?"Right":"Left",length:i.points[0].x===i.points[1].x?s:r},!0)),l.push(new wi(e,"segments",{type:"Orthogonal",direction:c,length:h/2},!0));var f={element:e,addSegments:l,type:"Addition",cancel:!1};return this.commandHandler.triggerEvent(Ce.segmentCollectionChange,f),f.cancel||(e.segments=l.concat(e.segments),a=o+2),a},t.prototype.insertFirstSegment=function(e,i,r,s,o){var a,l,d,u,h=[];if(e.sourcePortID&&i.length&&e.segments[0].points.length>2)for(var f=void 0,p=0;p0?"Bottom":"Top":r>0?"Right":"Left"),f=u,h.push(u)}else h.push(new wi(e,"segments",{type:"Orthogonal",direction:i.direction,length:i.length/3},!0)),"Bottom"===i.direction||"Top"===i.direction?(l=Math.abs(r),a=r>0?"Right":"Left"):(l=Math.abs(s),a=s>0?"Bottom":"Top"),u=new wi(e,"segments",{type:"Orthogonal",direction:a,length:l},!0),h.push(u);var y={element:e,addSegments:h,type:"Addition",cancel:!1};if(this.commandHandler.triggerEvent(Ce.segmentCollectionChange,y),!y.cancel){if(e.sourcePortID&&i.length&&e.segments[0].points.length>2)e.segments.splice(0,1),d=1;else{var S=e.segments[1];S&&S.length&&(S.length=a!==S.direction?S.length+l:S.length-l),d=2,i.length=2*i.length/3}e.segments=h.concat(e.segments)}return d},t.prototype.updateAdjacentSegments=function(e,i,r,s){var o=e.segments[parseInt(i.toString(),10)],a=o.points[o.points.length-1],h=!0;"Orthogonal"===o.type&&(o.points[0]=o.points[0],o.points[o.points.length-1]=a,e.segments[i-1]&&(h=this.updatePreviousSegment(r,s,e,i)),e.segments.length-1>i&&h&&this.updateNextSegment(e,o,e.segments[i+1],r,s))},t.prototype.addTerminalSegment=function(e,i,r,s,o){var l,h,c,d,a=e.segments.indexOf(i),u=[],f=e.segments.pop(),p=e.segments[e.segments.length-1];l=p&&"Orthogonal"===p.type?p:null;for(var g=0;g0&&"Left"===o.direction?c.middleLeft:c.middleRight,o.length>c.width/2?Math.abs(a.length)0&&"Top"===o.direction?c.topCenter:c.bottomCenter,o.length>c.height/2?Math.abs(a.length)1)for(var a=0,l=this.diagram.views;a0)for(var e=t===Ce.onUserHandleMouseLeave?this.previousAction:this.action,i={element:void 0},r=0;r0)for(var r={element:void 0},s=void 0,o=void 0,a=0;a-1&&(o=s,this.previousTarget=i,this.targetItem=e),o===e.fixedUserHandles[parseInt(a.toString(),10)].id&&(r.element=e.fixedUserHandles[parseInt(a.toString(),10)],this.userHandle(t,a,r,e))},n.prototype.mouseDown=function(t){var e=this;if("touchstart"===t.type&&(this.timeOutTapHold=setTimeout(function(){("Select"===e.action||"Drag"===e.action)&&e.mouseMove(t,void 0)},500)),!0!==this.inAction||!(this.tool instanceof qI||this.tool instanceof pa)){this.focus=!0;var i=t.touches,r=!!document.getElementsByClassName("e-dragclone")[0];if(this.isMouseOnScrollBar(t)&&!r)return this.isScrolling=!0,void t.preventDefault();if(this.checkFixedUserHandleEvent(Ce.onFixedUserHandleMouseDown,this.targetItem,this.previousTarget),this.checkUserHandleEvent(Ce.onUserHandleMouseDown),!this.checkEditBoxAsTarget(t)&&Yv(this.diagram)||Lc(this.diagram)&&!UI(this.diagram))if(("Select"===this.action||"Drag"===this.action)&&this.diagram.updatePortVisibility(this.hoverElement,ci.Hover,!0),!(this.tool instanceof Rl||this.tool instanceof Hl)||2!==t.button&&2!==t.buttons)if(!0===this.inAction&&!0===this.isMouseDown&&(this.tool instanceof Rl||this.tool instanceof Hl))this.isMouseDown=!0,this.eventArgs={},this.getMouseEventArgs(this.currentPosition,this.eventArgs),this.eventArgs.position=this.currentPosition,this.tool.mouseDown(this.eventArgs);else{this.isMouseDown=!0,this.currentPosition=this.prevPosition=this.getMousePosition(t),this.eventArgs={},this.diagram.textEditing&&!this.isMouseOnScrollBar(t)&&(this.diagram.endEdit(),this.diagram.textEditing=!1,"Canvas"===this.diagram.mode&&1!==this.diagram.scroller.currentZoom&&this.diagram.refreshDiagramLayer());var o=this.getTargetElement();this.action=this.diagram.findActionToBeDone(o.obj,o.sourceElement,this.currentPosition,o.target);var a=this.isMetaKey(t);a&&t.shiftKey&&this.diagram.connectorEditingToolModule?this.action="SegmentEnd":(a||t.shiftKey)&&(Vv(this.diagram)||Wv(this.diagram))&&(this.action="Select"),this.tool=this.diagram.getTool(this.action),this.tool||(this.action="Select",this.tool=this.diagram.getTool(this.action)),this.getMouseEventArgs(this.currentPosition,this.eventArgs),(a||t.shiftKey)&&(this.eventArgs.info=a&&t.shiftKey?{ctrlKey:a,shiftKey:t.shiftKey}:{ctrlKey:!0}),this.eventArgs.position=this.currentPosition;var h=this.diagram.selectedItems.nodes;if(this.tool.mouseDown(this.eventArgs),this.diagram.selectedItems.canToggleSelection&&h&&this.diagram.selectedItems.nodes&&this.tool instanceof fa)for(var c=0;c=2&&(this.touchStartList=VF(this.touchStartList,0,i)),i||t.preventDefault())}else this.inAction=!1,this.tool.mouseUp(this.eventArgs);!this.isForeignObject(t.target)&&!this.isForeignObject(t.target,!0)&&!i&&t.preventDefault()}},n.prototype.mouseMoveExtend=function(t,e){(this.tool instanceof Rl||this.tool instanceof Hl)&&this.tool.mouseMove(this.eventArgs),this.diagram.scrollSettings.canAutoScroll?this.checkAutoScroll(t):this.blocked||this.tool.mouseMove(this.eventArgs),this.eventArgs.target&&(this.hoverElement=this.eventArgs.target);var i=!((this.eventArgs.target instanceof te||this.eventArgs.target instanceof de)&&(e instanceof te||e instanceof de));this.tool instanceof zd&&this.diagram.updatePortVisibility(this.hoverElement instanceof te||this.hoverElement instanceof de?this.hoverElement:this.hoverNode,ci.Connect|ci.Hover,i),this.hoverElement instanceof te&&this.hoverNode instanceof te&&this.hoverNode&&this.hoverNode.id!==this.hoverElement.id&&this.diagram.updatePortVisibility(this.hoverNode,ci.Connect|ci.Hover,!0),this.hoverElement instanceof de&&this.hoverElement.ports.length>0&&this.diagram.updatePortVisibility(this.hoverElement,ci.Connect|ci.Hover,!0),this.previousElement instanceof te&&this.hoverElement&&this.previousElement.id!==this.hoverElement.id&&this.diagram.updatePortVisibility(this.previousElement,ci.Connect|ci.Hover,!0),this.previousElement=this.hoverElement,""!==this.diagram.tooltip.content&&(this.hoverElement=null),this.hoverNode=i?null:e},n.prototype.checkAction=function(t){if("LabelSelect"===this.action&&this.eventArgs.sourceWrapper&&(this.eventArgs.sourceWrapper instanceof ai||this.eventArgs.sourceWrapper instanceof es)){var e=this.commandHandler.findTarget(this.eventArgs.sourceWrapper,this.eventArgs.source);!_r(this.diagram,e,!1,this.eventArgs.sourceWrapper)&&ro(e)&&(this.action="LabelDrag",this.tool=this.getTool(this.action),this.tool.mouseDown(this.initialEventArgs))}else ro(t)&&Ad(t)&&this.initialEventArgs&&this.initialEventArgs.source&&"Select"===this.action&&(!_r(this.diagram,this.eventArgs.source,!1)&&this.eventArgs.source instanceof ei&&this.getMouseEventArgs(this.currentPosition,this.eventArgs),(!(t instanceof de)||t instanceof de&&!(wr(this.currentPosition,t.sourcePoint,t.hitPadding)||wr(this.currentPosition,t.targetPoint,t.hitPadding)))&&(this.action="Drag"),this.tool=this.getTool(this.action),this.tool.mouseDown(this.initialEventArgs))},n.prototype.isSwimlaneElements=function(t){return!(t&&(t.isLane||t.isPhase||t.isHeader))},n.prototype.canShowTouchTooltip=function(t){return!!("touchstart"===t.type&&this.diagram.tool&ri.SingleSelect&&this.diagram.tool&ri.ZoomPan)&&(this.isMouseDown=!1,!0)},n.prototype.mouseMove=function(t,e){if(this.focus=!0,"touchmove"===t.type&&(this.touchArgs={target:t.target,type:"touchmove"}),this.isScrolling)t.preventDefault();else if(Yv(this.diagram)||Lc(this.diagram)&&!UI(this.diagram)){this.currentPosition=this.getMousePosition(t);var i=this.diagram.findObjectsUnderMouse(this.currentPosition),r=this.diagram.findObjectUnderMouse(i,this.action,this.inAction);!function nse(n,t){n.rulerSettings.showRulers&&(n.hRuler.drawRulerMarker(n.hRuler.element,t,n.scroller.horizontalOffset),n.vRuler.drawRulerMarker(n.vRuler.element,t,n.scroller.verticalOffset))}(this.diagram,this.currentPosition);var s=!1,o=void 0;if("touchmove"===t.type&&(e=t.touches)&&e.length>1&&(this.touchMoveList=VF(this.touchMoveList,0,e),"PinchZoom"!==this.action&&(s=!0)),!1===R.equals(this.currentPosition,this.prevPosition)||this.inAction||this.canShowTouchTooltip(t)){if(!1===this.isMouseDown||s){this.eventArgs={};var a=null,l=void 0;if(null!==r){if((a=this.diagram.findElementUnderMouse(r,this.currentPosition,this.diagram))&&(l=this.commandHandler.findTarget(a,r)),(l instanceof Kn||l instanceof Or)&&(l.tooltip&&""!==l.tooltip.content||(l=r)),l!==this.hoverElement){var h=this.getContent();this.hoverElement&&"Auto"===this.hoverElement.tooltip.openOn&&""!==h&&this.elementLeave(),this.diagram.updatePortVisibility(this.hoverElement,ci.Hover,!0),r instanceof te&&(this.hoverNode=r);var c=!0;!this.isSwimlaneElements(r)&&this.hoverElement&&this.isSwimlaneElements(this.hoverElement)&&(c=!1),this.hoverElement=c?r:this.hoverElement;var d,u=void 0;(d=this.diagram.findElementUnderMouse(r,this.currentPosition,this.diagram))instanceof Ze&&((u=this.commandHandler.findTarget(d,r))instanceof Es||u instanceof Tc)&&this.hoverElement.constraints&oi.ToolTip&&(this.hoverElement=u);var f=void 0;d instanceof ai&&((f=this.commandHandler.findTarget(d,r))instanceof Kn||f instanceof Or)&&f.constraints&Nr.Tooltip&&(this.hoverElement=f),c?this.elementEnter(this.currentPosition,!1):this.hoverElement=r}else this.hoverElement&&this.hoverElement===l&&this.hoverElement.tooltip.content&&void 0!==this.diagram.tooltipObject&&"Mouse"===this.hoverElement.tooltip.relativeMode&&this.setTooltipOffset(this.currentPosition);a&&(o=this.commandHandler.findTarget(a,r))}this.action=this.diagram.findActionToBeDone(r,a,this.currentPosition,o),this.checkFixedUserHandleEvent(Ce.onFixedUserHandleMouseEnter,r,a),this.checkUserHandleEvent(Ce.onUserHandleMouseEnter),this.checkPreviousAction(),this.getMouseEventArgs(this.currentPosition,this.eventArgs),this.tool=this.getTool(this.action),this.mouseEvents(),this.tool instanceof pa||this.tool instanceof Hl||this.tool instanceof Rl?this.tool.mouseMove(this.eventArgs):e&&this.tool instanceof im&&this.tool.mouseDown(this.eventArgs),this.updateCursor(),this.renderUmlHighLighter(this.eventArgs);var p=!1;this.hoverElement&&!(this.tool instanceof im)&&r instanceof te&&this.isSwimlaneElements(r)&&(0===this.diagram.selectedItems.nodes.length||!_r(this.diagram,this.hoverElement))||this.hoverElement instanceof de||(p=!0),this.hoverElement&&!(this.tool instanceof im)&&r instanceof de&&(0===this.diagram.selectedItems.connectors.length||!_r(this.diagram,this.hoverElement))||this.hoverElement instanceof te||(p=!0),this.diagram.updatePortVisibility(this.hoverElement,ci.Hover,p);var g=this.getContent();null===r&&this.hoverElement&&"Auto"===this.hoverElement.tooltip.openOn&&g&&(this.hoverElement=null,this.elementLeave()),s=!1}else{this.eventArgs.position=this.currentPosition,"Drag"===this.action&&!_r(this.diagram,this.eventArgs.source,!1)&&this.eventArgs.source instanceof ei&&this.getMouseEventArgs(this.currentPosition,this.eventArgs),this.mouseEvents(),(t.ctrlKey||t.shiftKey)&&(this.eventArgs.info=t.ctrlKey&&t.shiftKey?{ctrlKey:t.ctrlKey,shiftKey:t.shiftKey}:{ctrlKey:!0}),this.checkAction(r);var y=this.getConnectorPadding(this.eventArgs);this.getMouseEventArgs(this.currentPosition,this.eventArgs,this.eventArgs.source,y),this.updateCursor(),this.inAction=!0,this.initialEventArgs=null,("Drag"===this.action||"Rotate"===this.action)&&(this.diagram.diagramActions=this.diagram.diagramActions|ee.Interactions);var S=this.diagram.scroller.getPageBounds();this.mouseMoveExtend(t,r);var b=this.diagram.scroller.getPageBounds();if(r&&(S.width!==b.width||S.height!==b.height||S.x!==b.x||S.y!==b.y)&&this.diagram.views&&this.diagram.views.overview){var M=this.diagram.views.overview;M.updateView(M)}}this.prevPosition=this.currentPosition,this.isForeignObject(t.target,!0)||t.preventDefault()}}},n.prototype.getContent=function(){var i,t=this.hoverElement instanceof te&&this.hoverElement.constraints&ie.Tooltip||this.hoverElement instanceof de&&this.hoverElement.constraints&qe.Tooltip||(this.hoverElement instanceof Es||this.hoverElement instanceof Tc)&&this.hoverElement.constraints&oi.ToolTip||(this.hoverElement instanceof Kn||this.hoverElement instanceof Or)&&this.hoverElement.constraints&Nr.Tooltip,e=this.hoverElement;e instanceof te&&e.children&&e.children.length>0&&(i=this.findIntersectChild(e));var r=t?this.hoverElement.tooltip.content:this.diagram.tooltip.content;return i?i.tooltip.content:r},n.prototype.findIntersectChild=function(t){for(var e,i=new Ne(this.currentPosition.x,this.currentPosition.y,8,8),r=0;r1&&1===t.which&&!function one(n){return!!(n&ee.PreventClearSelection)}(this.diagram.diagramActions)&&(c=!1,this.commandHandler.clearSelection()),(!_r(this.diagram,h)||!c)&&(this.commandHandler.selectObjects([h],void 0,a),this.diagram.selectedItems.canToggleSelection)){var d=this.diagram.selectedItems.nodes;d?d[0].parentObj instanceof Fd&&(s=!0):this.diagram.selectedItems.connectors.length>0&&(s=!0)}}var u=!1,f=this.updateContainerProperties(),p=void 0;if(this.addUmlNode(),this.inAction=!1,this.isMouseDown=!1,this.diagram.selectedObject.helperObject&&(p=this.updateContainerBounds()),this.tool&&(this.tool.prevPosition||this.tool instanceof eF)){this.eventArgs.position=this.currentPosition;var g=this.getConnectorPadding(this.eventArgs);this.getMouseEventArgs(this.currentPosition,this.eventArgs,this.eventArgs.source,g);var v=this.isMetaKey(t);if((v||t.shiftKey)&&(this.eventArgs.info=v&&t.shiftKey?{ctrlKey:v,shiftKey:t.shiftKey}:{ctrlKey:!0}),this.diagram.diagramActions&ee.Interactions&&(this.diagram.diagramActions=this.diagram.diagramActions&~ee.Interactions),this.eventArgs.clickCount=t.detail,this.diagram.selectedObject.helperObject&&(this.tool instanceof fa||this.tool instanceof Rd)){if(this.diagram.selectedObject.actualObject&&""!==this.diagram.selectedObject.actualObject.parentId){var S=this.diagram.getObject(this.diagram.selectedObject.actualObject.parentId);S&&S.isLane&&(this.commandHandler.isContainer=!0)}(u=this.diagram.lineRoutingModule&&this.diagram.nameTable.helper&&this.eventArgs.target&&this.eventArgs.target.isLane&&(this.eventArgs.source instanceof ei&&this.eventArgs.source.nodes.length>0&&""===this.eventArgs.source.nodes[0].parentId||""===this.eventArgs.source.parentId))&&(this.diagram.diagramActions=this.diagram.diagramActions|ee.PreventLaneContainerUpdate),this.tool.mouseUp(this.eventArgs,f.isPreventHistory)}else{if(this.diagram.selectedItems.canToggleSelection){var b=void 0,M=void 0;if(this.diagram.selectedItems.nodes.length>0)for(var w=0;w1&&D[0].id===i[parseInt(w.toString(),10)].id||r.length>0)&&(M=!0);!this.isSwimlaneSelected&&!s&&!M&&this.tool instanceof fa&&"Select"===this.currentAction&&(!b||this.diagram.selectedItems.connectors.length>0)&&this.commandHandler.clearSelection(!0)}this.isSwimlaneSelected=!1,this.tool.mouseUp(this.eventArgs),this.diagram.checkMenu&&(-1!==window.navigator.userAgent.indexOf("Linux")||-1!==window.navigator.userAgent.indexOf("X11"))&&(!t.pageY&&t instanceof TouchEvent&&t.changedTouches?(window.getSelection().removeAllRanges(),this.diagram.contextMenuModule.contextMenu.open(t.changedTouches[0].pageY,t.changedTouches[0].pageX,this.diagram.element),t.preventDefault()):this.diagram.contextMenuModule.contextMenu.open(t.pageY,t.pageX,this.diagram.element),this.diagram.checkMenu=!1)}f.hasStack&&this.diagram.endGroupAction()}if(p&&this.diagram.endGroupAction(),this.updateContainerBounds(!0),2!==this.eventArgs.clickCount&&(this.commandHandler.updateSelectedNodeProperties(this.eventArgs.source),u)){this.diagram.diagramActions=this.diagram.diagramActions&~ee.PreventLaneContainerUpdate;var A=this.eventArgs.source instanceof ei?this.eventArgs.source.nodes:[this.eventArgs.source];if(A)for(w=0;w0&&!N&&this.diagram.renderSelector(!0),!this.inAction&&!this.diagram.currentSymbol&&this.eventArgs){var T=this.getTargetElement();this.diagram.tool!==ri.ZoomPan&&this.diagram.triggerEvent(Ce.click,{element:T.target instanceof Es?T.target:this.eventArgs.source||this.diagram,position:this.eventArgs.position,count:t.detail,actualObject:this.eventArgs.actualObject,button:0===t.button?"Left":1===t.button?"Middle":"Right"})}this.eventArgs={}}this.diagram.diagramActions=this.diagram.diagramActions&~ee.PreventLaneContainerUpdate,e&&this.updateAnnotation(this.diagram.selectedItems),this.previousElement=null,this.eventArgs={},this.diagram.commandHandler.removeStackHighlighter()},n.prototype.isSwimlaneChild=function(t){if(t.shape&&"SwimLane"!==t.shape.type){var e=this.diagram.nameTable[t.parentId];if(!e)return!1;var i=e.parentId?this.diagram.nameTable[e.parentId]:e;return i&&i.shape&&"SwimLane"===i.shape.type}return!1},n.prototype.updateAnnotation=function(t){var e=t.nodes;if(e.length>0)for(var i=0;i0&&(a+=1),h.isPhase){l="Horizontal"===r.orientation?this.currentPosition.x-e.wrapper.bounds.x:this.currentPosition.y-(e.wrapper.bounds.y+r.header.height);var g={id:Qe(),offset:l,header:{annotation:{content:void 0===h.phases[0].header?"Phase":h.phases[0].header.annotation.content,style:void 0===h.phases[0].header?{}:h.phases[0].header.annotation.style}},style:void 0===h.phases[0]?{}:h.phases[0].style};this.diagram.addPhases(e,[g])}else{var v={id:Qe(),style:h.lanes[0].style,header:{annotation:{content:h.lanes[0].header.annotation.content,style:h.lanes[0].header.annotation.style},style:h.lanes[0].header.style}};if("Horizontal"===h.orientation?v.height=h.lanes[0].height:v.width=h.lanes[0].width,"Horizontal"===r.orientation?(s=i.rowIndex?i.rowIndex:this.diagram.nameTable[i.parentId].rowIndex,i.wrapper.offsetYs)v.header.width=r.lanes[parseInt(s.toString(),10)].header.width,v.header.height=r.lanes[parseInt(s.toString(),10)].header.height;else{var S=void 0;S="Horizontal"===r.orientation?i.rowIndex<3?0:s-a-1:s-1,v.header.width=r.lanes[parseInt(S.toString(),10)].header.width,v.header.height=r.lanes[parseInt(S.toString(),10)].header.height}p&&("height"===p?(v.width=v.height,delete v.height):(v.height=v.width,delete v.width)),this.diagram.addLanes(e,[v],"Horizontal"===r.orientation?s-a:s)}this.commandHandler.select(e)}else if(h.isLane){var b={id:Qe(),width:t.width,height:t.height,addInfo:t.addInfo,shape:{type:"SwimLane",header:{annotation:{content:void 0===h.header?"Header":h.header.annotation.content,style:void 0===h.header?{}:h.header.annotation.style},height:50,style:h.header?h.header.style:h.lanes[0].header.style},phases:[{id:Qe(),header:{annotation:{content:void 0===h.phases||void 0===h.phases[0].header?"Phase":h.phases[0].header.annotation.content,style:void 0===h.phases||void 0===h.phases[0].header?{}:h.phases[0].header.annotation.style},style:void 0===h.phases||void 0===h.phases[0].header?{}:h.phases[0].header.style},style:void 0===h.phases?{}:h.phases[0].style}],lanes:[{id:Qe(),height:t.height,width:t.width,style:h.lanes[0].style,header:{annotation:{content:h.lanes[0].header.annotation.content,style:h.lanes[0].header.annotation.style},style:h.lanes[0].header.style}}],orientation:h.orientation}};"Vertical"===h.orientation&&(b.width+=20),b.offsetX=this.currentPosition.x+b.width/2,b.offsetY=this.currentPosition.y+b.height/2,b.style=t.style,this.diagram.add(b)}},n.prototype.mouseLeave=function(t){this.tool&&this.inAction&&this.tool.mouseLeave(this.eventArgs),this.diagram.selectedObject.helperObject&&(this.updateContainerProperties(),this.updateContainerBounds()&&this.diagram.endGroupAction()),this.eventArgs&&this.eventArgs.source&&(this.diagram.updatePortVisibility(this.eventArgs.source,ci.Hover,!0),this.hoverElement=null),this.eventArgs&&!this.eventArgs.source&&this.hoverElement&&(this.hoverElement=null),this.tool instanceof zd&&this.eventArgs&&this.eventArgs.target&&this.eventArgs.target instanceof te&&(this.diagram.updatePortVisibility(this.eventArgs.target,ci.Hover|ci.Connect,!0),this.hoverElement=null);var i=this.diagram.selectedItems;i&&i.wrapper&&(cm(this.diagram,i)||this.diagram.renderSelector(!0)),(this.diagram.diagramActions&ee.Interactions||this.diagram.diagramActions&ee.ToolAction)&&(this.diagram.diagramActions=this.diagram.diagramActions&~ee.ToolAction),this.isMouseDown=!1,this.focus=!1,this.touchStartList=null,this.touchMoveList=null,this.elementLeave(),this.commandHandler.removeSnap(),this.inAction=!1,this.eventArgs={},this.diagram.selectedObject&&this.diagram.selectedObject.helperObject&&(this.diagram.remove(this.diagram.selectedObject.helperObject),this.diagram.selectedObject={helperObject:void 0,actualObject:void 0}),this.tool=null,function rse(){var t,e,n=document.getElementsByClassName("e-d-ruler-marker");if(n&&n.length>0)for(e=n.length-1;e>=0;e--)(t=n[parseInt(e.toString(),10)])&&t.parentNode.removeChild(t)}(),"Rotate"===this.action&&this.diagram.diagramCanvas.classList.remove("e-diagram-rotate"),t.preventDefault()},n.prototype.mouseWheel=function(t){this.diagram.blazorActions|=on.interaction;var e={event:t,cancel:!1};if(this.diagram.triggerEvent(Ce.mouseWheel,e),!e.cancel){var i=t.wheelDelta>0||-40*t.detail>0,r=this.getMousePosition(t);if(this.diagram.tooltipObject.close(),this.isMetaKey(t)){var o=this.diagram.scrollSettings.zoomFactor;this.diagram.zoomTo(i?{type:"ZoomIn",zoomFactor:o,focusPoint:r}:{type:"ZoomOut",zoomFactor:o,focusPoint:r}),t.preventDefault()}else{var a=this.diagram.scroller.horizontalOffset,l=this.diagram.scroller.verticalOffset,h=i?10:-10;this.tool&&(this.tool instanceof Rl||this.tool instanceof Hl)&&(this.eventArgs={},this.getMouseEventArgs(r,this.eventArgs),this.eventArgs.position=r,this.tool.mouseWheel(this.eventArgs)),this.diagram.scrollActions|=da.Interaction;var c=!0;if(t.isTrusted){var d=!1;(Math.abs(t.deltaY)<100&&-0===Math.abs(t.deltaX)||Math.abs(t.deltaX)<100&&-0===Math.abs(t.deltaY))&&(d=!0);var u=!1;(0!==t.deltaX||0!==t.deltaY)&&(u=navigator.userAgent.includes("Macintosh")),u?Math.abs(t.deltaX)>Math.abs(t.deltaY)?(t.shiftKey||t.deltaX&&-0!==t.deltaX&&(d||!u))&&this.diagram.scroller.zoom(1,h,0,r,c,void 0,d):t.deltaY&&-0!==t.deltaY&&(d||!u)&&this.diagram.scroller.zoom(1,0,h,r,c,void 0,d):t.shiftKey||t.deltaX&&-0!==t.deltaX&&(d||!u)?this.diagram.scroller.zoom(1,h,0,r,c,void 0,d):t.deltaY&&-0!==t.deltaY&&(d||!u)&&this.diagram.scroller.zoom(1,0,h,r,c,void 0,d)}else t.shiftKey||t.deltaX&&-0!==t.deltaX?this.diagram.scroller.zoom(1,h,0,r,c):this.diagram.scroller.zoom(1,0,h,r,c);this.diagram.scrollActions&=~da.Interaction,(a!==this.diagram.scroller.horizontalOffset||l!==this.diagram.scroller.verticalOffset)&&t.preventDefault()}if(this.diagram.textEditing){if(this.diagram.isTriggerEvent=!0,this.diagram.activeLabel.parentId){var p=this.diagram.getObject(this.diagram.activeLabel.parentId);this.diagram.startTextEdit(p,this.diagram.activeLabel.id)}this.diagram.isTriggerEvent=!1}this.diagram.blazorActions=this.diagram.blazorActions&~on.interaction}},n.prototype.keyDown=function(t){if(t.fromMouseEvents&&(t.ctrlKey&&(this.keyArgs.keyModifiers=1),t.shiftKey&&(this.keyArgs.keyModifiers=4),t.shiftKey&&t.ctrlKey&&(this.keyArgs.keyModifiers=5)),!(this.diagram.diagramActions&ee.TextEdit)&&!this.checkEditBoxAsTarget(t)||"Escape"===t.key||27===t.keyCode){var i=void 0,r=t.keyCode?t.keyCode:t.which,s=t.key;("ArrowDown"===s||"ArrowUp"===s||"ArrowLeft"===s||"ArrowRight"===s)&&(this.isNudgeKey=!0);var o=this.isMetaKey(t);if(this.diagram.commandManager&&this.diagram.commands)for(var l=0,h=Object.keys(this.diagram.commands);l4&&(S({keyDownEventArgs:KeyboardEvent,parameter:i.parameter,type:"KEYDOWN"}),this.keyCount=0,this.keyArgs.newValue={offsetX:this.diagram.selectedItems.offsetX,offsetY:this.diagram.selectedItems.offsetY},this.diagram.triggerEvent(Ce.positionChange,this.keyArgs))),this.isKeyUp=!1):S({keyDownEventArgs:KeyboardEvent,parameter:i.parameter})}break}}}}this.keyArgs={element:this.diagram.selectedItems,key:t.key,keyCode:t.keyCode?t.keyCode:t.which},this.getKeyModifier(this.keyArgs,t),this.diagram.diagramActions&ee.TextEdit&&this.getlabel(this.keyArgs,t),this.diagram.triggerEvent(Ce.keyDown,this.keyArgs)},n.prototype.getlabel=function(t,e){var i=this.diagram.activeLabel;t.target=this.diagram.element.id+"_editBox";var r=this.diagram.nameTable[i.parentId];if(document.getElementById(this.diagram.element.id+"_editBox")){t.text=document.getElementById(this.diagram.element.id+"_editBox").value;for(var s=0;s=this.diagram.scroller.viewPortWidth-18?r="right":e.x+this.diagram.scroller.horizontalOffsetthis.diagram.scroller.viewPortHeight-18?r="bottom":e.y+this.diagram.scroller.verticalOffset0&&(s=this.findIntersectChild(this.hoverElement)),"Auto"===this.hoverElement.tooltip.openOn&&""!==r&&Ex(this.diagram,s||(i?this.hoverElement:void 0)),this.hoverElement.tooltip.content&&("Mouse"===this.hoverElement.tooltip.relativeMode?this.setTooltipOffset(t):(this.diagram.tooltipObject.offsetX=0,this.diagram.tooltipObject.offsetY=0));var o=this.diagram.findObjectsUnderMouse(this.currentPosition),a=this.diagram.findObjectUnderMouse(o,this.action,this.inAction);if(null!==a){var l=void 0;this.hoverElement.tooltip.isSticky&&(this.diagram.tooltipObject.isSticky=!0),a instanceof te&&a.children&&a.children.length>0&&(a=s||a),l=a.ports&&(this.hoverElement instanceof Es||this.hoverElement instanceof Tc)||a.annotations&&(this.hoverElement instanceof Kn||this.hoverElement instanceof Or)?document.getElementById(a.id+"_"+this.hoverElement.id):document.getElementById(a.id+(a.shape&&a.shape instanceof dm?"_content_native_element":"_groupElement")),"Auto"===this.hoverElement.tooltip.openOn&&""!==r&&(this.diagram.tooltipObject.close(),this.diagram.tooltipObject.openOn=this.hoverElement.tooltip.openOn,this.diagram.tooltipObject.dataBind()),function Kre(n,t){var e=0;return n instanceof de?n.constraints&qe.Tooltip?e=n.constraints&qe.Tooltip:n.constraints&qe.InheritTooltip&&(e=t.constraints&nt.Tooltip):n instanceof Es||n instanceof Tc?n.constraints&oi.ToolTip?e=n.constraints&oi.ToolTip:n.constraints&oi.InheritTooltip&&(e=t.constraints&nt.Tooltip):n instanceof Kn||n instanceof Or?n.constraints&Nr.Tooltip&&(e=n.constraints&Nr.Tooltip):n.constraints&ie.Tooltip?e=n.constraints&ie.Tooltip:n.constraints&ie.InheritTooltip&&(e=t.constraints&nt.Tooltip),e}(this.hoverElement,this.diagram)&&"Auto"===this.hoverElement.tooltip.openOn&&(this.diagram.tooltipObject.target=this.hoverElement.id,this.diagram.tooltipObject.open("Mouse"===this.hoverElement.tooltip.relativeMode?this.diagram.element:l))}}},n.prototype.elementLeave=function(){this.diagram.tooltipObject&&!this.diagram.tooltipObject.isSticky&&"Custom"!==this.diagram.tooltipObject.openOn&&this.diagram.tooltipObject.close()},n.prototype.setTooltipOffset=function(t){var e=function Mse(n,t,e,i){var o="Mouse"===(!(e instanceof te?e.constraints&ie.InheritTooltip:e instanceof de?e.constraints&qe.InheritTooltip:e.constraints&oi.InheritTooltip)&&(e instanceof te?e.constraints&ie.Tooltip:e instanceof de?e.constraints&qe.Tooltip:e.constraints&oi.ToolTip)?e.tooltip.relativeMode:n.tooltip.relativeMode);"Mouse"===i?o=!0:"Object"===i&&(o=!1);var a=function wse(n,t,e,i){var o,r={},s=document.getElementById(e.element.id);if(n instanceof te||n instanceof de)o=n.wrapper.bounds;else{var a=e.findObjectsUnderMouse(t),l=e.findObjectUnderMouse(a,"Select",!1);o=e.findElementUnderMouse(l,t,e).bounds}var c=s.getBoundingClientRect();switch(e.tooltipObject.position){case"BottomCenter":r=zc(t,o.bottomCenter,e,i,c.width/2,c.height);break;case"BottomLeft":case"LeftBottom":r=zc(t,o.bottomLeft,e,i,0,c.height);break;case"BottomRight":case"RightBottom":r=zc(t,o.bottomRight,e,i,c.width,c.height);break;case"LeftCenter":r=zc(t,o.middleLeft,e,i,0,c.height/2);break;case"LeftTop":case"TopLeft":r=zc(t,o.topLeft,e,i,0,0);break;case"RightCenter":r=zc(t,o.middleRight,e,i,c.width,c.height/2);break;case"RightTop":case"TopRight":r=zc(t,o.topRight,e,i,c.width,0);break;case"TopCenter":r=zc(t,o.topCenter,e,i,c.width/2,0)}return r}(e,t,n,o),l=Za(n);return{x:a.x+l.width,y:a.y+l.height}}(this.diagram,t,this.hoverElement);this.diagram.tooltipObject.offsetX=e.x,this.diagram.tooltipObject.offsetY=e.y},n.prototype.altKeyPressed=function(t){return!!(t&ft.Alt)},n.prototype.ctrlKeyPressed=function(t){return!!(t&ft.Control)},n.prototype.shiftKeyPressed=function(t){return!!(t&ft.Shift)},n.prototype.scrolled=function(t){this.diagram.updateScrollOffset()},n.prototype.isMobileOrIPadDevice=function(){var t=navigator.userAgent||navigator.vendor||window.opera;return/iPhone|iPad|iPod/.test(t)&&!window.MSStream?"iOS":/android/i.test(t)?"Android":/Mobile|Tablet/.test(t)?"Mobile":"Desktop"},n.prototype.doubleClick=function(t){if(Yv(this.diagram)){var e=this.isMobileOrIPadDevice(),i=this.diagram.tool;"Desktop"!==e&&this.tool&&(this.tool instanceof Rl||this.tool instanceof Hl)&&(this.diagram.tool=0);var r=void 0,s=this.diagram.findObjectsUnderMouse(this.currentPosition),o=this.diagram.findObjectUnderMouse(s,this.action,this.inAction);if(null!==o&&Yv(this.diagram))if(r=this.diagram.findElementUnderMouse(o,this.currentPosition,this.diagram),this.tool&&(this.tool instanceof Rl||this.tool instanceof Hl))this.diagram.tool=i,this.tool.mouseUp(this.eventArgs),this.isMouseDown=!1,this.eventArgs={},this.tool=null,t.preventDefault();else{var l=this.diagram.commandHandler.getObjectLayer(o.id);!l||l.lock||!l.visible||this.diagram.diagramActions&ee.TextEdit||this.diagram.startTextEdit(o,r instanceof ai?r.id.split(o.id+"_")[1]:void 0)}this.diagram.triggerEvent(Ce.doubleClick,{source:o||this.diagram,position:this.currentPosition,count:t.detail})}},n.prototype.itemClick=function(t,e){var i=t;return Dn(this.diagram,i,!0)?i:null},n.prototype.inputChange=function(t){var i,s,o,a,l,h,c,d,u,f=document.getElementById(this.diagram.element.id+"_editBox"),p=document.getElementById(this.diagram.element.id+"_editTextBoxDiv"),g=f.value,v=g.split("\n");(!(a=this.diagram.selectedItems.nodes[0]?this.diagram.selectedItems.nodes[0]:this.diagram.selectedItems.connectors[0])&&this.tool instanceof $I||a&&"SwimLane"===a.shape.type)&&(a=this.diagram.nameTable[this.diagram.activeLabel.parentId]),a&&("Text"!==a.shape.type&&a.annotations.length>0||"Text"===a.shape.type)&&(c=HF((o=this.diagram.getWrapper(a.wrapper,this.diagram.activeLabel.id)).style,g,void 0,void 0,i=(i=a.wrapper.bounds.width90?i:90),s=Number(f.style.fontSize.split("px")[0]),v.length>1&&""===v[v.length-1]&&(c.height=c.height+s),d=this.diagram.scroller.transform,u=P3(this.diagram)?d.scale:1,l=(12>c.height?12:c.height)*u,p.style.left=(o.bounds.center.x+d.tx)*d.scale-(h=(90>(h=c.width)?90:h)*u)/2-2.5+"px",p.style.top=(o.bounds.center.y+d.ty)*d.scale-l/2-3+"px",p.style.width=h+"px",p.style.height=l+"px",f.style.minHeight="12px",f.style.minWidth="90px",f.style.width=h+"px",f.style.height=l+"px")},n.prototype.isAddTextNode=function(t,e){return!(!(this.tool instanceof $I||e)||(this.tool=null,t&&!_I(this.diagram)&&(this.diagram.drawingObject=void 0,this.diagram.currentDrawingObject=void 0),MF(this.diagram.nodes,t.id)||MF(this.diagram.connectors,t.id)))},n.prototype.checkEditBoxAsTarget=function(t){return!(!t.target||t.target.id!==this.diagram.element.id+"_editBox")},n.prototype.getMouseEventArgs=function(t,e,i,r){var s,o,a;if(e.position=t,i?(o=this.diagram.findObjectsUnderMouse(this.currentPosition,i),s=this.diagram.findTargetObjectUnderMouse(o,this.action,this.inAction,e.position,i)):"Drag"===this.action||"ConnectorSourceEnd"===this.action||"SegmentEnd"===this.action||"OrthoThumb"===this.action||"BezierSourceThumb"===this.action||"BezierTargetThumb"===this.action||"ConnectorTargetEnd"===this.action||-1!==this.action.indexOf("Rotate")||-1!==this.action.indexOf("Resize")?(s=this.diagram.selectedItems,!this.diagram.currentSymbol&&"Drag"===this.action&&s&&this.diagram.selectedItems.nodes.length>0&&"SwimLane"===this.diagram.selectedItems.nodes[0].shape.type&&(o=this.diagram.findObjectsUnderMouse(this.currentPosition),s=this.diagram.findObjectUnderMouse(o,this.action,this.inAction))):(o=this.diagram.findObjectsUnderMouse(this.currentPosition),s=this.diagram.findObjectUnderMouse(o,this.action,this.inAction)),s&&s.isHeader&&(this.eventArgs.actualObject=s=this.diagram.nameTable[s.parentId]),s){var l=void 0,h=void 0,c=void 0;if(((a=this.diagram.findElementUnderMouse(s,this.currentPosition,this.diagram,r))&&s.ports&&s.ports.length&&!lb(s,a)||!a||!s)&&o&&o.length&&i instanceof ei)for(l=i.connectors[0],c=o.length-1;c>=0;c--)if(((h=o[parseInt(c.toString(),10)])instanceof te||h instanceof de)&&l&&l.connectionPadding){if(a=this.diagram.findElementUnderMouse(s=h,this.currentPosition,this.diagram,r),l.constraints&qe.ConnectToNearByPort&&s&&s.ports&&s.ports.length&&lb(s,a))break;if((h instanceof te||h instanceof de)&&l&&l.connectionPadding&&h.wrapper.outerBounds.containsPoint(this.currentPosition)&&l.constraints&qe.ConnectToNearByNode&&!(l.constraints&qe.ConnectToNearByPort)){a=this.diagram.findElementUnderMouse(s=h,this.currentPosition,this.diagram,0);break}}}return i?(e.target=s,e.targetWrapper=a):(e.source=s,e.sourceWrapper=a),e.actualObject=this.eventArgs.actualObject,e.source instanceof ei&&void 0===e.actualObject&&(e.source.nodes.length>0||e.source.connectors.length>0)&&(e.actualObject=e.source.nodes.length>0?this.diagram.nameTable[e.source.nodes[0].id]:this.diagram.nameTable[e.source.connectors[0].id]),e.startTouches=this.touchStartList,e.moveTouches=this.touchMoveList,e},n.prototype.resetTool=function(){this.action="Select",this.hoverElement=null,this.hoverNode=null,this.tool=this.diagram.getTool(this.action),this.updateCursor()},n.prototype.updateTool=function(){this.action=this.currentPosition&&"Pan"!==this.action?"Pan":"Select"},n.prototype.getTool=function(t){switch(t){case"Select":return new tm(this.commandHandler,!0);case"Drag":return new fa(this.commandHandler);case"Rotate":return new Xx(this.commandHandler);case"LayoutAnimation":return new Une(this.commandHandler);case"FixedUserHandle":return new _ne(this.commandHandler,!0);case"Hyperlink":return new eF(this.commandHandler);case"ResizeSouthEast":case"ResizeSouthWest":case"ResizeNorthEast":case"ResizeNorthWest":case"ResizeSouth":case"ResizeNorth":case"ResizeWest":case"ResizeEast":return new Rd(this.commandHandler,t);case"ConnectorSourceEnd":case"ConnectorTargetEnd":case"BezierSourceThumb":case"BezierTargetThumb":return new zd(this.commandHandler,t);case"SegmentEnd":case"OrthoThumb":return new r_(this.commandHandler,t);case"Draw":var e="shape",i=function gse(n){var t;return n&&(n.type?t="Connector":n.shape&&!n.type&&(t="Node")),t}(this.diagram.drawingObject);if("Node"===i&&"Text"===this.diagram.drawingObject.shape.type)return new $I(this.commandHandler);if("Connector"===i&&"Freehand"===this.diagram.drawingObject.type)return new Yne(this.commandHandler);if("Node"===i&&"Polygon"===this.diagram.drawingObject.shape[""+e]&&!this.diagram.drawingObject.shape.points)return new Rl(this.commandHandler);if("Node"===i||"Node"===i&&"Polygon"===this.diagram.drawingObject.shape[""+e]&&this.diagram.drawingObject.shape.points)return new qI(this.commandHandler,this.diagram.drawingObject);if("Connector"===i&&"Polyline"===this.diagram.drawingObject.type)return new Hl(this.commandHandler);if("Connector"===i)return new pa(this.commandHandler,"ConnectorSourceEnd",this.diagram.drawingObject);break;case"Pan":return new im(this.commandHandler,!1);case"PinchZoom":return new im(this.commandHandler,!0);case"PortDrag":return new fa(this.commandHandler,"Port");case"PortDraw":return new pa(this.commandHandler,"ConnectorSourceEnd",this.diagram.drawingObject);case"LabelSelect":return new tm(this.commandHandler,!0,"LabelSelect");case"LabelDrag":return new jne(this.commandHandler);case"LabelResizeSouthEast":case"LabelResizeSouthWest":case"LabelResizeNorthEast":case"LabelResizeNorthWest":case"LabelResizeSouth":case"LabelResizeNorth":case"LabelResizeWest":case"LabelResizeEast":return new Vne(this.commandHandler,t);case"LabelRotate":return new Wne(this.commandHandler)}return null},n.prototype.getCursor=function(t){var e=this.diagram.selectedItems.annotation?this.diagram.selectedItems.wrapper.children[0]:this.diagram.selectedItems;return function Fne(n,t){if(t+=360,t%=360,-1===n.indexOf("Resize"))return Gx[""+n];var e=Gx[""+n];return t>=0&&t<25||t>=160&&t<=205||t>=340&&t<=360?e:t>=25&&t<=70||t>=205&&t<=250?"n-resize"===e||"s-resize"===e?"ne-resize":"nw-resize"===e||"se-resize"===e?"n-resize":"e-resize"===e||"w-resize"===e?"nw-resize":"e-resize":t>=70&&t<=115||t>=250&&t<=295?"n-resize"===e||"s-resize"===e?"e-resize":"nw-resize"===e||"se-resize"===e?"ne-resize":"e-resize"===e||"w-resize"===e?"n-resize":"nw-resize":t>=115&&t<=155||t>=295&&t<=340?"n-resize"===e||"s-resize"===e?"nw-resize":"nw-resize"===e||"se-resize"===e?"e-resize":"e-resize"===e||"w-resize"===e?"ne-resize":Gx[""+n]:"n-resize"}(t,this.diagram.selectedItems.annotation?e.rotateAngle+e.parentTransform:e.rotateAngle)},n.prototype.findElementUnderMouse=function(t,e,i,r){return this.objectFinder.findElementUnderSelectedItem(t,e,i,r)},n.prototype.findObjectsUnderMouse=function(t,e){return this.objectFinder.findObjectsUnderMouse(t,this.diagram,this.eventArgs,e)},n.prototype.findObjectUnderMouse=function(t,e,i){return this.objectFinder.findObjectUnderMouse(this.diagram,t,e,i,this.eventArgs,this.currentPosition)},n.prototype.findTargetUnderMouse=function(t,e,i,r,s){return this.objectFinder.findObjectUnderMouse(this.diagram,t,e,i,this.eventArgs,r,s)},n.prototype.findActionToBeDone=function(t,e,i,r){return function kne(n,t,e,i,r,s,o){if(s&&s.length>1&&r&&r.length>1)return"PinchZoom";if(i.currentSymbol)return"Drag";if("PortDraw"===i.eventHandler.action&&(i.tool&=~ri.DrawOnce),(k3(i)||_I(i))&&i.drawingObject)return"Draw";if($a(i)&&(l=i.selectedItems).wrapper&&qr(l.constraints,"UserHandle"))for(var h=0,c=l.userHandles;h=50&&(l.x=(a.points[parseInt(h.toString(),10)].x+a.points[h+1].x)/2,l.y=(a.points[parseInt(h.toString(),10)].y+a.points[h+1].y)/2,wr(e,l,n.hitPadding?n.hitPadding:10)))return"OrthoThumb"}else RI(n)&&console.warn('[WARNING] :: Module "ConnectorEditing" is not available in Diagram component! You either misspelled the module name or forgot to load it.');return null}(g,l,e,i);if("OrthoThumb"===S)return S;if(qr(l.constraints,"ConnectorSourceThumb")&&PI(g)&&S||qr(l.constraints,"ConnectorTargetThumb")&&zI(g)&&S)return S}}else{var b=i.selectedItems.handleSize/2/i.scroller.currentZoom,M=10/i.scroller.currentZoom,w=Bi();qi(w,f.rotateAngle+f.parentTransform,f.offsetX,f.offsetY);var C=f.offsetX-f.pivot.x*f.actualSize.width,D=f.offsetY-f.pivot.y*f.actualSize.height,A={x:C+(.5===f.pivot.x?2*f.pivot.x:f.pivot.x)*f.actualSize.width/2,y:D-30/i.scroller.currentZoom};A=Ke(w,A);var x=!!i.selectedItems.annotation,P=!(!x||!HI(i.selectedItems.annotation));if(qr(l.constraints,"Rotate")&&wr(e,A,M)&&i.selectedItems.thumbsConstraints&bt.Rotate){if(x&&P)return"LabelRotate";if(!x)return"Rotate"}if(u.Inflate(b),u.containsPoint(e)&&(S=function Pne(n,t,e,i,r,s){var o;return 1===n.selectedItems.nodes.length&&0===n.selectedItems.connectors.length&&n.selectedItems.nodes[0].container&&(o=function Hne(n,t,e,i,r){var s=10/n.scroller.currentZoom,o=n.selectedItems,a=t.actualSize.width,l=t.actualSize.height,h=new Ne(i,r,t.style.strokeWidth,l),c=new Ne(i+a,r,t.style.strokeWidth,l),d=new Ne(i,r,a,t.style.strokeWidth),u=new Ne(i,r+l,a,t.style.strokeWidth),f=Dn(n,n.selectedItems.nodes[0],!0)?n.nameTable[n.selectedItems.nodes[0].parentId]:n.selectedItems.nodes[0];if(ga(o.constraints,"ResizeEast",o.thumbsConstraints,o)&&c.containsPoint(e,s))return"ResizeEast";if(ga(o.constraints,"ResizeSouth",o.thumbsConstraints,o)&&u.containsPoint(e,s))return"ResizeSouth";if("Grid"!==f.container.type){if(ga(o.constraints,"ResizeWest",o.thumbsConstraints,o)&&h.containsPoint(e,s))return"ResizeWest";if(ga(o.constraints,"ResizeNorth",o.thumbsConstraints,o)&&d.containsPoint(e,s))return"ResizeNorth"}return null}(n,t,e,r,s)),!o&&(!n.selectedItems.nodes[0]||!n.selectedItems.nodes[0].isPhase&&!n.selectedItems.nodes[0].isLane&&"SwimLane"!==n.selectedItems.nodes[0].shape.type)&&(o=function Bne(n,t,e,i,r,s){var o=40/n.scroller.currentZoom,a=n.selectedItems.handleSize/2/n.scroller.currentZoom,l=n.selectedItems,h=!!l.annotation;if(t.actualSize.width>=o&&t.actualSize.height>=o){if(ga(l.constraints,"ResizeSouthEast",l.thumbsConstraints,l)&&wr(e,Ke(i,{x:r+t.actualSize.width,y:s+t.actualSize.height}),a))return h?"LabelResizeSouthEast":"ResizeSouthEast";if(ga(l.constraints,"ResizeSouthWest",l.thumbsConstraints,l)&&wr(e,Ke(i,{x:r,y:s+t.actualSize.height}),a))return h?"LabelResizeSouthWest":"ResizeSouthWest";if(ga(l.constraints,"ResizeNorthEast",l.thumbsConstraints,l)&&wr(e,Ke(i,{x:r+t.actualSize.width,y:s}),a))return h?"LabelResizeNorthEast":"ResizeNorthEast";if(ga(l.constraints,"ResizeNorthWest",l.thumbsConstraints,l)&&wr(e,Ke(i,{x:r,y:s}),a))return h?"LabelResizeNorthWest":"ResizeNorthWest"}return ga(l.constraints,"ResizeEast",l.thumbsConstraints,l)&&wr(e,Ke(i,{x:r+t.actualSize.width,y:s+t.actualSize.height/2}),a)?h?"LabelResizeEast":"ResizeEast":ga(l.constraints,"ResizeWest",l.thumbsConstraints,l)&&wr(e,Ke(i,{x:r,y:s+t.actualSize.height/2}),a)?h?"LabelResizeWest":"ResizeWest":ga(l.constraints,"ResizeSouth",l.thumbsConstraints,l)&&wr(e,Ke(i,{x:r+t.actualSize.width/2,y:s+t.actualSize.height}),a)?h?"LabelResizeSouth":"ResizeSouth":ga(l.constraints,"ResizeNorth",l.thumbsConstraints,l)&&wr(e,Ke(i,{x:r+t.actualSize.width/2,y:s}),a)?h?"LabelResizeNorth":"ResizeNorth":null}(n,t,e,i,r,s)),o||null}(i,f,e,w,C,D),S))return S}}if(Lc(i)&&!n)return"Pan";if((o instanceof Es||o instanceof Tc)&&(!Lc(i)||Vv(i)||Wv(i))&&(S=function Rne(n,t,e,i){if(_x(t)&&(va(t,ci.Hover)||va(t,ci.Visible))){if(t.constraints&oi.Drag)return"PortDrag"}else if(Fx(t)&&(va(t,ci.Hover)||va(t,ci.Visible))&&t.constraints&oi.Draw){n.drawingObject={};var r={type:"Orthogonal",sourcePortID:t.id};return n.drawingObject=r,n.tool|=ri.DrawOnce,n.currentDrawingObject=r,"PortDraw"}return"None"}(i,o),"None"!==S))return S;if((o instanceof Kn||o instanceof Or)&&!Lc(i)&&Ad(o))return _r(i,o,void 0,t)&&ro(o)?"LabelDrag":"LabelSelect";if(null!==n){if(!(n instanceof te||n instanceof de))return"Select";if(t&&t.id){var L=t.id.split(n.id)[1];if(L&&L.match("^_icon"))return"LayoutAnimation"}if(t&&t.id)for(var O=void 0,N=0;N-1)return"FixedUserHandle";if(t instanceof ai&&t.hyperlink.link)return"Hyperlink";if(!ro(n)||!_r(i,n,!1)||void 0!==i.selectedItems.annotation)return n&&Lc(i)&&!UI(i)?"Pan":i.selectedItems.nodes.length&&i.selectedItems.nodes[0].isLane&&i.selectedItems.wrapper&&i.selectedItems.wrapper.bounds.containsPoint(e)?"Drag":"Select";if(n instanceof de&&!wr(e,n.sourcePoint,n.hitPadding)&&!wr(e,n.targetPoint,n.hitPadding)||!(n instanceof de))return"Drag"}return"Select"}(t,e,this.currentPosition,this.diagram,this.touchStartList,this.touchMoveList,r)},n.prototype.updateContainerBounds=function(t){var e=!1;if(this.diagram.selectedObject.helperObject&&this.diagram.selectedObject.actualObject)for(var i=this.diagram.selectedObject.actualObject,r=this.diagram.selectedObject.actualObject instanceof ei?i.nodes:[i],s=0;si.y&&(h+=u>0?-1:1,u+=u>0?-1:1):i&&e.wrapper.offsetYi.x&&(h+=u>0?-1:1,u+=u>0?-1:1):i&&e.wrapper.offsetX1)for(var S=t.offsetX-this.diagram.selectedItems.offsetX,b=t.offsetY-this.diagram.selectedItems.offsetY,M=t.rotateAngle-this.diagram.selectedItems.rotateAngle,w=0;w-1){var A=c.children;A.splice(A.indexOf(o.id),1),this.diagram.nameTable[o.id].parentId="",i=!0,c.wrapper.children.splice(D,1)}}if(function One(n,t,e,i){var r=n,s=e.nameTable[r.parentId],o=e.nameTable[r.parentId];if(t&&o&&o.container&&"Stack"===o.container.type&&t.container&&"Stack"===t.container.type&&o.id!==t.parentId){var a=o.wrapper.children.indexOf(r.wrapper);a>-1&&(e.nameTable[r.id].parentId=t.id,o.wrapper.children.splice(a,1))}if(t&&t.parentId&&r.parentId&&"Drag"===i&&o.container&&"Stack"===o.container.type){var l=s.wrapper.children.indexOf(t.wrapper),h=s.wrapper.children.indexOf(r.wrapper),c={targetIndex:l,target:t,sourceIndex:h,source:n};s.wrapper.children.splice(h,1),s.wrapper.children.splice(l,0,r.wrapper),e.commandHandler.addHistoryEntry({type:"StackChildPositionChanged",redoObject:{targetIndex:h,target:t,sourceIndex:l,source:n},undoObject:c,category:"Internal"})}}(o,h,this.diagram,this.action),(c=Dn(this.diagram,o)?this.diagram.nameTable[o.parentId]:this.diagram.nameTable[o.parentId]||o)&&c.container&&"Canvas"===c.container.type&&(c.wrapper.maxWidth=c.maxWidth=c.wrapper.actualSize.width,c.wrapper.maxHeight=c.maxHeight=c.wrapper.actualSize.height,e=!0),Dn(this.diagram,o,!0)&&c&&"Canvas"===c.container.type)if(this.diagram.selectedItems.nodes.length>1)for(w=0;w0)for(var i=0;i0&&e.columnIndex>0||l&&e.isLane)){if("Horizontal"===t.container.orientation&&e.isPhase&&e.wrapper.width>e.maxWidth&&(e.maxWidth=e.wrapper.width,e.wrapper.maxWidth=e.wrapper.width),h.updateColumnWidth(e.columnIndex,r.width,!0,c),Vx(this.diagram,e,t),e.isPhase){var p=this.diagram.nameTable[""+t.shape.phases[e.columnIndex].header.id];p.maxWidth0?(r=new op(t,"",u),t.shape.classShape.attributes.push(r)):i.id.includes("_umlMethods")&&t.shape.classShape.methods.length>0&&(s=new fm(t,"",u),t.shape.classShape.methods.push(s))),"Interface"===t.shape.classifier&&(i.id.includes("_umlProperty")&&t.shape.interfaceShape.attributes.length>0?(r=new op(t,"",u),t.shape.classShape.attributes.push(r)):i.id.includes("_umlMethods")&&t.shape.interfaceShape.methods.length>0&&(s=new fm(t,"",u),t.shape.interfaceShape.methods.push(s))),"Enumeration"===t.shape.classifier&&i.id.includes("_umlMember")&&t.shape.enumerationShape.members.length>0){var f=new db(t,"",u);t.shape.enumerationShape.members.push(f)}t.wrapper.children.indexOf(c.wrapper),this.diagram.enableServerDataBinding(!0),this.diagram.add(c),this.diagram.updateConnectorEdges(t),this.diagram.clearSelection(),this.diagram.select([this.diagram.nameTable[c.id]]),this.diagram.endGroupAction(),this.diagram.startTextEdit()}}},n}(),Zoe=function(){function n(){}return n.prototype.findObjectsUnderMouse=function(t,e,i,r,s){var o=[];r&&r instanceof ei&&r.nodes.length+r.connectors.length===1&&(r=r.nodes[0]||r.connectors[0]).children&&0===r.children.length&&(i.actualObject=r);for(var a,l,h,c,p,d=r&&r instanceof de&&(r.constraints&qe.ConnectToNearByNode||r.constraints&qe.ConnectToNearByPort)&&r.connectionPadding||0,f={},g=0,v=e.spatialSearch.findObjects(new Ne(t.x-50-d,t.y-50-d,100+d,100+d));g-1&&o.splice(T,1),"UmlClassifier"===y.shape.type&&y.container&&"Stack"===y.container.type&&(T=o.indexOf(e.nameTable[e.nameTable[y.id].wrapper.children[0].id]))>-1&&o.splice(T,1)}for(var z=0;zs.zIndex&&(t[parseInt(r.toString(),10)]=l),r>0&&i&&a&&(a.isLane||a.isPhase||a.isHeader)&&t[parseInt(r.toString(),10)].zIndex=2)for(var d=t.length-1;d>=0;d--)if(t[parseInt(d.toString(),10)].parentId){var u=hm(t[parseInt(d.toString(),10)],e,""),f=hm(t[d-1],e,""),g=e.nameTable[""+f];g&&u!==f&&e.nameTable[""+u].zIndex=0;p--){d=ip(e[parseInt(p.toString(),10)],!1),c=ip(e[parseInt(p.toString(),10)],!0);var g=t[""+l].tool,v=this.findTargetElement(e[parseInt(p.toString(),10)].wrapper,o,t,void 0);if("Draw"===i&&v&&(e[parseInt(p.toString(),10)]instanceof te||e[parseInt(p.toString(),10)]instanceof de)&&!lb(e[parseInt(p.toString(),10)],v)&&(g&&"ConnectorSourceEnd"===g[""+h]&&!Rh(e[parseInt(p.toString(),10)])||g&&"ConnectorTargetEnd"===g[""+h]&&!ua(e[parseInt(p.toString(),10)])))return u;if(e[parseInt(p.toString(),10)]instanceof te||e[parseInt(p.toString(),10)]instanceof de&&(Rh(e[parseInt(p.toString(),10)])||Ld(d)||ua(e[parseInt(p.toString(),10)])||zh(c)||"PortDraw"===i&&g instanceof zd&&"ConnectorTargetEnd"===g[""+h]&&(ua(e[parseInt(p.toString(),10)])||zh(c))))return u=e[parseInt(p.toString(),10)],f&&(u=this.isTarget(u,t,i)),s.actualObject=u,u}else if("ConnectorTargetEnd"===i&&a){for(p=e.length-1;p>=0;p--)if(c=ip(e[parseInt(p.toString(),10)],!0),(e[parseInt(p.toString(),10)]instanceof te||e[parseInt(p.toString(),10)]instanceof de)&&(ua(e[parseInt(p.toString(),10)])||zh(c)))return u=e[parseInt(p.toString(),10)],u=this.isTarget(u,t,i),s.actualObject=u,u}else{if(a&&("Drag"===i||t[""+l].tool instanceof fa)){var y=0;for(p=0;p=S.zIndex?u:S,y=Math.max(y,S.zIndex)):y=(u=S).zIndex)}return u&&"Bpmn"===u.shape.type&&(t.selectedItems.nodes.length>0&&"Bpmn"===t.selectedItems.nodes[0].shape.type||(u=null)),u&&(s.actualObject=u),u}if("Select"!==i&&"Pan"!==i||!t[""+l].tool)if("Pan"===i||"LayoutAnimation"===i){for(p=e.length-1;p>=0;p--)if((e[parseInt(p.toString(),10)]instanceof te||e[parseInt(p.toString(),10)]instanceof de)&&(v=this.findTargetElement(e[parseInt(p.toString(),10)].wrapper,o,t,void 0),"Pan"===i||v&&(v.id.match("_icon_content_shape$")||v.id.match("_icon_content_rect$"))))return e[parseInt(p.toString(),10)]}else u=e[e.length-1],s&&u&&(s.actualObject=u);else{for(p=e.length-1;p>=0;p--)if(e[parseInt(p.toString(),10)]instanceof de){var b=e[p-1];if(e[p-1]instanceof te&&b.ports){if((v=this.findTargetElement(b.wrapper,o,t,void 0))&&(v.id.match("_icon_content_shape$")||v.id.match("_icon_content_rect$")))return b;for(var M=0;M=0;s--){var o=t.children[parseInt(s.toString(),10)];if(o&&o.outerBounds.containsPoint(e,r||0))if(o.visible){if(o instanceof Cs){var a=this.findTargetElement(o,e,i);if(a)return a}var l="Clip"===o.style.textOverflow||"Ellipsis"===o.style.textOverflow;if(o.bounds.containsPoint(e,r||0)&&!l)return o;if(t.bounds.containsPoint(e,r||0)&&l)return o}else if(o instanceof Ze&&t&&t.id){var h=void 0;if(t.id.includes("group_container")){var c=t.id.slice(0,-15);h=i.getObject(c)}else h=i.getObject(t.id);if(ob(h,o.id))return o}}return t.bounds.containsPoint(e,r)&&"none"!==t.style.fill?t:null},n}(),Joe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),lp=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},n_=function(n){function t(e,i,r,s){var o=n.call(this,e,i,r,s)||this;return o.objectZIndex=-1,o.zIndexTable={},o.objects=[],o}return Joe(t,n),lp([I("")],t.prototype,"id",void 0),lp([I(!0)],t.prototype,"visible",void 0),lp([I(!1)],t.prototype,"lock",void 0),lp([I()],t.prototype,"objects",void 0),lp([I()],t.prototype,"addInfo",void 0),lp([I(-1)],t.prototype,"zIndex",void 0),t}(Ee),ET=function(n,t,e,i){return new(e||(e=Promise))(function(r,s){function o(h){try{l(i.next(h))}catch(c){s(c)}}function a(h){try{l(i.throw(h))}catch(c){s(c)}}function l(h){h.done?r(h.value):new e(function(c){c(h.value)}).then(o,a)}l((i=i.apply(n,t||[])).next())})},DT=function(n,t){var i,r,s,o,e={label:0,sent:function(){if(1&s[0])throw s[1];return s[1]},trys:[],ops:[]};return o={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function a(h){return function(c){return function l(h){if(i)throw new TypeError("Generator is already executing.");for(;e;)try{if(i=1,r&&(s=2&h[0]?r.return:h[0]?r.throw||((s=r.return)&&s.call(r),0):r.next)&&!(s=s.call(r,h[1])).done)return s;switch(r=0,s&&(h=[2&h[0],s.value]),h[0]){case 0:case 1:s=h;break;case 4:return e.label++,{value:h[1],done:!1};case 5:e.label++,r=h[1],h=[0];continue;case 7:h=e.ops.pop(),e.trys.pop();continue;default:if(!(s=(s=e.trys).length>0&&s[s.length-1])&&(6===h[0]||2===h[0])){e=0;continue}if(3===h[0]&&(!s||h[1]>s[0]&&h[1]1)for(var i=0;i-1)return e[parseInt(i.toString(),10)];return this.diagram.activeLayer},n.prototype.getLayer=function(t){for(var e=this.diagram.layers,i=0;i=0;o--)this.diagram.unSelect(this.diagram.nameTable[s[parseInt(o.toString(),10)]]),this.diagram.remove(this.diagram.nameTable[s[parseInt(o.toString(),10)]]),"default_layer"!==i.id&&this.diagram.activeLayer.id===t&&(this.diagram.activeLayer=this.diagram.layers[this.diagram.layers.length-1]);delete this.diagram.layerZIndexTable[i.zIndex],this.diagram.layers.splice(r,1),"SVG"!==this.diagram.mode&&this.diagram.refreshDiagramLayer()}},n.prototype.moveObjects=function(t,e){this.diagram.startGroupAction();for(var i={},r=[],s=0;s-1){if(r=[],(h=this.diagram.nameTable[""+s]).children)for(var p=0,g=h.children;p0){for(var y=void 0,S=0,b=r;S0)for(var r=0;r0)for(r=0;r0){t=t.concat(this.diagram.selectedItems.connectors);for(var i=0;i0)for(t=t.concat(this.diagram.selectedItems.nodes),i=0;i0){for(var i=0,r=t.shape.activity.subProcess.processes;i0&&this.copyProcesses(this.processTable[""+s])}this.clipboardData.processTable=this.processTable}},n.prototype.group=function(){this.oldSelectedObjects=am(this.diagram);var e=this.diagram.isProtectedOnChange;this.diagram.protectPropertyChange(!0),this.diagram.diagramActions=this.diagram.diagramActions|ee.Group;var r={};r.id="group"+Qe(),(r=new te(this.diagram,"nodes",r,!0)).children=[];for(var s=this.diagram.selectedItems.nodes.concat(this.diagram.selectedItems.connectors).sort(function(h,c){return h.zIndex-c.zIndex}),o=0;o0){var a=this.diagram.add(r);a&&this.select(a),this.addHistoryEntry({type:"Group",undoObject:r,redoObject:r,category:"Internal"}),this.diagram.diagramActions=this.diagram.diagramActions&~ee.Group,this.diagram.protectPropertyChange(e)}},n.prototype.unGroup=function(t){var i=this.diagram.isProtectedOnChange;this.diagram.protectPropertyChange(!0),this.diagram.diagramActions=this.diagram.diagramActions|ee.Group;var r=[];t?r.push(t):r=this.diagram.selectedItems.nodes,this.diagram.startGroupAction();for(var s=0;s0&&this.diagram.removePorts(o,o.ports),o.annotations&&o.annotations.length>0&&!ce()&&this.diagram.removeLabels(o,o.annotations);for(var c=this.diagram.nameTable[o.parentId],d=o.children.length-1;d>=0;d--)this.diagram.nameTable[o.children[parseInt(d.toString(),10)]].parentId="",this.diagram.deleteChild(this.diagram.nameTable[o.children[parseInt(d.toString(),10)]],o),o.parentId&&o.children[parseInt(d.toString(),10)]&&this.diagram.addChild(c,o.children[parseInt(d.toString(),10)]);this.resetDependentConnectors(o.inEdges,!0),this.resetDependentConnectors(o.outEdges,!1),this.diagram.diagramActions&ee.UndoRedo||this.addHistoryEntry({type:"UnGroup",undoObject:a,redoObject:a,category:"Internal"}),o.parentId&&this.diagram.deleteChild(o,c)}this.diagram.removeNode(o,l),this.clearSelection()}this.diagram.endGroupAction(),this.diagram.diagramActions=this.diagram.diagramActions&~ee.Group,this.diagram.protectPropertyChange(i)},n.prototype.resetDependentConnectors=function(t,e){for(var i=0;i0&&(g=!1)}if(g){var y=this.cloneConnector(f,i);c.push(y),o[h.id]=y.id}}else{var S=this.cloneNode(h,i);if(c.push(S),S){o[h.id]=S.id;var b=h.inEdges;if(b)for(var M=0,w=b;M0)for(var u=0;u0)for(r=t.segments,s=0;s0&&this.diagram.drawingObject&&"Bezier"===this.diagram.drawingObject.type&&(t.segments=[]);var e=this.diagram.add(t);"SVG"!==this.diagram.mode&&this.diagram.refreshDiagramLayer(),this.selectObjects([e]),t&&!_I(this.diagram)&&(this.diagram.tool&=~ri.DrawOnce,this.diagram.currentDrawingObject=void 0)},n.prototype.enableServerDataBinding=function(t){this.diagram.enableServerDataBinding(t)},n.prototype.addText=function(t,e){var i=this.diagram.findElementUnderMouse(t,e,this.diagram);this.diagram.startTextEdit(t,i instanceof ai?i.id.split("_")[1]:void 0)},n.prototype.isUserHandle=function(t){var e=this.diagram.selectedItems;if(e.wrapper&&qr(e.constraints,"UserHandle"))for(var i=0,r=e.userHandles;i0&&t[0]&&t[0].isLane)for(s=this.diagram.getObject(t[0].parentId),t[0].shape.header=[],a=0;a1||e&&1===t.length)){if(1!==t.length)return[2];this.clearSelection()}if(!(u||d||1!==t.length||e&&$a(this.diagram)))return this.clearSelection(),[2]}if(!r.cancel){for(f=0;f0||e)&&p.children&&!p.parentId)for(g=0;g0||e,!0)}else this.select(p,f>0||e,!0);void 0===i&&(i=c),r={oldValue:i||[],newValue:this.getSelectedObject(),cause:this.diagram.diagramActions,state:"Changed",type:"Addition",cancel:!1},this.diagram.renderSelector(e||t&&t.length>1),ce()||this.diagram.triggerEvent(Ce.selectionChange,r),this.diagram.enableServerDataBinding(!0)}return[2]})})},n.prototype.findParent=function(t){return t.parentId&&this.findParent(t=this.diagram.nameTable[t.parentId]),t},n.prototype.selectProcesses=function(t){if(this.hasProcesses(t))for(var e=t.shape.activity.subProcess.processes,i=0;i0)},n.prototype.select=function(t,e,i){var r=this.getObjectLayer(t.id);if(Ad(t)&&!(t instanceof ei)&&!_r(this.diagram,t)&&r&&!r.lock&&r.visible&&t.wrapper.visible){(e=!!$a(this.diagram)&&e)||this.clearSelection(),this.diagram.enableServerDataBinding(!1);var s=this.diagram.selectedItems;if(t instanceof te?s.nodes.push(t.isHeader?this.diagram.nameTable[t.parentId]:t):s.connectors.push(t),s.selectedObjects.push(t),e)s.wrapper.rotateAngle=s.rotateAngle=0,s.wrapper.children.push(t.wrapper);else if(s.init(this.diagram),1===s.nodes.length&&0===s.connectors.length){var l=Wx(this.diagram,s);l&&(s.wrapper.children[0]=l),s.rotateAngle=s.nodes[0].rotateAngle,s.wrapper.rotateAngle=s.nodes[0].rotateAngle,s.wrapper.pivot=s.nodes[0].pivot}i||this.diagram.renderSelector(e),this.diagram.enableServerDataBinding(!0)}},n.prototype.labelSelect=function(t,e){this.oldSelectedObjects=am(this.diagram);var i=this.diagram.selectedItems,r=this.diagram.allowServerDataBinding;this.diagram.allowServerDataBinding=!1,i.nodes=i.connectors=[],this.diagram.allowServerDataBinding=r,t instanceof te?i.nodes[0]=t:i.connectors[0]=t,i.annotation=this.findTarget(e,t),i.init(this.diagram),this.diagram.renderSelector(!1)},n.prototype.unSelect=function(t){var e=this.diagram.selectedItems.nodes.concat(this.diagram.selectedItems.connectors),i=e.filter(function(a){return a.id!==t.id}),r={oldValue:e,newValue:i,cause:this.diagram.diagramActions,state:"Changing",type:"Removal",cancel:!1};if(this.diagram.currentSymbol||ce()||this.diagram.triggerEvent(Ce.selectionChange,r),_r(this.diagram,t)){var s=this.diagram.selectedItems,o=void 0;t instanceof te?(o=s.nodes.indexOf(t,0),s.nodes.splice(o,1)):(o=s.connectors.indexOf(t,0),s.connectors.splice(o,1)),o=s.selectedObjects.indexOf(t,0),s.selectedObjects.splice(o,1),(r={oldValue:e,newValue:i,cause:this.diagram.diagramActions,state:"Changed",type:"Removal",cancel:(r={oldValue:e,newValue:i,cause:this.diagram.diagramActions,state:"Changed",type:"Removal",cancel:!1}).cancel}).cancel||(o=s.wrapper.children.indexOf(t.wrapper,0),s.wrapper.children.splice(o,1),this.diagram.updateSelector(),this.diagram.currentSymbol||this.diagram.triggerEvent(Ce.selectionChange,r))}},n.prototype.moveSvgNode=function(t,e){var i=this.diagram.nameTable[""+e];if("Native"===i.shape.type||"HTML"===i.shape.type)this.updateNativeNodeIndex(t,e);else{var r=xt(e+"_groupElement",this.diagram.element.id),s=xt(t+"_groupElement",this.diagram.element.id);r.parentNode.insertBefore(s,r)}},n.prototype.moveAfterSvgNode=function(t,e){var i=this.diagram.nameTable[""+e];if(!i||"HTML"!==i.shape.type&&"Native"!==i.shape.type)a=xt(e+"_groupElement",this.diagram.element.id),o=xt(t+"_groupElement",this.diagram.element.id),a.insertAdjacentElement("afterend",o);else for(var r=0;rd&&"SwimLane"!==p.shape.type){var S=$(p);p.zIndex=d-((-1!==i.indexOf(p)?i.indexOf(p):0)+1),p.children&&(d=this.findLowestZIndex(p,c)||d),this.triggerOrderCommand(S,p,p),p.children&&this.updateGroupZindex(p,"SendToBack",d)}else"SwimLane"===p.shape.type&&(y=this.swapZIndexObjects(a,h,r,g));if("SVG"===this.diagram.mode){for(var M="SwimLane"!==this.diagram.nameTable[""+r].shape.type?d:y,w=h[parseInt(M.toString(),10)];!w&&Md)&&(d=f.zIndex)}for(var p=JSON.parse(JSON.stringify(l)),v=Number(Object.keys(l).sort(function(wo,Ul){return Number(wo)-Number(Ul)}).reverse()[0]),y=this.diagram.nameTable[""+e].zIndex,S=[],M=0;M<=v;M++)S.push(l[parseInt(M.toString(),10)]);if("SwimLane"===this.diagram.nameTable[""+e].shape.type)for(var C=v;C>=y;C--)if(l[parseInt(C.toString(),10)]&&this.diagram.nameTable[l[parseInt(C.toString(),10)]].parentId!==e){v=C;break}var D=this.diagram.nameTable[""+e];if(D.zIndexx&&(x=L.zIndex)}}else x=d;D.zIndex=x+((-1!==r.indexOf(D)?r.indexOf(D):0)+1),this.triggerOrderCommand(A,D,D)}else if("SwimLane"===D.shape.type){for(var O=0,N=-1,T=0,z=0,U=JSON.parse(JSON.stringify(l)),B=0;B<=y;B++)if(l[parseInt(B.toString(),10)]&&this.diagram.nameTable[l[parseInt(B.toString(),10)]].parentId===e&&-1===N){N=B,T=B;break}for(var j=0;j<=v;j++)p[parseInt(j.toString(),10)]&&p[parseInt(j.toString(),10)]!==e&&this.diagram.nameTable[p[parseInt(j.toString(),10)]].parentId!==e&&this.diagram.nameTable[p[parseInt(j.toString(),10)]].zIndex>=this.diagram.nameTable[""+e].zIndex&&O++;for(var ue=N,fe=0;fe<=O;fe++){for(;!l[parseInt(ue.toString(),10)];)ue++;z=this.diagram.nameTable[l[parseInt(ue.toString(),10)]].zIndex,ue++}for(var Me=z;Me<=v;Me++){for(;!U[parseInt(N.toString(),10)];)N++;for(;!l[parseInt(Me.toString(),10)];)Me++;l[parseInt(Me.toString(),10)]=U[parseInt(N.toString(),10)],this.diagram.nameTable[l[parseInt(Me.toString(),10)]].zIndex=Me,N++}l[parseInt(v.toString(),10)]=this.diagram.nameTable[""+e].id,this.diagram.nameTable[""+e].zIndex=v,ue=y+1;for(var De=T,xe=0;xe0&&("Native"===hr[0].shape.type||"HTML"===hr[0].shape.type)){for(Ci.parentNode.removeChild(Ci),De=0;De0?r[0]:null},n.prototype.findLowestZIndex=function(t,e){var r=this.diagram.nodes.filter(function(s){return-1!==e.indexOf(s.id)}).filter(function(s){return""===s.parentId&&s.id!==t.id}).map(function(s){return s.zIndex});return r.sort(function(s,o){return s-o}),r.length>0?r[0]:null},n.prototype.triggerOrderCommand=function(t,e,i){var s={zIndex:$(t).zIndex},o={zIndex:e.zIndex},a={element:i,cause:this.diagram.diagramActions,diagramAction:this.diagram.getDiagramAction(this.diagram.diagramActions),oldValue:s,newValue:o};this.diagram.triggerEvent(Ce.propertyChange,a)},n.prototype.checkGroupNode=function(t,e,i){return i[""+e].parentId===i[""+t].parentId},n.prototype.sortByZIndex=function(t,e,i){if("BringForward"===i){var r=e||"zIndex";t=t.sort(function(o,a){return a[""+r]-o[""+r]})}else{var s=e||"zIndex";t=t.sort(function(o,a){return o[""+s]-a[""+s]})}return t},n.prototype.orderCommands=function(t,e,i){var r=this,s=e.nodes;if(s=s.concat(e.connectors),t)if("SendBackward"===i)for(var o=0;oa}),S=v.filter(function(D){return D0?Math.max.apply(Math,S):a,M=y.length>0?Math.min.apply(Math,y):a;if(a!==M){var w=c.zIndexTable[parseInt(M.toString(),10)],C=c.zIndexTable[parseInt(a.toString(),10)];this.moveSvgNode(C,w)}else"SendToBack"===i&&(w=c.zIndexTable[parseInt(a.toString(),10)],C=c.zIndexTable[parseInt(b.toString(),10)],this.moveAfterSvgNode(w,C))}}else this.diagram.refreshCanvasLayers()}},n.prototype.swapDomOrder=function(t,e){if(t){var i=this.diagram.getObject(e);if("Native"===i.shape.type||"HTML"===i.shape.type)this.updateNativeNodeIndex(e,t),this.updateNativeNodeIndex(t,e);else{var r=xt(e+"_groupElement",this.diagram.element.id),s=xt(t+"_groupElement",this.diagram.element.id);r.parentNode.insertBefore(r,s),r.parentNode.insertBefore(s,r)}}},n.prototype.sendForward=function(t){var e=this;if(this.diagram.protectPropertyChange(!0),$a(this.diagram)||t){$(t||(this.diagram.selectedItems.nodes.length?this.diagram.selectedItems.nodes[0]:this.diagram.selectedItems.connectors[0]));var s=t&&t.id,o=this.diagram.layers.indexOf(this.getObjectLayer(s=s||(this.diagram.selectedItems.nodes.length?this.diagram.selectedItems.nodes[0].id:this.diagram.selectedItems.connectors[0].id))),a=$(this.diagram.nameTable),h=(parseInt(o.toString(),10),this.diagram.nameTable[""+s]),c=[],d=this.diagram.spatialSearch.findObjects(h.wrapper.bounds);d.length>2&&(d=this.sortByZIndex(d,void 0,"BringForward"));for(var u=0,f=d;u=0;p--)this.diagram.nameTable[c[parseInt(p.toString(),10)].id].parentId===s&&c.splice(p,1);if(c.length>0){var y=this.diagram.nameTable[c[c.length-1].id];if(y.parentId){var b=hm(y,this.diagram,""),M=this.diagram.nameTable[""+b];M.id!==s&&(c[0]=M)}var w={};for(p=0;p0&&(Object.values(O).forEach(function(ue){ue>=T&&N.push(ue)}),0!==N.length&&this.updateZIndexBySendForward(h,N,o))}var z=[];if(Object.keys(this.changedNodeZIndexes).forEach(function(ue){if((a[""+ue]?a[""+ue].zIndex:null)!==e.changedNodeZIndexes[""+ue]){var De=$(a[""+ue]);z.push(De)}}),this.updateLayerZindexTable(o),L.nodes.splice(0,L.nodes.length),z.forEach(function(ue){var fe=$(ue);L.nodes.push(fe)}),"SVG"===this.diagram.mode){var U=c[c.length-1].id,B=c[c.length-1];B&&!("HTML"===B.shape.type||"Native"===B.shape.type)&&this.moveAfterSvgNode(s,U),this.updateNativeNodeIndex(U,s)}else this.diagram.refreshCanvasLayers();var j=[];Object.keys(this.changedNodeZIndexes).forEach(function(ue){if((a[""+ue]?a[""+ue].zIndex:null)!==e.changedNodeZIndexes[""+ue]){var De=$(e.diagram.nameTable[""+ue]);j.push(De)}});var Q=$(this.diagram.selectedItems);Q.nodes.splice(0,Q.nodes.length),j.forEach(function(ue){var fe=$(ue);Q.nodes.push(fe)}),this.diagram.diagramActions&ee.UndoRedo||this.addHistoryEntry({type:"SendForward",category:"Internal",undoObject:L,redoObject:Q}),this.diagram.endGroupAction()}}this.diagram.protectPropertyChange(!1)},n.prototype.updateZIndexBySendForward=function(t,e,i){var r=$(t);t.zIndex=Math.min.apply(Math,e);var a,s=Math.min.apply(Math,e),o=Math.min.apply(Math,e),l=this.diagram.layers[parseInt(i.toString(),10)].objects,h=this.diagram.nodes.filter(function(S){return-1!==l.indexOf(S.id)});t.children&&this.updateGroupZindex(t,"BringForward",t.zIndex);var c=h.filter(function(S){return S.zIndex===Math.min.apply(Math,e)&&S.id!==t.id});if(c&&c.length>0&&c[0].children){for(var d=Math.min.apply(Math,e),u=0;uo&&g!==t&&g.parentId!==t.id&&c&&c.length>0&&g.parentId!==c[0].id){var v=$(g);g.zIndex=a+1,a++,this.triggerOrderCommand(v,g,g)}var y=g.zIndex;this.changedNodeZIndexes[g.id]=(this.changedNodeZIndexes.hasOwnProperty(g.id),y)}},n.prototype.arrangeZIndexForLowerNodes=function(t,e,i){var r=i.filter(function(o){return o.zIndex<=t&&o.parentId!==e.id});r.sort(function(o,a){return a.zIndex-o.zIndex});for(var s=0;se&&(e=r.zIndex)}return e},n.prototype.sendBackward=function(t){var e=this;if(this.diagram.protectPropertyChange(!0),$a(this.diagram)||t){$(t||(this.diagram.selectedItems.nodes.length?this.diagram.selectedItems.nodes[0]:this.diagram.selectedItems.connectors[0]));var s=t&&t.id,o=this.diagram.layers.indexOf(this.getObjectLayer(s=s||(this.diagram.selectedItems.nodes.length?this.diagram.selectedItems.nodes[0].id:this.diagram.selectedItems.connectors[0].id))),a=$(this.diagram.nameTable),h=(parseInt(o.toString(),10),this.diagram.nameTable[""+s]),c=[],d=this.diagram.spatialSearch.findObjects(h.wrapper.bounds);d.length>2&&(d=this.sortByZIndex(d));for(var u=0,f=d;uNumber(p.zIndex)&&""===p.parentId&&h.wrapper.bounds.intersects(p.wrapper.bounds)&&c.push(p);for(var p=c.length-1;p>=0;p--)(v=this.diagram.nameTable[c[parseInt(p.toString(),10)].id]).parentId===s&&c.splice(p,1);if(c.length>0){var v;if((v=this.diagram.nameTable[c[c.length-1].id]).parentId){var S=hm(v,this.diagram,""),b=this.diagram.nameTable[""+S];s!==b.id&&(c[c.length-1]=b)}var M={};for(p=0;p0&&(Object.values(L).forEach(function(fe){fe<=N&&O.push(fe)}),0!==O.length&&this.updateZIndexBySendBackward(h,O,o))}var T=[];if(Object.keys(this.changedNodeZIndexes).forEach(function(fe){if((a[""+fe]?a[""+fe].zIndex:null)!==e.changedNodeZIndexes[""+fe]){var xe=$(a[""+fe]);T.push(xe)}}),this.updateLayerZindexTable(o),P.nodes.splice(0,P.nodes.length),T.forEach(function(fe){var Me=$(fe);P.nodes.push(Me)}),"SVG"===this.diagram.mode){var z=c[c.length-1].id,U=c[c.length-1];U&&"HTML"!==U.shape.type&&"Native"!==U.shape.type&&this.moveSvgNode(s,z);var B=this.diagram.nameTable[""+z];B.children&&B.children.length>0?this.updateNativeNodeIndex(s):this.updateNativeNodeIndex(s,z)}else this.diagram.refreshCanvasLayers();var j=[];Object.keys(this.changedNodeZIndexes).forEach(function(fe){if((a[""+fe]?a[""+fe].zIndex:null)!==e.changedNodeZIndexes[""+fe]){var xe=$(e.diagram.nameTable[""+fe]);j.push(xe)}});var Q=$(this.diagram.selectedItems);Q.nodes.splice(0,Q.nodes.length),j.forEach(function(fe){var Me=$(fe);Q.nodes.push(Me)}),this.diagram.diagramActions&ee.UndoRedo||this.addHistoryEntry({type:"SendBackward",category:"Internal",undoObject:P,redoObject:Q}),this.diagram.endGroupAction()}}this.diagram.protectPropertyChange(!1)},n.prototype.updateZIndexBySendBackward=function(t,e,i){var r=$(t);t.zIndex=Math.max.apply(Math,e);var f,s=t.zIndex,o=Math.max.apply(Math,e),a=this.diagram.layers[parseInt(i.toString(),10)].objects,l=this.diagram.nodes.filter(function(S){return-1!==a.indexOf(S.id)}),h=l.filter(function(S){return S.zIndex===Math.max.apply(Math,e)&&S.id!==t.id});if(h&&h.length>0&&h[0].children)for(var c=Math.max.apply(Math,e),d=0;d0&&g.parentId!==h[0].id){var v=$(g);g.zIndex=f-1,f--,this.triggerOrderCommand(v,g,g)}var y=g.zIndex;this.changedNodeZIndexes[""+g.id]=(this.changedNodeZIndexes.hasOwnProperty(g.id),y)}},n.prototype.findLowestChildZIndex=function(t){for(var e=t.zIndex,i=0;i0),this.selectObjects([t],!0))},n.prototype.clearSelection=function(t,e){return ET(this,void 0,void 0,function(){var i,r,s,o;return DT(this,function(a){return i=this.diagram.allowServerDataBinding,this.diagram.enableServerDataBinding(!1),$a(this.diagram)&&(r=this.diagram.selectedItems,s=this.getSelectedObject(),this.diagram.currentSymbol&&(this.diagram.previousSelectedObject=s),o={oldValue:s,newValue:[],cause:this.diagram.diagramActions,state:"Changing",type:"Removal",cancel:!1},t&&(ce()||this.diagram.triggerEvent(Ce.selectionChange,o)),o.cancel||(r.offsetX=0,r.offsetY=0,r.width=0,r.height=0,r.rotateAngle=0,r.nodes=[],r.connectors=[],r.wrapper=null,r.annotation=void 0,r.selectedObjects=[],this.diagram.clearSelectorLayer(),t&&(o={oldValue:s,newValue:[],cause:this.diagram.diagramActions,state:"Changed",type:"Removal",cancel:!1},ce()||this.diagram.triggerEvent(Ce.selectionChange,o))),this.diagram.enableServerDataBinding(i)),[2]})})},n.prototype.clearSelectedItems=function(){this.clearSelection((this.diagram.selectedItems.nodes?this.diagram.selectedItems.nodes.length:0)+(this.diagram.selectedItems.connectors?this.diagram.selectedItems.connectors.length:0)>0)},n.prototype.removeStackHighlighter=function(){var t=Fl(this.diagram.element.id),e=t.getElementById(t.id+"_stack_highlighter");e&&e.parentNode.removeChild(e)},n.prototype.renderStackHighlighter=function(t,e){var r,s,o,i=this.diagram.selectedItems.nodes[0];if(!e){var a=this.diagram.findObjectsUnderMouse(t.position);if((e=this.diagram.findObjectUnderMouse(a,"Drag",!0))&&!(e.isLane||e.isPhase||e.isHeader))for(var l=0;l0)for(var a=0;a1)if(i){var h=l.segments[0],c=l.segments[1],u=Ol(AI(t.wrapper,t.wrapper.corners,t.wrapper.bounds),h.direction),g=kl({corners:void 0,point:u=qa(l,0,u,{x:l.sourceWrapper.offsetX,y:l.sourceWrapper.offsetY},!1),margin:void 0,direction:h.direction},{corners:void 0,point:c.points[1],margin:void 0,direction:void 0});h.length=R.distancePoints(g[0],g[1]),c.direction&&c.length&&(c.length=R.distancePoints(g[1],g[2]))}else if(o){switch(l.segments[0].direction){case"Bottom":r=t.wrapper.bounds.bottomCenter.x-e.bottomCenter.x,s=t.wrapper.bounds.bottomCenter.y-e.bottomCenter.y;break;case"Top":r=t.wrapper.bounds.topCenter.x-e.topCenter.x,s=t.wrapper.bounds.topCenter.y-e.topCenter.y;break;case"Left":r=t.wrapper.bounds.middleLeft.x-e.middleLeft.x,s=t.wrapper.bounds.middleLeft.y-e.middleLeft.y;break;case"Right":r=t.wrapper.bounds.middleRight.x-e.middleRight.x,s=t.wrapper.bounds.middleRight.y-e.middleRight.y}this.dragSourceEnd(l,r,s,!0,null,"ConnectorSourceEnd",void 0,void 0,void 0,!(t.parentId&&this.diagram.diagramActions&ee.isGroupDragging))}}},n.prototype.updateEndPoint=function(t,e){var r={sourcePoint:t.sourcePoint,targetPoint:t.targetPoint};t.sourceID&&(r.sourceID=t.sourceID),t.targetID&&(r.targetID=t.targetID),t.sourcePortID&&(r.sourcePortID=t.sourcePortID),t.targetPortID&&(r.targetPortID=t.targetPortID),t.segments&&(r.segments=t.segments),this.diagram.connectorPropertyChange(t,e||{},r),this.diagram.updateSelector()},n.prototype.dragSourceEnd=function(t,e,i,r,s,o,a,l,h,c,d){var u=this.diagram.nameTable[t.id],f={},p=this.checkBoundaryConstraints(e,i,u.wrapper.bounds);if(PI(u)&&p&&"BezierSourceThumb"!==o&&Qv(this.diagram)&&(f=$(f={sourcePoint:u.sourcePoint}),u.sourcePoint.x+=e,u.sourcePoint.y+=i,"ConnectorSourceEnd"===o&&"Orthogonal"===u.type&&this.changeSegmentLength(u,l,h,c),"Bpmn"===u.shape.type&&"Default"===u.shape.sequence&&"Sequence"===u.shape.flow&&this.updatePathElementOffset(u)),"Bezier"===u.type)if(f={sourcePoint:u.sourcePoint},d)this.translateBezierPoints(t,""===o?"ConnectorSourceEnd":o,e,i,d,s,!a);else for(var g=0;g2){var d=R.direction((c=t.segments[2]).points[0],c.points[1]);o.direction===_n(d)?("Right"===o.direction?c.points[0].x=o.points[o.points.length-1].x=l.wrapper.corners.middleRight.x+20:"Left"===o.direction?c.points[0].x=o.points[o.points.length-1].x=l.wrapper.corners.middleLeft.x-20:c.points[0].y=o.points[o.points.length-1].y="Top"===o.direction?l.wrapper.corners.topCenter.y-20:l.wrapper.corners.bottomCenter.y+20,c.direction&&c.length&&(c.length=R.distancePoints(c.points[0],c.points[c.points.length-1])),o.length=R.distancePoints(o.points[0],o.points[o.points.length-1])):o.direction===d&&c.direction&&c.length?("Top"===o.direction||"Bottom"===o.direction?(c.points[0]=o.points[0],c.points[c.points.length-1].x=c.points[0].x):(c.points[0]=o.points[0],c.points[c.points.length-1].y=c.points[0].y),c.length=R.distancePoints(c.points[0],c.points[c.points.length-1]),t.segments.splice(0,2)):o.length=20}else o.length=20;else if(o.length<1)if(""!==t.sourceID){var c;"Right"===a.direction?a.points[a.points.length-1].y=(h=l.wrapper.corners.middleRight).y:"Left"===a.direction?a.points[a.points.length-1].y=(h=l.wrapper.corners.middleLeft).y:a.points[a.points.length-1].x="Top"===a.direction?(h=l.wrapper.corners.topCenter).x:(h=l.wrapper.corners.bottomCenter).x,a.length=R.distancePoints(h,a.points[a.points.length-1]),t.segments.length>2&&(c=t.segments[2]).direction&&c.length&&(c.length=R.distancePoints(a.points[a.points.length-1],c.points[c.points.length-1])),t.segments.splice(0,1)}else t.segments.splice(0,1)}else e&&!i&&t.sourceID!==e.id&&t.segments&&null!==t.segments[0].direction&&e&&e instanceof te&&s&&this.changeSourceEndToNode(t,e),e&&i&&t.sourcePortID!==i&&t.segments&&null!==t.segments[0].direction&&e&&e instanceof te&&s&&this.changeSourceEndToPort(t,e,i)},n.prototype.canConnect=function(t,e){return!(!ua(e)||!Rh(e))},n.prototype.changeSourceEndToPort=function(t,e,i){var r=this.diagram.getWrapper(e.wrapper,i),s={x:r.offsetX,y:r.offsetY},o=zo(s,xn(e.wrapper),e.wrapper.bounds),a=t.segments[0],l=t.segments[1];if(a.direction!==o){var h=[],c={};if(a.direction===_n(o)){c={};var d=void 0;"Top"===o||"Bottom"===o?(d="Top"===o?{type:"Orthogonal",isTerminal:!0,direction:o,length:Math.abs(a.points[0].y-s.y)}:{type:"Orthogonal",isTerminal:!0,direction:o,length:Math.abs(s.y-a.points[0].y)},c=a.points[0].x>s.x?{type:"Orthogonal",isTerminal:!0,direction:"Right",length:a.points[0].x-s.x}:{type:"Orthogonal",isTerminal:!0,direction:"Left",length:s.x-a.points[0].x}):(d="Right"===o?{type:"Orthogonal",isTerminal:!0,direction:o,length:Math.abs(a.points[0].x-s.x)}:{type:"Orthogonal",isTerminal:!0,direction:o,length:Math.abs(s.x-a.points[0].x)},c=a.points[0].y>s.y?{type:"Orthogonal",direction:"Top",isTerminal:!0,length:a.points[0].y-s.y}:{type:"Orthogonal",direction:"Bottom",isTerminal:!0,length:s.y-a.points[0].y}),h.push(new wi(t,"segments",d,!0)),h.push(new wi(t,"segments",c,!0))}else h.push(new wi(t,"segments",c={type:"Orthogonal",direction:o,length:20,isTerminal:!0},!0));a.direction!==_n(o)&&("Top"===o||"Bottom"===o?(a.points[0].x=s.x,a.points[0].y=a.points[a.points.length-1].y="Top"===o?s.y-20:s.y+20):(a.points[0].y=s.y,a.points[0].x=a.points[a.points.length-1].x="Right"===o?s.x+20:s.x-20),a.length=R.distancePoints(a.points[0],a.points[a.points.length-1]),l.length=R.distancePoints(a.points[a.points.length-1],l.points[l.points.length-1])),t.segments=h.concat(t.segments)}else a.points[0]=s,"Top"===o||"Bottom"===o?a.points[a.points.length-1].x=s.x:a.points[a.points.length-1].y=s.y,a.length=R.distancePoints(a.points[0],a.points[a.points.length-1]),l.length=R.distancePoints(a.points[a.points.length-1],l.points[l.points.length-1])},n.prototype.removeTerminalSegment=function(t,e){for(var i=0;ii.width||"Left"===o.direction&&r.x>=o.points[0].x||"Right"===o.direction&&r.x<=o.points[0].x)o.points[0].y=o.points[o.points.length-1].y=r.y,o.points[0].x=r.x,o.length=R.distancePoints(o.points[0],o.points[o.points.length-1]),a.length=R.distancePoints(o.points[o.points.length-1],a.points[a.points.length-1]);else{var h=void 0;s="Bottom"===(h=a.direction?a.direction:R.direction(a.points[0],a.points[a.points.length-1]))?i.bottomCenter:i.topCenter,a.length&&a.direction&&(a.length="Top"===h?o.points[o.points.length-1].y-(s.y+20):s.y+20-o.points[o.points.length-1].y),o.length=o.points[o.points.length-1].x-s.x,o.direction=o.length>0?"Right":"Left",l.push(new wi(t,"segments",{type:"Orthogonal",direction:h,length:20},!0)),t.segments=l.concat(t.segments)}else r="Bottom"===o.direction?i.bottomCenter:i.topCenter,o.length>i.height||"Top"===o.direction&&r.y>=o.points[0].y||"Bottom"===o.direction&&r.y<=o.points[0].y?(o.points[0].x=o.points[o.points.length-1].x=r.x,o.points[0].y=r.y,o.length=R.distancePoints(o.points[0],o.points[o.points.length-1]),a.length=R.distancePoints(o.points[o.points.length-1],a.points[a.points.length-1])):(s="Left"===a.direction?i.middleLeft:i.middleRight,h=void 0,h=a.direction?a.direction:R.direction(a.points[0],a.points[a.points.length-1]),a.length&&a.direction&&(a.length="Left"===h?o.points[o.points.length-1].x-(s.x+20):s.x+20-o.points[o.points.length-1].x),o.length=o.points[o.points.length-1].y-s.y,o.direction=o.length>0?"Bottom":"Top",l.push(new wi(t,"segments",{type:"Orthogonal",direction:h,length:20},!0)),t.segments=l.concat(t.segments))},n.prototype.translateBezierPoints=function(t,e,i,r,s,o,a){var l=t.segments.indexOf(s),h=t.segments[parseInt(l.toString(),10)],c=l>0?t.segments[l-1]:null,d=null!==c?c.point:t.sourcePoint,u=l===t.segments.length-1?t.targetPoint:h.point;if(h)if("BezierSourceThumb"===e&&(h.vector1.angle||h.vector1.distance)){var f=h.vector1.distance,p=h.vector1.angle;h.vector1={distance:t.distance(d,o),angle:R.findAngle(d,o)},this.translateSubsequentSegment(t,s,!0,h.vector1.distance-f,h.vector1.angle-p)}else"BezierTargetThumb"===e&&(h.vector2.angle||h.vector2.distance)?(f=h.vector2.distance,p=h.vector2.angle,h.vector2={distance:t.distance(u,o),angle:R.findAngle(u,o)},this.translateSubsequentSegment(t,s,!1,h.vector2.distance-f,h.vector2.angle-p)):("ConnectorSourceEnd"===e&&!t.sourceID||"ConnectorTargetEnd"===e&&!t.targetID)&&a&&JI(h.vector1)&&JI(h.vector2)?(R.isEmptyPoint(h.point1)&&(h.bezierPoint1=KI(t.sourcePoint,t.targetPoint)),R.isEmptyPoint(h.point2)&&(h.bezierPoint2=KI(t.targetPoint,t.sourcePoint))):"BezierSourceThumb"===e||"ConnectorSourceEnd"===e&&!a&&JI(h.vector1)?(h.bezierPoint1.x+=i,h.bezierPoint1.y+=r,(!R.isEmptyPoint(h.point1)||a)&&(h.point1={x:h.bezierPoint1.x,y:h.bezierPoint1.y})):("BezierTargetThumb"===e||"ConnectorTargetEnd"===e&&!a&&JI(h.vector2))&&(h.bezierPoint2.x+=i,h.bezierPoint2.y+=r,(!R.isEmptyPoint(h.point2)||a)&&(h.point2={x:h.bezierPoint2.x,y:h.bezierPoint2.y}))},n.prototype.translateSubsequentSegment=function(t,e,i,r,s){var o=t.segments.indexOf(e);parseInt(o.toString(),10),t.bezierSettings.smoothness&CI.SymmetricAngle||(s=null),t.bezierSettings.smoothness&CI.SymmetricDistance||(r=null),(null!=r||null!=s)&&(i?0!==o&&this.updatePreviousBezierSegment(t,o,r,s):o!==t.segments.length-1&&this.updateNextBezierSegment(t,o,r,s))},n.prototype.updatePreviousBezierSegment=function(t,e,i,r){var s=t.segments[e-1],a=(s.vector2.angle+r)%360;a<0&&(a+=360),s.vector2={distance:s.vector2.distance+i,angle:a}},n.prototype.updateNextBezierSegment=function(t,e,i,r){var s=t.segments[e+1],a=(s.vector1.angle+r)%360;a<0&&(a+=360),s.vector1={distance:s.vector1.distance+i,angle:a}},n.prototype.dragTargetEnd=function(t,e,i,r,s,o,a,l){var c,h=this.diagram.nameTable[t.id],d=this.checkBoundaryConstraints(e,i,h.wrapper.bounds);if(zI(h)&&"BezierTargetThumb"!==o&&d&&Qv(this.diagram)){if(c=$(c={targetPoint:h.targetPoint}),h.targetPoint.x+=e,h.targetPoint.y+=i,"ConnectorTargetEnd"===o&&"Orthogonal"===h.type&&h.segments&&h.segments.length>0){var u=h.segments[h.segments.length-2];u&&2===h.segments[h.segments.length-1].points.length&&("Left"===u.direction||"Right"===u.direction?u.points[u.points.length-1].x=h.targetPoint.x:u.points[u.points.length-1].y=h.targetPoint.y,u.length=R.distancePoints(u.points[0],u.points[u.points.length-1]),u.direction=R.direction(u.points[0],u.points[u.points.length-1]))}"Bpmn"===h.shape.type&&"Default"===h.shape.sequence&&"Sequence"===h.shape.flow&&this.updatePathElementOffset(h)}if("Bezier"===h.type)if(c={targetPoint:h.targetPoint},l)this.translateBezierPoints(t,""===o?"ConnectorTargetEnd":o,e,i,l,s,!a);else for(var f=0;f0){if(void 0!==s&&o.segments[parseInt(s.toString(),10)])if("Bezier"===o.type){var a=o.segments[parseInt(s.toString(),10)],l=a.isInternalSegment;l&&null!==o.bezierSettings&&"FreeForm"!==o.bezierSettings.segmentEditOrientation?("Horizontal"===a.orientation?a.point.x+=e:a.point.y+=i,this.updateDirectionalBezierCurve(o)):(a.point.x+=e,a.point.y+=i),l&&(o.isBezierEditing=!0)}else o.segments[parseInt(s.toString(),10)].point.x+=e,o.segments[parseInt(s.toString(),10)].point.y+=i;else for(var h=0;h1){var a=e[1],l=e[2],h={x:.5*(a.x+l.x),y:.5*(a.y+l.y)},c=t.segments[0];c.vector1.angle=Gt(s,a),c.vector1.distance=.5*R.findLength(s,a),c.vector2.angle=Gt(h,a),c.vector2.distance=.5*R.findLength(h,a),c.point=h;var d=t.segments[1];if(d.vector1.angle=Gt(h,l),d.vector1.distance=.5*R.findLength(h,l),t.segments.length>2){var u=e[3],f={x:.5*(l.x+u.x),y:.5*(l.y+u.y)};d.vector2.angle=Gt(f,l),d.vector2.distance=.5*R.findLength(f,l),d.point=f;var p=t.segments[2];if(p.vector1.angle=Gt(f,u),p.vector1.distance=.5*R.findLength(f,u),t.segments.length>3){var g=e[4],v={x:.5*(u.x+g.x),y:.5*(u.y+g.y)};p.vector2.angle=Gt(v,u),p.vector2.distance=.5*R.findLength(v,u),p.point=v;var y=t.segments[3];y.vector1.angle=Gt(v,g),y.vector1.distance=.5*R.findLength(v,g),y.vector2.angle=Gt(o,g),y.vector2.distance=.5*R.findLength(o,g)}else p.vector2.angle=Gt(o,u),p.vector2.distance=.5*R.findLength(o,u)}else d.vector2.angle=Gt(o,l),d.vector2.distance=.5*R.findLength(o,l)}},n.prototype.rotateObjects=function(t,e,i,r,s){r=r||{};var o=Bi();qi(o,i,r.x,r.y);for(var l=0,h=e;l0){this.diagram.protectPropertyChange(!0);var o=t;o.segments=[],this.diagram.connectorPropertyChange(o,{},{segments:o.segments}),this.diagram.protectPropertyChange(!1)}}},n.prototype.updateInnerParentProperties=function(t){var r=this.diagram.isProtectedOnChange;this.diagram.protectPropertyChange(!0);for(var s=this.getAllDescendants(t,[],!1,!0),o=0;o0&&(f=this.diagram.bpmnModule.getChildrenBound(d,d.id,this.diagram),u=d.wrapper.bounds.containsRect(f)),h=d.wrapper.actualSize.width*t,c=d.wrapper.actualSize.height*e,void 0!==d.maxWidth&&0!==d.maxWidth&&(h=Math.min(d.maxWidth,h)),void 0!==d.minWidth&&0!==d.minWidth&&(h=Math.max(d.minWidth,h)),void 0!==d.maxHeight&&0!==d.maxHeight&&(c=Math.min(d.maxHeight,c)),void 0!==d.minHeight&&0!==d.minHeight&&(c=Math.max(d.minHeight,c)),u&&(h=Math.max(h,f.right-d.wrapper.bounds.x),c=Math.max(c,f.bottom-d.wrapper.bounds.y)),t=h/d.actualSize.width,e=c/d.actualSize.height}var p=Bi();o||(o=r);var g=o.wrapper;if(qi(p,-g.rotateAngle,i.x,i.y),Xf(p,t,e,i.x,i.y),qi(p,g.rotateAngle,i.x,i.y),r instanceof te){var d,v=Ke(p,{x:(d=r).wrapper.offsetX,y:d.wrapper.offsetY}),y=d.wrapper.offsetX-d.wrapper.actualSize.width*d.pivot.x,S=d.wrapper.offsetY-d.wrapper.actualSize.height*d.pivot.y;if(h>0)if(d.processId){var b=this.diagram.nameTable[d.processId];(!b.maxWidth||d.margin.left+h0)if(d.processId){var M=this.diagram.nameTable[d.processId];(!M.maxHeight||d.margin.top+c0){if(e.dragLimit=e.dragLimit?e.dragLimit:{},e.dragLimit.top||e.dragLimit.bottom||e.dragLimit.left||e.dragLimit.right){var b={minDistance:null};S=this.getRelativeOffset(v,d,b);var M={minDistance:null};g=this.getRelativeOffset(v,y,M),S=null!=b&&M.minDistance0){if(S=y[y.length-1]){var b=void 0;for(b=0;b=e.x-t.dragLimit.left-r.width/2&&i.x<=e.x+t.dragLimit.right+r.width/2&&(s=!0),i.y>=e.y-t.dragLimit.top-r.height/2&&i.y<=e.y+t.dragLimit.bottom+r.height/2&&(o=!0),{x:s,y:o}},n.prototype.updateLabelMargin=function(t,e,i,r,s,o,a){if(i=i||{x:e.offset,y:0},e&&i&&i.x>0&&i.x<1){var l=R.getLengthFromListOfPoints(t.intermediatePoints),h=this.getPointAtLength(l*i.x,t.intermediatePoints,0),c=this.diagram.scrollSettings.currentZoom,d=e.dragLimit?e.dragLimit:{left:0,right:0,top:0,bottom:0};if(d.top||d.bottom||d.left||d.right){this.diagram.getWrapper(t.wrapper,e.id);var f=new Ne(0,0,0,0),p=this.diagram.getWrapper(t.wrapper,e.id);f.x=p.offsetX/c+o,f.y=p.offsetY/c+a,f.width=p.bounds.width/c,f.height=p.bounds.height/c;var g=new Ne(h.x-(d.left||0)-f.width/2,h.y-(d.top||0)-f.height/2,(d.left||0)+(d.right||0)+f.width,(d.top||0)+(d.bottom||0)+f.height);if(g.containsPoint(r));else for(var S=0,b=this.boundsInterSects([h,r],g,!1);S=t){c=t-r,d=R.findAngle(s,a),u=c*Math.cos(d*Math.PI/180),f=c*Math.sin(d*Math.PI/180),o={x:s.x+u,y:s.y+f};break}r+=h,s=a}else s=a;return o},n.prototype.getInterceptWithSegment=function(t,e){for(var o,a,i=[],r=[],s=[],l=R.findLength({x:0,y:0},{x:this.diagram.scroller.viewPortWidth,y:this.diagram.scroller.viewPortHeight}),h=1;h0&&a<=90||a>180&&a<=270?90:-90;r.push(R.transform(t,a+c,l)),r.push(R.transform(t,o+c,l));var f=nm({x1:s[0].x,y1:s[0].y,x2:s[1].x,y2:s[1].y},{x1:r[0].x,y1:r[0].y,x2:r[1].x,y2:r[1].y});f.enabled&&i.push(f.intersectPt)}return i},n.prototype.getAnnotationChanges=function(t,e){var r={};return r[ab(t,e.id,!0)]={width:e.width,height:e.height,offset:t instanceof te?{x:e.offset.x,y:e.offset.y}:e.offset,rotateAngle:e.rotateAngle,margin:{left:e.margin.left,right:e.margin.right,top:e.margin.top,bottom:e.margin.bottom},horizontalAlignment:e.horizontalAlignment,verticalAlignment:e.verticalAlignment,alignment:t instanceof de?e.alignment:void 0},{annotations:r}},n.prototype.getConnectorPortChanges=function(t,e){var i=function Wse(n,t,e){for(var i=n.ports,r=0;r1&&(v.width=g,v.offset.x=1/S),p>1&&(v.height=p,v.offset.y=1/b)}}e instanceof Or&&(e.alignment="Center"),l=this.getAnnotationChanges(t,e),t instanceof te?this.diagram.nodePropertyChange(t,a,l):this.diagram.connectorPropertyChange(t,a,l),this.diagram.updateDiagramObject(t)},n.prototype.getSubProcess=function(t){var i,e={nodes:[],connectors:[]};return t instanceof te?i=t.processId:t&&t.nodes&&t.nodes.length&&t.nodes[0].processId&&(i=t.nodes[0].processId),i&&e.nodes.push($(this.diagram.nameTable[i])),e},n.prototype.checkBoundaryConstraints=function(t,e,i,r){var s=this.diagram.pageSettings,o=this.diagram.pageSettings.boundaryConstraints,a=this.diagram.scroller;if("Page"===o||"Diagram"===o){var l=i?void 0:this.diagram.selectedItems.wrapper.bounds;return!!((i?i.right:l.right)+(t||0)<=("Page"===o?s.width:a.viewPortWidth)&&(i?i.left:l.left)+(t||0)>=0&&(i?i.bottom:l.bottom)+(e||0)<=("Page"===o?s.height:a.viewPortHeight)&&(i?i.top:l.top)+(e||0)>=0||"None"!==this.diagram.layout.type&&r)}return!0},n.prototype.dragSelectedObjects=function(t,e){var i=this,r=this.diagram.selectedItems;this.state&&!this.state.backup&&(this.state.backup={},this.state.backup.offsetX=r.offsetX,this.state.backup.offsetY=r.offsetY),r=XI(this.diagram,r)||r;var s=this.diagram.selectedItems.nodes.filter(function(c){return"SwimLane"===c.shape.type});if(s.length>0&&!this.diagram.currentSymbol&&this.diagram.selectedItems.nodes.length>1){var o=this.diagram.selectedItems.nodes.filter(function(c){return""===c.parentId||"SwimLane"!==i.diagram.nameTable[c.parentId].shape.type});if(o.length>0){for(var a=0;a0||l.length>1)&&(o=o.concat(l),this.diagram.selectedItems.nodes.splice(0,this.diagram.selectedItems.nodes.length),o.forEach(function(c){i.diagram.selectedItems.nodes.push(c)}),r=this.diagram.selectedItems,this.diagram.selectedObject.helperObject=void 0)}}if(this.checkBoundaryConstraints(t,e)){this.diagram.diagramActions=this.diagram.diagramActions|ee.PreventZIndexOnDragging|ee.DragUsingMouse;var h=this.diagram.selectedObject.actualObject;return(h&&h instanceof te&&h.isLane&&Qx(h,this.diagram)||!h||!h.isLane)&&this.diagram.drag(r,t,e),this.diagram.diagramActions=this.diagram.diagramActions&~(ee.PreventZIndexOnDragging|ee.DragUsingMouse),this.diagram.refreshCanvasLayers(),this.checkHtmlObjectDrag(r),!0}return!1},n.prototype.checkHtmlObjectDrag=function(t){var e=!1;this.diagram.views&&this.diagram.views.length>1&&(t instanceof ei?e=t.nodes.some(function(i){return i.shape&&"HTML"===i.shape.type}):t.shape&&"HTML"===t.shape.type&&(e=!0),e&&this.resetOverviewCanvas())},n.prototype.resetOverviewCanvas=function(){for(var t=0,e=this.diagram.views;t0&&(this.layoutAnimateModule.stopCurrentAnimation(this.objectStore[0],e,t),this.objectStore=[]),a=this.diagram.doLayout(),this.objectStore.push(a)),this.canUpdateTemplate=!1,this.diagram.blazorActions&=~on.expandNode,this.diagram.preventNodesUpdate=r,this.diagram.layoutAnimateModule&&this.diagram.organizationalChartModule&&!i)this.diagram.allowServerDataBinding=!1,this.layoutAnimateModule.expand(this.diagram.layout.enableAnimation,a,t,this.diagram);else{var l={element:$(t),state:!!t.isExpanded};this.triggerEvent(Ce.expandStateChange,l),this.diagram.lineRoutingModule&&this.diagram.constraints&nt.LineRouting&&"ComplexHierarchicalTree"!==this.diagram.layout.type&&this.diagram.resetSegments()}return this.diagram.layout.fixedNode=""===o?"":this.diagram.layout.fixedNode,a},n.prototype.getparentexpand=function(t,e,i,r){for(var s,o=0;o0&&(this.diagram.selectedItems.wrapper.rotateAngle=this.diagram.selectedItems.rotateAngle=s.rotateAngle),!(r instanceof te&&"SwimLane"!==r.shape.type)||r.isLane||r.isPhase||r.isHeader||Dn(this.diagram,r)){if(r instanceof ei)for(var d=0;d30||g.wrapper.outerBounds.topCenter.y-p.wrapper.outerBounds.bottomCenter.y>30)&&this.diagram.lineRoutingModule.refreshConnectorSegments(this.diagram,f,!0)}}this.updateSelector(),this.diagram.protectPropertyChange(!1)}},n.prototype.drawSelectionRectangle=function(t,e,i,r){this.diagram.drawSelectionRectangle(t,e,i,r)},n.prototype.startGroupAction=function(){this.diagram.startGroupAction()},n.prototype.endGroupAction=function(){this.diagram.endGroupAction()},n.prototype.removeChildFromBPmn=function(t,e,i){var r=this.diagram.nameTable[t.id]||t.nodes[0];if(i&&r&&r.processId&&r.processId===i.wrapper.id){var s=$(r);s.processId=r.processId,this.diagram.startGroupAction();var o=this.diagram.nameTable[r.processId].shape.activity.subProcess.processes||[];o.splice(o.indexOf(r.id),1),this.diagram.bpmnModule.removeChildFromBPMN(this.diagram.nameTable[r.processId].wrapper,r.id,this.diagram),this.diagram.nameTable[r.id].processId="",r.offsetX=r.wrapper.offsetX,r.offsetY=r.wrapper.offsetY;var a=$(r);this.addHistoryEntry({type:"PositionChanged",redoObject:{nodes:[a]},undoObject:{nodes:[s]},category:"Internal"}),this.diagram.endGroupAction()}},n.prototype.isDroppable=function(t,e){var i=this.diagram.nameTable[t.id]||t.nodes[0];return i instanceof te&&(!ce()&&"TextAnnotation"===i.shape.shape||("Group"===e.shape.shape&&(e.shape.activity.subProcess.collapsed=!1),!(i&&"Bpmn"===i.shape.type&&(i.processId===e.id||i.id===e.processId||"Bpmn"===e.shape.type&&!(e instanceof de)&&e.shape.activity&&e.shape.activity.subProcess&&e.shape.activity.subProcess.collapsed))))},n.prototype.renderHighlighter=function(t,e,i){if(new Ne,t.target instanceof te||t.target instanceof de||e&&(t.source instanceof te||t.source instanceof de)){var a=this.findTarget(e?t.sourceWrapper:t.targetWrapper,e?t.source:t.target,i,!0),l=void 0;if(a instanceof Bd)for(var h=a.id,c=t.target,u=0,f=c.wrapper.children[0].children[0].children[2].children;u0){var r=0;t[0]=this.diagram.nameTable[t[0].id]||t[0];var s="Object"===i?yr(t[0].wrapper):this.diagram.selectedItems.wrapper.bounds,o={nodes:[],connectors:[]},a={nodes:[],connectors:[]};for(r="Object"===i?r+1:r;r0){var i=0,r=0,s=0,o=0,a=0,l=0,h=0,c=0,d={nodes:[],connectors:[]},u={nodes:[],connectors:[]};for(i=0;io.center.y&&(r=n[parseInt(e.toString(),10)],n[parseInt(e.toString(),10)]=n[parseInt(i.toString(),10)],n[parseInt(i.toString(),10)]=r):s.center.x>o.center.x&&(r=n[parseInt(e.toString(),10)],n[parseInt(e.toString(),10)]=n[parseInt(i.toString(),10)],n[parseInt(i.toString(),10)]=r)}}return n}(t,e),i=1;i0){var i=0,r={x:.5,y:.5};t[0]=this.diagram.nameTable[t[0].id]||t[0];var s=yr(t[0].wrapper),o={nodes:[],connectors:[]},a={nodes:[],connectors:[]};for(i=1;ii.zIndex){for(var s=this.diagram.layers.indexOf(this.diagram.getActiveLayer()),o=this.diagram.layers[parseInt(s.toString(),10)].zIndexTable,a=JSON.parse(JSON.stringify(o)),l=i.zIndex,h=r.zIndex,c=h;c>=l;c--)l!==c?o[c-1]?(o[parseInt(c.toString(),10)]=o[c-1],this.diagram.nameTable[o[parseInt(c.toString(),10)]].zIndex=c):(o[c-1]=o[parseInt(c.toString(),10)],this.diagram.nameTable[o[c-1]].zIndex=c,delete o[parseInt(c.toString(),10)]):this.swapZIndexObjects(h,o,r.id,a);"SVG"===this.diagram.mode?(this.moveSvgNode(e.parentId,i.id),this.updateNativeNodeIndex(e.parentId,i.id)):this.diagram.refreshCanvasLayers()}},n.prototype.findLeastIndexConnector=function(t,e,i){for(var r=0;rs.zIndex&&(i=s)}return i},n.prototype.findLeastIndexObject=function(t,e){var i=t;return t instanceof te&&(i=this.findLeastIndexConnector(t.inEdges,e,i),i=this.findLeastIndexConnector(t.outEdges,e,i)),i},n.prototype.checkSelection=function(t,e){var i;if(1===t.nodes.length&&0===t.connectors.length)if(Dn(this.diagram,t.nodes[0],!0)){var r=t.nodes[0];if("SwimLane"===(i="SwimLane"===t.nodes[0].shape?t.nodes[0]:this.diagram.nameTable[t.nodes[0].parentId]).shape.type){var s="Horizontal"===i.shape.orientation;(r.isPhase&&(s&&"ResizeSouth"===e||!s&&"ResizeEast"===e)||r.isLane&&(s&&"ResizeEast"===e||!s&&"ResizeSouth"===e))&&W3(this.diagram,i,e)}else if("Grid"===i.container.type)if("Horizontal"===i.container.orientation&&1===r.rowIndex||"Vertical"===i.container.orientation&&r.rowIndex>0&&r.columnIndex>0){if("ResizeSouth"===e)for(var o=0;o1&&(this.diagram.realActions=this.diagram.realActions|$i.hScrollbarMoved,this.scrolled=!0),this.diagram.scrollSettings.horizontalOffset=t},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"verticalOffset",{get:function(){return this.vOffset},set:function(t){this.vOffset=t,Math.abs(this.vOffset-this.diagram.scrollSettings.verticalOffset)>1&&(this.diagram.realActions=this.diagram.realActions|$i.vScrollbarMoved,this.scrolled=!0),this.diagram.scrollSettings.verticalOffset=t},enumerable:!0,configurable:!0}),n.prototype.getBounds=function(){var e=this.diagram.spatialSearch.getPageBounds(0,0);return(e.x<0||e.y<0)&&!this.diagram.pageSettings.multiplePage?this.getPageBounds(void 0,void 0,!0,!0):this.getPageBounds(void 0,void 0,!0)},n.prototype.updateScrollOffsets=function(t,e){var i,r,s=this.getBounds();s.x*=this.currentZoom,s.y*=this.currentZoom,s.width*=this.currentZoom,s.height*=this.currentZoom,i=Math.max(0,t-s.left),r=Math.max(0,e-s.top),void 0!==t&&void 0!==e?(this.horizontalOffset=i,this.verticalOffset=r,this.diagram.setOffset(i,r)):this.diagram.setOffset(-this.horizontalOffset-s.x,-this.verticalOffset-s.y),this.transform={tx:Math.max(this.horizontalOffset,-s.left)/this.currentZoom,ty:Math.max(this.verticalOffset,-s.top)/this.currentZoom,scale:this.currentZoom}},n.prototype.setScrollOffset=function(t,e){this.scrolled=!1;var i=this.getBounds();i.x*=this.currentZoom,i.y*=this.currentZoom,i.width*=this.currentZoom,i.height*=this.currentZoom;var r=-i.left,s=-i.top,o=!1,a=this.viewPortWidth*this.currentZoom,l=this.viewPortHeight*this.currentZoom,h=r-t;if(h!==this.horizontalOffset){rh?this.horizontalOffset-=t:this.horizontalOffset=h,o=!0);var c=Math.max(i.right+this.vScrollSize,a);if(!o&&c<-h+this.viewPortWidth){var d=-h+a-this.vScrollSize,u=-this.horizontalOffset+a-this.vScrollSize;this.horizontalOffset=dd-u?h:-(i.right+this.vScrollSize-a),o=!0}o||(this.horizontalOffset=r-t)}o=!1;var f=s-e;if(f!==this.verticalOffset){sf?this.verticalOffset-=e:this.verticalOffset=f,o=!0);var p=Math.max(i.bottom+this.hScrollSize,l);if(!o&&p<-f+l){var g=-f+l-this.hScrollSize,v=-this.verticalOffset+l-this.hScrollSize;this.verticalOffset=gg-v?f:-(i.bottom+this.hScrollSize-l),o=!0}o||(this.verticalOffset=s-e)}this.transform={tx:Math.max(this.horizontalOffset,-i.left)/this.currentZoom,ty:Math.max(this.verticalOffset,-i.top)/this.currentZoom,scale:this.currentZoom},this.setSize()},n.prototype.getObjects=function(t,e){for(var i=[],r=0;r0){for(var l=0;l0){h.push(i[parseInt(o.toString(),10)].id);for(var d=0;d=e.bottom&&(l=0),-this.horizontalOffset<=e.x&&-this.horizontalOffset+this.viewPortWidth>=e.right&&(a=0),this.hScrollSize=a,this.vScrollSize=l;var h=this.diagramWidth,c=this.diagramHeight;this.diagramWidth=Math.max(e.right,-this.horizontalOffset+this.viewPortWidth-l)-i,this.diagramHeight=Math.max(e.bottom,-this.verticalOffset+this.viewPortHeight-a)-r,(h!==this.diagramWidth||c!==this.diagramHeight)&&"Diagram"!==this.diagram.scrollSettings.scrollLimit&&this.diagram.setSize(this.diagramWidth,this.diagramHeight),"Diagram"===this.diagram.scrollSettings.scrollLimit&&(h===this.diagramWidth&&c===this.diagramHeight&&1===this.currentZoom||this.diagram.diagramActions&&t&&(!this.diagram.diagramActions||!t||0===this.verticalOffset&&this.verticalOffset!==t.y||0===this.horizontalOffset&&this.horizontalOffset!==t.x)?t&&h===this.diagramWidth&&c===this.diagramHeight&&(this.diagram.diagramCanvas.scrollHeight>this.viewPortHeight&&t.y<0&&this.horizontalOffset===t.x&&0===this.verticalOffset||this.diagram.diagramCanvas.scrollWidth>this.viewPortWidth&&t.x<0&&this.verticalOffset===t.y&&0===this.horizontalOffset)&&(this.verticalOffset=t.y,this.horizontalOffset=t.x,this.transform={tx:Math.max(t.x,-e.left)/this.currentZoom,ty:Math.max(t.y,-e.top)/this.currentZoom,scale:this.currentZoom}):(this.diagram.scrollActions&da.Interaction&&t&&(this.transform={tx:Math.max(t.x,-e.left/this.currentZoom)/this.currentZoom,ty:Math.max(t.y,-e.top/this.currentZoom)/this.currentZoom,scale:this.currentZoom},this.horizontalOffset=t.x,this.verticalOffset=t.y),this.diagram.setSize(this.diagramWidth,this.diagramHeight),!(this.diagram.scrollActions&da.PropertyChange)&&t&&(this.horizontalOffset=t.x,this.verticalOffset=t.y,this.transform={tx:Math.max(t.x,-e.left)/this.currentZoom,ty:Math.max(t.y,-e.top)/this.currentZoom,scale:this.currentZoom}))),this.diagram.transformLayers(),this.diagram.element.style.overflow="hidden"},n.prototype.setViewPortSize=function(t,e){this.viewPortWidth=t,this.viewPortHeight=e},n.prototype.getPageBounds=function(t,e,i,r){var o,s=new Ne;if("Content"===e||r||null===this.diagram.pageSettings.width||null===this.diagram.pageSettings.height){var u=t?void 0:0;o=this.diagram.spatialSearch.getPageBounds(u,u)}else{var a=this.diagram.pageSettings.width,l=this.diagram.pageSettings.height,h=0,c=0;if(this.diagram.pageSettings.multiplePage){if((s=this.diagram.spatialSearch.getPageBounds(0,0)).right>a&&(a*=d=Math.ceil(s.right/a)),s.bottom>l&&(l*=d=Math.ceil(s.bottom/l)),s.left<0&&Math.abs(s.left)>h){var d=Math.ceil(Math.abs(s.left)/this.diagram.pageSettings.width);h=this.diagram.pageSettings.width*d}s.top<0&&Math.abs(s.top)>c&&(d=Math.ceil(Math.abs(s.top)/this.diagram.pageSettings.height),c=this.diagram.pageSettings.height*d)}o=new Ne(-h,-c,a+h,l+c)}if(i){var f=this.diagram.scrollSettings.padding;o.x-=f.left,o.y-=f.top,o.width+=f.left+f.right,o.height+=f.top+f.bottom}return o},n.prototype.getPageBreak=function(t){for(var e=0,i=0,r=-1,s=[],c=this.diagram.pageSettings.margin.left,d=this.diagram.pageSettings.margin.right,u=this.diagram.pageSettings.margin.top,f=this.diagram.pageSettings.margin.bottom,p=1,g=1;t.width>e;)(e+=this.diagram.pageSettings.width?this.diagram.pageSettings.width:t.width)===this.diagram.pageSettings.width&&(s[++r]={x1:t.left+c,y1:t.top+u,x2:t.left+c,y2:t.bottom-f}),ei;)(i+=this.diagram.pageSettings.height?this.diagram.pageSettings.height:t.height)===this.diagram.pageSettings.height&&(s[++r]={x1:t.left+c,y1:t.top+u,x2:t.right-d,y2:t.top+u}),i=this.diagram.scrollSettings.minZoom||l||t>=1)){this.currentZoom*=t;var c=this.getPageBounds(void 0,void 0,!0);c.x*=this.currentZoom,c.y*=this.currentZoom;var d=Bi();Xf(d,t,t,r.x,r.y),r3(d,e||0,i||0),bx(h,d);var u=Ke(h,{x:0,y:0});if(1===t&&(u=this.applyScrollLimit(u.x,u.y,s,o,a)),a=-c.y>=u.y&&-c.x>=u.x&&a,(this.diagram.scrollActions&da.PropertyChange||!(this.diagram.scrollActions&da.Interaction)||"Diagram"!==this.diagram.scrollSettings.scrollLimit||a)&&(this.transform={tx:Math.max(u.x,-c.left)/this.currentZoom,ty:Math.max(u.y,-c.top)/this.currentZoom,scale:this.currentZoom},this.horizontalOffset=u.x,this.verticalOffset=u.y),this.setSize(u),"SVG"!==this.diagram.mode&&Ds(this.diagram)&&this.diagram.scroller.virtualizeElements(),"SVG"!==this.diagram.mode&&!Ds(this.diagram)&&this.diagram.refreshDiagramLayer(),this.diagram.setOffset(-this.horizontalOffset-c.x,-this.verticalOffset-c.y),eb(this.diagram),this.diagram.views&&this.diagram.views.overview){var f=this.diagram.views.overview,p=f.scrollOverviewRect(f.parent.scroller.horizontalOffset,f.parent.scroller.verticalOffset,f.parent.scroller.currentZoom,!0);f.updateOverviewrect(-p.x,-p.y,p.width,p.height),f.updateView(f)}}}},n.prototype.fitToPage=function(t){var e=(t=t||{}).mode,i=t.region,r=t.margin||{},s=t.canZoomIn,o=t.customBounds,a=t.canZoomOut;r.bottom=r.bottom||25,r.top=r.top||25,r.left=r.left||25,r.right=r.right||25;var h,l=o,c=-this.horizontalOffset,d=-this.verticalOffset;if("PageSettings"===(i=i||"PageSettings")&&this.diagram.pageSettings.width&&this.diagram.pageSettings.height||this.diagram.nodes.length>0||this.diagram.connectors.length>0){e=e||"Page","CustomBounds"!==i&&(l=this.getPageBounds(!0,i,!0));var u={x:0,y:0};r.left+r.right>this.viewPortWidth&&(this.viewPortWidth<=100?(r.left=5,r.right=5):(r.left=25,r.right=25)),r.top+r.bottom>this.viewPortHeight&&(this.viewPortHeight<=100?(r.top=5,r.bottom=5):(r.top=25,r.bottom=25)),u.x=(this.viewPortWidth-(r.left+r.right))/l.width,u.y=(this.viewPortHeight-(r.top+r.bottom))/l.height,!s&&l.width-this.horizontalOffset-a+this.viewPortWidth&&(i=o.right-this.viewPortWidth,i+=20),o.x<-a&&(i=o.x),o.bottom>-l+this.viewPortHeight&&(r=o.bottom-this.viewPortHeight,r+=20),o.y<-l&&(r=o.y),this.zoom(1,-this.horizontalOffset-i,-this.verticalOffset-r,null,void 0,e))},n.prototype.bringToCenter=function(t){var e=this.currentZoom,i=new Ne(t.x*e,t.y*e,t.width*e,t.height*e),r=i.x+i.width/2-this.viewPortWidth/2,s=i.y+i.height/2-this.viewPortHeight/2;this.zoom(1,-this.horizontalOffset-(r*=-1),-this.verticalOffset-(s*=-1),null)},n.prototype.applyScrollLimit=function(t,e,i,r,s){if("Infinity"===this.diagram.scrollSettings.scrollLimit&&void 0===i&&!r&&(t=-t,e=-e),"Infinity"!==this.diagram.scrollSettings.scrollLimit){var o=void 0;if("Limited"===this.diagram.scrollSettings.scrollLimit){var a=this.diagram.scrollSettings.scrollableArea;o=new Ne(a.x,a.y,a.width,a.height)}(o=o||(s?this.getPageBounds():this.getPageBounds(!0))).x*=this.currentZoom,o.y*=this.currentZoom,o.width*=this.currentZoom,o.height*=this.currentZoom,void 0!==i&&(t*=-1,e*=-1),r&&(t*=-1,e*=-1);var l=Math.max(o.right,this.viewPortWidth);if(!r&&!(t<=o.x&&(t+this.viewPortWidth>=o.right||t>=o.right-this.viewPortWidth)||t>=o.x&&t+this.viewPortWidth<=l))if(t>=o.x)t=Math.max(o.x,Math.min(t,t-(t+this.viewPortWidth-this.vScrollSize-l)));else{var h=o.right-this.viewPortWidth;t=Math.min(h,o.x)}var c=Math.max(o.bottom,this.viewPortHeight);r||e<=o.y&&e+this.viewPortHeight>=o.bottom||e>=o.y&&e+this.viewPortHeight<=c||(e>=o.y?e=Math.max(o.y,Math.min(e,e-(e+this.viewPortHeight-this.hScrollSize-c))):(h=o.bottom-this.viewPortHeight,e=Math.min(o.y,h))),t*=-1,e*=-1}return{x:t,y:e}},n}(),tae=function(){function n(t,e,i,r,s){this.objects=[],this.left=t,this.top=e,this.width=i,this.height=r,this.spatialSearch=s}return n.prototype.findQuads=function(t,e){null!=this.first&&this.first.isIntersect(t)&&this.first.findQuads(t,e),null!=this.second&&this.second.isIntersect(t)&&this.second.findQuads(t,e),null!=this.third&&this.third.isIntersect(t)&&this.third.findQuads(t,e),null!=this.fourth&&this.fourth.isIntersect(t)&&this.fourth.findQuads(t,e),this.objects.length>0&&e.push(this)},n.prototype.isIntersect=function(t){return!(this.left+this.widtht.right||this.top>t.bottom)},n.prototype.selectQuad=function(){for(var i,t=null,e=this;null!=e;)i=e.getQuad(t),e=i.source,t=i.target||t;return t},n.prototype.getQuad=function(t){var e=this.width/2,i=this.height/2;if(e>=1e3&&i>=1e3){var r=this.left+e,s=this.top+i;if(this.spatialSearch.childRight<=r){if(this.spatialSearch.childBottom<=s)return this.first||((o=new n(this.left,this.top,e,i,this.spatialSearch)).parent=this,this.first=o),{source:this.first};if(this.spatialSearch.childTop>=s)return this.third||((o=new n(this.left,s,e,i,this.spatialSearch)).parent=this,this.third=o),{source:this.third}}else if(this.spatialSearch.childLeft>=r){if(this.spatialSearch.childBottom<=s)return this.second||((o=new n(r,this.top,e,i,this.spatialSearch)).parent=this,this.second=o),{source:this.second};var o;if(this.spatialSearch.childTop>=s)return this.fourth||((o=new n(r,s,e,i,this.spatialSearch)).parent=this,this.fourth=o),{source:this.fourth}}}return this.objects.push(this.spatialSearch.childNode),{target:this}},n.prototype.isContained=function(){return this.spatialSearch.childLeft>=this.left&&this.spatialSearch.childRight<=this.left+this.width&&this.spatialSearch.childTop>=this.top&&this.spatialSearch.childBottom<=this.top+this.height},n.prototype.addIntoAQuad=function(t){var e={};this.spatialSearch.setCurrentNode(t);for(var i=null;!e.isAdded;)i=(e=this.spatialSearch.parentQuad.add(i)).quad;return i},n.prototype.add=function(t){if(t=null,this.isContained())return{isAdded:!0,quad:t=this.selectQuad()};var e=void 0,i=!(0!==this.objects.length||this.first||this.second||this.third||this.fourth),r=2*this.width,s=2*this.height;return this.spatialSearch.childLeft=this.childLeft?(this.pageLeft=this.childLeft,this.leftElement=t,r=!0):t===this.leftElement&&(this.pageLeft=Number.MAX_VALUE,this.findLeft(this.parentQuad),r=!0)),(this.pageTop!==this.childTop||t!==this.topElement)&&(this.pageTop>=this.childTop?(this.pageTop=this.childTop,this.topElement=t,r=!0):t===this.topElement&&(this.pageTop=Number.MAX_VALUE,this.findTop(this.parentQuad),r=!0)),(this.pageBottom!==this.childBottom||t!==this.bottomElement)&&(this.pageBottom<=this.childBottom?(r=!0,this.pageBottom=this.childBottom,this.bottomElement=t):t===this.bottomElement&&(this.pageBottom=-Number.MAX_VALUE,this.findBottom(this.parentQuad),r=!0)),(this.pageRight!==this.childRight||t!==this.rightElement)&&(this.pageRight<=this.childRight?(this.pageRight=this.childRight,this.rightElement=t,r=!0):t===this.rightElement&&(this.pageRight=-Number.MAX_VALUE,this.findRight(this.parentQuad),r=!0)),r}return this.setCurrentNode(null),!1},n.prototype.isWithinPageBounds=function(t){return t.left>=this.pageLeft&&t.right<=this.pageRight&&t.top>=this.pageTop&&t.bottom<=this.pageBottom},n.prototype.findQuads=function(t){var e=[];return this.parentQuad.findQuads(t,e),e},n.prototype.findObjects=function(t){for(var i=[],r=0,s=this.findQuads(t);r=r.outerBounds.left&&(this.pageLeft=r.outerBounds.left,this.leftElement=r)}},n.prototype.findTop=function(t){t.first||t.second?(t.first&&this.findTop(t.first),t.second&&this.findTop(t.second)):(t.third&&this.findTop(t.third),t.fourth&&this.findTop(t.fourth));for(var e=0,i=t.objects;e=r.outerBounds.top&&(this.pageTop=r.outerBounds.top,this.topElement=r)}},n.prototype.setCurrentNode=function(t){if(this.childNode=t,t){var e=t.outerBounds;this.childLeft=Number(e.left),this.childTop=Number(e.top),this.childRight=Number(e.right),this.childBottom=Number(e.bottom)}else this.childLeft=Number.MAX_VALUE,this.childTop=Number.MAX_VALUE,this.childRight=-Number.MAX_VALUE,this.childBottom=-Number.MAX_VALUE},n.prototype.getPageBounds=function(t,e){if(this.pageLeft===Number.MAX_VALUE)return new Ne(0,0,0,0);var i=void 0!==t?Math.min(this.pageLeft,0):this.pageLeft,r=void 0!==e?Math.min(this.pageTop,0):this.pageTop;return new Ne(Math.round(i),Math.round(r),Math.round(this.pageRight-i),Math.round(this.pageBottom-r))},n.prototype.getQuad=function(t){return this.quadTable[t.id]},n}(),iae=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),nae=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return iae(t,n),function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);r>3&&s&&Object.defineProperty(t,e,s)}([I(!1)],t.prototype,"preventDefaults",void 0),t}(Ee),sae=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),o_=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},oae=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return sae(t,n),o_([I("")],t.prototype,"action",void 0),o_([I("")],t.prototype,"cursor",void 0),t}(Ee),a_=function(){function n(){this.size=20,this.intermediatePoints=[],this.gridCollection=[],this.startArray=[],this.targetGridCollection=[],this.sourceGridCollection=[],this.considerWalkable=[]}return n.prototype.lineRouting=function(t){var e=t.connectors.length;if(this.renderVirtualRegion(t),e>0)for(var i=0;i=t.right||e.right<=t.left||e.top>=t.bottom||e.bottom<=t.top)},n.prototype.findEndPoint=function(t,e,i){var r,s;if(e&&""!==t.sourcePortID&&t.sourcePortWrapper||!e&&""!==t.targetPortID&&t.targetPortWrapper){s=zo(r=e?{x:t.sourcePortWrapper.offsetX,y:t.sourcePortWrapper.offsetY}:{x:t.targetPortWrapper.offsetX,y:t.targetPortWrapper.offsetY},void 0,e?t.sourceWrapper.bounds:t.targetWrapper.bounds);var o=e?t.sourcePortWrapper.bounds:t.targetPortWrapper.bounds;r=i?"Top"===s?{x:o.topCenter.x,y:o.topCenter.y}:"Left"===s?{x:o.middleLeft.x,y:o.middleLeft.y}:"Right"===s?{x:o.middleRight.x,y:o.middleRight.y}:{x:o.bottomCenter.x,y:o.bottomCenter.y}:{x:o.center.x,y:o.center.y}}else r=e&&this.startNode||!e&&this.targetNode?e?{x:this.startNode.wrapper.offsetX,y:this.startNode.wrapper.offsetY}:{x:this.targetNode.wrapper.offsetX,y:this.targetNode.wrapper.offsetY}:e?{x:t.sourcePoint.x,y:t.sourcePoint.y}:{x:t.targetPoint.x,y:t.targetPoint.y};return r},n.prototype.refreshConnectorSegments=function(t,e,i,r){var h,c,f,p,g,y,S,b,M,w,C,s=e.sourceID,o=e.targetID,a=e.sourcePortID,l=e.targetPortID;if(function Jre(n,t){var e=0;return n.constraints&qe.LineRouting?e=n.constraints&qe.LineRouting:n.constraints&qe.InheritLineRouting&&(e=t.constraints&nt.LineRouting),e}(e,t)||r){this.startNode=t.nameTable[""+s],this.targetNode=t.nameTable[""+o],this.intermediatePoints=[],this.startArray=[],this.targetGridCollection=[],this.sourceGridCollection=[],this.startGrid=void 0,this.targetGrid=void 0;for(var D=0;D0;){var L=this.startArray.pop();if(L){for(D=0;D1&&(e.segments=[]),this.updateConnectorSegments(t,this.intermediatePoints,this.gridCollection,e,i)){this.considerWalkable=[];break e}this.targetGridCollection.splice(this.targetGridCollection.indexOf(O),1),L=this.startArray.pop()}}L&&this.findPath(L)}}}},n.prototype.checkChildNodes=function(t,e){var i=!1,r=!1;if(t.nodeId.length>=1&&!e)for(var s=0;s1&&this.targetGridCollection[0].nodeId.length>1)for(var c=0;c<=1;c++){for(var d=this.targetGridCollection[parseInt(c.toString(),10)].gridX,u=this.targetGridCollection[parseInt(c.toString(),10)].gridY,f=this.targetGridCollection[parseInt(c.toString(),10)].nodeId,p=void 0,g=0;g=e.right&&t.top<=e.top&&t.bottom>=e.bottom},n.prototype.getEndvalue=function(t,e){return this.gridCollection[t.gridX][t.gridY].walkable?t:"left"===e?this.getEndvalue(this.gridCollection[t.gridX-1][t.gridY],e):"right"===e?this.getEndvalue(this.gridCollection[t.gridX+1][t.gridY],e):"top"===e?this.getEndvalue(this.gridCollection[t.gridX][t.gridY-1],e):"bottom"===e?this.getEndvalue(this.gridCollection[t.gridX][t.gridY+1],e):t},n.prototype.changeValue=function(t,e,i){t.walkable||this.considerWalkable.push(t);for(var r,s=0;s<=e;s++)"left"===i?r=this.gridCollection[t.gridX-s][t.gridY]:"right"===i?r=this.gridCollection[t.gridX+s][t.gridY]:"top"===i?r=this.gridCollection[t.gridX][t.gridY-s]:"bottom"===i&&(r=this.gridCollection[t.gridX][t.gridY+s]),r.walkable||this.considerWalkable.push(r)},n.prototype.getIntermediatePoints=function(t){var e;for(this.intermediatePoints=[];t;)this.intermediatePoints.push({x:t.gridX,y:t.gridY}),t=t.parent;this.intermediatePoints.reverse(),this.intermediatePoints.length>=1&&void 0!==this.intermediatePoints[0]&&void 0!==this.intermediatePoints[1]&&(this.intermediatePoints[0].x===this.intermediatePoints[1].x?this.intermediatePoints[0].yi.y&&o.y>s.y){for(var a=i.xi.x&&o.x>s.x)){for(var u=i.y=1&&u.length>1&&(g=u[u.length-2].x!==u[u.length-1].x?u[u.length-2].x>u[u.length-1].x?"Left":"Right":u[u.length-2].y>u[u.length-1].y?"Top":"Bottom"),M>=2&&v===g&&u.length>1&&u.splice(u.length-2,1),v=g);if(u&&u.length>1){for(var w=0;wD.x?S.bounds.middleLeft:S.bounds.middleRight),w===u.length-2&&""===r.targetPortID&&y&&(l=C.x>D.x?y.bounds.middleRight:y.bounds.middleLeft),0===w&&b&&(C.x=b.x,C.y=D.y=b.y,b=qa(r,0,b,Ol(S.bounds,_n(C.x>D.x?"Left":"Right")),!1),C.x=b.x),w===u.length-2&&l&&(w>0&&r.targetDecorator&&l.x-D.x<0&&Math.abs(l.x-C.x)0&&r.targetDecorator&&l.x-D.x>0&&Math.abs(l.x-C.x)D.y?S.bounds.topCenter:S.bounds.bottomCenter),w===u.length-2&&""===r.targetPortID&&y&&(l=C.y>D.y?y.bounds.bottomCenter:y.bounds.topCenter),0===w&&b&&(C.y=b.y,C.x=D.x=b.x,b=qa(r,0,b,Ol(S.bounds,_n(C.y>D.y?"Top":"Bottom")),!1),C.y=b.y),w===u.length-2&&l&&(w>0&&r.targetDecorator&&l.y-D.y<0&&Math.abs(l.y-C.y)0&&r.targetDecorator&&l.y-D.y>0&&Math.abs(l.y-C.y)D.x?(f="Left",p=C.x-D.x):(f="Right",p=D.x-C.x):C.y>D.y?(f="Top",p=C.y-D.y):(f="Bottom",p=D.y-C.y),o.push({type:"Orthogonal",length:p,direction:f})}}if(o&&o.length>0){var L=o[o.length-1];if(1===o.length&&(L.length-=20),L.length<10&&2===o.length&&(o.pop(),o.length>0&&(o[0].length-=20,L=o[0])),r.targetDecorator&&("Top"===L.direction||"Bottom"===L.direction)&&L.length>r.targetDecorator.height+1||("Right"===L.direction||"Left"===L.direction)&&L.length>r.targetDecorator.width+1)return r.segments=o,s&&t.connectorPropertyChange(r,{},{type:"Orthogonal",segments:o}),!0}return!1},n.prototype.findPath=function(t){for(var e,i=[],r=this.findNearestNeigbours(t,this.gridCollection,!0),s=0;sl)&&(e.x!==t.gridX||e.y!==t.gridY)&&(i.push(e),o.previousDistance=l,o.afterDistance=o.afterDistance||this.manhattan(Math.abs(e.x-this.targetGrid.gridX),Math.abs(e.y-this.targetGrid.gridY)),o.totalDistance=o.previousDistance+o.afterDistance,o.parent=t)}if(i.length>0)for(s=0;st?i*t+e:i*e+t},n.prototype.manhattan=function(t,e){return t+e},n.prototype.findNearestNeigbours=function(t,e,i){var r=[],s=t.parent;if(s){var o=(t.gridX-s.gridX)/Math.max(Math.abs(t.gridX-s.gridX),1),a=(t.gridY-s.gridY)/Math.max(Math.abs(t.gridY-s.gridY),1);0!==o?(this.isWalkable(t.gridX,t.gridY-1,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX][t.gridY-1])&&r.push(e[t.gridX][t.gridY-1]),this.isWalkable(t.gridX,t.gridY+1,!0)&&this.sourceGridCollection.indexOf(e[t.gridX][t.gridY+1])&&r.push(e[t.gridX][t.gridY+1]),this.isWalkable(t.gridX+o,t.gridY,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX+o][t.gridY])&&r.push(e[t.gridX+o][t.gridY])):0!==a&&(this.isWalkable(t.gridX-1,t.gridY,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX-1][t.gridY])&&r.push(e[t.gridX-1][t.gridY]),this.isWalkable(t.gridX+1,t.gridY,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX+1][t.gridY])&&r.push(e[t.gridX+1][t.gridY]),this.isWalkable(t.gridX,t.gridY+a,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX][t.gridY+a])&&r.push(e[t.gridX][t.gridY+a]))}else this.neigbour(t,"top",r,i),this.neigbour(t,"right",r,i),this.neigbour(t,"bottom",r,i),this.neigbour(t,"left",r,i);return r},n.prototype.neigbour=function(t,e,i,r){for(var o,s=1;s>0;){var a="top"===e||"bottom"===e?t.gridX:"left"===e?t.gridX-s:t.gridX+s,l="right"===e||"left"===e?t.gridY:"top"===e?t.gridY-s:t.gridY+s;if((o=this.gridCollection[parseInt(a.toString(),10)][parseInt(l.toString(),10)])&&(r&&-1===this.sourceGridCollection.indexOf(o)||!r&&-1===this.targetGridCollection.indexOf(o)))return i&&this.isWalkable(a,l)&&i.push(o),s;if(!(a>0&&l>0))break;s++}return null},n.prototype.resetGridColl=function(t,e,i){for(var s,r=1;r>0;){var o="top"===e||"bottom"===e?t.gridX:"left"===e?t.gridX-r:t.gridX+r,a="right"===e||"left"===e?t.gridY:"top"===e?t.gridY-r:t.gridY+r;if((s=this.gridCollection[parseInt(o.toString(),10)][parseInt(a.toString(),10)])&&(i&&-1===this.sourceGridCollection.indexOf(s)||!i&&-1===this.targetGridCollection.indexOf(s))){if(this.isWalkable(o,a))break;var l=this.gridCollection[parseInt(o.toString(),10)][parseInt(a.toString(),10)];this.considerWalkable.push(l)}if(!(o>0&&a>0))break;"top"===e||"left"===e?r--:r++}return null},n.prototype.isWalkable=function(t,e,i){if(t>=0&&t=0&&e0?1:-1,this.isWalkable(h,c-1)&&!this.isWalkable(h-a,c-1)||this.isWalkable(h,c+1)&&!this.isWalkable(h-a,c+1)))return{x:t,y:e};if(0!==l){if(l=l>0?1:-1,this.isWalkable(h-1,c)&&!this.isWalkable(h-1,c-l)||this.isWalkable(h+1,c)&&!this.isWalkable(h+1,c-l))return{x:t,y:e};if(this.findIntermediatePoints(h+1,c,h,c,s,o)||this.findIntermediatePoints(h-1,c,h,c,s,o))return{x:t,y:e}}return this.findIntermediatePoints(h+a,c+l,h,c,s,o)},n.prototype.destroy=function(){},n.prototype.getModuleName=function(){return"LineRouting"},n}(),aae=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),hae=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return aae(t,n),function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);r>3&&s&&Object.defineProperty(t,e,s)}([I(!0)],t.prototype,"inversedAlignment",void 0),t}(Ee),cae=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Oe=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},xT=function(n,t,e,i){return new(e||(e=Promise))(function(r,s){function o(h){try{l(i.next(h))}catch(c){s(c)}}function a(h){try{l(i.throw(h))}catch(c){s(c)}}function l(h){h.done?r(h.value):new e(function(c){c(h.value)}).then(o,a)}l((i=i.apply(n,t||[])).next())})},TT=function(n,t){var i,r,s,o,e={label:0,sent:function(){if(1&s[0])throw s[1];return s[1]},trys:[],ops:[]};return o={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function a(h){return function(c){return function l(h){if(i)throw new TypeError("Generator is already executing.");for(;e;)try{if(i=1,r&&(s=2&h[0]?r.return:h[0]?r.throw||((s=r.return)&&s.call(r),0):r.next)&&!(s=s.call(r,h[1])).done)return s;switch(r=0,s&&(h=[2&h[0],s.value]),h[0]){case 0:case 1:s=h;break;case 4:return e.label++,{value:h[1],done:!1};case 5:e.label++,r=h[1],h=[0];continue;case 7:h=e.ops.pop(),e.trys.pop();continue;default:if(!(s=(s=e.trys).length>0&&s[s.length-1])&&(6===h[0]||2===h[0])){e=0;continue}if(3===h[0]&&(!s||h[1]>s[0]&&h[1]0&&((!s.style||!s.style.fill)&&(o.style.fill="transparent"),(!s.style||!s.style.strokeColor)&&(o.style.strokeColor="transparent")),s.shape&&"UmlActivity"===s.shape.type&&rb(s,o),s.shape&&"SwimLane"===s.shape.type&&fF(s,o),r.nodeDefaults&&Ro(o,s,r.nodeDefaults),r.updateAnnotationText(o.annotations);if(e&&e.connectors)for(a=0;e&&e.connectors&&a0&&0===i.nodes.length)this.clearCollection(),a=!0;else{for(var g=0,v=Object.keys(e.nodes);g0&&0===i.connectors.length)this.clearCollection(!0),a=!0;else{for(var C=0,D=Object.keys(e.connectors);C0){this.renderSelector(!0);break}if(e.selectedItems.constraints){this.renderSelector(!0);break}break;case"snapSettings":this.updateSnapSettings(e);break;case"commandManager":this.initCommands();break;case"layout":o=!0;break;case"segmentThumbShape":this.updateSelector();break;case"dataSourceSettings":this.clear(),"None"===this.layout.type?a=!0:(this.initObjects(),o=!0);break;case"tooltip":l3(this);break;case"rulerSettings":this.updateRulerSettings(e);break;case"layers":this.updateLayer(e);break;case"scrollSettings":this.scrollActions|=da.PropertyChange,this.updateScrollSettings(e),this.scrollActions&=~da.PropertyChange,this.scrollSettings.horizontalOffset=-this.scroller.horizontalOffset||0,this.scrollSettings.verticalOffset=-this.scroller.verticalOffset||0;break;case"locale":e.locale!==i.locale&&(this.realActions|=$i.PreventDataInit,n.prototype.refresh.call(this),this.realActions&=~$i.PreventDataInit);break;case"contextMenuSettings":if(void 0!==e.contextMenuSettings.showCustomMenuOnly&&(this.contextMenuSettings.showCustomMenuOnly=e.contextMenuSettings.showCustomMenuOnly),void 0!==e.contextMenuSettings.show&&(this.contextMenuSettings.show=e.contextMenuSettings.show),e.contextMenuSettings.items){for(var A=e.contextMenuSettings.items,x=0,P=Object.keys(A);x0){for(var N=[],T=O.ports.length-1;T>=0;T--)"LineDistribution"===O.ports[parseInt(T.toString(),10)].id.split("_")[1]&&N.push(O.ports[parseInt(T.toString(),10)]);this.removePorts(O,N)}}for(T=0;T0)for(var ue=0,fe=Object.keys(e.nodes);ue0)for(var De=0,xe=Object.keys(e.connectors);De=0;o--)this.commandHandler.expandNode(r[parseInt(o.toString(),10)],this,0!==o);this.canLayout&&this.doLayout(),this.lineRoutingModule?this.connectors.sourceID!==this.connectors.targetID&&this.lineRoutingModule.lineRouting(this):this.constraints&nt.LineRouting&&console.warn('[WARNING] :: Module "LineRouting" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),this.validatePageSize(),this.renderPageBreaks(),this.diagramRenderer.renderSvgGridlines(this.snapSettings,Ud(this.element.id),this.scroller.transform,this.rulerSettings,this.hRuler,this.vRuler),this.commandHandler.initSelectorWrapper(),this.notify("initial-load",{}),this.trigger("load"),this.scroller.setSize(),this.scroller.updateScrollOffsets(),this.isRefreshed||this.refreshDiagramLayer(),(this.scrollSettings.verticalOffset>0||this.scrollSettings.horizontalOffset>0)&&this.updateScrollOffset(),X.isDevice&&(this.tool=ri.ZoomPan|ri.SingleSelect),this.notify("initial-end",{}),this.isProtectedOnChange=!1,this.tooltipObject=l3(this),this.diagramActions=ee.Render,this.initCommands();var a=document.getElementsByClassName(this.element.id+"_hiddenUserHandleTemplate");(function Noe(n,t,e,i){var r,s,o,a,l,d=document.getElementById(i).ej2_instances[0];if(n&&t){r=GF(n);for(var u=0,f=e.userHandles;u0;)e[0].parentNode.removeChild(e[0]);var i=document.getElementById(this.element.id+"content");i&&this.element.removeChild(i);var r="measureElement";if(window[""+r]){window[""+r].usageCount-=1;var s="measureElementCount";window[""+s]--,0===window[""+s]&&(window[""+r].parentNode.removeChild(window[""+r]),window[""+r]=null)}}window.domTable={};for(var a=0;a1&&(this.callBlazorModel=!1,this.insertBlazorDiagramObjects(this.selectedItems),this.commandHandler.group(),this.callBlazorModel=!0,this.commandHandler.getBlazorOldValues())},t.prototype.unGroup=function(){this.callBlazorModel=!1,this.insertBlazorDiagramObjects(this.selectedItems),this.commandHandler.unGroup(),this.callBlazorModel=!0,this.commandHandler.getBlazorOldValues()},t.prototype.sendToBack=function(){this.commandHandler.sendToBack()},t.prototype.setActiveLayer=function(e){var i=this.commandHandler.getLayer(e);this.activeLayer=i},t.prototype.addLayer=function(e,i){this.commandHandler.addLayer(e,i)},t.prototype.removeLayer=function(e){this.commandHandler.removeLayer(e,ce())},t.prototype.moveObjects=function(e,i){$(this.layers),this.enableServerDataBinding(!1),this.commandHandler.moveObjects(e,i)},t.prototype.layerObjectUpdate=function(){},t.prototype.sendLayerBackward=function(e){this.layerObjectUpdate(),this.commandHandler.sendLayerBackward(e)},t.prototype.bringLayerForward=function(e){this.layerObjectUpdate(),this.commandHandler.bringLayerForward(e)},t.prototype.cloneLayer=function(e){this.commandHandler.cloneLayer(e)},t.prototype.bringToFront=function(){this.commandHandler.bringToFront()},t.prototype.moveForward=function(){this.commandHandler.sendForward()},t.prototype.sendBackward=function(){this.commandHandler.sendBackward()},t.prototype.getObject=function(e){return this.nameTable[""+e]},t.prototype.getNodeObject=function(e){return $(this.nameTable[""+e])},t.prototype.getConnectorObject=function(e){return $(this.nameTable[""+e])},t.prototype.getActiveLayer=function(){return this.activeLayer},t.prototype.nudgeCommand=function(e,i,r){if("object"!=typeof e&&(this.selectedItems.nodes.length||this.selectedItems.connectors.length)>0){var s=void 0;i.type&&"KEYDOWN"===i.type&&(s=i.type),this.nudge(e,void 0,void 0,s)}},t.prototype.nudge=function(e,i,r,s){var o=0,a=0;"Left"===e||"Right"===e?o=("Left"===e?-1:1)*(i||1):a=("Up"===e?-1:1)*(r||1),"KEYDOWN"===s&&(o*=5,a*=5);var h=this.selectedItems,c=this.selectedItems.wrapper.children[0];if(c instanceof ai)this.commandHandler.labelDrag(h.nodes[0],c,o,a);else{var d=$(this.selectedItems);this.protectPropertyChange(!0),this.drag(h,o,a),this.protectPropertyChange(!1);var u={type:"PositionChanged",redoObject:$(this.selectedItems),undoObject:d,category:"Internal"};this.addHistoryEntry(u)}this.refreshCanvasLayers()},t.prototype.insertBlazorDiagramObjects=function(e){},t.prototype.drag=function(e,i,r){if(this.insertBlazorDiagramObjects(e),!(this.bpmnModule&&e instanceof te&&this.bpmnModule.updateAnnotationDrag(e,this,i,r))){if(e instanceof ei){if(this.preventConnectorsUpdate=!0,e.nodes&&e.nodes.length){for(var o=0,a=e.nodes;o0&&o.nodes[0].children){this.fromUndo||(this.rotateUsingButton=!0);for(var h=this.commandHandler.getAllDescendants(o.nodes[0],[]),c=0;c0&&o.nodes[0].children){var g={type:"RotationChanged",redoObject:$(e),undoObject:$(o),category:"Internal",childTable:a};this.commandHandler.addHistoryEntry(g),this.commandHandler.updateSelector()}return u},t.prototype.dragSourceEnd=function(e,i,r){this.insertBlazorDiagramObjects(e),this.commandHandler.dragSourceEnd(e,i,r),this.callBlazorModel&&this.commandHandler.getBlazorOldValues()},t.prototype.dragTargetEnd=function(e,i,r){this.insertBlazorDiagramObjects(e),this.commandHandler.dragTargetEnd(e,i,r),this.callBlazorModel&&this.commandHandler.getBlazorOldValues()},t.prototype.findObjectsUnderMouse=function(e,i){return this.eventHandler.findObjectsUnderMouse(e,i)},t.prototype.findObjectUnderMouse=function(e,i,r){return this.eventHandler.findObjectUnderMouse(e,i,r)},t.prototype.findTargetObjectUnderMouse=function(e,i,r,s,o){return this.eventHandler.findTargetUnderMouse(e,i,r,s,o)},t.prototype.findElementUnderMouse=function(e,i,r,s){return this.eventHandler.findElementUnderMouse(e,i,r,s)},t.prototype.findActionToBeDone=function(e,i,r,s){return this.eventHandler.findActionToBeDone(e,i,r,s)},t.prototype.updateConnectorPort=function(e){if(e.ports.length)for(var i=void 0,r=0,s=e.ports;r=0;s--)if(i.push(r[parseInt(s.toString(),10)]),i.length>this.historyManager.stackLimit)return i}else i=r;return i},t.prototype.getEdges=function(e){return e.outEdge?this.nameTable[e.id].outEdges:this.nameTable[e.id].inEdges},t.prototype.getParentId=function(e){return this.nameTable[""+e].parentId},t.prototype.addConnector=function(e){return this.add(e)},t.prototype.UpdateBlazorDiagramModelCollection=function(e,i,r,s){},t.prototype.UpdateBlazorDiagramModel=function(e,i,r,s){},t.prototype.UpdateBlazorLabelOrPortObjects=function(e,i,r,s){},t.prototype.addBlazorDiagramObjects=function(){},t.prototype.removeNodeEdges=function(e,i,r){var s=this.nameTable[""+e],o=r?s.outEdges:s.inEdges;if(o.length>0)for(var a=0;a0)){for(var c=0;c0))}this.removePortEdges(l,a.element.sourcePortID,a.element.id,h)}a.element.targetID&&this.removeNodeEdges(a.element.targetID,a.element.id,!1)}}this.diagramActions=this.diagramActions|ee.PublicMethod,e.id=e.id||Qe();var u=this.activeLayer;if(!a.cancel&&u&&!u.lock){if(u.objects.indexOf(e.id)<0&&!u.lock&&(u.visible||(u.visible=!0,this.dataBind()),u.objects.push(e.id)),ps(e)===de)(r=new de(this,"connectors",e,!0)).status="New",this.nameTable[r.targetID]&&"TextAnnotation"===this.nameTable[r.targetID].shape.shape&&(r.isBpmnAnnotationConnector=!0,r.constraints=r.constraints&~qe.Delete),Ro(r,e,this.connectorDefaults),this.connectors.push(r),this.initObject(r),!1===e.visible&&this.updateElementVisibility(r.wrapper,r,e.visible),this.updateEdges(r),this.insertBlazorConnector(r);else{if(Ro(r=new te(this,"nodes",e,!0),e,this.nodeDefaults),r.parentId=e.parentId?e.parentId:r.parentId,r.umlIndex=e.umlIndex,r.status="New",(o="TextAnnotation"===r.shape.shape)&&!e.isTextAnnotationCopied&&(r.inEdges=e.inEdges?e.inEdges:r.inEdges),this.nodes.push(r),this.initObject(r,u,void 0,i),o&&this.bpmnModule)for(c=0;c-1&&e.parentId&&this.nameTable[e.parentId]&&"UmlClassifier"===this.nameTable[e.parentId].shape.type){var g=this.nameTable[e.parentId];g.children.splice(r.umlIndex,0,r.id),g.wrapper.children.splice(r.umlIndex,0,r.wrapper),g.wrapper.measure(new me),g.wrapper.arrange(g.wrapper.desiredSize),this.updateDiagramObject(g)}}if(a={element:r,cause:this.diagramActions,diagramAction:this.getDiagramAction(this.diagramActions),state:"Changed",type:"Addition",cancel:!1},this.parentObject&&(a.parentId=this.parentObject.id),"helper"!==e.id&&!(this.diagramActions&ee.PreventCollectionChangeOnDragOver)&&this.triggerEvent(Ce.collectionChange,a),!(this.diagramActions&ee.UndoRedo||this.diagramActions&ee.Group||this.diagramActions&ee.PreventHistory)){var v={type:"CollectionChanged",changeType:"Insert",undoObject:$(e),redoObject:$(e),category:"Internal"};this.addHistoryEntry(v)}this.parentObject=void 0,"SVG"===this.mode&&(this.updateSvgNodes(r),this.updateTextElementValue(r),this.updateDiagramObject(r),o&&this.updateDiagramObject(this.nameTable[r.inEdges[0]]),r.shape.activity&&r.shape.activity.subProcess.processes&&r.shape.activity.subProcess.processes.length&&this.updateProcesses(r),this.updateBridging())}}if(this.protectPropertyChange(s),this.resetDiagramActions(ee.PublicMethod),r&&this.layers.length>1&&this.moveNode(r),this.views)for(var S=0,b=this.views;S=0;l--)this.moveSvgNode(a[parseInt(l.toString(),10)])}for(var h=0,c=i;h=0;o--)r[parseInt(o.toString(),10)]===e.id&&r.splice(o,1);for(var a=0;s.ports&&a=0;s--)if(i=this.nameTable[r[parseInt(s.toString(),10)]])if(this.connectorTable[i.id]=$(i),i.isBpmnAnnotationConnector){var o=this.nameTable[i.targetID];this.removeObjectsFromLayer(i);var a=this.connectors.indexOf(i);-1!==a&&this.connectors.splice(a,1),this.removeElements(i),this.removeFromAQuad(i),delete this.nameTable[i.id];var l=this.nameTable[i.sourceID];if(l){var h=l.outEdges.indexOf(i.id);-1!==h&&l.outEdges.splice(h,1)}e.id!==i.targetID&&this.remove(o)}else this.remove(i)},t.prototype.removeObjectsFromLayer=function(e){if(e.children)for(var i=0;i-1&&(_r(this,e)&&this.unSelect(e),this.layers[parseInt(s.toString(),10)].objects.splice(a,1),delete this.layers[parseInt(s.toString(),10)].zIndexTable[this.nameTable[e.id].zIndex])},t.prototype.removeElements=function(e){if("SVG"===this.mode||"Canvas"===this.mode&&"Native"===e.shape.type){var i=xt(e.id+"_groupElement",this.element.id),r=e;if(r.ports&&r.ports.length>0)for(var s=0;s0){l[parseInt(s.toString(),10)].id.indexOf("icon_content")>0&&"SVG"===this.mode&&((h=xt(l[parseInt(s.toString(),10)].id+"_shape_groupElement",this.element.id))&&h.parentNode.removeChild(h),(h=xt(l[parseInt(s.toString(),10)].id+"_rect_groupElement",this.element.id))&&h.parentNode.removeChild(h));for(var c=0,d=this.views;c=0;o--)a.children[parseInt(o.toString(),10)].children&&(l=n.nameTable[a.children[parseInt(o.toString(),10)].id])&&(l.isLane?Jv(n,l):(n.removeDependentConnector(l),n.diagramActions|=ee.PreventHistory,l.constraints&ie.Delete?n.remove(l):q3(n,l,{},!1),n.diagramActions&=~ee.PreventHistory));a&&(i=n.nameTable[a.id])&&Jv(n,i)}}(this,e),!(this.diagramActions&ee.UndoRedo||this.diagramActions&ee.PreventHistory)&&(e instanceof te||e instanceof de)){var o={type:"CollectionChanged",changeType:"Remove",undoObject:$(e),redoObject:$(e),category:"Internal"};this.diagramActions&ee.Clear||e.children&&!e.isLane&&!e.isPhase&&e.children.length>0&&this.undoRedoModule&&"None"===this.layout.type&&(this.historyManager.startGroupAction(),s=!0),(e instanceof te||e instanceof de)&&this.deleteDependentConnector&&this.removeDependentConnector(e),!e.isLane&&!e.isPhase&&!(this.diagramActions&ee.Clear)&&!this.isStackChild(e)&&this.addHistoryEntry(o)}"TextAnnotation"===e.shape.shape&&this.removeDependentConnector(e),e.children&&!e.isLane&&!e.isPhase&&(!(this.diagramActions&ee.UndoRedo)||!ce())&&this.deleteGroup(e),e.parentId&&(this.deleteChild(e,void 0,!0),this.nameTable[e.parentId]&&"UmlClassifier"===this.nameTable[e.parentId].shape.type&&(this.updateDiagramObject(this.nameTable[e.parentId]),this.updateConnectorEdges(this.nameTable[e.parentId])));var a=void 0;this.diagramActions=this.diagramActions|ee.PublicMethod;var l=this.nameTable[e.id];if(l instanceof te?("Bpmn"===l.shape.type&&this.bpmnModule&&this.bpmnModule.removeBpmnProcesses(l,this),(l.isLane||l.isPhase||"SwimLane"===l.shape.type)&&(h=l.isLane||l.isPhase?this.nameTable[l.parentId]:this.nameTable[l.id],l.isLane?Q3(this,l,h):l.isPhase&&G3(this,l,h)),-1!==(a=this.nodes.indexOf(l))&&(this.crudDeleteNodes.push(this.nameTable[l.id]),this.nodes.splice(a,1),this.updateNodeEdges(l))):(-1!==(a=this.connectors.indexOf(l))&&(this.crudDeleteNodes.push(this.nameTable[l.id]),this.connectors.splice(a,1)),this.updateEdges(l),this.spliceConnectorEdges(e,!0),this.spliceConnectorEdges(e,!1)),!this.isServerUpdate&&!(this.blazorActions&on.GroupClipboardInProcess)&&this.commandHandler.getBlazorOldValues(),s&&this.historyManager.endGroupAction(),_r(this,l)&&this.unSelect(l),!l.isPhase){if(this.removeObjectsFromLayer(e),this.currentDrawingObject&&(this.currentDrawingObject.wrapper=void 0),delete this.nameTable[e.id],i.length>0&&i[0].id===l.id&&l.parentId){var h,d=this.nameTable[l.parentId];d&&d.isLane&&"SwimLane"===this.nameTable[d.parentId].shape.type&&Y3(this,h=this.nameTable[d.parentId],d,l)}this.removeElements(l),this.updateBridging(),"SVG"!==this.mode&&this.refreshDiagramLayer(),this.diagramActions&ee.Clear||(this.removeFromAQuad(l),r={element:e,cause:this.diagramActions,diagramAction:this.getDiagramAction(this.diagramActions),state:"Changed",type:"Removal",cancel:!1},"helper"!==e.id&&this.triggerEvent(Ce.collectionChange,r),this.resetTool())}}}else if(i.length>0){this.undoRedoModule&&(this.historyManager.startGroupAction(),this.blazorActions|=on.GroupingInProgress,s=!0);for(var u=0;u=p.wrapper.bounds.width&&"Horizontal"===p.shape.orientation||this.selectedItems.wrapper.bounds.y<=p.wrapper.bounds.y+g&&this.selectedItems.wrapper.bounds.height>=p.wrapper.bounds.height-g&&"Vertical"===p.shape.orientation)&&(kI(p)||p.shape.lanes.length>1)&&this.remove(i[parseInt(u.toString(),10)])}}else this.remove(i[parseInt(u.toString(),10)])}s&&(this.blazorActions&=~on.GroupingInProgress,this.isServerUpdate=!0,this.commandHandler.getBlazorOldValues(),this.UpdateBlazorDiagramModelCollection(void 0,void 0,void 0,!0),this.historyManager.endGroupAction(),this.isServerUpdate=!1),this.clearSelection()}e&&(kI(e)||this.diagramActions&ee.Clear)||this.diagramActions&ee.UndoRedo||this.diagramActions&ee.PreventHistory||!(e instanceof te||e instanceof de)||(o={type:"ConnectionChanged",undoObject:$(e),redoObject:$(e),category:"Internal"},!e.isLane&&!e.isPhase&&!(this.diagramActions&ee.Clear)&&!this.isStackChild(e)&&this.addHistoryEntry(o)),this.tooltipObject.close()},t.prototype.isStackChild=function(e){var i,r=this.nameTable[e.parentId];if(e&&e.parentId&&r.container&&"Stack"===r.container.type&&"UmlClassifier"!==this.nameTable[e.parentId].shape.type){i=!0;var s={sourceIndex:r.wrapper.children.indexOf(e.wrapper),source:e,target:void 0,targetIndex:void 0};this.diagramActions&ee.UndoRedo||this.addHistoryEntry({type:"StackChildPositionChanged",redoObject:{sourceIndex:void 0,source:e,target:void 0,targetIndex:void 0},undoObject:s,category:"Internal"})}return i},t.prototype.deleteChild=function(e,i,r){var s;if(s="string"==typeof e?e:e.id,(i=i?this.nameTable[i.id]:this.nameTable[e.parentId])&&i.children){for(var o=0;o=0;i--)this.removeLayer(this.layers[parseInt(i.toString(),10)].id);this.commandHandler.addLayer({id:"default_layer",visible:!0,lock:!1,objects:[],zIndex:0,objectZIndex:-1,zIndexTable:{}},null,!0),this.setActiveLayer(this.layers[this.layers.length-1].id)},t.prototype.clearObjects=function(e){var i=[];i=e||(i=i.concat(this.nodes)).concat(this.connectors),this.diagramActions=this.diagramActions|ee.Clear;for(var r=0,s=i;r0||"Text"===e.shape.type))if("Text"===e.shape.type)i=e.wrapper.children[0].id.split("_")[1];else for(var p=e.annotations.length-1;p>=0;p--)e.annotations[parseInt(p.toString(),10)].visibility&&(i=e.annotations[parseInt(p.toString(),10)].id);i&&(u=this.getWrapper(e.wrapper,i))}if(e&&u&&!(u instanceof es)&&(!function sne(n,t){return"Text"===t.shape.type?t.constraints&ie.ReadOnly:t.constraints&(t instanceof de?qe.ReadOnly:ie.ReadOnly)?n.constraints&Nr.InheritReadOnly?1:0:n.constraints&Nr.ReadOnly?1:0}(u,e)||f)){var g=u.style,v=void 0;v=90>(v=u.bounds.width50?50:e.width,u.style.fontSize)),e.parentId&&"UmlClassifier"===this.nameTable[e.parentId].shape.type?(l.width=e.wrapper.bounds.width-20,c=(e.wrapper.bounds.center.x+r.tx)*r.scale-l.width/2*s-2.5,d=(e.wrapper.bounds.center.y+r.ty)*r.scale-l.height/2*s-3,u.style.textAlign="Left"):(l.width=Math.max(l.width,50),c=(u.bounds.center.x+r.tx)*r.scale-l.width/2*s-2.5,d=(u.bounds.center.y+r.ty)*r.scale-l.height/2*s-3),Ho(y,{id:this.element.id+"_editTextBoxDiv",style:"position: absolute;left:"+c+"px;top:"+d+"px;width:"+(l.width+1)*s+"px;height:"+l.height*s+"px; containerName:"+e.id+";"}),Ho(S,{"aria-label":a,id:this.element.id+"_editBox",style:"width:"+(l.width+1)*s+"px;height:"+l.height*s+"px;resize: none;outline: none;overflow: hidden;;font-family:"+g.fontFamily+";font-size:"+g.fontSize*s+"px;text-align:"+u.style.textAlign.toLocaleLowerCase()+";",class:"e-diagram-text-edit"}),S.style.fontWeight=g.bold?"bold":"",S.style.fontStyle=g.italic?"italic":"",S.style.lineHeight=(1.2*g.fontSize+"px;").toString(),S.style.textDecoration=g.textDecoration?g.textDecoration:"",this.activeLabel.parentId=e.id,this.activeLabel.id=i,u.visible=!1,this.updateDiagramObject(e),this.diagramActions=this.diagramActions|ee.TextEdit,this.isTriggerEvent||(E.add(S,"input",this.eventHandler.inputChange,this.eventHandler),E.add(S,"focusout",this.focusOutEdit,this),S.select())}}}},t.prototype.updateConnectorfixedUserHandles=function(e){if(e.fixedUserHandles.length)for(var i=void 0,r=0,s=e.fixedUserHandles;r0&&this.mindMapChartModule.updateLayout(o,this.nameTable,this.layout,l,this.dataSourceSettings.id,this.dataSourceSettings.root),e=!0;else if(this.radialTreeModule)this.radialTreeModule.updateLayout(o,this.nameTable,this.layout,l),e=!0;else if(this.symmetricalLayoutModule)this.symmetricalLayoutModule.maxIteration=this.layout.maxIteration,this.symmetricalLayoutModule.springLength=this.layout.springLength,this.symmetricalLayoutModule.springFactor=this.layout.springFactor,this.symmetricalLayoutModule.updateLayout(o,this.connectors,this.symmetricalLayoutModule,this.nameTable,this.layout,l),e=!0;else if(this.complexHierarchicalTreeModule){this.canDistribute(a,r)&&(this.lineDistributionModule.diagram=this,this.connectors.forEach(function(P){P.obstaclePointCollection=[]}));var c=this.complexHierarchicalTreeModule.getLayoutNodesCollection(this.nodes);c.length>0&&this.complexHierarchicalTreeModule.doLayout(c,this.nameTable,this.layout,l,this),e=!0,this.canDistribute(a,r)&&this.lineDistributionModule.initLineDistribution(this.layout,this)}else this.flowchartLayoutModule?(this.flowchartLayoutModule.updateLayout(this.nodes,this),e=!0):console.warn("[WARNING] :: Module "+("OrganizationalChart"===this.layout.type?"HierarchicalTree":this.layout.type)+" is not available in Diagram component! You either misspelled the module name or forgot to load it.");if(e){this.preventDiagramUpdate=!0;for(var u={},p=0,g=o;p0)for(var S=0;S0)for(var M=0;M0)for(var s=0,o=r.ports;s0&&function Rse(n){var t,e,i,r=[];for(t=0;t0&&y.connectors[w].bezierSettings&&y.connectors[w].bezierSettings.allowSegmentsReset&&(y.connectors[w].segments=[]);if(t.connectors=y.connectors||[],t.dataSourceSettings=y.dataSourceSettings||{},t.dataSourceSettings.doBinding=i,t.height=y.height||"100%",t.setNodeTemplate=r,t.getConnectorDefaults=v,t.getNodeDefaults=g,t.getCustomProperty=o,t.mode=y.mode||"SVG",y.nodes)for(w=0;w0)){var r=this.nodes.filter(function(a){return 0===a.inEdges.length})[0],s=this.convertMindmapToMermaid(r,0);i.push(s),this.updateTextDataSource(i,r.outEdges,1),e=(i=i.filter(function(a){return""!==a.trim()})).join("\n")}return e},t.prototype.updateTextDataSource=function(e,i,r){for(var s=0;s0&&this.updateTextDataSource(e,h,r+1),s++}},t.prototype.convertMindmapToMermaid=function(e,i){var r=e.id,o=" ".repeat(2*(i+1)),a=e.annotations.length>0?e.annotations[0].content.replace(/\n/g," "):"",l=o+a,h=o+r;if(e.shape&&"Basic"===e.shape.type){var c=e.shape;"Rectangle"===c.shape?l=h+"["+a+"]":"Ellipse"===c.shape?l=h+"(("+a+"))":"Hexagon"===c.shape&&(l=h+"{{"+a+"}}")}else if(e.shape&&"Flow"===e.shape.type)"Terminator"===e.shape.shape&&(l=h+"("+a+")");else if(e.shape&&"Path"===e.shape.type){var u=e.shape;u.data===this.bangShape?l=h+"))"+a+"((":u.data===this.cloudShape&&(l=h+")"+a+"(")}return l},t.prototype.saveFlowDiagramInMermaidFormat=function(){var e=this,i=[],r="graph TD\n",s={nodes:this.nodes,edges:this.connectors};return s.nodes.reduce(function(a,l){return a[l.id]=l.annotations.length?l.annotations[0].content:"",a},{}),s.edges.forEach(function(a){var l=a.sourceID,h=a.targetID,f=e.nameTable[""+h],p=e.getNodeShape(e.nameTable[""+l]),g=e.getNodeShape(f),v=a.annotations[0]&&""!==a.annotations[0].content?"|"+a.annotations[0].content+"|":"";-1===i.indexOf(l)?i.push(l):p="",-1===i.indexOf(h)?i.push(h):g="";var y=e.arrowType(a);r+=" "+l+p+" "+y+v+" "+h+g+"\n"}),s.nodes.forEach(function(a){r+=" style "+a.id+" fill:"+a.style.fill+",stroke:"+a.style.strokeColor+",stroke-width:"+a.style.strokeWidth+"px;\n"}),r},t.prototype.arrowType=function(e){var i=e.targetDecorator.shape;return e.style.opacity<1?"~~~":""!==e.style.strokeDashArray?"-.->":"Arrow"===i?e.style.strokeWidth>1?"==>":"--\x3e":"None"===i?"---":"--\x3e"},t.prototype.getNodeShape=function(e){var i=e.annotations.length>0?e.annotations[0].content:"",r=e.shape.shape;if(!r){var s=e.shape.data;return"M 0 0 A 1 1 0 0 0 7 0 A 1 1 0 0 0 0 0 M -1 0 A 1 1 0 0 0 8 0 A 1 1 0 0 0 -1 0"===s?"((("+i+")))":"M 0 0 L 1 -1 L 5 -1 L 6 0 L 0 0"===s?"[/"+i+"\\]":"M 0 1 L 0 6 C 2 7 4 7 6 6 L 6 1 C 5 0 1 0 0 1 C 1 2 5 2 6 1"===s?"[("+i+")]":"M 0 0 L 12 0 L 14 2 L 2 2 L 0 0"===s?"[\\"+i+"\\]":"M 0 0 L 5 0 L 4 1 L 1 1 L 0 0"===s?"[\\"+i+"/]":"M 0 0 L 2 -2 L 11 -2 L 13 0 L 11 2 L 2 2 L 0 0"===s?"{{"+i+"}}":">"+i+"]"}switch(r){case"Terminator":return"(["+i+"])";case"Process":default:return"["+i+"]";case"Decision":return"{"+i+"}";case"Parallelogram":return"[/"+i+"/]";case"Ellipse":return"(("+i+"))";case"PreDefinedProcess":return"[["+i+"]]"}},t.prototype.loadDiagramFromMermaid=function(e){this.layout&&"Flowchart"===this.layout.type&&this.flowchartLayoutModule?this.convertMermaidToFlowChart(e):this.layout&&"MindMap"===this.layout.type&&this.mindMapChartModule?this.convertMermaidToMindmap(e):console.warn('[WARNING] :: Module "FlowchartLayout" or "MindMap" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.countLeadingSpaces=function(e){for(var i=0,r=e.length;i0});this.clear(),this.mermaidNodeBaseCollection=[];var r=[],s={text:"",children:[],currentLevel:0,branch:"Left"},o=[],l=!1,h=!1,c=!1;if(i.length>0){for(var d=function(M){var w=i[parseInt(M.toString(),10)],C=0,D="",A=u.countLeadingSpaces(w),x=w.includes('"`');if(h=w.includes('`"'),c=(l=!!x||l)||c?c:0===A&&M>0,l&&h&&!x)return s.text+="\n"+w,l=!1,"continue";if(!x&&l)return s.text+="\n"+w,"continue";if(l=!h&&l,w.length>0&&(/\s/.test(w[0])&&M>0||0===A)){if(-1!==o.findIndex(function(B){return B.space===A.toString()}))for(var L=o.length-1;L>=0;L--){var O=o[parseInt(L.toString(),10)];if((N=parseFloat(O.space))>A)o.splice(L,1);else{if(N=0;L--){var N,T=o[parseInt(L.toString(),10)];if(!((N=parseFloat(T.space))>A)){var z=o[o.length-1];o.push({space:A.toString(),level:z.level+1});break}o.splice(L,1)}C=o[o.length-1].level}D=w.trim().replace(/^[+-]/,"")}var U={text:D,branch:void 0,children:[],currentLevel:0===M?0:C-1};if(r.length>0){for(;r.length>=C&&0!==r.length;)r.pop();r.length>0&&r[r.length-1].children.push(U)}r.push(U),s=U},u=this,f=0;f0){var c=h[h.length-1];c.arrowType=a[2],""!==a[3]&&(c.label&&c.label.some(function(d){return d.trim().length>0})?c.label.push(a[3]):(c.label=[],c.label[c.parentId.length-1]=a[3]))}h.filter(function(d){return d.parentId&&0===d.parentId.length}).forEach(function(d){d.parentId=null}),i=i.concat(h)}}this.createFlowChart(i),this.doLayout(),this.clearHistory()},t.prototype.createFlowChart=function(e){for(var i=[],r=0;r1)for(var h=0;h|---|--\s*.*?\s*-->|~~~|==>|===|==\s*.*?\s*==>|\s*-\.\s*->|\s*-\.\s*-|\s*-\.\s*.*?\s*\.\s*->|\s*-\..*?\.\s*->)(.*)$/);if(l){i=l[1].trim();var h=l[2].trim();r=l[3].trim();var d=h.match(/(-\.|\\-\\-|==|--|~~)(.*?)(\1>|\.->|==>|\\->|~~>)/),u=void 0,f="";o=null!==(u=d?{text:d[2].trim()||null,arrowType:d[1]+d[3]}:{text:null,arrowType:h}).text?u.text:"",s=(f=u.arrowType).includes("--\x3e")?"single-line-arrow":f.includes("---")?"single-line":f.includes("==>")?"double-line-arrow":f.includes("==")?"double-line":f.includes("~~~")?"wiggly-arrow":f.includes("-.->")||f.includes(".->")?"dotted-arrow":f.includes("-.-")||f.includes(".-")?"dotted":"single-line-arrow"}return[i,r,s,o]},t.prototype.parseStyle=function(e,i){if(e.startsWith("style")){var s=e.match(/^style\s+(\w+)\s+fill:([^,]+),stroke:([^,]+),stroke-width:(\d+)px;/);if(s){var c={id:s[1],fill:s[2],stroke:s[3],strokeWidth:parseInt(s[4],10)},d=i.filter(function(u){return u.id===c.id});d[0].color=c.fill,d[0].stroke=c.stroke,d[0].strokeWidth=c.strokeWidth}}},t.prototype.getNodeData=function(e,i,r){for(var s=[],o=null,a=null,l=0,h="",c=function(v){var y=e[parseInt(v.toString(),10)],S=d.splitNested(y);if(S[0].includes("|")){var b=S[0].match(/\|([^|]*)\|/);b&&(h=b[1]);var M=S[0].split("|");M.length>=3&&(S[0]=M[2].trim())}var w=S[0].trim();if(0===v?o=w:a=w,i.find(function(L){return L.id===w}))l++;else{var D=S.length>1?S[1]:S[0],A=d.getShape(D),x=D.replace(/[\\[\]\\(\\)\\{\\}\\{\\}\\/>]/g,"");s.push({id:w,name:x,shape:A,color:"white",parentId:[]})}},d=this,u=0;u"===h?0===s?(r.trim().length>0&&i.push(r.trim()),r=h,o=h,s++):(r+=h,s++):"]"===h||"}"===h||")"===h?1===s&&h===o?(i.push((r+=h).trim()),r="",s--):s>1?(r+=h,s--):r+=h:r+=h}return r.trim().length>0&&i.push(r.trim()),i},t.prototype.getShape=function(e){var i={};return e.startsWith("(((")?i={type:"Path",data:"M 0 0 A 1 1 0 0 0 7 0 A 1 1 0 0 0 0 0 M -1 0 A 1 1 0 0 0 8 0 A 1 1 0 0 0 -1 0"}:e.startsWith("((")?i={shape:"Ellipse",type:"Basic"}:e.startsWith("([")?i={type:"Flow",shape:"Terminator"}:e.startsWith("(")?i={type:"Flow",shape:"Process"}:e.startsWith("[[")?i={type:"Flow",shape:"PreDefinedProcess"}:e.startsWith("[/")?i=e.endsWith("/]")?{type:"Basic",shape:"Parallelogram"}:{type:"Path",data:"M 0 0 L 1 -1 L 5 -1 L 6 0 L 0 0"}:e.startsWith("[(")?i={type:"Path",data:"M 0 1 L 0 6 C 2 7 4 7 6 6 L 6 1 C 5 0 1 0 0 1 C 1 2 5 2 6 1"}:e.startsWith("[\\")?i=e.endsWith("\\]")?{type:"Path",data:"M 0 0 L 12 0 L 14 2 L 2 2 L 0 0"}:{type:"Path",data:"M 0 0 L 5 0 L 4 1 L 1 1 L 0 0"}:e.startsWith("[")?i={type:"Basic",shape:"Rectangle"}:e.startsWith("{{")?i={type:"Path",data:"M 0 0 L 2 -2 L 11 -2 L 13 0 L 11 2 L 2 2 L 0 0"}:e.startsWith("{")?i={type:"Flow",shape:"Decision"}:e.startsWith(">")&&(i={type:"Path",data:"M 0 0 L 8 0 L 8 2 L 0 2 L 2 1 L 0 0"}),i},t.prototype.getDiagramContent=function(e){return this.printandExportModule?this.printandExportModule.getDiagramContent(e):(console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),"")},t.prototype.exportImage=function(e,i){this.printandExportModule?this.printandExportModule.exportImages(e,i):console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.printImage=function(e,i){this.printandExportModule?(i.printOptions=!0,this.printandExportModule.exportImages(e,i)):console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.setStackLimit=function(e){this.undoRedoModule&&e&&(this.historyManager.stackLimit=e,this.undoRedoModule.applyLimit(this.historyManager.currentEntry,e,this,!0))},t.prototype.clearHistory=function(){this.undoRedoModule&&this.undoRedoModule.clearHistory(this)},t.prototype.getDiagramBounds=function(){if(this.printandExportModule){var e=this.printandExportModule.getDiagramBounds("",{});return e.width=e.width>this.scrollSettings.viewPortWidth?e.width+(e.x>0?e.x:0):this.scrollSettings.viewPortWidth,e.height=e.height>this.scrollSettings.viewPortHeight?e.height+(e.y>0?e.y:0):this.scrollSettings.viewPortHeight,e.x=e.x>0?0:e.x,e.y=e.y>0?0:e.y,e}return console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),new Ne},t.prototype.exportDiagram=function(e){return this.printandExportModule?this.printandExportModule.exportDiagram(e):(console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),"")},t.prototype.print=function(e){this.printandExportModule?this.printandExportModule.print(e):console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.addPorts=function(e,i){var s;this.protectPropertyChange(!0),e=this.nameTable[e.id]||e,i.length>1&&this.startGroupAction();for(var o=function(h){if(e.ports.some(function(y){return y.id===i[parseInt(h.toString(),10)].id}))return"continue";if(e instanceof te?(s=new Es(e,"ports",i[parseInt(h.toString(),10)],!0),e.ports.push(s)):e instanceof de&&(s=new Tc(e,"ports",i[parseInt(h.toString(),10)],!0),e.ports.push(s)),e.children)for(var c=e.wrapper,d=0;d1&&this.endGroupAction(),e.wrapper.measure(new me(e.width,e.height)),e.wrapper.arrange(e.wrapper.desiredSize),this.updateDiagramObject(e),this.protectPropertyChange(!1)},t.prototype.addConstraints=function(e,i){return e|i},t.prototype.removeConstraints=function(e,i){return e&~i},t.prototype.addNodeLabels=function(e,i){this.addLabels(e,i)},t.prototype.addConnectorLabels=function(e,i){this.addLabels(e,i)},t.prototype.addLabels=function(e,i){this.protectPropertyChange(!0);var s,r=(e=this.nameTable[e.id]||e).wrapper;i.length>1&&this.startGroupAction();for(var o=0;o1&&this.endGroupAction(),e.wrapper.measure(new me(r.width,r.height)),e.wrapper.arrange(r.desiredSize),this.updateDiagramObject(e),this.protectPropertyChange(!1),this.refreshCanvasLayers()},t.prototype.addChildToUmlNode=function(e,i,r){var s,o,a,l,h="NoWrap";"Class"===e.shape.classifier||"Interface"===e.shape.classifier?"Method"===r?(o=new fm(e,"",i),"Class"===e.shape.classifier?(e.shape.classShape.methods.push(o),s=e.shape.classShape):"Interface"===e.shape.classifier&&(e.shape.interfaceShape.methods.push(o),s=e.shape.interfaceShape),function soe(n,t,e,i){if(e.methods&&e.methods.length){var r=e.methods,s="",o="",a=void 0,l=1,h=void 0,c=0,d=0,u=n.shape,g="Class"===u.classifier?u.classShape:u.interfaceShape;1===r.length?g.attributes.length>0?(c=g.attributes.filter(function(w){return w.isSeparator}).length,h=(l=2+g.attributes.length+c)+1,aT(n,t,l)):h=l+1:(c=g.attributes.filter(function(w){return w.isSeparator}).length,d=g.methods.filter(function(w){return w.isSeparator}).length,h=(l=2+g.attributes.length+c+g.methods.length+d)+1);for(var v=0;v1&&this.startGroupAction();for(var r=i.length-1;r>=0;r--)if(e.children&&e.children.length>0){var s=e.wrapper.children.filter(function(o){return o.id===e.id+"group_container"});s&&s.length>0&&this.removelabelExtension(e,i,r,s[0])}else this.removelabelExtension(e,i,r,e.wrapper);i.length>1&&this.endGroupAction(),this.refreshCanvasLayers()},t.prototype.removePortsExtenion=function(e,i,r,s){for(var o=0;o1&&this.startGroupAction();for(var r=i.length-1;r>=0;r--)if(e.children&&e.children.length>0)for(var s=0;s1&&this.endGroupAction()},t.prototype.getSizeValue=function(e,i){var r;return r=e.toString().indexOf("px")>0?e.toString():e.toString().indexOf("%")>0?void 0!==i?"100%":e.toString():e.toString()+"px",i&&(Za(this),r="calc("+r+" - "+i+"px)"),r},t.prototype.renderRulers=function(){this.rulerSettings.showRulers?(function ise(n){var t=Za(n),i=Tt("div",{id:n.element.id+"_overlapRuler",style:"height:"+t.height+"px;width:"+t.width+"px;position:absolute;left:0;top:0",class:"e-ruler-overlap"});n.element.insertBefore(i,n.element.firstChild)}(this),oF(this,!0),oF(this,!1)):qx(this)},t.prototype.intOffPageBackground=function(){var e=new me;e=Za(this);var i=document.getElementById(this.element.id+"content"),r=this.getSizeValue(this.width,e.width),s=this.getSizeValue(this.height,e.height),o=this.rulerSettings.showRulers?"width:"+r+"; height:"+s+";top:"+e.height+"px;left:"+e.width+"px;overflow: scroll;position:absolute;overflow:auto;":"width:"+r+"; height:"+s+";position:absolute; left:0px; top:0px;overflow: auto;",a={id:this.element.id+"content",tabindex:"0",style:o};i?(this.diagramCanvas=i,Ka(this.diagramCanvas,o)):(this.diagramCanvas=Tt("div",a),this.element.appendChild(this.diagramCanvas)),this.diagramCanvas.style.background=this.backgroundColor},t.prototype.initDiagram=function(){this.intOffPageBackground(),Ho(this.element,{style:"width:"+this.getSizeValue(this.width)+"; height:"+this.getSizeValue(this.height)+";position:relative;overflow:hidden;"})},t.prototype.renderHiddenUserHandleTemplateLayer=function(e){var r=Tt("div",{class:this.element.id+"_hiddenUserHandleTemplate",style:"width:"+e.width+"px; height:"+e.height+"px;visibility:hidden ; overflow: hidden;"});this.element.appendChild(r)},t.prototype.renderBackgroundLayer=function(e,i){var r=this.createSvg(this.element.id+"_backgroundLayer_svg",e.width,e.height);Ka(r,i);var s=Fi("g",{id:this.element.id+"_backgroundImageLayer",class:"e-background-image-layer"});r.appendChild(s);var a=Fi("g",{id:this.element.id+"_backgroundLayer",class:"e-background-layer"});r.appendChild(a),this.diagramCanvas.appendChild(r)},t.prototype.renderGridLayer=function(e,i){var r=this.createSvg(this.element.id+"_gridline_svg",e.width,e.height);r.setAttribute("class","e-grid-layer");var s=Fi("g",{id:this.element.id+"_gridline"}),o=Fi("rect",{id:this.element.id+"_grid_rect",x:"0",y:"0",width:"100%",height:"100%"});if(lm()){var a=new URL(window.location.href);o.setAttribute("fill",""!==a.search?"url(#"+this.element.id+"_pattern)":"url("+location.protocol+"//"+location.host+location.pathname+"#"+this.element.id+"_pattern)")}else o.setAttribute("fill","url(#"+this.element.id+"_pattern)");s.appendChild(o),r.appendChild(s),this.diagramCanvas.appendChild(r),ti(r,{style:i})},t.prototype.renderDiagramLayer=function(e,i){if(this.diagramLayerDiv=Tt("div",{id:this.element.id+"_diagramLayer_div",style:"width:"+e.width+"px; height:"+e.height+"px;"+i}),"SVG"===this.mode){var s=this.createSvg(this.element.id+"_diagramLayer_svg",e.width,e.height);s.style["pointer-events"]="none",s.setAttribute("class","e-diagram-layer");var o=Fi("g",{id:this.element.id+"_diagramLayer"}),a=Fi("g",{});this.diagramLayer=o,s.style["pointer-events"]="all",a.appendChild(o),s.appendChild(a),this.diagramLayerDiv.appendChild(s)}else this.diagramLayer=bo.createCanvas(this.element.id+"_diagram",e.width,e.height),Ka(this.diagramLayer,"position:absolute;left:0px;top:0px;"),this.diagramLayerDiv.appendChild(this.diagramLayer);this.diagramCanvas.appendChild(this.diagramLayerDiv)},t.prototype.initLayers=function(){var e="position:absolute;top:0px;left:0px;overflow:hidden;pointer-events:none;",r=document.getElementById(this.element.id).getBoundingClientRect(),s=function Loe(){var n=Tt("div",{style:"visibility:hidden; width: 100px"});document.body.appendChild(n);var t=n.getBoundingClientRect().width;n.style.overflow="scroll";var e=Tt("div",{style:"width:100%"});n.appendChild(e);var i=e.getBoundingClientRect().width;return n.parentNode.removeChild(n),t-i}();this.scroller.scrollerWidth=s,this.scroller.setViewPortSize(r.width,r.height),this.renderRulers();var o="measureElement";window[""+o]&&(window[""+o]=null,document.getElementById("measureElement").remove()),function WF(){var n="measureElement";if(window[""+n])window[""+n].usageCount+=1;else{var t=Tt("div",{id:"measureElement",style:"visibility:hidden ; height: 0px ; width: 0px; overflow: hidden;"}),e=Tt("span",{style:"display:inline-block ; line-height: normal"});t.appendChild(e);var i=Tt("img",{alt:"measureElementImage",src:"data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7"});t.appendChild(i);var r=document.createElementNS("http://www.w3.org/2000/svg","svg");r.setAttribute("xmlns:xlink","http://www.w3.org/1999/xlink"),t.appendChild(r);var s=document.createElementNS("http://www.w3.org/2000/svg","path");s.setAttribute("d",""),r.appendChild(s),document.createTextNode("");var a=document.createElementNS("http://www.w3.org/2000/svg","text");a.setAttributeNS("http://www.w3.org/XML/1998/namespace","xml:space","preserve"),r.appendChild(a),window[""+n]=t,window[""+n].usageCount=1,document.body.appendChild(t);var l="measureElementCount";window[""+l]?window[""+l]++:window[""+l]=1}}(),this.renderBackgroundLayer(r,e),this.renderGridLayer(r,e),this.renderDiagramLayer(r,e),this.renderHTMLLayer(r,e),this.renderPortsExpandLayer(r,e),this.renderNativeLayer(r,e),this.renderAdornerLayer(r,e),this.renderHiddenUserHandleTemplateLayer(r)},t.prototype.renderAdornerLayer=function(e,i){var r=Tt("div",{id:this.element.id+"_diagramAdornerLayer",style:"width:"+e.width+"px;height:"+e.height+"px;"+i}),s=Tt("div",{id:this.element.id+"_diagramUserHandleLayer",style:"width:"+e.width+"px;height:"+e.height+"px;"+i});s.setAttribute("class","e-userHandle-layer"),r.appendChild(s);var o=this.createSvg(this.element.id+"_diagramAdorner_svg",e.width,e.height);o.setAttribute("class","e-adorner-layer"),o.style["pointer-events"]="none",this.adornerLayer=Fi("g",{id:this.element.id+"_diagramAdorner"}),this.adornerLayer.style[" pointer-events"]="all",o.appendChild(this.adornerLayer),r.appendChild(o),this.diagramCanvas.appendChild(r);var a=Fi("g",{id:this.element.id+"_SelectorElement"});this.adornerLayer.appendChild(a),ti(o,{style:"pointer-events:none;"})},t.prototype.renderPortsExpandLayer=function(e,i){var r=this.createSvg(this.element.id+"_diagramPorts_svg",e.width,e.height);r.setAttribute("class","e-ports-expand-layer");var s=Fi("g",{id:this.element.id+"_diagramPorts",class:"e-ports-layer",style:"pointer-events: all;"});r.appendChild(s);var o=Fi("g",{id:this.element.id+"_diagramExpander",class:"e-expand-layer",style:"pointer-events: all;"});r.appendChild(o),this.diagramCanvas.appendChild(r),ti(r,{style:i})},t.prototype.renderHTMLLayer=function(e,i){this.htmlLayer=Tt("div",{id:this.element.id+"_htmlLayer",style:"width:"+e.width+"px; height:"+e.height+"px;position:absolute;top:0px;left:0px;overflow:hidden;pointer-events:none;",class:"e-html-layer"});var r=Tt("div",{id:this.element.id+"_htmlLayer_div",style:"position:absolute;top:0px;left:0px;pointer-events:all;"});this.htmlLayer.appendChild(r),this.diagramCanvas.appendChild(this.htmlLayer)},t.prototype.renderNativeLayer=function(e,i){var r=this.createSvg(this.element.id+"_nativeLayer_svg",e.width,e.height),s=Fi("g",{id:this.element.id+"_nativeLayer",style:"pointer-events:all;"});r.appendChild(s),this.diagramLayerDiv.appendChild(r),ti(r,{class:"e-native-layer",style:i})},t.prototype.createSvg=function(e,i,r){var s=document.createElementNS("http://www.w3.org/2000/svg","svg");return ti(s,{id:e,width:i,height:r}),s},t.prototype.updateBazorShape=function(){for(var e=0;e1,i=[],r={},s={},o=[],a=0,l=this.nodes;a0||b&&b.children&&b.children.length>0)&&(M=!1),S&&S.wrapper&&b&&b.wrapper&&M?this.initConnectors(r[""+h],p):i.push(r[""+h])}else b=r[y.targetID],(S=r[y.sourceID])&&S.children&&S.children.length>0||b&&b.children&&b.children.length>0?i.push(r[""+h]):this.initConnectors(r[""+h],p);else r[""+h].children?o.push(h):r[""+h].shape instanceof uT&&r[""+h].shape.activity.subProcess.processes&&r[""+h].shape.activity.subProcess.processes.length>0?s[r[""+h].id]=h:this.initNodes(r[""+h],p);if(this.bpmnModule)for(var w=0,C=this.bpmnModule.bpmnTextAnnotationConnector;w-1&&-1===r.indexOf(c)&&-1===s.indexOf(c)&&r.splice(0,0,c);-1===r.indexOf(o)&&s.push(o)}return r.concat(s)},t.prototype.addToLayer=function(e,i){var r;if(i&&(r=this.commandHandler.getObjectLayer(e.id)),(!i||!r)&&-1===this.activeLayer.objects.indexOf(e.id)&&this.activeLayer.objects.push(e.id),(e instanceof te||e instanceof de)&&("SwimLane"!==e.shape.type||e.children&&e.children.length>0)){if(e.parentId){var s=this.swimlaneZIndexTable[e.parentId],o=this.swimlaneChildTable[e.id];(s&&-1!==s||o&&-1!==o)&&(e.zIndex=this.swimlaneChildTable[e.id])}e instanceof de&&e.sourceID&&e.targetID?-1!==this.activeLayer.objects.indexOf(e.sourceID)&&-1!==this.activeLayer.objects.indexOf(e.targetID)&&this.setZIndex(r||this.activeLayer,e):this.setZIndex(r||this.activeLayer,e)}},t.prototype.updateLayer=function(e){for(var i=0,r=Object.keys(e.layers);i0)for(r=0;rs;l--)r.zIndexTable[parseInt(l.toString(),10)]=r.zIndexTable[l-1],this.nameTable[r.zIndexTable[parseInt(l.toString(),10)]]&&(this.nameTable[r.zIndexTable[parseInt(l.toString(),10)]].zIndex=l);r.zIndexTable[parseInt(a.toString(),10)]=i.id}}},t.prototype.initializeDiagramLayers=function(){for(var e=0;ethis.layers[parseInt(a.toString(),10)].zIndex&&(i=this.layers[parseInt(e.toString(),10)],this.layers[parseInt(e.toString(),10)]=this.layers[parseInt(a.toString(),10)],this.layers[parseInt(a.toString(),10)]=i);0===this.layers.length&&this.commandHandler.addLayer({id:"default_layer",visible:!0,lock:!1,objects:[],zIndex:0,objectZIndex:-1,zIndexTable:{}},null,!0),this.setActiveLayer(this.layers[this.layers.length-1].id)},t.prototype.resetTool=function(){this.eventHandler.resetTool()},t.prototype.initObjectExtend=function(e,i,r){if(r){var s=this.commandHandler.checkBoundaryConstraints(void 0,void 0,e.wrapper.bounds,!0);if("SwimLane"===e.shape.type)for(var o=0,a=Object.keys(i.zIndexTable);o0)&&this.setZIndex(i,e)),e instanceof te){if(r){if("helper"!==e.id&&(o=Zi(this.getNodeDefaults))){if((a=o(e,this))&&a.ports)for(var l=0;l0)for(l=0;l0&&!e.container||e.processId){var r=this.nameTable[e.id];if(!(this.realActions&$i.PreventScale||this.realActions&$i.PreventDrag)){if(r.offsetX&&(this.realActions&$i.EnableGroupAction||!(this.diagramActions&ee.UndoRedo||this.diagramActions&ee.ToolAction||this.diagramActions&ee.PublicMethod))){this.realActions|=$i.PreventScale;var s=r.offsetX-e.wrapper.offsetX;r.offsetX=e.wrapper.offsetX;var o=r.offsetY-e.wrapper.offsetY;r.offsetY=e.wrapper.offsetY,s+o!==0&&this.drag(r,s,o),this.realActions&=~$i.PreventScale}else r.offsetX=e.wrapper.offsetX;r.offsetY&&(this.realActions&$i.EnableGroupAction||!(this.diagramActions&ee.UndoRedo||this.diagramActions&ee.ToolAction||this.diagramActions&ee.PublicMethod))?(this.realActions|=$i.PreventScale,o=r.offsetY-e.wrapper.offsetY,r.offsetY=e.wrapper.offsetY,this.drag(r,0,o),this.realActions&=~$i.PreventScale):r.offsetY=e.wrapper.offsetY,this.diagramActions&&(r.width=e.wrapper.actualSize.width,r.height=e.wrapper.actualSize.height)}}i&&e.children&&e.children.length>0&&(void 0!==this.nameTable[e.id].width?this.scaleObject(e,this.nameTable[e.id].width,!0):this.nameTable[e.id].width=e.wrapper.actualSize.width,void 0!==this.nameTable[e.id].height?this.scaleObject(e,this.nameTable[e.id].height,!1):this.nameTable[e.id].height=e.wrapper.actualSize.height)},t.prototype.initNode=function(e,i,r){var a,f,s=e.initContainer(),o=new Mi;if(this.diagramSettings.inversedAlignment||(s.inversedAlignment=!1),s.children||(s.children=[]),e.children){s.measureChildren=!1,o.id=e.id+"group_container",o.style.fill=e.shape&&"SwimLane"===e.shape.type?e.style.fill:"none",o.style.strokeColor="none",o.horizontalAlignment="Stretch",o.verticalAlignment="Stretch",o.pivot=e.pivot,s.style=e.style,s.padding.left=e.padding.left,s.padding.right=e.padding.right,s.padding.top=e.padding.top,s.padding.bottom=e.padding.bottom,o.children=[],o.preventContainer=!0,e.container&&(o.relativeMode="Object");var l=!!(e.ports&&e.ports.length>0);if(m(e.container)&&!l&&s.children.push(o),e.container&&"Grid"===e.container.type)for(var h=0;h0&&e.wrapper.children[0]instanceof Gv){if(this.setZIndex(this.activeLayer,e),this.connectors.length>0)for(h=0;h0?i.phases.length:0,v="Horizontal"===i.orientation,y=v?i.phases.length||1:s.length+1,S=v?(i.header&&i.hasHeader?1:0)+(i.phases.length>0?1:0)+i.lanes.length:(i.header&&i.hasHeader?1:0)+i.phases.length;if(0===h&&!v&&i.lanes.length&&(S+=1),v?(a=(i.header&&i.hasHeader?1:0)+(h>0?1:0),l=0):(a=i.header&&i.hasHeader?1:0,l=h>0?1:0),s.length>0)for(o+=i.header&&i.hasHeader?i.header.height:0,f=0;fl?d.margin.left=d.margin.left-(u.bounds.left-e.bounds.left):u.children[0].children[1].actualSize.width+r>=d.margin.left&&(d.margin.left=u.children[0].children[1].actualSize.width+r),d.margin.lefta?d.margin.top=d.margin.top-(u.bounds.top-o):u.children[0].children[1].actualSize.height+r>=d.margin.top&&(d.margin.top=u.children[0].children[1].actualSize.height+r),d.margin.left0)for(o=0;o0&&this.updateChildPosition(e)},t.prototype.addBpmnAnnotationConnector=function(e,i){if(e.parentObj instanceof t||e.parentObj instanceof Fd){var r=e.shape,o=""!==r.textAnnotation.textAnnotationTarget&&this.nameTable[r.textAnnotation.textAnnotationTarget],a=o?this.nameTable[r.textAnnotation.textAnnotationTarget]:null,l=null!=a?a.wrapper:null,h=e.ports[0],c={x:0,y:0};switch(r.textAnnotation.textAnnotationDirection){case"Left":h.offset={x:0,y:.5},c.x=i.bounds.left-40,c.y=i.bounds.bottom+30;break;case"Right":h.offset={x:1,y:.5},c.x=i.bounds.right+40,c.y=i.bounds.bottom+30;break;case"Top":h.offset={x:.5,y:0},c.x=i.bounds.right+30,c.y=i.bounds.top-40;break;case"Bottom":h.offset={x:.5,y:1},c.x=i.bounds.right+30,c.y=i.bounds.bottom+40;break;default:h.offset={x:0,y:.5},c.x=i.bounds.left-40,c.y=i.bounds.bottom+30,o&&null!=i&&null!=l&&(i.bounds.left>l.bounds.right?h.offset={x:0,y:.5}:i.bounds.rightl.bounds.top?h.offset={x:.5,y:0}:i.bounds.top0&&this.updateChildPosition(r)}},t.prototype.canExecute=function(){return!0},t.prototype.updateStackProperty=function(e,i,r){e.container&&"Stack"===e.container.type&&(i.width||(i.wrapper.horizontalAlignment="Stretch",i.horizontalAlignment="Stretch"),i.height||(i.verticalAlignment="Stretch",i.wrapper.verticalAlignment="Stretch"),r&&"UmlClassifier"===e.shape.type&&(i.umlIndex=r))},t.prototype.initViews=function(){this.isLoading||(this.views.push(this.element.id),this.views[this.element.id]=this)},t.prototype.initCommands=function(){var e=this.commandManager.commands,i={copy:{execute:this.copyCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.C,keyModifiers:ft.Control}},paste:{execute:this.pasteCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.V,keyModifiers:ft.Control}},cut:{execute:this.cutCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.X,keyModifiers:ft.Control}},delete:{execute:this.removeCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Delete}},selectAll:{execute:this.selectAll.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.A,keyModifiers:ft.Control}},undo:{execute:this.undo.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Z,keyModifiers:ft.Control}},redo:{execute:this.redo.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Y,keyModifiers:ft.Control}},nudgeUp:{execute:this.nudgeCommand.bind(this,"Up"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Up},parameter:"up"},nudgeRight:{execute:this.nudgeCommand.bind(this,"Right"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Right},parameter:"right"},nudgeDown:{execute:this.nudgeCommand.bind(this,"Down"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Down},parameter:"down"},nudgeLeft:{execute:this.nudgeCommand.bind(this,"Left"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Left},parameter:"left"},startEdit:{execute:this.startEditCommad.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.F2}},endEdit:{execute:this.endEditCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Escape}},focusToNextItem:{execute:this.navigateItems.bind(this,!0),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Tab}},focusToPreviousItem:{execute:this.navigateItems.bind(this,!1),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Tab,keyModifiers:ft.Shift}},selectFocusedItem:{execute:this.startEditCommad.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Enter}},bold:{execute:this.fontStyleCommand.bind(this,"bold"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.B,keyModifiers:ft.Control}},italic:{execute:this.fontStyleCommand.bind(this,"italic"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.I,keyModifiers:ft.Control}},underline:{execute:this.fontStyleCommand.bind(this,"underline"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.U,keyModifiers:ft.Control}},duplicate:{execute:this.duplicateCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.D,keyModifiers:ft.Control}},group:{execute:this.groupCommand.bind(this,"group"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.G,keyModifiers:ft.Control}},ungroup:{execute:this.groupCommand.bind(this,"ungroup"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.U,keyModifiers:ft.Control|ft.Shift}},rotateClockwise:{execute:this.rotateCommand.bind(this,"clockwise"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.R,keyModifiers:ft.Control}},rotateAntiClockwise:{execute:this.rotateCommand.bind(this,"antiClockwise"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.L,keyModifiers:ft.Control}},flipHorizontal:{execute:this.flipCommand.bind(this,"horizontal"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.H,keyModifiers:ft.Control}},flipVertical:{execute:this.flipCommand.bind(this,"vertical"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.J,keyModifiers:ft.Control}},pointerTool:{execute:this.toolCommand.bind(this,"pointer"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number1,keyModifiers:ft.Control}},textTool:{execute:this.toolCommand.bind(this,"text"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number2,keyModifiers:ft.Control}},connectTool:{execute:this.toolCommand.bind(this,"connect"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number3,keyModifiers:ft.Control}},freeForm:{execute:this.toolCommand.bind(this,"freeForm"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number5,keyModifiers:ft.Control}},lineTool:{execute:this.toolCommand.bind(this,"line"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number6,keyModifiers:ft.Control}},rectangleTool:{execute:this.toolCommand.bind(this,"rectangle"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number8,keyModifiers:ft.Control}},ellipseTool:{execute:this.toolCommand.bind(this,"ellipse"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number9,keyModifiers:ft.Control}},zoomIn:{execute:this.zoomCommand.bind(this,"zoomIn"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Plus,keyModifiers:ft.Control}},zoomOut:{execute:this.zoomCommand.bind(this,"zoomOut"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Minus,keyModifiers:ft.Control}},shiftUp:{execute:this.shiftCommand.bind(this,"Up"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Up,keyModifiers:ft.Shift}},shiftDown:{execute:this.shiftCommand.bind(this,"Down"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Down,keyModifiers:ft.Shift}},shiftLeft:{execute:this.shiftCommand.bind(this,"Left"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Left,keyModifiers:ft.Shift}},shiftRight:{execute:this.shiftCommand.bind(this,"Right"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Right,keyModifiers:ft.Shift}},alignTextCenter:{execute:this.alignCommand.bind(this,"center"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.C,keyModifiers:ft.Control|ft.Shift}},alignTextLeft:{execute:this.alignCommand.bind(this,"right"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.L,keyModifiers:ft.Control|ft.Shift}},alignTextRight:{execute:this.alignCommand.bind(this,"left"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.R,keyModifiers:ft.Control|ft.Shift}},alignTextTop:{execute:this.alignCommand.bind(this,"top"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.E,keyModifiers:ft.Control|ft.Shift}},alignTextCenterVertical:{execute:this.alignCommand.bind(this,"centerVertical"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.M,keyModifiers:ft.Control|ft.Shift}},alignTextBottom:{execute:this.alignCommand.bind(this,"bottom"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.V,keyModifiers:ft.Control|ft.Shift}},alignJustify:{execute:this.alignCommand.bind(this,"justify"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.J,keyModifiers:ft.Control|ft.Shift}},sendToBack:{execute:this.orderCommand.bind(this,"sendToBack"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.B,keyModifiers:ft.Control|ft.Shift}},bringToFront:{execute:this.orderCommand.bind(this,"bringToFront"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.F,keyModifiers:ft.Control|ft.Shift}},sendBackward:{execute:this.orderCommand.bind(this,"sendBackward"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.BracketLeft,keyModifiers:ft.Control}},bringForward:{execute:this.orderCommand.bind(this,"bringForward"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.BracketRight,keyModifiers:ft.Control}}};this.initCommandManager(e,i)},t.prototype.overrideCommands=function(e,i){for(var r,s=0,o=Object.keys(i);se.zIndex){("HTML"===e.shape.type||"Native"===e.shape.type)&&(o="HTML"===e.shape.type?"html":"native"),s=Eoe(i,r[parseInt(a.toString(),10)].id,o);break}return s},t.prototype.updateDiagramObject=function(e,i,r){for(var s,o="domTable",a=0,l=this.views;a1&&(d=this.commandHandler.getObjectLayer(e.id)),void 0===d||d&&d.visible||r){var u=Io(this.element.id);window[""+o][s.element.id+"_diagramLayer"]||(window[""+o][s.element.id+"_diagramLayer"]=document.getElementById(s.element.id+"_diagramLayer"));var f=window[""+o][s.element.id+"_diagramLayer"];this.diagramActions&ee.Interactions&&this.updateCanupdateStyle(e.wrapper.children,!0);var p=this.getMidPoint(e);this.diagramRenderer.updateNode(e.wrapper,f,u,void 0,i?void 0:this.getZindexPosition(e,s.element.id),p,this.portCenterPoint),this.updateCanupdateStyle(e.wrapper.children,!0)}}},t.prototype.applyMarginBezier=function(e,i){i.cx=i.cx+e.margin.left,i.cx=i.cx-e.margin.right,i.cy=i.cy+e.margin.top,i.cy=i.cy-e.margin.bottom},t.prototype.getMidPoint=function(e){var i;if(e instanceof de&&"Bezier"===e.type){i=[];for(var r=this.getBezierPoints(e),s=R.getLengthFromListOfPoints(r),o=0;o0&&e.updateView(e));var s=Io(e.element.id);this.renderDiagramElements(e.diagramLayer,e.diagramRenderer,s,void 0,void 0,i);for(var o=0;o0&&this.renderBasicElement(e),!this.diagramActions||!(this.diagramActions&ee.Render)||ee.ToolAction&this.diagramActions||Ds(this)||1!==this.scroller.currentZoom?this.refreshElements(e):this.renderTimer||(this.renderTimer=setTimeout(function(){i.refreshElements(e)},40)))},t.prototype.updatePortVisibility=function(e,i,r){var s;if((e instanceof te||e instanceof de)&&(!this.drawingObject||!this.drawingObject.shape)&&ro(e)){for(var a=e.ports,l=!1,h=0;h=0&&this.scroller.removeCollection.splice(l,1);var h=this.nameTable[e[parseInt(a.toString(),10)]];this.updateTextElementValue(h),this.diagramRenderer.renderElement(h.wrapper,s,o,void 0,void 0,void 0,void 0,h.zIndex)}for(var c=0;c0?this.scroller.oldCollectionObjects:void 0,b=Object.keys(S||g.zIndexTable);b.sort(function(N,T){return parseInt(""+N,10)-parseInt(""+T,10)});for(var M=0,w=b;M0?h:0)+"px",y=(this.realActions&$i.vScrollbarMoved?0:-(this.scroller.verticalOffset<0?this.scroller.verticalOffset:0))+"px"):(v="0px",y="0px"),this.realActions&$i.hScrollbarMoved&&(this.realActions=this.realActions&~$i.hScrollbarMoved),this.realActions&$i.vScrollbarMoved&&(this.realActions=this.realActions&~$i.vScrollbarMoved)):(v=(l.x<0?h:-this.scroller.horizontalOffset)+"px",y=(l.y<0?c:-this.scroller.verticalOffset)+"px"),this.diagramLayer.style.left=v,this.diagramLayer.style.top=y,A.tx=-l.x/A.scale,A.ty=-l.y/A.scale);var P=!0;if(o&&(P=!1),this.updateTextElementValue(D),this.refreshing&&D.shape.activity&&D.shape.activity.subProcess&&D.shape.activity.subProcess.processes){for(var L=0;L0){var o=s.children[0],a=o.data;(r.isBezierEditing&&this.selectedItems.connectors[0].id===r.id||"Bezier"!==r.type)&&r.getSegmentElement(r,o,"ComplexHierarchicalTree"===this.layout.type||"HierarchicalTree"===this.layout.type?this.layout.orientation:void 0,void 0,!1),o.data!==a&&(s.measure(new me),s.arrange(s.desiredSize),"SVG"===this.mode&&!e&&this.updateDiagramObject(r))}}else this.constraints&nt.Bridging&&console.warn('[WARNING] :: Module "ConnectorBridging" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.setCursor=function(e){this.diagramRenderer.setCursor(this.diagramCanvas,e)},t.prototype.clearCanvas=function(e){var i=e.contentWidth||e.diagramLayer.width/this.scroller.currentZoom,r=e.contentHeight||e.diagramLayer.height/this.scroller.currentZoom;"SVG"!==e.mode&&bo.getContext(e.diagramLayer).clearRect(0,0,i,r)},t.prototype.updateScrollOffset=function(){this.scroller.setScrollOffset(this.diagramCanvas.scrollLeft,this.diagramCanvas.scrollTop),eb(this),Ds(this)&&this.scroller.virtualizeElements()},t.prototype.setOffset=function(e,i){var r="domTable";window[""+r][this.element.id+"content"]||(window[""+r][this.element.id+"content"]=document.getElementById(this.element.id+"content"));var s=window[""+r][this.element.id+"content"];s&&(s.scrollLeft=e,s.scrollTop=i)},t.prototype.setSize=function(e,i){if(this.diagramLayer&&!this.preventDiagramUpdate){var r=Za(this);e-=r.width,i-=r.height;var s=this.spatialSearch.getPageBounds();s.x*=this.scroller.currentZoom,s.y*=this.scroller.currentZoom,s.width*=this.scroller.currentZoom,s.height*=this.scroller.currentZoom;var o="SVG"===this.mode?1:1.5,a="SVG"===this.mode?mT(this.element.id):this.diagramLayer,h="Canvas"===this.mode&&this.constraints&nt.Virtualization?this.scroller.viewPortHeight:i;a.setAttribute("width",(o*("Canvas"===this.mode&&this.constraints&nt.Virtualization?this.scroller.viewPortWidth:e)).toString()),a.setAttribute("height",(o*h).toString());var c=document.getElementById(this.element.id+"_diagramUserHandleLayer");c&&(c.style.width=e+"px",c.style.height=i+"px");var d={width:e.toString(),height:i.toString()};this.diagramLayerDiv.style.width=e+"px",this.diagramLayerDiv.style.height=i+"px",ti(FF(this.element.id),d),ti(function xoe(n){return xt(n).getElementsByClassName("e-ports-expand-layer")[0]}(this.element.id),d);var u=Fl(this.element.id);ti(u,d),u.parentNode.style.width=e+"px",u.parentNode.style.height=i+"px";var f=Ud(this.element.id);ti(f,d),this.diagramRenderer.updateGrid(this.snapSettings,f,this.scroller.transform,this.rulerSettings,this.hRuler,this.vRuler),ti(IT(this.element.id),d),this.htmlLayer.style.width=e+"px",this.htmlLayer.style.height=i+"px","SVG"!==this.mode&&!Ds(this)&&this.refreshDiagramLayer(),"SVG"===this.mode&&Ds(this)&&this.scroller.virtualizeElements()}},t.prototype.transformLayers=function(){var e=this.spatialSearch.getPageBounds();e.x*=this.scroller.currentZoom,e.y*=this.scroller.currentZoom,e.width*=this.scroller.currentZoom,e.height*=this.scroller.currentZoom,this.diagramRenderer.updateGrid(this.snapSettings,Ud(this.element.id),this.scroller.transform,this.rulerSettings,this.hRuler,this.vRuler),this.diagramRenderer.transformLayers(this.scroller.transform,"SVG"===this.mode),this.diagramActions&ee.DragUsingMouse||this.updateSelector(),this.renderPageBreaks(e)},t.prototype.removePageBreaks=function(){if(this.diagramLayer){var e=_F(this.element.id);if(e&&e.childNodes)for(var i=e.childNodes.length,r=0;rthis.pageSettings.height&&(e=this.pageSettings.height,this.pageSettings.height=this.pageSettings.width,this.pageSettings.width=e):this.pageSettings.height>this.pageSettings.width&&(e=this.pageSettings.width,this.pageSettings.width=this.pageSettings.height,this.pageSettings.height=e)},t.prototype.setOverview=function(e,i){if(e)e&&(this.views.push(e.id),this.views[e.id]=e,e.renderDocument(e),e.diagramRenderer.setLayers(),e.updateView(e),this.renderNodes(e));else{for(var r=0;r1&&this.updateSelectionRectangle(),this.isProtectedOnChange=s},t.prototype.updateSelectionRectangle=function(){for(var e=pm(this.element.id),i=!1,r=0;r1&&this.updateSelectionRectangle(),this.enableServerDataBinding(e)},t.prototype.renderSelectorForAnnotation=function(e,i){this.diagramRenderer.renderResizeHandle(e.wrapper.children[0],i,e.thumbsConstraints,this.scroller.currentZoom,e.constraints,this.scroller.transform,void 0,ro(e.annotation),void 0,void 0,e.handleSize)},t.prototype.drawSelectionRectangle=function(e,i,r,s){this.clearSelectorLayer(),this.diagramRenderer.drawSelectionRectangle(e,i,r,s,this.adornerLayer,this.scroller.transform)},t.prototype.renderHighlighter=function(e){var i=Fl(this.element.id);this.diagramRenderer.renderHighlighter(e,i,this.scroller.transform)},t.prototype.clearHighlighter=function(){var e=Fl(this.element.id),i=e.getElementById(e.id+"_highlighter");i&&i.parentNode.removeChild(i)},t.prototype.getNodesConnectors=function(e){for(var i=0;i0;h--)this.eventHandler&&this.eventHandler.touchArgs&&"touchmove"===this.eventHandler.touchArgs.type?(this.diagramRenderer.touchMove=!0,l&&l===o[h-1].id||(a=o[h-1]).parentNode.removeChild(a)):(a=o[h-1]).parentNode.removeChild(a);if(!ce()){var c=ST(this.element.id).childNodes;for(r=c.length;r>0;r--)c[r-1].parentNode.removeChild(c[r-1])}}},t.prototype.getWrapper=function(e,i){var r;i=e.id+"_"+i;for(var s=e instanceof Mi?e:this.getPortContainer(this.nameTable[e.id]),o=0;o0&&this.applyStyle(e,a=r.annotations)}for(i=0;i0){var a=this.selectedItems.connectors[parseInt(i.toString(),10)].annotations;this.applyStyle(e,a)}},t.prototype.applyStyle=function(e,i){for(var r=0;r0)for(var i=0;i0?r[0].zIndex+(e?1:-1):e?0:this.nodes.length+this.connectors.length-1)<0?i=this.nodes.length+this.connectors.length-1:i===this.nodes.length+this.connectors.length&&(i=0);for(var s=0;s0)for(var s=void 0,o=r.children.length-1;o>=0;o--){var a=r.children[parseInt(o.toString(),10)];i.length>0&&-1!==i.indexOf(a.id.split("_groupElement")[0])&&(r.parentNode.insertBefore(a,s||r),s=a)}r&&r.parentNode.removeChild(r)},t.prototype.deleteGroup=function(e){var r=[];e.children&&(r=this.commandHandler.getChildren(e,[])),this.UpdateBlazorDiagramModelCollection(e);for(var s=0,o=r;s0)for(var xe=0;xe0)if("Path"===t.shape.type&&void 0!==n.shape.data)t.wrapper.children[0].data=n.shape.data;else if("Text"===t.shape.type&&void 0!==n.shape.content)t.wrapper.children[0].content=n.shape.content;else if("Image"===t.shape.type&&void 0!==n.shape.source)t.wrapper.children[0].source=n.shape.source;else if("Native"===t.shape.type){for(var r=void 0,s=0;s-1)&&(this.diagramActions&ee.PreventZIndexOnDragging?this.updateDiagramObject(e,!0):this.updateDiagramObject(e)),!s&&d&&(this.lineRoutingModule&&this.diagramActions&&this.constraints&nt.LineRouting&&"helper"!==e.id?this.diagramActions&ee.ToolAction||this.lineRoutingModule.renderVirtualRegion(this,!0):this.diagramActions&&this.constraints&nt.LineRouting&&"helper"!==e.id&&console.warn('[WARNING] :: Module "LineRouting" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),this.updateConnectorEdges(e),"helper"!==e.id&&!(this.diagramActions&ee.ToolAction))))for(var Sa=this.spatialSearch.findObjects(e.wrapper.outerBounds),Mo=0;Moe?Math.abs(r-e):Math.abs(e-r),d=s>i?Math.abs(s-i):Math.abs(i-s);(0===c&&0===d||Number.isNaN(c)&&Number.isNaN(d))&&o.laneMargin&&(u=o.margin.left-o.laneMargin.left,f=o.margin.top-o.laneMargin.top);var p=o.width,g=o.height,v=new Ne(0,0,0,0);if(0!==p&&0!==g&&(v=new Ne((0!==r?r:o.offsetX)-p/2,(0!==s?s:o.offsetY)-g/2,p,g)),h){var y=l,b=this.selectedItems.nodes?this.selectedItems.nodes[0]:void 0;if(""!==y.textAnnotation.textAnnotationTarget&&this.nameTable[y.textAnnotation.textAnnotationTarget])if(""===o.parentId||b&&b.shape&&"TextAnnotation"===b.shape.shape){if("Auto"===y.textAnnotation.textAnnotationDirection&&a.children[0]instanceof Mi&&a.children[0].children[0]instanceof Ze){var w=a.children[0],C=document.getElementById(w.id+"_groupElement"),D=document.getElementById(w.children[0].id+"_groupElement");C.removeChild(D),w.children.splice(0,1),this.isProtectedOnChange=!0,this.bpmnModule.setAnnotationPath(v,w,o,y,y.textAnnotation.textAnnotationDirection,this),this.isProtectedOnChange=!1}}else this.isPositionUndo=!0,this.updateTextAnnotationInSwimlane(o,o),this.isPositionUndo=!1;else o.inEdges.length>0&&(x=this.nameTable[""+o.inEdges[0]])&&x.isBpmnAnnotationConnector&&(x.sourcePoint={x:r>e?x.sourcePoint.x+c:x.sourcePoint.x-c,y:s>i?x.sourcePoint.y+d:x.sourcePoint.y-d});this.nodePropertyChange(o,{},P={ports:[{offset:o.ports[0].offset}]})}else for(var L=0,O=o.outEdges;Le?T.offsetX+c:T.offsetX-c,T.offsetY=s>i?T.offsetY+d:T.offsetY-d,P={offsetX:T.offsetX,offsetY:T.offsetY}),this.nodePropertyChange(T,z,P)}}}},t.prototype.updatePorts=function(e,i){if(e&&e.ports.length>0)for(var r=0,s=Object.keys(e.ports);r0)for(var i=0;i0)for(var r=0;r0&&void 0===r.segments&&(e.segments=[]),void 0!==r.shape&&void 0!==e.shape&&e.shape&&"Bpmn"===e.shape.type&&this.bpmnModule&&this.bpmnModule.updateBPMNConnector(e,i,r,this),void 0!==e.constraints?(this.updateThumbConstraints(this.selectedItems.connectors,this.selectedItems),s=!0):s},t.prototype.connectorPropertyChange=function(e,i,r,s,o){if(this.canEnableBlazorObject){var a=$(e);this.insertValue(a,!1)}var d,u,f,p,l=e.wrapper.bounds,h=!1,c=[];if(h=this.connectorProprtyChangeExtend(e,i,r,h),void 0!==r.visible&&this.updateElementVisibility(e.wrapper,e,e.visible),void 0!==r.sourcePoint||void 0!==r.targetPoint||void 0!==r.sourceID||void 0!==r.targetID||void 0!==r.targetPadding||void 0!==r.sourcePortID||void 0!==r.targetPortID||void 0!==r.sourcePadding||void 0!==r.type||void 0!==r.segments||void 0!==r.flip){if(void 0!==r.sourceID&&r.sourceID!==i.sourceID||r.sourcePortID){if(u=this.findInOutConnectPorts(g=this.nameTable[e.sourceID],!1),(!g||Rh(g)||""!==e.sourcePortID&&Ld(u))&&(e.sourceWrapper=g?this.getEndNodeWrapper(g,e,!0):void 0,e.sourcePortID&&void 0===r.sourcePortID&&(e.sourcePortWrapper=g?this.getWrapper(g.wrapper,e.sourcePortID):void 0),this.removePortEdges(this.nameTable[i.sourceID]||g,i.sourcePortID||e.sourcePortID,e.id,!1)),void 0!==r.sourceID&&void 0!==i.sourceID&&""!==i.sourceID){var v=this.nameTable[i.sourceID];void 0!==v&&v.outEdges&&-1!==v.outEdges.indexOf(e.id)&&sm(v.outEdges,e.id)}this.updateEdges(e)}if(void 0!==r.targetID&&r.targetID!==i.targetID){if(d=this.findInOutConnectPorts(y=this.nameTable[r.targetID],!0),(!y||ua(y)||""!==e.targetPortID&&zh(d))&&(e.targetWrapper=y?this.getEndNodeWrapper(y,e,!1):void 0,e.targetPortID&&void 0===r.targetPortID&&(e.targetPortWrapper=y?this.getWrapper(y.wrapper,e.targetPortID):void 0),this.removePortEdges(this.nameTable[i.targetID]||y,i.targetPortID||e.targetPortID,e.id,!0)),void 0!==i&&void 0!==i.targetID&&""!==i.targetID){var S=this.nameTable[i.targetID];void 0!==S&&S.inEdges&&-1!==S.inEdges.indexOf(e.id)&&sm(S.inEdges,e.id)}this.updateEdges(e)}var g,y;void 0!==r.sourcePortID&&r.sourcePortID!==i.sourcePortID&&(e.sourceID&&this.nameTable[e.sourceID]&&(f=this.nameTable[e.sourceID].wrapper),!(g=this.nameTable[e.sourceID])||Rh(g)||""!==e.sourcePortID&&Ld(u)?e.sourcePortWrapper=f?this.getWrapper(f,r.sourcePortID):void 0:""===e.sourcePortID&&!Rh(g)&&(e.sourcePortWrapper=void 0)),void 0!==r.targetPortID&&r.targetPortID!==i.targetPortID&&(e.targetID&&this.nameTable[e.targetID]&&(p=this.nameTable[e.targetID].wrapper),!(y=this.nameTable[e.targetID])||ua(y)||""!==e.targetPortID&&zh(d)?e.targetPortWrapper=p?this.getWrapper(p,r.targetPortID):void 0:""===e.targetPortID&&!ua(y)&&(e.targetPortWrapper=void 0)),void 0!==r.flip&&(e.flip=r.flip,EF(e)),"Orthogonal"===e.type&&this.lineRoutingModule&&this.diagramActions&&this.constraints&nt.LineRouting&&!(this.diagramActions&ee.ToolAction)&&"ComplexHierarchicalTree"!==this.layout.type&&(this.lineRoutingModule.renderVirtualRegion(this,!0),e.sourceID!==e.targetID&&e.segments.length>1&&this.lineRoutingModule.refreshConnectorSegments(this,e,!1)),c=this.getPoints(e)}void 0!==r.style&&Hh(r.style,e.wrapper.children[0]),(c.length>0||void 0!==r.sourceDecorator||void 0!==r.targetDecorator&&function qse(n){return-1!==n.indexOf("shape")||-1!==n.indexOf("pathData")||-1!==n.indexOf("width")||-1!==n.indexOf("height")}(Object.keys(r.targetDecorator))||void 0!==r.cornerRadius)&&(tp(e,c.length>0?c:e.intermediatePoints,this.diagramActions),void 0!==r.type&&(h=!0),c.length>0&&(e.wrapper.measure(new me(e.wrapper.width,e.wrapper.height)),e.wrapper.arrange(e.wrapper.desiredSize),this.updateConnectorAnnotation(e),this.updateConnectorPort(e),this.updateConnectorfixedUserHandles(e),this.updateObject(e,i,r))),(r.sourcePoint||r.targetPoint||r.segments)&&this.diagramActions===ee.Render&&(h=!0),"Bpmn"===e.shape.type&&"Default"===e.shape.sequence&&"Sequence"===e.shape.flow&&this.commandHandler.updatePathElementOffset(e),s||this.updateBridging(),this.updateAnnotations(r,e),this.updateConnectorPorts(r,e),this.updatefixedUserHandle(r,e),e.wrapper.measure(new me(e.wrapper.width,e.wrapper.height)),e.wrapper.arrange(e.wrapper.desiredSize),!1===l.equals(l,e.wrapper.bounds)&&(this.updateQuad(e),"Drag"!==this.eventHandler.currentAction&&this.updateGroupSize(e)),!0===h&&this.checkSelectedItem(e)&&(!(this.diagramActions&ee.ToolAction)||this.diagramActions&ee.UndoRedo)&&this.updateSelector(),this.preventConnectorsUpdate||(!Ds(this)||Ds(this)&&this.scroller.oldCollectionObjects.indexOf(e.id)>-1)&&(this.diagramActions&ee.PreventZIndexOnDragging?this.updateDiagramObject(e,!0):this.updateDiagramObject(e)),this.updateConnectorEdges(e),this.diagramActions&&"New"!==e.status&&(e.status="Update"),this.triggerPropertyChange(o,e,i,r)},t.prototype.removePortEdges=function(e,i,r,s){if(e)for(var o=0;o0&&e.id===s[s.length-1].id&&(r=!0),r},t.prototype.updateDiagramContainerVisibility=function(e,i){if(e instanceof Cs)for(var r=0;r>"),r instanceof es&&this.updateAnnotationWrapper(r,s,o,a)),void 0!==e.template&&(r.content=e.template,this.updateAnnotationWrapper(r,s,o,a))},t.prototype.updateAnnotationWrapper=function(e,i,r,s){for(var o=0,a=this.views;o=0&&this.nodes.splice(s,1),delete this.nameTable[""+r]}var o=this.nodes.indexOf(this.nameTable[this.currentSymbol.id]);o>=0&&this.nodes.splice(o,1)}},t.prototype.selectDragedNode=function(e,i,r){this.currentSymbol=e,"SVG"!==this.mode&&this.refreshDiagramLayer(),this.commandHandler.oldSelectedObjects=am(this),this.commandHandler.select(e),this.eventHandler.mouseDown(i.event),this.eventHandler.mouseMove(i.event,i),this.preventDiagramUpdate=!1,this.updatePage(),r.style.opacity="0"},t.prototype.initDroppables=function(){var s,o,e=this,i={},r={},a="selectedSymbols";this.droppable=new lR(this.element);var l=5;this.droppable.over=function(h){if(e.rulerSettings.showRulers){var c=document.getElementById(e.element.id+"_vRuler"),d=parseFloat(c.style.width);l=d+1}if(0===e.previousSelectedObjects.length&&!e.currentSymbol&&(e.previousSelectedObjects=e.commandHandler.getSelectedObject()),e.commandHandler.PreventConnectorSplit=!0,e.currentSymbol)h.event.touches&&h.event.touches.length&&e.eventHandler.mouseMove(h.event,h.event.touches);else{var u=null;if(!h.dragData&&"drag"===h.name){var f=document.getElementsByClassName("e-dragclone")[0];f&&(u=f)}if(h.dragData||u){var p=void 0,g=void 0;document.getElementById(e.element.id+"content").focus();var v=e.eventHandler.getMousePosition(h.event),y=void 0,S=u||h.dragData.helper,b=S.getAttribute("paletteId"),M=void 0,w=void 0,C=void 0,D=void 0;if(!b&&h.dragData){e.triggerEvent(Ce.dragEnter,A={source:null,element:p,cancel:!1,diagram:e,dragData:h.dragData.draggedElement.ej2_instances[0].dragData,dragItem:p});var x=void 0,P=void 0;if(A.dragItem){if(A.dragItem.sourcePoint&&A.dragItem.targetPoint?P=new de(e,"connectors",A.dragItem,!0):x=new te(e,"nodes",A.dragItem,!0),e.initObject(p=x||P,void 0,void 0,!0),e.enterObject=p,e.enterTable=r,p instanceof te)x.offsetX=v.x+5+x.width*x.pivot.x,x.offsetY=v.y+x.height*x.pivot.y;else if(p instanceof de){var L=Ne.toBounds([p.sourcePoint,p.targetPoint]),O=v.x-L.left,N=v.y-L.top;p.sourcePoint.x+=O,p.sourcePoint.y+=N,p.targetPoint.x+=O,p.targetPoint.y+=N}e.preventDiagramUpdate=!0,e.currentSymbol=p,"SVG"!==e.mode&&e.refreshDiagramLayer(),e.selectDragedNode(p,h,S),delete e.enterObject,delete e.enterTable,e.droppable[""+a]=S,e.allowServerDataBinding=!0}}if(b){var T=document.getElementById(b).ej2_instances[0];if(e.droppable.sourceElement=T,T){var B=T[""+a];e.allowServerDataBinding=!1,y=$(T[""+a]),i=T.childTable;var j=B.wrapper.children[0].children[0];if(D=function $se(n,t,e){var i=AF(n,t,e,"width"),r=AF(n,t,e,"height");return new me(i,r)}(T,y,j),T[""+a]instanceof te){"TextAnnotation"===B.shape.shape?(y.offsetX=v.x+11+D.width*y.pivot.x,y.offsetY=v.y+11+D.height*y.pivot.y):(y.offsetX=v.x+5+D.width*y.pivot.x,y.offsetY=v.y+D.height*y.pivot.y),"Bpmn"===(x=new te(e,"nodes",y,!0)).shape.type&&x.shape.activity.subProcess.processes&&x.shape.activity.subProcess.processes.length&&(x.shape.activity.subProcess.processes=[]),w=x.previewSize,C=T.symbolDragSize;var Q=T.symbolPreview;if(x.width=(M=x.dragSize).width||C.width||w.width||Q.width||x.width,x.height=M.height||C.height||w.height||Q.height||x.height,"SwimLane"===x.shape.type){if(e.diagramActions|=ee.PreventHistory,x.shape.isLane){x.children=[],s={id:"header"+Qe()},"Horizontal"===x.shape.orientation?(s.width=x.shape.lanes[0].header.width,s.height=x.shape.lanes[0].height):(s.width=x.shape.lanes[0].width,s.height=x.shape.lanes[0].header.height),s.style=x.shape.lanes[0].header.style,s.offsetX=v.x+l+s.width/2,s.offsetY=v.y+s.height/2,e.diagramActions|=ee.PreventCollectionChangeOnDragOver,s=e.add(s),o={id:"body"+Qe()},"Horizontal"===x.shape.orientation?(o.width=x.shape.lanes[0].width-s.width,o.height=x.shape.lanes[0].height,o.offsetX=v.x+l+(x.shape.lanes[0].header.width+o.width/2),o.offsetY=v.y+o.height/2):(o.width=x.shape.lanes[0].width,o.height=x.shape.lanes[0].height-s.height,o.offsetX=v.x+l+o.width/2,o.offsetY=v.y+(x.shape.lanes[0].header.height+o.height/2)),o.style=x.shape.lanes[0].style,o=e.add(o);var oe={id:"group"+Qe(),children:[s.id,o.id]};oe.shape=x.shape,oe.width=x.shape.lanes[0].width,oe.height=x.shape.lanes[0].height,oe.previewSize=x.previewSize,oe.dragSize=x.dragSize,oe.addInfo=x.addInfo,x=e.add(oe),e.diagramActions&=~ee.PreventCollectionChangeOnDragOver}e.diagramActions&=~ee.PreventHistory}if(x.shape.isPhase&&((g="Horizontal"===x.shape.orientation)?(x.offsetX=v.x+l+(x.width||j.actualSize.width)/2,x.offsetY=v.y,x.shape.data="M20,"+x.height/2+" L"+(x.width-20)+","+x.height/2+"z",x.height=1):(x.offsetX=v.x+5,x.offsetY=v.y+(x.height||j.actualSize.height)/2,x.shape.data="M"+x.width/2+",20 L"+x.width/2+","+(x.height-20)+"z",x.width=1)),"UmlClassifier"===x.shape.type&&(x.children=x.width=x.height=void 0,y.children=void 0,"Class"===x.shape.classifier&&x.shape.classShape.methods.length<=0&&x.shape.classShape.attributes.length<=0&&(x.shape.classShape.attributes=[{name:"Name",type:"Type",style:{}}]),"Enumeration"===x.shape.classifier&&x.shape.enumerationShape.members.length<=0&&(x.shape.enumerationShape.members=[{name:"Name"}]),"Interface"===x.shape.classifier&&x.shape.interfaceShape.methods.length<=0&&x.shape.interfaceShape.attributes.length<=0&&(x.shape.interfaceShape.attributes=[{name:"Name",type:"Type",style:{}}])),p=x,y.children){var ue=y;r=e.getChildren(ue,{},i),rT(ue,-ue.offsetX,-ue.offsetY,r,!0,e)}}else if(T[""+a]instanceof de){p=new de(e,"connectors",y,!0);var Me=Ne.toBounds([p.sourcePoint,p.targetPoint]),De=v.x-Me.left,xe=v.y-Me.top;p.sourcePoint.x+=De,p.sourcePoint.y+=xe,p.targetPoint.x+=De,p.targetPoint.y+=xe}p.shape.isLane||(p.id+=Qe());var A={source:T,element:p,cancel:!1,diagram:e,dragData:null,dragItem:p};if(e.enterObject=p,e.enterTable=r,e.triggerEvent(Ce.dragEnter,A),p instanceof te&&"SwimLane"===p.shape.type&&p.shape.isLane){var Ie=A.element,Ve=Ie.shape.lanes[0];g="Horizontal"===Ie.shape.orientation;var ot=e.nameTable[p.children[0]],$e=e.nameTable[p.children[1]];w=p.previewSize,C=T.symbolDragSize,Ve.width=(M=p.dragSize).width||C.width||w.width||Ve.width,Ve.height=M.height||C.height||w.height||Ve.height,g?(s.width=Ve.header.width,s.height=Ve.height,o.width=Ve.width-s.width,o.height=Ve.height,o.offsetX=v.x+l+(Ve.header.width+$e.width/2),o.offsetY=v.y+$e.height/2):(s.width=Ve.width,s.height=Ve.header.height,o.width=Ve.width,o.height=Ve.height-s.height,o.offsetX=v.x+l+$e.width/2,o.offsetY=v.y+(Ve.header.height+$e.height/2)),s.offsetX=v.x+l+ot.width/2,s.offsetY=v.y+ot.height/2,p.width=Ve.width,p.height=Ve.height}if(p instanceof te&&p.shape.isPhase&&(g?p.height=1:p.width=1),!e.activeLayer.lock&&!A.cancel){if(e.preventDiagramUpdate=!0,p.children&&e.findChild(p,r),e.preventDiagramUpdate=!0,p.zIndex!==Number.MIN_VALUE&&(p.zIndex=Number.MIN_VALUE),e.initObject(p,void 0,void 0,!0),e.bpmnModule)for(var Ci=0;Ci0&&(S.segments=[]),d=this.add(S,!0)),(S||d)&&(Vv(this)||Wv(this))&&this.select([this.nameTable[S[""+b]]],!1,this.previousSelectedObjects),y.target&&y.target instanceof de&&!0===this.enableConnectorSplit&&this.nameTable[S[""+b]]instanceof te&&(this.commandHandler.connectorSplit(this.nameTable[S[""+b]],y.target),this.commandHandler.PreventConnectorSplit=!1))),this.protectPropertyChange(!1),v=this.nameTable[S[""+b]],S.hasTarget&&(S.nodeId=S.hasTarget,this.remove(S)),this.bpmnModule&&v instanceof te&&S.processId&&(v.processId=S.processId,this.bpmnModule.dropBPMNchild(this.nameTable[v.processId],v,this)),y.cancel||this.endGroupAction(),"SVG"!==this.mode&&this.refreshDiagramLayer(),delete this.droppable[""+c]):(this.triggerEvent(Ce.drop,y={source:h.droppedElement,element:void 0,target:this.eventHandler.hoverNode||this.eventHandler.lastObjectUnderMouse||this,cancel:!1,position:void 0}),S=void 0,b="id"),this.droppable[M="selectedSymbols"]&&this.droppable[""+M].parentNode)gt(this.droppable[""+M]);else for(w=document.getElementsByClassName("e-dragclone"),C=0;C0)for(var f=0;f1),e.previousSelectedObject=null}}},t.prototype.getDropEventArgs=function(e){if(this.eventHandler.lastObjectUnderMouse||this.eventHandler.hoverNode){var i=this.eventHandler.lastObjectUnderMouse||this.eventHandler.hoverNode;e.target=ps(i)===de?{connector:i}:{node:i}}else e.target.diagramId=this.element.id},t.prototype.removeChildInNodes=function(e){if(e){if(e.children)for(var i=0;i1){var l=2;if(e.children&&e.children.length>0)for(;e.children.indexOf(i.objects[s-l])>-1;)l++;this.commandHandler.moveSvgNode(e.id,i.objects[s-l]),this.commandHandler.moveSvgNode(i.objects[s-l],e.id)}else if(o){var h=this.commandHandler.getLayer(this.layerZIndexTable[o.zIndex]).objects[0];h?(this.commandHandler.moveSvgNode(e.id,h),this.commandHandler.updateNativeNodeIndex(e.id,h)):this.moveObjectsUp(e,i)}else this.moveObjectsUp(e,i)},t.prototype.moveObjectsUp=function(e,i){for(var r,s=this.layers.length-1;s>=0;s--)if(r=this.layers[parseInt(s.toString(),10)],i.id!==r.id){var o=this.commandHandler.getLayer(this.layerZIndexTable[r.zIndex]).objects[r.objects.length-1];if(o){this.commandHandler.moveSvgNode(e.id,o),this.commandHandler.moveSvgNode(o,e.id);break}}},t.prototype.insertData=function(e){return this.crudOperation(e,"create",this.getNewUpdateNodes("New"))},t.prototype.updateData=function(e){return this.crudOperation(e,"update",this.getNewUpdateNodes("Update"))},t.prototype.removeData=function(e){return this.crudOperation(e,"destroy",this.getDeletedNodes())},t.prototype.crudOperation=function(e,i,r){if(e){var s=this.parameterMap(e,!(e instanceof de));if(s){var o=e instanceof de?this.dataSourceSettings.connectionDataSource.crudAction[""+i]:this.dataSourceSettings.crudAction[""+i];this.raiseAjaxPost(JSON.stringify(s),o)}return s}var a=r;return this.processCrudCollection(a,this.dataSourceSettings.crudAction[""+i],this.dataSourceSettings.connectionDataSource.crudAction[""+i]),a},t.prototype.processCrudCollection=function(e,i,r){if(e.nodes){var s=[],o=void 0;for(o=0;o0&&this.raiseAjaxPost(JSON.stringify(s),i)}if(e.connectors){for(s=[],o=void 0,o=0;o0&&this.raiseAjaxPost(JSON.stringify(s),r)}},t.prototype.parameterMap=function(e,i){var s,r={},o=i?this.dataSourceSettings:this.dataSourceSettings.connectionDataSource;if(o.id&&(r[o.id]=e.id),o.sourcePointX&&o.sourcePointY&&(r[o.sourcePointX]=e.sourcePoint.x,r[o.sourcePointY]=e.sourcePoint.y),o.targetPointX&&o.targetPointY&&(r[o.targetPointX]=e.targetPoint.x,r[o.targetPointY]=e.targetPoint.y),o.sourceID&&(r[o.sourceID]=e.sourceID),o.targetID&&(r[o.targetID]=e.targetID),o.crudAction&&o.crudAction.customFields&&o.crudAction.customFields.length>0)for(s=0;s{class n extends ph{constructor(e){super(),this.viewContainerRef=e,ml("currentInstance",this,this.viewContainerRef),this.registerEvents($ae),this.directivePropList=qae}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-layer"]],inputs:{addInfo:"addInfo",id:"id",lock:"lock",objects:"objects",visible:"visible",zIndex:"zIndex"},features:[yn]}),n})(),Jae=(()=>{class n extends gh{constructor(){super("layers")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-layers"]],contentQueries:function(e,i,r){if(1&e&&dn(r,Zae,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),Kae=["action","cursor"],ele=[],tle=(()=>{class n extends ph{constructor(e){super(),this.viewContainerRef=e,ml("currentInstance",this,this.viewContainerRef),this.registerEvents(ele),this.directivePropList=Kae}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-cursormap"]],inputs:{action:"action",cursor:"cursor"},features:[yn]}),n})(),ile=(()=>{class n extends gh{constructor(){super("customcursor")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-cursormaps"]],contentQueries:function(e,i,r){if(1&e&&dn(r,tle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),rle=["alignment","cornerRadius","displacement","fill","handleStrokeColor","handleStrokeWidth","height","iconStrokeColor","iconStrokeWidth","id","offset","padding","pathData","tooltip","visibility","width"],nle=[],sle=(()=>{class n extends ph{constructor(e){super(),this.viewContainerRef=e,ml("currentInstance",this,this.viewContainerRef),this.registerEvents(nle),this.directivePropList=rle}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-connector-fixeduserhandle"]],inputs:{alignment:"alignment",cornerRadius:"cornerRadius",displacement:"displacement",fill:"fill",handleStrokeColor:"handleStrokeColor",handleStrokeWidth:"handleStrokeWidth",height:"height",iconStrokeColor:"iconStrokeColor",iconStrokeWidth:"iconStrokeWidth",id:"id",offset:"offset",padding:"padding",pathData:"pathData",tooltip:"tooltip",visibility:"visibility",width:"width"},features:[yn]}),n})(),ole=(()=>{class n extends gh{constructor(){super("fixeduserhandles")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-connector-fixeduserhandles"]],contentQueries:function(e,i,r){if(1&e&&dn(r,sle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),ale=["addInfo","alignment","annotationType","constraints","content","displacement","dragLimit","height","horizontalAlignment","hyperlink","id","margin","offset","rotateAngle","rotationReference","segmentAngle","style","template","tooltip","type","verticalAlignment","visibility","width"],lle=[],hle=(()=>{class n extends ph{constructor(e){super(),this.viewContainerRef=e,ml("currentInstance",this,this.viewContainerRef),this.registerEvents(lle),this.directivePropList=ale}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-connector-annotation"]],inputs:{addInfo:"addInfo",alignment:"alignment",annotationType:"annotationType",constraints:"constraints",content:"content",displacement:"displacement",dragLimit:"dragLimit",height:"height",horizontalAlignment:"horizontalAlignment",hyperlink:"hyperlink",id:"id",margin:"margin",offset:"offset",rotateAngle:"rotateAngle",rotationReference:"rotationReference",segmentAngle:"segmentAngle",style:"style",template:"template",tooltip:"tooltip",type:"type",verticalAlignment:"verticalAlignment",visibility:"visibility",width:"width"},features:[yn]}),n})(),cle=(()=>{class n extends gh{constructor(){super("annotations")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-connector-annotations"]],contentQueries:function(e,i,r){if(1&e&&dn(r,hle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),dle=["addInfo","allowNodeOverlap","annotations","bezierSettings","bridgeSpace","connectionPadding","connectorSpacing","constraints","cornerRadius","dragSize","excludeFromLayout","fixedUserHandles","flip","flipMode","hitPadding","id","margin","maxSegmentThumb","ports","previewSize","segmentThumbShape","segmentThumbSize","segments","shape","sourceDecorator","sourceID","sourcePadding","sourcePoint","sourcePortID","style","symbolInfo","targetDecorator","targetID","targetPadding","targetPoint","targetPortID","tooltip","type","visible","wrapper","zIndex"],ule=[],fle=(()=>{class n extends ph{constructor(e){super(),this.viewContainerRef=e,this.tags=["fixedUserHandles","annotations"],ml("currentInstance",this,this.viewContainerRef),this.registerEvents(ule),this.directivePropList=dle}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-connector"]],contentQueries:function(e,i,r){if(1&e&&(dn(r,ole,5),dn(r,cle,5)),2&e){let s;Kr(s=en())&&(i.childFixedUserHandles=s.first),Kr(s=en())&&(i.childAnnotations=s.first)}},inputs:{addInfo:"addInfo",allowNodeOverlap:"allowNodeOverlap",annotations:"annotations",bezierSettings:"bezierSettings",bridgeSpace:"bridgeSpace",connectionPadding:"connectionPadding",connectorSpacing:"connectorSpacing",constraints:"constraints",cornerRadius:"cornerRadius",dragSize:"dragSize",excludeFromLayout:"excludeFromLayout",fixedUserHandles:"fixedUserHandles",flip:"flip",flipMode:"flipMode",hitPadding:"hitPadding",id:"id",margin:"margin",maxSegmentThumb:"maxSegmentThumb",ports:"ports",previewSize:"previewSize",segmentThumbShape:"segmentThumbShape",segmentThumbSize:"segmentThumbSize",segments:"segments",shape:"shape",sourceDecorator:"sourceDecorator",sourceID:"sourceID",sourcePadding:"sourcePadding",sourcePoint:"sourcePoint",sourcePortID:"sourcePortID",style:"style",symbolInfo:"symbolInfo",targetDecorator:"targetDecorator",targetID:"targetID",targetPadding:"targetPadding",targetPoint:"targetPoint",targetPortID:"targetPortID",tooltip:"tooltip",type:"type",visible:"visible",wrapper:"wrapper",zIndex:"zIndex"},features:[yn]}),n})(),ple=(()=>{class n extends gh{constructor(){super("connectors")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-connectors"]],contentQueries:function(e,i,r){if(1&e&&dn(r,fle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),gle=["cornerRadius","fill","handleStrokeColor","handleStrokeWidth","height","iconStrokeColor","iconStrokeWidth","id","margin","offset","padding","pathData","tooltip","visibility","width"],vle=[],mle=(()=>{class n extends ph{constructor(e){super(),this.viewContainerRef=e,ml("currentInstance",this,this.viewContainerRef),this.registerEvents(vle),this.directivePropList=gle}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-node-fixeduserhandle"]],inputs:{cornerRadius:"cornerRadius",fill:"fill",handleStrokeColor:"handleStrokeColor",handleStrokeWidth:"handleStrokeWidth",height:"height",iconStrokeColor:"iconStrokeColor",iconStrokeWidth:"iconStrokeWidth",id:"id",margin:"margin",offset:"offset",padding:"padding",pathData:"pathData",tooltip:"tooltip",visibility:"visibility",width:"width"},features:[yn]}),n})(),yle=(()=>{class n extends gh{constructor(){super("fixeduserhandles")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-node-fixeduserhandles"]],contentQueries:function(e,i,r){if(1&e&&dn(r,mle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),Sle=["addInfo","annotationType","constraints","content","dragLimit","height","horizontalAlignment","hyperlink","id","margin","offset","rotateAngle","rotationReference","style","template","tooltip","type","verticalAlignment","visibility","width"],Ile=[],v_=(()=>{class n extends ph{constructor(e){super(),this.viewContainerRef=e,ml("currentInstance",this,this.viewContainerRef),this.registerEvents(Ile),this.directivePropList=Sle}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-node-annotation"]],inputs:{addInfo:"addInfo",annotationType:"annotationType",constraints:"constraints",content:"content",dragLimit:"dragLimit",height:"height",horizontalAlignment:"horizontalAlignment",hyperlink:"hyperlink",id:"id",margin:"margin",offset:"offset",rotateAngle:"rotateAngle",rotationReference:"rotationReference",style:"style",template:"template",tooltip:"tooltip",type:"type",verticalAlignment:"verticalAlignment",visibility:"visibility",width:"width"},features:[yn]}),n})(),m_=(()=>{class n extends gh{constructor(){super("annotations")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-node-annotations"]],contentQueries:function(e,i,r){if(1&e&&dn(r,v_,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),ble=["addInfo","connectionDirection","constraints","height","horizontalAlignment","id","inEdges","margin","offset","outEdges","pathData","shape","style","tooltip","verticalAlignment","visibility","width"],Mle=[],wle=(()=>{class n extends ph{constructor(e){super(),this.viewContainerRef=e,ml("currentInstance",this,this.viewContainerRef),this.registerEvents(Mle),this.directivePropList=ble}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-node-port"]],inputs:{addInfo:"addInfo",connectionDirection:"connectionDirection",constraints:"constraints",height:"height",horizontalAlignment:"horizontalAlignment",id:"id",inEdges:"inEdges",margin:"margin",offset:"offset",outEdges:"outEdges",pathData:"pathData",shape:"shape",style:"style",tooltip:"tooltip",verticalAlignment:"verticalAlignment",visibility:"visibility",width:"width"},features:[yn]}),n})(),Cle=(()=>{class n extends gh{constructor(){super("ports")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-node-ports"]],contentQueries:function(e,i,r){if(1&e&&dn(r,wle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),Ele=["addInfo","annotations","backgroundColor","borderColor","borderWidth","branch","children","collapseIcon","columnIndex","columnSpan","columns","constraints","container","data","dragSize","excludeFromLayout","expandIcon","fixedUserHandles","flip","flipMode","height","horizontalAlignment","id","isExpanded","layoutInfo","margin","maxHeight","maxWidth","minHeight","minWidth","offsetX","offsetY","padding","pivot","ports","previewSize","rotateAngle","rowIndex","rowSpan","rows","shadow","shape","style","symbolInfo","tooltip","verticalAlignment","visible","width","wrapper","zIndex"],Dle=[],y_=(()=>{class n extends ph{constructor(e){super(),this.viewContainerRef=e,this.tags=["fixedUserHandles","annotations","ports"],ml("currentInstance",this,this.viewContainerRef),this.registerEvents(Dle),this.directivePropList=Ele}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-node"]],contentQueries:function(e,i,r){if(1&e&&(dn(r,yle,5),dn(r,m_,5),dn(r,Cle,5)),2&e){let s;Kr(s=en())&&(i.childFixedUserHandles=s.first),Kr(s=en())&&(i.childAnnotations=s.first),Kr(s=en())&&(i.childPorts=s.first)}},inputs:{addInfo:"addInfo",annotations:"annotations",backgroundColor:"backgroundColor",borderColor:"borderColor",borderWidth:"borderWidth",branch:"branch",children:"children",collapseIcon:"collapseIcon",columnIndex:"columnIndex",columnSpan:"columnSpan",columns:"columns",constraints:"constraints",container:"container",data:"data",dragSize:"dragSize",excludeFromLayout:"excludeFromLayout",expandIcon:"expandIcon",fixedUserHandles:"fixedUserHandles",flip:"flip",flipMode:"flipMode",height:"height",horizontalAlignment:"horizontalAlignment",id:"id",isExpanded:"isExpanded",layoutInfo:"layoutInfo",margin:"margin",maxHeight:"maxHeight",maxWidth:"maxWidth",minHeight:"minHeight",minWidth:"minWidth",offsetX:"offsetX",offsetY:"offsetY",padding:"padding",pivot:"pivot",ports:"ports",previewSize:"previewSize",rotateAngle:"rotateAngle",rowIndex:"rowIndex",rowSpan:"rowSpan",rows:"rows",shadow:"shadow",shape:"shape",style:"style",symbolInfo:"symbolInfo",tooltip:"tooltip",verticalAlignment:"verticalAlignment",visible:"visible",width:"width",wrapper:"wrapper",zIndex:"zIndex"},features:[yn]}),n})(),S_=(()=>{class n extends gh{constructor(){super("nodes")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-nodes"]],contentQueries:function(e,i,r){if(1&e&&dn(r,y_,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})();const xle=["animationComplete","click","collectionChange","commandExecute","connectionChange","contextMenuBeforeItemRender","contextMenuClick","contextMenuOpen","created","dataLoaded","doubleClick","dragEnter","dragLeave","dragOver","drop","elementDraw","expandStateChange","fixedUserHandleClick","historyChange","historyStateChange","keyDown","keyUp","load","loaded","mouseEnter","mouseLeave","mouseOver","mouseWheel","onFixedUserHandleMouseDown","onFixedUserHandleMouseEnter","onFixedUserHandleMouseLeave","onFixedUserHandleMouseUp","onImageLoad","onUserHandleMouseDown","onUserHandleMouseEnter","onUserHandleMouseLeave","onUserHandleMouseUp","positionChange","propertyChange","rotateChange","scrollChange","segmentChange","segmentCollectionChange","selectionChange","sizeChange","sourcePointChange","targetPointChange","textEdit"],Tle=[""];let Ale=(()=>{let n=class extends _l{constructor(e,i,r,s){super(),this.ngEle=e,this.srenderer=i,this.viewContainerRef=r,this.injector=s,this.tags=["layers","customCursor","connectors","nodes"],this.element=this.ngEle.nativeElement,this.injectedModules=this.injectedModules||[];try{let o=this.injector.get("DiagramsHierarchicalTree");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsMindMap");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsRadialTree");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsComplexHierarchicalTree");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsDataBinding");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsSnapping");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsPrintAndExport");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsBpmnDiagrams");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsSymmetricLayout");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsConnectorBridging");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsUndoRedo");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsLayoutAnimation");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsDiagramContextMenu");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsLineRouting");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsConnectorEditing");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsLineDistribution");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsEj1Serialization");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsFlowchartLayout");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}this.registerEvents(xle),this.addTwoWay.call(this,Tle),ml("currentInstance",this,this.viewContainerRef),this.context=new SR}ngOnInit(){this.context.ngOnInit(this)}ngAfterViewInit(){this.context.ngAfterViewInit(this)}ngOnDestroy(){this.context.ngOnDestroy(this)}ngAfterContentChecked(){this.tagObjects[0].instance=this.childLayers,this.childCustomCursor&&(this.tagObjects[1].instance=this.childCustomCursor),this.childConnectors&&(this.tagObjects[2].instance=this.childConnectors),this.childNodes&&(this.tagObjects[3].instance=this.childNodes),this.context.ngAfterContentChecked(this)}};return n.\u0275fac=function(e){return new(e||n)(Ot($c),Ot(cM),Ot(An),Ot(Wo))},n.\u0275cmp=_b({type:n,selectors:[["ejs-diagram"]],contentQueries:function(e,i,r){if(1&e&&(dn(r,Qae,5),dn(r,Gae,5),dn(r,Xae,5),dn(r,Jae,5),dn(r,ile,5),dn(r,ple,5),dn(r,S_,5)),2&e){let s;Kr(s=en())&&(i.annotationTemplate=s.first),Kr(s=en())&&(i.nodeTemplate=s.first),Kr(s=en())&&(i.userHandleTemplate=s.first),Kr(s=en())&&(i.childLayers=s.first),Kr(s=en())&&(i.childCustomCursor=s.first),Kr(s=en())&&(i.childConnectors=s.first),Kr(s=en())&&(i.childNodes=s.first)}},inputs:{addInfo:"addInfo",annotationTemplate:"annotationTemplate",backgroundColor:"backgroundColor",bridgeDirection:"bridgeDirection",commandManager:"commandManager",connectorDefaults:"connectorDefaults",connectors:"connectors",constraints:"constraints",contextMenuSettings:"contextMenuSettings",customCursor:"customCursor",dataSourceSettings:"dataSourceSettings",diagramSettings:"diagramSettings",drawingObject:"drawingObject",enableConnectorSplit:"enableConnectorSplit",enablePersistence:"enablePersistence",enableRtl:"enableRtl",fixedUserHandleTemplate:"fixedUserHandleTemplate",getConnectorDefaults:"getConnectorDefaults",getCustomCursor:"getCustomCursor",getCustomProperty:"getCustomProperty",getCustomTool:"getCustomTool",getDescription:"getDescription",getNodeDefaults:"getNodeDefaults",height:"height",historyManager:"historyManager",layers:"layers",layout:"layout",locale:"locale",mode:"mode",nodeDefaults:"nodeDefaults",nodeTemplate:"nodeTemplate",nodes:"nodes",pageSettings:"pageSettings",rulerSettings:"rulerSettings",scrollSettings:"scrollSettings",segmentThumbShape:"segmentThumbShape",segmentThumbSize:"segmentThumbSize",selectedItems:"selectedItems",serializationSettings:"serializationSettings",setNodeTemplate:"setNodeTemplate",snapSettings:"snapSettings",tool:"tool",tooltip:"tooltip",updateSelection:"updateSelection",userHandleTemplate:"userHandleTemplate",width:"width"},outputs:{animationComplete:"animationComplete",click:"click",collectionChange:"collectionChange",commandExecute:"commandExecute",connectionChange:"connectionChange",contextMenuBeforeItemRender:"contextMenuBeforeItemRender",contextMenuClick:"contextMenuClick",contextMenuOpen:"contextMenuOpen",created:"created",dataLoaded:"dataLoaded",doubleClick:"doubleClick",dragEnter:"dragEnter",dragLeave:"dragLeave",dragOver:"dragOver",drop:"drop",elementDraw:"elementDraw",expandStateChange:"expandStateChange",fixedUserHandleClick:"fixedUserHandleClick",historyChange:"historyChange",historyStateChange:"historyStateChange",keyDown:"keyDown",keyUp:"keyUp",load:"load",loaded:"loaded",mouseEnter:"mouseEnter",mouseLeave:"mouseLeave",mouseOver:"mouseOver",mouseWheel:"mouseWheel",onFixedUserHandleMouseDown:"onFixedUserHandleMouseDown",onFixedUserHandleMouseEnter:"onFixedUserHandleMouseEnter",onFixedUserHandleMouseLeave:"onFixedUserHandleMouseLeave",onFixedUserHandleMouseUp:"onFixedUserHandleMouseUp",onImageLoad:"onImageLoad",onUserHandleMouseDown:"onUserHandleMouseDown",onUserHandleMouseEnter:"onUserHandleMouseEnter",onUserHandleMouseLeave:"onUserHandleMouseLeave",onUserHandleMouseUp:"onUserHandleMouseUp",positionChange:"positionChange",propertyChange:"propertyChange",rotateChange:"rotateChange",scrollChange:"scrollChange",segmentChange:"segmentChange",segmentCollectionChange:"segmentCollectionChange",selectionChange:"selectionChange",sizeChange:"sizeChange",sourcePointChange:"sourcePointChange",targetPointChange:"targetPointChange",textEdit:"textEdit"},features:[yn],decls:0,vars:0,template:function(e,i){},encapsulation:2,changeDetection:0}),k0([xC()],n.prototype,"annotationTemplate",void 0),k0([xC()],n.prototype,"nodeTemplate",void 0),k0([xC()],n.prototype,"userHandleTemplate",void 0),n=k0([PZ([SR])],n),n})(),Lle=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=km({type:n}),n.\u0275inj=yp({imports:[[sq]]}),n})();const Nle=["diagram"];let Ole=(()=>{class n{constructor(){this.layers=[]}ngOnInit(){this.layers=[{id:"layer1",objects:["node1","node2"]},{id:"layers2",objects:["node3"]}]}moveObjects(){this.diagram.moveObjects(["node1"],"layer2"),console.log(this.layers)}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275cmp=_b({type:n,selectors:[["app-container"]],viewQuery:function(i,r){if(1&i&&function uP(n,t,e){const i=Ti();i.firstCreatePass&&(cP(i,new aP(n,t,e),-1),2==(2&t)&&(i.staticViewQueries=!0)),hP(i,Se(),t)}(Nle,5),2&i){let s;Kr(s=en())&&(r.diagram=s.first)}},standalone:!0,features:[PP([]),RP],decls:14,vars:13,consts:[[3,"click"],["id","diagram","width","100%","height","580px",3,"layers"],["diagram",""],["id","node1",3,"width","height","offsetX","offsetY"],["content","Layer 1 Object"],["id","node2",3,"width","height","offsetX","offsetY"],["id","node3",3,"width","height","offsetX","offsetY"],["content","Layer 2 Object"]],template:function(i,r){1&i&&(id(0,"button",0),lw("click",function(){return r.moveObjects()}),function MP(n,t=""){const e=Se(),i=Ti(),r=n+jt,s=i.firstCreatePass?Lu(i,r,1,t,null):i.data[r],o=wP(i,e,s,t,n);e[r]=o,_m()&&uy(i,e,o,s),ll(s,!1)}(1,"moveObjects"),rd(),id(2,"ejs-diagram",1,2)(4,"e-nodes")(5,"e-node",3)(6,"e-node-annotations"),ug(7,"e-node-annotation",4),rd()(),id(8,"e-node",5)(9,"e-node-annotations"),ug(10,"e-node-annotation",4),rd()(),id(11,"e-node",6)(12,"e-node-annotations"),ug(13,"e-node-annotation",7),rd()()()()),2&i&&(Xp(2),qu("layers",r.layers),Xp(3),qu("width",100)("height",100)("offsetX",100)("offsetY",100),Xp(3),qu("width",100)("height",100)("offsetX",100)("offsetY",300),Xp(3),qu("width",100)("height",100)("offsetX",300)("offsetY",300))},dependencies:[Lle,Ale,v_,m_,y_,S_],encapsulation:2})}}return n})();Wd(332),function $q(n,t){return DG({rootComponent:n,...Ez(t)})}(Ole).catch(n=>console.error(n))},332:()=>{!function(Z){const se=Z.performance;function ye(zi){se&&se.mark&&se.mark(zi)}function pe(zi,ht){se&&se.measure&&se.measure(zi,ht)}ye("Zone");const be=Z.__Zone_symbol_prefix||"__zone_symbol__";function ke(zi){return be+zi}const at=!0===Z[ke("forceDuplicateZoneCheck")];if(Z.Zone){if(at||"function"!=typeof Z.Zone.__symbol__)throw new Error("Zone already loaded.");return Z.Zone}let tt=(()=>{class zi{static{this.__symbol__=ke}static assertZonePatched(){if(Z.Promise!==_o.ZoneAwarePromise)throw new Error("Zone.js has detected that ZoneAwarePromise `(window|global).Promise` has been overwritten.\nMost likely cause is that a Promise polyfill has been loaded after Zone.js (Polyfilling Promise api is not necessary when zone.js is loaded. If you must load one, do so before loading zone.js.)")}static get root(){let F=zi.current;for(;F.parent;)F=F.parent;return F}static get current(){return Ur.zone}static get currentTask(){return Do}static __load_patch(F,ae,Et=!1){if(_o.hasOwnProperty(F)){if(!Et&&at)throw Error("Already loaded patch: "+F)}else if(!Z["__Zone_disable_"+F]){const Xt="Zone:"+F;ye(Xt),_o[F]=ae(Z,zi,cn),pe(Xt,Xt)}}get parent(){return this._parent}get name(){return this._name}constructor(F,ae){this._parent=F,this._name=ae?ae.name||"unnamed":"",this._properties=ae&&ae.properties||{},this._zoneDelegate=new Lt(this,this._parent&&this._parent._zoneDelegate,ae)}get(F){const ae=this.getZoneWith(F);if(ae)return ae._properties[F]}getZoneWith(F){let ae=this;for(;ae;){if(ae._properties.hasOwnProperty(F))return ae;ae=ae._parent}return null}fork(F){if(!F)throw new Error("ZoneSpec required!");return this._zoneDelegate.fork(this,F)}wrap(F,ae){if("function"!=typeof F)throw new Error("Expecting function got: "+F);const Et=this._zoneDelegate.intercept(this,F,ae),Xt=this;return function(){return Xt.runGuarded(Et,this,arguments,ae)}}run(F,ae,Et,Xt){Ur={parent:Ur,zone:this};try{return this._zoneDelegate.invoke(this,F,ae,Et,Xt)}finally{Ur=Ur.parent}}runGuarded(F,ae=null,Et,Xt){Ur={parent:Ur,zone:this};try{try{return this._zoneDelegate.invoke(this,F,ae,Et,Xt)}catch(Vn){if(this._zoneDelegate.handleError(this,Vn))throw Vn}}finally{Ur=Ur.parent}}runTask(F,ae,Et){if(F.zone!=this)throw new Error("A task can only be run in the zone of creation! (Creation: "+(F.zone||jn).name+"; Execution: "+this.name+")");if(F.state===sr&&(F.type===rs||F.type===Pt))return;const Xt=F.state!=lt;Xt&&F._transitionTo(lt,Pi),F.runCount++;const Vn=Do;Do=F,Ur={parent:Ur,zone:this};try{F.type==Pt&&F.data&&!F.data.isPeriodic&&(F.cancelFn=void 0);try{return this._zoneDelegate.invokeTask(this,F,ae,Et)}catch(Ue){if(this._zoneDelegate.handleError(this,Ue))throw Ue}}finally{F.state!==sr&&F.state!==et&&(F.type==rs||F.data&&F.data.isPeriodic?Xt&&F._transitionTo(Pi,lt):(F.runCount=0,this._updateTaskCount(F,-1),Xt&&F._transitionTo(sr,lt,sr))),Ur=Ur.parent,Do=Vn}}scheduleTask(F){if(F.zone&&F.zone!==this){let Et=this;for(;Et;){if(Et===F.zone)throw Error(`can not reschedule task to ${this.name} which is descendants of the original zone ${F.zone.name}`);Et=Et.parent}}F._transitionTo(Zr,sr);const ae=[];F._zoneDelegates=ae,F._zone=this;try{F=this._zoneDelegate.scheduleTask(this,F)}catch(Et){throw F._transitionTo(et,Zr,sr),this._zoneDelegate.handleError(this,Et),Et}return F._zoneDelegates===ae&&this._updateTaskCount(F,1),F.state==Zr&&F._transitionTo(Pi,Zr),F}scheduleMicroTask(F,ae,Et,Xt){return this.scheduleTask(new pt(yi,F,ae,Et,Xt,void 0))}scheduleMacroTask(F,ae,Et,Xt,Vn){return this.scheduleTask(new pt(Pt,F,ae,Et,Xt,Vn))}scheduleEventTask(F,ae,Et,Xt,Vn){return this.scheduleTask(new pt(rs,F,ae,Et,Xt,Vn))}cancelTask(F){if(F.zone!=this)throw new Error("A task can only be cancelled in the zone of creation! (Creation: "+(F.zone||jn).name+"; Execution: "+this.name+")");if(F.state===Pi||F.state===lt){F._transitionTo(dr,Pi,lt);try{this._zoneDelegate.cancelTask(this,F)}catch(ae){throw F._transitionTo(et,dr),this._zoneDelegate.handleError(this,ae),ae}return this._updateTaskCount(F,-1),F._transitionTo(sr,dr),F.runCount=0,F}}_updateTaskCount(F,ae){const Et=F._zoneDelegates;-1==ae&&(F._zoneDelegates=null);for(let Xt=0;Xtzi.hasTask(F,ae),onScheduleTask:(zi,ht,F,ae)=>zi.scheduleTask(F,ae),onInvokeTask:(zi,ht,F,ae,Et,Xt)=>zi.invokeTask(F,ae,Et,Xt),onCancelTask:(zi,ht,F,ae)=>zi.cancelTask(F,ae)};class Lt{constructor(ht,F,ae){this._taskCounts={microTask:0,macroTask:0,eventTask:0},this.zone=ht,this._parentDelegate=F,this._forkZS=ae&&(ae&&ae.onFork?ae:F._forkZS),this._forkDlgt=ae&&(ae.onFork?F:F._forkDlgt),this._forkCurrZone=ae&&(ae.onFork?this.zone:F._forkCurrZone),this._interceptZS=ae&&(ae.onIntercept?ae:F._interceptZS),this._interceptDlgt=ae&&(ae.onIntercept?F:F._interceptDlgt),this._interceptCurrZone=ae&&(ae.onIntercept?this.zone:F._interceptCurrZone),this._invokeZS=ae&&(ae.onInvoke?ae:F._invokeZS),this._invokeDlgt=ae&&(ae.onInvoke?F:F._invokeDlgt),this._invokeCurrZone=ae&&(ae.onInvoke?this.zone:F._invokeCurrZone),this._handleErrorZS=ae&&(ae.onHandleError?ae:F._handleErrorZS),this._handleErrorDlgt=ae&&(ae.onHandleError?F:F._handleErrorDlgt),this._handleErrorCurrZone=ae&&(ae.onHandleError?this.zone:F._handleErrorCurrZone),this._scheduleTaskZS=ae&&(ae.onScheduleTask?ae:F._scheduleTaskZS),this._scheduleTaskDlgt=ae&&(ae.onScheduleTask?F:F._scheduleTaskDlgt),this._scheduleTaskCurrZone=ae&&(ae.onScheduleTask?this.zone:F._scheduleTaskCurrZone),this._invokeTaskZS=ae&&(ae.onInvokeTask?ae:F._invokeTaskZS),this._invokeTaskDlgt=ae&&(ae.onInvokeTask?F:F._invokeTaskDlgt),this._invokeTaskCurrZone=ae&&(ae.onInvokeTask?this.zone:F._invokeTaskCurrZone),this._cancelTaskZS=ae&&(ae.onCancelTask?ae:F._cancelTaskZS),this._cancelTaskDlgt=ae&&(ae.onCancelTask?F:F._cancelTaskDlgt),this._cancelTaskCurrZone=ae&&(ae.onCancelTask?this.zone:F._cancelTaskCurrZone),this._hasTaskZS=null,this._hasTaskDlgt=null,this._hasTaskDlgtOwner=null,this._hasTaskCurrZone=null;const Et=ae&&ae.onHasTask;(Et||F&&F._hasTaskZS)&&(this._hasTaskZS=Et?ae:At,this._hasTaskDlgt=F,this._hasTaskDlgtOwner=this,this._hasTaskCurrZone=ht,ae.onScheduleTask||(this._scheduleTaskZS=At,this._scheduleTaskDlgt=F,this._scheduleTaskCurrZone=this.zone),ae.onInvokeTask||(this._invokeTaskZS=At,this._invokeTaskDlgt=F,this._invokeTaskCurrZone=this.zone),ae.onCancelTask||(this._cancelTaskZS=At,this._cancelTaskDlgt=F,this._cancelTaskCurrZone=this.zone))}fork(ht,F){return this._forkZS?this._forkZS.onFork(this._forkDlgt,this.zone,ht,F):new tt(ht,F)}intercept(ht,F,ae){return this._interceptZS?this._interceptZS.onIntercept(this._interceptDlgt,this._interceptCurrZone,ht,F,ae):F}invoke(ht,F,ae,Et,Xt){return this._invokeZS?this._invokeZS.onInvoke(this._invokeDlgt,this._invokeCurrZone,ht,F,ae,Et,Xt):F.apply(ae,Et)}handleError(ht,F){return!this._handleErrorZS||this._handleErrorZS.onHandleError(this._handleErrorDlgt,this._handleErrorCurrZone,ht,F)}scheduleTask(ht,F){let ae=F;if(this._scheduleTaskZS)this._hasTaskZS&&ae._zoneDelegates.push(this._hasTaskDlgtOwner),ae=this._scheduleTaskZS.onScheduleTask(this._scheduleTaskDlgt,this._scheduleTaskCurrZone,ht,F),ae||(ae=F);else if(F.scheduleFn)F.scheduleFn(F);else{if(F.type!=yi)throw new Error("Task is missing scheduleFn.");Wt(F)}return ae}invokeTask(ht,F,ae,Et){return this._invokeTaskZS?this._invokeTaskZS.onInvokeTask(this._invokeTaskDlgt,this._invokeTaskCurrZone,ht,F,ae,Et):F.callback.apply(ae,Et)}cancelTask(ht,F){let ae;if(this._cancelTaskZS)ae=this._cancelTaskZS.onCancelTask(this._cancelTaskDlgt,this._cancelTaskCurrZone,ht,F);else{if(!F.cancelFn)throw Error("Task is not cancelable");ae=F.cancelFn(F)}return ae}hasTask(ht,F){try{this._hasTaskZS&&this._hasTaskZS.onHasTask(this._hasTaskDlgt,this._hasTaskCurrZone,ht,F)}catch(ae){this.handleError(ht,ae)}}_updateTaskCount(ht,F){const ae=this._taskCounts,Et=ae[ht],Xt=ae[ht]=Et+F;if(Xt<0)throw new Error("More tasks executed then were scheduled.");0!=Et&&0!=Xt||this.hasTask(this.zone,{microTask:ae.microTask>0,macroTask:ae.macroTask>0,eventTask:ae.eventTask>0,change:ht})}}class pt{constructor(ht,F,ae,Et,Xt,Vn){if(this._zone=null,this.runCount=0,this._zoneDelegates=null,this._state="notScheduled",this.type=ht,this.source=F,this.data=Et,this.scheduleFn=Xt,this.cancelFn=Vn,!ae)throw new Error("callback is not defined");this.callback=ae;const Ue=this;this.invoke=ht===rs&&Et&&Et.useG?pt.invokeTask:function(){return pt.invokeTask.call(Z,Ue,this,arguments)}}static invokeTask(ht,F,ae){ht||(ht=this),Ls++;try{return ht.runCount++,ht.zone.runTask(ht,F,ae)}finally{1==Ls&&ct(),Ls--}}get zone(){return this._zone}get state(){return this._state}cancelScheduleRequest(){this._transitionTo(sr,Zr)}_transitionTo(ht,F,ae){if(this._state!==F&&this._state!==ae)throw new Error(`${this.type} '${this.source}': can not transition to '${ht}', expecting state '${F}'${ae?" or '"+ae+"'":""}, was '${this._state}'.`);this._state=ht,ht==sr&&(this._zoneDelegates=null)}toString(){return this.data&&typeof this.data.handleId<"u"?this.data.handleId.toString():Object.prototype.toString.call(this)}toJSON(){return{type:this.type,state:this.state,source:this.source,zone:this.zone.name,runCount:this.runCount}}}const Di=ke("setTimeout"),ni=ke("Promise"),mi=ke("then");let is,cr=[],ki=!1;function Pr(zi){if(is||Z[ni]&&(is=Z[ni].resolve(0)),is){let ht=is[mi];ht||(ht=is.then),ht.call(is,zi)}else Z[Di](zi,0)}function Wt(zi){0===Ls&&0===cr.length&&Pr(ct),zi&&cr.push(zi)}function ct(){if(!ki){for(ki=!0;cr.length;){const zi=cr;cr=[];for(let ht=0;htUr,onUnhandledError:jr,microtaskDrainDone:jr,scheduleMicroTask:Wt,showUncaughtError:()=>!tt[ke("ignoreConsoleErrorUncaughtError")],patchEventTarget:()=>[],patchOnProperties:jr,patchMethod:()=>jr,bindArguments:()=>[],patchThen:()=>jr,patchMacroTask:()=>jr,patchEventPrototype:()=>jr,isIEOrEdge:()=>!1,getGlobalObjects:()=>{},ObjectDefineProperty:()=>jr,ObjectGetOwnPropertyDescriptor:()=>{},ObjectCreate:()=>{},ArraySlice:()=>[],patchClass:()=>jr,wrapWithCurrentZone:()=>jr,filterProperties:()=>[],attachOriginToPatched:()=>jr,_redefineProperty:()=>jr,patchCallbacks:()=>jr,nativeScheduleMicroTask:Pr};let Ur={parent:null,zone:new tt(null,null)},Do=null,Ls=0;function jr(){}pe("Zone","Zone"),Z.Zone=tt}(globalThis);const Wl=Object.getOwnPropertyDescriptor,Vd=Object.defineProperty,Wd=Object.getPrototypeOf,Yd=Object.create,Sb=Array.prototype.slice,mm="addEventListener",$r="removeEventListener",Yl=Zone.__symbol__(mm),_h=Zone.__symbol__($r),Ts="true",Wi="false",Qd=Zone.__symbol__("");function hp(Z,se){return Zone.current.wrap(Z,se)}function ym(Z,se,ye,pe,be){return Zone.current.scheduleMacroTask(Z,se,ye,pe,be)}const Ji=Zone.__symbol__,Uh=typeof window<"u",jh=Uh?window:void 0,gn=Uh&&jh||globalThis,Sm="removeAttribute";function Gd(Z,se){for(let ye=Z.length-1;ye>=0;ye--)"function"==typeof Z[ye]&&(Z[ye]=hp(Z[ye],se+"_"+ye));return Z}function cp(Z){return!Z||!1!==Z.writable&&!("function"==typeof Z.get&&typeof Z.set>"u")}const dp=typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope,Vh=!("nw"in gn)&&typeof gn.process<"u"&&"[object process]"==={}.toString.call(gn.process),Xd=!Vh&&!dp&&!(!Uh||!jh.HTMLElement),up=typeof gn.process<"u"&&"[object process]"==={}.toString.call(gn.process)&&!dp&&!(!Uh||!jh.HTMLElement),Ql={},Wh=function(Z){if(!(Z=Z||gn.event))return;let se=Ql[Z.type];se||(se=Ql[Z.type]=Ji("ON_PROPERTY"+Z.type));const ye=this||Z.target||gn,pe=ye[se];let be;return Xd&&ye===jh&&"error"===Z.type?(be=pe&&pe.call(this,Z.message,Z.filename,Z.lineno,Z.colno,Z.error),!0===be&&Z.preventDefault()):(be=pe&&pe.apply(this,arguments),null!=be&&!be&&Z.preventDefault()),be};function Gl(Z,se,ye){let pe=Wl(Z,se);if(!pe&&ye&&Wl(ye,se)&&(pe={enumerable:!0,configurable:!0}),!pe||!pe.configurable)return;const be=Ji("on"+se+"patched");if(Z.hasOwnProperty(be)&&Z[be])return;delete pe.writable,delete pe.value;const ke=pe.get,at=pe.set,tt=se.slice(2);let At=Ql[tt];At||(At=Ql[tt]=Ji("ON_PROPERTY"+tt)),pe.set=function(Lt){let pt=this;!pt&&Z===gn&&(pt=gn),pt&&("function"==typeof pt[At]&&pt.removeEventListener(tt,Wh),at&&at.call(pt,null),pt[At]=Lt,"function"==typeof Lt&&pt.addEventListener(tt,Wh,!1))},pe.get=function(){let Lt=this;if(!Lt&&Z===gn&&(Lt=gn),!Lt)return null;const pt=Lt[At];if(pt)return pt;if(ke){let Di=ke.call(this);if(Di)return pe.set.call(this,Di),"function"==typeof Lt[Sm]&&Lt.removeAttribute(se),Di}return null},Vd(Z,se,pe),Z[be]=!0}function fp(Z,se,ye){if(se)for(let pe=0;pefunction(at,tt){const At=ye(at,tt);return At.cbIdx>=0&&"function"==typeof tt[At.cbIdx]?ym(At.name,tt[At.cbIdx],At,be):ke.apply(at,tt)})}function Ia(Z,se){Z[Ji("OriginalDelegate")]=se}let bb=!1,$d=!1;function Mb(){if(bb)return $d;bb=!0;try{const Z=jh.navigator.userAgent;(-1!==Z.indexOf("MSIE ")||-1!==Z.indexOf("Trident/")||-1!==Z.indexOf("Edge/"))&&($d=!0)}catch{}return $d}Zone.__load_patch("ZoneAwarePromise",(Z,se,ye)=>{const pe=Object.getOwnPropertyDescriptor,be=Object.defineProperty,at=ye.symbol,tt=[],At=!1!==Z[at("DISABLE_WRAPPING_UNCAUGHT_PROMISE_REJECTION")],Lt=at("Promise"),pt=at("then"),Di="__creationTrace__";ye.onUnhandledError=Ue=>{if(ye.showUncaughtError()){const He=Ue&&Ue.rejection;He?console.error("Unhandled Promise rejection:",He instanceof Error?He.message:He,"; Zone:",Ue.zone.name,"; Task:",Ue.task&&Ue.task.source,"; Value:",He,He instanceof Error?He.stack:void 0):console.error(Ue)}},ye.microtaskDrainDone=()=>{for(;tt.length;){const Ue=tt.shift();try{Ue.zone.runGuarded(()=>{throw Ue.throwOriginal?Ue.rejection:Ue})}catch(He){mi(He)}}};const ni=at("unhandledPromiseRejectionHandler");function mi(Ue){ye.onUnhandledError(Ue);try{const He=se[ni];"function"==typeof He&&He.call(this,Ue)}catch{}}function cr(Ue){return Ue&&Ue.then}function ki(Ue){return Ue}function is(Ue){return F.reject(Ue)}const Pr=at("state"),Wt=at("value"),ct=at("finally"),jn=at("parentPromiseValue"),sr=at("parentPromiseState"),Zr="Promise.then",Pi=null,lt=!0,dr=!1,et=0;function yi(Ue,He){return ge=>{try{cn(Ue,He,ge)}catch(We){cn(Ue,!1,We)}}}const Pt=function(){let Ue=!1;return function(ge){return function(){Ue||(Ue=!0,ge.apply(null,arguments))}}},rs="Promise resolved with itself",_o=at("currentTaskTrace");function cn(Ue,He,ge){const We=Pt();if(Ue===ge)throw new TypeError(rs);if(Ue[Pr]===Pi){let wt=null;try{("object"==typeof ge||"function"==typeof ge)&&(wt=ge&&ge.then)}catch(Xe){return We(()=>{cn(Ue,!1,Xe)})(),Ue}if(He!==dr&&ge instanceof F&&ge.hasOwnProperty(Pr)&&ge.hasOwnProperty(Wt)&&ge[Pr]!==Pi)Do(ge),cn(Ue,ge[Pr],ge[Wt]);else if(He!==dr&&"function"==typeof wt)try{wt.call(ge,We(yi(Ue,He)),We(yi(Ue,!1)))}catch(Xe){We(()=>{cn(Ue,!1,Xe)})()}else{Ue[Pr]=He;const Xe=Ue[Wt];if(Ue[Wt]=ge,Ue[ct]===ct&&He===lt&&(Ue[Pr]=Ue[sr],Ue[Wt]=Ue[jn]),He===dr&&ge instanceof Error){const mt=se.currentTask&&se.currentTask.data&&se.currentTask.data[Di];mt&&be(ge,_o,{configurable:!0,enumerable:!1,writable:!0,value:mt})}for(let mt=0;mt{try{const dt=Ue[Wt],qt=!!ge&&ct===ge[ct];qt&&(ge[jn]=dt,ge[sr]=Xe);const li=He.run(mt,void 0,qt&&mt!==is&&mt!==ki?[]:[dt]);cn(ge,!0,li)}catch(dt){cn(ge,!1,dt)}},ge)}const zi=function(){},ht=Z.AggregateError;class F{static toString(){return"function ZoneAwarePromise() { [native code] }"}static resolve(He){return He instanceof F?He:cn(new this(null),lt,He)}static reject(He){return cn(new this(null),dr,He)}static withResolvers(){const He={};return He.promise=new F((ge,We)=>{He.resolve=ge,He.reject=We}),He}static any(He){if(!He||"function"!=typeof He[Symbol.iterator])return Promise.reject(new ht([],"All promises were rejected"));const ge=[];let We=0;try{for(let mt of He)We++,ge.push(F.resolve(mt))}catch{return Promise.reject(new ht([],"All promises were rejected"))}if(0===We)return Promise.reject(new ht([],"All promises were rejected"));let wt=!1;const Xe=[];return new F((mt,dt)=>{for(let qt=0;qt{wt||(wt=!0,mt(li))},li=>{Xe.push(li),We--,0===We&&(wt=!0,dt(new ht(Xe,"All promises were rejected")))})})}static race(He){let ge,We,wt=new this((dt,qt)=>{ge=dt,We=qt});function Xe(dt){ge(dt)}function mt(dt){We(dt)}for(let dt of He)cr(dt)||(dt=this.resolve(dt)),dt.then(Xe,mt);return wt}static all(He){return F.allWithCallback(He)}static allSettled(He){return(this&&this.prototype instanceof F?this:F).allWithCallback(He,{thenCallback:We=>({status:"fulfilled",value:We}),errorCallback:We=>({status:"rejected",reason:We})})}static allWithCallback(He,ge){let We,wt,Xe=new this((li,ur)=>{We=li,wt=ur}),mt=2,dt=0;const qt=[];for(let li of He){cr(li)||(li=this.resolve(li));const ur=dt;try{li.then(ir=>{qt[ur]=ge?ge.thenCallback(ir):ir,mt--,0===mt&&We(qt)},ir=>{ge?(qt[ur]=ge.errorCallback(ir),mt--,0===mt&&We(qt)):wt(ir)})}catch(ir){wt(ir)}mt++,dt++}return mt-=2,0===mt&&We(qt),Xe}constructor(He){const ge=this;if(!(ge instanceof F))throw new Error("Must be an instanceof Promise.");ge[Pr]=Pi,ge[Wt]=[];try{const We=Pt();He&&He(We(yi(ge,lt)),We(yi(ge,dr)))}catch(We){cn(ge,!1,We)}}get[Symbol.toStringTag](){return"Promise"}get[Symbol.species](){return F}then(He,ge){let We=this.constructor?.[Symbol.species];(!We||"function"!=typeof We)&&(We=this.constructor||F);const wt=new We(zi),Xe=se.current;return this[Pr]==Pi?this[Wt].push(Xe,wt,He,ge):Ls(this,Xe,wt,He,ge),wt}catch(He){return this.then(null,He)}finally(He){let ge=this.constructor?.[Symbol.species];(!ge||"function"!=typeof ge)&&(ge=F);const We=new ge(zi);We[ct]=ct;const wt=se.current;return this[Pr]==Pi?this[Wt].push(wt,We,He,He):Ls(this,wt,We,He,He),We}}F.resolve=F.resolve,F.reject=F.reject,F.race=F.race,F.all=F.all;const ae=Z[Lt]=Z.Promise;Z.Promise=F;const Et=at("thenPatched");function Xt(Ue){const He=Ue.prototype,ge=pe(He,"then");if(ge&&(!1===ge.writable||!ge.configurable))return;const We=He.then;He[pt]=We,Ue.prototype.then=function(wt,Xe){return new F((dt,qt)=>{We.call(this,dt,qt)}).then(wt,Xe)},Ue[Et]=!0}return ye.patchThen=Xt,ae&&(Xt(ae),tl(Z,"fetch",Ue=>function Vn(Ue){return function(He,ge){let We=Ue.apply(He,ge);if(We instanceof F)return We;let wt=We.constructor;return wt[Et]||Xt(wt),We}}(Ue))),Promise[se.__symbol__("uncaughtPromiseErrors")]=tt,F}),Zone.__load_patch("toString",Z=>{const se=Function.prototype.toString,ye=Ji("OriginalDelegate"),pe=Ji("Promise"),be=Ji("Error"),ke=function(){if("function"==typeof this){const Lt=this[ye];if(Lt)return"function"==typeof Lt?se.call(Lt):Object.prototype.toString.call(Lt);if(this===Promise){const pt=Z[pe];if(pt)return se.call(pt)}if(this===Error){const pt=Z[be];if(pt)return se.call(pt)}}return se.call(this)};ke[ye]=se,Function.prototype.toString=ke;const at=Object.prototype.toString;Object.prototype.toString=function(){return"function"==typeof Promise&&this instanceof Promise?"[object Promise]":at.call(this)}});let il=!1;if(typeof window<"u")try{const Z=Object.defineProperty({},"passive",{get:function(){il=!0}});window.addEventListener("test",Z,Z),window.removeEventListener("test",Z,Z)}catch{il=!1}const PT={useG:!0},Co={},wb={},Mm=new RegExp("^"+Qd+"(\\w+)(true|false)$"),Cb=Ji("propagationStopped");function wm(Z,se){const ye=(se?se(Z):Z)+Wi,pe=(se?se(Z):Z)+Ts,be=Qd+ye,ke=Qd+pe;Co[Z]={},Co[Z][Wi]=be,Co[Z][Ts]=ke}function Eb(Z,se,ye,pe){const be=pe&&pe.add||mm,ke=pe&&pe.rm||$r,at=pe&&pe.listeners||"eventListeners",tt=pe&&pe.rmAll||"removeAllListeners",At=Ji(be),Lt="."+be+":",pt="prependListener",Di="."+pt+":",ni=function(Wt,ct,jn){if(Wt.isRemoved)return;const sr=Wt.callback;let Zr;"object"==typeof sr&&sr.handleEvent&&(Wt.callback=lt=>sr.handleEvent(lt),Wt.originalDelegate=sr);try{Wt.invoke(Wt,ct,[jn])}catch(lt){Zr=lt}const Pi=Wt.options;return Pi&&"object"==typeof Pi&&Pi.once&&ct[ke].call(ct,jn.type,Wt.originalDelegate?Wt.originalDelegate:Wt.callback,Pi),Zr};function mi(Wt,ct,jn){if(!(ct=ct||Z.event))return;const sr=Wt||ct.target||Z,Zr=sr[Co[ct.type][jn?Ts:Wi]];if(Zr){const Pi=[];if(1===Zr.length){const lt=ni(Zr[0],sr,ct);lt&&Pi.push(lt)}else{const lt=Zr.slice();for(let dr=0;dr{throw dr})}}}const cr=function(Wt){return mi(this,Wt,!1)},ki=function(Wt){return mi(this,Wt,!0)};function is(Wt,ct){if(!Wt)return!1;let jn=!0;ct&&void 0!==ct.useG&&(jn=ct.useG);const sr=ct&&ct.vh;let Zr=!0;ct&&void 0!==ct.chkDup&&(Zr=ct.chkDup);let Pi=!1;ct&&void 0!==ct.rt&&(Pi=ct.rt);let lt=Wt;for(;lt&&!lt.hasOwnProperty(be);)lt=Wd(lt);if(!lt&&Wt[be]&&(lt=Wt),!lt||lt[At])return!1;const dr=ct&&ct.eventNameToString,et={},yi=lt[At]=lt[be],Pt=lt[Ji(ke)]=lt[ke],rs=lt[Ji(at)]=lt[at],_o=lt[Ji(tt)]=lt[tt];let cn;ct&&ct.prepend&&(cn=lt[Ji(ct.prepend)]=lt[ct.prepend]);const F=jn?function(ge){if(!et.isExisting)return yi.call(et.target,et.eventName,et.capture?ki:cr,et.options)}:function(ge){return yi.call(et.target,et.eventName,ge.invoke,et.options)},ae=jn?function(ge){if(!ge.isRemoved){const We=Co[ge.eventName];let wt;We&&(wt=We[ge.capture?Ts:Wi]);const Xe=wt&&ge.target[wt];if(Xe)for(let mt=0;mt{Vo.zone.cancelTask(Vo)},{once:!0})),et.target=null,Fc&&(Fc.taskData=null),Jd&&(Tn.once=!0),!il&&"boolean"==typeof Vo.options||(Vo.options=Tn),Vo.target=qt,Vo.capture=Zl,Vo.eventName=li,ir&&(Vo.originalDelegate=ur),dt?jo.unshift(Vo):jo.push(Vo),mt?qt:void 0}};return lt[be]=He(yi,Lt,F,ae,Pi),cn&&(lt[pt]=He(cn,Di,function(ge){return cn.call(et.target,et.eventName,ge.invoke,et.options)},ae,Pi,!0)),lt[ke]=function(){const ge=this||Z;let We=arguments[0];ct&&ct.transferEventName&&(We=ct.transferEventName(We));const wt=arguments[2],Xe=!!wt&&("boolean"==typeof wt||wt.capture),mt=arguments[1];if(!mt)return Pt.apply(this,arguments);if(sr&&!sr(Pt,mt,ge,arguments))return;const dt=Co[We];let qt;dt&&(qt=dt[Xe?Ts:Wi]);const li=qt&&ge[qt];if(li)for(let ur=0;urfunction(be,ke){be[Cb]=!0,pe&&pe.apply(be,ke)})}function xb(Z,se,ye,pe,be){const ke=Zone.__symbol__(pe);if(se[ke])return;const at=se[ke]=se[pe];se[pe]=function(tt,At,Lt){return At&&At.prototype&&be.forEach(function(pt){const Di=`${ye}.${pe}::`+pt,ni=At.prototype;try{if(ni.hasOwnProperty(pt)){const mi=Z.ObjectGetOwnPropertyDescriptor(ni,pt);mi&&mi.value?(mi.value=Z.wrapWithCurrentZone(mi.value,Di),Z._redefineProperty(At.prototype,pt,mi)):ni[pt]&&(ni[pt]=Z.wrapWithCurrentZone(ni[pt],Di))}else ni[pt]&&(ni[pt]=Z.wrapWithCurrentZone(ni[pt],Di))}catch{}}),at.call(se,tt,At,Lt)},Z.attachOriginToPatched(se[pe],at)}function Tb(Z,se,ye){if(!ye||0===ye.length)return se;const pe=ye.filter(ke=>ke.target===Z);if(!pe||0===pe.length)return se;const be=pe[0].ignoreProperties;return se.filter(ke=>-1===be.indexOf(ke))}function Eo(Z,se,ye,pe){Z&&fp(Z,Tb(Z,se,ye),pe)}function Zd(Z){return Object.getOwnPropertyNames(Z).filter(se=>se.startsWith("on")&&se.length>2).map(se=>se.substring(2))}Zone.__load_patch("util",(Z,se,ye)=>{const pe=Zd(Z);ye.patchOnProperties=fp,ye.patchMethod=tl,ye.bindArguments=Gd,ye.patchMacroTask=Ib;const be=se.__symbol__("BLACK_LISTED_EVENTS"),ke=se.__symbol__("UNPATCHED_EVENTS");Z[ke]&&(Z[be]=Z[ke]),Z[be]&&(se[be]=se[ke]=Z[be]),ye.patchEventPrototype=Cm,ye.patchEventTarget=Eb,ye.isIEOrEdge=Mb,ye.ObjectDefineProperty=Vd,ye.ObjectGetOwnPropertyDescriptor=Wl,ye.ObjectCreate=Yd,ye.ArraySlice=Sb,ye.patchClass=qd,ye.wrapWithCurrentZone=hp,ye.filterProperties=Tb,ye.attachOriginToPatched=Ia,ye._redefineProperty=Object.defineProperty,ye.patchCallbacks=xb,ye.getGlobalObjects=()=>({globalSources:wb,zoneSymbolEventNames:Co,eventNames:pe,isBrowser:Xd,isMix:up,isNode:Vh,TRUE_STR:Ts,FALSE_STR:Wi,ZONE_SYMBOL_PREFIX:Qd,ADD_EVENT_LISTENER_STR:mm,REMOVE_EVENT_LISTENER_STR:$r})});const As=Ji("zoneTask");function Xl(Z,se,ye,pe){let be=null,ke=null;ye+=pe;const at={};function tt(Lt){const pt=Lt.data;return pt.args[0]=function(){return Lt.invoke.apply(this,arguments)},pt.handleId=be.apply(Z,pt.args),Lt}function At(Lt){return ke.call(Z,Lt.data.handleId)}be=tl(Z,se+=pe,Lt=>function(pt,Di){if("function"==typeof Di[0]){const ni={isPeriodic:"Interval"===pe,delay:"Timeout"===pe||"Interval"===pe?Di[1]||0:void 0,args:Di},mi=Di[0];Di[0]=function(){try{return mi.apply(this,arguments)}finally{ni.isPeriodic||("number"==typeof ni.handleId?delete at[ni.handleId]:ni.handleId&&(ni.handleId[As]=null))}};const cr=ym(se,Di[0],ni,tt,At);if(!cr)return cr;const ki=cr.data.handleId;return"number"==typeof ki?at[ki]=cr:ki&&(ki[As]=cr),ki&&ki.ref&&ki.unref&&"function"==typeof ki.ref&&"function"==typeof ki.unref&&(cr.ref=ki.ref.bind(ki),cr.unref=ki.unref.bind(ki)),"number"==typeof ki||ki?ki:cr}return Lt.apply(Z,Di)}),ke=tl(Z,ye,Lt=>function(pt,Di){const ni=Di[0];let mi;"number"==typeof ni?mi=at[ni]:(mi=ni&&ni[As],mi||(mi=ni)),mi&&"string"==typeof mi.type?"notScheduled"!==mi.state&&(mi.cancelFn&&mi.data.isPeriodic||0===mi.runCount)&&("number"==typeof ni?delete at[ni]:ni&&(ni[As]=null),mi.zone.cancelTask(mi)):Lt.apply(Z,Di)})}Zone.__load_patch("legacy",Z=>{const se=Z[Zone.__symbol__("legacyPatch")];se&&se()}),Zone.__load_patch("timers",Z=>{const ye="clear";Xl(Z,"set",ye,"Timeout"),Xl(Z,"set",ye,"Interval"),Xl(Z,"set",ye,"Immediate")}),Zone.__load_patch("requestAnimationFrame",Z=>{Xl(Z,"request","cancel","AnimationFrame"),Xl(Z,"mozRequest","mozCancel","AnimationFrame"),Xl(Z,"webkitRequest","webkitCancel","AnimationFrame")}),Zone.__load_patch("blocking",(Z,se)=>{const ye=["alert","prompt","confirm"];for(let pe=0;pefunction(At,Lt){return se.current.run(ke,Z,Lt,tt)})}),Zone.__load_patch("EventTarget",(Z,se,ye)=>{(function ql(Z,se){se.patchEventPrototype(Z,se)})(Z,ye),function Dm(Z,se){if(Zone[se.symbol("patchEventTarget")])return;const{eventNames:ye,zoneSymbolEventNames:pe,TRUE_STR:be,FALSE_STR:ke,ZONE_SYMBOL_PREFIX:at}=se.getGlobalObjects();for(let At=0;At{qd("MutationObserver"),qd("WebKitMutationObserver")}),Zone.__load_patch("IntersectionObserver",(Z,se,ye)=>{qd("IntersectionObserver")}),Zone.__load_patch("FileReader",(Z,se,ye)=>{qd("FileReader")}),Zone.__load_patch("on_property",(Z,se,ye)=>{!function pp(Z,se){if(Vh&&!up||Zone[Z.symbol("patchEvents")])return;const ye=se.__Zone_ignore_on_properties;let pe=[];if(Xd){const be=window;pe=pe.concat(["Document","SVGElement","Element","HTMLElement","HTMLBodyElement","HTMLMediaElement","HTMLFrameSetElement","HTMLFrameElement","HTMLIFrameElement","HTMLMarqueeElement","Worker"]);const ke=function bm(){try{const Z=jh.navigator.userAgent;if(-1!==Z.indexOf("MSIE ")||-1!==Z.indexOf("Trident/"))return!0}catch{}return!1}()?[{target:be,ignoreProperties:["error"]}]:[];Eo(be,Zd(be),ye&&ye.concat(ke),Wd(be))}pe=pe.concat(["XMLHttpRequest","XMLHttpRequestEventTarget","IDBIndex","IDBRequest","IDBOpenDBRequest","IDBDatabase","IDBTransaction","IDBCursor","WebSocket"]);for(let be=0;be{!function Em(Z,se){const{isBrowser:ye,isMix:pe}=se.getGlobalObjects();(ye||pe)&&Z.customElements&&"customElements"in Z&&se.patchCallbacks(se,Z.customElements,"customElements","define",["connectedCallback","disconnectedCallback","adoptedCallback","attributeChangedCallback"])}(Z,ye)}),Zone.__load_patch("XHR",(Z,se)=>{!function At(Lt){const pt=Lt.XMLHttpRequest;if(!pt)return;const Di=pt.prototype;let mi=Di[Yl],cr=Di[_h];if(!mi){const et=Lt.XMLHttpRequestEventTarget;if(et){const yi=et.prototype;mi=yi[Yl],cr=yi[_h]}}const ki="readystatechange",is="scheduled";function Pr(et){const yi=et.data,Pt=yi.target;Pt[ke]=!1,Pt[tt]=!1;const rs=Pt[be];mi||(mi=Pt[Yl],cr=Pt[_h]),rs&&cr.call(Pt,ki,rs);const _o=Pt[be]=()=>{if(Pt.readyState===Pt.DONE)if(!yi.aborted&&Pt[ke]&&et.state===is){const Ur=Pt[se.__symbol__("loadfalse")];if(0!==Pt.status&&Ur&&Ur.length>0){const Do=et.invoke;et.invoke=function(){const Ls=Pt[se.__symbol__("loadfalse")];for(let jr=0;jrfunction(et,yi){return et[pe]=0==yi[2],et[at]=yi[1],jn.apply(et,yi)}),Zr=Ji("fetchTaskAborting"),Pi=Ji("fetchTaskScheduling"),lt=tl(Di,"send",()=>function(et,yi){if(!0===se.current[Pi]||et[pe])return lt.apply(et,yi);{const Pt={target:et,url:et[at],isPeriodic:!1,args:yi,aborted:!1},rs=ym("XMLHttpRequest.send",Wt,Pt,Pr,ct);et&&!0===et[tt]&&!Pt.aborted&&rs.state===is&&rs.invoke()}}),dr=tl(Di,"abort",()=>function(et,yi){const Pt=function ni(et){return et[ye]}(et);if(Pt&&"string"==typeof Pt.type){if(null==Pt.cancelFn||Pt.data&&Pt.data.aborted)return;Pt.zone.cancelTask(Pt)}else if(!0===se.current[Zr])return dr.apply(et,yi)})}(Z);const ye=Ji("xhrTask"),pe=Ji("xhrSync"),be=Ji("xhrListener"),ke=Ji("xhrScheduled"),at=Ji("xhrURL"),tt=Ji("xhrErrorBeforeScheduled")}),Zone.__load_patch("geolocation",Z=>{Z.navigator&&Z.navigator.geolocation&&function Im(Z,se){const ye=Z.constructor.name;for(let pe=0;pe{const At=function(){return tt.apply(this,Gd(arguments,ye+"."+be))};return Ia(At,tt),At})(ke)}}}(Z.navigator.geolocation,["getCurrentPosition","watchPosition"])}),Zone.__load_patch("PromiseRejectionEvent",(Z,se)=>{function ye(pe){return function(be){Db(Z,pe).forEach(at=>{const tt=Z.PromiseRejectionEvent;if(tt){const At=new tt(pe,{promise:be.promise,reason:be.rejection});at.invoke(At)}})}}Z.PromiseRejectionEvent&&(se[Ji("unhandledPromiseRejectionHandler")]=ye("unhandledrejection"),se[Ji("rejectionHandledHandler")]=ye("rejectionhandled"))}),Zone.__load_patch("queueMicrotask",(Z,se,ye)=>{!function gp(Z,se){se.patchMethod(Z,"queueMicrotask",ye=>function(pe,be){Zone.current.scheduleMicroTask("queueMicrotask",be[0])})}(Z,ye)})}},Wl=>{Wl(Wl.s=51)}]); \ No newline at end of file diff --git a/ej2-angular/samples/diagram/layers/layers-cs6/main.f823f2a09376668e.js b/ej2-angular/samples/diagram/layers/layers-cs6/main.f823f2a09376668e.js deleted file mode 100644 index c697d8f951..0000000000 --- a/ej2-angular/samples/diagram/layers/layers-cs6/main.f823f2a09376668e.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";(self.webpackChunksyncfusion_component=self.webpackChunksyncfusion_component||[]).push([[179],{51:(_l,jd,Vd)=>{let $r=null,Fh=1;const Ts=Symbol("SIGNAL");function Wi(n){const t=$r;return $r=n,t}function gn(n){if((!Vh(n)||n.dirty)&&(n.dirty||n.lastCleanEpoch!==Fh)){if(!n.producerMustRecompute(n)&&!jh(n))return n.dirty=!1,void(n.lastCleanEpoch=Fh);n.producerRecomputeValue(n),n.dirty=!1,n.lastCleanEpoch=Fh}}function jh(n){Vl(n);for(let t=0;t0}function Vl(n){n.producerNode??=[],n.producerIndexOfThis??=[],n.producerLastReadVersion??=[]}let qd=null;function Eo(n){return"function"==typeof n}function $d(n){const e=n(i=>{Error.call(i),i.stack=(new Error).stack});return e.prototype=Object.create(Error.prototype),e.prototype.constructor=e,e}const ff=$d(n=>function(e){n(this),this.message=e?`${e.length} errors occurred during unsubscription:\n${e.map((i,r)=>`${r+1}) ${i.toString()}`).join("\n ")}`:"",this.name="UnsubscriptionError",this.errors=e});function gf(n,t){if(n){const e=n.indexOf(t);0<=e&&n.splice(e,1)}}class As{constructor(t){this.initialTeardown=t,this.closed=!1,this._parentage=null,this._finalizers=null}unsubscribe(){let t;if(!this.closed){this.closed=!0;const{_parentage:e}=this;if(e)if(this._parentage=null,Array.isArray(e))for(const s of e)s.remove(this);else e.remove(this);const{initialTeardown:i}=this;if(Eo(i))try{i()}catch(s){t=s instanceof ff?s.errors:[s]}const{_finalizers:r}=this;if(r){this._finalizers=null;for(const s of r)try{Cm(s)}catch(o){t=t??[],o instanceof ff?t=[...t,...o.errors]:t.push(o)}}if(t)throw new ff(t)}}add(t){var e;if(t&&t!==this)if(this.closed)Cm(t);else{if(t instanceof As){if(t.closed||t._hasParent(this))return;t._addParent(this)}(this._finalizers=null!==(e=this._finalizers)&&void 0!==e?e:[]).push(t)}}_hasParent(t){const{_parentage:e}=this;return e===t||Array.isArray(e)&&e.includes(t)}_addParent(t){const{_parentage:e}=this;this._parentage=Array.isArray(e)?(e.push(t),e):e?[e,t]:t}_removeParent(t){const{_parentage:e}=this;e===t?this._parentage=null:Array.isArray(e)&&gf(e,t)}remove(t){const{_finalizers:e}=this;e&&gf(e,t),t instanceof As&&t._removeParent(this)}}As.EMPTY=(()=>{const n=new As;return n.closed=!0,n})();const Wl=As.EMPTY;function wm(n){return n instanceof As||n&&"closed"in n&&Eo(n.remove)&&Eo(n.add)&&Eo(n.unsubscribe)}function Cm(n){Eo(n)?n():n.unsubscribe()}const Yl={onUnhandledError:null,onStoppedNotification:null,Promise:void 0,useDeprecatedSynchronousErrorHandling:!1,useDeprecatedNextContext:!1},Z={setTimeout(n,t,...e){const{delegate:i}=Z;return i?.setTimeout?i.setTimeout(n,t,...e):setTimeout(n,t,...e)},clearTimeout(n){const{delegate:t}=Z;return(t?.clearTimeout||clearTimeout)(n)},delegate:void 0};function ye(){}const fe=at("C",void 0,void 0);function at(n,t,e){return{kind:n,value:t,error:e}}let tt=null;function At(n){if(Yl.useDeprecatedSynchronousErrorHandling){const t=!tt;if(t&&(tt={errorThrown:!1,error:null}),n(),t){const{errorThrown:e,error:i}=tt;if(tt=null,e)throw i}}else n()}class ft extends As{constructor(t){super(),this.isStopped=!1,t?(this.destination=t,wm(t)&&t.add(this)):this.destination=Wt}static create(t,e,i){return new cr(t,e,i)}next(t){this.isStopped?kr(function ke(n){return at("N",n,void 0)}(t),this):this._next(t)}error(t){this.isStopped?kr(function be(n){return at("E",void 0,n)}(t),this):(this.isStopped=!0,this._error(t))}complete(){this.isStopped?kr(fe,this):(this.isStopped=!0,this._complete())}unsubscribe(){this.closed||(this.isStopped=!0,super.unsubscribe(),this.destination=null)}_next(t){this.destination.next(t)}_error(t){try{this.destination.error(t)}finally{this.unsubscribe()}}_complete(){try{this.destination.complete()}finally{this.unsubscribe()}}}const Ei=Function.prototype.bind;function ti(n,t){return Ei.call(n,t)}class gi{constructor(t){this.partialObserver=t}next(t){const{partialObserver:e}=this;if(e.next)try{e.next(t)}catch(i){Oi(i)}}error(t){const{partialObserver:e}=this;if(e.error)try{e.error(t)}catch(i){Oi(i)}else Oi(t)}complete(){const{partialObserver:t}=this;if(t.complete)try{t.complete()}catch(e){Oi(e)}}}class cr extends ft{constructor(t,e,i){let r;if(super(),Eo(t)||!t)r={next:t??void 0,error:e??void 0,complete:i??void 0};else{let s;this&&Yl.useDeprecatedNextContext?(s=Object.create(t),s.unsubscribe=()=>this.unsubscribe(),r={next:t.next&&ti(t.next,s),error:t.error&&ti(t.error,s),complete:t.complete&&ti(t.complete,s)}):r=t}this.destination=new gi(r)}}function Oi(n){Yl.useDeprecatedSynchronousErrorHandling?function Lt(n){Yl.useDeprecatedSynchronousErrorHandling&&tt&&(tt.errorThrown=!0,tt.error=n)}(n):function se(n){Z.setTimeout(()=>{const{onUnhandledError:t}=Yl;if(!t)throw n;t(n)})}(n)}function kr(n,t){const{onStoppedNotification:e}=Yl;e&&Z.setTimeout(()=>e(n,t))}const Wt={closed:!0,next:ye,error:function es(n){throw n},complete:ye},ct="function"==typeof Symbol&&Symbol.observable||"@@observable";function _n(n){return n}let ki=(()=>{class n{constructor(e){e&&(this._subscribe=e)}lift(e){const i=new n;return i.source=this,i.operator=e,i}subscribe(e,i,r){const s=function et(n){return n&&n instanceof ft||function dr(n){return n&&Eo(n.next)&&Eo(n.error)&&Eo(n.complete)}(n)&&wm(n)}(e)?e:new cr(e,i,r);return At(()=>{const{operator:o,source:a}=this;s.add(o?o.call(s,a):a?this._subscribe(s):this._trySubscribe(s))}),s}_trySubscribe(e){try{return this._subscribe(e)}catch(i){e.error(i)}}forEach(e,i){return new(i=lt(i))((r,s)=>{const o=new cr({next:a=>{try{e(a)}catch(l){s(l),o.unsubscribe()}},error:s,complete:r});this.subscribe(o)})}_subscribe(e){var i;return null===(i=this.source)||void 0===i?void 0:i.subscribe(e)}[ct](){return this}pipe(...e){return function Zr(n){return 0===n.length?_n:1===n.length?n[0]:function(e){return n.reduce((i,r)=>r(i),e)}}(e)(this)}toPromise(e){return new(e=lt(e))((i,r)=>{let s;this.subscribe(o=>s=o,o=>r(o),()=>i(s))})}}return n.create=t=>new n(t),n})();function lt(n){var t;return null!==(t=n??Yl.Promise)&&void 0!==t?t:Promise}const vi=$d(n=>function(){n(this),this.name="ObjectUnsubscribedError",this.message="object unsubscribed"});let Pt=(()=>{class n extends ki{constructor(){super(),this.closed=!1,this.currentObservers=null,this.observers=[],this.isStopped=!1,this.hasError=!1,this.thrownError=null}lift(e){const i=new ts(this,this);return i.operator=e,i}_throwIfClosed(){if(this.closed)throw new vi}next(e){At(()=>{if(this._throwIfClosed(),!this.isStopped){this.currentObservers||(this.currentObservers=Array.from(this.observers));for(const i of this.currentObservers)i.next(e)}})}error(e){At(()=>{if(this._throwIfClosed(),!this.isStopped){this.hasError=this.isStopped=!0,this.thrownError=e;const{observers:i}=this;for(;i.length;)i.shift().error(e)}})}complete(){At(()=>{if(this._throwIfClosed(),!this.isStopped){this.isStopped=!0;const{observers:e}=this;for(;e.length;)e.shift().complete()}})}unsubscribe(){this.isStopped=this.closed=!0,this.observers=this.currentObservers=null}get observed(){var e;return(null===(e=this.observers)||void 0===e?void 0:e.length)>0}_trySubscribe(e){return this._throwIfClosed(),super._trySubscribe(e)}_subscribe(e){return this._throwIfClosed(),this._checkFinalizedStatuses(e),this._innerSubscribe(e)}_innerSubscribe(e){const{hasError:i,isStopped:r,observers:s}=this;return i||r?Wl:(this.currentObservers=null,s.push(e),new As(()=>{this.currentObservers=null,gf(s,e)}))}_checkFinalizedStatuses(e){const{hasError:i,thrownError:r,isStopped:s}=this;i?e.error(r):s&&e.complete()}asObservable(){const e=new ki;return e.source=this,e}}return n.create=(t,e)=>new ts(t,e),n})();class ts extends Pt{constructor(t,e){super(),this.destination=t,this.source=e}next(t){var e,i;null===(i=null===(e=this.destination)||void 0===e?void 0:e.next)||void 0===i||i.call(e,t)}error(t){var e,i;null===(i=null===(e=this.destination)||void 0===e?void 0:e.error)||void 0===i||i.call(e,t)}complete(){var t,e;null===(e=null===(t=this.destination)||void 0===t?void 0:t.complete)||void 0===e||e.call(t)}_subscribe(t){var e,i;return null!==(i=null===(e=this.source)||void 0===e?void 0:e.subscribe(t))&&void 0!==i?i:Wl}}class _o extends Pt{constructor(t){super(),this._value=t}get value(){return this.getValue()}_subscribe(t){const e=super._subscribe(t);return!e.closed&&t.next(this._value),e}getValue(){const{hasError:t,thrownError:e,_value:i}=this;if(t)throw e;return this._throwIfClosed(),i}next(t){super.next(this._value=t)}}class Ls extends ft{constructor(t,e,i,r,s,o){super(t),this.onFinalize=s,this.shouldUnsubscribe=o,this._next=e?function(a){try{e(a)}catch(l){t.error(l)}}:super._next,this._error=r?function(a){try{r(a)}catch(l){t.error(l)}finally{this.unsubscribe()}}:super._error,this._complete=i?function(){try{i()}catch(a){t.error(a)}finally{this.unsubscribe()}}:super._complete}unsubscribe(){var t;if(!this.shouldUnsubscribe||this.shouldUnsubscribe()){const{closed:e}=this;super.unsubscribe(),!e&&(null===(t=this.onFinalize)||void 0===t||t.call(this))}}}function jr(n,t){return function Ur(n){return t=>{if(function cn(n){return Eo(n?.lift)}(t))return t.lift(function(e){try{return n(e,this)}catch(i){this.error(i)}});throw new TypeError("Unable to lift unknown Observable type")}}((e,i)=>{let r=0;e.subscribe(function Do(n,t,e,i,r){return new Ls(n,t,e,i,r)}(i,s=>{i.next(n.call(t,s,r++))}))})}class F extends Error{constructor(t,e){super(function ae(n,t){return`NG0${Math.abs(n)}${t?": "+t:""}`}(t,e)),this.code=t}}function Xe(n){for(let t in n)if(n[t]===Xe)return t;throw Error("Could not find renamed property on target object.")}function mt(n,t){for(const e in t)t.hasOwnProperty(e)&&!n.hasOwnProperty(e)&&(n[e]=t[e])}function dt(n){if("string"==typeof n)return n;if(Array.isArray(n))return"["+n.map(dt).join(", ")+"]";if(null==n)return""+n;if(n.overriddenName)return`${n.overriddenName}`;if(n.name)return`${n.name}`;const t=n.toString();if(null==t)return""+t;const e=t.indexOf("\n");return-1===e?t:t.substring(0,e)}function qt(n,t){return null==n||""===n?null===t?"":t:null==t||""===t?n:n+" "+t}const ur=Xe({__forward_ref__:Xe});function ir(n){return n.__forward_ref__=ir,n.toString=function(){return dt(this())},n}function vt(n){return function Dn(n){return"function"==typeof n&&n.hasOwnProperty(ur)&&n.__forward_ref__===ir}(n)?n():n}function Ql(n){return n&&!!n.\u0275providers}const Gl=Xe({\u0275cmp:Xe}),Zd=Xe({\u0275dir:Xe}),vf=Xe({\u0275pipe:Xe}),Uo=Xe({\u0275fac:Xe}),jo=Xe({__NG_ELEMENT_ID__:Xe}),mf=Xe({__NG_ENV_ID__:Xe});function zi(n){return"function"==typeof n?n.name||n.toString():"object"==typeof n&&null!=n&&"function"==typeof n.type?n.type.name||n.type.toString():function Nt(n){return"string"==typeof n?n:null==n?"":String(n)}(n)}function Ab(n,t){throw new F(-201,!1)}function ro(n,t){null==n&&function zt(n,t,e,i){throw new Error(`ASSERTION ERROR: ${n}`+(null==i?"":` [Expected=> ${e} ${i} ${t} <=Actual]`))}(t,n,null,"!=")}function Yi(n){return{token:n.token,providedIn:n.providedIn||null,factory:n.factory,value:void 0}}function yf(n){return{providers:n.providers||[],imports:n.imports||[]}}function Em(n){return zT(n,xm)||zT(n,RT)}function zT(n,t){return n.hasOwnProperty(t)?n[t]:null}function Dm(n){return n&&(n.hasOwnProperty(Lb)||n.hasOwnProperty(x_))?n[Lb]:null}const xm=Xe({\u0275prov:Xe}),Lb=Xe({\u0275inj:Xe}),RT=Xe({ngInjectableDef:Xe}),x_=Xe({ngInjectorDef:Xe});var Di=function(n){return n[n.Default=0]="Default",n[n.Host=1]="Host",n[n.Self=2]="Self",n[n.SkipSelf=4]="SkipSelf",n[n.Optional=8]="Optional",n}(Di||{});let Nb;function no(n){const t=Nb;return Nb=n,t}function BT(n,t,e){const i=Em(n);return i&&"root"==i.providedIn?void 0===i.value?i.value=i.factory():i.value:e&Di.Optional?null:void 0!==t?t:void Ab()}const rr=globalThis;class Ht{constructor(t,e){this._desc=t,this.ngMetadataName="InjectionToken",this.\u0275prov=void 0,"number"==typeof e?this.__NG_ELEMENT_ID__=e:void 0!==e&&(this.\u0275prov=Yi({token:this,providedIn:e.providedIn||"root",factory:e.factory}))}get multi(){return this}toString(){return`InjectionToken ${this._desc}`}}const Sf={},Rb="__NG_DI_FLAG__",Tm="ngTempTokenPath",L_=/\n/gm,_T="__source";let Kd;function Qh(n){const t=Kd;return Kd=n,t}function k_(n,t=Di.Default){if(void 0===Kd)throw new F(-203,!1);return null===Kd?BT(n,void 0,t):Kd.get(n,t&Di.Optional?null:void 0,t)}function Fi(n,t=Di.Default){return(function HT(){return Nb}()||k_)(vt(n),t)}function Ri(n,t=Di.Default){return Fi(n,Am(t))}function Am(n){return typeof n>"u"||"number"==typeof n?n:0|(n.optional&&8)|(n.host&&1)|(n.self&&2)|(n.skipSelf&&4)}function Hb(n){const t=[];for(let e=0;et){o=s-1;break}}}for(;ss?"":r[d+1].toLowerCase();const p=8&i?u:null;if(p&&-1!==jT(p,h,0)||2&i&&h!==u){if(ba(i))return!1;o=!0}}}}else{if(!o&&!ba(i)&&!ba(l))return!1;if(o&&ba(l))continue;o=!1,i=l|1&i}}return ba(i)||o}function ba(n){return 0==(1&n)}function __(n,t,e,i){if(null===t)return-1;let r=0;if(i||!e){let s=!1;for(;r-1)for(e++;e0?'="'+a+'"':"")+"]"}else 8&i?r+="."+o:4&i&&(r+=" "+o);else""!==r&&!ba(o)&&(t+=qT(s,r),r=""),i=o,s=s||!ba(i);e++}return""!==r&&(t+=qT(s,r)),t}function Fb(n){return Xl(()=>{const t=ZT(n),e={...t,decls:n.decls,vars:n.vars,template:n.template,consts:n.consts||null,ngContentSelectors:n.ngContentSelectors,onPush:n.changeDetection===Lm.OnPush,directiveDefs:null,pipeDefs:null,dependencies:t.standalone&&n.dependencies||null,getStandaloneInjector:null,signals:n.signals??!1,data:n.data||{},encapsulation:n.encapsulation||Ia.Emulated,styles:n.styles||Qi,_:null,schemas:n.schemas||null,tView:null,id:""};JT(e);const i=n.dependencies;return e.directiveDefs=Om(i,!1),e.pipeDefs=Om(i,!0),e.id=function Z_(n){let t=0;const e=[n.selectors,n.ngContentSelectors,n.hostVars,n.hostAttrs,n.consts,n.vars,n.decls,n.encapsulation,n.standalone,n.signals,n.exportAs,JSON.stringify(n.inputs),JSON.stringify(n.outputs),Object.getOwnPropertyNames(n.type.prototype),!!n.contentQueries,!!n.viewQuery].join("|");for(const r of e)t=Math.imul(31,t)+r.charCodeAt(0)<<0;return t+=2147483648,"c"+t}(e),e})}function X_(n){return ci(n)||jn(n)}function q_(n){return null!==n}function Nm(n){return Xl(()=>({type:n.type,bootstrap:n.bootstrap||Qi,declarations:n.declarations||Qi,imports:n.imports||Qi,exports:n.exports||Qi,transitiveCompileScopes:null,schemas:n.schemas||null,id:n.id||null}))}function $T(n,t){if(null==n)return tl;const e={};for(const i in n)if(n.hasOwnProperty(i)){const r=n[i];let s,o,a=Gh.None;Array.isArray(r)?(a=r[0],s=r[1],o=r[2]??s):(s=r,o=r),t?(e[s]=a!==Gh.None?[i,a]:i,t[s]=o):e[s]=i}return e}function nr(n){return Xl(()=>{const t=ZT(n);return JT(t),t})}function ci(n){return n[Gl]||null}function jn(n){return n[Zd]||null}function gs(n){return n[vf]||null}function ZT(n){const t={};return{type:n.type,providersResolver:null,factory:null,hostBindings:n.hostBindings||null,hostVars:n.hostVars||0,hostAttrs:n.hostAttrs||null,contentQueries:n.contentQueries||null,declaredInputs:t,inputTransforms:null,inputConfig:n.inputs||tl,exportAs:n.exportAs||null,standalone:!0===n.standalone,signals:!0===n.signals,selectors:n.selectors||Qi,viewQuery:n.viewQuery||null,features:n.features||null,setInput:null,findHostDirectiveDefs:null,hostDirectives:null,inputs:$T(n.inputs,t),outputs:$T(n.outputs),debugInfo:null}}function JT(n){n.features?.forEach(t=>t(n))}function Om(n,t){if(!n)return null;const e=t?gs:X_;return()=>("function"==typeof n?n():n).map(i=>e(i)).filter(q_)}const Vr=0,Be=1,Ct=2,vn=3,Ma=4,Os=5,wa=6,eu=7,Er=8,Xs=9,ql=10,Yt=11,Mf=12,KT=13,tu=14,Jr=15,wf=16,iu=17,il=18,Cf=19,eA=20,Xh=21,km=22,Uc=23,Ut=25,_b=1,rl=7,ru=9,mn=10;var Ub=function(n){return n[n.None=0]="None",n[n.HasTransplantedViews=2]="HasTransplantedViews",n}(Ub||{});function ks(n){return Array.isArray(n)&&"object"==typeof n[_b]}function Ps(n){return Array.isArray(n)&&!0===n[_b]}function jb(n){return 0!=(4&n.flags)}function jc(n){return n.componentOffset>-1}function zm(n){return 1==(1&n.flags)}function Ca(n){return!!n.template}function Vb(n){return 0!=(512&n[Ct])}function Vc(n,t){return n.hasOwnProperty(Uo)?n[Uo]:null}class tU{constructor(t,e,i){this.previousValue=t,this.currentValue=e,this.firstChange=i}isFirstChange(){return this.firstChange}}function nA(n,t,e,i){null!==t?t.applyValueToInputSignal(t,i):n[e]=i}function sA(n){return n.type.prototype.ngOnChanges&&(n.setInput=rU),iU}function iU(){const n=aA(this),t=n?.current;if(t){const e=n.previous;if(e===tl)n.previous=t;else for(let i in t)e[i]=t[i];n.current=null,this.ngOnChanges(t)}}function rU(n,t,e,i,r){const s=this.declaredInputs[i],o=aA(n)||function nU(n,t){return n[oA]=t}(n,{previous:tl,current:null}),a=o.current||(o.current={}),l=o.previous,h=l[s];a[s]=new tU(h&&h.currentValue,e,l===tl),nA(n,t,r,e)}const oA="__ngSimpleChanges__";function aA(n){return n[oA]||null}const nl=function(n,t,e){};let cA=!1;function pr(n){for(;Array.isArray(n);)n=n[Vr];return n}function qs(n,t){return pr(t[n.index])}function xf(n,t){return n.data[t]}function To(n,t){const e=t[n];return ks(e)?e:e[Vr]}function Xb(n){return 128==(128&n[Ct])}function sl(n,t){return null==t?null:n[t]}function dA(n){n[iu]=0}function cU(n){1024&n[Ct]||(n[Ct]|=1024,Xb(n)&&Tf(n))}function pA(n){return 9216&n[Ct]||n[Uc]?.dirty}function qb(n){pA(n)?Tf(n):64&n[Ct]&&(function oU(){return cA}()?(n[Ct]|=1024,Tf(n)):n[ql].changeDetectionScheduler?.notify())}function Tf(n){n[ql].changeDetectionScheduler?.notify();let t=Wc(n);for(;null!==t&&!(8192&t[Ct])&&(t[Ct]|=8192,Xb(t));)t=Wc(t)}function Wc(n){const t=n[vn];return Ps(t)?t[vn]:t}const Rt={lFrame:wA(null),bindingsEnabled:!0,skipHydrationRootTNode:null};function gA(){return Rt.bindingsEnabled}function Se(){return Rt.lFrame.lView}function xi(){return Rt.lFrame.tView}function fr(){let n=vA();for(;null!==n&&64===n.type;)n=n.parent;return n}function vA(){return Rt.lFrame.currentTNode}function ol(n,t){const e=Rt.lFrame;e.currentTNode=n,e.isParent=t}function Zb(){return Rt.lFrame.isParent}function wU(n,t){const e=Rt.lFrame;e.bindingIndex=e.bindingRootIndex=n,Kb(t)}function Kb(n){Rt.lFrame.currentDirectiveIndex=n}function IA(){return Rt.lFrame.currentQueryIndex}function t1(n){Rt.lFrame.currentQueryIndex=n}function EU(n){const t=n[Be];return 2===t.type?t.declTNode:1===t.type?n[Os]:null}function bA(n,t,e){if(e&Di.SkipSelf){let r=t,s=n;for(;!(r=r.parent,null!==r||e&Di.Host||(r=EU(s),null===r||(s=s[tu],10&r.type))););if(null===r)return!1;t=r,n=s}const i=Rt.lFrame=MA();return i.currentTNode=t,i.lView=n,!0}function i1(n){const t=MA(),e=n[Be];Rt.lFrame=t,t.currentTNode=e.firstChild,t.lView=n,t.tView=e,t.contextLView=n,t.bindingIndex=e.bindingStartIndex,t.inI18n=!1}function MA(){const n=Rt.lFrame,t=null===n?null:n.child;return null===t?wA(n):t}function wA(n){const t={currentTNode:null,isParent:!0,lView:null,tView:null,selectedIndex:-1,contextLView:null,elementDepthCount:0,currentNamespace:null,currentDirectiveIndex:-1,bindingRootIndex:-1,bindingIndex:-1,currentQueryIndex:0,parent:n,child:null,inI18n:!1};return null!==n&&(n.child=t),t}function CA(){const n=Rt.lFrame;return Rt.lFrame=n.parent,n.currentTNode=null,n.lView=null,n}const EA=CA;function r1(){const n=CA();n.isParent=!0,n.tView=null,n.selectedIndex=-1,n.contextLView=null,n.elementDepthCount=0,n.currentDirectiveIndex=-1,n.currentNamespace=null,n.bindingRootIndex=-1,n.bindingIndex=-1,n.currentQueryIndex=0}function zs(){return Rt.lFrame.selectedIndex}function Yc(n){Rt.lFrame.selectedIndex=n}let xA=!0;function Bm(){return xA}function qh(n){xA=n}function Fm(n,t){for(let e=t.directiveStart,i=t.directiveEnd;e=i)break}else t[l]<0&&(n[iu]+=65536),(a>14>16&&(3&n[Ct])===t&&(n[Ct]+=16384,AA(a,s)):AA(a,s)}const ou=-1;class Lf{constructor(t,e,i){this.factory=t,this.resolving=!1,this.canSeeViewProviders=e,this.injectImpl=i}}function o1(n){return n!==ou}function Nf(n){return 32767&n}function Of(n,t){let e=function HU(n){return n>>16}(n),i=t;for(;e>0;)i=i[tu],e--;return i}let a1=!0;function jm(n){const t=a1;return a1=n,t}const LA=255,NA=5;let BU=0;const ll={};function Vm(n,t){const e=OA(n,t);if(-1!==e)return e;const i=t[Be];i.firstCreatePass&&(n.injectorIndex=t.length,l1(i.data,n),l1(t,null),l1(i.blueprint,null));const r=Wm(n,t),s=n.injectorIndex;if(o1(r)){const o=Nf(r),a=Of(r,t),l=a[Be].data;for(let h=0;h<8;h++)t[s+h]=a[o+h]|l[o+h]}return t[s+8]=r,s}function l1(n,t){n.push(0,0,0,0,0,0,0,0,t)}function OA(n,t){return-1===n.injectorIndex||n.parent&&n.parent.injectorIndex===n.injectorIndex||null===t[n.injectorIndex+8]?-1:n.injectorIndex}function Wm(n,t){if(n.parent&&-1!==n.parent.injectorIndex)return n.parent.injectorIndex;let e=0,i=null,r=t;for(;null!==r;){if(i=FA(r),null===i)return ou;if(e++,r=r[tu],-1!==i.injectorIndex)return i.injectorIndex|e<<16}return ou}function h1(n,t,e){!function FU(n,t,e){let i;"string"==typeof e?i=e.charCodeAt(0)||0:e.hasOwnProperty(jo)&&(i=e[jo]),null==i&&(i=e[jo]=BU++);const r=i&LA;t.data[n+(r>>NA)]|=1<=0?t&LA:VU:t}(e);if("function"==typeof s){if(!bA(t,n,i))return i&Di.Host?kA(r,0,i):PA(t,e,i,r);try{let o;if(o=s(i),null!=o||i&Di.Optional)return o;Ab()}finally{EA()}}else if("number"==typeof s){let o=null,a=OA(n,t),l=ou,h=i&Di.Host?t[Jr][Os]:null;for((-1===a||i&Di.SkipSelf)&&(l=-1===a?Wm(n,t):t[a+8],l!==ou&&BA(i,!1)?(o=t[Be],a=Nf(l),t=Of(l,t)):a=-1);-1!==a;){const c=t[Be];if(HA(s,a,c.data)){const d=UU(a,t,e,o,i,h);if(d!==ll)return d}l=t[a+8],l!==ou&&BA(i,t[Be].data[a+8]===h)&&HA(s,a,t)?(o=c,a=Nf(l),t=Of(l,t)):a=-1}}return r}function UU(n,t,e,i,r,s){const o=t[Be],a=o.data[n+8],c=Ym(a,o,e,null==i?jc(a)&&a1:i!=o&&0!=(3&a.type),r&Di.Host&&s===a);return null!==c?Qc(t,o,c,a):ll}function Ym(n,t,e,i,r){const s=n.providerIndexes,o=t.data,a=1048575&s,l=n.directiveStart,c=s>>20,u=r?a+c:n.directiveEnd;for(let p=i?a:a+c;p=l&&f.type===e)return p}if(r){const p=o[l];if(p&&Ca(p)&&p.type===e)return l}return null}function Qc(n,t,e,i){let r=n[e];const s=t.data;if(function kU(n){return n instanceof Lf}(r)){const o=r;o.resolving&&function Vo(n,t){const e=t?`. Dependency path: ${t.join(" > ")} > ${n}`:"";throw new F(-200,`Circular dependency in DI detected for ${n}${e}`)}(zi(s[e]));const a=jm(o.canSeeViewProviders);o.resolving=!0;const h=o.injectImpl?no(o.injectImpl):null;bA(n,i,Di.Default);try{r=n[e]=o.factory(void 0,s,n,i),t.firstCreatePass&&e>=i.directiveStart&&function NU(n,t,e){const{ngOnChanges:i,ngOnInit:r,ngDoCheck:s}=t.type.prototype;if(i){const o=sA(t);(e.preOrderHooks??=[]).push(n,o),(e.preOrderCheckHooks??=[]).push(n,o)}r&&(e.preOrderHooks??=[]).push(0-n,r),s&&((e.preOrderHooks??=[]).push(n,s),(e.preOrderCheckHooks??=[]).push(n,s))}(e,s[e],t)}finally{null!==h&&no(h),jm(a),o.resolving=!1,EA()}}return r}function HA(n,t,e){return!!(e[t+(n>>NA)]&1<Array.isArray(e)?fu(e,t):t(e))}function UA(n,t,e){t>=n.length?n.push(e):n.splice(t,0,e)}function Qm(n,t){return t>=n.length-1?n.pop():n.splice(t,1)[0]}const mu=new Ht(""),GA=new Ht("",-1),S1=new Ht("");class $m{get(t,e=Sf){if(e===Sf){const i=new Error(`NullInjectorError: No provider for ${dt(t)}!`);throw i.name="NullInjectorError",i}return e}}function pj(...n){return{\u0275providers:XA(0,n),\u0275fromNgModule:!0}}function XA(n,...t){const e=[],i=new Set;let r;const s=o=>{e.push(o)};return fu(t,o=>{const a=o;Zm(a,s,[],i)&&(r||=[],r.push(a))}),void 0!==r&&qA(r,s),e}function qA(n,t){for(let e=0;e{t(s,i)})}}function Zm(n,t,e,i){if(!(n=vt(n)))return!1;let r=null,s=Dm(n);const o=!s&&ci(n);if(s||o){if(o&&!o.standalone)return!1;r=n}else{const l=n.ngModule;if(s=Dm(l),!s)return!1;r=l}const a=i.has(r);if(o){if(a)return!1;if(i.add(r),o.dependencies){const l="function"==typeof o.dependencies?o.dependencies():o.dependencies;for(const h of l)Zm(h,t,e,i)}}else{if(!s)return!1;{if(null!=s.imports&&!a){let h;i.add(r);try{fu(s.imports,c=>{Zm(c,t,e,i)&&(h||=[],h.push(c))})}finally{}void 0!==h&&qA(h,t)}if(!a){const h=Vc(r)||(()=>new r);t({provide:r,useFactory:h,deps:Qi},r),t({provide:S1,useValue:r,multi:!0},r),t({provide:mu,useValue:()=>Fi(r),multi:!0},r)}const l=s.providers;if(null!=l&&!a){const h=n;b1(l,c=>{t(c,h)})}}}return r!==n&&void 0!==n.providers}function b1(n,t){for(let e of n)Ql(e)&&(e=e.\u0275providers),Array.isArray(e)?b1(e,t):t(e)}const fj=Xe({provide:String,useValue:Xe});function M1(n){return null!==n&&"object"==typeof n&&fj in n}function Gc(n){return"function"==typeof n}const w1=new Ht(""),Jm={},vj={};let C1;function Km(){return void 0===C1&&(C1=new $m),C1}class Jl{}class yu extends Jl{get destroyed(){return this._destroyed}constructor(t,e,i,r){super(),this.parent=e,this.source=i,this.scopes=r,this.records=new Map,this._ngOnDestroyHooks=new Set,this._onDestroyHooks=[],this._destroyed=!1,D1(t,o=>this.processProvider(o)),this.records.set(GA,Su(void 0,this)),r.has("environment")&&this.records.set(Jl,Su(void 0,this));const s=this.records.get(w1);null!=s&&"string"==typeof s.value&&this.scopes.add(s.value),this.injectorDefTypes=new Set(this.get(S1,Qi,Di.Self))}destroy(){this.assertNotDestroyed(),this._destroyed=!0;try{for(const e of this._ngOnDestroyHooks)e.ngOnDestroy();const t=this._onDestroyHooks;this._onDestroyHooks=[];for(const e of t)e()}finally{this.records.clear(),this._ngOnDestroyHooks.clear(),this.injectorDefTypes.clear()}}onDestroy(t){return this.assertNotDestroyed(),this._onDestroyHooks.push(t),()=>this.removeOnDestroy(t)}runInContext(t){this.assertNotDestroyed();const e=Qh(this),i=no(void 0);try{return t()}finally{Qh(e),no(i)}}get(t,e=Sf,i=Di.Default){if(this.assertNotDestroyed(),t.hasOwnProperty(mf))return t[mf](this);i=Am(i);const s=Qh(this),o=no(void 0);try{if(!(i&Di.SkipSelf)){let l=this.records.get(t);if(void 0===l){const h=function bj(n){return"function"==typeof n||"object"==typeof n&&n instanceof Ht}(t)&&Em(t);l=h&&this.injectableDefInScope(h)?Su(E1(t),Jm):null,this.records.set(t,l)}if(null!=l)return this.hydrate(t,l)}return(i&Di.Self?Km():this.parent).get(t,e=i&Di.Optional&&e===Sf?null:e)}catch(a){if("NullInjectorError"===a.name){if((a[Tm]=a[Tm]||[]).unshift(dt(t)),s)throw a;return function z_(n,t,e,i){const r=n[Tm];throw t[_T]&&r.unshift(t[_T]),n.message=function R_(n,t,e,i=null){n=n&&"\n"===n.charAt(0)&&"\u0275"==n.charAt(1)?n.slice(2):n;let r=dt(t);if(Array.isArray(t))r=t.map(dt).join(" -> ");else if("object"==typeof t){let s=[];for(let o in t)if(t.hasOwnProperty(o)){let a=t[o];s.push(o+":"+("string"==typeof a?JSON.stringify(a):dt(a)))}r=`{${s.join(", ")}}`}return`${e}${i?"("+i+")":""}[${r}]: ${n.replace(L_,"\n ")}`}("\n"+n.message,r,e,i),n.ngTokenPath=r,n[Tm]=null,n}(a,t,"R3InjectorError",this.source)}throw a}finally{no(o),Qh(s)}}resolveInjectorInitializers(){const t=Qh(this),e=no(void 0);try{const r=this.get(mu,Qi,Di.Self);for(const s of r)s()}finally{Qh(t),no(e)}}toString(){const t=[],e=this.records;for(const i of e.keys())t.push(dt(i));return`R3Injector[${t.join(", ")}]`}assertNotDestroyed(){if(this._destroyed)throw new F(205,!1)}processProvider(t){let e=Gc(t=vt(t))?t:vt(t&&t.provide);const i=function yj(n){return M1(n)?Su(void 0,n.useValue):Su(JA(n),Jm)}(t);if(!Gc(t)&&!0===t.multi){let r=this.records.get(e);r||(r=Su(void 0,Jm,!0),r.factory=()=>Hb(r.multi),this.records.set(e,r)),e=t,r.multi.push(t)}this.records.set(e,i)}hydrate(t,e){return e.value===Jm&&(e.value=vj,e.value=e.factory()),"object"==typeof e.value&&e.value&&function Ij(n){return null!==n&&"object"==typeof n&&"function"==typeof n.ngOnDestroy}(e.value)&&this._ngOnDestroyHooks.add(e.value),e.value}injectableDefInScope(t){if(!t.providedIn)return!1;const e=vt(t.providedIn);return"string"==typeof e?"any"===e||this.scopes.has(e):this.injectorDefTypes.has(e)}removeOnDestroy(t){const e=this._onDestroyHooks.indexOf(t);-1!==e&&this._onDestroyHooks.splice(e,1)}}function E1(n){const t=Em(n),e=null!==t?t.factory:Vc(n);if(null!==e)return e;if(n instanceof Ht)throw new F(204,!1);if(n instanceof Function)return function mj(n){if(n.length>0)throw new F(204,!1);const e=function D_(n){return n&&(n[xm]||n[RT])||null}(n);return null!==e?()=>e.factory(n):()=>new n}(n);throw new F(204,!1)}function JA(n,t,e){let i;if(Gc(n)){const r=vt(n);return Vc(r)||E1(r)}if(M1(n))i=()=>vt(n.useValue);else if(function ZA(n){return!(!n||!n.useFactory)}(n))i=()=>n.useFactory(...Hb(n.deps||[]));else if(function $A(n){return!(!n||!n.useExisting)}(n))i=()=>Fi(vt(n.useExisting));else{const r=vt(n&&(n.useClass||n.provide));if(!function Sj(n){return!!n.deps}(n))return Vc(r)||E1(r);i=()=>new r(...Hb(n.deps))}return i}function Su(n,t,e=!1){return{factory:n,value:t,multi:e?[]:void 0}}function D1(n,t){for(const e of n)Array.isArray(e)?D1(e,t):e&&Ql(e)?D1(e.\u0275providers,t):t(e)}function iL(n,t=null,e=null,i){const r=function rL(n,t=null,e=null,i,r=new Set){const s=[e||Qi,pj(n)];return i=i||("object"==typeof n?void 0:dt(n)),new yu(s,t||Km(),i||null,r)}(n,t,e,i);return r.resolveInjectorInitializers(),r}let A1,Wo=(()=>{class n{static{this.THROW_IF_NOT_FOUND=Sf}static{this.NULL=new $m}static create(e,i){if(Array.isArray(e))return iL({name:""},i,e,"");{const r=e.name??"";return iL({name:r},e.parent,e.providers,r)}}static{this.\u0275prov=Yi({token:n,providedIn:"any",factory:()=>Fi(GA)})}static{this.__NG_ELEMENT_ID__=-1}}return n})();const L1=new Ht("",{providedIn:"root",factory:()=>Lj}),Lj="ng",sL=new Ht(""),Iu=new Ht("",{providedIn:"platform",factory:()=>"unknown"}),oL=new Ht("",{providedIn:"root",factory:()=>function $h(){if(void 0!==A1)return A1;if(typeof document<"u")return document;throw new F(210,!1)}().body?.querySelector("[ngCspNonce]")?.getAttribute("ngCspNonce")||null});function ny(n){return 128==(128&n.flags)}var Kh=function(n){return n[n.Important=1]="Important",n[n.DashCase=2]="DashCase",n}(Kh||{});const z1=new Map;let Vj=0;const H1="__ngContext__";function Rs(n,t){ks(t)?(n[H1]=t[Cf],function Yj(n){z1.set(n[Cf],n)}(t)):n[H1]=t}let B1;function F1(n,t){return B1(n,t)}function Mu(n,t,e,i,r){if(null!=i){let s,o=!1;Ps(i)?s=i:ks(i)&&(o=!0,i=i[Vr]);const a=pr(i);0===n&&null!==e?null==r?TL(t,e,a):qc(t,e,a,r||null,!0):1===n&&null!==e?qc(t,e,a,r||null,!0):2===n?function dy(n,t,e){const i=hy(n,t);i&&function a6(n,t,e,i){n.removeChild(t,e,i)}(n,i,t,e)}(t,a,o):3===n&&t.destroyNode(a),null!=s&&function c6(n,t,e,i,r){const s=e[rl];s!==pr(e)&&Mu(t,n,i,s,r);for(let a=mn;a0&&(n[e-1][Ma]=i[Ma]);const s=Qm(n,mn+t);!function e6(n,t){EL(n,t),t[Vr]=null,t[Os]=null}(i[Be],i);const o=s[il];null!==o&&o.detachView(s[Be]),i[vn]=null,i[Ma]=null,i[Ct]&=-129}return i}function ly(n,t){if(!(256&t[Ct])){const e=t[Yt];e.destroyNode&&uy(n,t,e,3,null,null),function i6(n){let t=n[Mf];if(!t)return U1(n[Be],n);for(;t;){let e=null;if(ks(t))e=t[Mf];else{const i=t[mn];i&&(e=i)}if(!e){for(;t&&!t[Ma]&&t!==n;)ks(t)&&U1(t[Be],t),t=t[vn];null===t&&(t=n),ks(t)&&U1(t[Be],t),e=t&&t[Ma]}t=e}}(t)}}function U1(n,t){if(!(256&t[Ct])){t[Ct]&=-129,t[Ct]|=256,t[Uc]&&function Gd(n){if(Vl(n),Vh(n))for(let t=0;t=0?i[o]():i[-o].unsubscribe(),s+=2}else e[s].call(i[e[s+1]]);null!==i&&(t[eu]=null);const r=t[Xh];if(null!==r){t[Xh]=null;for(let s=0;s-1){const{encapsulation:s}=n.data[i.directiveStart+r];if(s===Ia.None||s===Ia.Emulated)return null}return qs(i,e)}}(n,t.parent,e)}function qc(n,t,e,i,r){n.insertBefore(t,e,i,r)}function TL(n,t,e){n.appendChild(t,e)}function AL(n,t,e,i,r){null!==i?qc(n,t,e,i,r):TL(n,t,e)}function hy(n,t){return n.parentNode(t)}let V1,OL=function NL(n,t,e){return 40&n.type?qs(n,e):null};function cy(n,t,e,i){const r=j1(n,i,t),s=t[Yt],a=function LL(n,t,e){return OL(n,t,e)}(i.parent||t[Os],i,t);if(null!=r)if(Array.isArray(e))for(let l=0;lnull;function sM(n,t,e=!1){return JL(n,t,e)}class G6{}class rN{}class q6{resolveComponentFactory(t){throw function X6(n){const t=Error(`No component factory found for ${dt(n)}.`);return t.ngComponent=n,t}(t)}}let by=(()=>{class n{static{this.NULL=new q6}}return n})();function $6(){return Tu(fr(),Se())}function Tu(n,t){return new $c(qs(n,t))}let $c=(()=>{class n{constructor(e){this.nativeElement=e}static{this.__NG_ELEMENT_ID__=$6}}return n})();function Z6(n){return n instanceof $c?n.nativeElement:n}class sN{}let hM=(()=>{class n{constructor(){this.destroyNode=null}static{this.__NG_ELEMENT_ID__=()=>function J6(){const n=Se(),e=To(fr().index,n);return(ks(e)?e:n)[Yt]}()}}return n})(),K6=(()=>{class n{static{this.\u0275prov=Yi({token:n,providedIn:"root",factory:()=>null})}}return n})();const cM={};function Gf(n,t,e,i,r=!1){for(;null!==e;){const s=t[e.index];null!==s&&i.push(pr(s)),Ps(s)&&pN(s,i);const o=e.type;if(8&o)Gf(n,t,e.child,i);else if(32&o){const a=F1(e,t);let l;for(;l=a();)i.push(l)}else if(16&o){const a=PL(t,e);if(Array.isArray(a))i.push(...a);else{const l=Wc(t[Jr]);Gf(l[Be],l,a,i,!0)}}e=r?e.projectionNext:e.next}return i}function pN(n,t){for(let e=mn;e!1,producerRecomputeValue:()=>{},consumerMarkedDirty:()=>{},consumerOnSignalRead:()=>{},consumerIsAlwaysLive:!0,consumerMarkedDirty:n=>{Tf(n.lView)},consumerOnSignalRead(){this.lView[Uc]=this}};function gN(n){return mN(n[Mf])}function vN(n){return mN(n[Ma])}function mN(n){for(;null!==n&&!Ps(n);)n=n[Ma];return n}function pM(n){return n.ngOriginalError}class eh{constructor(){this._console=console}handleError(t){const e=this._findOriginalError(t);this._console.error("ERROR",t),e&&this._console.error("ORIGINAL ERROR",e)}_findOriginalError(t){let e=t&&pM(t);for(;e&&pM(e);)e=pM(e);return e||null}}const SN=new Ht("",{providedIn:"root",factory:()=>Ri(eh).handleError.bind(void 0)}),bN=new Ht("",{providedIn:"root",factory:()=>!1}),Qt={};function Ey(n=1){EN(xi(),Se(),zs()+n,!1)}function EN(n,t,e,i){if(!i)if(3==(3&t[Ct])){const s=n.preOrderCheckHooks;null!==s&&_m(t,s,e)}else{const s=n.preOrderHooks;null!==s&&Um(t,s,0,e)}Yc(e)}function Ot(n,t=Di.Default){const e=Se();return null===e?Fi(n,t):zA(fr(),e,vt(n),t)}function DN(n,t,e,i,r,s){const o=Wi(null);try{let a=null;r&Gh.SignalBased&&(a=t[i][Ts]),null!==a&&void 0!==a.transformFn&&(s=a.transformFn(s)),r&Gh.HasDecoratorInputTransform&&(s=n.inputTransforms[i].call(t,s)),null!==n.setInput?n.setInput(t,a,s,e,i):nA(t,a,i,s)}finally{Wi(o)}}function Dy(n,t,e,i,r,s,o,a,l,h,c){const d=t.blueprint.slice();return d[Vr]=r,d[Ct]=204|i,(null!==h||n&&2048&n[Ct])&&(d[Ct]|=2048),dA(d),d[vn]=d[tu]=n,d[Er]=e,d[ql]=o||n&&n[ql],d[Yt]=a||n&&n[Yt],d[Xs]=l||n&&n[Xs]||null,d[Os]=s,d[Cf]=function Wj(){return Vj++}(),d[wa]=c,d[eA]=h,d[Jr]=2==t.type?n[Jr]:d,d}function Au(n,t,e,i,r){let s=n.data[t];if(null===s)s=function fM(n,t,e,i,r){const s=vA(),o=Zb(),l=n.data[t]=function LV(n,t,e,i,r,s){let o=t?t.injectorIndex:-1,a=0;return function su(){return null!==Rt.skipHydrationRootTNode}()&&(a|=128),{type:e,index:i,insertBeforeIndex:null,injectorIndex:o,directiveStart:-1,directiveEnd:-1,directiveStylingLast:-1,componentOffset:-1,propertyBindings:null,flags:a,providerIndexes:0,value:r,attrs:s,mergedAttrs:null,localNames:null,initialInputs:void 0,inputs:null,outputs:null,tView:null,next:null,prev:null,projectionNext:null,child:null,parent:t,projection:null,styles:null,stylesWithoutHost:null,residualStyles:void 0,classes:null,classesWithoutHost:null,residualClasses:void 0,classBindings:0,styleBindings:0}}(0,o?s:s&&s.parent,e,t,i,r);return null===n.firstChild&&(n.firstChild=l),null!==s&&(o?null==s.child&&null!==l.parent&&(s.child=l):null===s.next&&(s.next=l,l.prev=s)),l}(n,t,e,i,r),function MU(){return Rt.lFrame.inI18n}()&&(s.flags|=32);else if(64&s.type){s.type=e,s.value=i,s.attrs=r;const o=function Af(){const n=Rt.lFrame,t=n.currentTNode;return n.isParent?t:t.parent}();s.injectorIndex=null===o?-1:o.injectorIndex}return ol(s,!0),s}function Xf(n,t,e,i){if(0===e)return-1;const r=t.length;for(let s=0;sUt&&EN(n,t,Ut,!1),nl(o?2:0,r),e(i,r)}finally{Yc(s),nl(o?3:1,r)}}function gM(n,t,e){if(jb(t)){const i=Wi(null);try{const s=t.directiveEnd;for(let o=t.directiveStart;onull;function LN(n,t,e,i,r){for(let s in t){if(!t.hasOwnProperty(s))continue;const o=t[s];if(void 0===o)continue;i??={};let a,l=Gh.None;Array.isArray(o)?(a=o[0],l=o[1]):a=o;let h=s;if(null!==r){if(!r.hasOwnProperty(s))continue;h=r[s]}0===n?NN(i,e,h,a,l):NN(i,e,h,a)}return i}function NN(n,t,e,i,r){let s;n.hasOwnProperty(e)?(s=n[e]).push(t,i):s=n[e]=[t,i],void 0!==r&&s.push(r)}function ON(n,t,e,i,r,s){for(let h=0;h0;){const e=n[--t];if("number"==typeof e&&e<0)return e}return 0})(o)!=a&&o.push(a),o.push(e,i,s)}}(n,t,i,Xf(n,e,r.hostVars,Qt),r)}function YV(n,t,e,i,r,s){const o=s[t];if(null!==o)for(let a=0;an.nextProducerIndex;)n.producerNode.pop(),n.producerLastReadVersion.pop(),n.producerIndexOfThis.pop()}}(a,o),function pV(n){n.lView[Uc]!==n&&(n.lView=null,fN.push(n))}(a)),r1()}}function FN(n,t){for(let e=gN(n);null!==e;e=vN(e))for(let i=mn;i-1&&(Ff(t,i),Qm(e,i))}this._attachedToViewContainer=!1}ly(this._lView[Be],this._lView)}onDestroy(t){!function Hm(n,t){if(256==(256&n[Ct]))throw new F(911,!1);null===n[Xh]&&(n[Xh]=[]),n[Xh].push(t)}(this._lView,t)}markForCheck(){qf(this._cdRefInjectingView||this._lView)}detach(){this._lView[Ct]&=-129}reattach(){qb(this._lView),this._lView[Ct]|=128}detectChanges(){this._lView[Ct]|=1024,function CM(n,t=!0){const e=n[ql],i=e.rendererFactory;i.begin?.();try{!function XV(n){EM(n,0);let t=0;for(;pA(n);){if(100===t)throw new F(103,!1);t++,EM(n,1)}}(n)}catch(s){throw t&&Ty(n,s),s}finally{i.end?.(),e.inlineEffectRunner?.flush()}}(this._lView,this.notifyErrorHandler)}checkNoChanges(){}attachToViewContainerRef(){if(this._appRef)throw new F(902,!1);this._attachedToViewContainer=!0}detachFromAppRef(){this._appRef=null,EL(this._lView[Be],this._lView)}attachToAppRef(t){if(this._attachedToViewContainer)throw new F(902,!1);this._appRef=t,qb(this._lView)}}const VN=new Set;function xM(n){return t=>{setTimeout(n,void 0,t)}}const Yo=class h7 extends Pt{constructor(t=!1){super(),this.__isAsync=t}emit(t){super.next(t)}subscribe(t,e,i){let r=t,s=e||(()=>null),o=i;if(t&&"object"==typeof t){const l=t;r=l.next?.bind(l),s=l.error?.bind(l),o=l.complete?.bind(l)}this.__isAsync&&(s=xM(s),r&&(r=xM(r)),o&&(o=xM(o)));const a=super.subscribe({next:r,error:s,complete:o});return t instanceof As&&t.add(a),a}};function WN(...n){}class zr{constructor({enableLongStackTrace:t=!1,shouldCoalesceEventChangeDetection:e=!1,shouldCoalesceRunChangeDetection:i=!1}){if(this.hasPendingMacrotasks=!1,this.hasPendingMicrotasks=!1,this.isStable=!0,this.onUnstable=new Yo(!1),this.onMicrotaskEmpty=new Yo(!1),this.onStable=new Yo(!1),this.onError=new Yo(!1),typeof Zone>"u")throw new F(908,!1);Zone.assertZonePatched();const r=this;r._nesting=0,r._outer=r._inner=Zone.current,Zone.TaskTrackingZoneSpec&&(r._inner=r._inner.fork(new Zone.TaskTrackingZoneSpec)),t&&Zone.longStackTraceZoneSpec&&(r._inner=r._inner.fork(Zone.longStackTraceZoneSpec)),r.shouldCoalesceEventChangeDetection=!i&&e,r.shouldCoalesceRunChangeDetection=i,r.lastRequestAnimationFrameId=-1,r.nativeRequestAnimationFrame=function c7(){const n="function"==typeof rr.requestAnimationFrame;let t=rr[n?"requestAnimationFrame":"setTimeout"],e=rr[n?"cancelAnimationFrame":"clearTimeout"];if(typeof Zone<"u"&&t&&e){const i=t[Zone.__symbol__("OriginalDelegate")];i&&(t=i);const r=e[Zone.__symbol__("OriginalDelegate")];r&&(e=r)}return{nativeRequestAnimationFrame:t,nativeCancelAnimationFrame:e}}().nativeRequestAnimationFrame,function p7(n){const t=()=>{!function u7(n){n.isCheckStableRunning||-1!==n.lastRequestAnimationFrameId||(n.lastRequestAnimationFrameId=n.nativeRequestAnimationFrame.call(rr,()=>{n.fakeTopEventTask||(n.fakeTopEventTask=Zone.root.scheduleEventTask("fakeTopEventTask",()=>{n.lastRequestAnimationFrameId=-1,AM(n),n.isCheckStableRunning=!0,TM(n),n.isCheckStableRunning=!1},void 0,()=>{},()=>{})),n.fakeTopEventTask.invoke()}),AM(n))}(n)};n._inner=n._inner.fork({name:"angular",properties:{isAngularZone:!0},onInvokeTask:(e,i,r,s,o,a)=>{if(function f7(n){return!(!Array.isArray(n)||1!==n.length)&&!0===n[0].data?.__ignore_ng_zone__}(a))return e.invokeTask(r,s,o,a);try{return YN(n),e.invokeTask(r,s,o,a)}finally{(n.shouldCoalesceEventChangeDetection&&"eventTask"===s.type||n.shouldCoalesceRunChangeDetection)&&t(),QN(n)}},onInvoke:(e,i,r,s,o,a,l)=>{try{return YN(n),e.invoke(r,s,o,a,l)}finally{n.shouldCoalesceRunChangeDetection&&t(),QN(n)}},onHasTask:(e,i,r,s)=>{e.hasTask(r,s),i===r&&("microTask"==s.change?(n._hasPendingMicrotasks=s.microTask,AM(n),TM(n)):"macroTask"==s.change&&(n.hasPendingMacrotasks=s.macroTask))},onHandleError:(e,i,r,s)=>(e.handleError(r,s),n.runOutsideAngular(()=>n.onError.emit(s)),!1)})}(r)}static isInAngularZone(){return typeof Zone<"u"&&!0===Zone.current.get("isAngularZone")}static assertInAngularZone(){if(!zr.isInAngularZone())throw new F(909,!1)}static assertNotInAngularZone(){if(zr.isInAngularZone())throw new F(909,!1)}run(t,e,i){return this._inner.run(t,e,i)}runTask(t,e,i,r){const s=this._inner,o=s.scheduleEventTask("NgZoneEvent: "+r,t,d7,WN,WN);try{return s.runTask(o,e,i)}finally{s.cancelTask(o)}}runGuarded(t,e,i){return this._inner.runGuarded(t,e,i)}runOutsideAngular(t){return this._outer.run(t)}}const d7={};function TM(n){if(0==n._nesting&&!n.hasPendingMicrotasks&&!n.isStable)try{n._nesting++,n.onMicrotaskEmpty.emit(null)}finally{if(n._nesting--,!n.hasPendingMicrotasks)try{n.runOutsideAngular(()=>n.onStable.emit(null))}finally{n.isStable=!0}}}function AM(n){n.hasPendingMicrotasks=!!(n._hasPendingMicrotasks||(n.shouldCoalesceEventChangeDetection||n.shouldCoalesceRunChangeDetection)&&-1!==n.lastRequestAnimationFrameId)}function YN(n){n._nesting++,n.isStable&&(n.isStable=!1,n.onUnstable.emit(null))}function QN(n){n._nesting--,TM(n)}let Zf=(()=>{class n{constructor(){this.handler=null,this.internalCallbacks=[]}execute(){const e=[...this.internalCallbacks];this.internalCallbacks.length=0;for(const r of e)r();return!!this.handler?.execute()||e.length>0}ngOnDestroy(){this.handler?.destroy(),this.handler=null,this.internalCallbacks.length=0}static{this.\u0275prov=Yi({token:n,providedIn:"root",factory:()=>new n})}}return n})();function y7(n,t){const e=To(t,n),i=e[Be];!function S7(n,t){for(let e=t.length;e0&&HL(n,e,s.join(" "))}}(u,w,f,i),void 0!==e&&function A7(n,t,e){const i=n.projection=[];for(let r=0;r=0;i--){const r=n[i];r.hostVars=t+=r.hostVars,r.hostAttrs=bf(r.hostAttrs,e=bf(e,r.hostAttrs))}}(i)}function N7(n,t){for(const e in t.inputs){if(!t.inputs.hasOwnProperty(e)||n.inputs.hasOwnProperty(e))continue;const i=t.inputs[e];if(void 0!==i&&(n.inputs[e]=i,n.declaredInputs[e]=t.declaredInputs[e],null!==t.inputTransforms)){const r=Array.isArray(i)?i[0]:i;if(!t.inputTransforms.hasOwnProperty(r))continue;n.inputTransforms??={},n.inputTransforms[r]=t.inputTransforms[r]}}}function Ly(n){return n===tl?{}:n===Qi?[]:n}function k7(n,t){const e=n.viewQuery;n.viewQuery=e?(i,r)=>{t(i,r),e(i,r)}:t}function P7(n,t){const e=n.contentQueries;n.contentQueries=e?(i,r,s)=>{t(i,r,s),e(i,r,s)}:t}function z7(n,t){const e=n.hostBindings;n.hostBindings=e?(i,r)=>{t(i,r),e(i,r)}:t}function Nu(n,t){return!t||null===t.firstChild||ny(n)}function ng(n,t,e,i=!0){const r=t[Be];if(function r6(n,t,e,i){const r=mn+i,s=e.length;i>0&&(e[r-1][Ma]=t),i{class n{static{this.__NG_ELEMENT_ID__=h9}}return n})();function h9(){return pO(fr(),Se())}const c9=xn,dO=class extends c9{constructor(t,e,i){super(),this._lContainer=t,this._hostTNode=e,this._hostLView=i}get element(){return Tu(this._hostTNode,this._hostLView)}get injector(){return new Vn(this._hostTNode,this._hostLView)}get parentInjector(){const t=Wm(this._hostTNode,this._hostLView);if(o1(t)){const e=Of(t,this._hostLView),i=Nf(t);return new Vn(e[Be].data[i+8],e)}return new Vn(null,this._hostLView)}clear(){for(;this.length>0;)this.remove(this.length-1)}get(t){const e=uO(this._lContainer);return null!==e&&e[t]||null}get length(){return this._lContainer.length-mn}createEmbeddedView(t,e,i){let r,s;"number"==typeof i?r=i:null!=i&&(r=i.index,s=i.injector);const a=t.createEmbeddedViewImpl(e||{},s,null);return this.insertImpl(a,r,Nu(this._hostTNode,null)),a}createComponent(t,e,i,r,s){const o=t&&!function kf(n){return"function"==typeof n}(t);let a;if(o)a=e;else{const f=e||{};a=f.index,i=f.injector,r=f.projectableNodes,s=f.environmentInjector||f.ngModuleRef}const l=o?t:new Jf(ci(t)),h=i||this.parentInjector;if(!s&&null==l.ngModule){const g=(o?h:this.parentInjector).get(Jl,null);g&&(s=g)}ci(l.componentType??{});const p=l.create(h,r,null,s);return this.insertImpl(p.hostView,a,Nu(this._hostTNode,null)),p}insert(t,e){return this.insertImpl(t,e,!0)}insertImpl(t,e,i){const r=t._lView;if(function hU(n){return Ps(n[vn])}(r)){const a=this.indexOf(t);if(-1!==a)this.detach(a);else{const l=r[vn],h=new dO(l,l[Os],l[vn]);h.detach(h.indexOf(t))}}const s=this._adjustIndex(e),o=this._lContainer;return ng(o,r,s,i),t.attachToViewContainerRef(),UA(HM(o),s,t),t}move(t,e){return this.insert(t,e)}indexOf(t){const e=uO(this._lContainer);return null!==e?e.indexOf(t):-1}remove(t){const e=this._adjustIndex(t,-1),i=Ff(this._lContainer,e);i&&(Qm(HM(this._lContainer),e),ly(i[Be],i))}detach(t){const e=this._adjustIndex(t,-1),i=Ff(this._lContainer,e);return i&&null!=Qm(HM(this._lContainer),e)?new $f(i):null}_adjustIndex(t,e=0){return t??this.length+e}};function uO(n){return n[8]}function HM(n){return n[8]||(n[8]=[])}function pO(n,t){let e;const i=t[n.index];return Ps(i)?e=i:(e=function PN(n,t,e,i){return[n,!0,0,t,null,i,null,e,null,null]}(i,t,null,n),t[n.index]=e,xy(t,e)),fO(e,t,n,i),new dO(e,n,t)}let fO=function vO(n,t,e,i){if(n[rl])return;let r;r=8&e.type?pr(i):function d9(n,t){const e=n[Yt],i=e.createComment(""),r=qs(t,n);return qc(e,hy(e,r),i,function l6(n,t){return n.nextSibling(t)}(e,r),!1),i}(t,e),n[rl]=r};function Xu(n,t,e){const i=Se();return function Tn(n,t,e){return!Object.is(n[t],e)&&(n[t]=e,!0)}(i,function al(){return Rt.lFrame.bindingIndex++}(),t)&&function No(n,t,e,i,r,s,o,a){const l=qs(t,e);let c,h=t.inputs;!a&&null!=h&&(c=h[i])?(wM(n,e,c,i,r),jc(t)&&function kV(n,t){const e=To(t,n);16&e[Ct]||(e[Ct]|=64)}(e,t.index)):3&t.type&&(i=function OV(n){return"class"===n?"className":"for"===n?"htmlFor":"formaction"===n?"formAction":"innerHtml"===n?"innerHTML":"readonly"===n?"readOnly":"tabindex"===n?"tabIndex":n}(i),r=null!=o?o(r,t.value||"",i):r,s.setProperty(l,i,r))}(xi(),function Pr(){const n=Rt.lFrame;return xf(n.tView,n.selectedIndex)}(),i,n,t,i[Yt],e,!1),Xu}function $M(n,t,e,i,r){const o=r?"class":"style";wM(n,e,t.inputs[o],o,i)}function id(n,t,e,i){const r=Se(),s=xi(),o=Ut+n,a=r[Yt],l=s.firstCreatePass?function B8(n,t,e,i,r,s){const o=t.consts,l=Au(t,n,2,i,sl(o,r));return function SM(n,t,e,i){if(gA()){const r=null===i?null:{"":-1},s=function FV(n,t){const e=n.directiveRegistry;let i=null,r=null;if(e)for(let s=0;s(qh(!0),ay(i,r,function DA(){return Rt.lFrame.currentNamespace}()));const $u="en-US";let Mk=$u;function ow(n){return!!n&&"function"==typeof n.then}function Gk(n){return!!n&&"function"==typeof n.subscribe}function aw(n,t,e,i){const r=Se(),s=xi(),o=fr();return function qk(n,t,e,i,r,s,o){const a=zm(i),h=n.firstCreatePass&&HN(n),c=t[Er],d=RN(t);let u=!0;if(3&i.type||o){const g=qs(i,t),v=o?o(g):g,y=d.length,S=o?M=>o(pr(M[i.index])):i.index;let b=null;if(!o&&a&&(b=function UW(n,t,e,i){const r=n.cleanup;if(null!=r)for(let s=0;sl?a[l]:null}"string"==typeof o&&(s+=2)}return null}(n,t,r,i.index)),null!==b)(b.__ngLastListenerFn__||b).__ngNextListenerFn__=s,b.__ngLastListenerFn__=s,u=!1;else{s=Zk(i,t,c,s,!1);const M=e.listen(v,r,s);d.push(s,M),h&&h.push(r,S,y,y+1)}}else s=Zk(i,t,c,s,!1);const p=i.outputs;let f;if(u&&null!==p&&(f=p[r])){const g=f.length;if(g)for(let v=0;v-1?To(n.index,t):t);let l=$k(t,e,i,o),h=s.__ngNextListenerFn__;for(;h;)l=$k(t,e,h,o)&&l,h=h.__ngNextListenerFn__;return r&&!1===l&&o.preventDefault(),l}}function QW(){return this._results[Symbol.iterator]()}class hw{get changes(){return this._changes??=new Yo}constructor(t=!1){this._emitDistinctChangesOnly=t,this.dirty=!0,this._results=[],this._changesDetected=!1,this._changes=void 0,this.length=0,this.first=void 0,this.last=void 0;const e=hw.prototype;e[Symbol.iterator]||(e[Symbol.iterator]=QW)}get(t){return this._results[t]}map(t){return this._results.map(t)}filter(t){return this._results.filter(t)}find(t){return this._results.find(t)}reduce(t,e){return this._results.reduce(t,e)}forEach(t){this._results.forEach(t)}some(t){return this._results.some(t)}toArray(){return this._results.slice()}toString(){return this._results.toString()}reset(t,e){this.dirty=!1;const i=function oo(n){return n.flat(Number.POSITIVE_INFINITY)}(t);(this._changesDetected=!function $U(n,t,e){if(n.length!==t.length)return!1;for(let i=0;i{class n{static{this.__NG_ELEMENT_ID__=qW}}return n})();const GW=ih,XW=class extends GW{constructor(t,e,i){super(),this._declarationLView=t,this._declarationTContainer=e,this.elementRef=i}get ssrId(){return this._declarationTContainer.tView?.ssrId||null}createEmbeddedView(t,e){return this.createEmbeddedViewImpl(t,e)}createEmbeddedViewImpl(t,e,i){const r=function rg(n,t,e,i){const r=t.tView,a=Dy(n,r,e,4096&n[Ct]?4096:16,null,t,null,null,null,i?.injector??null,i?.dehydratedView??null);a[wf]=n[t.index];const h=n[il];return null!==h&&(a[il]=h.createEmbeddedView(r)),LM(r,a,e),a}(this._declarationLView,this._declarationTContainer,t,{injector:e,dehydratedView:i});return new $f(r)}};function qW(){return Gy(fr(),Se())}function Gy(n,t){return 4&n.type?new XW(t,n,Tu(n,t)):null}class cw{constructor(t){this.queryList=t,this.matches=null}clone(){return new cw(this.queryList)}setDirty(){this.queryList.setDirty()}}class dw{constructor(t=[]){this.queries=t}createEmbeddedView(t){const e=t.queries;if(null!==e){const i=null!==t.contentQueries?t.contentQueries[0]:e.length,r=[];for(let s=0;s0)i.push(o[a/2]);else{const h=s[a+1],c=t[-l];for(let d=mn;d(qh(!0),function oy(n,t){return n.createText(t)}(t[Yt],i));function vw(n,t,e,i,r){if(n=vt(n),Array.isArray(n))for(let s=0;s>20;if(Gc(n)||!n.multi){const p=new Lf(h,r,Ot),f=yw(l,t,r?c:c+u,d);-1===f?(h1(Vm(a,o),s,l),mw(s,n,t.length),t.push(l),a.directiveStart++,a.directiveEnd++,r&&(a.providerIndexes+=1048576),e.push(p),o.push(p)):(e[f]=p,o[f]=p)}else{const p=yw(l,t,c+u,d),f=yw(l,t,c,c+u),v=f>=0&&e[f];if(r&&!v||!r&&!(p>=0&&e[p])){h1(Vm(a,o),s,l);const y=function yY(n,t,e,i,r){const s=new Lf(n,e,Ot);return s.multi=[],s.index=t,s.componentProviders=0,kP(s,r,i&&!e),s}(r?mY:vY,e.length,r,i,h);!r&&v&&(e[f].providerFactory=y),mw(s,n,t.length,0),t.push(l),a.directiveStart++,a.directiveEnd++,r&&(a.providerIndexes+=1048576),e.push(y),o.push(y)}else mw(s,n,p>-1?p:f,kP(e[r?f:p],h,!r&&i));!r&&i&&v&&e[f].componentProviders++}}}function mw(n,t,e,i){const r=Gc(t),s=function gj(n){return!!n.useClass}(t);if(r||s){const l=(s?vt(t.useClass):t).prototype.ngOnDestroy;if(l){const h=n.destroyHooks||(n.destroyHooks=[]);if(!r&&t.multi){const c=h.indexOf(e);-1===c?h.push(e,[i,l]):h[c+1].push(i,l)}else h.push(e,l)}}}function kP(n,t,e){return e&&n.componentProviders++,n.multi.push(t)-1}function yw(n,t,e,i){for(let r=e;r{e.providersResolver=(i,r)=>function gY(n,t,e){const i=xi();if(i.firstCreatePass){const r=Ca(n);vw(e,i.data,i.blueprint,r,!0),vw(t,i.data,i.blueprint,r,!1)}}(i,r?r(n):n,t)}}class sd{}class zP extends sd{constructor(t){super(),this.componentFactoryResolver=new JN(this),this.instance=null;const e=new yu([...t.providers,{provide:sd,useValue:this},{provide:by,useValue:this.componentFactoryResolver}],t.parent||Km(),t.debugName,new Set(["environment"]));this.injector=e,t.runEnvironmentInitializers&&e.resolveInjectorInitializers()}destroy(){this.injector.destroy()}onDestroy(t){this.injector.onDestroy(t)}}let wY=(()=>{class n{constructor(e){this._injector=e,this.cachedInjectors=new Map}getOrCreateStandaloneInjector(e){if(!e.standalone)return null;if(!this.cachedInjectors.has(e)){const i=XA(0,e.type),r=i.length>0?function MY(n,t,e=null){return new zP({providers:n,parent:t,debugName:e,runEnvironmentInitializers:!0}).injector}([i],this._injector,`Standalone[${e.type.name}]`):null;this.cachedInjectors.set(e,r)}return this.cachedInjectors.get(e)}ngOnDestroy(){try{for(const e of this.cachedInjectors.values())null!==e&&e.destroy()}finally{this.cachedInjectors.clear()}}static{this.\u0275prov=Yi({token:n,providedIn:"environment",factory:()=>new n(Fi(Jl))})}}return n})();function RP(n){(function Zc(n){VN.has(n)||(VN.add(n),performance?.mark?.("mark_feature_usage",{detail:{feature:n}}))})("NgStandalone"),n.getStandaloneInjector=t=>t.get(wY).getOrCreateStandaloneInjector(n)}let Tw=(()=>{class n{constructor(){this.taskId=0,this.pendingTasks=new Set,this.hasPendingTasks=new _o(!1)}get _hasPendingTasks(){return this.hasPendingTasks.value}add(){this._hasPendingTasks||this.hasPendingTasks.next(!0);const e=this.taskId++;return this.pendingTasks.add(e),e}remove(e){this.pendingTasks.delete(e),0===this.pendingTasks.size&&this._hasPendingTasks&&this.hasPendingTasks.next(!1)}ngOnDestroy(){this.pendingTasks.clear(),this._hasPendingTasks&&this.hasPendingTasks.next(!1)}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();const g2=new Ht(""),XQ=new Ht("");let kw=(()=>{class n{constructor(){this.initialized=!1,this.done=!1,this.donePromise=new Promise((e,i)=>{this.resolve=e,this.reject=i}),this.appInits=Ri(XQ,{optional:!0})??[]}runInitializers(){if(this.initialized)return;const e=[];for(const r of this.appInits){const s=r();if(ow(s))e.push(s);else if(Gk(s)){const o=new Promise((a,l)=>{s.subscribe({complete:a,error:l})});e.push(o)}}const i=()=>{this.done=!0,this.resolve()};Promise.all(e).then(()=>{i()}).catch(r=>{this.reject(r)}),0===e.length&&i(),this.initialized=!0}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();const v2=new Ht("");let Ku=(()=>{class n{constructor(){this._bootstrapListeners=[],this._runningTick=!1,this._destroyed=!1,this._destroyListeners=[],this._views=[],this.internalErrorHandler=Ri(SN),this.afterRenderEffectManager=Ri(Zf),this.componentTypes=[],this.components=[],this.isStable=Ri(Tw).hasPendingTasks.pipe(jr(e=>!e)),this._injector=Ri(Jl)}get destroyed(){return this._destroyed}get injector(){return this._injector}bootstrap(e,i){const r=e instanceof rN;if(!this._injector.get(kw).done)throw!r&&function _c(n){const t=ci(n)||jn(n)||gs(n);return null!==t&&t.standalone}(e),new F(405,!1);let o;o=r?e:this._injector.get(by).resolveComponentFactory(e),this.componentTypes.push(o.componentType);const a=function $Q(n){return n.isBoundToModule}(o)?void 0:this._injector.get(sd),h=o.create(Wo.NULL,[],i||o.selector,a),c=h.location.nativeElement,d=h.injector.get(g2,null);return d?.registerApplication(c),h.onDestroy(()=>{this.detachView(h.hostView),Ky(this.components,h),d?.unregisterApplication(c)}),this._loadComponent(h),h}tick(){if(this._runningTick)throw new F(101,!1);try{this._runningTick=!0;for(let e of this._views)e.detectChanges()}catch(e){this.internalErrorHandler(e)}finally{try{this.afterRenderEffectManager.execute()}catch(e){this.internalErrorHandler(e)}this._runningTick=!1}}attachView(e){const i=e;this._views.push(i),i.attachToAppRef(this)}detachView(e){const i=e;Ky(this._views,i),i.detachFromAppRef()}_loadComponent(e){this.attachView(e.hostView),this.tick(),this.components.push(e);const i=this._injector.get(v2,[]);[...this._bootstrapListeners,...i].forEach(r=>r(e))}ngOnDestroy(){if(!this._destroyed)try{this._destroyListeners.forEach(e=>e()),this._views.slice().forEach(e=>e.destroy())}finally{this._destroyed=!0,this._views=[],this._bootstrapListeners=[],this._destroyListeners=[]}}onDestroy(e){return this._destroyListeners.push(e),()=>Ky(this._destroyListeners,e)}destroy(){if(this._destroyed)throw new F(406,!1);const e=this._injector;e.destroy&&!e.destroyed&&e.destroy()}get viewCount(){return this._views.length}warnIfDestroyed(){}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();function Ky(n,t){const e=n.indexOf(t);e>-1&&n.splice(e,1)}let JQ=(()=>{class n{constructor(){this.zone=Ri(zr),this.applicationRef=Ri(Ku)}initialize(){this._onMicrotaskEmptySubscription||(this._onMicrotaskEmptySubscription=this.zone.onMicrotaskEmpty.subscribe({next:()=>{this.zone.run(()=>{this.applicationRef.tick()})}}))}ngOnDestroy(){this._onMicrotaskEmptySubscription?.unsubscribe()}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();function b2(n){return[{provide:zr,useFactory:n},{provide:mu,multi:!0,useFactory:()=>{const t=Ri(JQ,{optional:!0});return()=>t.initialize()}},{provide:mu,multi:!0,useFactory:()=>{const t=Ri(tG);return()=>{t.initialize()}}},{provide:SN,useFactory:KQ}]}function KQ(){const n=Ri(zr),t=Ri(eh);return e=>n.runOutsideAngular(()=>t.handleError(e))}function eG(n){return function I1(n){return{\u0275providers:n}}([[],b2(()=>new zr(function M2(n){return{enableLongStackTrace:!1,shouldCoalesceEventChangeDetection:n?.eventCoalescing??!1,shouldCoalesceRunChangeDetection:n?.runCoalescing??!1}}(n)))])}let tG=(()=>{class n{constructor(){this.subscription=new As,this.initialized=!1,this.zone=Ri(zr),this.pendingTasks=Ri(Tw)}initialize(){if(this.initialized)return;this.initialized=!0;let e=null;!this.zone.isStable&&!this.zone.hasPendingMacrotasks&&!this.zone.hasPendingMicrotasks&&(e=this.pendingTasks.add()),this.zone.runOutsideAngular(()=>{this.subscription.add(this.zone.onStable.subscribe(()=>{zr.assertNotInAngularZone(),queueMicrotask(()=>{null!==e&&!this.zone.hasPendingMacrotasks&&!this.zone.hasPendingMicrotasks&&(this.pendingTasks.remove(e),e=null)})}))}),this.subscription.add(this.zone.onUnstable.subscribe(()=>{zr.assertInAngularZone(),e??=this.pendingTasks.add()}))}ngOnDestroy(){this.subscription.unsubscribe()}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();const rh=new Ht("",{providedIn:"root",factory:()=>Ri(rh,Di.Optional|Di.SkipSelf)||function iG(){return typeof $localize<"u"&&$localize.locale||$u}()}),Pw=new Ht("");let rc=null;function DG(n){try{const{rootComponent:t,appProviders:e,platformProviders:i}=n,r=function aG(n=[]){if(rc)return rc;const t=function E2(n=[],t){return Wo.create({name:t,providers:[{provide:w1,useValue:"platform"},{provide:Pw,useValue:new Set([()=>rc=null])},...n]})}(n);return rc=t,function m2(){!function bb(n){qd=n}(()=>{throw new F(600,!1)})}(),function D2(n){n.get(sL,null)?.forEach(e=>e())}(t),t}(i),s=[eG(),...e||[]],a=new zP({providers:s,parent:r,debugName:"",runEnvironmentInitializers:!1}).injector,l=a.get(zr);return l.run(()=>{a.resolveInjectorInitializers();const h=a.get(eh,null);let c;l.runOutsideAngular(()=>{c=l.onError.subscribe({next:p=>{h.handleError(p)}})});const d=()=>a.destroy(),u=r.get(Pw);return u.add(d),a.onDestroy(()=>{c.unsubscribe(),u.delete(d)}),function y2(n,t,e){try{const i=e();return ow(i)?i.catch(r=>{throw t.runOutsideAngular(()=>n.handleError(r)),r}):i}catch(i){throw t.runOutsideAngular(()=>n.handleError(i)),i}}(h,l,()=>{const p=a.get(kw);return p.runInitializers(),p.donePromise.then(()=>{!function wk(n){ro(n,"Expected localeId to be defined"),"string"==typeof n&&(Mk=n.toLowerCase().replace(/_/g,"-"))}(a.get(rh,$u)||$u);const g=a.get(Ku);return void 0!==t&&g.bootstrap(t),g})})})}catch(t){return Promise.reject(t)}}let $2=null;function jw(){return $2}class UG{}const ad=new Ht("");let sq=(()=>{class n{static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275mod=Nm({type:n})}static{this.\u0275inj=yf({})}}return n})();function uz(n){return"server"===n}class kq extends UG{constructor(){super(...arguments),this.supportsDOMEvents=!0}}class sC extends kq{static makeCurrent(){!function _G(n){$2??=n}(new sC)}onAndCancel(t,e,i){return t.addEventListener(e,i),()=>{t.removeEventListener(e,i)}}dispatchEvent(t,e){t.dispatchEvent(e)}remove(t){t.parentNode&&t.parentNode.removeChild(t)}createElement(t,e){return(e=e||this.getDefaultDocument()).createElement(t)}createHtmlDocument(){return document.implementation.createHTMLDocument("fakeTitle")}getDefaultDocument(){return document}isElementNode(t){return t.nodeType===Node.ELEMENT_NODE}isShadowRoot(t){return t instanceof DocumentFragment}getGlobalEventTarget(t,e){return"window"===e?window:"document"===e?t:"body"===e?t.body:null}getBaseHref(t){const e=function Pq(){return Eg=Eg||document.querySelector("base"),Eg?Eg.getAttribute("href"):null}();return null==e?null:function zq(n){return new URL(n,document.baseURI).pathname}(e)}resetBaseElement(){Eg=null}getUserAgent(){return window.navigator.userAgent}getCookie(t){return function xX(n,t){t=encodeURIComponent(t);for(const e of n.split(";")){const i=e.indexOf("="),[r,s]=-1==i?[e,""]:[e.slice(0,i),e.slice(i+1)];if(r.trim()===t)return decodeURIComponent(s)}return null}(document.cookie,t)}}let Eg=null,Hq=(()=>{class n{build(){return new XMLHttpRequest}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();const oC=new Ht("");let vz=(()=>{class n{constructor(e,i){this._zone=i,this._eventNameToPlugin=new Map,e.forEach(r=>{r.manager=this}),this._plugins=e.slice().reverse()}addEventListener(e,i,r){return this._findPluginFor(i).addEventListener(e,i,r)}getZone(){return this._zone}_findPluginFor(e){let i=this._eventNameToPlugin.get(e);if(i)return i;if(i=this._plugins.find(s=>s.supports(e)),!i)throw new F(5101,!1);return this._eventNameToPlugin.set(e,i),i}static{this.\u0275fac=function(i){return new(i||n)(Fi(oC),Fi(zr))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();class mz{constructor(t){this._doc=t}}const aC="ng-app-id";let yz=(()=>{class n{constructor(e,i,r,s={}){this.doc=e,this.appId=i,this.nonce=r,this.platformId=s,this.styleRef=new Map,this.hostNodes=new Set,this.styleNodesInDOM=this.collectServerRenderedStyles(),this.platformIsServer=uz(s),this.resetHostNodes()}addStyles(e){for(const i of e)1===this.changeUsageCount(i,1)&&this.onStyleAdded(i)}removeStyles(e){for(const i of e)this.changeUsageCount(i,-1)<=0&&this.onStyleRemoved(i)}ngOnDestroy(){const e=this.styleNodesInDOM;e&&(e.forEach(i=>i.remove()),e.clear());for(const i of this.getAllStyles())this.onStyleRemoved(i);this.resetHostNodes()}addHost(e){this.hostNodes.add(e);for(const i of this.getAllStyles())this.addStyleToHost(e,i)}removeHost(e){this.hostNodes.delete(e)}getAllStyles(){return this.styleRef.keys()}onStyleAdded(e){for(const i of this.hostNodes)this.addStyleToHost(i,e)}onStyleRemoved(e){const i=this.styleRef;i.get(e)?.elements?.forEach(r=>r.remove()),i.delete(e)}collectServerRenderedStyles(){const e=this.doc.head?.querySelectorAll(`style[${aC}="${this.appId}"]`);if(e?.length){const i=new Map;return e.forEach(r=>{null!=r.textContent&&i.set(r.textContent,r)}),i}return null}changeUsageCount(e,i){const r=this.styleRef;if(r.has(e)){const s=r.get(e);return s.usage+=i,s.usage}return r.set(e,{usage:i,elements:[]}),i}getStyleElement(e,i){const r=this.styleNodesInDOM,s=r?.get(i);if(s?.parentNode===e)return r.delete(i),s.removeAttribute(aC),s;{const o=this.doc.createElement("style");return this.nonce&&o.setAttribute("nonce",this.nonce),o.textContent=i,this.platformIsServer&&o.setAttribute(aC,this.appId),e.appendChild(o),o}}addStyleToHost(e,i){const r=this.getStyleElement(e,i),s=this.styleRef,o=s.get(i)?.elements;o?o.push(r):s.set(i,{elements:[r],usage:1})}resetHostNodes(){const e=this.hostNodes;e.clear(),e.add(this.doc.head)}static{this.\u0275fac=function(i){return new(i||n)(Fi(ad),Fi(L1),Fi(oL,8),Fi(Iu))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();const lC={svg:"http://www.w3.org/2000/svg",xhtml:"http://www.w3.org/1999/xhtml",xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/",math:"http://www.w3.org/1998/MathML/"},hC=/%COMP%/g,Uq=new Ht("",{providedIn:"root",factory:()=>!0});function Iz(n,t){return t.map(e=>e.replace(hC,n))}let bz=(()=>{class n{constructor(e,i,r,s,o,a,l,h=null){this.eventManager=e,this.sharedStylesHost=i,this.appId=r,this.removeStylesOnCompDestroy=s,this.doc=o,this.platformId=a,this.ngZone=l,this.nonce=h,this.rendererByCompId=new Map,this.platformIsServer=uz(a),this.defaultRenderer=new cC(e,o,l,this.platformIsServer)}createRenderer(e,i){if(!e||!i)return this.defaultRenderer;this.platformIsServer&&i.encapsulation===Ia.ShadowDom&&(i={...i,encapsulation:Ia.Emulated});const r=this.getOrCreateRenderer(e,i);return r instanceof wz?r.applyToHost(e):r instanceof dC&&r.applyStyles(),r}getOrCreateRenderer(e,i){const r=this.rendererByCompId;let s=r.get(i.id);if(!s){const o=this.doc,a=this.ngZone,l=this.eventManager,h=this.sharedStylesHost,c=this.removeStylesOnCompDestroy,d=this.platformIsServer;switch(i.encapsulation){case Ia.Emulated:s=new wz(l,h,i,this.appId,c,o,a,d);break;case Ia.ShadowDom:return new Yq(l,h,e,i,o,a,this.nonce,d);default:s=new dC(l,h,i,c,o,a,d)}r.set(i.id,s)}return s}ngOnDestroy(){this.rendererByCompId.clear()}static{this.\u0275fac=function(i){return new(i||n)(Fi(vz),Fi(yz),Fi(L1),Fi(Uq),Fi(ad),Fi(Iu),Fi(zr),Fi(oL))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();class cC{constructor(t,e,i,r){this.eventManager=t,this.doc=e,this.ngZone=i,this.platformIsServer=r,this.data=Object.create(null),this.throwOnSyntheticProps=!0,this.destroyNode=null}destroy(){}createElement(t,e){return e?this.doc.createElementNS(lC[e]||e,t):this.doc.createElement(t)}createComment(t){return this.doc.createComment(t)}createText(t){return this.doc.createTextNode(t)}appendChild(t,e){(Mz(t)?t.content:t).appendChild(e)}insertBefore(t,e,i){t&&(Mz(t)?t.content:t).insertBefore(e,i)}removeChild(t,e){t&&t.removeChild(e)}selectRootElement(t,e){let i="string"==typeof t?this.doc.querySelector(t):t;if(!i)throw new F(-5104,!1);return e||(i.textContent=""),i}parentNode(t){return t.parentNode}nextSibling(t){return t.nextSibling}setAttribute(t,e,i,r){if(r){e=r+":"+e;const s=lC[r];s?t.setAttributeNS(s,e,i):t.setAttribute(e,i)}else t.setAttribute(e,i)}removeAttribute(t,e,i){if(i){const r=lC[i];r?t.removeAttributeNS(r,e):t.removeAttribute(`${i}:${e}`)}else t.removeAttribute(e)}addClass(t,e){t.classList.add(e)}removeClass(t,e){t.classList.remove(e)}setStyle(t,e,i,r){r&(Kh.DashCase|Kh.Important)?t.style.setProperty(e,i,r&Kh.Important?"important":""):t.style[e]=i}removeStyle(t,e,i){i&Kh.DashCase?t.style.removeProperty(e):t.style[e]=""}setProperty(t,e,i){null!=t&&(t[e]=i)}setValue(t,e){t.nodeValue=e}listen(t,e,i){if("string"==typeof t&&!(t=jw().getGlobalEventTarget(this.doc,t)))throw new Error(`Unsupported event target ${t} for event ${e}`);return this.eventManager.addEventListener(t,e,this.decoratePreventDefault(i))}decoratePreventDefault(t){return e=>{if("__ngUnwrap__"===e)return t;!1===(this.platformIsServer?this.ngZone.runGuarded(()=>t(e)):t(e))&&e.preventDefault()}}}function Mz(n){return"TEMPLATE"===n.tagName&&void 0!==n.content}class Yq extends cC{constructor(t,e,i,r,s,o,a,l){super(t,s,o,l),this.sharedStylesHost=e,this.hostEl=i,this.shadowRoot=i.attachShadow({mode:"open"}),this.sharedStylesHost.addHost(this.shadowRoot);const h=Iz(r.id,r.styles);for(const c of h){const d=document.createElement("style");a&&d.setAttribute("nonce",a),d.textContent=c,this.shadowRoot.appendChild(d)}}nodeOrShadowRoot(t){return t===this.hostEl?this.shadowRoot:t}appendChild(t,e){return super.appendChild(this.nodeOrShadowRoot(t),e)}insertBefore(t,e,i){return super.insertBefore(this.nodeOrShadowRoot(t),e,i)}removeChild(t,e){return super.removeChild(this.nodeOrShadowRoot(t),e)}parentNode(t){return this.nodeOrShadowRoot(super.parentNode(this.nodeOrShadowRoot(t)))}destroy(){this.sharedStylesHost.removeHost(this.shadowRoot)}}class dC extends cC{constructor(t,e,i,r,s,o,a,l){super(t,s,o,a),this.sharedStylesHost=e,this.removeStylesOnCompDestroy=r,this.styles=l?Iz(l,i.styles):i.styles}applyStyles(){this.sharedStylesHost.addStyles(this.styles)}destroy(){this.removeStylesOnCompDestroy&&this.sharedStylesHost.removeStyles(this.styles)}}class wz extends dC{constructor(t,e,i,r,s,o,a,l){const h=r+"-"+i.id;super(t,e,i,s,o,a,l,h),this.contentAttr=function jq(n){return"_ngcontent-%COMP%".replace(hC,n)}(h),this.hostAttr=function Vq(n){return"_nghost-%COMP%".replace(hC,n)}(h)}applyToHost(t){this.applyStyles(),this.setAttribute(t,this.hostAttr,"")}createElement(t,e){const i=super.createElement(t,e);return super.setAttribute(i,this.contentAttr,""),i}}let Qq=(()=>{class n extends mz{constructor(e){super(e)}supports(e){return!0}addEventListener(e,i,r){return e.addEventListener(i,r,!1),()=>this.removeEventListener(e,i,r)}removeEventListener(e,i,r){return e.removeEventListener(i,r)}static{this.\u0275fac=function(i){return new(i||n)(Fi(ad))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();const Cz=["alt","control","meta","shift"],Gq={"\b":"Backspace","\t":"Tab","\x7f":"Delete","\x1b":"Escape",Del:"Delete",Esc:"Escape",Left:"ArrowLeft",Right:"ArrowRight",Up:"ArrowUp",Down:"ArrowDown",Menu:"ContextMenu",Scroll:"ScrollLock",Win:"OS"},Xq={alt:n=>n.altKey,control:n=>n.ctrlKey,meta:n=>n.metaKey,shift:n=>n.shiftKey};let qq=(()=>{class n extends mz{constructor(e){super(e)}supports(e){return null!=n.parseEventName(e)}addEventListener(e,i,r){const s=n.parseEventName(i),o=n.eventCallback(s.fullKey,r,this.manager.getZone());return this.manager.getZone().runOutsideAngular(()=>jw().onAndCancel(e,s.domEventName,o))}static parseEventName(e){const i=e.toLowerCase().split("."),r=i.shift();if(0===i.length||"keydown"!==r&&"keyup"!==r)return null;const s=n._normalizeKey(i.pop());let o="",a=i.indexOf("code");if(a>-1&&(i.splice(a,1),o="code."),Cz.forEach(h=>{const c=i.indexOf(h);c>-1&&(i.splice(c,1),o+=h+".")}),o+=s,0!=i.length||0===s.length)return null;const l={};return l.domEventName=r,l.fullKey=o,l}static matchEventFullKeyCode(e,i){let r=Gq[e.key]||e.key,s="";return i.indexOf("code.")>-1&&(r=e.code,s="code."),!(null==r||!r)&&(r=r.toLowerCase()," "===r?r="space":"."===r&&(r="dot"),Cz.forEach(o=>{o!==r&&(0,Xq[o])(e)&&(s+=o+".")}),s+=r,s===i)}static eventCallback(e,i,r){return s=>{n.matchEventFullKeyCode(s,e)&&r.runGuarded(()=>i(s))}}static _normalizeKey(e){return"esc"===e?"escape":e}static{this.\u0275fac=function(i){return new(i||n)(Fi(ad))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();function Ez(n){return{appProviders:[...i$,...n?.providers??[]],platformProviders:e$}}const e$=[{provide:Iu,useValue:"browser"},{provide:sL,useValue:function Zq(){sC.makeCurrent()},multi:!0},{provide:ad,useFactory:function Kq(){return function Aj(n){A1=n}(document),document},deps:[]}],i$=[{provide:w1,useValue:"root"},{provide:eh,useFactory:function Jq(){return new eh},deps:[]},{provide:oC,useClass:Qq,multi:!0,deps:[ad,zr,Iu]},{provide:oC,useClass:qq,multi:!0,deps:[ad]},bz,yz,vz,{provide:sN,useExisting:bz},{provide:class cq{},useClass:Hq,deps:[]},[]];var o$=0,uC=!1;function M0(n,t){var e=t;return e.unshift(void 0),new(Function.prototype.bind.apply(n,e))}function Y(n,t){for(var e=t,i=n.replace(/\[/g,".").replace(/\]/g,"").split("."),r=0;r"u"}function wi(n){return n+"_"+o$++}function C0(n,t){return n===t||!(n===document||!n)&&C0(n.parentNode,t)}function Tg(n){try{throw new Error(n)}catch(t){throw new Error(t.message+"\n"+t.stack)}}function Re(n){var t=n+"";return t.match(/auto|cm|mm|in|px|pt|pc|%|em|ex|ch|rem|vw|vh|vmin|vmax/)?t:t+"px"}function ce(){return uC}var Ag,n,t,d$={latn:{_digits:"0123456789",_type:"numeric"}},Lz={decimal:".",group:",",percentSign:"%",plusSign:"+",minusSign:"-",infinity:"\u221e",nan:"NaN",exponential:"E"},Nz=[0,1,2,3,4,5,6,7,8,9],Rr=function(){function n(){}return n.getMainObject=function(t,e){return Y(ce()?e:"main."+e,t)},n.getNumberingSystem=function(t){return Y("supplemental.numberingSystems",t)||this.numberingSystems},n.reverseObject=function(t,e){for(var r={},s=0,o=e||Object.keys(t);s13&&(f+=1,o-=12),o-=1,a=f-4716;var y=u-24e5,S=10631/30,b=u-1948084,M=Math.floor(b/10631);b-=10631*M;var w=Math.floor((b-.1335)/S),C=30*M+w;b-=Math.floor(w*S+.1335);var D=Math.floor((b+28.5001)/29.5);13===D&&(D=12);for(var A=b-Math.floor(29.5001*D-29),x=0;xy);x++);var R=x+16260,L=Math.floor((R-1)/12),O=L+1,N=R-12*L,T=y-t[x-1]+1;return(T+"").length>2&&(T=A,N=D,O=C),{year:O,month:N,date:T}},n.toGregorian=function i(r,s,o){var g=Math.floor(o+t[12*(r-1)+1+(s-1)-16260-1]-1+24e5+.5),v=Math.floor((g-1867216.25)/36524.25),y=1524+(v=g+1+v-Math.floor(v/4)),S=Math.floor((y-122.1)/365.25),b=Math.floor(365.25*S),M=Math.floor((y-b)/30.6001),w=y-b-Math.floor(30.6001*M),C=M-(M>13.5?13:1),D=S-(C>2.5?4716:4715);return D<=0&&C--,new Date(D+"/"+C+"/"+w)};var ut,f$=/\/MMMMM|MMMM|MMM|a|LLLL|LLL|EEEEE|EEEE|E|K|cccc|ccc|WW|W|G+|z+/gi,Oz="stand-alone",g$=["sun","mon","tue","wed","thu","fri","sat"],kz={m:"getMinutes",h:"getHours",H:"getHours",s:"getSeconds",d:"getDate",f:"getMilliseconds"},Pz=function(){function n(){}return n.dateFormat=function(t,e,i){var r=this,s=ut.getDependables(i,t,e.calendar),o=Y("parserObject.numbers",s),a=s.dateObject,l={isIslamic:ut.islamicRegex.test(e.calendar)};ce()&&e.isServerRendered&&(e=ut.compareBlazorDateFormats(e,t));var h=e.format||ut.getResultantPattern(e.skeleton,s.dateObject,e.type,!1,ce()?t:"");if(l.dateSeperator=ce()?Y("dateSeperator",a):ut.getDateSeparator(s.dateObject),st(h))Tg("Format options or type given must be invalid");else{h=ut.ConvertDateToWeekFormat(h),ce()&&(h=h.replace(/tt/,"a")),l.pattern=h,l.numMapper=ce()?ze({},o):Rr.getNumberMapper(s.parserObject,Rr.getNumberingSystem(i));for(var d=0,u=h.match(f$)||[];d2?r+=e.month[""+u]:f=!0;break;case"E":case"c":r+=e.weekday[""+g$[t.getDay()]];break;case"H":case"h":case"m":case"s":case"d":case"f":if(f=!0,"d"===d)u=o.date;else if("f"===d){f=!1,g=!0;var y=(p=(p=t[""+kz[""+d]]().toString()).substring(0,c)).length;if(c!==y){if(c>3)continue;for(var S=0;S0?1:0],o=Math.abs(t);return s.replace(/HH?|mm/g,function(a){var l=a.length,h=-1!==a.indexOf("H");return i.checkTwodigitNumber(Math.floor(h?o/60:o%60),l)})},n}(),zz={ms:"minimumSignificantDigits",ls:"maximumSignificantDigits",mf:"minimumFractionDigits",lf:"maximumFractionDigits"},rp=["infinity","nan","group","decimal","exponential"],Rz=function(){function n(){}return n.numberFormatter=function(t,e,i){var l,r=this,s=ze({},e),o={},a={},h=ut.getDependables(i,t,"",!0),c=h.numericObject;a.numberMapper=ce()?ze({},c):Rr.getNumberMapper(h.parserObject,Rr.getNumberingSystem(i),!0),a.currencySymbol=ce()?Y("currencySymbol",c):ut.getCurrencySymbol(h.numericObject,s.currency||Og,e.altSymbol,e.ignoreCurrency),a.percentSymbol=ce()?Y("numberSymbols.percentSign",c):a.numberMapper.numberSymbols.percentSign,a.minusSymbol=ce()?Y("numberSymbols.minusSign",c):a.numberMapper.numberSymbols.minusSign;var d=a.numberMapper.numberSymbols;if(e.format&&!ut.formatRegex.test(e.format))o=ut.customFormat(e.format,a,h.numericObject),!st(s.useGrouping)&&s.useGrouping&&(s.useGrouping=o.pData.useGrouping);else{if(ze(s,ut.getProperNumericSkeleton(e.format||"N")),s.isCurrency="currency"===s.type,s.isPercent="percent"===s.type,ce()||(l=ut.getSymbolPattern(s.type,a.numberMapper.numberSystem,h.numericObject,s.isAccount)),s.groupOne=this.checkValueRange(s.maximumSignificantDigits,s.minimumSignificantDigits,!0),this.checkValueRange(s.maximumFractionDigits,s.minimumFractionDigits,!1,!0),st(s.fractionDigits)||(s.minimumFractionDigits=s.maximumFractionDigits=s.fractionDigits),st(s.useGrouping)&&(s.useGrouping=!0),s.isCurrency&&!ce()&&(l=l.replace(/\u00A4/g,ut.defaultCurrency)),ce())o.nData=ze({},{},Y(s.type+"nData",c)),o.pData=ze({},{},Y(s.type+"pData",c)),"currency"===s.type&&e.currency&&ut.replaceBlazorCurrency([o.pData,o.nData],a.currencySymbol,e.currency);else{var u=l.split(";");o.nData=ut.getFormatData(u[1]||"-"+u[0],!0,a.currencySymbol),o.pData=ut.getFormatData(u[0],!1,a.currencySymbol),s.useGrouping&&(s.groupSeparator=d[rp[2]],s.groupData=this.getGroupingDetails(u[0]))}if(st(s.minimumFractionDigits)&&(s.minimumFractionDigits=o.nData.minimumFraction),st(s.maximumFractionDigits)){var f=o.nData.maximumFraction;s.maximumFractionDigits=st(f)&&s.isPercent?0:f}var g=s.minimumFractionDigits,v=s.maximumFractionDigits;!st(g)&&!st(v)&&g>v&&(s.maximumFractionDigits=g)}return ze(o.nData,s),ze(o.pData,s),function(y){return isNaN(y)?d[rp[1]]:isFinite(y)?r.intNumberFormatter(y,o,a,e):d[rp[0]]}},n.getGroupingDetails=function(t){var e={},i=t.match(ut.negativeDataRegex);if(i&&i[4]){var r=i[4],s=r.lastIndexOf(",");if(-1!==s){var o=r.split(".")[0];e.primary=o.length-s-1;var a=r.lastIndexOf(",",s-1);-1!==a&&(e.secondary=s-1-a)}}return e},n.checkValueRange=function(t,e,i,r){var s=r?"f":"s",o=0,a=zz["l"+s],l=zz["m"+s];if(st(t)||(this.checkRange(t,a,r),o++),st(e)||(this.checkRange(e,l,r),o++),2===o){if(!(tr[1])&&Tg(e+"value must be within the range"+r[0]+"to"+r[1])},n.intNumberFormatter=function(t,e,i,r){var s;if(!st(e.nData.type)){t<0?(t*=-1,s=e.nData):s=0===t&&e.zeroData||e.pData;var o="";if(s.isPercent&&(t*=100),s.groupOne)o=this.processSignificantDigits(t,s.minimumSignificantDigits,s.maximumSignificantDigits);else if(o=this.processFraction(t,s.minimumFractionDigits,s.maximumFractionDigits,r),s.minimumIntegerDigits&&(o=this.processMinimumIntegers(o,s.minimumIntegerDigits)),i.isCustomFormat&&s.minimumFractionDigits=0&&"0"===l[parseInt(c.toString(),10)]&&c>=s.minimumFractionDigits;c--)l=l.slice(0,c);o=a[0]+"."+l}return"scientific"===s.type&&(o=(o=t.toExponential(s.maximumFractionDigits)).replace("e",i.numberMapper.numberSymbols[rp[4]])),o=o.replace(".",i.numberMapper.numberSymbols[rp[3]]),o="#,###,,;(#,###,,)"===s.format?this.customPivotFormat(parseInt(o,10)):o,s.useGrouping&&(o=this.groupNumbers(o,s.groupData.primary,s.groupSeparator||",",i.numberMapper.numberSymbols[rp[3]]||".",s.groupData.secondary)),o=Rr.convertValueParts(o,ut.latnParseRegex,i.numberMapper.mapper),"N/A"===s.nlead?s.nlead:"0"===o&&r&&"0"===r.format?o+s.nend:s.nlead+o+s.nend}},n.processSignificantDigits=function(t,e,i){var r=t+"";return r.lengthe;)c=l.slice(h-e,h)+(c.length?i+c:""),h-=e,o&&(e=s,o=!1);return a[0]=l.slice(0,h)+(c.length?i:"")+c,a.join(r)},n.processFraction=function(t,e,i,r){var s=(t+"").split(".")[1],o=s?s.length:0;if(e&&oi||0===i))return t.toFixed(i);var h=t+"";return"0"===h[0]&&r&&"###.00"===r.format&&(h=h.slice(1)),h},n.processMinimumIntegers=function(t,e){var i=t.split("."),r=i[0],s=r.length;if(s=5e5){var r=(t/=1e6).toString().split(".")[1];return r&&+r.substring(0,1)>=5?Math.ceil(t).toString():Math.floor(t).toString()}return""},n}(),Lg=(new RegExp("^([^0-9]*)(([0-9,]*[0-9]+)(.[0-9]+)?)([Ee][+-]?[0-9]+)?([^0-9]*)$"),function(){function n(t){this.ranArray=[],this.boundedEvents={},!m(t)&&(this.context=t)}return n.prototype.on=function(t,e,i,r){if(!m(e)){var s=i||this.context;if(this.notExist(t))return void(this.boundedEvents[""+t]=[{handler:e,context:s,id:r}]);m(r)?this.isHandlerPresent(this.boundedEvents[""+t],e)||this.boundedEvents[""+t].push({handler:e,context:s}):-1===this.ranArray.indexOf(r)&&(this.ranArray.push(r),this.boundedEvents[""+t].push({handler:e,context:s,id:r}))}},n.prototype.off=function(t,e,i){if(!this.notExist(t)){var r=Y(t,this.boundedEvents);if(e){for(var s=0;s1&&(_.fractionDigits=parseInt(P[2],10)),_}function f(T,P,_,B){var j=B?{}:{nlead:"",nend:""},Q=T.match(n.customRegex);if(Q){B||(j.nlead=g(Q[1],_),j.nend=g(Q[10],_),j.groupPattern=Q[4]);var oe=Q[7];if(oe&&P){var ue=oe.match(t);j.minimumFraction=m(ue)?0:ue.length,j.maximumFraction=oe.length-1}}return j}function g(T,P){return T?(T=T.replace(n.defaultCurrency,P),""===P?T.trim():T):""}function v(T,P,_,B){return B?"$":Y("currencies."+P+(_?"."+_:".symbol"),T)||Y("currencies."+P+".symbol-alt-narrow",T)||"$"}function S(T,P,_){var B={type:"decimal",minimumFractionDigits:0,maximumFractionDigits:0},j=T.match(n.customRegex);if(m(j)||""===j[5]&&"N/A"!==T)return B.type=void 0,B;B.nlead=j[1],B.nend=j[10];var Q=j[6],oe=!!Q.match(/ $/g),ue=-1!==Q.replace(/ $/g,"").indexOf(" ");B.useGrouping=-1!==Q.indexOf(",")||ue,Q=Q.replace(/,/g,"");var pe=j[7];if(-1!==Q.indexOf("0")&&(B.minimumIntegerDigits=Q.length-Q.indexOf("0")),m(pe)||(B.minimumFractionDigits=pe.lastIndexOf("0"),B.maximumFractionDigits=pe.lastIndexOf("#"),-1===B.minimumFractionDigits&&(B.minimumFractionDigits=0),(-1===B.maximumFractionDigits||B.maximumFractionDigitsQ.lastIndexOf("'"))){B[""+a[parseInt(j.toString(),10)]]=Q.substr(0,oe)+_+Q.substr(oe+1),B[""+a[""+P]]=!0,B.type=B.isCurrency?"currency":"percent";break}}return B}function C(T,P){if(-1!==T.indexOf(",")){var _=T.split(",");T=_[0]+Y("numberMapper.numberSymbols.group",P)+_[1].replace(".",Y("numberMapper.numberSymbols.decimal",P))}else T=T.replace(".",Y("numberMapper.numberSymbols.decimal",P));return T}function A(T,P,_){T+=".";for(var B=0;B0;Q-=3)T=","+_[Q-2]+_[Q-1]+_[parseInt(Q.toString(),10)]+T;return T=T.slice(1),P[1]?T+"."+P[1]:T}n.dateParseRegex=/([a-z])\1*|'([^']|'')+'|''|./gi,n.basicPatterns=["short","medium","long","full"],n.defaultObject={dates:{calendars:{gregorian:{months:{"stand-alone":{abbreviated:{1:"Jan",2:"Feb",3:"Mar",4:"Apr",5:"May",6:"Jun",7:"Jul",8:"Aug",9:"Sep",10:"Oct",11:"Nov",12:"Dec"},narrow:{1:"J",2:"F",3:"M",4:"A",5:"M",6:"J",7:"J",8:"A",9:"S",10:"O",11:"N",12:"D"},wide:{1:"January",2:"February",3:"March",4:"April",5:"May",6:"June",7:"July",8:"August",9:"September",10:"October",11:"November",12:"December"}}},days:{"stand-alone":{abbreviated:{sun:"Sun",mon:"Mon",tue:"Tue",wed:"Wed",thu:"Thu",fri:"Fri",sat:"Sat"},narrow:{sun:"S",mon:"M",tue:"T",wed:"W",thu:"T",fri:"F",sat:"S"},short:{sun:"Su",mon:"Mo",tue:"Tu",wed:"We",thu:"Th",fri:"Fr",sat:"Sa"},wide:{sun:"Sunday",mon:"Monday",tue:"Tuesday",wed:"Wednesday",thu:"Thursday",fri:"Friday",sat:"Saturday"}}},dayPeriods:{format:{wide:{am:"AM",pm:"PM"}}},eras:{eraNames:{0:"Before Christ","0-alt-variant":"Before Common Era",1:"Anno Domini","1-alt-variant":"Common Era"},eraAbbr:{0:"BC","0-alt-variant":"BCE",1:"AD","1-alt-variant":"CE"},eraNarrow:{0:"B","0-alt-variant":"BCE",1:"A","1-alt-variant":"CE"}},dateFormats:{full:"EEEE, MMMM d, y",long:"MMMM d, y",medium:"MMM d, y",short:"M/d/yy"},timeFormats:{full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},dateTimeFormats:{full:"{1} 'at' {0}",long:"{1} 'at' {0}",medium:"{1}, {0}",short:"{1}, {0}",availableFormats:{d:"d",E:"ccc",Ed:"d E",Ehm:"E h:mm a",EHm:"E HH:mm",Ehms:"E h:mm:ss a",EHms:"E HH:mm:ss",Gy:"y G",GyMMM:"MMM y G",GyMMMd:"MMM d, y G",GyMMMEd:"E, MMM d, y G",h:"h a",H:"HH",hm:"h:mm a",Hm:"HH:mm",hms:"h:mm:ss a",Hms:"HH:mm:ss",hmsv:"h:mm:ss a v",Hmsv:"HH:mm:ss v",hmv:"h:mm a v",Hmv:"HH:mm v",M:"L",Md:"M/d",MEd:"E, M/d",MMM:"LLL",MMMd:"MMM d",MMMEd:"E, MMM d",MMMMd:"MMMM d",ms:"mm:ss",y:"y",yM:"M/y",yMd:"M/d/y",yMEd:"E, M/d/y",yMMM:"MMM y",yMMMd:"MMM d, y",yMMMEd:"E, MMM d, y",yMMMM:"MMMM y"}}},islamic:{months:{"stand-alone":{abbreviated:{1:"Muh.",2:"Saf.",3:"Rab. I",4:"Rab. II",5:"Jum. I",6:"Jum. II",7:"Raj.",8:"Sha.",9:"Ram.",10:"Shaw.",11:"Dhu\u02bbl-Q.",12:"Dhu\u02bbl-H."},narrow:{1:"1",2:"2",3:"3",4:"4",5:"5",6:"6",7:"7",8:"8",9:"9",10:"10",11:"11",12:"12"},wide:{1:"Muharram",2:"Safar",3:"Rabi\u02bb I",4:"Rabi\u02bb II",5:"Jumada I",6:"Jumada II",7:"Rajab",8:"Sha\u02bbban",9:"Ramadan",10:"Shawwal",11:"Dhu\u02bbl-Qi\u02bbdah",12:"Dhu\u02bbl-Hijjah"}}},days:{"stand-alone":{abbreviated:{sun:"Sun",mon:"Mon",tue:"Tue",wed:"Wed",thu:"Thu",fri:"Fri",sat:"Sat"},narrow:{sun:"S",mon:"M",tue:"T",wed:"W",thu:"T",fri:"F",sat:"S"},short:{sun:"Su",mon:"Mo",tue:"Tu",wed:"We",thu:"Th",fri:"Fr",sat:"Sa"},wide:{sun:"Sunday",mon:"Monday",tue:"Tuesday",wed:"Wednesday",thu:"Thursday",fri:"Friday",sat:"Saturday"}}},dayPeriods:{format:{wide:{am:"AM",pm:"PM"}}},eras:{eraNames:{0:"AH"},eraAbbr:{0:"AH"},eraNarrow:{0:"AH"}},dateFormats:{full:"EEEE, MMMM d, y G",long:"MMMM d, y G",medium:"MMM d, y G",short:"M/d/y GGGGG"},timeFormats:{full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},dateTimeFormats:{full:"{1} 'at' {0}",long:"{1} 'at' {0}",medium:"{1}, {0}",short:"{1}, {0}",availableFormats:{d:"d",E:"ccc",Ed:"d E",Ehm:"E h:mm a",EHm:"E HH:mm",Ehms:"E h:mm:ss a",EHms:"E HH:mm:ss",Gy:"y G",GyMMM:"MMM y G",GyMMMd:"MMM d, y G",GyMMMEd:"E, MMM d, y G",h:"h a",H:"HH",hm:"h:mm a",Hm:"HH:mm",hms:"h:mm:ss a",Hms:"HH:mm:ss",M:"L",Md:"M/d",MEd:"E, M/d",MMM:"LLL",MMMd:"MMM d",MMMEd:"E, MMM d",MMMMd:"MMMM d",ms:"mm:ss",y:"y G",yyyy:"y G",yyyyM:"M/y GGGGG",yyyyMd:"M/d/y GGGGG",yyyyMEd:"E, M/d/y GGGGG",yyyyMMM:"MMM y G",yyyyMMMd:"MMM d, y G",yyyyMMMEd:"E, MMM d, y G",yyyyMMMM:"MMMM y G",yyyyQQQ:"QQQ y G",yyyyQQQQ:"QQQQ y G"}}}},timeZoneNames:{hourFormat:"+HH:mm;-HH:mm",gmtFormat:"GMT{0}",gmtZeroFormat:"GMT"}},numbers:{currencies:{USD:{displayName:"US Dollar",symbol:"$","symbol-alt-narrow":"$"},EUR:{displayName:"Euro",symbol:"\u20ac","symbol-alt-narrow":"\u20ac"},GBP:{displayName:"British Pound","symbol-alt-narrow":"\xa3"}},defaultNumberingSystem:"latn",minimumGroupingDigits:"1","symbols-numberSystem-latn":{decimal:".",group:",",list:";",percentSign:"%",plusSign:"+",minusSign:"-",exponential:"E",superscriptingExponent:"\xd7",perMille:"\u2030",infinity:"\u221e",nan:"NaN",timeSeparator:":"},"decimalFormats-numberSystem-latn":{standard:"#,##0.###"},"percentFormats-numberSystem-latn":{standard:"#,##0%"},"currencyFormats-numberSystem-latn":{standard:"\xa4#,##0.00",accounting:"\xa4#,##0.00;(\xa4#,##0.00)"},"scientificFormats-numberSystem-latn":{standard:"#E0"}}},n.blazorDefaultObject={numbers:{mapper:{0:"0",1:"1",2:"2",3:"3",4:"4",5:"5",6:"6",7:"7",8:"8",9:"9"},mapperDigits:"0123456789",numberSymbols:{decimal:".",group:",",plusSign:"+",minusSign:"-",percentSign:"%",nan:"NaN",timeSeparator:":",infinity:"\u221e"},timeSeparator:":",currencySymbol:"$",currencypData:{nlead:"$",nend:"",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},percentpData:{nlead:"",nend:"%",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},percentnData:{nlead:"-",nend:"%",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},currencynData:{nlead:"($",nend:")",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},decimalnData:{nlead:"-",nend:"",groupData:{primary:3},maximumFraction:2,minimumFraction:2},decimalpData:{nlead:"",nend:"",groupData:{primary:3},maximumFraction:2,minimumFraction:2}},dates:{dayPeriods:{am:"AM",pm:"PM"},dateSeperator:"/",days:{abbreviated:{sun:"Sun",mon:"Mon",tue:"Tue",wed:"Wed",thu:"Thu",fri:"Fri",sat:"Sat"},short:{sun:"Su",mon:"Mo",tue:"Tu",wed:"We",thu:"Th",fri:"Fr",sat:"Sa"},wide:{sun:"Sunday",mon:"Monday",tue:"Tuesday",wed:"Wednesday",thu:"Thursday",fri:"Friday",sat:"Saturday"}},months:{abbreviated:{1:"Jan",2:"Feb",3:"Mar",4:"Apr",5:"May",6:"Jun",7:"Jul",8:"Aug",9:"Sep",10:"Oct",11:"Nov",12:"Dec"},wide:{1:"January",2:"February",3:"March",4:"April",5:"May",6:"June",7:"July",8:"August",9:"September",10:"October",11:"November",12:"December"}},eras:{1:"AD"}}},n.monthIndex={3:"abbreviated",4:"wide",5:"narrow",1:"abbreviated"},n.month="months",n.days="days",n.patternMatcher={C:"currency",P:"percent",N:"decimal",A:"currency",E:"scientific"},n.getResultantPattern=l,n.getDependables=h,n.getSymbolPattern=c,n.ConvertDateToWeekFormat=d,n.compareBlazorDateFormats=u,n.getProperNumericSkeleton=p,n.getFormatData=f,n.changeCurrencySymbol=g,n.getCurrencySymbol=v,n.customFormat=function y(T,P,_){for(var B={},j=T.split(";"),Q=["pData","nData","zeroData"],oe=0;oe1,pe.nData=ce()?Y(De.type+"nData",oe):f(ot[1]||"-"+ot[0],!0,Ie),pe.pData=ce()?Y(De.type+"pData",oe):f(ot[0],!1,Ie),!Me[2]&&!P.minimumFractionDigits&&!P.maximumFractionDigits&&(ue=f(Ve.split(";")[0],!0,"",!0).minimumFraction)}if(n.formatRegex.test(P.format)||!P.format){if(ze(Q,p(P.format||"N")),Q.custom=!1,$e="###0",(Q.fractionDigits||P.minimumFractionDigits||P.maximumFractionDigits||ue)&&(Q.fractionDigits&&(P.minimumFractionDigits=P.maximumFractionDigits=Q.fractionDigits),$e=A($e,ue||Q.fractionDigits||P.minimumFractionDigits||0,P.maximumFractionDigits||0)),P.minimumIntegerDigits&&($e=x($e,P.minimumIntegerDigits)),P.useGrouping&&($e=R($e)),"currency"===Q.type||Q.type&&ce()){ce()&&"currency"!==Q.type&&(pe.pData=Y(Q.type+"pData",oe),pe.nData=Y(Q.type+"nData",oe));var hr=$e;$e=pe.pData.nlead+hr+pe.pData.nend,(pe.hasNegativePattern||ce())&&($e+=";"+pe.nData.nlead+hr+pe.nData.nend)}"percent"===Q.type&&!ce()&&($e+=" %")}else $e=P.format.replace(/'/g,'"');return Object.keys(xe).length>0&&($e=B?$e:C($e,xe)),$e},n.fractionDigitsPattern=A,n.minimumIntegerPattern=x,n.groupingPattern=R,n.getWeekData=function L(T,P){var _="sun",B=Y("supplemental.weekData.firstDay",P),j=T;return/en-/.test(j)&&(j=j.slice(3)),j=j.slice(0,2).toUpperCase()+j.substr(2),B&&(_=B[""+j]||B[j.slice(0,2)]||"sun"),o[""+_]},n.replaceBlazorCurrency=function O(T,P,_){var B=function p$(n){return Y(n||"",u$)}(_);if(P!==B)for(var j=0,Q=T;j=0?_:_+7;var j=Math.floor((T.getTime()-P.getTime()-6e4*(T.getTimezoneOffset()-P.getTimezoneOffset()))/864e5)+1;if(_<4){if((B=Math.floor((j+_-1)/7)+1)>52){var oe=new Date(T.getFullYear()+1,0,1).getDay();B=(oe=oe>=0?oe:oe+7)<4?1:53}}else B=Math.floor((j+_-1)/7);return B}}(ut||(ut={}));var np=function(){function n(t,e,i){this.type="GET",this.emitError=!0,"string"==typeof t?(this.url=t,this.type=m(e)?this.type:e.toUpperCase(),this.contentType=i):Aa(t)&&Object.keys(t).length>0&&Nn(this,t),this.contentType=m(this.contentType)?"application/json; charset=utf-8":this.contentType}return n.prototype.send=function(t){var e=this,i={"application/json":"json","multipart/form-data":"formData","application/octet-stream":"blob","application/x-www-form-urlencoded":"formData"};try{m(this.fetchRequest)&&"GET"===this.type?this.fetchRequest=new Request(this.url,{method:this.type}):m(this.fetchRequest)&&(this.data=m(t)?this.data:t,this.fetchRequest=new Request(this.url,{method:this.type,headers:{"Content-Type":this.contentType},body:this.data}));var r={cancel:!1,fetchRequest:this.fetchRequest};return this.triggerEvent(this.beforeSend,r),r.cancel?null:(this.fetchResponse=fetch(this.fetchRequest),this.fetchResponse.then(function(s){if(e.triggerEvent(e.onLoad,s),!s.ok)throw s;for(var o="text",a=0,l=Object.keys(i);a-1},n.getValue=function(t,e){var i=typeof window<"u"?window.browserDetails:{};return typeof navigator<"u"&&"MacIntel"===navigator.platform&&navigator.maxTouchPoints>1&&!0===n.isTouch&&!gC.CHROME.test(navigator.userAgent)&&(i.isIos=!0,i.isDevice=!0,i.isTouch=!0,i.isPointer=!0),typeof window<"u"&&window.Capacitor&&"ios"===window.Capacitor.getPlatform()&&(i.isPointer=!1),typeof i[""+t]>"u"?i[""+t]=e.test(n.userAgent):i[""+t]},Object.defineProperty(n,"userAgent",{get:function(){return n.uA},set:function(t){n.uA=t,window.browserDetails={}},enumerable:!0,configurable:!0}),Object.defineProperty(n,"info",{get:function(){return st(window.browserDetails.info)?window.browserDetails.info=n.extractBrowserDetail():window.browserDetails.info},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isIE",{get:function(){return n.getValue("isIE",A$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isTouch",{get:function(){return st(window.browserDetails.isTouch)?window.browserDetails.isTouch="ontouchstart"in window.navigator||window&&window.navigator&&window.navigator.maxTouchPoints>0||"ontouchstart"in window:window.browserDetails.isTouch},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isPointer",{get:function(){return st(window.browserDetails.isPointer)?window.browserDetails.isPointer="pointerEnabled"in window.navigator:window.browserDetails.isPointer},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isMSPointer",{get:function(){return st(window.browserDetails.isMSPointer)?window.browserDetails.isMSPointer="msPointerEnabled"in window.navigator:window.browserDetails.isMSPointer},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isDevice",{get:function(){return n.getValue("isDevice",T$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isIos",{get:function(){return n.getValue("isIos",N$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isIos7",{get:function(){return n.getValue("isIos7",O$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isAndroid",{get:function(){return n.getValue("isAndroid",k$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isWebView",{get:function(){return st(window.browserDetails.isWebView)&&(window.browserDetails.isWebView=!(st(window.cordova)&&st(window.PhoneGap)&&st(window.phonegap)&&"object"!==window.forge)),window.browserDetails.isWebView},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isWindows",{get:function(){return n.getValue("isWindows",P$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"touchStartEvent",{get:function(){return st(window.browserDetails.touchStartEvent)?window.browserDetails.touchStartEvent=n.getTouchStartEvent():window.browserDetails.touchStartEvent},enumerable:!0,configurable:!0}),Object.defineProperty(n,"touchMoveEvent",{get:function(){return st(window.browserDetails.touchMoveEvent)?window.browserDetails.touchMoveEvent=n.getTouchMoveEvent():window.browserDetails.touchMoveEvent},enumerable:!0,configurable:!0}),Object.defineProperty(n,"touchEndEvent",{get:function(){return st(window.browserDetails.touchEndEvent)?window.browserDetails.touchEndEvent=n.getTouchEndEvent():window.browserDetails.touchEndEvent},enumerable:!0,configurable:!0}),Object.defineProperty(n,"touchCancelEvent",{get:function(){return st(window.browserDetails.touchCancelEvent)?window.browserDetails.touchCancelEvent=n.getTouchCancelEvent():window.browserDetails.touchCancelEvent},enumerable:!0,configurable:!0}),n.uA=typeof navigator<"u"?navigator.userAgent:"",n}(),E=function(){function n(){}return n.addOrGetEventData=function(t){return"__eventList"in t?t.__eventList.events:(t.__eventList={},t.__eventList.events=[])},n.add=function(t,e,i,r,s){var a,o=n.addOrGetEventData(t);a=s?function l$(n,t){var e;return function(){for(var i=this,r=[],s=0;s"u"||(e.innerHTML=t.innerHTML?t.innerHTML:"",void 0!==t.className&&(e.className=t.className),void 0!==t.id&&(e.id=t.id),void 0!==t.styles&&e.setAttribute("style",t.styles),void 0!==t.attrs&&Fe(e,t.attrs)),e}function V(n,t){for(var e=Vz(t),i=RegExp,r=0,s=n;r0}function pl(n,t,e){for(var i=document.createDocumentFragment(),r=0,s=n;r0;)i.appendChild(n[0]);else for(var r=0,s=n;r-1&&!r[parseInt(s.toString(),10)].match(/\[.*\]/)){var o=r[parseInt(s.toString(),10)].split("#");if(o[1].match(/^\d/)||o[1].match(t)){var a=r[parseInt(s.toString(),10)].split(".");a[0]=a[0].replace(/#/,"[id='")+"']",r[parseInt(s.toString(),10)]=a.join(".")}}e[parseInt(i.toString(),10)]=r.join(" ")}return e.join(",")}return n}function J(n,t){var e=n;if("function"==typeof e.closest)return e.closest(t);for(;e&&1===e.nodeType;){if(vC(e,t))return e;e=e.parentNode}return null}function je(n,t){void 0!==t&&Object.keys(t).forEach(function(e){n.style[""+e]=t[""+e]})}function vC(n,t){var e=n.matches||n.msMatchesSelector||n.webkitMatchesSelector;return e?e.call(n,t):-1!==[].indexOf.call(document.querySelectorAll(t),n)}var H$=new RegExp("]"),ah=function(){function n(t,e){this.isRendered=!1,this.isComplexArraySetter=!1,this.isServerRendered=!1,this.allowServerDataBinding=!0,this.isProtectedOnChange=!0,this.properties={},this.changedProperties={},this.oldProperties={},this.bulkChanges={},this.refreshing=!1,this.ignoreCollectionWatch=!1,this.finalUpdate=function(){},this.childChangedProperties={},this.modelObserver=new Lg(this),st(e)||(this.element="string"==typeof e?document.querySelector(e):e,m(this.element)||(this.isProtectedOnChange=!1,this.addInstance())),st(t)||this.setProperties(t,!0),this.isDestroyed=!1}return n.prototype.setProperties=function(t,e){var i=this.isProtectedOnChange;this.isProtectedOnChange=!!e,Nn(this,t),!0!==e?(Nn(this.changedProperties,t),this.dataBind()):ce()&&this.isRendered&&this.serverDataBind(t),this.finalUpdate(),this.changedProperties={},this.oldProperties={},this.isProtectedOnChange=i},n.callChildDataBind=function(t,e){for(var r=0,s=Object.keys(t);r=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Hs=function(n){function t(i){var r=n.call(this,i,void 0)||this;return r.easing={ease:"cubic-bezier(0.250, 0.100, 0.250, 1.000)",linear:"cubic-bezier(0.250, 0.250, 0.750, 0.750)",easeIn:"cubic-bezier(0.420, 0.000, 1.000, 1.000)",easeOut:"cubic-bezier(0.000, 0.000, 0.580, 1.000)",easeInOut:"cubic-bezier(0.420, 0.000, 0.580, 1.000)",elasticInOut:"cubic-bezier(0.5,-0.58,0.38,1.81)",elasticIn:"cubic-bezier(0.17,0.67,0.59,1.81)",elasticOut:"cubic-bezier(0.7,-0.75,0.99,1.01)"},r}var e;return X$(t,n),e=t,t.prototype.animate=function(i,r){var s=this.getModel(r=r||{});if("string"==typeof i)for(var a=0,l=Array.prototype.slice.call(we(i,document));a0?r-1:0,i+=e=-1!==e?"-"+e:"-"+r}return this.controlParent!==this.parentObj&&(i=this.parentObj.getParentKey()+"."+this.propName+e),i},n}(),J$=["grid","pivotview","treegrid","spreadsheet","rangeNavigator","DocumentEditor","listbox","inplaceeditor","PdfViewer","richtexteditor","DashboardLayout","chart","stockChart","circulargauge","diagram","heatmap","lineargauge","maps","slider","smithchart","barcode","sparkline","treemap","bulletChart","kanban","daterangepicker","schedule","gantt","signature","query-builder","drop-down-tree","carousel","filemanager","uploader","accordion","tab","treeview"],tR=[115,121,110,99,102,117,115,105,111,110,46,105,115,76,105,99,86,97,108,105,100,97,116,101,100],iR=function(){function n(t){this.isValidated=!1,this.isLicensed=!0,this.version="27",this.platform=/JavaScript|ASPNET|ASPNETCORE|ASPNETMVC|FileFormats|essentialstudio/i,this.errors={noLicense:"This application was built using a trial version of Syncfusion Essential Studio. To remove the license validation message permanently, a valid license key must be included.",trailExpired:"This application was built using a trial version of Syncfusion Essential Studio. To remove the license validation message permanently, a valid license key must be included.",versionMismatched:"The included Syncfusion license key is invalid.",platformMismatched:"The included Syncfusion license key is invalid.",invalidKey:"The included Syncfusion license key is invalid."},this.manager=function(){var e=null;return{setKey:function i(s){e=s},getKey:function r(){return e}}}(),this.npxManager=function(){return{getKey:function i(){return"npxKeyReplace"}}}(),this.manager.setKey(t)}return n.prototype.validate=function(){if(!this.isValidated&&ip&&!Y(T0(tR),ip)&&!Y("Blazor",ip)){var i=void 0,r=void 0;if(this.manager&&this.manager.getKey()||this.npxManager&&"npxKeyReplace"!==this.npxManager.getKey()){var s=this.getInfoFromKey();if(s&&s.length)for(var o=0,a=s;o"+i+' Claim your FREE account\n
have a Syncfusion account? Sign In
\n
\n ';if(typeof document<"u"&&!m(document)){var t=mi("div",{innerHTML:n});document.body.appendChild(t)}}(),oR=!0),this.render(),this.mount?this.accessMount():this.trigger("created")}},t.prototype.renderComplete=function(e){ce()&&window.sfBlazor.renderComplete(this.element,e),this.isRendered=!0},t.prototype.dataBind=function(){this.injectModules(),n.prototype.dataBind.call(this)},t.prototype.on=function(e,i,r){if("string"==typeof e)this.localObserver.on(e,i,r);else for(var s=0,o=e;s=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},rZ={left:0,top:0,bottom:0,right:0},bC={isDragged:!1},nZ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return aR(t,n),gr([I(0)],t.prototype,"left",void 0),gr([I(0)],t.prototype,"top",void 0),t}(Ee),ap=function(n){function t(i,r){var s=n.call(this,r,i)||this;return s.dragLimit=e.getDefaultPosition(),s.borderWidth=e.getDefaultPosition(),s.padding=e.getDefaultPosition(),s.diffX=0,s.prevLeft=0,s.prevTop=0,s.dragProcessStarted=!1,s.eleTop=0,s.tapHoldTimer=0,s.externalInitialize=!1,s.diffY=0,s.parentScrollX=0,s.parentScrollY=0,s.droppables={},s.bind(),s}var e;return aR(t,n),e=t,t.prototype.bind=function(){this.toggleEvents(),X.isIE&&V([this.element],"e-block-touch"),this.droppables[this.scope]={}},t.getDefaultPosition=function(){return ze({},rZ)},t.prototype.toggleEvents=function(i){var r;st(this.handle)||(r=U(this.handle,this.element));var s=this.enableTapHold&&X.isDevice&&X.isTouch?this.mobileInitialize:this.initialize;i?E.remove(r||this.element,X.isSafari()?"touchstart":X.touchStartEvent,s):E.add(r||this.element,X.isSafari()?"touchstart":X.touchStartEvent,s,this)},t.prototype.mobileInitialize=function(i){var r=this,s=i.currentTarget;this.tapHoldTimer=setTimeout(function(){r.externalInitialize=!0,r.removeTapholdTimer(),r.initialize(i,s)},this.tapHoldThreshold),E.add(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.removeTapholdTimer,this),E.add(document,X.isSafari()?"touchend":X.touchEndEvent,this.removeTapholdTimer,this)},t.prototype.removeTapholdTimer=function(){clearTimeout(this.tapHoldTimer),E.remove(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.removeTapholdTimer),E.remove(document,X.isSafari()?"touchend":X.touchEndEvent,this.removeTapholdTimer)},t.prototype.getScrollableParent=function(i,r){return m(i)?null:i[{vertical:"scrollHeight",horizontal:"scrollWidth"}[""+r]]>i[{vertical:"clientHeight",horizontal:"clientWidth"}[""+r]]&&("vertical"===r?i.scrollTop>0:i.scrollLeft>0)?("vertical"===r?(this.parentScrollY=this.parentScrollY+(0===this.parentScrollY?i.scrollTop:i.scrollTop-this.parentScrollY),this.tempScrollHeight=i.scrollHeight):(this.parentScrollX=this.parentScrollX+(0===this.parentScrollX?i.scrollLeft:i.scrollLeft-this.parentScrollX),this.tempScrollWidth=i.scrollWidth),m(i)?i:this.getScrollableParent(i.parentNode,r)):this.getScrollableParent(i.parentNode,r)},t.prototype.getScrollableValues=function(){this.parentScrollX=0,this.parentScrollY=0,this.element.classList.contains("e-dialog")&&this.element.classList.contains("e-dlg-modal"),this.getScrollableParent(this.element.parentNode,"vertical"),this.getScrollableParent(this.element.parentNode,"horizontal")},t.prototype.initialize=function(i,r){if(this.currentStateTarget=i.target,!this.isDragStarted()){if(this.isDragStarted(!0),this.externalInitialize=!1,this.target=i.currentTarget||r,this.dragProcessStarted=!1,this.abort){var s=this.abort;"string"==typeof s&&(s=[s]);for(var o=0;o=this.distance||this.externalInitialize){var p=this.getHelperElement(i);if(!p||m(p))return;r&&i.preventDefault();var f=this.helperElement=p;if(this.parentClientRect=this.calculateParentPosition(f.offsetParent),this.dragStart){var v={event:i,element:l,target:this.getProperTargetElement(i),bindEvents:ce()?this.bindDragEvents.bind(this):null,dragElement:f};this.trigger("dragStart",v)}this.dragArea?this.setDragArea():(this.dragLimit={left:0,right:0,bottom:0,top:0},this.borderWidth={top:0,left:0}),o={left:this.position.left-this.parentClientRect.left,top:this.position.top-this.parentClientRect.top},this.clone&&!this.enableTailMode&&(this.diffX=this.position.left-this.offset.left,this.diffY=this.position.top-this.offset.top),this.getScrollableValues();var y=getComputedStyle(l),S=parseFloat(y.marginTop);this.clone&&0!==S&&(o.top+=S),this.eleTop=isNaN(parseFloat(y.top))?0:parseFloat(y.top)-this.offset.top,this.enableScrollHandler&&!this.clone&&(o.top-=this.parentScrollY,o.left-=this.parentScrollX);var b=this.getProcessedPositionValue({top:o.top-this.diffY+"px",left:o.left-this.diffX+"px"});this.dragArea&&"string"!=typeof this.dragArea&&this.dragArea.classList.contains("e-kanban-content")&&"relative"===this.dragArea.style.position&&(o.top+=this.dragArea.scrollTop),this.dragElePosition={top:o.top,left:o.left},je(f,this.getDragPosition({position:"absolute",left:b.left,top:b.top})),E.remove(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.intDragStart),E.remove(document,X.isSafari()?"touchend":X.touchEndEvent,this.intDestroy),ce()||this.bindDragEvents(f)}}},t.prototype.bindDragEvents=function(i){Tr(i)?(E.add(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.intDrag,this),E.add(document,X.isSafari()?"touchend":X.touchEndEvent,this.intDragStop,this),this.setGlobalDroppables(!1,this.element,i)):(this.toggleEvents(),document.body.classList.remove("e-prevent-select"))},t.prototype.elementInViewport=function(i){for(this.top=i.offsetTop,this.left=i.offsetLeft,this.width=i.offsetWidth,this.height=i.offsetHeight;i.offsetParent;)this.top+=(i=i.offsetParent).offsetTop,this.left+=i.offsetLeft;return this.top>=window.pageYOffset&&this.left>=window.pageXOffset&&this.top+this.height<=window.pageYOffset+window.innerHeight&&this.left+this.width<=window.pageXOffset+window.innerWidth},t.prototype.getProcessedPositionValue=function(i){return this.queryPositionInfo?this.queryPositionInfo(i):i},t.prototype.calculateParentPosition=function(i){if(m(i))return{left:0,top:0};var r=i.getBoundingClientRect(),s=getComputedStyle(i);return{left:r.left+window.pageXOffset-parseInt(s.marginLeft,10),top:r.top+window.pageYOffset-parseInt(s.marginTop,10)}},t.prototype.intDrag=function(i){if(st(i.changedTouches)||1===i.changedTouches.length){var r,s;this.clone&&i.changedTouches&&X.isDevice&&X.isTouch&&i.preventDefault(),this.position=this.getMousePosition(i,this.isDragScroll);var o=this.getDocumentWidthHeight("Height");oy&&y>0?this.dragLimit.left:this.dragLimit.right+window.pageXOffset0?y-(y-this.dragLimit.right)+window.pageXOffset-M:y<0?this.dragLimit.left:y}if(this.pageY!==v||this.skipDistanceCheck){var w=d.offsetHeight+(parseFloat(b.marginTop)+parseFloat(b.marginBottom));s=this.dragLimit.top>S&&S>0?this.dragLimit.top:this.dragLimit.bottom+window.pageYOffset0?S-(S-this.dragLimit.bottom)+window.pageYOffset-w:S<0?this.dragLimit.top:S}}else r=y,s=S;var A,x,C=p+this.borderWidth.top,D=u+this.borderWidth.left;if(this.dragProcessStarted&&(m(s)&&(s=this.prevTop),m(r)&&(r=this.prevLeft)),this.helperElement.classList.contains("e-treeview"))this.dragArea?(this.dragLimit.top=this.clone?this.dragLimit.top:0,A=s-C<0?this.dragLimit.top:s-this.borderWidth.top,x=r-D<0?this.dragLimit.left:r-this.borderWidth.left):(A=s-this.borderWidth.top,x=r-this.borderWidth.left);else if(this.dragArea){var R=this.helperElement.classList.contains("e-dialog");this.dragLimit.top=this.clone?this.dragLimit.top:0,A=s-C<0?this.dragLimit.top:s-C,x=r-D<0?R?r-(D-this.borderWidth.left):this.dragElePosition.left:r-D}else A=s-C,x=r-D;var L=parseFloat(getComputedStyle(this.element).marginTop);if(L>0&&(this.clone&&(A+=L,S<0&&(L+S>=0?A=L+S:A-=L),this.dragArea&&(A=this.dragLimit.bottom=0){var O=this.dragLimit.top+S-C;O+L+C<0?A-=L+C:A=O}else A-=L+C;this.dragArea&&this.helperElement.classList.contains("e-treeview")&&(A=A+(w=d.offsetHeight+(parseFloat(b.marginTop)+parseFloat(b.marginBottom)))>this.dragLimit.bottom?this.dragLimit.bottom-w:A),this.enableScrollHandler&&!this.clone&&(A-=this.parentScrollY,x-=this.parentScrollX),this.dragArea&&"string"!=typeof this.dragArea&&this.dragArea.classList.contains("e-kanban-content")&&"relative"===this.dragArea.style.position&&(A+=this.dragArea.scrollTop);var N=this.getProcessedPositionValue({top:A+"px",left:x+"px"});this.isPreventScroll&&(N=this.getProcessedPositionValue({top:this.position.top-this.parentClientRect.top-2+"px",left:this.position.left-this.parentClientRect.left-2+"px"})),je(d,this.getDragPosition(N)),!this.elementInViewport(d)&&this.enableAutoScroll&&!this.helperElement.classList.contains("e-treeview")&&this.helperElement.scrollIntoView();var T=document.querySelectorAll(":hover");if(this.enableAutoScroll&&this.helperElement.classList.contains("e-treeview")){0===T.length&&(T=this.getPathElements(i));var P=this.getScrollParent(T,!1);this.elementInViewport(this.helperElement)?this.getScrollPosition(P,A):this.elementInViewport(this.helperElement)||(0===(T=[].slice.call(document.querySelectorAll(":hover"))).length&&(T=this.getPathElements(i)),P=this.getScrollParent(T,!0),this.getScrollPosition(P,A))}this.dragProcessStarted=!0,this.prevLeft=r,this.prevTop=s,this.position.left=r,this.position.top=s,this.pageX=g,this.pageY=v}},t.prototype.getScrollParent=function(i,r){for(var o,s=r?i.reverse():i,a=s.length-1;a>=0;a--)if(("auto"===(o=window.getComputedStyle(s[parseInt(a.toString(),10)])["overflow-y"])||"scroll"===o)&&s[parseInt(a.toString(),10)].scrollHeight>s[parseInt(a.toString(),10)].clientHeight)return s[parseInt(a.toString(),10)];if("visible"===(o=window.getComputedStyle(document.scrollingElement)["overflow-y"]))return document.scrollingElement.style.overflow="auto",document.scrollingElement},t.prototype.getScrollPosition=function(i,r){if(i&&i===document.scrollingElement)i.clientHeight+document.scrollingElement.scrollTop-this.helperElement.clientHeightr?i.scrollTop+=this.helperElement.clientHeight:i.scrollTop>r-this.helperElement.clientHeight&&(i.scrollTop-=this.helperElement.clientHeight);else if(i&&i!==document.scrollingElement){var s=document.scrollingElement.scrollTop,o=this.helperElement.clientHeight;i.clientHeight+i.getBoundingClientRect().top-o+sr-o-s&&(i.scrollTop-=this.helperElement.clientHeight)}},t.prototype.getPathElements=function(i){return document.elementsFromPoint(i.clientX>0?i.clientX:0,i.clientY>0?i.clientY:0)},t.prototype.triggerOutFunction=function(i,r){this.hoverObject.instance.intOut(i,r.target),this.hoverObject.instance.dragData[this.scope]=null,this.hoverObject=null},t.prototype.getDragPosition=function(i){var r=ze({},i);return this.axis&&("x"===this.axis?delete r.top:"y"===this.axis&&delete r.left),r},t.prototype.getDocumentWidthHeight=function(i){var r=document.body,s=document.documentElement;return Math.max(r["scroll"+i],s["scroll"+i],r["offset"+i],s["offset"+i],s["client"+i])},t.prototype.intDragStop=function(i){if(this.dragProcessStarted=!1,st(i.changedTouches)||1===i.changedTouches.length){if(-1!==["touchend","pointerup","mouseup"].indexOf(i.type)){if(this.dragStop){var s=this.getProperTargetElement(i);this.trigger("dragStop",{event:i,element:this.element,target:s,helper:this.helperElement})}this.intDestroy(i)}else this.element.setAttribute("aria-grabbed","false");var o=this.checkTargetElement(i);o.target&&o.instance&&(o.instance.dragStopCalled=!0,o.instance.dragData[this.scope]=this.droppables[this.scope],o.instance.intDrop(i,o.target)),this.setGlobalDroppables(!0),document.body.classList.remove("e-prevent-select")}},t.prototype.intDestroy=function(i){this.dragProcessStarted=!1,this.toggleEvents(),document.body.classList.remove("e-prevent-select"),this.element.setAttribute("aria-grabbed","false"),E.remove(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.intDragStart),E.remove(document,X.isSafari()?"touchend":X.touchEndEvent,this.intDragStop),E.remove(document,X.isSafari()?"touchend":X.touchEndEvent,this.intDestroy),E.remove(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.intDrag),this.isDragStarted()&&this.isDragStarted(!0)},t.prototype.onPropertyChanged=function(i,r){},t.prototype.getModuleName=function(){return"draggable"},t.prototype.isDragStarted=function(i){return i&&(bC.isDragged=!bC.isDragged),bC.isDragged},t.prototype.setDragArea=function(){var i,r,a,s=0,o=0;if(a="string"==typeof this.dragArea?U(this.dragArea):this.dragArea){var h=a.getBoundingClientRect();i=a.scrollWidth?a.scrollWidth:h.right-h.left,r=a.scrollHeight?this.dragArea&&!m(this.helperElement)&&this.helperElement.classList.contains("e-treeview")?a.clientHeight:a.scrollHeight:h.bottom-h.top;for(var c=["Top","Left","Bottom","Right"],d=getComputedStyle(a),u=0;u12;return C0(i.target,this.helperElement)||-1!==i.type.indexOf("touch")||a?(this.helperElement.style.pointerEvents="none",s=document.elementFromPoint(r.clientX,r.clientY),this.helperElement.style.pointerEvents=o):s=i.target,s},t.prototype.currentStateCheck=function(i,r){return m(this.currentStateTarget)||this.currentStateTarget===i?m(r)?i:r:this.currentStateTarget},t.prototype.getMousePosition=function(i,r){var a,l,s=void 0!==i.srcElement?i.srcElement:i.target,o=this.getCoordinates(i),h=m(s.offsetParent);if(r?(a=this.clone?o.pageX:o.pageX+(h?0:s.offsetParent.scrollLeft)-this.relativeXPosition,l=this.clone?o.pageY:o.pageY+(h?0:s.offsetParent.scrollTop)-this.relativeYPosition):(a=this.clone?o.pageX:o.pageX+window.pageXOffset-this.relativeXPosition,l=this.clone?o.pageY:o.pageY+window.pageYOffset-this.relativeYPosition),document.scrollingElement&&!r&&!this.clone){var c=document.scrollingElement;a=c.scrollWidth>0&&c.scrollWidth>c.clientWidth&&c.scrollLeft>0?a-c.scrollLeft:a,l=c.scrollHeight>0&&c.scrollHeight>c.clientHeight&&c.scrollTop>0?l-c.scrollTop:l}return{left:a-(this.margin.left+this.cursorAt.left),top:l-(this.margin.top+this.cursorAt.top)}},t.prototype.getCoordinates=function(i){return i.type.indexOf("touch")>-1?i.changedTouches[0]:i},t.prototype.getHelperElement=function(i){var r;return this.clone?this.helper?r=this.helper({sender:i,element:this.target}):(r=mi("div",{className:"e-drag-helper e-block-touch",innerHTML:"Draggable"}),document.body.appendChild(r)):r=this.element,r},t.prototype.setGlobalDroppables=function(i,r,s){this.droppables[this.scope]=i?null:{draggable:r,helper:s,draggedElement:this.element}},t.prototype.checkTargetElement=function(i){var r=this.getProperTargetElement(i),s=this.getDropInstance(r);if(!s&&r&&!m(r.parentNode)){var o=J(r.parentNode,".e-droppable")||r.parentElement;o&&(s=this.getDropInstance(o))}return{target:r,instance:s}},t.prototype.getDropInstance=function(i){var s,o=i&&i.ej2_instances;if(o)for(var a=0,l=o;a=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},lR=function(n){function t(e,i){var r=n.call(this,i,e)||this;return r.mouseOver=!1,r.dragData={},r.dragStopCalled=!1,r.bind(),r}return sZ(t,n),t.prototype.bind=function(){this.wireEvents()},t.prototype.wireEvents=function(){E.add(this.element,X.isSafari()?"touchend":X.touchEndEvent,this.intDrop,this)},t.prototype.onPropertyChanged=function(e,i){},t.prototype.getModuleName=function(){return"droppable"},t.prototype.intOver=function(e,i){this.mouseOver||(this.trigger("over",{event:e,target:i,dragData:this.dragData[this.scope]}),this.mouseOver=!0)},t.prototype.intOut=function(e,i){this.mouseOver&&(this.trigger("out",{evt:e,target:i}),this.mouseOver=!1)},t.prototype.intDrop=function(e,i){if(this.dragStopCalled){this.dragStopCalled=!1;var a,r=!0,s=this.dragData[this.scope],o=!!s&&s.helper&&Tr(s.helper);o&&(a=this.isDropArea(e,s.helper,i),this.accept&&(r=vC(s.helper,this.accept))),o&&this.drop&&a.canDrop&&r&&this.trigger("drop",{event:e,target:a.target,droppedElement:s.helper,dragData:s}),this.mouseOver=!1}},t.prototype.isDropArea=function(e,i,r){var s={canDrop:!0,target:r||e.target},o="touchend"===e.type;if(o||s.target===i){i.style.display="none";var a=o?e.changedTouches[0]:e,l=document.elementFromPoint(a.clientX,a.clientY);s.canDrop=!1,s.canDrop=C0(l,this.element),s.canDrop&&(s.target=l),i.style.display=""}return s},t.prototype.destroy=function(){E.remove(this.element,X.isSafari()?"touchend":X.touchEndEvent,this.intDrop),n.prototype.destroy.call(this)},lp([I()],t.prototype,"accept",void 0),lp([I("default")],t.prototype,"scope",void 0),lp([H()],t.prototype,"drop",void 0),lp([H()],t.prototype,"over",void 0),lp([H()],t.prototype,"out",void 0),lp([Ft],t)}(ah),ho=function(){function n(t,e,i){this.controlName=t,this.localeStrings=e,this.setLocale(i||"en-US")}return n.prototype.setLocale=function(t){var e=this.intGetControlConstant(n.locale,t);this.currentLocale=e||this.localeStrings},n.load=function(t){this.locale=ze(this.locale,t,{},!0)},n.prototype.getConstant=function(t){return m(this.currentLocale[""+t])?this.localeStrings[""+t]||"":this.currentLocale[""+t]},n.prototype.intGetControlConstant=function(t,e){return t[""+e]?t[""+e][this.controlName]:null},n.locale={},n}(),hR=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),hh=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},lZ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return hR(t,n),hh([I(50)],t.prototype,"swipeThresholdDistance",void 0),t}(Ee),hZ=/(Up|Down)/,Fs=function(n){function t(e,i){var r=n.call(this,i,e)||this;return r.touchAction=!0,r.tapCount=0,r.startEvent=function(s){if(!0===r.touchAction){var o=r.updateChangeTouches(s);void 0!==s.changedTouches&&(r.touchAction=!1),r.isTouchMoved=!1,r.movedDirection="",r.startPoint=r.lastMovedPoint={clientX:o.clientX,clientY:o.clientY},r.startEventData=o,r.hScrollLocked=r.vScrollLocked=!1,r.tStampStart=Date.now(),r.timeOutTapHold=setTimeout(function(){r.tapHoldEvent(s)},r.tapHoldThreshold),E.add(r.element,X.touchMoveEvent,r.moveEvent,r),E.add(r.element,X.touchEndEvent,r.endEvent,r),E.add(r.element,X.touchCancelEvent,r.cancelEvent,r)}},r.moveEvent=function(s){var o=r.updateChangeTouches(s);r.movedPoint=o,r.isTouchMoved=!(o.clientX===r.startPoint.clientX&&o.clientY===r.startPoint.clientY);var a={};r.isTouchMoved&&(clearTimeout(r.timeOutTapHold),r.calcScrollPoints(s),a=ze(a,{},{startEvents:r.startEventData,originalEvent:s,startX:r.startPoint.clientX,startY:r.startPoint.clientY,distanceX:r.distanceX,distanceY:r.distanceY,scrollDirection:r.scrollDirection,velocity:r.getVelocity(o)}),r.trigger("scroll",a),r.lastMovedPoint={clientX:o.clientX,clientY:o.clientY})},r.cancelEvent=function(s){clearTimeout(r.timeOutTapHold),clearTimeout(r.timeOutTap),r.tapCount=0,r.swipeFn(s),E.remove(r.element,X.touchCancelEvent,r.cancelEvent)},r.endEvent=function(s){r.swipeFn(s),r.isTouchMoved||"function"==typeof r.tap&&(r.trigger("tap",{originalEvent:s,tapCount:++r.tapCount}),r.timeOutTap=setTimeout(function(){r.tapCount=0},r.tapThreshold)),r.modeclear()},r.swipeFn=function(s){clearTimeout(r.timeOutTapHold),clearTimeout(r.timeOutTap);var o=r.updateChangeTouches(s),a=o.clientX-r.startPoint.clientX,l=o.clientY-r.startPoint.clientY;a=Math.floor(a<0?-1*a:a),l=Math.floor(l<0?-1*l:a),r.isTouchMoved=a>1||l>1,/Firefox/.test(X.userAgent)&&0===o.clientX&&0===o.clientY&&"mouseup"===s.type&&(r.isTouchMoved=!1),r.endPoint=o,r.calcPoints(s);var c={originalEvent:s,startEvents:r.startEventData,startX:r.startPoint.clientX,startY:r.startPoint.clientY,distanceX:r.distanceX,distanceY:r.distanceY,swipeDirection:r.movedDirection,velocity:r.getVelocity(o)};if(r.isTouchMoved){var d=r.swipeSettings.swipeThresholdDistance,u=ze(void 0,r.defaultArgs,c),p=!1,f=r.element,g=r.isScrollable(f),v=hZ.test(r.movedDirection);(dthis.distanceY?i.clientX>this.startPoint.clientX?"Right":"Left":i.clientYthis.distanceY||!0===this.hScrollLocked)&&!1===this.vScrollLocked?(this.scrollDirection=i.clientX>this.lastMovedPoint.clientX?"Right":"Left",this.hScrollLocked=!0):(this.scrollDirection=i.clientY=e[r[0]+s[0]]},t.prototype.updateChangeTouches=function(e){return e.changedTouches&&0!==e.changedTouches.length?e.changedTouches[0]:e},hh([H()],t.prototype,"tap",void 0),hh([H()],t.prototype,"tapHold",void 0),hh([H()],t.prototype,"swipe",void 0),hh([H()],t.prototype,"scroll",void 0),hh([I(350)],t.prototype,"tapThreshold",void 0),hh([I(750)],t.prototype,"tapHoldThreshold",void 0),hh([re({},lZ)],t.prototype,"swipeSettings",void 0),hh([Ft],t)}(ah),cZ=new RegExp("\\n|\\r|\\s\\s+","g"),dZ=new RegExp(/'|"/g),uZ=new RegExp("if ?\\("),pZ=new RegExp("else if ?\\("),cR=new RegExp("else"),fZ=new RegExp("for ?\\("),dR=new RegExp("(/if|/for)"),gZ=new RegExp("\\((.*)\\)",""),MC=new RegExp("^[0-9]+$","g"),vZ=new RegExp("[\\w\"'.\\s+]+","g"),mZ=new RegExp('"(.*?)"',"g"),yZ=new RegExp("[\\w\"'@#$.\\s-+]+","g"),uR=new RegExp("\\${([^}]*)}","g"),SZ=/^\..*/gm,wC=/\\/gi,IZ=/\\\\/gi,bZ=new RegExp("[\\w\"'@#$.\\s+]+","g"),MZ=/\window\./gm;function hp(n,t,e,i,r){return!t||MC.test(n)||-1!==i.indexOf(n.split(".")[0])||r||"true"===n||"false"===n?n:e+"."+n}function CC(n,t,e,i){return t&&!MC.test(n)&&-1===i.indexOf(n.split(".")[0])?e+'["'+n:n}function pR(n){return n.match(IZ)?n:n.replace(wC,"\\\\")}function fR(n,t,e,i){if(n=n.trim(),/\window\./gm.test(n))return n;var s=/'|"/gm;return/@|\$|#/gm.test(n)&&(n=CC(n,-1===e.indexOf(n),t,e)+'"]'),SZ.test(n)?function EZ(n,t,e,i){return!t||MC.test(n)||-1!==i.indexOf(n.split(".")[0])||/^\..*/gm.test(n)?n:e+"."+n}(n,!s.test(n)&&-1===e.indexOf(n),t,e):hp(n,!s.test(n)&&-1===e.indexOf(n),t,e,i)}var DZ=/^[\n\r.]+0&&t.forEach(function(e){he(e)})},n.removeJsEvents=function(){var t=this.wrapElement.querySelectorAll("["+vR.join("],[")+"]");t.length>0&&t.forEach(function(e){vR.forEach(function(i){e.hasAttribute(i)&&e.removeAttribute(i)})})},n.removeXssAttrs=function(){var t=this;this.removeAttrs.forEach(function(e,i){var r=t.wrapElement.querySelectorAll(e.selector);r.length>0&&r.forEach("a[href]"===e.selector?function(s){-1!==s.getAttribute(e.attribute).replace(/\t|\s|&/,"").indexOf("javascript:alert")&&s.removeAttribute(e.attribute)}:function(s){s.removeAttribute(e.attribute)})})},n}();function PZ(n){return function(t){!function kZ(n,t){t.forEach(function(e){Object.getOwnPropertyNames(e.prototype).forEach(function(i){(!Object.prototype.hasOwnProperty.call(n.prototype,i)||e.isFormBase&&"constructor"!==i)&&(n.prototype["".concat(i)]=e.prototype["".concat(i)])})})}(t,n)}}function mR(n,t,e){var i={};if(n&&n.length){for(var r=0,s=n;r"u"||(y.innerHTML=v.innerHTML?v.innerHTML:"",void 0!==v.className&&(y.className=v.className),void 0!==v.id&&(y.id=v.id),void 0!==v.styles&&y.setAttribute("style",v.styles),void 0!==e.ngAttr&&y.setAttribute(e.ngAttr,""),void 0!==v.attrs&&Fe(y,v.attrs)),y};for(var i=0,r=e.tags;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s}function jZ(n){for(var t,e=n.childNodes,i=0;i"u"&&(c["".concat(o)]=[]),c["".concat(o)].push(h),h.rootNodes}}});var ml,hd,ph,Vg,sc,uo,YZ=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),La=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Jo_RTL=(new Lg,"e-rtl"),ys=function(n){function t(e,i){return n.call(this,e,i)||this}return YZ(t,n),t.prototype.preRender=function(){},t.prototype.render=function(){this.initialize(),this.removeRippleEffect=function ms(n,t,e){var i=function q$(n){return{selector:n&&n.selector?n.selector:null,ignore:n&&n.ignore?n.ignore:null,rippleFlag:n&&n.rippleFlag,isCenterRipple:n&&n.isCenterRipple,duration:n&&n.duration?n.duration:350}}(t);return!1===i.rippleFlag||void 0===i.rippleFlag&&!Zo?function(){}:(n.setAttribute("data-ripple","true"),E.add(n,"mousedown",Zz,{parent:n,rippleOptions:i}),E.add(n,"mouseup",Jz,{parent:n,rippleOptions:i,done:e}),E.add(n,"mouseleave",op,{parent:n,rippleOptions:i}),X.isPointer&&E.add(n,"transitionend",op,{parent:n,rippleOptions:i}),function(){n.removeAttribute("data-ripple"),E.remove(n,"mousedown",Zz),E.remove(n,"mouseup",Jz),E.remove(n,"mouseleave",op),E.remove(n,"transitionend",op)})}(this.element,{selector:".e-btn"}),this.renderComplete()},t.prototype.initialize=function(){if(this.cssClass&&V([this.element],this.cssClass.replace(/\s+/g," ").trim().split(" ")),this.isPrimary&&this.element.classList.add("e-primary"),!ce()||ce()&&"progress-btn"!==this.getModuleName()){if(this.content){var e=this.enableHtmlSanitizer?Ti.sanitize(this.content):this.content;this.element.innerHTML=e}this.setIconCss()}this.enableRtl&&this.element.classList.add(Jo_RTL),this.disabled?this.controlStatus(this.disabled):this.wireEvents()},t.prototype.controlStatus=function(e){this.element.disabled=e},t.prototype.setIconCss=function(){if(this.iconCss){var e=this.createElement("span",{className:"e-btn-icon "+this.iconCss});this.element.textContent.trim()?(e.classList.add("e-icon-"+this.iconPosition.toLowerCase()),("Top"===this.iconPosition||"Bottom"===this.iconPosition)&&this.element.classList.add("e-"+this.iconPosition.toLowerCase()+"-icon-btn")):this.element.classList.add("e-icon-btn");var i=this.element.childNodes[0];!i||"Left"!==this.iconPosition&&"Top"!==this.iconPosition?this.element.appendChild(e):this.element.insertBefore(e,i)}},t.prototype.wireEvents=function(){this.isToggle&&E.add(this.element,"click",this.btnClickHandler,this)},t.prototype.unWireEvents=function(){this.isToggle&&E.remove(this.element,"click",this.btnClickHandler)},t.prototype.btnClickHandler=function(){this.element.classList.contains("e-active")?this.element.classList.remove("e-active"):this.element.classList.add("e-active")},t.prototype.destroy=function(){var e=["e-primary",Jo_RTL,"e-icon-btn","e-success","e-info","e-danger","e-warning","e-flat","e-outline","e-small","e-bigger","e-active","e-round","e-top-icon-btn","e-bottom-icon-btn"];this.cssClass&&(e=e.concat(this.cssClass.split(" "))),n.prototype.destroy.call(this),K([this.element],e),this.element.getAttribute("class")||this.element.removeAttribute("class"),this.disabled&&this.element.removeAttribute("disabled"),this.content&&(this.element.innerHTML=this.element.innerHTML.replace(this.content,""));var i=this.element.querySelector("span.e-btn-icon");i&&he(i),this.unWireEvents(),Zo&&this.removeRippleEffect()},t.prototype.getModuleName=function(){return"btn"},t.prototype.getPersistData=function(){return this.addOnPersist([])},t.Inject=function(){},t.prototype.onPropertyChanged=function(e,i){for(var r=this.element.querySelector("span.e-btn-icon"),s=0,o=Object.keys(e);s=hd.width?hd.width:0;return ml.right+JR()-n}function dE(){return U0()+ml.width/2}function uE(n,t,e,i){if(void 0===t&&(t=null),void 0===e&&(e={X:!1,Y:!1}),!e.Y&&!e.X)return{left:0,top:0};var r=n.getBoundingClientRect();if(uo=t,sc=n.ownerDocument,i||(i=is(n,"left","top")),e.X){var s=uo?r4():l4(),o=mE(),a=yE(),l=o-i.left,h=i.left+r.width-a;r.width>s?i.left=l>0&&h<=0?a-r.width:h>0&&l<=0?o:l>h?a-r.width:o:l>0?i.left+=l:h>0&&(i.left-=h)}if(e.Y){var c=uo?n4():a4(),d=vE(),u=SE(),p=d-i.top,f=i.top+r.height-u;r.height>c?i.top=p>0&&f<=0?u-r.height:f>0&&p<=0?d:p>f?u-r.height:d:p>0?i.top+=p:f>0&&(i.top-=f)}return i}function oc(n,t,e,i){void 0===t&&(t=null);var r=is(n,"left","top");e&&(r.left=e),i&&(r.top=i);var s=[];uo=t,sc=n.ownerDocument;var o=n.getBoundingClientRect(),l=r.left,h=r.left+o.width,d=gE(r.top,r.top+o.height),u=e4(l,h);return d.topSide&&s.push("top"),u.rightSide&&s.push("right"),u.leftSide&&s.push("left"),d.bottomSide&&s.push("bottom"),s}function bJ(n,t,e,i,r,s,o,a,l){if(void 0===o&&(o=null),void 0===a&&(a={X:!0,Y:!0}),t&&n&&r&&s&&(a.X||a.Y)){var d,h={TL:null,TR:null,BL:null,BR:null},c={TL:null,TR:null,BL:null,BR:null};if("none"===window.getComputedStyle(n).display){var u=n.style.visibility;n.style.visibility="hidden",n.style.display="block",d=n.getBoundingClientRect(),n.style.removeProperty("display"),n.style.visibility=u}else d=n.getBoundingClientRect();var p={posX:r,posY:s,offsetX:e,offsetY:i,position:{left:0,top:0}};uo=o,sc=t.ownerDocument,function wJ(n,t,e,i,r){e.position=is(n,e.posX,e.posY,i,r),t.TL=is(n,"left","top",i,r),t.TR=is(n,"right","top",i,r),t.BR=is(n,"left","bottom",i,r),t.BL=is(n,"right","bottom",i,r)}(t,h,p,l,d),fE(c,p,d),a.X&&t4(t,c,h,p,d,!0),a.Y&&h.TL.top>-1&&i4(t,c,h,p,d,!0),function MJ(n,t,e){var i=0,r=0;if(null!=n.offsetParent&&("absolute"===getComputedStyle(n.offsetParent).position||"relative"===getComputedStyle(n.offsetParent).position)){var s=is(n.offsetParent,"left","top",!1,e);i=s.left,r=s.top}var o=1,a=1,l=KR(n);if(l){var h=getComputedStyle(l).transform;if("none"!==h){var c=new DOMMatrix(h);o=c.a,a=c.d}if("none"!==getComputedStyle(l).zoom){var u=pE(document.body);o*=u,a*=u}}n.style.top=t.position.top/a+t.offsetY-r/a+"px",n.style.left=t.position.left/o+t.offsetX-i/o+"px"}(n,p,d)}}function pE(n){var t=getComputedStyle(n).zoom;return parseFloat(t)||1}function KR(n){for(;n;){var t=window.getComputedStyle(n).transform,e=pE(document.body);if(t&&"none"!==t||e&&1!==e)return n;if(n===document.body)return null;n=n.offsetParent||n.parentElement}return null}function fE(n,t,e){n.TL={top:t.position.top+t.offsetY,left:t.position.left+t.offsetX},n.TR={top:n.TL.top,left:n.TL.left+e.width},n.BL={top:n.TL.top+e.height,left:n.TL.left},n.BR={top:n.TL.top+e.height,left:n.TL.left+e.width}}function e4(n,t){var e=!1,i=!1;return n-V0()yE()&&(i=!0),{leftSide:e,rightSide:i}}function t4(n,t,e,i,r,s){var o=e4(t.TL.left,t.TR.left),a=gE(t.TL.top,t.BL.top);e.TL.left-V0()<=mE()&&(o.leftSide=!1),e.TR.left>yE()&&(o.rightSide=!1),(o.leftSide&&!o.rightSide||!o.leftSide&&o.rightSide)&&(i.posX="right"===i.posX?"left":"right",i.offsetX=i.offsetX+r.width,i.offsetX=-1*i.offsetX,i.position=is(n,i.posX,i.posY,!1),fE(t,i,r),s&&t4(n,t,e,i,r,!1),!o.leftSide&&o.rightSide&&a.bottomSide&&(i.offsetX=0))}function i4(n,t,e,i,r,s){var o=gE(t.TL.top,t.BL.top);e.TL.top-j0()<=vE()&&(o.topSide=!1),e.BL.top>=SE()&&n.getBoundingClientRect().bottomSE()&&(i=!0),{topSide:e,bottomSide:i}}function r4(){return uo.getBoundingClientRect().width}function n4(){return uo.getBoundingClientRect().height}function s4(){return uo.getBoundingClientRect().left}function o4(){return uo.getBoundingClientRect().top}function vE(){return uo?o4():0}function mE(){return uo?s4():0}function yE(){return uo?V0()+s4()+r4():V0()+l4()}function SE(){return uo?j0()+o4()+n4():j0()+a4()}function j0(){return sc.documentElement.scrollTop||sc.body.scrollTop}function V0(){return sc.documentElement.scrollLeft||sc.body.scrollLeft}function a4(){return window.innerHeight}function l4(){var n=window.innerWidth,t=document.documentElement.getBoundingClientRect();return n-(n-(m(document.documentElement)?0:t.width))}function h4(){uo=null,sc=null}var c4=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),bn=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},d4=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return c4(t,n),bn([I("left")],t.prototype,"X",void 0),bn([I("top")],t.prototype,"Y",void 0),t}(Ee),Gn_OPEN="e-popup-open",Gn_CLOSE="e-popup-close",ac=function(n){function t(e,i){return n.call(this,i,e)||this}return c4(t,n),t.prototype.onPropertyChanged=function(e,i){for(var r=0,s=Object.keys(e);r0&&c.left>0&&c.right>0&&c.bottom>0}var s=i.getBoundingClientRect();return!(r.bottoms.bottom||r.right>s.right||r.leftr.top?this.element.style.top="0px":s.bottomr.left&&(this.element.style.left=parseInt(this.element.style.left,10)+(s.left-r.left)+"px"))}},t.prototype.checkCollision=function(){var e=this.collision.X,i=this.collision.Y;"none"===e&&"none"===i||("flip"===e&&"flip"===i?this.callFlip({X:!0,Y:!0}):"fit"===e&&"fit"===i?this.callFit({X:!0,Y:!0}):("flip"===e?this.callFlip({X:!0,Y:!1}):"flip"===i&&this.callFlip({Y:!0,X:!1}),"fit"===e?this.callFit({X:!0,Y:!1}):"fit"===i&&this.callFit({X:!1,Y:!0})))},t.prototype.show=function(e,i){var r=this;if(this.getRelateToElement().classList.contains("e-filemanager")&&(this.fmDialogContainer=this.element.getElementsByClassName("e-file-select-wrap")[0]),this.wireEvents(),!m(this.fmDialogContainer)&&X.isIos&&(this.fmDialogContainer.style.display="block"),1e3===this.zIndex||!m(i)){var o=m(i)?this.element:i;this.zIndex=lc(o),je(this.element,{zIndex:this.zIndex})}e=m(e)||"object"!=typeof e?this.showAnimation:e,("none"!==this.collision.X||"none"!==this.collision.Y)&&(K([this.element],Gn_CLOSE),V([this.element],Gn_OPEN),this.checkCollision(),K([this.element],Gn_OPEN),V([this.element],Gn_CLOSE)),m(e)?(K([this.element],Gn_CLOSE),V([this.element],Gn_OPEN),this.trigger("open")):(e.begin=function(){r.isDestroyed||(K([r.element],Gn_CLOSE),V([r.element],Gn_OPEN))},e.end=function(){r.isDestroyed||r.trigger("open")},new Hs(e).animate(this.element))},t.prototype.hide=function(e){var i=this;e=m(e)||"object"!=typeof e?this.hideAnimation:e,m(e)?(K([this.element],Gn_OPEN),V([this.element],Gn_CLOSE),this.trigger("close")):(e.end=function(){i.isDestroyed||(K([i.element],Gn_OPEN),V([i.element],Gn_CLOSE),i.trigger("close"))},new Hs(e).animate(this.element)),this.unwireEvents()},t.prototype.getScrollableParent=function(e){return this.checkFixedParent(e),function IE(n,t){for(var e=getComputedStyle(n),i=[],r=/(auto|scroll)/,s=n.parentElement;s&&"HTML"!==s.tagName;){var o=getComputedStyle(s);!("absolute"===e.position&&"static"===o.position)&&r.test(o.overflow+o.overflowY+o.overflowX)&&i.push(s),s=s.parentElement}return t||i.push(document),i}(e,this.fixedParent)},t.prototype.checkFixedParent=function(e){for(var i=e.parentElement;i&&"HTML"!==i.tagName;){var r=getComputedStyle(i);("fixed"===r.position||"sticky"===r.position)&&!m(this.element)&&this.element.offsetParent&&"BODY"===this.element.offsetParent.tagName&&"hidden"!==getComputedStyle(this.element.offsetParent).overflow&&(this.element.style.top=window.scrollY>parseInt(this.element.style.top,10)?Re(window.scrollY-parseInt(this.element.style.top,10)):Re(parseInt(this.element.style.top,10)-window.scrollY),this.element.style.position="fixed",this.fixedParent=!0),i=i.parentElement,!m(this.element)&&m(this.element.offsetParent)&&"fixed"===r.position&&"fixed"===this.element.style.position&&(this.fixedParent=!0)}},bn([I("auto")],t.prototype,"height",void 0),bn([I("auto")],t.prototype,"width",void 0),bn([I(null)],t.prototype,"content",void 0),bn([I("container")],t.prototype,"targetType",void 0),bn([I(null)],t.prototype,"viewPortElement",void 0),bn([I({X:"none",Y:"none"})],t.prototype,"collision",void 0),bn([I("")],t.prototype,"relateTo",void 0),bn([re({},d4)],t.prototype,"position",void 0),bn([I(0)],t.prototype,"offsetX",void 0),bn([I(0)],t.prototype,"offsetY",void 0),bn([I(1e3)],t.prototype,"zIndex",void 0),bn([I(!1)],t.prototype,"enableRtl",void 0),bn([I("reposition")],t.prototype,"actionOnScroll",void 0),bn([I(null)],t.prototype,"showAnimation",void 0),bn([I(null)],t.prototype,"hideAnimation",void 0),bn([H()],t.prototype,"open",void 0),bn([H()],t.prototype,"close",void 0),bn([H()],t.prototype,"targetExitViewport",void 0),bn([Ft],t)}(yi);function lc(n){for(var t=n.parentElement,e=[];t&&"BODY"!==t.tagName;){var i=document.defaultView.getComputedStyle(t,null).getPropertyValue("z-index"),r=document.defaultView.getComputedStyle(t,null).getPropertyValue("position");"auto"!==i&&"static"!==r&&e.push(i),t=t.parentElement}for(var s=[],o=0;o2147483647?2147483647:c}var _i,Oa,cp,vh,CE,mh,$t,yh,bE=["north-west","north","north-east","west","east","south-west","south","south-east"],Wg="e-resize-handle",hc="e-focused-handle",CJ="e-dlg-resizable",u4=["e-restrict-left"],p4="e-resize-viewport",EJ=["north","west","east","south"],ME=0,wE=0,f4=0,g4=0,Yg=0,Qg=0,Gg=null,EE=null,DE=null,W0=!0,v4=0,xE=!0;function xJ(n){TE();var t=mi("span",{attrs:{unselectable:"on",contenteditable:"false"}});t.setAttribute("class","e-dialog-border-resize e-"+n),"south"===n&&(t.style.height="2px",t.style.width="100%",t.style.bottom="0px",t.style.left="0px"),"north"===n&&(t.style.height="2px",t.style.width="100%",t.style.top="0px",t.style.left="0px"),"east"===n&&(t.style.height="100%",t.style.width="2px",t.style.right="0px",t.style.top="0px"),"west"===n&&(t.style.height="100%",t.style.width="2px",t.style.left="0px",t.style.top="0px"),_i.appendChild(t)}function m4(n){var t;return m(n)||(t="string"==typeof n?document.querySelector(n):n),t}function y4(n){for(var t=n||this,e=_i.querySelectorAll("."+Wg),i=0;i-1?"mouse":"touch"}function I4(n){if(n.preventDefault(),_i=n.target.parentElement,TE(),Yg=n.pageX,Qg=n.pageY,n.target.classList.add(hc),m(Gg)||!0!==Gg(n,this)){this.targetEle&&_i&&_i.querySelector("."+CJ)&&($t="body"===this.target?null:this.targetEle,mh=this.targetEle.clientWidth,vh=this.targetEle.clientHeight);var e=m($t)?document:$t;E.add(e,"mousemove",Xg,this),E.add(document,"mouseup",Y0,this);for(var i=0;i=0||s.top<0)&&(e=!0):e=!0;var a=wE+(r-Qg);a=a>cp?a:cp;var l=0;m($t)||(l=o.top);var h=m($t)?0:$t.offsetHeight-$t.clientHeight,c=s.top-l-h/2;if(c=c<0?0:c,s.top>0&&c+a>vh){if(e=!1,_i.classList.contains(p4))return;_i.style.height=vh-parseInt(c.toString(),10)+"px"}else{var d=0;if(e){s.top<0&&t+(s.height+s.top)>0&&a+(d=s.top)<=30&&(a=s.height-(s.height+s.top)+30),a+s.top>=vh&&(_i.style.height=s.height+(t-(s.height+s.top))+"px");var u=m($t)?d:c;a>=cp&&a+u<=vh&&(_i.style.height=a+"px")}}}function LE(n){var e,t=!1,i="mouse"===S4(n.type)?n.pageY:n.touches[0].pageY,r=cc(_i),s=m($t)?0:$t.offsetHeight-$t.clientHeight;m($t)||(e=cc($t)),(!m($t)&&r.top-e.top>0||m($t)&&i>0||!m($t)&&Math.floor(r.top-e.top+r.height+(e.bottom-r.bottom))-s<=vh)&&(t=!0);var o=wE-(i-Qg);if(t&&o>=cp&&o<=vh){var a=0;m($t)||(a=e.top);var l=g4-a+(i-Qg);l=l>0?l:1,_i.style.height=o+"px",_i.style.top=l+"px"}}function NE(n){var i,t=document.documentElement.clientWidth,e=!1;m($t)||(i=cc($t));var r="mouse"===S4(n.type)?n.pageX:n.touches[0].pageX,s=cc(_i),o=m($t)?0:$t.offsetWidth-$t.clientWidth,a=m($t)?0:i.left,l=m($t)?0:i.width;m(yh)&&(m($t)?yh=t:(yh=s.left-a-o/2+s.width,yh+=l-o-yh)),(!m($t)&&Math.floor(s.left-i.left+s.width+(i.right-s.right))-o<=mh||m($t)&&r>=0)&&(e=!0);var h=ME-(r-Yg);if(W0&&(h=h>yh?yh:h),e&&h>=CE&&h<=mh){var c=0;m($t)||(c=i.left);var d=f4-c+(r-Yg);d=d>0?d:1,h!==v4&&xE&&(_i.style.width=h+"px"),W0&&(_i.style.left=d+"px",xE=1!==d)}v4=h}function OE(n){var i,t=document.documentElement.clientWidth,e=!1;m($t)||(i=cc($t));var s=(n.touches?n.changedTouches[0]:n).pageX,o=cc(_i);(!m($t)&&(o.left-i.left+o.width<=mh||o.right-i.left>=o.width)||m($t)&&t-s>0)&&(e=!0);var a=ME+(s-Yg),l=0;if(m($t)||(l=i.left),o.left-l+a>mh){if(e=!1,_i.classList.contains(p4))return;_i.style.width=mh-(o.left-l)+"px"}e&&a>=CE&&a<=mh&&(_i.style.width=a+"px")}function M4(){for(var n=_i.querySelectorAll("."+Wg),t=0;t=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},OJ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return kE(t,n),Zt([I(!0)],t.prototype,"isFlat",void 0),Zt([I()],t.prototype,"buttonModel",void 0),Zt([I("Button")],t.prototype,"type",void 0),Zt([H()],t.prototype,"click",void 0),t}(Ee),kJ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return kE(t,n),Zt([I("Fade")],t.prototype,"effect",void 0),Zt([I(400)],t.prototype,"duration",void 0),Zt([I(0)],t.prototype,"delay",void 0),t}(Ee),Q0="e-dialog",PE="e-rtl",zE="e-dlg-header-content",w4="e-dlg-header",G0="e-footer-content",X0="e-dlg-modal",C4="e-icon-dlg-close",yl="e-dlg-target",ka="e-scroll-disabled",E4="e-device",q0="e-dlg-fullscreen",D4="e-dlg-closeicon-btn",x4="e-popup-open",T4="Information",A4="e-scroll-disabled",L4="e-alert-dialog",N4="e-confirm-dialog",RE="e-dlg-resizable",dp="e-restrict-left",O4="e-resize-viewport",HE="user action",QJ=function(n){function t(e,i){var r=n.call(this,e,i)||this;return r.needsID=!0,r}return kE(t,n),t.prototype.render=function(){this.initialize(),this.initRender(),this.wireEvents(),"100%"===this.width&&(this.element.style.width=""),""!==this.minHeight&&(this.element.style.minHeight=Re(this.minHeight)),this.enableResize&&(this.setResize(),this.isModal&&(this.isModelResize=!0),"None"===this.animationSettings.effect&&this.getMinHeight()),this.renderComplete()},t.prototype.initializeValue=function(){this.dlgClosedBy=HE},t.prototype.preRender=function(){var e=this;if(this.initializeValue(),this.headerContent=null,this.allowMaxHeight=!0,this.preventVisibility=!0,this.clonedEle=this.element.cloneNode(!0),this.closeIconClickEventHandler=function(s){e.dlgClosedBy="close icon",e.hide(s)},this.dlgOverlayClickEventHandler=function(s){e.dlgClosedBy="overlayClick",s.preventFocus=!1,e.trigger("overlayClick",s,function(o){o.preventFocus||e.focusContent(),e.dlgClosedBy=HE})},this.l10n=new ho("dialog",{close:"Close"},this.locale),this.checkPositionData(),m(this.target)){var r=this.isProtectedOnChange;this.isProtectedOnChange=!0,this.target=document.body,this.isProtectedOnChange=r}},t.prototype.updatePersistData=function(){this.enablePersistence&&this.setProperties({width:parseFloat(this.element.style.width),height:parseFloat(this.element.style.height),position:{X:parseFloat(this.dragObj.element.style.left),Y:parseFloat(this.dragObj.element.style.top)}},!0)},t.prototype.isNumberValue=function(e){return/^[-+]?\d*\.?\d+$/.test(e)},t.prototype.checkPositionData=function(){if(!m(this.position)){if(!m(this.position.X)&&"number"!=typeof this.position.X&&this.isNumberValue(this.position.X)){var i=this.isProtectedOnChange;this.isProtectedOnChange=!0,this.position.X=parseFloat(this.position.X),this.isProtectedOnChange=i}m(this.position.Y)||"number"==typeof this.position.Y||this.isNumberValue(this.position.Y)&&(i=this.isProtectedOnChange,this.isProtectedOnChange=!0,this.position.Y=parseFloat(this.position.Y),this.isProtectedOnChange=i)}},t.prototype.getEle=function(e,i){for(var r=void 0,s=0;s=0&&t[e])xJ(t[e]);else if(""!==t[e].trim()){var i=mi("div",{className:"e-icons "+Wg+" e-"+t[e]});_i.appendChild(i)}cp=n.minHeight,CE=n.minWidth,mh=n.maxWidth,vh=n.maxHeight,n.proxy&&n.proxy.element&&n.proxy.element.classList.contains("e-dialog")?y4(n.proxy):y4()}({element:this.element,direction:r,minHeight:parseInt(e.slice(0,i.indexOf("p")),10),maxHeight:this.targetEle.clientHeight,minWidth:parseInt(i.slice(0,i.indexOf("p")),10),maxWidth:this.targetEle.clientWidth,boundary:this.target===document.body?null:this.targetEle,resizeBegin:this.onResizeStart.bind(this),resizeComplete:this.onResizeComplete.bind(this),resizing:this.onResizing.bind(this),proxy:this}),this.wireWindowResizeEvent()}else M4(),this.unWireWindowResizeEvent(),this.element.classList.remove(this.isModal?dp:O4),this.element.classList.remove(RE)},t.prototype.getFocusElement=function(e){var r=e.querySelectorAll('input,select,textarea,button:enabled,a,[contenteditable="true"],[tabindex]');return{element:r[r.length-1]}},t.prototype.keyDown=function(e){var i=this;if(9===e.keyCode&&this.isModal){var r=void 0;m(this.btnObj)||(r=this.btnObj[this.btnObj.length-1]),m(this.btnObj)&&!m(this.ftrTemplateContent)&&(r=this.getFocusElement(this.ftrTemplateContent)),m(this.btnObj)&&m(this.ftrTemplateContent)&&!m(this.contentEle)&&(r=this.getFocusElement(this.contentEle)),!m(r)&&document.activeElement===r.element&&!e.shiftKey&&(e.preventDefault(),this.focusableElements(this.element).focus()),document.activeElement===this.focusableElements(this.element)&&e.shiftKey&&(e.preventDefault(),m(r)||r.element.focus())}var h,s=document.activeElement,o=["input","textarea"].indexOf(s.tagName.toLowerCase())>-1,a=!1;if(o||(a=s.hasAttribute("contenteditable")&&"true"===s.getAttribute("contenteditable")),27===e.keyCode&&this.closeOnEscape){this.dlgClosedBy="escape";var l=document.querySelector(".e-popup-open:not(.e-dialog)");!m(l)&&!l.classList.contains("e-toolbar-pop")||this.hide(e)}(13===e.keyCode&&!e.ctrlKey&&"textarea"!==s.tagName.toLowerCase()&&o&&!m(this.primaryButtonEle)||13===e.keyCode&&e.ctrlKey&&("textarea"===s.tagName.toLowerCase()||a)&&!m(this.primaryButtonEle))&&this.buttons.some(function(d,u){h=u;var p=d.buttonModel;return!m(p)&&!0===p.isPrimary})&&"function"==typeof this.buttons[h].click&&setTimeout(function(){i.buttons[h].click.call(i,e)})},t.prototype.initialize=function(){m(this.target)||(this.targetEle="string"==typeof this.target?document.querySelector(this.target):this.target),this.isBlazorServerRender()||V([this.element],Q0),X.isDevice&&V([this.element],E4),this.isBlazorServerRender()||this.setCSSClass(),this.setMaxHeight()},t.prototype.initRender=function(){var e=this;if(this.initialRender=!0,this.isBlazorServerRender()||Fe(this.element,{role:"dialog"}),1e3===this.zIndex?(this.setzIndex(this.element,!1),this.calculatezIndex=!0):this.calculatezIndex=!1,this.setTargetContent(),""!==this.header&&!m(this.header)&&this.setHeader(),this.renderCloseIcon(),this.setContent(),""===this.footerTemplate||m(this.footerTemplate)?!m(this.buttons[0])&&!m(this.buttons[0].buttonModel)&&this.setButton():this.setFooterTemplate(),this.allowDragging&&!m(this.headerContent)&&this.setAllowDragging(),Fe(this.element,{"aria-modal":this.isModal?"true":"false"}),this.isModal&&this.setIsModal(),!0!==this.element.classList.contains(L4)&&!0!==this.element.classList.contains(N4)&&!m(this.element.parentElement)){var i=this.isModal?this.dlgContainer.parentElement:this.element.parentElement;this.refElement=this.createElement("div",{className:"e-dlg-ref-element"}),i.insertBefore(this.refElement,this.isModal?this.dlgContainer:this.element)}if(m(this.targetEle)||this.targetEle.appendChild(this.isModal?this.dlgContainer:this.element),this.popupObj=new ac(this.element,{height:this.height,width:this.width,zIndex:this.zIndex,relateTo:this.target,actionOnScroll:"none",enableRtl:this.enableRtl,open:function(o){var a={container:e.isModal?e.dlgContainer:e.element,element:e.element,target:e.target,preventFocus:!1};e.enableResize&&e.resetResizeIcon(),e.trigger("open",a,function(l){l.preventFocus||e.focusContent()})},close:function(o){e.isModal&&V([e.dlgOverlay],"e-fade"),e.unBindEvent(e.element),e.isModal&&(e.dlgContainer.style.display="none"),e.trigger("close",e.closeArgs);var a=document.activeElement;!m(a)&&!m(a.blur)&&a.blur(),!m(e.storeActiveElement)&&!m(e.storeActiveElement.focus)&&e.storeActiveElement.focus()}}),this.positionChange(),this.setEnableRTL(),this.isBlazorServerRender()||(V([this.element],"e-popup-close"),this.isModal&&this.setOverlayZindex()),this.visible){if(this.show(),this.isModal){var r=this.getTargetContainer(this.target);r instanceof Element&&"rtl"===window.getComputedStyle(r).getPropertyValue("direction")&&this.setPopupPosition()}}else this.isModal&&(this.dlgOverlay.style.display="none");this.initialRender=!1},t.prototype.getTargetContainer=function(e){var i=null;if("string"==typeof e)if(e.startsWith("#"))i=document.getElementById(e.substring(1));else if(e.startsWith(".")){var r=document.getElementsByClassName(e.substring(1));i=r.length>0?r[0]:null}else!(e instanceof HTMLElement)&&e!==document.body&&(i=document.querySelector(e));else e instanceof HTMLElement&&(i=e);return i},t.prototype.resetResizeIcon=function(){var e=this.getMinHeight();if(this.targetEle.offsetHeight0&&("function"==typeof this.buttons[e].click&&E.add(s[e],"click",this.buttons[e].click,this),"object"==typeof this.buttons[e].click&&E.add(s[e],"click",this.buttonClickHandler.bind(this,e),this)),!this.isBlazorServerRender()&&!m(this.ftrTemplateContent)&&(this.btnObj[e].appendTo(this.ftrTemplateContent.children[e]),this.buttons[e].isFlat&&this.btnObj[e].element.classList.add("e-flat"),this.primaryButtonEle=this.element.getElementsByClassName("e-primary")[0]))},t.prototype.buttonClickHandler=function(e){this.trigger("buttons["+e+"].click",{})},t.prototype.setContent=function(){this.contentEle=this.createElement("div",{className:"e-dlg-content",id:this.element.id+"_dialog-content"}),Fe(this.element,this.headerEle?{"aria-describedby":this.element.id+"_title "+this.element.id+"_dialog-content"}:{"aria-describedby":this.element.id+"_dialog-content"}),this.innerContentElement?this.contentEle.appendChild(this.innerContentElement):(!m(this.content)&&""!==this.content||!this.initialRender)&&(("string"!=typeof this.content||ce())&&this.content instanceof HTMLElement?this.contentEle.appendChild(this.content):this.setTemplate(this.content,this.contentEle,"content")),m(this.headerContent)?this.element.insertBefore(this.contentEle,this.element.children[0]):this.element.insertBefore(this.contentEle,this.element.children[1]),"auto"===this.height&&(!this.isBlazorServerRender()&&X.isIE&&""===this.element.style.width&&!m(this.width)&&(this.element.style.width=Re(this.width)),this.setMaxHeight())},t.prototype.setTemplate=function(e,i,r){var s,o,a;o=i.classList.contains(w4)?this.element.id+"header":i.classList.contains(G0)?this.element.id+"footerTemplate":this.element.id+"content",m(e.outerHTML)?("string"==typeof e||"string"!=typeof e||ce()&&!this.isStringTemplate)&&("string"==typeof e&&(e=this.sanitizeHelper(e)),this.isVue||"string"!=typeof e?(s=ii(e),a=e):i.innerHTML=e):i.appendChild(e);var l=[];if(!m(s)){for(var c=0,d=s({},this,r,o,!(ce()&&!this.isStringTemplate&&0===a.indexOf("
Blazor"))||this.isStringTemplate);c/g,"");(this.element.children.length>0||i)&&(this.innerContentElement=document.createDocumentFragment(),[].slice.call(this.element.childNodes).forEach(function(r){8!==r.nodeType&&e.innerContentElement.appendChild(r)}))}},t.prototype.setHeader=function(){this.headerEle?this.headerEle.innerHTML="":this.headerEle=this.createElement("div",{id:this.element.id+"_title",className:w4}),this.createHeaderContent(),this.headerContent.appendChild(this.headerEle),this.setTemplate(this.header,this.headerEle,"header"),Fe(this.element,{"aria-describedby":this.element.id+"_title"}),Fe(this.element,{"aria-labelledby":this.element.id+"_dialog-header"}),this.element.insertBefore(this.headerContent,this.element.children[0]),this.allowDragging&&!m(this.headerContent)&&this.setAllowDragging()},t.prototype.setFooterTemplate=function(){this.ftrTemplateContent?this.ftrTemplateContent.innerHTML="":this.ftrTemplateContent=this.createElement("div",{className:G0}),""===this.footerTemplate||m(this.footerTemplate)?this.ftrTemplateContent.innerHTML=this.buttonContent.join(""):this.setTemplate(this.footerTemplate,this.ftrTemplateContent,"footerTemplate"),this.element.appendChild(this.ftrTemplateContent)},t.prototype.createHeaderContent=function(){m(this.headerContent)&&(this.headerContent=this.createElement("div",{id:this.element.id+"_dialog-header",className:zE}))},t.prototype.renderCloseIcon=function(){this.showCloseIcon&&(this.closeIcon=this.createElement("button",{className:D4,attrs:{type:"button"}}),this.closeIconBtnObj=new ys({cssClass:"e-flat",iconCss:C4+" e-icons"}),this.closeIconTitle(),m(this.headerContent)?(this.createHeaderContent(),pl([this.closeIcon],this.headerContent),this.element.insertBefore(this.headerContent,this.element.children[0])):pl([this.closeIcon],this.headerContent),this.closeIconBtnObj.appendTo(this.closeIcon))},t.prototype.closeIconTitle=function(){this.l10n.setLocale(this.locale);var e=this.l10n.getConstant("close");this.closeIcon.setAttribute("title",e),this.closeIcon.setAttribute("aria-label",e)},t.prototype.setCSSClass=function(e){e&&(K([this.element],e.split(" ")),this.isModal&&!m(this.dlgContainer)&&K([this.dlgContainer],e.split(" "))),this.cssClass&&(V([this.element],this.cssClass.split(" ")),this.isModal&&!m(this.dlgContainer)&&V([this.dlgContainer],this.cssClass.split(" ")))},t.prototype.setIsModal=function(){this.dlgContainer=this.createElement("div",{className:"e-dlg-container"}),this.setCSSClass(),this.element.classList.remove(x4),this.element.parentNode.insertBefore(this.dlgContainer,this.element),this.dlgContainer.appendChild(this.element),V([this.element],X0),this.dlgOverlay=this.createElement("div",{className:"e-dlg-overlay"}),this.dlgOverlay.style.zIndex=(this.zIndex-1).toString(),this.dlgContainer.appendChild(this.dlgOverlay)},t.prototype.getValidFocusNode=function(e){for(var i,r=0;r0||"a"===i.tagName.toLowerCase()&&i.hasAttribute("href"))&&i.tabIndex>-1&&!i.disabled&&!this.disableElement(i,'[disabled],[aria-disabled="true"],[type="hidden"]'))return i;i=null}return i},t.prototype.focusableElements=function(e){if(!m(e)){var r=e.querySelectorAll('input,select,textarea,button,a,[contenteditable="true"],[tabindex]');return this.getValidFocusNode(r)}return null},t.prototype.getAutoFocusNode=function(e){var i=e.querySelector("."+D4),s=e.querySelectorAll("[autofocus]"),o=this.getValidFocusNode(s);if(ce()&&(this.primaryButtonEle=this.element.getElementsByClassName("e-primary")[0]),m(o)){if(!m(o=this.focusableElements(this.contentEle)))return o;if(!m(this.primaryButtonEle))return this.element.querySelector(".e-primary")}else i=o;return i},t.prototype.disableElement=function(e,i){var r=e?e.matches||e.webkitMatchesSelector||e.msGetRegionContent:null;if(r)for(;e;e=e.parentNode)if(e instanceof Element&&r.call(e,i))return e;return null},t.prototype.focusContent=function(){var e=this.getAutoFocusNode(this.element),i=m(e)?this.element:e,r=X.userAgent;(r.indexOf("MSIE ")>0||r.indexOf("Trident/")>0)&&this.element.focus(),i.focus(),this.unBindEvent(this.element),this.bindEvent(this.element)},t.prototype.bindEvent=function(e){E.add(e,"keydown",this.keyDown,this)},t.prototype.unBindEvent=function(e){E.remove(e,"keydown",this.keyDown)},t.prototype.updateSanitizeContent=function(){this.isBlazorServerRender()||(this.contentEle.innerHTML=this.sanitizeHelper(this.content))},t.prototype.isBlazorServerRender=function(){return ce()&&this.isServerRendered},t.prototype.getModuleName=function(){return"dialog"},t.prototype.onPropertyChanged=function(e,i){if(this.element.classList.contains(Q0))for(var r=0,s=Object.keys(e);r0?this.showCloseIcon||""!==this.header&&!m(this.header)?this.showCloseIcon||he(this.closeIcon):(he(this.headerContent),this.headerContent=null):(this.renderCloseIcon(),this.wireEvents());break;case"locale":this.showCloseIcon&&this.closeIconTitle();break;case"visible":this.visible?this.show():this.hide();break;case"isModal":this.updateIsModal();break;case"height":je(this.element,{height:Re(e.height)}),this.updatePersistData();break;case"width":je(this.element,{width:Re(e.width)}),this.updatePersistData();break;case"zIndex":this.popupObj.zIndex=this.zIndex,this.isModal&&this.setOverlayZindex(this.zIndex),this.element.style.zIndex!==this.zIndex.toString()&&(this.calculatezIndex=!1);break;case"cssClass":this.setCSSClass(i.cssClass);break;case"buttons":this.unWireButtonEvents(),this.destroyButtons(),m(this.ftrTemplateContent)||(he(this.ftrTemplateContent),this.ftrTemplateContent=null),this.footerTemplate="",this.setButton();break;case"allowDragging":this.allowDragging&&!m(this.headerContent)?this.setAllowDragging():this.dragObj.destroy();break;case"target":this.setTarget(e.target);break;case"position":if(this.checkPositionData(),this.isModal){var a=this.position.X,l=this.position.Y;m(i.position)||(m(i.position.X)||(a=i.position.X),m(i.position.Y)||(l=i.position.Y)),this.dlgContainer.classList.contains("e-dlg-"+a+"-"+l)&&this.dlgContainer.classList.remove("e-dlg-"+a+"-"+l)}this.positionChange(),this.updatePersistData();break;case"enableRtl":this.setEnableRTL();break;case"enableResize":this.setResize();break;case"minHeight":""!==this.minHeight&&(this.element.style.minHeight=Re(this.minHeight))}},t.prototype.setTarget=function(e){this.popupObj.relateTo=e,this.target=e,this.targetEle="string"==typeof this.target?document.querySelector(this.target):this.target,this.dragObj&&(this.dragObj.dragArea=this.targetEle),this.setMaxHeight(),this.isModal&&this.updateIsModal(),this.enableResize&&this.setResize()},t.prototype.updateIsModal=function(){if(this.element.setAttribute("aria-modal",this.isModal?"true":"false"),this.isModal)m(this.dlgOverlay)&&(this.setIsModal(),this.element.style.top="0px",this.element.style.left="0px",m(this.targetEle)||this.targetEle.appendChild(this.dlgContainer));else{for(K([this.element],X0),K([document.body],[yl,ka]),he(this.dlgOverlay);this.dlgContainer.firstChild;)this.dlgContainer.parentElement.insertBefore(this.dlgContainer.firstChild,this.dlgContainer);this.dlgContainer.parentElement.removeChild(this.dlgContainer)}this.visible&&this.show(),this.positionChange(),this.isModal&&this.dlgOverlay&&E.add(this.dlgOverlay,"click",this.dlgOverlayClickEventHandler,this)},t.prototype.setzIndex=function(e,i){var r=this.isProtectedOnChange;this.isProtectedOnChange=!0;var s=lc(e);this.zIndex=s>this.zIndex?s:this.zIndex,this.isProtectedOnChange=r,i&&(this.popupObj.zIndex=this.zIndex)},t.prototype.windowResizeHandler=function(){(function AJ(n){mh=n})(this.targetEle.clientWidth),function LJ(n){vh=n}(this.targetEle.clientHeight),this.setMaxHeight()},t.prototype.getPersistData=function(){return this.addOnPersist(["width","height","position"])},t.prototype.removeAllChildren=function(e){for(;e.children[0];)this.removeAllChildren(e.children[0]),e.removeChild(e.children[0])},t.prototype.destroy=function(){if(!this.isDestroyed){var e=[PE,X0,RE,dp,q0,E4],i=["role","aria-modal","aria-labelledby","aria-describedby","aria-grabbed","tabindex","style"];K([this.targetEle],[yl,ka]),!m(this.element)&&this.element.classList.contains(q0)&&K([document.body],[yl,ka]),this.isModal&&K([m(this.targetEle)?document.body:this.targetEle],ka),this.unWireEvents(),this.unWireButtonEvents(),this.destroyButtons(),m(this.closeIconBtnObj)||this.closeIconBtnObj.destroy(),m(this.dragObj)||this.dragObj.destroy(),!m(this.popupObj.element)&&this.popupObj.element.classList.contains("e-popup")&&this.popupObj.destroy(),K([this.element],e),!m(this.cssClass)&&""!==this.cssClass&&K([this.element],this.cssClass.split(" ")),!m(this.refElement)&&!m(this.refElement.parentElement)&&(this.refElement.parentElement.insertBefore(this.isModal?this.dlgContainer:this.element,this.refElement),he(this.refElement),this.refElement=void 0),this.isModal&&(he(this.dlgOverlay),this.dlgContainer.parentNode.insertBefore(this.element,this.dlgContainer),he(this.dlgContainer)),this.element.innerHTML=this.clonedEle.innerHTML;for(var r=0;r0&&""===this.footerTemplate&&this.ftrTemplateContent)for(var e=0;e=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},BE="e-tooltip",B4="e-icons",F4="e-tooltip-close",FE="e-tooltip-wrap",_4="e-tip-content",up="e-arrow-tip",U4="e-arrow-tip-outer",$0="e-arrow-tip-inner",qg="e-tip-bottom",_E="e-tip-top",j4="e-tip-left",UE="e-tip-right",jE="e-popup",$g="e-popup-open",VE="e-popup-close",Z0="e-lib",V4="e-tooltip-popup-container",JJ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return P4(t,n),Gi([I({effect:"FadeIn",duration:150,delay:0})],t.prototype,"open",void 0),Gi([I({effect:"FadeOut",duration:150,delay:0})],t.prototype,"close",void 0),t}(Ee),Sh=function(n){function t(e,i){var r=n.call(this,e,i)||this;return r.mouseMoveEvent=null,r.mouseMoveTarget=null,r.containerElement=null,r.isBodyContainer=!0,r}return P4(t,n),t.prototype.initialize=function(){this.formatPosition(),V([this.element],BE)},t.prototype.formatPosition=function(){var e,i;this.position&&(0===this.position.indexOf("Top")||0===this.position.indexOf("Bottom")?(e=this.position.split(/(?=[A-Z])/),this.tooltipPositionY=e[0],this.tooltipPositionX=e[1]):(i=this.position.split(/(?=[A-Z])/),this.tooltipPositionX=i[0],this.tooltipPositionY=i[1]))},t.prototype.renderArrow=function(){this.setTipClass(this.position);var e=this.createElement("div",{className:up+" "+this.tipClass});e.appendChild(this.createElement("div",{className:U4+" "+this.tipClass})),e.appendChild(this.createElement("div",{className:$0+" "+this.tipClass})),this.tooltipEle.appendChild(e)},t.prototype.setTipClass=function(e){this.tipClass=0===e.indexOf("Right")?j4:0===e.indexOf("Bottom")?_E:0===e.indexOf("Left")?UE:qg},t.prototype.renderPopup=function(e){var i=this.mouseTrail?{top:0,left:0}:this.getTooltipPosition(e);this.tooltipEle.classList.remove(Z0),this.popupObj=new ac(this.tooltipEle,{height:this.height,width:this.width,position:{X:i.left,Y:i.top},enableRtl:this.enableRtl,open:this.openPopupHandler.bind(this),close:this.closePopupHandler.bind(this)})},t.prototype.getScalingFactor=function(e){if(!e)return{x:1,y:1};var i={x:1,y:1},r=e.closest('[style*="transform: scale"]');if(r&&r!==this.tooltipEle&&r.contains(this.tooltipEle)){var a=window.getComputedStyle(r).getPropertyValue("transform").match(/matrix\(([^)]+)\)/)[1].split(",").map(parseFloat);i.x=a[0],i.y=a[3]}return i},t.prototype.getTooltipPosition=function(e){this.tooltipEle.style.display="block";var i=this.element.closest('[style*="zoom"]');i&&(i.contains(this.tooltipEle)||(this.tooltipEle.style.zoom=getComputedStyle(i).zoom));var r=is(e,this.tooltipPositionX,this.tooltipPositionY,!this.isBodyContainer,this.isBodyContainer?null:this.containerElement.getBoundingClientRect()),s=this.getScalingFactor(e),o=this.calculateTooltipOffset(this.position,s.x,s.y),a=this.calculateElementPosition(r,o),c=this.collisionFlipFit(e,a[0],a[1]);return c.left=c.left/s.x,c.top=c.top/s.y,this.tooltipEle.style.display="",c},t.prototype.windowResize=function(){this.reposition(this.findTarget())},t.prototype.reposition=function(e){if(this.popupObj&&e){var i=this.getTooltipPosition(e);this.popupObj.position={X:i.left,Y:i.top},this.popupObj.dataBind()}},t.prototype.openPopupHandler=function(){!this.mouseTrail&&this.needTemplateReposition()&&this.reposition(this.findTarget()),this.trigger("afterOpen",this.tooltipEventArgs),this.tooltipEventArgs=null},t.prototype.closePopupHandler=function(){this.isReact&&!("Click"===this.opensOn||"function"==typeof this.content)&&this.clearTemplate(["content"]),this.clear();var e={type:this.tooltipEventArgs.event?this.tooltipEventArgs.event.type:null,cancel:!1,target:this.tooltipEventArgs.target,event:this.tooltipEventArgs.event?this.tooltipEventArgs.event:null,element:this.tooltipEle,isInteracted:!m(this.tooltipEventArgs.event)};this.trigger("afterClose",e),e=null},t.prototype.calculateTooltipOffset=function(e,i,r){void 0===i&&(i=1),void 0===r&&(r=1);var o,a,l,h,c,d,u,p,s={top:0,left:0};if(1!==i||1!==r){var f=this.tooltipEle.getBoundingClientRect(),g=void 0;l=Math.round(f.width),h=Math.round(f.height),(c=U("."+up,this.tooltipEle))&&(g=c.getBoundingClientRect()),o=c?Math.round(g.width):0,a=c?Math.round(g.height):0,d=this.showTipPointer?0:8,u=a/2+2+(h-this.tooltipEle.clientHeight*r),p=o/2+2+(l-this.tooltipEle.clientWidth*i)}else l=this.tooltipEle.offsetWidth,h=this.tooltipEle.offsetHeight,c=U("."+up,this.tooltipEle),d=this.showTipPointer?0:8,u=(a=c?c.offsetHeight:0)/2+2+(this.tooltipEle.offsetHeight-this.tooltipEle.clientHeight),p=(o=c?c.offsetWidth:0)/2+2+(this.tooltipEle.offsetWidth-this.tooltipEle.clientWidth);switch(this.mouseTrail&&(d+=2),e){case"RightTop":s.left+=o+d,s.top-=h-u;break;case"RightCenter":s.left+=o+d,s.top-=h/2;break;case"RightBottom":s.left+=o+d,s.top-=u;break;case"BottomRight":s.top+=a+d,s.left-=p;break;case"BottomCenter":s.top+=a+d,s.left-=l/2;break;case"BottomLeft":s.top+=a+d,s.left-=l-p;break;case"LeftBottom":s.left-=o+l+d,s.top-=u;break;case"LeftCenter":s.left-=o+l+d,s.top-=h/2;break;case"LeftTop":s.left-=o+l+d,s.top-=h-u;break;case"TopLeft":s.top-=h+a+d,s.left-=l-p;break;case"TopRight":s.top-=h+a+d,s.left-=p;break;default:s.top-=h+a+d,s.left-=l/2}return s.left+=this.offsetX,s.top+=this.offsetY,s},t.prototype.updateTipPosition=function(e){var i=we("."+up+",."+U4+",."+$0,this.tooltipEle);K(i,[qg,_E,j4,UE]),this.setTipClass(e),V(i,this.tipClass)},t.prototype.adjustArrow=function(e,i,r,s){var o=U("."+up,this.tooltipEle);if(!1!==this.showTipPointer&&null!==o){var a,l;this.updateTipPosition(i),this.tooltipEle.style.display="block";var f,h=this.tooltipEle.clientWidth,c=this.tooltipEle.clientHeight,d=U("."+$0,this.tooltipEle),u=o.offsetWidth,p=o.offsetHeight;this.tooltipEle.style.display="",this.tipClass===qg||this.tipClass===_E?(this.tipClass===qg?(l="99.9%",d.style.top="-"+(p-2)+"px"):(l=-(p-1)+"px",d.style.top="-"+(p-6)+"px"),e&&(a=(f="Center"!==r||h>e.offsetWidth||this.mouseTrail)&&"Left"===r||!f&&"End"===this.tipPointerPosition?h-u-2+"px":f&&"Right"===r||!f&&"Start"===this.tipPointerPosition?"2px":!f||"End"!==this.tipPointerPosition&&"Start"!==this.tipPointerPosition?h/2-u/2+"px":"End"===this.tipPointerPosition?e.offsetWidth+(this.tooltipEle.offsetWidth-e.offsetWidth)/2-u/2-2+"px":(this.tooltipEle.offsetWidth-e.offsetWidth)/2-u/2+2+"px")):(this.tipClass===UE?(a="99.9%",d.style.left="-"+(u-2)+"px"):(a=-(u-1)+"px",d.style.left=u-2-u+"px"),l=(f="Center"!==s||c>e.offsetHeight||this.mouseTrail)&&"Top"===s||!f&&"End"===this.tipPointerPosition?c-p-2+"px":f&&"Bottom"===s||!f&&"Start"===this.tipPointerPosition?"2px":c/2-p/2+"px"),o.style.top=l,o.style.left=a}},t.prototype.renderContent=function(e){var i=this,r=U("."+_4,this.tooltipEle);if(this.cssClass&&V([this.tooltipEle],this.cssClass.split(" ")),e&&!m(e.getAttribute("title"))&&(e.setAttribute("data-content",e.getAttribute("title")),e.removeAttribute("title")),m(this.content))e&&!m(e.getAttribute("data-content"))&&(r.innerHTML=e.getAttribute("data-content"));else if(r.innerHTML="",this.content instanceof HTMLElement)r.appendChild(this.content);else if("string"==typeof this.content)this.isAngular?this.setProperties({content:Ti.sanitize(this.content)},!0):this.content=this.enableHtmlSanitizer?Ti.sanitize(this.content):this.content,this.enableHtmlParse?(o=ii(this.content)({},this,"content",this.element.id+"content",void 0,void 0,r,this.root))&&Dt(o,r):r.textContent=this.content;else{var o;(o=ii(this.content)({},this,"content",this.element.id+"content",void 0,void 0,r))&&(this.isAngular&&setTimeout(function(){i.reposition(e)},1),Dt(o,r)),this.renderReactTemplates()}},t.prototype.renderCloseIcon=function(){if(this.isSticky){var i=this.createElement("div",{className:B4+" "+F4});this.tooltipEle.appendChild(i),E.add(i,X.touchStartEvent,this.onStickyClose,this)}else{var e=this.tooltipEle.querySelector("."+B4+"."+F4);e&>(e)}},t.prototype.addDescribedBy=function(e,i){var r=(e.getAttribute("aria-describedby")||"").split(/\s+/);r.indexOf(i)<0&&r.push(i),Fe(e,{"aria-describedby":r.join(" ").trim(),"data-tooltip-id":i})},t.prototype.removeDescribedBy=function(e){var i=e.getAttribute("data-tooltip-id"),r=(e.getAttribute("aria-describedby")||"").split(/\s+/),s=r.indexOf(i);-1!==s&&r.splice(s,1),e.removeAttribute("data-tooltip-id");var o=r.join(" ").trim();o?e.setAttribute("aria-describedby",o):e.removeAttribute("aria-describedby")},t.prototype.tapHoldHandler=function(e){clearTimeout(this.autoCloseTimer),this.targetHover(e.originalEvent)},t.prototype.touchEndHandler=function(){var e=this;this.isSticky||(this.autoCloseTimer=setTimeout(function(){e.close()},1500))},t.prototype.targetClick=function(e){var i;!m(i=this.target?J(e.target,this.target):this.element)&&(null===i.getAttribute("data-tooltip-id")?this.targetHover(e):this.isSticky||this.hideTooltip(this.animation.close,e,i))},t.prototype.targetHover=function(e){var i;if(!(m(i=this.target?J(e.target,this.target):this.element)||null!==i.getAttribute("data-tooltip-id")&&0===this.closeDelay)){for(var s=0,o=[].slice.call(we('[data-tooltip-id= "'+this.ctrlId+'_content"]',document));s0?this.showTimer=setTimeout(function(){o.mouseTrail&&E.add(i,"mousemove touchstart mouseenter",o.onMouseMove,o),o.popupObj&&(o.popupObj.show(a,i),o.mouseMoveEvent&&o.mouseTrail&&o.onMouseMove(o.mouseMoveEvent))},this.openDelay):this.popupObj&&this.popupObj.show(a,i)}s&&this.wireMouseEvents(s,i)},t.prototype.needTemplateReposition=function(){return!m(this.viewContainerRef)&&"string"!=typeof this.viewContainerRef||this.isReact},t.prototype.checkCollision=function(e,i,r){var s={left:i,top:r,position:this.position,horizontal:this.tooltipPositionX,vertical:this.tooltipPositionY},o=oc(this.tooltipEle,this.checkCollideTarget(),i,r);return o.length>0&&(s.horizontal=o.indexOf("left")>=0?"Right":o.indexOf("right")>=0?"Left":this.tooltipPositionX,s.vertical=o.indexOf("top")>=0?"Bottom":o.indexOf("bottom")>=0?"Top":this.tooltipPositionY),s},t.prototype.calculateElementPosition=function(e,i){return[this.isBodyContainer?e.left+i.left:e.left-this.containerElement.getBoundingClientRect().left+i.left+window.pageXOffset+this.containerElement.scrollLeft,this.isBodyContainer?e.top+i.top:e.top-this.containerElement.getBoundingClientRect().top+i.top+window.pageYOffset+this.containerElement.scrollTop]},t.prototype.collisionFlipFit=function(e,i,r){var s=this.checkCollision(e,i,r),o=s.position;if(this.tooltipPositionY!==s.vertical&&(o=0===this.position.indexOf("Bottom")||0===this.position.indexOf("Top")?s.vertical+this.tooltipPositionX:this.tooltipPositionX+s.vertical),this.tooltipPositionX!==s.horizontal&&(0===o.indexOf("Left")&&(s.vertical="LeftTop"===o||"LeftCenter"===o?"Top":"Bottom",o=s.vertical+"Left"),0===o.indexOf("Right")&&(s.vertical="RightTop"===o||"RightCenter"===o?"Top":"Bottom",o=s.vertical+"Right"),s.horizontal=this.tooltipPositionX),this.tooltipEventArgs={type:null,cancel:!1,target:e,event:null,element:this.tooltipEle,collidedPosition:o},this.trigger("beforeCollision",this.tooltipEventArgs),this.tooltipEventArgs.cancel)o=this.position;else{var a=s.vertical,l=s.horizontal;if(s.position!==o){var h=is(e,l,a,!this.isBodyContainer,this.isBodyContainer?null:this.containerElement.getBoundingClientRect());this.adjustArrow(e,o,l,a);var c=this.getScalingFactor(e),d=this.calculateTooltipOffset(o,c.x,c.y);d.top-=this.getOffSetPosition("TopBottom",o,this.offsetY),d.left-=this.getOffSetPosition("RightLeft",o,this.offsetX),s.position=o;var u=this.calculateElementPosition(h,d);s.left=u[0],s.top=u[1]}else this.adjustArrow(e,o,l,a)}var p={left:s.left,top:s.top},f=this.isBodyContainer?uE(this.tooltipEle,this.checkCollideTarget(),{X:!0,Y:this.windowCollision},p):p;this.tooltipEle.style.display="block";var g=U("."+up,this.tooltipEle);if(this.showTipPointer&&null!=g&&(0===o.indexOf("Bottom")||0===o.indexOf("Top"))){var v=parseInt(g.style.left,10)-(f.left-s.left);v<0?v=0:v+g.offsetWidth>this.tooltipEle.clientWidth&&(v=this.tooltipEle.clientWidth-g.offsetWidth),g.style.left=v.toString()+"px"}return this.tooltipEle.style.display="",p.left=f.left,p.top=f.top,p},t.prototype.getOffSetPosition=function(e,i,r){return-1!==e.indexOf(this.position.split(/(?=[A-Z])/)[0])&&-1!==e.indexOf(i.split(/(?=[A-Z])/)[0])?2*r:0},t.prototype.checkCollideTarget=function(){return!this.windowCollision&&this.target?this.element:null},t.prototype.hideTooltip=function(e,i,r){var s=this;this.closeDelay>0?(clearTimeout(this.hideTimer),clearTimeout(this.showTimer),this.hideTimer=setTimeout(function(){s.closeDelay&&s.tooltipEle&&s.isTooltipOpen||s.tooltipHide(e,i,r)},this.closeDelay)):this.tooltipHide(e,i,r)},t.prototype.tooltipHide=function(e,i,r){var o,s=this;o=i?this.target?r||i.target:this.element:U('[data-tooltip-id= "'+this.ctrlId+'_content"]',document),this.tooltipEventArgs={type:i?i.type:null,cancel:!1,target:o,event:i||null,element:this.tooltipEle,isInteracted:!m(i)},this.trigger("beforeClose",this.tooltipEventArgs,function(a){a.cancel?s.isHidden=!1:(s.mouseMoveBeforeRemove(),s.popupHide(e,o,i))})},t.prototype.popupHide=function(e,i,r){i&&r&&this.restoreElement(i),this.isHidden=!0;var s={name:this.animation.close.effect,duration:e.duration,delay:e.delay,timingFunction:"easeIn"};"None"===e.effect&&(s=void 0),this.popupObj&&this.popupObj.hide(s)},t.prototype.restoreElement=function(e){this.unwireMouseEvents(e),m(e.getAttribute("data-content"))||(e.setAttribute("title",e.getAttribute("data-content")),e.removeAttribute("data-content")),this.removeDescribedBy(e)},t.prototype.clear=function(){var e=this.findTarget();e&&this.restoreElement(e),this.tooltipEle&&(K([this.tooltipEle],VE),V([this.tooltipEle],$g)),this.isHidden&&(this.popupObj&&this.popupObj.destroy(),this.tooltipEle&>(this.tooltipEle),this.tooltipEle=null,this.popupObj=null)},t.prototype.tooltipHover=function(){this.tooltipEle&&(this.isTooltipOpen=!0)},t.prototype.tooltipMouseOut=function(e){this.isTooltipOpen=!1,this.hideTooltip(this.animation.close,e,this.findTarget())},t.prototype.onMouseOut=function(e){var i=e.relatedTarget;if(i&&!this.mouseTrail){var r=J(i,"."+FE+"."+Z0+"."+jE);r?E.add(r,"mouseleave",this.tooltipElementMouseOut,this):(this.hideTooltip(this.animation.close,e,this.findTarget()),0===this.closeDelay&&("None"===this.animation.close.effect||this.isReact&&"string"!=typeof this.content)&&this.clear())}else this.hideTooltip(this.animation.close,e,this.findTarget()),this.clear();this.popupObj&&!this.popupObj.element.classList.contains($g)&&this.clear()},t.prototype.tooltipElementMouseOut=function(e){this.hideTooltip(this.animation.close,e,this.findTarget()),E.remove(this.element,"mouseleave",this.tooltipElementMouseOut),this.clear()},t.prototype.onStickyClose=function(){this.close()},t.prototype.onMouseMove=function(e){var i=0,r=0;e.type.indexOf("touch")>-1?(e.preventDefault(),i=e.touches[0].pageX,r=e.touches[0].pageY):(i=e.pageX,r=e.pageY),Hs.stop(this.tooltipEle),K([this.tooltipEle],VE),V([this.tooltipEle],$g),this.adjustArrow(e.target,this.position,this.tooltipPositionX,this.tooltipPositionY);var s=this.getScalingFactor(e.target),o=this.calculateTooltipOffset(this.position,s.x,s.y),h=this.checkCollision(e.target,i+o.left+this.offsetX,r+o.top+this.offsetY);if(this.tooltipPositionX!==h.horizontal||this.tooltipPositionY!==h.vertical){var c=0===this.position.indexOf("Bottom")||0===this.position.indexOf("Top")?h.vertical+h.horizontal:h.horizontal+h.vertical;h.position=c,this.adjustArrow(e.target,h.position,h.horizontal,h.vertical);var d=this.calculateTooltipOffset(h.position,s.x,s.y);h.left=i+d.left-this.offsetX,h.top=r+d.top-this.offsetY}this.tooltipEle.style.left=h.left+"px",this.tooltipEle.style.top=h.top+"px"},t.prototype.keyDown=function(e){this.tooltipEle&&27===e.keyCode&&this.close()},t.prototype.touchEnd=function(e){this.tooltipEle&&null===J(e.target,"."+BE)&&!this.isSticky&&this.close()},t.prototype.scrollHandler=function(e){this.tooltipEle&&!this.isSticky&&!J(e.target,"."+FE+"."+Z0+"."+jE)&&!this.isSticky&&this.close()},t.prototype.render=function(){this.initialize(),this.wireEvents(this.opensOn),this.renderComplete()},t.prototype.preRender=function(){this.tipClass=qg,this.tooltipPositionX="Center",this.tooltipPositionY="Top",this.isHidden=!0},t.prototype.wireEvents=function(e){for(var r=0,s=this.getTriggerList(e);r0)for(var i=0,r=e;i0)for(var i=0,r=e;i0&&this.condition&&-1!==this.condition.indexOf("not")&&(e[s].condition=e[s].condition?e[s].condition+"not":"not"),i=e[s].validate(t),r){if(!i)return!1}else if(i)return!0;return r},n.prototype.toJson=function(){var t,e;if(this.isComplex){t=[],e=this.predicates;for(var i=0;ie.length-3?(e=e.substring(0,e.length-1),n.endsWith(n.toLowerCase(t),n.toLowerCase(e))):(e.lastIndexOf("%")!==e.indexOf("%")&&e.lastIndexOf("%")>e.indexOf("%")+1&&(e=e.substring(e.indexOf("%")+1,e.lastIndexOf("%"))),-1!==t.indexOf(e)))},n.fnSort=function(t){return"ascending"===(t=t?n.toLowerCase(t):"ascending")?this.fnAscending:this.fnDescending},n.fnAscending=function(t,e){return m(t)&&m(e)||null==e?-1:"string"==typeof t?t.localeCompare(e):null==t?1:t-e},n.fnDescending=function(t,e){return m(t)&&m(e)?-1:null==e?1:"string"==typeof t?-1*t.localeCompare(e):null==t?-1:e-t},n.extractFields=function(t,e){for(var i={},r=0;r0||e.length>0;)o=t.length>0&&e.length>0?r?r(this.getVal(t,0,i),this.getVal(e,0,i),t[0],e[0])<=0?t:e:t[0][i]0?t:e,s.push(o.shift());return s},n.getVal=function(t,e,i){return i?this.getObject(i,t[e]):t[e]},n.toLowerCase=function(t){return t?"string"==typeof t?t.toLowerCase():t.toString():0===t||!1===t?t.toString():""},n.callAdaptorFunction=function(t,e,i,r){if(e in t){var s=t[e](i,r);m(s)||(i=s)}return i},n.getAddParams=function(t,e,i){var r={};return n.callAdaptorFunction(t,"addParams",{dm:e,query:i,params:i?i.params:[],reqParams:r}),r},n.isPlainObject=function(t){return!!t&&t.constructor===Object},n.isCors=function(){var t=null;try{t=new window.XMLHttpRequest}catch{}return!!t&&"withCredentials"in t},n.getGuid=function(t){var i;return(t||"")+"00000000-0000-4000-0000-000000000000".replace(/0/g,function(r,s){if("crypto"in window&&"getRandomValues"in crypto){var o=new Uint8Array(1);window.crypto.getRandomValues(o),i=o[0]%16|0}else i=16*Math.random()|0;return"0123456789abcdef"[19===s?3&i|8:i]})},n.isNull=function(t){return null==t},n.getItemFromComparer=function(t,e,i){var r,s,o,a=0,l="string"==typeof n.getVal(t,0,e);if(t.length)for(;m(r)&&a0&&(r=s,o=t[a]));return o},n.distinct=function(t,e,i){i=!m(i)&&i;var s,r=[],o={};return t.forEach(function(a,l){(s="object"==typeof t[l]?n.getVal(t,l,e):t[l])in o||(r.push(i?t[l]:s),o[s]=1)}),r},n.processData=function(t,e){var i=this.prepareQuery(t),r=new nt(e);t.requiresCounts&&i.requiresCount();var s=r.executeLocal(i),o={result:t.requiresCounts?s.result:s,count:s.count,aggregates:JSON.stringify(s.aggregates)};return t.requiresCounts?o:s},n.prepareQuery=function(t){var e=this,i=new jt;return t.select&&i.select(t.select),t.where&&n.parse.parseJson(t.where).filter(function(o){if(m(o.condition))i.where(o.field,o.operator,o.value,o.ignoreCase,o.ignoreAccent);else{var a=[];o.field?a.push(new Ss(o.field,o.operator,o.value,o.ignoreCase,o.ignoreAccent)):a=a.concat(e.getPredicate(o.predicates)),"or"===o.condition?i.where(Ss.or(a)):"and"===o.condition&&i.where(Ss.and(a))}}),t.search&&n.parse.parseJson(t.search).filter(function(o){return i.search(o.key,o.fields,o.operator,o.ignoreCase,o.ignoreAccent)}),t.aggregates&&t.aggregates.filter(function(o){return i.aggregate(o.type,o.field)}),t.sorted&&t.sorted.filter(function(o){return i.sortBy(o.name,o.direction)}),t.skip&&i.skip(t.skip),t.take&&i.take(t.take),t.group&&t.group.filter(function(o){return i.group(o)}),i},n.getPredicate=function(t){for(var e=[],i=0;i":"greaterthan","<=":"lessthanorequal",">=":"greaterthanorequal","==":"equal","!=":"notequal","*=":"contains","$=":"endswith","^=":"startswith"},n.odBiOperator={"<":" lt ",">":" gt ","<=":" le ",">=":" ge ","==":" eq ","!=":" ne ",lessthan:" lt ",lessthanorequal:" le ",greaterthan:" gt ",greaterthanorequal:" ge ",equal:" eq ",notequal:" ne "},n.odUniOperator={"$=":"endswith","^=":"startswith","*=":"substringof",endswith:"endswith",startswith:"startswith",contains:"substringof",doesnotendwith:"not endswith",doesnotstartwith:"not startswith",doesnotcontain:"not substringof",wildcard:"wildcard",like:"like"},n.odv4UniOperator={"$=":"endswith","^=":"startswith","*=":"contains",endswith:"endswith",startswith:"startswith",contains:"contains",doesnotendwith:"not endswith",doesnotstartwith:"not startswith",doesnotcontain:"not contains",wildcard:"wildcard",like:"like"},n.diacritics={"\u24b6":"A",\uff21:"A",\u00c0:"A",\u00c1:"A",\u00c2:"A",\u1ea6:"A",\u1ea4:"A",\u1eaa:"A",\u1ea8:"A",\u00c3:"A",\u0100:"A",\u0102:"A",\u1eb0:"A",\u1eae:"A",\u1eb4:"A",\u1eb2:"A",\u0226:"A",\u01e0:"A",\u00c4:"A",\u01de:"A",\u1ea2:"A",\u00c5:"A",\u01fa:"A",\u01cd:"A",\u0200:"A",\u0202:"A",\u1ea0:"A",\u1eac:"A",\u1eb6:"A",\u1e00:"A",\u0104:"A",\u023a:"A",\u2c6f:"A",\ua732:"AA",\u00c6:"AE",\u01fc:"AE",\u01e2:"AE",\ua734:"AO",\ua736:"AU",\ua738:"AV",\ua73a:"AV",\ua73c:"AY","\u24b7":"B",\uff22:"B",\u1e02:"B",\u1e04:"B",\u1e06:"B",\u0243:"B",\u0182:"B",\u0181:"B","\u24b8":"C",\uff23:"C",\u0106:"C",\u0108:"C",\u010a:"C",\u010c:"C",\u00c7:"C",\u1e08:"C",\u0187:"C",\u023b:"C",\ua73e:"C","\u24b9":"D",\uff24:"D",\u1e0a:"D",\u010e:"D",\u1e0c:"D",\u1e10:"D",\u1e12:"D",\u1e0e:"D",\u0110:"D",\u018b:"D",\u018a:"D",\u0189:"D",\ua779:"D",\u01f1:"DZ",\u01c4:"DZ",\u01f2:"Dz",\u01c5:"Dz","\u24ba":"E",\uff25:"E",\u00c8:"E",\u00c9:"E",\u00ca:"E",\u1ec0:"E",\u1ebe:"E",\u1ec4:"E",\u1ec2:"E",\u1ebc:"E",\u0112:"E",\u1e14:"E",\u1e16:"E",\u0114:"E",\u0116:"E",\u00cb:"E",\u1eba:"E",\u011a:"E",\u0204:"E",\u0206:"E",\u1eb8:"E",\u1ec6:"E",\u0228:"E",\u1e1c:"E",\u0118:"E",\u1e18:"E",\u1e1a:"E",\u0190:"E",\u018e:"E","\u24bb":"F",\uff26:"F",\u1e1e:"F",\u0191:"F",\ua77b:"F","\u24bc":"G",\uff27:"G",\u01f4:"G",\u011c:"G",\u1e20:"G",\u011e:"G",\u0120:"G",\u01e6:"G",\u0122:"G",\u01e4:"G",\u0193:"G",\ua7a0:"G",\ua77d:"G",\ua77e:"G","\u24bd":"H",\uff28:"H",\u0124:"H",\u1e22:"H",\u1e26:"H",\u021e:"H",\u1e24:"H",\u1e28:"H",\u1e2a:"H",\u0126:"H",\u2c67:"H",\u2c75:"H",\ua78d:"H","\u24be":"I",\uff29:"I",\u00cc:"I",\u00cd:"I",\u00ce:"I",\u0128:"I",\u012a:"I",\u012c:"I",\u0130:"I",\u00cf:"I",\u1e2e:"I",\u1ec8:"I",\u01cf:"I",\u0208:"I",\u020a:"I",\u1eca:"I",\u012e:"I",\u1e2c:"I",\u0197:"I","\u24bf":"J",\uff2a:"J",\u0134:"J",\u0248:"J","\u24c0":"K",\uff2b:"K",\u1e30:"K",\u01e8:"K",\u1e32:"K",\u0136:"K",\u1e34:"K",\u0198:"K",\u2c69:"K",\ua740:"K",\ua742:"K",\ua744:"K",\ua7a2:"K","\u24c1":"L",\uff2c:"L",\u013f:"L",\u0139:"L",\u013d:"L",\u1e36:"L",\u1e38:"L",\u013b:"L",\u1e3c:"L",\u1e3a:"L",\u0141:"L",\u023d:"L",\u2c62:"L",\u2c60:"L",\ua748:"L",\ua746:"L",\ua780:"L",\u01c7:"LJ",\u01c8:"Lj","\u24c2":"M",\uff2d:"M",\u1e3e:"M",\u1e40:"M",\u1e42:"M",\u2c6e:"M",\u019c:"M","\u24c3":"N",\uff2e:"N",\u01f8:"N",\u0143:"N",\u00d1:"N",\u1e44:"N",\u0147:"N",\u1e46:"N",\u0145:"N",\u1e4a:"N",\u1e48:"N",\u0220:"N",\u019d:"N",\ua790:"N",\ua7a4:"N",\u01ca:"NJ",\u01cb:"Nj","\u24c4":"O",\uff2f:"O",\u00d2:"O",\u00d3:"O",\u00d4:"O",\u1ed2:"O",\u1ed0:"O",\u1ed6:"O",\u1ed4:"O",\u00d5:"O",\u1e4c:"O",\u022c:"O",\u1e4e:"O",\u014c:"O",\u1e50:"O",\u1e52:"O",\u014e:"O",\u022e:"O",\u0230:"O",\u00d6:"O",\u022a:"O",\u1ece:"O",\u0150:"O",\u01d1:"O",\u020c:"O",\u020e:"O",\u01a0:"O",\u1edc:"O",\u1eda:"O",\u1ee0:"O",\u1ede:"O",\u1ee2:"O",\u1ecc:"O",\u1ed8:"O",\u01ea:"O",\u01ec:"O",\u00d8:"O",\u01fe:"O",\u0186:"O",\u019f:"O",\ua74a:"O",\ua74c:"O",\u01a2:"OI",\ua74e:"OO",\u0222:"OU","\u24c5":"P",\uff30:"P",\u1e54:"P",\u1e56:"P",\u01a4:"P",\u2c63:"P",\ua750:"P",\ua752:"P",\ua754:"P","\u24c6":"Q",\uff31:"Q",\ua756:"Q",\ua758:"Q",\u024a:"Q","\u24c7":"R",\uff32:"R",\u0154:"R",\u1e58:"R",\u0158:"R",\u0210:"R",\u0212:"R",\u1e5a:"R",\u1e5c:"R",\u0156:"R",\u1e5e:"R",\u024c:"R",\u2c64:"R",\ua75a:"R",\ua7a6:"R",\ua782:"R","\u24c8":"S",\uff33:"S",\u1e9e:"S",\u015a:"S",\u1e64:"S",\u015c:"S",\u1e60:"S",\u0160:"S",\u1e66:"S",\u1e62:"S",\u1e68:"S",\u0218:"S",\u015e:"S",\u2c7e:"S",\ua7a8:"S",\ua784:"S","\u24c9":"T",\uff34:"T",\u1e6a:"T",\u0164:"T",\u1e6c:"T",\u021a:"T",\u0162:"T",\u1e70:"T",\u1e6e:"T",\u0166:"T",\u01ac:"T",\u01ae:"T",\u023e:"T",\ua786:"T",\ua728:"TZ","\u24ca":"U",\uff35:"U",\u00d9:"U",\u00da:"U",\u00db:"U",\u0168:"U",\u1e78:"U",\u016a:"U",\u1e7a:"U",\u016c:"U",\u00dc:"U",\u01db:"U",\u01d7:"U",\u01d5:"U",\u01d9:"U",\u1ee6:"U",\u016e:"U",\u0170:"U",\u01d3:"U",\u0214:"U",\u0216:"U",\u01af:"U",\u1eea:"U",\u1ee8:"U",\u1eee:"U",\u1eec:"U",\u1ef0:"U",\u1ee4:"U",\u1e72:"U",\u0172:"U",\u1e76:"U",\u1e74:"U",\u0244:"U","\u24cb":"V",\uff36:"V",\u1e7c:"V",\u1e7e:"V",\u01b2:"V",\ua75e:"V",\u0245:"V",\ua760:"VY","\u24cc":"W",\uff37:"W",\u1e80:"W",\u1e82:"W",\u0174:"W",\u1e86:"W",\u1e84:"W",\u1e88:"W",\u2c72:"W","\u24cd":"X",\uff38:"X",\u1e8a:"X",\u1e8c:"X","\u24ce":"Y",\uff39:"Y",\u1ef2:"Y",\u00dd:"Y",\u0176:"Y",\u1ef8:"Y",\u0232:"Y",\u1e8e:"Y",\u0178:"Y",\u1ef6:"Y",\u1ef4:"Y",\u01b3:"Y",\u024e:"Y",\u1efe:"Y","\u24cf":"Z",\uff3a:"Z",\u0179:"Z",\u1e90:"Z",\u017b:"Z",\u017d:"Z",\u1e92:"Z",\u1e94:"Z",\u01b5:"Z",\u0224:"Z",\u2c7f:"Z",\u2c6b:"Z",\ua762:"Z","\u24d0":"a",\uff41:"a",\u1e9a:"a",\u00e0:"a",\u00e1:"a",\u00e2:"a",\u1ea7:"a",\u1ea5:"a",\u1eab:"a",\u1ea9:"a",\u00e3:"a",\u0101:"a",\u0103:"a",\u1eb1:"a",\u1eaf:"a",\u1eb5:"a",\u1eb3:"a",\u0227:"a",\u01e1:"a",\u00e4:"a",\u01df:"a",\u1ea3:"a",\u00e5:"a",\u01fb:"a",\u01ce:"a",\u0201:"a",\u0203:"a",\u1ea1:"a",\u1ead:"a",\u1eb7:"a",\u1e01:"a",\u0105:"a",\u2c65:"a",\u0250:"a",\ua733:"aa",\u00e6:"ae",\u01fd:"ae",\u01e3:"ae",\ua735:"ao",\ua737:"au",\ua739:"av",\ua73b:"av",\ua73d:"ay","\u24d1":"b",\uff42:"b",\u1e03:"b",\u1e05:"b",\u1e07:"b",\u0180:"b",\u0183:"b",\u0253:"b","\u24d2":"c",\uff43:"c",\u0107:"c",\u0109:"c",\u010b:"c",\u010d:"c",\u00e7:"c",\u1e09:"c",\u0188:"c",\u023c:"c",\ua73f:"c",\u2184:"c","\u24d3":"d",\uff44:"d",\u1e0b:"d",\u010f:"d",\u1e0d:"d",\u1e11:"d",\u1e13:"d",\u1e0f:"d",\u0111:"d",\u018c:"d",\u0256:"d",\u0257:"d",\ua77a:"d",\u01f3:"dz",\u01c6:"dz","\u24d4":"e",\uff45:"e",\u00e8:"e",\u00e9:"e",\u00ea:"e",\u1ec1:"e",\u1ebf:"e",\u1ec5:"e",\u1ec3:"e",\u1ebd:"e",\u0113:"e",\u1e15:"e",\u1e17:"e",\u0115:"e",\u0117:"e",\u00eb:"e",\u1ebb:"e",\u011b:"e",\u0205:"e",\u0207:"e",\u1eb9:"e",\u1ec7:"e",\u0229:"e",\u1e1d:"e",\u0119:"e",\u1e19:"e",\u1e1b:"e",\u0247:"e",\u025b:"e",\u01dd:"e","\u24d5":"f",\uff46:"f",\u1e1f:"f",\u0192:"f",\ua77c:"f","\u24d6":"g",\uff47:"g",\u01f5:"g",\u011d:"g",\u1e21:"g",\u011f:"g",\u0121:"g",\u01e7:"g",\u0123:"g",\u01e5:"g",\u0260:"g",\ua7a1:"g",\u1d79:"g",\ua77f:"g","\u24d7":"h",\uff48:"h",\u0125:"h",\u1e23:"h",\u1e27:"h",\u021f:"h",\u1e25:"h",\u1e29:"h",\u1e2b:"h",\u1e96:"h",\u0127:"h",\u2c68:"h",\u2c76:"h",\u0265:"h",\u0195:"hv","\u24d8":"i",\uff49:"i",\u00ec:"i",\u00ed:"i",\u00ee:"i",\u0129:"i",\u012b:"i",\u012d:"i",\u00ef:"i",\u1e2f:"i",\u1ec9:"i",\u01d0:"i",\u0209:"i",\u020b:"i",\u1ecb:"i",\u012f:"i",\u1e2d:"i",\u0268:"i",\u0131:"i","\u24d9":"j",\uff4a:"j",\u0135:"j",\u01f0:"j",\u0249:"j","\u24da":"k",\uff4b:"k",\u1e31:"k",\u01e9:"k",\u1e33:"k",\u0137:"k",\u1e35:"k",\u0199:"k",\u2c6a:"k",\ua741:"k",\ua743:"k",\ua745:"k",\ua7a3:"k","\u24db":"l",\uff4c:"l",\u0140:"l",\u013a:"l",\u013e:"l",\u1e37:"l",\u1e39:"l",\u013c:"l",\u1e3d:"l",\u1e3b:"l",\u017f:"l",\u0142:"l",\u019a:"l",\u026b:"l",\u2c61:"l",\ua749:"l",\ua781:"l",\ua747:"l",\u01c9:"lj","\u24dc":"m",\uff4d:"m",\u1e3f:"m",\u1e41:"m",\u1e43:"m",\u0271:"m",\u026f:"m","\u24dd":"n",\uff4e:"n",\u01f9:"n",\u0144:"n",\u00f1:"n",\u1e45:"n",\u0148:"n",\u1e47:"n",\u0146:"n",\u1e4b:"n",\u1e49:"n",\u019e:"n",\u0272:"n",\u0149:"n",\ua791:"n",\ua7a5:"n",\u01cc:"nj","\u24de":"o",\uff4f:"o",\u00f2:"o",\u00f3:"o",\u00f4:"o",\u1ed3:"o",\u1ed1:"o",\u1ed7:"o",\u1ed5:"o",\u00f5:"o",\u1e4d:"o",\u022d:"o",\u1e4f:"o",\u014d:"o",\u1e51:"o",\u1e53:"o",\u014f:"o",\u022f:"o",\u0231:"o",\u00f6:"o",\u022b:"o",\u1ecf:"o",\u0151:"o",\u01d2:"o",\u020d:"o",\u020f:"o",\u01a1:"o",\u1edd:"o",\u1edb:"o",\u1ee1:"o",\u1edf:"o",\u1ee3:"o",\u1ecd:"o",\u1ed9:"o",\u01eb:"o",\u01ed:"o",\u00f8:"o",\u01ff:"o",\u0254:"o",\ua74b:"o",\ua74d:"o",\u0275:"o",\u01a3:"oi",\u0223:"ou",\ua74f:"oo","\u24df":"p",\uff50:"p",\u1e55:"p",\u1e57:"p",\u01a5:"p",\u1d7d:"p",\ua751:"p",\ua753:"p",\ua755:"p","\u24e0":"q",\uff51:"q",\u024b:"q",\ua757:"q",\ua759:"q","\u24e1":"r",\uff52:"r",\u0155:"r",\u1e59:"r",\u0159:"r",\u0211:"r",\u0213:"r",\u1e5b:"r",\u1e5d:"r",\u0157:"r",\u1e5f:"r",\u024d:"r",\u027d:"r",\ua75b:"r",\ua7a7:"r",\ua783:"r","\u24e2":"s",\uff53:"s",\u00df:"s",\u015b:"s",\u1e65:"s",\u015d:"s",\u1e61:"s",\u0161:"s",\u1e67:"s",\u1e63:"s",\u1e69:"s",\u0219:"s",\u015f:"s",\u023f:"s",\ua7a9:"s",\ua785:"s",\u1e9b:"s","\u24e3":"t",\uff54:"t",\u1e6b:"t",\u1e97:"t",\u0165:"t",\u1e6d:"t",\u021b:"t",\u0163:"t",\u1e71:"t",\u1e6f:"t",\u0167:"t",\u01ad:"t",\u0288:"t",\u2c66:"t",\ua787:"t",\ua729:"tz","\u24e4":"u",\uff55:"u",\u00f9:"u",\u00fa:"u",\u00fb:"u",\u0169:"u",\u1e79:"u",\u016b:"u",\u1e7b:"u",\u016d:"u",\u00fc:"u",\u01dc:"u",\u01d8:"u",\u01d6:"u",\u01da:"u",\u1ee7:"u",\u016f:"u",\u0171:"u",\u01d4:"u",\u0215:"u",\u0217:"u",\u01b0:"u",\u1eeb:"u",\u1ee9:"u",\u1eef:"u",\u1eed:"u",\u1ef1:"u",\u1ee5:"u",\u1e73:"u",\u0173:"u",\u1e77:"u",\u1e75:"u",\u0289:"u","\u24e5":"v",\uff56:"v",\u1e7d:"v",\u1e7f:"v",\u028b:"v",\ua75f:"v",\u028c:"v",\ua761:"vy","\u24e6":"w",\uff57:"w",\u1e81:"w",\u1e83:"w",\u0175:"w",\u1e87:"w",\u1e85:"w",\u1e98:"w",\u1e89:"w",\u2c73:"w","\u24e7":"x",\uff58:"x",\u1e8b:"x",\u1e8d:"x","\u24e8":"y",\uff59:"y",\u1ef3:"y",\u00fd:"y",\u0177:"y",\u1ef9:"y",\u0233:"y",\u1e8f:"y",\u00ff:"y",\u1ef7:"y",\u1e99:"y",\u1ef5:"y",\u01b4:"y",\u024f:"y",\u1eff:"y","\u24e9":"z",\uff5a:"z",\u017a:"z",\u1e91:"z",\u017c:"z",\u017e:"z",\u1e93:"z",\u1e95:"z",\u01b6:"z",\u0225:"z",\u0240:"z",\u2c6c:"z",\ua763:"z",\u0386:"\u0391",\u0388:"\u0395",\u0389:"\u0397",\u038a:"\u0399",\u03aa:"\u0399",\u038c:"\u039f",\u038e:"\u03a5",\u03ab:"\u03a5",\u038f:"\u03a9",\u03ac:"\u03b1",\u03ad:"\u03b5",\u03ae:"\u03b7",\u03af:"\u03b9",\u03ca:"\u03b9",\u0390:"\u03b9",\u03cc:"\u03bf",\u03cd:"\u03c5",\u03cb:"\u03c5",\u03b0:"\u03c5",\u03c9:"\u03c9",\u03c2:"\u03c3"},n.fnOperators={equal:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?n.toLowerCase(t)===n.toLowerCase(e):t===e},notequal:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),!n.fnOperators.equal(t,e,i)},lessthan:function(t,e,i){return i?n.toLowerCase(t)n.toLowerCase(e):t>e},lessthanorequal:function(t,e,i){return i?n.toLowerCase(t)<=n.toLowerCase(e):(m(t)&&(t=void 0),t<=e)},greaterthanorequal:function(t,e,i){return i?n.toLowerCase(t)>=n.toLowerCase(e):t>=e},contains:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?!m(t)&&!m(e)&&-1!==n.toLowerCase(t).indexOf(n.toLowerCase(e)):!m(t)&&!m(e)&&-1!==t.toString().indexOf(e)},doesnotcontain:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?!m(t)&&!m(e)&&-1===n.toLowerCase(t).indexOf(n.toLowerCase(e)):!m(t)&&!m(e)&&-1===t.toString().indexOf(e)},isnotnull:function(t){return null!=t},isnull:function(t){return null==t},startswith:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.startsWith(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.startsWith(t,e)},doesnotstartwith:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.notStartsWith(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.notStartsWith(t,e)},like:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.like(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.like(t,e)},isempty:function(t){return void 0===t||""===t},isnotempty:function(t){return void 0!==t&&""!==t},wildcard:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?(t||"boolean"==typeof t)&&e&&"object"!=typeof t&&n.wildCard(n.toLowerCase(t),n.toLowerCase(e)):(t||"boolean"==typeof t)&&e&&n.wildCard(t,e)},endswith:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.endsWith(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.endsWith(t,e)},doesnotendwith:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.notEndsWith(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.notEndsWith(t,e)},processSymbols:function(t){var e=n.operatorSymbols[t];return e?n.fnOperators[e]:n.throwError("Query - Process Operator : Invalid operator")},processOperator:function(t){return n.fnOperators[t]||n.fnOperators.processSymbols(t)}},n.parse={parseJson:function(t){return"string"!=typeof t||!/^[\s]*\[|^[\s]*\{(.)+:/g.test(t)&&-1!==t.indexOf('"')?t instanceof Array?n.parse.iterateAndReviveArray(t):"object"==typeof t&&null!==t&&n.parse.iterateAndReviveJson(t):t=JSON.parse(t,n.parse.jsonReviver),t},iterateAndReviveArray:function(t){for(var e=0;e-1||e.indexOf("z")>-1,o=e.split(/[^0-9.]/);if(s){if(o[5].indexOf(".")>-1){var a=o[5].split(".");o[5]=a[0],o[6]=new Date(e).getUTCMilliseconds().toString()}else o[6]="00";e=n.dateParse.toTimeZone(new Date(parseInt(o[0],10),parseInt(o[1],10)-1,parseInt(o[2],10),parseInt(o[3],10),parseInt(o[4],10),parseInt(o[5]?o[5]:"00",10),parseInt(o[6],10)),n.serverTimezoneOffset,!1)}else{var l=new Date(parseInt(o[0],10),parseInt(o[1],10)-1,parseInt(o[2],10),parseInt(o[3],10),parseInt(o[4],10),parseInt(o[5]?o[5]:"00",10)),h=parseInt(o[6],10),c=parseInt(o[7],10);if(isNaN(h)&&isNaN(c))return l;e.indexOf("+")>-1?l.setHours(l.getHours()-h,l.getMinutes()-c):l.setHours(l.getHours()+h,l.getMinutes()+c),e=n.dateParse.toTimeZone(l,n.serverTimezoneOffset,!1)}null==n.serverTimezoneOffset&&(e=n.dateParse.addSelfOffset(e))}}return e},isJson:function(t){return"string"==typeof t[0]?t:n.parse.parseJson(t)},isGuid:function(t){return null!=/[A-Fa-f0-9]{8}(?:-[A-Fa-f0-9]{4}){3}-[A-Fa-f0-9]{12}/i.exec(t)},replacer:function(t,e){return n.isPlainObject(t)?n.parse.jsonReplacer(t,e):t instanceof Array?n.parse.arrayReplacer(t):t instanceof Date?n.parse.jsonReplacer({val:t},e).val:t},jsonReplacer:function(t,e){for(var i,s=0,o=Object.keys(t);s=0?"+":"-",s=function(a){var l=Math.floor(Math.abs(a));return(l<10?"0":"")+l};return e.getFullYear()+"-"+s(e.getMonth()+1)+"-"+s(e.getDate())+"T"+s(e.getHours())+":"+s(e.getMinutes())+":"+s(e.getSeconds())+r+s(i/60)+":"+s(i%60)}},n}(),Ml=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),BK={GroupGuid:"{271bbba0-1ee7}"},a5=function(){function n(t){this.options={from:"table",requestType:"json",sortBy:"sorted",select:"select",skip:"skip",group:"group",take:"take",search:"search",count:"requiresCounts",where:"where",aggregates:"aggregates",expand:"expand"},this.type=n,this.dataSource=t,this.pvt={}}return n.prototype.processResponse=function(t,e,i,r){return t},n}(),QE=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ml(t,n),t.prototype.processQuery=function(e,i){for(var a,l,p,r=e.dataSource.json.slice(0),s=r.length,o=!0,h={},c=0,d=[],u=[],f=0;f1?e.sort.filter(function(p){return p.fieldName===c})[0]:e.sort[0];s=this.onSortBy(s,d,e.query,!0)}e.page&&(s=this.onPage(s,e.page,e.query)),this.formGroupResult(s,h)}else{for(var o=e.lazyLoad.onDemandGroupInfo,a=o.where.length-1;a>=0;a--)s=this.onWhere(s,o.where[a]);if(e.group.length!==o.level)s=le.group(s,e.group[o.level].fieldName,r,null,null,e.group[o.level].comparer,!0),e.sort.length&&(s=this.onSortBy(s,e.sort[parseInt(o.level.toString(),10)],e.query,!0));else for(a=e.sort.length-1;a>=o.level;a--)s=this.onSortBy(s,e.sort[parseInt(a.toString(),10)],e.query,!1);i=s.length,h=s,s=(s=s.slice(o.skip)).slice(0,o.take),e.group.length!==o.level&&this.formGroupResult(s,h)}return{result:s,count:i}},t.prototype.formGroupResult=function(e,i){if(e.length&&i.length){var r="GroupGuid",s="childLevels",o="level",a="records";e[r]=i[r],e[s]=i[s],e[o]=i[o],e[a]=i[a]}return e},t.prototype.getAggregate=function(e){var i=jt.filterQueries(e.queries,"onAggregates"),r=[];if(i.length)for(var s=void 0,o=0;o=0;l--)a[l]&&(o=i.comparer,le.endsWith(a[l]," desc")&&(o=le.fnSort("descending"),a[l]=a[l].replace(" desc","")),e=le.sort(e,a[l],o));return e}return le.sort(e,s?"key":a,i.comparer)},t.prototype.onGroup=function(e,i,r){if(!e||!e.length)return e;var s=this.getAggregate(r);return le.group(e,le.getValue(i.fieldName,r),s,null,null,i.comparer)},t.prototype.onPage=function(e,i,r){var s=le.getValue(i.pageSize,r),o=(le.getValue(i.pageIndex,r)-1)*s;return e&&e.length?e.slice(o,o+s):e},t.prototype.onRange=function(e,i){return e&&e.length?e.slice(le.getValue(i.start),le.getValue(i.end)):e},t.prototype.onTake=function(e,i){return e&&e.length?e.slice(0,le.getValue(i.nos)):e},t.prototype.onSkip=function(e,i){return e&&e.length?e.slice(le.getValue(i.nos)):e},t.prototype.onSelect=function(e,i){return e&&e.length?le.select(e,le.getValue(i.fieldNames)):e},t.prototype.insert=function(e,i,r,s,o){return m(o)?e.dataSource.json.push(i):e.dataSource.json.splice(o,0,i)},t.prototype.remove=function(e,i,r,s){var a,o=e.dataSource.json;for("object"==typeof r&&!(r instanceof Date)&&(r=le.getObject(i,r)),a=0;a1&&(g="("+g+")"),p.filters.push(g);for(var y=0,S="object"==typeof p.filters[f]?Object.keys(p.filters[f]):[];y-1&&this.formRemoteGroupedData(e[s].items,i+1,r-1);var o="GroupGuid",h="records";return e[o]=BK[o],e.level=i,e.childLevels=r,e[h]=e[0].items.length?this.getGroupedRecords(e,!m(e[0].items[h])):[],e},t.prototype.getGroupedRecords=function(e,i){for(var r=[],o=0;ol.length-3?(l=l.substring(0,l.length-1),o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.endswith:le.odv4UniOperator.endswith):l.lastIndexOf("%")!==l.indexOf("%")&&l.lastIndexOf("%")>l.indexOf("%")+1?(l=l.substring(l.indexOf("%")+1,l.lastIndexOf("%")),o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains):o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains),l="'"+(l=encodeURIComponent(l))+"'";else if("wildcard"===o)if(-1!==l.indexOf("*")){var d=l.split("*"),u=void 0,p=0;if(0!==l.indexOf("*")&&-1===d[0].indexOf("%3f")&&-1===d[0].indexOf("?")&&(u="'"+(u=d[0])+"'",s+=(o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.startswith:le.odv4UniOperator.startswith)+"(",s+=c+",",a&&(s+=a),s+=u+")",p++),l.lastIndexOf("*")!==l.length-1&&-1===d[d.length-1].indexOf("%3f")&&-1===d[d.length-1].indexOf("?")&&(u="'"+(u=d[d.length-1])+"'",p>0&&(s+=" and "),s+=(o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.endswith:le.odv4UniOperator.endswith)+"(",s+=c+",",a&&(s+=a),s+=u+")",p++),d.length>2)for(var f=1;f0&&(s+=" and "),"substringof"===(o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains)||"not substringof"===o){var g=u;u=c,c=g}s+=o+"(",s+=c+",",a&&(s+=a),s+=u+")",p++}0===p?(o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains,(-1!==l.indexOf("?")||-1!==l.indexOf("%3f"))&&(l=-1!==l.indexOf("?")?l.split("?").join(""):l.split("%3f").join("")),l="'"+l+"'"):o="wildcard"}else o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains,(-1!==l.indexOf("?")||-1!==l.indexOf("%3f"))&&(l=-1!==l.indexOf("?")?l.split("?").join(""):l.split("%3f").join("")),l="'"+l+"'";return"substringof"!==o&&"not substringof"!==o||(g=l,l=c,c=g),"wildcard"!==o&&(s+=o+"(",s+=c+",",a&&(s+=a),s+=l+")"),s},t.prototype.addParams=function(e){n.prototype.addParams.call(this,e),delete e.reqParams.params},t.prototype.onComplexPredicate=function(e,i,r){for(var s=[],o=0;o-1;p--)!/\bContent-ID:/i.test(c[p])||!/\bHTTP.+201/.test(c[p])||(l=parseInt(/\bContent-ID: (\d+)/i.exec(c[p])[1],10),o.addedRecords[l]&&(h=le.parse.parseJson(/^\{.+\}/m.exec(c[p])[0]),ze({},o.addedRecords[l],this.processResponse(h))));return o}return null},t.prototype.compareAndRemove=function(e,i,r){var s=this;return m(i)||Object.keys(e).forEach(function(o){o!==r&&"@odata.etag"!==o&&(le.isPlainObject(e[o])?(s.compareAndRemove(e[o],i[o]),0===Object.keys(e[o]).filter(function(l){return"@odata.etag"!==l}).length&&delete e[o]):(e[o]===i[o]||e[o]&&i[o]&&e[o].valueOf()===i[o].valueOf())&&delete e[o])}),e},t}(uc),FK=function(n){function t(){var e=n.call(this)||this;return yt("beforeSend",uc.prototype.beforeSend,e),e}return Ml(t,n),t.prototype.insert=function(e,i,r,s,o){return this.pvt.position=o,this.updateType="add",{url:e.dataSource.insertUrl||e.dataSource.crudUrl||e.dataSource.url,data:JSON.stringify(ze({},{value:i,table:r,action:"insert"},le.getAddParams(this,e,s)))}},t.prototype.remove=function(e,i,r,s,o){return n.prototype.remove.call(this,e,i,r),{type:"POST",url:e.dataSource.removeUrl||e.dataSource.crudUrl||e.dataSource.url,data:JSON.stringify(ze({},{key:r,keyColumn:i,table:s,action:"remove"},le.getAddParams(this,e,o)))}},t.prototype.update=function(e,i,r,s,o){return this.updateType="update",this.updateKey=i,{type:"POST",url:e.dataSource.updateUrl||e.dataSource.crudUrl||e.dataSource.url,data:JSON.stringify(ze({},{value:r,action:"update",keyColumn:i,key:r[i],table:s},le.getAddParams(this,e,o)))}},t.prototype.processResponse=function(e,i,r,s,o,a,l){var h;if(e="batch"===(o?JSON.parse(o.data):e).action?le.parse.parseJson(e):e,"add"===this.updateType&&n.prototype.insert.call(this,i,e,null,null,this.pvt.position),"update"===this.updateType&&n.prototype.update.call(this,i,this.updateKey,e),this.updateType=void 0,e.added)for(h=0;hi&&h.push(c)}for(c=0;cthis.pageSize;)h.results.splice(0,1),h.keys.splice(0,1);return window.localStorage.setItem(this.guidId,JSON.stringify(h)),e},t.prototype.beforeSend=function(e,i,r){!m(this.cacheAdaptor.options.batch)&&le.endsWith(r.url,this.cacheAdaptor.options.batch)&&"post"===r.type.toLowerCase()&&i.headers.set("Accept",this.cacheAdaptor.options.multipartAccept),e.dataSource.crossDomain||i.headers.set("Accept",this.cacheAdaptor.options.accept)},t.prototype.update=function(e,i,r,s){return this.isCrudAction=!0,this.cacheAdaptor.update(e,i,r,s)},t.prototype.insert=function(e,i,r){return this.isInsertAction=!0,this.cacheAdaptor.insert(e,i,r)},t.prototype.remove=function(e,i,r,s){return this.isCrudAction=!0,this.cacheAdaptor.remove(e,i,r,s)},t.prototype.batchRequest=function(e,i,r){return this.cacheAdaptor.batchRequest(e,i,r)},t}(uc),nt=function(){function n(t,e,i){var s,r=this;return this.dateParse=!0,this.timeZoneHandling=!0,this.persistQuery={},this.isInitialLoad=!1,this.requests=[],this.isInitialLoad=!0,!t&&!this.dataSource&&(t=[]),i=i||t.adaptor,t&&!1===t.timeZoneHandling&&(this.timeZoneHandling=t.timeZoneHandling),t instanceof Array?s={json:t,offline:!0}:"object"==typeof t?(t.json||(t.json=[]),t.enablePersistence||(t.enablePersistence=!1),t.id||(t.id=""),t.ignoreOnPersist||(t.ignoreOnPersist=[]),s={url:t.url,insertUrl:t.insertUrl,removeUrl:t.removeUrl,updateUrl:t.updateUrl,crudUrl:t.crudUrl,batchUrl:t.batchUrl,json:t.json,headers:t.headers,accept:t.accept,data:t.data,timeTillExpiration:t.timeTillExpiration,cachingPageSize:t.cachingPageSize,enableCaching:t.enableCaching,requestType:t.requestType,key:t.key,crossDomain:t.crossDomain,jsonp:t.jsonp,dataType:t.dataType,offline:void 0!==t.offline?t.offline:!(t.adaptor instanceof FK||t.adaptor instanceof _K||t.url),requiresFormat:t.requiresFormat,enablePersistence:t.enablePersistence,id:t.id,ignoreOnPersist:t.ignoreOnPersist}):le.throwError("DataManager: Invalid arguments"),void 0===s.requiresFormat&&!le.isCors()&&(s.requiresFormat=!!m(s.crossDomain)||s.crossDomain),void 0===s.dataType&&(s.dataType="json"),this.dataSource=s,this.defaultQuery=e,this.dataSource.enablePersistence&&this.dataSource.id&&window.addEventListener("unload",this.setPersistData.bind(this)),s.url&&s.offline&&!s.json.length?(this.isDataAvailable=!1,this.adaptor=i||new gp,this.dataSource.offline=!1,this.ready=this.executeQuery(e||new jt),this.ready.then(function(o){r.dataSource.offline=!0,r.isDataAvailable=!0,s.json=o.result,r.adaptor=new QE})):this.adaptor=s.offline?new QE:new gp,!s.jsonp&&this.adaptor instanceof gp&&(s.jsonp="callback"),this.adaptor=i||this.adaptor,s.enableCaching&&(this.adaptor=new UK(this.adaptor,s.timeTillExpiration,s.cachingPageSize)),this}return Object.defineProperty(n.prototype,"moduleName",{get:function(){return"datamanager"},enumerable:!0,configurable:!0}),n.prototype.getPersistedData=function(t){var e=localStorage.getItem(t||this.dataSource.id);return JSON.parse(e)},n.prototype.setPersistData=function(t,e,i){localStorage.setItem(e||this.dataSource.id,JSON.stringify(i||this.persistQuery))},n.prototype.setPersistQuery=function(t){var e=this,i=this.getPersistedData();if(this.isInitialLoad&&i&&Object.keys(i).length){this.persistQuery=i,this.persistQuery.queries=this.persistQuery.queries.filter(function(s){if(e.dataSource.ignoreOnPersist&&e.dataSource.ignoreOnPersist.length&&s.fn&&e.dataSource.ignoreOnPersist.some(function(l){return s.fn===l}))return!1;if("onWhere"===s.fn){var o=s.e;if(o&&o.isComplex&&o.predicates instanceof Array){var a=o.predicates.map(function(l){if(l.predicates&&l.predicates instanceof Array){var h=l.predicates.map(function(v){return new Ss(v.field,v.operator,v.value,v.ignoreCase,v.ignoreAccent,v.matchCase)});return"and"===l.condition?Ss.and(h):Ss.or(h)}return new Ss(l.field,l.operator,l.value,l.ignoreCase,l.ignoreAccent,l.matchCase)});s.e=new Ss(a[0],o.condition,a.slice(1))}}return!0});var r=ze(new jt,this.persistQuery);return this.isInitialLoad=!1,r}return this.persistQuery=t,this.isInitialLoad=!1,t},n.prototype.setDefaultQuery=function(t){return this.defaultQuery=t,this},n.prototype.executeLocal=function(t){!this.defaultQuery&&!(t instanceof jt)&&le.throwError("DataManager - executeLocal() : A query is required to execute"),this.dataSource.json||le.throwError("DataManager - executeLocal() : Json data is required to execute"),this.dataSource.enablePersistence&&this.dataSource.id&&(t=this.setPersistQuery(t));var e=this.adaptor.processQuery(this,t=t||this.defaultQuery);if(t.subQuery){var i=t.subQuery.fromTable,r=t.subQuery.lookups,s=t.isCountRequired?e.result:e;r&&r instanceof Array&&le.buildHierarchy(t.subQuery.fKey,i,s,r,t.subQuery.key);for(var o=0;oli");P.classList.remove("json-parent");for(var j=0;j',W=ve.children[0].placeholder}return W}function Q(k,W,ve){!m(ve)&&""!==ve&&K(W,ve.split(" ")),!m(k)&&""!==k&&V(W,k.split(" "))}function oe(k,W,ve){if("multiselect"===ve||function Mo(k){if(!k)return!1;for(var W=k;W&&W!==document.body;){if("none"===window.getComputedStyle(W).display)return!1;W=W.parentElement}return!0}(k)){var Te="multiselect"===ve?k:k.clientWidth-parseInt(getComputedStyle(k,null).getPropertyValue("padding-left"),10);!m(W)&&!m(W.getElementsByClassName("e-float-text-content")[0])&&(W.getElementsByClassName("e-float-text-content")[0].classList.contains("e-float-text-overflow")&&W.getElementsByClassName("e-float-text-content")[0].classList.remove("e-float-text-overflow"),(Te0)for(var Ye=0;Ye<_e.length;Ye++)_e[parseInt(Ye.toString(),10)].addEventListener("mousedown",wo,!1),_e[parseInt(Ye.toString(),10)].addEventListener("mouseup",Hl,!1);else if(_e.length>0)for(Ye=0;Ye<_e.length;Ye++)_e[parseInt(Ye.toString(),10)].removeEventListener("mousedown",wo,this),_e[parseInt(Ye.toString(),10)].removeEventListener("mouseup",Hl,this)}function wo(){for(var W=this.parentElement;!W.classList.contains("e-input-group");)W=W.parentElement;!function ya(k,W){!k.classList.contains("e-disabled")&&!k.querySelector("input").readOnly&&W.classList.add("e-input-btn-ripple")}(W,this)}function Hl(){var k=this;setTimeout(function(){k.classList.remove("e-input-btn-ripple")},500)}function mb(k,W){var ve=W("span",{className:k});return ve.classList.add("e-input-group-icon"),ve}function I_(k,W,ve,Te){var _e=m(Te)?mi:Te,Ye=mb(k,_e);W.classList.add("e-float-icon-left");var fi=W.querySelector(".e-input-in-wrap");if(m(fi)){fi=_e("span",{className:"e-input-in-wrap"}),ve.parentNode.insertBefore(fi,ve);var Gs=W.querySelectorAll(ve.tagName+" ~ *");fi.appendChild(ve);for(var Kn=0;Kn-1)if("class"===_e){var Ye=this.getInputValidClassList(k[""+_e]);""!==Ye&&V([W],Ye.split(" "))}else if("style"===_e){var fi=W.getAttribute(_e);fi=m(fi)?k[""+_e]:fi+k[""+_e],W.setAttribute(_e,fi)}else W.setAttribute(_e,k[""+_e])}},n.isBlank=function Hle(k){return!k||/^\s*$/.test(k)}}(Le||(Le={})),new RegExp("^(-)?(\\d*)$"),new RegExp("^[A-Za-z0-9._%+-]{1,}@[A-Za-z0-9._%+-]{1,}([.]{1}[a-zA-Z0-9]{2,}|[.]{1}[a-zA-Z0-9]{2,4}[.]{1}[a-zA-Z0-9]{2,4})$"),new RegExp("^([0-9]{4})-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])$"),new RegExp("^[0-9]*$"),new RegExp("^[+]?[0-9]{9,13}$"),new RegExp("^\\d{13,16}$");var me=function(){function n(t,e){this.width=t,this.height=e}return n.prototype.isEmpty=function(){return 0===this.height&&0===this.width},n.prototype.clone=function(){return new n(this.width,this.height)},n}(),Rie=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),KB=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},z=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Rie(t,n),t.equals=function(e,i){return e===i||!(!e||!i)&&(!e||!i||e.x===i.x&&e.y===i.y)},t.isEmptyPoint=function(e){return!(e.x&&e.y)},t.transform=function(e,i,r){var s={x:0,y:0};return s.x=Math.round(100*(e.x+r*Math.cos(i*Math.PI/180)))/100,s.y=Math.round(100*(e.y+r*Math.sin(i*Math.PI/180)))/100,s},t.findLength=function(e,i){return Math.sqrt(Math.pow(e.x-i.x,2)+Math.pow(e.y-i.y,2))},t.findAngle=function(e,i){var r=Math.atan2(i.y-e.y,i.x-e.x);return r=180*r/Math.PI,(r%=360)<0&&(r+=360),r},t.distancePoints=function(e,i){return Math.sqrt(Math.pow(i.x-e.x,2)+Math.pow(i.y-e.y,2))},t.getLengthFromListOfPoints=function(e){for(var i=0,r=0;ri.y&&!r?o.y+=s:o.y-=s:e.y===i.y?e.xi.x&&!r?o.x+=s:o.x-=s:r?(a=this.findAngle(e,i),o=this.transform(e,a,s)):(a=this.findAngle(i,e),o=this.transform(i,a,s)),o},t.direction=function(e,i){return Math.abs(i.x-e.x)>Math.abs(i.y-e.y)?e.x0)for(var r=0;rt.right||this.top>t.bottom||this.bottom=t.right&&this.top<=t.top&&this.bottom>=t.bottom},n.prototype.containsPoint=function(t,e){return void 0===e&&(e=0),this.left-e<=t.x&&this.right+e>=t.x&&this.top-e<=t.y&&this.bottom+e>=t.y},n.toBounds=function(t){for(var e=new n,i=0,r=t;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},s3=function(n){if(n)switch(n.type){case"Linear":default:return bI;case"Radial":return Gie}return bI},Yie=function(){return function n(t,e,i,r){this.left=t,this.right=e,this.top=i,this.bottom=r}}(),$n=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),it([I(0)],t.prototype,"left",void 0),it([I(0)],t.prototype,"right",void 0),it([I(0)],t.prototype,"top",void 0),it([I(0)],t.prototype,"bottom",void 0),t}(Ee),Qie=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),it([I(45)],t.prototype,"angle",void 0),it([I(5)],t.prototype,"distance",void 0),it([I(.7)],t.prototype,"opacity",void 0),it([I("lightgrey")],t.prototype,"color",void 0),t}(Ee),o3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),t.prototype.getClassName=function(){return"Stop"},it([I("")],t.prototype,"color",void 0),it([I(0)],t.prototype,"offset",void 0),it([I(1)],t.prototype,"opacity",void 0),t}(Ee),wx=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),it([Bt([],o3)],t.prototype,"stops",void 0),it([I("None")],t.prototype,"type",void 0),it([I("")],t.prototype,"id",void 0),t}(Ee),bI=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),it([I(0)],t.prototype,"x1",void 0),it([I(0)],t.prototype,"x2",void 0),it([I(0)],t.prototype,"y1",void 0),it([I(0)],t.prototype,"y2",void 0),t}(wx),Gie=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),it([I(0)],t.prototype,"cx",void 0),it([I(0)],t.prototype,"cy",void 0),it([I(0)],t.prototype,"fx",void 0),it([I(0)],t.prototype,"fy",void 0),it([I(50)],t.prototype,"r",void 0),t}(wx),Ll=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),it([I("white")],t.prototype,"fill",void 0),it([I("black")],t.prototype,"strokeColor",void 0),it([I("")],t.prototype,"strokeDashArray",void 0),it([I(1)],t.prototype,"strokeWidth",void 0),it([I(1)],t.prototype,"opacity",void 0),it([x0(s3)],t.prototype,"gradient",void 0),t}(Ee),a3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),it([I("transparent")],t.prototype,"fill",void 0),t}(Ll),Xp=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),it([I("black")],t.prototype,"color",void 0),it([I("Arial")],t.prototype,"fontFamily",void 0),it([I(12)],t.prototype,"fontSize",void 0),it([I(!1)],t.prototype,"italic",void 0),it([I(!1)],t.prototype,"bold",void 0),it([I("CollapseSpace")],t.prototype,"whiteSpace",void 0),it([I("WrapWithOverflow")],t.prototype,"textWrapping",void 0),it([I("Center")],t.prototype,"textAlign",void 0),it([I("None")],t.prototype,"textDecoration",void 0),it([I("Wrap")],t.prototype,"textOverflow",void 0),it([I("transparent")],t.prototype,"fill",void 0),t}(Ll),on=function(n){return n[n.Default=0]="Default",n[n.expandNode=2]="expandNode",n[n.interaction=4]="interaction",n[n.GroupingInProgress=8]="GroupingInProgress",n[n.GroupClipboardInProcess=16]="GroupClipboardInProcess",n[n.ClearObject=32]="ClearObject",n}(on||{}),hi=function(n){return n[n.Visible=1]="Visible",n[n.Hidden=2]="Hidden",n[n.Hover=4]="Hover",n[n.Connect=8]="Connect",n}(hi||{}),Kt=function(n){return n[n.None=0]="None",n[n.ShowHorizontalLines=1]="ShowHorizontalLines",n[n.ShowVerticalLines=2]="ShowVerticalLines",n[n.ShowLines=3]="ShowLines",n[n.SnapToHorizontalLines=4]="SnapToHorizontalLines",n[n.SnapToVerticalLines=8]="SnapToVerticalLines",n[n.SnapToLines=12]="SnapToLines",n[n.SnapToObject=16]="SnapToObject",n[n.All=31]="All",n}(Kt||{}),mr=function(n){return n[n.None=1]="None",n[n.ConnectorSourceThumb=2]="ConnectorSourceThumb",n[n.ConnectorTargetThumb=4]="ConnectorTargetThumb",n[n.ResizeSouthEast=8]="ResizeSouthEast",n[n.ResizeSouthWest=16]="ResizeSouthWest",n[n.ResizeNorthEast=32]="ResizeNorthEast",n[n.ResizeNorthWest=64]="ResizeNorthWest",n[n.ResizeEast=128]="ResizeEast",n[n.ResizeWest=256]="ResizeWest",n[n.ResizeSouth=512]="ResizeSouth",n[n.ResizeNorth=1024]="ResizeNorth",n[n.Rotate=2048]="Rotate",n[n.UserHandle=4096]="UserHandle",n[n.ToolTip=8192]="ToolTip",n[n.ResizeAll=2046]="ResizeAll",n[n.All=16382]="All",n}(mr||{}),qe=function(n){return n[n.None=1]="None",n[n.Select=2]="Select",n[n.Delete=4]="Delete",n[n.Drag=8]="Drag",n[n.DragSourceEnd=16]="DragSourceEnd",n[n.DragTargetEnd=32]="DragTargetEnd",n[n.DragSegmentThumb=64]="DragSegmentThumb",n[n.AllowDrop=128]="AllowDrop",n[n.Bridging=256]="Bridging",n[n.BridgeObstacle=512]="BridgeObstacle",n[n.InheritBridging=1024]="InheritBridging",n[n.PointerEvents=2048]="PointerEvents",n[n.Tooltip=4096]="Tooltip",n[n.InheritTooltip=8192]="InheritTooltip",n[n.Interaction=4218]="Interaction",n[n.ReadOnly=16384]="ReadOnly",n[n.LineRouting=32768]="LineRouting",n[n.InheritLineRouting=65536]="InheritLineRouting",n[n.ConnectToNearByNode=131072]="ConnectToNearByNode",n[n.ConnectToNearByPort=262144]="ConnectToNearByPort",n[n.ConnectToNearByElement=393216]="ConnectToNearByElement",n[n.InheritSegmentThumbShape=524288]="InheritSegmentThumbShape",n[n.InheritSegmentThumbSize=1048576]="InheritSegmentThumbSize",n[n.Default=2043454]="Default",n}(qe||{}),Lr=function(n){return n[n.ReadOnly=2]="ReadOnly",n[n.InheritReadOnly=4]="InheritReadOnly",n[n.Select=8]="Select",n[n.Drag=16]="Drag",n[n.Resize=32]="Resize",n[n.Rotate=64]="Rotate",n[n.Tooltip=128]="Tooltip",n[n.Interaction=120]="Interaction",n[n.None=0]="None",n}(Lr||{}),ie=function(n){return n[n.None=0]="None",n[n.Select=2]="Select",n[n.Drag=4]="Drag",n[n.Rotate=8]="Rotate",n[n.Shadow=16]="Shadow",n[n.PointerEvents=32]="PointerEvents",n[n.Delete=64]="Delete",n[n.InConnect=128]="InConnect",n[n.OutConnect=256]="OutConnect",n[n.Individual=512]="Individual",n[n.Expandable=1024]="Expandable",n[n.AllowDrop=2048]="AllowDrop",n[n.Inherit=78]="Inherit",n[n.ResizeNorthEast=4096]="ResizeNorthEast",n[n.ResizeEast=8192]="ResizeEast",n[n.ResizeSouthEast=16384]="ResizeSouthEast",n[n.ResizeSouth=32768]="ResizeSouth",n[n.ResizeSouthWest=65536]="ResizeSouthWest",n[n.ResizeWest=131072]="ResizeWest",n[n.ResizeNorthWest=262144]="ResizeNorthWest",n[n.ResizeNorth=524288]="ResizeNorth",n[n.Resize=1044480]="Resize",n[n.AspectRatio=1048576]="AspectRatio",n[n.Tooltip=2097152]="Tooltip",n[n.InheritTooltip=4194304]="InheritTooltip",n[n.ReadOnly=8388608]="ReadOnly",n[n.HideThumbs=16777216]="HideThumbs",n[n.AllowMovingOutsideLane=33554432]="AllowMovingOutsideLane",n[n.Default=5240814]="Default",n}(ie||{}),Xr=function(n){return n[n.None=0]="None",n[n.ElementIsPort=2]="ElementIsPort",n[n.ElementIsGroup=4]="ElementIsGroup",n[n.HorizontalLaneHeader=8]="HorizontalLaneHeader",n}(Xr||{}),bt=function(n){return n[n.Rotate=2]="Rotate",n[n.ConnectorSource=4]="ConnectorSource",n[n.ConnectorTarget=8]="ConnectorTarget",n[n.ResizeNorthEast=16]="ResizeNorthEast",n[n.ResizeEast=32]="ResizeEast",n[n.ResizeSouthEast=64]="ResizeSouthEast",n[n.ResizeSouth=128]="ResizeSouth",n[n.ResizeSouthWest=256]="ResizeSouthWest",n[n.ResizeWest=512]="ResizeWest",n[n.ResizeNorthWest=1024]="ResizeNorthWest",n[n.ResizeNorth=2048]="ResizeNorth",n[n.Default=4094]="Default",n}(bt||{}),rt=function(n){return n[n.None=1]="None",n[n.Bridging=2]="Bridging",n[n.UndoRedo=4]="UndoRedo",n[n.Tooltip=8]="Tooltip",n[n.UserInteraction=16]="UserInteraction",n[n.ApiUpdate=32]="ApiUpdate",n[n.PageEditable=48]="PageEditable",n[n.Zoom=64]="Zoom",n[n.PanX=128]="PanX",n[n.PanY=256]="PanY",n[n.Pan=384]="Pan",n[n.ZoomTextEdit=512]="ZoomTextEdit",n[n.Virtualization=1024]="Virtualization",n[n.LineRouting=2048]="LineRouting",n[n.Default=500]="Default",n}(rt||{}),Ci=function(n){return n[n.None=0]="None",n[n.SingleSelect=1]="SingleSelect",n[n.MultipleSelect=2]="MultipleSelect",n[n.ZoomPan=4]="ZoomPan",n[n.DrawOnce=8]="DrawOnce",n[n.ContinuousDraw=16]="ContinuousDraw",n[n.Default=3]="Default",n}(Ci||{}),Ya=function(n){return n[n.Self=1]="Self",n[n.Parent=2]="Parent",n}(Ya||{}),pt=function(n){return n[n.None=0]="None",n[n.Control=1]="Control",n[n.Meta=1]="Meta",n[n.Alt=2]="Alt",n[n.Shift=4]="Shift",n}(pt||{}),Mt=function(n){return n[n.None=null]="None",n[n.Number0=0]="Number0",n[n.Number1=1]="Number1",n[n.Number2=2]="Number2",n[n.Number3=3]="Number3",n[n.Number4=4]="Number4",n[n.Number5=5]="Number5",n[n.Number6=6]="Number6",n[n.Number7=7]="Number7",n[n.Number8=8]="Number8",n[n.Number9=9]="Number9",n[n.A=65]="A",n[n.B=66]="B",n[n.C=67]="C",n[n.D=68]="D",n[n.E=69]="E",n[n.F=70]="F",n[n.G=71]="G",n[n.H=72]="H",n[n.I=73]="I",n[n.J=74]="J",n[n.K=75]="K",n[n.L=76]="L",n[n.M=77]="M",n[n.N=78]="N",n[n.O=79]="O",n[n.P=80]="P",n[n.Q=81]="Q",n[n.R=82]="R",n[n.S=83]="S",n[n.T=84]="T",n[n.U=85]="U",n[n.V=86]="V",n[n.W=87]="W",n[n.X=88]="X",n[n.Y=89]="Y",n[n.Z=90]="Z",n[n.Left=37]="Left",n[n.Up=38]="Up",n[n.Right=39]="Right",n[n.Down=40]="Down",n[n.Escape=27]="Escape",n[n.Space=32]="Space",n[n.PageUp=33]="PageUp",n[n.PageDown=34]="PageDown",n[n.End=35]="End",n[n.Home=36]="Home",n[n.Delete=46]="Delete",n[n.Tab=9]="Tab",n[n.Enter=13]="Enter",n[n.BackSpace=8]="BackSpace",n[n.F1=112]="F1",n[n.F2=113]="F2",n[n.F3=114]="F3",n[n.F4=115]="F4",n[n.F5=116]="F5",n[n.F6=117]="F6",n[n.F7=118]="F7",n[n.F8=119]="F8",n[n.F9=120]="F9",n[n.F10=121]="F10",n[n.F11=122]="F11",n[n.F12=123]="F12",n[n.Star=56]="Star",n[n.Plus=187]="Plus",n[n.Minus=189]="Minus",n[n.BracketLeft=219]="BracketLeft",n[n.BracketRight=221]="BracketRight",n}(Mt||{}),ee=function(n){return n[n.Render=2]="Render",n[n.PublicMethod=4]="PublicMethod",n[n.ToolAction=8]="ToolAction",n[n.UndoRedo=16]="UndoRedo",n[n.TextEdit=32]="TextEdit",n[n.Group=64]="Group",n[n.Clear=128]="Clear",n[n.PreventClearSelection=256]="PreventClearSelection",n[n.Interactions=512]="Interactions",n[n.PreventHistory=1024]="PreventHistory",n[n.PreventIconsUpdate=2048]="PreventIconsUpdate",n[n.PreventCollectionChangeOnDragOver=4096]="PreventCollectionChangeOnDragOver",n[n.PreventZIndexOnDragging=8192]="PreventZIndexOnDragging",n[n.isGroupDragging=16384]="isGroupDragging",n[n.DragUsingMouse=32768]="DragUsingMouse",n[n.DecoratorPropertyChange=65536]="DecoratorPropertyChange",n[n.PreventLaneContainerUpdate=131072]="PreventLaneContainerUpdate",n}(ee||{}),Qa=function(n){return n[n.None=2]="None",n[n.DrawSelectorBorder=4]="DrawSelectorBorder",n[n.PreventRenderSelector=8]="PreventRenderSelector",n}(Qa||{}),$i=function(n){return n[n.None=0]="None",n[n.PreventDrag=2]="PreventDrag",n[n.PreventScale=4]="PreventScale",n[n.PreventDataInit=8]="PreventDataInit",n[n.hScrollbarMoved=16]="hScrollbarMoved",n[n.vScrollbarMoved=32]="vScrollbarMoved",n[n.AnimationClick=64]="AnimationClick",n[n.EnableGroupAction=128]="EnableGroupAction",n[n.PanInProgress=256]="PanInProgress",n[n.OverViewAction=512]="OverViewAction",n}($i||{}),ca=function(n){return n[n.None=0]="None",n[n.PropertyChange=1024]="PropertyChange",n[n.Interaction=2048]="Interaction",n}(ca||{}),Ae=function(n){return n[n.Zero=0]="Zero",n[n.One=1]="One",n[n.Two=2]="Two",n[n.Three=3]="Three",n[n.Four=4]="Four",n[n.Five=5]="Five",n}(Ae||{}),Ce=function(n){return n[n.collectionChange=0]="collectionChange",n[n.rotateChange=1]="rotateChange",n[n.positionChange=2]="positionChange",n[n.propertyChange=3]="propertyChange",n[n.selectionChange=4]="selectionChange",n[n.sizeChange=5]="sizeChange",n[n.drop=6]="drop",n[n.sourcePointChange=7]="sourcePointChange",n[n.targetPointChange=8]="targetPointChange",n[n.connectionChange=9]="connectionChange",n[n.animationComplete=10]="animationComplete",n[n.click=11]="click",n[n.doubleClick=12]="doubleClick",n[n.scrollChange=13]="scrollChange",n[n.dragEnter=14]="dragEnter",n[n.dragLeave=15]="dragLeave",n[n.dragOver=16]="dragOver",n[n.textEdit=17]="textEdit",n[n.paletteSelectionChange=18]="paletteSelectionChange",n[n.historyChange=19]="historyChange",n[n.mouseEnter=20]="mouseEnter",n[n.mouseLeave=21]="mouseLeave",n[n.mouseOver=22]="mouseOver",n[n.expandStateChange=23]="expandStateChange",n[n.segmentCollectionChange=24]="segmentCollectionChange",n[n.commandExecute=25]="commandExecute",n[n.historyStateChange=26]="historyStateChange",n[n.onUserHandleMouseDown=27]="onUserHandleMouseDown",n[n.onUserHandleMouseUp=28]="onUserHandleMouseUp",n[n.onUserHandleMouseEnter=29]="onUserHandleMouseEnter",n[n.onUserHandleMouseLeave=30]="onUserHandleMouseLeave",n[n.onImageLoad=31]="onImageLoad",n[n.onDoBindingInit=32]="onDoBindingInit",n[n.keyUp=33]="keyUp",n[n.keyDown=34]="keyDown",n[n.fixedUserHandleClick=35]="fixedUserHandleClick",n[n.elementDraw=36]="elementDraw",n[n.mouseWheel=37]="mouseWheel",n[n.segmentChange=38]="segmentChange",n[n.onFixedUserHandleMouseDown=39]="onFixedUserHandleMouseDown",n[n.onFixedUserHandleMouseUp=40]="onFixedUserHandleMouseUp",n[n.onFixedUserHandleMouseEnter=41]="onFixedUserHandleMouseEnter",n[n.onFixedUserHandleMouseLeave=42]="onFixedUserHandleMouseLeave",n[n.loaded=43]="loaded",n}(Ce||{}),ri=function(n){return n[n.None=1]="None",n[n.Drag=2]="Drag",n[n.Draw=4]="Draw",n[n.InConnect=8]="InConnect",n[n.OutConnect=16]="OutConnect",n[n.ToolTip=32]="ToolTip",n[n.InheritTooltip=64]="InheritTooltip",n[n.Default=24]="Default",n}(ri||{}),Cx=function(n){return n[n.None=1]="None",n[n.Source=2]="Source",n[n.Target=4]="Target",n[n.Intermediate=8]="Intermediate",n[n.All=14]="All",n}(Cx||{}),MI=function(n){return n[n.None=0]="None",n[n.SymmetricAngle=2]="SymmetricAngle",n[n.SymmetricDistance=4]="SymmetricDistance",n[n.Default=6]="Default",n}(MI||{}),as=function(){function n(){this.pivot={x:.5,y:.5},this.isDirt=!0,this.isExport=!1,this.exportScaleValue={x:0,y:0},this.exportScaleOffset={x:0,y:0},this.canApplyStyle=!0,this.visible=!0,this.offsetX=0,this.offsetY=0,this.cornerRadius=0,this.minHeight=void 0,this.minWidth=void 0,this.maxWidth=void 0,this.maxHeight=void 0,this.width=void 0,this.height=void 0,this.rotateAngle=0,this.margin={left:0,right:0,top:0,bottom:0},this.connectionDirection="Auto",this.horizontalAlignment="Auto",this.verticalAlignment="Auto",this.flip="None",this.flipMode="All",this.relativeMode="Point",this.transform=Ya.Self|Ya.Parent,this.style={fill:"white",strokeColor:"black",opacity:1,strokeWidth:1},this.desiredSize=new me,this.actualSize=new me,this.parentTransform=0,this.preventContainer=!1,this.isSvgRender=!1,this.bounds=new Ne(0,0,0,0),this.shadow=null,this.description="",this.staticSize=!1,this.shapeType="",this.isRectElement=!1,this.isCalculateDesiredSize=!0,this.flipOffset={x:0,y:0},this.elementActions=Xr.None,this.inversedAlignment=!0,this.position=void 0,this.unitMode=void 0,this.float=!1,this.floatingBounds=void 0}return n.prototype.setOffsetWithRespectToBounds=function(t,e,i){this.unitMode=i,this.position={x:t,y:e}},n.prototype.getAbsolutePosition=function(t){if(void 0!==this.position)return"Absolute"===this.unitMode?this.position:{x:this.position.x*t.width,y:this.position.y*t.height}},Object.defineProperty(n.prototype,"outerBounds",{get:function(){return this.floatingBounds||this.bounds},set:function(t){this.floatingBounds=t},enumerable:!0,configurable:!0}),n.prototype.measure=function(t,e,i){var s=void 0!==this.height?this.height:(t.height||0)-this.margin.top-this.margin.bottom;return this.id&&0===s&&this.elementActions&Xr.HorizontalLaneHeader&&(s=this.actualSize.height),this.desiredSize=new me(void 0!==this.width?this.width:(t.width||0)-this.margin.left-this.margin.right,s),this.isCalculateDesiredSize&&(this.desiredSize=this.validateDesiredSize(this.desiredSize,t)),this.desiredSize},n.prototype.arrange=function(t){return this.actualSize=t,this.updateBounds(),this.actualSize},n.prototype.updateBounds=function(){this.bounds=yr(this)},n.prototype.validateDesiredSize=function(t,e){return this.isRectElement&&!this.width&&!this.minWidth&&!this.maxWidth&&(t.width=50),this.isRectElement&&!this.height&&!this.minHeight&&!this.maxHeight&&(t.height=50),(void 0===t||void 0!==this.width&&void 0!==this.height)&&((t=t||new me).width=void 0===this.width?(e.width||0)-this.margin.left-this.margin.right:this.width,t.height=void 0===this.height?(e.height||0)-this.margin.top-this.margin.bottom:this.height),void 0!==this.minWidth&&(t.width=Math.max(t.width,this.minWidth)),void 0!==this.minHeight&&(t.height=Math.max(t.height,this.minHeight)),void 0!==this.maxWidth&&0!==this.maxWidth&&(t.width=Math.min(t.width,this.maxWidth)),void 0!==this.maxHeight&&0!==this.maxHeight&&(t.height=Math.min(t.height,this.maxHeight)),t},n}(),ere=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Cs=function(n){function t(){var e=null!==n&&n.apply(this,arguments)||this;return e.padding=new Yie(0,0,0,0),e.desiredBounds=void 0,e.measureChildren=!0,e.prevRotateAngle=0,e}return ere(t,n),t.prototype.hasChildren=function(){return void 0!==this.children&&this.children.length>0},t.prototype.measure=function(e,i,r){this.desiredBounds=void 0;var o,a,s=void 0;if(this.hasChildren()){for(var l=0;l=n.width&&s.length>0)i[i.length]={text:s,x:0,dy:0,width:o},s="";else{(s+=a[r+1]||"").indexOf("\n")>-1&&(i[i.length]={text:s,x:0,dy:0,width:Bc(s,n)},s="");var l=Bc(s,n);Math.ceil(l)+2>=n.width&&s.length>0&&(i[i.length]={text:s,x:0,dy:0,width:l},s=""),r===a.length-1&&s.length>0&&(i[i.length]={text:s,x:0,dy:0,width:l},s="")}else i=function Soe(n,t,e){var c,d,u,p,i=[],r="",s=0,o=0,a="nowrap"!==n.whiteSpace,h=(t||n.content).split("\n");for(s=0;s0?" ":"")+c[parseInt(o.toString(),10)];var f=Bc(d=c[o+1]?r+" "+c[o+1]:r,n);Math.floor(f)>(e||n.width)-2&&r.length>0?(i[i.length]={text:r,x:0,dy:0,width:d===r?f:r===p?u:Bc(r,n)},r=""):o===c.length-1&&(i[i.length]={text:r,x:0,dy:0,width:f},r=""),p=d,u=f}return i}(n,t,e);else i[i.length]={text:a,x:0,dy:0,width:Bc(a,n)};return i}(l,r,n.isLaneOrientation?i:void 0),n.wrapBounds=a=function Ioe(n,t){var r,s,e={x:0,width:0},i=0;for(i=0;in.width&&("Ellipsis"===n.textOverflow||"Clip"===n.textOverflow)?0:-r/2:"right"===n.textAlign?-r:t.length>1?0:-r/2,t[parseInt(i.toString(),10)].dy=1.2*n.fontSize,t[parseInt(i.toString(),10)].x=r,e.x=Math.min(e.x,r),e.width=Math.max(e.width,s);return e}(l,o),s.width=a.width,n.wrapBounds.width>=i&&"Wrap"!==l.textOverflow&&(s.width=i),s.height=o.length*n.style.fontSize*1.2,s}(this,0,0,this.isLaneOrientation?e.height:this.width||e.width):this.desiredSize,this.desiredSize=void 0===this.width||void 0===this.height?new me(i.width,i.height):new me(this.width,this.height),this.desiredSize=this.validateDesiredSize(this.desiredSize,e),this.desiredSize},t.prototype.arrange=function(e){return(e.width!==this.actualSize.width||e.height!==this.actualSize.height||this.isDirt)&&(this.doWrap=!0),this.actualSize=e,this.updateBounds(),this.isDirt=!1,this.actualSize},t}(as),ire=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Ii=function(n){function t(){var e=null!==n&&n.apply(this,arguments)||this;return e.measureChildren=void 0,e}return ire(t,n),t.prototype.measure=function(e,i,r){var s=void 0,o=void 0;if(this.hasChildren()){for(var a=0,l=this.children;a=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},xd=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return are(t,n),Lh([I("")],t.prototype,"content",void 0),Lh([I("TopLeft")],t.prototype,"position",void 0),Lh([I("Mouse")],t.prototype,"relativeMode",void 0),Lh([I(!0)],t.prototype,"showTipPointer",void 0),Lh([I("auto")],t.prototype,"width",void 0),Lh([I("auto")],t.prototype,"height",void 0),Lh([I("Auto")],t.prototype,"openOn",void 0),Lh([I()],t.prototype,"animation",void 0),Lh([I(!1)],t.prototype,"isSticky",void 0),t}(Ee);function l3(n){var t=new Sh;t=h3(n.tooltip,t);var e=new Sh(t);return e.beforeCollision=hre,e.beforeOpen=lre,e.cssClass="e-diagram-tooltip",e.opensOn="custom",e.appendTo("#"+n.element.id),e.close(),e}function lre(n){(""===this.content||void 0===this.content)&&(n.element.style.display="none")}function hre(n){n.collidedPosition&&n.collidedPosition!==this.position&&(n.element.style.display="none")}function Ex(n,t){var e=n.tooltipObject;return h3(t?t.tooltip:n.tooltip,e),e}function h3(n,t){return n.content?(t.content=n.content,"string"==typeof n.content&&(t.content=ko(function(){return n.content})),t.position=n.position,t.showTipPointer=n.showTipPointer,t.width=n.width,t.height=n.height,t.animation=n.animation?n.animation:{close:{effect:"None"}}):t.close(),t}var Dx=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Hn=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},xx=function(n){function t(e,i,r,s){var o=n.call(this,e,i,r,s)||this;return o.inEdges=[],o.outEdges=[],o}return Dx(t,n),Hn([I("")],t.prototype,"id",void 0),Hn([I("Center")],t.prototype,"horizontalAlignment",void 0),Hn([I("Center")],t.prototype,"verticalAlignment",void 0),Hn([re({},$n)],t.prototype,"margin",void 0),Hn([I(12)],t.prototype,"width",void 0),Hn([I(12)],t.prototype,"height",void 0),Hn([re({},Ll)],t.prototype,"style",void 0),Hn([I("Square")],t.prototype,"shape",void 0),Hn([I("Auto")],t.prototype,"connectionDirection",void 0),Hn([I(hi.Connect)],t.prototype,"visibility",void 0),Hn([I("")],t.prototype,"pathData",void 0),Hn([I(ri.Default)],t.prototype,"constraints",void 0),Hn([I()],t.prototype,"addInfo",void 0),Hn([I()],t.prototype,"outEdges",void 0),Hn([I()],t.prototype,"inEdges",void 0),Hn([re({},xd)],t.prototype,"tooltip",void 0),t}(Ee),Es=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return Dx(t,n),t.prototype.getClassName=function(){return"PointPort"},Hn([re({x:.5,y:.5},z)],t.prototype,"offset",void 0),t}(xx),xc=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return Dx(t,n),t.prototype.getClassName=function(){return"PathPort"},Hn([I(.5)],t.prototype,"offset",void 0),Hn([re({x:0,y:0},z)],t.prototype,"displacement",void 0),Hn([I("Center")],t.prototype,"alignment",void 0),t}(xx),EI=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),lr=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},cre=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return EI(t,n),lr([I("blue")],t.prototype,"color",void 0),lr([I("")],t.prototype,"content",void 0),lr([I("")],t.prototype,"link",void 0),lr([I("None")],t.prototype,"textDecoration",void 0),lr([I("NewTab")],t.prototype,"hyperlinkOpenState",void 0),t}(Ee),Tx=function(n){function t(e,i,r,s){var o=n.call(this,e,i,r,s)||this;return r.id||(o.id=e.parentObj&&e.parentObj.propName&&"phases"===e.parentObj.propName?e.parentObj.id:Qe()),o}return EI(t,n),lr([I("")],t.prototype,"content",void 0),lr([I(void 0)],t.prototype,"template",void 0),lr([I("String")],t.prototype,"annotationType",void 0),lr([I(!0)],t.prototype,"visibility",void 0),lr([I(Lr.InheritReadOnly)],t.prototype,"constraints",void 0),lr([re(void 0,cre)],t.prototype,"hyperlink",void 0),lr([I("")],t.prototype,"id",void 0),lr([I()],t.prototype,"width",void 0),lr([I()],t.prototype,"height",void 0),lr([I(0)],t.prototype,"rotateAngle",void 0),lr([I("Parent")],t.prototype,"rotationReference",void 0),lr([re({strokeWidth:0,strokeColor:"transparent",fill:"transparent"},Xp)],t.prototype,"style",void 0),lr([I("Center")],t.prototype,"horizontalAlignment",void 0),lr([I("Center")],t.prototype,"verticalAlignment",void 0),lr([re({},$n)],t.prototype,"margin",void 0),lr([re({top:void 0,bottom:void 0,left:void 0,right:void 0},$n)],t.prototype,"dragLimit",void 0),lr([I("Shape")],t.prototype,"type",void 0),lr([re({},xd)],t.prototype,"tooltip",void 0),lr([I()],t.prototype,"addInfo",void 0),t}(Ee),Zn=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return EI(t,n),t.prototype.getClassName=function(){return"ShapeAnnotation"},lr([re({x:.5,y:.5},z)],t.prototype,"offset",void 0),t}(Tx),Nr=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return EI(t,n),t.prototype.getClassName=function(){return"PathAnnotation"},lr([I(.5)],t.prototype,"offset",void 0),lr([re({x:0,y:0},z)],t.prototype,"displacement",void 0),lr([I("Center")],t.prototype,"alignment",void 0),lr([I(!1)],t.prototype,"segmentAngle",void 0),t}(Tx);function Ax(n){return fre[n.toString()]}function c3(n){return mre[""+n]}var fre={X:"M14,14 L106,106 M106,14 L14,106",Circle:"M0,50 A50,50,0 1 1 100,50 A50,50,0 1 1 0,50 Z",Square:"M0,0 L10,0 L10,10 L0,10 z"},gre={OpenArrow:"M15.9,23 L5,16 L15.9,9 L17,10.7 L8.7,16 L17,21.3Z",Square:"M0,0 L10,0 L10,10 L0,10 z",Fletch:"M14.8,10c0,0-3.5,6,0.2,12c0,0-2.5-6-10.9-6C4.1,16,11.3,16,14.8,10z",OpenFetch:"M6,17c-0.6,0-1-0.4-1-1s0.4-1,1-1c10.9,0,11-5,11-5c0-0.6,0.4-1,1-1s1,0.4,1,1C19,10.3,18.9,17,6,17C6,17,6,17,6,17z M18,23c-0.5,0-1-0.4-1-1c0-0.2-0.3-5-11-5c-0.6,0-1-0.5-1-1s0.4-1,1-1c0,0,0,0,0,0c12.9,0,13,6.7,13,7 C19,22.6,18.6,23,18,23z",IndentedArrow:"M17,10c0,0-4.5,5.5,0,12L5,16L17,10z",OutdentedArrow:"M14.6,10c0,0,5.4,6,0,12L5,16L14.6,10z",DoubleArrow:"M19,10 L19,22 L13,16Z M12,10 L12,22 L6,16Z",Arrow:"M15,10 L15,22 L5,16Z",Diamond:"M12,23l-7-7l7-7l6.9,7L12,23z",Circle:"M0,50 A50,50,0 1 1 100,50 A50,50,0 1 1 0,50 Z"},vre={Square:"M0,0 L10,0 L10,10 L0,10 z",Rhombus:"M10,5 L5,10 L0,5 L5,0 L10,5 Z ",Rectangle:"M0,0 L15,0 L15,10 L0,10 z ",OpenArrow:"M15.9,23 L5,16 L15.9,9 L17,10.7 L8.7,16 L17,21.3Z",Fletch:"M9.82,0 C9.82,0,6.61,5,10,10 C10,10,7.71,5,0,5 C0,5,6.61,5,9.82,0 Z ",OpenFetch:"M0.71,5.71 C0.29,5.71,0,5.43,0,5 C0,4.57,0.29,4.29,0.71,4.29 C8.5,4.29,8.57,0.71,8.57,0.71 C8.57,0.29,8.86,0,9.29,0 C9.719999999999999,0,10,0.29,10,0.71 C10,0.93,9.93,5.71,0.71,5.71 C0.71,5.71,0.71,5.71,0.71,5.71 Z M9.29,10 C8.93,10,8.57,9.71,8.57,9.29 C8.57,9.14,8.36,5.71,0.71,5.71 C0.29,5.71,0,5.36,0,5 C0,4.64,0.29,4.29,0.71,4.29 C0.71,4.29,0.71,4.29,0.71,4.29 C9.93,4.29,10,9.07,10,9.29 C10,9.71,9.71,10,9.29,10 Z ",IndentedArrow:"M10,0 C10,0,6.25,4.58,10,10 L0,5 L10,0 Z ",OutdentedArrow:"M8,0 C8,0,12.5,5,8,10 L0,5 L8,0 Z ",DoubleArrow:"M19,10 L19,22 L13,16Z M12,10 L12,22 L6,16Z",Arrow:"M15,10 L15,22 L5,16Z",Diamond:"M10,5 L5,10 L0,5 L5,0 L10,5 Z ",Circle:"M10,5 C10,7.76,7.76,10,5,10 C2.24,10,0,7.76,0,5 C0,2.24,2.24,0,5,0 C7.76,0,10,2.24,10,5 Z ",Ellipse:"M15,5 C15,7.76,11.64,10,7.5,10 C3.36,10,0,7.76,0,5 C0,2.24,3.36,0,7.5,0 C11.64,0,15,2.24,15,5 Z "},mre={Square:"M0,0 L10,0 L10,10 L0,10 z",Rhombus:"M10,5 L5,10 L0,5 L5,0 L10,5 Z ",Rectangle:"M0,0 L15,0 L15,10 L0,10 z",OpenArrow:"M23,15.9 L16,5 L9,15.9 L10.7,17 L16,8.7 L21,17.3Z",Fletch:"M9.82,0 C9.82,0,6.61,5,10,10 C10,10,7.71,5,0,5 C0,5,6.61,5,9.82,0 Z ",OpenFetch:"M0.71,5.71 C0.29,5.71,0,5.43,0,5 C0,4.57,0.29,4.29,0.71,4.29 C8.5,4.29,8.57,0.71,8.57,0.71 C8.57,0.29,8.86,0,9.29,0 C9.719999999999999,0,10,0.29,10,0.71 C10,0.93,9.93,5.71,0.71,5.71 C0.71,5.71,0.71,5.71,0.71,5.71 Z M9.29,10 C8.93,10,8.57,9.71,8.57,9.29 C8.57,9.14,8.36,5.71,0.71,5.71 C0.29,5.71,0,5.36,0,5 C0,4.64,0.29,4.29,0.71,4.29 C0.71,4.29,0.71,4.29,0.71,4.29 C9.93,4.29,10,9.07,10,9.29 C10,9.71,9.71,10,9.29,10 Z ",IndentedArrow:"M10,0 C10,0,6.25,4.58,10,10 L0,5 L10,0 Z ",OutdentedArrow:"M8,0 C8,0,12.5,5,8,10 L0,5 L8,0 Z ",DoubleArrow:"M10,19 L22,19 L16,13Z M10,12 L22,12 L16,6Z",Arrow:"M10,15 L22,15 L16,5Z",Diamond:"M10,5 L5,10 L0,5 L5,0 L10,5 Z ",Circle:"M10,5 C10,7.76,7.76,10,5,10 C2.24,10,0,7.76,0,5 C0,2.24,2.24,0,5,0 C7.76,0,10,2.24,10,5 Z ",Ellipse:"M15,5 C15,7.76,11.64,10,7.5,10 C3.36,10,0,7.76,0,5 C0,2.24,3.36,0,7.5,0 C11.64,0,15,2.24,15,5 Z "};function Lx(n){return yre[n.toString()]}var yre={Process:"M419.511,76.687L359.511,76.687L359.511,43.086L419.511,43.086z",Decision:"M 253.005,115.687L 200.567,146.071L 148.097,115.687L 200.534,85.304L 253.005,115.687 Z",Document:"M 60 31.9 c 0 0 -11 -7.7 -30 0 s -30 0 -30 0 V 0 h 60 V 31.9 Z",PreDefinedProcess:"M 0,0 L 50,0 L 50,50 L 0,50 Z M 8.334,0 L 8.334,50 M 41.667,0 L 41.667,50",Terminator:"M 269.711,29.33C 269.71,44.061 257.77,56 243.04,56L 158.058,56C 143.33,56 131.39,44.061 131.39,29.33L 131.39,29.33C 131.391,14.6057 143.33,2.669 158.058,2.669L 243.044,2.669C 257.772,2.669 269.711,14.6057 269.711,29.333 Z",PaperTap:"M0.0009,17.2042 L0.0009,47.165 C0.001,47.165 14.403,53.5455 25.00,47.165 C35.599,40.7852 44.403,43.5087 50.00,47.165L50.001,17.2042 M50.001,32.7987 L50.001,2.8405 C50.001,2.8405 35.599,-3.5427 25.001,2.8405C14.403,9.2237 5.599,6.494 0.0009,2.8405 L0.0009,32.7987",DirectData:"M 132.62 0 L 17.38 0 C 7.78 0 0 13.43 0 30 C 0 46.57 7.78 60 17.38 60 L 132.62 60 M 132.62 0C 123.02 0 115.24 13.43 115.24 30 C 115.24 46.57 123.02 60 132.62 60 C 142.22 60 150 46.57 150 30 C 150 13.43 142.22 0 132.62 0 z ",SequentialData:"M0.0029,24.999 C0.0029,11.1922 10.433,0.0021 23.295,0.0021 C36.159,0.00216 46.585,11.1922 46.585,24.999C46.585,38.8057 36.159,49.9979 23.295,49.9979 C10.433,49.9979 0.0029,38.8057 0.0029,24.999 z M23.294,49.999 L50.002,49.999",Sort:"M50.001,24.9971 L25.001,49.9971 L0.00097,24.9971 L25.001,-0.00286865 L50.001,24.9971 z M0.000976562,24.9971 L50.001,24.9971",MultiDocument:"M43.6826,40 C44.8746,40.6183 45.8586,41.3502 46.8366,42.1122 L46.8366,4.74487 L3.09857,4.74487 L3.09857,10.9544 M46.837,35.143 C48.027,35.765 49.025,36.604 50.003,37.369 L50.003,0.002 L6.264,0.002 L6.264,4.744 M43.682,47.113 L43.682,10.765 L0.0025,10.7652 L0.0025,47.1132 C0.0025,47.1132 12.5846,53.6101 21.8426,47.1132 C31.1006,40.6163 38.792,43.393 43.6826,47.1132 z",Collate:"M50.001,0.0028 L25.001,25.0029 L0.00097,0.0028 L50.001,0.002 z M0.0009,50.002 L25.001,25.002L50.001,50.002 L0.0009,50.0029 z",SummingJunction:"M7.3252,42.6768 L42.6772,7.3247 M42.6768,42.6768 L7.3248,7.3247 M0.0009,25.001 C0.0009,11.193 11.197,0.0009 25.001,0.0009 C38.809,0.0009 50.001,11.193 50.001,25.001 C50.001,38.809 38.809,50.001 25.001,50.001 C11.197,50.00 0.0009,38.809 0.0009,25.00 z",Or:"M 0 50 L 100 50 M 50 100 L 50 0.0 M 0 50 C 0 22.384 22.392 0 50 0 C 77.616 0 100 22.384 100 50 C 100 77.616 77.616 100 50 100 C 22.392 100 0 77.616 0 50 Z",InternalStorage:"M 0 3.81946A 2.5,3.81946 0 0,1 2.5,0L 47.5 0A 2.5,3.81946 0 0,1 50,3.81946L 50 45.836A 2.5,3.819446 0 0,1 47.5,49.652778L 2.5 49.652778A 2.5,3.819446 0 0,1 0,45.8336L 0 3.819446ZM 0 11.45834L 50 11.4583334M 12.5 0L 12.5 49.652778",Extract:"M0,35 L30,0 L60,35 Z",ManualOperation:"M46.4,28.8 L14.8,28.8 L0,0 L60,0 Z",Merge:"M60,0 L30,35 L0,0 Z",OffPageReference:"M60,33.3 L30.1,39 L0,33.3 L0,0 L60,0 Z",SequentialAccessStorage:"M 60 30 C 60 13.4 46.6 0 30 0 S 0 13.4 0 30 s 13.4 30 30 30 h 28.6 v -6.5 h -9.9C 55.5 48 60 39.5 60 30 Z",Annotation:"M49.9984,50.0029 L-0.00271199,50.0029 L-0.00271199,0.00286865 L49.9984,0.00286865",Annotation2:"M49.9977,50.0029 L25.416,50.0029 L25.416,0.00286865 L49.9977,0.00286865 M25.4166,25.0029 L-0.00227869,25.0029",Data:"M 10 0 L 40 0 L 30 40 L 0 40 Z",Card:"M275,60 L400,60 L400,110 L260,110 L260,75 Z",Delay:"M0,0 L12.029,0 C14.212999,0 16,1.7869979 16,3.9709952 C16,6.1549926 14.212999,7.9409904 12.029,7.9409904 L0,7.9409904 z",Preparation:"M 1048.17 572 C 1051.06 568.86 1055.17 567.05 1059.5 567 L 1094.51 567 C 1098.84 567.05 1102.95 568.86 1105.84 572 L 1126.43 595 C 1127.01 596.28 1127.01 597.72 1126.43 599 L 1105.84 622 C 1102.95 625.14 1098.84 626.95 1094.51 627 L 1059.5 627 C 1055.17 626.95 1051.06 625.14 1048.17 622 L 1027.58 599 C 1027 597.72 1027 596.28 1027.58 595 L 1048.17 572 Z",Display:"M47.8809,19.2914 L32.7968,-0.00594145 L11.3902,-0.00594145 C7.93166,-0.00594145 0.00124586,11.187 0.00124586,24.9968C0.00124586,38.8032 7.93166,49.9962 11.3902,49.9962 L32.7968,49.99 L47.615,31.038 C47.615,31.0388 52.798,24.9968 47.880,19.2914 z",ManualInput:"M 912 732 L 1006.85 707 C 1008.2 707 1009.5 707.53 1010.46 708.46 C 1011.41 709.4 1011.95 710.67 1011.95 712 L 1011.95 762C 1012 764.41 1010.28 766.52 1007.87 767 L 917.1 767 C 915.75 767 914.45 766.47 913.49 765.54 C 912.54 764.6 912 763.33 912 762 L 912 732 Z",LoopLimit:"M 8 9 L 27 9 L 33 15 L 33 26 C 33 27 33 27 32 27 L 4 27 C 3 27 2 27 2 26 L 2 15 L 8 9 Z",StoredData:"M 5.55 0L 50 0A 1.5,30 0 0,1 50,0A 5.555,25 0 0,0 50,50A 1.5,30 0 0,1 50,50L 5.555 50A 5.55,25 0 0,1 5.555,0Z"};function d3(n,t,e){var i;i="Straight"!==n.type&&n.sourceWrapper?n.sourceWrapper.corners.center:function Sre(n){var t;if(n.sourcePortWrapper){var e=n.sourcePortWrapper;t={x:e.offsetX,y:e.offsetY}}else t=n.sourceID&&n.sourceWrapper&&n.targetWrapper?Nh(n,0,n.sourceWrapper.corners.center,n.targetWrapper.corners.center,!1):n.sourcePoint;return t}(n);var r=function bre(n,t,e,i,r){var b,M,s=n.sourceWrapper,o=n.targetWrapper,a=n.sourcePortWrapper,l=n.targetPortWrapper,d=[],f=Ga(n),y={corners:undefined,point:t,direction:undefined,margin:{left:5,right:5,bottom:5,top:5}},S={corners:undefined,point:e,direction:undefined,margin:{left:5,right:5,bottom:5,top:5}};if(void 0!==s&&void 0!==o&&(b=En(s),M=En(o),y.corners=s.corners,S.corners=o.corners),void 0!==a&&(y.direction="Left"===a.connectionDirection||"Top"===a.connectionDirection||"Bottom"===a.connectionDirection||"Right"===a.connectionDirection?a.connectionDirection:zo({x:a.offsetX,y:a.offsetY},b,s.bounds)),void 0!==l&&(S.direction="Left"===l.connectionDirection||"Right"===l.connectionDirection||"Bottom"===l.connectionDirection||"Top"===l.connectionDirection?l.connectionDirection:zo({x:l.offsetX,y:l.offsetY},M,o.bounds)),"Bezier"===n.type&&!n.isBezierEditing&&n.segments.length>0)for(var D=n.segments.length-1;D>=0;)n.segments[parseInt(D.toString(),10)].isInternalSegment&&n.segments.pop(),D--;if(void 0!==s&&void 0!==o)return(void 0===y.direction||void 0===S.direction)&&(i?function Ire(n,t,e){"LeftToRight"===e?(n.direction=n.direction?n.direction:"Right",t.direction=t.direction?t.direction:"Left"):"RightToLeft"===e?(n.direction=n.direction?n.direction:"Left",t.direction=t.direction?t.direction:"Right"):"TopToBottom"===e?(n.direction=n.direction?n.direction:"Bottom",t.direction=t.direction?t.direction:"Top"):"BottomToTop"===e&&(n.direction=n.direction?n.direction:"Top",t.direction=t.direction?t.direction:"Bottom")}(y,S,i):y.corners.top>S.corners.bottom&&Math.abs(y.corners.top-S.corners.bottom)>f?(y.direction=y.direction?y.direction:"Top",S.direction=S.direction?S.direction:"Bottom"):y.corners.bottomf?(y.direction=y.direction?y.direction:"Bottom",S.direction=S.direction?S.direction:"Top"):y.corners.rightf||y.corners.right+f=y.corners.left-f&&y.corners.left>S.corners.left?(y.direction=y.direction?y.direction:"Right",S.direction=S.direction?S.direction:"Left"):y.corners.left>S.corners.right&&Math.abs(y.corners.left-S.corners.right)>y.margin.left+y.margin.right||S.corners.right+f=S.corners.left-f&&y.corners.left0&&n.segments[0].direction&&(y.direction=n.segments[0].direction),y.point=Tc(b,y.direction),d=Tc(b,ls(y.direction)),y.point=Nh(n,0,y.point,d,!1)):y.point=o.corners.center;if(void 0!==h){switch(S.point={x:h.offsetX,y:h.offsetY},S.direction){case"Bottom":case"Top":S.point.y=S.point.y;break;case"Left":case"Right":S.point.x=S.point.x}n.targetPadding&&!w&&(S.point=DI(n,y,S,!0))}else"Orthogonal"===n.type||"Bezier"===n.type?(S.point=Tc(M,S.direction),d=Tc(M,ls(S.direction)),S.point=Nh(n,0,S.point,d,!0)):S.point=a.corners.center;if("Orthogonal"!==n.type){var C=void 0,D=void 0;if("Bezier"===n.type){if(n.bezierSettings.allowSegmentsReset||0===n.segments.length||!z.isEmptyPoint(n.segments[n.segments.length-1].point))return c=b3(n,y,S,void 0,s),Nx(n,y,S);_v(n)}else _v(n);if(void 0===n.sourcePortWrapper){y.point=y.corners.center,n.segments&&n.segments.length>0&&(C=z.isEmptyPoint((D=n.segments[0]).point)?void 0:D);var A=void 0!==C?C.point:S.point;if("Bezier"===n.type&&n.segments.length>0&&n.segments[0].vector1.angle&&n.segments[0].vector1.distance){var x=Math.max(y.corners.width,y.corners.height);A=z.transform(y.point,n.segments[0].vector1.angle,x/2)}y.point=w?n.sourceWrapper.bounds.center:Nh(n,0,y.point,A,!1)}if(void 0===n.targetPortWrapper){S.point=S.corners.center,n.segments&&n.segments.length>1&&(C=z.isEmptyPoint((D=n.segments[n.segments.length-2]).point)?void 0:D);var R=C?C.point:y.point;"Bezier"===n.type&&n.segments.length>0&&n.segments[n.segments.length-1].vector2.angle&&n.segments[n.segments.length-1].vector2.distance&&(x=Math.max(y.corners.width,y.corners.height),R=z.transform(S.point,n.segments[0].vector2.angle,x/2)),S.point=w?n.targetWrapper.bounds.center:Nh(n,0,R,S.point,!0)}c=Nx(n,y,S)}else"Orthogonal"===n.type&&n.segments&&n.segments.length>0&&null!==n.segments[0].direction?c=function Nre(n,t,e,i,r,s,o){var a,h,c,d;_v(n);for(var u=0;u0&&n.segments[u-1].direction===h.direction?u=y3(n,u,t):h.direction?t.point=u3(t,n.segments[parseInt(u.toString(),10)]):(p=n.segments[u-1])&&p.points&&(t.point=p.points[p.points.length-1]),u===n.segments.length-1)if(S3(n,t),v3(a=void 0===r?Lre(n,t,e):f3(n,t,e),n),h.points=[],a.length>=2)for(c=0;c2&&n.segments.length>2){var f={x:a[parseInt(c.toString(),10)].x,y:t.point.y};h.points=[],h.points.push(f),h.points.push(a[parseInt(c.toString(),10)]);var p=n.segments[u-1];n.segments.length<4&&p.points.pop(),p.points=p.points.concat(h.points)}else h.points.push(a[parseInt(c.toString(),10)]);else h.points.push(a[parseInt(c.toString(),10)]);else d=u;if(void 0!==d&&!n.selectedSegmentIndex&&(d===n.segments.length-1&&(n.segments[d-1].direction=null,n.segments[d-1].length=null),n.segments.splice(d,1)),i&&0===u){var g=g3(n,i,s);g&&(t.point=g)}}return I3(n,[])}(n,y,S,l,h,o):(n.segments[0]||(C=new bi(n,"segments",{type:"Orthogonal"},!0),n.segments.push(C)),n.segments[0].points=c=b3(n,y,S,void 0,s));return c}(n,y.direction,S.direction,y.point,S.point,r);if(_v(n),(n.sourceWrapper||n.targetWrapper)&&function Dre(n,t,e){var i=n.sourcePortWrapper,r=n.targetPortWrapper,s=n.sourceWrapper,o=t.point,a={left:0,right:0,top:0,bottom:0},l={x:0,y:0},c="Top";if(s?(o=e.point,a=t.margin):(s=n.targetWrapper,a=e.margin),"Orthogonal"===n.type)if(n.segments&&n.segments.length>0&&n.sourceWrapper&&n.segments[0].direction)t.direction=n.segments[0].direction,l=Nh(n,0,l=Tc(s.corners,t.direction),Tc(s.corners,ls(t.direction)),!1);else{var u={corners:null,direction:null,point:null,margin:null};Uv(s,{corners:null,direction:null,point:o,margin:a},u,n),l=u.point,c=u.direction}else{var p=void 0;n.segments&&n.segments.length>1&&(p=s===n.sourceWrapper?n.segments[0].point:n.segments[n.segments.length-2].point),l=Nh(n,0,s.bounds.center,n.segments&&n.segments.length>1?p:o,s===n.targetWrapper)}s===n.sourceWrapper?(t.direction=t.direction||c,t.point=l,n.sourcePortWrapper&&(t.point={x:i.offsetX,y:i.offsetY},n.sourcePadding&&(t.point=DI(n,t,e,!1)))):(e.direction=e.direction||c,e.point=l,n.targetPortWrapper&&(e.point={x:r.offsetX,y:r.offsetY},n.targetPadding&&(e.point=DI(n,t,e,!0))))}(n,y,S),"Straight"===n.type||"Bezier"===n.type)d=Nx(n,y,S);else if("Orthogonal"===n.type&&n.segments&&n.segments.length>0&&null!==n.segments[0].length&&null!==n.segments[0].direction)d=function Ere(n,t,e,i,r,s,o){var a,l,c,u,h=[];if(_v(n),n.segments.length>0){for(var p=0;p0&&n.segments[p-1].direction===f.direction)p=y3(n,p,t);else{var g=n.segments[p-1];t.point=f.direction?u3(t,f):g.points[g.points.length-1]}if(p===n.segments.length-1&&(o||r?n.targetWrapper&&void 0===n.targetPortWrapper?(S3(n,t),l=wre(n,t,e)):l=f3(n,t,e):l=Mre(n,t,e),l))if(v3(l,n),f.points=[],l.length>=2)for(a=0;at.corners.top&&e.point.ye.point.x?"Left":"Right"):e.point.x>t.corners.left&&e.point.xe.point.y?"Top":"Bottom")),n.sourcePortWrapper&&s===ls(r)?(("Left"===s||"Right"===s)&&t.point.y>=t.corners.top&&t.point.y<=t.corners.center.y&&e.point.y>=t.corners.top&&e.point.y<=t.corners.center.y?(t.direction="Top",a=t.point.y-t.corners.top+20):("Left"===s||"Right"===s)&&t.point.y>t.corners.center.y&&t.point.y<=t.corners.bottom&&e.point.y>t.corners.center.y&&e.point.y<=t.corners.bottom?(t.direction="Bottom",a=t.corners.bottom-t.point.y+20):("Top"===s||"Bottom"===s)&&t.point.x>=t.corners.left&&t.point.x<=t.corners.center.x&&e.point.x>=t.corners.left&&e.point.x<=t.corners.center.x?(t.direction="Left",a=t.point.x-t.corners.left+20):("Top"===s||"Bottom"===s)&&t.point.x<=t.corners.right&&t.point.x>t.corners.center.x&&e.point.x<=t.corners.right&&e.point.xt.point.y&&t.point.y>=e.corners.top?(i="Top",r=t.point.y-e.corners.top+20):e.corners.center.y===t.point.y&&"Top"===n.segments[n.segments.length-2].direction||e.corners.center.ye.point.y?t.point.y-t.corners.top+20:t.corners.bottom-t.point.y+20):(i="Top",r=e.corners.height/2+20):e.corners.center.x!==t.point.x||e.corners.topt.point.x&&t.point.x>=e.corners.left?(i="Left",r=t.point.x-e.corners.left+20):e.corners.center.x===t.point.x&&"Left"===n.segments[n.segments.length-2].direction||e.corners.center.x<=t.point.x&&t.point.x<=e.corners.right?(i="Right",r=e.corners.right-t.point.x+20):void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&t.corners.left<=t.point.x&&t.point.x<=t.corners.right&&(i=t.direction,r=t.point.x>e.point.x?t.point.x-t.corners.left+20:t.corners.right-t.point.x+20):(i="Left",r=e.corners.width/2+20);var a=t.point;t.point=Bn(t.point,"Left"===i||"Top"===i?-r:r,"Left"===i||"Right"===i?0:90),t.direction=z.direction(t.point,e.point),void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&(t.corners.center.x===e.corners.center.x||t.corners.center.y===e.corners.center.y)&&(t.direction=e.direction);var l=Ys(n,t,e);return l.splice(0,0,a),l}function f3(n,t,e){var i,r;e.corners=n.targetWrapper.corners,void 0!==n.sourcePortWrapper&&(r=zo({x:n.sourcePortWrapper.offsetX,y:n.sourcePortWrapper.offsetY},En(n.sourceWrapper),n.sourceWrapper.bounds));var a=function Cre(n,t,e,i){var r=!1;switch(e.direction){case"Left":void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&"Right"===i&&t.point.x>e.point.x&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom||("Bottom"===i&&t.point.y>e.point.y||"Top"===i&&t.point.y=t.corners.left&&t.point.x<=t.corners.right?(t.direction="Right"===i?t.point.y>e.point.y?"Top":"Bottom":t.point.xe.point.x&&(t.point.y>e.point.y||t.point.yt.point.y&&e.corners.bottome.point.y||t.point.x>e.point.x&&t.point.y<=e.point.y&&e.corners.top=t.point.y?t.direction="Top":t.point.xe.point.x&&t.point.y>e.point.y&&e.corners.bottomt.point.y?t.direction="Bottom":t.point.y===e.point.y&&t.point.xe.point.y||"Top"===i&&t.point.ye.point.x&&t.point.x>=t.corners.left&&t.point.x<=t.corners.right?(t.direction=t.point.x>e.point.x?"Left":"Right",r=!0):void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&"Left"===i&&t.point.x=t.corners.top&&t.point.y<=t.corners.bottom?(t.direction=t.point.y>e.point.y?"Top":"Bottom",r=!0):t.point.x=t.point.y&&t.point.y===e.point.y||t.point.y>e.point.y&&t.point.x>e.point.x?t.direction="Top":t.point.ye.point.x?t.direction="Bottom":t.point.xe.point.y||t.point.ye.point.x&&(t.direction="Left");break;case"Top":void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&"Bottom"===i&&t.point.y>e.point.y&&t.point.x>=t.corners.left&&t.point.x<=t.corners.right||("Right"===i&&t.point.x>e.point.x||"Left"===i&&e.point.y>t.point.y&&e.point.x>t.point.x)&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom?(t.direction="Bottom"===i?t.point.x>e.point.x?"Left":"Right":t.point.ye.point.y&&t.point.x>e.corners.left&&t.point.x=e.point.y?t.direction="Top":t.point.ye.point.x?t.direction="Left":t.point.yt.point.x)&&t.point.y>e.point.y&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom||"Top"===i&&t.point.y=t.corners.left&&t.point.x<=t.corners.right)?(t.direction="Right"===i||"Left"===i?t.point.y>e.point.y?"Top":"Bottom":t.point.x>e.point.x?"Left":"Right",r=!0):t.point.ye.corners.left&&e.corners.right>t.point.x?t.point.ye.corners.left&&e.corners.center.x>=t.point.x?t.direction="Left":t.point.ye.point.y&&t.point.x>e.point.x?t.direction="Left":t.point.y>e.point.y&&t.point.xe.point.x||e.point.x>t.point.x)&&(t.direction="Bottom")}return r}(n,t,e,r);return!n.selectedSegmentIndex&&void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&e.direction===ls(r)&&(("Left"===e.direction&&t.point.x>e.point.x||"Right"===e.direction&&t.point.x=t.corners.top&&t.point.y<=t.corners.bottom||"Bottom"===e.direction&&t.point.y=t.corners.left&&t.point.x<=t.corners.right)?i=p3(n,t,e):n.selectedSegmentIndex||t.direction!==e.direction?!n.selectedSegmentIndex&&("Left"===e.direction&&t.point.x>e.point.x||"Right"===e.direction&&t.point.x=t.point.y||"Top"===e.direction&&t.point.y>e.point.y||"Bottom"===e.direction&&t.point.y=t.point.x?i=n.selectedSegmentIndex?Nl(t,e):p3(n,t,e):!n.selectedSegmentIndex&&void 0!==n.sourceWrapper&&void 0!==n.targetWrapper&&void 0!==n.targetPortWrapper&&("Left"===t.direction||"Right"===t.direction)&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom&&("Top"===e.direction||"Bottom"===e.direction)&&e.corners.center.x===t.corners.center.x?(t.direction="Top"===e.direction?"Bottom":"Top",i=Ys(n,t,e,"Top"===e.direction?t.corners.bottom-t.point.y+20:t.point.y-t.corners.top+20)):!n.selectedSegmentIndex&&void 0!==n.sourceWrapper&&void 0!==n.targetWrapper&&void 0!==n.targetPortWrapper&&("Top"===t.direction||"Bottom"===t.direction)&&t.point.x>=t.corners.left&&t.point.x<=t.corners.right&&("Left"===e.direction||"Right"===e.direction)&&e.corners.center.y===t.corners.center.y?(t.direction="Left"===e.direction?"Right":"Left",i=Ys(n,t,e,"Left"===e.direction?t.corners.right-t.point.x+20:t.point.x-t.corners.left+20)):i=a?Ys(n,t,e,"Left"===t.direction||"Right"===t.direction?"Left"===t.direction?t.point.x-t.corners.left+20:t.corners.right-t.point.x+20:"Top"===t.direction?t.point.y-t.corners.top+20:t.corners.bottom-t.point.y+20):Nl(t,e):i=Ys(n,t,e),i}function g3(n,t,e){var r,i={x:t.offsetX,y:t.offsetY},s=En(e),o=zo(i,s,e.bounds),a=n.segments[0];return a.direction!==o&&(function Ore(n,t,e,i,r,s){var a,h,o=13,l=[];l.push(i),i.y===r.y&&("Left"===t&&r.xi.x)||i.x===r.x&&("Top"===t&&r.yi.y)||("Top"===t||"Bottom"===t?"Top"===t&&r.yi.y-o||"Bottom"===t&&r.y>i.y&&r.yo&&("Top"===t&&r.yi.y)?l.push({x:i.x,y:r.y}):(a=r.xi.x-o||"right"===t&&r.x>i.x&&r.xo&&("Left"===t&&r.xi.x)?l.push({x:r.x,y:i.y}):(l.push({x:a="Left"===t?e.left-o:e.right+o,y:i.y}),l.push({x:a,y:r.y})),s&&(l.push(n.points[0]),l.reverse()),n.points=l)}(a,o,s,a.points[0],a.points[a.points.length-1],!1),r=a.points[a.points.length-1],a.direction=z.direction(a.points[a.points.length-2],a.points[a.points.length-1])),r}function v3(n,t,e){var s,i=t.segments[t.segments.length-2],r=i.points[i.points.length-1];(("Top"===i.direction||"Bottom"===i.direction)&&r.x===n[1].x||("Left"===i.direction||"Right"===i.direction)&&r.y===n[1].y)&&(i.points[i.points.length-1]=n[1],s=z.direction(i.points[0],i.points[i.points.length-1]),void 0!==t.sourceWrapper&&void 0===t.sourcePortWrapper&&s===ls(i.direction)&&("Left"===i.direction||"Right"===i.direction?i.points[0].x="Right"===i.direction?i.points[0].x-t.sourceWrapper.corners.width:i.points[0].x+t.sourceWrapper.corners.width:i.points[0].y="Bottom"===i.direction?i.points[0].y-t.sourceWrapper.corners.height:i.points[0].y+t.sourceWrapper.corners.height),i.direction=s,i.length=z.distancePoints(i.points[0],i.points[i.points.length-1]),n.splice(0,1))}function DI(n,t,e,i){var o=i?n.targetPadding:n.sourcePadding,a=i?n.targetPortWrapper:n.sourcePortWrapper,l=new Ne(a.bounds.x-o,a.bounds.y-o,a.actualSize.width+2*o,a.actualSize.height+2*o),h=[l.topLeft,l.topRight,l.bottomRight,l.bottomLeft];h[h.length]=h[0];var d=i?e.point:t.point;return kx({x1:t.point.x,y1:t.point.y,x2:e.point.x,y2:e.point.y},h,0,d)||d}function m3(n,t){var e=[],i=mF(0,n.corners,t);i.push(i[0]);for(var r=0;r0){var r=void 0,s=[],o=t.point;for(r=0;r1&&z.equals(a.points[0],a.points[1])&&n.segments.splice(r,1),a)for(var l=0;l0||0===r)&&i.push(a.points[parseInt(l.toString(),10)])}}return i}function Ox(n,t,e){return"Top"===n||"Bottom"===n?e.x>t.x?"Right":"Left":e.y>t.y?"Bottom":"Top"}function _v(n){if("Straight"===n.type||"Bezier"===n.type){if(0===n.segments.length||n.segments.length>0&&!z.isEmptyPoint(n.segments[n.segments.length-1].point))if("Bezier"===n.type){var t=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0},!0);n.segments.push(t)}else t=new Pl(n,"segments",{type:"Straight"},!0),n.segments.push(t)}else{if(n.segments.length>0)for(var e=!1,i=0;i=t.corners.left&&e.point.x<=t.corners.right&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom)t.direction=e.point.y>t.point.y?"Bottom":"Top",i=Ys(n,t,e,"Top"===t.direction?t.point.y-t.corners.top+20:t.corners.bottom-t.point.y+20);else if(n.sourcePortWrapper&&r===ls(o)){var h;("Left"===r||"Right"===r)&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom?(t.direction=e.point.y>t.point.y?"Bottom":"Top",h=t.corners.height/2+20):("Top"===r||"Bottom"===r)&&t.point.x>=t.corners.left&&t.point.x<=t.corners.right&&(t.direction=e.point.x>t.point.x?"Right":"Left",h=t.corners.width/2+20),t.direction&&h?i=Ys(n,t,e,h,!0):(t.direction=o,i=Nl(t,e))}else if(!n.sourcePortWrapper||r!==e.direction||"Top"!==r&&"Bottom"!==r||t.corners.center.x!==e.corners.center.x)if(t.direction===e.direction)if(("Left"===t.direction||"Right"===t.direction)&&e.point.y>t.corners.top-20&&e.point.yt.corners.left-20&&e.point.xt.point.y?"Bottom":"Top",i=Ys(n,t,e,"Bottom"===t.direction?t.corners.bottom-t.point.y+20:t.point.y-t.corners.top+20);else t.direction=o,i=Ys(n,t,e,"Top"===o||"Bottom"===o?n.sourceWrapper.height/2+20:n.sourceWrapper.width/2+20),t.point=i[1],"Left"===o||"Right"===o?(e.direction=o,e.point="Left"===o?e.corners.middleLeft:e.corners.middleRight):Uv(n.targetWrapper,t,e,n),i=Ys(n,t,e);return i}function S3(n,t){if(void 0!==n.targetWrapper&&void 0===n.targetPortWrapper&&En(n.targetWrapper).containsPoint(t.point,1)){var i=n.targetWrapper,r=n.segments[n.segments.length-2],s=r.points[r.points.length-1],o=ls(r.direction);"Bottom"===o?s.yi.corners.top-1&&(r.points[r.points.length-1].y=i.corners.top-20,r.length=z.distancePoints(r.points[0],r.points[r.points.length-1])):"Left"===o?s.x>i.corners.left-1&&(r.points[r.points.length-1].x=i.corners.left-20,r.length=z.distancePoints(r.points[0],r.points[r.points.length-1])):"Right"===o&&s.x0||0===e)&&t.push(i.points[parseInt(r.toString(),10)]);return t}function Uv(n,t,e,i){var r,s={x:0,y:0},o=xI(n,n.corners,n.bounds),a=t.margin,l=t.point;if(o.bottomCenter.y+a.bottoml.y)r="Top",s=o.topCenter;else if(o.middleLeft.x-a.left>l.x)r="Left",s=o.middleLeft;else if(o.middleRight.x+a.rightc&&(p=c,r="Right",s=o.middleRight),p>d&&(p=d,r="Bottom",s=o.bottomCenter),p>u&&(r="Left",s=o.middleLeft)}e.point=s,e.direction=r;var f=Tc(o,ls(e.direction));e.point=Nh(i,0,e.point,f,n===i.targetWrapper)}function b3(n,t,e,i,r){var s,o,a;if(s=function Qre(n,t){var e=!1;switch(n){case"Left":switch(t){case"Right":case"Bottom":e=!0}break;case"Top":switch(t){case"Left":case"Right":case"Bottom":e=!0}break;case"Bottom":"Right"===t&&(e=!0)}return e}(t.direction,e.direction),s&&x3(t,e),"Right"===t.direction&&"Left"===e.direction)a=function kre(n,t,e,i){var o=Math.round(Math.abs(t.point.y-e.point.y)),a={x:Math.max(t.point.x,t.corners.right),y:t.point.y},l={x:Math.min(e.point.x,e.corners.left),y:e.point.y},h=Ga(n);if(i){var c=l;l=a,a=c}return t.corners.bottom+he.corners.bottom+h||("Bezier"!==n.type||e.corners.left-t.corners.right<=2*h&&e.corners.left-t.corners.right>=5)&&(h=0),t.margin={left:h,right:h,top:h,bottom:h},e.margin={left:h,right:h,top:h,bottom:h},0===o&&(t.corners.right=e.corners.right?void 0!==i&&(i.offsetYe.corners.bottom+e.margin.bottom)||void 0===i&&t.corners.middleRight.ye.corners.bottom+e.margin.bottom&&t.corners.top>e.corners.bottom||void 0===i&&t.corners.middleRight.y>e.corners.bottom||void 0!==i&&i.offsetYe.corners.top||void 0===i&&t.corners.middleRight.y>e.corners.bottom?Ae.Three:t.corners.rightr.offsetY+e.margin.right||void 0===r&&t.corners.top>e.corners.middleRight.y||void 0!==r&&(void 0!==i&&i.offsetXr.offsetX||void 0===r&&t.corners.left>e.corners.topCenter.x?Ae.Four:Ae.Two:void 0!==s&&Math.abs(t.corners.right-e.corners.left)<=5&&Math.abs(s.offsetY-e.corners.top)<=5||void 0!==r&&t.corners.right=25&&t.corners.middleRight.y+t.margin.righte.corners.bottom+e.margin.bottom||void 0===o&&t.corners.middleRight.y>e.corners.bottom+e.margin.bottom?t.corners.top>e.corners.bottom?void 0!==a&&t.corners.right+t.margin.righta.offsetX||void 0===a&&t.corners.left>e.corners.bottomCenter.x?Ae.Four:Ae.Two:void 0!==o&&Math.abs(t.corners.right-e.corners.left)<=25&&Math.abs(o.offsetY-e.corners.bottom)<=25?Ae.Two:Ae.Four}(n,t,e,s);else if("Bottom"===t.direction&&"Top"===e.direction)a=function Hre(n,t,e){var r=t.point.x-e.point.x,s=Ga(n);return t.corners.right+se.corners.right+s||("Bezier"!==n.type||e.corners.top-t.corners.bottom<=2*s&&e.corners.top-t.corners.bottom>=5)&&(s=0),t.margin={left:s,right:s,top:s,bottom:s},e.margin={left:s,right:s,top:s,bottom:s},0===r&&t.corners.bottome.corners.right+e.margin.right||void 0===i&&t.corners.bottomCenter.x>e.corners.right+e.margin.right?Ae.Three:t.corners.bottomr.offsetX||void 0===r&&t.corners.left>e.corners.left||void 0!==r&&t.corners.right+t.margin.righte.corners.bottom?Ae.Five:0===s||0===o?Ae.One:Ae.Three}(n,t,e)}else"Bottom"===t.direction&&"Left"===e.direction?a=function Bre(n,t,e,i){var r=n.sourcePortWrapper,s=n.targetPortWrapper,o=Ga(n);if(e.margin={left:o,right:o,top:o,bottom:o},t.margin={top:o,bottom:o,left:o,right:o},i){var l=r;r=s,s=l}return void 0!==r&&r.offsetXs.offsetY||void 0===s&&t.corners.top>e.corners.middleLeft.y?Ae.Four:Ae.Two:void 0!==s&&Math.abs(t.corners.right-e.corners.left)<=25&&Math.abs(s.offsetY-t.corners.bottom)<=25?Ae.Two:Ae.Four}(n,t,e,s):"Left"===t.direction&&"Left"===e.direction?a=function Ure(n,t,e){var i=n.sourcePortWrapper,r=n.targetPortWrapper,s=Ga(n);t.margin={left:s,right:s,top:s,bottom:s},e.margin={left:s,right:s,top:s,bottom:s};var o=Math.round(Math.abs(t.point.x-e.point.x)),a=Math.round(Math.abs(t.point.y-e.point.y));return t.corners.leftr.offsetY||void 0===r&&t.corners.top-t.margin.top>e.corners.middleLeft.y?Ae.Three:t.corners.righte.corners.bottom+e.margin.bottom||void 0===i&&t.corners.middleLeft.y>e.corners.bottom+e.margin.bottom?Ae.Three:t.corners.left>e.corners.right?Ae.Five:0===o||0===a?Ae.One:Ae.Three}(n,t,e):"Left"===t.direction&&"Top"===e.direction?a=function _re(n,t,e,i){var s=n.sourcePortWrapper,o=Ga(n);e.margin={left:o,right:o,top:o,bottom:o},t.margin={top:o,bottom:o,left:o,right:o};var a=n.targetPortWrapper,l={x:Math.min(t.point.x,t.corners.left),y:t.point.y},h={x:e.point.x,y:Math.min(e.point.y,e.corners.top)};if(i){var c=s;s=a,a=c;var d=l;l=h,h=d}return void 0!==s&&s.offsetYa.offsetX||void 0===a&&t.corners.left-t.margin.left>e.corners.topCenter.x?Ae.Two:Ae.Four:void 0!==a&&t.corners.rightr.offsetX||void 0===r&&t.corners.left>e.corners.left||void 0!==r&&t.corners.right+t.margin.righte.corners.right+e.margin.right||void 0===i&&t.corners.left>e.corners.right||void 0!==i&&i.offsetXe.corners.bottom?Ae.Five:0===s||0===o?Ae.One:Ae.Three}(n,t,e));return s&&x3(t,e),o=function Vre(n,t,e,i,r,s){var l,d,h=n.sourceWrapper.corners,c=n.targetWrapper.corners,u=20,p={corners:e.corners,point:e.point,direction:e.direction,margin:e.margin},f={corners:i.corners,point:i.point,direction:i.direction,margin:i.margin};if(!(p.direction===f.direction&&t!==Ae.Five||p.direction!==ls(f.direction)&&t!==Ae.Three))switch(p.direction){case"Left":h.middleLeft.x>c.middleRight.x&&(d=(h.middleLeft.x-c.middleRight.x)/2,u=s?d:Math.min(u,d));break;case"Right":h.middleRight.xc.bottomCenter.y&&(d=(h.topCenter.y-c.bottomCenter.y)/2,u=s?d:Math.min(u,d));break;case"Bottom":h.bottomCenter.yp&&hp)&&o>c&&o<=d&&e>=20&&(s=n.point.x-t.corners.left+s),i&&n.direction===t.direction&&n.corners.left>t.corners.left&&n.corners.left-t.corners.right>=20&&(s=(n.corners.left-t.corners.right)/2),f=Bn(n.point,s,180);break;case"Top":(o>c&&oc)&&h>p&&h<=u&&e>=20&&(s=n.point.y-t.corners.top+s),i&&n.direction===t.direction&&n.corners.top>t.corners.top&&n.corners.top-t.corners.bottom>=20&&(s=(n.corners.top-t.corners.bottom)/2),f=Bn(n.point,s,270);break;case"Right":(h>p&&hp)&&a=c&&e>=20&&(s=t.corners.right-n.point.x+s),i&&n.direction===t.direction&&n.corners.right=20&&(s=(t.corners.left-n.corners.right)/2),f=Bn(n.point,s,0);break;case"Bottom":(o>c&&oc)&&l=p&&e>=20&&(s=t.corners.bottom-n.point.y+s),i&&n.direction===t.direction&&n.corners.bottom=20&&(s=(t.corners.top-n.corners.bottom)/2),f=Bn(n.point,s,90)}r=[n.point,f];var g=void 0;if("Top"===n.direction||"Bottom"===n.direction){var v=n.direction;n.direction=f.x>t.point.x?"Left":"Right",n.point=f,r=TI(n,t,v,r,g=i?.5*Math.abs(f.x-t.point.x):g,i)}else v=n.direction,n.direction=f.y>t.point.y?"Top":"Bottom",n.point=f,r=TI(n,t,v,r,g=i?.5*Math.abs(f.y-t.point.y):g,i);return r}(p,f,u,g)),l}(n,a,t,e,i,r),"Bezier"===n.type&&function Yre(n,t,e){if("Bezier"===n.type)if(0===n.segments.length){var i=e[0],r=e[e.length-1];if(t===Ae.One){var s=Math.min(20,.5*z.findLength(i,r)),o={angle:Gt(i,r),distance:s},a={angle:Gt(r,i),distance:s},l=z.direction(i,r),c=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,orientation:"Left"===l||"Right"===l?"Horizontal":"Vertical"},!0);n.segments.push(c)}else if(t===Ae.Two)o={angle:Gt(i,d=e[1]),distance:.5*z.findLength(i,d)},a={angle:Gt(r,d),distance:.5*z.findLength(r,d)},l=z.direction(i,d),c=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,orientation:"Left"===l||"Right"===l?"Horizontal":"Vertical"},!0),n.segments.push(c);else if(t===Ae.Three){var d={x:.5*((u=e[1]).x+(p=e[e.length-2]).x),y:.5*(u.y+p.y)},f=(o={angle:Gt(i,u),distance:.5*z.findLength(i,u)},a={angle:Gt(d,u),distance:.5*z.findLength(d,u)},z.direction(i,u)),v=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,point:d,orientation:"Left"===f||"Right"===f?"Horizontal":"Vertical"},!0);n.segments.push(v);var y={angle:Gt(d,p),distance:.5*z.findLength(d,p)},S={angle:Gt(r,p),distance:.5*z.findLength(r,p)},b=z.direction(d,p),w=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:y,vector2:S,orientation:"Left"===b||"Right"===b?"Horizontal":"Vertical"},!0);n.segments.push(w)}else if(t===Ae.Four){var D={x:.5*((u=e[1]).x+(p=e[2]).x),y:.5*(u.y+p.y)},A={x:.5*(p.x+(C=e[3]).x),y:.5*(p.y+C.y)};o={angle:Gt(i,u),distance:.5*z.findLength(i,u)},a={angle:Gt(D,u),distance:.5*z.findLength(D,u)},f=z.direction(i,u),v=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,point:D,orientation:"Left"===f||"Right"===f?"Horizontal":"Vertical"},!0),n.segments.push(v),y={angle:Gt(D,p),distance:.5*z.findLength(D,p)},S={angle:Gt(A,p),distance:.5*z.findLength(A,p)},b=z.direction(D,p),w=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:y,vector2:S,point:A,orientation:"Left"===b||"Right"===b?"Horizontal":"Vertical"},!0),n.segments.push(w);var x={angle:Gt(A,C),distance:.5*z.findLength(A,C)},R={angle:Gt(r,C),distance:.5*z.findLength(r,C)},L=z.direction(A,C),N=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:x,vector2:R,orientation:"Left"===L||"Right"===L?"Horizontal":"Vertical"},!0);n.segments.push(N)}else if(t===Ae.Five){var u,p,C,T=e[4],P=(D={x:.5*((u=e[1]).x+(p=e[2]).x),y:.5*(u.y+p.y)},A={x:.5*(p.x+(C=e[3]).x),y:.5*(p.y+C.y)},{x:.5*(C.x+T.x),y:.5*(C.y+T.y)});o={angle:Gt(i,u),distance:.5*z.findLength(i,u)},a={angle:Gt(D,u),distance:.5*z.findLength(D,u)},f=z.direction(i,u),v=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,point:D,orientation:"Left"===f||"Right"===f?"Horizontal":"Vertical"},!0),n.segments.push(v),y={angle:Gt(D,p),distance:.5*z.findLength(D,p)},S={angle:Gt(A,p),distance:.5*z.findLength(A,p)},b=z.direction(D,p),w=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:y,vector2:S,point:A,orientation:"Left"===b||"Right"===b?"Horizontal":"Vertical"},!0),n.segments.push(w),x={angle:Gt(A,C),distance:.5*z.findLength(A,C)},R={angle:Gt(P,C),distance:.5*z.findLength(P,C)},L=z.direction(A,C),N=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:x,vector2:R,point:P,orientation:"Left"===L||"Right"===L?"Horizontal":"Vertical"},!0),n.segments.push(N);var _={angle:Gt(P,T),distance:.5*z.findLength(P,T)},B={angle:Gt(r,T),distance:.5*z.findLength(r,T)},j=z.direction(P,T),oe=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:_,vector2:B,orientation:"Left"===j||"Right"===j?"Horizontal":"Vertical"},!0);n.segments.push(oe)}else c=new ps(n,"segments",{type:"Bezier"},!0),n.segments.push(c)}else for(var ue=0;ue=13?13:n.connectorSpacing<=1?1:n.connectorSpacing}function Gt(n,t){var i=z.findLength({x:t.x,y:n.y},t),r=z.findLength(t,n),s=Math.asin(i/r);return s=180*s/Math.PI,n.xt.y&&(s=360-s):s=n.y0)for(var l=1;lc)&&(s=c,a=h),s>=0&&s<=1)break}}return a}function w3(n,t){var c,d,u,p,f,g,S,b,M,w,D,e=n.x1,i=n.y1,r=n.x2,s=n.y2,o=t.x1,a=t.y1,l=t.x2,h=t.y2;if(w=(c=s-i)*l+(u=e-r)*h+(f=r*i-e*s),0!==(M=c*o+u*a+f)&&0!==w&&C3(M,w)||(b=(d=h-a)*r+(p=o-l)*s+(g=l*a-o*h),0!==(S=d*e+p*i+g)&&0!==b&&C3(S,b)))return null;var A=c*p-d*u;return 0===A?null:(A<0?-A/2:A/2,0,{x:(D=u*g-p*f)<0?(D-0)/A:(D+0)/A,y:(D=d*f-c*g)<0?(D-0)/A:(D+0)/A})}function C3(n,t){return n*t>=0}function E3(n,t,e){switch(t.direction){case"Left":t.point.x>n.left&&(e=t.point.x-n.left>e?t.point.x-n.left+e:e);break;case"Right":t.point.xe?n.right-t.point.x+e:e);break;case"Top":t.point.y>n.top&&(e=t.point.y-n.top>e?t.point.y-n.top+e:e);break;case"Bottom":t.point.ye?n.bottom-t.point.y+e:e)}return e}function Nl(n,t){var e;switch(n.direction){case"Left":case"Right":var i={x:t.point.x,y:n.point.y};e=z.equals(n.point,i)||z.equals(t.point,i)?[n.point,t.point]:[n.point,i,t.point];break;case"Top":case"Bottom":var r={x:n.point.x,y:t.point.y};e=z.equals(n.point,r)||z.equals(t.point,r)?[n.point,t.point]:[n.point,r,t.point]}return e}function Ys(n,t,e,i,r,s){void 0===s&&(s=!1),i||(i=20),s&&t.direction!==e.direction&&(i="Left"===t.direction||"Right"===t.direction?Math.floor(.5*Math.abs(t.point.x-e.point.x)):Math.floor(.5*Math.abs(t.point.y-e.point.y)));var l,h,u,o=n.sourcePortWrapper,c=e.point.x-t.point.x,d=e.point.y-t.point.y;if(!r&&(Math.abs(c)<.001||Math.abs(d)<.001)&&void 0===e.direction)return[t.point,e.point];if(void 0===n.targetWrapper&&Math.abs(c)<=31&&Math.abs(d)<=31){if("Left"===t.direction||"Right"===t.direction?Math.abs(d)<12&&(t.direction=t.point.y>e.point.y?"Top":"Bottom"):Math.abs(c)<12&&(t.direction=t.point.x>e.point.x?"Left":"Right"),Math.abs(c)>12||Math.abs(d)>12)return Nl(t,e);i+=5}return"Left"===t.direction||"Right"===t.direction?("Right"===t.direction?(void 0!==e.direction&&"Right"===e.direction&&(i=Math.max(t.point.x,e.point.x)-t.point.x+i),t.point.x>e.point.x&&void 0===o&&(i=-i)):(void 0!==e.direction&&"Left"===e.direction&&(i=t.point.x-Math.min(t.point.x,e.point.x)+i),(t.point.x>e.point.x||void 0!==o||"Left"===t.direction)&&(i=-i)),u=e.point.y-t.point.y,l=Bn(t.point,i,0),0!=(u=e.point.y-l.y)&&(h=Bn(l,e.point.y-l.y,90))):("Top"===t.direction||"Bottom"===t.direction)&&("Bottom"===t.direction?void 0!==e.direction&&"Bottom"===e.direction&&(i=Math.max(t.point.y,e.point.y)-t.point.y+i):(void 0!==e.direction&&"Top"===e.direction&&(i=t.point.y-Math.min(t.point.y,e.point.y)+i),(t.point.y>e.point.y||void 0!==o||"Top"===t.direction)&&(i=-i)),u=e.point.x-t.point.x,l=Bn(t.point,i,90),0!=(u=e.point.x-l.x)&&(h=Bn(l,e.point.x-l.x,0))),0===u?[t.point,e.point]:[t.point,l,h,e.point]}function TI(n,t,e,i,r,s){var o;switch(void 0===r&&(r=20),void 0===s&&(s=!1),void 0===e?(n.margin={left:2,right:2,top:2,bottom:2},t.margin={left:0,right:5,top:0,bottom:5},s&&(n.margin={left:10,right:10,top:10,bottom:10},t.margin={left:10,right:10,top:10,bottom:10},"Left"===n.direction?(r=zx(n,t,e,r),n.corners.left-t.corners.right>=5&&(r=Math.abs(n.point.x-n.corners.left)+.5*Math.floor(n.corners.left-t.corners.right))):"Right"===n.direction?(r=Rx(n,t,r,e),t.corners.left-n.corners.right>=5&&(r=Math.abs(n.point.x-n.corners.right)+.5*Math.floor(t.corners.left-n.corners.right))):"Top"===n.direction?(r=Px(n,t,e,r),n.corners.top-t.corners.bottom>=5&&(r=Math.abs(n.point.y-n.corners.top)+.5*Math.floor(n.corners.top-t.corners.bottom))):"Bottom"===n.direction&&(r=Hx(n,t,r,e),t.corners.top-n.corners.bottom>=5&&(r=Math.abs(n.point.y-n.corners.bottom)+.5*Math.floor(t.corners.top-n.corners.bottom))))):("Bottom"===n.direction?s?t.corners.top-n.corners.bottom<20&&(r=t.corners.bottom-n.point.y+25):t.corners.top>n.corners.bottom&&t.corners.top-n.corners.bottom<20&&(r=(t.corners.top-n.corners.bottom)/2):"Top"===n.direction?s?n.corners.top-t.corners.bottom<20&&(r=n.point.y-t.corners.top+25):t.corners.bottomn.corners.right&&t.corners.left-n.corners.right<20&&(r=(t.corners.left-n.corners.right)/2):"Left"===n.direction&&(s?n.corners.left-t.corners.right<20&&(r=n.point.x-t.corners.left+25):t.corners.rightt.point.y||"Top"===t.direction&&n.point.yt.point.x||"Left"===t.direction&&n.point.xh||e.corners.top-e.margin.top<=i.point.y&&e.corners.bottom+e.margin.bottom>=i.point.y))if(!s||"Top"!==e.direction&&"Bottom"!==e.direction)c=Math.min(Math.abs(i.corners.left-e.corners.right)/2,20),h=e.corners.right-n.x+c;else{var c=Math.abs(i.corners.left-e.corners.right)/2;h=e.corners.right-n.x+c}else h="Top"===e.direction&&n.y>i.point.y||"Bottom"===e.direction&&n.y=e.corners.left-e.margin.left&&n.x<=e.corners.right+e.margin.right?Math.min(i.corners.left,e.corners.left)-n.x-20:i.corners.left-n.x-20;break;case"Right":if(e.corners.left-e.margin.left>i.corners.right+i.margin.right&&(e.corners.left-e.margin.right-i.corners.right>h||e.corners.top-e.margin.top<=i.point.y&&e.corners.bottom+e.margin.bottom>=i.point.y))if(!s||"Top"!==e.direction&&"Bottom"!==e.direction)c=Math.min(Math.abs(e.corners.left-i.corners.right)/2,20),h=e.corners.left-n.x-c;else{c=Math.abs(e.corners.left-i.corners.right)/2;h=e.corners.left-n.x-c}else h="Top"===e.direction&&n.y>i.point.y||"Bottom"===e.direction&&n.y=e.corners.left-e.margin.left&&n.x<=e.corners.right+e.margin.right?Math.max(i.corners.right,e.corners.right)-n.x+20:i.corners.right-n.x+20}o=Bn(n,h,0),a=Bn(o,i.point.y-n.y,90),l=i.point}else if("vertical"===t){switch(i.direction){case"Top":e.corners.bottom+e.margin.bottomh||e.corners.left-e.margin.left<=i.point.x&&e.corners.right+e.margin.right>=i.point.x)?!s||"Right"!==e.direction&&"Left"!==e.direction?(c=Math.min(Math.abs(i.corners.top-e.corners.bottom)/2,20),h=e.corners.bottom-n.y+c):(c=Math.abs(i.corners.top-e.corners.bottom)/2,h=e.corners.bottom-n.y+c):h="Left"===e.direction&&n.x>i.point.x||"Right"===e.direction&&n.x=e.corners.top-e.margin.top&&n.y<=e.corners.bottom+e.margin.bottom?Math.min(i.corners.top,e.corners.top)-n.y-20:i.corners.top-n.y-20;break;case"Bottom":e.corners.top-e.margin.top>i.corners.bottom+i.margin.bottom&&(e.corners.top-e.margin.top-i.corners.bottom>h||e.corners.left-e.margin.left<=i.point.x&&e.corners.right+e.margin.right>=i.point.x)?!s||"Right"!==e.direction&&"Left"!==e.direction?(c=Math.min(Math.abs(e.corners.top-i.corners.bottom)/2,20),h=e.corners.top-n.y-c):(c=Math.abs(e.corners.top-i.corners.bottom)/2,h=e.corners.top-n.y-c):h="Left"===e.direction&&n.x>i.point.x||"Right"===e.direction&&n.x=e.corners.top-e.margin.top&&n.y<=e.corners.bottom+e.margin.bottom?Math.max(i.corners.bottom,e.corners.bottom)-n.y+20:i.corners.bottom-n.y+20}o=Bn(n,h,90),a=Bn(o,i.point.x-n.x,0),l=i.point}r.push(o),r.push(a),r.push(l)}function Px(n,t,e,i){return n.corners.top-n.margin.top>t.corners.top+t.margin.top&&n.corners.top-n.margin.top<=t.corners.bottom+t.margin.bottom?(("Right"===t.direction&&n.point.xt.point.x)&&(i+=n.corners.top-t.corners.top),i+=n.point.y-n.corners.top):i+=void 0!==e&&"Left"!==e&&"Right"===t.direction&&n.point.xt.corners.left-t.margin.left&&n.corners.left-n.margin.left<=t.corners.right+t.margin.right?(("Bottom"===t.direction&&n.point.yt.point.y)&&(i+=n.corners.left-t.corners.left),i+=n.point.x-n.corners.left):i+=void 0!==e&&"Top"!==e&&"Bottom"===t.direction&&n.point.y=t.corners.left-t.margin.left?(("Bottom"===t.direction&&n.point.yt.point.y)&&(e+=t.corners.right-n.corners.right),e+=n.corners.right-n.point.x):e+=void 0!==i&&"Top"!==i&&"Bottom"===t.direction&&n.point.y=t.corners.top-t.margin.top?(("Right"===t.direction&&n.point.xt.point.x)&&(e+=t.corners.bottom-n.corners.bottom),e+=n.corners.bottom-n.point.y):e+=void 0!==i&&"Left"!==i&&"Right"===t.direction&&n.point.xf&&d=u&&d=p&&d<=f?"Left":"Right"}function ls(n){switch(n){case"Top":return"Bottom";case"Bottom":return"Top";case"Left":return"Right";case"Right":return"Left"}return"auto"}var A3=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Ac=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},AI=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return A3(t,n),Ac([I()],t.prototype,"width",void 0),Ac([I()],t.prototype,"height",void 0),t}(Ee),Gre=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return A3(t,n),Ac([I()],t.prototype,"width",void 0),Ac([I()],t.prototype,"height",void 0),Ac([I()],t.prototype,"fit",void 0),Ac([I()],t.prototype,"description",void 0),Ac([I()],t.prototype,"template",void 0),Ac([I()],t.prototype,"tooltip",void 0),t}(Ee),Xre=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Ol=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},L3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Xre(t,n),Ol([I("")],t.prototype,"id",void 0),Ol([I(Number.MIN_VALUE)],t.prototype,"zIndex",void 0),Ol([re({},$n)],t.prototype,"margin",void 0),Ol([I(!0)],t.prototype,"visible",void 0),Ol([re({},xd)],t.prototype,"tooltip",void 0),Ol([I(!1)],t.prototype,"excludeFromLayout",void 0),Ol([I()],t.prototype,"addInfo",void 0),Ol([I("None")],t.prototype,"flip",void 0),Ol([I("All")],t.prototype,"flipMode",void 0),Ol([re({},Gre)],t.prototype,"symbolInfo",void 0),t}(Ee),qre=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Jn=function(n){function t(e,i,r,s){var o=n.call(this)||this;return o.data="",o.nodeId="",o.annotationId="",o.diagramId="",o.diagramId=i,o.nodeId=e,o.annotationId=r,o.templateFn=GF(s),o}return qre(t,n),t.prototype.getNodeTemplate=function(){return this.templateFn},Object.defineProperty(t.prototype,"content",{get:function(){return this.data},set:function(e){this.data=e,this.canReset||(this.canReset=!0,this.isTemplate||(this.template=Bh(this,!0)),this.canReset=!1,this.isDirt=!0)},enumerable:!0,configurable:!0}),t}(as),Bx=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),hs=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},N3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Bx(t,n),hs([I("")],t.prototype,"id",void 0),hs([I("transparent")],t.prototype,"fill",void 0),hs([I("black")],t.prototype,"iconStrokeColor",void 0),hs([I(0)],t.prototype,"iconStrokeWidth",void 0),hs([I(!0)],t.prototype,"visibility",void 0),hs([I(10)],t.prototype,"width",void 0),hs([I(10)],t.prototype,"height",void 0),hs([I("transparent")],t.prototype,"handleStrokeColor",void 0),hs([I(1)],t.prototype,"handleStrokeWidth",void 0),hs([I("")],t.prototype,"pathData",void 0),hs([I(0)],t.prototype,"cornerRadius",void 0),hs([re({left:0,right:0,top:0,bottom:0},$n)],t.prototype,"padding",void 0),hs([re({},xd)],t.prototype,"tooltip",void 0),t}(Ee),O3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Bx(t,n),hs([re({x:0,y:0},z)],t.prototype,"offset",void 0),hs([re({},$n)],t.prototype,"margin",void 0),t}(N3),LI=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Bx(t,n),hs([I(.5)],t.prototype,"offset",void 0),hs([I("Center")],t.prototype,"alignment",void 0),hs([re({x:0,y:0},z)],t.prototype,"displacement",void 0),t}(N3);function Td(n){return n?n instanceof Zn||n instanceof Nr?n.constraints&Lr.Select:n instanceof de?n.constraints&qe.Select:n.constraints&ie.Select:1}function to(n){return n?n instanceof Zn||n instanceof Nr?n.constraints&Lr.Drag:n instanceof de?n.constraints&qe.Drag:n instanceof si?1:n.constraints&ie.Drag:1}function $re(n,t){return n instanceof de?n.constraints&qe.PointerEvents:n.constraints&ie.PointerEvents}function NI(n){return n instanceof de?n.constraints&qe.Delete:n.constraints&ie.Delete}function OI(n){return n.constraints&qe.DragSourceEnd}function kI(n){return n.constraints&qe.DragTargetEnd}function PI(n){return n.constraints&qe.DragSegmentThumb}function zI(n){return n instanceof Zn||n instanceof Nr?n.constraints&Lr.Rotate:n.constraints&ie.Rotate}function RI(n){return n.constraints&ie.Shadow}function da(n){return n instanceof te&&n.constraints&ie.InConnect?n.constraints&ie.InConnect:0}function Oh(n){return n&&n.constraints&&!(n.constraints&ri.None)&&n.constraints&ri.InConnect?n.constraints&ri.InConnect:0}function kh(n){return n instanceof te&&n.constraints&ie.OutConnect?n.constraints&ie.OutConnect:0}function Ad(n){return n&&n.constraints&&!(n.constraints&ri.None)&&n.constraints&ri.OutConnect?n.constraints&ri.OutConnect:0}function kl(n,t){var e=0;return n instanceof Zn||n instanceof Nr?e=n.constraints&Lr.Resize:n&&("SouthEast"===t?e=n.constraints&ie.ResizeSouthEast:"East"===t?e=n.constraints&ie.ResizeEast:"NorthEast"===t?e=n.constraints&ie.ResizeNorthEast:"South"===t?e=n.constraints&ie.ResizeSouth:"North"===t?e=n.constraints&ie.ResizeNorth:"SouthWest"===t?e=n.constraints&ie.ResizeSouthWest:"West"===t?e=n.constraints&ie.ResizeWest:"NorthWest"===t&&(e=n.constraints&ie.ResizeNorthWest)),e}function HI(n){return n instanceof de?n.constraints&qe.AllowDrop:n.constraints&ie.AllowDrop}function Ds(n){return n.constraints&rt.Virtualization}function jv(n){return n.tool&Ci.SingleSelect}function Vv(n){return n.tool&Ci.MultipleSelect}function Lc(n){return n.tool&Ci.ZoomPan}function BI(n){return n.tool&Ci.ContinuousDraw}function k3(n){return n.tool&Ci.DrawOnce}function FI(n){return n.tool&Ci.SingleSelect||n.tool&Ci.MultipleSelect}function Wv(n){return n.constraints&rt.UserInteraction}function P3(n){return n.constraints&rt.ZoomTextEdit}function Yv(n){return function ine(n){return n.constraints&rt.ApiUpdate}(n)||n.diagramActions&ee.ToolAction}function Fx(n,t){return n.constraints&ri.Draw}function _x(n,t){return n.constraints&ri.Drag}function _I(n){return!(n&Qa.DrawSelectorBorder)}function z3(n){return!!(n&Qa.PreventRenderSelector)}var Ux=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Qv=function(n){function t(){var e=null!==n&&n.apply(this,arguments)||this;return e.childTable=[],e.cellStyle={},e.desiredRowHeight=[],e.desiredCellWidth=[],e}return Ux(t,n),t.prototype.rowDefinitions=function(){return this.rowDefns},t.prototype.columnDefinitions=function(){return this.colDefns},t.prototype.addObject=function(e,i,r,s,o){if(this.rows.length>=i){var a=this.rows[parseInt(i.toString(),10)];if(a.cells.length>r){o=o||1,s=s||1;var l=a.cells[parseInt(r.toString(),10)];l.columnSpan=Math.max(o,l.columnSpan),l.rowSpan=Math.max(s,l.rowSpan);var h=new ane;(h=e).rowId=i,h.columnId=r,h.columnSpan=o,this.childTable[h.id]=h,this.addObjectToCell(h,l)}}},t.prototype.addObjectToCell=function(e,i){i.children||(i.children=[]),e.style.strokeColor="black",e.style.strokeWidth=1,i.children.push(e)},t.prototype.updateProperties=function(e,i,r,s){this.offsetX=e,this.offsetY=i,this.width=r,this.height=s},t.prototype.setDefinitions=function(e,i){this.rowDefns=e,this.colDefns=i,this.children=[],this.rows=this.rows||[];for(var r=0;r0){for(var h=0;hi&&this.updateRowHeight(e,l,!1)}},t.prototype.setTextRefresh=function(e){if(e.children&&e.children.length)for(var i=e.children,r=0;ri&&this.updateColumnWidth(e,a,!1)}},t.prototype.calculateCellWidth=function(e){for(var i,r,s,o=0;os.bounds.width&&(0===s.children.length||void 0===s.children[0].maxWidth)?s.outerBounds.width:s.bounds.width,i=i?is.bounds.height?s.outerBounds.height:s.bounds.height,i=i?i0?e.children[0]:void 0;if(a&&1===e.columnSpan){o="Width"===i?a.bounds.right:a.bounds.bottom,s||(s="Width"===i?a.bounds.width:a.bounds.height);for(var l=0;lo){var d=c-o+("Width"===i?a.bounds.width:a.bounds.height);s&&(s=s0?this.rowDefns.splice(e,0,i):this.rowDefns.push(i);var s=new R3;s.cells=[],(new Ld).width=this.width,this.addCellInRow(this.colDefns,i,s),e>this.rows.length-1?this.rows.push(s):this.rows.splice(e,0,s),r&&(this.measure(new me(this.width,this.height)),this.arrange(this.desiredSize))},t.prototype.addColumn=function(e,i,r){var s,o,a,l,h=this.rows;this.colDefns.length>0?this.colDefns.splice(e,0,i):this.colDefns.push(i),void 0!==this.width&&(this.width+=i.width);for(var c=0;cs.cells.length-1?s.cells.push(l):s.cells.splice(e,0,l),this.children.push(l);r&&(this.measure(new me(this.width,this.height)),this.arrange(this.desiredSize))},t.prototype.removeRow=function(e){var i,r,o=this.rows[parseInt(e.toString(),10)];this.height-=this.rowDefns[parseInt(e.toString(),10)].height;for(var a=0;a0){var r=0,s=0;i=new me(0,0),this.calculateSize();for(var o=0,a=this.rows;o0){for(var o=this.offsetX-e.width*this.pivot.x,a=this.offsetY-e.height*this.pivot.y,l=o,h=0,c=this.rows;h1&&this.children.splice(this.children.indexOf(f)+1,f.columnSpan-1),f.rowSpan>1)for(y=s,S=0;y+f.rowSpan-10){for(var c=0;c0?1:0,v=0;v0||a.outEdges.length>0))for(p=a.inEdges.concat(a.outEdges),s=0;s0)for(o=0;o1)for(a=1;a0))if(h=n.wrapper.children[0],"Horizontal"===e.orientation)for(o=e.header&&e.hasHeader?h.rows[1]:h.rows[0],r=0;r0){var e=void 0;t.lineRoutingModule&&t.constraints&rt.LineRouting&&t.lineRoutingModule.renderVirtualRegion(t,!0);for(var i=0;i0?o+1:o)].height=t.wrapper.height;else if(t.isPhase)for(l[t.rowIndex-o].offset=t.wrapper.height,f=0;f0?1:0)].width=t.wrapper.width}function jI(n,t){var i=n.shape,r=i.header&&i.hasHeader?1:0;return"Horizontal"===i.orientation?t.rowIndex-(r+=i.phases.length>0?1:0):t.columnIndex-(i.phaseSize&&i.phases.length>0?1:0)}function VI(n){var t=0,e=n.shape;return"Horizontal"===e.orientation&&(t=e.header&&e.hasHeader?1:0),e.phases.length>0&&e.phaseSize&&(t+=1),t}function WI(n,t,e,i){var r=n.shape;if(r.phases.length>0){var s=t.nameTable[r.phases[parseInt(i.toString(),10)].header.id];s&&s.maxWidth0?u+1:u);var w=Nc(n,o),C=void 0!==i?i:l.lanes.length;if(u+=C,r={element:M,cause:n.diagramActions,diagramAction:n.getDiagramAction(n.diagramActions),state:"Changing",type:"Addition",cancel:!1,laneIndex:C},n.triggerEvent(Ce.collectionChange,r),!r.cancel){if(c){var D=new Gv;D.height=e.height,o.addRow(u,D,!1),s.height=void 0!==s.height?s.height+e.height:s.height,s.wrapper.height=o.height=s.height}else{var A=new Ld;A.width=e.width,o.addColumn(C+1,A,!1),s.width&&(s.width+=e.width,s.wrapper.width=o.width=s.width),n.diagramActions&ee.UndoRedo||(o.rows[0].cells[0].columnSpan+=1)}n.diagramActions&ee.UndoRedo||(M.id=""===M.id?Qe():M.id),void 0!==i?l.lanes.splice(i,0,M):l.lanes.push(M),r={element:M,cause:n.diagramActions,diagramAction:n.getDiagramAction(n.diagramActions),state:"Changed",type:"Addition",cancel:!1,laneIndex:C},n.triggerEvent(Ce.collectionChange,r),B3(o,n,s,u,C,c),h="Horizontal"===l.orientation?n.nameTable[o.rows[parseInt(u.toString(),10)].cells[0].children[0].id]:l.header&&l.hasHeader?n.nameTable[o.rows[1].cells[parseInt(u.toString(),10)].children[0].id]:n.nameTable[o.rows[0].cells[parseInt(u.toString(),10)].children[0].id],n.diagramActions&ee.UndoRedo||(d={type:"LaneCollectionChanged",changeType:"Insert",undoObject:$(M),redoObject:$(h),category:"Internal"},n.addHistoryEntry(d)),$p(n,s,"Horizontal"===l.orientation?u:l.header&&l.hasHeader?1:0),qp(s),Oc(n,s);var R=!1;if((p=e.children)&&p.length>0)for(f=0;f0){var o=t.children[0],a=n.nameTable[o.id];(function vne(n,t,e){return n.left-(e.left||0)<=t.x&&n.right+(e.right||0)>=t.x&&n.top-(e.top||0)<=t.y&&n.bottom+(e.bottom||0)>=t.y})(o.bounds,e,r)&&(n.addChild(a,i),s=!0)}return s}function mne(n,t,e){if("SwimLane"===t.shape.type){var i=void 0,r=void 0,s=void 0,a=void 0,l=void 0,h=void 0,c=t.wrapper.bounds.x,d=t.wrapper.bounds.y,u=t.shape,p=u.padding,f=u.phases,g=void 0,v=t.wrapper.children[0],y="Horizontal"===u.orientation;if(i=u.header&&u.hasHeader?0:-1,u.phases.length>0&&(i+=1),e.offset>(y?u.lanes[0].header.width:u.lanes[0].header.height)){for(h=0;he.offset){if(g=h>0?e.offset-(h>0?f[h-1]:s).offset:e.offset,y){var b=v.columnDefinitions()[parseInt(h.toString(),10)];b.width-=g,(a=n.nameTable[u.phases[parseInt(h.toString(),10)].header.id]).maxWidth=a.wrapper.maxWidth=b.width,v.updateColumnWidth(h,b.width,!1);var M=new Ld;M.width=g,l=h,v.addColumn(h,M,!1);break}var w=v.rowDefinitions()[h+i];w.height-=g,a=n.nameTable[u.phases[parseInt(h.toString(),10)].header.id],v.updateRowHeight(h+i,w.height,!1);var C=new Gv;C.height=g,l=h,v.addRow(h+i,C,!1);break}if(n.diagramActions&ee.UndoRedo&&void 0===l&&(D=n.historyManager.currentEntry.next).isLastPhase&&function yne(n,t,e,i,r,s){var a=t.shape.phases[n-2],l=e.previousPhase.offset;if(r){var h=i.columnDefinitions()[n-1],c=new Ld;n>1?(c.width=h.width-(l-a.offset),h.width=l-a.offset):(c.width=h.width-l,h.width=l),i.updateColumnWidth(n-1,h.width,!1),i.addColumn(n,c,!1)}else{h=i.rowDefinitions()[parseInt(n.toString(),10)];var d=new Gv;n>1?(d.height=e.undoObject.offset-l,h.height=l-a.offset):(d.height=h.height-l,h.height=l),i.updateRowHeight(n,h.height,!1),i.addRow(1+n,d,!1)}}(l=f.length,t,D,v,y),l>=0){var A=new ub(t.shape,"phases",e,!0);if(n.diagramActions&ee.UndoRedo||(A.id+=Qe()),u.phases.splice(l,0,A),jx(v,n,t,i,y,l),y){if(r=n.nameTable[v.rows[parseInt(i.toString(),10)].cells[parseInt(l.toString(),10)].children[0].id],0===l&&u.header&&u.hasHeader){v.rows[0].cells[0].children=v.rows[0].cells[1].children,v.rows[0].cells[1].children=[];for(var x=v.rows[0],R=0;Rl+1){var O=n.nameTable[v.rows[parseInt(i.toString(),10)].cells[l+1].children[0].id];v.updateColumnWidth(l+1,L[l+1].width,!0,p),O.maxWidth=O.wrapper.maxWidth=L[l+1].width}t.width=t.wrapper.width=t.wrapper.children[0].width=v.width}else{r=n.nameTable[v.rows[i+l].cells[0].children[0].id];var N=v.rowDefinitions(),T=N[i+l].height;(function Ine(n,t,e,i,r){for(var o,a,l=e.rows[parseInt(i.toString(),10)],h=e.rows[i+1],c=e.rows[i-1],d=1;di+l+1&&v.updateRowHeight(i+l+1,T=N[i+l+1].height,!0,p),t.height=t.wrapper.height=t.wrapper.children[0].height=v.actualSize.height}if(qp(t),t.width=t.wrapper.actualSize.width,Oc(n,t),n.drag(t,c-t.wrapper.bounds.x,d-t.wrapper.bounds.y),UI(t,n),n.commandHandler.select(r),!(n.diagramActions&ee.UndoRedo)){var D={type:"PhaseCollectionChanged",changeType:"Insert",undoObject:$(A),redoObject:$(r),category:"Internal"};n.addHistoryEntry(D)}n.updateDiagramObject(t)}}}}function V3(n,t,e,i,r,s,o){var a,l,f,h=t.shape,c="Horizontal"===h.orientation,d=t.wrapper.children[0],g=c?s:o;e?(a=c?e.bounds.x+e.bounds.width:e.bounds.x,l=c?e.bounds.y:e.bounds.y+e.bounds.height):(a=d.bounds.x,l=r.bounds.y);var v=new Ne(a,l,i.desiredCellWidth,i.desiredCellHeight),S=Xv(n,0,t,{id:t.id+(c?h.lanes[g-2]:h.lanes[g-1]).id+Qe()[0],rowIndex:s,columnIndex:o,width:i.minWidth,height:i.minHeight,style:(c?h.lanes[g-2]:h.lanes[g-1]).style,constraints:ie.Default|ie.AllowDrop,container:{type:"Canvas",orientation:c?"Horizontal":"Vertical"}},!1,!1,!0);if(S.children[0].isCalculateDesiredSize=!1,d.addObject(S,s,o),r&&r.children&&r.children.length)for(f=0;f1)for(var f=1;fh.margin.left&&(h.margin.left=p)):(h.margin.top-=e.desiredCellHeight,p>h.margin.top&&(h.margin.top=p)))}(n,r,i,v,S,c,e)}function W3(n,t,e){if("SwimLane"===t.shape.type&&("ResizeSouth"===e||"ResizeEast"===e)){var i=t.shape,r=t.wrapper.children[0],s=void 0,o=void 0;"ResizeSouth"===e?"Vertical"===i.orientation?s=r.rows[r.rows.length-1].cells[0]:(o=r.rows.length-1,s=r.rows[parseInt(o.toString(),10)].cells[r.rows[parseInt(o.toString(),10)].cells.length-1]):(o=i.header&&i.hasHeader?1:0,s=r.rows[parseInt(o.toString(),10)].cells[r.rows[parseInt(o.toString(),10)].cells.length-1]),n.commandHandler.select(n.nameTable[s.children[0].id])}}function YI(n,t,e,i,r,s){var o,a,l,c,u,p,f,d=Qe(),g=n.shape,v=g.phases,y=n.offsetX-n.wrapper.actualSize.width/2,S=n.offsetY-n.wrapper.actualSize.height/2;if("Vertical"===g.orientation&&(S+=g.header&&g.hasHeader?g.header.height:0),!s)for(r||(n.id+=d,g&&g.header&&g.hasHeader?g.header.id+=d:g.header=void 0),o=0;v&&o0&&s.columnIndex>0||s.isLane)?(a=function Lne(n,t,e){for(var i=new Ne,r="SwimLane"===n.shape.type?n.wrapper.children[0].rows:n.wrapper.rows,s=e?1:0;s=0;a--)i?i.id===o.children[parseInt(a.toString(),10)].id&&o.children.splice(a,1):(n.removeDependentConnector(o.children[parseInt(a.toString(),10)]),n.diagramActions&ee.UndoRedo||(n.diagramActions=n.diagramActions|ee.UndoRedo,s=!0),n.remove(o.children[parseInt(a.toString(),10)]),o.children.splice(a,1),s&&(n.diagramActions=n.diagramActions&~ee.UndoRedo))}function Mne(n){return n.children[0]}function Zv(n,t){t&&(n.nodes.splice(n.nodes.indexOf(t),1),n.removeFromAQuad(t),n.removeObjectsFromLayer(t),delete n.nameTable[t.id],n.removeElements(t))}function Q3(n,t,e,i){var r;if("SwimLane"===e.shape.type){var s=e.shape,o=void 0;if(1===s.lanes.length)n.remove(e);else{var a=e.wrapper.bounds.x,l=e.wrapper.bounds.y,h=void 0,c=void 0,d=void 0,u=void 0,f=e.wrapper.children[0];if(o=i?s.lanes.indexOf(i):jI(e,t),r={element:t,cause:n.diagramActions,diagramAction:n.getDiagramAction(n.diagramActions),state:"Changing",type:"Removal",cancel:!1,laneIndex:o},n.triggerEvent(Ce.collectionChange,r),!r.cancel){var g=s.lanes[parseInt(o.toString(),10)],v=g.children;g.children=[];for(var y=0;y0)for(u=0;u0)for(u=0;u0)for(e=0;e1){c===l.phases.length-1&&(o=!0,a=$(l.phases[c-1]));var u=$(l.phases[parseInt(c.toString(),10)]);if(l.phases.splice(c,1),!(n.diagramActions&ee.UndoRedo)){var p={type:"PhaseCollectionChanged",changeType:"Remove",undoObject:u,previousPhase:a,redoObject:$(t),category:"Internal",isLastPhase:o};n.addHistoryEntry(p)}"Horizontal"===l.orientation?function Cne(n,t,e,i){var r,s,o,a,l,h,c,d,u,p,f,g;for(i=void 0!==i?i:e.columnIndex,c=0;c1&&(s=r.cells[parseInt(i.toString(),10)],l=(o=r.cells.length-1===i?r.cells[i-1]:r.cells[i+1]).children[0],s.children.length>0))if(f=n.nameTable[(a=s.children[0]).id],0===o.children.length&&s.children.length>0)o.children=s.children,o.columnSpan=s.columnSpan-1;else{for(d=0;d0){var M=s.children[0],w=n.nameTable[M.id];if(i=e.x&&a.bounds.y<=e.y&&a.bounds.bottom>=e.y)&&!(t.constraints&ie.AllowMovingOutsideLane)){var l=$(t);n.clearSelection(),$3(n,t),t.parentId="",t.parentObj=n,t.propName="nodes";var h={type:"ChildCollectionChanged",category:"Internal",undoObject:l,redoObject:$(t)};n.addHistoryEntry(h),n.commandHandler.isContainer&&(n.commandHandler.isContainer=!1,n.endGroupAction()),Z3(t,n)}n.protectPropertyChange(o)}}function QI(n,t){var e,i,r;return n.enableServerDataBinding(!1),ce()||(n.selectedObject.helperObject?r=n.selectedObject.helperObject:(n.selectedItems.nodes.length>0||n.selectedItems.connectors.length>0)&&(t instanceof si&&t.nodes.length+t.connectors.length===1?(e=t.nodes.length>0?t.nodes[0]:t.connectors[0],i=n.selectedItems.wrapper.children[0]):(e=t,i=n.selectedItems.wrapper),n.selectedObject.actualObject=e,!n.currentSymbol&&(e.isLane&&Qx(e,n)&&cs(n,e)||!e.isLane&&cs(n,e)||n.constraints&rt.LineRouting&&n.selectedItems.nodes.length>0))&&(r=function Nne(n,t){for(var e,i={},r=0,s=Object.keys(t);r=t.x-e&&n.x<=t.x+e&&n.y>=t.y-e&&n.y<=t.y+e}function Xa(n){return n.selectedItems.nodes.length>0||n.selectedItems.connectors.length>0}function K3(n){return 1===n.selectedItems.connectors.length&&!n.selectedItems.nodes.length}function _r(n,t,e,i){if(void 0===e&&(e=!0),t instanceof si)return!0;if(t instanceof te)for(;t;){if(-1!==n.selectedItems.nodes.indexOf(t)&&void 0===n.selectedItems.annotation)return!0;if(e)break;t=n.nameTable[t.parentId]}else if(t instanceof de){if(-1!==n.selectedItems.connectors.indexOf(t)&&void 0===n.selectedItems.annotation)return!0}else if((t instanceof Zn||t instanceof Nr)&&n.selectedItems.annotation&&n.selectedItems.wrapper.children[0].id===i.id)return!0;return!1}var Gx={None:"default",Rotate:"crosshair",Select:"default",Drag:"move",ResizeWest:"w-resize",ResizeEast:"e-resize",ResizeSouth:"s-resize",ResizeNorth:"n-resize",Draw:"crosshair",PortDraw:"crosshair",ResizeNorthEast:"ne-resize",ResizeNorthWest:"nw-resize",ResizeSouthEast:"se-resize",ResizeSouthWest:"sw-resize",ConnectorSourceEnd:"move",ConnectorTargetEnd:"move",BezierSourceThumb:"move",BezierTargetThumb:"move",OrthoThumb:"move",SegmentEnd:"move",Pan:"grab",Hyperlink:"pointer",PortDrag:"pointer",LabelSelect:"pointer",LabelDrag:"move",LabelRotate:"crosshair",LabelResizeWest:"w-resize",LabelResizeEast:"e-resize",LabelResizeSouth:"s-resize",LabelResizeNorth:"n-resize",LabelResizeNorthEast:"ne-resize",LabelResizeNorthWest:"nw-resize",LabelResizeSouthEast:"se-resize",LabelResizeSouthWest:"sw-resize"},ds=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Od=function(n,t,e,i){return new(e||(e=Promise))(function(r,s){function o(h){try{l(i.next(h))}catch(c){s(c)}}function a(h){try{l(i.throw(h))}catch(c){s(c)}}function l(h){h.done?r(h.value):new e(function(c){c(h.value)}).then(o,a)}l((i=i.apply(n,t||[])).next())})},kd=function(n,t){var i,r,s,o,e={label:0,sent:function(){if(1&s[0])throw s[1];return s[1]},trys:[],ops:[]};return o={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function a(h){return function(c){return function l(h){if(i)throw new TypeError("Generator is already executing.");for(;e;)try{if(i=1,r&&(s=2&h[0]?r.return:h[0]?r.throw||((s=r.return)&&s.call(r),0):r.next)&&!(s=s.call(r,h[1])).done)return s;switch(r=0,s&&(h=[2&h[0],s.value]),h[0]){case 0:case 1:s=h;break;case 4:return e.label++,{value:h[1],done:!1};case 5:e.label++,r=h[1],h=[0];continue;case 7:h=e.ops.pop(),e.trys.pop();continue;default:if(!(s=(s=e.trys).length>0&&s[s.length-1])&&(6===h[0]||2===h[0])){e=0;continue}if(3===h[0]&&(!s||h[1]>s[0]&&h[1]-1&&(r=i.fixedUserHandles[parseInt(o.toString(),10)]);this.commandHandler.triggerEvent(Ce.fixedUserHandleClick,{fixedUserHandle:r,element:e.source}),n.prototype.mouseUp.call(this,e)},t}(us),Pd=function(n){function t(e,i){var r=n.call(this,e,!0)||this;return r.isConnected=!1,r.endPoint=i,r}return ds(t,n),t.prototype.mouseDown=function(e){return Od(this,void 0,void 0,function(){var r,s,o,a,l;return kd(this,function(h){if(this.inAction=!0,this.undoElement=void 0,this instanceof pa||(this.undoElement=$(e.source)),n.prototype.mouseDown.call(this,e),e.source&&e.source.connectors&&(this.oldConnector=$(r=e.source.connectors[0])),"BezierSourceThumb"===this.endPoint||"BezierTargetThumb"===this.endPoint)for(s=0;s0))},t.prototype.endAction=function(){n.prototype.endAction.call(this),this.prevPosition=null,this.endPoint=null},t}(us),ua=function(n){function t(e,i){var r=n.call(this,e,!0)||this;return r.currentTarget=null,r.isStartAction=!1,r.canCancel=!1,r.canTrigger=!1,r.objectType=i,r}return ds(t,n),t.prototype.mouseDown=function(e){if(e.source instanceof te||e.source instanceof de){var i=this.commandHandler.getSelectedObject();this.commandHandler.selectObjects([e.source],e.info&&e.info.ctrlKey,i);var r={nodes:[],connectors:[]};e.source instanceof te?r.nodes.push($(e.source)):r.connectors.push($(e.source)),this.undoElement=$(r)}else this.undoElement=$(e.source);this.undoParentElement=this.commandHandler.getSubProcess(e.source),"Port"===this.objectType&&(this.portId=e.sourceWrapper.id),this.commandHandler.insertBlazorConnector(e.source),n.prototype.mouseDown.call(this,e),this.initialOffset={x:0,y:0}},t.prototype.mouseUp=function(e,i){return Od(this,void 0,void 0,function(){var s,o,a,l,h,c,d,u,f,g,v,y,S,b,M;return kd(this,function(w){if(this.checkPropertyValue(),a=!1,h={nodes:[],connectors:[]},"Port"!==this.objectType){if(e.source instanceof te||e.source instanceof de?(e.source instanceof te?h.nodes.push($(e.source)):h.connectors.push($(e.source)),(o=$(h)).offsetX=(c=e.source.wrapper).offsetX,o.offsetY=c.offsetY):o=$(e.source),("helper"===(l=this.commandHandler.renderContainerHelper(e.source)||e.source||this.commandHandler.renderContainerHelper(e.source)).id||"helper"!==l.id)&&((l instanceof si&&(Math.round(l.width)===Math.round(this.undoElement.width)&&Math.round(l.height)===Math.round(this.undoElement.height)||l.selectedObjects&&1===l.selectedObjects.length)||!(l instanceof si))&&(l.offsetX!==this.undoElement.offsetX||l.offsetY!==this.undoElement.offsetY||l.sourcePoint!==this.undoElement.sourcePoint||l.targetPoint!==this.undoElement.targetPoint)||this.isSelectionHasConnector(l))&&(e.source&&(s={offsetX:e.source.wrapper.offsetX,offsetY:e.source.wrapper.offsetY}),g={source:e.source,state:"Completed",oldValue:this.intialValue,newValue:s,target:this.currentTarget,targetPosition:this.currentPosition,allowDrop:(g={source:e.source,state:"Completed",oldValue:this.intialValue,newValue:s,target:this.currentTarget,targetPosition:this.currentPosition,allowDrop:!0,cancel:!1}).allowDrop,cancel:g.cancel},d=!0,"helper"===l.id?this.canTrigger?(this.commandHandler.triggerEvent(Ce.positionChange,g),this.connectorEndPointChangeEvent(g),d=!0):d=!1:(this.commandHandler.triggerEvent(Ce.positionChange,g),this.connectorEndPointChangeEvent(g)),!i&&d&&(this.commandHandler.startGroupAction(),a=!0,M={type:"PositionChanged",redoObject:$(o),undoObject:$(this.undoElement),category:"Internal"},o.nodes[0]&&o.nodes[0].processId&&(u={type:"SizeChanged",category:"Internal",undoObject:this.undoParentElement,redoObject:this.commandHandler.getSubProcess(e.source)},this.commandHandler.addHistoryEntry(u)),this.commandHandler.addHistoryEntry(M))),this.commandHandler.snapPoint(this.prevPosition,this.currentPosition,0,0),this.commandHandler.removeSnap(),this.commandHandler.removeHighlighter(),e.source&&this.currentTarget&&HI(this.currentTarget)&&this.commandHandler.isDroppable(e.source,this.currentTarget)){if(f=!0,this.commandHandler.drop(this.currentElement,this.currentTarget,this.currentPosition),this.currentTarget&&this.currentTarget instanceof de&&!0===this.commandHandler.diagram.enableConnectorSplit)if(this.currentElement&&this.currentElement instanceof te){if(void 0!==this.currentElement.children)for(b=0;b0)for(var s=0;s0)for(var a=0;a0)for(a=0;a0&&e.connectors.length>0)||e.width===this.undoElement.width&&e.height===this.undoElement.height)},t.prototype.mouseMove=function(e){n.prototype.mouseMove.call(this,e);var r,s,i=!1;(r=this.commandHandler.renderContainerHelper(e.source)||e.source)instanceof te||r instanceof de?r instanceof te?r.offsetX===this.undoElement.nodes[0].offsetX&&r.offsetY===this.undoElement.nodes[0].offsetY&&(i=!0):z.equals(r.sourcePoint,this.undoElement.connectors[0].sourcePoint)&&z.equals(r.targetPoint,this.undoElement.connectors[0].targetPoint)&&(i=!0):r.wrapper.offsetX===this.undoElement.wrapper.offsetX&&r.wrapper.offsetY===this.undoElement.wrapper.offsetY&&(i=!0),r&&(s={offsetX:r.wrapper.offsetX,offsetY:r.wrapper.offsetY});var o={source:r,state:"Start",oldValue:s,newValue:s,target:e.target,targetPosition:e.position,allowDrop:!0,cancel:!1};if(o={source:r,state:"Start",oldValue:s,newValue:s,target:e.target,targetPosition:e.position,allowDrop:o.allowDrop,cancel:o.cancel},this.isStartAction||(this.intialValue={offsetX:r.wrapper.offsetX,offsetY:r.wrapper.offsetY}),i&&!ce()&&(this.commandHandler.triggerEvent(Ce.positionChange,o),this.connectorEndPointChangeEvent(o),this.isStartAction=!0),this.currentPosition=e.position,"Port"!==this.objectType){var h=this.initialOffset.x+(this.currentPosition.x-this.prevPosition.x),c=this.initialOffset.y+(this.currentPosition.y-this.prevPosition.y);this.commandHandler.dragOverElement(e,this.currentPosition),this.commandHandler.disConnect(e.source),this.commandHandler.removeSnap();var d,u=void 0,p=this.commandHandler.snapPoint(this.prevPosition,this.currentPosition,h,c);this.initialOffset.x=h-p.x,this.initialOffset.y=c-p.y,r&&(d={offsetX:r.wrapper.offsetX,offsetY:r.wrapper.offsetY},u={offsetX:r.wrapper.offsetX+p.x,offsetY:r.wrapper.offsetY+p.y}),this.currentTarget&&e.target!==this.currentTarget&&this.commandHandler.removeChildFromBPmn(e.source,e.target,this.currentTarget),this.currentTarget=e.target;var f={source:r,state:"Progress",oldValue:d,newValue:u,target:e.target,targetPosition:e.position,allowDrop:!0,cancel:!1};if(this.commandHandler.triggerEvent(Ce.positionChange,f),this.canTrigger=!0,this.connectorEndPointChangeEvent(f,p),!f.cancel&&!this.canCancel){this.blocked=!this.commandHandler.dragSelectedObjects(p.x,p.y);var g=!this.commandHandler.mouseOver(this.currentElement,this.currentTarget,this.currentPosition);this.blocked=this.blocked||g}if(this.commandHandler.removeStackHighlighter(),this.commandHandler.renderStackHighlighter(e),this.currentTarget&&e.source!==this.currentTarget&&this.commandHandler.isDroppable(e.source,this.currentTarget)&&"helper"!==e.source.id){var v=e.source instanceof si?e.source.nodes[0]:e.source;!this.commandHandler.isParentAsContainer(v,!0)&&"SwimLane"!==v.shape.type&&!v.shape.isPhase&&(this.currentTarget.isLane?this.commandHandler.renderStackHighlighter(e,this.currentTarget):this.commandHandler.drawHighlighter(this.currentTarget))}else this.commandHandler.removeHighlighter();if(this.commandHandler.canEnableDefaultTooltip()){var y=this.getTooltipContent(e.source);this.commandHandler.showTooltip(e.source,e.position,ko(function(){return y}),"MoveTool",this.isTooltipVisible),this.isTooltipVisible=!1}}else{var b=Hi(),M=e.source;qi(b,-M.rotateAngle||-M.wrapper.rotateAngle,M.offsetX||M.wrapper.offsetX,M.offsetY||M.wrapper.offsetY);var w=Je(b,{x:this.prevPosition.x,y:this.prevPosition.y}),C=Je(b,{x:e.position.x,y:e.position.y});this.commandHandler.portDrag(e.source,e.sourceWrapper,C.x-w.x,C.y-w.y)}return this.prevPosition=this.currentPosition,!this.blocked},t.prototype.getTooltipContent=function(e){return"X:"+Math.round(e.wrapper.bounds.x)+" Y:"+Math.round(e.wrapper.bounds.y)},t.prototype.mouseLeave=function(e){this.mouseUp(e)},t.prototype.endAction=function(){n.prototype.endAction.call(this),this.currentTarget=null,this.prevPosition=null},t}(us),Xx=function(n){function t(e){var i=n.call(this,e,!0)||this;return i.rotateStart=!1,i}return ds(t,n),t.prototype.mouseDown=function(e){if(this.undoElement=$(e.source),this.undoElement.nodes[0]&&this.undoElement.nodes[0].children)for(var r=this.commandHandler.getAllDescendants(this.undoElement.nodes[0],[]),s=0;s=2){var s=e.startTouches[0],o=e.startTouches[1],a=e.moveTouches[0],l=e.moveTouches[1],h=this.getDistance(a,l)/this.getDistance(s,o);this.commandHandler.zoom(h,0,0,e.position),this.updateTouch(s,a),this.updateTouch(o,l)}}else this.commandHandler.scroll(this.currentPosition.x-this.prevPosition.x,this.currentPosition.y-this.prevPosition.y,this.currentPosition);return this.commandHandler.dataBinding(),!this.blocked},t.prototype.mouseUp=function(e){this.commandHandler.setBlazorDiagramProps(!1),this.checkPropertyValue(),this.commandHandler.updatePanState(!1),n.prototype.mouseUp.call(this,e),this.inAction=!1},t.prototype.endAction=function(){n.prototype.endAction.call(this)},t.prototype.getDistance=function(e,i){var r=i.pageX-e.pageX,s=i.pageY-e.pageY;return Math.sqrt(r*r+s*s)},t.prototype.updateTouch=function(e,i){e.pageX=i.pageX,e.pageY=i.pageY},t}(us),Une=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseUp=function(e){this.checkPropertyValue(),this.commandHandler.initExpand(e),n.prototype.mouseUp.call(this,e)},t}(us),eF=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseUp=function(e){this.checkPropertyValue();var i="_blank",r="",s=window.innerHeight,o=window.innerWidth,a=window.screenTop,l=window.screenLeft;"CurrentTab"===e.sourceWrapper.hyperlink.hyperlinkOpenState?i="_self":"NewWindow"===e.sourceWrapper.hyperlink.hyperlinkOpenState&&(r="height="+s+",width="+o+",top="+a+",left="+l),window.open(e.sourceWrapper.hyperlink.link,i,r).focus(),n.prototype.mouseUp.call(this,e)},t}(us),Ph=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseDown=function(e){if(n.prototype.mouseDown.call(this,e),this.inAction=!0,this.drawingObject){var r=void 0,s=this.drawingObject.shape;this.drawingObject.shape.points.push(r={x:(r=s.points[s.points.length-1]).x,y:r.y})}else this.startPoint={x:this.startPosition.x,y:this.startPosition.y},this.drawingObject=this.commandHandler.drawObject({offsetX:this.currentPosition.x,offsetY:this.currentPosition.y,width:5,height:5,style:{strokeColor:"black",strokeWidth:1},shape:{type:"Basic",shape:"Polygon",points:[{x:this.startPoint.x,y:this.startPoint.y},{x:this.currentPosition.x,y:this.currentPosition.y}]}})},t.prototype.mouseMove=function(e){if(n.prototype.mouseMove.call(this,e),this.inAction){var i=this.drawingObject.shape;if(i.points[i.points.length-1].x=this.currentPosition.x,i.points[i.points.length-1].y=this.currentPosition.y,this.drawingObject.wrapper.children[0].data=Sx(this.drawingObject.shape.points),this.inAction&&!1===z.equals(this.currentPosition,this.prevPosition)){var r=Ne.toBounds(this.drawingObject.shape.points);this.commandHandler.updateNodeDimension(this.drawingObject,r)}}return!0},t.prototype.mouseUp=function(e,i){this.checkPropertyValue(),n.prototype.mouseMove.call(this,e),this.inAction&&(this.inAction=!1,this.commandHandler.addObjectToDiagram(this.drawingObject)),this.endAction()},t.prototype.mouseWheel=function(e){n.prototype.mouseWheel.call(this,e),this.mouseMove(e)},t.prototype.endAction=function(){this.inAction=!1,this.drawingObject=null},t}(us),zh=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseMove=function(e){if(n.prototype.mouseMove.call(this,e),this.inAction){var i=this.drawingObject;i.targetPoint=this.currentPosition,this.commandHandler.updateConnectorPoints(i)}return!0},t.prototype.mouseDown=function(e){if(n.prototype.mouseDown.call(this,e),this.inAction=!0,this.drawingObject){var r=this.drawingObject,s=void 0;(s=new Pl(r,"segments",{type:"Straight"},!0)).point=this.currentPosition,r.segments[r.segments.length-1]=s}else this.drawingObject=this.commandHandler.drawObject({id:"Connector",type:"Straight",sourcePoint:this.currentPosition,targetPoint:this.currentPosition})},t.prototype.mouseWheel=function(e){n.prototype.mouseWheel.call(this,e),this.mouseMove(e)},t.prototype.mouseUp=function(e){if(this.checkPropertyValue(),n.prototype.mouseMove.call(this,e),this.inAction&&this.drawingObject){var i=this.drawingObject;i.segments[i.segments.length-1].point={x:0,y:0},this.commandHandler.addObjectToDiagram(this.drawingObject)}this.endAction()},t.prototype.endAction=function(){this.drawingObject=null,this.inAction=!1},t}(us),jne=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseDown=function(e){this.inAction=!0,this.undoElement=$(e.source),this.annotationId=e.sourceWrapper.id,n.prototype.mouseDown.call(this,e)},t.prototype.mouseMove=function(e){n.prototype.mouseMove.call(this,e);var i=this.currentPosition.x-this.prevPosition.x,r=this.currentPosition.y-this.prevPosition.y,s=e.source;if(s instanceof te){var o=Hi();qi(o,-s.rotateAngle,0,0);var a=Je(o,{x:i,y:r});i=a.x,r=a.y}return this.inAction&&(this.commandHandler.labelDrag(e.source,e.sourceWrapper,i,r),this.commandHandler.updateSelector()),this.prevPosition=this.currentPosition,!this.blocked},t.prototype.mouseUp=function(e){this.checkPropertyValue();var i=e.source;this.inAction=!1;var r={type:"AnnotationPropertyChanged",objectId:this.annotationId,undoObject:$(this.undoElement),category:"Internal",redoObject:$(i)};this.commandHandler.addHistoryEntry(r),n.prototype.mouseUp.call(this,e)},t.prototype.mouseLeave=function(e){this.mouseUp(e)},t}(us),Vne=function(n){function t(e,i){var r=n.call(this,e,!0)||this;return r.corner=i,r}return ds(t,n),t.prototype.mouseDown=function(e){this.inAction=!0;var i=e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0];this.annotationId=e.source.wrapper.children[0].id,this.undoElement=$(i);var r=e.source.wrapper.children[0];this.initialBounds={x:r.offsetX,y:r.offsetY,width:r.actualSize.width,height:r.actualSize.height},n.prototype.mouseDown.call(this,e)},t.prototype.mouseMove=function(e){return n.prototype.mouseMove.call(this,e),this.inAction&&this.resizeObject(e),!this.blocked},t.prototype.mouseUp=function(e){this.checkPropertyValue();var i=e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0];this.inAction=!1;var r={type:"AnnotationPropertyChanged",objectId:this.annotationId,redoObject:$(i),undoObject:$(this.undoElement),category:"Internal"};this.commandHandler.addHistoryEntry(r),n.prototype.mouseUp.call(this,e)},t.prototype.mouseLeave=function(e){this.mouseUp(e)},t.prototype.resizeObject=function(e){var i,s,o,r=e.source.wrapper.children[0],a={x:r.offsetX,y:r.offsetY},l=r.rotateAngle;l=((l+=(i=e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0])instanceof te?i.rotateAngle:0)+360)%360;var h=Hi();qi(h,l,a.x,a.y);var c=this.corner.slice(5),d=this.updateSize(r,this.startPosition,this.currentPosition,c,this.initialBounds,l),u=r.offsetX-r.actualSize.width*r.pivot.x,p=r.offsetY-r.actualSize.height*r.pivot.y,f=this.getPivot(c),g=Je(h,f={x:u+r.actualSize.width*f.x,y:p+r.actualSize.height*f.y});d.x=g.x,d.y=g.y,this.commandHandler.labelResize(i,e.source.annotation,s=(s=d.width)<0?1:s,o=(o=d.height)<0?1:o,d,e.source),this.commandHandler.updateSelector()},t}(us),Wne=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseDown=function(e){this.inAction=!0,this.annotationId=e.source.wrapper.children[0].id,this.undoElement=$(e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0]),n.prototype.mouseDown.call(this,e)},t.prototype.mouseMove=function(e){return n.prototype.mouseMove.call(this,e),e.source&&this.inAction&&(this.commandHandler.labelRotate(e.source.nodes[0]?e.source.nodes[0]:e.source.connectors[0],e.source.annotation,this.currentPosition,e.source),this.commandHandler.updateSelector()),this.prevPosition=this.currentPosition,!this.blocked},t.prototype.mouseUp=function(e){this.checkPropertyValue(),this.inAction=!1;var r={type:"AnnotationPropertyChanged",objectId:this.annotationId,redoObject:$(e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0]),undoObject:$(this.undoElement),category:"Internal"};this.commandHandler.addHistoryEntry(r),n.prototype.mouseUp.call(this,e)},t.prototype.mouseLeave=function(e){this.mouseUp(e)},t}(us),Yne=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseMove=function(e){if(n.prototype.mouseMove.call(this,e),this.inAction){var i=this.drawingObject.shape;if(i.points.push(this.currentPosition),this.drawingObject.wrapper.children[0].data=Ix(this.drawingObject.shape.points),i.data=Ix(i.points),this.inAction&&!1===z.equals(this.currentPosition,this.prevPosition)){var s=Ne.toBounds(this.drawingObject.shape.points);this.commandHandler.updateNodeDimension(this.drawingObject,s)}}return!0},t.prototype.mouseDown=function(e){n.prototype.mouseDown.call(this,e),this.inAction=!0,this.startPoint={x:this.startPosition.x,y:this.startPosition.y},this.drawingObject=this.commandHandler.drawObject({offsetX:this.currentPosition.x,offsetY:this.currentPosition.y,width:5,height:5,style:{strokeColor:"black",strokeWidth:1,fill:"transparent"},shape:{type:"Path",points:[{x:this.startPoint.x,y:this.startPoint.y},{x:this.currentPosition.x,y:this.currentPosition.y}]}})},t.prototype.mouseUp=function(e){if(this.checkPropertyValue(),this.inAction){this.inAction=!1;var s=this.drawingObject.shape,o=s.points;this.commandHandler.addObjectToDiagram(this.drawingObject),this.commandHandler.diagram.remove(this.commandHandler.diagram.nameTable[""+this.drawingObject.id]),o=this.pointReduction(o,10);var h={id:"newConnector"+Qe(),type:"Bezier",sourcePoint:{x:o[0].x,y:o[0].y},targetPoint:{x:o[o.length-1].x,y:o[o.length-1].y},segments:[],bezierSettings:{allowSegmentsReset:!1}};this.drawingObject=this.commandHandler.drawObject(h),this.drawingObject=this.bezierCurveSmoothness(o,.5,this.drawingObject,s),this.commandHandler.updateConnectorPoints(this.drawingObject),this.commandHandler.addObjectToDiagram(this.drawingObject),n.prototype.mouseUp.call(this,e)}},t.prototype.pointReduction=function(e,i){if(null===e||e.length<3)return e;var s=e.length-1,o=[];for(o.push(0),o.push(s);e[parseInt((0).toString(),10)]===e[parseInt(s.toString(),10)];)s--;this.reduction(e,0,s,i,o);var a=[];return o.sort(function(l,h){return l-h}),o.forEach(function(l){a.push(e[parseInt(l.toString(),10)])}),a},t.prototype.reduction=function(e,i,r,s,o){for(var a=0,l=0,h=i;ha&&(a=c,l=h)}a>s&&0!==l&&(o.push(l),this.reduction(e,i,l,s,o),this.reduction(e,l,r,s,o))},t.prototype.perpendicularDistance=function(e,i,r){return Math.abs(.5*(e.x*i.y-i.x*e.y+(i.x*r.y-r.x*i.y)+(r.x*e.y-e.x*r.y)))/Math.sqrt(Math.pow(e.x-i.x,2)+Math.pow(e.y-i.y,2))*2},t.prototype.bezierCurveSmoothness=function(e,i,r,s){if(e.length<3)return r;for(var o=0;o=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Qne=function(n){if(n)switch(n.type){case"Bpmn":return $ne;case"UmlActivity":return qne;case"UmlClassifier":return Kne;default:return tm}return tm},Gne=function(n){if(n)switch(n.type){case"Straight":default:return Pl;case"Bezier":return ps;case"Orthogonal":return bi}},tF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I(10)],t.prototype,"width",void 0),Pe([I(10)],t.prototype,"height",void 0),Pe([I("Arrow")],t.prototype,"shape",void 0),Pe([re({fill:"black",strokeColor:"black",strokeWidth:1},Ll)],t.prototype,"style",void 0),Pe([re({x:0,y:.5},z)],t.prototype,"pivot",void 0),Pe([I("")],t.prototype,"pathData",void 0),t}(Ee),$I=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I(0)],t.prototype,"angle",void 0),Pe([I(0)],t.prototype,"distance",void 0),t}(Ee),Xne=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I(Cx.All)],t.prototype,"controlPointsVisibility",void 0),Pe([I("FreeForm")],t.prototype,"segmentEditOrientation",void 0),Pe([I(MI.Default)],t.prototype,"smoothness",void 0),Pe([I(!0)],t.prototype,"allowSegmentsReset",void 0),t}(Ee),tm=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I("None")],t.prototype,"type",void 0),t}(Ee),qne=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I("Object")],t.prototype,"flow",void 0),Pe([I(30)],t.prototype,"exceptionFlowHeight",void 0),t}(tm),$ne=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I("Sequence")],t.prototype,"flow",void 0),Pe([I("Normal")],t.prototype,"sequence",void 0),Pe([I("Default")],t.prototype,"message",void 0),Pe([I("Default")],t.prototype,"association",void 0),t}(tm),iF=function(n){function t(e,i,r,s){var o=n.call(this,e,i,r,s)||this;return o.points=[],o}return Qs(t,n),Pe([I("Straight")],t.prototype,"type",void 0),Pe([I(!0)],t.prototype,"allowDrag",void 0),t}(Ee),Pl=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),t.prototype.getClassName=function(){return"StraightSegment"},Pe([re({x:0,y:0},z)],t.prototype,"point",void 0),t}(iF),ps=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),t.prototype.getClassName=function(){return"BezierSegment"},t.prototype.getPoints=function(e,i){var r=[];if(r.length>0||null!=i){var o=this.bezireToPoly(r.length>0?r[r.length-1]:i,e);r.push.apply(r,o)}return r},t.prototype.bezireToPoly=function(e,i){var r=[];return i&&this.flattenCubicBezier(r,e,i.bezierPoint1,i.bezierPoint2,{x:i.points[1].x,y:i.points[1].y},10),r},t.prototype.flattenCubicBezier=function(e,i,r,s,o,a){var h,l=(z.findLength(i,r)+z.findLength(r,s)+z.findLength(s,o))/a;for(h=0;h<=l;h++){var c=h/l;e.push({x:(1-c)*(1-c)*(1-c)*i.x+3*c*(1-c)*(1-c)*r.x+3*c*c*(1-c)*s.x+c*c*c*o.x,y:(1-c)*(1-c)*(1-c)*i.y+3*c*(1-c)*(1-c)*r.y+3*c*c*(1-c)*s.y+c*c*c*o.y})}},Pe([I("Horizontal")],t.prototype,"orientation",void 0),Pe([re({x:0,y:0},z)],t.prototype,"point1",void 0),Pe([re({x:0,y:0},z)],t.prototype,"point2",void 0),Pe([re({angle:0,distance:0},$I)],t.prototype,"vector1",void 0),Pe([re({angle:0,distance:0},$I)],t.prototype,"vector2",void 0),t}(Pl),bi=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),t.prototype.getClassName=function(){return"OrthogonalSegment"},Pe([I(null)],t.prototype,"length",void 0),Pe([I(null)],t.prototype,"direction",void 0),t}(iF);function rF(n,t,e){var s=e?45:180/(2+2/(n.height/n.width)),o=s,a=180-s,l=a+2*s,h=360-s,c=Gt(t,n.center);return c>o&&ca&&cl&&cMath.abs(t.y-n.y)?n.x=c)return s=z.findAngle(n[parseInt(d.toString(),10)],n[d+1]),{point:r=z.transform(n[parseInt(d.toString(),10)],s,c-(a||0)),index:l=d};a=o[parseInt(d.toString(),10)]}return{point:r,index:l}}(n,t),r=z.findAngle(n[i.index],n[i.index+1]),s=function xse(n){var e=0;switch(n.alignment){case"Center":case"After":e=0;break;case"Before":e=-0}return e}(t),o=z.transform(i.point,r+45,s);return i.point=o,i.angle=r,i}(i,e),h=l.point;s.id=this.id+"_"+e.id;var c=e.style;s.style={fill:c.fill,strokeColor:c.strokeColor,gradient:null,opacity:c.opacity,strokeDashArray:c.strokeDashArray,strokeWidth:c.strokeWidth},0===r.width&&(r.width=this.style.strokeWidth),0===r.height&&(r.height=this.style.strokeWidth);var d_y=(h.y-r.y)/r.height;a.x=r.width*((h.x-r.x)/r.width),a.y=r.height*d_y;var g,v,u=SF(e,l.angle,i),p=u.hAlign,f=u.vAlign;return"left"===p?(g="Left",a.x+=e.displacement.x):"right"===p?(g="Right",a.x-=e.displacement.x):"center"===p&&(g="Center"),"top"===f?(v="Top",a.y+=e.displacement.y):"bottom"===f?(v="Bottom",a.y-=e.displacement.y):"center"===f&&(v="Center"),s.horizontalAlignment=g,s.verticalAlignment=v,(s=nm(s,o&&"Label"!==o.flipMode&&"None"!==o.flipMode?this.flip:"None",e)).float=!0,s.connectionDirection=e.connectionDirection,s.setOffsetWithRespectToBounds(a.x,a.y,"Absolute"),s.relativeMode="Point",s.visible=!(!ga(e,hi.Visible)||ga(e,hi.Hover)||ga(e,hi.Connect)),s.elementActions=s.elementActions|Xr.ElementIsPort,s},t.prototype.getConnectorRelation=function(){var e=this.shape;"Association"===e.relationship?(this.segments[0].type="Straight",this.sourceDecorator.shape="None",this.targetDecorator.shape="Arrow"):"Inheritance"===e.relationship?(this.segments[0].type="Orthogonal",this.sourceDecorator.shape="None",this.targetDecorator.shape="Arrow"):"Composition"===e.relationship||"Aggregation"===e.relationship?(this.segments[0].type="Orthogonal",this.sourceDecorator.shape="Diamond",this.targetDecorator.shape="None"):"Dependency"===e.relationship?(this.segments[0].type="Orthogonal",this.sourceDecorator.shape="None",this.targetDecorator.shape="OpenArrow"):"Realization"===e.relationship&&(this.segments[0].type="Orthogonal",this.sourceDecorator.shape="None",this.targetDecorator.shape="Arrow"),"BiDirectional"===e.associationType&&(this.sourceDecorator.shape="None",this.targetDecorator.shape="None");var i,o,r="",s="";e.multiplicity.source&&(e.multiplicity.source.lowerBounds=e.multiplicity.source.lowerBounds,e.multiplicity.source.upperBounds=e.multiplicity.source.upperBounds),e.multiplicity.target&&(e.multiplicity.target.lowerBounds=e.multiplicity.target.lowerBounds,e.multiplicity.target.upperBounds=e.multiplicity.target.upperBounds);var a=e.multiplicity.source,l=e.multiplicity.target;o=a.upperBounds?a.lowerBounds+"..."+a.upperBounds:a.lowerBounds,i=l.upperBounds?l.lowerBounds+"..."+l.upperBounds:l.lowerBounds,"ManyToOne"===e.multiplicity.type&&(e.multiplicity.target.optional=!1,r=o||"*",s="1"),"OneToMany"===e.multiplicity.type&&(e.multiplicity.source.optional=!1,s=i||"*",r="1"),"ManyToMany"===e.multiplicity.type&&(r=o||"*",s=i||"*"),"OneToOne"===e.multiplicity.type&&(e.multiplicity.target.optional=!1,e.multiplicity.source.optional=!1,r="1",s="1"),this.annotations=[{id:this.id+"sourcelabel",content:r,offset:0,alignment:"Before",margin:{right:5,bottom:5}},{id:this.id+"targetlabel",content:s,offset:1,alignment:"Before",margin:{right:5,bottom:5}}]},t.prototype.getBpmnSequenceFlow=function(){var e=new Ke,i=new Ke;return"Normal"===this.shape.sequence&&"Bezier"!==this.type&&(this.targetDecorator.shape="Arrow"),"Default"===this.shape.sequence&&(e=this.getSegmentElement(this,e),i=DF(this.intermediatePoints,this),this.targetDecorator.shape="Arrow"),"Conditional"===this.shape.sequence&&(this.targetDecorator.shape="Arrow",this.sourceDecorator.shape="Diamond",i.id=this.id+this.shape.type),i},t.prototype.getUMLObjectFlow=function(){if(this.annotations)for(var e=0;e0&&(this.sourcePoint=o[0],this.targetPoint=o[o.length-1]),o},t.prototype.clipDecorator=function(e,i,r,s){var a,l,o={x:0,y:0},h=i.length,c=z.distancePoints(a=r?i[0]:i[h-1],l=r?i[1]:i[h-2]);c=0===c?1:c;var d=1,u=r?e.sourceWrapper:e.targetWrapper;u&&(d=u.style.strokeWidth,s&&s&ee.DecoratorPropertyChange&&(d=1));var p=d-1;return o.x=Math.round(a.x+p*(l.x-a.x)/c),o.y=Math.round(a.y+p*(l.y-a.y)/c),(r&&"None"!==e.sourceDecorator.shape||!r&&"None"!==e.targetDecorator.shape)&&(o=z.adjustPoint(o,l,!0,s&ee.DecoratorPropertyChange?0:d/2)),o},t.prototype.clipDecorators=function(e,i,r){return"None"!==e.sourceDecorator.shape&&(i[0]=this.clipDecorator(e,i,!0,r)),"None"!==e.targetDecorator.shape&&(i[i.length-1]=this.clipDecorator(e,i,!1,r)),i},t.prototype.updateSegmentElement=function(e,i,r,s){var o=new Ne,a=this.getSegmentPath(e,i,s);if("Bezier"===e.type){if(this.segments.length>0)for(var l=0;l0)if("Straight"===e.type&&e.segments.length<2)for(var o=0;o1)for(o=0;o0&&"Bezier"!==this.type)for(var p=0;p0&&(a=p0&&(f<2*this.cornerRadius?(l=z.adjustPoint(h[parseInt(p.toString(),10)],h[p+1],!0,f/2),p0&&(s=this.bridgePath(e,s,p),"Orthogonal"===e.type&&(s=this.bridgePath(e,s,p+1))),s+=" L"+a.x+" "+a.y))}else if("Bezier"===this.type){var g=void 0,v=void 0;if(this.parentObj.element){var y=this.parentObj.element.ej2_instances[0].eventHandler.action;g=this.parentObj.element.ej2_instances[0].eventHandler.tool instanceof zd,v=y.includes("PortDraw")||y.includes("Drag")}for(var S=void 0,b=this.segments,M=0;M2&&(b[parseInt(M.toString(),10)].bezierPoint1={x:0,y:0},b[parseInt(M.toString(),10)].bezierPoint2={x:0,y:0}),!z.isEmptyPoint(b[parseInt(M.toString(),10)].point1)||b[parseInt(M.toString(),10)].vector1.angle||b[parseInt(M.toString(),10)].vector1.distance?b[parseInt(M.toString(),10)].vector1.angle||b[parseInt(M.toString(),10)].vector1.distance?b[parseInt(M.toString(),10)].bezierPoint1=z.transform(h[parseInt(M.toString(),10)],b[parseInt(M.toString(),10)].vector1.angle,b[parseInt(M.toString(),10)].vector1.distance):b[parseInt(M.toString(),10)].bezierPoint1={x:b[parseInt(M.toString(),10)].point1.x||b[parseInt(M.toString(),10)].bezierPoint1.x,y:b[parseInt(M.toString(),10)].point1.y||b[parseInt(M.toString(),10)].bezierPoint1.y}:((e.sourceID||this.sourcePortID)&&this.sourceWrapper&&!v&&!g&&(S=rF(this.sourceWrapper.bounds,h[parseInt(M.toString(),10)],!0)),b[parseInt(M.toString(),10)].bezierPoint1=JI(h[parseInt(M.toString(),10)],h[M+1],S)),!z.isEmptyPoint(b[parseInt(M.toString(),10)].point2)||b[parseInt(M.toString(),10)].vector2.angle||b[parseInt(M.toString(),10)].vector2.distance?b[parseInt(M.toString(),10)].vector2.angle||b[parseInt(M.toString(),10)].vector2.distance?b[parseInt(M.toString(),10)].bezierPoint2=z.transform(h[M+1],b[parseInt(M.toString(),10)].vector2.angle,b[parseInt(M.toString(),10)].vector2.distance):b[parseInt(M.toString(),10)].bezierPoint2={x:b[parseInt(M.toString(),10)].point2.x||b[parseInt(M.toString(),10)].bezierPoint2.x,y:b[parseInt(M.toString(),10)].point2.y||b[parseInt(M.toString(),10)].bezierPoint2.y}:((e.targetID||this.targetPortID)&&this.targetWrapper&&!v&&!g&&(S=rF(this.targetWrapper.bounds,h[M+1],!0)),b[parseInt(M.toString(),10)].bezierPoint2=JI(h[M+1],h[parseInt(M.toString(),10)],S));h.splice(1,0,{x:b[0].bezierPoint1.x,y:b[0].bezierPoint1.y}),h.splice(h.length-1,0,{x:b[b.length-1].bezierPoint2.x,y:b[b.length-1].bezierPoint2.y}),h=this.clipDecorators(e,h,r);for(var w=0;w0&&(s=this.bridgePath(e,s,D),s+=" L"+o.x+" "+o.y);return s},t.prototype.updateShapeElement=function(e){var i;switch(e.shape.type){case"Bpmn":e.wrapper.children[3]instanceof Ke&&(i=e.wrapper.children[3]),"Message"===e.shape.flow&&this.updateShapePosition(e,i);break;case"UmlActivity":"Exception"===e.shape.flow&&this.getUMLExceptionFlow(e.wrapper.children[0])}},t.prototype.updateShapePosition=function(e,i){var o=xF(this.intermediatePoints,i,.5);i.offsetX=o.x,i.offsetY=o.y},t.prototype.scale=function(e,i,r,s,o){var a=0,l=0;if(this.wrapper&&this.wrapper.outerBounds){var h=function T3(n){var t=n.wrapper.children[0].bounds;return"None"!==n.sourceDecorator.shape&&t.uniteRect(n.wrapper.children[1].bounds),"None"!==n.targetDecorator.shape&&t.uniteRect(n.wrapper.children[2].bounds),t}(this),c=Math.abs((this.wrapper.bounds.width||this.style.strokeWidth||1)-2),d=Math.abs((this.wrapper.bounds.height||this.style.strokeWidth||1)-2);a=h.width-c,l=h.height-d,e=Math.abs((r-Math.max(a,l))/c),i=Math.abs((s-Math.max(a,l))/d),a=l=Math.min(a,l)}e=i=Math.min(e,i);var u=Hi();qi(u,-(o=o||this.wrapper).rotateAngle,o.offsetX,o.offsetY),Gp(u,e,i,o.offsetX,o.offsetY),qi(u,o.rotateAngle,o.offsetX,o.offsetY);var p=function Uie(n,t){for(var e=[],i=0,r=t;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},tse=function(n){function t(e,i){var r=n.call(this,e,i)||this;return r.offset=0,r.scale=1,r}return ese(t,n),t.prototype.preRender=function(){this.unWireEvents(),this.wireEvents()},t.prototype.render=function(){this.updateRulerGeometry(),this.renderComplete()},t.prototype.getModuleName=function(){return"Ruler"},t.prototype.destroy=function(){this.unWireEvents(),this.notify("destroy",{}),n.prototype.destroy.call(this),this.element.classList.remove("e-ruler")},t.prototype.getPersistData=function(){return this.addOnPersist(["loaded"])},t.prototype.onPropertyChanged=function(e,i){for(var r=0,s=Object.keys(e);r100;)r/=10,s/=10;for(;s<25;)r*=10,s*=10;return s>=25&&s%25!=0&&(s=25*Math.round(s/25)),s*e/r},t.prototype.createMarkerLine=function(e,i,r){var s;return i&&((s=e.getElementById(i.id+"_marker"))&&s.parentNode.removeChild(s),s=Bi("line",r)),s},t.prototype.drawRulerMarker=function(e,i,r){var s,o,h,d,u="Horizontal"===this.orientation,p=e.getElementsByTagName("svg");for(h=0;h0)for(var a=i.childNodes.length-1;a>=0;a--)i.childNodes[parseInt(a.toString(),10)].parentNode.removeChild(i.childNodes[parseInt(a.toString(),10)]);i.appendChild(s)}return s},t.prototype.wireEvents=function(){},t.prototype.unWireEvents=function(){},kc([I(5)],t.prototype,"interval",void 0),kc([I(100)],t.prototype,"segmentWidth",void 0),kc([I("Horizontal")],t.prototype,"orientation",void 0),kc([I("RightOrBottom")],t.prototype,"tickAlignment",void 0),kc([I("red")],t.prototype,"markerColor",void 0),kc([I(25)],t.prototype,"thickness",void 0),kc([I(null)],t.prototype,"arrangeTick",void 0),kc([I(400)],t.prototype,"length",void 0),t}(yi);function oF(n,t){var e=document.getElementById(n.element.id+(t?"_hRuler":"_vRuler")),i=qa(n),r=aF(n);e||(e=Tt("div",{id:n.element.id+(t?"_hRuler":"_vRuler"),style:"height:"+(t?i.height:r.height+100)+"px;overflow:hidden;width:"+(t?r.width+100:i.width)+"px;position:absolute;font-size:11px;"+(t?"margin-left:"+i.width+"px;":"margin-top:"+i.height+"px;")})),n.element.insertBefore(e,n.element.firstChild);var l=t?n.rulerSettings.horizontalRuler:n.rulerSettings.verticalRuler,h=new tse(l);h.orientation=t?"Horizontal":"Vertical",h.length=(t?r.width:r.height)+l.segmentWidth,h.appendTo("#"+n.element.id+(t?"_hRuler":"_vRuler")),t?n.hRuler=h:n.vRuler=h;var c=document.getElementById(n.element.id+(t?"_hRuler":"_vRuler"));t?n.hRuler.element=c:n.vRuler.element=c}function KI(n){var t=-n.scroller.horizontalOffset,e=-n.scroller.verticalOffset;n&&n.rulerSettings.showRulers?(n.hRuler.length=0,n.vRuler.length=0,void 0!==t&&n.hRuler.element&&lF(n,n.hRuler,t,!0),void 0!==e&&n.vRuler.element&&lF(n,n.vRuler,e,!1)):qx(n)}function qx(n){an(n.element.id+"_hRuler"),an(n.element.id+"_vRuler"),an(n.element.id+"_overlapRuler")}function qa(n){var t=0,e=0;return n.rulerSettings.showRulers&&(t=n.rulerSettings.horizontalRuler.thickness,e=n.rulerSettings.verticalRuler.thickness),new me(e,t)}function aF(n){var t=qa(n),e=n.scroller.viewPortHeight,i=n.scroller.viewPortWidth;return i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},hF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return ase(t,n),t.prototype.getClassName=function(){return"UserHandle"},Fn([I("")],t.prototype,"name",void 0),Fn([I("")],t.prototype,"pathData",void 0),Fn([I("")],t.prototype,"content",void 0),Fn([I("")],t.prototype,"source",void 0),Fn([I("#000000")],t.prototype,"backgroundColor",void 0),Fn([I("Top")],t.prototype,"side",void 0),Fn([I("")],t.prototype,"borderColor",void 0),Fn([I(.5)],t.prototype,"borderWidth",void 0),Fn([I(25)],t.prototype,"size",void 0),Fn([I("white")],t.prototype,"pathColor",void 0),Fn([I(10)],t.prototype,"displacement",void 0),Fn([I(!0)],t.prototype,"visible",void 0),Fn([I(0)],t.prototype,"offset",void 0),Fn([re({},$n)],t.prototype,"margin",void 0),Fn([I("Center")],t.prototype,"horizontalAlignment",void 0),Fn([I("Center")],t.prototype,"verticalAlignment",void 0),Fn([I(!1)],t.prototype,"disableNodes",void 0),Fn([I(!1)],t.prototype,"disableConnectors",void 0),Fn([re({},xd)],t.prototype,"tooltip",void 0),Fn([I("")],t.prototype,"template",void 0),t}(Ee);function cF(n){return lse[n.toString()]}var lse={Action:"M 90 82.895 C 90 86.819 86.776 90 82.8 90 H 7.2 C 3.224 90 0 86.819 0 82.895 V 7.105 C 0 3.181 3.224 0 7.2 0 h 75.6 C 86.776 0 90 3.181 90 7.105 V 82.895 Z",Decision:"M10,19.707L0.293,10L10,0.293L19.707,10L10,19.707z",MergeNode:"M10,19.707L0.293,10L10,0.293L19.707,10L10,19.707z",InitialNode:"M10,19.5c-5.238,0-9.5-4.262-9.5-9.5S4.762,0.5,10,0.5s9.5,4.262,9.5,9.5S15.238,19.5,10,19.5z",ForkNode:"m0.75,0.75l636.00002,0l0,290l-636.00002,0l0,-290z",JoinNode:"m0.75,0.75l636.00002,0l0,290l-636.00002,0l0,-290z",TimeEvent:"M50.001,0.00286865 L25.001,25.0029 L0.000976562,0.00286865 L50.001,0.00286865 z M0.000976562,50.0029 L25.001,25.0029 L50.001,50.0029 L0.000976562,50.0029 z",AcceptingEvent:"M17.8336 32.164 L29.64 24 L17.32 16 L48.1664 16 L48.5 32 Z",SendSignal:"M48.164 31.8336 L56 23.832 L47.836 16 L16.168 16 L16.1668 31.8336 Z",ReceiveSignal:"M48.1664 31.8336 L39.836 24 L47.836 16 L16.168 16 L16.168 31.836 Z",StructuredNode:"M0,0 L50,0 L50,50 L0,50 z",Note:"M20 12 L4 12 L4 22 L22 22 L22 14 L20 14 L20 12 L22 14 Z"},eb=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),$a=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},hse=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return eb(t,n),$a([I()],t.prototype,"key",void 0),$a([I()],t.prototype,"keyModifiers",void 0),t}(Ee),dF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return eb(t,n),t.prototype.getClassName=function(){return"Command"},$a([I("")],t.prototype,"name",void 0),$a([I()],t.prototype,"canExecute",void 0),$a([I()],t.prototype,"execute",void 0),$a([re({},hse)],t.prototype,"gesture",void 0),$a([I("")],t.prototype,"parameter",void 0),t}(Ee),cse=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return eb(t,n),$a([Bt([],dF)],t.prototype,"commands",void 0),t}(Ee),dse=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return eb(t,n),$a([I()],t.prototype,"show",void 0),$a([I()],t.prototype,"showCustomMenuOnly",void 0),$a([I()],t.prototype,"items",void 0),t}(Ee),Jp=function(){function n(){}return n.prototype.renderShadow=function(t,e,i,r){void 0===i&&(i=null);var l,o=z.transform({x:0,y:0},t.shadow.angle,t.shadow.distance);r&&(l=r.getElementById(e.id+"_shadow")),l||(l=document.createElementNS("http://www.w3.org/2000/svg",i?"path":"rect"),e.appendChild(l));var h={id:e.id+"_shadow",fill:t.shadow.color,stroke:t.shadow.color,opacity:t.shadow.opacity.toString(),transform:"rotate("+t.angle+","+(t.x+t.width*t.pivotX)+","+(t.y+t.height*t.pivotY)+")translate("+(t.x+o.x)+","+(t.y+o.y)+")"};if(r){var c=r.getElementById(e.id);c&&c.insertBefore(l,c.firstChild)}oi(l,h),i?i&&this.renderPath(l,t,i):oi(l,{width:t.width,height:t.height})},n.prototype.parseDashArray=function(t){return[]},n.prototype.drawRectangle=function(t,e,i,r,s,o,a,l,h){var c,d,u,p;e.shadow&&!r&&this.renderShadow(e,t,void 0,o),c=e.id===t.id?e.id+"_container":e.id,o&&(d=o.getElementById(c)),(!d||s)&&(d=document.createElementNS("http://www.w3.org/2000/svg","rect"),t.appendChild(d)),o&&!e.shadow&&(u=o.getElementById(e.id+"_groupElement_shadow"))&&u.parentNode.removeChild(u),p=l?{id:c,x:e.x.toString(),y:e.y.toString(),width:e.width.toString(),height:e.height.toString(),visibility:e.visible?"visible":"hidden",transform:"rotate("+e.angle+","+(e.x+e.width/2)+","+(e.y+e.height/2)+")",rx:e.cornerRadius||0,ry:e.cornerRadius||0,opacity:e.opacity}:{id:c,x:e.x.toString(),y:e.y.toString(),width:e.width.toString(),height:e.height.toString(),visibility:e.visible?"visible":"hidden",transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")",rx:e.cornerRadius||0,ry:e.cornerRadius||0,opacity:e.opacity},a&&(p.role="img",p["aria-label"]=a);var f=e.class||"";h||(f.includes("e-diagram-resize-handle")||f.includes("e-diagram-endpoint-handle")||f.includes("e-diagram-bezier-control-handle"))&&(f+=" e-disabled"),e.class&&(p.class=f),a||(p["pointer-events"]="none"),oi(d,p),this.setSvgStyle(d,e,i)},n.prototype.updateSelectionRegion=function(t,e){var i;i=t.parentNode.getElementById(e.id);var r={id:e.id,x:e.x.toString(),y:e.y.toString(),width:e.width.toString(),height:e.height.toString(),transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")",class:"e-diagram-selected-region"};i||(i=document.createElementNS("http://www.w3.org/2000/svg","rect"),t.appendChild(i)),this.setSvgStyle(i,e),oi(i,r)},n.prototype.createGElement=function(t,e){return Bi(t,e)},n.prototype.drawLine=function(t,e){var i=document.createElementNS("http://www.w3.org/2000/svg","line");this.setSvgStyle(i,e);var r=e.x+e.width*e.pivotX,s=e.y+e.height*e.pivotY,o={id:e.id,x1:e.startPoint.x+e.x,y1:e.startPoint.y+e.y,x2:e.endPoint.x+e.x,y2:e.endPoint.y+e.y,stroke:e.stroke,"stroke-width":e.strokeWidth.toString(),opacity:e.opacity.toString(),transform:"rotate("+e.angle+" "+r+" "+s+")",visibility:e.visible?"visible":"hidden"};e.class&&(o.class=e.class),oi(i,o),t.appendChild(i)},n.prototype.drawCircle=function(t,e,i,r){var s=document.createElementNS("http://www.w3.org/2000/svg","circle");this.setSvgStyle(s,e);var o=e.class||"";i||(o+=" e-disabled");var a={id:e.id,cx:e.centerX,cy:e.centerY,r:e.radius,visibility:e.visible?"visible":"hidden",class:o};r&&(a.role="img",a["aria-label"]=r),s.style.display=e.visible?"block":"none",oi(s,a),t.appendChild(s)},n.prototype.drawPath=function(t,e,i,r,s,o,a){var h,c,l=[];l=e3(l=Dd(e.data)),e.shadow&&this.renderShadow(e,t,l,s),s&&!e.shadow&&(h=s.getElementById(e.id+"_groupElement_shadow"))&&h.parentNode.removeChild(h),s&&(c=s.getElementById(e.id)),(!c||r)&&(c=document.createElementNS("http://www.w3.org/2000/svg","path"),t.appendChild(c)),this.renderPath(c,e,l);var d={};d=a?{id:e.id,transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")translate("+e.x+","+e.y+"),scale("+a+")",visibility:e.visible?"visible":"hidden",opacity:e.opacity}:{id:e.id,transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")translate("+e.x+","+e.y+")",visibility:e.visible?"visible":"hidden",opacity:e.opacity},o&&(d.role="img",d["aria-label"]=o),e.class&&(d.class=e.class),oi(c,d),this.setSvgStyle(c,e,i)},n.prototype.renderPath=function(t,e,i){var r,s,o,a,l,h,c,d,u=i,p="";for(l=0,h=0,d=0,c=u.length;de.width&&"Wrap"!==e.textOverflow&&"NoWrap"===e.textWrapping&&(h[0].text=qF(e.content,e)),v=0;vD&&(u.text=u.text.slice(0,u.text.length-3),u.text=u.text.concat("..."),l.data=u.text),this.alignText(y,p,u,l,f,g,v,e,h),C+=u.dy}}C&&e.isHorizontalLane&&(M=e.parentOffsetX+e.pivotX,w=e.parentOffsetY+e.pivotY,e.y=e.parentOffsetY-C*e.pivotY+.5),e.textDecoration&&"LineThrough"===e.textDecoration&&(e.textDecoration=fb(e.textDecoration));var R={id:e.id+"_text",fill:e.color,visibility:e.visible?"visible":"hidden","text-decoration":e.textDecoration,transform:"rotate("+e.angle+","+M+","+w+")translate("+e.x+","+e.y+")",opacity:e.opacity};r&&(R.role="img",R["aria-label"]=r),oi(y,R)}},n.prototype.alignText=function(t,e,i,r,s,o,a,l,h){"justify"!==l.textAlign?this.setText(t,e,i,r,s,o,l):a!==h.length-1?this.setText(t,e,i,r,s,o,l,l.width,"spacing"):this.setText(t,e,i,r,s,o,l)},n.prototype.setText=function(t,e,i,r,s,o,a,l,h){oi(e,"justify"!==a.textAlign?{x:s.toString(),y:o.toString()}:{x:s.toString(),y:o.toString(),textLength:l||0,lengthAdjust:h||"spacing"}),t.setAttribute("fill",i.text),e.appendChild(r),t.appendChild(e)},n.prototype.drawImage=function(t,e,i,r){var s;i&&(s=i.getElementById(e.id+"image")),s||(s=document.createElementNS("http://www.w3.org/2000/svg","image"),t.appendChild(s));var o=new Image;o.src=e.source;var a="None"!==e.scale?e.scale:"",l=e.alignment,h=l.charAt(0).toLowerCase()+l.slice(1);"Stretch"!==a&&(h+=" "+a.charAt(0).toLowerCase()+a.slice(1)),oi(s,{id:e.id+"image",x:e.x.toString(),y:e.y.toString(),transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")",width:e.width.toString(),visibility:e.visible?"visible":"hidden",height:e.height.toString(),preserveAspectRatio:h,opacity:e.opacity.toString()}),s.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",o.src.toString())},n.prototype.drawHTMLContent=function(t,e,i,r,s){var o,a;if(e&&(o=e.querySelector("#"+t.id+"_html_element")),!o){(a=e.querySelector("#"+t.id+"_html_element")||e.querySelector("#"+t.nodeId+"_html_element"))||(a=Tt("div",{id:t.nodeId+"_html_element",class:"foreign-object"})),o=Tt("div",{id:t.id+"_html_element",class:"foreign-object"});var c=document.getElementById(t.diagramId).ej2_instances[0],d=!1;if(e.parentNode&&e.parentNode.parentNode&&e.parentNode.parentNode.parentNode&&e.parentNode.parentNode.parentNode.classList.contains("e-overview")&&(d=!0),d)c.isReact?c.renderReactTemplates(function(){o.appendChild(t.template.cloneNode(!0))}):o.appendChild(t.template.cloneNode(!0));else{if("string"==typeof t.template){var u=document.createElement("div");u.innerHTML=t.template,t.template=u,c.selectedItems.userHandles.filter(function(g){return g.name===t.id.split("_shape")[0]&&""!==g.template})[0].template=t.template}t.isTemplate&&t.template?o.appendChild(t.template):t.template&&o.appendChild(t.template.cloneNode(!0))}void 0!==s&&e.childNodes.length>s&&e.insertBefore(o,e.childNodes[parseInt(s.toString(),10)]),a.appendChild(o),e.appendChild(a)}var f=En(t).topLeft;o.setAttribute("style","height:"+t.actualSize.height+"px; width:"+t.actualSize.width+"px;left:"+f.x+"px; top:"+f.y+"px;position:absolute;transform:rotate("+(t.rotateAngle+t.parentTransform)+"deg);pointer-events:"+(r?"all":"none")+";visibility:"+(t.visible?"visible":"hidden")+";opacity:"+t.style.opacity+";")},n.prototype.drawNativeContent=function(t,e,i,r,s){var o,a;if(s&&(o=s.getElementById(t.id+"_native_element"),a=s.getElementById(t.id+"_clip")),!o){(o=document.createElementNS("http://www.w3.org/2000/svg","g")).setAttribute("id",t.id+"_native_element"),o.appendChild(t.template.cloneNode(!0));var l=this.createGElement("g",{id:t.id+"_inner_native_element"});l.appendChild(o),e.appendChild(l)}a&&o.removeChild(a),o.setAttribute("style","visibility:"+(t.visible?"visible":"hidden")+";opacity:"+t.style.opacity+";"),this.setNativTransform(t,o,i,r),"Slice"===t.scale&&this.drawClipPath(t,o,i,r,s),oi(o,t.description?{role:"img","aria-label":t.description}:{})},n.prototype.setNativTransform=function(t,e,i,r){var s=0!==t.contentSize.width?t.contentSize.width:1,o=0!==t.contentSize.height?t.contentSize.height:1;e.setAttribute("transform","rotate("+t.parentTransform+","+t.offsetX+","+t.offsetY+") translate("+(t.offsetX-t.templatePosition.x*r/s-r*t.pivot.x)+","+(t.offsetY-t.templatePosition.y*i/o-i*t.pivot.y)+") scale("+r/s+","+i/o+")")},n.prototype.drawClipPath=function(t,e,i,r,s){var o=t.contentSize.width,a=t.contentSize.height,l=t.width/(r/o),h=t.height/(i/a),c=t.templatePosition.x+(t.width>=t.height?0:(o-l)/2),d=t.templatePosition.y+(t.height>=t.width?0:(a-h)/2),u=s.getElementById(t.id+"_clip");(u=document.createElementNS("http://www.w3.org/2000/svg","clipPath")).setAttribute("id",t.id+"_clip"),e.appendChild(u);var p=s.getElementById(t.id+"_clip_rect");return p=document.createElementNS("http://www.w3.org/2000/svg","rect"),u.appendChild(p),oi(p,{id:t.id+"_clip_rect",width:l.toString(),height:h.toString(),x:c.toString(),y:d.toString()}),om()?e.setAttribute("clip-path","url("+location.protocol+"//"+location.host+location.pathname+"#"+t.id+"_clip)"):e.setAttribute("clip-path","url(#"+t.id+"_clip)"),e},n.prototype.renderGradient=function(t,e,i){var r,s,o,h,c,a=IT(i),l=a.getElementById(i+"gradient_pattern");if(l||(l=Bi("defs",{id:i+"gradient_pattern"}),a.insertBefore(l,a.firstChild)),bF(e.id),"None"!==t.gradient.type){for(var d=0;dt.width&&("Ellipsis"===t.textOverflow||"Clip"===t.textOverflow)&&"NoWrap"===t.textWrapping?0:.5*t.width:"right"===t.textAlign&&(c=1*t.width),s.x=0+c+(e?e.x:0),s.y=1.2+d-r.height/2,s},n}(),Pc=function(){function n(t,e,i){this.renderer=null,this.isSvgMode=!0,this.transform={x:0,y:0},this.diagramId=t,this.element=xt(this.diagramId),this.svgRenderer=e,this.isSvgMode=i,this.renderer=i?new Jp:new bo}return n.prototype.setCursor=function(t,e){t.style.cursor=e},n.prototype.setLayers=function(){this.iconSvgLayer=this.element.getElementsByClassName("e-ports-expand-layer")[0],this.adornerSvgLayer=this.element.getElementsByClassName("e-adorner-layer")[0],this.nativeSvgLayer=this.element.getElementsByClassName("e-native-layer")[0],this.diagramSvgLayer=this.element.getElementsByClassName("e-diagram-layer")[0]},n.prototype.getAdornerLayer=function(){return yT(this.diagramId)},n.prototype.getParentSvg=function(t,e,i){return this.diagramId&&t&&t.id?t.id.split("_icon_content").length>1||t.id.split("_nodeport").length>1||t.elementActions&Xr.ElementIsPort?this.iconSvgLayer:e&&"selector"===e?this.adornerSvgLayer:t instanceof Cn?this.nativeSvgLayer:this.diagramSvgLayer:i},n.prototype.getParentElement=function(t,e,i,r){var s=e;if(i&&this.diagramId&&t&&t.id){t.id.split("_icon_content").length>1?(s=i.getElementById(this.diagramId+"_diagramExpander"),e=null):t.id.split("_nodeport").length>1?s=i.getElementById(this.diagramId+"_diagramPorts"):t instanceof Cn?(s=i.getElementById(this.diagramId+"_nativeLayer"),e=null):t.elementActions&Xr.ElementIsPort?(s=i.getElementById(this.diagramId+"_diagramPorts"),e=null):s=i.getElementById(this.diagramId+"_diagramLayer");var o=this.getGroupElement(t,e||s,r);s=o.g,o.svg&&(i=o.svg)}return{g:s,svg:i}},n.prototype.getGroupElement=function(t,e,i){var r,o,s=this.getParentSvg(t);if(e&&s){if(s&&!(r=s.getElementById(t.id+"_groupElement"))&&s!==this.nativeSvgLayer){var a=this.nativeSvgLayer;r=a.getElementById(t.id+"_groupElement"),o=a}r||(r=this.svgRenderer.createGElement("g",{id:t.id+"_groupElement"}),void 0!==i&&e.childNodes.length>i?e.insertBefore(r,e.childNodes[parseInt(i.toString(),10)]):e.appendChild(r))}return{g:r,svg:o}},n.prototype.renderElement=function(t,e,i,r,s,o,a,l,h,c,d){t instanceof Cs?(t.id=t.id?t.id:Qe(),this.renderContainer(t,e,i,r,s,o,a,l,h,c,d)):t instanceof CI?this.renderImageElement(t,e,r,s,a):t instanceof Ke?this.renderPathElement(t,e,r,s,a,h,d):t instanceof ni?this.renderTextElement(t,e,r,s,a,c):t instanceof Cn?this.renderNativeElement(t,e,r,s,a):t instanceof Jn?this.renderHTMLElement(t,e,i,r,s,a,l):this.renderRect(t,e,r,s,h)},n.prototype.drawSelectionRectangle=function(t,e,i,r,s,o){var a={width:i*o.scale,height:r*o.scale,x:.5+(t=(t+o.tx)*o.scale),y:.5+(e=(e+o.ty)*o.scale),fill:"transparent",stroke:"gray",angle:0,pivotX:.5,pivotY:.5,strokeWidth:1,dashArray:"6 3",opacity:1,visible:!0,id:s.id+"_selected_region"},l=this.getAdornerLayer();this.svgRenderer.updateSelectionRegion(l,a)},n.prototype.renderHighlighter=function(t,e,i){var r=t.actualSize.width||2,s=t.actualSize.height||2,o=t.offsetX-r*t.pivot.x,a=t.offsetY-s*t.pivot.y;this.svgRenderer.drawRectangle(e,{width:r*i.scale,height:s*i.scale,x:o=(o+i.tx)*i.scale,y:a=(a+i.ty)*i.scale,fill:"transparent",stroke:"#8CC63F",angle:t.rotateAngle,pivotX:t.pivot.x,pivotY:t.pivot.y,strokeWidth:4,dashArray:"",opacity:1,cornerRadius:0,visible:!0,id:e.id+"_highlighter",class:"e-diagram-highlighter"},this.diagramId,void 0,void 0,e)},n.prototype.renderSelectionRectangle=function(t,e,i,r){var s=t.actualSize.width||2,o=t.actualSize.height||2,a=t.offsetX-s*t.pivot.x,l=t.offsetY-o*t.pivot.y,h={width:s*i.scale,height:o*i.scale,x:a=(a+i.tx)*i.scale,y:l=(l+i.ty)*i.scale,fill:"transparent",stroke:"#00cc00",angle:t.rotateAngle,pivotX:t.pivot.x,pivotY:t.pivot.y,strokeWidth:r?2:1,dashArray:"",opacity:1,cornerRadius:0,visible:!0,id:t.id+"_highlighter",class:r?"e-diagram-first-selection-indicator e-diagram-selection-indicator":"e-diagram-selection-indicator"},c=this.getParentSvg(t,"selector");this.svgRenderer.drawRectangle(e,h,this.diagramId,void 0,void 0,c)},n.prototype.renderSelectionLine=function(t,e,i,r){var s=this.getBaseAttributes(t,i);s.data=t.absolutePath,s.id=s.id+"_highlighter";var o=t.description?t.description:t.id;this.isSvgMode||(s.x=t.flipOffset.x?t.flipOffset.x:s.x,s.y=t.flipOffset.y?t.flipOffset.y:s.y),i&&(s.x=s.x*i.scale,s.y=s.y*i.scale),s.stroke="#00cc00",s.strokeWidth=r?2:1,s.class=r?"e-diagram-first-selection-indicator e-diagram-selection-indicator":"e-diagram-selection-indicator";var a=this.getParentSvg(t,"selector");this.svgRenderer.drawPath(e,s,this.diagramId,void 0,a,o,i.scale)},n.prototype.renderStackHighlighter=function(t,e,i,r,s,o,a){var l=t.actualSize.width||2,h=t.offsetX-l*t.pivot.x,c=t.actualSize.height||2,d=t.offsetY-c*t.pivot.y;h=(h+i.tx)*i.scale;var u,p=t.bounds,f="";if(d=(d+i.ty)*i.scale,r)if(o){var v,y;u="M 0 0 L "+(2+(g=l*i.scale))+" 0 Z",v=t.actualSize.width/Number(p.width?p.width:1)*i.scale,y=t.actualSize.height/Number(p.height?p.height:1)*i.scale,f=SI(II(Dd("M7,4 L8,4 8,7 11,7 11,8 8,8 8,11 7,11 7,8 4,8 4,7 7,7 z M7.5,0.99999994C3.9160004,1 1,3.9160004 0.99999994,7.5 1,11.084 3.9160004,14 7.5,14 11.084,14 14,11.084 14,7.5 14,3.9160004 11.084,1 7.5,0.99999994 z M7.5,0 C11.636002,0 15,3.3639984 15,7.5 15,11.636002 11.636002,15 7.5,15 3.3640003,15 0,11.636002 0,7.5 0,3.3639984 3.3640003,0 7.5,0 z")),v+g+2,y-8,!1,p.x,p.y,0,0),s.y>=t.offsetY&&(d+=c)}else{var g;a&&s.y>=t.offsetY&&(d+=c*i.scale),u="M -10 -10 L 0 0 Z M -10 10 L 0 0 Z M 0 0 L "+(g=l*i.scale)+" 0 Z M "+g+" 0 L "+(g+10)+" 10 Z L "+(g+10)+" -10 Z"}else u="M 10 -10 L 0 0 Z M -10 -10 L 0 0 Z M 0 0 L 0 "+(g=c*i.scale)+" Z M 0 "+g+" L -10 "+(g+10)+" Z L 10 "+(g+10)+" Z",s.x>=t.offsetX&&(h+=l*i.scale);this.svgRenderer.drawPath(e,{data:u+f,width:l*i.scale,height:c*i.scale,x:h,y:d,fill:"transparent",stroke:"#8CC63F",angle:t.rotateAngle,pivotX:t.pivot.x,pivotY:t.pivot.y,strokeWidth:1,dashArray:"",opacity:1,visible:!0,id:e.id+"_stack_highlighter",class:"e-diagram-highlighter"},this.diagramId)},n.prototype.drawLine=function(t,e){this.svgRenderer.drawLine(t,e)},n.prototype.drawPath=function(t,e){this.svgRenderer.drawPath(t,e,this.diagramId)},n.prototype.renderResizeHandle=function(t,e,i,r,s,o,a,l,h,c,d){var u=t.offsetX-t.actualSize.width*t.pivot.x,p=t.offsetY-t.actualSize.height*t.pivot.y,f=t.actualSize.height,g=t.actualSize.width;!c&&i&bt.Rotate&&_I(this.rendererActions)&&!z3(this.rendererActions)&&(this.renderPivotLine(t,e,o,s,a),this.renderRotateThumb(t,e,o,s,a)),this.renderBorder(t,e,o,l,h,c);var v=t.actualSize.width*r,y=t.actualSize.height*r;!h&&_I(this.rendererActions)&&!z3(this.rendererActions)&&(t.isTextAnnotation||(v>=40&&y>=40&&(s&mr.ResizeNorthWest&&this.renderCircularHandle("resizeNorthWest",t,u,p,e,qr(s,"ResizeNorthWest"),i&bt.ResizeNorthWest,o,void 0,a,{"aria-label":"Thumb to resize the selected object on top left side direction"},void 0,"e-diagram-resize-handle e-northwest",d),s&mr.ResizeNorthEast&&this.renderCircularHandle("resizeNorthEast",t,u+g,p,e,qr(s,"ResizeNorthEast"),i&bt.ResizeNorthEast,o,void 0,a,{"aria-label":"Thumb to resize the selected object on top right side direction"},void 0,"e-diagram-resize-handle e-northeast",d),s&mr.ResizeSouthWest&&this.renderCircularHandle("resizeSouthWest",t,u,p+f,e,qr(s,"ResizeSouthWest"),i&bt.ResizeSouthWest,o,void 0,a,{"aria-label":"Thumb to resize the selected object on bottom left side direction"},void 0,"e-diagram-resize-handle e-southwest",d),s&mr.ResizeSouthEast&&this.renderCircularHandle("resizeSouthEast",t,u+g,p+f,e,qr(s,"ResizeSouthEast"),i&bt.ResizeSouthEast,o,void 0,a,{"aria-label":"Thumb to resize the selected object on bottom right side direction"},void 0,"e-diagram-resize-handle e-southeast",d)),s&mr.ResizeNorth&&this.renderCircularHandle("resizeNorth",t,u+g/2,p,e,qr(s,"ResizeNorth"),i&bt.ResizeNorth,o,void 0,a,{"aria-label":"Thumb to resize the selected object on top side direction"},void 0,"e-diagram-resize-handle e-north",d),s&mr.ResizeSouth&&this.renderCircularHandle("resizeSouth",t,u+g/2,p+f,e,qr(s,"ResizeSouth"),i&bt.ResizeSouth,o,void 0,a,{"aria-label":"Thumb to resize the selected object on bottom side direction"},void 0,"e-diagram-resize-handle e-south",d),s&mr.ResizeWest&&this.renderCircularHandle("resizeWest",t,u,p+f/2,e,qr(s,"ResizeWest"),i&bt.ResizeWest,o,void 0,a,{"aria-label":"Thumb to resize the selected object on left side direction"},void 0,"e-diagram-resize-handle e-west",d),s&mr.ResizeEast&&this.renderCircularHandle("resizeEast",t,u+g,p+f/2,e,qr(s,"ResizeEast"),i&bt.ResizeEast,o,void 0,a,{"aria-label":"Thumb to resize the selected object on right side direction"},void 0,"e-diagram-resize-handle e-east",d)))},n.prototype.renderEndPointHandle=function(t,e,i,r,s,o,a,l,h,c){var f,g,d=t.sourcePoint,u=t.targetPoint,p=t.wrapper;if(this.renderCircularHandle("connectorSourceThumb",p,d.x,d.y,e,qr(r,"ConnectorSourceThumb"),i&bt.ConnectorSource,s,o,void 0,{"aria-label":"Thumb to move the source point of the connector"},void 0,"e-diagram-endpoint-handle e-sourceend",c),this.renderCircularHandle("connectorTargetThumb",p,u.x,u.y,e,qr(r,"ConnectorTargetThumb"),i&bt.ConnectorTarget,s,a,void 0,{"aria-label":"Thumb to move the target point of the connector"},void 0,"e-diagram-endpoint-handle e-targetend",c),l)if("Straight"===t.type&&t.segments.length>0)for(f=0;f0)for(f=0;f=3&&3===t.segments.length&&(S=1,b=t.segments.length-1),S=t.segments.length>t.maxSegmentThumb+2?2:S,b=t.segments.length>t.maxSegmentThumb+2?t.segments.length-2:b,1===t.segments.length&&t.segments[0].points.length<=2&&(S=1,b=t.segments.length),f=S;f=50&&i.allowDrag),this.renderOrthogonalThumb(t+"_"+(d+1),e,(i.points[parseInt(d.toString(),10)].x+i.points[d+1].x)/2,(i.points[parseInt(d.toString(),10)].y+i.points[d+1].y)/2,r,h,l,o,a,u)}else for(d=0;d=50&&i.allowDrag),this.renderOrthogonalThumb(t+"_"+(d+1),e,(i.points[parseInt(d.toString(),10)].x+i.points[d+1].x)/2,(i.points[parseInt(d.toString(),10)].y+i.points[d+1].y)/2,r,h,l,o,a,u)},n.prototype.renderOrthogonalThumb=function(t,e,i,r,s,o,a,l,h,c){var d,g,u=0,p=document.getElementById(this.diagramId);p&&(g=p.ej2_instances[0]);var y=h.constraints&qe.InheritSegmentThumbShape?g.segmentThumbShape:h.segmentThumbShape,b=h.constraints&qe.InheritSegmentThumbSize?g.segmentThumbSize:h.segmentThumbSize;if(d="horizontal"===a?function ure(n){return vre[""+n]}(y):c3(y),"Arrow"===y||"DoubleArrow"===y||"OpenArrow"===y)switch(c){case"Bottom":case"Right":u=180;break;default:u=0}else if("Fletch"===y||"OpenFetch"===y||"IndentedArrow"===y||"OutdentedArrow"===y)switch(c){case"Bottom":u=-90;break;case"Top":u=90;break;case"Right":u=180;break;default:u=0}var M={x:(i+l.tx)*l.scale-b/2,y:(r+l.ty)*l.scale-b/2,angle:u,fill:"#e2e2e2",stroke:"black",strokeWidth:1,dashArray:"",data:d,width:b,height:b,pivotX:.5,pivotY:.5,opacity:1,visible:o,id:t,class:"e-diagram-ortho-segment-handle"},w=af(M.data),C=new me(M.width,M.height),D=new Ke;M.data=D.updatePath(M.data,w,C),this.svgRenderer.drawPath(s,M,this.diagramId)},n.prototype.renderPivotLine=function(t,e,i,r,s){var o=t,l=!!(r&mr.Rotate);s&&(l=!1);var h=this.getBaseAttributes(o,i);h.fill="None",h.stroke="black",h.strokeWidth=1,h.dashArray="2,3",h.visible=l;var c=i.scale;h.x*=c,h.y*=c,h.width*=c,h.height*=c,h.id="pivotLine",h.class="e-diagram-pivot-line";var u={x:o.actualSize.width*o.pivot.x*c,y:0};h.startPoint={x:o.actualSize.width*o.pivot.x*c,y:-20},h.endPoint=u,this.svgRenderer.drawLine(e,h)},n.prototype.renderBezierLine=function(t,e,i,r,s,o){var l=this.getBaseAttributes(e,o);l.id=t,l.stroke="black",l.strokeWidth=1,l.dashArray="3,3",l.fill="None",l.class="e-diagram-bezier-control-line",l.x=0,l.y=0;var h=o.scale,g={x:(s.x+o.tx)*h,y:(s.y+o.ty)*h};l.startPoint={x:(r.x+o.tx)*h,y:(r.y+o.ty)*h},l.endPoint=g,this.svgRenderer.drawLine(i,l)},n.prototype.renderCircularHandle=function(t,e,i,r,s,o,a,l,h,c,d,u,p,f){var g=e,v={x:i,y:r};if(0!==g.rotateAngle||0!==g.parentTransform){var y=Hi();qi(y,g.rotateAngle+g.parentTransform,g.offsetX,g.offsetY),v=Je(y,v)}var S=this.getBaseAttributes(g);S.stroke="black",S.strokeWidth=1,void 0!==u?(S.id="segmentEnd_"+u,S.fill="#e2e2e2"):S.fill=h?"#8CC63F":"white",S.cornerRadius=f/2,S.angle=e.rotateAngle,S.id=t,S.visible=o,S.class=p,S.width=f,S.height=f,S.x=(v.x+l.tx)*l.scale,S.y=(v.y+l.ty)*l.scale,S.x=S.x-S.width/2,S.y=S.y-S.height/2,h&&(S.class+=" e-connected"),c&&(S.visible=!1);var b=this.getParentSvg(e,"selector");this.svgRenderer.drawRectangle(s,S,this.diagramId,!0,!0,b,d,!0,a)},n.prototype.renderBezierHandle=function(t,e,i,r,s,o,a,l,h,c,d,u,p){var v,f=document.getElementById(this.diagramId);f&&(v=f.ej2_instances[0]);var y=e,S={x:i,y:r};if(0!==y.rotateAngle||0!==y.parentTransform){var b=Hi();qi(b,y.rotateAngle+y.parentTransform,y.offsetX,y.offsetY),S=Je(b,S)}var D=a.constraints&qe.InheritSegmentThumbSize?v.segmentThumbSize:a.segmentThumbSize,A=c3(a.constraints&qe.InheritSegmentThumbShape?v.segmentThumbShape:a.segmentThumbShape),x=this.getBaseAttributes(y);x.stroke="black",x.strokeWidth=1,void 0!==d?(x.id="segmentEnd_"+d,x.fill="#e2e2e2"):x.fill=h?"#8CC63F":"white",x.angle=e.rotateAngle,x.id=t,x.visible=o,x.class=u,x.width=D,x.height=D,x.data=A,x.x=(S.x+l.tx)*l.scale,x.y=(S.y+l.ty)*l.scale,x.x=x.x-x.width/2,x.y=x.y-x.height/2,h&&(x.class+=" e-connected"),c&&(x.visible=!1);var R=af(x.data),L=new me(x.width,x.height),O=new Ke;x.data=O.updatePath(x.data,R,L);var N=this.getParentSvg(e,"selector");this.svgRenderer.drawPath(s,x,this.diagramId,!0,N)},n.prototype.renderBorder=function(t,e,i,r,s,o){var l=this.getBaseAttributes(t,i);l.x*=i.scale,l.y*=i.scale,l.width*=i.scale,l.height*=i.scale,l.fill="transparent",l.stroke="#097F7F",l.strokeWidth=1.2,l.gradient=null,l.dashArray="6,3",l.class="e-diagram-selector",o&&(l.class+=" e-diagram-lane"),l.id="borderRect",l.id=this.rendererActions&Qa.DrawSelectorBorder?"borderRect_symbol":"borderRect",r||(l.class+=" e-disabled"),s&&(l.class+=" e-thick-border"),l.cornerRadius=0;var h=this.getParentSvg(t,"selector");this.svgRenderer.drawRectangle(e,l,this.diagramId,void 0,!0,h)},n.prototype.renderUserHandler=function(t,e,i,r,s,o){for(var l,a=t.wrapper,h=0,c=t.userHandles;h0||d.disableNodes&&t.nodes.length>0||"Drag"===s&&o)&&(l=!1);var u=document.getElementById(d.name+"_template_hiddenUserHandle");u&&(d.template=u.childNodes[0].cloneNode(!0));var p=iT(t,d,i);if(p.x=(p.x+i.tx)*i.scale,p.y=(p.y+i.ty)*i.scale,d.visible&&(d.visible=!!(t.constraints&mr.UserHandle)),l)if(d.pathData){var f=d.pathData?d.pathData:d.content,g=this.getBaseAttributes(a);g.id=d.name+"_userhandle",g.fill=d.backgroundColor,g.stroke=d.borderColor,g.strokeWidth=d.borderWidth,g.centerX=p.x,g.centerY=p.y,g.radius=.5*d.size,g.class="e-diagram-userhandle-circle",g.angle=0,g.visible=d.visible,g.opacity=1,this.svgRenderer.drawCircle(e,g,1,{"aria-label":d.name+"user handle"});var y=[];y=II(y=Dd(f));var S=af(f),w=SI(y,(d.size-.45*d.size)/S.width,(d.size-.45*d.size)/S.height,!0,S.x,S.y,0,0);S=af(w),this.svgRenderer.drawPath(e,C={x:p.x-S.width/2,y:p.y-S.height/2,angle:0,id:"",class:"e-diagram-userhandle-path",fill:d.pathColor,stroke:d.backgroundColor,strokeWidth:.5,dashArray:"",data:w,width:d.size-5,height:d.size-5,pivotX:0,pivotY:0,opacity:1,visible:d.visible},this.diagramId,void 0,void 0,{"aria-label":d.name+"user handle"})}else if(d.content){var D=new Cn(d.name,this.diagramId);D.content=d.content,D.offsetX=p.x,D.offsetY=p.y,D.id=d.name+"_shape",D.horizontalAlignment="Center",D.verticalAlignment="Center",D.visible=d.visible,D.setOffsetWithRespectToBounds(p.x,p.y,"Fraction"),D.relativeMode="Object",D.description=d.name||"User handle",D.measure(new me(d.size,d.size)),D.arrange(D.desiredSize),this.svgRenderer.drawNativeContent(D,e,d.size,d.size,this.adornerSvgLayer)}else if(d.source){var C,A=new CI;(C=this.getBaseAttributes(A,i)).width=d.size,C.height=d.size,C.x=p.x-d.size/2,C.y=p.y-d.size/2,C.sourceWidth=d.size,C.sourceHeight=d.size,C.alignment=A.imageAlign,C.source=d.source,C.scale=A.imageScale,C.visible=d.visible,C.description=d.name||"User handle",C.id=d.name+"_",this.renderer.drawImage(e,C,this.adornerSvgLayer,!1)}else{var x=new Jn(d.name,this.diagramId);x.offsetX=p.x,x.offsetY=p.y,x.id=d.name+"_shape",x.visible=d.visible,x.relativeMode="Object",x.template=d.template,x.measure(new me(d.size,d.size)),x.arrange(x.desiredSize),this.svgRenderer.drawHTMLContent(x,r,void 0,!0,void 0)}}},n.prototype.renderRotateThumb=function(t,e,i,r,s){new Ke;var a,l=new me;l.width=18,l.height=16;var d=!!(r&mr.Rotate);s&&(d=!1);var p=t.offsetX-t.actualSize.width*t.pivot.x+t.pivot.x*t.actualSize.width,f=t.offsetY-t.actualSize.height*t.pivot.y;if(a={x:(p=(p+i.tx)*i.scale)-.5*l.width,y:(f=(f+i.ty)*i.scale)-30-.5*l.height},0!==t.rotateAngle||0!==t.parentTransform){var g=Hi();qi(g,t.rotateAngle+t.parentTransform,(i.tx+t.offsetX)*i.scale,(i.ty+t.offsetY)*i.scale),a=Je(g,a)}this.svgRenderer.drawPath(e,{x:a.x,y:a.y,angle:t.rotateAngle+t.parentTransform,fill:"#231f20",stroke:"black",strokeWidth:.5,dashArray:"",data:"M 16.856144362449648 10.238890446662904 L 18.000144362449646 3.437890446662903L 15.811144362449646 4.254890446662903 C 14.837144362449646 2.5608904466629028 13.329144362449647 1.2598904466629026 11.485144362449645 0.5588904466629026 C 9.375144362449646 - 0.24510955333709716 7.071144362449646 - 0.18010955333709716 5.010144362449646 0.7438904466629028 C 2.942144362449646 1.6678904466629028 1.365144362449646 3.341890446662903 0.558144362449646 5.452890446662903 C - 0.244855637550354 7.567890446662903 - 0.17985563755035394 9.866890446662904 0.7431443624496461 11.930890446662904 C 1.6681443624496461 13.994890446662904 3.343144362449646 15.575890446662903 5.457144362449647 16.380890446662903 C 6.426144362449647 16.7518904466629 7.450144362449647 16.9348904466629 8.470144362449647 16.9348904466629 C 9.815144362449647 16.9348904466629 11.155144362449647 16.6178904466629 12.367144362449647 15.986890446662901 L 11.351144362449647 14.024890446662901 C 9.767144362449647 14.8468904466629 7.906144362449647 14.953890446662902 6.237144362449647 14.3178904466629 C 4.677144362449647 13.7218904466629 3.444144362449647 12.5558904466629 2.758144362449647 11.028890446662901 C 2.078144362449646 9.501890446662903 2.031144362449646 7.802890446662903 2.622144362449646 6.243890446662903 C 3.216144362449646 4.6798904466629025 4.387144362449646 3.442890446662903 5.914144362449646 2.760890446662903 C 7.437144362449646 2.078890446662903 9.137144362449646 2.0298904466629026 10.700144362449645 2.6258904466629027 C 11.946144362449646 3.100890446662903 12.971144362449646 3.9538904466629026 13.686144362449646 5.049890446662903 L 11.540144362449645 5.850890446662903 L 16.856144362449648 10.238890446662904 Z",width:20,height:20,pivotX:0,pivotY:0,opacity:1,visible:d,id:"rotateThumb",class:"e-diagram-rotate-handle"},this.diagramId,!0,void 0,{"aria-label":"Thumb to rotate the selected object"})},n.prototype.renderPathElement=function(t,e,i,r,s,o,a){var l=this.getBaseAttributes(t,i,o);if(l.data=t.absolutePath,l.data=t.absolutePath,t.isPathPort&&a){l.x=a[t.id]?a[t.id].cx:l.x,l.y=a[t.id]?a[t.id].cy:l.y,t.bounds.x=l.x,t.bounds.y=l.y;var h=document.getElementById(this.diagramId);h&&"PortDrag"!==h.ej2_instances[0].eventHandler.currentAction&&(t.offsetX=l.x+t.width/2,t.offsetY=l.y+t.height/2)}var u=t.description?t.description:t.id;if(this.isSvgMode||(l.x=t.flipOffset.x?t.flipOffset.x:l.x,l.y=t.flipOffset.y?t.flipOffset.y:l.y),t.isExport){var p=t.absoluteBounds,f=Dd(l.data),g=this.findAndStoreArcValues(f);l.arc=g,l.data=BF(t,p,0,l)}this.renderer.drawPath(e,l,this.diagramId,void 0,r,u)},n.prototype.findAndStoreArcValues=function(t){var e=[];return t.forEach(function(i){"A"===i.command&&e.push({r1:i.r1/2,r2:i.r2/2})}),e},n.prototype.renderSvgGridlines=function(t,e,i,r,s,o){var a=document.createElementNS("http://www.w3.org/2000/svg","pattern"),l=document.createElementNS("http://www.w3.org/2000/svg","defs");l.setAttribute("id",this.diagramId+"_grid_pattern_defn"),(t.constraints&Kt.ShowHorizontalLines||t.constraints&Kt.ShowVerticalLines)&&a.setAttribute("id",this.diagramId+"_pattern");var h=0,c=0,d=0,u=0,p=1,f=!1,g="Lines"===t.gridType,v=g?t.verticalGridlines.lineIntervals:t.verticalGridlines.dotIntervals,y=g?t.horizontalGridlines.lineIntervals:t.horizontalGridlines.dotIntervals;if(r.showRulers&&r.dynamicGrid&&s&&o)d=o.updateSegmentWidth(i.scale),u=s.updateSegmentWidth(i.scale),t.horizontalGridlines.scaledIntervals=[d/s.interval],t.verticalGridlines.scaledIntervals=[u/o.interval],f=!0;else{for(var S=0;S=2)for(;e>=2;)e/=2;else if(e<=.5)for(;e<=.5;)e*=2;var i;if(t.horizontalGridlines.scaledIntervals=t.horizontalGridlines.snapIntervals,t.verticalGridlines.scaledIntervals=t.verticalGridlines.snapIntervals,1!==e){var r=t.horizontalGridlines;for(r.scaledIntervals=[],i=0;ithis.groupElement.actualSize.height&&("Clip"===t.style.textOverflow||"Ellipsis"===t.style.textOverflow)&&(a.y=a.y+(a.height-this.groupElement.actualSize.height)/2),this.renderer.drawRectangle(e,a,this.diagramId,void 0,void 0,r),this.renderer.drawText(e,a,r,l,this.diagramId,t.isExport&&Math.min(t.exportScaleValue.x||t.exportScaleValue.y),this.groupElement),this.isSvgMode&&(t.doWrap=!1)},n.prototype.renderNativeElement=function(t,e,i,r,s){var o,a,l=this.getParentSvg(t,void 0,e)||r,h=this.getParentElement(t,e,l).g||e,c=this.getBaseAttributes(t,i);switch(c.fill="transparent",c.cornerRadius=t.cornerRadius,c.stroke="transparent",this.renderer.drawRectangle(e,c,this.diagramId,void 0,void 0,r),t.scale){case"None":o=t.contentSize.width,a=t.contentSize.height;break;case"Stretch":o=t.actualSize.width,a=t.actualSize.height;break;case"Meet":o=a=t.actualSize.width<=t.actualSize.height?t.actualSize.width:t.actualSize.height;break;case"Slice":o=a=t.actualSize.width>=t.actualSize.height?t.actualSize.width:t.actualSize.height}this.svgRenderer&&this.svgRenderer.drawNativeContent(t,h,a,o,l)},n.prototype.renderHTMLElement=function(t,e,i,r,s,o,a){var l=this.getBaseAttributes(t,r);l.fill="transparent",l.cornerRadius=t.cornerRadius,l.stroke="transparent",this.renderer.drawRectangle(e,l,this.diagramId,void 0,void 0,s),this.svgRenderer&&this.svgRenderer.drawHTMLContent(t,i.children[0],r,function Sse(n){var t=n.parentElement;do{if(pm(t,"e-diagram"))return!0;t=t.parentElement}while(t);return!1}(i),a)},n.prototype.renderImageElement=function(t,e,i,r,s){var o=this.getBaseAttributes(t,i);o.cornerRadius=0,this.renderer.drawRectangle(e,o,this.diagramId,void 0,void 0,r);var a,l,h,c,g,d=t.contentSize.width,u=t.contentSize.height,p=o.width/d,f=o.height/u;if("Stretch"===t.stretch)a=d*(g=Math.min(p,f)),l=u*g;else switch(t.stretch){case"Meet":a=d*(g=Math.min(p,f)),l=u*g,o.x+=Math.abs(o.width-a)/2,o.y+=Math.abs(o.height-l)/2;break;case"Slice":g=Math.max(p,f),h=o.width/(a=d*g)*d,c=o.height/(l=u*g)*u;break;case"None":a=d,l=u}o.width=a,o.height=l,o.sourceWidth=h,o.sourceHeight=c,o.source=t.source,o.alignment=t.imageAlign,o.scale=t.imageScale,o.description=t.description?t.description:t.id,this.renderer.drawImage(e,o,r,s)},n.prototype.renderContainer=function(t,e,i,r,s,o,a,l,h,c,d){var g,u={svg:s,g:e},p=document.getElementById(this.diagramId);if(p&&(g=p.ej2_instances[0]),this.diagramId&&(s=this.getParentSvg(t)||s,this.isSvgMode)){var v=this.getParentElement(t,e,s,l).g||e;s=this.getParentSvg(this.hasNativeParent(t.children))||s;var y=this.getParentElement(this.hasNativeParent(t.children),v,s,l);u.svg=y.svg||s,u.g=y.g||v,o&&s&&(s.getElementById(u.g.id)||e.appendChild(u.g)),e=u.g}if(this.renderRect(t,e,r,s),this.groupElement=t,t.hasChildren()){for(var b,S=void 0,M=0,w=t.children;M0&&(D=g.selectedItems.nodes[0]);var L,A=void 0,x=void 0,R=!1;if(g&&g.selectedItems&&(L=g.getObject(t.id)),"None"!==t.flip&&(D=L),"None"===t.flip&&(D=L),D&&D.flipMode&&(R=!0),!(t.elementActions&Xr.ElementIsGroup)&&g instanceof Rl&&g.nameTable[t.id]&&"connectors"!==g.nameTable[t.id].propName&&R&&D){if(A=t.children&&t.children[0]instanceof Cn?document.getElementById(D.id+"_content_inner_native_element"):document.getElementById(D.id+"_content_groupElement"),!(t.children[0]instanceof Cn)&&"Text"!==D.shape.type&&"None"!==D.flipMode&&"Label"!==D.flipMode&&"All"!==D.flipMode&&"PortAndLabel"!==D.flipMode&&"LabelText"!==D.flipMode&&"PortAndLabelText"!==D.flipMode&&"LabelAndLabelText"!==D.flipMode||t.children[0]instanceof Cn&&"Port"===D.flipMode)return void this.renderFlipElement(t,A,D.flip);if((t.children[0]instanceof Cn&&("All"===D.flipMode||"Label"===D.flipMode)||"Label"===D.flipMode||"PortAndLabel"===D.flipMode||"LabelText"===D.flipMode||"PortAndLabelText"===D.flipMode||"LabelAndLabelText"===D.flipMode||"Image"===D.shape.type&&"Label"===D.flipMode)&&this.renderFlipElement(t,A,t.flip),"None"!==t.flip&&"None"===D.flipMode)this.renderFlipElement(t,A,t.flip);else if("None"!==t.flip&&("Label"===D.flipMode||"PortAndLabel"===D.flipMode||"LabelText"===D.flipMode||"PortAndLabelText"===D.flipMode||"LabelAndLabelText"===D.flipMode)||t.children[0]instanceof Cn&&"None"!==t.flip&&D&&("None"===D.flipMode||"All"===D.flipMode)){for(var O=0;O0){var i=t[0];if(i instanceof Cn)return i;i.children&&i.children.length&&this.hasNativeParent(i.children,e++||0)}},n.prototype.renderRect=function(t,e,i,r,s){var o=this.getBaseAttributes(t,i,s);o.cornerRadius=t.cornerRadius||0,t.isExport&&(o.cornerRadius*=t.exportScaleValue.x),this.renderer.drawRectangle(e,o,this.diagramId,t.isExport,void 0,r,t.description?t.description:t.id)},n.prototype.drawRect=function(t,e){e.cornerRadius=0,this.svgRenderer.drawRectangle(t,e,this.diagramId)},n.prototype.getBaseAttributes=function(t,e,i){var r={width:t.actualSize.width,height:t.actualSize.height,x:t.offsetX-t.actualSize.width*t.pivot.x,y:t.offsetY-t.actualSize.height*t.pivot.y,fill:t.style.fill,stroke:t.style.strokeColor,angle:t.rotateAngle+t.parentTransform,pivotX:t.pivot.x,pivotY:t.pivot.y,strokeWidth:t.style.strokeWidth,dashArray:t.style.strokeDashArray||"",opacity:t.style.opacity,shadow:t.shadow,gradient:t.style.gradient,visible:t.visible,id:t.id,description:t.description,canApplyStyle:t.canApplyStyle,shapeType:t.shapeType};return"Page"===t.rotationReference&&(r.angle=t.rotateAngle),i&&(r.x=r.x-.5,r.y=r.y-.5),t.isExport&&(r.width*=t.exportScaleValue.x,r.height*=t.exportScaleValue.y,r.x*=t.exportScaleValue.x,r.y*=t.exportScaleValue.y,r.strokeWidth*=t.exportScaleValue.x),t.flip&&(r.flip=t.flip),e&&(r.x+=e.tx,r.y+=e.ty),r},n.renderSvgBackGroundImage=function(t,e,i,r,s,o){if(t.source){var l=IT(e.id).getElementById(e.id+"_image");if(!l){var h=function Toe(n){return xt(n).getElementsByClassName("e-background-image-layer")[0]}(e.id);(l=document.createElementNS("http://www.w3.org/2000/svg","image")).setAttribute("id",e.id+"_image"),h.appendChild(l)}var c=new Image;c.src=t.source,l.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",c.src.toString());var d="None"!==t.scale?t.scale:"",u=t.align,p=u.charAt(0).toLowerCase()+u.slice(1);d&&(p+=" "+d.charAt(0).toLowerCase()+d.slice(1)),oi(l,{id:e.id+"_image",x:i,y:r,width:s,height:o,preserveAspectRatio:p})}},n.prototype.transformLayers=function(t,e){var i=t.tx*t.scale,r=t.ty*t.scale,s="domTable";if(i!==this.transform.x||r!==this.transform.y||0===i||0===r){e&&(window[""+s][this.diagramId+"_diagramLayer"]||(window[""+s][this.diagramId+"_diagramLayer"]=this.diagramSvgLayer.getElementById(this.diagramId+"_diagramLayer")),window[""+s][this.diagramId+"_diagramLayer"].setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+"),scale("+t.scale+")"));var a=function Aoe(n){var t="domTable",e=null;return window[t][n+"_gridline"]?e=window[t][n+"_gridline"]:(e=_d(n).getElementById(n+"_gridline"),window[t][n+"_gridline"]=e),e}(this.diagramId);return a.setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+")"),window[""+s][this.diagramId+"_diagramPorts"]||(window[""+s][this.diagramId+"_diagramPorts"]=this.iconSvgLayer.getElementById(this.diagramId+"_diagramPorts")),window[""+s][this.diagramId+"_diagramPorts"].setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+"),scale("+t.scale+")"),window[""+s][this.diagramId+"_diagramExpander"]||(window[""+s][this.diagramId+"_diagramExpander"]=this.iconSvgLayer.getElementById(this.diagramId+"_diagramExpander")),window[""+s][this.diagramId+"_diagramExpander"].setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+"),scale("+t.scale+")"),window[""+s][this.diagramId+"_nativeLayer"]||(window[""+s][this.diagramId+"_nativeLayer"]=this.nativeSvgLayer.getElementById(this.diagramId+"_nativeLayer")),window[""+s][this.diagramId+"_nativeLayer"].setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+"),scale("+t.scale+")"),Io(this.diagramId).children[0].style.transform="translate("+t.tx*t.scale+"px,"+t.ty*t.scale+"px)scale("+t.scale+")",this.transform={x:t.tx*t.scale,y:t.ty*t.scale},!0}return!1},n.prototype.updateNode=function(t,e,i,r,s,o,a){this.renderElement(t,e,i,r,this.getParentSvg(t),void 0,void 0,s,null,o,a)},n}(),use=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),tb=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},uF=function(n){function t(e,i){var r=n.call(this,e,i)||this;return r.mode="Canvas",r.id="overview",r.actionName="",r.startPoint=null,r.currentPoint=null,r.prevPoint=null,r.scale=null,r.inAction=!1,r.viewPortRatio=1,r.horizontalOffset=0,r.verticalOffset=0,r.model={},r.event=!0,r.overviewid=88123,r.model={width:r.width,height:r.height},r}return use(t,n),t.prototype.onPropertyChanged=function(e,i){for(var r=0,s=Object.keys(e);r0||e.toString().indexOf("%")>0?e.toString():e.toString()+"px"},t.prototype.renderCanvas=function(e){var i=document.getElementById(this.element.id+"_canvas");i||(i=Tt("div",{}),this.element.appendChild(i)),Ho(i,{id:this.element.id+"_canvas",class:"drawing",style:"position:relative; height:"+this.getSizeValue(this.model.height)+"; width:"+this.getSizeValue(this.model.width)+";style:-ms-touch-action: none;touch-action: none;"}),this.element.setAttribute("tabindex",String(-1)),this.element.style.overflow="hidden",this.element.style.height=String(this.model.height),this.element.style.width=String(this.model.width),this.canvas=i},t.prototype.setParent=function(e){var i=document.getElementById(e);if(this.parent){var s=this.parent;this.parent=null,s.setOverview(null,this.element.id),this.removeDocument(this)}this.parent=this.getDiagram(i,"ej2_instances"),this.parent&&this.parent.setOverview(this)},t.prototype.getDiagram=function(e,i){for(var r,s=e[""+i].length,o=0;o0?p:Math.floor(window.innerWidth)}if(0===h){var f=Math.floor(window.innerHeight-u-Math.floor(c.top));h=f>0?f:Math.floor(window.innerHeight)}l>0&&(s.setAttribute("width",String(l)),this.model.height=h),h>0&&(s.setAttribute("height",String(h)),this.model.width=l),e.diagramLayerDiv||(e.diagramLayerDiv=Tt("div",{}),e.diagramLayer=bo.createCanvas(this.element.id+"_diagramLayer",this.model.width,this.model.height),e.diagramLayer.setAttribute("style","position:absolute; left:0px; top:0px "),e.diagramLayerDiv.appendChild(e.diagramLayer),e.canvas.appendChild(e.diagramLayerDiv)),Ho(e.diagramLayerDiv,{id:this.element.id+"_diagramLayer_div",style:"width:"+this.model.width+"px; height:"+this.model.height+"px;position:absolute;top:0px;left:0px"}),this.renderHtmlLayer(e.canvas),this.renderNativeLayer(e.canvas,e),this.addOverviewRectPanel(e)},t.prototype.removeDocument=function(e){var i=document.getElementById(this.canvas.id+"_svg");this.canvas.removeChild(i);var r=document.getElementById(this.element.id+"_htmlLayer");this.canvas.removeChild(r);var s=document.getElementById(this.element.id+"_diagramLayer_div");this.canvas.removeChild(s),e.diagramLayerDiv=null,e.diagramLayer=null,window.domTable[this.id+"html_layer"]=null},t.prototype.renderHtmlLayer=function(e){var i=Tt("div",{id:this.element.id+"_htmlLayer",class:"e-html-layer",style:"pointer-events:none;position:absolute;top:0px;left:0px;"}),s=Tt("div",{id:this.element.id+"_htmlLayer_div",style:"position:absolute;top:0px;left:0px;"});return i.appendChild(s),e.appendChild(i),i},t.prototype.renderNativeLayer=function(e,i){if(!document.getElementById(this.element.id+"_nativeLayer_svg")){var r=this.parent.createSvg(this.element.id+"_nativeLayer_svg",this.model.width,this.model.height),s=Bi("g",{id:this.element.id+"_nativeLayer"});r.appendChild(s),i.diagramLayerDiv.appendChild(r),oi(r,{class:"e-native-layer"})}},t.prototype.addOverviewRectPanel=function(e){var i=document.getElementById(this.canvas.id+"_overviewsvg");i&&i.parentNode.removeChild(i),i=Bi("svg",{id:this.canvas.id+"_overviewsvg",class:"overviewsvg",version:"1.1",style:"position:absolute;left:0px;top:0px; aria-label:Specifies overview",width:this.model.width,height:this.model.height}),e.canvas.appendChild(i);var s=Bi("g",{id:this.element.id+"_overviewlayer",style:"pointer-events:none"});i.appendChild(s);var o=Bi("rect",{fill:"transparent",width:"100%",height:"100%",class:"overviewbackrect",id:this.canvas.id+"overviewbackrect"});o.setAttribute("style"," pointer-events: none; "),s.appendChild(o);var a=Bi("g",{id:this.canvas.id+"overviewhandle",style:"pointer-events:all"});s.appendChild(a);var l=Bi("rect",{id:this.canvas.id+"overviewrect",fill:"transparent"});a.appendChild(l),this.renderOverviewCorner("left",a),this.renderOverviewCorner("right",a),this.renderOverviewCorner("top",a),this.renderOverviewCorner("bottom",a),this.renderOverviewCorner("topleft",a),this.renderOverviewCorner("topright",a),this.renderOverviewCorner("bottomleft",a),this.renderOverviewCorner("bottomright",a)},t.prototype.renderOverviewCorner=function(e,i){var s,o=Bi(s="top"===e||"bottom"===e||"right"===e||"left"===e?"rect":"circle",{id:this.canvas.id+"visible"+e,class:"overview-resizer"});i.appendChild(o);var a=Bi(s,{id:this.canvas.id+e,class:"overviewresizer",fill:"transparent"});i.appendChild(a)},t.prototype.updateOverviewRectangle=function(){var e=this.currentPoint.x-this.prevPoint.x,i=this.currentPoint.y-this.prevPoint.y,r=new me;r.width=0,r.height=0;var s=0,o=0;switch(this.resizeDirection){case"left":r.width-=e,r.height-=e/this.viewPortRatio,s=e,o=e/this.viewPortRatio,o/=2;break;case"right":r.width+=e,r.height+=e/this.viewPortRatio,o=e/this.viewPortRatio,o/=-2;break;case"top":r.height-=i,r.width-=i*this.viewPortRatio,o=i,s=i*this.viewPortRatio,s/=2;break;case"bottom":r.height+=i,r.width+=i*this.viewPortRatio,s=i*this.viewPortRatio,s/=-2;break;case"topleft":Math.abs(i)>Math.abs(e)?e=i*this.viewPortRatio:i=e/this.viewPortRatio,r.width-=e,r.height-=i,s=e,o=i;break;case"topright":Math.abs(i)>Math.abs(e)?e=-i*this.viewPortRatio:i=-e/this.viewPortRatio,o=i,r.width+=e,r.height-=i;break;case"bottomleft":Math.abs(i)>Math.abs(e)?e=-i*this.viewPortRatio:i=-e/this.viewPortRatio,s=e,r.width-=e,r.height+=i;break;case"bottomright":Math.abs(i)>Math.abs(e)?e=i*this.viewPortRatio:i=e/this.viewPortRatio,r.width+=e,r.height+=i}this.updateHelper(s,o,r,void 0,void 0)},t.prototype.updateHelper=function(e,i,r,s,o){var a,l,h,u,p,d=this.element.getElementsByTagName("svg")[2].getElementById("helper");r?(a=(h=d.getBBox()).x+e,l=h.y+i,s=h.width+r.width,o=h.height+r.height):(u=this.currentPoint.x>this.startPoint.x?this.currentPoint.x-this.prevPoint.x:this.prevPoint.x-this.currentPoint.x,p=this.currentPoint.y>this.startPoint.y?this.currentPoint.y-this.prevPoint.y:this.prevPoint.y-this.currentPoint.y,Math.abs(p)>Math.abs(u)?u=this.viewPortRatio*p:p=u/this.viewPortRatio,h=d.getBBox(),a=this.startPoint.x>this.currentPoint.x?h.x-u:h.x,l=this.startPoint.y>this.currentPoint.y?h.y-p:h.y,s=h.width+u,o=h.height+p),oi(this.helper,{id:this.helper.id,x:a,y:l,width:Math.max(0,s),height:Math.max(0,o)})},t.prototype.updateOverviewrect=function(e,i,r,s){Ho(document.getElementById(this.canvas.id+"overviewrect"),{x:e,y:i,width:Math.max(1,r),height:Math.max(1,s)}),this.updateOverviewCorner("top",e+8,i+1,Math.max(0,r-16),2),this.updateOverviewCorner("bottom",e+8,i+s+3,Math.max(0,r-16),2),this.updateOverviewCorner("left",e-2,i+11,2,Math.max(0,s-16)),this.updateOverviewCorner("right",e+r,i+11,2,Math.max(0,s-16)),this.updateOverviewCorner("topleft",e,i+3,5,5),this.updateOverviewCorner("topright",e+r,i+3,5,5),this.updateOverviewCorner("bottomleft",e,i+s+3,5,5),this.updateOverviewCorner("bottomright",e+r,i+s+3,5,5)},t.prototype.updateOverviewCorner=function(e,i,r,s,o){var a,l;"top"===e||"bottom"===e||"right"===e||"left"===e?(a={x:i,y:r,width:s,height:o,fill:"#ED1C24"},l={x:i-2,y:r-2,width:2===s?4:s,height:2===o?4:o}):(a={cx:i,cy:r,r:4,fill:"#ED1C24"},l={cx:i,cy:r,r:6,fill:"transparent"}),Ho(document.getElementById(this.canvas.id+"visible"+e),a),Ho(document.getElementById(this.canvas.id+e),l)},t.prototype.translateOverviewRectangle=function(){Number(this.model.width),Number(this.model.height);var r=this.currentPoint.x-this.prevPoint.x,s=this.currentPoint.y-this.prevPoint.y,l=this.element.getElementsByClassName("overviewsvg")[0].getElementById(this.canvas.id+"overviewrect").getBBox(),h=l.x+r,c=l.y+s,d=l.width,u=l.height;this.updateOverviewrect(h,c,d,u),this.updateParentView(this.parent.scroller.currentZoom,h,c,d,u,null)},t.prototype.renderOverviewRect=function(e,i,r,s){var o=Number(this.model.width),a=Number(this.model.height),c=Math.max(this.parent.scroller.viewPortWidth/(r/o*this.contentWidth),this.parent.scroller.viewPortHeight/(s/a*this.contentHeight));if(c>=.25&&c<=30){this.updateParentView(c,e,i,r,s,{x:0,y:0});var u=this.scrollOverviewRect(this.parent.scroller.horizontalOffset,this.parent.scroller.verticalOffset,this.parent.scroller.currentZoom,!0);if(this.helper){var f=this.element.getElementsByTagName("rect")[10].getBBox();u.x=f.x,u.y=f.y}"pan"===this.actionName?this.updateOverviewrect(-u.x,-u.y,u.width,u.height):this.updateOverviewrect(u.x,u.y,u.width,u.height)}},t.prototype.scrollOverviewRect=function(e,i,r,s){if(!this.actionName||s){var o=Number(this.model.width),a=Number(this.model.height),l=Math.min(this.contentWidth/o,this.contentHeight/a),h=new Ne,c=h.x=e/r/l,d=h.y=i/r/l,u=0;this.parent.rulerSettings.showRulers&&(u=25);var p=document.getElementById(this.parent.element.id+"content"),f=0,g=0;p&&(f=p.offsetWidth-p.clientWidth,g=p.offsetHeight-p.clientHeight);var v=h.width=(this.parent.scroller.viewPortWidth-u-f)/r/l,y=h.height=(this.parent.scroller.viewPortHeight-u-g)/r/l;if(s){var S=new Ne;return S.x=c,S.y=d,S.width=v,S.height=y,S}this.updateOverviewrect(-c,-d,v,y)}return null},t.prototype.updateParentView=function(e,i,r,s,o,a){var f,g,l=Number(this.model.width),h=Number(this.model.height),u=i*(this.contentWidth/l)*e,p=r*(this.contentHeight/h)*e;this.parent.scroller.getPageBounds(),(1!==e||"pan"===this.actionName)&&(f=-u-this.parent.scroller.horizontalOffset,g=-p-this.parent.scroller.verticalOffset),this.parent.setBlazorDiagramProps(!0),this.parent.realActions|=$i.OverViewAction,"scale"===this.actionName||"draw"===this.actionName?this.parent.scroller.zoom(e/this.parent.scroller.currentZoom,f,g,a):ce()?this.parent.scroller.zoom(1,f,g,a):this.parent.pan(f,g,a,!0)},t.prototype.updateHtmlLayer=function(e){var i=Io(e.element.id),r=this.parent.scroller.getPageBounds(!0),o=r.height,a=Math.max(r.width,this.parent.scroller.viewPortWidth),l=Math.max(o,this.parent.scroller.viewPortHeight/this.parent.scroller.currentZoom),h=Math.min(Number(this.model.width)/a,Number(this.model.height)/l);i.style.transform="scale("+h+") translate("+this.parent.scroller.transform.tx+"px,"+this.parent.scroller.transform.ty+"px)"},t.prototype.updateView=function(e){var i=this.parent.scroller.getPageBounds(),r=i.width,s=i.height,o=Number(this.model.width),a=Number(this.model.height),l=Math.max(r,this.parent.scroller.viewPortWidth),h=Math.max(s,this.parent.scroller.viewPortHeight);this.contentWidth=l=Math.max(l,o/a*h),this.contentHeight=h=Math.max(h,a/o*l);var c=Math.min(o/l,a/h),d=document.getElementById(this.element.id+"_htmlLayer");d.style.webkitTransform="scale("+c+") translate("+-i.x+"px,"+-i.y+"px)",d.style.transform="scale("+c+") translate("+-i.x+"px,"+-i.y+"px)",document.getElementById(this.element.id+"_overviewlayer").setAttribute("transform","translate("+-i.x*c+","+-i.y*c+")"),this.horizontalOffset=i.x*c,this.verticalOffset=i.y*c;var p=document.getElementById(this.element.id+"_diagramLayer"),f=UF(this.element.id),g=p.getContext("2d"),v=Number(this.model.width)/this.contentWidth,y=Number(this.model.height)/this.contentHeight;v=Math.min(v,y);var S=this.parent.scroller.transform;f.setAttribute("transform","translate("+S.tx*v+","+S.ty*y+"),scale("+v+")"),g.setTransform(v,0,0,v,0,0),g.fillStyle="red",this.scrollOverviewRect(this.parent.scroller.horizontalOffset,this.parent.scroller.verticalOffset,this.parent.scroller.currentZoom)},t.prototype.scrolled=function(e){if(this.event){var i=this.scrollOverviewRect(this.parent.scroller.horizontalOffset,this.parent.scroller.verticalOffset,this.parent.scroller.currentZoom,!0);this.updateOverviewrect(-i.x,-i.y,i.width,i.height),this.updateView(this)}},t.prototype.updateCursor=function(e){if(pm(e.target,"overviewresizer"))switch(e.target.id){case this.canvas.id+"left":this.canvas.style.cursor="w-resize";break;case this.canvas.id+"right":this.canvas.style.cursor="e-resize";break;case this.canvas.id+"top":this.canvas.style.cursor="n-resize";break;case this.canvas.id+"bottom":this.canvas.style.cursor="s-resize";break;case this.canvas.id+"topleft":this.canvas.style.cursor="nw-resize";break;case this.canvas.id+"topright":this.canvas.style.cursor="ne-resize";break;case this.canvas.id+"bottomleft":this.canvas.style.cursor="sw-resize";break;case this.canvas.id+"bottomright":this.canvas.style.cursor="se-resize"}else this.canvas.style.cursor="default"},t.prototype.mouseMove=function(e){if(this.event=!1,this.updateCursor(e),this.currentPoint=this.mousePosition(e),this.actionName)switch(this.actionName){case"draw":!this.inAction&&(this.startPoint.x!==this.currentPoint.x||this.startPoint.y!==this.currentPoint.y)&&(this.initHelper(),this.inAction=!0),this.inAction&&this.updateHelper();break;case"scale":this.inAction||(this.initHelper(),this.inAction=!0),this.updateOverviewRectangle();break;case"pan":(this.startPoint.x!==this.currentPoint.x||this.startPoint.y===this.currentPoint.y||this.inAction)&&(this.inAction=!0,this.translateOverviewRectangle())}this.prevPoint=this.currentPoint},t.prototype.documentMouseUp=function(e){this.inAction=!1,this.actionName="",this.helper&&(this.helper.parentNode.removeChild(this.helper),this.helper=null),this.event=!0,document.getElementById(this.canvas.id+"overviewhandle").style.pointerEvents="all"},t.prototype.windowResize=function(e){var i=this;return this.resizeTo&&clearTimeout(this.resizeTo),this.resizeTo=setTimeout(function(){var s=document.getElementById(i.element.id).getBoundingClientRect();i.model.width=s.width>0?s.width:i.model.width,i.model.height=s.height>0?s.height:i.model.height,i.renderCanvas(),i.setParent(i.sourceID)},10),!1},t.prototype.mouseDown=function(e){if(e.target.id===this.canvas.id+"_overviewsvg"&&(this.actionName="draw"),e.target.id===this.canvas.id+"overviewrect"&&(this.actionName="pan"),pm(e.target,"overviewresizer"))switch(this.actionName="scale",e.target.id){case this.canvas.id+"left":this.resizeDirection="left";break;case this.canvas.id+"right":this.resizeDirection="right";break;case this.canvas.id+"top":this.resizeDirection="top";break;case this.canvas.id+"bottom":this.resizeDirection="bottom";break;case this.canvas.id+"topleft":this.resizeDirection="topleft";break;case this.canvas.id+"topright":this.resizeDirection="topright";break;case this.canvas.id+"bottomleft":this.resizeDirection="bottomleft";break;case this.canvas.id+"bottomright":this.resizeDirection="bottomright"}this.startPoint=this.prevPoint=this.mousePosition(e),this.viewPortRatio=this.parent.scroller.viewPortWidth/this.parent.scroller.viewPortHeight,document.getElementById(this.canvas.id+"overviewhandle").style.pointerEvents="none"},t.prototype.mouseUp=function(e){if(this.currentPoint=this.mousePosition(e),this.actionName)if(this.startPoint.x!==this.currentPoint.x||this.startPoint.y!==this.currentPoint.y){if("pan"!==this.actionName&&this.helper){var i=this.element.getElementsByTagName("rect")[10].getBBox();this.resizeDirection=this.resizeDirection||"",this.renderOverviewRect(i.x,i.y,o=i.width,a=i.height)}}else if(e.target.id===this.canvas.id+"_overviewsvg"||"helper"===e.target.id){var o=(i=this.element.getElementsByTagName("svg")[2].getElementById(this.canvas.id+"overviewrect").getBBox()).width,a=i.height;this.inAction=!0,this.actionName="pan",this.renderOverviewRect(this.currentPoint.x-o/2,this.currentPoint.y-a/2,o,a),this.inAction=!1}this.helper&&(this.helper.parentNode.removeChild(this.helper),this.helper=null),this.actionName="",this.startPoint=null,this.currentPoint=null,this.prevPoint=null,this.helper=null,this.viewPortRatio=1,this.resizeDirection="",this.inAction=!1,this.event=!0,document.getElementById(this.canvas.id+"overviewhandle").style.pointerEvents="all"},t.prototype.initHelper=function(){var e=this.element.getElementsByTagName("svg")[2],i=this.startPoint.x,r=this.startPoint.y,s=1,o=1;if("scale"===this.actionName){var l=e.getElementById(this.canvas.id+"overviewrect").getBBox();i=l.x,r=l.y,s=l.width,o=l.height}var h=Bi("rect",{id:"helper",x:i,y:r,width:s,height:o,fill:"transparent",stroke:"gray","stroke-dasharray":"2 2","shape-rendering":"crispEdges"});e.getElementById(this.element.id+"_overviewlayer").appendChild(h),this.helper=h},t.prototype.mousePosition=function(e){var i,r,s;-1!==e.type.indexOf("touch")?(r=(i=e).changedTouches[0].clientX-this.element.offsetLeft,s=i.changedTouches[0].clientY-this.element.offsetTop):(r=e.clientX,s=e.clientY);var l=this.element.getBoundingClientRect();return{x:(r-=l.left)+this.horizontalOffset,y:(s-=l.top)+this.verticalOffset}},t.prototype.destroy=function(){if(this.unWireEvents(),this.notify("destroy",{}),n.prototype.destroy.call(this),document.getElementById(this.element.id)){this.element.classList.remove("e-overview");var e=document.getElementById(this.element.id+"_canvas");e&&this.element.removeChild(e)}this.parent.views.splice(this.parent.views.indexOf(this.element.id),1),this.diagramLayerDiv=null,this.canvas=null,this.parent=null},t.prototype.getModuleName=function(){return"Overview"},tb([I("100%")],t.prototype,"width",void 0),tb([I("100%")],t.prototype,"height",void 0),tb([I("")],t.prototype,"sourceID",void 0),tb([H()],t.prototype,"created",void 0),t}(yi);function fse(n,t){for(var e=0;ez.findLength(e,n)?e:t;var o=z.findAngle(t,e),a=z.findAngle(i,n),l=z.findLength(i,n),h=a+2*(o-a);return{x:i.x+l*Math.cos(h*Math.PI/180),y:i.y+l*Math.sin(h*Math.PI/180)}}function Kp(n,t,e){if(n&&n.children&&n.children.length>0)for(var r=void 0,s=0;s0&&"annotations"!==r&&"ports"!==r)if(n[""+l].length>0)for(var h=0;h<=n[""+l].length;h++)Ro(n[""+l],t?t[""+l]:void 0,e[""+l],"annotations"===l||"ports"===l?n:void 0,l);else Ro(n[""+l],t?t[""+l]:void 0,e[""+l],"annotations"===l||"ports"===l?n:void 0,l);else if(s instanceof Object&&t&&"annotations"!==r&&"ports"!==r)Ro(n[""+l],t[""+l],e[""+l]);else if("annotations"!==r&&"ports"!==r&&t&&!t[""+l]||!t&&n&&(n[""+l]||void 0!==n[""+l]))n[""+l]=e[""+l];else{var c=void 0;("annotations"===r||"ports"===r)&&("annotations"===r?(n[""+l]&&Ro(n[""+l],t[""+l],e[""+l]),n[""+l]||(fs(i)===de?(c=new Nr(i,"annotations",e[""+l]),i.annotations.push(c)):(c=new Zn(i,"annotations",e[""+l]),i.annotations.push(c)))):n[""+l]?Ro(n[""+l],t[""+l],e[""+l]):(c=new Es(i,"ports",e[""+l]),i.ports.push(c)))}}}function bse(n,t){for(var e="Bezier"===n.type?function yse(n){var t=[];if("Bezier"===n.type)for(var e=0,i=0;i0||n.ports.length>0){var p=n.wrapper.children;for(i=3;i0)return{enabled:!1,intersectPt:e};var l=o/s,h=a/s;return l>=0&&l<=1&&h>=0&&h<=1?(e.x=i.x1+l*(i.x2-i.x1),e.y=i.y1+l*(i.y2-i.y1),{enabled:!0,intersectPt:e}):{enabled:!1,intersectPt:e}}function rb(n,t,e,i){var a=im(vF(n.x,n.y,t.x,t.y),vF(e.x,e.y,i.x,i.y));return a.enabled?a.intersectPt:{x:0,y:0}}function vF(n,t,e,i){return{x1:Number(n)||0,y1:Number(t)||0,x2:Number(e)||0,y2:Number(i)||0}}function mF(n,t,e){var i=[],s={x:t.topRight.x+(e=e||0),y:t.topRight.y},o={x:t.bottomRight.x,y:t.bottomRight.y-e},a={x:t.bottomLeft.x,y:t.bottomLeft.y+e};return i.push({x:t.topLeft.x-e,y:t.topLeft.y}),i.push(s),i.push(o),i.push(a),i}function zc(n,t,e,i,r,s){var o={},a=e.scroller.transform.scale,h=e.scroller.verticalOffset;return o.x=(i?n.x:t.x)*a+e.scroller.horizontalOffset-r,o.y=(i?n.y:t.y)*a+h-s,o}function yF(n,t){var e=new Ke;return e.data=n.pathData,e.height=n.height>10?n.height-(n.padding.bottom+n.padding.top):n.height,e.width=n.width>10?n.width-(n.padding.left+n.padding.right):n.width,e.visible=n.visibility,e.id=t.id+"_shape",e.inversedAlignment=!1,e.horizontalAlignment="Center",e.verticalAlignment="Center",e.style={fill:n.iconStrokeColor,strokeColor:n.iconStrokeColor,strokeWidth:n.iconStrokeWidth},e.setOffsetWithRespectToBounds(.5,.5,"Fraction"),e.relativeMode="Object",e.description=t.description||"",e}function Zx(n,t,e){var i=Jx(n,t),r=z.findAngle(n[i.index],n[i.index+1]),s=function Tse(n){var t;t=n instanceof LI?0:void 0===n.content?10:0;var e=0;switch(n.alignment){case"Center":e=0;break;case"Before":e=-(0+t);break;case"After":e=0+t}return e}(t),o=z.transform(i.point,r+45,s);return i.point=o,i.angle=r,i}function Jx(n,t){for(var r,s,a,l,e=0,i=t.offset,o=[],h=0;h=c)return s=z.findAngle(n[parseInt(d.toString(),10)],n[d+1]),{point:r=z.transform(n[parseInt(d.toString(),10)],s,c-(a||0)),index:l=d};a=o[parseInt(d.toString(),10)]}return{point:r,index:l}}function SF(n,t,e){t%=360;var a,l,s=225;switch(n.alignment){case"Before":t>=45&&t<=135?(l="right",a=.5===n.offset?"center":"top"):t>=s&&t<=315?(l="left",a=.5===n.offset?"center":"bottom"):t>45&&t=45&&t<=135?(l="left",a=.5===n.offset?"center":"top"):t>=s&&t<=315?(l="right",a=.5===n.offset?"center":"bottom"):t>45&&tMath.abs(t.y-n.y)?n.x0)for(var e=0;e=0;r--)("nodes"===i||"connectors"===i)&&(n[""+i][parseInt(r.toString(),10)].wrapper=null),"dataManager"!==i&&(n[""+i][parseInt(r.toString(),10)]=tT(n[""+i][parseInt(r.toString(),10)],e[""+i][parseInt(r.toString(),10)],void 0!==t[""+i]?t[""+i][parseInt(r.toString(),10)]:[]),("[]"===JSON.stringify(n[""+i][parseInt(r.toString(),10)])||"{}"===JSON.stringify(n[""+i][parseInt(r.toString(),10)])||void 0===n[""+i][parseInt(r.toString(),10)])&&n[""+i].splice(r,1));n=void 0}function Rh(n,t){var e=t.style,i=t;t.canApplyStyle=!0;for(var r=0,s=Object.keys(n);r=0&&n.splice(e,1)}function ef(n,t,e){var i;n.intermediatePoints=t,n.updateSegmentElement(n,t,n.wrapper.children[0],e);var r=n.sourceDecorator;if("Bezier"===n.type){var s=n.segments[0],o=n.segments[n.segments.length-1];i=[z.isEmptyPoint(o.point2)?o.bezierPoint2:o.point2,z.isEmptyPoint(s.point1)?s.bezierPoint1:s.point1]}else i=n.intermediatePoints;t=n.clipDecorators(n,t,e);var a=n.wrapper.children[0];a.canMeasurePath=!0,n.updateDecoratorElement(a=n.wrapper.children[1],t[0],i[1],r),n.updateDecoratorElement(a=n.wrapper.children[2],t[t.length-1],i[i.length-2],n.targetDecorator),n.updateShapeElement(n)}function iT(n,t,e){var l,i=n.wrapper,s=t.offset,o=t.size/e.scale,a=t.margin,h=i.offsetX-i.actualSize.width*i.pivot.x,c=i.offsetY-i.actualSize.height*i.pivot.y;if(l={x:0,y:0},n.nodes.length>0){switch(t.side){case"Top":l.x+=h+s*i.actualSize.width,l.y+=c-o;break;case"Bottom":l.x+=h+s*i.actualSize.width,l.y+=c+i.actualSize.height+o;break;case"Left":l.x+=h-o,l.y+=c+s*i.actualSize.height;break;case"Right":l.x+=h+i.actualSize.width+o,l.y+=c+s*i.actualSize.height}l.x+=(a.left-a.right)/e.scale+o/2*("Center"===t.horizontalAlignment?0:"Right"===t.horizontalAlignment?-1:1),l.y+=(a.top-a.bottom)/e.scale+o/2*("Center"===t.verticalAlignment?0:"Top"===t.verticalAlignment?-1:1)}else if(n.connectors.length>0){var d=n.connectors[0],u={offset:s},p=Jx(d.intermediatePoints,u),f=p.index;l=p.point;var y,v=Zx(d.intermediatePoints,u).angle;qi(y=Hi(),-v,d.intermediatePoints[parseInt(f.toString(),10)].x,d.intermediatePoints[parseInt(f.toString(),10)].y),(l=Je(y,l)).x+=a.left-a.right+o/2*("Center"===t.horizontalAlignment?0:"Right"===t.horizontalAlignment?-1:1),l.y+=a.top-a.bottom+o/2*("Center"===t.verticalAlignment?0:"Top"===t.verticalAlignment?-1:1),qi(y=Hi(),v,d.intermediatePoints[parseInt(f.toString(),10)].x,d.intermediatePoints[parseInt(f.toString(),10)].y),l=Je(y,l)}return 0===i.rotateAngle&&0===i.parentTransform||(qi(y=Hi(),i.rotateAngle+i.parentTransform,i.offsetX,i.offsetY),l=Je(y,l)),l}function fa(n,t,e,i){if(i.annotation){if(kl(i.annotation))return!0}else if(mr[""+t]&n&&bt[""+t]&e)return!0;return!1}function qr(n,t){return!!(mr[""+t]&n)}function Hc(n,t){return!!(Cx[""+t]&n)}function ga(n,t){return n.visibility&t}function nb(n,t){var e;if("Text"===n.shape.type)e=n.shape;else{var i=t.split("_");t=i[i.length-1];for(var r=0;rn[""+t]?e.splice(0,0,n):e.push(n);else if(e.length>1){for(var i=0,r=e.length-1,s=Math.floor((i+r)/2);s!==i;)if(e[parseInt(s.toString(),10)][""+t]n[""+t]))break;r=s,s=Math.floor((i+r)/2)}e[parseInt(r.toString(),10)][""+t]n[""+t]?e.splice(i,0,n):e[parseInt(i.toString(),10)][""+t]n[""+t]&&e.splice(r,0,n)}}function Qse(n){var t=document.getElementById(n.diagramId),e="ej2_instances",i=t[""+e][0].nodes;void 0===i&&(i=function Gse(n){for(var t=[],e=0;e30?10:o/2;for(var h=0,c=0;c=l){var u=l-h;r=Gt(n[c],n[c+1]),s=z.transform(n[c],r,u);break}h+=d}return s},ab=function(n,t){if(n instanceof te||n instanceof de)for(var e=0;e=0||navigator.platform.indexOf("iPad")>=0||navigator.platform.indexOf("iPhone")>=0||navigator.platform.indexOf("MacIntel")>=0)&&("safari"===X.info.name||"webkit"===X.info.name)}function AF(n,t,e,i){return void 0!==t.previewSize[""+i]?t.previewSize[""+i]:void 0!==n.symbolPreview[""+i]?n.symbolPreview[""+i]:t[""+i]||e.actualSize[""+i]}function am(n,t,e){return n&&n.parentId&&(e=(n=t.nameTable[n.parentId]).parentId?am(n,t,e):n.id),e}function lm(n,t){return n.selectedItems.connectors.length>1&&0===n.selectedItems.nodes.length&&0!==t.rotateAngle}function Zse(n){if(n.arrowType&&""!==n.arrowType.trim())switch(n.arrowType){case"single-line-arrow":default:return{targetDecorator:"Arrow",strokeWidth:1};case"double-line-arrow":return{targetDecorator:"Arrow",strokeWidth:2};case"dotted-arrow":return{targetDecorator:"Arrow",strokeDashArray:"2,2"};case"single-line":return{targetDecorator:"None",strokeWidth:1};case"double-line":return{targetDecorator:"None",strokeWidth:2};case"dotted":return{targetDecorator:"None",strokeDashArray:"2,2"};case"wiggly-arrow":return{targetDecorator:"None",strokeWidth:1,opacity:0}}return{targetDecorator:"Arrow",strokeWidth:1}}var Jse=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),io=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},LF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Jse(t,n),io([I("None")],t.prototype,"shape",void 0),io([I("white")],t.prototype,"fill",void 0),io([I("Auto")],t.prototype,"horizontalAlignment",void 0),io([I("Auto")],t.prototype,"verticalAlignment",void 0),io([I(10)],t.prototype,"width",void 0),io([I(10)],t.prototype,"height",void 0),io([re({x:.5,y:1},z)],t.prototype,"offset",void 0),io([I("#1a1a1a")],t.prototype,"borderColor",void 0),io([I(1)],t.prototype,"borderWidth",void 0),io([re({},$n)],t.prototype,"margin",void 0),io([I("")],t.prototype,"pathData",void 0),io([I("")],t.prototype,"content",void 0),io([I(0)],t.prototype,"cornerRadius",void 0),io([re({left:2,right:2,top:2,bottom:2},$n)],t.prototype,"padding",void 0),io([I("#1a1a1a")],t.prototype,"iconColor",void 0),t}(Ee),Kse=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),oT=function(n){function t(){var e=null!==n&&n.apply(this,arguments)||this;return e.orientation="Vertical",e.measureChildren=void 0,e.considerPadding=!0,e}return Kse(t,n),t.prototype.measure=function(e){return this.desiredSize=this.measureStackPanel(e,"Horizontal"===this.orientation?this.updateHorizontalStack:this.updateVerticalStack),this.desiredSize},t.prototype.arrange=function(e){return this.actualSize=this.arrangeStackPanel(e,"Horizontal"===this.orientation?this.arrangeHorizontalStack:this.arrangeVerticalStack),this.updateBounds(),this.actualSize},t.prototype.measureStackPanel=function(e,i){var r=void 0;if(void 0!==this.children&&this.children.length>0)for(var s=0,o=this.children;s0){var r=void 0,s=void 0;r=this.offsetX-e.width*this.pivot.x+this.padding.left,s=this.offsetY-e.height*this.pivot.y+this.padding.top;for(var o=0,a=this.children;o0)for(var i=0,r=this.children;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},aoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return ooe(t,n),Hh([I("Horizontal")],t.prototype,"orientation",void 0),Hh([I("Center")],t.prototype,"type",void 0),Hh([I(void 0)],t.prototype,"offset",void 0),Hh([I(!1)],t.prototype,"enableRouting",void 0),Hh([I([])],t.prototype,"children",void 0),Hh([I("")],t.prototype,"assistants",void 0),Hh([I("")],t.prototype,"level",void 0),Hh([I("")],t.prototype,"hasSubTree",void 0),Hh([I("")],t.prototype,"rows",void 0),t}(Ee),Li=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),q=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},loe=function(n){if(n)switch(n.type){case"Basic":default:return lb;case"Flow":return PF;case"Path":return NF;case"Image":return kF;case"Text":return Rd;case"Bpmn":return uT;case"Native":return hm;case"HTML":return OF;case"UmlActivity":return zF;case"UmlClassifier":return RF;case"SwimLane":return Fd}return lb},va=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),q([I("Basic")],t.prototype,"type",void 0),t}(Ee),NF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"Path"},q([I("Path")],t.prototype,"type",void 0),q([I("")],t.prototype,"data",void 0),t}(va),hm=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"Native"},q([I("Native")],t.prototype,"type",void 0),q([I("")],t.prototype,"content",void 0),q([I("Stretch")],t.prototype,"scale",void 0),t}(va),OF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"Html"},q([I("HTML")],t.prototype,"type",void 0),q([I("")],t.prototype,"content",void 0),t}(va),kF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"Image"},q([I("Image")],t.prototype,"type",void 0),q([I("")],t.prototype,"source",void 0),q([I("None")],t.prototype,"scale",void 0),q([I("None")],t.prototype,"align",void 0),t}(va),Rd=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"Text"},q([I("Text")],t.prototype,"type",void 0),q([I("")],t.prototype,"content",void 0),q([re({},$n)],t.prototype,"margin",void 0),t}(va),lb=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"BasicShape"},q([I("Basic")],t.prototype,"type",void 0),q([I("Rectangle")],t.prototype,"shape",void 0),q([I(0)],t.prototype,"cornerRadius",void 0),q([Bt([],z)],t.prototype,"points",void 0),t}(va),PF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"FlowShape"},q([I("Flow")],t.prototype,"type",void 0),q([I("Terminator")],t.prototype,"shape",void 0),t}(va),lT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"BpmnGateway"},q([I("None")],t.prototype,"type",void 0),t}(Ee),hT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"BpmnDataObject"},q([I("None")],t.prototype,"type",void 0),q([I(!1)],t.prototype,"collection",void 0),t}(Ee),hoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),q([I("None")],t.prototype,"type",void 0),q([I("None")],t.prototype,"loop",void 0),q([I(!1)],t.prototype,"call",void 0),q([I(!1)],t.prototype,"compensation",void 0),t}(Ee),cT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"BpmnEvent"},q([I("Start")],t.prototype,"event",void 0),q([I("None")],t.prototype,"trigger",void 0),t}(Ee),Hd=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"BpmnSubEvent"},q([I("None")],t.prototype,"trigger",void 0),q([I("Start")],t.prototype,"event",void 0),q([I("")],t.prototype,"id",void 0),q([re({},z)],t.prototype,"offset",void 0),q([Bt([],Zn)],t.prototype,"annotations",void 0),q([Bt([],Es)],t.prototype,"ports",void 0),q([I()],t.prototype,"width",void 0),q([I()],t.prototype,"height",void 0),q([re({},$n)],t.prototype,"margin",void 0),q([I("Center")],t.prototype,"horizontalAlignment",void 0),q([I("Center")],t.prototype,"verticalAlignment",void 0),q([I(!0)],t.prototype,"visible",void 0),t}(Ee),coe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),q([re({id:"success",event:"End",offset:{x:1,y:.5}},Hd)],t.prototype,"success",void 0),q([re({id:"failure",event:"Intermediate",trigger:"Error",offset:{x:.25,y:1}},Hd)],t.prototype,"failure",void 0),q([re({id:"cancel",event:"Intermediate",trigger:"Cancel",offset:{x:.75,y:1}},Hd)],t.prototype,"cancel",void 0),t}(Ee),doe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),q([I("None")],t.prototype,"type",void 0),q([I(!1)],t.prototype,"adhoc",void 0),q([I("Default")],t.prototype,"boundary",void 0),q([I(!1)],t.prototype,"compensation",void 0),q([I("None")],t.prototype,"loop",void 0),q([I(!0)],t.prototype,"collapsed",void 0),q([Bt([],Hd)],t.prototype,"events",void 0),q([re({},coe)],t.prototype,"transaction",void 0),q([I(void 0)],t.prototype,"processes",void 0),t}(Ee),dT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"BpmnActivity"},q([I("Task")],t.prototype,"activity",void 0),q([re({},hoe)],t.prototype,"task",void 0),q([re({},doe)],t.prototype,"subProcess",void 0),t}(Ee),cm=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return Li(t,n),t.prototype.getClassName=function(){return"BpmnAnnotation"},q([I("")],t.prototype,"text",void 0),q([I("")],t.prototype,"id",void 0),q([I(0)],t.prototype,"angle",void 0),q([I()],t.prototype,"height",void 0),q([I()],t.prototype,"width",void 0),q([I(0)],t.prototype,"length",void 0),t}(Ee),uoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),q([I("")],t.prototype,"textAnnotationTarget",void 0),q([I("Auto")],t.prototype,"textAnnotationDirection",void 0),t}(Ee),uT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"BpmnShape"},q([I("Bpmn")],t.prototype,"type",void 0),q([I("Event")],t.prototype,"shape",void 0),q([re({},cT)],t.prototype,"event",void 0),q([re({},lT)],t.prototype,"gateway",void 0),q([re({},hT)],t.prototype,"dataObject",void 0),q([re({},dT)],t.prototype,"activity",void 0),q([re({},cm)],t.prototype,"annotation",void 0),q([Bt([],cm)],t.prototype,"annotations",void 0),q([re({},uoe)],t.prototype,"textAnnotation",void 0),t}(va),zF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"UmlActivityShape"},q([I("UmlActivity")],t.prototype,"type",void 0),q([I("Action")],t.prototype,"shape",void 0),t}(va),pT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"MethodArguments"},q([I("")],t.prototype,"name",void 0),q([I("")],t.prototype,"type",void 0),q([re({},Xp)],t.prototype,"style",void 0),t}(Ee),of=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"UmlClassAttribute"},q([I("Public")],t.prototype,"scope",void 0),q([I(!1)],t.prototype,"isSeparator",void 0),q([re({fill:"#F9F9F9",strokeColor:"#CCCCCC"},Ll)],t.prototype,"separatorStyle",void 0),t}(pT),dm=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"UmlClassMethod"},q([Bt([],pT)],t.prototype,"parameters",void 0),t}(of),hb=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"UmlClass"},q([I("")],t.prototype,"name",void 0),q([Bt([],of)],t.prototype,"attributes",void 0),q([Bt([],dm)],t.prototype,"methods",void 0),q([re({},Xp)],t.prototype,"style",void 0),t}(Ee),fT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"UmlInterface"},q([I(!1)],t.prototype,"isSeparator",void 0),q([re({fill:"#F9F9F9",strokeColor:"#CCCCCC"},Ll)],t.prototype,"separatorStyle",void 0),t}(hb),cb=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"UmlEnumerationMember"},q([I("")],t.prototype,"name",void 0),q([I("")],t.prototype,"value",void 0),q([I(!1)],t.prototype,"isSeparator",void 0),q([re({fill:"#F9F9F9",strokeColor:"#CCCCCC"},Ll)],t.prototype,"separatorStyle",void 0),q([re({},Xp)],t.prototype,"style",void 0),t}(Ee),gT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"UmlEnumeration"},q([I("")],t.prototype,"name",void 0),q([Bt([],cb)],t.prototype,"members",void 0),q([re({},Xp)],t.prototype,"style",void 0),t}(Ee),RF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"UmlClassifierShape"},q([I("UmlClassifier")],t.prototype,"type",void 0),q([re({},hb)],t.prototype,"classShape",void 0),q([re({},fT)],t.prototype,"interfaceShape",void 0),q([re({},gT)],t.prototype,"enumerationShape",void 0),q([I("Class")],t.prototype,"classifier",void 0),t}(va),te=function(n){function t(e,i,r,s){var a,o=n.call(this,e,i,r,s)||this;return o.isCanvasUpdate=!1,o.status="None",o.parentId="",o.processId="",o.umlIndex=-1,o.outEdges=[],o.inEdges=[],o.isHeader=!1,o.isLane=!1,o.isPhase=!1,o.children&&o.children.length>0&&((!(a=r).style||!a.style.fill)&&(o.style.fill="transparent"),(!a.style||!a.style.strokeColor)&&(o.style.strokeColor="transparent")),o.shape&&"UmlActivity"===o.shape.type&&ib(r,o),o.shape&&"SwimLane"===o.shape.type&&pF(r,o),o.ports&&o.ports.length&&function vse(n){for(var t=0;t>";t=n;break;case"FinalNode":t=IF(e)}return t}(new Ke,i,this);break;case"Bpmn":if(e.bpmnModule){i=e.bpmnModule.initBPMNContent(i,this,e),this.wrapper.elementActions=this.wrapper.elementActions|Xr.ElementIsGroup;var v=this.shape.activity.subProcess;if(v.processes&&v.processes.length)for(var S=0,b=this.shape.activity.subProcess.processes;S>",margin:{left:10,right:10},id:"class",style:{fontSize:i.style.fontSize,color:i.style.color,fill:i.style.fill,textWrapping:r},offset:{x:.5,y:.3},constraints:Lr.ReadOnly}],constraints:(ie.Default|ie.HideThumbs)&~(ie.Rotate|ie.Drag|ie.Resize),verticalAlignment:"Stretch",horizontalAlignment:"Stretch",style:{fill:t.style.fill,strokeColor:"black"===t.style.strokeColor?"#ffffff00":t.style.strokeColor}},!0);return e.initObject(s),e.nodes.push(s),e.UpdateBlazorDiagramModel(s,"Node"),t.children.push(s.id),function toe(n,t,e,i){if("Enumeration"===n.shape.classifier){var r=e.members;if(r&&r.length){nf(n,t);for(var s="",o=0;o0)for(var o=0;o0&&s.phaseSize&&(i+=s.phaseSize,qv(n,s.phaseSize)),s.lanes.length>0)for(o=0;o0){var a=0;for(o=0;o0&&"Horizontal"===r.orientation)for(l=0;l0&&(i+=r.phaseSize,o=$v(r.phaseSize),n.push(o)),a=0;a0&&o.phaseSize){for(var l=0;l0)for(l=0;l0?e.nameTable[this.nodes[0].id].wrapper:e.nameTable[this.connectors[0].id].wrapper,this.annotation.id);i.children.push(s)}else if(this.nodes||this.connectors){for(var o=0;o-1}function VF(n,t,e){n=[];for(var i=0,r=e.length;i0?c.getElementsByTagName("svg")[0].outerHTML:c.getElementsByTagName("g").length>0?c.getElementsByTagName("g")[0].outerHTML:"",s.shape.content=h,n.content=h,c.parentElement.removeChild(c)}l="nodeTemplate"}else a=s,l="annotationTemplate";var f=document.getElementById(n.diagramId).ej2_instances[0];if("string"!=typeof n.content&&"function"!=typeof n.content||n.isTemplate)if(n.isTemplate){if(v=void 0,v=f.isReact?n.getNodeTemplate()($(e),f,l+"_"+("nodeTemplate"===l?e.id:n.nodeId+e.id),void 0,void 0,!1,i):f.isVue||f.isVue3?n.getNodeTemplate()?n.getNodeTemplate()($(e),f,l+"_"+("nodeTemplate"===l?e.id:n.nodeId+e.id),void 0,void 0,!1,i):(v=ii("nodeTemplate"===l?f.nodeTemplate:f.annotationTemplate))($(e),f,l+"_"+("nodeTemplate"===l?e.id:n.nodeId+e.id),void 0,void 0,!1,i):n.getNodeTemplate()($(e),f,l+"_"+("nodeTemplate"===l?e.id:n.nodeId+e.id),void 0,void 0,!1))for(var M=0;M=1&&0===n.x&&("Clip"===i.textOverflow||"Ellipsis"===i.textOverflow)&&("Wrap"===i.textWrapping||"WrapWithOverflow"===i.textWrapping)&&(n.x=t[e-1]?t[e-1].x:-n.width/2),n.x}function QF(n,t,e,i){return e&&!t.template||t.template&&"function"==typeof t.template&&i.isReact?(n.isTemplate=!0,n.template=n.content=Bh(n,!0,t)):n.content=t.template,n}function Qe(){for(var e,t="",i=0;i<5;i++){if(typeof window<"u"&&"crypto"in window&&"getRandomValues"in crypto){var r=new Uint16Array(1);e=(window.msCrypto||window.crypto).getRandomValues(r)[0]%60}else e=Math.floor(61*Math.random());0===i&&e<10?i--:t+="0123456789ABCDEFGHIJKLMNOPQRSTUVWXTZabcdefghiklmnopqrstuvwxyz".substring(e,e+1)}return t}function GF(n){if(n)try{return"function"!=typeof n&&document.querySelectorAll(n).length?ii(document.querySelector(n).innerHTML.trim()):ii(n)}catch{return ii(n)}}function En(n){new Ne;var e=n.offsetY-n.actualSize.height*n.pivot.y,i=n.offsetY+n.actualSize.height*(1-n.pivot.y),r=n.offsetX-n.actualSize.width*n.pivot.x,s=n.offsetX+n.actualSize.width*(1-n.pivot.x);return Ne.toBounds([{x:r,y:e},{x:s,y:e},{x:r,y:i},{x:s,y:i}])}function yr(n){var t=new Ne,e=En(n),i=e.middleLeft,r=e.topCenter,s=e.bottomCenter,o=e.middleRight,a=e.topLeft,l=e.topRight,h=e.bottomLeft,c=e.bottomRight;if(n.corners={topLeft:a,topCenter:r,topRight:l,middleLeft:i,middleRight:o,bottomLeft:h,bottomCenter:s,bottomRight:c},0!==n.rotateAngle||0!==n.parentTransform){var d=Hi();qi(d,n.rotateAngle+n.parentTransform,n.offsetX,n.offsetY),n.corners.topLeft=a=Je(d,a),n.corners.topCenter=r=Je(d,r),n.corners.topRight=l=Je(d,l),n.corners.middleLeft=i=Je(d,i),n.corners.middleRight=o=Je(d,o),n.corners.bottomLeft=h=Je(d,h),n.corners.bottomCenter=s=Je(d,s),n.corners.bottomRight=c=Je(d,c)}return t=Ne.toBounds([a,l,h,c]),n.corners.left=t.left,n.corners.right=t.right,n.corners.top=t.top,n.corners.bottom=t.bottom,n.corners.center=t.center,n.corners.width=t.width,n.corners.height=t.height,t}function $(n,t,e,i){var r={},s="properties";if(n){e=n.propName;var l=[],h=[];if((l=l.concat(Object.keys(n[""+s]||n))).push("version"),e){var c=Zi(t);h=c?c(e):[],l=l.concat(h)}for(var d=function Ooe(n){switch(n){case"nodes":case"children":return["inEdges","outEdges","parentId","processId","nodeId","umlIndex","isPhase","isLane"];case"connectors":return["parentId"];case"annotation":case"annotations":return["nodeId"];case"shape":return["hasHeader"];case"layers":return["objectZIndex"]}return[]}(e),u=0,p=l=l.concat(d);u0&&(e=r),r=Math.floor(Poe(e,i)),s=Bc(o+=n.substr(e,r),t)}while(s<=t.width);for(o=o.substr(0,e),a=e;a=t.width){n=n.substr(0,o.length-1);break}return"Ellipsis"===t.textOverflow?(n=n.substr(0,n.length-3),n+="..."):n=n.substr(0,n.length),n}function MT(n,t){if("NoWrap"===t&&"PreserveAll"===n)return"pre";var e="";switch(n){case"CollapseAll":e="nowrap";break;case"CollapseSpace":e="pre-line";break;case"PreserveAll":e="pre-wrap"}return e}function wT(n,t){var e=Hi();qi(e,t,0,0);var i=Je(e,{x:0,y:0}),r=Je(e,{x:n.width,y:0}),s=Je(e,{x:0,y:n.height}),o=Je(e,{x:n.width,y:n.height}),a=Math.min(i.x,r.x,s.x,o.x),l=Math.min(i.y,r.y,s.y,o.y),h=Math.max(i.x,r.x,s.x,o.x),c=Math.max(i.y,r.y,s.y,o.y);return new me(h-a,c-l)}function xs(n,t,e,i){if(0!==n){var r=Hi();return qi(r,n,t,e),Je(r,i)}return i}function Zi(n){return void 0!==n&&"string"==typeof n&&(n=Y(n,window)),n}var bo=function(){function n(){}return n.getContext=function(t){return t.getContext("2d")},n.setCanvasSize=function(t,e,i){t&&(t.setAttribute("width",e.toString()),t.setAttribute("height",i.toString()))},n.prototype.renderGradient=function(t,e,i,r){var s,o,a;if("None"!==t.gradient.type){for(var l=0;l0?(w=0===S.r1?e.arc[parseInt(r.toString(),10)].r1:S.r1,C=0===S.r2?e.arc[parseInt(r.toString(),10)].r2:S.r2,r++):(w=S.r1,C=S.r2);var D=S.angle*(Math.PI/180),A=S.largeArc,x=S.sweep,R={x:u,y:p},L={x:Math.cos(D)*(M.x-R.x)/2+Math.sin(D)*(M.y-R.y)/2,y:-Math.sin(D)*(M.x-R.x)/2+Math.cos(D)*(M.y-R.y)/2},O=Math.pow(L.x,2)/Math.pow(w,2)+Math.pow(L.y,2)/Math.pow(C,2);O>1&&(w*=Math.sqrt(O),C*=Math.sqrt(O));var N=Math.pow(C,2)*Math.pow(L.x,2),T=(A===x?-1:1)*Math.sqrt((Math.pow(w,2)*Math.pow(C,2)-Math.pow(w,2)*Math.pow(L.y,2)-N)/(Math.pow(w,2)*Math.pow(L.y,2)+Math.pow(C,2)*Math.pow(L.x,2)));isNaN(T)&&(T=0);var P={x:T*w*L.y/C,y:T*-C*L.x/w},_={x:(M.x+R.x)/2+Math.cos(D)*P.x-Math.sin(D)*P.y,y:(M.y+R.y)/2+Math.sin(D)*P.x+Math.cos(D)*P.y},B=this.a([1,0],[(L.x-P.x)/w,(L.y-P.y)/C]),j=[(L.x-P.x)/w,(L.y-P.y)/C],Q=[(-L.x-P.x)/w,(-L.y-P.y)/C],oe=this.a(j,Q);this.r(j,Q)<=-1&&(oe=Math.PI),this.r(j,Q)>=1&&(oe=0);var pe=B+oe/2*(x?1:-1);if(Math.cos(pe),Math.sin(pe),S.centp=_,S.xAxisRotation=D,S.rx=w,S.ry=C,S.a1=B,S.ad=oe,S.sweep=x,null!=s){var De=w>C?w:C,xe=w>C?1:w/C,Ie=w>C?C/w:1;s.save(),s.translate(_.x,_.y),s.rotate(D),s.scale(xe,Ie),s.arc(0,0,De,B,B+oe,!x),s.scale(1/xe,1/Ie),s.rotate(-D),s.translate(-_.x,-_.y),s.restore()}break;case"Z":case"z":s.closePath(),u=o,p=a}o=u,a=p}}},n.prototype.drawText=function(t,e,i,r,s,o,a){if(e.content&&!0===e.visible){var l=n.getContext(t);l.save(),this.setStyle(t,e),o&&(e.fontSize*=o),this.rotateContext(t,e.angle,e.x+e.width*e.pivotX,e.y+e.height*e.pivotY),this.setFontStyle(t,e);var u,d=0;u=e.childNodes;var p=e.wrapBounds;if(l.fillStyle=e.color,p){var f=this.labelAlign(e,p,u);for(d=0;de.width&&"Wrap"!==e.textOverflow&&"NoWrap"===e.textWrapping&&(g.text=qF(g.text,e)),"Clip"!==e.textOverflow&&"Ellipsis"!==e.textOverflow||"Wrap"!==e.textWrapping?l.fillText(g.text,v,y):ya.actualSize.height+a.bounds.y&&(g.text=g.text.slice(0,g.text.length-3),g.text=g.text.concat("...")),l.fillText(g.text,v,y)),"Underline"===e.textDecoration||"Overline"===e.textDecoration||"LineThrough"===e.textDecoration){var M=v,w=void 0,D=v+l.measureText(g.text).width,A=void 0;switch(e.textDecoration){case"Underline":w=y+2,A=y+2;break;case"Overline":w=f.y+g.dy*d,A=f.y+g.dy*d;break;case"LineThrough":w=(y+f.y+g.dy*d)/2+2,A=(y+f.y+g.dy*d)/2+2}l.beginPath(),l.moveTo(M,w),l.lineTo(D,A),l.strokeStyle=e.color,l.lineWidth=.08*e.fontSize,l.globalAlpha=e.opacity,l.stroke()}}}l.restore()}},n.prototype.loadImage=function(t,e,i,r,s){this.rotateContext(i,e.angle,r,s);var o=new Image;o.src=e.source,this.image(t,o,e.x,e.y,e.width,e.height,e)},n.prototype.drawImage=function(t,e,i,r){var s=this;if(e.visible){var o=n.getContext(t);o.save();var a=e.x+e.width*e.pivotX,l=e.y+e.height*e.pivotY,h=new Image;h.src=e.source,o.canvas.id.split("_"),r?h.onload=function(){s.loadImage(o,e,t,a,l)}:this.loadImage(o,e,t,a,l),o.restore()}},n.prototype.image=function(t,e,i,r,s,o,a){t.beginPath();var l=e.width,h=e.height,c=s,d=o,u=0,p=0;if(a&&"None"!==a.alignment){var f=a.alignment.toLowerCase().substr(1,3),g=a.alignment.toLowerCase().substr(5,3);if("Slice"===a.scale){var v=function(){u=c,p=h*c/l},y=function(){u=l*d/h,p=d};c>d?(v(),d>p&&y()):c===d?l>h?y():v():(y(),c>u&&v());var S=this.getSliceOffset(f,u,c,l),b=this.getSliceOffset(g,p,d,h),M=l-S,w=h-b,C=u-S*(u/l),D=p-b*(p/h),A=Tt("canvas",{width:s.toString(),height:o.toString()});A.getContext("2d").drawImage(e,S,b,M,w,0,0,C,D),t.drawImage(A,i,r,s,o)}else if("Meet"===a.scale){var R=h/l,L=d/c;p=L>R?c*R:d,i+=this.getMeetOffset(f,u=L>R?c:d/R,c),r+=this.getMeetOffset(g,p,d),t.drawImage(e,0,0,l,h,i,r,u,p)}else t.drawImage(e,i,r,s,o)}else if("None"!==a.flip){var O=1,N=1;("Horizontal"===a.flip||"Both"===a.flip)&&(i=-i,s=-s,O=-1),("Vertical"===a.flip||"Both"===a.flip)&&(r=-r,o=-o,N=-1),t.scale(O,N),t.drawImage(e,i,r,s,o)}else t.drawImage(e,i,r,s,o);t.closePath()},n.prototype.getSliceOffset=function(t,e,i,r){switch(t){case"min":default:return 0;case"mid":return(e-i)/2*r/e;case"max":return(e-i)*r/e}},n.prototype.getMeetOffset=function(t,e,i){var r=Math.max(e,i),s=Math.min(e,i);switch(t){case"min":default:return 0;case"mid":return(r-s)/2;case"max":return r-s}},n.prototype.m=function(t){return Math.sqrt(Math.pow(t[0],2)+Math.pow(t[1],2))},n.prototype.r=function(t,e){return(t[0]*e[0]+t[1]*e[1])/(this.m(t)*this.m(e))},n.prototype.a=function(t,e){return(t[0]*e[1]t.width&&("Ellipsis"===t.textOverflow||"Clip"===t.textOverflow)&&"NoWrap"===t.textWrapping?0:.5*t.width:"right"===t.textAlign&&(c=1*t.width),s.x=t.x+c+(e?e.x:0),s.y=a+d-r.height/2,s},n}(),gb=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Vi=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Roe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return gb(t,n),Vi([I("")],t.prototype,"source",void 0),Vi([I("transparent")],t.prototype,"color",void 0),Vi([I("None")],t.prototype,"scale",void 0),Vi([I("None")],t.prototype,"align",void 0),t}(Ee),Hoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return gb(t,n),Vi([I("Page")],t.prototype,"mode",void 0),Vi([I("PageSettings")],t.prototype,"region",void 0),Vi([re({top:25,bottom:25,left:25,right:25},$n)],t.prototype,"margin",void 0),Vi([I(!1)],t.prototype,"canZoomIn",void 0),Vi([I(void 0)],t.prototype,"customBounds",void 0),Vi([I(!1)],t.prototype,"canFit",void 0),t}(Ee),Boe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return gb(t,n),Vi([I(null)],t.prototype,"width",void 0),Vi([I(null)],t.prototype,"height",void 0),Vi([re({},$n)],t.prototype,"margin",void 0),Vi([I("Landscape")],t.prototype,"orientation",void 0),Vi([I("Infinity")],t.prototype,"boundaryConstraints",void 0),Vi([re({},Roe)],t.prototype,"background",void 0),Vi([I(!1)],t.prototype,"multiplePage",void 0),Vi([I(!1)],t.prototype,"showPageBreaks",void 0),Vi([re({},Hoe)],t.prototype,"fitOptions",void 0),t}(Ee),Foe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return gb(t,n),Vi([I(0)],t.prototype,"horizontalOffset",void 0),Vi([I(0)],t.prototype,"verticalOffset",void 0),Vi([I(1)],t.prototype,"currentZoom",void 0),Vi([I(0)],t.prototype,"viewPortWidth",void 0),Vi([I(0)],t.prototype,"viewPortHeight",void 0),Vi([I(.2)],t.prototype,"minZoom",void 0),Vi([I(30)],t.prototype,"maxZoom",void 0),Vi([I("Diagram")],t.prototype,"scrollLimit",void 0),Vi([I()],t.prototype,"scrollableArea",void 0),Vi([I(!1)],t.prototype,"canAutoScroll",void 0),Vi([I(100)],t.prototype,"autoScrollFrequency",void 0),Vi([re({left:15,right:15,top:15,bottom:15},$n)],t.prototype,"autoScrollBorder",void 0),Vi([re({left:0,right:0,top:0,bottom:0},$n)],t.prototype,"padding",void 0),Vi([I(.2)],t.prototype,"zoomFactor",void 0),t}(Ee),_oe=function(){function n(){this.services={}}return n.prototype.register=function(t,e){this.services[""+t]=e},n.prototype.getService=function(t){return this.services[""+t]},n}(),$F=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),ma=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},ZF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return $F(t,n),ma([I("lightgray")],t.prototype,"lineColor",void 0),ma([I("")],t.prototype,"lineDashArray",void 0),ma([I([1.25,18.75,.25,19.75,.25,19.75,.25,19.75,.25,19.75])],t.prototype,"lineIntervals",void 0),ma([I([1,19,.5,19.5,.5,19.5,.5,19.5,.5,19.5])],t.prototype,"dotIntervals",void 0),ma([I([20])],t.prototype,"snapIntervals",void 0),t}(Ee),Uoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return $F(t,n),ma([re({},ZF)],t.prototype,"horizontalGridlines",void 0),ma([re({},ZF)],t.prototype,"verticalGridlines",void 0),ma([I(Kt.All)],t.prototype,"constraints",void 0),ma([I(5)],t.prototype,"snapAngle",void 0),ma([I("Lines")],t.prototype,"gridType",void 0),ma([I(5)],t.prototype,"snapObjectDistance",void 0),ma([I("#07EDE1")],t.prototype,"snapLineColor",void 0),t}(Ee),JF=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Ja=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},KF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return JF(t,n),Ja([I(5)],t.prototype,"interval",void 0),Ja([I(100)],t.prototype,"segmentWidth",void 0),Ja([I("Horizontal")],t.prototype,"orientation",void 0),Ja([I("RightOrBottom")],t.prototype,"tickAlignment",void 0),Ja([I("red")],t.prototype,"markerColor",void 0),Ja([I(25)],t.prototype,"thickness",void 0),Ja([I(null)],t.prototype,"arrangeTick",void 0),t}(Ee),joe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return JF(t,n),Ja([I(!1)],t.prototype,"showRulers",void 0),Ja([I(!0)],t.prototype,"dynamicGrid",void 0),Ja([re({orientation:"Horizontal"},KF)],t.prototype,"horizontalRuler",void 0),Ja([re({orientation:"Vertical"},KF)],t.prototype,"verticalRuler",void 0),t}(Ee),Voe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),e_=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Woe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Voe(t,n),e_([I("")],t.prototype,"property",void 0),e_([I("")],t.prototype,"field",void 0),t}(Ee),CT=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),ln=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},t_=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return CT(t,n),ln([I("")],t.prototype,"read",void 0),ln([I("")],t.prototype,"create",void 0),ln([I("")],t.prototype,"update",void 0),ln([I("")],t.prototype,"destroy",void 0),ln([I()],t.prototype,"customFields",void 0),t}(Ee),Yoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return CT(t,n),ln([I("")],t.prototype,"id",void 0),ln([I("")],t.prototype,"sourceID",void 0),ln([I("")],t.prototype,"targetID",void 0),ln([I(null)],t.prototype,"sourcePointX",void 0),ln([I(null)],t.prototype,"sourcePointY",void 0),ln([I(null)],t.prototype,"targetPointX",void 0),ln([I(null)],t.prototype,"targetPointY",void 0),ln([I(null)],t.prototype,"dataManager",void 0),ln([re({},t_)],t.prototype,"crudAction",void 0),t}(Ee),Qoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return CT(t,n),ln([I("")],t.prototype,"id",void 0),ln([I(null)],t.prototype,"dataManager",void 0),ln([I(null)],t.prototype,"dataSource",void 0),ln([I("")],t.prototype,"root",void 0),ln([I("")],t.prototype,"parentId",void 0),ln([I()],t.prototype,"doBinding",void 0),ln([Bt([],Woe)],t.prototype,"dataMapSettings",void 0),ln([re({},t_)],t.prototype,"crudAction",void 0),ln([re({},Yoe)],t.prototype,"connectionDataSource",void 0),t}(Ee),i_=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Cr=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Goe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return i_(t,n),Cr([I("LeftInFlow")],t.prototype,"yesBranchDirection",void 0),Cr([I("RightInFlow")],t.prototype,"noBranchDirection",void 0),Cr([I(["Yes","True"])],t.prototype,"yesBranchValues",void 0),Cr([I(["No","False"])],t.prototype,"noBranchValues",void 0),t}(Ee),Xoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return i_(t,n),Cr([I("")],t.prototype,"fixedNode",void 0),Cr([I(30)],t.prototype,"horizontalSpacing",void 0),Cr([I("SamePoint")],t.prototype,"connectionPointOrigin",void 0),Cr([I("Nonlinear")],t.prototype,"arrangement",void 0),Cr([I(30)],t.prototype,"verticalSpacing",void 0),Cr([I(30)],t.prototype,"maxIteration",void 0),Cr([I(40)],t.prototype,"springFactor",void 0),Cr([I(50)],t.prototype,"springLength",void 0),Cr([re({left:50,top:50,right:0,bottom:0},$n)],t.prototype,"margin",void 0),Cr([I("Auto")],t.prototype,"horizontalAlignment",void 0),Cr([I("Auto")],t.prototype,"verticalAlignment",void 0),Cr([I("TopToBottom")],t.prototype,"orientation",void 0),Cr([I("Auto")],t.prototype,"connectionDirection",void 0),Cr([I("Default")],t.prototype,"connectorSegments",void 0),Cr([I("None")],t.prototype,"type",void 0),Cr([I()],t.prototype,"getLayoutInfo",void 0),Cr([I()],t.prototype,"layoutInfo",void 0),Cr([I()],t.prototype,"getBranch",void 0),Cr([I()],t.prototype,"bounds",void 0),Cr([I(!0)],t.prototype,"enableAnimation",void 0),Cr([I(!1)],t.prototype,"enableRouting",void 0),Cr([I("")],t.prototype,"root",void 0),Cr([re({},Goe)],t.prototype,"flowchartLayoutSettings",void 0),t}(Ee),qoe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),r_=function(n){function t(e,i){var r=n.call(this,e,!0)||this;return r.oldValue=null,r.endPoint=i,r}return qoe(t,n),t.prototype.mouseDown=function(e){var i,r=!0;if(e.source&&e.source.connectors&&(i=e.source.connectors[0]),e.info&&e.actualObject&&(r=e.info.ctrlKey&&"Orthogonal"!==e.actualObject.type),i&&r){this.inAction=!0,this.undoElement=$(e.source),n.prototype.mouseDown.call(this,e);for(var s=0;s0)1!==s&&this.removePrevSegment(i,s);else if(a){var l=z.distancePoints(a.points[0],a.points[1]);Math.abs(a.length||0===a.length?a.length:l)<=5&&this.removeNextSegment(i,s)}this.commandHandler.updateEndPoint(i,r),i.selectedSegmentIndex=0}if(this.undoElement){var c=$(e.source);this.commandHandler.addHistoryEntry({type:"SegmentChanged",redoObject:c,undoObject:this.undoElement,category:"Internal"})}if(i.isBezierEditing&&(i.isBezierEditing=!1),this.prevPosition!==this.startPosition){var u={source:i,state:"Completed",oldValue:this.oldValue,newValue:$(this.selectedSegment),cancel:!1,segment:this.selectedSegment};this.commandHandler.triggerEvent(Ce.segmentChange,u)}n.prototype.mouseUp.call(this,e)},t.prototype.removePrevSegment=function(e,i){var r=e.segments[i-2],s=e.segments[i+1];if(s&&!((s.length||0===s.length?s.length:z.distancePoints(s.points[0],s.points[1]))<=5)){var a=e.segments.slice(i-1,i+1),l={element:e,removeSegments:a,type:"Removal",cancel:!1};if(this.commandHandler.triggerEvent(Ce.segmentCollectionChange,l),!l.cancel){var h=e.segments[i+1];e.segments.splice(i-1,2);var c=this.selectedSegment;"Left"===c.direction||"Right"===c.direction?(r.points[r.points.length-1].x=h.points[0].x,h.points[0].y=r.points[r.points.length-1].y):(r.points[r.points.length-1].y=h.points[0].y,h.points[0].x=r.points[r.points.length-1].x),(c.length||0===c.length)&&this.findSegmentDirection(r),this.findSegmentDirection(h)}}},t.prototype.findSegmentDirection=function(e){e.direction&&(e.length||0===e.length)&&(e.length=z.distancePoints(e.points[0],e.points[e.points.length-1]),e.direction=z.direction(e.points[0],e.points[e.points.length-1]))},t.prototype.removeNextSegment=function(e,i){var l,h,r=this.selectedSegment,s=e.segments[i-1],o=e.segments[i+2],a=e.segments[i+1];if(a.length||0===a.length?(l=e.segments.slice(i,2),h={element:e,removeSegments:l,type:"Removal",cancel:!1},this.commandHandler.triggerEvent(Ce.segmentCollectionChange,h={element:e,removeSegments:l,type:"Removal",cancel:!1}),h.cancel||(e.segments.splice(i,2),"Top"===r.direction||"Bottom"===r.direction?(o.points[0].y=r.points[0].y,s.points[s.points.length-1].x=o.points[0].x):(o.points[0].x=r.points[0].x,s.points[s.points.length-1].y=o.points[0].y))):(l=e.segments.slice(i+1,1),this.commandHandler.triggerEvent(Ce.segmentCollectionChange,h={element:e,removeSegments:l,type:"Removal",cancel:!1}),h.cancel||(e.segments.splice(i+1,1),"Top"===r.direction||"Bottom"===r.direction?s.points[s.points.length-1].x=a.points[a.points.length-1].x:s.points[s.points.length-1].y=a.points[a.points.length-1].y,this.findSegmentDirection(s),r.length=r.direction=null)),s&&o&&!h.cancel&&(s.length=z.distancePoints(s.points[0],o.points[0]),s.direction=z.direction(s.points[0],o.points[0]),o.length||0===o.length)){o.length=z.distancePoints(s.points[s.points.length-1],o.points[o.points.length-1]);var c=s.points,d=o.points;o.direction=z.direction(c[c.length-1],d[d.length-1])}},t.prototype.addOrRemoveSegment=function(e,i,r){for(var s,o,a=[],l={segments:e.segments},h=0;h0?"Bottom":"Top":r>0?"Right":"Left",length:i.points[0].x===i.points[1].x?s:r},!0)),l.push(new bi(e,"segments",{type:"Orthogonal",direction:c,length:h/2},!0));var p={element:e,addSegments:l,type:"Addition",cancel:!1};return this.commandHandler.triggerEvent(Ce.segmentCollectionChange,p),p.cancel||(e.segments=l.concat(e.segments),a=o+2),a},t.prototype.insertFirstSegment=function(e,i,r,s,o){var a,l,d,u,h=[];if(e.sourcePortID&&i.length&&e.segments[0].points.length>2)for(var p=void 0,f=0;f0?"Bottom":"Top":r>0?"Right":"Left"),p=u,h.push(u)}else h.push(new bi(e,"segments",{type:"Orthogonal",direction:i.direction,length:i.length/3},!0)),"Bottom"===i.direction||"Top"===i.direction?(l=Math.abs(r),a=r>0?"Right":"Left"):(l=Math.abs(s),a=s>0?"Bottom":"Top"),u=new bi(e,"segments",{type:"Orthogonal",direction:a,length:l},!0),h.push(u);var y={element:e,addSegments:h,type:"Addition",cancel:!1};if(this.commandHandler.triggerEvent(Ce.segmentCollectionChange,y),!y.cancel){if(e.sourcePortID&&i.length&&e.segments[0].points.length>2)e.segments.splice(0,1),d=1;else{var S=e.segments[1];S&&S.length&&(S.length=a!==S.direction?S.length+l:S.length-l),d=2,i.length=2*i.length/3}e.segments=h.concat(e.segments)}return d},t.prototype.updateAdjacentSegments=function(e,i,r,s){var o=e.segments[parseInt(i.toString(),10)],a=o.points[o.points.length-1],h=!0;"Orthogonal"===o.type&&(o.points[0]=o.points[0],o.points[o.points.length-1]=a,e.segments[i-1]&&(h=this.updatePreviousSegment(r,s,e,i)),e.segments.length-1>i&&h&&this.updateNextSegment(e,o,e.segments[i+1],r,s))},t.prototype.addTerminalSegment=function(e,i,r,s,o){var l,h,c,d,a=e.segments.indexOf(i),u=[],p=e.segments.pop(),f=e.segments[e.segments.length-1];l=f&&"Orthogonal"===f.type?f:null;for(var g=0;g0&&"Left"===o.direction?c.middleLeft:c.middleRight,o.length>c.width/2?Math.abs(a.length)0&&"Top"===o.direction?c.topCenter:c.bottomCenter,o.length>c.height/2?Math.abs(a.length)1)for(var a=0,l=this.diagram.views;a0)for(var e=t===Ce.onUserHandleMouseLeave?this.previousAction:this.action,i={element:void 0},r=0;r0)for(var r={element:void 0},s=void 0,o=void 0,a=0;a-1&&(o=s,this.previousTarget=i,this.targetItem=e),o===e.fixedUserHandles[parseInt(a.toString(),10)].id&&(r.element=e.fixedUserHandles[parseInt(a.toString(),10)],this.userHandle(t,a,r,e))},n.prototype.mouseDown=function(t){if(!0!==this.inAction||!(this.tool instanceof XI||this.tool instanceof pa)){this.focus=!0;var e=t.touches,i=!!document.getElementsByClassName("e-dragclone")[0];if(this.isMouseOnScrollBar(t)&&!i)return this.isScrolling=!0,void t.preventDefault();if(this.checkFixedUserHandleEvent(Ce.onFixedUserHandleMouseDown,this.targetItem,this.previousTarget),this.checkUserHandleEvent(Ce.onUserHandleMouseDown),!this.checkEditBoxAsTarget(t)&&Wv(this.diagram)||Lc(this.diagram)&&!FI(this.diagram))if(("Select"===this.action||"Drag"===this.action)&&this.diagram.updatePortVisibility(this.hoverElement,hi.Hover,!0),!(this.tool instanceof Ph||this.tool instanceof zh)||2!==t.button&&2!==t.buttons)if(!0===this.inAction&&!0===this.isMouseDown&&(this.tool instanceof Ph||this.tool instanceof zh))this.isMouseDown=!0,this.eventArgs={},this.getMouseEventArgs(this.currentPosition,this.eventArgs),this.eventArgs.position=this.currentPosition,this.tool.mouseDown(this.eventArgs);else{this.isMouseDown=!0,this.currentPosition=this.prevPosition=this.getMousePosition(t),this.eventArgs={},this.diagram.textEditing&&!this.isMouseOnScrollBar(t)&&(this.diagram.endEdit(),this.diagram.textEditing=!1,"Canvas"===this.diagram.mode&&1!==this.diagram.scroller.currentZoom&&this.diagram.refreshDiagramLayer());var s=this.getTargetElement();this.action=this.diagram.findActionToBeDone(s.obj,s.sourceElement,this.currentPosition,s.target);var o=this.isMetaKey(t);o&&t.shiftKey&&this.diagram.connectorEditingToolModule?this.action="SegmentEnd":(o||t.shiftKey)&&(jv(this.diagram)||Vv(this.diagram))&&(this.action="Select"),this.tool=this.diagram.getTool(this.action),this.tool||(this.action="Select",this.tool=this.diagram.getTool(this.action)),this.getMouseEventArgs(this.currentPosition,this.eventArgs),(o||t.shiftKey)&&(this.eventArgs.info=o&&t.shiftKey?{ctrlKey:o,shiftKey:t.shiftKey}:{ctrlKey:!0}),this.eventArgs.position=this.currentPosition;var l=this.diagram.selectedItems.nodes;if(this.tool.mouseDown(this.eventArgs),this.diagram.selectedItems.canToggleSelection&&l&&this.diagram.selectedItems.nodes&&this.tool instanceof ua)for(var h=0;h=2&&(this.touchStartList=VF(this.touchStartList,0,e)),e||t.preventDefault())}else this.inAction=!1,this.tool.mouseUp(this.eventArgs);!this.isForeignObject(t.target)&&!this.isForeignObject(t.target,!0)&&!e&&t.preventDefault()}},n.prototype.mouseMoveExtend=function(t,e){(this.tool instanceof Ph||this.tool instanceof zh)&&this.tool.mouseMove(this.eventArgs),this.diagram.scrollSettings.canAutoScroll?this.checkAutoScroll(t):this.blocked||this.tool.mouseMove(this.eventArgs),this.eventArgs.target&&(this.hoverElement=this.eventArgs.target);var i=!((this.eventArgs.target instanceof te||this.eventArgs.target instanceof de)&&(e instanceof te||e instanceof de));this.tool instanceof Pd&&this.diagram.updatePortVisibility(this.hoverElement instanceof te||this.hoverElement instanceof de?this.hoverElement:this.hoverNode,hi.Connect|hi.Hover,i),this.hoverElement instanceof te&&this.hoverNode instanceof te&&this.hoverNode&&this.hoverNode.id!==this.hoverElement.id&&this.diagram.updatePortVisibility(this.hoverNode,hi.Connect|hi.Hover,!0),this.hoverElement instanceof de&&this.hoverElement.ports.length>0&&this.diagram.updatePortVisibility(this.hoverElement,hi.Connect|hi.Hover,!0),this.previousElement instanceof te&&this.hoverElement&&this.previousElement.id!==this.hoverElement.id&&this.diagram.updatePortVisibility(this.previousElement,hi.Connect|hi.Hover,!0),this.previousElement=this.hoverElement,""!==this.diagram.tooltip.content&&(this.hoverElement=null),this.hoverNode=i?null:e},n.prototype.checkAction=function(t){if("LabelSelect"===this.action&&this.eventArgs.sourceWrapper&&(this.eventArgs.sourceWrapper instanceof ni||this.eventArgs.sourceWrapper instanceof Jn)){var e=this.commandHandler.findTarget(this.eventArgs.sourceWrapper,this.eventArgs.source);!_r(this.diagram,e,!1,this.eventArgs.sourceWrapper)&&to(e)&&(this.action="LabelDrag",this.tool=this.getTool(this.action),this.tool.mouseDown(this.initialEventArgs))}else to(t)&&Td(t)&&this.initialEventArgs&&this.initialEventArgs.source&&"Select"===this.action&&(!_r(this.diagram,this.eventArgs.source,!1)&&this.eventArgs.source instanceof si&&this.getMouseEventArgs(this.currentPosition,this.eventArgs),(!(t instanceof de)||t instanceof de&&!(wr(this.currentPosition,t.sourcePoint,t.hitPadding)||wr(this.currentPosition,t.targetPoint,t.hitPadding)))&&(this.action="Drag"),this.tool=this.getTool(this.action),this.tool.mouseDown(this.initialEventArgs))},n.prototype.isSwimlaneElements=function(t){return!(t&&(t.isLane||t.isPhase||t.isHeader))},n.prototype.mouseMove=function(t,e){if(this.focus=!0,this.isScrolling)t.preventDefault();else if(Wv(this.diagram)||Lc(this.diagram)&&!FI(this.diagram)){this.currentPosition=this.getMousePosition(t);var i=this.diagram.findObjectsUnderMouse(this.currentPosition),r=this.diagram.findObjectUnderMouse(i,this.action,this.inAction);!function nse(n,t){n.rulerSettings.showRulers&&(n.hRuler.drawRulerMarker(n.hRuler.element,t,n.scroller.horizontalOffset),n.vRuler.drawRulerMarker(n.vRuler.element,t,n.scroller.verticalOffset))}(this.diagram,this.currentPosition);var s=!1,o=void 0;if("touchmove"===t.type&&(e=t.touches)&&e.length>1&&(this.touchMoveList=VF(this.touchMoveList,0,e),"PinchZoom"!==this.action&&(s=!0)),!1===z.equals(this.currentPosition,this.prevPosition)||this.inAction){if(!1===this.isMouseDown||s){this.eventArgs={};var a=null,l=void 0;if(null!==r){if((a=this.diagram.findElementUnderMouse(r,this.currentPosition,this.diagram))&&(l=this.commandHandler.findTarget(a,r)),(l instanceof Zn||l instanceof Nr)&&(l.tooltip&&""!==l.tooltip.content||(l=r)),l!==this.hoverElement){var h=this.getContent();this.hoverElement&&"Auto"===this.hoverElement.tooltip.openOn&&""!==h&&this.elementLeave(),this.diagram.updatePortVisibility(this.hoverElement,hi.Hover,!0),r instanceof te&&(this.hoverNode=r);var c=!0;!this.isSwimlaneElements(r)&&this.hoverElement&&this.isSwimlaneElements(this.hoverElement)&&(c=!1),this.hoverElement=c?r:this.hoverElement;var d,u=void 0;(d=this.diagram.findElementUnderMouse(r,this.currentPosition,this.diagram))instanceof Ke&&((u=this.commandHandler.findTarget(d,r))instanceof Es||u instanceof xc)&&this.hoverElement.constraints&ri.ToolTip&&(this.hoverElement=u);var p=void 0;d instanceof ni&&((p=this.commandHandler.findTarget(d,r))instanceof Zn||p instanceof Nr)&&p.constraints&Lr.Tooltip&&(this.hoverElement=p),c?this.elementEnter(this.currentPosition,!1):this.hoverElement=r}else this.hoverElement&&this.hoverElement===l&&this.hoverElement.tooltip.content&&void 0!==this.diagram.tooltipObject&&"Mouse"===this.hoverElement.tooltip.relativeMode&&this.setTooltipOffset(this.currentPosition);a&&(o=this.commandHandler.findTarget(a,r))}this.action=this.diagram.findActionToBeDone(r,a,this.currentPosition,o),this.checkFixedUserHandleEvent(Ce.onFixedUserHandleMouseEnter,r,a),this.checkUserHandleEvent(Ce.onUserHandleMouseEnter),this.checkPreviousAction(),this.getMouseEventArgs(this.currentPosition,this.eventArgs),this.tool=this.getTool(this.action),this.mouseEvents(),this.tool instanceof pa||this.tool instanceof zh||this.tool instanceof Ph?this.tool.mouseMove(this.eventArgs):e&&this.tool instanceof em&&this.tool.mouseDown(this.eventArgs),this.updateCursor(),this.renderUmlHighLighter(this.eventArgs);var f=!1;this.hoverElement&&!(this.tool instanceof em)&&r instanceof te&&this.isSwimlaneElements(r)&&(0===this.diagram.selectedItems.nodes.length||!_r(this.diagram,this.hoverElement))||this.hoverElement instanceof de||(f=!0),this.hoverElement&&!(this.tool instanceof em)&&r instanceof de&&(0===this.diagram.selectedItems.connectors.length||!_r(this.diagram,this.hoverElement))||this.hoverElement instanceof te||(f=!0),this.diagram.updatePortVisibility(this.hoverElement,hi.Hover,f);var g=this.getContent();null===r&&this.hoverElement&&"Auto"===this.hoverElement.tooltip.openOn&&g&&(this.hoverElement=null,this.elementLeave()),s=!1}else{this.eventArgs.position=this.currentPosition,"Drag"===this.action&&!_r(this.diagram,this.eventArgs.source,!1)&&this.eventArgs.source instanceof si&&this.getMouseEventArgs(this.currentPosition,this.eventArgs),this.mouseEvents(),(t.ctrlKey||t.shiftKey)&&(this.eventArgs.info=t.ctrlKey&&t.shiftKey?{ctrlKey:t.ctrlKey,shiftKey:t.shiftKey}:{ctrlKey:!0}),this.checkAction(r);var y=this.getConnectorPadding(this.eventArgs);this.getMouseEventArgs(this.currentPosition,this.eventArgs,this.eventArgs.source,y),this.updateCursor(),this.inAction=!0,this.initialEventArgs=null,("Drag"===this.action||"Rotate"===this.action)&&(this.diagram.diagramActions=this.diagram.diagramActions|ee.Interactions);var S=this.diagram.scroller.getPageBounds();this.mouseMoveExtend(t,r);var b=this.diagram.scroller.getPageBounds();if(r&&(S.width!==b.width||S.height!==b.height||S.x!==b.x||S.y!==b.y)&&this.diagram.views&&this.diagram.views.overview){var M=this.diagram.views.overview;M.updateView(M)}}this.prevPosition=this.currentPosition,this.isForeignObject(t.target,!0)||t.preventDefault()}}},n.prototype.getContent=function(){var i,t=this.hoverElement instanceof te&&this.hoverElement.constraints&ie.Tooltip||this.hoverElement instanceof de&&this.hoverElement.constraints&qe.Tooltip||(this.hoverElement instanceof Es||this.hoverElement instanceof xc)&&this.hoverElement.constraints&ri.ToolTip||(this.hoverElement instanceof Zn||this.hoverElement instanceof Nr)&&this.hoverElement.constraints&Lr.Tooltip,e=this.hoverElement;e instanceof te&&e.children&&e.children.length>0&&(i=this.findIntersectChild(e));var r=t?this.hoverElement.tooltip.content:this.diagram.tooltip.content;return i?i.tooltip.content:r},n.prototype.findIntersectChild=function(t){for(var e,i=new Ne(this.currentPosition.x,this.currentPosition.y,8,8),r=0;r1&&1===t.which&&!function one(n){return!!(n&ee.PreventClearSelection)}(this.diagram.diagramActions)&&(c=!1,this.commandHandler.clearSelection()),(!_r(this.diagram,h)||!c)&&(this.commandHandler.selectObjects([h],void 0,a),this.diagram.selectedItems.canToggleSelection)){var d=this.diagram.selectedItems.nodes;d?d[0].parentObj instanceof Bd&&(s=!0):this.diagram.selectedItems.connectors.length>0&&(s=!0)}}var u=!1,p=this.updateContainerProperties(),f=void 0;if(this.addUmlNode(),this.inAction=!1,this.isMouseDown=!1,this.diagram.selectedObject.helperObject&&(f=this.updateContainerBounds()),this.tool&&(this.tool.prevPosition||this.tool instanceof eF)){this.eventArgs.position=this.currentPosition;var g=this.getConnectorPadding(this.eventArgs);this.getMouseEventArgs(this.currentPosition,this.eventArgs,this.eventArgs.source,g);var v=this.isMetaKey(t);if((v||t.shiftKey)&&(this.eventArgs.info=v&&t.shiftKey?{ctrlKey:v,shiftKey:t.shiftKey}:{ctrlKey:!0}),this.diagram.diagramActions&ee.Interactions&&(this.diagram.diagramActions=this.diagram.diagramActions&~ee.Interactions),this.eventArgs.clickCount=t.detail,this.diagram.selectedObject.helperObject&&(this.tool instanceof ua||this.tool instanceof zd)){if(this.diagram.selectedObject.actualObject&&""!==this.diagram.selectedObject.actualObject.parentId){var S=this.diagram.getObject(this.diagram.selectedObject.actualObject.parentId);S&&S.isLane&&(this.commandHandler.isContainer=!0)}(u=this.diagram.lineRoutingModule&&this.diagram.nameTable.helper&&this.eventArgs.target&&this.eventArgs.target.isLane&&(this.eventArgs.source instanceof si&&this.eventArgs.source.nodes.length>0&&""===this.eventArgs.source.nodes[0].parentId||""===this.eventArgs.source.parentId))&&(this.diagram.diagramActions=this.diagram.diagramActions|ee.PreventLaneContainerUpdate),this.tool.mouseUp(this.eventArgs,p.isPreventHistory)}else{if(this.diagram.selectedItems.canToggleSelection){var b=void 0,M=void 0;if(this.diagram.selectedItems.nodes.length>0)for(var w=0;w1&&D[0].id===i[parseInt(w.toString(),10)].id||r.length>0)&&(M=!0);!this.isSwimlaneSelected&&!s&&!M&&this.tool instanceof ua&&"Select"===this.currentAction&&(!b||this.diagram.selectedItems.connectors.length>0)&&this.commandHandler.clearSelection(!0)}this.isSwimlaneSelected=!1,this.tool.mouseUp(this.eventArgs),this.diagram.checkMenu&&(-1!==window.navigator.userAgent.indexOf("Linux")||-1!==window.navigator.userAgent.indexOf("X11"))&&(!t.pageY&&t instanceof TouchEvent&&t.changedTouches?(window.getSelection().removeAllRanges(),this.diagram.contextMenuModule.contextMenu.open(t.changedTouches[0].pageY,t.changedTouches[0].pageX,this.diagram.element),t.preventDefault()):this.diagram.contextMenuModule.contextMenu.open(t.pageY,t.pageX,this.diagram.element),this.diagram.checkMenu=!1)}p.hasStack&&this.diagram.endGroupAction()}if(f&&this.diagram.endGroupAction(),this.updateContainerBounds(!0),2!==this.eventArgs.clickCount&&(this.commandHandler.updateSelectedNodeProperties(this.eventArgs.source),u)){this.diagram.diagramActions=this.diagram.diagramActions&~ee.PreventLaneContainerUpdate;var A=this.eventArgs.source instanceof si?this.eventArgs.source.nodes:[this.eventArgs.source];if(A)for(w=0;w0&&!N&&this.diagram.renderSelector(!0),!this.inAction&&!this.diagram.currentSymbol&&this.eventArgs){var T=this.getTargetElement();this.diagram.tool!==Ci.ZoomPan&&this.diagram.triggerEvent(Ce.click,{element:T.target instanceof Es?T.target:this.eventArgs.source||this.diagram,position:this.eventArgs.position,count:t.detail,actualObject:this.eventArgs.actualObject,button:0===t.button?"Left":1===t.button?"Middle":"Right"})}this.eventArgs={}}this.diagram.diagramActions=this.diagram.diagramActions&~ee.PreventLaneContainerUpdate,e&&this.updateAnnotation(this.diagram.selectedItems),this.eventArgs={},this.diagram.commandHandler.removeStackHighlighter()},n.prototype.isSwimlaneChild=function(t){if(t.shape&&"SwimLane"!==t.shape.type){var e=this.diagram.nameTable[t.parentId];if(!e)return!1;var i=e.parentId?this.diagram.nameTable[e.parentId]:e;return i&&i.shape&&"SwimLane"===i.shape.type}return!1},n.prototype.updateAnnotation=function(t){var e=t.nodes;if(e.length>0)for(var i=0;i0&&(a+=1),h.isPhase){l="Horizontal"===r.orientation?this.currentPosition.x-e.wrapper.bounds.x:this.currentPosition.y-(e.wrapper.bounds.y+r.header.height);var g={id:Qe(),offset:l,header:{annotation:{content:void 0===h.phases[0].header?"Phase":h.phases[0].header.annotation.content,style:void 0===h.phases[0].header?{}:h.phases[0].header.annotation.style}},style:void 0===h.phases[0]?{}:h.phases[0].style};this.diagram.addPhases(e,[g])}else{var v={id:Qe(),style:h.lanes[0].style,header:{annotation:{content:h.lanes[0].header.annotation.content,style:h.lanes[0].header.annotation.style},style:h.lanes[0].header.style}};if("Horizontal"===h.orientation?v.height=h.lanes[0].height:v.width=h.lanes[0].width,"Horizontal"===r.orientation?(s=i.rowIndex?i.rowIndex:this.diagram.nameTable[i.parentId].rowIndex,i.wrapper.offsetYs)v.header.width=r.lanes[parseInt(s.toString(),10)].header.width,v.header.height=r.lanes[parseInt(s.toString(),10)].header.height;else{var S=void 0;S="Horizontal"===r.orientation?i.rowIndex<3?0:s-a-1:s-1,v.header.width=r.lanes[parseInt(S.toString(),10)].header.width,v.header.height=r.lanes[parseInt(S.toString(),10)].header.height}f&&("height"===f?(v.width=v.height,delete v.height):(v.height=v.width,delete v.width)),this.diagram.addLanes(e,[v],"Horizontal"===r.orientation?s-a:s)}this.commandHandler.select(e)}else if(h.isLane){var b={id:Qe(),width:t.width,height:t.height,addInfo:t.addInfo,shape:{type:"SwimLane",header:{annotation:{content:void 0===h.header?"Header":h.header.annotation.content,style:void 0===h.header?{}:h.header.annotation.style},height:50,style:h.header?h.header.style:h.lanes[0].header.style},phases:[{id:Qe(),header:{annotation:{content:void 0===h.phases||void 0===h.phases[0].header?"Phase":h.phases[0].header.annotation.content,style:void 0===h.phases||void 0===h.phases[0].header?{}:h.phases[0].header.annotation.style},style:void 0===h.phases||void 0===h.phases[0].header?{}:h.phases[0].header.style},style:void 0===h.phases?{}:h.phases[0].style}],lanes:[{id:Qe(),height:t.height,width:t.width,style:h.lanes[0].style,header:{annotation:{content:h.lanes[0].header.annotation.content,style:h.lanes[0].header.annotation.style},style:h.lanes[0].header.style}}],orientation:h.orientation}};"Vertical"===h.orientation&&(b.width+=20),b.offsetX=this.currentPosition.x+b.width/2,b.offsetY=this.currentPosition.y+b.height/2,b.style=t.style,this.diagram.add(b)}},n.prototype.mouseLeave=function(t){this.tool&&this.inAction&&this.tool.mouseLeave(this.eventArgs),this.diagram.selectedObject.helperObject&&(this.updateContainerProperties(),this.updateContainerBounds()&&this.diagram.endGroupAction()),this.eventArgs&&this.eventArgs.source&&(this.diagram.updatePortVisibility(this.eventArgs.source,hi.Hover,!0),this.hoverElement=null),this.eventArgs&&!this.eventArgs.source&&this.hoverElement&&(this.hoverElement=null),this.tool instanceof Pd&&this.eventArgs&&this.eventArgs.target&&this.eventArgs.target instanceof te&&(this.diagram.updatePortVisibility(this.eventArgs.target,hi.Hover|hi.Connect,!0),this.hoverElement=null);var i=this.diagram.selectedItems;i&&i.wrapper&&(lm(this.diagram,i)||this.diagram.renderSelector(!0)),(this.diagram.diagramActions&ee.Interactions||this.diagram.diagramActions&ee.ToolAction)&&(this.diagram.diagramActions=this.diagram.diagramActions&~ee.ToolAction),this.isMouseDown=!1,this.focus=!1,this.touchStartList=null,this.touchMoveList=null,this.elementLeave(),this.commandHandler.removeSnap(),this.inAction=!1,this.eventArgs={},this.diagram.selectedObject&&this.diagram.selectedObject.helperObject&&(this.diagram.remove(this.diagram.selectedObject.helperObject),this.diagram.selectedObject={helperObject:void 0,actualObject:void 0}),this.tool=null,function rse(){var t,e,n=document.getElementsByClassName("e-d-ruler-marker");if(n&&n.length>0)for(e=n.length-1;e>=0;e--)(t=n[parseInt(e.toString(),10)])&&t.parentNode.removeChild(t)}(),"Rotate"===this.action&&this.diagram.diagramCanvas.classList.remove("e-diagram-rotate"),t.preventDefault()},n.prototype.mouseWheel=function(t){this.diagram.blazorActions|=on.interaction;var e={event:t,cancel:!1};if(this.diagram.triggerEvent(Ce.mouseWheel,e),!e.cancel){var i=t.wheelDelta>0||-40*t.detail>0,r=this.getMousePosition(t);if(this.diagram.tooltipObject.close(),this.isMetaKey(t)){var o=this.diagram.scrollSettings.zoomFactor;this.diagram.zoomTo(i?{type:"ZoomIn",zoomFactor:o,focusPoint:r}:{type:"ZoomOut",zoomFactor:o,focusPoint:r}),t.preventDefault()}else{var a=this.diagram.scroller.horizontalOffset,l=this.diagram.scroller.verticalOffset,h=i?10:-10;this.tool&&(this.tool instanceof Ph||this.tool instanceof zh)&&(this.eventArgs={},this.getMouseEventArgs(r,this.eventArgs),this.eventArgs.position=r,this.tool.mouseWheel(this.eventArgs)),this.diagram.scrollActions|=ca.Interaction;var c=!0;if(t.isTrusted){var d=!1;(Math.abs(t.deltaY)<100&&-0===Math.abs(t.deltaX)||Math.abs(t.deltaX)<100&&-0===Math.abs(t.deltaY))&&(d=!0);var u=!1;(0!==t.deltaX||0!==t.deltaY)&&(u=navigator.userAgent.includes("Macintosh")),u?Math.abs(t.deltaX)>Math.abs(t.deltaY)?(t.shiftKey||t.deltaX&&-0!==t.deltaX&&(d||!u))&&this.diagram.scroller.zoom(1,h,0,r,c,void 0,d):t.deltaY&&-0!==t.deltaY&&(d||!u)&&this.diagram.scroller.zoom(1,0,h,r,c,void 0,d):t.shiftKey||t.deltaX&&-0!==t.deltaX&&(d||!u)?this.diagram.scroller.zoom(1,h,0,r,c,void 0,d):t.deltaY&&-0!==t.deltaY&&(d||!u)&&this.diagram.scroller.zoom(1,0,h,r,c,void 0,d)}else t.shiftKey||t.deltaX&&-0!==t.deltaX?this.diagram.scroller.zoom(1,h,0,r,c):this.diagram.scroller.zoom(1,0,h,r,c);this.diagram.scrollActions&=~ca.Interaction,(a!==this.diagram.scroller.horizontalOffset||l!==this.diagram.scroller.verticalOffset)&&t.preventDefault()}if(this.diagram.textEditing){if(this.diagram.isTriggerEvent=!0,this.diagram.activeLabel.parentId){var f=this.diagram.getObject(this.diagram.activeLabel.parentId);this.diagram.startTextEdit(f,this.diagram.activeLabel.id)}this.diagram.isTriggerEvent=!1}this.diagram.blazorActions=this.diagram.blazorActions&~on.interaction}},n.prototype.keyDown=function(t){if(t.fromMouseEvents&&(t.ctrlKey&&(this.keyArgs.keyModifiers=1),t.shiftKey&&(this.keyArgs.keyModifiers=4),t.shiftKey&&t.ctrlKey&&(this.keyArgs.keyModifiers=5)),!(this.diagram.diagramActions&ee.TextEdit)&&!this.checkEditBoxAsTarget(t)||"Escape"===t.key||27===t.keyCode){var i=void 0,r=t.keyCode?t.keyCode:t.which,s=t.key;("ArrowDown"===s||"ArrowUp"===s||"ArrowLeft"===s||"ArrowRight"===s)&&(this.isNudgeKey=!0);var o=this.isMetaKey(t);if(this.diagram.commandManager&&this.diagram.commands)for(var l=0,h=Object.keys(this.diagram.commands);l4&&(S({keyDownEventArgs:KeyboardEvent,parameter:i.parameter,type:"KEYDOWN"}),this.keyCount=0)),this.isKeyUp=!1):S({keyDownEventArgs:KeyboardEvent,parameter:i.parameter})}break}}}}this.keyArgs={element:this.diagram.selectedItems,key:t.key,keyCode:t.keyCode?t.keyCode:t.which},this.getKeyModifier(this.keyArgs,t),this.diagram.diagramActions&ee.TextEdit&&this.getlabel(this.keyArgs,t),this.diagram.triggerEvent(Ce.keyDown,this.keyArgs)},n.prototype.getlabel=function(t,e){var i=this.diagram.activeLabel;t.target=this.diagram.element.id+"_editBox";var r=this.diagram.nameTable[i.parentId];if(document.getElementById(this.diagram.element.id+"_editBox")){t.text=document.getElementById(this.diagram.element.id+"_editBox").value;for(var s=0;s=this.diagram.scroller.viewPortWidth-18?r="right":e.x+this.diagram.scroller.horizontalOffsetthis.diagram.scroller.viewPortHeight-18?r="bottom":e.y+this.diagram.scroller.verticalOffset0&&(s=this.findIntersectChild(this.hoverElement)),"Auto"===this.hoverElement.tooltip.openOn&&""!==r&&Ex(this.diagram,s||(i?this.hoverElement:void 0)),this.hoverElement.tooltip.content&&("Mouse"===this.hoverElement.tooltip.relativeMode?this.setTooltipOffset(t):(this.diagram.tooltipObject.offsetX=0,this.diagram.tooltipObject.offsetY=0));var o=this.diagram.findObjectsUnderMouse(this.currentPosition),a=this.diagram.findObjectUnderMouse(o,this.action,this.inAction);if(null!==a){var l=void 0;this.hoverElement.tooltip.isSticky&&(this.diagram.tooltipObject.isSticky=!0),a instanceof te&&a.children&&a.children.length>0&&(a=s||a),l=a.ports&&(this.hoverElement instanceof Es||this.hoverElement instanceof xc)||a.annotations&&(this.hoverElement instanceof Zn||this.hoverElement instanceof Nr)?document.getElementById(a.id+"_"+this.hoverElement.id):document.getElementById(a.id+(a.shape&&a.shape instanceof hm?"_content_native_element":"_groupElement")),"Auto"===this.hoverElement.tooltip.openOn&&""!==r&&(this.diagram.tooltipObject.close(),this.diagram.tooltipObject.openOn=this.hoverElement.tooltip.openOn,this.diagram.tooltipObject.dataBind()),function Kre(n,t){var e=0;return n instanceof de?n.constraints&qe.Tooltip?e=n.constraints&qe.Tooltip:n.constraints&qe.InheritTooltip&&(e=t.constraints&rt.Tooltip):n instanceof Es||n instanceof xc?n.constraints&ri.ToolTip?e=n.constraints&ri.ToolTip:n.constraints&ri.InheritTooltip&&(e=t.constraints&rt.Tooltip):n instanceof Zn||n instanceof Nr?n.constraints&Lr.Tooltip&&(e=n.constraints&Lr.Tooltip):n.constraints&ie.Tooltip?e=n.constraints&ie.Tooltip:n.constraints&ie.InheritTooltip&&(e=t.constraints&rt.Tooltip),e}(this.hoverElement,this.diagram)&&"Auto"===this.hoverElement.tooltip.openOn&&(this.diagram.tooltipObject.target=this.hoverElement.id,this.diagram.tooltipObject.open("Mouse"===this.hoverElement.tooltip.relativeMode?this.diagram.element:l))}}},n.prototype.elementLeave=function(){this.diagram.tooltipObject&&!this.diagram.tooltipObject.isSticky&&"Custom"!==this.diagram.tooltipObject.openOn&&this.diagram.tooltipObject.close()},n.prototype.setTooltipOffset=function(t){var e=function Mse(n,t,e,i){var o="Mouse"===(!(e instanceof te?e.constraints&ie.InheritTooltip:e instanceof de?e.constraints&qe.InheritTooltip:e.constraints&ri.InheritTooltip)&&(e instanceof te?e.constraints&ie.Tooltip:e instanceof de?e.constraints&qe.Tooltip:e.constraints&ri.ToolTip)?e.tooltip.relativeMode:n.tooltip.relativeMode);"Mouse"===i?o=!0:"Object"===i&&(o=!1);var a=function wse(n,t,e,i){var o,r={},s=document.getElementById(e.element.id);if(n instanceof te||n instanceof de)o=n.wrapper.bounds;else{var a=e.findObjectsUnderMouse(t),l=e.findObjectUnderMouse(a,"Select",!1);o=e.findElementUnderMouse(l,t,e).bounds}var c=s.getBoundingClientRect();switch(e.tooltipObject.position){case"BottomCenter":r=zc(t,o.bottomCenter,e,i,c.width/2,c.height);break;case"BottomLeft":case"LeftBottom":r=zc(t,o.bottomLeft,e,i,0,c.height);break;case"BottomRight":case"RightBottom":r=zc(t,o.bottomRight,e,i,c.width,c.height);break;case"LeftCenter":r=zc(t,o.middleLeft,e,i,0,c.height/2);break;case"LeftTop":case"TopLeft":r=zc(t,o.topLeft,e,i,0,0);break;case"RightCenter":r=zc(t,o.middleRight,e,i,c.width,c.height/2);break;case"RightTop":case"TopRight":r=zc(t,o.topRight,e,i,c.width,0);break;case"TopCenter":r=zc(t,o.topCenter,e,i,c.width/2,0)}return r}(e,t,n,o),l=qa(n);return{x:a.x+l.width,y:a.y+l.height}}(this.diagram,t,this.hoverElement);this.diagram.tooltipObject.offsetX=e.x,this.diagram.tooltipObject.offsetY=e.y},n.prototype.altKeyPressed=function(t){return!!(t&pt.Alt)},n.prototype.ctrlKeyPressed=function(t){return!!(t&pt.Control)},n.prototype.shiftKeyPressed=function(t){return!!(t&pt.Shift)},n.prototype.scrolled=function(t){this.diagram.updateScrollOffset()},n.prototype.doubleClick=function(t){if(Wv(this.diagram)){var e=void 0,i=this.diagram.findObjectsUnderMouse(this.currentPosition),r=this.diagram.findObjectUnderMouse(i,this.action,this.inAction);if(null!==r&&Wv(this.diagram))if(e=this.diagram.findElementUnderMouse(r,this.currentPosition,this.diagram),this.tool&&(this.tool instanceof Ph||this.tool instanceof zh))this.tool.mouseUp(this.eventArgs),this.isMouseDown=!1,this.eventArgs={},this.tool=null,t.preventDefault();else{var o=this.diagram.commandHandler.getObjectLayer(r.id);!o||o.lock||!o.visible||this.diagram.diagramActions&ee.TextEdit||this.diagram.startTextEdit(r,e instanceof ni?e.id.split(r.id+"_")[1]:void 0)}this.diagram.triggerEvent(Ce.doubleClick,{source:r||this.diagram,position:this.currentPosition,count:t.detail})}},n.prototype.itemClick=function(t,e){var i=t;return cs(this.diagram,i,!0)?i:null},n.prototype.inputChange=function(t){var i,s,o,a,l,h,c,d,u,p=document.getElementById(this.diagram.element.id+"_editBox"),f=document.getElementById(this.diagram.element.id+"_editTextBoxDiv"),g=p.value,v=g.split("\n");(!(a=this.diagram.selectedItems.nodes[0]?this.diagram.selectedItems.nodes[0]:this.diagram.selectedItems.connectors[0])&&this.tool instanceof qI||a&&"SwimLane"===a.shape.type)&&(a=this.diagram.nameTable[this.diagram.activeLabel.parentId]),a&&("Text"!==a.shape.type&&a.annotations.length>0||"Text"===a.shape.type)&&(c=HF((o=this.diagram.getWrapper(a.wrapper,this.diagram.activeLabel.id)).style,g,void 0,void 0,i=(i=a.wrapper.bounds.width90?i:90),s=Number(p.style.fontSize.split("px")[0]),v.length>1&&""===v[v.length-1]&&(c.height=c.height+s),d=this.diagram.scroller.transform,u=P3(this.diagram)?d.scale:1,l=(12>c.height?12:c.height)*u,f.style.left=(o.bounds.center.x+d.tx)*d.scale-(h=(90>(h=c.width)?90:h)*u)/2-2.5+"px",f.style.top=(o.bounds.center.y+d.ty)*d.scale-l/2-3+"px",f.style.width=h+"px",f.style.height=l+"px",p.style.minHeight="12px",p.style.minWidth="90px",p.style.width=h+"px",p.style.height=l+"px")},n.prototype.isAddTextNode=function(t,e){return!(!(this.tool instanceof qI||e)||(this.tool=null,t&&!BI(this.diagram)&&(this.diagram.drawingObject=void 0,this.diagram.currentDrawingObject=void 0),MF(this.diagram.nodes,t.id)||MF(this.diagram.connectors,t.id)))},n.prototype.checkEditBoxAsTarget=function(t){return!(!t.target||t.target.id!==this.diagram.element.id+"_editBox")},n.prototype.getMouseEventArgs=function(t,e,i,r){var s,o,a;if(e.position=t,i?(o=this.diagram.findObjectsUnderMouse(this.currentPosition,i),s=this.diagram.findTargetObjectUnderMouse(o,this.action,this.inAction,e.position,i)):"Drag"===this.action||"ConnectorSourceEnd"===this.action||"SegmentEnd"===this.action||"OrthoThumb"===this.action||"BezierSourceThumb"===this.action||"BezierTargetThumb"===this.action||"ConnectorTargetEnd"===this.action||-1!==this.action.indexOf("Rotate")||-1!==this.action.indexOf("Resize")?(s=this.diagram.selectedItems,!this.diagram.currentSymbol&&"Drag"===this.action&&s&&this.diagram.selectedItems.nodes.length>0&&"SwimLane"===this.diagram.selectedItems.nodes[0].shape.type&&(o=this.diagram.findObjectsUnderMouse(this.currentPosition),s=this.diagram.findObjectUnderMouse(o,this.action,this.inAction))):(o=this.diagram.findObjectsUnderMouse(this.currentPosition),s=this.diagram.findObjectUnderMouse(o,this.action,this.inAction)),s&&s.isHeader&&(this.eventArgs.actualObject=s=this.diagram.nameTable[s.parentId]),s){var l=void 0,h=void 0,c=void 0;if(((a=this.diagram.findElementUnderMouse(s,this.currentPosition,this.diagram,r))&&s.ports&&s.ports.length&&!ab(s,a)||!a||!s)&&o&&o.length&&i instanceof si)for(l=i.connectors[0],c=o.length-1;c>=0;c--)if(((h=o[parseInt(c.toString(),10)])instanceof te||h instanceof de)&&l&&l.connectionPadding){if(a=this.diagram.findElementUnderMouse(s=h,this.currentPosition,this.diagram,r),l.constraints&qe.ConnectToNearByPort&&s&&s.ports&&s.ports.length&&ab(s,a))break;if((h instanceof te||h instanceof de)&&l&&l.connectionPadding&&h.wrapper.outerBounds.containsPoint(this.currentPosition)&&l.constraints&qe.ConnectToNearByNode&&!(l.constraints&qe.ConnectToNearByPort)){a=this.diagram.findElementUnderMouse(s=h,this.currentPosition,this.diagram,0);break}}}return i?(e.target=s,e.targetWrapper=a):(e.source=s,e.sourceWrapper=a),e.actualObject=this.eventArgs.actualObject,e.source instanceof si&&void 0===e.actualObject&&(e.source.nodes.length>0||e.source.connectors.length>0)&&(e.actualObject=e.source.nodes.length>0?this.diagram.nameTable[e.source.nodes[0].id]:this.diagram.nameTable[e.source.connectors[0].id]),e.startTouches=this.touchStartList,e.moveTouches=this.touchMoveList,e},n.prototype.resetTool=function(){this.action="Select",this.hoverElement=null,this.hoverNode=null,this.tool=this.diagram.getTool(this.action),this.updateCursor()},n.prototype.updateTool=function(){this.eventArgs&&!this.eventArgs.position&&(this.action="Select")},n.prototype.getTool=function(t){switch(t){case"Select":return new Kv(this.commandHandler,!0);case"Drag":return new ua(this.commandHandler);case"Rotate":return new Xx(this.commandHandler);case"LayoutAnimation":return new Une(this.commandHandler);case"FixedUserHandle":return new _ne(this.commandHandler,!0);case"Hyperlink":return new eF(this.commandHandler);case"ResizeSouthEast":case"ResizeSouthWest":case"ResizeNorthEast":case"ResizeNorthWest":case"ResizeSouth":case"ResizeNorth":case"ResizeWest":case"ResizeEast":return new zd(this.commandHandler,t);case"ConnectorSourceEnd":case"ConnectorTargetEnd":case"BezierSourceThumb":case"BezierTargetThumb":return new Pd(this.commandHandler,t);case"SegmentEnd":case"OrthoThumb":return new r_(this.commandHandler,t);case"Draw":var e="shape",i=function gse(n){var t;return n&&(n.type?t="Connector":n.shape&&!n.type&&(t="Node")),t}(this.diagram.drawingObject);if("Node"===i&&"Text"===this.diagram.drawingObject.shape.type)return new qI(this.commandHandler);if("Connector"===i&&"Freehand"===this.diagram.drawingObject.type)return new Yne(this.commandHandler);if("Node"===i&&"Polygon"===this.diagram.drawingObject.shape[""+e]&&!this.diagram.drawingObject.shape.points)return new Ph(this.commandHandler);if("Node"===i||"Node"===i&&"Polygon"===this.diagram.drawingObject.shape[""+e]&&this.diagram.drawingObject.shape.points)return new XI(this.commandHandler,this.diagram.drawingObject);if("Connector"===i&&"Polyline"===this.diagram.drawingObject.type)return new zh(this.commandHandler);if("Connector"===i)return new pa(this.commandHandler,"ConnectorSourceEnd",this.diagram.drawingObject);break;case"Pan":return new em(this.commandHandler,!1);case"PinchZoom":return new em(this.commandHandler,!0);case"PortDrag":return new ua(this.commandHandler,"Port");case"PortDraw":return new pa(this.commandHandler,"ConnectorSourceEnd",this.diagram.drawingObject);case"LabelSelect":return new Kv(this.commandHandler,!0,"LabelSelect");case"LabelDrag":return new jne(this.commandHandler);case"LabelResizeSouthEast":case"LabelResizeSouthWest":case"LabelResizeNorthEast":case"LabelResizeNorthWest":case"LabelResizeSouth":case"LabelResizeNorth":case"LabelResizeWest":case"LabelResizeEast":return new Vne(this.commandHandler,t);case"LabelRotate":return new Wne(this.commandHandler)}return null},n.prototype.getCursor=function(t){var e=this.diagram.selectedItems.annotation?this.diagram.selectedItems.wrapper.children[0]:this.diagram.selectedItems;return function Fne(n,t){if(t+=360,t%=360,-1===n.indexOf("Resize"))return Gx[""+n];var e=Gx[""+n];return t>=0&&t<25||t>=160&&t<=205||t>=340&&t<=360?e:t>=25&&t<=70||t>=205&&t<=250?"n-resize"===e||"s-resize"===e?"ne-resize":"nw-resize"===e||"se-resize"===e?"n-resize":"e-resize"===e||"w-resize"===e?"nw-resize":"e-resize":t>=70&&t<=115||t>=250&&t<=295?"n-resize"===e||"s-resize"===e?"e-resize":"nw-resize"===e||"se-resize"===e?"ne-resize":"e-resize"===e||"w-resize"===e?"n-resize":"nw-resize":t>=115&&t<=155||t>=295&&t<=340?"n-resize"===e||"s-resize"===e?"nw-resize":"nw-resize"===e||"se-resize"===e?"e-resize":"e-resize"===e||"w-resize"===e?"ne-resize":Gx[""+n]:"n-resize"}(t,this.diagram.selectedItems.annotation?e.rotateAngle+e.parentTransform:e.rotateAngle)},n.prototype.findElementUnderMouse=function(t,e,i,r){return this.objectFinder.findElementUnderSelectedItem(t,e,i,r)},n.prototype.findObjectsUnderMouse=function(t,e){return this.objectFinder.findObjectsUnderMouse(t,this.diagram,this.eventArgs,e)},n.prototype.findObjectUnderMouse=function(t,e,i){return this.objectFinder.findObjectUnderMouse(this.diagram,t,e,i,this.eventArgs,this.currentPosition)},n.prototype.findTargetUnderMouse=function(t,e,i,r,s){return this.objectFinder.findObjectUnderMouse(this.diagram,t,e,i,this.eventArgs,r,s)},n.prototype.findActionToBeDone=function(t,e,i,r){return function kne(n,t,e,i,r,s,o){if(s&&s.length>1&&r&&r.length>1)return"PinchZoom";if(i.currentSymbol)return"Drag";if("PortDraw"===i.eventHandler.action&&(i.tool&=~Ci.DrawOnce),(k3(i)||BI(i))&&i.drawingObject)return"Draw";if(Xa(i)&&(l=i.selectedItems).wrapper&&qr(l.constraints,"UserHandle"))for(var h=0,c=l.userHandles;h=50&&(l.x=(a.points[parseInt(h.toString(),10)].x+a.points[h+1].x)/2,l.y=(a.points[parseInt(h.toString(),10)].y+a.points[h+1].y)/2,wr(e,l,n.hitPadding?n.hitPadding:10)))return"OrthoThumb"}else PI(n)&&console.warn('[WARNING] :: Module "ConnectorEditing" is not available in Diagram component! You either misspelled the module name or forgot to load it.');return null}(g,l,e,i);if("OrthoThumb"===S)return S;if(qr(l.constraints,"ConnectorSourceThumb")&&OI(g)&&S||qr(l.constraints,"ConnectorTargetThumb")&&kI(g)&&S)return S}}else{var b=i.selectedItems.handleSize/2/i.scroller.currentZoom,M=10/i.scroller.currentZoom,w=Hi();qi(w,p.rotateAngle+p.parentTransform,p.offsetX,p.offsetY);var C=p.offsetX-p.pivot.x*p.actualSize.width,D=p.offsetY-p.pivot.y*p.actualSize.height,A={x:C+(.5===p.pivot.x?2*p.pivot.x:p.pivot.x)*p.actualSize.width/2,y:D-30/i.scroller.currentZoom};A=Je(w,A);var x=!!i.selectedItems.annotation,R=!(!x||!zI(i.selectedItems.annotation));if(qr(l.constraints,"Rotate")&&wr(e,A,M)&&i.selectedItems.thumbsConstraints&bt.Rotate){if(x&&R)return"LabelRotate";if(!x)return"Rotate"}if(u.Inflate(b),u.containsPoint(e)&&(S=function Pne(n,t,e,i,r,s){var o;return 1===n.selectedItems.nodes.length&&0===n.selectedItems.connectors.length&&n.selectedItems.nodes[0].container&&(o=function Hne(n,t,e,i,r){var s=10/n.scroller.currentZoom,o=40/n.scroller.currentZoom,a=n.selectedItems,l=t.actualSize.width,h=t.actualSize.height,c=new Ne(i,r,t.style.strokeWidth,h),d=new Ne(i+l,r,t.style.strokeWidth,h),u=new Ne(i,r,l,t.style.strokeWidth),p=new Ne(i,r+h,l,t.style.strokeWidth),f=cs(n,n.selectedItems.nodes[0],!0)?n.nameTable[n.selectedItems.nodes[0].parentId]:n.selectedItems.nodes[0];if(l>=o&&h>=o){if(fa(a.constraints,"ResizeEast",a.thumbsConstraints,a)&&d.containsPoint(e,s))return"ResizeEast";if(fa(a.constraints,"ResizeSouth",a.thumbsConstraints,a)&&p.containsPoint(e,s))return"ResizeSouth";if("Grid"!==f.container.type){if(fa(a.constraints,"ResizeWest",a.thumbsConstraints,a)&&c.containsPoint(e,s))return"ResizeWest";if(fa(a.constraints,"ResizeNorth",a.thumbsConstraints,a)&&u.containsPoint(e,s))return"ResizeNorth"}}return null}(n,t,e,r,s)),!o&&(!n.selectedItems.nodes[0]||!n.selectedItems.nodes[0].isPhase&&!n.selectedItems.nodes[0].isLane&&"SwimLane"!==n.selectedItems.nodes[0].shape.type)&&(o=function Bne(n,t,e,i,r,s){var o=40/n.scroller.currentZoom,a=n.selectedItems.handleSize/2/n.scroller.currentZoom,l=n.selectedItems,h=!!l.annotation;if(t.actualSize.width>=o&&t.actualSize.height>=o){if(fa(l.constraints,"ResizeSouthEast",l.thumbsConstraints,l)&&wr(e,Je(i,{x:r+t.actualSize.width,y:s+t.actualSize.height}),a))return h?"LabelResizeSouthEast":"ResizeSouthEast";if(fa(l.constraints,"ResizeSouthWest",l.thumbsConstraints,l)&&wr(e,Je(i,{x:r,y:s+t.actualSize.height}),a))return h?"LabelResizeSouthWest":"ResizeSouthWest";if(fa(l.constraints,"ResizeNorthEast",l.thumbsConstraints,l)&&wr(e,Je(i,{x:r+t.actualSize.width,y:s}),a))return h?"LabelResizeNorthEast":"ResizeNorthEast";if(fa(l.constraints,"ResizeNorthWest",l.thumbsConstraints,l)&&wr(e,Je(i,{x:r,y:s}),a))return h?"LabelResizeNorthWest":"ResizeNorthWest"}return fa(l.constraints,"ResizeEast",l.thumbsConstraints,l)&&wr(e,Je(i,{x:r+t.actualSize.width,y:s+t.actualSize.height/2}),a)?h?"LabelResizeEast":"ResizeEast":fa(l.constraints,"ResizeWest",l.thumbsConstraints,l)&&wr(e,Je(i,{x:r,y:s+t.actualSize.height/2}),a)?h?"LabelResizeWest":"ResizeWest":fa(l.constraints,"ResizeSouth",l.thumbsConstraints,l)&&wr(e,Je(i,{x:r+t.actualSize.width/2,y:s+t.actualSize.height}),a)?h?"LabelResizeSouth":"ResizeSouth":fa(l.constraints,"ResizeNorth",l.thumbsConstraints,l)&&wr(e,Je(i,{x:r+t.actualSize.width/2,y:s}),a)?h?"LabelResizeNorth":"ResizeNorth":null}(n,t,e,i,r,s)),o||null}(i,p,e,w,C,D),S))return S}}if(Lc(i)&&!n)return"Pan";if((o instanceof Es||o instanceof xc)&&(!Lc(i)||jv(i)||Vv(i))&&(S=function Rne(n,t,e,i){if(_x(t)&&(ga(t,hi.Hover)||ga(t,hi.Visible))){if(t.constraints&ri.Drag)return"PortDrag"}else if(Fx(t)&&(ga(t,hi.Hover)||ga(t,hi.Visible))&&t.constraints&ri.Draw){n.drawingObject={};var r={type:"Orthogonal",sourcePortID:t.id};return n.drawingObject=r,n.tool|=Ci.DrawOnce,n.currentDrawingObject=r,"PortDraw"}return"None"}(i,o),"None"!==S))return S;if((o instanceof Zn||o instanceof Nr)&&!Lc(i)&&Td(o))return _r(i,o,void 0,t)&&to(o)?"LabelDrag":"LabelSelect";if(null!==n){if(!(n instanceof te||n instanceof de))return"Select";if(t&&t.id){var L=t.id.split(n.id)[1];if(L&&L.match("^_icon"))return"LayoutAnimation"}if(t&&t.id)for(var O=void 0,N=0;N-1)return"FixedUserHandle";if(t instanceof ni&&t.hyperlink.link)return"Hyperlink";if(!to(n)||!_r(i,n,!1)||void 0!==i.selectedItems.annotation)return n&&Lc(i)&&!FI(i)?"Pan":i.selectedItems.nodes.length&&i.selectedItems.nodes[0].isLane&&i.selectedItems.wrapper&&i.selectedItems.wrapper.bounds.containsPoint(e)?"Drag":"Select";if(n instanceof de&&!wr(e,n.sourcePoint,n.hitPadding)&&!wr(e,n.targetPoint,n.hitPadding)||!(n instanceof de))return"Drag"}return"Select"}(t,e,this.currentPosition,this.diagram,this.touchStartList,this.touchMoveList,r)},n.prototype.updateContainerBounds=function(t){var e=!1;if(this.diagram.selectedObject.helperObject&&this.diagram.selectedObject.actualObject instanceof te){var i=this.tool instanceof zd,r=this.diagram.selectedObject.actualObject,s=this.diagram.nameTable[r.parentId];t?q3(this.diagram,r,this.currentPosition,i):((!s||s&&"SwimLane"!==s.shape.type)&&this.diagram.updateDiagramObject(r),e=function Ane(n,t,e,i){var r,o=!1;if(cs(n,t,!0)){n.protectPropertyChange(!0);var a=(r=n.nameTable[t.parentId]).wrapper;if(r&&"Canvas"===r.container.type){if(i||a.bounds.x<=e.x&&a.bounds.right>=e.x&&a.bounds.y<=e.y&&a.bounds.bottom>=e.y){var l=void 0,h=a.bounds.y,c=a.bounds.x,d=n.nameTable[r.parentId]||r;if("SwimLane"===d.shape.type)o=Jv(r,d,t,n,!0);else{var p=n.nameTable[r.parentId]||r,f=p.shape;l=p.wrapper,a.actualSize.widtha.outerBounds.x)&&(void 0!==r.rowIndex?(l.updateColumnWidth(r.columnIndex,a.outerBounds.width,!0),"Horizontal"===f.orientation&&f.phaseSize&&WI(p,n,a,r.columnIndex),Oc(n,p),n.drag(p,c-a.bounds.x,h-a.bounds.y)):n.scale(r,1+(a.outerBounds.width-a.actualSize.width)/a.actualSize.width,1,a.outerBounds.xa.outerBounds.y)&&(void 0!==r.rowIndex?(l.updateRowHeight(r.rowIndex,a.outerBounds.height,!0),n.drag(p,c-a.bounds.x,h-a.bounds.y)):n.scale(r,1,1+(a.outerBounds.height-a.actualSize.height)/a.actualSize.height,a.outerBounds.yi.y&&(h+=u>0?-1:1,u+=u>0?-1:1):i&&e.wrapper.offsetYi.x&&(h+=u>0?-1:1,u+=u>0?-1:1):i&&e.wrapper.offsetX1&&!(this.diagram.lineRoutingModule&&this.diagram.constraints&rt.LineRouting))for(var b=t.offsetX-this.diagram.selectedItems.offsetX,M=t.offsetY-this.diagram.selectedItems.offsetY,w=t.rotateAngle-this.diagram.selectedItems.rotateAngle,C=0;C-1){var x=c.children;x.splice(x.indexOf(o.id),1),this.diagram.nameTable[o.id].parentId="",i=!0,c.wrapper.children.splice(A,1)}}if(function One(n,t,e,i){var r=n,s=e.nameTable[r.parentId],o=e.nameTable[r.parentId];if(t&&o&&o.container&&"Stack"===o.container.type&&t.container&&"Stack"===t.container.type&&o.id!==t.parentId){var a=o.wrapper.children.indexOf(r.wrapper);a>-1&&(e.nameTable[r.id].parentId=t.id,o.wrapper.children.splice(a,1))}if(t&&t.parentId&&r.parentId&&"Drag"===i&&o.container&&"Stack"===o.container.type){var l=s.wrapper.children.indexOf(t.wrapper),h=s.wrapper.children.indexOf(r.wrapper),c={targetIndex:l,target:t,sourceIndex:h,source:n};s.wrapper.children.splice(h,1),s.wrapper.children.splice(l,0,r.wrapper),e.commandHandler.addHistoryEntry({type:"StackChildPositionChanged",redoObject:{targetIndex:h,target:t,sourceIndex:l,source:n},undoObject:c,category:"Internal"})}}(o,h,this.diagram,this.action),(c=cs(this.diagram,o)?this.diagram.nameTable[o.parentId]:this.diagram.nameTable[o.parentId]||o)&&c.container&&"Canvas"===c.container.type&&(c.wrapper.maxWidth=c.maxWidth=c.wrapper.actualSize.width,c.wrapper.maxHeight=c.maxHeight=c.wrapper.actualSize.height,e=!0),cs(this.diagram,o,!0)&&c&&"Canvas"===c.container.type)if(this.diagram.selectedItems.nodes.length>1)for(C=0;C0)for(var i=0;i0&&e.columnIndex>0||l&&e.isLane)){if("Horizontal"===t.container.orientation&&e.isPhase&&e.wrapper.width>e.maxWidth&&(e.maxWidth=e.wrapper.width,e.wrapper.maxWidth=e.wrapper.width),h.updateColumnWidth(e.columnIndex,r.width,!0,c),Vx(this.diagram,e,t),e.isPhase){var f=this.diagram.nameTable[""+t.shape.phases[e.columnIndex].header.id];f.maxWidth0?(r=new of(t,"",u),t.shape.classShape.attributes.push(r)):i.id.includes("_umlMethods")&&t.shape.classShape.methods.length>0&&(s=new dm(t,"",u),t.shape.classShape.methods.push(s))),"Interface"===t.shape.classifier&&(i.id.includes("_umlProperty")&&t.shape.interfaceShape.attributes.length>0?(r=new of(t,"",u),t.shape.classShape.attributes.push(r)):i.id.includes("_umlMethods")&&t.shape.interfaceShape.methods.length>0&&(s=new dm(t,"",u),t.shape.interfaceShape.methods.push(s))),"Enumeration"===t.shape.classifier&&i.id.includes("_umlMember")&&t.shape.enumerationShape.members.length>0){var p=new cb(t,"",u);t.shape.enumerationShape.members.push(p)}t.wrapper.children.indexOf(c.wrapper),this.diagram.enableServerDataBinding(!0),this.diagram.add(c),this.diagram.updateConnectorEdges(t),this.diagram.clearSelection(),this.diagram.select([this.diagram.nameTable[c.id]]),this.diagram.endGroupAction(),this.diagram.startTextEdit()}}},n}(),Zoe=function(){function n(){}return n.prototype.findObjectsUnderMouse=function(t,e,i,r,s){var o=[];r&&r instanceof si&&r.nodes.length+r.connectors.length===1&&(r=r.nodes[0]||r.connectors[0]).children&&0===r.children.length&&(i.actualObject=r);for(var a,l,h,c,f,d=r&&r instanceof de&&(r.constraints&qe.ConnectToNearByNode||r.constraints&qe.ConnectToNearByPort)&&r.connectionPadding||0,p={},g=0,v=e.spatialSearch.findObjects(new Ne(t.x-50-d,t.y-50-d,100+d,100+d));g-1&&o.splice(T,1),"UmlClassifier"===y.shape.type&&y.container&&"Stack"===y.container.type&&(T=o.indexOf(e.nameTable[e.nameTable[y.id].wrapper.children[0].id]))>-1&&o.splice(T,1)}for(var P=0;Ps.zIndex&&(t[parseInt(r.toString(),10)]=l),r>0&&i&&a&&(a.isLane||a.isPhase||a.isHeader)&&t[parseInt(r.toString(),10)].zIndex=2)for(var d=t.length-1;d>=0;d--)if(t[parseInt(d.toString(),10)].parentId){var u=am(t[parseInt(d.toString(),10)],e,""),p=am(t[d-1],e,""),g=e.nameTable[""+p];g&&u!==p&&e.nameTable[""+u].zIndex=0;f--){d=tf(e[parseInt(f.toString(),10)],!1),c=tf(e[parseInt(f.toString(),10)],!0);var g=t[""+l].tool,v=this.findTargetElement(e[parseInt(f.toString(),10)].wrapper,o,t,void 0);if("Draw"===i&&v&&(e[parseInt(f.toString(),10)]instanceof te||e[parseInt(f.toString(),10)]instanceof de)&&!ab(e[parseInt(f.toString(),10)],v)&&(g&&"ConnectorSourceEnd"===g[""+h]&&!kh(e[parseInt(f.toString(),10)])||g&&"ConnectorTargetEnd"===g[""+h]&&!da(e[parseInt(f.toString(),10)])))return u;if(e[parseInt(f.toString(),10)]instanceof te||e[parseInt(f.toString(),10)]instanceof de&&(kh(e[parseInt(f.toString(),10)])||Ad(d)||da(e[parseInt(f.toString(),10)])||Oh(c)||"PortDraw"===i&&g instanceof Pd&&"ConnectorTargetEnd"===g[""+h]&&(da(e[parseInt(f.toString(),10)])||Oh(c))))return u=e[parseInt(f.toString(),10)],p&&(u=this.isTarget(u,t,i)),s.actualObject=u,u}else if("ConnectorTargetEnd"===i&&a){for(f=e.length-1;f>=0;f--)if(c=tf(e[parseInt(f.toString(),10)],!0),(e[parseInt(f.toString(),10)]instanceof te||e[parseInt(f.toString(),10)]instanceof de)&&(da(e[parseInt(f.toString(),10)])||Oh(c)))return u=e[parseInt(f.toString(),10)],u=this.isTarget(u,t,i),s.actualObject=u,u}else{if(a&&("Drag"===i||t[""+l].tool instanceof ua)){var y=0;for(f=0;f=S.zIndex?u:S,y=Math.max(y,S.zIndex)):y=(u=S).zIndex)}return u&&"Bpmn"===u.shape.type&&(t.selectedItems.nodes.length>0&&"Bpmn"===t.selectedItems.nodes[0].shape.type||(u=null)),u&&(s.actualObject=u),u}if("Select"!==i&&"Pan"!==i||!t[""+l].tool)if("Pan"===i||"LayoutAnimation"===i){for(f=e.length-1;f>=0;f--)if((e[parseInt(f.toString(),10)]instanceof te||e[parseInt(f.toString(),10)]instanceof de)&&(v=this.findTargetElement(e[parseInt(f.toString(),10)].wrapper,o,t,void 0),"Pan"===i||v&&(v.id.match("_icon_content_shape$")||v.id.match("_icon_content_rect$"))))return e[parseInt(f.toString(),10)]}else u=e[e.length-1],s&&u&&(s.actualObject=u);else{for(f=e.length-1;f>=0;f--)if(e[parseInt(f.toString(),10)]instanceof de){var b=e[f-1];if(e[f-1]instanceof te&&b.ports){if((v=this.findTargetElement(b.wrapper,o,t,void 0))&&(v.id.match("_icon_content_shape$")||v.id.match("_icon_content_rect$")))return b;for(var M=0;M=0;s--){var o=t.children[parseInt(s.toString(),10)];if(o&&o.outerBounds.containsPoint(e,r||0))if(o.visible){if(o instanceof Cs){var a=this.findTargetElement(o,e,i);if(a)return a}var l="Clip"===o.style.textOverflow||"Ellipsis"===o.style.textOverflow;if(o.bounds.containsPoint(e,r||0)&&!l)return o;if(t.bounds.containsPoint(e,r||0)&&l)return o}else if(o instanceof Ke&&t&&t.id){var h=void 0;if(t.id.includes("group_container")){var c=t.id.slice(0,-15);h=i.getObject(c)}else h=i.getObject(t.id);if(sb(h,o.id))return o}}return t.bounds.containsPoint(e,r)&&"none"!==t.style.fill?t:null},n}(),Joe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),lf=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},n_=function(n){function t(e,i,r,s){var o=n.call(this,e,i,r,s)||this;return o.objectZIndex=-1,o.zIndexTable={},o.objects=[],o}return Joe(t,n),lf([I("")],t.prototype,"id",void 0),lf([I(!0)],t.prototype,"visible",void 0),lf([I(!1)],t.prototype,"lock",void 0),lf([I()],t.prototype,"objects",void 0),lf([I()],t.prototype,"addInfo",void 0),lf([I(-1)],t.prototype,"zIndex",void 0),t}(Ee),ET=function(n,t,e,i){return new(e||(e=Promise))(function(r,s){function o(h){try{l(i.next(h))}catch(c){s(c)}}function a(h){try{l(i.throw(h))}catch(c){s(c)}}function l(h){h.done?r(h.value):new e(function(c){c(h.value)}).then(o,a)}l((i=i.apply(n,t||[])).next())})},DT=function(n,t){var i,r,s,o,e={label:0,sent:function(){if(1&s[0])throw s[1];return s[1]},trys:[],ops:[]};return o={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function a(h){return function(c){return function l(h){if(i)throw new TypeError("Generator is already executing.");for(;e;)try{if(i=1,r&&(s=2&h[0]?r.return:h[0]?r.throw||((s=r.return)&&s.call(r),0):r.next)&&!(s=s.call(r,h[1])).done)return s;switch(r=0,s&&(h=[2&h[0],s.value]),h[0]){case 0:case 1:s=h;break;case 4:return e.label++,{value:h[1],done:!1};case 5:e.label++,r=h[1],h=[0];continue;case 7:h=e.ops.pop(),e.trys.pop();continue;default:if(!(s=(s=e.trys).length>0&&s[s.length-1])&&(6===h[0]||2===h[0])){e=0;continue}if(3===h[0]&&(!s||h[1]>s[0]&&h[1]1)for(var i=0;i-1)return e[parseInt(i.toString(),10)];return this.diagram.activeLayer},n.prototype.getLayer=function(t){for(var e=this.diagram.layers,i=0;i=0;o--)this.diagram.unSelect(this.diagram.nameTable[s[parseInt(o.toString(),10)]]),this.diagram.remove(this.diagram.nameTable[s[parseInt(o.toString(),10)]]),"default_layer"!==i.id&&this.diagram.activeLayer.id===t&&(this.diagram.activeLayer=this.diagram.layers[this.diagram.layers.length-1]);delete this.diagram.layerZIndexTable[i.zIndex],this.diagram.layers.splice(r,1),"SVG"!==this.diagram.mode&&this.diagram.refreshDiagramLayer()}},n.prototype.moveObjects=function(t,e){this.diagram.startGroupAction();for(var i={},r=[],s=0;s-1){if(r=[],(h=this.diagram.nameTable[""+s]).children)for(var f=0,g=h.children;f0){for(var y=void 0,S=0,b=r;S0)for(var r=0;r0)for(r=0;r0){t=t.concat(this.diagram.selectedItems.connectors);for(var i=0;i0)for(t=t.concat(this.diagram.selectedItems.nodes),i=0;i0){for(var i=0,r=t.shape.activity.subProcess.processes;i0&&this.copyProcesses(this.processTable[""+s])}this.clipboardData.processTable=this.processTable}},n.prototype.group=function(){this.oldSelectedObjects=sm(this.diagram);var e=this.diagram.isProtectedOnChange;this.diagram.protectPropertyChange(!0),this.diagram.diagramActions=this.diagram.diagramActions|ee.Group;var r={};r.id="group"+Qe(),(r=new te(this.diagram,"nodes",r,!0)).children=[];for(var s=this.diagram.selectedItems.nodes.concat(this.diagram.selectedItems.connectors).sort(function(h,c){return h.zIndex-c.zIndex}),o=0;o0){var a=this.diagram.add(r);a&&this.select(a),this.addHistoryEntry({type:"Group",undoObject:r,redoObject:r,category:"Internal"}),this.diagram.diagramActions=this.diagram.diagramActions&~ee.Group,this.diagram.protectPropertyChange(e)}},n.prototype.unGroup=function(t){var i=this.diagram.isProtectedOnChange;this.diagram.protectPropertyChange(!0),this.diagram.diagramActions=this.diagram.diagramActions|ee.Group;var r=[];t?r.push(t):r=this.diagram.selectedItems.nodes,this.diagram.startGroupAction();for(var s=0;s0&&this.diagram.removePorts(o,o.ports),o.annotations&&o.annotations.length>0&&!ce()&&this.diagram.removeLabels(o,o.annotations);for(var c=this.diagram.nameTable[o.parentId],d=o.children.length-1;d>=0;d--)this.diagram.nameTable[o.children[parseInt(d.toString(),10)]].parentId="",this.diagram.deleteChild(this.diagram.nameTable[o.children[parseInt(d.toString(),10)]],o),o.parentId&&o.children[parseInt(d.toString(),10)]&&this.diagram.addChild(c,o.children[parseInt(d.toString(),10)]);this.resetDependentConnectors(o.inEdges,!0),this.resetDependentConnectors(o.outEdges,!1),this.diagram.diagramActions&ee.UndoRedo||this.addHistoryEntry({type:"UnGroup",undoObject:a,redoObject:a,category:"Internal"}),o.parentId&&this.diagram.deleteChild(o,c)}this.diagram.removeNode(o,l),this.clearSelection()}this.diagram.endGroupAction(),this.diagram.diagramActions=this.diagram.diagramActions&~ee.Group,this.diagram.protectPropertyChange(i)},n.prototype.resetDependentConnectors=function(t,e){for(var i=0;i0&&(g=!1)}if(g){var y=this.cloneConnector(p,i);c.push(y),o[h.id]=y.id}}else{var S=this.cloneNode(h,i);if(c.push(S),S){o[h.id]=S.id;var b=h.inEdges;if(b)for(var M=0,w=b;M0)for(var u=0;u0)for(r=t.segments,s=0;s0&&this.diagram.drawingObject&&"Bezier"===this.diagram.drawingObject.type&&(t.segments=[]);var e=this.diagram.add(t);"SVG"!==this.diagram.mode&&this.diagram.refreshDiagramLayer(),this.selectObjects([e]),t&&!BI(this.diagram)&&(this.diagram.tool&=~Ci.DrawOnce,this.diagram.currentDrawingObject=void 0)},n.prototype.enableServerDataBinding=function(t){this.diagram.enableServerDataBinding(t)},n.prototype.addText=function(t,e){var i=this.diagram.findElementUnderMouse(t,e,this.diagram);this.diagram.startTextEdit(t,i instanceof ni?i.id.split("_")[1]:void 0)},n.prototype.isUserHandle=function(t){var e=this.diagram.selectedItems;if(e.wrapper&&qr(e.constraints,"UserHandle"))for(var i=0,r=e.userHandles;i0&&t[0]&&t[0].isLane)for(s=this.diagram.getObject(t[0].parentId),t[0].shape.header=[],a=0;a1||e&&1===t.length)){if(1!==t.length)return[2];this.clearSelection()}if(!(u||d||1!==t.length||e&&Xa(this.diagram)))return this.clearSelection(),[2]}if(!r.cancel){for(p=0;p0||e)&&f.children&&!f.parentId)for(g=0;g0||e,!0)}else this.select(f,p>0||e,!0);void 0===i&&(i=c),r={oldValue:i||[],newValue:this.getSelectedObject(),cause:this.diagram.diagramActions,state:"Changed",type:"Addition",cancel:!1},this.diagram.renderSelector(e||t&&t.length>1),ce()||this.diagram.triggerEvent(Ce.selectionChange,r),this.diagram.enableServerDataBinding(!0)}return[2]})})},n.prototype.findParent=function(t){return t.parentId&&this.findParent(t=this.diagram.nameTable[t.parentId]),t},n.prototype.selectProcesses=function(t){if(this.hasProcesses(t))for(var e=t.shape.activity.subProcess.processes,i=0;i0)},n.prototype.select=function(t,e,i){var r=this.getObjectLayer(t.id);if(Td(t)&&!(t instanceof si)&&!_r(this.diagram,t)&&r&&!r.lock&&r.visible&&t.wrapper.visible){(e=!!Xa(this.diagram)&&e)||this.clearSelection(),this.diagram.enableServerDataBinding(!1);var s=this.diagram.selectedItems;if(t instanceof te?s.nodes.push(t.isHeader?this.diagram.nameTable[t.parentId]:t):s.connectors.push(t),s.selectedObjects.push(t),e)s.wrapper.rotateAngle=s.rotateAngle=0,s.wrapper.children.push(t.wrapper);else if(s.init(this.diagram),1===s.nodes.length&&0===s.connectors.length){var l=Wx(this.diagram,s);l&&(s.wrapper.children[0]=l),s.rotateAngle=s.nodes[0].rotateAngle,s.wrapper.rotateAngle=s.nodes[0].rotateAngle,s.wrapper.pivot=s.nodes[0].pivot}i||this.diagram.renderSelector(e),this.diagram.enableServerDataBinding(!0)}},n.prototype.labelSelect=function(t,e){this.oldSelectedObjects=sm(this.diagram);var i=this.diagram.selectedItems,r=this.diagram.allowServerDataBinding;this.diagram.allowServerDataBinding=!1,i.nodes=i.connectors=[],this.diagram.allowServerDataBinding=r,t instanceof te?i.nodes[0]=t:i.connectors[0]=t,i.annotation=this.findTarget(e,t),i.init(this.diagram),this.diagram.renderSelector(!1)},n.prototype.unSelect=function(t){var e=this.diagram.selectedItems.nodes.concat(this.diagram.selectedItems.connectors),i=e.filter(function(a){return a.id!==t.id}),r={oldValue:e,newValue:i,cause:this.diagram.diagramActions,state:"Changing",type:"Removal",cancel:!1};if(this.diagram.currentSymbol||ce()||this.diagram.triggerEvent(Ce.selectionChange,r),_r(this.diagram,t)){var s=this.diagram.selectedItems,o=void 0;t instanceof te?(o=s.nodes.indexOf(t,0),s.nodes.splice(o,1)):(o=s.connectors.indexOf(t,0),s.connectors.splice(o,1)),o=s.selectedObjects.indexOf(t,0),s.selectedObjects.splice(o,1),(r={oldValue:e,newValue:i,cause:this.diagram.diagramActions,state:"Changed",type:"Removal",cancel:(r={oldValue:e,newValue:i,cause:this.diagram.diagramActions,state:"Changed",type:"Removal",cancel:!1}).cancel}).cancel||(o=s.wrapper.children.indexOf(t.wrapper,0),s.wrapper.children.splice(o,1),this.diagram.updateSelector(),this.diagram.currentSymbol||this.diagram.triggerEvent(Ce.selectionChange,r))}},n.prototype.moveSvgNode=function(t,e){var i=xt(e+"_groupElement",this.diagram.element.id),r=xt(t+"_groupElement",this.diagram.element.id);i.parentNode.insertBefore(r,i)},n.prototype.moveAfterSvgNode=function(t,e){var i=xt(e+"_groupElement",this.diagram.element.id),r=xt(t+"_groupElement",this.diagram.element.id);i.insertAdjacentElement("afterend",r)},n.prototype.sendLayerBackward=function(t){var e=this.getLayer(t);if(e&&0!==e.zIndex){var i=e.zIndex;if("SVG"===this.diagram.mode){var r=e.objects,s=this.getLayer(this.diagram.layerZIndexTable[i-1]).objects[0];if(s)for(var o=0,a=r;od&&"SwimLane"!==f.shape.type){var S=$(f);f.zIndex=d-((-1!==i.indexOf(f)?i.indexOf(f):0)+1),f.children&&(d=this.findLowestZIndex(f,c)||d),this.triggerOrderCommand(S,f,f),f.children&&this.updateGroupZindex(f,"SendToBack",d)}else"SwimLane"===f.shape.type&&(y=this.swapZIndexObjects(a,h,r,g));if("SVG"===this.diagram.mode){for(var M="SwimLane"!==this.diagram.nameTable[""+r].shape.type?d:y,w=h[parseInt(M.toString(),10)];!w&&Md)&&(d=p.zIndex)}for(var f=JSON.parse(JSON.stringify(l)),v=Number(Object.keys(l).sort(function(wo,Hl){return Number(wo)-Number(Hl)}).reverse()[0]),y=this.diagram.nameTable[""+e].zIndex,S=[],M=0;M<=v;M++)S.push(l[parseInt(M.toString(),10)]);if("SwimLane"===this.diagram.nameTable[""+e].shape.type)for(var C=v;C>=y;C--)if(l[parseInt(C.toString(),10)]&&this.diagram.nameTable[l[parseInt(C.toString(),10)]].parentId!==e){v=C;break}var D=this.diagram.nameTable[""+e];if(D.zIndexx&&(x=L.zIndex)}}else x=d;D.zIndex=x+((-1!==r.indexOf(D)?r.indexOf(D):0)+1),this.triggerOrderCommand(A,D,D)}else if("SwimLane"===D.shape.type){for(var O=0,N=-1,T=0,P=0,_=JSON.parse(JSON.stringify(l)),B=0;B<=y;B++)if(l[parseInt(B.toString(),10)]&&this.diagram.nameTable[l[parseInt(B.toString(),10)]].parentId===e&&-1===N){N=B,T=B;break}for(var j=0;j<=v;j++)f[parseInt(j.toString(),10)]&&f[parseInt(j.toString(),10)]!==e&&this.diagram.nameTable[f[parseInt(j.toString(),10)]].parentId!==e&&this.diagram.nameTable[f[parseInt(j.toString(),10)]].zIndex>=this.diagram.nameTable[""+e].zIndex&&O++;for(var ue=N,pe=0;pe<=O;pe++){for(;!l[parseInt(ue.toString(),10)];)ue++;P=this.diagram.nameTable[l[parseInt(ue.toString(),10)]].zIndex,ue++}for(var Me=P;Me<=v;Me++){for(;!_[parseInt(N.toString(),10)];)N++;for(;!l[parseInt(Me.toString(),10)];)Me++;l[parseInt(Me.toString(),10)]=_[parseInt(N.toString(),10)],this.diagram.nameTable[l[parseInt(Me.toString(),10)]].zIndex=Me,N++}l[parseInt(v.toString(),10)]=this.diagram.nameTable[""+e].id,this.diagram.nameTable[""+e].zIndex=v,ue=y+1;for(var De=T,xe=0;xe0&&("Native"===hr[0].shape.type||"HTML"===hr[0].shape.type)){for(Mi.parentNode.removeChild(Mi),De=0;De0?r[0]:null},n.prototype.findLowestZIndex=function(t,e){var r=this.diagram.nodes.filter(function(s){return-1!==e.indexOf(s.id)}).filter(function(s){return""===s.parentId&&s.id!==t.id}).map(function(s){return s.zIndex});return r.sort(function(s,o){return s-o}),r.length>0?r[0]:null},n.prototype.triggerOrderCommand=function(t,e,i){var s={zIndex:$(t).zIndex},o={zIndex:e.zIndex},a={element:i,cause:this.diagram.diagramActions,diagramAction:this.diagram.getDiagramAction(this.diagram.diagramActions),oldValue:s,newValue:o};this.diagram.triggerEvent(Ce.propertyChange,a)},n.prototype.checkGroupNode=function(t,e,i){return i[""+e].parentId===i[""+t].parentId},n.prototype.sortByZIndex=function(t,e,i){if("BringForward"===i){var r=e||"zIndex";t=t.sort(function(o,a){return a[""+r]-o[""+r]})}else{var s=e||"zIndex";t=t.sort(function(o,a){return o[""+s]-a[""+s]})}return t},n.prototype.orderCommands=function(t,e,i){var r=this,s=e.nodes;if(s=s.concat(e.connectors),t)if("SendBackward"===i)for(var o=0;oa}),S=v.filter(function(D){return D0?Math.max.apply(Math,S):a,M=y.length>0?Math.min.apply(Math,y):a;if(a!==M){var w=c.zIndexTable[parseInt(M.toString(),10)],C=c.zIndexTable[parseInt(a.toString(),10)];this.moveSvgNode(C,w)}else"SendToBack"===i&&(w=c.zIndexTable[parseInt(a.toString(),10)],C=c.zIndexTable[parseInt(b.toString(),10)],this.moveAfterSvgNode(w,C))}}else this.diagram.refreshCanvasLayers()}},n.prototype.sendForward=function(t){var e=this;if(this.diagram.protectPropertyChange(!0),Xa(this.diagram)||t){$(t||(this.diagram.selectedItems.nodes.length?this.diagram.selectedItems.nodes[0]:this.diagram.selectedItems.connectors[0]));var s=t&&t.id,o=this.diagram.layers.indexOf(this.getObjectLayer(s=s||(this.diagram.selectedItems.nodes.length?this.diagram.selectedItems.nodes[0].id:this.diagram.selectedItems.connectors[0].id))),a=$(this.diagram.nameTable),h=(parseInt(o.toString(),10),this.diagram.nameTable[""+s]),c=[],d=this.diagram.spatialSearch.findObjects(h.wrapper.bounds);d.length>2&&(d=this.sortByZIndex(d,void 0,"BringForward"));for(var u=0,p=d;u=0;f--)this.diagram.nameTable[c[parseInt(f.toString(),10)].id].parentId===s&&c.splice(f,1);if(c.length>0){var y=this.diagram.nameTable[c[c.length-1].id];if(y.parentId){var b=am(y,this.diagram,""),M=this.diagram.nameTable[""+b];M.id!==s&&(c[0]=M)}var w={};for(f=0;f0&&(Object.values(O).forEach(function(ue){ue>=T&&N.push(ue)}),0!==N.length&&this.updateZIndexBySendForward(h,N,o))}var P=[];if(Object.keys(this.changedNodeZIndexes).forEach(function(ue){if((a[""+ue]?a[""+ue].zIndex:null)!==e.changedNodeZIndexes[""+ue]){var De=$(a[""+ue]);P.push(De)}}),this.updateLayerZindexTable(o),L.nodes.splice(0,L.nodes.length),P.forEach(function(ue){var pe=$(ue);L.nodes.push(pe)}),"SVG"===this.diagram.mode){var _=c[c.length-1].id,B=c[c.length-1];B&&!("HTML"===B.shape.type||"Native"===B.shape.type)&&this.moveAfterSvgNode(s,_),this.updateNativeNodeIndex(_,s)}else this.diagram.refreshCanvasLayers();var j=[];Object.keys(this.changedNodeZIndexes).forEach(function(ue){if((a[""+ue]?a[""+ue].zIndex:null)!==e.changedNodeZIndexes[""+ue]){var De=$(e.diagram.nameTable[""+ue]);j.push(De)}});var Q=$(this.diagram.selectedItems);Q.nodes.splice(0,Q.nodes.length),j.forEach(function(ue){var pe=$(ue);Q.nodes.push(pe)}),this.diagram.diagramActions&ee.UndoRedo||this.addHistoryEntry({type:"SendForward",category:"Internal",undoObject:L,redoObject:Q}),this.diagram.endGroupAction()}}this.diagram.protectPropertyChange(!1)},n.prototype.updateZIndexBySendForward=function(t,e,i){var r=$(t);t.zIndex=Math.min.apply(Math,e);var a,s=Math.min.apply(Math,e),o=Math.min.apply(Math,e),l=this.diagram.layers[parseInt(i.toString(),10)].objects,h=this.diagram.nodes.filter(function(S){return-1!==l.indexOf(S.id)});t.children&&this.updateGroupZindex(t,"BringForward",t.zIndex);var c=h.filter(function(S){return S.zIndex===Math.min.apply(Math,e)&&S.id!==t.id});if(c&&c.length>0&&c[0].children){for(var d=Math.min.apply(Math,e),u=0;uo&&g!==t&&g.parentId!==t.id&&c&&c.length>0&&g.parentId!==c[0].id){var v=$(g);g.zIndex=a+1,a++,this.triggerOrderCommand(v,g,g)}var y=g.zIndex;this.changedNodeZIndexes[g.id]=(this.changedNodeZIndexes.hasOwnProperty(g.id),y)}},n.prototype.arrangeZIndexForLowerNodes=function(t,e,i){var r=i.filter(function(o){return o.zIndex<=t&&o.parentId!==e.id});r.sort(function(o,a){return a.zIndex-o.zIndex});for(var s=0;se&&(e=r.zIndex)}return e},n.prototype.sendBackward=function(t){var e=this;if(this.diagram.protectPropertyChange(!0),Xa(this.diagram)||t){$(t||(this.diagram.selectedItems.nodes.length?this.diagram.selectedItems.nodes[0]:this.diagram.selectedItems.connectors[0]));var s=t&&t.id,o=this.diagram.layers.indexOf(this.getObjectLayer(s=s||(this.diagram.selectedItems.nodes.length?this.diagram.selectedItems.nodes[0].id:this.diagram.selectedItems.connectors[0].id))),a=$(this.diagram.nameTable),h=(parseInt(o.toString(),10),this.diagram.nameTable[""+s]),c=[],d=this.diagram.spatialSearch.findObjects(h.wrapper.bounds);d.length>2&&(d=this.sortByZIndex(d));for(var u=0,p=d;uNumber(f.zIndex)&&""===f.parentId&&h.wrapper.bounds.intersects(f.wrapper.bounds)&&c.push(f);for(var f=c.length-1;f>=0;f--)(v=this.diagram.nameTable[c[parseInt(f.toString(),10)].id]).parentId===s&&c.splice(f,1);if(c.length>0){var v;if((v=this.diagram.nameTable[c[c.length-1].id]).parentId){var S=am(v,this.diagram,""),b=this.diagram.nameTable[""+S];s!==b.id&&(c[c.length-1]=b)}var M={};for(f=0;f0&&(Object.values(L).forEach(function(pe){pe<=N&&O.push(pe)}),0!==O.length&&this.updateZIndexBySendBackward(h,O,o))}var T=[];if(Object.keys(this.changedNodeZIndexes).forEach(function(pe){if((a[""+pe]?a[""+pe].zIndex:null)!==e.changedNodeZIndexes[""+pe]){var xe=$(a[""+pe]);T.push(xe)}}),this.updateLayerZindexTable(o),R.nodes.splice(0,R.nodes.length),T.forEach(function(pe){var Me=$(pe);R.nodes.push(Me)}),"SVG"===this.diagram.mode){var P=c[c.length-1].id,_=c[c.length-1];_&&"HTML"!==_.shape.type&&"Native"!==_.shape.type&&this.moveSvgNode(s,P);var B=this.diagram.nameTable[""+P];B.children&&B.children.length>0?this.updateNativeNodeIndex(s):this.updateNativeNodeIndex(s,P)}else this.diagram.refreshCanvasLayers();var j=[];Object.keys(this.changedNodeZIndexes).forEach(function(pe){if((a[""+pe]?a[""+pe].zIndex:null)!==e.changedNodeZIndexes[""+pe]){var xe=$(e.diagram.nameTable[""+pe]);j.push(xe)}});var Q=$(this.diagram.selectedItems);Q.nodes.splice(0,Q.nodes.length),j.forEach(function(pe){var Me=$(pe);Q.nodes.push(Me)}),this.diagram.diagramActions&ee.UndoRedo||this.addHistoryEntry({type:"SendBackward",category:"Internal",undoObject:R,redoObject:Q}),this.diagram.endGroupAction()}}this.diagram.protectPropertyChange(!1)},n.prototype.updateZIndexBySendBackward=function(t,e,i){var r=$(t);t.zIndex=Math.max.apply(Math,e);var p,s=t.zIndex,o=Math.max.apply(Math,e),a=this.diagram.layers[parseInt(i.toString(),10)].objects,l=this.diagram.nodes.filter(function(S){return-1!==a.indexOf(S.id)}),h=l.filter(function(S){return S.zIndex===Math.max.apply(Math,e)&&S.id!==t.id});if(h&&h.length>0&&h[0].children)for(var c=Math.max.apply(Math,e),d=0;d0&&g.parentId!==h[0].id){var v=$(g);g.zIndex=p-1,p--,this.triggerOrderCommand(v,g,g)}var y=g.zIndex;this.changedNodeZIndexes[""+g.id]=(this.changedNodeZIndexes.hasOwnProperty(g.id),y)}},n.prototype.findLowestChildZIndex=function(t){for(var e=t.zIndex,i=0;i0),this.selectObjects([t],!0))},n.prototype.clearSelection=function(t,e){return ET(this,void 0,void 0,function(){var i,r,s,o;return DT(this,function(a){return i=this.diagram.allowServerDataBinding,this.diagram.enableServerDataBinding(!1),Xa(this.diagram)&&(r=this.diagram.selectedItems,s=this.getSelectedObject(),this.diagram.currentSymbol&&(this.diagram.previousSelectedObject=s),o={oldValue:s,newValue:[],cause:this.diagram.diagramActions,state:"Changing",type:"Removal",cancel:!1},t&&(ce()||this.diagram.triggerEvent(Ce.selectionChange,o)),o.cancel||(r.offsetX=0,r.offsetY=0,r.width=0,r.height=0,r.rotateAngle=0,r.nodes=[],r.connectors=[],r.wrapper=null,r.annotation=void 0,r.selectedObjects=[],this.diagram.clearSelectorLayer(),t&&(o={oldValue:s,newValue:[],cause:this.diagram.diagramActions,state:"Changed",type:"Removal",cancel:!1},ce()||this.diagram.triggerEvent(Ce.selectionChange,o))),this.diagram.enableServerDataBinding(i)),[2]})})},n.prototype.clearSelectedItems=function(){this.clearSelection((this.diagram.selectedItems.nodes?this.diagram.selectedItems.nodes.length:0)+(this.diagram.selectedItems.connectors?this.diagram.selectedItems.connectors.length:0)>0)},n.prototype.removeStackHighlighter=function(){var t=zl(this.diagram.element.id),e=t.getElementById(t.id+"_stack_highlighter");e&&e.parentNode.removeChild(e)},n.prototype.renderStackHighlighter=function(t,e){var r,s,o,i=this.diagram.selectedItems.nodes[0];if(!e){var a=this.diagram.findObjectsUnderMouse(t.position);if((e=this.diagram.findObjectUnderMouse(a,"Drag",!0))&&!(e.isLane||e.isPhase||e.isHeader))for(var l=0;l0)for(var a=0;a1)if(i){var h=l.segments[0],c=l.segments[1],u=Tc(xI(t.wrapper,t.wrapper.corners,t.wrapper.bounds),h.direction),g=Nl({corners:void 0,point:u=Nh(l,0,u,{x:l.sourceWrapper.offsetX,y:l.sourceWrapper.offsetY},!1),margin:void 0,direction:h.direction},{corners:void 0,point:c.points[1],margin:void 0,direction:void 0});h.length=z.distancePoints(g[0],g[1]),c.direction&&c.length&&(c.length=z.distancePoints(g[1],g[2]))}else if(o){switch(l.segments[0].direction){case"Bottom":r=t.wrapper.bounds.bottomCenter.x-e.bottomCenter.x,s=t.wrapper.bounds.bottomCenter.y-e.bottomCenter.y;break;case"Top":r=t.wrapper.bounds.topCenter.x-e.topCenter.x,s=t.wrapper.bounds.topCenter.y-e.topCenter.y;break;case"Left":r=t.wrapper.bounds.middleLeft.x-e.middleLeft.x,s=t.wrapper.bounds.middleLeft.y-e.middleLeft.y;break;case"Right":r=t.wrapper.bounds.middleRight.x-e.middleRight.x,s=t.wrapper.bounds.middleRight.y-e.middleRight.y}this.dragSourceEnd(l,r,s,!0,null,"ConnectorSourceEnd",void 0,void 0,void 0,!(t.parentId&&this.diagram.diagramActions&ee.isGroupDragging))}}},n.prototype.updateEndPoint=function(t,e){var r={sourcePoint:t.sourcePoint,targetPoint:t.targetPoint};t.sourceID&&(r.sourceID=t.sourceID),t.targetID&&(r.targetID=t.targetID),t.sourcePortID&&(r.sourcePortID=t.sourcePortID),t.targetPortID&&(r.targetPortID=t.targetPortID),t.segments&&(r.segments=t.segments),this.diagram.connectorPropertyChange(t,e||{},r),this.diagram.updateSelector()},n.prototype.dragSourceEnd=function(t,e,i,r,s,o,a,l,h,c,d){var u=this.diagram.nameTable[t.id],p={},f=this.checkBoundaryConstraints(e,i,u.wrapper.bounds);if(OI(u)&&f&&"BezierSourceThumb"!==o&&Yv(this.diagram)&&(p=$(p={sourcePoint:u.sourcePoint}),u.sourcePoint.x+=e,u.sourcePoint.y+=i,"ConnectorSourceEnd"===o&&"Orthogonal"===u.type&&this.changeSegmentLength(u,l,h,c),"Bpmn"===u.shape.type&&"Default"===u.shape.sequence&&"Sequence"===u.shape.flow&&this.updatePathElementOffset(u)),"Bezier"===u.type)if(p={sourcePoint:u.sourcePoint},d)this.translateBezierPoints(t,""===o?"ConnectorSourceEnd":o,e,i,d,s,!a);else for(var g=0;g2){var d=z.direction((c=t.segments[2]).points[0],c.points[1]);o.direction===ls(d)?("Right"===o.direction?c.points[0].x=o.points[o.points.length-1].x=l.wrapper.corners.middleRight.x+20:"Left"===o.direction?c.points[0].x=o.points[o.points.length-1].x=l.wrapper.corners.middleLeft.x-20:c.points[0].y=o.points[o.points.length-1].y="Top"===o.direction?l.wrapper.corners.topCenter.y-20:l.wrapper.corners.bottomCenter.y+20,c.direction&&c.length&&(c.length=z.distancePoints(c.points[0],c.points[c.points.length-1])),o.length=z.distancePoints(o.points[0],o.points[o.points.length-1])):o.direction===d&&c.direction&&c.length?("Top"===o.direction||"Bottom"===o.direction?(c.points[0]=o.points[0],c.points[c.points.length-1].x=c.points[0].x):(c.points[0]=o.points[0],c.points[c.points.length-1].y=c.points[0].y),c.length=z.distancePoints(c.points[0],c.points[c.points.length-1]),t.segments.splice(0,2)):o.length=20}else o.length=20;else if(o.length<1)if(""!==t.sourceID){var c;"Right"===a.direction?a.points[a.points.length-1].y=(h=l.wrapper.corners.middleRight).y:"Left"===a.direction?a.points[a.points.length-1].y=(h=l.wrapper.corners.middleLeft).y:a.points[a.points.length-1].x="Top"===a.direction?(h=l.wrapper.corners.topCenter).x:(h=l.wrapper.corners.bottomCenter).x,a.length=z.distancePoints(h,a.points[a.points.length-1]),t.segments.length>2&&(c=t.segments[2]).direction&&c.length&&(c.length=z.distancePoints(a.points[a.points.length-1],c.points[c.points.length-1])),t.segments.splice(0,1)}else t.segments.splice(0,1)}else e&&!i&&t.sourceID!==e.id&&t.segments&&null!==t.segments[0].direction&&e&&e instanceof te&&s&&this.changeSourceEndToNode(t,e),e&&i&&t.sourcePortID!==i&&t.segments&&null!==t.segments[0].direction&&e&&e instanceof te&&s&&this.changeSourceEndToPort(t,e,i)},n.prototype.canConnect=function(t,e){return!(!da(e)||!kh(e))},n.prototype.changeSourceEndToPort=function(t,e,i){var r=this.diagram.getWrapper(e.wrapper,i),s={x:r.offsetX,y:r.offsetY},o=zo(s,En(e.wrapper),e.wrapper.bounds),a=t.segments[0],l=t.segments[1];if(a.direction!==o){var h=[],c={};if(a.direction===ls(o)){c={};var d=void 0;"Top"===o||"Bottom"===o?(d="Top"===o?{type:"Orthogonal",isTerminal:!0,direction:o,length:Math.abs(a.points[0].y-s.y)}:{type:"Orthogonal",isTerminal:!0,direction:o,length:Math.abs(s.y-a.points[0].y)},c=a.points[0].x>s.x?{type:"Orthogonal",isTerminal:!0,direction:"Right",length:a.points[0].x-s.x}:{type:"Orthogonal",isTerminal:!0,direction:"Left",length:s.x-a.points[0].x}):(d="Right"===o?{type:"Orthogonal",isTerminal:!0,direction:o,length:Math.abs(a.points[0].x-s.x)}:{type:"Orthogonal",isTerminal:!0,direction:o,length:Math.abs(s.x-a.points[0].x)},c=a.points[0].y>s.y?{type:"Orthogonal",direction:"Top",isTerminal:!0,length:a.points[0].y-s.y}:{type:"Orthogonal",direction:"Bottom",isTerminal:!0,length:s.y-a.points[0].y}),h.push(new bi(t,"segments",d,!0)),h.push(new bi(t,"segments",c,!0))}else h.push(new bi(t,"segments",c={type:"Orthogonal",direction:o,length:20,isTerminal:!0},!0));a.direction!==ls(o)&&("Top"===o||"Bottom"===o?(a.points[0].x=s.x,a.points[0].y=a.points[a.points.length-1].y="Top"===o?s.y-20:s.y+20):(a.points[0].y=s.y,a.points[0].x=a.points[a.points.length-1].x="Right"===o?s.x+20:s.x-20),a.length=z.distancePoints(a.points[0],a.points[a.points.length-1]),l.length=z.distancePoints(a.points[a.points.length-1],l.points[l.points.length-1])),t.segments=h.concat(t.segments)}else a.points[0]=s,"Top"===o||"Bottom"===o?a.points[a.points.length-1].x=s.x:a.points[a.points.length-1].y=s.y,a.length=z.distancePoints(a.points[0],a.points[a.points.length-1]),l.length=z.distancePoints(a.points[a.points.length-1],l.points[l.points.length-1])},n.prototype.removeTerminalSegment=function(t,e){for(var i=0;ii.width||"Left"===o.direction&&r.x>=o.points[0].x||"Right"===o.direction&&r.x<=o.points[0].x)o.points[0].y=o.points[o.points.length-1].y=r.y,o.points[0].x=r.x,o.length=z.distancePoints(o.points[0],o.points[o.points.length-1]),a.length=z.distancePoints(o.points[o.points.length-1],a.points[a.points.length-1]);else{var h=void 0;s="Bottom"===(h=a.direction?a.direction:z.direction(a.points[0],a.points[a.points.length-1]))?i.bottomCenter:i.topCenter,a.length&&a.direction&&(a.length="Top"===h?o.points[o.points.length-1].y-(s.y+20):s.y+20-o.points[o.points.length-1].y),o.length=o.points[o.points.length-1].x-s.x,o.direction=o.length>0?"Right":"Left",l.push(new bi(t,"segments",{type:"Orthogonal",direction:h,length:20},!0)),t.segments=l.concat(t.segments)}else r="Bottom"===o.direction?i.bottomCenter:i.topCenter,o.length>i.height||"Top"===o.direction&&r.y>=o.points[0].y||"Bottom"===o.direction&&r.y<=o.points[0].y?(o.points[0].x=o.points[o.points.length-1].x=r.x,o.points[0].y=r.y,o.length=z.distancePoints(o.points[0],o.points[o.points.length-1]),a.length=z.distancePoints(o.points[o.points.length-1],a.points[a.points.length-1])):(s="Left"===a.direction?i.middleLeft:i.middleRight,h=void 0,h=a.direction?a.direction:z.direction(a.points[0],a.points[a.points.length-1]),a.length&&a.direction&&(a.length="Left"===h?o.points[o.points.length-1].x-(s.x+20):s.x+20-o.points[o.points.length-1].x),o.length=o.points[o.points.length-1].y-s.y,o.direction=o.length>0?"Bottom":"Top",l.push(new bi(t,"segments",{type:"Orthogonal",direction:h,length:20},!0)),t.segments=l.concat(t.segments))},n.prototype.translateBezierPoints=function(t,e,i,r,s,o,a){var l=t.segments.indexOf(s),h=t.segments[parseInt(l.toString(),10)],c=l>0?t.segments[l-1]:null,d=null!==c?c.point:t.sourcePoint,u=l===t.segments.length-1?t.targetPoint:h.point;if(h)if("BezierSourceThumb"===e&&(h.vector1.angle||h.vector1.distance)){var p=h.vector1.distance,f=h.vector1.angle;h.vector1={distance:t.distance(d,o),angle:z.findAngle(d,o)},this.translateSubsequentSegment(t,s,!0,h.vector1.distance-p,h.vector1.angle-f)}else"BezierTargetThumb"===e&&(h.vector2.angle||h.vector2.distance)?(p=h.vector2.distance,f=h.vector2.angle,h.vector2={distance:t.distance(u,o),angle:z.findAngle(u,o)},this.translateSubsequentSegment(t,s,!1,h.vector2.distance-p,h.vector2.angle-f)):("ConnectorSourceEnd"===e&&!t.sourceID||"ConnectorTargetEnd"===e&&!t.targetID)&&a&&ZI(h.vector1)&&ZI(h.vector2)?(z.isEmptyPoint(h.point1)&&(h.bezierPoint1=JI(t.sourcePoint,t.targetPoint)),z.isEmptyPoint(h.point2)&&(h.bezierPoint2=JI(t.targetPoint,t.sourcePoint))):"BezierSourceThumb"===e||"ConnectorSourceEnd"===e&&!a&&ZI(h.vector1)?(h.bezierPoint1.x+=i,h.bezierPoint1.y+=r,(!z.isEmptyPoint(h.point1)||a)&&(h.point1={x:h.bezierPoint1.x,y:h.bezierPoint1.y})):("BezierTargetThumb"===e||"ConnectorTargetEnd"===e&&!a&&ZI(h.vector2))&&(h.bezierPoint2.x+=i,h.bezierPoint2.y+=r,(!z.isEmptyPoint(h.point2)||a)&&(h.point2={x:h.bezierPoint2.x,y:h.bezierPoint2.y}))},n.prototype.translateSubsequentSegment=function(t,e,i,r,s){var o=t.segments.indexOf(e);parseInt(o.toString(),10),t.bezierSettings.smoothness&MI.SymmetricAngle||(s=null),t.bezierSettings.smoothness&MI.SymmetricDistance||(r=null),(null!=r||null!=s)&&(i?0!==o&&this.updatePreviousBezierSegment(t,o,r,s):o!==t.segments.length-1&&this.updateNextBezierSegment(t,o,r,s))},n.prototype.updatePreviousBezierSegment=function(t,e,i,r){var s=t.segments[e-1],a=(s.vector2.angle+r)%360;a<0&&(a+=360),s.vector2={distance:s.vector2.distance+i,angle:a}},n.prototype.updateNextBezierSegment=function(t,e,i,r){var s=t.segments[e+1],a=(s.vector1.angle+r)%360;a<0&&(a+=360),s.vector1={distance:s.vector1.distance+i,angle:a}},n.prototype.dragTargetEnd=function(t,e,i,r,s,o,a,l){var c,h=this.diagram.nameTable[t.id],d=this.checkBoundaryConstraints(e,i,h.wrapper.bounds);if(kI(h)&&"BezierTargetThumb"!==o&&d&&Yv(this.diagram)){if(c=$(c={targetPoint:h.targetPoint}),h.targetPoint.x+=e,h.targetPoint.y+=i,"ConnectorTargetEnd"===o&&"Orthogonal"===h.type&&h.segments&&h.segments.length>0){var u=h.segments[h.segments.length-2];u&&2===h.segments[h.segments.length-1].points.length&&("Left"===u.direction||"Right"===u.direction?u.points[u.points.length-1].x=h.targetPoint.x:u.points[u.points.length-1].y=h.targetPoint.y,u.length=z.distancePoints(u.points[0],u.points[u.points.length-1]),u.direction=z.direction(u.points[0],u.points[u.points.length-1]))}"Bpmn"===h.shape.type&&"Default"===h.shape.sequence&&"Sequence"===h.shape.flow&&this.updatePathElementOffset(h)}if("Bezier"===h.type)if(c={targetPoint:h.targetPoint},l)this.translateBezierPoints(t,""===o?"ConnectorTargetEnd":o,e,i,l,s,!a);else for(var p=0;p0){if(void 0!==s&&o.segments[parseInt(s.toString(),10)])if("Bezier"===o.type){var a=o.segments[parseInt(s.toString(),10)],l=a.isInternalSegment;l&&null!==o.bezierSettings&&"FreeForm"!==o.bezierSettings.segmentEditOrientation?("Horizontal"===a.orientation?a.point.x+=e:a.point.y+=i,this.updateDirectionalBezierCurve(o)):(a.point.x+=e,a.point.y+=i),l&&(o.isBezierEditing=!0)}else o.segments[parseInt(s.toString(),10)].point.x+=e,o.segments[parseInt(s.toString(),10)].point.y+=i;else for(var h=0;h1){var a=e[1],l=e[2],h={x:.5*(a.x+l.x),y:.5*(a.y+l.y)},c=t.segments[0];c.vector1.angle=Gt(s,a),c.vector1.distance=.5*z.findLength(s,a),c.vector2.angle=Gt(h,a),c.vector2.distance=.5*z.findLength(h,a),c.point=h;var d=t.segments[1];if(d.vector1.angle=Gt(h,l),d.vector1.distance=.5*z.findLength(h,l),t.segments.length>2){var u=e[3],p={x:.5*(l.x+u.x),y:.5*(l.y+u.y)};d.vector2.angle=Gt(p,l),d.vector2.distance=.5*z.findLength(p,l),d.point=p;var f=t.segments[2];if(f.vector1.angle=Gt(p,u),f.vector1.distance=.5*z.findLength(p,u),t.segments.length>3){var g=e[4],v={x:.5*(u.x+g.x),y:.5*(u.y+g.y)};f.vector2.angle=Gt(v,u),f.vector2.distance=.5*z.findLength(v,u),f.point=v;var y=t.segments[3];y.vector1.angle=Gt(v,g),y.vector1.distance=.5*z.findLength(v,g),y.vector2.angle=Gt(o,g),y.vector2.distance=.5*z.findLength(o,g)}else f.vector2.angle=Gt(o,u),f.vector2.distance=.5*z.findLength(o,u)}else d.vector2.angle=Gt(o,l),d.vector2.distance=.5*z.findLength(o,l)}},n.prototype.rotateObjects=function(t,e,i,r,s){r=r||{};var o=Hi();qi(o,i,r.x,r.y);for(var l=0,h=e;l0){this.diagram.protectPropertyChange(!0);var o=t;o.segments=[],this.diagram.connectorPropertyChange(o,{},{segments:o.segments}),this.diagram.protectPropertyChange(!1)}}},n.prototype.updateInnerParentProperties=function(t){var r=this.diagram.isProtectedOnChange;this.diagram.protectPropertyChange(!0);for(var s=this.getAllDescendants(t,[],!1,!0),o=0;o0&&(p=this.diagram.bpmnModule.getChildrenBound(d,d.id,this.diagram),u=d.wrapper.bounds.containsRect(p)),h=d.wrapper.actualSize.width*t,c=d.wrapper.actualSize.height*e,void 0!==d.maxWidth&&0!==d.maxWidth&&(h=Math.min(d.maxWidth,h)),void 0!==d.minWidth&&0!==d.minWidth&&(h=Math.max(d.minWidth,h)),void 0!==d.maxHeight&&0!==d.maxHeight&&(c=Math.min(d.maxHeight,c)),void 0!==d.minHeight&&0!==d.minHeight&&(c=Math.max(d.minHeight,c)),u&&(h=Math.max(h,p.right-d.wrapper.bounds.x),c=Math.max(c,p.bottom-d.wrapper.bounds.y)),t=h/d.actualSize.width,e=c/d.actualSize.height}var f=Hi();o||(o=r);var g=o.wrapper;if(qi(f,-g.rotateAngle,i.x,i.y),Gp(f,t,e,i.x,i.y),qi(f,g.rotateAngle,i.x,i.y),r instanceof te){var d,v=Je(f,{x:(d=r).wrapper.offsetX,y:d.wrapper.offsetY}),y=d.wrapper.offsetX-d.wrapper.actualSize.width*d.pivot.x,S=d.wrapper.offsetY-d.wrapper.actualSize.height*d.pivot.y;if(h>0)if(d.processId){var b=this.diagram.nameTable[d.processId];(!b.maxWidth||d.margin.left+h0)if(d.processId){var M=this.diagram.nameTable[d.processId];(!M.maxHeight||d.margin.top+c0){if(e.dragLimit=e.dragLimit?e.dragLimit:{},e.dragLimit.top||e.dragLimit.bottom||e.dragLimit.left||e.dragLimit.right){var b={minDistance:null};S=this.getRelativeOffset(v,d,b);var M={minDistance:null};g=this.getRelativeOffset(v,y,M),S=null!=b&&M.minDistance0){if(S=y[y.length-1]){var b=void 0;for(b=0;b=e.x-t.dragLimit.left-r.width/2&&i.x<=e.x+t.dragLimit.right+r.width/2&&(s=!0),i.y>=e.y-t.dragLimit.top-r.height/2&&i.y<=e.y+t.dragLimit.bottom+r.height/2&&(o=!0),{x:s,y:o}},n.prototype.updateLabelMargin=function(t,e,i,r,s,o,a){if(i=i||{x:e.offset,y:0},e&&i&&i.x>0&&i.x<1){var l=z.getLengthFromListOfPoints(t.intermediatePoints),h=this.getPointAtLength(l*i.x,t.intermediatePoints,0),c=this.diagram.scrollSettings.currentZoom,d=e.dragLimit?e.dragLimit:{left:0,right:0,top:0,bottom:0};if(d.top||d.bottom||d.left||d.right){this.diagram.getWrapper(t.wrapper,e.id);var p=new Ne(0,0,0,0),f=this.diagram.getWrapper(t.wrapper,e.id);p.x=f.offsetX/c+o,p.y=f.offsetY/c+a,p.width=f.bounds.width/c,p.height=f.bounds.height/c;var g=new Ne(h.x-(d.left||0)-p.width/2,h.y-(d.top||0)-p.height/2,(d.left||0)+(d.right||0)+p.width,(d.top||0)+(d.bottom||0)+p.height);if(g.containsPoint(r));else for(var S=0,b=this.boundsInterSects([h,r],g,!1);S=t){c=t-r,d=z.findAngle(s,a),u=c*Math.cos(d*Math.PI/180),p=c*Math.sin(d*Math.PI/180),o={x:s.x+u,y:s.y+p};break}r+=h,s=a}else s=a;return o},n.prototype.getInterceptWithSegment=function(t,e){for(var o,a,i=[],r=[],s=[],l=z.findLength({x:0,y:0},{x:this.diagram.scroller.viewPortWidth,y:this.diagram.scroller.viewPortHeight}),h=1;h0&&a<=90||a>180&&a<=270?90:-90;r.push(z.transform(t,a+c,l)),r.push(z.transform(t,o+c,l));var p=im({x1:s[0].x,y1:s[0].y,x2:s[1].x,y2:s[1].y},{x1:r[0].x,y1:r[0].y,x2:r[1].x,y2:r[1].y});p.enabled&&i.push(p.intersectPt)}return i},n.prototype.getAnnotationChanges=function(t,e){var r={};return r[ob(t,e.id,!0)]={width:e.width,height:e.height,offset:t instanceof te?{x:e.offset.x,y:e.offset.y}:e.offset,rotateAngle:e.rotateAngle,margin:{left:e.margin.left,right:e.margin.right,top:e.margin.top,bottom:e.margin.bottom},horizontalAlignment:e.horizontalAlignment,verticalAlignment:e.verticalAlignment,alignment:t instanceof de?e.alignment:void 0},{annotations:r}},n.prototype.getConnectorPortChanges=function(t,e){var i=function Wse(n,t,e){for(var i=n.ports,r=0;r1&&(v.width=g,v.offset.x=1/S),f>1&&(v.height=f,v.offset.y=1/b)}}e instanceof Nr&&(e.alignment="Center"),l=this.getAnnotationChanges(t,e),t instanceof te?this.diagram.nodePropertyChange(t,a,l):this.diagram.connectorPropertyChange(t,a,l),this.diagram.updateDiagramObject(t)},n.prototype.getSubProcess=function(t){var i,e={nodes:[],connectors:[]};return t instanceof te?i=t.processId:t&&t.nodes&&t.nodes.length&&t.nodes[0].processId&&(i=t.nodes[0].processId),i&&e.nodes.push($(this.diagram.nameTable[i])),e},n.prototype.checkBoundaryConstraints=function(t,e,i,r){var s=this.diagram.pageSettings,o=this.diagram.pageSettings.boundaryConstraints,a=this.diagram.scroller;if("Page"===o||"Diagram"===o){var l=i?void 0:this.diagram.selectedItems.wrapper.bounds;return!!((i?i.right:l.right)+(t||0)<=("Page"===o?s.width:a.viewPortWidth)&&(i?i.left:l.left)+(t||0)>=0&&(i?i.bottom:l.bottom)+(e||0)<=("Page"===o?s.height:a.viewPortHeight)&&(i?i.top:l.top)+(e||0)>=0||"None"!==this.diagram.layout.type&&r)}return!0},n.prototype.dragSelectedObjects=function(t,e){var i=this,r=this.diagram.selectedItems;this.state&&!this.state.backup&&(this.state.backup={},this.state.backup.offsetX=r.offsetX,this.state.backup.offsetY=r.offsetY),r=QI(this.diagram,r)||r;var s=this.diagram.selectedItems.nodes.filter(function(c){return"SwimLane"===c.shape.type});if(s.length>0&&!this.diagram.currentSymbol&&this.diagram.selectedItems.nodes.length>1){var o=this.diagram.selectedItems.nodes.filter(function(c){return""===c.parentId||"SwimLane"!==i.diagram.nameTable[c.parentId].shape.type});if(o.length>0){for(var a=0;a0||l.length>1)&&(o=o.concat(l),this.diagram.selectedItems.nodes.splice(0,this.diagram.selectedItems.nodes.length),o.forEach(function(c){i.diagram.selectedItems.nodes.push(c)}),r=this.diagram.selectedItems,this.diagram.selectedObject.helperObject=void 0)}}if(this.checkBoundaryConstraints(t,e)){this.diagram.diagramActions=this.diagram.diagramActions|ee.PreventZIndexOnDragging|ee.DragUsingMouse;var h=this.diagram.selectedObject.actualObject;return(h&&h instanceof te&&h.isLane&&Qx(h,this.diagram)||!h||!h.isLane)&&this.diagram.drag(r,t,e),this.diagram.diagramActions=this.diagram.diagramActions&~(ee.PreventZIndexOnDragging|ee.DragUsingMouse),this.diagram.refreshCanvasLayers(),this.checkHtmlObjectDrag(r),!0}return!1},n.prototype.checkHtmlObjectDrag=function(t){var e=!1;this.diagram.views&&this.diagram.views.length>1&&(t instanceof si?e=t.nodes.some(function(i){return i.shape&&"HTML"===i.shape.type}):t.shape&&"HTML"===t.shape.type&&(e=!0),e&&this.resetOverviewCanvas())},n.prototype.resetOverviewCanvas=function(){for(var t=0,e=this.diagram.views;t0&&(this.layoutAnimateModule.stopCurrentAnimation(this.objectStore[0],e,t),this.objectStore=[]),a=this.diagram.doLayout(),this.objectStore.push(a)),this.canUpdateTemplate=!1,this.diagram.blazorActions&=~on.expandNode,this.diagram.preventNodesUpdate=r,this.diagram.layoutAnimateModule&&this.diagram.organizationalChartModule&&!i)this.diagram.allowServerDataBinding=!1,this.layoutAnimateModule.expand(this.diagram.layout.enableAnimation,a,t,this.diagram);else{var l={element:$(t),state:!!t.isExpanded};this.triggerEvent(Ce.expandStateChange,l),this.diagram.lineRoutingModule&&this.diagram.constraints&rt.LineRouting&&"ComplexHierarchicalTree"!==this.diagram.layout.type&&this.diagram.resetSegments()}return this.diagram.layout.fixedNode=""===o?"":this.diagram.layout.fixedNode,a},n.prototype.getparentexpand=function(t,e,i,r){for(var s,o=0;o0&&(this.diagram.selectedItems.wrapper.rotateAngle=this.diagram.selectedItems.rotateAngle=s.rotateAngle),r instanceof te&&"SwimLane"!==r.shape.type&&!r.isLane&&!r.isPhase&&!r.isHeader)(r.offsetX!==r.wrapper.offsetX||r.offsetY!==r.wrapper.offsetY||r.width!==r.wrapper.width||r.height!==r.wrapper.height||r.rotateAngle!==r.wrapper.rotateAngle)&&(r.offsetX+=o,r.offsetY+=a,r.width+=l,r.height+=h,r.rotateAngle+=c,this.diagram.nodePropertyChange(r,{},{offsetX:r.offsetX,offsetY:r.offsetY,width:r.width,height:r.height,rotateAngle:r.rotateAngle})),e=this.diagram.spatialSearch.findObjects(r.wrapper.outerBounds);else if(r instanceof si)for(var d=0;d30||g.wrapper.outerBounds.topCenter.y-f.wrapper.outerBounds.bottomCenter.y>30)&&this.diagram.lineRoutingModule.refreshConnectorSegments(this.diagram,p,!0)}}this.updateSelector(),this.diagram.protectPropertyChange(!1)}},n.prototype.drawSelectionRectangle=function(t,e,i,r){this.diagram.drawSelectionRectangle(t,e,i,r)},n.prototype.startGroupAction=function(){this.diagram.startGroupAction()},n.prototype.endGroupAction=function(){this.diagram.endGroupAction()},n.prototype.removeChildFromBPmn=function(t,e,i){var r=this.diagram.nameTable[t.id]||t.nodes[0];if(i&&r&&r.processId&&r.processId===i.wrapper.id){var s=$(r);s.processId=r.processId,this.diagram.startGroupAction();var o=this.diagram.nameTable[r.processId].shape.activity.subProcess.processes||[];o.splice(o.indexOf(r.id),1),this.diagram.bpmnModule.removeChildFromBPMN(this.diagram.nameTable[r.processId].wrapper,r.id,this.diagram),this.diagram.nameTable[r.id].processId="",r.offsetX=r.wrapper.offsetX,r.offsetY=r.wrapper.offsetY;var a=$(r);this.addHistoryEntry({type:"PositionChanged",redoObject:{nodes:[a]},undoObject:{nodes:[s]},category:"Internal"}),this.diagram.endGroupAction()}},n.prototype.isDroppable=function(t,e){var i=this.diagram.nameTable[t.id]||t.nodes[0];return i instanceof te&&(!ce()&&"TextAnnotation"===i.shape.shape||("Group"===e.shape.shape&&(e.shape.activity.subProcess.collapsed=!1),!(i&&"Bpmn"===i.shape.type&&(i.processId===e.id||i.id===e.processId||"Bpmn"===e.shape.type&&!(e instanceof de)&&e.shape.activity&&e.shape.activity.subProcess&&e.shape.activity.subProcess.collapsed))))},n.prototype.renderHighlighter=function(t,e,i){if(new Ne,t.target instanceof te||t.target instanceof de||e&&(t.source instanceof te||t.source instanceof de)){var a=this.findTarget(e?t.sourceWrapper:t.targetWrapper,e?t.source:t.target,i,!0),l=void 0;if(a instanceof Hd)for(var h=a.id,c=t.target,u=0,p=c.wrapper.children[0].children[0].children[2].children;u0){var r=0;t[0]=this.diagram.nameTable[t[0].id]||t[0];var s="Object"===i?yr(t[0].wrapper):this.diagram.selectedItems.wrapper.bounds,o={nodes:[],connectors:[]},a={nodes:[],connectors:[]};for(r="Object"===i?r+1:r;r0){var i=0,r=0,s=0,o=0,a=0,l=0,h=0,c=0,d={nodes:[],connectors:[]},u={nodes:[],connectors:[]};for(i=0;io.center.y&&(r=n[parseInt(e.toString(),10)],n[parseInt(e.toString(),10)]=n[parseInt(i.toString(),10)],n[parseInt(i.toString(),10)]=r):s.center.x>o.center.x&&(r=n[parseInt(e.toString(),10)],n[parseInt(e.toString(),10)]=n[parseInt(i.toString(),10)],n[parseInt(i.toString(),10)]=r)}}return n}(t,e),i=1;i0){var i=0,r={x:.5,y:.5};t[0]=this.diagram.nameTable[t[0].id]||t[0];var s=yr(t[0].wrapper),o={nodes:[],connectors:[]},a={nodes:[],connectors:[]};for(i=1;ii.zIndex){for(var s=this.diagram.layers.indexOf(this.diagram.getActiveLayer()),o=this.diagram.layers[parseInt(s.toString(),10)].zIndexTable,a=JSON.parse(JSON.stringify(o)),l=i.zIndex,h=r.zIndex,c=h;c>=l;c--)l!==c?o[c-1]?(o[parseInt(c.toString(),10)]=o[c-1],this.diagram.nameTable[o[parseInt(c.toString(),10)]].zIndex=c):(o[c-1]=o[parseInt(c.toString(),10)],this.diagram.nameTable[o[c-1]].zIndex=c,delete o[parseInt(c.toString(),10)]):this.swapZIndexObjects(h,o,r.id,a);"SVG"===this.diagram.mode?(this.moveSvgNode(e.parentId,i.id),this.updateNativeNodeIndex(e.parentId,i.id)):this.diagram.refreshCanvasLayers()}},n.prototype.findLeastIndexConnector=function(t,e,i){for(var r=0;rs.zIndex&&(i=s)}return i},n.prototype.findLeastIndexObject=function(t,e){var i=t;return t instanceof te&&(i=this.findLeastIndexConnector(t.inEdges,e,i),i=this.findLeastIndexConnector(t.outEdges,e,i)),i},n.prototype.checkSelection=function(t,e){var i;if(1===t.nodes.length&&0===t.connectors.length)if(cs(this.diagram,t.nodes[0],!0)){var r=t.nodes[0];if("SwimLane"===(i="SwimLane"===t.nodes[0].shape?t.nodes[0]:this.diagram.nameTable[t.nodes[0].parentId]).shape.type){var s="Horizontal"===i.shape.orientation;(r.isPhase&&(s&&"ResizeSouth"===e||!s&&"ResizeEast"===e)||r.isLane&&(s&&"ResizeEast"===e||!s&&"ResizeSouth"===e))&&W3(this.diagram,i,e)}else if("Grid"===i.container.type)if("Horizontal"===i.container.orientation&&1===r.rowIndex||"Vertical"===i.container.orientation&&r.rowIndex>0&&r.columnIndex>0){if("ResizeSouth"===e)for(var o=0;o1&&(this.diagram.realActions=this.diagram.realActions|$i.hScrollbarMoved,this.scrolled=!0),this.diagram.scrollSettings.horizontalOffset=t},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"verticalOffset",{get:function(){return this.vOffset},set:function(t){this.vOffset=t,Math.abs(this.vOffset-this.diagram.scrollSettings.verticalOffset)>1&&(this.diagram.realActions=this.diagram.realActions|$i.vScrollbarMoved,this.scrolled=!0),this.diagram.scrollSettings.verticalOffset=t},enumerable:!0,configurable:!0}),n.prototype.getBounds=function(){var e=this.diagram.spatialSearch.getPageBounds(0,0);return(e.x<0||e.y<0)&&!this.diagram.pageSettings.multiplePage?this.getPageBounds(void 0,void 0,!0,!0):this.getPageBounds(void 0,void 0,!0)},n.prototype.updateScrollOffsets=function(t,e){var i,r,s=this.getBounds();s.x*=this.currentZoom,s.y*=this.currentZoom,s.width*=this.currentZoom,s.height*=this.currentZoom,i=Math.max(0,t-s.left),r=Math.max(0,e-s.top),void 0!==t&&void 0!==e?(this.horizontalOffset=i,this.verticalOffset=r,this.diagram.setOffset(i,r)):this.diagram.setOffset(-this.horizontalOffset-s.x,-this.verticalOffset-s.y),this.transform={tx:Math.max(this.horizontalOffset,-s.left)/this.currentZoom,ty:Math.max(this.verticalOffset,-s.top)/this.currentZoom,scale:this.currentZoom}},n.prototype.setScrollOffset=function(t,e){this.scrolled=!1;var i=this.getBounds();i.x*=this.currentZoom,i.y*=this.currentZoom,i.width*=this.currentZoom,i.height*=this.currentZoom;var r=-i.left,s=-i.top,o=!1,a=this.viewPortWidth*this.currentZoom,l=this.viewPortHeight*this.currentZoom,h=r-t;if(h!==this.horizontalOffset){rh?this.horizontalOffset-=t:this.horizontalOffset=h,o=!0);var c=Math.max(i.right+this.vScrollSize,a);if(!o&&c<-h+this.viewPortWidth){var d=-h+a-this.vScrollSize,u=-this.horizontalOffset+a-this.vScrollSize;this.horizontalOffset=dd-u?h:-(i.right+this.vScrollSize-a),o=!0}o||(this.horizontalOffset=r-t)}o=!1;var p=s-e;if(p!==this.verticalOffset){sp?this.verticalOffset-=e:this.verticalOffset=p,o=!0);var f=Math.max(i.bottom+this.hScrollSize,l);if(!o&&f<-p+l){var g=-p+l-this.hScrollSize,v=-this.verticalOffset+l-this.hScrollSize;this.verticalOffset=gg-v?p:-(i.bottom+this.hScrollSize-l),o=!0}o||(this.verticalOffset=s-e)}this.transform={tx:Math.max(this.horizontalOffset,-i.left)/this.currentZoom,ty:Math.max(this.verticalOffset,-i.top)/this.currentZoom,scale:this.currentZoom},this.setSize()},n.prototype.getObjects=function(t,e){for(var i=[],r=0;r0){for(var l=0;l0){h.push(i[parseInt(o.toString(),10)].id);for(var d=0;d=e.bottom&&(l=0),-this.horizontalOffset<=e.x&&-this.horizontalOffset+this.viewPortWidth>=e.right&&(a=0),this.hScrollSize=a,this.vScrollSize=l;var h=this.diagramWidth,c=this.diagramHeight;this.diagramWidth=Math.max(e.right,-this.horizontalOffset+this.viewPortWidth-l)-i,this.diagramHeight=Math.max(e.bottom,-this.verticalOffset+this.viewPortHeight-a)-r,(h!==this.diagramWidth||c!==this.diagramHeight)&&"Diagram"!==this.diagram.scrollSettings.scrollLimit&&this.diagram.setSize(this.diagramWidth,this.diagramHeight),"Diagram"===this.diagram.scrollSettings.scrollLimit&&(h===this.diagramWidth&&c===this.diagramHeight&&1===this.currentZoom||this.diagram.diagramActions&&t&&(!this.diagram.diagramActions||!t||0===this.verticalOffset&&this.verticalOffset!==t.y||0===this.horizontalOffset&&this.horizontalOffset!==t.x)?t&&h===this.diagramWidth&&c===this.diagramHeight&&(this.diagram.diagramCanvas.scrollHeight>this.viewPortHeight&&t.y<0&&this.horizontalOffset===t.x&&0===this.verticalOffset||this.diagram.diagramCanvas.scrollWidth>this.viewPortWidth&&t.x<0&&this.verticalOffset===t.y&&0===this.horizontalOffset)&&(this.verticalOffset=t.y,this.horizontalOffset=t.x,this.transform={tx:Math.max(t.x,-e.left)/this.currentZoom,ty:Math.max(t.y,-e.top)/this.currentZoom,scale:this.currentZoom}):(this.diagram.scrollActions&ca.Interaction&&t&&(this.transform={tx:Math.max(t.x,-e.left/this.currentZoom)/this.currentZoom,ty:Math.max(t.y,-e.top/this.currentZoom)/this.currentZoom,scale:this.currentZoom},this.horizontalOffset=t.x,this.verticalOffset=t.y),this.diagram.setSize(this.diagramWidth,this.diagramHeight),!(this.diagram.scrollActions&ca.PropertyChange)&&t&&(this.horizontalOffset=t.x,this.verticalOffset=t.y,this.transform={tx:Math.max(t.x,-e.left)/this.currentZoom,ty:Math.max(t.y,-e.top)/this.currentZoom,scale:this.currentZoom}))),this.diagram.transformLayers(),this.diagram.element.style.overflow="hidden"},n.prototype.setViewPortSize=function(t,e){this.viewPortWidth=t,this.viewPortHeight=e},n.prototype.getPageBounds=function(t,e,i,r){var o,s=new Ne;if("Content"===e||r||null===this.diagram.pageSettings.width||null===this.diagram.pageSettings.height){var u=t?void 0:0;o=this.diagram.spatialSearch.getPageBounds(u,u)}else{var a=this.diagram.pageSettings.width,l=this.diagram.pageSettings.height,h=0,c=0;if(this.diagram.pageSettings.multiplePage){if((s=this.diagram.spatialSearch.getPageBounds(0,0)).right>a&&(a*=d=Math.ceil(s.right/a)),s.bottom>l&&(l*=d=Math.ceil(s.bottom/l)),s.left<0&&Math.abs(s.left)>h){var d=Math.ceil(Math.abs(s.left)/this.diagram.pageSettings.width);h=this.diagram.pageSettings.width*d}s.top<0&&Math.abs(s.top)>c&&(d=Math.ceil(Math.abs(s.top)/this.diagram.pageSettings.height),c=this.diagram.pageSettings.height*d)}o=new Ne(-h,-c,a+h,l+c)}if(i){var p=this.diagram.scrollSettings.padding;o.x-=p.left,o.y-=p.top,o.width+=p.left+p.right,o.height+=p.top+p.bottom}return o},n.prototype.getPageBreak=function(t){for(var e=0,i=0,r=-1,s=[],c=this.diagram.pageSettings.margin.left,d=this.diagram.pageSettings.margin.right,u=this.diagram.pageSettings.margin.top,p=this.diagram.pageSettings.margin.bottom,f=1,g=1;t.width>e;)(e+=this.diagram.pageSettings.width?this.diagram.pageSettings.width:t.width)===this.diagram.pageSettings.width&&(s[++r]={x1:t.left+c,y1:t.top+u,x2:t.left+c,y2:t.bottom-p}),ei;)(i+=this.diagram.pageSettings.height?this.diagram.pageSettings.height:t.height)===this.diagram.pageSettings.height&&(s[++r]={x1:t.left+c,y1:t.top+u,x2:t.right-d,y2:t.top+u}),i=this.diagram.scrollSettings.minZoom||l||t>=1)){this.currentZoom*=t;var c=this.getPageBounds(void 0,void 0,!0);c.x*=this.currentZoom,c.y*=this.currentZoom;var d=Hi();Gp(d,t,t,r.x,r.y),r3(d,e||0,i||0),bx(h,d);var u=Je(h,{x:0,y:0});if(1===t&&(u=this.applyScrollLimit(u.x,u.y,s,o,a)),a=-c.y>=u.y&&-c.x>=u.x&&a,(this.diagram.scrollActions&ca.PropertyChange||!(this.diagram.scrollActions&ca.Interaction)||"Diagram"!==this.diagram.scrollSettings.scrollLimit||a)&&(this.transform={tx:Math.max(u.x,-c.left)/this.currentZoom,ty:Math.max(u.y,-c.top)/this.currentZoom,scale:this.currentZoom},this.horizontalOffset=u.x,this.verticalOffset=u.y),this.setSize(u),"SVG"!==this.diagram.mode&&Ds(this.diagram)&&this.diagram.scroller.virtualizeElements(),"SVG"!==this.diagram.mode&&!Ds(this.diagram)&&this.diagram.refreshDiagramLayer(),this.diagram.setOffset(-this.horizontalOffset-c.x,-this.verticalOffset-c.y),KI(this.diagram),this.diagram.views&&this.diagram.views.overview){var p=this.diagram.views.overview,f=p.scrollOverviewRect(p.parent.scroller.horizontalOffset,p.parent.scroller.verticalOffset,p.parent.scroller.currentZoom,!0);p.updateOverviewrect(-f.x,-f.y,f.width,f.height),p.updateView(p)}}}},n.prototype.fitToPage=function(t){var e=(t=t||{}).mode,i=t.region,r=t.margin||{},s=t.canZoomIn,o=t.customBounds,a=t.canZoomOut;r.bottom=r.bottom||25,r.top=r.top||25,r.left=r.left||25,r.right=r.right||25;var h,l=o,c=-this.horizontalOffset,d=-this.verticalOffset;if("PageSettings"===(i=i||"PageSettings")&&this.diagram.pageSettings.width&&this.diagram.pageSettings.height||this.diagram.nodes.length>0||this.diagram.connectors.length>0){e=e||"Page","CustomBounds"!==i&&(l=this.getPageBounds(!0,i,!0));var u={x:0,y:0};r.left+r.right>this.viewPortWidth&&(this.viewPortWidth<=100?(r.left=5,r.right=5):(r.left=25,r.right=25)),r.top+r.bottom>this.viewPortHeight&&(this.viewPortHeight<=100?(r.top=5,r.bottom=5):(r.top=25,r.bottom=25)),u.x=(this.viewPortWidth-(r.left+r.right))/l.width,u.y=(this.viewPortHeight-(r.top+r.bottom))/l.height,!s&&l.width-this.horizontalOffset-a+this.viewPortWidth&&(i=o.right-this.viewPortWidth,i+=20),o.x<-a&&(i=o.x),o.bottom>-l+this.viewPortHeight&&(r=o.bottom-this.viewPortHeight,r+=20),o.y<-l&&(r=o.y),this.zoom(1,-this.horizontalOffset-i,-this.verticalOffset-r,null,void 0,e))},n.prototype.bringToCenter=function(t){var e=this.currentZoom,i=new Ne(t.x*e,t.y*e,t.width*e,t.height*e),r=i.x+i.width/2-this.viewPortWidth/2,s=i.y+i.height/2-this.viewPortHeight/2;this.zoom(1,-this.horizontalOffset-(r*=-1),-this.verticalOffset-(s*=-1),null)},n.prototype.applyScrollLimit=function(t,e,i,r,s){if("Infinity"===this.diagram.scrollSettings.scrollLimit&&void 0===i&&!r&&(t=-t,e=-e),"Infinity"!==this.diagram.scrollSettings.scrollLimit){var o=void 0;if("Limited"===this.diagram.scrollSettings.scrollLimit){var a=this.diagram.scrollSettings.scrollableArea;o=new Ne(a.x,a.y,a.width,a.height)}(o=o||(s?this.getPageBounds():this.getPageBounds(!0))).x*=this.currentZoom,o.y*=this.currentZoom,o.width*=this.currentZoom,o.height*=this.currentZoom,void 0!==i&&(t*=-1,e*=-1),r&&(t*=-1,e*=-1);var l=Math.max(o.right,this.viewPortWidth);if(!r&&!(t<=o.x&&(t+this.viewPortWidth>=o.right||t>=o.right-this.viewPortWidth)||t>=o.x&&t+this.viewPortWidth<=l))if(t>=o.x)t=Math.max(o.x,Math.min(t,t-(t+this.viewPortWidth-this.vScrollSize-l)));else{var h=o.right-this.viewPortWidth;t=Math.min(h,o.x)}var c=Math.max(o.bottom,this.viewPortHeight);r||e<=o.y&&e+this.viewPortHeight>=o.bottom||e>=o.y&&e+this.viewPortHeight<=c||(e>=o.y?e=Math.max(o.y,Math.min(e,e-(e+this.viewPortHeight-this.hScrollSize-c))):(h=o.bottom-this.viewPortHeight,e=Math.min(o.y,h))),t*=-1,e*=-1}return{x:t,y:e}},n}(),tae=function(){function n(t,e,i,r,s){this.objects=[],this.left=t,this.top=e,this.width=i,this.height=r,this.spatialSearch=s}return n.prototype.findQuads=function(t,e){null!=this.first&&this.first.isIntersect(t)&&this.first.findQuads(t,e),null!=this.second&&this.second.isIntersect(t)&&this.second.findQuads(t,e),null!=this.third&&this.third.isIntersect(t)&&this.third.findQuads(t,e),null!=this.fourth&&this.fourth.isIntersect(t)&&this.fourth.findQuads(t,e),this.objects.length>0&&e.push(this)},n.prototype.isIntersect=function(t){return!(this.left+this.widtht.right||this.top>t.bottom)},n.prototype.selectQuad=function(){for(var i,t=null,e=this;null!=e;)i=e.getQuad(t),e=i.source,t=i.target||t;return t},n.prototype.getQuad=function(t){var e=this.width/2,i=this.height/2;if(e>=1e3&&i>=1e3){var r=this.left+e,s=this.top+i;if(this.spatialSearch.childRight<=r){if(this.spatialSearch.childBottom<=s)return this.first||((o=new n(this.left,this.top,e,i,this.spatialSearch)).parent=this,this.first=o),{source:this.first};if(this.spatialSearch.childTop>=s)return this.third||((o=new n(this.left,s,e,i,this.spatialSearch)).parent=this,this.third=o),{source:this.third}}else if(this.spatialSearch.childLeft>=r){if(this.spatialSearch.childBottom<=s)return this.second||((o=new n(r,this.top,e,i,this.spatialSearch)).parent=this,this.second=o),{source:this.second};var o;if(this.spatialSearch.childTop>=s)return this.fourth||((o=new n(r,s,e,i,this.spatialSearch)).parent=this,this.fourth=o),{source:this.fourth}}}return this.objects.push(this.spatialSearch.childNode),{target:this}},n.prototype.isContained=function(){return this.spatialSearch.childLeft>=this.left&&this.spatialSearch.childRight<=this.left+this.width&&this.spatialSearch.childTop>=this.top&&this.spatialSearch.childBottom<=this.top+this.height},n.prototype.addIntoAQuad=function(t){var e={};this.spatialSearch.setCurrentNode(t);for(var i=null;!e.isAdded;)i=(e=this.spatialSearch.parentQuad.add(i)).quad;return i},n.prototype.add=function(t){if(t=null,this.isContained())return{isAdded:!0,quad:t=this.selectQuad()};var e=void 0,i=!(0!==this.objects.length||this.first||this.second||this.third||this.fourth),r=2*this.width,s=2*this.height;return this.spatialSearch.childLeft=this.childLeft?(this.pageLeft=this.childLeft,this.leftElement=t,r=!0):t===this.leftElement&&(this.pageLeft=Number.MAX_VALUE,this.findLeft(this.parentQuad),r=!0)),(this.pageTop!==this.childTop||t!==this.topElement)&&(this.pageTop>=this.childTop?(this.pageTop=this.childTop,this.topElement=t,r=!0):t===this.topElement&&(this.pageTop=Number.MAX_VALUE,this.findTop(this.parentQuad),r=!0)),(this.pageBottom!==this.childBottom||t!==this.bottomElement)&&(this.pageBottom<=this.childBottom?(r=!0,this.pageBottom=this.childBottom,this.bottomElement=t):t===this.bottomElement&&(this.pageBottom=-Number.MAX_VALUE,this.findBottom(this.parentQuad),r=!0)),(this.pageRight!==this.childRight||t!==this.rightElement)&&(this.pageRight<=this.childRight?(this.pageRight=this.childRight,this.rightElement=t,r=!0):t===this.rightElement&&(this.pageRight=-Number.MAX_VALUE,this.findRight(this.parentQuad),r=!0)),r}return this.setCurrentNode(null),!1},n.prototype.isWithinPageBounds=function(t){return t.left>=this.pageLeft&&t.right<=this.pageRight&&t.top>=this.pageTop&&t.bottom<=this.pageBottom},n.prototype.findQuads=function(t){var e=[];return this.parentQuad.findQuads(t,e),e},n.prototype.findObjects=function(t){for(var i=[],r=0,s=this.findQuads(t);r=r.outerBounds.left&&(this.pageLeft=r.outerBounds.left,this.leftElement=r)}},n.prototype.findTop=function(t){t.first||t.second?(t.first&&this.findTop(t.first),t.second&&this.findTop(t.second)):(t.third&&this.findTop(t.third),t.fourth&&this.findTop(t.fourth));for(var e=0,i=t.objects;e=r.outerBounds.top&&(this.pageTop=r.outerBounds.top,this.topElement=r)}},n.prototype.setCurrentNode=function(t){if(this.childNode=t,t){var e=t.outerBounds;this.childLeft=Number(e.left),this.childTop=Number(e.top),this.childRight=Number(e.right),this.childBottom=Number(e.bottom)}else this.childLeft=Number.MAX_VALUE,this.childTop=Number.MAX_VALUE,this.childRight=-Number.MAX_VALUE,this.childBottom=-Number.MAX_VALUE},n.prototype.getPageBounds=function(t,e){if(this.pageLeft===Number.MAX_VALUE)return new Ne(0,0,0,0);var i=void 0!==t?Math.min(this.pageLeft,0):this.pageLeft,r=void 0!==e?Math.min(this.pageTop,0):this.pageTop;return new Ne(Math.round(i),Math.round(r),Math.round(this.pageRight-i),Math.round(this.pageBottom-r))},n.prototype.getQuad=function(t){return this.quadTable[t.id]},n}(),iae=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),nae=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return iae(t,n),function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);r>3&&s&&Object.defineProperty(t,e,s)}([I(!1)],t.prototype,"preventDefaults",void 0),t}(Ee),sae=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),o_=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},oae=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return sae(t,n),o_([I("")],t.prototype,"action",void 0),o_([I("")],t.prototype,"cursor",void 0),t}(Ee),a_=function(){function n(){this.size=20,this.intermediatePoints=[],this.gridCollection=[],this.startArray=[],this.targetGridCollection=[],this.sourceGridCollection=[],this.considerWalkable=[]}return n.prototype.lineRouting=function(t){var e=t.connectors.length;if(this.renderVirtualRegion(t),e>0)for(var i=0;i=t.right||e.right<=t.left||e.top>=t.bottom||e.bottom<=t.top)},n.prototype.findEndPoint=function(t,e,i){var r,s;if(e&&""!==t.sourcePortID&&t.sourcePortWrapper||!e&&""!==t.targetPortID&&t.targetPortWrapper){s=zo(r=e?{x:t.sourcePortWrapper.offsetX,y:t.sourcePortWrapper.offsetY}:{x:t.targetPortWrapper.offsetX,y:t.targetPortWrapper.offsetY},void 0,e?t.sourceWrapper.bounds:t.targetWrapper.bounds);var o=e?t.sourcePortWrapper.bounds:t.targetPortWrapper.bounds;r=i?"Top"===s?{x:o.topCenter.x,y:o.topCenter.y}:"Left"===s?{x:o.middleLeft.x,y:o.middleLeft.y}:"Right"===s?{x:o.middleRight.x,y:o.middleRight.y}:{x:o.bottomCenter.x,y:o.bottomCenter.y}:{x:o.center.x,y:o.center.y}}else r=e&&this.startNode||!e&&this.targetNode?e?{x:this.startNode.wrapper.offsetX,y:this.startNode.wrapper.offsetY}:{x:this.targetNode.wrapper.offsetX,y:this.targetNode.wrapper.offsetY}:e?{x:t.sourcePoint.x,y:t.sourcePoint.y}:{x:t.targetPoint.x,y:t.targetPoint.y};return r},n.prototype.refreshConnectorSegments=function(t,e,i,r){var h,c,p,f,g,y,S,b,M,w,C,s=e.sourceID,o=e.targetID,a=e.sourcePortID,l=e.targetPortID;if(function Jre(n,t){var e=0;return n.constraints&qe.LineRouting?e=n.constraints&qe.LineRouting:n.constraints&qe.InheritLineRouting&&(e=t.constraints&rt.LineRouting),e}(e,t)||r){this.startNode=t.nameTable[""+s],this.targetNode=t.nameTable[""+o],this.intermediatePoints=[],this.startArray=[],this.targetGridCollection=[],this.sourceGridCollection=[],this.startGrid=void 0,this.targetGrid=void 0;for(var D=0;D0;){var L=this.startArray.pop();if(L){for(D=0;D1&&(e.segments=[]),this.updateConnectorSegments(t,this.intermediatePoints,this.gridCollection,e,i)){this.considerWalkable=[];break e}this.targetGridCollection.splice(this.targetGridCollection.indexOf(O),1),L=this.startArray.pop()}}L&&this.findPath(L)}}}},n.prototype.checkChildNodes=function(t,e){var i=!1,r=!1;if(t.nodeId.length>=1&&!e)for(var s=0;s1&&this.targetGridCollection[0].nodeId.length>1)for(var c=0;c<=1;c++){for(var d=this.targetGridCollection[parseInt(c.toString(),10)].gridX,u=this.targetGridCollection[parseInt(c.toString(),10)].gridY,p=this.targetGridCollection[parseInt(c.toString(),10)].nodeId,f=void 0,g=0;g=e.right&&t.top<=e.top&&t.bottom>=e.bottom},n.prototype.getEndvalue=function(t,e){return this.gridCollection[t.gridX][t.gridY].walkable?t:"left"===e?this.getEndvalue(this.gridCollection[t.gridX-1][t.gridY],e):"right"===e?this.getEndvalue(this.gridCollection[t.gridX+1][t.gridY],e):"top"===e?this.getEndvalue(this.gridCollection[t.gridX][t.gridY-1],e):"bottom"===e?this.getEndvalue(this.gridCollection[t.gridX][t.gridY+1],e):t},n.prototype.changeValue=function(t,e,i){t.walkable||this.considerWalkable.push(t);for(var r,s=0;s<=e;s++)"left"===i?r=this.gridCollection[t.gridX-s][t.gridY]:"right"===i?r=this.gridCollection[t.gridX+s][t.gridY]:"top"===i?r=this.gridCollection[t.gridX][t.gridY-s]:"bottom"===i&&(r=this.gridCollection[t.gridX][t.gridY+s]),r.walkable||this.considerWalkable.push(r)},n.prototype.getIntermediatePoints=function(t){var e;for(this.intermediatePoints=[];t;)this.intermediatePoints.push({x:t.gridX,y:t.gridY}),t=t.parent;this.intermediatePoints.reverse(),this.intermediatePoints.length>=1&&void 0!==this.intermediatePoints[0]&&void 0!==this.intermediatePoints[1]&&(this.intermediatePoints[0].x===this.intermediatePoints[1].x?this.intermediatePoints[0].y=1&&u.length>1&&(g=u[u.length-2].x!==u[u.length-1].x?u[u.length-2].x>u[u.length-1].x?"Left":"Right":u[u.length-2].y>u[u.length-1].y?"Top":"Bottom"),M>=2&&v===g&&u.length>1&&u.splice(u.length-2,1),v=g);if(u&&u.length>1){for(var w=0;wD.x?S.bounds.middleLeft:S.bounds.middleRight),w===u.length-2&&""===r.targetPortID&&y&&(l=C.x>D.x?y.bounds.middleRight:y.bounds.middleLeft),0===w&&b&&(C.x=b.x,C.y=D.y=b.y),w===u.length-2&&l&&(w>0&&r.targetDecorator&&l.x-D.x<0&&Math.abs(l.x-C.x)0&&r.targetDecorator&&l.x-D.x>0&&Math.abs(l.x-C.x)D.y?S.bounds.topCenter:S.bounds.bottomCenter),w===u.length-2&&""===r.targetPortID&&y&&(l=C.y>D.y?y.bounds.bottomCenter:y.bounds.topCenter),0===w&&b&&(C.y=b.y,C.x=D.x=b.x),w===u.length-2&&l&&(w>0&&r.targetDecorator&&l.y-D.y<0&&Math.abs(l.y-C.y)0&&r.targetDecorator&&l.y-D.y>0&&Math.abs(l.y-C.y)D.x?(p="Left",f=C.x-D.x):(p="Right",f=D.x-C.x):C.y>D.y?(p="Top",f=C.y-D.y):(p="Bottom",f=D.y-C.y),o.push({type:"Orthogonal",length:f,direction:p})}}if(o&&o.length>0){var A=o[o.length-1];if(1===o.length&&(A.length-=20),A.length<10&&2===o.length&&(o.pop(),o.length>0&&(o[0].length-=20,A=o[0])),r.targetDecorator&&("Top"===A.direction||"Bottom"===A.direction)&&A.length>r.targetDecorator.height+1||("Right"===A.direction||"Left"===A.direction)&&A.length>r.targetDecorator.width+1)return r.segments=o,s&&t.connectorPropertyChange(r,{},{type:"Orthogonal",segments:o}),!0}return!1},n.prototype.findPath=function(t){for(var e,i=[],r=this.findNearestNeigbours(t,this.gridCollection,!0),s=0;sl)&&(e.x!==t.gridX||e.y!==t.gridY)&&(i.push(e),o.previousDistance=l,o.afterDistance=o.afterDistance||this.manhattan(Math.abs(e.x-this.targetGrid.gridX),Math.abs(e.y-this.targetGrid.gridY)),o.totalDistance=o.previousDistance+o.afterDistance,o.parent=t)}if(i.length>0)for(s=0;st?i*t+e:i*e+t},n.prototype.manhattan=function(t,e){return t+e},n.prototype.findNearestNeigbours=function(t,e,i){var r=[],s=t.parent;if(s){var o=(t.gridX-s.gridX)/Math.max(Math.abs(t.gridX-s.gridX),1),a=(t.gridY-s.gridY)/Math.max(Math.abs(t.gridY-s.gridY),1);0!==o?(this.isWalkable(t.gridX,t.gridY-1,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX][t.gridY-1])&&r.push(e[t.gridX][t.gridY-1]),this.isWalkable(t.gridX,t.gridY+1,!0)&&this.sourceGridCollection.indexOf(e[t.gridX][t.gridY+1])&&r.push(e[t.gridX][t.gridY+1]),this.isWalkable(t.gridX+o,t.gridY,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX+o][t.gridY])&&r.push(e[t.gridX+o][t.gridY])):0!==a&&(this.isWalkable(t.gridX-1,t.gridY,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX-1][t.gridY])&&r.push(e[t.gridX-1][t.gridY]),this.isWalkable(t.gridX+1,t.gridY,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX+1][t.gridY])&&r.push(e[t.gridX+1][t.gridY]),this.isWalkable(t.gridX,t.gridY+a,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX][t.gridY+a])&&r.push(e[t.gridX][t.gridY+a]))}else this.neigbour(t,"top",r,i),this.neigbour(t,"right",r,i),this.neigbour(t,"bottom",r,i),this.neigbour(t,"left",r,i);return r},n.prototype.neigbour=function(t,e,i,r){for(var o,s=1;s>0;){var a="top"===e||"bottom"===e?t.gridX:"left"===e?t.gridX-s:t.gridX+s,l="right"===e||"left"===e?t.gridY:"top"===e?t.gridY-s:t.gridY+s;if((o=this.gridCollection[parseInt(a.toString(),10)][parseInt(l.toString(),10)])&&(r&&-1===this.sourceGridCollection.indexOf(o)||!r&&-1===this.targetGridCollection.indexOf(o)))return i&&this.isWalkable(a,l)&&i.push(o),s;if(!(a>0&&l>0))break;s++}return null},n.prototype.resetGridColl=function(t,e,i){for(var s,r=1;r>0;){var o="top"===e||"bottom"===e?t.gridX:"left"===e?t.gridX-r:t.gridX+r,a="right"===e||"left"===e?t.gridY:"top"===e?t.gridY-r:t.gridY+r;if((s=this.gridCollection[parseInt(o.toString(),10)][parseInt(a.toString(),10)])&&(i&&-1===this.sourceGridCollection.indexOf(s)||!i&&-1===this.targetGridCollection.indexOf(s))){if(this.isWalkable(o,a))break;var l=this.gridCollection[parseInt(o.toString(),10)][parseInt(a.toString(),10)];this.considerWalkable.push(l)}if(!(o>0&&a>0))break;"top"===e||"left"===e?r--:r++}return null},n.prototype.isWalkable=function(t,e,i){if(t>=0&&t=0&&e0?1:-1,this.isWalkable(h,c-1)&&!this.isWalkable(h-a,c-1)||this.isWalkable(h,c+1)&&!this.isWalkable(h-a,c+1)))return{x:t,y:e};if(0!==l){if(l=l>0?1:-1,this.isWalkable(h-1,c)&&!this.isWalkable(h-1,c-l)||this.isWalkable(h+1,c)&&!this.isWalkable(h+1,c-l))return{x:t,y:e};if(this.findIntermediatePoints(h+1,c,h,c,s,o)||this.findIntermediatePoints(h-1,c,h,c,s,o))return{x:t,y:e}}return this.findIntermediatePoints(h+a,c+l,h,c,s,o)},n.prototype.destroy=function(){},n.prototype.getModuleName=function(){return"LineRouting"},n}(),aae=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),hae=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return aae(t,n),function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);r>3&&s&&Object.defineProperty(t,e,s)}([I(!0)],t.prototype,"inversedAlignment",void 0),t}(Ee),cae=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Oe=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},xT=function(n,t,e,i){return new(e||(e=Promise))(function(r,s){function o(h){try{l(i.next(h))}catch(c){s(c)}}function a(h){try{l(i.throw(h))}catch(c){s(c)}}function l(h){h.done?r(h.value):new e(function(c){c(h.value)}).then(o,a)}l((i=i.apply(n,t||[])).next())})},TT=function(n,t){var i,r,s,o,e={label:0,sent:function(){if(1&s[0])throw s[1];return s[1]},trys:[],ops:[]};return o={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function a(h){return function(c){return function l(h){if(i)throw new TypeError("Generator is already executing.");for(;e;)try{if(i=1,r&&(s=2&h[0]?r.return:h[0]?r.throw||((s=r.return)&&s.call(r),0):r.next)&&!(s=s.call(r,h[1])).done)return s;switch(r=0,s&&(h=[2&h[0],s.value]),h[0]){case 0:case 1:s=h;break;case 4:return e.label++,{value:h[1],done:!1};case 5:e.label++,r=h[1],h=[0];continue;case 7:h=e.ops.pop(),e.trys.pop();continue;default:if(!(s=(s=e.trys).length>0&&s[s.length-1])&&(6===h[0]||2===h[0])){e=0;continue}if(3===h[0]&&(!s||h[1]>s[0]&&h[1]0&&((!s.style||!s.style.fill)&&(o.style.fill="transparent"),(!s.style||!s.style.strokeColor)&&(o.style.strokeColor="transparent")),s.shape&&"UmlActivity"===s.shape.type&&ib(s,o),s.shape&&"SwimLane"===s.shape.type&&pF(s,o),r.nodeDefaults&&Ro(o,s,r.nodeDefaults),r.updateAnnotationText(o.annotations);if(e&&e.connectors)for(a=0;e&&e.connectors&&a0&&0===i.nodes.length)this.clearCollection(),a=!0;else{for(var g=0,v=Object.keys(e.nodes);g0&&0===i.connectors.length)this.clearCollection(!0),a=!0;else{for(var C=0,D=Object.keys(e.connectors);C0){this.renderSelector(!0);break}if(e.selectedItems.constraints){this.renderSelector(!0);break}break;case"snapSettings":this.updateSnapSettings(e);break;case"commandManager":this.initCommands();break;case"layout":o=!0;break;case"segmentThumbShape":this.updateSelector();break;case"dataSourceSettings":this.clear(),"None"===this.layout.type?a=!0:(this.initObjects(),o=!0);break;case"tooltip":l3(this);break;case"rulerSettings":this.updateRulerSettings(e);break;case"layers":this.updateLayer(e);break;case"scrollSettings":this.scrollActions|=ca.PropertyChange,this.updateScrollSettings(e),this.scrollActions&=~ca.PropertyChange,this.scrollSettings.horizontalOffset=-this.scroller.horizontalOffset||0,this.scrollSettings.verticalOffset=-this.scroller.verticalOffset||0;break;case"locale":e.locale!==i.locale&&(this.realActions|=$i.PreventDataInit,n.prototype.refresh.call(this),this.realActions&=~$i.PreventDataInit);break;case"contextMenuSettings":if(void 0!==e.contextMenuSettings.showCustomMenuOnly&&(this.contextMenuSettings.showCustomMenuOnly=e.contextMenuSettings.showCustomMenuOnly),void 0!==e.contextMenuSettings.show&&(this.contextMenuSettings.show=e.contextMenuSettings.show),e.contextMenuSettings.items){for(var A=e.contextMenuSettings.items,x=0,R=Object.keys(A);x0){for(var N=[],T=O.ports.length-1;T>=0;T--)"LineDistribution"===O.ports[parseInt(T.toString(),10)].id.split("_")[1]&&N.push(O.ports[parseInt(T.toString(),10)]);this.removePorts(O,N)}}for(T=0;T0)for(var ue=0,pe=Object.keys(e.nodes);ue0)for(var De=0,xe=Object.keys(e.connectors);De=0;o--)this.commandHandler.expandNode(r[parseInt(o.toString(),10)],this,0!==o);this.canLayout&&this.doLayout(),this.lineRoutingModule?this.connectors.sourceID!==this.connectors.targetID&&this.lineRoutingModule.lineRouting(this):this.constraints&rt.LineRouting&&console.warn('[WARNING] :: Module "LineRouting" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),this.validatePageSize(),this.renderPageBreaks(),this.diagramRenderer.renderSvgGridlines(this.snapSettings,_d(this.element.id),this.scroller.transform,this.rulerSettings,this.hRuler,this.vRuler),this.commandHandler.initSelectorWrapper(),this.notify("initial-load",{}),this.trigger("load"),this.scroller.setSize(),this.scroller.updateScrollOffsets(),this.isRefreshed||this.refreshDiagramLayer(),(this.scrollSettings.verticalOffset>0||this.scrollSettings.horizontalOffset>0)&&this.updateScrollOffset(),X.isDevice&&(this.tool=Ci.ZoomPan|Ci.SingleSelect),this.notify("initial-end",{}),this.isProtectedOnChange=!1,this.tooltipObject=l3(this),this.diagramActions=ee.Render,this.initCommands();var a=document.getElementsByClassName(this.element.id+"_hiddenUserHandleTemplate");(function Noe(n,t,e,i){var r,s,o,a,l,d=document.getElementById(i).ej2_instances[0];if(n&&t){r=GF(n);for(var u=0,p=e.userHandles;u0;)e[0].parentNode.removeChild(e[0]);var i=document.getElementById(this.element.id+"content");i&&this.element.removeChild(i);var r="measureElement";if(window[""+r]){window[""+r].usageCount-=1;var s="measureElementCount";window[""+s]--,0===window[""+s]&&(window[""+r].parentNode.removeChild(window[""+r]),window[""+r]=null)}}window.domTable={};for(var a=0;a1&&(this.callBlazorModel=!1,this.insertBlazorDiagramObjects(this.selectedItems),this.commandHandler.group(),this.callBlazorModel=!0,this.commandHandler.getBlazorOldValues())},t.prototype.unGroup=function(){this.callBlazorModel=!1,this.insertBlazorDiagramObjects(this.selectedItems),this.commandHandler.unGroup(),this.callBlazorModel=!0,this.commandHandler.getBlazorOldValues()},t.prototype.sendToBack=function(){this.commandHandler.sendToBack()},t.prototype.setActiveLayer=function(e){var i=this.commandHandler.getLayer(e);this.activeLayer=i},t.prototype.addLayer=function(e,i){this.commandHandler.addLayer(e,i)},t.prototype.removeLayer=function(e){this.commandHandler.removeLayer(e,ce())},t.prototype.moveObjects=function(e,i){$(this.layers),this.enableServerDataBinding(!1),this.commandHandler.moveObjects(e,i)},t.prototype.layerObjectUpdate=function(){},t.prototype.sendLayerBackward=function(e){this.layerObjectUpdate(),this.commandHandler.sendLayerBackward(e)},t.prototype.bringLayerForward=function(e){this.layerObjectUpdate(),this.commandHandler.bringLayerForward(e)},t.prototype.cloneLayer=function(e){this.commandHandler.cloneLayer(e)},t.prototype.bringToFront=function(){this.commandHandler.bringToFront()},t.prototype.moveForward=function(){this.commandHandler.sendForward()},t.prototype.sendBackward=function(){this.commandHandler.sendBackward()},t.prototype.getObject=function(e){return this.nameTable[""+e]},t.prototype.getNodeObject=function(e){return $(this.nameTable[""+e])},t.prototype.getConnectorObject=function(e){return $(this.nameTable[""+e])},t.prototype.getActiveLayer=function(){return this.activeLayer},t.prototype.nudgeCommand=function(e,i,r){if("object"!=typeof e&&(this.selectedItems.nodes.length||this.selectedItems.connectors.length)>0){var s=void 0;i.type&&"KEYDOWN"===i.type&&(s=i.type),this.nudge(e,void 0,void 0,s)}},t.prototype.nudge=function(e,i,r,s){var o=0,a=0;"Left"===e||"Right"===e?o=("Left"===e?-1:1)*(i||1):a=("Up"===e?-1:1)*(r||1),"KEYDOWN"===s&&(o*=5,a*=5);var h=this.selectedItems,c=this.selectedItems.wrapper.children[0];if(c instanceof ni)this.commandHandler.labelDrag(h.nodes[0],c,o,a);else{var d=$(this.selectedItems);this.protectPropertyChange(!0),this.drag(h,o,a),this.protectPropertyChange(!1);var u={type:"PositionChanged",redoObject:$(this.selectedItems),undoObject:d,category:"Internal"};this.addHistoryEntry(u)}this.refreshCanvasLayers()},t.prototype.insertBlazorDiagramObjects=function(e){},t.prototype.drag=function(e,i,r){if(this.insertBlazorDiagramObjects(e),!(this.bpmnModule&&e instanceof te&&this.bpmnModule.updateAnnotationDrag(e,this,i,r))){if(e instanceof si){if(this.preventConnectorsUpdate=!0,e.nodes&&e.nodes.length){for(var o=0,a=e.nodes;o0&&o.nodes[0].children){this.fromUndo||(this.rotateUsingButton=!0);for(var h=this.commandHandler.getAllDescendants(o.nodes[0],[]),c=0;c0&&o.nodes[0].children){var g={type:"RotationChanged",redoObject:$(e),undoObject:$(o),category:"Internal",childTable:a};this.commandHandler.addHistoryEntry(g),this.commandHandler.updateSelector()}return u},t.prototype.dragSourceEnd=function(e,i,r){this.insertBlazorDiagramObjects(e),this.commandHandler.dragSourceEnd(e,i,r),this.callBlazorModel&&this.commandHandler.getBlazorOldValues()},t.prototype.dragTargetEnd=function(e,i,r){this.insertBlazorDiagramObjects(e),this.commandHandler.dragTargetEnd(e,i,r),this.callBlazorModel&&this.commandHandler.getBlazorOldValues()},t.prototype.findObjectsUnderMouse=function(e,i){return this.eventHandler.findObjectsUnderMouse(e,i)},t.prototype.findObjectUnderMouse=function(e,i,r){return this.eventHandler.findObjectUnderMouse(e,i,r)},t.prototype.findTargetObjectUnderMouse=function(e,i,r,s,o){return this.eventHandler.findTargetUnderMouse(e,i,r,s,o)},t.prototype.findElementUnderMouse=function(e,i,r,s){return this.eventHandler.findElementUnderMouse(e,i,r,s)},t.prototype.findActionToBeDone=function(e,i,r,s){return this.eventHandler.findActionToBeDone(e,i,r,s)},t.prototype.updateConnectorPort=function(e){if(e.ports.length)for(var i=void 0,r=0,s=e.ports;r=0;s--)if(i.push(r[parseInt(s.toString(),10)]),i.length>this.historyManager.stackLimit)return i}else i=r;return i},t.prototype.getEdges=function(e){return e.outEdge?this.nameTable[e.id].outEdges:this.nameTable[e.id].inEdges},t.prototype.getParentId=function(e){return this.nameTable[""+e].parentId},t.prototype.addConnector=function(e){return this.add(e)},t.prototype.UpdateBlazorDiagramModelCollection=function(e,i,r,s){},t.prototype.UpdateBlazorDiagramModel=function(e,i,r,s){},t.prototype.UpdateBlazorLabelOrPortObjects=function(e,i,r,s){},t.prototype.addBlazorDiagramObjects=function(){},t.prototype.removeNodeEdges=function(e,i,r){var s=this.nameTable[""+e],o=r?s.outEdges:s.inEdges;if(o.length>0)for(var a=0;a0)){for(var c=0;c0))}this.removePortEdges(l,a.element.sourcePortID,a.element.id,h)}a.element.targetID&&this.removeNodeEdges(a.element.targetID,a.element.id,!1)}}this.diagramActions=this.diagramActions|ee.PublicMethod,e.id=e.id||Qe();var u=this.activeLayer;if(!a.cancel&&u&&!u.lock){if(u.objects.indexOf(e.id)<0&&!u.lock&&(u.visible||(u.visible=!0,this.dataBind()),u.objects.push(e.id)),fs(e)===de)(r=new de(this,"connectors",e,!0)).status="New",this.nameTable[r.targetID]&&"TextAnnotation"===this.nameTable[r.targetID].shape.shape&&(r.isBpmnAnnotationConnector=!0,r.constraints=r.constraints&~qe.Delete),Ro(r,e,this.connectorDefaults),this.connectors.push(r),this.initObject(r),!1===e.visible&&this.updateElementVisibility(r.wrapper,r,e.visible),this.updateEdges(r),this.insertBlazorConnector(r);else{if(Ro(r=new te(this,"nodes",e,!0),e,this.nodeDefaults),r.parentId=e.parentId?e.parentId:r.parentId,r.umlIndex=e.umlIndex,r.status="New",(o="TextAnnotation"===r.shape.shape)&&!e.isTextAnnotationCopied&&(r.inEdges=e.inEdges?e.inEdges:r.inEdges),this.nodes.push(r),this.initObject(r,u,void 0,i),o&&this.bpmnModule)for(c=0;c-1&&e.parentId&&this.nameTable[e.parentId]&&"UmlClassifier"===this.nameTable[e.parentId].shape.type){var g=this.nameTable[e.parentId];g.children.splice(r.umlIndex,0,r.id),g.wrapper.children.splice(r.umlIndex,0,r.wrapper),g.wrapper.measure(new me),g.wrapper.arrange(g.wrapper.desiredSize),this.updateDiagramObject(g)}}if(a={element:r,cause:this.diagramActions,diagramAction:this.getDiagramAction(this.diagramActions),state:"Changed",type:"Addition",cancel:!1},this.parentObject&&(a.parentId=this.parentObject.id),"helper"!==e.id&&!(this.diagramActions&ee.PreventCollectionChangeOnDragOver)&&this.triggerEvent(Ce.collectionChange,a),!(this.diagramActions&ee.UndoRedo||this.diagramActions&ee.Group||this.diagramActions&ee.PreventHistory)){var v={type:"CollectionChanged",changeType:"Insert",undoObject:$(e),redoObject:$(e),category:"Internal"};this.addHistoryEntry(v)}this.parentObject=void 0,"SVG"===this.mode&&(this.updateSvgNodes(r),this.updateTextElementValue(r),this.updateDiagramObject(r),o&&this.updateDiagramObject(this.nameTable[r.inEdges[0]]),r.shape.activity&&r.shape.activity.subProcess.processes&&r.shape.activity.subProcess.processes.length&&this.updateProcesses(r),this.updateBridging())}}if(this.protectPropertyChange(s),this.resetDiagramActions(ee.PublicMethod),r&&this.layers.length>1&&this.moveNode(r),this.views)for(var S=0,b=this.views;S=0;l--)this.moveSvgNode(a[parseInt(l.toString(),10)])}for(var h=0,c=i;h=0;o--)r[parseInt(o.toString(),10)]===e.id&&r.splice(o,1);for(var a=0;s.ports&&a=0;s--)if(i=this.nameTable[r[parseInt(s.toString(),10)]])if(this.connectorTable[i.id]=$(i),i.isBpmnAnnotationConnector){var o=this.nameTable[i.targetID];this.removeObjectsFromLayer(i);var a=this.connectors.indexOf(i);-1!==a&&this.connectors.splice(a,1),this.removeElements(i),this.removeFromAQuad(i),delete this.nameTable[i.id];var l=this.nameTable[i.sourceID];if(l){var h=l.outEdges.indexOf(i.id);-1!==h&&l.outEdges.splice(h,1)}e.id!==i.targetID&&this.remove(o)}else this.remove(i)},t.prototype.removeObjectsFromLayer=function(e){if(e.children)for(var i=0;i-1&&(_r(this,e)&&this.unSelect(e),this.layers[parseInt(s.toString(),10)].objects.splice(a,1),delete this.layers[parseInt(s.toString(),10)].zIndexTable[this.nameTable[e.id].zIndex])},t.prototype.removeElements=function(e){if("SVG"===this.mode||"Canvas"===this.mode&&"Native"===e.shape.type){var i=xt(e.id+"_groupElement",this.element.id),r=e;if(r.ports&&r.ports.length>0)for(var s=0;s0){l[parseInt(s.toString(),10)].id.indexOf("icon_content")>0&&"SVG"===this.mode&&((h=xt(l[parseInt(s.toString(),10)].id+"_shape_groupElement",this.element.id))&&h.parentNode.removeChild(h),(h=xt(l[parseInt(s.toString(),10)].id+"_rect_groupElement",this.element.id))&&h.parentNode.removeChild(h));for(var c=0,d=this.views;c=0;o--)a.children[parseInt(o.toString(),10)].children&&(l=n.nameTable[a.children[parseInt(o.toString(),10)].id])&&(l.isLane?Zv(n,l):(n.removeDependentConnector(l),n.diagramActions|=ee.PreventHistory,l.constraints&ie.Delete?n.remove(l):q3(n,l,{},!1),n.diagramActions&=~ee.PreventHistory));a&&(i=n.nameTable[a.id])&&Zv(n,i)}}(this,e),!(this.diagramActions&ee.UndoRedo||this.diagramActions&ee.PreventHistory)&&(e instanceof te||e instanceof de)){var o={type:"CollectionChanged",changeType:"Remove",undoObject:$(e),redoObject:$(e),category:"Internal"};this.diagramActions&ee.Clear||e.children&&!e.isLane&&!e.isPhase&&e.children.length>0&&this.undoRedoModule&&"None"===this.layout.type&&(this.historyManager.startGroupAction(),s=!0),(e instanceof te||e instanceof de)&&this.deleteDependentConnector&&this.removeDependentConnector(e),!e.isLane&&!e.isPhase&&!(this.diagramActions&ee.Clear)&&!this.isStackChild(e)&&this.addHistoryEntry(o)}"TextAnnotation"===e.shape.shape&&this.removeDependentConnector(e),e.children&&!e.isLane&&!e.isPhase&&(!(this.diagramActions&ee.UndoRedo)||!ce())&&this.deleteGroup(e),e.parentId&&(this.deleteChild(e,void 0,!0),this.nameTable[e.parentId]&&"UmlClassifier"===this.nameTable[e.parentId].shape.type&&(this.updateDiagramObject(this.nameTable[e.parentId]),this.updateConnectorEdges(this.nameTable[e.parentId])));var a=void 0;this.diagramActions=this.diagramActions|ee.PublicMethod;var l=this.nameTable[e.id];if(l instanceof te?("Bpmn"===l.shape.type&&this.bpmnModule&&this.bpmnModule.removeBpmnProcesses(l,this),(l.isLane||l.isPhase||"SwimLane"===l.shape.type)&&(h=l.isLane||l.isPhase?this.nameTable[l.parentId]:this.nameTable[l.id],l.isLane?Q3(this,l,h):l.isPhase&&G3(this,l,h)),-1!==(a=this.nodes.indexOf(l))&&(this.crudDeleteNodes.push(this.nameTable[l.id]),this.nodes.splice(a,1),this.updateNodeEdges(l))):(-1!==(a=this.connectors.indexOf(l))&&(this.crudDeleteNodes.push(this.nameTable[l.id]),this.connectors.splice(a,1)),this.updateEdges(l),this.spliceConnectorEdges(e,!0),this.spliceConnectorEdges(e,!1)),!this.isServerUpdate&&!(this.blazorActions&on.GroupClipboardInProcess)&&this.commandHandler.getBlazorOldValues(),s&&this.historyManager.endGroupAction(),_r(this,l)&&this.unSelect(l),!l.isPhase){if(this.removeObjectsFromLayer(e),this.currentDrawingObject&&(this.currentDrawingObject.wrapper=void 0),delete this.nameTable[e.id],i.length>0&&i[0].id===l.id&&l.parentId){var h,d=this.nameTable[l.parentId];d&&d.isLane&&"SwimLane"===this.nameTable[d.parentId].shape.type&&Y3(this,h=this.nameTable[d.parentId],d,l)}this.removeElements(l),this.updateBridging(),"SVG"!==this.mode&&this.refreshDiagramLayer(),this.diagramActions&ee.Clear||(this.removeFromAQuad(l),r={element:e,cause:this.diagramActions,diagramAction:this.getDiagramAction(this.diagramActions),state:"Changed",type:"Removal",cancel:!1},"helper"!==e.id&&this.triggerEvent(Ce.collectionChange,r),this.resetTool())}}}else if(i.length>0){this.undoRedoModule&&(this.historyManager.startGroupAction(),this.blazorActions|=on.GroupingInProgress,s=!0);for(var u=0;u=f.wrapper.bounds.width&&"Horizontal"===f.shape.orientation||this.selectedItems.wrapper.bounds.y<=f.wrapper.bounds.y+g&&this.selectedItems.wrapper.bounds.height>=f.wrapper.bounds.height-g&&"Vertical"===f.shape.orientation)&&(NI(f)||f.shape.lanes.length>1)&&this.remove(i[parseInt(u.toString(),10)])}}else this.remove(i[parseInt(u.toString(),10)])}s&&(this.blazorActions&=~on.GroupingInProgress,this.isServerUpdate=!0,this.commandHandler.getBlazorOldValues(),this.UpdateBlazorDiagramModelCollection(void 0,void 0,void 0,!0),this.historyManager.endGroupAction(),this.isServerUpdate=!1),this.clearSelection()}e&&(NI(e)||this.diagramActions&ee.Clear)||this.diagramActions&ee.UndoRedo||this.diagramActions&ee.PreventHistory||!(e instanceof te||e instanceof de)||(o={type:"ConnectionChanged",undoObject:$(e),redoObject:$(e),category:"Internal"},!e.isLane&&!e.isPhase&&!(this.diagramActions&ee.Clear)&&!this.isStackChild(e)&&this.addHistoryEntry(o)),this.tooltipObject.close()},t.prototype.isStackChild=function(e){var i,r=this.nameTable[e.parentId];if(e&&e.parentId&&r.container&&"Stack"===r.container.type&&"UmlClassifier"!==this.nameTable[e.parentId].shape.type){i=!0;var s={sourceIndex:r.wrapper.children.indexOf(e.wrapper),source:e,target:void 0,targetIndex:void 0};this.diagramActions&ee.UndoRedo||this.addHistoryEntry({type:"StackChildPositionChanged",redoObject:{sourceIndex:void 0,source:e,target:void 0,targetIndex:void 0},undoObject:s,category:"Internal"})}return i},t.prototype.deleteChild=function(e,i,r){var s;if(s="string"==typeof e?e:e.id,(i=i?this.nameTable[i.id]:this.nameTable[e.parentId])&&i.children){for(var o=0;o=0;i--)this.removeLayer(this.layers[parseInt(i.toString(),10)].id);this.commandHandler.addLayer({id:"default_layer",visible:!0,lock:!1,objects:[],zIndex:0,objectZIndex:-1,zIndexTable:{}},null,!0),this.setActiveLayer(this.layers[this.layers.length-1].id)},t.prototype.clearObjects=function(e){var i=[];i=e||(i=i.concat(this.nodes)).concat(this.connectors),this.diagramActions=this.diagramActions|ee.Clear;for(var r=0,s=i;r0||"Text"===e.shape.type))if("Text"===e.shape.type)i=e.wrapper.children[0].id.split("_")[1];else for(var f=e.annotations.length-1;f>=0;f--)e.annotations[parseInt(f.toString(),10)].visibility&&(i=e.annotations[parseInt(f.toString(),10)].id);i&&(u=this.getWrapper(e.wrapper,i))}if(e&&u&&!(u instanceof Jn)&&(!function sne(n,t){return"Text"===t.shape.type?t.constraints&ie.ReadOnly:t.constraints&(t instanceof de?qe.ReadOnly:ie.ReadOnly)?n.constraints&Lr.InheritReadOnly?1:0:n.constraints&Lr.ReadOnly?1:0}(u,e)||p)){var g=u.style,v=void 0;v=90>(v=u.bounds.width50?50:e.width,u.style.fontSize)),e.parentId&&"UmlClassifier"===this.nameTable[e.parentId].shape.type?(l.width=e.wrapper.bounds.width-20,c=(e.wrapper.bounds.center.x+r.tx)*r.scale-l.width/2*s-2.5,d=(e.wrapper.bounds.center.y+r.ty)*r.scale-l.height/2*s-3,u.style.textAlign="Left"):(l.width=Math.max(l.width,50),c=(u.bounds.center.x+r.tx)*r.scale-l.width/2*s-2.5,d=(u.bounds.center.y+r.ty)*r.scale-l.height/2*s-3),Ho(y,{id:this.element.id+"_editTextBoxDiv",style:"position: absolute;left:"+c+"px;top:"+d+"px;width:"+(l.width+1)*s+"px;height:"+l.height*s+"px; containerName:"+e.id+";"}),Ho(S,{"aria-label":a,id:this.element.id+"_editBox",style:"width:"+(l.width+1)*s+"px;height:"+l.height*s+"px;resize: none;outline: none;overflow: hidden;;font-family:"+g.fontFamily+";font-size:"+g.fontSize*s+"px;text-align:"+u.style.textAlign.toLocaleLowerCase()+";",class:"e-diagram-text-edit"}),S.style.fontWeight=g.bold?"bold":"",S.style.fontStyle=g.italic?"italic":"",S.style.lineHeight=(1.2*g.fontSize+"px;").toString(),S.style.textDecoration=g.textDecoration?g.textDecoration:"",this.activeLabel.parentId=e.id,this.activeLabel.id=i,u.visible=!1,this.updateDiagramObject(e),this.diagramActions=this.diagramActions|ee.TextEdit,this.isTriggerEvent||(E.add(S,"input",this.eventHandler.inputChange,this.eventHandler),E.add(S,"focusout",this.focusOutEdit,this),S.select())}}}},t.prototype.updateConnectorfixedUserHandles=function(e){if(e.fixedUserHandles.length)for(var i=void 0,r=0,s=e.fixedUserHandles;r0&&this.mindMapChartModule.updateLayout(o,this.nameTable,this.layout,l,this.dataSourceSettings.id,this.dataSourceSettings.root),e=!0;else if(this.radialTreeModule)this.radialTreeModule.updateLayout(o,this.nameTable,this.layout,l),e=!0;else if(this.symmetricalLayoutModule)this.symmetricalLayoutModule.maxIteration=this.layout.maxIteration,this.symmetricalLayoutModule.springLength=this.layout.springLength,this.symmetricalLayoutModule.springFactor=this.layout.springFactor,this.symmetricalLayoutModule.updateLayout(o,this.connectors,this.symmetricalLayoutModule,this.nameTable,this.layout,l),e=!0;else if(this.complexHierarchicalTreeModule){this.canDistribute(a,r)&&(this.lineDistributionModule.diagram=this,this.connectors.forEach(function(R){R.obstaclePointCollection=[]}));var c=this.complexHierarchicalTreeModule.getLayoutNodesCollection(this.nodes);c.length>0&&this.complexHierarchicalTreeModule.doLayout(c,this.nameTable,this.layout,l,this),e=!0,this.canDistribute(a,r)&&this.lineDistributionModule.initLineDistribution(this.layout,this)}else this.flowchartLayoutModule?(this.flowchartLayoutModule.updateLayout(this.nodes,this),e=!0):console.warn("[WARNING] :: Module "+("OrganizationalChart"===this.layout.type?"HierarchicalTree":this.layout.type)+" is not available in Diagram component! You either misspelled the module name or forgot to load it.");if(e){this.preventDiagramUpdate=!0;for(var u={},f=0,g=o;f0)for(var S=0;S0)for(var M=0;M0)for(var s=0,o=r.ports;s0&&function Rse(n){var t,e,i,r=[];for(t=0;t0&&y.connectors[w].bezierSettings&&y.connectors[w].bezierSettings.allowSegmentsReset&&(y.connectors[w].segments=[]);if(t.connectors=y.connectors||[],t.dataSourceSettings=y.dataSourceSettings||{},t.dataSourceSettings.doBinding=i,t.height=y.height||"100%",t.setNodeTemplate=r,t.getConnectorDefaults=v,t.getNodeDefaults=g,t.getCustomProperty=o,t.mode=y.mode||"SVG",y.nodes)for(w=0;w0)){var r=this.nodes.filter(function(a){return 0===a.inEdges.length})[0],s=this.convertMindmapToMermaid(r,0);i.push(s),this.updateTextDataSource(i,r.outEdges,1),e=(i=i.filter(function(a){return""!==a.trim()})).join("\n")}return e},t.prototype.updateTextDataSource=function(e,i,r){for(var s=0;s0&&this.updateTextDataSource(e,h,r+1),s++}},t.prototype.convertMindmapToMermaid=function(e,i){var r=e.id,o=" ".repeat(2*(i+1)),a=e.annotations.length>0?e.annotations[0].content.replace(/\n/g," "):"",l=o+a,h=o+r;if(e.shape&&"Basic"===e.shape.type){var c=e.shape;"Rectangle"===c.shape?l=h+"["+a+"]":"Ellipse"===c.shape?l=h+"(("+a+"))":"Hexagon"===c.shape&&(l=h+"{{"+a+"}}")}else if(e.shape&&"Flow"===e.shape.type)"Terminator"===e.shape.shape&&(l=h+"("+a+")");else if(e.shape&&"Path"===e.shape.type){var u=e.shape;u.data===this.bangShape?l=h+"))"+a+"((":u.data===this.cloudShape&&(l=h+")"+a+"(")}return l},t.prototype.saveFlowDiagramInMermaidFormat=function(){var e=this,i=[],r="graph TD\n",s={nodes:this.nodes,edges:this.connectors};return s.nodes.reduce(function(a,l){return a[l.id]=l.annotations.length?l.annotations[0].content:"",a},{}),s.edges.forEach(function(a){var l=a.sourceID,h=a.targetID,p=e.nameTable[""+h],f=e.getNodeShape(e.nameTable[""+l]),g=e.getNodeShape(p),v=a.annotations[0]&&""!==a.annotations[0].content?"|"+a.annotations[0].content+"|":"";-1===i.indexOf(l)?i.push(l):f="",-1===i.indexOf(h)?i.push(h):g="";var y=e.arrowType(a);r+=" "+l+f+" "+y+v+" "+h+g+"\n"}),s.nodes.forEach(function(a){r+=" style "+a.id+" fill:"+a.style.fill+",stroke:"+a.style.strokeColor+",stroke-width:"+a.style.strokeWidth+"px;\n"}),r},t.prototype.arrowType=function(e){var i=e.targetDecorator.shape;return e.style.opacity<1?"~~~":""!==e.style.strokeDashArray?"-.->":"Arrow"===i?e.style.strokeWidth>1?"==>":"--\x3e":"None"===i?"---":"--\x3e"},t.prototype.getNodeShape=function(e){var i=e.annotations.length>0?e.annotations[0].content:"",r=e.shape.shape;if(!r){var s=e.shape.data;return"M 0 0 A 1 1 0 0 0 7 0 A 1 1 0 0 0 0 0 M -1 0 A 1 1 0 0 0 8 0 A 1 1 0 0 0 -1 0"===s?"((("+i+")))":"M 0 0 L 1 -1 L 5 -1 L 6 0 L 0 0"===s?"[/"+i+"\\]":"M 0 1 L 0 6 C 2 7 4 7 6 6 L 6 1 C 5 0 1 0 0 1 C 1 2 5 2 6 1"===s?"[("+i+")]":"M 0 0 L 12 0 L 14 2 L 2 2 L 0 0"===s?"[\\"+i+"\\]":"M 0 0 L 5 0 L 4 1 L 1 1 L 0 0"===s?"[\\"+i+"/]":"M 0 0 L 2 -2 L 11 -2 L 13 0 L 11 2 L 2 2 L 0 0"===s?"{{"+i+"}}":">"+i+"]"}switch(r){case"Terminator":return"(["+i+"])";case"Process":default:return"["+i+"]";case"Decision":return"{"+i+"}";case"Parallelogram":return"[/"+i+"/]";case"Ellipse":return"(("+i+"))";case"PreDefinedProcess":return"[["+i+"]]"}},t.prototype.loadDiagramFromMermaid=function(e){this.layout&&"Flowchart"===this.layout.type&&this.flowchartLayoutModule?this.convertMermaidToFlowChart(e):this.layout&&"MindMap"===this.layout.type&&this.mindMapChartModule?this.convertMermaidToMindmap(e):console.warn('[WARNING] :: Module "FlowchartLayout" or "MindMap" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.countLeadingSpaces=function(e){for(var i=0,r=e.length;i0});this.clear(),this.mermaidNodeBaseCollection=[];var r=[],s={text:"",children:[],currentLevel:0,branch:"Left"},o=[],l=!1,h=!1,c=!1;if(i.length>0){for(var d=function(M){var w=i[parseInt(M.toString(),10)],C=0,D="",A=u.countLeadingSpaces(w),x=w.includes('"`');if(h=w.includes('`"'),c=(l=!!x||l)||c?c:0===A&&M>0,l&&h&&!x)return s.text+="\n"+w,l=!1,"continue";if(!x&&l)return s.text+="\n"+w,"continue";if(l=!h&&l,w.length>0&&(/\s/.test(w[0])&&M>0||0===A)){if(-1!==o.findIndex(function(B){return B.space===A.toString()}))for(var L=o.length-1;L>=0;L--){var O=o[parseInt(L.toString(),10)];if((N=parseFloat(O.space))>A)o.splice(L,1);else{if(N=0;L--){var N,T=o[parseInt(L.toString(),10)];if(!((N=parseFloat(T.space))>A)){var P=o[o.length-1];o.push({space:A.toString(),level:P.level+1});break}o.splice(L,1)}C=o[o.length-1].level}D=w.trim().replace(/^[+-]/,"")}var _={text:D,branch:void 0,children:[],currentLevel:0===M?0:C-1};if(r.length>0){for(;r.length>=C&&0!==r.length;)r.pop();r.length>0&&r[r.length-1].children.push(_)}r.push(_),s=_},u=this,p=0;p0){var c=h[h.length-1];c.arrowType=a[2],""!==a[3]&&(c.label&&c.label.some(function(d){return d.trim().length>0})?c.label.push(a[3]):(c.label=[],c.label[c.parentId.length-1]=a[3]))}h.filter(function(d){return d.parentId&&0===d.parentId.length}).forEach(function(d){d.parentId=null}),i=i.concat(h)}}this.createFlowChart(i),this.doLayout(),this.clearHistory()},t.prototype.createFlowChart=function(e){for(var i=[],r=0;r1)for(var h=0;h|---|--\s*.*?\s*-->|~~~|==>|===|==\s*.*?\s*==>|\s*-\.\s*->|\s*-\.\s*-|\s*-\.\s*.*?\s*\.\s*->|\s*-\..*?\.\s*->)(.*)$/);if(l){i=l[1].trim();var h=l[2].trim();r=l[3].trim();var d=h.match(/(-\.|\\-\\-|==|--|~~)(.*?)(\1>|\.->|==>|\\->|~~>)/),u=void 0,p="";o=null!==(u=d?{text:d[2].trim()||null,arrowType:d[1]+d[3]}:{text:null,arrowType:h}).text?u.text:"",s=(p=u.arrowType).includes("--\x3e")?"single-line-arrow":p.includes("---")?"single-line":p.includes("==>")?"double-line-arrow":p.includes("==")?"double-line":p.includes("~~~")?"wiggly-arrow":p.includes("-.->")||p.includes(".->")?"dotted-arrow":p.includes("-.-")||p.includes(".-")?"dotted":"single-line-arrow"}return[i,r,s,o]},t.prototype.parseStyle=function(e,i){if(e.startsWith("style")){var s=e.match(/^style\s+(\w+)\s+fill:([^,]+),stroke:([^,]+),stroke-width:(\d+)px;/);if(s){var c={id:s[1],fill:s[2],stroke:s[3],strokeWidth:parseInt(s[4],10)},d=i.filter(function(u){return u.id===c.id});d[0].color=c.fill,d[0].stroke=c.stroke,d[0].strokeWidth=c.strokeWidth}}},t.prototype.getNodeData=function(e,i,r){for(var s=[],o=null,a=null,l=0,h="",c=function(v){var y=e[parseInt(v.toString(),10)],S=d.splitNested(y);if(S[0].includes("|")){var b=S[0].match(/\|([^|]*)\|/);b&&(h=b[1]);var M=S[0].split("|");M.length>=3&&(S[0]=M[2].trim())}var w=S[0].trim();if(0===v?o=w:a=w,i.find(function(L){return L.id===w}))l++;else{var D=S.length>1?S[1]:S[0],A=d.getShape(D),x=D.replace(/[\\[\]\\(\\)\\{\\}\\{\\}\\/>]/g,"");s.push({id:w,name:x,shape:A,color:"white",parentId:[]})}},d=this,u=0;u"===h?0===s?(r.trim().length>0&&i.push(r.trim()),r=h,o=h,s++):(r+=h,s++):"]"===h||"}"===h||")"===h?1===s&&h===o?(i.push((r+=h).trim()),r="",s--):s>1?(r+=h,s--):r+=h:r+=h}return r.trim().length>0&&i.push(r.trim()),i},t.prototype.getShape=function(e){var i={};return e.startsWith("(((")?i={type:"Path",data:"M 0 0 A 1 1 0 0 0 7 0 A 1 1 0 0 0 0 0 M -1 0 A 1 1 0 0 0 8 0 A 1 1 0 0 0 -1 0"}:e.startsWith("((")?i={shape:"Ellipse",type:"Basic"}:e.startsWith("([")?i={type:"Flow",shape:"Terminator"}:e.startsWith("(")?i={type:"Flow",shape:"Process"}:e.startsWith("[[")?i={type:"Flow",shape:"PreDefinedProcess"}:e.startsWith("[/")?i=e.endsWith("/]")?{type:"Basic",shape:"Parallelogram"}:{type:"Path",data:"M 0 0 L 1 -1 L 5 -1 L 6 0 L 0 0"}:e.startsWith("[(")?i={type:"Path",data:"M 0 1 L 0 6 C 2 7 4 7 6 6 L 6 1 C 5 0 1 0 0 1 C 1 2 5 2 6 1"}:e.startsWith("[\\")?i=e.endsWith("\\]")?{type:"Path",data:"M 0 0 L 12 0 L 14 2 L 2 2 L 0 0"}:{type:"Path",data:"M 0 0 L 5 0 L 4 1 L 1 1 L 0 0"}:e.startsWith("[")?i={type:"Basic",shape:"Rectangle"}:e.startsWith("{{")?i={type:"Path",data:"M 0 0 L 2 -2 L 11 -2 L 13 0 L 11 2 L 2 2 L 0 0"}:e.startsWith("{")?i={type:"Flow",shape:"Decision"}:e.startsWith(">")&&(i={type:"Path",data:"M 0 0 L 8 0 L 8 2 L 0 2 L 2 1 L 0 0"}),i},t.prototype.getDiagramContent=function(e){return this.printandExportModule?this.printandExportModule.getDiagramContent(e):(console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),"")},t.prototype.exportImage=function(e,i){this.printandExportModule?this.printandExportModule.exportImages(e,i):console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.printImage=function(e,i){this.printandExportModule?(i.printOptions=!0,this.printandExportModule.exportImages(e,i)):console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.setStackLimit=function(e){this.undoRedoModule&&e&&(this.historyManager.stackLimit=e,this.undoRedoModule.applyLimit(this.historyManager.currentEntry,e,this,!0))},t.prototype.clearHistory=function(){this.undoRedoModule&&this.undoRedoModule.clearHistory(this)},t.prototype.getDiagramBounds=function(){if(this.printandExportModule){var e=this.printandExportModule.getDiagramBounds("",{});return e.width=e.width>this.scrollSettings.viewPortWidth?e.width+(e.x>0?e.x:0):this.scrollSettings.viewPortWidth,e.height=e.height>this.scrollSettings.viewPortHeight?e.height+(e.y>0?e.y:0):this.scrollSettings.viewPortHeight,e.x=e.x>0?0:e.x,e.y=e.y>0?0:e.y,e}return console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),new Ne},t.prototype.exportDiagram=function(e){return this.printandExportModule?this.printandExportModule.exportDiagram(e):(console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),"")},t.prototype.print=function(e){this.printandExportModule?this.printandExportModule.print(e):console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.addPorts=function(e,i){var s;this.protectPropertyChange(!0),e=this.nameTable[e.id]||e,i.length>1&&this.startGroupAction();for(var o=function(h){if(e.ports.some(function(y){return y.id===i[parseInt(h.toString(),10)].id}))return"continue";if(e instanceof te?(s=new Es(e,"ports",i[parseInt(h.toString(),10)],!0),e.ports.push(s)):e instanceof de&&(s=new xc(e,"ports",i[parseInt(h.toString(),10)],!0),e.ports.push(s)),e.children)for(var c=e.wrapper,d=0;d1&&this.endGroupAction(),e.wrapper.measure(new me(e.width,e.height)),e.wrapper.arrange(e.wrapper.desiredSize),this.updateDiagramObject(e),this.protectPropertyChange(!1)},t.prototype.addConstraints=function(e,i){return e|i},t.prototype.removeConstraints=function(e,i){return e&~i},t.prototype.addNodeLabels=function(e,i){this.addLabels(e,i)},t.prototype.addConnectorLabels=function(e,i){this.addLabels(e,i)},t.prototype.addLabels=function(e,i){this.protectPropertyChange(!0);var s,r=(e=this.nameTable[e.id]||e).wrapper;i.length>1&&this.startGroupAction();for(var o=0;o1&&this.endGroupAction(),e.wrapper.measure(new me(r.width,r.height)),e.wrapper.arrange(r.desiredSize),this.updateDiagramObject(e),this.protectPropertyChange(!1),this.refreshCanvasLayers()},t.prototype.addChildToUmlNode=function(e,i,r){var s,o,a,l,h="NoWrap";"Class"===e.shape.classifier||"Interface"===e.shape.classifier?"Method"===r?(o=new dm(e,"",i),"Class"===e.shape.classifier?(e.shape.classShape.methods.push(o),s=e.shape.classShape):"Interface"===e.shape.classifier&&(e.shape.interfaceShape.methods.push(o),s=e.shape.interfaceShape),function soe(n,t,e,i){if(e.methods&&e.methods.length){var r=e.methods,s="",o="",a=void 0,l=1,h=void 0,c=0,d=0,u=n.shape,g="Class"===u.classifier?u.classShape:u.interfaceShape;1===r.length?g.attributes.length>0?(c=g.attributes.filter(function(w){return w.isSeparator}).length,h=(l=2+g.attributes.length+c)+1,aT(n,t,l)):h=l+1:(c=g.attributes.filter(function(w){return w.isSeparator}).length,d=g.methods.filter(function(w){return w.isSeparator}).length,h=(l=2+g.attributes.length+c+g.methods.length+d)+1);for(var v=0;v1&&this.startGroupAction();for(var r=i.length-1;r>=0;r--)if(e.children&&e.children.length>0){var s=e.wrapper.children.filter(function(o){return o.id===e.id+"group_container"});s&&s.length>0&&this.removelabelExtension(e,i,r,s[0])}else this.removelabelExtension(e,i,r,e.wrapper);i.length>1&&this.endGroupAction(),this.refreshCanvasLayers()},t.prototype.removePortsExtenion=function(e,i,r,s){for(var o=0;o1&&this.startGroupAction();for(var r=i.length-1;r>=0;r--)if(e.children&&e.children.length>0)for(var s=0;s1&&this.endGroupAction()},t.prototype.getSizeValue=function(e,i){var r;return r=e.toString().indexOf("px")>0?e.toString():e.toString().indexOf("%")>0?void 0!==i?"100%":e.toString():e.toString()+"px",i&&(qa(this),r="calc("+r+" - "+i+"px)"),r},t.prototype.renderRulers=function(){this.rulerSettings.showRulers?(function ise(n){var t=qa(n),i=Tt("div",{id:n.element.id+"_overlapRuler",style:"height:"+t.height+"px;width:"+t.width+"px;position:absolute;left:0;top:0",class:"e-ruler-overlap"});n.element.insertBefore(i,n.element.firstChild)}(this),oF(this,!0),oF(this,!1)):qx(this)},t.prototype.intOffPageBackground=function(){var e=new me;e=qa(this);var i=document.getElementById(this.element.id+"content"),r=this.getSizeValue(this.width,e.width),s=this.getSizeValue(this.height,e.height),o=this.rulerSettings.showRulers?"width:"+r+"; height:"+s+";top:"+e.height+"px;left:"+e.width+"px;overflow: scroll;position:absolute;overflow:auto;":"width:"+r+"; height:"+s+";position:absolute; left:0px; top:0px;overflow: auto;",a={id:this.element.id+"content",tabindex:"0",style:o};i?(this.diagramCanvas=i,Za(this.diagramCanvas,o)):(this.diagramCanvas=Tt("div",a),this.element.appendChild(this.diagramCanvas)),this.diagramCanvas.style.background=this.backgroundColor},t.prototype.initDiagram=function(){this.intOffPageBackground(),Ho(this.element,{style:"width:"+this.getSizeValue(this.width)+"; height:"+this.getSizeValue(this.height)+";position:relative;overflow:hidden;"})},t.prototype.renderHiddenUserHandleTemplateLayer=function(e){var r=Tt("div",{class:this.element.id+"_hiddenUserHandleTemplate",style:"width:"+e.width+"px; height:"+e.height+"px;visibility:hidden ; overflow: hidden;"});this.element.appendChild(r)},t.prototype.renderBackgroundLayer=function(e,i){var r=this.createSvg(this.element.id+"_backgroundLayer_svg",e.width,e.height);Za(r,i);var s=Bi("g",{id:this.element.id+"_backgroundImageLayer",class:"e-background-image-layer"});r.appendChild(s);var a=Bi("g",{id:this.element.id+"_backgroundLayer",class:"e-background-layer"});r.appendChild(a),this.diagramCanvas.appendChild(r)},t.prototype.renderGridLayer=function(e,i){var r=this.createSvg(this.element.id+"_gridline_svg",e.width,e.height);r.setAttribute("class","e-grid-layer");var s=Bi("g",{id:this.element.id+"_gridline"}),o=Bi("rect",{id:this.element.id+"_grid_rect",x:"0",y:"0",width:"100%",height:"100%"});if(om()){var a=new URL(window.location.href);o.setAttribute("fill",""!==a.search?"url(#"+this.element.id+"_pattern)":"url("+location.protocol+"//"+location.host+location.pathname+"#"+this.element.id+"_pattern)")}else o.setAttribute("fill","url(#"+this.element.id+"_pattern)");s.appendChild(o),r.appendChild(s),this.diagramCanvas.appendChild(r),oi(r,{style:i})},t.prototype.renderDiagramLayer=function(e,i){if(this.diagramLayerDiv=Tt("div",{id:this.element.id+"_diagramLayer_div",style:"width:"+e.width+"px; height:"+e.height+"px;"+i}),"SVG"===this.mode){var s=this.createSvg(this.element.id+"_diagramLayer_svg",e.width,e.height);s.style["pointer-events"]="none",s.setAttribute("class","e-diagram-layer");var o=Bi("g",{id:this.element.id+"_diagramLayer"}),a=Bi("g",{});this.diagramLayer=o,s.style["pointer-events"]="all",a.appendChild(o),s.appendChild(a),this.diagramLayerDiv.appendChild(s)}else this.diagramLayer=bo.createCanvas(this.element.id+"_diagram",e.width,e.height),Za(this.diagramLayer,"position:absolute;left:0px;top:0px;"),this.diagramLayerDiv.appendChild(this.diagramLayer);this.diagramCanvas.appendChild(this.diagramLayerDiv)},t.prototype.initLayers=function(){var e="position:absolute;top:0px;left:0px;overflow:hidden;pointer-events:none;",r=document.getElementById(this.element.id).getBoundingClientRect(),s=function Loe(){var n=Tt("div",{style:"visibility:hidden; width: 100px"});document.body.appendChild(n);var t=n.getBoundingClientRect().width;n.style.overflow="scroll";var e=Tt("div",{style:"width:100%"});n.appendChild(e);var i=e.getBoundingClientRect().width;return n.parentNode.removeChild(n),t-i}();this.scroller.scrollerWidth=s,this.scroller.setViewPortSize(r.width,r.height),this.renderRulers();var o="measureElement";window[""+o]&&(window[""+o]=null,document.getElementById("measureElement").remove()),function WF(){var n="measureElement";if(window[""+n])window[""+n].usageCount+=1;else{var t=Tt("div",{id:"measureElement",style:"visibility:hidden ; height: 0px ; width: 0px; overflow: hidden;"}),e=Tt("span",{style:"display:inline-block ; line-height: normal"});t.appendChild(e);var i=Tt("img",{alt:"measureElementImage",src:"data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7"});t.appendChild(i);var r=document.createElementNS("http://www.w3.org/2000/svg","svg");r.setAttribute("xmlns:xlink","http://www.w3.org/1999/xlink"),t.appendChild(r);var s=document.createElementNS("http://www.w3.org/2000/svg","path");s.setAttribute("d",""),r.appendChild(s),document.createTextNode("");var a=document.createElementNS("http://www.w3.org/2000/svg","text");a.setAttributeNS("http://www.w3.org/XML/1998/namespace","xml:space","preserve"),r.appendChild(a),window[""+n]=t,window[""+n].usageCount=1,document.body.appendChild(t);var l="measureElementCount";window[""+l]?window[""+l]++:window[""+l]=1}}(),this.renderBackgroundLayer(r,e),this.renderGridLayer(r,e),this.renderDiagramLayer(r,e),this.renderHTMLLayer(r,e),this.renderPortsExpandLayer(r,e),this.renderNativeLayer(r,e),this.renderAdornerLayer(r,e),this.renderHiddenUserHandleTemplateLayer(r)},t.prototype.renderAdornerLayer=function(e,i){var r=Tt("div",{id:this.element.id+"_diagramAdornerLayer",style:"width:"+e.width+"px;height:"+e.height+"px;"+i}),s=Tt("div",{id:this.element.id+"_diagramUserHandleLayer",style:"width:"+e.width+"px;height:"+e.height+"px;"+i});s.setAttribute("class","e-userHandle-layer"),r.appendChild(s);var o=this.createSvg(this.element.id+"_diagramAdorner_svg",e.width,e.height);o.setAttribute("class","e-adorner-layer"),o.style["pointer-events"]="none",this.adornerLayer=Bi("g",{id:this.element.id+"_diagramAdorner"}),this.adornerLayer.style[" pointer-events"]="all",o.appendChild(this.adornerLayer),r.appendChild(o),this.diagramCanvas.appendChild(r);var a=Bi("g",{id:this.element.id+"_SelectorElement"});this.adornerLayer.appendChild(a),oi(o,{style:"pointer-events:none;"})},t.prototype.renderPortsExpandLayer=function(e,i){var r=this.createSvg(this.element.id+"_diagramPorts_svg",e.width,e.height);r.setAttribute("class","e-ports-expand-layer");var s=Bi("g",{id:this.element.id+"_diagramPorts",class:"e-ports-layer",style:"pointer-events: all;"});r.appendChild(s);var o=Bi("g",{id:this.element.id+"_diagramExpander",class:"e-expand-layer",style:"pointer-events: all;"});r.appendChild(o),this.diagramCanvas.appendChild(r),oi(r,{style:i})},t.prototype.renderHTMLLayer=function(e,i){this.htmlLayer=Tt("div",{id:this.element.id+"_htmlLayer",style:"width:"+e.width+"px; height:"+e.height+"px;position:absolute;top:0px;left:0px;overflow:hidden;pointer-events:none;",class:"e-html-layer"});var r=Tt("div",{id:this.element.id+"_htmlLayer_div",style:"position:absolute;top:0px;left:0px;pointer-events:all;"});this.htmlLayer.appendChild(r),this.diagramCanvas.appendChild(this.htmlLayer)},t.prototype.renderNativeLayer=function(e,i){var r=this.createSvg(this.element.id+"_nativeLayer_svg",e.width,e.height),s=Bi("g",{id:this.element.id+"_nativeLayer",style:"pointer-events:all;"});r.appendChild(s),this.diagramLayerDiv.appendChild(r),oi(r,{class:"e-native-layer",style:i})},t.prototype.createSvg=function(e,i,r){var s=document.createElementNS("http://www.w3.org/2000/svg","svg");return oi(s,{id:e,width:i,height:r}),s},t.prototype.updateBazorShape=function(){for(var e=0;e1,i=[],r={},s={},o=[],a=0,l=this.nodes;a0||b&&b.children&&b.children.length>0)&&(M=!1),S&&S.wrapper&&b&&b.wrapper&&M?this.initConnectors(r[""+h],f):i.push(r[""+h])}else b=r[y.targetID],(S=r[y.sourceID])&&S.children&&S.children.length>0||b&&b.children&&b.children.length>0?i.push(r[""+h]):this.initConnectors(r[""+h],f);else r[""+h].children?o.push(h):r[""+h].shape instanceof uT&&r[""+h].shape.activity.subProcess.processes&&r[""+h].shape.activity.subProcess.processes.length>0?s[r[""+h].id]=h:this.initNodes(r[""+h],f);if(this.bpmnModule)for(var w=0,C=this.bpmnModule.bpmnTextAnnotationConnector;w-1&&-1===r.indexOf(c)&&-1===s.indexOf(c)&&r.splice(0,0,c);-1===r.indexOf(o)&&s.push(o)}return r.concat(s)},t.prototype.addToLayer=function(e,i){var r;if(i&&(r=this.commandHandler.getObjectLayer(e.id)),(!i||!r)&&-1===this.activeLayer.objects.indexOf(e.id)&&this.activeLayer.objects.push(e.id),(e instanceof te||e instanceof de)&&("SwimLane"!==e.shape.type||e.children&&e.children.length>0)){if(e.parentId){var s=this.swimlaneZIndexTable[e.parentId],o=this.swimlaneChildTable[e.id];(s&&-1!==s||o&&-1!==o)&&(e.zIndex=this.swimlaneChildTable[e.id])}e instanceof de&&e.sourceID&&e.targetID?-1!==this.activeLayer.objects.indexOf(e.sourceID)&&-1!==this.activeLayer.objects.indexOf(e.targetID)&&this.setZIndex(r||this.activeLayer,e):this.setZIndex(r||this.activeLayer,e)}},t.prototype.updateLayer=function(e){for(var i=0,r=Object.keys(e.layers);i0)for(r=0;rs;l--)r.zIndexTable[parseInt(l.toString(),10)]=r.zIndexTable[l-1],this.nameTable[r.zIndexTable[parseInt(l.toString(),10)]]&&(this.nameTable[r.zIndexTable[parseInt(l.toString(),10)]].zIndex=l);r.zIndexTable[parseInt(a.toString(),10)]=i.id}}},t.prototype.initializeDiagramLayers=function(){for(var e=0;ethis.layers[parseInt(a.toString(),10)].zIndex&&(i=this.layers[parseInt(e.toString(),10)],this.layers[parseInt(e.toString(),10)]=this.layers[parseInt(a.toString(),10)],this.layers[parseInt(a.toString(),10)]=i);0===this.layers.length&&this.commandHandler.addLayer({id:"default_layer",visible:!0,lock:!1,objects:[],zIndex:0,objectZIndex:-1,zIndexTable:{}},null,!0),this.setActiveLayer(this.layers[this.layers.length-1].id)},t.prototype.resetTool=function(){this.eventHandler.resetTool()},t.prototype.initObjectExtend=function(e,i,r){if(r){var s=this.commandHandler.checkBoundaryConstraints(void 0,void 0,e.wrapper.bounds,!0);if("SwimLane"===e.shape.type)for(var o=0,a=Object.keys(i.zIndexTable);o0)&&this.setZIndex(i,e)),e instanceof te){if(r){if("helper"!==e.id&&(o=Zi(this.getNodeDefaults))){if((a=o(e,this))&&a.ports)for(var l=0;l0)for(l=0;l0&&!e.container||e.processId){var r=this.nameTable[e.id];if(!(this.realActions&$i.PreventScale||this.realActions&$i.PreventDrag)){if(r.offsetX&&(this.realActions&$i.EnableGroupAction||!(this.diagramActions&ee.UndoRedo||this.diagramActions&ee.ToolAction||this.diagramActions&ee.PublicMethod))){this.realActions|=$i.PreventScale;var s=r.offsetX-e.wrapper.offsetX;r.offsetX=e.wrapper.offsetX;var o=r.offsetY-e.wrapper.offsetY;r.offsetY=e.wrapper.offsetY,s+o!==0&&this.drag(r,s,o),this.realActions&=~$i.PreventScale}else r.offsetX=e.wrapper.offsetX;r.offsetY&&(this.realActions&$i.EnableGroupAction||!(this.diagramActions&ee.UndoRedo||this.diagramActions&ee.ToolAction||this.diagramActions&ee.PublicMethod))?(this.realActions|=$i.PreventScale,o=r.offsetY-e.wrapper.offsetY,r.offsetY=e.wrapper.offsetY,this.drag(r,0,o),this.realActions&=~$i.PreventScale):r.offsetY=e.wrapper.offsetY,this.diagramActions&&(r.width=e.wrapper.actualSize.width,r.height=e.wrapper.actualSize.height)}}i&&e.children&&e.children.length>0&&(void 0!==this.nameTable[e.id].width?this.scaleObject(e,this.nameTable[e.id].width,!0):this.nameTable[e.id].width=e.wrapper.actualSize.width,void 0!==this.nameTable[e.id].height?this.scaleObject(e,this.nameTable[e.id].height,!1):this.nameTable[e.id].height=e.wrapper.actualSize.height)},t.prototype.initNode=function(e,i,r){var a,p,s=e.initContainer(),o=new Ii;if(this.diagramSettings.inversedAlignment||(s.inversedAlignment=!1),s.children||(s.children=[]),e.children){s.measureChildren=!1,o.id=e.id+"group_container",o.style.fill=e.shape&&"SwimLane"===e.shape.type?e.style.fill:"none",o.style.strokeColor="none",o.horizontalAlignment="Stretch",o.verticalAlignment="Stretch",o.pivot=e.pivot,s.style=e.style,s.padding.left=e.padding.left,s.padding.right=e.padding.right,s.padding.top=e.padding.top,s.padding.bottom=e.padding.bottom,o.children=[],o.preventContainer=!0,e.container&&(o.relativeMode="Object");var l=!!(e.ports&&e.ports.length>0);if(m(e.container)&&!l&&s.children.push(o),e.container&&"Grid"===e.container.type)for(var h=0;h0&&e.wrapper.children[0]instanceof Qv){if(this.setZIndex(this.activeLayer,e),this.connectors.length>0)for(h=0;h0?i.phases.length:0,v="Horizontal"===i.orientation,y=v?i.phases.length||1:s.length+1,S=v?(i.header&&i.hasHeader?1:0)+(i.phases.length>0?1:0)+i.lanes.length:(i.header&&i.hasHeader?1:0)+i.phases.length;if(0===h&&!v&&i.lanes.length&&(S+=1),v?(a=(i.header&&i.hasHeader?1:0)+(h>0?1:0),l=0):(a=i.header&&i.hasHeader?1:0,l=h>0?1:0),s.length>0)for(o+=i.header&&i.hasHeader?i.header.height:0,p=0;pl?d.margin.left=d.margin.left-(u.bounds.left-e.bounds.left):u.children[0].children[1].actualSize.width+r>=d.margin.left&&(d.margin.left=u.children[0].children[1].actualSize.width+r),d.margin.lefta?d.margin.top=d.margin.top-(u.bounds.top-o):u.children[0].children[1].actualSize.height+r>=d.margin.top&&(d.margin.top=u.children[0].children[1].actualSize.height+r),d.margin.left0)for(o=0;o0&&this.updateChildPosition(e)},t.prototype.addBpmnAnnotationConnector=function(e,i){if(e.parentObj instanceof t||e.parentObj instanceof Bd){var r=e.shape,o=""!==r.textAnnotation.textAnnotationTarget&&this.nameTable[r.textAnnotation.textAnnotationTarget],a=o?this.nameTable[r.textAnnotation.textAnnotationTarget]:null,l=null!=a?a.wrapper:null,h=e.ports[0],c={x:0,y:0};switch(r.textAnnotation.textAnnotationDirection){case"Left":h.offset={x:0,y:.5},c.x=i.bounds.left-40,c.y=i.bounds.bottom+30;break;case"Right":h.offset={x:1,y:.5},c.x=i.bounds.right+40,c.y=i.bounds.bottom+30;break;case"Top":h.offset={x:.5,y:0},c.x=i.bounds.right+30,c.y=i.bounds.top-40;break;case"Bottom":h.offset={x:.5,y:1},c.x=i.bounds.right+30,c.y=i.bounds.bottom+40;break;default:h.offset={x:0,y:.5},c.x=i.bounds.left-40,c.y=i.bounds.bottom+30,o&&null!=i&&null!=l&&(i.bounds.left>l.bounds.right?h.offset={x:0,y:.5}:i.bounds.rightl.bounds.top?h.offset={x:.5,y:0}:i.bounds.top0&&this.updateChildPosition(r)}},t.prototype.canExecute=function(){return!0},t.prototype.updateStackProperty=function(e,i,r){e.container&&"Stack"===e.container.type&&(i.width||(i.wrapper.horizontalAlignment="Stretch",i.horizontalAlignment="Stretch"),i.height||(i.verticalAlignment="Stretch",i.wrapper.verticalAlignment="Stretch"),r&&"UmlClassifier"===e.shape.type&&(i.umlIndex=r))},t.prototype.initViews=function(){this.isLoading||(this.views.push(this.element.id),this.views[this.element.id]=this)},t.prototype.initCommands=function(){var e=this.commandManager.commands,i={copy:{execute:this.copyCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.C,keyModifiers:pt.Control}},paste:{execute:this.pasteCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.V,keyModifiers:pt.Control}},cut:{execute:this.cutCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.X,keyModifiers:pt.Control}},delete:{execute:this.removeCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Delete}},selectAll:{execute:this.selectAll.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.A,keyModifiers:pt.Control}},undo:{execute:this.undo.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Z,keyModifiers:pt.Control}},redo:{execute:this.redo.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Y,keyModifiers:pt.Control}},nudgeUp:{execute:this.nudgeCommand.bind(this,"Up"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Up},parameter:"up"},nudgeRight:{execute:this.nudgeCommand.bind(this,"Right"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Right},parameter:"right"},nudgeDown:{execute:this.nudgeCommand.bind(this,"Down"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Down},parameter:"down"},nudgeLeft:{execute:this.nudgeCommand.bind(this,"Left"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Left},parameter:"left"},startEdit:{execute:this.startEditCommad.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.F2}},endEdit:{execute:this.endEditCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Escape}},focusToNextItem:{execute:this.navigateItems.bind(this,!0),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Tab}},focusToPreviousItem:{execute:this.navigateItems.bind(this,!1),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Tab,keyModifiers:pt.Shift}},selectFocusedItem:{execute:this.startEditCommad.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Enter}},bold:{execute:this.fontStyleCommand.bind(this,"bold"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.B,keyModifiers:pt.Control}},italic:{execute:this.fontStyleCommand.bind(this,"italic"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.I,keyModifiers:pt.Control}},underline:{execute:this.fontStyleCommand.bind(this,"underline"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.U,keyModifiers:pt.Control}},duplicate:{execute:this.duplicateCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.D,keyModifiers:pt.Control}},group:{execute:this.groupCommand.bind(this,"group"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.G,keyModifiers:pt.Control}},ungroup:{execute:this.groupCommand.bind(this,"ungroup"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.U,keyModifiers:pt.Control|pt.Shift}},rotateClockwise:{execute:this.rotateCommand.bind(this,"clockwise"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.R,keyModifiers:pt.Control}},rotateAntiClockwise:{execute:this.rotateCommand.bind(this,"antiClockwise"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.L,keyModifiers:pt.Control}},flipHorizontal:{execute:this.flipCommand.bind(this,"horizontal"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.H,keyModifiers:pt.Control}},flipVertical:{execute:this.flipCommand.bind(this,"vertical"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.J,keyModifiers:pt.Control}},pointerTool:{execute:this.toolCommand.bind(this,"pointer"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number1,keyModifiers:pt.Control}},textTool:{execute:this.toolCommand.bind(this,"text"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number2,keyModifiers:pt.Control}},connectTool:{execute:this.toolCommand.bind(this,"connect"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number3,keyModifiers:pt.Control}},freeForm:{execute:this.toolCommand.bind(this,"freeForm"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number5,keyModifiers:pt.Control}},lineTool:{execute:this.toolCommand.bind(this,"line"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number6,keyModifiers:pt.Control}},rectangleTool:{execute:this.toolCommand.bind(this,"rectangle"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number8,keyModifiers:pt.Control}},ellipseTool:{execute:this.toolCommand.bind(this,"ellipse"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number9,keyModifiers:pt.Control}},zoomIn:{execute:this.zoomCommand.bind(this,"zoomIn"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Plus,keyModifiers:pt.Control}},zoomOut:{execute:this.zoomCommand.bind(this,"zoomOut"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Minus,keyModifiers:pt.Control}},shiftUp:{execute:this.shiftCommand.bind(this,"Up"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Up,keyModifiers:pt.Shift}},shiftDown:{execute:this.shiftCommand.bind(this,"Down"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Down,keyModifiers:pt.Shift}},shiftLeft:{execute:this.shiftCommand.bind(this,"Left"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Left,keyModifiers:pt.Shift}},shiftRight:{execute:this.shiftCommand.bind(this,"Right"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Right,keyModifiers:pt.Shift}},alignTextCenter:{execute:this.alignCommand.bind(this,"center"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.C,keyModifiers:pt.Control|pt.Shift}},alignTextLeft:{execute:this.alignCommand.bind(this,"right"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.L,keyModifiers:pt.Control|pt.Shift}},alignTextRight:{execute:this.alignCommand.bind(this,"left"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.R,keyModifiers:pt.Control|pt.Shift}},alignTextTop:{execute:this.alignCommand.bind(this,"top"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.E,keyModifiers:pt.Control|pt.Shift}},alignTextCenterVertical:{execute:this.alignCommand.bind(this,"centerVertical"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.M,keyModifiers:pt.Control|pt.Shift}},alignTextBottom:{execute:this.alignCommand.bind(this,"bottom"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.V,keyModifiers:pt.Control|pt.Shift}},alignJustify:{execute:this.alignCommand.bind(this,"justify"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.J,keyModifiers:pt.Control|pt.Shift}},sendToBack:{execute:this.orderCommand.bind(this,"sendToBack"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.B,keyModifiers:pt.Control|pt.Shift}},bringToFront:{execute:this.orderCommand.bind(this,"bringToFront"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.F,keyModifiers:pt.Control|pt.Shift}},sendBackward:{execute:this.orderCommand.bind(this,"sendBackward"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.BracketLeft,keyModifiers:pt.Control}},bringForward:{execute:this.orderCommand.bind(this,"bringForward"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.BracketRight,keyModifiers:pt.Control}}};this.initCommandManager(e,i)},t.prototype.overrideCommands=function(e,i){for(var r,s=0,o=Object.keys(i);se.zIndex){("HTML"===e.shape.type||"Native"===e.shape.type)&&(o="HTML"===e.shape.type?"html":"native"),s=Eoe(i,r[parseInt(a.toString(),10)].id,o);break}return s},t.prototype.updateDiagramObject=function(e,i,r){for(var s,o="domTable",a=0,l=this.views;a1&&(d=this.commandHandler.getObjectLayer(e.id)),void 0===d||d&&d.visible||r){var u=Io(this.element.id);window[""+o][s.element.id+"_diagramLayer"]||(window[""+o][s.element.id+"_diagramLayer"]=document.getElementById(s.element.id+"_diagramLayer"));var p=window[""+o][s.element.id+"_diagramLayer"];this.diagramActions&ee.Interactions&&this.updateCanupdateStyle(e.wrapper.children,!0);var f=this.getMidPoint(e);this.diagramRenderer.updateNode(e.wrapper,p,u,void 0,i?void 0:this.getZindexPosition(e,s.element.id),f,this.portCenterPoint),this.updateCanupdateStyle(e.wrapper.children,!0)}}},t.prototype.applyMarginBezier=function(e,i){i.cx=i.cx+e.margin.left,i.cx=i.cx-e.margin.right,i.cy=i.cy+e.margin.top,i.cy=i.cy-e.margin.bottom},t.prototype.getMidPoint=function(e){var i;if(e instanceof de&&"Bezier"===e.type){i=[];for(var r=this.getBezierPoints(e),s=z.getLengthFromListOfPoints(r),o=0;o0&&e.updateView(e));var s=Io(e.element.id);this.renderDiagramElements(e.diagramLayer,e.diagramRenderer,s,void 0,void 0,i);for(var o=0;o0&&this.renderBasicElement(e),!this.diagramActions||!(this.diagramActions&ee.Render)||ee.ToolAction&this.diagramActions||Ds(this)||1!==this.scroller.currentZoom?this.refreshElements(e):this.renderTimer||(this.renderTimer=setTimeout(function(){i.refreshElements(e)},40)))},t.prototype.updatePortVisibility=function(e,i,r){var s;if((e instanceof te||e instanceof de)&&(!this.drawingObject||!this.drawingObject.shape)&&to(e)){for(var a=e.ports,l=!1,h=0;h=0&&this.scroller.removeCollection.splice(l,1);var h=this.nameTable[e[parseInt(a.toString(),10)]];this.updateTextElementValue(h),this.diagramRenderer.renderElement(h.wrapper,s,o,void 0,void 0,void 0,void 0,h.zIndex)}for(var c=0;c0?this.scroller.oldCollectionObjects:void 0,b=Object.keys(S||g.zIndexTable);b.sort(function(N,T){return parseInt(""+N,10)-parseInt(""+T,10)});for(var M=0,w=b;M0?h:0)+"px",y=(this.realActions&$i.vScrollbarMoved?0:-(this.scroller.verticalOffset<0?this.scroller.verticalOffset:0))+"px"):(v="0px",y="0px"),this.realActions&$i.hScrollbarMoved&&(this.realActions=this.realActions&~$i.hScrollbarMoved),this.realActions&$i.vScrollbarMoved&&(this.realActions=this.realActions&~$i.vScrollbarMoved)):(v=(l.x<0?h:-this.scroller.horizontalOffset)+"px",y=(l.y<0?c:-this.scroller.verticalOffset)+"px"),this.diagramLayer.style.left=v,this.diagramLayer.style.top=y,A.tx=-l.x/A.scale,A.ty=-l.y/A.scale);var R=!0;if(o&&(R=!1),this.updateTextElementValue(D),this.refreshing&&D.shape.activity&&D.shape.activity.subProcess&&D.shape.activity.subProcess.processes){for(var L=0;L0){var o=s.children[0],a=o.data;(r.isBezierEditing&&this.selectedItems.connectors[0].id===r.id||"Bezier"!==r.type)&&r.getSegmentElement(r,o,"ComplexHierarchicalTree"===this.layout.type||"HierarchicalTree"===this.layout.type?this.layout.orientation:void 0,void 0,!1),o.data!==a&&(s.measure(new me),s.arrange(s.desiredSize),"SVG"===this.mode&&!e&&this.updateDiagramObject(r))}}else this.constraints&rt.Bridging&&console.warn('[WARNING] :: Module "ConnectorBridging" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.setCursor=function(e){this.diagramRenderer.setCursor(this.diagramCanvas,e)},t.prototype.clearCanvas=function(e){var i=e.contentWidth||e.diagramLayer.width/this.scroller.currentZoom,r=e.contentHeight||e.diagramLayer.height/this.scroller.currentZoom;"SVG"!==e.mode&&bo.getContext(e.diagramLayer).clearRect(0,0,i,r)},t.prototype.updateScrollOffset=function(){this.scroller.setScrollOffset(this.diagramCanvas.scrollLeft,this.diagramCanvas.scrollTop),KI(this),Ds(this)&&this.scroller.virtualizeElements()},t.prototype.setOffset=function(e,i){var r="domTable";window[""+r][this.element.id+"content"]||(window[""+r][this.element.id+"content"]=document.getElementById(this.element.id+"content"));var s=window[""+r][this.element.id+"content"];s&&(s.scrollLeft=e,s.scrollTop=i)},t.prototype.setSize=function(e,i){if(this.diagramLayer&&!this.preventDiagramUpdate){var r=qa(this);e-=r.width,i-=r.height;var s=this.spatialSearch.getPageBounds();s.x*=this.scroller.currentZoom,s.y*=this.scroller.currentZoom,s.width*=this.scroller.currentZoom,s.height*=this.scroller.currentZoom;var o="SVG"===this.mode?1:1.5,a="SVG"===this.mode?mT(this.element.id):this.diagramLayer,h="Canvas"===this.mode&&this.constraints&rt.Virtualization?this.scroller.viewPortHeight:i;a.setAttribute("width",(o*("Canvas"===this.mode&&this.constraints&rt.Virtualization?this.scroller.viewPortWidth:e)).toString()),a.setAttribute("height",(o*h).toString());var c=document.getElementById(this.element.id+"_diagramUserHandleLayer");c&&(c.style.width=e+"px",c.style.height=i+"px");var d={width:e.toString(),height:i.toString()};this.diagramLayerDiv.style.width=e+"px",this.diagramLayerDiv.style.height=i+"px",oi(FF(this.element.id),d),oi(function xoe(n){return xt(n).getElementsByClassName("e-ports-expand-layer")[0]}(this.element.id),d);var u=zl(this.element.id);oi(u,d),u.parentNode.style.width=e+"px",u.parentNode.style.height=i+"px";var p=_d(this.element.id);oi(p,d),this.diagramRenderer.updateGrid(this.snapSettings,p,this.scroller.transform,this.rulerSettings,this.hRuler,this.vRuler),oi(IT(this.element.id),d),this.htmlLayer.style.width=e+"px",this.htmlLayer.style.height=i+"px","SVG"!==this.mode&&!Ds(this)&&this.refreshDiagramLayer(),"SVG"===this.mode&&Ds(this)&&this.scroller.virtualizeElements()}},t.prototype.transformLayers=function(){var e=this.spatialSearch.getPageBounds();e.x*=this.scroller.currentZoom,e.y*=this.scroller.currentZoom,e.width*=this.scroller.currentZoom,e.height*=this.scroller.currentZoom,this.diagramRenderer.updateGrid(this.snapSettings,_d(this.element.id),this.scroller.transform,this.rulerSettings,this.hRuler,this.vRuler),this.diagramRenderer.transformLayers(this.scroller.transform,"SVG"===this.mode),this.diagramActions&ee.DragUsingMouse||this.updateSelector(),this.renderPageBreaks(e)},t.prototype.removePageBreaks=function(){if(this.diagramLayer){var e=_F(this.element.id);if(e&&e.childNodes)for(var i=e.childNodes.length,r=0;rthis.pageSettings.height&&(e=this.pageSettings.height,this.pageSettings.height=this.pageSettings.width,this.pageSettings.width=e):this.pageSettings.height>this.pageSettings.width&&(e=this.pageSettings.width,this.pageSettings.width=this.pageSettings.height,this.pageSettings.height=e)},t.prototype.setOverview=function(e,i){if(e)e&&(this.views.push(e.id),this.views[e.id]=e,e.renderDocument(e),e.diagramRenderer.setLayers(),e.updateView(e),this.renderNodes(e));else{for(var r=0;r1&&this.updateSelectionRectangle(),this.isProtectedOnChange=s},t.prototype.updateSelectionRectangle=function(){for(var e=um(this.element.id),i=!1,r=0;r1&&this.updateSelectionRectangle(),this.enableServerDataBinding(e)},t.prototype.renderSelectorForAnnotation=function(e,i){this.diagramRenderer.renderResizeHandle(e.wrapper.children[0],i,e.thumbsConstraints,this.scroller.currentZoom,e.constraints,this.scroller.transform,void 0,to(e.annotation),void 0,void 0,e.handleSize)},t.prototype.drawSelectionRectangle=function(e,i,r,s){this.clearSelectorLayer(),this.diagramRenderer.drawSelectionRectangle(e,i,r,s,this.adornerLayer,this.scroller.transform)},t.prototype.renderHighlighter=function(e){var i=zl(this.element.id);this.diagramRenderer.renderHighlighter(e,i,this.scroller.transform)},t.prototype.clearHighlighter=function(){var e=zl(this.element.id),i=e.getElementById(e.id+"_highlighter");i&&i.parentNode.removeChild(i)},t.prototype.getNodesConnectors=function(e){for(var i=0;i0;l--)(a=o[l-1]).parentNode.removeChild(a);if(!ce()){var h=ST(this.element.id).childNodes;for(r=h.length;r>0;r--)h[r-1].parentNode.removeChild(h[r-1])}}},t.prototype.getWrapper=function(e,i){var r;i=e.id+"_"+i;for(var s=e instanceof Ii?e:this.getPortContainer(this.nameTable[e.id]),o=0;o0&&this.applyStyle(e,a=r.annotations)}for(i=0;i0){var a=this.selectedItems.connectors[parseInt(i.toString(),10)].annotations;this.applyStyle(e,a)}},t.prototype.applyStyle=function(e,i){for(var r=0;r0)for(var i=0;i0?r[0].zIndex+(e?1:-1):e?0:this.nodes.length+this.connectors.length-1)<0?i=this.nodes.length+this.connectors.length-1:i===this.nodes.length+this.connectors.length&&(i=0);for(var s=0;s0)for(var s=void 0,o=r.children.length-1;o>=0;o--){var a=r.children[parseInt(o.toString(),10)];i.length>0&&-1!==i.indexOf(a.id.split("_groupElement")[0])&&(r.parentNode.insertBefore(a,s||r),s=a)}r&&r.parentNode.removeChild(r)},t.prototype.deleteGroup=function(e){var r=[];e.children&&(r=this.commandHandler.getChildren(e,[])),this.UpdateBlazorDiagramModelCollection(e);for(var s=0,o=r;s0)for(var xe=0;xe0)if("Path"===t.shape.type&&void 0!==n.shape.data)t.wrapper.children[0].data=n.shape.data;else if("Text"===t.shape.type&&void 0!==n.shape.content)t.wrapper.children[0].content=n.shape.content;else if("Image"===t.shape.type&&void 0!==n.shape.source)t.wrapper.children[0].source=n.shape.source;else if("Native"===t.shape.type){for(var r=void 0,s=0;s-1)&&(this.diagramActions&ee.PreventZIndexOnDragging?this.updateDiagramObject(e,!0):this.updateDiagramObject(e)),!s&&d&&(this.lineRoutingModule&&this.diagramActions&&this.constraints&rt.LineRouting&&"helper"!==e.id?this.diagramActions&ee.ToolAction||this.lineRoutingModule.renderVirtualRegion(this,!0):this.diagramActions&&this.constraints&rt.LineRouting&&"helper"!==e.id&&console.warn('[WARNING] :: Module "LineRouting" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),this.updateConnectorEdges(e),"helper"!==e.id&&!(this.diagramActions&ee.ToolAction))))for(var ya=this.spatialSearch.findObjects(e.wrapper.outerBounds),Mo=0;Moe?Math.abs(r-e):Math.abs(e-r),d=s>i?Math.abs(s-i):Math.abs(i-s);(0===c&&0===d||Number.isNaN(c)&&Number.isNaN(d))&&o.laneMargin&&(u=o.margin.left-o.laneMargin.left,p=o.margin.top-o.laneMargin.top);var f=o.width,g=o.height,v=new Ne(0,0,0,0);if(0!==f&&0!==g&&(v=new Ne((0!==r?r:o.offsetX)-f/2,(0!==s?s:o.offsetY)-g/2,f,g)),h){var y=l,b=this.selectedItems.nodes?this.selectedItems.nodes[0]:void 0;if(""!==y.textAnnotation.textAnnotationTarget&&this.nameTable[y.textAnnotation.textAnnotationTarget])if(""===o.parentId||b&&b.shape&&"TextAnnotation"===b.shape.shape){if("Auto"===y.textAnnotation.textAnnotationDirection&&a.children[0]instanceof Ii&&a.children[0].children[0]instanceof Ke){var w=a.children[0],C=document.getElementById(w.id+"_groupElement"),D=document.getElementById(w.children[0].id+"_groupElement");C.removeChild(D),w.children.splice(0,1),this.isProtectedOnChange=!0,this.bpmnModule.setAnnotationPath(v,w,o,y,y.textAnnotation.textAnnotationDirection,this),this.isProtectedOnChange=!1}}else this.isPositionUndo=!0,this.updateTextAnnotationInSwimlane(o,o),this.isPositionUndo=!1;else o.inEdges.length>0&&(x=this.nameTable[""+o.inEdges[0]])&&x.isBpmnAnnotationConnector&&(x.sourcePoint={x:r>e?x.sourcePoint.x+c:x.sourcePoint.x-c,y:s>i?x.sourcePoint.y+d:x.sourcePoint.y-d});this.nodePropertyChange(o,{},R={ports:[{offset:o.ports[0].offset}]})}else for(var L=0,O=o.outEdges;Le?T.offsetX+c:T.offsetX-c,T.offsetY=s>i?T.offsetY+d:T.offsetY-d,R={offsetX:T.offsetX,offsetY:T.offsetY}),this.nodePropertyChange(T,P,R)}}}},t.prototype.updatePorts=function(e,i){if(e&&e.ports.length>0)for(var r=0,s=Object.keys(e.ports);r0)for(var i=0;i0)for(var r=0;r0&&void 0===r.segments&&(e.segments=[]),void 0!==r.shape&&void 0!==e.shape&&e.shape&&"Bpmn"===e.shape.type&&this.bpmnModule&&this.bpmnModule.updateBPMNConnector(e,i,r,this),void 0!==e.constraints?(this.updateThumbConstraints(this.selectedItems.connectors,this.selectedItems),s=!0):s},t.prototype.connectorPropertyChange=function(e,i,r,s,o){if(this.canEnableBlazorObject){var a=$(e);this.insertValue(a,!1)}var d,u,p,f,l=e.wrapper.bounds,h=!1,c=[];if(h=this.connectorProprtyChangeExtend(e,i,r,h),void 0!==r.visible&&this.updateElementVisibility(e.wrapper,e,e.visible),void 0!==r.sourcePoint||void 0!==r.targetPoint||void 0!==r.sourceID||void 0!==r.targetID||void 0!==r.targetPadding||void 0!==r.sourcePortID||void 0!==r.targetPortID||void 0!==r.sourcePadding||void 0!==r.type||void 0!==r.segments||void 0!==r.flip){if(void 0!==r.sourceID&&r.sourceID!==i.sourceID||r.sourcePortID){if(u=this.findInOutConnectPorts(g=this.nameTable[e.sourceID],!1),(!g||kh(g)||""!==e.sourcePortID&&Ad(u))&&(e.sourceWrapper=g?this.getEndNodeWrapper(g,e,!0):void 0,e.sourcePortID&&void 0===r.sourcePortID&&(e.sourcePortWrapper=g?this.getWrapper(g.wrapper,e.sourcePortID):void 0),this.removePortEdges(this.nameTable[i.sourceID]||g,i.sourcePortID||e.sourcePortID,e.id,!1)),void 0!==r.sourceID&&void 0!==i.sourceID&&""!==i.sourceID){var v=this.nameTable[i.sourceID];void 0!==v&&v.outEdges&&-1!==v.outEdges.indexOf(e.id)&&rm(v.outEdges,e.id)}this.updateEdges(e)}if(void 0!==r.targetID&&r.targetID!==i.targetID){if(d=this.findInOutConnectPorts(y=this.nameTable[r.targetID],!0),(!y||da(y)||""!==e.targetPortID&&Oh(d))&&(e.targetWrapper=y?this.getEndNodeWrapper(y,e,!1):void 0,e.targetPortID&&void 0===r.targetPortID&&(e.targetPortWrapper=y?this.getWrapper(y.wrapper,e.targetPortID):void 0),this.removePortEdges(this.nameTable[i.targetID]||y,i.targetPortID||e.targetPortID,e.id,!0)),void 0!==i&&void 0!==i.targetID&&""!==i.targetID){var S=this.nameTable[i.targetID];void 0!==S&&S.inEdges&&-1!==S.inEdges.indexOf(e.id)&&rm(S.inEdges,e.id)}this.updateEdges(e)}var g,y;void 0!==r.sourcePortID&&r.sourcePortID!==i.sourcePortID&&(e.sourceID&&this.nameTable[e.sourceID]&&(p=this.nameTable[e.sourceID].wrapper),!(g=this.nameTable[e.sourceID])||kh(g)||""!==e.sourcePortID&&Ad(u)?e.sourcePortWrapper=p?this.getWrapper(p,r.sourcePortID):void 0:""===e.sourcePortID&&!kh(g)&&(e.sourcePortWrapper=void 0)),void 0!==r.targetPortID&&r.targetPortID!==i.targetPortID&&(e.targetID&&this.nameTable[e.targetID]&&(f=this.nameTable[e.targetID].wrapper),!(y=this.nameTable[e.targetID])||da(y)||""!==e.targetPortID&&Oh(d)?e.targetPortWrapper=f?this.getWrapper(f,r.targetPortID):void 0:""===e.targetPortID&&!da(y)&&(e.targetPortWrapper=void 0)),void 0!==r.flip&&(e.flip=r.flip,EF(e)),"Orthogonal"===e.type&&this.lineRoutingModule&&this.diagramActions&&this.constraints&rt.LineRouting&&!(this.diagramActions&ee.ToolAction)&&"ComplexHierarchicalTree"!==this.layout.type&&(this.lineRoutingModule.renderVirtualRegion(this,!0),e.sourceID!==e.targetID&&e.segments.length>1&&this.lineRoutingModule.refreshConnectorSegments(this,e,!1)),c=this.getPoints(e)}void 0!==r.style&&Rh(r.style,e.wrapper.children[0]),(c.length>0||void 0!==r.sourceDecorator||void 0!==r.targetDecorator&&function qse(n){return-1!==n.indexOf("shape")||-1!==n.indexOf("pathData")||-1!==n.indexOf("width")||-1!==n.indexOf("height")}(Object.keys(r.targetDecorator))||void 0!==r.cornerRadius)&&(ef(e,c.length>0?c:e.intermediatePoints,this.diagramActions),void 0!==r.type&&(h=!0),c.length>0&&(e.wrapper.measure(new me(e.wrapper.width,e.wrapper.height)),e.wrapper.arrange(e.wrapper.desiredSize),this.updateConnectorAnnotation(e),this.updateConnectorPort(e),this.updateConnectorfixedUserHandles(e),this.updateObject(e,i,r))),(r.sourcePoint||r.targetPoint||r.segments)&&this.diagramActions===ee.Render&&(h=!0),"Bpmn"===e.shape.type&&"Default"===e.shape.sequence&&"Sequence"===e.shape.flow&&this.commandHandler.updatePathElementOffset(e),s||this.updateBridging(),this.updateAnnotations(r,e),this.updateConnectorPorts(r,e),this.updatefixedUserHandle(r,e),e.wrapper.measure(new me(e.wrapper.width,e.wrapper.height)),e.wrapper.arrange(e.wrapper.desiredSize),!1===l.equals(l,e.wrapper.bounds)&&(this.updateQuad(e),"Drag"!==this.eventHandler.currentAction&&this.updateGroupSize(e)),!0===h&&this.checkSelectedItem(e)&&(!(this.diagramActions&ee.ToolAction)||this.diagramActions&ee.UndoRedo)&&this.updateSelector(),this.preventConnectorsUpdate||(!Ds(this)||Ds(this)&&this.scroller.oldCollectionObjects.indexOf(e.id)>-1)&&(this.diagramActions&ee.PreventZIndexOnDragging?this.updateDiagramObject(e,!0):this.updateDiagramObject(e)),this.updateConnectorEdges(e),this.diagramActions&&"New"!==e.status&&(e.status="Update"),this.triggerPropertyChange(o,e,i,r)},t.prototype.removePortEdges=function(e,i,r,s){if(e)for(var o=0;o0&&e.id===s[s.length-1].id&&(r=!0),r},t.prototype.updateDiagramContainerVisibility=function(e,i){if(e instanceof Cs)for(var r=0;r>"),r instanceof Jn&&this.updateAnnotationWrapper(r,s,o,a)),void 0!==e.template&&(r.content=e.template,this.updateAnnotationWrapper(r,s,o,a))},t.prototype.updateAnnotationWrapper=function(e,i,r,s){for(var o=0,a=this.views;o=0&&this.nodes.splice(s,1),delete this.nameTable[""+r]}var o=this.nodes.indexOf(this.nameTable[this.currentSymbol.id]);o>=0&&this.nodes.splice(o,1)}},t.prototype.selectDragedNode=function(e,i,r){this.currentSymbol=e,"SVG"!==this.mode&&this.refreshDiagramLayer(),this.commandHandler.oldSelectedObjects=sm(this),this.commandHandler.select(e),this.eventHandler.mouseDown(i.event),this.eventHandler.mouseMove(i.event,i),this.preventDiagramUpdate=!1,this.updatePage(),r.style.opacity="0"},t.prototype.initDroppables=function(){var s,o,e=this,i={},r={},a="selectedSymbols";this.droppable=new lR(this.element);var l=5;this.droppable.over=function(h){if(e.rulerSettings.showRulers){var c=document.getElementById(e.element.id+"_vRuler"),d=parseFloat(c.style.width);l=d+1}if(0===e.previousSelectedObjects.length&&!e.currentSymbol&&(e.previousSelectedObjects=e.commandHandler.getSelectedObject()),e.commandHandler.PreventConnectorSplit=!0,e.currentSymbol)h.event.touches&&h.event.touches.length&&e.eventHandler.mouseMove(h.event,h.event.touches);else{var u=null;if(!h.dragData&&"drag"===h.name){var p=document.getElementsByClassName("e-dragclone")[0];p&&(u=p)}if(h.dragData||u){var f=void 0,g=void 0;document.getElementById(e.element.id+"content").focus();var v=e.eventHandler.getMousePosition(h.event),y=void 0,S=u||h.dragData.helper,b=S.getAttribute("paletteId"),M=void 0,w=void 0,C=void 0,D=void 0;if(!b&&h.dragData){e.triggerEvent(Ce.dragEnter,A={source:null,element:f,cancel:!1,diagram:e,dragData:h.dragData.draggedElement.ej2_instances[0].dragData,dragItem:f});var x=void 0,R=void 0;if(A.dragItem){if(A.dragItem.sourcePoint&&A.dragItem.targetPoint?R=new de(e,"connectors",A.dragItem,!0):x=new te(e,"nodes",A.dragItem,!0),e.initObject(f=x||R,void 0,void 0,!0),e.enterObject=f,e.enterTable=r,f instanceof te)x.offsetX=v.x+5+x.width*x.pivot.x,x.offsetY=v.y+x.height*x.pivot.y;else if(f instanceof de){var L=Ne.toBounds([f.sourcePoint,f.targetPoint]),O=v.x-L.left,N=v.y-L.top;f.sourcePoint.x+=O,f.sourcePoint.y+=N,f.targetPoint.x+=O,f.targetPoint.y+=N}e.preventDiagramUpdate=!0,e.currentSymbol=f,"SVG"!==e.mode&&e.refreshDiagramLayer(),e.selectDragedNode(f,h,S),delete e.enterObject,delete e.enterTable,e.droppable[""+a]=S,e.allowServerDataBinding=!0}}if(b){var T=document.getElementById(b).ej2_instances[0];if(e.droppable.sourceElement=T,T){var B=T[""+a];e.allowServerDataBinding=!1,y=$(T[""+a]),i=T.childTable;var j=B.wrapper.children[0].children[0];if(D=function $se(n,t,e){var i=AF(n,t,e,"width"),r=AF(n,t,e,"height");return new me(i,r)}(T,y,j),T[""+a]instanceof te){"TextAnnotation"===B.shape.shape?(y.offsetX=v.x+11+D.width*y.pivot.x,y.offsetY=v.y+11+D.height*y.pivot.y):(y.offsetX=v.x+5+D.width*y.pivot.x,y.offsetY=v.y+D.height*y.pivot.y),"Bpmn"===(x=new te(e,"nodes",y,!0)).shape.type&&x.shape.activity.subProcess.processes&&x.shape.activity.subProcess.processes.length&&(x.shape.activity.subProcess.processes=[]),w=x.previewSize,C=T.symbolDragSize;var Q=T.symbolPreview;if(x.width=(M=x.dragSize).width||C.width||w.width||Q.width||x.width,x.height=M.height||C.height||w.height||Q.height||x.height,"SwimLane"===x.shape.type){if(e.diagramActions|=ee.PreventHistory,x.shape.isLane){x.children=[],s={id:"header"+Qe()},"Horizontal"===x.shape.orientation?(s.width=x.shape.lanes[0].header.width,s.height=x.shape.lanes[0].height):(s.width=x.shape.lanes[0].width,s.height=x.shape.lanes[0].header.height),s.style=x.shape.lanes[0].header.style,s.offsetX=v.x+l+s.width/2,s.offsetY=v.y+s.height/2,e.diagramActions|=ee.PreventCollectionChangeOnDragOver,s=e.add(s),o={id:"body"+Qe()},"Horizontal"===x.shape.orientation?(o.width=x.shape.lanes[0].width-s.width,o.height=x.shape.lanes[0].height,o.offsetX=v.x+l+(x.shape.lanes[0].header.width+o.width/2),o.offsetY=v.y+o.height/2):(o.width=x.shape.lanes[0].width,o.height=x.shape.lanes[0].height-s.height,o.offsetX=v.x+l+o.width/2,o.offsetY=v.y+(x.shape.lanes[0].header.height+o.height/2)),o.style=x.shape.lanes[0].style,o=e.add(o);var oe={id:"group"+Qe(),children:[s.id,o.id]};oe.shape=x.shape,oe.width=x.shape.lanes[0].width,oe.height=x.shape.lanes[0].height,oe.previewSize=x.previewSize,oe.dragSize=x.dragSize,oe.addInfo=x.addInfo,x=e.add(oe),e.diagramActions&=~ee.PreventCollectionChangeOnDragOver}e.diagramActions&=~ee.PreventHistory}if(x.shape.isPhase&&((g="Horizontal"===x.shape.orientation)?(x.offsetX=v.x+l+(x.width||j.actualSize.width)/2,x.offsetY=v.y,x.shape.data="M20,"+x.height/2+" L"+(x.width-20)+","+x.height/2+"z",x.height=1):(x.offsetX=v.x+5,x.offsetY=v.y+(x.height||j.actualSize.height)/2,x.shape.data="M"+x.width/2+",20 L"+x.width/2+","+(x.height-20)+"z",x.width=1)),"UmlClassifier"===x.shape.type&&(x.children=x.width=x.height=void 0,y.children=void 0,"Class"===x.shape.classifier&&x.shape.classShape.methods.length<=0&&x.shape.classShape.attributes.length<=0&&(x.shape.classShape.attributes=[{name:"Name",type:"Type",style:{}}]),"Enumeration"===x.shape.classifier&&x.shape.enumerationShape.members.length<=0&&(x.shape.enumerationShape.members=[{name:"Name"}]),"Interface"===x.shape.classifier&&x.shape.interfaceShape.methods.length<=0&&x.shape.interfaceShape.attributes.length<=0&&(x.shape.interfaceShape.attributes=[{name:"Name",type:"Type",style:{}}])),f=x,y.children){var ue=y;r=e.getChildren(ue,{},i),rT(ue,-ue.offsetX,-ue.offsetY,r,!0,e)}}else if(T[""+a]instanceof de){f=new de(e,"connectors",y,!0);var Me=Ne.toBounds([f.sourcePoint,f.targetPoint]),De=v.x-Me.left,xe=v.y-Me.top;f.sourcePoint.x+=De,f.sourcePoint.y+=xe,f.targetPoint.x+=De,f.targetPoint.y+=xe}f.shape.isLane||(f.id+=Qe());var A={source:T,element:f,cancel:!1,diagram:e,dragData:null,dragItem:f};if(e.enterObject=f,e.enterTable=r,e.triggerEvent(Ce.dragEnter,A),f instanceof te&&"SwimLane"===f.shape.type&&f.shape.isLane){var Ie=A.element,Ve=Ie.shape.lanes[0];g="Horizontal"===Ie.shape.orientation;var ot=e.nameTable[f.children[0]],$e=e.nameTable[f.children[1]];w=f.previewSize,C=T.symbolDragSize,Ve.width=(M=f.dragSize).width||C.width||w.width||Ve.width,Ve.height=M.height||C.height||w.height||Ve.height,g?(s.width=Ve.header.width,s.height=Ve.height,o.width=Ve.width-s.width,o.height=Ve.height,o.offsetX=v.x+l+(Ve.header.width+$e.width/2),o.offsetY=v.y+$e.height/2):(s.width=Ve.width,s.height=Ve.header.height,o.width=Ve.width,o.height=Ve.height-s.height,o.offsetX=v.x+l+$e.width/2,o.offsetY=v.y+(Ve.header.height+$e.height/2)),s.offsetX=v.x+l+ot.width/2,s.offsetY=v.y+ot.height/2,f.width=Ve.width,f.height=Ve.height}if(f instanceof te&&f.shape.isPhase&&(g?f.height=1:f.width=1),!e.activeLayer.lock&&!A.cancel){if(e.preventDiagramUpdate=!0,f.children&&e.findChild(f,r),e.preventDiagramUpdate=!0,f.zIndex!==Number.MIN_VALUE&&(f.zIndex=Number.MIN_VALUE),e.initObject(f,void 0,void 0,!0),e.bpmnModule)for(var Mi=0;Mi0&&(S.segments=[]),d=this.add(S,!0)),(S||d)&&(jv(this)||Vv(this))&&this.select([this.nameTable[S[""+b]]],!1,this.previousSelectedObjects),y.target&&y.target instanceof de&&!0===this.enableConnectorSplit&&this.nameTable[S[""+b]]instanceof te&&(this.commandHandler.connectorSplit(this.nameTable[S[""+b]],y.target),this.commandHandler.PreventConnectorSplit=!1))),this.protectPropertyChange(!1),v=this.nameTable[S[""+b]],S.hasTarget&&(S.nodeId=S.hasTarget,this.remove(S)),this.bpmnModule&&v instanceof te&&S.processId&&(v.processId=S.processId,this.bpmnModule.dropBPMNchild(this.nameTable[v.processId],v,this)),y.cancel||this.endGroupAction(),"SVG"!==this.mode&&this.refreshDiagramLayer(),delete this.droppable[""+c]):(this.triggerEvent(Ce.drop,y={source:h.droppedElement,element:void 0,target:this.eventHandler.hoverNode||this.eventHandler.lastObjectUnderMouse||this,cancel:!1,position:void 0}),S=void 0,b="id"),this.droppable[M="selectedSymbols"]&&this.droppable[""+M].parentNode)gt(this.droppable[""+M]);else for(w=document.getElementsByClassName("e-dragclone"),C=0;C0)for(var p=0;p1),e.previousSelectedObject=null}}},t.prototype.getDropEventArgs=function(e){if(this.eventHandler.lastObjectUnderMouse||this.eventHandler.hoverNode){var i=this.eventHandler.lastObjectUnderMouse||this.eventHandler.hoverNode;e.target=fs(i)===de?{connector:i}:{node:i}}else e.target.diagramId=this.element.id},t.prototype.removeChildInNodes=function(e){if(e){if(e.children)for(var i=0;i1){var l=2;if(e.children&&e.children.length>0)for(;e.children.indexOf(i.objects[s-l])>-1;)l++;this.commandHandler.moveSvgNode(e.id,i.objects[s-l]),this.commandHandler.moveSvgNode(i.objects[s-l],e.id)}else if(o){var h=this.commandHandler.getLayer(this.layerZIndexTable[o.zIndex]).objects[0];h?(this.commandHandler.moveSvgNode(e.id,h),this.commandHandler.updateNativeNodeIndex(e.id,h)):this.moveObjectsUp(e,i)}else this.moveObjectsUp(e,i)},t.prototype.moveObjectsUp=function(e,i){for(var r,s=this.layers.length-1;s>=0;s--)if(r=this.layers[parseInt(s.toString(),10)],i.id!==r.id){var o=this.commandHandler.getLayer(this.layerZIndexTable[r.zIndex]).objects[r.objects.length-1];if(o){this.commandHandler.moveSvgNode(e.id,o),this.commandHandler.moveSvgNode(o,e.id);break}}},t.prototype.insertData=function(e){return this.crudOperation(e,"create",this.getNewUpdateNodes("New"))},t.prototype.updateData=function(e){return this.crudOperation(e,"update",this.getNewUpdateNodes("Update"))},t.prototype.removeData=function(e){return this.crudOperation(e,"destroy",this.getDeletedNodes())},t.prototype.crudOperation=function(e,i,r){if(e){var s=this.parameterMap(e,!(e instanceof de));if(s){var o=e instanceof de?this.dataSourceSettings.connectionDataSource.crudAction[""+i]:this.dataSourceSettings.crudAction[""+i];this.raiseAjaxPost(JSON.stringify(s),o)}return s}var a=r;return this.processCrudCollection(a,this.dataSourceSettings.crudAction[""+i],this.dataSourceSettings.connectionDataSource.crudAction[""+i]),a},t.prototype.processCrudCollection=function(e,i,r){if(e.nodes){var s=[],o=void 0;for(o=0;o0&&this.raiseAjaxPost(JSON.stringify(s),i)}if(e.connectors){for(s=[],o=void 0,o=0;o0&&this.raiseAjaxPost(JSON.stringify(s),r)}},t.prototype.parameterMap=function(e,i){var s,r={},o=i?this.dataSourceSettings:this.dataSourceSettings.connectionDataSource;if(o.id&&(r[o.id]=e.id),o.sourcePointX&&o.sourcePointY&&(r[o.sourcePointX]=e.sourcePoint.x,r[o.sourcePointY]=e.sourcePoint.y),o.targetPointX&&o.targetPointY&&(r[o.targetPointX]=e.targetPoint.x,r[o.targetPointY]=e.targetPoint.y),o.sourceID&&(r[o.sourceID]=e.sourceID),o.targetID&&(r[o.targetID]=e.targetID),o.crudAction&&o.crudAction.customFields&&o.crudAction.customFields.length>0)for(s=0;s{class n extends ch{constructor(e){super(),this.viewContainerRef=e,gl("currentInstance",this,this.viewContainerRef),this.registerEvents($ae),this.directivePropList=qae}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-layer"]],inputs:{addInfo:"addInfo",id:"id",lock:"lock",objects:"objects",visible:"visible",zIndex:"zIndex"},features:[yn]}),n})(),Jae=(()=>{class n extends dh{constructor(){super("layers")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-layers"]],contentQueries:function(e,i,r){if(1&e&&dn(r,Zae,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),Kae=["action","cursor"],ele=[],tle=(()=>{class n extends ch{constructor(e){super(),this.viewContainerRef=e,gl("currentInstance",this,this.viewContainerRef),this.registerEvents(ele),this.directivePropList=Kae}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-cursormap"]],inputs:{action:"action",cursor:"cursor"},features:[yn]}),n})(),ile=(()=>{class n extends dh{constructor(){super("customcursor")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-cursormaps"]],contentQueries:function(e,i,r){if(1&e&&dn(r,tle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),rle=["alignment","cornerRadius","displacement","fill","handleStrokeColor","handleStrokeWidth","height","iconStrokeColor","iconStrokeWidth","id","offset","padding","pathData","tooltip","visibility","width"],nle=[],sle=(()=>{class n extends ch{constructor(e){super(),this.viewContainerRef=e,gl("currentInstance",this,this.viewContainerRef),this.registerEvents(nle),this.directivePropList=rle}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-connector-fixeduserhandle"]],inputs:{alignment:"alignment",cornerRadius:"cornerRadius",displacement:"displacement",fill:"fill",handleStrokeColor:"handleStrokeColor",handleStrokeWidth:"handleStrokeWidth",height:"height",iconStrokeColor:"iconStrokeColor",iconStrokeWidth:"iconStrokeWidth",id:"id",offset:"offset",padding:"padding",pathData:"pathData",tooltip:"tooltip",visibility:"visibility",width:"width"},features:[yn]}),n})(),ole=(()=>{class n extends dh{constructor(){super("fixeduserhandles")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-connector-fixeduserhandles"]],contentQueries:function(e,i,r){if(1&e&&dn(r,sle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),ale=["addInfo","alignment","annotationType","constraints","content","displacement","dragLimit","height","horizontalAlignment","hyperlink","id","margin","offset","rotateAngle","rotationReference","segmentAngle","style","template","tooltip","type","verticalAlignment","visibility","width"],lle=[],hle=(()=>{class n extends ch{constructor(e){super(),this.viewContainerRef=e,gl("currentInstance",this,this.viewContainerRef),this.registerEvents(lle),this.directivePropList=ale}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-connector-annotation"]],inputs:{addInfo:"addInfo",alignment:"alignment",annotationType:"annotationType",constraints:"constraints",content:"content",displacement:"displacement",dragLimit:"dragLimit",height:"height",horizontalAlignment:"horizontalAlignment",hyperlink:"hyperlink",id:"id",margin:"margin",offset:"offset",rotateAngle:"rotateAngle",rotationReference:"rotationReference",segmentAngle:"segmentAngle",style:"style",template:"template",tooltip:"tooltip",type:"type",verticalAlignment:"verticalAlignment",visibility:"visibility",width:"width"},features:[yn]}),n})(),cle=(()=>{class n extends dh{constructor(){super("annotations")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-connector-annotations"]],contentQueries:function(e,i,r){if(1&e&&dn(r,hle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),dle=["addInfo","allowNodeOverlap","annotations","bezierSettings","bridgeSpace","connectionPadding","connectorSpacing","constraints","cornerRadius","dragSize","excludeFromLayout","fixedUserHandles","flip","flipMode","hitPadding","id","margin","maxSegmentThumb","ports","previewSize","segmentThumbShape","segmentThumbSize","segments","shape","sourceDecorator","sourceID","sourcePadding","sourcePoint","sourcePortID","style","symbolInfo","targetDecorator","targetID","targetPadding","targetPoint","targetPortID","tooltip","type","visible","wrapper","zIndex"],ule=[],ple=(()=>{class n extends ch{constructor(e){super(),this.viewContainerRef=e,this.tags=["fixedUserHandles","annotations"],gl("currentInstance",this,this.viewContainerRef),this.registerEvents(ule),this.directivePropList=dle}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-connector"]],contentQueries:function(e,i,r){if(1&e&&(dn(r,ole,5),dn(r,cle,5)),2&e){let s;Kr(s=en())&&(i.childFixedUserHandles=s.first),Kr(s=en())&&(i.childAnnotations=s.first)}},inputs:{addInfo:"addInfo",allowNodeOverlap:"allowNodeOverlap",annotations:"annotations",bezierSettings:"bezierSettings",bridgeSpace:"bridgeSpace",connectionPadding:"connectionPadding",connectorSpacing:"connectorSpacing",constraints:"constraints",cornerRadius:"cornerRadius",dragSize:"dragSize",excludeFromLayout:"excludeFromLayout",fixedUserHandles:"fixedUserHandles",flip:"flip",flipMode:"flipMode",hitPadding:"hitPadding",id:"id",margin:"margin",maxSegmentThumb:"maxSegmentThumb",ports:"ports",previewSize:"previewSize",segmentThumbShape:"segmentThumbShape",segmentThumbSize:"segmentThumbSize",segments:"segments",shape:"shape",sourceDecorator:"sourceDecorator",sourceID:"sourceID",sourcePadding:"sourcePadding",sourcePoint:"sourcePoint",sourcePortID:"sourcePortID",style:"style",symbolInfo:"symbolInfo",targetDecorator:"targetDecorator",targetID:"targetID",targetPadding:"targetPadding",targetPoint:"targetPoint",targetPortID:"targetPortID",tooltip:"tooltip",type:"type",visible:"visible",wrapper:"wrapper",zIndex:"zIndex"},features:[yn]}),n})(),fle=(()=>{class n extends dh{constructor(){super("connectors")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-connectors"]],contentQueries:function(e,i,r){if(1&e&&dn(r,ple,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),gle=["cornerRadius","fill","handleStrokeColor","handleStrokeWidth","height","iconStrokeColor","iconStrokeWidth","id","margin","offset","padding","pathData","tooltip","visibility","width"],vle=[],mle=(()=>{class n extends ch{constructor(e){super(),this.viewContainerRef=e,gl("currentInstance",this,this.viewContainerRef),this.registerEvents(vle),this.directivePropList=gle}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-node-fixeduserhandle"]],inputs:{cornerRadius:"cornerRadius",fill:"fill",handleStrokeColor:"handleStrokeColor",handleStrokeWidth:"handleStrokeWidth",height:"height",iconStrokeColor:"iconStrokeColor",iconStrokeWidth:"iconStrokeWidth",id:"id",margin:"margin",offset:"offset",padding:"padding",pathData:"pathData",tooltip:"tooltip",visibility:"visibility",width:"width"},features:[yn]}),n})(),yle=(()=>{class n extends dh{constructor(){super("fixeduserhandles")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-node-fixeduserhandles"]],contentQueries:function(e,i,r){if(1&e&&dn(r,mle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),Sle=["addInfo","annotationType","constraints","content","dragLimit","height","horizontalAlignment","hyperlink","id","margin","offset","rotateAngle","rotationReference","style","template","tooltip","type","verticalAlignment","visibility","width"],Ile=[],v_=(()=>{class n extends ch{constructor(e){super(),this.viewContainerRef=e,gl("currentInstance",this,this.viewContainerRef),this.registerEvents(Ile),this.directivePropList=Sle}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-node-annotation"]],inputs:{addInfo:"addInfo",annotationType:"annotationType",constraints:"constraints",content:"content",dragLimit:"dragLimit",height:"height",horizontalAlignment:"horizontalAlignment",hyperlink:"hyperlink",id:"id",margin:"margin",offset:"offset",rotateAngle:"rotateAngle",rotationReference:"rotationReference",style:"style",template:"template",tooltip:"tooltip",type:"type",verticalAlignment:"verticalAlignment",visibility:"visibility",width:"width"},features:[yn]}),n})(),m_=(()=>{class n extends dh{constructor(){super("annotations")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-node-annotations"]],contentQueries:function(e,i,r){if(1&e&&dn(r,v_,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),ble=["addInfo","connectionDirection","constraints","height","horizontalAlignment","id","inEdges","margin","offset","outEdges","pathData","shape","style","tooltip","verticalAlignment","visibility","width"],Mle=[],wle=(()=>{class n extends ch{constructor(e){super(),this.viewContainerRef=e,gl("currentInstance",this,this.viewContainerRef),this.registerEvents(Mle),this.directivePropList=ble}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-node-port"]],inputs:{addInfo:"addInfo",connectionDirection:"connectionDirection",constraints:"constraints",height:"height",horizontalAlignment:"horizontalAlignment",id:"id",inEdges:"inEdges",margin:"margin",offset:"offset",outEdges:"outEdges",pathData:"pathData",shape:"shape",style:"style",tooltip:"tooltip",verticalAlignment:"verticalAlignment",visibility:"visibility",width:"width"},features:[yn]}),n})(),Cle=(()=>{class n extends dh{constructor(){super("ports")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-node-ports"]],contentQueries:function(e,i,r){if(1&e&&dn(r,wle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),Ele=["addInfo","annotations","backgroundColor","borderColor","borderWidth","branch","children","collapseIcon","columnIndex","columnSpan","columns","constraints","container","data","dragSize","excludeFromLayout","expandIcon","fixedUserHandles","flip","flipMode","height","horizontalAlignment","id","isExpanded","layoutInfo","margin","maxHeight","maxWidth","minHeight","minWidth","offsetX","offsetY","padding","pivot","ports","previewSize","rotateAngle","rowIndex","rowSpan","rows","shadow","shape","style","symbolInfo","tooltip","verticalAlignment","visible","width","wrapper","zIndex"],Dle=[],y_=(()=>{class n extends ch{constructor(e){super(),this.viewContainerRef=e,this.tags=["fixedUserHandles","annotations","ports"],gl("currentInstance",this,this.viewContainerRef),this.registerEvents(Dle),this.directivePropList=Ele}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-node"]],contentQueries:function(e,i,r){if(1&e&&(dn(r,yle,5),dn(r,m_,5),dn(r,Cle,5)),2&e){let s;Kr(s=en())&&(i.childFixedUserHandles=s.first),Kr(s=en())&&(i.childAnnotations=s.first),Kr(s=en())&&(i.childPorts=s.first)}},inputs:{addInfo:"addInfo",annotations:"annotations",backgroundColor:"backgroundColor",borderColor:"borderColor",borderWidth:"borderWidth",branch:"branch",children:"children",collapseIcon:"collapseIcon",columnIndex:"columnIndex",columnSpan:"columnSpan",columns:"columns",constraints:"constraints",container:"container",data:"data",dragSize:"dragSize",excludeFromLayout:"excludeFromLayout",expandIcon:"expandIcon",fixedUserHandles:"fixedUserHandles",flip:"flip",flipMode:"flipMode",height:"height",horizontalAlignment:"horizontalAlignment",id:"id",isExpanded:"isExpanded",layoutInfo:"layoutInfo",margin:"margin",maxHeight:"maxHeight",maxWidth:"maxWidth",minHeight:"minHeight",minWidth:"minWidth",offsetX:"offsetX",offsetY:"offsetY",padding:"padding",pivot:"pivot",ports:"ports",previewSize:"previewSize",rotateAngle:"rotateAngle",rowIndex:"rowIndex",rowSpan:"rowSpan",rows:"rows",shadow:"shadow",shape:"shape",style:"style",symbolInfo:"symbolInfo",tooltip:"tooltip",verticalAlignment:"verticalAlignment",visible:"visible",width:"width",wrapper:"wrapper",zIndex:"zIndex"},features:[yn]}),n})(),S_=(()=>{class n extends dh{constructor(){super("nodes")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-nodes"]],contentQueries:function(e,i,r){if(1&e&&dn(r,y_,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})();const xle=["animationComplete","click","collectionChange","commandExecute","connectionChange","contextMenuBeforeItemRender","contextMenuClick","contextMenuOpen","created","dataLoaded","doubleClick","dragEnter","dragLeave","dragOver","drop","elementDraw","expandStateChange","fixedUserHandleClick","historyChange","historyStateChange","keyDown","keyUp","load","loaded","mouseEnter","mouseLeave","mouseOver","mouseWheel","onFixedUserHandleMouseDown","onFixedUserHandleMouseEnter","onFixedUserHandleMouseLeave","onFixedUserHandleMouseUp","onImageLoad","onUserHandleMouseDown","onUserHandleMouseEnter","onUserHandleMouseLeave","onUserHandleMouseUp","positionChange","propertyChange","rotateChange","scrollChange","segmentChange","segmentCollectionChange","selectionChange","sizeChange","sourcePointChange","targetPointChange","textEdit"],Tle=[""];let Ale=(()=>{let n=class extends Rl{constructor(e,i,r,s){super(),this.ngEle=e,this.srenderer=i,this.viewContainerRef=r,this.injector=s,this.tags=["layers","customCursor","connectors","nodes"],this.element=this.ngEle.nativeElement,this.injectedModules=this.injectedModules||[];try{let o=this.injector.get("DiagramsHierarchicalTree");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsMindMap");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsRadialTree");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsComplexHierarchicalTree");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsDataBinding");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsSnapping");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsPrintAndExport");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsBpmnDiagrams");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsSymmetricLayout");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsConnectorBridging");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsUndoRedo");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsLayoutAnimation");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsDiagramContextMenu");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsLineRouting");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsConnectorEditing");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsLineDistribution");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsEj1Serialization");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsFlowchartLayout");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}this.registerEvents(xle),this.addTwoWay.call(this,Tle),gl("currentInstance",this,this.viewContainerRef),this.context=new SR}ngOnInit(){this.context.ngOnInit(this)}ngAfterViewInit(){this.context.ngAfterViewInit(this)}ngOnDestroy(){this.context.ngOnDestroy(this)}ngAfterContentChecked(){this.tagObjects[0].instance=this.childLayers,this.childCustomCursor&&(this.tagObjects[1].instance=this.childCustomCursor),this.childConnectors&&(this.tagObjects[2].instance=this.childConnectors),this.childNodes&&(this.tagObjects[3].instance=this.childNodes),this.context.ngAfterContentChecked(this)}};return n.\u0275fac=function(e){return new(e||n)(Ot($c),Ot(hM),Ot(xn),Ot(Wo))},n.\u0275cmp=Fb({type:n,selectors:[["ejs-diagram"]],contentQueries:function(e,i,r){if(1&e&&(dn(r,Qae,5),dn(r,Gae,5),dn(r,Xae,5),dn(r,Jae,5),dn(r,ile,5),dn(r,fle,5),dn(r,S_,5)),2&e){let s;Kr(s=en())&&(i.annotationTemplate=s.first),Kr(s=en())&&(i.nodeTemplate=s.first),Kr(s=en())&&(i.userHandleTemplate=s.first),Kr(s=en())&&(i.childLayers=s.first),Kr(s=en())&&(i.childCustomCursor=s.first),Kr(s=en())&&(i.childConnectors=s.first),Kr(s=en())&&(i.childNodes=s.first)}},inputs:{addInfo:"addInfo",annotationTemplate:"annotationTemplate",backgroundColor:"backgroundColor",bridgeDirection:"bridgeDirection",commandManager:"commandManager",connectorDefaults:"connectorDefaults",connectors:"connectors",constraints:"constraints",contextMenuSettings:"contextMenuSettings",customCursor:"customCursor",dataSourceSettings:"dataSourceSettings",diagramSettings:"diagramSettings",drawingObject:"drawingObject",enableConnectorSplit:"enableConnectorSplit",enablePersistence:"enablePersistence",enableRtl:"enableRtl",fixedUserHandleTemplate:"fixedUserHandleTemplate",getConnectorDefaults:"getConnectorDefaults",getCustomCursor:"getCustomCursor",getCustomProperty:"getCustomProperty",getCustomTool:"getCustomTool",getDescription:"getDescription",getNodeDefaults:"getNodeDefaults",height:"height",historyManager:"historyManager",layers:"layers",layout:"layout",locale:"locale",mode:"mode",nodeDefaults:"nodeDefaults",nodeTemplate:"nodeTemplate",nodes:"nodes",pageSettings:"pageSettings",rulerSettings:"rulerSettings",scrollSettings:"scrollSettings",segmentThumbShape:"segmentThumbShape",segmentThumbSize:"segmentThumbSize",selectedItems:"selectedItems",serializationSettings:"serializationSettings",setNodeTemplate:"setNodeTemplate",snapSettings:"snapSettings",tool:"tool",tooltip:"tooltip",updateSelection:"updateSelection",userHandleTemplate:"userHandleTemplate",width:"width"},outputs:{animationComplete:"animationComplete",click:"click",collectionChange:"collectionChange",commandExecute:"commandExecute",connectionChange:"connectionChange",contextMenuBeforeItemRender:"contextMenuBeforeItemRender",contextMenuClick:"contextMenuClick",contextMenuOpen:"contextMenuOpen",created:"created",dataLoaded:"dataLoaded",doubleClick:"doubleClick",dragEnter:"dragEnter",dragLeave:"dragLeave",dragOver:"dragOver",drop:"drop",elementDraw:"elementDraw",expandStateChange:"expandStateChange",fixedUserHandleClick:"fixedUserHandleClick",historyChange:"historyChange",historyStateChange:"historyStateChange",keyDown:"keyDown",keyUp:"keyUp",load:"load",loaded:"loaded",mouseEnter:"mouseEnter",mouseLeave:"mouseLeave",mouseOver:"mouseOver",mouseWheel:"mouseWheel",onFixedUserHandleMouseDown:"onFixedUserHandleMouseDown",onFixedUserHandleMouseEnter:"onFixedUserHandleMouseEnter",onFixedUserHandleMouseLeave:"onFixedUserHandleMouseLeave",onFixedUserHandleMouseUp:"onFixedUserHandleMouseUp",onImageLoad:"onImageLoad",onUserHandleMouseDown:"onUserHandleMouseDown",onUserHandleMouseEnter:"onUserHandleMouseEnter",onUserHandleMouseLeave:"onUserHandleMouseLeave",onUserHandleMouseUp:"onUserHandleMouseUp",positionChange:"positionChange",propertyChange:"propertyChange",rotateChange:"rotateChange",scrollChange:"scrollChange",segmentChange:"segmentChange",segmentCollectionChange:"segmentCollectionChange",selectionChange:"selectionChange",sizeChange:"sizeChange",sourcePointChange:"sourcePointChange",targetPointChange:"targetPointChange",textEdit:"textEdit"},features:[yn],decls:0,vars:0,template:function(e,i){},encapsulation:2,changeDetection:0}),O0([DC()],n.prototype,"annotationTemplate",void 0),O0([DC()],n.prototype,"nodeTemplate",void 0),O0([DC()],n.prototype,"userHandleTemplate",void 0),n=O0([PZ([SR])],n),n})(),Lle=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Nm({type:n}),n.\u0275inj=yf({imports:[[sq]]}),n})();const Nle=["diagram"];let Ole=(()=>{class n{constructor(){this.layers=[]}ngOnInit(){this.layers=[{id:"layer1",objects:["node1","node2"]},{id:"layers2",objects:["node3"]}]}moveObjects(){this.diagram.moveObjects(["node1"],"layer2")}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275cmp=Fb({type:n,selectors:[["app-container"]],viewQuery:function(i,r){if(1&i&&function uP(n,t,e){const i=xi();i.firstCreatePass&&(cP(i,new aP(n,t,e),-1),2==(2&t)&&(i.staticViewQueries=!0)),hP(i,Se(),t)}(Nle,5),2&i){let s;Kr(s=en())&&(r.diagram=s.first)}},standalone:!0,features:[PP([]),RP],decls:14,vars:13,consts:[["id","diagram","width","100%","height","580px",3,"layers"],["diagram",""],["id","node1",3,"width","height","offsetX","offsetY"],["content","Layer 1 Object"],["id","node2",3,"width","height","offsetX","offsetY"],["id","node3",3,"width","height","offsetX","offsetY"],["content","Layer 2 Object"],[3,"click"]],template:function(i,r){1&i&&(id(0,"ejs-diagram",0,1)(2,"e-nodes")(3,"e-node",2)(4,"e-node-annotations"),dg(5,"e-node-annotation",3),rd()(),id(6,"e-node",4)(7,"e-node-annotations"),dg(8,"e-node-annotation",3),rd()(),id(9,"e-node",5)(10,"e-node-annotations"),dg(11,"e-node-annotation",6),rd()()()(),id(12,"button",7),aw("click",function(){return r.moveObjects()}),function MP(n,t=""){const e=Se(),i=xi(),r=n+Ut,s=i.firstCreatePass?Au(i,r,1,t,null):i.data[r],o=wP(i,e,s,t,n);e[r]=o,Bm()&&cy(i,e,o,s),ol(s,!1)}(13,"moveObjects"),rd()),2&i&&(Xu("layers",r.layers),Ey(3),Xu("width",100)("height",100)("offsetX",100)("offsetY",100),Ey(3),Xu("width",100)("height",100)("offsetX",100)("offsetY",300),Ey(3),Xu("width",100)("height",100)("offsetX",300)("offsetY",300))},dependencies:[Lle,Ale,v_,m_,y_,S_],encapsulation:2})}}return n})();Vd(332),function $q(n,t){return DG({rootComponent:n,...Ez(t)})}(Ole).catch(n=>console.error(n))},332:()=>{!function(Z){const se=Z.performance;function ye(Pi){se&&se.mark&&se.mark(Pi)}function fe(Pi,ht){se&&se.measure&&se.measure(Pi,ht)}ye("Zone");const be=Z.__Zone_symbol_prefix||"__zone_symbol__";function ke(Pi){return be+Pi}const at=!0===Z[ke("forceDuplicateZoneCheck")];if(Z.Zone){if(at||"function"!=typeof Z.Zone.__symbol__)throw new Error("Zone already loaded.");return Z.Zone}let tt=(()=>{class Pi{static{this.__symbol__=ke}static assertZonePatched(){if(Z.Promise!==_o.ZoneAwarePromise)throw new Error("Zone.js has detected that ZoneAwarePromise `(window|global).Promise` has been overwritten.\nMost likely cause is that a Promise polyfill has been loaded after Zone.js (Polyfilling Promise api is not necessary when zone.js is loaded. If you must load one, do so before loading zone.js.)")}static get root(){let F=Pi.current;for(;F.parent;)F=F.parent;return F}static get current(){return Ur.zone}static get currentTask(){return Do}static __load_patch(F,ae,Et=!1){if(_o.hasOwnProperty(F)){if(!Et&&at)throw Error("Already loaded patch: "+F)}else if(!Z["__Zone_disable_"+F]){const Xt="Zone:"+F;ye(Xt),_o[F]=ae(Z,Pi,cn),fe(Xt,Xt)}}get parent(){return this._parent}get name(){return this._name}constructor(F,ae){this._parent=F,this._name=ae?ae.name||"unnamed":"",this._properties=ae&&ae.properties||{},this._zoneDelegate=new Lt(this,this._parent&&this._parent._zoneDelegate,ae)}get(F){const ae=this.getZoneWith(F);if(ae)return ae._properties[F]}getZoneWith(F){let ae=this;for(;ae;){if(ae._properties.hasOwnProperty(F))return ae;ae=ae._parent}return null}fork(F){if(!F)throw new Error("ZoneSpec required!");return this._zoneDelegate.fork(this,F)}wrap(F,ae){if("function"!=typeof F)throw new Error("Expecting function got: "+F);const Et=this._zoneDelegate.intercept(this,F,ae),Xt=this;return function(){return Xt.runGuarded(Et,this,arguments,ae)}}run(F,ae,Et,Xt){Ur={parent:Ur,zone:this};try{return this._zoneDelegate.invoke(this,F,ae,Et,Xt)}finally{Ur=Ur.parent}}runGuarded(F,ae=null,Et,Xt){Ur={parent:Ur,zone:this};try{try{return this._zoneDelegate.invoke(this,F,ae,Et,Xt)}catch(Un){if(this._zoneDelegate.handleError(this,Un))throw Un}}finally{Ur=Ur.parent}}runTask(F,ae,Et){if(F.zone!=this)throw new Error("A task can only be run in the zone of creation! (Creation: "+(F.zone||_n).name+"; Execution: "+this.name+")");if(F.state===sr&&(F.type===ts||F.type===Pt))return;const Xt=F.state!=lt;Xt&&F._transitionTo(lt,ki),F.runCount++;const Un=Do;Do=F,Ur={parent:Ur,zone:this};try{F.type==Pt&&F.data&&!F.data.isPeriodic&&(F.cancelFn=void 0);try{return this._zoneDelegate.invokeTask(this,F,ae,Et)}catch(Ue){if(this._zoneDelegate.handleError(this,Ue))throw Ue}}finally{F.state!==sr&&F.state!==et&&(F.type==ts||F.data&&F.data.isPeriodic?Xt&&F._transitionTo(ki,lt):(F.runCount=0,this._updateTaskCount(F,-1),Xt&&F._transitionTo(sr,lt,sr))),Ur=Ur.parent,Do=Un}}scheduleTask(F){if(F.zone&&F.zone!==this){let Et=this;for(;Et;){if(Et===F.zone)throw Error(`can not reschedule task to ${this.name} which is descendants of the original zone ${F.zone.name}`);Et=Et.parent}}F._transitionTo(Zr,sr);const ae=[];F._zoneDelegates=ae,F._zone=this;try{F=this._zoneDelegate.scheduleTask(this,F)}catch(Et){throw F._transitionTo(et,Zr,sr),this._zoneDelegate.handleError(this,Et),Et}return F._zoneDelegates===ae&&this._updateTaskCount(F,1),F.state==Zr&&F._transitionTo(ki,Zr),F}scheduleMicroTask(F,ae,Et,Xt){return this.scheduleTask(new ft(vi,F,ae,Et,Xt,void 0))}scheduleMacroTask(F,ae,Et,Xt,Un){return this.scheduleTask(new ft(Pt,F,ae,Et,Xt,Un))}scheduleEventTask(F,ae,Et,Xt,Un){return this.scheduleTask(new ft(ts,F,ae,Et,Xt,Un))}cancelTask(F){if(F.zone!=this)throw new Error("A task can only be cancelled in the zone of creation! (Creation: "+(F.zone||_n).name+"; Execution: "+this.name+")");if(F.state===ki||F.state===lt){F._transitionTo(dr,ki,lt);try{this._zoneDelegate.cancelTask(this,F)}catch(ae){throw F._transitionTo(et,dr),this._zoneDelegate.handleError(this,ae),ae}return this._updateTaskCount(F,-1),F._transitionTo(sr,dr),F.runCount=0,F}}_updateTaskCount(F,ae){const Et=F._zoneDelegates;-1==ae&&(F._zoneDelegates=null);for(let Xt=0;XtPi.hasTask(F,ae),onScheduleTask:(Pi,ht,F,ae)=>Pi.scheduleTask(F,ae),onInvokeTask:(Pi,ht,F,ae,Et,Xt)=>Pi.invokeTask(F,ae,Et,Xt),onCancelTask:(Pi,ht,F,ae)=>Pi.cancelTask(F,ae)};class Lt{constructor(ht,F,ae){this._taskCounts={microTask:0,macroTask:0,eventTask:0},this.zone=ht,this._parentDelegate=F,this._forkZS=ae&&(ae&&ae.onFork?ae:F._forkZS),this._forkDlgt=ae&&(ae.onFork?F:F._forkDlgt),this._forkCurrZone=ae&&(ae.onFork?this.zone:F._forkCurrZone),this._interceptZS=ae&&(ae.onIntercept?ae:F._interceptZS),this._interceptDlgt=ae&&(ae.onIntercept?F:F._interceptDlgt),this._interceptCurrZone=ae&&(ae.onIntercept?this.zone:F._interceptCurrZone),this._invokeZS=ae&&(ae.onInvoke?ae:F._invokeZS),this._invokeDlgt=ae&&(ae.onInvoke?F:F._invokeDlgt),this._invokeCurrZone=ae&&(ae.onInvoke?this.zone:F._invokeCurrZone),this._handleErrorZS=ae&&(ae.onHandleError?ae:F._handleErrorZS),this._handleErrorDlgt=ae&&(ae.onHandleError?F:F._handleErrorDlgt),this._handleErrorCurrZone=ae&&(ae.onHandleError?this.zone:F._handleErrorCurrZone),this._scheduleTaskZS=ae&&(ae.onScheduleTask?ae:F._scheduleTaskZS),this._scheduleTaskDlgt=ae&&(ae.onScheduleTask?F:F._scheduleTaskDlgt),this._scheduleTaskCurrZone=ae&&(ae.onScheduleTask?this.zone:F._scheduleTaskCurrZone),this._invokeTaskZS=ae&&(ae.onInvokeTask?ae:F._invokeTaskZS),this._invokeTaskDlgt=ae&&(ae.onInvokeTask?F:F._invokeTaskDlgt),this._invokeTaskCurrZone=ae&&(ae.onInvokeTask?this.zone:F._invokeTaskCurrZone),this._cancelTaskZS=ae&&(ae.onCancelTask?ae:F._cancelTaskZS),this._cancelTaskDlgt=ae&&(ae.onCancelTask?F:F._cancelTaskDlgt),this._cancelTaskCurrZone=ae&&(ae.onCancelTask?this.zone:F._cancelTaskCurrZone),this._hasTaskZS=null,this._hasTaskDlgt=null,this._hasTaskDlgtOwner=null,this._hasTaskCurrZone=null;const Et=ae&&ae.onHasTask;(Et||F&&F._hasTaskZS)&&(this._hasTaskZS=Et?ae:At,this._hasTaskDlgt=F,this._hasTaskDlgtOwner=this,this._hasTaskCurrZone=ht,ae.onScheduleTask||(this._scheduleTaskZS=At,this._scheduleTaskDlgt=F,this._scheduleTaskCurrZone=this.zone),ae.onInvokeTask||(this._invokeTaskZS=At,this._invokeTaskDlgt=F,this._invokeTaskCurrZone=this.zone),ae.onCancelTask||(this._cancelTaskZS=At,this._cancelTaskDlgt=F,this._cancelTaskCurrZone=this.zone))}fork(ht,F){return this._forkZS?this._forkZS.onFork(this._forkDlgt,this.zone,ht,F):new tt(ht,F)}intercept(ht,F,ae){return this._interceptZS?this._interceptZS.onIntercept(this._interceptDlgt,this._interceptCurrZone,ht,F,ae):F}invoke(ht,F,ae,Et,Xt){return this._invokeZS?this._invokeZS.onInvoke(this._invokeDlgt,this._invokeCurrZone,ht,F,ae,Et,Xt):F.apply(ae,Et)}handleError(ht,F){return!this._handleErrorZS||this._handleErrorZS.onHandleError(this._handleErrorDlgt,this._handleErrorCurrZone,ht,F)}scheduleTask(ht,F){let ae=F;if(this._scheduleTaskZS)this._hasTaskZS&&ae._zoneDelegates.push(this._hasTaskDlgtOwner),ae=this._scheduleTaskZS.onScheduleTask(this._scheduleTaskDlgt,this._scheduleTaskCurrZone,ht,F),ae||(ae=F);else if(F.scheduleFn)F.scheduleFn(F);else{if(F.type!=vi)throw new Error("Task is missing scheduleFn.");Wt(F)}return ae}invokeTask(ht,F,ae,Et){return this._invokeTaskZS?this._invokeTaskZS.onInvokeTask(this._invokeTaskDlgt,this._invokeTaskCurrZone,ht,F,ae,Et):F.callback.apply(ae,Et)}cancelTask(ht,F){let ae;if(this._cancelTaskZS)ae=this._cancelTaskZS.onCancelTask(this._cancelTaskDlgt,this._cancelTaskCurrZone,ht,F);else{if(!F.cancelFn)throw Error("Task is not cancelable");ae=F.cancelFn(F)}return ae}hasTask(ht,F){try{this._hasTaskZS&&this._hasTaskZS.onHasTask(this._hasTaskDlgt,this._hasTaskCurrZone,ht,F)}catch(ae){this.handleError(ht,ae)}}_updateTaskCount(ht,F){const ae=this._taskCounts,Et=ae[ht],Xt=ae[ht]=Et+F;if(Xt<0)throw new Error("More tasks executed then were scheduled.");0!=Et&&0!=Xt||this.hasTask(this.zone,{microTask:ae.microTask>0,macroTask:ae.macroTask>0,eventTask:ae.eventTask>0,change:ht})}}class ft{constructor(ht,F,ae,Et,Xt,Un){if(this._zone=null,this.runCount=0,this._zoneDelegates=null,this._state="notScheduled",this.type=ht,this.source=F,this.data=Et,this.scheduleFn=Xt,this.cancelFn=Un,!ae)throw new Error("callback is not defined");this.callback=ae;const Ue=this;this.invoke=ht===ts&&Et&&Et.useG?ft.invokeTask:function(){return ft.invokeTask.call(Z,Ue,this,arguments)}}static invokeTask(ht,F,ae){ht||(ht=this),Ls++;try{return ht.runCount++,ht.zone.runTask(ht,F,ae)}finally{1==Ls&&ct(),Ls--}}get zone(){return this._zone}get state(){return this._state}cancelScheduleRequest(){this._transitionTo(sr,Zr)}_transitionTo(ht,F,ae){if(this._state!==F&&this._state!==ae)throw new Error(`${this.type} '${this.source}': can not transition to '${ht}', expecting state '${F}'${ae?" or '"+ae+"'":""}, was '${this._state}'.`);this._state=ht,ht==sr&&(this._zoneDelegates=null)}toString(){return this.data&&typeof this.data.handleId<"u"?this.data.handleId.toString():Object.prototype.toString.call(this)}toJSON(){return{type:this.type,state:this.state,source:this.source,zone:this.zone.name,runCount:this.runCount}}}const Ei=ke("setTimeout"),ti=ke("Promise"),gi=ke("then");let es,cr=[],Oi=!1;function kr(Pi){if(es||Z[ti]&&(es=Z[ti].resolve(0)),es){let ht=es[gi];ht||(ht=es.then),ht.call(es,Pi)}else Z[Ei](Pi,0)}function Wt(Pi){0===Ls&&0===cr.length&&kr(ct),Pi&&cr.push(Pi)}function ct(){if(!Oi){for(Oi=!0;cr.length;){const Pi=cr;cr=[];for(let ht=0;htUr,onUnhandledError:jr,microtaskDrainDone:jr,scheduleMicroTask:Wt,showUncaughtError:()=>!tt[ke("ignoreConsoleErrorUncaughtError")],patchEventTarget:()=>[],patchOnProperties:jr,patchMethod:()=>jr,bindArguments:()=>[],patchThen:()=>jr,patchMacroTask:()=>jr,patchEventPrototype:()=>jr,isIEOrEdge:()=>!1,getGlobalObjects:()=>{},ObjectDefineProperty:()=>jr,ObjectGetOwnPropertyDescriptor:()=>{},ObjectCreate:()=>{},ArraySlice:()=>[],patchClass:()=>jr,wrapWithCurrentZone:()=>jr,filterProperties:()=>[],attachOriginToPatched:()=>jr,_redefineProperty:()=>jr,patchCallbacks:()=>jr,nativeScheduleMicroTask:kr};let Ur={parent:null,zone:new tt(null,null)},Do=null,Ls=0;function jr(){}fe("Zone","Zone"),Z.Zone=tt}(globalThis);const _l=Object.getOwnPropertyDescriptor,jd=Object.defineProperty,Vd=Object.getPrototypeOf,Wd=Object.create,yb=Array.prototype.slice,gm="addEventListener",$r="removeEventListener",Ul=Zone.__symbol__(gm),Fh=Zone.__symbol__($r),Ts="true",Wi="false",Yd=Zone.__symbol__("");function hf(Z,se){return Zone.current.wrap(Z,se)}function vm(Z,se,ye,fe,be){return Zone.current.scheduleMacroTask(Z,se,ye,fe,be)}const Ji=Zone.__symbol__,_h=typeof window<"u",Uh=_h?window:void 0,gn=_h&&Uh||globalThis,mm="removeAttribute";function Qd(Z,se){for(let ye=Z.length-1;ye>=0;ye--)"function"==typeof Z[ye]&&(Z[ye]=hf(Z[ye],se+"_"+ye));return Z}function cf(Z){return!Z||!1!==Z.writable&&!("function"==typeof Z.get&&typeof Z.set>"u")}const df=typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope,jh=!("nw"in gn)&&typeof gn.process<"u"&&"[object process]"==={}.toString.call(gn.process),Gd=!jh&&!df&&!(!_h||!Uh.HTMLElement),uf=typeof gn.process<"u"&&"[object process]"==={}.toString.call(gn.process)&&!df&&!(!_h||!Uh.HTMLElement),jl={},Vh=function(Z){if(!(Z=Z||gn.event))return;let se=jl[Z.type];se||(se=jl[Z.type]=Ji("ON_PROPERTY"+Z.type));const ye=this||Z.target||gn,fe=ye[se];let be;return Gd&&ye===Uh&&"error"===Z.type?(be=fe&&fe.call(this,Z.message,Z.filename,Z.lineno,Z.colno,Z.error),!0===be&&Z.preventDefault()):(be=fe&&fe.apply(this,arguments),null!=be&&!be&&Z.preventDefault()),be};function Vl(Z,se,ye){let fe=_l(Z,se);if(!fe&&ye&&_l(ye,se)&&(fe={enumerable:!0,configurable:!0}),!fe||!fe.configurable)return;const be=Ji("on"+se+"patched");if(Z.hasOwnProperty(be)&&Z[be])return;delete fe.writable,delete fe.value;const ke=fe.get,at=fe.set,tt=se.slice(2);let At=jl[tt];At||(At=jl[tt]=Ji("ON_PROPERTY"+tt)),fe.set=function(Lt){let ft=this;!ft&&Z===gn&&(ft=gn),ft&&("function"==typeof ft[At]&&ft.removeEventListener(tt,Vh),at&&at.call(ft,null),ft[At]=Lt,"function"==typeof Lt&&ft.addEventListener(tt,Vh,!1))},fe.get=function(){let Lt=this;if(!Lt&&Z===gn&&(Lt=gn),!Lt)return null;const ft=Lt[At];if(ft)return ft;if(ke){let Ei=ke.call(this);if(Ei)return fe.set.call(this,Ei),"function"==typeof Lt[mm]&&Lt.removeAttribute(se),Ei}return null},jd(Z,se,fe),Z[be]=!0}function pf(Z,se,ye){if(se)for(let fe=0;fefunction(at,tt){const At=ye(at,tt);return At.cbIdx>=0&&"function"==typeof tt[At.cbIdx]?vm(At.name,tt[At.cbIdx],At,be):ke.apply(at,tt)})}function Sa(Z,se){Z[Ji("OriginalDelegate")]=se}let Ib=!1,qd=!1;function bb(){if(Ib)return qd;Ib=!0;try{const Z=Uh.navigator.userAgent;(-1!==Z.indexOf("MSIE ")||-1!==Z.indexOf("Trident/")||-1!==Z.indexOf("Edge/"))&&(qd=!0)}catch{}return qd}Zone.__load_patch("ZoneAwarePromise",(Z,se,ye)=>{const fe=Object.getOwnPropertyDescriptor,be=Object.defineProperty,at=ye.symbol,tt=[],At=!1!==Z[at("DISABLE_WRAPPING_UNCAUGHT_PROMISE_REJECTION")],Lt=at("Promise"),ft=at("then"),Ei="__creationTrace__";ye.onUnhandledError=Ue=>{if(ye.showUncaughtError()){const He=Ue&&Ue.rejection;He?console.error("Unhandled Promise rejection:",He instanceof Error?He.message:He,"; Zone:",Ue.zone.name,"; Task:",Ue.task&&Ue.task.source,"; Value:",He,He instanceof Error?He.stack:void 0):console.error(Ue)}},ye.microtaskDrainDone=()=>{for(;tt.length;){const Ue=tt.shift();try{Ue.zone.runGuarded(()=>{throw Ue.throwOriginal?Ue.rejection:Ue})}catch(He){gi(He)}}};const ti=at("unhandledPromiseRejectionHandler");function gi(Ue){ye.onUnhandledError(Ue);try{const He=se[ti];"function"==typeof He&&He.call(this,Ue)}catch{}}function cr(Ue){return Ue&&Ue.then}function Oi(Ue){return Ue}function es(Ue){return F.reject(Ue)}const kr=at("state"),Wt=at("value"),ct=at("finally"),_n=at("parentPromiseValue"),sr=at("parentPromiseState"),Zr="Promise.then",ki=null,lt=!0,dr=!1,et=0;function vi(Ue,He){return ge=>{try{cn(Ue,He,ge)}catch(We){cn(Ue,!1,We)}}}const Pt=function(){let Ue=!1;return function(ge){return function(){Ue||(Ue=!0,ge.apply(null,arguments))}}},ts="Promise resolved with itself",_o=at("currentTaskTrace");function cn(Ue,He,ge){const We=Pt();if(Ue===ge)throw new TypeError(ts);if(Ue[kr]===ki){let wt=null;try{("object"==typeof ge||"function"==typeof ge)&&(wt=ge&&ge.then)}catch(Xe){return We(()=>{cn(Ue,!1,Xe)})(),Ue}if(He!==dr&&ge instanceof F&&ge.hasOwnProperty(kr)&&ge.hasOwnProperty(Wt)&&ge[kr]!==ki)Do(ge),cn(Ue,ge[kr],ge[Wt]);else if(He!==dr&&"function"==typeof wt)try{wt.call(ge,We(vi(Ue,He)),We(vi(Ue,!1)))}catch(Xe){We(()=>{cn(Ue,!1,Xe)})()}else{Ue[kr]=He;const Xe=Ue[Wt];if(Ue[Wt]=ge,Ue[ct]===ct&&He===lt&&(Ue[kr]=Ue[sr],Ue[Wt]=Ue[_n]),He===dr&&ge instanceof Error){const mt=se.currentTask&&se.currentTask.data&&se.currentTask.data[Ei];mt&&be(ge,_o,{configurable:!0,enumerable:!1,writable:!0,value:mt})}for(let mt=0;mt{try{const dt=Ue[Wt],qt=!!ge&&ct===ge[ct];qt&&(ge[_n]=dt,ge[sr]=Xe);const ai=He.run(mt,void 0,qt&&mt!==es&&mt!==Oi?[]:[dt]);cn(ge,!0,ai)}catch(dt){cn(ge,!1,dt)}},ge)}const Pi=function(){},ht=Z.AggregateError;class F{static toString(){return"function ZoneAwarePromise() { [native code] }"}static resolve(He){return He instanceof F?He:cn(new this(null),lt,He)}static reject(He){return cn(new this(null),dr,He)}static withResolvers(){const He={};return He.promise=new F((ge,We)=>{He.resolve=ge,He.reject=We}),He}static any(He){if(!He||"function"!=typeof He[Symbol.iterator])return Promise.reject(new ht([],"All promises were rejected"));const ge=[];let We=0;try{for(let mt of He)We++,ge.push(F.resolve(mt))}catch{return Promise.reject(new ht([],"All promises were rejected"))}if(0===We)return Promise.reject(new ht([],"All promises were rejected"));let wt=!1;const Xe=[];return new F((mt,dt)=>{for(let qt=0;qt{wt||(wt=!0,mt(ai))},ai=>{Xe.push(ai),We--,0===We&&(wt=!0,dt(new ht(Xe,"All promises were rejected")))})})}static race(He){let ge,We,wt=new this((dt,qt)=>{ge=dt,We=qt});function Xe(dt){ge(dt)}function mt(dt){We(dt)}for(let dt of He)cr(dt)||(dt=this.resolve(dt)),dt.then(Xe,mt);return wt}static all(He){return F.allWithCallback(He)}static allSettled(He){return(this&&this.prototype instanceof F?this:F).allWithCallback(He,{thenCallback:We=>({status:"fulfilled",value:We}),errorCallback:We=>({status:"rejected",reason:We})})}static allWithCallback(He,ge){let We,wt,Xe=new this((ai,ur)=>{We=ai,wt=ur}),mt=2,dt=0;const qt=[];for(let ai of He){cr(ai)||(ai=this.resolve(ai));const ur=dt;try{ai.then(ir=>{qt[ur]=ge?ge.thenCallback(ir):ir,mt--,0===mt&&We(qt)},ir=>{ge?(qt[ur]=ge.errorCallback(ir),mt--,0===mt&&We(qt)):wt(ir)})}catch(ir){wt(ir)}mt++,dt++}return mt-=2,0===mt&&We(qt),Xe}constructor(He){const ge=this;if(!(ge instanceof F))throw new Error("Must be an instanceof Promise.");ge[kr]=ki,ge[Wt]=[];try{const We=Pt();He&&He(We(vi(ge,lt)),We(vi(ge,dr)))}catch(We){cn(ge,!1,We)}}get[Symbol.toStringTag](){return"Promise"}get[Symbol.species](){return F}then(He,ge){let We=this.constructor?.[Symbol.species];(!We||"function"!=typeof We)&&(We=this.constructor||F);const wt=new We(Pi),Xe=se.current;return this[kr]==ki?this[Wt].push(Xe,wt,He,ge):Ls(this,Xe,wt,He,ge),wt}catch(He){return this.then(null,He)}finally(He){let ge=this.constructor?.[Symbol.species];(!ge||"function"!=typeof ge)&&(ge=F);const We=new ge(Pi);We[ct]=ct;const wt=se.current;return this[kr]==ki?this[Wt].push(wt,We,He,He):Ls(this,wt,We,He,He),We}}F.resolve=F.resolve,F.reject=F.reject,F.race=F.race,F.all=F.all;const ae=Z[Lt]=Z.Promise;Z.Promise=F;const Et=at("thenPatched");function Xt(Ue){const He=Ue.prototype,ge=fe(He,"then");if(ge&&(!1===ge.writable||!ge.configurable))return;const We=He.then;He[ft]=We,Ue.prototype.then=function(wt,Xe){return new F((dt,qt)=>{We.call(this,dt,qt)}).then(wt,Xe)},Ue[Et]=!0}return ye.patchThen=Xt,ae&&(Xt(ae),Ka(Z,"fetch",Ue=>function Un(Ue){return function(He,ge){let We=Ue.apply(He,ge);if(We instanceof F)return We;let wt=We.constructor;return wt[Et]||Xt(wt),We}}(Ue))),Promise[se.__symbol__("uncaughtPromiseErrors")]=tt,F}),Zone.__load_patch("toString",Z=>{const se=Function.prototype.toString,ye=Ji("OriginalDelegate"),fe=Ji("Promise"),be=Ji("Error"),ke=function(){if("function"==typeof this){const Lt=this[ye];if(Lt)return"function"==typeof Lt?se.call(Lt):Object.prototype.toString.call(Lt);if(this===Promise){const ft=Z[fe];if(ft)return se.call(ft)}if(this===Error){const ft=Z[be];if(ft)return se.call(ft)}}return se.call(this)};ke[ye]=se,Function.prototype.toString=ke;const at=Object.prototype.toString;Object.prototype.toString=function(){return"function"==typeof Promise&&this instanceof Promise?"[object Promise]":at.call(this)}});let el=!1;if(typeof window<"u")try{const Z=Object.defineProperty({},"passive",{get:function(){el=!0}});window.addEventListener("test",Z,Z),window.removeEventListener("test",Z,Z)}catch{el=!1}const PT={useG:!0},Co={},Mb={},Im=new RegExp("^"+Yd+"(\\w+)(true|false)$"),wb=Ji("propagationStopped");function bm(Z,se){const ye=(se?se(Z):Z)+Wi,fe=(se?se(Z):Z)+Ts,be=Yd+ye,ke=Yd+fe;Co[Z]={},Co[Z][Wi]=be,Co[Z][Ts]=ke}function Cb(Z,se,ye,fe){const be=fe&&fe.add||gm,ke=fe&&fe.rm||$r,at=fe&&fe.listeners||"eventListeners",tt=fe&&fe.rmAll||"removeAllListeners",At=Ji(be),Lt="."+be+":",ft="prependListener",Ei="."+ft+":",ti=function(Wt,ct,_n){if(Wt.isRemoved)return;const sr=Wt.callback;let Zr;"object"==typeof sr&&sr.handleEvent&&(Wt.callback=lt=>sr.handleEvent(lt),Wt.originalDelegate=sr);try{Wt.invoke(Wt,ct,[_n])}catch(lt){Zr=lt}const ki=Wt.options;return ki&&"object"==typeof ki&&ki.once&&ct[ke].call(ct,_n.type,Wt.originalDelegate?Wt.originalDelegate:Wt.callback,ki),Zr};function gi(Wt,ct,_n){if(!(ct=ct||Z.event))return;const sr=Wt||ct.target||Z,Zr=sr[Co[ct.type][_n?Ts:Wi]];if(Zr){const ki=[];if(1===Zr.length){const lt=ti(Zr[0],sr,ct);lt&&ki.push(lt)}else{const lt=Zr.slice();for(let dr=0;dr{throw dr})}}}const cr=function(Wt){return gi(this,Wt,!1)},Oi=function(Wt){return gi(this,Wt,!0)};function es(Wt,ct){if(!Wt)return!1;let _n=!0;ct&&void 0!==ct.useG&&(_n=ct.useG);const sr=ct&&ct.vh;let Zr=!0;ct&&void 0!==ct.chkDup&&(Zr=ct.chkDup);let ki=!1;ct&&void 0!==ct.rt&&(ki=ct.rt);let lt=Wt;for(;lt&&!lt.hasOwnProperty(be);)lt=Vd(lt);if(!lt&&Wt[be]&&(lt=Wt),!lt||lt[At])return!1;const dr=ct&&ct.eventNameToString,et={},vi=lt[At]=lt[be],Pt=lt[Ji(ke)]=lt[ke],ts=lt[Ji(at)]=lt[at],_o=lt[Ji(tt)]=lt[tt];let cn;ct&&ct.prepend&&(cn=lt[Ji(ct.prepend)]=lt[ct.prepend]);const F=_n?function(ge){if(!et.isExisting)return vi.call(et.target,et.eventName,et.capture?Oi:cr,et.options)}:function(ge){return vi.call(et.target,et.eventName,ge.invoke,et.options)},ae=_n?function(ge){if(!ge.isRemoved){const We=Co[ge.eventName];let wt;We&&(wt=We[ge.capture?Ts:Wi]);const Xe=wt&&ge.target[wt];if(Xe)for(let mt=0;mt{Vo.zone.cancelTask(Vo)},{once:!0})),et.target=null,Fc&&(Fc.taskData=null),Zd&&(Dn.once=!0),!el&&"boolean"==typeof Vo.options||(Vo.options=Dn),Vo.target=qt,Vo.capture=Gl,Vo.eventName=ai,ir&&(Vo.originalDelegate=ur),dt?jo.unshift(Vo):jo.push(Vo),mt?qt:void 0}};return lt[be]=He(vi,Lt,F,ae,ki),cn&&(lt[ft]=He(cn,Ei,function(ge){return cn.call(et.target,et.eventName,ge.invoke,et.options)},ae,ki,!0)),lt[ke]=function(){const ge=this||Z;let We=arguments[0];ct&&ct.transferEventName&&(We=ct.transferEventName(We));const wt=arguments[2],Xe=!!wt&&("boolean"==typeof wt||wt.capture),mt=arguments[1];if(!mt)return Pt.apply(this,arguments);if(sr&&!sr(Pt,mt,ge,arguments))return;const dt=Co[We];let qt;dt&&(qt=dt[Xe?Ts:Wi]);const ai=qt&&ge[qt];if(ai)for(let ur=0;urfunction(be,ke){be[wb]=!0,fe&&fe.apply(be,ke)})}function Db(Z,se,ye,fe,be){const ke=Zone.__symbol__(fe);if(se[ke])return;const at=se[ke]=se[fe];se[fe]=function(tt,At,Lt){return At&&At.prototype&&be.forEach(function(ft){const Ei=`${ye}.${fe}::`+ft,ti=At.prototype;try{if(ti.hasOwnProperty(ft)){const gi=Z.ObjectGetOwnPropertyDescriptor(ti,ft);gi&&gi.value?(gi.value=Z.wrapWithCurrentZone(gi.value,Ei),Z._redefineProperty(At.prototype,ft,gi)):ti[ft]&&(ti[ft]=Z.wrapWithCurrentZone(ti[ft],Ei))}else ti[ft]&&(ti[ft]=Z.wrapWithCurrentZone(ti[ft],Ei))}catch{}}),at.call(se,tt,At,Lt)},Z.attachOriginToPatched(se[fe],at)}function xb(Z,se,ye){if(!ye||0===ye.length)return se;const fe=ye.filter(ke=>ke.target===Z);if(!fe||0===fe.length)return se;const be=fe[0].ignoreProperties;return se.filter(ke=>-1===be.indexOf(ke))}function Eo(Z,se,ye,fe){Z&&pf(Z,xb(Z,se,ye),fe)}function $d(Z){return Object.getOwnPropertyNames(Z).filter(se=>se.startsWith("on")&&se.length>2).map(se=>se.substring(2))}Zone.__load_patch("util",(Z,se,ye)=>{const fe=$d(Z);ye.patchOnProperties=pf,ye.patchMethod=Ka,ye.bindArguments=Qd,ye.patchMacroTask=Sb;const be=se.__symbol__("BLACK_LISTED_EVENTS"),ke=se.__symbol__("UNPATCHED_EVENTS");Z[ke]&&(Z[be]=Z[ke]),Z[be]&&(se[be]=se[ke]=Z[be]),ye.patchEventPrototype=Mm,ye.patchEventTarget=Cb,ye.isIEOrEdge=bb,ye.ObjectDefineProperty=jd,ye.ObjectGetOwnPropertyDescriptor=_l,ye.ObjectCreate=Wd,ye.ArraySlice=yb,ye.patchClass=Xd,ye.wrapWithCurrentZone=hf,ye.filterProperties=xb,ye.attachOriginToPatched=Sa,ye._redefineProperty=Object.defineProperty,ye.patchCallbacks=Db,ye.getGlobalObjects=()=>({globalSources:Mb,zoneSymbolEventNames:Co,eventNames:fe,isBrowser:Gd,isMix:uf,isNode:jh,TRUE_STR:Ts,FALSE_STR:Wi,ZONE_SYMBOL_PREFIX:Yd,ADD_EVENT_LISTENER_STR:gm,REMOVE_EVENT_LISTENER_STR:$r})});const As=Ji("zoneTask");function Wl(Z,se,ye,fe){let be=null,ke=null;ye+=fe;const at={};function tt(Lt){const ft=Lt.data;return ft.args[0]=function(){return Lt.invoke.apply(this,arguments)},ft.handleId=be.apply(Z,ft.args),Lt}function At(Lt){return ke.call(Z,Lt.data.handleId)}be=Ka(Z,se+=fe,Lt=>function(ft,Ei){if("function"==typeof Ei[0]){const ti={isPeriodic:"Interval"===fe,delay:"Timeout"===fe||"Interval"===fe?Ei[1]||0:void 0,args:Ei},gi=Ei[0];Ei[0]=function(){try{return gi.apply(this,arguments)}finally{ti.isPeriodic||("number"==typeof ti.handleId?delete at[ti.handleId]:ti.handleId&&(ti.handleId[As]=null))}};const cr=vm(se,Ei[0],ti,tt,At);if(!cr)return cr;const Oi=cr.data.handleId;return"number"==typeof Oi?at[Oi]=cr:Oi&&(Oi[As]=cr),Oi&&Oi.ref&&Oi.unref&&"function"==typeof Oi.ref&&"function"==typeof Oi.unref&&(cr.ref=Oi.ref.bind(Oi),cr.unref=Oi.unref.bind(Oi)),"number"==typeof Oi||Oi?Oi:cr}return Lt.apply(Z,Ei)}),ke=Ka(Z,ye,Lt=>function(ft,Ei){const ti=Ei[0];let gi;"number"==typeof ti?gi=at[ti]:(gi=ti&&ti[As],gi||(gi=ti)),gi&&"string"==typeof gi.type?"notScheduled"!==gi.state&&(gi.cancelFn&&gi.data.isPeriodic||0===gi.runCount)&&("number"==typeof ti?delete at[ti]:ti&&(ti[As]=null),gi.zone.cancelTask(gi)):Lt.apply(Z,Ei)})}Zone.__load_patch("legacy",Z=>{const se=Z[Zone.__symbol__("legacyPatch")];se&&se()}),Zone.__load_patch("timers",Z=>{const ye="clear";Wl(Z,"set",ye,"Timeout"),Wl(Z,"set",ye,"Interval"),Wl(Z,"set",ye,"Immediate")}),Zone.__load_patch("requestAnimationFrame",Z=>{Wl(Z,"request","cancel","AnimationFrame"),Wl(Z,"mozRequest","mozCancel","AnimationFrame"),Wl(Z,"webkitRequest","webkitCancel","AnimationFrame")}),Zone.__load_patch("blocking",(Z,se)=>{const ye=["alert","prompt","confirm"];for(let fe=0;fefunction(At,Lt){return se.current.run(ke,Z,Lt,tt)})}),Zone.__load_patch("EventTarget",(Z,se,ye)=>{(function Yl(Z,se){se.patchEventPrototype(Z,se)})(Z,ye),function Cm(Z,se){if(Zone[se.symbol("patchEventTarget")])return;const{eventNames:ye,zoneSymbolEventNames:fe,TRUE_STR:be,FALSE_STR:ke,ZONE_SYMBOL_PREFIX:at}=se.getGlobalObjects();for(let At=0;At{Xd("MutationObserver"),Xd("WebKitMutationObserver")}),Zone.__load_patch("IntersectionObserver",(Z,se,ye)=>{Xd("IntersectionObserver")}),Zone.__load_patch("FileReader",(Z,se,ye)=>{Xd("FileReader")}),Zone.__load_patch("on_property",(Z,se,ye)=>{!function ff(Z,se){if(jh&&!uf||Zone[Z.symbol("patchEvents")])return;const ye=se.__Zone_ignore_on_properties;let fe=[];if(Gd){const be=window;fe=fe.concat(["Document","SVGElement","Element","HTMLElement","HTMLBodyElement","HTMLMediaElement","HTMLFrameSetElement","HTMLFrameElement","HTMLIFrameElement","HTMLMarqueeElement","Worker"]);const ke=function Sm(){try{const Z=Uh.navigator.userAgent;if(-1!==Z.indexOf("MSIE ")||-1!==Z.indexOf("Trident/"))return!0}catch{}return!1}()?[{target:be,ignoreProperties:["error"]}]:[];Eo(be,$d(be),ye&&ye.concat(ke),Vd(be))}fe=fe.concat(["XMLHttpRequest","XMLHttpRequestEventTarget","IDBIndex","IDBRequest","IDBOpenDBRequest","IDBDatabase","IDBTransaction","IDBCursor","WebSocket"]);for(let be=0;be{!function wm(Z,se){const{isBrowser:ye,isMix:fe}=se.getGlobalObjects();(ye||fe)&&Z.customElements&&"customElements"in Z&&se.patchCallbacks(se,Z.customElements,"customElements","define",["connectedCallback","disconnectedCallback","adoptedCallback","attributeChangedCallback"])}(Z,ye)}),Zone.__load_patch("XHR",(Z,se)=>{!function At(Lt){const ft=Lt.XMLHttpRequest;if(!ft)return;const Ei=ft.prototype;let gi=Ei[Ul],cr=Ei[Fh];if(!gi){const et=Lt.XMLHttpRequestEventTarget;if(et){const vi=et.prototype;gi=vi[Ul],cr=vi[Fh]}}const Oi="readystatechange",es="scheduled";function kr(et){const vi=et.data,Pt=vi.target;Pt[ke]=!1,Pt[tt]=!1;const ts=Pt[be];gi||(gi=Pt[Ul],cr=Pt[Fh]),ts&&cr.call(Pt,Oi,ts);const _o=Pt[be]=()=>{if(Pt.readyState===Pt.DONE)if(!vi.aborted&&Pt[ke]&&et.state===es){const Ur=Pt[se.__symbol__("loadfalse")];if(0!==Pt.status&&Ur&&Ur.length>0){const Do=et.invoke;et.invoke=function(){const Ls=Pt[se.__symbol__("loadfalse")];for(let jr=0;jrfunction(et,vi){return et[fe]=0==vi[2],et[at]=vi[1],_n.apply(et,vi)}),Zr=Ji("fetchTaskAborting"),ki=Ji("fetchTaskScheduling"),lt=Ka(Ei,"send",()=>function(et,vi){if(!0===se.current[ki]||et[fe])return lt.apply(et,vi);{const Pt={target:et,url:et[at],isPeriodic:!1,args:vi,aborted:!1},ts=vm("XMLHttpRequest.send",Wt,Pt,kr,ct);et&&!0===et[tt]&&!Pt.aborted&&ts.state===es&&ts.invoke()}}),dr=Ka(Ei,"abort",()=>function(et,vi){const Pt=function ti(et){return et[ye]}(et);if(Pt&&"string"==typeof Pt.type){if(null==Pt.cancelFn||Pt.data&&Pt.data.aborted)return;Pt.zone.cancelTask(Pt)}else if(!0===se.current[Zr])return dr.apply(et,vi)})}(Z);const ye=Ji("xhrTask"),fe=Ji("xhrSync"),be=Ji("xhrListener"),ke=Ji("xhrScheduled"),at=Ji("xhrURL"),tt=Ji("xhrErrorBeforeScheduled")}),Zone.__load_patch("geolocation",Z=>{Z.navigator&&Z.navigator.geolocation&&function ym(Z,se){const ye=Z.constructor.name;for(let fe=0;fe{const At=function(){return tt.apply(this,Qd(arguments,ye+"."+be))};return Sa(At,tt),At})(ke)}}}(Z.navigator.geolocation,["getCurrentPosition","watchPosition"])}),Zone.__load_patch("PromiseRejectionEvent",(Z,se)=>{function ye(fe){return function(be){Eb(Z,fe).forEach(at=>{const tt=Z.PromiseRejectionEvent;if(tt){const At=new tt(fe,{promise:be.promise,reason:be.rejection});at.invoke(At)}})}}Z.PromiseRejectionEvent&&(se[Ji("unhandledPromiseRejectionHandler")]=ye("unhandledrejection"),se[Ji("rejectionHandledHandler")]=ye("rejectionhandled"))}),Zone.__load_patch("queueMicrotask",(Z,se,ye)=>{!function gf(Z,se){se.patchMethod(Z,"queueMicrotask",ye=>function(fe,be){Zone.current.scheduleMicroTask("queueMicrotask",be[0])})}(Z,ye)})}},_l=>{_l(_l.s=51)}]); \ No newline at end of file diff --git a/ej2-angular/samples/diagram/layers/layers-cs7/index.html b/ej2-angular/samples/diagram/layers/layers-cs7/index.html index ffc35b5c9c..852300d60e 100644 --- a/ej2-angular/samples/diagram/layers/layers-cs7/index.html +++ b/ej2-angular/samples/diagram/layers/layers-cs7/index.html @@ -19,5 +19,5 @@
Loading....
- + \ No newline at end of file diff --git a/ej2-angular/samples/diagram/layers/layers-cs7/main.10ecba4e72d9d589.js b/ej2-angular/samples/diagram/layers/layers-cs7/main.10ecba4e72d9d589.js new file mode 100644 index 0000000000..35a55aae64 --- /dev/null +++ b/ej2-angular/samples/diagram/layers/layers-cs7/main.10ecba4e72d9d589.js @@ -0,0 +1 @@ +"use strict";(self.webpackChunksyncfusion_component=self.webpackChunksyncfusion_component||[]).push([[179],{51:(Wl,Vd,Wd)=>{let $r=null,_h=1;const Ts=Symbol("SIGNAL");function Wi(n){const t=$r;return $r=n,t}function gn(n){if((!Wh(n)||n.dirty)&&(n.dirty||n.lastCleanEpoch!==_h)){if(!n.producerMustRecompute(n)&&!Vh(n))return n.dirty=!1,void(n.lastCleanEpoch=_h);n.producerRecomputeValue(n),n.dirty=!1,n.lastCleanEpoch=_h}}function Vh(n){Gl(n);for(let t=0;t0}function Gl(n){n.producerNode??=[],n.producerIndexOfThis??=[],n.producerLastReadVersion??=[]}let $d=null;function Eo(n){return"function"==typeof n}function Zd(n){const e=n(i=>{Error.call(i),i.stack=(new Error).stack});return e.prototype=Object.create(Error.prototype),e.prototype.constructor=e,e}const pp=Zd(n=>function(e){n(this),this.message=e?`${e.length} errors occurred during unsubscription:\n${e.map((i,r)=>`${r+1}) ${i.toString()}`).join("\n ")}`:"",this.name="UnsubscriptionError",this.errors=e});function gp(n,t){if(n){const e=n.indexOf(t);0<=e&&n.splice(e,1)}}class As{constructor(t){this.initialTeardown=t,this.closed=!1,this._parentage=null,this._finalizers=null}unsubscribe(){let t;if(!this.closed){this.closed=!0;const{_parentage:e}=this;if(e)if(this._parentage=null,Array.isArray(e))for(const s of e)s.remove(this);else e.remove(this);const{initialTeardown:i}=this;if(Eo(i))try{i()}catch(s){t=s instanceof pp?s.errors:[s]}const{_finalizers:r}=this;if(r){this._finalizers=null;for(const s of r)try{Dm(s)}catch(o){t=t??[],o instanceof pp?t=[...t,...o.errors]:t.push(o)}}if(t)throw new pp(t)}}add(t){var e;if(t&&t!==this)if(this.closed)Dm(t);else{if(t instanceof As){if(t.closed||t._hasParent(this))return;t._addParent(this)}(this._finalizers=null!==(e=this._finalizers)&&void 0!==e?e:[]).push(t)}}_hasParent(t){const{_parentage:e}=this;return e===t||Array.isArray(e)&&e.includes(t)}_addParent(t){const{_parentage:e}=this;this._parentage=Array.isArray(e)?(e.push(t),e):e?[e,t]:t}_removeParent(t){const{_parentage:e}=this;e===t?this._parentage=null:Array.isArray(e)&&gp(e,t)}remove(t){const{_finalizers:e}=this;e&&gp(e,t),t instanceof As&&t._removeParent(this)}}As.EMPTY=(()=>{const n=new As;return n.closed=!0,n})();const Xl=As.EMPTY;function Em(n){return n instanceof As||n&&"closed"in n&&Eo(n.remove)&&Eo(n.add)&&Eo(n.unsubscribe)}function Dm(n){Eo(n)?n():n.unsubscribe()}const ql={onUnhandledError:null,onStoppedNotification:null,Promise:void 0,useDeprecatedSynchronousErrorHandling:!1,useDeprecatedNextContext:!1},Z={setTimeout(n,t,...e){const{delegate:i}=Z;return i?.setTimeout?i.setTimeout(n,t,...e):setTimeout(n,t,...e)},clearTimeout(n){const{delegate:t}=Z;return(t?.clearTimeout||clearTimeout)(n)},delegate:void 0};function ye(){}const pe=at("C",void 0,void 0);function at(n,t,e){return{kind:n,value:t,error:e}}let tt=null;function At(n){if(ql.useDeprecatedSynchronousErrorHandling){const t=!tt;if(t&&(tt={errorThrown:!1,error:null}),n(),t){const{errorThrown:e,error:i}=tt;if(tt=null,e)throw i}}else n()}class pt extends As{constructor(t){super(),this.isStopped=!1,t?(this.destination=t,Em(t)&&t.add(this)):this.destination=Wt}static create(t,e,i){return new cr(t,e,i)}next(t){this.isStopped?Pr(function ke(n){return at("N",n,void 0)}(t),this):this._next(t)}error(t){this.isStopped?Pr(function be(n){return at("E",void 0,n)}(t),this):(this.isStopped=!0,this._error(t))}complete(){this.isStopped?Pr(pe,this):(this.isStopped=!0,this._complete())}unsubscribe(){this.closed||(this.isStopped=!0,super.unsubscribe(),this.destination=null)}_next(t){this.destination.next(t)}_error(t){try{this.destination.error(t)}finally{this.unsubscribe()}}_complete(){try{this.destination.complete()}finally{this.unsubscribe()}}}const Di=Function.prototype.bind;function ni(n,t){return Di.call(n,t)}class mi{constructor(t){this.partialObserver=t}next(t){const{partialObserver:e}=this;if(e.next)try{e.next(t)}catch(i){ki(i)}}error(t){const{partialObserver:e}=this;if(e.error)try{e.error(t)}catch(i){ki(i)}else ki(t)}complete(){const{partialObserver:t}=this;if(t.complete)try{t.complete()}catch(e){ki(e)}}}class cr extends pt{constructor(t,e,i){let r;if(super(),Eo(t)||!t)r={next:t??void 0,error:e??void 0,complete:i??void 0};else{let s;this&&ql.useDeprecatedNextContext?(s=Object.create(t),s.unsubscribe=()=>this.unsubscribe(),r={next:t.next&&ni(t.next,s),error:t.error&&ni(t.error,s),complete:t.complete&&ni(t.complete,s)}):r=t}this.destination=new mi(r)}}function ki(n){ql.useDeprecatedSynchronousErrorHandling?function Lt(n){ql.useDeprecatedSynchronousErrorHandling&&tt&&(tt.errorThrown=!0,tt.error=n)}(n):function se(n){Z.setTimeout(()=>{const{onUnhandledError:t}=ql;if(!t)throw n;t(n)})}(n)}function Pr(n,t){const{onStoppedNotification:e}=ql;e&&Z.setTimeout(()=>e(n,t))}const Wt={closed:!0,next:ye,error:function is(n){throw n},complete:ye},ct="function"==typeof Symbol&&Symbol.observable||"@@observable";function jn(n){return n}let Pi=(()=>{class n{constructor(e){e&&(this._subscribe=e)}lift(e){const i=new n;return i.source=this,i.operator=e,i}subscribe(e,i,r){const s=function et(n){return n&&n instanceof pt||function dr(n){return n&&Eo(n.next)&&Eo(n.error)&&Eo(n.complete)}(n)&&Em(n)}(e)?e:new cr(e,i,r);return At(()=>{const{operator:o,source:a}=this;s.add(o?o.call(s,a):a?this._subscribe(s):this._trySubscribe(s))}),s}_trySubscribe(e){try{return this._subscribe(e)}catch(i){e.error(i)}}forEach(e,i){return new(i=lt(i))((r,s)=>{const o=new cr({next:a=>{try{e(a)}catch(l){s(l),o.unsubscribe()}},error:s,complete:r});this.subscribe(o)})}_subscribe(e){var i;return null===(i=this.source)||void 0===i?void 0:i.subscribe(e)}[ct](){return this}pipe(...e){return function Zr(n){return 0===n.length?jn:1===n.length?n[0]:function(e){return n.reduce((i,r)=>r(i),e)}}(e)(this)}toPromise(e){return new(e=lt(e))((i,r)=>{let s;this.subscribe(o=>s=o,o=>r(o),()=>i(s))})}}return n.create=t=>new n(t),n})();function lt(n){var t;return null!==(t=n??ql.Promise)&&void 0!==t?t:Promise}const yi=Zd(n=>function(){n(this),this.name="ObjectUnsubscribedError",this.message="object unsubscribed"});let Pt=(()=>{class n extends Pi{constructor(){super(),this.closed=!1,this.currentObservers=null,this.observers=[],this.isStopped=!1,this.hasError=!1,this.thrownError=null}lift(e){const i=new rs(this,this);return i.operator=e,i}_throwIfClosed(){if(this.closed)throw new yi}next(e){At(()=>{if(this._throwIfClosed(),!this.isStopped){this.currentObservers||(this.currentObservers=Array.from(this.observers));for(const i of this.currentObservers)i.next(e)}})}error(e){At(()=>{if(this._throwIfClosed(),!this.isStopped){this.hasError=this.isStopped=!0,this.thrownError=e;const{observers:i}=this;for(;i.length;)i.shift().error(e)}})}complete(){At(()=>{if(this._throwIfClosed(),!this.isStopped){this.isStopped=!0;const{observers:e}=this;for(;e.length;)e.shift().complete()}})}unsubscribe(){this.isStopped=this.closed=!0,this.observers=this.currentObservers=null}get observed(){var e;return(null===(e=this.observers)||void 0===e?void 0:e.length)>0}_trySubscribe(e){return this._throwIfClosed(),super._trySubscribe(e)}_subscribe(e){return this._throwIfClosed(),this._checkFinalizedStatuses(e),this._innerSubscribe(e)}_innerSubscribe(e){const{hasError:i,isStopped:r,observers:s}=this;return i||r?Xl:(this.currentObservers=null,s.push(e),new As(()=>{this.currentObservers=null,gp(s,e)}))}_checkFinalizedStatuses(e){const{hasError:i,thrownError:r,isStopped:s}=this;i?e.error(r):s&&e.complete()}asObservable(){const e=new Pi;return e.source=this,e}}return n.create=(t,e)=>new rs(t,e),n})();class rs extends Pt{constructor(t,e){super(),this.destination=t,this.source=e}next(t){var e,i;null===(i=null===(e=this.destination)||void 0===e?void 0:e.next)||void 0===i||i.call(e,t)}error(t){var e,i;null===(i=null===(e=this.destination)||void 0===e?void 0:e.error)||void 0===i||i.call(e,t)}complete(){var t,e;null===(e=null===(t=this.destination)||void 0===t?void 0:t.complete)||void 0===e||e.call(t)}_subscribe(t){var e,i;return null!==(i=null===(e=this.source)||void 0===e?void 0:e.subscribe(t))&&void 0!==i?i:Xl}}class _o extends Pt{constructor(t){super(),this._value=t}get value(){return this.getValue()}_subscribe(t){const e=super._subscribe(t);return!e.closed&&t.next(this._value),e}getValue(){const{hasError:t,thrownError:e,_value:i}=this;if(t)throw e;return this._throwIfClosed(),i}next(t){super.next(this._value=t)}}class Ls extends pt{constructor(t,e,i,r,s,o){super(t),this.onFinalize=s,this.shouldUnsubscribe=o,this._next=e?function(a){try{e(a)}catch(l){t.error(l)}}:super._next,this._error=r?function(a){try{r(a)}catch(l){t.error(l)}finally{this.unsubscribe()}}:super._error,this._complete=i?function(){try{i()}catch(a){t.error(a)}finally{this.unsubscribe()}}:super._complete}unsubscribe(){var t;if(!this.shouldUnsubscribe||this.shouldUnsubscribe()){const{closed:e}=this;super.unsubscribe(),!e&&(null===(t=this.onFinalize)||void 0===t||t.call(this))}}}function jr(n,t){return function Ur(n){return t=>{if(function cn(n){return Eo(n?.lift)}(t))return t.lift(function(e){try{return n(e,this)}catch(i){this.error(i)}});throw new TypeError("Unable to lift unknown Observable type")}}((e,i)=>{let r=0;e.subscribe(function Do(n,t,e,i,r){return new Ls(n,t,e,i,r)}(i,s=>{i.next(n.call(t,s,r++))}))})}class F extends Error{constructor(t,e){super(function ae(n,t){return`NG0${Math.abs(n)}${t?": "+t:""}`}(t,e)),this.code=t}}function Xe(n){for(let t in n)if(n[t]===Xe)return t;throw Error("Could not find renamed property on target object.")}function mt(n,t){for(const e in t)t.hasOwnProperty(e)&&!n.hasOwnProperty(e)&&(n[e]=t[e])}function dt(n){if("string"==typeof n)return n;if(Array.isArray(n))return"["+n.map(dt).join(", ")+"]";if(null==n)return""+n;if(n.overriddenName)return`${n.overriddenName}`;if(n.name)return`${n.name}`;const t=n.toString();if(null==t)return""+t;const e=t.indexOf("\n");return-1===e?t:t.substring(0,e)}function qt(n,t){return null==n||""===n?null===t?"":t:null==t||""===t?n:n+" "+t}const ur=Xe({__forward_ref__:Xe});function ir(n){return n.__forward_ref__=ir,n.toString=function(){return dt(this())},n}function vt(n){return function Tn(n){return"function"==typeof n&&n.hasOwnProperty(ur)&&n.__forward_ref__===ir}(n)?n():n}function $l(n){return n&&!!n.\u0275providers}const Zl=Xe({\u0275cmp:Xe}),Jd=Xe({\u0275dir:Xe}),vp=Xe({\u0275pipe:Xe}),Uo=Xe({\u0275fac:Xe}),jo=Xe({__NG_ELEMENT_ID__:Xe}),mp=Xe({__NG_ENV_ID__:Xe});function Ri(n){return"function"==typeof n?n.name||n.toString():"object"==typeof n&&null!=n&&"function"==typeof n.type?n.type.name||n.type.toString():function Nt(n){return"string"==typeof n?n:null==n?"":String(n)}(n)}function Nb(n,t){throw new F(-201,!1)}function so(n,t){null==n&&function zt(n,t,e,i){throw new Error(`ASSERTION ERROR: ${n}`+(null==i?"":` [Expected=> ${e} ${i} ${t} <=Actual]`))}(t,n,null,"!=")}function Yi(n){return{token:n.token,providedIn:n.providedIn||null,factory:n.factory,value:void 0}}function yp(n){return{providers:n.providers||[],imports:n.imports||[]}}function xm(n){return RT(n,Am)||RT(n,HT)}function RT(n,t){return n.hasOwnProperty(t)?n[t]:null}function Tm(n){return n&&(n.hasOwnProperty(Ob)||n.hasOwnProperty(x_))?n[Ob]:null}const Am=Xe({\u0275prov:Xe}),Ob=Xe({\u0275inj:Xe}),HT=Xe({ngInjectableDef:Xe}),x_=Xe({ngInjectorDef:Xe});var xi=function(n){return n[n.Default=0]="Default",n[n.Host=1]="Host",n[n.Self=2]="Self",n[n.SkipSelf=4]="SkipSelf",n[n.Optional=8]="Optional",n}(xi||{});let kb;function oo(n){const t=kb;return kb=n,t}function FT(n,t,e){const i=xm(n);return i&&"root"==i.providedIn?void 0===i.value?i.value=i.factory():i.value:e&xi.Optional?null:void 0!==t?t:void Nb()}const rr=globalThis;class Ht{constructor(t,e){this._desc=t,this.ngMetadataName="InjectionToken",this.\u0275prov=void 0,"number"==typeof e?this.__NG_ELEMENT_ID__=e:void 0!==e&&(this.\u0275prov=Yi({token:this,providedIn:e.providedIn||"root",factory:e.factory}))}get multi(){return this}toString(){return`InjectionToken ${this._desc}`}}const Sp={},Bb="__NG_DI_FLAG__",Lm="ngTempTokenPath",L_=/\n/gm,UT="__source";let eu;function Gh(n){const t=eu;return eu=n,t}function k_(n,t=xi.Default){if(void 0===eu)throw new F(-203,!1);return null===eu?FT(n,void 0,t):eu.get(n,t&xi.Optional?null:void 0,t)}function _i(n,t=xi.Default){return(function BT(){return kb}()||k_)(vt(n),t)}function Hi(n,t=xi.Default){return _i(n,Nm(t))}function Nm(n){return typeof n>"u"||"number"==typeof n?n:0|(n.optional&&8)|(n.host&&1)|(n.self&&2)|(n.skipSelf&&4)}function Fb(n){const t=[];for(let e=0;et){o=s-1;break}}}for(;ss?"":r[d+1].toLowerCase();const f=8&i?u:null;if(f&&-1!==VT(f,h,0)||2&i&&h!==u){if(Ma(i))return!1;o=!0}}}}else{if(!o&&!Ma(i)&&!Ma(l))return!1;if(o&&Ma(l))continue;o=!1,i=l|1&i}}return Ma(i)||o}function Ma(n){return 0==(1&n)}function __(n,t,e,i){if(null===t)return-1;let r=0;if(i||!e){let s=!1;for(;r-1)for(e++;e0?'="'+a+'"':"")+"]"}else 8&i?r+="."+o:4&i&&(r+=" "+o);else""!==r&&!Ma(o)&&(t+=$T(s,r),r=""),i=o,s=s||!Ma(i);e++}return""!==r&&(t+=$T(s,r)),t}function Ub(n){return Jl(()=>{const t=JT(n),e={...t,decls:n.decls,vars:n.vars,template:n.template,consts:n.consts||null,ngContentSelectors:n.ngContentSelectors,onPush:n.changeDetection===Om.OnPush,directiveDefs:null,pipeDefs:null,dependencies:t.standalone&&n.dependencies||null,getStandaloneInjector:null,signals:n.signals??!1,data:n.data||{},encapsulation:n.encapsulation||ba.Emulated,styles:n.styles||Qi,_:null,schemas:n.schemas||null,tView:null,id:""};KT(e);const i=n.dependencies;return e.directiveDefs=Pm(i,!1),e.pipeDefs=Pm(i,!0),e.id=function Z_(n){let t=0;const e=[n.selectors,n.ngContentSelectors,n.hostVars,n.hostAttrs,n.consts,n.vars,n.decls,n.encapsulation,n.standalone,n.signals,n.exportAs,JSON.stringify(n.inputs),JSON.stringify(n.outputs),Object.getOwnPropertyNames(n.type.prototype),!!n.contentQueries,!!n.viewQuery].join("|");for(const r of e)t=Math.imul(31,t)+r.charCodeAt(0)<<0;return t+=2147483648,"c"+t}(e),e})}function X_(n){return di(n)||Wn(n)}function q_(n){return null!==n}function km(n){return Jl(()=>({type:n.type,bootstrap:n.bootstrap||Qi,declarations:n.declarations||Qi,imports:n.imports||Qi,exports:n.exports||Qi,transitiveCompileScopes:null,schemas:n.schemas||null,id:n.id||null}))}function ZT(n,t){if(null==n)return rl;const e={};for(const i in n)if(n.hasOwnProperty(i)){const r=n[i];let s,o,a=Xh.None;Array.isArray(r)?(a=r[0],s=r[1],o=r[2]??s):(s=r,o=r),t?(e[s]=a!==Xh.None?[i,a]:i,t[s]=o):e[s]=i}return e}function nr(n){return Jl(()=>{const t=JT(n);return KT(t),t})}function di(n){return n[Zl]||null}function Wn(n){return n[Jd]||null}function gs(n){return n[vp]||null}function JT(n){const t={};return{type:n.type,providersResolver:null,factory:null,hostBindings:n.hostBindings||null,hostVars:n.hostVars||0,hostAttrs:n.hostAttrs||null,contentQueries:n.contentQueries||null,declaredInputs:t,inputTransforms:null,inputConfig:n.inputs||rl,exportAs:n.exportAs||null,standalone:!0===n.standalone,signals:!0===n.signals,selectors:n.selectors||Qi,viewQuery:n.viewQuery||null,features:n.features||null,setInput:null,findHostDirectiveDefs:null,hostDirectives:null,inputs:ZT(n.inputs,t),outputs:ZT(n.outputs),debugInfo:null}}function KT(n){n.features?.forEach(t=>t(n))}function Pm(n,t){if(!n)return null;const e=t?gs:X_;return()=>("function"==typeof n?n():n).map(i=>e(i)).filter(q_)}const Vr=0,Be=1,Ct=2,vn=3,wa=4,Os=5,Ca=6,tu=7,Er=8,Xs=9,Kl=10,Yt=11,Mp=12,eA=13,iu=14,Jr=15,wp=16,ru=17,nl=18,Cp=19,tA=20,qh=21,zm=22,Vc=23,jt=25,jb=1,sl=7,nu=9,mn=10;var Vb=function(n){return n[n.None=0]="None",n[n.HasTransplantedViews=2]="HasTransplantedViews",n}(Vb||{});function ks(n){return Array.isArray(n)&&"object"==typeof n[jb]}function Ps(n){return Array.isArray(n)&&!0===n[jb]}function Wb(n){return 0!=(4&n.flags)}function Wc(n){return n.componentOffset>-1}function Hm(n){return 1==(1&n.flags)}function Ea(n){return!!n.template}function Yb(n){return 0!=(512&n[Ct])}function Yc(n,t){return n.hasOwnProperty(Uo)?n[Uo]:null}class tU{constructor(t,e,i){this.previousValue=t,this.currentValue=e,this.firstChange=i}isFirstChange(){return this.firstChange}}function sA(n,t,e,i){null!==t?t.applyValueToInputSignal(t,i):n[e]=i}function oA(n){return n.type.prototype.ngOnChanges&&(n.setInput=rU),iU}function iU(){const n=lA(this),t=n?.current;if(t){const e=n.previous;if(e===rl)n.previous=t;else for(let i in t)e[i]=t[i];n.current=null,this.ngOnChanges(t)}}function rU(n,t,e,i,r){const s=this.declaredInputs[i],o=lA(n)||function nU(n,t){return n[aA]=t}(n,{previous:rl,current:null}),a=o.current||(o.current={}),l=o.previous,h=l[s];a[s]=new tU(h&&h.currentValue,e,l===rl),sA(n,t,r,e)}const aA="__ngSimpleChanges__";function lA(n){return n[aA]||null}const ol=function(n,t,e){};let dA=!1;function fr(n){for(;Array.isArray(n);)n=n[Vr];return n}function qs(n,t){return fr(t[n.index])}function xp(n,t){return n.data[t]}function To(n,t){const e=t[n];return ks(e)?e:e[Vr]}function $b(n){return 128==(128&n[Ct])}function al(n,t){return null==t?null:n[t]}function uA(n){n[ru]=0}function cU(n){1024&n[Ct]||(n[Ct]|=1024,$b(n)&&Tp(n))}function pA(n){return 9216&n[Ct]||n[Vc]?.dirty}function Zb(n){pA(n)?Tp(n):64&n[Ct]&&(function oU(){return dA}()?(n[Ct]|=1024,Tp(n)):n[Kl].changeDetectionScheduler?.notify())}function Tp(n){n[Kl].changeDetectionScheduler?.notify();let t=Qc(n);for(;null!==t&&!(8192&t[Ct])&&(t[Ct]|=8192,$b(t));)t=Qc(t)}function Qc(n){const t=n[vn];return Ps(t)?t[vn]:t}const Rt={lFrame:CA(null),bindingsEnabled:!0,skipHydrationRootTNode:null};function vA(){return Rt.bindingsEnabled}function Se(){return Rt.lFrame.lView}function Ti(){return Rt.lFrame.tView}function pr(){let n=mA();for(;null!==n&&64===n.type;)n=n.parent;return n}function mA(){return Rt.lFrame.currentTNode}function ll(n,t){const e=Rt.lFrame;e.currentTNode=n,e.isParent=t}function Kb(){return Rt.lFrame.isParent}function wU(n,t){const e=Rt.lFrame;e.bindingIndex=e.bindingRootIndex=n,t1(t)}function t1(n){Rt.lFrame.currentDirectiveIndex=n}function bA(){return Rt.lFrame.currentQueryIndex}function r1(n){Rt.lFrame.currentQueryIndex=n}function EU(n){const t=n[Be];return 2===t.type?t.declTNode:1===t.type?n[Os]:null}function MA(n,t,e){if(e&xi.SkipSelf){let r=t,s=n;for(;!(r=r.parent,null!==r||e&xi.Host||(r=EU(s),null===r||(s=s[iu],10&r.type))););if(null===r)return!1;t=r,n=s}const i=Rt.lFrame=wA();return i.currentTNode=t,i.lView=n,!0}function n1(n){const t=wA(),e=n[Be];Rt.lFrame=t,t.currentTNode=e.firstChild,t.lView=n,t.tView=e,t.contextLView=n,t.bindingIndex=e.bindingStartIndex,t.inI18n=!1}function wA(){const n=Rt.lFrame,t=null===n?null:n.child;return null===t?CA(n):t}function CA(n){const t={currentTNode:null,isParent:!0,lView:null,tView:null,selectedIndex:-1,contextLView:null,elementDepthCount:0,currentNamespace:null,currentDirectiveIndex:-1,bindingRootIndex:-1,bindingIndex:-1,currentQueryIndex:0,parent:n,child:null,inI18n:!1};return null!==n&&(n.child=t),t}function EA(){const n=Rt.lFrame;return Rt.lFrame=n.parent,n.currentTNode=null,n.lView=null,n}const DA=EA;function s1(){const n=EA();n.isParent=!0,n.tView=null,n.selectedIndex=-1,n.contextLView=null,n.elementDepthCount=0,n.currentDirectiveIndex=-1,n.currentNamespace=null,n.bindingRootIndex=-1,n.bindingIndex=-1,n.currentQueryIndex=0}function zs(){return Rt.lFrame.selectedIndex}function Gc(n){Rt.lFrame.selectedIndex=n}let TA=!0;function _m(){return TA}function $h(n){TA=n}function Um(n,t){for(let e=t.directiveStart,i=t.directiveEnd;e=i)break}else t[l]<0&&(n[ru]+=65536),(a>14>16&&(3&n[Ct])===t&&(n[Ct]+=16384,LA(a,s)):LA(a,s)}const au=-1;class Lp{constructor(t,e,i){this.factory=t,this.resolving=!1,this.canSeeViewProviders=e,this.injectImpl=i}}function l1(n){return n!==au}function Np(n){return 32767&n}function Op(n,t){let e=function HU(n){return n>>16}(n),i=t;for(;e>0;)i=i[iu],e--;return i}let h1=!0;function Wm(n){const t=h1;return h1=n,t}const NA=255,OA=5;let BU=0;const cl={};function Ym(n,t){const e=kA(n,t);if(-1!==e)return e;const i=t[Be];i.firstCreatePass&&(n.injectorIndex=t.length,c1(i.data,n),c1(t,null),c1(i.blueprint,null));const r=Qm(n,t),s=n.injectorIndex;if(l1(r)){const o=Np(r),a=Op(r,t),l=a[Be].data;for(let h=0;h<8;h++)t[s+h]=a[o+h]|l[o+h]}return t[s+8]=r,s}function c1(n,t){n.push(0,0,0,0,0,0,0,0,t)}function kA(n,t){return-1===n.injectorIndex||n.parent&&n.parent.injectorIndex===n.injectorIndex||null===t[n.injectorIndex+8]?-1:n.injectorIndex}function Qm(n,t){if(n.parent&&-1!==n.parent.injectorIndex)return n.parent.injectorIndex;let e=0,i=null,r=t;for(;null!==r;){if(i=_A(r),null===i)return au;if(e++,r=r[iu],-1!==i.injectorIndex)return i.injectorIndex|e<<16}return au}function d1(n,t,e){!function FU(n,t,e){let i;"string"==typeof e?i=e.charCodeAt(0)||0:e.hasOwnProperty(jo)&&(i=e[jo]),null==i&&(i=e[jo]=BU++);const r=i&NA;t.data[n+(r>>OA)]|=1<=0?t&NA:VU:t}(e);if("function"==typeof s){if(!MA(t,n,i))return i&xi.Host?PA(r,0,i):zA(t,e,i,r);try{let o;if(o=s(i),null!=o||i&xi.Optional)return o;Nb()}finally{DA()}}else if("number"==typeof s){let o=null,a=kA(n,t),l=au,h=i&xi.Host?t[Jr][Os]:null;for((-1===a||i&xi.SkipSelf)&&(l=-1===a?Qm(n,t):t[a+8],l!==au&&FA(i,!1)?(o=t[Be],a=Np(l),t=Op(l,t)):a=-1);-1!==a;){const c=t[Be];if(BA(s,a,c.data)){const d=UU(a,t,e,o,i,h);if(d!==cl)return d}l=t[a+8],l!==au&&FA(i,t[Be].data[a+8]===h)&&BA(s,a,t)?(o=c,a=Np(l),t=Op(l,t)):a=-1}}return r}function UU(n,t,e,i,r,s){const o=t[Be],a=o.data[n+8],c=Gm(a,o,e,null==i?Wc(a)&&h1:i!=o&&0!=(3&a.type),r&xi.Host&&s===a);return null!==c?Xc(t,o,c,a):cl}function Gm(n,t,e,i,r){const s=n.providerIndexes,o=t.data,a=1048575&s,l=n.directiveStart,c=s>>20,u=r?a+c:n.directiveEnd;for(let f=i?a:a+c;f=l&&p.type===e)return f}if(r){const f=o[l];if(f&&Ea(f)&&f.type===e)return l}return null}function Xc(n,t,e,i){let r=n[e];const s=t.data;if(function kU(n){return n instanceof Lp}(r)){const o=r;o.resolving&&function Vo(n,t){const e=t?`. Dependency path: ${t.join(" > ")} > ${n}`:"";throw new F(-200,`Circular dependency in DI detected for ${n}${e}`)}(Ri(s[e]));const a=Wm(o.canSeeViewProviders);o.resolving=!0;const h=o.injectImpl?oo(o.injectImpl):null;MA(n,i,xi.Default);try{r=n[e]=o.factory(void 0,s,n,i),t.firstCreatePass&&e>=i.directiveStart&&function NU(n,t,e){const{ngOnChanges:i,ngOnInit:r,ngDoCheck:s}=t.type.prototype;if(i){const o=oA(t);(e.preOrderHooks??=[]).push(n,o),(e.preOrderCheckHooks??=[]).push(n,o)}r&&(e.preOrderHooks??=[]).push(0-n,r),s&&((e.preOrderHooks??=[]).push(n,s),(e.preOrderCheckHooks??=[]).push(n,s))}(e,s[e],t)}finally{null!==h&&oo(h),Wm(a),o.resolving=!1,DA()}}return r}function BA(n,t,e){return!!(e[t+(n>>OA)]&1<Array.isArray(e)?gu(e,t):t(e))}function jA(n,t,e){t>=n.length?n.push(e):n.splice(t,0,e)}function Xm(n,t){return t>=n.length-1?n.pop():n.splice(t,1)[0]}const yu=new Ht(""),XA=new Ht("",-1),b1=new Ht("");class Jm{get(t,e=Sp){if(e===Sp){const i=new Error(`NullInjectorError: No provider for ${dt(t)}!`);throw i.name="NullInjectorError",i}return e}}function fj(...n){return{\u0275providers:qA(0,n),\u0275fromNgModule:!0}}function qA(n,...t){const e=[],i=new Set;let r;const s=o=>{e.push(o)};return gu(t,o=>{const a=o;Km(a,s,[],i)&&(r||=[],r.push(a))}),void 0!==r&&$A(r,s),e}function $A(n,t){for(let e=0;e{t(s,i)})}}function Km(n,t,e,i){if(!(n=vt(n)))return!1;let r=null,s=Tm(n);const o=!s&&di(n);if(s||o){if(o&&!o.standalone)return!1;r=n}else{const l=n.ngModule;if(s=Tm(l),!s)return!1;r=l}const a=i.has(r);if(o){if(a)return!1;if(i.add(r),o.dependencies){const l="function"==typeof o.dependencies?o.dependencies():o.dependencies;for(const h of l)Km(h,t,e,i)}}else{if(!s)return!1;{if(null!=s.imports&&!a){let h;i.add(r);try{gu(s.imports,c=>{Km(c,t,e,i)&&(h||=[],h.push(c))})}finally{}void 0!==h&&$A(h,t)}if(!a){const h=Yc(r)||(()=>new r);t({provide:r,useFactory:h,deps:Qi},r),t({provide:b1,useValue:r,multi:!0},r),t({provide:yu,useValue:()=>_i(r),multi:!0},r)}const l=s.providers;if(null!=l&&!a){const h=n;w1(l,c=>{t(c,h)})}}}return r!==n&&void 0!==n.providers}function w1(n,t){for(let e of n)$l(e)&&(e=e.\u0275providers),Array.isArray(e)?w1(e,t):t(e)}const pj=Xe({provide:String,useValue:Xe});function C1(n){return null!==n&&"object"==typeof n&&pj in n}function qc(n){return"function"==typeof n}const E1=new Ht(""),ey={},vj={};let D1;function ty(){return void 0===D1&&(D1=new Jm),D1}class ih{}class Su extends ih{get destroyed(){return this._destroyed}constructor(t,e,i,r){super(),this.parent=e,this.source=i,this.scopes=r,this.records=new Map,this._ngOnDestroyHooks=new Set,this._onDestroyHooks=[],this._destroyed=!1,T1(t,o=>this.processProvider(o)),this.records.set(XA,Iu(void 0,this)),r.has("environment")&&this.records.set(ih,Iu(void 0,this));const s=this.records.get(E1);null!=s&&"string"==typeof s.value&&this.scopes.add(s.value),this.injectorDefTypes=new Set(this.get(b1,Qi,xi.Self))}destroy(){this.assertNotDestroyed(),this._destroyed=!0;try{for(const e of this._ngOnDestroyHooks)e.ngOnDestroy();const t=this._onDestroyHooks;this._onDestroyHooks=[];for(const e of t)e()}finally{this.records.clear(),this._ngOnDestroyHooks.clear(),this.injectorDefTypes.clear()}}onDestroy(t){return this.assertNotDestroyed(),this._onDestroyHooks.push(t),()=>this.removeOnDestroy(t)}runInContext(t){this.assertNotDestroyed();const e=Gh(this),i=oo(void 0);try{return t()}finally{Gh(e),oo(i)}}get(t,e=Sp,i=xi.Default){if(this.assertNotDestroyed(),t.hasOwnProperty(mp))return t[mp](this);i=Nm(i);const s=Gh(this),o=oo(void 0);try{if(!(i&xi.SkipSelf)){let l=this.records.get(t);if(void 0===l){const h=function bj(n){return"function"==typeof n||"object"==typeof n&&n instanceof Ht}(t)&&xm(t);l=h&&this.injectableDefInScope(h)?Iu(x1(t),ey):null,this.records.set(t,l)}if(null!=l)return this.hydrate(t,l)}return(i&xi.Self?ty():this.parent).get(t,e=i&xi.Optional&&e===Sp?null:e)}catch(a){if("NullInjectorError"===a.name){if((a[Lm]=a[Lm]||[]).unshift(dt(t)),s)throw a;return function z_(n,t,e,i){const r=n[Lm];throw t[UT]&&r.unshift(t[UT]),n.message=function R_(n,t,e,i=null){n=n&&"\n"===n.charAt(0)&&"\u0275"==n.charAt(1)?n.slice(2):n;let r=dt(t);if(Array.isArray(t))r=t.map(dt).join(" -> ");else if("object"==typeof t){let s=[];for(let o in t)if(t.hasOwnProperty(o)){let a=t[o];s.push(o+":"+("string"==typeof a?JSON.stringify(a):dt(a)))}r=`{${s.join(", ")}}`}return`${e}${i?"("+i+")":""}[${r}]: ${n.replace(L_,"\n ")}`}("\n"+n.message,r,e,i),n.ngTokenPath=r,n[Lm]=null,n}(a,t,"R3InjectorError",this.source)}throw a}finally{oo(o),Gh(s)}}resolveInjectorInitializers(){const t=Gh(this),e=oo(void 0);try{const r=this.get(yu,Qi,xi.Self);for(const s of r)s()}finally{Gh(t),oo(e)}}toString(){const t=[],e=this.records;for(const i of e.keys())t.push(dt(i));return`R3Injector[${t.join(", ")}]`}assertNotDestroyed(){if(this._destroyed)throw new F(205,!1)}processProvider(t){let e=qc(t=vt(t))?t:vt(t&&t.provide);const i=function yj(n){return C1(n)?Iu(void 0,n.useValue):Iu(KA(n),ey)}(t);if(!qc(t)&&!0===t.multi){let r=this.records.get(e);r||(r=Iu(void 0,ey,!0),r.factory=()=>Fb(r.multi),this.records.set(e,r)),e=t,r.multi.push(t)}this.records.set(e,i)}hydrate(t,e){return e.value===ey&&(e.value=vj,e.value=e.factory()),"object"==typeof e.value&&e.value&&function Ij(n){return null!==n&&"object"==typeof n&&"function"==typeof n.ngOnDestroy}(e.value)&&this._ngOnDestroyHooks.add(e.value),e.value}injectableDefInScope(t){if(!t.providedIn)return!1;const e=vt(t.providedIn);return"string"==typeof e?"any"===e||this.scopes.has(e):this.injectorDefTypes.has(e)}removeOnDestroy(t){const e=this._onDestroyHooks.indexOf(t);-1!==e&&this._onDestroyHooks.splice(e,1)}}function x1(n){const t=xm(n),e=null!==t?t.factory:Yc(n);if(null!==e)return e;if(n instanceof Ht)throw new F(204,!1);if(n instanceof Function)return function mj(n){if(n.length>0)throw new F(204,!1);const e=function D_(n){return n&&(n[Am]||n[HT])||null}(n);return null!==e?()=>e.factory(n):()=>new n}(n);throw new F(204,!1)}function KA(n,t,e){let i;if(qc(n)){const r=vt(n);return Yc(r)||x1(r)}if(C1(n))i=()=>vt(n.useValue);else if(function JA(n){return!(!n||!n.useFactory)}(n))i=()=>n.useFactory(...Fb(n.deps||[]));else if(function ZA(n){return!(!n||!n.useExisting)}(n))i=()=>_i(vt(n.useExisting));else{const r=vt(n&&(n.useClass||n.provide));if(!function Sj(n){return!!n.deps}(n))return Yc(r)||x1(r);i=()=>new r(...Fb(n.deps))}return i}function Iu(n,t,e=!1){return{factory:n,value:t,multi:e?[]:void 0}}function T1(n,t){for(const e of n)Array.isArray(e)?T1(e,t):e&&$l(e)?T1(e.\u0275providers,t):t(e)}function rL(n,t=null,e=null,i){const r=function nL(n,t=null,e=null,i,r=new Set){const s=[e||Qi,fj(n)];return i=i||("object"==typeof n?void 0:dt(n)),new Su(s,t||ty(),i||null,r)}(n,t,e,i);return r.resolveInjectorInitializers(),r}let N1,Wo=(()=>{class n{static{this.THROW_IF_NOT_FOUND=Sp}static{this.NULL=new Jm}static create(e,i){if(Array.isArray(e))return rL({name:""},i,e,"");{const r=e.name??"";return rL({name:r},e.parent,e.providers,r)}}static{this.\u0275prov=Yi({token:n,providedIn:"any",factory:()=>_i(XA)})}static{this.__NG_ELEMENT_ID__=-1}}return n})();const O1=new Ht("",{providedIn:"root",factory:()=>Lj}),Lj="ng",oL=new Ht(""),bu=new Ht("",{providedIn:"platform",factory:()=>"unknown"}),aL=new Ht("",{providedIn:"root",factory:()=>function Zh(){if(void 0!==N1)return N1;if(typeof document<"u")return document;throw new F(210,!1)}().body?.querySelector("[ngCspNonce]")?.getAttribute("ngCspNonce")||null});function oy(n){return 128==(128&n.flags)}var ec=function(n){return n[n.Important=1]="Important",n[n.DashCase=2]="DashCase",n}(ec||{});const H1=new Map;let Vj=0;const F1="__ngContext__";function Rs(n,t){ks(t)?(n[F1]=t[Cp],function Yj(n){H1.set(n[Cp],n)}(t)):n[F1]=t}let _1;function U1(n,t){return _1(n,t)}function wu(n,t,e,i,r){if(null!=i){let s,o=!1;Ps(i)?s=i:ks(i)&&(o=!0,i=i[Vr]);const a=fr(i);0===n&&null!==e?null==r?AL(t,e,a):Zc(t,e,a,r||null,!0):1===n&&null!==e?Zc(t,e,a,r||null,!0):2===n?function fy(n,t,e){const i=dy(n,t);i&&function a6(n,t,e,i){n.removeChild(t,e,i)}(n,i,t,e)}(t,a,o):3===n&&t.destroyNode(a),null!=s&&function c6(n,t,e,i,r){const s=e[sl];s!==fr(e)&&wu(t,n,i,s,r);for(let a=mn;a0&&(n[e-1][wa]=i[wa]);const s=Xm(n,mn+t);!function e6(n,t){DL(n,t),t[Vr]=null,t[Os]=null}(i[Be],i);const o=s[nl];null!==o&&o.detachView(s[Be]),i[vn]=null,i[wa]=null,i[Ct]&=-129}return i}function cy(n,t){if(!(256&t[Ct])){const e=t[Yt];e.destroyNode&&py(n,t,e,3,null,null),function i6(n){let t=n[Mp];if(!t)return V1(n[Be],n);for(;t;){let e=null;if(ks(t))e=t[Mp];else{const i=t[mn];i&&(e=i)}if(!e){for(;t&&!t[wa]&&t!==n;)ks(t)&&V1(t[Be],t),t=t[vn];null===t&&(t=n),ks(t)&&V1(t[Be],t),e=t&&t[wa]}t=e}}(t)}}function V1(n,t){if(!(256&t[Ct])){t[Ct]&=-129,t[Ct]|=256,t[Vc]&&function Xd(n){if(Gl(n),Wh(n))for(let t=0;t=0?i[o]():i[-o].unsubscribe(),s+=2}else e[s].call(i[e[s+1]]);null!==i&&(t[tu]=null);const r=t[qh];if(null!==r){t[qh]=null;for(let s=0;s-1){const{encapsulation:s}=n.data[i.directiveStart+r];if(s===ba.None||s===ba.Emulated)return null}return qs(i,e)}}(n,t.parent,e)}function Zc(n,t,e,i,r){n.insertBefore(t,e,i,r)}function AL(n,t,e){n.appendChild(t,e)}function LL(n,t,e,i,r){null!==i?Zc(n,t,e,i,r):AL(n,t,e)}function dy(n,t){return n.parentNode(t)}let Y1,kL=function OL(n,t,e){return 40&n.type?qs(n,e):null};function uy(n,t,e,i){const r=W1(n,i,t),s=t[Yt],a=function NL(n,t,e){return kL(n,t,e)}(i.parent||t[Os],i,t);if(null!=r)if(Array.isArray(e))for(let l=0;lnull;function aM(n,t,e=!1){return KL(n,t,e)}class G6{}class nN{}class q6{resolveComponentFactory(t){throw function X6(n){const t=Error(`No component factory found for ${dt(n)}.`);return t.ngComponent=n,t}(t)}}let wy=(()=>{class n{static{this.NULL=new q6}}return n})();function $6(){return Au(pr(),Se())}function Au(n,t){return new Jc(qs(n,t))}let Jc=(()=>{class n{constructor(e){this.nativeElement=e}static{this.__NG_ELEMENT_ID__=$6}}return n})();function Z6(n){return n instanceof Jc?n.nativeElement:n}class oN{}let dM=(()=>{class n{constructor(){this.destroyNode=null}static{this.__NG_ELEMENT_ID__=()=>function J6(){const n=Se(),e=To(pr().index,n);return(ks(e)?e:n)[Yt]}()}}return n})(),K6=(()=>{class n{static{this.\u0275prov=Yi({token:n,providedIn:"root",factory:()=>null})}}return n})();const uM={};function Gp(n,t,e,i,r=!1){for(;null!==e;){const s=t[e.index];null!==s&&i.push(fr(s)),Ps(s)&&pN(s,i);const o=e.type;if(8&o)Gp(n,t,e.child,i);else if(32&o){const a=U1(e,t);let l;for(;l=a();)i.push(l)}else if(16&o){const a=zL(t,e);if(Array.isArray(a))i.push(...a);else{const l=Qc(t[Jr]);Gp(l[Be],l,a,i,!0)}}e=r?e.projectionNext:e.next}return i}function pN(n,t){for(let e=mn;e!1,producerRecomputeValue:()=>{},consumerMarkedDirty:()=>{},consumerOnSignalRead:()=>{},consumerIsAlwaysLive:!0,consumerMarkedDirty:n=>{Tp(n.lView)},consumerOnSignalRead(){this.lView[Vc]=this}};function vN(n){return yN(n[Mp])}function mN(n){return yN(n[wa])}function yN(n){for(;null!==n&&!Ps(n);)n=n[wa];return n}function gM(n){return n.ngOriginalError}class nh{constructor(){this._console=console}handleError(t){const e=this._findOriginalError(t);this._console.error("ERROR",t),e&&this._console.error("ORIGINAL ERROR",e)}_findOriginalError(t){let e=t&&gM(t);for(;e&&gM(e);)e=gM(e);return e||null}}const IN=new Ht("",{providedIn:"root",factory:()=>Hi(nh).handleError.bind(void 0)}),MN=new Ht("",{providedIn:"root",factory:()=>!1}),Qt={};function Xp(n=1){DN(Ti(),Se(),zs()+n,!1)}function DN(n,t,e,i){if(!i)if(3==(3&t[Ct])){const s=n.preOrderCheckHooks;null!==s&&jm(t,s,e)}else{const s=n.preOrderHooks;null!==s&&Vm(t,s,0,e)}Gc(e)}function Ot(n,t=xi.Default){const e=Se();return null===e?_i(n,t):RA(pr(),e,vt(n),t)}function xN(n,t,e,i,r,s){const o=Wi(null);try{let a=null;r&Xh.SignalBased&&(a=t[i][Ts]),null!==a&&void 0!==a.transformFn&&(s=a.transformFn(s)),r&Xh.HasDecoratorInputTransform&&(s=n.inputTransforms[i].call(t,s)),null!==n.setInput?n.setInput(t,a,s,e,i):sA(t,a,i,s)}finally{Wi(o)}}function xy(n,t,e,i,r,s,o,a,l,h,c){const d=t.blueprint.slice();return d[Vr]=r,d[Ct]=204|i,(null!==h||n&&2048&n[Ct])&&(d[Ct]|=2048),uA(d),d[vn]=d[iu]=n,d[Er]=e,d[Kl]=o||n&&n[Kl],d[Yt]=a||n&&n[Yt],d[Xs]=l||n&&n[Xs]||null,d[Os]=s,d[Cp]=function Wj(){return Vj++}(),d[Ca]=c,d[tA]=h,d[Jr]=2==t.type?n[Jr]:d,d}function Lu(n,t,e,i,r){let s=n.data[t];if(null===s)s=function vM(n,t,e,i,r){const s=mA(),o=Kb(),l=n.data[t]=function LV(n,t,e,i,r,s){let o=t?t.injectorIndex:-1,a=0;return function ou(){return null!==Rt.skipHydrationRootTNode}()&&(a|=128),{type:e,index:i,insertBeforeIndex:null,injectorIndex:o,directiveStart:-1,directiveEnd:-1,directiveStylingLast:-1,componentOffset:-1,propertyBindings:null,flags:a,providerIndexes:0,value:r,attrs:s,mergedAttrs:null,localNames:null,initialInputs:void 0,inputs:null,outputs:null,tView:null,next:null,prev:null,projectionNext:null,child:null,parent:t,projection:null,styles:null,stylesWithoutHost:null,residualStyles:void 0,classes:null,classesWithoutHost:null,residualClasses:void 0,classBindings:0,styleBindings:0}}(0,o?s:s&&s.parent,e,t,i,r);return null===n.firstChild&&(n.firstChild=l),null!==s&&(o?null==s.child&&null!==l.parent&&(s.child=l):null===s.next&&(s.next=l,l.prev=s)),l}(n,t,e,i,r),function MU(){return Rt.lFrame.inI18n}()&&(s.flags|=32);else if(64&s.type){s.type=e,s.value=i,s.attrs=r;const o=function Ap(){const n=Rt.lFrame,t=n.currentTNode;return n.isParent?t:t.parent}();s.injectorIndex=null===o?-1:o.injectorIndex}return ll(s,!0),s}function qp(n,t,e,i){if(0===e)return-1;const r=t.length;for(let s=0;sjt&&DN(n,t,jt,!1),ol(o?2:0,r),e(i,r)}finally{Gc(s),ol(o?3:1,r)}}function mM(n,t,e){if(Wb(t)){const i=Wi(null);try{const s=t.directiveEnd;for(let o=t.directiveStart;onull;function NN(n,t,e,i,r){for(let s in t){if(!t.hasOwnProperty(s))continue;const o=t[s];if(void 0===o)continue;i??={};let a,l=Xh.None;Array.isArray(o)?(a=o[0],l=o[1]):a=o;let h=s;if(null!==r){if(!r.hasOwnProperty(s))continue;h=r[s]}0===n?ON(i,e,h,a,l):ON(i,e,h,a)}return i}function ON(n,t,e,i,r){let s;n.hasOwnProperty(e)?(s=n[e]).push(t,i):s=n[e]=[t,i],void 0!==r&&s.push(r)}function kN(n,t,e,i,r,s){for(let h=0;h0;){const e=n[--t];if("number"==typeof e&&e<0)return e}return 0})(o)!=a&&o.push(a),o.push(e,i,s)}}(n,t,i,qp(n,e,r.hostVars,Qt),r)}function YV(n,t,e,i,r,s){const o=s[t];if(null!==o)for(let a=0;an.nextProducerIndex;)n.producerNode.pop(),n.producerLastReadVersion.pop(),n.producerIndexOfThis.pop()}}(a,o),function fV(n){n.lView[Vc]!==n&&(n.lView=null,gN.push(n))}(a)),s1()}}function _N(n,t){for(let e=vN(n);null!==e;e=mN(e))for(let i=mn;i-1&&(Fp(t,i),Xm(e,i))}this._attachedToViewContainer=!1}cy(this._lView[Be],this._lView)}onDestroy(t){!function Fm(n,t){if(256==(256&n[Ct]))throw new F(911,!1);null===n[qh]&&(n[qh]=[]),n[qh].push(t)}(this._lView,t)}markForCheck(){$p(this._cdRefInjectingView||this._lView)}detach(){this._lView[Ct]&=-129}reattach(){Zb(this._lView),this._lView[Ct]|=128}detectChanges(){this._lView[Ct]|=1024,function DM(n,t=!0){const e=n[Kl],i=e.rendererFactory;i.begin?.();try{!function XV(n){xM(n,0);let t=0;for(;pA(n);){if(100===t)throw new F(103,!1);t++,xM(n,1)}}(n)}catch(s){throw t&&Ay(n,s),s}finally{i.end?.(),e.inlineEffectRunner?.flush()}}(this._lView,this.notifyErrorHandler)}checkNoChanges(){}attachToViewContainerRef(){if(this._appRef)throw new F(902,!1);this._attachedToViewContainer=!0}detachFromAppRef(){this._appRef=null,DL(this._lView[Be],this._lView)}attachToAppRef(t){if(this._attachedToViewContainer)throw new F(902,!1);this._appRef=t,Zb(this._lView)}}const WN=new Set;function AM(n){return t=>{setTimeout(n,void 0,t)}}const Yo=class h7 extends Pt{constructor(t=!1){super(),this.__isAsync=t}emit(t){super.next(t)}subscribe(t,e,i){let r=t,s=e||(()=>null),o=i;if(t&&"object"==typeof t){const l=t;r=l.next?.bind(l),s=l.error?.bind(l),o=l.complete?.bind(l)}this.__isAsync&&(s=AM(s),r&&(r=AM(r)),o&&(o=AM(o)));const a=super.subscribe({next:r,error:s,complete:o});return t instanceof As&&t.add(a),a}};function YN(...n){}class Rr{constructor({enableLongStackTrace:t=!1,shouldCoalesceEventChangeDetection:e=!1,shouldCoalesceRunChangeDetection:i=!1}){if(this.hasPendingMacrotasks=!1,this.hasPendingMicrotasks=!1,this.isStable=!0,this.onUnstable=new Yo(!1),this.onMicrotaskEmpty=new Yo(!1),this.onStable=new Yo(!1),this.onError=new Yo(!1),typeof Zone>"u")throw new F(908,!1);Zone.assertZonePatched();const r=this;r._nesting=0,r._outer=r._inner=Zone.current,Zone.TaskTrackingZoneSpec&&(r._inner=r._inner.fork(new Zone.TaskTrackingZoneSpec)),t&&Zone.longStackTraceZoneSpec&&(r._inner=r._inner.fork(Zone.longStackTraceZoneSpec)),r.shouldCoalesceEventChangeDetection=!i&&e,r.shouldCoalesceRunChangeDetection=i,r.lastRequestAnimationFrameId=-1,r.nativeRequestAnimationFrame=function c7(){const n="function"==typeof rr.requestAnimationFrame;let t=rr[n?"requestAnimationFrame":"setTimeout"],e=rr[n?"cancelAnimationFrame":"clearTimeout"];if(typeof Zone<"u"&&t&&e){const i=t[Zone.__symbol__("OriginalDelegate")];i&&(t=i);const r=e[Zone.__symbol__("OriginalDelegate")];r&&(e=r)}return{nativeRequestAnimationFrame:t,nativeCancelAnimationFrame:e}}().nativeRequestAnimationFrame,function f7(n){const t=()=>{!function u7(n){n.isCheckStableRunning||-1!==n.lastRequestAnimationFrameId||(n.lastRequestAnimationFrameId=n.nativeRequestAnimationFrame.call(rr,()=>{n.fakeTopEventTask||(n.fakeTopEventTask=Zone.root.scheduleEventTask("fakeTopEventTask",()=>{n.lastRequestAnimationFrameId=-1,NM(n),n.isCheckStableRunning=!0,LM(n),n.isCheckStableRunning=!1},void 0,()=>{},()=>{})),n.fakeTopEventTask.invoke()}),NM(n))}(n)};n._inner=n._inner.fork({name:"angular",properties:{isAngularZone:!0},onInvokeTask:(e,i,r,s,o,a)=>{if(function p7(n){return!(!Array.isArray(n)||1!==n.length)&&!0===n[0].data?.__ignore_ng_zone__}(a))return e.invokeTask(r,s,o,a);try{return QN(n),e.invokeTask(r,s,o,a)}finally{(n.shouldCoalesceEventChangeDetection&&"eventTask"===s.type||n.shouldCoalesceRunChangeDetection)&&t(),GN(n)}},onInvoke:(e,i,r,s,o,a,l)=>{try{return QN(n),e.invoke(r,s,o,a,l)}finally{n.shouldCoalesceRunChangeDetection&&t(),GN(n)}},onHasTask:(e,i,r,s)=>{e.hasTask(r,s),i===r&&("microTask"==s.change?(n._hasPendingMicrotasks=s.microTask,NM(n),LM(n)):"macroTask"==s.change&&(n.hasPendingMacrotasks=s.macroTask))},onHandleError:(e,i,r,s)=>(e.handleError(r,s),n.runOutsideAngular(()=>n.onError.emit(s)),!1)})}(r)}static isInAngularZone(){return typeof Zone<"u"&&!0===Zone.current.get("isAngularZone")}static assertInAngularZone(){if(!Rr.isInAngularZone())throw new F(909,!1)}static assertNotInAngularZone(){if(Rr.isInAngularZone())throw new F(909,!1)}run(t,e,i){return this._inner.run(t,e,i)}runTask(t,e,i,r){const s=this._inner,o=s.scheduleEventTask("NgZoneEvent: "+r,t,d7,YN,YN);try{return s.runTask(o,e,i)}finally{s.cancelTask(o)}}runGuarded(t,e,i){return this._inner.runGuarded(t,e,i)}runOutsideAngular(t){return this._outer.run(t)}}const d7={};function LM(n){if(0==n._nesting&&!n.hasPendingMicrotasks&&!n.isStable)try{n._nesting++,n.onMicrotaskEmpty.emit(null)}finally{if(n._nesting--,!n.hasPendingMicrotasks)try{n.runOutsideAngular(()=>n.onStable.emit(null))}finally{n.isStable=!0}}}function NM(n){n.hasPendingMicrotasks=!!(n._hasPendingMicrotasks||(n.shouldCoalesceEventChangeDetection||n.shouldCoalesceRunChangeDetection)&&-1!==n.lastRequestAnimationFrameId)}function QN(n){n._nesting++,n.isStable&&(n.isStable=!1,n.onUnstable.emit(null))}function GN(n){n._nesting--,LM(n)}let Jp=(()=>{class n{constructor(){this.handler=null,this.internalCallbacks=[]}execute(){const e=[...this.internalCallbacks];this.internalCallbacks.length=0;for(const r of e)r();return!!this.handler?.execute()||e.length>0}ngOnDestroy(){this.handler?.destroy(),this.handler=null,this.internalCallbacks.length=0}static{this.\u0275prov=Yi({token:n,providedIn:"root",factory:()=>new n})}}return n})();function y7(n,t){const e=To(t,n),i=e[Be];!function S7(n,t){for(let e=t.length;e0&&BL(n,e,s.join(" "))}}(u,w,p,i),void 0!==e&&function A7(n,t,e){const i=n.projection=[];for(let r=0;r=0;i--){const r=n[i];r.hostVars=t+=r.hostVars,r.hostAttrs=bp(r.hostAttrs,e=bp(e,r.hostAttrs))}}(i)}function N7(n,t){for(const e in t.inputs){if(!t.inputs.hasOwnProperty(e)||n.inputs.hasOwnProperty(e))continue;const i=t.inputs[e];if(void 0!==i&&(n.inputs[e]=i,n.declaredInputs[e]=t.declaredInputs[e],null!==t.inputTransforms)){const r=Array.isArray(i)?i[0]:i;if(!t.inputTransforms.hasOwnProperty(r))continue;n.inputTransforms??={},n.inputTransforms[r]=t.inputTransforms[r]}}}function Ny(n){return n===rl?{}:n===Qi?[]:n}function k7(n,t){const e=n.viewQuery;n.viewQuery=e?(i,r)=>{t(i,r),e(i,r)}:t}function P7(n,t){const e=n.contentQueries;n.contentQueries=e?(i,r,s)=>{t(i,r,s),e(i,r,s)}:t}function z7(n,t){const e=n.hostBindings;n.hostBindings=e?(i,r)=>{t(i,r),e(i,r)}:t}function Ou(n,t){return!t||null===t.firstChild||oy(n)}function sg(n,t,e,i=!0){const r=t[Be];if(function r6(n,t,e,i){const r=mn+i,s=e.length;i>0&&(e[r-1][wa]=t),i{class n{static{this.__NG_ELEMENT_ID__=h9}}return n})();function h9(){return pO(pr(),Se())}const c9=An,uO=class extends c9{constructor(t,e,i){super(),this._lContainer=t,this._hostTNode=e,this._hostLView=i}get element(){return Au(this._hostTNode,this._hostLView)}get injector(){return new Yn(this._hostTNode,this._hostLView)}get parentInjector(){const t=Qm(this._hostTNode,this._hostLView);if(l1(t)){const e=Op(t,this._hostLView),i=Np(t);return new Yn(e[Be].data[i+8],e)}return new Yn(null,this._hostLView)}clear(){for(;this.length>0;)this.remove(this.length-1)}get(t){const e=fO(this._lContainer);return null!==e&&e[t]||null}get length(){return this._lContainer.length-mn}createEmbeddedView(t,e,i){let r,s;"number"==typeof i?r=i:null!=i&&(r=i.index,s=i.injector);const a=t.createEmbeddedViewImpl(e||{},s,null);return this.insertImpl(a,r,Ou(this._hostTNode,null)),a}createComponent(t,e,i,r,s){const o=t&&!function kp(n){return"function"==typeof n}(t);let a;if(o)a=e;else{const p=e||{};a=p.index,i=p.injector,r=p.projectableNodes,s=p.environmentInjector||p.ngModuleRef}const l=o?t:new Kp(di(t)),h=i||this.parentInjector;if(!s&&null==l.ngModule){const g=(o?h:this.parentInjector).get(ih,null);g&&(s=g)}di(l.componentType??{});const f=l.create(h,r,null,s);return this.insertImpl(f.hostView,a,Ou(this._hostTNode,null)),f}insert(t,e){return this.insertImpl(t,e,!0)}insertImpl(t,e,i){const r=t._lView;if(function hU(n){return Ps(n[vn])}(r)){const a=this.indexOf(t);if(-1!==a)this.detach(a);else{const l=r[vn],h=new uO(l,l[Os],l[vn]);h.detach(h.indexOf(t))}}const s=this._adjustIndex(e),o=this._lContainer;return sg(o,r,s,i),t.attachToViewContainerRef(),jA(FM(o),s,t),t}move(t,e){return this.insert(t,e)}indexOf(t){const e=fO(this._lContainer);return null!==e?e.indexOf(t):-1}remove(t){const e=this._adjustIndex(t,-1),i=Fp(this._lContainer,e);i&&(Xm(FM(this._lContainer),e),cy(i[Be],i))}detach(t){const e=this._adjustIndex(t,-1),i=Fp(this._lContainer,e);return i&&null!=Xm(FM(this._lContainer),e)?new Zp(i):null}_adjustIndex(t,e=0){return t??this.length+e}};function fO(n){return n[8]}function FM(n){return n[8]||(n[8]=[])}function pO(n,t){let e;const i=t[n.index];return Ps(i)?e=i:(e=function zN(n,t,e,i){return[n,!0,0,t,null,i,null,e,null,null]}(i,t,null,n),t[n.index]=e,Ty(t,e)),gO(e,t,n,i),new uO(e,n,t)}let gO=function mO(n,t,e,i){if(n[sl])return;let r;r=8&e.type?fr(i):function d9(n,t){const e=n[Yt],i=e.createComment(""),r=qs(t,n);return Zc(e,dy(e,r),i,function l6(n,t){return n.nextSibling(t)}(e,r),!1),i}(t,e),n[sl]=r};function qu(n,t,e){const i=Se();return function Ln(n,t,e){return!Object.is(n[t],e)&&(n[t]=e,!0)}(i,function hl(){return Rt.lFrame.bindingIndex++}(),t)&&function No(n,t,e,i,r,s,o,a){const l=qs(t,e);let c,h=t.inputs;!a&&null!=h&&(c=h[i])?(EM(n,e,c,i,r),Wc(t)&&function kV(n,t){const e=To(t,n);16&e[Ct]||(e[Ct]|=64)}(e,t.index)):3&t.type&&(i=function OV(n){return"class"===n?"className":"for"===n?"htmlFor":"formaction"===n?"formAction":"innerHtml"===n?"innerHTML":"readonly"===n?"readOnly":"tabindex"===n?"tabIndex":n}(i),r=null!=o?o(r,t.value||"",i):r,s.setProperty(l,i,r))}(Ti(),function zr(){const n=Rt.lFrame;return xp(n.tView,n.selectedIndex)}(),i,n,t,i[Yt],e,!1),qu}function JM(n,t,e,i,r){const o=r?"class":"style";EM(n,e,t.inputs[o],o,i)}function nc(n,t,e,i){const r=Se(),s=Ti(),o=jt+n,a=r[Yt],l=s.firstCreatePass?function B8(n,t,e,i,r,s){const o=t.consts,l=Lu(t,n,2,i,al(o,r));return function bM(n,t,e,i){if(vA()){const r=null===i?null:{"":-1},s=function FV(n,t){const e=n.directiveRegistry;let i=null,r=null;if(e)for(let s=0;s($h(!0),hy(i,r,function xA(){return Rt.lFrame.currentNamespace}()));const Zu="en-US";let wk=Zu;function lw(n){return!!n&&"function"==typeof n.then}function Xk(n){return!!n&&"function"==typeof n.subscribe}function Xy(n,t,e,i){const r=Se(),s=Ti(),o=pr();return function $k(n,t,e,i,r,s,o){const a=Hm(i),h=n.firstCreatePass&&BN(n),c=t[Er],d=HN(t);let u=!0;if(3&i.type||o){const g=qs(i,t),v=o?o(g):g,y=d.length,S=o?M=>o(fr(M[i.index])):i.index;let b=null;if(!o&&a&&(b=function UW(n,t,e,i){const r=n.cleanup;if(null!=r)for(let s=0;sl?a[l]:null}"string"==typeof o&&(s+=2)}return null}(n,t,r,i.index)),null!==b)(b.__ngLastListenerFn__||b).__ngNextListenerFn__=s,b.__ngLastListenerFn__=s,u=!1;else{s=Jk(i,t,c,s,!1);const M=e.listen(v,r,s);d.push(s,M),h&&h.push(r,S,y,y+1)}}else s=Jk(i,t,c,s,!1);const f=i.outputs;let p;if(u&&null!==f&&(p=f[r])){const g=p.length;if(g)for(let v=0;v-1?To(n.index,t):t);let l=Zk(t,e,i,o),h=s.__ngNextListenerFn__;for(;h;)l=Zk(t,e,h,o)&&l,h=h.__ngNextListenerFn__;return r&&!1===l&&o.preventDefault(),l}}function QW(){return this._results[Symbol.iterator]()}class cw{get changes(){return this._changes??=new Yo}constructor(t=!1){this._emitDistinctChangesOnly=t,this.dirty=!0,this._results=[],this._changesDetected=!1,this._changes=void 0,this.length=0,this.first=void 0,this.last=void 0;const e=cw.prototype;e[Symbol.iterator]||(e[Symbol.iterator]=QW)}get(t){return this._results[t]}map(t){return this._results.map(t)}filter(t){return this._results.filter(t)}find(t){return this._results.find(t)}reduce(t,e){return this._results.reduce(t,e)}forEach(t){this._results.forEach(t)}some(t){return this._results.some(t)}toArray(){return this._results.slice()}toString(){return this._results.toString()}reset(t,e){this.dirty=!1;const i=function lo(n){return n.flat(Number.POSITIVE_INFINITY)}(t);(this._changesDetected=!function $U(n,t,e){if(n.length!==t.length)return!1;for(let i=0;i{class n{static{this.__NG_ELEMENT_ID__=qW}}return n})();const GW=oh,XW=class extends GW{constructor(t,e,i){super(),this._declarationLView=t,this._declarationTContainer=e,this.elementRef=i}get ssrId(){return this._declarationTContainer.tView?.ssrId||null}createEmbeddedView(t,e){return this.createEmbeddedViewImpl(t,e)}createEmbeddedViewImpl(t,e,i){const r=function ng(n,t,e,i){const r=t.tView,a=xy(n,r,e,4096&n[Ct]?4096:16,null,t,null,null,null,i?.injector??null,i?.dehydratedView??null);a[wp]=n[t.index];const h=n[nl];return null!==h&&(a[nl]=h.createEmbeddedView(r)),OM(r,a,e),a}(this._declarationLView,this._declarationTContainer,t,{injector:e,dehydratedView:i});return new Zp(r)}};function qW(){return qy(pr(),Se())}function qy(n,t){return 4&n.type?new XW(t,n,Au(n,t)):null}class dw{constructor(t){this.queryList=t,this.matches=null}clone(){return new dw(this.queryList)}setDirty(){this.queryList.setDirty()}}class uw{constructor(t=[]){this.queries=t}createEmbeddedView(t){const e=t.queries;if(null!==e){const i=null!==t.contentQueries?t.contentQueries[0]:e.length,r=[];for(let s=0;s0)i.push(o[a/2]);else{const h=s[a+1],c=t[-l];for(let d=mn;d($h(!0),function ly(n,t){return n.createText(t)}(t[Yt],i));function yw(n,t,e,i,r){if(n=vt(n),Array.isArray(n))for(let s=0;s>20;if(qc(n)||!n.multi){const f=new Lp(h,r,Ot),p=Iw(l,t,r?c:c+u,d);-1===p?(d1(Ym(a,o),s,l),Sw(s,n,t.length),t.push(l),a.directiveStart++,a.directiveEnd++,r&&(a.providerIndexes+=1048576),e.push(f),o.push(f)):(e[p]=f,o[p]=f)}else{const f=Iw(l,t,c+u,d),p=Iw(l,t,c,c+u),v=p>=0&&e[p];if(r&&!v||!r&&!(f>=0&&e[f])){d1(Ym(a,o),s,l);const y=function yY(n,t,e,i,r){const s=new Lp(n,e,Ot);return s.multi=[],s.index=t,s.componentProviders=0,kP(s,r,i&&!e),s}(r?mY:vY,e.length,r,i,h);!r&&v&&(e[p].providerFactory=y),Sw(s,n,t.length,0),t.push(l),a.directiveStart++,a.directiveEnd++,r&&(a.providerIndexes+=1048576),e.push(y),o.push(y)}else Sw(s,n,f>-1?f:p,kP(e[r?p:f],h,!r&&i));!r&&i&&v&&e[p].componentProviders++}}}function Sw(n,t,e,i){const r=qc(t),s=function gj(n){return!!n.useClass}(t);if(r||s){const l=(s?vt(t.useClass):t).prototype.ngOnDestroy;if(l){const h=n.destroyHooks||(n.destroyHooks=[]);if(!r&&t.multi){const c=h.indexOf(e);-1===c?h.push(e,[i,l]):h[c+1].push(i,l)}else h.push(e,l)}}}function kP(n,t,e){return e&&n.componentProviders++,n.multi.push(t)-1}function Iw(n,t,e,i){for(let r=e;r{e.providersResolver=(i,r)=>function gY(n,t,e){const i=Ti();if(i.firstCreatePass){const r=Ea(n);yw(e,i.data,i.blueprint,r,!0),yw(t,i.data,i.blueprint,r,!1)}}(i,r?r(n):n,t)}}class sd{}class zP extends sd{constructor(t){super(),this.componentFactoryResolver=new KN(this),this.instance=null;const e=new Su([...t.providers,{provide:sd,useValue:this},{provide:wy,useValue:this.componentFactoryResolver}],t.parent||ty(),t.debugName,new Set(["environment"]));this.injector=e,t.runEnvironmentInitializers&&e.resolveInjectorInitializers()}destroy(){this.injector.destroy()}onDestroy(t){this.injector.onDestroy(t)}}let wY=(()=>{class n{constructor(e){this._injector=e,this.cachedInjectors=new Map}getOrCreateStandaloneInjector(e){if(!e.standalone)return null;if(!this.cachedInjectors.has(e)){const i=qA(0,e.type),r=i.length>0?function MY(n,t,e=null){return new zP({providers:n,parent:t,debugName:e,runEnvironmentInitializers:!0}).injector}([i],this._injector,`Standalone[${e.type.name}]`):null;this.cachedInjectors.set(e,r)}return this.cachedInjectors.get(e)}ngOnDestroy(){try{for(const e of this.cachedInjectors.values())null!==e&&e.destroy()}finally{this.cachedInjectors.clear()}}static{this.\u0275prov=Yi({token:n,providedIn:"environment",factory:()=>new n(_i(ih))})}}return n})();function RP(n){(function Kc(n){WN.has(n)||(WN.add(n),performance?.mark?.("mark_feature_usage",{detail:{feature:n}}))})("NgStandalone"),n.getStandaloneInjector=t=>t.get(wY).getOrCreateStandaloneInjector(n)}let Lw=(()=>{class n{constructor(){this.taskId=0,this.pendingTasks=new Set,this.hasPendingTasks=new _o(!1)}get _hasPendingTasks(){return this.hasPendingTasks.value}add(){this._hasPendingTasks||this.hasPendingTasks.next(!0);const e=this.taskId++;return this.pendingTasks.add(e),e}remove(e){this.pendingTasks.delete(e),0===this.pendingTasks.size&&this._hasPendingTasks&&this.hasPendingTasks.next(!1)}ngOnDestroy(){this.pendingTasks.clear(),this._hasPendingTasks&&this.hasPendingTasks.next(!1)}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();const g2=new Ht(""),XQ=new Ht("");let zw=(()=>{class n{constructor(){this.initialized=!1,this.done=!1,this.donePromise=new Promise((e,i)=>{this.resolve=e,this.reject=i}),this.appInits=Hi(XQ,{optional:!0})??[]}runInitializers(){if(this.initialized)return;const e=[];for(const r of this.appInits){const s=r();if(lw(s))e.push(s);else if(Xk(s)){const o=new Promise((a,l)=>{s.subscribe({complete:a,error:l})});e.push(o)}}const i=()=>{this.done=!0,this.resolve()};Promise.all(e).then(()=>{i()}).catch(r=>{this.reject(r)}),0===e.length&&i(),this.initialized=!0}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();const v2=new Ht("");let ef=(()=>{class n{constructor(){this._bootstrapListeners=[],this._runningTick=!1,this._destroyed=!1,this._destroyListeners=[],this._views=[],this.internalErrorHandler=Hi(IN),this.afterRenderEffectManager=Hi(Jp),this.componentTypes=[],this.components=[],this.isStable=Hi(Lw).hasPendingTasks.pipe(jr(e=>!e)),this._injector=Hi(ih)}get destroyed(){return this._destroyed}get injector(){return this._injector}bootstrap(e,i){const r=e instanceof nN;if(!this._injector.get(zw).done)throw!r&&function jc(n){const t=di(n)||Wn(n)||gs(n);return null!==t&&t.standalone}(e),new F(405,!1);let o;o=r?e:this._injector.get(wy).resolveComponentFactory(e),this.componentTypes.push(o.componentType);const a=function $Q(n){return n.isBoundToModule}(o)?void 0:this._injector.get(sd),h=o.create(Wo.NULL,[],i||o.selector,a),c=h.location.nativeElement,d=h.injector.get(g2,null);return d?.registerApplication(c),h.onDestroy(()=>{this.detachView(h.hostView),t0(this.components,h),d?.unregisterApplication(c)}),this._loadComponent(h),h}tick(){if(this._runningTick)throw new F(101,!1);try{this._runningTick=!0;for(let e of this._views)e.detectChanges()}catch(e){this.internalErrorHandler(e)}finally{try{this.afterRenderEffectManager.execute()}catch(e){this.internalErrorHandler(e)}this._runningTick=!1}}attachView(e){const i=e;this._views.push(i),i.attachToAppRef(this)}detachView(e){const i=e;t0(this._views,i),i.detachFromAppRef()}_loadComponent(e){this.attachView(e.hostView),this.tick(),this.components.push(e);const i=this._injector.get(v2,[]);[...this._bootstrapListeners,...i].forEach(r=>r(e))}ngOnDestroy(){if(!this._destroyed)try{this._destroyListeners.forEach(e=>e()),this._views.slice().forEach(e=>e.destroy())}finally{this._destroyed=!0,this._views=[],this._bootstrapListeners=[],this._destroyListeners=[]}}onDestroy(e){return this._destroyListeners.push(e),()=>t0(this._destroyListeners,e)}destroy(){if(this._destroyed)throw new F(406,!1);const e=this._injector;e.destroy&&!e.destroyed&&e.destroy()}get viewCount(){return this._views.length}warnIfDestroyed(){}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();function t0(n,t){const e=n.indexOf(t);e>-1&&n.splice(e,1)}let JQ=(()=>{class n{constructor(){this.zone=Hi(Rr),this.applicationRef=Hi(ef)}initialize(){this._onMicrotaskEmptySubscription||(this._onMicrotaskEmptySubscription=this.zone.onMicrotaskEmpty.subscribe({next:()=>{this.zone.run(()=>{this.applicationRef.tick()})}}))}ngOnDestroy(){this._onMicrotaskEmptySubscription?.unsubscribe()}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();function b2(n){return[{provide:Rr,useFactory:n},{provide:yu,multi:!0,useFactory:()=>{const t=Hi(JQ,{optional:!0});return()=>t.initialize()}},{provide:yu,multi:!0,useFactory:()=>{const t=Hi(tG);return()=>{t.initialize()}}},{provide:IN,useFactory:KQ}]}function KQ(){const n=Hi(Rr),t=Hi(nh);return e=>n.runOutsideAngular(()=>t.handleError(e))}function eG(n){return function M1(n){return{\u0275providers:n}}([[],b2(()=>new Rr(function M2(n){return{enableLongStackTrace:!1,shouldCoalesceEventChangeDetection:n?.eventCoalescing??!1,shouldCoalesceRunChangeDetection:n?.runCoalescing??!1}}(n)))])}let tG=(()=>{class n{constructor(){this.subscription=new As,this.initialized=!1,this.zone=Hi(Rr),this.pendingTasks=Hi(Lw)}initialize(){if(this.initialized)return;this.initialized=!0;let e=null;!this.zone.isStable&&!this.zone.hasPendingMacrotasks&&!this.zone.hasPendingMicrotasks&&(e=this.pendingTasks.add()),this.zone.runOutsideAngular(()=>{this.subscription.add(this.zone.onStable.subscribe(()=>{Rr.assertNotInAngularZone(),queueMicrotask(()=>{null!==e&&!this.zone.hasPendingMacrotasks&&!this.zone.hasPendingMicrotasks&&(this.pendingTasks.remove(e),e=null)})}))}),this.subscription.add(this.zone.onUnstable.subscribe(()=>{Rr.assertInAngularZone(),e??=this.pendingTasks.add()}))}ngOnDestroy(){this.subscription.unsubscribe()}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();const ah=new Ht("",{providedIn:"root",factory:()=>Hi(ah,xi.Optional|xi.SkipSelf)||function iG(){return typeof $localize<"u"&&$localize.locale||Zu}()}),Rw=new Ht("");let oc=null;function DG(n){try{const{rootComponent:t,appProviders:e,platformProviders:i}=n,r=function aG(n=[]){if(oc)return oc;const t=function E2(n=[],t){return Wo.create({name:t,providers:[{provide:E1,useValue:"platform"},{provide:Rw,useValue:new Set([()=>oc=null])},...n]})}(n);return oc=t,function m2(){!function wb(n){$d=n}(()=>{throw new F(600,!1)})}(),function D2(n){n.get(oL,null)?.forEach(e=>e())}(t),t}(i),s=[eG(),...e||[]],a=new zP({providers:s,parent:r,debugName:"",runEnvironmentInitializers:!1}).injector,l=a.get(Rr);return l.run(()=>{a.resolveInjectorInitializers();const h=a.get(nh,null);let c;l.runOutsideAngular(()=>{c=l.onError.subscribe({next:f=>{h.handleError(f)}})});const d=()=>a.destroy(),u=r.get(Rw);return u.add(d),a.onDestroy(()=>{c.unsubscribe(),u.delete(d)}),function y2(n,t,e){try{const i=e();return lw(i)?i.catch(r=>{throw t.runOutsideAngular(()=>n.handleError(r)),r}):i}catch(i){throw t.runOutsideAngular(()=>n.handleError(i)),i}}(h,l,()=>{const f=a.get(zw);return f.runInitializers(),f.donePromise.then(()=>{!function Ck(n){so(n,"Expected localeId to be defined"),"string"==typeof n&&(wk=n.toLowerCase().replace(/_/g,"-"))}(a.get(ah,Zu)||Zu);const g=a.get(ef);return void 0!==t&&g.bootstrap(t),g})})})}catch(t){return Promise.reject(t)}}let $2=null;function Ww(){return $2}class UG{}const ad=new Ht("");let sq=(()=>{class n{static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275mod=km({type:n})}static{this.\u0275inj=yp({})}}return n})();function uz(n){return"server"===n}class kq extends UG{constructor(){super(...arguments),this.supportsDOMEvents=!0}}class aC extends kq{static makeCurrent(){!function _G(n){$2??=n}(new aC)}onAndCancel(t,e,i){return t.addEventListener(e,i),()=>{t.removeEventListener(e,i)}}dispatchEvent(t,e){t.dispatchEvent(e)}remove(t){t.parentNode&&t.parentNode.removeChild(t)}createElement(t,e){return(e=e||this.getDefaultDocument()).createElement(t)}createHtmlDocument(){return document.implementation.createHTMLDocument("fakeTitle")}getDefaultDocument(){return document}isElementNode(t){return t.nodeType===Node.ELEMENT_NODE}isShadowRoot(t){return t instanceof DocumentFragment}getGlobalEventTarget(t,e){return"window"===e?window:"document"===e?t:"body"===e?t.body:null}getBaseHref(t){const e=function Pq(){return Dg=Dg||document.querySelector("base"),Dg?Dg.getAttribute("href"):null}();return null==e?null:function zq(n){return new URL(n,document.baseURI).pathname}(e)}resetBaseElement(){Dg=null}getUserAgent(){return window.navigator.userAgent}getCookie(t){return function xX(n,t){t=encodeURIComponent(t);for(const e of n.split(";")){const i=e.indexOf("="),[r,s]=-1==i?[e,""]:[e.slice(0,i),e.slice(i+1)];if(r.trim()===t)return decodeURIComponent(s)}return null}(document.cookie,t)}}let Dg=null,Hq=(()=>{class n{build(){return new XMLHttpRequest}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();const lC=new Ht("");let vz=(()=>{class n{constructor(e,i){this._zone=i,this._eventNameToPlugin=new Map,e.forEach(r=>{r.manager=this}),this._plugins=e.slice().reverse()}addEventListener(e,i,r){return this._findPluginFor(i).addEventListener(e,i,r)}getZone(){return this._zone}_findPluginFor(e){let i=this._eventNameToPlugin.get(e);if(i)return i;if(i=this._plugins.find(s=>s.supports(e)),!i)throw new F(5101,!1);return this._eventNameToPlugin.set(e,i),i}static{this.\u0275fac=function(i){return new(i||n)(_i(lC),_i(Rr))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();class mz{constructor(t){this._doc=t}}const hC="ng-app-id";let yz=(()=>{class n{constructor(e,i,r,s={}){this.doc=e,this.appId=i,this.nonce=r,this.platformId=s,this.styleRef=new Map,this.hostNodes=new Set,this.styleNodesInDOM=this.collectServerRenderedStyles(),this.platformIsServer=uz(s),this.resetHostNodes()}addStyles(e){for(const i of e)1===this.changeUsageCount(i,1)&&this.onStyleAdded(i)}removeStyles(e){for(const i of e)this.changeUsageCount(i,-1)<=0&&this.onStyleRemoved(i)}ngOnDestroy(){const e=this.styleNodesInDOM;e&&(e.forEach(i=>i.remove()),e.clear());for(const i of this.getAllStyles())this.onStyleRemoved(i);this.resetHostNodes()}addHost(e){this.hostNodes.add(e);for(const i of this.getAllStyles())this.addStyleToHost(e,i)}removeHost(e){this.hostNodes.delete(e)}getAllStyles(){return this.styleRef.keys()}onStyleAdded(e){for(const i of this.hostNodes)this.addStyleToHost(i,e)}onStyleRemoved(e){const i=this.styleRef;i.get(e)?.elements?.forEach(r=>r.remove()),i.delete(e)}collectServerRenderedStyles(){const e=this.doc.head?.querySelectorAll(`style[${hC}="${this.appId}"]`);if(e?.length){const i=new Map;return e.forEach(r=>{null!=r.textContent&&i.set(r.textContent,r)}),i}return null}changeUsageCount(e,i){const r=this.styleRef;if(r.has(e)){const s=r.get(e);return s.usage+=i,s.usage}return r.set(e,{usage:i,elements:[]}),i}getStyleElement(e,i){const r=this.styleNodesInDOM,s=r?.get(i);if(s?.parentNode===e)return r.delete(i),s.removeAttribute(hC),s;{const o=this.doc.createElement("style");return this.nonce&&o.setAttribute("nonce",this.nonce),o.textContent=i,this.platformIsServer&&o.setAttribute(hC,this.appId),e.appendChild(o),o}}addStyleToHost(e,i){const r=this.getStyleElement(e,i),s=this.styleRef,o=s.get(i)?.elements;o?o.push(r):s.set(i,{elements:[r],usage:1})}resetHostNodes(){const e=this.hostNodes;e.clear(),e.add(this.doc.head)}static{this.\u0275fac=function(i){return new(i||n)(_i(ad),_i(O1),_i(aL,8),_i(bu))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();const cC={svg:"http://www.w3.org/2000/svg",xhtml:"http://www.w3.org/1999/xhtml",xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/",math:"http://www.w3.org/1998/MathML/"},dC=/%COMP%/g,Uq=new Ht("",{providedIn:"root",factory:()=>!0});function Iz(n,t){return t.map(e=>e.replace(dC,n))}let bz=(()=>{class n{constructor(e,i,r,s,o,a,l,h=null){this.eventManager=e,this.sharedStylesHost=i,this.appId=r,this.removeStylesOnCompDestroy=s,this.doc=o,this.platformId=a,this.ngZone=l,this.nonce=h,this.rendererByCompId=new Map,this.platformIsServer=uz(a),this.defaultRenderer=new uC(e,o,l,this.platformIsServer)}createRenderer(e,i){if(!e||!i)return this.defaultRenderer;this.platformIsServer&&i.encapsulation===ba.ShadowDom&&(i={...i,encapsulation:ba.Emulated});const r=this.getOrCreateRenderer(e,i);return r instanceof wz?r.applyToHost(e):r instanceof fC&&r.applyStyles(),r}getOrCreateRenderer(e,i){const r=this.rendererByCompId;let s=r.get(i.id);if(!s){const o=this.doc,a=this.ngZone,l=this.eventManager,h=this.sharedStylesHost,c=this.removeStylesOnCompDestroy,d=this.platformIsServer;switch(i.encapsulation){case ba.Emulated:s=new wz(l,h,i,this.appId,c,o,a,d);break;case ba.ShadowDom:return new Yq(l,h,e,i,o,a,this.nonce,d);default:s=new fC(l,h,i,c,o,a,d)}r.set(i.id,s)}return s}ngOnDestroy(){this.rendererByCompId.clear()}static{this.\u0275fac=function(i){return new(i||n)(_i(vz),_i(yz),_i(O1),_i(Uq),_i(ad),_i(bu),_i(Rr),_i(aL))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();class uC{constructor(t,e,i,r){this.eventManager=t,this.doc=e,this.ngZone=i,this.platformIsServer=r,this.data=Object.create(null),this.throwOnSyntheticProps=!0,this.destroyNode=null}destroy(){}createElement(t,e){return e?this.doc.createElementNS(cC[e]||e,t):this.doc.createElement(t)}createComment(t){return this.doc.createComment(t)}createText(t){return this.doc.createTextNode(t)}appendChild(t,e){(Mz(t)?t.content:t).appendChild(e)}insertBefore(t,e,i){t&&(Mz(t)?t.content:t).insertBefore(e,i)}removeChild(t,e){t&&t.removeChild(e)}selectRootElement(t,e){let i="string"==typeof t?this.doc.querySelector(t):t;if(!i)throw new F(-5104,!1);return e||(i.textContent=""),i}parentNode(t){return t.parentNode}nextSibling(t){return t.nextSibling}setAttribute(t,e,i,r){if(r){e=r+":"+e;const s=cC[r];s?t.setAttributeNS(s,e,i):t.setAttribute(e,i)}else t.setAttribute(e,i)}removeAttribute(t,e,i){if(i){const r=cC[i];r?t.removeAttributeNS(r,e):t.removeAttribute(`${i}:${e}`)}else t.removeAttribute(e)}addClass(t,e){t.classList.add(e)}removeClass(t,e){t.classList.remove(e)}setStyle(t,e,i,r){r&(ec.DashCase|ec.Important)?t.style.setProperty(e,i,r&ec.Important?"important":""):t.style[e]=i}removeStyle(t,e,i){i&ec.DashCase?t.style.removeProperty(e):t.style[e]=""}setProperty(t,e,i){null!=t&&(t[e]=i)}setValue(t,e){t.nodeValue=e}listen(t,e,i){if("string"==typeof t&&!(t=Ww().getGlobalEventTarget(this.doc,t)))throw new Error(`Unsupported event target ${t} for event ${e}`);return this.eventManager.addEventListener(t,e,this.decoratePreventDefault(i))}decoratePreventDefault(t){return e=>{if("__ngUnwrap__"===e)return t;!1===(this.platformIsServer?this.ngZone.runGuarded(()=>t(e)):t(e))&&e.preventDefault()}}}function Mz(n){return"TEMPLATE"===n.tagName&&void 0!==n.content}class Yq extends uC{constructor(t,e,i,r,s,o,a,l){super(t,s,o,l),this.sharedStylesHost=e,this.hostEl=i,this.shadowRoot=i.attachShadow({mode:"open"}),this.sharedStylesHost.addHost(this.shadowRoot);const h=Iz(r.id,r.styles);for(const c of h){const d=document.createElement("style");a&&d.setAttribute("nonce",a),d.textContent=c,this.shadowRoot.appendChild(d)}}nodeOrShadowRoot(t){return t===this.hostEl?this.shadowRoot:t}appendChild(t,e){return super.appendChild(this.nodeOrShadowRoot(t),e)}insertBefore(t,e,i){return super.insertBefore(this.nodeOrShadowRoot(t),e,i)}removeChild(t,e){return super.removeChild(this.nodeOrShadowRoot(t),e)}parentNode(t){return this.nodeOrShadowRoot(super.parentNode(this.nodeOrShadowRoot(t)))}destroy(){this.sharedStylesHost.removeHost(this.shadowRoot)}}class fC extends uC{constructor(t,e,i,r,s,o,a,l){super(t,s,o,a),this.sharedStylesHost=e,this.removeStylesOnCompDestroy=r,this.styles=l?Iz(l,i.styles):i.styles}applyStyles(){this.sharedStylesHost.addStyles(this.styles)}destroy(){this.removeStylesOnCompDestroy&&this.sharedStylesHost.removeStyles(this.styles)}}class wz extends fC{constructor(t,e,i,r,s,o,a,l){const h=r+"-"+i.id;super(t,e,i,s,o,a,l,h),this.contentAttr=function jq(n){return"_ngcontent-%COMP%".replace(dC,n)}(h),this.hostAttr=function Vq(n){return"_nghost-%COMP%".replace(dC,n)}(h)}applyToHost(t){this.applyStyles(),this.setAttribute(t,this.hostAttr,"")}createElement(t,e){const i=super.createElement(t,e);return super.setAttribute(i,this.contentAttr,""),i}}let Qq=(()=>{class n extends mz{constructor(e){super(e)}supports(e){return!0}addEventListener(e,i,r){return e.addEventListener(i,r,!1),()=>this.removeEventListener(e,i,r)}removeEventListener(e,i,r){return e.removeEventListener(i,r)}static{this.\u0275fac=function(i){return new(i||n)(_i(ad))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();const Cz=["alt","control","meta","shift"],Gq={"\b":"Backspace","\t":"Tab","\x7f":"Delete","\x1b":"Escape",Del:"Delete",Esc:"Escape",Left:"ArrowLeft",Right:"ArrowRight",Up:"ArrowUp",Down:"ArrowDown",Menu:"ContextMenu",Scroll:"ScrollLock",Win:"OS"},Xq={alt:n=>n.altKey,control:n=>n.ctrlKey,meta:n=>n.metaKey,shift:n=>n.shiftKey};let qq=(()=>{class n extends mz{constructor(e){super(e)}supports(e){return null!=n.parseEventName(e)}addEventListener(e,i,r){const s=n.parseEventName(i),o=n.eventCallback(s.fullKey,r,this.manager.getZone());return this.manager.getZone().runOutsideAngular(()=>Ww().onAndCancel(e,s.domEventName,o))}static parseEventName(e){const i=e.toLowerCase().split("."),r=i.shift();if(0===i.length||"keydown"!==r&&"keyup"!==r)return null;const s=n._normalizeKey(i.pop());let o="",a=i.indexOf("code");if(a>-1&&(i.splice(a,1),o="code."),Cz.forEach(h=>{const c=i.indexOf(h);c>-1&&(i.splice(c,1),o+=h+".")}),o+=s,0!=i.length||0===s.length)return null;const l={};return l.domEventName=r,l.fullKey=o,l}static matchEventFullKeyCode(e,i){let r=Gq[e.key]||e.key,s="";return i.indexOf("code.")>-1&&(r=e.code,s="code."),!(null==r||!r)&&(r=r.toLowerCase()," "===r?r="space":"."===r&&(r="dot"),Cz.forEach(o=>{o!==r&&(0,Xq[o])(e)&&(s+=o+".")}),s+=r,s===i)}static eventCallback(e,i,r){return s=>{n.matchEventFullKeyCode(s,e)&&r.runGuarded(()=>i(s))}}static _normalizeKey(e){return"esc"===e?"escape":e}static{this.\u0275fac=function(i){return new(i||n)(_i(ad))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();function Ez(n){return{appProviders:[...i$,...n?.providers??[]],platformProviders:e$}}const e$=[{provide:bu,useValue:"browser"},{provide:oL,useValue:function Zq(){aC.makeCurrent()},multi:!0},{provide:ad,useFactory:function Kq(){return function Aj(n){N1=n}(document),document},deps:[]}],i$=[{provide:E1,useValue:"root"},{provide:nh,useFactory:function Jq(){return new nh},deps:[]},{provide:lC,useClass:Qq,multi:!0,deps:[ad,Rr,bu]},{provide:lC,useClass:qq,multi:!0,deps:[ad]},bz,yz,vz,{provide:oN,useExisting:bz},{provide:class cq{},useClass:Hq,deps:[]},[]];var o$=0,pC=!1;function C0(n,t){var e=t;return e.unshift(void 0),new(Function.prototype.bind.apply(n,e))}function Y(n,t){for(var e=t,i=n.replace(/\[/g,".").replace(/\]/g,"").split("."),r=0;r"u"}function Ei(n){return n+"_"+o$++}function D0(n,t){return n===t||!(n===document||!n)&&D0(n.parentNode,t)}function Ag(n){try{throw new Error(n)}catch(t){throw new Error(t.message+"\n"+t.stack)}}function Re(n){var t=n+"";return t.match(/auto|cm|mm|in|px|pt|pc|%|em|ex|ch|rem|vw|vh|vmin|vmax/)?t:t+"px"}function ce(){return pC}var Lg,n,t,d$={latn:{_digits:"0123456789",_type:"numeric"}},Lz={decimal:".",group:",",percentSign:"%",plusSign:"+",minusSign:"-",infinity:"\u221e",nan:"NaN",exponential:"E"},Nz=[0,1,2,3,4,5,6,7,8,9],Hr=function(){function n(){}return n.getMainObject=function(t,e){return Y(ce()?e:"main."+e,t)},n.getNumberingSystem=function(t){return Y("supplemental.numberingSystems",t)||this.numberingSystems},n.reverseObject=function(t,e){for(var r={},s=0,o=e||Object.keys(t);s13&&(p+=1,o-=12),o-=1,a=p-4716;var y=u-24e5,S=10631/30,b=u-1948084,M=Math.floor(b/10631);b-=10631*M;var w=Math.floor((b-.1335)/S),C=30*M+w;b-=Math.floor(w*S+.1335);var D=Math.floor((b+28.5001)/29.5);13===D&&(D=12);for(var A=b-Math.floor(29.5001*D-29),x=0;xy);x++);var P=x+16260,L=Math.floor((P-1)/12),O=L+1,N=P-12*L,T=y-t[x-1]+1;return(T+"").length>2&&(T=A,N=D,O=C),{year:O,month:N,date:T}},n.toGregorian=function i(r,s,o){var g=Math.floor(o+t[12*(r-1)+1+(s-1)-16260-1]-1+24e5+.5),v=Math.floor((g-1867216.25)/36524.25),y=1524+(v=g+1+v-Math.floor(v/4)),S=Math.floor((y-122.1)/365.25),b=Math.floor(365.25*S),M=Math.floor((y-b)/30.6001),w=y-b-Math.floor(30.6001*M),C=M-(M>13.5?13:1),D=S-(C>2.5?4716:4715);return D<=0&&C--,new Date(D+"/"+C+"/"+w)};var ut,p$=/\/MMMMM|MMMM|MMM|a|LLLL|LLL|EEEEE|EEEE|E|K|cccc|ccc|WW|W|G+|z+/gi,Oz="stand-alone",g$=["sun","mon","tue","wed","thu","fri","sat"],kz={m:"getMinutes",h:"getHours",H:"getHours",s:"getSeconds",d:"getDate",f:"getMilliseconds"},Pz=function(){function n(){}return n.dateFormat=function(t,e,i){var r=this,s=ut.getDependables(i,t,e.calendar),o=Y("parserObject.numbers",s),a=s.dateObject,l={isIslamic:ut.islamicRegex.test(e.calendar)};ce()&&e.isServerRendered&&(e=ut.compareBlazorDateFormats(e,t));var h=e.format||ut.getResultantPattern(e.skeleton,s.dateObject,e.type,!1,ce()?t:"");if(l.dateSeperator=ce()?Y("dateSeperator",a):ut.getDateSeparator(s.dateObject),st(h))Ag("Format options or type given must be invalid");else{h=ut.ConvertDateToWeekFormat(h),ce()&&(h=h.replace(/tt/,"a")),l.pattern=h,l.numMapper=ce()?ze({},o):Hr.getNumberMapper(s.parserObject,Hr.getNumberingSystem(i));for(var d=0,u=h.match(p$)||[];d2?r+=e.month[""+u]:p=!0;break;case"E":case"c":r+=e.weekday[""+g$[t.getDay()]];break;case"H":case"h":case"m":case"s":case"d":case"f":if(p=!0,"d"===d)u=o.date;else if("f"===d){p=!1,g=!0;var y=(f=(f=t[""+kz[""+d]]().toString()).substring(0,c)).length;if(c!==y){if(c>3)continue;for(var S=0;S0?1:0],o=Math.abs(t);return s.replace(/HH?|mm/g,function(a){var l=a.length,h=-1!==a.indexOf("H");return i.checkTwodigitNumber(Math.floor(h?o/60:o%60),l)})},n}(),zz={ms:"minimumSignificantDigits",ls:"maximumSignificantDigits",mf:"minimumFractionDigits",lf:"maximumFractionDigits"},sf=["infinity","nan","group","decimal","exponential"],Rz=function(){function n(){}return n.numberFormatter=function(t,e,i){var l,r=this,s=ze({},e),o={},a={},h=ut.getDependables(i,t,"",!0),c=h.numericObject;a.numberMapper=ce()?ze({},c):Hr.getNumberMapper(h.parserObject,Hr.getNumberingSystem(i),!0),a.currencySymbol=ce()?Y("currencySymbol",c):ut.getCurrencySymbol(h.numericObject,s.currency||kg,e.altSymbol,e.ignoreCurrency),a.percentSymbol=ce()?Y("numberSymbols.percentSign",c):a.numberMapper.numberSymbols.percentSign,a.minusSymbol=ce()?Y("numberSymbols.minusSign",c):a.numberMapper.numberSymbols.minusSign;var d=a.numberMapper.numberSymbols;if(e.format&&!ut.formatRegex.test(e.format))o=ut.customFormat(e.format,a,h.numericObject),!st(s.useGrouping)&&s.useGrouping&&(s.useGrouping=o.pData.useGrouping);else{if(ze(s,ut.getProperNumericSkeleton(e.format||"N")),s.isCurrency="currency"===s.type,s.isPercent="percent"===s.type,ce()||(l=ut.getSymbolPattern(s.type,a.numberMapper.numberSystem,h.numericObject,s.isAccount)),s.groupOne=this.checkValueRange(s.maximumSignificantDigits,s.minimumSignificantDigits,!0),this.checkValueRange(s.maximumFractionDigits,s.minimumFractionDigits,!1,!0),st(s.fractionDigits)||(s.minimumFractionDigits=s.maximumFractionDigits=s.fractionDigits),st(s.useGrouping)&&(s.useGrouping=!0),s.isCurrency&&!ce()&&(l=l.replace(/\u00A4/g,ut.defaultCurrency)),ce())o.nData=ze({},{},Y(s.type+"nData",c)),o.pData=ze({},{},Y(s.type+"pData",c)),"currency"===s.type&&e.currency&&ut.replaceBlazorCurrency([o.pData,o.nData],a.currencySymbol,e.currency);else{var u=l.split(";");o.nData=ut.getFormatData(u[1]||"-"+u[0],!0,a.currencySymbol),o.pData=ut.getFormatData(u[0],!1,a.currencySymbol),s.useGrouping&&(s.groupSeparator=d[sf[2]],s.groupData=this.getGroupingDetails(u[0]))}if(st(s.minimumFractionDigits)&&(s.minimumFractionDigits=o.nData.minimumFraction),st(s.maximumFractionDigits)){var p=o.nData.maximumFraction;s.maximumFractionDigits=st(p)&&s.isPercent?0:p}var g=s.minimumFractionDigits,v=s.maximumFractionDigits;!st(g)&&!st(v)&&g>v&&(s.maximumFractionDigits=g)}return ze(o.nData,s),ze(o.pData,s),function(y){return isNaN(y)?d[sf[1]]:isFinite(y)?r.intNumberFormatter(y,o,a,e):d[sf[0]]}},n.getGroupingDetails=function(t){var e={},i=t.match(ut.negativeDataRegex);if(i&&i[4]){var r=i[4],s=r.lastIndexOf(",");if(-1!==s){var o=r.split(".")[0];e.primary=o.length-s-1;var a=r.lastIndexOf(",",s-1);-1!==a&&(e.secondary=s-1-a)}}return e},n.checkValueRange=function(t,e,i,r){var s=r?"f":"s",o=0,a=zz["l"+s],l=zz["m"+s];if(st(t)||(this.checkRange(t,a,r),o++),st(e)||(this.checkRange(e,l,r),o++),2===o){if(!(tr[1])&&Ag(e+"value must be within the range"+r[0]+"to"+r[1])},n.intNumberFormatter=function(t,e,i,r){var s;if(!st(e.nData.type)){t<0?(t*=-1,s=e.nData):s=0===t&&e.zeroData||e.pData;var o="";if(s.isPercent&&(t*=100),s.groupOne)o=this.processSignificantDigits(t,s.minimumSignificantDigits,s.maximumSignificantDigits);else if(o=this.processFraction(t,s.minimumFractionDigits,s.maximumFractionDigits,r),s.minimumIntegerDigits&&(o=this.processMinimumIntegers(o,s.minimumIntegerDigits)),i.isCustomFormat&&s.minimumFractionDigits=0&&"0"===l[parseInt(c.toString(),10)]&&c>=s.minimumFractionDigits;c--)l=l.slice(0,c);o=a[0]+"."+l}return"scientific"===s.type&&(o=(o=t.toExponential(s.maximumFractionDigits)).replace("e",i.numberMapper.numberSymbols[sf[4]])),o=o.replace(".",i.numberMapper.numberSymbols[sf[3]]),o="#,###,,;(#,###,,)"===s.format?this.customPivotFormat(parseInt(o,10)):o,s.useGrouping&&(o=this.groupNumbers(o,s.groupData.primary,s.groupSeparator||",",i.numberMapper.numberSymbols[sf[3]]||".",s.groupData.secondary)),o=Hr.convertValueParts(o,ut.latnParseRegex,i.numberMapper.mapper),"N/A"===s.nlead?s.nlead:"0"===o&&r&&"0"===r.format?o+s.nend:s.nlead+o+s.nend}},n.processSignificantDigits=function(t,e,i){var r=t+"";return r.lengthe;)c=l.slice(h-e,h)+(c.length?i+c:""),h-=e,o&&(e=s,o=!1);return a[0]=l.slice(0,h)+(c.length?i:"")+c,a.join(r)},n.processFraction=function(t,e,i,r){var s=(t+"").split(".")[1],o=s?s.length:0;if(e&&oi||0===i))return t.toFixed(i);var h=t+"";return"0"===h[0]&&r&&"###.00"===r.format&&(h=h.slice(1)),h},n.processMinimumIntegers=function(t,e){var i=t.split("."),r=i[0],s=r.length;if(s=5e5){var r=(t/=1e6).toString().split(".")[1];return r&&+r.substring(0,1)>=5?Math.ceil(t).toString():Math.floor(t).toString()}return""},n}(),Ng=(new RegExp("^([^0-9]*)(([0-9,]*[0-9]+)(.[0-9]+)?)([Ee][+-]?[0-9]+)?([^0-9]*)$"),function(){function n(t){this.ranArray=[],this.boundedEvents={},!m(t)&&(this.context=t)}return n.prototype.on=function(t,e,i,r){if(!m(e)){var s=i||this.context;if(this.notExist(t))return void(this.boundedEvents[""+t]=[{handler:e,context:s,id:r}]);m(r)?this.isHandlerPresent(this.boundedEvents[""+t],e)||this.boundedEvents[""+t].push({handler:e,context:s}):-1===this.ranArray.indexOf(r)&&(this.ranArray.push(r),this.boundedEvents[""+t].push({handler:e,context:s,id:r}))}},n.prototype.off=function(t,e,i){if(!this.notExist(t)){var r=Y(t,this.boundedEvents);if(e){for(var s=0;s1&&(U.fractionDigits=parseInt(z[2],10)),U}function p(T,z,U,B){var j=B?{}:{nlead:"",nend:""},Q=T.match(n.customRegex);if(Q){B||(j.nlead=g(Q[1],U),j.nend=g(Q[10],U),j.groupPattern=Q[4]);var oe=Q[7];if(oe&&z){var ue=oe.match(t);j.minimumFraction=m(ue)?0:ue.length,j.maximumFraction=oe.length-1}}return j}function g(T,z){return T?(T=T.replace(n.defaultCurrency,z),""===z?T.trim():T):""}function v(T,z,U,B){return B?"$":Y("currencies."+z+(U?"."+U:".symbol"),T)||Y("currencies."+z+".symbol-alt-narrow",T)||"$"}function S(T,z,U){var B={type:"decimal",minimumFractionDigits:0,maximumFractionDigits:0},j=T.match(n.customRegex);if(m(j)||""===j[5]&&"N/A"!==T)return B.type=void 0,B;B.nlead=j[1],B.nend=j[10];var Q=j[6],oe=!!Q.match(/ $/g),ue=-1!==Q.replace(/ $/g,"").indexOf(" ");B.useGrouping=-1!==Q.indexOf(",")||ue,Q=Q.replace(/,/g,"");var fe=j[7];if(-1!==Q.indexOf("0")&&(B.minimumIntegerDigits=Q.length-Q.indexOf("0")),m(fe)||(B.minimumFractionDigits=fe.lastIndexOf("0"),B.maximumFractionDigits=fe.lastIndexOf("#"),-1===B.minimumFractionDigits&&(B.minimumFractionDigits=0),(-1===B.maximumFractionDigits||B.maximumFractionDigitsQ.lastIndexOf("'"))){B[""+a[parseInt(j.toString(),10)]]=Q.substr(0,oe)+U+Q.substr(oe+1),B[""+a[""+z]]=!0,B.type=B.isCurrency?"currency":"percent";break}}return B}function C(T,z){if(-1!==T.indexOf(",")){var U=T.split(",");T=U[0]+Y("numberMapper.numberSymbols.group",z)+U[1].replace(".",Y("numberMapper.numberSymbols.decimal",z))}else T=T.replace(".",Y("numberMapper.numberSymbols.decimal",z));return T}function A(T,z,U){T+=".";for(var B=0;B0;Q-=3)T=","+U[Q-2]+U[Q-1]+U[parseInt(Q.toString(),10)]+T;return T=T.slice(1),z[1]?T+"."+z[1]:T}n.dateParseRegex=/([a-z])\1*|'([^']|'')+'|''|./gi,n.basicPatterns=["short","medium","long","full"],n.defaultObject={dates:{calendars:{gregorian:{months:{"stand-alone":{abbreviated:{1:"Jan",2:"Feb",3:"Mar",4:"Apr",5:"May",6:"Jun",7:"Jul",8:"Aug",9:"Sep",10:"Oct",11:"Nov",12:"Dec"},narrow:{1:"J",2:"F",3:"M",4:"A",5:"M",6:"J",7:"J",8:"A",9:"S",10:"O",11:"N",12:"D"},wide:{1:"January",2:"February",3:"March",4:"April",5:"May",6:"June",7:"July",8:"August",9:"September",10:"October",11:"November",12:"December"}}},days:{"stand-alone":{abbreviated:{sun:"Sun",mon:"Mon",tue:"Tue",wed:"Wed",thu:"Thu",fri:"Fri",sat:"Sat"},narrow:{sun:"S",mon:"M",tue:"T",wed:"W",thu:"T",fri:"F",sat:"S"},short:{sun:"Su",mon:"Mo",tue:"Tu",wed:"We",thu:"Th",fri:"Fr",sat:"Sa"},wide:{sun:"Sunday",mon:"Monday",tue:"Tuesday",wed:"Wednesday",thu:"Thursday",fri:"Friday",sat:"Saturday"}}},dayPeriods:{format:{wide:{am:"AM",pm:"PM"}}},eras:{eraNames:{0:"Before Christ","0-alt-variant":"Before Common Era",1:"Anno Domini","1-alt-variant":"Common Era"},eraAbbr:{0:"BC","0-alt-variant":"BCE",1:"AD","1-alt-variant":"CE"},eraNarrow:{0:"B","0-alt-variant":"BCE",1:"A","1-alt-variant":"CE"}},dateFormats:{full:"EEEE, MMMM d, y",long:"MMMM d, y",medium:"MMM d, y",short:"M/d/yy"},timeFormats:{full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},dateTimeFormats:{full:"{1} 'at' {0}",long:"{1} 'at' {0}",medium:"{1}, {0}",short:"{1}, {0}",availableFormats:{d:"d",E:"ccc",Ed:"d E",Ehm:"E h:mm a",EHm:"E HH:mm",Ehms:"E h:mm:ss a",EHms:"E HH:mm:ss",Gy:"y G",GyMMM:"MMM y G",GyMMMd:"MMM d, y G",GyMMMEd:"E, MMM d, y G",h:"h a",H:"HH",hm:"h:mm a",Hm:"HH:mm",hms:"h:mm:ss a",Hms:"HH:mm:ss",hmsv:"h:mm:ss a v",Hmsv:"HH:mm:ss v",hmv:"h:mm a v",Hmv:"HH:mm v",M:"L",Md:"M/d",MEd:"E, M/d",MMM:"LLL",MMMd:"MMM d",MMMEd:"E, MMM d",MMMMd:"MMMM d",ms:"mm:ss",y:"y",yM:"M/y",yMd:"M/d/y",yMEd:"E, M/d/y",yMMM:"MMM y",yMMMd:"MMM d, y",yMMMEd:"E, MMM d, y",yMMMM:"MMMM y"}}},islamic:{months:{"stand-alone":{abbreviated:{1:"Muh.",2:"Saf.",3:"Rab. I",4:"Rab. II",5:"Jum. I",6:"Jum. II",7:"Raj.",8:"Sha.",9:"Ram.",10:"Shaw.",11:"Dhu\u02bbl-Q.",12:"Dhu\u02bbl-H."},narrow:{1:"1",2:"2",3:"3",4:"4",5:"5",6:"6",7:"7",8:"8",9:"9",10:"10",11:"11",12:"12"},wide:{1:"Muharram",2:"Safar",3:"Rabi\u02bb I",4:"Rabi\u02bb II",5:"Jumada I",6:"Jumada II",7:"Rajab",8:"Sha\u02bbban",9:"Ramadan",10:"Shawwal",11:"Dhu\u02bbl-Qi\u02bbdah",12:"Dhu\u02bbl-Hijjah"}}},days:{"stand-alone":{abbreviated:{sun:"Sun",mon:"Mon",tue:"Tue",wed:"Wed",thu:"Thu",fri:"Fri",sat:"Sat"},narrow:{sun:"S",mon:"M",tue:"T",wed:"W",thu:"T",fri:"F",sat:"S"},short:{sun:"Su",mon:"Mo",tue:"Tu",wed:"We",thu:"Th",fri:"Fr",sat:"Sa"},wide:{sun:"Sunday",mon:"Monday",tue:"Tuesday",wed:"Wednesday",thu:"Thursday",fri:"Friday",sat:"Saturday"}}},dayPeriods:{format:{wide:{am:"AM",pm:"PM"}}},eras:{eraNames:{0:"AH"},eraAbbr:{0:"AH"},eraNarrow:{0:"AH"}},dateFormats:{full:"EEEE, MMMM d, y G",long:"MMMM d, y G",medium:"MMM d, y G",short:"M/d/y GGGGG"},timeFormats:{full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},dateTimeFormats:{full:"{1} 'at' {0}",long:"{1} 'at' {0}",medium:"{1}, {0}",short:"{1}, {0}",availableFormats:{d:"d",E:"ccc",Ed:"d E",Ehm:"E h:mm a",EHm:"E HH:mm",Ehms:"E h:mm:ss a",EHms:"E HH:mm:ss",Gy:"y G",GyMMM:"MMM y G",GyMMMd:"MMM d, y G",GyMMMEd:"E, MMM d, y G",h:"h a",H:"HH",hm:"h:mm a",Hm:"HH:mm",hms:"h:mm:ss a",Hms:"HH:mm:ss",M:"L",Md:"M/d",MEd:"E, M/d",MMM:"LLL",MMMd:"MMM d",MMMEd:"E, MMM d",MMMMd:"MMMM d",ms:"mm:ss",y:"y G",yyyy:"y G",yyyyM:"M/y GGGGG",yyyyMd:"M/d/y GGGGG",yyyyMEd:"E, M/d/y GGGGG",yyyyMMM:"MMM y G",yyyyMMMd:"MMM d, y G",yyyyMMMEd:"E, MMM d, y G",yyyyMMMM:"MMMM y G",yyyyQQQ:"QQQ y G",yyyyQQQQ:"QQQQ y G"}}}},timeZoneNames:{hourFormat:"+HH:mm;-HH:mm",gmtFormat:"GMT{0}",gmtZeroFormat:"GMT"}},numbers:{currencies:{USD:{displayName:"US Dollar",symbol:"$","symbol-alt-narrow":"$"},EUR:{displayName:"Euro",symbol:"\u20ac","symbol-alt-narrow":"\u20ac"},GBP:{displayName:"British Pound","symbol-alt-narrow":"\xa3"}},defaultNumberingSystem:"latn",minimumGroupingDigits:"1","symbols-numberSystem-latn":{decimal:".",group:",",list:";",percentSign:"%",plusSign:"+",minusSign:"-",exponential:"E",superscriptingExponent:"\xd7",perMille:"\u2030",infinity:"\u221e",nan:"NaN",timeSeparator:":"},"decimalFormats-numberSystem-latn":{standard:"#,##0.###"},"percentFormats-numberSystem-latn":{standard:"#,##0%"},"currencyFormats-numberSystem-latn":{standard:"\xa4#,##0.00",accounting:"\xa4#,##0.00;(\xa4#,##0.00)"},"scientificFormats-numberSystem-latn":{standard:"#E0"}}},n.blazorDefaultObject={numbers:{mapper:{0:"0",1:"1",2:"2",3:"3",4:"4",5:"5",6:"6",7:"7",8:"8",9:"9"},mapperDigits:"0123456789",numberSymbols:{decimal:".",group:",",plusSign:"+",minusSign:"-",percentSign:"%",nan:"NaN",timeSeparator:":",infinity:"\u221e"},timeSeparator:":",currencySymbol:"$",currencypData:{nlead:"$",nend:"",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},percentpData:{nlead:"",nend:"%",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},percentnData:{nlead:"-",nend:"%",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},currencynData:{nlead:"($",nend:")",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},decimalnData:{nlead:"-",nend:"",groupData:{primary:3},maximumFraction:2,minimumFraction:2},decimalpData:{nlead:"",nend:"",groupData:{primary:3},maximumFraction:2,minimumFraction:2}},dates:{dayPeriods:{am:"AM",pm:"PM"},dateSeperator:"/",days:{abbreviated:{sun:"Sun",mon:"Mon",tue:"Tue",wed:"Wed",thu:"Thu",fri:"Fri",sat:"Sat"},short:{sun:"Su",mon:"Mo",tue:"Tu",wed:"We",thu:"Th",fri:"Fr",sat:"Sa"},wide:{sun:"Sunday",mon:"Monday",tue:"Tuesday",wed:"Wednesday",thu:"Thursday",fri:"Friday",sat:"Saturday"}},months:{abbreviated:{1:"Jan",2:"Feb",3:"Mar",4:"Apr",5:"May",6:"Jun",7:"Jul",8:"Aug",9:"Sep",10:"Oct",11:"Nov",12:"Dec"},wide:{1:"January",2:"February",3:"March",4:"April",5:"May",6:"June",7:"July",8:"August",9:"September",10:"October",11:"November",12:"December"}},eras:{1:"AD"}}},n.monthIndex={3:"abbreviated",4:"wide",5:"narrow",1:"abbreviated"},n.month="months",n.days="days",n.patternMatcher={C:"currency",P:"percent",N:"decimal",A:"currency",E:"scientific"},n.getResultantPattern=l,n.getDependables=h,n.getSymbolPattern=c,n.ConvertDateToWeekFormat=d,n.compareBlazorDateFormats=u,n.getProperNumericSkeleton=f,n.getFormatData=p,n.changeCurrencySymbol=g,n.getCurrencySymbol=v,n.customFormat=function y(T,z,U){for(var B={},j=T.split(";"),Q=["pData","nData","zeroData"],oe=0;oe1,fe.nData=ce()?Y(De.type+"nData",oe):p(ot[1]||"-"+ot[0],!0,Ie),fe.pData=ce()?Y(De.type+"pData",oe):p(ot[0],!1,Ie),!Me[2]&&!z.minimumFractionDigits&&!z.maximumFractionDigits&&(ue=p(Ve.split(";")[0],!0,"",!0).minimumFraction)}if(n.formatRegex.test(z.format)||!z.format){if(ze(Q,f(z.format||"N")),Q.custom=!1,$e="###0",(Q.fractionDigits||z.minimumFractionDigits||z.maximumFractionDigits||ue)&&(Q.fractionDigits&&(z.minimumFractionDigits=z.maximumFractionDigits=Q.fractionDigits),$e=A($e,ue||Q.fractionDigits||z.minimumFractionDigits||0,z.maximumFractionDigits||0)),z.minimumIntegerDigits&&($e=x($e,z.minimumIntegerDigits)),z.useGrouping&&($e=P($e)),"currency"===Q.type||Q.type&&ce()){ce()&&"currency"!==Q.type&&(fe.pData=Y(Q.type+"pData",oe),fe.nData=Y(Q.type+"nData",oe));var hr=$e;$e=fe.pData.nlead+hr+fe.pData.nend,(fe.hasNegativePattern||ce())&&($e+=";"+fe.nData.nlead+hr+fe.nData.nend)}"percent"===Q.type&&!ce()&&($e+=" %")}else $e=z.format.replace(/'/g,'"');return Object.keys(xe).length>0&&($e=B?$e:C($e,xe)),$e},n.fractionDigitsPattern=A,n.minimumIntegerPattern=x,n.groupingPattern=P,n.getWeekData=function L(T,z){var U="sun",B=Y("supplemental.weekData.firstDay",z),j=T;return/en-/.test(j)&&(j=j.slice(3)),j=j.slice(0,2).toUpperCase()+j.substr(2),B&&(U=B[""+j]||B[j.slice(0,2)]||"sun"),o[""+U]},n.replaceBlazorCurrency=function O(T,z,U){var B=function f$(n){return Y(n||"",u$)}(U);if(z!==B)for(var j=0,Q=T;j=0?U:U+7;var j=Math.floor((T.getTime()-z.getTime()-6e4*(T.getTimezoneOffset()-z.getTimezoneOffset()))/864e5)+1;if(U<4){if((B=Math.floor((j+U-1)/7)+1)>52){var oe=new Date(T.getFullYear()+1,0,1).getDay();B=(oe=oe>=0?oe:oe+7)<4?1:53}}else B=Math.floor((j+U-1)/7);return B}}(ut||(ut={}));var of=function(){function n(t,e,i){this.type="GET",this.emitError=!0,"string"==typeof t?(this.url=t,this.type=m(e)?this.type:e.toUpperCase(),this.contentType=i):La(t)&&Object.keys(t).length>0&&kn(this,t),this.contentType=m(this.contentType)?"application/json; charset=utf-8":this.contentType}return n.prototype.send=function(t){var e=this,i={"application/json":"json","multipart/form-data":"formData","application/octet-stream":"blob","application/x-www-form-urlencoded":"formData"};try{m(this.fetchRequest)&&"GET"===this.type?this.fetchRequest=new Request(this.url,{method:this.type}):m(this.fetchRequest)&&(this.data=m(t)?this.data:t,this.fetchRequest=new Request(this.url,{method:this.type,headers:{"Content-Type":this.contentType},body:this.data}));var r={cancel:!1,fetchRequest:this.fetchRequest};return this.triggerEvent(this.beforeSend,r),r.cancel?null:(this.fetchResponse=fetch(this.fetchRequest),this.fetchResponse.then(function(s){if(e.triggerEvent(e.onLoad,s),!s.ok)throw s;for(var o="text",a=0,l=Object.keys(i);a-1},n.getValue=function(t,e){var i=typeof window<"u"?window.browserDetails:{};return typeof navigator<"u"&&"MacIntel"===navigator.platform&&navigator.maxTouchPoints>1&&!0===n.isTouch&&!mC.CHROME.test(navigator.userAgent)&&(i.isIos=!0,i.isDevice=!0,i.isTouch=!0,i.isPointer=!0,i.isPointer="pointerEnabled"in window.navigator),typeof window<"u"&&window.Capacitor&&"ios"===window.Capacitor.getPlatform()&&(i.isPointer=!1),typeof i[""+t]>"u"?i[""+t]=e.test(n.userAgent):i[""+t]},Object.defineProperty(n,"userAgent",{get:function(){return n.uA},set:function(t){n.uA=t,window.browserDetails={}},enumerable:!0,configurable:!0}),Object.defineProperty(n,"info",{get:function(){return st(window.browserDetails.info)?window.browserDetails.info=n.extractBrowserDetail():window.browserDetails.info},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isIE",{get:function(){return n.getValue("isIE",A$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isTouch",{get:function(){return st(window.browserDetails.isTouch)?window.browserDetails.isTouch="ontouchstart"in window.navigator||window&&window.navigator&&window.navigator.maxTouchPoints>0||"ontouchstart"in window:window.browserDetails.isTouch},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isPointer",{get:function(){return st(window.browserDetails.isPointer)?window.browserDetails.isPointer="pointerEnabled"in window.navigator:window.browserDetails.isPointer},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isMSPointer",{get:function(){return st(window.browserDetails.isMSPointer)?window.browserDetails.isMSPointer="msPointerEnabled"in window.navigator:window.browserDetails.isMSPointer},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isDevice",{get:function(){return n.getValue("isDevice",T$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isIos",{get:function(){return n.getValue("isIos",N$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isIos7",{get:function(){return n.getValue("isIos7",O$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isAndroid",{get:function(){return n.getValue("isAndroid",k$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isWebView",{get:function(){return st(window.browserDetails.isWebView)&&(window.browserDetails.isWebView=!(st(window.cordova)&&st(window.PhoneGap)&&st(window.phonegap)&&"object"!==window.forge)),window.browserDetails.isWebView},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isWindows",{get:function(){return n.getValue("isWindows",P$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"touchStartEvent",{get:function(){return st(window.browserDetails.touchStartEvent)?window.browserDetails.touchStartEvent=n.getTouchStartEvent():window.browserDetails.touchStartEvent},enumerable:!0,configurable:!0}),Object.defineProperty(n,"touchMoveEvent",{get:function(){return st(window.browserDetails.touchMoveEvent)?window.browserDetails.touchMoveEvent=n.getTouchMoveEvent():window.browserDetails.touchMoveEvent},enumerable:!0,configurable:!0}),Object.defineProperty(n,"touchEndEvent",{get:function(){return st(window.browserDetails.touchEndEvent)?window.browserDetails.touchEndEvent=n.getTouchEndEvent():window.browserDetails.touchEndEvent},enumerable:!0,configurable:!0}),Object.defineProperty(n,"touchCancelEvent",{get:function(){return st(window.browserDetails.touchCancelEvent)?window.browserDetails.touchCancelEvent=n.getTouchCancelEvent():window.browserDetails.touchCancelEvent},enumerable:!0,configurable:!0}),n.uA=typeof navigator<"u"?navigator.userAgent:"",n}(),E=function(){function n(){}return n.addOrGetEventData=function(t){return"__eventList"in t?t.__eventList.events:(t.__eventList={},t.__eventList.events=[])},n.add=function(t,e,i,r,s){var a,o=n.addOrGetEventData(t);a=s?function l$(n,t){var e;return function(){for(var i=this,r=[],s=0;s"u"||(e.innerHTML=t.innerHTML?t.innerHTML:"",void 0!==t.className&&(e.className=t.className),void 0!==t.id&&(e.id=t.id),void 0!==t.styles&&e.setAttribute("style",t.styles),void 0!==t.attrs&&Fe(e,t.attrs)),e}function V(n,t){for(var e=Vz(t),i=RegExp,r=0,s=n;r0}function gl(n,t,e){for(var i=document.createDocumentFragment(),r=0,s=n;r0;)i.appendChild(n[0]);else for(var r=0,s=n;r-1&&!r[parseInt(s.toString(),10)].match(/\[.*\]/)){var o=r[parseInt(s.toString(),10)].split("#");if(o[1].match(/^\d/)||o[1].match(t)){var a=r[parseInt(s.toString(),10)].split(".");a[0]=a[0].replace(/#/,"[id='")+"']",r[parseInt(s.toString(),10)]=a.join(".")}}e[parseInt(i.toString(),10)]=r.join(" ")}return e.join(",")}return n}function J(n,t){var e=n;if("function"==typeof e.closest)return e.closest(t);for(;e&&1===e.nodeType;){if(yC(e,t))return e;e=e.parentNode}return null}function je(n,t){void 0!==t&&Object.keys(t).forEach(function(e){n.style[""+e]=t[""+e]})}function yC(n,t){var e=n.matches||n.msMatchesSelector||n.webkitMatchesSelector;return e?e.call(n,t):-1!==[].indexOf.call(document.querySelectorAll(t),n)}var H$=new RegExp("]"),dh=function(){function n(t,e){this.isRendered=!1,this.isComplexArraySetter=!1,this.isServerRendered=!1,this.allowServerDataBinding=!0,this.isProtectedOnChange=!0,this.properties={},this.changedProperties={},this.oldProperties={},this.bulkChanges={},this.refreshing=!1,this.ignoreCollectionWatch=!1,this.finalUpdate=function(){},this.childChangedProperties={},this.modelObserver=new Ng(this),st(e)||(this.element="string"==typeof e?document.querySelector(e):e,m(this.element)||(this.isProtectedOnChange=!1,this.addInstance())),st(t)||this.setProperties(t,!0),this.isDestroyed=!1}return n.prototype.setProperties=function(t,e){var i=this.isProtectedOnChange;this.isProtectedOnChange=!!e,kn(this,t),!0!==e?(kn(this.changedProperties,t),this.dataBind()):ce()&&this.isRendered&&this.serverDataBind(t),this.finalUpdate(),this.changedProperties={},this.oldProperties={},this.isProtectedOnChange=i},n.callChildDataBind=function(t,e){for(var r=0,s=Object.keys(t);r=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Hs=function(n){function t(i){var r=n.call(this,i,void 0)||this;return r.easing={ease:"cubic-bezier(0.250, 0.100, 0.250, 1.000)",linear:"cubic-bezier(0.250, 0.250, 0.750, 0.750)",easeIn:"cubic-bezier(0.420, 0.000, 1.000, 1.000)",easeOut:"cubic-bezier(0.000, 0.000, 0.580, 1.000)",easeInOut:"cubic-bezier(0.420, 0.000, 0.580, 1.000)",elasticInOut:"cubic-bezier(0.5,-0.58,0.38,1.81)",elasticIn:"cubic-bezier(0.17,0.67,0.59,1.81)",elasticOut:"cubic-bezier(0.7,-0.75,0.99,1.01)"},r}var e;return X$(t,n),e=t,t.prototype.animate=function(i,r){var s=this.getModel(r=r||{});if("string"==typeof i)for(var a=0,l=Array.prototype.slice.call(we(i,document));a0?r-1:0,i+=e=-1!==e?"-"+e:"-"+r}return this.controlParent!==this.parentObj&&(i=this.parentObj.getParentKey()+"."+this.propName+e),i},n}(),J$=["grid","pivotview","treegrid","spreadsheet","rangeNavigator","DocumentEditor","listbox","inplaceeditor","PdfViewer","richtexteditor","DashboardLayout","chart","stockChart","circulargauge","diagram","heatmap","lineargauge","maps","slider","smithchart","barcode","sparkline","treemap","bulletChart","kanban","daterangepicker","schedule","gantt","signature","query-builder","drop-down-tree","carousel","filemanager","uploader","accordion","tab","treeview"],tR=[115,121,110,99,102,117,115,105,111,110,46,105,115,76,105,99,86,97,108,105,100,97,116,101,100],iR=function(){function n(t){this.isValidated=!1,this.isLicensed=!0,this.version="27",this.platform=/JavaScript|ASPNET|ASPNETCORE|ASPNETMVC|FileFormats|essentialstudio/i,this.errors={noLicense:"This application was built using a trial version of Syncfusion Essential Studio. To remove the license validation message permanently, a valid license key must be included.",trailExpired:"This application was built using a trial version of Syncfusion Essential Studio. To remove the license validation message permanently, a valid license key must be included.",versionMismatched:"The included Syncfusion license key is invalid.",platformMismatched:"The included Syncfusion license key is invalid.",invalidKey:"The included Syncfusion license key is invalid."},this.manager=function(){var e=null;return{setKey:function i(s){e=s},getKey:function r(){return e}}}(),this.npxManager=function(){return{getKey:function i(){return"npxKeyReplace"}}}(),this.manager.setKey(t)}return n.prototype.validate=function(){if(!this.isValidated&&nf&&!Y(L0(tR),nf)&&!Y("Blazor",nf)){var i=void 0,r=void 0;if(this.manager&&this.manager.getKey()||this.npxManager&&"npxKeyReplace"!==this.npxManager.getKey()){var s=this.getInfoFromKey();if(s&&s.length)for(var o=0,a=s;o"+i+' Claim your FREE account\n
have a Syncfusion account? Sign In
\n
\n ';if(typeof document<"u"&&!m(document)){var t=Si("div",{innerHTML:n});document.body.appendChild(t)}}(),oR=!0),this.render(),this.mount?this.accessMount():this.trigger("created")}},t.prototype.renderComplete=function(e){ce()&&window.sfBlazor.renderComplete(this.element,e),this.isRendered=!0},t.prototype.dataBind=function(){this.injectModules(),n.prototype.dataBind.call(this)},t.prototype.on=function(e,i,r){if("string"==typeof e)this.localObserver.on(e,i,r);else for(var s=0,o=e;s=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},rZ={left:0,top:0,bottom:0,right:0},wC={isDragged:!1},nZ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return aR(t,n),gr([I(0)],t.prototype,"left",void 0),gr([I(0)],t.prototype,"top",void 0),t}(Ee),hf=function(n){function t(i,r){var s=n.call(this,r,i)||this;return s.dragLimit=e.getDefaultPosition(),s.borderWidth=e.getDefaultPosition(),s.padding=e.getDefaultPosition(),s.diffX=0,s.prevLeft=0,s.prevTop=0,s.dragProcessStarted=!1,s.eleTop=0,s.tapHoldTimer=0,s.externalInitialize=!1,s.diffY=0,s.parentScrollX=0,s.parentScrollY=0,s.droppables={},s.bind(),s}var e;return aR(t,n),e=t,t.prototype.bind=function(){this.toggleEvents(),X.isIE&&V([this.element],"e-block-touch"),this.droppables[this.scope]={}},t.getDefaultPosition=function(){return ze({},rZ)},t.prototype.toggleEvents=function(i){var r;st(this.handle)||(r=_(this.handle,this.element));var s=this.enableTapHold&&X.isDevice&&X.isTouch?this.mobileInitialize:this.initialize;i?E.remove(r||this.element,X.isSafari()?"touchstart":X.touchStartEvent,s):E.add(r||this.element,X.isSafari()?"touchstart":X.touchStartEvent,s,this)},t.prototype.mobileInitialize=function(i){var r=this,s=i.currentTarget;this.tapHoldTimer=setTimeout(function(){r.externalInitialize=!0,r.removeTapholdTimer(),r.initialize(i,s)},this.tapHoldThreshold),E.add(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.removeTapholdTimer,this),E.add(document,X.isSafari()?"touchend":X.touchEndEvent,this.removeTapholdTimer,this)},t.prototype.removeTapholdTimer=function(){clearTimeout(this.tapHoldTimer),E.remove(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.removeTapholdTimer),E.remove(document,X.isSafari()?"touchend":X.touchEndEvent,this.removeTapholdTimer)},t.prototype.getScrollableParent=function(i,r){return m(i)?null:i[{vertical:"scrollHeight",horizontal:"scrollWidth"}[""+r]]>i[{vertical:"clientHeight",horizontal:"clientWidth"}[""+r]]&&("vertical"===r?i.scrollTop>0:i.scrollLeft>0)?("vertical"===r?(this.parentScrollY=this.parentScrollY+(0===this.parentScrollY?i.scrollTop:i.scrollTop-this.parentScrollY),this.tempScrollHeight=i.scrollHeight):(this.parentScrollX=this.parentScrollX+(0===this.parentScrollX?i.scrollLeft:i.scrollLeft-this.parentScrollX),this.tempScrollWidth=i.scrollWidth),m(i)?i:this.getScrollableParent(i.parentNode,r)):this.getScrollableParent(i.parentNode,r)},t.prototype.getScrollableValues=function(){this.parentScrollX=0,this.parentScrollY=0,this.element.classList.contains("e-dialog")&&this.element.classList.contains("e-dlg-modal"),this.getScrollableParent(this.element.parentNode,"vertical"),this.getScrollableParent(this.element.parentNode,"horizontal")},t.prototype.initialize=function(i,r){if(this.currentStateTarget=i.target,!this.isDragStarted()){if(this.isDragStarted(!0),this.externalInitialize=!1,this.target=i.currentTarget||r,this.dragProcessStarted=!1,this.abort){var s=this.abort;"string"==typeof s&&(s=[s]);for(var o=0;o=this.distance||this.externalInitialize){var f=this.getHelperElement(i);if(!f||m(f))return;r&&i.preventDefault();var p=this.helperElement=f;if(this.parentClientRect=this.calculateParentPosition(p.offsetParent),this.dragStart){var v={event:i,element:l,target:this.getProperTargetElement(i),bindEvents:ce()?this.bindDragEvents.bind(this):null,dragElement:p};this.trigger("dragStart",v)}this.dragArea?this.setDragArea():(this.dragLimit={left:0,right:0,bottom:0,top:0},this.borderWidth={top:0,left:0}),o={left:this.position.left-this.parentClientRect.left,top:this.position.top-this.parentClientRect.top},this.clone&&!this.enableTailMode&&(this.diffX=this.position.left-this.offset.left,this.diffY=this.position.top-this.offset.top),this.getScrollableValues();var y=getComputedStyle(l),S=parseFloat(y.marginTop);this.clone&&0!==S&&(o.top+=S),this.eleTop=isNaN(parseFloat(y.top))?0:parseFloat(y.top)-this.offset.top,this.enableScrollHandler&&!this.clone&&(o.top-=this.parentScrollY,o.left-=this.parentScrollX);var b=this.getProcessedPositionValue({top:o.top-this.diffY+"px",left:o.left-this.diffX+"px"});this.dragArea&&"string"!=typeof this.dragArea&&this.dragArea.classList.contains("e-kanban-content")&&"relative"===this.dragArea.style.position&&(o.top+=this.dragArea.scrollTop),this.dragElePosition={top:o.top,left:o.left},je(p,this.getDragPosition({position:"absolute",left:b.left,top:b.top})),E.remove(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.intDragStart),E.remove(document,X.isSafari()?"touchend":X.touchEndEvent,this.intDestroy),ce()||this.bindDragEvents(p)}}},t.prototype.bindDragEvents=function(i){Tr(i)?(E.add(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.intDrag,this),E.add(document,X.isSafari()?"touchend":X.touchEndEvent,this.intDragStop,this),this.setGlobalDroppables(!1,this.element,i)):(this.toggleEvents(),document.body.classList.remove("e-prevent-select"))},t.prototype.elementInViewport=function(i){for(this.top=i.offsetTop,this.left=i.offsetLeft,this.width=i.offsetWidth,this.height=i.offsetHeight;i.offsetParent;)this.top+=(i=i.offsetParent).offsetTop,this.left+=i.offsetLeft;return this.top>=window.pageYOffset&&this.left>=window.pageXOffset&&this.top+this.height<=window.pageYOffset+window.innerHeight&&this.left+this.width<=window.pageXOffset+window.innerWidth},t.prototype.getProcessedPositionValue=function(i){return this.queryPositionInfo?this.queryPositionInfo(i):i},t.prototype.calculateParentPosition=function(i){if(m(i))return{left:0,top:0};var r=i.getBoundingClientRect(),s=getComputedStyle(i);return{left:r.left+window.pageXOffset-parseInt(s.marginLeft,10),top:r.top+window.pageYOffset-parseInt(s.marginTop,10)}},t.prototype.intDrag=function(i){if(st(i.changedTouches)||1===i.changedTouches.length){var r,s;this.clone&&i.changedTouches&&X.isDevice&&X.isTouch&&i.preventDefault(),this.position=this.getMousePosition(i,this.isDragScroll);var o=this.getDocumentWidthHeight("Height");oy&&y>0?this.dragLimit.left:this.dragLimit.right+window.pageXOffset0?y-(y-this.dragLimit.right)+window.pageXOffset-M:y<0?this.dragLimit.left:y}if(this.pageY!==v||this.skipDistanceCheck){var w=d.offsetHeight+(parseFloat(b.marginTop)+parseFloat(b.marginBottom));s=this.dragLimit.top>S&&S>0?this.dragLimit.top:this.dragLimit.bottom+window.pageYOffset0?S-(S-this.dragLimit.bottom)+window.pageYOffset-w:S<0?this.dragLimit.top:S}}else r=y,s=S;var A,x,C=f+this.borderWidth.top,D=u+this.borderWidth.left;if(this.dragProcessStarted&&(m(s)&&(s=this.prevTop),m(r)&&(r=this.prevLeft)),this.helperElement.classList.contains("e-treeview"))this.dragArea?(this.dragLimit.top=this.clone?this.dragLimit.top:0,A=s-C<0?this.dragLimit.top:s-this.borderWidth.top,x=r-D<0?this.dragLimit.left:r-this.borderWidth.left):(A=s-this.borderWidth.top,x=r-this.borderWidth.left);else if(this.dragArea){var P=this.helperElement.classList.contains("e-dialog");this.dragLimit.top=this.clone?this.dragLimit.top:0,A=s-C<0?this.dragLimit.top:s-C,x=r-D<0?P?r-(D-this.borderWidth.left):this.dragElePosition.left:r-D}else A=s-C,x=r-D;var L=parseFloat(getComputedStyle(this.element).marginTop);if(L>0&&(this.clone&&(A+=L,S<0&&(L+S>=0?A=L+S:A-=L),this.dragArea&&(A=this.dragLimit.bottom=0){var O=this.dragLimit.top+S-C;O+L+C<0?A-=L+C:A=O}else A-=L+C;this.dragArea&&this.helperElement.classList.contains("e-treeview")&&(A=A+(w=d.offsetHeight+(parseFloat(b.marginTop)+parseFloat(b.marginBottom)))>this.dragLimit.bottom?this.dragLimit.bottom-w:A),this.enableScrollHandler&&!this.clone&&(A-=this.parentScrollY,x-=this.parentScrollX),this.dragArea&&"string"!=typeof this.dragArea&&this.dragArea.classList.contains("e-kanban-content")&&"relative"===this.dragArea.style.position&&(A+=this.dragArea.scrollTop);var N=this.getProcessedPositionValue({top:A+"px",left:x+"px"});this.isPreventScroll&&(N=this.getProcessedPositionValue({top:this.position.top-this.parentClientRect.top-2+"px",left:this.position.left-this.parentClientRect.left-2+"px"})),je(d,this.getDragPosition(N)),!this.elementInViewport(d)&&this.enableAutoScroll&&!this.helperElement.classList.contains("e-treeview")&&this.helperElement.scrollIntoView();var T=document.querySelectorAll(":hover");if(this.enableAutoScroll&&this.helperElement.classList.contains("e-treeview")){0===T.length&&(T=this.getPathElements(i));var z=this.getScrollParent(T,!1);this.elementInViewport(this.helperElement)?this.getScrollPosition(z,A):this.elementInViewport(this.helperElement)||(0===(T=[].slice.call(document.querySelectorAll(":hover"))).length&&(T=this.getPathElements(i)),z=this.getScrollParent(T,!0),this.getScrollPosition(z,A))}this.dragProcessStarted=!0,this.prevLeft=r,this.prevTop=s,this.position.left=r,this.position.top=s,this.pageX=g,this.pageY=v}},t.prototype.getScrollParent=function(i,r){for(var o,s=r?i.reverse():i,a=s.length-1;a>=0;a--)if(("auto"===(o=window.getComputedStyle(s[parseInt(a.toString(),10)])["overflow-y"])||"scroll"===o)&&s[parseInt(a.toString(),10)].scrollHeight>s[parseInt(a.toString(),10)].clientHeight)return s[parseInt(a.toString(),10)];if("visible"===(o=window.getComputedStyle(document.scrollingElement)["overflow-y"]))return document.scrollingElement.style.overflow="auto",document.scrollingElement},t.prototype.getScrollPosition=function(i,r){if(i&&i===document.scrollingElement)i.clientHeight+document.scrollingElement.scrollTop-this.helperElement.clientHeightr?i.scrollTop+=this.helperElement.clientHeight:i.scrollTop>r-this.helperElement.clientHeight&&(i.scrollTop-=this.helperElement.clientHeight);else if(i&&i!==document.scrollingElement){var s=document.scrollingElement.scrollTop,o=this.helperElement.clientHeight;i.clientHeight+i.getBoundingClientRect().top-o+sr-o-s&&(i.scrollTop-=this.helperElement.clientHeight)}},t.prototype.getPathElements=function(i){return document.elementsFromPoint(i.clientX>0?i.clientX:0,i.clientY>0?i.clientY:0)},t.prototype.triggerOutFunction=function(i,r){this.hoverObject.instance.intOut(i,r.target),this.hoverObject.instance.dragData[this.scope]=null,this.hoverObject=null},t.prototype.getDragPosition=function(i){var r=ze({},i);return this.axis&&("x"===this.axis?delete r.top:"y"===this.axis&&delete r.left),r},t.prototype.getDocumentWidthHeight=function(i){var r=document.body,s=document.documentElement;return Math.max(r["scroll"+i],s["scroll"+i],r["offset"+i],s["offset"+i],s["client"+i])},t.prototype.intDragStop=function(i){if(this.dragProcessStarted=!1,st(i.changedTouches)||1===i.changedTouches.length){if(-1!==["touchend","pointerup","mouseup"].indexOf(i.type)){if(this.dragStop){var s=this.getProperTargetElement(i);this.trigger("dragStop",{event:i,element:this.element,target:s,helper:this.helperElement})}this.intDestroy(i)}else this.element.setAttribute("aria-grabbed","false");var o=this.checkTargetElement(i);o.target&&o.instance&&(o.instance.dragStopCalled=!0,o.instance.dragData[this.scope]=this.droppables[this.scope],o.instance.intDrop(i,o.target)),this.setGlobalDroppables(!0),document.body.classList.remove("e-prevent-select")}},t.prototype.intDestroy=function(i){this.dragProcessStarted=!1,this.toggleEvents(),document.body.classList.remove("e-prevent-select"),this.element.setAttribute("aria-grabbed","false"),E.remove(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.intDragStart),E.remove(document,X.isSafari()?"touchend":X.touchEndEvent,this.intDragStop),E.remove(document,X.isSafari()?"touchend":X.touchEndEvent,this.intDestroy),E.remove(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.intDrag),this.isDragStarted()&&this.isDragStarted(!0)},t.prototype.onPropertyChanged=function(i,r){},t.prototype.getModuleName=function(){return"draggable"},t.prototype.isDragStarted=function(i){return i&&(wC.isDragged=!wC.isDragged),wC.isDragged},t.prototype.setDragArea=function(){var i,r,a,s=0,o=0;if(a="string"==typeof this.dragArea?_(this.dragArea):this.dragArea){var h=a.getBoundingClientRect();i=a.scrollWidth?a.scrollWidth:h.right-h.left,r=a.scrollHeight?this.dragArea&&!m(this.helperElement)&&this.helperElement.classList.contains("e-treeview")?a.clientHeight:a.scrollHeight:h.bottom-h.top;for(var c=["Top","Left","Bottom","Right"],d=getComputedStyle(a),u=0;u12;return D0(i.target,this.helperElement)||-1!==i.type.indexOf("touch")||a?(this.helperElement.style.pointerEvents="none",s=document.elementFromPoint(r.clientX,r.clientY),this.helperElement.style.pointerEvents=o):s=i.target,s},t.prototype.currentStateCheck=function(i,r){return m(this.currentStateTarget)||this.currentStateTarget===i?m(r)?i:r:this.currentStateTarget},t.prototype.getMousePosition=function(i,r){var a,l,s=void 0!==i.srcElement?i.srcElement:i.target,o=this.getCoordinates(i),h=m(s.offsetParent);if(r?(a=this.clone?o.pageX:o.pageX+(h?0:s.offsetParent.scrollLeft)-this.relativeXPosition,l=this.clone?o.pageY:o.pageY+(h?0:s.offsetParent.scrollTop)-this.relativeYPosition):(a=this.clone?o.pageX:o.pageX+window.pageXOffset-this.relativeXPosition,l=this.clone?o.pageY:o.pageY+window.pageYOffset-this.relativeYPosition),document.scrollingElement&&!r&&!this.clone){var c=document.scrollingElement;a=c.scrollWidth>0&&c.scrollWidth>c.clientWidth&&c.scrollLeft>0?a-c.scrollLeft:a,l=c.scrollHeight>0&&c.scrollHeight>c.clientHeight&&c.scrollTop>0?l-c.scrollTop:l}return{left:a-(this.margin.left+this.cursorAt.left),top:l-(this.margin.top+this.cursorAt.top)}},t.prototype.getCoordinates=function(i){return i.type.indexOf("touch")>-1?i.changedTouches[0]:i},t.prototype.getHelperElement=function(i){var r;return this.clone?this.helper?r=this.helper({sender:i,element:this.target}):(r=Si("div",{className:"e-drag-helper e-block-touch",innerHTML:"Draggable"}),document.body.appendChild(r)):r=this.element,r},t.prototype.setGlobalDroppables=function(i,r,s){this.droppables[this.scope]=i?null:{draggable:r,helper:s,draggedElement:this.element}},t.prototype.checkTargetElement=function(i){var r=this.getProperTargetElement(i),s=this.getDropInstance(r);if(!s&&r&&!m(r.parentNode)){var o=J(r.parentNode,".e-droppable")||r.parentElement;o&&(s=this.getDropInstance(o))}return{target:r,instance:s}},t.prototype.getDropInstance=function(i){var s,o=i&&i.ej2_instances;if(o)for(var a=0,l=o;a=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},lR=function(n){function t(e,i){var r=n.call(this,i,e)||this;return r.mouseOver=!1,r.dragData={},r.dragStopCalled=!1,r.bind(),r}return sZ(t,n),t.prototype.bind=function(){this.wireEvents()},t.prototype.wireEvents=function(){E.add(this.element,X.isSafari()?"touchend":X.touchEndEvent,this.intDrop,this)},t.prototype.onPropertyChanged=function(e,i){},t.prototype.getModuleName=function(){return"droppable"},t.prototype.intOver=function(e,i){this.mouseOver||(this.trigger("over",{event:e,target:i,dragData:this.dragData[this.scope]}),this.mouseOver=!0)},t.prototype.intOut=function(e,i){this.mouseOver&&(this.trigger("out",{evt:e,target:i}),this.mouseOver=!1)},t.prototype.intDrop=function(e,i){if(this.dragStopCalled){this.dragStopCalled=!1;var a,r=!0,s=this.dragData[this.scope],o=!!s&&s.helper&&Tr(s.helper);o&&(a=this.isDropArea(e,s.helper,i),this.accept&&(r=yC(s.helper,this.accept))),o&&this.drop&&a.canDrop&&r&&this.trigger("drop",{event:e,target:a.target,droppedElement:s.helper,dragData:s}),this.mouseOver=!1}},t.prototype.isDropArea=function(e,i,r){var s={canDrop:!0,target:r||e.target},o="touchend"===e.type;if(o||s.target===i){i.style.display="none";var a=o?e.changedTouches[0]:e,l=document.elementFromPoint(a.clientX,a.clientY);s.canDrop=!1,s.canDrop=D0(l,this.element),s.canDrop&&(s.target=l),i.style.display=""}return s},t.prototype.destroy=function(){E.remove(this.element,X.isSafari()?"touchend":X.touchEndEvent,this.intDrop),n.prototype.destroy.call(this)},cf([I()],t.prototype,"accept",void 0),cf([I("default")],t.prototype,"scope",void 0),cf([H()],t.prototype,"drop",void 0),cf([H()],t.prototype,"over",void 0),cf([H()],t.prototype,"out",void 0),cf([Ft],t)}(dh),uo=function(){function n(t,e,i){this.controlName=t,this.localeStrings=e,this.setLocale(i||"en-US")}return n.prototype.setLocale=function(t){var e=this.intGetControlConstant(n.locale,t);this.currentLocale=e||this.localeStrings},n.load=function(t){this.locale=ze(this.locale,t,{},!0)},n.prototype.getConstant=function(t){return m(this.currentLocale[""+t])?this.localeStrings[""+t]||"":this.currentLocale[""+t]},n.prototype.intGetControlConstant=function(t,e){return t[""+e]?t[""+e][this.controlName]:null},n.locale={},n}(),hR=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),fh=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},lZ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return hR(t,n),fh([I(50)],t.prototype,"swipeThresholdDistance",void 0),t}(Ee),hZ=/(Up|Down)/,Fs=function(n){function t(e,i){var r=n.call(this,i,e)||this;return r.touchAction=!0,r.tapCount=0,r.startEvent=function(s){if(!0===r.touchAction){var o=r.updateChangeTouches(s);void 0!==s.changedTouches&&(r.touchAction=!1),r.isTouchMoved=!1,r.movedDirection="",r.startPoint=r.lastMovedPoint={clientX:o.clientX,clientY:o.clientY},r.startEventData=o,r.hScrollLocked=r.vScrollLocked=!1,r.tStampStart=Date.now(),r.timeOutTapHold=setTimeout(function(){r.tapHoldEvent(s)},r.tapHoldThreshold),E.add(r.element,X.touchMoveEvent,r.moveEvent,r),E.add(r.element,X.touchEndEvent,r.endEvent,r),E.add(r.element,X.touchCancelEvent,r.cancelEvent,r)}},r.moveEvent=function(s){var o=r.updateChangeTouches(s);r.movedPoint=o,r.isTouchMoved=!(o.clientX===r.startPoint.clientX&&o.clientY===r.startPoint.clientY);var a={};r.isTouchMoved&&(clearTimeout(r.timeOutTapHold),r.calcScrollPoints(s),a=ze(a,{},{startEvents:r.startEventData,originalEvent:s,startX:r.startPoint.clientX,startY:r.startPoint.clientY,distanceX:r.distanceX,distanceY:r.distanceY,scrollDirection:r.scrollDirection,velocity:r.getVelocity(o)}),r.trigger("scroll",a),r.lastMovedPoint={clientX:o.clientX,clientY:o.clientY})},r.cancelEvent=function(s){clearTimeout(r.timeOutTapHold),clearTimeout(r.timeOutTap),r.tapCount=0,r.swipeFn(s),E.remove(r.element,X.touchCancelEvent,r.cancelEvent)},r.endEvent=function(s){r.swipeFn(s),r.isTouchMoved||"function"==typeof r.tap&&(r.trigger("tap",{originalEvent:s,tapCount:++r.tapCount}),r.timeOutTap=setTimeout(function(){r.tapCount=0},r.tapThreshold)),r.modeclear()},r.swipeFn=function(s){clearTimeout(r.timeOutTapHold),clearTimeout(r.timeOutTap);var o=r.updateChangeTouches(s),a=o.clientX-r.startPoint.clientX,l=o.clientY-r.startPoint.clientY;a=Math.floor(a<0?-1*a:a),l=Math.floor(l<0?-1*l:a),r.isTouchMoved=a>1||l>1,/Firefox/.test(X.userAgent)&&0===o.clientX&&0===o.clientY&&"mouseup"===s.type&&(r.isTouchMoved=!1),r.endPoint=o,r.calcPoints(s);var c={originalEvent:s,startEvents:r.startEventData,startX:r.startPoint.clientX,startY:r.startPoint.clientY,distanceX:r.distanceX,distanceY:r.distanceY,swipeDirection:r.movedDirection,velocity:r.getVelocity(o)};if(r.isTouchMoved){var d=r.swipeSettings.swipeThresholdDistance,u=ze(void 0,r.defaultArgs,c),f=!1,p=r.element,g=r.isScrollable(p),v=hZ.test(r.movedDirection);(dthis.distanceY?i.clientX>this.startPoint.clientX?"Right":"Left":i.clientYthis.distanceY||!0===this.hScrollLocked)&&!1===this.vScrollLocked?(this.scrollDirection=i.clientX>this.lastMovedPoint.clientX?"Right":"Left",this.hScrollLocked=!0):(this.scrollDirection=i.clientY=e[r[0]+s[0]]},t.prototype.updateChangeTouches=function(e){return e.changedTouches&&0!==e.changedTouches.length?e.changedTouches[0]:e},fh([H()],t.prototype,"tap",void 0),fh([H()],t.prototype,"tapHold",void 0),fh([H()],t.prototype,"swipe",void 0),fh([H()],t.prototype,"scroll",void 0),fh([I(350)],t.prototype,"tapThreshold",void 0),fh([I(750)],t.prototype,"tapHoldThreshold",void 0),fh([re({},lZ)],t.prototype,"swipeSettings",void 0),fh([Ft],t)}(dh),cZ=new RegExp("\\n|\\r|\\s\\s+","g"),dZ=new RegExp(/'|"/g),uZ=new RegExp("if ?\\("),fZ=new RegExp("else if ?\\("),cR=new RegExp("else"),pZ=new RegExp("for ?\\("),dR=new RegExp("(/if|/for)"),gZ=new RegExp("\\((.*)\\)",""),CC=new RegExp("^[0-9]+$","g"),vZ=new RegExp("[\\w\"'.\\s+]+","g"),mZ=new RegExp('"(.*?)"',"g"),yZ=new RegExp("[\\w\"'@#$.\\s-+]+","g"),uR=new RegExp("\\${([^}]*)}","g"),SZ=/^\..*/gm,EC=/\\/gi,IZ=/\\\\/gi,bZ=new RegExp("[\\w\"'@#$.\\s+]+","g"),MZ=/\window\./gm;function df(n,t,e,i,r){return!t||CC.test(n)||-1!==i.indexOf(n.split(".")[0])||r||"true"===n||"false"===n?n:e+"."+n}function DC(n,t,e,i){return t&&!CC.test(n)&&-1===i.indexOf(n.split(".")[0])?e+'["'+n:n}function fR(n){return n.match(IZ)?n:n.replace(EC,"\\\\")}function pR(n,t,e,i){if(n=n.trim(),/\window\./gm.test(n))return n;var s=/'|"/gm;return/@|\$|#/gm.test(n)&&(n=DC(n,-1===e.indexOf(n),t,e)+'"]'),SZ.test(n)?function EZ(n,t,e,i){return!t||CC.test(n)||-1!==i.indexOf(n.split(".")[0])||/^\..*/gm.test(n)?n:e+"."+n}(n,!s.test(n)&&-1===e.indexOf(n),t,e):df(n,!s.test(n)&&-1===e.indexOf(n),t,e,i)}var DZ=/^[\n\r.]+0&&t.forEach(function(e){he(e)})},n.removeJsEvents=function(){var t=this.wrapElement.querySelectorAll("["+vR.join("],[")+"]");t.length>0&&t.forEach(function(e){vR.forEach(function(i){e.hasAttribute(i)&&e.removeAttribute(i)})})},n.removeXssAttrs=function(){var t=this;this.removeAttrs.forEach(function(e,i){var r=t.wrapElement.querySelectorAll(e.selector);r.length>0&&r.forEach("a[href]"===e.selector?function(s){-1!==s.getAttribute(e.attribute).replace(/\t|\s|&/,"").indexOf("javascript:alert")&&s.removeAttribute(e.attribute)}:function(s){s.removeAttribute(e.attribute)})})},n}();function PZ(n){return function(t){!function kZ(n,t){t.forEach(function(e){Object.getOwnPropertyNames(e.prototype).forEach(function(i){(!Object.prototype.hasOwnProperty.call(n.prototype,i)||e.isFormBase&&"constructor"!==i)&&(n.prototype["".concat(i)]=e.prototype["".concat(i)])})})}(t,n)}}function mR(n,t,e){var i={};if(n&&n.length){for(var r=0,s=n;r"u"||(y.innerHTML=v.innerHTML?v.innerHTML:"",void 0!==v.className&&(y.className=v.className),void 0!==v.id&&(y.id=v.id),void 0!==v.styles&&y.setAttribute("style",v.styles),void 0!==e.ngAttr&&y.setAttribute(e.ngAttr,""),void 0!==v.attrs&&Fe(y,v.attrs)),y};for(var i=0,r=e.tags;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s}function jZ(n){for(var t,e=n.childNodes,i=0;i"u"&&(c["".concat(o)]=[]),c["".concat(o)].push(h),h.rootNodes}}});var Sl,hd,mh,Wg,lc,po,YZ=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Na=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Jo_RTL=(new Ng,"e-rtl"),ys=function(n){function t(e,i){return n.call(this,e,i)||this}return YZ(t,n),t.prototype.preRender=function(){},t.prototype.render=function(){this.initialize(),this.removeRippleEffect=function ms(n,t,e){var i=function q$(n){return{selector:n&&n.selector?n.selector:null,ignore:n&&n.ignore?n.ignore:null,rippleFlag:n&&n.rippleFlag,isCenterRipple:n&&n.isCenterRipple,duration:n&&n.duration?n.duration:350}}(t);return!1===i.rippleFlag||void 0===i.rippleFlag&&!Zo?function(){}:(n.setAttribute("data-ripple","true"),E.add(n,"mousedown",Zz,{parent:n,rippleOptions:i}),E.add(n,"mouseup",Jz,{parent:n,rippleOptions:i,done:e}),E.add(n,"mouseleave",lf,{parent:n,rippleOptions:i}),X.isPointer&&E.add(n,"transitionend",lf,{parent:n,rippleOptions:i}),function(){n.removeAttribute("data-ripple"),E.remove(n,"mousedown",Zz),E.remove(n,"mouseup",Jz),E.remove(n,"mouseleave",lf),E.remove(n,"transitionend",lf)})}(this.element,{selector:".e-btn"}),this.renderComplete()},t.prototype.initialize=function(){if(this.cssClass&&V([this.element],this.cssClass.replace(/\s+/g," ").trim().split(" ")),this.isPrimary&&this.element.classList.add("e-primary"),!ce()||ce()&&"progress-btn"!==this.getModuleName()){if(this.content){var e=this.enableHtmlSanitizer?Ai.sanitize(this.content):this.content;this.element.innerHTML=e}this.setIconCss()}this.enableRtl&&this.element.classList.add(Jo_RTL),this.disabled?this.controlStatus(this.disabled):this.wireEvents()},t.prototype.controlStatus=function(e){this.element.disabled=e},t.prototype.setIconCss=function(){if(this.iconCss){var e=this.createElement("span",{className:"e-btn-icon "+this.iconCss});this.element.textContent.trim()?(e.classList.add("e-icon-"+this.iconPosition.toLowerCase()),("Top"===this.iconPosition||"Bottom"===this.iconPosition)&&this.element.classList.add("e-"+this.iconPosition.toLowerCase()+"-icon-btn")):this.element.classList.add("e-icon-btn");var i=this.element.childNodes[0];!i||"Left"!==this.iconPosition&&"Top"!==this.iconPosition?this.element.appendChild(e):this.element.insertBefore(e,i)}},t.prototype.wireEvents=function(){this.isToggle&&E.add(this.element,"click",this.btnClickHandler,this)},t.prototype.unWireEvents=function(){this.isToggle&&E.remove(this.element,"click",this.btnClickHandler)},t.prototype.btnClickHandler=function(){this.element.classList.contains("e-active")?this.element.classList.remove("e-active"):this.element.classList.add("e-active")},t.prototype.destroy=function(){var e=["e-primary",Jo_RTL,"e-icon-btn","e-success","e-info","e-danger","e-warning","e-flat","e-outline","e-small","e-bigger","e-active","e-round","e-top-icon-btn","e-bottom-icon-btn"];this.cssClass&&(e=e.concat(this.cssClass.split(" "))),n.prototype.destroy.call(this),K([this.element],e),this.element.getAttribute("class")||this.element.removeAttribute("class"),this.disabled&&this.element.removeAttribute("disabled"),this.content&&(this.element.innerHTML=this.element.innerHTML.replace(this.content,""));var i=this.element.querySelector("span.e-btn-icon");i&&he(i),this.unWireEvents(),Zo&&this.removeRippleEffect()},t.prototype.getModuleName=function(){return"btn"},t.prototype.getPersistData=function(){return this.addOnPersist([])},t.Inject=function(){},t.prototype.onPropertyChanged=function(e,i){for(var r=this.element.querySelector("span.e-btn-icon"),s=0,o=Object.keys(e);s=hd.width?hd.width:0;return Sl.right+JR()-n}function fE(){return V0()+Sl.width/2}function pE(n,t,e,i){if(void 0===t&&(t=null),void 0===e&&(e={X:!1,Y:!1}),!e.Y&&!e.X)return{left:0,top:0};var r=n.getBoundingClientRect();if(po=t,lc=n.ownerDocument,i||(i=ns(n,"left","top")),e.X){var s=po?r4():l4(),o=SE(),a=IE(),l=o-i.left,h=i.left+r.width-a;r.width>s?i.left=l>0&&h<=0?a-r.width:h>0&&l<=0?o:l>h?a-r.width:o:l>0?i.left+=l:h>0&&(i.left-=h)}if(e.Y){var c=po?n4():a4(),d=yE(),u=bE(),f=d-i.top,p=i.top+r.height-u;r.height>c?i.top=f>0&&p<=0?u-r.height:p>0&&f<=0?d:f>p?u-r.height:d:f>0?i.top+=f:p>0&&(i.top-=p)}return i}function hc(n,t,e,i){void 0===t&&(t=null);var r=ns(n,"left","top");e&&(r.left=e),i&&(r.top=i);var s=[];po=t,lc=n.ownerDocument;var o=n.getBoundingClientRect(),l=r.left,h=r.left+o.width,d=mE(r.top,r.top+o.height),u=e4(l,h);return d.topSide&&s.push("top"),u.rightSide&&s.push("right"),u.leftSide&&s.push("left"),d.bottomSide&&s.push("bottom"),s}function bJ(n,t,e,i,r,s,o,a,l){if(void 0===o&&(o=null),void 0===a&&(a={X:!0,Y:!0}),t&&n&&r&&s&&(a.X||a.Y)){var d,h={TL:null,TR:null,BL:null,BR:null},c={TL:null,TR:null,BL:null,BR:null};if("none"===window.getComputedStyle(n).display){var u=n.style.visibility;n.style.visibility="hidden",n.style.display="block",d=n.getBoundingClientRect(),n.style.removeProperty("display"),n.style.visibility=u}else d=n.getBoundingClientRect();var f={posX:r,posY:s,offsetX:e,offsetY:i,position:{left:0,top:0}};po=o,lc=t.ownerDocument,function wJ(n,t,e,i,r){e.position=ns(n,e.posX,e.posY,i,r),t.TL=ns(n,"left","top",i,r),t.TR=ns(n,"right","top",i,r),t.BR=ns(n,"left","bottom",i,r),t.BL=ns(n,"right","bottom",i,r)}(t,h,f,l,d),vE(c,f,d),a.X&&t4(t,c,h,f,d,!0),a.Y&&h.TL.top>-1&&i4(t,c,h,f,d,!0),function MJ(n,t,e){var i=0,r=0;if(null!=n.offsetParent&&("absolute"===getComputedStyle(n.offsetParent).position||"relative"===getComputedStyle(n.offsetParent).position)){var s=ns(n.offsetParent,"left","top",!1,e);i=s.left,r=s.top}var o=1,a=1,l=KR(n);if(l){var h=getComputedStyle(l).transform;if("none"!==h){var c=new DOMMatrix(h);o=c.a,a=c.d}if("none"!==getComputedStyle(l).zoom){var u=gE(document.body);o*=u,a*=u}}n.style.top=t.position.top/a+t.offsetY-r/a+"px",n.style.left=t.position.left/o+t.offsetX-i/o+"px"}(n,f,d)}}function gE(n){var t=getComputedStyle(n).zoom;return parseFloat(t)||1}function KR(n){for(;n;){var t=window.getComputedStyle(n).transform,e=gE(document.body);if(t&&"none"!==t||e&&1!==e)return n;if(n===document.body)return null;n=n.offsetParent||n.parentElement}return null}function vE(n,t,e){n.TL={top:t.position.top+t.offsetY,left:t.position.left+t.offsetX},n.TR={top:n.TL.top,left:n.TL.left+e.width},n.BL={top:n.TL.top+e.height,left:n.TL.left},n.BR={top:n.TL.top+e.height,left:n.TL.left+e.width}}function e4(n,t){var e=!1,i=!1;return n-Y0()IE()&&(i=!0),{leftSide:e,rightSide:i}}function t4(n,t,e,i,r,s){var o=e4(t.TL.left,t.TR.left),a=mE(t.TL.top,t.BL.top);e.TL.left-Y0()<=SE()&&(o.leftSide=!1),e.TR.left>IE()&&(o.rightSide=!1),(o.leftSide&&!o.rightSide||!o.leftSide&&o.rightSide)&&(i.posX="right"===i.posX?"left":"right",i.offsetX=i.offsetX+r.width,i.offsetX=-1*i.offsetX,i.position=ns(n,i.posX,i.posY,!1),vE(t,i,r),s&&t4(n,t,e,i,r,!1),!o.leftSide&&o.rightSide&&a.bottomSide&&(i.offsetX=0))}function i4(n,t,e,i,r,s){var o=mE(t.TL.top,t.BL.top);e.TL.top-W0()<=yE()&&(o.topSide=!1),e.BL.top>=bE()&&n.getBoundingClientRect().bottombE()&&(i=!0),{topSide:e,bottomSide:i}}function r4(){return po.getBoundingClientRect().width}function n4(){return po.getBoundingClientRect().height}function s4(){return po.getBoundingClientRect().left}function o4(){return po.getBoundingClientRect().top}function yE(){return po?o4():0}function SE(){return po?s4():0}function IE(){return po?Y0()+s4()+r4():Y0()+l4()}function bE(){return po?W0()+o4()+n4():W0()+a4()}function W0(){return lc.documentElement.scrollTop||lc.body.scrollTop}function Y0(){return lc.documentElement.scrollLeft||lc.body.scrollLeft}function a4(){return window.innerHeight}function l4(){var n=window.innerWidth,t=document.documentElement.getBoundingClientRect();return n-(n-(m(document.documentElement)?0:t.width))}function h4(){po=null,lc=null}var c4=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),bn=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},d4=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return c4(t,n),bn([I("left")],t.prototype,"X",void 0),bn([I("top")],t.prototype,"Y",void 0),t}(Ee),qn_OPEN="e-popup-open",qn_CLOSE="e-popup-close",cc=function(n){function t(e,i){return n.call(this,i,e)||this}return c4(t,n),t.prototype.onPropertyChanged=function(e,i){for(var r=0,s=Object.keys(e);r0&&c.left>0&&c.right>0&&c.bottom>0}var s=i.getBoundingClientRect();return!(r.bottoms.bottom||r.right>s.right||r.leftr.top?this.element.style.top="0px":s.bottomr.left&&(this.element.style.left=parseInt(this.element.style.left,10)+(s.left-r.left)+"px"))}},t.prototype.checkCollision=function(){var e=this.collision.X,i=this.collision.Y;"none"===e&&"none"===i||("flip"===e&&"flip"===i?this.callFlip({X:!0,Y:!0}):"fit"===e&&"fit"===i?this.callFit({X:!0,Y:!0}):("flip"===e?this.callFlip({X:!0,Y:!1}):"flip"===i&&this.callFlip({Y:!0,X:!1}),"fit"===e?this.callFit({X:!0,Y:!1}):"fit"===i&&this.callFit({X:!1,Y:!0})))},t.prototype.show=function(e,i){var r=this;if(this.getRelateToElement().classList.contains("e-filemanager")&&(this.fmDialogContainer=this.element.getElementsByClassName("e-file-select-wrap")[0]),this.wireEvents(),!m(this.fmDialogContainer)&&X.isIos&&(this.fmDialogContainer.style.display="block"),1e3===this.zIndex||!m(i)){var o=m(i)?this.element:i;this.zIndex=dc(o),je(this.element,{zIndex:this.zIndex})}e=m(e)||"object"!=typeof e?this.showAnimation:e,("none"!==this.collision.X||"none"!==this.collision.Y)&&(K([this.element],qn_CLOSE),V([this.element],qn_OPEN),this.checkCollision(),K([this.element],qn_OPEN),V([this.element],qn_CLOSE)),m(e)?(K([this.element],qn_CLOSE),V([this.element],qn_OPEN),this.trigger("open")):(e.begin=function(){r.isDestroyed||(K([r.element],qn_CLOSE),V([r.element],qn_OPEN))},e.end=function(){r.isDestroyed||r.trigger("open")},new Hs(e).animate(this.element))},t.prototype.hide=function(e){var i=this;e=m(e)||"object"!=typeof e?this.hideAnimation:e,m(e)?(K([this.element],qn_OPEN),V([this.element],qn_CLOSE),this.trigger("close")):(e.end=function(){i.isDestroyed||(K([i.element],qn_OPEN),V([i.element],qn_CLOSE),i.trigger("close"))},new Hs(e).animate(this.element)),this.unwireEvents()},t.prototype.getScrollableParent=function(e){return this.checkFixedParent(e),function ME(n,t){for(var e=getComputedStyle(n),i=[],r=/(auto|scroll)/,s=n.parentElement;s&&"HTML"!==s.tagName;){var o=getComputedStyle(s);!("absolute"===e.position&&"static"===o.position)&&r.test(o.overflow+o.overflowY+o.overflowX)&&i.push(s),s=s.parentElement}return t||i.push(document),i}(e,this.fixedParent)},t.prototype.checkFixedParent=function(e){for(var i=e.parentElement;i&&"HTML"!==i.tagName;){var r=getComputedStyle(i);("fixed"===r.position||"sticky"===r.position)&&!m(this.element)&&this.element.offsetParent&&"BODY"===this.element.offsetParent.tagName&&"hidden"!==getComputedStyle(this.element.offsetParent).overflow&&(this.element.style.top=window.scrollY>parseInt(this.element.style.top,10)?Re(window.scrollY-parseInt(this.element.style.top,10)):Re(parseInt(this.element.style.top,10)-window.scrollY),this.element.style.position="fixed",this.fixedParent=!0),i=i.parentElement,!m(this.element)&&m(this.element.offsetParent)&&"fixed"===r.position&&"fixed"===this.element.style.position&&(this.fixedParent=!0)}},bn([I("auto")],t.prototype,"height",void 0),bn([I("auto")],t.prototype,"width",void 0),bn([I(null)],t.prototype,"content",void 0),bn([I("container")],t.prototype,"targetType",void 0),bn([I(null)],t.prototype,"viewPortElement",void 0),bn([I({X:"none",Y:"none"})],t.prototype,"collision",void 0),bn([I("")],t.prototype,"relateTo",void 0),bn([re({},d4)],t.prototype,"position",void 0),bn([I(0)],t.prototype,"offsetX",void 0),bn([I(0)],t.prototype,"offsetY",void 0),bn([I(1e3)],t.prototype,"zIndex",void 0),bn([I(!1)],t.prototype,"enableRtl",void 0),bn([I("reposition")],t.prototype,"actionOnScroll",void 0),bn([I(null)],t.prototype,"showAnimation",void 0),bn([I(null)],t.prototype,"hideAnimation",void 0),bn([H()],t.prototype,"open",void 0),bn([H()],t.prototype,"close",void 0),bn([H()],t.prototype,"targetExitViewport",void 0),bn([Ft],t)}(Ii);function dc(n){for(var t=n.parentElement,e=[];t&&"BODY"!==t.tagName;){var i=document.defaultView.getComputedStyle(t,null).getPropertyValue("z-index"),r=document.defaultView.getComputedStyle(t,null).getPropertyValue("position");"auto"!==i&&"static"!==r&&e.push(i),t=t.parentElement}for(var s=[],o=0;o2147483647?2147483647:c}var Ui,ka,uf,Ih,DE,bh,$t,Mh,wE=["north-west","north","north-east","west","east","south-west","south","south-east"],Yg="e-resize-handle",uc="e-focused-handle",CJ="e-dlg-resizable",u4=["e-restrict-left"],f4="e-resize-viewport",EJ=["north","west","east","south"],CE=0,EE=0,p4=0,g4=0,Qg=0,Gg=0,Xg=null,xE=null,TE=null,Q0=!0,v4=0,AE=!0;function xJ(n){LE();var t=Si("span",{attrs:{unselectable:"on",contenteditable:"false"}});t.setAttribute("class","e-dialog-border-resize e-"+n),"south"===n&&(t.style.height="2px",t.style.width="100%",t.style.bottom="0px",t.style.left="0px"),"north"===n&&(t.style.height="2px",t.style.width="100%",t.style.top="0px",t.style.left="0px"),"east"===n&&(t.style.height="100%",t.style.width="2px",t.style.right="0px",t.style.top="0px"),"west"===n&&(t.style.height="100%",t.style.width="2px",t.style.left="0px",t.style.top="0px"),Ui.appendChild(t)}function m4(n){var t;return m(n)||(t="string"==typeof n?document.querySelector(n):n),t}function y4(n){for(var t=n||this,e=Ui.querySelectorAll("."+Yg),i=0;i-1?"mouse":"touch"}function I4(n){if(n.preventDefault(),Ui=n.target.parentElement,LE(),Qg=n.pageX,Gg=n.pageY,n.target.classList.add(uc),m(Xg)||!0!==Xg(n,this)){this.targetEle&&Ui&&Ui.querySelector("."+CJ)&&($t="body"===this.target?null:this.targetEle,bh=this.targetEle.clientWidth,Ih=this.targetEle.clientHeight);var e=m($t)?document:$t;E.add(e,"mousemove",qg,this),E.add(document,"mouseup",G0,this);for(var i=0;i=0||s.top<0)&&(e=!0):e=!0;var a=EE+(r-Gg);a=a>uf?a:uf;var l=0;m($t)||(l=o.top);var h=m($t)?0:$t.offsetHeight-$t.clientHeight,c=s.top-l-h/2;if(c=c<0?0:c,s.top>0&&c+a>Ih){if(e=!1,Ui.classList.contains(f4))return;Ui.style.height=Ih-parseInt(c.toString(),10)+"px"}else{var d=0;if(e){s.top<0&&t+(s.height+s.top)>0&&a+(d=s.top)<=30&&(a=s.height-(s.height+s.top)+30),a+s.top>=Ih&&(Ui.style.height=s.height+(t-(s.height+s.top))+"px");var u=m($t)?d:c;a>=uf&&a+u<=Ih&&(Ui.style.height=a+"px")}}}function OE(n){var e,t=!1,i="mouse"===S4(n.type)?n.pageY:n.touches[0].pageY,r=fc(Ui),s=m($t)?0:$t.offsetHeight-$t.clientHeight;m($t)||(e=fc($t)),(!m($t)&&r.top-e.top>0||m($t)&&i>0||!m($t)&&Math.floor(r.top-e.top+r.height+(e.bottom-r.bottom))-s<=Ih)&&(t=!0);var o=EE-(i-Gg);if(t&&o>=uf&&o<=Ih){var a=0;m($t)||(a=e.top);var l=g4-a+(i-Gg);l=l>0?l:1,Ui.style.height=o+"px",Ui.style.top=l+"px"}}function kE(n){var i,t=document.documentElement.clientWidth,e=!1;m($t)||(i=fc($t));var r="mouse"===S4(n.type)?n.pageX:n.touches[0].pageX,s=fc(Ui),o=m($t)?0:$t.offsetWidth-$t.clientWidth,a=m($t)?0:i.left,l=m($t)?0:i.width;m(Mh)&&(m($t)?Mh=t:(Mh=s.left-a-o/2+s.width,Mh+=l-o-Mh)),(!m($t)&&Math.floor(s.left-i.left+s.width+(i.right-s.right))-o<=bh||m($t)&&r>=0)&&(e=!0);var h=CE-(r-Qg);if(Q0&&(h=h>Mh?Mh:h),e&&h>=DE&&h<=bh){var c=0;m($t)||(c=i.left);var d=p4-c+(r-Qg);d=d>0?d:1,h!==v4&&AE&&(Ui.style.width=h+"px"),Q0&&(Ui.style.left=d+"px",AE=1!==d)}v4=h}function PE(n){var i,t=document.documentElement.clientWidth,e=!1;m($t)||(i=fc($t));var s=(n.touches?n.changedTouches[0]:n).pageX,o=fc(Ui);(!m($t)&&(o.left-i.left+o.width<=bh||o.right-i.left>=o.width)||m($t)&&t-s>0)&&(e=!0);var a=CE+(s-Qg),l=0;if(m($t)||(l=i.left),o.left-l+a>bh){if(e=!1,Ui.classList.contains(f4))return;Ui.style.width=bh-(o.left-l)+"px"}e&&a>=DE&&a<=bh&&(Ui.style.width=a+"px")}function M4(){for(var n=Ui.querySelectorAll("."+Yg),t=0;t=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},OJ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return zE(t,n),Zt([I(!0)],t.prototype,"isFlat",void 0),Zt([I()],t.prototype,"buttonModel",void 0),Zt([I("Button")],t.prototype,"type",void 0),Zt([H()],t.prototype,"click",void 0),t}(Ee),kJ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return zE(t,n),Zt([I("Fade")],t.prototype,"effect",void 0),Zt([I(400)],t.prototype,"duration",void 0),Zt([I(0)],t.prototype,"delay",void 0),t}(Ee),X0="e-dialog",RE="e-rtl",HE="e-dlg-header-content",w4="e-dlg-header",q0="e-footer-content",$0="e-dlg-modal",C4="e-icon-dlg-close",Pa="e-dlg-target",ea="e-scroll-disabled",E4="e-device",Z0="e-dlg-fullscreen",D4="e-dlg-closeicon-btn",x4="e-popup-open",T4="Information",A4="e-scroll-disabled",L4="e-alert-dialog",N4="e-confirm-dialog",BE="e-dlg-resizable",ff="e-restrict-left",O4="e-resize-viewport",FE="user action",QJ=function(n){function t(e,i){var r=n.call(this,e,i)||this;return r.needsID=!0,r}return zE(t,n),t.prototype.render=function(){this.initialize(),this.initRender(),this.wireEvents(),"100%"===this.width&&(this.element.style.width=""),""!==this.minHeight&&(this.element.style.minHeight=Re(this.minHeight)),this.enableResize&&(this.setResize(),this.isModal&&(this.isModelResize=!0),"None"===this.animationSettings.effect&&this.getMinHeight()),this.renderComplete()},t.prototype.initializeValue=function(){this.dlgClosedBy=FE},t.prototype.preRender=function(){var e=this;if(this.initializeValue(),this.headerContent=null,this.allowMaxHeight=!0,this.preventVisibility=!0,this.clonedEle=this.element.cloneNode(!0),this.closeIconClickEventHandler=function(s){e.dlgClosedBy="close icon",e.hide(s)},this.dlgOverlayClickEventHandler=function(s){e.dlgClosedBy="overlayClick",s.preventFocus=!1,e.trigger("overlayClick",s,function(o){o.preventFocus||e.focusContent(),e.dlgClosedBy=FE})},this.l10n=new uo("dialog",{close:"Close"},this.locale),this.checkPositionData(),m(this.target)){var r=this.isProtectedOnChange;this.isProtectedOnChange=!0,this.target=document.body,this.isProtectedOnChange=r}},t.prototype.updatePersistData=function(){this.enablePersistence&&this.setProperties({width:parseFloat(this.element.style.width),height:parseFloat(this.element.style.height),position:{X:parseFloat(this.dragObj.element.style.left),Y:parseFloat(this.dragObj.element.style.top)}},!0)},t.prototype.isNumberValue=function(e){return/^[-+]?\d*\.?\d+$/.test(e)},t.prototype.checkPositionData=function(){if(!m(this.position)){if(!m(this.position.X)&&"number"!=typeof this.position.X&&this.isNumberValue(this.position.X)){var i=this.isProtectedOnChange;this.isProtectedOnChange=!0,this.position.X=parseFloat(this.position.X),this.isProtectedOnChange=i}m(this.position.Y)||"number"==typeof this.position.Y||this.isNumberValue(this.position.Y)&&(i=this.isProtectedOnChange,this.isProtectedOnChange=!0,this.position.Y=parseFloat(this.position.Y),this.isProtectedOnChange=i)}},t.prototype.getEle=function(e,i){for(var r=void 0,s=0;s=0&&t[e])xJ(t[e]);else if(""!==t[e].trim()){var i=Si("div",{className:"e-icons "+Yg+" e-"+t[e]});Ui.appendChild(i)}uf=n.minHeight,DE=n.minWidth,bh=n.maxWidth,Ih=n.maxHeight,n.proxy&&n.proxy.element&&n.proxy.element.classList.contains("e-dialog")?y4(n.proxy):y4()}({element:this.element,direction:r,minHeight:parseInt(e.slice(0,i.indexOf("p")),10),maxHeight:this.targetEle.clientHeight,minWidth:parseInt(i.slice(0,i.indexOf("p")),10),maxWidth:this.targetEle.clientWidth,boundary:this.target===document.body?null:this.targetEle,resizeBegin:this.onResizeStart.bind(this),resizeComplete:this.onResizeComplete.bind(this),resizing:this.onResizing.bind(this),proxy:this}),this.wireWindowResizeEvent()}else M4(),this.unWireWindowResizeEvent(),this.element.classList.remove(this.isModal?ff:O4),this.element.classList.remove(BE)},t.prototype.getFocusElement=function(e){var r=e.querySelectorAll('input,select,textarea,button:enabled,a,[contenteditable="true"],[tabindex]');return{element:r[r.length-1]}},t.prototype.keyDown=function(e){var i=this;if(9===e.keyCode&&this.isModal){var r=void 0;m(this.btnObj)||(r=this.btnObj[this.btnObj.length-1]),m(this.btnObj)&&!m(this.ftrTemplateContent)&&(r=this.getFocusElement(this.ftrTemplateContent)),m(this.btnObj)&&m(this.ftrTemplateContent)&&!m(this.contentEle)&&(r=this.getFocusElement(this.contentEle)),!m(r)&&document.activeElement===r.element&&!e.shiftKey&&(e.preventDefault(),this.focusableElements(this.element).focus()),document.activeElement===this.focusableElements(this.element)&&e.shiftKey&&(e.preventDefault(),m(r)||r.element.focus())}var h,s=document.activeElement,o=["input","textarea"].indexOf(s.tagName.toLowerCase())>-1,a=!1;if(o||(a=s.hasAttribute("contenteditable")&&"true"===s.getAttribute("contenteditable")),27===e.keyCode&&this.closeOnEscape){this.dlgClosedBy="escape";var l=document.querySelector(".e-popup-open:not(.e-dialog)");!m(l)&&!l.classList.contains("e-toolbar-pop")&&!l.classList.contains("e-slider-tooltip")||this.hide(e)}(13===e.keyCode&&!e.ctrlKey&&"textarea"!==s.tagName.toLowerCase()&&o&&!m(this.primaryButtonEle)||13===e.keyCode&&e.ctrlKey&&("textarea"===s.tagName.toLowerCase()||a)&&!m(this.primaryButtonEle))&&this.buttons.some(function(d,u){h=u;var f=d.buttonModel;return!m(f)&&!0===f.isPrimary})&&"function"==typeof this.buttons[h].click&&setTimeout(function(){i.buttons[h].click.call(i,e)})},t.prototype.initialize=function(){m(this.target)||(this.targetEle="string"==typeof this.target?document.querySelector(this.target):this.target),this.isBlazorServerRender()||V([this.element],X0),X.isDevice&&V([this.element],E4),this.isBlazorServerRender()||this.setCSSClass(),this.setMaxHeight()},t.prototype.initRender=function(){var e=this;if(this.initialRender=!0,this.isBlazorServerRender()||Fe(this.element,{role:"dialog"}),1e3===this.zIndex?(this.setzIndex(this.element,!1),this.calculatezIndex=!0):this.calculatezIndex=!1,this.setTargetContent(),""!==this.header&&!m(this.header)&&this.setHeader(),this.renderCloseIcon(),this.setContent(),""===this.footerTemplate||m(this.footerTemplate)?!m(this.buttons[0])&&!m(this.buttons[0].buttonModel)&&this.setButton():this.setFooterTemplate(),this.allowDragging&&!m(this.headerContent)&&this.setAllowDragging(),Fe(this.element,{"aria-modal":this.isModal?"true":"false"}),this.isModal&&this.setIsModal(),!0!==this.element.classList.contains(L4)&&!0!==this.element.classList.contains(N4)&&!m(this.element.parentElement)){var i=this.isModal?this.dlgContainer.parentElement:this.element.parentElement;this.refElement=this.createElement("div",{className:"e-dlg-ref-element"}),i.insertBefore(this.refElement,this.isModal?this.dlgContainer:this.element)}if(m(this.targetEle)||this.targetEle.appendChild(this.isModal?this.dlgContainer:this.element),this.popupObj=new cc(this.element,{height:this.height,width:this.width,zIndex:this.zIndex,relateTo:this.target,actionOnScroll:"none",enableRtl:this.enableRtl,open:function(o){var a={container:e.isModal?e.dlgContainer:e.element,element:e.element,target:e.target,preventFocus:!1};e.enableResize&&e.resetResizeIcon(),e.trigger("open",a,function(l){l.preventFocus||e.focusContent()})},close:function(o){e.isModal&&V([e.dlgOverlay],"e-fade"),e.unBindEvent(e.element),e.isModal&&(e.dlgContainer.style.display="none"),e.trigger("close",e.closeArgs);var a=document.activeElement;!m(a)&&!m(a.blur)&&a.blur(),!m(e.storeActiveElement)&&!m(e.storeActiveElement.focus)&&e.storeActiveElement.focus()}}),this.positionChange(),this.setEnableRTL(),this.isBlazorServerRender()||(V([this.element],"e-popup-close"),this.isModal&&this.setOverlayZindex()),this.visible){if(this.show(),this.isModal){var r=this.getTargetContainer(this.target);r instanceof Element&&"rtl"===window.getComputedStyle(r).getPropertyValue("direction")&&this.setPopupPosition()}}else this.isModal&&(this.dlgOverlay.style.display="none");this.initialRender=!1},t.prototype.getTargetContainer=function(e){var i=null;if("string"==typeof e)if(e.startsWith("#"))i=document.getElementById(e.substring(1));else if(e.startsWith(".")){var r=document.getElementsByClassName(e.substring(1));i=r.length>0?r[0]:null}else!(e instanceof HTMLElement)&&e!==document.body&&(i=document.querySelector(e));else e instanceof HTMLElement&&(i=e);return i},t.prototype.resetResizeIcon=function(){var e=this.getMinHeight();if(this.targetEle.offsetHeight0&&("function"==typeof this.buttons[e].click&&E.add(s[e],"click",this.buttons[e].click,this),"object"==typeof this.buttons[e].click&&E.add(s[e],"click",this.buttonClickHandler.bind(this,e),this)),!this.isBlazorServerRender()&&!m(this.ftrTemplateContent)&&(this.btnObj[e].appendTo(this.ftrTemplateContent.children[e]),this.buttons[e].isFlat&&this.btnObj[e].element.classList.add("e-flat"),this.primaryButtonEle=this.element.getElementsByClassName("e-primary")[0]))},t.prototype.buttonClickHandler=function(e){this.trigger("buttons["+e+"].click",{})},t.prototype.setContent=function(){this.contentEle=this.createElement("div",{className:"e-dlg-content",id:this.element.id+"_dialog-content"}),Fe(this.element,this.headerEle?{"aria-describedby":this.element.id+"_title "+this.element.id+"_dialog-content"}:{"aria-describedby":this.element.id+"_dialog-content"}),this.innerContentElement?this.contentEle.appendChild(this.innerContentElement):(!m(this.content)&&""!==this.content||!this.initialRender)&&(("string"!=typeof this.content||ce())&&this.content instanceof HTMLElement?this.contentEle.appendChild(this.content):this.setTemplate(this.content,this.contentEle,"content")),m(this.headerContent)?this.element.insertBefore(this.contentEle,this.element.children[0]):this.element.insertBefore(this.contentEle,this.element.children[1]),"auto"===this.height&&(!this.isBlazorServerRender()&&X.isIE&&""===this.element.style.width&&!m(this.width)&&(this.element.style.width=Re(this.width)),this.setMaxHeight())},t.prototype.setTemplate=function(e,i,r){var s,o,a;o=i.classList.contains(w4)?this.element.id+"header":i.classList.contains(q0)?this.element.id+"footerTemplate":this.element.id+"content",m(e.outerHTML)?("string"==typeof e||"string"!=typeof e||ce()&&!this.isStringTemplate)&&("string"==typeof e&&(e=this.sanitizeHelper(e)),this.isVue||"string"!=typeof e?(s=si(e),a=e):i.innerHTML=e):i.appendChild(e);var l=[];if(!m(s)){for(var c=0,d=s({},this,r,o,!(ce()&&!this.isStringTemplate&&0===a.indexOf("
Blazor"))||this.isStringTemplate);c/g,"");(this.element.children.length>0||i)&&(this.innerContentElement=document.createDocumentFragment(),[].slice.call(this.element.childNodes).forEach(function(r){8!==r.nodeType&&e.innerContentElement.appendChild(r)}))}},t.prototype.setHeader=function(){this.headerEle?this.headerEle.innerHTML="":this.headerEle=this.createElement("div",{id:this.element.id+"_title",className:w4}),this.createHeaderContent(),this.headerContent.appendChild(this.headerEle),this.setTemplate(this.header,this.headerEle,"header"),Fe(this.element,{"aria-describedby":this.element.id+"_title"}),Fe(this.element,{"aria-labelledby":this.element.id+"_dialog-header"}),this.element.insertBefore(this.headerContent,this.element.children[0]),this.allowDragging&&!m(this.headerContent)&&this.setAllowDragging()},t.prototype.setFooterTemplate=function(){this.ftrTemplateContent?this.ftrTemplateContent.innerHTML="":this.ftrTemplateContent=this.createElement("div",{className:q0}),""===this.footerTemplate||m(this.footerTemplate)?this.ftrTemplateContent.innerHTML=this.buttonContent.join(""):this.setTemplate(this.footerTemplate,this.ftrTemplateContent,"footerTemplate"),this.element.appendChild(this.ftrTemplateContent)},t.prototype.createHeaderContent=function(){m(this.headerContent)&&(this.headerContent=this.createElement("div",{id:this.element.id+"_dialog-header",className:HE}))},t.prototype.renderCloseIcon=function(){this.showCloseIcon&&(this.closeIcon=this.createElement("button",{className:D4,attrs:{type:"button"}}),this.closeIconBtnObj=new ys({cssClass:"e-flat",iconCss:C4+" e-icons"}),this.closeIconTitle(),m(this.headerContent)?(this.createHeaderContent(),gl([this.closeIcon],this.headerContent),this.element.insertBefore(this.headerContent,this.element.children[0])):gl([this.closeIcon],this.headerContent),this.closeIconBtnObj.appendTo(this.closeIcon))},t.prototype.closeIconTitle=function(){this.l10n.setLocale(this.locale);var e=this.l10n.getConstant("close");this.closeIcon.setAttribute("title",e),this.closeIcon.setAttribute("aria-label",e)},t.prototype.setCSSClass=function(e){e&&(K([this.element],e.split(" ")),this.isModal&&!m(this.dlgContainer)&&K([this.dlgContainer],e.split(" "))),this.cssClass&&(V([this.element],this.cssClass.split(" ")),this.isModal&&!m(this.dlgContainer)&&V([this.dlgContainer],this.cssClass.split(" ")))},t.prototype.setIsModal=function(){this.dlgContainer=this.createElement("div",{className:"e-dlg-container"}),this.setCSSClass(),this.element.classList.remove(x4),this.element.parentNode.insertBefore(this.dlgContainer,this.element),this.dlgContainer.appendChild(this.element),V([this.element],$0),this.dlgOverlay=this.createElement("div",{className:"e-dlg-overlay"}),this.dlgOverlay.style.zIndex=(this.zIndex-1).toString(),this.dlgContainer.appendChild(this.dlgOverlay)},t.prototype.getValidFocusNode=function(e){for(var i,r=0;r0||"a"===i.tagName.toLowerCase()&&i.hasAttribute("href"))&&i.tabIndex>-1&&!i.disabled&&!this.disableElement(i,'[disabled],[aria-disabled="true"],[type="hidden"]'))return i;i=null}return i},t.prototype.focusableElements=function(e){if(!m(e)){var r=e.querySelectorAll('input,select,textarea,button,a,[contenteditable="true"],[tabindex]');return this.getValidFocusNode(r)}return null},t.prototype.getAutoFocusNode=function(e){var i=e.querySelector("."+D4),s=e.querySelectorAll("[autofocus]"),o=this.getValidFocusNode(s);if(ce()&&(this.primaryButtonEle=this.element.getElementsByClassName("e-primary")[0]),m(o)){if(!m(o=this.focusableElements(this.contentEle)))return o;if(!m(this.primaryButtonEle))return this.element.querySelector(".e-primary")}else i=o;return i},t.prototype.disableElement=function(e,i){var r=e?e.matches||e.webkitMatchesSelector||e.msGetRegionContent:null;if(r)for(;e;e=e.parentNode)if(e instanceof Element&&r.call(e,i))return e;return null},t.prototype.focusContent=function(){var e=this.getAutoFocusNode(this.element),i=m(e)?this.element:e,r=X.userAgent;(r.indexOf("MSIE ")>0||r.indexOf("Trident/")>0)&&this.element.focus(),i.focus(),this.unBindEvent(this.element),this.bindEvent(this.element)},t.prototype.bindEvent=function(e){E.add(e,"keydown",this.keyDown,this)},t.prototype.unBindEvent=function(e){E.remove(e,"keydown",this.keyDown)},t.prototype.updateSanitizeContent=function(){this.isBlazorServerRender()||(this.contentEle.innerHTML=this.sanitizeHelper(this.content))},t.prototype.isBlazorServerRender=function(){return ce()&&this.isServerRendered},t.prototype.getModuleName=function(){return"dialog"},t.prototype.onPropertyChanged=function(e,i){if(this.element.classList.contains(X0))for(var r=0,s=Object.keys(e);r0?this.showCloseIcon||""!==this.header&&!m(this.header)?this.showCloseIcon||he(this.closeIcon):(he(this.headerContent),this.headerContent=null):(this.renderCloseIcon(),this.wireEvents());break;case"locale":this.showCloseIcon&&this.closeIconTitle();break;case"visible":this.visible?this.show():this.hide();break;case"isModal":this.updateIsModal();break;case"height":je(this.element,{height:Re(e.height)}),this.updatePersistData();break;case"width":je(this.element,{width:Re(e.width)}),this.updatePersistData();break;case"zIndex":this.popupObj.zIndex=this.zIndex,this.isModal&&this.setOverlayZindex(this.zIndex),this.element.style.zIndex!==this.zIndex.toString()&&(this.calculatezIndex=!1);break;case"cssClass":this.setCSSClass(i.cssClass);break;case"buttons":this.unWireButtonEvents(),this.destroyButtons(),m(this.ftrTemplateContent)||(he(this.ftrTemplateContent),this.ftrTemplateContent=null),this.footerTemplate="",this.setButton();break;case"allowDragging":this.allowDragging&&!m(this.headerContent)?this.setAllowDragging():this.dragObj.destroy();break;case"target":this.setTarget(e.target);break;case"position":if(this.checkPositionData(),this.isModal){var a=this.position.X,l=this.position.Y;m(i.position)||(m(i.position.X)||(a=i.position.X),m(i.position.Y)||(l=i.position.Y)),this.dlgContainer.classList.contains("e-dlg-"+a+"-"+l)&&this.dlgContainer.classList.remove("e-dlg-"+a+"-"+l)}this.positionChange(),this.updatePersistData();break;case"enableRtl":this.setEnableRTL();break;case"enableResize":this.setResize(),this.isModelResize=this.enableResize&&this.isModal,this.enableResize&&this.dialogOpen&&this.resetResizeIcon();break;case"minHeight":""!==this.minHeight&&(this.element.style.minHeight=Re(this.minHeight))}},t.prototype.setTarget=function(e){this.popupObj.relateTo=e,this.target=e,this.targetEle="string"==typeof this.target?document.querySelector(this.target):this.target,this.dragObj&&(this.dragObj.dragArea=this.targetEle),this.setMaxHeight(),this.isModal&&this.updateIsModal(),this.enableResize&&this.setResize(),m(this.targetEle)||(this.isModal&&!m(this.dlgContainer)?this.targetEle.appendChild(this.dlgContainer):m(this.element)||this.targetEle.appendChild(this.element))},t.prototype.updateIsModal=function(){if(this.element.setAttribute("aria-modal",this.isModal?"true":"false"),this.isModal)m(this.dlgOverlay)&&(this.setIsModal(),this.element.style.top="0px",this.element.style.left="0px",m(this.targetEle)||this.targetEle.appendChild(this.dlgContainer));else{for(K([this.element],$0),K([document.body],[Pa,ea]),he(this.dlgOverlay);this.dlgContainer.firstChild;)this.dlgContainer.parentElement.insertBefore(this.dlgContainer.firstChild,this.dlgContainer);this.dlgContainer.parentElement.removeChild(this.dlgContainer)}this.visible&&this.show(),this.positionChange(),this.isModal&&this.dlgOverlay&&E.add(this.dlgOverlay,"click",this.dlgOverlayClickEventHandler,this)},t.prototype.setzIndex=function(e,i){var r=this.isProtectedOnChange;this.isProtectedOnChange=!0;var s=dc(e);this.zIndex=s>this.zIndex?s:this.zIndex,this.isProtectedOnChange=r,i&&(this.popupObj.zIndex=this.zIndex)},t.prototype.windowResizeHandler=function(){(function AJ(n){bh=n})(this.targetEle.clientWidth),function LJ(n){Ih=n}(this.targetEle.clientHeight),this.setMaxHeight()},t.prototype.getPersistData=function(){return this.addOnPersist(["width","height","position"])},t.prototype.removeAllChildren=function(e){for(;e.children[0];)this.removeAllChildren(e.children[0]),e.removeChild(e.children[0])},t.prototype.destroy=function(){if(!this.isDestroyed){var e=[RE,$0,BE,ff,Z0,E4],i=["role","aria-modal","aria-labelledby","aria-describedby","aria-grabbed","tabindex","style"];K([this.targetEle],[Pa,ea]),!m(this.element)&&this.element.classList.contains(Z0)&&K([document.body],[Pa,ea]),this.isModal&&K([m(this.targetEle)?document.body:this.targetEle],ea),this.unWireEvents(),this.unWireButtonEvents(),this.destroyButtons(),m(this.closeIconBtnObj)||this.closeIconBtnObj.destroy(),m(this.dragObj)||this.dragObj.destroy(),!m(this.popupObj.element)&&this.popupObj.element.classList.contains("e-popup")&&this.popupObj.destroy(),K([this.element],e),!m(this.cssClass)&&""!==this.cssClass&&K([this.element],this.cssClass.split(" ")),!m(this.refElement)&&!m(this.refElement.parentElement)&&(this.refElement.parentElement.insertBefore(this.isModal?this.dlgContainer:this.element,this.refElement),he(this.refElement),this.refElement=void 0),this.isModal&&(he(this.dlgOverlay),this.dlgContainer.parentNode.insertBefore(this.element,this.dlgContainer),he(this.dlgContainer)),this.element.innerHTML=this.clonedEle.innerHTML;for(var r=0;r0&&""===this.footerTemplate&&this.ftrTemplateContent)for(var e=0;e=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},_E="e-tooltip",B4="e-icons",F4="e-tooltip-close",UE="e-tooltip-wrap",_4="e-tip-content",pf="e-arrow-tip",U4="e-arrow-tip-outer",J0="e-arrow-tip-inner",$g="e-tip-bottom",jE="e-tip-top",j4="e-tip-left",VE="e-tip-right",WE="e-popup",Zg="e-popup-open",YE="e-popup-close",K0="e-lib",V4="e-tooltip-popup-container",JJ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return P4(t,n),Gi([I({effect:"FadeIn",duration:150,delay:0})],t.prototype,"open",void 0),Gi([I({effect:"FadeOut",duration:150,delay:0})],t.prototype,"close",void 0),t}(Ee),wh=function(n){function t(e,i){var r=n.call(this,e,i)||this;return r.mouseMoveEvent=null,r.mouseMoveTarget=null,r.containerElement=null,r.isBodyContainer=!0,r}return P4(t,n),t.prototype.initialize=function(){this.formatPosition(),V([this.element],_E)},t.prototype.formatPosition=function(){var e,i;this.position&&(0===this.position.indexOf("Top")||0===this.position.indexOf("Bottom")?(e=this.position.split(/(?=[A-Z])/),this.tooltipPositionY=e[0],this.tooltipPositionX=e[1]):(i=this.position.split(/(?=[A-Z])/),this.tooltipPositionX=i[0],this.tooltipPositionY=i[1]))},t.prototype.renderArrow=function(){this.setTipClass(this.position);var e=this.createElement("div",{className:pf+" "+this.tipClass});e.appendChild(this.createElement("div",{className:U4+" "+this.tipClass})),e.appendChild(this.createElement("div",{className:J0+" "+this.tipClass})),this.tooltipEle.appendChild(e)},t.prototype.setTipClass=function(e){this.tipClass=0===e.indexOf("Right")?j4:0===e.indexOf("Bottom")?jE:0===e.indexOf("Left")?VE:$g},t.prototype.renderPopup=function(e){var i=this.mouseTrail?{top:0,left:0}:this.getTooltipPosition(e);this.tooltipEle.classList.remove(K0),this.popupObj=new cc(this.tooltipEle,{height:this.height,width:this.width,position:{X:i.left,Y:i.top},enableRtl:this.enableRtl,open:this.openPopupHandler.bind(this),close:this.closePopupHandler.bind(this)})},t.prototype.getScalingFactor=function(e){if(!e)return{x:1,y:1};var i={x:1,y:1},r=e.closest('[style*="transform: scale"]');if(r&&r!==this.tooltipEle&&r.contains(this.tooltipEle)){var a=window.getComputedStyle(r).getPropertyValue("transform").match(/matrix\(([^)]+)\)/)[1].split(",").map(parseFloat);i.x=a[0],i.y=a[3]}return i},t.prototype.getTooltipPosition=function(e){this.tooltipEle.style.display="block";var i=this.element.closest('[style*="zoom"]');i&&(i.contains(this.tooltipEle)||(this.tooltipEle.style.zoom=getComputedStyle(i).zoom));var r=ns(e,this.tooltipPositionX,this.tooltipPositionY,!this.isBodyContainer,this.isBodyContainer?null:this.containerElement.getBoundingClientRect()),s=this.getScalingFactor(e),o=this.calculateTooltipOffset(this.position,s.x,s.y),a=this.calculateElementPosition(r,o),c=this.collisionFlipFit(e,a[0],a[1]);return c.left=c.left/s.x,c.top=c.top/s.y,this.tooltipEle.style.display="",c},t.prototype.windowResize=function(){this.reposition(this.findTarget())},t.prototype.reposition=function(e){if(this.popupObj&&e){var i=this.getTooltipPosition(e);this.popupObj.position={X:i.left,Y:i.top},this.popupObj.dataBind()}},t.prototype.openPopupHandler=function(){!this.mouseTrail&&this.needTemplateReposition()&&this.reposition(this.findTarget()),this.trigger("afterOpen",this.tooltipEventArgs),this.tooltipEventArgs=null},t.prototype.closePopupHandler=function(){this.isReact&&!("Click"===this.opensOn||"function"==typeof this.content)&&this.clearTemplate(["content"]),this.clear();var e={type:this.tooltipEventArgs.event?this.tooltipEventArgs.event.type:null,cancel:!1,target:this.tooltipEventArgs.target,event:this.tooltipEventArgs.event?this.tooltipEventArgs.event:null,element:this.tooltipEle,isInteracted:!m(this.tooltipEventArgs.event)};this.trigger("afterClose",e),e=null},t.prototype.calculateTooltipOffset=function(e,i,r){void 0===i&&(i=1),void 0===r&&(r=1);var o,a,l,h,c,d,u,f,s={top:0,left:0};if(1!==i||1!==r){var p=this.tooltipEle.getBoundingClientRect(),g=void 0;l=Math.round(p.width),h=Math.round(p.height),(c=_("."+pf,this.tooltipEle))&&(g=c.getBoundingClientRect()),o=c?Math.round(g.width):0,a=c?Math.round(g.height):0,d=this.showTipPointer?0:8,u=a/2+2+(h-this.tooltipEle.clientHeight*r),f=o/2+2+(l-this.tooltipEle.clientWidth*i)}else l=this.tooltipEle.offsetWidth,h=this.tooltipEle.offsetHeight,c=_("."+pf,this.tooltipEle),d=this.showTipPointer?0:8,u=(a=c?c.offsetHeight:0)/2+2+(this.tooltipEle.offsetHeight-this.tooltipEle.clientHeight),f=(o=c?c.offsetWidth:0)/2+2+(this.tooltipEle.offsetWidth-this.tooltipEle.clientWidth);switch(this.mouseTrail&&(d+=2),e){case"RightTop":s.left+=o+d,s.top-=h-u;break;case"RightCenter":s.left+=o+d,s.top-=h/2;break;case"RightBottom":s.left+=o+d,s.top-=u;break;case"BottomRight":s.top+=a+d,s.left-=f;break;case"BottomCenter":s.top+=a+d,s.left-=l/2;break;case"BottomLeft":s.top+=a+d,s.left-=l-f;break;case"LeftBottom":s.left-=o+l+d,s.top-=u;break;case"LeftCenter":s.left-=o+l+d,s.top-=h/2;break;case"LeftTop":s.left-=o+l+d,s.top-=h-u;break;case"TopLeft":s.top-=h+a+d,s.left-=l-f;break;case"TopRight":s.top-=h+a+d,s.left-=f;break;default:s.top-=h+a+d,s.left-=l/2}return s.left+=this.offsetX,s.top+=this.offsetY,s},t.prototype.updateTipPosition=function(e){var i=we("."+pf+",."+U4+",."+J0,this.tooltipEle);K(i,[$g,jE,j4,VE]),this.setTipClass(e),V(i,this.tipClass)},t.prototype.adjustArrow=function(e,i,r,s){var o=_("."+pf,this.tooltipEle);if(!1!==this.showTipPointer&&null!==o){var a,l;this.updateTipPosition(i),this.tooltipEle.style.display="block";var p,h=this.tooltipEle.clientWidth,c=this.tooltipEle.clientHeight,d=_("."+J0,this.tooltipEle),u=o.offsetWidth,f=o.offsetHeight;this.tooltipEle.style.display="",this.tipClass===$g||this.tipClass===jE?(this.tipClass===$g?(l="99.9%",d.style.top="-"+(f-2)+"px"):(l=-(f-1)+"px",d.style.top="-"+(f-6)+"px"),e&&(a=(p="Center"!==r||h>e.offsetWidth||this.mouseTrail)&&"Left"===r||!p&&"End"===this.tipPointerPosition?h-u-2+"px":p&&"Right"===r||!p&&"Start"===this.tipPointerPosition?"2px":!p||"End"!==this.tipPointerPosition&&"Start"!==this.tipPointerPosition?h/2-u/2+"px":"End"===this.tipPointerPosition?e.offsetWidth+(this.tooltipEle.offsetWidth-e.offsetWidth)/2-u/2-2+"px":(this.tooltipEle.offsetWidth-e.offsetWidth)/2-u/2+2+"px")):(this.tipClass===VE?(a="99.9%",d.style.left="-"+(u-2)+"px"):(a=-(u-1)+"px",d.style.left=u-2-u+"px"),l=(p="Center"!==s||c>e.offsetHeight||this.mouseTrail)&&"Top"===s||!p&&"End"===this.tipPointerPosition?c-f-2+"px":p&&"Bottom"===s||!p&&"Start"===this.tipPointerPosition?"2px":c/2-f/2+"px"),o.style.top=l,o.style.left=a}},t.prototype.renderContent=function(e){var i=this,r=_("."+_4,this.tooltipEle);if(this.cssClass&&V([this.tooltipEle],this.cssClass.split(" ")),e&&!m(e.getAttribute("title"))&&(e.setAttribute("data-content",e.getAttribute("title")),e.removeAttribute("title")),m(this.content))e&&!m(e.getAttribute("data-content"))&&(r.innerHTML=e.getAttribute("data-content"));else if(r.innerHTML="",this.content instanceof HTMLElement)r.appendChild(this.content);else if("string"==typeof this.content)this.isAngular?this.setProperties({content:Ai.sanitize(this.content)},!0):this.content=this.enableHtmlSanitizer?Ai.sanitize(this.content):this.content,this.enableHtmlParse?(o=si(this.content)({},this,"content",this.element.id+"content",void 0,void 0,r,this.root))&&Dt(o,r):r.textContent=this.content;else{var o;(o=si(this.content)({},this,"content",this.element.id+"content",void 0,void 0,r))&&(this.isAngular&&setTimeout(function(){i.reposition(e)},1),Dt(o,r)),this.renderReactTemplates()}},t.prototype.renderCloseIcon=function(){if(this.isSticky){var i=this.createElement("div",{className:B4+" "+F4});this.tooltipEle.appendChild(i),E.add(i,X.touchStartEvent,this.onStickyClose,this)}else{var e=this.tooltipEle.querySelector("."+B4+"."+F4);e&>(e)}},t.prototype.addDescribedBy=function(e,i){var r=(e.getAttribute("aria-describedby")||"").split(/\s+/);r.indexOf(i)<0&&r.push(i),Fe(e,{"aria-describedby":r.join(" ").trim(),"data-tooltip-id":i})},t.prototype.removeDescribedBy=function(e){var i=e.getAttribute("data-tooltip-id"),r=(e.getAttribute("aria-describedby")||"").split(/\s+/),s=r.indexOf(i);-1!==s&&r.splice(s,1),e.removeAttribute("data-tooltip-id");var o=r.join(" ").trim();o?e.setAttribute("aria-describedby",o):e.removeAttribute("aria-describedby")},t.prototype.tapHoldHandler=function(e){clearTimeout(this.autoCloseTimer),this.targetHover(e.originalEvent)},t.prototype.touchEndHandler=function(){var e=this;this.isSticky||(this.autoCloseTimer=setTimeout(function(){e.close()},1500))},t.prototype.targetClick=function(e){var i;!m(i=this.target?J(e.target,this.target):this.element)&&(null===i.getAttribute("data-tooltip-id")?this.targetHover(e):this.isSticky||this.hideTooltip(this.animation.close,e,i))},t.prototype.targetHover=function(e){var i;if(!(m(i=this.target?J(e.target,this.target):this.element)||null!==i.getAttribute("data-tooltip-id")&&0===this.closeDelay)){for(var s=0,o=[].slice.call(we('[data-tooltip-id= "'+this.ctrlId+'_content"]',document));s0?this.showTimer=setTimeout(function(){o.mouseTrail&&E.add(i,"mousemove touchstart mouseenter",o.onMouseMove,o),o.popupObj&&(o.popupObj.show(a,i),o.mouseMoveEvent&&o.mouseTrail&&o.onMouseMove(o.mouseMoveEvent))},this.openDelay):this.popupObj&&this.popupObj.show(a,i)}s&&this.wireMouseEvents(s,i)},t.prototype.needTemplateReposition=function(){return!m(this.viewContainerRef)&&"string"!=typeof this.viewContainerRef||this.isReact},t.prototype.checkCollision=function(e,i,r){var s={left:i,top:r,position:this.position,horizontal:this.tooltipPositionX,vertical:this.tooltipPositionY},o=hc(this.tooltipEle,this.checkCollideTarget(),i,r);return o.length>0&&(s.horizontal=o.indexOf("left")>=0?"Right":o.indexOf("right")>=0?"Left":this.tooltipPositionX,s.vertical=o.indexOf("top")>=0?"Bottom":o.indexOf("bottom")>=0?"Top":this.tooltipPositionY),s},t.prototype.calculateElementPosition=function(e,i){return[this.isBodyContainer?e.left+i.left:e.left-this.containerElement.getBoundingClientRect().left+i.left+window.pageXOffset+this.containerElement.scrollLeft,this.isBodyContainer?e.top+i.top:e.top-this.containerElement.getBoundingClientRect().top+i.top+window.pageYOffset+this.containerElement.scrollTop]},t.prototype.collisionFlipFit=function(e,i,r){var s=this.checkCollision(e,i,r),o=s.position;if(this.tooltipPositionY!==s.vertical&&(o=0===this.position.indexOf("Bottom")||0===this.position.indexOf("Top")?s.vertical+this.tooltipPositionX:this.tooltipPositionX+s.vertical),this.tooltipPositionX!==s.horizontal&&(0===o.indexOf("Left")&&(s.vertical="LeftTop"===o||"LeftCenter"===o?"Top":"Bottom",o=s.vertical+"Left"),0===o.indexOf("Right")&&(s.vertical="RightTop"===o||"RightCenter"===o?"Top":"Bottom",o=s.vertical+"Right"),s.horizontal=this.tooltipPositionX),this.tooltipEventArgs={type:null,cancel:!1,target:e,event:null,element:this.tooltipEle,collidedPosition:o},this.trigger("beforeCollision",this.tooltipEventArgs),this.tooltipEventArgs.cancel)o=this.position;else{var a=s.vertical,l=s.horizontal;if(s.position!==o){var h=ns(e,l,a,!this.isBodyContainer,this.isBodyContainer?null:this.containerElement.getBoundingClientRect());this.adjustArrow(e,o,l,a);var c=this.getScalingFactor(e),d=this.calculateTooltipOffset(o,c.x,c.y);d.top-=this.getOffSetPosition("TopBottom",o,this.offsetY),d.left-=this.getOffSetPosition("RightLeft",o,this.offsetX),s.position=o;var u=this.calculateElementPosition(h,d);s.left=u[0],s.top=u[1]}else this.adjustArrow(e,o,l,a)}var f={left:s.left,top:s.top},p=this.isBodyContainer?pE(this.tooltipEle,this.checkCollideTarget(),{X:!0,Y:this.windowCollision},f):f;this.tooltipEle.style.display="block";var g=_("."+pf,this.tooltipEle);if(this.showTipPointer&&null!=g&&(0===o.indexOf("Bottom")||0===o.indexOf("Top"))){var v=parseInt(g.style.left,10)-(p.left-s.left);v<0?v=0:v+g.offsetWidth>this.tooltipEle.clientWidth&&(v=this.tooltipEle.clientWidth-g.offsetWidth),g.style.left=v.toString()+"px"}return this.tooltipEle.style.display="",f.left=p.left,f.top=p.top,f},t.prototype.getOffSetPosition=function(e,i,r){return-1!==e.indexOf(this.position.split(/(?=[A-Z])/)[0])&&-1!==e.indexOf(i.split(/(?=[A-Z])/)[0])?2*r:0},t.prototype.checkCollideTarget=function(){return!this.windowCollision&&this.target?this.element:null},t.prototype.hideTooltip=function(e,i,r){var s=this;this.closeDelay>0?(clearTimeout(this.hideTimer),clearTimeout(this.showTimer),this.hideTimer=setTimeout(function(){s.closeDelay&&s.tooltipEle&&s.isTooltipOpen||s.tooltipHide(e,i,r)},this.closeDelay)):this.tooltipHide(e,i,r)},t.prototype.tooltipHide=function(e,i,r){var o,s=this;o=i?this.target?r||i.target:this.element:_('[data-tooltip-id= "'+this.ctrlId+'_content"]',document),this.tooltipEventArgs={type:i?i.type:null,cancel:!1,target:o,event:i||null,element:this.tooltipEle,isInteracted:!m(i)},this.trigger("beforeClose",this.tooltipEventArgs,function(a){a.cancel?s.isHidden=!1:(s.mouseMoveBeforeRemove(),s.popupHide(e,o,i))})},t.prototype.popupHide=function(e,i,r){i&&r&&this.restoreElement(i),this.isHidden=!0;var s={name:this.animation.close.effect,duration:e.duration,delay:e.delay,timingFunction:"easeIn"};"None"===e.effect&&(s=void 0),this.popupObj&&this.popupObj.hide(s)},t.prototype.restoreElement=function(e){this.unwireMouseEvents(e),m(e.getAttribute("data-content"))||(e.setAttribute("title",e.getAttribute("data-content")),e.removeAttribute("data-content")),this.removeDescribedBy(e)},t.prototype.clear=function(){var e=this.findTarget();e&&this.restoreElement(e),this.tooltipEle&&(K([this.tooltipEle],YE),V([this.tooltipEle],Zg)),this.isHidden&&(this.popupObj&&this.popupObj.destroy(),this.tooltipEle&>(this.tooltipEle),this.tooltipEle=null,this.popupObj=null)},t.prototype.tooltipHover=function(){this.tooltipEle&&(this.isTooltipOpen=!0)},t.prototype.tooltipMouseOut=function(e){this.isTooltipOpen=!1,this.hideTooltip(this.animation.close,e,this.findTarget())},t.prototype.onMouseOut=function(e){var i=e.relatedTarget;if(i&&!this.mouseTrail){var r=J(i,"."+UE+"."+K0+"."+WE);r?E.add(r,"mouseleave",this.tooltipElementMouseOut,this):(this.hideTooltip(this.animation.close,e,this.findTarget()),0===this.closeDelay&&("None"===this.animation.close.effect||this.isReact&&"string"!=typeof this.content)&&this.clear())}else this.hideTooltip(this.animation.close,e,this.findTarget()),this.clear();this.popupObj&&!this.popupObj.element.classList.contains(Zg)&&this.clear()},t.prototype.tooltipElementMouseOut=function(e){this.hideTooltip(this.animation.close,e,this.findTarget()),E.remove(this.element,"mouseleave",this.tooltipElementMouseOut),this.clear()},t.prototype.onStickyClose=function(){this.close()},t.prototype.onMouseMove=function(e){var i=0,r=0;e.type.indexOf("touch")>-1?(e.preventDefault(),i=e.touches[0].pageX,r=e.touches[0].pageY):(i=e.pageX,r=e.pageY),Hs.stop(this.tooltipEle),K([this.tooltipEle],YE),V([this.tooltipEle],Zg),this.adjustArrow(e.target,this.position,this.tooltipPositionX,this.tooltipPositionY);var s=this.getScalingFactor(e.target),o=this.calculateTooltipOffset(this.position,s.x,s.y),h=this.checkCollision(e.target,i+o.left+this.offsetX,r+o.top+this.offsetY);if(this.tooltipPositionX!==h.horizontal||this.tooltipPositionY!==h.vertical){var c=0===this.position.indexOf("Bottom")||0===this.position.indexOf("Top")?h.vertical+h.horizontal:h.horizontal+h.vertical;h.position=c,this.adjustArrow(e.target,h.position,h.horizontal,h.vertical);var d=this.calculateTooltipOffset(h.position,s.x,s.y);h.left=i+d.left-this.offsetX,h.top=r+d.top-this.offsetY}this.tooltipEle.style.left=h.left+"px",this.tooltipEle.style.top=h.top+"px"},t.prototype.keyDown=function(e){this.tooltipEle&&27===e.keyCode&&this.close()},t.prototype.touchEnd=function(e){this.tooltipEle&&null===J(e.target,"."+_E)&&!this.isSticky&&this.close()},t.prototype.scrollHandler=function(e){this.tooltipEle&&!this.isSticky&&!J(e.target,"."+UE+"."+K0+"."+WE)&&!this.isSticky&&this.close()},t.prototype.render=function(){this.initialize(),this.wireEvents(this.opensOn),this.renderComplete()},t.prototype.preRender=function(){this.tipClass=$g,this.tooltipPositionX="Center",this.tooltipPositionY="Top",this.isHidden=!0},t.prototype.wireEvents=function(e){for(var r=0,s=this.getTriggerList(e);r0)for(var i=0,r=e;i0)for(var i=0,r=e;i0&&this.condition&&-1!==this.condition.indexOf("not")&&(e[s].condition=e[s].condition?e[s].condition+"not":"not"),i=e[s].validate(t),r){if(!i)return!1}else if(i)return!0;return r},n.prototype.toJson=function(){var t,e;if(this.isComplex){t=[],e=this.predicates;for(var i=0;ie.length-3?(e=e.substring(0,e.length-1),n.endsWith(n.toLowerCase(t),n.toLowerCase(e))):(e.lastIndexOf("%")!==e.indexOf("%")&&e.lastIndexOf("%")>e.indexOf("%")+1&&(e=e.substring(e.indexOf("%")+1,e.lastIndexOf("%"))),-1!==t.indexOf(e)))},n.fnSort=function(t){return"ascending"===(t=t?n.toLowerCase(t):"ascending")?this.fnAscending:this.fnDescending},n.fnAscending=function(t,e){return m(t)&&m(e)||null==e?-1:"string"==typeof t?t.localeCompare(e):null==t?1:t-e},n.fnDescending=function(t,e){return m(t)&&m(e)?-1:null==e?1:"string"==typeof t?-1*t.localeCompare(e):null==t?-1:e-t},n.extractFields=function(t,e){for(var i={},r=0;r0||e.length>0;)o=t.length>0&&e.length>0?r?r(this.getVal(t,0,i),this.getVal(e,0,i),t[0],e[0])<=0?t:e:t[0][i]0?t:e,s.push(o.shift());return s},n.getVal=function(t,e,i){return i?this.getObject(i,t[e]):t[e]},n.toLowerCase=function(t){return t?"string"==typeof t?t.toLowerCase():t.toString():0===t||!1===t?t.toString():""},n.callAdaptorFunction=function(t,e,i,r){if(e in t){var s=t[e](i,r);m(s)||(i=s)}return i},n.getAddParams=function(t,e,i){var r={};return n.callAdaptorFunction(t,"addParams",{dm:e,query:i,params:i?i.params:[],reqParams:r}),r},n.isPlainObject=function(t){return!!t&&t.constructor===Object},n.isCors=function(){var t=null;try{t=new window.XMLHttpRequest}catch{}return!!t&&"withCredentials"in t},n.getGuid=function(t){var i;return(t||"")+"00000000-0000-4000-0000-000000000000".replace(/0/g,function(r,s){if("crypto"in window&&"getRandomValues"in crypto){var o=new Uint8Array(1);window.crypto.getRandomValues(o),i=o[0]%16|0}else i=16*Math.random()|0;return"0123456789abcdef"[19===s?3&i|8:i]})},n.isNull=function(t){return null==t},n.getItemFromComparer=function(t,e,i){var r,s,o,a=0,l="string"==typeof n.getVal(t,0,e);if(t.length)for(;m(r)&&a0&&(r=s,o=t[a]));return o},n.distinct=function(t,e,i){i=!m(i)&&i;var s,r=[],o={};return t.forEach(function(a,l){(s="object"==typeof t[l]?n.getVal(t,l,e):t[l])in o||(r.push(i?t[l]:s),o[s]=1)}),r},n.processData=function(t,e){var i=this.prepareQuery(t),r=new it(e);t.requiresCounts&&i.requiresCount();var s=r.executeLocal(i),o={result:t.requiresCounts?s.result:s,count:s.count,aggregates:JSON.stringify(s.aggregates)};return t.requiresCounts?o:s},n.prepareQuery=function(t){var e=this,i=new _t;return t.select&&i.select(t.select),t.where&&n.parse.parseJson(t.where).filter(function(o){if(m(o.condition))i.where(o.field,o.operator,o.value,o.ignoreCase,o.ignoreAccent);else{var a=[];o.field?a.push(new Ss(o.field,o.operator,o.value,o.ignoreCase,o.ignoreAccent)):a=a.concat(e.getPredicate(o.predicates)),"or"===o.condition?i.where(Ss.or(a)):"and"===o.condition&&i.where(Ss.and(a))}}),t.search&&n.parse.parseJson(t.search).filter(function(o){return i.search(o.key,o.fields,o.operator,o.ignoreCase,o.ignoreAccent)}),t.aggregates&&t.aggregates.filter(function(o){return i.aggregate(o.type,o.field)}),t.sorted&&t.sorted.filter(function(o){return i.sortBy(o.name,o.direction)}),t.skip&&i.skip(t.skip),t.take&&i.take(t.take),t.group&&t.group.filter(function(o){return i.group(o)}),i},n.getPredicate=function(t){for(var e=[],i=0;i":"greaterthan","<=":"lessthanorequal",">=":"greaterthanorequal","==":"equal","!=":"notequal","*=":"contains","$=":"endswith","^=":"startswith"},n.odBiOperator={"<":" lt ",">":" gt ","<=":" le ",">=":" ge ","==":" eq ","!=":" ne ",lessthan:" lt ",lessthanorequal:" le ",greaterthan:" gt ",greaterthanorequal:" ge ",equal:" eq ",notequal:" ne "},n.odUniOperator={"$=":"endswith","^=":"startswith","*=":"substringof",endswith:"endswith",startswith:"startswith",contains:"substringof",doesnotendwith:"not endswith",doesnotstartwith:"not startswith",doesnotcontain:"not substringof",wildcard:"wildcard",like:"like"},n.odv4UniOperator={"$=":"endswith","^=":"startswith","*=":"contains",endswith:"endswith",startswith:"startswith",contains:"contains",doesnotendwith:"not endswith",doesnotstartwith:"not startswith",doesnotcontain:"not contains",wildcard:"wildcard",like:"like"},n.diacritics={"\u24b6":"A",\uff21:"A",\u00c0:"A",\u00c1:"A",\u00c2:"A",\u1ea6:"A",\u1ea4:"A",\u1eaa:"A",\u1ea8:"A",\u00c3:"A",\u0100:"A",\u0102:"A",\u1eb0:"A",\u1eae:"A",\u1eb4:"A",\u1eb2:"A",\u0226:"A",\u01e0:"A",\u00c4:"A",\u01de:"A",\u1ea2:"A",\u00c5:"A",\u01fa:"A",\u01cd:"A",\u0200:"A",\u0202:"A",\u1ea0:"A",\u1eac:"A",\u1eb6:"A",\u1e00:"A",\u0104:"A",\u023a:"A",\u2c6f:"A",\ua732:"AA",\u00c6:"AE",\u01fc:"AE",\u01e2:"AE",\ua734:"AO",\ua736:"AU",\ua738:"AV",\ua73a:"AV",\ua73c:"AY","\u24b7":"B",\uff22:"B",\u1e02:"B",\u1e04:"B",\u1e06:"B",\u0243:"B",\u0182:"B",\u0181:"B","\u24b8":"C",\uff23:"C",\u0106:"C",\u0108:"C",\u010a:"C",\u010c:"C",\u00c7:"C",\u1e08:"C",\u0187:"C",\u023b:"C",\ua73e:"C","\u24b9":"D",\uff24:"D",\u1e0a:"D",\u010e:"D",\u1e0c:"D",\u1e10:"D",\u1e12:"D",\u1e0e:"D",\u0110:"D",\u018b:"D",\u018a:"D",\u0189:"D",\ua779:"D",\u01f1:"DZ",\u01c4:"DZ",\u01f2:"Dz",\u01c5:"Dz","\u24ba":"E",\uff25:"E",\u00c8:"E",\u00c9:"E",\u00ca:"E",\u1ec0:"E",\u1ebe:"E",\u1ec4:"E",\u1ec2:"E",\u1ebc:"E",\u0112:"E",\u1e14:"E",\u1e16:"E",\u0114:"E",\u0116:"E",\u00cb:"E",\u1eba:"E",\u011a:"E",\u0204:"E",\u0206:"E",\u1eb8:"E",\u1ec6:"E",\u0228:"E",\u1e1c:"E",\u0118:"E",\u1e18:"E",\u1e1a:"E",\u0190:"E",\u018e:"E","\u24bb":"F",\uff26:"F",\u1e1e:"F",\u0191:"F",\ua77b:"F","\u24bc":"G",\uff27:"G",\u01f4:"G",\u011c:"G",\u1e20:"G",\u011e:"G",\u0120:"G",\u01e6:"G",\u0122:"G",\u01e4:"G",\u0193:"G",\ua7a0:"G",\ua77d:"G",\ua77e:"G","\u24bd":"H",\uff28:"H",\u0124:"H",\u1e22:"H",\u1e26:"H",\u021e:"H",\u1e24:"H",\u1e28:"H",\u1e2a:"H",\u0126:"H",\u2c67:"H",\u2c75:"H",\ua78d:"H","\u24be":"I",\uff29:"I",\u00cc:"I",\u00cd:"I",\u00ce:"I",\u0128:"I",\u012a:"I",\u012c:"I",\u0130:"I",\u00cf:"I",\u1e2e:"I",\u1ec8:"I",\u01cf:"I",\u0208:"I",\u020a:"I",\u1eca:"I",\u012e:"I",\u1e2c:"I",\u0197:"I","\u24bf":"J",\uff2a:"J",\u0134:"J",\u0248:"J","\u24c0":"K",\uff2b:"K",\u1e30:"K",\u01e8:"K",\u1e32:"K",\u0136:"K",\u1e34:"K",\u0198:"K",\u2c69:"K",\ua740:"K",\ua742:"K",\ua744:"K",\ua7a2:"K","\u24c1":"L",\uff2c:"L",\u013f:"L",\u0139:"L",\u013d:"L",\u1e36:"L",\u1e38:"L",\u013b:"L",\u1e3c:"L",\u1e3a:"L",\u0141:"L",\u023d:"L",\u2c62:"L",\u2c60:"L",\ua748:"L",\ua746:"L",\ua780:"L",\u01c7:"LJ",\u01c8:"Lj","\u24c2":"M",\uff2d:"M",\u1e3e:"M",\u1e40:"M",\u1e42:"M",\u2c6e:"M",\u019c:"M","\u24c3":"N",\uff2e:"N",\u01f8:"N",\u0143:"N",\u00d1:"N",\u1e44:"N",\u0147:"N",\u1e46:"N",\u0145:"N",\u1e4a:"N",\u1e48:"N",\u0220:"N",\u019d:"N",\ua790:"N",\ua7a4:"N",\u01ca:"NJ",\u01cb:"Nj","\u24c4":"O",\uff2f:"O",\u00d2:"O",\u00d3:"O",\u00d4:"O",\u1ed2:"O",\u1ed0:"O",\u1ed6:"O",\u1ed4:"O",\u00d5:"O",\u1e4c:"O",\u022c:"O",\u1e4e:"O",\u014c:"O",\u1e50:"O",\u1e52:"O",\u014e:"O",\u022e:"O",\u0230:"O",\u00d6:"O",\u022a:"O",\u1ece:"O",\u0150:"O",\u01d1:"O",\u020c:"O",\u020e:"O",\u01a0:"O",\u1edc:"O",\u1eda:"O",\u1ee0:"O",\u1ede:"O",\u1ee2:"O",\u1ecc:"O",\u1ed8:"O",\u01ea:"O",\u01ec:"O",\u00d8:"O",\u01fe:"O",\u0186:"O",\u019f:"O",\ua74a:"O",\ua74c:"O",\u01a2:"OI",\ua74e:"OO",\u0222:"OU","\u24c5":"P",\uff30:"P",\u1e54:"P",\u1e56:"P",\u01a4:"P",\u2c63:"P",\ua750:"P",\ua752:"P",\ua754:"P","\u24c6":"Q",\uff31:"Q",\ua756:"Q",\ua758:"Q",\u024a:"Q","\u24c7":"R",\uff32:"R",\u0154:"R",\u1e58:"R",\u0158:"R",\u0210:"R",\u0212:"R",\u1e5a:"R",\u1e5c:"R",\u0156:"R",\u1e5e:"R",\u024c:"R",\u2c64:"R",\ua75a:"R",\ua7a6:"R",\ua782:"R","\u24c8":"S",\uff33:"S",\u1e9e:"S",\u015a:"S",\u1e64:"S",\u015c:"S",\u1e60:"S",\u0160:"S",\u1e66:"S",\u1e62:"S",\u1e68:"S",\u0218:"S",\u015e:"S",\u2c7e:"S",\ua7a8:"S",\ua784:"S","\u24c9":"T",\uff34:"T",\u1e6a:"T",\u0164:"T",\u1e6c:"T",\u021a:"T",\u0162:"T",\u1e70:"T",\u1e6e:"T",\u0166:"T",\u01ac:"T",\u01ae:"T",\u023e:"T",\ua786:"T",\ua728:"TZ","\u24ca":"U",\uff35:"U",\u00d9:"U",\u00da:"U",\u00db:"U",\u0168:"U",\u1e78:"U",\u016a:"U",\u1e7a:"U",\u016c:"U",\u00dc:"U",\u01db:"U",\u01d7:"U",\u01d5:"U",\u01d9:"U",\u1ee6:"U",\u016e:"U",\u0170:"U",\u01d3:"U",\u0214:"U",\u0216:"U",\u01af:"U",\u1eea:"U",\u1ee8:"U",\u1eee:"U",\u1eec:"U",\u1ef0:"U",\u1ee4:"U",\u1e72:"U",\u0172:"U",\u1e76:"U",\u1e74:"U",\u0244:"U","\u24cb":"V",\uff36:"V",\u1e7c:"V",\u1e7e:"V",\u01b2:"V",\ua75e:"V",\u0245:"V",\ua760:"VY","\u24cc":"W",\uff37:"W",\u1e80:"W",\u1e82:"W",\u0174:"W",\u1e86:"W",\u1e84:"W",\u1e88:"W",\u2c72:"W","\u24cd":"X",\uff38:"X",\u1e8a:"X",\u1e8c:"X","\u24ce":"Y",\uff39:"Y",\u1ef2:"Y",\u00dd:"Y",\u0176:"Y",\u1ef8:"Y",\u0232:"Y",\u1e8e:"Y",\u0178:"Y",\u1ef6:"Y",\u1ef4:"Y",\u01b3:"Y",\u024e:"Y",\u1efe:"Y","\u24cf":"Z",\uff3a:"Z",\u0179:"Z",\u1e90:"Z",\u017b:"Z",\u017d:"Z",\u1e92:"Z",\u1e94:"Z",\u01b5:"Z",\u0224:"Z",\u2c7f:"Z",\u2c6b:"Z",\ua762:"Z","\u24d0":"a",\uff41:"a",\u1e9a:"a",\u00e0:"a",\u00e1:"a",\u00e2:"a",\u1ea7:"a",\u1ea5:"a",\u1eab:"a",\u1ea9:"a",\u00e3:"a",\u0101:"a",\u0103:"a",\u1eb1:"a",\u1eaf:"a",\u1eb5:"a",\u1eb3:"a",\u0227:"a",\u01e1:"a",\u00e4:"a",\u01df:"a",\u1ea3:"a",\u00e5:"a",\u01fb:"a",\u01ce:"a",\u0201:"a",\u0203:"a",\u1ea1:"a",\u1ead:"a",\u1eb7:"a",\u1e01:"a",\u0105:"a",\u2c65:"a",\u0250:"a",\ua733:"aa",\u00e6:"ae",\u01fd:"ae",\u01e3:"ae",\ua735:"ao",\ua737:"au",\ua739:"av",\ua73b:"av",\ua73d:"ay","\u24d1":"b",\uff42:"b",\u1e03:"b",\u1e05:"b",\u1e07:"b",\u0180:"b",\u0183:"b",\u0253:"b","\u24d2":"c",\uff43:"c",\u0107:"c",\u0109:"c",\u010b:"c",\u010d:"c",\u00e7:"c",\u1e09:"c",\u0188:"c",\u023c:"c",\ua73f:"c",\u2184:"c","\u24d3":"d",\uff44:"d",\u1e0b:"d",\u010f:"d",\u1e0d:"d",\u1e11:"d",\u1e13:"d",\u1e0f:"d",\u0111:"d",\u018c:"d",\u0256:"d",\u0257:"d",\ua77a:"d",\u01f3:"dz",\u01c6:"dz","\u24d4":"e",\uff45:"e",\u00e8:"e",\u00e9:"e",\u00ea:"e",\u1ec1:"e",\u1ebf:"e",\u1ec5:"e",\u1ec3:"e",\u1ebd:"e",\u0113:"e",\u1e15:"e",\u1e17:"e",\u0115:"e",\u0117:"e",\u00eb:"e",\u1ebb:"e",\u011b:"e",\u0205:"e",\u0207:"e",\u1eb9:"e",\u1ec7:"e",\u0229:"e",\u1e1d:"e",\u0119:"e",\u1e19:"e",\u1e1b:"e",\u0247:"e",\u025b:"e",\u01dd:"e","\u24d5":"f",\uff46:"f",\u1e1f:"f",\u0192:"f",\ua77c:"f","\u24d6":"g",\uff47:"g",\u01f5:"g",\u011d:"g",\u1e21:"g",\u011f:"g",\u0121:"g",\u01e7:"g",\u0123:"g",\u01e5:"g",\u0260:"g",\ua7a1:"g",\u1d79:"g",\ua77f:"g","\u24d7":"h",\uff48:"h",\u0125:"h",\u1e23:"h",\u1e27:"h",\u021f:"h",\u1e25:"h",\u1e29:"h",\u1e2b:"h",\u1e96:"h",\u0127:"h",\u2c68:"h",\u2c76:"h",\u0265:"h",\u0195:"hv","\u24d8":"i",\uff49:"i",\u00ec:"i",\u00ed:"i",\u00ee:"i",\u0129:"i",\u012b:"i",\u012d:"i",\u00ef:"i",\u1e2f:"i",\u1ec9:"i",\u01d0:"i",\u0209:"i",\u020b:"i",\u1ecb:"i",\u012f:"i",\u1e2d:"i",\u0268:"i",\u0131:"i","\u24d9":"j",\uff4a:"j",\u0135:"j",\u01f0:"j",\u0249:"j","\u24da":"k",\uff4b:"k",\u1e31:"k",\u01e9:"k",\u1e33:"k",\u0137:"k",\u1e35:"k",\u0199:"k",\u2c6a:"k",\ua741:"k",\ua743:"k",\ua745:"k",\ua7a3:"k","\u24db":"l",\uff4c:"l",\u0140:"l",\u013a:"l",\u013e:"l",\u1e37:"l",\u1e39:"l",\u013c:"l",\u1e3d:"l",\u1e3b:"l",\u017f:"l",\u0142:"l",\u019a:"l",\u026b:"l",\u2c61:"l",\ua749:"l",\ua781:"l",\ua747:"l",\u01c9:"lj","\u24dc":"m",\uff4d:"m",\u1e3f:"m",\u1e41:"m",\u1e43:"m",\u0271:"m",\u026f:"m","\u24dd":"n",\uff4e:"n",\u01f9:"n",\u0144:"n",\u00f1:"n",\u1e45:"n",\u0148:"n",\u1e47:"n",\u0146:"n",\u1e4b:"n",\u1e49:"n",\u019e:"n",\u0272:"n",\u0149:"n",\ua791:"n",\ua7a5:"n",\u01cc:"nj","\u24de":"o",\uff4f:"o",\u00f2:"o",\u00f3:"o",\u00f4:"o",\u1ed3:"o",\u1ed1:"o",\u1ed7:"o",\u1ed5:"o",\u00f5:"o",\u1e4d:"o",\u022d:"o",\u1e4f:"o",\u014d:"o",\u1e51:"o",\u1e53:"o",\u014f:"o",\u022f:"o",\u0231:"o",\u00f6:"o",\u022b:"o",\u1ecf:"o",\u0151:"o",\u01d2:"o",\u020d:"o",\u020f:"o",\u01a1:"o",\u1edd:"o",\u1edb:"o",\u1ee1:"o",\u1edf:"o",\u1ee3:"o",\u1ecd:"o",\u1ed9:"o",\u01eb:"o",\u01ed:"o",\u00f8:"o",\u01ff:"o",\u0254:"o",\ua74b:"o",\ua74d:"o",\u0275:"o",\u01a3:"oi",\u0223:"ou",\ua74f:"oo","\u24df":"p",\uff50:"p",\u1e55:"p",\u1e57:"p",\u01a5:"p",\u1d7d:"p",\ua751:"p",\ua753:"p",\ua755:"p","\u24e0":"q",\uff51:"q",\u024b:"q",\ua757:"q",\ua759:"q","\u24e1":"r",\uff52:"r",\u0155:"r",\u1e59:"r",\u0159:"r",\u0211:"r",\u0213:"r",\u1e5b:"r",\u1e5d:"r",\u0157:"r",\u1e5f:"r",\u024d:"r",\u027d:"r",\ua75b:"r",\ua7a7:"r",\ua783:"r","\u24e2":"s",\uff53:"s",\u00df:"s",\u015b:"s",\u1e65:"s",\u015d:"s",\u1e61:"s",\u0161:"s",\u1e67:"s",\u1e63:"s",\u1e69:"s",\u0219:"s",\u015f:"s",\u023f:"s",\ua7a9:"s",\ua785:"s",\u1e9b:"s","\u24e3":"t",\uff54:"t",\u1e6b:"t",\u1e97:"t",\u0165:"t",\u1e6d:"t",\u021b:"t",\u0163:"t",\u1e71:"t",\u1e6f:"t",\u0167:"t",\u01ad:"t",\u0288:"t",\u2c66:"t",\ua787:"t",\ua729:"tz","\u24e4":"u",\uff55:"u",\u00f9:"u",\u00fa:"u",\u00fb:"u",\u0169:"u",\u1e79:"u",\u016b:"u",\u1e7b:"u",\u016d:"u",\u00fc:"u",\u01dc:"u",\u01d8:"u",\u01d6:"u",\u01da:"u",\u1ee7:"u",\u016f:"u",\u0171:"u",\u01d4:"u",\u0215:"u",\u0217:"u",\u01b0:"u",\u1eeb:"u",\u1ee9:"u",\u1eef:"u",\u1eed:"u",\u1ef1:"u",\u1ee5:"u",\u1e73:"u",\u0173:"u",\u1e77:"u",\u1e75:"u",\u0289:"u","\u24e5":"v",\uff56:"v",\u1e7d:"v",\u1e7f:"v",\u028b:"v",\ua75f:"v",\u028c:"v",\ua761:"vy","\u24e6":"w",\uff57:"w",\u1e81:"w",\u1e83:"w",\u0175:"w",\u1e87:"w",\u1e85:"w",\u1e98:"w",\u1e89:"w",\u2c73:"w","\u24e7":"x",\uff58:"x",\u1e8b:"x",\u1e8d:"x","\u24e8":"y",\uff59:"y",\u1ef3:"y",\u00fd:"y",\u0177:"y",\u1ef9:"y",\u0233:"y",\u1e8f:"y",\u00ff:"y",\u1ef7:"y",\u1e99:"y",\u1ef5:"y",\u01b4:"y",\u024f:"y",\u1eff:"y","\u24e9":"z",\uff5a:"z",\u017a:"z",\u1e91:"z",\u017c:"z",\u017e:"z",\u1e93:"z",\u1e95:"z",\u01b6:"z",\u0225:"z",\u0240:"z",\u2c6c:"z",\ua763:"z",\u0386:"\u0391",\u0388:"\u0395",\u0389:"\u0397",\u038a:"\u0399",\u03aa:"\u0399",\u038c:"\u039f",\u038e:"\u03a5",\u03ab:"\u03a5",\u038f:"\u03a9",\u03ac:"\u03b1",\u03ad:"\u03b5",\u03ae:"\u03b7",\u03af:"\u03b9",\u03ca:"\u03b9",\u0390:"\u03b9",\u03cc:"\u03bf",\u03cd:"\u03c5",\u03cb:"\u03c5",\u03b0:"\u03c5",\u03c9:"\u03c9",\u03c2:"\u03c3"},n.fnOperators={equal:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?n.toLowerCase(t)===n.toLowerCase(e):t===e},notequal:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),!n.fnOperators.equal(t,e,i)},lessthan:function(t,e,i){return i?n.toLowerCase(t)n.toLowerCase(e):t>e},lessthanorequal:function(t,e,i){return i?n.toLowerCase(t)<=n.toLowerCase(e):(m(t)&&(t=void 0),t<=e)},greaterthanorequal:function(t,e,i){return i?n.toLowerCase(t)>=n.toLowerCase(e):t>=e},contains:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?!m(t)&&!m(e)&&-1!==n.toLowerCase(t).indexOf(n.toLowerCase(e)):!m(t)&&!m(e)&&-1!==t.toString().indexOf(e)},doesnotcontain:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?!m(t)&&!m(e)&&-1===n.toLowerCase(t).indexOf(n.toLowerCase(e)):!m(t)&&!m(e)&&-1===t.toString().indexOf(e)},isnotnull:function(t){return null!=t},isnull:function(t){return null==t},startswith:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.startsWith(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.startsWith(t,e)},doesnotstartwith:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.notStartsWith(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.notStartsWith(t,e)},like:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.like(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.like(t,e)},isempty:function(t){return void 0===t||""===t},isnotempty:function(t){return void 0!==t&&""!==t},wildcard:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?(t||"boolean"==typeof t)&&e&&"object"!=typeof t&&n.wildCard(n.toLowerCase(t),n.toLowerCase(e)):(t||"boolean"==typeof t)&&e&&n.wildCard(t,e)},endswith:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.endsWith(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.endsWith(t,e)},doesnotendwith:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.notEndsWith(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.notEndsWith(t,e)},processSymbols:function(t){var e=n.operatorSymbols[t];return e?n.fnOperators[e]:n.throwError("Query - Process Operator : Invalid operator")},processOperator:function(t){return n.fnOperators[t]||n.fnOperators.processSymbols(t)}},n.parse={parseJson:function(t){return"string"!=typeof t||!/^[\s]*\[|^[\s]*\{(.)+:/g.test(t)&&-1!==t.indexOf('"')?t instanceof Array?n.parse.iterateAndReviveArray(t):"object"==typeof t&&null!==t&&n.parse.iterateAndReviveJson(t):t=JSON.parse(t,n.parse.jsonReviver),t},iterateAndReviveArray:function(t){for(var e=0;e-1||e.indexOf("z")>-1,o=e.split(/[^0-9.]/);if(s){if(o[5].indexOf(".")>-1){var a=o[5].split(".");o[5]=a[0],o[6]=new Date(e).getUTCMilliseconds().toString()}else o[6]="00";e=n.dateParse.toTimeZone(new Date(parseInt(o[0],10),parseInt(o[1],10)-1,parseInt(o[2],10),parseInt(o[3],10),parseInt(o[4],10),parseInt(o[5]?o[5]:"00",10),parseInt(o[6],10)),n.serverTimezoneOffset,!1)}else{var l=new Date(parseInt(o[0],10),parseInt(o[1],10)-1,parseInt(o[2],10),parseInt(o[3],10),parseInt(o[4],10),parseInt(o[5]?o[5]:"00",10)),h=parseInt(o[6],10),c=parseInt(o[7],10);if(isNaN(h)&&isNaN(c))return l;e.indexOf("+")>-1?l.setHours(l.getHours()-h,l.getMinutes()-c):l.setHours(l.getHours()+h,l.getMinutes()+c),e=n.dateParse.toTimeZone(l,n.serverTimezoneOffset,!1)}null==n.serverTimezoneOffset&&(e=n.dateParse.addSelfOffset(e))}}return e},isJson:function(t){return"string"==typeof t[0]?t:n.parse.parseJson(t)},isGuid:function(t){return null!=/[A-Fa-f0-9]{8}(?:-[A-Fa-f0-9]{4}){3}-[A-Fa-f0-9]{12}/i.exec(t)},replacer:function(t,e){return n.isPlainObject(t)?n.parse.jsonReplacer(t,e):t instanceof Array?n.parse.arrayReplacer(t):t instanceof Date?n.parse.jsonReplacer({val:t},e).val:t},jsonReplacer:function(t,e){for(var i,s=0,o=Object.keys(t);s=0?"+":"-",s=function(a){var l=Math.floor(Math.abs(a));return(l<10?"0":"")+l};return e.getFullYear()+"-"+s(e.getMonth()+1)+"-"+s(e.getDate())+"T"+s(e.getHours())+":"+s(e.getMinutes())+":"+s(e.getSeconds())+r+s(i/60)+":"+s(i%60)}},n}(),wl=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),BK={GroupGuid:"{271bbba0-1ee7}"},a5=function(){function n(t){this.options={from:"table",requestType:"json",sortBy:"sorted",select:"select",skip:"skip",group:"group",take:"take",search:"search",count:"requiresCounts",where:"where",aggregates:"aggregates",expand:"expand"},this.type=n,this.dataSource=t,this.pvt={}}return n.prototype.processResponse=function(t,e,i,r){return t},n}(),XE=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return wl(t,n),t.prototype.processQuery=function(e,i){for(var a,l,f,r=e.dataSource.json.slice(0),s=r.length,o=!0,h={},c=0,d=[],u=[],p=0;p1?e.sort.filter(function(f){return f.fieldName===c})[0]:e.sort[0];s=this.onSortBy(s,d,e.query,!0)}e.page&&(s=this.onPage(s,e.page,e.query)),this.formGroupResult(s,h)}else{for(var o=e.lazyLoad.onDemandGroupInfo,a=o.where.length-1;a>=0;a--)s=this.onWhere(s,o.where[a]);if(e.group.length!==o.level)s=le.group(s,e.group[o.level].fieldName,r,null,null,e.group[o.level].comparer,!0),e.sort.length&&(s=this.onSortBy(s,e.sort[parseInt(o.level.toString(),10)],e.query,!0));else for(a=e.sort.length-1;a>=o.level;a--)s=this.onSortBy(s,e.sort[parseInt(a.toString(),10)],e.query,!1);i=s.length,h=s,s=(s=s.slice(o.skip)).slice(0,o.take),e.group.length!==o.level&&this.formGroupResult(s,h)}return{result:s,count:i}},t.prototype.formGroupResult=function(e,i){if(e.length&&i.length){var r="GroupGuid",s="childLevels",o="level",a="records";e[r]=i[r],e[s]=i[s],e[o]=i[o],e[a]=i[a]}return e},t.prototype.getAggregate=function(e){var i=_t.filterQueries(e.queries,"onAggregates"),r=[];if(i.length)for(var s=void 0,o=0;o=0;l--)a[l]&&(o=i.comparer,le.endsWith(a[l]," desc")&&(o=le.fnSort("descending"),a[l]=a[l].replace(" desc","")),e=le.sort(e,a[l],o));return e}return le.sort(e,s?"key":a,i.comparer)},t.prototype.onGroup=function(e,i,r){if(!e||!e.length)return e;var s=this.getAggregate(r);return le.group(e,le.getValue(i.fieldName,r),s,null,null,i.comparer)},t.prototype.onPage=function(e,i,r){var s=le.getValue(i.pageSize,r),o=(le.getValue(i.pageIndex,r)-1)*s;return e&&e.length?e.slice(o,o+s):e},t.prototype.onRange=function(e,i){return e&&e.length?e.slice(le.getValue(i.start),le.getValue(i.end)):e},t.prototype.onTake=function(e,i){return e&&e.length?e.slice(0,le.getValue(i.nos)):e},t.prototype.onSkip=function(e,i){return e&&e.length?e.slice(le.getValue(i.nos)):e},t.prototype.onSelect=function(e,i){return e&&e.length?le.select(e,le.getValue(i.fieldNames)):e},t.prototype.insert=function(e,i,r,s,o){return m(o)?e.dataSource.json.push(i):e.dataSource.json.splice(o,0,i)},t.prototype.remove=function(e,i,r,s){var a,o=e.dataSource.json;for("object"==typeof r&&!(r instanceof Date)&&(r=le.getObject(i,r)),a=0;a1&&(g="("+g+")"),f.filters.push(g);for(var y=0,S="object"==typeof f.filters[p]?Object.keys(f.filters[p]):[];y-1&&this.formRemoteGroupedData(e[s].items,i+1,r-1);var o="GroupGuid",h="records";return e[o]=BK[o],e.level=i,e.childLevels=r,e[h]=e[0].items.length?this.getGroupedRecords(e,!m(e[0].items[h])):[],e},t.prototype.getGroupedRecords=function(e,i){for(var r=[],o=0;ol.length-3?(l=l.substring(0,l.length-1),o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.endswith:le.odv4UniOperator.endswith):l.lastIndexOf("%")!==l.indexOf("%")&&l.lastIndexOf("%")>l.indexOf("%")+1?(l=l.substring(l.indexOf("%")+1,l.lastIndexOf("%")),o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains):o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains),l="'"+(l=encodeURIComponent(l))+"'";else if("wildcard"===o)if(-1!==l.indexOf("*")){var d=l.split("*"),u=void 0,f=0;if(0!==l.indexOf("*")&&-1===d[0].indexOf("%3f")&&-1===d[0].indexOf("?")&&(u="'"+(u=d[0])+"'",s+=(o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.startswith:le.odv4UniOperator.startswith)+"(",s+=c+",",a&&(s+=a),s+=u+")",f++),l.lastIndexOf("*")!==l.length-1&&-1===d[d.length-1].indexOf("%3f")&&-1===d[d.length-1].indexOf("?")&&(u="'"+(u=d[d.length-1])+"'",f>0&&(s+=" and "),s+=(o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.endswith:le.odv4UniOperator.endswith)+"(",s+=c+",",a&&(s+=a),s+=u+")",f++),d.length>2)for(var p=1;p0&&(s+=" and "),"substringof"===(o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains)||"not substringof"===o){var g=u;u=c,c=g}s+=o+"(",s+=c+",",a&&(s+=a),s+=u+")",f++}0===f?(o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains,(-1!==l.indexOf("?")||-1!==l.indexOf("%3f"))&&(l=-1!==l.indexOf("?")?l.split("?").join(""):l.split("%3f").join("")),l="'"+l+"'"):o="wildcard"}else o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains,(-1!==l.indexOf("?")||-1!==l.indexOf("%3f"))&&(l=-1!==l.indexOf("?")?l.split("?").join(""):l.split("%3f").join("")),l="'"+l+"'";return"substringof"!==o&&"not substringof"!==o||(g=l,l=c,c=g),"wildcard"!==o&&(s+=o+"(",s+=c+",",a&&(s+=a),s+=l+")"),s},t.prototype.addParams=function(e){n.prototype.addParams.call(this,e),delete e.reqParams.params},t.prototype.onComplexPredicate=function(e,i,r){for(var s=[],o=0;o-1;f--)!/\bContent-ID:/i.test(c[f])||!/\bHTTP.+201/.test(c[f])||(l=parseInt(/\bContent-ID: (\d+)/i.exec(c[f])[1],10),o.addedRecords[l]&&(h=le.parse.parseJson(/^\{.+\}/m.exec(c[f])[0]),ze({},o.addedRecords[l],this.processResponse(h))));return o}return null},t.prototype.compareAndRemove=function(e,i,r){var s=this;return m(i)||Object.keys(e).forEach(function(o){o!==r&&"@odata.etag"!==o&&(le.isPlainObject(e[o])?(s.compareAndRemove(e[o],i[o]),0===Object.keys(e[o]).filter(function(l){return"@odata.etag"!==l}).length&&delete e[o]):(e[o]===i[o]||e[o]&&i[o]&&e[o].valueOf()===i[o].valueOf())&&delete e[o])}),e},t}(gc),FK=function(n){function t(){var e=n.call(this)||this;return yt("beforeSend",gc.prototype.beforeSend,e),e}return wl(t,n),t.prototype.insert=function(e,i,r,s,o){return this.pvt.position=o,this.updateType="add",{url:e.dataSource.insertUrl||e.dataSource.crudUrl||e.dataSource.url,data:JSON.stringify(ze({},{value:i,table:r,action:"insert"},le.getAddParams(this,e,s)))}},t.prototype.remove=function(e,i,r,s,o){return n.prototype.remove.call(this,e,i,r),{type:"POST",url:e.dataSource.removeUrl||e.dataSource.crudUrl||e.dataSource.url,data:JSON.stringify(ze({},{key:r,keyColumn:i,table:s,action:"remove"},le.getAddParams(this,e,o)))}},t.prototype.update=function(e,i,r,s,o){return this.updateType="update",this.updateKey=i,{type:"POST",url:e.dataSource.updateUrl||e.dataSource.crudUrl||e.dataSource.url,data:JSON.stringify(ze({},{value:r,action:"update",keyColumn:i,key:r[i],table:s},le.getAddParams(this,e,o)))}},t.prototype.processResponse=function(e,i,r,s,o,a,l){var h;if(e="batch"===(o?JSON.parse(o.data):e).action?le.parse.parseJson(e):e,"add"===this.updateType&&n.prototype.insert.call(this,i,e,null,null,this.pvt.position),"update"===this.updateType&&n.prototype.update.call(this,i,this.updateKey,e),this.updateType=void 0,e.added)for(h=0;hi&&h.push(c)}for(c=0;cthis.pageSize;)h.results.splice(0,1),h.keys.splice(0,1);return window.localStorage.setItem(this.guidId,JSON.stringify(h)),e},t.prototype.beforeSend=function(e,i,r){!m(this.cacheAdaptor.options.batch)&&le.endsWith(r.url,this.cacheAdaptor.options.batch)&&"post"===r.type.toLowerCase()&&i.headers.set("Accept",this.cacheAdaptor.options.multipartAccept),e.dataSource.crossDomain||i.headers.set("Accept",this.cacheAdaptor.options.accept)},t.prototype.update=function(e,i,r,s){return this.isCrudAction=!0,this.cacheAdaptor.update(e,i,r,s)},t.prototype.insert=function(e,i,r){return this.isInsertAction=!0,this.cacheAdaptor.insert(e,i,r)},t.prototype.remove=function(e,i,r,s){return this.isCrudAction=!0,this.cacheAdaptor.remove(e,i,r,s)},t.prototype.batchRequest=function(e,i,r){return this.cacheAdaptor.batchRequest(e,i,r)},t}(gc),it=function(){function n(t,e,i){var s,r=this;return this.dateParse=!0,this.timeZoneHandling=!0,this.persistQuery={},this.isInitialLoad=!1,this.requests=[],this.isInitialLoad=!0,!t&&!this.dataSource&&(t=[]),i=i||t.adaptor,t&&!1===t.timeZoneHandling&&(this.timeZoneHandling=t.timeZoneHandling),t instanceof Array?s={json:t,offline:!0}:"object"==typeof t?(t.json||(t.json=[]),t.enablePersistence||(t.enablePersistence=!1),t.id||(t.id=""),t.ignoreOnPersist||(t.ignoreOnPersist=[]),s={url:t.url,insertUrl:t.insertUrl,removeUrl:t.removeUrl,updateUrl:t.updateUrl,crudUrl:t.crudUrl,batchUrl:t.batchUrl,json:t.json,headers:t.headers,accept:t.accept,data:t.data,timeTillExpiration:t.timeTillExpiration,cachingPageSize:t.cachingPageSize,enableCaching:t.enableCaching,requestType:t.requestType,key:t.key,crossDomain:t.crossDomain,jsonp:t.jsonp,dataType:t.dataType,offline:void 0!==t.offline?t.offline:!(t.adaptor instanceof FK||t.adaptor instanceof _K||t.url),requiresFormat:t.requiresFormat,enablePersistence:t.enablePersistence,id:t.id,ignoreOnPersist:t.ignoreOnPersist}):le.throwError("DataManager: Invalid arguments"),void 0===s.requiresFormat&&!le.isCors()&&(s.requiresFormat=!!m(s.crossDomain)||s.crossDomain),void 0===s.dataType&&(s.dataType="json"),this.dataSource=s,this.defaultQuery=e,this.dataSource.enablePersistence&&this.dataSource.id&&window.addEventListener("unload",this.setPersistData.bind(this)),s.url&&s.offline&&!s.json.length?(this.isDataAvailable=!1,this.adaptor=i||new mf,this.dataSource.offline=!1,this.ready=this.executeQuery(e||new _t),this.ready.then(function(o){r.dataSource.offline=!0,r.isDataAvailable=!0,s.json=o.result,r.adaptor=new XE})):this.adaptor=s.offline?new XE:new mf,!s.jsonp&&this.adaptor instanceof mf&&(s.jsonp="callback"),this.adaptor=i||this.adaptor,s.enableCaching&&(this.adaptor=new UK(this.adaptor,s.timeTillExpiration,s.cachingPageSize)),this}return Object.defineProperty(n.prototype,"moduleName",{get:function(){return"datamanager"},enumerable:!0,configurable:!0}),n.prototype.getPersistedData=function(t){var e=localStorage.getItem(t||this.dataSource.id);return JSON.parse(e)},n.prototype.setPersistData=function(t,e,i){localStorage.setItem(e||this.dataSource.id,JSON.stringify(i||this.persistQuery))},n.prototype.setPersistQuery=function(t){var e=this,i=this.getPersistedData();if(this.isInitialLoad&&i&&Object.keys(i).length){this.persistQuery=i,this.persistQuery.queries=this.persistQuery.queries.filter(function(s){if(e.dataSource.ignoreOnPersist&&e.dataSource.ignoreOnPersist.length&&s.fn&&e.dataSource.ignoreOnPersist.some(function(l){return s.fn===l}))return!1;if("onWhere"===s.fn){var o=s.e;if(o&&o.isComplex&&o.predicates instanceof Array){var a=o.predicates.map(function(l){if(l.predicates&&l.predicates instanceof Array){var h=l.predicates.map(function(v){return new Ss(v.field,v.operator,v.value,v.ignoreCase,v.ignoreAccent,v.matchCase)});return"and"===l.condition?Ss.and(h):Ss.or(h)}return new Ss(l.field,l.operator,l.value,l.ignoreCase,l.ignoreAccent,l.matchCase)});s.e=new Ss(a[0],o.condition,a.slice(1))}}return!0});var r=ze(new _t,this.persistQuery);return this.isInitialLoad=!1,r}return this.persistQuery=t,this.isInitialLoad=!1,t},n.prototype.setDefaultQuery=function(t){return this.defaultQuery=t,this},n.prototype.executeLocal=function(t){!this.defaultQuery&&!(t instanceof _t)&&le.throwError("DataManager - executeLocal() : A query is required to execute"),this.dataSource.json||le.throwError("DataManager - executeLocal() : Json data is required to execute"),this.dataSource.enablePersistence&&this.dataSource.id&&(t=this.setPersistQuery(t));var e=this.adaptor.processQuery(this,t=t||this.defaultQuery);if(t.subQuery){var i=t.subQuery.fromTable,r=t.subQuery.lookups,s=t.isCountRequired?e.result:e;r&&r instanceof Array&&le.buildHierarchy(t.subQuery.fKey,i,s,r,t.subQuery.key);for(var o=0;oli");z.classList.remove("json-parent");for(var j=0;j',W=ve.children[0].placeholder}return W}function Q(k,W,ve){!m(ve)&&""!==ve&&K(W,ve.split(" ")),!m(k)&&""!==k&&V(W,k.split(" "))}function oe(k,W,ve){if("multiselect"===ve||function Mo(k){if(!k)return!1;for(var W=k;W&&W!==document.body;){if("none"===window.getComputedStyle(W).display)return!1;W=W.parentElement}return!0}(k)){var Te="multiselect"===ve?k:k.clientWidth-parseInt(getComputedStyle(k,null).getPropertyValue("padding-left"),10);!m(W)&&!m(W.getElementsByClassName("e-float-text-content")[0])&&(W.getElementsByClassName("e-float-text-content")[0].classList.contains("e-float-text-overflow")&&W.getElementsByClassName("e-float-text-content")[0].classList.remove("e-float-text-overflow"),(Te0)for(var Ye=0;Ye<_e.length;Ye++)_e[parseInt(Ye.toString(),10)].addEventListener("mousedown",wo,!1),_e[parseInt(Ye.toString(),10)].addEventListener("mouseup",Ul,!1);else if(_e.length>0)for(Ye=0;Ye<_e.length;Ye++)_e[parseInt(Ye.toString(),10)].removeEventListener("mousedown",wo,this),_e[parseInt(Ye.toString(),10)].removeEventListener("mouseup",Ul,this)}function wo(){for(var W=this.parentElement;!W.classList.contains("e-input-group");)W=W.parentElement;!function Sa(k,W){!k.classList.contains("e-disabled")&&!k.querySelector("input").readOnly&&W.classList.add("e-input-btn-ripple")}(W,this)}function Ul(){var k=this;setTimeout(function(){k.classList.remove("e-input-btn-ripple")},500)}function Sb(k,W){var ve=W("span",{className:k});return ve.classList.add("e-input-group-icon"),ve}function I_(k,W,ve,Te){var _e=m(Te)?Si:Te,Ye=Sb(k,_e);W.classList.add("e-float-icon-left");var vi=W.querySelector(".e-input-in-wrap");if(m(vi)){vi=_e("span",{className:"e-input-in-wrap"}),ve.parentNode.insertBefore(vi,ve);var Gs=W.querySelectorAll(ve.tagName+" ~ *");vi.appendChild(ve);for(var ts=0;ts-1)if("class"===_e){var Ye=this.getInputValidClassList(k[""+_e]);""!==Ye&&V([W],Ye.split(" "))}else if("style"===_e){var vi=W.getAttribute(_e);vi=m(vi)?k[""+_e]:vi+k[""+_e],W.setAttribute(_e,vi)}else W.setAttribute(_e,k[""+_e])}},n.isBlank=function Hle(k){return!k||/^\s*$/.test(k)}}(Le||(Le={})),new RegExp("^(-)?(\\d*)$"),new RegExp("^[A-Za-z0-9._%+-]{1,}@[A-Za-z0-9._%+-]{1,}([.]{1}[a-zA-Z0-9]{2,}|[.]{1}[a-zA-Z0-9]{2,4}[.]{1}[a-zA-Z0-9]{2,4})$"),new RegExp("^([0-9]{4})-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])$"),new RegExp("^[0-9]*$"),new RegExp("^[+]?[0-9]{9,13}$"),new RegExp("^\\d{13,16}$");var me=function(){function n(t,e){this.width=t,this.height=e}return n.prototype.isEmpty=function(){return 0===this.height&&0===this.width},n.prototype.clone=function(){return new n(this.width,this.height)},n}(),Rie=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),KB=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},R=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Rie(t,n),t.equals=function(e,i){return e===i||!(!e||!i)&&(!e||!i||e.x===i.x&&e.y===i.y)},t.isEmptyPoint=function(e){return!(e.x&&e.y)},t.transform=function(e,i,r){var s={x:0,y:0};return s.x=Math.round(100*(e.x+r*Math.cos(i*Math.PI/180)))/100,s.y=Math.round(100*(e.y+r*Math.sin(i*Math.PI/180)))/100,s},t.findLength=function(e,i){return Math.sqrt(Math.pow(e.x-i.x,2)+Math.pow(e.y-i.y,2))},t.findAngle=function(e,i){var r=Math.atan2(i.y-e.y,i.x-e.x);return r=180*r/Math.PI,(r%=360)<0&&(r+=360),r},t.distancePoints=function(e,i){return Math.sqrt(Math.pow(i.x-e.x,2)+Math.pow(i.y-e.y,2))},t.getLengthFromListOfPoints=function(e){for(var i=0,r=0;ri.y&&!r?o.y+=s:o.y-=s:e.y===i.y?e.xi.x&&!r?o.x+=s:o.x-=s:r?(a=this.findAngle(e,i),o=this.transform(e,a,s)):(a=this.findAngle(i,e),o=this.transform(i,a,s)),o},t.direction=function(e,i){return Math.abs(i.x-e.x)>Math.abs(i.y-e.y)?e.x0)for(var r=0;rt.right||this.top>t.bottom||this.bottom=t.right&&this.top<=t.top&&this.bottom>=t.bottom},n.prototype.containsPoint=function(t,e){return void 0===e&&(e=0),this.left-e<=t.x&&this.right+e>=t.x&&this.top-e<=t.y&&this.bottom+e>=t.y},n.toBounds=function(t){for(var e=new n,i=0,r=t;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},s3=function(n){if(n)switch(n.type){case"Linear":default:return CI;case"Radial":return Gie}return CI},Yie=function(){return function n(t,e,i,r){this.left=t,this.right=e,this.top=i,this.bottom=r}}(),Jn=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),rt([I(0)],t.prototype,"left",void 0),rt([I(0)],t.prototype,"right",void 0),rt([I(0)],t.prototype,"top",void 0),rt([I(0)],t.prototype,"bottom",void 0),t}(Ee),Qie=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),rt([I(45)],t.prototype,"angle",void 0),rt([I(5)],t.prototype,"distance",void 0),rt([I(.7)],t.prototype,"opacity",void 0),rt([I("lightgrey")],t.prototype,"color",void 0),t}(Ee),o3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),t.prototype.getClassName=function(){return"Stop"},rt([I("")],t.prototype,"color",void 0),rt([I(0)],t.prototype,"offset",void 0),rt([I(1)],t.prototype,"opacity",void 0),t}(Ee),Cx=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),rt([Bt([],o3)],t.prototype,"stops",void 0),rt([I("None")],t.prototype,"type",void 0),rt([I("")],t.prototype,"id",void 0),t}(Ee),CI=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),rt([I(0)],t.prototype,"x1",void 0),rt([I(0)],t.prototype,"x2",void 0),rt([I(0)],t.prototype,"y1",void 0),rt([I(0)],t.prototype,"y2",void 0),t}(Cx),Gie=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),rt([I(0)],t.prototype,"cx",void 0),rt([I(0)],t.prototype,"cy",void 0),rt([I(0)],t.prototype,"fx",void 0),rt([I(0)],t.prototype,"fy",void 0),rt([I(50)],t.prototype,"r",void 0),t}(Cx),Nl=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),rt([I("white")],t.prototype,"fill",void 0),rt([I("black")],t.prototype,"strokeColor",void 0),rt([I("")],t.prototype,"strokeDashArray",void 0),rt([I(1)],t.prototype,"strokeWidth",void 0),rt([I(1)],t.prototype,"opacity",void 0),rt([A0(s3)],t.prototype,"gradient",void 0),t}(Ee),a3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),rt([I("transparent")],t.prototype,"fill",void 0),t}(Nl),qf=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),rt([I("black")],t.prototype,"color",void 0),rt([I("Arial")],t.prototype,"fontFamily",void 0),rt([I(12)],t.prototype,"fontSize",void 0),rt([I(!1)],t.prototype,"italic",void 0),rt([I(!1)],t.prototype,"bold",void 0),rt([I("CollapseSpace")],t.prototype,"whiteSpace",void 0),rt([I("WrapWithOverflow")],t.prototype,"textWrapping",void 0),rt([I("Center")],t.prototype,"textAlign",void 0),rt([I("None")],t.prototype,"textDecoration",void 0),rt([I("Wrap")],t.prototype,"textOverflow",void 0),rt([I("transparent")],t.prototype,"fill",void 0),t}(Nl),on=function(n){return n[n.Default=0]="Default",n[n.expandNode=2]="expandNode",n[n.interaction=4]="interaction",n[n.GroupingInProgress=8]="GroupingInProgress",n[n.GroupClipboardInProcess=16]="GroupClipboardInProcess",n[n.ClearObject=32]="ClearObject",n}(on||{}),ci=function(n){return n[n.Visible=1]="Visible",n[n.Hidden=2]="Hidden",n[n.Hover=4]="Hover",n[n.Connect=8]="Connect",n}(ci||{}),Kt=function(n){return n[n.None=0]="None",n[n.ShowHorizontalLines=1]="ShowHorizontalLines",n[n.ShowVerticalLines=2]="ShowVerticalLines",n[n.ShowLines=3]="ShowLines",n[n.SnapToHorizontalLines=4]="SnapToHorizontalLines",n[n.SnapToVerticalLines=8]="SnapToVerticalLines",n[n.SnapToLines=12]="SnapToLines",n[n.SnapToObject=16]="SnapToObject",n[n.All=31]="All",n}(Kt||{}),mr=function(n){return n[n.None=1]="None",n[n.ConnectorSourceThumb=2]="ConnectorSourceThumb",n[n.ConnectorTargetThumb=4]="ConnectorTargetThumb",n[n.ResizeSouthEast=8]="ResizeSouthEast",n[n.ResizeSouthWest=16]="ResizeSouthWest",n[n.ResizeNorthEast=32]="ResizeNorthEast",n[n.ResizeNorthWest=64]="ResizeNorthWest",n[n.ResizeEast=128]="ResizeEast",n[n.ResizeWest=256]="ResizeWest",n[n.ResizeSouth=512]="ResizeSouth",n[n.ResizeNorth=1024]="ResizeNorth",n[n.Rotate=2048]="Rotate",n[n.UserHandle=4096]="UserHandle",n[n.ToolTip=8192]="ToolTip",n[n.ResizeAll=2046]="ResizeAll",n[n.All=16382]="All",n}(mr||{}),qe=function(n){return n[n.None=1]="None",n[n.Select=2]="Select",n[n.Delete=4]="Delete",n[n.Drag=8]="Drag",n[n.DragSourceEnd=16]="DragSourceEnd",n[n.DragTargetEnd=32]="DragTargetEnd",n[n.DragSegmentThumb=64]="DragSegmentThumb",n[n.AllowDrop=128]="AllowDrop",n[n.Bridging=256]="Bridging",n[n.BridgeObstacle=512]="BridgeObstacle",n[n.InheritBridging=1024]="InheritBridging",n[n.PointerEvents=2048]="PointerEvents",n[n.Tooltip=4096]="Tooltip",n[n.InheritTooltip=8192]="InheritTooltip",n[n.Interaction=4218]="Interaction",n[n.ReadOnly=16384]="ReadOnly",n[n.LineRouting=32768]="LineRouting",n[n.InheritLineRouting=65536]="InheritLineRouting",n[n.ConnectToNearByNode=131072]="ConnectToNearByNode",n[n.ConnectToNearByPort=262144]="ConnectToNearByPort",n[n.ConnectToNearByElement=393216]="ConnectToNearByElement",n[n.InheritSegmentThumbShape=524288]="InheritSegmentThumbShape",n[n.InheritSegmentThumbSize=1048576]="InheritSegmentThumbSize",n[n.Default=2043454]="Default",n}(qe||{}),Nr=function(n){return n[n.ReadOnly=2]="ReadOnly",n[n.InheritReadOnly=4]="InheritReadOnly",n[n.Select=8]="Select",n[n.Drag=16]="Drag",n[n.Resize=32]="Resize",n[n.Rotate=64]="Rotate",n[n.Tooltip=128]="Tooltip",n[n.Interaction=120]="Interaction",n[n.None=0]="None",n}(Nr||{}),ie=function(n){return n[n.None=0]="None",n[n.Select=2]="Select",n[n.Drag=4]="Drag",n[n.Rotate=8]="Rotate",n[n.Shadow=16]="Shadow",n[n.PointerEvents=32]="PointerEvents",n[n.Delete=64]="Delete",n[n.InConnect=128]="InConnect",n[n.OutConnect=256]="OutConnect",n[n.Individual=512]="Individual",n[n.Expandable=1024]="Expandable",n[n.AllowDrop=2048]="AllowDrop",n[n.Inherit=78]="Inherit",n[n.ResizeNorthEast=4096]="ResizeNorthEast",n[n.ResizeEast=8192]="ResizeEast",n[n.ResizeSouthEast=16384]="ResizeSouthEast",n[n.ResizeSouth=32768]="ResizeSouth",n[n.ResizeSouthWest=65536]="ResizeSouthWest",n[n.ResizeWest=131072]="ResizeWest",n[n.ResizeNorthWest=262144]="ResizeNorthWest",n[n.ResizeNorth=524288]="ResizeNorth",n[n.Resize=1044480]="Resize",n[n.AspectRatio=1048576]="AspectRatio",n[n.Tooltip=2097152]="Tooltip",n[n.InheritTooltip=4194304]="InheritTooltip",n[n.ReadOnly=8388608]="ReadOnly",n[n.HideThumbs=16777216]="HideThumbs",n[n.AllowMovingOutsideLane=33554432]="AllowMovingOutsideLane",n[n.Default=5240814]="Default",n}(ie||{}),Xr=function(n){return n[n.None=0]="None",n[n.ElementIsPort=2]="ElementIsPort",n[n.ElementIsGroup=4]="ElementIsGroup",n[n.HorizontalLaneHeader=8]="HorizontalLaneHeader",n}(Xr||{}),bt=function(n){return n[n.Rotate=2]="Rotate",n[n.ConnectorSource=4]="ConnectorSource",n[n.ConnectorTarget=8]="ConnectorTarget",n[n.ResizeNorthEast=16]="ResizeNorthEast",n[n.ResizeEast=32]="ResizeEast",n[n.ResizeSouthEast=64]="ResizeSouthEast",n[n.ResizeSouth=128]="ResizeSouth",n[n.ResizeSouthWest=256]="ResizeSouthWest",n[n.ResizeWest=512]="ResizeWest",n[n.ResizeNorthWest=1024]="ResizeNorthWest",n[n.ResizeNorth=2048]="ResizeNorth",n[n.Default=4094]="Default",n}(bt||{}),nt=function(n){return n[n.None=1]="None",n[n.Bridging=2]="Bridging",n[n.UndoRedo=4]="UndoRedo",n[n.Tooltip=8]="Tooltip",n[n.UserInteraction=16]="UserInteraction",n[n.ApiUpdate=32]="ApiUpdate",n[n.PageEditable=48]="PageEditable",n[n.Zoom=64]="Zoom",n[n.PanX=128]="PanX",n[n.PanY=256]="PanY",n[n.Pan=384]="Pan",n[n.ZoomTextEdit=512]="ZoomTextEdit",n[n.Virtualization=1024]="Virtualization",n[n.LineRouting=2048]="LineRouting",n[n.Default=500]="Default",n}(nt||{}),ri=function(n){return n[n.None=0]="None",n[n.SingleSelect=1]="SingleSelect",n[n.MultipleSelect=2]="MultipleSelect",n[n.ZoomPan=4]="ZoomPan",n[n.DrawOnce=8]="DrawOnce",n[n.ContinuousDraw=16]="ContinuousDraw",n[n.Default=3]="Default",n}(ri||{}),Qa=function(n){return n[n.Self=1]="Self",n[n.Parent=2]="Parent",n}(Qa||{}),ft=function(n){return n[n.None=0]="None",n[n.Control=1]="Control",n[n.Meta=1]="Meta",n[n.Alt=2]="Alt",n[n.Shift=4]="Shift",n}(ft||{}),Mt=function(n){return n[n.None=null]="None",n[n.Number0=0]="Number0",n[n.Number1=1]="Number1",n[n.Number2=2]="Number2",n[n.Number3=3]="Number3",n[n.Number4=4]="Number4",n[n.Number5=5]="Number5",n[n.Number6=6]="Number6",n[n.Number7=7]="Number7",n[n.Number8=8]="Number8",n[n.Number9=9]="Number9",n[n.A=65]="A",n[n.B=66]="B",n[n.C=67]="C",n[n.D=68]="D",n[n.E=69]="E",n[n.F=70]="F",n[n.G=71]="G",n[n.H=72]="H",n[n.I=73]="I",n[n.J=74]="J",n[n.K=75]="K",n[n.L=76]="L",n[n.M=77]="M",n[n.N=78]="N",n[n.O=79]="O",n[n.P=80]="P",n[n.Q=81]="Q",n[n.R=82]="R",n[n.S=83]="S",n[n.T=84]="T",n[n.U=85]="U",n[n.V=86]="V",n[n.W=87]="W",n[n.X=88]="X",n[n.Y=89]="Y",n[n.Z=90]="Z",n[n.Left=37]="Left",n[n.Up=38]="Up",n[n.Right=39]="Right",n[n.Down=40]="Down",n[n.Escape=27]="Escape",n[n.Space=32]="Space",n[n.PageUp=33]="PageUp",n[n.PageDown=34]="PageDown",n[n.End=35]="End",n[n.Home=36]="Home",n[n.Delete=46]="Delete",n[n.Tab=9]="Tab",n[n.Enter=13]="Enter",n[n.BackSpace=8]="BackSpace",n[n.F1=112]="F1",n[n.F2=113]="F2",n[n.F3=114]="F3",n[n.F4=115]="F4",n[n.F5=116]="F5",n[n.F6=117]="F6",n[n.F7=118]="F7",n[n.F8=119]="F8",n[n.F9=120]="F9",n[n.F10=121]="F10",n[n.F11=122]="F11",n[n.F12=123]="F12",n[n.Star=56]="Star",n[n.Plus=187]="Plus",n[n.Minus=189]="Minus",n[n.BracketLeft=219]="BracketLeft",n[n.BracketRight=221]="BracketRight",n}(Mt||{}),ee=function(n){return n[n.Render=2]="Render",n[n.PublicMethod=4]="PublicMethod",n[n.ToolAction=8]="ToolAction",n[n.UndoRedo=16]="UndoRedo",n[n.TextEdit=32]="TextEdit",n[n.Group=64]="Group",n[n.Clear=128]="Clear",n[n.PreventClearSelection=256]="PreventClearSelection",n[n.Interactions=512]="Interactions",n[n.PreventHistory=1024]="PreventHistory",n[n.PreventIconsUpdate=2048]="PreventIconsUpdate",n[n.PreventCollectionChangeOnDragOver=4096]="PreventCollectionChangeOnDragOver",n[n.PreventZIndexOnDragging=8192]="PreventZIndexOnDragging",n[n.isGroupDragging=16384]="isGroupDragging",n[n.DragUsingMouse=32768]="DragUsingMouse",n[n.DecoratorPropertyChange=65536]="DecoratorPropertyChange",n[n.PreventLaneContainerUpdate=131072]="PreventLaneContainerUpdate",n}(ee||{}),Ga=function(n){return n[n.None=2]="None",n[n.DrawSelectorBorder=4]="DrawSelectorBorder",n[n.PreventRenderSelector=8]="PreventRenderSelector",n}(Ga||{}),$i=function(n){return n[n.None=0]="None",n[n.PreventDrag=2]="PreventDrag",n[n.PreventScale=4]="PreventScale",n[n.PreventDataInit=8]="PreventDataInit",n[n.hScrollbarMoved=16]="hScrollbarMoved",n[n.vScrollbarMoved=32]="vScrollbarMoved",n[n.AnimationClick=64]="AnimationClick",n[n.EnableGroupAction=128]="EnableGroupAction",n[n.PanInProgress=256]="PanInProgress",n[n.OverViewAction=512]="OverViewAction",n}($i||{}),da=function(n){return n[n.None=0]="None",n[n.PropertyChange=1024]="PropertyChange",n[n.Interaction=2048]="Interaction",n}(da||{}),Ae=function(n){return n[n.Zero=0]="Zero",n[n.One=1]="One",n[n.Two=2]="Two",n[n.Three=3]="Three",n[n.Four=4]="Four",n[n.Five=5]="Five",n}(Ae||{}),Ce=function(n){return n[n.collectionChange=0]="collectionChange",n[n.rotateChange=1]="rotateChange",n[n.positionChange=2]="positionChange",n[n.propertyChange=3]="propertyChange",n[n.selectionChange=4]="selectionChange",n[n.sizeChange=5]="sizeChange",n[n.drop=6]="drop",n[n.sourcePointChange=7]="sourcePointChange",n[n.targetPointChange=8]="targetPointChange",n[n.connectionChange=9]="connectionChange",n[n.animationComplete=10]="animationComplete",n[n.click=11]="click",n[n.doubleClick=12]="doubleClick",n[n.scrollChange=13]="scrollChange",n[n.dragEnter=14]="dragEnter",n[n.dragLeave=15]="dragLeave",n[n.dragOver=16]="dragOver",n[n.textEdit=17]="textEdit",n[n.paletteSelectionChange=18]="paletteSelectionChange",n[n.historyChange=19]="historyChange",n[n.mouseEnter=20]="mouseEnter",n[n.mouseLeave=21]="mouseLeave",n[n.mouseOver=22]="mouseOver",n[n.expandStateChange=23]="expandStateChange",n[n.segmentCollectionChange=24]="segmentCollectionChange",n[n.commandExecute=25]="commandExecute",n[n.historyStateChange=26]="historyStateChange",n[n.onUserHandleMouseDown=27]="onUserHandleMouseDown",n[n.onUserHandleMouseUp=28]="onUserHandleMouseUp",n[n.onUserHandleMouseEnter=29]="onUserHandleMouseEnter",n[n.onUserHandleMouseLeave=30]="onUserHandleMouseLeave",n[n.onImageLoad=31]="onImageLoad",n[n.onDoBindingInit=32]="onDoBindingInit",n[n.keyUp=33]="keyUp",n[n.keyDown=34]="keyDown",n[n.fixedUserHandleClick=35]="fixedUserHandleClick",n[n.elementDraw=36]="elementDraw",n[n.mouseWheel=37]="mouseWheel",n[n.segmentChange=38]="segmentChange",n[n.onFixedUserHandleMouseDown=39]="onFixedUserHandleMouseDown",n[n.onFixedUserHandleMouseUp=40]="onFixedUserHandleMouseUp",n[n.onFixedUserHandleMouseEnter=41]="onFixedUserHandleMouseEnter",n[n.onFixedUserHandleMouseLeave=42]="onFixedUserHandleMouseLeave",n[n.loaded=43]="loaded",n}(Ce||{}),oi=function(n){return n[n.None=1]="None",n[n.Drag=2]="Drag",n[n.Draw=4]="Draw",n[n.InConnect=8]="InConnect",n[n.OutConnect=16]="OutConnect",n[n.ToolTip=32]="ToolTip",n[n.InheritTooltip=64]="InheritTooltip",n[n.Default=24]="Default",n}(oi||{}),Ex=function(n){return n[n.None=1]="None",n[n.Source=2]="Source",n[n.Target=4]="Target",n[n.Intermediate=8]="Intermediate",n[n.All=14]="All",n}(Ex||{}),EI=function(n){return n[n.None=0]="None",n[n.SymmetricAngle=2]="SymmetricAngle",n[n.SymmetricDistance=4]="SymmetricDistance",n[n.Default=6]="Default",n}(EI||{}),hs=function(){function n(){this.pivot={x:.5,y:.5},this.isDirt=!0,this.isExport=!1,this.exportScaleValue={x:0,y:0},this.exportScaleOffset={x:0,y:0},this.canApplyStyle=!0,this.visible=!0,this.offsetX=0,this.offsetY=0,this.cornerRadius=0,this.minHeight=void 0,this.minWidth=void 0,this.maxWidth=void 0,this.maxHeight=void 0,this.width=void 0,this.height=void 0,this.rotateAngle=0,this.margin={left:0,right:0,top:0,bottom:0},this.connectionDirection="Auto",this.horizontalAlignment="Auto",this.verticalAlignment="Auto",this.flip="None",this.flipMode="All",this.relativeMode="Point",this.transform=Qa.Self|Qa.Parent,this.style={fill:"white",strokeColor:"black",opacity:1,strokeWidth:1},this.desiredSize=new me,this.actualSize=new me,this.parentTransform=0,this.preventContainer=!1,this.isSvgRender=!1,this.bounds=new Ne(0,0,0,0),this.shadow=null,this.description="",this.staticSize=!1,this.shapeType="",this.isRectElement=!1,this.isCalculateDesiredSize=!0,this.flipOffset={x:0,y:0},this.elementActions=Xr.None,this.inversedAlignment=!0,this.position=void 0,this.unitMode=void 0,this.float=!1,this.floatingBounds=void 0}return n.prototype.setOffsetWithRespectToBounds=function(t,e,i){this.unitMode=i,this.position={x:t,y:e}},n.prototype.getAbsolutePosition=function(t){if(void 0!==this.position)return"Absolute"===this.unitMode?this.position:{x:this.position.x*t.width,y:this.position.y*t.height}},Object.defineProperty(n.prototype,"outerBounds",{get:function(){return this.floatingBounds||this.bounds},set:function(t){this.floatingBounds=t},enumerable:!0,configurable:!0}),n.prototype.measure=function(t,e,i){var s=void 0!==this.height?this.height:(t.height||0)-this.margin.top-this.margin.bottom;return this.id&&0===s&&this.elementActions&Xr.HorizontalLaneHeader&&(s=this.actualSize.height),this.desiredSize=new me(void 0!==this.width?this.width:(t.width||0)-this.margin.left-this.margin.right,s),this.isCalculateDesiredSize&&(this.desiredSize=this.validateDesiredSize(this.desiredSize,t)),this.desiredSize},n.prototype.arrange=function(t){return this.actualSize=t,this.updateBounds(),this.actualSize},n.prototype.updateBounds=function(){this.bounds=yr(this)},n.prototype.validateDesiredSize=function(t,e){return this.isRectElement&&!this.width&&!this.minWidth&&!this.maxWidth&&(t.width=50),this.isRectElement&&!this.height&&!this.minHeight&&!this.maxHeight&&(t.height=50),(void 0===t||void 0!==this.width&&void 0!==this.height)&&((t=t||new me).width=void 0===this.width?(e.width||0)-this.margin.left-this.margin.right:this.width,t.height=void 0===this.height?(e.height||0)-this.margin.top-this.margin.bottom:this.height),void 0!==this.minWidth&&(t.width=Math.max(t.width,this.minWidth)),void 0!==this.minHeight&&(t.height=Math.max(t.height,this.minHeight)),void 0!==this.maxWidth&&0!==this.maxWidth&&(t.width=Math.min(t.width,this.maxWidth)),void 0!==this.maxHeight&&0!==this.maxHeight&&(t.height=Math.min(t.height,this.maxHeight)),t},n}(),ere=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Cs=function(n){function t(){var e=null!==n&&n.apply(this,arguments)||this;return e.padding=new Yie(0,0,0,0),e.desiredBounds=void 0,e.measureChildren=!0,e.prevRotateAngle=0,e}return ere(t,n),t.prototype.hasChildren=function(){return void 0!==this.children&&this.children.length>0},t.prototype.measure=function(e,i,r){this.desiredBounds=void 0;var o,a,s=void 0;if(this.hasChildren()){for(var l=0;l=n.width&&s.length>0)i[i.length]={text:s,x:0,dy:0,width:o},s="";else{(s+=a[r+1]||"").indexOf("\n")>-1&&(i[i.length]={text:s,x:0,dy:0,width:_c(s,n)},s="");var l=_c(s,n);Math.ceil(l)+2>=n.width&&s.length>0&&(i[i.length]={text:s,x:0,dy:0,width:l},s=""),r===a.length-1&&s.length>0&&(i[i.length]={text:s,x:0,dy:0,width:l},s="")}else i=function Soe(n,t,e){var c,d,u,f,i=[],r="",s=0,o=0,a="nowrap"!==n.whiteSpace,h=(t||n.content).split("\n");for(s=0;s0?" ":"")+c[parseInt(o.toString(),10)];var p=_c(d=c[o+1]?r+" "+c[o+1]:r,n);Math.floor(p)>(e||n.width)-2&&r.length>0?(i[i.length]={text:r,x:0,dy:0,width:d===r?p:r===f?u:_c(r,n)},r=""):o===c.length-1&&(i[i.length]={text:r,x:0,dy:0,width:p},r=""),f=d,u=p}return i}(n,t,e);else i[i.length]={text:a,x:0,dy:0,width:_c(a,n)};return i}(l,r,n.isLaneOrientation?i:void 0),n.wrapBounds=a=function Ioe(n,t){var r,s,e={x:0,width:0},i=0;for(i=0;in.width&&("Ellipsis"===n.textOverflow||"Clip"===n.textOverflow)?0:-r/2:"right"===n.textAlign?-r:t.length>1?0:-r/2,t[parseInt(i.toString(),10)].dy=1.2*n.fontSize,t[parseInt(i.toString(),10)].x=r,e.x=Math.min(e.x,r),e.width=Math.max(e.width,s);return e}(l,o),s.width=a.width,n.wrapBounds.width>=i&&"Wrap"!==l.textOverflow&&(s.width=i),s.height=o.length*n.style.fontSize*1.2,s}(this,0,0,this.isLaneOrientation?e.height:this.width||e.width):this.desiredSize,this.desiredSize=void 0===this.width||void 0===this.height?new me(i.width,i.height):new me(this.width,this.height),this.desiredSize=this.validateDesiredSize(this.desiredSize,e),this.desiredSize},t.prototype.arrange=function(e){return(e.width!==this.actualSize.width||e.height!==this.actualSize.height||this.isDirt)&&(this.doWrap=!0),this.actualSize=e,this.updateBounds(),this.isDirt=!1,this.actualSize},t}(hs),ire=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Mi=function(n){function t(){var e=null!==n&&n.apply(this,arguments)||this;return e.measureChildren=void 0,e}return ire(t,n),t.prototype.measure=function(e,i,r){var s=void 0,o=void 0;if(this.hasChildren()){for(var a=0,l=this.children;a=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Td=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return are(t,n),Ph([I("")],t.prototype,"content",void 0),Ph([I("TopLeft")],t.prototype,"position",void 0),Ph([I("Mouse")],t.prototype,"relativeMode",void 0),Ph([I(!0)],t.prototype,"showTipPointer",void 0),Ph([I("auto")],t.prototype,"width",void 0),Ph([I("auto")],t.prototype,"height",void 0),Ph([I("Auto")],t.prototype,"openOn",void 0),Ph([I()],t.prototype,"animation",void 0),Ph([I(!1)],t.prototype,"isSticky",void 0),t}(Ee);function l3(n){var t=new wh;t=h3(n.tooltip,t);var e=new wh(t);return e.beforeCollision=hre,e.beforeOpen=lre,e.cssClass="e-diagram-tooltip",e.opensOn="custom",e.appendTo("#"+n.element.id),e.close(),e}function lre(n){(""===this.content||void 0===this.content)&&(n.element.style.display="none")}function hre(n){n.collidedPosition&&n.collidedPosition!==this.position&&(n.element.style.display="none")}function Dx(n,t){var e=n.tooltipObject;return h3(t?t.tooltip:n.tooltip,e),e}function h3(n,t){return n.content?(t.content=n.content,"string"==typeof n.content&&(t.content=ko(function(){return n.content})),t.position=n.position,t.showTipPointer=n.showTipPointer,t.width=n.width,t.height=n.height,t.animation=n.animation?n.animation:{close:{effect:"None"}}):t.close(),t}var xx=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Bn=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Tx=function(n){function t(e,i,r,s){var o=n.call(this,e,i,r,s)||this;return o.inEdges=[],o.outEdges=[],o}return xx(t,n),Bn([I("")],t.prototype,"id",void 0),Bn([I("Center")],t.prototype,"horizontalAlignment",void 0),Bn([I("Center")],t.prototype,"verticalAlignment",void 0),Bn([re({},Jn)],t.prototype,"margin",void 0),Bn([I(12)],t.prototype,"width",void 0),Bn([I(12)],t.prototype,"height",void 0),Bn([re({},Nl)],t.prototype,"style",void 0),Bn([I("Square")],t.prototype,"shape",void 0),Bn([I("Auto")],t.prototype,"connectionDirection",void 0),Bn([I(ci.Connect)],t.prototype,"visibility",void 0),Bn([I("")],t.prototype,"pathData",void 0),Bn([I(oi.Default)],t.prototype,"constraints",void 0),Bn([I()],t.prototype,"addInfo",void 0),Bn([I()],t.prototype,"outEdges",void 0),Bn([I()],t.prototype,"inEdges",void 0),Bn([re({},Td)],t.prototype,"tooltip",void 0),t}(Ee),Es=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return xx(t,n),t.prototype.getClassName=function(){return"PointPort"},Bn([re({x:.5,y:.5},R)],t.prototype,"offset",void 0),t}(Tx),Lc=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return xx(t,n),t.prototype.getClassName=function(){return"PathPort"},Bn([I(.5)],t.prototype,"offset",void 0),Bn([re({x:0,y:0},R)],t.prototype,"displacement",void 0),Bn([I("Center")],t.prototype,"alignment",void 0),t}(Tx),TI=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),lr=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},cre=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return TI(t,n),lr([I("blue")],t.prototype,"color",void 0),lr([I("")],t.prototype,"content",void 0),lr([I("")],t.prototype,"link",void 0),lr([I("None")],t.prototype,"textDecoration",void 0),lr([I("NewTab")],t.prototype,"hyperlinkOpenState",void 0),t}(Ee),Ax=function(n){function t(e,i,r,s){var o=n.call(this,e,i,r,s)||this;return r.id||(o.id=e.parentObj&&e.parentObj.propName&&"phases"===e.parentObj.propName?e.parentObj.id:Qe()),o}return TI(t,n),lr([I("")],t.prototype,"content",void 0),lr([I(void 0)],t.prototype,"template",void 0),lr([I("String")],t.prototype,"annotationType",void 0),lr([I(!0)],t.prototype,"visibility",void 0),lr([I(Nr.InheritReadOnly)],t.prototype,"constraints",void 0),lr([re(void 0,cre)],t.prototype,"hyperlink",void 0),lr([I("")],t.prototype,"id",void 0),lr([I()],t.prototype,"width",void 0),lr([I()],t.prototype,"height",void 0),lr([I(0)],t.prototype,"rotateAngle",void 0),lr([I("Parent")],t.prototype,"rotationReference",void 0),lr([re({strokeWidth:0,strokeColor:"transparent",fill:"transparent"},qf)],t.prototype,"style",void 0),lr([I("Center")],t.prototype,"horizontalAlignment",void 0),lr([I("Center")],t.prototype,"verticalAlignment",void 0),lr([re({},Jn)],t.prototype,"margin",void 0),lr([re({top:void 0,bottom:void 0,left:void 0,right:void 0},Jn)],t.prototype,"dragLimit",void 0),lr([I("Shape")],t.prototype,"type",void 0),lr([re({},Td)],t.prototype,"tooltip",void 0),lr([I()],t.prototype,"addInfo",void 0),t}(Ee),Kn=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return TI(t,n),t.prototype.getClassName=function(){return"ShapeAnnotation"},lr([re({x:.5,y:.5},R)],t.prototype,"offset",void 0),t}(Ax),Or=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return TI(t,n),t.prototype.getClassName=function(){return"PathAnnotation"},lr([I(.5)],t.prototype,"offset",void 0),lr([re({x:0,y:0},R)],t.prototype,"displacement",void 0),lr([I("Center")],t.prototype,"alignment",void 0),lr([I(!1)],t.prototype,"segmentAngle",void 0),t}(Ax);function Lx(n){return pre[n.toString()]}function c3(n){return mre[""+n]}var pre={X:"M14,14 L106,106 M106,14 L14,106",Circle:"M0,50 A50,50,0 1 1 100,50 A50,50,0 1 1 0,50 Z",Square:"M0,0 L10,0 L10,10 L0,10 z"},gre={OpenArrow:"M15.9,23 L5,16 L15.9,9 L17,10.7 L8.7,16 L17,21.3Z",Square:"M0,0 L10,0 L10,10 L0,10 z",Fletch:"M14.8,10c0,0-3.5,6,0.2,12c0,0-2.5-6-10.9-6C4.1,16,11.3,16,14.8,10z",OpenFetch:"M6,17c-0.6,0-1-0.4-1-1s0.4-1,1-1c10.9,0,11-5,11-5c0-0.6,0.4-1,1-1s1,0.4,1,1C19,10.3,18.9,17,6,17C6,17,6,17,6,17z M18,23c-0.5,0-1-0.4-1-1c0-0.2-0.3-5-11-5c-0.6,0-1-0.5-1-1s0.4-1,1-1c0,0,0,0,0,0c12.9,0,13,6.7,13,7 C19,22.6,18.6,23,18,23z",IndentedArrow:"M17,10c0,0-4.5,5.5,0,12L5,16L17,10z",OutdentedArrow:"M14.6,10c0,0,5.4,6,0,12L5,16L14.6,10z",DoubleArrow:"M19,10 L19,22 L13,16Z M12,10 L12,22 L6,16Z",Arrow:"M15,10 L15,22 L5,16Z",Diamond:"M12,23l-7-7l7-7l6.9,7L12,23z",Circle:"M0,50 A50,50,0 1 1 100,50 A50,50,0 1 1 0,50 Z"},vre={Square:"M0,0 L10,0 L10,10 L0,10 z",Rhombus:"M10,5 L5,10 L0,5 L5,0 L10,5 Z ",Rectangle:"M0,0 L15,0 L15,10 L0,10 z ",OpenArrow:"M15.9,23 L5,16 L15.9,9 L17,10.7 L8.7,16 L17,21.3Z",Fletch:"M9.82,0 C9.82,0,6.61,5,10,10 C10,10,7.71,5,0,5 C0,5,6.61,5,9.82,0 Z ",OpenFetch:"M0.71,5.71 C0.29,5.71,0,5.43,0,5 C0,4.57,0.29,4.29,0.71,4.29 C8.5,4.29,8.57,0.71,8.57,0.71 C8.57,0.29,8.86,0,9.29,0 C9.719999999999999,0,10,0.29,10,0.71 C10,0.93,9.93,5.71,0.71,5.71 C0.71,5.71,0.71,5.71,0.71,5.71 Z M9.29,10 C8.93,10,8.57,9.71,8.57,9.29 C8.57,9.14,8.36,5.71,0.71,5.71 C0.29,5.71,0,5.36,0,5 C0,4.64,0.29,4.29,0.71,4.29 C0.71,4.29,0.71,4.29,0.71,4.29 C9.93,4.29,10,9.07,10,9.29 C10,9.71,9.71,10,9.29,10 Z ",IndentedArrow:"M10,0 C10,0,6.25,4.58,10,10 L0,5 L10,0 Z ",OutdentedArrow:"M8,0 C8,0,12.5,5,8,10 L0,5 L8,0 Z ",DoubleArrow:"M19,10 L19,22 L13,16Z M12,10 L12,22 L6,16Z",Arrow:"M15,10 L15,22 L5,16Z",Diamond:"M10,5 L5,10 L0,5 L5,0 L10,5 Z ",Circle:"M10,5 C10,7.76,7.76,10,5,10 C2.24,10,0,7.76,0,5 C0,2.24,2.24,0,5,0 C7.76,0,10,2.24,10,5 Z ",Ellipse:"M15,5 C15,7.76,11.64,10,7.5,10 C3.36,10,0,7.76,0,5 C0,2.24,3.36,0,7.5,0 C11.64,0,15,2.24,15,5 Z "},mre={Square:"M0,0 L10,0 L10,10 L0,10 z",Rhombus:"M10,5 L5,10 L0,5 L5,0 L10,5 Z ",Rectangle:"M0,0 L15,0 L15,10 L0,10 z",OpenArrow:"M23,15.9 L16,5 L9,15.9 L10.7,17 L16,8.7 L21,17.3Z",Fletch:"M9.82,0 C9.82,0,6.61,5,10,10 C10,10,7.71,5,0,5 C0,5,6.61,5,9.82,0 Z ",OpenFetch:"M0.71,5.71 C0.29,5.71,0,5.43,0,5 C0,4.57,0.29,4.29,0.71,4.29 C8.5,4.29,8.57,0.71,8.57,0.71 C8.57,0.29,8.86,0,9.29,0 C9.719999999999999,0,10,0.29,10,0.71 C10,0.93,9.93,5.71,0.71,5.71 C0.71,5.71,0.71,5.71,0.71,5.71 Z M9.29,10 C8.93,10,8.57,9.71,8.57,9.29 C8.57,9.14,8.36,5.71,0.71,5.71 C0.29,5.71,0,5.36,0,5 C0,4.64,0.29,4.29,0.71,4.29 C0.71,4.29,0.71,4.29,0.71,4.29 C9.93,4.29,10,9.07,10,9.29 C10,9.71,9.71,10,9.29,10 Z ",IndentedArrow:"M10,0 C10,0,6.25,4.58,10,10 L0,5 L10,0 Z ",OutdentedArrow:"M8,0 C8,0,12.5,5,8,10 L0,5 L8,0 Z ",DoubleArrow:"M10,19 L22,19 L16,13Z M10,12 L22,12 L16,6Z",Arrow:"M10,15 L22,15 L16,5Z",Diamond:"M10,5 L5,10 L0,5 L5,0 L10,5 Z ",Circle:"M10,5 C10,7.76,7.76,10,5,10 C2.24,10,0,7.76,0,5 C0,2.24,2.24,0,5,0 C7.76,0,10,2.24,10,5 Z ",Ellipse:"M15,5 C15,7.76,11.64,10,7.5,10 C3.36,10,0,7.76,0,5 C0,2.24,3.36,0,7.5,0 C11.64,0,15,2.24,15,5 Z "};function Nx(n){return yre[n.toString()]}var yre={Process:"M419.511,76.687L359.511,76.687L359.511,43.086L419.511,43.086z",Decision:"M 253.005,115.687L 200.567,146.071L 148.097,115.687L 200.534,85.304L 253.005,115.687 Z",Document:"M 60 31.9 c 0 0 -11 -7.7 -30 0 s -30 0 -30 0 V 0 h 60 V 31.9 Z",PreDefinedProcess:"M 0,0 L 50,0 L 50,50 L 0,50 Z M 8.334,0 L 8.334,50 M 41.667,0 L 41.667,50",Terminator:"M 269.711,29.33C 269.71,44.061 257.77,56 243.04,56L 158.058,56C 143.33,56 131.39,44.061 131.39,29.33L 131.39,29.33C 131.391,14.6057 143.33,2.669 158.058,2.669L 243.044,2.669C 257.772,2.669 269.711,14.6057 269.711,29.333 Z",PaperTap:"M0.0009,17.2042 L0.0009,47.165 C0.001,47.165 14.403,53.5455 25.00,47.165 C35.599,40.7852 44.403,43.5087 50.00,47.165L50.001,17.2042 M50.001,32.7987 L50.001,2.8405 C50.001,2.8405 35.599,-3.5427 25.001,2.8405C14.403,9.2237 5.599,6.494 0.0009,2.8405 L0.0009,32.7987",DirectData:"M 132.62 0 L 17.38 0 C 7.78 0 0 13.43 0 30 C 0 46.57 7.78 60 17.38 60 L 132.62 60 M 132.62 0C 123.02 0 115.24 13.43 115.24 30 C 115.24 46.57 123.02 60 132.62 60 C 142.22 60 150 46.57 150 30 C 150 13.43 142.22 0 132.62 0 z ",SequentialData:"M0.0029,24.999 C0.0029,11.1922 10.433,0.0021 23.295,0.0021 C36.159,0.00216 46.585,11.1922 46.585,24.999C46.585,38.8057 36.159,49.9979 23.295,49.9979 C10.433,49.9979 0.0029,38.8057 0.0029,24.999 z M23.294,49.999 L50.002,49.999",Sort:"M50.001,24.9971 L25.001,49.9971 L0.00097,24.9971 L25.001,-0.00286865 L50.001,24.9971 z M0.000976562,24.9971 L50.001,24.9971",MultiDocument:"M43.6826,40 C44.8746,40.6183 45.8586,41.3502 46.8366,42.1122 L46.8366,4.74487 L3.09857,4.74487 L3.09857,10.9544 M46.837,35.143 C48.027,35.765 49.025,36.604 50.003,37.369 L50.003,0.002 L6.264,0.002 L6.264,4.744 M43.682,47.113 L43.682,10.765 L0.0025,10.7652 L0.0025,47.1132 C0.0025,47.1132 12.5846,53.6101 21.8426,47.1132 C31.1006,40.6163 38.792,43.393 43.6826,47.1132 z",Collate:"M50.001,0.0028 L25.001,25.0029 L0.00097,0.0028 L50.001,0.002 z M0.0009,50.002 L25.001,25.002L50.001,50.002 L0.0009,50.0029 z",SummingJunction:"M7.3252,42.6768 L42.6772,7.3247 M42.6768,42.6768 L7.3248,7.3247 M0.0009,25.001 C0.0009,11.193 11.197,0.0009 25.001,0.0009 C38.809,0.0009 50.001,11.193 50.001,25.001 C50.001,38.809 38.809,50.001 25.001,50.001 C11.197,50.00 0.0009,38.809 0.0009,25.00 z",Or:"M 0 50 L 100 50 M 50 100 L 50 0.0 M 0 50 C 0 22.384 22.392 0 50 0 C 77.616 0 100 22.384 100 50 C 100 77.616 77.616 100 50 100 C 22.392 100 0 77.616 0 50 Z",InternalStorage:"M 0 3.81946A 2.5,3.81946 0 0,1 2.5,0L 47.5 0A 2.5,3.81946 0 0,1 50,3.81946L 50 45.836A 2.5,3.819446 0 0,1 47.5,49.652778L 2.5 49.652778A 2.5,3.819446 0 0,1 0,45.8336L 0 3.819446ZM 0 11.45834L 50 11.4583334M 12.5 0L 12.5 49.652778",Extract:"M0,35 L30,0 L60,35 Z",ManualOperation:"M46.4,28.8 L14.8,28.8 L0,0 L60,0 Z",Merge:"M60,0 L30,35 L0,0 Z",OffPageReference:"M60,33.3 L30.1,39 L0,33.3 L0,0 L60,0 Z",SequentialAccessStorage:"M 60 30 C 60 13.4 46.6 0 30 0 S 0 13.4 0 30 s 13.4 30 30 30 h 28.6 v -6.5 h -9.9C 55.5 48 60 39.5 60 30 Z",Annotation:"M49.9984,50.0029 L-0.00271199,50.0029 L-0.00271199,0.00286865 L49.9984,0.00286865",Annotation2:"M49.9977,50.0029 L25.416,50.0029 L25.416,0.00286865 L49.9977,0.00286865 M25.4166,25.0029 L-0.00227869,25.0029",Data:"M 10 0 L 40 0 L 30 40 L 0 40 Z",Card:"M275,60 L400,60 L400,110 L260,110 L260,75 Z",Delay:"M0,0 L12.029,0 C14.212999,0 16,1.7869979 16,3.9709952 C16,6.1549926 14.212999,7.9409904 12.029,7.9409904 L0,7.9409904 z",Preparation:"M 1048.17 572 C 1051.06 568.86 1055.17 567.05 1059.5 567 L 1094.51 567 C 1098.84 567.05 1102.95 568.86 1105.84 572 L 1126.43 595 C 1127.01 596.28 1127.01 597.72 1126.43 599 L 1105.84 622 C 1102.95 625.14 1098.84 626.95 1094.51 627 L 1059.5 627 C 1055.17 626.95 1051.06 625.14 1048.17 622 L 1027.58 599 C 1027 597.72 1027 596.28 1027.58 595 L 1048.17 572 Z",Display:"M47.8809,19.2914 L32.7968,-0.00594145 L11.3902,-0.00594145 C7.93166,-0.00594145 0.00124586,11.187 0.00124586,24.9968C0.00124586,38.8032 7.93166,49.9962 11.3902,49.9962 L32.7968,49.99 L47.615,31.038 C47.615,31.0388 52.798,24.9968 47.880,19.2914 z",ManualInput:"M 912 732 L 1006.85 707 C 1008.2 707 1009.5 707.53 1010.46 708.46 C 1011.41 709.4 1011.95 710.67 1011.95 712 L 1011.95 762C 1012 764.41 1010.28 766.52 1007.87 767 L 917.1 767 C 915.75 767 914.45 766.47 913.49 765.54 C 912.54 764.6 912 763.33 912 762 L 912 732 Z",LoopLimit:"M 8 9 L 27 9 L 33 15 L 33 26 C 33 27 33 27 32 27 L 4 27 C 3 27 2 27 2 26 L 2 15 L 8 9 Z",StoredData:"M 5.55 0L 50 0A 1.5,30 0 0,1 50,0A 5.555,25 0 0,0 50,50A 1.5,30 0 0,1 50,50L 5.555 50A 5.55,25 0 0,1 5.555,0Z"};function d3(n,t,e){var i;i="Straight"!==n.type&&n.sourceWrapper?n.sourceWrapper.corners.center:function Sre(n){var t;if(n.sourcePortWrapper){var e=n.sourcePortWrapper;t={x:e.offsetX,y:e.offsetY}}else t=n.sourceID&&n.sourceWrapper&&n.targetWrapper?qa(n,0,n.sourceWrapper.corners.center,n.targetWrapper.corners.center,!1):n.sourcePoint;return t}(n);var r=function bre(n,t,e,i,r){var b,M,s=n.sourceWrapper,o=n.targetWrapper,a=n.sourcePortWrapper,l=n.targetPortWrapper,d=[],p=Xa(n),y={corners:undefined,point:t,direction:undefined,margin:{left:5,right:5,bottom:5,top:5}},S={corners:undefined,point:e,direction:undefined,margin:{left:5,right:5,bottom:5,top:5}};if(void 0!==s&&void 0!==o&&(b=xn(s),M=xn(o),y.corners=s.corners,S.corners=o.corners),void 0!==a&&(y.direction="Left"===a.connectionDirection||"Top"===a.connectionDirection||"Bottom"===a.connectionDirection||"Right"===a.connectionDirection?a.connectionDirection:zo({x:a.offsetX,y:a.offsetY},b,s.bounds)),void 0!==l&&(S.direction="Left"===l.connectionDirection||"Right"===l.connectionDirection||"Bottom"===l.connectionDirection||"Top"===l.connectionDirection?l.connectionDirection:zo({x:l.offsetX,y:l.offsetY},M,o.bounds)),"Bezier"===n.type&&!n.isBezierEditing&&n.segments.length>0)for(var D=n.segments.length-1;D>=0;)n.segments[parseInt(D.toString(),10)].isInternalSegment&&n.segments.pop(),D--;if(void 0!==s&&void 0!==o)return(void 0===y.direction||void 0===S.direction)&&(i?function Ire(n,t,e){"LeftToRight"===e?(n.direction=n.direction?n.direction:"Right",t.direction=t.direction?t.direction:"Left"):"RightToLeft"===e?(n.direction=n.direction?n.direction:"Left",t.direction=t.direction?t.direction:"Right"):"TopToBottom"===e?(n.direction=n.direction?n.direction:"Bottom",t.direction=t.direction?t.direction:"Top"):"BottomToTop"===e&&(n.direction=n.direction?n.direction:"Top",t.direction=t.direction?t.direction:"Bottom")}(y,S,i):y.corners.top>S.corners.bottom&&Math.abs(y.corners.top-S.corners.bottom)>p?(y.direction=y.direction?y.direction:"Top",S.direction=S.direction?S.direction:"Bottom"):y.corners.bottomp?(y.direction=y.direction?y.direction:"Bottom",S.direction=S.direction?S.direction:"Top"):y.corners.rightp||y.corners.right+p=y.corners.left-p&&y.corners.left>S.corners.left?(y.direction=y.direction?y.direction:"Right",S.direction=S.direction?S.direction:"Left"):y.corners.left>S.corners.right&&Math.abs(y.corners.left-S.corners.right)>y.margin.left+y.margin.right||S.corners.right+p=S.corners.left-p&&y.corners.left0&&n.segments[0].direction&&(y.direction=n.segments[0].direction),y.point=Ol(b,y.direction),d=Ol(b,_n(y.direction)),y.point=qa(n,0,y.point,d,!1)):y.point=o.corners.center;if(void 0!==h){switch(S.point={x:h.offsetX,y:h.offsetY},S.direction){case"Bottom":case"Top":S.point.y=S.point.y;break;case"Left":case"Right":S.point.x=S.point.x}n.targetPadding&&!w&&(S.point=AI(n,y,S,!0))}else"Orthogonal"===n.type||"Bezier"===n.type?(S.point=Ol(M,S.direction),d=Ol(M,_n(S.direction)),S.point=qa(n,0,S.point,d,!0)):S.point=a.corners.center;if("Orthogonal"!==n.type){var C=void 0,D=void 0;if("Bezier"===n.type){if(n.bezierSettings.allowSegmentsReset||0===n.segments.length||!R.isEmptyPoint(n.segments[n.segments.length-1].point))return c=b3(n,y,S,void 0,s),Ox(n,y,S);Uv(n)}else Uv(n);if(void 0===n.sourcePortWrapper){y.point=y.corners.center,n.segments&&n.segments.length>0&&(C=R.isEmptyPoint((D=n.segments[0]).point)?void 0:D);var A=void 0!==C?C.point:S.point;if("Bezier"===n.type&&n.segments.length>0&&n.segments[0].vector1.angle&&n.segments[0].vector1.distance){var x=Math.max(y.corners.width,y.corners.height);A=R.transform(y.point,n.segments[0].vector1.angle,x/2)}y.point=w?n.sourceWrapper.bounds.center:qa(n,0,y.point,A,!1)}if(void 0===n.targetPortWrapper){S.point=S.corners.center,n.segments&&n.segments.length>1&&(C=R.isEmptyPoint((D=n.segments[n.segments.length-2]).point)?void 0:D);var P=C?C.point:y.point;"Bezier"===n.type&&n.segments.length>0&&n.segments[n.segments.length-1].vector2.angle&&n.segments[n.segments.length-1].vector2.distance&&(x=Math.max(y.corners.width,y.corners.height),P=R.transform(S.point,n.segments[0].vector2.angle,x/2)),S.point=w?n.targetWrapper.bounds.center:qa(n,0,P,S.point,!0)}c=Ox(n,y,S)}else"Orthogonal"===n.type&&n.segments&&n.segments.length>0&&null!==n.segments[0].direction?c=function Nre(n,t,e,i,r,s,o){var a,h,c,d;Uv(n);for(var u=0;u0&&n.segments[u-1].direction===h.direction?u=y3(n,u,t):h.direction?t.point=u3(t,n.segments[parseInt(u.toString(),10)]):(f=n.segments[u-1])&&f.points&&f.points.length>0&&(t.point=f.points[f.points.length-1]),u===n.segments.length-1)if(S3(n,t),v3(a=void 0===r?Lre(n,t,e):p3(n,t,e),n),h.points=[],a.length>=2)for(c=0;c2&&n.segments.length>2){var p={x:a[parseInt(c.toString(),10)].x,y:t.point.y};h.points=[],h.points.push(p),h.points.push(a[parseInt(c.toString(),10)]);var f=n.segments[u-1];n.segments.length<4&&f.points.pop(),f.points=f.points.concat(h.points)}else h.points.push(a[parseInt(c.toString(),10)]);else h.points.push(a[parseInt(c.toString(),10)]);else d=u;if(void 0!==d&&!n.selectedSegmentIndex&&(d===n.segments.length-1&&(n.segments[d-1].direction=null,n.segments[d-1].length=null),n.segments.splice(d,1)),i&&0===u){var g=g3(n,i,s);g&&(t.point=g)}}return I3(n,[])}(n,y,S,l,h,o):(n.segments[0]||(C=new wi(n,"segments",{type:"Orthogonal"},!0),n.segments.push(C)),n.segments[0].points=c=b3(n,y,S,void 0,s));return c}(n,y.direction,S.direction,y.point,S.point,r);if(Uv(n),(n.sourceWrapper||n.targetWrapper)&&function Dre(n,t,e){var i=n.sourcePortWrapper,r=n.targetPortWrapper,s=n.sourceWrapper,o=t.point,a={left:0,right:0,top:0,bottom:0},l={x:0,y:0},c="Top";if(s?(o=e.point,a=t.margin):(s=n.targetWrapper,a=e.margin),"Orthogonal"===n.type)if(n.segments&&n.segments.length>0&&n.sourceWrapper&&n.segments[0].direction)t.direction=n.segments[0].direction,l=qa(n,0,l=Ol(s.corners,t.direction),Ol(s.corners,_n(t.direction)),!1);else{var u={corners:null,direction:null,point:null,margin:null};jv(s,{corners:null,direction:null,point:o,margin:a},u,n),l=u.point,c=u.direction}else{var f=void 0;n.segments&&n.segments.length>1&&(f=s===n.sourceWrapper?n.segments[0].point:n.segments[n.segments.length-2].point),l=qa(n,0,s.bounds.center,n.segments&&n.segments.length>1?f:o,s===n.targetWrapper)}s===n.sourceWrapper?(t.direction=t.direction||c,t.point=l,n.sourcePortWrapper&&(t.point={x:i.offsetX,y:i.offsetY},n.sourcePadding&&(t.point=AI(n,t,e,!1)))):(e.direction=e.direction||c,e.point=l,n.targetPortWrapper&&(e.point={x:r.offsetX,y:r.offsetY},n.targetPadding&&(e.point=AI(n,t,e,!0))))}(n,y,S),"Straight"===n.type||"Bezier"===n.type)d=Ox(n,y,S);else if("Orthogonal"===n.type&&n.segments&&n.segments.length>0&&null!==n.segments[0].length&&null!==n.segments[0].direction)d=function Ere(n,t,e,i,r,s,o){var a,l,c,u,h=[];if(Uv(n),n.segments.length>0){for(var f=0;f0&&n.segments[f-1].direction===p.direction)f=y3(n,f,t);else{var g=n.segments[f-1];t.point=p.direction?u3(t,p):g.points[g.points.length-1]}if(f===n.segments.length-1&&(o||r?n.targetWrapper&&void 0===n.targetPortWrapper?(S3(n,t),l=wre(n,t,e)):l=p3(n,t,e):l=Mre(n,t,e),l))if(v3(l,n),p.points=[],l.length>=2)for(a=0;at.corners.top&&e.point.ye.point.x?"Left":"Right"):e.point.x>t.corners.left&&e.point.xe.point.y?"Top":"Bottom")),n.sourcePortWrapper&&s===_n(r)?(("Left"===s||"Right"===s)&&t.point.y>=t.corners.top&&t.point.y<=t.corners.center.y&&e.point.y>=t.corners.top&&e.point.y<=t.corners.center.y?(t.direction="Top",a=t.point.y-t.corners.top+20):("Left"===s||"Right"===s)&&t.point.y>t.corners.center.y&&t.point.y<=t.corners.bottom&&e.point.y>t.corners.center.y&&e.point.y<=t.corners.bottom?(t.direction="Bottom",a=t.corners.bottom-t.point.y+20):("Top"===s||"Bottom"===s)&&t.point.x>=t.corners.left&&t.point.x<=t.corners.center.x&&e.point.x>=t.corners.left&&e.point.x<=t.corners.center.x?(t.direction="Left",a=t.point.x-t.corners.left+20):("Top"===s||"Bottom"===s)&&t.point.x<=t.corners.right&&t.point.x>t.corners.center.x&&e.point.x<=t.corners.right&&e.point.xt.point.y&&t.point.y>=e.corners.top?(i="Top",r=t.point.y-e.corners.top+20):e.corners.center.y===t.point.y&&"Top"===n.segments[n.segments.length-2].direction||e.corners.center.ye.point.y?t.point.y-t.corners.top+20:t.corners.bottom-t.point.y+20):(i="Top",r=e.corners.height/2+20):e.corners.center.x!==t.point.x||e.corners.topt.point.x&&t.point.x>=e.corners.left?(i="Left",r=t.point.x-e.corners.left+20):e.corners.center.x===t.point.x&&"Left"===n.segments[n.segments.length-2].direction||e.corners.center.x<=t.point.x&&t.point.x<=e.corners.right?(i="Right",r=e.corners.right-t.point.x+20):void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&t.corners.left<=t.point.x&&t.point.x<=t.corners.right&&(i=t.direction,r=t.point.x>e.point.x?t.point.x-t.corners.left+20:t.corners.right-t.point.x+20):(i="Left",r=e.corners.width/2+20);var a=t.point;t.point=Fn(t.point,"Left"===i||"Top"===i?-r:r,"Left"===i||"Right"===i?0:90),t.direction=R.direction(t.point,e.point),void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&(t.corners.center.x===e.corners.center.x||t.corners.center.y===e.corners.center.y)&&(t.direction=e.direction);var l=Ys(n,t,e);return l.splice(0,0,a),l}function p3(n,t,e){var i,r;e.corners=n.targetWrapper.corners,void 0!==n.sourcePortWrapper&&(r=zo({x:n.sourcePortWrapper.offsetX,y:n.sourcePortWrapper.offsetY},xn(n.sourceWrapper),n.sourceWrapper.bounds));var a=function Cre(n,t,e,i){var r=!1;switch(e.direction){case"Left":void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&"Right"===i&&t.point.x>e.point.x&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom||("Bottom"===i&&t.point.y>e.point.y||"Top"===i&&t.point.y=t.corners.left&&t.point.x<=t.corners.right?(t.direction="Right"===i?t.point.y>e.point.y?"Top":"Bottom":t.point.xe.point.x&&(t.point.y>e.point.y||t.point.yt.point.y&&e.corners.bottome.point.y||t.point.x>e.point.x&&t.point.y<=e.point.y&&e.corners.top=t.point.y?t.direction="Top":t.point.xe.point.x&&t.point.y>e.point.y&&e.corners.bottomt.point.y?t.direction="Bottom":t.point.y===e.point.y&&t.point.xe.point.y||"Top"===i&&t.point.ye.point.x&&t.point.x>=t.corners.left&&t.point.x<=t.corners.right?(t.direction=t.point.x>e.point.x?"Left":"Right",r=!0):void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&"Left"===i&&t.point.x=t.corners.top&&t.point.y<=t.corners.bottom?(t.direction=t.point.y>e.point.y?"Top":"Bottom",r=!0):t.point.x=t.point.y&&t.point.y===e.point.y||t.point.y>e.point.y&&t.point.x>e.point.x?t.direction="Top":t.point.ye.point.x?t.direction="Bottom":t.point.xe.point.y||t.point.ye.point.x&&(t.direction="Left");break;case"Top":void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&"Bottom"===i&&t.point.y>e.point.y&&t.point.x>=t.corners.left&&t.point.x<=t.corners.right||("Right"===i&&t.point.x>e.point.x||"Left"===i&&e.point.y>t.point.y&&e.point.x>t.point.x)&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom?(t.direction="Bottom"===i?t.point.x>e.point.x?"Left":"Right":t.point.ye.point.y&&t.point.x>e.corners.left&&t.point.x=e.point.y?t.direction="Top":t.point.ye.point.x?t.direction="Left":t.point.yt.point.x)&&t.point.y>e.point.y&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom||"Top"===i&&t.point.y=t.corners.left&&t.point.x<=t.corners.right)?(t.direction="Right"===i||"Left"===i?t.point.y>e.point.y?"Top":"Bottom":t.point.x>e.point.x?"Left":"Right",r=!0):t.point.ye.corners.left&&e.corners.right>t.point.x?t.point.ye.corners.left&&e.corners.center.x>=t.point.x?t.direction="Left":t.point.ye.point.y&&t.point.x>e.point.x?t.direction="Left":t.point.y>e.point.y&&t.point.xe.point.x||e.point.x>t.point.x)&&(t.direction="Bottom")}return r}(n,t,e,r);return!n.selectedSegmentIndex&&void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&e.direction===_n(r)&&(("Left"===e.direction&&t.point.x>e.point.x||"Right"===e.direction&&t.point.x=t.corners.top&&t.point.y<=t.corners.bottom||"Bottom"===e.direction&&t.point.y=t.corners.left&&t.point.x<=t.corners.right)?i=f3(n,t,e):n.selectedSegmentIndex||t.direction!==e.direction?!n.selectedSegmentIndex&&("Left"===e.direction&&t.point.x>e.point.x||"Right"===e.direction&&t.point.x=t.point.y||"Top"===e.direction&&t.point.y>e.point.y||"Bottom"===e.direction&&t.point.y=t.point.x?i=n.selectedSegmentIndex?kl(t,e):f3(n,t,e):!n.selectedSegmentIndex&&void 0!==n.sourceWrapper&&void 0!==n.targetWrapper&&void 0!==n.targetPortWrapper&&("Left"===t.direction||"Right"===t.direction)&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom&&("Top"===e.direction||"Bottom"===e.direction)&&e.corners.center.x===t.corners.center.x?(t.direction="Top"===e.direction?"Bottom":"Top",i=Ys(n,t,e,"Top"===e.direction?t.corners.bottom-t.point.y+20:t.point.y-t.corners.top+20)):!n.selectedSegmentIndex&&void 0!==n.sourceWrapper&&void 0!==n.targetWrapper&&void 0!==n.targetPortWrapper&&("Top"===t.direction||"Bottom"===t.direction)&&t.point.x>=t.corners.left&&t.point.x<=t.corners.right&&("Left"===e.direction||"Right"===e.direction)&&e.corners.center.y===t.corners.center.y?(t.direction="Left"===e.direction?"Right":"Left",i=Ys(n,t,e,"Left"===e.direction?t.corners.right-t.point.x+20:t.point.x-t.corners.left+20)):i=a?Ys(n,t,e,"Left"===t.direction||"Right"===t.direction?"Left"===t.direction?t.point.x-t.corners.left+20:t.corners.right-t.point.x+20:"Top"===t.direction?t.point.y-t.corners.top+20:t.corners.bottom-t.point.y+20):kl(t,e):i=Ys(n,t,e),i}function g3(n,t,e){var r,i={x:t.offsetX,y:t.offsetY},s=xn(e),o=zo(i,s,e.bounds),a=n.segments[0];return a.direction!==o&&(function Ore(n,t,e,i,r,s){var a,h,o=13,l=[];l.push(i),i.y===r.y&&("Left"===t&&r.xi.x)||i.x===r.x&&("Top"===t&&r.yi.y)||("Top"===t||"Bottom"===t?"Top"===t&&r.yi.y-o||"Bottom"===t&&r.y>i.y&&r.yo&&("Top"===t&&r.yi.y)?l.push({x:i.x,y:r.y}):(a=r.xi.x-o||"right"===t&&r.x>i.x&&r.xo&&("Left"===t&&r.xi.x)?l.push({x:r.x,y:i.y}):(l.push({x:a="Left"===t?e.left-o:e.right+o,y:i.y}),l.push({x:a,y:r.y})),s&&(l.push(n.points[0]),l.reverse()),n.points=l)}(a,o,s,a.points[0],a.points[a.points.length-1],!1),r=a.points[a.points.length-1],a.direction=R.direction(a.points[a.points.length-2],a.points[a.points.length-1])),r}function v3(n,t,e){var s,i=t.segments[t.segments.length-2],r=i.points[i.points.length-1];(("Top"===i.direction||"Bottom"===i.direction)&&r.x===n[1].x||("Left"===i.direction||"Right"===i.direction)&&r.y===n[1].y)&&(i.points[i.points.length-1]=n[1],s=R.direction(i.points[0],i.points[i.points.length-1]),void 0!==t.sourceWrapper&&void 0===t.sourcePortWrapper&&s===_n(i.direction)&&("Left"===i.direction||"Right"===i.direction?i.points[0].x="Right"===i.direction?i.points[0].x-t.sourceWrapper.corners.width:i.points[0].x+t.sourceWrapper.corners.width:i.points[0].y="Bottom"===i.direction?i.points[0].y-t.sourceWrapper.corners.height:i.points[0].y+t.sourceWrapper.corners.height),i.direction=s,i.length=R.distancePoints(i.points[0],i.points[i.points.length-1]),n.splice(0,1))}function AI(n,t,e,i){var o=i?n.targetPadding:n.sourcePadding,a=i?n.targetPortWrapper:n.sourcePortWrapper,l=new Ne(a.bounds.x-o,a.bounds.y-o,a.actualSize.width+2*o,a.actualSize.height+2*o),h=[l.topLeft,l.topRight,l.bottomRight,l.bottomLeft];h[h.length]=h[0];var d=i?e.point:t.point;return Px({x1:t.point.x,y1:t.point.y,x2:e.point.x,y2:e.point.y},h,0,d)||d}function m3(n,t){var e=[],i=mF(0,n.corners,t);i.push(i[0]);for(var r=0;r0){var r=void 0,s=[],o=t.point;for(r=0;r1&&R.equals(a.points[0],a.points[1])&&n.segments.splice(r,1),a)for(var l=0;l0||0===r)&&i.push(a.points[parseInt(l.toString(),10)])}}return i}function kx(n,t,e){return"Top"===n||"Bottom"===n?e.x>t.x?"Right":"Left":e.y>t.y?"Bottom":"Top"}function Uv(n){if("Straight"===n.type||"Bezier"===n.type){if(0===n.segments.length||n.segments.length>0&&!R.isEmptyPoint(n.segments[n.segments.length-1].point))if("Bezier"===n.type){var t=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0},!0);n.segments.push(t)}else t=new Bl(n,"segments",{type:"Straight"},!0),n.segments.push(t)}else{if(n.segments.length>0)for(var e=!1,i=0;i=t.corners.left&&e.point.x<=t.corners.right&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom)t.direction=e.point.y>t.point.y?"Bottom":"Top",i=Ys(n,t,e,"Top"===t.direction?t.point.y-t.corners.top+20:t.corners.bottom-t.point.y+20);else if(n.sourcePortWrapper&&r===_n(o)){var h;("Left"===r||"Right"===r)&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom?(t.direction=e.point.y>t.point.y?"Bottom":"Top",h=t.corners.height/2+20):("Top"===r||"Bottom"===r)&&t.point.x>=t.corners.left&&t.point.x<=t.corners.right&&(t.direction=e.point.x>t.point.x?"Right":"Left",h=t.corners.width/2+20),t.direction&&h?i=Ys(n,t,e,h,!0):(t.direction=o,i=kl(t,e))}else if(!n.sourcePortWrapper||r!==e.direction||"Top"!==r&&"Bottom"!==r||t.corners.center.x!==e.corners.center.x)if(t.direction===e.direction)if(("Left"===t.direction||"Right"===t.direction)&&e.point.y>t.corners.top-20&&e.point.yt.corners.left-20&&e.point.xt.point.y?"Bottom":"Top",i=Ys(n,t,e,"Bottom"===t.direction?t.corners.bottom-t.point.y+20:t.point.y-t.corners.top+20);else t.direction=o,i=Ys(n,t,e,"Top"===o||"Bottom"===o?n.sourceWrapper.height/2+20:n.sourceWrapper.width/2+20),t.point=i[1],"Left"===o||"Right"===o?(e.direction=o,e.point="Left"===o?e.corners.middleLeft:e.corners.middleRight):jv(n.targetWrapper,t,e,n),i=Ys(n,t,e);return i}function S3(n,t){if(void 0!==n.targetWrapper&&void 0===n.targetPortWrapper&&xn(n.targetWrapper).containsPoint(t.point,1)){var i=n.targetWrapper,r=n.segments[n.segments.length-2],s=r.points[r.points.length-1],o=_n(r.direction);"Bottom"===o?s.yi.corners.top-1&&(r.points[r.points.length-1].y=i.corners.top-20,r.length=R.distancePoints(r.points[0],r.points[r.points.length-1])):"Left"===o?s.x>i.corners.left-1&&(r.points[r.points.length-1].x=i.corners.left-20,r.length=R.distancePoints(r.points[0],r.points[r.points.length-1])):"Right"===o&&s.x0||0===e)&&t.push(i.points[parseInt(r.toString(),10)]);return t}function jv(n,t,e,i){var r,s={x:0,y:0},o=LI(n,n.corners,n.bounds),a=t.margin,l=t.point;if(o.bottomCenter.y+a.bottoml.y)r="Top",s=o.topCenter;else if(o.middleLeft.x-a.left>l.x)r="Left",s=o.middleLeft;else if(o.middleRight.x+a.rightc&&(f=c,r="Right",s=o.middleRight),f>d&&(f=d,r="Bottom",s=o.bottomCenter),f>u&&(r="Left",s=o.middleLeft)}e.point=s,e.direction=r;var p=Ol(o,_n(e.direction));e.point=qa(i,0,e.point,p,n===i.targetWrapper)}function b3(n,t,e,i,r){var s,o,a;if(s=function Qre(n,t){var e=!1;switch(n){case"Left":switch(t){case"Right":case"Bottom":e=!0}break;case"Top":switch(t){case"Left":case"Right":case"Bottom":e=!0}break;case"Bottom":"Right"===t&&(e=!0)}return e}(t.direction,e.direction),s&&x3(t,e),"Right"===t.direction&&"Left"===e.direction)a=function kre(n,t,e,i){var o=Math.round(Math.abs(t.point.y-e.point.y)),a={x:Math.max(t.point.x,t.corners.right),y:t.point.y},l={x:Math.min(e.point.x,e.corners.left),y:e.point.y},h=Xa(n);if(i){var c=l;l=a,a=c}return t.corners.bottom+he.corners.bottom+h||("Bezier"!==n.type||e.corners.left-t.corners.right<=2*h&&e.corners.left-t.corners.right>=5)&&(h=0),t.margin={left:h,right:h,top:h,bottom:h},e.margin={left:h,right:h,top:h,bottom:h},0===o&&(t.corners.right=e.corners.right?void 0!==i&&(i.offsetYe.corners.bottom+e.margin.bottom)||void 0===i&&t.corners.middleRight.ye.corners.bottom+e.margin.bottom&&t.corners.top>e.corners.bottom||void 0===i&&t.corners.middleRight.y>e.corners.bottom||void 0!==i&&i.offsetYe.corners.top||void 0===i&&t.corners.middleRight.y>e.corners.bottom?Ae.Three:t.corners.rightr.offsetY+e.margin.right||void 0===r&&t.corners.top>e.corners.middleRight.y||void 0!==r&&(void 0!==i&&i.offsetXr.offsetX||void 0===r&&t.corners.left>e.corners.topCenter.x?Ae.Four:Ae.Two:void 0!==s&&Math.abs(t.corners.right-e.corners.left)<=5&&Math.abs(s.offsetY-e.corners.top)<=5||void 0!==r&&t.corners.right=25&&t.corners.middleRight.y+t.margin.righte.corners.bottom+e.margin.bottom||void 0===o&&t.corners.middleRight.y>e.corners.bottom+e.margin.bottom?t.corners.top>e.corners.bottom?void 0!==a&&t.corners.right+t.margin.righta.offsetX||void 0===a&&t.corners.left>e.corners.bottomCenter.x?Ae.Four:Ae.Two:void 0!==o&&Math.abs(t.corners.right-e.corners.left)<=25&&Math.abs(o.offsetY-e.corners.bottom)<=25?Ae.Two:Ae.Four}(n,t,e,s);else if("Bottom"===t.direction&&"Top"===e.direction)a=function Hre(n,t,e){var r=t.point.x-e.point.x,s=Xa(n);return t.corners.right+se.corners.right+s||("Bezier"!==n.type||e.corners.top-t.corners.bottom<=2*s&&e.corners.top-t.corners.bottom>=5)&&(s=0),t.margin={left:s,right:s,top:s,bottom:s},e.margin={left:s,right:s,top:s,bottom:s},0===r&&t.corners.bottome.corners.right+e.margin.right||void 0===i&&t.corners.bottomCenter.x>e.corners.right+e.margin.right?Ae.Three:t.corners.bottomr.offsetX||void 0===r&&t.corners.left>e.corners.left||void 0!==r&&t.corners.right+t.margin.righte.corners.bottom?Ae.Five:0===s||0===o?Ae.One:Ae.Three}(n,t,e)}else"Bottom"===t.direction&&"Left"===e.direction?a=function Bre(n,t,e,i){var r=n.sourcePortWrapper,s=n.targetPortWrapper,o=Xa(n);if(e.margin={left:o,right:o,top:o,bottom:o},t.margin={top:o,bottom:o,left:o,right:o},i){var l=r;r=s,s=l}return void 0!==r&&r.offsetXs.offsetY||void 0===s&&t.corners.top>e.corners.middleLeft.y?Ae.Four:Ae.Two:void 0!==s&&Math.abs(t.corners.right-e.corners.left)<=25&&Math.abs(s.offsetY-t.corners.bottom)<=25?Ae.Two:Ae.Four}(n,t,e,s):"Left"===t.direction&&"Left"===e.direction?a=function Ure(n,t,e){var i=n.sourcePortWrapper,r=n.targetPortWrapper,s=Xa(n);t.margin={left:s,right:s,top:s,bottom:s},e.margin={left:s,right:s,top:s,bottom:s};var o=Math.round(Math.abs(t.point.x-e.point.x)),a=Math.round(Math.abs(t.point.y-e.point.y));return t.corners.leftr.offsetY||void 0===r&&t.corners.top-t.margin.top>e.corners.middleLeft.y?Ae.Three:t.corners.righte.corners.bottom+e.margin.bottom||void 0===i&&t.corners.middleLeft.y>e.corners.bottom+e.margin.bottom?Ae.Three:t.corners.left>e.corners.right?Ae.Five:0===o||0===a?Ae.One:Ae.Three}(n,t,e):"Left"===t.direction&&"Top"===e.direction?a=function _re(n,t,e,i){var s=n.sourcePortWrapper,o=Xa(n);e.margin={left:o,right:o,top:o,bottom:o},t.margin={top:o,bottom:o,left:o,right:o};var a=n.targetPortWrapper,l={x:Math.min(t.point.x,t.corners.left),y:t.point.y},h={x:e.point.x,y:Math.min(e.point.y,e.corners.top)};if(i){var c=s;s=a,a=c;var d=l;l=h,h=d}return void 0!==s&&s.offsetYa.offsetX||void 0===a&&t.corners.left-t.margin.left>e.corners.topCenter.x?Ae.Two:Ae.Four:void 0!==a&&t.corners.rightr.offsetX||void 0===r&&t.corners.left>e.corners.left||void 0!==r&&t.corners.right+t.margin.righte.corners.right+e.margin.right||void 0===i&&t.corners.left>e.corners.right||void 0!==i&&i.offsetXe.corners.bottom?Ae.Five:0===s||0===o?Ae.One:Ae.Three}(n,t,e));return s&&x3(t,e),o=function Vre(n,t,e,i,r,s){var l,d,h=n.sourceWrapper.corners,c=n.targetWrapper.corners,u=20,f={corners:e.corners,point:e.point,direction:e.direction,margin:e.margin},p={corners:i.corners,point:i.point,direction:i.direction,margin:i.margin};if(!(f.direction===p.direction&&t!==Ae.Five||f.direction!==_n(p.direction)&&t!==Ae.Three))switch(f.direction){case"Left":h.middleLeft.x>c.middleRight.x&&(d=(h.middleLeft.x-c.middleRight.x)/2,u=s?d:Math.min(u,d));break;case"Right":h.middleRight.xc.bottomCenter.y&&(d=(h.topCenter.y-c.bottomCenter.y)/2,u=s?d:Math.min(u,d));break;case"Bottom":h.bottomCenter.yf&&hf)&&o>c&&o<=d&&e>=20&&(s=n.point.x-t.corners.left+s),i&&n.direction===t.direction&&n.corners.left>t.corners.left&&n.corners.left-t.corners.right>=20&&(s=(n.corners.left-t.corners.right)/2),p=Fn(n.point,s,180);break;case"Top":(o>c&&oc)&&h>f&&h<=u&&e>=20&&(s=n.point.y-t.corners.top+s),i&&n.direction===t.direction&&n.corners.top>t.corners.top&&n.corners.top-t.corners.bottom>=20&&(s=(n.corners.top-t.corners.bottom)/2),p=Fn(n.point,s,270);break;case"Right":(h>f&&hf)&&a=c&&e>=20&&(s=t.corners.right-n.point.x+s),i&&n.direction===t.direction&&n.corners.right=20&&(s=(t.corners.left-n.corners.right)/2),p=Fn(n.point,s,0);break;case"Bottom":(o>c&&oc)&&l=f&&e>=20&&(s=t.corners.bottom-n.point.y+s),i&&n.direction===t.direction&&n.corners.bottom=20&&(s=(t.corners.top-n.corners.bottom)/2),p=Fn(n.point,s,90)}r=[n.point,p];var g=void 0;if("Top"===n.direction||"Bottom"===n.direction){var v=n.direction;n.direction=p.x>t.point.x?"Left":"Right",n.point=p,r=NI(n,t,v,r,g=i?.5*Math.abs(p.x-t.point.x):g,i)}else v=n.direction,n.direction=p.y>t.point.y?"Top":"Bottom",n.point=p,r=NI(n,t,v,r,g=i?.5*Math.abs(p.y-t.point.y):g,i);return r}(f,p,u,g)),l}(n,a,t,e,i,r),"Bezier"===n.type&&function Yre(n,t,e){if("Bezier"===n.type)if(0===n.segments.length){var i=e[0],r=e[e.length-1];if(t===Ae.One){var s=Math.min(20,.5*R.findLength(i,r)),o={angle:Gt(i,r),distance:s},a={angle:Gt(r,i),distance:s},l=R.direction(i,r),c=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,orientation:"Left"===l||"Right"===l?"Horizontal":"Vertical"},!0);n.segments.push(c)}else if(t===Ae.Two)o={angle:Gt(i,d=e[1]),distance:.5*R.findLength(i,d)},a={angle:Gt(r,d),distance:.5*R.findLength(r,d)},l=R.direction(i,d),c=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,orientation:"Left"===l||"Right"===l?"Horizontal":"Vertical"},!0),n.segments.push(c);else if(t===Ae.Three){var d={x:.5*((u=e[1]).x+(f=e[e.length-2]).x),y:.5*(u.y+f.y)},p=(o={angle:Gt(i,u),distance:.5*R.findLength(i,u)},a={angle:Gt(d,u),distance:.5*R.findLength(d,u)},R.direction(i,u)),v=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,point:d,orientation:"Left"===p||"Right"===p?"Horizontal":"Vertical"},!0);n.segments.push(v);var y={angle:Gt(d,f),distance:.5*R.findLength(d,f)},S={angle:Gt(r,f),distance:.5*R.findLength(r,f)},b=R.direction(d,f),w=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:y,vector2:S,orientation:"Left"===b||"Right"===b?"Horizontal":"Vertical"},!0);n.segments.push(w)}else if(t===Ae.Four){var D={x:.5*((u=e[1]).x+(f=e[2]).x),y:.5*(u.y+f.y)},A={x:.5*(f.x+(C=e[3]).x),y:.5*(f.y+C.y)};o={angle:Gt(i,u),distance:.5*R.findLength(i,u)},a={angle:Gt(D,u),distance:.5*R.findLength(D,u)},p=R.direction(i,u),v=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,point:D,orientation:"Left"===p||"Right"===p?"Horizontal":"Vertical"},!0),n.segments.push(v),y={angle:Gt(D,f),distance:.5*R.findLength(D,f)},S={angle:Gt(A,f),distance:.5*R.findLength(A,f)},b=R.direction(D,f),w=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:y,vector2:S,point:A,orientation:"Left"===b||"Right"===b?"Horizontal":"Vertical"},!0),n.segments.push(w);var x={angle:Gt(A,C),distance:.5*R.findLength(A,C)},P={angle:Gt(r,C),distance:.5*R.findLength(r,C)},L=R.direction(A,C),N=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:x,vector2:P,orientation:"Left"===L||"Right"===L?"Horizontal":"Vertical"},!0);n.segments.push(N)}else if(t===Ae.Five){var u,f,C,T=e[4],z=(D={x:.5*((u=e[1]).x+(f=e[2]).x),y:.5*(u.y+f.y)},A={x:.5*(f.x+(C=e[3]).x),y:.5*(f.y+C.y)},{x:.5*(C.x+T.x),y:.5*(C.y+T.y)});o={angle:Gt(i,u),distance:.5*R.findLength(i,u)},a={angle:Gt(D,u),distance:.5*R.findLength(D,u)},p=R.direction(i,u),v=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,point:D,orientation:"Left"===p||"Right"===p?"Horizontal":"Vertical"},!0),n.segments.push(v),y={angle:Gt(D,f),distance:.5*R.findLength(D,f)},S={angle:Gt(A,f),distance:.5*R.findLength(A,f)},b=R.direction(D,f),w=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:y,vector2:S,point:A,orientation:"Left"===b||"Right"===b?"Horizontal":"Vertical"},!0),n.segments.push(w),x={angle:Gt(A,C),distance:.5*R.findLength(A,C)},P={angle:Gt(z,C),distance:.5*R.findLength(z,C)},L=R.direction(A,C),N=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:x,vector2:P,point:z,orientation:"Left"===L||"Right"===L?"Horizontal":"Vertical"},!0),n.segments.push(N);var U={angle:Gt(z,T),distance:.5*R.findLength(z,T)},B={angle:Gt(r,T),distance:.5*R.findLength(r,T)},j=R.direction(z,T),oe=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:U,vector2:B,orientation:"Left"===j||"Right"===j?"Horizontal":"Vertical"},!0);n.segments.push(oe)}else c=new fs(n,"segments",{type:"Bezier"},!0),n.segments.push(c)}else for(var ue=0;ue=13?13:n.connectorSpacing<=1?1:n.connectorSpacing}function Gt(n,t){var i=R.findLength({x:t.x,y:n.y},t),r=R.findLength(t,n),s=Math.asin(i/r);return s=180*s/Math.PI,n.xt.y&&(s=360-s):s=n.y0)for(var l=1;lc)&&(s=c,a=h),s>=0&&s<=1)break}}return a}function w3(n,t){var c,d,u,f,p,g,S,b,M,w,D,e=n.x1,i=n.y1,r=n.x2,s=n.y2,o=t.x1,a=t.y1,l=t.x2,h=t.y2;if(w=(c=s-i)*l+(u=e-r)*h+(p=r*i-e*s),0!==(M=c*o+u*a+p)&&0!==w&&C3(M,w)||(b=(d=h-a)*r+(f=o-l)*s+(g=l*a-o*h),0!==(S=d*e+f*i+g)&&0!==b&&C3(S,b)))return null;var A=c*f-d*u;return 0===A?null:(A<0?-A/2:A/2,0,{x:(D=u*g-f*p)<0?(D-0)/A:(D+0)/A,y:(D=d*p-c*g)<0?(D-0)/A:(D+0)/A})}function C3(n,t){return n*t>=0}function E3(n,t,e){switch(t.direction){case"Left":t.point.x>n.left&&(e=t.point.x-n.left>e?t.point.x-n.left+e:e);break;case"Right":t.point.xe?n.right-t.point.x+e:e);break;case"Top":t.point.y>n.top&&(e=t.point.y-n.top>e?t.point.y-n.top+e:e);break;case"Bottom":t.point.ye?n.bottom-t.point.y+e:e)}return e}function kl(n,t){var e;switch(n.direction){case"Left":case"Right":var i={x:t.point.x,y:n.point.y};e=R.equals(n.point,i)||R.equals(t.point,i)?[n.point,t.point]:[n.point,i,t.point];break;case"Top":case"Bottom":var r={x:n.point.x,y:t.point.y};e=R.equals(n.point,r)||R.equals(t.point,r)?[n.point,t.point]:[n.point,r,t.point]}return e}function Ys(n,t,e,i,r,s){void 0===s&&(s=!1),i||(i=20),s&&t.direction!==e.direction&&(i="Left"===t.direction||"Right"===t.direction?Math.floor(.5*Math.abs(t.point.x-e.point.x)):Math.floor(.5*Math.abs(t.point.y-e.point.y)));var l,h,u,o=n.sourcePortWrapper,c=e.point.x-t.point.x,d=e.point.y-t.point.y;if(!r&&(Math.abs(c)<.001||Math.abs(d)<.001)&&void 0===e.direction)return[t.point,e.point];if(void 0===n.targetWrapper&&Math.abs(c)<=31&&Math.abs(d)<=31){if("Left"===t.direction||"Right"===t.direction?Math.abs(d)<12&&(t.direction=t.point.y>e.point.y?"Top":"Bottom"):Math.abs(c)<12&&(t.direction=t.point.x>e.point.x?"Left":"Right"),Math.abs(c)>12||Math.abs(d)>12)return kl(t,e);i+=5}return"Left"===t.direction||"Right"===t.direction?("Right"===t.direction?(void 0!==e.direction&&"Right"===e.direction&&(i=Math.max(t.point.x,e.point.x)-t.point.x+i),t.point.x>e.point.x&&void 0===o&&(i=-i)):(void 0!==e.direction&&"Left"===e.direction&&(i=t.point.x-Math.min(t.point.x,e.point.x)+i),(t.point.x>e.point.x||void 0!==o||"Left"===t.direction)&&(i=-i)),u=e.point.y-t.point.y,l=Fn(t.point,i,0),0!=(u=e.point.y-l.y)&&(h=Fn(l,e.point.y-l.y,90))):("Top"===t.direction||"Bottom"===t.direction)&&("Bottom"===t.direction?void 0!==e.direction&&"Bottom"===e.direction&&(i=Math.max(t.point.y,e.point.y)-t.point.y+i):(void 0!==e.direction&&"Top"===e.direction&&(i=t.point.y-Math.min(t.point.y,e.point.y)+i),(t.point.y>e.point.y||void 0!==o||"Top"===t.direction)&&(i=-i)),u=e.point.x-t.point.x,l=Fn(t.point,i,90),0!=(u=e.point.x-l.x)&&(h=Fn(l,e.point.x-l.x,0))),0===u?[t.point,e.point]:[t.point,l,h,e.point]}function NI(n,t,e,i,r,s){var o;switch(void 0===r&&(r=20),void 0===s&&(s=!1),void 0===e?(n.margin={left:2,right:2,top:2,bottom:2},t.margin={left:0,right:5,top:0,bottom:5},s&&(n.margin={left:10,right:10,top:10,bottom:10},t.margin={left:10,right:10,top:10,bottom:10},"Left"===n.direction?(r=Rx(n,t,e,r),n.corners.left-t.corners.right>=5&&(r=Math.abs(n.point.x-n.corners.left)+.5*Math.floor(n.corners.left-t.corners.right))):"Right"===n.direction?(r=Hx(n,t,r,e),t.corners.left-n.corners.right>=5&&(r=Math.abs(n.point.x-n.corners.right)+.5*Math.floor(t.corners.left-n.corners.right))):"Top"===n.direction?(r=zx(n,t,e,r),n.corners.top-t.corners.bottom>=5&&(r=Math.abs(n.point.y-n.corners.top)+.5*Math.floor(n.corners.top-t.corners.bottom))):"Bottom"===n.direction&&(r=Bx(n,t,r,e),t.corners.top-n.corners.bottom>=5&&(r=Math.abs(n.point.y-n.corners.bottom)+.5*Math.floor(t.corners.top-n.corners.bottom))))):("Bottom"===n.direction?s?t.corners.top-n.corners.bottom<20&&(r=t.corners.bottom-n.point.y+25):t.corners.top>n.corners.bottom&&t.corners.top-n.corners.bottom<20&&(r=(t.corners.top-n.corners.bottom)/2):"Top"===n.direction?s?n.corners.top-t.corners.bottom<20&&(r=n.point.y-t.corners.top+25):t.corners.bottomn.corners.right&&t.corners.left-n.corners.right<20&&(r=(t.corners.left-n.corners.right)/2):"Left"===n.direction&&(s?n.corners.left-t.corners.right<20&&(r=n.point.x-t.corners.left+25):t.corners.rightt.point.y||"Top"===t.direction&&n.point.yt.point.x||"Left"===t.direction&&n.point.xh||e.corners.top-e.margin.top<=i.point.y&&e.corners.bottom+e.margin.bottom>=i.point.y))if(!s||"Top"!==e.direction&&"Bottom"!==e.direction)c=Math.min(Math.abs(i.corners.left-e.corners.right)/2,20),h=e.corners.right-n.x+c;else{var c=Math.abs(i.corners.left-e.corners.right)/2;h=e.corners.right-n.x+c}else h="Top"===e.direction&&n.y>i.point.y||"Bottom"===e.direction&&n.y=e.corners.left-e.margin.left&&n.x<=e.corners.right+e.margin.right?Math.min(i.corners.left,e.corners.left)-n.x-20:i.corners.left-n.x-20;break;case"Right":if(e.corners.left-e.margin.left>i.corners.right+i.margin.right&&(e.corners.left-e.margin.right-i.corners.right>h||e.corners.top-e.margin.top<=i.point.y&&e.corners.bottom+e.margin.bottom>=i.point.y))if(!s||"Top"!==e.direction&&"Bottom"!==e.direction)c=Math.min(Math.abs(e.corners.left-i.corners.right)/2,20),h=e.corners.left-n.x-c;else{c=Math.abs(e.corners.left-i.corners.right)/2;h=e.corners.left-n.x-c}else h="Top"===e.direction&&n.y>i.point.y||"Bottom"===e.direction&&n.y=e.corners.left-e.margin.left&&n.x<=e.corners.right+e.margin.right?Math.max(i.corners.right,e.corners.right)-n.x+20:i.corners.right-n.x+20}o=Fn(n,h,0),a=Fn(o,i.point.y-n.y,90),l=i.point}else if("vertical"===t){switch(i.direction){case"Top":e.corners.bottom+e.margin.bottomh||e.corners.left-e.margin.left<=i.point.x&&e.corners.right+e.margin.right>=i.point.x)?!s||"Right"!==e.direction&&"Left"!==e.direction?(c=Math.min(Math.abs(i.corners.top-e.corners.bottom)/2,20),h=e.corners.bottom-n.y+c):(c=Math.abs(i.corners.top-e.corners.bottom)/2,h=e.corners.bottom-n.y+c):h="Left"===e.direction&&n.x>i.point.x||"Right"===e.direction&&n.x=e.corners.top-e.margin.top&&n.y<=e.corners.bottom+e.margin.bottom?Math.min(i.corners.top,e.corners.top)-n.y-20:i.corners.top-n.y-20;break;case"Bottom":e.corners.top-e.margin.top>i.corners.bottom+i.margin.bottom&&(e.corners.top-e.margin.top-i.corners.bottom>h||e.corners.left-e.margin.left<=i.point.x&&e.corners.right+e.margin.right>=i.point.x)?!s||"Right"!==e.direction&&"Left"!==e.direction?(c=Math.min(Math.abs(e.corners.top-i.corners.bottom)/2,20),h=e.corners.top-n.y-c):(c=Math.abs(e.corners.top-i.corners.bottom)/2,h=e.corners.top-n.y-c):h="Left"===e.direction&&n.x>i.point.x||"Right"===e.direction&&n.x=e.corners.top-e.margin.top&&n.y<=e.corners.bottom+e.margin.bottom?Math.max(i.corners.bottom,e.corners.bottom)-n.y+20:i.corners.bottom-n.y+20}o=Fn(n,h,90),a=Fn(o,i.point.x-n.x,0),l=i.point}r.push(o),r.push(a),r.push(l)}function zx(n,t,e,i){return n.corners.top-n.margin.top>t.corners.top+t.margin.top&&n.corners.top-n.margin.top<=t.corners.bottom+t.margin.bottom?(("Right"===t.direction&&n.point.xt.point.x)&&(i+=n.corners.top-t.corners.top),i+=n.point.y-n.corners.top):i+=void 0!==e&&"Left"!==e&&"Right"===t.direction&&n.point.xt.corners.left-t.margin.left&&n.corners.left-n.margin.left<=t.corners.right+t.margin.right?(("Bottom"===t.direction&&n.point.yt.point.y)&&(i+=n.corners.left-t.corners.left),i+=n.point.x-n.corners.left):i+=void 0!==e&&"Top"!==e&&"Bottom"===t.direction&&n.point.y=t.corners.left-t.margin.left?(("Bottom"===t.direction&&n.point.yt.point.y)&&(e+=t.corners.right-n.corners.right),e+=n.corners.right-n.point.x):e+=void 0!==i&&"Top"!==i&&"Bottom"===t.direction&&n.point.y=t.corners.top-t.margin.top?(("Right"===t.direction&&n.point.xt.point.x)&&(e+=t.corners.bottom-n.corners.bottom),e+=n.corners.bottom-n.point.y):e+=void 0!==i&&"Left"!==i&&"Right"===t.direction&&n.point.xp&&d=u&&d=f&&d<=p?"Left":"Right"}function _n(n){switch(n){case"Top":return"Bottom";case"Bottom":return"Top";case"Left":return"Right";case"Right":return"Left"}return"auto"}var A3=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Nc=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},OI=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return A3(t,n),Nc([I()],t.prototype,"width",void 0),Nc([I()],t.prototype,"height",void 0),t}(Ee),Gre=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return A3(t,n),Nc([I()],t.prototype,"width",void 0),Nc([I()],t.prototype,"height",void 0),Nc([I()],t.prototype,"fit",void 0),Nc([I()],t.prototype,"description",void 0),Nc([I()],t.prototype,"template",void 0),Nc([I()],t.prototype,"tooltip",void 0),t}(Ee),Xre=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Pl=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},L3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Xre(t,n),Pl([I("")],t.prototype,"id",void 0),Pl([I(Number.MIN_VALUE)],t.prototype,"zIndex",void 0),Pl([re({},Jn)],t.prototype,"margin",void 0),Pl([I(!0)],t.prototype,"visible",void 0),Pl([re({},Td)],t.prototype,"tooltip",void 0),Pl([I(!1)],t.prototype,"excludeFromLayout",void 0),Pl([I()],t.prototype,"addInfo",void 0),Pl([I("None")],t.prototype,"flip",void 0),Pl([I("All")],t.prototype,"flipMode",void 0),Pl([re({},Gre)],t.prototype,"symbolInfo",void 0),t}(Ee),qre=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),es=function(n){function t(e,i,r,s){var o=n.call(this)||this;return o.data="",o.nodeId="",o.annotationId="",o.diagramId="",o.diagramId=i,o.nodeId=e,o.annotationId=r,o.templateFn=GF(s),o}return qre(t,n),t.prototype.getNodeTemplate=function(){return this.templateFn},Object.defineProperty(t.prototype,"content",{get:function(){return this.data},set:function(e){this.data=e,this.canReset||(this.canReset=!0,this.isTemplate||(this.template=Fh(this,!0)),this.canReset=!1,this.isDirt=!0)},enumerable:!0,configurable:!0}),t}(hs),Fx=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),cs=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},N3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Fx(t,n),cs([I("")],t.prototype,"id",void 0),cs([I("transparent")],t.prototype,"fill",void 0),cs([I("black")],t.prototype,"iconStrokeColor",void 0),cs([I(0)],t.prototype,"iconStrokeWidth",void 0),cs([I(!0)],t.prototype,"visibility",void 0),cs([I(10)],t.prototype,"width",void 0),cs([I(10)],t.prototype,"height",void 0),cs([I("transparent")],t.prototype,"handleStrokeColor",void 0),cs([I(1)],t.prototype,"handleStrokeWidth",void 0),cs([I("")],t.prototype,"pathData",void 0),cs([I(0)],t.prototype,"cornerRadius",void 0),cs([re({left:0,right:0,top:0,bottom:0},Jn)],t.prototype,"padding",void 0),cs([re({},Td)],t.prototype,"tooltip",void 0),t}(Ee),O3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Fx(t,n),cs([re({x:0,y:0},R)],t.prototype,"offset",void 0),cs([re({},Jn)],t.prototype,"margin",void 0),t}(N3),kI=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Fx(t,n),cs([I(.5)],t.prototype,"offset",void 0),cs([I("Center")],t.prototype,"alignment",void 0),cs([re({x:0,y:0},R)],t.prototype,"displacement",void 0),t}(N3);function Ad(n){return n?n instanceof Kn||n instanceof Or?n.constraints&Nr.Select:n instanceof de?n.constraints&qe.Select:n.constraints&ie.Select:1}function ro(n){return n?n instanceof Kn||n instanceof Or?n.constraints&Nr.Drag:n instanceof de?n.constraints&qe.Drag:n instanceof ei?1:n.constraints&ie.Drag:1}function $re(n,t){return n instanceof de?n.constraints&qe.PointerEvents:n.constraints&ie.PointerEvents}function PI(n){return n instanceof de?n.constraints&qe.Delete:n.constraints&ie.Delete}function zI(n){return n.constraints&qe.DragSourceEnd}function RI(n){return n.constraints&qe.DragTargetEnd}function HI(n){return n.constraints&qe.DragSegmentThumb}function BI(n){return n instanceof Kn||n instanceof Or?n.constraints&Nr.Rotate:n.constraints&ie.Rotate}function FI(n){return n.constraints&ie.Shadow}function ua(n){return n instanceof te&&n.constraints&ie.InConnect?n.constraints&ie.InConnect:0}function zh(n){return n&&n.constraints&&!(n.constraints&oi.None)&&n.constraints&oi.InConnect?n.constraints&oi.InConnect:0}function Rh(n){return n instanceof te&&n.constraints&ie.OutConnect?n.constraints&ie.OutConnect:0}function Ld(n){return n&&n.constraints&&!(n.constraints&oi.None)&&n.constraints&oi.OutConnect?n.constraints&oi.OutConnect:0}function zl(n,t){var e=0;return n instanceof Kn||n instanceof Or?e=n.constraints&Nr.Resize:n&&("SouthEast"===t?e=n.constraints&ie.ResizeSouthEast:"East"===t?e=n.constraints&ie.ResizeEast:"NorthEast"===t?e=n.constraints&ie.ResizeNorthEast:"South"===t?e=n.constraints&ie.ResizeSouth:"North"===t?e=n.constraints&ie.ResizeNorth:"SouthWest"===t?e=n.constraints&ie.ResizeSouthWest:"West"===t?e=n.constraints&ie.ResizeWest:"NorthWest"===t&&(e=n.constraints&ie.ResizeNorthWest)),e}function _I(n){return n instanceof de?n.constraints&qe.AllowDrop:n.constraints&ie.AllowDrop}function Ds(n){return n.constraints&nt.Virtualization}function Vv(n){return n.tool&ri.SingleSelect}function Wv(n){return n.tool&ri.MultipleSelect}function Oc(n){return n.tool&ri.ZoomPan}function UI(n){return n.tool&ri.ContinuousDraw}function k3(n){return n.tool&ri.DrawOnce}function jI(n){return n.tool&ri.SingleSelect||n.tool&ri.MultipleSelect}function Yv(n){return n.constraints&nt.UserInteraction}function P3(n){return n.constraints&nt.ZoomTextEdit}function Qv(n){return function ine(n){return n.constraints&nt.ApiUpdate}(n)||n.diagramActions&ee.ToolAction}function _x(n,t){return n.constraints&oi.Draw}function Ux(n,t){return n.constraints&oi.Drag}function VI(n){return!(n&Ga.DrawSelectorBorder)}function z3(n){return!!(n&Ga.PreventRenderSelector)}var jx=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Gv=function(n){function t(){var e=null!==n&&n.apply(this,arguments)||this;return e.childTable=[],e.cellStyle={},e.desiredRowHeight=[],e.desiredCellWidth=[],e}return jx(t,n),t.prototype.rowDefinitions=function(){return this.rowDefns},t.prototype.columnDefinitions=function(){return this.colDefns},t.prototype.addObject=function(e,i,r,s,o){if(this.rows.length>=i){var a=this.rows[parseInt(i.toString(),10)];if(a.cells.length>r){o=o||1,s=s||1;var l=a.cells[parseInt(r.toString(),10)];l.columnSpan=Math.max(o,l.columnSpan),l.rowSpan=Math.max(s,l.rowSpan);var h=new ane;(h=e).rowId=i,h.columnId=r,h.columnSpan=o,this.childTable[h.id]=h,this.addObjectToCell(h,l)}}},t.prototype.addObjectToCell=function(e,i){i.children||(i.children=[]),e.style.strokeColor="black",e.style.strokeWidth=1,i.children.push(e)},t.prototype.updateProperties=function(e,i,r,s){this.offsetX=e,this.offsetY=i,this.width=r,this.height=s},t.prototype.setDefinitions=function(e,i){this.rowDefns=e,this.colDefns=i,this.children=[],this.rows=this.rows||[];for(var r=0;r0){for(var h=0;hi&&this.updateRowHeight(e,l,!1)}},t.prototype.setTextRefresh=function(e){if(e.children&&e.children.length)for(var i=e.children,r=0;ri&&this.updateColumnWidth(e,a,!1)}},t.prototype.calculateCellWidth=function(e){for(var i,r,s,o=0;os.bounds.width&&(0===s.children.length||void 0===s.children[0].maxWidth)?s.outerBounds.width:s.bounds.width,i=i?is.bounds.height?s.outerBounds.height:s.bounds.height,i=i?i0?e.children[0]:void 0;if(a&&1===e.columnSpan){o="Width"===i?a.bounds.right:a.bounds.bottom,s||(s="Width"===i?a.bounds.width:a.bounds.height);for(var l=0;lo){var d=c-o+("Width"===i?a.bounds.width:a.bounds.height);s&&(s=s0?this.rowDefns.splice(e,0,i):this.rowDefns.push(i);var s=new R3;s.cells=[],(new Nd).width=this.width,this.addCellInRow(this.colDefns,i,s),e>this.rows.length-1?this.rows.push(s):this.rows.splice(e,0,s),r&&(this.measure(new me(this.width,this.height)),this.arrange(this.desiredSize))},t.prototype.addColumn=function(e,i,r){var s,o,a,l,h=this.rows;this.colDefns.length>0?this.colDefns.splice(e,0,i):this.colDefns.push(i),void 0!==this.width&&(this.width+=i.width);for(var c=0;cs.cells.length-1?s.cells.push(l):s.cells.splice(e,0,l),this.children.push(l);r&&(this.measure(new me(this.width,this.height)),this.arrange(this.desiredSize))},t.prototype.removeRow=function(e){var i,r,o=this.rows[parseInt(e.toString(),10)];this.height-=this.rowDefns[parseInt(e.toString(),10)].height;for(var a=0;a0){var r=0,s=0;i=new me(0,0),this.calculateSize();for(var o=0,a=this.rows;o0){for(var o=this.offsetX-e.width*this.pivot.x,a=this.offsetY-e.height*this.pivot.y,l=o,h=0,c=this.rows;h1&&this.children.splice(this.children.indexOf(p)+1,p.columnSpan-1),p.rowSpan>1)for(y=s,S=0;y+p.rowSpan-10){for(var c=0;c0?1:0,v=0;v0||a.outEdges.length>0))for(f=a.inEdges.concat(a.outEdges),s=0;s0)for(o=0;o1)for(a=1;a0))if(h=n.wrapper.children[0],"Horizontal"===e.orientation)for(o=e.header&&e.hasHeader?h.rows[1]:h.rows[0],r=0;r0){var e=void 0;t.lineRoutingModule&&t.constraints&nt.LineRouting&&t.lineRoutingModule.renderVirtualRegion(t,!0);for(var i=0;i0?o+1:o)].height=t.wrapper.height;else if(t.isPhase)for(l[t.rowIndex-o].offset=t.wrapper.height,p=0;p0?1:0)].width=t.wrapper.width}function YI(n,t){var i=n.shape,r=i.header&&i.hasHeader?1:0;return"Horizontal"===i.orientation?t.rowIndex-(r+=i.phases.length>0?1:0):t.columnIndex-(i.phaseSize&&i.phases.length>0?1:0)}function QI(n){var t=0,e=n.shape;return"Horizontal"===e.orientation&&(t=e.header&&e.hasHeader?1:0),e.phases.length>0&&e.phaseSize&&(t+=1),t}function GI(n,t,e,i){var r=n.shape;if(r.phases.length>0){var s=t.nameTable[r.phases[parseInt(i.toString(),10)].header.id];s&&s.maxWidth0?u+1:u);var w=kc(n,o),C=void 0!==i?i:l.lanes.length;if(u+=C,r={element:M,cause:n.diagramActions,diagramAction:n.getDiagramAction(n.diagramActions),state:"Changing",type:"Addition",cancel:!1,laneIndex:C},n.triggerEvent(Ce.collectionChange,r),!r.cancel){if(c){var D=new Xv;D.height=e.height,o.addRow(u,D,!1),s.height=void 0!==s.height?s.height+e.height:s.height,s.wrapper.height=o.height=s.height}else{var A=new Nd;A.width=e.width,o.addColumn(C+1,A,!1),s.width&&(s.width+=e.width,s.wrapper.width=o.width=s.width),n.diagramActions&ee.UndoRedo||(o.rows[0].cells[0].columnSpan+=1)}n.diagramActions&ee.UndoRedo||(M.id=""===M.id?Qe():M.id),void 0!==i?l.lanes.splice(i,0,M):l.lanes.push(M),r={element:M,cause:n.diagramActions,diagramAction:n.getDiagramAction(n.diagramActions),state:"Changed",type:"Addition",cancel:!1,laneIndex:C},n.triggerEvent(Ce.collectionChange,r),B3(o,n,s,u,C,c),h="Horizontal"===l.orientation?n.nameTable[o.rows[parseInt(u.toString(),10)].cells[0].children[0].id]:l.header&&l.hasHeader?n.nameTable[o.rows[1].cells[parseInt(u.toString(),10)].children[0].id]:n.nameTable[o.rows[0].cells[parseInt(u.toString(),10)].children[0].id],n.diagramActions&ee.UndoRedo||(d={type:"LaneCollectionChanged",changeType:"Insert",undoObject:$(M),redoObject:$(h),category:"Internal"},n.addHistoryEntry(d)),Zf(n,s,"Horizontal"===l.orientation?u:l.header&&l.hasHeader?1:0),$f(s),Pc(n,s);var P=!1;if((f=e.children)&&f.length>0)for(p=0;p0){var o=t.children[0],a=n.nameTable[o.id];(function vne(n,t,e){return n.left-(e.left||0)<=t.x&&n.right+(e.right||0)>=t.x&&n.top-(e.top||0)<=t.y&&n.bottom+(e.bottom||0)>=t.y})(o.bounds,e,r)&&(n.addChild(a,i),s=!0)}return s}function mne(n,t,e){if("SwimLane"===t.shape.type){var i=void 0,r=void 0,s=void 0,a=void 0,l=void 0,h=void 0,c=t.wrapper.bounds.x,d=t.wrapper.bounds.y,u=t.shape,f=u.padding,p=u.phases,g=void 0,v=t.wrapper.children[0],y="Horizontal"===u.orientation;if(i=u.header&&u.hasHeader?0:-1,u.phases.length>0&&(i+=1),e.offset>(y?u.lanes[0].header.width:u.lanes[0].header.height)){for(h=0;he.offset){if(g=h>0?e.offset-(h>0?p[h-1]:s).offset:e.offset,y){var b=v.columnDefinitions()[parseInt(h.toString(),10)];b.width-=g,(a=n.nameTable[u.phases[parseInt(h.toString(),10)].header.id]).maxWidth=a.wrapper.maxWidth=b.width,v.updateColumnWidth(h,b.width,!1);var M=new Nd;M.width=g,l=h,v.addColumn(h,M,!1);break}var w=v.rowDefinitions()[h+i];w.height-=g,a=n.nameTable[u.phases[parseInt(h.toString(),10)].header.id],v.updateRowHeight(h+i,w.height,!1);var C=new Xv;C.height=g,l=h,v.addRow(h+i,C,!1);break}if(n.diagramActions&ee.UndoRedo&&void 0===l&&(D=n.historyManager.currentEntry.next).isLastPhase&&function yne(n,t,e,i,r,s){var a=t.shape.phases[n-2],l=e.previousPhase.offset;if(r){var h=i.columnDefinitions()[n-1],c=new Nd;n>1?(c.width=h.width-(l-a.offset),h.width=l-a.offset):(c.width=h.width-l,h.width=l),i.updateColumnWidth(n-1,h.width,!1),i.addColumn(n,c,!1)}else{h=i.rowDefinitions()[parseInt(n.toString(),10)];var d=new Xv;n>1?(d.height=e.undoObject.offset-l,h.height=l-a.offset):(d.height=h.height-l,h.height=l),i.updateRowHeight(n,h.height,!1),i.addRow(1+n,d,!1)}}(l=p.length,t,D,v,y),l>=0){var A=new pb(t.shape,"phases",e,!0);if(n.diagramActions&ee.UndoRedo||(A.id+=Qe()),u.phases.splice(l,0,A),Vx(v,n,t,i,y,l),y){if(r=n.nameTable[v.rows[parseInt(i.toString(),10)].cells[parseInt(l.toString(),10)].children[0].id],0===l&&u.header&&u.hasHeader){v.rows[0].cells[0].children=v.rows[0].cells[1].children,v.rows[0].cells[1].children=[];for(var x=v.rows[0],P=0;Pl+1){var O=n.nameTable[v.rows[parseInt(i.toString(),10)].cells[l+1].children[0].id];v.updateColumnWidth(l+1,L[l+1].width,!0,f),O.maxWidth=O.wrapper.maxWidth=L[l+1].width}t.width=t.wrapper.width=t.wrapper.children[0].width=v.width}else{r=n.nameTable[v.rows[i+l].cells[0].children[0].id];var N=v.rowDefinitions(),T=N[i+l].height;(function Ine(n,t,e,i,r){for(var o,a,l=e.rows[parseInt(i.toString(),10)],h=e.rows[i+1],c=e.rows[i-1],d=1;di+l+1&&v.updateRowHeight(i+l+1,T=N[i+l+1].height,!0,f),t.height=t.wrapper.height=t.wrapper.children[0].height=v.actualSize.height}if($f(t),t.width=t.wrapper.actualSize.width,Pc(n,t),n.drag(t,c-t.wrapper.bounds.x,d-t.wrapper.bounds.y),WI(t,n),n.commandHandler.select(r),!(n.diagramActions&ee.UndoRedo)){var D={type:"PhaseCollectionChanged",changeType:"Insert",undoObject:$(A),redoObject:$(r),category:"Internal"};n.addHistoryEntry(D)}n.updateDiagramObject(t)}}}}function V3(n,t,e,i,r,s,o){var a,l,p,h=t.shape,c="Horizontal"===h.orientation,d=t.wrapper.children[0],g=c?s:o;e?(a=c?e.bounds.x+e.bounds.width:e.bounds.x,l=c?e.bounds.y:e.bounds.y+e.bounds.height):(a=d.bounds.x,l=r.bounds.y);var v=new Ne(a,l,i.desiredCellWidth,i.desiredCellHeight),S=qv(n,0,t,{id:t.id+(c?h.lanes[g-2]:h.lanes[g-1]).id+Qe()[0],rowIndex:s,columnIndex:o,width:i.minWidth,height:i.minHeight,style:(c?h.lanes[g-2]:h.lanes[g-1]).style,constraints:ie.Default|ie.AllowDrop,container:{type:"Canvas",orientation:c?"Horizontal":"Vertical"}},!1,!1,!0);if(S.children[0].isCalculateDesiredSize=!1,d.addObject(S,s,o),r&&r.children&&r.children.length)for(p=0;p1)for(var p=1;ph.margin.left&&(h.margin.left=f)):(h.margin.top-=e.desiredCellHeight,f>h.margin.top&&(h.margin.top=f)))}(n,r,i,v,S,c,e)}function W3(n,t,e){if("SwimLane"===t.shape.type&&("ResizeSouth"===e||"ResizeEast"===e)){var i=t.shape,r=t.wrapper.children[0],s=void 0,o=void 0;"ResizeSouth"===e?"Vertical"===i.orientation?s=r.rows[r.rows.length-1].cells[0]:(o=r.rows.length-1,s=r.rows[parseInt(o.toString(),10)].cells[r.rows[parseInt(o.toString(),10)].cells.length-1]):(o=i.header&&i.hasHeader?1:0,s=r.rows[parseInt(o.toString(),10)].cells[r.rows[parseInt(o.toString(),10)].cells.length-1]),n.commandHandler.select(n.nameTable[s.children[0].id])}}function XI(n,t,e,i,r,s){var o,a,l,c,u,f,p,d=Qe(),g=n.shape,v=g.phases,y=n.offsetX-n.wrapper.actualSize.width/2,S=n.offsetY-n.wrapper.actualSize.height/2;if("Vertical"===g.orientation&&(S+=g.header&&g.hasHeader?g.header.height:0),!s)for(r||(n.id+=d,g&&g.header&&g.hasHeader?g.header.id+=d:g.header=void 0),o=0;v&&o0&&s.columnIndex>0||s.isLane)?(a=function Lne(n,t,e){for(var i=new Ne,r="SwimLane"===n.shape.type?n.wrapper.children[0].rows:n.wrapper.rows,s=e?1:0;s=0;a--)i?i.id===o.children[parseInt(a.toString(),10)].id&&o.children.splice(a,1):(n.removeDependentConnector(o.children[parseInt(a.toString(),10)]),n.diagramActions&ee.UndoRedo||(n.diagramActions=n.diagramActions|ee.UndoRedo,s=!0),n.remove(o.children[parseInt(a.toString(),10)]),o.children.splice(a,1),s&&(n.diagramActions=n.diagramActions&~ee.UndoRedo))}function Mne(n){return n.children[0]}function Jv(n,t){t&&(n.nodes.splice(n.nodes.indexOf(t),1),n.removeFromAQuad(t),n.removeObjectsFromLayer(t),delete n.nameTable[t.id],n.removeElements(t))}function Q3(n,t,e,i){var r;if("SwimLane"===e.shape.type){var s=e.shape,o=void 0;if(1===s.lanes.length)n.remove(e);else{var a=e.wrapper.bounds.x,l=e.wrapper.bounds.y,h=void 0,c=void 0,d=void 0,u=void 0,p=e.wrapper.children[0];if(o=i?s.lanes.indexOf(i):YI(e,t),r={element:t,cause:n.diagramActions,diagramAction:n.getDiagramAction(n.diagramActions),state:"Changing",type:"Removal",cancel:!1,laneIndex:o},n.triggerEvent(Ce.collectionChange,r),!r.cancel){var g=s.lanes[parseInt(o.toString(),10)],v=g.children;g.children=[];for(var y=0;y0)for(u=0;u0)for(u=0;u0)for(e=0;e1){c===l.phases.length-1&&(o=!0,a=$(l.phases[c-1]));var u=$(l.phases[parseInt(c.toString(),10)]);if(l.phases.splice(c,1),!(n.diagramActions&ee.UndoRedo)){var f={type:"PhaseCollectionChanged",changeType:"Remove",undoObject:u,previousPhase:a,redoObject:$(t),category:"Internal",isLastPhase:o};n.addHistoryEntry(f)}"Horizontal"===l.orientation?function Cne(n,t,e,i){var r,s,o,a,l,h,c,d,u,f,p,g;for(i=void 0!==i?i:e.columnIndex,c=0;c1&&(s=r.cells[parseInt(i.toString(),10)],l=(o=r.cells.length-1===i?r.cells[i-1]:r.cells[i+1]).children[0],s.children.length>0))if(p=n.nameTable[(a=s.children[0]).id],0===o.children.length&&s.children.length>0)o.children=s.children,o.columnSpan=s.columnSpan-1;else{for(d=0;d0){var M=s.children[0],w=n.nameTable[M.id];if(i=e.x&&a.bounds.y<=e.y&&a.bounds.bottom>=e.y){var l=void 0,h=a.bounds.y,c=a.bounds.x,d=n.nameTable[r.parentId]||r;if("SwimLane"===d.shape.type)o=em(r,d,t,n,!0);else{var f=n.nameTable[r.parentId]||r,p=f.shape;l=f.wrapper,a.actualSize.widtha.outerBounds.x)&&(void 0!==r.rowIndex?(l.updateColumnWidth(r.columnIndex,a.outerBounds.width,!0),"Horizontal"===p.orientation&&p.phaseSize&&GI(f,n,a,r.columnIndex),Pc(n,f),n.drag(f,c-a.bounds.x,h-a.bounds.y)):n.scale(r,1+(a.outerBounds.width-a.actualSize.width)/a.actualSize.width,1,a.outerBounds.xa.outerBounds.y)&&(void 0!==r.rowIndex?(l.updateRowHeight(r.rowIndex,a.outerBounds.height,!0),n.drag(f,c-a.bounds.x,h-a.bounds.y)):n.scale(r,1,1+(a.outerBounds.height-a.actualSize.height)/a.actualSize.height,a.outerBounds.y=e.x&&a.bounds.y<=e.y&&a.bounds.bottom>=e.y)&&!(t.constraints&ie.AllowMovingOutsideLane)){var l=$(t);n.clearSelection(),$3(n,t),t.parentId="",t.parentObj=n,t.propName="nodes";var h={type:"ChildCollectionChanged",category:"Internal",undoObject:l,redoObject:$(t)};n.addHistoryEntry(h),n.commandHandler.isContainer&&(n.commandHandler.isContainer=!1,n.endGroupAction()),Z3(t,n)}n.protectPropertyChange(o)}}function qI(n,t){var e,i,r;return n.enableServerDataBinding(!1),ce()||(n.selectedObject.helperObject?r=n.selectedObject.helperObject:(n.selectedItems.nodes.length>0||n.selectedItems.connectors.length>0)&&(t instanceof ei&&t.nodes.length+t.connectors.length===1?(e=t.nodes.length>0?t.nodes[0]:t.connectors[0],i=n.selectedItems.wrapper.children[0]):(e=t,i=n.selectedItems.wrapper),n.selectedObject.actualObject=e,!n.currentSymbol&&(e.isLane&&Gx(e,n)&&Dn(n,e)||!e.isLane&&Dn(n,e)||n.constraints&nt.LineRouting&&n.selectedItems.nodes.length>0))&&(r=function Nne(n,t){for(var e,i={},r=0,s=Object.keys(t);r=t.x-e&&n.x<=t.x+e&&n.y>=t.y-e&&n.y<=t.y+e}function $a(n){return n.selectedItems.nodes.length>0||n.selectedItems.connectors.length>0}function K3(n){return 1===n.selectedItems.connectors.length&&!n.selectedItems.nodes.length}function _r(n,t,e,i){if(void 0===e&&(e=!0),t instanceof ei)return!0;if(t instanceof te)for(;t;){if(-1!==n.selectedItems.nodes.indexOf(t)&&void 0===n.selectedItems.annotation)return!0;if(e)break;t=n.nameTable[t.parentId]}else if(t instanceof de){if(-1!==n.selectedItems.connectors.indexOf(t)&&void 0===n.selectedItems.annotation)return!0}else if((t instanceof Kn||t instanceof Or)&&n.selectedItems.annotation&&n.selectedItems.wrapper.children[0].id===i.id)return!0;return!1}var Xx={None:"default",Rotate:"crosshair",Select:"default",Drag:"move",ResizeWest:"w-resize",ResizeEast:"e-resize",ResizeSouth:"s-resize",ResizeNorth:"n-resize",Draw:"crosshair",PortDraw:"crosshair",ResizeNorthEast:"ne-resize",ResizeNorthWest:"nw-resize",ResizeSouthEast:"se-resize",ResizeSouthWest:"sw-resize",ConnectorSourceEnd:"move",ConnectorTargetEnd:"move",BezierSourceThumb:"move",BezierTargetThumb:"move",OrthoThumb:"move",SegmentEnd:"move",Pan:"grab",Hyperlink:"pointer",PortDrag:"pointer",LabelSelect:"pointer",LabelDrag:"move",LabelRotate:"crosshair",LabelResizeWest:"w-resize",LabelResizeEast:"e-resize",LabelResizeSouth:"s-resize",LabelResizeNorth:"n-resize",LabelResizeNorthEast:"ne-resize",LabelResizeNorthWest:"nw-resize",LabelResizeSouthEast:"se-resize",LabelResizeSouthWest:"sw-resize"},ds=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),kd=function(n,t,e,i){return new(e||(e=Promise))(function(r,s){function o(h){try{l(i.next(h))}catch(c){s(c)}}function a(h){try{l(i.throw(h))}catch(c){s(c)}}function l(h){h.done?r(h.value):new e(function(c){c(h.value)}).then(o,a)}l((i=i.apply(n,t||[])).next())})},Pd=function(n,t){var i,r,s,o,e={label:0,sent:function(){if(1&s[0])throw s[1];return s[1]},trys:[],ops:[]};return o={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function a(h){return function(c){return function l(h){if(i)throw new TypeError("Generator is already executing.");for(;e;)try{if(i=1,r&&(s=2&h[0]?r.return:h[0]?r.throw||((s=r.return)&&s.call(r),0):r.next)&&!(s=s.call(r,h[1])).done)return s;switch(r=0,s&&(h=[2&h[0],s.value]),h[0]){case 0:case 1:s=h;break;case 4:return e.label++,{value:h[1],done:!1};case 5:e.label++,r=h[1],h=[0];continue;case 7:h=e.ops.pop(),e.trys.pop();continue;default:if(!(s=(s=e.trys).length>0&&s[s.length-1])&&(6===h[0]||2===h[0])){e=0;continue}if(3===h[0]&&(!s||h[1]>s[0]&&h[1]-1&&(r=i.fixedUserHandles[parseInt(o.toString(),10)]);this.commandHandler.triggerEvent(Ce.fixedUserHandleClick,{fixedUserHandle:r,element:e.source}),n.prototype.mouseUp.call(this,e)},t}(us),zd=function(n){function t(e,i){var r=n.call(this,e,!0)||this;return r.isConnected=!1,r.endPoint=i,r}return ds(t,n),t.prototype.mouseDown=function(e){return kd(this,void 0,void 0,function(){var r,s,o,a,l;return Pd(this,function(h){if(this.inAction=!0,this.undoElement=void 0,this instanceof pa||(this.undoElement=$(e.source)),n.prototype.mouseDown.call(this,e),e.source&&e.source.connectors&&(this.oldConnector=$(r=e.source.connectors[0])),"BezierSourceThumb"===this.endPoint||"BezierTargetThumb"===this.endPoint)for(s=0;s0))},t.prototype.endAction=function(){n.prototype.endAction.call(this),this.prevPosition=null,this.endPoint=null},t}(us),fa=function(n){function t(e,i){var r=n.call(this,e,!0)||this;return r.currentTarget=null,r.isStartAction=!1,r.canCancel=!1,r.canTrigger=!1,r.objectType=i,r}return ds(t,n),t.prototype.mouseDown=function(e){if(e.source instanceof te||e.source instanceof de){var i=this.commandHandler.getSelectedObject();this.commandHandler.selectObjects([e.source],e.info&&e.info.ctrlKey,i);var r={nodes:[],connectors:[]};e.source instanceof te?r.nodes.push($(e.source)):r.connectors.push($(e.source)),this.undoElement=$(r)}else this.undoElement=$(e.source);this.undoParentElement=this.commandHandler.getSubProcess(e.source),"Port"===this.objectType&&(this.portId=e.sourceWrapper.id),this.commandHandler.insertBlazorConnector(e.source),n.prototype.mouseDown.call(this,e),this.initialOffset={x:0,y:0}},t.prototype.mouseUp=function(e,i){return kd(this,void 0,void 0,function(){var s,o,a,l,h,c,d,u,p,g,v,y,S,b,M;return Pd(this,function(w){if(this.checkPropertyValue(),a=!1,h={nodes:[],connectors:[]},"Port"!==this.objectType){if(e.source instanceof te||e.source instanceof de?(e.source instanceof te?h.nodes.push($(e.source)):h.connectors.push($(e.source)),(o=$(h)).offsetX=(c=e.source.wrapper).offsetX,o.offsetY=c.offsetY):o=$(e.source),("helper"===(l=this.commandHandler.renderContainerHelper(e.source)||e.source||this.commandHandler.renderContainerHelper(e.source)).id||"helper"!==l.id)&&((l instanceof ei&&(Math.round(l.width)===Math.round(this.undoElement.width)&&Math.round(l.height)===Math.round(this.undoElement.height)||l.selectedObjects&&1===l.selectedObjects.length)||!(l instanceof ei))&&(l.offsetX!==this.undoElement.offsetX||l.offsetY!==this.undoElement.offsetY||l.sourcePoint!==this.undoElement.sourcePoint||l.targetPoint!==this.undoElement.targetPoint)||this.isSelectionHasConnector(l))&&(e.source&&(s={offsetX:e.source.wrapper.offsetX,offsetY:e.source.wrapper.offsetY}),g={source:e.source,state:"Completed",oldValue:this.intialValue,newValue:s,target:this.currentTarget,targetPosition:this.currentPosition,allowDrop:(g={source:e.source,state:"Completed",oldValue:this.intialValue,newValue:s,target:this.currentTarget,targetPosition:this.currentPosition,allowDrop:!0,cancel:!1}).allowDrop,cancel:g.cancel},d=!0,"helper"===l.id?this.canTrigger?(this.commandHandler.triggerEvent(Ce.positionChange,g),this.connectorEndPointChangeEvent(g),d=!0):d=!1:(this.commandHandler.triggerEvent(Ce.positionChange,g),this.connectorEndPointChangeEvent(g)),!i&&d&&(this.commandHandler.startGroupAction(),a=!0,M={type:"PositionChanged",redoObject:$(o),undoObject:$(this.undoElement),category:"Internal"},o.nodes[0]&&o.nodes[0].processId&&(u={type:"SizeChanged",category:"Internal",undoObject:this.undoParentElement,redoObject:this.commandHandler.getSubProcess(e.source)},this.commandHandler.addHistoryEntry(u)),this.commandHandler.addHistoryEntry(M))),this.commandHandler.snapPoint(this.prevPosition,this.currentPosition,0,0),this.commandHandler.removeSnap(),this.commandHandler.removeHighlighter(),e.source&&this.currentTarget&&_I(this.currentTarget)&&this.commandHandler.isDroppable(e.source,this.currentTarget)){if(p=!0,this.commandHandler.drop(this.currentElement,this.currentTarget,this.currentPosition),this.currentTarget&&this.currentTarget instanceof de&&!0===this.commandHandler.diagram.enableConnectorSplit)if(this.currentElement&&this.currentElement instanceof te){if(void 0!==this.currentElement.children)for(b=0;b0)for(var s=0;s0)for(var a=0;a0)for(a=0;a0&&e.connectors.length>0)||e.width===this.undoElement.width&&e.height===this.undoElement.height)},t.prototype.mouseMove=function(e){n.prototype.mouseMove.call(this,e);var r,s,i=!1;(r=this.commandHandler.renderContainerHelper(e.source)||e.source)instanceof te||r instanceof de?r instanceof te?r.offsetX===this.undoElement.nodes[0].offsetX&&r.offsetY===this.undoElement.nodes[0].offsetY&&(i=!0):R.equals(r.sourcePoint,this.undoElement.connectors[0].sourcePoint)&&R.equals(r.targetPoint,this.undoElement.connectors[0].targetPoint)&&(i=!0):r.wrapper.offsetX===this.undoElement.wrapper.offsetX&&r.wrapper.offsetY===this.undoElement.wrapper.offsetY&&(i=!0),r&&(s={offsetX:r.wrapper.offsetX,offsetY:r.wrapper.offsetY});var o={source:r,state:"Start",oldValue:s,newValue:s,target:e.target,targetPosition:e.position,allowDrop:!0,cancel:!1};if(o={source:r,state:"Start",oldValue:s,newValue:s,target:e.target,targetPosition:e.position,allowDrop:o.allowDrop,cancel:o.cancel},this.isStartAction||(this.intialValue={offsetX:r.wrapper.offsetX,offsetY:r.wrapper.offsetY}),i&&!ce()&&(this.commandHandler.triggerEvent(Ce.positionChange,o),this.connectorEndPointChangeEvent(o),this.isStartAction=!0),this.currentPosition=e.position,"Port"!==this.objectType){var h=this.initialOffset.x+(this.currentPosition.x-this.prevPosition.x),c=this.initialOffset.y+(this.currentPosition.y-this.prevPosition.y);this.commandHandler.dragOverElement(e,this.currentPosition),this.commandHandler.disConnect(e.source),this.commandHandler.removeSnap();var d,u=void 0,f=this.commandHandler.snapPoint(this.prevPosition,this.currentPosition,h,c);this.initialOffset.x=h-f.x,this.initialOffset.y=c-f.y,r&&(d={offsetX:r.wrapper.offsetX,offsetY:r.wrapper.offsetY},u={offsetX:r.wrapper.offsetX+f.x,offsetY:r.wrapper.offsetY+f.y}),this.currentTarget&&e.target!==this.currentTarget&&this.commandHandler.removeChildFromBPmn(e.source,e.target,this.currentTarget),this.currentTarget=e.target;var p={source:r,state:"Progress",oldValue:d,newValue:u,target:e.target,targetPosition:e.position,allowDrop:!0,cancel:!1};if(this.commandHandler.triggerEvent(Ce.positionChange,p),this.canTrigger=!0,this.connectorEndPointChangeEvent(p,f),!p.cancel&&!this.canCancel){this.blocked=!this.commandHandler.dragSelectedObjects(f.x,f.y);var g=!this.commandHandler.mouseOver(this.currentElement,this.currentTarget,this.currentPosition);this.blocked=this.blocked||g}if(this.commandHandler.removeStackHighlighter(),this.commandHandler.renderStackHighlighter(e),this.currentTarget&&e.source!==this.currentTarget&&this.commandHandler.isDroppable(e.source,this.currentTarget)&&"helper"!==e.source.id){var v=e.source instanceof ei?e.source.nodes[0]:e.source;!this.commandHandler.isParentAsContainer(v,!0)&&"SwimLane"!==v.shape.type&&!v.shape.isPhase&&(this.currentTarget.isLane?this.commandHandler.renderStackHighlighter(e,this.currentTarget):this.commandHandler.drawHighlighter(this.currentTarget))}else this.commandHandler.removeHighlighter();if(this.commandHandler.canEnableDefaultTooltip()){var y=this.getTooltipContent(e.source);this.commandHandler.showTooltip(e.source,e.position,ko(function(){return y}),"MoveTool",this.isTooltipVisible),this.isTooltipVisible=!1}}else{var b=Bi(),M=e.source;qi(b,-M.rotateAngle||-M.wrapper.rotateAngle,M.offsetX||M.wrapper.offsetX,M.offsetY||M.wrapper.offsetY);var w=Ke(b,{x:this.prevPosition.x,y:this.prevPosition.y}),C=Ke(b,{x:e.position.x,y:e.position.y});this.commandHandler.portDrag(e.source,e.sourceWrapper,C.x-w.x,C.y-w.y)}return this.prevPosition=this.currentPosition,!this.blocked},t.prototype.getTooltipContent=function(e){return"X:"+Math.round(e.wrapper.bounds.x)+" Y:"+Math.round(e.wrapper.bounds.y)},t.prototype.mouseLeave=function(e){this.mouseUp(e)},t.prototype.endAction=function(){n.prototype.endAction.call(this),this.currentTarget=null,this.prevPosition=null},t}(us),qx=function(n){function t(e){var i=n.call(this,e,!0)||this;return i.rotateStart=!1,i}return ds(t,n),t.prototype.mouseDown=function(e){if(this.undoElement=$(e.source),this.undoElement.nodes[0]&&this.undoElement.nodes[0].children)for(var r=this.commandHandler.getAllDescendants(this.undoElement.nodes[0],[]),s=0;s=2){var s=e.startTouches[0],o=e.startTouches[1],a=e.moveTouches[0],l=e.moveTouches[1],h=this.getDistance(a,l)/this.getDistance(s,o);this.commandHandler.zoom(h,0,0,e.position),this.updateTouch(s,a),this.updateTouch(o,l)}}else this.commandHandler.scroll(this.currentPosition.x-this.prevPosition.x,this.currentPosition.y-this.prevPosition.y,this.currentPosition);return this.commandHandler.dataBinding(),!this.blocked},t.prototype.mouseUp=function(e){this.commandHandler.setBlazorDiagramProps(!1),this.checkPropertyValue(),this.commandHandler.updatePanState(!1),n.prototype.mouseUp.call(this,e),this.inAction=!1},t.prototype.endAction=function(){n.prototype.endAction.call(this)},t.prototype.getDistance=function(e,i){var r=i.pageX-e.pageX,s=i.pageY-e.pageY;return Math.sqrt(r*r+s*s)},t.prototype.updateTouch=function(e,i){e.pageX=i.pageX,e.pageY=i.pageY},t}(us),Une=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseUp=function(e){this.checkPropertyValue(),this.commandHandler.initExpand(e),n.prototype.mouseUp.call(this,e)},t}(us),eF=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseUp=function(e){this.checkPropertyValue();var i="_blank",r="",s=window.innerHeight,o=window.innerWidth,a=window.screenTop,l=window.screenLeft;"CurrentTab"===e.sourceWrapper.hyperlink.hyperlinkOpenState?i="_self":"NewWindow"===e.sourceWrapper.hyperlink.hyperlinkOpenState&&(r="height="+s+",width="+o+",top="+a+",left="+l),window.open(e.sourceWrapper.hyperlink.link,i,r).focus(),n.prototype.mouseUp.call(this,e)},t}(us),Rl=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseDown=function(e){if(n.prototype.mouseDown.call(this,e),this.inAction=!0,this.drawingObject){var r=void 0,s=this.drawingObject.shape;this.drawingObject.shape.points.push(r={x:(r=s.points[s.points.length-1]).x,y:r.y})}else{this.startPoint={x:this.startPosition.x,y:this.startPosition.y};var i={offsetX:this.currentPosition.x,offsetY:this.currentPosition.y,width:5,height:5,shape:{type:"Basic",shape:"Polygon",points:[{x:this.startPoint.x,y:this.startPoint.y},{x:this.currentPosition.x,y:this.currentPosition.y}]}};this.triggerElementDrawEvent(e.source,"Start","Node",this.getShapeType(),!0),this.drawingObject=this.commandHandler.drawObject(i)}},t.prototype.mouseMove=function(e){if(n.prototype.mouseMove.call(this,e),this.inAction){var i=this.drawingObject.shape;if(i.points[i.points.length-1].x=this.currentPosition.x,i.points[i.points.length-1].y=this.currentPosition.y,this.drawingObject.wrapper.children[0].data=Ix(this.drawingObject.shape.points),this.triggerElementDrawEvent(this.drawingObject,"Progress","Node",this.getShapeType(),!1),this.inAction&&!1===R.equals(this.currentPosition,this.prevPosition)){var r=Ne.toBounds(this.drawingObject.shape.points);this.commandHandler.updateNodeDimension(this.drawingObject,r)}}return!0},t.prototype.mouseUp=function(e,i){this.checkPropertyValue(),n.prototype.mouseMove.call(this,e),this.inAction&&(this.inAction=!1,this.commandHandler.addObjectToDiagram(this.drawingObject),this.triggerElementDrawEvent(this.drawingObject,"Completed","Node",this.getShapeType(),!1)),this.endAction()},t.prototype.mouseWheel=function(e){n.prototype.mouseWheel.call(this,e),this.mouseMove(e)},t.prototype.endAction=function(){this.inAction=!1,this.drawingObject=null},t}(us),Hl=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseMove=function(e){if(n.prototype.mouseMove.call(this,e),this.inAction){var i=this.drawingObject;i.targetPoint=this.currentPosition,this.triggerElementDrawEvent(this.drawingObject,"Progress","Connector",this.drawingObject.type,!1),this.commandHandler.updateConnectorPoints(i)}return!0},t.prototype.mouseDown=function(e){if(n.prototype.mouseDown.call(this,e),this.inAction=!0,this.drawingObject){var r=this.drawingObject,s=void 0;(s=new Bl(r,"segments",{type:"Straight"},!0)).point=this.currentPosition,r.segments[r.segments.length-1]=s}else{var i={id:"Connector",type:"Straight",sourcePoint:this.currentPosition,targetPoint:this.currentPosition};this.triggerElementDrawEvent(e.source,"Start","Connector",this.commandHandler.diagram.drawingObject.type,!0),this.inAction&&(this.drawingObject=this.commandHandler.drawObject(i))}},t.prototype.mouseWheel=function(e){n.prototype.mouseWheel.call(this,e),this.mouseMove(e)},t.prototype.mouseUp=function(e){if(this.checkPropertyValue(),n.prototype.mouseMove.call(this,e),this.inAction&&this.drawingObject){var i=this.drawingObject;i.segments[i.segments.length-1].point={x:0,y:0},this.commandHandler.addObjectToDiagram(this.drawingObject),this.triggerElementDrawEvent(this.drawingObject,"Completed","Connector",this.drawingObject.type,!1)}this.endAction()},t.prototype.endAction=function(){this.drawingObject=null,this.inAction=!1},t}(us),jne=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseDown=function(e){this.inAction=!0,this.undoElement=$(e.source),this.annotationId=e.sourceWrapper.id,n.prototype.mouseDown.call(this,e)},t.prototype.mouseMove=function(e){n.prototype.mouseMove.call(this,e);var i=this.currentPosition.x-this.prevPosition.x,r=this.currentPosition.y-this.prevPosition.y,s=e.source;if(s instanceof te){var o=Bi();qi(o,-s.rotateAngle,0,0);var a=Ke(o,{x:i,y:r});i=a.x,r=a.y}return this.inAction&&(this.commandHandler.labelDrag(e.source,e.sourceWrapper,i,r),this.commandHandler.updateSelector()),this.prevPosition=this.currentPosition,!this.blocked},t.prototype.mouseUp=function(e){this.checkPropertyValue();var i=e.source;this.inAction=!1;var r={type:"AnnotationPropertyChanged",objectId:this.annotationId,undoObject:$(this.undoElement),category:"Internal",redoObject:$(i)};this.commandHandler.addHistoryEntry(r),n.prototype.mouseUp.call(this,e)},t.prototype.mouseLeave=function(e){this.mouseUp(e)},t}(us),Vne=function(n){function t(e,i){var r=n.call(this,e,!0)||this;return r.corner=i,r}return ds(t,n),t.prototype.mouseDown=function(e){this.inAction=!0;var i=e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0];this.annotationId=e.source.wrapper.children[0].id,this.undoElement=$(i);var r=e.source.wrapper.children[0];this.initialBounds={x:r.offsetX,y:r.offsetY,width:r.actualSize.width,height:r.actualSize.height},n.prototype.mouseDown.call(this,e)},t.prototype.mouseMove=function(e){return n.prototype.mouseMove.call(this,e),this.inAction&&this.resizeObject(e),!this.blocked},t.prototype.mouseUp=function(e){this.checkPropertyValue();var i=e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0];this.inAction=!1;var r={type:"AnnotationPropertyChanged",objectId:this.annotationId,redoObject:$(i),undoObject:$(this.undoElement),category:"Internal"};this.commandHandler.addHistoryEntry(r),n.prototype.mouseUp.call(this,e)},t.prototype.mouseLeave=function(e){this.mouseUp(e)},t.prototype.resizeObject=function(e){var i,s,o,r=e.source.wrapper.children[0],a={x:r.offsetX,y:r.offsetY},l=r.rotateAngle;l=((l+=(i=e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0])instanceof te?i.rotateAngle:0)+360)%360;var h=Bi();qi(h,l,a.x,a.y);var c=this.corner.slice(5),d=this.updateSize(r,this.startPosition,this.currentPosition,c,this.initialBounds,l),u=r.offsetX-r.actualSize.width*r.pivot.x,f=r.offsetY-r.actualSize.height*r.pivot.y,p=this.getPivot(c),g=Ke(h,p={x:u+r.actualSize.width*p.x,y:f+r.actualSize.height*p.y});d.x=g.x,d.y=g.y,this.commandHandler.labelResize(i,e.source.annotation,s=(s=d.width)<0?1:s,o=(o=d.height)<0?1:o,d,e.source),this.commandHandler.updateSelector()},t}(us),Wne=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseDown=function(e){this.inAction=!0,this.annotationId=e.source.wrapper.children[0].id,this.undoElement=$(e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0]),n.prototype.mouseDown.call(this,e)},t.prototype.mouseMove=function(e){return n.prototype.mouseMove.call(this,e),e.source&&this.inAction&&(this.commandHandler.labelRotate(e.source.nodes[0]?e.source.nodes[0]:e.source.connectors[0],e.source.annotation,this.currentPosition,e.source),this.commandHandler.updateSelector()),this.prevPosition=this.currentPosition,!this.blocked},t.prototype.mouseUp=function(e){this.checkPropertyValue(),this.inAction=!1;var r={type:"AnnotationPropertyChanged",objectId:this.annotationId,redoObject:$(e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0]),undoObject:$(this.undoElement),category:"Internal"};this.commandHandler.addHistoryEntry(r),n.prototype.mouseUp.call(this,e)},t.prototype.mouseLeave=function(e){this.mouseUp(e)},t}(us),Yne=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseMove=function(e){if(n.prototype.mouseMove.call(this,e),this.inAction){var i=this.drawingObject.shape;if(i.points.push(this.currentPosition),this.drawingObject.wrapper.children[0].data=bx(this.drawingObject.shape.points),i.data=bx(i.points),this.triggerElementDrawEvent(e.source,"Progress","Connector",this.drawingObject.type,!1),this.inAction&&!1===R.equals(this.currentPosition,this.prevPosition)){var s=Ne.toBounds(this.drawingObject.shape.points);this.commandHandler.updateNodeDimension(this.drawingObject,s)}}return!0},t.prototype.mouseDown=function(e){n.prototype.mouseDown.call(this,e),this.inAction=!0,this.startPoint={x:this.startPosition.x,y:this.startPosition.y};var i={offsetX:this.currentPosition.x,offsetY:this.currentPosition.y,width:5,height:5,style:{strokeColor:"black",strokeWidth:1,fill:"transparent"},shape:{type:"Path",points:[{x:this.startPoint.x,y:this.startPoint.y},{x:this.currentPosition.x,y:this.currentPosition.y}]}};this.triggerElementDrawEvent(e.source,"Start","Connector",this.commandHandler.diagram.drawingObject.type,!0),this.drawingObject=this.commandHandler.drawObject(i)},t.prototype.mouseUp=function(e){if(this.checkPropertyValue(),this.inAction){this.inAction=!1;var s=this.drawingObject.shape,o=s.points;this.commandHandler.addObjectToDiagram(this.drawingObject),this.commandHandler.diagram.remove(this.commandHandler.diagram.nameTable[""+this.drawingObject.id]),o=this.pointReduction(o,10);var h={id:"newConnector"+Qe(),type:"Bezier",sourcePoint:{x:o[0].x,y:o[0].y},targetPoint:{x:o[o.length-1].x,y:o[o.length-1].y},segments:[],bezierSettings:{allowSegmentsReset:!1}};this.drawingObject=this.commandHandler.drawObject(h),this.drawingObject=this.bezierCurveSmoothness(o,.5,this.drawingObject,s),this.commandHandler.updateConnectorPoints(this.drawingObject),this.commandHandler.addObjectToDiagram(this.drawingObject),this.triggerElementDrawEvent(this.drawingObject,"Completed","Connector",this.drawingObject.type,!1),n.prototype.mouseUp.call(this,e)}},t.prototype.pointReduction=function(e,i){if(null===e||e.length<3)return e;var s=e.length-1,o=[];for(o.push(0),o.push(s);e[parseInt((0).toString(),10)]===e[parseInt(s.toString(),10)];)s--;this.reduction(e,0,s,i,o);var a=[];return o.sort(function(l,h){return l-h}),o.forEach(function(l){a.push(e[parseInt(l.toString(),10)])}),a},t.prototype.reduction=function(e,i,r,s,o){for(var a=0,l=0,h=i;ha&&(a=c,l=h)}a>s&&0!==l&&(o.push(l),this.reduction(e,i,l,s,o),this.reduction(e,l,r,s,o))},t.prototype.perpendicularDistance=function(e,i,r){return Math.abs(.5*(e.x*i.y-i.x*e.y+(i.x*r.y-r.x*i.y)+(r.x*e.y-e.x*r.y)))/Math.sqrt(Math.pow(e.x-i.x,2)+Math.pow(e.y-i.y,2))*2},t.prototype.bezierCurveSmoothness=function(e,i,r,s){if(e.length<3)return r;for(var o=0;o=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Qne=function(n){if(n)switch(n.type){case"Bpmn":return $ne;case"UmlActivity":return qne;case"UmlClassifier":return Kne;default:return rm}return rm},Gne=function(n){if(n)switch(n.type){case"Straight":default:return Bl;case"Bezier":return fs;case"Orthogonal":return wi}},tF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I(10)],t.prototype,"width",void 0),Pe([I(10)],t.prototype,"height",void 0),Pe([I("Arrow")],t.prototype,"shape",void 0),Pe([re({fill:"black",strokeColor:"black",strokeWidth:1},Nl)],t.prototype,"style",void 0),Pe([re({x:0,y:.5},R)],t.prototype,"pivot",void 0),Pe([I("")],t.prototype,"pathData",void 0),t}(Ee),JI=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I(0)],t.prototype,"angle",void 0),Pe([I(0)],t.prototype,"distance",void 0),t}(Ee),Xne=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I(Ex.All)],t.prototype,"controlPointsVisibility",void 0),Pe([I("FreeForm")],t.prototype,"segmentEditOrientation",void 0),Pe([I(EI.Default)],t.prototype,"smoothness",void 0),Pe([I(!0)],t.prototype,"allowSegmentsReset",void 0),t}(Ee),rm=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I("None")],t.prototype,"type",void 0),t}(Ee),qne=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I("Object")],t.prototype,"flow",void 0),Pe([I(30)],t.prototype,"exceptionFlowHeight",void 0),t}(rm),$ne=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I("Sequence")],t.prototype,"flow",void 0),Pe([I("Normal")],t.prototype,"sequence",void 0),Pe([I("Default")],t.prototype,"message",void 0),Pe([I("Default")],t.prototype,"association",void 0),t}(rm),iF=function(n){function t(e,i,r,s){var o=n.call(this,e,i,r,s)||this;return o.points=[],o}return Qs(t,n),Pe([I("Straight")],t.prototype,"type",void 0),Pe([I(!0)],t.prototype,"allowDrag",void 0),t}(Ee),Bl=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),t.prototype.getClassName=function(){return"StraightSegment"},Pe([re({x:0,y:0},R)],t.prototype,"point",void 0),t}(iF),fs=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),t.prototype.getClassName=function(){return"BezierSegment"},t.prototype.getPoints=function(e,i){var r=[];if(r.length>0||null!=i){var o=this.bezireToPoly(r.length>0?r[r.length-1]:i,e);r.push.apply(r,o)}return r},t.prototype.bezireToPoly=function(e,i){var r=[];return i&&this.flattenCubicBezier(r,e,i.bezierPoint1,i.bezierPoint2,{x:i.points[1].x,y:i.points[1].y},10),r},t.prototype.flattenCubicBezier=function(e,i,r,s,o,a){var h,l=(R.findLength(i,r)+R.findLength(r,s)+R.findLength(s,o))/a;for(h=0;h<=l;h++){var c=h/l;e.push({x:(1-c)*(1-c)*(1-c)*i.x+3*c*(1-c)*(1-c)*r.x+3*c*c*(1-c)*s.x+c*c*c*o.x,y:(1-c)*(1-c)*(1-c)*i.y+3*c*(1-c)*(1-c)*r.y+3*c*c*(1-c)*s.y+c*c*c*o.y})}},Pe([I("Horizontal")],t.prototype,"orientation",void 0),Pe([re({x:0,y:0},R)],t.prototype,"point1",void 0),Pe([re({x:0,y:0},R)],t.prototype,"point2",void 0),Pe([re({angle:0,distance:0},JI)],t.prototype,"vector1",void 0),Pe([re({angle:0,distance:0},JI)],t.prototype,"vector2",void 0),t}(Bl),wi=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),t.prototype.getClassName=function(){return"OrthogonalSegment"},Pe([I(null)],t.prototype,"length",void 0),Pe([I(null)],t.prototype,"direction",void 0),t}(iF);function rF(n,t,e){var s=e?45:180/(2+2/(n.height/n.width)),o=s,a=180-s,l=a+2*s,h=360-s,c=Gt(t,n.center);return c>o&&ca&&cl&&cMath.abs(t.y-n.y)?n.x=c)return s=R.findAngle(n[parseInt(d.toString(),10)],n[d+1]),{point:r=R.transform(n[parseInt(d.toString(),10)],s,c-(a||0)),index:l=d};a=o[parseInt(d.toString(),10)]}return{point:r,index:l}}(n,t),r=R.findAngle(n[i.index],n[i.index+1]),s=function xse(n){var e=0;switch(n.alignment){case"Center":case"After":e=0;break;case"Before":e=-0}return e}(t),o=R.transform(i.point,r+45,s);return i.point=o,i.angle=r,i}(i,e),h=l.point;s.id=this.id+"_"+e.id;var c=e.style;s.style={fill:c.fill,strokeColor:c.strokeColor,gradient:null,opacity:c.opacity,strokeDashArray:c.strokeDashArray,strokeWidth:c.strokeWidth},0===r.width&&(r.width=this.style.strokeWidth),0===r.height&&(r.height=this.style.strokeWidth);var d_y=(h.y-r.y)/r.height;a.x=r.width*((h.x-r.x)/r.width),a.y=r.height*d_y;var g,v,u=SF(e,l.angle,i),f=u.hAlign,p=u.vAlign;return"left"===f?(g="Left",a.x+=e.displacement.x):"right"===f?(g="Right",a.x-=e.displacement.x):"center"===f&&(g="Center"),"top"===p?(v="Top",a.y+=e.displacement.y):"bottom"===p?(v="Bottom",a.y-=e.displacement.y):"center"===p&&(v="Center"),s.horizontalAlignment=g,s.verticalAlignment=v,(s=om(s,o&&"Label"!==o.flipMode&&"None"!==o.flipMode?this.flip:"None",e)).float=!0,s.connectionDirection=e.connectionDirection,s.setOffsetWithRespectToBounds(a.x,a.y,"Absolute"),s.relativeMode="Point",s.visible=!(!va(e,ci.Visible)||va(e,ci.Hover)||va(e,ci.Connect)),s.elementActions=s.elementActions|Xr.ElementIsPort,s},t.prototype.getConnectorRelation=function(){var e=this.shape;"Association"===e.relationship?(this.segments[0].type="Straight",this.sourceDecorator.shape="None",this.targetDecorator.shape="Arrow"):"Inheritance"===e.relationship?(this.segments[0].type="Orthogonal",this.sourceDecorator.shape="None",this.targetDecorator.shape="Arrow"):"Composition"===e.relationship||"Aggregation"===e.relationship?(this.segments[0].type="Orthogonal",this.sourceDecorator.shape="Diamond",this.targetDecorator.shape="None"):"Dependency"===e.relationship?(this.segments[0].type="Orthogonal",this.sourceDecorator.shape="None",this.targetDecorator.shape="OpenArrow"):"Realization"===e.relationship&&(this.segments[0].type="Orthogonal",this.sourceDecorator.shape="None",this.targetDecorator.shape="Arrow"),"BiDirectional"===e.associationType&&(this.sourceDecorator.shape="None",this.targetDecorator.shape="None");var i,o,r="",s="";e.multiplicity.source&&(e.multiplicity.source.lowerBounds=e.multiplicity.source.lowerBounds,e.multiplicity.source.upperBounds=e.multiplicity.source.upperBounds),e.multiplicity.target&&(e.multiplicity.target.lowerBounds=e.multiplicity.target.lowerBounds,e.multiplicity.target.upperBounds=e.multiplicity.target.upperBounds);var a=e.multiplicity.source,l=e.multiplicity.target;o=a.upperBounds?a.lowerBounds+"..."+a.upperBounds:a.lowerBounds,i=l.upperBounds?l.lowerBounds+"..."+l.upperBounds:l.lowerBounds,"ManyToOne"===e.multiplicity.type&&(e.multiplicity.target.optional=!1,r=o||"*",s="1"),"OneToMany"===e.multiplicity.type&&(e.multiplicity.source.optional=!1,s=i||"*",r="1"),"ManyToMany"===e.multiplicity.type&&(r=o||"*",s=i||"*"),"OneToOne"===e.multiplicity.type&&(e.multiplicity.target.optional=!1,e.multiplicity.source.optional=!1,r="1",s="1"),this.annotations=[{id:this.id+"sourcelabel",content:r,offset:0,alignment:"Before",margin:{right:5,bottom:5}},{id:this.id+"targetlabel",content:s,offset:1,alignment:"Before",margin:{right:5,bottom:5}}]},t.prototype.getBpmnSequenceFlow=function(){var e=new Ze,i=new Ze;return"Normal"===this.shape.sequence&&"Bezier"!==this.type&&(this.targetDecorator.shape="Arrow"),"Default"===this.shape.sequence&&(e=this.getSegmentElement(this,e),i=DF(this.intermediatePoints,this),this.targetDecorator.shape="Arrow"),"Conditional"===this.shape.sequence&&(this.targetDecorator.shape="Arrow",this.sourceDecorator.shape="Diamond",i.id=this.id+this.shape.type),i},t.prototype.getUMLObjectFlow=function(){if(this.annotations)for(var e=0;e0&&(this.sourcePoint=o[0],this.targetPoint=o[o.length-1]),o},t.prototype.clipDecorator=function(e,i,r,s){var a,l,o={x:0,y:0},h=i.length,c=R.distancePoints(a=r?i[0]:i[h-1],l=r?i[1]:i[h-2]);c=0===c?1:c;var d=1,u=r?e.sourceWrapper:e.targetWrapper;u&&(d=u.style.strokeWidth,s&&s&ee.DecoratorPropertyChange&&(d=1));var f=d-1;return o.x=Math.round(a.x+f*(l.x-a.x)/c),o.y=Math.round(a.y+f*(l.y-a.y)/c),(r&&"None"!==e.sourceDecorator.shape||!r&&"None"!==e.targetDecorator.shape)&&(o=R.adjustPoint(o,l,!0,s&ee.DecoratorPropertyChange?0:d/2)),o},t.prototype.clipDecorators=function(e,i,r){return"None"!==e.sourceDecorator.shape&&(i[0]=this.clipDecorator(e,i,!0,r)),"None"!==e.targetDecorator.shape&&(i[i.length-1]=this.clipDecorator(e,i,!1,r)),i},t.prototype.updateSegmentElement=function(e,i,r,s){var o=new Ne,a=this.getSegmentPath(e,i,s);if("Bezier"===e.type){if(this.segments.length>0)for(var l=0;l0)if("Straight"===e.type&&e.segments.length<2)for(var o=0;o1)for(o=0;o0&&"Bezier"!==this.type)for(var f=0;f0&&(a=f0&&(p<2*this.cornerRadius?(l=R.adjustPoint(h[parseInt(f.toString(),10)],h[f+1],!0,p/2),f0&&(s=this.bridgePath(e,s,f),"Orthogonal"===e.type&&(s=this.bridgePath(e,s,f+1))),s+=" L"+a.x+" "+a.y))}else if("Bezier"===this.type){var g=void 0,v=void 0;if(this.parentObj.element){var y=this.parentObj.element.ej2_instances[0].eventHandler.action;g=this.parentObj.element.ej2_instances[0].eventHandler.tool instanceof Rd,v=y.includes("PortDraw")||y.includes("Drag")}for(var S=void 0,b=this.segments,M=0;M2&&(b[parseInt(M.toString(),10)].bezierPoint1={x:0,y:0},b[parseInt(M.toString(),10)].bezierPoint2={x:0,y:0}),!R.isEmptyPoint(b[parseInt(M.toString(),10)].point1)||b[parseInt(M.toString(),10)].vector1.angle||b[parseInt(M.toString(),10)].vector1.distance?b[parseInt(M.toString(),10)].vector1.angle||b[parseInt(M.toString(),10)].vector1.distance?b[parseInt(M.toString(),10)].bezierPoint1=R.transform(h[parseInt(M.toString(),10)],b[parseInt(M.toString(),10)].vector1.angle,b[parseInt(M.toString(),10)].vector1.distance):b[parseInt(M.toString(),10)].bezierPoint1={x:b[parseInt(M.toString(),10)].point1.x||b[parseInt(M.toString(),10)].bezierPoint1.x,y:b[parseInt(M.toString(),10)].point1.y||b[parseInt(M.toString(),10)].bezierPoint1.y}:((e.sourceID||this.sourcePortID)&&this.sourceWrapper&&!v&&!g&&(S=rF(this.sourceWrapper.bounds,h[parseInt(M.toString(),10)],!0)),b[parseInt(M.toString(),10)].bezierPoint1=eb(h[parseInt(M.toString(),10)],h[M+1],S)),!R.isEmptyPoint(b[parseInt(M.toString(),10)].point2)||b[parseInt(M.toString(),10)].vector2.angle||b[parseInt(M.toString(),10)].vector2.distance?b[parseInt(M.toString(),10)].vector2.angle||b[parseInt(M.toString(),10)].vector2.distance?b[parseInt(M.toString(),10)].bezierPoint2=R.transform(h[M+1],b[parseInt(M.toString(),10)].vector2.angle,b[parseInt(M.toString(),10)].vector2.distance):b[parseInt(M.toString(),10)].bezierPoint2={x:b[parseInt(M.toString(),10)].point2.x||b[parseInt(M.toString(),10)].bezierPoint2.x,y:b[parseInt(M.toString(),10)].point2.y||b[parseInt(M.toString(),10)].bezierPoint2.y}:((e.targetID||this.targetPortID)&&this.targetWrapper&&!v&&!g&&(S=rF(this.targetWrapper.bounds,h[M+1],!0)),b[parseInt(M.toString(),10)].bezierPoint2=eb(h[M+1],h[parseInt(M.toString(),10)],S));h.splice(1,0,{x:b[0].bezierPoint1.x,y:b[0].bezierPoint1.y}),h.splice(h.length-1,0,{x:b[b.length-1].bezierPoint2.x,y:b[b.length-1].bezierPoint2.y}),h=this.clipDecorators(e,h,r);for(var w=0;w0&&(s=this.bridgePath(e,s,D),s+=" L"+o.x+" "+o.y);return s},t.prototype.updateShapeElement=function(e){var i;switch(e.shape.type){case"Bpmn":e.wrapper.children[3]instanceof Ze&&(i=e.wrapper.children[3]),"Message"===e.shape.flow&&this.updateShapePosition(e,i);break;case"UmlActivity":"Exception"===e.shape.flow&&this.getUMLExceptionFlow(e.wrapper.children[0])}},t.prototype.updateShapePosition=function(e,i){var o=xF(this.intermediatePoints,i,.5);i.offsetX=o.x,i.offsetY=o.y},t.prototype.scale=function(e,i,r,s,o){var a=0,l=0;if(this.wrapper&&this.wrapper.outerBounds){var h=function T3(n){var t=n.wrapper.children[0].bounds;return"None"!==n.sourceDecorator.shape&&t.uniteRect(n.wrapper.children[1].bounds),"None"!==n.targetDecorator.shape&&t.uniteRect(n.wrapper.children[2].bounds),t}(this),c=Math.abs((this.wrapper.bounds.width||this.style.strokeWidth||1)-2),d=Math.abs((this.wrapper.bounds.height||this.style.strokeWidth||1)-2);a=h.width-c,l=h.height-d,e=Math.abs((r-Math.max(a,l))/c),i=Math.abs((s-Math.max(a,l))/d),a=l=Math.min(a,l)}e=i=Math.min(e,i);var u=Bi();qi(u,-(o=o||this.wrapper).rotateAngle,o.offsetX,o.offsetY),Xf(u,e,i,o.offsetX,o.offsetY),qi(u,o.rotateAngle,o.offsetX,o.offsetY);var f=function Uie(n,t){for(var e=[],i=0,r=t;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},tse=function(n){function t(e,i){var r=n.call(this,e,i)||this;return r.offset=0,r.scale=1,r}return ese(t,n),t.prototype.preRender=function(){this.unWireEvents(),this.wireEvents()},t.prototype.render=function(){this.updateRulerGeometry(),this.renderComplete()},t.prototype.getModuleName=function(){return"Ruler"},t.prototype.destroy=function(){this.unWireEvents(),this.notify("destroy",{}),n.prototype.destroy.call(this),this.element.classList.remove("e-ruler")},t.prototype.getPersistData=function(){return this.addOnPersist(["loaded"])},t.prototype.onPropertyChanged=function(e,i){for(var r=0,s=Object.keys(e);r100;)r/=10,s/=10;for(;s<25;)r*=10,s*=10;return s>=25&&s%25!=0&&(s=25*Math.round(s/25)),s*e/r},t.prototype.createMarkerLine=function(e,i,r){var s;return i&&((s=e.getElementById(i.id+"_marker"))&&s.parentNode.removeChild(s),s=Fi("line",r)),s},t.prototype.drawRulerMarker=function(e,i,r){var s,o,h,d,u="Horizontal"===this.orientation,f=e.getElementsByTagName("svg");for(h=0;h0)for(var a=i.childNodes.length-1;a>=0;a--)i.childNodes[parseInt(a.toString(),10)].parentNode.removeChild(i.childNodes[parseInt(a.toString(),10)]);i.appendChild(s)}return s},t.prototype.wireEvents=function(){},t.prototype.unWireEvents=function(){},zc([I(5)],t.prototype,"interval",void 0),zc([I(100)],t.prototype,"segmentWidth",void 0),zc([I("Horizontal")],t.prototype,"orientation",void 0),zc([I("RightOrBottom")],t.prototype,"tickAlignment",void 0),zc([I("red")],t.prototype,"markerColor",void 0),zc([I(25)],t.prototype,"thickness",void 0),zc([I(null)],t.prototype,"arrangeTick",void 0),zc([I(400)],t.prototype,"length",void 0),t}(Ii);function oF(n,t){var e=document.getElementById(n.element.id+(t?"_hRuler":"_vRuler")),i=Za(n),r=aF(n);e||(e=Tt("div",{id:n.element.id+(t?"_hRuler":"_vRuler"),style:"height:"+(t?i.height:r.height+100)+"px;overflow:hidden;width:"+(t?r.width+100:i.width)+"px;position:absolute;font-size:11px;"+(t?"margin-left:"+i.width+"px;":"margin-top:"+i.height+"px;")})),n.element.insertBefore(e,n.element.firstChild);var l=t?n.rulerSettings.horizontalRuler:n.rulerSettings.verticalRuler,h=new tse(l);h.orientation=t?"Horizontal":"Vertical",h.length=(t?r.width:r.height)+l.segmentWidth,h.appendTo("#"+n.element.id+(t?"_hRuler":"_vRuler")),t?n.hRuler=h:n.vRuler=h;var c=document.getElementById(n.element.id+(t?"_hRuler":"_vRuler"));t?n.hRuler.element=c:n.vRuler.element=c}function tb(n){var t=-n.scroller.horizontalOffset,e=-n.scroller.verticalOffset;n&&n.rulerSettings.showRulers?(n.hRuler.length=0,n.vRuler.length=0,void 0!==t&&n.hRuler.element&&lF(n,n.hRuler,t,!0),void 0!==e&&n.vRuler.element&&lF(n,n.vRuler,e,!1)):$x(n)}function $x(n){an(n.element.id+"_hRuler"),an(n.element.id+"_vRuler"),an(n.element.id+"_overlapRuler")}function Za(n){var t=0,e=0;return n.rulerSettings.showRulers&&(t=n.rulerSettings.horizontalRuler.thickness,e=n.rulerSettings.verticalRuler.thickness),new me(e,t)}function aF(n){var t=Za(n),e=n.scroller.viewPortHeight,i=n.scroller.viewPortWidth;return i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},hF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return ase(t,n),t.prototype.getClassName=function(){return"UserHandle"},Un([I("")],t.prototype,"name",void 0),Un([I("")],t.prototype,"pathData",void 0),Un([I("")],t.prototype,"content",void 0),Un([I("")],t.prototype,"source",void 0),Un([I("#000000")],t.prototype,"backgroundColor",void 0),Un([I("Top")],t.prototype,"side",void 0),Un([I("")],t.prototype,"borderColor",void 0),Un([I(.5)],t.prototype,"borderWidth",void 0),Un([I(25)],t.prototype,"size",void 0),Un([I("white")],t.prototype,"pathColor",void 0),Un([I(10)],t.prototype,"displacement",void 0),Un([I(!0)],t.prototype,"visible",void 0),Un([I(0)],t.prototype,"offset",void 0),Un([re({},Jn)],t.prototype,"margin",void 0),Un([I("Center")],t.prototype,"horizontalAlignment",void 0),Un([I("Center")],t.prototype,"verticalAlignment",void 0),Un([I(!1)],t.prototype,"disableNodes",void 0),Un([I(!1)],t.prototype,"disableConnectors",void 0),Un([re({},Td)],t.prototype,"tooltip",void 0),Un([I("")],t.prototype,"template",void 0),t}(Ee);function cF(n){return lse[n.toString()]}var lse={Action:"M 90 82.895 C 90 86.819 86.776 90 82.8 90 H 7.2 C 3.224 90 0 86.819 0 82.895 V 7.105 C 0 3.181 3.224 0 7.2 0 h 75.6 C 86.776 0 90 3.181 90 7.105 V 82.895 Z",Decision:"M10,19.707L0.293,10L10,0.293L19.707,10L10,19.707z",MergeNode:"M10,19.707L0.293,10L10,0.293L19.707,10L10,19.707z",InitialNode:"M10,19.5c-5.238,0-9.5-4.262-9.5-9.5S4.762,0.5,10,0.5s9.5,4.262,9.5,9.5S15.238,19.5,10,19.5z",ForkNode:"m0.75,0.75l636.00002,0l0,290l-636.00002,0l0,-290z",JoinNode:"m0.75,0.75l636.00002,0l0,290l-636.00002,0l0,-290z",TimeEvent:"M50.001,0.00286865 L25.001,25.0029 L0.000976562,0.00286865 L50.001,0.00286865 z M0.000976562,50.0029 L25.001,25.0029 L50.001,50.0029 L0.000976562,50.0029 z",AcceptingEvent:"M17.8336 32.164 L29.64 24 L17.32 16 L48.1664 16 L48.5 32 Z",SendSignal:"M48.164 31.8336 L56 23.832 L47.836 16 L16.168 16 L16.1668 31.8336 Z",ReceiveSignal:"M48.1664 31.8336 L39.836 24 L47.836 16 L16.168 16 L16.168 31.836 Z",StructuredNode:"M0,0 L50,0 L50,50 L0,50 z",Note:"M20 12 L4 12 L4 22 L22 22 L22 14 L20 14 L20 12 L22 14 Z"},ib=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Ja=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},hse=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return ib(t,n),Ja([I()],t.prototype,"key",void 0),Ja([I()],t.prototype,"keyModifiers",void 0),t}(Ee),dF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return ib(t,n),t.prototype.getClassName=function(){return"Command"},Ja([I("")],t.prototype,"name",void 0),Ja([I()],t.prototype,"canExecute",void 0),Ja([I()],t.prototype,"execute",void 0),Ja([re({},hse)],t.prototype,"gesture",void 0),Ja([I("")],t.prototype,"parameter",void 0),t}(Ee),cse=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return ib(t,n),Ja([Bt([],dF)],t.prototype,"commands",void 0),t}(Ee),dse=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return ib(t,n),Ja([I()],t.prototype,"show",void 0),Ja([I()],t.prototype,"showCustomMenuOnly",void 0),Ja([I()],t.prototype,"items",void 0),t}(Ee),Kf=function(){function n(){}return n.prototype.renderShadow=function(t,e,i,r){void 0===i&&(i=null);var l,o=R.transform({x:0,y:0},t.shadow.angle,t.shadow.distance);r&&(l=r.getElementById(e.id+"_shadow")),l||(l=document.createElementNS("http://www.w3.org/2000/svg",i?"path":"rect"),e.appendChild(l));var h={id:e.id+"_shadow",fill:t.shadow.color,stroke:t.shadow.color,opacity:t.shadow.opacity.toString(),transform:"rotate("+t.angle+","+(t.x+t.width*t.pivotX)+","+(t.y+t.height*t.pivotY)+")translate("+(t.x+o.x)+","+(t.y+o.y)+")"};if(r){var c=r.getElementById(e.id);c&&c.insertBefore(l,c.firstChild)}ti(l,h),i?i&&this.renderPath(l,t,i):ti(l,{width:t.width,height:t.height})},n.prototype.parseDashArray=function(t){return[]},n.prototype.drawRectangle=function(t,e,i,r,s,o,a,l,h){var c,d,u,f;e.shadow&&!r&&this.renderShadow(e,t,void 0,o),c=e.id===t.id?e.id+"_container":e.id,o&&(d=o.getElementById(c)),(!d||s)&&(d=document.createElementNS("http://www.w3.org/2000/svg","rect"),t.appendChild(d)),o&&!e.shadow&&(u=o.getElementById(e.id+"_groupElement_shadow"))&&u.parentNode.removeChild(u),f=l?{id:c,x:e.x.toString(),y:e.y.toString(),width:e.width.toString(),height:e.height.toString(),visibility:e.visible?"visible":"hidden",transform:"rotate("+e.angle+","+(e.x+e.width/2)+","+(e.y+e.height/2)+")",rx:e.cornerRadius||0,ry:e.cornerRadius||0,opacity:e.opacity}:{id:c,x:e.x.toString(),y:e.y.toString(),width:e.width.toString(),height:e.height.toString(),visibility:e.visible?"visible":"hidden",transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")",rx:e.cornerRadius||0,ry:e.cornerRadius||0,opacity:e.opacity},a&&(f.role="img",f["aria-label"]=a);var p=e.class||"";h||(p.includes("e-diagram-resize-handle")||p.includes("e-diagram-endpoint-handle")||p.includes("e-diagram-bezier-control-handle"))&&(p+=" e-disabled"),e.class&&(f.class=p),a||(f["pointer-events"]="none"),ti(d,f),this.setSvgStyle(d,e,i)},n.prototype.updateSelectionRegion=function(t,e){var i;i=t.parentNode.getElementById(e.id);var r={id:e.id,x:e.x.toString(),y:e.y.toString(),width:e.width.toString(),height:e.height.toString(),transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")",class:"e-diagram-selected-region"};i||(i=document.createElementNS("http://www.w3.org/2000/svg","rect"),t.appendChild(i)),this.setSvgStyle(i,e),ti(i,r)},n.prototype.createGElement=function(t,e){return Fi(t,e)},n.prototype.drawLine=function(t,e){var i=document.createElementNS("http://www.w3.org/2000/svg","line");this.setSvgStyle(i,e);var r=e.x+e.width*e.pivotX,s=e.y+e.height*e.pivotY,o={id:e.id,x1:e.startPoint.x+e.x,y1:e.startPoint.y+e.y,x2:e.endPoint.x+e.x,y2:e.endPoint.y+e.y,stroke:e.stroke,"stroke-width":e.strokeWidth.toString(),opacity:e.opacity.toString(),transform:"rotate("+e.angle+" "+r+" "+s+")",visibility:e.visible?"visible":"hidden"};e.class&&(o.class=e.class),ti(i,o),t.appendChild(i)},n.prototype.drawCircle=function(t,e,i,r){var s=document.createElementNS("http://www.w3.org/2000/svg","circle");this.setSvgStyle(s,e);var o=e.class||"";i||(o+=" e-disabled");var a={id:e.id,cx:e.centerX,cy:e.centerY,r:e.radius,visibility:e.visible?"visible":"hidden",class:o};r&&(a.role="img",a["aria-label"]=r),s.style.display=e.visible?"block":"none",ti(s,a),t.appendChild(s)},n.prototype.drawPath=function(t,e,i,r,s,o,a){var h,c,l=[];l=e3(l=xd(e.data)),e.shadow&&this.renderShadow(e,t,l,s),s&&!e.shadow&&(h=s.getElementById(e.id+"_groupElement_shadow"))&&h.parentNode.removeChild(h),s&&(c=s.getElementById(e.id)),(!c||r)&&(c=document.createElementNS("http://www.w3.org/2000/svg","path"),t.appendChild(c)),this.renderPath(c,e,l);var d={};d=a?{id:e.id,transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")translate("+e.x+","+e.y+"),scale("+a+")",visibility:e.visible?"visible":"hidden",opacity:e.opacity}:{id:e.id,transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")translate("+e.x+","+e.y+")",visibility:e.visible?"visible":"hidden",opacity:e.opacity},o&&(d.role="img",d["aria-label"]=o),e.class&&(d.class=e.class),ti(c,d),this.setSvgStyle(c,e,i)},n.prototype.renderPath=function(t,e,i){var r,s,o,a,l,h,c,d,u=i,f="";for(l=0,h=0,d=0,c=u.length;de.width&&"Wrap"!==e.textOverflow&&"NoWrap"===e.textWrapping&&(h[0].text=qF(e.content,e)),v=0;vD&&(u.text=u.text.slice(0,u.text.length-3),u.text=u.text.concat("..."),l.data=u.text),this.alignText(y,f,u,l,p,g,v,e,h),C+=u.dy}}C&&e.isHorizontalLane&&(M=e.parentOffsetX+e.pivotX,w=e.parentOffsetY+e.pivotY,e.y=e.parentOffsetY-C*e.pivotY+.5),e.textDecoration&&"LineThrough"===e.textDecoration&&(e.textDecoration=vb(e.textDecoration));var P={id:e.id+"_text",fill:e.color,visibility:e.visible?"visible":"hidden","text-decoration":e.textDecoration,transform:"rotate("+e.angle+","+M+","+w+")translate("+e.x+","+e.y+")",opacity:e.opacity};r&&(P.role="img",P["aria-label"]=r),ti(y,P)}},n.prototype.alignText=function(t,e,i,r,s,o,a,l,h){"justify"!==l.textAlign?this.setText(t,e,i,r,s,o,l):a!==h.length-1?this.setText(t,e,i,r,s,o,l,l.width,"spacing"):this.setText(t,e,i,r,s,o,l)},n.prototype.setText=function(t,e,i,r,s,o,a,l,h){ti(e,"justify"!==a.textAlign?{x:s.toString(),y:o.toString()}:{x:s.toString(),y:o.toString(),textLength:l||0,lengthAdjust:h||"spacing"}),t.setAttribute("fill",i.text),e.appendChild(r),t.appendChild(e)},n.prototype.drawImage=function(t,e,i,r){var s;i&&(s=i.getElementById(e.id+"image")),s||(s=document.createElementNS("http://www.w3.org/2000/svg","image"),t.appendChild(s));var o=new Image;o.src=e.source;var a="None"!==e.scale?e.scale:"",l=e.alignment,h=l.charAt(0).toLowerCase()+l.slice(1);"Stretch"!==a&&(h+=" "+a.charAt(0).toLowerCase()+a.slice(1)),ti(s,{id:e.id+"image",x:e.x.toString(),y:e.y.toString(),transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")",width:e.width.toString(),visibility:e.visible?"visible":"hidden",height:e.height.toString(),preserveAspectRatio:h,opacity:e.opacity.toString()}),s.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",o.src.toString())},n.prototype.drawHTMLContent=function(t,e,i,r,s){var o,a;if(e&&(o=e.querySelector("#"+t.id+"_html_element")),!o){(a=e.querySelector("#"+t.id+"_html_element")||e.querySelector("#"+t.nodeId+"_html_element"))||(a=Tt("div",{id:t.nodeId+"_html_element",class:"foreign-object"})),o=Tt("div",{id:t.id+"_html_element",class:"foreign-object"});var c=document.getElementById(t.diagramId).ej2_instances[0],d=!1;if(e.parentNode&&e.parentNode.parentNode&&e.parentNode.parentNode.parentNode&&e.parentNode.parentNode.parentNode.classList.contains("e-overview")&&(d=!0),d)c.isReact?c.renderReactTemplates(function(){o.appendChild(t.template.cloneNode(!0))}):o.appendChild(t.template.cloneNode(!0));else{if("string"==typeof t.template){var u=document.createElement("div");u.innerHTML=t.template,t.template=u,c.selectedItems.userHandles.filter(function(g){return g.name===t.id.split("_shape")[0]&&""!==g.template})[0].template=t.template}t.isTemplate&&t.template?o.appendChild(t.template):t.template&&o.appendChild(t.template.cloneNode(!0))}void 0!==s&&e.childNodes.length>s&&e.insertBefore(o,e.childNodes[parseInt(s.toString(),10)]),a.appendChild(o),e.appendChild(a)}var p=xn(t).topLeft;o.setAttribute("style","height:"+t.actualSize.height+"px; width:"+t.actualSize.width+"px;left:"+p.x+"px; top:"+p.y+"px;position:absolute;transform:rotate("+(t.rotateAngle+t.parentTransform)+"deg);pointer-events:"+(r?"all":"none")+";visibility:"+(t.visible?"visible":"hidden")+";opacity:"+t.style.opacity+";")},n.prototype.drawNativeContent=function(t,e,i,r,s){var o,a;if(s&&(o=s.getElementById(t.id+"_native_element"),a=s.getElementById(t.id+"_clip")),!o){(o=document.createElementNS("http://www.w3.org/2000/svg","g")).setAttribute("id",t.id+"_native_element"),o.appendChild(t.template.cloneNode(!0));var l=this.createGElement("g",{id:t.id+"_inner_native_element"});l.appendChild(o),e.appendChild(l)}a&&o.removeChild(a),o.setAttribute("style","visibility:"+(t.visible?"visible":"hidden")+";opacity:"+t.style.opacity+";"),this.setNativTransform(t,o,i,r),"Slice"===t.scale&&this.drawClipPath(t,o,i,r,s),ti(o,t.description?{role:"img","aria-label":t.description}:{})},n.prototype.setNativTransform=function(t,e,i,r){var s=0!==t.contentSize.width?t.contentSize.width:1,o=0!==t.contentSize.height?t.contentSize.height:1;e.setAttribute("transform","rotate("+t.parentTransform+","+t.offsetX+","+t.offsetY+") translate("+(t.offsetX-t.templatePosition.x*r/s-r*t.pivot.x)+","+(t.offsetY-t.templatePosition.y*i/o-i*t.pivot.y)+") scale("+r/s+","+i/o+")")},n.prototype.drawClipPath=function(t,e,i,r,s){var o=t.contentSize.width,a=t.contentSize.height,l=t.width/(r/o),h=t.height/(i/a),c=t.templatePosition.x+(t.width>=t.height?0:(o-l)/2),d=t.templatePosition.y+(t.height>=t.width?0:(a-h)/2),u=s.getElementById(t.id+"_clip");(u=document.createElementNS("http://www.w3.org/2000/svg","clipPath")).setAttribute("id",t.id+"_clip"),e.appendChild(u);var f=s.getElementById(t.id+"_clip_rect");return f=document.createElementNS("http://www.w3.org/2000/svg","rect"),u.appendChild(f),ti(f,{id:t.id+"_clip_rect",width:l.toString(),height:h.toString(),x:c.toString(),y:d.toString()}),lm()?e.setAttribute("clip-path","url("+location.protocol+"//"+location.host+location.pathname+"#"+t.id+"_clip)"):e.setAttribute("clip-path","url(#"+t.id+"_clip)"),e},n.prototype.renderGradient=function(t,e,i){var r,s,o,h,c,a=bT(i),l=a.getElementById(i+"gradient_pattern");if(l||(l=Fi("defs",{id:i+"gradient_pattern"}),a.insertBefore(l,a.firstChild)),bF(e.id),"None"!==t.gradient.type){for(var d=0;dt.width&&("Ellipsis"===t.textOverflow||"Clip"===t.textOverflow)&&"NoWrap"===t.textWrapping?0:.5*t.width:"right"===t.textAlign&&(c=1*t.width),s.x=0+c+(e?e.x:0),s.y=1.2+d-r.height/2,s},n}(),Rc=function(){function n(t,e,i){this.renderer=null,this.isSvgMode=!0,this.touchMove=void 0,this.transform={x:0,y:0},this.diagramId=t,this.element=xt(this.diagramId),this.svgRenderer=e,this.isSvgMode=i,this.renderer=i?new Kf:new bo}return n.prototype.setCursor=function(t,e){t.style.cursor=e},n.prototype.setLayers=function(){this.iconSvgLayer=this.element.getElementsByClassName("e-ports-expand-layer")[0],this.adornerSvgLayer=this.element.getElementsByClassName("e-adorner-layer")[0],this.nativeSvgLayer=this.element.getElementsByClassName("e-native-layer")[0],this.diagramSvgLayer=this.element.getElementsByClassName("e-diagram-layer")[0]},n.prototype.getAdornerLayer=function(){return ST(this.diagramId)},n.prototype.getParentSvg=function(t,e,i){return this.diagramId&&t&&t.id?t.id.split("_icon_content").length>1||t.id.split("_nodeport").length>1||t.elementActions&Xr.ElementIsPort?this.iconSvgLayer:e&&"selector"===e?this.adornerSvgLayer:t instanceof En?this.nativeSvgLayer:this.diagramSvgLayer:i},n.prototype.getParentElement=function(t,e,i,r){var s=e;if(i&&this.diagramId&&t&&t.id){t.id.split("_icon_content").length>1?(s=i.getElementById(this.diagramId+"_diagramExpander"),e=null):t.id.split("_nodeport").length>1?s=i.getElementById(this.diagramId+"_diagramPorts"):t instanceof En?(s=i.getElementById(this.diagramId+"_nativeLayer"),e=null):t.elementActions&Xr.ElementIsPort?(s=i.getElementById(this.diagramId+"_diagramPorts"),e=null):s=i.getElementById(this.diagramId+"_diagramLayer");var o=this.getGroupElement(t,e||s,r);s=o.g,o.svg&&(i=o.svg)}return{g:s,svg:i}},n.prototype.getGroupElement=function(t,e,i){var r,o,s=this.getParentSvg(t);if(e&&s){if(s&&!(r=s.getElementById(t.id+"_groupElement"))&&s!==this.nativeSvgLayer){var a=this.nativeSvgLayer;r=a.getElementById(t.id+"_groupElement"),o=a}r||(r=this.svgRenderer.createGElement("g",{id:t.id+"_groupElement"}),void 0!==i&&e.childNodes.length>i?e.insertBefore(r,e.childNodes[parseInt(i.toString(),10)]):e.appendChild(r))}return{g:r,svg:o}},n.prototype.renderElement=function(t,e,i,r,s,o,a,l,h,c,d){t instanceof Cs?(t.id=t.id?t.id:Qe(),this.renderContainer(t,e,i,r,s,o,a,l,h,c,d)):t instanceof xI?this.renderImageElement(t,e,r,s,a):t instanceof Ze?this.renderPathElement(t,e,r,s,a,h,d):t instanceof ai?this.renderTextElement(t,e,r,s,a,c):t instanceof En?this.renderNativeElement(t,e,r,s,a):t instanceof es?this.renderHTMLElement(t,e,i,r,s,a,l):this.renderRect(t,e,r,s,h)},n.prototype.drawSelectionRectangle=function(t,e,i,r,s,o){var a={width:i*o.scale,height:r*o.scale,x:.5+(t=(t+o.tx)*o.scale),y:.5+(e=(e+o.ty)*o.scale),fill:"transparent",stroke:"gray",angle:0,pivotX:.5,pivotY:.5,strokeWidth:1,dashArray:"6 3",opacity:1,visible:!0,id:s.id+"_selected_region"},l=this.getAdornerLayer();this.svgRenderer.updateSelectionRegion(l,a)},n.prototype.renderHighlighter=function(t,e,i){var r=t.actualSize.width||2,s=t.actualSize.height||2,o=t.offsetX-r*t.pivot.x,a=t.offsetY-s*t.pivot.y;this.svgRenderer.drawRectangle(e,{width:r*i.scale,height:s*i.scale,x:o=(o+i.tx)*i.scale,y:a=(a+i.ty)*i.scale,fill:"transparent",stroke:"#8CC63F",angle:t.rotateAngle,pivotX:t.pivot.x,pivotY:t.pivot.y,strokeWidth:4,dashArray:"",opacity:1,cornerRadius:0,visible:!0,id:e.id+"_highlighter",class:"e-diagram-highlighter"},this.diagramId,void 0,void 0,e)},n.prototype.renderSelectionRectangle=function(t,e,i,r){var s=t.actualSize.width||2,o=t.actualSize.height||2,a=t.offsetX-s*t.pivot.x,l=t.offsetY-o*t.pivot.y,h={width:s*i.scale,height:o*i.scale,x:a=(a+i.tx)*i.scale,y:l=(l+i.ty)*i.scale,fill:"transparent",stroke:"#00cc00",angle:t.rotateAngle,pivotX:t.pivot.x,pivotY:t.pivot.y,strokeWidth:r?2:1,dashArray:"",opacity:1,cornerRadius:0,visible:!0,id:t.id+"_highlighter",class:r?"e-diagram-first-selection-indicator e-diagram-selection-indicator":"e-diagram-selection-indicator"},c=this.getParentSvg(t,"selector");this.svgRenderer.drawRectangle(e,h,this.diagramId,void 0,void 0,c)},n.prototype.renderSelectionLine=function(t,e,i,r){var s=this.getBaseAttributes(t,i);s.data=t.absolutePath,s.id=s.id+"_highlighter";var o=t.description?t.description:t.id;this.isSvgMode||(s.x=t.flipOffset.x?t.flipOffset.x:s.x,s.y=t.flipOffset.y?t.flipOffset.y:s.y),i&&(s.x=s.x*i.scale,s.y=s.y*i.scale),s.stroke="#00cc00",s.strokeWidth=r?2:1,s.class=r?"e-diagram-first-selection-indicator e-diagram-selection-indicator":"e-diagram-selection-indicator";var a=this.getParentSvg(t,"selector");this.svgRenderer.drawPath(e,s,this.diagramId,void 0,a,o,i.scale)},n.prototype.renderStackHighlighter=function(t,e,i,r,s,o,a){var l=t.actualSize.width||2,h=t.offsetX-l*t.pivot.x,c=t.actualSize.height||2,d=t.offsetY-c*t.pivot.y;h=(h+i.tx)*i.scale;var u,f=t.bounds,p="";if(d=(d+i.ty)*i.scale,r)if(o){var v,y;u="M 0 0 L "+(2+(g=l*i.scale))+" 0 Z",v=t.actualSize.width/Number(f.width?f.width:1)*i.scale,y=t.actualSize.height/Number(f.height?f.height:1)*i.scale,p=MI(wI(xd("M7,4 L8,4 8,7 11,7 11,8 8,8 8,11 7,11 7,8 4,8 4,7 7,7 z M7.5,0.99999994C3.9160004,1 1,3.9160004 0.99999994,7.5 1,11.084 3.9160004,14 7.5,14 11.084,14 14,11.084 14,7.5 14,3.9160004 11.084,1 7.5,0.99999994 z M7.5,0 C11.636002,0 15,3.3639984 15,7.5 15,11.636002 11.636002,15 7.5,15 3.3640003,15 0,11.636002 0,7.5 0,3.3639984 3.3640003,0 7.5,0 z")),v+g+2,y-8,!1,f.x,f.y,0,0),s.y>=t.offsetY&&(d+=c)}else{var g;a&&s.y>=t.offsetY&&(d+=c*i.scale),u="M -10 -10 L 0 0 Z M -10 10 L 0 0 Z M 0 0 L "+(g=l*i.scale)+" 0 Z M "+g+" 0 L "+(g+10)+" 10 Z L "+(g+10)+" -10 Z"}else u="M 10 -10 L 0 0 Z M -10 -10 L 0 0 Z M 0 0 L 0 "+(g=c*i.scale)+" Z M 0 "+g+" L -10 "+(g+10)+" Z L 10 "+(g+10)+" Z",s.x>=t.offsetX&&(h+=l*i.scale);this.svgRenderer.drawPath(e,{data:u+p,width:l*i.scale,height:c*i.scale,x:h,y:d,fill:"transparent",stroke:"#8CC63F",angle:t.rotateAngle,pivotX:t.pivot.x,pivotY:t.pivot.y,strokeWidth:1,dashArray:"",opacity:1,visible:!0,id:e.id+"_stack_highlighter",class:"e-diagram-highlighter"},this.diagramId)},n.prototype.drawLine=function(t,e){this.svgRenderer.drawLine(t,e)},n.prototype.drawPath=function(t,e){this.svgRenderer.drawPath(t,e,this.diagramId)},n.prototype.renderResizeHandle=function(t,e,i,r,s,o,a,l,h,c,d){var u=t.offsetX-t.actualSize.width*t.pivot.x,f=t.offsetY-t.actualSize.height*t.pivot.y,p=t.actualSize.height,g=t.actualSize.width;if(!c&&i&bt.Rotate&&VI(this.rendererActions)&&!z3(this.rendererActions))this.renderPivotLine(t,e,o,s,a),this.renderRotateThumb(t,e,o,s,a);else if(this.touchMove){var v=document.getElementById("rotateThumb");v&&v.setAttribute("visibility","hidden")}this.renderBorder(t,e,o,l,h,c);var y=t.actualSize.width*r,S=t.actualSize.height*r;!h&&VI(this.rendererActions)&&!z3(this.rendererActions)&&(t.isTextAnnotation||(y>=40&&S>=40&&(s&mr.ResizeNorthWest&&this.renderCircularHandle("resizeNorthWest",t,u,f,e,qr(s,"ResizeNorthWest"),i&bt.ResizeNorthWest,o,void 0,a,{"aria-label":"Thumb to resize the selected object on top left side direction"},void 0,"e-diagram-resize-handle e-northwest",d),s&mr.ResizeNorthEast&&this.renderCircularHandle("resizeNorthEast",t,u+g,f,e,qr(s,"ResizeNorthEast"),i&bt.ResizeNorthEast,o,void 0,a,{"aria-label":"Thumb to resize the selected object on top right side direction"},void 0,"e-diagram-resize-handle e-northeast",d),s&mr.ResizeSouthWest&&this.renderCircularHandle("resizeSouthWest",t,u,f+p,e,qr(s,"ResizeSouthWest"),i&bt.ResizeSouthWest,o,void 0,a,{"aria-label":"Thumb to resize the selected object on bottom left side direction"},void 0,"e-diagram-resize-handle e-southwest",d),s&mr.ResizeSouthEast&&this.renderCircularHandle("resizeSouthEast",t,u+g,f+p,e,qr(s,"ResizeSouthEast"),i&bt.ResizeSouthEast,o,void 0,a,{"aria-label":"Thumb to resize the selected object on bottom right side direction"},void 0,"e-diagram-resize-handle e-southeast",d)),s&mr.ResizeNorth&&this.renderCircularHandle("resizeNorth",t,u+g/2,f,e,qr(s,"ResizeNorth"),i&bt.ResizeNorth,o,void 0,a,{"aria-label":"Thumb to resize the selected object on top side direction"},void 0,"e-diagram-resize-handle e-north",d),s&mr.ResizeSouth&&this.renderCircularHandle("resizeSouth",t,u+g/2,f+p,e,qr(s,"ResizeSouth"),i&bt.ResizeSouth,o,void 0,a,{"aria-label":"Thumb to resize the selected object on bottom side direction"},void 0,"e-diagram-resize-handle e-south",d),s&mr.ResizeWest&&this.renderCircularHandle("resizeWest",t,u,f+p/2,e,qr(s,"ResizeWest"),i&bt.ResizeWest,o,void 0,a,{"aria-label":"Thumb to resize the selected object on left side direction"},void 0,"e-diagram-resize-handle e-west",d),s&mr.ResizeEast&&this.renderCircularHandle("resizeEast",t,u+g,f+p/2,e,qr(s,"ResizeEast"),i&bt.ResizeEast,o,void 0,a,{"aria-label":"Thumb to resize the selected object on right side direction"},void 0,"e-diagram-resize-handle e-east",d)))},n.prototype.renderEndPointHandle=function(t,e,i,r,s,o,a,l,h,c){var p,g,d=t.sourcePoint,u=t.targetPoint,f=t.wrapper;if(this.renderCircularHandle("connectorSourceThumb",f,d.x,d.y,e,qr(r,"ConnectorSourceThumb"),i&bt.ConnectorSource,s,o,void 0,{"aria-label":"Thumb to move the source point of the connector"},void 0,"e-diagram-endpoint-handle e-sourceend",c),this.renderCircularHandle("connectorTargetThumb",f,u.x,u.y,e,qr(r,"ConnectorTargetThumb"),i&bt.ConnectorTarget,s,a,void 0,{"aria-label":"Thumb to move the target point of the connector"},void 0,"e-diagram-endpoint-handle e-targetend",c),l)if("Straight"===t.type&&t.segments.length>0)for(p=0;p0)for(p=0;p=3&&3===t.segments.length&&(S=1,b=t.segments.length-1),S=t.segments.length>t.maxSegmentThumb+2?2:S,b=t.segments.length>t.maxSegmentThumb+2?t.segments.length-2:b,1===t.segments.length&&t.segments[0].points.length<=2&&(S=1,b=t.segments.length),p=S;p=50&&i.allowDrag),this.renderOrthogonalThumb(t+"_"+(d+1),e,(i.points[parseInt(d.toString(),10)].x+i.points[d+1].x)/2,(i.points[parseInt(d.toString(),10)].y+i.points[d+1].y)/2,r,h,l,o,a,u)}else for(d=0;d=50&&i.allowDrag),this.renderOrthogonalThumb(t+"_"+(d+1),e,(i.points[parseInt(d.toString(),10)].x+i.points[d+1].x)/2,(i.points[parseInt(d.toString(),10)].y+i.points[d+1].y)/2,r,h,l,o,a,u)},n.prototype.renderOrthogonalThumb=function(t,e,i,r,s,o,a,l,h,c){var d,g,u=0,f=document.getElementById(this.diagramId);f&&(g=f.ej2_instances[0]);var y=h.constraints&qe.InheritSegmentThumbShape?g.segmentThumbShape:h.segmentThumbShape,b=h.constraints&qe.InheritSegmentThumbSize?g.segmentThumbSize:h.segmentThumbSize;if(d="horizontal"===a?function ure(n){return vre[""+n]}(y):c3(y),"Arrow"===y||"DoubleArrow"===y||"OpenArrow"===y)switch(c){case"Bottom":case"Right":u=180;break;default:u=0}else if("Fletch"===y||"OpenFetch"===y||"IndentedArrow"===y||"OutdentedArrow"===y)switch(c){case"Bottom":u=-90;break;case"Top":u=90;break;case"Right":u=180;break;default:u=0}var M={x:(i+l.tx)*l.scale-b/2,y:(r+l.ty)*l.scale-b/2,angle:u,fill:"#e2e2e2",stroke:"black",strokeWidth:1,dashArray:"",data:d,width:b,height:b,pivotX:.5,pivotY:.5,opacity:1,visible:o,id:t,class:"e-diagram-ortho-segment-handle"},w=ap(M.data),C=new me(M.width,M.height),D=new Ze;if(M.data=D.updatePath(M.data,w,C),this.touchMove){var A=document.getElementById(t);A?this.updateSegmentPosition(A,M):this.svgRenderer.drawPath(s,M,this.diagramId)}else this.svgRenderer.drawPath(s,M,this.diagramId)},n.prototype.renderPivotLine=function(t,e,i,r,s){var o=t,l=!!(r&mr.Rotate);s&&(l=!1);var h=this.getBaseAttributes(o,i);h.fill="None",h.stroke="black",h.strokeWidth=1,h.dashArray="2,3",h.visible=l;var c=i.scale;h.x*=c,h.y*=c,h.width*=c,h.height*=c,h.id="pivotLine",h.class="e-diagram-pivot-line";var u={x:o.actualSize.width*o.pivot.x*c,y:0};h.startPoint={x:o.actualSize.width*o.pivot.x*c,y:-20},h.endPoint=u,this.svgRenderer.drawLine(e,h)},n.prototype.renderBezierLine=function(t,e,i,r,s,o){var l=this.getBaseAttributes(e,o);l.id=t,l.stroke="black",l.strokeWidth=1,l.dashArray="3,3",l.fill="None",l.class="e-diagram-bezier-control-line",l.x=0,l.y=0;var h=o.scale,g={x:(s.x+o.tx)*h,y:(s.y+o.ty)*h};l.startPoint={x:(r.x+o.tx)*h,y:(r.y+o.ty)*h},l.endPoint=g,this.svgRenderer.drawLine(i,l)},n.prototype.renderCircularHandle=function(t,e,i,r,s,o,a,l,h,c,d,u,f,p){var g=e,v={x:i,y:r};if(0!==g.rotateAngle||0!==g.parentTransform){var y=Bi();qi(y,g.rotateAngle+g.parentTransform,g.offsetX,g.offsetY),v=Ke(y,v)}var S=this.getBaseAttributes(g);if(S.stroke="black",S.strokeWidth=1,void 0!==u?(S.id="segmentEnd_"+u,S.fill="#e2e2e2"):S.fill=h?"#8CC63F":"white",S.cornerRadius=p/2,S.angle=e.rotateAngle,S.id=t,S.visible=o,S.class=f,S.width=p,S.height=p,S.x=(v.x+l.tx)*l.scale,S.y=(v.y+l.ty)*l.scale,S.x=S.x-S.width/2,S.y=S.y-S.height/2,h&&(S.class+=" e-connected"),c&&(S.visible=!1),this.touchMove){var b=document.getElementById(t);if(b)this.updateResizeHandle(b,S);else{var M=this.getParentSvg(e,"selector");this.svgRenderer.drawRectangle(s,S,this.diagramId,!0,!0,M,d,!0,a)}}else M=this.getParentSvg(e,"selector"),this.svgRenderer.drawRectangle(s,S,this.diagramId,!0,!0,M,d,!0,a)},n.prototype.updateResizeHandle=function(t,e){ti(t,{id:e.id,x:e.x.toString(),y:e.y.toString(),width:e.width.toString(),height:e.height.toString(),visibility:e.visible?"visible":"hidden",transform:"rotate("+e.angle+","+(e.x+e.width/2)+","+(e.y+e.height/2)+")",rx:e.cornerRadius||0,ry:e.cornerRadius||0,opacity:e.opacity})},n.prototype.renderBezierHandle=function(t,e,i,r,s,o,a,l,h,c,d,u,f){var v,p=document.getElementById(this.diagramId);p&&(v=p.ej2_instances[0]);var y=e,S={x:i,y:r};if(0!==y.rotateAngle||0!==y.parentTransform){var b=Bi();qi(b,y.rotateAngle+y.parentTransform,y.offsetX,y.offsetY),S=Ke(b,S)}var D=a.constraints&qe.InheritSegmentThumbSize?v.segmentThumbSize:a.segmentThumbSize,A=c3(a.constraints&qe.InheritSegmentThumbShape?v.segmentThumbShape:a.segmentThumbShape),x=this.getBaseAttributes(y);x.stroke="black",x.strokeWidth=1,void 0!==d?(x.id="segmentEnd_"+d,x.fill="#e2e2e2"):x.fill=h?"#8CC63F":"white",x.angle=e.rotateAngle,x.id=t,x.visible=o,x.class=u,x.width=D,x.height=D,x.data=A,x.x=(S.x+l.tx)*l.scale,x.y=(S.y+l.ty)*l.scale,x.x=x.x-x.width/2,x.y=x.y-x.height/2,h&&(x.class+=" e-connected"),c&&(x.visible=!1);var P=ap(x.data),L=new me(x.width,x.height),O=new Ze;if(x.data=O.updatePath(x.data,P,L),this.touchMove){var N=document.getElementById(t);if(N)this.updateSegmentPosition(N,x);else{var T=this.getParentSvg(e,"selector");this.svgRenderer.drawPath(s,x,this.diagramId,!0,T)}}else T=this.getParentSvg(e,"selector"),this.svgRenderer.drawPath(s,x,this.diagramId,!0,T)},n.prototype.updateSegmentPosition=function(t,e){ti(t,{id:e.id,transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")translate("+e.x+","+e.y+")",visibility:e.visible?"visible":"hidden",opacity:e.opacity})},n.prototype.renderBorder=function(t,e,i,r,s,o){var l=this.getBaseAttributes(t,i);l.x*=i.scale,l.y*=i.scale,l.width*=i.scale,l.height*=i.scale,l.fill="transparent",l.stroke="#097F7F",l.strokeWidth=1.2,l.gradient=null,l.dashArray="6,3",l.class="e-diagram-selector",o&&(l.class+=" e-diagram-lane"),l.id="borderRect",l.id=this.rendererActions&Ga.DrawSelectorBorder?"borderRect_symbol":"borderRect",r||(l.class+=" e-disabled"),s&&(l.class+=" e-thick-border"),l.cornerRadius=0;var h=this.getParentSvg(t,"selector");this.svgRenderer.drawRectangle(e,l,this.diagramId,void 0,!0,h)},n.prototype.renderUserHandler=function(t,e,i,r,s,o){for(var l,a=t.wrapper,h=0,c=t.userHandles;h0||d.disableNodes&&t.nodes.length>0||"Drag"===s&&o)&&(l=!1);var u=document.getElementById(d.name+"_template_hiddenUserHandle");u&&(d.template=u.childNodes[0].cloneNode(!0));var f=rT(t,d,i);if(f.x=(f.x+i.tx)*i.scale,f.y=(f.y+i.ty)*i.scale,d.visible&&(d.visible=!!(t.constraints&mr.UserHandle)),l)if(d.pathData){var p=d.pathData?d.pathData:d.content,g=this.getBaseAttributes(a);g.id=d.name+"_userhandle",g.fill=d.backgroundColor,g.stroke=d.borderColor,g.strokeWidth=d.borderWidth,g.centerX=f.x,g.centerY=f.y,g.radius=.5*d.size,g.class="e-diagram-userhandle-circle",g.angle=0,g.visible=d.visible,g.opacity=1,this.svgRenderer.drawCircle(e,g,1,{"aria-label":d.name+"user handle"});var y=[];y=wI(y=xd(p));var S=ap(p),w=MI(y,(d.size-.45*d.size)/S.width,(d.size-.45*d.size)/S.height,!0,S.x,S.y,0,0);S=ap(w),this.svgRenderer.drawPath(e,C={x:f.x-S.width/2,y:f.y-S.height/2,angle:0,id:"",class:"e-diagram-userhandle-path",fill:d.pathColor,stroke:d.backgroundColor,strokeWidth:.5,dashArray:"",data:w,width:d.size-5,height:d.size-5,pivotX:0,pivotY:0,opacity:1,visible:d.visible},this.diagramId,void 0,void 0,{"aria-label":d.name+"user handle"})}else if(d.content){var D=new En(d.name,this.diagramId);D.content=d.content,D.offsetX=f.x,D.offsetY=f.y,D.id=d.name+"_shape",D.horizontalAlignment="Center",D.verticalAlignment="Center",D.visible=d.visible,D.setOffsetWithRespectToBounds(f.x,f.y,"Fraction"),D.relativeMode="Object",D.description=d.name||"User handle",D.measure(new me(d.size,d.size)),D.arrange(D.desiredSize),this.svgRenderer.drawNativeContent(D,e,d.size,d.size,this.adornerSvgLayer)}else if(d.source){var C,A=new xI;(C=this.getBaseAttributes(A,i)).width=d.size,C.height=d.size,C.x=f.x-d.size/2,C.y=f.y-d.size/2,C.sourceWidth=d.size,C.sourceHeight=d.size,C.alignment=A.imageAlign,C.source=d.source,C.scale=A.imageScale,C.visible=d.visible,C.description=d.name||"User handle",C.id=d.name+"_",this.renderer.drawImage(e,C,this.adornerSvgLayer,!1)}else{var x=new es(d.name,this.diagramId);x.offsetX=f.x,x.offsetY=f.y,x.id=d.name+"_shape",x.visible=d.visible,x.relativeMode="Object",x.template=d.template,x.measure(new me(d.size,d.size)),x.arrange(x.desiredSize),this.svgRenderer.drawHTMLContent(x,r,void 0,!0,void 0)}}},n.prototype.renderRotateThumb=function(t,e,i,r,s){new Ze;var a,l=new me;l.width=18,l.height=16;var d=!!(r&mr.Rotate);s&&(d=!1);var f=t.offsetX-t.actualSize.width*t.pivot.x+t.pivot.x*t.actualSize.width,p=t.offsetY-t.actualSize.height*t.pivot.y;if(a={x:(f=(f+i.tx)*i.scale)-.5*l.width,y:(p=(p+i.ty)*i.scale)-30-.5*l.height},0!==t.rotateAngle||0!==t.parentTransform){var g=Bi();qi(g,t.rotateAngle+t.parentTransform,(i.tx+t.offsetX)*i.scale,(i.ty+t.offsetY)*i.scale),a=Ke(g,a)}var v={x:a.x,y:a.y,angle:t.rotateAngle+t.parentTransform,fill:"#231f20",stroke:"black",strokeWidth:.5,dashArray:"",data:"M 16.856144362449648 10.238890446662904 L 18.000144362449646 3.437890446662903L 15.811144362449646 4.254890446662903 C 14.837144362449646 2.5608904466629028 13.329144362449647 1.2598904466629026 11.485144362449645 0.5588904466629026 C 9.375144362449646 - 0.24510955333709716 7.071144362449646 - 0.18010955333709716 5.010144362449646 0.7438904466629028 C 2.942144362449646 1.6678904466629028 1.365144362449646 3.341890446662903 0.558144362449646 5.452890446662903 C - 0.244855637550354 7.567890446662903 - 0.17985563755035394 9.866890446662904 0.7431443624496461 11.930890446662904 C 1.6681443624496461 13.994890446662904 3.343144362449646 15.575890446662903 5.457144362449647 16.380890446662903 C 6.426144362449647 16.7518904466629 7.450144362449647 16.9348904466629 8.470144362449647 16.9348904466629 C 9.815144362449647 16.9348904466629 11.155144362449647 16.6178904466629 12.367144362449647 15.986890446662901 L 11.351144362449647 14.024890446662901 C 9.767144362449647 14.8468904466629 7.906144362449647 14.953890446662902 6.237144362449647 14.3178904466629 C 4.677144362449647 13.7218904466629 3.444144362449647 12.5558904466629 2.758144362449647 11.028890446662901 C 2.078144362449646 9.501890446662903 2.031144362449646 7.802890446662903 2.622144362449646 6.243890446662903 C 3.216144362449646 4.6798904466629025 4.387144362449646 3.442890446662903 5.914144362449646 2.760890446662903 C 7.437144362449646 2.078890446662903 9.137144362449646 2.0298904466629026 10.700144362449645 2.6258904466629027 C 11.946144362449646 3.100890446662903 12.971144362449646 3.9538904466629026 13.686144362449646 5.049890446662903 L 11.540144362449645 5.850890446662903 L 16.856144362449648 10.238890446662904 Z",width:20,height:20,pivotX:0,pivotY:0,opacity:1,visible:d,id:"rotateThumb",class:"e-diagram-rotate-handle"};if(this.touchMove){var y=document.getElementById("rotateThumb");y?this.updateSegmentPosition(y,v):this.svgRenderer.drawPath(e,v,this.diagramId,!0,void 0,{"aria-label":"Thumb to rotate the selected object"})}else this.svgRenderer.drawPath(e,v,this.diagramId,!0,void 0,{"aria-label":"Thumb to rotate the selected object"})},n.prototype.renderPathElement=function(t,e,i,r,s,o,a){var l=this.getBaseAttributes(t,i,o);if(l.data=t.absolutePath,l.data=t.absolutePath,t.isPathPort&&a){l.x=a[t.id]?a[t.id].cx:l.x,l.y=a[t.id]?a[t.id].cy:l.y,t.bounds.x=l.x,t.bounds.y=l.y;var h=document.getElementById(this.diagramId);h&&"PortDrag"!==h.ej2_instances[0].eventHandler.currentAction&&(t.offsetX=l.x+t.width/2,t.offsetY=l.y+t.height/2)}var u=t.description?t.description:t.id;if(this.isSvgMode||(l.x=t.flipOffset.x?t.flipOffset.x:l.x,l.y=t.flipOffset.y?t.flipOffset.y:l.y),t.isExport){var f=t.absoluteBounds,p=xd(l.data),g=this.findAndStoreArcValues(p);l.arc=g,l.data=BF(t,f,0,l)}this.renderer.drawPath(e,l,this.diagramId,void 0,r,u)},n.prototype.findAndStoreArcValues=function(t){var e=[];return t.forEach(function(i){"A"===i.command&&e.push({r1:i.r1/2,r2:i.r2/2})}),e},n.prototype.renderSvgGridlines=function(t,e,i,r,s,o){var a=document.createElementNS("http://www.w3.org/2000/svg","pattern"),l=document.createElementNS("http://www.w3.org/2000/svg","defs");l.setAttribute("id",this.diagramId+"_grid_pattern_defn"),(t.constraints&Kt.ShowHorizontalLines||t.constraints&Kt.ShowVerticalLines)&&a.setAttribute("id",this.diagramId+"_pattern");var h=0,c=0,d=0,u=0,f=1,p=!1,g="Lines"===t.gridType,v=g?t.verticalGridlines.lineIntervals:t.verticalGridlines.dotIntervals,y=g?t.horizontalGridlines.lineIntervals:t.horizontalGridlines.dotIntervals;if(r.showRulers&&r.dynamicGrid&&s&&o)d=o.updateSegmentWidth(i.scale),u=s.updateSegmentWidth(i.scale),t.horizontalGridlines.scaledIntervals=[d/s.interval],t.verticalGridlines.scaledIntervals=[u/o.interval],p=!0;else{for(var S=0;S=2)for(;e>=2;)e/=2;else if(e<=.5)for(;e<=.5;)e*=2;var i;if(t.horizontalGridlines.scaledIntervals=t.horizontalGridlines.snapIntervals,t.verticalGridlines.scaledIntervals=t.verticalGridlines.snapIntervals,1!==e){var r=t.horizontalGridlines;for(r.scaledIntervals=[],i=0;ithis.groupElement.actualSize.height&&("Clip"===t.style.textOverflow||"Ellipsis"===t.style.textOverflow)&&(a.y=a.y+(a.height-this.groupElement.actualSize.height)/2),this.renderer.drawRectangle(e,a,this.diagramId,void 0,void 0,r),this.renderer.drawText(e,a,r,l,this.diagramId,t.isExport&&Math.min(t.exportScaleValue.x||t.exportScaleValue.y),this.groupElement),this.isSvgMode&&(t.doWrap=!1)},n.prototype.renderNativeElement=function(t,e,i,r,s){var o,a,l=this.getParentSvg(t,void 0,e)||r,h=this.getParentElement(t,e,l).g||e,c=this.getBaseAttributes(t,i);switch(c.fill="transparent",c.cornerRadius=t.cornerRadius,c.stroke="transparent",this.renderer.drawRectangle(e,c,this.diagramId,void 0,void 0,r),t.scale){case"None":o=t.contentSize.width,a=t.contentSize.height;break;case"Stretch":o=t.actualSize.width,a=t.actualSize.height;break;case"Meet":o=a=t.actualSize.width<=t.actualSize.height?t.actualSize.width:t.actualSize.height;break;case"Slice":o=a=t.actualSize.width>=t.actualSize.height?t.actualSize.width:t.actualSize.height}this.svgRenderer&&this.svgRenderer.drawNativeContent(t,h,a,o,l)},n.prototype.renderHTMLElement=function(t,e,i,r,s,o,a){var l=this.getBaseAttributes(t,r);l.fill="transparent",l.cornerRadius=t.cornerRadius,l.stroke="transparent",this.renderer.drawRectangle(e,l,this.diagramId,void 0,void 0,s),this.svgRenderer&&this.svgRenderer.drawHTMLContent(t,i.children[0],r,function Sse(n){var t=n.parentElement;do{if(gm(t,"e-diagram"))return!0;t=t.parentElement}while(t);return!1}(i),a)},n.prototype.renderImageElement=function(t,e,i,r,s){var o=this.getBaseAttributes(t,i);o.cornerRadius=0,this.renderer.drawRectangle(e,o,this.diagramId,void 0,void 0,r);var a,l,h,c,g,d=t.contentSize.width,u=t.contentSize.height,f=o.width/d,p=o.height/u;if("Stretch"===t.stretch)a=d*(g=Math.min(f,p)),l=u*g;else switch(t.stretch){case"Meet":a=d*(g=Math.min(f,p)),l=u*g,o.x+=Math.abs(o.width-a)/2,o.y+=Math.abs(o.height-l)/2;break;case"Slice":g=Math.max(f,p),h=o.width/(a=d*g)*d,c=o.height/(l=u*g)*u;break;case"None":a=d,l=u}o.width=a,o.height=l,o.sourceWidth=h,o.sourceHeight=c,o.source=t.source,o.alignment=t.imageAlign,o.scale=t.imageScale,o.description=t.description?t.description:t.id,this.renderer.drawImage(e,o,r,s)},n.prototype.renderContainer=function(t,e,i,r,s,o,a,l,h,c,d){var g,u={svg:s,g:e},f=document.getElementById(this.diagramId);if(f&&(g=f.ej2_instances[0]),this.diagramId&&(s=this.getParentSvg(t)||s,this.isSvgMode)){var v=this.getParentElement(t,e,s,l).g||e;s=this.getParentSvg(this.hasNativeParent(t.children))||s;var y=this.getParentElement(this.hasNativeParent(t.children),v,s,l);u.svg=y.svg||s,u.g=y.g||v,o&&s&&(s.getElementById(u.g.id)||e.appendChild(u.g)),e=u.g}if(this.renderRect(t,e,r,s),this.groupElement=t,t.hasChildren()){for(var b,S=void 0,M=0,w=t.children;M0&&(D=g.selectedItems.nodes[0]);var L,A=void 0,x=void 0,P=!1;if(g&&g.selectedItems&&(L=g.getObject(t.id)),"None"!==t.flip&&(D=L),"None"===t.flip&&(D=L),D&&D.flipMode&&(P=!0),!(t.elementActions&Xr.ElementIsGroup)&&g instanceof _l&&g.nameTable[t.id]&&"connectors"!==g.nameTable[t.id].propName&&P&&D){if(A=t.children&&t.children[0]instanceof En?document.getElementById(D.id+"_content_inner_native_element"):document.getElementById(D.id+"_content_groupElement"),!(t.children[0]instanceof En)&&"Text"!==D.shape.type&&"None"!==D.flipMode&&"Label"!==D.flipMode&&"All"!==D.flipMode&&"PortAndLabel"!==D.flipMode&&"LabelText"!==D.flipMode&&"PortAndLabelText"!==D.flipMode&&"LabelAndLabelText"!==D.flipMode||t.children[0]instanceof En&&"Port"===D.flipMode)return void this.renderFlipElement(t,A,D.flip);if((t.children[0]instanceof En&&("All"===D.flipMode||"Label"===D.flipMode)||"Label"===D.flipMode||"PortAndLabel"===D.flipMode||"LabelText"===D.flipMode||"PortAndLabelText"===D.flipMode||"LabelAndLabelText"===D.flipMode||"Image"===D.shape.type&&"Label"===D.flipMode)&&this.renderFlipElement(t,A,t.flip),"None"!==t.flip&&"None"===D.flipMode)this.renderFlipElement(t,A,t.flip);else if("None"!==t.flip&&("Label"===D.flipMode||"PortAndLabel"===D.flipMode||"LabelText"===D.flipMode||"PortAndLabelText"===D.flipMode||"LabelAndLabelText"===D.flipMode)||t.children[0]instanceof En&&"None"!==t.flip&&D&&("None"===D.flipMode||"All"===D.flipMode)){for(var O=0;O0){var i=t[0];if(i instanceof En)return i;i.children&&i.children.length&&this.hasNativeParent(i.children,e++||0)}},n.prototype.renderRect=function(t,e,i,r,s){var o=this.getBaseAttributes(t,i,s);o.cornerRadius=t.cornerRadius||0,t.isExport&&(o.cornerRadius*=t.exportScaleValue.x),this.renderer.drawRectangle(e,o,this.diagramId,t.isExport,void 0,r,t.description?t.description:t.id)},n.prototype.drawRect=function(t,e){e.cornerRadius=0,this.svgRenderer.drawRectangle(t,e,this.diagramId)},n.prototype.getBaseAttributes=function(t,e,i){var r={width:t.actualSize.width,height:t.actualSize.height,x:t.offsetX-t.actualSize.width*t.pivot.x,y:t.offsetY-t.actualSize.height*t.pivot.y,fill:t.style.fill,stroke:t.style.strokeColor,angle:t.rotateAngle+t.parentTransform,pivotX:t.pivot.x,pivotY:t.pivot.y,strokeWidth:t.style.strokeWidth,dashArray:t.style.strokeDashArray||"",opacity:t.style.opacity,shadow:t.shadow,gradient:t.style.gradient,visible:t.visible,id:t.id,description:t.description,canApplyStyle:t.canApplyStyle,shapeType:t.shapeType};return"Page"===t.rotationReference&&(r.angle=t.rotateAngle),i&&(r.x=r.x-.5,r.y=r.y-.5),t.isExport&&(r.width*=t.exportScaleValue.x,r.height*=t.exportScaleValue.y,r.x*=t.exportScaleValue.x,r.y*=t.exportScaleValue.y,r.strokeWidth*=t.exportScaleValue.x),t.flip&&(r.flip=t.flip),e&&(r.x+=e.tx,r.y+=e.ty),r},n.renderSvgBackGroundImage=function(t,e,i,r,s,o){if(t.source){var l=bT(e.id).getElementById(e.id+"_image");if(!l){var h=function Toe(n){return xt(n).getElementsByClassName("e-background-image-layer")[0]}(e.id);(l=document.createElementNS("http://www.w3.org/2000/svg","image")).setAttribute("id",e.id+"_image"),h.appendChild(l)}var c=new Image;c.src=t.source,l.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",c.src.toString());var d="None"!==t.scale?t.scale:"",u=t.align,f=u.charAt(0).toLowerCase()+u.slice(1);d&&(f+=" "+d.charAt(0).toLowerCase()+d.slice(1)),ti(l,{id:e.id+"_image",x:i,y:r,width:s,height:o,preserveAspectRatio:f})}},n.prototype.transformLayers=function(t,e){var i=t.tx*t.scale,r=t.ty*t.scale,s="domTable";if(i!==this.transform.x||r!==this.transform.y||0===i||0===r){e&&(window[""+s][this.diagramId+"_diagramLayer"]||(window[""+s][this.diagramId+"_diagramLayer"]=this.diagramSvgLayer.getElementById(this.diagramId+"_diagramLayer")),window[""+s][this.diagramId+"_diagramLayer"].setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+"),scale("+t.scale+")"));var a=function Aoe(n){var t="domTable",e=null;return window[t][n+"_gridline"]?e=window[t][n+"_gridline"]:(e=Ud(n).getElementById(n+"_gridline"),window[t][n+"_gridline"]=e),e}(this.diagramId);return a.setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+")"),window[""+s][this.diagramId+"_diagramPorts"]||(window[""+s][this.diagramId+"_diagramPorts"]=this.iconSvgLayer.getElementById(this.diagramId+"_diagramPorts")),window[""+s][this.diagramId+"_diagramPorts"].setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+"),scale("+t.scale+")"),window[""+s][this.diagramId+"_diagramExpander"]||(window[""+s][this.diagramId+"_diagramExpander"]=this.iconSvgLayer.getElementById(this.diagramId+"_diagramExpander")),window[""+s][this.diagramId+"_diagramExpander"].setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+"),scale("+t.scale+")"),window[""+s][this.diagramId+"_nativeLayer"]||(window[""+s][this.diagramId+"_nativeLayer"]=this.nativeSvgLayer.getElementById(this.diagramId+"_nativeLayer")),window[""+s][this.diagramId+"_nativeLayer"].setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+"),scale("+t.scale+")"),Io(this.diagramId).children[0].style.transform="translate("+t.tx*t.scale+"px,"+t.ty*t.scale+"px)scale("+t.scale+")",this.transform={x:t.tx*t.scale,y:t.ty*t.scale},!0}return!1},n.prototype.updateNode=function(t,e,i,r,s,o,a){this.renderElement(t,e,i,r,this.getParentSvg(t),void 0,void 0,s,null,o,a)},n}(),use=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),rb=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},uF=function(n){function t(e,i){var r=n.call(this,e,i)||this;return r.mode="Canvas",r.id="overview",r.actionName="",r.startPoint=null,r.currentPoint=null,r.prevPoint=null,r.scale=null,r.inAction=!1,r.viewPortRatio=1,r.horizontalOffset=0,r.verticalOffset=0,r.model={},r.event=!0,r.overviewid=88123,r.model={width:r.width,height:r.height},r}return use(t,n),t.prototype.onPropertyChanged=function(e,i){for(var r=0,s=Object.keys(e);r0||e.toString().indexOf("%")>0?e.toString():e.toString()+"px"},t.prototype.renderCanvas=function(e){var i=document.getElementById(this.element.id+"_canvas");i||(i=Tt("div",{}),this.element.appendChild(i)),Ho(i,{id:this.element.id+"_canvas",class:"drawing",style:"position:relative; height:"+this.getSizeValue(this.model.height)+"; width:"+this.getSizeValue(this.model.width)+";style:-ms-touch-action: none;touch-action: none;"}),this.element.setAttribute("tabindex",String(-1)),this.element.style.overflow="hidden",this.element.style.height=String(this.model.height),this.element.style.width=String(this.model.width),this.canvas=i},t.prototype.setParent=function(e){var i=document.getElementById(e);if(this.parent){var s=this.parent;this.parent=null,s.setOverview(null,this.element.id),this.removeDocument(this)}this.parent=this.getDiagram(i,"ej2_instances"),this.parent&&this.parent.setOverview(this)},t.prototype.getDiagram=function(e,i){for(var r,s=e[""+i].length,o=0;o0?f:Math.floor(window.innerWidth)}if(0===h){var p=Math.floor(window.innerHeight-u-Math.floor(c.top));h=p>0?p:Math.floor(window.innerHeight)}l>0&&(s.setAttribute("width",String(l)),this.model.height=h),h>0&&(s.setAttribute("height",String(h)),this.model.width=l),e.diagramLayerDiv||(e.diagramLayerDiv=Tt("div",{}),e.diagramLayer=bo.createCanvas(this.element.id+"_diagramLayer",this.model.width,this.model.height),e.diagramLayer.setAttribute("style","position:absolute; left:0px; top:0px "),e.diagramLayerDiv.appendChild(e.diagramLayer),e.canvas.appendChild(e.diagramLayerDiv)),Ho(e.diagramLayerDiv,{id:this.element.id+"_diagramLayer_div",style:"width:"+this.model.width+"px; height:"+this.model.height+"px;position:absolute;top:0px;left:0px"}),this.renderHtmlLayer(e.canvas),this.renderNativeLayer(e.canvas,e),this.addOverviewRectPanel(e)},t.prototype.removeDocument=function(e){var i=document.getElementById(this.canvas.id+"_svg");this.canvas.removeChild(i);var r=document.getElementById(this.element.id+"_htmlLayer");this.canvas.removeChild(r);var s=document.getElementById(this.element.id+"_diagramLayer_div");this.canvas.removeChild(s),e.diagramLayerDiv=null,e.diagramLayer=null,window.domTable[this.id+"html_layer"]=null},t.prototype.renderHtmlLayer=function(e){var i=Tt("div",{id:this.element.id+"_htmlLayer",class:"e-html-layer",style:"pointer-events:none;position:absolute;top:0px;left:0px;"}),s=Tt("div",{id:this.element.id+"_htmlLayer_div",style:"position:absolute;top:0px;left:0px;"});return i.appendChild(s),e.appendChild(i),i},t.prototype.renderNativeLayer=function(e,i){if(!document.getElementById(this.element.id+"_nativeLayer_svg")){var r=this.parent.createSvg(this.element.id+"_nativeLayer_svg",this.model.width,this.model.height),s=Fi("g",{id:this.element.id+"_nativeLayer"});r.appendChild(s),i.diagramLayerDiv.appendChild(r),ti(r,{class:"e-native-layer"})}},t.prototype.addOverviewRectPanel=function(e){var i=document.getElementById(this.canvas.id+"_overviewsvg");i&&i.parentNode.removeChild(i),i=Fi("svg",{id:this.canvas.id+"_overviewsvg",class:"overviewsvg",version:"1.1",style:"position:absolute;left:0px;top:0px; aria-label:Specifies overview",width:this.model.width,height:this.model.height}),e.canvas.appendChild(i);var s=Fi("g",{id:this.element.id+"_overviewlayer",style:"pointer-events:none"});i.appendChild(s);var o=Fi("rect",{fill:"transparent",width:"100%",height:"100%",class:"overviewbackrect",id:this.canvas.id+"overviewbackrect"});o.setAttribute("style"," pointer-events: none; "),s.appendChild(o);var a=Fi("g",{id:this.canvas.id+"overviewhandle",style:"pointer-events:all"});s.appendChild(a);var l=Fi("rect",{id:this.canvas.id+"overviewrect",fill:"transparent"});a.appendChild(l),this.renderOverviewCorner("left",a),this.renderOverviewCorner("right",a),this.renderOverviewCorner("top",a),this.renderOverviewCorner("bottom",a),this.renderOverviewCorner("topleft",a),this.renderOverviewCorner("topright",a),this.renderOverviewCorner("bottomleft",a),this.renderOverviewCorner("bottomright",a)},t.prototype.renderOverviewCorner=function(e,i){var s,o=Fi(s="top"===e||"bottom"===e||"right"===e||"left"===e?"rect":"circle",{id:this.canvas.id+"visible"+e,class:"overview-resizer"});i.appendChild(o);var a=Fi(s,{id:this.canvas.id+e,class:"overviewresizer",fill:"transparent"});i.appendChild(a)},t.prototype.updateOverviewRectangle=function(){var e=this.currentPoint.x-this.prevPoint.x,i=this.currentPoint.y-this.prevPoint.y,r=new me;r.width=0,r.height=0;var s=0,o=0;switch(this.resizeDirection){case"left":r.width-=e,r.height-=e/this.viewPortRatio,s=e,o=e/this.viewPortRatio,o/=2;break;case"right":r.width+=e,r.height+=e/this.viewPortRatio,o=e/this.viewPortRatio,o/=-2;break;case"top":r.height-=i,r.width-=i*this.viewPortRatio,o=i,s=i*this.viewPortRatio,s/=2;break;case"bottom":r.height+=i,r.width+=i*this.viewPortRatio,s=i*this.viewPortRatio,s/=-2;break;case"topleft":Math.abs(i)>Math.abs(e)?e=i*this.viewPortRatio:i=e/this.viewPortRatio,r.width-=e,r.height-=i,s=e,o=i;break;case"topright":Math.abs(i)>Math.abs(e)?e=-i*this.viewPortRatio:i=-e/this.viewPortRatio,o=i,r.width+=e,r.height-=i;break;case"bottomleft":Math.abs(i)>Math.abs(e)?e=-i*this.viewPortRatio:i=-e/this.viewPortRatio,s=e,r.width-=e,r.height+=i;break;case"bottomright":Math.abs(i)>Math.abs(e)?e=i*this.viewPortRatio:i=e/this.viewPortRatio,r.width+=e,r.height+=i}this.updateHelper(s,o,r,void 0,void 0)},t.prototype.updateHelper=function(e,i,r,s,o){var a,l,h,u,f,d=this.element.getElementsByTagName("svg")[2].getElementById("helper");r?(a=(h=d.getBBox()).x+e,l=h.y+i,s=h.width+r.width,o=h.height+r.height):(u=this.currentPoint.x>this.startPoint.x?this.currentPoint.x-this.prevPoint.x:this.prevPoint.x-this.currentPoint.x,f=this.currentPoint.y>this.startPoint.y?this.currentPoint.y-this.prevPoint.y:this.prevPoint.y-this.currentPoint.y,Math.abs(f)>Math.abs(u)?u=this.viewPortRatio*f:f=u/this.viewPortRatio,h=d.getBBox(),a=this.startPoint.x>this.currentPoint.x?h.x-u:h.x,l=this.startPoint.y>this.currentPoint.y?h.y-f:h.y,s=h.width+u,o=h.height+f),ti(this.helper,{id:this.helper.id,x:a,y:l,width:Math.max(0,s),height:Math.max(0,o)})},t.prototype.updateOverviewrect=function(e,i,r,s){Ho(document.getElementById(this.canvas.id+"overviewrect"),{x:e,y:i,width:Math.max(1,r),height:Math.max(1,s)}),this.updateOverviewCorner("top",e+8,i+1,Math.max(0,r-16),2),this.updateOverviewCorner("bottom",e+8,i+s+3,Math.max(0,r-16),2),this.updateOverviewCorner("left",e-2,i+11,2,Math.max(0,s-16)),this.updateOverviewCorner("right",e+r,i+11,2,Math.max(0,s-16)),this.updateOverviewCorner("topleft",e,i+3,5,5),this.updateOverviewCorner("topright",e+r,i+3,5,5),this.updateOverviewCorner("bottomleft",e,i+s+3,5,5),this.updateOverviewCorner("bottomright",e+r,i+s+3,5,5)},t.prototype.updateOverviewCorner=function(e,i,r,s,o){var a,l;"top"===e||"bottom"===e||"right"===e||"left"===e?(a={x:i,y:r,width:s,height:o,fill:"#ED1C24"},l={x:i-2,y:r-2,width:2===s?4:s,height:2===o?4:o}):(a={cx:i,cy:r,r:4,fill:"#ED1C24"},l={cx:i,cy:r,r:6,fill:"transparent"}),Ho(document.getElementById(this.canvas.id+"visible"+e),a),Ho(document.getElementById(this.canvas.id+e),l)},t.prototype.translateOverviewRectangle=function(){Number(this.model.width),Number(this.model.height);var r=this.currentPoint.x-this.prevPoint.x,s=this.currentPoint.y-this.prevPoint.y,l=this.element.getElementsByClassName("overviewsvg")[0].getElementById(this.canvas.id+"overviewrect").getBBox(),h=l.x+r,c=l.y+s,d=l.width,u=l.height;this.updateOverviewrect(h,c,d,u),this.updateParentView(this.parent.scroller.currentZoom,h,c,d,u,null)},t.prototype.renderOverviewRect=function(e,i,r,s){var o=Number(this.model.width),a=Number(this.model.height),c=Math.max(this.parent.scroller.viewPortWidth/(r/o*this.contentWidth),this.parent.scroller.viewPortHeight/(s/a*this.contentHeight));if(c>=.25&&c<=30){this.updateParentView(c,e,i,r,s,{x:0,y:0});var u=this.scrollOverviewRect(this.parent.scroller.horizontalOffset,this.parent.scroller.verticalOffset,this.parent.scroller.currentZoom,!0);if(this.helper){var p=this.element.getElementsByTagName("rect")[10].getBBox();u.x=p.x,u.y=p.y}"pan"===this.actionName?this.updateOverviewrect(-u.x,-u.y,u.width,u.height):this.updateOverviewrect(u.x,u.y,u.width,u.height)}},t.prototype.scrollOverviewRect=function(e,i,r,s){if(!this.actionName||s){var o=Number(this.model.width),a=Number(this.model.height),l=Math.min(this.contentWidth/o,this.contentHeight/a),h=new Ne,c=h.x=e/r/l,d=h.y=i/r/l,u=0;this.parent.rulerSettings.showRulers&&(u=25);var f=document.getElementById(this.parent.element.id+"content"),p=0,g=0;f&&(p=f.offsetWidth-f.clientWidth,g=f.offsetHeight-f.clientHeight);var v=h.width=(this.parent.scroller.viewPortWidth-u-p)/r/l,y=h.height=(this.parent.scroller.viewPortHeight-u-g)/r/l;if(s){var S=new Ne;return S.x=c,S.y=d,S.width=v,S.height=y,S}this.updateOverviewrect(-c,-d,v,y)}return null},t.prototype.updateParentView=function(e,i,r,s,o,a){var p,g,l=Number(this.model.width),h=Number(this.model.height),u=i*(this.contentWidth/l)*e,f=r*(this.contentHeight/h)*e;this.parent.scroller.getPageBounds(),(1!==e||"pan"===this.actionName)&&(p=-u-this.parent.scroller.horizontalOffset,g=-f-this.parent.scroller.verticalOffset),this.parent.setBlazorDiagramProps(!0),this.parent.realActions|=$i.OverViewAction,"scale"===this.actionName||"draw"===this.actionName?this.parent.scroller.zoom(e/this.parent.scroller.currentZoom,p,g,a):ce()?this.parent.scroller.zoom(1,p,g,a):this.parent.pan(p,g,a,!0)},t.prototype.updateHtmlLayer=function(e){var i=Io(e.element.id),r=this.parent.scroller.getPageBounds(!0),o=r.height,a=Math.max(r.width,this.parent.scroller.viewPortWidth),l=Math.max(o,this.parent.scroller.viewPortHeight/this.parent.scroller.currentZoom),h=Math.min(Number(this.model.width)/a,Number(this.model.height)/l);i.style.transform="scale("+h+") translate("+this.parent.scroller.transform.tx+"px,"+this.parent.scroller.transform.ty+"px)"},t.prototype.updateView=function(e){var i=this.parent.scroller.getPageBounds(),r=i.width,s=i.height,o=Number(this.model.width),a=Number(this.model.height),l=Math.max(r,this.parent.scroller.viewPortWidth),h=Math.max(s,this.parent.scroller.viewPortHeight);this.contentWidth=l=Math.max(l,o/a*h),this.contentHeight=h=Math.max(h,a/o*l);var c=Math.min(o/l,a/h),d=document.getElementById(this.element.id+"_htmlLayer");d.style.webkitTransform="scale("+c+") translate("+-i.x+"px,"+-i.y+"px)",d.style.transform="scale("+c+") translate("+-i.x+"px,"+-i.y+"px)",document.getElementById(this.element.id+"_overviewlayer").setAttribute("transform","translate("+-i.x*c+","+-i.y*c+")"),this.horizontalOffset=i.x*c,this.verticalOffset=i.y*c;var f=document.getElementById(this.element.id+"_diagramLayer"),p=UF(this.element.id),g=f.getContext("2d"),v=Number(this.model.width)/this.contentWidth,y=Number(this.model.height)/this.contentHeight;v=Math.min(v,y);var S=this.parent.scroller.transform;p.setAttribute("transform","translate("+S.tx*v+","+S.ty*y+"),scale("+v+")"),g.setTransform(v,0,0,v,0,0),g.fillStyle="red",this.scrollOverviewRect(this.parent.scroller.horizontalOffset,this.parent.scroller.verticalOffset,this.parent.scroller.currentZoom)},t.prototype.scrolled=function(e){if(this.event){var i=this.scrollOverviewRect(this.parent.scroller.horizontalOffset,this.parent.scroller.verticalOffset,this.parent.scroller.currentZoom,!0);this.updateOverviewrect(-i.x,-i.y,i.width,i.height),this.updateView(this)}},t.prototype.updateCursor=function(e){if(gm(e.target,"overviewresizer"))switch(e.target.id){case this.canvas.id+"left":this.canvas.style.cursor="w-resize";break;case this.canvas.id+"right":this.canvas.style.cursor="e-resize";break;case this.canvas.id+"top":this.canvas.style.cursor="n-resize";break;case this.canvas.id+"bottom":this.canvas.style.cursor="s-resize";break;case this.canvas.id+"topleft":this.canvas.style.cursor="nw-resize";break;case this.canvas.id+"topright":this.canvas.style.cursor="ne-resize";break;case this.canvas.id+"bottomleft":this.canvas.style.cursor="sw-resize";break;case this.canvas.id+"bottomright":this.canvas.style.cursor="se-resize"}else this.canvas.style.cursor="default"},t.prototype.mouseMove=function(e){if(this.event=!1,this.updateCursor(e),this.currentPoint=this.mousePosition(e),this.actionName)switch(this.actionName){case"draw":!this.inAction&&(this.startPoint.x!==this.currentPoint.x||this.startPoint.y!==this.currentPoint.y)&&(this.initHelper(),this.inAction=!0),this.inAction&&this.updateHelper();break;case"scale":this.inAction||(this.initHelper(),this.inAction=!0),this.updateOverviewRectangle();break;case"pan":(this.startPoint.x!==this.currentPoint.x||this.startPoint.y===this.currentPoint.y||this.inAction)&&(this.inAction=!0,this.translateOverviewRectangle())}this.prevPoint=this.currentPoint},t.prototype.documentMouseUp=function(e){this.inAction=!1,this.actionName="",this.helper&&(this.helper.parentNode.removeChild(this.helper),this.helper=null),this.event=!0,document.getElementById(this.canvas.id+"overviewhandle").style.pointerEvents="all"},t.prototype.windowResize=function(e){var i=this;return this.resizeTo&&clearTimeout(this.resizeTo),this.resizeTo=setTimeout(function(){var s=document.getElementById(i.element.id).getBoundingClientRect();i.model.width=s.width>0?s.width:i.model.width,i.model.height=s.height>0?s.height:i.model.height,i.renderCanvas(),i.setParent(i.sourceID)},10),!1},t.prototype.mouseDown=function(e){if(e.target.id===this.canvas.id+"_overviewsvg"&&(this.actionName="draw"),e.target.id===this.canvas.id+"overviewrect"&&(this.actionName="pan"),gm(e.target,"overviewresizer"))switch(this.actionName="scale",e.target.id){case this.canvas.id+"left":this.resizeDirection="left";break;case this.canvas.id+"right":this.resizeDirection="right";break;case this.canvas.id+"top":this.resizeDirection="top";break;case this.canvas.id+"bottom":this.resizeDirection="bottom";break;case this.canvas.id+"topleft":this.resizeDirection="topleft";break;case this.canvas.id+"topright":this.resizeDirection="topright";break;case this.canvas.id+"bottomleft":this.resizeDirection="bottomleft";break;case this.canvas.id+"bottomright":this.resizeDirection="bottomright"}this.startPoint=this.prevPoint=this.mousePosition(e),this.viewPortRatio=this.parent.scroller.viewPortWidth/this.parent.scroller.viewPortHeight,document.getElementById(this.canvas.id+"overviewhandle").style.pointerEvents="none"},t.prototype.mouseUp=function(e){if(this.currentPoint=this.mousePosition(e),this.actionName)if(this.startPoint.x!==this.currentPoint.x||this.startPoint.y!==this.currentPoint.y){if("pan"!==this.actionName&&this.helper){var i=this.element.getElementsByTagName("rect")[10].getBBox();this.resizeDirection=this.resizeDirection||"",this.renderOverviewRect(i.x,i.y,o=i.width,a=i.height)}}else if(e.target.id===this.canvas.id+"_overviewsvg"||"helper"===e.target.id){var o=(i=this.element.getElementsByTagName("svg")[2].getElementById(this.canvas.id+"overviewrect").getBBox()).width,a=i.height;this.inAction=!0,this.actionName="pan",this.renderOverviewRect(this.currentPoint.x-o/2,this.currentPoint.y-a/2,o,a),this.inAction=!1}this.helper&&(this.helper.parentNode.removeChild(this.helper),this.helper=null),this.actionName="",this.startPoint=null,this.currentPoint=null,this.prevPoint=null,this.helper=null,this.viewPortRatio=1,this.resizeDirection="",this.inAction=!1,this.event=!0,document.getElementById(this.canvas.id+"overviewhandle").style.pointerEvents="all"},t.prototype.initHelper=function(){var e=this.element.getElementsByTagName("svg")[2],i=this.startPoint.x,r=this.startPoint.y,s=1,o=1;if("scale"===this.actionName){var l=e.getElementById(this.canvas.id+"overviewrect").getBBox();i=l.x,r=l.y,s=l.width,o=l.height}var h=Fi("rect",{id:"helper",x:i,y:r,width:s,height:o,fill:"transparent",stroke:"gray","stroke-dasharray":"2 2","shape-rendering":"crispEdges"});e.getElementById(this.element.id+"_overviewlayer").appendChild(h),this.helper=h},t.prototype.mousePosition=function(e){var i,r,s;-1!==e.type.indexOf("touch")?(r=(i=e).changedTouches[0].clientX-this.element.offsetLeft,s=i.changedTouches[0].clientY-this.element.offsetTop):(r=e.clientX,s=e.clientY);var l=this.element.getBoundingClientRect();return{x:(r-=l.left)+this.horizontalOffset,y:(s-=l.top)+this.verticalOffset}},t.prototype.destroy=function(){if(this.unWireEvents(),this.notify("destroy",{}),n.prototype.destroy.call(this),document.getElementById(this.element.id)){this.element.classList.remove("e-overview");var e=document.getElementById(this.element.id+"_canvas");e&&this.element.removeChild(e)}this.parent.views.splice(this.parent.views.indexOf(this.element.id),1),this.diagramLayerDiv=null,this.canvas=null,this.parent=null},t.prototype.getModuleName=function(){return"Overview"},rb([I("100%")],t.prototype,"width",void 0),rb([I("100%")],t.prototype,"height",void 0),rb([I("")],t.prototype,"sourceID",void 0),rb([H()],t.prototype,"created",void 0),t}(Ii);function pse(n,t){for(var e=0;eR.findLength(e,n)?e:t;var o=R.findAngle(t,e),a=R.findAngle(i,n),l=R.findLength(i,n),h=a+2*(o-a);return{x:i.x+l*Math.cos(h*Math.PI/180),y:i.y+l*Math.sin(h*Math.PI/180)}}function ep(n,t,e){if(n&&n.children&&n.children.length>0)for(var r=void 0,s=0;s0&&"annotations"!==r&&"ports"!==r)if(n[""+l].length>0)for(var h=0;h<=n[""+l].length;h++)Ro(n[""+l],t?t[""+l]:void 0,e[""+l],"annotations"===l||"ports"===l?n:void 0,l);else Ro(n[""+l],t?t[""+l]:void 0,e[""+l],"annotations"===l||"ports"===l?n:void 0,l);else if(s instanceof Object&&t&&"annotations"!==r&&"ports"!==r)Ro(n[""+l],t[""+l],e[""+l]);else if("annotations"!==r&&"ports"!==r&&t&&!t[""+l]||!t&&n&&(n[""+l]||void 0!==n[""+l]))n[""+l]=e[""+l];else{var c=void 0;("annotations"===r||"ports"===r)&&("annotations"===r?(n[""+l]&&Ro(n[""+l],t[""+l],e[""+l]),n[""+l]||(ps(i)===de?(c=new Or(i,"annotations",e[""+l]),i.annotations.push(c)):(c=new Kn(i,"annotations",e[""+l]),i.annotations.push(c)))):n[""+l]?Ro(n[""+l],t[""+l],e[""+l]):(c=new Es(i,"ports",e[""+l]),i.ports.push(c)))}}}function bse(n,t){for(var e="Bezier"===n.type?function yse(n){var t=[];if("Bezier"===n.type)for(var e=0,i=0;i0||n.ports.length>0){var f=n.wrapper.children;for(i=3;i0)return{enabled:!1,intersectPt:e};var l=o/s,h=a/s;return l>=0&&l<=1&&h>=0&&h<=1?(e.x=i.x1+l*(i.x2-i.x1),e.y=i.y1+l*(i.y2-i.y1),{enabled:!0,intersectPt:e}):{enabled:!1,intersectPt:e}}function sb(n,t,e,i){var a=nm(vF(n.x,n.y,t.x,t.y),vF(e.x,e.y,i.x,i.y));return a.enabled?a.intersectPt:{x:0,y:0}}function vF(n,t,e,i){return{x1:Number(n)||0,y1:Number(t)||0,x2:Number(e)||0,y2:Number(i)||0}}function mF(n,t,e){var i=[],s={x:t.topRight.x+(e=e||0),y:t.topRight.y},o={x:t.bottomRight.x,y:t.bottomRight.y-e},a={x:t.bottomLeft.x,y:t.bottomLeft.y+e};return i.push({x:t.topLeft.x-e,y:t.topLeft.y}),i.push(s),i.push(o),i.push(a),i}function Hc(n,t,e,i,r,s){var o={},a=e.scroller.transform.scale,h=e.scroller.verticalOffset;return o.x=(i?n.x:t.x)*a+e.scroller.horizontalOffset-r,o.y=(i?n.y:t.y)*a+h-s,o}function yF(n,t){var e=new Ze;return e.data=n.pathData,e.height=n.height>10?n.height-(n.padding.bottom+n.padding.top):n.height,e.width=n.width>10?n.width-(n.padding.left+n.padding.right):n.width,e.visible=n.visibility,e.id=t.id+"_shape",e.inversedAlignment=!1,e.horizontalAlignment="Center",e.verticalAlignment="Center",e.style={fill:n.iconStrokeColor,strokeColor:n.iconStrokeColor,strokeWidth:n.iconStrokeWidth},e.setOffsetWithRespectToBounds(.5,.5,"Fraction"),e.relativeMode="Object",e.description=t.description||"",e}function Jx(n,t,e){var i=Kx(n,t),r=R.findAngle(n[i.index],n[i.index+1]),s=function Tse(n){var t;t=n instanceof kI?0:void 0===n.content?10:0;var e=0;switch(n.alignment){case"Center":e=0;break;case"Before":e=-(0+t);break;case"After":e=0+t}return e}(t),o=R.transform(i.point,r+45,s);return i.point=o,i.angle=r,i}function Kx(n,t){for(var r,s,a,l,e=0,i=t.offset,o=[],h=0;h=c)return s=R.findAngle(n[parseInt(d.toString(),10)],n[d+1]),{point:r=R.transform(n[parseInt(d.toString(),10)],s,c-(a||0)),index:l=d};a=o[parseInt(d.toString(),10)]}return{point:r,index:l}}function SF(n,t,e){t%=360;var a,l,s=225;switch(n.alignment){case"Before":t>=45&&t<=135?(l="right",a=.5===n.offset?"center":"top"):t>=s&&t<=315?(l="left",a=.5===n.offset?"center":"bottom"):t>45&&t=45&&t<=135?(l="left",a=.5===n.offset?"center":"top"):t>=s&&t<=315?(l="right",a=.5===n.offset?"center":"bottom"):t>45&&tMath.abs(t.y-n.y)?n.x0)for(var e=0;e=0;r--)("nodes"===i||"connectors"===i)&&(n[""+i][parseInt(r.toString(),10)].wrapper=null),"dataManager"!==i&&(n[""+i][parseInt(r.toString(),10)]=iT(n[""+i][parseInt(r.toString(),10)],e[""+i][parseInt(r.toString(),10)],void 0!==t[""+i]?t[""+i][parseInt(r.toString(),10)]:[]),("[]"===JSON.stringify(n[""+i][parseInt(r.toString(),10)])||"{}"===JSON.stringify(n[""+i][parseInt(r.toString(),10)])||void 0===n[""+i][parseInt(r.toString(),10)])&&n[""+i].splice(r,1));n=void 0}function Hh(n,t){var e=t.style,i=t;t.canApplyStyle=!0;for(var r=0,s=Object.keys(n);r=0&&n.splice(e,1)}function tp(n,t,e){var i;n.intermediatePoints=t,n.updateSegmentElement(n,t,n.wrapper.children[0],e);var r=n.sourceDecorator;if("Bezier"===n.type){var s=n.segments[0],o=n.segments[n.segments.length-1];i=[R.isEmptyPoint(o.point2)?o.bezierPoint2:o.point2,R.isEmptyPoint(s.point1)?s.bezierPoint1:s.point1]}else i=n.intermediatePoints;t=n.clipDecorators(n,t,e);var a=n.wrapper.children[0];a.canMeasurePath=!0,n.updateDecoratorElement(a=n.wrapper.children[1],t[0],i[1],r),n.updateDecoratorElement(a=n.wrapper.children[2],t[t.length-1],i[i.length-2],n.targetDecorator),n.updateShapeElement(n)}function rT(n,t,e){var l,i=n.wrapper,s=t.offset,o=t.size/e.scale,a=t.margin,h=i.offsetX-i.actualSize.width*i.pivot.x,c=i.offsetY-i.actualSize.height*i.pivot.y;if(l={x:0,y:0},n.nodes.length>0){switch(t.side){case"Top":l.x+=h+s*i.actualSize.width,l.y+=c-o;break;case"Bottom":l.x+=h+s*i.actualSize.width,l.y+=c+i.actualSize.height+o;break;case"Left":l.x+=h-o,l.y+=c+s*i.actualSize.height;break;case"Right":l.x+=h+i.actualSize.width+o,l.y+=c+s*i.actualSize.height}l.x+=(a.left-a.right)/e.scale+o/2*("Center"===t.horizontalAlignment?0:"Right"===t.horizontalAlignment?-1:1),l.y+=(a.top-a.bottom)/e.scale+o/2*("Center"===t.verticalAlignment?0:"Top"===t.verticalAlignment?-1:1)}else if(n.connectors.length>0){var d=n.connectors[0],u={offset:s},f=Kx(d.intermediatePoints,u),p=f.index;l=f.point;var y,v=Jx(d.intermediatePoints,u).angle;qi(y=Bi(),-v,d.intermediatePoints[parseInt(p.toString(),10)].x,d.intermediatePoints[parseInt(p.toString(),10)].y),(l=Ke(y,l)).x+=a.left-a.right+o/2*("Center"===t.horizontalAlignment?0:"Right"===t.horizontalAlignment?-1:1),l.y+=a.top-a.bottom+o/2*("Center"===t.verticalAlignment?0:"Top"===t.verticalAlignment?-1:1),qi(y=Bi(),v,d.intermediatePoints[parseInt(p.toString(),10)].x,d.intermediatePoints[parseInt(p.toString(),10)].y),l=Ke(y,l)}return 0===i.rotateAngle&&0===i.parentTransform||(qi(y=Bi(),i.rotateAngle+i.parentTransform,i.offsetX,i.offsetY),l=Ke(y,l)),l}function ga(n,t,e,i){if(i.annotation){if(zl(i.annotation))return!0}else if(mr[""+t]&n&&bt[""+t]&e)return!0;return!1}function qr(n,t){return!!(mr[""+t]&n)}function Fc(n,t){return!!(Ex[""+t]&n)}function va(n,t){return n.visibility&t}function ob(n,t){var e;if("Text"===n.shape.type)e=n.shape;else{var i=t.split("_");t=i[i.length-1];for(var r=0;rn[""+t]?e.splice(0,0,n):e.push(n);else if(e.length>1){for(var i=0,r=e.length-1,s=Math.floor((i+r)/2);s!==i;)if(e[parseInt(s.toString(),10)][""+t]n[""+t]))break;r=s,s=Math.floor((i+r)/2)}e[parseInt(r.toString(),10)][""+t]n[""+t]?e.splice(i,0,n):e[parseInt(i.toString(),10)][""+t]n[""+t]&&e.splice(r,0,n)}}function Qse(n){var t=document.getElementById(n.diagramId),e="ej2_instances",i=t[""+e][0].nodes;void 0===i&&(i=function Gse(n){for(var t=[],e=0;e30?10:o/2;for(var h=0,c=0;c=l){var u=l-h;r=Gt(n[c],n[c+1]),s=R.transform(n[c],r,u);break}h+=d}return s},hb=function(n,t){if(n instanceof te||n instanceof de)for(var e=0;e=0||navigator.platform.indexOf("iPad")>=0||navigator.platform.indexOf("iPhone")>=0||navigator.platform.indexOf("MacIntel")>=0)&&("safari"===X.info.name||"webkit"===X.info.name)}function AF(n,t,e,i){return void 0!==t.previewSize[""+i]?t.previewSize[""+i]:void 0!==n.symbolPreview[""+i]?n.symbolPreview[""+i]:t[""+i]||e.actualSize[""+i]}function hm(n,t,e){return n&&n.parentId&&(e=(n=t.nameTable[n.parentId]).parentId?hm(n,t,e):n.id),e}function cm(n,t){return n.selectedItems.connectors.length>1&&0===n.selectedItems.nodes.length&&0!==t.rotateAngle}function Zse(n){if(n.arrowType&&""!==n.arrowType.trim())switch(n.arrowType){case"single-line-arrow":default:return{targetDecorator:"Arrow",strokeWidth:1};case"double-line-arrow":return{targetDecorator:"Arrow",strokeWidth:2};case"dotted-arrow":return{targetDecorator:"Arrow",strokeDashArray:"2,2"};case"single-line":return{targetDecorator:"None",strokeWidth:1};case"double-line":return{targetDecorator:"None",strokeWidth:2};case"dotted":return{targetDecorator:"None",strokeDashArray:"2,2"};case"wiggly-arrow":return{targetDecorator:"None",strokeWidth:1,opacity:0}}return{targetDecorator:"Arrow",strokeWidth:1}}var Jse=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),no=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},LF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Jse(t,n),no([I("None")],t.prototype,"shape",void 0),no([I("white")],t.prototype,"fill",void 0),no([I("Auto")],t.prototype,"horizontalAlignment",void 0),no([I("Auto")],t.prototype,"verticalAlignment",void 0),no([I(10)],t.prototype,"width",void 0),no([I(10)],t.prototype,"height",void 0),no([re({x:.5,y:1},R)],t.prototype,"offset",void 0),no([I("#1a1a1a")],t.prototype,"borderColor",void 0),no([I(1)],t.prototype,"borderWidth",void 0),no([re({},Jn)],t.prototype,"margin",void 0),no([I("")],t.prototype,"pathData",void 0),no([I("")],t.prototype,"content",void 0),no([I(0)],t.prototype,"cornerRadius",void 0),no([re({left:2,right:2,top:2,bottom:2},Jn)],t.prototype,"padding",void 0),no([I("#1a1a1a")],t.prototype,"iconColor",void 0),t}(Ee),Kse=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),aT=function(n){function t(){var e=null!==n&&n.apply(this,arguments)||this;return e.orientation="Vertical",e.measureChildren=void 0,e.considerPadding=!0,e}return Kse(t,n),t.prototype.measure=function(e){return this.desiredSize=this.measureStackPanel(e,"Horizontal"===this.orientation?this.updateHorizontalStack:this.updateVerticalStack),this.desiredSize},t.prototype.arrange=function(e){return this.actualSize=this.arrangeStackPanel(e,"Horizontal"===this.orientation?this.arrangeHorizontalStack:this.arrangeVerticalStack),this.updateBounds(),this.actualSize},t.prototype.measureStackPanel=function(e,i){var r=void 0;if(void 0!==this.children&&this.children.length>0)for(var s=0,o=this.children;s0){var r=void 0,s=void 0;r=this.offsetX-e.width*this.pivot.x+this.padding.left,s=this.offsetY-e.height*this.pivot.y+this.padding.top;for(var o=0,a=this.children;o0)for(var i=0,r=this.children;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},aoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return ooe(t,n),Bh([I("Horizontal")],t.prototype,"orientation",void 0),Bh([I("Center")],t.prototype,"type",void 0),Bh([I(void 0)],t.prototype,"offset",void 0),Bh([I(!1)],t.prototype,"enableRouting",void 0),Bh([I([])],t.prototype,"children",void 0),Bh([I("")],t.prototype,"assistants",void 0),Bh([I("")],t.prototype,"level",void 0),Bh([I("")],t.prototype,"hasSubTree",void 0),Bh([I("")],t.prototype,"rows",void 0),t}(Ee),Ni=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),q=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},loe=function(n){if(n)switch(n.type){case"Basic":default:return cb;case"Flow":return PF;case"Path":return NF;case"Image":return kF;case"Text":return Hd;case"Bpmn":return fT;case"Native":return dm;case"HTML":return OF;case"UmlActivity":return zF;case"UmlClassifier":return RF;case"SwimLane":return _d}return cb},ma=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),q([I("Basic")],t.prototype,"type",void 0),t}(Ee),NF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"Path"},q([I("Path")],t.prototype,"type",void 0),q([I("")],t.prototype,"data",void 0),t}(ma),dm=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"Native"},q([I("Native")],t.prototype,"type",void 0),q([I("")],t.prototype,"content",void 0),q([I("Stretch")],t.prototype,"scale",void 0),t}(ma),OF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"Html"},q([I("HTML")],t.prototype,"type",void 0),q([I("")],t.prototype,"content",void 0),t}(ma),kF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"Image"},q([I("Image")],t.prototype,"type",void 0),q([I("")],t.prototype,"source",void 0),q([I("None")],t.prototype,"scale",void 0),q([I("None")],t.prototype,"align",void 0),t}(ma),Hd=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"Text"},q([I("Text")],t.prototype,"type",void 0),q([I("")],t.prototype,"content",void 0),q([re({},Jn)],t.prototype,"margin",void 0),t}(ma),cb=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"BasicShape"},q([I("Basic")],t.prototype,"type",void 0),q([I("Rectangle")],t.prototype,"shape",void 0),q([I(0)],t.prototype,"cornerRadius",void 0),q([Bt([],R)],t.prototype,"points",void 0),t}(ma),PF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"FlowShape"},q([I("Flow")],t.prototype,"type",void 0),q([I("Terminator")],t.prototype,"shape",void 0),t}(ma),hT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"BpmnGateway"},q([I("None")],t.prototype,"type",void 0),t}(Ee),cT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"BpmnDataObject"},q([I("None")],t.prototype,"type",void 0),q([I(!1)],t.prototype,"collection",void 0),t}(Ee),hoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),q([I("None")],t.prototype,"type",void 0),q([I("None")],t.prototype,"loop",void 0),q([I(!1)],t.prototype,"call",void 0),q([I(!1)],t.prototype,"compensation",void 0),t}(Ee),dT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"BpmnEvent"},q([I("Start")],t.prototype,"event",void 0),q([I("None")],t.prototype,"trigger",void 0),t}(Ee),Bd=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"BpmnSubEvent"},q([I("None")],t.prototype,"trigger",void 0),q([I("Start")],t.prototype,"event",void 0),q([I("")],t.prototype,"id",void 0),q([re({},R)],t.prototype,"offset",void 0),q([Bt([],Kn)],t.prototype,"annotations",void 0),q([Bt([],Es)],t.prototype,"ports",void 0),q([I()],t.prototype,"width",void 0),q([I()],t.prototype,"height",void 0),q([re({},Jn)],t.prototype,"margin",void 0),q([I("Center")],t.prototype,"horizontalAlignment",void 0),q([I("Center")],t.prototype,"verticalAlignment",void 0),q([I(!0)],t.prototype,"visible",void 0),t}(Ee),coe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),q([re({id:"success",event:"End",offset:{x:1,y:.5}},Bd)],t.prototype,"success",void 0),q([re({id:"failure",event:"Intermediate",trigger:"Error",offset:{x:.25,y:1}},Bd)],t.prototype,"failure",void 0),q([re({id:"cancel",event:"Intermediate",trigger:"Cancel",offset:{x:.75,y:1}},Bd)],t.prototype,"cancel",void 0),t}(Ee),doe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),q([I("None")],t.prototype,"type",void 0),q([I(!1)],t.prototype,"adhoc",void 0),q([I("Default")],t.prototype,"boundary",void 0),q([I(!1)],t.prototype,"compensation",void 0),q([I("None")],t.prototype,"loop",void 0),q([I(!0)],t.prototype,"collapsed",void 0),q([Bt([],Bd)],t.prototype,"events",void 0),q([re({},coe)],t.prototype,"transaction",void 0),q([I(void 0)],t.prototype,"processes",void 0),t}(Ee),uT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"BpmnActivity"},q([I("Task")],t.prototype,"activity",void 0),q([re({},hoe)],t.prototype,"task",void 0),q([re({},doe)],t.prototype,"subProcess",void 0),t}(Ee),um=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return Ni(t,n),t.prototype.getClassName=function(){return"BpmnAnnotation"},q([I("")],t.prototype,"text",void 0),q([I("")],t.prototype,"id",void 0),q([I(0)],t.prototype,"angle",void 0),q([I()],t.prototype,"height",void 0),q([I()],t.prototype,"width",void 0),q([I(0)],t.prototype,"length",void 0),t}(Ee),uoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),q([I("")],t.prototype,"textAnnotationTarget",void 0),q([I("Auto")],t.prototype,"textAnnotationDirection",void 0),t}(Ee),fT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"BpmnShape"},q([I("Bpmn")],t.prototype,"type",void 0),q([I("Event")],t.prototype,"shape",void 0),q([re({},dT)],t.prototype,"event",void 0),q([re({},hT)],t.prototype,"gateway",void 0),q([re({},cT)],t.prototype,"dataObject",void 0),q([re({},uT)],t.prototype,"activity",void 0),q([re({},um)],t.prototype,"annotation",void 0),q([Bt([],um)],t.prototype,"annotations",void 0),q([re({},uoe)],t.prototype,"textAnnotation",void 0),t}(ma),zF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"UmlActivityShape"},q([I("UmlActivity")],t.prototype,"type",void 0),q([I("Action")],t.prototype,"shape",void 0),t}(ma),pT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"MethodArguments"},q([I("")],t.prototype,"name",void 0),q([I("")],t.prototype,"type",void 0),q([re({},qf)],t.prototype,"style",void 0),t}(Ee),op=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"UmlClassAttribute"},q([I("Public")],t.prototype,"scope",void 0),q([I(!1)],t.prototype,"isSeparator",void 0),q([re({fill:"#F9F9F9",strokeColor:"#CCCCCC"},Nl)],t.prototype,"separatorStyle",void 0),t}(pT),fm=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"UmlClassMethod"},q([Bt([],pT)],t.prototype,"parameters",void 0),t}(op),db=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"UmlClass"},q([I("")],t.prototype,"name",void 0),q([Bt([],op)],t.prototype,"attributes",void 0),q([Bt([],fm)],t.prototype,"methods",void 0),q([re({},qf)],t.prototype,"style",void 0),t}(Ee),gT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"UmlInterface"},q([I(!1)],t.prototype,"isSeparator",void 0),q([re({fill:"#F9F9F9",strokeColor:"#CCCCCC"},Nl)],t.prototype,"separatorStyle",void 0),t}(db),ub=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"UmlEnumerationMember"},q([I("")],t.prototype,"name",void 0),q([I("")],t.prototype,"value",void 0),q([I(!1)],t.prototype,"isSeparator",void 0),q([re({fill:"#F9F9F9",strokeColor:"#CCCCCC"},Nl)],t.prototype,"separatorStyle",void 0),q([re({},qf)],t.prototype,"style",void 0),t}(Ee),vT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"UmlEnumeration"},q([I("")],t.prototype,"name",void 0),q([Bt([],ub)],t.prototype,"members",void 0),q([re({},qf)],t.prototype,"style",void 0),t}(Ee),RF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"UmlClassifierShape"},q([I("UmlClassifier")],t.prototype,"type",void 0),q([re({},db)],t.prototype,"classShape",void 0),q([re({},gT)],t.prototype,"interfaceShape",void 0),q([re({},vT)],t.prototype,"enumerationShape",void 0),q([I("Class")],t.prototype,"classifier",void 0),t}(ma),te=function(n){function t(e,i,r,s){var a,o=n.call(this,e,i,r,s)||this;return o.isCanvasUpdate=!1,o.status="None",o.parentId="",o.processId="",o.umlIndex=-1,o.outEdges=[],o.inEdges=[],o.isHeader=!1,o.isLane=!1,o.isPhase=!1,o.children&&o.children.length>0&&((!(a=r).style||!a.style.fill)&&(o.style.fill="transparent"),(!a.style||!a.style.strokeColor)&&(o.style.strokeColor="transparent")),o.shape&&"UmlActivity"===o.shape.type&&nb(r,o),o.shape&&"SwimLane"===o.shape.type&&fF(r,o),o.ports&&o.ports.length&&function vse(n){for(var t=0;t>";t=n;break;case"FinalNode":t=IF(e)}return t}(new Ze,i,this);break;case"Bpmn":if(e.bpmnModule){i=e.bpmnModule.initBPMNContent(i,this,e),this.wrapper.elementActions=this.wrapper.elementActions|Xr.ElementIsGroup;var v=this.shape.activity.subProcess;if(v.processes&&v.processes.length)for(var S=0,b=this.shape.activity.subProcess.processes;S>",margin:{left:10,right:10},id:"class",style:{fontSize:i.style.fontSize,color:i.style.color,fill:i.style.fill,textWrapping:r},offset:{x:.5,y:.3},constraints:Nr.ReadOnly}],constraints:(ie.Default|ie.HideThumbs)&~(ie.Rotate|ie.Drag|ie.Resize),verticalAlignment:"Stretch",horizontalAlignment:"Stretch",style:{fill:t.style.fill,strokeColor:"black"===t.style.strokeColor?"#ffffff00":t.style.strokeColor}},!0);return e.initObject(s),e.nodes.push(s),e.UpdateBlazorDiagramModel(s,"Node"),t.children.push(s.id),function toe(n,t,e,i){if("Enumeration"===n.shape.classifier){var r=e.members;if(r&&r.length){np(n,t);for(var s="",o=0;o0)for(var o=0;o0&&s.phaseSize&&(i+=s.phaseSize,$v(n,s.phaseSize)),s.lanes.length>0)for(o=0;o0){var a=0;for(o=0;o0&&"Horizontal"===r.orientation)for(l=0;l0&&(i+=r.phaseSize,o=Zv(r.phaseSize),n.push(o)),a=0;a0&&o.phaseSize){for(var l=0;l0)for(l=0;l0?e.nameTable[this.nodes[0].id].wrapper:e.nameTable[this.connectors[0].id].wrapper,this.annotation.id);i.children.push(s)}else if(this.nodes||this.connectors){for(var o=0;o-1}function VF(n,t,e){n=[];for(var i=0,r=e.length;i0?c.getElementsByTagName("svg")[0].outerHTML:c.getElementsByTagName("g").length>0?c.getElementsByTagName("g")[0].outerHTML:"",s.shape.content=h,n.content=h,c.parentElement.removeChild(c)}l="nodeTemplate"}else a=s,l="annotationTemplate";var p=document.getElementById(n.diagramId).ej2_instances[0];if("string"!=typeof n.content&&"function"!=typeof n.content||n.isTemplate)if(n.isTemplate){if(v=void 0,v=p.isReact?n.getNodeTemplate()($(e),p,l+"_"+("nodeTemplate"===l?e.id:n.nodeId+e.id),void 0,void 0,!1,i):p.isVue||p.isVue3?n.getNodeTemplate()?n.getNodeTemplate()($(e),p,l+"_"+("nodeTemplate"===l?e.id:n.nodeId+e.id),void 0,void 0,!1,i):(v=si("nodeTemplate"===l?p.nodeTemplate:p.annotationTemplate))($(e),p,l+"_"+("nodeTemplate"===l?e.id:n.nodeId+e.id),void 0,void 0,!1,i):n.getNodeTemplate()($(e),p,l+"_"+("nodeTemplate"===l?e.id:n.nodeId+e.id),void 0,void 0,!1))for(var M=0;M=1&&0===n.x&&("Clip"===i.textOverflow||"Ellipsis"===i.textOverflow)&&("Wrap"===i.textWrapping||"WrapWithOverflow"===i.textWrapping)&&(n.x=t[e-1]?t[e-1].x:-n.width/2),n.x}function QF(n,t,e,i){return e&&!t.template||t.template&&"function"==typeof t.template&&i.isReact?(n.isTemplate=!0,n.template=n.content=Fh(n,!0,t)):n.content=t.template,n}function Qe(){for(var e,t="",i=0;i<5;i++){if(typeof window<"u"&&"crypto"in window&&"getRandomValues"in crypto){var r=new Uint16Array(1);e=(window.msCrypto||window.crypto).getRandomValues(r)[0]%60}else e=Math.floor(61*Math.random());0===i&&e<10?i--:t+="0123456789ABCDEFGHIJKLMNOPQRSTUVWXTZabcdefghiklmnopqrstuvwxyz".substring(e,e+1)}return t}function GF(n){if(n)try{return"function"!=typeof n&&document.querySelectorAll(n).length?si(document.querySelector(n).innerHTML.trim()):si(n)}catch{return si(n)}}function xn(n){new Ne;var e=n.offsetY-n.actualSize.height*n.pivot.y,i=n.offsetY+n.actualSize.height*(1-n.pivot.y),r=n.offsetX-n.actualSize.width*n.pivot.x,s=n.offsetX+n.actualSize.width*(1-n.pivot.x);return Ne.toBounds([{x:r,y:e},{x:s,y:e},{x:r,y:i},{x:s,y:i}])}function yr(n){var t=new Ne,e=xn(n),i=e.middleLeft,r=e.topCenter,s=e.bottomCenter,o=e.middleRight,a=e.topLeft,l=e.topRight,h=e.bottomLeft,c=e.bottomRight;if(n.corners={topLeft:a,topCenter:r,topRight:l,middleLeft:i,middleRight:o,bottomLeft:h,bottomCenter:s,bottomRight:c},0!==n.rotateAngle||0!==n.parentTransform){var d=Bi();qi(d,n.rotateAngle+n.parentTransform,n.offsetX,n.offsetY),n.corners.topLeft=a=Ke(d,a),n.corners.topCenter=r=Ke(d,r),n.corners.topRight=l=Ke(d,l),n.corners.middleLeft=i=Ke(d,i),n.corners.middleRight=o=Ke(d,o),n.corners.bottomLeft=h=Ke(d,h),n.corners.bottomCenter=s=Ke(d,s),n.corners.bottomRight=c=Ke(d,c)}return t=Ne.toBounds([a,l,h,c]),n.corners.left=t.left,n.corners.right=t.right,n.corners.top=t.top,n.corners.bottom=t.bottom,n.corners.center=t.center,n.corners.width=t.width,n.corners.height=t.height,t}function $(n,t,e,i){var r={},s="properties";if(n){e=n.propName;var l=[],h=[];if((l=l.concat(Object.keys(n[""+s]||n))).push("version"),e){var c=Zi(t);h=c?c(e):[],l=l.concat(h)}for(var d=function Ooe(n){switch(n){case"nodes":case"children":return["inEdges","outEdges","parentId","processId","nodeId","umlIndex","isPhase","isLane"];case"connectors":return["parentId"];case"annotation":case"annotations":return["nodeId"];case"shape":return["hasHeader"];case"layers":return["objectZIndex"]}return[]}(e),u=0,f=l=l.concat(d);u0&&(e=r),r=Math.floor(Poe(e,i)),s=_c(o+=n.substr(e,r),t)}while(s<=t.width);for(o=o.substr(0,e),a=e;a=t.width){n=n.substr(0,o.length-1);break}return"Ellipsis"===t.textOverflow?(n=n.substr(0,n.length-3),n+="..."):n=n.substr(0,n.length),n}function wT(n,t){if("NoWrap"===t&&"PreserveAll"===n)return"pre";var e="";switch(n){case"CollapseAll":e="nowrap";break;case"CollapseSpace":e="pre-line";break;case"PreserveAll":e="pre-wrap"}return e}function CT(n,t){var e=Bi();qi(e,t,0,0);var i=Ke(e,{x:0,y:0}),r=Ke(e,{x:n.width,y:0}),s=Ke(e,{x:0,y:n.height}),o=Ke(e,{x:n.width,y:n.height}),a=Math.min(i.x,r.x,s.x,o.x),l=Math.min(i.y,r.y,s.y,o.y),h=Math.max(i.x,r.x,s.x,o.x),c=Math.max(i.y,r.y,s.y,o.y);return new me(h-a,c-l)}function xs(n,t,e,i){if(0!==n){var r=Bi();return qi(r,n,t,e),Ke(r,i)}return i}function Zi(n){return void 0!==n&&"string"==typeof n&&(n=Y(n,window)),n}var bo=function(){function n(){}return n.getContext=function(t){return t.getContext("2d")},n.setCanvasSize=function(t,e,i){t&&(t.setAttribute("width",e.toString()),t.setAttribute("height",i.toString()))},n.prototype.renderGradient=function(t,e,i,r){var s,o,a;if("None"!==t.gradient.type){for(var l=0;l0?(w=0===S.r1?e.arc[parseInt(r.toString(),10)].r1:S.r1,C=0===S.r2?e.arc[parseInt(r.toString(),10)].r2:S.r2,r++):(w=S.r1,C=S.r2);var D=S.angle*(Math.PI/180),A=S.largeArc,x=S.sweep,P={x:u,y:f},L={x:Math.cos(D)*(M.x-P.x)/2+Math.sin(D)*(M.y-P.y)/2,y:-Math.sin(D)*(M.x-P.x)/2+Math.cos(D)*(M.y-P.y)/2},O=Math.pow(L.x,2)/Math.pow(w,2)+Math.pow(L.y,2)/Math.pow(C,2);O>1&&(w*=Math.sqrt(O),C*=Math.sqrt(O));var N=Math.pow(C,2)*Math.pow(L.x,2),T=(A===x?-1:1)*Math.sqrt((Math.pow(w,2)*Math.pow(C,2)-Math.pow(w,2)*Math.pow(L.y,2)-N)/(Math.pow(w,2)*Math.pow(L.y,2)+Math.pow(C,2)*Math.pow(L.x,2)));isNaN(T)&&(T=0);var z={x:T*w*L.y/C,y:T*-C*L.x/w},U={x:(M.x+P.x)/2+Math.cos(D)*z.x-Math.sin(D)*z.y,y:(M.y+P.y)/2+Math.sin(D)*z.x+Math.cos(D)*z.y},B=this.a([1,0],[(L.x-z.x)/w,(L.y-z.y)/C]),j=[(L.x-z.x)/w,(L.y-z.y)/C],Q=[(-L.x-z.x)/w,(-L.y-z.y)/C],oe=this.a(j,Q);this.r(j,Q)<=-1&&(oe=Math.PI),this.r(j,Q)>=1&&(oe=0);var fe=B+oe/2*(x?1:-1);if(Math.cos(fe),Math.sin(fe),S.centp=U,S.xAxisRotation=D,S.rx=w,S.ry=C,S.a1=B,S.ad=oe,S.sweep=x,null!=s){var De=w>C?w:C,xe=w>C?1:w/C,Ie=w>C?C/w:1;s.save(),s.translate(U.x,U.y),s.rotate(D),s.scale(xe,Ie),s.arc(0,0,De,B,B+oe,!x),s.scale(1/xe,1/Ie),s.rotate(-D),s.translate(-U.x,-U.y),s.restore()}break;case"Z":case"z":s.closePath(),u=o,f=a}o=u,a=f}}},n.prototype.drawText=function(t,e,i,r,s,o,a){if(e.content&&!0===e.visible){var l=n.getContext(t);l.save(),this.setStyle(t,e),o&&(e.fontSize*=o),this.applyFlipAndRotate(l,e,t,e.x+e.width*e.pivotX,e.y+e.height*e.pivotY),this.setFontStyle(t,e);var u,d=0;u=e.childNodes;var f=e.wrapBounds;if(l.fillStyle=e.color,f){var p=this.labelAlign(e,f,u);for(d=0;de.width&&"Wrap"!==e.textOverflow&&"NoWrap"===e.textWrapping&&(g.text=qF(g.text,e)),"Clip"!==e.textOverflow&&"Ellipsis"!==e.textOverflow||"Wrap"!==e.textWrapping?l.fillText(g.text,v,y):ya.actualSize.height+a.bounds.y&&(g.text=g.text.slice(0,g.text.length-3),g.text=g.text.concat("...")),l.fillText(g.text,v,y)),"Underline"===e.textDecoration||"Overline"===e.textDecoration||"LineThrough"===e.textDecoration){var M=v,w=void 0,D=v+l.measureText(g.text).width,A=void 0;switch(e.textDecoration){case"Underline":w=y+2,A=y+2;break;case"Overline":w=p.y+g.dy*d,A=p.y+g.dy*d;break;case"LineThrough":w=(y+p.y+g.dy*d)/2+2,A=(y+p.y+g.dy*d)/2+2}l.beginPath(),l.moveTo(M,w),l.lineTo(D,A),l.strokeStyle=e.color,l.lineWidth=.08*e.fontSize,l.globalAlpha=e.opacity,l.stroke()}}}l.restore()}},n.prototype.applyFlipAndRotate=function(t,e,i,r,s){"Horizontal"===e.flip||"Vertical"===e.flip?(t.translate(e.x+e.width/2,e.y+e.height/2),t.rotate(-e.angle*Math.PI/180),t.translate(-e.x-e.width/2,-e.y-e.height/2)):this.rotateContext(i,e.angle,r,s),t.translate(e.x,e.y),"Horizontal"===e.flip?(t.scale(-1,1),t.translate(-1*e.width,0)):"Vertical"===e.flip?(t.scale(1,-1),t.translate(0,-1*e.height)):"Both"===e.flip&&(t.scale(-1,-1),t.translate(-1*e.width,-1*e.height)),t.translate(-e.x,-e.y)},n.prototype.loadImage=function(t,e,i,r,s){var o=new Image;o.src=e.source,this.image(t,o,e.x,e.y,e.width,e.height,e)},n.prototype.drawImage=function(t,e,i,r){var s=this;if(e.visible){var o=n.getContext(t);o.save();var a=e.x+e.width*e.pivotX,l=e.y+e.height*e.pivotY,h=new Image;h.src=e.source,this.setStyle(t,e),o.canvas.id.split("_"),this.applyFlipAndRotate(o,e,t,a,l),r?h.onload=function(){s.loadImage(o,e,t,a,l)}:this.loadImage(o,e,t,a,l),o.restore()}},n.prototype.image=function(t,e,i,r,s,o,a){t.beginPath();var l=e.width,h=e.height,c=s,d=o,u=0,f=0;if(a&&"None"!==a.alignment){var p=a.alignment.toLowerCase().substr(1,3),g=a.alignment.toLowerCase().substr(5,3);if("Slice"===a.scale){var v=function(){u=c,f=h*c/l},y=function(){u=l*d/h,f=d};c>d?(v(),d>f&&y()):c===d?l>h?y():v():(y(),c>u&&v());var S=this.getSliceOffset(p,u,c,l),b=this.getSliceOffset(g,f,d,h),M=l-S,w=h-b,C=u-S*(u/l),D=f-b*(f/h),A=Tt("canvas",{width:s.toString(),height:o.toString()});A.getContext("2d").drawImage(e,S,b,M,w,0,0,C,D),t.drawImage(A,i,r,s,o)}else if("Meet"===a.scale){var P=h/l,L=d/c;f=L>P?c*P:d,i+=this.getMeetOffset(p,u=L>P?c:d/P,c),r+=this.getMeetOffset(g,f,d),t.drawImage(e,0,0,l,h,i,r,u,f)}else t.drawImage(e,i,r,s,o)}else if("None"!==a.flip){var O=1,N=1;("Horizontal"===a.flip||"Both"===a.flip)&&(i=-i,s=-s,O=-1),("Vertical"===a.flip||"Both"===a.flip)&&(r=-r,o=-o,N=-1),t.scale(O,N),t.drawImage(e,i,r,s,o)}else t.drawImage(e,i,r,s,o);t.closePath()},n.prototype.getSliceOffset=function(t,e,i,r){switch(t){case"min":default:return 0;case"mid":return(e-i)/2*r/e;case"max":return(e-i)*r/e}},n.prototype.getMeetOffset=function(t,e,i){var r=Math.max(e,i),s=Math.min(e,i);switch(t){case"min":default:return 0;case"mid":return(r-s)/2;case"max":return r-s}},n.prototype.m=function(t){return Math.sqrt(Math.pow(t[0],2)+Math.pow(t[1],2))},n.prototype.r=function(t,e){return(t[0]*e[0]+t[1]*e[1])/(this.m(t)*this.m(e))},n.prototype.a=function(t,e){return(t[0]*e[1]t.width&&("Ellipsis"===t.textOverflow||"Clip"===t.textOverflow)&&"NoWrap"===t.textWrapping?0:.5*t.width:"right"===t.textAlign&&(c=1*t.width),s.x=t.x+c+(e?e.x:0),s.y=a+d-r.height/2,s},n}(),mb=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Vi=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Roe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return mb(t,n),Vi([I("")],t.prototype,"source",void 0),Vi([I("transparent")],t.prototype,"color",void 0),Vi([I("None")],t.prototype,"scale",void 0),Vi([I("None")],t.prototype,"align",void 0),t}(Ee),Hoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return mb(t,n),Vi([I("Page")],t.prototype,"mode",void 0),Vi([I("PageSettings")],t.prototype,"region",void 0),Vi([re({top:25,bottom:25,left:25,right:25},Jn)],t.prototype,"margin",void 0),Vi([I(!1)],t.prototype,"canZoomIn",void 0),Vi([I(void 0)],t.prototype,"customBounds",void 0),Vi([I(!1)],t.prototype,"canFit",void 0),t}(Ee),Boe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return mb(t,n),Vi([I(null)],t.prototype,"width",void 0),Vi([I(null)],t.prototype,"height",void 0),Vi([re({},Jn)],t.prototype,"margin",void 0),Vi([I("Landscape")],t.prototype,"orientation",void 0),Vi([I("Infinity")],t.prototype,"boundaryConstraints",void 0),Vi([re({},Roe)],t.prototype,"background",void 0),Vi([I(!1)],t.prototype,"multiplePage",void 0),Vi([I(!1)],t.prototype,"showPageBreaks",void 0),Vi([re({},Hoe)],t.prototype,"fitOptions",void 0),t}(Ee),Foe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return mb(t,n),Vi([I(0)],t.prototype,"horizontalOffset",void 0),Vi([I(0)],t.prototype,"verticalOffset",void 0),Vi([I(1)],t.prototype,"currentZoom",void 0),Vi([I(0)],t.prototype,"viewPortWidth",void 0),Vi([I(0)],t.prototype,"viewPortHeight",void 0),Vi([I(.2)],t.prototype,"minZoom",void 0),Vi([I(30)],t.prototype,"maxZoom",void 0),Vi([I("Diagram")],t.prototype,"scrollLimit",void 0),Vi([I()],t.prototype,"scrollableArea",void 0),Vi([I(!1)],t.prototype,"canAutoScroll",void 0),Vi([I(100)],t.prototype,"autoScrollFrequency",void 0),Vi([re({left:15,right:15,top:15,bottom:15},Jn)],t.prototype,"autoScrollBorder",void 0),Vi([re({left:0,right:0,top:0,bottom:0},Jn)],t.prototype,"padding",void 0),Vi([I(.2)],t.prototype,"zoomFactor",void 0),t}(Ee),_oe=function(){function n(){this.services={}}return n.prototype.register=function(t,e){this.services[""+t]=e},n.prototype.getService=function(t){return this.services[""+t]},n}(),$F=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),ya=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},ZF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return $F(t,n),ya([I("lightgray")],t.prototype,"lineColor",void 0),ya([I("")],t.prototype,"lineDashArray",void 0),ya([I([1.25,18.75,.25,19.75,.25,19.75,.25,19.75,.25,19.75])],t.prototype,"lineIntervals",void 0),ya([I([1,19,.5,19.5,.5,19.5,.5,19.5,.5,19.5])],t.prototype,"dotIntervals",void 0),ya([I([20])],t.prototype,"snapIntervals",void 0),t}(Ee),Uoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return $F(t,n),ya([re({},ZF)],t.prototype,"horizontalGridlines",void 0),ya([re({},ZF)],t.prototype,"verticalGridlines",void 0),ya([I(Kt.All)],t.prototype,"constraints",void 0),ya([I(5)],t.prototype,"snapAngle",void 0),ya([I("Lines")],t.prototype,"gridType",void 0),ya([I(5)],t.prototype,"snapObjectDistance",void 0),ya([I("#07EDE1")],t.prototype,"snapLineColor",void 0),t}(Ee),JF=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),el=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},KF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return JF(t,n),el([I(5)],t.prototype,"interval",void 0),el([I(100)],t.prototype,"segmentWidth",void 0),el([I("Horizontal")],t.prototype,"orientation",void 0),el([I("RightOrBottom")],t.prototype,"tickAlignment",void 0),el([I("red")],t.prototype,"markerColor",void 0),el([I(25)],t.prototype,"thickness",void 0),el([I(null)],t.prototype,"arrangeTick",void 0),t}(Ee),joe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return JF(t,n),el([I(!1)],t.prototype,"showRulers",void 0),el([I(!0)],t.prototype,"dynamicGrid",void 0),el([re({orientation:"Horizontal"},KF)],t.prototype,"horizontalRuler",void 0),el([re({orientation:"Vertical"},KF)],t.prototype,"verticalRuler",void 0),t}(Ee),Voe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),e_=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Woe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Voe(t,n),e_([I("")],t.prototype,"property",void 0),e_([I("")],t.prototype,"field",void 0),t}(Ee),ET=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),ln=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},t_=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return ET(t,n),ln([I("")],t.prototype,"read",void 0),ln([I("")],t.prototype,"create",void 0),ln([I("")],t.prototype,"update",void 0),ln([I("")],t.prototype,"destroy",void 0),ln([I()],t.prototype,"customFields",void 0),t}(Ee),Yoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return ET(t,n),ln([I("")],t.prototype,"id",void 0),ln([I("")],t.prototype,"sourceID",void 0),ln([I("")],t.prototype,"targetID",void 0),ln([I(null)],t.prototype,"sourcePointX",void 0),ln([I(null)],t.prototype,"sourcePointY",void 0),ln([I(null)],t.prototype,"targetPointX",void 0),ln([I(null)],t.prototype,"targetPointY",void 0),ln([I(null)],t.prototype,"dataManager",void 0),ln([re({},t_)],t.prototype,"crudAction",void 0),t}(Ee),Qoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return ET(t,n),ln([I("")],t.prototype,"id",void 0),ln([I(null)],t.prototype,"dataManager",void 0),ln([I(null)],t.prototype,"dataSource",void 0),ln([I("")],t.prototype,"root",void 0),ln([I("")],t.prototype,"parentId",void 0),ln([I()],t.prototype,"doBinding",void 0),ln([Bt([],Woe)],t.prototype,"dataMapSettings",void 0),ln([re({},t_)],t.prototype,"crudAction",void 0),ln([re({},Yoe)],t.prototype,"connectionDataSource",void 0),t}(Ee),i_=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Cr=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Goe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return i_(t,n),Cr([I("LeftInFlow")],t.prototype,"yesBranchDirection",void 0),Cr([I("RightInFlow")],t.prototype,"noBranchDirection",void 0),Cr([I(["Yes","True"])],t.prototype,"yesBranchValues",void 0),Cr([I(["No","False"])],t.prototype,"noBranchValues",void 0),t}(Ee),Xoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return i_(t,n),Cr([I("")],t.prototype,"fixedNode",void 0),Cr([I(30)],t.prototype,"horizontalSpacing",void 0),Cr([I("SamePoint")],t.prototype,"connectionPointOrigin",void 0),Cr([I("Nonlinear")],t.prototype,"arrangement",void 0),Cr([I(30)],t.prototype,"verticalSpacing",void 0),Cr([I(30)],t.prototype,"maxIteration",void 0),Cr([I(40)],t.prototype,"springFactor",void 0),Cr([I(50)],t.prototype,"springLength",void 0),Cr([re({left:50,top:50,right:0,bottom:0},Jn)],t.prototype,"margin",void 0),Cr([I("Auto")],t.prototype,"horizontalAlignment",void 0),Cr([I("Auto")],t.prototype,"verticalAlignment",void 0),Cr([I("TopToBottom")],t.prototype,"orientation",void 0),Cr([I("Auto")],t.prototype,"connectionDirection",void 0),Cr([I("Default")],t.prototype,"connectorSegments",void 0),Cr([I("None")],t.prototype,"type",void 0),Cr([I()],t.prototype,"getLayoutInfo",void 0),Cr([I()],t.prototype,"layoutInfo",void 0),Cr([I()],t.prototype,"getBranch",void 0),Cr([I()],t.prototype,"bounds",void 0),Cr([I(!0)],t.prototype,"enableAnimation",void 0),Cr([I(!1)],t.prototype,"enableRouting",void 0),Cr([I("")],t.prototype,"root",void 0),Cr([re({},Goe)],t.prototype,"flowchartLayoutSettings",void 0),t}(Ee),qoe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),r_=function(n){function t(e,i){var r=n.call(this,e,!0)||this;return r.oldValue=null,r.endPoint=i,r}return qoe(t,n),t.prototype.mouseDown=function(e){var i,r=!0;if(e.source&&e.source.connectors&&(i=e.source.connectors[0]),e.info&&e.actualObject&&(r=e.info.ctrlKey&&"Orthogonal"!==e.actualObject.type),i&&r){this.inAction=!0,this.undoElement=$(e.source),n.prototype.mouseDown.call(this,e);for(var s=0;s0)1!==s&&this.removePrevSegment(i,s);else if(a){var l=R.distancePoints(a.points[0],a.points[1]);Math.abs(a.length||0===a.length?a.length:l)<=5&&this.removeNextSegment(i,s)}this.commandHandler.updateEndPoint(i,r),i.selectedSegmentIndex=0}if(this.undoElement){var c=$(e.source);this.commandHandler.addHistoryEntry({type:"SegmentChanged",redoObject:c,undoObject:this.undoElement,category:"Internal"})}if(i.isBezierEditing&&(i.isBezierEditing=!1),this.prevPosition!==this.startPosition){var u={source:i,state:"Completed",oldValue:this.oldValue,newValue:$(this.selectedSegment),cancel:!1,segment:this.selectedSegment};this.commandHandler.triggerEvent(Ce.segmentChange,u)}n.prototype.mouseUp.call(this,e)},t.prototype.removePrevSegment=function(e,i){var r=e.segments[i-2],s=e.segments[i+1];if(s&&!((s.length||0===s.length?s.length:R.distancePoints(s.points[0],s.points[1]))<=5)){var a=e.segments.slice(i-1,i+1),l={element:e,removeSegments:a,type:"Removal",cancel:!1};if(this.commandHandler.triggerEvent(Ce.segmentCollectionChange,l),!l.cancel){var h=e.segments[i+1];e.segments.splice(i-1,2);var c=this.selectedSegment;"Left"===c.direction||"Right"===c.direction?(r.points[r.points.length-1].x=h.points[0].x,h.points[0].y=r.points[r.points.length-1].y):(r.points[r.points.length-1].y=h.points[0].y,h.points[0].x=r.points[r.points.length-1].x),(c.length||0===c.length)&&this.findSegmentDirection(r),this.findSegmentDirection(h)}}},t.prototype.findSegmentDirection=function(e){e.direction&&(e.length||0===e.length)&&(e.length=R.distancePoints(e.points[0],e.points[e.points.length-1]),e.direction=R.direction(e.points[0],e.points[e.points.length-1]))},t.prototype.removeNextSegment=function(e,i){var l,h,r=this.selectedSegment,s=e.segments[i-1],o=e.segments[i+2],a=e.segments[i+1];if(a.length||0===a.length?(l=e.segments.slice(i,2),h={element:e,removeSegments:l,type:"Removal",cancel:!1},this.commandHandler.triggerEvent(Ce.segmentCollectionChange,h={element:e,removeSegments:l,type:"Removal",cancel:!1}),h.cancel||(e.segments.splice(i,2),"Top"===r.direction||"Bottom"===r.direction?(o.points[0].y=r.points[0].y,s.points[s.points.length-1].x=o.points[0].x):(o.points[0].x=r.points[0].x,s.points[s.points.length-1].y=o.points[0].y))):(l=e.segments.slice(i+1,1),this.commandHandler.triggerEvent(Ce.segmentCollectionChange,h={element:e,removeSegments:l,type:"Removal",cancel:!1}),h.cancel||(e.segments.splice(i+1,1),"Top"===r.direction||"Bottom"===r.direction?s.points[s.points.length-1].x=a.points[a.points.length-1].x:s.points[s.points.length-1].y=a.points[a.points.length-1].y,this.findSegmentDirection(s),r.length=r.direction=null)),s&&o&&!h.cancel&&(s.length=R.distancePoints(s.points[0],o.points[0]),s.direction=R.direction(s.points[0],o.points[0]),o.length||0===o.length)){o.length=R.distancePoints(s.points[s.points.length-1],o.points[o.points.length-1]);var c=s.points,d=o.points;o.direction=R.direction(c[c.length-1],d[d.length-1])}},t.prototype.addOrRemoveSegment=function(e,i,r){for(var s,o,a=[],l={segments:e.segments},h=0;h0?"Bottom":"Top":r>0?"Right":"Left",length:i.points[0].x===i.points[1].x?s:r},!0)),l.push(new wi(e,"segments",{type:"Orthogonal",direction:c,length:h/2},!0));var f={element:e,addSegments:l,type:"Addition",cancel:!1};return this.commandHandler.triggerEvent(Ce.segmentCollectionChange,f),f.cancel||(e.segments=l.concat(e.segments),a=o+2),a},t.prototype.insertFirstSegment=function(e,i,r,s,o){var a,l,d,u,h=[];if(e.sourcePortID&&i.length&&e.segments[0].points.length>2)for(var f=void 0,p=0;p0?"Bottom":"Top":r>0?"Right":"Left"),f=u,h.push(u)}else h.push(new wi(e,"segments",{type:"Orthogonal",direction:i.direction,length:i.length/3},!0)),"Bottom"===i.direction||"Top"===i.direction?(l=Math.abs(r),a=r>0?"Right":"Left"):(l=Math.abs(s),a=s>0?"Bottom":"Top"),u=new wi(e,"segments",{type:"Orthogonal",direction:a,length:l},!0),h.push(u);var y={element:e,addSegments:h,type:"Addition",cancel:!1};if(this.commandHandler.triggerEvent(Ce.segmentCollectionChange,y),!y.cancel){if(e.sourcePortID&&i.length&&e.segments[0].points.length>2)e.segments.splice(0,1),d=1;else{var S=e.segments[1];S&&S.length&&(S.length=a!==S.direction?S.length+l:S.length-l),d=2,i.length=2*i.length/3}e.segments=h.concat(e.segments)}return d},t.prototype.updateAdjacentSegments=function(e,i,r,s){var o=e.segments[parseInt(i.toString(),10)],a=o.points[o.points.length-1],h=!0;"Orthogonal"===o.type&&(o.points[0]=o.points[0],o.points[o.points.length-1]=a,e.segments[i-1]&&(h=this.updatePreviousSegment(r,s,e,i)),e.segments.length-1>i&&h&&this.updateNextSegment(e,o,e.segments[i+1],r,s))},t.prototype.addTerminalSegment=function(e,i,r,s,o){var l,h,c,d,a=e.segments.indexOf(i),u=[],f=e.segments.pop(),p=e.segments[e.segments.length-1];l=p&&"Orthogonal"===p.type?p:null;for(var g=0;g0&&"Left"===o.direction?c.middleLeft:c.middleRight,o.length>c.width/2?Math.abs(a.length)0&&"Top"===o.direction?c.topCenter:c.bottomCenter,o.length>c.height/2?Math.abs(a.length)1)for(var a=0,l=this.diagram.views;a0)for(var e=t===Ce.onUserHandleMouseLeave?this.previousAction:this.action,i={element:void 0},r=0;r0)for(var r={element:void 0},s=void 0,o=void 0,a=0;a-1&&(o=s,this.previousTarget=i,this.targetItem=e),o===e.fixedUserHandles[parseInt(a.toString(),10)].id&&(r.element=e.fixedUserHandles[parseInt(a.toString(),10)],this.userHandle(t,a,r,e))},n.prototype.mouseDown=function(t){var e=this;if("touchstart"===t.type&&(this.timeOutTapHold=setTimeout(function(){("Select"===e.action||"Drag"===e.action)&&e.mouseMove(t,void 0)},500)),!0!==this.inAction||!(this.tool instanceof $I||this.tool instanceof pa)){this.focus=!0;var i=t.touches,r=!!document.getElementsByClassName("e-dragclone")[0];if(this.isMouseOnScrollBar(t)&&!r)return this.isScrolling=!0,void t.preventDefault();if(this.checkFixedUserHandleEvent(Ce.onFixedUserHandleMouseDown,this.targetItem,this.previousTarget),this.checkUserHandleEvent(Ce.onUserHandleMouseDown),!this.checkEditBoxAsTarget(t)&&Yv(this.diagram)||Oc(this.diagram)&&!jI(this.diagram))if(("Select"===this.action||"Drag"===this.action)&&this.diagram.updatePortVisibility(this.hoverElement,ci.Hover,!0),!(this.tool instanceof Rl||this.tool instanceof Hl)||2!==t.button&&2!==t.buttons)if(!0===this.inAction&&!0===this.isMouseDown&&(this.tool instanceof Rl||this.tool instanceof Hl))this.isMouseDown=!0,this.eventArgs={},this.getMouseEventArgs(this.currentPosition,this.eventArgs),this.eventArgs.position=this.currentPosition,this.tool.mouseDown(this.eventArgs);else{this.isMouseDown=!0,this.currentPosition=this.prevPosition=this.getMousePosition(t),this.eventArgs={},this.diagram.textEditing&&!this.isMouseOnScrollBar(t)&&(this.diagram.endEdit(),this.diagram.textEditing=!1,"Canvas"===this.diagram.mode&&1!==this.diagram.scroller.currentZoom&&this.diagram.refreshDiagramLayer());var o=this.getTargetElement();this.action=this.diagram.findActionToBeDone(o.obj,o.sourceElement,this.currentPosition,o.target);var a=this.isMetaKey(t);a&&t.shiftKey&&this.diagram.connectorEditingToolModule?this.action="SegmentEnd":(a||t.shiftKey)&&(Vv(this.diagram)||Wv(this.diagram))&&(this.action="Select"),this.tool=this.diagram.getTool(this.action),this.tool||(this.action="Select",this.tool=this.diagram.getTool(this.action)),this.getMouseEventArgs(this.currentPosition,this.eventArgs),(a||t.shiftKey)&&(this.eventArgs.info=a&&t.shiftKey?{ctrlKey:a,shiftKey:t.shiftKey}:{ctrlKey:!0}),this.eventArgs.position=this.currentPosition;var h=this.diagram.selectedItems.nodes;if(this.tool.mouseDown(this.eventArgs),this.diagram.selectedItems.canToggleSelection&&h&&this.diagram.selectedItems.nodes&&this.tool instanceof fa)for(var c=0;c=2&&(this.touchStartList=VF(this.touchStartList,0,i)),i||t.preventDefault())}else this.inAction=!1,this.tool.mouseUp(this.eventArgs);!this.isForeignObject(t.target)&&!this.isForeignObject(t.target,!0)&&!i&&t.preventDefault()}},n.prototype.mouseMoveExtend=function(t,e){(this.tool instanceof Rl||this.tool instanceof Hl)&&this.tool.mouseMove(this.eventArgs),this.diagram.scrollSettings.canAutoScroll?this.checkAutoScroll(t):this.blocked||this.tool.mouseMove(this.eventArgs),this.eventArgs.target&&(this.hoverElement=this.eventArgs.target);var i=!((this.eventArgs.target instanceof te||this.eventArgs.target instanceof de)&&(e instanceof te||e instanceof de));this.tool instanceof zd&&this.diagram.updatePortVisibility(this.hoverElement instanceof te||this.hoverElement instanceof de?this.hoverElement:this.hoverNode,ci.Connect|ci.Hover,i),this.hoverElement instanceof te&&this.hoverNode instanceof te&&this.hoverNode&&this.hoverNode.id!==this.hoverElement.id&&this.diagram.updatePortVisibility(this.hoverNode,ci.Connect|ci.Hover,!0),this.hoverElement instanceof de&&this.hoverElement.ports.length>0&&this.diagram.updatePortVisibility(this.hoverElement,ci.Connect|ci.Hover,!0),this.previousElement instanceof te&&this.hoverElement&&this.previousElement.id!==this.hoverElement.id&&this.diagram.updatePortVisibility(this.previousElement,ci.Connect|ci.Hover,!0),this.previousElement=this.hoverElement,""!==this.diagram.tooltip.content&&(this.hoverElement=null),this.hoverNode=i?null:e},n.prototype.checkAction=function(t){if("LabelSelect"===this.action&&this.eventArgs.sourceWrapper&&(this.eventArgs.sourceWrapper instanceof ai||this.eventArgs.sourceWrapper instanceof es)){var e=this.commandHandler.findTarget(this.eventArgs.sourceWrapper,this.eventArgs.source);!_r(this.diagram,e,!1,this.eventArgs.sourceWrapper)&&ro(e)&&(this.action="LabelDrag",this.tool=this.getTool(this.action),this.tool.mouseDown(this.initialEventArgs))}else ro(t)&&Ad(t)&&this.initialEventArgs&&this.initialEventArgs.source&&"Select"===this.action&&(!_r(this.diagram,this.eventArgs.source,!1)&&this.eventArgs.source instanceof ei&&this.getMouseEventArgs(this.currentPosition,this.eventArgs),(!(t instanceof de)||t instanceof de&&!(wr(this.currentPosition,t.sourcePoint,t.hitPadding)||wr(this.currentPosition,t.targetPoint,t.hitPadding)))&&(this.action="Drag"),this.tool=this.getTool(this.action),this.tool.mouseDown(this.initialEventArgs))},n.prototype.isSwimlaneElements=function(t){return!(t&&(t.isLane||t.isPhase||t.isHeader))},n.prototype.canShowTouchTooltip=function(t){return!!("touchstart"===t.type&&this.diagram.tool&ri.SingleSelect&&this.diagram.tool&ri.ZoomPan)&&(this.isMouseDown=!1,!0)},n.prototype.mouseMove=function(t,e){if(this.focus=!0,"touchmove"===t.type&&(this.touchArgs={target:t.target,type:"touchmove"}),this.isScrolling)t.preventDefault();else if(Yv(this.diagram)||Oc(this.diagram)&&!jI(this.diagram)){this.currentPosition=this.getMousePosition(t);var i=this.diagram.findObjectsUnderMouse(this.currentPosition),r=this.diagram.findObjectUnderMouse(i,this.action,this.inAction);!function nse(n,t){n.rulerSettings.showRulers&&(n.hRuler.drawRulerMarker(n.hRuler.element,t,n.scroller.horizontalOffset),n.vRuler.drawRulerMarker(n.vRuler.element,t,n.scroller.verticalOffset))}(this.diagram,this.currentPosition);var s=!1,o=void 0;if("touchmove"===t.type&&(e=t.touches)&&e.length>1&&(this.touchMoveList=VF(this.touchMoveList,0,e),"PinchZoom"!==this.action&&(s=!0)),!1===R.equals(this.currentPosition,this.prevPosition)||this.inAction||this.canShowTouchTooltip(t)){if(!1===this.isMouseDown||s){this.eventArgs={};var a=null,l=void 0;if(null!==r){if((a=this.diagram.findElementUnderMouse(r,this.currentPosition,this.diagram))&&(l=this.commandHandler.findTarget(a,r)),(l instanceof Kn||l instanceof Or)&&(l.tooltip&&""!==l.tooltip.content||(l=r)),l!==this.hoverElement){var h=this.getContent();this.hoverElement&&"Auto"===this.hoverElement.tooltip.openOn&&""!==h&&this.elementLeave(),this.diagram.updatePortVisibility(this.hoverElement,ci.Hover,!0),r instanceof te&&(this.hoverNode=r);var c=!0;!this.isSwimlaneElements(r)&&this.hoverElement&&this.isSwimlaneElements(this.hoverElement)&&(c=!1),this.hoverElement=c?r:this.hoverElement;var d,u=void 0;(d=this.diagram.findElementUnderMouse(r,this.currentPosition,this.diagram))instanceof Ze&&((u=this.commandHandler.findTarget(d,r))instanceof Es||u instanceof Lc)&&this.hoverElement.constraints&oi.ToolTip&&(this.hoverElement=u);var f=void 0;d instanceof ai&&((f=this.commandHandler.findTarget(d,r))instanceof Kn||f instanceof Or)&&f.constraints&Nr.Tooltip&&(this.hoverElement=f),c?this.elementEnter(this.currentPosition,!1):this.hoverElement=r}else this.hoverElement&&this.hoverElement===l&&this.hoverElement.tooltip.content&&void 0!==this.diagram.tooltipObject&&"Mouse"===this.hoverElement.tooltip.relativeMode&&this.setTooltipOffset(this.currentPosition);a&&(o=this.commandHandler.findTarget(a,r))}this.action=this.diagram.findActionToBeDone(r,a,this.currentPosition,o),this.checkFixedUserHandleEvent(Ce.onFixedUserHandleMouseEnter,r,a),this.checkUserHandleEvent(Ce.onUserHandleMouseEnter),this.checkPreviousAction(),this.getMouseEventArgs(this.currentPosition,this.eventArgs),this.tool=this.getTool(this.action),this.mouseEvents(),this.tool instanceof pa||this.tool instanceof Hl||this.tool instanceof Rl?this.tool.mouseMove(this.eventArgs):e&&this.tool instanceof im&&this.tool.mouseDown(this.eventArgs),this.updateCursor(),this.renderUmlHighLighter(this.eventArgs);var p=!1;this.hoverElement&&!(this.tool instanceof im)&&r instanceof te&&this.isSwimlaneElements(r)&&(0===this.diagram.selectedItems.nodes.length||!_r(this.diagram,this.hoverElement))||this.hoverElement instanceof de||(p=!0),this.hoverElement&&!(this.tool instanceof im)&&r instanceof de&&(0===this.diagram.selectedItems.connectors.length||!_r(this.diagram,this.hoverElement))||this.hoverElement instanceof te||(p=!0),this.diagram.updatePortVisibility(this.hoverElement,ci.Hover,p);var g=this.getContent();null===r&&this.hoverElement&&"Auto"===this.hoverElement.tooltip.openOn&&g&&(this.hoverElement=null,this.elementLeave()),s=!1}else{this.eventArgs.position=this.currentPosition,"Drag"===this.action&&!_r(this.diagram,this.eventArgs.source,!1)&&this.eventArgs.source instanceof ei&&this.getMouseEventArgs(this.currentPosition,this.eventArgs),this.mouseEvents(),(t.ctrlKey||t.shiftKey)&&(this.eventArgs.info=t.ctrlKey&&t.shiftKey?{ctrlKey:t.ctrlKey,shiftKey:t.shiftKey}:{ctrlKey:!0}),this.checkAction(r);var y=this.getConnectorPadding(this.eventArgs);this.getMouseEventArgs(this.currentPosition,this.eventArgs,this.eventArgs.source,y),this.updateCursor(),this.inAction=!0,this.initialEventArgs=null,("Drag"===this.action||"Rotate"===this.action)&&(this.diagram.diagramActions=this.diagram.diagramActions|ee.Interactions);var S=this.diagram.scroller.getPageBounds();this.mouseMoveExtend(t,r);var b=this.diagram.scroller.getPageBounds();if(r&&(S.width!==b.width||S.height!==b.height||S.x!==b.x||S.y!==b.y)&&this.diagram.views&&this.diagram.views.overview){var M=this.diagram.views.overview;M.updateView(M)}}this.prevPosition=this.currentPosition,this.isForeignObject(t.target,!0)||t.preventDefault()}}},n.prototype.getContent=function(){var i,t=this.hoverElement instanceof te&&this.hoverElement.constraints&ie.Tooltip||this.hoverElement instanceof de&&this.hoverElement.constraints&qe.Tooltip||(this.hoverElement instanceof Es||this.hoverElement instanceof Lc)&&this.hoverElement.constraints&oi.ToolTip||(this.hoverElement instanceof Kn||this.hoverElement instanceof Or)&&this.hoverElement.constraints&Nr.Tooltip,e=this.hoverElement;e instanceof te&&e.children&&e.children.length>0&&(i=this.findIntersectChild(e));var r=t?this.hoverElement.tooltip.content:this.diagram.tooltip.content;return i?i.tooltip.content:r},n.prototype.findIntersectChild=function(t){for(var e,i=new Ne(this.currentPosition.x,this.currentPosition.y,8,8),r=0;r1&&1===t.which&&!function one(n){return!!(n&ee.PreventClearSelection)}(this.diagram.diagramActions)&&(c=!1,this.commandHandler.clearSelection()),(!_r(this.diagram,h)||!c)&&(this.commandHandler.selectObjects([h],void 0,a),this.diagram.selectedItems.canToggleSelection)){var d=this.diagram.selectedItems.nodes;d?d[0].parentObj instanceof Fd&&(s=!0):this.diagram.selectedItems.connectors.length>0&&(s=!0)}}var u=!1,f=this.updateContainerProperties(),p=void 0;if(this.addUmlNode(),this.inAction=!1,this.isMouseDown=!1,this.diagram.selectedObject.helperObject&&(p=this.updateContainerBounds()),this.tool&&(this.tool.prevPosition||this.tool instanceof eF)){this.eventArgs.position=this.currentPosition;var g=this.getConnectorPadding(this.eventArgs);this.getMouseEventArgs(this.currentPosition,this.eventArgs,this.eventArgs.source,g);var v=this.isMetaKey(t);if((v||t.shiftKey)&&(this.eventArgs.info=v&&t.shiftKey?{ctrlKey:v,shiftKey:t.shiftKey}:{ctrlKey:!0}),this.diagram.diagramActions&ee.Interactions&&(this.diagram.diagramActions=this.diagram.diagramActions&~ee.Interactions),this.eventArgs.clickCount=t.detail,this.diagram.selectedObject.helperObject&&(this.tool instanceof fa||this.tool instanceof Rd)){if(this.diagram.selectedObject.actualObject&&""!==this.diagram.selectedObject.actualObject.parentId){var S=this.diagram.getObject(this.diagram.selectedObject.actualObject.parentId);S&&S.isLane&&(this.commandHandler.isContainer=!0)}(u=this.diagram.lineRoutingModule&&this.diagram.nameTable.helper&&this.eventArgs.target&&this.eventArgs.target.isLane&&(this.eventArgs.source instanceof ei&&this.eventArgs.source.nodes.length>0&&""===this.eventArgs.source.nodes[0].parentId||""===this.eventArgs.source.parentId))&&(this.diagram.diagramActions=this.diagram.diagramActions|ee.PreventLaneContainerUpdate),this.tool.mouseUp(this.eventArgs,f.isPreventHistory)}else{if(this.diagram.selectedItems.canToggleSelection){var b=void 0,M=void 0;if(this.diagram.selectedItems.nodes.length>0)for(var w=0;w1&&D[0].id===i[parseInt(w.toString(),10)].id||r.length>0)&&(M=!0);!this.isSwimlaneSelected&&!s&&!M&&this.tool instanceof fa&&"Select"===this.currentAction&&(!b||this.diagram.selectedItems.connectors.length>0)&&this.commandHandler.clearSelection(!0)}this.isSwimlaneSelected=!1,this.tool.mouseUp(this.eventArgs),this.diagram.checkMenu&&(-1!==window.navigator.userAgent.indexOf("Linux")||-1!==window.navigator.userAgent.indexOf("X11"))&&(!t.pageY&&t instanceof TouchEvent&&t.changedTouches?(window.getSelection().removeAllRanges(),this.diagram.contextMenuModule.contextMenu.open(t.changedTouches[0].pageY,t.changedTouches[0].pageX,this.diagram.element),t.preventDefault()):this.diagram.contextMenuModule.contextMenu.open(t.pageY,t.pageX,this.diagram.element),this.diagram.checkMenu=!1)}f.hasStack&&this.diagram.endGroupAction()}if(p&&this.diagram.endGroupAction(),this.updateContainerBounds(!0),2!==this.eventArgs.clickCount&&(this.commandHandler.updateSelectedNodeProperties(this.eventArgs.source),u)){this.diagram.diagramActions=this.diagram.diagramActions&~ee.PreventLaneContainerUpdate;var A=this.eventArgs.source instanceof ei?this.eventArgs.source.nodes:[this.eventArgs.source];if(A)for(w=0;w0&&!N&&this.diagram.renderSelector(!0),!this.inAction&&!this.diagram.currentSymbol&&this.eventArgs){var T=this.getTargetElement();this.diagram.tool!==ri.ZoomPan&&this.diagram.triggerEvent(Ce.click,{element:T.target instanceof Es?T.target:this.eventArgs.source||this.diagram,position:this.eventArgs.position,count:t.detail,actualObject:this.eventArgs.actualObject,button:0===t.button?"Left":1===t.button?"Middle":"Right"})}this.eventArgs={}}this.diagram.diagramActions=this.diagram.diagramActions&~ee.PreventLaneContainerUpdate,e&&this.updateAnnotation(this.diagram.selectedItems),this.previousElement=null,this.eventArgs={},this.diagram.commandHandler.removeStackHighlighter()},n.prototype.isSwimlaneChild=function(t){if(t.shape&&"SwimLane"!==t.shape.type){var e=this.diagram.nameTable[t.parentId];if(!e)return!1;var i=e.parentId?this.diagram.nameTable[e.parentId]:e;return i&&i.shape&&"SwimLane"===i.shape.type}return!1},n.prototype.updateAnnotation=function(t){var e=t.nodes;if(e.length>0)for(var i=0;i0&&(a+=1),h.isPhase){l="Horizontal"===r.orientation?this.currentPosition.x-e.wrapper.bounds.x:this.currentPosition.y-(e.wrapper.bounds.y+r.header.height);var g={id:Qe(),offset:l,header:{annotation:{content:void 0===h.phases[0].header?"Phase":h.phases[0].header.annotation.content,style:void 0===h.phases[0].header?{}:h.phases[0].header.annotation.style}},style:void 0===h.phases[0]?{}:h.phases[0].style};this.diagram.addPhases(e,[g])}else{var v={id:Qe(),style:h.lanes[0].style,header:{annotation:{content:h.lanes[0].header.annotation.content,style:h.lanes[0].header.annotation.style},style:h.lanes[0].header.style}};if("Horizontal"===h.orientation?v.height=h.lanes[0].height:v.width=h.lanes[0].width,"Horizontal"===r.orientation?(s=i.rowIndex?i.rowIndex:this.diagram.nameTable[i.parentId].rowIndex,i.wrapper.offsetYs)v.header.width=r.lanes[parseInt(s.toString(),10)].header.width,v.header.height=r.lanes[parseInt(s.toString(),10)].header.height;else{var S=void 0;S="Horizontal"===r.orientation?i.rowIndex<3?0:s-a-1:s-1,v.header.width=r.lanes[parseInt(S.toString(),10)].header.width,v.header.height=r.lanes[parseInt(S.toString(),10)].header.height}p&&("height"===p?(v.width=v.height,delete v.height):(v.height=v.width,delete v.width)),this.diagram.addLanes(e,[v],"Horizontal"===r.orientation?s-a:s)}this.commandHandler.select(e)}else if(h.isLane){var b={id:Qe(),width:t.width,height:t.height,addInfo:t.addInfo,shape:{type:"SwimLane",header:{annotation:{content:void 0===h.header?"Header":h.header.annotation.content,style:void 0===h.header?{}:h.header.annotation.style},height:50,style:h.header?h.header.style:h.lanes[0].header.style},phases:[{id:Qe(),header:{annotation:{content:void 0===h.phases||void 0===h.phases[0].header?"Phase":h.phases[0].header.annotation.content,style:void 0===h.phases||void 0===h.phases[0].header?{}:h.phases[0].header.annotation.style},style:void 0===h.phases||void 0===h.phases[0].header?{}:h.phases[0].header.style},style:void 0===h.phases?{}:h.phases[0].style}],lanes:[{id:Qe(),height:t.height,width:t.width,style:h.lanes[0].style,header:{annotation:{content:h.lanes[0].header.annotation.content,style:h.lanes[0].header.annotation.style},style:h.lanes[0].header.style}}],orientation:h.orientation}};"Vertical"===h.orientation&&(b.width+=20),b.offsetX=this.currentPosition.x+b.width/2,b.offsetY=this.currentPosition.y+b.height/2,b.style=t.style,this.diagram.add(b)}},n.prototype.mouseLeave=function(t){this.tool&&this.inAction&&this.tool.mouseLeave(this.eventArgs),this.diagram.selectedObject.helperObject&&(this.updateContainerProperties(),this.updateContainerBounds()&&this.diagram.endGroupAction()),this.eventArgs&&this.eventArgs.source&&(this.diagram.updatePortVisibility(this.eventArgs.source,ci.Hover,!0),this.hoverElement=null),this.eventArgs&&!this.eventArgs.source&&this.hoverElement&&(this.hoverElement=null),this.tool instanceof zd&&this.eventArgs&&this.eventArgs.target&&this.eventArgs.target instanceof te&&(this.diagram.updatePortVisibility(this.eventArgs.target,ci.Hover|ci.Connect,!0),this.hoverElement=null);var i=this.diagram.selectedItems;i&&i.wrapper&&(cm(this.diagram,i)||this.diagram.renderSelector(!0)),(this.diagram.diagramActions&ee.Interactions||this.diagram.diagramActions&ee.ToolAction)&&(this.diagram.diagramActions=this.diagram.diagramActions&~ee.ToolAction),this.isMouseDown=!1,this.focus=!1,this.touchStartList=null,this.touchMoveList=null,this.elementLeave(),this.commandHandler.removeSnap(),this.inAction=!1,this.eventArgs={},this.diagram.selectedObject&&this.diagram.selectedObject.helperObject&&(this.diagram.remove(this.diagram.selectedObject.helperObject),this.diagram.selectedObject={helperObject:void 0,actualObject:void 0}),this.tool=null,function rse(){var t,e,n=document.getElementsByClassName("e-d-ruler-marker");if(n&&n.length>0)for(e=n.length-1;e>=0;e--)(t=n[parseInt(e.toString(),10)])&&t.parentNode.removeChild(t)}(),"Rotate"===this.action&&this.diagram.diagramCanvas.classList.remove("e-diagram-rotate"),t.preventDefault()},n.prototype.mouseWheel=function(t){this.diagram.blazorActions|=on.interaction;var e={event:t,cancel:!1};if(this.diagram.triggerEvent(Ce.mouseWheel,e),!e.cancel){var i=t.wheelDelta>0||-40*t.detail>0,r=this.getMousePosition(t);if(this.diagram.tooltipObject.close(),this.isMetaKey(t)){var o=this.diagram.scrollSettings.zoomFactor;this.diagram.zoomTo(i?{type:"ZoomIn",zoomFactor:o,focusPoint:r}:{type:"ZoomOut",zoomFactor:o,focusPoint:r}),t.preventDefault()}else{var a=this.diagram.scroller.horizontalOffset,l=this.diagram.scroller.verticalOffset,h=i?10:-10;this.tool&&(this.tool instanceof Rl||this.tool instanceof Hl)&&(this.eventArgs={},this.getMouseEventArgs(r,this.eventArgs),this.eventArgs.position=r,this.tool.mouseWheel(this.eventArgs)),this.diagram.scrollActions|=da.Interaction;var c=!0;if(t.isTrusted){var d=!1;(Math.abs(t.deltaY)<100&&-0===Math.abs(t.deltaX)||Math.abs(t.deltaX)<100&&-0===Math.abs(t.deltaY))&&(d=!0);var u=!1;(0!==t.deltaX||0!==t.deltaY)&&(u=navigator.userAgent.includes("Macintosh")),u?Math.abs(t.deltaX)>Math.abs(t.deltaY)?(t.shiftKey||t.deltaX&&-0!==t.deltaX&&(d||!u))&&this.diagram.scroller.zoom(1,h,0,r,c,void 0,d):t.deltaY&&-0!==t.deltaY&&(d||!u)&&this.diagram.scroller.zoom(1,0,h,r,c,void 0,d):t.shiftKey||t.deltaX&&-0!==t.deltaX&&(d||!u)?this.diagram.scroller.zoom(1,h,0,r,c,void 0,d):t.deltaY&&-0!==t.deltaY&&(d||!u)&&this.diagram.scroller.zoom(1,0,h,r,c,void 0,d)}else t.shiftKey||t.deltaX&&-0!==t.deltaX?this.diagram.scroller.zoom(1,h,0,r,c):this.diagram.scroller.zoom(1,0,h,r,c);this.diagram.scrollActions&=~da.Interaction,(a!==this.diagram.scroller.horizontalOffset||l!==this.diagram.scroller.verticalOffset)&&t.preventDefault()}if(this.diagram.textEditing){if(this.diagram.isTriggerEvent=!0,this.diagram.activeLabel.parentId){var p=this.diagram.getObject(this.diagram.activeLabel.parentId);this.diagram.startTextEdit(p,this.diagram.activeLabel.id)}this.diagram.isTriggerEvent=!1}this.diagram.blazorActions=this.diagram.blazorActions&~on.interaction}},n.prototype.keyDown=function(t){if(t.fromMouseEvents&&(t.ctrlKey&&(this.keyArgs.keyModifiers=1),t.shiftKey&&(this.keyArgs.keyModifiers=4),t.shiftKey&&t.ctrlKey&&(this.keyArgs.keyModifiers=5)),!(this.diagram.diagramActions&ee.TextEdit)&&!this.checkEditBoxAsTarget(t)||"Escape"===t.key||27===t.keyCode){var i=void 0,r=t.keyCode?t.keyCode:t.which,s=t.key;("ArrowDown"===s||"ArrowUp"===s||"ArrowLeft"===s||"ArrowRight"===s)&&(this.isNudgeKey=!0);var o=this.isMetaKey(t);if(this.diagram.commandManager&&this.diagram.commands)for(var l=0,h=Object.keys(this.diagram.commands);l4&&(S({keyDownEventArgs:KeyboardEvent,parameter:i.parameter,type:"KEYDOWN"}),this.keyCount=0,this.keyArgs.newValue={offsetX:this.diagram.selectedItems.offsetX,offsetY:this.diagram.selectedItems.offsetY},this.diagram.triggerEvent(Ce.positionChange,this.keyArgs))),this.isKeyUp=!1):S({keyDownEventArgs:KeyboardEvent,parameter:i.parameter})}break}}}}this.keyArgs={element:this.diagram.selectedItems,key:t.key,keyCode:t.keyCode?t.keyCode:t.which},this.getKeyModifier(this.keyArgs,t),this.diagram.diagramActions&ee.TextEdit&&this.getlabel(this.keyArgs,t),this.diagram.triggerEvent(Ce.keyDown,this.keyArgs)},n.prototype.getlabel=function(t,e){var i=this.diagram.activeLabel;t.target=this.diagram.element.id+"_editBox";var r=this.diagram.nameTable[i.parentId];if(document.getElementById(this.diagram.element.id+"_editBox")){t.text=document.getElementById(this.diagram.element.id+"_editBox").value;for(var s=0;s=this.diagram.scroller.viewPortWidth-18?r="right":e.x+this.diagram.scroller.horizontalOffsetthis.diagram.scroller.viewPortHeight-18?r="bottom":e.y+this.diagram.scroller.verticalOffset0&&(s=this.findIntersectChild(this.hoverElement)),"Auto"===this.hoverElement.tooltip.openOn&&""!==r&&Dx(this.diagram,s||(i?this.hoverElement:void 0)),this.hoverElement.tooltip.content&&("Mouse"===this.hoverElement.tooltip.relativeMode?this.setTooltipOffset(t):(this.diagram.tooltipObject.offsetX=0,this.diagram.tooltipObject.offsetY=0));var o=this.diagram.findObjectsUnderMouse(this.currentPosition),a=this.diagram.findObjectUnderMouse(o,this.action,this.inAction);if(null!==a){var l=void 0;this.hoverElement.tooltip.isSticky&&(this.diagram.tooltipObject.isSticky=!0),a instanceof te&&a.children&&a.children.length>0&&(a=s||a),l=a.ports&&(this.hoverElement instanceof Es||this.hoverElement instanceof Lc)||a.annotations&&(this.hoverElement instanceof Kn||this.hoverElement instanceof Or)?document.getElementById(a.id+"_"+this.hoverElement.id):document.getElementById(a.id+(a.shape&&a.shape instanceof dm?"_content_native_element":"_groupElement")),"Auto"===this.hoverElement.tooltip.openOn&&""!==r&&(this.diagram.tooltipObject.close(),this.diagram.tooltipObject.openOn=this.hoverElement.tooltip.openOn,this.diagram.tooltipObject.dataBind()),function Kre(n,t){var e=0;return n instanceof de?n.constraints&qe.Tooltip?e=n.constraints&qe.Tooltip:n.constraints&qe.InheritTooltip&&(e=t.constraints&nt.Tooltip):n instanceof Es||n instanceof Lc?n.constraints&oi.ToolTip?e=n.constraints&oi.ToolTip:n.constraints&oi.InheritTooltip&&(e=t.constraints&nt.Tooltip):n instanceof Kn||n instanceof Or?n.constraints&Nr.Tooltip&&(e=n.constraints&Nr.Tooltip):n.constraints&ie.Tooltip?e=n.constraints&ie.Tooltip:n.constraints&ie.InheritTooltip&&(e=t.constraints&nt.Tooltip),e}(this.hoverElement,this.diagram)&&"Auto"===this.hoverElement.tooltip.openOn&&(this.diagram.tooltipObject.target=this.hoverElement.id,this.diagram.tooltipObject.open("Mouse"===this.hoverElement.tooltip.relativeMode?this.diagram.element:l))}}},n.prototype.elementLeave=function(){this.diagram.tooltipObject&&!this.diagram.tooltipObject.isSticky&&"Custom"!==this.diagram.tooltipObject.openOn&&this.diagram.tooltipObject.close()},n.prototype.setTooltipOffset=function(t){var e=function Mse(n,t,e,i){var o="Mouse"===(!(e instanceof te?e.constraints&ie.InheritTooltip:e instanceof de?e.constraints&qe.InheritTooltip:e.constraints&oi.InheritTooltip)&&(e instanceof te?e.constraints&ie.Tooltip:e instanceof de?e.constraints&qe.Tooltip:e.constraints&oi.ToolTip)?e.tooltip.relativeMode:n.tooltip.relativeMode);"Mouse"===i?o=!0:"Object"===i&&(o=!1);var a=function wse(n,t,e,i){var o,r={},s=document.getElementById(e.element.id);if(n instanceof te||n instanceof de)o=n.wrapper.bounds;else{var a=e.findObjectsUnderMouse(t),l=e.findObjectUnderMouse(a,"Select",!1);o=e.findElementUnderMouse(l,t,e).bounds}var c=s.getBoundingClientRect();switch(e.tooltipObject.position){case"BottomCenter":r=Hc(t,o.bottomCenter,e,i,c.width/2,c.height);break;case"BottomLeft":case"LeftBottom":r=Hc(t,o.bottomLeft,e,i,0,c.height);break;case"BottomRight":case"RightBottom":r=Hc(t,o.bottomRight,e,i,c.width,c.height);break;case"LeftCenter":r=Hc(t,o.middleLeft,e,i,0,c.height/2);break;case"LeftTop":case"TopLeft":r=Hc(t,o.topLeft,e,i,0,0);break;case"RightCenter":r=Hc(t,o.middleRight,e,i,c.width,c.height/2);break;case"RightTop":case"TopRight":r=Hc(t,o.topRight,e,i,c.width,0);break;case"TopCenter":r=Hc(t,o.topCenter,e,i,c.width/2,0)}return r}(e,t,n,o),l=Za(n);return{x:a.x+l.width,y:a.y+l.height}}(this.diagram,t,this.hoverElement);this.diagram.tooltipObject.offsetX=e.x,this.diagram.tooltipObject.offsetY=e.y},n.prototype.altKeyPressed=function(t){return!!(t&ft.Alt)},n.prototype.ctrlKeyPressed=function(t){return!!(t&ft.Control)},n.prototype.shiftKeyPressed=function(t){return!!(t&ft.Shift)},n.prototype.scrolled=function(t){this.diagram.updateScrollOffset()},n.prototype.isMobileOrIPadDevice=function(){var t=navigator.userAgent||navigator.vendor||window.opera;return/iPhone|iPad|iPod/.test(t)&&!window.MSStream?"iOS":/android/i.test(t)?"Android":/Mobile|Tablet/.test(t)?"Mobile":"Desktop"},n.prototype.doubleClick=function(t){if(Yv(this.diagram)){var e=this.isMobileOrIPadDevice(),i=this.diagram.tool;"Desktop"!==e&&this.tool&&(this.tool instanceof Rl||this.tool instanceof Hl)&&(this.diagram.tool=0);var r=void 0,s=this.diagram.findObjectsUnderMouse(this.currentPosition),o=this.diagram.findObjectUnderMouse(s,this.action,this.inAction);if(null!==o&&Yv(this.diagram))if(r=this.diagram.findElementUnderMouse(o,this.currentPosition,this.diagram),this.tool&&(this.tool instanceof Rl||this.tool instanceof Hl))this.diagram.tool=i,this.tool.mouseUp(this.eventArgs),this.isMouseDown=!1,this.eventArgs={},this.tool=null,t.preventDefault();else{var l=this.diagram.commandHandler.getObjectLayer(o.id);!l||l.lock||!l.visible||this.diagram.diagramActions&ee.TextEdit||this.diagram.startTextEdit(o,r instanceof ai?r.id.split(o.id+"_")[1]:void 0)}this.diagram.triggerEvent(Ce.doubleClick,{source:o||this.diagram,position:this.currentPosition,count:t.detail})}},n.prototype.itemClick=function(t,e){var i=t;return Dn(this.diagram,i,!0)?i:null},n.prototype.inputChange=function(t){var i,s,o,a,l,h,c,d,u,f=document.getElementById(this.diagram.element.id+"_editBox"),p=document.getElementById(this.diagram.element.id+"_editTextBoxDiv"),g=f.value,v=g.split("\n");(!(a=this.diagram.selectedItems.nodes[0]?this.diagram.selectedItems.nodes[0]:this.diagram.selectedItems.connectors[0])&&this.tool instanceof ZI||a&&"SwimLane"===a.shape.type)&&(a=this.diagram.nameTable[this.diagram.activeLabel.parentId]),a&&("Text"!==a.shape.type&&a.annotations.length>0||"Text"===a.shape.type)&&(c=HF((o=this.diagram.getWrapper(a.wrapper,this.diagram.activeLabel.id)).style,g,void 0,void 0,i=(i=a.wrapper.bounds.width90?i:90),s=Number(f.style.fontSize.split("px")[0]),v.length>1&&""===v[v.length-1]&&(c.height=c.height+s),d=this.diagram.scroller.transform,u=P3(this.diagram)?d.scale:1,l=(12>c.height?12:c.height)*u,p.style.left=(o.bounds.center.x+d.tx)*d.scale-(h=(90>(h=c.width)?90:h)*u)/2-2.5+"px",p.style.top=(o.bounds.center.y+d.ty)*d.scale-l/2-3+"px",p.style.width=h+"px",p.style.height=l+"px",f.style.minHeight="12px",f.style.minWidth="90px",f.style.width=h+"px",f.style.height=l+"px")},n.prototype.isAddTextNode=function(t,e){return!(!(this.tool instanceof ZI||e)||(this.tool=null,t&&!UI(this.diagram)&&(this.diagram.drawingObject=void 0,this.diagram.currentDrawingObject=void 0),MF(this.diagram.nodes,t.id)||MF(this.diagram.connectors,t.id)))},n.prototype.checkEditBoxAsTarget=function(t){return!(!t.target||t.target.id!==this.diagram.element.id+"_editBox")},n.prototype.getMouseEventArgs=function(t,e,i,r){var s,o,a;if(e.position=t,i?(o=this.diagram.findObjectsUnderMouse(this.currentPosition,i),s=this.diagram.findTargetObjectUnderMouse(o,this.action,this.inAction,e.position,i)):"Drag"===this.action||"ConnectorSourceEnd"===this.action||"SegmentEnd"===this.action||"OrthoThumb"===this.action||"BezierSourceThumb"===this.action||"BezierTargetThumb"===this.action||"ConnectorTargetEnd"===this.action||-1!==this.action.indexOf("Rotate")||-1!==this.action.indexOf("Resize")?(s=this.diagram.selectedItems,!this.diagram.currentSymbol&&"Drag"===this.action&&s&&this.diagram.selectedItems.nodes.length>0&&"SwimLane"===this.diagram.selectedItems.nodes[0].shape.type&&(o=this.diagram.findObjectsUnderMouse(this.currentPosition),s=this.diagram.findObjectUnderMouse(o,this.action,this.inAction))):(o=this.diagram.findObjectsUnderMouse(this.currentPosition),s=this.diagram.findObjectUnderMouse(o,this.action,this.inAction)),s&&s.isHeader&&(this.eventArgs.actualObject=s=this.diagram.nameTable[s.parentId]),s){var l=void 0,h=void 0,c=void 0;if(((a=this.diagram.findElementUnderMouse(s,this.currentPosition,this.diagram,r))&&s.ports&&s.ports.length&&!hb(s,a)||!a||!s)&&o&&o.length&&i instanceof ei)for(l=i.connectors[0],c=o.length-1;c>=0;c--)if(((h=o[parseInt(c.toString(),10)])instanceof te||h instanceof de)&&l&&l.connectionPadding){if(a=this.diagram.findElementUnderMouse(s=h,this.currentPosition,this.diagram,r),l.constraints&qe.ConnectToNearByPort&&s&&s.ports&&s.ports.length&&hb(s,a))break;if((h instanceof te||h instanceof de)&&l&&l.connectionPadding&&h.wrapper.outerBounds.containsPoint(this.currentPosition)&&l.constraints&qe.ConnectToNearByNode&&!(l.constraints&qe.ConnectToNearByPort)){a=this.diagram.findElementUnderMouse(s=h,this.currentPosition,this.diagram,0);break}}}return i?(e.target=s,e.targetWrapper=a):(e.source=s,e.sourceWrapper=a),e.actualObject=this.eventArgs.actualObject,e.source instanceof ei&&void 0===e.actualObject&&(e.source.nodes.length>0||e.source.connectors.length>0)&&(e.actualObject=e.source.nodes.length>0?this.diagram.nameTable[e.source.nodes[0].id]:this.diagram.nameTable[e.source.connectors[0].id]),e.startTouches=this.touchStartList,e.moveTouches=this.touchMoveList,e},n.prototype.resetTool=function(){this.action="Select",this.hoverElement=null,this.hoverNode=null,this.tool=this.diagram.getTool(this.action),this.updateCursor()},n.prototype.updateTool=function(){this.action=this.currentPosition&&"Pan"!==this.action?"Pan":"Select"},n.prototype.getTool=function(t){switch(t){case"Select":return new tm(this.commandHandler,!0);case"Drag":return new fa(this.commandHandler);case"Rotate":return new qx(this.commandHandler);case"LayoutAnimation":return new Une(this.commandHandler);case"FixedUserHandle":return new _ne(this.commandHandler,!0);case"Hyperlink":return new eF(this.commandHandler);case"ResizeSouthEast":case"ResizeSouthWest":case"ResizeNorthEast":case"ResizeNorthWest":case"ResizeSouth":case"ResizeNorth":case"ResizeWest":case"ResizeEast":return new Rd(this.commandHandler,t);case"ConnectorSourceEnd":case"ConnectorTargetEnd":case"BezierSourceThumb":case"BezierTargetThumb":return new zd(this.commandHandler,t);case"SegmentEnd":case"OrthoThumb":return new r_(this.commandHandler,t);case"Draw":var e="shape",i=function gse(n){var t;return n&&(n.type?t="Connector":n.shape&&!n.type&&(t="Node")),t}(this.diagram.drawingObject);if("Node"===i&&"Text"===this.diagram.drawingObject.shape.type)return new ZI(this.commandHandler);if("Connector"===i&&"Freehand"===this.diagram.drawingObject.type)return new Yne(this.commandHandler);if("Node"===i&&"Polygon"===this.diagram.drawingObject.shape[""+e]&&!this.diagram.drawingObject.shape.points)return new Rl(this.commandHandler);if("Node"===i||"Node"===i&&"Polygon"===this.diagram.drawingObject.shape[""+e]&&this.diagram.drawingObject.shape.points)return new $I(this.commandHandler,this.diagram.drawingObject);if("Connector"===i&&"Polyline"===this.diagram.drawingObject.type)return new Hl(this.commandHandler);if("Connector"===i)return new pa(this.commandHandler,"ConnectorSourceEnd",this.diagram.drawingObject);break;case"Pan":return new im(this.commandHandler,!1);case"PinchZoom":return new im(this.commandHandler,!0);case"PortDrag":return new fa(this.commandHandler,"Port");case"PortDraw":return new pa(this.commandHandler,"ConnectorSourceEnd",this.diagram.drawingObject);case"LabelSelect":return new tm(this.commandHandler,!0,"LabelSelect");case"LabelDrag":return new jne(this.commandHandler);case"LabelResizeSouthEast":case"LabelResizeSouthWest":case"LabelResizeNorthEast":case"LabelResizeNorthWest":case"LabelResizeSouth":case"LabelResizeNorth":case"LabelResizeWest":case"LabelResizeEast":return new Vne(this.commandHandler,t);case"LabelRotate":return new Wne(this.commandHandler)}return null},n.prototype.getCursor=function(t){var e=this.diagram.selectedItems.annotation?this.diagram.selectedItems.wrapper.children[0]:this.diagram.selectedItems;return function Fne(n,t){if(t+=360,t%=360,-1===n.indexOf("Resize"))return Xx[""+n];var e=Xx[""+n];return t>=0&&t<25||t>=160&&t<=205||t>=340&&t<=360?e:t>=25&&t<=70||t>=205&&t<=250?"n-resize"===e||"s-resize"===e?"ne-resize":"nw-resize"===e||"se-resize"===e?"n-resize":"e-resize"===e||"w-resize"===e?"nw-resize":"e-resize":t>=70&&t<=115||t>=250&&t<=295?"n-resize"===e||"s-resize"===e?"e-resize":"nw-resize"===e||"se-resize"===e?"ne-resize":"e-resize"===e||"w-resize"===e?"n-resize":"nw-resize":t>=115&&t<=155||t>=295&&t<=340?"n-resize"===e||"s-resize"===e?"nw-resize":"nw-resize"===e||"se-resize"===e?"e-resize":"e-resize"===e||"w-resize"===e?"ne-resize":Xx[""+n]:"n-resize"}(t,this.diagram.selectedItems.annotation?e.rotateAngle+e.parentTransform:e.rotateAngle)},n.prototype.findElementUnderMouse=function(t,e,i,r){return this.objectFinder.findElementUnderSelectedItem(t,e,i,r)},n.prototype.findObjectsUnderMouse=function(t,e){return this.objectFinder.findObjectsUnderMouse(t,this.diagram,this.eventArgs,e)},n.prototype.findObjectUnderMouse=function(t,e,i){return this.objectFinder.findObjectUnderMouse(this.diagram,t,e,i,this.eventArgs,this.currentPosition)},n.prototype.findTargetUnderMouse=function(t,e,i,r,s){return this.objectFinder.findObjectUnderMouse(this.diagram,t,e,i,this.eventArgs,r,s)},n.prototype.findActionToBeDone=function(t,e,i,r){return function kne(n,t,e,i,r,s,o){if(s&&s.length>1&&r&&r.length>1)return"PinchZoom";if(i.currentSymbol)return"Drag";if("PortDraw"===i.eventHandler.action&&(i.tool&=~ri.DrawOnce),(k3(i)||UI(i))&&i.drawingObject)return"Draw";if($a(i)&&(l=i.selectedItems).wrapper&&qr(l.constraints,"UserHandle"))for(var h=0,c=l.userHandles;h=50&&(l.x=(a.points[parseInt(h.toString(),10)].x+a.points[h+1].x)/2,l.y=(a.points[parseInt(h.toString(),10)].y+a.points[h+1].y)/2,wr(e,l,n.hitPadding?n.hitPadding:10)))return"OrthoThumb"}else HI(n)&&console.warn('[WARNING] :: Module "ConnectorEditing" is not available in Diagram component! You either misspelled the module name or forgot to load it.');return null}(g,l,e,i);if("OrthoThumb"===S)return S;if(qr(l.constraints,"ConnectorSourceThumb")&&zI(g)&&S||qr(l.constraints,"ConnectorTargetThumb")&&RI(g)&&S)return S}}else{var b=i.selectedItems.handleSize/2/i.scroller.currentZoom,M=10/i.scroller.currentZoom,w=Bi();qi(w,f.rotateAngle+f.parentTransform,f.offsetX,f.offsetY);var C=f.offsetX-f.pivot.x*f.actualSize.width,D=f.offsetY-f.pivot.y*f.actualSize.height,A={x:C+(.5===f.pivot.x?2*f.pivot.x:f.pivot.x)*f.actualSize.width/2,y:D-30/i.scroller.currentZoom};A=Ke(w,A);var x=!!i.selectedItems.annotation,P=!(!x||!BI(i.selectedItems.annotation));if(qr(l.constraints,"Rotate")&&wr(e,A,M)&&i.selectedItems.thumbsConstraints&bt.Rotate){if(x&&P)return"LabelRotate";if(!x)return"Rotate"}if(u.Inflate(b),u.containsPoint(e)&&(S=function Pne(n,t,e,i,r,s){var o;return 1===n.selectedItems.nodes.length&&0===n.selectedItems.connectors.length&&n.selectedItems.nodes[0].container&&(o=function Hne(n,t,e,i,r){var s=10/n.scroller.currentZoom,o=n.selectedItems,a=t.actualSize.width,l=t.actualSize.height,h=new Ne(i,r,t.style.strokeWidth,l),c=new Ne(i+a,r,t.style.strokeWidth,l),d=new Ne(i,r,a,t.style.strokeWidth),u=new Ne(i,r+l,a,t.style.strokeWidth),f=Dn(n,n.selectedItems.nodes[0],!0)?n.nameTable[n.selectedItems.nodes[0].parentId]:n.selectedItems.nodes[0];if(ga(o.constraints,"ResizeEast",o.thumbsConstraints,o)&&c.containsPoint(e,s))return"ResizeEast";if(ga(o.constraints,"ResizeSouth",o.thumbsConstraints,o)&&u.containsPoint(e,s))return"ResizeSouth";if("Grid"!==f.container.type){if(ga(o.constraints,"ResizeWest",o.thumbsConstraints,o)&&h.containsPoint(e,s))return"ResizeWest";if(ga(o.constraints,"ResizeNorth",o.thumbsConstraints,o)&&d.containsPoint(e,s))return"ResizeNorth"}return null}(n,t,e,r,s)),!o&&(!n.selectedItems.nodes[0]||!n.selectedItems.nodes[0].isPhase&&!n.selectedItems.nodes[0].isLane&&"SwimLane"!==n.selectedItems.nodes[0].shape.type)&&(o=function Bne(n,t,e,i,r,s){var o=40/n.scroller.currentZoom,a=n.selectedItems.handleSize/2/n.scroller.currentZoom,l=n.selectedItems,h=!!l.annotation;if(t.actualSize.width>=o&&t.actualSize.height>=o){if(ga(l.constraints,"ResizeSouthEast",l.thumbsConstraints,l)&&wr(e,Ke(i,{x:r+t.actualSize.width,y:s+t.actualSize.height}),a))return h?"LabelResizeSouthEast":"ResizeSouthEast";if(ga(l.constraints,"ResizeSouthWest",l.thumbsConstraints,l)&&wr(e,Ke(i,{x:r,y:s+t.actualSize.height}),a))return h?"LabelResizeSouthWest":"ResizeSouthWest";if(ga(l.constraints,"ResizeNorthEast",l.thumbsConstraints,l)&&wr(e,Ke(i,{x:r+t.actualSize.width,y:s}),a))return h?"LabelResizeNorthEast":"ResizeNorthEast";if(ga(l.constraints,"ResizeNorthWest",l.thumbsConstraints,l)&&wr(e,Ke(i,{x:r,y:s}),a))return h?"LabelResizeNorthWest":"ResizeNorthWest"}return ga(l.constraints,"ResizeEast",l.thumbsConstraints,l)&&wr(e,Ke(i,{x:r+t.actualSize.width,y:s+t.actualSize.height/2}),a)?h?"LabelResizeEast":"ResizeEast":ga(l.constraints,"ResizeWest",l.thumbsConstraints,l)&&wr(e,Ke(i,{x:r,y:s+t.actualSize.height/2}),a)?h?"LabelResizeWest":"ResizeWest":ga(l.constraints,"ResizeSouth",l.thumbsConstraints,l)&&wr(e,Ke(i,{x:r+t.actualSize.width/2,y:s+t.actualSize.height}),a)?h?"LabelResizeSouth":"ResizeSouth":ga(l.constraints,"ResizeNorth",l.thumbsConstraints,l)&&wr(e,Ke(i,{x:r+t.actualSize.width/2,y:s}),a)?h?"LabelResizeNorth":"ResizeNorth":null}(n,t,e,i,r,s)),o||null}(i,f,e,w,C,D),S))return S}}if(Oc(i)&&!n)return"Pan";if((o instanceof Es||o instanceof Lc)&&(!Oc(i)||Vv(i)||Wv(i))&&(S=function Rne(n,t,e,i){if(Ux(t)&&(va(t,ci.Hover)||va(t,ci.Visible))){if(t.constraints&oi.Drag)return"PortDrag"}else if(_x(t)&&(va(t,ci.Hover)||va(t,ci.Visible))&&t.constraints&oi.Draw){n.drawingObject={};var r={type:"Orthogonal",sourcePortID:t.id};return n.drawingObject=r,n.tool|=ri.DrawOnce,n.currentDrawingObject=r,"PortDraw"}return"None"}(i,o),"None"!==S))return S;if((o instanceof Kn||o instanceof Or)&&!Oc(i)&&Ad(o))return _r(i,o,void 0,t)&&ro(o)?"LabelDrag":"LabelSelect";if(null!==n){if(!(n instanceof te||n instanceof de))return"Select";if(t&&t.id){var L=t.id.split(n.id)[1];if(L&&L.match("^_icon"))return"LayoutAnimation"}if(t&&t.id)for(var O=void 0,N=0;N-1)return"FixedUserHandle";if(t instanceof ai&&t.hyperlink.link)return"Hyperlink";if(!ro(n)||!_r(i,n,!1)||void 0!==i.selectedItems.annotation)return n&&Oc(i)&&!jI(i)?"Pan":i.selectedItems.nodes.length&&i.selectedItems.nodes[0].isLane&&i.selectedItems.wrapper&&i.selectedItems.wrapper.bounds.containsPoint(e)?"Drag":"Select";if(n instanceof de&&!wr(e,n.sourcePoint,n.hitPadding)&&!wr(e,n.targetPoint,n.hitPadding)||!(n instanceof de))return"Drag"}return"Select"}(t,e,this.currentPosition,this.diagram,this.touchStartList,this.touchMoveList,r)},n.prototype.updateContainerBounds=function(t){var e=!1;if(this.diagram.selectedObject.helperObject&&this.diagram.selectedObject.actualObject)for(var i=this.diagram.selectedObject.actualObject,r=this.diagram.selectedObject.actualObject instanceof ei?i.nodes:[i],s=0;si.y&&(h+=u>0?-1:1,u+=u>0?-1:1):i&&e.wrapper.offsetYi.x&&(h+=u>0?-1:1,u+=u>0?-1:1):i&&e.wrapper.offsetX1)for(var S=t.offsetX-this.diagram.selectedItems.offsetX,b=t.offsetY-this.diagram.selectedItems.offsetY,M=t.rotateAngle-this.diagram.selectedItems.rotateAngle,w=0;w-1){var A=c.children;A.splice(A.indexOf(o.id),1),this.diagram.nameTable[o.id].parentId="",i=!0,c.wrapper.children.splice(D,1)}}if(function One(n,t,e,i){var r=n,s=e.nameTable[r.parentId],o=e.nameTable[r.parentId];if(t&&o&&o.container&&"Stack"===o.container.type&&t.container&&"Stack"===t.container.type&&o.id!==t.parentId){var a=o.wrapper.children.indexOf(r.wrapper);a>-1&&(e.nameTable[r.id].parentId=t.id,o.wrapper.children.splice(a,1))}if(t&&t.parentId&&r.parentId&&"Drag"===i&&o.container&&"Stack"===o.container.type){var l=s.wrapper.children.indexOf(t.wrapper),h=s.wrapper.children.indexOf(r.wrapper),c={targetIndex:l,target:t,sourceIndex:h,source:n};s.wrapper.children.splice(h,1),s.wrapper.children.splice(l,0,r.wrapper),e.commandHandler.addHistoryEntry({type:"StackChildPositionChanged",redoObject:{targetIndex:h,target:t,sourceIndex:l,source:n},undoObject:c,category:"Internal"})}}(o,h,this.diagram,this.action),(c=Dn(this.diagram,o)?this.diagram.nameTable[o.parentId]:this.diagram.nameTable[o.parentId]||o)&&c.container&&"Canvas"===c.container.type&&(c.wrapper.maxWidth=c.maxWidth=c.wrapper.actualSize.width,c.wrapper.maxHeight=c.maxHeight=c.wrapper.actualSize.height,e=!0),Dn(this.diagram,o,!0)&&c&&"Canvas"===c.container.type)if(this.diagram.selectedItems.nodes.length>1)for(w=0;w0)for(var i=0;i0&&e.columnIndex>0||l&&e.isLane)){if("Horizontal"===t.container.orientation&&e.isPhase&&e.wrapper.width>e.maxWidth&&(e.maxWidth=e.wrapper.width,e.wrapper.maxWidth=e.wrapper.width),h.updateColumnWidth(e.columnIndex,r.width,!0,c),Wx(this.diagram,e,t),e.isPhase){var p=this.diagram.nameTable[""+t.shape.phases[e.columnIndex].header.id];p.maxWidth0?(r=new op(t,"",u),t.shape.classShape.attributes.push(r)):i.id.includes("_umlMethods")&&t.shape.classShape.methods.length>0&&(s=new fm(t,"",u),t.shape.classShape.methods.push(s))),"Interface"===t.shape.classifier&&(i.id.includes("_umlProperty")&&t.shape.interfaceShape.attributes.length>0?(r=new op(t,"",u),t.shape.classShape.attributes.push(r)):i.id.includes("_umlMethods")&&t.shape.interfaceShape.methods.length>0&&(s=new fm(t,"",u),t.shape.interfaceShape.methods.push(s))),"Enumeration"===t.shape.classifier&&i.id.includes("_umlMember")&&t.shape.enumerationShape.members.length>0){var f=new ub(t,"",u);t.shape.enumerationShape.members.push(f)}t.wrapper.children.indexOf(c.wrapper),this.diagram.enableServerDataBinding(!0),this.diagram.add(c),this.diagram.updateConnectorEdges(t),this.diagram.clearSelection(),this.diagram.select([this.diagram.nameTable[c.id]]),this.diagram.endGroupAction(),this.diagram.startTextEdit()}}},n}(),Zoe=function(){function n(){}return n.prototype.findObjectsUnderMouse=function(t,e,i,r,s){var o=[];r&&r instanceof ei&&r.nodes.length+r.connectors.length===1&&(r=r.nodes[0]||r.connectors[0]).children&&0===r.children.length&&(i.actualObject=r);for(var a,l,h,c,p,d=r&&r instanceof de&&(r.constraints&qe.ConnectToNearByNode||r.constraints&qe.ConnectToNearByPort)&&r.connectionPadding||0,f={},g=0,v=e.spatialSearch.findObjects(new Ne(t.x-50-d,t.y-50-d,100+d,100+d));g-1&&o.splice(T,1),"UmlClassifier"===y.shape.type&&y.container&&"Stack"===y.container.type&&(T=o.indexOf(e.nameTable[e.nameTable[y.id].wrapper.children[0].id]))>-1&&o.splice(T,1)}for(var z=0;zs.zIndex&&(t[parseInt(r.toString(),10)]=l),r>0&&i&&a&&(a.isLane||a.isPhase||a.isHeader)&&t[parseInt(r.toString(),10)].zIndex=2)for(var d=t.length-1;d>=0;d--)if(t[parseInt(d.toString(),10)].parentId){var u=hm(t[parseInt(d.toString(),10)],e,""),f=hm(t[d-1],e,""),g=e.nameTable[""+f];g&&u!==f&&e.nameTable[""+u].zIndex=0;p--){d=ip(e[parseInt(p.toString(),10)],!1),c=ip(e[parseInt(p.toString(),10)],!0);var g=t[""+l].tool,v=this.findTargetElement(e[parseInt(p.toString(),10)].wrapper,o,t,void 0);if("Draw"===i&&v&&(e[parseInt(p.toString(),10)]instanceof te||e[parseInt(p.toString(),10)]instanceof de)&&!hb(e[parseInt(p.toString(),10)],v)&&(g&&"ConnectorSourceEnd"===g[""+h]&&!Rh(e[parseInt(p.toString(),10)])||g&&"ConnectorTargetEnd"===g[""+h]&&!ua(e[parseInt(p.toString(),10)])))return u;if(e[parseInt(p.toString(),10)]instanceof te||e[parseInt(p.toString(),10)]instanceof de&&(Rh(e[parseInt(p.toString(),10)])||Ld(d)||ua(e[parseInt(p.toString(),10)])||zh(c)||"PortDraw"===i&&g instanceof zd&&"ConnectorTargetEnd"===g[""+h]&&(ua(e[parseInt(p.toString(),10)])||zh(c))))return u=e[parseInt(p.toString(),10)],f&&(u=this.isTarget(u,t,i)),s.actualObject=u,u}else if("ConnectorTargetEnd"===i&&a){for(p=e.length-1;p>=0;p--)if(c=ip(e[parseInt(p.toString(),10)],!0),(e[parseInt(p.toString(),10)]instanceof te||e[parseInt(p.toString(),10)]instanceof de)&&(ua(e[parseInt(p.toString(),10)])||zh(c)))return u=e[parseInt(p.toString(),10)],u=this.isTarget(u,t,i),s.actualObject=u,u}else{if(a&&("Drag"===i||t[""+l].tool instanceof fa)){var y=0;for(p=0;p=S.zIndex?u:S,y=Math.max(y,S.zIndex)):y=(u=S).zIndex)}return u&&"Bpmn"===u.shape.type&&(t.selectedItems.nodes.length>0&&"Bpmn"===t.selectedItems.nodes[0].shape.type||(u=null)),u&&(s.actualObject=u),u}if("Select"!==i&&"Pan"!==i||!t[""+l].tool)if("Pan"===i||"LayoutAnimation"===i){for(p=e.length-1;p>=0;p--)if((e[parseInt(p.toString(),10)]instanceof te||e[parseInt(p.toString(),10)]instanceof de)&&(v=this.findTargetElement(e[parseInt(p.toString(),10)].wrapper,o,t,void 0),"Pan"===i||v&&(v.id.match("_icon_content_shape$")||v.id.match("_icon_content_rect$"))))return e[parseInt(p.toString(),10)]}else u=e[e.length-1],s&&u&&(s.actualObject=u);else{for(p=e.length-1;p>=0;p--)if(e[parseInt(p.toString(),10)]instanceof de){var b=e[p-1];if(e[p-1]instanceof te&&b.ports){if((v=this.findTargetElement(b.wrapper,o,t,void 0))&&(v.id.match("_icon_content_shape$")||v.id.match("_icon_content_rect$")))return b;for(var M=0;M=0;s--){var o=t.children[parseInt(s.toString(),10)];if(o&&o.outerBounds.containsPoint(e,r||0))if(o.visible){if(o instanceof Cs){var a=this.findTargetElement(o,e,i);if(a)return a}var l="Clip"===o.style.textOverflow||"Ellipsis"===o.style.textOverflow;if(o.bounds.containsPoint(e,r||0)&&!l)return o;if(t.bounds.containsPoint(e,r||0)&&l)return o}else if(o instanceof Ze&&t&&t.id){var h=void 0;if(t.id.includes("group_container")){var c=t.id.slice(0,-15);h=i.getObject(c)}else h=i.getObject(t.id);if(ab(h,o.id))return o}}return t.bounds.containsPoint(e,r)&&"none"!==t.style.fill?t:null},n}(),Joe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),lp=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},n_=function(n){function t(e,i,r,s){var o=n.call(this,e,i,r,s)||this;return o.objectZIndex=-1,o.zIndexTable={},o.objects=[],o}return Joe(t,n),lp([I("")],t.prototype,"id",void 0),lp([I(!0)],t.prototype,"visible",void 0),lp([I(!1)],t.prototype,"lock",void 0),lp([I()],t.prototype,"objects",void 0),lp([I()],t.prototype,"addInfo",void 0),lp([I(-1)],t.prototype,"zIndex",void 0),t}(Ee),DT=function(n,t,e,i){return new(e||(e=Promise))(function(r,s){function o(h){try{l(i.next(h))}catch(c){s(c)}}function a(h){try{l(i.throw(h))}catch(c){s(c)}}function l(h){h.done?r(h.value):new e(function(c){c(h.value)}).then(o,a)}l((i=i.apply(n,t||[])).next())})},xT=function(n,t){var i,r,s,o,e={label:0,sent:function(){if(1&s[0])throw s[1];return s[1]},trys:[],ops:[]};return o={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function a(h){return function(c){return function l(h){if(i)throw new TypeError("Generator is already executing.");for(;e;)try{if(i=1,r&&(s=2&h[0]?r.return:h[0]?r.throw||((s=r.return)&&s.call(r),0):r.next)&&!(s=s.call(r,h[1])).done)return s;switch(r=0,s&&(h=[2&h[0],s.value]),h[0]){case 0:case 1:s=h;break;case 4:return e.label++,{value:h[1],done:!1};case 5:e.label++,r=h[1],h=[0];continue;case 7:h=e.ops.pop(),e.trys.pop();continue;default:if(!(s=(s=e.trys).length>0&&s[s.length-1])&&(6===h[0]||2===h[0])){e=0;continue}if(3===h[0]&&(!s||h[1]>s[0]&&h[1]1)for(var i=0;i-1)return e[parseInt(i.toString(),10)];return this.diagram.activeLayer},n.prototype.getLayer=function(t){for(var e=this.diagram.layers,i=0;i=0;o--)this.diagram.unSelect(this.diagram.nameTable[s[parseInt(o.toString(),10)]]),this.diagram.remove(this.diagram.nameTable[s[parseInt(o.toString(),10)]]),"default_layer"!==i.id&&this.diagram.activeLayer.id===t&&(this.diagram.activeLayer=this.diagram.layers[this.diagram.layers.length-1]);delete this.diagram.layerZIndexTable[i.zIndex],this.diagram.layers.splice(r,1),"SVG"!==this.diagram.mode&&this.diagram.refreshDiagramLayer()}},n.prototype.moveObjects=function(t,e){this.diagram.startGroupAction();for(var i={},r=[],s=0;s-1){if(r=[],(h=this.diagram.nameTable[""+s]).children)for(var p=0,g=h.children;p0){for(var y=void 0,S=0,b=r;S0)for(var r=0;r0)for(r=0;r0){t=t.concat(this.diagram.selectedItems.connectors);for(var i=0;i0)for(t=t.concat(this.diagram.selectedItems.nodes),i=0;i0){for(var i=0,r=t.shape.activity.subProcess.processes;i0&&this.copyProcesses(this.processTable[""+s])}this.clipboardData.processTable=this.processTable}},n.prototype.group=function(){this.oldSelectedObjects=am(this.diagram);var e=this.diagram.isProtectedOnChange;this.diagram.protectPropertyChange(!0),this.diagram.diagramActions=this.diagram.diagramActions|ee.Group;var r={};r.id="group"+Qe(),(r=new te(this.diagram,"nodes",r,!0)).children=[];for(var s=this.diagram.selectedItems.nodes.concat(this.diagram.selectedItems.connectors).sort(function(h,c){return h.zIndex-c.zIndex}),o=0;o0){var a=this.diagram.add(r);a&&this.select(a),this.addHistoryEntry({type:"Group",undoObject:r,redoObject:r,category:"Internal"}),this.diagram.diagramActions=this.diagram.diagramActions&~ee.Group,this.diagram.protectPropertyChange(e)}},n.prototype.unGroup=function(t){var i=this.diagram.isProtectedOnChange;this.diagram.protectPropertyChange(!0),this.diagram.diagramActions=this.diagram.diagramActions|ee.Group;var r=[];t?r.push(t):r=this.diagram.selectedItems.nodes,this.diagram.startGroupAction();for(var s=0;s0&&this.diagram.removePorts(o,o.ports),o.annotations&&o.annotations.length>0&&!ce()&&this.diagram.removeLabels(o,o.annotations);for(var c=this.diagram.nameTable[o.parentId],d=o.children.length-1;d>=0;d--)this.diagram.nameTable[o.children[parseInt(d.toString(),10)]].parentId="",this.diagram.deleteChild(this.diagram.nameTable[o.children[parseInt(d.toString(),10)]],o),o.parentId&&o.children[parseInt(d.toString(),10)]&&this.diagram.addChild(c,o.children[parseInt(d.toString(),10)]);this.resetDependentConnectors(o.inEdges,!0),this.resetDependentConnectors(o.outEdges,!1),this.diagram.diagramActions&ee.UndoRedo||this.addHistoryEntry({type:"UnGroup",undoObject:a,redoObject:a,category:"Internal"}),o.parentId&&this.diagram.deleteChild(o,c)}this.diagram.removeNode(o,l),this.clearSelection()}this.diagram.endGroupAction(),this.diagram.diagramActions=this.diagram.diagramActions&~ee.Group,this.diagram.protectPropertyChange(i)},n.prototype.resetDependentConnectors=function(t,e){for(var i=0;i0&&(g=!1)}if(g){var y=this.cloneConnector(f,i);c.push(y),o[h.id]=y.id}}else{var S=this.cloneNode(h,i);if(c.push(S),S){o[h.id]=S.id;var b=h.inEdges;if(b)for(var M=0,w=b;M0)for(var u=0;u0)for(r=t.segments,s=0;s0&&this.diagram.drawingObject&&"Bezier"===this.diagram.drawingObject.type&&(t.segments=[]);var e=this.diagram.add(t);"SVG"!==this.diagram.mode&&this.diagram.refreshDiagramLayer(),this.selectObjects([e]),t&&!UI(this.diagram)&&(this.diagram.tool&=~ri.DrawOnce,this.diagram.currentDrawingObject=void 0)},n.prototype.enableServerDataBinding=function(t){this.diagram.enableServerDataBinding(t)},n.prototype.addText=function(t,e){var i=this.diagram.findElementUnderMouse(t,e,this.diagram);this.diagram.startTextEdit(t,i instanceof ai?i.id.split("_")[1]:void 0)},n.prototype.isUserHandle=function(t){var e=this.diagram.selectedItems;if(e.wrapper&&qr(e.constraints,"UserHandle"))for(var i=0,r=e.userHandles;i0&&t[0]&&t[0].isLane)for(s=this.diagram.getObject(t[0].parentId),t[0].shape.header=[],a=0;a1||e&&1===t.length)){if(1!==t.length)return[2];this.clearSelection()}if(!(u||d||1!==t.length||e&&$a(this.diagram)))return this.clearSelection(),[2]}if(!r.cancel){for(f=0;f0||e)&&p.children&&!p.parentId)for(g=0;g0||e,!0)}else this.select(p,f>0||e,!0);void 0===i&&(i=c),r={oldValue:i||[],newValue:this.getSelectedObject(),cause:this.diagram.diagramActions,state:"Changed",type:"Addition",cancel:!1},this.diagram.renderSelector(e||t&&t.length>1),ce()||this.diagram.triggerEvent(Ce.selectionChange,r),this.diagram.enableServerDataBinding(!0)}return[2]})})},n.prototype.findParent=function(t){return t.parentId&&this.findParent(t=this.diagram.nameTable[t.parentId]),t},n.prototype.selectProcesses=function(t){if(this.hasProcesses(t))for(var e=t.shape.activity.subProcess.processes,i=0;i0)},n.prototype.select=function(t,e,i){var r=this.getObjectLayer(t.id);if(Ad(t)&&!(t instanceof ei)&&!_r(this.diagram,t)&&r&&!r.lock&&r.visible&&t.wrapper.visible){(e=!!$a(this.diagram)&&e)||this.clearSelection(),this.diagram.enableServerDataBinding(!1);var s=this.diagram.selectedItems;if(t instanceof te?s.nodes.push(t.isHeader?this.diagram.nameTable[t.parentId]:t):s.connectors.push(t),s.selectedObjects.push(t),e)s.wrapper.rotateAngle=s.rotateAngle=0,s.wrapper.children.push(t.wrapper);else if(s.init(this.diagram),1===s.nodes.length&&0===s.connectors.length){var l=Yx(this.diagram,s);l&&(s.wrapper.children[0]=l),s.rotateAngle=s.nodes[0].rotateAngle,s.wrapper.rotateAngle=s.nodes[0].rotateAngle,s.wrapper.pivot=s.nodes[0].pivot}i||this.diagram.renderSelector(e),this.diagram.enableServerDataBinding(!0)}},n.prototype.labelSelect=function(t,e){this.oldSelectedObjects=am(this.diagram);var i=this.diagram.selectedItems,r=this.diagram.allowServerDataBinding;this.diagram.allowServerDataBinding=!1,i.nodes=i.connectors=[],this.diagram.allowServerDataBinding=r,t instanceof te?i.nodes[0]=t:i.connectors[0]=t,i.annotation=this.findTarget(e,t),i.init(this.diagram),this.diagram.renderSelector(!1)},n.prototype.unSelect=function(t){var e=this.diagram.selectedItems.nodes.concat(this.diagram.selectedItems.connectors),i=e.filter(function(a){return a.id!==t.id}),r={oldValue:e,newValue:i,cause:this.diagram.diagramActions,state:"Changing",type:"Removal",cancel:!1};if(this.diagram.currentSymbol||ce()||this.diagram.triggerEvent(Ce.selectionChange,r),_r(this.diagram,t)){var s=this.diagram.selectedItems,o=void 0;t instanceof te?(o=s.nodes.indexOf(t,0),s.nodes.splice(o,1)):(o=s.connectors.indexOf(t,0),s.connectors.splice(o,1)),o=s.selectedObjects.indexOf(t,0),s.selectedObjects.splice(o,1),(r={oldValue:e,newValue:i,cause:this.diagram.diagramActions,state:"Changed",type:"Removal",cancel:(r={oldValue:e,newValue:i,cause:this.diagram.diagramActions,state:"Changed",type:"Removal",cancel:!1}).cancel}).cancel||(o=s.wrapper.children.indexOf(t.wrapper,0),s.wrapper.children.splice(o,1),this.diagram.updateSelector(),this.diagram.currentSymbol||this.diagram.triggerEvent(Ce.selectionChange,r))}},n.prototype.moveSvgNode=function(t,e){var i=this.diagram.nameTable[""+e];if("Native"===i.shape.type||"HTML"===i.shape.type)this.updateNativeNodeIndex(t,e);else{var r=xt(e+"_groupElement",this.diagram.element.id),s=xt(t+"_groupElement",this.diagram.element.id);r.parentNode.insertBefore(s,r)}},n.prototype.moveAfterSvgNode=function(t,e){var i=this.diagram.nameTable[""+e];if(!i||"HTML"!==i.shape.type&&"Native"!==i.shape.type)a=xt(e+"_groupElement",this.diagram.element.id),o=xt(t+"_groupElement",this.diagram.element.id),a.insertAdjacentElement("afterend",o);else for(var r=0;rd&&"SwimLane"!==p.shape.type){var S=$(p);p.zIndex=d-((-1!==i.indexOf(p)?i.indexOf(p):0)+1),p.children&&(d=this.findLowestZIndex(p,c)||d),this.triggerOrderCommand(S,p,p),p.children&&this.updateGroupZindex(p,"SendToBack",d)}else"SwimLane"===p.shape.type&&(y=this.swapZIndexObjects(a,h,r,g));if("SVG"===this.diagram.mode){for(var M="SwimLane"!==this.diagram.nameTable[""+r].shape.type?d:y,w=h[parseInt(M.toString(),10)];!w&&Md)&&(d=f.zIndex)}for(var p=JSON.parse(JSON.stringify(l)),v=Number(Object.keys(l).sort(function(wo,Ul){return Number(wo)-Number(Ul)}).reverse()[0]),y=this.diagram.nameTable[""+e].zIndex,S=[],M=0;M<=v;M++)S.push(l[parseInt(M.toString(),10)]);if("SwimLane"===this.diagram.nameTable[""+e].shape.type)for(var C=v;C>=y;C--)if(l[parseInt(C.toString(),10)]&&this.diagram.nameTable[l[parseInt(C.toString(),10)]].parentId!==e){v=C;break}var D=this.diagram.nameTable[""+e];if(D.zIndexx&&(x=L.zIndex)}}else x=d;D.zIndex=x+((-1!==r.indexOf(D)?r.indexOf(D):0)+1),this.triggerOrderCommand(A,D,D)}else if("SwimLane"===D.shape.type){for(var O=0,N=-1,T=0,z=0,U=JSON.parse(JSON.stringify(l)),B=0;B<=y;B++)if(l[parseInt(B.toString(),10)]&&this.diagram.nameTable[l[parseInt(B.toString(),10)]].parentId===e&&-1===N){N=B,T=B;break}for(var j=0;j<=v;j++)p[parseInt(j.toString(),10)]&&p[parseInt(j.toString(),10)]!==e&&this.diagram.nameTable[p[parseInt(j.toString(),10)]].parentId!==e&&this.diagram.nameTable[p[parseInt(j.toString(),10)]].zIndex>=this.diagram.nameTable[""+e].zIndex&&O++;for(var ue=N,fe=0;fe<=O;fe++){for(;!l[parseInt(ue.toString(),10)];)ue++;z=this.diagram.nameTable[l[parseInt(ue.toString(),10)]].zIndex,ue++}for(var Me=z;Me<=v;Me++){for(;!U[parseInt(N.toString(),10)];)N++;for(;!l[parseInt(Me.toString(),10)];)Me++;l[parseInt(Me.toString(),10)]=U[parseInt(N.toString(),10)],this.diagram.nameTable[l[parseInt(Me.toString(),10)]].zIndex=Me,N++}l[parseInt(v.toString(),10)]=this.diagram.nameTable[""+e].id,this.diagram.nameTable[""+e].zIndex=v,ue=y+1;for(var De=T,xe=0;xe0&&("Native"===hr[0].shape.type||"HTML"===hr[0].shape.type)){for(Ci.parentNode.removeChild(Ci),De=0;De0?r[0]:null},n.prototype.findLowestZIndex=function(t,e){var r=this.diagram.nodes.filter(function(s){return-1!==e.indexOf(s.id)}).filter(function(s){return""===s.parentId&&s.id!==t.id}).map(function(s){return s.zIndex});return r.sort(function(s,o){return s-o}),r.length>0?r[0]:null},n.prototype.triggerOrderCommand=function(t,e,i){var s={zIndex:$(t).zIndex},o={zIndex:e.zIndex},a={element:i,cause:this.diagram.diagramActions,diagramAction:this.diagram.getDiagramAction(this.diagram.diagramActions),oldValue:s,newValue:o};this.diagram.triggerEvent(Ce.propertyChange,a)},n.prototype.checkGroupNode=function(t,e,i){return i[""+e].parentId===i[""+t].parentId},n.prototype.sortByZIndex=function(t,e,i){if("BringForward"===i){var r=e||"zIndex";t=t.sort(function(o,a){return a[""+r]-o[""+r]})}else{var s=e||"zIndex";t=t.sort(function(o,a){return o[""+s]-a[""+s]})}return t},n.prototype.orderCommands=function(t,e,i){var r=this,s=e.nodes;if(s=s.concat(e.connectors),t)if("SendBackward"===i)for(var o=0;oa}),S=v.filter(function(D){return D0?Math.max.apply(Math,S):a,M=y.length>0?Math.min.apply(Math,y):a;if(a!==M){var w=c.zIndexTable[parseInt(M.toString(),10)],C=c.zIndexTable[parseInt(a.toString(),10)];this.moveSvgNode(C,w)}else"SendToBack"===i&&(w=c.zIndexTable[parseInt(a.toString(),10)],C=c.zIndexTable[parseInt(b.toString(),10)],this.moveAfterSvgNode(w,C))}}else this.diagram.refreshCanvasLayers()}},n.prototype.swapDomOrder=function(t,e){if(t){var i=this.diagram.getObject(e);if("Native"===i.shape.type||"HTML"===i.shape.type)this.updateNativeNodeIndex(e,t),this.updateNativeNodeIndex(t,e);else{var r=xt(e+"_groupElement",this.diagram.element.id),s=xt(t+"_groupElement",this.diagram.element.id);r.parentNode.insertBefore(r,s),r.parentNode.insertBefore(s,r)}}},n.prototype.sendForward=function(t){var e=this;if(this.diagram.protectPropertyChange(!0),$a(this.diagram)||t){$(t||(this.diagram.selectedItems.nodes.length?this.diagram.selectedItems.nodes[0]:this.diagram.selectedItems.connectors[0]));var s=t&&t.id,o=this.diagram.layers.indexOf(this.getObjectLayer(s=s||(this.diagram.selectedItems.nodes.length?this.diagram.selectedItems.nodes[0].id:this.diagram.selectedItems.connectors[0].id))),a=$(this.diagram.nameTable),h=(parseInt(o.toString(),10),this.diagram.nameTable[""+s]),c=[],d=this.diagram.spatialSearch.findObjects(h.wrapper.bounds);d.length>2&&(d=this.sortByZIndex(d,void 0,"BringForward"));for(var u=0,f=d;u=0;p--)this.diagram.nameTable[c[parseInt(p.toString(),10)].id].parentId===s&&c.splice(p,1);if(c.length>0){var y=this.diagram.nameTable[c[c.length-1].id];if(y.parentId){var b=hm(y,this.diagram,""),M=this.diagram.nameTable[""+b];M.id!==s&&(c[0]=M)}var w={};for(p=0;p0&&(Object.values(O).forEach(function(ue){ue>=T&&N.push(ue)}),0!==N.length&&this.updateZIndexBySendForward(h,N,o))}var z=[];if(Object.keys(this.changedNodeZIndexes).forEach(function(ue){if((a[""+ue]?a[""+ue].zIndex:null)!==e.changedNodeZIndexes[""+ue]){var De=$(a[""+ue]);z.push(De)}}),this.updateLayerZindexTable(o),L.nodes.splice(0,L.nodes.length),z.forEach(function(ue){var fe=$(ue);L.nodes.push(fe)}),"SVG"===this.diagram.mode){var U=c[c.length-1].id,B=c[c.length-1];B&&!("HTML"===B.shape.type||"Native"===B.shape.type)&&this.moveAfterSvgNode(s,U),this.updateNativeNodeIndex(U,s)}else this.diagram.refreshCanvasLayers();var j=[];Object.keys(this.changedNodeZIndexes).forEach(function(ue){if((a[""+ue]?a[""+ue].zIndex:null)!==e.changedNodeZIndexes[""+ue]){var De=$(e.diagram.nameTable[""+ue]);j.push(De)}});var Q=$(this.diagram.selectedItems);Q.nodes.splice(0,Q.nodes.length),j.forEach(function(ue){var fe=$(ue);Q.nodes.push(fe)}),this.diagram.diagramActions&ee.UndoRedo||this.addHistoryEntry({type:"SendForward",category:"Internal",undoObject:L,redoObject:Q}),this.diagram.endGroupAction()}}this.diagram.protectPropertyChange(!1)},n.prototype.updateZIndexBySendForward=function(t,e,i){var r=$(t);t.zIndex=Math.min.apply(Math,e);var a,s=Math.min.apply(Math,e),o=Math.min.apply(Math,e),l=this.diagram.layers[parseInt(i.toString(),10)].objects,h=this.diagram.nodes.filter(function(S){return-1!==l.indexOf(S.id)});t.children&&this.updateGroupZindex(t,"BringForward",t.zIndex);var c=h.filter(function(S){return S.zIndex===Math.min.apply(Math,e)&&S.id!==t.id});if(c&&c.length>0&&c[0].children){for(var d=Math.min.apply(Math,e),u=0;uo&&g!==t&&g.parentId!==t.id&&c&&c.length>0&&g.parentId!==c[0].id){var v=$(g);g.zIndex=a+1,a++,this.triggerOrderCommand(v,g,g)}var y=g.zIndex;this.changedNodeZIndexes[g.id]=(this.changedNodeZIndexes.hasOwnProperty(g.id),y)}},n.prototype.arrangeZIndexForLowerNodes=function(t,e,i){var r=i.filter(function(o){return o.zIndex<=t&&o.parentId!==e.id});r.sort(function(o,a){return a.zIndex-o.zIndex});for(var s=0;se&&(e=r.zIndex)}return e},n.prototype.sendBackward=function(t){var e=this;if(this.diagram.protectPropertyChange(!0),$a(this.diagram)||t){$(t||(this.diagram.selectedItems.nodes.length?this.diagram.selectedItems.nodes[0]:this.diagram.selectedItems.connectors[0]));var s=t&&t.id,o=this.diagram.layers.indexOf(this.getObjectLayer(s=s||(this.diagram.selectedItems.nodes.length?this.diagram.selectedItems.nodes[0].id:this.diagram.selectedItems.connectors[0].id))),a=$(this.diagram.nameTable),h=(parseInt(o.toString(),10),this.diagram.nameTable[""+s]),c=[],d=this.diagram.spatialSearch.findObjects(h.wrapper.bounds);d.length>2&&(d=this.sortByZIndex(d));for(var u=0,f=d;uNumber(p.zIndex)&&""===p.parentId&&h.wrapper.bounds.intersects(p.wrapper.bounds)&&c.push(p);for(var p=c.length-1;p>=0;p--)(v=this.diagram.nameTable[c[parseInt(p.toString(),10)].id]).parentId===s&&c.splice(p,1);if(c.length>0){var v;if((v=this.diagram.nameTable[c[c.length-1].id]).parentId){var S=hm(v,this.diagram,""),b=this.diagram.nameTable[""+S];s!==b.id&&(c[c.length-1]=b)}var M={};for(p=0;p0&&(Object.values(L).forEach(function(fe){fe<=N&&O.push(fe)}),0!==O.length&&this.updateZIndexBySendBackward(h,O,o))}var T=[];if(Object.keys(this.changedNodeZIndexes).forEach(function(fe){if((a[""+fe]?a[""+fe].zIndex:null)!==e.changedNodeZIndexes[""+fe]){var xe=$(a[""+fe]);T.push(xe)}}),this.updateLayerZindexTable(o),P.nodes.splice(0,P.nodes.length),T.forEach(function(fe){var Me=$(fe);P.nodes.push(Me)}),"SVG"===this.diagram.mode){var z=c[c.length-1].id,U=c[c.length-1];U&&"HTML"!==U.shape.type&&"Native"!==U.shape.type&&this.moveSvgNode(s,z);var B=this.diagram.nameTable[""+z];B.children&&B.children.length>0?this.updateNativeNodeIndex(s):this.updateNativeNodeIndex(s,z)}else this.diagram.refreshCanvasLayers();var j=[];Object.keys(this.changedNodeZIndexes).forEach(function(fe){if((a[""+fe]?a[""+fe].zIndex:null)!==e.changedNodeZIndexes[""+fe]){var xe=$(e.diagram.nameTable[""+fe]);j.push(xe)}});var Q=$(this.diagram.selectedItems);Q.nodes.splice(0,Q.nodes.length),j.forEach(function(fe){var Me=$(fe);Q.nodes.push(Me)}),this.diagram.diagramActions&ee.UndoRedo||this.addHistoryEntry({type:"SendBackward",category:"Internal",undoObject:P,redoObject:Q}),this.diagram.endGroupAction()}}this.diagram.protectPropertyChange(!1)},n.prototype.updateZIndexBySendBackward=function(t,e,i){var r=$(t);t.zIndex=Math.max.apply(Math,e);var f,s=t.zIndex,o=Math.max.apply(Math,e),a=this.diagram.layers[parseInt(i.toString(),10)].objects,l=this.diagram.nodes.filter(function(S){return-1!==a.indexOf(S.id)}),h=l.filter(function(S){return S.zIndex===Math.max.apply(Math,e)&&S.id!==t.id});if(h&&h.length>0&&h[0].children)for(var c=Math.max.apply(Math,e),d=0;d0&&g.parentId!==h[0].id){var v=$(g);g.zIndex=f-1,f--,this.triggerOrderCommand(v,g,g)}var y=g.zIndex;this.changedNodeZIndexes[""+g.id]=(this.changedNodeZIndexes.hasOwnProperty(g.id),y)}},n.prototype.findLowestChildZIndex=function(t){for(var e=t.zIndex,i=0;i0),this.selectObjects([t],!0))},n.prototype.clearSelection=function(t,e){return DT(this,void 0,void 0,function(){var i,r,s,o;return xT(this,function(a){return i=this.diagram.allowServerDataBinding,this.diagram.enableServerDataBinding(!1),$a(this.diagram)&&(r=this.diagram.selectedItems,s=this.getSelectedObject(),this.diagram.currentSymbol&&(this.diagram.previousSelectedObject=s),o={oldValue:s,newValue:[],cause:this.diagram.diagramActions,state:"Changing",type:"Removal",cancel:!1},t&&(ce()||this.diagram.triggerEvent(Ce.selectionChange,o)),o.cancel||(r.offsetX=0,r.offsetY=0,r.width=0,r.height=0,r.rotateAngle=0,r.nodes=[],r.connectors=[],r.wrapper=null,r.annotation=void 0,r.selectedObjects=[],this.diagram.clearSelectorLayer(),t&&(o={oldValue:s,newValue:[],cause:this.diagram.diagramActions,state:"Changed",type:"Removal",cancel:!1},ce()||this.diagram.triggerEvent(Ce.selectionChange,o))),this.diagram.enableServerDataBinding(i)),[2]})})},n.prototype.clearSelectedItems=function(){this.clearSelection((this.diagram.selectedItems.nodes?this.diagram.selectedItems.nodes.length:0)+(this.diagram.selectedItems.connectors?this.diagram.selectedItems.connectors.length:0)>0)},n.prototype.removeStackHighlighter=function(){var t=Fl(this.diagram.element.id),e=t.getElementById(t.id+"_stack_highlighter");e&&e.parentNode.removeChild(e)},n.prototype.renderStackHighlighter=function(t,e){var r,s,o,i=this.diagram.selectedItems.nodes[0];if(!e){var a=this.diagram.findObjectsUnderMouse(t.position);if((e=this.diagram.findObjectUnderMouse(a,"Drag",!0))&&!(e.isLane||e.isPhase||e.isHeader))for(var l=0;l0)for(var a=0;a1)if(i){var h=l.segments[0],c=l.segments[1],u=Ol(LI(t.wrapper,t.wrapper.corners,t.wrapper.bounds),h.direction),g=kl({corners:void 0,point:u=qa(l,0,u,{x:l.sourceWrapper.offsetX,y:l.sourceWrapper.offsetY},!1),margin:void 0,direction:h.direction},{corners:void 0,point:c.points[1],margin:void 0,direction:void 0});h.length=R.distancePoints(g[0],g[1]),c.direction&&c.length&&(c.length=R.distancePoints(g[1],g[2]))}else if(o){switch(l.segments[0].direction){case"Bottom":r=t.wrapper.bounds.bottomCenter.x-e.bottomCenter.x,s=t.wrapper.bounds.bottomCenter.y-e.bottomCenter.y;break;case"Top":r=t.wrapper.bounds.topCenter.x-e.topCenter.x,s=t.wrapper.bounds.topCenter.y-e.topCenter.y;break;case"Left":r=t.wrapper.bounds.middleLeft.x-e.middleLeft.x,s=t.wrapper.bounds.middleLeft.y-e.middleLeft.y;break;case"Right":r=t.wrapper.bounds.middleRight.x-e.middleRight.x,s=t.wrapper.bounds.middleRight.y-e.middleRight.y}this.dragSourceEnd(l,r,s,!0,null,"ConnectorSourceEnd",void 0,void 0,void 0,!(t.parentId&&this.diagram.diagramActions&ee.isGroupDragging))}}},n.prototype.updateEndPoint=function(t,e){var r={sourcePoint:t.sourcePoint,targetPoint:t.targetPoint};t.sourceID&&(r.sourceID=t.sourceID),t.targetID&&(r.targetID=t.targetID),t.sourcePortID&&(r.sourcePortID=t.sourcePortID),t.targetPortID&&(r.targetPortID=t.targetPortID),t.segments&&(r.segments=t.segments),this.diagram.connectorPropertyChange(t,e||{},r),this.diagram.updateSelector()},n.prototype.dragSourceEnd=function(t,e,i,r,s,o,a,l,h,c,d){var u=this.diagram.nameTable[t.id],f={},p=this.checkBoundaryConstraints(e,i,u.wrapper.bounds);if(zI(u)&&p&&"BezierSourceThumb"!==o&&Qv(this.diagram)&&(f=$(f={sourcePoint:u.sourcePoint}),u.sourcePoint.x+=e,u.sourcePoint.y+=i,"ConnectorSourceEnd"===o&&"Orthogonal"===u.type&&this.changeSegmentLength(u,l,h,c),"Bpmn"===u.shape.type&&"Default"===u.shape.sequence&&"Sequence"===u.shape.flow&&this.updatePathElementOffset(u)),"Bezier"===u.type)if(f={sourcePoint:u.sourcePoint},d)this.translateBezierPoints(t,""===o?"ConnectorSourceEnd":o,e,i,d,s,!a);else for(var g=0;g2){var d=R.direction((c=t.segments[2]).points[0],c.points[1]);o.direction===_n(d)?("Right"===o.direction?c.points[0].x=o.points[o.points.length-1].x=l.wrapper.corners.middleRight.x+20:"Left"===o.direction?c.points[0].x=o.points[o.points.length-1].x=l.wrapper.corners.middleLeft.x-20:c.points[0].y=o.points[o.points.length-1].y="Top"===o.direction?l.wrapper.corners.topCenter.y-20:l.wrapper.corners.bottomCenter.y+20,c.direction&&c.length&&(c.length=R.distancePoints(c.points[0],c.points[c.points.length-1])),o.length=R.distancePoints(o.points[0],o.points[o.points.length-1])):o.direction===d&&c.direction&&c.length?("Top"===o.direction||"Bottom"===o.direction?(c.points[0]=o.points[0],c.points[c.points.length-1].x=c.points[0].x):(c.points[0]=o.points[0],c.points[c.points.length-1].y=c.points[0].y),c.length=R.distancePoints(c.points[0],c.points[c.points.length-1]),t.segments.splice(0,2)):o.length=20}else o.length=20;else if(o.length<1)if(""!==t.sourceID){var c;"Right"===a.direction?a.points[a.points.length-1].y=(h=l.wrapper.corners.middleRight).y:"Left"===a.direction?a.points[a.points.length-1].y=(h=l.wrapper.corners.middleLeft).y:a.points[a.points.length-1].x="Top"===a.direction?(h=l.wrapper.corners.topCenter).x:(h=l.wrapper.corners.bottomCenter).x,a.length=R.distancePoints(h,a.points[a.points.length-1]),t.segments.length>2&&(c=t.segments[2]).direction&&c.length&&(c.length=R.distancePoints(a.points[a.points.length-1],c.points[c.points.length-1])),t.segments.splice(0,1)}else t.segments.splice(0,1)}else e&&!i&&t.sourceID!==e.id&&t.segments&&null!==t.segments[0].direction&&e&&e instanceof te&&s&&this.changeSourceEndToNode(t,e),e&&i&&t.sourcePortID!==i&&t.segments&&null!==t.segments[0].direction&&e&&e instanceof te&&s&&this.changeSourceEndToPort(t,e,i)},n.prototype.canConnect=function(t,e){return!(!ua(e)||!Rh(e))},n.prototype.changeSourceEndToPort=function(t,e,i){var r=this.diagram.getWrapper(e.wrapper,i),s={x:r.offsetX,y:r.offsetY},o=zo(s,xn(e.wrapper),e.wrapper.bounds),a=t.segments[0],l=t.segments[1];if(a.direction!==o){var h=[],c={};if(a.direction===_n(o)){c={};var d=void 0;"Top"===o||"Bottom"===o?(d="Top"===o?{type:"Orthogonal",isTerminal:!0,direction:o,length:Math.abs(a.points[0].y-s.y)}:{type:"Orthogonal",isTerminal:!0,direction:o,length:Math.abs(s.y-a.points[0].y)},c=a.points[0].x>s.x?{type:"Orthogonal",isTerminal:!0,direction:"Right",length:a.points[0].x-s.x}:{type:"Orthogonal",isTerminal:!0,direction:"Left",length:s.x-a.points[0].x}):(d="Right"===o?{type:"Orthogonal",isTerminal:!0,direction:o,length:Math.abs(a.points[0].x-s.x)}:{type:"Orthogonal",isTerminal:!0,direction:o,length:Math.abs(s.x-a.points[0].x)},c=a.points[0].y>s.y?{type:"Orthogonal",direction:"Top",isTerminal:!0,length:a.points[0].y-s.y}:{type:"Orthogonal",direction:"Bottom",isTerminal:!0,length:s.y-a.points[0].y}),h.push(new wi(t,"segments",d,!0)),h.push(new wi(t,"segments",c,!0))}else h.push(new wi(t,"segments",c={type:"Orthogonal",direction:o,length:20,isTerminal:!0},!0));a.direction!==_n(o)&&("Top"===o||"Bottom"===o?(a.points[0].x=s.x,a.points[0].y=a.points[a.points.length-1].y="Top"===o?s.y-20:s.y+20):(a.points[0].y=s.y,a.points[0].x=a.points[a.points.length-1].x="Right"===o?s.x+20:s.x-20),a.length=R.distancePoints(a.points[0],a.points[a.points.length-1]),l.length=R.distancePoints(a.points[a.points.length-1],l.points[l.points.length-1])),t.segments=h.concat(t.segments)}else a.points[0]=s,"Top"===o||"Bottom"===o?a.points[a.points.length-1].x=s.x:a.points[a.points.length-1].y=s.y,a.length=R.distancePoints(a.points[0],a.points[a.points.length-1]),l.length=R.distancePoints(a.points[a.points.length-1],l.points[l.points.length-1])},n.prototype.removeTerminalSegment=function(t,e){for(var i=0;ii.width||"Left"===o.direction&&r.x>=o.points[0].x||"Right"===o.direction&&r.x<=o.points[0].x)o.points[0].y=o.points[o.points.length-1].y=r.y,o.points[0].x=r.x,o.length=R.distancePoints(o.points[0],o.points[o.points.length-1]),a.length=R.distancePoints(o.points[o.points.length-1],a.points[a.points.length-1]);else{var h=void 0;s="Bottom"===(h=a.direction?a.direction:R.direction(a.points[0],a.points[a.points.length-1]))?i.bottomCenter:i.topCenter,a.length&&a.direction&&(a.length="Top"===h?o.points[o.points.length-1].y-(s.y+20):s.y+20-o.points[o.points.length-1].y),o.length=o.points[o.points.length-1].x-s.x,o.direction=o.length>0?"Right":"Left",l.push(new wi(t,"segments",{type:"Orthogonal",direction:h,length:20},!0)),t.segments=l.concat(t.segments)}else r="Bottom"===o.direction?i.bottomCenter:i.topCenter,o.length>i.height||"Top"===o.direction&&r.y>=o.points[0].y||"Bottom"===o.direction&&r.y<=o.points[0].y?(o.points[0].x=o.points[o.points.length-1].x=r.x,o.points[0].y=r.y,o.length=R.distancePoints(o.points[0],o.points[o.points.length-1]),a.length=R.distancePoints(o.points[o.points.length-1],a.points[a.points.length-1])):(s="Left"===a.direction?i.middleLeft:i.middleRight,h=void 0,h=a.direction?a.direction:R.direction(a.points[0],a.points[a.points.length-1]),a.length&&a.direction&&(a.length="Left"===h?o.points[o.points.length-1].x-(s.x+20):s.x+20-o.points[o.points.length-1].x),o.length=o.points[o.points.length-1].y-s.y,o.direction=o.length>0?"Bottom":"Top",l.push(new wi(t,"segments",{type:"Orthogonal",direction:h,length:20},!0)),t.segments=l.concat(t.segments))},n.prototype.translateBezierPoints=function(t,e,i,r,s,o,a){var l=t.segments.indexOf(s),h=t.segments[parseInt(l.toString(),10)],c=l>0?t.segments[l-1]:null,d=null!==c?c.point:t.sourcePoint,u=l===t.segments.length-1?t.targetPoint:h.point;if(h)if("BezierSourceThumb"===e&&(h.vector1.angle||h.vector1.distance)){var f=h.vector1.distance,p=h.vector1.angle;h.vector1={distance:t.distance(d,o),angle:R.findAngle(d,o)},this.translateSubsequentSegment(t,s,!0,h.vector1.distance-f,h.vector1.angle-p)}else"BezierTargetThumb"===e&&(h.vector2.angle||h.vector2.distance)?(f=h.vector2.distance,p=h.vector2.angle,h.vector2={distance:t.distance(u,o),angle:R.findAngle(u,o)},this.translateSubsequentSegment(t,s,!1,h.vector2.distance-f,h.vector2.angle-p)):("ConnectorSourceEnd"===e&&!t.sourceID||"ConnectorTargetEnd"===e&&!t.targetID)&&a&&KI(h.vector1)&&KI(h.vector2)?(R.isEmptyPoint(h.point1)&&(h.bezierPoint1=eb(t.sourcePoint,t.targetPoint)),R.isEmptyPoint(h.point2)&&(h.bezierPoint2=eb(t.targetPoint,t.sourcePoint))):"BezierSourceThumb"===e||"ConnectorSourceEnd"===e&&!a&&KI(h.vector1)?(h.bezierPoint1.x+=i,h.bezierPoint1.y+=r,(!R.isEmptyPoint(h.point1)||a)&&(h.point1={x:h.bezierPoint1.x,y:h.bezierPoint1.y})):("BezierTargetThumb"===e||"ConnectorTargetEnd"===e&&!a&&KI(h.vector2))&&(h.bezierPoint2.x+=i,h.bezierPoint2.y+=r,(!R.isEmptyPoint(h.point2)||a)&&(h.point2={x:h.bezierPoint2.x,y:h.bezierPoint2.y}))},n.prototype.translateSubsequentSegment=function(t,e,i,r,s){var o=t.segments.indexOf(e);parseInt(o.toString(),10),t.bezierSettings.smoothness&EI.SymmetricAngle||(s=null),t.bezierSettings.smoothness&EI.SymmetricDistance||(r=null),(null!=r||null!=s)&&(i?0!==o&&this.updatePreviousBezierSegment(t,o,r,s):o!==t.segments.length-1&&this.updateNextBezierSegment(t,o,r,s))},n.prototype.updatePreviousBezierSegment=function(t,e,i,r){var s=t.segments[e-1],a=(s.vector2.angle+r)%360;a<0&&(a+=360),s.vector2={distance:s.vector2.distance+i,angle:a}},n.prototype.updateNextBezierSegment=function(t,e,i,r){var s=t.segments[e+1],a=(s.vector1.angle+r)%360;a<0&&(a+=360),s.vector1={distance:s.vector1.distance+i,angle:a}},n.prototype.dragTargetEnd=function(t,e,i,r,s,o,a,l){var c,h=this.diagram.nameTable[t.id],d=this.checkBoundaryConstraints(e,i,h.wrapper.bounds);if(RI(h)&&"BezierTargetThumb"!==o&&d&&Qv(this.diagram)){if(c=$(c={targetPoint:h.targetPoint}),h.targetPoint.x+=e,h.targetPoint.y+=i,"ConnectorTargetEnd"===o&&"Orthogonal"===h.type&&h.segments&&h.segments.length>0){var u=h.segments[h.segments.length-2];u&&2===h.segments[h.segments.length-1].points.length&&("Left"===u.direction||"Right"===u.direction?u.points[u.points.length-1].x=h.targetPoint.x:u.points[u.points.length-1].y=h.targetPoint.y,u.length=R.distancePoints(u.points[0],u.points[u.points.length-1]),u.direction=R.direction(u.points[0],u.points[u.points.length-1]))}"Bpmn"===h.shape.type&&"Default"===h.shape.sequence&&"Sequence"===h.shape.flow&&this.updatePathElementOffset(h)}if("Bezier"===h.type)if(c={targetPoint:h.targetPoint},l)this.translateBezierPoints(t,""===o?"ConnectorTargetEnd":o,e,i,l,s,!a);else for(var f=0;f0){if(void 0!==s&&o.segments[parseInt(s.toString(),10)])if("Bezier"===o.type){var a=o.segments[parseInt(s.toString(),10)],l=a.isInternalSegment;l&&null!==o.bezierSettings&&"FreeForm"!==o.bezierSettings.segmentEditOrientation?("Horizontal"===a.orientation?a.point.x+=e:a.point.y+=i,this.updateDirectionalBezierCurve(o)):(a.point.x+=e,a.point.y+=i),l&&(o.isBezierEditing=!0)}else o.segments[parseInt(s.toString(),10)].point.x+=e,o.segments[parseInt(s.toString(),10)].point.y+=i;else for(var h=0;h1){var a=e[1],l=e[2],h={x:.5*(a.x+l.x),y:.5*(a.y+l.y)},c=t.segments[0];c.vector1.angle=Gt(s,a),c.vector1.distance=.5*R.findLength(s,a),c.vector2.angle=Gt(h,a),c.vector2.distance=.5*R.findLength(h,a),c.point=h;var d=t.segments[1];if(d.vector1.angle=Gt(h,l),d.vector1.distance=.5*R.findLength(h,l),t.segments.length>2){var u=e[3],f={x:.5*(l.x+u.x),y:.5*(l.y+u.y)};d.vector2.angle=Gt(f,l),d.vector2.distance=.5*R.findLength(f,l),d.point=f;var p=t.segments[2];if(p.vector1.angle=Gt(f,u),p.vector1.distance=.5*R.findLength(f,u),t.segments.length>3){var g=e[4],v={x:.5*(u.x+g.x),y:.5*(u.y+g.y)};p.vector2.angle=Gt(v,u),p.vector2.distance=.5*R.findLength(v,u),p.point=v;var y=t.segments[3];y.vector1.angle=Gt(v,g),y.vector1.distance=.5*R.findLength(v,g),y.vector2.angle=Gt(o,g),y.vector2.distance=.5*R.findLength(o,g)}else p.vector2.angle=Gt(o,u),p.vector2.distance=.5*R.findLength(o,u)}else d.vector2.angle=Gt(o,l),d.vector2.distance=.5*R.findLength(o,l)}},n.prototype.rotateObjects=function(t,e,i,r,s){r=r||{};var o=Bi();qi(o,i,r.x,r.y);for(var l=0,h=e;l0){this.diagram.protectPropertyChange(!0);var o=t;o.segments=[],this.diagram.connectorPropertyChange(o,{},{segments:o.segments}),this.diagram.protectPropertyChange(!1)}}},n.prototype.updateInnerParentProperties=function(t){var r=this.diagram.isProtectedOnChange;this.diagram.protectPropertyChange(!0);for(var s=this.getAllDescendants(t,[],!1,!0),o=0;o0&&(f=this.diagram.bpmnModule.getChildrenBound(d,d.id,this.diagram),u=d.wrapper.bounds.containsRect(f)),h=d.wrapper.actualSize.width*t,c=d.wrapper.actualSize.height*e,void 0!==d.maxWidth&&0!==d.maxWidth&&(h=Math.min(d.maxWidth,h)),void 0!==d.minWidth&&0!==d.minWidth&&(h=Math.max(d.minWidth,h)),void 0!==d.maxHeight&&0!==d.maxHeight&&(c=Math.min(d.maxHeight,c)),void 0!==d.minHeight&&0!==d.minHeight&&(c=Math.max(d.minHeight,c)),u&&(h=Math.max(h,f.right-d.wrapper.bounds.x),c=Math.max(c,f.bottom-d.wrapper.bounds.y)),t=h/d.actualSize.width,e=c/d.actualSize.height}var p=Bi();o||(o=r);var g=o.wrapper;if(qi(p,-g.rotateAngle,i.x,i.y),Xf(p,t,e,i.x,i.y),qi(p,g.rotateAngle,i.x,i.y),r instanceof te){var d,v=Ke(p,{x:(d=r).wrapper.offsetX,y:d.wrapper.offsetY}),y=d.wrapper.offsetX-d.wrapper.actualSize.width*d.pivot.x,S=d.wrapper.offsetY-d.wrapper.actualSize.height*d.pivot.y;if(h>0)if(d.processId){var b=this.diagram.nameTable[d.processId];(!b.maxWidth||d.margin.left+h0)if(d.processId){var M=this.diagram.nameTable[d.processId];(!M.maxHeight||d.margin.top+c0){if(e.dragLimit=e.dragLimit?e.dragLimit:{},e.dragLimit.top||e.dragLimit.bottom||e.dragLimit.left||e.dragLimit.right){var b={minDistance:null};S=this.getRelativeOffset(v,d,b);var M={minDistance:null};g=this.getRelativeOffset(v,y,M),S=null!=b&&M.minDistance0){if(S=y[y.length-1]){var b=void 0;for(b=0;b=e.x-t.dragLimit.left-r.width/2&&i.x<=e.x+t.dragLimit.right+r.width/2&&(s=!0),i.y>=e.y-t.dragLimit.top-r.height/2&&i.y<=e.y+t.dragLimit.bottom+r.height/2&&(o=!0),{x:s,y:o}},n.prototype.updateLabelMargin=function(t,e,i,r,s,o,a){if(i=i||{x:e.offset,y:0},e&&i&&i.x>0&&i.x<1){var l=R.getLengthFromListOfPoints(t.intermediatePoints),h=this.getPointAtLength(l*i.x,t.intermediatePoints,0),c=this.diagram.scrollSettings.currentZoom,d=e.dragLimit?e.dragLimit:{left:0,right:0,top:0,bottom:0};if(d.top||d.bottom||d.left||d.right){this.diagram.getWrapper(t.wrapper,e.id);var f=new Ne(0,0,0,0),p=this.diagram.getWrapper(t.wrapper,e.id);f.x=p.offsetX/c+o,f.y=p.offsetY/c+a,f.width=p.bounds.width/c,f.height=p.bounds.height/c;var g=new Ne(h.x-(d.left||0)-f.width/2,h.y-(d.top||0)-f.height/2,(d.left||0)+(d.right||0)+f.width,(d.top||0)+(d.bottom||0)+f.height);if(g.containsPoint(r));else for(var S=0,b=this.boundsInterSects([h,r],g,!1);S=t){c=t-r,d=R.findAngle(s,a),u=c*Math.cos(d*Math.PI/180),f=c*Math.sin(d*Math.PI/180),o={x:s.x+u,y:s.y+f};break}r+=h,s=a}else s=a;return o},n.prototype.getInterceptWithSegment=function(t,e){for(var o,a,i=[],r=[],s=[],l=R.findLength({x:0,y:0},{x:this.diagram.scroller.viewPortWidth,y:this.diagram.scroller.viewPortHeight}),h=1;h0&&a<=90||a>180&&a<=270?90:-90;r.push(R.transform(t,a+c,l)),r.push(R.transform(t,o+c,l));var f=nm({x1:s[0].x,y1:s[0].y,x2:s[1].x,y2:s[1].y},{x1:r[0].x,y1:r[0].y,x2:r[1].x,y2:r[1].y});f.enabled&&i.push(f.intersectPt)}return i},n.prototype.getAnnotationChanges=function(t,e){var r={};return r[lb(t,e.id,!0)]={width:e.width,height:e.height,offset:t instanceof te?{x:e.offset.x,y:e.offset.y}:e.offset,rotateAngle:e.rotateAngle,margin:{left:e.margin.left,right:e.margin.right,top:e.margin.top,bottom:e.margin.bottom},horizontalAlignment:e.horizontalAlignment,verticalAlignment:e.verticalAlignment,alignment:t instanceof de?e.alignment:void 0},{annotations:r}},n.prototype.getConnectorPortChanges=function(t,e){var i=function Wse(n,t,e){for(var i=n.ports,r=0;r1&&(v.width=g,v.offset.x=1/S),p>1&&(v.height=p,v.offset.y=1/b)}}e instanceof Or&&(e.alignment="Center"),l=this.getAnnotationChanges(t,e),t instanceof te?this.diagram.nodePropertyChange(t,a,l):this.diagram.connectorPropertyChange(t,a,l),this.diagram.updateDiagramObject(t)},n.prototype.getSubProcess=function(t){var i,e={nodes:[],connectors:[]};return t instanceof te?i=t.processId:t&&t.nodes&&t.nodes.length&&t.nodes[0].processId&&(i=t.nodes[0].processId),i&&e.nodes.push($(this.diagram.nameTable[i])),e},n.prototype.checkBoundaryConstraints=function(t,e,i,r){var s=this.diagram.pageSettings,o=this.diagram.pageSettings.boundaryConstraints,a=this.diagram.scroller;if("Page"===o||"Diagram"===o){var l=i?void 0:this.diagram.selectedItems.wrapper.bounds;return!!((i?i.right:l.right)+(t||0)<=("Page"===o?s.width:a.viewPortWidth)&&(i?i.left:l.left)+(t||0)>=0&&(i?i.bottom:l.bottom)+(e||0)<=("Page"===o?s.height:a.viewPortHeight)&&(i?i.top:l.top)+(e||0)>=0||"None"!==this.diagram.layout.type&&r)}return!0},n.prototype.dragSelectedObjects=function(t,e){var i=this,r=this.diagram.selectedItems;this.state&&!this.state.backup&&(this.state.backup={},this.state.backup.offsetX=r.offsetX,this.state.backup.offsetY=r.offsetY),r=qI(this.diagram,r)||r;var s=this.diagram.selectedItems.nodes.filter(function(c){return"SwimLane"===c.shape.type});if(s.length>0&&!this.diagram.currentSymbol&&this.diagram.selectedItems.nodes.length>1){var o=this.diagram.selectedItems.nodes.filter(function(c){return""===c.parentId||"SwimLane"!==i.diagram.nameTable[c.parentId].shape.type});if(o.length>0){for(var a=0;a0||l.length>1)&&(o=o.concat(l),this.diagram.selectedItems.nodes.splice(0,this.diagram.selectedItems.nodes.length),o.forEach(function(c){i.diagram.selectedItems.nodes.push(c)}),r=this.diagram.selectedItems,this.diagram.selectedObject.helperObject=void 0)}}if(this.checkBoundaryConstraints(t,e)){this.diagram.diagramActions=this.diagram.diagramActions|ee.PreventZIndexOnDragging|ee.DragUsingMouse;var h=this.diagram.selectedObject.actualObject;return(h&&h instanceof te&&h.isLane&&Gx(h,this.diagram)||!h||!h.isLane)&&this.diagram.drag(r,t,e),this.diagram.diagramActions=this.diagram.diagramActions&~(ee.PreventZIndexOnDragging|ee.DragUsingMouse),this.diagram.refreshCanvasLayers(),this.checkHtmlObjectDrag(r),!0}return!1},n.prototype.checkHtmlObjectDrag=function(t){var e=!1;this.diagram.views&&this.diagram.views.length>1&&(t instanceof ei?e=t.nodes.some(function(i){return i.shape&&"HTML"===i.shape.type}):t.shape&&"HTML"===t.shape.type&&(e=!0),e&&this.resetOverviewCanvas())},n.prototype.resetOverviewCanvas=function(){for(var t=0,e=this.diagram.views;t0&&(this.layoutAnimateModule.stopCurrentAnimation(this.objectStore[0],e,t),this.objectStore=[]),a=this.diagram.doLayout(),this.objectStore.push(a)),this.canUpdateTemplate=!1,this.diagram.blazorActions&=~on.expandNode,this.diagram.preventNodesUpdate=r,this.diagram.layoutAnimateModule&&this.diagram.organizationalChartModule&&!i)this.diagram.allowServerDataBinding=!1,this.layoutAnimateModule.expand(this.diagram.layout.enableAnimation,a,t,this.diagram);else{var l={element:$(t),state:!!t.isExpanded};this.triggerEvent(Ce.expandStateChange,l),this.diagram.lineRoutingModule&&this.diagram.constraints&nt.LineRouting&&"ComplexHierarchicalTree"!==this.diagram.layout.type&&this.diagram.resetSegments()}return this.diagram.layout.fixedNode=""===o?"":this.diagram.layout.fixedNode,a},n.prototype.getparentexpand=function(t,e,i,r){for(var s,o=0;o0&&(this.diagram.selectedItems.wrapper.rotateAngle=this.diagram.selectedItems.rotateAngle=s.rotateAngle),!(r instanceof te&&"SwimLane"!==r.shape.type)||r.isLane||r.isPhase||r.isHeader||Dn(this.diagram,r)){if(r instanceof ei)for(var d=0;d30||g.wrapper.outerBounds.topCenter.y-p.wrapper.outerBounds.bottomCenter.y>30)&&this.diagram.lineRoutingModule.refreshConnectorSegments(this.diagram,f,!0)}}this.updateSelector(),this.diagram.protectPropertyChange(!1)}},n.prototype.drawSelectionRectangle=function(t,e,i,r){this.diagram.drawSelectionRectangle(t,e,i,r)},n.prototype.startGroupAction=function(){this.diagram.startGroupAction()},n.prototype.endGroupAction=function(){this.diagram.endGroupAction()},n.prototype.removeChildFromBPmn=function(t,e,i){var r=this.diagram.nameTable[t.id]||t.nodes[0];if(i&&r&&r.processId&&r.processId===i.wrapper.id){var s=$(r);s.processId=r.processId,this.diagram.startGroupAction();var o=this.diagram.nameTable[r.processId].shape.activity.subProcess.processes||[];o.splice(o.indexOf(r.id),1),this.diagram.bpmnModule.removeChildFromBPMN(this.diagram.nameTable[r.processId].wrapper,r.id,this.diagram),this.diagram.nameTable[r.id].processId="",r.offsetX=r.wrapper.offsetX,r.offsetY=r.wrapper.offsetY;var a=$(r);this.addHistoryEntry({type:"PositionChanged",redoObject:{nodes:[a]},undoObject:{nodes:[s]},category:"Internal"}),this.diagram.endGroupAction()}},n.prototype.isDroppable=function(t,e){var i=this.diagram.nameTable[t.id]||t.nodes[0];return i instanceof te&&(!ce()&&"TextAnnotation"===i.shape.shape||("Group"===e.shape.shape&&(e.shape.activity.subProcess.collapsed=!1),!(i&&"Bpmn"===i.shape.type&&(i.processId===e.id||i.id===e.processId||"Bpmn"===e.shape.type&&!(e instanceof de)&&e.shape.activity&&e.shape.activity.subProcess&&e.shape.activity.subProcess.collapsed))))},n.prototype.renderHighlighter=function(t,e,i){if(new Ne,t.target instanceof te||t.target instanceof de||e&&(t.source instanceof te||t.source instanceof de)){var a=this.findTarget(e?t.sourceWrapper:t.targetWrapper,e?t.source:t.target,i,!0),l=void 0;if(a instanceof Bd)for(var h=a.id,c=t.target,u=0,f=c.wrapper.children[0].children[0].children[2].children;u0){var r=0;t[0]=this.diagram.nameTable[t[0].id]||t[0];var s="Object"===i?yr(t[0].wrapper):this.diagram.selectedItems.wrapper.bounds,o={nodes:[],connectors:[]},a={nodes:[],connectors:[]};for(r="Object"===i?r+1:r;r0){var i=0,r=0,s=0,o=0,a=0,l=0,h=0,c=0,d={nodes:[],connectors:[]},u={nodes:[],connectors:[]};for(i=0;io.center.y&&(r=n[parseInt(e.toString(),10)],n[parseInt(e.toString(),10)]=n[parseInt(i.toString(),10)],n[parseInt(i.toString(),10)]=r):s.center.x>o.center.x&&(r=n[parseInt(e.toString(),10)],n[parseInt(e.toString(),10)]=n[parseInt(i.toString(),10)],n[parseInt(i.toString(),10)]=r)}}return n}(t,e),i=1;i0){var i=0,r={x:.5,y:.5};t[0]=this.diagram.nameTable[t[0].id]||t[0];var s=yr(t[0].wrapper),o={nodes:[],connectors:[]},a={nodes:[],connectors:[]};for(i=1;ii.zIndex){for(var s=this.diagram.layers.indexOf(this.diagram.getActiveLayer()),o=this.diagram.layers[parseInt(s.toString(),10)].zIndexTable,a=JSON.parse(JSON.stringify(o)),l=i.zIndex,h=r.zIndex,c=h;c>=l;c--)l!==c?o[c-1]?(o[parseInt(c.toString(),10)]=o[c-1],this.diagram.nameTable[o[parseInt(c.toString(),10)]].zIndex=c):(o[c-1]=o[parseInt(c.toString(),10)],this.diagram.nameTable[o[c-1]].zIndex=c,delete o[parseInt(c.toString(),10)]):this.swapZIndexObjects(h,o,r.id,a);"SVG"===this.diagram.mode?(this.moveSvgNode(e.parentId,i.id),this.updateNativeNodeIndex(e.parentId,i.id)):this.diagram.refreshCanvasLayers()}},n.prototype.findLeastIndexConnector=function(t,e,i){for(var r=0;rs.zIndex&&(i=s)}return i},n.prototype.findLeastIndexObject=function(t,e){var i=t;return t instanceof te&&(i=this.findLeastIndexConnector(t.inEdges,e,i),i=this.findLeastIndexConnector(t.outEdges,e,i)),i},n.prototype.checkSelection=function(t,e){var i;if(1===t.nodes.length&&0===t.connectors.length)if(Dn(this.diagram,t.nodes[0],!0)){var r=t.nodes[0];if("SwimLane"===(i="SwimLane"===t.nodes[0].shape?t.nodes[0]:this.diagram.nameTable[t.nodes[0].parentId]).shape.type){var s="Horizontal"===i.shape.orientation;(r.isPhase&&(s&&"ResizeSouth"===e||!s&&"ResizeEast"===e)||r.isLane&&(s&&"ResizeEast"===e||!s&&"ResizeSouth"===e))&&W3(this.diagram,i,e)}else if("Grid"===i.container.type)if("Horizontal"===i.container.orientation&&1===r.rowIndex||"Vertical"===i.container.orientation&&r.rowIndex>0&&r.columnIndex>0){if("ResizeSouth"===e)for(var o=0;o1&&(this.diagram.realActions=this.diagram.realActions|$i.hScrollbarMoved,this.scrolled=!0),this.diagram.scrollSettings.horizontalOffset=t},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"verticalOffset",{get:function(){return this.vOffset},set:function(t){this.vOffset=t,Math.abs(this.vOffset-this.diagram.scrollSettings.verticalOffset)>1&&(this.diagram.realActions=this.diagram.realActions|$i.vScrollbarMoved,this.scrolled=!0),this.diagram.scrollSettings.verticalOffset=t},enumerable:!0,configurable:!0}),n.prototype.getBounds=function(){var e=this.diagram.spatialSearch.getPageBounds(0,0);return(e.x<0||e.y<0)&&!this.diagram.pageSettings.multiplePage?this.getPageBounds(void 0,void 0,!0,!0):this.getPageBounds(void 0,void 0,!0)},n.prototype.updateScrollOffsets=function(t,e){var i,r,s=this.getBounds();s.x*=this.currentZoom,s.y*=this.currentZoom,s.width*=this.currentZoom,s.height*=this.currentZoom,i=Math.max(0,t-s.left),r=Math.max(0,e-s.top),void 0!==t&&void 0!==e?(this.horizontalOffset=i,this.verticalOffset=r,this.diagram.setOffset(i,r)):this.diagram.setOffset(-this.horizontalOffset-s.x,-this.verticalOffset-s.y),this.transform={tx:Math.max(this.horizontalOffset,-s.left)/this.currentZoom,ty:Math.max(this.verticalOffset,-s.top)/this.currentZoom,scale:this.currentZoom}},n.prototype.setScrollOffset=function(t,e){this.scrolled=!1;var i=this.getBounds();i.x*=this.currentZoom,i.y*=this.currentZoom,i.width*=this.currentZoom,i.height*=this.currentZoom;var r=-i.left,s=-i.top,o=!1,a=this.viewPortWidth*this.currentZoom,l=this.viewPortHeight*this.currentZoom,h=r-t;if(h!==this.horizontalOffset){rh?this.horizontalOffset-=t:this.horizontalOffset=h,o=!0);var c=Math.max(i.right+this.vScrollSize,a);if(!o&&c<-h+this.viewPortWidth){var d=-h+a-this.vScrollSize,u=-this.horizontalOffset+a-this.vScrollSize;this.horizontalOffset=dd-u?h:-(i.right+this.vScrollSize-a),o=!0}o||(this.horizontalOffset=r-t)}o=!1;var f=s-e;if(f!==this.verticalOffset){sf?this.verticalOffset-=e:this.verticalOffset=f,o=!0);var p=Math.max(i.bottom+this.hScrollSize,l);if(!o&&p<-f+l){var g=-f+l-this.hScrollSize,v=-this.verticalOffset+l-this.hScrollSize;this.verticalOffset=gg-v?f:-(i.bottom+this.hScrollSize-l),o=!0}o||(this.verticalOffset=s-e)}this.transform={tx:Math.max(this.horizontalOffset,-i.left)/this.currentZoom,ty:Math.max(this.verticalOffset,-i.top)/this.currentZoom,scale:this.currentZoom},this.setSize()},n.prototype.getObjects=function(t,e){for(var i=[],r=0;r0){for(var l=0;l0){h.push(i[parseInt(o.toString(),10)].id);for(var d=0;d=e.bottom&&(l=0),-this.horizontalOffset<=e.x&&-this.horizontalOffset+this.viewPortWidth>=e.right&&(a=0),this.hScrollSize=a,this.vScrollSize=l;var h=this.diagramWidth,c=this.diagramHeight;this.diagramWidth=Math.max(e.right,-this.horizontalOffset+this.viewPortWidth-l)-i,this.diagramHeight=Math.max(e.bottom,-this.verticalOffset+this.viewPortHeight-a)-r,(h!==this.diagramWidth||c!==this.diagramHeight)&&"Diagram"!==this.diagram.scrollSettings.scrollLimit&&this.diagram.setSize(this.diagramWidth,this.diagramHeight),"Diagram"===this.diagram.scrollSettings.scrollLimit&&(h===this.diagramWidth&&c===this.diagramHeight&&1===this.currentZoom||this.diagram.diagramActions&&t&&(!this.diagram.diagramActions||!t||0===this.verticalOffset&&this.verticalOffset!==t.y||0===this.horizontalOffset&&this.horizontalOffset!==t.x)?t&&h===this.diagramWidth&&c===this.diagramHeight&&(this.diagram.diagramCanvas.scrollHeight>this.viewPortHeight&&t.y<0&&this.horizontalOffset===t.x&&0===this.verticalOffset||this.diagram.diagramCanvas.scrollWidth>this.viewPortWidth&&t.x<0&&this.verticalOffset===t.y&&0===this.horizontalOffset)&&(this.verticalOffset=t.y,this.horizontalOffset=t.x,this.transform={tx:Math.max(t.x,-e.left)/this.currentZoom,ty:Math.max(t.y,-e.top)/this.currentZoom,scale:this.currentZoom}):(this.diagram.scrollActions&da.Interaction&&t&&(this.transform={tx:Math.max(t.x,-e.left/this.currentZoom)/this.currentZoom,ty:Math.max(t.y,-e.top/this.currentZoom)/this.currentZoom,scale:this.currentZoom},this.horizontalOffset=t.x,this.verticalOffset=t.y),this.diagram.setSize(this.diagramWidth,this.diagramHeight),!(this.diagram.scrollActions&da.PropertyChange)&&t&&(this.horizontalOffset=t.x,this.verticalOffset=t.y,this.transform={tx:Math.max(t.x,-e.left)/this.currentZoom,ty:Math.max(t.y,-e.top)/this.currentZoom,scale:this.currentZoom}))),this.diagram.transformLayers(),this.diagram.element.style.overflow="hidden"},n.prototype.setViewPortSize=function(t,e){this.viewPortWidth=t,this.viewPortHeight=e},n.prototype.getPageBounds=function(t,e,i,r){var o,s=new Ne;if("Content"===e||r||null===this.diagram.pageSettings.width||null===this.diagram.pageSettings.height){var u=t?void 0:0;o=this.diagram.spatialSearch.getPageBounds(u,u)}else{var a=this.diagram.pageSettings.width,l=this.diagram.pageSettings.height,h=0,c=0;if(this.diagram.pageSettings.multiplePage){if((s=this.diagram.spatialSearch.getPageBounds(0,0)).right>a&&(a*=d=Math.ceil(s.right/a)),s.bottom>l&&(l*=d=Math.ceil(s.bottom/l)),s.left<0&&Math.abs(s.left)>h){var d=Math.ceil(Math.abs(s.left)/this.diagram.pageSettings.width);h=this.diagram.pageSettings.width*d}s.top<0&&Math.abs(s.top)>c&&(d=Math.ceil(Math.abs(s.top)/this.diagram.pageSettings.height),c=this.diagram.pageSettings.height*d)}o=new Ne(-h,-c,a+h,l+c)}if(i){var f=this.diagram.scrollSettings.padding;o.x-=f.left,o.y-=f.top,o.width+=f.left+f.right,o.height+=f.top+f.bottom}return o},n.prototype.getPageBreak=function(t){for(var e=0,i=0,r=-1,s=[],c=this.diagram.pageSettings.margin.left,d=this.diagram.pageSettings.margin.right,u=this.diagram.pageSettings.margin.top,f=this.diagram.pageSettings.margin.bottom,p=1,g=1;t.width>e;)(e+=this.diagram.pageSettings.width?this.diagram.pageSettings.width:t.width)===this.diagram.pageSettings.width&&(s[++r]={x1:t.left+c,y1:t.top+u,x2:t.left+c,y2:t.bottom-f}),ei;)(i+=this.diagram.pageSettings.height?this.diagram.pageSettings.height:t.height)===this.diagram.pageSettings.height&&(s[++r]={x1:t.left+c,y1:t.top+u,x2:t.right-d,y2:t.top+u}),i=this.diagram.scrollSettings.minZoom||l||t>=1)){this.currentZoom*=t;var c=this.getPageBounds(void 0,void 0,!0);c.x*=this.currentZoom,c.y*=this.currentZoom;var d=Bi();Xf(d,t,t,r.x,r.y),r3(d,e||0,i||0),Mx(h,d);var u=Ke(h,{x:0,y:0});if(1===t&&(u=this.applyScrollLimit(u.x,u.y,s,o,a)),a=-c.y>=u.y&&-c.x>=u.x&&a,(this.diagram.scrollActions&da.PropertyChange||!(this.diagram.scrollActions&da.Interaction)||"Diagram"!==this.diagram.scrollSettings.scrollLimit||a)&&(this.transform={tx:Math.max(u.x,-c.left)/this.currentZoom,ty:Math.max(u.y,-c.top)/this.currentZoom,scale:this.currentZoom},this.horizontalOffset=u.x,this.verticalOffset=u.y),this.setSize(u),"SVG"!==this.diagram.mode&&Ds(this.diagram)&&this.diagram.scroller.virtualizeElements(),"SVG"!==this.diagram.mode&&!Ds(this.diagram)&&this.diagram.refreshDiagramLayer(),this.diagram.setOffset(-this.horizontalOffset-c.x,-this.verticalOffset-c.y),tb(this.diagram),this.diagram.views&&this.diagram.views.overview){var f=this.diagram.views.overview,p=f.scrollOverviewRect(f.parent.scroller.horizontalOffset,f.parent.scroller.verticalOffset,f.parent.scroller.currentZoom,!0);f.updateOverviewrect(-p.x,-p.y,p.width,p.height),f.updateView(f)}}}},n.prototype.fitToPage=function(t){var e=(t=t||{}).mode,i=t.region,r=t.margin||{},s=t.canZoomIn,o=t.customBounds,a=t.canZoomOut;r.bottom=r.bottom||25,r.top=r.top||25,r.left=r.left||25,r.right=r.right||25;var h,l=o,c=-this.horizontalOffset,d=-this.verticalOffset;if("PageSettings"===(i=i||"PageSettings")&&this.diagram.pageSettings.width&&this.diagram.pageSettings.height||this.diagram.nodes.length>0||this.diagram.connectors.length>0){e=e||"Page","CustomBounds"!==i&&(l=this.getPageBounds(!0,i,!0));var u={x:0,y:0};r.left+r.right>this.viewPortWidth&&(this.viewPortWidth<=100?(r.left=5,r.right=5):(r.left=25,r.right=25)),r.top+r.bottom>this.viewPortHeight&&(this.viewPortHeight<=100?(r.top=5,r.bottom=5):(r.top=25,r.bottom=25)),u.x=(this.viewPortWidth-(r.left+r.right))/l.width,u.y=(this.viewPortHeight-(r.top+r.bottom))/l.height,!s&&l.width-this.horizontalOffset-a+this.viewPortWidth&&(i=o.right-this.viewPortWidth,i+=20),o.x<-a&&(i=o.x),o.bottom>-l+this.viewPortHeight&&(r=o.bottom-this.viewPortHeight,r+=20),o.y<-l&&(r=o.y),this.zoom(1,-this.horizontalOffset-i,-this.verticalOffset-r,null,void 0,e))},n.prototype.bringToCenter=function(t){var e=this.currentZoom,i=new Ne(t.x*e,t.y*e,t.width*e,t.height*e),r=i.x+i.width/2-this.viewPortWidth/2,s=i.y+i.height/2-this.viewPortHeight/2;this.zoom(1,-this.horizontalOffset-(r*=-1),-this.verticalOffset-(s*=-1),null)},n.prototype.applyScrollLimit=function(t,e,i,r,s){if("Infinity"===this.diagram.scrollSettings.scrollLimit&&void 0===i&&!r&&(t=-t,e=-e),"Infinity"!==this.diagram.scrollSettings.scrollLimit){var o=void 0;if("Limited"===this.diagram.scrollSettings.scrollLimit){var a=this.diagram.scrollSettings.scrollableArea;o=new Ne(a.x,a.y,a.width,a.height)}(o=o||(s?this.getPageBounds():this.getPageBounds(!0))).x*=this.currentZoom,o.y*=this.currentZoom,o.width*=this.currentZoom,o.height*=this.currentZoom,void 0!==i&&(t*=-1,e*=-1),r&&(t*=-1,e*=-1);var l=Math.max(o.right,this.viewPortWidth);if(!r&&!(t<=o.x&&(t+this.viewPortWidth>=o.right||t>=o.right-this.viewPortWidth)||t>=o.x&&t+this.viewPortWidth<=l))if(t>=o.x)t=Math.max(o.x,Math.min(t,t-(t+this.viewPortWidth-this.vScrollSize-l)));else{var h=o.right-this.viewPortWidth;t=Math.min(h,o.x)}var c=Math.max(o.bottom,this.viewPortHeight);r||e<=o.y&&e+this.viewPortHeight>=o.bottom||e>=o.y&&e+this.viewPortHeight<=c||(e>=o.y?e=Math.max(o.y,Math.min(e,e-(e+this.viewPortHeight-this.hScrollSize-c))):(h=o.bottom-this.viewPortHeight,e=Math.min(o.y,h))),t*=-1,e*=-1}return{x:t,y:e}},n}(),tae=function(){function n(t,e,i,r,s){this.objects=[],this.left=t,this.top=e,this.width=i,this.height=r,this.spatialSearch=s}return n.prototype.findQuads=function(t,e){null!=this.first&&this.first.isIntersect(t)&&this.first.findQuads(t,e),null!=this.second&&this.second.isIntersect(t)&&this.second.findQuads(t,e),null!=this.third&&this.third.isIntersect(t)&&this.third.findQuads(t,e),null!=this.fourth&&this.fourth.isIntersect(t)&&this.fourth.findQuads(t,e),this.objects.length>0&&e.push(this)},n.prototype.isIntersect=function(t){return!(this.left+this.widtht.right||this.top>t.bottom)},n.prototype.selectQuad=function(){for(var i,t=null,e=this;null!=e;)i=e.getQuad(t),e=i.source,t=i.target||t;return t},n.prototype.getQuad=function(t){var e=this.width/2,i=this.height/2;if(e>=1e3&&i>=1e3){var r=this.left+e,s=this.top+i;if(this.spatialSearch.childRight<=r){if(this.spatialSearch.childBottom<=s)return this.first||((o=new n(this.left,this.top,e,i,this.spatialSearch)).parent=this,this.first=o),{source:this.first};if(this.spatialSearch.childTop>=s)return this.third||((o=new n(this.left,s,e,i,this.spatialSearch)).parent=this,this.third=o),{source:this.third}}else if(this.spatialSearch.childLeft>=r){if(this.spatialSearch.childBottom<=s)return this.second||((o=new n(r,this.top,e,i,this.spatialSearch)).parent=this,this.second=o),{source:this.second};var o;if(this.spatialSearch.childTop>=s)return this.fourth||((o=new n(r,s,e,i,this.spatialSearch)).parent=this,this.fourth=o),{source:this.fourth}}}return this.objects.push(this.spatialSearch.childNode),{target:this}},n.prototype.isContained=function(){return this.spatialSearch.childLeft>=this.left&&this.spatialSearch.childRight<=this.left+this.width&&this.spatialSearch.childTop>=this.top&&this.spatialSearch.childBottom<=this.top+this.height},n.prototype.addIntoAQuad=function(t){var e={};this.spatialSearch.setCurrentNode(t);for(var i=null;!e.isAdded;)i=(e=this.spatialSearch.parentQuad.add(i)).quad;return i},n.prototype.add=function(t){if(t=null,this.isContained())return{isAdded:!0,quad:t=this.selectQuad()};var e=void 0,i=!(0!==this.objects.length||this.first||this.second||this.third||this.fourth),r=2*this.width,s=2*this.height;return this.spatialSearch.childLeft=this.childLeft?(this.pageLeft=this.childLeft,this.leftElement=t,r=!0):t===this.leftElement&&(this.pageLeft=Number.MAX_VALUE,this.findLeft(this.parentQuad),r=!0)),(this.pageTop!==this.childTop||t!==this.topElement)&&(this.pageTop>=this.childTop?(this.pageTop=this.childTop,this.topElement=t,r=!0):t===this.topElement&&(this.pageTop=Number.MAX_VALUE,this.findTop(this.parentQuad),r=!0)),(this.pageBottom!==this.childBottom||t!==this.bottomElement)&&(this.pageBottom<=this.childBottom?(r=!0,this.pageBottom=this.childBottom,this.bottomElement=t):t===this.bottomElement&&(this.pageBottom=-Number.MAX_VALUE,this.findBottom(this.parentQuad),r=!0)),(this.pageRight!==this.childRight||t!==this.rightElement)&&(this.pageRight<=this.childRight?(this.pageRight=this.childRight,this.rightElement=t,r=!0):t===this.rightElement&&(this.pageRight=-Number.MAX_VALUE,this.findRight(this.parentQuad),r=!0)),r}return this.setCurrentNode(null),!1},n.prototype.isWithinPageBounds=function(t){return t.left>=this.pageLeft&&t.right<=this.pageRight&&t.top>=this.pageTop&&t.bottom<=this.pageBottom},n.prototype.findQuads=function(t){var e=[];return this.parentQuad.findQuads(t,e),e},n.prototype.findObjects=function(t){for(var i=[],r=0,s=this.findQuads(t);r=r.outerBounds.left&&(this.pageLeft=r.outerBounds.left,this.leftElement=r)}},n.prototype.findTop=function(t){t.first||t.second?(t.first&&this.findTop(t.first),t.second&&this.findTop(t.second)):(t.third&&this.findTop(t.third),t.fourth&&this.findTop(t.fourth));for(var e=0,i=t.objects;e=r.outerBounds.top&&(this.pageTop=r.outerBounds.top,this.topElement=r)}},n.prototype.setCurrentNode=function(t){if(this.childNode=t,t){var e=t.outerBounds;this.childLeft=Number(e.left),this.childTop=Number(e.top),this.childRight=Number(e.right),this.childBottom=Number(e.bottom)}else this.childLeft=Number.MAX_VALUE,this.childTop=Number.MAX_VALUE,this.childRight=-Number.MAX_VALUE,this.childBottom=-Number.MAX_VALUE},n.prototype.getPageBounds=function(t,e){if(this.pageLeft===Number.MAX_VALUE)return new Ne(0,0,0,0);var i=void 0!==t?Math.min(this.pageLeft,0):this.pageLeft,r=void 0!==e?Math.min(this.pageTop,0):this.pageTop;return new Ne(Math.round(i),Math.round(r),Math.round(this.pageRight-i),Math.round(this.pageBottom-r))},n.prototype.getQuad=function(t){return this.quadTable[t.id]},n}(),iae=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),nae=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return iae(t,n),function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);r>3&&s&&Object.defineProperty(t,e,s)}([I(!1)],t.prototype,"preventDefaults",void 0),t}(Ee),sae=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),o_=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},oae=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return sae(t,n),o_([I("")],t.prototype,"action",void 0),o_([I("")],t.prototype,"cursor",void 0),t}(Ee),a_=function(){function n(){this.size=20,this.intermediatePoints=[],this.gridCollection=[],this.startArray=[],this.targetGridCollection=[],this.sourceGridCollection=[],this.considerWalkable=[]}return n.prototype.lineRouting=function(t){var e=t.connectors.length;if(this.renderVirtualRegion(t),e>0)for(var i=0;i=t.right||e.right<=t.left||e.top>=t.bottom||e.bottom<=t.top)},n.prototype.findEndPoint=function(t,e,i){var r,s;if(e&&""!==t.sourcePortID&&t.sourcePortWrapper||!e&&""!==t.targetPortID&&t.targetPortWrapper){s=zo(r=e?{x:t.sourcePortWrapper.offsetX,y:t.sourcePortWrapper.offsetY}:{x:t.targetPortWrapper.offsetX,y:t.targetPortWrapper.offsetY},void 0,e?t.sourceWrapper.bounds:t.targetWrapper.bounds);var o=e?t.sourcePortWrapper.bounds:t.targetPortWrapper.bounds;r=i?"Top"===s?{x:o.topCenter.x,y:o.topCenter.y}:"Left"===s?{x:o.middleLeft.x,y:o.middleLeft.y}:"Right"===s?{x:o.middleRight.x,y:o.middleRight.y}:{x:o.bottomCenter.x,y:o.bottomCenter.y}:{x:o.center.x,y:o.center.y}}else r=e&&this.startNode||!e&&this.targetNode?e?{x:this.startNode.wrapper.offsetX,y:this.startNode.wrapper.offsetY}:{x:this.targetNode.wrapper.offsetX,y:this.targetNode.wrapper.offsetY}:e?{x:t.sourcePoint.x,y:t.sourcePoint.y}:{x:t.targetPoint.x,y:t.targetPoint.y};return r},n.prototype.refreshConnectorSegments=function(t,e,i,r){var h,c,f,p,g,y,S,b,M,w,C,s=e.sourceID,o=e.targetID,a=e.sourcePortID,l=e.targetPortID;if(function Jre(n,t){var e=0;return n.constraints&qe.LineRouting?e=n.constraints&qe.LineRouting:n.constraints&qe.InheritLineRouting&&(e=t.constraints&nt.LineRouting),e}(e,t)||r){this.startNode=t.nameTable[""+s],this.targetNode=t.nameTable[""+o],this.intermediatePoints=[],this.startArray=[],this.targetGridCollection=[],this.sourceGridCollection=[],this.startGrid=void 0,this.targetGrid=void 0;for(var D=0;D0;){var L=this.startArray.pop();if(L){for(D=0;D1&&(e.segments=[]),this.updateConnectorSegments(t,this.intermediatePoints,this.gridCollection,e,i)){this.considerWalkable=[];break e}this.targetGridCollection.splice(this.targetGridCollection.indexOf(O),1),L=this.startArray.pop()}}L&&this.findPath(L)}}}},n.prototype.checkChildNodes=function(t,e){var i=!1,r=!1;if(t.nodeId.length>=1&&!e)for(var s=0;s1&&this.targetGridCollection[0].nodeId.length>1)for(var c=0;c<=1;c++){for(var d=this.targetGridCollection[parseInt(c.toString(),10)].gridX,u=this.targetGridCollection[parseInt(c.toString(),10)].gridY,f=this.targetGridCollection[parseInt(c.toString(),10)].nodeId,p=void 0,g=0;g=e.right&&t.top<=e.top&&t.bottom>=e.bottom},n.prototype.getEndvalue=function(t,e){return this.gridCollection[t.gridX][t.gridY].walkable?t:"left"===e?this.getEndvalue(this.gridCollection[t.gridX-1][t.gridY],e):"right"===e?this.getEndvalue(this.gridCollection[t.gridX+1][t.gridY],e):"top"===e?this.getEndvalue(this.gridCollection[t.gridX][t.gridY-1],e):"bottom"===e?this.getEndvalue(this.gridCollection[t.gridX][t.gridY+1],e):t},n.prototype.changeValue=function(t,e,i){t.walkable||this.considerWalkable.push(t);for(var r,s=0;s<=e;s++)"left"===i?r=this.gridCollection[t.gridX-s][t.gridY]:"right"===i?r=this.gridCollection[t.gridX+s][t.gridY]:"top"===i?r=this.gridCollection[t.gridX][t.gridY-s]:"bottom"===i&&(r=this.gridCollection[t.gridX][t.gridY+s]),r.walkable||this.considerWalkable.push(r)},n.prototype.getIntermediatePoints=function(t){var e;for(this.intermediatePoints=[];t;)this.intermediatePoints.push({x:t.gridX,y:t.gridY}),t=t.parent;this.intermediatePoints.reverse(),this.intermediatePoints.length>=1&&void 0!==this.intermediatePoints[0]&&void 0!==this.intermediatePoints[1]&&(this.intermediatePoints[0].x===this.intermediatePoints[1].x?this.intermediatePoints[0].yi.y&&o.y>s.y){for(var a=i.xi.x&&o.x>s.x)){for(var u=i.y=1&&u.length>1&&(g=u[u.length-2].x!==u[u.length-1].x?u[u.length-2].x>u[u.length-1].x?"Left":"Right":u[u.length-2].y>u[u.length-1].y?"Top":"Bottom"),M>=2&&v===g&&u.length>1&&u.splice(u.length-2,1),v=g);if(u&&u.length>1){for(var w=0;wD.x?S.bounds.middleLeft:S.bounds.middleRight),w===u.length-2&&""===r.targetPortID&&y&&(l=C.x>D.x?y.bounds.middleRight:y.bounds.middleLeft),0===w&&b&&(C.x=b.x,C.y=D.y=b.y,b=qa(r,0,b,Ol(S.bounds,_n(C.x>D.x?"Left":"Right")),!1),C.x=b.x),w===u.length-2&&l&&(w>0&&r.targetDecorator&&l.x-D.x<0&&Math.abs(l.x-C.x)0&&r.targetDecorator&&l.x-D.x>0&&Math.abs(l.x-C.x)D.y?S.bounds.topCenter:S.bounds.bottomCenter),w===u.length-2&&""===r.targetPortID&&y&&(l=C.y>D.y?y.bounds.bottomCenter:y.bounds.topCenter),0===w&&b&&(C.y=b.y,C.x=D.x=b.x,b=qa(r,0,b,Ol(S.bounds,_n(C.y>D.y?"Top":"Bottom")),!1),C.y=b.y),w===u.length-2&&l&&(w>0&&r.targetDecorator&&l.y-D.y<0&&Math.abs(l.y-C.y)0&&r.targetDecorator&&l.y-D.y>0&&Math.abs(l.y-C.y)D.x?(f="Left",p=C.x-D.x):(f="Right",p=D.x-C.x):C.y>D.y?(f="Top",p=C.y-D.y):(f="Bottom",p=D.y-C.y),o.push({type:"Orthogonal",length:p,direction:f})}}if(o&&o.length>0){var L=o[o.length-1];if(1===o.length&&(L.length-=20),L.length<10&&2===o.length&&(o.pop(),o.length>0&&(o[0].length-=20,L=o[0])),r.targetDecorator&&("Top"===L.direction||"Bottom"===L.direction)&&L.length>r.targetDecorator.height+1||("Right"===L.direction||"Left"===L.direction)&&L.length>r.targetDecorator.width+1)return r.segments=o,s&&t.connectorPropertyChange(r,{},{type:"Orthogonal",segments:o}),!0}return!1},n.prototype.findPath=function(t){for(var e,i=[],r=this.findNearestNeigbours(t,this.gridCollection,!0),s=0;sl)&&(e.x!==t.gridX||e.y!==t.gridY)&&(i.push(e),o.previousDistance=l,o.afterDistance=o.afterDistance||this.manhattan(Math.abs(e.x-this.targetGrid.gridX),Math.abs(e.y-this.targetGrid.gridY)),o.totalDistance=o.previousDistance+o.afterDistance,o.parent=t)}if(i.length>0)for(s=0;st?i*t+e:i*e+t},n.prototype.manhattan=function(t,e){return t+e},n.prototype.findNearestNeigbours=function(t,e,i){var r=[],s=t.parent;if(s){var o=(t.gridX-s.gridX)/Math.max(Math.abs(t.gridX-s.gridX),1),a=(t.gridY-s.gridY)/Math.max(Math.abs(t.gridY-s.gridY),1);0!==o?(this.isWalkable(t.gridX,t.gridY-1,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX][t.gridY-1])&&r.push(e[t.gridX][t.gridY-1]),this.isWalkable(t.gridX,t.gridY+1,!0)&&this.sourceGridCollection.indexOf(e[t.gridX][t.gridY+1])&&r.push(e[t.gridX][t.gridY+1]),this.isWalkable(t.gridX+o,t.gridY,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX+o][t.gridY])&&r.push(e[t.gridX+o][t.gridY])):0!==a&&(this.isWalkable(t.gridX-1,t.gridY,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX-1][t.gridY])&&r.push(e[t.gridX-1][t.gridY]),this.isWalkable(t.gridX+1,t.gridY,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX+1][t.gridY])&&r.push(e[t.gridX+1][t.gridY]),this.isWalkable(t.gridX,t.gridY+a,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX][t.gridY+a])&&r.push(e[t.gridX][t.gridY+a]))}else this.neigbour(t,"top",r,i),this.neigbour(t,"right",r,i),this.neigbour(t,"bottom",r,i),this.neigbour(t,"left",r,i);return r},n.prototype.neigbour=function(t,e,i,r){for(var o,s=1;s>0;){var a="top"===e||"bottom"===e?t.gridX:"left"===e?t.gridX-s:t.gridX+s,l="right"===e||"left"===e?t.gridY:"top"===e?t.gridY-s:t.gridY+s;if((o=this.gridCollection[parseInt(a.toString(),10)][parseInt(l.toString(),10)])&&(r&&-1===this.sourceGridCollection.indexOf(o)||!r&&-1===this.targetGridCollection.indexOf(o)))return i&&this.isWalkable(a,l)&&i.push(o),s;if(!(a>0&&l>0))break;s++}return null},n.prototype.resetGridColl=function(t,e,i){for(var s,r=1;r>0;){var o="top"===e||"bottom"===e?t.gridX:"left"===e?t.gridX-r:t.gridX+r,a="right"===e||"left"===e?t.gridY:"top"===e?t.gridY-r:t.gridY+r;if((s=this.gridCollection[parseInt(o.toString(),10)][parseInt(a.toString(),10)])&&(i&&-1===this.sourceGridCollection.indexOf(s)||!i&&-1===this.targetGridCollection.indexOf(s))){if(this.isWalkable(o,a))break;var l=this.gridCollection[parseInt(o.toString(),10)][parseInt(a.toString(),10)];this.considerWalkable.push(l)}if(!(o>0&&a>0))break;"top"===e||"left"===e?r--:r++}return null},n.prototype.isWalkable=function(t,e,i){if(t>=0&&t=0&&e0?1:-1,this.isWalkable(h,c-1)&&!this.isWalkable(h-a,c-1)||this.isWalkable(h,c+1)&&!this.isWalkable(h-a,c+1)))return{x:t,y:e};if(0!==l){if(l=l>0?1:-1,this.isWalkable(h-1,c)&&!this.isWalkable(h-1,c-l)||this.isWalkable(h+1,c)&&!this.isWalkable(h+1,c-l))return{x:t,y:e};if(this.findIntermediatePoints(h+1,c,h,c,s,o)||this.findIntermediatePoints(h-1,c,h,c,s,o))return{x:t,y:e}}return this.findIntermediatePoints(h+a,c+l,h,c,s,o)},n.prototype.destroy=function(){},n.prototype.getModuleName=function(){return"LineRouting"},n}(),aae=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),hae=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return aae(t,n),function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);r>3&&s&&Object.defineProperty(t,e,s)}([I(!0)],t.prototype,"inversedAlignment",void 0),t}(Ee),cae=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Oe=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},TT=function(n,t,e,i){return new(e||(e=Promise))(function(r,s){function o(h){try{l(i.next(h))}catch(c){s(c)}}function a(h){try{l(i.throw(h))}catch(c){s(c)}}function l(h){h.done?r(h.value):new e(function(c){c(h.value)}).then(o,a)}l((i=i.apply(n,t||[])).next())})},AT=function(n,t){var i,r,s,o,e={label:0,sent:function(){if(1&s[0])throw s[1];return s[1]},trys:[],ops:[]};return o={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function a(h){return function(c){return function l(h){if(i)throw new TypeError("Generator is already executing.");for(;e;)try{if(i=1,r&&(s=2&h[0]?r.return:h[0]?r.throw||((s=r.return)&&s.call(r),0):r.next)&&!(s=s.call(r,h[1])).done)return s;switch(r=0,s&&(h=[2&h[0],s.value]),h[0]){case 0:case 1:s=h;break;case 4:return e.label++,{value:h[1],done:!1};case 5:e.label++,r=h[1],h=[0];continue;case 7:h=e.ops.pop(),e.trys.pop();continue;default:if(!(s=(s=e.trys).length>0&&s[s.length-1])&&(6===h[0]||2===h[0])){e=0;continue}if(3===h[0]&&(!s||h[1]>s[0]&&h[1]0&&((!s.style||!s.style.fill)&&(o.style.fill="transparent"),(!s.style||!s.style.strokeColor)&&(o.style.strokeColor="transparent")),s.shape&&"UmlActivity"===s.shape.type&&nb(s,o),s.shape&&"SwimLane"===s.shape.type&&fF(s,o),r.nodeDefaults&&Ro(o,s,r.nodeDefaults),r.updateAnnotationText(o.annotations);if(e&&e.connectors)for(a=0;e&&e.connectors&&a0&&0===i.nodes.length)this.clearCollection(),a=!0;else{for(var g=0,v=Object.keys(e.nodes);g0&&0===i.connectors.length)this.clearCollection(!0),a=!0;else{for(var C=0,D=Object.keys(e.connectors);C0){this.renderSelector(!0);break}if(e.selectedItems.constraints){this.renderSelector(!0);break}break;case"snapSettings":this.updateSnapSettings(e);break;case"commandManager":this.initCommands();break;case"layout":o=!0;break;case"segmentThumbShape":this.updateSelector();break;case"dataSourceSettings":this.clear(),"None"===this.layout.type?a=!0:(this.initObjects(),o=!0);break;case"tooltip":l3(this);break;case"rulerSettings":this.updateRulerSettings(e);break;case"layers":this.updateLayer(e);break;case"scrollSettings":this.scrollActions|=da.PropertyChange,this.updateScrollSettings(e),this.scrollActions&=~da.PropertyChange,this.scrollSettings.horizontalOffset=-this.scroller.horizontalOffset||0,this.scrollSettings.verticalOffset=-this.scroller.verticalOffset||0;break;case"locale":e.locale!==i.locale&&(this.realActions|=$i.PreventDataInit,n.prototype.refresh.call(this),this.realActions&=~$i.PreventDataInit);break;case"contextMenuSettings":if(void 0!==e.contextMenuSettings.showCustomMenuOnly&&(this.contextMenuSettings.showCustomMenuOnly=e.contextMenuSettings.showCustomMenuOnly),void 0!==e.contextMenuSettings.show&&(this.contextMenuSettings.show=e.contextMenuSettings.show),e.contextMenuSettings.items){for(var A=e.contextMenuSettings.items,x=0,P=Object.keys(A);x0){for(var N=[],T=O.ports.length-1;T>=0;T--)"LineDistribution"===O.ports[parseInt(T.toString(),10)].id.split("_")[1]&&N.push(O.ports[parseInt(T.toString(),10)]);this.removePorts(O,N)}}for(T=0;T0)for(var ue=0,fe=Object.keys(e.nodes);ue0)for(var De=0,xe=Object.keys(e.connectors);De=0;o--)this.commandHandler.expandNode(r[parseInt(o.toString(),10)],this,0!==o);this.canLayout&&this.doLayout(),this.lineRoutingModule?this.connectors.sourceID!==this.connectors.targetID&&this.lineRoutingModule.lineRouting(this):this.constraints&nt.LineRouting&&console.warn('[WARNING] :: Module "LineRouting" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),this.validatePageSize(),this.renderPageBreaks(),this.diagramRenderer.renderSvgGridlines(this.snapSettings,Ud(this.element.id),this.scroller.transform,this.rulerSettings,this.hRuler,this.vRuler),this.commandHandler.initSelectorWrapper(),this.notify("initial-load",{}),this.trigger("load"),this.scroller.setSize(),this.scroller.updateScrollOffsets(),this.isRefreshed||this.refreshDiagramLayer(),(this.scrollSettings.verticalOffset>0||this.scrollSettings.horizontalOffset>0)&&this.updateScrollOffset(),X.isDevice&&(this.tool=ri.ZoomPan|ri.SingleSelect),this.notify("initial-end",{}),this.isProtectedOnChange=!1,this.tooltipObject=l3(this),this.diagramActions=ee.Render,this.initCommands();var a=document.getElementsByClassName(this.element.id+"_hiddenUserHandleTemplate");(function Noe(n,t,e,i){var r,s,o,a,l,d=document.getElementById(i).ej2_instances[0];if(n&&t){r=GF(n);for(var u=0,f=e.userHandles;u0;)e[0].parentNode.removeChild(e[0]);var i=document.getElementById(this.element.id+"content");i&&this.element.removeChild(i);var r="measureElement";if(window[""+r]){window[""+r].usageCount-=1;var s="measureElementCount";window[""+s]--,0===window[""+s]&&(window[""+r].parentNode.removeChild(window[""+r]),window[""+r]=null)}}window.domTable={};for(var a=0;a1&&(this.callBlazorModel=!1,this.insertBlazorDiagramObjects(this.selectedItems),this.commandHandler.group(),this.callBlazorModel=!0,this.commandHandler.getBlazorOldValues())},t.prototype.unGroup=function(){this.callBlazorModel=!1,this.insertBlazorDiagramObjects(this.selectedItems),this.commandHandler.unGroup(),this.callBlazorModel=!0,this.commandHandler.getBlazorOldValues()},t.prototype.sendToBack=function(){this.commandHandler.sendToBack()},t.prototype.setActiveLayer=function(e){var i=this.commandHandler.getLayer(e);this.activeLayer=i},t.prototype.addLayer=function(e,i){this.commandHandler.addLayer(e,i)},t.prototype.removeLayer=function(e){this.commandHandler.removeLayer(e,ce())},t.prototype.moveObjects=function(e,i){$(this.layers),this.enableServerDataBinding(!1),this.commandHandler.moveObjects(e,i)},t.prototype.layerObjectUpdate=function(){},t.prototype.sendLayerBackward=function(e){this.layerObjectUpdate(),this.commandHandler.sendLayerBackward(e)},t.prototype.bringLayerForward=function(e){this.layerObjectUpdate(),this.commandHandler.bringLayerForward(e)},t.prototype.cloneLayer=function(e){this.commandHandler.cloneLayer(e)},t.prototype.bringToFront=function(){this.commandHandler.bringToFront()},t.prototype.moveForward=function(){this.commandHandler.sendForward()},t.prototype.sendBackward=function(){this.commandHandler.sendBackward()},t.prototype.getObject=function(e){return this.nameTable[""+e]},t.prototype.getNodeObject=function(e){return $(this.nameTable[""+e])},t.prototype.getConnectorObject=function(e){return $(this.nameTable[""+e])},t.prototype.getActiveLayer=function(){return this.activeLayer},t.prototype.nudgeCommand=function(e,i,r){if("object"!=typeof e&&(this.selectedItems.nodes.length||this.selectedItems.connectors.length)>0){var s=void 0;i.type&&"KEYDOWN"===i.type&&(s=i.type),this.nudge(e,void 0,void 0,s)}},t.prototype.nudge=function(e,i,r,s){var o=0,a=0;"Left"===e||"Right"===e?o=("Left"===e?-1:1)*(i||1):a=("Up"===e?-1:1)*(r||1),"KEYDOWN"===s&&(o*=5,a*=5);var h=this.selectedItems,c=this.selectedItems.wrapper.children[0];if(c instanceof ai)this.commandHandler.labelDrag(h.nodes[0],c,o,a);else{var d=$(this.selectedItems);this.protectPropertyChange(!0),this.drag(h,o,a),this.protectPropertyChange(!1);var u={type:"PositionChanged",redoObject:$(this.selectedItems),undoObject:d,category:"Internal"};this.addHistoryEntry(u)}this.refreshCanvasLayers()},t.prototype.insertBlazorDiagramObjects=function(e){},t.prototype.drag=function(e,i,r){if(this.insertBlazorDiagramObjects(e),!(this.bpmnModule&&e instanceof te&&this.bpmnModule.updateAnnotationDrag(e,this,i,r))){if(e instanceof ei){if(this.preventConnectorsUpdate=!0,e.nodes&&e.nodes.length){for(var o=0,a=e.nodes;o0&&o.nodes[0].children){this.fromUndo||(this.rotateUsingButton=!0);for(var h=this.commandHandler.getAllDescendants(o.nodes[0],[]),c=0;c0&&o.nodes[0].children){var g={type:"RotationChanged",redoObject:$(e),undoObject:$(o),category:"Internal",childTable:a};this.commandHandler.addHistoryEntry(g),this.commandHandler.updateSelector()}return u},t.prototype.dragSourceEnd=function(e,i,r){this.insertBlazorDiagramObjects(e),this.commandHandler.dragSourceEnd(e,i,r),this.callBlazorModel&&this.commandHandler.getBlazorOldValues()},t.prototype.dragTargetEnd=function(e,i,r){this.insertBlazorDiagramObjects(e),this.commandHandler.dragTargetEnd(e,i,r),this.callBlazorModel&&this.commandHandler.getBlazorOldValues()},t.prototype.findObjectsUnderMouse=function(e,i){return this.eventHandler.findObjectsUnderMouse(e,i)},t.prototype.findObjectUnderMouse=function(e,i,r){return this.eventHandler.findObjectUnderMouse(e,i,r)},t.prototype.findTargetObjectUnderMouse=function(e,i,r,s,o){return this.eventHandler.findTargetUnderMouse(e,i,r,s,o)},t.prototype.findElementUnderMouse=function(e,i,r,s){return this.eventHandler.findElementUnderMouse(e,i,r,s)},t.prototype.findActionToBeDone=function(e,i,r,s){return this.eventHandler.findActionToBeDone(e,i,r,s)},t.prototype.updateConnectorPort=function(e){if(e.ports.length)for(var i=void 0,r=0,s=e.ports;r=0;s--)if(i.push(r[parseInt(s.toString(),10)]),i.length>this.historyManager.stackLimit)return i}else i=r;return i},t.prototype.getEdges=function(e){return e.outEdge?this.nameTable[e.id].outEdges:this.nameTable[e.id].inEdges},t.prototype.getParentId=function(e){return this.nameTable[""+e].parentId},t.prototype.addConnector=function(e){return this.add(e)},t.prototype.UpdateBlazorDiagramModelCollection=function(e,i,r,s){},t.prototype.UpdateBlazorDiagramModel=function(e,i,r,s){},t.prototype.UpdateBlazorLabelOrPortObjects=function(e,i,r,s){},t.prototype.addBlazorDiagramObjects=function(){},t.prototype.removeNodeEdges=function(e,i,r){var s=this.nameTable[""+e],o=r?s.outEdges:s.inEdges;if(o.length>0)for(var a=0;a0)){for(var c=0;c0))}this.removePortEdges(l,a.element.sourcePortID,a.element.id,h)}a.element.targetID&&this.removeNodeEdges(a.element.targetID,a.element.id,!1)}}this.diagramActions=this.diagramActions|ee.PublicMethod,e.id=e.id||Qe();var u=this.activeLayer;if(!a.cancel&&u&&!u.lock){if(u.objects.indexOf(e.id)<0&&!u.lock&&(u.visible||(u.visible=!0,this.dataBind()),u.objects.push(e.id)),ps(e)===de)(r=new de(this,"connectors",e,!0)).status="New",this.nameTable[r.targetID]&&"TextAnnotation"===this.nameTable[r.targetID].shape.shape&&(r.isBpmnAnnotationConnector=!0,r.constraints=r.constraints&~qe.Delete),Ro(r,e,this.connectorDefaults),this.connectors.push(r),this.initObject(r),!1===e.visible&&this.updateElementVisibility(r.wrapper,r,e.visible),this.updateEdges(r),this.insertBlazorConnector(r);else{if(Ro(r=new te(this,"nodes",e,!0),e,this.nodeDefaults),r.parentId=e.parentId?e.parentId:r.parentId,r.umlIndex=e.umlIndex,r.status="New",(o="TextAnnotation"===r.shape.shape)&&!e.isTextAnnotationCopied&&(r.inEdges=e.inEdges?e.inEdges:r.inEdges),this.nodes.push(r),this.initObject(r,u,void 0,i),o&&this.bpmnModule)for(c=0;c-1&&e.parentId&&this.nameTable[e.parentId]&&"UmlClassifier"===this.nameTable[e.parentId].shape.type){var g=this.nameTable[e.parentId];g.children.splice(r.umlIndex,0,r.id),g.wrapper.children.splice(r.umlIndex,0,r.wrapper),g.wrapper.measure(new me),g.wrapper.arrange(g.wrapper.desiredSize),this.updateDiagramObject(g)}}if(a={element:r,cause:this.diagramActions,diagramAction:this.getDiagramAction(this.diagramActions),state:"Changed",type:"Addition",cancel:!1},this.parentObject&&(a.parentId=this.parentObject.id),"helper"!==e.id&&!(this.diagramActions&ee.PreventCollectionChangeOnDragOver)&&this.triggerEvent(Ce.collectionChange,a),!(this.diagramActions&ee.UndoRedo||this.diagramActions&ee.Group||this.diagramActions&ee.PreventHistory)){var v={type:"CollectionChanged",changeType:"Insert",undoObject:$(e),redoObject:$(e),category:"Internal"};this.addHistoryEntry(v)}this.parentObject=void 0,"SVG"===this.mode&&(this.updateSvgNodes(r),this.updateTextElementValue(r),this.updateDiagramObject(r),o&&this.updateDiagramObject(this.nameTable[r.inEdges[0]]),r.shape.activity&&r.shape.activity.subProcess.processes&&r.shape.activity.subProcess.processes.length&&this.updateProcesses(r),this.updateBridging())}}if(this.protectPropertyChange(s),this.resetDiagramActions(ee.PublicMethod),r&&this.layers.length>1&&this.moveNode(r),this.views)for(var S=0,b=this.views;S=0;l--)this.moveSvgNode(a[parseInt(l.toString(),10)])}for(var h=0,c=i;h=0;o--)r[parseInt(o.toString(),10)]===e.id&&r.splice(o,1);for(var a=0;s.ports&&a=0;s--)if(i=this.nameTable[r[parseInt(s.toString(),10)]])if(this.connectorTable[i.id]=$(i),i.isBpmnAnnotationConnector){var o=this.nameTable[i.targetID];this.removeObjectsFromLayer(i);var a=this.connectors.indexOf(i);-1!==a&&this.connectors.splice(a,1),this.removeElements(i),this.removeFromAQuad(i),delete this.nameTable[i.id];var l=this.nameTable[i.sourceID];if(l){var h=l.outEdges.indexOf(i.id);-1!==h&&l.outEdges.splice(h,1)}e.id!==i.targetID&&this.remove(o)}else this.remove(i)},t.prototype.removeObjectsFromLayer=function(e){if(e.children)for(var i=0;i-1&&(_r(this,e)&&this.unSelect(e),this.layers[parseInt(s.toString(),10)].objects.splice(a,1),delete this.layers[parseInt(s.toString(),10)].zIndexTable[this.nameTable[e.id].zIndex])},t.prototype.removeElements=function(e){if("SVG"===this.mode||"Canvas"===this.mode&&"Native"===e.shape.type){var i=xt(e.id+"_groupElement",this.element.id),r=e;if(r.ports&&r.ports.length>0)for(var s=0;s0){l[parseInt(s.toString(),10)].id.indexOf("icon_content")>0&&"SVG"===this.mode&&((h=xt(l[parseInt(s.toString(),10)].id+"_shape_groupElement",this.element.id))&&h.parentNode.removeChild(h),(h=xt(l[parseInt(s.toString(),10)].id+"_rect_groupElement",this.element.id))&&h.parentNode.removeChild(h));for(var c=0,d=this.views;c=0;o--)a.children[parseInt(o.toString(),10)].children&&(l=n.nameTable[a.children[parseInt(o.toString(),10)].id])&&(l.isLane?Jv(n,l):(n.removeDependentConnector(l),n.diagramActions|=ee.PreventHistory,l.constraints&ie.Delete?n.remove(l):q3(n,l,{},!1),n.diagramActions&=~ee.PreventHistory));a&&(i=n.nameTable[a.id])&&Jv(n,i)}}(this,e),!(this.diagramActions&ee.UndoRedo||this.diagramActions&ee.PreventHistory)&&(e instanceof te||e instanceof de)){var o={type:"CollectionChanged",changeType:"Remove",undoObject:$(e),redoObject:$(e),category:"Internal"};this.diagramActions&ee.Clear||e.children&&!e.isLane&&!e.isPhase&&e.children.length>0&&this.undoRedoModule&&"None"===this.layout.type&&(this.historyManager.startGroupAction(),s=!0),(e instanceof te||e instanceof de)&&this.deleteDependentConnector&&this.removeDependentConnector(e),!e.isLane&&!e.isPhase&&!(this.diagramActions&ee.Clear)&&!this.isStackChild(e)&&this.addHistoryEntry(o)}"TextAnnotation"===e.shape.shape&&this.removeDependentConnector(e),e.children&&!e.isLane&&!e.isPhase&&(!(this.diagramActions&ee.UndoRedo)||!ce())&&this.deleteGroup(e),e.parentId&&(this.deleteChild(e,void 0,!0),this.nameTable[e.parentId]&&"UmlClassifier"===this.nameTable[e.parentId].shape.type&&(this.updateDiagramObject(this.nameTable[e.parentId]),this.updateConnectorEdges(this.nameTable[e.parentId])));var a=void 0;this.diagramActions=this.diagramActions|ee.PublicMethod;var l=this.nameTable[e.id];if(l instanceof te?("Bpmn"===l.shape.type&&this.bpmnModule&&this.bpmnModule.removeBpmnProcesses(l,this),(l.isLane||l.isPhase||"SwimLane"===l.shape.type)&&(h=l.isLane||l.isPhase?this.nameTable[l.parentId]:this.nameTable[l.id],l.isLane?Q3(this,l,h):l.isPhase&&G3(this,l,h)),-1!==(a=this.nodes.indexOf(l))&&(this.crudDeleteNodes.push(this.nameTable[l.id]),this.nodes.splice(a,1),this.updateNodeEdges(l))):(-1!==(a=this.connectors.indexOf(l))&&(this.crudDeleteNodes.push(this.nameTable[l.id]),this.connectors.splice(a,1)),this.updateEdges(l),this.spliceConnectorEdges(e,!0),this.spliceConnectorEdges(e,!1)),!this.isServerUpdate&&!(this.blazorActions&on.GroupClipboardInProcess)&&this.commandHandler.getBlazorOldValues(),s&&this.historyManager.endGroupAction(),_r(this,l)&&this.unSelect(l),!l.isPhase){if(this.removeObjectsFromLayer(e),this.currentDrawingObject&&(this.currentDrawingObject.wrapper=void 0),delete this.nameTable[e.id],i.length>0&&i[0].id===l.id&&l.parentId){var h,d=this.nameTable[l.parentId];d&&d.isLane&&"SwimLane"===this.nameTable[d.parentId].shape.type&&Y3(this,h=this.nameTable[d.parentId],d,l)}this.removeElements(l),this.updateBridging(),"SVG"!==this.mode&&this.refreshDiagramLayer(),this.diagramActions&ee.Clear||(this.removeFromAQuad(l),r={element:e,cause:this.diagramActions,diagramAction:this.getDiagramAction(this.diagramActions),state:"Changed",type:"Removal",cancel:!1},"helper"!==e.id&&this.triggerEvent(Ce.collectionChange,r),this.resetTool())}}}else if(i.length>0){this.undoRedoModule&&(this.historyManager.startGroupAction(),this.blazorActions|=on.GroupingInProgress,s=!0);for(var u=0;u=p.wrapper.bounds.width&&"Horizontal"===p.shape.orientation||this.selectedItems.wrapper.bounds.y<=p.wrapper.bounds.y+g&&this.selectedItems.wrapper.bounds.height>=p.wrapper.bounds.height-g&&"Vertical"===p.shape.orientation)&&(PI(p)||p.shape.lanes.length>1)&&this.remove(i[parseInt(u.toString(),10)])}}else this.remove(i[parseInt(u.toString(),10)])}s&&(this.blazorActions&=~on.GroupingInProgress,this.isServerUpdate=!0,this.commandHandler.getBlazorOldValues(),this.UpdateBlazorDiagramModelCollection(void 0,void 0,void 0,!0),this.historyManager.endGroupAction(),this.isServerUpdate=!1),this.clearSelection()}e&&(PI(e)||this.diagramActions&ee.Clear)||this.diagramActions&ee.UndoRedo||this.diagramActions&ee.PreventHistory||!(e instanceof te||e instanceof de)||(o={type:"ConnectionChanged",undoObject:$(e),redoObject:$(e),category:"Internal"},!e.isLane&&!e.isPhase&&!(this.diagramActions&ee.Clear)&&!this.isStackChild(e)&&this.addHistoryEntry(o)),this.tooltipObject.close()},t.prototype.isStackChild=function(e){var i,r=this.nameTable[e.parentId];if(e&&e.parentId&&r.container&&"Stack"===r.container.type&&"UmlClassifier"!==this.nameTable[e.parentId].shape.type){i=!0;var s={sourceIndex:r.wrapper.children.indexOf(e.wrapper),source:e,target:void 0,targetIndex:void 0};this.diagramActions&ee.UndoRedo||this.addHistoryEntry({type:"StackChildPositionChanged",redoObject:{sourceIndex:void 0,source:e,target:void 0,targetIndex:void 0},undoObject:s,category:"Internal"})}return i},t.prototype.deleteChild=function(e,i,r){var s;if(s="string"==typeof e?e:e.id,(i=i?this.nameTable[i.id]:this.nameTable[e.parentId])&&i.children){for(var o=0;o=0;i--)this.removeLayer(this.layers[parseInt(i.toString(),10)].id);this.commandHandler.addLayer({id:"default_layer",visible:!0,lock:!1,objects:[],zIndex:0,objectZIndex:-1,zIndexTable:{}},null,!0),this.setActiveLayer(this.layers[this.layers.length-1].id)},t.prototype.clearObjects=function(e){var i=[];i=e||(i=i.concat(this.nodes)).concat(this.connectors),this.diagramActions=this.diagramActions|ee.Clear;for(var r=0,s=i;r0||"Text"===e.shape.type))if("Text"===e.shape.type)i=e.wrapper.children[0].id.split("_")[1];else for(var p=e.annotations.length-1;p>=0;p--)e.annotations[parseInt(p.toString(),10)].visibility&&(i=e.annotations[parseInt(p.toString(),10)].id);i&&(u=this.getWrapper(e.wrapper,i))}if(e&&u&&!(u instanceof es)&&(!function sne(n,t){return"Text"===t.shape.type?t.constraints&ie.ReadOnly:t.constraints&(t instanceof de?qe.ReadOnly:ie.ReadOnly)?n.constraints&Nr.InheritReadOnly?1:0:n.constraints&Nr.ReadOnly?1:0}(u,e)||f)){var g=u.style,v=void 0;v=90>(v=u.bounds.width50?50:e.width,u.style.fontSize)),e.parentId&&"UmlClassifier"===this.nameTable[e.parentId].shape.type?(l.width=e.wrapper.bounds.width-20,c=(e.wrapper.bounds.center.x+r.tx)*r.scale-l.width/2*s-2.5,d=(e.wrapper.bounds.center.y+r.ty)*r.scale-l.height/2*s-3,u.style.textAlign="Left"):(l.width=Math.max(l.width,50),c=(u.bounds.center.x+r.tx)*r.scale-l.width/2*s-2.5,d=(u.bounds.center.y+r.ty)*r.scale-l.height/2*s-3),Ho(y,{id:this.element.id+"_editTextBoxDiv",style:"position: absolute;left:"+c+"px;top:"+d+"px;width:"+(l.width+1)*s+"px;height:"+l.height*s+"px; containerName:"+e.id+";"}),Ho(S,{"aria-label":a,id:this.element.id+"_editBox",style:"width:"+(l.width+1)*s+"px;height:"+l.height*s+"px;resize: none;outline: none;overflow: hidden;;font-family:"+g.fontFamily+";font-size:"+g.fontSize*s+"px;text-align:"+u.style.textAlign.toLocaleLowerCase()+";",class:"e-diagram-text-edit"}),S.style.fontWeight=g.bold?"bold":"",S.style.fontStyle=g.italic?"italic":"",S.style.lineHeight=(1.2*g.fontSize+"px;").toString(),S.style.textDecoration=g.textDecoration?g.textDecoration:"",this.activeLabel.parentId=e.id,this.activeLabel.id=i,u.visible=!1,this.updateDiagramObject(e),this.diagramActions=this.diagramActions|ee.TextEdit,this.isTriggerEvent||(E.add(S,"input",this.eventHandler.inputChange,this.eventHandler),E.add(S,"focusout",this.focusOutEdit,this),S.select())}}}},t.prototype.updateConnectorfixedUserHandles=function(e){if(e.fixedUserHandles.length)for(var i=void 0,r=0,s=e.fixedUserHandles;r0&&this.mindMapChartModule.updateLayout(o,this.nameTable,this.layout,l,this.dataSourceSettings.id,this.dataSourceSettings.root),e=!0;else if(this.radialTreeModule)this.radialTreeModule.updateLayout(o,this.nameTable,this.layout,l),e=!0;else if(this.symmetricalLayoutModule)this.symmetricalLayoutModule.maxIteration=this.layout.maxIteration,this.symmetricalLayoutModule.springLength=this.layout.springLength,this.symmetricalLayoutModule.springFactor=this.layout.springFactor,this.symmetricalLayoutModule.updateLayout(o,this.connectors,this.symmetricalLayoutModule,this.nameTable,this.layout,l),e=!0;else if(this.complexHierarchicalTreeModule){this.canDistribute(a,r)&&(this.lineDistributionModule.diagram=this,this.connectors.forEach(function(P){P.obstaclePointCollection=[]}));var c=this.complexHierarchicalTreeModule.getLayoutNodesCollection(this.nodes);c.length>0&&this.complexHierarchicalTreeModule.doLayout(c,this.nameTable,this.layout,l,this),e=!0,this.canDistribute(a,r)&&this.lineDistributionModule.initLineDistribution(this.layout,this)}else this.flowchartLayoutModule?(this.flowchartLayoutModule.updateLayout(this.nodes,this),e=!0):console.warn("[WARNING] :: Module "+("OrganizationalChart"===this.layout.type?"HierarchicalTree":this.layout.type)+" is not available in Diagram component! You either misspelled the module name or forgot to load it.");if(e){this.preventDiagramUpdate=!0;for(var u={},p=0,g=o;p0)for(var S=0;S0)for(var M=0;M0)for(var s=0,o=r.ports;s0&&function Rse(n){var t,e,i,r=[];for(t=0;t0&&y.connectors[w].bezierSettings&&y.connectors[w].bezierSettings.allowSegmentsReset&&(y.connectors[w].segments=[]);if(t.connectors=y.connectors||[],t.dataSourceSettings=y.dataSourceSettings||{},t.dataSourceSettings.doBinding=i,t.height=y.height||"100%",t.setNodeTemplate=r,t.getConnectorDefaults=v,t.getNodeDefaults=g,t.getCustomProperty=o,t.mode=y.mode||"SVG",y.nodes)for(w=0;w0)){var r=this.nodes.filter(function(a){return 0===a.inEdges.length})[0],s=this.convertMindmapToMermaid(r,0);i.push(s),this.updateTextDataSource(i,r.outEdges,1),e=(i=i.filter(function(a){return""!==a.trim()})).join("\n")}return e},t.prototype.updateTextDataSource=function(e,i,r){for(var s=0;s0&&this.updateTextDataSource(e,h,r+1),s++}},t.prototype.convertMindmapToMermaid=function(e,i){var r=e.id,o=" ".repeat(2*(i+1)),a=e.annotations.length>0?e.annotations[0].content.replace(/\n/g," "):"",l=o+a,h=o+r;if(e.shape&&"Basic"===e.shape.type){var c=e.shape;"Rectangle"===c.shape?l=h+"["+a+"]":"Ellipse"===c.shape?l=h+"(("+a+"))":"Hexagon"===c.shape&&(l=h+"{{"+a+"}}")}else if(e.shape&&"Flow"===e.shape.type)"Terminator"===e.shape.shape&&(l=h+"("+a+")");else if(e.shape&&"Path"===e.shape.type){var u=e.shape;u.data===this.bangShape?l=h+"))"+a+"((":u.data===this.cloudShape&&(l=h+")"+a+"(")}return l},t.prototype.saveFlowDiagramInMermaidFormat=function(){var e=this,i=[],r="graph TD\n",s={nodes:this.nodes,edges:this.connectors};return s.nodes.reduce(function(a,l){return a[l.id]=l.annotations.length?l.annotations[0].content:"",a},{}),s.edges.forEach(function(a){var l=a.sourceID,h=a.targetID,f=e.nameTable[""+h],p=e.getNodeShape(e.nameTable[""+l]),g=e.getNodeShape(f),v=a.annotations[0]&&""!==a.annotations[0].content?"|"+a.annotations[0].content+"|":"";-1===i.indexOf(l)?i.push(l):p="",-1===i.indexOf(h)?i.push(h):g="";var y=e.arrowType(a);r+=" "+l+p+" "+y+v+" "+h+g+"\n"}),s.nodes.forEach(function(a){r+=" style "+a.id+" fill:"+a.style.fill+",stroke:"+a.style.strokeColor+",stroke-width:"+a.style.strokeWidth+"px;\n"}),r},t.prototype.arrowType=function(e){var i=e.targetDecorator.shape;return e.style.opacity<1?"~~~":""!==e.style.strokeDashArray?"-.->":"Arrow"===i?e.style.strokeWidth>1?"==>":"--\x3e":"None"===i?"---":"--\x3e"},t.prototype.getNodeShape=function(e){var i=e.annotations.length>0?e.annotations[0].content:"",r=e.shape.shape;if(!r){var s=e.shape.data;return"M 0 0 A 1 1 0 0 0 7 0 A 1 1 0 0 0 0 0 M -1 0 A 1 1 0 0 0 8 0 A 1 1 0 0 0 -1 0"===s?"((("+i+")))":"M 0 0 L 1 -1 L 5 -1 L 6 0 L 0 0"===s?"[/"+i+"\\]":"M 0 1 L 0 6 C 2 7 4 7 6 6 L 6 1 C 5 0 1 0 0 1 C 1 2 5 2 6 1"===s?"[("+i+")]":"M 0 0 L 12 0 L 14 2 L 2 2 L 0 0"===s?"[\\"+i+"\\]":"M 0 0 L 5 0 L 4 1 L 1 1 L 0 0"===s?"[\\"+i+"/]":"M 0 0 L 2 -2 L 11 -2 L 13 0 L 11 2 L 2 2 L 0 0"===s?"{{"+i+"}}":">"+i+"]"}switch(r){case"Terminator":return"(["+i+"])";case"Process":default:return"["+i+"]";case"Decision":return"{"+i+"}";case"Parallelogram":return"[/"+i+"/]";case"Ellipse":return"(("+i+"))";case"PreDefinedProcess":return"[["+i+"]]"}},t.prototype.loadDiagramFromMermaid=function(e){this.layout&&"Flowchart"===this.layout.type&&this.flowchartLayoutModule?this.convertMermaidToFlowChart(e):this.layout&&"MindMap"===this.layout.type&&this.mindMapChartModule?this.convertMermaidToMindmap(e):console.warn('[WARNING] :: Module "FlowchartLayout" or "MindMap" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.countLeadingSpaces=function(e){for(var i=0,r=e.length;i0});this.clear(),this.mermaidNodeBaseCollection=[];var r=[],s={text:"",children:[],currentLevel:0,branch:"Left"},o=[],l=!1,h=!1,c=!1;if(i.length>0){for(var d=function(M){var w=i[parseInt(M.toString(),10)],C=0,D="",A=u.countLeadingSpaces(w),x=w.includes('"`');if(h=w.includes('`"'),c=(l=!!x||l)||c?c:0===A&&M>0,l&&h&&!x)return s.text+="\n"+w,l=!1,"continue";if(!x&&l)return s.text+="\n"+w,"continue";if(l=!h&&l,w.length>0&&(/\s/.test(w[0])&&M>0||0===A)){if(-1!==o.findIndex(function(B){return B.space===A.toString()}))for(var L=o.length-1;L>=0;L--){var O=o[parseInt(L.toString(),10)];if((N=parseFloat(O.space))>A)o.splice(L,1);else{if(N=0;L--){var N,T=o[parseInt(L.toString(),10)];if(!((N=parseFloat(T.space))>A)){var z=o[o.length-1];o.push({space:A.toString(),level:z.level+1});break}o.splice(L,1)}C=o[o.length-1].level}D=w.trim().replace(/^[+-]/,"")}var U={text:D,branch:void 0,children:[],currentLevel:0===M?0:C-1};if(r.length>0){for(;r.length>=C&&0!==r.length;)r.pop();r.length>0&&r[r.length-1].children.push(U)}r.push(U),s=U},u=this,f=0;f0){var c=h[h.length-1];c.arrowType=a[2],""!==a[3]&&(c.label&&c.label.some(function(d){return d.trim().length>0})?c.label.push(a[3]):(c.label=[],c.label[c.parentId.length-1]=a[3]))}h.filter(function(d){return d.parentId&&0===d.parentId.length}).forEach(function(d){d.parentId=null}),i=i.concat(h)}}this.createFlowChart(i),this.doLayout(),this.clearHistory()},t.prototype.createFlowChart=function(e){for(var i=[],r=0;r1)for(var h=0;h|---|--\s*.*?\s*-->|~~~|==>|===|==\s*.*?\s*==>|\s*-\.\s*->|\s*-\.\s*-|\s*-\.\s*.*?\s*\.\s*->|\s*-\..*?\.\s*->)(.*)$/);if(l){i=l[1].trim();var h=l[2].trim();r=l[3].trim();var d=h.match(/(-\.|\\-\\-|==|--|~~)(.*?)(\1>|\.->|==>|\\->|~~>)/),u=void 0,f="";o=null!==(u=d?{text:d[2].trim()||null,arrowType:d[1]+d[3]}:{text:null,arrowType:h}).text?u.text:"",s=(f=u.arrowType).includes("--\x3e")?"single-line-arrow":f.includes("---")?"single-line":f.includes("==>")?"double-line-arrow":f.includes("==")?"double-line":f.includes("~~~")?"wiggly-arrow":f.includes("-.->")||f.includes(".->")?"dotted-arrow":f.includes("-.-")||f.includes(".-")?"dotted":"single-line-arrow"}return[i,r,s,o]},t.prototype.parseStyle=function(e,i){if(e.startsWith("style")){var s=e.match(/^style\s+(\w+)\s+fill:([^,]+),stroke:([^,]+),stroke-width:(\d+)px;/);if(s){var c={id:s[1],fill:s[2],stroke:s[3],strokeWidth:parseInt(s[4],10)},d=i.filter(function(u){return u.id===c.id});d[0].color=c.fill,d[0].stroke=c.stroke,d[0].strokeWidth=c.strokeWidth}}},t.prototype.getNodeData=function(e,i,r){for(var s=[],o=null,a=null,l=0,h="",c=function(v){var y=e[parseInt(v.toString(),10)],S=d.splitNested(y);if(S[0].includes("|")){var b=S[0].match(/\|([^|]*)\|/);b&&(h=b[1]);var M=S[0].split("|");M.length>=3&&(S[0]=M[2].trim())}var w=S[0].trim();if(0===v?o=w:a=w,i.find(function(L){return L.id===w}))l++;else{var D=S.length>1?S[1]:S[0],A=d.getShape(D),x=D.replace(/[\\[\]\\(\\)\\{\\}\\{\\}\\/>]/g,"");s.push({id:w,name:x,shape:A,color:"white",parentId:[]})}},d=this,u=0;u"===h?0===s?(r.trim().length>0&&i.push(r.trim()),r=h,o=h,s++):(r+=h,s++):"]"===h||"}"===h||")"===h?1===s&&h===o?(i.push((r+=h).trim()),r="",s--):s>1?(r+=h,s--):r+=h:r+=h}return r.trim().length>0&&i.push(r.trim()),i},t.prototype.getShape=function(e){var i={};return e.startsWith("(((")?i={type:"Path",data:"M 0 0 A 1 1 0 0 0 7 0 A 1 1 0 0 0 0 0 M -1 0 A 1 1 0 0 0 8 0 A 1 1 0 0 0 -1 0"}:e.startsWith("((")?i={shape:"Ellipse",type:"Basic"}:e.startsWith("([")?i={type:"Flow",shape:"Terminator"}:e.startsWith("(")?i={type:"Flow",shape:"Process"}:e.startsWith("[[")?i={type:"Flow",shape:"PreDefinedProcess"}:e.startsWith("[/")?i=e.endsWith("/]")?{type:"Basic",shape:"Parallelogram"}:{type:"Path",data:"M 0 0 L 1 -1 L 5 -1 L 6 0 L 0 0"}:e.startsWith("[(")?i={type:"Path",data:"M 0 1 L 0 6 C 2 7 4 7 6 6 L 6 1 C 5 0 1 0 0 1 C 1 2 5 2 6 1"}:e.startsWith("[\\")?i=e.endsWith("\\]")?{type:"Path",data:"M 0 0 L 12 0 L 14 2 L 2 2 L 0 0"}:{type:"Path",data:"M 0 0 L 5 0 L 4 1 L 1 1 L 0 0"}:e.startsWith("[")?i={type:"Basic",shape:"Rectangle"}:e.startsWith("{{")?i={type:"Path",data:"M 0 0 L 2 -2 L 11 -2 L 13 0 L 11 2 L 2 2 L 0 0"}:e.startsWith("{")?i={type:"Flow",shape:"Decision"}:e.startsWith(">")&&(i={type:"Path",data:"M 0 0 L 8 0 L 8 2 L 0 2 L 2 1 L 0 0"}),i},t.prototype.getDiagramContent=function(e){return this.printandExportModule?this.printandExportModule.getDiagramContent(e):(console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),"")},t.prototype.exportImage=function(e,i){this.printandExportModule?this.printandExportModule.exportImages(e,i):console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.printImage=function(e,i){this.printandExportModule?(i.printOptions=!0,this.printandExportModule.exportImages(e,i)):console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.setStackLimit=function(e){this.undoRedoModule&&e&&(this.historyManager.stackLimit=e,this.undoRedoModule.applyLimit(this.historyManager.currentEntry,e,this,!0))},t.prototype.clearHistory=function(){this.undoRedoModule&&this.undoRedoModule.clearHistory(this)},t.prototype.getDiagramBounds=function(){if(this.printandExportModule){var e=this.printandExportModule.getDiagramBounds("",{});return e.width=e.width>this.scrollSettings.viewPortWidth?e.width+(e.x>0?e.x:0):this.scrollSettings.viewPortWidth,e.height=e.height>this.scrollSettings.viewPortHeight?e.height+(e.y>0?e.y:0):this.scrollSettings.viewPortHeight,e.x=e.x>0?0:e.x,e.y=e.y>0?0:e.y,e}return console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),new Ne},t.prototype.exportDiagram=function(e){return this.printandExportModule?this.printandExportModule.exportDiagram(e):(console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),"")},t.prototype.print=function(e){this.printandExportModule?this.printandExportModule.print(e):console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.addPorts=function(e,i){var s;this.protectPropertyChange(!0),e=this.nameTable[e.id]||e,i.length>1&&this.startGroupAction();for(var o=function(h){if(e.ports.some(function(y){return y.id===i[parseInt(h.toString(),10)].id}))return"continue";if(e instanceof te?(s=new Es(e,"ports",i[parseInt(h.toString(),10)],!0),e.ports.push(s)):e instanceof de&&(s=new Lc(e,"ports",i[parseInt(h.toString(),10)],!0),e.ports.push(s)),e.children)for(var c=e.wrapper,d=0;d1&&this.endGroupAction(),e.wrapper.measure(new me(e.width,e.height)),e.wrapper.arrange(e.wrapper.desiredSize),this.updateDiagramObject(e),this.protectPropertyChange(!1)},t.prototype.addConstraints=function(e,i){return e|i},t.prototype.removeConstraints=function(e,i){return e&~i},t.prototype.addNodeLabels=function(e,i){this.addLabels(e,i)},t.prototype.addConnectorLabels=function(e,i){this.addLabels(e,i)},t.prototype.addLabels=function(e,i){this.protectPropertyChange(!0);var s,r=(e=this.nameTable[e.id]||e).wrapper;i.length>1&&this.startGroupAction();for(var o=0;o1&&this.endGroupAction(),e.wrapper.measure(new me(r.width,r.height)),e.wrapper.arrange(r.desiredSize),this.updateDiagramObject(e),this.protectPropertyChange(!1),this.refreshCanvasLayers()},t.prototype.addChildToUmlNode=function(e,i,r){var s,o,a,l,h="NoWrap";"Class"===e.shape.classifier||"Interface"===e.shape.classifier?"Method"===r?(o=new fm(e,"",i),"Class"===e.shape.classifier?(e.shape.classShape.methods.push(o),s=e.shape.classShape):"Interface"===e.shape.classifier&&(e.shape.interfaceShape.methods.push(o),s=e.shape.interfaceShape),function soe(n,t,e,i){if(e.methods&&e.methods.length){var r=e.methods,s="",o="",a=void 0,l=1,h=void 0,c=0,d=0,u=n.shape,g="Class"===u.classifier?u.classShape:u.interfaceShape;1===r.length?g.attributes.length>0?(c=g.attributes.filter(function(w){return w.isSeparator}).length,h=(l=2+g.attributes.length+c)+1,lT(n,t,l)):h=l+1:(c=g.attributes.filter(function(w){return w.isSeparator}).length,d=g.methods.filter(function(w){return w.isSeparator}).length,h=(l=2+g.attributes.length+c+g.methods.length+d)+1);for(var v=0;v1&&this.startGroupAction();for(var r=i.length-1;r>=0;r--)if(e.children&&e.children.length>0){var s=e.wrapper.children.filter(function(o){return o.id===e.id+"group_container"});s&&s.length>0&&this.removelabelExtension(e,i,r,s[0])}else this.removelabelExtension(e,i,r,e.wrapper);i.length>1&&this.endGroupAction(),this.refreshCanvasLayers()},t.prototype.removePortsExtenion=function(e,i,r,s){for(var o=0;o1&&this.startGroupAction();for(var r=i.length-1;r>=0;r--)if(e.children&&e.children.length>0)for(var s=0;s1&&this.endGroupAction()},t.prototype.getSizeValue=function(e,i){var r;return r=e.toString().indexOf("px")>0?e.toString():e.toString().indexOf("%")>0?void 0!==i?"100%":e.toString():e.toString()+"px",i&&(Za(this),r="calc("+r+" - "+i+"px)"),r},t.prototype.renderRulers=function(){this.rulerSettings.showRulers?(function ise(n){var t=Za(n),i=Tt("div",{id:n.element.id+"_overlapRuler",style:"height:"+t.height+"px;width:"+t.width+"px;position:absolute;left:0;top:0",class:"e-ruler-overlap"});n.element.insertBefore(i,n.element.firstChild)}(this),oF(this,!0),oF(this,!1)):$x(this)},t.prototype.intOffPageBackground=function(){var e=new me;e=Za(this);var i=document.getElementById(this.element.id+"content"),r=this.getSizeValue(this.width,e.width),s=this.getSizeValue(this.height,e.height),o=this.rulerSettings.showRulers?"width:"+r+"; height:"+s+";top:"+e.height+"px;left:"+e.width+"px;overflow: scroll;position:absolute;overflow:auto;":"width:"+r+"; height:"+s+";position:absolute; left:0px; top:0px;overflow: auto;",a={id:this.element.id+"content",tabindex:"0",style:o};i?(this.diagramCanvas=i,Ka(this.diagramCanvas,o)):(this.diagramCanvas=Tt("div",a),this.element.appendChild(this.diagramCanvas)),this.diagramCanvas.style.background=this.backgroundColor},t.prototype.initDiagram=function(){this.intOffPageBackground(),Ho(this.element,{style:"width:"+this.getSizeValue(this.width)+"; height:"+this.getSizeValue(this.height)+";position:relative;overflow:hidden;"})},t.prototype.renderHiddenUserHandleTemplateLayer=function(e){var r=Tt("div",{class:this.element.id+"_hiddenUserHandleTemplate",style:"width:"+e.width+"px; height:"+e.height+"px;visibility:hidden ; overflow: hidden;"});this.element.appendChild(r)},t.prototype.renderBackgroundLayer=function(e,i){var r=this.createSvg(this.element.id+"_backgroundLayer_svg",e.width,e.height);Ka(r,i);var s=Fi("g",{id:this.element.id+"_backgroundImageLayer",class:"e-background-image-layer"});r.appendChild(s);var a=Fi("g",{id:this.element.id+"_backgroundLayer",class:"e-background-layer"});r.appendChild(a),this.diagramCanvas.appendChild(r)},t.prototype.renderGridLayer=function(e,i){var r=this.createSvg(this.element.id+"_gridline_svg",e.width,e.height);r.setAttribute("class","e-grid-layer");var s=Fi("g",{id:this.element.id+"_gridline"}),o=Fi("rect",{id:this.element.id+"_grid_rect",x:"0",y:"0",width:"100%",height:"100%"});if(lm()){var a=new URL(window.location.href);o.setAttribute("fill",""!==a.search?"url(#"+this.element.id+"_pattern)":"url("+location.protocol+"//"+location.host+location.pathname+"#"+this.element.id+"_pattern)")}else o.setAttribute("fill","url(#"+this.element.id+"_pattern)");s.appendChild(o),r.appendChild(s),this.diagramCanvas.appendChild(r),ti(r,{style:i})},t.prototype.renderDiagramLayer=function(e,i){if(this.diagramLayerDiv=Tt("div",{id:this.element.id+"_diagramLayer_div",style:"width:"+e.width+"px; height:"+e.height+"px;"+i}),"SVG"===this.mode){var s=this.createSvg(this.element.id+"_diagramLayer_svg",e.width,e.height);s.style["pointer-events"]="none",s.setAttribute("class","e-diagram-layer");var o=Fi("g",{id:this.element.id+"_diagramLayer"}),a=Fi("g",{});this.diagramLayer=o,s.style["pointer-events"]="all",a.appendChild(o),s.appendChild(a),this.diagramLayerDiv.appendChild(s)}else this.diagramLayer=bo.createCanvas(this.element.id+"_diagram",e.width,e.height),Ka(this.diagramLayer,"position:absolute;left:0px;top:0px;"),this.diagramLayerDiv.appendChild(this.diagramLayer);this.diagramCanvas.appendChild(this.diagramLayerDiv)},t.prototype.initLayers=function(){var e="position:absolute;top:0px;left:0px;overflow:hidden;pointer-events:none;",r=document.getElementById(this.element.id).getBoundingClientRect(),s=function Loe(){var n=Tt("div",{style:"visibility:hidden; width: 100px"});document.body.appendChild(n);var t=n.getBoundingClientRect().width;n.style.overflow="scroll";var e=Tt("div",{style:"width:100%"});n.appendChild(e);var i=e.getBoundingClientRect().width;return n.parentNode.removeChild(n),t-i}();this.scroller.scrollerWidth=s,this.scroller.setViewPortSize(r.width,r.height),this.renderRulers();var o="measureElement";window[""+o]&&(window[""+o]=null,document.getElementById("measureElement").remove()),function WF(){var n="measureElement";if(window[""+n])window[""+n].usageCount+=1;else{var t=Tt("div",{id:"measureElement",style:"visibility:hidden ; height: 0px ; width: 0px; overflow: hidden;"}),e=Tt("span",{style:"display:inline-block ; line-height: normal"});t.appendChild(e);var i=Tt("img",{alt:"measureElementImage",src:"data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7"});t.appendChild(i);var r=document.createElementNS("http://www.w3.org/2000/svg","svg");r.setAttribute("xmlns:xlink","http://www.w3.org/1999/xlink"),t.appendChild(r);var s=document.createElementNS("http://www.w3.org/2000/svg","path");s.setAttribute("d",""),r.appendChild(s),document.createTextNode("");var a=document.createElementNS("http://www.w3.org/2000/svg","text");a.setAttributeNS("http://www.w3.org/XML/1998/namespace","xml:space","preserve"),r.appendChild(a),window[""+n]=t,window[""+n].usageCount=1,document.body.appendChild(t);var l="measureElementCount";window[""+l]?window[""+l]++:window[""+l]=1}}(),this.renderBackgroundLayer(r,e),this.renderGridLayer(r,e),this.renderDiagramLayer(r,e),this.renderHTMLLayer(r,e),this.renderPortsExpandLayer(r,e),this.renderNativeLayer(r,e),this.renderAdornerLayer(r,e),this.renderHiddenUserHandleTemplateLayer(r)},t.prototype.renderAdornerLayer=function(e,i){var r=Tt("div",{id:this.element.id+"_diagramAdornerLayer",style:"width:"+e.width+"px;height:"+e.height+"px;"+i}),s=Tt("div",{id:this.element.id+"_diagramUserHandleLayer",style:"width:"+e.width+"px;height:"+e.height+"px;"+i});s.setAttribute("class","e-userHandle-layer"),r.appendChild(s);var o=this.createSvg(this.element.id+"_diagramAdorner_svg",e.width,e.height);o.setAttribute("class","e-adorner-layer"),o.style["pointer-events"]="none",this.adornerLayer=Fi("g",{id:this.element.id+"_diagramAdorner"}),this.adornerLayer.style[" pointer-events"]="all",o.appendChild(this.adornerLayer),r.appendChild(o),this.diagramCanvas.appendChild(r);var a=Fi("g",{id:this.element.id+"_SelectorElement"});this.adornerLayer.appendChild(a),ti(o,{style:"pointer-events:none;"})},t.prototype.renderPortsExpandLayer=function(e,i){var r=this.createSvg(this.element.id+"_diagramPorts_svg",e.width,e.height);r.setAttribute("class","e-ports-expand-layer");var s=Fi("g",{id:this.element.id+"_diagramPorts",class:"e-ports-layer",style:"pointer-events: all;"});r.appendChild(s);var o=Fi("g",{id:this.element.id+"_diagramExpander",class:"e-expand-layer",style:"pointer-events: all;"});r.appendChild(o),this.diagramCanvas.appendChild(r),ti(r,{style:i})},t.prototype.renderHTMLLayer=function(e,i){this.htmlLayer=Tt("div",{id:this.element.id+"_htmlLayer",style:"width:"+e.width+"px; height:"+e.height+"px;position:absolute;top:0px;left:0px;overflow:hidden;pointer-events:none;",class:"e-html-layer"});var r=Tt("div",{id:this.element.id+"_htmlLayer_div",style:"position:absolute;top:0px;left:0px;pointer-events:all;"});this.htmlLayer.appendChild(r),this.diagramCanvas.appendChild(this.htmlLayer)},t.prototype.renderNativeLayer=function(e,i){var r=this.createSvg(this.element.id+"_nativeLayer_svg",e.width,e.height),s=Fi("g",{id:this.element.id+"_nativeLayer",style:"pointer-events:all;"});r.appendChild(s),this.diagramLayerDiv.appendChild(r),ti(r,{class:"e-native-layer",style:i})},t.prototype.createSvg=function(e,i,r){var s=document.createElementNS("http://www.w3.org/2000/svg","svg");return ti(s,{id:e,width:i,height:r}),s},t.prototype.updateBazorShape=function(){for(var e=0;e1,i=[],r={},s={},o=[],a=0,l=this.nodes;a0||b&&b.children&&b.children.length>0)&&(M=!1),S&&S.wrapper&&b&&b.wrapper&&M?this.initConnectors(r[""+h],p):i.push(r[""+h])}else b=r[y.targetID],(S=r[y.sourceID])&&S.children&&S.children.length>0||b&&b.children&&b.children.length>0?i.push(r[""+h]):this.initConnectors(r[""+h],p);else r[""+h].children?o.push(h):r[""+h].shape instanceof fT&&r[""+h].shape.activity.subProcess.processes&&r[""+h].shape.activity.subProcess.processes.length>0?s[r[""+h].id]=h:this.initNodes(r[""+h],p);if(this.bpmnModule)for(var w=0,C=this.bpmnModule.bpmnTextAnnotationConnector;w-1&&-1===r.indexOf(c)&&-1===s.indexOf(c)&&r.splice(0,0,c);-1===r.indexOf(o)&&s.push(o)}return r.concat(s)},t.prototype.addToLayer=function(e,i){var r;if(i&&(r=this.commandHandler.getObjectLayer(e.id)),(!i||!r)&&-1===this.activeLayer.objects.indexOf(e.id)&&this.activeLayer.objects.push(e.id),(e instanceof te||e instanceof de)&&("SwimLane"!==e.shape.type||e.children&&e.children.length>0)){if(e.parentId){var s=this.swimlaneZIndexTable[e.parentId],o=this.swimlaneChildTable[e.id];(s&&-1!==s||o&&-1!==o)&&(e.zIndex=this.swimlaneChildTable[e.id])}e instanceof de&&e.sourceID&&e.targetID?-1!==this.activeLayer.objects.indexOf(e.sourceID)&&-1!==this.activeLayer.objects.indexOf(e.targetID)&&this.setZIndex(r||this.activeLayer,e):this.setZIndex(r||this.activeLayer,e)}},t.prototype.updateLayer=function(e){for(var i=0,r=Object.keys(e.layers);i0)for(r=0;rs;l--)r.zIndexTable[parseInt(l.toString(),10)]=r.zIndexTable[l-1],this.nameTable[r.zIndexTable[parseInt(l.toString(),10)]]&&(this.nameTable[r.zIndexTable[parseInt(l.toString(),10)]].zIndex=l);r.zIndexTable[parseInt(a.toString(),10)]=i.id}}},t.prototype.initializeDiagramLayers=function(){for(var e=0;ethis.layers[parseInt(a.toString(),10)].zIndex&&(i=this.layers[parseInt(e.toString(),10)],this.layers[parseInt(e.toString(),10)]=this.layers[parseInt(a.toString(),10)],this.layers[parseInt(a.toString(),10)]=i);0===this.layers.length&&this.commandHandler.addLayer({id:"default_layer",visible:!0,lock:!1,objects:[],zIndex:0,objectZIndex:-1,zIndexTable:{}},null,!0),this.setActiveLayer(this.layers[this.layers.length-1].id)},t.prototype.resetTool=function(){this.eventHandler.resetTool()},t.prototype.initObjectExtend=function(e,i,r){if(r){var s=this.commandHandler.checkBoundaryConstraints(void 0,void 0,e.wrapper.bounds,!0);if("SwimLane"===e.shape.type)for(var o=0,a=Object.keys(i.zIndexTable);o0)&&this.setZIndex(i,e)),e instanceof te){if(r){if("helper"!==e.id&&(o=Zi(this.getNodeDefaults))){if((a=o(e,this))&&a.ports)for(var l=0;l0)for(l=0;l0&&!e.container||e.processId){var r=this.nameTable[e.id];if(!(this.realActions&$i.PreventScale||this.realActions&$i.PreventDrag)){if(r.offsetX&&(this.realActions&$i.EnableGroupAction||!(this.diagramActions&ee.UndoRedo||this.diagramActions&ee.ToolAction||this.diagramActions&ee.PublicMethod))){this.realActions|=$i.PreventScale;var s=r.offsetX-e.wrapper.offsetX;r.offsetX=e.wrapper.offsetX;var o=r.offsetY-e.wrapper.offsetY;r.offsetY=e.wrapper.offsetY,s+o!==0&&this.drag(r,s,o),this.realActions&=~$i.PreventScale}else r.offsetX=e.wrapper.offsetX;r.offsetY&&(this.realActions&$i.EnableGroupAction||!(this.diagramActions&ee.UndoRedo||this.diagramActions&ee.ToolAction||this.diagramActions&ee.PublicMethod))?(this.realActions|=$i.PreventScale,o=r.offsetY-e.wrapper.offsetY,r.offsetY=e.wrapper.offsetY,this.drag(r,0,o),this.realActions&=~$i.PreventScale):r.offsetY=e.wrapper.offsetY,this.diagramActions&&(r.width=e.wrapper.actualSize.width,r.height=e.wrapper.actualSize.height)}}i&&e.children&&e.children.length>0&&(void 0!==this.nameTable[e.id].width?this.scaleObject(e,this.nameTable[e.id].width,!0):this.nameTable[e.id].width=e.wrapper.actualSize.width,void 0!==this.nameTable[e.id].height?this.scaleObject(e,this.nameTable[e.id].height,!1):this.nameTable[e.id].height=e.wrapper.actualSize.height)},t.prototype.initNode=function(e,i,r){var a,f,s=e.initContainer(),o=new Mi;if(this.diagramSettings.inversedAlignment||(s.inversedAlignment=!1),s.children||(s.children=[]),e.children){s.measureChildren=!1,o.id=e.id+"group_container",o.style.fill=e.shape&&"SwimLane"===e.shape.type?e.style.fill:"none",o.style.strokeColor="none",o.horizontalAlignment="Stretch",o.verticalAlignment="Stretch",o.pivot=e.pivot,s.style=e.style,s.padding.left=e.padding.left,s.padding.right=e.padding.right,s.padding.top=e.padding.top,s.padding.bottom=e.padding.bottom,o.children=[],o.preventContainer=!0,e.container&&(o.relativeMode="Object");var l=!!(e.ports&&e.ports.length>0);if(m(e.container)&&!l&&s.children.push(o),e.container&&"Grid"===e.container.type)for(var h=0;h0&&e.wrapper.children[0]instanceof Gv){if(this.setZIndex(this.activeLayer,e),this.connectors.length>0)for(h=0;h0?i.phases.length:0,v="Horizontal"===i.orientation,y=v?i.phases.length||1:s.length+1,S=v?(i.header&&i.hasHeader?1:0)+(i.phases.length>0?1:0)+i.lanes.length:(i.header&&i.hasHeader?1:0)+i.phases.length;if(0===h&&!v&&i.lanes.length&&(S+=1),v?(a=(i.header&&i.hasHeader?1:0)+(h>0?1:0),l=0):(a=i.header&&i.hasHeader?1:0,l=h>0?1:0),s.length>0)for(o+=i.header&&i.hasHeader?i.header.height:0,f=0;fl?d.margin.left=d.margin.left-(u.bounds.left-e.bounds.left):u.children[0].children[1].actualSize.width+r>=d.margin.left&&(d.margin.left=u.children[0].children[1].actualSize.width+r),d.margin.lefta?d.margin.top=d.margin.top-(u.bounds.top-o):u.children[0].children[1].actualSize.height+r>=d.margin.top&&(d.margin.top=u.children[0].children[1].actualSize.height+r),d.margin.left0)for(o=0;o0&&this.updateChildPosition(e)},t.prototype.addBpmnAnnotationConnector=function(e,i){if(e.parentObj instanceof t||e.parentObj instanceof Fd){var r=e.shape,o=""!==r.textAnnotation.textAnnotationTarget&&this.nameTable[r.textAnnotation.textAnnotationTarget],a=o?this.nameTable[r.textAnnotation.textAnnotationTarget]:null,l=null!=a?a.wrapper:null,h=e.ports[0],c={x:0,y:0};switch(r.textAnnotation.textAnnotationDirection){case"Left":h.offset={x:0,y:.5},c.x=i.bounds.left-40,c.y=i.bounds.bottom+30;break;case"Right":h.offset={x:1,y:.5},c.x=i.bounds.right+40,c.y=i.bounds.bottom+30;break;case"Top":h.offset={x:.5,y:0},c.x=i.bounds.right+30,c.y=i.bounds.top-40;break;case"Bottom":h.offset={x:.5,y:1},c.x=i.bounds.right+30,c.y=i.bounds.bottom+40;break;default:h.offset={x:0,y:.5},c.x=i.bounds.left-40,c.y=i.bounds.bottom+30,o&&null!=i&&null!=l&&(i.bounds.left>l.bounds.right?h.offset={x:0,y:.5}:i.bounds.rightl.bounds.top?h.offset={x:.5,y:0}:i.bounds.top0&&this.updateChildPosition(r)}},t.prototype.canExecute=function(){return!0},t.prototype.updateStackProperty=function(e,i,r){e.container&&"Stack"===e.container.type&&(i.width||(i.wrapper.horizontalAlignment="Stretch",i.horizontalAlignment="Stretch"),i.height||(i.verticalAlignment="Stretch",i.wrapper.verticalAlignment="Stretch"),r&&"UmlClassifier"===e.shape.type&&(i.umlIndex=r))},t.prototype.initViews=function(){this.isLoading||(this.views.push(this.element.id),this.views[this.element.id]=this)},t.prototype.initCommands=function(){var e=this.commandManager.commands,i={copy:{execute:this.copyCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.C,keyModifiers:ft.Control}},paste:{execute:this.pasteCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.V,keyModifiers:ft.Control}},cut:{execute:this.cutCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.X,keyModifiers:ft.Control}},delete:{execute:this.removeCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Delete}},selectAll:{execute:this.selectAll.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.A,keyModifiers:ft.Control}},undo:{execute:this.undo.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Z,keyModifiers:ft.Control}},redo:{execute:this.redo.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Y,keyModifiers:ft.Control}},nudgeUp:{execute:this.nudgeCommand.bind(this,"Up"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Up},parameter:"up"},nudgeRight:{execute:this.nudgeCommand.bind(this,"Right"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Right},parameter:"right"},nudgeDown:{execute:this.nudgeCommand.bind(this,"Down"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Down},parameter:"down"},nudgeLeft:{execute:this.nudgeCommand.bind(this,"Left"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Left},parameter:"left"},startEdit:{execute:this.startEditCommad.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.F2}},endEdit:{execute:this.endEditCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Escape}},focusToNextItem:{execute:this.navigateItems.bind(this,!0),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Tab}},focusToPreviousItem:{execute:this.navigateItems.bind(this,!1),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Tab,keyModifiers:ft.Shift}},selectFocusedItem:{execute:this.startEditCommad.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Enter}},bold:{execute:this.fontStyleCommand.bind(this,"bold"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.B,keyModifiers:ft.Control}},italic:{execute:this.fontStyleCommand.bind(this,"italic"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.I,keyModifiers:ft.Control}},underline:{execute:this.fontStyleCommand.bind(this,"underline"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.U,keyModifiers:ft.Control}},duplicate:{execute:this.duplicateCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.D,keyModifiers:ft.Control}},group:{execute:this.groupCommand.bind(this,"group"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.G,keyModifiers:ft.Control}},ungroup:{execute:this.groupCommand.bind(this,"ungroup"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.U,keyModifiers:ft.Control|ft.Shift}},rotateClockwise:{execute:this.rotateCommand.bind(this,"clockwise"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.R,keyModifiers:ft.Control}},rotateAntiClockwise:{execute:this.rotateCommand.bind(this,"antiClockwise"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.L,keyModifiers:ft.Control}},flipHorizontal:{execute:this.flipCommand.bind(this,"horizontal"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.H,keyModifiers:ft.Control}},flipVertical:{execute:this.flipCommand.bind(this,"vertical"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.J,keyModifiers:ft.Control}},pointerTool:{execute:this.toolCommand.bind(this,"pointer"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number1,keyModifiers:ft.Control}},textTool:{execute:this.toolCommand.bind(this,"text"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number2,keyModifiers:ft.Control}},connectTool:{execute:this.toolCommand.bind(this,"connect"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number3,keyModifiers:ft.Control}},freeForm:{execute:this.toolCommand.bind(this,"freeForm"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number5,keyModifiers:ft.Control}},lineTool:{execute:this.toolCommand.bind(this,"line"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number6,keyModifiers:ft.Control}},rectangleTool:{execute:this.toolCommand.bind(this,"rectangle"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number8,keyModifiers:ft.Control}},ellipseTool:{execute:this.toolCommand.bind(this,"ellipse"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number9,keyModifiers:ft.Control}},zoomIn:{execute:this.zoomCommand.bind(this,"zoomIn"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Plus,keyModifiers:ft.Control}},zoomOut:{execute:this.zoomCommand.bind(this,"zoomOut"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Minus,keyModifiers:ft.Control}},shiftUp:{execute:this.shiftCommand.bind(this,"Up"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Up,keyModifiers:ft.Shift}},shiftDown:{execute:this.shiftCommand.bind(this,"Down"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Down,keyModifiers:ft.Shift}},shiftLeft:{execute:this.shiftCommand.bind(this,"Left"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Left,keyModifiers:ft.Shift}},shiftRight:{execute:this.shiftCommand.bind(this,"Right"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Right,keyModifiers:ft.Shift}},alignTextCenter:{execute:this.alignCommand.bind(this,"center"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.C,keyModifiers:ft.Control|ft.Shift}},alignTextLeft:{execute:this.alignCommand.bind(this,"right"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.L,keyModifiers:ft.Control|ft.Shift}},alignTextRight:{execute:this.alignCommand.bind(this,"left"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.R,keyModifiers:ft.Control|ft.Shift}},alignTextTop:{execute:this.alignCommand.bind(this,"top"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.E,keyModifiers:ft.Control|ft.Shift}},alignTextCenterVertical:{execute:this.alignCommand.bind(this,"centerVertical"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.M,keyModifiers:ft.Control|ft.Shift}},alignTextBottom:{execute:this.alignCommand.bind(this,"bottom"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.V,keyModifiers:ft.Control|ft.Shift}},alignJustify:{execute:this.alignCommand.bind(this,"justify"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.J,keyModifiers:ft.Control|ft.Shift}},sendToBack:{execute:this.orderCommand.bind(this,"sendToBack"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.B,keyModifiers:ft.Control|ft.Shift}},bringToFront:{execute:this.orderCommand.bind(this,"bringToFront"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.F,keyModifiers:ft.Control|ft.Shift}},sendBackward:{execute:this.orderCommand.bind(this,"sendBackward"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.BracketLeft,keyModifiers:ft.Control}},bringForward:{execute:this.orderCommand.bind(this,"bringForward"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.BracketRight,keyModifiers:ft.Control}}};this.initCommandManager(e,i)},t.prototype.overrideCommands=function(e,i){for(var r,s=0,o=Object.keys(i);se.zIndex){("HTML"===e.shape.type||"Native"===e.shape.type)&&(o="HTML"===e.shape.type?"html":"native"),s=Eoe(i,r[parseInt(a.toString(),10)].id,o);break}return s},t.prototype.updateDiagramObject=function(e,i,r){for(var s,o="domTable",a=0,l=this.views;a1&&(d=this.commandHandler.getObjectLayer(e.id)),void 0===d||d&&d.visible||r){var u=Io(this.element.id);window[""+o][s.element.id+"_diagramLayer"]||(window[""+o][s.element.id+"_diagramLayer"]=document.getElementById(s.element.id+"_diagramLayer"));var f=window[""+o][s.element.id+"_diagramLayer"];this.diagramActions&ee.Interactions&&this.updateCanupdateStyle(e.wrapper.children,!0);var p=this.getMidPoint(e);this.diagramRenderer.updateNode(e.wrapper,f,u,void 0,i?void 0:this.getZindexPosition(e,s.element.id),p,this.portCenterPoint),this.updateCanupdateStyle(e.wrapper.children,!0)}}},t.prototype.applyMarginBezier=function(e,i){i.cx=i.cx+e.margin.left,i.cx=i.cx-e.margin.right,i.cy=i.cy+e.margin.top,i.cy=i.cy-e.margin.bottom},t.prototype.getMidPoint=function(e){var i;if(e instanceof de&&"Bezier"===e.type){i=[];for(var r=this.getBezierPoints(e),s=R.getLengthFromListOfPoints(r),o=0;o0&&e.updateView(e));var s=Io(e.element.id);this.renderDiagramElements(e.diagramLayer,e.diagramRenderer,s,void 0,void 0,i);for(var o=0;o0&&this.renderBasicElement(e),!this.diagramActions||!(this.diagramActions&ee.Render)||ee.ToolAction&this.diagramActions||Ds(this)||1!==this.scroller.currentZoom?this.refreshElements(e):this.renderTimer||(this.renderTimer=setTimeout(function(){i.refreshElements(e)},40)))},t.prototype.updatePortVisibility=function(e,i,r){var s;if((e instanceof te||e instanceof de)&&(!this.drawingObject||!this.drawingObject.shape)&&ro(e)){for(var a=e.ports,l=!1,h=0;h=0&&this.scroller.removeCollection.splice(l,1);var h=this.nameTable[e[parseInt(a.toString(),10)]];this.updateTextElementValue(h),this.diagramRenderer.renderElement(h.wrapper,s,o,void 0,void 0,void 0,void 0,h.zIndex)}for(var c=0;c0?this.scroller.oldCollectionObjects:void 0,b=Object.keys(S||g.zIndexTable);b.sort(function(N,T){return parseInt(""+N,10)-parseInt(""+T,10)});for(var M=0,w=b;M0?h:0)+"px",y=(this.realActions&$i.vScrollbarMoved?0:-(this.scroller.verticalOffset<0?this.scroller.verticalOffset:0))+"px"):(v="0px",y="0px"),this.realActions&$i.hScrollbarMoved&&(this.realActions=this.realActions&~$i.hScrollbarMoved),this.realActions&$i.vScrollbarMoved&&(this.realActions=this.realActions&~$i.vScrollbarMoved)):(v=(l.x<0?h:-this.scroller.horizontalOffset)+"px",y=(l.y<0?c:-this.scroller.verticalOffset)+"px"),this.diagramLayer.style.left=v,this.diagramLayer.style.top=y,A.tx=-l.x/A.scale,A.ty=-l.y/A.scale);var P=!0;if(o&&(P=!1),this.updateTextElementValue(D),this.refreshing&&D.shape.activity&&D.shape.activity.subProcess&&D.shape.activity.subProcess.processes){for(var L=0;L0){var o=s.children[0],a=o.data;(r.isBezierEditing&&this.selectedItems.connectors[0].id===r.id||"Bezier"!==r.type)&&r.getSegmentElement(r,o,"ComplexHierarchicalTree"===this.layout.type||"HierarchicalTree"===this.layout.type?this.layout.orientation:void 0,void 0,!1),o.data!==a&&(s.measure(new me),s.arrange(s.desiredSize),"SVG"===this.mode&&!e&&this.updateDiagramObject(r))}}else this.constraints&nt.Bridging&&console.warn('[WARNING] :: Module "ConnectorBridging" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.setCursor=function(e){this.diagramRenderer.setCursor(this.diagramCanvas,e)},t.prototype.clearCanvas=function(e){var i=e.contentWidth||e.diagramLayer.width/this.scroller.currentZoom,r=e.contentHeight||e.diagramLayer.height/this.scroller.currentZoom;"SVG"!==e.mode&&bo.getContext(e.diagramLayer).clearRect(0,0,i,r)},t.prototype.updateScrollOffset=function(){this.scroller.setScrollOffset(this.diagramCanvas.scrollLeft,this.diagramCanvas.scrollTop),tb(this),Ds(this)&&this.scroller.virtualizeElements()},t.prototype.setOffset=function(e,i){var r="domTable";window[""+r][this.element.id+"content"]||(window[""+r][this.element.id+"content"]=document.getElementById(this.element.id+"content"));var s=window[""+r][this.element.id+"content"];s&&(s.scrollLeft=e,s.scrollTop=i)},t.prototype.setSize=function(e,i){if(this.diagramLayer&&!this.preventDiagramUpdate){var r=Za(this);e-=r.width,i-=r.height;var s=this.spatialSearch.getPageBounds();s.x*=this.scroller.currentZoom,s.y*=this.scroller.currentZoom,s.width*=this.scroller.currentZoom,s.height*=this.scroller.currentZoom;var o="SVG"===this.mode?1:1.5,a="SVG"===this.mode?yT(this.element.id):this.diagramLayer,h="Canvas"===this.mode&&this.constraints&nt.Virtualization?this.scroller.viewPortHeight:i;a.setAttribute("width",(o*("Canvas"===this.mode&&this.constraints&nt.Virtualization?this.scroller.viewPortWidth:e)).toString()),a.setAttribute("height",(o*h).toString());var c=document.getElementById(this.element.id+"_diagramUserHandleLayer");c&&(c.style.width=e+"px",c.style.height=i+"px");var d={width:e.toString(),height:i.toString()};this.diagramLayerDiv.style.width=e+"px",this.diagramLayerDiv.style.height=i+"px",ti(FF(this.element.id),d),ti(function xoe(n){return xt(n).getElementsByClassName("e-ports-expand-layer")[0]}(this.element.id),d);var u=Fl(this.element.id);ti(u,d),u.parentNode.style.width=e+"px",u.parentNode.style.height=i+"px";var f=Ud(this.element.id);ti(f,d),this.diagramRenderer.updateGrid(this.snapSettings,f,this.scroller.transform,this.rulerSettings,this.hRuler,this.vRuler),ti(bT(this.element.id),d),this.htmlLayer.style.width=e+"px",this.htmlLayer.style.height=i+"px","SVG"!==this.mode&&!Ds(this)&&this.refreshDiagramLayer(),"SVG"===this.mode&&Ds(this)&&this.scroller.virtualizeElements()}},t.prototype.transformLayers=function(){var e=this.spatialSearch.getPageBounds();e.x*=this.scroller.currentZoom,e.y*=this.scroller.currentZoom,e.width*=this.scroller.currentZoom,e.height*=this.scroller.currentZoom,this.diagramRenderer.updateGrid(this.snapSettings,Ud(this.element.id),this.scroller.transform,this.rulerSettings,this.hRuler,this.vRuler),this.diagramRenderer.transformLayers(this.scroller.transform,"SVG"===this.mode),this.diagramActions&ee.DragUsingMouse||this.updateSelector(),this.renderPageBreaks(e)},t.prototype.removePageBreaks=function(){if(this.diagramLayer){var e=_F(this.element.id);if(e&&e.childNodes)for(var i=e.childNodes.length,r=0;rthis.pageSettings.height&&(e=this.pageSettings.height,this.pageSettings.height=this.pageSettings.width,this.pageSettings.width=e):this.pageSettings.height>this.pageSettings.width&&(e=this.pageSettings.width,this.pageSettings.width=this.pageSettings.height,this.pageSettings.height=e)},t.prototype.setOverview=function(e,i){if(e)e&&(this.views.push(e.id),this.views[e.id]=e,e.renderDocument(e),e.diagramRenderer.setLayers(),e.updateView(e),this.renderNodes(e));else{for(var r=0;r1&&this.updateSelectionRectangle(),this.isProtectedOnChange=s},t.prototype.updateSelectionRectangle=function(){for(var e=pm(this.element.id),i=!1,r=0;r1&&this.updateSelectionRectangle(),this.enableServerDataBinding(e)},t.prototype.renderSelectorForAnnotation=function(e,i){this.diagramRenderer.renderResizeHandle(e.wrapper.children[0],i,e.thumbsConstraints,this.scroller.currentZoom,e.constraints,this.scroller.transform,void 0,ro(e.annotation),void 0,void 0,e.handleSize)},t.prototype.drawSelectionRectangle=function(e,i,r,s){this.clearSelectorLayer(),this.diagramRenderer.drawSelectionRectangle(e,i,r,s,this.adornerLayer,this.scroller.transform)},t.prototype.renderHighlighter=function(e){var i=Fl(this.element.id);this.diagramRenderer.renderHighlighter(e,i,this.scroller.transform)},t.prototype.clearHighlighter=function(){var e=Fl(this.element.id),i=e.getElementById(e.id+"_highlighter");i&&i.parentNode.removeChild(i)},t.prototype.getNodesConnectors=function(e){for(var i=0;i0;h--)this.eventHandler&&this.eventHandler.touchArgs&&"touchmove"===this.eventHandler.touchArgs.type?(this.diagramRenderer.touchMove=!0,l&&l===o[h-1].id||(a=o[h-1]).parentNode.removeChild(a)):(a=o[h-1]).parentNode.removeChild(a);if(!ce()){var c=IT(this.element.id).childNodes;for(r=c.length;r>0;r--)c[r-1].parentNode.removeChild(c[r-1])}}},t.prototype.getWrapper=function(e,i){var r;i=e.id+"_"+i;for(var s=e instanceof Mi?e:this.getPortContainer(this.nameTable[e.id]),o=0;o0&&this.applyStyle(e,a=r.annotations)}for(i=0;i0){var a=this.selectedItems.connectors[parseInt(i.toString(),10)].annotations;this.applyStyle(e,a)}},t.prototype.applyStyle=function(e,i){for(var r=0;r0)for(var i=0;i0?r[0].zIndex+(e?1:-1):e?0:this.nodes.length+this.connectors.length-1)<0?i=this.nodes.length+this.connectors.length-1:i===this.nodes.length+this.connectors.length&&(i=0);for(var s=0;s0)for(var s=void 0,o=r.children.length-1;o>=0;o--){var a=r.children[parseInt(o.toString(),10)];i.length>0&&-1!==i.indexOf(a.id.split("_groupElement")[0])&&(r.parentNode.insertBefore(a,s||r),s=a)}r&&r.parentNode.removeChild(r)},t.prototype.deleteGroup=function(e){var r=[];e.children&&(r=this.commandHandler.getChildren(e,[])),this.UpdateBlazorDiagramModelCollection(e);for(var s=0,o=r;s0)for(var xe=0;xe0)if("Path"===t.shape.type&&void 0!==n.shape.data)t.wrapper.children[0].data=n.shape.data;else if("Text"===t.shape.type&&void 0!==n.shape.content)t.wrapper.children[0].content=n.shape.content;else if("Image"===t.shape.type&&void 0!==n.shape.source)t.wrapper.children[0].source=n.shape.source;else if("Native"===t.shape.type){for(var r=void 0,s=0;s-1)&&(this.diagramActions&ee.PreventZIndexOnDragging?this.updateDiagramObject(e,!0):this.updateDiagramObject(e)),!s&&d&&(this.lineRoutingModule&&this.diagramActions&&this.constraints&nt.LineRouting&&"helper"!==e.id?this.diagramActions&ee.ToolAction||this.lineRoutingModule.renderVirtualRegion(this,!0):this.diagramActions&&this.constraints&nt.LineRouting&&"helper"!==e.id&&console.warn('[WARNING] :: Module "LineRouting" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),this.updateConnectorEdges(e),"helper"!==e.id&&!(this.diagramActions&ee.ToolAction))))for(var Sa=this.spatialSearch.findObjects(e.wrapper.outerBounds),Mo=0;Moe?Math.abs(r-e):Math.abs(e-r),d=s>i?Math.abs(s-i):Math.abs(i-s);(0===c&&0===d||Number.isNaN(c)&&Number.isNaN(d))&&o.laneMargin&&(u=o.margin.left-o.laneMargin.left,f=o.margin.top-o.laneMargin.top);var p=o.width,g=o.height,v=new Ne(0,0,0,0);if(0!==p&&0!==g&&(v=new Ne((0!==r?r:o.offsetX)-p/2,(0!==s?s:o.offsetY)-g/2,p,g)),h){var y=l,b=this.selectedItems.nodes?this.selectedItems.nodes[0]:void 0;if(""!==y.textAnnotation.textAnnotationTarget&&this.nameTable[y.textAnnotation.textAnnotationTarget])if(""===o.parentId||b&&b.shape&&"TextAnnotation"===b.shape.shape){if("Auto"===y.textAnnotation.textAnnotationDirection&&a.children[0]instanceof Mi&&a.children[0].children[0]instanceof Ze){var w=a.children[0],C=document.getElementById(w.id+"_groupElement"),D=document.getElementById(w.children[0].id+"_groupElement");C.removeChild(D),w.children.splice(0,1),this.isProtectedOnChange=!0,this.bpmnModule.setAnnotationPath(v,w,o,y,y.textAnnotation.textAnnotationDirection,this),this.isProtectedOnChange=!1}}else this.isPositionUndo=!0,this.updateTextAnnotationInSwimlane(o,o),this.isPositionUndo=!1;else o.inEdges.length>0&&(x=this.nameTable[""+o.inEdges[0]])&&x.isBpmnAnnotationConnector&&(x.sourcePoint={x:r>e?x.sourcePoint.x+c:x.sourcePoint.x-c,y:s>i?x.sourcePoint.y+d:x.sourcePoint.y-d});this.nodePropertyChange(o,{},P={ports:[{offset:o.ports[0].offset}]})}else for(var L=0,O=o.outEdges;Le?T.offsetX+c:T.offsetX-c,T.offsetY=s>i?T.offsetY+d:T.offsetY-d,P={offsetX:T.offsetX,offsetY:T.offsetY}),this.nodePropertyChange(T,z,P)}}}},t.prototype.updatePorts=function(e,i){if(e&&e.ports.length>0)for(var r=0,s=Object.keys(e.ports);r0)for(var i=0;i0)for(var r=0;r0&&void 0===r.segments&&(e.segments=[]),void 0!==r.shape&&void 0!==e.shape&&e.shape&&"Bpmn"===e.shape.type&&this.bpmnModule&&this.bpmnModule.updateBPMNConnector(e,i,r,this),void 0!==e.constraints?(this.updateThumbConstraints(this.selectedItems.connectors,this.selectedItems),s=!0):s},t.prototype.connectorPropertyChange=function(e,i,r,s,o){if(this.canEnableBlazorObject){var a=$(e);this.insertValue(a,!1)}var d,u,f,p,l=e.wrapper.bounds,h=!1,c=[];if(h=this.connectorProprtyChangeExtend(e,i,r,h),void 0!==r.visible&&this.updateElementVisibility(e.wrapper,e,e.visible),void 0!==r.sourcePoint||void 0!==r.targetPoint||void 0!==r.sourceID||void 0!==r.targetID||void 0!==r.targetPadding||void 0!==r.sourcePortID||void 0!==r.targetPortID||void 0!==r.sourcePadding||void 0!==r.type||void 0!==r.segments||void 0!==r.flip){if(void 0!==r.sourceID&&r.sourceID!==i.sourceID||r.sourcePortID){if(u=this.findInOutConnectPorts(g=this.nameTable[e.sourceID],!1),(!g||Rh(g)||""!==e.sourcePortID&&Ld(u))&&(e.sourceWrapper=g?this.getEndNodeWrapper(g,e,!0):void 0,e.sourcePortID&&void 0===r.sourcePortID&&(e.sourcePortWrapper=g?this.getWrapper(g.wrapper,e.sourcePortID):void 0),this.removePortEdges(this.nameTable[i.sourceID]||g,i.sourcePortID||e.sourcePortID,e.id,!1)),void 0!==r.sourceID&&void 0!==i.sourceID&&""!==i.sourceID){var v=this.nameTable[i.sourceID];void 0!==v&&v.outEdges&&-1!==v.outEdges.indexOf(e.id)&&sm(v.outEdges,e.id)}this.updateEdges(e)}if(void 0!==r.targetID&&r.targetID!==i.targetID){if(d=this.findInOutConnectPorts(y=this.nameTable[r.targetID],!0),(!y||ua(y)||""!==e.targetPortID&&zh(d))&&(e.targetWrapper=y?this.getEndNodeWrapper(y,e,!1):void 0,e.targetPortID&&void 0===r.targetPortID&&(e.targetPortWrapper=y?this.getWrapper(y.wrapper,e.targetPortID):void 0),this.removePortEdges(this.nameTable[i.targetID]||y,i.targetPortID||e.targetPortID,e.id,!0)),void 0!==i&&void 0!==i.targetID&&""!==i.targetID){var S=this.nameTable[i.targetID];void 0!==S&&S.inEdges&&-1!==S.inEdges.indexOf(e.id)&&sm(S.inEdges,e.id)}this.updateEdges(e)}var g,y;void 0!==r.sourcePortID&&r.sourcePortID!==i.sourcePortID&&(e.sourceID&&this.nameTable[e.sourceID]&&(f=this.nameTable[e.sourceID].wrapper),!(g=this.nameTable[e.sourceID])||Rh(g)||""!==e.sourcePortID&&Ld(u)?e.sourcePortWrapper=f?this.getWrapper(f,r.sourcePortID):void 0:""===e.sourcePortID&&!Rh(g)&&(e.sourcePortWrapper=void 0)),void 0!==r.targetPortID&&r.targetPortID!==i.targetPortID&&(e.targetID&&this.nameTable[e.targetID]&&(p=this.nameTable[e.targetID].wrapper),!(y=this.nameTable[e.targetID])||ua(y)||""!==e.targetPortID&&zh(d)?e.targetPortWrapper=p?this.getWrapper(p,r.targetPortID):void 0:""===e.targetPortID&&!ua(y)&&(e.targetPortWrapper=void 0)),void 0!==r.flip&&(e.flip=r.flip,EF(e)),"Orthogonal"===e.type&&this.lineRoutingModule&&this.diagramActions&&this.constraints&nt.LineRouting&&!(this.diagramActions&ee.ToolAction)&&"ComplexHierarchicalTree"!==this.layout.type&&(this.lineRoutingModule.renderVirtualRegion(this,!0),e.sourceID!==e.targetID&&e.segments.length>1&&this.lineRoutingModule.refreshConnectorSegments(this,e,!1)),c=this.getPoints(e)}void 0!==r.style&&Hh(r.style,e.wrapper.children[0]),(c.length>0||void 0!==r.sourceDecorator||void 0!==r.targetDecorator&&function qse(n){return-1!==n.indexOf("shape")||-1!==n.indexOf("pathData")||-1!==n.indexOf("width")||-1!==n.indexOf("height")}(Object.keys(r.targetDecorator))||void 0!==r.cornerRadius)&&(tp(e,c.length>0?c:e.intermediatePoints,this.diagramActions),void 0!==r.type&&(h=!0),c.length>0&&(e.wrapper.measure(new me(e.wrapper.width,e.wrapper.height)),e.wrapper.arrange(e.wrapper.desiredSize),this.updateConnectorAnnotation(e),this.updateConnectorPort(e),this.updateConnectorfixedUserHandles(e),this.updateObject(e,i,r))),(r.sourcePoint||r.targetPoint||r.segments)&&this.diagramActions===ee.Render&&(h=!0),"Bpmn"===e.shape.type&&"Default"===e.shape.sequence&&"Sequence"===e.shape.flow&&this.commandHandler.updatePathElementOffset(e),s||this.updateBridging(),this.updateAnnotations(r,e),this.updateConnectorPorts(r,e),this.updatefixedUserHandle(r,e),e.wrapper.measure(new me(e.wrapper.width,e.wrapper.height)),e.wrapper.arrange(e.wrapper.desiredSize),!1===l.equals(l,e.wrapper.bounds)&&(this.updateQuad(e),"Drag"!==this.eventHandler.currentAction&&this.updateGroupSize(e)),!0===h&&this.checkSelectedItem(e)&&(!(this.diagramActions&ee.ToolAction)||this.diagramActions&ee.UndoRedo)&&this.updateSelector(),this.preventConnectorsUpdate||(!Ds(this)||Ds(this)&&this.scroller.oldCollectionObjects.indexOf(e.id)>-1)&&(this.diagramActions&ee.PreventZIndexOnDragging?this.updateDiagramObject(e,!0):this.updateDiagramObject(e)),this.updateConnectorEdges(e),this.diagramActions&&"New"!==e.status&&(e.status="Update"),this.triggerPropertyChange(o,e,i,r)},t.prototype.removePortEdges=function(e,i,r,s){if(e)for(var o=0;o0&&e.id===s[s.length-1].id&&(r=!0),r},t.prototype.updateDiagramContainerVisibility=function(e,i){if(e instanceof Cs)for(var r=0;r>"),r instanceof es&&this.updateAnnotationWrapper(r,s,o,a)),void 0!==e.template&&(r.content=e.template,this.updateAnnotationWrapper(r,s,o,a))},t.prototype.updateAnnotationWrapper=function(e,i,r,s){for(var o=0,a=this.views;o=0&&this.nodes.splice(s,1),delete this.nameTable[""+r]}var o=this.nodes.indexOf(this.nameTable[this.currentSymbol.id]);o>=0&&this.nodes.splice(o,1)}},t.prototype.selectDragedNode=function(e,i,r){this.currentSymbol=e,"SVG"!==this.mode&&this.refreshDiagramLayer(),this.commandHandler.oldSelectedObjects=am(this),this.commandHandler.select(e),this.eventHandler.mouseDown(i.event),this.eventHandler.mouseMove(i.event,i),this.preventDiagramUpdate=!1,this.updatePage(),r.style.opacity="0"},t.prototype.initDroppables=function(){var s,o,e=this,i={},r={},a="selectedSymbols";this.droppable=new lR(this.element);var l=5;this.droppable.over=function(h){if(e.rulerSettings.showRulers){var c=document.getElementById(e.element.id+"_vRuler"),d=parseFloat(c.style.width);l=d+1}if(0===e.previousSelectedObjects.length&&!e.currentSymbol&&(e.previousSelectedObjects=e.commandHandler.getSelectedObject()),e.commandHandler.PreventConnectorSplit=!0,e.currentSymbol)h.event.touches&&h.event.touches.length&&e.eventHandler.mouseMove(h.event,h.event.touches);else{var u=null;if(!h.dragData&&"drag"===h.name){var f=document.getElementsByClassName("e-dragclone")[0];f&&(u=f)}if(h.dragData||u){var p=void 0,g=void 0;document.getElementById(e.element.id+"content").focus();var v=e.eventHandler.getMousePosition(h.event),y=void 0,S=u||h.dragData.helper,b=S.getAttribute("paletteId"),M=void 0,w=void 0,C=void 0,D=void 0;if(!b&&h.dragData){e.triggerEvent(Ce.dragEnter,A={source:null,element:p,cancel:!1,diagram:e,dragData:h.dragData.draggedElement.ej2_instances[0].dragData,dragItem:p});var x=void 0,P=void 0;if(A.dragItem){if(A.dragItem.sourcePoint&&A.dragItem.targetPoint?P=new de(e,"connectors",A.dragItem,!0):x=new te(e,"nodes",A.dragItem,!0),e.initObject(p=x||P,void 0,void 0,!0),e.enterObject=p,e.enterTable=r,p instanceof te)x.offsetX=v.x+5+x.width*x.pivot.x,x.offsetY=v.y+x.height*x.pivot.y;else if(p instanceof de){var L=Ne.toBounds([p.sourcePoint,p.targetPoint]),O=v.x-L.left,N=v.y-L.top;p.sourcePoint.x+=O,p.sourcePoint.y+=N,p.targetPoint.x+=O,p.targetPoint.y+=N}e.preventDiagramUpdate=!0,e.currentSymbol=p,"SVG"!==e.mode&&e.refreshDiagramLayer(),e.selectDragedNode(p,h,S),delete e.enterObject,delete e.enterTable,e.droppable[""+a]=S,e.allowServerDataBinding=!0}}if(b){var T=document.getElementById(b).ej2_instances[0];if(e.droppable.sourceElement=T,T){var B=T[""+a];e.allowServerDataBinding=!1,y=$(T[""+a]),i=T.childTable;var j=B.wrapper.children[0].children[0];if(D=function $se(n,t,e){var i=AF(n,t,e,"width"),r=AF(n,t,e,"height");return new me(i,r)}(T,y,j),T[""+a]instanceof te){"TextAnnotation"===B.shape.shape?(y.offsetX=v.x+11+D.width*y.pivot.x,y.offsetY=v.y+11+D.height*y.pivot.y):(y.offsetX=v.x+5+D.width*y.pivot.x,y.offsetY=v.y+D.height*y.pivot.y),"Bpmn"===(x=new te(e,"nodes",y,!0)).shape.type&&x.shape.activity.subProcess.processes&&x.shape.activity.subProcess.processes.length&&(x.shape.activity.subProcess.processes=[]),w=x.previewSize,C=T.symbolDragSize;var Q=T.symbolPreview;if(x.width=(M=x.dragSize).width||C.width||w.width||Q.width||x.width,x.height=M.height||C.height||w.height||Q.height||x.height,"SwimLane"===x.shape.type){if(e.diagramActions|=ee.PreventHistory,x.shape.isLane){x.children=[],s={id:"header"+Qe()},"Horizontal"===x.shape.orientation?(s.width=x.shape.lanes[0].header.width,s.height=x.shape.lanes[0].height):(s.width=x.shape.lanes[0].width,s.height=x.shape.lanes[0].header.height),s.style=x.shape.lanes[0].header.style,s.offsetX=v.x+l+s.width/2,s.offsetY=v.y+s.height/2,e.diagramActions|=ee.PreventCollectionChangeOnDragOver,s=e.add(s),o={id:"body"+Qe()},"Horizontal"===x.shape.orientation?(o.width=x.shape.lanes[0].width-s.width,o.height=x.shape.lanes[0].height,o.offsetX=v.x+l+(x.shape.lanes[0].header.width+o.width/2),o.offsetY=v.y+o.height/2):(o.width=x.shape.lanes[0].width,o.height=x.shape.lanes[0].height-s.height,o.offsetX=v.x+l+o.width/2,o.offsetY=v.y+(x.shape.lanes[0].header.height+o.height/2)),o.style=x.shape.lanes[0].style,o=e.add(o);var oe={id:"group"+Qe(),children:[s.id,o.id]};oe.shape=x.shape,oe.width=x.shape.lanes[0].width,oe.height=x.shape.lanes[0].height,oe.previewSize=x.previewSize,oe.dragSize=x.dragSize,oe.addInfo=x.addInfo,x=e.add(oe),e.diagramActions&=~ee.PreventCollectionChangeOnDragOver}e.diagramActions&=~ee.PreventHistory}if(x.shape.isPhase&&((g="Horizontal"===x.shape.orientation)?(x.offsetX=v.x+l+(x.width||j.actualSize.width)/2,x.offsetY=v.y,x.shape.data="M20,"+x.height/2+" L"+(x.width-20)+","+x.height/2+"z",x.height=1):(x.offsetX=v.x+5,x.offsetY=v.y+(x.height||j.actualSize.height)/2,x.shape.data="M"+x.width/2+",20 L"+x.width/2+","+(x.height-20)+"z",x.width=1)),"UmlClassifier"===x.shape.type&&(x.children=x.width=x.height=void 0,y.children=void 0,"Class"===x.shape.classifier&&x.shape.classShape.methods.length<=0&&x.shape.classShape.attributes.length<=0&&(x.shape.classShape.attributes=[{name:"Name",type:"Type",style:{}}]),"Enumeration"===x.shape.classifier&&x.shape.enumerationShape.members.length<=0&&(x.shape.enumerationShape.members=[{name:"Name"}]),"Interface"===x.shape.classifier&&x.shape.interfaceShape.methods.length<=0&&x.shape.interfaceShape.attributes.length<=0&&(x.shape.interfaceShape.attributes=[{name:"Name",type:"Type",style:{}}])),p=x,y.children){var ue=y;r=e.getChildren(ue,{},i),nT(ue,-ue.offsetX,-ue.offsetY,r,!0,e)}}else if(T[""+a]instanceof de){p=new de(e,"connectors",y,!0);var Me=Ne.toBounds([p.sourcePoint,p.targetPoint]),De=v.x-Me.left,xe=v.y-Me.top;p.sourcePoint.x+=De,p.sourcePoint.y+=xe,p.targetPoint.x+=De,p.targetPoint.y+=xe}p.shape.isLane||(p.id+=Qe());var A={source:T,element:p,cancel:!1,diagram:e,dragData:null,dragItem:p};if(e.enterObject=p,e.enterTable=r,e.triggerEvent(Ce.dragEnter,A),p instanceof te&&"SwimLane"===p.shape.type&&p.shape.isLane){var Ie=A.element,Ve=Ie.shape.lanes[0];g="Horizontal"===Ie.shape.orientation;var ot=e.nameTable[p.children[0]],$e=e.nameTable[p.children[1]];w=p.previewSize,C=T.symbolDragSize,Ve.width=(M=p.dragSize).width||C.width||w.width||Ve.width,Ve.height=M.height||C.height||w.height||Ve.height,g?(s.width=Ve.header.width,s.height=Ve.height,o.width=Ve.width-s.width,o.height=Ve.height,o.offsetX=v.x+l+(Ve.header.width+$e.width/2),o.offsetY=v.y+$e.height/2):(s.width=Ve.width,s.height=Ve.header.height,o.width=Ve.width,o.height=Ve.height-s.height,o.offsetX=v.x+l+$e.width/2,o.offsetY=v.y+(Ve.header.height+$e.height/2)),s.offsetX=v.x+l+ot.width/2,s.offsetY=v.y+ot.height/2,p.width=Ve.width,p.height=Ve.height}if(p instanceof te&&p.shape.isPhase&&(g?p.height=1:p.width=1),!e.activeLayer.lock&&!A.cancel){if(e.preventDiagramUpdate=!0,p.children&&e.findChild(p,r),e.preventDiagramUpdate=!0,p.zIndex!==Number.MIN_VALUE&&(p.zIndex=Number.MIN_VALUE),e.initObject(p,void 0,void 0,!0),e.bpmnModule)for(var Ci=0;Ci0&&(S.segments=[]),d=this.add(S,!0)),(S||d)&&(Vv(this)||Wv(this))&&this.select([this.nameTable[S[""+b]]],!1,this.previousSelectedObjects),y.target&&y.target instanceof de&&!0===this.enableConnectorSplit&&this.nameTable[S[""+b]]instanceof te&&(this.commandHandler.connectorSplit(this.nameTable[S[""+b]],y.target),this.commandHandler.PreventConnectorSplit=!1))),this.protectPropertyChange(!1),v=this.nameTable[S[""+b]],S.hasTarget&&(S.nodeId=S.hasTarget,this.remove(S)),this.bpmnModule&&v instanceof te&&S.processId&&(v.processId=S.processId,this.bpmnModule.dropBPMNchild(this.nameTable[v.processId],v,this)),y.cancel||this.endGroupAction(),"SVG"!==this.mode&&this.refreshDiagramLayer(),delete this.droppable[""+c]):(this.triggerEvent(Ce.drop,y={source:h.droppedElement,element:void 0,target:this.eventHandler.hoverNode||this.eventHandler.lastObjectUnderMouse||this,cancel:!1,position:void 0}),S=void 0,b="id"),this.droppable[M="selectedSymbols"]&&this.droppable[""+M].parentNode)gt(this.droppable[""+M]);else for(w=document.getElementsByClassName("e-dragclone"),C=0;C0)for(var f=0;f1),e.previousSelectedObject=null}}},t.prototype.getDropEventArgs=function(e){if(this.eventHandler.lastObjectUnderMouse||this.eventHandler.hoverNode){var i=this.eventHandler.lastObjectUnderMouse||this.eventHandler.hoverNode;e.target=ps(i)===de?{connector:i}:{node:i}}else e.target.diagramId=this.element.id},t.prototype.removeChildInNodes=function(e){if(e){if(e.children)for(var i=0;i1){var l=2;if(e.children&&e.children.length>0)for(;e.children.indexOf(i.objects[s-l])>-1;)l++;this.commandHandler.moveSvgNode(e.id,i.objects[s-l]),this.commandHandler.moveSvgNode(i.objects[s-l],e.id)}else if(o){var h=this.commandHandler.getLayer(this.layerZIndexTable[o.zIndex]).objects[0];h?(this.commandHandler.moveSvgNode(e.id,h),this.commandHandler.updateNativeNodeIndex(e.id,h)):this.moveObjectsUp(e,i)}else this.moveObjectsUp(e,i)},t.prototype.moveObjectsUp=function(e,i){for(var r,s=this.layers.length-1;s>=0;s--)if(r=this.layers[parseInt(s.toString(),10)],i.id!==r.id){var o=this.commandHandler.getLayer(this.layerZIndexTable[r.zIndex]).objects[r.objects.length-1];if(o){this.commandHandler.moveSvgNode(e.id,o),this.commandHandler.moveSvgNode(o,e.id);break}}},t.prototype.insertData=function(e){return this.crudOperation(e,"create",this.getNewUpdateNodes("New"))},t.prototype.updateData=function(e){return this.crudOperation(e,"update",this.getNewUpdateNodes("Update"))},t.prototype.removeData=function(e){return this.crudOperation(e,"destroy",this.getDeletedNodes())},t.prototype.crudOperation=function(e,i,r){if(e){var s=this.parameterMap(e,!(e instanceof de));if(s){var o=e instanceof de?this.dataSourceSettings.connectionDataSource.crudAction[""+i]:this.dataSourceSettings.crudAction[""+i];this.raiseAjaxPost(JSON.stringify(s),o)}return s}var a=r;return this.processCrudCollection(a,this.dataSourceSettings.crudAction[""+i],this.dataSourceSettings.connectionDataSource.crudAction[""+i]),a},t.prototype.processCrudCollection=function(e,i,r){if(e.nodes){var s=[],o=void 0;for(o=0;o0&&this.raiseAjaxPost(JSON.stringify(s),i)}if(e.connectors){for(s=[],o=void 0,o=0;o0&&this.raiseAjaxPost(JSON.stringify(s),r)}},t.prototype.parameterMap=function(e,i){var s,r={},o=i?this.dataSourceSettings:this.dataSourceSettings.connectionDataSource;if(o.id&&(r[o.id]=e.id),o.sourcePointX&&o.sourcePointY&&(r[o.sourcePointX]=e.sourcePoint.x,r[o.sourcePointY]=e.sourcePoint.y),o.targetPointX&&o.targetPointY&&(r[o.targetPointX]=e.targetPoint.x,r[o.targetPointY]=e.targetPoint.y),o.sourceID&&(r[o.sourceID]=e.sourceID),o.targetID&&(r[o.targetID]=e.targetID),o.crudAction&&o.crudAction.customFields&&o.crudAction.customFields.length>0)for(s=0;s{class n extends ph{constructor(e){super(),this.viewContainerRef=e,ml("currentInstance",this,this.viewContainerRef),this.registerEvents($ae),this.directivePropList=qae}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-layer"]],inputs:{addInfo:"addInfo",id:"id",lock:"lock",objects:"objects",visible:"visible",zIndex:"zIndex"},features:[yn]}),n})(),Jae=(()=>{class n extends gh{constructor(){super("layers")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-layers"]],contentQueries:function(e,i,r){if(1&e&&dn(r,Zae,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),Kae=["action","cursor"],ele=[],tle=(()=>{class n extends ph{constructor(e){super(),this.viewContainerRef=e,ml("currentInstance",this,this.viewContainerRef),this.registerEvents(ele),this.directivePropList=Kae}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-cursormap"]],inputs:{action:"action",cursor:"cursor"},features:[yn]}),n})(),ile=(()=>{class n extends gh{constructor(){super("customcursor")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-cursormaps"]],contentQueries:function(e,i,r){if(1&e&&dn(r,tle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),rle=["alignment","cornerRadius","displacement","fill","handleStrokeColor","handleStrokeWidth","height","iconStrokeColor","iconStrokeWidth","id","offset","padding","pathData","tooltip","visibility","width"],nle=[],sle=(()=>{class n extends ph{constructor(e){super(),this.viewContainerRef=e,ml("currentInstance",this,this.viewContainerRef),this.registerEvents(nle),this.directivePropList=rle}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-connector-fixeduserhandle"]],inputs:{alignment:"alignment",cornerRadius:"cornerRadius",displacement:"displacement",fill:"fill",handleStrokeColor:"handleStrokeColor",handleStrokeWidth:"handleStrokeWidth",height:"height",iconStrokeColor:"iconStrokeColor",iconStrokeWidth:"iconStrokeWidth",id:"id",offset:"offset",padding:"padding",pathData:"pathData",tooltip:"tooltip",visibility:"visibility",width:"width"},features:[yn]}),n})(),ole=(()=>{class n extends gh{constructor(){super("fixeduserhandles")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-connector-fixeduserhandles"]],contentQueries:function(e,i,r){if(1&e&&dn(r,sle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),ale=["addInfo","alignment","annotationType","constraints","content","displacement","dragLimit","height","horizontalAlignment","hyperlink","id","margin","offset","rotateAngle","rotationReference","segmentAngle","style","template","tooltip","type","verticalAlignment","visibility","width"],lle=[],hle=(()=>{class n extends ph{constructor(e){super(),this.viewContainerRef=e,ml("currentInstance",this,this.viewContainerRef),this.registerEvents(lle),this.directivePropList=ale}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-connector-annotation"]],inputs:{addInfo:"addInfo",alignment:"alignment",annotationType:"annotationType",constraints:"constraints",content:"content",displacement:"displacement",dragLimit:"dragLimit",height:"height",horizontalAlignment:"horizontalAlignment",hyperlink:"hyperlink",id:"id",margin:"margin",offset:"offset",rotateAngle:"rotateAngle",rotationReference:"rotationReference",segmentAngle:"segmentAngle",style:"style",template:"template",tooltip:"tooltip",type:"type",verticalAlignment:"verticalAlignment",visibility:"visibility",width:"width"},features:[yn]}),n})(),cle=(()=>{class n extends gh{constructor(){super("annotations")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-connector-annotations"]],contentQueries:function(e,i,r){if(1&e&&dn(r,hle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),dle=["addInfo","allowNodeOverlap","annotations","bezierSettings","bridgeSpace","connectionPadding","connectorSpacing","constraints","cornerRadius","dragSize","excludeFromLayout","fixedUserHandles","flip","flipMode","hitPadding","id","margin","maxSegmentThumb","ports","previewSize","segmentThumbShape","segmentThumbSize","segments","shape","sourceDecorator","sourceID","sourcePadding","sourcePoint","sourcePortID","style","symbolInfo","targetDecorator","targetID","targetPadding","targetPoint","targetPortID","tooltip","type","visible","wrapper","zIndex"],ule=[],fle=(()=>{class n extends ph{constructor(e){super(),this.viewContainerRef=e,this.tags=["fixedUserHandles","annotations"],ml("currentInstance",this,this.viewContainerRef),this.registerEvents(ule),this.directivePropList=dle}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-connector"]],contentQueries:function(e,i,r){if(1&e&&(dn(r,ole,5),dn(r,cle,5)),2&e){let s;Kr(s=en())&&(i.childFixedUserHandles=s.first),Kr(s=en())&&(i.childAnnotations=s.first)}},inputs:{addInfo:"addInfo",allowNodeOverlap:"allowNodeOverlap",annotations:"annotations",bezierSettings:"bezierSettings",bridgeSpace:"bridgeSpace",connectionPadding:"connectionPadding",connectorSpacing:"connectorSpacing",constraints:"constraints",cornerRadius:"cornerRadius",dragSize:"dragSize",excludeFromLayout:"excludeFromLayout",fixedUserHandles:"fixedUserHandles",flip:"flip",flipMode:"flipMode",hitPadding:"hitPadding",id:"id",margin:"margin",maxSegmentThumb:"maxSegmentThumb",ports:"ports",previewSize:"previewSize",segmentThumbShape:"segmentThumbShape",segmentThumbSize:"segmentThumbSize",segments:"segments",shape:"shape",sourceDecorator:"sourceDecorator",sourceID:"sourceID",sourcePadding:"sourcePadding",sourcePoint:"sourcePoint",sourcePortID:"sourcePortID",style:"style",symbolInfo:"symbolInfo",targetDecorator:"targetDecorator",targetID:"targetID",targetPadding:"targetPadding",targetPoint:"targetPoint",targetPortID:"targetPortID",tooltip:"tooltip",type:"type",visible:"visible",wrapper:"wrapper",zIndex:"zIndex"},features:[yn]}),n})(),ple=(()=>{class n extends gh{constructor(){super("connectors")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-connectors"]],contentQueries:function(e,i,r){if(1&e&&dn(r,fle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),gle=["cornerRadius","fill","handleStrokeColor","handleStrokeWidth","height","iconStrokeColor","iconStrokeWidth","id","margin","offset","padding","pathData","tooltip","visibility","width"],vle=[],mle=(()=>{class n extends ph{constructor(e){super(),this.viewContainerRef=e,ml("currentInstance",this,this.viewContainerRef),this.registerEvents(vle),this.directivePropList=gle}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-node-fixeduserhandle"]],inputs:{cornerRadius:"cornerRadius",fill:"fill",handleStrokeColor:"handleStrokeColor",handleStrokeWidth:"handleStrokeWidth",height:"height",iconStrokeColor:"iconStrokeColor",iconStrokeWidth:"iconStrokeWidth",id:"id",margin:"margin",offset:"offset",padding:"padding",pathData:"pathData",tooltip:"tooltip",visibility:"visibility",width:"width"},features:[yn]}),n})(),yle=(()=>{class n extends gh{constructor(){super("fixeduserhandles")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-node-fixeduserhandles"]],contentQueries:function(e,i,r){if(1&e&&dn(r,mle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),Sle=["addInfo","annotationType","constraints","content","dragLimit","height","horizontalAlignment","hyperlink","id","margin","offset","rotateAngle","rotationReference","style","template","tooltip","type","verticalAlignment","visibility","width"],Ile=[],v_=(()=>{class n extends ph{constructor(e){super(),this.viewContainerRef=e,ml("currentInstance",this,this.viewContainerRef),this.registerEvents(Ile),this.directivePropList=Sle}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-node-annotation"]],inputs:{addInfo:"addInfo",annotationType:"annotationType",constraints:"constraints",content:"content",dragLimit:"dragLimit",height:"height",horizontalAlignment:"horizontalAlignment",hyperlink:"hyperlink",id:"id",margin:"margin",offset:"offset",rotateAngle:"rotateAngle",rotationReference:"rotationReference",style:"style",template:"template",tooltip:"tooltip",type:"type",verticalAlignment:"verticalAlignment",visibility:"visibility",width:"width"},features:[yn]}),n})(),m_=(()=>{class n extends gh{constructor(){super("annotations")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-node-annotations"]],contentQueries:function(e,i,r){if(1&e&&dn(r,v_,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),ble=["addInfo","connectionDirection","constraints","height","horizontalAlignment","id","inEdges","margin","offset","outEdges","pathData","shape","style","tooltip","verticalAlignment","visibility","width"],Mle=[],wle=(()=>{class n extends ph{constructor(e){super(),this.viewContainerRef=e,ml("currentInstance",this,this.viewContainerRef),this.registerEvents(Mle),this.directivePropList=ble}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-node-port"]],inputs:{addInfo:"addInfo",connectionDirection:"connectionDirection",constraints:"constraints",height:"height",horizontalAlignment:"horizontalAlignment",id:"id",inEdges:"inEdges",margin:"margin",offset:"offset",outEdges:"outEdges",pathData:"pathData",shape:"shape",style:"style",tooltip:"tooltip",verticalAlignment:"verticalAlignment",visibility:"visibility",width:"width"},features:[yn]}),n})(),Cle=(()=>{class n extends gh{constructor(){super("ports")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-node-ports"]],contentQueries:function(e,i,r){if(1&e&&dn(r,wle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),Ele=["addInfo","annotations","backgroundColor","borderColor","borderWidth","branch","children","collapseIcon","columnIndex","columnSpan","columns","constraints","container","data","dragSize","excludeFromLayout","expandIcon","fixedUserHandles","flip","flipMode","height","horizontalAlignment","id","isExpanded","layoutInfo","margin","maxHeight","maxWidth","minHeight","minWidth","offsetX","offsetY","padding","pivot","ports","previewSize","rotateAngle","rowIndex","rowSpan","rows","shadow","shape","style","symbolInfo","tooltip","verticalAlignment","visible","width","wrapper","zIndex"],Dle=[],y_=(()=>{class n extends ph{constructor(e){super(),this.viewContainerRef=e,this.tags=["fixedUserHandles","annotations","ports"],ml("currentInstance",this,this.viewContainerRef),this.registerEvents(Dle),this.directivePropList=Ele}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-node"]],contentQueries:function(e,i,r){if(1&e&&(dn(r,yle,5),dn(r,m_,5),dn(r,Cle,5)),2&e){let s;Kr(s=en())&&(i.childFixedUserHandles=s.first),Kr(s=en())&&(i.childAnnotations=s.first),Kr(s=en())&&(i.childPorts=s.first)}},inputs:{addInfo:"addInfo",annotations:"annotations",backgroundColor:"backgroundColor",borderColor:"borderColor",borderWidth:"borderWidth",branch:"branch",children:"children",collapseIcon:"collapseIcon",columnIndex:"columnIndex",columnSpan:"columnSpan",columns:"columns",constraints:"constraints",container:"container",data:"data",dragSize:"dragSize",excludeFromLayout:"excludeFromLayout",expandIcon:"expandIcon",fixedUserHandles:"fixedUserHandles",flip:"flip",flipMode:"flipMode",height:"height",horizontalAlignment:"horizontalAlignment",id:"id",isExpanded:"isExpanded",layoutInfo:"layoutInfo",margin:"margin",maxHeight:"maxHeight",maxWidth:"maxWidth",minHeight:"minHeight",minWidth:"minWidth",offsetX:"offsetX",offsetY:"offsetY",padding:"padding",pivot:"pivot",ports:"ports",previewSize:"previewSize",rotateAngle:"rotateAngle",rowIndex:"rowIndex",rowSpan:"rowSpan",rows:"rows",shadow:"shadow",shape:"shape",style:"style",symbolInfo:"symbolInfo",tooltip:"tooltip",verticalAlignment:"verticalAlignment",visible:"visible",width:"width",wrapper:"wrapper",zIndex:"zIndex"},features:[yn]}),n})(),S_=(()=>{class n extends gh{constructor(){super("nodes")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-nodes"]],contentQueries:function(e,i,r){if(1&e&&dn(r,y_,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})();const xle=["animationComplete","click","collectionChange","commandExecute","connectionChange","contextMenuBeforeItemRender","contextMenuClick","contextMenuOpen","created","dataLoaded","doubleClick","dragEnter","dragLeave","dragOver","drop","elementDraw","expandStateChange","fixedUserHandleClick","historyChange","historyStateChange","keyDown","keyUp","load","loaded","mouseEnter","mouseLeave","mouseOver","mouseWheel","onFixedUserHandleMouseDown","onFixedUserHandleMouseEnter","onFixedUserHandleMouseLeave","onFixedUserHandleMouseUp","onImageLoad","onUserHandleMouseDown","onUserHandleMouseEnter","onUserHandleMouseLeave","onUserHandleMouseUp","positionChange","propertyChange","rotateChange","scrollChange","segmentChange","segmentCollectionChange","selectionChange","sizeChange","sourcePointChange","targetPointChange","textEdit"],Tle=[""];let Ale=(()=>{let n=class extends _l{constructor(e,i,r,s){super(),this.ngEle=e,this.srenderer=i,this.viewContainerRef=r,this.injector=s,this.tags=["layers","customCursor","connectors","nodes"],this.element=this.ngEle.nativeElement,this.injectedModules=this.injectedModules||[];try{let o=this.injector.get("DiagramsHierarchicalTree");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsMindMap");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsRadialTree");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsComplexHierarchicalTree");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsDataBinding");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsSnapping");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsPrintAndExport");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsBpmnDiagrams");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsSymmetricLayout");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsConnectorBridging");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsUndoRedo");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsLayoutAnimation");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsDiagramContextMenu");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsLineRouting");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsConnectorEditing");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsLineDistribution");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsEj1Serialization");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsFlowchartLayout");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}this.registerEvents(xle),this.addTwoWay.call(this,Tle),ml("currentInstance",this,this.viewContainerRef),this.context=new SR}ngOnInit(){this.context.ngOnInit(this)}ngAfterViewInit(){this.context.ngAfterViewInit(this)}ngOnDestroy(){this.context.ngOnDestroy(this)}ngAfterContentChecked(){this.tagObjects[0].instance=this.childLayers,this.childCustomCursor&&(this.tagObjects[1].instance=this.childCustomCursor),this.childConnectors&&(this.tagObjects[2].instance=this.childConnectors),this.childNodes&&(this.tagObjects[3].instance=this.childNodes),this.context.ngAfterContentChecked(this)}};return n.\u0275fac=function(e){return new(e||n)(Ot(Jc),Ot(dM),Ot(An),Ot(Wo))},n.\u0275cmp=Ub({type:n,selectors:[["ejs-diagram"]],contentQueries:function(e,i,r){if(1&e&&(dn(r,Qae,5),dn(r,Gae,5),dn(r,Xae,5),dn(r,Jae,5),dn(r,ile,5),dn(r,ple,5),dn(r,S_,5)),2&e){let s;Kr(s=en())&&(i.annotationTemplate=s.first),Kr(s=en())&&(i.nodeTemplate=s.first),Kr(s=en())&&(i.userHandleTemplate=s.first),Kr(s=en())&&(i.childLayers=s.first),Kr(s=en())&&(i.childCustomCursor=s.first),Kr(s=en())&&(i.childConnectors=s.first),Kr(s=en())&&(i.childNodes=s.first)}},inputs:{addInfo:"addInfo",annotationTemplate:"annotationTemplate",backgroundColor:"backgroundColor",bridgeDirection:"bridgeDirection",commandManager:"commandManager",connectorDefaults:"connectorDefaults",connectors:"connectors",constraints:"constraints",contextMenuSettings:"contextMenuSettings",customCursor:"customCursor",dataSourceSettings:"dataSourceSettings",diagramSettings:"diagramSettings",drawingObject:"drawingObject",enableConnectorSplit:"enableConnectorSplit",enablePersistence:"enablePersistence",enableRtl:"enableRtl",fixedUserHandleTemplate:"fixedUserHandleTemplate",getConnectorDefaults:"getConnectorDefaults",getCustomCursor:"getCustomCursor",getCustomProperty:"getCustomProperty",getCustomTool:"getCustomTool",getDescription:"getDescription",getNodeDefaults:"getNodeDefaults",height:"height",historyManager:"historyManager",layers:"layers",layout:"layout",locale:"locale",mode:"mode",nodeDefaults:"nodeDefaults",nodeTemplate:"nodeTemplate",nodes:"nodes",pageSettings:"pageSettings",rulerSettings:"rulerSettings",scrollSettings:"scrollSettings",segmentThumbShape:"segmentThumbShape",segmentThumbSize:"segmentThumbSize",selectedItems:"selectedItems",serializationSettings:"serializationSettings",setNodeTemplate:"setNodeTemplate",snapSettings:"snapSettings",tool:"tool",tooltip:"tooltip",updateSelection:"updateSelection",userHandleTemplate:"userHandleTemplate",width:"width"},outputs:{animationComplete:"animationComplete",click:"click",collectionChange:"collectionChange",commandExecute:"commandExecute",connectionChange:"connectionChange",contextMenuBeforeItemRender:"contextMenuBeforeItemRender",contextMenuClick:"contextMenuClick",contextMenuOpen:"contextMenuOpen",created:"created",dataLoaded:"dataLoaded",doubleClick:"doubleClick",dragEnter:"dragEnter",dragLeave:"dragLeave",dragOver:"dragOver",drop:"drop",elementDraw:"elementDraw",expandStateChange:"expandStateChange",fixedUserHandleClick:"fixedUserHandleClick",historyChange:"historyChange",historyStateChange:"historyStateChange",keyDown:"keyDown",keyUp:"keyUp",load:"load",loaded:"loaded",mouseEnter:"mouseEnter",mouseLeave:"mouseLeave",mouseOver:"mouseOver",mouseWheel:"mouseWheel",onFixedUserHandleMouseDown:"onFixedUserHandleMouseDown",onFixedUserHandleMouseEnter:"onFixedUserHandleMouseEnter",onFixedUserHandleMouseLeave:"onFixedUserHandleMouseLeave",onFixedUserHandleMouseUp:"onFixedUserHandleMouseUp",onImageLoad:"onImageLoad",onUserHandleMouseDown:"onUserHandleMouseDown",onUserHandleMouseEnter:"onUserHandleMouseEnter",onUserHandleMouseLeave:"onUserHandleMouseLeave",onUserHandleMouseUp:"onUserHandleMouseUp",positionChange:"positionChange",propertyChange:"propertyChange",rotateChange:"rotateChange",scrollChange:"scrollChange",segmentChange:"segmentChange",segmentCollectionChange:"segmentCollectionChange",selectionChange:"selectionChange",sizeChange:"sizeChange",sourcePointChange:"sourcePointChange",targetPointChange:"targetPointChange",textEdit:"textEdit"},features:[yn],decls:0,vars:0,template:function(e,i){},encapsulation:2,changeDetection:0}),P0([TC()],n.prototype,"annotationTemplate",void 0),P0([TC()],n.prototype,"nodeTemplate",void 0),P0([TC()],n.prototype,"userHandleTemplate",void 0),n=P0([PZ([SR])],n),n})(),Lle=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=km({type:n}),n.\u0275inj=yp({imports:[[sq]]}),n})();const Nle=["diagram"];let Ole=(()=>{class n{constructor(){this.layers=[]}ngOnInit(){this.layers=[{id:"layer1",objects:["node1"]},{id:"layers2",objects:["node2"]},{id:"layers3",objects:["node3"]}]}bringLayerForward(){this.diagram.bringLayerForward("layer1")}sendLayerBackward(){this.diagram.sendLayerBackward("layer1")}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275cmp=Ub({type:n,selectors:[["app-container"]],viewQuery:function(i,r){if(1&i&&function fP(n,t,e){const i=Ti();i.firstCreatePass&&(dP(i,new lP(n,t,e),-1),2==(2&t)&&(i.staticViewQueries=!0)),cP(i,Se(),t)}(Nle,5),2&i){let s;Kr(s=en())&&(r.diagram=s.first)}},standalone:!0,features:[PP([]),RP],decls:16,vars:13,consts:[[3,"click"],["id","diagram","width","100%","height","580px",3,"layers"],["diagram",""],["id","node1",3,"width","height","offsetX","offsetY"],["content","Layer 1 Object"],["id","node2",3,"width","height","offsetX","offsetY"],["content","Layer 2 Object"],["id","node3",3,"width","height","offsetX","offsetY"],["content","Layer 3 Object"]],template:function(i,r){1&i&&(nc(0,"button",0),Xy("click",function(){return r.bringLayerForward()}),vw(1,"bringLayerForward"),sc(),nc(2,"button",0),Xy("click",function(){return r.sendLayerBackward()}),vw(3,"sendLayerBackward"),sc(),nc(4,"ejs-diagram",1,2)(6,"e-nodes")(7,"e-node",3)(8,"e-node-annotations"),ug(9,"e-node-annotation",4),sc()(),nc(10,"e-node",5)(11,"e-node-annotations"),ug(12,"e-node-annotation",6),sc()(),nc(13,"e-node",7)(14,"e-node-annotations"),ug(15,"e-node-annotation",8),sc()()()()),2&i&&(Xp(4),qu("layers",r.layers),Xp(3),qu("width",100)("height",100)("offsetX",100)("offsetY",100),Xp(3),qu("width",100)("height",100)("offsetX",130)("offsetY",130),Xp(3),qu("width",100)("height",100)("offsetX",160)("offsetY",160))},dependencies:[Lle,Ale,v_,m_,y_,S_],encapsulation:2})}}return n})();Wd(332),function $q(n,t){return DG({rootComponent:n,...Ez(t)})}(Ole).catch(n=>console.error(n))},332:()=>{!function(Z){const se=Z.performance;function ye(zi){se&&se.mark&&se.mark(zi)}function pe(zi,ht){se&&se.measure&&se.measure(zi,ht)}ye("Zone");const be=Z.__Zone_symbol_prefix||"__zone_symbol__";function ke(zi){return be+zi}const at=!0===Z[ke("forceDuplicateZoneCheck")];if(Z.Zone){if(at||"function"!=typeof Z.Zone.__symbol__)throw new Error("Zone already loaded.");return Z.Zone}let tt=(()=>{class zi{static{this.__symbol__=ke}static assertZonePatched(){if(Z.Promise!==_o.ZoneAwarePromise)throw new Error("Zone.js has detected that ZoneAwarePromise `(window|global).Promise` has been overwritten.\nMost likely cause is that a Promise polyfill has been loaded after Zone.js (Polyfilling Promise api is not necessary when zone.js is loaded. If you must load one, do so before loading zone.js.)")}static get root(){let F=zi.current;for(;F.parent;)F=F.parent;return F}static get current(){return Ur.zone}static get currentTask(){return Do}static __load_patch(F,ae,Et=!1){if(_o.hasOwnProperty(F)){if(!Et&&at)throw Error("Already loaded patch: "+F)}else if(!Z["__Zone_disable_"+F]){const Xt="Zone:"+F;ye(Xt),_o[F]=ae(Z,zi,cn),pe(Xt,Xt)}}get parent(){return this._parent}get name(){return this._name}constructor(F,ae){this._parent=F,this._name=ae?ae.name||"unnamed":"",this._properties=ae&&ae.properties||{},this._zoneDelegate=new Lt(this,this._parent&&this._parent._zoneDelegate,ae)}get(F){const ae=this.getZoneWith(F);if(ae)return ae._properties[F]}getZoneWith(F){let ae=this;for(;ae;){if(ae._properties.hasOwnProperty(F))return ae;ae=ae._parent}return null}fork(F){if(!F)throw new Error("ZoneSpec required!");return this._zoneDelegate.fork(this,F)}wrap(F,ae){if("function"!=typeof F)throw new Error("Expecting function got: "+F);const Et=this._zoneDelegate.intercept(this,F,ae),Xt=this;return function(){return Xt.runGuarded(Et,this,arguments,ae)}}run(F,ae,Et,Xt){Ur={parent:Ur,zone:this};try{return this._zoneDelegate.invoke(this,F,ae,Et,Xt)}finally{Ur=Ur.parent}}runGuarded(F,ae=null,Et,Xt){Ur={parent:Ur,zone:this};try{try{return this._zoneDelegate.invoke(this,F,ae,Et,Xt)}catch(Vn){if(this._zoneDelegate.handleError(this,Vn))throw Vn}}finally{Ur=Ur.parent}}runTask(F,ae,Et){if(F.zone!=this)throw new Error("A task can only be run in the zone of creation! (Creation: "+(F.zone||jn).name+"; Execution: "+this.name+")");if(F.state===sr&&(F.type===rs||F.type===Pt))return;const Xt=F.state!=lt;Xt&&F._transitionTo(lt,Pi),F.runCount++;const Vn=Do;Do=F,Ur={parent:Ur,zone:this};try{F.type==Pt&&F.data&&!F.data.isPeriodic&&(F.cancelFn=void 0);try{return this._zoneDelegate.invokeTask(this,F,ae,Et)}catch(Ue){if(this._zoneDelegate.handleError(this,Ue))throw Ue}}finally{F.state!==sr&&F.state!==et&&(F.type==rs||F.data&&F.data.isPeriodic?Xt&&F._transitionTo(Pi,lt):(F.runCount=0,this._updateTaskCount(F,-1),Xt&&F._transitionTo(sr,lt,sr))),Ur=Ur.parent,Do=Vn}}scheduleTask(F){if(F.zone&&F.zone!==this){let Et=this;for(;Et;){if(Et===F.zone)throw Error(`can not reschedule task to ${this.name} which is descendants of the original zone ${F.zone.name}`);Et=Et.parent}}F._transitionTo(Zr,sr);const ae=[];F._zoneDelegates=ae,F._zone=this;try{F=this._zoneDelegate.scheduleTask(this,F)}catch(Et){throw F._transitionTo(et,Zr,sr),this._zoneDelegate.handleError(this,Et),Et}return F._zoneDelegates===ae&&this._updateTaskCount(F,1),F.state==Zr&&F._transitionTo(Pi,Zr),F}scheduleMicroTask(F,ae,Et,Xt){return this.scheduleTask(new pt(yi,F,ae,Et,Xt,void 0))}scheduleMacroTask(F,ae,Et,Xt,Vn){return this.scheduleTask(new pt(Pt,F,ae,Et,Xt,Vn))}scheduleEventTask(F,ae,Et,Xt,Vn){return this.scheduleTask(new pt(rs,F,ae,Et,Xt,Vn))}cancelTask(F){if(F.zone!=this)throw new Error("A task can only be cancelled in the zone of creation! (Creation: "+(F.zone||jn).name+"; Execution: "+this.name+")");if(F.state===Pi||F.state===lt){F._transitionTo(dr,Pi,lt);try{this._zoneDelegate.cancelTask(this,F)}catch(ae){throw F._transitionTo(et,dr),this._zoneDelegate.handleError(this,ae),ae}return this._updateTaskCount(F,-1),F._transitionTo(sr,dr),F.runCount=0,F}}_updateTaskCount(F,ae){const Et=F._zoneDelegates;-1==ae&&(F._zoneDelegates=null);for(let Xt=0;Xtzi.hasTask(F,ae),onScheduleTask:(zi,ht,F,ae)=>zi.scheduleTask(F,ae),onInvokeTask:(zi,ht,F,ae,Et,Xt)=>zi.invokeTask(F,ae,Et,Xt),onCancelTask:(zi,ht,F,ae)=>zi.cancelTask(F,ae)};class Lt{constructor(ht,F,ae){this._taskCounts={microTask:0,macroTask:0,eventTask:0},this.zone=ht,this._parentDelegate=F,this._forkZS=ae&&(ae&&ae.onFork?ae:F._forkZS),this._forkDlgt=ae&&(ae.onFork?F:F._forkDlgt),this._forkCurrZone=ae&&(ae.onFork?this.zone:F._forkCurrZone),this._interceptZS=ae&&(ae.onIntercept?ae:F._interceptZS),this._interceptDlgt=ae&&(ae.onIntercept?F:F._interceptDlgt),this._interceptCurrZone=ae&&(ae.onIntercept?this.zone:F._interceptCurrZone),this._invokeZS=ae&&(ae.onInvoke?ae:F._invokeZS),this._invokeDlgt=ae&&(ae.onInvoke?F:F._invokeDlgt),this._invokeCurrZone=ae&&(ae.onInvoke?this.zone:F._invokeCurrZone),this._handleErrorZS=ae&&(ae.onHandleError?ae:F._handleErrorZS),this._handleErrorDlgt=ae&&(ae.onHandleError?F:F._handleErrorDlgt),this._handleErrorCurrZone=ae&&(ae.onHandleError?this.zone:F._handleErrorCurrZone),this._scheduleTaskZS=ae&&(ae.onScheduleTask?ae:F._scheduleTaskZS),this._scheduleTaskDlgt=ae&&(ae.onScheduleTask?F:F._scheduleTaskDlgt),this._scheduleTaskCurrZone=ae&&(ae.onScheduleTask?this.zone:F._scheduleTaskCurrZone),this._invokeTaskZS=ae&&(ae.onInvokeTask?ae:F._invokeTaskZS),this._invokeTaskDlgt=ae&&(ae.onInvokeTask?F:F._invokeTaskDlgt),this._invokeTaskCurrZone=ae&&(ae.onInvokeTask?this.zone:F._invokeTaskCurrZone),this._cancelTaskZS=ae&&(ae.onCancelTask?ae:F._cancelTaskZS),this._cancelTaskDlgt=ae&&(ae.onCancelTask?F:F._cancelTaskDlgt),this._cancelTaskCurrZone=ae&&(ae.onCancelTask?this.zone:F._cancelTaskCurrZone),this._hasTaskZS=null,this._hasTaskDlgt=null,this._hasTaskDlgtOwner=null,this._hasTaskCurrZone=null;const Et=ae&&ae.onHasTask;(Et||F&&F._hasTaskZS)&&(this._hasTaskZS=Et?ae:At,this._hasTaskDlgt=F,this._hasTaskDlgtOwner=this,this._hasTaskCurrZone=ht,ae.onScheduleTask||(this._scheduleTaskZS=At,this._scheduleTaskDlgt=F,this._scheduleTaskCurrZone=this.zone),ae.onInvokeTask||(this._invokeTaskZS=At,this._invokeTaskDlgt=F,this._invokeTaskCurrZone=this.zone),ae.onCancelTask||(this._cancelTaskZS=At,this._cancelTaskDlgt=F,this._cancelTaskCurrZone=this.zone))}fork(ht,F){return this._forkZS?this._forkZS.onFork(this._forkDlgt,this.zone,ht,F):new tt(ht,F)}intercept(ht,F,ae){return this._interceptZS?this._interceptZS.onIntercept(this._interceptDlgt,this._interceptCurrZone,ht,F,ae):F}invoke(ht,F,ae,Et,Xt){return this._invokeZS?this._invokeZS.onInvoke(this._invokeDlgt,this._invokeCurrZone,ht,F,ae,Et,Xt):F.apply(ae,Et)}handleError(ht,F){return!this._handleErrorZS||this._handleErrorZS.onHandleError(this._handleErrorDlgt,this._handleErrorCurrZone,ht,F)}scheduleTask(ht,F){let ae=F;if(this._scheduleTaskZS)this._hasTaskZS&&ae._zoneDelegates.push(this._hasTaskDlgtOwner),ae=this._scheduleTaskZS.onScheduleTask(this._scheduleTaskDlgt,this._scheduleTaskCurrZone,ht,F),ae||(ae=F);else if(F.scheduleFn)F.scheduleFn(F);else{if(F.type!=yi)throw new Error("Task is missing scheduleFn.");Wt(F)}return ae}invokeTask(ht,F,ae,Et){return this._invokeTaskZS?this._invokeTaskZS.onInvokeTask(this._invokeTaskDlgt,this._invokeTaskCurrZone,ht,F,ae,Et):F.callback.apply(ae,Et)}cancelTask(ht,F){let ae;if(this._cancelTaskZS)ae=this._cancelTaskZS.onCancelTask(this._cancelTaskDlgt,this._cancelTaskCurrZone,ht,F);else{if(!F.cancelFn)throw Error("Task is not cancelable");ae=F.cancelFn(F)}return ae}hasTask(ht,F){try{this._hasTaskZS&&this._hasTaskZS.onHasTask(this._hasTaskDlgt,this._hasTaskCurrZone,ht,F)}catch(ae){this.handleError(ht,ae)}}_updateTaskCount(ht,F){const ae=this._taskCounts,Et=ae[ht],Xt=ae[ht]=Et+F;if(Xt<0)throw new Error("More tasks executed then were scheduled.");0!=Et&&0!=Xt||this.hasTask(this.zone,{microTask:ae.microTask>0,macroTask:ae.macroTask>0,eventTask:ae.eventTask>0,change:ht})}}class pt{constructor(ht,F,ae,Et,Xt,Vn){if(this._zone=null,this.runCount=0,this._zoneDelegates=null,this._state="notScheduled",this.type=ht,this.source=F,this.data=Et,this.scheduleFn=Xt,this.cancelFn=Vn,!ae)throw new Error("callback is not defined");this.callback=ae;const Ue=this;this.invoke=ht===rs&&Et&&Et.useG?pt.invokeTask:function(){return pt.invokeTask.call(Z,Ue,this,arguments)}}static invokeTask(ht,F,ae){ht||(ht=this),Ls++;try{return ht.runCount++,ht.zone.runTask(ht,F,ae)}finally{1==Ls&&ct(),Ls--}}get zone(){return this._zone}get state(){return this._state}cancelScheduleRequest(){this._transitionTo(sr,Zr)}_transitionTo(ht,F,ae){if(this._state!==F&&this._state!==ae)throw new Error(`${this.type} '${this.source}': can not transition to '${ht}', expecting state '${F}'${ae?" or '"+ae+"'":""}, was '${this._state}'.`);this._state=ht,ht==sr&&(this._zoneDelegates=null)}toString(){return this.data&&typeof this.data.handleId<"u"?this.data.handleId.toString():Object.prototype.toString.call(this)}toJSON(){return{type:this.type,state:this.state,source:this.source,zone:this.zone.name,runCount:this.runCount}}}const Di=ke("setTimeout"),ni=ke("Promise"),mi=ke("then");let is,cr=[],ki=!1;function Pr(zi){if(is||Z[ni]&&(is=Z[ni].resolve(0)),is){let ht=is[mi];ht||(ht=is.then),ht.call(is,zi)}else Z[Di](zi,0)}function Wt(zi){0===Ls&&0===cr.length&&Pr(ct),zi&&cr.push(zi)}function ct(){if(!ki){for(ki=!0;cr.length;){const zi=cr;cr=[];for(let ht=0;htUr,onUnhandledError:jr,microtaskDrainDone:jr,scheduleMicroTask:Wt,showUncaughtError:()=>!tt[ke("ignoreConsoleErrorUncaughtError")],patchEventTarget:()=>[],patchOnProperties:jr,patchMethod:()=>jr,bindArguments:()=>[],patchThen:()=>jr,patchMacroTask:()=>jr,patchEventPrototype:()=>jr,isIEOrEdge:()=>!1,getGlobalObjects:()=>{},ObjectDefineProperty:()=>jr,ObjectGetOwnPropertyDescriptor:()=>{},ObjectCreate:()=>{},ArraySlice:()=>[],patchClass:()=>jr,wrapWithCurrentZone:()=>jr,filterProperties:()=>[],attachOriginToPatched:()=>jr,_redefineProperty:()=>jr,patchCallbacks:()=>jr,nativeScheduleMicroTask:Pr};let Ur={parent:null,zone:new tt(null,null)},Do=null,Ls=0;function jr(){}pe("Zone","Zone"),Z.Zone=tt}(globalThis);const Wl=Object.getOwnPropertyDescriptor,Vd=Object.defineProperty,Wd=Object.getPrototypeOf,Yd=Object.create,Ib=Array.prototype.slice,mm="addEventListener",$r="removeEventListener",Yl=Zone.__symbol__(mm),_h=Zone.__symbol__($r),Ts="true",Wi="false",Qd=Zone.__symbol__("");function hp(Z,se){return Zone.current.wrap(Z,se)}function ym(Z,se,ye,pe,be){return Zone.current.scheduleMacroTask(Z,se,ye,pe,be)}const Ji=Zone.__symbol__,Uh=typeof window<"u",jh=Uh?window:void 0,gn=Uh&&jh||globalThis,Sm="removeAttribute";function Gd(Z,se){for(let ye=Z.length-1;ye>=0;ye--)"function"==typeof Z[ye]&&(Z[ye]=hp(Z[ye],se+"_"+ye));return Z}function cp(Z){return!Z||!1!==Z.writable&&!("function"==typeof Z.get&&typeof Z.set>"u")}const dp=typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope,Vh=!("nw"in gn)&&typeof gn.process<"u"&&"[object process]"==={}.toString.call(gn.process),Xd=!Vh&&!dp&&!(!Uh||!jh.HTMLElement),up=typeof gn.process<"u"&&"[object process]"==={}.toString.call(gn.process)&&!dp&&!(!Uh||!jh.HTMLElement),Ql={},Wh=function(Z){if(!(Z=Z||gn.event))return;let se=Ql[Z.type];se||(se=Ql[Z.type]=Ji("ON_PROPERTY"+Z.type));const ye=this||Z.target||gn,pe=ye[se];let be;return Xd&&ye===jh&&"error"===Z.type?(be=pe&&pe.call(this,Z.message,Z.filename,Z.lineno,Z.colno,Z.error),!0===be&&Z.preventDefault()):(be=pe&&pe.apply(this,arguments),null!=be&&!be&&Z.preventDefault()),be};function Gl(Z,se,ye){let pe=Wl(Z,se);if(!pe&&ye&&Wl(ye,se)&&(pe={enumerable:!0,configurable:!0}),!pe||!pe.configurable)return;const be=Ji("on"+se+"patched");if(Z.hasOwnProperty(be)&&Z[be])return;delete pe.writable,delete pe.value;const ke=pe.get,at=pe.set,tt=se.slice(2);let At=Ql[tt];At||(At=Ql[tt]=Ji("ON_PROPERTY"+tt)),pe.set=function(Lt){let pt=this;!pt&&Z===gn&&(pt=gn),pt&&("function"==typeof pt[At]&&pt.removeEventListener(tt,Wh),at&&at.call(pt,null),pt[At]=Lt,"function"==typeof Lt&&pt.addEventListener(tt,Wh,!1))},pe.get=function(){let Lt=this;if(!Lt&&Z===gn&&(Lt=gn),!Lt)return null;const pt=Lt[At];if(pt)return pt;if(ke){let Di=ke.call(this);if(Di)return pe.set.call(this,Di),"function"==typeof Lt[Sm]&&Lt.removeAttribute(se),Di}return null},Vd(Z,se,pe),Z[be]=!0}function fp(Z,se,ye){if(se)for(let pe=0;pefunction(at,tt){const At=ye(at,tt);return At.cbIdx>=0&&"function"==typeof tt[At.cbIdx]?ym(At.name,tt[At.cbIdx],At,be):ke.apply(at,tt)})}function Ia(Z,se){Z[Ji("OriginalDelegate")]=se}let Mb=!1,$d=!1;function wb(){if(Mb)return $d;Mb=!0;try{const Z=jh.navigator.userAgent;(-1!==Z.indexOf("MSIE ")||-1!==Z.indexOf("Trident/")||-1!==Z.indexOf("Edge/"))&&($d=!0)}catch{}return $d}Zone.__load_patch("ZoneAwarePromise",(Z,se,ye)=>{const pe=Object.getOwnPropertyDescriptor,be=Object.defineProperty,at=ye.symbol,tt=[],At=!1!==Z[at("DISABLE_WRAPPING_UNCAUGHT_PROMISE_REJECTION")],Lt=at("Promise"),pt=at("then"),Di="__creationTrace__";ye.onUnhandledError=Ue=>{if(ye.showUncaughtError()){const He=Ue&&Ue.rejection;He?console.error("Unhandled Promise rejection:",He instanceof Error?He.message:He,"; Zone:",Ue.zone.name,"; Task:",Ue.task&&Ue.task.source,"; Value:",He,He instanceof Error?He.stack:void 0):console.error(Ue)}},ye.microtaskDrainDone=()=>{for(;tt.length;){const Ue=tt.shift();try{Ue.zone.runGuarded(()=>{throw Ue.throwOriginal?Ue.rejection:Ue})}catch(He){mi(He)}}};const ni=at("unhandledPromiseRejectionHandler");function mi(Ue){ye.onUnhandledError(Ue);try{const He=se[ni];"function"==typeof He&&He.call(this,Ue)}catch{}}function cr(Ue){return Ue&&Ue.then}function ki(Ue){return Ue}function is(Ue){return F.reject(Ue)}const Pr=at("state"),Wt=at("value"),ct=at("finally"),jn=at("parentPromiseValue"),sr=at("parentPromiseState"),Zr="Promise.then",Pi=null,lt=!0,dr=!1,et=0;function yi(Ue,He){return ge=>{try{cn(Ue,He,ge)}catch(We){cn(Ue,!1,We)}}}const Pt=function(){let Ue=!1;return function(ge){return function(){Ue||(Ue=!0,ge.apply(null,arguments))}}},rs="Promise resolved with itself",_o=at("currentTaskTrace");function cn(Ue,He,ge){const We=Pt();if(Ue===ge)throw new TypeError(rs);if(Ue[Pr]===Pi){let wt=null;try{("object"==typeof ge||"function"==typeof ge)&&(wt=ge&&ge.then)}catch(Xe){return We(()=>{cn(Ue,!1,Xe)})(),Ue}if(He!==dr&&ge instanceof F&&ge.hasOwnProperty(Pr)&&ge.hasOwnProperty(Wt)&&ge[Pr]!==Pi)Do(ge),cn(Ue,ge[Pr],ge[Wt]);else if(He!==dr&&"function"==typeof wt)try{wt.call(ge,We(yi(Ue,He)),We(yi(Ue,!1)))}catch(Xe){We(()=>{cn(Ue,!1,Xe)})()}else{Ue[Pr]=He;const Xe=Ue[Wt];if(Ue[Wt]=ge,Ue[ct]===ct&&He===lt&&(Ue[Pr]=Ue[sr],Ue[Wt]=Ue[jn]),He===dr&&ge instanceof Error){const mt=se.currentTask&&se.currentTask.data&&se.currentTask.data[Di];mt&&be(ge,_o,{configurable:!0,enumerable:!1,writable:!0,value:mt})}for(let mt=0;mt{try{const dt=Ue[Wt],qt=!!ge&&ct===ge[ct];qt&&(ge[jn]=dt,ge[sr]=Xe);const li=He.run(mt,void 0,qt&&mt!==is&&mt!==ki?[]:[dt]);cn(ge,!0,li)}catch(dt){cn(ge,!1,dt)}},ge)}const zi=function(){},ht=Z.AggregateError;class F{static toString(){return"function ZoneAwarePromise() { [native code] }"}static resolve(He){return He instanceof F?He:cn(new this(null),lt,He)}static reject(He){return cn(new this(null),dr,He)}static withResolvers(){const He={};return He.promise=new F((ge,We)=>{He.resolve=ge,He.reject=We}),He}static any(He){if(!He||"function"!=typeof He[Symbol.iterator])return Promise.reject(new ht([],"All promises were rejected"));const ge=[];let We=0;try{for(let mt of He)We++,ge.push(F.resolve(mt))}catch{return Promise.reject(new ht([],"All promises were rejected"))}if(0===We)return Promise.reject(new ht([],"All promises were rejected"));let wt=!1;const Xe=[];return new F((mt,dt)=>{for(let qt=0;qt{wt||(wt=!0,mt(li))},li=>{Xe.push(li),We--,0===We&&(wt=!0,dt(new ht(Xe,"All promises were rejected")))})})}static race(He){let ge,We,wt=new this((dt,qt)=>{ge=dt,We=qt});function Xe(dt){ge(dt)}function mt(dt){We(dt)}for(let dt of He)cr(dt)||(dt=this.resolve(dt)),dt.then(Xe,mt);return wt}static all(He){return F.allWithCallback(He)}static allSettled(He){return(this&&this.prototype instanceof F?this:F).allWithCallback(He,{thenCallback:We=>({status:"fulfilled",value:We}),errorCallback:We=>({status:"rejected",reason:We})})}static allWithCallback(He,ge){let We,wt,Xe=new this((li,ur)=>{We=li,wt=ur}),mt=2,dt=0;const qt=[];for(let li of He){cr(li)||(li=this.resolve(li));const ur=dt;try{li.then(ir=>{qt[ur]=ge?ge.thenCallback(ir):ir,mt--,0===mt&&We(qt)},ir=>{ge?(qt[ur]=ge.errorCallback(ir),mt--,0===mt&&We(qt)):wt(ir)})}catch(ir){wt(ir)}mt++,dt++}return mt-=2,0===mt&&We(qt),Xe}constructor(He){const ge=this;if(!(ge instanceof F))throw new Error("Must be an instanceof Promise.");ge[Pr]=Pi,ge[Wt]=[];try{const We=Pt();He&&He(We(yi(ge,lt)),We(yi(ge,dr)))}catch(We){cn(ge,!1,We)}}get[Symbol.toStringTag](){return"Promise"}get[Symbol.species](){return F}then(He,ge){let We=this.constructor?.[Symbol.species];(!We||"function"!=typeof We)&&(We=this.constructor||F);const wt=new We(zi),Xe=se.current;return this[Pr]==Pi?this[Wt].push(Xe,wt,He,ge):Ls(this,Xe,wt,He,ge),wt}catch(He){return this.then(null,He)}finally(He){let ge=this.constructor?.[Symbol.species];(!ge||"function"!=typeof ge)&&(ge=F);const We=new ge(zi);We[ct]=ct;const wt=se.current;return this[Pr]==Pi?this[Wt].push(wt,We,He,He):Ls(this,wt,We,He,He),We}}F.resolve=F.resolve,F.reject=F.reject,F.race=F.race,F.all=F.all;const ae=Z[Lt]=Z.Promise;Z.Promise=F;const Et=at("thenPatched");function Xt(Ue){const He=Ue.prototype,ge=pe(He,"then");if(ge&&(!1===ge.writable||!ge.configurable))return;const We=He.then;He[pt]=We,Ue.prototype.then=function(wt,Xe){return new F((dt,qt)=>{We.call(this,dt,qt)}).then(wt,Xe)},Ue[Et]=!0}return ye.patchThen=Xt,ae&&(Xt(ae),tl(Z,"fetch",Ue=>function Vn(Ue){return function(He,ge){let We=Ue.apply(He,ge);if(We instanceof F)return We;let wt=We.constructor;return wt[Et]||Xt(wt),We}}(Ue))),Promise[se.__symbol__("uncaughtPromiseErrors")]=tt,F}),Zone.__load_patch("toString",Z=>{const se=Function.prototype.toString,ye=Ji("OriginalDelegate"),pe=Ji("Promise"),be=Ji("Error"),ke=function(){if("function"==typeof this){const Lt=this[ye];if(Lt)return"function"==typeof Lt?se.call(Lt):Object.prototype.toString.call(Lt);if(this===Promise){const pt=Z[pe];if(pt)return se.call(pt)}if(this===Error){const pt=Z[be];if(pt)return se.call(pt)}}return se.call(this)};ke[ye]=se,Function.prototype.toString=ke;const at=Object.prototype.toString;Object.prototype.toString=function(){return"function"==typeof Promise&&this instanceof Promise?"[object Promise]":at.call(this)}});let il=!1;if(typeof window<"u")try{const Z=Object.defineProperty({},"passive",{get:function(){il=!0}});window.addEventListener("test",Z,Z),window.removeEventListener("test",Z,Z)}catch{il=!1}const zT={useG:!0},Co={},Cb={},Mm=new RegExp("^"+Qd+"(\\w+)(true|false)$"),Eb=Ji("propagationStopped");function wm(Z,se){const ye=(se?se(Z):Z)+Wi,pe=(se?se(Z):Z)+Ts,be=Qd+ye,ke=Qd+pe;Co[Z]={},Co[Z][Wi]=be,Co[Z][Ts]=ke}function Db(Z,se,ye,pe){const be=pe&&pe.add||mm,ke=pe&&pe.rm||$r,at=pe&&pe.listeners||"eventListeners",tt=pe&&pe.rmAll||"removeAllListeners",At=Ji(be),Lt="."+be+":",pt="prependListener",Di="."+pt+":",ni=function(Wt,ct,jn){if(Wt.isRemoved)return;const sr=Wt.callback;let Zr;"object"==typeof sr&&sr.handleEvent&&(Wt.callback=lt=>sr.handleEvent(lt),Wt.originalDelegate=sr);try{Wt.invoke(Wt,ct,[jn])}catch(lt){Zr=lt}const Pi=Wt.options;return Pi&&"object"==typeof Pi&&Pi.once&&ct[ke].call(ct,jn.type,Wt.originalDelegate?Wt.originalDelegate:Wt.callback,Pi),Zr};function mi(Wt,ct,jn){if(!(ct=ct||Z.event))return;const sr=Wt||ct.target||Z,Zr=sr[Co[ct.type][jn?Ts:Wi]];if(Zr){const Pi=[];if(1===Zr.length){const lt=ni(Zr[0],sr,ct);lt&&Pi.push(lt)}else{const lt=Zr.slice();for(let dr=0;dr{throw dr})}}}const cr=function(Wt){return mi(this,Wt,!1)},ki=function(Wt){return mi(this,Wt,!0)};function is(Wt,ct){if(!Wt)return!1;let jn=!0;ct&&void 0!==ct.useG&&(jn=ct.useG);const sr=ct&&ct.vh;let Zr=!0;ct&&void 0!==ct.chkDup&&(Zr=ct.chkDup);let Pi=!1;ct&&void 0!==ct.rt&&(Pi=ct.rt);let lt=Wt;for(;lt&&!lt.hasOwnProperty(be);)lt=Wd(lt);if(!lt&&Wt[be]&&(lt=Wt),!lt||lt[At])return!1;const dr=ct&&ct.eventNameToString,et={},yi=lt[At]=lt[be],Pt=lt[Ji(ke)]=lt[ke],rs=lt[Ji(at)]=lt[at],_o=lt[Ji(tt)]=lt[tt];let cn;ct&&ct.prepend&&(cn=lt[Ji(ct.prepend)]=lt[ct.prepend]);const F=jn?function(ge){if(!et.isExisting)return yi.call(et.target,et.eventName,et.capture?ki:cr,et.options)}:function(ge){return yi.call(et.target,et.eventName,ge.invoke,et.options)},ae=jn?function(ge){if(!ge.isRemoved){const We=Co[ge.eventName];let wt;We&&(wt=We[ge.capture?Ts:Wi]);const Xe=wt&&ge.target[wt];if(Xe)for(let mt=0;mt{Vo.zone.cancelTask(Vo)},{once:!0})),et.target=null,Uc&&(Uc.taskData=null),Jd&&(Tn.once=!0),!il&&"boolean"==typeof Vo.options||(Vo.options=Tn),Vo.target=qt,Vo.capture=Zl,Vo.eventName=li,ir&&(Vo.originalDelegate=ur),dt?jo.unshift(Vo):jo.push(Vo),mt?qt:void 0}};return lt[be]=He(yi,Lt,F,ae,Pi),cn&&(lt[pt]=He(cn,Di,function(ge){return cn.call(et.target,et.eventName,ge.invoke,et.options)},ae,Pi,!0)),lt[ke]=function(){const ge=this||Z;let We=arguments[0];ct&&ct.transferEventName&&(We=ct.transferEventName(We));const wt=arguments[2],Xe=!!wt&&("boolean"==typeof wt||wt.capture),mt=arguments[1];if(!mt)return Pt.apply(this,arguments);if(sr&&!sr(Pt,mt,ge,arguments))return;const dt=Co[We];let qt;dt&&(qt=dt[Xe?Ts:Wi]);const li=qt&&ge[qt];if(li)for(let ur=0;urfunction(be,ke){be[Eb]=!0,pe&&pe.apply(be,ke)})}function Tb(Z,se,ye,pe,be){const ke=Zone.__symbol__(pe);if(se[ke])return;const at=se[ke]=se[pe];se[pe]=function(tt,At,Lt){return At&&At.prototype&&be.forEach(function(pt){const Di=`${ye}.${pe}::`+pt,ni=At.prototype;try{if(ni.hasOwnProperty(pt)){const mi=Z.ObjectGetOwnPropertyDescriptor(ni,pt);mi&&mi.value?(mi.value=Z.wrapWithCurrentZone(mi.value,Di),Z._redefineProperty(At.prototype,pt,mi)):ni[pt]&&(ni[pt]=Z.wrapWithCurrentZone(ni[pt],Di))}else ni[pt]&&(ni[pt]=Z.wrapWithCurrentZone(ni[pt],Di))}catch{}}),at.call(se,tt,At,Lt)},Z.attachOriginToPatched(se[pe],at)}function Ab(Z,se,ye){if(!ye||0===ye.length)return se;const pe=ye.filter(ke=>ke.target===Z);if(!pe||0===pe.length)return se;const be=pe[0].ignoreProperties;return se.filter(ke=>-1===be.indexOf(ke))}function Eo(Z,se,ye,pe){Z&&fp(Z,Ab(Z,se,ye),pe)}function Zd(Z){return Object.getOwnPropertyNames(Z).filter(se=>se.startsWith("on")&&se.length>2).map(se=>se.substring(2))}Zone.__load_patch("util",(Z,se,ye)=>{const pe=Zd(Z);ye.patchOnProperties=fp,ye.patchMethod=tl,ye.bindArguments=Gd,ye.patchMacroTask=bb;const be=se.__symbol__("BLACK_LISTED_EVENTS"),ke=se.__symbol__("UNPATCHED_EVENTS");Z[ke]&&(Z[be]=Z[ke]),Z[be]&&(se[be]=se[ke]=Z[be]),ye.patchEventPrototype=Cm,ye.patchEventTarget=Db,ye.isIEOrEdge=wb,ye.ObjectDefineProperty=Vd,ye.ObjectGetOwnPropertyDescriptor=Wl,ye.ObjectCreate=Yd,ye.ArraySlice=Ib,ye.patchClass=qd,ye.wrapWithCurrentZone=hp,ye.filterProperties=Ab,ye.attachOriginToPatched=Ia,ye._redefineProperty=Object.defineProperty,ye.patchCallbacks=Tb,ye.getGlobalObjects=()=>({globalSources:Cb,zoneSymbolEventNames:Co,eventNames:pe,isBrowser:Xd,isMix:up,isNode:Vh,TRUE_STR:Ts,FALSE_STR:Wi,ZONE_SYMBOL_PREFIX:Qd,ADD_EVENT_LISTENER_STR:mm,REMOVE_EVENT_LISTENER_STR:$r})});const As=Ji("zoneTask");function Xl(Z,se,ye,pe){let be=null,ke=null;ye+=pe;const at={};function tt(Lt){const pt=Lt.data;return pt.args[0]=function(){return Lt.invoke.apply(this,arguments)},pt.handleId=be.apply(Z,pt.args),Lt}function At(Lt){return ke.call(Z,Lt.data.handleId)}be=tl(Z,se+=pe,Lt=>function(pt,Di){if("function"==typeof Di[0]){const ni={isPeriodic:"Interval"===pe,delay:"Timeout"===pe||"Interval"===pe?Di[1]||0:void 0,args:Di},mi=Di[0];Di[0]=function(){try{return mi.apply(this,arguments)}finally{ni.isPeriodic||("number"==typeof ni.handleId?delete at[ni.handleId]:ni.handleId&&(ni.handleId[As]=null))}};const cr=ym(se,Di[0],ni,tt,At);if(!cr)return cr;const ki=cr.data.handleId;return"number"==typeof ki?at[ki]=cr:ki&&(ki[As]=cr),ki&&ki.ref&&ki.unref&&"function"==typeof ki.ref&&"function"==typeof ki.unref&&(cr.ref=ki.ref.bind(ki),cr.unref=ki.unref.bind(ki)),"number"==typeof ki||ki?ki:cr}return Lt.apply(Z,Di)}),ke=tl(Z,ye,Lt=>function(pt,Di){const ni=Di[0];let mi;"number"==typeof ni?mi=at[ni]:(mi=ni&&ni[As],mi||(mi=ni)),mi&&"string"==typeof mi.type?"notScheduled"!==mi.state&&(mi.cancelFn&&mi.data.isPeriodic||0===mi.runCount)&&("number"==typeof ni?delete at[ni]:ni&&(ni[As]=null),mi.zone.cancelTask(mi)):Lt.apply(Z,Di)})}Zone.__load_patch("legacy",Z=>{const se=Z[Zone.__symbol__("legacyPatch")];se&&se()}),Zone.__load_patch("timers",Z=>{const ye="clear";Xl(Z,"set",ye,"Timeout"),Xl(Z,"set",ye,"Interval"),Xl(Z,"set",ye,"Immediate")}),Zone.__load_patch("requestAnimationFrame",Z=>{Xl(Z,"request","cancel","AnimationFrame"),Xl(Z,"mozRequest","mozCancel","AnimationFrame"),Xl(Z,"webkitRequest","webkitCancel","AnimationFrame")}),Zone.__load_patch("blocking",(Z,se)=>{const ye=["alert","prompt","confirm"];for(let pe=0;pefunction(At,Lt){return se.current.run(ke,Z,Lt,tt)})}),Zone.__load_patch("EventTarget",(Z,se,ye)=>{(function ql(Z,se){se.patchEventPrototype(Z,se)})(Z,ye),function Dm(Z,se){if(Zone[se.symbol("patchEventTarget")])return;const{eventNames:ye,zoneSymbolEventNames:pe,TRUE_STR:be,FALSE_STR:ke,ZONE_SYMBOL_PREFIX:at}=se.getGlobalObjects();for(let At=0;At{qd("MutationObserver"),qd("WebKitMutationObserver")}),Zone.__load_patch("IntersectionObserver",(Z,se,ye)=>{qd("IntersectionObserver")}),Zone.__load_patch("FileReader",(Z,se,ye)=>{qd("FileReader")}),Zone.__load_patch("on_property",(Z,se,ye)=>{!function pp(Z,se){if(Vh&&!up||Zone[Z.symbol("patchEvents")])return;const ye=se.__Zone_ignore_on_properties;let pe=[];if(Xd){const be=window;pe=pe.concat(["Document","SVGElement","Element","HTMLElement","HTMLBodyElement","HTMLMediaElement","HTMLFrameSetElement","HTMLFrameElement","HTMLIFrameElement","HTMLMarqueeElement","Worker"]);const ke=function bm(){try{const Z=jh.navigator.userAgent;if(-1!==Z.indexOf("MSIE ")||-1!==Z.indexOf("Trident/"))return!0}catch{}return!1}()?[{target:be,ignoreProperties:["error"]}]:[];Eo(be,Zd(be),ye&&ye.concat(ke),Wd(be))}pe=pe.concat(["XMLHttpRequest","XMLHttpRequestEventTarget","IDBIndex","IDBRequest","IDBOpenDBRequest","IDBDatabase","IDBTransaction","IDBCursor","WebSocket"]);for(let be=0;be{!function Em(Z,se){const{isBrowser:ye,isMix:pe}=se.getGlobalObjects();(ye||pe)&&Z.customElements&&"customElements"in Z&&se.patchCallbacks(se,Z.customElements,"customElements","define",["connectedCallback","disconnectedCallback","adoptedCallback","attributeChangedCallback"])}(Z,ye)}),Zone.__load_patch("XHR",(Z,se)=>{!function At(Lt){const pt=Lt.XMLHttpRequest;if(!pt)return;const Di=pt.prototype;let mi=Di[Yl],cr=Di[_h];if(!mi){const et=Lt.XMLHttpRequestEventTarget;if(et){const yi=et.prototype;mi=yi[Yl],cr=yi[_h]}}const ki="readystatechange",is="scheduled";function Pr(et){const yi=et.data,Pt=yi.target;Pt[ke]=!1,Pt[tt]=!1;const rs=Pt[be];mi||(mi=Pt[Yl],cr=Pt[_h]),rs&&cr.call(Pt,ki,rs);const _o=Pt[be]=()=>{if(Pt.readyState===Pt.DONE)if(!yi.aborted&&Pt[ke]&&et.state===is){const Ur=Pt[se.__symbol__("loadfalse")];if(0!==Pt.status&&Ur&&Ur.length>0){const Do=et.invoke;et.invoke=function(){const Ls=Pt[se.__symbol__("loadfalse")];for(let jr=0;jrfunction(et,yi){return et[pe]=0==yi[2],et[at]=yi[1],jn.apply(et,yi)}),Zr=Ji("fetchTaskAborting"),Pi=Ji("fetchTaskScheduling"),lt=tl(Di,"send",()=>function(et,yi){if(!0===se.current[Pi]||et[pe])return lt.apply(et,yi);{const Pt={target:et,url:et[at],isPeriodic:!1,args:yi,aborted:!1},rs=ym("XMLHttpRequest.send",Wt,Pt,Pr,ct);et&&!0===et[tt]&&!Pt.aborted&&rs.state===is&&rs.invoke()}}),dr=tl(Di,"abort",()=>function(et,yi){const Pt=function ni(et){return et[ye]}(et);if(Pt&&"string"==typeof Pt.type){if(null==Pt.cancelFn||Pt.data&&Pt.data.aborted)return;Pt.zone.cancelTask(Pt)}else if(!0===se.current[Zr])return dr.apply(et,yi)})}(Z);const ye=Ji("xhrTask"),pe=Ji("xhrSync"),be=Ji("xhrListener"),ke=Ji("xhrScheduled"),at=Ji("xhrURL"),tt=Ji("xhrErrorBeforeScheduled")}),Zone.__load_patch("geolocation",Z=>{Z.navigator&&Z.navigator.geolocation&&function Im(Z,se){const ye=Z.constructor.name;for(let pe=0;pe{const At=function(){return tt.apply(this,Gd(arguments,ye+"."+be))};return Ia(At,tt),At})(ke)}}}(Z.navigator.geolocation,["getCurrentPosition","watchPosition"])}),Zone.__load_patch("PromiseRejectionEvent",(Z,se)=>{function ye(pe){return function(be){xb(Z,pe).forEach(at=>{const tt=Z.PromiseRejectionEvent;if(tt){const At=new tt(pe,{promise:be.promise,reason:be.rejection});at.invoke(At)}})}}Z.PromiseRejectionEvent&&(se[Ji("unhandledPromiseRejectionHandler")]=ye("unhandledrejection"),se[Ji("rejectionHandledHandler")]=ye("rejectionhandled"))}),Zone.__load_patch("queueMicrotask",(Z,se,ye)=>{!function gp(Z,se){se.patchMethod(Z,"queueMicrotask",ye=>function(pe,be){Zone.current.scheduleMicroTask("queueMicrotask",be[0])})}(Z,ye)})}},Wl=>{Wl(Wl.s=51)}]); \ No newline at end of file diff --git a/ej2-angular/samples/diagram/layers/layers-cs7/main.5c7a28317b4bc2f4.js b/ej2-angular/samples/diagram/layers/layers-cs7/main.5c7a28317b4bc2f4.js deleted file mode 100644 index 573351ecd7..0000000000 --- a/ej2-angular/samples/diagram/layers/layers-cs7/main.5c7a28317b4bc2f4.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";(self.webpackChunksyncfusion_component=self.webpackChunksyncfusion_component||[]).push([[179],{51:(_l,jd,Vd)=>{let $r=null,Fh=1;const Ts=Symbol("SIGNAL");function Wi(n){const t=$r;return $r=n,t}function gn(n){if((!Vh(n)||n.dirty)&&(n.dirty||n.lastCleanEpoch!==Fh)){if(!n.producerMustRecompute(n)&&!jh(n))return n.dirty=!1,void(n.lastCleanEpoch=Fh);n.producerRecomputeValue(n),n.dirty=!1,n.lastCleanEpoch=Fh}}function jh(n){Vl(n);for(let t=0;t0}function Vl(n){n.producerNode??=[],n.producerIndexOfThis??=[],n.producerLastReadVersion??=[]}let qd=null;function Eo(n){return"function"==typeof n}function $d(n){const e=n(i=>{Error.call(i),i.stack=(new Error).stack});return e.prototype=Object.create(Error.prototype),e.prototype.constructor=e,e}const ff=$d(n=>function(e){n(this),this.message=e?`${e.length} errors occurred during unsubscription:\n${e.map((i,r)=>`${r+1}) ${i.toString()}`).join("\n ")}`:"",this.name="UnsubscriptionError",this.errors=e});function gf(n,t){if(n){const e=n.indexOf(t);0<=e&&n.splice(e,1)}}class As{constructor(t){this.initialTeardown=t,this.closed=!1,this._parentage=null,this._finalizers=null}unsubscribe(){let t;if(!this.closed){this.closed=!0;const{_parentage:e}=this;if(e)if(this._parentage=null,Array.isArray(e))for(const s of e)s.remove(this);else e.remove(this);const{initialTeardown:i}=this;if(Eo(i))try{i()}catch(s){t=s instanceof ff?s.errors:[s]}const{_finalizers:r}=this;if(r){this._finalizers=null;for(const s of r)try{Cm(s)}catch(o){t=t??[],o instanceof ff?t=[...t,...o.errors]:t.push(o)}}if(t)throw new ff(t)}}add(t){var e;if(t&&t!==this)if(this.closed)Cm(t);else{if(t instanceof As){if(t.closed||t._hasParent(this))return;t._addParent(this)}(this._finalizers=null!==(e=this._finalizers)&&void 0!==e?e:[]).push(t)}}_hasParent(t){const{_parentage:e}=this;return e===t||Array.isArray(e)&&e.includes(t)}_addParent(t){const{_parentage:e}=this;this._parentage=Array.isArray(e)?(e.push(t),e):e?[e,t]:t}_removeParent(t){const{_parentage:e}=this;e===t?this._parentage=null:Array.isArray(e)&&gf(e,t)}remove(t){const{_finalizers:e}=this;e&&gf(e,t),t instanceof As&&t._removeParent(this)}}As.EMPTY=(()=>{const n=new As;return n.closed=!0,n})();const Wl=As.EMPTY;function wm(n){return n instanceof As||n&&"closed"in n&&Eo(n.remove)&&Eo(n.add)&&Eo(n.unsubscribe)}function Cm(n){Eo(n)?n():n.unsubscribe()}const Yl={onUnhandledError:null,onStoppedNotification:null,Promise:void 0,useDeprecatedSynchronousErrorHandling:!1,useDeprecatedNextContext:!1},Z={setTimeout(n,t,...e){const{delegate:i}=Z;return i?.setTimeout?i.setTimeout(n,t,...e):setTimeout(n,t,...e)},clearTimeout(n){const{delegate:t}=Z;return(t?.clearTimeout||clearTimeout)(n)},delegate:void 0};function ye(){}const fe=at("C",void 0,void 0);function at(n,t,e){return{kind:n,value:t,error:e}}let tt=null;function At(n){if(Yl.useDeprecatedSynchronousErrorHandling){const t=!tt;if(t&&(tt={errorThrown:!1,error:null}),n(),t){const{errorThrown:e,error:i}=tt;if(tt=null,e)throw i}}else n()}class ft extends As{constructor(t){super(),this.isStopped=!1,t?(this.destination=t,wm(t)&&t.add(this)):this.destination=Wt}static create(t,e,i){return new cr(t,e,i)}next(t){this.isStopped?kr(function ke(n){return at("N",n,void 0)}(t),this):this._next(t)}error(t){this.isStopped?kr(function be(n){return at("E",void 0,n)}(t),this):(this.isStopped=!0,this._error(t))}complete(){this.isStopped?kr(fe,this):(this.isStopped=!0,this._complete())}unsubscribe(){this.closed||(this.isStopped=!0,super.unsubscribe(),this.destination=null)}_next(t){this.destination.next(t)}_error(t){try{this.destination.error(t)}finally{this.unsubscribe()}}_complete(){try{this.destination.complete()}finally{this.unsubscribe()}}}const Ei=Function.prototype.bind;function ti(n,t){return Ei.call(n,t)}class gi{constructor(t){this.partialObserver=t}next(t){const{partialObserver:e}=this;if(e.next)try{e.next(t)}catch(i){Oi(i)}}error(t){const{partialObserver:e}=this;if(e.error)try{e.error(t)}catch(i){Oi(i)}else Oi(t)}complete(){const{partialObserver:t}=this;if(t.complete)try{t.complete()}catch(e){Oi(e)}}}class cr extends ft{constructor(t,e,i){let r;if(super(),Eo(t)||!t)r={next:t??void 0,error:e??void 0,complete:i??void 0};else{let s;this&&Yl.useDeprecatedNextContext?(s=Object.create(t),s.unsubscribe=()=>this.unsubscribe(),r={next:t.next&&ti(t.next,s),error:t.error&&ti(t.error,s),complete:t.complete&&ti(t.complete,s)}):r=t}this.destination=new gi(r)}}function Oi(n){Yl.useDeprecatedSynchronousErrorHandling?function Lt(n){Yl.useDeprecatedSynchronousErrorHandling&&tt&&(tt.errorThrown=!0,tt.error=n)}(n):function se(n){Z.setTimeout(()=>{const{onUnhandledError:t}=Yl;if(!t)throw n;t(n)})}(n)}function kr(n,t){const{onStoppedNotification:e}=Yl;e&&Z.setTimeout(()=>e(n,t))}const Wt={closed:!0,next:ye,error:function es(n){throw n},complete:ye},ct="function"==typeof Symbol&&Symbol.observable||"@@observable";function _n(n){return n}let ki=(()=>{class n{constructor(e){e&&(this._subscribe=e)}lift(e){const i=new n;return i.source=this,i.operator=e,i}subscribe(e,i,r){const s=function et(n){return n&&n instanceof ft||function dr(n){return n&&Eo(n.next)&&Eo(n.error)&&Eo(n.complete)}(n)&&wm(n)}(e)?e:new cr(e,i,r);return At(()=>{const{operator:o,source:a}=this;s.add(o?o.call(s,a):a?this._subscribe(s):this._trySubscribe(s))}),s}_trySubscribe(e){try{return this._subscribe(e)}catch(i){e.error(i)}}forEach(e,i){return new(i=lt(i))((r,s)=>{const o=new cr({next:a=>{try{e(a)}catch(l){s(l),o.unsubscribe()}},error:s,complete:r});this.subscribe(o)})}_subscribe(e){var i;return null===(i=this.source)||void 0===i?void 0:i.subscribe(e)}[ct](){return this}pipe(...e){return function Zr(n){return 0===n.length?_n:1===n.length?n[0]:function(e){return n.reduce((i,r)=>r(i),e)}}(e)(this)}toPromise(e){return new(e=lt(e))((i,r)=>{let s;this.subscribe(o=>s=o,o=>r(o),()=>i(s))})}}return n.create=t=>new n(t),n})();function lt(n){var t;return null!==(t=n??Yl.Promise)&&void 0!==t?t:Promise}const vi=$d(n=>function(){n(this),this.name="ObjectUnsubscribedError",this.message="object unsubscribed"});let Pt=(()=>{class n extends ki{constructor(){super(),this.closed=!1,this.currentObservers=null,this.observers=[],this.isStopped=!1,this.hasError=!1,this.thrownError=null}lift(e){const i=new ts(this,this);return i.operator=e,i}_throwIfClosed(){if(this.closed)throw new vi}next(e){At(()=>{if(this._throwIfClosed(),!this.isStopped){this.currentObservers||(this.currentObservers=Array.from(this.observers));for(const i of this.currentObservers)i.next(e)}})}error(e){At(()=>{if(this._throwIfClosed(),!this.isStopped){this.hasError=this.isStopped=!0,this.thrownError=e;const{observers:i}=this;for(;i.length;)i.shift().error(e)}})}complete(){At(()=>{if(this._throwIfClosed(),!this.isStopped){this.isStopped=!0;const{observers:e}=this;for(;e.length;)e.shift().complete()}})}unsubscribe(){this.isStopped=this.closed=!0,this.observers=this.currentObservers=null}get observed(){var e;return(null===(e=this.observers)||void 0===e?void 0:e.length)>0}_trySubscribe(e){return this._throwIfClosed(),super._trySubscribe(e)}_subscribe(e){return this._throwIfClosed(),this._checkFinalizedStatuses(e),this._innerSubscribe(e)}_innerSubscribe(e){const{hasError:i,isStopped:r,observers:s}=this;return i||r?Wl:(this.currentObservers=null,s.push(e),new As(()=>{this.currentObservers=null,gf(s,e)}))}_checkFinalizedStatuses(e){const{hasError:i,thrownError:r,isStopped:s}=this;i?e.error(r):s&&e.complete()}asObservable(){const e=new ki;return e.source=this,e}}return n.create=(t,e)=>new ts(t,e),n})();class ts extends Pt{constructor(t,e){super(),this.destination=t,this.source=e}next(t){var e,i;null===(i=null===(e=this.destination)||void 0===e?void 0:e.next)||void 0===i||i.call(e,t)}error(t){var e,i;null===(i=null===(e=this.destination)||void 0===e?void 0:e.error)||void 0===i||i.call(e,t)}complete(){var t,e;null===(e=null===(t=this.destination)||void 0===t?void 0:t.complete)||void 0===e||e.call(t)}_subscribe(t){var e,i;return null!==(i=null===(e=this.source)||void 0===e?void 0:e.subscribe(t))&&void 0!==i?i:Wl}}class _o extends Pt{constructor(t){super(),this._value=t}get value(){return this.getValue()}_subscribe(t){const e=super._subscribe(t);return!e.closed&&t.next(this._value),e}getValue(){const{hasError:t,thrownError:e,_value:i}=this;if(t)throw e;return this._throwIfClosed(),i}next(t){super.next(this._value=t)}}class Ls extends ft{constructor(t,e,i,r,s,o){super(t),this.onFinalize=s,this.shouldUnsubscribe=o,this._next=e?function(a){try{e(a)}catch(l){t.error(l)}}:super._next,this._error=r?function(a){try{r(a)}catch(l){t.error(l)}finally{this.unsubscribe()}}:super._error,this._complete=i?function(){try{i()}catch(a){t.error(a)}finally{this.unsubscribe()}}:super._complete}unsubscribe(){var t;if(!this.shouldUnsubscribe||this.shouldUnsubscribe()){const{closed:e}=this;super.unsubscribe(),!e&&(null===(t=this.onFinalize)||void 0===t||t.call(this))}}}function jr(n,t){return function Ur(n){return t=>{if(function cn(n){return Eo(n?.lift)}(t))return t.lift(function(e){try{return n(e,this)}catch(i){this.error(i)}});throw new TypeError("Unable to lift unknown Observable type")}}((e,i)=>{let r=0;e.subscribe(function Do(n,t,e,i,r){return new Ls(n,t,e,i,r)}(i,s=>{i.next(n.call(t,s,r++))}))})}class F extends Error{constructor(t,e){super(function ae(n,t){return`NG0${Math.abs(n)}${t?": "+t:""}`}(t,e)),this.code=t}}function Xe(n){for(let t in n)if(n[t]===Xe)return t;throw Error("Could not find renamed property on target object.")}function mt(n,t){for(const e in t)t.hasOwnProperty(e)&&!n.hasOwnProperty(e)&&(n[e]=t[e])}function dt(n){if("string"==typeof n)return n;if(Array.isArray(n))return"["+n.map(dt).join(", ")+"]";if(null==n)return""+n;if(n.overriddenName)return`${n.overriddenName}`;if(n.name)return`${n.name}`;const t=n.toString();if(null==t)return""+t;const e=t.indexOf("\n");return-1===e?t:t.substring(0,e)}function qt(n,t){return null==n||""===n?null===t?"":t:null==t||""===t?n:n+" "+t}const ur=Xe({__forward_ref__:Xe});function ir(n){return n.__forward_ref__=ir,n.toString=function(){return dt(this())},n}function vt(n){return function Dn(n){return"function"==typeof n&&n.hasOwnProperty(ur)&&n.__forward_ref__===ir}(n)?n():n}function Ql(n){return n&&!!n.\u0275providers}const Gl=Xe({\u0275cmp:Xe}),Zd=Xe({\u0275dir:Xe}),vf=Xe({\u0275pipe:Xe}),Uo=Xe({\u0275fac:Xe}),jo=Xe({__NG_ELEMENT_ID__:Xe}),mf=Xe({__NG_ENV_ID__:Xe});function zi(n){return"function"==typeof n?n.name||n.toString():"object"==typeof n&&null!=n&&"function"==typeof n.type?n.type.name||n.type.toString():function Nt(n){return"string"==typeof n?n:null==n?"":String(n)}(n)}function Lb(n,t){throw new F(-201,!1)}function ro(n,t){null==n&&function zt(n,t,e,i){throw new Error(`ASSERTION ERROR: ${n}`+(null==i?"":` [Expected=> ${e} ${i} ${t} <=Actual]`))}(t,n,null,"!=")}function Yi(n){return{token:n.token,providedIn:n.providedIn||null,factory:n.factory,value:void 0}}function yf(n){return{providers:n.providers||[],imports:n.imports||[]}}function Em(n){return RT(n,xm)||RT(n,HT)}function RT(n,t){return n.hasOwnProperty(t)?n[t]:null}function Dm(n){return n&&(n.hasOwnProperty(Nb)||n.hasOwnProperty(x_))?n[Nb]:null}const xm=Xe({\u0275prov:Xe}),Nb=Xe({\u0275inj:Xe}),HT=Xe({ngInjectableDef:Xe}),x_=Xe({ngInjectorDef:Xe});var Di=function(n){return n[n.Default=0]="Default",n[n.Host=1]="Host",n[n.Self=2]="Self",n[n.SkipSelf=4]="SkipSelf",n[n.Optional=8]="Optional",n}(Di||{});let Ob;function no(n){const t=Ob;return Ob=n,t}function FT(n,t,e){const i=Em(n);return i&&"root"==i.providedIn?void 0===i.value?i.value=i.factory():i.value:e&Di.Optional?null:void 0!==t?t:void Lb()}const rr=globalThis;class Ht{constructor(t,e){this._desc=t,this.ngMetadataName="InjectionToken",this.\u0275prov=void 0,"number"==typeof e?this.__NG_ELEMENT_ID__=e:void 0!==e&&(this.\u0275prov=Yi({token:this,providedIn:e.providedIn||"root",factory:e.factory}))}get multi(){return this}toString(){return`InjectionToken ${this._desc}`}}const Sf={},Hb="__NG_DI_FLAG__",Tm="ngTempTokenPath",L_=/\n/gm,UT="__source";let Kd;function Qh(n){const t=Kd;return Kd=n,t}function k_(n,t=Di.Default){if(void 0===Kd)throw new F(-203,!1);return null===Kd?FT(n,void 0,t):Kd.get(n,t&Di.Optional?null:void 0,t)}function Fi(n,t=Di.Default){return(function BT(){return Ob}()||k_)(vt(n),t)}function Ri(n,t=Di.Default){return Fi(n,Am(t))}function Am(n){return typeof n>"u"||"number"==typeof n?n:0|(n.optional&&8)|(n.host&&1)|(n.self&&2)|(n.skipSelf&&4)}function Bb(n){const t=[];for(let e=0;et){o=s-1;break}}}for(;ss?"":r[d+1].toLowerCase();const p=8&i?u:null;if(p&&-1!==VT(p,h,0)||2&i&&h!==u){if(ba(i))return!1;o=!0}}}}else{if(!o&&!ba(i)&&!ba(l))return!1;if(o&&ba(l))continue;o=!1,i=l|1&i}}return ba(i)||o}function ba(n){return 0==(1&n)}function __(n,t,e,i){if(null===t)return-1;let r=0;if(i||!e){let s=!1;for(;r-1)for(e++;e0?'="'+a+'"':"")+"]"}else 8&i?r+="."+o:4&i&&(r+=" "+o);else""!==r&&!ba(o)&&(t+=$T(s,r),r=""),i=o,s=s||!ba(i);e++}return""!==r&&(t+=$T(s,r)),t}function _b(n){return Xl(()=>{const t=JT(n),e={...t,decls:n.decls,vars:n.vars,template:n.template,consts:n.consts||null,ngContentSelectors:n.ngContentSelectors,onPush:n.changeDetection===Lm.OnPush,directiveDefs:null,pipeDefs:null,dependencies:t.standalone&&n.dependencies||null,getStandaloneInjector:null,signals:n.signals??!1,data:n.data||{},encapsulation:n.encapsulation||Ia.Emulated,styles:n.styles||Qi,_:null,schemas:n.schemas||null,tView:null,id:""};KT(e);const i=n.dependencies;return e.directiveDefs=Om(i,!1),e.pipeDefs=Om(i,!0),e.id=function Z_(n){let t=0;const e=[n.selectors,n.ngContentSelectors,n.hostVars,n.hostAttrs,n.consts,n.vars,n.decls,n.encapsulation,n.standalone,n.signals,n.exportAs,JSON.stringify(n.inputs),JSON.stringify(n.outputs),Object.getOwnPropertyNames(n.type.prototype),!!n.contentQueries,!!n.viewQuery].join("|");for(const r of e)t=Math.imul(31,t)+r.charCodeAt(0)<<0;return t+=2147483648,"c"+t}(e),e})}function X_(n){return ci(n)||jn(n)}function q_(n){return null!==n}function Nm(n){return Xl(()=>({type:n.type,bootstrap:n.bootstrap||Qi,declarations:n.declarations||Qi,imports:n.imports||Qi,exports:n.exports||Qi,transitiveCompileScopes:null,schemas:n.schemas||null,id:n.id||null}))}function ZT(n,t){if(null==n)return tl;const e={};for(const i in n)if(n.hasOwnProperty(i)){const r=n[i];let s,o,a=Gh.None;Array.isArray(r)?(a=r[0],s=r[1],o=r[2]??s):(s=r,o=r),t?(e[s]=a!==Gh.None?[i,a]:i,t[s]=o):e[s]=i}return e}function nr(n){return Xl(()=>{const t=JT(n);return KT(t),t})}function ci(n){return n[Gl]||null}function jn(n){return n[Zd]||null}function gs(n){return n[vf]||null}function JT(n){const t={};return{type:n.type,providersResolver:null,factory:null,hostBindings:n.hostBindings||null,hostVars:n.hostVars||0,hostAttrs:n.hostAttrs||null,contentQueries:n.contentQueries||null,declaredInputs:t,inputTransforms:null,inputConfig:n.inputs||tl,exportAs:n.exportAs||null,standalone:!0===n.standalone,signals:!0===n.signals,selectors:n.selectors||Qi,viewQuery:n.viewQuery||null,features:n.features||null,setInput:null,findHostDirectiveDefs:null,hostDirectives:null,inputs:ZT(n.inputs,t),outputs:ZT(n.outputs),debugInfo:null}}function KT(n){n.features?.forEach(t=>t(n))}function Om(n,t){if(!n)return null;const e=t?gs:X_;return()=>("function"==typeof n?n():n).map(i=>e(i)).filter(q_)}const Vr=0,Be=1,Ct=2,vn=3,Ma=4,Os=5,wa=6,eu=7,Er=8,Xs=9,ql=10,Yt=11,Mf=12,eA=13,tu=14,Jr=15,wf=16,iu=17,il=18,Cf=19,tA=20,Xh=21,km=22,Vc=23,Ut=25,Ub=1,rl=7,ru=9,mn=10;var jb=function(n){return n[n.None=0]="None",n[n.HasTransplantedViews=2]="HasTransplantedViews",n}(jb||{});function ks(n){return Array.isArray(n)&&"object"==typeof n[Ub]}function Ps(n){return Array.isArray(n)&&!0===n[Ub]}function Vb(n){return 0!=(4&n.flags)}function Wc(n){return n.componentOffset>-1}function zm(n){return 1==(1&n.flags)}function Ca(n){return!!n.template}function Wb(n){return 0!=(512&n[Ct])}function Yc(n,t){return n.hasOwnProperty(Uo)?n[Uo]:null}class tU{constructor(t,e,i){this.previousValue=t,this.currentValue=e,this.firstChange=i}isFirstChange(){return this.firstChange}}function sA(n,t,e,i){null!==t?t.applyValueToInputSignal(t,i):n[e]=i}function oA(n){return n.type.prototype.ngOnChanges&&(n.setInput=rU),iU}function iU(){const n=lA(this),t=n?.current;if(t){const e=n.previous;if(e===tl)n.previous=t;else for(let i in t)e[i]=t[i];n.current=null,this.ngOnChanges(t)}}function rU(n,t,e,i,r){const s=this.declaredInputs[i],o=lA(n)||function nU(n,t){return n[aA]=t}(n,{previous:tl,current:null}),a=o.current||(o.current={}),l=o.previous,h=l[s];a[s]=new tU(h&&h.currentValue,e,l===tl),sA(n,t,r,e)}const aA="__ngSimpleChanges__";function lA(n){return n[aA]||null}const nl=function(n,t,e){};let dA=!1;function pr(n){for(;Array.isArray(n);)n=n[Vr];return n}function qs(n,t){return pr(t[n.index])}function xf(n,t){return n.data[t]}function To(n,t){const e=t[n];return ks(e)?e:e[Vr]}function qb(n){return 128==(128&n[Ct])}function sl(n,t){return null==t?null:n[t]}function uA(n){n[iu]=0}function cU(n){1024&n[Ct]||(n[Ct]|=1024,qb(n)&&Tf(n))}function fA(n){return 9216&n[Ct]||n[Vc]?.dirty}function $b(n){fA(n)?Tf(n):64&n[Ct]&&(function oU(){return dA}()?(n[Ct]|=1024,Tf(n)):n[ql].changeDetectionScheduler?.notify())}function Tf(n){n[ql].changeDetectionScheduler?.notify();let t=Qc(n);for(;null!==t&&!(8192&t[Ct])&&(t[Ct]|=8192,qb(t));)t=Qc(t)}function Qc(n){const t=n[vn];return Ps(t)?t[vn]:t}const Rt={lFrame:CA(null),bindingsEnabled:!0,skipHydrationRootTNode:null};function vA(){return Rt.bindingsEnabled}function Se(){return Rt.lFrame.lView}function xi(){return Rt.lFrame.tView}function fr(){let n=mA();for(;null!==n&&64===n.type;)n=n.parent;return n}function mA(){return Rt.lFrame.currentTNode}function ol(n,t){const e=Rt.lFrame;e.currentTNode=n,e.isParent=t}function Jb(){return Rt.lFrame.isParent}function wU(n,t){const e=Rt.lFrame;e.bindingIndex=e.bindingRootIndex=n,e1(t)}function e1(n){Rt.lFrame.currentDirectiveIndex=n}function bA(){return Rt.lFrame.currentQueryIndex}function i1(n){Rt.lFrame.currentQueryIndex=n}function EU(n){const t=n[Be];return 2===t.type?t.declTNode:1===t.type?n[Os]:null}function MA(n,t,e){if(e&Di.SkipSelf){let r=t,s=n;for(;!(r=r.parent,null!==r||e&Di.Host||(r=EU(s),null===r||(s=s[tu],10&r.type))););if(null===r)return!1;t=r,n=s}const i=Rt.lFrame=wA();return i.currentTNode=t,i.lView=n,!0}function r1(n){const t=wA(),e=n[Be];Rt.lFrame=t,t.currentTNode=e.firstChild,t.lView=n,t.tView=e,t.contextLView=n,t.bindingIndex=e.bindingStartIndex,t.inI18n=!1}function wA(){const n=Rt.lFrame,t=null===n?null:n.child;return null===t?CA(n):t}function CA(n){const t={currentTNode:null,isParent:!0,lView:null,tView:null,selectedIndex:-1,contextLView:null,elementDepthCount:0,currentNamespace:null,currentDirectiveIndex:-1,bindingRootIndex:-1,bindingIndex:-1,currentQueryIndex:0,parent:n,child:null,inI18n:!1};return null!==n&&(n.child=t),t}function EA(){const n=Rt.lFrame;return Rt.lFrame=n.parent,n.currentTNode=null,n.lView=null,n}const DA=EA;function n1(){const n=EA();n.isParent=!0,n.tView=null,n.selectedIndex=-1,n.contextLView=null,n.elementDepthCount=0,n.currentDirectiveIndex=-1,n.currentNamespace=null,n.bindingRootIndex=-1,n.bindingIndex=-1,n.currentQueryIndex=0}function zs(){return Rt.lFrame.selectedIndex}function Gc(n){Rt.lFrame.selectedIndex=n}let TA=!0;function Bm(){return TA}function qh(n){TA=n}function Fm(n,t){for(let e=t.directiveStart,i=t.directiveEnd;e=i)break}else t[l]<0&&(n[iu]+=65536),(a>14>16&&(3&n[Ct])===t&&(n[Ct]+=16384,LA(a,s)):LA(a,s)}const ou=-1;class Lf{constructor(t,e,i){this.factory=t,this.resolving=!1,this.canSeeViewProviders=e,this.injectImpl=i}}function a1(n){return n!==ou}function Nf(n){return 32767&n}function Of(n,t){let e=function HU(n){return n>>16}(n),i=t;for(;e>0;)i=i[tu],e--;return i}let l1=!0;function jm(n){const t=l1;return l1=n,t}const NA=255,OA=5;let BU=0;const ll={};function Vm(n,t){const e=kA(n,t);if(-1!==e)return e;const i=t[Be];i.firstCreatePass&&(n.injectorIndex=t.length,h1(i.data,n),h1(t,null),h1(i.blueprint,null));const r=Wm(n,t),s=n.injectorIndex;if(a1(r)){const o=Nf(r),a=Of(r,t),l=a[Be].data;for(let h=0;h<8;h++)t[s+h]=a[o+h]|l[o+h]}return t[s+8]=r,s}function h1(n,t){n.push(0,0,0,0,0,0,0,0,t)}function kA(n,t){return-1===n.injectorIndex||n.parent&&n.parent.injectorIndex===n.injectorIndex||null===t[n.injectorIndex+8]?-1:n.injectorIndex}function Wm(n,t){if(n.parent&&-1!==n.parent.injectorIndex)return n.parent.injectorIndex;let e=0,i=null,r=t;for(;null!==r;){if(i=_A(r),null===i)return ou;if(e++,r=r[tu],-1!==i.injectorIndex)return i.injectorIndex|e<<16}return ou}function c1(n,t,e){!function FU(n,t,e){let i;"string"==typeof e?i=e.charCodeAt(0)||0:e.hasOwnProperty(jo)&&(i=e[jo]),null==i&&(i=e[jo]=BU++);const r=i&NA;t.data[n+(r>>OA)]|=1<=0?t&NA:VU:t}(e);if("function"==typeof s){if(!MA(t,n,i))return i&Di.Host?PA(r,0,i):zA(t,e,i,r);try{let o;if(o=s(i),null!=o||i&Di.Optional)return o;Lb()}finally{DA()}}else if("number"==typeof s){let o=null,a=kA(n,t),l=ou,h=i&Di.Host?t[Jr][Os]:null;for((-1===a||i&Di.SkipSelf)&&(l=-1===a?Wm(n,t):t[a+8],l!==ou&&FA(i,!1)?(o=t[Be],a=Nf(l),t=Of(l,t)):a=-1);-1!==a;){const c=t[Be];if(BA(s,a,c.data)){const d=UU(a,t,e,o,i,h);if(d!==ll)return d}l=t[a+8],l!==ou&&FA(i,t[Be].data[a+8]===h)&&BA(s,a,t)?(o=c,a=Nf(l),t=Of(l,t)):a=-1}}return r}function UU(n,t,e,i,r,s){const o=t[Be],a=o.data[n+8],c=Ym(a,o,e,null==i?Wc(a)&&l1:i!=o&&0!=(3&a.type),r&Di.Host&&s===a);return null!==c?Xc(t,o,c,a):ll}function Ym(n,t,e,i,r){const s=n.providerIndexes,o=t.data,a=1048575&s,l=n.directiveStart,c=s>>20,u=r?a+c:n.directiveEnd;for(let p=i?a:a+c;p=l&&f.type===e)return p}if(r){const p=o[l];if(p&&Ca(p)&&p.type===e)return l}return null}function Xc(n,t,e,i){let r=n[e];const s=t.data;if(function kU(n){return n instanceof Lf}(r)){const o=r;o.resolving&&function Vo(n,t){const e=t?`. Dependency path: ${t.join(" > ")} > ${n}`:"";throw new F(-200,`Circular dependency in DI detected for ${n}${e}`)}(zi(s[e]));const a=jm(o.canSeeViewProviders);o.resolving=!0;const h=o.injectImpl?no(o.injectImpl):null;MA(n,i,Di.Default);try{r=n[e]=o.factory(void 0,s,n,i),t.firstCreatePass&&e>=i.directiveStart&&function NU(n,t,e){const{ngOnChanges:i,ngOnInit:r,ngDoCheck:s}=t.type.prototype;if(i){const o=oA(t);(e.preOrderHooks??=[]).push(n,o),(e.preOrderCheckHooks??=[]).push(n,o)}r&&(e.preOrderHooks??=[]).push(0-n,r),s&&((e.preOrderHooks??=[]).push(n,s),(e.preOrderCheckHooks??=[]).push(n,s))}(e,s[e],t)}finally{null!==h&&no(h),jm(a),o.resolving=!1,DA()}}return r}function BA(n,t,e){return!!(e[t+(n>>OA)]&1<Array.isArray(e)?fu(e,t):t(e))}function jA(n,t,e){t>=n.length?n.push(e):n.splice(t,0,e)}function Qm(n,t){return t>=n.length-1?n.pop():n.splice(t,1)[0]}const mu=new Ht(""),XA=new Ht("",-1),I1=new Ht("");class $m{get(t,e=Sf){if(e===Sf){const i=new Error(`NullInjectorError: No provider for ${dt(t)}!`);throw i.name="NullInjectorError",i}return e}}function pj(...n){return{\u0275providers:qA(0,n),\u0275fromNgModule:!0}}function qA(n,...t){const e=[],i=new Set;let r;const s=o=>{e.push(o)};return fu(t,o=>{const a=o;Zm(a,s,[],i)&&(r||=[],r.push(a))}),void 0!==r&&$A(r,s),e}function $A(n,t){for(let e=0;e{t(s,i)})}}function Zm(n,t,e,i){if(!(n=vt(n)))return!1;let r=null,s=Dm(n);const o=!s&&ci(n);if(s||o){if(o&&!o.standalone)return!1;r=n}else{const l=n.ngModule;if(s=Dm(l),!s)return!1;r=l}const a=i.has(r);if(o){if(a)return!1;if(i.add(r),o.dependencies){const l="function"==typeof o.dependencies?o.dependencies():o.dependencies;for(const h of l)Zm(h,t,e,i)}}else{if(!s)return!1;{if(null!=s.imports&&!a){let h;i.add(r);try{fu(s.imports,c=>{Zm(c,t,e,i)&&(h||=[],h.push(c))})}finally{}void 0!==h&&$A(h,t)}if(!a){const h=Yc(r)||(()=>new r);t({provide:r,useFactory:h,deps:Qi},r),t({provide:I1,useValue:r,multi:!0},r),t({provide:mu,useValue:()=>Fi(r),multi:!0},r)}const l=s.providers;if(null!=l&&!a){const h=n;M1(l,c=>{t(c,h)})}}}return r!==n&&void 0!==n.providers}function M1(n,t){for(let e of n)Ql(e)&&(e=e.\u0275providers),Array.isArray(e)?M1(e,t):t(e)}const fj=Xe({provide:String,useValue:Xe});function w1(n){return null!==n&&"object"==typeof n&&fj in n}function qc(n){return"function"==typeof n}const C1=new Ht(""),Jm={},vj={};let E1;function Km(){return void 0===E1&&(E1=new $m),E1}class Jl{}class yu extends Jl{get destroyed(){return this._destroyed}constructor(t,e,i,r){super(),this.parent=e,this.source=i,this.scopes=r,this.records=new Map,this._ngOnDestroyHooks=new Set,this._onDestroyHooks=[],this._destroyed=!1,x1(t,o=>this.processProvider(o)),this.records.set(XA,Su(void 0,this)),r.has("environment")&&this.records.set(Jl,Su(void 0,this));const s=this.records.get(C1);null!=s&&"string"==typeof s.value&&this.scopes.add(s.value),this.injectorDefTypes=new Set(this.get(I1,Qi,Di.Self))}destroy(){this.assertNotDestroyed(),this._destroyed=!0;try{for(const e of this._ngOnDestroyHooks)e.ngOnDestroy();const t=this._onDestroyHooks;this._onDestroyHooks=[];for(const e of t)e()}finally{this.records.clear(),this._ngOnDestroyHooks.clear(),this.injectorDefTypes.clear()}}onDestroy(t){return this.assertNotDestroyed(),this._onDestroyHooks.push(t),()=>this.removeOnDestroy(t)}runInContext(t){this.assertNotDestroyed();const e=Qh(this),i=no(void 0);try{return t()}finally{Qh(e),no(i)}}get(t,e=Sf,i=Di.Default){if(this.assertNotDestroyed(),t.hasOwnProperty(mf))return t[mf](this);i=Am(i);const s=Qh(this),o=no(void 0);try{if(!(i&Di.SkipSelf)){let l=this.records.get(t);if(void 0===l){const h=function bj(n){return"function"==typeof n||"object"==typeof n&&n instanceof Ht}(t)&&Em(t);l=h&&this.injectableDefInScope(h)?Su(D1(t),Jm):null,this.records.set(t,l)}if(null!=l)return this.hydrate(t,l)}return(i&Di.Self?Km():this.parent).get(t,e=i&Di.Optional&&e===Sf?null:e)}catch(a){if("NullInjectorError"===a.name){if((a[Tm]=a[Tm]||[]).unshift(dt(t)),s)throw a;return function z_(n,t,e,i){const r=n[Tm];throw t[UT]&&r.unshift(t[UT]),n.message=function R_(n,t,e,i=null){n=n&&"\n"===n.charAt(0)&&"\u0275"==n.charAt(1)?n.slice(2):n;let r=dt(t);if(Array.isArray(t))r=t.map(dt).join(" -> ");else if("object"==typeof t){let s=[];for(let o in t)if(t.hasOwnProperty(o)){let a=t[o];s.push(o+":"+("string"==typeof a?JSON.stringify(a):dt(a)))}r=`{${s.join(", ")}}`}return`${e}${i?"("+i+")":""}[${r}]: ${n.replace(L_,"\n ")}`}("\n"+n.message,r,e,i),n.ngTokenPath=r,n[Tm]=null,n}(a,t,"R3InjectorError",this.source)}throw a}finally{no(o),Qh(s)}}resolveInjectorInitializers(){const t=Qh(this),e=no(void 0);try{const r=this.get(mu,Qi,Di.Self);for(const s of r)s()}finally{Qh(t),no(e)}}toString(){const t=[],e=this.records;for(const i of e.keys())t.push(dt(i));return`R3Injector[${t.join(", ")}]`}assertNotDestroyed(){if(this._destroyed)throw new F(205,!1)}processProvider(t){let e=qc(t=vt(t))?t:vt(t&&t.provide);const i=function yj(n){return w1(n)?Su(void 0,n.useValue):Su(KA(n),Jm)}(t);if(!qc(t)&&!0===t.multi){let r=this.records.get(e);r||(r=Su(void 0,Jm,!0),r.factory=()=>Bb(r.multi),this.records.set(e,r)),e=t,r.multi.push(t)}this.records.set(e,i)}hydrate(t,e){return e.value===Jm&&(e.value=vj,e.value=e.factory()),"object"==typeof e.value&&e.value&&function Ij(n){return null!==n&&"object"==typeof n&&"function"==typeof n.ngOnDestroy}(e.value)&&this._ngOnDestroyHooks.add(e.value),e.value}injectableDefInScope(t){if(!t.providedIn)return!1;const e=vt(t.providedIn);return"string"==typeof e?"any"===e||this.scopes.has(e):this.injectorDefTypes.has(e)}removeOnDestroy(t){const e=this._onDestroyHooks.indexOf(t);-1!==e&&this._onDestroyHooks.splice(e,1)}}function D1(n){const t=Em(n),e=null!==t?t.factory:Yc(n);if(null!==e)return e;if(n instanceof Ht)throw new F(204,!1);if(n instanceof Function)return function mj(n){if(n.length>0)throw new F(204,!1);const e=function D_(n){return n&&(n[xm]||n[HT])||null}(n);return null!==e?()=>e.factory(n):()=>new n}(n);throw new F(204,!1)}function KA(n,t,e){let i;if(qc(n)){const r=vt(n);return Yc(r)||D1(r)}if(w1(n))i=()=>vt(n.useValue);else if(function JA(n){return!(!n||!n.useFactory)}(n))i=()=>n.useFactory(...Bb(n.deps||[]));else if(function ZA(n){return!(!n||!n.useExisting)}(n))i=()=>Fi(vt(n.useExisting));else{const r=vt(n&&(n.useClass||n.provide));if(!function Sj(n){return!!n.deps}(n))return Yc(r)||D1(r);i=()=>new r(...Bb(n.deps))}return i}function Su(n,t,e=!1){return{factory:n,value:t,multi:e?[]:void 0}}function x1(n,t){for(const e of n)Array.isArray(e)?x1(e,t):e&&Ql(e)?x1(e.\u0275providers,t):t(e)}function rL(n,t=null,e=null,i){const r=function nL(n,t=null,e=null,i,r=new Set){const s=[e||Qi,pj(n)];return i=i||("object"==typeof n?void 0:dt(n)),new yu(s,t||Km(),i||null,r)}(n,t,e,i);return r.resolveInjectorInitializers(),r}let L1,Wo=(()=>{class n{static{this.THROW_IF_NOT_FOUND=Sf}static{this.NULL=new $m}static create(e,i){if(Array.isArray(e))return rL({name:""},i,e,"");{const r=e.name??"";return rL({name:r},e.parent,e.providers,r)}}static{this.\u0275prov=Yi({token:n,providedIn:"any",factory:()=>Fi(XA)})}static{this.__NG_ELEMENT_ID__=-1}}return n})();const N1=new Ht("",{providedIn:"root",factory:()=>Lj}),Lj="ng",oL=new Ht(""),Iu=new Ht("",{providedIn:"platform",factory:()=>"unknown"}),aL=new Ht("",{providedIn:"root",factory:()=>function $h(){if(void 0!==L1)return L1;if(typeof document<"u")return document;throw new F(210,!1)}().body?.querySelector("[ngCspNonce]")?.getAttribute("ngCspNonce")||null});function ny(n){return 128==(128&n.flags)}var Kh=function(n){return n[n.Important=1]="Important",n[n.DashCase=2]="DashCase",n}(Kh||{});const R1=new Map;let Vj=0;const B1="__ngContext__";function Rs(n,t){ks(t)?(n[B1]=t[Cf],function Yj(n){R1.set(n[Cf],n)}(t)):n[B1]=t}let F1;function _1(n,t){return F1(n,t)}function Mu(n,t,e,i,r){if(null!=i){let s,o=!1;Ps(i)?s=i:ks(i)&&(o=!0,i=i[Vr]);const a=pr(i);0===n&&null!==e?null==r?AL(t,e,a):Zc(t,e,a,r||null,!0):1===n&&null!==e?Zc(t,e,a,r||null,!0):2===n?function dy(n,t,e){const i=hy(n,t);i&&function a6(n,t,e,i){n.removeChild(t,e,i)}(n,i,t,e)}(t,a,o):3===n&&t.destroyNode(a),null!=s&&function c6(n,t,e,i,r){const s=e[rl];s!==pr(e)&&Mu(t,n,i,s,r);for(let a=mn;a0&&(n[e-1][Ma]=i[Ma]);const s=Qm(n,mn+t);!function e6(n,t){DL(n,t),t[Vr]=null,t[Os]=null}(i[Be],i);const o=s[il];null!==o&&o.detachView(s[Be]),i[vn]=null,i[Ma]=null,i[Ct]&=-129}return i}function ly(n,t){if(!(256&t[Ct])){const e=t[Yt];e.destroyNode&&uy(n,t,e,3,null,null),function i6(n){let t=n[Mf];if(!t)return j1(n[Be],n);for(;t;){let e=null;if(ks(t))e=t[Mf];else{const i=t[mn];i&&(e=i)}if(!e){for(;t&&!t[Ma]&&t!==n;)ks(t)&&j1(t[Be],t),t=t[vn];null===t&&(t=n),ks(t)&&j1(t[Be],t),e=t&&t[Ma]}t=e}}(t)}}function j1(n,t){if(!(256&t[Ct])){t[Ct]&=-129,t[Ct]|=256,t[Vc]&&function Gd(n){if(Vl(n),Vh(n))for(let t=0;t=0?i[o]():i[-o].unsubscribe(),s+=2}else e[s].call(i[e[s+1]]);null!==i&&(t[eu]=null);const r=t[Xh];if(null!==r){t[Xh]=null;for(let s=0;s-1){const{encapsulation:s}=n.data[i.directiveStart+r];if(s===Ia.None||s===Ia.Emulated)return null}return qs(i,e)}}(n,t.parent,e)}function Zc(n,t,e,i,r){n.insertBefore(t,e,i,r)}function AL(n,t,e){n.appendChild(t,e)}function LL(n,t,e,i,r){null!==i?Zc(n,t,e,i,r):AL(n,t,e)}function hy(n,t){return n.parentNode(t)}let W1,kL=function OL(n,t,e){return 40&n.type?qs(n,e):null};function cy(n,t,e,i){const r=V1(n,i,t),s=t[Yt],a=function NL(n,t,e){return kL(n,t,e)}(i.parent||t[Os],i,t);if(null!=r)if(Array.isArray(e))for(let l=0;lnull;function oM(n,t,e=!1){return KL(n,t,e)}class G6{}class nN{}class q6{resolveComponentFactory(t){throw function X6(n){const t=Error(`No component factory found for ${dt(n)}.`);return t.ngComponent=n,t}(t)}}let by=(()=>{class n{static{this.NULL=new q6}}return n})();function $6(){return Tu(fr(),Se())}function Tu(n,t){return new Jc(qs(n,t))}let Jc=(()=>{class n{constructor(e){this.nativeElement=e}static{this.__NG_ELEMENT_ID__=$6}}return n})();function Z6(n){return n instanceof Jc?n.nativeElement:n}class oN{}let cM=(()=>{class n{constructor(){this.destroyNode=null}static{this.__NG_ELEMENT_ID__=()=>function J6(){const n=Se(),e=To(fr().index,n);return(ks(e)?e:n)[Yt]}()}}return n})(),K6=(()=>{class n{static{this.\u0275prov=Yi({token:n,providedIn:"root",factory:()=>null})}}return n})();const dM={};function Gf(n,t,e,i,r=!1){for(;null!==e;){const s=t[e.index];null!==s&&i.push(pr(s)),Ps(s)&&fN(s,i);const o=e.type;if(8&o)Gf(n,t,e.child,i);else if(32&o){const a=_1(e,t);let l;for(;l=a();)i.push(l)}else if(16&o){const a=zL(t,e);if(Array.isArray(a))i.push(...a);else{const l=Qc(t[Jr]);Gf(l[Be],l,a,i,!0)}}e=r?e.projectionNext:e.next}return i}function fN(n,t){for(let e=mn;e!1,producerRecomputeValue:()=>{},consumerMarkedDirty:()=>{},consumerOnSignalRead:()=>{},consumerIsAlwaysLive:!0,consumerMarkedDirty:n=>{Tf(n.lView)},consumerOnSignalRead(){this.lView[Vc]=this}};function vN(n){return yN(n[Mf])}function mN(n){return yN(n[Ma])}function yN(n){for(;null!==n&&!Ps(n);)n=n[Ma];return n}function fM(n){return n.ngOriginalError}class eh{constructor(){this._console=console}handleError(t){const e=this._findOriginalError(t);this._console.error("ERROR",t),e&&this._console.error("ORIGINAL ERROR",e)}_findOriginalError(t){let e=t&&fM(t);for(;e&&fM(e);)e=fM(e);return e||null}}const IN=new Ht("",{providedIn:"root",factory:()=>Ri(eh).handleError.bind(void 0)}),MN=new Ht("",{providedIn:"root",factory:()=>!1}),Qt={};function Ey(n=1){DN(xi(),Se(),zs()+n,!1)}function DN(n,t,e,i){if(!i)if(3==(3&t[Ct])){const s=n.preOrderCheckHooks;null!==s&&_m(t,s,e)}else{const s=n.preOrderHooks;null!==s&&Um(t,s,0,e)}Gc(e)}function Ot(n,t=Di.Default){const e=Se();return null===e?Fi(n,t):RA(fr(),e,vt(n),t)}function xN(n,t,e,i,r,s){const o=Wi(null);try{let a=null;r&Gh.SignalBased&&(a=t[i][Ts]),null!==a&&void 0!==a.transformFn&&(s=a.transformFn(s)),r&Gh.HasDecoratorInputTransform&&(s=n.inputTransforms[i].call(t,s)),null!==n.setInput?n.setInput(t,a,s,e,i):sA(t,a,i,s)}finally{Wi(o)}}function Dy(n,t,e,i,r,s,o,a,l,h,c){const d=t.blueprint.slice();return d[Vr]=r,d[Ct]=204|i,(null!==h||n&&2048&n[Ct])&&(d[Ct]|=2048),uA(d),d[vn]=d[tu]=n,d[Er]=e,d[ql]=o||n&&n[ql],d[Yt]=a||n&&n[Yt],d[Xs]=l||n&&n[Xs]||null,d[Os]=s,d[Cf]=function Wj(){return Vj++}(),d[wa]=c,d[tA]=h,d[Jr]=2==t.type?n[Jr]:d,d}function Au(n,t,e,i,r){let s=n.data[t];if(null===s)s=function gM(n,t,e,i,r){const s=mA(),o=Jb(),l=n.data[t]=function LV(n,t,e,i,r,s){let o=t?t.injectorIndex:-1,a=0;return function su(){return null!==Rt.skipHydrationRootTNode}()&&(a|=128),{type:e,index:i,insertBeforeIndex:null,injectorIndex:o,directiveStart:-1,directiveEnd:-1,directiveStylingLast:-1,componentOffset:-1,propertyBindings:null,flags:a,providerIndexes:0,value:r,attrs:s,mergedAttrs:null,localNames:null,initialInputs:void 0,inputs:null,outputs:null,tView:null,next:null,prev:null,projectionNext:null,child:null,parent:t,projection:null,styles:null,stylesWithoutHost:null,residualStyles:void 0,classes:null,classesWithoutHost:null,residualClasses:void 0,classBindings:0,styleBindings:0}}(0,o?s:s&&s.parent,e,t,i,r);return null===n.firstChild&&(n.firstChild=l),null!==s&&(o?null==s.child&&null!==l.parent&&(s.child=l):null===s.next&&(s.next=l,l.prev=s)),l}(n,t,e,i,r),function MU(){return Rt.lFrame.inI18n}()&&(s.flags|=32);else if(64&s.type){s.type=e,s.value=i,s.attrs=r;const o=function Af(){const n=Rt.lFrame,t=n.currentTNode;return n.isParent?t:t.parent}();s.injectorIndex=null===o?-1:o.injectorIndex}return ol(s,!0),s}function Xf(n,t,e,i){if(0===e)return-1;const r=t.length;for(let s=0;sUt&&DN(n,t,Ut,!1),nl(o?2:0,r),e(i,r)}finally{Gc(s),nl(o?3:1,r)}}function vM(n,t,e){if(Vb(t)){const i=Wi(null);try{const s=t.directiveEnd;for(let o=t.directiveStart;onull;function NN(n,t,e,i,r){for(let s in t){if(!t.hasOwnProperty(s))continue;const o=t[s];if(void 0===o)continue;i??={};let a,l=Gh.None;Array.isArray(o)?(a=o[0],l=o[1]):a=o;let h=s;if(null!==r){if(!r.hasOwnProperty(s))continue;h=r[s]}0===n?ON(i,e,h,a,l):ON(i,e,h,a)}return i}function ON(n,t,e,i,r){let s;n.hasOwnProperty(e)?(s=n[e]).push(t,i):s=n[e]=[t,i],void 0!==r&&s.push(r)}function kN(n,t,e,i,r,s){for(let h=0;h0;){const e=n[--t];if("number"==typeof e&&e<0)return e}return 0})(o)!=a&&o.push(a),o.push(e,i,s)}}(n,t,i,Xf(n,e,r.hostVars,Qt),r)}function YV(n,t,e,i,r,s){const o=s[t];if(null!==o)for(let a=0;an.nextProducerIndex;)n.producerNode.pop(),n.producerLastReadVersion.pop(),n.producerIndexOfThis.pop()}}(a,o),function pV(n){n.lView[Vc]!==n&&(n.lView=null,gN.push(n))}(a)),n1()}}function _N(n,t){for(let e=vN(n);null!==e;e=mN(e))for(let i=mn;i-1&&(Ff(t,i),Qm(e,i))}this._attachedToViewContainer=!1}ly(this._lView[Be],this._lView)}onDestroy(t){!function Hm(n,t){if(256==(256&n[Ct]))throw new F(911,!1);null===n[Xh]&&(n[Xh]=[]),n[Xh].push(t)}(this._lView,t)}markForCheck(){qf(this._cdRefInjectingView||this._lView)}detach(){this._lView[Ct]&=-129}reattach(){$b(this._lView),this._lView[Ct]|=128}detectChanges(){this._lView[Ct]|=1024,function EM(n,t=!0){const e=n[ql],i=e.rendererFactory;i.begin?.();try{!function XV(n){DM(n,0);let t=0;for(;fA(n);){if(100===t)throw new F(103,!1);t++,DM(n,1)}}(n)}catch(s){throw t&&Ty(n,s),s}finally{i.end?.(),e.inlineEffectRunner?.flush()}}(this._lView,this.notifyErrorHandler)}checkNoChanges(){}attachToViewContainerRef(){if(this._appRef)throw new F(902,!1);this._attachedToViewContainer=!0}detachFromAppRef(){this._appRef=null,DL(this._lView[Be],this._lView)}attachToAppRef(t){if(this._attachedToViewContainer)throw new F(902,!1);this._appRef=t,$b(this._lView)}}const WN=new Set;function TM(n){return t=>{setTimeout(n,void 0,t)}}const Yo=class h7 extends Pt{constructor(t=!1){super(),this.__isAsync=t}emit(t){super.next(t)}subscribe(t,e,i){let r=t,s=e||(()=>null),o=i;if(t&&"object"==typeof t){const l=t;r=l.next?.bind(l),s=l.error?.bind(l),o=l.complete?.bind(l)}this.__isAsync&&(s=TM(s),r&&(r=TM(r)),o&&(o=TM(o)));const a=super.subscribe({next:r,error:s,complete:o});return t instanceof As&&t.add(a),a}};function YN(...n){}class zr{constructor({enableLongStackTrace:t=!1,shouldCoalesceEventChangeDetection:e=!1,shouldCoalesceRunChangeDetection:i=!1}){if(this.hasPendingMacrotasks=!1,this.hasPendingMicrotasks=!1,this.isStable=!0,this.onUnstable=new Yo(!1),this.onMicrotaskEmpty=new Yo(!1),this.onStable=new Yo(!1),this.onError=new Yo(!1),typeof Zone>"u")throw new F(908,!1);Zone.assertZonePatched();const r=this;r._nesting=0,r._outer=r._inner=Zone.current,Zone.TaskTrackingZoneSpec&&(r._inner=r._inner.fork(new Zone.TaskTrackingZoneSpec)),t&&Zone.longStackTraceZoneSpec&&(r._inner=r._inner.fork(Zone.longStackTraceZoneSpec)),r.shouldCoalesceEventChangeDetection=!i&&e,r.shouldCoalesceRunChangeDetection=i,r.lastRequestAnimationFrameId=-1,r.nativeRequestAnimationFrame=function c7(){const n="function"==typeof rr.requestAnimationFrame;let t=rr[n?"requestAnimationFrame":"setTimeout"],e=rr[n?"cancelAnimationFrame":"clearTimeout"];if(typeof Zone<"u"&&t&&e){const i=t[Zone.__symbol__("OriginalDelegate")];i&&(t=i);const r=e[Zone.__symbol__("OriginalDelegate")];r&&(e=r)}return{nativeRequestAnimationFrame:t,nativeCancelAnimationFrame:e}}().nativeRequestAnimationFrame,function p7(n){const t=()=>{!function u7(n){n.isCheckStableRunning||-1!==n.lastRequestAnimationFrameId||(n.lastRequestAnimationFrameId=n.nativeRequestAnimationFrame.call(rr,()=>{n.fakeTopEventTask||(n.fakeTopEventTask=Zone.root.scheduleEventTask("fakeTopEventTask",()=>{n.lastRequestAnimationFrameId=-1,LM(n),n.isCheckStableRunning=!0,AM(n),n.isCheckStableRunning=!1},void 0,()=>{},()=>{})),n.fakeTopEventTask.invoke()}),LM(n))}(n)};n._inner=n._inner.fork({name:"angular",properties:{isAngularZone:!0},onInvokeTask:(e,i,r,s,o,a)=>{if(function f7(n){return!(!Array.isArray(n)||1!==n.length)&&!0===n[0].data?.__ignore_ng_zone__}(a))return e.invokeTask(r,s,o,a);try{return QN(n),e.invokeTask(r,s,o,a)}finally{(n.shouldCoalesceEventChangeDetection&&"eventTask"===s.type||n.shouldCoalesceRunChangeDetection)&&t(),GN(n)}},onInvoke:(e,i,r,s,o,a,l)=>{try{return QN(n),e.invoke(r,s,o,a,l)}finally{n.shouldCoalesceRunChangeDetection&&t(),GN(n)}},onHasTask:(e,i,r,s)=>{e.hasTask(r,s),i===r&&("microTask"==s.change?(n._hasPendingMicrotasks=s.microTask,LM(n),AM(n)):"macroTask"==s.change&&(n.hasPendingMacrotasks=s.macroTask))},onHandleError:(e,i,r,s)=>(e.handleError(r,s),n.runOutsideAngular(()=>n.onError.emit(s)),!1)})}(r)}static isInAngularZone(){return typeof Zone<"u"&&!0===Zone.current.get("isAngularZone")}static assertInAngularZone(){if(!zr.isInAngularZone())throw new F(909,!1)}static assertNotInAngularZone(){if(zr.isInAngularZone())throw new F(909,!1)}run(t,e,i){return this._inner.run(t,e,i)}runTask(t,e,i,r){const s=this._inner,o=s.scheduleEventTask("NgZoneEvent: "+r,t,d7,YN,YN);try{return s.runTask(o,e,i)}finally{s.cancelTask(o)}}runGuarded(t,e,i){return this._inner.runGuarded(t,e,i)}runOutsideAngular(t){return this._outer.run(t)}}const d7={};function AM(n){if(0==n._nesting&&!n.hasPendingMicrotasks&&!n.isStable)try{n._nesting++,n.onMicrotaskEmpty.emit(null)}finally{if(n._nesting--,!n.hasPendingMicrotasks)try{n.runOutsideAngular(()=>n.onStable.emit(null))}finally{n.isStable=!0}}}function LM(n){n.hasPendingMicrotasks=!!(n._hasPendingMicrotasks||(n.shouldCoalesceEventChangeDetection||n.shouldCoalesceRunChangeDetection)&&-1!==n.lastRequestAnimationFrameId)}function QN(n){n._nesting++,n.isStable&&(n.isStable=!1,n.onUnstable.emit(null))}function GN(n){n._nesting--,AM(n)}let Zf=(()=>{class n{constructor(){this.handler=null,this.internalCallbacks=[]}execute(){const e=[...this.internalCallbacks];this.internalCallbacks.length=0;for(const r of e)r();return!!this.handler?.execute()||e.length>0}ngOnDestroy(){this.handler?.destroy(),this.handler=null,this.internalCallbacks.length=0}static{this.\u0275prov=Yi({token:n,providedIn:"root",factory:()=>new n})}}return n})();function y7(n,t){const e=To(t,n),i=e[Be];!function S7(n,t){for(let e=t.length;e0&&BL(n,e,s.join(" "))}}(u,w,f,i),void 0!==e&&function A7(n,t,e){const i=n.projection=[];for(let r=0;r=0;i--){const r=n[i];r.hostVars=t+=r.hostVars,r.hostAttrs=bf(r.hostAttrs,e=bf(e,r.hostAttrs))}}(i)}function N7(n,t){for(const e in t.inputs){if(!t.inputs.hasOwnProperty(e)||n.inputs.hasOwnProperty(e))continue;const i=t.inputs[e];if(void 0!==i&&(n.inputs[e]=i,n.declaredInputs[e]=t.declaredInputs[e],null!==t.inputTransforms)){const r=Array.isArray(i)?i[0]:i;if(!t.inputTransforms.hasOwnProperty(r))continue;n.inputTransforms??={},n.inputTransforms[r]=t.inputTransforms[r]}}}function Ly(n){return n===tl?{}:n===Qi?[]:n}function k7(n,t){const e=n.viewQuery;n.viewQuery=e?(i,r)=>{t(i,r),e(i,r)}:t}function P7(n,t){const e=n.contentQueries;n.contentQueries=e?(i,r,s)=>{t(i,r,s),e(i,r,s)}:t}function z7(n,t){const e=n.hostBindings;n.hostBindings=e?(i,r)=>{t(i,r),e(i,r)}:t}function Nu(n,t){return!t||null===t.firstChild||ny(n)}function ng(n,t,e,i=!0){const r=t[Be];if(function r6(n,t,e,i){const r=mn+i,s=e.length;i>0&&(e[r-1][Ma]=t),i{class n{static{this.__NG_ELEMENT_ID__=h9}}return n})();function h9(){return fO(fr(),Se())}const c9=xn,uO=class extends c9{constructor(t,e,i){super(),this._lContainer=t,this._hostTNode=e,this._hostLView=i}get element(){return Tu(this._hostTNode,this._hostLView)}get injector(){return new Vn(this._hostTNode,this._hostLView)}get parentInjector(){const t=Wm(this._hostTNode,this._hostLView);if(a1(t)){const e=Of(t,this._hostLView),i=Nf(t);return new Vn(e[Be].data[i+8],e)}return new Vn(null,this._hostLView)}clear(){for(;this.length>0;)this.remove(this.length-1)}get(t){const e=pO(this._lContainer);return null!==e&&e[t]||null}get length(){return this._lContainer.length-mn}createEmbeddedView(t,e,i){let r,s;"number"==typeof i?r=i:null!=i&&(r=i.index,s=i.injector);const a=t.createEmbeddedViewImpl(e||{},s,null);return this.insertImpl(a,r,Nu(this._hostTNode,null)),a}createComponent(t,e,i,r,s){const o=t&&!function kf(n){return"function"==typeof n}(t);let a;if(o)a=e;else{const f=e||{};a=f.index,i=f.injector,r=f.projectableNodes,s=f.environmentInjector||f.ngModuleRef}const l=o?t:new Jf(ci(t)),h=i||this.parentInjector;if(!s&&null==l.ngModule){const g=(o?h:this.parentInjector).get(Jl,null);g&&(s=g)}ci(l.componentType??{});const p=l.create(h,r,null,s);return this.insertImpl(p.hostView,a,Nu(this._hostTNode,null)),p}insert(t,e){return this.insertImpl(t,e,!0)}insertImpl(t,e,i){const r=t._lView;if(function hU(n){return Ps(n[vn])}(r)){const a=this.indexOf(t);if(-1!==a)this.detach(a);else{const l=r[vn],h=new uO(l,l[Os],l[vn]);h.detach(h.indexOf(t))}}const s=this._adjustIndex(e),o=this._lContainer;return ng(o,r,s,i),t.attachToViewContainerRef(),jA(BM(o),s,t),t}move(t,e){return this.insert(t,e)}indexOf(t){const e=pO(this._lContainer);return null!==e?e.indexOf(t):-1}remove(t){const e=this._adjustIndex(t,-1),i=Ff(this._lContainer,e);i&&(Qm(BM(this._lContainer),e),ly(i[Be],i))}detach(t){const e=this._adjustIndex(t,-1),i=Ff(this._lContainer,e);return i&&null!=Qm(BM(this._lContainer),e)?new $f(i):null}_adjustIndex(t,e=0){return t??this.length+e}};function pO(n){return n[8]}function BM(n){return n[8]||(n[8]=[])}function fO(n,t){let e;const i=t[n.index];return Ps(i)?e=i:(e=function zN(n,t,e,i){return[n,!0,0,t,null,i,null,e,null,null]}(i,t,null,n),t[n.index]=e,xy(t,e)),gO(e,t,n,i),new uO(e,n,t)}let gO=function mO(n,t,e,i){if(n[rl])return;let r;r=8&e.type?pr(i):function d9(n,t){const e=n[Yt],i=e.createComment(""),r=qs(t,n);return Zc(e,hy(e,r),i,function l6(n,t){return n.nextSibling(t)}(e,r),!1),i}(t,e),n[rl]=r};function Xu(n,t,e){const i=Se();return function Tn(n,t,e){return!Object.is(n[t],e)&&(n[t]=e,!0)}(i,function al(){return Rt.lFrame.bindingIndex++}(),t)&&function No(n,t,e,i,r,s,o,a){const l=qs(t,e);let c,h=t.inputs;!a&&null!=h&&(c=h[i])?(CM(n,e,c,i,r),Wc(t)&&function kV(n,t){const e=To(t,n);16&e[Ct]||(e[Ct]|=64)}(e,t.index)):3&t.type&&(i=function OV(n){return"class"===n?"className":"for"===n?"htmlFor":"formaction"===n?"formAction":"innerHtml"===n?"innerHTML":"readonly"===n?"readOnly":"tabindex"===n?"tabIndex":n}(i),r=null!=o?o(r,t.value||"",i):r,s.setProperty(l,i,r))}(xi(),function Pr(){const n=Rt.lFrame;return xf(n.tView,n.selectedIndex)}(),i,n,t,i[Yt],e,!1),Xu}function ZM(n,t,e,i,r){const o=r?"class":"style";CM(n,e,t.inputs[o],o,i)}function rc(n,t,e,i){const r=Se(),s=xi(),o=Ut+n,a=r[Yt],l=s.firstCreatePass?function B8(n,t,e,i,r,s){const o=t.consts,l=Au(t,n,2,i,sl(o,r));return function IM(n,t,e,i){if(vA()){const r=null===i?null:{"":-1},s=function FV(n,t){const e=n.directiveRegistry;let i=null,r=null;if(e)for(let s=0;s(qh(!0),ay(i,r,function xA(){return Rt.lFrame.currentNamespace}()));const $u="en-US";let wk=$u;function aw(n){return!!n&&"function"==typeof n.then}function Xk(n){return!!n&&"function"==typeof n.subscribe}function Gy(n,t,e,i){const r=Se(),s=xi(),o=fr();return function $k(n,t,e,i,r,s,o){const a=zm(i),h=n.firstCreatePass&&BN(n),c=t[Er],d=HN(t);let u=!0;if(3&i.type||o){const g=qs(i,t),v=o?o(g):g,y=d.length,S=o?M=>o(pr(M[i.index])):i.index;let b=null;if(!o&&a&&(b=function UW(n,t,e,i){const r=n.cleanup;if(null!=r)for(let s=0;sl?a[l]:null}"string"==typeof o&&(s+=2)}return null}(n,t,r,i.index)),null!==b)(b.__ngLastListenerFn__||b).__ngNextListenerFn__=s,b.__ngLastListenerFn__=s,u=!1;else{s=Jk(i,t,c,s,!1);const M=e.listen(v,r,s);d.push(s,M),h&&h.push(r,S,y,y+1)}}else s=Jk(i,t,c,s,!1);const p=i.outputs;let f;if(u&&null!==p&&(f=p[r])){const g=f.length;if(g)for(let v=0;v-1?To(n.index,t):t);let l=Zk(t,e,i,o),h=s.__ngNextListenerFn__;for(;h;)l=Zk(t,e,h,o)&&l,h=h.__ngNextListenerFn__;return r&&!1===l&&o.preventDefault(),l}}function QW(){return this._results[Symbol.iterator]()}class hw{get changes(){return this._changes??=new Yo}constructor(t=!1){this._emitDistinctChangesOnly=t,this.dirty=!0,this._results=[],this._changesDetected=!1,this._changes=void 0,this.length=0,this.first=void 0,this.last=void 0;const e=hw.prototype;e[Symbol.iterator]||(e[Symbol.iterator]=QW)}get(t){return this._results[t]}map(t){return this._results.map(t)}filter(t){return this._results.filter(t)}find(t){return this._results.find(t)}reduce(t,e){return this._results.reduce(t,e)}forEach(t){this._results.forEach(t)}some(t){return this._results.some(t)}toArray(){return this._results.slice()}toString(){return this._results.toString()}reset(t,e){this.dirty=!1;const i=function oo(n){return n.flat(Number.POSITIVE_INFINITY)}(t);(this._changesDetected=!function $U(n,t,e){if(n.length!==t.length)return!1;for(let i=0;i{class n{static{this.__NG_ELEMENT_ID__=qW}}return n})();const GW=ih,XW=class extends GW{constructor(t,e,i){super(),this._declarationLView=t,this._declarationTContainer=e,this.elementRef=i}get ssrId(){return this._declarationTContainer.tView?.ssrId||null}createEmbeddedView(t,e){return this.createEmbeddedViewImpl(t,e)}createEmbeddedViewImpl(t,e,i){const r=function rg(n,t,e,i){const r=t.tView,a=Dy(n,r,e,4096&n[Ct]?4096:16,null,t,null,null,null,i?.injector??null,i?.dehydratedView??null);a[wf]=n[t.index];const h=n[il];return null!==h&&(a[il]=h.createEmbeddedView(r)),NM(r,a,e),a}(this._declarationLView,this._declarationTContainer,t,{injector:e,dehydratedView:i});return new $f(r)}};function qW(){return Xy(fr(),Se())}function Xy(n,t){return 4&n.type?new XW(t,n,Tu(n,t)):null}class cw{constructor(t){this.queryList=t,this.matches=null}clone(){return new cw(this.queryList)}setDirty(){this.queryList.setDirty()}}class dw{constructor(t=[]){this.queries=t}createEmbeddedView(t){const e=t.queries;if(null!==e){const i=null!==t.contentQueries?t.contentQueries[0]:e.length,r=[];for(let s=0;s0)i.push(o[a/2]);else{const h=s[a+1],c=t[-l];for(let d=mn;d(qh(!0),function oy(n,t){return n.createText(t)}(t[Yt],i));function mw(n,t,e,i,r){if(n=vt(n),Array.isArray(n))for(let s=0;s>20;if(qc(n)||!n.multi){const p=new Lf(h,r,Ot),f=Sw(l,t,r?c:c+u,d);-1===f?(c1(Vm(a,o),s,l),yw(s,n,t.length),t.push(l),a.directiveStart++,a.directiveEnd++,r&&(a.providerIndexes+=1048576),e.push(p),o.push(p)):(e[f]=p,o[f]=p)}else{const p=Sw(l,t,c+u,d),f=Sw(l,t,c,c+u),v=f>=0&&e[f];if(r&&!v||!r&&!(p>=0&&e[p])){c1(Vm(a,o),s,l);const y=function yY(n,t,e,i,r){const s=new Lf(n,e,Ot);return s.multi=[],s.index=t,s.componentProviders=0,kP(s,r,i&&!e),s}(r?mY:vY,e.length,r,i,h);!r&&v&&(e[f].providerFactory=y),yw(s,n,t.length,0),t.push(l),a.directiveStart++,a.directiveEnd++,r&&(a.providerIndexes+=1048576),e.push(y),o.push(y)}else yw(s,n,p>-1?p:f,kP(e[r?f:p],h,!r&&i));!r&&i&&v&&e[f].componentProviders++}}}function yw(n,t,e,i){const r=qc(t),s=function gj(n){return!!n.useClass}(t);if(r||s){const l=(s?vt(t.useClass):t).prototype.ngOnDestroy;if(l){const h=n.destroyHooks||(n.destroyHooks=[]);if(!r&&t.multi){const c=h.indexOf(e);-1===c?h.push(e,[i,l]):h[c+1].push(i,l)}else h.push(e,l)}}}function kP(n,t,e){return e&&n.componentProviders++,n.multi.push(t)-1}function Sw(n,t,e,i){for(let r=e;r{e.providersResolver=(i,r)=>function gY(n,t,e){const i=xi();if(i.firstCreatePass){const r=Ca(n);mw(e,i.data,i.blueprint,r,!0),mw(t,i.data,i.blueprint,r,!1)}}(i,r?r(n):n,t)}}class sd{}class zP extends sd{constructor(t){super(),this.componentFactoryResolver=new KN(this),this.instance=null;const e=new yu([...t.providers,{provide:sd,useValue:this},{provide:by,useValue:this.componentFactoryResolver}],t.parent||Km(),t.debugName,new Set(["environment"]));this.injector=e,t.runEnvironmentInitializers&&e.resolveInjectorInitializers()}destroy(){this.injector.destroy()}onDestroy(t){this.injector.onDestroy(t)}}let wY=(()=>{class n{constructor(e){this._injector=e,this.cachedInjectors=new Map}getOrCreateStandaloneInjector(e){if(!e.standalone)return null;if(!this.cachedInjectors.has(e)){const i=qA(0,e.type),r=i.length>0?function MY(n,t,e=null){return new zP({providers:n,parent:t,debugName:e,runEnvironmentInitializers:!0}).injector}([i],this._injector,`Standalone[${e.type.name}]`):null;this.cachedInjectors.set(e,r)}return this.cachedInjectors.get(e)}ngOnDestroy(){try{for(const e of this.cachedInjectors.values())null!==e&&e.destroy()}finally{this.cachedInjectors.clear()}}static{this.\u0275prov=Yi({token:n,providedIn:"environment",factory:()=>new n(Fi(Jl))})}}return n})();function RP(n){(function Kc(n){WN.has(n)||(WN.add(n),performance?.mark?.("mark_feature_usage",{detail:{feature:n}}))})("NgStandalone"),n.getStandaloneInjector=t=>t.get(wY).getOrCreateStandaloneInjector(n)}let Aw=(()=>{class n{constructor(){this.taskId=0,this.pendingTasks=new Set,this.hasPendingTasks=new _o(!1)}get _hasPendingTasks(){return this.hasPendingTasks.value}add(){this._hasPendingTasks||this.hasPendingTasks.next(!0);const e=this.taskId++;return this.pendingTasks.add(e),e}remove(e){this.pendingTasks.delete(e),0===this.pendingTasks.size&&this._hasPendingTasks&&this.hasPendingTasks.next(!1)}ngOnDestroy(){this.pendingTasks.clear(),this._hasPendingTasks&&this.hasPendingTasks.next(!1)}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();const g2=new Ht(""),XQ=new Ht("");let Pw=(()=>{class n{constructor(){this.initialized=!1,this.done=!1,this.donePromise=new Promise((e,i)=>{this.resolve=e,this.reject=i}),this.appInits=Ri(XQ,{optional:!0})??[]}runInitializers(){if(this.initialized)return;const e=[];for(const r of this.appInits){const s=r();if(aw(s))e.push(s);else if(Xk(s)){const o=new Promise((a,l)=>{s.subscribe({complete:a,error:l})});e.push(o)}}const i=()=>{this.done=!0,this.resolve()};Promise.all(e).then(()=>{i()}).catch(r=>{this.reject(r)}),0===e.length&&i(),this.initialized=!0}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();const v2=new Ht("");let Ku=(()=>{class n{constructor(){this._bootstrapListeners=[],this._runningTick=!1,this._destroyed=!1,this._destroyListeners=[],this._views=[],this.internalErrorHandler=Ri(IN),this.afterRenderEffectManager=Ri(Zf),this.componentTypes=[],this.components=[],this.isStable=Ri(Aw).hasPendingTasks.pipe(jr(e=>!e)),this._injector=Ri(Jl)}get destroyed(){return this._destroyed}get injector(){return this._injector}bootstrap(e,i){const r=e instanceof nN;if(!this._injector.get(Pw).done)throw!r&&function jc(n){const t=ci(n)||jn(n)||gs(n);return null!==t&&t.standalone}(e),new F(405,!1);let o;o=r?e:this._injector.get(by).resolveComponentFactory(e),this.componentTypes.push(o.componentType);const a=function $Q(n){return n.isBoundToModule}(o)?void 0:this._injector.get(sd),h=o.create(Wo.NULL,[],i||o.selector,a),c=h.location.nativeElement,d=h.injector.get(g2,null);return d?.registerApplication(c),h.onDestroy(()=>{this.detachView(h.hostView),e0(this.components,h),d?.unregisterApplication(c)}),this._loadComponent(h),h}tick(){if(this._runningTick)throw new F(101,!1);try{this._runningTick=!0;for(let e of this._views)e.detectChanges()}catch(e){this.internalErrorHandler(e)}finally{try{this.afterRenderEffectManager.execute()}catch(e){this.internalErrorHandler(e)}this._runningTick=!1}}attachView(e){const i=e;this._views.push(i),i.attachToAppRef(this)}detachView(e){const i=e;e0(this._views,i),i.detachFromAppRef()}_loadComponent(e){this.attachView(e.hostView),this.tick(),this.components.push(e);const i=this._injector.get(v2,[]);[...this._bootstrapListeners,...i].forEach(r=>r(e))}ngOnDestroy(){if(!this._destroyed)try{this._destroyListeners.forEach(e=>e()),this._views.slice().forEach(e=>e.destroy())}finally{this._destroyed=!0,this._views=[],this._bootstrapListeners=[],this._destroyListeners=[]}}onDestroy(e){return this._destroyListeners.push(e),()=>e0(this._destroyListeners,e)}destroy(){if(this._destroyed)throw new F(406,!1);const e=this._injector;e.destroy&&!e.destroyed&&e.destroy()}get viewCount(){return this._views.length}warnIfDestroyed(){}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();function e0(n,t){const e=n.indexOf(t);e>-1&&n.splice(e,1)}let JQ=(()=>{class n{constructor(){this.zone=Ri(zr),this.applicationRef=Ri(Ku)}initialize(){this._onMicrotaskEmptySubscription||(this._onMicrotaskEmptySubscription=this.zone.onMicrotaskEmpty.subscribe({next:()=>{this.zone.run(()=>{this.applicationRef.tick()})}}))}ngOnDestroy(){this._onMicrotaskEmptySubscription?.unsubscribe()}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();function b2(n){return[{provide:zr,useFactory:n},{provide:mu,multi:!0,useFactory:()=>{const t=Ri(JQ,{optional:!0});return()=>t.initialize()}},{provide:mu,multi:!0,useFactory:()=>{const t=Ri(tG);return()=>{t.initialize()}}},{provide:IN,useFactory:KQ}]}function KQ(){const n=Ri(zr),t=Ri(eh);return e=>n.runOutsideAngular(()=>t.handleError(e))}function eG(n){return function b1(n){return{\u0275providers:n}}([[],b2(()=>new zr(function M2(n){return{enableLongStackTrace:!1,shouldCoalesceEventChangeDetection:n?.eventCoalescing??!1,shouldCoalesceRunChangeDetection:n?.runCoalescing??!1}}(n)))])}let tG=(()=>{class n{constructor(){this.subscription=new As,this.initialized=!1,this.zone=Ri(zr),this.pendingTasks=Ri(Aw)}initialize(){if(this.initialized)return;this.initialized=!0;let e=null;!this.zone.isStable&&!this.zone.hasPendingMacrotasks&&!this.zone.hasPendingMicrotasks&&(e=this.pendingTasks.add()),this.zone.runOutsideAngular(()=>{this.subscription.add(this.zone.onStable.subscribe(()=>{zr.assertNotInAngularZone(),queueMicrotask(()=>{null!==e&&!this.zone.hasPendingMacrotasks&&!this.zone.hasPendingMicrotasks&&(this.pendingTasks.remove(e),e=null)})}))}),this.subscription.add(this.zone.onUnstable.subscribe(()=>{zr.assertInAngularZone(),e??=this.pendingTasks.add()}))}ngOnDestroy(){this.subscription.unsubscribe()}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();const rh=new Ht("",{providedIn:"root",factory:()=>Ri(rh,Di.Optional|Di.SkipSelf)||function iG(){return typeof $localize<"u"&&$localize.locale||$u}()}),zw=new Ht("");let sc=null;function DG(n){try{const{rootComponent:t,appProviders:e,platformProviders:i}=n,r=function aG(n=[]){if(sc)return sc;const t=function E2(n=[],t){return Wo.create({name:t,providers:[{provide:C1,useValue:"platform"},{provide:zw,useValue:new Set([()=>sc=null])},...n]})}(n);return sc=t,function m2(){!function Mb(n){qd=n}(()=>{throw new F(600,!1)})}(),function D2(n){n.get(oL,null)?.forEach(e=>e())}(t),t}(i),s=[eG(),...e||[]],a=new zP({providers:s,parent:r,debugName:"",runEnvironmentInitializers:!1}).injector,l=a.get(zr);return l.run(()=>{a.resolveInjectorInitializers();const h=a.get(eh,null);let c;l.runOutsideAngular(()=>{c=l.onError.subscribe({next:p=>{h.handleError(p)}})});const d=()=>a.destroy(),u=r.get(zw);return u.add(d),a.onDestroy(()=>{c.unsubscribe(),u.delete(d)}),function y2(n,t,e){try{const i=e();return aw(i)?i.catch(r=>{throw t.runOutsideAngular(()=>n.handleError(r)),r}):i}catch(i){throw t.runOutsideAngular(()=>n.handleError(i)),i}}(h,l,()=>{const p=a.get(Pw);return p.runInitializers(),p.donePromise.then(()=>{!function Ck(n){ro(n,"Expected localeId to be defined"),"string"==typeof n&&(wk=n.toLowerCase().replace(/_/g,"-"))}(a.get(rh,$u)||$u);const g=a.get(Ku);return void 0!==t&&g.bootstrap(t),g})})})}catch(t){return Promise.reject(t)}}let $2=null;function Vw(){return $2}class UG{}const ad=new Ht("");let sq=(()=>{class n{static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275mod=Nm({type:n})}static{this.\u0275inj=yf({})}}return n})();function uz(n){return"server"===n}class kq extends UG{constructor(){super(...arguments),this.supportsDOMEvents=!0}}class oC extends kq{static makeCurrent(){!function _G(n){$2??=n}(new oC)}onAndCancel(t,e,i){return t.addEventListener(e,i),()=>{t.removeEventListener(e,i)}}dispatchEvent(t,e){t.dispatchEvent(e)}remove(t){t.parentNode&&t.parentNode.removeChild(t)}createElement(t,e){return(e=e||this.getDefaultDocument()).createElement(t)}createHtmlDocument(){return document.implementation.createHTMLDocument("fakeTitle")}getDefaultDocument(){return document}isElementNode(t){return t.nodeType===Node.ELEMENT_NODE}isShadowRoot(t){return t instanceof DocumentFragment}getGlobalEventTarget(t,e){return"window"===e?window:"document"===e?t:"body"===e?t.body:null}getBaseHref(t){const e=function Pq(){return Eg=Eg||document.querySelector("base"),Eg?Eg.getAttribute("href"):null}();return null==e?null:function zq(n){return new URL(n,document.baseURI).pathname}(e)}resetBaseElement(){Eg=null}getUserAgent(){return window.navigator.userAgent}getCookie(t){return function xX(n,t){t=encodeURIComponent(t);for(const e of n.split(";")){const i=e.indexOf("="),[r,s]=-1==i?[e,""]:[e.slice(0,i),e.slice(i+1)];if(r.trim()===t)return decodeURIComponent(s)}return null}(document.cookie,t)}}let Eg=null,Hq=(()=>{class n{build(){return new XMLHttpRequest}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();const aC=new Ht("");let vz=(()=>{class n{constructor(e,i){this._zone=i,this._eventNameToPlugin=new Map,e.forEach(r=>{r.manager=this}),this._plugins=e.slice().reverse()}addEventListener(e,i,r){return this._findPluginFor(i).addEventListener(e,i,r)}getZone(){return this._zone}_findPluginFor(e){let i=this._eventNameToPlugin.get(e);if(i)return i;if(i=this._plugins.find(s=>s.supports(e)),!i)throw new F(5101,!1);return this._eventNameToPlugin.set(e,i),i}static{this.\u0275fac=function(i){return new(i||n)(Fi(aC),Fi(zr))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();class mz{constructor(t){this._doc=t}}const lC="ng-app-id";let yz=(()=>{class n{constructor(e,i,r,s={}){this.doc=e,this.appId=i,this.nonce=r,this.platformId=s,this.styleRef=new Map,this.hostNodes=new Set,this.styleNodesInDOM=this.collectServerRenderedStyles(),this.platformIsServer=uz(s),this.resetHostNodes()}addStyles(e){for(const i of e)1===this.changeUsageCount(i,1)&&this.onStyleAdded(i)}removeStyles(e){for(const i of e)this.changeUsageCount(i,-1)<=0&&this.onStyleRemoved(i)}ngOnDestroy(){const e=this.styleNodesInDOM;e&&(e.forEach(i=>i.remove()),e.clear());for(const i of this.getAllStyles())this.onStyleRemoved(i);this.resetHostNodes()}addHost(e){this.hostNodes.add(e);for(const i of this.getAllStyles())this.addStyleToHost(e,i)}removeHost(e){this.hostNodes.delete(e)}getAllStyles(){return this.styleRef.keys()}onStyleAdded(e){for(const i of this.hostNodes)this.addStyleToHost(i,e)}onStyleRemoved(e){const i=this.styleRef;i.get(e)?.elements?.forEach(r=>r.remove()),i.delete(e)}collectServerRenderedStyles(){const e=this.doc.head?.querySelectorAll(`style[${lC}="${this.appId}"]`);if(e?.length){const i=new Map;return e.forEach(r=>{null!=r.textContent&&i.set(r.textContent,r)}),i}return null}changeUsageCount(e,i){const r=this.styleRef;if(r.has(e)){const s=r.get(e);return s.usage+=i,s.usage}return r.set(e,{usage:i,elements:[]}),i}getStyleElement(e,i){const r=this.styleNodesInDOM,s=r?.get(i);if(s?.parentNode===e)return r.delete(i),s.removeAttribute(lC),s;{const o=this.doc.createElement("style");return this.nonce&&o.setAttribute("nonce",this.nonce),o.textContent=i,this.platformIsServer&&o.setAttribute(lC,this.appId),e.appendChild(o),o}}addStyleToHost(e,i){const r=this.getStyleElement(e,i),s=this.styleRef,o=s.get(i)?.elements;o?o.push(r):s.set(i,{elements:[r],usage:1})}resetHostNodes(){const e=this.hostNodes;e.clear(),e.add(this.doc.head)}static{this.\u0275fac=function(i){return new(i||n)(Fi(ad),Fi(N1),Fi(aL,8),Fi(Iu))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();const hC={svg:"http://www.w3.org/2000/svg",xhtml:"http://www.w3.org/1999/xhtml",xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/",math:"http://www.w3.org/1998/MathML/"},cC=/%COMP%/g,Uq=new Ht("",{providedIn:"root",factory:()=>!0});function Iz(n,t){return t.map(e=>e.replace(cC,n))}let bz=(()=>{class n{constructor(e,i,r,s,o,a,l,h=null){this.eventManager=e,this.sharedStylesHost=i,this.appId=r,this.removeStylesOnCompDestroy=s,this.doc=o,this.platformId=a,this.ngZone=l,this.nonce=h,this.rendererByCompId=new Map,this.platformIsServer=uz(a),this.defaultRenderer=new dC(e,o,l,this.platformIsServer)}createRenderer(e,i){if(!e||!i)return this.defaultRenderer;this.platformIsServer&&i.encapsulation===Ia.ShadowDom&&(i={...i,encapsulation:Ia.Emulated});const r=this.getOrCreateRenderer(e,i);return r instanceof wz?r.applyToHost(e):r instanceof uC&&r.applyStyles(),r}getOrCreateRenderer(e,i){const r=this.rendererByCompId;let s=r.get(i.id);if(!s){const o=this.doc,a=this.ngZone,l=this.eventManager,h=this.sharedStylesHost,c=this.removeStylesOnCompDestroy,d=this.platformIsServer;switch(i.encapsulation){case Ia.Emulated:s=new wz(l,h,i,this.appId,c,o,a,d);break;case Ia.ShadowDom:return new Yq(l,h,e,i,o,a,this.nonce,d);default:s=new uC(l,h,i,c,o,a,d)}r.set(i.id,s)}return s}ngOnDestroy(){this.rendererByCompId.clear()}static{this.\u0275fac=function(i){return new(i||n)(Fi(vz),Fi(yz),Fi(N1),Fi(Uq),Fi(ad),Fi(Iu),Fi(zr),Fi(aL))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();class dC{constructor(t,e,i,r){this.eventManager=t,this.doc=e,this.ngZone=i,this.platformIsServer=r,this.data=Object.create(null),this.throwOnSyntheticProps=!0,this.destroyNode=null}destroy(){}createElement(t,e){return e?this.doc.createElementNS(hC[e]||e,t):this.doc.createElement(t)}createComment(t){return this.doc.createComment(t)}createText(t){return this.doc.createTextNode(t)}appendChild(t,e){(Mz(t)?t.content:t).appendChild(e)}insertBefore(t,e,i){t&&(Mz(t)?t.content:t).insertBefore(e,i)}removeChild(t,e){t&&t.removeChild(e)}selectRootElement(t,e){let i="string"==typeof t?this.doc.querySelector(t):t;if(!i)throw new F(-5104,!1);return e||(i.textContent=""),i}parentNode(t){return t.parentNode}nextSibling(t){return t.nextSibling}setAttribute(t,e,i,r){if(r){e=r+":"+e;const s=hC[r];s?t.setAttributeNS(s,e,i):t.setAttribute(e,i)}else t.setAttribute(e,i)}removeAttribute(t,e,i){if(i){const r=hC[i];r?t.removeAttributeNS(r,e):t.removeAttribute(`${i}:${e}`)}else t.removeAttribute(e)}addClass(t,e){t.classList.add(e)}removeClass(t,e){t.classList.remove(e)}setStyle(t,e,i,r){r&(Kh.DashCase|Kh.Important)?t.style.setProperty(e,i,r&Kh.Important?"important":""):t.style[e]=i}removeStyle(t,e,i){i&Kh.DashCase?t.style.removeProperty(e):t.style[e]=""}setProperty(t,e,i){null!=t&&(t[e]=i)}setValue(t,e){t.nodeValue=e}listen(t,e,i){if("string"==typeof t&&!(t=Vw().getGlobalEventTarget(this.doc,t)))throw new Error(`Unsupported event target ${t} for event ${e}`);return this.eventManager.addEventListener(t,e,this.decoratePreventDefault(i))}decoratePreventDefault(t){return e=>{if("__ngUnwrap__"===e)return t;!1===(this.platformIsServer?this.ngZone.runGuarded(()=>t(e)):t(e))&&e.preventDefault()}}}function Mz(n){return"TEMPLATE"===n.tagName&&void 0!==n.content}class Yq extends dC{constructor(t,e,i,r,s,o,a,l){super(t,s,o,l),this.sharedStylesHost=e,this.hostEl=i,this.shadowRoot=i.attachShadow({mode:"open"}),this.sharedStylesHost.addHost(this.shadowRoot);const h=Iz(r.id,r.styles);for(const c of h){const d=document.createElement("style");a&&d.setAttribute("nonce",a),d.textContent=c,this.shadowRoot.appendChild(d)}}nodeOrShadowRoot(t){return t===this.hostEl?this.shadowRoot:t}appendChild(t,e){return super.appendChild(this.nodeOrShadowRoot(t),e)}insertBefore(t,e,i){return super.insertBefore(this.nodeOrShadowRoot(t),e,i)}removeChild(t,e){return super.removeChild(this.nodeOrShadowRoot(t),e)}parentNode(t){return this.nodeOrShadowRoot(super.parentNode(this.nodeOrShadowRoot(t)))}destroy(){this.sharedStylesHost.removeHost(this.shadowRoot)}}class uC extends dC{constructor(t,e,i,r,s,o,a,l){super(t,s,o,a),this.sharedStylesHost=e,this.removeStylesOnCompDestroy=r,this.styles=l?Iz(l,i.styles):i.styles}applyStyles(){this.sharedStylesHost.addStyles(this.styles)}destroy(){this.removeStylesOnCompDestroy&&this.sharedStylesHost.removeStyles(this.styles)}}class wz extends uC{constructor(t,e,i,r,s,o,a,l){const h=r+"-"+i.id;super(t,e,i,s,o,a,l,h),this.contentAttr=function jq(n){return"_ngcontent-%COMP%".replace(cC,n)}(h),this.hostAttr=function Vq(n){return"_nghost-%COMP%".replace(cC,n)}(h)}applyToHost(t){this.applyStyles(),this.setAttribute(t,this.hostAttr,"")}createElement(t,e){const i=super.createElement(t,e);return super.setAttribute(i,this.contentAttr,""),i}}let Qq=(()=>{class n extends mz{constructor(e){super(e)}supports(e){return!0}addEventListener(e,i,r){return e.addEventListener(i,r,!1),()=>this.removeEventListener(e,i,r)}removeEventListener(e,i,r){return e.removeEventListener(i,r)}static{this.\u0275fac=function(i){return new(i||n)(Fi(ad))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();const Cz=["alt","control","meta","shift"],Gq={"\b":"Backspace","\t":"Tab","\x7f":"Delete","\x1b":"Escape",Del:"Delete",Esc:"Escape",Left:"ArrowLeft",Right:"ArrowRight",Up:"ArrowUp",Down:"ArrowDown",Menu:"ContextMenu",Scroll:"ScrollLock",Win:"OS"},Xq={alt:n=>n.altKey,control:n=>n.ctrlKey,meta:n=>n.metaKey,shift:n=>n.shiftKey};let qq=(()=>{class n extends mz{constructor(e){super(e)}supports(e){return null!=n.parseEventName(e)}addEventListener(e,i,r){const s=n.parseEventName(i),o=n.eventCallback(s.fullKey,r,this.manager.getZone());return this.manager.getZone().runOutsideAngular(()=>Vw().onAndCancel(e,s.domEventName,o))}static parseEventName(e){const i=e.toLowerCase().split("."),r=i.shift();if(0===i.length||"keydown"!==r&&"keyup"!==r)return null;const s=n._normalizeKey(i.pop());let o="",a=i.indexOf("code");if(a>-1&&(i.splice(a,1),o="code."),Cz.forEach(h=>{const c=i.indexOf(h);c>-1&&(i.splice(c,1),o+=h+".")}),o+=s,0!=i.length||0===s.length)return null;const l={};return l.domEventName=r,l.fullKey=o,l}static matchEventFullKeyCode(e,i){let r=Gq[e.key]||e.key,s="";return i.indexOf("code.")>-1&&(r=e.code,s="code."),!(null==r||!r)&&(r=r.toLowerCase()," "===r?r="space":"."===r&&(r="dot"),Cz.forEach(o=>{o!==r&&(0,Xq[o])(e)&&(s+=o+".")}),s+=r,s===i)}static eventCallback(e,i,r){return s=>{n.matchEventFullKeyCode(s,e)&&r.runGuarded(()=>i(s))}}static _normalizeKey(e){return"esc"===e?"escape":e}static{this.\u0275fac=function(i){return new(i||n)(Fi(ad))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();function Ez(n){return{appProviders:[...i$,...n?.providers??[]],platformProviders:e$}}const e$=[{provide:Iu,useValue:"browser"},{provide:oL,useValue:function Zq(){oC.makeCurrent()},multi:!0},{provide:ad,useFactory:function Kq(){return function Aj(n){L1=n}(document),document},deps:[]}],i$=[{provide:C1,useValue:"root"},{provide:eh,useFactory:function Jq(){return new eh},deps:[]},{provide:aC,useClass:Qq,multi:!0,deps:[ad,zr,Iu]},{provide:aC,useClass:qq,multi:!0,deps:[ad]},bz,yz,vz,{provide:oN,useExisting:bz},{provide:class cq{},useClass:Hq,deps:[]},[]];var o$=0,pC=!1;function w0(n,t){var e=t;return e.unshift(void 0),new(Function.prototype.bind.apply(n,e))}function Y(n,t){for(var e=t,i=n.replace(/\[/g,".").replace(/\]/g,"").split("."),r=0;r"u"}function wi(n){return n+"_"+o$++}function E0(n,t){return n===t||!(n===document||!n)&&E0(n.parentNode,t)}function Tg(n){try{throw new Error(n)}catch(t){throw new Error(t.message+"\n"+t.stack)}}function Re(n){var t=n+"";return t.match(/auto|cm|mm|in|px|pt|pc|%|em|ex|ch|rem|vw|vh|vmin|vmax/)?t:t+"px"}function ce(){return pC}var Ag,n,t,d$={latn:{_digits:"0123456789",_type:"numeric"}},Lz={decimal:".",group:",",percentSign:"%",plusSign:"+",minusSign:"-",infinity:"\u221e",nan:"NaN",exponential:"E"},Nz=[0,1,2,3,4,5,6,7,8,9],Rr=function(){function n(){}return n.getMainObject=function(t,e){return Y(ce()?e:"main."+e,t)},n.getNumberingSystem=function(t){return Y("supplemental.numberingSystems",t)||this.numberingSystems},n.reverseObject=function(t,e){for(var r={},s=0,o=e||Object.keys(t);s13&&(f+=1,o-=12),o-=1,a=f-4716;var y=u-24e5,S=10631/30,b=u-1948084,M=Math.floor(b/10631);b-=10631*M;var w=Math.floor((b-.1335)/S),C=30*M+w;b-=Math.floor(w*S+.1335);var D=Math.floor((b+28.5001)/29.5);13===D&&(D=12);for(var A=b-Math.floor(29.5001*D-29),x=0;xy);x++);var R=x+16260,L=Math.floor((R-1)/12),O=L+1,N=R-12*L,T=y-t[x-1]+1;return(T+"").length>2&&(T=A,N=D,O=C),{year:O,month:N,date:T}},n.toGregorian=function i(r,s,o){var g=Math.floor(o+t[12*(r-1)+1+(s-1)-16260-1]-1+24e5+.5),v=Math.floor((g-1867216.25)/36524.25),y=1524+(v=g+1+v-Math.floor(v/4)),S=Math.floor((y-122.1)/365.25),b=Math.floor(365.25*S),M=Math.floor((y-b)/30.6001),w=y-b-Math.floor(30.6001*M),C=M-(M>13.5?13:1),D=S-(C>2.5?4716:4715);return D<=0&&C--,new Date(D+"/"+C+"/"+w)};var ut,f$=/\/MMMMM|MMMM|MMM|a|LLLL|LLL|EEEEE|EEEE|E|K|cccc|ccc|WW|W|G+|z+/gi,Oz="stand-alone",g$=["sun","mon","tue","wed","thu","fri","sat"],kz={m:"getMinutes",h:"getHours",H:"getHours",s:"getSeconds",d:"getDate",f:"getMilliseconds"},Pz=function(){function n(){}return n.dateFormat=function(t,e,i){var r=this,s=ut.getDependables(i,t,e.calendar),o=Y("parserObject.numbers",s),a=s.dateObject,l={isIslamic:ut.islamicRegex.test(e.calendar)};ce()&&e.isServerRendered&&(e=ut.compareBlazorDateFormats(e,t));var h=e.format||ut.getResultantPattern(e.skeleton,s.dateObject,e.type,!1,ce()?t:"");if(l.dateSeperator=ce()?Y("dateSeperator",a):ut.getDateSeparator(s.dateObject),st(h))Tg("Format options or type given must be invalid");else{h=ut.ConvertDateToWeekFormat(h),ce()&&(h=h.replace(/tt/,"a")),l.pattern=h,l.numMapper=ce()?ze({},o):Rr.getNumberMapper(s.parserObject,Rr.getNumberingSystem(i));for(var d=0,u=h.match(f$)||[];d2?r+=e.month[""+u]:f=!0;break;case"E":case"c":r+=e.weekday[""+g$[t.getDay()]];break;case"H":case"h":case"m":case"s":case"d":case"f":if(f=!0,"d"===d)u=o.date;else if("f"===d){f=!1,g=!0;var y=(p=(p=t[""+kz[""+d]]().toString()).substring(0,c)).length;if(c!==y){if(c>3)continue;for(var S=0;S0?1:0],o=Math.abs(t);return s.replace(/HH?|mm/g,function(a){var l=a.length,h=-1!==a.indexOf("H");return i.checkTwodigitNumber(Math.floor(h?o/60:o%60),l)})},n}(),zz={ms:"minimumSignificantDigits",ls:"maximumSignificantDigits",mf:"minimumFractionDigits",lf:"maximumFractionDigits"},rp=["infinity","nan","group","decimal","exponential"],Rz=function(){function n(){}return n.numberFormatter=function(t,e,i){var l,r=this,s=ze({},e),o={},a={},h=ut.getDependables(i,t,"",!0),c=h.numericObject;a.numberMapper=ce()?ze({},c):Rr.getNumberMapper(h.parserObject,Rr.getNumberingSystem(i),!0),a.currencySymbol=ce()?Y("currencySymbol",c):ut.getCurrencySymbol(h.numericObject,s.currency||Og,e.altSymbol,e.ignoreCurrency),a.percentSymbol=ce()?Y("numberSymbols.percentSign",c):a.numberMapper.numberSymbols.percentSign,a.minusSymbol=ce()?Y("numberSymbols.minusSign",c):a.numberMapper.numberSymbols.minusSign;var d=a.numberMapper.numberSymbols;if(e.format&&!ut.formatRegex.test(e.format))o=ut.customFormat(e.format,a,h.numericObject),!st(s.useGrouping)&&s.useGrouping&&(s.useGrouping=o.pData.useGrouping);else{if(ze(s,ut.getProperNumericSkeleton(e.format||"N")),s.isCurrency="currency"===s.type,s.isPercent="percent"===s.type,ce()||(l=ut.getSymbolPattern(s.type,a.numberMapper.numberSystem,h.numericObject,s.isAccount)),s.groupOne=this.checkValueRange(s.maximumSignificantDigits,s.minimumSignificantDigits,!0),this.checkValueRange(s.maximumFractionDigits,s.minimumFractionDigits,!1,!0),st(s.fractionDigits)||(s.minimumFractionDigits=s.maximumFractionDigits=s.fractionDigits),st(s.useGrouping)&&(s.useGrouping=!0),s.isCurrency&&!ce()&&(l=l.replace(/\u00A4/g,ut.defaultCurrency)),ce())o.nData=ze({},{},Y(s.type+"nData",c)),o.pData=ze({},{},Y(s.type+"pData",c)),"currency"===s.type&&e.currency&&ut.replaceBlazorCurrency([o.pData,o.nData],a.currencySymbol,e.currency);else{var u=l.split(";");o.nData=ut.getFormatData(u[1]||"-"+u[0],!0,a.currencySymbol),o.pData=ut.getFormatData(u[0],!1,a.currencySymbol),s.useGrouping&&(s.groupSeparator=d[rp[2]],s.groupData=this.getGroupingDetails(u[0]))}if(st(s.minimumFractionDigits)&&(s.minimumFractionDigits=o.nData.minimumFraction),st(s.maximumFractionDigits)){var f=o.nData.maximumFraction;s.maximumFractionDigits=st(f)&&s.isPercent?0:f}var g=s.minimumFractionDigits,v=s.maximumFractionDigits;!st(g)&&!st(v)&&g>v&&(s.maximumFractionDigits=g)}return ze(o.nData,s),ze(o.pData,s),function(y){return isNaN(y)?d[rp[1]]:isFinite(y)?r.intNumberFormatter(y,o,a,e):d[rp[0]]}},n.getGroupingDetails=function(t){var e={},i=t.match(ut.negativeDataRegex);if(i&&i[4]){var r=i[4],s=r.lastIndexOf(",");if(-1!==s){var o=r.split(".")[0];e.primary=o.length-s-1;var a=r.lastIndexOf(",",s-1);-1!==a&&(e.secondary=s-1-a)}}return e},n.checkValueRange=function(t,e,i,r){var s=r?"f":"s",o=0,a=zz["l"+s],l=zz["m"+s];if(st(t)||(this.checkRange(t,a,r),o++),st(e)||(this.checkRange(e,l,r),o++),2===o){if(!(tr[1])&&Tg(e+"value must be within the range"+r[0]+"to"+r[1])},n.intNumberFormatter=function(t,e,i,r){var s;if(!st(e.nData.type)){t<0?(t*=-1,s=e.nData):s=0===t&&e.zeroData||e.pData;var o="";if(s.isPercent&&(t*=100),s.groupOne)o=this.processSignificantDigits(t,s.minimumSignificantDigits,s.maximumSignificantDigits);else if(o=this.processFraction(t,s.minimumFractionDigits,s.maximumFractionDigits,r),s.minimumIntegerDigits&&(o=this.processMinimumIntegers(o,s.minimumIntegerDigits)),i.isCustomFormat&&s.minimumFractionDigits=0&&"0"===l[parseInt(c.toString(),10)]&&c>=s.minimumFractionDigits;c--)l=l.slice(0,c);o=a[0]+"."+l}return"scientific"===s.type&&(o=(o=t.toExponential(s.maximumFractionDigits)).replace("e",i.numberMapper.numberSymbols[rp[4]])),o=o.replace(".",i.numberMapper.numberSymbols[rp[3]]),o="#,###,,;(#,###,,)"===s.format?this.customPivotFormat(parseInt(o,10)):o,s.useGrouping&&(o=this.groupNumbers(o,s.groupData.primary,s.groupSeparator||",",i.numberMapper.numberSymbols[rp[3]]||".",s.groupData.secondary)),o=Rr.convertValueParts(o,ut.latnParseRegex,i.numberMapper.mapper),"N/A"===s.nlead?s.nlead:"0"===o&&r&&"0"===r.format?o+s.nend:s.nlead+o+s.nend}},n.processSignificantDigits=function(t,e,i){var r=t+"";return r.lengthe;)c=l.slice(h-e,h)+(c.length?i+c:""),h-=e,o&&(e=s,o=!1);return a[0]=l.slice(0,h)+(c.length?i:"")+c,a.join(r)},n.processFraction=function(t,e,i,r){var s=(t+"").split(".")[1],o=s?s.length:0;if(e&&oi||0===i))return t.toFixed(i);var h=t+"";return"0"===h[0]&&r&&"###.00"===r.format&&(h=h.slice(1)),h},n.processMinimumIntegers=function(t,e){var i=t.split("."),r=i[0],s=r.length;if(s=5e5){var r=(t/=1e6).toString().split(".")[1];return r&&+r.substring(0,1)>=5?Math.ceil(t).toString():Math.floor(t).toString()}return""},n}(),Lg=(new RegExp("^([^0-9]*)(([0-9,]*[0-9]+)(.[0-9]+)?)([Ee][+-]?[0-9]+)?([^0-9]*)$"),function(){function n(t){this.ranArray=[],this.boundedEvents={},!m(t)&&(this.context=t)}return n.prototype.on=function(t,e,i,r){if(!m(e)){var s=i||this.context;if(this.notExist(t))return void(this.boundedEvents[""+t]=[{handler:e,context:s,id:r}]);m(r)?this.isHandlerPresent(this.boundedEvents[""+t],e)||this.boundedEvents[""+t].push({handler:e,context:s}):-1===this.ranArray.indexOf(r)&&(this.ranArray.push(r),this.boundedEvents[""+t].push({handler:e,context:s,id:r}))}},n.prototype.off=function(t,e,i){if(!this.notExist(t)){var r=Y(t,this.boundedEvents);if(e){for(var s=0;s1&&(_.fractionDigits=parseInt(P[2],10)),_}function f(T,P,_,B){var j=B?{}:{nlead:"",nend:""},Q=T.match(n.customRegex);if(Q){B||(j.nlead=g(Q[1],_),j.nend=g(Q[10],_),j.groupPattern=Q[4]);var oe=Q[7];if(oe&&P){var ue=oe.match(t);j.minimumFraction=m(ue)?0:ue.length,j.maximumFraction=oe.length-1}}return j}function g(T,P){return T?(T=T.replace(n.defaultCurrency,P),""===P?T.trim():T):""}function v(T,P,_,B){return B?"$":Y("currencies."+P+(_?"."+_:".symbol"),T)||Y("currencies."+P+".symbol-alt-narrow",T)||"$"}function S(T,P,_){var B={type:"decimal",minimumFractionDigits:0,maximumFractionDigits:0},j=T.match(n.customRegex);if(m(j)||""===j[5]&&"N/A"!==T)return B.type=void 0,B;B.nlead=j[1],B.nend=j[10];var Q=j[6],oe=!!Q.match(/ $/g),ue=-1!==Q.replace(/ $/g,"").indexOf(" ");B.useGrouping=-1!==Q.indexOf(",")||ue,Q=Q.replace(/,/g,"");var pe=j[7];if(-1!==Q.indexOf("0")&&(B.minimumIntegerDigits=Q.length-Q.indexOf("0")),m(pe)||(B.minimumFractionDigits=pe.lastIndexOf("0"),B.maximumFractionDigits=pe.lastIndexOf("#"),-1===B.minimumFractionDigits&&(B.minimumFractionDigits=0),(-1===B.maximumFractionDigits||B.maximumFractionDigitsQ.lastIndexOf("'"))){B[""+a[parseInt(j.toString(),10)]]=Q.substr(0,oe)+_+Q.substr(oe+1),B[""+a[""+P]]=!0,B.type=B.isCurrency?"currency":"percent";break}}return B}function C(T,P){if(-1!==T.indexOf(",")){var _=T.split(",");T=_[0]+Y("numberMapper.numberSymbols.group",P)+_[1].replace(".",Y("numberMapper.numberSymbols.decimal",P))}else T=T.replace(".",Y("numberMapper.numberSymbols.decimal",P));return T}function A(T,P,_){T+=".";for(var B=0;B0;Q-=3)T=","+_[Q-2]+_[Q-1]+_[parseInt(Q.toString(),10)]+T;return T=T.slice(1),P[1]?T+"."+P[1]:T}n.dateParseRegex=/([a-z])\1*|'([^']|'')+'|''|./gi,n.basicPatterns=["short","medium","long","full"],n.defaultObject={dates:{calendars:{gregorian:{months:{"stand-alone":{abbreviated:{1:"Jan",2:"Feb",3:"Mar",4:"Apr",5:"May",6:"Jun",7:"Jul",8:"Aug",9:"Sep",10:"Oct",11:"Nov",12:"Dec"},narrow:{1:"J",2:"F",3:"M",4:"A",5:"M",6:"J",7:"J",8:"A",9:"S",10:"O",11:"N",12:"D"},wide:{1:"January",2:"February",3:"March",4:"April",5:"May",6:"June",7:"July",8:"August",9:"September",10:"October",11:"November",12:"December"}}},days:{"stand-alone":{abbreviated:{sun:"Sun",mon:"Mon",tue:"Tue",wed:"Wed",thu:"Thu",fri:"Fri",sat:"Sat"},narrow:{sun:"S",mon:"M",tue:"T",wed:"W",thu:"T",fri:"F",sat:"S"},short:{sun:"Su",mon:"Mo",tue:"Tu",wed:"We",thu:"Th",fri:"Fr",sat:"Sa"},wide:{sun:"Sunday",mon:"Monday",tue:"Tuesday",wed:"Wednesday",thu:"Thursday",fri:"Friday",sat:"Saturday"}}},dayPeriods:{format:{wide:{am:"AM",pm:"PM"}}},eras:{eraNames:{0:"Before Christ","0-alt-variant":"Before Common Era",1:"Anno Domini","1-alt-variant":"Common Era"},eraAbbr:{0:"BC","0-alt-variant":"BCE",1:"AD","1-alt-variant":"CE"},eraNarrow:{0:"B","0-alt-variant":"BCE",1:"A","1-alt-variant":"CE"}},dateFormats:{full:"EEEE, MMMM d, y",long:"MMMM d, y",medium:"MMM d, y",short:"M/d/yy"},timeFormats:{full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},dateTimeFormats:{full:"{1} 'at' {0}",long:"{1} 'at' {0}",medium:"{1}, {0}",short:"{1}, {0}",availableFormats:{d:"d",E:"ccc",Ed:"d E",Ehm:"E h:mm a",EHm:"E HH:mm",Ehms:"E h:mm:ss a",EHms:"E HH:mm:ss",Gy:"y G",GyMMM:"MMM y G",GyMMMd:"MMM d, y G",GyMMMEd:"E, MMM d, y G",h:"h a",H:"HH",hm:"h:mm a",Hm:"HH:mm",hms:"h:mm:ss a",Hms:"HH:mm:ss",hmsv:"h:mm:ss a v",Hmsv:"HH:mm:ss v",hmv:"h:mm a v",Hmv:"HH:mm v",M:"L",Md:"M/d",MEd:"E, M/d",MMM:"LLL",MMMd:"MMM d",MMMEd:"E, MMM d",MMMMd:"MMMM d",ms:"mm:ss",y:"y",yM:"M/y",yMd:"M/d/y",yMEd:"E, M/d/y",yMMM:"MMM y",yMMMd:"MMM d, y",yMMMEd:"E, MMM d, y",yMMMM:"MMMM y"}}},islamic:{months:{"stand-alone":{abbreviated:{1:"Muh.",2:"Saf.",3:"Rab. I",4:"Rab. II",5:"Jum. I",6:"Jum. II",7:"Raj.",8:"Sha.",9:"Ram.",10:"Shaw.",11:"Dhu\u02bbl-Q.",12:"Dhu\u02bbl-H."},narrow:{1:"1",2:"2",3:"3",4:"4",5:"5",6:"6",7:"7",8:"8",9:"9",10:"10",11:"11",12:"12"},wide:{1:"Muharram",2:"Safar",3:"Rabi\u02bb I",4:"Rabi\u02bb II",5:"Jumada I",6:"Jumada II",7:"Rajab",8:"Sha\u02bbban",9:"Ramadan",10:"Shawwal",11:"Dhu\u02bbl-Qi\u02bbdah",12:"Dhu\u02bbl-Hijjah"}}},days:{"stand-alone":{abbreviated:{sun:"Sun",mon:"Mon",tue:"Tue",wed:"Wed",thu:"Thu",fri:"Fri",sat:"Sat"},narrow:{sun:"S",mon:"M",tue:"T",wed:"W",thu:"T",fri:"F",sat:"S"},short:{sun:"Su",mon:"Mo",tue:"Tu",wed:"We",thu:"Th",fri:"Fr",sat:"Sa"},wide:{sun:"Sunday",mon:"Monday",tue:"Tuesday",wed:"Wednesday",thu:"Thursday",fri:"Friday",sat:"Saturday"}}},dayPeriods:{format:{wide:{am:"AM",pm:"PM"}}},eras:{eraNames:{0:"AH"},eraAbbr:{0:"AH"},eraNarrow:{0:"AH"}},dateFormats:{full:"EEEE, MMMM d, y G",long:"MMMM d, y G",medium:"MMM d, y G",short:"M/d/y GGGGG"},timeFormats:{full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},dateTimeFormats:{full:"{1} 'at' {0}",long:"{1} 'at' {0}",medium:"{1}, {0}",short:"{1}, {0}",availableFormats:{d:"d",E:"ccc",Ed:"d E",Ehm:"E h:mm a",EHm:"E HH:mm",Ehms:"E h:mm:ss a",EHms:"E HH:mm:ss",Gy:"y G",GyMMM:"MMM y G",GyMMMd:"MMM d, y G",GyMMMEd:"E, MMM d, y G",h:"h a",H:"HH",hm:"h:mm a",Hm:"HH:mm",hms:"h:mm:ss a",Hms:"HH:mm:ss",M:"L",Md:"M/d",MEd:"E, M/d",MMM:"LLL",MMMd:"MMM d",MMMEd:"E, MMM d",MMMMd:"MMMM d",ms:"mm:ss",y:"y G",yyyy:"y G",yyyyM:"M/y GGGGG",yyyyMd:"M/d/y GGGGG",yyyyMEd:"E, M/d/y GGGGG",yyyyMMM:"MMM y G",yyyyMMMd:"MMM d, y G",yyyyMMMEd:"E, MMM d, y G",yyyyMMMM:"MMMM y G",yyyyQQQ:"QQQ y G",yyyyQQQQ:"QQQQ y G"}}}},timeZoneNames:{hourFormat:"+HH:mm;-HH:mm",gmtFormat:"GMT{0}",gmtZeroFormat:"GMT"}},numbers:{currencies:{USD:{displayName:"US Dollar",symbol:"$","symbol-alt-narrow":"$"},EUR:{displayName:"Euro",symbol:"\u20ac","symbol-alt-narrow":"\u20ac"},GBP:{displayName:"British Pound","symbol-alt-narrow":"\xa3"}},defaultNumberingSystem:"latn",minimumGroupingDigits:"1","symbols-numberSystem-latn":{decimal:".",group:",",list:";",percentSign:"%",plusSign:"+",minusSign:"-",exponential:"E",superscriptingExponent:"\xd7",perMille:"\u2030",infinity:"\u221e",nan:"NaN",timeSeparator:":"},"decimalFormats-numberSystem-latn":{standard:"#,##0.###"},"percentFormats-numberSystem-latn":{standard:"#,##0%"},"currencyFormats-numberSystem-latn":{standard:"\xa4#,##0.00",accounting:"\xa4#,##0.00;(\xa4#,##0.00)"},"scientificFormats-numberSystem-latn":{standard:"#E0"}}},n.blazorDefaultObject={numbers:{mapper:{0:"0",1:"1",2:"2",3:"3",4:"4",5:"5",6:"6",7:"7",8:"8",9:"9"},mapperDigits:"0123456789",numberSymbols:{decimal:".",group:",",plusSign:"+",minusSign:"-",percentSign:"%",nan:"NaN",timeSeparator:":",infinity:"\u221e"},timeSeparator:":",currencySymbol:"$",currencypData:{nlead:"$",nend:"",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},percentpData:{nlead:"",nend:"%",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},percentnData:{nlead:"-",nend:"%",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},currencynData:{nlead:"($",nend:")",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},decimalnData:{nlead:"-",nend:"",groupData:{primary:3},maximumFraction:2,minimumFraction:2},decimalpData:{nlead:"",nend:"",groupData:{primary:3},maximumFraction:2,minimumFraction:2}},dates:{dayPeriods:{am:"AM",pm:"PM"},dateSeperator:"/",days:{abbreviated:{sun:"Sun",mon:"Mon",tue:"Tue",wed:"Wed",thu:"Thu",fri:"Fri",sat:"Sat"},short:{sun:"Su",mon:"Mo",tue:"Tu",wed:"We",thu:"Th",fri:"Fr",sat:"Sa"},wide:{sun:"Sunday",mon:"Monday",tue:"Tuesday",wed:"Wednesday",thu:"Thursday",fri:"Friday",sat:"Saturday"}},months:{abbreviated:{1:"Jan",2:"Feb",3:"Mar",4:"Apr",5:"May",6:"Jun",7:"Jul",8:"Aug",9:"Sep",10:"Oct",11:"Nov",12:"Dec"},wide:{1:"January",2:"February",3:"March",4:"April",5:"May",6:"June",7:"July",8:"August",9:"September",10:"October",11:"November",12:"December"}},eras:{1:"AD"}}},n.monthIndex={3:"abbreviated",4:"wide",5:"narrow",1:"abbreviated"},n.month="months",n.days="days",n.patternMatcher={C:"currency",P:"percent",N:"decimal",A:"currency",E:"scientific"},n.getResultantPattern=l,n.getDependables=h,n.getSymbolPattern=c,n.ConvertDateToWeekFormat=d,n.compareBlazorDateFormats=u,n.getProperNumericSkeleton=p,n.getFormatData=f,n.changeCurrencySymbol=g,n.getCurrencySymbol=v,n.customFormat=function y(T,P,_){for(var B={},j=T.split(";"),Q=["pData","nData","zeroData"],oe=0;oe1,pe.nData=ce()?Y(De.type+"nData",oe):f(ot[1]||"-"+ot[0],!0,Ie),pe.pData=ce()?Y(De.type+"pData",oe):f(ot[0],!1,Ie),!Me[2]&&!P.minimumFractionDigits&&!P.maximumFractionDigits&&(ue=f(Ve.split(";")[0],!0,"",!0).minimumFraction)}if(n.formatRegex.test(P.format)||!P.format){if(ze(Q,p(P.format||"N")),Q.custom=!1,$e="###0",(Q.fractionDigits||P.minimumFractionDigits||P.maximumFractionDigits||ue)&&(Q.fractionDigits&&(P.minimumFractionDigits=P.maximumFractionDigits=Q.fractionDigits),$e=A($e,ue||Q.fractionDigits||P.minimumFractionDigits||0,P.maximumFractionDigits||0)),P.minimumIntegerDigits&&($e=x($e,P.minimumIntegerDigits)),P.useGrouping&&($e=R($e)),"currency"===Q.type||Q.type&&ce()){ce()&&"currency"!==Q.type&&(pe.pData=Y(Q.type+"pData",oe),pe.nData=Y(Q.type+"nData",oe));var hr=$e;$e=pe.pData.nlead+hr+pe.pData.nend,(pe.hasNegativePattern||ce())&&($e+=";"+pe.nData.nlead+hr+pe.nData.nend)}"percent"===Q.type&&!ce()&&($e+=" %")}else $e=P.format.replace(/'/g,'"');return Object.keys(xe).length>0&&($e=B?$e:C($e,xe)),$e},n.fractionDigitsPattern=A,n.minimumIntegerPattern=x,n.groupingPattern=R,n.getWeekData=function L(T,P){var _="sun",B=Y("supplemental.weekData.firstDay",P),j=T;return/en-/.test(j)&&(j=j.slice(3)),j=j.slice(0,2).toUpperCase()+j.substr(2),B&&(_=B[""+j]||B[j.slice(0,2)]||"sun"),o[""+_]},n.replaceBlazorCurrency=function O(T,P,_){var B=function p$(n){return Y(n||"",u$)}(_);if(P!==B)for(var j=0,Q=T;j=0?_:_+7;var j=Math.floor((T.getTime()-P.getTime()-6e4*(T.getTimezoneOffset()-P.getTimezoneOffset()))/864e5)+1;if(_<4){if((B=Math.floor((j+_-1)/7)+1)>52){var oe=new Date(T.getFullYear()+1,0,1).getDay();B=(oe=oe>=0?oe:oe+7)<4?1:53}}else B=Math.floor((j+_-1)/7);return B}}(ut||(ut={}));var np=function(){function n(t,e,i){this.type="GET",this.emitError=!0,"string"==typeof t?(this.url=t,this.type=m(e)?this.type:e.toUpperCase(),this.contentType=i):Aa(t)&&Object.keys(t).length>0&&Nn(this,t),this.contentType=m(this.contentType)?"application/json; charset=utf-8":this.contentType}return n.prototype.send=function(t){var e=this,i={"application/json":"json","multipart/form-data":"formData","application/octet-stream":"blob","application/x-www-form-urlencoded":"formData"};try{m(this.fetchRequest)&&"GET"===this.type?this.fetchRequest=new Request(this.url,{method:this.type}):m(this.fetchRequest)&&(this.data=m(t)?this.data:t,this.fetchRequest=new Request(this.url,{method:this.type,headers:{"Content-Type":this.contentType},body:this.data}));var r={cancel:!1,fetchRequest:this.fetchRequest};return this.triggerEvent(this.beforeSend,r),r.cancel?null:(this.fetchResponse=fetch(this.fetchRequest),this.fetchResponse.then(function(s){if(e.triggerEvent(e.onLoad,s),!s.ok)throw s;for(var o="text",a=0,l=Object.keys(i);a-1},n.getValue=function(t,e){var i=typeof window<"u"?window.browserDetails:{};return typeof navigator<"u"&&"MacIntel"===navigator.platform&&navigator.maxTouchPoints>1&&!0===n.isTouch&&!vC.CHROME.test(navigator.userAgent)&&(i.isIos=!0,i.isDevice=!0,i.isTouch=!0,i.isPointer=!0),typeof window<"u"&&window.Capacitor&&"ios"===window.Capacitor.getPlatform()&&(i.isPointer=!1),typeof i[""+t]>"u"?i[""+t]=e.test(n.userAgent):i[""+t]},Object.defineProperty(n,"userAgent",{get:function(){return n.uA},set:function(t){n.uA=t,window.browserDetails={}},enumerable:!0,configurable:!0}),Object.defineProperty(n,"info",{get:function(){return st(window.browserDetails.info)?window.browserDetails.info=n.extractBrowserDetail():window.browserDetails.info},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isIE",{get:function(){return n.getValue("isIE",A$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isTouch",{get:function(){return st(window.browserDetails.isTouch)?window.browserDetails.isTouch="ontouchstart"in window.navigator||window&&window.navigator&&window.navigator.maxTouchPoints>0||"ontouchstart"in window:window.browserDetails.isTouch},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isPointer",{get:function(){return st(window.browserDetails.isPointer)?window.browserDetails.isPointer="pointerEnabled"in window.navigator:window.browserDetails.isPointer},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isMSPointer",{get:function(){return st(window.browserDetails.isMSPointer)?window.browserDetails.isMSPointer="msPointerEnabled"in window.navigator:window.browserDetails.isMSPointer},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isDevice",{get:function(){return n.getValue("isDevice",T$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isIos",{get:function(){return n.getValue("isIos",N$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isIos7",{get:function(){return n.getValue("isIos7",O$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isAndroid",{get:function(){return n.getValue("isAndroid",k$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isWebView",{get:function(){return st(window.browserDetails.isWebView)&&(window.browserDetails.isWebView=!(st(window.cordova)&&st(window.PhoneGap)&&st(window.phonegap)&&"object"!==window.forge)),window.browserDetails.isWebView},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isWindows",{get:function(){return n.getValue("isWindows",P$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"touchStartEvent",{get:function(){return st(window.browserDetails.touchStartEvent)?window.browserDetails.touchStartEvent=n.getTouchStartEvent():window.browserDetails.touchStartEvent},enumerable:!0,configurable:!0}),Object.defineProperty(n,"touchMoveEvent",{get:function(){return st(window.browserDetails.touchMoveEvent)?window.browserDetails.touchMoveEvent=n.getTouchMoveEvent():window.browserDetails.touchMoveEvent},enumerable:!0,configurable:!0}),Object.defineProperty(n,"touchEndEvent",{get:function(){return st(window.browserDetails.touchEndEvent)?window.browserDetails.touchEndEvent=n.getTouchEndEvent():window.browserDetails.touchEndEvent},enumerable:!0,configurable:!0}),Object.defineProperty(n,"touchCancelEvent",{get:function(){return st(window.browserDetails.touchCancelEvent)?window.browserDetails.touchCancelEvent=n.getTouchCancelEvent():window.browserDetails.touchCancelEvent},enumerable:!0,configurable:!0}),n.uA=typeof navigator<"u"?navigator.userAgent:"",n}(),E=function(){function n(){}return n.addOrGetEventData=function(t){return"__eventList"in t?t.__eventList.events:(t.__eventList={},t.__eventList.events=[])},n.add=function(t,e,i,r,s){var a,o=n.addOrGetEventData(t);a=s?function l$(n,t){var e;return function(){for(var i=this,r=[],s=0;s"u"||(e.innerHTML=t.innerHTML?t.innerHTML:"",void 0!==t.className&&(e.className=t.className),void 0!==t.id&&(e.id=t.id),void 0!==t.styles&&e.setAttribute("style",t.styles),void 0!==t.attrs&&Fe(e,t.attrs)),e}function V(n,t){for(var e=Vz(t),i=RegExp,r=0,s=n;r0}function pl(n,t,e){for(var i=document.createDocumentFragment(),r=0,s=n;r0;)i.appendChild(n[0]);else for(var r=0,s=n;r-1&&!r[parseInt(s.toString(),10)].match(/\[.*\]/)){var o=r[parseInt(s.toString(),10)].split("#");if(o[1].match(/^\d/)||o[1].match(t)){var a=r[parseInt(s.toString(),10)].split(".");a[0]=a[0].replace(/#/,"[id='")+"']",r[parseInt(s.toString(),10)]=a.join(".")}}e[parseInt(i.toString(),10)]=r.join(" ")}return e.join(",")}return n}function J(n,t){var e=n;if("function"==typeof e.closest)return e.closest(t);for(;e&&1===e.nodeType;){if(mC(e,t))return e;e=e.parentNode}return null}function je(n,t){void 0!==t&&Object.keys(t).forEach(function(e){n.style[""+e]=t[""+e]})}function mC(n,t){var e=n.matches||n.msMatchesSelector||n.webkitMatchesSelector;return e?e.call(n,t):-1!==[].indexOf.call(document.querySelectorAll(t),n)}var H$=new RegExp("]"),ah=function(){function n(t,e){this.isRendered=!1,this.isComplexArraySetter=!1,this.isServerRendered=!1,this.allowServerDataBinding=!0,this.isProtectedOnChange=!0,this.properties={},this.changedProperties={},this.oldProperties={},this.bulkChanges={},this.refreshing=!1,this.ignoreCollectionWatch=!1,this.finalUpdate=function(){},this.childChangedProperties={},this.modelObserver=new Lg(this),st(e)||(this.element="string"==typeof e?document.querySelector(e):e,m(this.element)||(this.isProtectedOnChange=!1,this.addInstance())),st(t)||this.setProperties(t,!0),this.isDestroyed=!1}return n.prototype.setProperties=function(t,e){var i=this.isProtectedOnChange;this.isProtectedOnChange=!!e,Nn(this,t),!0!==e?(Nn(this.changedProperties,t),this.dataBind()):ce()&&this.isRendered&&this.serverDataBind(t),this.finalUpdate(),this.changedProperties={},this.oldProperties={},this.isProtectedOnChange=i},n.callChildDataBind=function(t,e){for(var r=0,s=Object.keys(t);r=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Hs=function(n){function t(i){var r=n.call(this,i,void 0)||this;return r.easing={ease:"cubic-bezier(0.250, 0.100, 0.250, 1.000)",linear:"cubic-bezier(0.250, 0.250, 0.750, 0.750)",easeIn:"cubic-bezier(0.420, 0.000, 1.000, 1.000)",easeOut:"cubic-bezier(0.000, 0.000, 0.580, 1.000)",easeInOut:"cubic-bezier(0.420, 0.000, 0.580, 1.000)",elasticInOut:"cubic-bezier(0.5,-0.58,0.38,1.81)",elasticIn:"cubic-bezier(0.17,0.67,0.59,1.81)",elasticOut:"cubic-bezier(0.7,-0.75,0.99,1.01)"},r}var e;return X$(t,n),e=t,t.prototype.animate=function(i,r){var s=this.getModel(r=r||{});if("string"==typeof i)for(var a=0,l=Array.prototype.slice.call(we(i,document));a0?r-1:0,i+=e=-1!==e?"-"+e:"-"+r}return this.controlParent!==this.parentObj&&(i=this.parentObj.getParentKey()+"."+this.propName+e),i},n}(),J$=["grid","pivotview","treegrid","spreadsheet","rangeNavigator","DocumentEditor","listbox","inplaceeditor","PdfViewer","richtexteditor","DashboardLayout","chart","stockChart","circulargauge","diagram","heatmap","lineargauge","maps","slider","smithchart","barcode","sparkline","treemap","bulletChart","kanban","daterangepicker","schedule","gantt","signature","query-builder","drop-down-tree","carousel","filemanager","uploader","accordion","tab","treeview"],tR=[115,121,110,99,102,117,115,105,111,110,46,105,115,76,105,99,86,97,108,105,100,97,116,101,100],iR=function(){function n(t){this.isValidated=!1,this.isLicensed=!0,this.version="27",this.platform=/JavaScript|ASPNET|ASPNETCORE|ASPNETMVC|FileFormats|essentialstudio/i,this.errors={noLicense:"This application was built using a trial version of Syncfusion Essential Studio. To remove the license validation message permanently, a valid license key must be included.",trailExpired:"This application was built using a trial version of Syncfusion Essential Studio. To remove the license validation message permanently, a valid license key must be included.",versionMismatched:"The included Syncfusion license key is invalid.",platformMismatched:"The included Syncfusion license key is invalid.",invalidKey:"The included Syncfusion license key is invalid."},this.manager=function(){var e=null;return{setKey:function i(s){e=s},getKey:function r(){return e}}}(),this.npxManager=function(){return{getKey:function i(){return"npxKeyReplace"}}}(),this.manager.setKey(t)}return n.prototype.validate=function(){if(!this.isValidated&&ip&&!Y(A0(tR),ip)&&!Y("Blazor",ip)){var i=void 0,r=void 0;if(this.manager&&this.manager.getKey()||this.npxManager&&"npxKeyReplace"!==this.npxManager.getKey()){var s=this.getInfoFromKey();if(s&&s.length)for(var o=0,a=s;o"+i+' Claim your FREE account\n
have a Syncfusion account? Sign In
\n
\n ';if(typeof document<"u"&&!m(document)){var t=mi("div",{innerHTML:n});document.body.appendChild(t)}}(),oR=!0),this.render(),this.mount?this.accessMount():this.trigger("created")}},t.prototype.renderComplete=function(e){ce()&&window.sfBlazor.renderComplete(this.element,e),this.isRendered=!0},t.prototype.dataBind=function(){this.injectModules(),n.prototype.dataBind.call(this)},t.prototype.on=function(e,i,r){if("string"==typeof e)this.localObserver.on(e,i,r);else for(var s=0,o=e;s=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},rZ={left:0,top:0,bottom:0,right:0},MC={isDragged:!1},nZ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return aR(t,n),gr([I(0)],t.prototype,"left",void 0),gr([I(0)],t.prototype,"top",void 0),t}(Ee),ap=function(n){function t(i,r){var s=n.call(this,r,i)||this;return s.dragLimit=e.getDefaultPosition(),s.borderWidth=e.getDefaultPosition(),s.padding=e.getDefaultPosition(),s.diffX=0,s.prevLeft=0,s.prevTop=0,s.dragProcessStarted=!1,s.eleTop=0,s.tapHoldTimer=0,s.externalInitialize=!1,s.diffY=0,s.parentScrollX=0,s.parentScrollY=0,s.droppables={},s.bind(),s}var e;return aR(t,n),e=t,t.prototype.bind=function(){this.toggleEvents(),X.isIE&&V([this.element],"e-block-touch"),this.droppables[this.scope]={}},t.getDefaultPosition=function(){return ze({},rZ)},t.prototype.toggleEvents=function(i){var r;st(this.handle)||(r=U(this.handle,this.element));var s=this.enableTapHold&&X.isDevice&&X.isTouch?this.mobileInitialize:this.initialize;i?E.remove(r||this.element,X.isSafari()?"touchstart":X.touchStartEvent,s):E.add(r||this.element,X.isSafari()?"touchstart":X.touchStartEvent,s,this)},t.prototype.mobileInitialize=function(i){var r=this,s=i.currentTarget;this.tapHoldTimer=setTimeout(function(){r.externalInitialize=!0,r.removeTapholdTimer(),r.initialize(i,s)},this.tapHoldThreshold),E.add(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.removeTapholdTimer,this),E.add(document,X.isSafari()?"touchend":X.touchEndEvent,this.removeTapholdTimer,this)},t.prototype.removeTapholdTimer=function(){clearTimeout(this.tapHoldTimer),E.remove(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.removeTapholdTimer),E.remove(document,X.isSafari()?"touchend":X.touchEndEvent,this.removeTapholdTimer)},t.prototype.getScrollableParent=function(i,r){return m(i)?null:i[{vertical:"scrollHeight",horizontal:"scrollWidth"}[""+r]]>i[{vertical:"clientHeight",horizontal:"clientWidth"}[""+r]]&&("vertical"===r?i.scrollTop>0:i.scrollLeft>0)?("vertical"===r?(this.parentScrollY=this.parentScrollY+(0===this.parentScrollY?i.scrollTop:i.scrollTop-this.parentScrollY),this.tempScrollHeight=i.scrollHeight):(this.parentScrollX=this.parentScrollX+(0===this.parentScrollX?i.scrollLeft:i.scrollLeft-this.parentScrollX),this.tempScrollWidth=i.scrollWidth),m(i)?i:this.getScrollableParent(i.parentNode,r)):this.getScrollableParent(i.parentNode,r)},t.prototype.getScrollableValues=function(){this.parentScrollX=0,this.parentScrollY=0,this.element.classList.contains("e-dialog")&&this.element.classList.contains("e-dlg-modal"),this.getScrollableParent(this.element.parentNode,"vertical"),this.getScrollableParent(this.element.parentNode,"horizontal")},t.prototype.initialize=function(i,r){if(this.currentStateTarget=i.target,!this.isDragStarted()){if(this.isDragStarted(!0),this.externalInitialize=!1,this.target=i.currentTarget||r,this.dragProcessStarted=!1,this.abort){var s=this.abort;"string"==typeof s&&(s=[s]);for(var o=0;o=this.distance||this.externalInitialize){var p=this.getHelperElement(i);if(!p||m(p))return;r&&i.preventDefault();var f=this.helperElement=p;if(this.parentClientRect=this.calculateParentPosition(f.offsetParent),this.dragStart){var v={event:i,element:l,target:this.getProperTargetElement(i),bindEvents:ce()?this.bindDragEvents.bind(this):null,dragElement:f};this.trigger("dragStart",v)}this.dragArea?this.setDragArea():(this.dragLimit={left:0,right:0,bottom:0,top:0},this.borderWidth={top:0,left:0}),o={left:this.position.left-this.parentClientRect.left,top:this.position.top-this.parentClientRect.top},this.clone&&!this.enableTailMode&&(this.diffX=this.position.left-this.offset.left,this.diffY=this.position.top-this.offset.top),this.getScrollableValues();var y=getComputedStyle(l),S=parseFloat(y.marginTop);this.clone&&0!==S&&(o.top+=S),this.eleTop=isNaN(parseFloat(y.top))?0:parseFloat(y.top)-this.offset.top,this.enableScrollHandler&&!this.clone&&(o.top-=this.parentScrollY,o.left-=this.parentScrollX);var b=this.getProcessedPositionValue({top:o.top-this.diffY+"px",left:o.left-this.diffX+"px"});this.dragArea&&"string"!=typeof this.dragArea&&this.dragArea.classList.contains("e-kanban-content")&&"relative"===this.dragArea.style.position&&(o.top+=this.dragArea.scrollTop),this.dragElePosition={top:o.top,left:o.left},je(f,this.getDragPosition({position:"absolute",left:b.left,top:b.top})),E.remove(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.intDragStart),E.remove(document,X.isSafari()?"touchend":X.touchEndEvent,this.intDestroy),ce()||this.bindDragEvents(f)}}},t.prototype.bindDragEvents=function(i){Tr(i)?(E.add(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.intDrag,this),E.add(document,X.isSafari()?"touchend":X.touchEndEvent,this.intDragStop,this),this.setGlobalDroppables(!1,this.element,i)):(this.toggleEvents(),document.body.classList.remove("e-prevent-select"))},t.prototype.elementInViewport=function(i){for(this.top=i.offsetTop,this.left=i.offsetLeft,this.width=i.offsetWidth,this.height=i.offsetHeight;i.offsetParent;)this.top+=(i=i.offsetParent).offsetTop,this.left+=i.offsetLeft;return this.top>=window.pageYOffset&&this.left>=window.pageXOffset&&this.top+this.height<=window.pageYOffset+window.innerHeight&&this.left+this.width<=window.pageXOffset+window.innerWidth},t.prototype.getProcessedPositionValue=function(i){return this.queryPositionInfo?this.queryPositionInfo(i):i},t.prototype.calculateParentPosition=function(i){if(m(i))return{left:0,top:0};var r=i.getBoundingClientRect(),s=getComputedStyle(i);return{left:r.left+window.pageXOffset-parseInt(s.marginLeft,10),top:r.top+window.pageYOffset-parseInt(s.marginTop,10)}},t.prototype.intDrag=function(i){if(st(i.changedTouches)||1===i.changedTouches.length){var r,s;this.clone&&i.changedTouches&&X.isDevice&&X.isTouch&&i.preventDefault(),this.position=this.getMousePosition(i,this.isDragScroll);var o=this.getDocumentWidthHeight("Height");oy&&y>0?this.dragLimit.left:this.dragLimit.right+window.pageXOffset0?y-(y-this.dragLimit.right)+window.pageXOffset-M:y<0?this.dragLimit.left:y}if(this.pageY!==v||this.skipDistanceCheck){var w=d.offsetHeight+(parseFloat(b.marginTop)+parseFloat(b.marginBottom));s=this.dragLimit.top>S&&S>0?this.dragLimit.top:this.dragLimit.bottom+window.pageYOffset0?S-(S-this.dragLimit.bottom)+window.pageYOffset-w:S<0?this.dragLimit.top:S}}else r=y,s=S;var A,x,C=p+this.borderWidth.top,D=u+this.borderWidth.left;if(this.dragProcessStarted&&(m(s)&&(s=this.prevTop),m(r)&&(r=this.prevLeft)),this.helperElement.classList.contains("e-treeview"))this.dragArea?(this.dragLimit.top=this.clone?this.dragLimit.top:0,A=s-C<0?this.dragLimit.top:s-this.borderWidth.top,x=r-D<0?this.dragLimit.left:r-this.borderWidth.left):(A=s-this.borderWidth.top,x=r-this.borderWidth.left);else if(this.dragArea){var R=this.helperElement.classList.contains("e-dialog");this.dragLimit.top=this.clone?this.dragLimit.top:0,A=s-C<0?this.dragLimit.top:s-C,x=r-D<0?R?r-(D-this.borderWidth.left):this.dragElePosition.left:r-D}else A=s-C,x=r-D;var L=parseFloat(getComputedStyle(this.element).marginTop);if(L>0&&(this.clone&&(A+=L,S<0&&(L+S>=0?A=L+S:A-=L),this.dragArea&&(A=this.dragLimit.bottom=0){var O=this.dragLimit.top+S-C;O+L+C<0?A-=L+C:A=O}else A-=L+C;this.dragArea&&this.helperElement.classList.contains("e-treeview")&&(A=A+(w=d.offsetHeight+(parseFloat(b.marginTop)+parseFloat(b.marginBottom)))>this.dragLimit.bottom?this.dragLimit.bottom-w:A),this.enableScrollHandler&&!this.clone&&(A-=this.parentScrollY,x-=this.parentScrollX),this.dragArea&&"string"!=typeof this.dragArea&&this.dragArea.classList.contains("e-kanban-content")&&"relative"===this.dragArea.style.position&&(A+=this.dragArea.scrollTop);var N=this.getProcessedPositionValue({top:A+"px",left:x+"px"});this.isPreventScroll&&(N=this.getProcessedPositionValue({top:this.position.top-this.parentClientRect.top-2+"px",left:this.position.left-this.parentClientRect.left-2+"px"})),je(d,this.getDragPosition(N)),!this.elementInViewport(d)&&this.enableAutoScroll&&!this.helperElement.classList.contains("e-treeview")&&this.helperElement.scrollIntoView();var T=document.querySelectorAll(":hover");if(this.enableAutoScroll&&this.helperElement.classList.contains("e-treeview")){0===T.length&&(T=this.getPathElements(i));var P=this.getScrollParent(T,!1);this.elementInViewport(this.helperElement)?this.getScrollPosition(P,A):this.elementInViewport(this.helperElement)||(0===(T=[].slice.call(document.querySelectorAll(":hover"))).length&&(T=this.getPathElements(i)),P=this.getScrollParent(T,!0),this.getScrollPosition(P,A))}this.dragProcessStarted=!0,this.prevLeft=r,this.prevTop=s,this.position.left=r,this.position.top=s,this.pageX=g,this.pageY=v}},t.prototype.getScrollParent=function(i,r){for(var o,s=r?i.reverse():i,a=s.length-1;a>=0;a--)if(("auto"===(o=window.getComputedStyle(s[parseInt(a.toString(),10)])["overflow-y"])||"scroll"===o)&&s[parseInt(a.toString(),10)].scrollHeight>s[parseInt(a.toString(),10)].clientHeight)return s[parseInt(a.toString(),10)];if("visible"===(o=window.getComputedStyle(document.scrollingElement)["overflow-y"]))return document.scrollingElement.style.overflow="auto",document.scrollingElement},t.prototype.getScrollPosition=function(i,r){if(i&&i===document.scrollingElement)i.clientHeight+document.scrollingElement.scrollTop-this.helperElement.clientHeightr?i.scrollTop+=this.helperElement.clientHeight:i.scrollTop>r-this.helperElement.clientHeight&&(i.scrollTop-=this.helperElement.clientHeight);else if(i&&i!==document.scrollingElement){var s=document.scrollingElement.scrollTop,o=this.helperElement.clientHeight;i.clientHeight+i.getBoundingClientRect().top-o+sr-o-s&&(i.scrollTop-=this.helperElement.clientHeight)}},t.prototype.getPathElements=function(i){return document.elementsFromPoint(i.clientX>0?i.clientX:0,i.clientY>0?i.clientY:0)},t.prototype.triggerOutFunction=function(i,r){this.hoverObject.instance.intOut(i,r.target),this.hoverObject.instance.dragData[this.scope]=null,this.hoverObject=null},t.prototype.getDragPosition=function(i){var r=ze({},i);return this.axis&&("x"===this.axis?delete r.top:"y"===this.axis&&delete r.left),r},t.prototype.getDocumentWidthHeight=function(i){var r=document.body,s=document.documentElement;return Math.max(r["scroll"+i],s["scroll"+i],r["offset"+i],s["offset"+i],s["client"+i])},t.prototype.intDragStop=function(i){if(this.dragProcessStarted=!1,st(i.changedTouches)||1===i.changedTouches.length){if(-1!==["touchend","pointerup","mouseup"].indexOf(i.type)){if(this.dragStop){var s=this.getProperTargetElement(i);this.trigger("dragStop",{event:i,element:this.element,target:s,helper:this.helperElement})}this.intDestroy(i)}else this.element.setAttribute("aria-grabbed","false");var o=this.checkTargetElement(i);o.target&&o.instance&&(o.instance.dragStopCalled=!0,o.instance.dragData[this.scope]=this.droppables[this.scope],o.instance.intDrop(i,o.target)),this.setGlobalDroppables(!0),document.body.classList.remove("e-prevent-select")}},t.prototype.intDestroy=function(i){this.dragProcessStarted=!1,this.toggleEvents(),document.body.classList.remove("e-prevent-select"),this.element.setAttribute("aria-grabbed","false"),E.remove(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.intDragStart),E.remove(document,X.isSafari()?"touchend":X.touchEndEvent,this.intDragStop),E.remove(document,X.isSafari()?"touchend":X.touchEndEvent,this.intDestroy),E.remove(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.intDrag),this.isDragStarted()&&this.isDragStarted(!0)},t.prototype.onPropertyChanged=function(i,r){},t.prototype.getModuleName=function(){return"draggable"},t.prototype.isDragStarted=function(i){return i&&(MC.isDragged=!MC.isDragged),MC.isDragged},t.prototype.setDragArea=function(){var i,r,a,s=0,o=0;if(a="string"==typeof this.dragArea?U(this.dragArea):this.dragArea){var h=a.getBoundingClientRect();i=a.scrollWidth?a.scrollWidth:h.right-h.left,r=a.scrollHeight?this.dragArea&&!m(this.helperElement)&&this.helperElement.classList.contains("e-treeview")?a.clientHeight:a.scrollHeight:h.bottom-h.top;for(var c=["Top","Left","Bottom","Right"],d=getComputedStyle(a),u=0;u12;return E0(i.target,this.helperElement)||-1!==i.type.indexOf("touch")||a?(this.helperElement.style.pointerEvents="none",s=document.elementFromPoint(r.clientX,r.clientY),this.helperElement.style.pointerEvents=o):s=i.target,s},t.prototype.currentStateCheck=function(i,r){return m(this.currentStateTarget)||this.currentStateTarget===i?m(r)?i:r:this.currentStateTarget},t.prototype.getMousePosition=function(i,r){var a,l,s=void 0!==i.srcElement?i.srcElement:i.target,o=this.getCoordinates(i),h=m(s.offsetParent);if(r?(a=this.clone?o.pageX:o.pageX+(h?0:s.offsetParent.scrollLeft)-this.relativeXPosition,l=this.clone?o.pageY:o.pageY+(h?0:s.offsetParent.scrollTop)-this.relativeYPosition):(a=this.clone?o.pageX:o.pageX+window.pageXOffset-this.relativeXPosition,l=this.clone?o.pageY:o.pageY+window.pageYOffset-this.relativeYPosition),document.scrollingElement&&!r&&!this.clone){var c=document.scrollingElement;a=c.scrollWidth>0&&c.scrollWidth>c.clientWidth&&c.scrollLeft>0?a-c.scrollLeft:a,l=c.scrollHeight>0&&c.scrollHeight>c.clientHeight&&c.scrollTop>0?l-c.scrollTop:l}return{left:a-(this.margin.left+this.cursorAt.left),top:l-(this.margin.top+this.cursorAt.top)}},t.prototype.getCoordinates=function(i){return i.type.indexOf("touch")>-1?i.changedTouches[0]:i},t.prototype.getHelperElement=function(i){var r;return this.clone?this.helper?r=this.helper({sender:i,element:this.target}):(r=mi("div",{className:"e-drag-helper e-block-touch",innerHTML:"Draggable"}),document.body.appendChild(r)):r=this.element,r},t.prototype.setGlobalDroppables=function(i,r,s){this.droppables[this.scope]=i?null:{draggable:r,helper:s,draggedElement:this.element}},t.prototype.checkTargetElement=function(i){var r=this.getProperTargetElement(i),s=this.getDropInstance(r);if(!s&&r&&!m(r.parentNode)){var o=J(r.parentNode,".e-droppable")||r.parentElement;o&&(s=this.getDropInstance(o))}return{target:r,instance:s}},t.prototype.getDropInstance=function(i){var s,o=i&&i.ej2_instances;if(o)for(var a=0,l=o;a=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},lR=function(n){function t(e,i){var r=n.call(this,i,e)||this;return r.mouseOver=!1,r.dragData={},r.dragStopCalled=!1,r.bind(),r}return sZ(t,n),t.prototype.bind=function(){this.wireEvents()},t.prototype.wireEvents=function(){E.add(this.element,X.isSafari()?"touchend":X.touchEndEvent,this.intDrop,this)},t.prototype.onPropertyChanged=function(e,i){},t.prototype.getModuleName=function(){return"droppable"},t.prototype.intOver=function(e,i){this.mouseOver||(this.trigger("over",{event:e,target:i,dragData:this.dragData[this.scope]}),this.mouseOver=!0)},t.prototype.intOut=function(e,i){this.mouseOver&&(this.trigger("out",{evt:e,target:i}),this.mouseOver=!1)},t.prototype.intDrop=function(e,i){if(this.dragStopCalled){this.dragStopCalled=!1;var a,r=!0,s=this.dragData[this.scope],o=!!s&&s.helper&&Tr(s.helper);o&&(a=this.isDropArea(e,s.helper,i),this.accept&&(r=mC(s.helper,this.accept))),o&&this.drop&&a.canDrop&&r&&this.trigger("drop",{event:e,target:a.target,droppedElement:s.helper,dragData:s}),this.mouseOver=!1}},t.prototype.isDropArea=function(e,i,r){var s={canDrop:!0,target:r||e.target},o="touchend"===e.type;if(o||s.target===i){i.style.display="none";var a=o?e.changedTouches[0]:e,l=document.elementFromPoint(a.clientX,a.clientY);s.canDrop=!1,s.canDrop=E0(l,this.element),s.canDrop&&(s.target=l),i.style.display=""}return s},t.prototype.destroy=function(){E.remove(this.element,X.isSafari()?"touchend":X.touchEndEvent,this.intDrop),n.prototype.destroy.call(this)},lp([I()],t.prototype,"accept",void 0),lp([I("default")],t.prototype,"scope",void 0),lp([H()],t.prototype,"drop",void 0),lp([H()],t.prototype,"over",void 0),lp([H()],t.prototype,"out",void 0),lp([Ft],t)}(ah),ho=function(){function n(t,e,i){this.controlName=t,this.localeStrings=e,this.setLocale(i||"en-US")}return n.prototype.setLocale=function(t){var e=this.intGetControlConstant(n.locale,t);this.currentLocale=e||this.localeStrings},n.load=function(t){this.locale=ze(this.locale,t,{},!0)},n.prototype.getConstant=function(t){return m(this.currentLocale[""+t])?this.localeStrings[""+t]||"":this.currentLocale[""+t]},n.prototype.intGetControlConstant=function(t,e){return t[""+e]?t[""+e][this.controlName]:null},n.locale={},n}(),hR=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),hh=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},lZ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return hR(t,n),hh([I(50)],t.prototype,"swipeThresholdDistance",void 0),t}(Ee),hZ=/(Up|Down)/,Fs=function(n){function t(e,i){var r=n.call(this,i,e)||this;return r.touchAction=!0,r.tapCount=0,r.startEvent=function(s){if(!0===r.touchAction){var o=r.updateChangeTouches(s);void 0!==s.changedTouches&&(r.touchAction=!1),r.isTouchMoved=!1,r.movedDirection="",r.startPoint=r.lastMovedPoint={clientX:o.clientX,clientY:o.clientY},r.startEventData=o,r.hScrollLocked=r.vScrollLocked=!1,r.tStampStart=Date.now(),r.timeOutTapHold=setTimeout(function(){r.tapHoldEvent(s)},r.tapHoldThreshold),E.add(r.element,X.touchMoveEvent,r.moveEvent,r),E.add(r.element,X.touchEndEvent,r.endEvent,r),E.add(r.element,X.touchCancelEvent,r.cancelEvent,r)}},r.moveEvent=function(s){var o=r.updateChangeTouches(s);r.movedPoint=o,r.isTouchMoved=!(o.clientX===r.startPoint.clientX&&o.clientY===r.startPoint.clientY);var a={};r.isTouchMoved&&(clearTimeout(r.timeOutTapHold),r.calcScrollPoints(s),a=ze(a,{},{startEvents:r.startEventData,originalEvent:s,startX:r.startPoint.clientX,startY:r.startPoint.clientY,distanceX:r.distanceX,distanceY:r.distanceY,scrollDirection:r.scrollDirection,velocity:r.getVelocity(o)}),r.trigger("scroll",a),r.lastMovedPoint={clientX:o.clientX,clientY:o.clientY})},r.cancelEvent=function(s){clearTimeout(r.timeOutTapHold),clearTimeout(r.timeOutTap),r.tapCount=0,r.swipeFn(s),E.remove(r.element,X.touchCancelEvent,r.cancelEvent)},r.endEvent=function(s){r.swipeFn(s),r.isTouchMoved||"function"==typeof r.tap&&(r.trigger("tap",{originalEvent:s,tapCount:++r.tapCount}),r.timeOutTap=setTimeout(function(){r.tapCount=0},r.tapThreshold)),r.modeclear()},r.swipeFn=function(s){clearTimeout(r.timeOutTapHold),clearTimeout(r.timeOutTap);var o=r.updateChangeTouches(s),a=o.clientX-r.startPoint.clientX,l=o.clientY-r.startPoint.clientY;a=Math.floor(a<0?-1*a:a),l=Math.floor(l<0?-1*l:a),r.isTouchMoved=a>1||l>1,/Firefox/.test(X.userAgent)&&0===o.clientX&&0===o.clientY&&"mouseup"===s.type&&(r.isTouchMoved=!1),r.endPoint=o,r.calcPoints(s);var c={originalEvent:s,startEvents:r.startEventData,startX:r.startPoint.clientX,startY:r.startPoint.clientY,distanceX:r.distanceX,distanceY:r.distanceY,swipeDirection:r.movedDirection,velocity:r.getVelocity(o)};if(r.isTouchMoved){var d=r.swipeSettings.swipeThresholdDistance,u=ze(void 0,r.defaultArgs,c),p=!1,f=r.element,g=r.isScrollable(f),v=hZ.test(r.movedDirection);(dthis.distanceY?i.clientX>this.startPoint.clientX?"Right":"Left":i.clientYthis.distanceY||!0===this.hScrollLocked)&&!1===this.vScrollLocked?(this.scrollDirection=i.clientX>this.lastMovedPoint.clientX?"Right":"Left",this.hScrollLocked=!0):(this.scrollDirection=i.clientY=e[r[0]+s[0]]},t.prototype.updateChangeTouches=function(e){return e.changedTouches&&0!==e.changedTouches.length?e.changedTouches[0]:e},hh([H()],t.prototype,"tap",void 0),hh([H()],t.prototype,"tapHold",void 0),hh([H()],t.prototype,"swipe",void 0),hh([H()],t.prototype,"scroll",void 0),hh([I(350)],t.prototype,"tapThreshold",void 0),hh([I(750)],t.prototype,"tapHoldThreshold",void 0),hh([re({},lZ)],t.prototype,"swipeSettings",void 0),hh([Ft],t)}(ah),cZ=new RegExp("\\n|\\r|\\s\\s+","g"),dZ=new RegExp(/'|"/g),uZ=new RegExp("if ?\\("),pZ=new RegExp("else if ?\\("),cR=new RegExp("else"),fZ=new RegExp("for ?\\("),dR=new RegExp("(/if|/for)"),gZ=new RegExp("\\((.*)\\)",""),wC=new RegExp("^[0-9]+$","g"),vZ=new RegExp("[\\w\"'.\\s+]+","g"),mZ=new RegExp('"(.*?)"',"g"),yZ=new RegExp("[\\w\"'@#$.\\s-+]+","g"),uR=new RegExp("\\${([^}]*)}","g"),SZ=/^\..*/gm,CC=/\\/gi,IZ=/\\\\/gi,bZ=new RegExp("[\\w\"'@#$.\\s+]+","g"),MZ=/\window\./gm;function hp(n,t,e,i,r){return!t||wC.test(n)||-1!==i.indexOf(n.split(".")[0])||r||"true"===n||"false"===n?n:e+"."+n}function EC(n,t,e,i){return t&&!wC.test(n)&&-1===i.indexOf(n.split(".")[0])?e+'["'+n:n}function pR(n){return n.match(IZ)?n:n.replace(CC,"\\\\")}function fR(n,t,e,i){if(n=n.trim(),/\window\./gm.test(n))return n;var s=/'|"/gm;return/@|\$|#/gm.test(n)&&(n=EC(n,-1===e.indexOf(n),t,e)+'"]'),SZ.test(n)?function EZ(n,t,e,i){return!t||wC.test(n)||-1!==i.indexOf(n.split(".")[0])||/^\..*/gm.test(n)?n:e+"."+n}(n,!s.test(n)&&-1===e.indexOf(n),t,e):hp(n,!s.test(n)&&-1===e.indexOf(n),t,e,i)}var DZ=/^[\n\r.]+0&&t.forEach(function(e){he(e)})},n.removeJsEvents=function(){var t=this.wrapElement.querySelectorAll("["+vR.join("],[")+"]");t.length>0&&t.forEach(function(e){vR.forEach(function(i){e.hasAttribute(i)&&e.removeAttribute(i)})})},n.removeXssAttrs=function(){var t=this;this.removeAttrs.forEach(function(e,i){var r=t.wrapElement.querySelectorAll(e.selector);r.length>0&&r.forEach("a[href]"===e.selector?function(s){-1!==s.getAttribute(e.attribute).replace(/\t|\s|&/,"").indexOf("javascript:alert")&&s.removeAttribute(e.attribute)}:function(s){s.removeAttribute(e.attribute)})})},n}();function PZ(n){return function(t){!function kZ(n,t){t.forEach(function(e){Object.getOwnPropertyNames(e.prototype).forEach(function(i){(!Object.prototype.hasOwnProperty.call(n.prototype,i)||e.isFormBase&&"constructor"!==i)&&(n.prototype["".concat(i)]=e.prototype["".concat(i)])})})}(t,n)}}function mR(n,t,e){var i={};if(n&&n.length){for(var r=0,s=n;r"u"||(y.innerHTML=v.innerHTML?v.innerHTML:"",void 0!==v.className&&(y.className=v.className),void 0!==v.id&&(y.id=v.id),void 0!==v.styles&&y.setAttribute("style",v.styles),void 0!==e.ngAttr&&y.setAttribute(e.ngAttr,""),void 0!==v.attrs&&Fe(y,v.attrs)),y};for(var i=0,r=e.tags;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s}function jZ(n){for(var t,e=n.childNodes,i=0;i"u"&&(c["".concat(o)]=[]),c["".concat(o)].push(h),h.rootNodes}}});var ml,hd,ph,Vg,ac,uo,YZ=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),La=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Jo_RTL=(new Lg,"e-rtl"),ys=function(n){function t(e,i){return n.call(this,e,i)||this}return YZ(t,n),t.prototype.preRender=function(){},t.prototype.render=function(){this.initialize(),this.removeRippleEffect=function ms(n,t,e){var i=function q$(n){return{selector:n&&n.selector?n.selector:null,ignore:n&&n.ignore?n.ignore:null,rippleFlag:n&&n.rippleFlag,isCenterRipple:n&&n.isCenterRipple,duration:n&&n.duration?n.duration:350}}(t);return!1===i.rippleFlag||void 0===i.rippleFlag&&!Zo?function(){}:(n.setAttribute("data-ripple","true"),E.add(n,"mousedown",Zz,{parent:n,rippleOptions:i}),E.add(n,"mouseup",Jz,{parent:n,rippleOptions:i,done:e}),E.add(n,"mouseleave",op,{parent:n,rippleOptions:i}),X.isPointer&&E.add(n,"transitionend",op,{parent:n,rippleOptions:i}),function(){n.removeAttribute("data-ripple"),E.remove(n,"mousedown",Zz),E.remove(n,"mouseup",Jz),E.remove(n,"mouseleave",op),E.remove(n,"transitionend",op)})}(this.element,{selector:".e-btn"}),this.renderComplete()},t.prototype.initialize=function(){if(this.cssClass&&V([this.element],this.cssClass.replace(/\s+/g," ").trim().split(" ")),this.isPrimary&&this.element.classList.add("e-primary"),!ce()||ce()&&"progress-btn"!==this.getModuleName()){if(this.content){var e=this.enableHtmlSanitizer?Ti.sanitize(this.content):this.content;this.element.innerHTML=e}this.setIconCss()}this.enableRtl&&this.element.classList.add(Jo_RTL),this.disabled?this.controlStatus(this.disabled):this.wireEvents()},t.prototype.controlStatus=function(e){this.element.disabled=e},t.prototype.setIconCss=function(){if(this.iconCss){var e=this.createElement("span",{className:"e-btn-icon "+this.iconCss});this.element.textContent.trim()?(e.classList.add("e-icon-"+this.iconPosition.toLowerCase()),("Top"===this.iconPosition||"Bottom"===this.iconPosition)&&this.element.classList.add("e-"+this.iconPosition.toLowerCase()+"-icon-btn")):this.element.classList.add("e-icon-btn");var i=this.element.childNodes[0];!i||"Left"!==this.iconPosition&&"Top"!==this.iconPosition?this.element.appendChild(e):this.element.insertBefore(e,i)}},t.prototype.wireEvents=function(){this.isToggle&&E.add(this.element,"click",this.btnClickHandler,this)},t.prototype.unWireEvents=function(){this.isToggle&&E.remove(this.element,"click",this.btnClickHandler)},t.prototype.btnClickHandler=function(){this.element.classList.contains("e-active")?this.element.classList.remove("e-active"):this.element.classList.add("e-active")},t.prototype.destroy=function(){var e=["e-primary",Jo_RTL,"e-icon-btn","e-success","e-info","e-danger","e-warning","e-flat","e-outline","e-small","e-bigger","e-active","e-round","e-top-icon-btn","e-bottom-icon-btn"];this.cssClass&&(e=e.concat(this.cssClass.split(" "))),n.prototype.destroy.call(this),K([this.element],e),this.element.getAttribute("class")||this.element.removeAttribute("class"),this.disabled&&this.element.removeAttribute("disabled"),this.content&&(this.element.innerHTML=this.element.innerHTML.replace(this.content,""));var i=this.element.querySelector("span.e-btn-icon");i&&he(i),this.unWireEvents(),Zo&&this.removeRippleEffect()},t.prototype.getModuleName=function(){return"btn"},t.prototype.getPersistData=function(){return this.addOnPersist([])},t.Inject=function(){},t.prototype.onPropertyChanged=function(e,i){for(var r=this.element.querySelector("span.e-btn-icon"),s=0,o=Object.keys(e);s=hd.width?hd.width:0;return ml.right+JR()-n}function uE(){return j0()+ml.width/2}function pE(n,t,e,i){if(void 0===t&&(t=null),void 0===e&&(e={X:!1,Y:!1}),!e.Y&&!e.X)return{left:0,top:0};var r=n.getBoundingClientRect();if(uo=t,ac=n.ownerDocument,i||(i=is(n,"left","top")),e.X){var s=uo?r4():l4(),o=yE(),a=SE(),l=o-i.left,h=i.left+r.width-a;r.width>s?i.left=l>0&&h<=0?a-r.width:h>0&&l<=0?o:l>h?a-r.width:o:l>0?i.left+=l:h>0&&(i.left-=h)}if(e.Y){var c=uo?n4():a4(),d=mE(),u=IE(),p=d-i.top,f=i.top+r.height-u;r.height>c?i.top=p>0&&f<=0?u-r.height:f>0&&p<=0?d:p>f?u-r.height:d:p>0?i.top+=p:f>0&&(i.top-=f)}return i}function lc(n,t,e,i){void 0===t&&(t=null);var r=is(n,"left","top");e&&(r.left=e),i&&(r.top=i);var s=[];uo=t,ac=n.ownerDocument;var o=n.getBoundingClientRect(),l=r.left,h=r.left+o.width,d=vE(r.top,r.top+o.height),u=e4(l,h);return d.topSide&&s.push("top"),u.rightSide&&s.push("right"),u.leftSide&&s.push("left"),d.bottomSide&&s.push("bottom"),s}function bJ(n,t,e,i,r,s,o,a,l){if(void 0===o&&(o=null),void 0===a&&(a={X:!0,Y:!0}),t&&n&&r&&s&&(a.X||a.Y)){var d,h={TL:null,TR:null,BL:null,BR:null},c={TL:null,TR:null,BL:null,BR:null};if("none"===window.getComputedStyle(n).display){var u=n.style.visibility;n.style.visibility="hidden",n.style.display="block",d=n.getBoundingClientRect(),n.style.removeProperty("display"),n.style.visibility=u}else d=n.getBoundingClientRect();var p={posX:r,posY:s,offsetX:e,offsetY:i,position:{left:0,top:0}};uo=o,ac=t.ownerDocument,function wJ(n,t,e,i,r){e.position=is(n,e.posX,e.posY,i,r),t.TL=is(n,"left","top",i,r),t.TR=is(n,"right","top",i,r),t.BR=is(n,"left","bottom",i,r),t.BL=is(n,"right","bottom",i,r)}(t,h,p,l,d),gE(c,p,d),a.X&&t4(t,c,h,p,d,!0),a.Y&&h.TL.top>-1&&i4(t,c,h,p,d,!0),function MJ(n,t,e){var i=0,r=0;if(null!=n.offsetParent&&("absolute"===getComputedStyle(n.offsetParent).position||"relative"===getComputedStyle(n.offsetParent).position)){var s=is(n.offsetParent,"left","top",!1,e);i=s.left,r=s.top}var o=1,a=1,l=KR(n);if(l){var h=getComputedStyle(l).transform;if("none"!==h){var c=new DOMMatrix(h);o=c.a,a=c.d}if("none"!==getComputedStyle(l).zoom){var u=fE(document.body);o*=u,a*=u}}n.style.top=t.position.top/a+t.offsetY-r/a+"px",n.style.left=t.position.left/o+t.offsetX-i/o+"px"}(n,p,d)}}function fE(n){var t=getComputedStyle(n).zoom;return parseFloat(t)||1}function KR(n){for(;n;){var t=window.getComputedStyle(n).transform,e=fE(document.body);if(t&&"none"!==t||e&&1!==e)return n;if(n===document.body)return null;n=n.offsetParent||n.parentElement}return null}function gE(n,t,e){n.TL={top:t.position.top+t.offsetY,left:t.position.left+t.offsetX},n.TR={top:n.TL.top,left:n.TL.left+e.width},n.BL={top:n.TL.top+e.height,left:n.TL.left},n.BR={top:n.TL.top+e.height,left:n.TL.left+e.width}}function e4(n,t){var e=!1,i=!1;return n-W0()SE()&&(i=!0),{leftSide:e,rightSide:i}}function t4(n,t,e,i,r,s){var o=e4(t.TL.left,t.TR.left),a=vE(t.TL.top,t.BL.top);e.TL.left-W0()<=yE()&&(o.leftSide=!1),e.TR.left>SE()&&(o.rightSide=!1),(o.leftSide&&!o.rightSide||!o.leftSide&&o.rightSide)&&(i.posX="right"===i.posX?"left":"right",i.offsetX=i.offsetX+r.width,i.offsetX=-1*i.offsetX,i.position=is(n,i.posX,i.posY,!1),gE(t,i,r),s&&t4(n,t,e,i,r,!1),!o.leftSide&&o.rightSide&&a.bottomSide&&(i.offsetX=0))}function i4(n,t,e,i,r,s){var o=vE(t.TL.top,t.BL.top);e.TL.top-V0()<=mE()&&(o.topSide=!1),e.BL.top>=IE()&&n.getBoundingClientRect().bottomIE()&&(i=!0),{topSide:e,bottomSide:i}}function r4(){return uo.getBoundingClientRect().width}function n4(){return uo.getBoundingClientRect().height}function s4(){return uo.getBoundingClientRect().left}function o4(){return uo.getBoundingClientRect().top}function mE(){return uo?o4():0}function yE(){return uo?s4():0}function SE(){return uo?W0()+s4()+r4():W0()+l4()}function IE(){return uo?V0()+o4()+n4():V0()+a4()}function V0(){return ac.documentElement.scrollTop||ac.body.scrollTop}function W0(){return ac.documentElement.scrollLeft||ac.body.scrollLeft}function a4(){return window.innerHeight}function l4(){var n=window.innerWidth,t=document.documentElement.getBoundingClientRect();return n-(n-(m(document.documentElement)?0:t.width))}function h4(){uo=null,ac=null}var c4=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),bn=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},d4=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return c4(t,n),bn([I("left")],t.prototype,"X",void 0),bn([I("top")],t.prototype,"Y",void 0),t}(Ee),Gn_OPEN="e-popup-open",Gn_CLOSE="e-popup-close",hc=function(n){function t(e,i){return n.call(this,i,e)||this}return c4(t,n),t.prototype.onPropertyChanged=function(e,i){for(var r=0,s=Object.keys(e);r0&&c.left>0&&c.right>0&&c.bottom>0}var s=i.getBoundingClientRect();return!(r.bottoms.bottom||r.right>s.right||r.leftr.top?this.element.style.top="0px":s.bottomr.left&&(this.element.style.left=parseInt(this.element.style.left,10)+(s.left-r.left)+"px"))}},t.prototype.checkCollision=function(){var e=this.collision.X,i=this.collision.Y;"none"===e&&"none"===i||("flip"===e&&"flip"===i?this.callFlip({X:!0,Y:!0}):"fit"===e&&"fit"===i?this.callFit({X:!0,Y:!0}):("flip"===e?this.callFlip({X:!0,Y:!1}):"flip"===i&&this.callFlip({Y:!0,X:!1}),"fit"===e?this.callFit({X:!0,Y:!1}):"fit"===i&&this.callFit({X:!1,Y:!0})))},t.prototype.show=function(e,i){var r=this;if(this.getRelateToElement().classList.contains("e-filemanager")&&(this.fmDialogContainer=this.element.getElementsByClassName("e-file-select-wrap")[0]),this.wireEvents(),!m(this.fmDialogContainer)&&X.isIos&&(this.fmDialogContainer.style.display="block"),1e3===this.zIndex||!m(i)){var o=m(i)?this.element:i;this.zIndex=cc(o),je(this.element,{zIndex:this.zIndex})}e=m(e)||"object"!=typeof e?this.showAnimation:e,("none"!==this.collision.X||"none"!==this.collision.Y)&&(K([this.element],Gn_CLOSE),V([this.element],Gn_OPEN),this.checkCollision(),K([this.element],Gn_OPEN),V([this.element],Gn_CLOSE)),m(e)?(K([this.element],Gn_CLOSE),V([this.element],Gn_OPEN),this.trigger("open")):(e.begin=function(){r.isDestroyed||(K([r.element],Gn_CLOSE),V([r.element],Gn_OPEN))},e.end=function(){r.isDestroyed||r.trigger("open")},new Hs(e).animate(this.element))},t.prototype.hide=function(e){var i=this;e=m(e)||"object"!=typeof e?this.hideAnimation:e,m(e)?(K([this.element],Gn_OPEN),V([this.element],Gn_CLOSE),this.trigger("close")):(e.end=function(){i.isDestroyed||(K([i.element],Gn_OPEN),V([i.element],Gn_CLOSE),i.trigger("close"))},new Hs(e).animate(this.element)),this.unwireEvents()},t.prototype.getScrollableParent=function(e){return this.checkFixedParent(e),function bE(n,t){for(var e=getComputedStyle(n),i=[],r=/(auto|scroll)/,s=n.parentElement;s&&"HTML"!==s.tagName;){var o=getComputedStyle(s);!("absolute"===e.position&&"static"===o.position)&&r.test(o.overflow+o.overflowY+o.overflowX)&&i.push(s),s=s.parentElement}return t||i.push(document),i}(e,this.fixedParent)},t.prototype.checkFixedParent=function(e){for(var i=e.parentElement;i&&"HTML"!==i.tagName;){var r=getComputedStyle(i);("fixed"===r.position||"sticky"===r.position)&&!m(this.element)&&this.element.offsetParent&&"BODY"===this.element.offsetParent.tagName&&"hidden"!==getComputedStyle(this.element.offsetParent).overflow&&(this.element.style.top=window.scrollY>parseInt(this.element.style.top,10)?Re(window.scrollY-parseInt(this.element.style.top,10)):Re(parseInt(this.element.style.top,10)-window.scrollY),this.element.style.position="fixed",this.fixedParent=!0),i=i.parentElement,!m(this.element)&&m(this.element.offsetParent)&&"fixed"===r.position&&"fixed"===this.element.style.position&&(this.fixedParent=!0)}},bn([I("auto")],t.prototype,"height",void 0),bn([I("auto")],t.prototype,"width",void 0),bn([I(null)],t.prototype,"content",void 0),bn([I("container")],t.prototype,"targetType",void 0),bn([I(null)],t.prototype,"viewPortElement",void 0),bn([I({X:"none",Y:"none"})],t.prototype,"collision",void 0),bn([I("")],t.prototype,"relateTo",void 0),bn([re({},d4)],t.prototype,"position",void 0),bn([I(0)],t.prototype,"offsetX",void 0),bn([I(0)],t.prototype,"offsetY",void 0),bn([I(1e3)],t.prototype,"zIndex",void 0),bn([I(!1)],t.prototype,"enableRtl",void 0),bn([I("reposition")],t.prototype,"actionOnScroll",void 0),bn([I(null)],t.prototype,"showAnimation",void 0),bn([I(null)],t.prototype,"hideAnimation",void 0),bn([H()],t.prototype,"open",void 0),bn([H()],t.prototype,"close",void 0),bn([H()],t.prototype,"targetExitViewport",void 0),bn([Ft],t)}(yi);function cc(n){for(var t=n.parentElement,e=[];t&&"BODY"!==t.tagName;){var i=document.defaultView.getComputedStyle(t,null).getPropertyValue("z-index"),r=document.defaultView.getComputedStyle(t,null).getPropertyValue("position");"auto"!==i&&"static"!==r&&e.push(i),t=t.parentElement}for(var s=[],o=0;o2147483647?2147483647:c}var _i,Oa,cp,vh,EE,mh,$t,yh,ME=["north-west","north","north-east","west","east","south-west","south","south-east"],Wg="e-resize-handle",dc="e-focused-handle",CJ="e-dlg-resizable",u4=["e-restrict-left"],p4="e-resize-viewport",EJ=["north","west","east","south"],wE=0,CE=0,f4=0,g4=0,Yg=0,Qg=0,Gg=null,DE=null,xE=null,Y0=!0,v4=0,TE=!0;function xJ(n){AE();var t=mi("span",{attrs:{unselectable:"on",contenteditable:"false"}});t.setAttribute("class","e-dialog-border-resize e-"+n),"south"===n&&(t.style.height="2px",t.style.width="100%",t.style.bottom="0px",t.style.left="0px"),"north"===n&&(t.style.height="2px",t.style.width="100%",t.style.top="0px",t.style.left="0px"),"east"===n&&(t.style.height="100%",t.style.width="2px",t.style.right="0px",t.style.top="0px"),"west"===n&&(t.style.height="100%",t.style.width="2px",t.style.left="0px",t.style.top="0px"),_i.appendChild(t)}function m4(n){var t;return m(n)||(t="string"==typeof n?document.querySelector(n):n),t}function y4(n){for(var t=n||this,e=_i.querySelectorAll("."+Wg),i=0;i-1?"mouse":"touch"}function I4(n){if(n.preventDefault(),_i=n.target.parentElement,AE(),Yg=n.pageX,Qg=n.pageY,n.target.classList.add(dc),m(Gg)||!0!==Gg(n,this)){this.targetEle&&_i&&_i.querySelector("."+CJ)&&($t="body"===this.target?null:this.targetEle,mh=this.targetEle.clientWidth,vh=this.targetEle.clientHeight);var e=m($t)?document:$t;E.add(e,"mousemove",Xg,this),E.add(document,"mouseup",Q0,this);for(var i=0;i=0||s.top<0)&&(e=!0):e=!0;var a=CE+(r-Qg);a=a>cp?a:cp;var l=0;m($t)||(l=o.top);var h=m($t)?0:$t.offsetHeight-$t.clientHeight,c=s.top-l-h/2;if(c=c<0?0:c,s.top>0&&c+a>vh){if(e=!1,_i.classList.contains(p4))return;_i.style.height=vh-parseInt(c.toString(),10)+"px"}else{var d=0;if(e){s.top<0&&t+(s.height+s.top)>0&&a+(d=s.top)<=30&&(a=s.height-(s.height+s.top)+30),a+s.top>=vh&&(_i.style.height=s.height+(t-(s.height+s.top))+"px");var u=m($t)?d:c;a>=cp&&a+u<=vh&&(_i.style.height=a+"px")}}}function NE(n){var e,t=!1,i="mouse"===S4(n.type)?n.pageY:n.touches[0].pageY,r=uc(_i),s=m($t)?0:$t.offsetHeight-$t.clientHeight;m($t)||(e=uc($t)),(!m($t)&&r.top-e.top>0||m($t)&&i>0||!m($t)&&Math.floor(r.top-e.top+r.height+(e.bottom-r.bottom))-s<=vh)&&(t=!0);var o=CE-(i-Qg);if(t&&o>=cp&&o<=vh){var a=0;m($t)||(a=e.top);var l=g4-a+(i-Qg);l=l>0?l:1,_i.style.height=o+"px",_i.style.top=l+"px"}}function OE(n){var i,t=document.documentElement.clientWidth,e=!1;m($t)||(i=uc($t));var r="mouse"===S4(n.type)?n.pageX:n.touches[0].pageX,s=uc(_i),o=m($t)?0:$t.offsetWidth-$t.clientWidth,a=m($t)?0:i.left,l=m($t)?0:i.width;m(yh)&&(m($t)?yh=t:(yh=s.left-a-o/2+s.width,yh+=l-o-yh)),(!m($t)&&Math.floor(s.left-i.left+s.width+(i.right-s.right))-o<=mh||m($t)&&r>=0)&&(e=!0);var h=wE-(r-Yg);if(Y0&&(h=h>yh?yh:h),e&&h>=EE&&h<=mh){var c=0;m($t)||(c=i.left);var d=f4-c+(r-Yg);d=d>0?d:1,h!==v4&&TE&&(_i.style.width=h+"px"),Y0&&(_i.style.left=d+"px",TE=1!==d)}v4=h}function kE(n){var i,t=document.documentElement.clientWidth,e=!1;m($t)||(i=uc($t));var s=(n.touches?n.changedTouches[0]:n).pageX,o=uc(_i);(!m($t)&&(o.left-i.left+o.width<=mh||o.right-i.left>=o.width)||m($t)&&t-s>0)&&(e=!0);var a=wE+(s-Yg),l=0;if(m($t)||(l=i.left),o.left-l+a>mh){if(e=!1,_i.classList.contains(p4))return;_i.style.width=mh-(o.left-l)+"px"}e&&a>=EE&&a<=mh&&(_i.style.width=a+"px")}function M4(){for(var n=_i.querySelectorAll("."+Wg),t=0;t=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},OJ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return PE(t,n),Zt([I(!0)],t.prototype,"isFlat",void 0),Zt([I()],t.prototype,"buttonModel",void 0),Zt([I("Button")],t.prototype,"type",void 0),Zt([H()],t.prototype,"click",void 0),t}(Ee),kJ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return PE(t,n),Zt([I("Fade")],t.prototype,"effect",void 0),Zt([I(400)],t.prototype,"duration",void 0),Zt([I(0)],t.prototype,"delay",void 0),t}(Ee),G0="e-dialog",zE="e-rtl",RE="e-dlg-header-content",w4="e-dlg-header",X0="e-footer-content",q0="e-dlg-modal",C4="e-icon-dlg-close",yl="e-dlg-target",ka="e-scroll-disabled",E4="e-device",$0="e-dlg-fullscreen",D4="e-dlg-closeicon-btn",x4="e-popup-open",T4="Information",A4="e-scroll-disabled",L4="e-alert-dialog",N4="e-confirm-dialog",HE="e-dlg-resizable",dp="e-restrict-left",O4="e-resize-viewport",BE="user action",QJ=function(n){function t(e,i){var r=n.call(this,e,i)||this;return r.needsID=!0,r}return PE(t,n),t.prototype.render=function(){this.initialize(),this.initRender(),this.wireEvents(),"100%"===this.width&&(this.element.style.width=""),""!==this.minHeight&&(this.element.style.minHeight=Re(this.minHeight)),this.enableResize&&(this.setResize(),this.isModal&&(this.isModelResize=!0),"None"===this.animationSettings.effect&&this.getMinHeight()),this.renderComplete()},t.prototype.initializeValue=function(){this.dlgClosedBy=BE},t.prototype.preRender=function(){var e=this;if(this.initializeValue(),this.headerContent=null,this.allowMaxHeight=!0,this.preventVisibility=!0,this.clonedEle=this.element.cloneNode(!0),this.closeIconClickEventHandler=function(s){e.dlgClosedBy="close icon",e.hide(s)},this.dlgOverlayClickEventHandler=function(s){e.dlgClosedBy="overlayClick",s.preventFocus=!1,e.trigger("overlayClick",s,function(o){o.preventFocus||e.focusContent(),e.dlgClosedBy=BE})},this.l10n=new ho("dialog",{close:"Close"},this.locale),this.checkPositionData(),m(this.target)){var r=this.isProtectedOnChange;this.isProtectedOnChange=!0,this.target=document.body,this.isProtectedOnChange=r}},t.prototype.updatePersistData=function(){this.enablePersistence&&this.setProperties({width:parseFloat(this.element.style.width),height:parseFloat(this.element.style.height),position:{X:parseFloat(this.dragObj.element.style.left),Y:parseFloat(this.dragObj.element.style.top)}},!0)},t.prototype.isNumberValue=function(e){return/^[-+]?\d*\.?\d+$/.test(e)},t.prototype.checkPositionData=function(){if(!m(this.position)){if(!m(this.position.X)&&"number"!=typeof this.position.X&&this.isNumberValue(this.position.X)){var i=this.isProtectedOnChange;this.isProtectedOnChange=!0,this.position.X=parseFloat(this.position.X),this.isProtectedOnChange=i}m(this.position.Y)||"number"==typeof this.position.Y||this.isNumberValue(this.position.Y)&&(i=this.isProtectedOnChange,this.isProtectedOnChange=!0,this.position.Y=parseFloat(this.position.Y),this.isProtectedOnChange=i)}},t.prototype.getEle=function(e,i){for(var r=void 0,s=0;s=0&&t[e])xJ(t[e]);else if(""!==t[e].trim()){var i=mi("div",{className:"e-icons "+Wg+" e-"+t[e]});_i.appendChild(i)}cp=n.minHeight,EE=n.minWidth,mh=n.maxWidth,vh=n.maxHeight,n.proxy&&n.proxy.element&&n.proxy.element.classList.contains("e-dialog")?y4(n.proxy):y4()}({element:this.element,direction:r,minHeight:parseInt(e.slice(0,i.indexOf("p")),10),maxHeight:this.targetEle.clientHeight,minWidth:parseInt(i.slice(0,i.indexOf("p")),10),maxWidth:this.targetEle.clientWidth,boundary:this.target===document.body?null:this.targetEle,resizeBegin:this.onResizeStart.bind(this),resizeComplete:this.onResizeComplete.bind(this),resizing:this.onResizing.bind(this),proxy:this}),this.wireWindowResizeEvent()}else M4(),this.unWireWindowResizeEvent(),this.element.classList.remove(this.isModal?dp:O4),this.element.classList.remove(HE)},t.prototype.getFocusElement=function(e){var r=e.querySelectorAll('input,select,textarea,button:enabled,a,[contenteditable="true"],[tabindex]');return{element:r[r.length-1]}},t.prototype.keyDown=function(e){var i=this;if(9===e.keyCode&&this.isModal){var r=void 0;m(this.btnObj)||(r=this.btnObj[this.btnObj.length-1]),m(this.btnObj)&&!m(this.ftrTemplateContent)&&(r=this.getFocusElement(this.ftrTemplateContent)),m(this.btnObj)&&m(this.ftrTemplateContent)&&!m(this.contentEle)&&(r=this.getFocusElement(this.contentEle)),!m(r)&&document.activeElement===r.element&&!e.shiftKey&&(e.preventDefault(),this.focusableElements(this.element).focus()),document.activeElement===this.focusableElements(this.element)&&e.shiftKey&&(e.preventDefault(),m(r)||r.element.focus())}var h,s=document.activeElement,o=["input","textarea"].indexOf(s.tagName.toLowerCase())>-1,a=!1;if(o||(a=s.hasAttribute("contenteditable")&&"true"===s.getAttribute("contenteditable")),27===e.keyCode&&this.closeOnEscape){this.dlgClosedBy="escape";var l=document.querySelector(".e-popup-open:not(.e-dialog)");!m(l)&&!l.classList.contains("e-toolbar-pop")||this.hide(e)}(13===e.keyCode&&!e.ctrlKey&&"textarea"!==s.tagName.toLowerCase()&&o&&!m(this.primaryButtonEle)||13===e.keyCode&&e.ctrlKey&&("textarea"===s.tagName.toLowerCase()||a)&&!m(this.primaryButtonEle))&&this.buttons.some(function(d,u){h=u;var p=d.buttonModel;return!m(p)&&!0===p.isPrimary})&&"function"==typeof this.buttons[h].click&&setTimeout(function(){i.buttons[h].click.call(i,e)})},t.prototype.initialize=function(){m(this.target)||(this.targetEle="string"==typeof this.target?document.querySelector(this.target):this.target),this.isBlazorServerRender()||V([this.element],G0),X.isDevice&&V([this.element],E4),this.isBlazorServerRender()||this.setCSSClass(),this.setMaxHeight()},t.prototype.initRender=function(){var e=this;if(this.initialRender=!0,this.isBlazorServerRender()||Fe(this.element,{role:"dialog"}),1e3===this.zIndex?(this.setzIndex(this.element,!1),this.calculatezIndex=!0):this.calculatezIndex=!1,this.setTargetContent(),""!==this.header&&!m(this.header)&&this.setHeader(),this.renderCloseIcon(),this.setContent(),""===this.footerTemplate||m(this.footerTemplate)?!m(this.buttons[0])&&!m(this.buttons[0].buttonModel)&&this.setButton():this.setFooterTemplate(),this.allowDragging&&!m(this.headerContent)&&this.setAllowDragging(),Fe(this.element,{"aria-modal":this.isModal?"true":"false"}),this.isModal&&this.setIsModal(),!0!==this.element.classList.contains(L4)&&!0!==this.element.classList.contains(N4)&&!m(this.element.parentElement)){var i=this.isModal?this.dlgContainer.parentElement:this.element.parentElement;this.refElement=this.createElement("div",{className:"e-dlg-ref-element"}),i.insertBefore(this.refElement,this.isModal?this.dlgContainer:this.element)}if(m(this.targetEle)||this.targetEle.appendChild(this.isModal?this.dlgContainer:this.element),this.popupObj=new hc(this.element,{height:this.height,width:this.width,zIndex:this.zIndex,relateTo:this.target,actionOnScroll:"none",enableRtl:this.enableRtl,open:function(o){var a={container:e.isModal?e.dlgContainer:e.element,element:e.element,target:e.target,preventFocus:!1};e.enableResize&&e.resetResizeIcon(),e.trigger("open",a,function(l){l.preventFocus||e.focusContent()})},close:function(o){e.isModal&&V([e.dlgOverlay],"e-fade"),e.unBindEvent(e.element),e.isModal&&(e.dlgContainer.style.display="none"),e.trigger("close",e.closeArgs);var a=document.activeElement;!m(a)&&!m(a.blur)&&a.blur(),!m(e.storeActiveElement)&&!m(e.storeActiveElement.focus)&&e.storeActiveElement.focus()}}),this.positionChange(),this.setEnableRTL(),this.isBlazorServerRender()||(V([this.element],"e-popup-close"),this.isModal&&this.setOverlayZindex()),this.visible){if(this.show(),this.isModal){var r=this.getTargetContainer(this.target);r instanceof Element&&"rtl"===window.getComputedStyle(r).getPropertyValue("direction")&&this.setPopupPosition()}}else this.isModal&&(this.dlgOverlay.style.display="none");this.initialRender=!1},t.prototype.getTargetContainer=function(e){var i=null;if("string"==typeof e)if(e.startsWith("#"))i=document.getElementById(e.substring(1));else if(e.startsWith(".")){var r=document.getElementsByClassName(e.substring(1));i=r.length>0?r[0]:null}else!(e instanceof HTMLElement)&&e!==document.body&&(i=document.querySelector(e));else e instanceof HTMLElement&&(i=e);return i},t.prototype.resetResizeIcon=function(){var e=this.getMinHeight();if(this.targetEle.offsetHeight0&&("function"==typeof this.buttons[e].click&&E.add(s[e],"click",this.buttons[e].click,this),"object"==typeof this.buttons[e].click&&E.add(s[e],"click",this.buttonClickHandler.bind(this,e),this)),!this.isBlazorServerRender()&&!m(this.ftrTemplateContent)&&(this.btnObj[e].appendTo(this.ftrTemplateContent.children[e]),this.buttons[e].isFlat&&this.btnObj[e].element.classList.add("e-flat"),this.primaryButtonEle=this.element.getElementsByClassName("e-primary")[0]))},t.prototype.buttonClickHandler=function(e){this.trigger("buttons["+e+"].click",{})},t.prototype.setContent=function(){this.contentEle=this.createElement("div",{className:"e-dlg-content",id:this.element.id+"_dialog-content"}),Fe(this.element,this.headerEle?{"aria-describedby":this.element.id+"_title "+this.element.id+"_dialog-content"}:{"aria-describedby":this.element.id+"_dialog-content"}),this.innerContentElement?this.contentEle.appendChild(this.innerContentElement):(!m(this.content)&&""!==this.content||!this.initialRender)&&(("string"!=typeof this.content||ce())&&this.content instanceof HTMLElement?this.contentEle.appendChild(this.content):this.setTemplate(this.content,this.contentEle,"content")),m(this.headerContent)?this.element.insertBefore(this.contentEle,this.element.children[0]):this.element.insertBefore(this.contentEle,this.element.children[1]),"auto"===this.height&&(!this.isBlazorServerRender()&&X.isIE&&""===this.element.style.width&&!m(this.width)&&(this.element.style.width=Re(this.width)),this.setMaxHeight())},t.prototype.setTemplate=function(e,i,r){var s,o,a;o=i.classList.contains(w4)?this.element.id+"header":i.classList.contains(X0)?this.element.id+"footerTemplate":this.element.id+"content",m(e.outerHTML)?("string"==typeof e||"string"!=typeof e||ce()&&!this.isStringTemplate)&&("string"==typeof e&&(e=this.sanitizeHelper(e)),this.isVue||"string"!=typeof e?(s=ii(e),a=e):i.innerHTML=e):i.appendChild(e);var l=[];if(!m(s)){for(var c=0,d=s({},this,r,o,!(ce()&&!this.isStringTemplate&&0===a.indexOf("
Blazor"))||this.isStringTemplate);c/g,"");(this.element.children.length>0||i)&&(this.innerContentElement=document.createDocumentFragment(),[].slice.call(this.element.childNodes).forEach(function(r){8!==r.nodeType&&e.innerContentElement.appendChild(r)}))}},t.prototype.setHeader=function(){this.headerEle?this.headerEle.innerHTML="":this.headerEle=this.createElement("div",{id:this.element.id+"_title",className:w4}),this.createHeaderContent(),this.headerContent.appendChild(this.headerEle),this.setTemplate(this.header,this.headerEle,"header"),Fe(this.element,{"aria-describedby":this.element.id+"_title"}),Fe(this.element,{"aria-labelledby":this.element.id+"_dialog-header"}),this.element.insertBefore(this.headerContent,this.element.children[0]),this.allowDragging&&!m(this.headerContent)&&this.setAllowDragging()},t.prototype.setFooterTemplate=function(){this.ftrTemplateContent?this.ftrTemplateContent.innerHTML="":this.ftrTemplateContent=this.createElement("div",{className:X0}),""===this.footerTemplate||m(this.footerTemplate)?this.ftrTemplateContent.innerHTML=this.buttonContent.join(""):this.setTemplate(this.footerTemplate,this.ftrTemplateContent,"footerTemplate"),this.element.appendChild(this.ftrTemplateContent)},t.prototype.createHeaderContent=function(){m(this.headerContent)&&(this.headerContent=this.createElement("div",{id:this.element.id+"_dialog-header",className:RE}))},t.prototype.renderCloseIcon=function(){this.showCloseIcon&&(this.closeIcon=this.createElement("button",{className:D4,attrs:{type:"button"}}),this.closeIconBtnObj=new ys({cssClass:"e-flat",iconCss:C4+" e-icons"}),this.closeIconTitle(),m(this.headerContent)?(this.createHeaderContent(),pl([this.closeIcon],this.headerContent),this.element.insertBefore(this.headerContent,this.element.children[0])):pl([this.closeIcon],this.headerContent),this.closeIconBtnObj.appendTo(this.closeIcon))},t.prototype.closeIconTitle=function(){this.l10n.setLocale(this.locale);var e=this.l10n.getConstant("close");this.closeIcon.setAttribute("title",e),this.closeIcon.setAttribute("aria-label",e)},t.prototype.setCSSClass=function(e){e&&(K([this.element],e.split(" ")),this.isModal&&!m(this.dlgContainer)&&K([this.dlgContainer],e.split(" "))),this.cssClass&&(V([this.element],this.cssClass.split(" ")),this.isModal&&!m(this.dlgContainer)&&V([this.dlgContainer],this.cssClass.split(" ")))},t.prototype.setIsModal=function(){this.dlgContainer=this.createElement("div",{className:"e-dlg-container"}),this.setCSSClass(),this.element.classList.remove(x4),this.element.parentNode.insertBefore(this.dlgContainer,this.element),this.dlgContainer.appendChild(this.element),V([this.element],q0),this.dlgOverlay=this.createElement("div",{className:"e-dlg-overlay"}),this.dlgOverlay.style.zIndex=(this.zIndex-1).toString(),this.dlgContainer.appendChild(this.dlgOverlay)},t.prototype.getValidFocusNode=function(e){for(var i,r=0;r0||"a"===i.tagName.toLowerCase()&&i.hasAttribute("href"))&&i.tabIndex>-1&&!i.disabled&&!this.disableElement(i,'[disabled],[aria-disabled="true"],[type="hidden"]'))return i;i=null}return i},t.prototype.focusableElements=function(e){if(!m(e)){var r=e.querySelectorAll('input,select,textarea,button,a,[contenteditable="true"],[tabindex]');return this.getValidFocusNode(r)}return null},t.prototype.getAutoFocusNode=function(e){var i=e.querySelector("."+D4),s=e.querySelectorAll("[autofocus]"),o=this.getValidFocusNode(s);if(ce()&&(this.primaryButtonEle=this.element.getElementsByClassName("e-primary")[0]),m(o)){if(!m(o=this.focusableElements(this.contentEle)))return o;if(!m(this.primaryButtonEle))return this.element.querySelector(".e-primary")}else i=o;return i},t.prototype.disableElement=function(e,i){var r=e?e.matches||e.webkitMatchesSelector||e.msGetRegionContent:null;if(r)for(;e;e=e.parentNode)if(e instanceof Element&&r.call(e,i))return e;return null},t.prototype.focusContent=function(){var e=this.getAutoFocusNode(this.element),i=m(e)?this.element:e,r=X.userAgent;(r.indexOf("MSIE ")>0||r.indexOf("Trident/")>0)&&this.element.focus(),i.focus(),this.unBindEvent(this.element),this.bindEvent(this.element)},t.prototype.bindEvent=function(e){E.add(e,"keydown",this.keyDown,this)},t.prototype.unBindEvent=function(e){E.remove(e,"keydown",this.keyDown)},t.prototype.updateSanitizeContent=function(){this.isBlazorServerRender()||(this.contentEle.innerHTML=this.sanitizeHelper(this.content))},t.prototype.isBlazorServerRender=function(){return ce()&&this.isServerRendered},t.prototype.getModuleName=function(){return"dialog"},t.prototype.onPropertyChanged=function(e,i){if(this.element.classList.contains(G0))for(var r=0,s=Object.keys(e);r0?this.showCloseIcon||""!==this.header&&!m(this.header)?this.showCloseIcon||he(this.closeIcon):(he(this.headerContent),this.headerContent=null):(this.renderCloseIcon(),this.wireEvents());break;case"locale":this.showCloseIcon&&this.closeIconTitle();break;case"visible":this.visible?this.show():this.hide();break;case"isModal":this.updateIsModal();break;case"height":je(this.element,{height:Re(e.height)}),this.updatePersistData();break;case"width":je(this.element,{width:Re(e.width)}),this.updatePersistData();break;case"zIndex":this.popupObj.zIndex=this.zIndex,this.isModal&&this.setOverlayZindex(this.zIndex),this.element.style.zIndex!==this.zIndex.toString()&&(this.calculatezIndex=!1);break;case"cssClass":this.setCSSClass(i.cssClass);break;case"buttons":this.unWireButtonEvents(),this.destroyButtons(),m(this.ftrTemplateContent)||(he(this.ftrTemplateContent),this.ftrTemplateContent=null),this.footerTemplate="",this.setButton();break;case"allowDragging":this.allowDragging&&!m(this.headerContent)?this.setAllowDragging():this.dragObj.destroy();break;case"target":this.setTarget(e.target);break;case"position":if(this.checkPositionData(),this.isModal){var a=this.position.X,l=this.position.Y;m(i.position)||(m(i.position.X)||(a=i.position.X),m(i.position.Y)||(l=i.position.Y)),this.dlgContainer.classList.contains("e-dlg-"+a+"-"+l)&&this.dlgContainer.classList.remove("e-dlg-"+a+"-"+l)}this.positionChange(),this.updatePersistData();break;case"enableRtl":this.setEnableRTL();break;case"enableResize":this.setResize();break;case"minHeight":""!==this.minHeight&&(this.element.style.minHeight=Re(this.minHeight))}},t.prototype.setTarget=function(e){this.popupObj.relateTo=e,this.target=e,this.targetEle="string"==typeof this.target?document.querySelector(this.target):this.target,this.dragObj&&(this.dragObj.dragArea=this.targetEle),this.setMaxHeight(),this.isModal&&this.updateIsModal(),this.enableResize&&this.setResize()},t.prototype.updateIsModal=function(){if(this.element.setAttribute("aria-modal",this.isModal?"true":"false"),this.isModal)m(this.dlgOverlay)&&(this.setIsModal(),this.element.style.top="0px",this.element.style.left="0px",m(this.targetEle)||this.targetEle.appendChild(this.dlgContainer));else{for(K([this.element],q0),K([document.body],[yl,ka]),he(this.dlgOverlay);this.dlgContainer.firstChild;)this.dlgContainer.parentElement.insertBefore(this.dlgContainer.firstChild,this.dlgContainer);this.dlgContainer.parentElement.removeChild(this.dlgContainer)}this.visible&&this.show(),this.positionChange(),this.isModal&&this.dlgOverlay&&E.add(this.dlgOverlay,"click",this.dlgOverlayClickEventHandler,this)},t.prototype.setzIndex=function(e,i){var r=this.isProtectedOnChange;this.isProtectedOnChange=!0;var s=cc(e);this.zIndex=s>this.zIndex?s:this.zIndex,this.isProtectedOnChange=r,i&&(this.popupObj.zIndex=this.zIndex)},t.prototype.windowResizeHandler=function(){(function AJ(n){mh=n})(this.targetEle.clientWidth),function LJ(n){vh=n}(this.targetEle.clientHeight),this.setMaxHeight()},t.prototype.getPersistData=function(){return this.addOnPersist(["width","height","position"])},t.prototype.removeAllChildren=function(e){for(;e.children[0];)this.removeAllChildren(e.children[0]),e.removeChild(e.children[0])},t.prototype.destroy=function(){if(!this.isDestroyed){var e=[zE,q0,HE,dp,$0,E4],i=["role","aria-modal","aria-labelledby","aria-describedby","aria-grabbed","tabindex","style"];K([this.targetEle],[yl,ka]),!m(this.element)&&this.element.classList.contains($0)&&K([document.body],[yl,ka]),this.isModal&&K([m(this.targetEle)?document.body:this.targetEle],ka),this.unWireEvents(),this.unWireButtonEvents(),this.destroyButtons(),m(this.closeIconBtnObj)||this.closeIconBtnObj.destroy(),m(this.dragObj)||this.dragObj.destroy(),!m(this.popupObj.element)&&this.popupObj.element.classList.contains("e-popup")&&this.popupObj.destroy(),K([this.element],e),!m(this.cssClass)&&""!==this.cssClass&&K([this.element],this.cssClass.split(" ")),!m(this.refElement)&&!m(this.refElement.parentElement)&&(this.refElement.parentElement.insertBefore(this.isModal?this.dlgContainer:this.element,this.refElement),he(this.refElement),this.refElement=void 0),this.isModal&&(he(this.dlgOverlay),this.dlgContainer.parentNode.insertBefore(this.element,this.dlgContainer),he(this.dlgContainer)),this.element.innerHTML=this.clonedEle.innerHTML;for(var r=0;r0&&""===this.footerTemplate&&this.ftrTemplateContent)for(var e=0;e=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},FE="e-tooltip",B4="e-icons",F4="e-tooltip-close",_E="e-tooltip-wrap",_4="e-tip-content",up="e-arrow-tip",U4="e-arrow-tip-outer",Z0="e-arrow-tip-inner",qg="e-tip-bottom",UE="e-tip-top",j4="e-tip-left",jE="e-tip-right",VE="e-popup",$g="e-popup-open",WE="e-popup-close",J0="e-lib",V4="e-tooltip-popup-container",JJ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return P4(t,n),Gi([I({effect:"FadeIn",duration:150,delay:0})],t.prototype,"open",void 0),Gi([I({effect:"FadeOut",duration:150,delay:0})],t.prototype,"close",void 0),t}(Ee),Sh=function(n){function t(e,i){var r=n.call(this,e,i)||this;return r.mouseMoveEvent=null,r.mouseMoveTarget=null,r.containerElement=null,r.isBodyContainer=!0,r}return P4(t,n),t.prototype.initialize=function(){this.formatPosition(),V([this.element],FE)},t.prototype.formatPosition=function(){var e,i;this.position&&(0===this.position.indexOf("Top")||0===this.position.indexOf("Bottom")?(e=this.position.split(/(?=[A-Z])/),this.tooltipPositionY=e[0],this.tooltipPositionX=e[1]):(i=this.position.split(/(?=[A-Z])/),this.tooltipPositionX=i[0],this.tooltipPositionY=i[1]))},t.prototype.renderArrow=function(){this.setTipClass(this.position);var e=this.createElement("div",{className:up+" "+this.tipClass});e.appendChild(this.createElement("div",{className:U4+" "+this.tipClass})),e.appendChild(this.createElement("div",{className:Z0+" "+this.tipClass})),this.tooltipEle.appendChild(e)},t.prototype.setTipClass=function(e){this.tipClass=0===e.indexOf("Right")?j4:0===e.indexOf("Bottom")?UE:0===e.indexOf("Left")?jE:qg},t.prototype.renderPopup=function(e){var i=this.mouseTrail?{top:0,left:0}:this.getTooltipPosition(e);this.tooltipEle.classList.remove(J0),this.popupObj=new hc(this.tooltipEle,{height:this.height,width:this.width,position:{X:i.left,Y:i.top},enableRtl:this.enableRtl,open:this.openPopupHandler.bind(this),close:this.closePopupHandler.bind(this)})},t.prototype.getScalingFactor=function(e){if(!e)return{x:1,y:1};var i={x:1,y:1},r=e.closest('[style*="transform: scale"]');if(r&&r!==this.tooltipEle&&r.contains(this.tooltipEle)){var a=window.getComputedStyle(r).getPropertyValue("transform").match(/matrix\(([^)]+)\)/)[1].split(",").map(parseFloat);i.x=a[0],i.y=a[3]}return i},t.prototype.getTooltipPosition=function(e){this.tooltipEle.style.display="block";var i=this.element.closest('[style*="zoom"]');i&&(i.contains(this.tooltipEle)||(this.tooltipEle.style.zoom=getComputedStyle(i).zoom));var r=is(e,this.tooltipPositionX,this.tooltipPositionY,!this.isBodyContainer,this.isBodyContainer?null:this.containerElement.getBoundingClientRect()),s=this.getScalingFactor(e),o=this.calculateTooltipOffset(this.position,s.x,s.y),a=this.calculateElementPosition(r,o),c=this.collisionFlipFit(e,a[0],a[1]);return c.left=c.left/s.x,c.top=c.top/s.y,this.tooltipEle.style.display="",c},t.prototype.windowResize=function(){this.reposition(this.findTarget())},t.prototype.reposition=function(e){if(this.popupObj&&e){var i=this.getTooltipPosition(e);this.popupObj.position={X:i.left,Y:i.top},this.popupObj.dataBind()}},t.prototype.openPopupHandler=function(){!this.mouseTrail&&this.needTemplateReposition()&&this.reposition(this.findTarget()),this.trigger("afterOpen",this.tooltipEventArgs),this.tooltipEventArgs=null},t.prototype.closePopupHandler=function(){this.isReact&&!("Click"===this.opensOn||"function"==typeof this.content)&&this.clearTemplate(["content"]),this.clear();var e={type:this.tooltipEventArgs.event?this.tooltipEventArgs.event.type:null,cancel:!1,target:this.tooltipEventArgs.target,event:this.tooltipEventArgs.event?this.tooltipEventArgs.event:null,element:this.tooltipEle,isInteracted:!m(this.tooltipEventArgs.event)};this.trigger("afterClose",e),e=null},t.prototype.calculateTooltipOffset=function(e,i,r){void 0===i&&(i=1),void 0===r&&(r=1);var o,a,l,h,c,d,u,p,s={top:0,left:0};if(1!==i||1!==r){var f=this.tooltipEle.getBoundingClientRect(),g=void 0;l=Math.round(f.width),h=Math.round(f.height),(c=U("."+up,this.tooltipEle))&&(g=c.getBoundingClientRect()),o=c?Math.round(g.width):0,a=c?Math.round(g.height):0,d=this.showTipPointer?0:8,u=a/2+2+(h-this.tooltipEle.clientHeight*r),p=o/2+2+(l-this.tooltipEle.clientWidth*i)}else l=this.tooltipEle.offsetWidth,h=this.tooltipEle.offsetHeight,c=U("."+up,this.tooltipEle),d=this.showTipPointer?0:8,u=(a=c?c.offsetHeight:0)/2+2+(this.tooltipEle.offsetHeight-this.tooltipEle.clientHeight),p=(o=c?c.offsetWidth:0)/2+2+(this.tooltipEle.offsetWidth-this.tooltipEle.clientWidth);switch(this.mouseTrail&&(d+=2),e){case"RightTop":s.left+=o+d,s.top-=h-u;break;case"RightCenter":s.left+=o+d,s.top-=h/2;break;case"RightBottom":s.left+=o+d,s.top-=u;break;case"BottomRight":s.top+=a+d,s.left-=p;break;case"BottomCenter":s.top+=a+d,s.left-=l/2;break;case"BottomLeft":s.top+=a+d,s.left-=l-p;break;case"LeftBottom":s.left-=o+l+d,s.top-=u;break;case"LeftCenter":s.left-=o+l+d,s.top-=h/2;break;case"LeftTop":s.left-=o+l+d,s.top-=h-u;break;case"TopLeft":s.top-=h+a+d,s.left-=l-p;break;case"TopRight":s.top-=h+a+d,s.left-=p;break;default:s.top-=h+a+d,s.left-=l/2}return s.left+=this.offsetX,s.top+=this.offsetY,s},t.prototype.updateTipPosition=function(e){var i=we("."+up+",."+U4+",."+Z0,this.tooltipEle);K(i,[qg,UE,j4,jE]),this.setTipClass(e),V(i,this.tipClass)},t.prototype.adjustArrow=function(e,i,r,s){var o=U("."+up,this.tooltipEle);if(!1!==this.showTipPointer&&null!==o){var a,l;this.updateTipPosition(i),this.tooltipEle.style.display="block";var f,h=this.tooltipEle.clientWidth,c=this.tooltipEle.clientHeight,d=U("."+Z0,this.tooltipEle),u=o.offsetWidth,p=o.offsetHeight;this.tooltipEle.style.display="",this.tipClass===qg||this.tipClass===UE?(this.tipClass===qg?(l="99.9%",d.style.top="-"+(p-2)+"px"):(l=-(p-1)+"px",d.style.top="-"+(p-6)+"px"),e&&(a=(f="Center"!==r||h>e.offsetWidth||this.mouseTrail)&&"Left"===r||!f&&"End"===this.tipPointerPosition?h-u-2+"px":f&&"Right"===r||!f&&"Start"===this.tipPointerPosition?"2px":!f||"End"!==this.tipPointerPosition&&"Start"!==this.tipPointerPosition?h/2-u/2+"px":"End"===this.tipPointerPosition?e.offsetWidth+(this.tooltipEle.offsetWidth-e.offsetWidth)/2-u/2-2+"px":(this.tooltipEle.offsetWidth-e.offsetWidth)/2-u/2+2+"px")):(this.tipClass===jE?(a="99.9%",d.style.left="-"+(u-2)+"px"):(a=-(u-1)+"px",d.style.left=u-2-u+"px"),l=(f="Center"!==s||c>e.offsetHeight||this.mouseTrail)&&"Top"===s||!f&&"End"===this.tipPointerPosition?c-p-2+"px":f&&"Bottom"===s||!f&&"Start"===this.tipPointerPosition?"2px":c/2-p/2+"px"),o.style.top=l,o.style.left=a}},t.prototype.renderContent=function(e){var i=this,r=U("."+_4,this.tooltipEle);if(this.cssClass&&V([this.tooltipEle],this.cssClass.split(" ")),e&&!m(e.getAttribute("title"))&&(e.setAttribute("data-content",e.getAttribute("title")),e.removeAttribute("title")),m(this.content))e&&!m(e.getAttribute("data-content"))&&(r.innerHTML=e.getAttribute("data-content"));else if(r.innerHTML="",this.content instanceof HTMLElement)r.appendChild(this.content);else if("string"==typeof this.content)this.isAngular?this.setProperties({content:Ti.sanitize(this.content)},!0):this.content=this.enableHtmlSanitizer?Ti.sanitize(this.content):this.content,this.enableHtmlParse?(o=ii(this.content)({},this,"content",this.element.id+"content",void 0,void 0,r,this.root))&&Dt(o,r):r.textContent=this.content;else{var o;(o=ii(this.content)({},this,"content",this.element.id+"content",void 0,void 0,r))&&(this.isAngular&&setTimeout(function(){i.reposition(e)},1),Dt(o,r)),this.renderReactTemplates()}},t.prototype.renderCloseIcon=function(){if(this.isSticky){var i=this.createElement("div",{className:B4+" "+F4});this.tooltipEle.appendChild(i),E.add(i,X.touchStartEvent,this.onStickyClose,this)}else{var e=this.tooltipEle.querySelector("."+B4+"."+F4);e&>(e)}},t.prototype.addDescribedBy=function(e,i){var r=(e.getAttribute("aria-describedby")||"").split(/\s+/);r.indexOf(i)<0&&r.push(i),Fe(e,{"aria-describedby":r.join(" ").trim(),"data-tooltip-id":i})},t.prototype.removeDescribedBy=function(e){var i=e.getAttribute("data-tooltip-id"),r=(e.getAttribute("aria-describedby")||"").split(/\s+/),s=r.indexOf(i);-1!==s&&r.splice(s,1),e.removeAttribute("data-tooltip-id");var o=r.join(" ").trim();o?e.setAttribute("aria-describedby",o):e.removeAttribute("aria-describedby")},t.prototype.tapHoldHandler=function(e){clearTimeout(this.autoCloseTimer),this.targetHover(e.originalEvent)},t.prototype.touchEndHandler=function(){var e=this;this.isSticky||(this.autoCloseTimer=setTimeout(function(){e.close()},1500))},t.prototype.targetClick=function(e){var i;!m(i=this.target?J(e.target,this.target):this.element)&&(null===i.getAttribute("data-tooltip-id")?this.targetHover(e):this.isSticky||this.hideTooltip(this.animation.close,e,i))},t.prototype.targetHover=function(e){var i;if(!(m(i=this.target?J(e.target,this.target):this.element)||null!==i.getAttribute("data-tooltip-id")&&0===this.closeDelay)){for(var s=0,o=[].slice.call(we('[data-tooltip-id= "'+this.ctrlId+'_content"]',document));s0?this.showTimer=setTimeout(function(){o.mouseTrail&&E.add(i,"mousemove touchstart mouseenter",o.onMouseMove,o),o.popupObj&&(o.popupObj.show(a,i),o.mouseMoveEvent&&o.mouseTrail&&o.onMouseMove(o.mouseMoveEvent))},this.openDelay):this.popupObj&&this.popupObj.show(a,i)}s&&this.wireMouseEvents(s,i)},t.prototype.needTemplateReposition=function(){return!m(this.viewContainerRef)&&"string"!=typeof this.viewContainerRef||this.isReact},t.prototype.checkCollision=function(e,i,r){var s={left:i,top:r,position:this.position,horizontal:this.tooltipPositionX,vertical:this.tooltipPositionY},o=lc(this.tooltipEle,this.checkCollideTarget(),i,r);return o.length>0&&(s.horizontal=o.indexOf("left")>=0?"Right":o.indexOf("right")>=0?"Left":this.tooltipPositionX,s.vertical=o.indexOf("top")>=0?"Bottom":o.indexOf("bottom")>=0?"Top":this.tooltipPositionY),s},t.prototype.calculateElementPosition=function(e,i){return[this.isBodyContainer?e.left+i.left:e.left-this.containerElement.getBoundingClientRect().left+i.left+window.pageXOffset+this.containerElement.scrollLeft,this.isBodyContainer?e.top+i.top:e.top-this.containerElement.getBoundingClientRect().top+i.top+window.pageYOffset+this.containerElement.scrollTop]},t.prototype.collisionFlipFit=function(e,i,r){var s=this.checkCollision(e,i,r),o=s.position;if(this.tooltipPositionY!==s.vertical&&(o=0===this.position.indexOf("Bottom")||0===this.position.indexOf("Top")?s.vertical+this.tooltipPositionX:this.tooltipPositionX+s.vertical),this.tooltipPositionX!==s.horizontal&&(0===o.indexOf("Left")&&(s.vertical="LeftTop"===o||"LeftCenter"===o?"Top":"Bottom",o=s.vertical+"Left"),0===o.indexOf("Right")&&(s.vertical="RightTop"===o||"RightCenter"===o?"Top":"Bottom",o=s.vertical+"Right"),s.horizontal=this.tooltipPositionX),this.tooltipEventArgs={type:null,cancel:!1,target:e,event:null,element:this.tooltipEle,collidedPosition:o},this.trigger("beforeCollision",this.tooltipEventArgs),this.tooltipEventArgs.cancel)o=this.position;else{var a=s.vertical,l=s.horizontal;if(s.position!==o){var h=is(e,l,a,!this.isBodyContainer,this.isBodyContainer?null:this.containerElement.getBoundingClientRect());this.adjustArrow(e,o,l,a);var c=this.getScalingFactor(e),d=this.calculateTooltipOffset(o,c.x,c.y);d.top-=this.getOffSetPosition("TopBottom",o,this.offsetY),d.left-=this.getOffSetPosition("RightLeft",o,this.offsetX),s.position=o;var u=this.calculateElementPosition(h,d);s.left=u[0],s.top=u[1]}else this.adjustArrow(e,o,l,a)}var p={left:s.left,top:s.top},f=this.isBodyContainer?pE(this.tooltipEle,this.checkCollideTarget(),{X:!0,Y:this.windowCollision},p):p;this.tooltipEle.style.display="block";var g=U("."+up,this.tooltipEle);if(this.showTipPointer&&null!=g&&(0===o.indexOf("Bottom")||0===o.indexOf("Top"))){var v=parseInt(g.style.left,10)-(f.left-s.left);v<0?v=0:v+g.offsetWidth>this.tooltipEle.clientWidth&&(v=this.tooltipEle.clientWidth-g.offsetWidth),g.style.left=v.toString()+"px"}return this.tooltipEle.style.display="",p.left=f.left,p.top=f.top,p},t.prototype.getOffSetPosition=function(e,i,r){return-1!==e.indexOf(this.position.split(/(?=[A-Z])/)[0])&&-1!==e.indexOf(i.split(/(?=[A-Z])/)[0])?2*r:0},t.prototype.checkCollideTarget=function(){return!this.windowCollision&&this.target?this.element:null},t.prototype.hideTooltip=function(e,i,r){var s=this;this.closeDelay>0?(clearTimeout(this.hideTimer),clearTimeout(this.showTimer),this.hideTimer=setTimeout(function(){s.closeDelay&&s.tooltipEle&&s.isTooltipOpen||s.tooltipHide(e,i,r)},this.closeDelay)):this.tooltipHide(e,i,r)},t.prototype.tooltipHide=function(e,i,r){var o,s=this;o=i?this.target?r||i.target:this.element:U('[data-tooltip-id= "'+this.ctrlId+'_content"]',document),this.tooltipEventArgs={type:i?i.type:null,cancel:!1,target:o,event:i||null,element:this.tooltipEle,isInteracted:!m(i)},this.trigger("beforeClose",this.tooltipEventArgs,function(a){a.cancel?s.isHidden=!1:(s.mouseMoveBeforeRemove(),s.popupHide(e,o,i))})},t.prototype.popupHide=function(e,i,r){i&&r&&this.restoreElement(i),this.isHidden=!0;var s={name:this.animation.close.effect,duration:e.duration,delay:e.delay,timingFunction:"easeIn"};"None"===e.effect&&(s=void 0),this.popupObj&&this.popupObj.hide(s)},t.prototype.restoreElement=function(e){this.unwireMouseEvents(e),m(e.getAttribute("data-content"))||(e.setAttribute("title",e.getAttribute("data-content")),e.removeAttribute("data-content")),this.removeDescribedBy(e)},t.prototype.clear=function(){var e=this.findTarget();e&&this.restoreElement(e),this.tooltipEle&&(K([this.tooltipEle],WE),V([this.tooltipEle],$g)),this.isHidden&&(this.popupObj&&this.popupObj.destroy(),this.tooltipEle&>(this.tooltipEle),this.tooltipEle=null,this.popupObj=null)},t.prototype.tooltipHover=function(){this.tooltipEle&&(this.isTooltipOpen=!0)},t.prototype.tooltipMouseOut=function(e){this.isTooltipOpen=!1,this.hideTooltip(this.animation.close,e,this.findTarget())},t.prototype.onMouseOut=function(e){var i=e.relatedTarget;if(i&&!this.mouseTrail){var r=J(i,"."+_E+"."+J0+"."+VE);r?E.add(r,"mouseleave",this.tooltipElementMouseOut,this):(this.hideTooltip(this.animation.close,e,this.findTarget()),0===this.closeDelay&&("None"===this.animation.close.effect||this.isReact&&"string"!=typeof this.content)&&this.clear())}else this.hideTooltip(this.animation.close,e,this.findTarget()),this.clear();this.popupObj&&!this.popupObj.element.classList.contains($g)&&this.clear()},t.prototype.tooltipElementMouseOut=function(e){this.hideTooltip(this.animation.close,e,this.findTarget()),E.remove(this.element,"mouseleave",this.tooltipElementMouseOut),this.clear()},t.prototype.onStickyClose=function(){this.close()},t.prototype.onMouseMove=function(e){var i=0,r=0;e.type.indexOf("touch")>-1?(e.preventDefault(),i=e.touches[0].pageX,r=e.touches[0].pageY):(i=e.pageX,r=e.pageY),Hs.stop(this.tooltipEle),K([this.tooltipEle],WE),V([this.tooltipEle],$g),this.adjustArrow(e.target,this.position,this.tooltipPositionX,this.tooltipPositionY);var s=this.getScalingFactor(e.target),o=this.calculateTooltipOffset(this.position,s.x,s.y),h=this.checkCollision(e.target,i+o.left+this.offsetX,r+o.top+this.offsetY);if(this.tooltipPositionX!==h.horizontal||this.tooltipPositionY!==h.vertical){var c=0===this.position.indexOf("Bottom")||0===this.position.indexOf("Top")?h.vertical+h.horizontal:h.horizontal+h.vertical;h.position=c,this.adjustArrow(e.target,h.position,h.horizontal,h.vertical);var d=this.calculateTooltipOffset(h.position,s.x,s.y);h.left=i+d.left-this.offsetX,h.top=r+d.top-this.offsetY}this.tooltipEle.style.left=h.left+"px",this.tooltipEle.style.top=h.top+"px"},t.prototype.keyDown=function(e){this.tooltipEle&&27===e.keyCode&&this.close()},t.prototype.touchEnd=function(e){this.tooltipEle&&null===J(e.target,"."+FE)&&!this.isSticky&&this.close()},t.prototype.scrollHandler=function(e){this.tooltipEle&&!this.isSticky&&!J(e.target,"."+_E+"."+J0+"."+VE)&&!this.isSticky&&this.close()},t.prototype.render=function(){this.initialize(),this.wireEvents(this.opensOn),this.renderComplete()},t.prototype.preRender=function(){this.tipClass=qg,this.tooltipPositionX="Center",this.tooltipPositionY="Top",this.isHidden=!0},t.prototype.wireEvents=function(e){for(var r=0,s=this.getTriggerList(e);r0)for(var i=0,r=e;i0)for(var i=0,r=e;i0&&this.condition&&-1!==this.condition.indexOf("not")&&(e[s].condition=e[s].condition?e[s].condition+"not":"not"),i=e[s].validate(t),r){if(!i)return!1}else if(i)return!0;return r},n.prototype.toJson=function(){var t,e;if(this.isComplex){t=[],e=this.predicates;for(var i=0;ie.length-3?(e=e.substring(0,e.length-1),n.endsWith(n.toLowerCase(t),n.toLowerCase(e))):(e.lastIndexOf("%")!==e.indexOf("%")&&e.lastIndexOf("%")>e.indexOf("%")+1&&(e=e.substring(e.indexOf("%")+1,e.lastIndexOf("%"))),-1!==t.indexOf(e)))},n.fnSort=function(t){return"ascending"===(t=t?n.toLowerCase(t):"ascending")?this.fnAscending:this.fnDescending},n.fnAscending=function(t,e){return m(t)&&m(e)||null==e?-1:"string"==typeof t?t.localeCompare(e):null==t?1:t-e},n.fnDescending=function(t,e){return m(t)&&m(e)?-1:null==e?1:"string"==typeof t?-1*t.localeCompare(e):null==t?-1:e-t},n.extractFields=function(t,e){for(var i={},r=0;r0||e.length>0;)o=t.length>0&&e.length>0?r?r(this.getVal(t,0,i),this.getVal(e,0,i),t[0],e[0])<=0?t:e:t[0][i]0?t:e,s.push(o.shift());return s},n.getVal=function(t,e,i){return i?this.getObject(i,t[e]):t[e]},n.toLowerCase=function(t){return t?"string"==typeof t?t.toLowerCase():t.toString():0===t||!1===t?t.toString():""},n.callAdaptorFunction=function(t,e,i,r){if(e in t){var s=t[e](i,r);m(s)||(i=s)}return i},n.getAddParams=function(t,e,i){var r={};return n.callAdaptorFunction(t,"addParams",{dm:e,query:i,params:i?i.params:[],reqParams:r}),r},n.isPlainObject=function(t){return!!t&&t.constructor===Object},n.isCors=function(){var t=null;try{t=new window.XMLHttpRequest}catch{}return!!t&&"withCredentials"in t},n.getGuid=function(t){var i;return(t||"")+"00000000-0000-4000-0000-000000000000".replace(/0/g,function(r,s){if("crypto"in window&&"getRandomValues"in crypto){var o=new Uint8Array(1);window.crypto.getRandomValues(o),i=o[0]%16|0}else i=16*Math.random()|0;return"0123456789abcdef"[19===s?3&i|8:i]})},n.isNull=function(t){return null==t},n.getItemFromComparer=function(t,e,i){var r,s,o,a=0,l="string"==typeof n.getVal(t,0,e);if(t.length)for(;m(r)&&a0&&(r=s,o=t[a]));return o},n.distinct=function(t,e,i){i=!m(i)&&i;var s,r=[],o={};return t.forEach(function(a,l){(s="object"==typeof t[l]?n.getVal(t,l,e):t[l])in o||(r.push(i?t[l]:s),o[s]=1)}),r},n.processData=function(t,e){var i=this.prepareQuery(t),r=new nt(e);t.requiresCounts&&i.requiresCount();var s=r.executeLocal(i),o={result:t.requiresCounts?s.result:s,count:s.count,aggregates:JSON.stringify(s.aggregates)};return t.requiresCounts?o:s},n.prepareQuery=function(t){var e=this,i=new jt;return t.select&&i.select(t.select),t.where&&n.parse.parseJson(t.where).filter(function(o){if(m(o.condition))i.where(o.field,o.operator,o.value,o.ignoreCase,o.ignoreAccent);else{var a=[];o.field?a.push(new Ss(o.field,o.operator,o.value,o.ignoreCase,o.ignoreAccent)):a=a.concat(e.getPredicate(o.predicates)),"or"===o.condition?i.where(Ss.or(a)):"and"===o.condition&&i.where(Ss.and(a))}}),t.search&&n.parse.parseJson(t.search).filter(function(o){return i.search(o.key,o.fields,o.operator,o.ignoreCase,o.ignoreAccent)}),t.aggregates&&t.aggregates.filter(function(o){return i.aggregate(o.type,o.field)}),t.sorted&&t.sorted.filter(function(o){return i.sortBy(o.name,o.direction)}),t.skip&&i.skip(t.skip),t.take&&i.take(t.take),t.group&&t.group.filter(function(o){return i.group(o)}),i},n.getPredicate=function(t){for(var e=[],i=0;i":"greaterthan","<=":"lessthanorequal",">=":"greaterthanorequal","==":"equal","!=":"notequal","*=":"contains","$=":"endswith","^=":"startswith"},n.odBiOperator={"<":" lt ",">":" gt ","<=":" le ",">=":" ge ","==":" eq ","!=":" ne ",lessthan:" lt ",lessthanorequal:" le ",greaterthan:" gt ",greaterthanorequal:" ge ",equal:" eq ",notequal:" ne "},n.odUniOperator={"$=":"endswith","^=":"startswith","*=":"substringof",endswith:"endswith",startswith:"startswith",contains:"substringof",doesnotendwith:"not endswith",doesnotstartwith:"not startswith",doesnotcontain:"not substringof",wildcard:"wildcard",like:"like"},n.odv4UniOperator={"$=":"endswith","^=":"startswith","*=":"contains",endswith:"endswith",startswith:"startswith",contains:"contains",doesnotendwith:"not endswith",doesnotstartwith:"not startswith",doesnotcontain:"not contains",wildcard:"wildcard",like:"like"},n.diacritics={"\u24b6":"A",\uff21:"A",\u00c0:"A",\u00c1:"A",\u00c2:"A",\u1ea6:"A",\u1ea4:"A",\u1eaa:"A",\u1ea8:"A",\u00c3:"A",\u0100:"A",\u0102:"A",\u1eb0:"A",\u1eae:"A",\u1eb4:"A",\u1eb2:"A",\u0226:"A",\u01e0:"A",\u00c4:"A",\u01de:"A",\u1ea2:"A",\u00c5:"A",\u01fa:"A",\u01cd:"A",\u0200:"A",\u0202:"A",\u1ea0:"A",\u1eac:"A",\u1eb6:"A",\u1e00:"A",\u0104:"A",\u023a:"A",\u2c6f:"A",\ua732:"AA",\u00c6:"AE",\u01fc:"AE",\u01e2:"AE",\ua734:"AO",\ua736:"AU",\ua738:"AV",\ua73a:"AV",\ua73c:"AY","\u24b7":"B",\uff22:"B",\u1e02:"B",\u1e04:"B",\u1e06:"B",\u0243:"B",\u0182:"B",\u0181:"B","\u24b8":"C",\uff23:"C",\u0106:"C",\u0108:"C",\u010a:"C",\u010c:"C",\u00c7:"C",\u1e08:"C",\u0187:"C",\u023b:"C",\ua73e:"C","\u24b9":"D",\uff24:"D",\u1e0a:"D",\u010e:"D",\u1e0c:"D",\u1e10:"D",\u1e12:"D",\u1e0e:"D",\u0110:"D",\u018b:"D",\u018a:"D",\u0189:"D",\ua779:"D",\u01f1:"DZ",\u01c4:"DZ",\u01f2:"Dz",\u01c5:"Dz","\u24ba":"E",\uff25:"E",\u00c8:"E",\u00c9:"E",\u00ca:"E",\u1ec0:"E",\u1ebe:"E",\u1ec4:"E",\u1ec2:"E",\u1ebc:"E",\u0112:"E",\u1e14:"E",\u1e16:"E",\u0114:"E",\u0116:"E",\u00cb:"E",\u1eba:"E",\u011a:"E",\u0204:"E",\u0206:"E",\u1eb8:"E",\u1ec6:"E",\u0228:"E",\u1e1c:"E",\u0118:"E",\u1e18:"E",\u1e1a:"E",\u0190:"E",\u018e:"E","\u24bb":"F",\uff26:"F",\u1e1e:"F",\u0191:"F",\ua77b:"F","\u24bc":"G",\uff27:"G",\u01f4:"G",\u011c:"G",\u1e20:"G",\u011e:"G",\u0120:"G",\u01e6:"G",\u0122:"G",\u01e4:"G",\u0193:"G",\ua7a0:"G",\ua77d:"G",\ua77e:"G","\u24bd":"H",\uff28:"H",\u0124:"H",\u1e22:"H",\u1e26:"H",\u021e:"H",\u1e24:"H",\u1e28:"H",\u1e2a:"H",\u0126:"H",\u2c67:"H",\u2c75:"H",\ua78d:"H","\u24be":"I",\uff29:"I",\u00cc:"I",\u00cd:"I",\u00ce:"I",\u0128:"I",\u012a:"I",\u012c:"I",\u0130:"I",\u00cf:"I",\u1e2e:"I",\u1ec8:"I",\u01cf:"I",\u0208:"I",\u020a:"I",\u1eca:"I",\u012e:"I",\u1e2c:"I",\u0197:"I","\u24bf":"J",\uff2a:"J",\u0134:"J",\u0248:"J","\u24c0":"K",\uff2b:"K",\u1e30:"K",\u01e8:"K",\u1e32:"K",\u0136:"K",\u1e34:"K",\u0198:"K",\u2c69:"K",\ua740:"K",\ua742:"K",\ua744:"K",\ua7a2:"K","\u24c1":"L",\uff2c:"L",\u013f:"L",\u0139:"L",\u013d:"L",\u1e36:"L",\u1e38:"L",\u013b:"L",\u1e3c:"L",\u1e3a:"L",\u0141:"L",\u023d:"L",\u2c62:"L",\u2c60:"L",\ua748:"L",\ua746:"L",\ua780:"L",\u01c7:"LJ",\u01c8:"Lj","\u24c2":"M",\uff2d:"M",\u1e3e:"M",\u1e40:"M",\u1e42:"M",\u2c6e:"M",\u019c:"M","\u24c3":"N",\uff2e:"N",\u01f8:"N",\u0143:"N",\u00d1:"N",\u1e44:"N",\u0147:"N",\u1e46:"N",\u0145:"N",\u1e4a:"N",\u1e48:"N",\u0220:"N",\u019d:"N",\ua790:"N",\ua7a4:"N",\u01ca:"NJ",\u01cb:"Nj","\u24c4":"O",\uff2f:"O",\u00d2:"O",\u00d3:"O",\u00d4:"O",\u1ed2:"O",\u1ed0:"O",\u1ed6:"O",\u1ed4:"O",\u00d5:"O",\u1e4c:"O",\u022c:"O",\u1e4e:"O",\u014c:"O",\u1e50:"O",\u1e52:"O",\u014e:"O",\u022e:"O",\u0230:"O",\u00d6:"O",\u022a:"O",\u1ece:"O",\u0150:"O",\u01d1:"O",\u020c:"O",\u020e:"O",\u01a0:"O",\u1edc:"O",\u1eda:"O",\u1ee0:"O",\u1ede:"O",\u1ee2:"O",\u1ecc:"O",\u1ed8:"O",\u01ea:"O",\u01ec:"O",\u00d8:"O",\u01fe:"O",\u0186:"O",\u019f:"O",\ua74a:"O",\ua74c:"O",\u01a2:"OI",\ua74e:"OO",\u0222:"OU","\u24c5":"P",\uff30:"P",\u1e54:"P",\u1e56:"P",\u01a4:"P",\u2c63:"P",\ua750:"P",\ua752:"P",\ua754:"P","\u24c6":"Q",\uff31:"Q",\ua756:"Q",\ua758:"Q",\u024a:"Q","\u24c7":"R",\uff32:"R",\u0154:"R",\u1e58:"R",\u0158:"R",\u0210:"R",\u0212:"R",\u1e5a:"R",\u1e5c:"R",\u0156:"R",\u1e5e:"R",\u024c:"R",\u2c64:"R",\ua75a:"R",\ua7a6:"R",\ua782:"R","\u24c8":"S",\uff33:"S",\u1e9e:"S",\u015a:"S",\u1e64:"S",\u015c:"S",\u1e60:"S",\u0160:"S",\u1e66:"S",\u1e62:"S",\u1e68:"S",\u0218:"S",\u015e:"S",\u2c7e:"S",\ua7a8:"S",\ua784:"S","\u24c9":"T",\uff34:"T",\u1e6a:"T",\u0164:"T",\u1e6c:"T",\u021a:"T",\u0162:"T",\u1e70:"T",\u1e6e:"T",\u0166:"T",\u01ac:"T",\u01ae:"T",\u023e:"T",\ua786:"T",\ua728:"TZ","\u24ca":"U",\uff35:"U",\u00d9:"U",\u00da:"U",\u00db:"U",\u0168:"U",\u1e78:"U",\u016a:"U",\u1e7a:"U",\u016c:"U",\u00dc:"U",\u01db:"U",\u01d7:"U",\u01d5:"U",\u01d9:"U",\u1ee6:"U",\u016e:"U",\u0170:"U",\u01d3:"U",\u0214:"U",\u0216:"U",\u01af:"U",\u1eea:"U",\u1ee8:"U",\u1eee:"U",\u1eec:"U",\u1ef0:"U",\u1ee4:"U",\u1e72:"U",\u0172:"U",\u1e76:"U",\u1e74:"U",\u0244:"U","\u24cb":"V",\uff36:"V",\u1e7c:"V",\u1e7e:"V",\u01b2:"V",\ua75e:"V",\u0245:"V",\ua760:"VY","\u24cc":"W",\uff37:"W",\u1e80:"W",\u1e82:"W",\u0174:"W",\u1e86:"W",\u1e84:"W",\u1e88:"W",\u2c72:"W","\u24cd":"X",\uff38:"X",\u1e8a:"X",\u1e8c:"X","\u24ce":"Y",\uff39:"Y",\u1ef2:"Y",\u00dd:"Y",\u0176:"Y",\u1ef8:"Y",\u0232:"Y",\u1e8e:"Y",\u0178:"Y",\u1ef6:"Y",\u1ef4:"Y",\u01b3:"Y",\u024e:"Y",\u1efe:"Y","\u24cf":"Z",\uff3a:"Z",\u0179:"Z",\u1e90:"Z",\u017b:"Z",\u017d:"Z",\u1e92:"Z",\u1e94:"Z",\u01b5:"Z",\u0224:"Z",\u2c7f:"Z",\u2c6b:"Z",\ua762:"Z","\u24d0":"a",\uff41:"a",\u1e9a:"a",\u00e0:"a",\u00e1:"a",\u00e2:"a",\u1ea7:"a",\u1ea5:"a",\u1eab:"a",\u1ea9:"a",\u00e3:"a",\u0101:"a",\u0103:"a",\u1eb1:"a",\u1eaf:"a",\u1eb5:"a",\u1eb3:"a",\u0227:"a",\u01e1:"a",\u00e4:"a",\u01df:"a",\u1ea3:"a",\u00e5:"a",\u01fb:"a",\u01ce:"a",\u0201:"a",\u0203:"a",\u1ea1:"a",\u1ead:"a",\u1eb7:"a",\u1e01:"a",\u0105:"a",\u2c65:"a",\u0250:"a",\ua733:"aa",\u00e6:"ae",\u01fd:"ae",\u01e3:"ae",\ua735:"ao",\ua737:"au",\ua739:"av",\ua73b:"av",\ua73d:"ay","\u24d1":"b",\uff42:"b",\u1e03:"b",\u1e05:"b",\u1e07:"b",\u0180:"b",\u0183:"b",\u0253:"b","\u24d2":"c",\uff43:"c",\u0107:"c",\u0109:"c",\u010b:"c",\u010d:"c",\u00e7:"c",\u1e09:"c",\u0188:"c",\u023c:"c",\ua73f:"c",\u2184:"c","\u24d3":"d",\uff44:"d",\u1e0b:"d",\u010f:"d",\u1e0d:"d",\u1e11:"d",\u1e13:"d",\u1e0f:"d",\u0111:"d",\u018c:"d",\u0256:"d",\u0257:"d",\ua77a:"d",\u01f3:"dz",\u01c6:"dz","\u24d4":"e",\uff45:"e",\u00e8:"e",\u00e9:"e",\u00ea:"e",\u1ec1:"e",\u1ebf:"e",\u1ec5:"e",\u1ec3:"e",\u1ebd:"e",\u0113:"e",\u1e15:"e",\u1e17:"e",\u0115:"e",\u0117:"e",\u00eb:"e",\u1ebb:"e",\u011b:"e",\u0205:"e",\u0207:"e",\u1eb9:"e",\u1ec7:"e",\u0229:"e",\u1e1d:"e",\u0119:"e",\u1e19:"e",\u1e1b:"e",\u0247:"e",\u025b:"e",\u01dd:"e","\u24d5":"f",\uff46:"f",\u1e1f:"f",\u0192:"f",\ua77c:"f","\u24d6":"g",\uff47:"g",\u01f5:"g",\u011d:"g",\u1e21:"g",\u011f:"g",\u0121:"g",\u01e7:"g",\u0123:"g",\u01e5:"g",\u0260:"g",\ua7a1:"g",\u1d79:"g",\ua77f:"g","\u24d7":"h",\uff48:"h",\u0125:"h",\u1e23:"h",\u1e27:"h",\u021f:"h",\u1e25:"h",\u1e29:"h",\u1e2b:"h",\u1e96:"h",\u0127:"h",\u2c68:"h",\u2c76:"h",\u0265:"h",\u0195:"hv","\u24d8":"i",\uff49:"i",\u00ec:"i",\u00ed:"i",\u00ee:"i",\u0129:"i",\u012b:"i",\u012d:"i",\u00ef:"i",\u1e2f:"i",\u1ec9:"i",\u01d0:"i",\u0209:"i",\u020b:"i",\u1ecb:"i",\u012f:"i",\u1e2d:"i",\u0268:"i",\u0131:"i","\u24d9":"j",\uff4a:"j",\u0135:"j",\u01f0:"j",\u0249:"j","\u24da":"k",\uff4b:"k",\u1e31:"k",\u01e9:"k",\u1e33:"k",\u0137:"k",\u1e35:"k",\u0199:"k",\u2c6a:"k",\ua741:"k",\ua743:"k",\ua745:"k",\ua7a3:"k","\u24db":"l",\uff4c:"l",\u0140:"l",\u013a:"l",\u013e:"l",\u1e37:"l",\u1e39:"l",\u013c:"l",\u1e3d:"l",\u1e3b:"l",\u017f:"l",\u0142:"l",\u019a:"l",\u026b:"l",\u2c61:"l",\ua749:"l",\ua781:"l",\ua747:"l",\u01c9:"lj","\u24dc":"m",\uff4d:"m",\u1e3f:"m",\u1e41:"m",\u1e43:"m",\u0271:"m",\u026f:"m","\u24dd":"n",\uff4e:"n",\u01f9:"n",\u0144:"n",\u00f1:"n",\u1e45:"n",\u0148:"n",\u1e47:"n",\u0146:"n",\u1e4b:"n",\u1e49:"n",\u019e:"n",\u0272:"n",\u0149:"n",\ua791:"n",\ua7a5:"n",\u01cc:"nj","\u24de":"o",\uff4f:"o",\u00f2:"o",\u00f3:"o",\u00f4:"o",\u1ed3:"o",\u1ed1:"o",\u1ed7:"o",\u1ed5:"o",\u00f5:"o",\u1e4d:"o",\u022d:"o",\u1e4f:"o",\u014d:"o",\u1e51:"o",\u1e53:"o",\u014f:"o",\u022f:"o",\u0231:"o",\u00f6:"o",\u022b:"o",\u1ecf:"o",\u0151:"o",\u01d2:"o",\u020d:"o",\u020f:"o",\u01a1:"o",\u1edd:"o",\u1edb:"o",\u1ee1:"o",\u1edf:"o",\u1ee3:"o",\u1ecd:"o",\u1ed9:"o",\u01eb:"o",\u01ed:"o",\u00f8:"o",\u01ff:"o",\u0254:"o",\ua74b:"o",\ua74d:"o",\u0275:"o",\u01a3:"oi",\u0223:"ou",\ua74f:"oo","\u24df":"p",\uff50:"p",\u1e55:"p",\u1e57:"p",\u01a5:"p",\u1d7d:"p",\ua751:"p",\ua753:"p",\ua755:"p","\u24e0":"q",\uff51:"q",\u024b:"q",\ua757:"q",\ua759:"q","\u24e1":"r",\uff52:"r",\u0155:"r",\u1e59:"r",\u0159:"r",\u0211:"r",\u0213:"r",\u1e5b:"r",\u1e5d:"r",\u0157:"r",\u1e5f:"r",\u024d:"r",\u027d:"r",\ua75b:"r",\ua7a7:"r",\ua783:"r","\u24e2":"s",\uff53:"s",\u00df:"s",\u015b:"s",\u1e65:"s",\u015d:"s",\u1e61:"s",\u0161:"s",\u1e67:"s",\u1e63:"s",\u1e69:"s",\u0219:"s",\u015f:"s",\u023f:"s",\ua7a9:"s",\ua785:"s",\u1e9b:"s","\u24e3":"t",\uff54:"t",\u1e6b:"t",\u1e97:"t",\u0165:"t",\u1e6d:"t",\u021b:"t",\u0163:"t",\u1e71:"t",\u1e6f:"t",\u0167:"t",\u01ad:"t",\u0288:"t",\u2c66:"t",\ua787:"t",\ua729:"tz","\u24e4":"u",\uff55:"u",\u00f9:"u",\u00fa:"u",\u00fb:"u",\u0169:"u",\u1e79:"u",\u016b:"u",\u1e7b:"u",\u016d:"u",\u00fc:"u",\u01dc:"u",\u01d8:"u",\u01d6:"u",\u01da:"u",\u1ee7:"u",\u016f:"u",\u0171:"u",\u01d4:"u",\u0215:"u",\u0217:"u",\u01b0:"u",\u1eeb:"u",\u1ee9:"u",\u1eef:"u",\u1eed:"u",\u1ef1:"u",\u1ee5:"u",\u1e73:"u",\u0173:"u",\u1e77:"u",\u1e75:"u",\u0289:"u","\u24e5":"v",\uff56:"v",\u1e7d:"v",\u1e7f:"v",\u028b:"v",\ua75f:"v",\u028c:"v",\ua761:"vy","\u24e6":"w",\uff57:"w",\u1e81:"w",\u1e83:"w",\u0175:"w",\u1e87:"w",\u1e85:"w",\u1e98:"w",\u1e89:"w",\u2c73:"w","\u24e7":"x",\uff58:"x",\u1e8b:"x",\u1e8d:"x","\u24e8":"y",\uff59:"y",\u1ef3:"y",\u00fd:"y",\u0177:"y",\u1ef9:"y",\u0233:"y",\u1e8f:"y",\u00ff:"y",\u1ef7:"y",\u1e99:"y",\u1ef5:"y",\u01b4:"y",\u024f:"y",\u1eff:"y","\u24e9":"z",\uff5a:"z",\u017a:"z",\u1e91:"z",\u017c:"z",\u017e:"z",\u1e93:"z",\u1e95:"z",\u01b6:"z",\u0225:"z",\u0240:"z",\u2c6c:"z",\ua763:"z",\u0386:"\u0391",\u0388:"\u0395",\u0389:"\u0397",\u038a:"\u0399",\u03aa:"\u0399",\u038c:"\u039f",\u038e:"\u03a5",\u03ab:"\u03a5",\u038f:"\u03a9",\u03ac:"\u03b1",\u03ad:"\u03b5",\u03ae:"\u03b7",\u03af:"\u03b9",\u03ca:"\u03b9",\u0390:"\u03b9",\u03cc:"\u03bf",\u03cd:"\u03c5",\u03cb:"\u03c5",\u03b0:"\u03c5",\u03c9:"\u03c9",\u03c2:"\u03c3"},n.fnOperators={equal:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?n.toLowerCase(t)===n.toLowerCase(e):t===e},notequal:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),!n.fnOperators.equal(t,e,i)},lessthan:function(t,e,i){return i?n.toLowerCase(t)n.toLowerCase(e):t>e},lessthanorequal:function(t,e,i){return i?n.toLowerCase(t)<=n.toLowerCase(e):(m(t)&&(t=void 0),t<=e)},greaterthanorequal:function(t,e,i){return i?n.toLowerCase(t)>=n.toLowerCase(e):t>=e},contains:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?!m(t)&&!m(e)&&-1!==n.toLowerCase(t).indexOf(n.toLowerCase(e)):!m(t)&&!m(e)&&-1!==t.toString().indexOf(e)},doesnotcontain:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?!m(t)&&!m(e)&&-1===n.toLowerCase(t).indexOf(n.toLowerCase(e)):!m(t)&&!m(e)&&-1===t.toString().indexOf(e)},isnotnull:function(t){return null!=t},isnull:function(t){return null==t},startswith:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.startsWith(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.startsWith(t,e)},doesnotstartwith:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.notStartsWith(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.notStartsWith(t,e)},like:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.like(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.like(t,e)},isempty:function(t){return void 0===t||""===t},isnotempty:function(t){return void 0!==t&&""!==t},wildcard:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?(t||"boolean"==typeof t)&&e&&"object"!=typeof t&&n.wildCard(n.toLowerCase(t),n.toLowerCase(e)):(t||"boolean"==typeof t)&&e&&n.wildCard(t,e)},endswith:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.endsWith(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.endsWith(t,e)},doesnotendwith:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.notEndsWith(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.notEndsWith(t,e)},processSymbols:function(t){var e=n.operatorSymbols[t];return e?n.fnOperators[e]:n.throwError("Query - Process Operator : Invalid operator")},processOperator:function(t){return n.fnOperators[t]||n.fnOperators.processSymbols(t)}},n.parse={parseJson:function(t){return"string"!=typeof t||!/^[\s]*\[|^[\s]*\{(.)+:/g.test(t)&&-1!==t.indexOf('"')?t instanceof Array?n.parse.iterateAndReviveArray(t):"object"==typeof t&&null!==t&&n.parse.iterateAndReviveJson(t):t=JSON.parse(t,n.parse.jsonReviver),t},iterateAndReviveArray:function(t){for(var e=0;e-1||e.indexOf("z")>-1,o=e.split(/[^0-9.]/);if(s){if(o[5].indexOf(".")>-1){var a=o[5].split(".");o[5]=a[0],o[6]=new Date(e).getUTCMilliseconds().toString()}else o[6]="00";e=n.dateParse.toTimeZone(new Date(parseInt(o[0],10),parseInt(o[1],10)-1,parseInt(o[2],10),parseInt(o[3],10),parseInt(o[4],10),parseInt(o[5]?o[5]:"00",10),parseInt(o[6],10)),n.serverTimezoneOffset,!1)}else{var l=new Date(parseInt(o[0],10),parseInt(o[1],10)-1,parseInt(o[2],10),parseInt(o[3],10),parseInt(o[4],10),parseInt(o[5]?o[5]:"00",10)),h=parseInt(o[6],10),c=parseInt(o[7],10);if(isNaN(h)&&isNaN(c))return l;e.indexOf("+")>-1?l.setHours(l.getHours()-h,l.getMinutes()-c):l.setHours(l.getHours()+h,l.getMinutes()+c),e=n.dateParse.toTimeZone(l,n.serverTimezoneOffset,!1)}null==n.serverTimezoneOffset&&(e=n.dateParse.addSelfOffset(e))}}return e},isJson:function(t){return"string"==typeof t[0]?t:n.parse.parseJson(t)},isGuid:function(t){return null!=/[A-Fa-f0-9]{8}(?:-[A-Fa-f0-9]{4}){3}-[A-Fa-f0-9]{12}/i.exec(t)},replacer:function(t,e){return n.isPlainObject(t)?n.parse.jsonReplacer(t,e):t instanceof Array?n.parse.arrayReplacer(t):t instanceof Date?n.parse.jsonReplacer({val:t},e).val:t},jsonReplacer:function(t,e){for(var i,s=0,o=Object.keys(t);s=0?"+":"-",s=function(a){var l=Math.floor(Math.abs(a));return(l<10?"0":"")+l};return e.getFullYear()+"-"+s(e.getMonth()+1)+"-"+s(e.getDate())+"T"+s(e.getHours())+":"+s(e.getMinutes())+":"+s(e.getSeconds())+r+s(i/60)+":"+s(i%60)}},n}(),Ml=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),BK={GroupGuid:"{271bbba0-1ee7}"},a5=function(){function n(t){this.options={from:"table",requestType:"json",sortBy:"sorted",select:"select",skip:"skip",group:"group",take:"take",search:"search",count:"requiresCounts",where:"where",aggregates:"aggregates",expand:"expand"},this.type=n,this.dataSource=t,this.pvt={}}return n.prototype.processResponse=function(t,e,i,r){return t},n}(),GE=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ml(t,n),t.prototype.processQuery=function(e,i){for(var a,l,p,r=e.dataSource.json.slice(0),s=r.length,o=!0,h={},c=0,d=[],u=[],f=0;f1?e.sort.filter(function(p){return p.fieldName===c})[0]:e.sort[0];s=this.onSortBy(s,d,e.query,!0)}e.page&&(s=this.onPage(s,e.page,e.query)),this.formGroupResult(s,h)}else{for(var o=e.lazyLoad.onDemandGroupInfo,a=o.where.length-1;a>=0;a--)s=this.onWhere(s,o.where[a]);if(e.group.length!==o.level)s=le.group(s,e.group[o.level].fieldName,r,null,null,e.group[o.level].comparer,!0),e.sort.length&&(s=this.onSortBy(s,e.sort[parseInt(o.level.toString(),10)],e.query,!0));else for(a=e.sort.length-1;a>=o.level;a--)s=this.onSortBy(s,e.sort[parseInt(a.toString(),10)],e.query,!1);i=s.length,h=s,s=(s=s.slice(o.skip)).slice(0,o.take),e.group.length!==o.level&&this.formGroupResult(s,h)}return{result:s,count:i}},t.prototype.formGroupResult=function(e,i){if(e.length&&i.length){var r="GroupGuid",s="childLevels",o="level",a="records";e[r]=i[r],e[s]=i[s],e[o]=i[o],e[a]=i[a]}return e},t.prototype.getAggregate=function(e){var i=jt.filterQueries(e.queries,"onAggregates"),r=[];if(i.length)for(var s=void 0,o=0;o=0;l--)a[l]&&(o=i.comparer,le.endsWith(a[l]," desc")&&(o=le.fnSort("descending"),a[l]=a[l].replace(" desc","")),e=le.sort(e,a[l],o));return e}return le.sort(e,s?"key":a,i.comparer)},t.prototype.onGroup=function(e,i,r){if(!e||!e.length)return e;var s=this.getAggregate(r);return le.group(e,le.getValue(i.fieldName,r),s,null,null,i.comparer)},t.prototype.onPage=function(e,i,r){var s=le.getValue(i.pageSize,r),o=(le.getValue(i.pageIndex,r)-1)*s;return e&&e.length?e.slice(o,o+s):e},t.prototype.onRange=function(e,i){return e&&e.length?e.slice(le.getValue(i.start),le.getValue(i.end)):e},t.prototype.onTake=function(e,i){return e&&e.length?e.slice(0,le.getValue(i.nos)):e},t.prototype.onSkip=function(e,i){return e&&e.length?e.slice(le.getValue(i.nos)):e},t.prototype.onSelect=function(e,i){return e&&e.length?le.select(e,le.getValue(i.fieldNames)):e},t.prototype.insert=function(e,i,r,s,o){return m(o)?e.dataSource.json.push(i):e.dataSource.json.splice(o,0,i)},t.prototype.remove=function(e,i,r,s){var a,o=e.dataSource.json;for("object"==typeof r&&!(r instanceof Date)&&(r=le.getObject(i,r)),a=0;a1&&(g="("+g+")"),p.filters.push(g);for(var y=0,S="object"==typeof p.filters[f]?Object.keys(p.filters[f]):[];y-1&&this.formRemoteGroupedData(e[s].items,i+1,r-1);var o="GroupGuid",h="records";return e[o]=BK[o],e.level=i,e.childLevels=r,e[h]=e[0].items.length?this.getGroupedRecords(e,!m(e[0].items[h])):[],e},t.prototype.getGroupedRecords=function(e,i){for(var r=[],o=0;ol.length-3?(l=l.substring(0,l.length-1),o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.endswith:le.odv4UniOperator.endswith):l.lastIndexOf("%")!==l.indexOf("%")&&l.lastIndexOf("%")>l.indexOf("%")+1?(l=l.substring(l.indexOf("%")+1,l.lastIndexOf("%")),o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains):o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains),l="'"+(l=encodeURIComponent(l))+"'";else if("wildcard"===o)if(-1!==l.indexOf("*")){var d=l.split("*"),u=void 0,p=0;if(0!==l.indexOf("*")&&-1===d[0].indexOf("%3f")&&-1===d[0].indexOf("?")&&(u="'"+(u=d[0])+"'",s+=(o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.startswith:le.odv4UniOperator.startswith)+"(",s+=c+",",a&&(s+=a),s+=u+")",p++),l.lastIndexOf("*")!==l.length-1&&-1===d[d.length-1].indexOf("%3f")&&-1===d[d.length-1].indexOf("?")&&(u="'"+(u=d[d.length-1])+"'",p>0&&(s+=" and "),s+=(o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.endswith:le.odv4UniOperator.endswith)+"(",s+=c+",",a&&(s+=a),s+=u+")",p++),d.length>2)for(var f=1;f0&&(s+=" and "),"substringof"===(o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains)||"not substringof"===o){var g=u;u=c,c=g}s+=o+"(",s+=c+",",a&&(s+=a),s+=u+")",p++}0===p?(o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains,(-1!==l.indexOf("?")||-1!==l.indexOf("%3f"))&&(l=-1!==l.indexOf("?")?l.split("?").join(""):l.split("%3f").join("")),l="'"+l+"'"):o="wildcard"}else o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains,(-1!==l.indexOf("?")||-1!==l.indexOf("%3f"))&&(l=-1!==l.indexOf("?")?l.split("?").join(""):l.split("%3f").join("")),l="'"+l+"'";return"substringof"!==o&&"not substringof"!==o||(g=l,l=c,c=g),"wildcard"!==o&&(s+=o+"(",s+=c+",",a&&(s+=a),s+=l+")"),s},t.prototype.addParams=function(e){n.prototype.addParams.call(this,e),delete e.reqParams.params},t.prototype.onComplexPredicate=function(e,i,r){for(var s=[],o=0;o-1;p--)!/\bContent-ID:/i.test(c[p])||!/\bHTTP.+201/.test(c[p])||(l=parseInt(/\bContent-ID: (\d+)/i.exec(c[p])[1],10),o.addedRecords[l]&&(h=le.parse.parseJson(/^\{.+\}/m.exec(c[p])[0]),ze({},o.addedRecords[l],this.processResponse(h))));return o}return null},t.prototype.compareAndRemove=function(e,i,r){var s=this;return m(i)||Object.keys(e).forEach(function(o){o!==r&&"@odata.etag"!==o&&(le.isPlainObject(e[o])?(s.compareAndRemove(e[o],i[o]),0===Object.keys(e[o]).filter(function(l){return"@odata.etag"!==l}).length&&delete e[o]):(e[o]===i[o]||e[o]&&i[o]&&e[o].valueOf()===i[o].valueOf())&&delete e[o])}),e},t}(fc),FK=function(n){function t(){var e=n.call(this)||this;return yt("beforeSend",fc.prototype.beforeSend,e),e}return Ml(t,n),t.prototype.insert=function(e,i,r,s,o){return this.pvt.position=o,this.updateType="add",{url:e.dataSource.insertUrl||e.dataSource.crudUrl||e.dataSource.url,data:JSON.stringify(ze({},{value:i,table:r,action:"insert"},le.getAddParams(this,e,s)))}},t.prototype.remove=function(e,i,r,s,o){return n.prototype.remove.call(this,e,i,r),{type:"POST",url:e.dataSource.removeUrl||e.dataSource.crudUrl||e.dataSource.url,data:JSON.stringify(ze({},{key:r,keyColumn:i,table:s,action:"remove"},le.getAddParams(this,e,o)))}},t.prototype.update=function(e,i,r,s,o){return this.updateType="update",this.updateKey=i,{type:"POST",url:e.dataSource.updateUrl||e.dataSource.crudUrl||e.dataSource.url,data:JSON.stringify(ze({},{value:r,action:"update",keyColumn:i,key:r[i],table:s},le.getAddParams(this,e,o)))}},t.prototype.processResponse=function(e,i,r,s,o,a,l){var h;if(e="batch"===(o?JSON.parse(o.data):e).action?le.parse.parseJson(e):e,"add"===this.updateType&&n.prototype.insert.call(this,i,e,null,null,this.pvt.position),"update"===this.updateType&&n.prototype.update.call(this,i,this.updateKey,e),this.updateType=void 0,e.added)for(h=0;hi&&h.push(c)}for(c=0;cthis.pageSize;)h.results.splice(0,1),h.keys.splice(0,1);return window.localStorage.setItem(this.guidId,JSON.stringify(h)),e},t.prototype.beforeSend=function(e,i,r){!m(this.cacheAdaptor.options.batch)&&le.endsWith(r.url,this.cacheAdaptor.options.batch)&&"post"===r.type.toLowerCase()&&i.headers.set("Accept",this.cacheAdaptor.options.multipartAccept),e.dataSource.crossDomain||i.headers.set("Accept",this.cacheAdaptor.options.accept)},t.prototype.update=function(e,i,r,s){return this.isCrudAction=!0,this.cacheAdaptor.update(e,i,r,s)},t.prototype.insert=function(e,i,r){return this.isInsertAction=!0,this.cacheAdaptor.insert(e,i,r)},t.prototype.remove=function(e,i,r,s){return this.isCrudAction=!0,this.cacheAdaptor.remove(e,i,r,s)},t.prototype.batchRequest=function(e,i,r){return this.cacheAdaptor.batchRequest(e,i,r)},t}(fc),nt=function(){function n(t,e,i){var s,r=this;return this.dateParse=!0,this.timeZoneHandling=!0,this.persistQuery={},this.isInitialLoad=!1,this.requests=[],this.isInitialLoad=!0,!t&&!this.dataSource&&(t=[]),i=i||t.adaptor,t&&!1===t.timeZoneHandling&&(this.timeZoneHandling=t.timeZoneHandling),t instanceof Array?s={json:t,offline:!0}:"object"==typeof t?(t.json||(t.json=[]),t.enablePersistence||(t.enablePersistence=!1),t.id||(t.id=""),t.ignoreOnPersist||(t.ignoreOnPersist=[]),s={url:t.url,insertUrl:t.insertUrl,removeUrl:t.removeUrl,updateUrl:t.updateUrl,crudUrl:t.crudUrl,batchUrl:t.batchUrl,json:t.json,headers:t.headers,accept:t.accept,data:t.data,timeTillExpiration:t.timeTillExpiration,cachingPageSize:t.cachingPageSize,enableCaching:t.enableCaching,requestType:t.requestType,key:t.key,crossDomain:t.crossDomain,jsonp:t.jsonp,dataType:t.dataType,offline:void 0!==t.offline?t.offline:!(t.adaptor instanceof FK||t.adaptor instanceof _K||t.url),requiresFormat:t.requiresFormat,enablePersistence:t.enablePersistence,id:t.id,ignoreOnPersist:t.ignoreOnPersist}):le.throwError("DataManager: Invalid arguments"),void 0===s.requiresFormat&&!le.isCors()&&(s.requiresFormat=!!m(s.crossDomain)||s.crossDomain),void 0===s.dataType&&(s.dataType="json"),this.dataSource=s,this.defaultQuery=e,this.dataSource.enablePersistence&&this.dataSource.id&&window.addEventListener("unload",this.setPersistData.bind(this)),s.url&&s.offline&&!s.json.length?(this.isDataAvailable=!1,this.adaptor=i||new gp,this.dataSource.offline=!1,this.ready=this.executeQuery(e||new jt),this.ready.then(function(o){r.dataSource.offline=!0,r.isDataAvailable=!0,s.json=o.result,r.adaptor=new GE})):this.adaptor=s.offline?new GE:new gp,!s.jsonp&&this.adaptor instanceof gp&&(s.jsonp="callback"),this.adaptor=i||this.adaptor,s.enableCaching&&(this.adaptor=new UK(this.adaptor,s.timeTillExpiration,s.cachingPageSize)),this}return Object.defineProperty(n.prototype,"moduleName",{get:function(){return"datamanager"},enumerable:!0,configurable:!0}),n.prototype.getPersistedData=function(t){var e=localStorage.getItem(t||this.dataSource.id);return JSON.parse(e)},n.prototype.setPersistData=function(t,e,i){localStorage.setItem(e||this.dataSource.id,JSON.stringify(i||this.persistQuery))},n.prototype.setPersistQuery=function(t){var e=this,i=this.getPersistedData();if(this.isInitialLoad&&i&&Object.keys(i).length){this.persistQuery=i,this.persistQuery.queries=this.persistQuery.queries.filter(function(s){if(e.dataSource.ignoreOnPersist&&e.dataSource.ignoreOnPersist.length&&s.fn&&e.dataSource.ignoreOnPersist.some(function(l){return s.fn===l}))return!1;if("onWhere"===s.fn){var o=s.e;if(o&&o.isComplex&&o.predicates instanceof Array){var a=o.predicates.map(function(l){if(l.predicates&&l.predicates instanceof Array){var h=l.predicates.map(function(v){return new Ss(v.field,v.operator,v.value,v.ignoreCase,v.ignoreAccent,v.matchCase)});return"and"===l.condition?Ss.and(h):Ss.or(h)}return new Ss(l.field,l.operator,l.value,l.ignoreCase,l.ignoreAccent,l.matchCase)});s.e=new Ss(a[0],o.condition,a.slice(1))}}return!0});var r=ze(new jt,this.persistQuery);return this.isInitialLoad=!1,r}return this.persistQuery=t,this.isInitialLoad=!1,t},n.prototype.setDefaultQuery=function(t){return this.defaultQuery=t,this},n.prototype.executeLocal=function(t){!this.defaultQuery&&!(t instanceof jt)&&le.throwError("DataManager - executeLocal() : A query is required to execute"),this.dataSource.json||le.throwError("DataManager - executeLocal() : Json data is required to execute"),this.dataSource.enablePersistence&&this.dataSource.id&&(t=this.setPersistQuery(t));var e=this.adaptor.processQuery(this,t=t||this.defaultQuery);if(t.subQuery){var i=t.subQuery.fromTable,r=t.subQuery.lookups,s=t.isCountRequired?e.result:e;r&&r instanceof Array&&le.buildHierarchy(t.subQuery.fKey,i,s,r,t.subQuery.key);for(var o=0;oli");P.classList.remove("json-parent");for(var j=0;j',W=ve.children[0].placeholder}return W}function Q(k,W,ve){!m(ve)&&""!==ve&&K(W,ve.split(" ")),!m(k)&&""!==k&&V(W,k.split(" "))}function oe(k,W,ve){if("multiselect"===ve||function Mo(k){if(!k)return!1;for(var W=k;W&&W!==document.body;){if("none"===window.getComputedStyle(W).display)return!1;W=W.parentElement}return!0}(k)){var Te="multiselect"===ve?k:k.clientWidth-parseInt(getComputedStyle(k,null).getPropertyValue("padding-left"),10);!m(W)&&!m(W.getElementsByClassName("e-float-text-content")[0])&&(W.getElementsByClassName("e-float-text-content")[0].classList.contains("e-float-text-overflow")&&W.getElementsByClassName("e-float-text-content")[0].classList.remove("e-float-text-overflow"),(Te0)for(var Ye=0;Ye<_e.length;Ye++)_e[parseInt(Ye.toString(),10)].addEventListener("mousedown",wo,!1),_e[parseInt(Ye.toString(),10)].addEventListener("mouseup",Hl,!1);else if(_e.length>0)for(Ye=0;Ye<_e.length;Ye++)_e[parseInt(Ye.toString(),10)].removeEventListener("mousedown",wo,this),_e[parseInt(Ye.toString(),10)].removeEventListener("mouseup",Hl,this)}function wo(){for(var W=this.parentElement;!W.classList.contains("e-input-group");)W=W.parentElement;!function ya(k,W){!k.classList.contains("e-disabled")&&!k.querySelector("input").readOnly&&W.classList.add("e-input-btn-ripple")}(W,this)}function Hl(){var k=this;setTimeout(function(){k.classList.remove("e-input-btn-ripple")},500)}function yb(k,W){var ve=W("span",{className:k});return ve.classList.add("e-input-group-icon"),ve}function I_(k,W,ve,Te){var _e=m(Te)?mi:Te,Ye=yb(k,_e);W.classList.add("e-float-icon-left");var fi=W.querySelector(".e-input-in-wrap");if(m(fi)){fi=_e("span",{className:"e-input-in-wrap"}),ve.parentNode.insertBefore(fi,ve);var Gs=W.querySelectorAll(ve.tagName+" ~ *");fi.appendChild(ve);for(var Kn=0;Kn-1)if("class"===_e){var Ye=this.getInputValidClassList(k[""+_e]);""!==Ye&&V([W],Ye.split(" "))}else if("style"===_e){var fi=W.getAttribute(_e);fi=m(fi)?k[""+_e]:fi+k[""+_e],W.setAttribute(_e,fi)}else W.setAttribute(_e,k[""+_e])}},n.isBlank=function Hle(k){return!k||/^\s*$/.test(k)}}(Le||(Le={})),new RegExp("^(-)?(\\d*)$"),new RegExp("^[A-Za-z0-9._%+-]{1,}@[A-Za-z0-9._%+-]{1,}([.]{1}[a-zA-Z0-9]{2,}|[.]{1}[a-zA-Z0-9]{2,4}[.]{1}[a-zA-Z0-9]{2,4})$"),new RegExp("^([0-9]{4})-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])$"),new RegExp("^[0-9]*$"),new RegExp("^[+]?[0-9]{9,13}$"),new RegExp("^\\d{13,16}$");var me=function(){function n(t,e){this.width=t,this.height=e}return n.prototype.isEmpty=function(){return 0===this.height&&0===this.width},n.prototype.clone=function(){return new n(this.width,this.height)},n}(),Rie=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),KB=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},z=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Rie(t,n),t.equals=function(e,i){return e===i||!(!e||!i)&&(!e||!i||e.x===i.x&&e.y===i.y)},t.isEmptyPoint=function(e){return!(e.x&&e.y)},t.transform=function(e,i,r){var s={x:0,y:0};return s.x=Math.round(100*(e.x+r*Math.cos(i*Math.PI/180)))/100,s.y=Math.round(100*(e.y+r*Math.sin(i*Math.PI/180)))/100,s},t.findLength=function(e,i){return Math.sqrt(Math.pow(e.x-i.x,2)+Math.pow(e.y-i.y,2))},t.findAngle=function(e,i){var r=Math.atan2(i.y-e.y,i.x-e.x);return r=180*r/Math.PI,(r%=360)<0&&(r+=360),r},t.distancePoints=function(e,i){return Math.sqrt(Math.pow(i.x-e.x,2)+Math.pow(i.y-e.y,2))},t.getLengthFromListOfPoints=function(e){for(var i=0,r=0;ri.y&&!r?o.y+=s:o.y-=s:e.y===i.y?e.xi.x&&!r?o.x+=s:o.x-=s:r?(a=this.findAngle(e,i),o=this.transform(e,a,s)):(a=this.findAngle(i,e),o=this.transform(i,a,s)),o},t.direction=function(e,i){return Math.abs(i.x-e.x)>Math.abs(i.y-e.y)?e.x0)for(var r=0;rt.right||this.top>t.bottom||this.bottom=t.right&&this.top<=t.top&&this.bottom>=t.bottom},n.prototype.containsPoint=function(t,e){return void 0===e&&(e=0),this.left-e<=t.x&&this.right+e>=t.x&&this.top-e<=t.y&&this.bottom+e>=t.y},n.toBounds=function(t){for(var e=new n,i=0,r=t;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},s3=function(n){if(n)switch(n.type){case"Linear":default:return MI;case"Radial":return Gie}return MI},Yie=function(){return function n(t,e,i,r){this.left=t,this.right=e,this.top=i,this.bottom=r}}(),$n=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),it([I(0)],t.prototype,"left",void 0),it([I(0)],t.prototype,"right",void 0),it([I(0)],t.prototype,"top",void 0),it([I(0)],t.prototype,"bottom",void 0),t}(Ee),Qie=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),it([I(45)],t.prototype,"angle",void 0),it([I(5)],t.prototype,"distance",void 0),it([I(.7)],t.prototype,"opacity",void 0),it([I("lightgrey")],t.prototype,"color",void 0),t}(Ee),o3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),t.prototype.getClassName=function(){return"Stop"},it([I("")],t.prototype,"color",void 0),it([I(0)],t.prototype,"offset",void 0),it([I(1)],t.prototype,"opacity",void 0),t}(Ee),Cx=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),it([Bt([],o3)],t.prototype,"stops",void 0),it([I("None")],t.prototype,"type",void 0),it([I("")],t.prototype,"id",void 0),t}(Ee),MI=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),it([I(0)],t.prototype,"x1",void 0),it([I(0)],t.prototype,"x2",void 0),it([I(0)],t.prototype,"y1",void 0),it([I(0)],t.prototype,"y2",void 0),t}(Cx),Gie=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),it([I(0)],t.prototype,"cx",void 0),it([I(0)],t.prototype,"cy",void 0),it([I(0)],t.prototype,"fx",void 0),it([I(0)],t.prototype,"fy",void 0),it([I(50)],t.prototype,"r",void 0),t}(Cx),Ll=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),it([I("white")],t.prototype,"fill",void 0),it([I("black")],t.prototype,"strokeColor",void 0),it([I("")],t.prototype,"strokeDashArray",void 0),it([I(1)],t.prototype,"strokeWidth",void 0),it([I(1)],t.prototype,"opacity",void 0),it([T0(s3)],t.prototype,"gradient",void 0),t}(Ee),a3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),it([I("transparent")],t.prototype,"fill",void 0),t}(Ll),Xp=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),it([I("black")],t.prototype,"color",void 0),it([I("Arial")],t.prototype,"fontFamily",void 0),it([I(12)],t.prototype,"fontSize",void 0),it([I(!1)],t.prototype,"italic",void 0),it([I(!1)],t.prototype,"bold",void 0),it([I("CollapseSpace")],t.prototype,"whiteSpace",void 0),it([I("WrapWithOverflow")],t.prototype,"textWrapping",void 0),it([I("Center")],t.prototype,"textAlign",void 0),it([I("None")],t.prototype,"textDecoration",void 0),it([I("Wrap")],t.prototype,"textOverflow",void 0),it([I("transparent")],t.prototype,"fill",void 0),t}(Ll),on=function(n){return n[n.Default=0]="Default",n[n.expandNode=2]="expandNode",n[n.interaction=4]="interaction",n[n.GroupingInProgress=8]="GroupingInProgress",n[n.GroupClipboardInProcess=16]="GroupClipboardInProcess",n[n.ClearObject=32]="ClearObject",n}(on||{}),hi=function(n){return n[n.Visible=1]="Visible",n[n.Hidden=2]="Hidden",n[n.Hover=4]="Hover",n[n.Connect=8]="Connect",n}(hi||{}),Kt=function(n){return n[n.None=0]="None",n[n.ShowHorizontalLines=1]="ShowHorizontalLines",n[n.ShowVerticalLines=2]="ShowVerticalLines",n[n.ShowLines=3]="ShowLines",n[n.SnapToHorizontalLines=4]="SnapToHorizontalLines",n[n.SnapToVerticalLines=8]="SnapToVerticalLines",n[n.SnapToLines=12]="SnapToLines",n[n.SnapToObject=16]="SnapToObject",n[n.All=31]="All",n}(Kt||{}),mr=function(n){return n[n.None=1]="None",n[n.ConnectorSourceThumb=2]="ConnectorSourceThumb",n[n.ConnectorTargetThumb=4]="ConnectorTargetThumb",n[n.ResizeSouthEast=8]="ResizeSouthEast",n[n.ResizeSouthWest=16]="ResizeSouthWest",n[n.ResizeNorthEast=32]="ResizeNorthEast",n[n.ResizeNorthWest=64]="ResizeNorthWest",n[n.ResizeEast=128]="ResizeEast",n[n.ResizeWest=256]="ResizeWest",n[n.ResizeSouth=512]="ResizeSouth",n[n.ResizeNorth=1024]="ResizeNorth",n[n.Rotate=2048]="Rotate",n[n.UserHandle=4096]="UserHandle",n[n.ToolTip=8192]="ToolTip",n[n.ResizeAll=2046]="ResizeAll",n[n.All=16382]="All",n}(mr||{}),qe=function(n){return n[n.None=1]="None",n[n.Select=2]="Select",n[n.Delete=4]="Delete",n[n.Drag=8]="Drag",n[n.DragSourceEnd=16]="DragSourceEnd",n[n.DragTargetEnd=32]="DragTargetEnd",n[n.DragSegmentThumb=64]="DragSegmentThumb",n[n.AllowDrop=128]="AllowDrop",n[n.Bridging=256]="Bridging",n[n.BridgeObstacle=512]="BridgeObstacle",n[n.InheritBridging=1024]="InheritBridging",n[n.PointerEvents=2048]="PointerEvents",n[n.Tooltip=4096]="Tooltip",n[n.InheritTooltip=8192]="InheritTooltip",n[n.Interaction=4218]="Interaction",n[n.ReadOnly=16384]="ReadOnly",n[n.LineRouting=32768]="LineRouting",n[n.InheritLineRouting=65536]="InheritLineRouting",n[n.ConnectToNearByNode=131072]="ConnectToNearByNode",n[n.ConnectToNearByPort=262144]="ConnectToNearByPort",n[n.ConnectToNearByElement=393216]="ConnectToNearByElement",n[n.InheritSegmentThumbShape=524288]="InheritSegmentThumbShape",n[n.InheritSegmentThumbSize=1048576]="InheritSegmentThumbSize",n[n.Default=2043454]="Default",n}(qe||{}),Lr=function(n){return n[n.ReadOnly=2]="ReadOnly",n[n.InheritReadOnly=4]="InheritReadOnly",n[n.Select=8]="Select",n[n.Drag=16]="Drag",n[n.Resize=32]="Resize",n[n.Rotate=64]="Rotate",n[n.Tooltip=128]="Tooltip",n[n.Interaction=120]="Interaction",n[n.None=0]="None",n}(Lr||{}),ie=function(n){return n[n.None=0]="None",n[n.Select=2]="Select",n[n.Drag=4]="Drag",n[n.Rotate=8]="Rotate",n[n.Shadow=16]="Shadow",n[n.PointerEvents=32]="PointerEvents",n[n.Delete=64]="Delete",n[n.InConnect=128]="InConnect",n[n.OutConnect=256]="OutConnect",n[n.Individual=512]="Individual",n[n.Expandable=1024]="Expandable",n[n.AllowDrop=2048]="AllowDrop",n[n.Inherit=78]="Inherit",n[n.ResizeNorthEast=4096]="ResizeNorthEast",n[n.ResizeEast=8192]="ResizeEast",n[n.ResizeSouthEast=16384]="ResizeSouthEast",n[n.ResizeSouth=32768]="ResizeSouth",n[n.ResizeSouthWest=65536]="ResizeSouthWest",n[n.ResizeWest=131072]="ResizeWest",n[n.ResizeNorthWest=262144]="ResizeNorthWest",n[n.ResizeNorth=524288]="ResizeNorth",n[n.Resize=1044480]="Resize",n[n.AspectRatio=1048576]="AspectRatio",n[n.Tooltip=2097152]="Tooltip",n[n.InheritTooltip=4194304]="InheritTooltip",n[n.ReadOnly=8388608]="ReadOnly",n[n.HideThumbs=16777216]="HideThumbs",n[n.AllowMovingOutsideLane=33554432]="AllowMovingOutsideLane",n[n.Default=5240814]="Default",n}(ie||{}),Xr=function(n){return n[n.None=0]="None",n[n.ElementIsPort=2]="ElementIsPort",n[n.ElementIsGroup=4]="ElementIsGroup",n[n.HorizontalLaneHeader=8]="HorizontalLaneHeader",n}(Xr||{}),bt=function(n){return n[n.Rotate=2]="Rotate",n[n.ConnectorSource=4]="ConnectorSource",n[n.ConnectorTarget=8]="ConnectorTarget",n[n.ResizeNorthEast=16]="ResizeNorthEast",n[n.ResizeEast=32]="ResizeEast",n[n.ResizeSouthEast=64]="ResizeSouthEast",n[n.ResizeSouth=128]="ResizeSouth",n[n.ResizeSouthWest=256]="ResizeSouthWest",n[n.ResizeWest=512]="ResizeWest",n[n.ResizeNorthWest=1024]="ResizeNorthWest",n[n.ResizeNorth=2048]="ResizeNorth",n[n.Default=4094]="Default",n}(bt||{}),rt=function(n){return n[n.None=1]="None",n[n.Bridging=2]="Bridging",n[n.UndoRedo=4]="UndoRedo",n[n.Tooltip=8]="Tooltip",n[n.UserInteraction=16]="UserInteraction",n[n.ApiUpdate=32]="ApiUpdate",n[n.PageEditable=48]="PageEditable",n[n.Zoom=64]="Zoom",n[n.PanX=128]="PanX",n[n.PanY=256]="PanY",n[n.Pan=384]="Pan",n[n.ZoomTextEdit=512]="ZoomTextEdit",n[n.Virtualization=1024]="Virtualization",n[n.LineRouting=2048]="LineRouting",n[n.Default=500]="Default",n}(rt||{}),Ci=function(n){return n[n.None=0]="None",n[n.SingleSelect=1]="SingleSelect",n[n.MultipleSelect=2]="MultipleSelect",n[n.ZoomPan=4]="ZoomPan",n[n.DrawOnce=8]="DrawOnce",n[n.ContinuousDraw=16]="ContinuousDraw",n[n.Default=3]="Default",n}(Ci||{}),Ya=function(n){return n[n.Self=1]="Self",n[n.Parent=2]="Parent",n}(Ya||{}),pt=function(n){return n[n.None=0]="None",n[n.Control=1]="Control",n[n.Meta=1]="Meta",n[n.Alt=2]="Alt",n[n.Shift=4]="Shift",n}(pt||{}),Mt=function(n){return n[n.None=null]="None",n[n.Number0=0]="Number0",n[n.Number1=1]="Number1",n[n.Number2=2]="Number2",n[n.Number3=3]="Number3",n[n.Number4=4]="Number4",n[n.Number5=5]="Number5",n[n.Number6=6]="Number6",n[n.Number7=7]="Number7",n[n.Number8=8]="Number8",n[n.Number9=9]="Number9",n[n.A=65]="A",n[n.B=66]="B",n[n.C=67]="C",n[n.D=68]="D",n[n.E=69]="E",n[n.F=70]="F",n[n.G=71]="G",n[n.H=72]="H",n[n.I=73]="I",n[n.J=74]="J",n[n.K=75]="K",n[n.L=76]="L",n[n.M=77]="M",n[n.N=78]="N",n[n.O=79]="O",n[n.P=80]="P",n[n.Q=81]="Q",n[n.R=82]="R",n[n.S=83]="S",n[n.T=84]="T",n[n.U=85]="U",n[n.V=86]="V",n[n.W=87]="W",n[n.X=88]="X",n[n.Y=89]="Y",n[n.Z=90]="Z",n[n.Left=37]="Left",n[n.Up=38]="Up",n[n.Right=39]="Right",n[n.Down=40]="Down",n[n.Escape=27]="Escape",n[n.Space=32]="Space",n[n.PageUp=33]="PageUp",n[n.PageDown=34]="PageDown",n[n.End=35]="End",n[n.Home=36]="Home",n[n.Delete=46]="Delete",n[n.Tab=9]="Tab",n[n.Enter=13]="Enter",n[n.BackSpace=8]="BackSpace",n[n.F1=112]="F1",n[n.F2=113]="F2",n[n.F3=114]="F3",n[n.F4=115]="F4",n[n.F5=116]="F5",n[n.F6=117]="F6",n[n.F7=118]="F7",n[n.F8=119]="F8",n[n.F9=120]="F9",n[n.F10=121]="F10",n[n.F11=122]="F11",n[n.F12=123]="F12",n[n.Star=56]="Star",n[n.Plus=187]="Plus",n[n.Minus=189]="Minus",n[n.BracketLeft=219]="BracketLeft",n[n.BracketRight=221]="BracketRight",n}(Mt||{}),ee=function(n){return n[n.Render=2]="Render",n[n.PublicMethod=4]="PublicMethod",n[n.ToolAction=8]="ToolAction",n[n.UndoRedo=16]="UndoRedo",n[n.TextEdit=32]="TextEdit",n[n.Group=64]="Group",n[n.Clear=128]="Clear",n[n.PreventClearSelection=256]="PreventClearSelection",n[n.Interactions=512]="Interactions",n[n.PreventHistory=1024]="PreventHistory",n[n.PreventIconsUpdate=2048]="PreventIconsUpdate",n[n.PreventCollectionChangeOnDragOver=4096]="PreventCollectionChangeOnDragOver",n[n.PreventZIndexOnDragging=8192]="PreventZIndexOnDragging",n[n.isGroupDragging=16384]="isGroupDragging",n[n.DragUsingMouse=32768]="DragUsingMouse",n[n.DecoratorPropertyChange=65536]="DecoratorPropertyChange",n[n.PreventLaneContainerUpdate=131072]="PreventLaneContainerUpdate",n}(ee||{}),Qa=function(n){return n[n.None=2]="None",n[n.DrawSelectorBorder=4]="DrawSelectorBorder",n[n.PreventRenderSelector=8]="PreventRenderSelector",n}(Qa||{}),$i=function(n){return n[n.None=0]="None",n[n.PreventDrag=2]="PreventDrag",n[n.PreventScale=4]="PreventScale",n[n.PreventDataInit=8]="PreventDataInit",n[n.hScrollbarMoved=16]="hScrollbarMoved",n[n.vScrollbarMoved=32]="vScrollbarMoved",n[n.AnimationClick=64]="AnimationClick",n[n.EnableGroupAction=128]="EnableGroupAction",n[n.PanInProgress=256]="PanInProgress",n[n.OverViewAction=512]="OverViewAction",n}($i||{}),ca=function(n){return n[n.None=0]="None",n[n.PropertyChange=1024]="PropertyChange",n[n.Interaction=2048]="Interaction",n}(ca||{}),Ae=function(n){return n[n.Zero=0]="Zero",n[n.One=1]="One",n[n.Two=2]="Two",n[n.Three=3]="Three",n[n.Four=4]="Four",n[n.Five=5]="Five",n}(Ae||{}),Ce=function(n){return n[n.collectionChange=0]="collectionChange",n[n.rotateChange=1]="rotateChange",n[n.positionChange=2]="positionChange",n[n.propertyChange=3]="propertyChange",n[n.selectionChange=4]="selectionChange",n[n.sizeChange=5]="sizeChange",n[n.drop=6]="drop",n[n.sourcePointChange=7]="sourcePointChange",n[n.targetPointChange=8]="targetPointChange",n[n.connectionChange=9]="connectionChange",n[n.animationComplete=10]="animationComplete",n[n.click=11]="click",n[n.doubleClick=12]="doubleClick",n[n.scrollChange=13]="scrollChange",n[n.dragEnter=14]="dragEnter",n[n.dragLeave=15]="dragLeave",n[n.dragOver=16]="dragOver",n[n.textEdit=17]="textEdit",n[n.paletteSelectionChange=18]="paletteSelectionChange",n[n.historyChange=19]="historyChange",n[n.mouseEnter=20]="mouseEnter",n[n.mouseLeave=21]="mouseLeave",n[n.mouseOver=22]="mouseOver",n[n.expandStateChange=23]="expandStateChange",n[n.segmentCollectionChange=24]="segmentCollectionChange",n[n.commandExecute=25]="commandExecute",n[n.historyStateChange=26]="historyStateChange",n[n.onUserHandleMouseDown=27]="onUserHandleMouseDown",n[n.onUserHandleMouseUp=28]="onUserHandleMouseUp",n[n.onUserHandleMouseEnter=29]="onUserHandleMouseEnter",n[n.onUserHandleMouseLeave=30]="onUserHandleMouseLeave",n[n.onImageLoad=31]="onImageLoad",n[n.onDoBindingInit=32]="onDoBindingInit",n[n.keyUp=33]="keyUp",n[n.keyDown=34]="keyDown",n[n.fixedUserHandleClick=35]="fixedUserHandleClick",n[n.elementDraw=36]="elementDraw",n[n.mouseWheel=37]="mouseWheel",n[n.segmentChange=38]="segmentChange",n[n.onFixedUserHandleMouseDown=39]="onFixedUserHandleMouseDown",n[n.onFixedUserHandleMouseUp=40]="onFixedUserHandleMouseUp",n[n.onFixedUserHandleMouseEnter=41]="onFixedUserHandleMouseEnter",n[n.onFixedUserHandleMouseLeave=42]="onFixedUserHandleMouseLeave",n[n.loaded=43]="loaded",n}(Ce||{}),ri=function(n){return n[n.None=1]="None",n[n.Drag=2]="Drag",n[n.Draw=4]="Draw",n[n.InConnect=8]="InConnect",n[n.OutConnect=16]="OutConnect",n[n.ToolTip=32]="ToolTip",n[n.InheritTooltip=64]="InheritTooltip",n[n.Default=24]="Default",n}(ri||{}),Ex=function(n){return n[n.None=1]="None",n[n.Source=2]="Source",n[n.Target=4]="Target",n[n.Intermediate=8]="Intermediate",n[n.All=14]="All",n}(Ex||{}),wI=function(n){return n[n.None=0]="None",n[n.SymmetricAngle=2]="SymmetricAngle",n[n.SymmetricDistance=4]="SymmetricDistance",n[n.Default=6]="Default",n}(wI||{}),as=function(){function n(){this.pivot={x:.5,y:.5},this.isDirt=!0,this.isExport=!1,this.exportScaleValue={x:0,y:0},this.exportScaleOffset={x:0,y:0},this.canApplyStyle=!0,this.visible=!0,this.offsetX=0,this.offsetY=0,this.cornerRadius=0,this.minHeight=void 0,this.minWidth=void 0,this.maxWidth=void 0,this.maxHeight=void 0,this.width=void 0,this.height=void 0,this.rotateAngle=0,this.margin={left:0,right:0,top:0,bottom:0},this.connectionDirection="Auto",this.horizontalAlignment="Auto",this.verticalAlignment="Auto",this.flip="None",this.flipMode="All",this.relativeMode="Point",this.transform=Ya.Self|Ya.Parent,this.style={fill:"white",strokeColor:"black",opacity:1,strokeWidth:1},this.desiredSize=new me,this.actualSize=new me,this.parentTransform=0,this.preventContainer=!1,this.isSvgRender=!1,this.bounds=new Ne(0,0,0,0),this.shadow=null,this.description="",this.staticSize=!1,this.shapeType="",this.isRectElement=!1,this.isCalculateDesiredSize=!0,this.flipOffset={x:0,y:0},this.elementActions=Xr.None,this.inversedAlignment=!0,this.position=void 0,this.unitMode=void 0,this.float=!1,this.floatingBounds=void 0}return n.prototype.setOffsetWithRespectToBounds=function(t,e,i){this.unitMode=i,this.position={x:t,y:e}},n.prototype.getAbsolutePosition=function(t){if(void 0!==this.position)return"Absolute"===this.unitMode?this.position:{x:this.position.x*t.width,y:this.position.y*t.height}},Object.defineProperty(n.prototype,"outerBounds",{get:function(){return this.floatingBounds||this.bounds},set:function(t){this.floatingBounds=t},enumerable:!0,configurable:!0}),n.prototype.measure=function(t,e,i){var s=void 0!==this.height?this.height:(t.height||0)-this.margin.top-this.margin.bottom;return this.id&&0===s&&this.elementActions&Xr.HorizontalLaneHeader&&(s=this.actualSize.height),this.desiredSize=new me(void 0!==this.width?this.width:(t.width||0)-this.margin.left-this.margin.right,s),this.isCalculateDesiredSize&&(this.desiredSize=this.validateDesiredSize(this.desiredSize,t)),this.desiredSize},n.prototype.arrange=function(t){return this.actualSize=t,this.updateBounds(),this.actualSize},n.prototype.updateBounds=function(){this.bounds=yr(this)},n.prototype.validateDesiredSize=function(t,e){return this.isRectElement&&!this.width&&!this.minWidth&&!this.maxWidth&&(t.width=50),this.isRectElement&&!this.height&&!this.minHeight&&!this.maxHeight&&(t.height=50),(void 0===t||void 0!==this.width&&void 0!==this.height)&&((t=t||new me).width=void 0===this.width?(e.width||0)-this.margin.left-this.margin.right:this.width,t.height=void 0===this.height?(e.height||0)-this.margin.top-this.margin.bottom:this.height),void 0!==this.minWidth&&(t.width=Math.max(t.width,this.minWidth)),void 0!==this.minHeight&&(t.height=Math.max(t.height,this.minHeight)),void 0!==this.maxWidth&&0!==this.maxWidth&&(t.width=Math.min(t.width,this.maxWidth)),void 0!==this.maxHeight&&0!==this.maxHeight&&(t.height=Math.min(t.height,this.maxHeight)),t},n}(),ere=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Cs=function(n){function t(){var e=null!==n&&n.apply(this,arguments)||this;return e.padding=new Yie(0,0,0,0),e.desiredBounds=void 0,e.measureChildren=!0,e.prevRotateAngle=0,e}return ere(t,n),t.prototype.hasChildren=function(){return void 0!==this.children&&this.children.length>0},t.prototype.measure=function(e,i,r){this.desiredBounds=void 0;var o,a,s=void 0;if(this.hasChildren()){for(var l=0;l=n.width&&s.length>0)i[i.length]={text:s,x:0,dy:0,width:o},s="";else{(s+=a[r+1]||"").indexOf("\n")>-1&&(i[i.length]={text:s,x:0,dy:0,width:_c(s,n)},s="");var l=_c(s,n);Math.ceil(l)+2>=n.width&&s.length>0&&(i[i.length]={text:s,x:0,dy:0,width:l},s=""),r===a.length-1&&s.length>0&&(i[i.length]={text:s,x:0,dy:0,width:l},s="")}else i=function Soe(n,t,e){var c,d,u,p,i=[],r="",s=0,o=0,a="nowrap"!==n.whiteSpace,h=(t||n.content).split("\n");for(s=0;s0?" ":"")+c[parseInt(o.toString(),10)];var f=_c(d=c[o+1]?r+" "+c[o+1]:r,n);Math.floor(f)>(e||n.width)-2&&r.length>0?(i[i.length]={text:r,x:0,dy:0,width:d===r?f:r===p?u:_c(r,n)},r=""):o===c.length-1&&(i[i.length]={text:r,x:0,dy:0,width:f},r=""),p=d,u=f}return i}(n,t,e);else i[i.length]={text:a,x:0,dy:0,width:_c(a,n)};return i}(l,r,n.isLaneOrientation?i:void 0),n.wrapBounds=a=function Ioe(n,t){var r,s,e={x:0,width:0},i=0;for(i=0;in.width&&("Ellipsis"===n.textOverflow||"Clip"===n.textOverflow)?0:-r/2:"right"===n.textAlign?-r:t.length>1?0:-r/2,t[parseInt(i.toString(),10)].dy=1.2*n.fontSize,t[parseInt(i.toString(),10)].x=r,e.x=Math.min(e.x,r),e.width=Math.max(e.width,s);return e}(l,o),s.width=a.width,n.wrapBounds.width>=i&&"Wrap"!==l.textOverflow&&(s.width=i),s.height=o.length*n.style.fontSize*1.2,s}(this,0,0,this.isLaneOrientation?e.height:this.width||e.width):this.desiredSize,this.desiredSize=void 0===this.width||void 0===this.height?new me(i.width,i.height):new me(this.width,this.height),this.desiredSize=this.validateDesiredSize(this.desiredSize,e),this.desiredSize},t.prototype.arrange=function(e){return(e.width!==this.actualSize.width||e.height!==this.actualSize.height||this.isDirt)&&(this.doWrap=!0),this.actualSize=e,this.updateBounds(),this.isDirt=!1,this.actualSize},t}(as),ire=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Ii=function(n){function t(){var e=null!==n&&n.apply(this,arguments)||this;return e.measureChildren=void 0,e}return ire(t,n),t.prototype.measure=function(e,i,r){var s=void 0,o=void 0;if(this.hasChildren()){for(var a=0,l=this.children;a=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},xd=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return are(t,n),Lh([I("")],t.prototype,"content",void 0),Lh([I("TopLeft")],t.prototype,"position",void 0),Lh([I("Mouse")],t.prototype,"relativeMode",void 0),Lh([I(!0)],t.prototype,"showTipPointer",void 0),Lh([I("auto")],t.prototype,"width",void 0),Lh([I("auto")],t.prototype,"height",void 0),Lh([I("Auto")],t.prototype,"openOn",void 0),Lh([I()],t.prototype,"animation",void 0),Lh([I(!1)],t.prototype,"isSticky",void 0),t}(Ee);function l3(n){var t=new Sh;t=h3(n.tooltip,t);var e=new Sh(t);return e.beforeCollision=hre,e.beforeOpen=lre,e.cssClass="e-diagram-tooltip",e.opensOn="custom",e.appendTo("#"+n.element.id),e.close(),e}function lre(n){(""===this.content||void 0===this.content)&&(n.element.style.display="none")}function hre(n){n.collidedPosition&&n.collidedPosition!==this.position&&(n.element.style.display="none")}function Dx(n,t){var e=n.tooltipObject;return h3(t?t.tooltip:n.tooltip,e),e}function h3(n,t){return n.content?(t.content=n.content,"string"==typeof n.content&&(t.content=ko(function(){return n.content})),t.position=n.position,t.showTipPointer=n.showTipPointer,t.width=n.width,t.height=n.height,t.animation=n.animation?n.animation:{close:{effect:"None"}}):t.close(),t}var xx=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Hn=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Tx=function(n){function t(e,i,r,s){var o=n.call(this,e,i,r,s)||this;return o.inEdges=[],o.outEdges=[],o}return xx(t,n),Hn([I("")],t.prototype,"id",void 0),Hn([I("Center")],t.prototype,"horizontalAlignment",void 0),Hn([I("Center")],t.prototype,"verticalAlignment",void 0),Hn([re({},$n)],t.prototype,"margin",void 0),Hn([I(12)],t.prototype,"width",void 0),Hn([I(12)],t.prototype,"height",void 0),Hn([re({},Ll)],t.prototype,"style",void 0),Hn([I("Square")],t.prototype,"shape",void 0),Hn([I("Auto")],t.prototype,"connectionDirection",void 0),Hn([I(hi.Connect)],t.prototype,"visibility",void 0),Hn([I("")],t.prototype,"pathData",void 0),Hn([I(ri.Default)],t.prototype,"constraints",void 0),Hn([I()],t.prototype,"addInfo",void 0),Hn([I()],t.prototype,"outEdges",void 0),Hn([I()],t.prototype,"inEdges",void 0),Hn([re({},xd)],t.prototype,"tooltip",void 0),t}(Ee),Es=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return xx(t,n),t.prototype.getClassName=function(){return"PointPort"},Hn([re({x:.5,y:.5},z)],t.prototype,"offset",void 0),t}(Tx),Ac=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return xx(t,n),t.prototype.getClassName=function(){return"PathPort"},Hn([I(.5)],t.prototype,"offset",void 0),Hn([re({x:0,y:0},z)],t.prototype,"displacement",void 0),Hn([I("Center")],t.prototype,"alignment",void 0),t}(Tx),DI=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),lr=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},cre=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return DI(t,n),lr([I("blue")],t.prototype,"color",void 0),lr([I("")],t.prototype,"content",void 0),lr([I("")],t.prototype,"link",void 0),lr([I("None")],t.prototype,"textDecoration",void 0),lr([I("NewTab")],t.prototype,"hyperlinkOpenState",void 0),t}(Ee),Ax=function(n){function t(e,i,r,s){var o=n.call(this,e,i,r,s)||this;return r.id||(o.id=e.parentObj&&e.parentObj.propName&&"phases"===e.parentObj.propName?e.parentObj.id:Qe()),o}return DI(t,n),lr([I("")],t.prototype,"content",void 0),lr([I(void 0)],t.prototype,"template",void 0),lr([I("String")],t.prototype,"annotationType",void 0),lr([I(!0)],t.prototype,"visibility",void 0),lr([I(Lr.InheritReadOnly)],t.prototype,"constraints",void 0),lr([re(void 0,cre)],t.prototype,"hyperlink",void 0),lr([I("")],t.prototype,"id",void 0),lr([I()],t.prototype,"width",void 0),lr([I()],t.prototype,"height",void 0),lr([I(0)],t.prototype,"rotateAngle",void 0),lr([I("Parent")],t.prototype,"rotationReference",void 0),lr([re({strokeWidth:0,strokeColor:"transparent",fill:"transparent"},Xp)],t.prototype,"style",void 0),lr([I("Center")],t.prototype,"horizontalAlignment",void 0),lr([I("Center")],t.prototype,"verticalAlignment",void 0),lr([re({},$n)],t.prototype,"margin",void 0),lr([re({top:void 0,bottom:void 0,left:void 0,right:void 0},$n)],t.prototype,"dragLimit",void 0),lr([I("Shape")],t.prototype,"type",void 0),lr([re({},xd)],t.prototype,"tooltip",void 0),lr([I()],t.prototype,"addInfo",void 0),t}(Ee),Zn=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return DI(t,n),t.prototype.getClassName=function(){return"ShapeAnnotation"},lr([re({x:.5,y:.5},z)],t.prototype,"offset",void 0),t}(Ax),Nr=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return DI(t,n),t.prototype.getClassName=function(){return"PathAnnotation"},lr([I(.5)],t.prototype,"offset",void 0),lr([re({x:0,y:0},z)],t.prototype,"displacement",void 0),lr([I("Center")],t.prototype,"alignment",void 0),lr([I(!1)],t.prototype,"segmentAngle",void 0),t}(Ax);function Lx(n){return fre[n.toString()]}function c3(n){return mre[""+n]}var fre={X:"M14,14 L106,106 M106,14 L14,106",Circle:"M0,50 A50,50,0 1 1 100,50 A50,50,0 1 1 0,50 Z",Square:"M0,0 L10,0 L10,10 L0,10 z"},gre={OpenArrow:"M15.9,23 L5,16 L15.9,9 L17,10.7 L8.7,16 L17,21.3Z",Square:"M0,0 L10,0 L10,10 L0,10 z",Fletch:"M14.8,10c0,0-3.5,6,0.2,12c0,0-2.5-6-10.9-6C4.1,16,11.3,16,14.8,10z",OpenFetch:"M6,17c-0.6,0-1-0.4-1-1s0.4-1,1-1c10.9,0,11-5,11-5c0-0.6,0.4-1,1-1s1,0.4,1,1C19,10.3,18.9,17,6,17C6,17,6,17,6,17z M18,23c-0.5,0-1-0.4-1-1c0-0.2-0.3-5-11-5c-0.6,0-1-0.5-1-1s0.4-1,1-1c0,0,0,0,0,0c12.9,0,13,6.7,13,7 C19,22.6,18.6,23,18,23z",IndentedArrow:"M17,10c0,0-4.5,5.5,0,12L5,16L17,10z",OutdentedArrow:"M14.6,10c0,0,5.4,6,0,12L5,16L14.6,10z",DoubleArrow:"M19,10 L19,22 L13,16Z M12,10 L12,22 L6,16Z",Arrow:"M15,10 L15,22 L5,16Z",Diamond:"M12,23l-7-7l7-7l6.9,7L12,23z",Circle:"M0,50 A50,50,0 1 1 100,50 A50,50,0 1 1 0,50 Z"},vre={Square:"M0,0 L10,0 L10,10 L0,10 z",Rhombus:"M10,5 L5,10 L0,5 L5,0 L10,5 Z ",Rectangle:"M0,0 L15,0 L15,10 L0,10 z ",OpenArrow:"M15.9,23 L5,16 L15.9,9 L17,10.7 L8.7,16 L17,21.3Z",Fletch:"M9.82,0 C9.82,0,6.61,5,10,10 C10,10,7.71,5,0,5 C0,5,6.61,5,9.82,0 Z ",OpenFetch:"M0.71,5.71 C0.29,5.71,0,5.43,0,5 C0,4.57,0.29,4.29,0.71,4.29 C8.5,4.29,8.57,0.71,8.57,0.71 C8.57,0.29,8.86,0,9.29,0 C9.719999999999999,0,10,0.29,10,0.71 C10,0.93,9.93,5.71,0.71,5.71 C0.71,5.71,0.71,5.71,0.71,5.71 Z M9.29,10 C8.93,10,8.57,9.71,8.57,9.29 C8.57,9.14,8.36,5.71,0.71,5.71 C0.29,5.71,0,5.36,0,5 C0,4.64,0.29,4.29,0.71,4.29 C0.71,4.29,0.71,4.29,0.71,4.29 C9.93,4.29,10,9.07,10,9.29 C10,9.71,9.71,10,9.29,10 Z ",IndentedArrow:"M10,0 C10,0,6.25,4.58,10,10 L0,5 L10,0 Z ",OutdentedArrow:"M8,0 C8,0,12.5,5,8,10 L0,5 L8,0 Z ",DoubleArrow:"M19,10 L19,22 L13,16Z M12,10 L12,22 L6,16Z",Arrow:"M15,10 L15,22 L5,16Z",Diamond:"M10,5 L5,10 L0,5 L5,0 L10,5 Z ",Circle:"M10,5 C10,7.76,7.76,10,5,10 C2.24,10,0,7.76,0,5 C0,2.24,2.24,0,5,0 C7.76,0,10,2.24,10,5 Z ",Ellipse:"M15,5 C15,7.76,11.64,10,7.5,10 C3.36,10,0,7.76,0,5 C0,2.24,3.36,0,7.5,0 C11.64,0,15,2.24,15,5 Z "},mre={Square:"M0,0 L10,0 L10,10 L0,10 z",Rhombus:"M10,5 L5,10 L0,5 L5,0 L10,5 Z ",Rectangle:"M0,0 L15,0 L15,10 L0,10 z",OpenArrow:"M23,15.9 L16,5 L9,15.9 L10.7,17 L16,8.7 L21,17.3Z",Fletch:"M9.82,0 C9.82,0,6.61,5,10,10 C10,10,7.71,5,0,5 C0,5,6.61,5,9.82,0 Z ",OpenFetch:"M0.71,5.71 C0.29,5.71,0,5.43,0,5 C0,4.57,0.29,4.29,0.71,4.29 C8.5,4.29,8.57,0.71,8.57,0.71 C8.57,0.29,8.86,0,9.29,0 C9.719999999999999,0,10,0.29,10,0.71 C10,0.93,9.93,5.71,0.71,5.71 C0.71,5.71,0.71,5.71,0.71,5.71 Z M9.29,10 C8.93,10,8.57,9.71,8.57,9.29 C8.57,9.14,8.36,5.71,0.71,5.71 C0.29,5.71,0,5.36,0,5 C0,4.64,0.29,4.29,0.71,4.29 C0.71,4.29,0.71,4.29,0.71,4.29 C9.93,4.29,10,9.07,10,9.29 C10,9.71,9.71,10,9.29,10 Z ",IndentedArrow:"M10,0 C10,0,6.25,4.58,10,10 L0,5 L10,0 Z ",OutdentedArrow:"M8,0 C8,0,12.5,5,8,10 L0,5 L8,0 Z ",DoubleArrow:"M10,19 L22,19 L16,13Z M10,12 L22,12 L16,6Z",Arrow:"M10,15 L22,15 L16,5Z",Diamond:"M10,5 L5,10 L0,5 L5,0 L10,5 Z ",Circle:"M10,5 C10,7.76,7.76,10,5,10 C2.24,10,0,7.76,0,5 C0,2.24,2.24,0,5,0 C7.76,0,10,2.24,10,5 Z ",Ellipse:"M15,5 C15,7.76,11.64,10,7.5,10 C3.36,10,0,7.76,0,5 C0,2.24,3.36,0,7.5,0 C11.64,0,15,2.24,15,5 Z "};function Nx(n){return yre[n.toString()]}var yre={Process:"M419.511,76.687L359.511,76.687L359.511,43.086L419.511,43.086z",Decision:"M 253.005,115.687L 200.567,146.071L 148.097,115.687L 200.534,85.304L 253.005,115.687 Z",Document:"M 60 31.9 c 0 0 -11 -7.7 -30 0 s -30 0 -30 0 V 0 h 60 V 31.9 Z",PreDefinedProcess:"M 0,0 L 50,0 L 50,50 L 0,50 Z M 8.334,0 L 8.334,50 M 41.667,0 L 41.667,50",Terminator:"M 269.711,29.33C 269.71,44.061 257.77,56 243.04,56L 158.058,56C 143.33,56 131.39,44.061 131.39,29.33L 131.39,29.33C 131.391,14.6057 143.33,2.669 158.058,2.669L 243.044,2.669C 257.772,2.669 269.711,14.6057 269.711,29.333 Z",PaperTap:"M0.0009,17.2042 L0.0009,47.165 C0.001,47.165 14.403,53.5455 25.00,47.165 C35.599,40.7852 44.403,43.5087 50.00,47.165L50.001,17.2042 M50.001,32.7987 L50.001,2.8405 C50.001,2.8405 35.599,-3.5427 25.001,2.8405C14.403,9.2237 5.599,6.494 0.0009,2.8405 L0.0009,32.7987",DirectData:"M 132.62 0 L 17.38 0 C 7.78 0 0 13.43 0 30 C 0 46.57 7.78 60 17.38 60 L 132.62 60 M 132.62 0C 123.02 0 115.24 13.43 115.24 30 C 115.24 46.57 123.02 60 132.62 60 C 142.22 60 150 46.57 150 30 C 150 13.43 142.22 0 132.62 0 z ",SequentialData:"M0.0029,24.999 C0.0029,11.1922 10.433,0.0021 23.295,0.0021 C36.159,0.00216 46.585,11.1922 46.585,24.999C46.585,38.8057 36.159,49.9979 23.295,49.9979 C10.433,49.9979 0.0029,38.8057 0.0029,24.999 z M23.294,49.999 L50.002,49.999",Sort:"M50.001,24.9971 L25.001,49.9971 L0.00097,24.9971 L25.001,-0.00286865 L50.001,24.9971 z M0.000976562,24.9971 L50.001,24.9971",MultiDocument:"M43.6826,40 C44.8746,40.6183 45.8586,41.3502 46.8366,42.1122 L46.8366,4.74487 L3.09857,4.74487 L3.09857,10.9544 M46.837,35.143 C48.027,35.765 49.025,36.604 50.003,37.369 L50.003,0.002 L6.264,0.002 L6.264,4.744 M43.682,47.113 L43.682,10.765 L0.0025,10.7652 L0.0025,47.1132 C0.0025,47.1132 12.5846,53.6101 21.8426,47.1132 C31.1006,40.6163 38.792,43.393 43.6826,47.1132 z",Collate:"M50.001,0.0028 L25.001,25.0029 L0.00097,0.0028 L50.001,0.002 z M0.0009,50.002 L25.001,25.002L50.001,50.002 L0.0009,50.0029 z",SummingJunction:"M7.3252,42.6768 L42.6772,7.3247 M42.6768,42.6768 L7.3248,7.3247 M0.0009,25.001 C0.0009,11.193 11.197,0.0009 25.001,0.0009 C38.809,0.0009 50.001,11.193 50.001,25.001 C50.001,38.809 38.809,50.001 25.001,50.001 C11.197,50.00 0.0009,38.809 0.0009,25.00 z",Or:"M 0 50 L 100 50 M 50 100 L 50 0.0 M 0 50 C 0 22.384 22.392 0 50 0 C 77.616 0 100 22.384 100 50 C 100 77.616 77.616 100 50 100 C 22.392 100 0 77.616 0 50 Z",InternalStorage:"M 0 3.81946A 2.5,3.81946 0 0,1 2.5,0L 47.5 0A 2.5,3.81946 0 0,1 50,3.81946L 50 45.836A 2.5,3.819446 0 0,1 47.5,49.652778L 2.5 49.652778A 2.5,3.819446 0 0,1 0,45.8336L 0 3.819446ZM 0 11.45834L 50 11.4583334M 12.5 0L 12.5 49.652778",Extract:"M0,35 L30,0 L60,35 Z",ManualOperation:"M46.4,28.8 L14.8,28.8 L0,0 L60,0 Z",Merge:"M60,0 L30,35 L0,0 Z",OffPageReference:"M60,33.3 L30.1,39 L0,33.3 L0,0 L60,0 Z",SequentialAccessStorage:"M 60 30 C 60 13.4 46.6 0 30 0 S 0 13.4 0 30 s 13.4 30 30 30 h 28.6 v -6.5 h -9.9C 55.5 48 60 39.5 60 30 Z",Annotation:"M49.9984,50.0029 L-0.00271199,50.0029 L-0.00271199,0.00286865 L49.9984,0.00286865",Annotation2:"M49.9977,50.0029 L25.416,50.0029 L25.416,0.00286865 L49.9977,0.00286865 M25.4166,25.0029 L-0.00227869,25.0029",Data:"M 10 0 L 40 0 L 30 40 L 0 40 Z",Card:"M275,60 L400,60 L400,110 L260,110 L260,75 Z",Delay:"M0,0 L12.029,0 C14.212999,0 16,1.7869979 16,3.9709952 C16,6.1549926 14.212999,7.9409904 12.029,7.9409904 L0,7.9409904 z",Preparation:"M 1048.17 572 C 1051.06 568.86 1055.17 567.05 1059.5 567 L 1094.51 567 C 1098.84 567.05 1102.95 568.86 1105.84 572 L 1126.43 595 C 1127.01 596.28 1127.01 597.72 1126.43 599 L 1105.84 622 C 1102.95 625.14 1098.84 626.95 1094.51 627 L 1059.5 627 C 1055.17 626.95 1051.06 625.14 1048.17 622 L 1027.58 599 C 1027 597.72 1027 596.28 1027.58 595 L 1048.17 572 Z",Display:"M47.8809,19.2914 L32.7968,-0.00594145 L11.3902,-0.00594145 C7.93166,-0.00594145 0.00124586,11.187 0.00124586,24.9968C0.00124586,38.8032 7.93166,49.9962 11.3902,49.9962 L32.7968,49.99 L47.615,31.038 C47.615,31.0388 52.798,24.9968 47.880,19.2914 z",ManualInput:"M 912 732 L 1006.85 707 C 1008.2 707 1009.5 707.53 1010.46 708.46 C 1011.41 709.4 1011.95 710.67 1011.95 712 L 1011.95 762C 1012 764.41 1010.28 766.52 1007.87 767 L 917.1 767 C 915.75 767 914.45 766.47 913.49 765.54 C 912.54 764.6 912 763.33 912 762 L 912 732 Z",LoopLimit:"M 8 9 L 27 9 L 33 15 L 33 26 C 33 27 33 27 32 27 L 4 27 C 3 27 2 27 2 26 L 2 15 L 8 9 Z",StoredData:"M 5.55 0L 50 0A 1.5,30 0 0,1 50,0A 5.555,25 0 0,0 50,50A 1.5,30 0 0,1 50,50L 5.555 50A 5.55,25 0 0,1 5.555,0Z"};function d3(n,t,e){var i;i="Straight"!==n.type&&n.sourceWrapper?n.sourceWrapper.corners.center:function Sre(n){var t;if(n.sourcePortWrapper){var e=n.sourcePortWrapper;t={x:e.offsetX,y:e.offsetY}}else t=n.sourceID&&n.sourceWrapper&&n.targetWrapper?Nh(n,0,n.sourceWrapper.corners.center,n.targetWrapper.corners.center,!1):n.sourcePoint;return t}(n);var r=function bre(n,t,e,i,r){var b,M,s=n.sourceWrapper,o=n.targetWrapper,a=n.sourcePortWrapper,l=n.targetPortWrapper,d=[],f=Ga(n),y={corners:undefined,point:t,direction:undefined,margin:{left:5,right:5,bottom:5,top:5}},S={corners:undefined,point:e,direction:undefined,margin:{left:5,right:5,bottom:5,top:5}};if(void 0!==s&&void 0!==o&&(b=En(s),M=En(o),y.corners=s.corners,S.corners=o.corners),void 0!==a&&(y.direction="Left"===a.connectionDirection||"Top"===a.connectionDirection||"Bottom"===a.connectionDirection||"Right"===a.connectionDirection?a.connectionDirection:zo({x:a.offsetX,y:a.offsetY},b,s.bounds)),void 0!==l&&(S.direction="Left"===l.connectionDirection||"Right"===l.connectionDirection||"Bottom"===l.connectionDirection||"Top"===l.connectionDirection?l.connectionDirection:zo({x:l.offsetX,y:l.offsetY},M,o.bounds)),"Bezier"===n.type&&!n.isBezierEditing&&n.segments.length>0)for(var D=n.segments.length-1;D>=0;)n.segments[parseInt(D.toString(),10)].isInternalSegment&&n.segments.pop(),D--;if(void 0!==s&&void 0!==o)return(void 0===y.direction||void 0===S.direction)&&(i?function Ire(n,t,e){"LeftToRight"===e?(n.direction=n.direction?n.direction:"Right",t.direction=t.direction?t.direction:"Left"):"RightToLeft"===e?(n.direction=n.direction?n.direction:"Left",t.direction=t.direction?t.direction:"Right"):"TopToBottom"===e?(n.direction=n.direction?n.direction:"Bottom",t.direction=t.direction?t.direction:"Top"):"BottomToTop"===e&&(n.direction=n.direction?n.direction:"Top",t.direction=t.direction?t.direction:"Bottom")}(y,S,i):y.corners.top>S.corners.bottom&&Math.abs(y.corners.top-S.corners.bottom)>f?(y.direction=y.direction?y.direction:"Top",S.direction=S.direction?S.direction:"Bottom"):y.corners.bottomf?(y.direction=y.direction?y.direction:"Bottom",S.direction=S.direction?S.direction:"Top"):y.corners.rightf||y.corners.right+f=y.corners.left-f&&y.corners.left>S.corners.left?(y.direction=y.direction?y.direction:"Right",S.direction=S.direction?S.direction:"Left"):y.corners.left>S.corners.right&&Math.abs(y.corners.left-S.corners.right)>y.margin.left+y.margin.right||S.corners.right+f=S.corners.left-f&&y.corners.left0&&n.segments[0].direction&&(y.direction=n.segments[0].direction),y.point=Lc(b,y.direction),d=Lc(b,ls(y.direction)),y.point=Nh(n,0,y.point,d,!1)):y.point=o.corners.center;if(void 0!==h){switch(S.point={x:h.offsetX,y:h.offsetY},S.direction){case"Bottom":case"Top":S.point.y=S.point.y;break;case"Left":case"Right":S.point.x=S.point.x}n.targetPadding&&!w&&(S.point=xI(n,y,S,!0))}else"Orthogonal"===n.type||"Bezier"===n.type?(S.point=Lc(M,S.direction),d=Lc(M,ls(S.direction)),S.point=Nh(n,0,S.point,d,!0)):S.point=a.corners.center;if("Orthogonal"!==n.type){var C=void 0,D=void 0;if("Bezier"===n.type){if(n.bezierSettings.allowSegmentsReset||0===n.segments.length||!z.isEmptyPoint(n.segments[n.segments.length-1].point))return c=b3(n,y,S,void 0,s),Ox(n,y,S);_v(n)}else _v(n);if(void 0===n.sourcePortWrapper){y.point=y.corners.center,n.segments&&n.segments.length>0&&(C=z.isEmptyPoint((D=n.segments[0]).point)?void 0:D);var A=void 0!==C?C.point:S.point;if("Bezier"===n.type&&n.segments.length>0&&n.segments[0].vector1.angle&&n.segments[0].vector1.distance){var x=Math.max(y.corners.width,y.corners.height);A=z.transform(y.point,n.segments[0].vector1.angle,x/2)}y.point=w?n.sourceWrapper.bounds.center:Nh(n,0,y.point,A,!1)}if(void 0===n.targetPortWrapper){S.point=S.corners.center,n.segments&&n.segments.length>1&&(C=z.isEmptyPoint((D=n.segments[n.segments.length-2]).point)?void 0:D);var R=C?C.point:y.point;"Bezier"===n.type&&n.segments.length>0&&n.segments[n.segments.length-1].vector2.angle&&n.segments[n.segments.length-1].vector2.distance&&(x=Math.max(y.corners.width,y.corners.height),R=z.transform(S.point,n.segments[0].vector2.angle,x/2)),S.point=w?n.targetWrapper.bounds.center:Nh(n,0,R,S.point,!0)}c=Ox(n,y,S)}else"Orthogonal"===n.type&&n.segments&&n.segments.length>0&&null!==n.segments[0].direction?c=function Nre(n,t,e,i,r,s,o){var a,h,c,d;_v(n);for(var u=0;u0&&n.segments[u-1].direction===h.direction?u=y3(n,u,t):h.direction?t.point=u3(t,n.segments[parseInt(u.toString(),10)]):(p=n.segments[u-1])&&p.points&&(t.point=p.points[p.points.length-1]),u===n.segments.length-1)if(S3(n,t),v3(a=void 0===r?Lre(n,t,e):f3(n,t,e),n),h.points=[],a.length>=2)for(c=0;c2&&n.segments.length>2){var f={x:a[parseInt(c.toString(),10)].x,y:t.point.y};h.points=[],h.points.push(f),h.points.push(a[parseInt(c.toString(),10)]);var p=n.segments[u-1];n.segments.length<4&&p.points.pop(),p.points=p.points.concat(h.points)}else h.points.push(a[parseInt(c.toString(),10)]);else h.points.push(a[parseInt(c.toString(),10)]);else d=u;if(void 0!==d&&!n.selectedSegmentIndex&&(d===n.segments.length-1&&(n.segments[d-1].direction=null,n.segments[d-1].length=null),n.segments.splice(d,1)),i&&0===u){var g=g3(n,i,s);g&&(t.point=g)}}return I3(n,[])}(n,y,S,l,h,o):(n.segments[0]||(C=new bi(n,"segments",{type:"Orthogonal"},!0),n.segments.push(C)),n.segments[0].points=c=b3(n,y,S,void 0,s));return c}(n,y.direction,S.direction,y.point,S.point,r);if(_v(n),(n.sourceWrapper||n.targetWrapper)&&function Dre(n,t,e){var i=n.sourcePortWrapper,r=n.targetPortWrapper,s=n.sourceWrapper,o=t.point,a={left:0,right:0,top:0,bottom:0},l={x:0,y:0},c="Top";if(s?(o=e.point,a=t.margin):(s=n.targetWrapper,a=e.margin),"Orthogonal"===n.type)if(n.segments&&n.segments.length>0&&n.sourceWrapper&&n.segments[0].direction)t.direction=n.segments[0].direction,l=Nh(n,0,l=Lc(s.corners,t.direction),Lc(s.corners,ls(t.direction)),!1);else{var u={corners:null,direction:null,point:null,margin:null};Uv(s,{corners:null,direction:null,point:o,margin:a},u,n),l=u.point,c=u.direction}else{var p=void 0;n.segments&&n.segments.length>1&&(p=s===n.sourceWrapper?n.segments[0].point:n.segments[n.segments.length-2].point),l=Nh(n,0,s.bounds.center,n.segments&&n.segments.length>1?p:o,s===n.targetWrapper)}s===n.sourceWrapper?(t.direction=t.direction||c,t.point=l,n.sourcePortWrapper&&(t.point={x:i.offsetX,y:i.offsetY},n.sourcePadding&&(t.point=xI(n,t,e,!1)))):(e.direction=e.direction||c,e.point=l,n.targetPortWrapper&&(e.point={x:r.offsetX,y:r.offsetY},n.targetPadding&&(e.point=xI(n,t,e,!0))))}(n,y,S),"Straight"===n.type||"Bezier"===n.type)d=Ox(n,y,S);else if("Orthogonal"===n.type&&n.segments&&n.segments.length>0&&null!==n.segments[0].length&&null!==n.segments[0].direction)d=function Ere(n,t,e,i,r,s,o){var a,l,c,u,h=[];if(_v(n),n.segments.length>0){for(var p=0;p0&&n.segments[p-1].direction===f.direction)p=y3(n,p,t);else{var g=n.segments[p-1];t.point=f.direction?u3(t,f):g.points[g.points.length-1]}if(p===n.segments.length-1&&(o||r?n.targetWrapper&&void 0===n.targetPortWrapper?(S3(n,t),l=wre(n,t,e)):l=f3(n,t,e):l=Mre(n,t,e),l))if(v3(l,n),f.points=[],l.length>=2)for(a=0;at.corners.top&&e.point.ye.point.x?"Left":"Right"):e.point.x>t.corners.left&&e.point.xe.point.y?"Top":"Bottom")),n.sourcePortWrapper&&s===ls(r)?(("Left"===s||"Right"===s)&&t.point.y>=t.corners.top&&t.point.y<=t.corners.center.y&&e.point.y>=t.corners.top&&e.point.y<=t.corners.center.y?(t.direction="Top",a=t.point.y-t.corners.top+20):("Left"===s||"Right"===s)&&t.point.y>t.corners.center.y&&t.point.y<=t.corners.bottom&&e.point.y>t.corners.center.y&&e.point.y<=t.corners.bottom?(t.direction="Bottom",a=t.corners.bottom-t.point.y+20):("Top"===s||"Bottom"===s)&&t.point.x>=t.corners.left&&t.point.x<=t.corners.center.x&&e.point.x>=t.corners.left&&e.point.x<=t.corners.center.x?(t.direction="Left",a=t.point.x-t.corners.left+20):("Top"===s||"Bottom"===s)&&t.point.x<=t.corners.right&&t.point.x>t.corners.center.x&&e.point.x<=t.corners.right&&e.point.xt.point.y&&t.point.y>=e.corners.top?(i="Top",r=t.point.y-e.corners.top+20):e.corners.center.y===t.point.y&&"Top"===n.segments[n.segments.length-2].direction||e.corners.center.ye.point.y?t.point.y-t.corners.top+20:t.corners.bottom-t.point.y+20):(i="Top",r=e.corners.height/2+20):e.corners.center.x!==t.point.x||e.corners.topt.point.x&&t.point.x>=e.corners.left?(i="Left",r=t.point.x-e.corners.left+20):e.corners.center.x===t.point.x&&"Left"===n.segments[n.segments.length-2].direction||e.corners.center.x<=t.point.x&&t.point.x<=e.corners.right?(i="Right",r=e.corners.right-t.point.x+20):void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&t.corners.left<=t.point.x&&t.point.x<=t.corners.right&&(i=t.direction,r=t.point.x>e.point.x?t.point.x-t.corners.left+20:t.corners.right-t.point.x+20):(i="Left",r=e.corners.width/2+20);var a=t.point;t.point=Bn(t.point,"Left"===i||"Top"===i?-r:r,"Left"===i||"Right"===i?0:90),t.direction=z.direction(t.point,e.point),void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&(t.corners.center.x===e.corners.center.x||t.corners.center.y===e.corners.center.y)&&(t.direction=e.direction);var l=Ys(n,t,e);return l.splice(0,0,a),l}function f3(n,t,e){var i,r;e.corners=n.targetWrapper.corners,void 0!==n.sourcePortWrapper&&(r=zo({x:n.sourcePortWrapper.offsetX,y:n.sourcePortWrapper.offsetY},En(n.sourceWrapper),n.sourceWrapper.bounds));var a=function Cre(n,t,e,i){var r=!1;switch(e.direction){case"Left":void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&"Right"===i&&t.point.x>e.point.x&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom||("Bottom"===i&&t.point.y>e.point.y||"Top"===i&&t.point.y=t.corners.left&&t.point.x<=t.corners.right?(t.direction="Right"===i?t.point.y>e.point.y?"Top":"Bottom":t.point.xe.point.x&&(t.point.y>e.point.y||t.point.yt.point.y&&e.corners.bottome.point.y||t.point.x>e.point.x&&t.point.y<=e.point.y&&e.corners.top=t.point.y?t.direction="Top":t.point.xe.point.x&&t.point.y>e.point.y&&e.corners.bottomt.point.y?t.direction="Bottom":t.point.y===e.point.y&&t.point.xe.point.y||"Top"===i&&t.point.ye.point.x&&t.point.x>=t.corners.left&&t.point.x<=t.corners.right?(t.direction=t.point.x>e.point.x?"Left":"Right",r=!0):void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&"Left"===i&&t.point.x=t.corners.top&&t.point.y<=t.corners.bottom?(t.direction=t.point.y>e.point.y?"Top":"Bottom",r=!0):t.point.x=t.point.y&&t.point.y===e.point.y||t.point.y>e.point.y&&t.point.x>e.point.x?t.direction="Top":t.point.ye.point.x?t.direction="Bottom":t.point.xe.point.y||t.point.ye.point.x&&(t.direction="Left");break;case"Top":void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&"Bottom"===i&&t.point.y>e.point.y&&t.point.x>=t.corners.left&&t.point.x<=t.corners.right||("Right"===i&&t.point.x>e.point.x||"Left"===i&&e.point.y>t.point.y&&e.point.x>t.point.x)&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom?(t.direction="Bottom"===i?t.point.x>e.point.x?"Left":"Right":t.point.ye.point.y&&t.point.x>e.corners.left&&t.point.x=e.point.y?t.direction="Top":t.point.ye.point.x?t.direction="Left":t.point.yt.point.x)&&t.point.y>e.point.y&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom||"Top"===i&&t.point.y=t.corners.left&&t.point.x<=t.corners.right)?(t.direction="Right"===i||"Left"===i?t.point.y>e.point.y?"Top":"Bottom":t.point.x>e.point.x?"Left":"Right",r=!0):t.point.ye.corners.left&&e.corners.right>t.point.x?t.point.ye.corners.left&&e.corners.center.x>=t.point.x?t.direction="Left":t.point.ye.point.y&&t.point.x>e.point.x?t.direction="Left":t.point.y>e.point.y&&t.point.xe.point.x||e.point.x>t.point.x)&&(t.direction="Bottom")}return r}(n,t,e,r);return!n.selectedSegmentIndex&&void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&e.direction===ls(r)&&(("Left"===e.direction&&t.point.x>e.point.x||"Right"===e.direction&&t.point.x=t.corners.top&&t.point.y<=t.corners.bottom||"Bottom"===e.direction&&t.point.y=t.corners.left&&t.point.x<=t.corners.right)?i=p3(n,t,e):n.selectedSegmentIndex||t.direction!==e.direction?!n.selectedSegmentIndex&&("Left"===e.direction&&t.point.x>e.point.x||"Right"===e.direction&&t.point.x=t.point.y||"Top"===e.direction&&t.point.y>e.point.y||"Bottom"===e.direction&&t.point.y=t.point.x?i=n.selectedSegmentIndex?Nl(t,e):p3(n,t,e):!n.selectedSegmentIndex&&void 0!==n.sourceWrapper&&void 0!==n.targetWrapper&&void 0!==n.targetPortWrapper&&("Left"===t.direction||"Right"===t.direction)&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom&&("Top"===e.direction||"Bottom"===e.direction)&&e.corners.center.x===t.corners.center.x?(t.direction="Top"===e.direction?"Bottom":"Top",i=Ys(n,t,e,"Top"===e.direction?t.corners.bottom-t.point.y+20:t.point.y-t.corners.top+20)):!n.selectedSegmentIndex&&void 0!==n.sourceWrapper&&void 0!==n.targetWrapper&&void 0!==n.targetPortWrapper&&("Top"===t.direction||"Bottom"===t.direction)&&t.point.x>=t.corners.left&&t.point.x<=t.corners.right&&("Left"===e.direction||"Right"===e.direction)&&e.corners.center.y===t.corners.center.y?(t.direction="Left"===e.direction?"Right":"Left",i=Ys(n,t,e,"Left"===e.direction?t.corners.right-t.point.x+20:t.point.x-t.corners.left+20)):i=a?Ys(n,t,e,"Left"===t.direction||"Right"===t.direction?"Left"===t.direction?t.point.x-t.corners.left+20:t.corners.right-t.point.x+20:"Top"===t.direction?t.point.y-t.corners.top+20:t.corners.bottom-t.point.y+20):Nl(t,e):i=Ys(n,t,e),i}function g3(n,t,e){var r,i={x:t.offsetX,y:t.offsetY},s=En(e),o=zo(i,s,e.bounds),a=n.segments[0];return a.direction!==o&&(function Ore(n,t,e,i,r,s){var a,h,o=13,l=[];l.push(i),i.y===r.y&&("Left"===t&&r.xi.x)||i.x===r.x&&("Top"===t&&r.yi.y)||("Top"===t||"Bottom"===t?"Top"===t&&r.yi.y-o||"Bottom"===t&&r.y>i.y&&r.yo&&("Top"===t&&r.yi.y)?l.push({x:i.x,y:r.y}):(a=r.xi.x-o||"right"===t&&r.x>i.x&&r.xo&&("Left"===t&&r.xi.x)?l.push({x:r.x,y:i.y}):(l.push({x:a="Left"===t?e.left-o:e.right+o,y:i.y}),l.push({x:a,y:r.y})),s&&(l.push(n.points[0]),l.reverse()),n.points=l)}(a,o,s,a.points[0],a.points[a.points.length-1],!1),r=a.points[a.points.length-1],a.direction=z.direction(a.points[a.points.length-2],a.points[a.points.length-1])),r}function v3(n,t,e){var s,i=t.segments[t.segments.length-2],r=i.points[i.points.length-1];(("Top"===i.direction||"Bottom"===i.direction)&&r.x===n[1].x||("Left"===i.direction||"Right"===i.direction)&&r.y===n[1].y)&&(i.points[i.points.length-1]=n[1],s=z.direction(i.points[0],i.points[i.points.length-1]),void 0!==t.sourceWrapper&&void 0===t.sourcePortWrapper&&s===ls(i.direction)&&("Left"===i.direction||"Right"===i.direction?i.points[0].x="Right"===i.direction?i.points[0].x-t.sourceWrapper.corners.width:i.points[0].x+t.sourceWrapper.corners.width:i.points[0].y="Bottom"===i.direction?i.points[0].y-t.sourceWrapper.corners.height:i.points[0].y+t.sourceWrapper.corners.height),i.direction=s,i.length=z.distancePoints(i.points[0],i.points[i.points.length-1]),n.splice(0,1))}function xI(n,t,e,i){var o=i?n.targetPadding:n.sourcePadding,a=i?n.targetPortWrapper:n.sourcePortWrapper,l=new Ne(a.bounds.x-o,a.bounds.y-o,a.actualSize.width+2*o,a.actualSize.height+2*o),h=[l.topLeft,l.topRight,l.bottomRight,l.bottomLeft];h[h.length]=h[0];var d=i?e.point:t.point;return Px({x1:t.point.x,y1:t.point.y,x2:e.point.x,y2:e.point.y},h,0,d)||d}function m3(n,t){var e=[],i=mF(0,n.corners,t);i.push(i[0]);for(var r=0;r0){var r=void 0,s=[],o=t.point;for(r=0;r1&&z.equals(a.points[0],a.points[1])&&n.segments.splice(r,1),a)for(var l=0;l0||0===r)&&i.push(a.points[parseInt(l.toString(),10)])}}return i}function kx(n,t,e){return"Top"===n||"Bottom"===n?e.x>t.x?"Right":"Left":e.y>t.y?"Bottom":"Top"}function _v(n){if("Straight"===n.type||"Bezier"===n.type){if(0===n.segments.length||n.segments.length>0&&!z.isEmptyPoint(n.segments[n.segments.length-1].point))if("Bezier"===n.type){var t=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0},!0);n.segments.push(t)}else t=new Pl(n,"segments",{type:"Straight"},!0),n.segments.push(t)}else{if(n.segments.length>0)for(var e=!1,i=0;i=t.corners.left&&e.point.x<=t.corners.right&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom)t.direction=e.point.y>t.point.y?"Bottom":"Top",i=Ys(n,t,e,"Top"===t.direction?t.point.y-t.corners.top+20:t.corners.bottom-t.point.y+20);else if(n.sourcePortWrapper&&r===ls(o)){var h;("Left"===r||"Right"===r)&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom?(t.direction=e.point.y>t.point.y?"Bottom":"Top",h=t.corners.height/2+20):("Top"===r||"Bottom"===r)&&t.point.x>=t.corners.left&&t.point.x<=t.corners.right&&(t.direction=e.point.x>t.point.x?"Right":"Left",h=t.corners.width/2+20),t.direction&&h?i=Ys(n,t,e,h,!0):(t.direction=o,i=Nl(t,e))}else if(!n.sourcePortWrapper||r!==e.direction||"Top"!==r&&"Bottom"!==r||t.corners.center.x!==e.corners.center.x)if(t.direction===e.direction)if(("Left"===t.direction||"Right"===t.direction)&&e.point.y>t.corners.top-20&&e.point.yt.corners.left-20&&e.point.xt.point.y?"Bottom":"Top",i=Ys(n,t,e,"Bottom"===t.direction?t.corners.bottom-t.point.y+20:t.point.y-t.corners.top+20);else t.direction=o,i=Ys(n,t,e,"Top"===o||"Bottom"===o?n.sourceWrapper.height/2+20:n.sourceWrapper.width/2+20),t.point=i[1],"Left"===o||"Right"===o?(e.direction=o,e.point="Left"===o?e.corners.middleLeft:e.corners.middleRight):Uv(n.targetWrapper,t,e,n),i=Ys(n,t,e);return i}function S3(n,t){if(void 0!==n.targetWrapper&&void 0===n.targetPortWrapper&&En(n.targetWrapper).containsPoint(t.point,1)){var i=n.targetWrapper,r=n.segments[n.segments.length-2],s=r.points[r.points.length-1],o=ls(r.direction);"Bottom"===o?s.yi.corners.top-1&&(r.points[r.points.length-1].y=i.corners.top-20,r.length=z.distancePoints(r.points[0],r.points[r.points.length-1])):"Left"===o?s.x>i.corners.left-1&&(r.points[r.points.length-1].x=i.corners.left-20,r.length=z.distancePoints(r.points[0],r.points[r.points.length-1])):"Right"===o&&s.x0||0===e)&&t.push(i.points[parseInt(r.toString(),10)]);return t}function Uv(n,t,e,i){var r,s={x:0,y:0},o=TI(n,n.corners,n.bounds),a=t.margin,l=t.point;if(o.bottomCenter.y+a.bottoml.y)r="Top",s=o.topCenter;else if(o.middleLeft.x-a.left>l.x)r="Left",s=o.middleLeft;else if(o.middleRight.x+a.rightc&&(p=c,r="Right",s=o.middleRight),p>d&&(p=d,r="Bottom",s=o.bottomCenter),p>u&&(r="Left",s=o.middleLeft)}e.point=s,e.direction=r;var f=Lc(o,ls(e.direction));e.point=Nh(i,0,e.point,f,n===i.targetWrapper)}function b3(n,t,e,i,r){var s,o,a;if(s=function Qre(n,t){var e=!1;switch(n){case"Left":switch(t){case"Right":case"Bottom":e=!0}break;case"Top":switch(t){case"Left":case"Right":case"Bottom":e=!0}break;case"Bottom":"Right"===t&&(e=!0)}return e}(t.direction,e.direction),s&&x3(t,e),"Right"===t.direction&&"Left"===e.direction)a=function kre(n,t,e,i){var o=Math.round(Math.abs(t.point.y-e.point.y)),a={x:Math.max(t.point.x,t.corners.right),y:t.point.y},l={x:Math.min(e.point.x,e.corners.left),y:e.point.y},h=Ga(n);if(i){var c=l;l=a,a=c}return t.corners.bottom+he.corners.bottom+h||("Bezier"!==n.type||e.corners.left-t.corners.right<=2*h&&e.corners.left-t.corners.right>=5)&&(h=0),t.margin={left:h,right:h,top:h,bottom:h},e.margin={left:h,right:h,top:h,bottom:h},0===o&&(t.corners.right=e.corners.right?void 0!==i&&(i.offsetYe.corners.bottom+e.margin.bottom)||void 0===i&&t.corners.middleRight.ye.corners.bottom+e.margin.bottom&&t.corners.top>e.corners.bottom||void 0===i&&t.corners.middleRight.y>e.corners.bottom||void 0!==i&&i.offsetYe.corners.top||void 0===i&&t.corners.middleRight.y>e.corners.bottom?Ae.Three:t.corners.rightr.offsetY+e.margin.right||void 0===r&&t.corners.top>e.corners.middleRight.y||void 0!==r&&(void 0!==i&&i.offsetXr.offsetX||void 0===r&&t.corners.left>e.corners.topCenter.x?Ae.Four:Ae.Two:void 0!==s&&Math.abs(t.corners.right-e.corners.left)<=5&&Math.abs(s.offsetY-e.corners.top)<=5||void 0!==r&&t.corners.right=25&&t.corners.middleRight.y+t.margin.righte.corners.bottom+e.margin.bottom||void 0===o&&t.corners.middleRight.y>e.corners.bottom+e.margin.bottom?t.corners.top>e.corners.bottom?void 0!==a&&t.corners.right+t.margin.righta.offsetX||void 0===a&&t.corners.left>e.corners.bottomCenter.x?Ae.Four:Ae.Two:void 0!==o&&Math.abs(t.corners.right-e.corners.left)<=25&&Math.abs(o.offsetY-e.corners.bottom)<=25?Ae.Two:Ae.Four}(n,t,e,s);else if("Bottom"===t.direction&&"Top"===e.direction)a=function Hre(n,t,e){var r=t.point.x-e.point.x,s=Ga(n);return t.corners.right+se.corners.right+s||("Bezier"!==n.type||e.corners.top-t.corners.bottom<=2*s&&e.corners.top-t.corners.bottom>=5)&&(s=0),t.margin={left:s,right:s,top:s,bottom:s},e.margin={left:s,right:s,top:s,bottom:s},0===r&&t.corners.bottome.corners.right+e.margin.right||void 0===i&&t.corners.bottomCenter.x>e.corners.right+e.margin.right?Ae.Three:t.corners.bottomr.offsetX||void 0===r&&t.corners.left>e.corners.left||void 0!==r&&t.corners.right+t.margin.righte.corners.bottom?Ae.Five:0===s||0===o?Ae.One:Ae.Three}(n,t,e)}else"Bottom"===t.direction&&"Left"===e.direction?a=function Bre(n,t,e,i){var r=n.sourcePortWrapper,s=n.targetPortWrapper,o=Ga(n);if(e.margin={left:o,right:o,top:o,bottom:o},t.margin={top:o,bottom:o,left:o,right:o},i){var l=r;r=s,s=l}return void 0!==r&&r.offsetXs.offsetY||void 0===s&&t.corners.top>e.corners.middleLeft.y?Ae.Four:Ae.Two:void 0!==s&&Math.abs(t.corners.right-e.corners.left)<=25&&Math.abs(s.offsetY-t.corners.bottom)<=25?Ae.Two:Ae.Four}(n,t,e,s):"Left"===t.direction&&"Left"===e.direction?a=function Ure(n,t,e){var i=n.sourcePortWrapper,r=n.targetPortWrapper,s=Ga(n);t.margin={left:s,right:s,top:s,bottom:s},e.margin={left:s,right:s,top:s,bottom:s};var o=Math.round(Math.abs(t.point.x-e.point.x)),a=Math.round(Math.abs(t.point.y-e.point.y));return t.corners.leftr.offsetY||void 0===r&&t.corners.top-t.margin.top>e.corners.middleLeft.y?Ae.Three:t.corners.righte.corners.bottom+e.margin.bottom||void 0===i&&t.corners.middleLeft.y>e.corners.bottom+e.margin.bottom?Ae.Three:t.corners.left>e.corners.right?Ae.Five:0===o||0===a?Ae.One:Ae.Three}(n,t,e):"Left"===t.direction&&"Top"===e.direction?a=function _re(n,t,e,i){var s=n.sourcePortWrapper,o=Ga(n);e.margin={left:o,right:o,top:o,bottom:o},t.margin={top:o,bottom:o,left:o,right:o};var a=n.targetPortWrapper,l={x:Math.min(t.point.x,t.corners.left),y:t.point.y},h={x:e.point.x,y:Math.min(e.point.y,e.corners.top)};if(i){var c=s;s=a,a=c;var d=l;l=h,h=d}return void 0!==s&&s.offsetYa.offsetX||void 0===a&&t.corners.left-t.margin.left>e.corners.topCenter.x?Ae.Two:Ae.Four:void 0!==a&&t.corners.rightr.offsetX||void 0===r&&t.corners.left>e.corners.left||void 0!==r&&t.corners.right+t.margin.righte.corners.right+e.margin.right||void 0===i&&t.corners.left>e.corners.right||void 0!==i&&i.offsetXe.corners.bottom?Ae.Five:0===s||0===o?Ae.One:Ae.Three}(n,t,e));return s&&x3(t,e),o=function Vre(n,t,e,i,r,s){var l,d,h=n.sourceWrapper.corners,c=n.targetWrapper.corners,u=20,p={corners:e.corners,point:e.point,direction:e.direction,margin:e.margin},f={corners:i.corners,point:i.point,direction:i.direction,margin:i.margin};if(!(p.direction===f.direction&&t!==Ae.Five||p.direction!==ls(f.direction)&&t!==Ae.Three))switch(p.direction){case"Left":h.middleLeft.x>c.middleRight.x&&(d=(h.middleLeft.x-c.middleRight.x)/2,u=s?d:Math.min(u,d));break;case"Right":h.middleRight.xc.bottomCenter.y&&(d=(h.topCenter.y-c.bottomCenter.y)/2,u=s?d:Math.min(u,d));break;case"Bottom":h.bottomCenter.yp&&hp)&&o>c&&o<=d&&e>=20&&(s=n.point.x-t.corners.left+s),i&&n.direction===t.direction&&n.corners.left>t.corners.left&&n.corners.left-t.corners.right>=20&&(s=(n.corners.left-t.corners.right)/2),f=Bn(n.point,s,180);break;case"Top":(o>c&&oc)&&h>p&&h<=u&&e>=20&&(s=n.point.y-t.corners.top+s),i&&n.direction===t.direction&&n.corners.top>t.corners.top&&n.corners.top-t.corners.bottom>=20&&(s=(n.corners.top-t.corners.bottom)/2),f=Bn(n.point,s,270);break;case"Right":(h>p&&hp)&&a=c&&e>=20&&(s=t.corners.right-n.point.x+s),i&&n.direction===t.direction&&n.corners.right=20&&(s=(t.corners.left-n.corners.right)/2),f=Bn(n.point,s,0);break;case"Bottom":(o>c&&oc)&&l=p&&e>=20&&(s=t.corners.bottom-n.point.y+s),i&&n.direction===t.direction&&n.corners.bottom=20&&(s=(t.corners.top-n.corners.bottom)/2),f=Bn(n.point,s,90)}r=[n.point,f];var g=void 0;if("Top"===n.direction||"Bottom"===n.direction){var v=n.direction;n.direction=f.x>t.point.x?"Left":"Right",n.point=f,r=AI(n,t,v,r,g=i?.5*Math.abs(f.x-t.point.x):g,i)}else v=n.direction,n.direction=f.y>t.point.y?"Top":"Bottom",n.point=f,r=AI(n,t,v,r,g=i?.5*Math.abs(f.y-t.point.y):g,i);return r}(p,f,u,g)),l}(n,a,t,e,i,r),"Bezier"===n.type&&function Yre(n,t,e){if("Bezier"===n.type)if(0===n.segments.length){var i=e[0],r=e[e.length-1];if(t===Ae.One){var s=Math.min(20,.5*z.findLength(i,r)),o={angle:Gt(i,r),distance:s},a={angle:Gt(r,i),distance:s},l=z.direction(i,r),c=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,orientation:"Left"===l||"Right"===l?"Horizontal":"Vertical"},!0);n.segments.push(c)}else if(t===Ae.Two)o={angle:Gt(i,d=e[1]),distance:.5*z.findLength(i,d)},a={angle:Gt(r,d),distance:.5*z.findLength(r,d)},l=z.direction(i,d),c=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,orientation:"Left"===l||"Right"===l?"Horizontal":"Vertical"},!0),n.segments.push(c);else if(t===Ae.Three){var d={x:.5*((u=e[1]).x+(p=e[e.length-2]).x),y:.5*(u.y+p.y)},f=(o={angle:Gt(i,u),distance:.5*z.findLength(i,u)},a={angle:Gt(d,u),distance:.5*z.findLength(d,u)},z.direction(i,u)),v=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,point:d,orientation:"Left"===f||"Right"===f?"Horizontal":"Vertical"},!0);n.segments.push(v);var y={angle:Gt(d,p),distance:.5*z.findLength(d,p)},S={angle:Gt(r,p),distance:.5*z.findLength(r,p)},b=z.direction(d,p),w=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:y,vector2:S,orientation:"Left"===b||"Right"===b?"Horizontal":"Vertical"},!0);n.segments.push(w)}else if(t===Ae.Four){var D={x:.5*((u=e[1]).x+(p=e[2]).x),y:.5*(u.y+p.y)},A={x:.5*(p.x+(C=e[3]).x),y:.5*(p.y+C.y)};o={angle:Gt(i,u),distance:.5*z.findLength(i,u)},a={angle:Gt(D,u),distance:.5*z.findLength(D,u)},f=z.direction(i,u),v=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,point:D,orientation:"Left"===f||"Right"===f?"Horizontal":"Vertical"},!0),n.segments.push(v),y={angle:Gt(D,p),distance:.5*z.findLength(D,p)},S={angle:Gt(A,p),distance:.5*z.findLength(A,p)},b=z.direction(D,p),w=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:y,vector2:S,point:A,orientation:"Left"===b||"Right"===b?"Horizontal":"Vertical"},!0),n.segments.push(w);var x={angle:Gt(A,C),distance:.5*z.findLength(A,C)},R={angle:Gt(r,C),distance:.5*z.findLength(r,C)},L=z.direction(A,C),N=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:x,vector2:R,orientation:"Left"===L||"Right"===L?"Horizontal":"Vertical"},!0);n.segments.push(N)}else if(t===Ae.Five){var u,p,C,T=e[4],P=(D={x:.5*((u=e[1]).x+(p=e[2]).x),y:.5*(u.y+p.y)},A={x:.5*(p.x+(C=e[3]).x),y:.5*(p.y+C.y)},{x:.5*(C.x+T.x),y:.5*(C.y+T.y)});o={angle:Gt(i,u),distance:.5*z.findLength(i,u)},a={angle:Gt(D,u),distance:.5*z.findLength(D,u)},f=z.direction(i,u),v=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,point:D,orientation:"Left"===f||"Right"===f?"Horizontal":"Vertical"},!0),n.segments.push(v),y={angle:Gt(D,p),distance:.5*z.findLength(D,p)},S={angle:Gt(A,p),distance:.5*z.findLength(A,p)},b=z.direction(D,p),w=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:y,vector2:S,point:A,orientation:"Left"===b||"Right"===b?"Horizontal":"Vertical"},!0),n.segments.push(w),x={angle:Gt(A,C),distance:.5*z.findLength(A,C)},R={angle:Gt(P,C),distance:.5*z.findLength(P,C)},L=z.direction(A,C),N=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:x,vector2:R,point:P,orientation:"Left"===L||"Right"===L?"Horizontal":"Vertical"},!0),n.segments.push(N);var _={angle:Gt(P,T),distance:.5*z.findLength(P,T)},B={angle:Gt(r,T),distance:.5*z.findLength(r,T)},j=z.direction(P,T),oe=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:_,vector2:B,orientation:"Left"===j||"Right"===j?"Horizontal":"Vertical"},!0);n.segments.push(oe)}else c=new ps(n,"segments",{type:"Bezier"},!0),n.segments.push(c)}else for(var ue=0;ue=13?13:n.connectorSpacing<=1?1:n.connectorSpacing}function Gt(n,t){var i=z.findLength({x:t.x,y:n.y},t),r=z.findLength(t,n),s=Math.asin(i/r);return s=180*s/Math.PI,n.xt.y&&(s=360-s):s=n.y0)for(var l=1;lc)&&(s=c,a=h),s>=0&&s<=1)break}}return a}function w3(n,t){var c,d,u,p,f,g,S,b,M,w,D,e=n.x1,i=n.y1,r=n.x2,s=n.y2,o=t.x1,a=t.y1,l=t.x2,h=t.y2;if(w=(c=s-i)*l+(u=e-r)*h+(f=r*i-e*s),0!==(M=c*o+u*a+f)&&0!==w&&C3(M,w)||(b=(d=h-a)*r+(p=o-l)*s+(g=l*a-o*h),0!==(S=d*e+p*i+g)&&0!==b&&C3(S,b)))return null;var A=c*p-d*u;return 0===A?null:(A<0?-A/2:A/2,0,{x:(D=u*g-p*f)<0?(D-0)/A:(D+0)/A,y:(D=d*f-c*g)<0?(D-0)/A:(D+0)/A})}function C3(n,t){return n*t>=0}function E3(n,t,e){switch(t.direction){case"Left":t.point.x>n.left&&(e=t.point.x-n.left>e?t.point.x-n.left+e:e);break;case"Right":t.point.xe?n.right-t.point.x+e:e);break;case"Top":t.point.y>n.top&&(e=t.point.y-n.top>e?t.point.y-n.top+e:e);break;case"Bottom":t.point.ye?n.bottom-t.point.y+e:e)}return e}function Nl(n,t){var e;switch(n.direction){case"Left":case"Right":var i={x:t.point.x,y:n.point.y};e=z.equals(n.point,i)||z.equals(t.point,i)?[n.point,t.point]:[n.point,i,t.point];break;case"Top":case"Bottom":var r={x:n.point.x,y:t.point.y};e=z.equals(n.point,r)||z.equals(t.point,r)?[n.point,t.point]:[n.point,r,t.point]}return e}function Ys(n,t,e,i,r,s){void 0===s&&(s=!1),i||(i=20),s&&t.direction!==e.direction&&(i="Left"===t.direction||"Right"===t.direction?Math.floor(.5*Math.abs(t.point.x-e.point.x)):Math.floor(.5*Math.abs(t.point.y-e.point.y)));var l,h,u,o=n.sourcePortWrapper,c=e.point.x-t.point.x,d=e.point.y-t.point.y;if(!r&&(Math.abs(c)<.001||Math.abs(d)<.001)&&void 0===e.direction)return[t.point,e.point];if(void 0===n.targetWrapper&&Math.abs(c)<=31&&Math.abs(d)<=31){if("Left"===t.direction||"Right"===t.direction?Math.abs(d)<12&&(t.direction=t.point.y>e.point.y?"Top":"Bottom"):Math.abs(c)<12&&(t.direction=t.point.x>e.point.x?"Left":"Right"),Math.abs(c)>12||Math.abs(d)>12)return Nl(t,e);i+=5}return"Left"===t.direction||"Right"===t.direction?("Right"===t.direction?(void 0!==e.direction&&"Right"===e.direction&&(i=Math.max(t.point.x,e.point.x)-t.point.x+i),t.point.x>e.point.x&&void 0===o&&(i=-i)):(void 0!==e.direction&&"Left"===e.direction&&(i=t.point.x-Math.min(t.point.x,e.point.x)+i),(t.point.x>e.point.x||void 0!==o||"Left"===t.direction)&&(i=-i)),u=e.point.y-t.point.y,l=Bn(t.point,i,0),0!=(u=e.point.y-l.y)&&(h=Bn(l,e.point.y-l.y,90))):("Top"===t.direction||"Bottom"===t.direction)&&("Bottom"===t.direction?void 0!==e.direction&&"Bottom"===e.direction&&(i=Math.max(t.point.y,e.point.y)-t.point.y+i):(void 0!==e.direction&&"Top"===e.direction&&(i=t.point.y-Math.min(t.point.y,e.point.y)+i),(t.point.y>e.point.y||void 0!==o||"Top"===t.direction)&&(i=-i)),u=e.point.x-t.point.x,l=Bn(t.point,i,90),0!=(u=e.point.x-l.x)&&(h=Bn(l,e.point.x-l.x,0))),0===u?[t.point,e.point]:[t.point,l,h,e.point]}function AI(n,t,e,i,r,s){var o;switch(void 0===r&&(r=20),void 0===s&&(s=!1),void 0===e?(n.margin={left:2,right:2,top:2,bottom:2},t.margin={left:0,right:5,top:0,bottom:5},s&&(n.margin={left:10,right:10,top:10,bottom:10},t.margin={left:10,right:10,top:10,bottom:10},"Left"===n.direction?(r=Rx(n,t,e,r),n.corners.left-t.corners.right>=5&&(r=Math.abs(n.point.x-n.corners.left)+.5*Math.floor(n.corners.left-t.corners.right))):"Right"===n.direction?(r=Hx(n,t,r,e),t.corners.left-n.corners.right>=5&&(r=Math.abs(n.point.x-n.corners.right)+.5*Math.floor(t.corners.left-n.corners.right))):"Top"===n.direction?(r=zx(n,t,e,r),n.corners.top-t.corners.bottom>=5&&(r=Math.abs(n.point.y-n.corners.top)+.5*Math.floor(n.corners.top-t.corners.bottom))):"Bottom"===n.direction&&(r=Bx(n,t,r,e),t.corners.top-n.corners.bottom>=5&&(r=Math.abs(n.point.y-n.corners.bottom)+.5*Math.floor(t.corners.top-n.corners.bottom))))):("Bottom"===n.direction?s?t.corners.top-n.corners.bottom<20&&(r=t.corners.bottom-n.point.y+25):t.corners.top>n.corners.bottom&&t.corners.top-n.corners.bottom<20&&(r=(t.corners.top-n.corners.bottom)/2):"Top"===n.direction?s?n.corners.top-t.corners.bottom<20&&(r=n.point.y-t.corners.top+25):t.corners.bottomn.corners.right&&t.corners.left-n.corners.right<20&&(r=(t.corners.left-n.corners.right)/2):"Left"===n.direction&&(s?n.corners.left-t.corners.right<20&&(r=n.point.x-t.corners.left+25):t.corners.rightt.point.y||"Top"===t.direction&&n.point.yt.point.x||"Left"===t.direction&&n.point.xh||e.corners.top-e.margin.top<=i.point.y&&e.corners.bottom+e.margin.bottom>=i.point.y))if(!s||"Top"!==e.direction&&"Bottom"!==e.direction)c=Math.min(Math.abs(i.corners.left-e.corners.right)/2,20),h=e.corners.right-n.x+c;else{var c=Math.abs(i.corners.left-e.corners.right)/2;h=e.corners.right-n.x+c}else h="Top"===e.direction&&n.y>i.point.y||"Bottom"===e.direction&&n.y=e.corners.left-e.margin.left&&n.x<=e.corners.right+e.margin.right?Math.min(i.corners.left,e.corners.left)-n.x-20:i.corners.left-n.x-20;break;case"Right":if(e.corners.left-e.margin.left>i.corners.right+i.margin.right&&(e.corners.left-e.margin.right-i.corners.right>h||e.corners.top-e.margin.top<=i.point.y&&e.corners.bottom+e.margin.bottom>=i.point.y))if(!s||"Top"!==e.direction&&"Bottom"!==e.direction)c=Math.min(Math.abs(e.corners.left-i.corners.right)/2,20),h=e.corners.left-n.x-c;else{c=Math.abs(e.corners.left-i.corners.right)/2;h=e.corners.left-n.x-c}else h="Top"===e.direction&&n.y>i.point.y||"Bottom"===e.direction&&n.y=e.corners.left-e.margin.left&&n.x<=e.corners.right+e.margin.right?Math.max(i.corners.right,e.corners.right)-n.x+20:i.corners.right-n.x+20}o=Bn(n,h,0),a=Bn(o,i.point.y-n.y,90),l=i.point}else if("vertical"===t){switch(i.direction){case"Top":e.corners.bottom+e.margin.bottomh||e.corners.left-e.margin.left<=i.point.x&&e.corners.right+e.margin.right>=i.point.x)?!s||"Right"!==e.direction&&"Left"!==e.direction?(c=Math.min(Math.abs(i.corners.top-e.corners.bottom)/2,20),h=e.corners.bottom-n.y+c):(c=Math.abs(i.corners.top-e.corners.bottom)/2,h=e.corners.bottom-n.y+c):h="Left"===e.direction&&n.x>i.point.x||"Right"===e.direction&&n.x=e.corners.top-e.margin.top&&n.y<=e.corners.bottom+e.margin.bottom?Math.min(i.corners.top,e.corners.top)-n.y-20:i.corners.top-n.y-20;break;case"Bottom":e.corners.top-e.margin.top>i.corners.bottom+i.margin.bottom&&(e.corners.top-e.margin.top-i.corners.bottom>h||e.corners.left-e.margin.left<=i.point.x&&e.corners.right+e.margin.right>=i.point.x)?!s||"Right"!==e.direction&&"Left"!==e.direction?(c=Math.min(Math.abs(e.corners.top-i.corners.bottom)/2,20),h=e.corners.top-n.y-c):(c=Math.abs(e.corners.top-i.corners.bottom)/2,h=e.corners.top-n.y-c):h="Left"===e.direction&&n.x>i.point.x||"Right"===e.direction&&n.x=e.corners.top-e.margin.top&&n.y<=e.corners.bottom+e.margin.bottom?Math.max(i.corners.bottom,e.corners.bottom)-n.y+20:i.corners.bottom-n.y+20}o=Bn(n,h,90),a=Bn(o,i.point.x-n.x,0),l=i.point}r.push(o),r.push(a),r.push(l)}function zx(n,t,e,i){return n.corners.top-n.margin.top>t.corners.top+t.margin.top&&n.corners.top-n.margin.top<=t.corners.bottom+t.margin.bottom?(("Right"===t.direction&&n.point.xt.point.x)&&(i+=n.corners.top-t.corners.top),i+=n.point.y-n.corners.top):i+=void 0!==e&&"Left"!==e&&"Right"===t.direction&&n.point.xt.corners.left-t.margin.left&&n.corners.left-n.margin.left<=t.corners.right+t.margin.right?(("Bottom"===t.direction&&n.point.yt.point.y)&&(i+=n.corners.left-t.corners.left),i+=n.point.x-n.corners.left):i+=void 0!==e&&"Top"!==e&&"Bottom"===t.direction&&n.point.y=t.corners.left-t.margin.left?(("Bottom"===t.direction&&n.point.yt.point.y)&&(e+=t.corners.right-n.corners.right),e+=n.corners.right-n.point.x):e+=void 0!==i&&"Top"!==i&&"Bottom"===t.direction&&n.point.y=t.corners.top-t.margin.top?(("Right"===t.direction&&n.point.xt.point.x)&&(e+=t.corners.bottom-n.corners.bottom),e+=n.corners.bottom-n.point.y):e+=void 0!==i&&"Left"!==i&&"Right"===t.direction&&n.point.xf&&d=u&&d=p&&d<=f?"Left":"Right"}function ls(n){switch(n){case"Top":return"Bottom";case"Bottom":return"Top";case"Left":return"Right";case"Right":return"Left"}return"auto"}var A3=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Nc=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},LI=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return A3(t,n),Nc([I()],t.prototype,"width",void 0),Nc([I()],t.prototype,"height",void 0),t}(Ee),Gre=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return A3(t,n),Nc([I()],t.prototype,"width",void 0),Nc([I()],t.prototype,"height",void 0),Nc([I()],t.prototype,"fit",void 0),Nc([I()],t.prototype,"description",void 0),Nc([I()],t.prototype,"template",void 0),Nc([I()],t.prototype,"tooltip",void 0),t}(Ee),Xre=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Ol=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},L3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Xre(t,n),Ol([I("")],t.prototype,"id",void 0),Ol([I(Number.MIN_VALUE)],t.prototype,"zIndex",void 0),Ol([re({},$n)],t.prototype,"margin",void 0),Ol([I(!0)],t.prototype,"visible",void 0),Ol([re({},xd)],t.prototype,"tooltip",void 0),Ol([I(!1)],t.prototype,"excludeFromLayout",void 0),Ol([I()],t.prototype,"addInfo",void 0),Ol([I("None")],t.prototype,"flip",void 0),Ol([I("All")],t.prototype,"flipMode",void 0),Ol([re({},Gre)],t.prototype,"symbolInfo",void 0),t}(Ee),qre=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Jn=function(n){function t(e,i,r,s){var o=n.call(this)||this;return o.data="",o.nodeId="",o.annotationId="",o.diagramId="",o.diagramId=i,o.nodeId=e,o.annotationId=r,o.templateFn=GF(s),o}return qre(t,n),t.prototype.getNodeTemplate=function(){return this.templateFn},Object.defineProperty(t.prototype,"content",{get:function(){return this.data},set:function(e){this.data=e,this.canReset||(this.canReset=!0,this.isTemplate||(this.template=Bh(this,!0)),this.canReset=!1,this.isDirt=!0)},enumerable:!0,configurable:!0}),t}(as),Fx=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),hs=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},N3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Fx(t,n),hs([I("")],t.prototype,"id",void 0),hs([I("transparent")],t.prototype,"fill",void 0),hs([I("black")],t.prototype,"iconStrokeColor",void 0),hs([I(0)],t.prototype,"iconStrokeWidth",void 0),hs([I(!0)],t.prototype,"visibility",void 0),hs([I(10)],t.prototype,"width",void 0),hs([I(10)],t.prototype,"height",void 0),hs([I("transparent")],t.prototype,"handleStrokeColor",void 0),hs([I(1)],t.prototype,"handleStrokeWidth",void 0),hs([I("")],t.prototype,"pathData",void 0),hs([I(0)],t.prototype,"cornerRadius",void 0),hs([re({left:0,right:0,top:0,bottom:0},$n)],t.prototype,"padding",void 0),hs([re({},xd)],t.prototype,"tooltip",void 0),t}(Ee),O3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Fx(t,n),hs([re({x:0,y:0},z)],t.prototype,"offset",void 0),hs([re({},$n)],t.prototype,"margin",void 0),t}(N3),NI=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Fx(t,n),hs([I(.5)],t.prototype,"offset",void 0),hs([I("Center")],t.prototype,"alignment",void 0),hs([re({x:0,y:0},z)],t.prototype,"displacement",void 0),t}(N3);function Td(n){return n?n instanceof Zn||n instanceof Nr?n.constraints&Lr.Select:n instanceof de?n.constraints&qe.Select:n.constraints&ie.Select:1}function to(n){return n?n instanceof Zn||n instanceof Nr?n.constraints&Lr.Drag:n instanceof de?n.constraints&qe.Drag:n instanceof si?1:n.constraints&ie.Drag:1}function $re(n,t){return n instanceof de?n.constraints&qe.PointerEvents:n.constraints&ie.PointerEvents}function OI(n){return n instanceof de?n.constraints&qe.Delete:n.constraints&ie.Delete}function kI(n){return n.constraints&qe.DragSourceEnd}function PI(n){return n.constraints&qe.DragTargetEnd}function zI(n){return n.constraints&qe.DragSegmentThumb}function RI(n){return n instanceof Zn||n instanceof Nr?n.constraints&Lr.Rotate:n.constraints&ie.Rotate}function HI(n){return n.constraints&ie.Shadow}function da(n){return n instanceof te&&n.constraints&ie.InConnect?n.constraints&ie.InConnect:0}function Oh(n){return n&&n.constraints&&!(n.constraints&ri.None)&&n.constraints&ri.InConnect?n.constraints&ri.InConnect:0}function kh(n){return n instanceof te&&n.constraints&ie.OutConnect?n.constraints&ie.OutConnect:0}function Ad(n){return n&&n.constraints&&!(n.constraints&ri.None)&&n.constraints&ri.OutConnect?n.constraints&ri.OutConnect:0}function kl(n,t){var e=0;return n instanceof Zn||n instanceof Nr?e=n.constraints&Lr.Resize:n&&("SouthEast"===t?e=n.constraints&ie.ResizeSouthEast:"East"===t?e=n.constraints&ie.ResizeEast:"NorthEast"===t?e=n.constraints&ie.ResizeNorthEast:"South"===t?e=n.constraints&ie.ResizeSouth:"North"===t?e=n.constraints&ie.ResizeNorth:"SouthWest"===t?e=n.constraints&ie.ResizeSouthWest:"West"===t?e=n.constraints&ie.ResizeWest:"NorthWest"===t&&(e=n.constraints&ie.ResizeNorthWest)),e}function BI(n){return n instanceof de?n.constraints&qe.AllowDrop:n.constraints&ie.AllowDrop}function Ds(n){return n.constraints&rt.Virtualization}function jv(n){return n.tool&Ci.SingleSelect}function Vv(n){return n.tool&Ci.MultipleSelect}function Oc(n){return n.tool&Ci.ZoomPan}function FI(n){return n.tool&Ci.ContinuousDraw}function k3(n){return n.tool&Ci.DrawOnce}function _I(n){return n.tool&Ci.SingleSelect||n.tool&Ci.MultipleSelect}function Wv(n){return n.constraints&rt.UserInteraction}function P3(n){return n.constraints&rt.ZoomTextEdit}function Yv(n){return function ine(n){return n.constraints&rt.ApiUpdate}(n)||n.diagramActions&ee.ToolAction}function _x(n,t){return n.constraints&ri.Draw}function Ux(n,t){return n.constraints&ri.Drag}function UI(n){return!(n&Qa.DrawSelectorBorder)}function z3(n){return!!(n&Qa.PreventRenderSelector)}var jx=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Qv=function(n){function t(){var e=null!==n&&n.apply(this,arguments)||this;return e.childTable=[],e.cellStyle={},e.desiredRowHeight=[],e.desiredCellWidth=[],e}return jx(t,n),t.prototype.rowDefinitions=function(){return this.rowDefns},t.prototype.columnDefinitions=function(){return this.colDefns},t.prototype.addObject=function(e,i,r,s,o){if(this.rows.length>=i){var a=this.rows[parseInt(i.toString(),10)];if(a.cells.length>r){o=o||1,s=s||1;var l=a.cells[parseInt(r.toString(),10)];l.columnSpan=Math.max(o,l.columnSpan),l.rowSpan=Math.max(s,l.rowSpan);var h=new ane;(h=e).rowId=i,h.columnId=r,h.columnSpan=o,this.childTable[h.id]=h,this.addObjectToCell(h,l)}}},t.prototype.addObjectToCell=function(e,i){i.children||(i.children=[]),e.style.strokeColor="black",e.style.strokeWidth=1,i.children.push(e)},t.prototype.updateProperties=function(e,i,r,s){this.offsetX=e,this.offsetY=i,this.width=r,this.height=s},t.prototype.setDefinitions=function(e,i){this.rowDefns=e,this.colDefns=i,this.children=[],this.rows=this.rows||[];for(var r=0;r0){for(var h=0;hi&&this.updateRowHeight(e,l,!1)}},t.prototype.setTextRefresh=function(e){if(e.children&&e.children.length)for(var i=e.children,r=0;ri&&this.updateColumnWidth(e,a,!1)}},t.prototype.calculateCellWidth=function(e){for(var i,r,s,o=0;os.bounds.width&&(0===s.children.length||void 0===s.children[0].maxWidth)?s.outerBounds.width:s.bounds.width,i=i?is.bounds.height?s.outerBounds.height:s.bounds.height,i=i?i0?e.children[0]:void 0;if(a&&1===e.columnSpan){o="Width"===i?a.bounds.right:a.bounds.bottom,s||(s="Width"===i?a.bounds.width:a.bounds.height);for(var l=0;lo){var d=c-o+("Width"===i?a.bounds.width:a.bounds.height);s&&(s=s0?this.rowDefns.splice(e,0,i):this.rowDefns.push(i);var s=new R3;s.cells=[],(new Ld).width=this.width,this.addCellInRow(this.colDefns,i,s),e>this.rows.length-1?this.rows.push(s):this.rows.splice(e,0,s),r&&(this.measure(new me(this.width,this.height)),this.arrange(this.desiredSize))},t.prototype.addColumn=function(e,i,r){var s,o,a,l,h=this.rows;this.colDefns.length>0?this.colDefns.splice(e,0,i):this.colDefns.push(i),void 0!==this.width&&(this.width+=i.width);for(var c=0;cs.cells.length-1?s.cells.push(l):s.cells.splice(e,0,l),this.children.push(l);r&&(this.measure(new me(this.width,this.height)),this.arrange(this.desiredSize))},t.prototype.removeRow=function(e){var i,r,o=this.rows[parseInt(e.toString(),10)];this.height-=this.rowDefns[parseInt(e.toString(),10)].height;for(var a=0;a0){var r=0,s=0;i=new me(0,0),this.calculateSize();for(var o=0,a=this.rows;o0){for(var o=this.offsetX-e.width*this.pivot.x,a=this.offsetY-e.height*this.pivot.y,l=o,h=0,c=this.rows;h1&&this.children.splice(this.children.indexOf(f)+1,f.columnSpan-1),f.rowSpan>1)for(y=s,S=0;y+f.rowSpan-10){for(var c=0;c0?1:0,v=0;v0||a.outEdges.length>0))for(p=a.inEdges.concat(a.outEdges),s=0;s0)for(o=0;o1)for(a=1;a0))if(h=n.wrapper.children[0],"Horizontal"===e.orientation)for(o=e.header&&e.hasHeader?h.rows[1]:h.rows[0],r=0;r0){var e=void 0;t.lineRoutingModule&&t.constraints&rt.LineRouting&&t.lineRoutingModule.renderVirtualRegion(t,!0);for(var i=0;i0?o+1:o)].height=t.wrapper.height;else if(t.isPhase)for(l[t.rowIndex-o].offset=t.wrapper.height,f=0;f0?1:0)].width=t.wrapper.width}function VI(n,t){var i=n.shape,r=i.header&&i.hasHeader?1:0;return"Horizontal"===i.orientation?t.rowIndex-(r+=i.phases.length>0?1:0):t.columnIndex-(i.phaseSize&&i.phases.length>0?1:0)}function WI(n){var t=0,e=n.shape;return"Horizontal"===e.orientation&&(t=e.header&&e.hasHeader?1:0),e.phases.length>0&&e.phaseSize&&(t+=1),t}function YI(n,t,e,i){var r=n.shape;if(r.phases.length>0){var s=t.nameTable[r.phases[parseInt(i.toString(),10)].header.id];s&&s.maxWidth0?u+1:u);var w=kc(n,o),C=void 0!==i?i:l.lanes.length;if(u+=C,r={element:M,cause:n.diagramActions,diagramAction:n.getDiagramAction(n.diagramActions),state:"Changing",type:"Addition",cancel:!1,laneIndex:C},n.triggerEvent(Ce.collectionChange,r),!r.cancel){if(c){var D=new Gv;D.height=e.height,o.addRow(u,D,!1),s.height=void 0!==s.height?s.height+e.height:s.height,s.wrapper.height=o.height=s.height}else{var A=new Ld;A.width=e.width,o.addColumn(C+1,A,!1),s.width&&(s.width+=e.width,s.wrapper.width=o.width=s.width),n.diagramActions&ee.UndoRedo||(o.rows[0].cells[0].columnSpan+=1)}n.diagramActions&ee.UndoRedo||(M.id=""===M.id?Qe():M.id),void 0!==i?l.lanes.splice(i,0,M):l.lanes.push(M),r={element:M,cause:n.diagramActions,diagramAction:n.getDiagramAction(n.diagramActions),state:"Changed",type:"Addition",cancel:!1,laneIndex:C},n.triggerEvent(Ce.collectionChange,r),B3(o,n,s,u,C,c),h="Horizontal"===l.orientation?n.nameTable[o.rows[parseInt(u.toString(),10)].cells[0].children[0].id]:l.header&&l.hasHeader?n.nameTable[o.rows[1].cells[parseInt(u.toString(),10)].children[0].id]:n.nameTable[o.rows[0].cells[parseInt(u.toString(),10)].children[0].id],n.diagramActions&ee.UndoRedo||(d={type:"LaneCollectionChanged",changeType:"Insert",undoObject:$(M),redoObject:$(h),category:"Internal"},n.addHistoryEntry(d)),$p(n,s,"Horizontal"===l.orientation?u:l.header&&l.hasHeader?1:0),qp(s),Pc(n,s);var R=!1;if((p=e.children)&&p.length>0)for(f=0;f0){var o=t.children[0],a=n.nameTable[o.id];(function vne(n,t,e){return n.left-(e.left||0)<=t.x&&n.right+(e.right||0)>=t.x&&n.top-(e.top||0)<=t.y&&n.bottom+(e.bottom||0)>=t.y})(o.bounds,e,r)&&(n.addChild(a,i),s=!0)}return s}function mne(n,t,e){if("SwimLane"===t.shape.type){var i=void 0,r=void 0,s=void 0,a=void 0,l=void 0,h=void 0,c=t.wrapper.bounds.x,d=t.wrapper.bounds.y,u=t.shape,p=u.padding,f=u.phases,g=void 0,v=t.wrapper.children[0],y="Horizontal"===u.orientation;if(i=u.header&&u.hasHeader?0:-1,u.phases.length>0&&(i+=1),e.offset>(y?u.lanes[0].header.width:u.lanes[0].header.height)){for(h=0;he.offset){if(g=h>0?e.offset-(h>0?f[h-1]:s).offset:e.offset,y){var b=v.columnDefinitions()[parseInt(h.toString(),10)];b.width-=g,(a=n.nameTable[u.phases[parseInt(h.toString(),10)].header.id]).maxWidth=a.wrapper.maxWidth=b.width,v.updateColumnWidth(h,b.width,!1);var M=new Ld;M.width=g,l=h,v.addColumn(h,M,!1);break}var w=v.rowDefinitions()[h+i];w.height-=g,a=n.nameTable[u.phases[parseInt(h.toString(),10)].header.id],v.updateRowHeight(h+i,w.height,!1);var C=new Gv;C.height=g,l=h,v.addRow(h+i,C,!1);break}if(n.diagramActions&ee.UndoRedo&&void 0===l&&(D=n.historyManager.currentEntry.next).isLastPhase&&function yne(n,t,e,i,r,s){var a=t.shape.phases[n-2],l=e.previousPhase.offset;if(r){var h=i.columnDefinitions()[n-1],c=new Ld;n>1?(c.width=h.width-(l-a.offset),h.width=l-a.offset):(c.width=h.width-l,h.width=l),i.updateColumnWidth(n-1,h.width,!1),i.addColumn(n,c,!1)}else{h=i.rowDefinitions()[parseInt(n.toString(),10)];var d=new Gv;n>1?(d.height=e.undoObject.offset-l,h.height=l-a.offset):(d.height=h.height-l,h.height=l),i.updateRowHeight(n,h.height,!1),i.addRow(1+n,d,!1)}}(l=f.length,t,D,v,y),l>=0){var A=new pb(t.shape,"phases",e,!0);if(n.diagramActions&ee.UndoRedo||(A.id+=Qe()),u.phases.splice(l,0,A),Vx(v,n,t,i,y,l),y){if(r=n.nameTable[v.rows[parseInt(i.toString(),10)].cells[parseInt(l.toString(),10)].children[0].id],0===l&&u.header&&u.hasHeader){v.rows[0].cells[0].children=v.rows[0].cells[1].children,v.rows[0].cells[1].children=[];for(var x=v.rows[0],R=0;Rl+1){var O=n.nameTable[v.rows[parseInt(i.toString(),10)].cells[l+1].children[0].id];v.updateColumnWidth(l+1,L[l+1].width,!0,p),O.maxWidth=O.wrapper.maxWidth=L[l+1].width}t.width=t.wrapper.width=t.wrapper.children[0].width=v.width}else{r=n.nameTable[v.rows[i+l].cells[0].children[0].id];var N=v.rowDefinitions(),T=N[i+l].height;(function Ine(n,t,e,i,r){for(var o,a,l=e.rows[parseInt(i.toString(),10)],h=e.rows[i+1],c=e.rows[i-1],d=1;di+l+1&&v.updateRowHeight(i+l+1,T=N[i+l+1].height,!0,p),t.height=t.wrapper.height=t.wrapper.children[0].height=v.actualSize.height}if(qp(t),t.width=t.wrapper.actualSize.width,Pc(n,t),n.drag(t,c-t.wrapper.bounds.x,d-t.wrapper.bounds.y),jI(t,n),n.commandHandler.select(r),!(n.diagramActions&ee.UndoRedo)){var D={type:"PhaseCollectionChanged",changeType:"Insert",undoObject:$(A),redoObject:$(r),category:"Internal"};n.addHistoryEntry(D)}n.updateDiagramObject(t)}}}}function V3(n,t,e,i,r,s,o){var a,l,f,h=t.shape,c="Horizontal"===h.orientation,d=t.wrapper.children[0],g=c?s:o;e?(a=c?e.bounds.x+e.bounds.width:e.bounds.x,l=c?e.bounds.y:e.bounds.y+e.bounds.height):(a=d.bounds.x,l=r.bounds.y);var v=new Ne(a,l,i.desiredCellWidth,i.desiredCellHeight),S=Xv(n,0,t,{id:t.id+(c?h.lanes[g-2]:h.lanes[g-1]).id+Qe()[0],rowIndex:s,columnIndex:o,width:i.minWidth,height:i.minHeight,style:(c?h.lanes[g-2]:h.lanes[g-1]).style,constraints:ie.Default|ie.AllowDrop,container:{type:"Canvas",orientation:c?"Horizontal":"Vertical"}},!1,!1,!0);if(S.children[0].isCalculateDesiredSize=!1,d.addObject(S,s,o),r&&r.children&&r.children.length)for(f=0;f1)for(var f=1;fh.margin.left&&(h.margin.left=p)):(h.margin.top-=e.desiredCellHeight,p>h.margin.top&&(h.margin.top=p)))}(n,r,i,v,S,c,e)}function W3(n,t,e){if("SwimLane"===t.shape.type&&("ResizeSouth"===e||"ResizeEast"===e)){var i=t.shape,r=t.wrapper.children[0],s=void 0,o=void 0;"ResizeSouth"===e?"Vertical"===i.orientation?s=r.rows[r.rows.length-1].cells[0]:(o=r.rows.length-1,s=r.rows[parseInt(o.toString(),10)].cells[r.rows[parseInt(o.toString(),10)].cells.length-1]):(o=i.header&&i.hasHeader?1:0,s=r.rows[parseInt(o.toString(),10)].cells[r.rows[parseInt(o.toString(),10)].cells.length-1]),n.commandHandler.select(n.nameTable[s.children[0].id])}}function QI(n,t,e,i,r,s){var o,a,l,c,u,p,f,d=Qe(),g=n.shape,v=g.phases,y=n.offsetX-n.wrapper.actualSize.width/2,S=n.offsetY-n.wrapper.actualSize.height/2;if("Vertical"===g.orientation&&(S+=g.header&&g.hasHeader?g.header.height:0),!s)for(r||(n.id+=d,g&&g.header&&g.hasHeader?g.header.id+=d:g.header=void 0),o=0;v&&o0&&s.columnIndex>0||s.isLane)?(a=function Lne(n,t,e){for(var i=new Ne,r="SwimLane"===n.shape.type?n.wrapper.children[0].rows:n.wrapper.rows,s=e?1:0;s=0;a--)i?i.id===o.children[parseInt(a.toString(),10)].id&&o.children.splice(a,1):(n.removeDependentConnector(o.children[parseInt(a.toString(),10)]),n.diagramActions&ee.UndoRedo||(n.diagramActions=n.diagramActions|ee.UndoRedo,s=!0),n.remove(o.children[parseInt(a.toString(),10)]),o.children.splice(a,1),s&&(n.diagramActions=n.diagramActions&~ee.UndoRedo))}function Mne(n){return n.children[0]}function Zv(n,t){t&&(n.nodes.splice(n.nodes.indexOf(t),1),n.removeFromAQuad(t),n.removeObjectsFromLayer(t),delete n.nameTable[t.id],n.removeElements(t))}function Q3(n,t,e,i){var r;if("SwimLane"===e.shape.type){var s=e.shape,o=void 0;if(1===s.lanes.length)n.remove(e);else{var a=e.wrapper.bounds.x,l=e.wrapper.bounds.y,h=void 0,c=void 0,d=void 0,u=void 0,f=e.wrapper.children[0];if(o=i?s.lanes.indexOf(i):VI(e,t),r={element:t,cause:n.diagramActions,diagramAction:n.getDiagramAction(n.diagramActions),state:"Changing",type:"Removal",cancel:!1,laneIndex:o},n.triggerEvent(Ce.collectionChange,r),!r.cancel){var g=s.lanes[parseInt(o.toString(),10)],v=g.children;g.children=[];for(var y=0;y0)for(u=0;u0)for(u=0;u0)for(e=0;e1){c===l.phases.length-1&&(o=!0,a=$(l.phases[c-1]));var u=$(l.phases[parseInt(c.toString(),10)]);if(l.phases.splice(c,1),!(n.diagramActions&ee.UndoRedo)){var p={type:"PhaseCollectionChanged",changeType:"Remove",undoObject:u,previousPhase:a,redoObject:$(t),category:"Internal",isLastPhase:o};n.addHistoryEntry(p)}"Horizontal"===l.orientation?function Cne(n,t,e,i){var r,s,o,a,l,h,c,d,u,p,f,g;for(i=void 0!==i?i:e.columnIndex,c=0;c1&&(s=r.cells[parseInt(i.toString(),10)],l=(o=r.cells.length-1===i?r.cells[i-1]:r.cells[i+1]).children[0],s.children.length>0))if(f=n.nameTable[(a=s.children[0]).id],0===o.children.length&&s.children.length>0)o.children=s.children,o.columnSpan=s.columnSpan-1;else{for(d=0;d0){var M=s.children[0],w=n.nameTable[M.id];if(i=e.x&&a.bounds.y<=e.y&&a.bounds.bottom>=e.y)&&!(t.constraints&ie.AllowMovingOutsideLane)){var l=$(t);n.clearSelection(),$3(n,t),t.parentId="",t.parentObj=n,t.propName="nodes";var h={type:"ChildCollectionChanged",category:"Internal",undoObject:l,redoObject:$(t)};n.addHistoryEntry(h),n.commandHandler.isContainer&&(n.commandHandler.isContainer=!1,n.endGroupAction()),Z3(t,n)}n.protectPropertyChange(o)}}function GI(n,t){var e,i,r;return n.enableServerDataBinding(!1),ce()||(n.selectedObject.helperObject?r=n.selectedObject.helperObject:(n.selectedItems.nodes.length>0||n.selectedItems.connectors.length>0)&&(t instanceof si&&t.nodes.length+t.connectors.length===1?(e=t.nodes.length>0?t.nodes[0]:t.connectors[0],i=n.selectedItems.wrapper.children[0]):(e=t,i=n.selectedItems.wrapper),n.selectedObject.actualObject=e,!n.currentSymbol&&(e.isLane&&Gx(e,n)&&cs(n,e)||!e.isLane&&cs(n,e)||n.constraints&rt.LineRouting&&n.selectedItems.nodes.length>0))&&(r=function Nne(n,t){for(var e,i={},r=0,s=Object.keys(t);r=t.x-e&&n.x<=t.x+e&&n.y>=t.y-e&&n.y<=t.y+e}function Xa(n){return n.selectedItems.nodes.length>0||n.selectedItems.connectors.length>0}function K3(n){return 1===n.selectedItems.connectors.length&&!n.selectedItems.nodes.length}function _r(n,t,e,i){if(void 0===e&&(e=!0),t instanceof si)return!0;if(t instanceof te)for(;t;){if(-1!==n.selectedItems.nodes.indexOf(t)&&void 0===n.selectedItems.annotation)return!0;if(e)break;t=n.nameTable[t.parentId]}else if(t instanceof de){if(-1!==n.selectedItems.connectors.indexOf(t)&&void 0===n.selectedItems.annotation)return!0}else if((t instanceof Zn||t instanceof Nr)&&n.selectedItems.annotation&&n.selectedItems.wrapper.children[0].id===i.id)return!0;return!1}var Xx={None:"default",Rotate:"crosshair",Select:"default",Drag:"move",ResizeWest:"w-resize",ResizeEast:"e-resize",ResizeSouth:"s-resize",ResizeNorth:"n-resize",Draw:"crosshair",PortDraw:"crosshair",ResizeNorthEast:"ne-resize",ResizeNorthWest:"nw-resize",ResizeSouthEast:"se-resize",ResizeSouthWest:"sw-resize",ConnectorSourceEnd:"move",ConnectorTargetEnd:"move",BezierSourceThumb:"move",BezierTargetThumb:"move",OrthoThumb:"move",SegmentEnd:"move",Pan:"grab",Hyperlink:"pointer",PortDrag:"pointer",LabelSelect:"pointer",LabelDrag:"move",LabelRotate:"crosshair",LabelResizeWest:"w-resize",LabelResizeEast:"e-resize",LabelResizeSouth:"s-resize",LabelResizeNorth:"n-resize",LabelResizeNorthEast:"ne-resize",LabelResizeNorthWest:"nw-resize",LabelResizeSouthEast:"se-resize",LabelResizeSouthWest:"sw-resize"},ds=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Od=function(n,t,e,i){return new(e||(e=Promise))(function(r,s){function o(h){try{l(i.next(h))}catch(c){s(c)}}function a(h){try{l(i.throw(h))}catch(c){s(c)}}function l(h){h.done?r(h.value):new e(function(c){c(h.value)}).then(o,a)}l((i=i.apply(n,t||[])).next())})},kd=function(n,t){var i,r,s,o,e={label:0,sent:function(){if(1&s[0])throw s[1];return s[1]},trys:[],ops:[]};return o={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function a(h){return function(c){return function l(h){if(i)throw new TypeError("Generator is already executing.");for(;e;)try{if(i=1,r&&(s=2&h[0]?r.return:h[0]?r.throw||((s=r.return)&&s.call(r),0):r.next)&&!(s=s.call(r,h[1])).done)return s;switch(r=0,s&&(h=[2&h[0],s.value]),h[0]){case 0:case 1:s=h;break;case 4:return e.label++,{value:h[1],done:!1};case 5:e.label++,r=h[1],h=[0];continue;case 7:h=e.ops.pop(),e.trys.pop();continue;default:if(!(s=(s=e.trys).length>0&&s[s.length-1])&&(6===h[0]||2===h[0])){e=0;continue}if(3===h[0]&&(!s||h[1]>s[0]&&h[1]-1&&(r=i.fixedUserHandles[parseInt(o.toString(),10)]);this.commandHandler.triggerEvent(Ce.fixedUserHandleClick,{fixedUserHandle:r,element:e.source}),n.prototype.mouseUp.call(this,e)},t}(us),Pd=function(n){function t(e,i){var r=n.call(this,e,!0)||this;return r.isConnected=!1,r.endPoint=i,r}return ds(t,n),t.prototype.mouseDown=function(e){return Od(this,void 0,void 0,function(){var r,s,o,a,l;return kd(this,function(h){if(this.inAction=!0,this.undoElement=void 0,this instanceof pa||(this.undoElement=$(e.source)),n.prototype.mouseDown.call(this,e),e.source&&e.source.connectors&&(this.oldConnector=$(r=e.source.connectors[0])),"BezierSourceThumb"===this.endPoint||"BezierTargetThumb"===this.endPoint)for(s=0;s0))},t.prototype.endAction=function(){n.prototype.endAction.call(this),this.prevPosition=null,this.endPoint=null},t}(us),ua=function(n){function t(e,i){var r=n.call(this,e,!0)||this;return r.currentTarget=null,r.isStartAction=!1,r.canCancel=!1,r.canTrigger=!1,r.objectType=i,r}return ds(t,n),t.prototype.mouseDown=function(e){if(e.source instanceof te||e.source instanceof de){var i=this.commandHandler.getSelectedObject();this.commandHandler.selectObjects([e.source],e.info&&e.info.ctrlKey,i);var r={nodes:[],connectors:[]};e.source instanceof te?r.nodes.push($(e.source)):r.connectors.push($(e.source)),this.undoElement=$(r)}else this.undoElement=$(e.source);this.undoParentElement=this.commandHandler.getSubProcess(e.source),"Port"===this.objectType&&(this.portId=e.sourceWrapper.id),this.commandHandler.insertBlazorConnector(e.source),n.prototype.mouseDown.call(this,e),this.initialOffset={x:0,y:0}},t.prototype.mouseUp=function(e,i){return Od(this,void 0,void 0,function(){var s,o,a,l,h,c,d,u,f,g,v,y,S,b,M;return kd(this,function(w){if(this.checkPropertyValue(),a=!1,h={nodes:[],connectors:[]},"Port"!==this.objectType){if(e.source instanceof te||e.source instanceof de?(e.source instanceof te?h.nodes.push($(e.source)):h.connectors.push($(e.source)),(o=$(h)).offsetX=(c=e.source.wrapper).offsetX,o.offsetY=c.offsetY):o=$(e.source),("helper"===(l=this.commandHandler.renderContainerHelper(e.source)||e.source||this.commandHandler.renderContainerHelper(e.source)).id||"helper"!==l.id)&&((l instanceof si&&(Math.round(l.width)===Math.round(this.undoElement.width)&&Math.round(l.height)===Math.round(this.undoElement.height)||l.selectedObjects&&1===l.selectedObjects.length)||!(l instanceof si))&&(l.offsetX!==this.undoElement.offsetX||l.offsetY!==this.undoElement.offsetY||l.sourcePoint!==this.undoElement.sourcePoint||l.targetPoint!==this.undoElement.targetPoint)||this.isSelectionHasConnector(l))&&(e.source&&(s={offsetX:e.source.wrapper.offsetX,offsetY:e.source.wrapper.offsetY}),g={source:e.source,state:"Completed",oldValue:this.intialValue,newValue:s,target:this.currentTarget,targetPosition:this.currentPosition,allowDrop:(g={source:e.source,state:"Completed",oldValue:this.intialValue,newValue:s,target:this.currentTarget,targetPosition:this.currentPosition,allowDrop:!0,cancel:!1}).allowDrop,cancel:g.cancel},d=!0,"helper"===l.id?this.canTrigger?(this.commandHandler.triggerEvent(Ce.positionChange,g),this.connectorEndPointChangeEvent(g),d=!0):d=!1:(this.commandHandler.triggerEvent(Ce.positionChange,g),this.connectorEndPointChangeEvent(g)),!i&&d&&(this.commandHandler.startGroupAction(),a=!0,M={type:"PositionChanged",redoObject:$(o),undoObject:$(this.undoElement),category:"Internal"},o.nodes[0]&&o.nodes[0].processId&&(u={type:"SizeChanged",category:"Internal",undoObject:this.undoParentElement,redoObject:this.commandHandler.getSubProcess(e.source)},this.commandHandler.addHistoryEntry(u)),this.commandHandler.addHistoryEntry(M))),this.commandHandler.snapPoint(this.prevPosition,this.currentPosition,0,0),this.commandHandler.removeSnap(),this.commandHandler.removeHighlighter(),e.source&&this.currentTarget&&BI(this.currentTarget)&&this.commandHandler.isDroppable(e.source,this.currentTarget)){if(f=!0,this.commandHandler.drop(this.currentElement,this.currentTarget,this.currentPosition),this.currentTarget&&this.currentTarget instanceof de&&!0===this.commandHandler.diagram.enableConnectorSplit)if(this.currentElement&&this.currentElement instanceof te){if(void 0!==this.currentElement.children)for(b=0;b0)for(var s=0;s0)for(var a=0;a0)for(a=0;a0&&e.connectors.length>0)||e.width===this.undoElement.width&&e.height===this.undoElement.height)},t.prototype.mouseMove=function(e){n.prototype.mouseMove.call(this,e);var r,s,i=!1;(r=this.commandHandler.renderContainerHelper(e.source)||e.source)instanceof te||r instanceof de?r instanceof te?r.offsetX===this.undoElement.nodes[0].offsetX&&r.offsetY===this.undoElement.nodes[0].offsetY&&(i=!0):z.equals(r.sourcePoint,this.undoElement.connectors[0].sourcePoint)&&z.equals(r.targetPoint,this.undoElement.connectors[0].targetPoint)&&(i=!0):r.wrapper.offsetX===this.undoElement.wrapper.offsetX&&r.wrapper.offsetY===this.undoElement.wrapper.offsetY&&(i=!0),r&&(s={offsetX:r.wrapper.offsetX,offsetY:r.wrapper.offsetY});var o={source:r,state:"Start",oldValue:s,newValue:s,target:e.target,targetPosition:e.position,allowDrop:!0,cancel:!1};if(o={source:r,state:"Start",oldValue:s,newValue:s,target:e.target,targetPosition:e.position,allowDrop:o.allowDrop,cancel:o.cancel},this.isStartAction||(this.intialValue={offsetX:r.wrapper.offsetX,offsetY:r.wrapper.offsetY}),i&&!ce()&&(this.commandHandler.triggerEvent(Ce.positionChange,o),this.connectorEndPointChangeEvent(o),this.isStartAction=!0),this.currentPosition=e.position,"Port"!==this.objectType){var h=this.initialOffset.x+(this.currentPosition.x-this.prevPosition.x),c=this.initialOffset.y+(this.currentPosition.y-this.prevPosition.y);this.commandHandler.dragOverElement(e,this.currentPosition),this.commandHandler.disConnect(e.source),this.commandHandler.removeSnap();var d,u=void 0,p=this.commandHandler.snapPoint(this.prevPosition,this.currentPosition,h,c);this.initialOffset.x=h-p.x,this.initialOffset.y=c-p.y,r&&(d={offsetX:r.wrapper.offsetX,offsetY:r.wrapper.offsetY},u={offsetX:r.wrapper.offsetX+p.x,offsetY:r.wrapper.offsetY+p.y}),this.currentTarget&&e.target!==this.currentTarget&&this.commandHandler.removeChildFromBPmn(e.source,e.target,this.currentTarget),this.currentTarget=e.target;var f={source:r,state:"Progress",oldValue:d,newValue:u,target:e.target,targetPosition:e.position,allowDrop:!0,cancel:!1};if(this.commandHandler.triggerEvent(Ce.positionChange,f),this.canTrigger=!0,this.connectorEndPointChangeEvent(f,p),!f.cancel&&!this.canCancel){this.blocked=!this.commandHandler.dragSelectedObjects(p.x,p.y);var g=!this.commandHandler.mouseOver(this.currentElement,this.currentTarget,this.currentPosition);this.blocked=this.blocked||g}if(this.commandHandler.removeStackHighlighter(),this.commandHandler.renderStackHighlighter(e),this.currentTarget&&e.source!==this.currentTarget&&this.commandHandler.isDroppable(e.source,this.currentTarget)&&"helper"!==e.source.id){var v=e.source instanceof si?e.source.nodes[0]:e.source;!this.commandHandler.isParentAsContainer(v,!0)&&"SwimLane"!==v.shape.type&&!v.shape.isPhase&&(this.currentTarget.isLane?this.commandHandler.renderStackHighlighter(e,this.currentTarget):this.commandHandler.drawHighlighter(this.currentTarget))}else this.commandHandler.removeHighlighter();if(this.commandHandler.canEnableDefaultTooltip()){var y=this.getTooltipContent(e.source);this.commandHandler.showTooltip(e.source,e.position,ko(function(){return y}),"MoveTool",this.isTooltipVisible),this.isTooltipVisible=!1}}else{var b=Hi(),M=e.source;qi(b,-M.rotateAngle||-M.wrapper.rotateAngle,M.offsetX||M.wrapper.offsetX,M.offsetY||M.wrapper.offsetY);var w=Je(b,{x:this.prevPosition.x,y:this.prevPosition.y}),C=Je(b,{x:e.position.x,y:e.position.y});this.commandHandler.portDrag(e.source,e.sourceWrapper,C.x-w.x,C.y-w.y)}return this.prevPosition=this.currentPosition,!this.blocked},t.prototype.getTooltipContent=function(e){return"X:"+Math.round(e.wrapper.bounds.x)+" Y:"+Math.round(e.wrapper.bounds.y)},t.prototype.mouseLeave=function(e){this.mouseUp(e)},t.prototype.endAction=function(){n.prototype.endAction.call(this),this.currentTarget=null,this.prevPosition=null},t}(us),qx=function(n){function t(e){var i=n.call(this,e,!0)||this;return i.rotateStart=!1,i}return ds(t,n),t.prototype.mouseDown=function(e){if(this.undoElement=$(e.source),this.undoElement.nodes[0]&&this.undoElement.nodes[0].children)for(var r=this.commandHandler.getAllDescendants(this.undoElement.nodes[0],[]),s=0;s=2){var s=e.startTouches[0],o=e.startTouches[1],a=e.moveTouches[0],l=e.moveTouches[1],h=this.getDistance(a,l)/this.getDistance(s,o);this.commandHandler.zoom(h,0,0,e.position),this.updateTouch(s,a),this.updateTouch(o,l)}}else this.commandHandler.scroll(this.currentPosition.x-this.prevPosition.x,this.currentPosition.y-this.prevPosition.y,this.currentPosition);return this.commandHandler.dataBinding(),!this.blocked},t.prototype.mouseUp=function(e){this.commandHandler.setBlazorDiagramProps(!1),this.checkPropertyValue(),this.commandHandler.updatePanState(!1),n.prototype.mouseUp.call(this,e),this.inAction=!1},t.prototype.endAction=function(){n.prototype.endAction.call(this)},t.prototype.getDistance=function(e,i){var r=i.pageX-e.pageX,s=i.pageY-e.pageY;return Math.sqrt(r*r+s*s)},t.prototype.updateTouch=function(e,i){e.pageX=i.pageX,e.pageY=i.pageY},t}(us),Une=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseUp=function(e){this.checkPropertyValue(),this.commandHandler.initExpand(e),n.prototype.mouseUp.call(this,e)},t}(us),eF=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseUp=function(e){this.checkPropertyValue();var i="_blank",r="",s=window.innerHeight,o=window.innerWidth,a=window.screenTop,l=window.screenLeft;"CurrentTab"===e.sourceWrapper.hyperlink.hyperlinkOpenState?i="_self":"NewWindow"===e.sourceWrapper.hyperlink.hyperlinkOpenState&&(r="height="+s+",width="+o+",top="+a+",left="+l),window.open(e.sourceWrapper.hyperlink.link,i,r).focus(),n.prototype.mouseUp.call(this,e)},t}(us),Ph=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseDown=function(e){if(n.prototype.mouseDown.call(this,e),this.inAction=!0,this.drawingObject){var r=void 0,s=this.drawingObject.shape;this.drawingObject.shape.points.push(r={x:(r=s.points[s.points.length-1]).x,y:r.y})}else this.startPoint={x:this.startPosition.x,y:this.startPosition.y},this.drawingObject=this.commandHandler.drawObject({offsetX:this.currentPosition.x,offsetY:this.currentPosition.y,width:5,height:5,style:{strokeColor:"black",strokeWidth:1},shape:{type:"Basic",shape:"Polygon",points:[{x:this.startPoint.x,y:this.startPoint.y},{x:this.currentPosition.x,y:this.currentPosition.y}]}})},t.prototype.mouseMove=function(e){if(n.prototype.mouseMove.call(this,e),this.inAction){var i=this.drawingObject.shape;if(i.points[i.points.length-1].x=this.currentPosition.x,i.points[i.points.length-1].y=this.currentPosition.y,this.drawingObject.wrapper.children[0].data=Ix(this.drawingObject.shape.points),this.inAction&&!1===z.equals(this.currentPosition,this.prevPosition)){var r=Ne.toBounds(this.drawingObject.shape.points);this.commandHandler.updateNodeDimension(this.drawingObject,r)}}return!0},t.prototype.mouseUp=function(e,i){this.checkPropertyValue(),n.prototype.mouseMove.call(this,e),this.inAction&&(this.inAction=!1,this.commandHandler.addObjectToDiagram(this.drawingObject)),this.endAction()},t.prototype.mouseWheel=function(e){n.prototype.mouseWheel.call(this,e),this.mouseMove(e)},t.prototype.endAction=function(){this.inAction=!1,this.drawingObject=null},t}(us),zh=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseMove=function(e){if(n.prototype.mouseMove.call(this,e),this.inAction){var i=this.drawingObject;i.targetPoint=this.currentPosition,this.commandHandler.updateConnectorPoints(i)}return!0},t.prototype.mouseDown=function(e){if(n.prototype.mouseDown.call(this,e),this.inAction=!0,this.drawingObject){var r=this.drawingObject,s=void 0;(s=new Pl(r,"segments",{type:"Straight"},!0)).point=this.currentPosition,r.segments[r.segments.length-1]=s}else this.drawingObject=this.commandHandler.drawObject({id:"Connector",type:"Straight",sourcePoint:this.currentPosition,targetPoint:this.currentPosition})},t.prototype.mouseWheel=function(e){n.prototype.mouseWheel.call(this,e),this.mouseMove(e)},t.prototype.mouseUp=function(e){if(this.checkPropertyValue(),n.prototype.mouseMove.call(this,e),this.inAction&&this.drawingObject){var i=this.drawingObject;i.segments[i.segments.length-1].point={x:0,y:0},this.commandHandler.addObjectToDiagram(this.drawingObject)}this.endAction()},t.prototype.endAction=function(){this.drawingObject=null,this.inAction=!1},t}(us),jne=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseDown=function(e){this.inAction=!0,this.undoElement=$(e.source),this.annotationId=e.sourceWrapper.id,n.prototype.mouseDown.call(this,e)},t.prototype.mouseMove=function(e){n.prototype.mouseMove.call(this,e);var i=this.currentPosition.x-this.prevPosition.x,r=this.currentPosition.y-this.prevPosition.y,s=e.source;if(s instanceof te){var o=Hi();qi(o,-s.rotateAngle,0,0);var a=Je(o,{x:i,y:r});i=a.x,r=a.y}return this.inAction&&(this.commandHandler.labelDrag(e.source,e.sourceWrapper,i,r),this.commandHandler.updateSelector()),this.prevPosition=this.currentPosition,!this.blocked},t.prototype.mouseUp=function(e){this.checkPropertyValue();var i=e.source;this.inAction=!1;var r={type:"AnnotationPropertyChanged",objectId:this.annotationId,undoObject:$(this.undoElement),category:"Internal",redoObject:$(i)};this.commandHandler.addHistoryEntry(r),n.prototype.mouseUp.call(this,e)},t.prototype.mouseLeave=function(e){this.mouseUp(e)},t}(us),Vne=function(n){function t(e,i){var r=n.call(this,e,!0)||this;return r.corner=i,r}return ds(t,n),t.prototype.mouseDown=function(e){this.inAction=!0;var i=e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0];this.annotationId=e.source.wrapper.children[0].id,this.undoElement=$(i);var r=e.source.wrapper.children[0];this.initialBounds={x:r.offsetX,y:r.offsetY,width:r.actualSize.width,height:r.actualSize.height},n.prototype.mouseDown.call(this,e)},t.prototype.mouseMove=function(e){return n.prototype.mouseMove.call(this,e),this.inAction&&this.resizeObject(e),!this.blocked},t.prototype.mouseUp=function(e){this.checkPropertyValue();var i=e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0];this.inAction=!1;var r={type:"AnnotationPropertyChanged",objectId:this.annotationId,redoObject:$(i),undoObject:$(this.undoElement),category:"Internal"};this.commandHandler.addHistoryEntry(r),n.prototype.mouseUp.call(this,e)},t.prototype.mouseLeave=function(e){this.mouseUp(e)},t.prototype.resizeObject=function(e){var i,s,o,r=e.source.wrapper.children[0],a={x:r.offsetX,y:r.offsetY},l=r.rotateAngle;l=((l+=(i=e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0])instanceof te?i.rotateAngle:0)+360)%360;var h=Hi();qi(h,l,a.x,a.y);var c=this.corner.slice(5),d=this.updateSize(r,this.startPosition,this.currentPosition,c,this.initialBounds,l),u=r.offsetX-r.actualSize.width*r.pivot.x,p=r.offsetY-r.actualSize.height*r.pivot.y,f=this.getPivot(c),g=Je(h,f={x:u+r.actualSize.width*f.x,y:p+r.actualSize.height*f.y});d.x=g.x,d.y=g.y,this.commandHandler.labelResize(i,e.source.annotation,s=(s=d.width)<0?1:s,o=(o=d.height)<0?1:o,d,e.source),this.commandHandler.updateSelector()},t}(us),Wne=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseDown=function(e){this.inAction=!0,this.annotationId=e.source.wrapper.children[0].id,this.undoElement=$(e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0]),n.prototype.mouseDown.call(this,e)},t.prototype.mouseMove=function(e){return n.prototype.mouseMove.call(this,e),e.source&&this.inAction&&(this.commandHandler.labelRotate(e.source.nodes[0]?e.source.nodes[0]:e.source.connectors[0],e.source.annotation,this.currentPosition,e.source),this.commandHandler.updateSelector()),this.prevPosition=this.currentPosition,!this.blocked},t.prototype.mouseUp=function(e){this.checkPropertyValue(),this.inAction=!1;var r={type:"AnnotationPropertyChanged",objectId:this.annotationId,redoObject:$(e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0]),undoObject:$(this.undoElement),category:"Internal"};this.commandHandler.addHistoryEntry(r),n.prototype.mouseUp.call(this,e)},t.prototype.mouseLeave=function(e){this.mouseUp(e)},t}(us),Yne=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseMove=function(e){if(n.prototype.mouseMove.call(this,e),this.inAction){var i=this.drawingObject.shape;if(i.points.push(this.currentPosition),this.drawingObject.wrapper.children[0].data=bx(this.drawingObject.shape.points),i.data=bx(i.points),this.inAction&&!1===z.equals(this.currentPosition,this.prevPosition)){var s=Ne.toBounds(this.drawingObject.shape.points);this.commandHandler.updateNodeDimension(this.drawingObject,s)}}return!0},t.prototype.mouseDown=function(e){n.prototype.mouseDown.call(this,e),this.inAction=!0,this.startPoint={x:this.startPosition.x,y:this.startPosition.y},this.drawingObject=this.commandHandler.drawObject({offsetX:this.currentPosition.x,offsetY:this.currentPosition.y,width:5,height:5,style:{strokeColor:"black",strokeWidth:1,fill:"transparent"},shape:{type:"Path",points:[{x:this.startPoint.x,y:this.startPoint.y},{x:this.currentPosition.x,y:this.currentPosition.y}]}})},t.prototype.mouseUp=function(e){if(this.checkPropertyValue(),this.inAction){this.inAction=!1;var s=this.drawingObject.shape,o=s.points;this.commandHandler.addObjectToDiagram(this.drawingObject),this.commandHandler.diagram.remove(this.commandHandler.diagram.nameTable[""+this.drawingObject.id]),o=this.pointReduction(o,10);var h={id:"newConnector"+Qe(),type:"Bezier",sourcePoint:{x:o[0].x,y:o[0].y},targetPoint:{x:o[o.length-1].x,y:o[o.length-1].y},segments:[],bezierSettings:{allowSegmentsReset:!1}};this.drawingObject=this.commandHandler.drawObject(h),this.drawingObject=this.bezierCurveSmoothness(o,.5,this.drawingObject,s),this.commandHandler.updateConnectorPoints(this.drawingObject),this.commandHandler.addObjectToDiagram(this.drawingObject),n.prototype.mouseUp.call(this,e)}},t.prototype.pointReduction=function(e,i){if(null===e||e.length<3)return e;var s=e.length-1,o=[];for(o.push(0),o.push(s);e[parseInt((0).toString(),10)]===e[parseInt(s.toString(),10)];)s--;this.reduction(e,0,s,i,o);var a=[];return o.sort(function(l,h){return l-h}),o.forEach(function(l){a.push(e[parseInt(l.toString(),10)])}),a},t.prototype.reduction=function(e,i,r,s,o){for(var a=0,l=0,h=i;ha&&(a=c,l=h)}a>s&&0!==l&&(o.push(l),this.reduction(e,i,l,s,o),this.reduction(e,l,r,s,o))},t.prototype.perpendicularDistance=function(e,i,r){return Math.abs(.5*(e.x*i.y-i.x*e.y+(i.x*r.y-r.x*i.y)+(r.x*e.y-e.x*r.y)))/Math.sqrt(Math.pow(e.x-i.x,2)+Math.pow(e.y-i.y,2))*2},t.prototype.bezierCurveSmoothness=function(e,i,r,s){if(e.length<3)return r;for(var o=0;o=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Qne=function(n){if(n)switch(n.type){case"Bpmn":return $ne;case"UmlActivity":return qne;case"UmlClassifier":return Kne;default:return tm}return tm},Gne=function(n){if(n)switch(n.type){case"Straight":default:return Pl;case"Bezier":return ps;case"Orthogonal":return bi}},tF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I(10)],t.prototype,"width",void 0),Pe([I(10)],t.prototype,"height",void 0),Pe([I("Arrow")],t.prototype,"shape",void 0),Pe([re({fill:"black",strokeColor:"black",strokeWidth:1},Ll)],t.prototype,"style",void 0),Pe([re({x:0,y:.5},z)],t.prototype,"pivot",void 0),Pe([I("")],t.prototype,"pathData",void 0),t}(Ee),ZI=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I(0)],t.prototype,"angle",void 0),Pe([I(0)],t.prototype,"distance",void 0),t}(Ee),Xne=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I(Ex.All)],t.prototype,"controlPointsVisibility",void 0),Pe([I("FreeForm")],t.prototype,"segmentEditOrientation",void 0),Pe([I(wI.Default)],t.prototype,"smoothness",void 0),Pe([I(!0)],t.prototype,"allowSegmentsReset",void 0),t}(Ee),tm=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I("None")],t.prototype,"type",void 0),t}(Ee),qne=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I("Object")],t.prototype,"flow",void 0),Pe([I(30)],t.prototype,"exceptionFlowHeight",void 0),t}(tm),$ne=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I("Sequence")],t.prototype,"flow",void 0),Pe([I("Normal")],t.prototype,"sequence",void 0),Pe([I("Default")],t.prototype,"message",void 0),Pe([I("Default")],t.prototype,"association",void 0),t}(tm),iF=function(n){function t(e,i,r,s){var o=n.call(this,e,i,r,s)||this;return o.points=[],o}return Qs(t,n),Pe([I("Straight")],t.prototype,"type",void 0),Pe([I(!0)],t.prototype,"allowDrag",void 0),t}(Ee),Pl=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),t.prototype.getClassName=function(){return"StraightSegment"},Pe([re({x:0,y:0},z)],t.prototype,"point",void 0),t}(iF),ps=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),t.prototype.getClassName=function(){return"BezierSegment"},t.prototype.getPoints=function(e,i){var r=[];if(r.length>0||null!=i){var o=this.bezireToPoly(r.length>0?r[r.length-1]:i,e);r.push.apply(r,o)}return r},t.prototype.bezireToPoly=function(e,i){var r=[];return i&&this.flattenCubicBezier(r,e,i.bezierPoint1,i.bezierPoint2,{x:i.points[1].x,y:i.points[1].y},10),r},t.prototype.flattenCubicBezier=function(e,i,r,s,o,a){var h,l=(z.findLength(i,r)+z.findLength(r,s)+z.findLength(s,o))/a;for(h=0;h<=l;h++){var c=h/l;e.push({x:(1-c)*(1-c)*(1-c)*i.x+3*c*(1-c)*(1-c)*r.x+3*c*c*(1-c)*s.x+c*c*c*o.x,y:(1-c)*(1-c)*(1-c)*i.y+3*c*(1-c)*(1-c)*r.y+3*c*c*(1-c)*s.y+c*c*c*o.y})}},Pe([I("Horizontal")],t.prototype,"orientation",void 0),Pe([re({x:0,y:0},z)],t.prototype,"point1",void 0),Pe([re({x:0,y:0},z)],t.prototype,"point2",void 0),Pe([re({angle:0,distance:0},ZI)],t.prototype,"vector1",void 0),Pe([re({angle:0,distance:0},ZI)],t.prototype,"vector2",void 0),t}(Pl),bi=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),t.prototype.getClassName=function(){return"OrthogonalSegment"},Pe([I(null)],t.prototype,"length",void 0),Pe([I(null)],t.prototype,"direction",void 0),t}(iF);function rF(n,t,e){var s=e?45:180/(2+2/(n.height/n.width)),o=s,a=180-s,l=a+2*s,h=360-s,c=Gt(t,n.center);return c>o&&ca&&cl&&cMath.abs(t.y-n.y)?n.x=c)return s=z.findAngle(n[parseInt(d.toString(),10)],n[d+1]),{point:r=z.transform(n[parseInt(d.toString(),10)],s,c-(a||0)),index:l=d};a=o[parseInt(d.toString(),10)]}return{point:r,index:l}}(n,t),r=z.findAngle(n[i.index],n[i.index+1]),s=function xse(n){var e=0;switch(n.alignment){case"Center":case"After":e=0;break;case"Before":e=-0}return e}(t),o=z.transform(i.point,r+45,s);return i.point=o,i.angle=r,i}(i,e),h=l.point;s.id=this.id+"_"+e.id;var c=e.style;s.style={fill:c.fill,strokeColor:c.strokeColor,gradient:null,opacity:c.opacity,strokeDashArray:c.strokeDashArray,strokeWidth:c.strokeWidth},0===r.width&&(r.width=this.style.strokeWidth),0===r.height&&(r.height=this.style.strokeWidth);var d_y=(h.y-r.y)/r.height;a.x=r.width*((h.x-r.x)/r.width),a.y=r.height*d_y;var g,v,u=SF(e,l.angle,i),p=u.hAlign,f=u.vAlign;return"left"===p?(g="Left",a.x+=e.displacement.x):"right"===p?(g="Right",a.x-=e.displacement.x):"center"===p&&(g="Center"),"top"===f?(v="Top",a.y+=e.displacement.y):"bottom"===f?(v="Bottom",a.y-=e.displacement.y):"center"===f&&(v="Center"),s.horizontalAlignment=g,s.verticalAlignment=v,(s=nm(s,o&&"Label"!==o.flipMode&&"None"!==o.flipMode?this.flip:"None",e)).float=!0,s.connectionDirection=e.connectionDirection,s.setOffsetWithRespectToBounds(a.x,a.y,"Absolute"),s.relativeMode="Point",s.visible=!(!ga(e,hi.Visible)||ga(e,hi.Hover)||ga(e,hi.Connect)),s.elementActions=s.elementActions|Xr.ElementIsPort,s},t.prototype.getConnectorRelation=function(){var e=this.shape;"Association"===e.relationship?(this.segments[0].type="Straight",this.sourceDecorator.shape="None",this.targetDecorator.shape="Arrow"):"Inheritance"===e.relationship?(this.segments[0].type="Orthogonal",this.sourceDecorator.shape="None",this.targetDecorator.shape="Arrow"):"Composition"===e.relationship||"Aggregation"===e.relationship?(this.segments[0].type="Orthogonal",this.sourceDecorator.shape="Diamond",this.targetDecorator.shape="None"):"Dependency"===e.relationship?(this.segments[0].type="Orthogonal",this.sourceDecorator.shape="None",this.targetDecorator.shape="OpenArrow"):"Realization"===e.relationship&&(this.segments[0].type="Orthogonal",this.sourceDecorator.shape="None",this.targetDecorator.shape="Arrow"),"BiDirectional"===e.associationType&&(this.sourceDecorator.shape="None",this.targetDecorator.shape="None");var i,o,r="",s="";e.multiplicity.source&&(e.multiplicity.source.lowerBounds=e.multiplicity.source.lowerBounds,e.multiplicity.source.upperBounds=e.multiplicity.source.upperBounds),e.multiplicity.target&&(e.multiplicity.target.lowerBounds=e.multiplicity.target.lowerBounds,e.multiplicity.target.upperBounds=e.multiplicity.target.upperBounds);var a=e.multiplicity.source,l=e.multiplicity.target;o=a.upperBounds?a.lowerBounds+"..."+a.upperBounds:a.lowerBounds,i=l.upperBounds?l.lowerBounds+"..."+l.upperBounds:l.lowerBounds,"ManyToOne"===e.multiplicity.type&&(e.multiplicity.target.optional=!1,r=o||"*",s="1"),"OneToMany"===e.multiplicity.type&&(e.multiplicity.source.optional=!1,s=i||"*",r="1"),"ManyToMany"===e.multiplicity.type&&(r=o||"*",s=i||"*"),"OneToOne"===e.multiplicity.type&&(e.multiplicity.target.optional=!1,e.multiplicity.source.optional=!1,r="1",s="1"),this.annotations=[{id:this.id+"sourcelabel",content:r,offset:0,alignment:"Before",margin:{right:5,bottom:5}},{id:this.id+"targetlabel",content:s,offset:1,alignment:"Before",margin:{right:5,bottom:5}}]},t.prototype.getBpmnSequenceFlow=function(){var e=new Ke,i=new Ke;return"Normal"===this.shape.sequence&&"Bezier"!==this.type&&(this.targetDecorator.shape="Arrow"),"Default"===this.shape.sequence&&(e=this.getSegmentElement(this,e),i=DF(this.intermediatePoints,this),this.targetDecorator.shape="Arrow"),"Conditional"===this.shape.sequence&&(this.targetDecorator.shape="Arrow",this.sourceDecorator.shape="Diamond",i.id=this.id+this.shape.type),i},t.prototype.getUMLObjectFlow=function(){if(this.annotations)for(var e=0;e0&&(this.sourcePoint=o[0],this.targetPoint=o[o.length-1]),o},t.prototype.clipDecorator=function(e,i,r,s){var a,l,o={x:0,y:0},h=i.length,c=z.distancePoints(a=r?i[0]:i[h-1],l=r?i[1]:i[h-2]);c=0===c?1:c;var d=1,u=r?e.sourceWrapper:e.targetWrapper;u&&(d=u.style.strokeWidth,s&&s&ee.DecoratorPropertyChange&&(d=1));var p=d-1;return o.x=Math.round(a.x+p*(l.x-a.x)/c),o.y=Math.round(a.y+p*(l.y-a.y)/c),(r&&"None"!==e.sourceDecorator.shape||!r&&"None"!==e.targetDecorator.shape)&&(o=z.adjustPoint(o,l,!0,s&ee.DecoratorPropertyChange?0:d/2)),o},t.prototype.clipDecorators=function(e,i,r){return"None"!==e.sourceDecorator.shape&&(i[0]=this.clipDecorator(e,i,!0,r)),"None"!==e.targetDecorator.shape&&(i[i.length-1]=this.clipDecorator(e,i,!1,r)),i},t.prototype.updateSegmentElement=function(e,i,r,s){var o=new Ne,a=this.getSegmentPath(e,i,s);if("Bezier"===e.type){if(this.segments.length>0)for(var l=0;l0)if("Straight"===e.type&&e.segments.length<2)for(var o=0;o1)for(o=0;o0&&"Bezier"!==this.type)for(var p=0;p0&&(a=p0&&(f<2*this.cornerRadius?(l=z.adjustPoint(h[parseInt(p.toString(),10)],h[p+1],!0,f/2),p0&&(s=this.bridgePath(e,s,p),"Orthogonal"===e.type&&(s=this.bridgePath(e,s,p+1))),s+=" L"+a.x+" "+a.y))}else if("Bezier"===this.type){var g=void 0,v=void 0;if(this.parentObj.element){var y=this.parentObj.element.ej2_instances[0].eventHandler.action;g=this.parentObj.element.ej2_instances[0].eventHandler.tool instanceof zd,v=y.includes("PortDraw")||y.includes("Drag")}for(var S=void 0,b=this.segments,M=0;M2&&(b[parseInt(M.toString(),10)].bezierPoint1={x:0,y:0},b[parseInt(M.toString(),10)].bezierPoint2={x:0,y:0}),!z.isEmptyPoint(b[parseInt(M.toString(),10)].point1)||b[parseInt(M.toString(),10)].vector1.angle||b[parseInt(M.toString(),10)].vector1.distance?b[parseInt(M.toString(),10)].vector1.angle||b[parseInt(M.toString(),10)].vector1.distance?b[parseInt(M.toString(),10)].bezierPoint1=z.transform(h[parseInt(M.toString(),10)],b[parseInt(M.toString(),10)].vector1.angle,b[parseInt(M.toString(),10)].vector1.distance):b[parseInt(M.toString(),10)].bezierPoint1={x:b[parseInt(M.toString(),10)].point1.x||b[parseInt(M.toString(),10)].bezierPoint1.x,y:b[parseInt(M.toString(),10)].point1.y||b[parseInt(M.toString(),10)].bezierPoint1.y}:((e.sourceID||this.sourcePortID)&&this.sourceWrapper&&!v&&!g&&(S=rF(this.sourceWrapper.bounds,h[parseInt(M.toString(),10)],!0)),b[parseInt(M.toString(),10)].bezierPoint1=KI(h[parseInt(M.toString(),10)],h[M+1],S)),!z.isEmptyPoint(b[parseInt(M.toString(),10)].point2)||b[parseInt(M.toString(),10)].vector2.angle||b[parseInt(M.toString(),10)].vector2.distance?b[parseInt(M.toString(),10)].vector2.angle||b[parseInt(M.toString(),10)].vector2.distance?b[parseInt(M.toString(),10)].bezierPoint2=z.transform(h[M+1],b[parseInt(M.toString(),10)].vector2.angle,b[parseInt(M.toString(),10)].vector2.distance):b[parseInt(M.toString(),10)].bezierPoint2={x:b[parseInt(M.toString(),10)].point2.x||b[parseInt(M.toString(),10)].bezierPoint2.x,y:b[parseInt(M.toString(),10)].point2.y||b[parseInt(M.toString(),10)].bezierPoint2.y}:((e.targetID||this.targetPortID)&&this.targetWrapper&&!v&&!g&&(S=rF(this.targetWrapper.bounds,h[M+1],!0)),b[parseInt(M.toString(),10)].bezierPoint2=KI(h[M+1],h[parseInt(M.toString(),10)],S));h.splice(1,0,{x:b[0].bezierPoint1.x,y:b[0].bezierPoint1.y}),h.splice(h.length-1,0,{x:b[b.length-1].bezierPoint2.x,y:b[b.length-1].bezierPoint2.y}),h=this.clipDecorators(e,h,r);for(var w=0;w0&&(s=this.bridgePath(e,s,D),s+=" L"+o.x+" "+o.y);return s},t.prototype.updateShapeElement=function(e){var i;switch(e.shape.type){case"Bpmn":e.wrapper.children[3]instanceof Ke&&(i=e.wrapper.children[3]),"Message"===e.shape.flow&&this.updateShapePosition(e,i);break;case"UmlActivity":"Exception"===e.shape.flow&&this.getUMLExceptionFlow(e.wrapper.children[0])}},t.prototype.updateShapePosition=function(e,i){var o=xF(this.intermediatePoints,i,.5);i.offsetX=o.x,i.offsetY=o.y},t.prototype.scale=function(e,i,r,s,o){var a=0,l=0;if(this.wrapper&&this.wrapper.outerBounds){var h=function T3(n){var t=n.wrapper.children[0].bounds;return"None"!==n.sourceDecorator.shape&&t.uniteRect(n.wrapper.children[1].bounds),"None"!==n.targetDecorator.shape&&t.uniteRect(n.wrapper.children[2].bounds),t}(this),c=Math.abs((this.wrapper.bounds.width||this.style.strokeWidth||1)-2),d=Math.abs((this.wrapper.bounds.height||this.style.strokeWidth||1)-2);a=h.width-c,l=h.height-d,e=Math.abs((r-Math.max(a,l))/c),i=Math.abs((s-Math.max(a,l))/d),a=l=Math.min(a,l)}e=i=Math.min(e,i);var u=Hi();qi(u,-(o=o||this.wrapper).rotateAngle,o.offsetX,o.offsetY),Gp(u,e,i,o.offsetX,o.offsetY),qi(u,o.rotateAngle,o.offsetX,o.offsetY);var p=function Uie(n,t){for(var e=[],i=0,r=t;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},tse=function(n){function t(e,i){var r=n.call(this,e,i)||this;return r.offset=0,r.scale=1,r}return ese(t,n),t.prototype.preRender=function(){this.unWireEvents(),this.wireEvents()},t.prototype.render=function(){this.updateRulerGeometry(),this.renderComplete()},t.prototype.getModuleName=function(){return"Ruler"},t.prototype.destroy=function(){this.unWireEvents(),this.notify("destroy",{}),n.prototype.destroy.call(this),this.element.classList.remove("e-ruler")},t.prototype.getPersistData=function(){return this.addOnPersist(["loaded"])},t.prototype.onPropertyChanged=function(e,i){for(var r=0,s=Object.keys(e);r100;)r/=10,s/=10;for(;s<25;)r*=10,s*=10;return s>=25&&s%25!=0&&(s=25*Math.round(s/25)),s*e/r},t.prototype.createMarkerLine=function(e,i,r){var s;return i&&((s=e.getElementById(i.id+"_marker"))&&s.parentNode.removeChild(s),s=Bi("line",r)),s},t.prototype.drawRulerMarker=function(e,i,r){var s,o,h,d,u="Horizontal"===this.orientation,p=e.getElementsByTagName("svg");for(h=0;h0)for(var a=i.childNodes.length-1;a>=0;a--)i.childNodes[parseInt(a.toString(),10)].parentNode.removeChild(i.childNodes[parseInt(a.toString(),10)]);i.appendChild(s)}return s},t.prototype.wireEvents=function(){},t.prototype.unWireEvents=function(){},zc([I(5)],t.prototype,"interval",void 0),zc([I(100)],t.prototype,"segmentWidth",void 0),zc([I("Horizontal")],t.prototype,"orientation",void 0),zc([I("RightOrBottom")],t.prototype,"tickAlignment",void 0),zc([I("red")],t.prototype,"markerColor",void 0),zc([I(25)],t.prototype,"thickness",void 0),zc([I(null)],t.prototype,"arrangeTick",void 0),zc([I(400)],t.prototype,"length",void 0),t}(yi);function oF(n,t){var e=document.getElementById(n.element.id+(t?"_hRuler":"_vRuler")),i=qa(n),r=aF(n);e||(e=Tt("div",{id:n.element.id+(t?"_hRuler":"_vRuler"),style:"height:"+(t?i.height:r.height+100)+"px;overflow:hidden;width:"+(t?r.width+100:i.width)+"px;position:absolute;font-size:11px;"+(t?"margin-left:"+i.width+"px;":"margin-top:"+i.height+"px;")})),n.element.insertBefore(e,n.element.firstChild);var l=t?n.rulerSettings.horizontalRuler:n.rulerSettings.verticalRuler,h=new tse(l);h.orientation=t?"Horizontal":"Vertical",h.length=(t?r.width:r.height)+l.segmentWidth,h.appendTo("#"+n.element.id+(t?"_hRuler":"_vRuler")),t?n.hRuler=h:n.vRuler=h;var c=document.getElementById(n.element.id+(t?"_hRuler":"_vRuler"));t?n.hRuler.element=c:n.vRuler.element=c}function eb(n){var t=-n.scroller.horizontalOffset,e=-n.scroller.verticalOffset;n&&n.rulerSettings.showRulers?(n.hRuler.length=0,n.vRuler.length=0,void 0!==t&&n.hRuler.element&&lF(n,n.hRuler,t,!0),void 0!==e&&n.vRuler.element&&lF(n,n.vRuler,e,!1)):$x(n)}function $x(n){an(n.element.id+"_hRuler"),an(n.element.id+"_vRuler"),an(n.element.id+"_overlapRuler")}function qa(n){var t=0,e=0;return n.rulerSettings.showRulers&&(t=n.rulerSettings.horizontalRuler.thickness,e=n.rulerSettings.verticalRuler.thickness),new me(e,t)}function aF(n){var t=qa(n),e=n.scroller.viewPortHeight,i=n.scroller.viewPortWidth;return i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},hF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return ase(t,n),t.prototype.getClassName=function(){return"UserHandle"},Fn([I("")],t.prototype,"name",void 0),Fn([I("")],t.prototype,"pathData",void 0),Fn([I("")],t.prototype,"content",void 0),Fn([I("")],t.prototype,"source",void 0),Fn([I("#000000")],t.prototype,"backgroundColor",void 0),Fn([I("Top")],t.prototype,"side",void 0),Fn([I("")],t.prototype,"borderColor",void 0),Fn([I(.5)],t.prototype,"borderWidth",void 0),Fn([I(25)],t.prototype,"size",void 0),Fn([I("white")],t.prototype,"pathColor",void 0),Fn([I(10)],t.prototype,"displacement",void 0),Fn([I(!0)],t.prototype,"visible",void 0),Fn([I(0)],t.prototype,"offset",void 0),Fn([re({},$n)],t.prototype,"margin",void 0),Fn([I("Center")],t.prototype,"horizontalAlignment",void 0),Fn([I("Center")],t.prototype,"verticalAlignment",void 0),Fn([I(!1)],t.prototype,"disableNodes",void 0),Fn([I(!1)],t.prototype,"disableConnectors",void 0),Fn([re({},xd)],t.prototype,"tooltip",void 0),Fn([I("")],t.prototype,"template",void 0),t}(Ee);function cF(n){return lse[n.toString()]}var lse={Action:"M 90 82.895 C 90 86.819 86.776 90 82.8 90 H 7.2 C 3.224 90 0 86.819 0 82.895 V 7.105 C 0 3.181 3.224 0 7.2 0 h 75.6 C 86.776 0 90 3.181 90 7.105 V 82.895 Z",Decision:"M10,19.707L0.293,10L10,0.293L19.707,10L10,19.707z",MergeNode:"M10,19.707L0.293,10L10,0.293L19.707,10L10,19.707z",InitialNode:"M10,19.5c-5.238,0-9.5-4.262-9.5-9.5S4.762,0.5,10,0.5s9.5,4.262,9.5,9.5S15.238,19.5,10,19.5z",ForkNode:"m0.75,0.75l636.00002,0l0,290l-636.00002,0l0,-290z",JoinNode:"m0.75,0.75l636.00002,0l0,290l-636.00002,0l0,-290z",TimeEvent:"M50.001,0.00286865 L25.001,25.0029 L0.000976562,0.00286865 L50.001,0.00286865 z M0.000976562,50.0029 L25.001,25.0029 L50.001,50.0029 L0.000976562,50.0029 z",AcceptingEvent:"M17.8336 32.164 L29.64 24 L17.32 16 L48.1664 16 L48.5 32 Z",SendSignal:"M48.164 31.8336 L56 23.832 L47.836 16 L16.168 16 L16.1668 31.8336 Z",ReceiveSignal:"M48.1664 31.8336 L39.836 24 L47.836 16 L16.168 16 L16.168 31.836 Z",StructuredNode:"M0,0 L50,0 L50,50 L0,50 z",Note:"M20 12 L4 12 L4 22 L22 22 L22 14 L20 14 L20 12 L22 14 Z"},tb=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),$a=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},hse=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return tb(t,n),$a([I()],t.prototype,"key",void 0),$a([I()],t.prototype,"keyModifiers",void 0),t}(Ee),dF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return tb(t,n),t.prototype.getClassName=function(){return"Command"},$a([I("")],t.prototype,"name",void 0),$a([I()],t.prototype,"canExecute",void 0),$a([I()],t.prototype,"execute",void 0),$a([re({},hse)],t.prototype,"gesture",void 0),$a([I("")],t.prototype,"parameter",void 0),t}(Ee),cse=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return tb(t,n),$a([Bt([],dF)],t.prototype,"commands",void 0),t}(Ee),dse=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return tb(t,n),$a([I()],t.prototype,"show",void 0),$a([I()],t.prototype,"showCustomMenuOnly",void 0),$a([I()],t.prototype,"items",void 0),t}(Ee),Jp=function(){function n(){}return n.prototype.renderShadow=function(t,e,i,r){void 0===i&&(i=null);var l,o=z.transform({x:0,y:0},t.shadow.angle,t.shadow.distance);r&&(l=r.getElementById(e.id+"_shadow")),l||(l=document.createElementNS("http://www.w3.org/2000/svg",i?"path":"rect"),e.appendChild(l));var h={id:e.id+"_shadow",fill:t.shadow.color,stroke:t.shadow.color,opacity:t.shadow.opacity.toString(),transform:"rotate("+t.angle+","+(t.x+t.width*t.pivotX)+","+(t.y+t.height*t.pivotY)+")translate("+(t.x+o.x)+","+(t.y+o.y)+")"};if(r){var c=r.getElementById(e.id);c&&c.insertBefore(l,c.firstChild)}oi(l,h),i?i&&this.renderPath(l,t,i):oi(l,{width:t.width,height:t.height})},n.prototype.parseDashArray=function(t){return[]},n.prototype.drawRectangle=function(t,e,i,r,s,o,a,l,h){var c,d,u,p;e.shadow&&!r&&this.renderShadow(e,t,void 0,o),c=e.id===t.id?e.id+"_container":e.id,o&&(d=o.getElementById(c)),(!d||s)&&(d=document.createElementNS("http://www.w3.org/2000/svg","rect"),t.appendChild(d)),o&&!e.shadow&&(u=o.getElementById(e.id+"_groupElement_shadow"))&&u.parentNode.removeChild(u),p=l?{id:c,x:e.x.toString(),y:e.y.toString(),width:e.width.toString(),height:e.height.toString(),visibility:e.visible?"visible":"hidden",transform:"rotate("+e.angle+","+(e.x+e.width/2)+","+(e.y+e.height/2)+")",rx:e.cornerRadius||0,ry:e.cornerRadius||0,opacity:e.opacity}:{id:c,x:e.x.toString(),y:e.y.toString(),width:e.width.toString(),height:e.height.toString(),visibility:e.visible?"visible":"hidden",transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")",rx:e.cornerRadius||0,ry:e.cornerRadius||0,opacity:e.opacity},a&&(p.role="img",p["aria-label"]=a);var f=e.class||"";h||(f.includes("e-diagram-resize-handle")||f.includes("e-diagram-endpoint-handle")||f.includes("e-diagram-bezier-control-handle"))&&(f+=" e-disabled"),e.class&&(p.class=f),a||(p["pointer-events"]="none"),oi(d,p),this.setSvgStyle(d,e,i)},n.prototype.updateSelectionRegion=function(t,e){var i;i=t.parentNode.getElementById(e.id);var r={id:e.id,x:e.x.toString(),y:e.y.toString(),width:e.width.toString(),height:e.height.toString(),transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")",class:"e-diagram-selected-region"};i||(i=document.createElementNS("http://www.w3.org/2000/svg","rect"),t.appendChild(i)),this.setSvgStyle(i,e),oi(i,r)},n.prototype.createGElement=function(t,e){return Bi(t,e)},n.prototype.drawLine=function(t,e){var i=document.createElementNS("http://www.w3.org/2000/svg","line");this.setSvgStyle(i,e);var r=e.x+e.width*e.pivotX,s=e.y+e.height*e.pivotY,o={id:e.id,x1:e.startPoint.x+e.x,y1:e.startPoint.y+e.y,x2:e.endPoint.x+e.x,y2:e.endPoint.y+e.y,stroke:e.stroke,"stroke-width":e.strokeWidth.toString(),opacity:e.opacity.toString(),transform:"rotate("+e.angle+" "+r+" "+s+")",visibility:e.visible?"visible":"hidden"};e.class&&(o.class=e.class),oi(i,o),t.appendChild(i)},n.prototype.drawCircle=function(t,e,i,r){var s=document.createElementNS("http://www.w3.org/2000/svg","circle");this.setSvgStyle(s,e);var o=e.class||"";i||(o+=" e-disabled");var a={id:e.id,cx:e.centerX,cy:e.centerY,r:e.radius,visibility:e.visible?"visible":"hidden",class:o};r&&(a.role="img",a["aria-label"]=r),s.style.display=e.visible?"block":"none",oi(s,a),t.appendChild(s)},n.prototype.drawPath=function(t,e,i,r,s,o,a){var h,c,l=[];l=e3(l=Dd(e.data)),e.shadow&&this.renderShadow(e,t,l,s),s&&!e.shadow&&(h=s.getElementById(e.id+"_groupElement_shadow"))&&h.parentNode.removeChild(h),s&&(c=s.getElementById(e.id)),(!c||r)&&(c=document.createElementNS("http://www.w3.org/2000/svg","path"),t.appendChild(c)),this.renderPath(c,e,l);var d={};d=a?{id:e.id,transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")translate("+e.x+","+e.y+"),scale("+a+")",visibility:e.visible?"visible":"hidden",opacity:e.opacity}:{id:e.id,transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")translate("+e.x+","+e.y+")",visibility:e.visible?"visible":"hidden",opacity:e.opacity},o&&(d.role="img",d["aria-label"]=o),e.class&&(d.class=e.class),oi(c,d),this.setSvgStyle(c,e,i)},n.prototype.renderPath=function(t,e,i){var r,s,o,a,l,h,c,d,u=i,p="";for(l=0,h=0,d=0,c=u.length;de.width&&"Wrap"!==e.textOverflow&&"NoWrap"===e.textWrapping&&(h[0].text=qF(e.content,e)),v=0;vD&&(u.text=u.text.slice(0,u.text.length-3),u.text=u.text.concat("..."),l.data=u.text),this.alignText(y,p,u,l,f,g,v,e,h),C+=u.dy}}C&&e.isHorizontalLane&&(M=e.parentOffsetX+e.pivotX,w=e.parentOffsetY+e.pivotY,e.y=e.parentOffsetY-C*e.pivotY+.5),e.textDecoration&&"LineThrough"===e.textDecoration&&(e.textDecoration=gb(e.textDecoration));var R={id:e.id+"_text",fill:e.color,visibility:e.visible?"visible":"hidden","text-decoration":e.textDecoration,transform:"rotate("+e.angle+","+M+","+w+")translate("+e.x+","+e.y+")",opacity:e.opacity};r&&(R.role="img",R["aria-label"]=r),oi(y,R)}},n.prototype.alignText=function(t,e,i,r,s,o,a,l,h){"justify"!==l.textAlign?this.setText(t,e,i,r,s,o,l):a!==h.length-1?this.setText(t,e,i,r,s,o,l,l.width,"spacing"):this.setText(t,e,i,r,s,o,l)},n.prototype.setText=function(t,e,i,r,s,o,a,l,h){oi(e,"justify"!==a.textAlign?{x:s.toString(),y:o.toString()}:{x:s.toString(),y:o.toString(),textLength:l||0,lengthAdjust:h||"spacing"}),t.setAttribute("fill",i.text),e.appendChild(r),t.appendChild(e)},n.prototype.drawImage=function(t,e,i,r){var s;i&&(s=i.getElementById(e.id+"image")),s||(s=document.createElementNS("http://www.w3.org/2000/svg","image"),t.appendChild(s));var o=new Image;o.src=e.source;var a="None"!==e.scale?e.scale:"",l=e.alignment,h=l.charAt(0).toLowerCase()+l.slice(1);"Stretch"!==a&&(h+=" "+a.charAt(0).toLowerCase()+a.slice(1)),oi(s,{id:e.id+"image",x:e.x.toString(),y:e.y.toString(),transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")",width:e.width.toString(),visibility:e.visible?"visible":"hidden",height:e.height.toString(),preserveAspectRatio:h,opacity:e.opacity.toString()}),s.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",o.src.toString())},n.prototype.drawHTMLContent=function(t,e,i,r,s){var o,a;if(e&&(o=e.querySelector("#"+t.id+"_html_element")),!o){(a=e.querySelector("#"+t.id+"_html_element")||e.querySelector("#"+t.nodeId+"_html_element"))||(a=Tt("div",{id:t.nodeId+"_html_element",class:"foreign-object"})),o=Tt("div",{id:t.id+"_html_element",class:"foreign-object"});var c=document.getElementById(t.diagramId).ej2_instances[0],d=!1;if(e.parentNode&&e.parentNode.parentNode&&e.parentNode.parentNode.parentNode&&e.parentNode.parentNode.parentNode.classList.contains("e-overview")&&(d=!0),d)c.isReact?c.renderReactTemplates(function(){o.appendChild(t.template.cloneNode(!0))}):o.appendChild(t.template.cloneNode(!0));else{if("string"==typeof t.template){var u=document.createElement("div");u.innerHTML=t.template,t.template=u,c.selectedItems.userHandles.filter(function(g){return g.name===t.id.split("_shape")[0]&&""!==g.template})[0].template=t.template}t.isTemplate&&t.template?o.appendChild(t.template):t.template&&o.appendChild(t.template.cloneNode(!0))}void 0!==s&&e.childNodes.length>s&&e.insertBefore(o,e.childNodes[parseInt(s.toString(),10)]),a.appendChild(o),e.appendChild(a)}var f=En(t).topLeft;o.setAttribute("style","height:"+t.actualSize.height+"px; width:"+t.actualSize.width+"px;left:"+f.x+"px; top:"+f.y+"px;position:absolute;transform:rotate("+(t.rotateAngle+t.parentTransform)+"deg);pointer-events:"+(r?"all":"none")+";visibility:"+(t.visible?"visible":"hidden")+";opacity:"+t.style.opacity+";")},n.prototype.drawNativeContent=function(t,e,i,r,s){var o,a;if(s&&(o=s.getElementById(t.id+"_native_element"),a=s.getElementById(t.id+"_clip")),!o){(o=document.createElementNS("http://www.w3.org/2000/svg","g")).setAttribute("id",t.id+"_native_element"),o.appendChild(t.template.cloneNode(!0));var l=this.createGElement("g",{id:t.id+"_inner_native_element"});l.appendChild(o),e.appendChild(l)}a&&o.removeChild(a),o.setAttribute("style","visibility:"+(t.visible?"visible":"hidden")+";opacity:"+t.style.opacity+";"),this.setNativTransform(t,o,i,r),"Slice"===t.scale&&this.drawClipPath(t,o,i,r,s),oi(o,t.description?{role:"img","aria-label":t.description}:{})},n.prototype.setNativTransform=function(t,e,i,r){var s=0!==t.contentSize.width?t.contentSize.width:1,o=0!==t.contentSize.height?t.contentSize.height:1;e.setAttribute("transform","rotate("+t.parentTransform+","+t.offsetX+","+t.offsetY+") translate("+(t.offsetX-t.templatePosition.x*r/s-r*t.pivot.x)+","+(t.offsetY-t.templatePosition.y*i/o-i*t.pivot.y)+") scale("+r/s+","+i/o+")")},n.prototype.drawClipPath=function(t,e,i,r,s){var o=t.contentSize.width,a=t.contentSize.height,l=t.width/(r/o),h=t.height/(i/a),c=t.templatePosition.x+(t.width>=t.height?0:(o-l)/2),d=t.templatePosition.y+(t.height>=t.width?0:(a-h)/2),u=s.getElementById(t.id+"_clip");(u=document.createElementNS("http://www.w3.org/2000/svg","clipPath")).setAttribute("id",t.id+"_clip"),e.appendChild(u);var p=s.getElementById(t.id+"_clip_rect");return p=document.createElementNS("http://www.w3.org/2000/svg","rect"),u.appendChild(p),oi(p,{id:t.id+"_clip_rect",width:l.toString(),height:h.toString(),x:c.toString(),y:d.toString()}),om()?e.setAttribute("clip-path","url("+location.protocol+"//"+location.host+location.pathname+"#"+t.id+"_clip)"):e.setAttribute("clip-path","url(#"+t.id+"_clip)"),e},n.prototype.renderGradient=function(t,e,i){var r,s,o,h,c,a=bT(i),l=a.getElementById(i+"gradient_pattern");if(l||(l=Bi("defs",{id:i+"gradient_pattern"}),a.insertBefore(l,a.firstChild)),bF(e.id),"None"!==t.gradient.type){for(var d=0;dt.width&&("Ellipsis"===t.textOverflow||"Clip"===t.textOverflow)&&"NoWrap"===t.textWrapping?0:.5*t.width:"right"===t.textAlign&&(c=1*t.width),s.x=0+c+(e?e.x:0),s.y=1.2+d-r.height/2,s},n}(),Rc=function(){function n(t,e,i){this.renderer=null,this.isSvgMode=!0,this.transform={x:0,y:0},this.diagramId=t,this.element=xt(this.diagramId),this.svgRenderer=e,this.isSvgMode=i,this.renderer=i?new Jp:new bo}return n.prototype.setCursor=function(t,e){t.style.cursor=e},n.prototype.setLayers=function(){this.iconSvgLayer=this.element.getElementsByClassName("e-ports-expand-layer")[0],this.adornerSvgLayer=this.element.getElementsByClassName("e-adorner-layer")[0],this.nativeSvgLayer=this.element.getElementsByClassName("e-native-layer")[0],this.diagramSvgLayer=this.element.getElementsByClassName("e-diagram-layer")[0]},n.prototype.getAdornerLayer=function(){return ST(this.diagramId)},n.prototype.getParentSvg=function(t,e,i){return this.diagramId&&t&&t.id?t.id.split("_icon_content").length>1||t.id.split("_nodeport").length>1||t.elementActions&Xr.ElementIsPort?this.iconSvgLayer:e&&"selector"===e?this.adornerSvgLayer:t instanceof Cn?this.nativeSvgLayer:this.diagramSvgLayer:i},n.prototype.getParentElement=function(t,e,i,r){var s=e;if(i&&this.diagramId&&t&&t.id){t.id.split("_icon_content").length>1?(s=i.getElementById(this.diagramId+"_diagramExpander"),e=null):t.id.split("_nodeport").length>1?s=i.getElementById(this.diagramId+"_diagramPorts"):t instanceof Cn?(s=i.getElementById(this.diagramId+"_nativeLayer"),e=null):t.elementActions&Xr.ElementIsPort?(s=i.getElementById(this.diagramId+"_diagramPorts"),e=null):s=i.getElementById(this.diagramId+"_diagramLayer");var o=this.getGroupElement(t,e||s,r);s=o.g,o.svg&&(i=o.svg)}return{g:s,svg:i}},n.prototype.getGroupElement=function(t,e,i){var r,o,s=this.getParentSvg(t);if(e&&s){if(s&&!(r=s.getElementById(t.id+"_groupElement"))&&s!==this.nativeSvgLayer){var a=this.nativeSvgLayer;r=a.getElementById(t.id+"_groupElement"),o=a}r||(r=this.svgRenderer.createGElement("g",{id:t.id+"_groupElement"}),void 0!==i&&e.childNodes.length>i?e.insertBefore(r,e.childNodes[parseInt(i.toString(),10)]):e.appendChild(r))}return{g:r,svg:o}},n.prototype.renderElement=function(t,e,i,r,s,o,a,l,h,c,d){t instanceof Cs?(t.id=t.id?t.id:Qe(),this.renderContainer(t,e,i,r,s,o,a,l,h,c,d)):t instanceof EI?this.renderImageElement(t,e,r,s,a):t instanceof Ke?this.renderPathElement(t,e,r,s,a,h,d):t instanceof ni?this.renderTextElement(t,e,r,s,a,c):t instanceof Cn?this.renderNativeElement(t,e,r,s,a):t instanceof Jn?this.renderHTMLElement(t,e,i,r,s,a,l):this.renderRect(t,e,r,s,h)},n.prototype.drawSelectionRectangle=function(t,e,i,r,s,o){var a={width:i*o.scale,height:r*o.scale,x:.5+(t=(t+o.tx)*o.scale),y:.5+(e=(e+o.ty)*o.scale),fill:"transparent",stroke:"gray",angle:0,pivotX:.5,pivotY:.5,strokeWidth:1,dashArray:"6 3",opacity:1,visible:!0,id:s.id+"_selected_region"},l=this.getAdornerLayer();this.svgRenderer.updateSelectionRegion(l,a)},n.prototype.renderHighlighter=function(t,e,i){var r=t.actualSize.width||2,s=t.actualSize.height||2,o=t.offsetX-r*t.pivot.x,a=t.offsetY-s*t.pivot.y;this.svgRenderer.drawRectangle(e,{width:r*i.scale,height:s*i.scale,x:o=(o+i.tx)*i.scale,y:a=(a+i.ty)*i.scale,fill:"transparent",stroke:"#8CC63F",angle:t.rotateAngle,pivotX:t.pivot.x,pivotY:t.pivot.y,strokeWidth:4,dashArray:"",opacity:1,cornerRadius:0,visible:!0,id:e.id+"_highlighter",class:"e-diagram-highlighter"},this.diagramId,void 0,void 0,e)},n.prototype.renderSelectionRectangle=function(t,e,i,r){var s=t.actualSize.width||2,o=t.actualSize.height||2,a=t.offsetX-s*t.pivot.x,l=t.offsetY-o*t.pivot.y,h={width:s*i.scale,height:o*i.scale,x:a=(a+i.tx)*i.scale,y:l=(l+i.ty)*i.scale,fill:"transparent",stroke:"#00cc00",angle:t.rotateAngle,pivotX:t.pivot.x,pivotY:t.pivot.y,strokeWidth:r?2:1,dashArray:"",opacity:1,cornerRadius:0,visible:!0,id:t.id+"_highlighter",class:r?"e-diagram-first-selection-indicator e-diagram-selection-indicator":"e-diagram-selection-indicator"},c=this.getParentSvg(t,"selector");this.svgRenderer.drawRectangle(e,h,this.diagramId,void 0,void 0,c)},n.prototype.renderSelectionLine=function(t,e,i,r){var s=this.getBaseAttributes(t,i);s.data=t.absolutePath,s.id=s.id+"_highlighter";var o=t.description?t.description:t.id;this.isSvgMode||(s.x=t.flipOffset.x?t.flipOffset.x:s.x,s.y=t.flipOffset.y?t.flipOffset.y:s.y),i&&(s.x=s.x*i.scale,s.y=s.y*i.scale),s.stroke="#00cc00",s.strokeWidth=r?2:1,s.class=r?"e-diagram-first-selection-indicator e-diagram-selection-indicator":"e-diagram-selection-indicator";var a=this.getParentSvg(t,"selector");this.svgRenderer.drawPath(e,s,this.diagramId,void 0,a,o,i.scale)},n.prototype.renderStackHighlighter=function(t,e,i,r,s,o,a){var l=t.actualSize.width||2,h=t.offsetX-l*t.pivot.x,c=t.actualSize.height||2,d=t.offsetY-c*t.pivot.y;h=(h+i.tx)*i.scale;var u,p=t.bounds,f="";if(d=(d+i.ty)*i.scale,r)if(o){var v,y;u="M 0 0 L "+(2+(g=l*i.scale))+" 0 Z",v=t.actualSize.width/Number(p.width?p.width:1)*i.scale,y=t.actualSize.height/Number(p.height?p.height:1)*i.scale,f=II(bI(Dd("M7,4 L8,4 8,7 11,7 11,8 8,8 8,11 7,11 7,8 4,8 4,7 7,7 z M7.5,0.99999994C3.9160004,1 1,3.9160004 0.99999994,7.5 1,11.084 3.9160004,14 7.5,14 11.084,14 14,11.084 14,7.5 14,3.9160004 11.084,1 7.5,0.99999994 z M7.5,0 C11.636002,0 15,3.3639984 15,7.5 15,11.636002 11.636002,15 7.5,15 3.3640003,15 0,11.636002 0,7.5 0,3.3639984 3.3640003,0 7.5,0 z")),v+g+2,y-8,!1,p.x,p.y,0,0),s.y>=t.offsetY&&(d+=c)}else{var g;a&&s.y>=t.offsetY&&(d+=c*i.scale),u="M -10 -10 L 0 0 Z M -10 10 L 0 0 Z M 0 0 L "+(g=l*i.scale)+" 0 Z M "+g+" 0 L "+(g+10)+" 10 Z L "+(g+10)+" -10 Z"}else u="M 10 -10 L 0 0 Z M -10 -10 L 0 0 Z M 0 0 L 0 "+(g=c*i.scale)+" Z M 0 "+g+" L -10 "+(g+10)+" Z L 10 "+(g+10)+" Z",s.x>=t.offsetX&&(h+=l*i.scale);this.svgRenderer.drawPath(e,{data:u+f,width:l*i.scale,height:c*i.scale,x:h,y:d,fill:"transparent",stroke:"#8CC63F",angle:t.rotateAngle,pivotX:t.pivot.x,pivotY:t.pivot.y,strokeWidth:1,dashArray:"",opacity:1,visible:!0,id:e.id+"_stack_highlighter",class:"e-diagram-highlighter"},this.diagramId)},n.prototype.drawLine=function(t,e){this.svgRenderer.drawLine(t,e)},n.prototype.drawPath=function(t,e){this.svgRenderer.drawPath(t,e,this.diagramId)},n.prototype.renderResizeHandle=function(t,e,i,r,s,o,a,l,h,c,d){var u=t.offsetX-t.actualSize.width*t.pivot.x,p=t.offsetY-t.actualSize.height*t.pivot.y,f=t.actualSize.height,g=t.actualSize.width;!c&&i&bt.Rotate&&UI(this.rendererActions)&&!z3(this.rendererActions)&&(this.renderPivotLine(t,e,o,s,a),this.renderRotateThumb(t,e,o,s,a)),this.renderBorder(t,e,o,l,h,c);var v=t.actualSize.width*r,y=t.actualSize.height*r;!h&&UI(this.rendererActions)&&!z3(this.rendererActions)&&(t.isTextAnnotation||(v>=40&&y>=40&&(s&mr.ResizeNorthWest&&this.renderCircularHandle("resizeNorthWest",t,u,p,e,qr(s,"ResizeNorthWest"),i&bt.ResizeNorthWest,o,void 0,a,{"aria-label":"Thumb to resize the selected object on top left side direction"},void 0,"e-diagram-resize-handle e-northwest",d),s&mr.ResizeNorthEast&&this.renderCircularHandle("resizeNorthEast",t,u+g,p,e,qr(s,"ResizeNorthEast"),i&bt.ResizeNorthEast,o,void 0,a,{"aria-label":"Thumb to resize the selected object on top right side direction"},void 0,"e-diagram-resize-handle e-northeast",d),s&mr.ResizeSouthWest&&this.renderCircularHandle("resizeSouthWest",t,u,p+f,e,qr(s,"ResizeSouthWest"),i&bt.ResizeSouthWest,o,void 0,a,{"aria-label":"Thumb to resize the selected object on bottom left side direction"},void 0,"e-diagram-resize-handle e-southwest",d),s&mr.ResizeSouthEast&&this.renderCircularHandle("resizeSouthEast",t,u+g,p+f,e,qr(s,"ResizeSouthEast"),i&bt.ResizeSouthEast,o,void 0,a,{"aria-label":"Thumb to resize the selected object on bottom right side direction"},void 0,"e-diagram-resize-handle e-southeast",d)),s&mr.ResizeNorth&&this.renderCircularHandle("resizeNorth",t,u+g/2,p,e,qr(s,"ResizeNorth"),i&bt.ResizeNorth,o,void 0,a,{"aria-label":"Thumb to resize the selected object on top side direction"},void 0,"e-diagram-resize-handle e-north",d),s&mr.ResizeSouth&&this.renderCircularHandle("resizeSouth",t,u+g/2,p+f,e,qr(s,"ResizeSouth"),i&bt.ResizeSouth,o,void 0,a,{"aria-label":"Thumb to resize the selected object on bottom side direction"},void 0,"e-diagram-resize-handle e-south",d),s&mr.ResizeWest&&this.renderCircularHandle("resizeWest",t,u,p+f/2,e,qr(s,"ResizeWest"),i&bt.ResizeWest,o,void 0,a,{"aria-label":"Thumb to resize the selected object on left side direction"},void 0,"e-diagram-resize-handle e-west",d),s&mr.ResizeEast&&this.renderCircularHandle("resizeEast",t,u+g,p+f/2,e,qr(s,"ResizeEast"),i&bt.ResizeEast,o,void 0,a,{"aria-label":"Thumb to resize the selected object on right side direction"},void 0,"e-diagram-resize-handle e-east",d)))},n.prototype.renderEndPointHandle=function(t,e,i,r,s,o,a,l,h,c){var f,g,d=t.sourcePoint,u=t.targetPoint,p=t.wrapper;if(this.renderCircularHandle("connectorSourceThumb",p,d.x,d.y,e,qr(r,"ConnectorSourceThumb"),i&bt.ConnectorSource,s,o,void 0,{"aria-label":"Thumb to move the source point of the connector"},void 0,"e-diagram-endpoint-handle e-sourceend",c),this.renderCircularHandle("connectorTargetThumb",p,u.x,u.y,e,qr(r,"ConnectorTargetThumb"),i&bt.ConnectorTarget,s,a,void 0,{"aria-label":"Thumb to move the target point of the connector"},void 0,"e-diagram-endpoint-handle e-targetend",c),l)if("Straight"===t.type&&t.segments.length>0)for(f=0;f0)for(f=0;f=3&&3===t.segments.length&&(S=1,b=t.segments.length-1),S=t.segments.length>t.maxSegmentThumb+2?2:S,b=t.segments.length>t.maxSegmentThumb+2?t.segments.length-2:b,1===t.segments.length&&t.segments[0].points.length<=2&&(S=1,b=t.segments.length),f=S;f=50&&i.allowDrag),this.renderOrthogonalThumb(t+"_"+(d+1),e,(i.points[parseInt(d.toString(),10)].x+i.points[d+1].x)/2,(i.points[parseInt(d.toString(),10)].y+i.points[d+1].y)/2,r,h,l,o,a,u)}else for(d=0;d=50&&i.allowDrag),this.renderOrthogonalThumb(t+"_"+(d+1),e,(i.points[parseInt(d.toString(),10)].x+i.points[d+1].x)/2,(i.points[parseInt(d.toString(),10)].y+i.points[d+1].y)/2,r,h,l,o,a,u)},n.prototype.renderOrthogonalThumb=function(t,e,i,r,s,o,a,l,h,c){var d,g,u=0,p=document.getElementById(this.diagramId);p&&(g=p.ej2_instances[0]);var y=h.constraints&qe.InheritSegmentThumbShape?g.segmentThumbShape:h.segmentThumbShape,b=h.constraints&qe.InheritSegmentThumbSize?g.segmentThumbSize:h.segmentThumbSize;if(d="horizontal"===a?function ure(n){return vre[""+n]}(y):c3(y),"Arrow"===y||"DoubleArrow"===y||"OpenArrow"===y)switch(c){case"Bottom":case"Right":u=180;break;default:u=0}else if("Fletch"===y||"OpenFetch"===y||"IndentedArrow"===y||"OutdentedArrow"===y)switch(c){case"Bottom":u=-90;break;case"Top":u=90;break;case"Right":u=180;break;default:u=0}var M={x:(i+l.tx)*l.scale-b/2,y:(r+l.ty)*l.scale-b/2,angle:u,fill:"#e2e2e2",stroke:"black",strokeWidth:1,dashArray:"",data:d,width:b,height:b,pivotX:.5,pivotY:.5,opacity:1,visible:o,id:t,class:"e-diagram-ortho-segment-handle"},w=af(M.data),C=new me(M.width,M.height),D=new Ke;M.data=D.updatePath(M.data,w,C),this.svgRenderer.drawPath(s,M,this.diagramId)},n.prototype.renderPivotLine=function(t,e,i,r,s){var o=t,l=!!(r&mr.Rotate);s&&(l=!1);var h=this.getBaseAttributes(o,i);h.fill="None",h.stroke="black",h.strokeWidth=1,h.dashArray="2,3",h.visible=l;var c=i.scale;h.x*=c,h.y*=c,h.width*=c,h.height*=c,h.id="pivotLine",h.class="e-diagram-pivot-line";var u={x:o.actualSize.width*o.pivot.x*c,y:0};h.startPoint={x:o.actualSize.width*o.pivot.x*c,y:-20},h.endPoint=u,this.svgRenderer.drawLine(e,h)},n.prototype.renderBezierLine=function(t,e,i,r,s,o){var l=this.getBaseAttributes(e,o);l.id=t,l.stroke="black",l.strokeWidth=1,l.dashArray="3,3",l.fill="None",l.class="e-diagram-bezier-control-line",l.x=0,l.y=0;var h=o.scale,g={x:(s.x+o.tx)*h,y:(s.y+o.ty)*h};l.startPoint={x:(r.x+o.tx)*h,y:(r.y+o.ty)*h},l.endPoint=g,this.svgRenderer.drawLine(i,l)},n.prototype.renderCircularHandle=function(t,e,i,r,s,o,a,l,h,c,d,u,p,f){var g=e,v={x:i,y:r};if(0!==g.rotateAngle||0!==g.parentTransform){var y=Hi();qi(y,g.rotateAngle+g.parentTransform,g.offsetX,g.offsetY),v=Je(y,v)}var S=this.getBaseAttributes(g);S.stroke="black",S.strokeWidth=1,void 0!==u?(S.id="segmentEnd_"+u,S.fill="#e2e2e2"):S.fill=h?"#8CC63F":"white",S.cornerRadius=f/2,S.angle=e.rotateAngle,S.id=t,S.visible=o,S.class=p,S.width=f,S.height=f,S.x=(v.x+l.tx)*l.scale,S.y=(v.y+l.ty)*l.scale,S.x=S.x-S.width/2,S.y=S.y-S.height/2,h&&(S.class+=" e-connected"),c&&(S.visible=!1);var b=this.getParentSvg(e,"selector");this.svgRenderer.drawRectangle(s,S,this.diagramId,!0,!0,b,d,!0,a)},n.prototype.renderBezierHandle=function(t,e,i,r,s,o,a,l,h,c,d,u,p){var v,f=document.getElementById(this.diagramId);f&&(v=f.ej2_instances[0]);var y=e,S={x:i,y:r};if(0!==y.rotateAngle||0!==y.parentTransform){var b=Hi();qi(b,y.rotateAngle+y.parentTransform,y.offsetX,y.offsetY),S=Je(b,S)}var D=a.constraints&qe.InheritSegmentThumbSize?v.segmentThumbSize:a.segmentThumbSize,A=c3(a.constraints&qe.InheritSegmentThumbShape?v.segmentThumbShape:a.segmentThumbShape),x=this.getBaseAttributes(y);x.stroke="black",x.strokeWidth=1,void 0!==d?(x.id="segmentEnd_"+d,x.fill="#e2e2e2"):x.fill=h?"#8CC63F":"white",x.angle=e.rotateAngle,x.id=t,x.visible=o,x.class=u,x.width=D,x.height=D,x.data=A,x.x=(S.x+l.tx)*l.scale,x.y=(S.y+l.ty)*l.scale,x.x=x.x-x.width/2,x.y=x.y-x.height/2,h&&(x.class+=" e-connected"),c&&(x.visible=!1);var R=af(x.data),L=new me(x.width,x.height),O=new Ke;x.data=O.updatePath(x.data,R,L);var N=this.getParentSvg(e,"selector");this.svgRenderer.drawPath(s,x,this.diagramId,!0,N)},n.prototype.renderBorder=function(t,e,i,r,s,o){var l=this.getBaseAttributes(t,i);l.x*=i.scale,l.y*=i.scale,l.width*=i.scale,l.height*=i.scale,l.fill="transparent",l.stroke="#097F7F",l.strokeWidth=1.2,l.gradient=null,l.dashArray="6,3",l.class="e-diagram-selector",o&&(l.class+=" e-diagram-lane"),l.id="borderRect",l.id=this.rendererActions&Qa.DrawSelectorBorder?"borderRect_symbol":"borderRect",r||(l.class+=" e-disabled"),s&&(l.class+=" e-thick-border"),l.cornerRadius=0;var h=this.getParentSvg(t,"selector");this.svgRenderer.drawRectangle(e,l,this.diagramId,void 0,!0,h)},n.prototype.renderUserHandler=function(t,e,i,r,s,o){for(var l,a=t.wrapper,h=0,c=t.userHandles;h0||d.disableNodes&&t.nodes.length>0||"Drag"===s&&o)&&(l=!1);var u=document.getElementById(d.name+"_template_hiddenUserHandle");u&&(d.template=u.childNodes[0].cloneNode(!0));var p=rT(t,d,i);if(p.x=(p.x+i.tx)*i.scale,p.y=(p.y+i.ty)*i.scale,d.visible&&(d.visible=!!(t.constraints&mr.UserHandle)),l)if(d.pathData){var f=d.pathData?d.pathData:d.content,g=this.getBaseAttributes(a);g.id=d.name+"_userhandle",g.fill=d.backgroundColor,g.stroke=d.borderColor,g.strokeWidth=d.borderWidth,g.centerX=p.x,g.centerY=p.y,g.radius=.5*d.size,g.class="e-diagram-userhandle-circle",g.angle=0,g.visible=d.visible,g.opacity=1,this.svgRenderer.drawCircle(e,g,1,{"aria-label":d.name+"user handle"});var y=[];y=bI(y=Dd(f));var S=af(f),w=II(y,(d.size-.45*d.size)/S.width,(d.size-.45*d.size)/S.height,!0,S.x,S.y,0,0);S=af(w),this.svgRenderer.drawPath(e,C={x:p.x-S.width/2,y:p.y-S.height/2,angle:0,id:"",class:"e-diagram-userhandle-path",fill:d.pathColor,stroke:d.backgroundColor,strokeWidth:.5,dashArray:"",data:w,width:d.size-5,height:d.size-5,pivotX:0,pivotY:0,opacity:1,visible:d.visible},this.diagramId,void 0,void 0,{"aria-label":d.name+"user handle"})}else if(d.content){var D=new Cn(d.name,this.diagramId);D.content=d.content,D.offsetX=p.x,D.offsetY=p.y,D.id=d.name+"_shape",D.horizontalAlignment="Center",D.verticalAlignment="Center",D.visible=d.visible,D.setOffsetWithRespectToBounds(p.x,p.y,"Fraction"),D.relativeMode="Object",D.description=d.name||"User handle",D.measure(new me(d.size,d.size)),D.arrange(D.desiredSize),this.svgRenderer.drawNativeContent(D,e,d.size,d.size,this.adornerSvgLayer)}else if(d.source){var C,A=new EI;(C=this.getBaseAttributes(A,i)).width=d.size,C.height=d.size,C.x=p.x-d.size/2,C.y=p.y-d.size/2,C.sourceWidth=d.size,C.sourceHeight=d.size,C.alignment=A.imageAlign,C.source=d.source,C.scale=A.imageScale,C.visible=d.visible,C.description=d.name||"User handle",C.id=d.name+"_",this.renderer.drawImage(e,C,this.adornerSvgLayer,!1)}else{var x=new Jn(d.name,this.diagramId);x.offsetX=p.x,x.offsetY=p.y,x.id=d.name+"_shape",x.visible=d.visible,x.relativeMode="Object",x.template=d.template,x.measure(new me(d.size,d.size)),x.arrange(x.desiredSize),this.svgRenderer.drawHTMLContent(x,r,void 0,!0,void 0)}}},n.prototype.renderRotateThumb=function(t,e,i,r,s){new Ke;var a,l=new me;l.width=18,l.height=16;var d=!!(r&mr.Rotate);s&&(d=!1);var p=t.offsetX-t.actualSize.width*t.pivot.x+t.pivot.x*t.actualSize.width,f=t.offsetY-t.actualSize.height*t.pivot.y;if(a={x:(p=(p+i.tx)*i.scale)-.5*l.width,y:(f=(f+i.ty)*i.scale)-30-.5*l.height},0!==t.rotateAngle||0!==t.parentTransform){var g=Hi();qi(g,t.rotateAngle+t.parentTransform,(i.tx+t.offsetX)*i.scale,(i.ty+t.offsetY)*i.scale),a=Je(g,a)}this.svgRenderer.drawPath(e,{x:a.x,y:a.y,angle:t.rotateAngle+t.parentTransform,fill:"#231f20",stroke:"black",strokeWidth:.5,dashArray:"",data:"M 16.856144362449648 10.238890446662904 L 18.000144362449646 3.437890446662903L 15.811144362449646 4.254890446662903 C 14.837144362449646 2.5608904466629028 13.329144362449647 1.2598904466629026 11.485144362449645 0.5588904466629026 C 9.375144362449646 - 0.24510955333709716 7.071144362449646 - 0.18010955333709716 5.010144362449646 0.7438904466629028 C 2.942144362449646 1.6678904466629028 1.365144362449646 3.341890446662903 0.558144362449646 5.452890446662903 C - 0.244855637550354 7.567890446662903 - 0.17985563755035394 9.866890446662904 0.7431443624496461 11.930890446662904 C 1.6681443624496461 13.994890446662904 3.343144362449646 15.575890446662903 5.457144362449647 16.380890446662903 C 6.426144362449647 16.7518904466629 7.450144362449647 16.9348904466629 8.470144362449647 16.9348904466629 C 9.815144362449647 16.9348904466629 11.155144362449647 16.6178904466629 12.367144362449647 15.986890446662901 L 11.351144362449647 14.024890446662901 C 9.767144362449647 14.8468904466629 7.906144362449647 14.953890446662902 6.237144362449647 14.3178904466629 C 4.677144362449647 13.7218904466629 3.444144362449647 12.5558904466629 2.758144362449647 11.028890446662901 C 2.078144362449646 9.501890446662903 2.031144362449646 7.802890446662903 2.622144362449646 6.243890446662903 C 3.216144362449646 4.6798904466629025 4.387144362449646 3.442890446662903 5.914144362449646 2.760890446662903 C 7.437144362449646 2.078890446662903 9.137144362449646 2.0298904466629026 10.700144362449645 2.6258904466629027 C 11.946144362449646 3.100890446662903 12.971144362449646 3.9538904466629026 13.686144362449646 5.049890446662903 L 11.540144362449645 5.850890446662903 L 16.856144362449648 10.238890446662904 Z",width:20,height:20,pivotX:0,pivotY:0,opacity:1,visible:d,id:"rotateThumb",class:"e-diagram-rotate-handle"},this.diagramId,!0,void 0,{"aria-label":"Thumb to rotate the selected object"})},n.prototype.renderPathElement=function(t,e,i,r,s,o,a){var l=this.getBaseAttributes(t,i,o);if(l.data=t.absolutePath,l.data=t.absolutePath,t.isPathPort&&a){l.x=a[t.id]?a[t.id].cx:l.x,l.y=a[t.id]?a[t.id].cy:l.y,t.bounds.x=l.x,t.bounds.y=l.y;var h=document.getElementById(this.diagramId);h&&"PortDrag"!==h.ej2_instances[0].eventHandler.currentAction&&(t.offsetX=l.x+t.width/2,t.offsetY=l.y+t.height/2)}var u=t.description?t.description:t.id;if(this.isSvgMode||(l.x=t.flipOffset.x?t.flipOffset.x:l.x,l.y=t.flipOffset.y?t.flipOffset.y:l.y),t.isExport){var p=t.absoluteBounds,f=Dd(l.data),g=this.findAndStoreArcValues(f);l.arc=g,l.data=BF(t,p,0,l)}this.renderer.drawPath(e,l,this.diagramId,void 0,r,u)},n.prototype.findAndStoreArcValues=function(t){var e=[];return t.forEach(function(i){"A"===i.command&&e.push({r1:i.r1/2,r2:i.r2/2})}),e},n.prototype.renderSvgGridlines=function(t,e,i,r,s,o){var a=document.createElementNS("http://www.w3.org/2000/svg","pattern"),l=document.createElementNS("http://www.w3.org/2000/svg","defs");l.setAttribute("id",this.diagramId+"_grid_pattern_defn"),(t.constraints&Kt.ShowHorizontalLines||t.constraints&Kt.ShowVerticalLines)&&a.setAttribute("id",this.diagramId+"_pattern");var h=0,c=0,d=0,u=0,p=1,f=!1,g="Lines"===t.gridType,v=g?t.verticalGridlines.lineIntervals:t.verticalGridlines.dotIntervals,y=g?t.horizontalGridlines.lineIntervals:t.horizontalGridlines.dotIntervals;if(r.showRulers&&r.dynamicGrid&&s&&o)d=o.updateSegmentWidth(i.scale),u=s.updateSegmentWidth(i.scale),t.horizontalGridlines.scaledIntervals=[d/s.interval],t.verticalGridlines.scaledIntervals=[u/o.interval],f=!0;else{for(var S=0;S=2)for(;e>=2;)e/=2;else if(e<=.5)for(;e<=.5;)e*=2;var i;if(t.horizontalGridlines.scaledIntervals=t.horizontalGridlines.snapIntervals,t.verticalGridlines.scaledIntervals=t.verticalGridlines.snapIntervals,1!==e){var r=t.horizontalGridlines;for(r.scaledIntervals=[],i=0;ithis.groupElement.actualSize.height&&("Clip"===t.style.textOverflow||"Ellipsis"===t.style.textOverflow)&&(a.y=a.y+(a.height-this.groupElement.actualSize.height)/2),this.renderer.drawRectangle(e,a,this.diagramId,void 0,void 0,r),this.renderer.drawText(e,a,r,l,this.diagramId,t.isExport&&Math.min(t.exportScaleValue.x||t.exportScaleValue.y),this.groupElement),this.isSvgMode&&(t.doWrap=!1)},n.prototype.renderNativeElement=function(t,e,i,r,s){var o,a,l=this.getParentSvg(t,void 0,e)||r,h=this.getParentElement(t,e,l).g||e,c=this.getBaseAttributes(t,i);switch(c.fill="transparent",c.cornerRadius=t.cornerRadius,c.stroke="transparent",this.renderer.drawRectangle(e,c,this.diagramId,void 0,void 0,r),t.scale){case"None":o=t.contentSize.width,a=t.contentSize.height;break;case"Stretch":o=t.actualSize.width,a=t.actualSize.height;break;case"Meet":o=a=t.actualSize.width<=t.actualSize.height?t.actualSize.width:t.actualSize.height;break;case"Slice":o=a=t.actualSize.width>=t.actualSize.height?t.actualSize.width:t.actualSize.height}this.svgRenderer&&this.svgRenderer.drawNativeContent(t,h,a,o,l)},n.prototype.renderHTMLElement=function(t,e,i,r,s,o,a){var l=this.getBaseAttributes(t,r);l.fill="transparent",l.cornerRadius=t.cornerRadius,l.stroke="transparent",this.renderer.drawRectangle(e,l,this.diagramId,void 0,void 0,s),this.svgRenderer&&this.svgRenderer.drawHTMLContent(t,i.children[0],r,function Sse(n){var t=n.parentElement;do{if(pm(t,"e-diagram"))return!0;t=t.parentElement}while(t);return!1}(i),a)},n.prototype.renderImageElement=function(t,e,i,r,s){var o=this.getBaseAttributes(t,i);o.cornerRadius=0,this.renderer.drawRectangle(e,o,this.diagramId,void 0,void 0,r);var a,l,h,c,g,d=t.contentSize.width,u=t.contentSize.height,p=o.width/d,f=o.height/u;if("Stretch"===t.stretch)a=d*(g=Math.min(p,f)),l=u*g;else switch(t.stretch){case"Meet":a=d*(g=Math.min(p,f)),l=u*g,o.x+=Math.abs(o.width-a)/2,o.y+=Math.abs(o.height-l)/2;break;case"Slice":g=Math.max(p,f),h=o.width/(a=d*g)*d,c=o.height/(l=u*g)*u;break;case"None":a=d,l=u}o.width=a,o.height=l,o.sourceWidth=h,o.sourceHeight=c,o.source=t.source,o.alignment=t.imageAlign,o.scale=t.imageScale,o.description=t.description?t.description:t.id,this.renderer.drawImage(e,o,r,s)},n.prototype.renderContainer=function(t,e,i,r,s,o,a,l,h,c,d){var g,u={svg:s,g:e},p=document.getElementById(this.diagramId);if(p&&(g=p.ej2_instances[0]),this.diagramId&&(s=this.getParentSvg(t)||s,this.isSvgMode)){var v=this.getParentElement(t,e,s,l).g||e;s=this.getParentSvg(this.hasNativeParent(t.children))||s;var y=this.getParentElement(this.hasNativeParent(t.children),v,s,l);u.svg=y.svg||s,u.g=y.g||v,o&&s&&(s.getElementById(u.g.id)||e.appendChild(u.g)),e=u.g}if(this.renderRect(t,e,r,s),this.groupElement=t,t.hasChildren()){for(var b,S=void 0,M=0,w=t.children;M0&&(D=g.selectedItems.nodes[0]);var L,A=void 0,x=void 0,R=!1;if(g&&g.selectedItems&&(L=g.getObject(t.id)),"None"!==t.flip&&(D=L),"None"===t.flip&&(D=L),D&&D.flipMode&&(R=!0),!(t.elementActions&Xr.ElementIsGroup)&&g instanceof Rl&&g.nameTable[t.id]&&"connectors"!==g.nameTable[t.id].propName&&R&&D){if(A=t.children&&t.children[0]instanceof Cn?document.getElementById(D.id+"_content_inner_native_element"):document.getElementById(D.id+"_content_groupElement"),!(t.children[0]instanceof Cn)&&"Text"!==D.shape.type&&"None"!==D.flipMode&&"Label"!==D.flipMode&&"All"!==D.flipMode&&"PortAndLabel"!==D.flipMode&&"LabelText"!==D.flipMode&&"PortAndLabelText"!==D.flipMode&&"LabelAndLabelText"!==D.flipMode||t.children[0]instanceof Cn&&"Port"===D.flipMode)return void this.renderFlipElement(t,A,D.flip);if((t.children[0]instanceof Cn&&("All"===D.flipMode||"Label"===D.flipMode)||"Label"===D.flipMode||"PortAndLabel"===D.flipMode||"LabelText"===D.flipMode||"PortAndLabelText"===D.flipMode||"LabelAndLabelText"===D.flipMode||"Image"===D.shape.type&&"Label"===D.flipMode)&&this.renderFlipElement(t,A,t.flip),"None"!==t.flip&&"None"===D.flipMode)this.renderFlipElement(t,A,t.flip);else if("None"!==t.flip&&("Label"===D.flipMode||"PortAndLabel"===D.flipMode||"LabelText"===D.flipMode||"PortAndLabelText"===D.flipMode||"LabelAndLabelText"===D.flipMode)||t.children[0]instanceof Cn&&"None"!==t.flip&&D&&("None"===D.flipMode||"All"===D.flipMode)){for(var O=0;O0){var i=t[0];if(i instanceof Cn)return i;i.children&&i.children.length&&this.hasNativeParent(i.children,e++||0)}},n.prototype.renderRect=function(t,e,i,r,s){var o=this.getBaseAttributes(t,i,s);o.cornerRadius=t.cornerRadius||0,t.isExport&&(o.cornerRadius*=t.exportScaleValue.x),this.renderer.drawRectangle(e,o,this.diagramId,t.isExport,void 0,r,t.description?t.description:t.id)},n.prototype.drawRect=function(t,e){e.cornerRadius=0,this.svgRenderer.drawRectangle(t,e,this.diagramId)},n.prototype.getBaseAttributes=function(t,e,i){var r={width:t.actualSize.width,height:t.actualSize.height,x:t.offsetX-t.actualSize.width*t.pivot.x,y:t.offsetY-t.actualSize.height*t.pivot.y,fill:t.style.fill,stroke:t.style.strokeColor,angle:t.rotateAngle+t.parentTransform,pivotX:t.pivot.x,pivotY:t.pivot.y,strokeWidth:t.style.strokeWidth,dashArray:t.style.strokeDashArray||"",opacity:t.style.opacity,shadow:t.shadow,gradient:t.style.gradient,visible:t.visible,id:t.id,description:t.description,canApplyStyle:t.canApplyStyle,shapeType:t.shapeType};return"Page"===t.rotationReference&&(r.angle=t.rotateAngle),i&&(r.x=r.x-.5,r.y=r.y-.5),t.isExport&&(r.width*=t.exportScaleValue.x,r.height*=t.exportScaleValue.y,r.x*=t.exportScaleValue.x,r.y*=t.exportScaleValue.y,r.strokeWidth*=t.exportScaleValue.x),t.flip&&(r.flip=t.flip),e&&(r.x+=e.tx,r.y+=e.ty),r},n.renderSvgBackGroundImage=function(t,e,i,r,s,o){if(t.source){var l=bT(e.id).getElementById(e.id+"_image");if(!l){var h=function Toe(n){return xt(n).getElementsByClassName("e-background-image-layer")[0]}(e.id);(l=document.createElementNS("http://www.w3.org/2000/svg","image")).setAttribute("id",e.id+"_image"),h.appendChild(l)}var c=new Image;c.src=t.source,l.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",c.src.toString());var d="None"!==t.scale?t.scale:"",u=t.align,p=u.charAt(0).toLowerCase()+u.slice(1);d&&(p+=" "+d.charAt(0).toLowerCase()+d.slice(1)),oi(l,{id:e.id+"_image",x:i,y:r,width:s,height:o,preserveAspectRatio:p})}},n.prototype.transformLayers=function(t,e){var i=t.tx*t.scale,r=t.ty*t.scale,s="domTable";if(i!==this.transform.x||r!==this.transform.y||0===i||0===r){e&&(window[""+s][this.diagramId+"_diagramLayer"]||(window[""+s][this.diagramId+"_diagramLayer"]=this.diagramSvgLayer.getElementById(this.diagramId+"_diagramLayer")),window[""+s][this.diagramId+"_diagramLayer"].setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+"),scale("+t.scale+")"));var a=function Aoe(n){var t="domTable",e=null;return window[t][n+"_gridline"]?e=window[t][n+"_gridline"]:(e=_d(n).getElementById(n+"_gridline"),window[t][n+"_gridline"]=e),e}(this.diagramId);return a.setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+")"),window[""+s][this.diagramId+"_diagramPorts"]||(window[""+s][this.diagramId+"_diagramPorts"]=this.iconSvgLayer.getElementById(this.diagramId+"_diagramPorts")),window[""+s][this.diagramId+"_diagramPorts"].setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+"),scale("+t.scale+")"),window[""+s][this.diagramId+"_diagramExpander"]||(window[""+s][this.diagramId+"_diagramExpander"]=this.iconSvgLayer.getElementById(this.diagramId+"_diagramExpander")),window[""+s][this.diagramId+"_diagramExpander"].setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+"),scale("+t.scale+")"),window[""+s][this.diagramId+"_nativeLayer"]||(window[""+s][this.diagramId+"_nativeLayer"]=this.nativeSvgLayer.getElementById(this.diagramId+"_nativeLayer")),window[""+s][this.diagramId+"_nativeLayer"].setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+"),scale("+t.scale+")"),Io(this.diagramId).children[0].style.transform="translate("+t.tx*t.scale+"px,"+t.ty*t.scale+"px)scale("+t.scale+")",this.transform={x:t.tx*t.scale,y:t.ty*t.scale},!0}return!1},n.prototype.updateNode=function(t,e,i,r,s,o,a){this.renderElement(t,e,i,r,this.getParentSvg(t),void 0,void 0,s,null,o,a)},n}(),use=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),ib=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},uF=function(n){function t(e,i){var r=n.call(this,e,i)||this;return r.mode="Canvas",r.id="overview",r.actionName="",r.startPoint=null,r.currentPoint=null,r.prevPoint=null,r.scale=null,r.inAction=!1,r.viewPortRatio=1,r.horizontalOffset=0,r.verticalOffset=0,r.model={},r.event=!0,r.overviewid=88123,r.model={width:r.width,height:r.height},r}return use(t,n),t.prototype.onPropertyChanged=function(e,i){for(var r=0,s=Object.keys(e);r0||e.toString().indexOf("%")>0?e.toString():e.toString()+"px"},t.prototype.renderCanvas=function(e){var i=document.getElementById(this.element.id+"_canvas");i||(i=Tt("div",{}),this.element.appendChild(i)),Ho(i,{id:this.element.id+"_canvas",class:"drawing",style:"position:relative; height:"+this.getSizeValue(this.model.height)+"; width:"+this.getSizeValue(this.model.width)+";style:-ms-touch-action: none;touch-action: none;"}),this.element.setAttribute("tabindex",String(-1)),this.element.style.overflow="hidden",this.element.style.height=String(this.model.height),this.element.style.width=String(this.model.width),this.canvas=i},t.prototype.setParent=function(e){var i=document.getElementById(e);if(this.parent){var s=this.parent;this.parent=null,s.setOverview(null,this.element.id),this.removeDocument(this)}this.parent=this.getDiagram(i,"ej2_instances"),this.parent&&this.parent.setOverview(this)},t.prototype.getDiagram=function(e,i){for(var r,s=e[""+i].length,o=0;o0?p:Math.floor(window.innerWidth)}if(0===h){var f=Math.floor(window.innerHeight-u-Math.floor(c.top));h=f>0?f:Math.floor(window.innerHeight)}l>0&&(s.setAttribute("width",String(l)),this.model.height=h),h>0&&(s.setAttribute("height",String(h)),this.model.width=l),e.diagramLayerDiv||(e.diagramLayerDiv=Tt("div",{}),e.diagramLayer=bo.createCanvas(this.element.id+"_diagramLayer",this.model.width,this.model.height),e.diagramLayer.setAttribute("style","position:absolute; left:0px; top:0px "),e.diagramLayerDiv.appendChild(e.diagramLayer),e.canvas.appendChild(e.diagramLayerDiv)),Ho(e.diagramLayerDiv,{id:this.element.id+"_diagramLayer_div",style:"width:"+this.model.width+"px; height:"+this.model.height+"px;position:absolute;top:0px;left:0px"}),this.renderHtmlLayer(e.canvas),this.renderNativeLayer(e.canvas,e),this.addOverviewRectPanel(e)},t.prototype.removeDocument=function(e){var i=document.getElementById(this.canvas.id+"_svg");this.canvas.removeChild(i);var r=document.getElementById(this.element.id+"_htmlLayer");this.canvas.removeChild(r);var s=document.getElementById(this.element.id+"_diagramLayer_div");this.canvas.removeChild(s),e.diagramLayerDiv=null,e.diagramLayer=null,window.domTable[this.id+"html_layer"]=null},t.prototype.renderHtmlLayer=function(e){var i=Tt("div",{id:this.element.id+"_htmlLayer",class:"e-html-layer",style:"pointer-events:none;position:absolute;top:0px;left:0px;"}),s=Tt("div",{id:this.element.id+"_htmlLayer_div",style:"position:absolute;top:0px;left:0px;"});return i.appendChild(s),e.appendChild(i),i},t.prototype.renderNativeLayer=function(e,i){if(!document.getElementById(this.element.id+"_nativeLayer_svg")){var r=this.parent.createSvg(this.element.id+"_nativeLayer_svg",this.model.width,this.model.height),s=Bi("g",{id:this.element.id+"_nativeLayer"});r.appendChild(s),i.diagramLayerDiv.appendChild(r),oi(r,{class:"e-native-layer"})}},t.prototype.addOverviewRectPanel=function(e){var i=document.getElementById(this.canvas.id+"_overviewsvg");i&&i.parentNode.removeChild(i),i=Bi("svg",{id:this.canvas.id+"_overviewsvg",class:"overviewsvg",version:"1.1",style:"position:absolute;left:0px;top:0px; aria-label:Specifies overview",width:this.model.width,height:this.model.height}),e.canvas.appendChild(i);var s=Bi("g",{id:this.element.id+"_overviewlayer",style:"pointer-events:none"});i.appendChild(s);var o=Bi("rect",{fill:"transparent",width:"100%",height:"100%",class:"overviewbackrect",id:this.canvas.id+"overviewbackrect"});o.setAttribute("style"," pointer-events: none; "),s.appendChild(o);var a=Bi("g",{id:this.canvas.id+"overviewhandle",style:"pointer-events:all"});s.appendChild(a);var l=Bi("rect",{id:this.canvas.id+"overviewrect",fill:"transparent"});a.appendChild(l),this.renderOverviewCorner("left",a),this.renderOverviewCorner("right",a),this.renderOverviewCorner("top",a),this.renderOverviewCorner("bottom",a),this.renderOverviewCorner("topleft",a),this.renderOverviewCorner("topright",a),this.renderOverviewCorner("bottomleft",a),this.renderOverviewCorner("bottomright",a)},t.prototype.renderOverviewCorner=function(e,i){var s,o=Bi(s="top"===e||"bottom"===e||"right"===e||"left"===e?"rect":"circle",{id:this.canvas.id+"visible"+e,class:"overview-resizer"});i.appendChild(o);var a=Bi(s,{id:this.canvas.id+e,class:"overviewresizer",fill:"transparent"});i.appendChild(a)},t.prototype.updateOverviewRectangle=function(){var e=this.currentPoint.x-this.prevPoint.x,i=this.currentPoint.y-this.prevPoint.y,r=new me;r.width=0,r.height=0;var s=0,o=0;switch(this.resizeDirection){case"left":r.width-=e,r.height-=e/this.viewPortRatio,s=e,o=e/this.viewPortRatio,o/=2;break;case"right":r.width+=e,r.height+=e/this.viewPortRatio,o=e/this.viewPortRatio,o/=-2;break;case"top":r.height-=i,r.width-=i*this.viewPortRatio,o=i,s=i*this.viewPortRatio,s/=2;break;case"bottom":r.height+=i,r.width+=i*this.viewPortRatio,s=i*this.viewPortRatio,s/=-2;break;case"topleft":Math.abs(i)>Math.abs(e)?e=i*this.viewPortRatio:i=e/this.viewPortRatio,r.width-=e,r.height-=i,s=e,o=i;break;case"topright":Math.abs(i)>Math.abs(e)?e=-i*this.viewPortRatio:i=-e/this.viewPortRatio,o=i,r.width+=e,r.height-=i;break;case"bottomleft":Math.abs(i)>Math.abs(e)?e=-i*this.viewPortRatio:i=-e/this.viewPortRatio,s=e,r.width-=e,r.height+=i;break;case"bottomright":Math.abs(i)>Math.abs(e)?e=i*this.viewPortRatio:i=e/this.viewPortRatio,r.width+=e,r.height+=i}this.updateHelper(s,o,r,void 0,void 0)},t.prototype.updateHelper=function(e,i,r,s,o){var a,l,h,u,p,d=this.element.getElementsByTagName("svg")[2].getElementById("helper");r?(a=(h=d.getBBox()).x+e,l=h.y+i,s=h.width+r.width,o=h.height+r.height):(u=this.currentPoint.x>this.startPoint.x?this.currentPoint.x-this.prevPoint.x:this.prevPoint.x-this.currentPoint.x,p=this.currentPoint.y>this.startPoint.y?this.currentPoint.y-this.prevPoint.y:this.prevPoint.y-this.currentPoint.y,Math.abs(p)>Math.abs(u)?u=this.viewPortRatio*p:p=u/this.viewPortRatio,h=d.getBBox(),a=this.startPoint.x>this.currentPoint.x?h.x-u:h.x,l=this.startPoint.y>this.currentPoint.y?h.y-p:h.y,s=h.width+u,o=h.height+p),oi(this.helper,{id:this.helper.id,x:a,y:l,width:Math.max(0,s),height:Math.max(0,o)})},t.prototype.updateOverviewrect=function(e,i,r,s){Ho(document.getElementById(this.canvas.id+"overviewrect"),{x:e,y:i,width:Math.max(1,r),height:Math.max(1,s)}),this.updateOverviewCorner("top",e+8,i+1,Math.max(0,r-16),2),this.updateOverviewCorner("bottom",e+8,i+s+3,Math.max(0,r-16),2),this.updateOverviewCorner("left",e-2,i+11,2,Math.max(0,s-16)),this.updateOverviewCorner("right",e+r,i+11,2,Math.max(0,s-16)),this.updateOverviewCorner("topleft",e,i+3,5,5),this.updateOverviewCorner("topright",e+r,i+3,5,5),this.updateOverviewCorner("bottomleft",e,i+s+3,5,5),this.updateOverviewCorner("bottomright",e+r,i+s+3,5,5)},t.prototype.updateOverviewCorner=function(e,i,r,s,o){var a,l;"top"===e||"bottom"===e||"right"===e||"left"===e?(a={x:i,y:r,width:s,height:o,fill:"#ED1C24"},l={x:i-2,y:r-2,width:2===s?4:s,height:2===o?4:o}):(a={cx:i,cy:r,r:4,fill:"#ED1C24"},l={cx:i,cy:r,r:6,fill:"transparent"}),Ho(document.getElementById(this.canvas.id+"visible"+e),a),Ho(document.getElementById(this.canvas.id+e),l)},t.prototype.translateOverviewRectangle=function(){Number(this.model.width),Number(this.model.height);var r=this.currentPoint.x-this.prevPoint.x,s=this.currentPoint.y-this.prevPoint.y,l=this.element.getElementsByClassName("overviewsvg")[0].getElementById(this.canvas.id+"overviewrect").getBBox(),h=l.x+r,c=l.y+s,d=l.width,u=l.height;this.updateOverviewrect(h,c,d,u),this.updateParentView(this.parent.scroller.currentZoom,h,c,d,u,null)},t.prototype.renderOverviewRect=function(e,i,r,s){var o=Number(this.model.width),a=Number(this.model.height),c=Math.max(this.parent.scroller.viewPortWidth/(r/o*this.contentWidth),this.parent.scroller.viewPortHeight/(s/a*this.contentHeight));if(c>=.25&&c<=30){this.updateParentView(c,e,i,r,s,{x:0,y:0});var u=this.scrollOverviewRect(this.parent.scroller.horizontalOffset,this.parent.scroller.verticalOffset,this.parent.scroller.currentZoom,!0);if(this.helper){var f=this.element.getElementsByTagName("rect")[10].getBBox();u.x=f.x,u.y=f.y}"pan"===this.actionName?this.updateOverviewrect(-u.x,-u.y,u.width,u.height):this.updateOverviewrect(u.x,u.y,u.width,u.height)}},t.prototype.scrollOverviewRect=function(e,i,r,s){if(!this.actionName||s){var o=Number(this.model.width),a=Number(this.model.height),l=Math.min(this.contentWidth/o,this.contentHeight/a),h=new Ne,c=h.x=e/r/l,d=h.y=i/r/l,u=0;this.parent.rulerSettings.showRulers&&(u=25);var p=document.getElementById(this.parent.element.id+"content"),f=0,g=0;p&&(f=p.offsetWidth-p.clientWidth,g=p.offsetHeight-p.clientHeight);var v=h.width=(this.parent.scroller.viewPortWidth-u-f)/r/l,y=h.height=(this.parent.scroller.viewPortHeight-u-g)/r/l;if(s){var S=new Ne;return S.x=c,S.y=d,S.width=v,S.height=y,S}this.updateOverviewrect(-c,-d,v,y)}return null},t.prototype.updateParentView=function(e,i,r,s,o,a){var f,g,l=Number(this.model.width),h=Number(this.model.height),u=i*(this.contentWidth/l)*e,p=r*(this.contentHeight/h)*e;this.parent.scroller.getPageBounds(),(1!==e||"pan"===this.actionName)&&(f=-u-this.parent.scroller.horizontalOffset,g=-p-this.parent.scroller.verticalOffset),this.parent.setBlazorDiagramProps(!0),this.parent.realActions|=$i.OverViewAction,"scale"===this.actionName||"draw"===this.actionName?this.parent.scroller.zoom(e/this.parent.scroller.currentZoom,f,g,a):ce()?this.parent.scroller.zoom(1,f,g,a):this.parent.pan(f,g,a,!0)},t.prototype.updateHtmlLayer=function(e){var i=Io(e.element.id),r=this.parent.scroller.getPageBounds(!0),o=r.height,a=Math.max(r.width,this.parent.scroller.viewPortWidth),l=Math.max(o,this.parent.scroller.viewPortHeight/this.parent.scroller.currentZoom),h=Math.min(Number(this.model.width)/a,Number(this.model.height)/l);i.style.transform="scale("+h+") translate("+this.parent.scroller.transform.tx+"px,"+this.parent.scroller.transform.ty+"px)"},t.prototype.updateView=function(e){var i=this.parent.scroller.getPageBounds(),r=i.width,s=i.height,o=Number(this.model.width),a=Number(this.model.height),l=Math.max(r,this.parent.scroller.viewPortWidth),h=Math.max(s,this.parent.scroller.viewPortHeight);this.contentWidth=l=Math.max(l,o/a*h),this.contentHeight=h=Math.max(h,a/o*l);var c=Math.min(o/l,a/h),d=document.getElementById(this.element.id+"_htmlLayer");d.style.webkitTransform="scale("+c+") translate("+-i.x+"px,"+-i.y+"px)",d.style.transform="scale("+c+") translate("+-i.x+"px,"+-i.y+"px)",document.getElementById(this.element.id+"_overviewlayer").setAttribute("transform","translate("+-i.x*c+","+-i.y*c+")"),this.horizontalOffset=i.x*c,this.verticalOffset=i.y*c;var p=document.getElementById(this.element.id+"_diagramLayer"),f=UF(this.element.id),g=p.getContext("2d"),v=Number(this.model.width)/this.contentWidth,y=Number(this.model.height)/this.contentHeight;v=Math.min(v,y);var S=this.parent.scroller.transform;f.setAttribute("transform","translate("+S.tx*v+","+S.ty*y+"),scale("+v+")"),g.setTransform(v,0,0,v,0,0),g.fillStyle="red",this.scrollOverviewRect(this.parent.scroller.horizontalOffset,this.parent.scroller.verticalOffset,this.parent.scroller.currentZoom)},t.prototype.scrolled=function(e){if(this.event){var i=this.scrollOverviewRect(this.parent.scroller.horizontalOffset,this.parent.scroller.verticalOffset,this.parent.scroller.currentZoom,!0);this.updateOverviewrect(-i.x,-i.y,i.width,i.height),this.updateView(this)}},t.prototype.updateCursor=function(e){if(pm(e.target,"overviewresizer"))switch(e.target.id){case this.canvas.id+"left":this.canvas.style.cursor="w-resize";break;case this.canvas.id+"right":this.canvas.style.cursor="e-resize";break;case this.canvas.id+"top":this.canvas.style.cursor="n-resize";break;case this.canvas.id+"bottom":this.canvas.style.cursor="s-resize";break;case this.canvas.id+"topleft":this.canvas.style.cursor="nw-resize";break;case this.canvas.id+"topright":this.canvas.style.cursor="ne-resize";break;case this.canvas.id+"bottomleft":this.canvas.style.cursor="sw-resize";break;case this.canvas.id+"bottomright":this.canvas.style.cursor="se-resize"}else this.canvas.style.cursor="default"},t.prototype.mouseMove=function(e){if(this.event=!1,this.updateCursor(e),this.currentPoint=this.mousePosition(e),this.actionName)switch(this.actionName){case"draw":!this.inAction&&(this.startPoint.x!==this.currentPoint.x||this.startPoint.y!==this.currentPoint.y)&&(this.initHelper(),this.inAction=!0),this.inAction&&this.updateHelper();break;case"scale":this.inAction||(this.initHelper(),this.inAction=!0),this.updateOverviewRectangle();break;case"pan":(this.startPoint.x!==this.currentPoint.x||this.startPoint.y===this.currentPoint.y||this.inAction)&&(this.inAction=!0,this.translateOverviewRectangle())}this.prevPoint=this.currentPoint},t.prototype.documentMouseUp=function(e){this.inAction=!1,this.actionName="",this.helper&&(this.helper.parentNode.removeChild(this.helper),this.helper=null),this.event=!0,document.getElementById(this.canvas.id+"overviewhandle").style.pointerEvents="all"},t.prototype.windowResize=function(e){var i=this;return this.resizeTo&&clearTimeout(this.resizeTo),this.resizeTo=setTimeout(function(){var s=document.getElementById(i.element.id).getBoundingClientRect();i.model.width=s.width>0?s.width:i.model.width,i.model.height=s.height>0?s.height:i.model.height,i.renderCanvas(),i.setParent(i.sourceID)},10),!1},t.prototype.mouseDown=function(e){if(e.target.id===this.canvas.id+"_overviewsvg"&&(this.actionName="draw"),e.target.id===this.canvas.id+"overviewrect"&&(this.actionName="pan"),pm(e.target,"overviewresizer"))switch(this.actionName="scale",e.target.id){case this.canvas.id+"left":this.resizeDirection="left";break;case this.canvas.id+"right":this.resizeDirection="right";break;case this.canvas.id+"top":this.resizeDirection="top";break;case this.canvas.id+"bottom":this.resizeDirection="bottom";break;case this.canvas.id+"topleft":this.resizeDirection="topleft";break;case this.canvas.id+"topright":this.resizeDirection="topright";break;case this.canvas.id+"bottomleft":this.resizeDirection="bottomleft";break;case this.canvas.id+"bottomright":this.resizeDirection="bottomright"}this.startPoint=this.prevPoint=this.mousePosition(e),this.viewPortRatio=this.parent.scroller.viewPortWidth/this.parent.scroller.viewPortHeight,document.getElementById(this.canvas.id+"overviewhandle").style.pointerEvents="none"},t.prototype.mouseUp=function(e){if(this.currentPoint=this.mousePosition(e),this.actionName)if(this.startPoint.x!==this.currentPoint.x||this.startPoint.y!==this.currentPoint.y){if("pan"!==this.actionName&&this.helper){var i=this.element.getElementsByTagName("rect")[10].getBBox();this.resizeDirection=this.resizeDirection||"",this.renderOverviewRect(i.x,i.y,o=i.width,a=i.height)}}else if(e.target.id===this.canvas.id+"_overviewsvg"||"helper"===e.target.id){var o=(i=this.element.getElementsByTagName("svg")[2].getElementById(this.canvas.id+"overviewrect").getBBox()).width,a=i.height;this.inAction=!0,this.actionName="pan",this.renderOverviewRect(this.currentPoint.x-o/2,this.currentPoint.y-a/2,o,a),this.inAction=!1}this.helper&&(this.helper.parentNode.removeChild(this.helper),this.helper=null),this.actionName="",this.startPoint=null,this.currentPoint=null,this.prevPoint=null,this.helper=null,this.viewPortRatio=1,this.resizeDirection="",this.inAction=!1,this.event=!0,document.getElementById(this.canvas.id+"overviewhandle").style.pointerEvents="all"},t.prototype.initHelper=function(){var e=this.element.getElementsByTagName("svg")[2],i=this.startPoint.x,r=this.startPoint.y,s=1,o=1;if("scale"===this.actionName){var l=e.getElementById(this.canvas.id+"overviewrect").getBBox();i=l.x,r=l.y,s=l.width,o=l.height}var h=Bi("rect",{id:"helper",x:i,y:r,width:s,height:o,fill:"transparent",stroke:"gray","stroke-dasharray":"2 2","shape-rendering":"crispEdges"});e.getElementById(this.element.id+"_overviewlayer").appendChild(h),this.helper=h},t.prototype.mousePosition=function(e){var i,r,s;-1!==e.type.indexOf("touch")?(r=(i=e).changedTouches[0].clientX-this.element.offsetLeft,s=i.changedTouches[0].clientY-this.element.offsetTop):(r=e.clientX,s=e.clientY);var l=this.element.getBoundingClientRect();return{x:(r-=l.left)+this.horizontalOffset,y:(s-=l.top)+this.verticalOffset}},t.prototype.destroy=function(){if(this.unWireEvents(),this.notify("destroy",{}),n.prototype.destroy.call(this),document.getElementById(this.element.id)){this.element.classList.remove("e-overview");var e=document.getElementById(this.element.id+"_canvas");e&&this.element.removeChild(e)}this.parent.views.splice(this.parent.views.indexOf(this.element.id),1),this.diagramLayerDiv=null,this.canvas=null,this.parent=null},t.prototype.getModuleName=function(){return"Overview"},ib([I("100%")],t.prototype,"width",void 0),ib([I("100%")],t.prototype,"height",void 0),ib([I("")],t.prototype,"sourceID",void 0),ib([H()],t.prototype,"created",void 0),t}(yi);function fse(n,t){for(var e=0;ez.findLength(e,n)?e:t;var o=z.findAngle(t,e),a=z.findAngle(i,n),l=z.findLength(i,n),h=a+2*(o-a);return{x:i.x+l*Math.cos(h*Math.PI/180),y:i.y+l*Math.sin(h*Math.PI/180)}}function Kp(n,t,e){if(n&&n.children&&n.children.length>0)for(var r=void 0,s=0;s0&&"annotations"!==r&&"ports"!==r)if(n[""+l].length>0)for(var h=0;h<=n[""+l].length;h++)Ro(n[""+l],t?t[""+l]:void 0,e[""+l],"annotations"===l||"ports"===l?n:void 0,l);else Ro(n[""+l],t?t[""+l]:void 0,e[""+l],"annotations"===l||"ports"===l?n:void 0,l);else if(s instanceof Object&&t&&"annotations"!==r&&"ports"!==r)Ro(n[""+l],t[""+l],e[""+l]);else if("annotations"!==r&&"ports"!==r&&t&&!t[""+l]||!t&&n&&(n[""+l]||void 0!==n[""+l]))n[""+l]=e[""+l];else{var c=void 0;("annotations"===r||"ports"===r)&&("annotations"===r?(n[""+l]&&Ro(n[""+l],t[""+l],e[""+l]),n[""+l]||(fs(i)===de?(c=new Nr(i,"annotations",e[""+l]),i.annotations.push(c)):(c=new Zn(i,"annotations",e[""+l]),i.annotations.push(c)))):n[""+l]?Ro(n[""+l],t[""+l],e[""+l]):(c=new Es(i,"ports",e[""+l]),i.ports.push(c)))}}}function bse(n,t){for(var e="Bezier"===n.type?function yse(n){var t=[];if("Bezier"===n.type)for(var e=0,i=0;i0||n.ports.length>0){var p=n.wrapper.children;for(i=3;i0)return{enabled:!1,intersectPt:e};var l=o/s,h=a/s;return l>=0&&l<=1&&h>=0&&h<=1?(e.x=i.x1+l*(i.x2-i.x1),e.y=i.y1+l*(i.y2-i.y1),{enabled:!0,intersectPt:e}):{enabled:!1,intersectPt:e}}function nb(n,t,e,i){var a=im(vF(n.x,n.y,t.x,t.y),vF(e.x,e.y,i.x,i.y));return a.enabled?a.intersectPt:{x:0,y:0}}function vF(n,t,e,i){return{x1:Number(n)||0,y1:Number(t)||0,x2:Number(e)||0,y2:Number(i)||0}}function mF(n,t,e){var i=[],s={x:t.topRight.x+(e=e||0),y:t.topRight.y},o={x:t.bottomRight.x,y:t.bottomRight.y-e},a={x:t.bottomLeft.x,y:t.bottomLeft.y+e};return i.push({x:t.topLeft.x-e,y:t.topLeft.y}),i.push(s),i.push(o),i.push(a),i}function Hc(n,t,e,i,r,s){var o={},a=e.scroller.transform.scale,h=e.scroller.verticalOffset;return o.x=(i?n.x:t.x)*a+e.scroller.horizontalOffset-r,o.y=(i?n.y:t.y)*a+h-s,o}function yF(n,t){var e=new Ke;return e.data=n.pathData,e.height=n.height>10?n.height-(n.padding.bottom+n.padding.top):n.height,e.width=n.width>10?n.width-(n.padding.left+n.padding.right):n.width,e.visible=n.visibility,e.id=t.id+"_shape",e.inversedAlignment=!1,e.horizontalAlignment="Center",e.verticalAlignment="Center",e.style={fill:n.iconStrokeColor,strokeColor:n.iconStrokeColor,strokeWidth:n.iconStrokeWidth},e.setOffsetWithRespectToBounds(.5,.5,"Fraction"),e.relativeMode="Object",e.description=t.description||"",e}function Jx(n,t,e){var i=Kx(n,t),r=z.findAngle(n[i.index],n[i.index+1]),s=function Tse(n){var t;t=n instanceof NI?0:void 0===n.content?10:0;var e=0;switch(n.alignment){case"Center":e=0;break;case"Before":e=-(0+t);break;case"After":e=0+t}return e}(t),o=z.transform(i.point,r+45,s);return i.point=o,i.angle=r,i}function Kx(n,t){for(var r,s,a,l,e=0,i=t.offset,o=[],h=0;h=c)return s=z.findAngle(n[parseInt(d.toString(),10)],n[d+1]),{point:r=z.transform(n[parseInt(d.toString(),10)],s,c-(a||0)),index:l=d};a=o[parseInt(d.toString(),10)]}return{point:r,index:l}}function SF(n,t,e){t%=360;var a,l,s=225;switch(n.alignment){case"Before":t>=45&&t<=135?(l="right",a=.5===n.offset?"center":"top"):t>=s&&t<=315?(l="left",a=.5===n.offset?"center":"bottom"):t>45&&t=45&&t<=135?(l="left",a=.5===n.offset?"center":"top"):t>=s&&t<=315?(l="right",a=.5===n.offset?"center":"bottom"):t>45&&tMath.abs(t.y-n.y)?n.x0)for(var e=0;e=0;r--)("nodes"===i||"connectors"===i)&&(n[""+i][parseInt(r.toString(),10)].wrapper=null),"dataManager"!==i&&(n[""+i][parseInt(r.toString(),10)]=iT(n[""+i][parseInt(r.toString(),10)],e[""+i][parseInt(r.toString(),10)],void 0!==t[""+i]?t[""+i][parseInt(r.toString(),10)]:[]),("[]"===JSON.stringify(n[""+i][parseInt(r.toString(),10)])||"{}"===JSON.stringify(n[""+i][parseInt(r.toString(),10)])||void 0===n[""+i][parseInt(r.toString(),10)])&&n[""+i].splice(r,1));n=void 0}function Rh(n,t){var e=t.style,i=t;t.canApplyStyle=!0;for(var r=0,s=Object.keys(n);r=0&&n.splice(e,1)}function ef(n,t,e){var i;n.intermediatePoints=t,n.updateSegmentElement(n,t,n.wrapper.children[0],e);var r=n.sourceDecorator;if("Bezier"===n.type){var s=n.segments[0],o=n.segments[n.segments.length-1];i=[z.isEmptyPoint(o.point2)?o.bezierPoint2:o.point2,z.isEmptyPoint(s.point1)?s.bezierPoint1:s.point1]}else i=n.intermediatePoints;t=n.clipDecorators(n,t,e);var a=n.wrapper.children[0];a.canMeasurePath=!0,n.updateDecoratorElement(a=n.wrapper.children[1],t[0],i[1],r),n.updateDecoratorElement(a=n.wrapper.children[2],t[t.length-1],i[i.length-2],n.targetDecorator),n.updateShapeElement(n)}function rT(n,t,e){var l,i=n.wrapper,s=t.offset,o=t.size/e.scale,a=t.margin,h=i.offsetX-i.actualSize.width*i.pivot.x,c=i.offsetY-i.actualSize.height*i.pivot.y;if(l={x:0,y:0},n.nodes.length>0){switch(t.side){case"Top":l.x+=h+s*i.actualSize.width,l.y+=c-o;break;case"Bottom":l.x+=h+s*i.actualSize.width,l.y+=c+i.actualSize.height+o;break;case"Left":l.x+=h-o,l.y+=c+s*i.actualSize.height;break;case"Right":l.x+=h+i.actualSize.width+o,l.y+=c+s*i.actualSize.height}l.x+=(a.left-a.right)/e.scale+o/2*("Center"===t.horizontalAlignment?0:"Right"===t.horizontalAlignment?-1:1),l.y+=(a.top-a.bottom)/e.scale+o/2*("Center"===t.verticalAlignment?0:"Top"===t.verticalAlignment?-1:1)}else if(n.connectors.length>0){var d=n.connectors[0],u={offset:s},p=Kx(d.intermediatePoints,u),f=p.index;l=p.point;var y,v=Jx(d.intermediatePoints,u).angle;qi(y=Hi(),-v,d.intermediatePoints[parseInt(f.toString(),10)].x,d.intermediatePoints[parseInt(f.toString(),10)].y),(l=Je(y,l)).x+=a.left-a.right+o/2*("Center"===t.horizontalAlignment?0:"Right"===t.horizontalAlignment?-1:1),l.y+=a.top-a.bottom+o/2*("Center"===t.verticalAlignment?0:"Top"===t.verticalAlignment?-1:1),qi(y=Hi(),v,d.intermediatePoints[parseInt(f.toString(),10)].x,d.intermediatePoints[parseInt(f.toString(),10)].y),l=Je(y,l)}return 0===i.rotateAngle&&0===i.parentTransform||(qi(y=Hi(),i.rotateAngle+i.parentTransform,i.offsetX,i.offsetY),l=Je(y,l)),l}function fa(n,t,e,i){if(i.annotation){if(kl(i.annotation))return!0}else if(mr[""+t]&n&&bt[""+t]&e)return!0;return!1}function qr(n,t){return!!(mr[""+t]&n)}function Fc(n,t){return!!(Ex[""+t]&n)}function ga(n,t){return n.visibility&t}function sb(n,t){var e;if("Text"===n.shape.type)e=n.shape;else{var i=t.split("_");t=i[i.length-1];for(var r=0;rn[""+t]?e.splice(0,0,n):e.push(n);else if(e.length>1){for(var i=0,r=e.length-1,s=Math.floor((i+r)/2);s!==i;)if(e[parseInt(s.toString(),10)][""+t]n[""+t]))break;r=s,s=Math.floor((i+r)/2)}e[parseInt(r.toString(),10)][""+t]n[""+t]?e.splice(i,0,n):e[parseInt(i.toString(),10)][""+t]n[""+t]&&e.splice(r,0,n)}}function Qse(n){var t=document.getElementById(n.diagramId),e="ej2_instances",i=t[""+e][0].nodes;void 0===i&&(i=function Gse(n){for(var t=[],e=0;e30?10:o/2;for(var h=0,c=0;c=l){var u=l-h;r=Gt(n[c],n[c+1]),s=z.transform(n[c],r,u);break}h+=d}return s},lb=function(n,t){if(n instanceof te||n instanceof de)for(var e=0;e=0||navigator.platform.indexOf("iPad")>=0||navigator.platform.indexOf("iPhone")>=0||navigator.platform.indexOf("MacIntel")>=0)&&("safari"===X.info.name||"webkit"===X.info.name)}function AF(n,t,e,i){return void 0!==t.previewSize[""+i]?t.previewSize[""+i]:void 0!==n.symbolPreview[""+i]?n.symbolPreview[""+i]:t[""+i]||e.actualSize[""+i]}function am(n,t,e){return n&&n.parentId&&(e=(n=t.nameTable[n.parentId]).parentId?am(n,t,e):n.id),e}function lm(n,t){return n.selectedItems.connectors.length>1&&0===n.selectedItems.nodes.length&&0!==t.rotateAngle}function Zse(n){if(n.arrowType&&""!==n.arrowType.trim())switch(n.arrowType){case"single-line-arrow":default:return{targetDecorator:"Arrow",strokeWidth:1};case"double-line-arrow":return{targetDecorator:"Arrow",strokeWidth:2};case"dotted-arrow":return{targetDecorator:"Arrow",strokeDashArray:"2,2"};case"single-line":return{targetDecorator:"None",strokeWidth:1};case"double-line":return{targetDecorator:"None",strokeWidth:2};case"dotted":return{targetDecorator:"None",strokeDashArray:"2,2"};case"wiggly-arrow":return{targetDecorator:"None",strokeWidth:1,opacity:0}}return{targetDecorator:"Arrow",strokeWidth:1}}var Jse=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),io=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},LF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Jse(t,n),io([I("None")],t.prototype,"shape",void 0),io([I("white")],t.prototype,"fill",void 0),io([I("Auto")],t.prototype,"horizontalAlignment",void 0),io([I("Auto")],t.prototype,"verticalAlignment",void 0),io([I(10)],t.prototype,"width",void 0),io([I(10)],t.prototype,"height",void 0),io([re({x:.5,y:1},z)],t.prototype,"offset",void 0),io([I("#1a1a1a")],t.prototype,"borderColor",void 0),io([I(1)],t.prototype,"borderWidth",void 0),io([re({},$n)],t.prototype,"margin",void 0),io([I("")],t.prototype,"pathData",void 0),io([I("")],t.prototype,"content",void 0),io([I(0)],t.prototype,"cornerRadius",void 0),io([re({left:2,right:2,top:2,bottom:2},$n)],t.prototype,"padding",void 0),io([I("#1a1a1a")],t.prototype,"iconColor",void 0),t}(Ee),Kse=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),aT=function(n){function t(){var e=null!==n&&n.apply(this,arguments)||this;return e.orientation="Vertical",e.measureChildren=void 0,e.considerPadding=!0,e}return Kse(t,n),t.prototype.measure=function(e){return this.desiredSize=this.measureStackPanel(e,"Horizontal"===this.orientation?this.updateHorizontalStack:this.updateVerticalStack),this.desiredSize},t.prototype.arrange=function(e){return this.actualSize=this.arrangeStackPanel(e,"Horizontal"===this.orientation?this.arrangeHorizontalStack:this.arrangeVerticalStack),this.updateBounds(),this.actualSize},t.prototype.measureStackPanel=function(e,i){var r=void 0;if(void 0!==this.children&&this.children.length>0)for(var s=0,o=this.children;s0){var r=void 0,s=void 0;r=this.offsetX-e.width*this.pivot.x+this.padding.left,s=this.offsetY-e.height*this.pivot.y+this.padding.top;for(var o=0,a=this.children;o0)for(var i=0,r=this.children;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},aoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return ooe(t,n),Hh([I("Horizontal")],t.prototype,"orientation",void 0),Hh([I("Center")],t.prototype,"type",void 0),Hh([I(void 0)],t.prototype,"offset",void 0),Hh([I(!1)],t.prototype,"enableRouting",void 0),Hh([I([])],t.prototype,"children",void 0),Hh([I("")],t.prototype,"assistants",void 0),Hh([I("")],t.prototype,"level",void 0),Hh([I("")],t.prototype,"hasSubTree",void 0),Hh([I("")],t.prototype,"rows",void 0),t}(Ee),Li=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),q=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},loe=function(n){if(n)switch(n.type){case"Basic":default:return hb;case"Flow":return PF;case"Path":return NF;case"Image":return kF;case"Text":return Rd;case"Bpmn":return pT;case"Native":return hm;case"HTML":return OF;case"UmlActivity":return zF;case"UmlClassifier":return RF;case"SwimLane":return Fd}return hb},va=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),q([I("Basic")],t.prototype,"type",void 0),t}(Ee),NF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"Path"},q([I("Path")],t.prototype,"type",void 0),q([I("")],t.prototype,"data",void 0),t}(va),hm=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"Native"},q([I("Native")],t.prototype,"type",void 0),q([I("")],t.prototype,"content",void 0),q([I("Stretch")],t.prototype,"scale",void 0),t}(va),OF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"Html"},q([I("HTML")],t.prototype,"type",void 0),q([I("")],t.prototype,"content",void 0),t}(va),kF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"Image"},q([I("Image")],t.prototype,"type",void 0),q([I("")],t.prototype,"source",void 0),q([I("None")],t.prototype,"scale",void 0),q([I("None")],t.prototype,"align",void 0),t}(va),Rd=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"Text"},q([I("Text")],t.prototype,"type",void 0),q([I("")],t.prototype,"content",void 0),q([re({},$n)],t.prototype,"margin",void 0),t}(va),hb=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"BasicShape"},q([I("Basic")],t.prototype,"type",void 0),q([I("Rectangle")],t.prototype,"shape",void 0),q([I(0)],t.prototype,"cornerRadius",void 0),q([Bt([],z)],t.prototype,"points",void 0),t}(va),PF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"FlowShape"},q([I("Flow")],t.prototype,"type",void 0),q([I("Terminator")],t.prototype,"shape",void 0),t}(va),hT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"BpmnGateway"},q([I("None")],t.prototype,"type",void 0),t}(Ee),cT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"BpmnDataObject"},q([I("None")],t.prototype,"type",void 0),q([I(!1)],t.prototype,"collection",void 0),t}(Ee),hoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),q([I("None")],t.prototype,"type",void 0),q([I("None")],t.prototype,"loop",void 0),q([I(!1)],t.prototype,"call",void 0),q([I(!1)],t.prototype,"compensation",void 0),t}(Ee),dT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"BpmnEvent"},q([I("Start")],t.prototype,"event",void 0),q([I("None")],t.prototype,"trigger",void 0),t}(Ee),Hd=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"BpmnSubEvent"},q([I("None")],t.prototype,"trigger",void 0),q([I("Start")],t.prototype,"event",void 0),q([I("")],t.prototype,"id",void 0),q([re({},z)],t.prototype,"offset",void 0),q([Bt([],Zn)],t.prototype,"annotations",void 0),q([Bt([],Es)],t.prototype,"ports",void 0),q([I()],t.prototype,"width",void 0),q([I()],t.prototype,"height",void 0),q([re({},$n)],t.prototype,"margin",void 0),q([I("Center")],t.prototype,"horizontalAlignment",void 0),q([I("Center")],t.prototype,"verticalAlignment",void 0),q([I(!0)],t.prototype,"visible",void 0),t}(Ee),coe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),q([re({id:"success",event:"End",offset:{x:1,y:.5}},Hd)],t.prototype,"success",void 0),q([re({id:"failure",event:"Intermediate",trigger:"Error",offset:{x:.25,y:1}},Hd)],t.prototype,"failure",void 0),q([re({id:"cancel",event:"Intermediate",trigger:"Cancel",offset:{x:.75,y:1}},Hd)],t.prototype,"cancel",void 0),t}(Ee),doe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),q([I("None")],t.prototype,"type",void 0),q([I(!1)],t.prototype,"adhoc",void 0),q([I("Default")],t.prototype,"boundary",void 0),q([I(!1)],t.prototype,"compensation",void 0),q([I("None")],t.prototype,"loop",void 0),q([I(!0)],t.prototype,"collapsed",void 0),q([Bt([],Hd)],t.prototype,"events",void 0),q([re({},coe)],t.prototype,"transaction",void 0),q([I(void 0)],t.prototype,"processes",void 0),t}(Ee),uT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"BpmnActivity"},q([I("Task")],t.prototype,"activity",void 0),q([re({},hoe)],t.prototype,"task",void 0),q([re({},doe)],t.prototype,"subProcess",void 0),t}(Ee),cm=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return Li(t,n),t.prototype.getClassName=function(){return"BpmnAnnotation"},q([I("")],t.prototype,"text",void 0),q([I("")],t.prototype,"id",void 0),q([I(0)],t.prototype,"angle",void 0),q([I()],t.prototype,"height",void 0),q([I()],t.prototype,"width",void 0),q([I(0)],t.prototype,"length",void 0),t}(Ee),uoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),q([I("")],t.prototype,"textAnnotationTarget",void 0),q([I("Auto")],t.prototype,"textAnnotationDirection",void 0),t}(Ee),pT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"BpmnShape"},q([I("Bpmn")],t.prototype,"type",void 0),q([I("Event")],t.prototype,"shape",void 0),q([re({},dT)],t.prototype,"event",void 0),q([re({},hT)],t.prototype,"gateway",void 0),q([re({},cT)],t.prototype,"dataObject",void 0),q([re({},uT)],t.prototype,"activity",void 0),q([re({},cm)],t.prototype,"annotation",void 0),q([Bt([],cm)],t.prototype,"annotations",void 0),q([re({},uoe)],t.prototype,"textAnnotation",void 0),t}(va),zF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"UmlActivityShape"},q([I("UmlActivity")],t.prototype,"type",void 0),q([I("Action")],t.prototype,"shape",void 0),t}(va),fT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"MethodArguments"},q([I("")],t.prototype,"name",void 0),q([I("")],t.prototype,"type",void 0),q([re({},Xp)],t.prototype,"style",void 0),t}(Ee),of=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"UmlClassAttribute"},q([I("Public")],t.prototype,"scope",void 0),q([I(!1)],t.prototype,"isSeparator",void 0),q([re({fill:"#F9F9F9",strokeColor:"#CCCCCC"},Ll)],t.prototype,"separatorStyle",void 0),t}(fT),dm=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"UmlClassMethod"},q([Bt([],fT)],t.prototype,"parameters",void 0),t}(of),cb=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"UmlClass"},q([I("")],t.prototype,"name",void 0),q([Bt([],of)],t.prototype,"attributes",void 0),q([Bt([],dm)],t.prototype,"methods",void 0),q([re({},Xp)],t.prototype,"style",void 0),t}(Ee),gT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"UmlInterface"},q([I(!1)],t.prototype,"isSeparator",void 0),q([re({fill:"#F9F9F9",strokeColor:"#CCCCCC"},Ll)],t.prototype,"separatorStyle",void 0),t}(cb),db=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"UmlEnumerationMember"},q([I("")],t.prototype,"name",void 0),q([I("")],t.prototype,"value",void 0),q([I(!1)],t.prototype,"isSeparator",void 0),q([re({fill:"#F9F9F9",strokeColor:"#CCCCCC"},Ll)],t.prototype,"separatorStyle",void 0),q([re({},Xp)],t.prototype,"style",void 0),t}(Ee),vT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"UmlEnumeration"},q([I("")],t.prototype,"name",void 0),q([Bt([],db)],t.prototype,"members",void 0),q([re({},Xp)],t.prototype,"style",void 0),t}(Ee),RF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"UmlClassifierShape"},q([I("UmlClassifier")],t.prototype,"type",void 0),q([re({},cb)],t.prototype,"classShape",void 0),q([re({},gT)],t.prototype,"interfaceShape",void 0),q([re({},vT)],t.prototype,"enumerationShape",void 0),q([I("Class")],t.prototype,"classifier",void 0),t}(va),te=function(n){function t(e,i,r,s){var a,o=n.call(this,e,i,r,s)||this;return o.isCanvasUpdate=!1,o.status="None",o.parentId="",o.processId="",o.umlIndex=-1,o.outEdges=[],o.inEdges=[],o.isHeader=!1,o.isLane=!1,o.isPhase=!1,o.children&&o.children.length>0&&((!(a=r).style||!a.style.fill)&&(o.style.fill="transparent"),(!a.style||!a.style.strokeColor)&&(o.style.strokeColor="transparent")),o.shape&&"UmlActivity"===o.shape.type&&rb(r,o),o.shape&&"SwimLane"===o.shape.type&&pF(r,o),o.ports&&o.ports.length&&function vse(n){for(var t=0;t>";t=n;break;case"FinalNode":t=IF(e)}return t}(new Ke,i,this);break;case"Bpmn":if(e.bpmnModule){i=e.bpmnModule.initBPMNContent(i,this,e),this.wrapper.elementActions=this.wrapper.elementActions|Xr.ElementIsGroup;var v=this.shape.activity.subProcess;if(v.processes&&v.processes.length)for(var S=0,b=this.shape.activity.subProcess.processes;S>",margin:{left:10,right:10},id:"class",style:{fontSize:i.style.fontSize,color:i.style.color,fill:i.style.fill,textWrapping:r},offset:{x:.5,y:.3},constraints:Lr.ReadOnly}],constraints:(ie.Default|ie.HideThumbs)&~(ie.Rotate|ie.Drag|ie.Resize),verticalAlignment:"Stretch",horizontalAlignment:"Stretch",style:{fill:t.style.fill,strokeColor:"black"===t.style.strokeColor?"#ffffff00":t.style.strokeColor}},!0);return e.initObject(s),e.nodes.push(s),e.UpdateBlazorDiagramModel(s,"Node"),t.children.push(s.id),function toe(n,t,e,i){if("Enumeration"===n.shape.classifier){var r=e.members;if(r&&r.length){nf(n,t);for(var s="",o=0;o0)for(var o=0;o0&&s.phaseSize&&(i+=s.phaseSize,qv(n,s.phaseSize)),s.lanes.length>0)for(o=0;o0){var a=0;for(o=0;o0&&"Horizontal"===r.orientation)for(l=0;l0&&(i+=r.phaseSize,o=$v(r.phaseSize),n.push(o)),a=0;a0&&o.phaseSize){for(var l=0;l0)for(l=0;l0?e.nameTable[this.nodes[0].id].wrapper:e.nameTable[this.connectors[0].id].wrapper,this.annotation.id);i.children.push(s)}else if(this.nodes||this.connectors){for(var o=0;o-1}function VF(n,t,e){n=[];for(var i=0,r=e.length;i0?c.getElementsByTagName("svg")[0].outerHTML:c.getElementsByTagName("g").length>0?c.getElementsByTagName("g")[0].outerHTML:"",s.shape.content=h,n.content=h,c.parentElement.removeChild(c)}l="nodeTemplate"}else a=s,l="annotationTemplate";var f=document.getElementById(n.diagramId).ej2_instances[0];if("string"!=typeof n.content&&"function"!=typeof n.content||n.isTemplate)if(n.isTemplate){if(v=void 0,v=f.isReact?n.getNodeTemplate()($(e),f,l+"_"+("nodeTemplate"===l?e.id:n.nodeId+e.id),void 0,void 0,!1,i):f.isVue||f.isVue3?n.getNodeTemplate()?n.getNodeTemplate()($(e),f,l+"_"+("nodeTemplate"===l?e.id:n.nodeId+e.id),void 0,void 0,!1,i):(v=ii("nodeTemplate"===l?f.nodeTemplate:f.annotationTemplate))($(e),f,l+"_"+("nodeTemplate"===l?e.id:n.nodeId+e.id),void 0,void 0,!1,i):n.getNodeTemplate()($(e),f,l+"_"+("nodeTemplate"===l?e.id:n.nodeId+e.id),void 0,void 0,!1))for(var M=0;M=1&&0===n.x&&("Clip"===i.textOverflow||"Ellipsis"===i.textOverflow)&&("Wrap"===i.textWrapping||"WrapWithOverflow"===i.textWrapping)&&(n.x=t[e-1]?t[e-1].x:-n.width/2),n.x}function QF(n,t,e,i){return e&&!t.template||t.template&&"function"==typeof t.template&&i.isReact?(n.isTemplate=!0,n.template=n.content=Bh(n,!0,t)):n.content=t.template,n}function Qe(){for(var e,t="",i=0;i<5;i++){if(typeof window<"u"&&"crypto"in window&&"getRandomValues"in crypto){var r=new Uint16Array(1);e=(window.msCrypto||window.crypto).getRandomValues(r)[0]%60}else e=Math.floor(61*Math.random());0===i&&e<10?i--:t+="0123456789ABCDEFGHIJKLMNOPQRSTUVWXTZabcdefghiklmnopqrstuvwxyz".substring(e,e+1)}return t}function GF(n){if(n)try{return"function"!=typeof n&&document.querySelectorAll(n).length?ii(document.querySelector(n).innerHTML.trim()):ii(n)}catch{return ii(n)}}function En(n){new Ne;var e=n.offsetY-n.actualSize.height*n.pivot.y,i=n.offsetY+n.actualSize.height*(1-n.pivot.y),r=n.offsetX-n.actualSize.width*n.pivot.x,s=n.offsetX+n.actualSize.width*(1-n.pivot.x);return Ne.toBounds([{x:r,y:e},{x:s,y:e},{x:r,y:i},{x:s,y:i}])}function yr(n){var t=new Ne,e=En(n),i=e.middleLeft,r=e.topCenter,s=e.bottomCenter,o=e.middleRight,a=e.topLeft,l=e.topRight,h=e.bottomLeft,c=e.bottomRight;if(n.corners={topLeft:a,topCenter:r,topRight:l,middleLeft:i,middleRight:o,bottomLeft:h,bottomCenter:s,bottomRight:c},0!==n.rotateAngle||0!==n.parentTransform){var d=Hi();qi(d,n.rotateAngle+n.parentTransform,n.offsetX,n.offsetY),n.corners.topLeft=a=Je(d,a),n.corners.topCenter=r=Je(d,r),n.corners.topRight=l=Je(d,l),n.corners.middleLeft=i=Je(d,i),n.corners.middleRight=o=Je(d,o),n.corners.bottomLeft=h=Je(d,h),n.corners.bottomCenter=s=Je(d,s),n.corners.bottomRight=c=Je(d,c)}return t=Ne.toBounds([a,l,h,c]),n.corners.left=t.left,n.corners.right=t.right,n.corners.top=t.top,n.corners.bottom=t.bottom,n.corners.center=t.center,n.corners.width=t.width,n.corners.height=t.height,t}function $(n,t,e,i){var r={},s="properties";if(n){e=n.propName;var l=[],h=[];if((l=l.concat(Object.keys(n[""+s]||n))).push("version"),e){var c=Zi(t);h=c?c(e):[],l=l.concat(h)}for(var d=function Ooe(n){switch(n){case"nodes":case"children":return["inEdges","outEdges","parentId","processId","nodeId","umlIndex","isPhase","isLane"];case"connectors":return["parentId"];case"annotation":case"annotations":return["nodeId"];case"shape":return["hasHeader"];case"layers":return["objectZIndex"]}return[]}(e),u=0,p=l=l.concat(d);u0&&(e=r),r=Math.floor(Poe(e,i)),s=_c(o+=n.substr(e,r),t)}while(s<=t.width);for(o=o.substr(0,e),a=e;a=t.width){n=n.substr(0,o.length-1);break}return"Ellipsis"===t.textOverflow?(n=n.substr(0,n.length-3),n+="..."):n=n.substr(0,n.length),n}function wT(n,t){if("NoWrap"===t&&"PreserveAll"===n)return"pre";var e="";switch(n){case"CollapseAll":e="nowrap";break;case"CollapseSpace":e="pre-line";break;case"PreserveAll":e="pre-wrap"}return e}function CT(n,t){var e=Hi();qi(e,t,0,0);var i=Je(e,{x:0,y:0}),r=Je(e,{x:n.width,y:0}),s=Je(e,{x:0,y:n.height}),o=Je(e,{x:n.width,y:n.height}),a=Math.min(i.x,r.x,s.x,o.x),l=Math.min(i.y,r.y,s.y,o.y),h=Math.max(i.x,r.x,s.x,o.x),c=Math.max(i.y,r.y,s.y,o.y);return new me(h-a,c-l)}function xs(n,t,e,i){if(0!==n){var r=Hi();return qi(r,n,t,e),Je(r,i)}return i}function Zi(n){return void 0!==n&&"string"==typeof n&&(n=Y(n,window)),n}var bo=function(){function n(){}return n.getContext=function(t){return t.getContext("2d")},n.setCanvasSize=function(t,e,i){t&&(t.setAttribute("width",e.toString()),t.setAttribute("height",i.toString()))},n.prototype.renderGradient=function(t,e,i,r){var s,o,a;if("None"!==t.gradient.type){for(var l=0;l0?(w=0===S.r1?e.arc[parseInt(r.toString(),10)].r1:S.r1,C=0===S.r2?e.arc[parseInt(r.toString(),10)].r2:S.r2,r++):(w=S.r1,C=S.r2);var D=S.angle*(Math.PI/180),A=S.largeArc,x=S.sweep,R={x:u,y:p},L={x:Math.cos(D)*(M.x-R.x)/2+Math.sin(D)*(M.y-R.y)/2,y:-Math.sin(D)*(M.x-R.x)/2+Math.cos(D)*(M.y-R.y)/2},O=Math.pow(L.x,2)/Math.pow(w,2)+Math.pow(L.y,2)/Math.pow(C,2);O>1&&(w*=Math.sqrt(O),C*=Math.sqrt(O));var N=Math.pow(C,2)*Math.pow(L.x,2),T=(A===x?-1:1)*Math.sqrt((Math.pow(w,2)*Math.pow(C,2)-Math.pow(w,2)*Math.pow(L.y,2)-N)/(Math.pow(w,2)*Math.pow(L.y,2)+Math.pow(C,2)*Math.pow(L.x,2)));isNaN(T)&&(T=0);var P={x:T*w*L.y/C,y:T*-C*L.x/w},_={x:(M.x+R.x)/2+Math.cos(D)*P.x-Math.sin(D)*P.y,y:(M.y+R.y)/2+Math.sin(D)*P.x+Math.cos(D)*P.y},B=this.a([1,0],[(L.x-P.x)/w,(L.y-P.y)/C]),j=[(L.x-P.x)/w,(L.y-P.y)/C],Q=[(-L.x-P.x)/w,(-L.y-P.y)/C],oe=this.a(j,Q);this.r(j,Q)<=-1&&(oe=Math.PI),this.r(j,Q)>=1&&(oe=0);var pe=B+oe/2*(x?1:-1);if(Math.cos(pe),Math.sin(pe),S.centp=_,S.xAxisRotation=D,S.rx=w,S.ry=C,S.a1=B,S.ad=oe,S.sweep=x,null!=s){var De=w>C?w:C,xe=w>C?1:w/C,Ie=w>C?C/w:1;s.save(),s.translate(_.x,_.y),s.rotate(D),s.scale(xe,Ie),s.arc(0,0,De,B,B+oe,!x),s.scale(1/xe,1/Ie),s.rotate(-D),s.translate(-_.x,-_.y),s.restore()}break;case"Z":case"z":s.closePath(),u=o,p=a}o=u,a=p}}},n.prototype.drawText=function(t,e,i,r,s,o,a){if(e.content&&!0===e.visible){var l=n.getContext(t);l.save(),this.setStyle(t,e),o&&(e.fontSize*=o),this.rotateContext(t,e.angle,e.x+e.width*e.pivotX,e.y+e.height*e.pivotY),this.setFontStyle(t,e);var u,d=0;u=e.childNodes;var p=e.wrapBounds;if(l.fillStyle=e.color,p){var f=this.labelAlign(e,p,u);for(d=0;de.width&&"Wrap"!==e.textOverflow&&"NoWrap"===e.textWrapping&&(g.text=qF(g.text,e)),"Clip"!==e.textOverflow&&"Ellipsis"!==e.textOverflow||"Wrap"!==e.textWrapping?l.fillText(g.text,v,y):ya.actualSize.height+a.bounds.y&&(g.text=g.text.slice(0,g.text.length-3),g.text=g.text.concat("...")),l.fillText(g.text,v,y)),"Underline"===e.textDecoration||"Overline"===e.textDecoration||"LineThrough"===e.textDecoration){var M=v,w=void 0,D=v+l.measureText(g.text).width,A=void 0;switch(e.textDecoration){case"Underline":w=y+2,A=y+2;break;case"Overline":w=f.y+g.dy*d,A=f.y+g.dy*d;break;case"LineThrough":w=(y+f.y+g.dy*d)/2+2,A=(y+f.y+g.dy*d)/2+2}l.beginPath(),l.moveTo(M,w),l.lineTo(D,A),l.strokeStyle=e.color,l.lineWidth=.08*e.fontSize,l.globalAlpha=e.opacity,l.stroke()}}}l.restore()}},n.prototype.loadImage=function(t,e,i,r,s){this.rotateContext(i,e.angle,r,s);var o=new Image;o.src=e.source,this.image(t,o,e.x,e.y,e.width,e.height,e)},n.prototype.drawImage=function(t,e,i,r){var s=this;if(e.visible){var o=n.getContext(t);o.save();var a=e.x+e.width*e.pivotX,l=e.y+e.height*e.pivotY,h=new Image;h.src=e.source,o.canvas.id.split("_"),r?h.onload=function(){s.loadImage(o,e,t,a,l)}:this.loadImage(o,e,t,a,l),o.restore()}},n.prototype.image=function(t,e,i,r,s,o,a){t.beginPath();var l=e.width,h=e.height,c=s,d=o,u=0,p=0;if(a&&"None"!==a.alignment){var f=a.alignment.toLowerCase().substr(1,3),g=a.alignment.toLowerCase().substr(5,3);if("Slice"===a.scale){var v=function(){u=c,p=h*c/l},y=function(){u=l*d/h,p=d};c>d?(v(),d>p&&y()):c===d?l>h?y():v():(y(),c>u&&v());var S=this.getSliceOffset(f,u,c,l),b=this.getSliceOffset(g,p,d,h),M=l-S,w=h-b,C=u-S*(u/l),D=p-b*(p/h),A=Tt("canvas",{width:s.toString(),height:o.toString()});A.getContext("2d").drawImage(e,S,b,M,w,0,0,C,D),t.drawImage(A,i,r,s,o)}else if("Meet"===a.scale){var R=h/l,L=d/c;p=L>R?c*R:d,i+=this.getMeetOffset(f,u=L>R?c:d/R,c),r+=this.getMeetOffset(g,p,d),t.drawImage(e,0,0,l,h,i,r,u,p)}else t.drawImage(e,i,r,s,o)}else if("None"!==a.flip){var O=1,N=1;("Horizontal"===a.flip||"Both"===a.flip)&&(i=-i,s=-s,O=-1),("Vertical"===a.flip||"Both"===a.flip)&&(r=-r,o=-o,N=-1),t.scale(O,N),t.drawImage(e,i,r,s,o)}else t.drawImage(e,i,r,s,o);t.closePath()},n.prototype.getSliceOffset=function(t,e,i,r){switch(t){case"min":default:return 0;case"mid":return(e-i)/2*r/e;case"max":return(e-i)*r/e}},n.prototype.getMeetOffset=function(t,e,i){var r=Math.max(e,i),s=Math.min(e,i);switch(t){case"min":default:return 0;case"mid":return(r-s)/2;case"max":return r-s}},n.prototype.m=function(t){return Math.sqrt(Math.pow(t[0],2)+Math.pow(t[1],2))},n.prototype.r=function(t,e){return(t[0]*e[0]+t[1]*e[1])/(this.m(t)*this.m(e))},n.prototype.a=function(t,e){return(t[0]*e[1]t.width&&("Ellipsis"===t.textOverflow||"Clip"===t.textOverflow)&&"NoWrap"===t.textWrapping?0:.5*t.width:"right"===t.textAlign&&(c=1*t.width),s.x=t.x+c+(e?e.x:0),s.y=a+d-r.height/2,s},n}(),vb=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Vi=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Roe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return vb(t,n),Vi([I("")],t.prototype,"source",void 0),Vi([I("transparent")],t.prototype,"color",void 0),Vi([I("None")],t.prototype,"scale",void 0),Vi([I("None")],t.prototype,"align",void 0),t}(Ee),Hoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return vb(t,n),Vi([I("Page")],t.prototype,"mode",void 0),Vi([I("PageSettings")],t.prototype,"region",void 0),Vi([re({top:25,bottom:25,left:25,right:25},$n)],t.prototype,"margin",void 0),Vi([I(!1)],t.prototype,"canZoomIn",void 0),Vi([I(void 0)],t.prototype,"customBounds",void 0),Vi([I(!1)],t.prototype,"canFit",void 0),t}(Ee),Boe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return vb(t,n),Vi([I(null)],t.prototype,"width",void 0),Vi([I(null)],t.prototype,"height",void 0),Vi([re({},$n)],t.prototype,"margin",void 0),Vi([I("Landscape")],t.prototype,"orientation",void 0),Vi([I("Infinity")],t.prototype,"boundaryConstraints",void 0),Vi([re({},Roe)],t.prototype,"background",void 0),Vi([I(!1)],t.prototype,"multiplePage",void 0),Vi([I(!1)],t.prototype,"showPageBreaks",void 0),Vi([re({},Hoe)],t.prototype,"fitOptions",void 0),t}(Ee),Foe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return vb(t,n),Vi([I(0)],t.prototype,"horizontalOffset",void 0),Vi([I(0)],t.prototype,"verticalOffset",void 0),Vi([I(1)],t.prototype,"currentZoom",void 0),Vi([I(0)],t.prototype,"viewPortWidth",void 0),Vi([I(0)],t.prototype,"viewPortHeight",void 0),Vi([I(.2)],t.prototype,"minZoom",void 0),Vi([I(30)],t.prototype,"maxZoom",void 0),Vi([I("Diagram")],t.prototype,"scrollLimit",void 0),Vi([I()],t.prototype,"scrollableArea",void 0),Vi([I(!1)],t.prototype,"canAutoScroll",void 0),Vi([I(100)],t.prototype,"autoScrollFrequency",void 0),Vi([re({left:15,right:15,top:15,bottom:15},$n)],t.prototype,"autoScrollBorder",void 0),Vi([re({left:0,right:0,top:0,bottom:0},$n)],t.prototype,"padding",void 0),Vi([I(.2)],t.prototype,"zoomFactor",void 0),t}(Ee),_oe=function(){function n(){this.services={}}return n.prototype.register=function(t,e){this.services[""+t]=e},n.prototype.getService=function(t){return this.services[""+t]},n}(),$F=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),ma=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},ZF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return $F(t,n),ma([I("lightgray")],t.prototype,"lineColor",void 0),ma([I("")],t.prototype,"lineDashArray",void 0),ma([I([1.25,18.75,.25,19.75,.25,19.75,.25,19.75,.25,19.75])],t.prototype,"lineIntervals",void 0),ma([I([1,19,.5,19.5,.5,19.5,.5,19.5,.5,19.5])],t.prototype,"dotIntervals",void 0),ma([I([20])],t.prototype,"snapIntervals",void 0),t}(Ee),Uoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return $F(t,n),ma([re({},ZF)],t.prototype,"horizontalGridlines",void 0),ma([re({},ZF)],t.prototype,"verticalGridlines",void 0),ma([I(Kt.All)],t.prototype,"constraints",void 0),ma([I(5)],t.prototype,"snapAngle",void 0),ma([I("Lines")],t.prototype,"gridType",void 0),ma([I(5)],t.prototype,"snapObjectDistance",void 0),ma([I("#07EDE1")],t.prototype,"snapLineColor",void 0),t}(Ee),JF=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Ja=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},KF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return JF(t,n),Ja([I(5)],t.prototype,"interval",void 0),Ja([I(100)],t.prototype,"segmentWidth",void 0),Ja([I("Horizontal")],t.prototype,"orientation",void 0),Ja([I("RightOrBottom")],t.prototype,"tickAlignment",void 0),Ja([I("red")],t.prototype,"markerColor",void 0),Ja([I(25)],t.prototype,"thickness",void 0),Ja([I(null)],t.prototype,"arrangeTick",void 0),t}(Ee),joe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return JF(t,n),Ja([I(!1)],t.prototype,"showRulers",void 0),Ja([I(!0)],t.prototype,"dynamicGrid",void 0),Ja([re({orientation:"Horizontal"},KF)],t.prototype,"horizontalRuler",void 0),Ja([re({orientation:"Vertical"},KF)],t.prototype,"verticalRuler",void 0),t}(Ee),Voe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),e_=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Woe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Voe(t,n),e_([I("")],t.prototype,"property",void 0),e_([I("")],t.prototype,"field",void 0),t}(Ee),ET=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),ln=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},t_=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return ET(t,n),ln([I("")],t.prototype,"read",void 0),ln([I("")],t.prototype,"create",void 0),ln([I("")],t.prototype,"update",void 0),ln([I("")],t.prototype,"destroy",void 0),ln([I()],t.prototype,"customFields",void 0),t}(Ee),Yoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return ET(t,n),ln([I("")],t.prototype,"id",void 0),ln([I("")],t.prototype,"sourceID",void 0),ln([I("")],t.prototype,"targetID",void 0),ln([I(null)],t.prototype,"sourcePointX",void 0),ln([I(null)],t.prototype,"sourcePointY",void 0),ln([I(null)],t.prototype,"targetPointX",void 0),ln([I(null)],t.prototype,"targetPointY",void 0),ln([I(null)],t.prototype,"dataManager",void 0),ln([re({},t_)],t.prototype,"crudAction",void 0),t}(Ee),Qoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return ET(t,n),ln([I("")],t.prototype,"id",void 0),ln([I(null)],t.prototype,"dataManager",void 0),ln([I(null)],t.prototype,"dataSource",void 0),ln([I("")],t.prototype,"root",void 0),ln([I("")],t.prototype,"parentId",void 0),ln([I()],t.prototype,"doBinding",void 0),ln([Bt([],Woe)],t.prototype,"dataMapSettings",void 0),ln([re({},t_)],t.prototype,"crudAction",void 0),ln([re({},Yoe)],t.prototype,"connectionDataSource",void 0),t}(Ee),i_=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Cr=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Goe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return i_(t,n),Cr([I("LeftInFlow")],t.prototype,"yesBranchDirection",void 0),Cr([I("RightInFlow")],t.prototype,"noBranchDirection",void 0),Cr([I(["Yes","True"])],t.prototype,"yesBranchValues",void 0),Cr([I(["No","False"])],t.prototype,"noBranchValues",void 0),t}(Ee),Xoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return i_(t,n),Cr([I("")],t.prototype,"fixedNode",void 0),Cr([I(30)],t.prototype,"horizontalSpacing",void 0),Cr([I("SamePoint")],t.prototype,"connectionPointOrigin",void 0),Cr([I("Nonlinear")],t.prototype,"arrangement",void 0),Cr([I(30)],t.prototype,"verticalSpacing",void 0),Cr([I(30)],t.prototype,"maxIteration",void 0),Cr([I(40)],t.prototype,"springFactor",void 0),Cr([I(50)],t.prototype,"springLength",void 0),Cr([re({left:50,top:50,right:0,bottom:0},$n)],t.prototype,"margin",void 0),Cr([I("Auto")],t.prototype,"horizontalAlignment",void 0),Cr([I("Auto")],t.prototype,"verticalAlignment",void 0),Cr([I("TopToBottom")],t.prototype,"orientation",void 0),Cr([I("Auto")],t.prototype,"connectionDirection",void 0),Cr([I("Default")],t.prototype,"connectorSegments",void 0),Cr([I("None")],t.prototype,"type",void 0),Cr([I()],t.prototype,"getLayoutInfo",void 0),Cr([I()],t.prototype,"layoutInfo",void 0),Cr([I()],t.prototype,"getBranch",void 0),Cr([I()],t.prototype,"bounds",void 0),Cr([I(!0)],t.prototype,"enableAnimation",void 0),Cr([I(!1)],t.prototype,"enableRouting",void 0),Cr([I("")],t.prototype,"root",void 0),Cr([re({},Goe)],t.prototype,"flowchartLayoutSettings",void 0),t}(Ee),qoe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),r_=function(n){function t(e,i){var r=n.call(this,e,!0)||this;return r.oldValue=null,r.endPoint=i,r}return qoe(t,n),t.prototype.mouseDown=function(e){var i,r=!0;if(e.source&&e.source.connectors&&(i=e.source.connectors[0]),e.info&&e.actualObject&&(r=e.info.ctrlKey&&"Orthogonal"!==e.actualObject.type),i&&r){this.inAction=!0,this.undoElement=$(e.source),n.prototype.mouseDown.call(this,e);for(var s=0;s0)1!==s&&this.removePrevSegment(i,s);else if(a){var l=z.distancePoints(a.points[0],a.points[1]);Math.abs(a.length||0===a.length?a.length:l)<=5&&this.removeNextSegment(i,s)}this.commandHandler.updateEndPoint(i,r),i.selectedSegmentIndex=0}if(this.undoElement){var c=$(e.source);this.commandHandler.addHistoryEntry({type:"SegmentChanged",redoObject:c,undoObject:this.undoElement,category:"Internal"})}if(i.isBezierEditing&&(i.isBezierEditing=!1),this.prevPosition!==this.startPosition){var u={source:i,state:"Completed",oldValue:this.oldValue,newValue:$(this.selectedSegment),cancel:!1,segment:this.selectedSegment};this.commandHandler.triggerEvent(Ce.segmentChange,u)}n.prototype.mouseUp.call(this,e)},t.prototype.removePrevSegment=function(e,i){var r=e.segments[i-2],s=e.segments[i+1];if(s&&!((s.length||0===s.length?s.length:z.distancePoints(s.points[0],s.points[1]))<=5)){var a=e.segments.slice(i-1,i+1),l={element:e,removeSegments:a,type:"Removal",cancel:!1};if(this.commandHandler.triggerEvent(Ce.segmentCollectionChange,l),!l.cancel){var h=e.segments[i+1];e.segments.splice(i-1,2);var c=this.selectedSegment;"Left"===c.direction||"Right"===c.direction?(r.points[r.points.length-1].x=h.points[0].x,h.points[0].y=r.points[r.points.length-1].y):(r.points[r.points.length-1].y=h.points[0].y,h.points[0].x=r.points[r.points.length-1].x),(c.length||0===c.length)&&this.findSegmentDirection(r),this.findSegmentDirection(h)}}},t.prototype.findSegmentDirection=function(e){e.direction&&(e.length||0===e.length)&&(e.length=z.distancePoints(e.points[0],e.points[e.points.length-1]),e.direction=z.direction(e.points[0],e.points[e.points.length-1]))},t.prototype.removeNextSegment=function(e,i){var l,h,r=this.selectedSegment,s=e.segments[i-1],o=e.segments[i+2],a=e.segments[i+1];if(a.length||0===a.length?(l=e.segments.slice(i,2),h={element:e,removeSegments:l,type:"Removal",cancel:!1},this.commandHandler.triggerEvent(Ce.segmentCollectionChange,h={element:e,removeSegments:l,type:"Removal",cancel:!1}),h.cancel||(e.segments.splice(i,2),"Top"===r.direction||"Bottom"===r.direction?(o.points[0].y=r.points[0].y,s.points[s.points.length-1].x=o.points[0].x):(o.points[0].x=r.points[0].x,s.points[s.points.length-1].y=o.points[0].y))):(l=e.segments.slice(i+1,1),this.commandHandler.triggerEvent(Ce.segmentCollectionChange,h={element:e,removeSegments:l,type:"Removal",cancel:!1}),h.cancel||(e.segments.splice(i+1,1),"Top"===r.direction||"Bottom"===r.direction?s.points[s.points.length-1].x=a.points[a.points.length-1].x:s.points[s.points.length-1].y=a.points[a.points.length-1].y,this.findSegmentDirection(s),r.length=r.direction=null)),s&&o&&!h.cancel&&(s.length=z.distancePoints(s.points[0],o.points[0]),s.direction=z.direction(s.points[0],o.points[0]),o.length||0===o.length)){o.length=z.distancePoints(s.points[s.points.length-1],o.points[o.points.length-1]);var c=s.points,d=o.points;o.direction=z.direction(c[c.length-1],d[d.length-1])}},t.prototype.addOrRemoveSegment=function(e,i,r){for(var s,o,a=[],l={segments:e.segments},h=0;h0?"Bottom":"Top":r>0?"Right":"Left",length:i.points[0].x===i.points[1].x?s:r},!0)),l.push(new bi(e,"segments",{type:"Orthogonal",direction:c,length:h/2},!0));var p={element:e,addSegments:l,type:"Addition",cancel:!1};return this.commandHandler.triggerEvent(Ce.segmentCollectionChange,p),p.cancel||(e.segments=l.concat(e.segments),a=o+2),a},t.prototype.insertFirstSegment=function(e,i,r,s,o){var a,l,d,u,h=[];if(e.sourcePortID&&i.length&&e.segments[0].points.length>2)for(var p=void 0,f=0;f0?"Bottom":"Top":r>0?"Right":"Left"),p=u,h.push(u)}else h.push(new bi(e,"segments",{type:"Orthogonal",direction:i.direction,length:i.length/3},!0)),"Bottom"===i.direction||"Top"===i.direction?(l=Math.abs(r),a=r>0?"Right":"Left"):(l=Math.abs(s),a=s>0?"Bottom":"Top"),u=new bi(e,"segments",{type:"Orthogonal",direction:a,length:l},!0),h.push(u);var y={element:e,addSegments:h,type:"Addition",cancel:!1};if(this.commandHandler.triggerEvent(Ce.segmentCollectionChange,y),!y.cancel){if(e.sourcePortID&&i.length&&e.segments[0].points.length>2)e.segments.splice(0,1),d=1;else{var S=e.segments[1];S&&S.length&&(S.length=a!==S.direction?S.length+l:S.length-l),d=2,i.length=2*i.length/3}e.segments=h.concat(e.segments)}return d},t.prototype.updateAdjacentSegments=function(e,i,r,s){var o=e.segments[parseInt(i.toString(),10)],a=o.points[o.points.length-1],h=!0;"Orthogonal"===o.type&&(o.points[0]=o.points[0],o.points[o.points.length-1]=a,e.segments[i-1]&&(h=this.updatePreviousSegment(r,s,e,i)),e.segments.length-1>i&&h&&this.updateNextSegment(e,o,e.segments[i+1],r,s))},t.prototype.addTerminalSegment=function(e,i,r,s,o){var l,h,c,d,a=e.segments.indexOf(i),u=[],p=e.segments.pop(),f=e.segments[e.segments.length-1];l=f&&"Orthogonal"===f.type?f:null;for(var g=0;g0&&"Left"===o.direction?c.middleLeft:c.middleRight,o.length>c.width/2?Math.abs(a.length)0&&"Top"===o.direction?c.topCenter:c.bottomCenter,o.length>c.height/2?Math.abs(a.length)1)for(var a=0,l=this.diagram.views;a0)for(var e=t===Ce.onUserHandleMouseLeave?this.previousAction:this.action,i={element:void 0},r=0;r0)for(var r={element:void 0},s=void 0,o=void 0,a=0;a-1&&(o=s,this.previousTarget=i,this.targetItem=e),o===e.fixedUserHandles[parseInt(a.toString(),10)].id&&(r.element=e.fixedUserHandles[parseInt(a.toString(),10)],this.userHandle(t,a,r,e))},n.prototype.mouseDown=function(t){if(!0!==this.inAction||!(this.tool instanceof qI||this.tool instanceof pa)){this.focus=!0;var e=t.touches,i=!!document.getElementsByClassName("e-dragclone")[0];if(this.isMouseOnScrollBar(t)&&!i)return this.isScrolling=!0,void t.preventDefault();if(this.checkFixedUserHandleEvent(Ce.onFixedUserHandleMouseDown,this.targetItem,this.previousTarget),this.checkUserHandleEvent(Ce.onUserHandleMouseDown),!this.checkEditBoxAsTarget(t)&&Wv(this.diagram)||Oc(this.diagram)&&!_I(this.diagram))if(("Select"===this.action||"Drag"===this.action)&&this.diagram.updatePortVisibility(this.hoverElement,hi.Hover,!0),!(this.tool instanceof Ph||this.tool instanceof zh)||2!==t.button&&2!==t.buttons)if(!0===this.inAction&&!0===this.isMouseDown&&(this.tool instanceof Ph||this.tool instanceof zh))this.isMouseDown=!0,this.eventArgs={},this.getMouseEventArgs(this.currentPosition,this.eventArgs),this.eventArgs.position=this.currentPosition,this.tool.mouseDown(this.eventArgs);else{this.isMouseDown=!0,this.currentPosition=this.prevPosition=this.getMousePosition(t),this.eventArgs={},this.diagram.textEditing&&!this.isMouseOnScrollBar(t)&&(this.diagram.endEdit(),this.diagram.textEditing=!1,"Canvas"===this.diagram.mode&&1!==this.diagram.scroller.currentZoom&&this.diagram.refreshDiagramLayer());var s=this.getTargetElement();this.action=this.diagram.findActionToBeDone(s.obj,s.sourceElement,this.currentPosition,s.target);var o=this.isMetaKey(t);o&&t.shiftKey&&this.diagram.connectorEditingToolModule?this.action="SegmentEnd":(o||t.shiftKey)&&(jv(this.diagram)||Vv(this.diagram))&&(this.action="Select"),this.tool=this.diagram.getTool(this.action),this.tool||(this.action="Select",this.tool=this.diagram.getTool(this.action)),this.getMouseEventArgs(this.currentPosition,this.eventArgs),(o||t.shiftKey)&&(this.eventArgs.info=o&&t.shiftKey?{ctrlKey:o,shiftKey:t.shiftKey}:{ctrlKey:!0}),this.eventArgs.position=this.currentPosition;var l=this.diagram.selectedItems.nodes;if(this.tool.mouseDown(this.eventArgs),this.diagram.selectedItems.canToggleSelection&&l&&this.diagram.selectedItems.nodes&&this.tool instanceof ua)for(var h=0;h=2&&(this.touchStartList=VF(this.touchStartList,0,e)),e||t.preventDefault())}else this.inAction=!1,this.tool.mouseUp(this.eventArgs);!this.isForeignObject(t.target)&&!this.isForeignObject(t.target,!0)&&!e&&t.preventDefault()}},n.prototype.mouseMoveExtend=function(t,e){(this.tool instanceof Ph||this.tool instanceof zh)&&this.tool.mouseMove(this.eventArgs),this.diagram.scrollSettings.canAutoScroll?this.checkAutoScroll(t):this.blocked||this.tool.mouseMove(this.eventArgs),this.eventArgs.target&&(this.hoverElement=this.eventArgs.target);var i=!((this.eventArgs.target instanceof te||this.eventArgs.target instanceof de)&&(e instanceof te||e instanceof de));this.tool instanceof Pd&&this.diagram.updatePortVisibility(this.hoverElement instanceof te||this.hoverElement instanceof de?this.hoverElement:this.hoverNode,hi.Connect|hi.Hover,i),this.hoverElement instanceof te&&this.hoverNode instanceof te&&this.hoverNode&&this.hoverNode.id!==this.hoverElement.id&&this.diagram.updatePortVisibility(this.hoverNode,hi.Connect|hi.Hover,!0),this.hoverElement instanceof de&&this.hoverElement.ports.length>0&&this.diagram.updatePortVisibility(this.hoverElement,hi.Connect|hi.Hover,!0),this.previousElement instanceof te&&this.hoverElement&&this.previousElement.id!==this.hoverElement.id&&this.diagram.updatePortVisibility(this.previousElement,hi.Connect|hi.Hover,!0),this.previousElement=this.hoverElement,""!==this.diagram.tooltip.content&&(this.hoverElement=null),this.hoverNode=i?null:e},n.prototype.checkAction=function(t){if("LabelSelect"===this.action&&this.eventArgs.sourceWrapper&&(this.eventArgs.sourceWrapper instanceof ni||this.eventArgs.sourceWrapper instanceof Jn)){var e=this.commandHandler.findTarget(this.eventArgs.sourceWrapper,this.eventArgs.source);!_r(this.diagram,e,!1,this.eventArgs.sourceWrapper)&&to(e)&&(this.action="LabelDrag",this.tool=this.getTool(this.action),this.tool.mouseDown(this.initialEventArgs))}else to(t)&&Td(t)&&this.initialEventArgs&&this.initialEventArgs.source&&"Select"===this.action&&(!_r(this.diagram,this.eventArgs.source,!1)&&this.eventArgs.source instanceof si&&this.getMouseEventArgs(this.currentPosition,this.eventArgs),(!(t instanceof de)||t instanceof de&&!(wr(this.currentPosition,t.sourcePoint,t.hitPadding)||wr(this.currentPosition,t.targetPoint,t.hitPadding)))&&(this.action="Drag"),this.tool=this.getTool(this.action),this.tool.mouseDown(this.initialEventArgs))},n.prototype.isSwimlaneElements=function(t){return!(t&&(t.isLane||t.isPhase||t.isHeader))},n.prototype.mouseMove=function(t,e){if(this.focus=!0,this.isScrolling)t.preventDefault();else if(Wv(this.diagram)||Oc(this.diagram)&&!_I(this.diagram)){this.currentPosition=this.getMousePosition(t);var i=this.diagram.findObjectsUnderMouse(this.currentPosition),r=this.diagram.findObjectUnderMouse(i,this.action,this.inAction);!function nse(n,t){n.rulerSettings.showRulers&&(n.hRuler.drawRulerMarker(n.hRuler.element,t,n.scroller.horizontalOffset),n.vRuler.drawRulerMarker(n.vRuler.element,t,n.scroller.verticalOffset))}(this.diagram,this.currentPosition);var s=!1,o=void 0;if("touchmove"===t.type&&(e=t.touches)&&e.length>1&&(this.touchMoveList=VF(this.touchMoveList,0,e),"PinchZoom"!==this.action&&(s=!0)),!1===z.equals(this.currentPosition,this.prevPosition)||this.inAction){if(!1===this.isMouseDown||s){this.eventArgs={};var a=null,l=void 0;if(null!==r){if((a=this.diagram.findElementUnderMouse(r,this.currentPosition,this.diagram))&&(l=this.commandHandler.findTarget(a,r)),(l instanceof Zn||l instanceof Nr)&&(l.tooltip&&""!==l.tooltip.content||(l=r)),l!==this.hoverElement){var h=this.getContent();this.hoverElement&&"Auto"===this.hoverElement.tooltip.openOn&&""!==h&&this.elementLeave(),this.diagram.updatePortVisibility(this.hoverElement,hi.Hover,!0),r instanceof te&&(this.hoverNode=r);var c=!0;!this.isSwimlaneElements(r)&&this.hoverElement&&this.isSwimlaneElements(this.hoverElement)&&(c=!1),this.hoverElement=c?r:this.hoverElement;var d,u=void 0;(d=this.diagram.findElementUnderMouse(r,this.currentPosition,this.diagram))instanceof Ke&&((u=this.commandHandler.findTarget(d,r))instanceof Es||u instanceof Ac)&&this.hoverElement.constraints&ri.ToolTip&&(this.hoverElement=u);var p=void 0;d instanceof ni&&((p=this.commandHandler.findTarget(d,r))instanceof Zn||p instanceof Nr)&&p.constraints&Lr.Tooltip&&(this.hoverElement=p),c?this.elementEnter(this.currentPosition,!1):this.hoverElement=r}else this.hoverElement&&this.hoverElement===l&&this.hoverElement.tooltip.content&&void 0!==this.diagram.tooltipObject&&"Mouse"===this.hoverElement.tooltip.relativeMode&&this.setTooltipOffset(this.currentPosition);a&&(o=this.commandHandler.findTarget(a,r))}this.action=this.diagram.findActionToBeDone(r,a,this.currentPosition,o),this.checkFixedUserHandleEvent(Ce.onFixedUserHandleMouseEnter,r,a),this.checkUserHandleEvent(Ce.onUserHandleMouseEnter),this.checkPreviousAction(),this.getMouseEventArgs(this.currentPosition,this.eventArgs),this.tool=this.getTool(this.action),this.mouseEvents(),this.tool instanceof pa||this.tool instanceof zh||this.tool instanceof Ph?this.tool.mouseMove(this.eventArgs):e&&this.tool instanceof em&&this.tool.mouseDown(this.eventArgs),this.updateCursor(),this.renderUmlHighLighter(this.eventArgs);var f=!1;this.hoverElement&&!(this.tool instanceof em)&&r instanceof te&&this.isSwimlaneElements(r)&&(0===this.diagram.selectedItems.nodes.length||!_r(this.diagram,this.hoverElement))||this.hoverElement instanceof de||(f=!0),this.hoverElement&&!(this.tool instanceof em)&&r instanceof de&&(0===this.diagram.selectedItems.connectors.length||!_r(this.diagram,this.hoverElement))||this.hoverElement instanceof te||(f=!0),this.diagram.updatePortVisibility(this.hoverElement,hi.Hover,f);var g=this.getContent();null===r&&this.hoverElement&&"Auto"===this.hoverElement.tooltip.openOn&&g&&(this.hoverElement=null,this.elementLeave()),s=!1}else{this.eventArgs.position=this.currentPosition,"Drag"===this.action&&!_r(this.diagram,this.eventArgs.source,!1)&&this.eventArgs.source instanceof si&&this.getMouseEventArgs(this.currentPosition,this.eventArgs),this.mouseEvents(),(t.ctrlKey||t.shiftKey)&&(this.eventArgs.info=t.ctrlKey&&t.shiftKey?{ctrlKey:t.ctrlKey,shiftKey:t.shiftKey}:{ctrlKey:!0}),this.checkAction(r);var y=this.getConnectorPadding(this.eventArgs);this.getMouseEventArgs(this.currentPosition,this.eventArgs,this.eventArgs.source,y),this.updateCursor(),this.inAction=!0,this.initialEventArgs=null,("Drag"===this.action||"Rotate"===this.action)&&(this.diagram.diagramActions=this.diagram.diagramActions|ee.Interactions);var S=this.diagram.scroller.getPageBounds();this.mouseMoveExtend(t,r);var b=this.diagram.scroller.getPageBounds();if(r&&(S.width!==b.width||S.height!==b.height||S.x!==b.x||S.y!==b.y)&&this.diagram.views&&this.diagram.views.overview){var M=this.diagram.views.overview;M.updateView(M)}}this.prevPosition=this.currentPosition,this.isForeignObject(t.target,!0)||t.preventDefault()}}},n.prototype.getContent=function(){var i,t=this.hoverElement instanceof te&&this.hoverElement.constraints&ie.Tooltip||this.hoverElement instanceof de&&this.hoverElement.constraints&qe.Tooltip||(this.hoverElement instanceof Es||this.hoverElement instanceof Ac)&&this.hoverElement.constraints&ri.ToolTip||(this.hoverElement instanceof Zn||this.hoverElement instanceof Nr)&&this.hoverElement.constraints&Lr.Tooltip,e=this.hoverElement;e instanceof te&&e.children&&e.children.length>0&&(i=this.findIntersectChild(e));var r=t?this.hoverElement.tooltip.content:this.diagram.tooltip.content;return i?i.tooltip.content:r},n.prototype.findIntersectChild=function(t){for(var e,i=new Ne(this.currentPosition.x,this.currentPosition.y,8,8),r=0;r1&&1===t.which&&!function one(n){return!!(n&ee.PreventClearSelection)}(this.diagram.diagramActions)&&(c=!1,this.commandHandler.clearSelection()),(!_r(this.diagram,h)||!c)&&(this.commandHandler.selectObjects([h],void 0,a),this.diagram.selectedItems.canToggleSelection)){var d=this.diagram.selectedItems.nodes;d?d[0].parentObj instanceof Bd&&(s=!0):this.diagram.selectedItems.connectors.length>0&&(s=!0)}}var u=!1,p=this.updateContainerProperties(),f=void 0;if(this.addUmlNode(),this.inAction=!1,this.isMouseDown=!1,this.diagram.selectedObject.helperObject&&(f=this.updateContainerBounds()),this.tool&&(this.tool.prevPosition||this.tool instanceof eF)){this.eventArgs.position=this.currentPosition;var g=this.getConnectorPadding(this.eventArgs);this.getMouseEventArgs(this.currentPosition,this.eventArgs,this.eventArgs.source,g);var v=this.isMetaKey(t);if((v||t.shiftKey)&&(this.eventArgs.info=v&&t.shiftKey?{ctrlKey:v,shiftKey:t.shiftKey}:{ctrlKey:!0}),this.diagram.diagramActions&ee.Interactions&&(this.diagram.diagramActions=this.diagram.diagramActions&~ee.Interactions),this.eventArgs.clickCount=t.detail,this.diagram.selectedObject.helperObject&&(this.tool instanceof ua||this.tool instanceof zd)){if(this.diagram.selectedObject.actualObject&&""!==this.diagram.selectedObject.actualObject.parentId){var S=this.diagram.getObject(this.diagram.selectedObject.actualObject.parentId);S&&S.isLane&&(this.commandHandler.isContainer=!0)}(u=this.diagram.lineRoutingModule&&this.diagram.nameTable.helper&&this.eventArgs.target&&this.eventArgs.target.isLane&&(this.eventArgs.source instanceof si&&this.eventArgs.source.nodes.length>0&&""===this.eventArgs.source.nodes[0].parentId||""===this.eventArgs.source.parentId))&&(this.diagram.diagramActions=this.diagram.diagramActions|ee.PreventLaneContainerUpdate),this.tool.mouseUp(this.eventArgs,p.isPreventHistory)}else{if(this.diagram.selectedItems.canToggleSelection){var b=void 0,M=void 0;if(this.diagram.selectedItems.nodes.length>0)for(var w=0;w1&&D[0].id===i[parseInt(w.toString(),10)].id||r.length>0)&&(M=!0);!this.isSwimlaneSelected&&!s&&!M&&this.tool instanceof ua&&"Select"===this.currentAction&&(!b||this.diagram.selectedItems.connectors.length>0)&&this.commandHandler.clearSelection(!0)}this.isSwimlaneSelected=!1,this.tool.mouseUp(this.eventArgs),this.diagram.checkMenu&&(-1!==window.navigator.userAgent.indexOf("Linux")||-1!==window.navigator.userAgent.indexOf("X11"))&&(!t.pageY&&t instanceof TouchEvent&&t.changedTouches?(window.getSelection().removeAllRanges(),this.diagram.contextMenuModule.contextMenu.open(t.changedTouches[0].pageY,t.changedTouches[0].pageX,this.diagram.element),t.preventDefault()):this.diagram.contextMenuModule.contextMenu.open(t.pageY,t.pageX,this.diagram.element),this.diagram.checkMenu=!1)}p.hasStack&&this.diagram.endGroupAction()}if(f&&this.diagram.endGroupAction(),this.updateContainerBounds(!0),2!==this.eventArgs.clickCount&&(this.commandHandler.updateSelectedNodeProperties(this.eventArgs.source),u)){this.diagram.diagramActions=this.diagram.diagramActions&~ee.PreventLaneContainerUpdate;var A=this.eventArgs.source instanceof si?this.eventArgs.source.nodes:[this.eventArgs.source];if(A)for(w=0;w0&&!N&&this.diagram.renderSelector(!0),!this.inAction&&!this.diagram.currentSymbol&&this.eventArgs){var T=this.getTargetElement();this.diagram.tool!==Ci.ZoomPan&&this.diagram.triggerEvent(Ce.click,{element:T.target instanceof Es?T.target:this.eventArgs.source||this.diagram,position:this.eventArgs.position,count:t.detail,actualObject:this.eventArgs.actualObject,button:0===t.button?"Left":1===t.button?"Middle":"Right"})}this.eventArgs={}}this.diagram.diagramActions=this.diagram.diagramActions&~ee.PreventLaneContainerUpdate,e&&this.updateAnnotation(this.diagram.selectedItems),this.eventArgs={},this.diagram.commandHandler.removeStackHighlighter()},n.prototype.isSwimlaneChild=function(t){if(t.shape&&"SwimLane"!==t.shape.type){var e=this.diagram.nameTable[t.parentId];if(!e)return!1;var i=e.parentId?this.diagram.nameTable[e.parentId]:e;return i&&i.shape&&"SwimLane"===i.shape.type}return!1},n.prototype.updateAnnotation=function(t){var e=t.nodes;if(e.length>0)for(var i=0;i0&&(a+=1),h.isPhase){l="Horizontal"===r.orientation?this.currentPosition.x-e.wrapper.bounds.x:this.currentPosition.y-(e.wrapper.bounds.y+r.header.height);var g={id:Qe(),offset:l,header:{annotation:{content:void 0===h.phases[0].header?"Phase":h.phases[0].header.annotation.content,style:void 0===h.phases[0].header?{}:h.phases[0].header.annotation.style}},style:void 0===h.phases[0]?{}:h.phases[0].style};this.diagram.addPhases(e,[g])}else{var v={id:Qe(),style:h.lanes[0].style,header:{annotation:{content:h.lanes[0].header.annotation.content,style:h.lanes[0].header.annotation.style},style:h.lanes[0].header.style}};if("Horizontal"===h.orientation?v.height=h.lanes[0].height:v.width=h.lanes[0].width,"Horizontal"===r.orientation?(s=i.rowIndex?i.rowIndex:this.diagram.nameTable[i.parentId].rowIndex,i.wrapper.offsetYs)v.header.width=r.lanes[parseInt(s.toString(),10)].header.width,v.header.height=r.lanes[parseInt(s.toString(),10)].header.height;else{var S=void 0;S="Horizontal"===r.orientation?i.rowIndex<3?0:s-a-1:s-1,v.header.width=r.lanes[parseInt(S.toString(),10)].header.width,v.header.height=r.lanes[parseInt(S.toString(),10)].header.height}f&&("height"===f?(v.width=v.height,delete v.height):(v.height=v.width,delete v.width)),this.diagram.addLanes(e,[v],"Horizontal"===r.orientation?s-a:s)}this.commandHandler.select(e)}else if(h.isLane){var b={id:Qe(),width:t.width,height:t.height,addInfo:t.addInfo,shape:{type:"SwimLane",header:{annotation:{content:void 0===h.header?"Header":h.header.annotation.content,style:void 0===h.header?{}:h.header.annotation.style},height:50,style:h.header?h.header.style:h.lanes[0].header.style},phases:[{id:Qe(),header:{annotation:{content:void 0===h.phases||void 0===h.phases[0].header?"Phase":h.phases[0].header.annotation.content,style:void 0===h.phases||void 0===h.phases[0].header?{}:h.phases[0].header.annotation.style},style:void 0===h.phases||void 0===h.phases[0].header?{}:h.phases[0].header.style},style:void 0===h.phases?{}:h.phases[0].style}],lanes:[{id:Qe(),height:t.height,width:t.width,style:h.lanes[0].style,header:{annotation:{content:h.lanes[0].header.annotation.content,style:h.lanes[0].header.annotation.style},style:h.lanes[0].header.style}}],orientation:h.orientation}};"Vertical"===h.orientation&&(b.width+=20),b.offsetX=this.currentPosition.x+b.width/2,b.offsetY=this.currentPosition.y+b.height/2,b.style=t.style,this.diagram.add(b)}},n.prototype.mouseLeave=function(t){this.tool&&this.inAction&&this.tool.mouseLeave(this.eventArgs),this.diagram.selectedObject.helperObject&&(this.updateContainerProperties(),this.updateContainerBounds()&&this.diagram.endGroupAction()),this.eventArgs&&this.eventArgs.source&&(this.diagram.updatePortVisibility(this.eventArgs.source,hi.Hover,!0),this.hoverElement=null),this.eventArgs&&!this.eventArgs.source&&this.hoverElement&&(this.hoverElement=null),this.tool instanceof Pd&&this.eventArgs&&this.eventArgs.target&&this.eventArgs.target instanceof te&&(this.diagram.updatePortVisibility(this.eventArgs.target,hi.Hover|hi.Connect,!0),this.hoverElement=null);var i=this.diagram.selectedItems;i&&i.wrapper&&(lm(this.diagram,i)||this.diagram.renderSelector(!0)),(this.diagram.diagramActions&ee.Interactions||this.diagram.diagramActions&ee.ToolAction)&&(this.diagram.diagramActions=this.diagram.diagramActions&~ee.ToolAction),this.isMouseDown=!1,this.focus=!1,this.touchStartList=null,this.touchMoveList=null,this.elementLeave(),this.commandHandler.removeSnap(),this.inAction=!1,this.eventArgs={},this.diagram.selectedObject&&this.diagram.selectedObject.helperObject&&(this.diagram.remove(this.diagram.selectedObject.helperObject),this.diagram.selectedObject={helperObject:void 0,actualObject:void 0}),this.tool=null,function rse(){var t,e,n=document.getElementsByClassName("e-d-ruler-marker");if(n&&n.length>0)for(e=n.length-1;e>=0;e--)(t=n[parseInt(e.toString(),10)])&&t.parentNode.removeChild(t)}(),"Rotate"===this.action&&this.diagram.diagramCanvas.classList.remove("e-diagram-rotate"),t.preventDefault()},n.prototype.mouseWheel=function(t){this.diagram.blazorActions|=on.interaction;var e={event:t,cancel:!1};if(this.diagram.triggerEvent(Ce.mouseWheel,e),!e.cancel){var i=t.wheelDelta>0||-40*t.detail>0,r=this.getMousePosition(t);if(this.diagram.tooltipObject.close(),this.isMetaKey(t)){var o=this.diagram.scrollSettings.zoomFactor;this.diagram.zoomTo(i?{type:"ZoomIn",zoomFactor:o,focusPoint:r}:{type:"ZoomOut",zoomFactor:o,focusPoint:r}),t.preventDefault()}else{var a=this.diagram.scroller.horizontalOffset,l=this.diagram.scroller.verticalOffset,h=i?10:-10;this.tool&&(this.tool instanceof Ph||this.tool instanceof zh)&&(this.eventArgs={},this.getMouseEventArgs(r,this.eventArgs),this.eventArgs.position=r,this.tool.mouseWheel(this.eventArgs)),this.diagram.scrollActions|=ca.Interaction;var c=!0;if(t.isTrusted){var d=!1;(Math.abs(t.deltaY)<100&&-0===Math.abs(t.deltaX)||Math.abs(t.deltaX)<100&&-0===Math.abs(t.deltaY))&&(d=!0);var u=!1;(0!==t.deltaX||0!==t.deltaY)&&(u=navigator.userAgent.includes("Macintosh")),u?Math.abs(t.deltaX)>Math.abs(t.deltaY)?(t.shiftKey||t.deltaX&&-0!==t.deltaX&&(d||!u))&&this.diagram.scroller.zoom(1,h,0,r,c,void 0,d):t.deltaY&&-0!==t.deltaY&&(d||!u)&&this.diagram.scroller.zoom(1,0,h,r,c,void 0,d):t.shiftKey||t.deltaX&&-0!==t.deltaX&&(d||!u)?this.diagram.scroller.zoom(1,h,0,r,c,void 0,d):t.deltaY&&-0!==t.deltaY&&(d||!u)&&this.diagram.scroller.zoom(1,0,h,r,c,void 0,d)}else t.shiftKey||t.deltaX&&-0!==t.deltaX?this.diagram.scroller.zoom(1,h,0,r,c):this.diagram.scroller.zoom(1,0,h,r,c);this.diagram.scrollActions&=~ca.Interaction,(a!==this.diagram.scroller.horizontalOffset||l!==this.diagram.scroller.verticalOffset)&&t.preventDefault()}if(this.diagram.textEditing){if(this.diagram.isTriggerEvent=!0,this.diagram.activeLabel.parentId){var f=this.diagram.getObject(this.diagram.activeLabel.parentId);this.diagram.startTextEdit(f,this.diagram.activeLabel.id)}this.diagram.isTriggerEvent=!1}this.diagram.blazorActions=this.diagram.blazorActions&~on.interaction}},n.prototype.keyDown=function(t){if(t.fromMouseEvents&&(t.ctrlKey&&(this.keyArgs.keyModifiers=1),t.shiftKey&&(this.keyArgs.keyModifiers=4),t.shiftKey&&t.ctrlKey&&(this.keyArgs.keyModifiers=5)),!(this.diagram.diagramActions&ee.TextEdit)&&!this.checkEditBoxAsTarget(t)||"Escape"===t.key||27===t.keyCode){var i=void 0,r=t.keyCode?t.keyCode:t.which,s=t.key;("ArrowDown"===s||"ArrowUp"===s||"ArrowLeft"===s||"ArrowRight"===s)&&(this.isNudgeKey=!0);var o=this.isMetaKey(t);if(this.diagram.commandManager&&this.diagram.commands)for(var l=0,h=Object.keys(this.diagram.commands);l4&&(S({keyDownEventArgs:KeyboardEvent,parameter:i.parameter,type:"KEYDOWN"}),this.keyCount=0)),this.isKeyUp=!1):S({keyDownEventArgs:KeyboardEvent,parameter:i.parameter})}break}}}}this.keyArgs={element:this.diagram.selectedItems,key:t.key,keyCode:t.keyCode?t.keyCode:t.which},this.getKeyModifier(this.keyArgs,t),this.diagram.diagramActions&ee.TextEdit&&this.getlabel(this.keyArgs,t),this.diagram.triggerEvent(Ce.keyDown,this.keyArgs)},n.prototype.getlabel=function(t,e){var i=this.diagram.activeLabel;t.target=this.diagram.element.id+"_editBox";var r=this.diagram.nameTable[i.parentId];if(document.getElementById(this.diagram.element.id+"_editBox")){t.text=document.getElementById(this.diagram.element.id+"_editBox").value;for(var s=0;s=this.diagram.scroller.viewPortWidth-18?r="right":e.x+this.diagram.scroller.horizontalOffsetthis.diagram.scroller.viewPortHeight-18?r="bottom":e.y+this.diagram.scroller.verticalOffset0&&(s=this.findIntersectChild(this.hoverElement)),"Auto"===this.hoverElement.tooltip.openOn&&""!==r&&Dx(this.diagram,s||(i?this.hoverElement:void 0)),this.hoverElement.tooltip.content&&("Mouse"===this.hoverElement.tooltip.relativeMode?this.setTooltipOffset(t):(this.diagram.tooltipObject.offsetX=0,this.diagram.tooltipObject.offsetY=0));var o=this.diagram.findObjectsUnderMouse(this.currentPosition),a=this.diagram.findObjectUnderMouse(o,this.action,this.inAction);if(null!==a){var l=void 0;this.hoverElement.tooltip.isSticky&&(this.diagram.tooltipObject.isSticky=!0),a instanceof te&&a.children&&a.children.length>0&&(a=s||a),l=a.ports&&(this.hoverElement instanceof Es||this.hoverElement instanceof Ac)||a.annotations&&(this.hoverElement instanceof Zn||this.hoverElement instanceof Nr)?document.getElementById(a.id+"_"+this.hoverElement.id):document.getElementById(a.id+(a.shape&&a.shape instanceof hm?"_content_native_element":"_groupElement")),"Auto"===this.hoverElement.tooltip.openOn&&""!==r&&(this.diagram.tooltipObject.close(),this.diagram.tooltipObject.openOn=this.hoverElement.tooltip.openOn,this.diagram.tooltipObject.dataBind()),function Kre(n,t){var e=0;return n instanceof de?n.constraints&qe.Tooltip?e=n.constraints&qe.Tooltip:n.constraints&qe.InheritTooltip&&(e=t.constraints&rt.Tooltip):n instanceof Es||n instanceof Ac?n.constraints&ri.ToolTip?e=n.constraints&ri.ToolTip:n.constraints&ri.InheritTooltip&&(e=t.constraints&rt.Tooltip):n instanceof Zn||n instanceof Nr?n.constraints&Lr.Tooltip&&(e=n.constraints&Lr.Tooltip):n.constraints&ie.Tooltip?e=n.constraints&ie.Tooltip:n.constraints&ie.InheritTooltip&&(e=t.constraints&rt.Tooltip),e}(this.hoverElement,this.diagram)&&"Auto"===this.hoverElement.tooltip.openOn&&(this.diagram.tooltipObject.target=this.hoverElement.id,this.diagram.tooltipObject.open("Mouse"===this.hoverElement.tooltip.relativeMode?this.diagram.element:l))}}},n.prototype.elementLeave=function(){this.diagram.tooltipObject&&!this.diagram.tooltipObject.isSticky&&"Custom"!==this.diagram.tooltipObject.openOn&&this.diagram.tooltipObject.close()},n.prototype.setTooltipOffset=function(t){var e=function Mse(n,t,e,i){var o="Mouse"===(!(e instanceof te?e.constraints&ie.InheritTooltip:e instanceof de?e.constraints&qe.InheritTooltip:e.constraints&ri.InheritTooltip)&&(e instanceof te?e.constraints&ie.Tooltip:e instanceof de?e.constraints&qe.Tooltip:e.constraints&ri.ToolTip)?e.tooltip.relativeMode:n.tooltip.relativeMode);"Mouse"===i?o=!0:"Object"===i&&(o=!1);var a=function wse(n,t,e,i){var o,r={},s=document.getElementById(e.element.id);if(n instanceof te||n instanceof de)o=n.wrapper.bounds;else{var a=e.findObjectsUnderMouse(t),l=e.findObjectUnderMouse(a,"Select",!1);o=e.findElementUnderMouse(l,t,e).bounds}var c=s.getBoundingClientRect();switch(e.tooltipObject.position){case"BottomCenter":r=Hc(t,o.bottomCenter,e,i,c.width/2,c.height);break;case"BottomLeft":case"LeftBottom":r=Hc(t,o.bottomLeft,e,i,0,c.height);break;case"BottomRight":case"RightBottom":r=Hc(t,o.bottomRight,e,i,c.width,c.height);break;case"LeftCenter":r=Hc(t,o.middleLeft,e,i,0,c.height/2);break;case"LeftTop":case"TopLeft":r=Hc(t,o.topLeft,e,i,0,0);break;case"RightCenter":r=Hc(t,o.middleRight,e,i,c.width,c.height/2);break;case"RightTop":case"TopRight":r=Hc(t,o.topRight,e,i,c.width,0);break;case"TopCenter":r=Hc(t,o.topCenter,e,i,c.width/2,0)}return r}(e,t,n,o),l=qa(n);return{x:a.x+l.width,y:a.y+l.height}}(this.diagram,t,this.hoverElement);this.diagram.tooltipObject.offsetX=e.x,this.diagram.tooltipObject.offsetY=e.y},n.prototype.altKeyPressed=function(t){return!!(t&pt.Alt)},n.prototype.ctrlKeyPressed=function(t){return!!(t&pt.Control)},n.prototype.shiftKeyPressed=function(t){return!!(t&pt.Shift)},n.prototype.scrolled=function(t){this.diagram.updateScrollOffset()},n.prototype.doubleClick=function(t){if(Wv(this.diagram)){var e=void 0,i=this.diagram.findObjectsUnderMouse(this.currentPosition),r=this.diagram.findObjectUnderMouse(i,this.action,this.inAction);if(null!==r&&Wv(this.diagram))if(e=this.diagram.findElementUnderMouse(r,this.currentPosition,this.diagram),this.tool&&(this.tool instanceof Ph||this.tool instanceof zh))this.tool.mouseUp(this.eventArgs),this.isMouseDown=!1,this.eventArgs={},this.tool=null,t.preventDefault();else{var o=this.diagram.commandHandler.getObjectLayer(r.id);!o||o.lock||!o.visible||this.diagram.diagramActions&ee.TextEdit||this.diagram.startTextEdit(r,e instanceof ni?e.id.split(r.id+"_")[1]:void 0)}this.diagram.triggerEvent(Ce.doubleClick,{source:r||this.diagram,position:this.currentPosition,count:t.detail})}},n.prototype.itemClick=function(t,e){var i=t;return cs(this.diagram,i,!0)?i:null},n.prototype.inputChange=function(t){var i,s,o,a,l,h,c,d,u,p=document.getElementById(this.diagram.element.id+"_editBox"),f=document.getElementById(this.diagram.element.id+"_editTextBoxDiv"),g=p.value,v=g.split("\n");(!(a=this.diagram.selectedItems.nodes[0]?this.diagram.selectedItems.nodes[0]:this.diagram.selectedItems.connectors[0])&&this.tool instanceof $I||a&&"SwimLane"===a.shape.type)&&(a=this.diagram.nameTable[this.diagram.activeLabel.parentId]),a&&("Text"!==a.shape.type&&a.annotations.length>0||"Text"===a.shape.type)&&(c=HF((o=this.diagram.getWrapper(a.wrapper,this.diagram.activeLabel.id)).style,g,void 0,void 0,i=(i=a.wrapper.bounds.width90?i:90),s=Number(p.style.fontSize.split("px")[0]),v.length>1&&""===v[v.length-1]&&(c.height=c.height+s),d=this.diagram.scroller.transform,u=P3(this.diagram)?d.scale:1,l=(12>c.height?12:c.height)*u,f.style.left=(o.bounds.center.x+d.tx)*d.scale-(h=(90>(h=c.width)?90:h)*u)/2-2.5+"px",f.style.top=(o.bounds.center.y+d.ty)*d.scale-l/2-3+"px",f.style.width=h+"px",f.style.height=l+"px",p.style.minHeight="12px",p.style.minWidth="90px",p.style.width=h+"px",p.style.height=l+"px")},n.prototype.isAddTextNode=function(t,e){return!(!(this.tool instanceof $I||e)||(this.tool=null,t&&!FI(this.diagram)&&(this.diagram.drawingObject=void 0,this.diagram.currentDrawingObject=void 0),MF(this.diagram.nodes,t.id)||MF(this.diagram.connectors,t.id)))},n.prototype.checkEditBoxAsTarget=function(t){return!(!t.target||t.target.id!==this.diagram.element.id+"_editBox")},n.prototype.getMouseEventArgs=function(t,e,i,r){var s,o,a;if(e.position=t,i?(o=this.diagram.findObjectsUnderMouse(this.currentPosition,i),s=this.diagram.findTargetObjectUnderMouse(o,this.action,this.inAction,e.position,i)):"Drag"===this.action||"ConnectorSourceEnd"===this.action||"SegmentEnd"===this.action||"OrthoThumb"===this.action||"BezierSourceThumb"===this.action||"BezierTargetThumb"===this.action||"ConnectorTargetEnd"===this.action||-1!==this.action.indexOf("Rotate")||-1!==this.action.indexOf("Resize")?(s=this.diagram.selectedItems,!this.diagram.currentSymbol&&"Drag"===this.action&&s&&this.diagram.selectedItems.nodes.length>0&&"SwimLane"===this.diagram.selectedItems.nodes[0].shape.type&&(o=this.diagram.findObjectsUnderMouse(this.currentPosition),s=this.diagram.findObjectUnderMouse(o,this.action,this.inAction))):(o=this.diagram.findObjectsUnderMouse(this.currentPosition),s=this.diagram.findObjectUnderMouse(o,this.action,this.inAction)),s&&s.isHeader&&(this.eventArgs.actualObject=s=this.diagram.nameTable[s.parentId]),s){var l=void 0,h=void 0,c=void 0;if(((a=this.diagram.findElementUnderMouse(s,this.currentPosition,this.diagram,r))&&s.ports&&s.ports.length&&!lb(s,a)||!a||!s)&&o&&o.length&&i instanceof si)for(l=i.connectors[0],c=o.length-1;c>=0;c--)if(((h=o[parseInt(c.toString(),10)])instanceof te||h instanceof de)&&l&&l.connectionPadding){if(a=this.diagram.findElementUnderMouse(s=h,this.currentPosition,this.diagram,r),l.constraints&qe.ConnectToNearByPort&&s&&s.ports&&s.ports.length&&lb(s,a))break;if((h instanceof te||h instanceof de)&&l&&l.connectionPadding&&h.wrapper.outerBounds.containsPoint(this.currentPosition)&&l.constraints&qe.ConnectToNearByNode&&!(l.constraints&qe.ConnectToNearByPort)){a=this.diagram.findElementUnderMouse(s=h,this.currentPosition,this.diagram,0);break}}}return i?(e.target=s,e.targetWrapper=a):(e.source=s,e.sourceWrapper=a),e.actualObject=this.eventArgs.actualObject,e.source instanceof si&&void 0===e.actualObject&&(e.source.nodes.length>0||e.source.connectors.length>0)&&(e.actualObject=e.source.nodes.length>0?this.diagram.nameTable[e.source.nodes[0].id]:this.diagram.nameTable[e.source.connectors[0].id]),e.startTouches=this.touchStartList,e.moveTouches=this.touchMoveList,e},n.prototype.resetTool=function(){this.action="Select",this.hoverElement=null,this.hoverNode=null,this.tool=this.diagram.getTool(this.action),this.updateCursor()},n.prototype.updateTool=function(){this.eventArgs&&!this.eventArgs.position&&(this.action="Select")},n.prototype.getTool=function(t){switch(t){case"Select":return new Kv(this.commandHandler,!0);case"Drag":return new ua(this.commandHandler);case"Rotate":return new qx(this.commandHandler);case"LayoutAnimation":return new Une(this.commandHandler);case"FixedUserHandle":return new _ne(this.commandHandler,!0);case"Hyperlink":return new eF(this.commandHandler);case"ResizeSouthEast":case"ResizeSouthWest":case"ResizeNorthEast":case"ResizeNorthWest":case"ResizeSouth":case"ResizeNorth":case"ResizeWest":case"ResizeEast":return new zd(this.commandHandler,t);case"ConnectorSourceEnd":case"ConnectorTargetEnd":case"BezierSourceThumb":case"BezierTargetThumb":return new Pd(this.commandHandler,t);case"SegmentEnd":case"OrthoThumb":return new r_(this.commandHandler,t);case"Draw":var e="shape",i=function gse(n){var t;return n&&(n.type?t="Connector":n.shape&&!n.type&&(t="Node")),t}(this.diagram.drawingObject);if("Node"===i&&"Text"===this.diagram.drawingObject.shape.type)return new $I(this.commandHandler);if("Connector"===i&&"Freehand"===this.diagram.drawingObject.type)return new Yne(this.commandHandler);if("Node"===i&&"Polygon"===this.diagram.drawingObject.shape[""+e]&&!this.diagram.drawingObject.shape.points)return new Ph(this.commandHandler);if("Node"===i||"Node"===i&&"Polygon"===this.diagram.drawingObject.shape[""+e]&&this.diagram.drawingObject.shape.points)return new qI(this.commandHandler,this.diagram.drawingObject);if("Connector"===i&&"Polyline"===this.diagram.drawingObject.type)return new zh(this.commandHandler);if("Connector"===i)return new pa(this.commandHandler,"ConnectorSourceEnd",this.diagram.drawingObject);break;case"Pan":return new em(this.commandHandler,!1);case"PinchZoom":return new em(this.commandHandler,!0);case"PortDrag":return new ua(this.commandHandler,"Port");case"PortDraw":return new pa(this.commandHandler,"ConnectorSourceEnd",this.diagram.drawingObject);case"LabelSelect":return new Kv(this.commandHandler,!0,"LabelSelect");case"LabelDrag":return new jne(this.commandHandler);case"LabelResizeSouthEast":case"LabelResizeSouthWest":case"LabelResizeNorthEast":case"LabelResizeNorthWest":case"LabelResizeSouth":case"LabelResizeNorth":case"LabelResizeWest":case"LabelResizeEast":return new Vne(this.commandHandler,t);case"LabelRotate":return new Wne(this.commandHandler)}return null},n.prototype.getCursor=function(t){var e=this.diagram.selectedItems.annotation?this.diagram.selectedItems.wrapper.children[0]:this.diagram.selectedItems;return function Fne(n,t){if(t+=360,t%=360,-1===n.indexOf("Resize"))return Xx[""+n];var e=Xx[""+n];return t>=0&&t<25||t>=160&&t<=205||t>=340&&t<=360?e:t>=25&&t<=70||t>=205&&t<=250?"n-resize"===e||"s-resize"===e?"ne-resize":"nw-resize"===e||"se-resize"===e?"n-resize":"e-resize"===e||"w-resize"===e?"nw-resize":"e-resize":t>=70&&t<=115||t>=250&&t<=295?"n-resize"===e||"s-resize"===e?"e-resize":"nw-resize"===e||"se-resize"===e?"ne-resize":"e-resize"===e||"w-resize"===e?"n-resize":"nw-resize":t>=115&&t<=155||t>=295&&t<=340?"n-resize"===e||"s-resize"===e?"nw-resize":"nw-resize"===e||"se-resize"===e?"e-resize":"e-resize"===e||"w-resize"===e?"ne-resize":Xx[""+n]:"n-resize"}(t,this.diagram.selectedItems.annotation?e.rotateAngle+e.parentTransform:e.rotateAngle)},n.prototype.findElementUnderMouse=function(t,e,i,r){return this.objectFinder.findElementUnderSelectedItem(t,e,i,r)},n.prototype.findObjectsUnderMouse=function(t,e){return this.objectFinder.findObjectsUnderMouse(t,this.diagram,this.eventArgs,e)},n.prototype.findObjectUnderMouse=function(t,e,i){return this.objectFinder.findObjectUnderMouse(this.diagram,t,e,i,this.eventArgs,this.currentPosition)},n.prototype.findTargetUnderMouse=function(t,e,i,r,s){return this.objectFinder.findObjectUnderMouse(this.diagram,t,e,i,this.eventArgs,r,s)},n.prototype.findActionToBeDone=function(t,e,i,r){return function kne(n,t,e,i,r,s,o){if(s&&s.length>1&&r&&r.length>1)return"PinchZoom";if(i.currentSymbol)return"Drag";if("PortDraw"===i.eventHandler.action&&(i.tool&=~Ci.DrawOnce),(k3(i)||FI(i))&&i.drawingObject)return"Draw";if(Xa(i)&&(l=i.selectedItems).wrapper&&qr(l.constraints,"UserHandle"))for(var h=0,c=l.userHandles;h=50&&(l.x=(a.points[parseInt(h.toString(),10)].x+a.points[h+1].x)/2,l.y=(a.points[parseInt(h.toString(),10)].y+a.points[h+1].y)/2,wr(e,l,n.hitPadding?n.hitPadding:10)))return"OrthoThumb"}else zI(n)&&console.warn('[WARNING] :: Module "ConnectorEditing" is not available in Diagram component! You either misspelled the module name or forgot to load it.');return null}(g,l,e,i);if("OrthoThumb"===S)return S;if(qr(l.constraints,"ConnectorSourceThumb")&&kI(g)&&S||qr(l.constraints,"ConnectorTargetThumb")&&PI(g)&&S)return S}}else{var b=i.selectedItems.handleSize/2/i.scroller.currentZoom,M=10/i.scroller.currentZoom,w=Hi();qi(w,p.rotateAngle+p.parentTransform,p.offsetX,p.offsetY);var C=p.offsetX-p.pivot.x*p.actualSize.width,D=p.offsetY-p.pivot.y*p.actualSize.height,A={x:C+(.5===p.pivot.x?2*p.pivot.x:p.pivot.x)*p.actualSize.width/2,y:D-30/i.scroller.currentZoom};A=Je(w,A);var x=!!i.selectedItems.annotation,R=!(!x||!RI(i.selectedItems.annotation));if(qr(l.constraints,"Rotate")&&wr(e,A,M)&&i.selectedItems.thumbsConstraints&bt.Rotate){if(x&&R)return"LabelRotate";if(!x)return"Rotate"}if(u.Inflate(b),u.containsPoint(e)&&(S=function Pne(n,t,e,i,r,s){var o;return 1===n.selectedItems.nodes.length&&0===n.selectedItems.connectors.length&&n.selectedItems.nodes[0].container&&(o=function Hne(n,t,e,i,r){var s=10/n.scroller.currentZoom,o=40/n.scroller.currentZoom,a=n.selectedItems,l=t.actualSize.width,h=t.actualSize.height,c=new Ne(i,r,t.style.strokeWidth,h),d=new Ne(i+l,r,t.style.strokeWidth,h),u=new Ne(i,r,l,t.style.strokeWidth),p=new Ne(i,r+h,l,t.style.strokeWidth),f=cs(n,n.selectedItems.nodes[0],!0)?n.nameTable[n.selectedItems.nodes[0].parentId]:n.selectedItems.nodes[0];if(l>=o&&h>=o){if(fa(a.constraints,"ResizeEast",a.thumbsConstraints,a)&&d.containsPoint(e,s))return"ResizeEast";if(fa(a.constraints,"ResizeSouth",a.thumbsConstraints,a)&&p.containsPoint(e,s))return"ResizeSouth";if("Grid"!==f.container.type){if(fa(a.constraints,"ResizeWest",a.thumbsConstraints,a)&&c.containsPoint(e,s))return"ResizeWest";if(fa(a.constraints,"ResizeNorth",a.thumbsConstraints,a)&&u.containsPoint(e,s))return"ResizeNorth"}}return null}(n,t,e,r,s)),!o&&(!n.selectedItems.nodes[0]||!n.selectedItems.nodes[0].isPhase&&!n.selectedItems.nodes[0].isLane&&"SwimLane"!==n.selectedItems.nodes[0].shape.type)&&(o=function Bne(n,t,e,i,r,s){var o=40/n.scroller.currentZoom,a=n.selectedItems.handleSize/2/n.scroller.currentZoom,l=n.selectedItems,h=!!l.annotation;if(t.actualSize.width>=o&&t.actualSize.height>=o){if(fa(l.constraints,"ResizeSouthEast",l.thumbsConstraints,l)&&wr(e,Je(i,{x:r+t.actualSize.width,y:s+t.actualSize.height}),a))return h?"LabelResizeSouthEast":"ResizeSouthEast";if(fa(l.constraints,"ResizeSouthWest",l.thumbsConstraints,l)&&wr(e,Je(i,{x:r,y:s+t.actualSize.height}),a))return h?"LabelResizeSouthWest":"ResizeSouthWest";if(fa(l.constraints,"ResizeNorthEast",l.thumbsConstraints,l)&&wr(e,Je(i,{x:r+t.actualSize.width,y:s}),a))return h?"LabelResizeNorthEast":"ResizeNorthEast";if(fa(l.constraints,"ResizeNorthWest",l.thumbsConstraints,l)&&wr(e,Je(i,{x:r,y:s}),a))return h?"LabelResizeNorthWest":"ResizeNorthWest"}return fa(l.constraints,"ResizeEast",l.thumbsConstraints,l)&&wr(e,Je(i,{x:r+t.actualSize.width,y:s+t.actualSize.height/2}),a)?h?"LabelResizeEast":"ResizeEast":fa(l.constraints,"ResizeWest",l.thumbsConstraints,l)&&wr(e,Je(i,{x:r,y:s+t.actualSize.height/2}),a)?h?"LabelResizeWest":"ResizeWest":fa(l.constraints,"ResizeSouth",l.thumbsConstraints,l)&&wr(e,Je(i,{x:r+t.actualSize.width/2,y:s+t.actualSize.height}),a)?h?"LabelResizeSouth":"ResizeSouth":fa(l.constraints,"ResizeNorth",l.thumbsConstraints,l)&&wr(e,Je(i,{x:r+t.actualSize.width/2,y:s}),a)?h?"LabelResizeNorth":"ResizeNorth":null}(n,t,e,i,r,s)),o||null}(i,p,e,w,C,D),S))return S}}if(Oc(i)&&!n)return"Pan";if((o instanceof Es||o instanceof Ac)&&(!Oc(i)||jv(i)||Vv(i))&&(S=function Rne(n,t,e,i){if(Ux(t)&&(ga(t,hi.Hover)||ga(t,hi.Visible))){if(t.constraints&ri.Drag)return"PortDrag"}else if(_x(t)&&(ga(t,hi.Hover)||ga(t,hi.Visible))&&t.constraints&ri.Draw){n.drawingObject={};var r={type:"Orthogonal",sourcePortID:t.id};return n.drawingObject=r,n.tool|=Ci.DrawOnce,n.currentDrawingObject=r,"PortDraw"}return"None"}(i,o),"None"!==S))return S;if((o instanceof Zn||o instanceof Nr)&&!Oc(i)&&Td(o))return _r(i,o,void 0,t)&&to(o)?"LabelDrag":"LabelSelect";if(null!==n){if(!(n instanceof te||n instanceof de))return"Select";if(t&&t.id){var L=t.id.split(n.id)[1];if(L&&L.match("^_icon"))return"LayoutAnimation"}if(t&&t.id)for(var O=void 0,N=0;N-1)return"FixedUserHandle";if(t instanceof ni&&t.hyperlink.link)return"Hyperlink";if(!to(n)||!_r(i,n,!1)||void 0!==i.selectedItems.annotation)return n&&Oc(i)&&!_I(i)?"Pan":i.selectedItems.nodes.length&&i.selectedItems.nodes[0].isLane&&i.selectedItems.wrapper&&i.selectedItems.wrapper.bounds.containsPoint(e)?"Drag":"Select";if(n instanceof de&&!wr(e,n.sourcePoint,n.hitPadding)&&!wr(e,n.targetPoint,n.hitPadding)||!(n instanceof de))return"Drag"}return"Select"}(t,e,this.currentPosition,this.diagram,this.touchStartList,this.touchMoveList,r)},n.prototype.updateContainerBounds=function(t){var e=!1;if(this.diagram.selectedObject.helperObject&&this.diagram.selectedObject.actualObject instanceof te){var i=this.tool instanceof zd,r=this.diagram.selectedObject.actualObject,s=this.diagram.nameTable[r.parentId];t?q3(this.diagram,r,this.currentPosition,i):((!s||s&&"SwimLane"!==s.shape.type)&&this.diagram.updateDiagramObject(r),e=function Ane(n,t,e,i){var r,o=!1;if(cs(n,t,!0)){n.protectPropertyChange(!0);var a=(r=n.nameTable[t.parentId]).wrapper;if(r&&"Canvas"===r.container.type){if(i||a.bounds.x<=e.x&&a.bounds.right>=e.x&&a.bounds.y<=e.y&&a.bounds.bottom>=e.y){var l=void 0,h=a.bounds.y,c=a.bounds.x,d=n.nameTable[r.parentId]||r;if("SwimLane"===d.shape.type)o=Jv(r,d,t,n,!0);else{var p=n.nameTable[r.parentId]||r,f=p.shape;l=p.wrapper,a.actualSize.widtha.outerBounds.x)&&(void 0!==r.rowIndex?(l.updateColumnWidth(r.columnIndex,a.outerBounds.width,!0),"Horizontal"===f.orientation&&f.phaseSize&&YI(p,n,a,r.columnIndex),Pc(n,p),n.drag(p,c-a.bounds.x,h-a.bounds.y)):n.scale(r,1+(a.outerBounds.width-a.actualSize.width)/a.actualSize.width,1,a.outerBounds.xa.outerBounds.y)&&(void 0!==r.rowIndex?(l.updateRowHeight(r.rowIndex,a.outerBounds.height,!0),n.drag(p,c-a.bounds.x,h-a.bounds.y)):n.scale(r,1,1+(a.outerBounds.height-a.actualSize.height)/a.actualSize.height,a.outerBounds.yi.y&&(h+=u>0?-1:1,u+=u>0?-1:1):i&&e.wrapper.offsetYi.x&&(h+=u>0?-1:1,u+=u>0?-1:1):i&&e.wrapper.offsetX1&&!(this.diagram.lineRoutingModule&&this.diagram.constraints&rt.LineRouting))for(var b=t.offsetX-this.diagram.selectedItems.offsetX,M=t.offsetY-this.diagram.selectedItems.offsetY,w=t.rotateAngle-this.diagram.selectedItems.rotateAngle,C=0;C-1){var x=c.children;x.splice(x.indexOf(o.id),1),this.diagram.nameTable[o.id].parentId="",i=!0,c.wrapper.children.splice(A,1)}}if(function One(n,t,e,i){var r=n,s=e.nameTable[r.parentId],o=e.nameTable[r.parentId];if(t&&o&&o.container&&"Stack"===o.container.type&&t.container&&"Stack"===t.container.type&&o.id!==t.parentId){var a=o.wrapper.children.indexOf(r.wrapper);a>-1&&(e.nameTable[r.id].parentId=t.id,o.wrapper.children.splice(a,1))}if(t&&t.parentId&&r.parentId&&"Drag"===i&&o.container&&"Stack"===o.container.type){var l=s.wrapper.children.indexOf(t.wrapper),h=s.wrapper.children.indexOf(r.wrapper),c={targetIndex:l,target:t,sourceIndex:h,source:n};s.wrapper.children.splice(h,1),s.wrapper.children.splice(l,0,r.wrapper),e.commandHandler.addHistoryEntry({type:"StackChildPositionChanged",redoObject:{targetIndex:h,target:t,sourceIndex:l,source:n},undoObject:c,category:"Internal"})}}(o,h,this.diagram,this.action),(c=cs(this.diagram,o)?this.diagram.nameTable[o.parentId]:this.diagram.nameTable[o.parentId]||o)&&c.container&&"Canvas"===c.container.type&&(c.wrapper.maxWidth=c.maxWidth=c.wrapper.actualSize.width,c.wrapper.maxHeight=c.maxHeight=c.wrapper.actualSize.height,e=!0),cs(this.diagram,o,!0)&&c&&"Canvas"===c.container.type)if(this.diagram.selectedItems.nodes.length>1)for(C=0;C0)for(var i=0;i0&&e.columnIndex>0||l&&e.isLane)){if("Horizontal"===t.container.orientation&&e.isPhase&&e.wrapper.width>e.maxWidth&&(e.maxWidth=e.wrapper.width,e.wrapper.maxWidth=e.wrapper.width),h.updateColumnWidth(e.columnIndex,r.width,!0,c),Wx(this.diagram,e,t),e.isPhase){var f=this.diagram.nameTable[""+t.shape.phases[e.columnIndex].header.id];f.maxWidth0?(r=new of(t,"",u),t.shape.classShape.attributes.push(r)):i.id.includes("_umlMethods")&&t.shape.classShape.methods.length>0&&(s=new dm(t,"",u),t.shape.classShape.methods.push(s))),"Interface"===t.shape.classifier&&(i.id.includes("_umlProperty")&&t.shape.interfaceShape.attributes.length>0?(r=new of(t,"",u),t.shape.classShape.attributes.push(r)):i.id.includes("_umlMethods")&&t.shape.interfaceShape.methods.length>0&&(s=new dm(t,"",u),t.shape.interfaceShape.methods.push(s))),"Enumeration"===t.shape.classifier&&i.id.includes("_umlMember")&&t.shape.enumerationShape.members.length>0){var p=new db(t,"",u);t.shape.enumerationShape.members.push(p)}t.wrapper.children.indexOf(c.wrapper),this.diagram.enableServerDataBinding(!0),this.diagram.add(c),this.diagram.updateConnectorEdges(t),this.diagram.clearSelection(),this.diagram.select([this.diagram.nameTable[c.id]]),this.diagram.endGroupAction(),this.diagram.startTextEdit()}}},n}(),Zoe=function(){function n(){}return n.prototype.findObjectsUnderMouse=function(t,e,i,r,s){var o=[];r&&r instanceof si&&r.nodes.length+r.connectors.length===1&&(r=r.nodes[0]||r.connectors[0]).children&&0===r.children.length&&(i.actualObject=r);for(var a,l,h,c,f,d=r&&r instanceof de&&(r.constraints&qe.ConnectToNearByNode||r.constraints&qe.ConnectToNearByPort)&&r.connectionPadding||0,p={},g=0,v=e.spatialSearch.findObjects(new Ne(t.x-50-d,t.y-50-d,100+d,100+d));g-1&&o.splice(T,1),"UmlClassifier"===y.shape.type&&y.container&&"Stack"===y.container.type&&(T=o.indexOf(e.nameTable[e.nameTable[y.id].wrapper.children[0].id]))>-1&&o.splice(T,1)}for(var P=0;Ps.zIndex&&(t[parseInt(r.toString(),10)]=l),r>0&&i&&a&&(a.isLane||a.isPhase||a.isHeader)&&t[parseInt(r.toString(),10)].zIndex=2)for(var d=t.length-1;d>=0;d--)if(t[parseInt(d.toString(),10)].parentId){var u=am(t[parseInt(d.toString(),10)],e,""),p=am(t[d-1],e,""),g=e.nameTable[""+p];g&&u!==p&&e.nameTable[""+u].zIndex=0;f--){d=tf(e[parseInt(f.toString(),10)],!1),c=tf(e[parseInt(f.toString(),10)],!0);var g=t[""+l].tool,v=this.findTargetElement(e[parseInt(f.toString(),10)].wrapper,o,t,void 0);if("Draw"===i&&v&&(e[parseInt(f.toString(),10)]instanceof te||e[parseInt(f.toString(),10)]instanceof de)&&!lb(e[parseInt(f.toString(),10)],v)&&(g&&"ConnectorSourceEnd"===g[""+h]&&!kh(e[parseInt(f.toString(),10)])||g&&"ConnectorTargetEnd"===g[""+h]&&!da(e[parseInt(f.toString(),10)])))return u;if(e[parseInt(f.toString(),10)]instanceof te||e[parseInt(f.toString(),10)]instanceof de&&(kh(e[parseInt(f.toString(),10)])||Ad(d)||da(e[parseInt(f.toString(),10)])||Oh(c)||"PortDraw"===i&&g instanceof Pd&&"ConnectorTargetEnd"===g[""+h]&&(da(e[parseInt(f.toString(),10)])||Oh(c))))return u=e[parseInt(f.toString(),10)],p&&(u=this.isTarget(u,t,i)),s.actualObject=u,u}else if("ConnectorTargetEnd"===i&&a){for(f=e.length-1;f>=0;f--)if(c=tf(e[parseInt(f.toString(),10)],!0),(e[parseInt(f.toString(),10)]instanceof te||e[parseInt(f.toString(),10)]instanceof de)&&(da(e[parseInt(f.toString(),10)])||Oh(c)))return u=e[parseInt(f.toString(),10)],u=this.isTarget(u,t,i),s.actualObject=u,u}else{if(a&&("Drag"===i||t[""+l].tool instanceof ua)){var y=0;for(f=0;f=S.zIndex?u:S,y=Math.max(y,S.zIndex)):y=(u=S).zIndex)}return u&&"Bpmn"===u.shape.type&&(t.selectedItems.nodes.length>0&&"Bpmn"===t.selectedItems.nodes[0].shape.type||(u=null)),u&&(s.actualObject=u),u}if("Select"!==i&&"Pan"!==i||!t[""+l].tool)if("Pan"===i||"LayoutAnimation"===i){for(f=e.length-1;f>=0;f--)if((e[parseInt(f.toString(),10)]instanceof te||e[parseInt(f.toString(),10)]instanceof de)&&(v=this.findTargetElement(e[parseInt(f.toString(),10)].wrapper,o,t,void 0),"Pan"===i||v&&(v.id.match("_icon_content_shape$")||v.id.match("_icon_content_rect$"))))return e[parseInt(f.toString(),10)]}else u=e[e.length-1],s&&u&&(s.actualObject=u);else{for(f=e.length-1;f>=0;f--)if(e[parseInt(f.toString(),10)]instanceof de){var b=e[f-1];if(e[f-1]instanceof te&&b.ports){if((v=this.findTargetElement(b.wrapper,o,t,void 0))&&(v.id.match("_icon_content_shape$")||v.id.match("_icon_content_rect$")))return b;for(var M=0;M=0;s--){var o=t.children[parseInt(s.toString(),10)];if(o&&o.outerBounds.containsPoint(e,r||0))if(o.visible){if(o instanceof Cs){var a=this.findTargetElement(o,e,i);if(a)return a}var l="Clip"===o.style.textOverflow||"Ellipsis"===o.style.textOverflow;if(o.bounds.containsPoint(e,r||0)&&!l)return o;if(t.bounds.containsPoint(e,r||0)&&l)return o}else if(o instanceof Ke&&t&&t.id){var h=void 0;if(t.id.includes("group_container")){var c=t.id.slice(0,-15);h=i.getObject(c)}else h=i.getObject(t.id);if(ob(h,o.id))return o}}return t.bounds.containsPoint(e,r)&&"none"!==t.style.fill?t:null},n}(),Joe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),lf=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},n_=function(n){function t(e,i,r,s){var o=n.call(this,e,i,r,s)||this;return o.objectZIndex=-1,o.zIndexTable={},o.objects=[],o}return Joe(t,n),lf([I("")],t.prototype,"id",void 0),lf([I(!0)],t.prototype,"visible",void 0),lf([I(!1)],t.prototype,"lock",void 0),lf([I()],t.prototype,"objects",void 0),lf([I()],t.prototype,"addInfo",void 0),lf([I(-1)],t.prototype,"zIndex",void 0),t}(Ee),DT=function(n,t,e,i){return new(e||(e=Promise))(function(r,s){function o(h){try{l(i.next(h))}catch(c){s(c)}}function a(h){try{l(i.throw(h))}catch(c){s(c)}}function l(h){h.done?r(h.value):new e(function(c){c(h.value)}).then(o,a)}l((i=i.apply(n,t||[])).next())})},xT=function(n,t){var i,r,s,o,e={label:0,sent:function(){if(1&s[0])throw s[1];return s[1]},trys:[],ops:[]};return o={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function a(h){return function(c){return function l(h){if(i)throw new TypeError("Generator is already executing.");for(;e;)try{if(i=1,r&&(s=2&h[0]?r.return:h[0]?r.throw||((s=r.return)&&s.call(r),0):r.next)&&!(s=s.call(r,h[1])).done)return s;switch(r=0,s&&(h=[2&h[0],s.value]),h[0]){case 0:case 1:s=h;break;case 4:return e.label++,{value:h[1],done:!1};case 5:e.label++,r=h[1],h=[0];continue;case 7:h=e.ops.pop(),e.trys.pop();continue;default:if(!(s=(s=e.trys).length>0&&s[s.length-1])&&(6===h[0]||2===h[0])){e=0;continue}if(3===h[0]&&(!s||h[1]>s[0]&&h[1]1)for(var i=0;i-1)return e[parseInt(i.toString(),10)];return this.diagram.activeLayer},n.prototype.getLayer=function(t){for(var e=this.diagram.layers,i=0;i=0;o--)this.diagram.unSelect(this.diagram.nameTable[s[parseInt(o.toString(),10)]]),this.diagram.remove(this.diagram.nameTable[s[parseInt(o.toString(),10)]]),"default_layer"!==i.id&&this.diagram.activeLayer.id===t&&(this.diagram.activeLayer=this.diagram.layers[this.diagram.layers.length-1]);delete this.diagram.layerZIndexTable[i.zIndex],this.diagram.layers.splice(r,1),"SVG"!==this.diagram.mode&&this.diagram.refreshDiagramLayer()}},n.prototype.moveObjects=function(t,e){this.diagram.startGroupAction();for(var i={},r=[],s=0;s-1){if(r=[],(h=this.diagram.nameTable[""+s]).children)for(var f=0,g=h.children;f0){for(var y=void 0,S=0,b=r;S0)for(var r=0;r0)for(r=0;r0){t=t.concat(this.diagram.selectedItems.connectors);for(var i=0;i0)for(t=t.concat(this.diagram.selectedItems.nodes),i=0;i0){for(var i=0,r=t.shape.activity.subProcess.processes;i0&&this.copyProcesses(this.processTable[""+s])}this.clipboardData.processTable=this.processTable}},n.prototype.group=function(){this.oldSelectedObjects=sm(this.diagram);var e=this.diagram.isProtectedOnChange;this.diagram.protectPropertyChange(!0),this.diagram.diagramActions=this.diagram.diagramActions|ee.Group;var r={};r.id="group"+Qe(),(r=new te(this.diagram,"nodes",r,!0)).children=[];for(var s=this.diagram.selectedItems.nodes.concat(this.diagram.selectedItems.connectors).sort(function(h,c){return h.zIndex-c.zIndex}),o=0;o0){var a=this.diagram.add(r);a&&this.select(a),this.addHistoryEntry({type:"Group",undoObject:r,redoObject:r,category:"Internal"}),this.diagram.diagramActions=this.diagram.diagramActions&~ee.Group,this.diagram.protectPropertyChange(e)}},n.prototype.unGroup=function(t){var i=this.diagram.isProtectedOnChange;this.diagram.protectPropertyChange(!0),this.diagram.diagramActions=this.diagram.diagramActions|ee.Group;var r=[];t?r.push(t):r=this.diagram.selectedItems.nodes,this.diagram.startGroupAction();for(var s=0;s0&&this.diagram.removePorts(o,o.ports),o.annotations&&o.annotations.length>0&&!ce()&&this.diagram.removeLabels(o,o.annotations);for(var c=this.diagram.nameTable[o.parentId],d=o.children.length-1;d>=0;d--)this.diagram.nameTable[o.children[parseInt(d.toString(),10)]].parentId="",this.diagram.deleteChild(this.diagram.nameTable[o.children[parseInt(d.toString(),10)]],o),o.parentId&&o.children[parseInt(d.toString(),10)]&&this.diagram.addChild(c,o.children[parseInt(d.toString(),10)]);this.resetDependentConnectors(o.inEdges,!0),this.resetDependentConnectors(o.outEdges,!1),this.diagram.diagramActions&ee.UndoRedo||this.addHistoryEntry({type:"UnGroup",undoObject:a,redoObject:a,category:"Internal"}),o.parentId&&this.diagram.deleteChild(o,c)}this.diagram.removeNode(o,l),this.clearSelection()}this.diagram.endGroupAction(),this.diagram.diagramActions=this.diagram.diagramActions&~ee.Group,this.diagram.protectPropertyChange(i)},n.prototype.resetDependentConnectors=function(t,e){for(var i=0;i0&&(g=!1)}if(g){var y=this.cloneConnector(p,i);c.push(y),o[h.id]=y.id}}else{var S=this.cloneNode(h,i);if(c.push(S),S){o[h.id]=S.id;var b=h.inEdges;if(b)for(var M=0,w=b;M0)for(var u=0;u0)for(r=t.segments,s=0;s0&&this.diagram.drawingObject&&"Bezier"===this.diagram.drawingObject.type&&(t.segments=[]);var e=this.diagram.add(t);"SVG"!==this.diagram.mode&&this.diagram.refreshDiagramLayer(),this.selectObjects([e]),t&&!FI(this.diagram)&&(this.diagram.tool&=~Ci.DrawOnce,this.diagram.currentDrawingObject=void 0)},n.prototype.enableServerDataBinding=function(t){this.diagram.enableServerDataBinding(t)},n.prototype.addText=function(t,e){var i=this.diagram.findElementUnderMouse(t,e,this.diagram);this.diagram.startTextEdit(t,i instanceof ni?i.id.split("_")[1]:void 0)},n.prototype.isUserHandle=function(t){var e=this.diagram.selectedItems;if(e.wrapper&&qr(e.constraints,"UserHandle"))for(var i=0,r=e.userHandles;i0&&t[0]&&t[0].isLane)for(s=this.diagram.getObject(t[0].parentId),t[0].shape.header=[],a=0;a1||e&&1===t.length)){if(1!==t.length)return[2];this.clearSelection()}if(!(u||d||1!==t.length||e&&Xa(this.diagram)))return this.clearSelection(),[2]}if(!r.cancel){for(p=0;p0||e)&&f.children&&!f.parentId)for(g=0;g0||e,!0)}else this.select(f,p>0||e,!0);void 0===i&&(i=c),r={oldValue:i||[],newValue:this.getSelectedObject(),cause:this.diagram.diagramActions,state:"Changed",type:"Addition",cancel:!1},this.diagram.renderSelector(e||t&&t.length>1),ce()||this.diagram.triggerEvent(Ce.selectionChange,r),this.diagram.enableServerDataBinding(!0)}return[2]})})},n.prototype.findParent=function(t){return t.parentId&&this.findParent(t=this.diagram.nameTable[t.parentId]),t},n.prototype.selectProcesses=function(t){if(this.hasProcesses(t))for(var e=t.shape.activity.subProcess.processes,i=0;i0)},n.prototype.select=function(t,e,i){var r=this.getObjectLayer(t.id);if(Td(t)&&!(t instanceof si)&&!_r(this.diagram,t)&&r&&!r.lock&&r.visible&&t.wrapper.visible){(e=!!Xa(this.diagram)&&e)||this.clearSelection(),this.diagram.enableServerDataBinding(!1);var s=this.diagram.selectedItems;if(t instanceof te?s.nodes.push(t.isHeader?this.diagram.nameTable[t.parentId]:t):s.connectors.push(t),s.selectedObjects.push(t),e)s.wrapper.rotateAngle=s.rotateAngle=0,s.wrapper.children.push(t.wrapper);else if(s.init(this.diagram),1===s.nodes.length&&0===s.connectors.length){var l=Yx(this.diagram,s);l&&(s.wrapper.children[0]=l),s.rotateAngle=s.nodes[0].rotateAngle,s.wrapper.rotateAngle=s.nodes[0].rotateAngle,s.wrapper.pivot=s.nodes[0].pivot}i||this.diagram.renderSelector(e),this.diagram.enableServerDataBinding(!0)}},n.prototype.labelSelect=function(t,e){this.oldSelectedObjects=sm(this.diagram);var i=this.diagram.selectedItems,r=this.diagram.allowServerDataBinding;this.diagram.allowServerDataBinding=!1,i.nodes=i.connectors=[],this.diagram.allowServerDataBinding=r,t instanceof te?i.nodes[0]=t:i.connectors[0]=t,i.annotation=this.findTarget(e,t),i.init(this.diagram),this.diagram.renderSelector(!1)},n.prototype.unSelect=function(t){var e=this.diagram.selectedItems.nodes.concat(this.diagram.selectedItems.connectors),i=e.filter(function(a){return a.id!==t.id}),r={oldValue:e,newValue:i,cause:this.diagram.diagramActions,state:"Changing",type:"Removal",cancel:!1};if(this.diagram.currentSymbol||ce()||this.diagram.triggerEvent(Ce.selectionChange,r),_r(this.diagram,t)){var s=this.diagram.selectedItems,o=void 0;t instanceof te?(o=s.nodes.indexOf(t,0),s.nodes.splice(o,1)):(o=s.connectors.indexOf(t,0),s.connectors.splice(o,1)),o=s.selectedObjects.indexOf(t,0),s.selectedObjects.splice(o,1),(r={oldValue:e,newValue:i,cause:this.diagram.diagramActions,state:"Changed",type:"Removal",cancel:(r={oldValue:e,newValue:i,cause:this.diagram.diagramActions,state:"Changed",type:"Removal",cancel:!1}).cancel}).cancel||(o=s.wrapper.children.indexOf(t.wrapper,0),s.wrapper.children.splice(o,1),this.diagram.updateSelector(),this.diagram.currentSymbol||this.diagram.triggerEvent(Ce.selectionChange,r))}},n.prototype.moveSvgNode=function(t,e){var i=xt(e+"_groupElement",this.diagram.element.id),r=xt(t+"_groupElement",this.diagram.element.id);i.parentNode.insertBefore(r,i)},n.prototype.moveAfterSvgNode=function(t,e){var i=xt(e+"_groupElement",this.diagram.element.id),r=xt(t+"_groupElement",this.diagram.element.id);i.insertAdjacentElement("afterend",r)},n.prototype.sendLayerBackward=function(t){var e=this.getLayer(t);if(e&&0!==e.zIndex){var i=e.zIndex;if("SVG"===this.diagram.mode){var r=e.objects,s=this.getLayer(this.diagram.layerZIndexTable[i-1]).objects[0];if(s)for(var o=0,a=r;od&&"SwimLane"!==f.shape.type){var S=$(f);f.zIndex=d-((-1!==i.indexOf(f)?i.indexOf(f):0)+1),f.children&&(d=this.findLowestZIndex(f,c)||d),this.triggerOrderCommand(S,f,f),f.children&&this.updateGroupZindex(f,"SendToBack",d)}else"SwimLane"===f.shape.type&&(y=this.swapZIndexObjects(a,h,r,g));if("SVG"===this.diagram.mode){for(var M="SwimLane"!==this.diagram.nameTable[""+r].shape.type?d:y,w=h[parseInt(M.toString(),10)];!w&&Md)&&(d=p.zIndex)}for(var f=JSON.parse(JSON.stringify(l)),v=Number(Object.keys(l).sort(function(wo,Hl){return Number(wo)-Number(Hl)}).reverse()[0]),y=this.diagram.nameTable[""+e].zIndex,S=[],M=0;M<=v;M++)S.push(l[parseInt(M.toString(),10)]);if("SwimLane"===this.diagram.nameTable[""+e].shape.type)for(var C=v;C>=y;C--)if(l[parseInt(C.toString(),10)]&&this.diagram.nameTable[l[parseInt(C.toString(),10)]].parentId!==e){v=C;break}var D=this.diagram.nameTable[""+e];if(D.zIndexx&&(x=L.zIndex)}}else x=d;D.zIndex=x+((-1!==r.indexOf(D)?r.indexOf(D):0)+1),this.triggerOrderCommand(A,D,D)}else if("SwimLane"===D.shape.type){for(var O=0,N=-1,T=0,P=0,_=JSON.parse(JSON.stringify(l)),B=0;B<=y;B++)if(l[parseInt(B.toString(),10)]&&this.diagram.nameTable[l[parseInt(B.toString(),10)]].parentId===e&&-1===N){N=B,T=B;break}for(var j=0;j<=v;j++)f[parseInt(j.toString(),10)]&&f[parseInt(j.toString(),10)]!==e&&this.diagram.nameTable[f[parseInt(j.toString(),10)]].parentId!==e&&this.diagram.nameTable[f[parseInt(j.toString(),10)]].zIndex>=this.diagram.nameTable[""+e].zIndex&&O++;for(var ue=N,pe=0;pe<=O;pe++){for(;!l[parseInt(ue.toString(),10)];)ue++;P=this.diagram.nameTable[l[parseInt(ue.toString(),10)]].zIndex,ue++}for(var Me=P;Me<=v;Me++){for(;!_[parseInt(N.toString(),10)];)N++;for(;!l[parseInt(Me.toString(),10)];)Me++;l[parseInt(Me.toString(),10)]=_[parseInt(N.toString(),10)],this.diagram.nameTable[l[parseInt(Me.toString(),10)]].zIndex=Me,N++}l[parseInt(v.toString(),10)]=this.diagram.nameTable[""+e].id,this.diagram.nameTable[""+e].zIndex=v,ue=y+1;for(var De=T,xe=0;xe0&&("Native"===hr[0].shape.type||"HTML"===hr[0].shape.type)){for(Mi.parentNode.removeChild(Mi),De=0;De0?r[0]:null},n.prototype.findLowestZIndex=function(t,e){var r=this.diagram.nodes.filter(function(s){return-1!==e.indexOf(s.id)}).filter(function(s){return""===s.parentId&&s.id!==t.id}).map(function(s){return s.zIndex});return r.sort(function(s,o){return s-o}),r.length>0?r[0]:null},n.prototype.triggerOrderCommand=function(t,e,i){var s={zIndex:$(t).zIndex},o={zIndex:e.zIndex},a={element:i,cause:this.diagram.diagramActions,diagramAction:this.diagram.getDiagramAction(this.diagram.diagramActions),oldValue:s,newValue:o};this.diagram.triggerEvent(Ce.propertyChange,a)},n.prototype.checkGroupNode=function(t,e,i){return i[""+e].parentId===i[""+t].parentId},n.prototype.sortByZIndex=function(t,e,i){if("BringForward"===i){var r=e||"zIndex";t=t.sort(function(o,a){return a[""+r]-o[""+r]})}else{var s=e||"zIndex";t=t.sort(function(o,a){return o[""+s]-a[""+s]})}return t},n.prototype.orderCommands=function(t,e,i){var r=this,s=e.nodes;if(s=s.concat(e.connectors),t)if("SendBackward"===i)for(var o=0;oa}),S=v.filter(function(D){return D0?Math.max.apply(Math,S):a,M=y.length>0?Math.min.apply(Math,y):a;if(a!==M){var w=c.zIndexTable[parseInt(M.toString(),10)],C=c.zIndexTable[parseInt(a.toString(),10)];this.moveSvgNode(C,w)}else"SendToBack"===i&&(w=c.zIndexTable[parseInt(a.toString(),10)],C=c.zIndexTable[parseInt(b.toString(),10)],this.moveAfterSvgNode(w,C))}}else this.diagram.refreshCanvasLayers()}},n.prototype.sendForward=function(t){var e=this;if(this.diagram.protectPropertyChange(!0),Xa(this.diagram)||t){$(t||(this.diagram.selectedItems.nodes.length?this.diagram.selectedItems.nodes[0]:this.diagram.selectedItems.connectors[0]));var s=t&&t.id,o=this.diagram.layers.indexOf(this.getObjectLayer(s=s||(this.diagram.selectedItems.nodes.length?this.diagram.selectedItems.nodes[0].id:this.diagram.selectedItems.connectors[0].id))),a=$(this.diagram.nameTable),h=(parseInt(o.toString(),10),this.diagram.nameTable[""+s]),c=[],d=this.diagram.spatialSearch.findObjects(h.wrapper.bounds);d.length>2&&(d=this.sortByZIndex(d,void 0,"BringForward"));for(var u=0,p=d;u=0;f--)this.diagram.nameTable[c[parseInt(f.toString(),10)].id].parentId===s&&c.splice(f,1);if(c.length>0){var y=this.diagram.nameTable[c[c.length-1].id];if(y.parentId){var b=am(y,this.diagram,""),M=this.diagram.nameTable[""+b];M.id!==s&&(c[0]=M)}var w={};for(f=0;f0&&(Object.values(O).forEach(function(ue){ue>=T&&N.push(ue)}),0!==N.length&&this.updateZIndexBySendForward(h,N,o))}var P=[];if(Object.keys(this.changedNodeZIndexes).forEach(function(ue){if((a[""+ue]?a[""+ue].zIndex:null)!==e.changedNodeZIndexes[""+ue]){var De=$(a[""+ue]);P.push(De)}}),this.updateLayerZindexTable(o),L.nodes.splice(0,L.nodes.length),P.forEach(function(ue){var pe=$(ue);L.nodes.push(pe)}),"SVG"===this.diagram.mode){var _=c[c.length-1].id,B=c[c.length-1];B&&!("HTML"===B.shape.type||"Native"===B.shape.type)&&this.moveAfterSvgNode(s,_),this.updateNativeNodeIndex(_,s)}else this.diagram.refreshCanvasLayers();var j=[];Object.keys(this.changedNodeZIndexes).forEach(function(ue){if((a[""+ue]?a[""+ue].zIndex:null)!==e.changedNodeZIndexes[""+ue]){var De=$(e.diagram.nameTable[""+ue]);j.push(De)}});var Q=$(this.diagram.selectedItems);Q.nodes.splice(0,Q.nodes.length),j.forEach(function(ue){var pe=$(ue);Q.nodes.push(pe)}),this.diagram.diagramActions&ee.UndoRedo||this.addHistoryEntry({type:"SendForward",category:"Internal",undoObject:L,redoObject:Q}),this.diagram.endGroupAction()}}this.diagram.protectPropertyChange(!1)},n.prototype.updateZIndexBySendForward=function(t,e,i){var r=$(t);t.zIndex=Math.min.apply(Math,e);var a,s=Math.min.apply(Math,e),o=Math.min.apply(Math,e),l=this.diagram.layers[parseInt(i.toString(),10)].objects,h=this.diagram.nodes.filter(function(S){return-1!==l.indexOf(S.id)});t.children&&this.updateGroupZindex(t,"BringForward",t.zIndex);var c=h.filter(function(S){return S.zIndex===Math.min.apply(Math,e)&&S.id!==t.id});if(c&&c.length>0&&c[0].children){for(var d=Math.min.apply(Math,e),u=0;uo&&g!==t&&g.parentId!==t.id&&c&&c.length>0&&g.parentId!==c[0].id){var v=$(g);g.zIndex=a+1,a++,this.triggerOrderCommand(v,g,g)}var y=g.zIndex;this.changedNodeZIndexes[g.id]=(this.changedNodeZIndexes.hasOwnProperty(g.id),y)}},n.prototype.arrangeZIndexForLowerNodes=function(t,e,i){var r=i.filter(function(o){return o.zIndex<=t&&o.parentId!==e.id});r.sort(function(o,a){return a.zIndex-o.zIndex});for(var s=0;se&&(e=r.zIndex)}return e},n.prototype.sendBackward=function(t){var e=this;if(this.diagram.protectPropertyChange(!0),Xa(this.diagram)||t){$(t||(this.diagram.selectedItems.nodes.length?this.diagram.selectedItems.nodes[0]:this.diagram.selectedItems.connectors[0]));var s=t&&t.id,o=this.diagram.layers.indexOf(this.getObjectLayer(s=s||(this.diagram.selectedItems.nodes.length?this.diagram.selectedItems.nodes[0].id:this.diagram.selectedItems.connectors[0].id))),a=$(this.diagram.nameTable),h=(parseInt(o.toString(),10),this.diagram.nameTable[""+s]),c=[],d=this.diagram.spatialSearch.findObjects(h.wrapper.bounds);d.length>2&&(d=this.sortByZIndex(d));for(var u=0,p=d;uNumber(f.zIndex)&&""===f.parentId&&h.wrapper.bounds.intersects(f.wrapper.bounds)&&c.push(f);for(var f=c.length-1;f>=0;f--)(v=this.diagram.nameTable[c[parseInt(f.toString(),10)].id]).parentId===s&&c.splice(f,1);if(c.length>0){var v;if((v=this.diagram.nameTable[c[c.length-1].id]).parentId){var S=am(v,this.diagram,""),b=this.diagram.nameTable[""+S];s!==b.id&&(c[c.length-1]=b)}var M={};for(f=0;f0&&(Object.values(L).forEach(function(pe){pe<=N&&O.push(pe)}),0!==O.length&&this.updateZIndexBySendBackward(h,O,o))}var T=[];if(Object.keys(this.changedNodeZIndexes).forEach(function(pe){if((a[""+pe]?a[""+pe].zIndex:null)!==e.changedNodeZIndexes[""+pe]){var xe=$(a[""+pe]);T.push(xe)}}),this.updateLayerZindexTable(o),R.nodes.splice(0,R.nodes.length),T.forEach(function(pe){var Me=$(pe);R.nodes.push(Me)}),"SVG"===this.diagram.mode){var P=c[c.length-1].id,_=c[c.length-1];_&&"HTML"!==_.shape.type&&"Native"!==_.shape.type&&this.moveSvgNode(s,P);var B=this.diagram.nameTable[""+P];B.children&&B.children.length>0?this.updateNativeNodeIndex(s):this.updateNativeNodeIndex(s,P)}else this.diagram.refreshCanvasLayers();var j=[];Object.keys(this.changedNodeZIndexes).forEach(function(pe){if((a[""+pe]?a[""+pe].zIndex:null)!==e.changedNodeZIndexes[""+pe]){var xe=$(e.diagram.nameTable[""+pe]);j.push(xe)}});var Q=$(this.diagram.selectedItems);Q.nodes.splice(0,Q.nodes.length),j.forEach(function(pe){var Me=$(pe);Q.nodes.push(Me)}),this.diagram.diagramActions&ee.UndoRedo||this.addHistoryEntry({type:"SendBackward",category:"Internal",undoObject:R,redoObject:Q}),this.diagram.endGroupAction()}}this.diagram.protectPropertyChange(!1)},n.prototype.updateZIndexBySendBackward=function(t,e,i){var r=$(t);t.zIndex=Math.max.apply(Math,e);var p,s=t.zIndex,o=Math.max.apply(Math,e),a=this.diagram.layers[parseInt(i.toString(),10)].objects,l=this.diagram.nodes.filter(function(S){return-1!==a.indexOf(S.id)}),h=l.filter(function(S){return S.zIndex===Math.max.apply(Math,e)&&S.id!==t.id});if(h&&h.length>0&&h[0].children)for(var c=Math.max.apply(Math,e),d=0;d0&&g.parentId!==h[0].id){var v=$(g);g.zIndex=p-1,p--,this.triggerOrderCommand(v,g,g)}var y=g.zIndex;this.changedNodeZIndexes[""+g.id]=(this.changedNodeZIndexes.hasOwnProperty(g.id),y)}},n.prototype.findLowestChildZIndex=function(t){for(var e=t.zIndex,i=0;i0),this.selectObjects([t],!0))},n.prototype.clearSelection=function(t,e){return DT(this,void 0,void 0,function(){var i,r,s,o;return xT(this,function(a){return i=this.diagram.allowServerDataBinding,this.diagram.enableServerDataBinding(!1),Xa(this.diagram)&&(r=this.diagram.selectedItems,s=this.getSelectedObject(),this.diagram.currentSymbol&&(this.diagram.previousSelectedObject=s),o={oldValue:s,newValue:[],cause:this.diagram.diagramActions,state:"Changing",type:"Removal",cancel:!1},t&&(ce()||this.diagram.triggerEvent(Ce.selectionChange,o)),o.cancel||(r.offsetX=0,r.offsetY=0,r.width=0,r.height=0,r.rotateAngle=0,r.nodes=[],r.connectors=[],r.wrapper=null,r.annotation=void 0,r.selectedObjects=[],this.diagram.clearSelectorLayer(),t&&(o={oldValue:s,newValue:[],cause:this.diagram.diagramActions,state:"Changed",type:"Removal",cancel:!1},ce()||this.diagram.triggerEvent(Ce.selectionChange,o))),this.diagram.enableServerDataBinding(i)),[2]})})},n.prototype.clearSelectedItems=function(){this.clearSelection((this.diagram.selectedItems.nodes?this.diagram.selectedItems.nodes.length:0)+(this.diagram.selectedItems.connectors?this.diagram.selectedItems.connectors.length:0)>0)},n.prototype.removeStackHighlighter=function(){var t=zl(this.diagram.element.id),e=t.getElementById(t.id+"_stack_highlighter");e&&e.parentNode.removeChild(e)},n.prototype.renderStackHighlighter=function(t,e){var r,s,o,i=this.diagram.selectedItems.nodes[0];if(!e){var a=this.diagram.findObjectsUnderMouse(t.position);if((e=this.diagram.findObjectUnderMouse(a,"Drag",!0))&&!(e.isLane||e.isPhase||e.isHeader))for(var l=0;l0)for(var a=0;a1)if(i){var h=l.segments[0],c=l.segments[1],u=Lc(TI(t.wrapper,t.wrapper.corners,t.wrapper.bounds),h.direction),g=Nl({corners:void 0,point:u=Nh(l,0,u,{x:l.sourceWrapper.offsetX,y:l.sourceWrapper.offsetY},!1),margin:void 0,direction:h.direction},{corners:void 0,point:c.points[1],margin:void 0,direction:void 0});h.length=z.distancePoints(g[0],g[1]),c.direction&&c.length&&(c.length=z.distancePoints(g[1],g[2]))}else if(o){switch(l.segments[0].direction){case"Bottom":r=t.wrapper.bounds.bottomCenter.x-e.bottomCenter.x,s=t.wrapper.bounds.bottomCenter.y-e.bottomCenter.y;break;case"Top":r=t.wrapper.bounds.topCenter.x-e.topCenter.x,s=t.wrapper.bounds.topCenter.y-e.topCenter.y;break;case"Left":r=t.wrapper.bounds.middleLeft.x-e.middleLeft.x,s=t.wrapper.bounds.middleLeft.y-e.middleLeft.y;break;case"Right":r=t.wrapper.bounds.middleRight.x-e.middleRight.x,s=t.wrapper.bounds.middleRight.y-e.middleRight.y}this.dragSourceEnd(l,r,s,!0,null,"ConnectorSourceEnd",void 0,void 0,void 0,!(t.parentId&&this.diagram.diagramActions&ee.isGroupDragging))}}},n.prototype.updateEndPoint=function(t,e){var r={sourcePoint:t.sourcePoint,targetPoint:t.targetPoint};t.sourceID&&(r.sourceID=t.sourceID),t.targetID&&(r.targetID=t.targetID),t.sourcePortID&&(r.sourcePortID=t.sourcePortID),t.targetPortID&&(r.targetPortID=t.targetPortID),t.segments&&(r.segments=t.segments),this.diagram.connectorPropertyChange(t,e||{},r),this.diagram.updateSelector()},n.prototype.dragSourceEnd=function(t,e,i,r,s,o,a,l,h,c,d){var u=this.diagram.nameTable[t.id],p={},f=this.checkBoundaryConstraints(e,i,u.wrapper.bounds);if(kI(u)&&f&&"BezierSourceThumb"!==o&&Yv(this.diagram)&&(p=$(p={sourcePoint:u.sourcePoint}),u.sourcePoint.x+=e,u.sourcePoint.y+=i,"ConnectorSourceEnd"===o&&"Orthogonal"===u.type&&this.changeSegmentLength(u,l,h,c),"Bpmn"===u.shape.type&&"Default"===u.shape.sequence&&"Sequence"===u.shape.flow&&this.updatePathElementOffset(u)),"Bezier"===u.type)if(p={sourcePoint:u.sourcePoint},d)this.translateBezierPoints(t,""===o?"ConnectorSourceEnd":o,e,i,d,s,!a);else for(var g=0;g2){var d=z.direction((c=t.segments[2]).points[0],c.points[1]);o.direction===ls(d)?("Right"===o.direction?c.points[0].x=o.points[o.points.length-1].x=l.wrapper.corners.middleRight.x+20:"Left"===o.direction?c.points[0].x=o.points[o.points.length-1].x=l.wrapper.corners.middleLeft.x-20:c.points[0].y=o.points[o.points.length-1].y="Top"===o.direction?l.wrapper.corners.topCenter.y-20:l.wrapper.corners.bottomCenter.y+20,c.direction&&c.length&&(c.length=z.distancePoints(c.points[0],c.points[c.points.length-1])),o.length=z.distancePoints(o.points[0],o.points[o.points.length-1])):o.direction===d&&c.direction&&c.length?("Top"===o.direction||"Bottom"===o.direction?(c.points[0]=o.points[0],c.points[c.points.length-1].x=c.points[0].x):(c.points[0]=o.points[0],c.points[c.points.length-1].y=c.points[0].y),c.length=z.distancePoints(c.points[0],c.points[c.points.length-1]),t.segments.splice(0,2)):o.length=20}else o.length=20;else if(o.length<1)if(""!==t.sourceID){var c;"Right"===a.direction?a.points[a.points.length-1].y=(h=l.wrapper.corners.middleRight).y:"Left"===a.direction?a.points[a.points.length-1].y=(h=l.wrapper.corners.middleLeft).y:a.points[a.points.length-1].x="Top"===a.direction?(h=l.wrapper.corners.topCenter).x:(h=l.wrapper.corners.bottomCenter).x,a.length=z.distancePoints(h,a.points[a.points.length-1]),t.segments.length>2&&(c=t.segments[2]).direction&&c.length&&(c.length=z.distancePoints(a.points[a.points.length-1],c.points[c.points.length-1])),t.segments.splice(0,1)}else t.segments.splice(0,1)}else e&&!i&&t.sourceID!==e.id&&t.segments&&null!==t.segments[0].direction&&e&&e instanceof te&&s&&this.changeSourceEndToNode(t,e),e&&i&&t.sourcePortID!==i&&t.segments&&null!==t.segments[0].direction&&e&&e instanceof te&&s&&this.changeSourceEndToPort(t,e,i)},n.prototype.canConnect=function(t,e){return!(!da(e)||!kh(e))},n.prototype.changeSourceEndToPort=function(t,e,i){var r=this.diagram.getWrapper(e.wrapper,i),s={x:r.offsetX,y:r.offsetY},o=zo(s,En(e.wrapper),e.wrapper.bounds),a=t.segments[0],l=t.segments[1];if(a.direction!==o){var h=[],c={};if(a.direction===ls(o)){c={};var d=void 0;"Top"===o||"Bottom"===o?(d="Top"===o?{type:"Orthogonal",isTerminal:!0,direction:o,length:Math.abs(a.points[0].y-s.y)}:{type:"Orthogonal",isTerminal:!0,direction:o,length:Math.abs(s.y-a.points[0].y)},c=a.points[0].x>s.x?{type:"Orthogonal",isTerminal:!0,direction:"Right",length:a.points[0].x-s.x}:{type:"Orthogonal",isTerminal:!0,direction:"Left",length:s.x-a.points[0].x}):(d="Right"===o?{type:"Orthogonal",isTerminal:!0,direction:o,length:Math.abs(a.points[0].x-s.x)}:{type:"Orthogonal",isTerminal:!0,direction:o,length:Math.abs(s.x-a.points[0].x)},c=a.points[0].y>s.y?{type:"Orthogonal",direction:"Top",isTerminal:!0,length:a.points[0].y-s.y}:{type:"Orthogonal",direction:"Bottom",isTerminal:!0,length:s.y-a.points[0].y}),h.push(new bi(t,"segments",d,!0)),h.push(new bi(t,"segments",c,!0))}else h.push(new bi(t,"segments",c={type:"Orthogonal",direction:o,length:20,isTerminal:!0},!0));a.direction!==ls(o)&&("Top"===o||"Bottom"===o?(a.points[0].x=s.x,a.points[0].y=a.points[a.points.length-1].y="Top"===o?s.y-20:s.y+20):(a.points[0].y=s.y,a.points[0].x=a.points[a.points.length-1].x="Right"===o?s.x+20:s.x-20),a.length=z.distancePoints(a.points[0],a.points[a.points.length-1]),l.length=z.distancePoints(a.points[a.points.length-1],l.points[l.points.length-1])),t.segments=h.concat(t.segments)}else a.points[0]=s,"Top"===o||"Bottom"===o?a.points[a.points.length-1].x=s.x:a.points[a.points.length-1].y=s.y,a.length=z.distancePoints(a.points[0],a.points[a.points.length-1]),l.length=z.distancePoints(a.points[a.points.length-1],l.points[l.points.length-1])},n.prototype.removeTerminalSegment=function(t,e){for(var i=0;ii.width||"Left"===o.direction&&r.x>=o.points[0].x||"Right"===o.direction&&r.x<=o.points[0].x)o.points[0].y=o.points[o.points.length-1].y=r.y,o.points[0].x=r.x,o.length=z.distancePoints(o.points[0],o.points[o.points.length-1]),a.length=z.distancePoints(o.points[o.points.length-1],a.points[a.points.length-1]);else{var h=void 0;s="Bottom"===(h=a.direction?a.direction:z.direction(a.points[0],a.points[a.points.length-1]))?i.bottomCenter:i.topCenter,a.length&&a.direction&&(a.length="Top"===h?o.points[o.points.length-1].y-(s.y+20):s.y+20-o.points[o.points.length-1].y),o.length=o.points[o.points.length-1].x-s.x,o.direction=o.length>0?"Right":"Left",l.push(new bi(t,"segments",{type:"Orthogonal",direction:h,length:20},!0)),t.segments=l.concat(t.segments)}else r="Bottom"===o.direction?i.bottomCenter:i.topCenter,o.length>i.height||"Top"===o.direction&&r.y>=o.points[0].y||"Bottom"===o.direction&&r.y<=o.points[0].y?(o.points[0].x=o.points[o.points.length-1].x=r.x,o.points[0].y=r.y,o.length=z.distancePoints(o.points[0],o.points[o.points.length-1]),a.length=z.distancePoints(o.points[o.points.length-1],a.points[a.points.length-1])):(s="Left"===a.direction?i.middleLeft:i.middleRight,h=void 0,h=a.direction?a.direction:z.direction(a.points[0],a.points[a.points.length-1]),a.length&&a.direction&&(a.length="Left"===h?o.points[o.points.length-1].x-(s.x+20):s.x+20-o.points[o.points.length-1].x),o.length=o.points[o.points.length-1].y-s.y,o.direction=o.length>0?"Bottom":"Top",l.push(new bi(t,"segments",{type:"Orthogonal",direction:h,length:20},!0)),t.segments=l.concat(t.segments))},n.prototype.translateBezierPoints=function(t,e,i,r,s,o,a){var l=t.segments.indexOf(s),h=t.segments[parseInt(l.toString(),10)],c=l>0?t.segments[l-1]:null,d=null!==c?c.point:t.sourcePoint,u=l===t.segments.length-1?t.targetPoint:h.point;if(h)if("BezierSourceThumb"===e&&(h.vector1.angle||h.vector1.distance)){var p=h.vector1.distance,f=h.vector1.angle;h.vector1={distance:t.distance(d,o),angle:z.findAngle(d,o)},this.translateSubsequentSegment(t,s,!0,h.vector1.distance-p,h.vector1.angle-f)}else"BezierTargetThumb"===e&&(h.vector2.angle||h.vector2.distance)?(p=h.vector2.distance,f=h.vector2.angle,h.vector2={distance:t.distance(u,o),angle:z.findAngle(u,o)},this.translateSubsequentSegment(t,s,!1,h.vector2.distance-p,h.vector2.angle-f)):("ConnectorSourceEnd"===e&&!t.sourceID||"ConnectorTargetEnd"===e&&!t.targetID)&&a&&JI(h.vector1)&&JI(h.vector2)?(z.isEmptyPoint(h.point1)&&(h.bezierPoint1=KI(t.sourcePoint,t.targetPoint)),z.isEmptyPoint(h.point2)&&(h.bezierPoint2=KI(t.targetPoint,t.sourcePoint))):"BezierSourceThumb"===e||"ConnectorSourceEnd"===e&&!a&&JI(h.vector1)?(h.bezierPoint1.x+=i,h.bezierPoint1.y+=r,(!z.isEmptyPoint(h.point1)||a)&&(h.point1={x:h.bezierPoint1.x,y:h.bezierPoint1.y})):("BezierTargetThumb"===e||"ConnectorTargetEnd"===e&&!a&&JI(h.vector2))&&(h.bezierPoint2.x+=i,h.bezierPoint2.y+=r,(!z.isEmptyPoint(h.point2)||a)&&(h.point2={x:h.bezierPoint2.x,y:h.bezierPoint2.y}))},n.prototype.translateSubsequentSegment=function(t,e,i,r,s){var o=t.segments.indexOf(e);parseInt(o.toString(),10),t.bezierSettings.smoothness&wI.SymmetricAngle||(s=null),t.bezierSettings.smoothness&wI.SymmetricDistance||(r=null),(null!=r||null!=s)&&(i?0!==o&&this.updatePreviousBezierSegment(t,o,r,s):o!==t.segments.length-1&&this.updateNextBezierSegment(t,o,r,s))},n.prototype.updatePreviousBezierSegment=function(t,e,i,r){var s=t.segments[e-1],a=(s.vector2.angle+r)%360;a<0&&(a+=360),s.vector2={distance:s.vector2.distance+i,angle:a}},n.prototype.updateNextBezierSegment=function(t,e,i,r){var s=t.segments[e+1],a=(s.vector1.angle+r)%360;a<0&&(a+=360),s.vector1={distance:s.vector1.distance+i,angle:a}},n.prototype.dragTargetEnd=function(t,e,i,r,s,o,a,l){var c,h=this.diagram.nameTable[t.id],d=this.checkBoundaryConstraints(e,i,h.wrapper.bounds);if(PI(h)&&"BezierTargetThumb"!==o&&d&&Yv(this.diagram)){if(c=$(c={targetPoint:h.targetPoint}),h.targetPoint.x+=e,h.targetPoint.y+=i,"ConnectorTargetEnd"===o&&"Orthogonal"===h.type&&h.segments&&h.segments.length>0){var u=h.segments[h.segments.length-2];u&&2===h.segments[h.segments.length-1].points.length&&("Left"===u.direction||"Right"===u.direction?u.points[u.points.length-1].x=h.targetPoint.x:u.points[u.points.length-1].y=h.targetPoint.y,u.length=z.distancePoints(u.points[0],u.points[u.points.length-1]),u.direction=z.direction(u.points[0],u.points[u.points.length-1]))}"Bpmn"===h.shape.type&&"Default"===h.shape.sequence&&"Sequence"===h.shape.flow&&this.updatePathElementOffset(h)}if("Bezier"===h.type)if(c={targetPoint:h.targetPoint},l)this.translateBezierPoints(t,""===o?"ConnectorTargetEnd":o,e,i,l,s,!a);else for(var p=0;p0){if(void 0!==s&&o.segments[parseInt(s.toString(),10)])if("Bezier"===o.type){var a=o.segments[parseInt(s.toString(),10)],l=a.isInternalSegment;l&&null!==o.bezierSettings&&"FreeForm"!==o.bezierSettings.segmentEditOrientation?("Horizontal"===a.orientation?a.point.x+=e:a.point.y+=i,this.updateDirectionalBezierCurve(o)):(a.point.x+=e,a.point.y+=i),l&&(o.isBezierEditing=!0)}else o.segments[parseInt(s.toString(),10)].point.x+=e,o.segments[parseInt(s.toString(),10)].point.y+=i;else for(var h=0;h1){var a=e[1],l=e[2],h={x:.5*(a.x+l.x),y:.5*(a.y+l.y)},c=t.segments[0];c.vector1.angle=Gt(s,a),c.vector1.distance=.5*z.findLength(s,a),c.vector2.angle=Gt(h,a),c.vector2.distance=.5*z.findLength(h,a),c.point=h;var d=t.segments[1];if(d.vector1.angle=Gt(h,l),d.vector1.distance=.5*z.findLength(h,l),t.segments.length>2){var u=e[3],p={x:.5*(l.x+u.x),y:.5*(l.y+u.y)};d.vector2.angle=Gt(p,l),d.vector2.distance=.5*z.findLength(p,l),d.point=p;var f=t.segments[2];if(f.vector1.angle=Gt(p,u),f.vector1.distance=.5*z.findLength(p,u),t.segments.length>3){var g=e[4],v={x:.5*(u.x+g.x),y:.5*(u.y+g.y)};f.vector2.angle=Gt(v,u),f.vector2.distance=.5*z.findLength(v,u),f.point=v;var y=t.segments[3];y.vector1.angle=Gt(v,g),y.vector1.distance=.5*z.findLength(v,g),y.vector2.angle=Gt(o,g),y.vector2.distance=.5*z.findLength(o,g)}else f.vector2.angle=Gt(o,u),f.vector2.distance=.5*z.findLength(o,u)}else d.vector2.angle=Gt(o,l),d.vector2.distance=.5*z.findLength(o,l)}},n.prototype.rotateObjects=function(t,e,i,r,s){r=r||{};var o=Hi();qi(o,i,r.x,r.y);for(var l=0,h=e;l0){this.diagram.protectPropertyChange(!0);var o=t;o.segments=[],this.diagram.connectorPropertyChange(o,{},{segments:o.segments}),this.diagram.protectPropertyChange(!1)}}},n.prototype.updateInnerParentProperties=function(t){var r=this.diagram.isProtectedOnChange;this.diagram.protectPropertyChange(!0);for(var s=this.getAllDescendants(t,[],!1,!0),o=0;o0&&(p=this.diagram.bpmnModule.getChildrenBound(d,d.id,this.diagram),u=d.wrapper.bounds.containsRect(p)),h=d.wrapper.actualSize.width*t,c=d.wrapper.actualSize.height*e,void 0!==d.maxWidth&&0!==d.maxWidth&&(h=Math.min(d.maxWidth,h)),void 0!==d.minWidth&&0!==d.minWidth&&(h=Math.max(d.minWidth,h)),void 0!==d.maxHeight&&0!==d.maxHeight&&(c=Math.min(d.maxHeight,c)),void 0!==d.minHeight&&0!==d.minHeight&&(c=Math.max(d.minHeight,c)),u&&(h=Math.max(h,p.right-d.wrapper.bounds.x),c=Math.max(c,p.bottom-d.wrapper.bounds.y)),t=h/d.actualSize.width,e=c/d.actualSize.height}var f=Hi();o||(o=r);var g=o.wrapper;if(qi(f,-g.rotateAngle,i.x,i.y),Gp(f,t,e,i.x,i.y),qi(f,g.rotateAngle,i.x,i.y),r instanceof te){var d,v=Je(f,{x:(d=r).wrapper.offsetX,y:d.wrapper.offsetY}),y=d.wrapper.offsetX-d.wrapper.actualSize.width*d.pivot.x,S=d.wrapper.offsetY-d.wrapper.actualSize.height*d.pivot.y;if(h>0)if(d.processId){var b=this.diagram.nameTable[d.processId];(!b.maxWidth||d.margin.left+h0)if(d.processId){var M=this.diagram.nameTable[d.processId];(!M.maxHeight||d.margin.top+c0){if(e.dragLimit=e.dragLimit?e.dragLimit:{},e.dragLimit.top||e.dragLimit.bottom||e.dragLimit.left||e.dragLimit.right){var b={minDistance:null};S=this.getRelativeOffset(v,d,b);var M={minDistance:null};g=this.getRelativeOffset(v,y,M),S=null!=b&&M.minDistance0){if(S=y[y.length-1]){var b=void 0;for(b=0;b=e.x-t.dragLimit.left-r.width/2&&i.x<=e.x+t.dragLimit.right+r.width/2&&(s=!0),i.y>=e.y-t.dragLimit.top-r.height/2&&i.y<=e.y+t.dragLimit.bottom+r.height/2&&(o=!0),{x:s,y:o}},n.prototype.updateLabelMargin=function(t,e,i,r,s,o,a){if(i=i||{x:e.offset,y:0},e&&i&&i.x>0&&i.x<1){var l=z.getLengthFromListOfPoints(t.intermediatePoints),h=this.getPointAtLength(l*i.x,t.intermediatePoints,0),c=this.diagram.scrollSettings.currentZoom,d=e.dragLimit?e.dragLimit:{left:0,right:0,top:0,bottom:0};if(d.top||d.bottom||d.left||d.right){this.diagram.getWrapper(t.wrapper,e.id);var p=new Ne(0,0,0,0),f=this.diagram.getWrapper(t.wrapper,e.id);p.x=f.offsetX/c+o,p.y=f.offsetY/c+a,p.width=f.bounds.width/c,p.height=f.bounds.height/c;var g=new Ne(h.x-(d.left||0)-p.width/2,h.y-(d.top||0)-p.height/2,(d.left||0)+(d.right||0)+p.width,(d.top||0)+(d.bottom||0)+p.height);if(g.containsPoint(r));else for(var S=0,b=this.boundsInterSects([h,r],g,!1);S=t){c=t-r,d=z.findAngle(s,a),u=c*Math.cos(d*Math.PI/180),p=c*Math.sin(d*Math.PI/180),o={x:s.x+u,y:s.y+p};break}r+=h,s=a}else s=a;return o},n.prototype.getInterceptWithSegment=function(t,e){for(var o,a,i=[],r=[],s=[],l=z.findLength({x:0,y:0},{x:this.diagram.scroller.viewPortWidth,y:this.diagram.scroller.viewPortHeight}),h=1;h0&&a<=90||a>180&&a<=270?90:-90;r.push(z.transform(t,a+c,l)),r.push(z.transform(t,o+c,l));var p=im({x1:s[0].x,y1:s[0].y,x2:s[1].x,y2:s[1].y},{x1:r[0].x,y1:r[0].y,x2:r[1].x,y2:r[1].y});p.enabled&&i.push(p.intersectPt)}return i},n.prototype.getAnnotationChanges=function(t,e){var r={};return r[ab(t,e.id,!0)]={width:e.width,height:e.height,offset:t instanceof te?{x:e.offset.x,y:e.offset.y}:e.offset,rotateAngle:e.rotateAngle,margin:{left:e.margin.left,right:e.margin.right,top:e.margin.top,bottom:e.margin.bottom},horizontalAlignment:e.horizontalAlignment,verticalAlignment:e.verticalAlignment,alignment:t instanceof de?e.alignment:void 0},{annotations:r}},n.prototype.getConnectorPortChanges=function(t,e){var i=function Wse(n,t,e){for(var i=n.ports,r=0;r1&&(v.width=g,v.offset.x=1/S),f>1&&(v.height=f,v.offset.y=1/b)}}e instanceof Nr&&(e.alignment="Center"),l=this.getAnnotationChanges(t,e),t instanceof te?this.diagram.nodePropertyChange(t,a,l):this.diagram.connectorPropertyChange(t,a,l),this.diagram.updateDiagramObject(t)},n.prototype.getSubProcess=function(t){var i,e={nodes:[],connectors:[]};return t instanceof te?i=t.processId:t&&t.nodes&&t.nodes.length&&t.nodes[0].processId&&(i=t.nodes[0].processId),i&&e.nodes.push($(this.diagram.nameTable[i])),e},n.prototype.checkBoundaryConstraints=function(t,e,i,r){var s=this.diagram.pageSettings,o=this.diagram.pageSettings.boundaryConstraints,a=this.diagram.scroller;if("Page"===o||"Diagram"===o){var l=i?void 0:this.diagram.selectedItems.wrapper.bounds;return!!((i?i.right:l.right)+(t||0)<=("Page"===o?s.width:a.viewPortWidth)&&(i?i.left:l.left)+(t||0)>=0&&(i?i.bottom:l.bottom)+(e||0)<=("Page"===o?s.height:a.viewPortHeight)&&(i?i.top:l.top)+(e||0)>=0||"None"!==this.diagram.layout.type&&r)}return!0},n.prototype.dragSelectedObjects=function(t,e){var i=this,r=this.diagram.selectedItems;this.state&&!this.state.backup&&(this.state.backup={},this.state.backup.offsetX=r.offsetX,this.state.backup.offsetY=r.offsetY),r=GI(this.diagram,r)||r;var s=this.diagram.selectedItems.nodes.filter(function(c){return"SwimLane"===c.shape.type});if(s.length>0&&!this.diagram.currentSymbol&&this.diagram.selectedItems.nodes.length>1){var o=this.diagram.selectedItems.nodes.filter(function(c){return""===c.parentId||"SwimLane"!==i.diagram.nameTable[c.parentId].shape.type});if(o.length>0){for(var a=0;a0||l.length>1)&&(o=o.concat(l),this.diagram.selectedItems.nodes.splice(0,this.diagram.selectedItems.nodes.length),o.forEach(function(c){i.diagram.selectedItems.nodes.push(c)}),r=this.diagram.selectedItems,this.diagram.selectedObject.helperObject=void 0)}}if(this.checkBoundaryConstraints(t,e)){this.diagram.diagramActions=this.diagram.diagramActions|ee.PreventZIndexOnDragging|ee.DragUsingMouse;var h=this.diagram.selectedObject.actualObject;return(h&&h instanceof te&&h.isLane&&Gx(h,this.diagram)||!h||!h.isLane)&&this.diagram.drag(r,t,e),this.diagram.diagramActions=this.diagram.diagramActions&~(ee.PreventZIndexOnDragging|ee.DragUsingMouse),this.diagram.refreshCanvasLayers(),this.checkHtmlObjectDrag(r),!0}return!1},n.prototype.checkHtmlObjectDrag=function(t){var e=!1;this.diagram.views&&this.diagram.views.length>1&&(t instanceof si?e=t.nodes.some(function(i){return i.shape&&"HTML"===i.shape.type}):t.shape&&"HTML"===t.shape.type&&(e=!0),e&&this.resetOverviewCanvas())},n.prototype.resetOverviewCanvas=function(){for(var t=0,e=this.diagram.views;t0&&(this.layoutAnimateModule.stopCurrentAnimation(this.objectStore[0],e,t),this.objectStore=[]),a=this.diagram.doLayout(),this.objectStore.push(a)),this.canUpdateTemplate=!1,this.diagram.blazorActions&=~on.expandNode,this.diagram.preventNodesUpdate=r,this.diagram.layoutAnimateModule&&this.diagram.organizationalChartModule&&!i)this.diagram.allowServerDataBinding=!1,this.layoutAnimateModule.expand(this.diagram.layout.enableAnimation,a,t,this.diagram);else{var l={element:$(t),state:!!t.isExpanded};this.triggerEvent(Ce.expandStateChange,l),this.diagram.lineRoutingModule&&this.diagram.constraints&rt.LineRouting&&"ComplexHierarchicalTree"!==this.diagram.layout.type&&this.diagram.resetSegments()}return this.diagram.layout.fixedNode=""===o?"":this.diagram.layout.fixedNode,a},n.prototype.getparentexpand=function(t,e,i,r){for(var s,o=0;o0&&(this.diagram.selectedItems.wrapper.rotateAngle=this.diagram.selectedItems.rotateAngle=s.rotateAngle),r instanceof te&&"SwimLane"!==r.shape.type&&!r.isLane&&!r.isPhase&&!r.isHeader)(r.offsetX!==r.wrapper.offsetX||r.offsetY!==r.wrapper.offsetY||r.width!==r.wrapper.width||r.height!==r.wrapper.height||r.rotateAngle!==r.wrapper.rotateAngle)&&(r.offsetX+=o,r.offsetY+=a,r.width+=l,r.height+=h,r.rotateAngle+=c,this.diagram.nodePropertyChange(r,{},{offsetX:r.offsetX,offsetY:r.offsetY,width:r.width,height:r.height,rotateAngle:r.rotateAngle})),e=this.diagram.spatialSearch.findObjects(r.wrapper.outerBounds);else if(r instanceof si)for(var d=0;d30||g.wrapper.outerBounds.topCenter.y-f.wrapper.outerBounds.bottomCenter.y>30)&&this.diagram.lineRoutingModule.refreshConnectorSegments(this.diagram,p,!0)}}this.updateSelector(),this.diagram.protectPropertyChange(!1)}},n.prototype.drawSelectionRectangle=function(t,e,i,r){this.diagram.drawSelectionRectangle(t,e,i,r)},n.prototype.startGroupAction=function(){this.diagram.startGroupAction()},n.prototype.endGroupAction=function(){this.diagram.endGroupAction()},n.prototype.removeChildFromBPmn=function(t,e,i){var r=this.diagram.nameTable[t.id]||t.nodes[0];if(i&&r&&r.processId&&r.processId===i.wrapper.id){var s=$(r);s.processId=r.processId,this.diagram.startGroupAction();var o=this.diagram.nameTable[r.processId].shape.activity.subProcess.processes||[];o.splice(o.indexOf(r.id),1),this.diagram.bpmnModule.removeChildFromBPMN(this.diagram.nameTable[r.processId].wrapper,r.id,this.diagram),this.diagram.nameTable[r.id].processId="",r.offsetX=r.wrapper.offsetX,r.offsetY=r.wrapper.offsetY;var a=$(r);this.addHistoryEntry({type:"PositionChanged",redoObject:{nodes:[a]},undoObject:{nodes:[s]},category:"Internal"}),this.diagram.endGroupAction()}},n.prototype.isDroppable=function(t,e){var i=this.diagram.nameTable[t.id]||t.nodes[0];return i instanceof te&&(!ce()&&"TextAnnotation"===i.shape.shape||("Group"===e.shape.shape&&(e.shape.activity.subProcess.collapsed=!1),!(i&&"Bpmn"===i.shape.type&&(i.processId===e.id||i.id===e.processId||"Bpmn"===e.shape.type&&!(e instanceof de)&&e.shape.activity&&e.shape.activity.subProcess&&e.shape.activity.subProcess.collapsed))))},n.prototype.renderHighlighter=function(t,e,i){if(new Ne,t.target instanceof te||t.target instanceof de||e&&(t.source instanceof te||t.source instanceof de)){var a=this.findTarget(e?t.sourceWrapper:t.targetWrapper,e?t.source:t.target,i,!0),l=void 0;if(a instanceof Hd)for(var h=a.id,c=t.target,u=0,p=c.wrapper.children[0].children[0].children[2].children;u0){var r=0;t[0]=this.diagram.nameTable[t[0].id]||t[0];var s="Object"===i?yr(t[0].wrapper):this.diagram.selectedItems.wrapper.bounds,o={nodes:[],connectors:[]},a={nodes:[],connectors:[]};for(r="Object"===i?r+1:r;r0){var i=0,r=0,s=0,o=0,a=0,l=0,h=0,c=0,d={nodes:[],connectors:[]},u={nodes:[],connectors:[]};for(i=0;io.center.y&&(r=n[parseInt(e.toString(),10)],n[parseInt(e.toString(),10)]=n[parseInt(i.toString(),10)],n[parseInt(i.toString(),10)]=r):s.center.x>o.center.x&&(r=n[parseInt(e.toString(),10)],n[parseInt(e.toString(),10)]=n[parseInt(i.toString(),10)],n[parseInt(i.toString(),10)]=r)}}return n}(t,e),i=1;i0){var i=0,r={x:.5,y:.5};t[0]=this.diagram.nameTable[t[0].id]||t[0];var s=yr(t[0].wrapper),o={nodes:[],connectors:[]},a={nodes:[],connectors:[]};for(i=1;ii.zIndex){for(var s=this.diagram.layers.indexOf(this.diagram.getActiveLayer()),o=this.diagram.layers[parseInt(s.toString(),10)].zIndexTable,a=JSON.parse(JSON.stringify(o)),l=i.zIndex,h=r.zIndex,c=h;c>=l;c--)l!==c?o[c-1]?(o[parseInt(c.toString(),10)]=o[c-1],this.diagram.nameTable[o[parseInt(c.toString(),10)]].zIndex=c):(o[c-1]=o[parseInt(c.toString(),10)],this.diagram.nameTable[o[c-1]].zIndex=c,delete o[parseInt(c.toString(),10)]):this.swapZIndexObjects(h,o,r.id,a);"SVG"===this.diagram.mode?(this.moveSvgNode(e.parentId,i.id),this.updateNativeNodeIndex(e.parentId,i.id)):this.diagram.refreshCanvasLayers()}},n.prototype.findLeastIndexConnector=function(t,e,i){for(var r=0;rs.zIndex&&(i=s)}return i},n.prototype.findLeastIndexObject=function(t,e){var i=t;return t instanceof te&&(i=this.findLeastIndexConnector(t.inEdges,e,i),i=this.findLeastIndexConnector(t.outEdges,e,i)),i},n.prototype.checkSelection=function(t,e){var i;if(1===t.nodes.length&&0===t.connectors.length)if(cs(this.diagram,t.nodes[0],!0)){var r=t.nodes[0];if("SwimLane"===(i="SwimLane"===t.nodes[0].shape?t.nodes[0]:this.diagram.nameTable[t.nodes[0].parentId]).shape.type){var s="Horizontal"===i.shape.orientation;(r.isPhase&&(s&&"ResizeSouth"===e||!s&&"ResizeEast"===e)||r.isLane&&(s&&"ResizeEast"===e||!s&&"ResizeSouth"===e))&&W3(this.diagram,i,e)}else if("Grid"===i.container.type)if("Horizontal"===i.container.orientation&&1===r.rowIndex||"Vertical"===i.container.orientation&&r.rowIndex>0&&r.columnIndex>0){if("ResizeSouth"===e)for(var o=0;o1&&(this.diagram.realActions=this.diagram.realActions|$i.hScrollbarMoved,this.scrolled=!0),this.diagram.scrollSettings.horizontalOffset=t},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"verticalOffset",{get:function(){return this.vOffset},set:function(t){this.vOffset=t,Math.abs(this.vOffset-this.diagram.scrollSettings.verticalOffset)>1&&(this.diagram.realActions=this.diagram.realActions|$i.vScrollbarMoved,this.scrolled=!0),this.diagram.scrollSettings.verticalOffset=t},enumerable:!0,configurable:!0}),n.prototype.getBounds=function(){var e=this.diagram.spatialSearch.getPageBounds(0,0);return(e.x<0||e.y<0)&&!this.diagram.pageSettings.multiplePage?this.getPageBounds(void 0,void 0,!0,!0):this.getPageBounds(void 0,void 0,!0)},n.prototype.updateScrollOffsets=function(t,e){var i,r,s=this.getBounds();s.x*=this.currentZoom,s.y*=this.currentZoom,s.width*=this.currentZoom,s.height*=this.currentZoom,i=Math.max(0,t-s.left),r=Math.max(0,e-s.top),void 0!==t&&void 0!==e?(this.horizontalOffset=i,this.verticalOffset=r,this.diagram.setOffset(i,r)):this.diagram.setOffset(-this.horizontalOffset-s.x,-this.verticalOffset-s.y),this.transform={tx:Math.max(this.horizontalOffset,-s.left)/this.currentZoom,ty:Math.max(this.verticalOffset,-s.top)/this.currentZoom,scale:this.currentZoom}},n.prototype.setScrollOffset=function(t,e){this.scrolled=!1;var i=this.getBounds();i.x*=this.currentZoom,i.y*=this.currentZoom,i.width*=this.currentZoom,i.height*=this.currentZoom;var r=-i.left,s=-i.top,o=!1,a=this.viewPortWidth*this.currentZoom,l=this.viewPortHeight*this.currentZoom,h=r-t;if(h!==this.horizontalOffset){rh?this.horizontalOffset-=t:this.horizontalOffset=h,o=!0);var c=Math.max(i.right+this.vScrollSize,a);if(!o&&c<-h+this.viewPortWidth){var d=-h+a-this.vScrollSize,u=-this.horizontalOffset+a-this.vScrollSize;this.horizontalOffset=dd-u?h:-(i.right+this.vScrollSize-a),o=!0}o||(this.horizontalOffset=r-t)}o=!1;var p=s-e;if(p!==this.verticalOffset){sp?this.verticalOffset-=e:this.verticalOffset=p,o=!0);var f=Math.max(i.bottom+this.hScrollSize,l);if(!o&&f<-p+l){var g=-p+l-this.hScrollSize,v=-this.verticalOffset+l-this.hScrollSize;this.verticalOffset=gg-v?p:-(i.bottom+this.hScrollSize-l),o=!0}o||(this.verticalOffset=s-e)}this.transform={tx:Math.max(this.horizontalOffset,-i.left)/this.currentZoom,ty:Math.max(this.verticalOffset,-i.top)/this.currentZoom,scale:this.currentZoom},this.setSize()},n.prototype.getObjects=function(t,e){for(var i=[],r=0;r0){for(var l=0;l0){h.push(i[parseInt(o.toString(),10)].id);for(var d=0;d=e.bottom&&(l=0),-this.horizontalOffset<=e.x&&-this.horizontalOffset+this.viewPortWidth>=e.right&&(a=0),this.hScrollSize=a,this.vScrollSize=l;var h=this.diagramWidth,c=this.diagramHeight;this.diagramWidth=Math.max(e.right,-this.horizontalOffset+this.viewPortWidth-l)-i,this.diagramHeight=Math.max(e.bottom,-this.verticalOffset+this.viewPortHeight-a)-r,(h!==this.diagramWidth||c!==this.diagramHeight)&&"Diagram"!==this.diagram.scrollSettings.scrollLimit&&this.diagram.setSize(this.diagramWidth,this.diagramHeight),"Diagram"===this.diagram.scrollSettings.scrollLimit&&(h===this.diagramWidth&&c===this.diagramHeight&&1===this.currentZoom||this.diagram.diagramActions&&t&&(!this.diagram.diagramActions||!t||0===this.verticalOffset&&this.verticalOffset!==t.y||0===this.horizontalOffset&&this.horizontalOffset!==t.x)?t&&h===this.diagramWidth&&c===this.diagramHeight&&(this.diagram.diagramCanvas.scrollHeight>this.viewPortHeight&&t.y<0&&this.horizontalOffset===t.x&&0===this.verticalOffset||this.diagram.diagramCanvas.scrollWidth>this.viewPortWidth&&t.x<0&&this.verticalOffset===t.y&&0===this.horizontalOffset)&&(this.verticalOffset=t.y,this.horizontalOffset=t.x,this.transform={tx:Math.max(t.x,-e.left)/this.currentZoom,ty:Math.max(t.y,-e.top)/this.currentZoom,scale:this.currentZoom}):(this.diagram.scrollActions&ca.Interaction&&t&&(this.transform={tx:Math.max(t.x,-e.left/this.currentZoom)/this.currentZoom,ty:Math.max(t.y,-e.top/this.currentZoom)/this.currentZoom,scale:this.currentZoom},this.horizontalOffset=t.x,this.verticalOffset=t.y),this.diagram.setSize(this.diagramWidth,this.diagramHeight),!(this.diagram.scrollActions&ca.PropertyChange)&&t&&(this.horizontalOffset=t.x,this.verticalOffset=t.y,this.transform={tx:Math.max(t.x,-e.left)/this.currentZoom,ty:Math.max(t.y,-e.top)/this.currentZoom,scale:this.currentZoom}))),this.diagram.transformLayers(),this.diagram.element.style.overflow="hidden"},n.prototype.setViewPortSize=function(t,e){this.viewPortWidth=t,this.viewPortHeight=e},n.prototype.getPageBounds=function(t,e,i,r){var o,s=new Ne;if("Content"===e||r||null===this.diagram.pageSettings.width||null===this.diagram.pageSettings.height){var u=t?void 0:0;o=this.diagram.spatialSearch.getPageBounds(u,u)}else{var a=this.diagram.pageSettings.width,l=this.diagram.pageSettings.height,h=0,c=0;if(this.diagram.pageSettings.multiplePage){if((s=this.diagram.spatialSearch.getPageBounds(0,0)).right>a&&(a*=d=Math.ceil(s.right/a)),s.bottom>l&&(l*=d=Math.ceil(s.bottom/l)),s.left<0&&Math.abs(s.left)>h){var d=Math.ceil(Math.abs(s.left)/this.diagram.pageSettings.width);h=this.diagram.pageSettings.width*d}s.top<0&&Math.abs(s.top)>c&&(d=Math.ceil(Math.abs(s.top)/this.diagram.pageSettings.height),c=this.diagram.pageSettings.height*d)}o=new Ne(-h,-c,a+h,l+c)}if(i){var p=this.diagram.scrollSettings.padding;o.x-=p.left,o.y-=p.top,o.width+=p.left+p.right,o.height+=p.top+p.bottom}return o},n.prototype.getPageBreak=function(t){for(var e=0,i=0,r=-1,s=[],c=this.diagram.pageSettings.margin.left,d=this.diagram.pageSettings.margin.right,u=this.diagram.pageSettings.margin.top,p=this.diagram.pageSettings.margin.bottom,f=1,g=1;t.width>e;)(e+=this.diagram.pageSettings.width?this.diagram.pageSettings.width:t.width)===this.diagram.pageSettings.width&&(s[++r]={x1:t.left+c,y1:t.top+u,x2:t.left+c,y2:t.bottom-p}),ei;)(i+=this.diagram.pageSettings.height?this.diagram.pageSettings.height:t.height)===this.diagram.pageSettings.height&&(s[++r]={x1:t.left+c,y1:t.top+u,x2:t.right-d,y2:t.top+u}),i=this.diagram.scrollSettings.minZoom||l||t>=1)){this.currentZoom*=t;var c=this.getPageBounds(void 0,void 0,!0);c.x*=this.currentZoom,c.y*=this.currentZoom;var d=Hi();Gp(d,t,t,r.x,r.y),r3(d,e||0,i||0),Mx(h,d);var u=Je(h,{x:0,y:0});if(1===t&&(u=this.applyScrollLimit(u.x,u.y,s,o,a)),a=-c.y>=u.y&&-c.x>=u.x&&a,(this.diagram.scrollActions&ca.PropertyChange||!(this.diagram.scrollActions&ca.Interaction)||"Diagram"!==this.diagram.scrollSettings.scrollLimit||a)&&(this.transform={tx:Math.max(u.x,-c.left)/this.currentZoom,ty:Math.max(u.y,-c.top)/this.currentZoom,scale:this.currentZoom},this.horizontalOffset=u.x,this.verticalOffset=u.y),this.setSize(u),"SVG"!==this.diagram.mode&&Ds(this.diagram)&&this.diagram.scroller.virtualizeElements(),"SVG"!==this.diagram.mode&&!Ds(this.diagram)&&this.diagram.refreshDiagramLayer(),this.diagram.setOffset(-this.horizontalOffset-c.x,-this.verticalOffset-c.y),eb(this.diagram),this.diagram.views&&this.diagram.views.overview){var p=this.diagram.views.overview,f=p.scrollOverviewRect(p.parent.scroller.horizontalOffset,p.parent.scroller.verticalOffset,p.parent.scroller.currentZoom,!0);p.updateOverviewrect(-f.x,-f.y,f.width,f.height),p.updateView(p)}}}},n.prototype.fitToPage=function(t){var e=(t=t||{}).mode,i=t.region,r=t.margin||{},s=t.canZoomIn,o=t.customBounds,a=t.canZoomOut;r.bottom=r.bottom||25,r.top=r.top||25,r.left=r.left||25,r.right=r.right||25;var h,l=o,c=-this.horizontalOffset,d=-this.verticalOffset;if("PageSettings"===(i=i||"PageSettings")&&this.diagram.pageSettings.width&&this.diagram.pageSettings.height||this.diagram.nodes.length>0||this.diagram.connectors.length>0){e=e||"Page","CustomBounds"!==i&&(l=this.getPageBounds(!0,i,!0));var u={x:0,y:0};r.left+r.right>this.viewPortWidth&&(this.viewPortWidth<=100?(r.left=5,r.right=5):(r.left=25,r.right=25)),r.top+r.bottom>this.viewPortHeight&&(this.viewPortHeight<=100?(r.top=5,r.bottom=5):(r.top=25,r.bottom=25)),u.x=(this.viewPortWidth-(r.left+r.right))/l.width,u.y=(this.viewPortHeight-(r.top+r.bottom))/l.height,!s&&l.width-this.horizontalOffset-a+this.viewPortWidth&&(i=o.right-this.viewPortWidth,i+=20),o.x<-a&&(i=o.x),o.bottom>-l+this.viewPortHeight&&(r=o.bottom-this.viewPortHeight,r+=20),o.y<-l&&(r=o.y),this.zoom(1,-this.horizontalOffset-i,-this.verticalOffset-r,null,void 0,e))},n.prototype.bringToCenter=function(t){var e=this.currentZoom,i=new Ne(t.x*e,t.y*e,t.width*e,t.height*e),r=i.x+i.width/2-this.viewPortWidth/2,s=i.y+i.height/2-this.viewPortHeight/2;this.zoom(1,-this.horizontalOffset-(r*=-1),-this.verticalOffset-(s*=-1),null)},n.prototype.applyScrollLimit=function(t,e,i,r,s){if("Infinity"===this.diagram.scrollSettings.scrollLimit&&void 0===i&&!r&&(t=-t,e=-e),"Infinity"!==this.diagram.scrollSettings.scrollLimit){var o=void 0;if("Limited"===this.diagram.scrollSettings.scrollLimit){var a=this.diagram.scrollSettings.scrollableArea;o=new Ne(a.x,a.y,a.width,a.height)}(o=o||(s?this.getPageBounds():this.getPageBounds(!0))).x*=this.currentZoom,o.y*=this.currentZoom,o.width*=this.currentZoom,o.height*=this.currentZoom,void 0!==i&&(t*=-1,e*=-1),r&&(t*=-1,e*=-1);var l=Math.max(o.right,this.viewPortWidth);if(!r&&!(t<=o.x&&(t+this.viewPortWidth>=o.right||t>=o.right-this.viewPortWidth)||t>=o.x&&t+this.viewPortWidth<=l))if(t>=o.x)t=Math.max(o.x,Math.min(t,t-(t+this.viewPortWidth-this.vScrollSize-l)));else{var h=o.right-this.viewPortWidth;t=Math.min(h,o.x)}var c=Math.max(o.bottom,this.viewPortHeight);r||e<=o.y&&e+this.viewPortHeight>=o.bottom||e>=o.y&&e+this.viewPortHeight<=c||(e>=o.y?e=Math.max(o.y,Math.min(e,e-(e+this.viewPortHeight-this.hScrollSize-c))):(h=o.bottom-this.viewPortHeight,e=Math.min(o.y,h))),t*=-1,e*=-1}return{x:t,y:e}},n}(),tae=function(){function n(t,e,i,r,s){this.objects=[],this.left=t,this.top=e,this.width=i,this.height=r,this.spatialSearch=s}return n.prototype.findQuads=function(t,e){null!=this.first&&this.first.isIntersect(t)&&this.first.findQuads(t,e),null!=this.second&&this.second.isIntersect(t)&&this.second.findQuads(t,e),null!=this.third&&this.third.isIntersect(t)&&this.third.findQuads(t,e),null!=this.fourth&&this.fourth.isIntersect(t)&&this.fourth.findQuads(t,e),this.objects.length>0&&e.push(this)},n.prototype.isIntersect=function(t){return!(this.left+this.widtht.right||this.top>t.bottom)},n.prototype.selectQuad=function(){for(var i,t=null,e=this;null!=e;)i=e.getQuad(t),e=i.source,t=i.target||t;return t},n.prototype.getQuad=function(t){var e=this.width/2,i=this.height/2;if(e>=1e3&&i>=1e3){var r=this.left+e,s=this.top+i;if(this.spatialSearch.childRight<=r){if(this.spatialSearch.childBottom<=s)return this.first||((o=new n(this.left,this.top,e,i,this.spatialSearch)).parent=this,this.first=o),{source:this.first};if(this.spatialSearch.childTop>=s)return this.third||((o=new n(this.left,s,e,i,this.spatialSearch)).parent=this,this.third=o),{source:this.third}}else if(this.spatialSearch.childLeft>=r){if(this.spatialSearch.childBottom<=s)return this.second||((o=new n(r,this.top,e,i,this.spatialSearch)).parent=this,this.second=o),{source:this.second};var o;if(this.spatialSearch.childTop>=s)return this.fourth||((o=new n(r,s,e,i,this.spatialSearch)).parent=this,this.fourth=o),{source:this.fourth}}}return this.objects.push(this.spatialSearch.childNode),{target:this}},n.prototype.isContained=function(){return this.spatialSearch.childLeft>=this.left&&this.spatialSearch.childRight<=this.left+this.width&&this.spatialSearch.childTop>=this.top&&this.spatialSearch.childBottom<=this.top+this.height},n.prototype.addIntoAQuad=function(t){var e={};this.spatialSearch.setCurrentNode(t);for(var i=null;!e.isAdded;)i=(e=this.spatialSearch.parentQuad.add(i)).quad;return i},n.prototype.add=function(t){if(t=null,this.isContained())return{isAdded:!0,quad:t=this.selectQuad()};var e=void 0,i=!(0!==this.objects.length||this.first||this.second||this.third||this.fourth),r=2*this.width,s=2*this.height;return this.spatialSearch.childLeft=this.childLeft?(this.pageLeft=this.childLeft,this.leftElement=t,r=!0):t===this.leftElement&&(this.pageLeft=Number.MAX_VALUE,this.findLeft(this.parentQuad),r=!0)),(this.pageTop!==this.childTop||t!==this.topElement)&&(this.pageTop>=this.childTop?(this.pageTop=this.childTop,this.topElement=t,r=!0):t===this.topElement&&(this.pageTop=Number.MAX_VALUE,this.findTop(this.parentQuad),r=!0)),(this.pageBottom!==this.childBottom||t!==this.bottomElement)&&(this.pageBottom<=this.childBottom?(r=!0,this.pageBottom=this.childBottom,this.bottomElement=t):t===this.bottomElement&&(this.pageBottom=-Number.MAX_VALUE,this.findBottom(this.parentQuad),r=!0)),(this.pageRight!==this.childRight||t!==this.rightElement)&&(this.pageRight<=this.childRight?(this.pageRight=this.childRight,this.rightElement=t,r=!0):t===this.rightElement&&(this.pageRight=-Number.MAX_VALUE,this.findRight(this.parentQuad),r=!0)),r}return this.setCurrentNode(null),!1},n.prototype.isWithinPageBounds=function(t){return t.left>=this.pageLeft&&t.right<=this.pageRight&&t.top>=this.pageTop&&t.bottom<=this.pageBottom},n.prototype.findQuads=function(t){var e=[];return this.parentQuad.findQuads(t,e),e},n.prototype.findObjects=function(t){for(var i=[],r=0,s=this.findQuads(t);r=r.outerBounds.left&&(this.pageLeft=r.outerBounds.left,this.leftElement=r)}},n.prototype.findTop=function(t){t.first||t.second?(t.first&&this.findTop(t.first),t.second&&this.findTop(t.second)):(t.third&&this.findTop(t.third),t.fourth&&this.findTop(t.fourth));for(var e=0,i=t.objects;e=r.outerBounds.top&&(this.pageTop=r.outerBounds.top,this.topElement=r)}},n.prototype.setCurrentNode=function(t){if(this.childNode=t,t){var e=t.outerBounds;this.childLeft=Number(e.left),this.childTop=Number(e.top),this.childRight=Number(e.right),this.childBottom=Number(e.bottom)}else this.childLeft=Number.MAX_VALUE,this.childTop=Number.MAX_VALUE,this.childRight=-Number.MAX_VALUE,this.childBottom=-Number.MAX_VALUE},n.prototype.getPageBounds=function(t,e){if(this.pageLeft===Number.MAX_VALUE)return new Ne(0,0,0,0);var i=void 0!==t?Math.min(this.pageLeft,0):this.pageLeft,r=void 0!==e?Math.min(this.pageTop,0):this.pageTop;return new Ne(Math.round(i),Math.round(r),Math.round(this.pageRight-i),Math.round(this.pageBottom-r))},n.prototype.getQuad=function(t){return this.quadTable[t.id]},n}(),iae=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),nae=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return iae(t,n),function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);r>3&&s&&Object.defineProperty(t,e,s)}([I(!1)],t.prototype,"preventDefaults",void 0),t}(Ee),sae=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),o_=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},oae=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return sae(t,n),o_([I("")],t.prototype,"action",void 0),o_([I("")],t.prototype,"cursor",void 0),t}(Ee),a_=function(){function n(){this.size=20,this.intermediatePoints=[],this.gridCollection=[],this.startArray=[],this.targetGridCollection=[],this.sourceGridCollection=[],this.considerWalkable=[]}return n.prototype.lineRouting=function(t){var e=t.connectors.length;if(this.renderVirtualRegion(t),e>0)for(var i=0;i=t.right||e.right<=t.left||e.top>=t.bottom||e.bottom<=t.top)},n.prototype.findEndPoint=function(t,e,i){var r,s;if(e&&""!==t.sourcePortID&&t.sourcePortWrapper||!e&&""!==t.targetPortID&&t.targetPortWrapper){s=zo(r=e?{x:t.sourcePortWrapper.offsetX,y:t.sourcePortWrapper.offsetY}:{x:t.targetPortWrapper.offsetX,y:t.targetPortWrapper.offsetY},void 0,e?t.sourceWrapper.bounds:t.targetWrapper.bounds);var o=e?t.sourcePortWrapper.bounds:t.targetPortWrapper.bounds;r=i?"Top"===s?{x:o.topCenter.x,y:o.topCenter.y}:"Left"===s?{x:o.middleLeft.x,y:o.middleLeft.y}:"Right"===s?{x:o.middleRight.x,y:o.middleRight.y}:{x:o.bottomCenter.x,y:o.bottomCenter.y}:{x:o.center.x,y:o.center.y}}else r=e&&this.startNode||!e&&this.targetNode?e?{x:this.startNode.wrapper.offsetX,y:this.startNode.wrapper.offsetY}:{x:this.targetNode.wrapper.offsetX,y:this.targetNode.wrapper.offsetY}:e?{x:t.sourcePoint.x,y:t.sourcePoint.y}:{x:t.targetPoint.x,y:t.targetPoint.y};return r},n.prototype.refreshConnectorSegments=function(t,e,i,r){var h,c,p,f,g,y,S,b,M,w,C,s=e.sourceID,o=e.targetID,a=e.sourcePortID,l=e.targetPortID;if(function Jre(n,t){var e=0;return n.constraints&qe.LineRouting?e=n.constraints&qe.LineRouting:n.constraints&qe.InheritLineRouting&&(e=t.constraints&rt.LineRouting),e}(e,t)||r){this.startNode=t.nameTable[""+s],this.targetNode=t.nameTable[""+o],this.intermediatePoints=[],this.startArray=[],this.targetGridCollection=[],this.sourceGridCollection=[],this.startGrid=void 0,this.targetGrid=void 0;for(var D=0;D0;){var L=this.startArray.pop();if(L){for(D=0;D1&&(e.segments=[]),this.updateConnectorSegments(t,this.intermediatePoints,this.gridCollection,e,i)){this.considerWalkable=[];break e}this.targetGridCollection.splice(this.targetGridCollection.indexOf(O),1),L=this.startArray.pop()}}L&&this.findPath(L)}}}},n.prototype.checkChildNodes=function(t,e){var i=!1,r=!1;if(t.nodeId.length>=1&&!e)for(var s=0;s1&&this.targetGridCollection[0].nodeId.length>1)for(var c=0;c<=1;c++){for(var d=this.targetGridCollection[parseInt(c.toString(),10)].gridX,u=this.targetGridCollection[parseInt(c.toString(),10)].gridY,p=this.targetGridCollection[parseInt(c.toString(),10)].nodeId,f=void 0,g=0;g=e.right&&t.top<=e.top&&t.bottom>=e.bottom},n.prototype.getEndvalue=function(t,e){return this.gridCollection[t.gridX][t.gridY].walkable?t:"left"===e?this.getEndvalue(this.gridCollection[t.gridX-1][t.gridY],e):"right"===e?this.getEndvalue(this.gridCollection[t.gridX+1][t.gridY],e):"top"===e?this.getEndvalue(this.gridCollection[t.gridX][t.gridY-1],e):"bottom"===e?this.getEndvalue(this.gridCollection[t.gridX][t.gridY+1],e):t},n.prototype.changeValue=function(t,e,i){t.walkable||this.considerWalkable.push(t);for(var r,s=0;s<=e;s++)"left"===i?r=this.gridCollection[t.gridX-s][t.gridY]:"right"===i?r=this.gridCollection[t.gridX+s][t.gridY]:"top"===i?r=this.gridCollection[t.gridX][t.gridY-s]:"bottom"===i&&(r=this.gridCollection[t.gridX][t.gridY+s]),r.walkable||this.considerWalkable.push(r)},n.prototype.getIntermediatePoints=function(t){var e;for(this.intermediatePoints=[];t;)this.intermediatePoints.push({x:t.gridX,y:t.gridY}),t=t.parent;this.intermediatePoints.reverse(),this.intermediatePoints.length>=1&&void 0!==this.intermediatePoints[0]&&void 0!==this.intermediatePoints[1]&&(this.intermediatePoints[0].x===this.intermediatePoints[1].x?this.intermediatePoints[0].y=1&&u.length>1&&(g=u[u.length-2].x!==u[u.length-1].x?u[u.length-2].x>u[u.length-1].x?"Left":"Right":u[u.length-2].y>u[u.length-1].y?"Top":"Bottom"),M>=2&&v===g&&u.length>1&&u.splice(u.length-2,1),v=g);if(u&&u.length>1){for(var w=0;wD.x?S.bounds.middleLeft:S.bounds.middleRight),w===u.length-2&&""===r.targetPortID&&y&&(l=C.x>D.x?y.bounds.middleRight:y.bounds.middleLeft),0===w&&b&&(C.x=b.x,C.y=D.y=b.y),w===u.length-2&&l&&(w>0&&r.targetDecorator&&l.x-D.x<0&&Math.abs(l.x-C.x)0&&r.targetDecorator&&l.x-D.x>0&&Math.abs(l.x-C.x)D.y?S.bounds.topCenter:S.bounds.bottomCenter),w===u.length-2&&""===r.targetPortID&&y&&(l=C.y>D.y?y.bounds.bottomCenter:y.bounds.topCenter),0===w&&b&&(C.y=b.y,C.x=D.x=b.x),w===u.length-2&&l&&(w>0&&r.targetDecorator&&l.y-D.y<0&&Math.abs(l.y-C.y)0&&r.targetDecorator&&l.y-D.y>0&&Math.abs(l.y-C.y)D.x?(p="Left",f=C.x-D.x):(p="Right",f=D.x-C.x):C.y>D.y?(p="Top",f=C.y-D.y):(p="Bottom",f=D.y-C.y),o.push({type:"Orthogonal",length:f,direction:p})}}if(o&&o.length>0){var A=o[o.length-1];if(1===o.length&&(A.length-=20),A.length<10&&2===o.length&&(o.pop(),o.length>0&&(o[0].length-=20,A=o[0])),r.targetDecorator&&("Top"===A.direction||"Bottom"===A.direction)&&A.length>r.targetDecorator.height+1||("Right"===A.direction||"Left"===A.direction)&&A.length>r.targetDecorator.width+1)return r.segments=o,s&&t.connectorPropertyChange(r,{},{type:"Orthogonal",segments:o}),!0}return!1},n.prototype.findPath=function(t){for(var e,i=[],r=this.findNearestNeigbours(t,this.gridCollection,!0),s=0;sl)&&(e.x!==t.gridX||e.y!==t.gridY)&&(i.push(e),o.previousDistance=l,o.afterDistance=o.afterDistance||this.manhattan(Math.abs(e.x-this.targetGrid.gridX),Math.abs(e.y-this.targetGrid.gridY)),o.totalDistance=o.previousDistance+o.afterDistance,o.parent=t)}if(i.length>0)for(s=0;st?i*t+e:i*e+t},n.prototype.manhattan=function(t,e){return t+e},n.prototype.findNearestNeigbours=function(t,e,i){var r=[],s=t.parent;if(s){var o=(t.gridX-s.gridX)/Math.max(Math.abs(t.gridX-s.gridX),1),a=(t.gridY-s.gridY)/Math.max(Math.abs(t.gridY-s.gridY),1);0!==o?(this.isWalkable(t.gridX,t.gridY-1,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX][t.gridY-1])&&r.push(e[t.gridX][t.gridY-1]),this.isWalkable(t.gridX,t.gridY+1,!0)&&this.sourceGridCollection.indexOf(e[t.gridX][t.gridY+1])&&r.push(e[t.gridX][t.gridY+1]),this.isWalkable(t.gridX+o,t.gridY,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX+o][t.gridY])&&r.push(e[t.gridX+o][t.gridY])):0!==a&&(this.isWalkable(t.gridX-1,t.gridY,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX-1][t.gridY])&&r.push(e[t.gridX-1][t.gridY]),this.isWalkable(t.gridX+1,t.gridY,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX+1][t.gridY])&&r.push(e[t.gridX+1][t.gridY]),this.isWalkable(t.gridX,t.gridY+a,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX][t.gridY+a])&&r.push(e[t.gridX][t.gridY+a]))}else this.neigbour(t,"top",r,i),this.neigbour(t,"right",r,i),this.neigbour(t,"bottom",r,i),this.neigbour(t,"left",r,i);return r},n.prototype.neigbour=function(t,e,i,r){for(var o,s=1;s>0;){var a="top"===e||"bottom"===e?t.gridX:"left"===e?t.gridX-s:t.gridX+s,l="right"===e||"left"===e?t.gridY:"top"===e?t.gridY-s:t.gridY+s;if((o=this.gridCollection[parseInt(a.toString(),10)][parseInt(l.toString(),10)])&&(r&&-1===this.sourceGridCollection.indexOf(o)||!r&&-1===this.targetGridCollection.indexOf(o)))return i&&this.isWalkable(a,l)&&i.push(o),s;if(!(a>0&&l>0))break;s++}return null},n.prototype.resetGridColl=function(t,e,i){for(var s,r=1;r>0;){var o="top"===e||"bottom"===e?t.gridX:"left"===e?t.gridX-r:t.gridX+r,a="right"===e||"left"===e?t.gridY:"top"===e?t.gridY-r:t.gridY+r;if((s=this.gridCollection[parseInt(o.toString(),10)][parseInt(a.toString(),10)])&&(i&&-1===this.sourceGridCollection.indexOf(s)||!i&&-1===this.targetGridCollection.indexOf(s))){if(this.isWalkable(o,a))break;var l=this.gridCollection[parseInt(o.toString(),10)][parseInt(a.toString(),10)];this.considerWalkable.push(l)}if(!(o>0&&a>0))break;"top"===e||"left"===e?r--:r++}return null},n.prototype.isWalkable=function(t,e,i){if(t>=0&&t=0&&e0?1:-1,this.isWalkable(h,c-1)&&!this.isWalkable(h-a,c-1)||this.isWalkable(h,c+1)&&!this.isWalkable(h-a,c+1)))return{x:t,y:e};if(0!==l){if(l=l>0?1:-1,this.isWalkable(h-1,c)&&!this.isWalkable(h-1,c-l)||this.isWalkable(h+1,c)&&!this.isWalkable(h+1,c-l))return{x:t,y:e};if(this.findIntermediatePoints(h+1,c,h,c,s,o)||this.findIntermediatePoints(h-1,c,h,c,s,o))return{x:t,y:e}}return this.findIntermediatePoints(h+a,c+l,h,c,s,o)},n.prototype.destroy=function(){},n.prototype.getModuleName=function(){return"LineRouting"},n}(),aae=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),hae=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return aae(t,n),function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);r>3&&s&&Object.defineProperty(t,e,s)}([I(!0)],t.prototype,"inversedAlignment",void 0),t}(Ee),cae=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Oe=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},TT=function(n,t,e,i){return new(e||(e=Promise))(function(r,s){function o(h){try{l(i.next(h))}catch(c){s(c)}}function a(h){try{l(i.throw(h))}catch(c){s(c)}}function l(h){h.done?r(h.value):new e(function(c){c(h.value)}).then(o,a)}l((i=i.apply(n,t||[])).next())})},AT=function(n,t){var i,r,s,o,e={label:0,sent:function(){if(1&s[0])throw s[1];return s[1]},trys:[],ops:[]};return o={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function a(h){return function(c){return function l(h){if(i)throw new TypeError("Generator is already executing.");for(;e;)try{if(i=1,r&&(s=2&h[0]?r.return:h[0]?r.throw||((s=r.return)&&s.call(r),0):r.next)&&!(s=s.call(r,h[1])).done)return s;switch(r=0,s&&(h=[2&h[0],s.value]),h[0]){case 0:case 1:s=h;break;case 4:return e.label++,{value:h[1],done:!1};case 5:e.label++,r=h[1],h=[0];continue;case 7:h=e.ops.pop(),e.trys.pop();continue;default:if(!(s=(s=e.trys).length>0&&s[s.length-1])&&(6===h[0]||2===h[0])){e=0;continue}if(3===h[0]&&(!s||h[1]>s[0]&&h[1]0&&((!s.style||!s.style.fill)&&(o.style.fill="transparent"),(!s.style||!s.style.strokeColor)&&(o.style.strokeColor="transparent")),s.shape&&"UmlActivity"===s.shape.type&&rb(s,o),s.shape&&"SwimLane"===s.shape.type&&pF(s,o),r.nodeDefaults&&Ro(o,s,r.nodeDefaults),r.updateAnnotationText(o.annotations);if(e&&e.connectors)for(a=0;e&&e.connectors&&a0&&0===i.nodes.length)this.clearCollection(),a=!0;else{for(var g=0,v=Object.keys(e.nodes);g0&&0===i.connectors.length)this.clearCollection(!0),a=!0;else{for(var C=0,D=Object.keys(e.connectors);C0){this.renderSelector(!0);break}if(e.selectedItems.constraints){this.renderSelector(!0);break}break;case"snapSettings":this.updateSnapSettings(e);break;case"commandManager":this.initCommands();break;case"layout":o=!0;break;case"segmentThumbShape":this.updateSelector();break;case"dataSourceSettings":this.clear(),"None"===this.layout.type?a=!0:(this.initObjects(),o=!0);break;case"tooltip":l3(this);break;case"rulerSettings":this.updateRulerSettings(e);break;case"layers":this.updateLayer(e);break;case"scrollSettings":this.scrollActions|=ca.PropertyChange,this.updateScrollSettings(e),this.scrollActions&=~ca.PropertyChange,this.scrollSettings.horizontalOffset=-this.scroller.horizontalOffset||0,this.scrollSettings.verticalOffset=-this.scroller.verticalOffset||0;break;case"locale":e.locale!==i.locale&&(this.realActions|=$i.PreventDataInit,n.prototype.refresh.call(this),this.realActions&=~$i.PreventDataInit);break;case"contextMenuSettings":if(void 0!==e.contextMenuSettings.showCustomMenuOnly&&(this.contextMenuSettings.showCustomMenuOnly=e.contextMenuSettings.showCustomMenuOnly),void 0!==e.contextMenuSettings.show&&(this.contextMenuSettings.show=e.contextMenuSettings.show),e.contextMenuSettings.items){for(var A=e.contextMenuSettings.items,x=0,R=Object.keys(A);x0){for(var N=[],T=O.ports.length-1;T>=0;T--)"LineDistribution"===O.ports[parseInt(T.toString(),10)].id.split("_")[1]&&N.push(O.ports[parseInt(T.toString(),10)]);this.removePorts(O,N)}}for(T=0;T0)for(var ue=0,pe=Object.keys(e.nodes);ue0)for(var De=0,xe=Object.keys(e.connectors);De=0;o--)this.commandHandler.expandNode(r[parseInt(o.toString(),10)],this,0!==o);this.canLayout&&this.doLayout(),this.lineRoutingModule?this.connectors.sourceID!==this.connectors.targetID&&this.lineRoutingModule.lineRouting(this):this.constraints&rt.LineRouting&&console.warn('[WARNING] :: Module "LineRouting" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),this.validatePageSize(),this.renderPageBreaks(),this.diagramRenderer.renderSvgGridlines(this.snapSettings,_d(this.element.id),this.scroller.transform,this.rulerSettings,this.hRuler,this.vRuler),this.commandHandler.initSelectorWrapper(),this.notify("initial-load",{}),this.trigger("load"),this.scroller.setSize(),this.scroller.updateScrollOffsets(),this.isRefreshed||this.refreshDiagramLayer(),(this.scrollSettings.verticalOffset>0||this.scrollSettings.horizontalOffset>0)&&this.updateScrollOffset(),X.isDevice&&(this.tool=Ci.ZoomPan|Ci.SingleSelect),this.notify("initial-end",{}),this.isProtectedOnChange=!1,this.tooltipObject=l3(this),this.diagramActions=ee.Render,this.initCommands();var a=document.getElementsByClassName(this.element.id+"_hiddenUserHandleTemplate");(function Noe(n,t,e,i){var r,s,o,a,l,d=document.getElementById(i).ej2_instances[0];if(n&&t){r=GF(n);for(var u=0,p=e.userHandles;u0;)e[0].parentNode.removeChild(e[0]);var i=document.getElementById(this.element.id+"content");i&&this.element.removeChild(i);var r="measureElement";if(window[""+r]){window[""+r].usageCount-=1;var s="measureElementCount";window[""+s]--,0===window[""+s]&&(window[""+r].parentNode.removeChild(window[""+r]),window[""+r]=null)}}window.domTable={};for(var a=0;a1&&(this.callBlazorModel=!1,this.insertBlazorDiagramObjects(this.selectedItems),this.commandHandler.group(),this.callBlazorModel=!0,this.commandHandler.getBlazorOldValues())},t.prototype.unGroup=function(){this.callBlazorModel=!1,this.insertBlazorDiagramObjects(this.selectedItems),this.commandHandler.unGroup(),this.callBlazorModel=!0,this.commandHandler.getBlazorOldValues()},t.prototype.sendToBack=function(){this.commandHandler.sendToBack()},t.prototype.setActiveLayer=function(e){var i=this.commandHandler.getLayer(e);this.activeLayer=i},t.prototype.addLayer=function(e,i){this.commandHandler.addLayer(e,i)},t.prototype.removeLayer=function(e){this.commandHandler.removeLayer(e,ce())},t.prototype.moveObjects=function(e,i){$(this.layers),this.enableServerDataBinding(!1),this.commandHandler.moveObjects(e,i)},t.prototype.layerObjectUpdate=function(){},t.prototype.sendLayerBackward=function(e){this.layerObjectUpdate(),this.commandHandler.sendLayerBackward(e)},t.prototype.bringLayerForward=function(e){this.layerObjectUpdate(),this.commandHandler.bringLayerForward(e)},t.prototype.cloneLayer=function(e){this.commandHandler.cloneLayer(e)},t.prototype.bringToFront=function(){this.commandHandler.bringToFront()},t.prototype.moveForward=function(){this.commandHandler.sendForward()},t.prototype.sendBackward=function(){this.commandHandler.sendBackward()},t.prototype.getObject=function(e){return this.nameTable[""+e]},t.prototype.getNodeObject=function(e){return $(this.nameTable[""+e])},t.prototype.getConnectorObject=function(e){return $(this.nameTable[""+e])},t.prototype.getActiveLayer=function(){return this.activeLayer},t.prototype.nudgeCommand=function(e,i,r){if("object"!=typeof e&&(this.selectedItems.nodes.length||this.selectedItems.connectors.length)>0){var s=void 0;i.type&&"KEYDOWN"===i.type&&(s=i.type),this.nudge(e,void 0,void 0,s)}},t.prototype.nudge=function(e,i,r,s){var o=0,a=0;"Left"===e||"Right"===e?o=("Left"===e?-1:1)*(i||1):a=("Up"===e?-1:1)*(r||1),"KEYDOWN"===s&&(o*=5,a*=5);var h=this.selectedItems,c=this.selectedItems.wrapper.children[0];if(c instanceof ni)this.commandHandler.labelDrag(h.nodes[0],c,o,a);else{var d=$(this.selectedItems);this.protectPropertyChange(!0),this.drag(h,o,a),this.protectPropertyChange(!1);var u={type:"PositionChanged",redoObject:$(this.selectedItems),undoObject:d,category:"Internal"};this.addHistoryEntry(u)}this.refreshCanvasLayers()},t.prototype.insertBlazorDiagramObjects=function(e){},t.prototype.drag=function(e,i,r){if(this.insertBlazorDiagramObjects(e),!(this.bpmnModule&&e instanceof te&&this.bpmnModule.updateAnnotationDrag(e,this,i,r))){if(e instanceof si){if(this.preventConnectorsUpdate=!0,e.nodes&&e.nodes.length){for(var o=0,a=e.nodes;o0&&o.nodes[0].children){this.fromUndo||(this.rotateUsingButton=!0);for(var h=this.commandHandler.getAllDescendants(o.nodes[0],[]),c=0;c0&&o.nodes[0].children){var g={type:"RotationChanged",redoObject:$(e),undoObject:$(o),category:"Internal",childTable:a};this.commandHandler.addHistoryEntry(g),this.commandHandler.updateSelector()}return u},t.prototype.dragSourceEnd=function(e,i,r){this.insertBlazorDiagramObjects(e),this.commandHandler.dragSourceEnd(e,i,r),this.callBlazorModel&&this.commandHandler.getBlazorOldValues()},t.prototype.dragTargetEnd=function(e,i,r){this.insertBlazorDiagramObjects(e),this.commandHandler.dragTargetEnd(e,i,r),this.callBlazorModel&&this.commandHandler.getBlazorOldValues()},t.prototype.findObjectsUnderMouse=function(e,i){return this.eventHandler.findObjectsUnderMouse(e,i)},t.prototype.findObjectUnderMouse=function(e,i,r){return this.eventHandler.findObjectUnderMouse(e,i,r)},t.prototype.findTargetObjectUnderMouse=function(e,i,r,s,o){return this.eventHandler.findTargetUnderMouse(e,i,r,s,o)},t.prototype.findElementUnderMouse=function(e,i,r,s){return this.eventHandler.findElementUnderMouse(e,i,r,s)},t.prototype.findActionToBeDone=function(e,i,r,s){return this.eventHandler.findActionToBeDone(e,i,r,s)},t.prototype.updateConnectorPort=function(e){if(e.ports.length)for(var i=void 0,r=0,s=e.ports;r=0;s--)if(i.push(r[parseInt(s.toString(),10)]),i.length>this.historyManager.stackLimit)return i}else i=r;return i},t.prototype.getEdges=function(e){return e.outEdge?this.nameTable[e.id].outEdges:this.nameTable[e.id].inEdges},t.prototype.getParentId=function(e){return this.nameTable[""+e].parentId},t.prototype.addConnector=function(e){return this.add(e)},t.prototype.UpdateBlazorDiagramModelCollection=function(e,i,r,s){},t.prototype.UpdateBlazorDiagramModel=function(e,i,r,s){},t.prototype.UpdateBlazorLabelOrPortObjects=function(e,i,r,s){},t.prototype.addBlazorDiagramObjects=function(){},t.prototype.removeNodeEdges=function(e,i,r){var s=this.nameTable[""+e],o=r?s.outEdges:s.inEdges;if(o.length>0)for(var a=0;a0)){for(var c=0;c0))}this.removePortEdges(l,a.element.sourcePortID,a.element.id,h)}a.element.targetID&&this.removeNodeEdges(a.element.targetID,a.element.id,!1)}}this.diagramActions=this.diagramActions|ee.PublicMethod,e.id=e.id||Qe();var u=this.activeLayer;if(!a.cancel&&u&&!u.lock){if(u.objects.indexOf(e.id)<0&&!u.lock&&(u.visible||(u.visible=!0,this.dataBind()),u.objects.push(e.id)),fs(e)===de)(r=new de(this,"connectors",e,!0)).status="New",this.nameTable[r.targetID]&&"TextAnnotation"===this.nameTable[r.targetID].shape.shape&&(r.isBpmnAnnotationConnector=!0,r.constraints=r.constraints&~qe.Delete),Ro(r,e,this.connectorDefaults),this.connectors.push(r),this.initObject(r),!1===e.visible&&this.updateElementVisibility(r.wrapper,r,e.visible),this.updateEdges(r),this.insertBlazorConnector(r);else{if(Ro(r=new te(this,"nodes",e,!0),e,this.nodeDefaults),r.parentId=e.parentId?e.parentId:r.parentId,r.umlIndex=e.umlIndex,r.status="New",(o="TextAnnotation"===r.shape.shape)&&!e.isTextAnnotationCopied&&(r.inEdges=e.inEdges?e.inEdges:r.inEdges),this.nodes.push(r),this.initObject(r,u,void 0,i),o&&this.bpmnModule)for(c=0;c-1&&e.parentId&&this.nameTable[e.parentId]&&"UmlClassifier"===this.nameTable[e.parentId].shape.type){var g=this.nameTable[e.parentId];g.children.splice(r.umlIndex,0,r.id),g.wrapper.children.splice(r.umlIndex,0,r.wrapper),g.wrapper.measure(new me),g.wrapper.arrange(g.wrapper.desiredSize),this.updateDiagramObject(g)}}if(a={element:r,cause:this.diagramActions,diagramAction:this.getDiagramAction(this.diagramActions),state:"Changed",type:"Addition",cancel:!1},this.parentObject&&(a.parentId=this.parentObject.id),"helper"!==e.id&&!(this.diagramActions&ee.PreventCollectionChangeOnDragOver)&&this.triggerEvent(Ce.collectionChange,a),!(this.diagramActions&ee.UndoRedo||this.diagramActions&ee.Group||this.diagramActions&ee.PreventHistory)){var v={type:"CollectionChanged",changeType:"Insert",undoObject:$(e),redoObject:$(e),category:"Internal"};this.addHistoryEntry(v)}this.parentObject=void 0,"SVG"===this.mode&&(this.updateSvgNodes(r),this.updateTextElementValue(r),this.updateDiagramObject(r),o&&this.updateDiagramObject(this.nameTable[r.inEdges[0]]),r.shape.activity&&r.shape.activity.subProcess.processes&&r.shape.activity.subProcess.processes.length&&this.updateProcesses(r),this.updateBridging())}}if(this.protectPropertyChange(s),this.resetDiagramActions(ee.PublicMethod),r&&this.layers.length>1&&this.moveNode(r),this.views)for(var S=0,b=this.views;S=0;l--)this.moveSvgNode(a[parseInt(l.toString(),10)])}for(var h=0,c=i;h=0;o--)r[parseInt(o.toString(),10)]===e.id&&r.splice(o,1);for(var a=0;s.ports&&a=0;s--)if(i=this.nameTable[r[parseInt(s.toString(),10)]])if(this.connectorTable[i.id]=$(i),i.isBpmnAnnotationConnector){var o=this.nameTable[i.targetID];this.removeObjectsFromLayer(i);var a=this.connectors.indexOf(i);-1!==a&&this.connectors.splice(a,1),this.removeElements(i),this.removeFromAQuad(i),delete this.nameTable[i.id];var l=this.nameTable[i.sourceID];if(l){var h=l.outEdges.indexOf(i.id);-1!==h&&l.outEdges.splice(h,1)}e.id!==i.targetID&&this.remove(o)}else this.remove(i)},t.prototype.removeObjectsFromLayer=function(e){if(e.children)for(var i=0;i-1&&(_r(this,e)&&this.unSelect(e),this.layers[parseInt(s.toString(),10)].objects.splice(a,1),delete this.layers[parseInt(s.toString(),10)].zIndexTable[this.nameTable[e.id].zIndex])},t.prototype.removeElements=function(e){if("SVG"===this.mode||"Canvas"===this.mode&&"Native"===e.shape.type){var i=xt(e.id+"_groupElement",this.element.id),r=e;if(r.ports&&r.ports.length>0)for(var s=0;s0){l[parseInt(s.toString(),10)].id.indexOf("icon_content")>0&&"SVG"===this.mode&&((h=xt(l[parseInt(s.toString(),10)].id+"_shape_groupElement",this.element.id))&&h.parentNode.removeChild(h),(h=xt(l[parseInt(s.toString(),10)].id+"_rect_groupElement",this.element.id))&&h.parentNode.removeChild(h));for(var c=0,d=this.views;c=0;o--)a.children[parseInt(o.toString(),10)].children&&(l=n.nameTable[a.children[parseInt(o.toString(),10)].id])&&(l.isLane?Zv(n,l):(n.removeDependentConnector(l),n.diagramActions|=ee.PreventHistory,l.constraints&ie.Delete?n.remove(l):q3(n,l,{},!1),n.diagramActions&=~ee.PreventHistory));a&&(i=n.nameTable[a.id])&&Zv(n,i)}}(this,e),!(this.diagramActions&ee.UndoRedo||this.diagramActions&ee.PreventHistory)&&(e instanceof te||e instanceof de)){var o={type:"CollectionChanged",changeType:"Remove",undoObject:$(e),redoObject:$(e),category:"Internal"};this.diagramActions&ee.Clear||e.children&&!e.isLane&&!e.isPhase&&e.children.length>0&&this.undoRedoModule&&"None"===this.layout.type&&(this.historyManager.startGroupAction(),s=!0),(e instanceof te||e instanceof de)&&this.deleteDependentConnector&&this.removeDependentConnector(e),!e.isLane&&!e.isPhase&&!(this.diagramActions&ee.Clear)&&!this.isStackChild(e)&&this.addHistoryEntry(o)}"TextAnnotation"===e.shape.shape&&this.removeDependentConnector(e),e.children&&!e.isLane&&!e.isPhase&&(!(this.diagramActions&ee.UndoRedo)||!ce())&&this.deleteGroup(e),e.parentId&&(this.deleteChild(e,void 0,!0),this.nameTable[e.parentId]&&"UmlClassifier"===this.nameTable[e.parentId].shape.type&&(this.updateDiagramObject(this.nameTable[e.parentId]),this.updateConnectorEdges(this.nameTable[e.parentId])));var a=void 0;this.diagramActions=this.diagramActions|ee.PublicMethod;var l=this.nameTable[e.id];if(l instanceof te?("Bpmn"===l.shape.type&&this.bpmnModule&&this.bpmnModule.removeBpmnProcesses(l,this),(l.isLane||l.isPhase||"SwimLane"===l.shape.type)&&(h=l.isLane||l.isPhase?this.nameTable[l.parentId]:this.nameTable[l.id],l.isLane?Q3(this,l,h):l.isPhase&&G3(this,l,h)),-1!==(a=this.nodes.indexOf(l))&&(this.crudDeleteNodes.push(this.nameTable[l.id]),this.nodes.splice(a,1),this.updateNodeEdges(l))):(-1!==(a=this.connectors.indexOf(l))&&(this.crudDeleteNodes.push(this.nameTable[l.id]),this.connectors.splice(a,1)),this.updateEdges(l),this.spliceConnectorEdges(e,!0),this.spliceConnectorEdges(e,!1)),!this.isServerUpdate&&!(this.blazorActions&on.GroupClipboardInProcess)&&this.commandHandler.getBlazorOldValues(),s&&this.historyManager.endGroupAction(),_r(this,l)&&this.unSelect(l),!l.isPhase){if(this.removeObjectsFromLayer(e),this.currentDrawingObject&&(this.currentDrawingObject.wrapper=void 0),delete this.nameTable[e.id],i.length>0&&i[0].id===l.id&&l.parentId){var h,d=this.nameTable[l.parentId];d&&d.isLane&&"SwimLane"===this.nameTable[d.parentId].shape.type&&Y3(this,h=this.nameTable[d.parentId],d,l)}this.removeElements(l),this.updateBridging(),"SVG"!==this.mode&&this.refreshDiagramLayer(),this.diagramActions&ee.Clear||(this.removeFromAQuad(l),r={element:e,cause:this.diagramActions,diagramAction:this.getDiagramAction(this.diagramActions),state:"Changed",type:"Removal",cancel:!1},"helper"!==e.id&&this.triggerEvent(Ce.collectionChange,r),this.resetTool())}}}else if(i.length>0){this.undoRedoModule&&(this.historyManager.startGroupAction(),this.blazorActions|=on.GroupingInProgress,s=!0);for(var u=0;u=f.wrapper.bounds.width&&"Horizontal"===f.shape.orientation||this.selectedItems.wrapper.bounds.y<=f.wrapper.bounds.y+g&&this.selectedItems.wrapper.bounds.height>=f.wrapper.bounds.height-g&&"Vertical"===f.shape.orientation)&&(OI(f)||f.shape.lanes.length>1)&&this.remove(i[parseInt(u.toString(),10)])}}else this.remove(i[parseInt(u.toString(),10)])}s&&(this.blazorActions&=~on.GroupingInProgress,this.isServerUpdate=!0,this.commandHandler.getBlazorOldValues(),this.UpdateBlazorDiagramModelCollection(void 0,void 0,void 0,!0),this.historyManager.endGroupAction(),this.isServerUpdate=!1),this.clearSelection()}e&&(OI(e)||this.diagramActions&ee.Clear)||this.diagramActions&ee.UndoRedo||this.diagramActions&ee.PreventHistory||!(e instanceof te||e instanceof de)||(o={type:"ConnectionChanged",undoObject:$(e),redoObject:$(e),category:"Internal"},!e.isLane&&!e.isPhase&&!(this.diagramActions&ee.Clear)&&!this.isStackChild(e)&&this.addHistoryEntry(o)),this.tooltipObject.close()},t.prototype.isStackChild=function(e){var i,r=this.nameTable[e.parentId];if(e&&e.parentId&&r.container&&"Stack"===r.container.type&&"UmlClassifier"!==this.nameTable[e.parentId].shape.type){i=!0;var s={sourceIndex:r.wrapper.children.indexOf(e.wrapper),source:e,target:void 0,targetIndex:void 0};this.diagramActions&ee.UndoRedo||this.addHistoryEntry({type:"StackChildPositionChanged",redoObject:{sourceIndex:void 0,source:e,target:void 0,targetIndex:void 0},undoObject:s,category:"Internal"})}return i},t.prototype.deleteChild=function(e,i,r){var s;if(s="string"==typeof e?e:e.id,(i=i?this.nameTable[i.id]:this.nameTable[e.parentId])&&i.children){for(var o=0;o=0;i--)this.removeLayer(this.layers[parseInt(i.toString(),10)].id);this.commandHandler.addLayer({id:"default_layer",visible:!0,lock:!1,objects:[],zIndex:0,objectZIndex:-1,zIndexTable:{}},null,!0),this.setActiveLayer(this.layers[this.layers.length-1].id)},t.prototype.clearObjects=function(e){var i=[];i=e||(i=i.concat(this.nodes)).concat(this.connectors),this.diagramActions=this.diagramActions|ee.Clear;for(var r=0,s=i;r0||"Text"===e.shape.type))if("Text"===e.shape.type)i=e.wrapper.children[0].id.split("_")[1];else for(var f=e.annotations.length-1;f>=0;f--)e.annotations[parseInt(f.toString(),10)].visibility&&(i=e.annotations[parseInt(f.toString(),10)].id);i&&(u=this.getWrapper(e.wrapper,i))}if(e&&u&&!(u instanceof Jn)&&(!function sne(n,t){return"Text"===t.shape.type?t.constraints&ie.ReadOnly:t.constraints&(t instanceof de?qe.ReadOnly:ie.ReadOnly)?n.constraints&Lr.InheritReadOnly?1:0:n.constraints&Lr.ReadOnly?1:0}(u,e)||p)){var g=u.style,v=void 0;v=90>(v=u.bounds.width50?50:e.width,u.style.fontSize)),e.parentId&&"UmlClassifier"===this.nameTable[e.parentId].shape.type?(l.width=e.wrapper.bounds.width-20,c=(e.wrapper.bounds.center.x+r.tx)*r.scale-l.width/2*s-2.5,d=(e.wrapper.bounds.center.y+r.ty)*r.scale-l.height/2*s-3,u.style.textAlign="Left"):(l.width=Math.max(l.width,50),c=(u.bounds.center.x+r.tx)*r.scale-l.width/2*s-2.5,d=(u.bounds.center.y+r.ty)*r.scale-l.height/2*s-3),Ho(y,{id:this.element.id+"_editTextBoxDiv",style:"position: absolute;left:"+c+"px;top:"+d+"px;width:"+(l.width+1)*s+"px;height:"+l.height*s+"px; containerName:"+e.id+";"}),Ho(S,{"aria-label":a,id:this.element.id+"_editBox",style:"width:"+(l.width+1)*s+"px;height:"+l.height*s+"px;resize: none;outline: none;overflow: hidden;;font-family:"+g.fontFamily+";font-size:"+g.fontSize*s+"px;text-align:"+u.style.textAlign.toLocaleLowerCase()+";",class:"e-diagram-text-edit"}),S.style.fontWeight=g.bold?"bold":"",S.style.fontStyle=g.italic?"italic":"",S.style.lineHeight=(1.2*g.fontSize+"px;").toString(),S.style.textDecoration=g.textDecoration?g.textDecoration:"",this.activeLabel.parentId=e.id,this.activeLabel.id=i,u.visible=!1,this.updateDiagramObject(e),this.diagramActions=this.diagramActions|ee.TextEdit,this.isTriggerEvent||(E.add(S,"input",this.eventHandler.inputChange,this.eventHandler),E.add(S,"focusout",this.focusOutEdit,this),S.select())}}}},t.prototype.updateConnectorfixedUserHandles=function(e){if(e.fixedUserHandles.length)for(var i=void 0,r=0,s=e.fixedUserHandles;r0&&this.mindMapChartModule.updateLayout(o,this.nameTable,this.layout,l,this.dataSourceSettings.id,this.dataSourceSettings.root),e=!0;else if(this.radialTreeModule)this.radialTreeModule.updateLayout(o,this.nameTable,this.layout,l),e=!0;else if(this.symmetricalLayoutModule)this.symmetricalLayoutModule.maxIteration=this.layout.maxIteration,this.symmetricalLayoutModule.springLength=this.layout.springLength,this.symmetricalLayoutModule.springFactor=this.layout.springFactor,this.symmetricalLayoutModule.updateLayout(o,this.connectors,this.symmetricalLayoutModule,this.nameTable,this.layout,l),e=!0;else if(this.complexHierarchicalTreeModule){this.canDistribute(a,r)&&(this.lineDistributionModule.diagram=this,this.connectors.forEach(function(R){R.obstaclePointCollection=[]}));var c=this.complexHierarchicalTreeModule.getLayoutNodesCollection(this.nodes);c.length>0&&this.complexHierarchicalTreeModule.doLayout(c,this.nameTable,this.layout,l,this),e=!0,this.canDistribute(a,r)&&this.lineDistributionModule.initLineDistribution(this.layout,this)}else this.flowchartLayoutModule?(this.flowchartLayoutModule.updateLayout(this.nodes,this),e=!0):console.warn("[WARNING] :: Module "+("OrganizationalChart"===this.layout.type?"HierarchicalTree":this.layout.type)+" is not available in Diagram component! You either misspelled the module name or forgot to load it.");if(e){this.preventDiagramUpdate=!0;for(var u={},f=0,g=o;f0)for(var S=0;S0)for(var M=0;M0)for(var s=0,o=r.ports;s0&&function Rse(n){var t,e,i,r=[];for(t=0;t0&&y.connectors[w].bezierSettings&&y.connectors[w].bezierSettings.allowSegmentsReset&&(y.connectors[w].segments=[]);if(t.connectors=y.connectors||[],t.dataSourceSettings=y.dataSourceSettings||{},t.dataSourceSettings.doBinding=i,t.height=y.height||"100%",t.setNodeTemplate=r,t.getConnectorDefaults=v,t.getNodeDefaults=g,t.getCustomProperty=o,t.mode=y.mode||"SVG",y.nodes)for(w=0;w0)){var r=this.nodes.filter(function(a){return 0===a.inEdges.length})[0],s=this.convertMindmapToMermaid(r,0);i.push(s),this.updateTextDataSource(i,r.outEdges,1),e=(i=i.filter(function(a){return""!==a.trim()})).join("\n")}return e},t.prototype.updateTextDataSource=function(e,i,r){for(var s=0;s0&&this.updateTextDataSource(e,h,r+1),s++}},t.prototype.convertMindmapToMermaid=function(e,i){var r=e.id,o=" ".repeat(2*(i+1)),a=e.annotations.length>0?e.annotations[0].content.replace(/\n/g," "):"",l=o+a,h=o+r;if(e.shape&&"Basic"===e.shape.type){var c=e.shape;"Rectangle"===c.shape?l=h+"["+a+"]":"Ellipse"===c.shape?l=h+"(("+a+"))":"Hexagon"===c.shape&&(l=h+"{{"+a+"}}")}else if(e.shape&&"Flow"===e.shape.type)"Terminator"===e.shape.shape&&(l=h+"("+a+")");else if(e.shape&&"Path"===e.shape.type){var u=e.shape;u.data===this.bangShape?l=h+"))"+a+"((":u.data===this.cloudShape&&(l=h+")"+a+"(")}return l},t.prototype.saveFlowDiagramInMermaidFormat=function(){var e=this,i=[],r="graph TD\n",s={nodes:this.nodes,edges:this.connectors};return s.nodes.reduce(function(a,l){return a[l.id]=l.annotations.length?l.annotations[0].content:"",a},{}),s.edges.forEach(function(a){var l=a.sourceID,h=a.targetID,p=e.nameTable[""+h],f=e.getNodeShape(e.nameTable[""+l]),g=e.getNodeShape(p),v=a.annotations[0]&&""!==a.annotations[0].content?"|"+a.annotations[0].content+"|":"";-1===i.indexOf(l)?i.push(l):f="",-1===i.indexOf(h)?i.push(h):g="";var y=e.arrowType(a);r+=" "+l+f+" "+y+v+" "+h+g+"\n"}),s.nodes.forEach(function(a){r+=" style "+a.id+" fill:"+a.style.fill+",stroke:"+a.style.strokeColor+",stroke-width:"+a.style.strokeWidth+"px;\n"}),r},t.prototype.arrowType=function(e){var i=e.targetDecorator.shape;return e.style.opacity<1?"~~~":""!==e.style.strokeDashArray?"-.->":"Arrow"===i?e.style.strokeWidth>1?"==>":"--\x3e":"None"===i?"---":"--\x3e"},t.prototype.getNodeShape=function(e){var i=e.annotations.length>0?e.annotations[0].content:"",r=e.shape.shape;if(!r){var s=e.shape.data;return"M 0 0 A 1 1 0 0 0 7 0 A 1 1 0 0 0 0 0 M -1 0 A 1 1 0 0 0 8 0 A 1 1 0 0 0 -1 0"===s?"((("+i+")))":"M 0 0 L 1 -1 L 5 -1 L 6 0 L 0 0"===s?"[/"+i+"\\]":"M 0 1 L 0 6 C 2 7 4 7 6 6 L 6 1 C 5 0 1 0 0 1 C 1 2 5 2 6 1"===s?"[("+i+")]":"M 0 0 L 12 0 L 14 2 L 2 2 L 0 0"===s?"[\\"+i+"\\]":"M 0 0 L 5 0 L 4 1 L 1 1 L 0 0"===s?"[\\"+i+"/]":"M 0 0 L 2 -2 L 11 -2 L 13 0 L 11 2 L 2 2 L 0 0"===s?"{{"+i+"}}":">"+i+"]"}switch(r){case"Terminator":return"(["+i+"])";case"Process":default:return"["+i+"]";case"Decision":return"{"+i+"}";case"Parallelogram":return"[/"+i+"/]";case"Ellipse":return"(("+i+"))";case"PreDefinedProcess":return"[["+i+"]]"}},t.prototype.loadDiagramFromMermaid=function(e){this.layout&&"Flowchart"===this.layout.type&&this.flowchartLayoutModule?this.convertMermaidToFlowChart(e):this.layout&&"MindMap"===this.layout.type&&this.mindMapChartModule?this.convertMermaidToMindmap(e):console.warn('[WARNING] :: Module "FlowchartLayout" or "MindMap" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.countLeadingSpaces=function(e){for(var i=0,r=e.length;i0});this.clear(),this.mermaidNodeBaseCollection=[];var r=[],s={text:"",children:[],currentLevel:0,branch:"Left"},o=[],l=!1,h=!1,c=!1;if(i.length>0){for(var d=function(M){var w=i[parseInt(M.toString(),10)],C=0,D="",A=u.countLeadingSpaces(w),x=w.includes('"`');if(h=w.includes('`"'),c=(l=!!x||l)||c?c:0===A&&M>0,l&&h&&!x)return s.text+="\n"+w,l=!1,"continue";if(!x&&l)return s.text+="\n"+w,"continue";if(l=!h&&l,w.length>0&&(/\s/.test(w[0])&&M>0||0===A)){if(-1!==o.findIndex(function(B){return B.space===A.toString()}))for(var L=o.length-1;L>=0;L--){var O=o[parseInt(L.toString(),10)];if((N=parseFloat(O.space))>A)o.splice(L,1);else{if(N=0;L--){var N,T=o[parseInt(L.toString(),10)];if(!((N=parseFloat(T.space))>A)){var P=o[o.length-1];o.push({space:A.toString(),level:P.level+1});break}o.splice(L,1)}C=o[o.length-1].level}D=w.trim().replace(/^[+-]/,"")}var _={text:D,branch:void 0,children:[],currentLevel:0===M?0:C-1};if(r.length>0){for(;r.length>=C&&0!==r.length;)r.pop();r.length>0&&r[r.length-1].children.push(_)}r.push(_),s=_},u=this,p=0;p0){var c=h[h.length-1];c.arrowType=a[2],""!==a[3]&&(c.label&&c.label.some(function(d){return d.trim().length>0})?c.label.push(a[3]):(c.label=[],c.label[c.parentId.length-1]=a[3]))}h.filter(function(d){return d.parentId&&0===d.parentId.length}).forEach(function(d){d.parentId=null}),i=i.concat(h)}}this.createFlowChart(i),this.doLayout(),this.clearHistory()},t.prototype.createFlowChart=function(e){for(var i=[],r=0;r1)for(var h=0;h|---|--\s*.*?\s*-->|~~~|==>|===|==\s*.*?\s*==>|\s*-\.\s*->|\s*-\.\s*-|\s*-\.\s*.*?\s*\.\s*->|\s*-\..*?\.\s*->)(.*)$/);if(l){i=l[1].trim();var h=l[2].trim();r=l[3].trim();var d=h.match(/(-\.|\\-\\-|==|--|~~)(.*?)(\1>|\.->|==>|\\->|~~>)/),u=void 0,p="";o=null!==(u=d?{text:d[2].trim()||null,arrowType:d[1]+d[3]}:{text:null,arrowType:h}).text?u.text:"",s=(p=u.arrowType).includes("--\x3e")?"single-line-arrow":p.includes("---")?"single-line":p.includes("==>")?"double-line-arrow":p.includes("==")?"double-line":p.includes("~~~")?"wiggly-arrow":p.includes("-.->")||p.includes(".->")?"dotted-arrow":p.includes("-.-")||p.includes(".-")?"dotted":"single-line-arrow"}return[i,r,s,o]},t.prototype.parseStyle=function(e,i){if(e.startsWith("style")){var s=e.match(/^style\s+(\w+)\s+fill:([^,]+),stroke:([^,]+),stroke-width:(\d+)px;/);if(s){var c={id:s[1],fill:s[2],stroke:s[3],strokeWidth:parseInt(s[4],10)},d=i.filter(function(u){return u.id===c.id});d[0].color=c.fill,d[0].stroke=c.stroke,d[0].strokeWidth=c.strokeWidth}}},t.prototype.getNodeData=function(e,i,r){for(var s=[],o=null,a=null,l=0,h="",c=function(v){var y=e[parseInt(v.toString(),10)],S=d.splitNested(y);if(S[0].includes("|")){var b=S[0].match(/\|([^|]*)\|/);b&&(h=b[1]);var M=S[0].split("|");M.length>=3&&(S[0]=M[2].trim())}var w=S[0].trim();if(0===v?o=w:a=w,i.find(function(L){return L.id===w}))l++;else{var D=S.length>1?S[1]:S[0],A=d.getShape(D),x=D.replace(/[\\[\]\\(\\)\\{\\}\\{\\}\\/>]/g,"");s.push({id:w,name:x,shape:A,color:"white",parentId:[]})}},d=this,u=0;u"===h?0===s?(r.trim().length>0&&i.push(r.trim()),r=h,o=h,s++):(r+=h,s++):"]"===h||"}"===h||")"===h?1===s&&h===o?(i.push((r+=h).trim()),r="",s--):s>1?(r+=h,s--):r+=h:r+=h}return r.trim().length>0&&i.push(r.trim()),i},t.prototype.getShape=function(e){var i={};return e.startsWith("(((")?i={type:"Path",data:"M 0 0 A 1 1 0 0 0 7 0 A 1 1 0 0 0 0 0 M -1 0 A 1 1 0 0 0 8 0 A 1 1 0 0 0 -1 0"}:e.startsWith("((")?i={shape:"Ellipse",type:"Basic"}:e.startsWith("([")?i={type:"Flow",shape:"Terminator"}:e.startsWith("(")?i={type:"Flow",shape:"Process"}:e.startsWith("[[")?i={type:"Flow",shape:"PreDefinedProcess"}:e.startsWith("[/")?i=e.endsWith("/]")?{type:"Basic",shape:"Parallelogram"}:{type:"Path",data:"M 0 0 L 1 -1 L 5 -1 L 6 0 L 0 0"}:e.startsWith("[(")?i={type:"Path",data:"M 0 1 L 0 6 C 2 7 4 7 6 6 L 6 1 C 5 0 1 0 0 1 C 1 2 5 2 6 1"}:e.startsWith("[\\")?i=e.endsWith("\\]")?{type:"Path",data:"M 0 0 L 12 0 L 14 2 L 2 2 L 0 0"}:{type:"Path",data:"M 0 0 L 5 0 L 4 1 L 1 1 L 0 0"}:e.startsWith("[")?i={type:"Basic",shape:"Rectangle"}:e.startsWith("{{")?i={type:"Path",data:"M 0 0 L 2 -2 L 11 -2 L 13 0 L 11 2 L 2 2 L 0 0"}:e.startsWith("{")?i={type:"Flow",shape:"Decision"}:e.startsWith(">")&&(i={type:"Path",data:"M 0 0 L 8 0 L 8 2 L 0 2 L 2 1 L 0 0"}),i},t.prototype.getDiagramContent=function(e){return this.printandExportModule?this.printandExportModule.getDiagramContent(e):(console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),"")},t.prototype.exportImage=function(e,i){this.printandExportModule?this.printandExportModule.exportImages(e,i):console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.printImage=function(e,i){this.printandExportModule?(i.printOptions=!0,this.printandExportModule.exportImages(e,i)):console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.setStackLimit=function(e){this.undoRedoModule&&e&&(this.historyManager.stackLimit=e,this.undoRedoModule.applyLimit(this.historyManager.currentEntry,e,this,!0))},t.prototype.clearHistory=function(){this.undoRedoModule&&this.undoRedoModule.clearHistory(this)},t.prototype.getDiagramBounds=function(){if(this.printandExportModule){var e=this.printandExportModule.getDiagramBounds("",{});return e.width=e.width>this.scrollSettings.viewPortWidth?e.width+(e.x>0?e.x:0):this.scrollSettings.viewPortWidth,e.height=e.height>this.scrollSettings.viewPortHeight?e.height+(e.y>0?e.y:0):this.scrollSettings.viewPortHeight,e.x=e.x>0?0:e.x,e.y=e.y>0?0:e.y,e}return console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),new Ne},t.prototype.exportDiagram=function(e){return this.printandExportModule?this.printandExportModule.exportDiagram(e):(console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),"")},t.prototype.print=function(e){this.printandExportModule?this.printandExportModule.print(e):console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.addPorts=function(e,i){var s;this.protectPropertyChange(!0),e=this.nameTable[e.id]||e,i.length>1&&this.startGroupAction();for(var o=function(h){if(e.ports.some(function(y){return y.id===i[parseInt(h.toString(),10)].id}))return"continue";if(e instanceof te?(s=new Es(e,"ports",i[parseInt(h.toString(),10)],!0),e.ports.push(s)):e instanceof de&&(s=new Ac(e,"ports",i[parseInt(h.toString(),10)],!0),e.ports.push(s)),e.children)for(var c=e.wrapper,d=0;d1&&this.endGroupAction(),e.wrapper.measure(new me(e.width,e.height)),e.wrapper.arrange(e.wrapper.desiredSize),this.updateDiagramObject(e),this.protectPropertyChange(!1)},t.prototype.addConstraints=function(e,i){return e|i},t.prototype.removeConstraints=function(e,i){return e&~i},t.prototype.addNodeLabels=function(e,i){this.addLabels(e,i)},t.prototype.addConnectorLabels=function(e,i){this.addLabels(e,i)},t.prototype.addLabels=function(e,i){this.protectPropertyChange(!0);var s,r=(e=this.nameTable[e.id]||e).wrapper;i.length>1&&this.startGroupAction();for(var o=0;o1&&this.endGroupAction(),e.wrapper.measure(new me(r.width,r.height)),e.wrapper.arrange(r.desiredSize),this.updateDiagramObject(e),this.protectPropertyChange(!1),this.refreshCanvasLayers()},t.prototype.addChildToUmlNode=function(e,i,r){var s,o,a,l,h="NoWrap";"Class"===e.shape.classifier||"Interface"===e.shape.classifier?"Method"===r?(o=new dm(e,"",i),"Class"===e.shape.classifier?(e.shape.classShape.methods.push(o),s=e.shape.classShape):"Interface"===e.shape.classifier&&(e.shape.interfaceShape.methods.push(o),s=e.shape.interfaceShape),function soe(n,t,e,i){if(e.methods&&e.methods.length){var r=e.methods,s="",o="",a=void 0,l=1,h=void 0,c=0,d=0,u=n.shape,g="Class"===u.classifier?u.classShape:u.interfaceShape;1===r.length?g.attributes.length>0?(c=g.attributes.filter(function(w){return w.isSeparator}).length,h=(l=2+g.attributes.length+c)+1,lT(n,t,l)):h=l+1:(c=g.attributes.filter(function(w){return w.isSeparator}).length,d=g.methods.filter(function(w){return w.isSeparator}).length,h=(l=2+g.attributes.length+c+g.methods.length+d)+1);for(var v=0;v1&&this.startGroupAction();for(var r=i.length-1;r>=0;r--)if(e.children&&e.children.length>0){var s=e.wrapper.children.filter(function(o){return o.id===e.id+"group_container"});s&&s.length>0&&this.removelabelExtension(e,i,r,s[0])}else this.removelabelExtension(e,i,r,e.wrapper);i.length>1&&this.endGroupAction(),this.refreshCanvasLayers()},t.prototype.removePortsExtenion=function(e,i,r,s){for(var o=0;o1&&this.startGroupAction();for(var r=i.length-1;r>=0;r--)if(e.children&&e.children.length>0)for(var s=0;s1&&this.endGroupAction()},t.prototype.getSizeValue=function(e,i){var r;return r=e.toString().indexOf("px")>0?e.toString():e.toString().indexOf("%")>0?void 0!==i?"100%":e.toString():e.toString()+"px",i&&(qa(this),r="calc("+r+" - "+i+"px)"),r},t.prototype.renderRulers=function(){this.rulerSettings.showRulers?(function ise(n){var t=qa(n),i=Tt("div",{id:n.element.id+"_overlapRuler",style:"height:"+t.height+"px;width:"+t.width+"px;position:absolute;left:0;top:0",class:"e-ruler-overlap"});n.element.insertBefore(i,n.element.firstChild)}(this),oF(this,!0),oF(this,!1)):$x(this)},t.prototype.intOffPageBackground=function(){var e=new me;e=qa(this);var i=document.getElementById(this.element.id+"content"),r=this.getSizeValue(this.width,e.width),s=this.getSizeValue(this.height,e.height),o=this.rulerSettings.showRulers?"width:"+r+"; height:"+s+";top:"+e.height+"px;left:"+e.width+"px;overflow: scroll;position:absolute;overflow:auto;":"width:"+r+"; height:"+s+";position:absolute; left:0px; top:0px;overflow: auto;",a={id:this.element.id+"content",tabindex:"0",style:o};i?(this.diagramCanvas=i,Za(this.diagramCanvas,o)):(this.diagramCanvas=Tt("div",a),this.element.appendChild(this.diagramCanvas)),this.diagramCanvas.style.background=this.backgroundColor},t.prototype.initDiagram=function(){this.intOffPageBackground(),Ho(this.element,{style:"width:"+this.getSizeValue(this.width)+"; height:"+this.getSizeValue(this.height)+";position:relative;overflow:hidden;"})},t.prototype.renderHiddenUserHandleTemplateLayer=function(e){var r=Tt("div",{class:this.element.id+"_hiddenUserHandleTemplate",style:"width:"+e.width+"px; height:"+e.height+"px;visibility:hidden ; overflow: hidden;"});this.element.appendChild(r)},t.prototype.renderBackgroundLayer=function(e,i){var r=this.createSvg(this.element.id+"_backgroundLayer_svg",e.width,e.height);Za(r,i);var s=Bi("g",{id:this.element.id+"_backgroundImageLayer",class:"e-background-image-layer"});r.appendChild(s);var a=Bi("g",{id:this.element.id+"_backgroundLayer",class:"e-background-layer"});r.appendChild(a),this.diagramCanvas.appendChild(r)},t.prototype.renderGridLayer=function(e,i){var r=this.createSvg(this.element.id+"_gridline_svg",e.width,e.height);r.setAttribute("class","e-grid-layer");var s=Bi("g",{id:this.element.id+"_gridline"}),o=Bi("rect",{id:this.element.id+"_grid_rect",x:"0",y:"0",width:"100%",height:"100%"});if(om()){var a=new URL(window.location.href);o.setAttribute("fill",""!==a.search?"url(#"+this.element.id+"_pattern)":"url("+location.protocol+"//"+location.host+location.pathname+"#"+this.element.id+"_pattern)")}else o.setAttribute("fill","url(#"+this.element.id+"_pattern)");s.appendChild(o),r.appendChild(s),this.diagramCanvas.appendChild(r),oi(r,{style:i})},t.prototype.renderDiagramLayer=function(e,i){if(this.diagramLayerDiv=Tt("div",{id:this.element.id+"_diagramLayer_div",style:"width:"+e.width+"px; height:"+e.height+"px;"+i}),"SVG"===this.mode){var s=this.createSvg(this.element.id+"_diagramLayer_svg",e.width,e.height);s.style["pointer-events"]="none",s.setAttribute("class","e-diagram-layer");var o=Bi("g",{id:this.element.id+"_diagramLayer"}),a=Bi("g",{});this.diagramLayer=o,s.style["pointer-events"]="all",a.appendChild(o),s.appendChild(a),this.diagramLayerDiv.appendChild(s)}else this.diagramLayer=bo.createCanvas(this.element.id+"_diagram",e.width,e.height),Za(this.diagramLayer,"position:absolute;left:0px;top:0px;"),this.diagramLayerDiv.appendChild(this.diagramLayer);this.diagramCanvas.appendChild(this.diagramLayerDiv)},t.prototype.initLayers=function(){var e="position:absolute;top:0px;left:0px;overflow:hidden;pointer-events:none;",r=document.getElementById(this.element.id).getBoundingClientRect(),s=function Loe(){var n=Tt("div",{style:"visibility:hidden; width: 100px"});document.body.appendChild(n);var t=n.getBoundingClientRect().width;n.style.overflow="scroll";var e=Tt("div",{style:"width:100%"});n.appendChild(e);var i=e.getBoundingClientRect().width;return n.parentNode.removeChild(n),t-i}();this.scroller.scrollerWidth=s,this.scroller.setViewPortSize(r.width,r.height),this.renderRulers();var o="measureElement";window[""+o]&&(window[""+o]=null,document.getElementById("measureElement").remove()),function WF(){var n="measureElement";if(window[""+n])window[""+n].usageCount+=1;else{var t=Tt("div",{id:"measureElement",style:"visibility:hidden ; height: 0px ; width: 0px; overflow: hidden;"}),e=Tt("span",{style:"display:inline-block ; line-height: normal"});t.appendChild(e);var i=Tt("img",{alt:"measureElementImage",src:"data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7"});t.appendChild(i);var r=document.createElementNS("http://www.w3.org/2000/svg","svg");r.setAttribute("xmlns:xlink","http://www.w3.org/1999/xlink"),t.appendChild(r);var s=document.createElementNS("http://www.w3.org/2000/svg","path");s.setAttribute("d",""),r.appendChild(s),document.createTextNode("");var a=document.createElementNS("http://www.w3.org/2000/svg","text");a.setAttributeNS("http://www.w3.org/XML/1998/namespace","xml:space","preserve"),r.appendChild(a),window[""+n]=t,window[""+n].usageCount=1,document.body.appendChild(t);var l="measureElementCount";window[""+l]?window[""+l]++:window[""+l]=1}}(),this.renderBackgroundLayer(r,e),this.renderGridLayer(r,e),this.renderDiagramLayer(r,e),this.renderHTMLLayer(r,e),this.renderPortsExpandLayer(r,e),this.renderNativeLayer(r,e),this.renderAdornerLayer(r,e),this.renderHiddenUserHandleTemplateLayer(r)},t.prototype.renderAdornerLayer=function(e,i){var r=Tt("div",{id:this.element.id+"_diagramAdornerLayer",style:"width:"+e.width+"px;height:"+e.height+"px;"+i}),s=Tt("div",{id:this.element.id+"_diagramUserHandleLayer",style:"width:"+e.width+"px;height:"+e.height+"px;"+i});s.setAttribute("class","e-userHandle-layer"),r.appendChild(s);var o=this.createSvg(this.element.id+"_diagramAdorner_svg",e.width,e.height);o.setAttribute("class","e-adorner-layer"),o.style["pointer-events"]="none",this.adornerLayer=Bi("g",{id:this.element.id+"_diagramAdorner"}),this.adornerLayer.style[" pointer-events"]="all",o.appendChild(this.adornerLayer),r.appendChild(o),this.diagramCanvas.appendChild(r);var a=Bi("g",{id:this.element.id+"_SelectorElement"});this.adornerLayer.appendChild(a),oi(o,{style:"pointer-events:none;"})},t.prototype.renderPortsExpandLayer=function(e,i){var r=this.createSvg(this.element.id+"_diagramPorts_svg",e.width,e.height);r.setAttribute("class","e-ports-expand-layer");var s=Bi("g",{id:this.element.id+"_diagramPorts",class:"e-ports-layer",style:"pointer-events: all;"});r.appendChild(s);var o=Bi("g",{id:this.element.id+"_diagramExpander",class:"e-expand-layer",style:"pointer-events: all;"});r.appendChild(o),this.diagramCanvas.appendChild(r),oi(r,{style:i})},t.prototype.renderHTMLLayer=function(e,i){this.htmlLayer=Tt("div",{id:this.element.id+"_htmlLayer",style:"width:"+e.width+"px; height:"+e.height+"px;position:absolute;top:0px;left:0px;overflow:hidden;pointer-events:none;",class:"e-html-layer"});var r=Tt("div",{id:this.element.id+"_htmlLayer_div",style:"position:absolute;top:0px;left:0px;pointer-events:all;"});this.htmlLayer.appendChild(r),this.diagramCanvas.appendChild(this.htmlLayer)},t.prototype.renderNativeLayer=function(e,i){var r=this.createSvg(this.element.id+"_nativeLayer_svg",e.width,e.height),s=Bi("g",{id:this.element.id+"_nativeLayer",style:"pointer-events:all;"});r.appendChild(s),this.diagramLayerDiv.appendChild(r),oi(r,{class:"e-native-layer",style:i})},t.prototype.createSvg=function(e,i,r){var s=document.createElementNS("http://www.w3.org/2000/svg","svg");return oi(s,{id:e,width:i,height:r}),s},t.prototype.updateBazorShape=function(){for(var e=0;e1,i=[],r={},s={},o=[],a=0,l=this.nodes;a0||b&&b.children&&b.children.length>0)&&(M=!1),S&&S.wrapper&&b&&b.wrapper&&M?this.initConnectors(r[""+h],f):i.push(r[""+h])}else b=r[y.targetID],(S=r[y.sourceID])&&S.children&&S.children.length>0||b&&b.children&&b.children.length>0?i.push(r[""+h]):this.initConnectors(r[""+h],f);else r[""+h].children?o.push(h):r[""+h].shape instanceof pT&&r[""+h].shape.activity.subProcess.processes&&r[""+h].shape.activity.subProcess.processes.length>0?s[r[""+h].id]=h:this.initNodes(r[""+h],f);if(this.bpmnModule)for(var w=0,C=this.bpmnModule.bpmnTextAnnotationConnector;w-1&&-1===r.indexOf(c)&&-1===s.indexOf(c)&&r.splice(0,0,c);-1===r.indexOf(o)&&s.push(o)}return r.concat(s)},t.prototype.addToLayer=function(e,i){var r;if(i&&(r=this.commandHandler.getObjectLayer(e.id)),(!i||!r)&&-1===this.activeLayer.objects.indexOf(e.id)&&this.activeLayer.objects.push(e.id),(e instanceof te||e instanceof de)&&("SwimLane"!==e.shape.type||e.children&&e.children.length>0)){if(e.parentId){var s=this.swimlaneZIndexTable[e.parentId],o=this.swimlaneChildTable[e.id];(s&&-1!==s||o&&-1!==o)&&(e.zIndex=this.swimlaneChildTable[e.id])}e instanceof de&&e.sourceID&&e.targetID?-1!==this.activeLayer.objects.indexOf(e.sourceID)&&-1!==this.activeLayer.objects.indexOf(e.targetID)&&this.setZIndex(r||this.activeLayer,e):this.setZIndex(r||this.activeLayer,e)}},t.prototype.updateLayer=function(e){for(var i=0,r=Object.keys(e.layers);i0)for(r=0;rs;l--)r.zIndexTable[parseInt(l.toString(),10)]=r.zIndexTable[l-1],this.nameTable[r.zIndexTable[parseInt(l.toString(),10)]]&&(this.nameTable[r.zIndexTable[parseInt(l.toString(),10)]].zIndex=l);r.zIndexTable[parseInt(a.toString(),10)]=i.id}}},t.prototype.initializeDiagramLayers=function(){for(var e=0;ethis.layers[parseInt(a.toString(),10)].zIndex&&(i=this.layers[parseInt(e.toString(),10)],this.layers[parseInt(e.toString(),10)]=this.layers[parseInt(a.toString(),10)],this.layers[parseInt(a.toString(),10)]=i);0===this.layers.length&&this.commandHandler.addLayer({id:"default_layer",visible:!0,lock:!1,objects:[],zIndex:0,objectZIndex:-1,zIndexTable:{}},null,!0),this.setActiveLayer(this.layers[this.layers.length-1].id)},t.prototype.resetTool=function(){this.eventHandler.resetTool()},t.prototype.initObjectExtend=function(e,i,r){if(r){var s=this.commandHandler.checkBoundaryConstraints(void 0,void 0,e.wrapper.bounds,!0);if("SwimLane"===e.shape.type)for(var o=0,a=Object.keys(i.zIndexTable);o0)&&this.setZIndex(i,e)),e instanceof te){if(r){if("helper"!==e.id&&(o=Zi(this.getNodeDefaults))){if((a=o(e,this))&&a.ports)for(var l=0;l0)for(l=0;l0&&!e.container||e.processId){var r=this.nameTable[e.id];if(!(this.realActions&$i.PreventScale||this.realActions&$i.PreventDrag)){if(r.offsetX&&(this.realActions&$i.EnableGroupAction||!(this.diagramActions&ee.UndoRedo||this.diagramActions&ee.ToolAction||this.diagramActions&ee.PublicMethod))){this.realActions|=$i.PreventScale;var s=r.offsetX-e.wrapper.offsetX;r.offsetX=e.wrapper.offsetX;var o=r.offsetY-e.wrapper.offsetY;r.offsetY=e.wrapper.offsetY,s+o!==0&&this.drag(r,s,o),this.realActions&=~$i.PreventScale}else r.offsetX=e.wrapper.offsetX;r.offsetY&&(this.realActions&$i.EnableGroupAction||!(this.diagramActions&ee.UndoRedo||this.diagramActions&ee.ToolAction||this.diagramActions&ee.PublicMethod))?(this.realActions|=$i.PreventScale,o=r.offsetY-e.wrapper.offsetY,r.offsetY=e.wrapper.offsetY,this.drag(r,0,o),this.realActions&=~$i.PreventScale):r.offsetY=e.wrapper.offsetY,this.diagramActions&&(r.width=e.wrapper.actualSize.width,r.height=e.wrapper.actualSize.height)}}i&&e.children&&e.children.length>0&&(void 0!==this.nameTable[e.id].width?this.scaleObject(e,this.nameTable[e.id].width,!0):this.nameTable[e.id].width=e.wrapper.actualSize.width,void 0!==this.nameTable[e.id].height?this.scaleObject(e,this.nameTable[e.id].height,!1):this.nameTable[e.id].height=e.wrapper.actualSize.height)},t.prototype.initNode=function(e,i,r){var a,p,s=e.initContainer(),o=new Ii;if(this.diagramSettings.inversedAlignment||(s.inversedAlignment=!1),s.children||(s.children=[]),e.children){s.measureChildren=!1,o.id=e.id+"group_container",o.style.fill=e.shape&&"SwimLane"===e.shape.type?e.style.fill:"none",o.style.strokeColor="none",o.horizontalAlignment="Stretch",o.verticalAlignment="Stretch",o.pivot=e.pivot,s.style=e.style,s.padding.left=e.padding.left,s.padding.right=e.padding.right,s.padding.top=e.padding.top,s.padding.bottom=e.padding.bottom,o.children=[],o.preventContainer=!0,e.container&&(o.relativeMode="Object");var l=!!(e.ports&&e.ports.length>0);if(m(e.container)&&!l&&s.children.push(o),e.container&&"Grid"===e.container.type)for(var h=0;h0&&e.wrapper.children[0]instanceof Qv){if(this.setZIndex(this.activeLayer,e),this.connectors.length>0)for(h=0;h0?i.phases.length:0,v="Horizontal"===i.orientation,y=v?i.phases.length||1:s.length+1,S=v?(i.header&&i.hasHeader?1:0)+(i.phases.length>0?1:0)+i.lanes.length:(i.header&&i.hasHeader?1:0)+i.phases.length;if(0===h&&!v&&i.lanes.length&&(S+=1),v?(a=(i.header&&i.hasHeader?1:0)+(h>0?1:0),l=0):(a=i.header&&i.hasHeader?1:0,l=h>0?1:0),s.length>0)for(o+=i.header&&i.hasHeader?i.header.height:0,p=0;pl?d.margin.left=d.margin.left-(u.bounds.left-e.bounds.left):u.children[0].children[1].actualSize.width+r>=d.margin.left&&(d.margin.left=u.children[0].children[1].actualSize.width+r),d.margin.lefta?d.margin.top=d.margin.top-(u.bounds.top-o):u.children[0].children[1].actualSize.height+r>=d.margin.top&&(d.margin.top=u.children[0].children[1].actualSize.height+r),d.margin.left0)for(o=0;o0&&this.updateChildPosition(e)},t.prototype.addBpmnAnnotationConnector=function(e,i){if(e.parentObj instanceof t||e.parentObj instanceof Bd){var r=e.shape,o=""!==r.textAnnotation.textAnnotationTarget&&this.nameTable[r.textAnnotation.textAnnotationTarget],a=o?this.nameTable[r.textAnnotation.textAnnotationTarget]:null,l=null!=a?a.wrapper:null,h=e.ports[0],c={x:0,y:0};switch(r.textAnnotation.textAnnotationDirection){case"Left":h.offset={x:0,y:.5},c.x=i.bounds.left-40,c.y=i.bounds.bottom+30;break;case"Right":h.offset={x:1,y:.5},c.x=i.bounds.right+40,c.y=i.bounds.bottom+30;break;case"Top":h.offset={x:.5,y:0},c.x=i.bounds.right+30,c.y=i.bounds.top-40;break;case"Bottom":h.offset={x:.5,y:1},c.x=i.bounds.right+30,c.y=i.bounds.bottom+40;break;default:h.offset={x:0,y:.5},c.x=i.bounds.left-40,c.y=i.bounds.bottom+30,o&&null!=i&&null!=l&&(i.bounds.left>l.bounds.right?h.offset={x:0,y:.5}:i.bounds.rightl.bounds.top?h.offset={x:.5,y:0}:i.bounds.top0&&this.updateChildPosition(r)}},t.prototype.canExecute=function(){return!0},t.prototype.updateStackProperty=function(e,i,r){e.container&&"Stack"===e.container.type&&(i.width||(i.wrapper.horizontalAlignment="Stretch",i.horizontalAlignment="Stretch"),i.height||(i.verticalAlignment="Stretch",i.wrapper.verticalAlignment="Stretch"),r&&"UmlClassifier"===e.shape.type&&(i.umlIndex=r))},t.prototype.initViews=function(){this.isLoading||(this.views.push(this.element.id),this.views[this.element.id]=this)},t.prototype.initCommands=function(){var e=this.commandManager.commands,i={copy:{execute:this.copyCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.C,keyModifiers:pt.Control}},paste:{execute:this.pasteCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.V,keyModifiers:pt.Control}},cut:{execute:this.cutCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.X,keyModifiers:pt.Control}},delete:{execute:this.removeCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Delete}},selectAll:{execute:this.selectAll.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.A,keyModifiers:pt.Control}},undo:{execute:this.undo.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Z,keyModifiers:pt.Control}},redo:{execute:this.redo.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Y,keyModifiers:pt.Control}},nudgeUp:{execute:this.nudgeCommand.bind(this,"Up"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Up},parameter:"up"},nudgeRight:{execute:this.nudgeCommand.bind(this,"Right"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Right},parameter:"right"},nudgeDown:{execute:this.nudgeCommand.bind(this,"Down"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Down},parameter:"down"},nudgeLeft:{execute:this.nudgeCommand.bind(this,"Left"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Left},parameter:"left"},startEdit:{execute:this.startEditCommad.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.F2}},endEdit:{execute:this.endEditCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Escape}},focusToNextItem:{execute:this.navigateItems.bind(this,!0),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Tab}},focusToPreviousItem:{execute:this.navigateItems.bind(this,!1),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Tab,keyModifiers:pt.Shift}},selectFocusedItem:{execute:this.startEditCommad.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Enter}},bold:{execute:this.fontStyleCommand.bind(this,"bold"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.B,keyModifiers:pt.Control}},italic:{execute:this.fontStyleCommand.bind(this,"italic"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.I,keyModifiers:pt.Control}},underline:{execute:this.fontStyleCommand.bind(this,"underline"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.U,keyModifiers:pt.Control}},duplicate:{execute:this.duplicateCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.D,keyModifiers:pt.Control}},group:{execute:this.groupCommand.bind(this,"group"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.G,keyModifiers:pt.Control}},ungroup:{execute:this.groupCommand.bind(this,"ungroup"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.U,keyModifiers:pt.Control|pt.Shift}},rotateClockwise:{execute:this.rotateCommand.bind(this,"clockwise"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.R,keyModifiers:pt.Control}},rotateAntiClockwise:{execute:this.rotateCommand.bind(this,"antiClockwise"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.L,keyModifiers:pt.Control}},flipHorizontal:{execute:this.flipCommand.bind(this,"horizontal"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.H,keyModifiers:pt.Control}},flipVertical:{execute:this.flipCommand.bind(this,"vertical"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.J,keyModifiers:pt.Control}},pointerTool:{execute:this.toolCommand.bind(this,"pointer"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number1,keyModifiers:pt.Control}},textTool:{execute:this.toolCommand.bind(this,"text"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number2,keyModifiers:pt.Control}},connectTool:{execute:this.toolCommand.bind(this,"connect"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number3,keyModifiers:pt.Control}},freeForm:{execute:this.toolCommand.bind(this,"freeForm"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number5,keyModifiers:pt.Control}},lineTool:{execute:this.toolCommand.bind(this,"line"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number6,keyModifiers:pt.Control}},rectangleTool:{execute:this.toolCommand.bind(this,"rectangle"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number8,keyModifiers:pt.Control}},ellipseTool:{execute:this.toolCommand.bind(this,"ellipse"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number9,keyModifiers:pt.Control}},zoomIn:{execute:this.zoomCommand.bind(this,"zoomIn"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Plus,keyModifiers:pt.Control}},zoomOut:{execute:this.zoomCommand.bind(this,"zoomOut"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Minus,keyModifiers:pt.Control}},shiftUp:{execute:this.shiftCommand.bind(this,"Up"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Up,keyModifiers:pt.Shift}},shiftDown:{execute:this.shiftCommand.bind(this,"Down"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Down,keyModifiers:pt.Shift}},shiftLeft:{execute:this.shiftCommand.bind(this,"Left"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Left,keyModifiers:pt.Shift}},shiftRight:{execute:this.shiftCommand.bind(this,"Right"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Right,keyModifiers:pt.Shift}},alignTextCenter:{execute:this.alignCommand.bind(this,"center"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.C,keyModifiers:pt.Control|pt.Shift}},alignTextLeft:{execute:this.alignCommand.bind(this,"right"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.L,keyModifiers:pt.Control|pt.Shift}},alignTextRight:{execute:this.alignCommand.bind(this,"left"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.R,keyModifiers:pt.Control|pt.Shift}},alignTextTop:{execute:this.alignCommand.bind(this,"top"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.E,keyModifiers:pt.Control|pt.Shift}},alignTextCenterVertical:{execute:this.alignCommand.bind(this,"centerVertical"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.M,keyModifiers:pt.Control|pt.Shift}},alignTextBottom:{execute:this.alignCommand.bind(this,"bottom"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.V,keyModifiers:pt.Control|pt.Shift}},alignJustify:{execute:this.alignCommand.bind(this,"justify"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.J,keyModifiers:pt.Control|pt.Shift}},sendToBack:{execute:this.orderCommand.bind(this,"sendToBack"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.B,keyModifiers:pt.Control|pt.Shift}},bringToFront:{execute:this.orderCommand.bind(this,"bringToFront"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.F,keyModifiers:pt.Control|pt.Shift}},sendBackward:{execute:this.orderCommand.bind(this,"sendBackward"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.BracketLeft,keyModifiers:pt.Control}},bringForward:{execute:this.orderCommand.bind(this,"bringForward"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.BracketRight,keyModifiers:pt.Control}}};this.initCommandManager(e,i)},t.prototype.overrideCommands=function(e,i){for(var r,s=0,o=Object.keys(i);se.zIndex){("HTML"===e.shape.type||"Native"===e.shape.type)&&(o="HTML"===e.shape.type?"html":"native"),s=Eoe(i,r[parseInt(a.toString(),10)].id,o);break}return s},t.prototype.updateDiagramObject=function(e,i,r){for(var s,o="domTable",a=0,l=this.views;a1&&(d=this.commandHandler.getObjectLayer(e.id)),void 0===d||d&&d.visible||r){var u=Io(this.element.id);window[""+o][s.element.id+"_diagramLayer"]||(window[""+o][s.element.id+"_diagramLayer"]=document.getElementById(s.element.id+"_diagramLayer"));var p=window[""+o][s.element.id+"_diagramLayer"];this.diagramActions&ee.Interactions&&this.updateCanupdateStyle(e.wrapper.children,!0);var f=this.getMidPoint(e);this.diagramRenderer.updateNode(e.wrapper,p,u,void 0,i?void 0:this.getZindexPosition(e,s.element.id),f,this.portCenterPoint),this.updateCanupdateStyle(e.wrapper.children,!0)}}},t.prototype.applyMarginBezier=function(e,i){i.cx=i.cx+e.margin.left,i.cx=i.cx-e.margin.right,i.cy=i.cy+e.margin.top,i.cy=i.cy-e.margin.bottom},t.prototype.getMidPoint=function(e){var i;if(e instanceof de&&"Bezier"===e.type){i=[];for(var r=this.getBezierPoints(e),s=z.getLengthFromListOfPoints(r),o=0;o0&&e.updateView(e));var s=Io(e.element.id);this.renderDiagramElements(e.diagramLayer,e.diagramRenderer,s,void 0,void 0,i);for(var o=0;o0&&this.renderBasicElement(e),!this.diagramActions||!(this.diagramActions&ee.Render)||ee.ToolAction&this.diagramActions||Ds(this)||1!==this.scroller.currentZoom?this.refreshElements(e):this.renderTimer||(this.renderTimer=setTimeout(function(){i.refreshElements(e)},40)))},t.prototype.updatePortVisibility=function(e,i,r){var s;if((e instanceof te||e instanceof de)&&(!this.drawingObject||!this.drawingObject.shape)&&to(e)){for(var a=e.ports,l=!1,h=0;h=0&&this.scroller.removeCollection.splice(l,1);var h=this.nameTable[e[parseInt(a.toString(),10)]];this.updateTextElementValue(h),this.diagramRenderer.renderElement(h.wrapper,s,o,void 0,void 0,void 0,void 0,h.zIndex)}for(var c=0;c0?this.scroller.oldCollectionObjects:void 0,b=Object.keys(S||g.zIndexTable);b.sort(function(N,T){return parseInt(""+N,10)-parseInt(""+T,10)});for(var M=0,w=b;M0?h:0)+"px",y=(this.realActions&$i.vScrollbarMoved?0:-(this.scroller.verticalOffset<0?this.scroller.verticalOffset:0))+"px"):(v="0px",y="0px"),this.realActions&$i.hScrollbarMoved&&(this.realActions=this.realActions&~$i.hScrollbarMoved),this.realActions&$i.vScrollbarMoved&&(this.realActions=this.realActions&~$i.vScrollbarMoved)):(v=(l.x<0?h:-this.scroller.horizontalOffset)+"px",y=(l.y<0?c:-this.scroller.verticalOffset)+"px"),this.diagramLayer.style.left=v,this.diagramLayer.style.top=y,A.tx=-l.x/A.scale,A.ty=-l.y/A.scale);var R=!0;if(o&&(R=!1),this.updateTextElementValue(D),this.refreshing&&D.shape.activity&&D.shape.activity.subProcess&&D.shape.activity.subProcess.processes){for(var L=0;L0){var o=s.children[0],a=o.data;(r.isBezierEditing&&this.selectedItems.connectors[0].id===r.id||"Bezier"!==r.type)&&r.getSegmentElement(r,o,"ComplexHierarchicalTree"===this.layout.type||"HierarchicalTree"===this.layout.type?this.layout.orientation:void 0,void 0,!1),o.data!==a&&(s.measure(new me),s.arrange(s.desiredSize),"SVG"===this.mode&&!e&&this.updateDiagramObject(r))}}else this.constraints&rt.Bridging&&console.warn('[WARNING] :: Module "ConnectorBridging" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.setCursor=function(e){this.diagramRenderer.setCursor(this.diagramCanvas,e)},t.prototype.clearCanvas=function(e){var i=e.contentWidth||e.diagramLayer.width/this.scroller.currentZoom,r=e.contentHeight||e.diagramLayer.height/this.scroller.currentZoom;"SVG"!==e.mode&&bo.getContext(e.diagramLayer).clearRect(0,0,i,r)},t.prototype.updateScrollOffset=function(){this.scroller.setScrollOffset(this.diagramCanvas.scrollLeft,this.diagramCanvas.scrollTop),eb(this),Ds(this)&&this.scroller.virtualizeElements()},t.prototype.setOffset=function(e,i){var r="domTable";window[""+r][this.element.id+"content"]||(window[""+r][this.element.id+"content"]=document.getElementById(this.element.id+"content"));var s=window[""+r][this.element.id+"content"];s&&(s.scrollLeft=e,s.scrollTop=i)},t.prototype.setSize=function(e,i){if(this.diagramLayer&&!this.preventDiagramUpdate){var r=qa(this);e-=r.width,i-=r.height;var s=this.spatialSearch.getPageBounds();s.x*=this.scroller.currentZoom,s.y*=this.scroller.currentZoom,s.width*=this.scroller.currentZoom,s.height*=this.scroller.currentZoom;var o="SVG"===this.mode?1:1.5,a="SVG"===this.mode?yT(this.element.id):this.diagramLayer,h="Canvas"===this.mode&&this.constraints&rt.Virtualization?this.scroller.viewPortHeight:i;a.setAttribute("width",(o*("Canvas"===this.mode&&this.constraints&rt.Virtualization?this.scroller.viewPortWidth:e)).toString()),a.setAttribute("height",(o*h).toString());var c=document.getElementById(this.element.id+"_diagramUserHandleLayer");c&&(c.style.width=e+"px",c.style.height=i+"px");var d={width:e.toString(),height:i.toString()};this.diagramLayerDiv.style.width=e+"px",this.diagramLayerDiv.style.height=i+"px",oi(FF(this.element.id),d),oi(function xoe(n){return xt(n).getElementsByClassName("e-ports-expand-layer")[0]}(this.element.id),d);var u=zl(this.element.id);oi(u,d),u.parentNode.style.width=e+"px",u.parentNode.style.height=i+"px";var p=_d(this.element.id);oi(p,d),this.diagramRenderer.updateGrid(this.snapSettings,p,this.scroller.transform,this.rulerSettings,this.hRuler,this.vRuler),oi(bT(this.element.id),d),this.htmlLayer.style.width=e+"px",this.htmlLayer.style.height=i+"px","SVG"!==this.mode&&!Ds(this)&&this.refreshDiagramLayer(),"SVG"===this.mode&&Ds(this)&&this.scroller.virtualizeElements()}},t.prototype.transformLayers=function(){var e=this.spatialSearch.getPageBounds();e.x*=this.scroller.currentZoom,e.y*=this.scroller.currentZoom,e.width*=this.scroller.currentZoom,e.height*=this.scroller.currentZoom,this.diagramRenderer.updateGrid(this.snapSettings,_d(this.element.id),this.scroller.transform,this.rulerSettings,this.hRuler,this.vRuler),this.diagramRenderer.transformLayers(this.scroller.transform,"SVG"===this.mode),this.diagramActions&ee.DragUsingMouse||this.updateSelector(),this.renderPageBreaks(e)},t.prototype.removePageBreaks=function(){if(this.diagramLayer){var e=_F(this.element.id);if(e&&e.childNodes)for(var i=e.childNodes.length,r=0;rthis.pageSettings.height&&(e=this.pageSettings.height,this.pageSettings.height=this.pageSettings.width,this.pageSettings.width=e):this.pageSettings.height>this.pageSettings.width&&(e=this.pageSettings.width,this.pageSettings.width=this.pageSettings.height,this.pageSettings.height=e)},t.prototype.setOverview=function(e,i){if(e)e&&(this.views.push(e.id),this.views[e.id]=e,e.renderDocument(e),e.diagramRenderer.setLayers(),e.updateView(e),this.renderNodes(e));else{for(var r=0;r1&&this.updateSelectionRectangle(),this.isProtectedOnChange=s},t.prototype.updateSelectionRectangle=function(){for(var e=um(this.element.id),i=!1,r=0;r1&&this.updateSelectionRectangle(),this.enableServerDataBinding(e)},t.prototype.renderSelectorForAnnotation=function(e,i){this.diagramRenderer.renderResizeHandle(e.wrapper.children[0],i,e.thumbsConstraints,this.scroller.currentZoom,e.constraints,this.scroller.transform,void 0,to(e.annotation),void 0,void 0,e.handleSize)},t.prototype.drawSelectionRectangle=function(e,i,r,s){this.clearSelectorLayer(),this.diagramRenderer.drawSelectionRectangle(e,i,r,s,this.adornerLayer,this.scroller.transform)},t.prototype.renderHighlighter=function(e){var i=zl(this.element.id);this.diagramRenderer.renderHighlighter(e,i,this.scroller.transform)},t.prototype.clearHighlighter=function(){var e=zl(this.element.id),i=e.getElementById(e.id+"_highlighter");i&&i.parentNode.removeChild(i)},t.prototype.getNodesConnectors=function(e){for(var i=0;i0;l--)(a=o[l-1]).parentNode.removeChild(a);if(!ce()){var h=IT(this.element.id).childNodes;for(r=h.length;r>0;r--)h[r-1].parentNode.removeChild(h[r-1])}}},t.prototype.getWrapper=function(e,i){var r;i=e.id+"_"+i;for(var s=e instanceof Ii?e:this.getPortContainer(this.nameTable[e.id]),o=0;o0&&this.applyStyle(e,a=r.annotations)}for(i=0;i0){var a=this.selectedItems.connectors[parseInt(i.toString(),10)].annotations;this.applyStyle(e,a)}},t.prototype.applyStyle=function(e,i){for(var r=0;r0)for(var i=0;i0?r[0].zIndex+(e?1:-1):e?0:this.nodes.length+this.connectors.length-1)<0?i=this.nodes.length+this.connectors.length-1:i===this.nodes.length+this.connectors.length&&(i=0);for(var s=0;s0)for(var s=void 0,o=r.children.length-1;o>=0;o--){var a=r.children[parseInt(o.toString(),10)];i.length>0&&-1!==i.indexOf(a.id.split("_groupElement")[0])&&(r.parentNode.insertBefore(a,s||r),s=a)}r&&r.parentNode.removeChild(r)},t.prototype.deleteGroup=function(e){var r=[];e.children&&(r=this.commandHandler.getChildren(e,[])),this.UpdateBlazorDiagramModelCollection(e);for(var s=0,o=r;s0)for(var xe=0;xe0)if("Path"===t.shape.type&&void 0!==n.shape.data)t.wrapper.children[0].data=n.shape.data;else if("Text"===t.shape.type&&void 0!==n.shape.content)t.wrapper.children[0].content=n.shape.content;else if("Image"===t.shape.type&&void 0!==n.shape.source)t.wrapper.children[0].source=n.shape.source;else if("Native"===t.shape.type){for(var r=void 0,s=0;s-1)&&(this.diagramActions&ee.PreventZIndexOnDragging?this.updateDiagramObject(e,!0):this.updateDiagramObject(e)),!s&&d&&(this.lineRoutingModule&&this.diagramActions&&this.constraints&rt.LineRouting&&"helper"!==e.id?this.diagramActions&ee.ToolAction||this.lineRoutingModule.renderVirtualRegion(this,!0):this.diagramActions&&this.constraints&rt.LineRouting&&"helper"!==e.id&&console.warn('[WARNING] :: Module "LineRouting" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),this.updateConnectorEdges(e),"helper"!==e.id&&!(this.diagramActions&ee.ToolAction))))for(var ya=this.spatialSearch.findObjects(e.wrapper.outerBounds),Mo=0;Moe?Math.abs(r-e):Math.abs(e-r),d=s>i?Math.abs(s-i):Math.abs(i-s);(0===c&&0===d||Number.isNaN(c)&&Number.isNaN(d))&&o.laneMargin&&(u=o.margin.left-o.laneMargin.left,p=o.margin.top-o.laneMargin.top);var f=o.width,g=o.height,v=new Ne(0,0,0,0);if(0!==f&&0!==g&&(v=new Ne((0!==r?r:o.offsetX)-f/2,(0!==s?s:o.offsetY)-g/2,f,g)),h){var y=l,b=this.selectedItems.nodes?this.selectedItems.nodes[0]:void 0;if(""!==y.textAnnotation.textAnnotationTarget&&this.nameTable[y.textAnnotation.textAnnotationTarget])if(""===o.parentId||b&&b.shape&&"TextAnnotation"===b.shape.shape){if("Auto"===y.textAnnotation.textAnnotationDirection&&a.children[0]instanceof Ii&&a.children[0].children[0]instanceof Ke){var w=a.children[0],C=document.getElementById(w.id+"_groupElement"),D=document.getElementById(w.children[0].id+"_groupElement");C.removeChild(D),w.children.splice(0,1),this.isProtectedOnChange=!0,this.bpmnModule.setAnnotationPath(v,w,o,y,y.textAnnotation.textAnnotationDirection,this),this.isProtectedOnChange=!1}}else this.isPositionUndo=!0,this.updateTextAnnotationInSwimlane(o,o),this.isPositionUndo=!1;else o.inEdges.length>0&&(x=this.nameTable[""+o.inEdges[0]])&&x.isBpmnAnnotationConnector&&(x.sourcePoint={x:r>e?x.sourcePoint.x+c:x.sourcePoint.x-c,y:s>i?x.sourcePoint.y+d:x.sourcePoint.y-d});this.nodePropertyChange(o,{},R={ports:[{offset:o.ports[0].offset}]})}else for(var L=0,O=o.outEdges;Le?T.offsetX+c:T.offsetX-c,T.offsetY=s>i?T.offsetY+d:T.offsetY-d,R={offsetX:T.offsetX,offsetY:T.offsetY}),this.nodePropertyChange(T,P,R)}}}},t.prototype.updatePorts=function(e,i){if(e&&e.ports.length>0)for(var r=0,s=Object.keys(e.ports);r0)for(var i=0;i0)for(var r=0;r0&&void 0===r.segments&&(e.segments=[]),void 0!==r.shape&&void 0!==e.shape&&e.shape&&"Bpmn"===e.shape.type&&this.bpmnModule&&this.bpmnModule.updateBPMNConnector(e,i,r,this),void 0!==e.constraints?(this.updateThumbConstraints(this.selectedItems.connectors,this.selectedItems),s=!0):s},t.prototype.connectorPropertyChange=function(e,i,r,s,o){if(this.canEnableBlazorObject){var a=$(e);this.insertValue(a,!1)}var d,u,p,f,l=e.wrapper.bounds,h=!1,c=[];if(h=this.connectorProprtyChangeExtend(e,i,r,h),void 0!==r.visible&&this.updateElementVisibility(e.wrapper,e,e.visible),void 0!==r.sourcePoint||void 0!==r.targetPoint||void 0!==r.sourceID||void 0!==r.targetID||void 0!==r.targetPadding||void 0!==r.sourcePortID||void 0!==r.targetPortID||void 0!==r.sourcePadding||void 0!==r.type||void 0!==r.segments||void 0!==r.flip){if(void 0!==r.sourceID&&r.sourceID!==i.sourceID||r.sourcePortID){if(u=this.findInOutConnectPorts(g=this.nameTable[e.sourceID],!1),(!g||kh(g)||""!==e.sourcePortID&&Ad(u))&&(e.sourceWrapper=g?this.getEndNodeWrapper(g,e,!0):void 0,e.sourcePortID&&void 0===r.sourcePortID&&(e.sourcePortWrapper=g?this.getWrapper(g.wrapper,e.sourcePortID):void 0),this.removePortEdges(this.nameTable[i.sourceID]||g,i.sourcePortID||e.sourcePortID,e.id,!1)),void 0!==r.sourceID&&void 0!==i.sourceID&&""!==i.sourceID){var v=this.nameTable[i.sourceID];void 0!==v&&v.outEdges&&-1!==v.outEdges.indexOf(e.id)&&rm(v.outEdges,e.id)}this.updateEdges(e)}if(void 0!==r.targetID&&r.targetID!==i.targetID){if(d=this.findInOutConnectPorts(y=this.nameTable[r.targetID],!0),(!y||da(y)||""!==e.targetPortID&&Oh(d))&&(e.targetWrapper=y?this.getEndNodeWrapper(y,e,!1):void 0,e.targetPortID&&void 0===r.targetPortID&&(e.targetPortWrapper=y?this.getWrapper(y.wrapper,e.targetPortID):void 0),this.removePortEdges(this.nameTable[i.targetID]||y,i.targetPortID||e.targetPortID,e.id,!0)),void 0!==i&&void 0!==i.targetID&&""!==i.targetID){var S=this.nameTable[i.targetID];void 0!==S&&S.inEdges&&-1!==S.inEdges.indexOf(e.id)&&rm(S.inEdges,e.id)}this.updateEdges(e)}var g,y;void 0!==r.sourcePortID&&r.sourcePortID!==i.sourcePortID&&(e.sourceID&&this.nameTable[e.sourceID]&&(p=this.nameTable[e.sourceID].wrapper),!(g=this.nameTable[e.sourceID])||kh(g)||""!==e.sourcePortID&&Ad(u)?e.sourcePortWrapper=p?this.getWrapper(p,r.sourcePortID):void 0:""===e.sourcePortID&&!kh(g)&&(e.sourcePortWrapper=void 0)),void 0!==r.targetPortID&&r.targetPortID!==i.targetPortID&&(e.targetID&&this.nameTable[e.targetID]&&(f=this.nameTable[e.targetID].wrapper),!(y=this.nameTable[e.targetID])||da(y)||""!==e.targetPortID&&Oh(d)?e.targetPortWrapper=f?this.getWrapper(f,r.targetPortID):void 0:""===e.targetPortID&&!da(y)&&(e.targetPortWrapper=void 0)),void 0!==r.flip&&(e.flip=r.flip,EF(e)),"Orthogonal"===e.type&&this.lineRoutingModule&&this.diagramActions&&this.constraints&rt.LineRouting&&!(this.diagramActions&ee.ToolAction)&&"ComplexHierarchicalTree"!==this.layout.type&&(this.lineRoutingModule.renderVirtualRegion(this,!0),e.sourceID!==e.targetID&&e.segments.length>1&&this.lineRoutingModule.refreshConnectorSegments(this,e,!1)),c=this.getPoints(e)}void 0!==r.style&&Rh(r.style,e.wrapper.children[0]),(c.length>0||void 0!==r.sourceDecorator||void 0!==r.targetDecorator&&function qse(n){return-1!==n.indexOf("shape")||-1!==n.indexOf("pathData")||-1!==n.indexOf("width")||-1!==n.indexOf("height")}(Object.keys(r.targetDecorator))||void 0!==r.cornerRadius)&&(ef(e,c.length>0?c:e.intermediatePoints,this.diagramActions),void 0!==r.type&&(h=!0),c.length>0&&(e.wrapper.measure(new me(e.wrapper.width,e.wrapper.height)),e.wrapper.arrange(e.wrapper.desiredSize),this.updateConnectorAnnotation(e),this.updateConnectorPort(e),this.updateConnectorfixedUserHandles(e),this.updateObject(e,i,r))),(r.sourcePoint||r.targetPoint||r.segments)&&this.diagramActions===ee.Render&&(h=!0),"Bpmn"===e.shape.type&&"Default"===e.shape.sequence&&"Sequence"===e.shape.flow&&this.commandHandler.updatePathElementOffset(e),s||this.updateBridging(),this.updateAnnotations(r,e),this.updateConnectorPorts(r,e),this.updatefixedUserHandle(r,e),e.wrapper.measure(new me(e.wrapper.width,e.wrapper.height)),e.wrapper.arrange(e.wrapper.desiredSize),!1===l.equals(l,e.wrapper.bounds)&&(this.updateQuad(e),"Drag"!==this.eventHandler.currentAction&&this.updateGroupSize(e)),!0===h&&this.checkSelectedItem(e)&&(!(this.diagramActions&ee.ToolAction)||this.diagramActions&ee.UndoRedo)&&this.updateSelector(),this.preventConnectorsUpdate||(!Ds(this)||Ds(this)&&this.scroller.oldCollectionObjects.indexOf(e.id)>-1)&&(this.diagramActions&ee.PreventZIndexOnDragging?this.updateDiagramObject(e,!0):this.updateDiagramObject(e)),this.updateConnectorEdges(e),this.diagramActions&&"New"!==e.status&&(e.status="Update"),this.triggerPropertyChange(o,e,i,r)},t.prototype.removePortEdges=function(e,i,r,s){if(e)for(var o=0;o0&&e.id===s[s.length-1].id&&(r=!0),r},t.prototype.updateDiagramContainerVisibility=function(e,i){if(e instanceof Cs)for(var r=0;r>"),r instanceof Jn&&this.updateAnnotationWrapper(r,s,o,a)),void 0!==e.template&&(r.content=e.template,this.updateAnnotationWrapper(r,s,o,a))},t.prototype.updateAnnotationWrapper=function(e,i,r,s){for(var o=0,a=this.views;o=0&&this.nodes.splice(s,1),delete this.nameTable[""+r]}var o=this.nodes.indexOf(this.nameTable[this.currentSymbol.id]);o>=0&&this.nodes.splice(o,1)}},t.prototype.selectDragedNode=function(e,i,r){this.currentSymbol=e,"SVG"!==this.mode&&this.refreshDiagramLayer(),this.commandHandler.oldSelectedObjects=sm(this),this.commandHandler.select(e),this.eventHandler.mouseDown(i.event),this.eventHandler.mouseMove(i.event,i),this.preventDiagramUpdate=!1,this.updatePage(),r.style.opacity="0"},t.prototype.initDroppables=function(){var s,o,e=this,i={},r={},a="selectedSymbols";this.droppable=new lR(this.element);var l=5;this.droppable.over=function(h){if(e.rulerSettings.showRulers){var c=document.getElementById(e.element.id+"_vRuler"),d=parseFloat(c.style.width);l=d+1}if(0===e.previousSelectedObjects.length&&!e.currentSymbol&&(e.previousSelectedObjects=e.commandHandler.getSelectedObject()),e.commandHandler.PreventConnectorSplit=!0,e.currentSymbol)h.event.touches&&h.event.touches.length&&e.eventHandler.mouseMove(h.event,h.event.touches);else{var u=null;if(!h.dragData&&"drag"===h.name){var p=document.getElementsByClassName("e-dragclone")[0];p&&(u=p)}if(h.dragData||u){var f=void 0,g=void 0;document.getElementById(e.element.id+"content").focus();var v=e.eventHandler.getMousePosition(h.event),y=void 0,S=u||h.dragData.helper,b=S.getAttribute("paletteId"),M=void 0,w=void 0,C=void 0,D=void 0;if(!b&&h.dragData){e.triggerEvent(Ce.dragEnter,A={source:null,element:f,cancel:!1,diagram:e,dragData:h.dragData.draggedElement.ej2_instances[0].dragData,dragItem:f});var x=void 0,R=void 0;if(A.dragItem){if(A.dragItem.sourcePoint&&A.dragItem.targetPoint?R=new de(e,"connectors",A.dragItem,!0):x=new te(e,"nodes",A.dragItem,!0),e.initObject(f=x||R,void 0,void 0,!0),e.enterObject=f,e.enterTable=r,f instanceof te)x.offsetX=v.x+5+x.width*x.pivot.x,x.offsetY=v.y+x.height*x.pivot.y;else if(f instanceof de){var L=Ne.toBounds([f.sourcePoint,f.targetPoint]),O=v.x-L.left,N=v.y-L.top;f.sourcePoint.x+=O,f.sourcePoint.y+=N,f.targetPoint.x+=O,f.targetPoint.y+=N}e.preventDiagramUpdate=!0,e.currentSymbol=f,"SVG"!==e.mode&&e.refreshDiagramLayer(),e.selectDragedNode(f,h,S),delete e.enterObject,delete e.enterTable,e.droppable[""+a]=S,e.allowServerDataBinding=!0}}if(b){var T=document.getElementById(b).ej2_instances[0];if(e.droppable.sourceElement=T,T){var B=T[""+a];e.allowServerDataBinding=!1,y=$(T[""+a]),i=T.childTable;var j=B.wrapper.children[0].children[0];if(D=function $se(n,t,e){var i=AF(n,t,e,"width"),r=AF(n,t,e,"height");return new me(i,r)}(T,y,j),T[""+a]instanceof te){"TextAnnotation"===B.shape.shape?(y.offsetX=v.x+11+D.width*y.pivot.x,y.offsetY=v.y+11+D.height*y.pivot.y):(y.offsetX=v.x+5+D.width*y.pivot.x,y.offsetY=v.y+D.height*y.pivot.y),"Bpmn"===(x=new te(e,"nodes",y,!0)).shape.type&&x.shape.activity.subProcess.processes&&x.shape.activity.subProcess.processes.length&&(x.shape.activity.subProcess.processes=[]),w=x.previewSize,C=T.symbolDragSize;var Q=T.symbolPreview;if(x.width=(M=x.dragSize).width||C.width||w.width||Q.width||x.width,x.height=M.height||C.height||w.height||Q.height||x.height,"SwimLane"===x.shape.type){if(e.diagramActions|=ee.PreventHistory,x.shape.isLane){x.children=[],s={id:"header"+Qe()},"Horizontal"===x.shape.orientation?(s.width=x.shape.lanes[0].header.width,s.height=x.shape.lanes[0].height):(s.width=x.shape.lanes[0].width,s.height=x.shape.lanes[0].header.height),s.style=x.shape.lanes[0].header.style,s.offsetX=v.x+l+s.width/2,s.offsetY=v.y+s.height/2,e.diagramActions|=ee.PreventCollectionChangeOnDragOver,s=e.add(s),o={id:"body"+Qe()},"Horizontal"===x.shape.orientation?(o.width=x.shape.lanes[0].width-s.width,o.height=x.shape.lanes[0].height,o.offsetX=v.x+l+(x.shape.lanes[0].header.width+o.width/2),o.offsetY=v.y+o.height/2):(o.width=x.shape.lanes[0].width,o.height=x.shape.lanes[0].height-s.height,o.offsetX=v.x+l+o.width/2,o.offsetY=v.y+(x.shape.lanes[0].header.height+o.height/2)),o.style=x.shape.lanes[0].style,o=e.add(o);var oe={id:"group"+Qe(),children:[s.id,o.id]};oe.shape=x.shape,oe.width=x.shape.lanes[0].width,oe.height=x.shape.lanes[0].height,oe.previewSize=x.previewSize,oe.dragSize=x.dragSize,oe.addInfo=x.addInfo,x=e.add(oe),e.diagramActions&=~ee.PreventCollectionChangeOnDragOver}e.diagramActions&=~ee.PreventHistory}if(x.shape.isPhase&&((g="Horizontal"===x.shape.orientation)?(x.offsetX=v.x+l+(x.width||j.actualSize.width)/2,x.offsetY=v.y,x.shape.data="M20,"+x.height/2+" L"+(x.width-20)+","+x.height/2+"z",x.height=1):(x.offsetX=v.x+5,x.offsetY=v.y+(x.height||j.actualSize.height)/2,x.shape.data="M"+x.width/2+",20 L"+x.width/2+","+(x.height-20)+"z",x.width=1)),"UmlClassifier"===x.shape.type&&(x.children=x.width=x.height=void 0,y.children=void 0,"Class"===x.shape.classifier&&x.shape.classShape.methods.length<=0&&x.shape.classShape.attributes.length<=0&&(x.shape.classShape.attributes=[{name:"Name",type:"Type",style:{}}]),"Enumeration"===x.shape.classifier&&x.shape.enumerationShape.members.length<=0&&(x.shape.enumerationShape.members=[{name:"Name"}]),"Interface"===x.shape.classifier&&x.shape.interfaceShape.methods.length<=0&&x.shape.interfaceShape.attributes.length<=0&&(x.shape.interfaceShape.attributes=[{name:"Name",type:"Type",style:{}}])),f=x,y.children){var ue=y;r=e.getChildren(ue,{},i),nT(ue,-ue.offsetX,-ue.offsetY,r,!0,e)}}else if(T[""+a]instanceof de){f=new de(e,"connectors",y,!0);var Me=Ne.toBounds([f.sourcePoint,f.targetPoint]),De=v.x-Me.left,xe=v.y-Me.top;f.sourcePoint.x+=De,f.sourcePoint.y+=xe,f.targetPoint.x+=De,f.targetPoint.y+=xe}f.shape.isLane||(f.id+=Qe());var A={source:T,element:f,cancel:!1,diagram:e,dragData:null,dragItem:f};if(e.enterObject=f,e.enterTable=r,e.triggerEvent(Ce.dragEnter,A),f instanceof te&&"SwimLane"===f.shape.type&&f.shape.isLane){var Ie=A.element,Ve=Ie.shape.lanes[0];g="Horizontal"===Ie.shape.orientation;var ot=e.nameTable[f.children[0]],$e=e.nameTable[f.children[1]];w=f.previewSize,C=T.symbolDragSize,Ve.width=(M=f.dragSize).width||C.width||w.width||Ve.width,Ve.height=M.height||C.height||w.height||Ve.height,g?(s.width=Ve.header.width,s.height=Ve.height,o.width=Ve.width-s.width,o.height=Ve.height,o.offsetX=v.x+l+(Ve.header.width+$e.width/2),o.offsetY=v.y+$e.height/2):(s.width=Ve.width,s.height=Ve.header.height,o.width=Ve.width,o.height=Ve.height-s.height,o.offsetX=v.x+l+$e.width/2,o.offsetY=v.y+(Ve.header.height+$e.height/2)),s.offsetX=v.x+l+ot.width/2,s.offsetY=v.y+ot.height/2,f.width=Ve.width,f.height=Ve.height}if(f instanceof te&&f.shape.isPhase&&(g?f.height=1:f.width=1),!e.activeLayer.lock&&!A.cancel){if(e.preventDiagramUpdate=!0,f.children&&e.findChild(f,r),e.preventDiagramUpdate=!0,f.zIndex!==Number.MIN_VALUE&&(f.zIndex=Number.MIN_VALUE),e.initObject(f,void 0,void 0,!0),e.bpmnModule)for(var Mi=0;Mi0&&(S.segments=[]),d=this.add(S,!0)),(S||d)&&(jv(this)||Vv(this))&&this.select([this.nameTable[S[""+b]]],!1,this.previousSelectedObjects),y.target&&y.target instanceof de&&!0===this.enableConnectorSplit&&this.nameTable[S[""+b]]instanceof te&&(this.commandHandler.connectorSplit(this.nameTable[S[""+b]],y.target),this.commandHandler.PreventConnectorSplit=!1))),this.protectPropertyChange(!1),v=this.nameTable[S[""+b]],S.hasTarget&&(S.nodeId=S.hasTarget,this.remove(S)),this.bpmnModule&&v instanceof te&&S.processId&&(v.processId=S.processId,this.bpmnModule.dropBPMNchild(this.nameTable[v.processId],v,this)),y.cancel||this.endGroupAction(),"SVG"!==this.mode&&this.refreshDiagramLayer(),delete this.droppable[""+c]):(this.triggerEvent(Ce.drop,y={source:h.droppedElement,element:void 0,target:this.eventHandler.hoverNode||this.eventHandler.lastObjectUnderMouse||this,cancel:!1,position:void 0}),S=void 0,b="id"),this.droppable[M="selectedSymbols"]&&this.droppable[""+M].parentNode)gt(this.droppable[""+M]);else for(w=document.getElementsByClassName("e-dragclone"),C=0;C0)for(var p=0;p1),e.previousSelectedObject=null}}},t.prototype.getDropEventArgs=function(e){if(this.eventHandler.lastObjectUnderMouse||this.eventHandler.hoverNode){var i=this.eventHandler.lastObjectUnderMouse||this.eventHandler.hoverNode;e.target=fs(i)===de?{connector:i}:{node:i}}else e.target.diagramId=this.element.id},t.prototype.removeChildInNodes=function(e){if(e){if(e.children)for(var i=0;i1){var l=2;if(e.children&&e.children.length>0)for(;e.children.indexOf(i.objects[s-l])>-1;)l++;this.commandHandler.moveSvgNode(e.id,i.objects[s-l]),this.commandHandler.moveSvgNode(i.objects[s-l],e.id)}else if(o){var h=this.commandHandler.getLayer(this.layerZIndexTable[o.zIndex]).objects[0];h?(this.commandHandler.moveSvgNode(e.id,h),this.commandHandler.updateNativeNodeIndex(e.id,h)):this.moveObjectsUp(e,i)}else this.moveObjectsUp(e,i)},t.prototype.moveObjectsUp=function(e,i){for(var r,s=this.layers.length-1;s>=0;s--)if(r=this.layers[parseInt(s.toString(),10)],i.id!==r.id){var o=this.commandHandler.getLayer(this.layerZIndexTable[r.zIndex]).objects[r.objects.length-1];if(o){this.commandHandler.moveSvgNode(e.id,o),this.commandHandler.moveSvgNode(o,e.id);break}}},t.prototype.insertData=function(e){return this.crudOperation(e,"create",this.getNewUpdateNodes("New"))},t.prototype.updateData=function(e){return this.crudOperation(e,"update",this.getNewUpdateNodes("Update"))},t.prototype.removeData=function(e){return this.crudOperation(e,"destroy",this.getDeletedNodes())},t.prototype.crudOperation=function(e,i,r){if(e){var s=this.parameterMap(e,!(e instanceof de));if(s){var o=e instanceof de?this.dataSourceSettings.connectionDataSource.crudAction[""+i]:this.dataSourceSettings.crudAction[""+i];this.raiseAjaxPost(JSON.stringify(s),o)}return s}var a=r;return this.processCrudCollection(a,this.dataSourceSettings.crudAction[""+i],this.dataSourceSettings.connectionDataSource.crudAction[""+i]),a},t.prototype.processCrudCollection=function(e,i,r){if(e.nodes){var s=[],o=void 0;for(o=0;o0&&this.raiseAjaxPost(JSON.stringify(s),i)}if(e.connectors){for(s=[],o=void 0,o=0;o0&&this.raiseAjaxPost(JSON.stringify(s),r)}},t.prototype.parameterMap=function(e,i){var s,r={},o=i?this.dataSourceSettings:this.dataSourceSettings.connectionDataSource;if(o.id&&(r[o.id]=e.id),o.sourcePointX&&o.sourcePointY&&(r[o.sourcePointX]=e.sourcePoint.x,r[o.sourcePointY]=e.sourcePoint.y),o.targetPointX&&o.targetPointY&&(r[o.targetPointX]=e.targetPoint.x,r[o.targetPointY]=e.targetPoint.y),o.sourceID&&(r[o.sourceID]=e.sourceID),o.targetID&&(r[o.targetID]=e.targetID),o.crudAction&&o.crudAction.customFields&&o.crudAction.customFields.length>0)for(s=0;s{class n extends ch{constructor(e){super(),this.viewContainerRef=e,gl("currentInstance",this,this.viewContainerRef),this.registerEvents($ae),this.directivePropList=qae}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-layer"]],inputs:{addInfo:"addInfo",id:"id",lock:"lock",objects:"objects",visible:"visible",zIndex:"zIndex"},features:[yn]}),n})(),Jae=(()=>{class n extends dh{constructor(){super("layers")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-layers"]],contentQueries:function(e,i,r){if(1&e&&dn(r,Zae,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),Kae=["action","cursor"],ele=[],tle=(()=>{class n extends ch{constructor(e){super(),this.viewContainerRef=e,gl("currentInstance",this,this.viewContainerRef),this.registerEvents(ele),this.directivePropList=Kae}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-cursormap"]],inputs:{action:"action",cursor:"cursor"},features:[yn]}),n})(),ile=(()=>{class n extends dh{constructor(){super("customcursor")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-cursormaps"]],contentQueries:function(e,i,r){if(1&e&&dn(r,tle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),rle=["alignment","cornerRadius","displacement","fill","handleStrokeColor","handleStrokeWidth","height","iconStrokeColor","iconStrokeWidth","id","offset","padding","pathData","tooltip","visibility","width"],nle=[],sle=(()=>{class n extends ch{constructor(e){super(),this.viewContainerRef=e,gl("currentInstance",this,this.viewContainerRef),this.registerEvents(nle),this.directivePropList=rle}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-connector-fixeduserhandle"]],inputs:{alignment:"alignment",cornerRadius:"cornerRadius",displacement:"displacement",fill:"fill",handleStrokeColor:"handleStrokeColor",handleStrokeWidth:"handleStrokeWidth",height:"height",iconStrokeColor:"iconStrokeColor",iconStrokeWidth:"iconStrokeWidth",id:"id",offset:"offset",padding:"padding",pathData:"pathData",tooltip:"tooltip",visibility:"visibility",width:"width"},features:[yn]}),n})(),ole=(()=>{class n extends dh{constructor(){super("fixeduserhandles")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-connector-fixeduserhandles"]],contentQueries:function(e,i,r){if(1&e&&dn(r,sle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),ale=["addInfo","alignment","annotationType","constraints","content","displacement","dragLimit","height","horizontalAlignment","hyperlink","id","margin","offset","rotateAngle","rotationReference","segmentAngle","style","template","tooltip","type","verticalAlignment","visibility","width"],lle=[],hle=(()=>{class n extends ch{constructor(e){super(),this.viewContainerRef=e,gl("currentInstance",this,this.viewContainerRef),this.registerEvents(lle),this.directivePropList=ale}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-connector-annotation"]],inputs:{addInfo:"addInfo",alignment:"alignment",annotationType:"annotationType",constraints:"constraints",content:"content",displacement:"displacement",dragLimit:"dragLimit",height:"height",horizontalAlignment:"horizontalAlignment",hyperlink:"hyperlink",id:"id",margin:"margin",offset:"offset",rotateAngle:"rotateAngle",rotationReference:"rotationReference",segmentAngle:"segmentAngle",style:"style",template:"template",tooltip:"tooltip",type:"type",verticalAlignment:"verticalAlignment",visibility:"visibility",width:"width"},features:[yn]}),n})(),cle=(()=>{class n extends dh{constructor(){super("annotations")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-connector-annotations"]],contentQueries:function(e,i,r){if(1&e&&dn(r,hle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),dle=["addInfo","allowNodeOverlap","annotations","bezierSettings","bridgeSpace","connectionPadding","connectorSpacing","constraints","cornerRadius","dragSize","excludeFromLayout","fixedUserHandles","flip","flipMode","hitPadding","id","margin","maxSegmentThumb","ports","previewSize","segmentThumbShape","segmentThumbSize","segments","shape","sourceDecorator","sourceID","sourcePadding","sourcePoint","sourcePortID","style","symbolInfo","targetDecorator","targetID","targetPadding","targetPoint","targetPortID","tooltip","type","visible","wrapper","zIndex"],ule=[],ple=(()=>{class n extends ch{constructor(e){super(),this.viewContainerRef=e,this.tags=["fixedUserHandles","annotations"],gl("currentInstance",this,this.viewContainerRef),this.registerEvents(ule),this.directivePropList=dle}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-connector"]],contentQueries:function(e,i,r){if(1&e&&(dn(r,ole,5),dn(r,cle,5)),2&e){let s;Kr(s=en())&&(i.childFixedUserHandles=s.first),Kr(s=en())&&(i.childAnnotations=s.first)}},inputs:{addInfo:"addInfo",allowNodeOverlap:"allowNodeOverlap",annotations:"annotations",bezierSettings:"bezierSettings",bridgeSpace:"bridgeSpace",connectionPadding:"connectionPadding",connectorSpacing:"connectorSpacing",constraints:"constraints",cornerRadius:"cornerRadius",dragSize:"dragSize",excludeFromLayout:"excludeFromLayout",fixedUserHandles:"fixedUserHandles",flip:"flip",flipMode:"flipMode",hitPadding:"hitPadding",id:"id",margin:"margin",maxSegmentThumb:"maxSegmentThumb",ports:"ports",previewSize:"previewSize",segmentThumbShape:"segmentThumbShape",segmentThumbSize:"segmentThumbSize",segments:"segments",shape:"shape",sourceDecorator:"sourceDecorator",sourceID:"sourceID",sourcePadding:"sourcePadding",sourcePoint:"sourcePoint",sourcePortID:"sourcePortID",style:"style",symbolInfo:"symbolInfo",targetDecorator:"targetDecorator",targetID:"targetID",targetPadding:"targetPadding",targetPoint:"targetPoint",targetPortID:"targetPortID",tooltip:"tooltip",type:"type",visible:"visible",wrapper:"wrapper",zIndex:"zIndex"},features:[yn]}),n})(),fle=(()=>{class n extends dh{constructor(){super("connectors")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-connectors"]],contentQueries:function(e,i,r){if(1&e&&dn(r,ple,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),gle=["cornerRadius","fill","handleStrokeColor","handleStrokeWidth","height","iconStrokeColor","iconStrokeWidth","id","margin","offset","padding","pathData","tooltip","visibility","width"],vle=[],mle=(()=>{class n extends ch{constructor(e){super(),this.viewContainerRef=e,gl("currentInstance",this,this.viewContainerRef),this.registerEvents(vle),this.directivePropList=gle}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-node-fixeduserhandle"]],inputs:{cornerRadius:"cornerRadius",fill:"fill",handleStrokeColor:"handleStrokeColor",handleStrokeWidth:"handleStrokeWidth",height:"height",iconStrokeColor:"iconStrokeColor",iconStrokeWidth:"iconStrokeWidth",id:"id",margin:"margin",offset:"offset",padding:"padding",pathData:"pathData",tooltip:"tooltip",visibility:"visibility",width:"width"},features:[yn]}),n})(),yle=(()=>{class n extends dh{constructor(){super("fixeduserhandles")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-node-fixeduserhandles"]],contentQueries:function(e,i,r){if(1&e&&dn(r,mle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),Sle=["addInfo","annotationType","constraints","content","dragLimit","height","horizontalAlignment","hyperlink","id","margin","offset","rotateAngle","rotationReference","style","template","tooltip","type","verticalAlignment","visibility","width"],Ile=[],v_=(()=>{class n extends ch{constructor(e){super(),this.viewContainerRef=e,gl("currentInstance",this,this.viewContainerRef),this.registerEvents(Ile),this.directivePropList=Sle}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-node-annotation"]],inputs:{addInfo:"addInfo",annotationType:"annotationType",constraints:"constraints",content:"content",dragLimit:"dragLimit",height:"height",horizontalAlignment:"horizontalAlignment",hyperlink:"hyperlink",id:"id",margin:"margin",offset:"offset",rotateAngle:"rotateAngle",rotationReference:"rotationReference",style:"style",template:"template",tooltip:"tooltip",type:"type",verticalAlignment:"verticalAlignment",visibility:"visibility",width:"width"},features:[yn]}),n})(),m_=(()=>{class n extends dh{constructor(){super("annotations")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-node-annotations"]],contentQueries:function(e,i,r){if(1&e&&dn(r,v_,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),ble=["addInfo","connectionDirection","constraints","height","horizontalAlignment","id","inEdges","margin","offset","outEdges","pathData","shape","style","tooltip","verticalAlignment","visibility","width"],Mle=[],wle=(()=>{class n extends ch{constructor(e){super(),this.viewContainerRef=e,gl("currentInstance",this,this.viewContainerRef),this.registerEvents(Mle),this.directivePropList=ble}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-node-port"]],inputs:{addInfo:"addInfo",connectionDirection:"connectionDirection",constraints:"constraints",height:"height",horizontalAlignment:"horizontalAlignment",id:"id",inEdges:"inEdges",margin:"margin",offset:"offset",outEdges:"outEdges",pathData:"pathData",shape:"shape",style:"style",tooltip:"tooltip",verticalAlignment:"verticalAlignment",visibility:"visibility",width:"width"},features:[yn]}),n})(),Cle=(()=>{class n extends dh{constructor(){super("ports")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-node-ports"]],contentQueries:function(e,i,r){if(1&e&&dn(r,wle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),Ele=["addInfo","annotations","backgroundColor","borderColor","borderWidth","branch","children","collapseIcon","columnIndex","columnSpan","columns","constraints","container","data","dragSize","excludeFromLayout","expandIcon","fixedUserHandles","flip","flipMode","height","horizontalAlignment","id","isExpanded","layoutInfo","margin","maxHeight","maxWidth","minHeight","minWidth","offsetX","offsetY","padding","pivot","ports","previewSize","rotateAngle","rowIndex","rowSpan","rows","shadow","shape","style","symbolInfo","tooltip","verticalAlignment","visible","width","wrapper","zIndex"],Dle=[],y_=(()=>{class n extends ch{constructor(e){super(),this.viewContainerRef=e,this.tags=["fixedUserHandles","annotations","ports"],gl("currentInstance",this,this.viewContainerRef),this.registerEvents(Dle),this.directivePropList=Ele}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-node"]],contentQueries:function(e,i,r){if(1&e&&(dn(r,yle,5),dn(r,m_,5),dn(r,Cle,5)),2&e){let s;Kr(s=en())&&(i.childFixedUserHandles=s.first),Kr(s=en())&&(i.childAnnotations=s.first),Kr(s=en())&&(i.childPorts=s.first)}},inputs:{addInfo:"addInfo",annotations:"annotations",backgroundColor:"backgroundColor",borderColor:"borderColor",borderWidth:"borderWidth",branch:"branch",children:"children",collapseIcon:"collapseIcon",columnIndex:"columnIndex",columnSpan:"columnSpan",columns:"columns",constraints:"constraints",container:"container",data:"data",dragSize:"dragSize",excludeFromLayout:"excludeFromLayout",expandIcon:"expandIcon",fixedUserHandles:"fixedUserHandles",flip:"flip",flipMode:"flipMode",height:"height",horizontalAlignment:"horizontalAlignment",id:"id",isExpanded:"isExpanded",layoutInfo:"layoutInfo",margin:"margin",maxHeight:"maxHeight",maxWidth:"maxWidth",minHeight:"minHeight",minWidth:"minWidth",offsetX:"offsetX",offsetY:"offsetY",padding:"padding",pivot:"pivot",ports:"ports",previewSize:"previewSize",rotateAngle:"rotateAngle",rowIndex:"rowIndex",rowSpan:"rowSpan",rows:"rows",shadow:"shadow",shape:"shape",style:"style",symbolInfo:"symbolInfo",tooltip:"tooltip",verticalAlignment:"verticalAlignment",visible:"visible",width:"width",wrapper:"wrapper",zIndex:"zIndex"},features:[yn]}),n})(),S_=(()=>{class n extends dh{constructor(){super("nodes")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-nodes"]],contentQueries:function(e,i,r){if(1&e&&dn(r,y_,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})();const xle=["animationComplete","click","collectionChange","commandExecute","connectionChange","contextMenuBeforeItemRender","contextMenuClick","contextMenuOpen","created","dataLoaded","doubleClick","dragEnter","dragLeave","dragOver","drop","elementDraw","expandStateChange","fixedUserHandleClick","historyChange","historyStateChange","keyDown","keyUp","load","loaded","mouseEnter","mouseLeave","mouseOver","mouseWheel","onFixedUserHandleMouseDown","onFixedUserHandleMouseEnter","onFixedUserHandleMouseLeave","onFixedUserHandleMouseUp","onImageLoad","onUserHandleMouseDown","onUserHandleMouseEnter","onUserHandleMouseLeave","onUserHandleMouseUp","positionChange","propertyChange","rotateChange","scrollChange","segmentChange","segmentCollectionChange","selectionChange","sizeChange","sourcePointChange","targetPointChange","textEdit"],Tle=[""];let Ale=(()=>{let n=class extends Rl{constructor(e,i,r,s){super(),this.ngEle=e,this.srenderer=i,this.viewContainerRef=r,this.injector=s,this.tags=["layers","customCursor","connectors","nodes"],this.element=this.ngEle.nativeElement,this.injectedModules=this.injectedModules||[];try{let o=this.injector.get("DiagramsHierarchicalTree");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsMindMap");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsRadialTree");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsComplexHierarchicalTree");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsDataBinding");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsSnapping");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsPrintAndExport");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsBpmnDiagrams");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsSymmetricLayout");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsConnectorBridging");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsUndoRedo");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsLayoutAnimation");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsDiagramContextMenu");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsLineRouting");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsConnectorEditing");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsLineDistribution");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsEj1Serialization");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsFlowchartLayout");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}this.registerEvents(xle),this.addTwoWay.call(this,Tle),gl("currentInstance",this,this.viewContainerRef),this.context=new SR}ngOnInit(){this.context.ngOnInit(this)}ngAfterViewInit(){this.context.ngAfterViewInit(this)}ngOnDestroy(){this.context.ngOnDestroy(this)}ngAfterContentChecked(){this.tagObjects[0].instance=this.childLayers,this.childCustomCursor&&(this.tagObjects[1].instance=this.childCustomCursor),this.childConnectors&&(this.tagObjects[2].instance=this.childConnectors),this.childNodes&&(this.tagObjects[3].instance=this.childNodes),this.context.ngAfterContentChecked(this)}};return n.\u0275fac=function(e){return new(e||n)(Ot(Jc),Ot(cM),Ot(xn),Ot(Wo))},n.\u0275cmp=_b({type:n,selectors:[["ejs-diagram"]],contentQueries:function(e,i,r){if(1&e&&(dn(r,Qae,5),dn(r,Gae,5),dn(r,Xae,5),dn(r,Jae,5),dn(r,ile,5),dn(r,fle,5),dn(r,S_,5)),2&e){let s;Kr(s=en())&&(i.annotationTemplate=s.first),Kr(s=en())&&(i.nodeTemplate=s.first),Kr(s=en())&&(i.userHandleTemplate=s.first),Kr(s=en())&&(i.childLayers=s.first),Kr(s=en())&&(i.childCustomCursor=s.first),Kr(s=en())&&(i.childConnectors=s.first),Kr(s=en())&&(i.childNodes=s.first)}},inputs:{addInfo:"addInfo",annotationTemplate:"annotationTemplate",backgroundColor:"backgroundColor",bridgeDirection:"bridgeDirection",commandManager:"commandManager",connectorDefaults:"connectorDefaults",connectors:"connectors",constraints:"constraints",contextMenuSettings:"contextMenuSettings",customCursor:"customCursor",dataSourceSettings:"dataSourceSettings",diagramSettings:"diagramSettings",drawingObject:"drawingObject",enableConnectorSplit:"enableConnectorSplit",enablePersistence:"enablePersistence",enableRtl:"enableRtl",fixedUserHandleTemplate:"fixedUserHandleTemplate",getConnectorDefaults:"getConnectorDefaults",getCustomCursor:"getCustomCursor",getCustomProperty:"getCustomProperty",getCustomTool:"getCustomTool",getDescription:"getDescription",getNodeDefaults:"getNodeDefaults",height:"height",historyManager:"historyManager",layers:"layers",layout:"layout",locale:"locale",mode:"mode",nodeDefaults:"nodeDefaults",nodeTemplate:"nodeTemplate",nodes:"nodes",pageSettings:"pageSettings",rulerSettings:"rulerSettings",scrollSettings:"scrollSettings",segmentThumbShape:"segmentThumbShape",segmentThumbSize:"segmentThumbSize",selectedItems:"selectedItems",serializationSettings:"serializationSettings",setNodeTemplate:"setNodeTemplate",snapSettings:"snapSettings",tool:"tool",tooltip:"tooltip",updateSelection:"updateSelection",userHandleTemplate:"userHandleTemplate",width:"width"},outputs:{animationComplete:"animationComplete",click:"click",collectionChange:"collectionChange",commandExecute:"commandExecute",connectionChange:"connectionChange",contextMenuBeforeItemRender:"contextMenuBeforeItemRender",contextMenuClick:"contextMenuClick",contextMenuOpen:"contextMenuOpen",created:"created",dataLoaded:"dataLoaded",doubleClick:"doubleClick",dragEnter:"dragEnter",dragLeave:"dragLeave",dragOver:"dragOver",drop:"drop",elementDraw:"elementDraw",expandStateChange:"expandStateChange",fixedUserHandleClick:"fixedUserHandleClick",historyChange:"historyChange",historyStateChange:"historyStateChange",keyDown:"keyDown",keyUp:"keyUp",load:"load",loaded:"loaded",mouseEnter:"mouseEnter",mouseLeave:"mouseLeave",mouseOver:"mouseOver",mouseWheel:"mouseWheel",onFixedUserHandleMouseDown:"onFixedUserHandleMouseDown",onFixedUserHandleMouseEnter:"onFixedUserHandleMouseEnter",onFixedUserHandleMouseLeave:"onFixedUserHandleMouseLeave",onFixedUserHandleMouseUp:"onFixedUserHandleMouseUp",onImageLoad:"onImageLoad",onUserHandleMouseDown:"onUserHandleMouseDown",onUserHandleMouseEnter:"onUserHandleMouseEnter",onUserHandleMouseLeave:"onUserHandleMouseLeave",onUserHandleMouseUp:"onUserHandleMouseUp",positionChange:"positionChange",propertyChange:"propertyChange",rotateChange:"rotateChange",scrollChange:"scrollChange",segmentChange:"segmentChange",segmentCollectionChange:"segmentCollectionChange",selectionChange:"selectionChange",sizeChange:"sizeChange",sourcePointChange:"sourcePointChange",targetPointChange:"targetPointChange",textEdit:"textEdit"},features:[yn],decls:0,vars:0,template:function(e,i){},encapsulation:2,changeDetection:0}),k0([xC()],n.prototype,"annotationTemplate",void 0),k0([xC()],n.prototype,"nodeTemplate",void 0),k0([xC()],n.prototype,"userHandleTemplate",void 0),n=k0([PZ([SR])],n),n})(),Lle=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Nm({type:n}),n.\u0275inj=yf({imports:[[sq]]}),n})();const Nle=["diagram"];let Ole=(()=>{class n{constructor(){this.layers=[]}ngOnInit(){this.layers=[{id:"layer1",objects:["node1"]},{id:"layers2",objects:["node2"]},{id:"layers3",objects:["node3"]}]}bringLayerForward(){this.diagram.bringLayerForward("layer1")}sendLayerBackward(){this.diagram.sendLayerBackward("layer1")}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275cmp=_b({type:n,selectors:[["app-container"]],viewQuery:function(i,r){if(1&i&&function pP(n,t,e){const i=xi();i.firstCreatePass&&(dP(i,new lP(n,t,e),-1),2==(2&t)&&(i.staticViewQueries=!0)),cP(i,Se(),t)}(Nle,5),2&i){let s;Kr(s=en())&&(r.diagram=s.first)}},standalone:!0,features:[PP([]),RP],decls:16,vars:13,consts:[["id","diagram","width","100%","height","580px",3,"layers"],["diagram",""],["id","node1",3,"width","height","offsetX","offsetY"],["content","Layer 1 Object"],["id","node2",3,"width","height","offsetX","offsetY"],["content","Layer 2 Object"],["id","node3",3,"width","height","offsetX","offsetY"],["content","Layer 3 Object"],[3,"click"]],template:function(i,r){1&i&&(rc(0,"ejs-diagram",0,1)(2,"e-nodes")(3,"e-node",2)(4,"e-node-annotations"),dg(5,"e-node-annotation",3),nc()(),rc(6,"e-node",4)(7,"e-node-annotations"),dg(8,"e-node-annotation",5),nc()(),rc(9,"e-node",6)(10,"e-node-annotations"),dg(11,"e-node-annotation",7),nc()()()(),rc(12,"button",8),Gy("click",function(){return r.bringLayerForward()}),gw(13,"bringLayerForward"),nc(),rc(14,"button",8),Gy("click",function(){return r.sendLayerBackward()}),gw(15,"sendLayerBackward"),nc()),2&i&&(Xu("layers",r.layers),Ey(3),Xu("width",100)("height",100)("offsetX",100)("offsetY",100),Ey(3),Xu("width",100)("height",100)("offsetX",130)("offsetY",130),Ey(3),Xu("width",100)("height",100)("offsetX",160)("offsetY",160))},dependencies:[Lle,Ale,v_,m_,y_,S_],encapsulation:2})}}return n})();Vd(332),function $q(n,t){return DG({rootComponent:n,...Ez(t)})}(Ole).catch(n=>console.error(n))},332:()=>{!function(Z){const se=Z.performance;function ye(Pi){se&&se.mark&&se.mark(Pi)}function fe(Pi,ht){se&&se.measure&&se.measure(Pi,ht)}ye("Zone");const be=Z.__Zone_symbol_prefix||"__zone_symbol__";function ke(Pi){return be+Pi}const at=!0===Z[ke("forceDuplicateZoneCheck")];if(Z.Zone){if(at||"function"!=typeof Z.Zone.__symbol__)throw new Error("Zone already loaded.");return Z.Zone}let tt=(()=>{class Pi{static{this.__symbol__=ke}static assertZonePatched(){if(Z.Promise!==_o.ZoneAwarePromise)throw new Error("Zone.js has detected that ZoneAwarePromise `(window|global).Promise` has been overwritten.\nMost likely cause is that a Promise polyfill has been loaded after Zone.js (Polyfilling Promise api is not necessary when zone.js is loaded. If you must load one, do so before loading zone.js.)")}static get root(){let F=Pi.current;for(;F.parent;)F=F.parent;return F}static get current(){return Ur.zone}static get currentTask(){return Do}static __load_patch(F,ae,Et=!1){if(_o.hasOwnProperty(F)){if(!Et&&at)throw Error("Already loaded patch: "+F)}else if(!Z["__Zone_disable_"+F]){const Xt="Zone:"+F;ye(Xt),_o[F]=ae(Z,Pi,cn),fe(Xt,Xt)}}get parent(){return this._parent}get name(){return this._name}constructor(F,ae){this._parent=F,this._name=ae?ae.name||"unnamed":"",this._properties=ae&&ae.properties||{},this._zoneDelegate=new Lt(this,this._parent&&this._parent._zoneDelegate,ae)}get(F){const ae=this.getZoneWith(F);if(ae)return ae._properties[F]}getZoneWith(F){let ae=this;for(;ae;){if(ae._properties.hasOwnProperty(F))return ae;ae=ae._parent}return null}fork(F){if(!F)throw new Error("ZoneSpec required!");return this._zoneDelegate.fork(this,F)}wrap(F,ae){if("function"!=typeof F)throw new Error("Expecting function got: "+F);const Et=this._zoneDelegate.intercept(this,F,ae),Xt=this;return function(){return Xt.runGuarded(Et,this,arguments,ae)}}run(F,ae,Et,Xt){Ur={parent:Ur,zone:this};try{return this._zoneDelegate.invoke(this,F,ae,Et,Xt)}finally{Ur=Ur.parent}}runGuarded(F,ae=null,Et,Xt){Ur={parent:Ur,zone:this};try{try{return this._zoneDelegate.invoke(this,F,ae,Et,Xt)}catch(Un){if(this._zoneDelegate.handleError(this,Un))throw Un}}finally{Ur=Ur.parent}}runTask(F,ae,Et){if(F.zone!=this)throw new Error("A task can only be run in the zone of creation! (Creation: "+(F.zone||_n).name+"; Execution: "+this.name+")");if(F.state===sr&&(F.type===ts||F.type===Pt))return;const Xt=F.state!=lt;Xt&&F._transitionTo(lt,ki),F.runCount++;const Un=Do;Do=F,Ur={parent:Ur,zone:this};try{F.type==Pt&&F.data&&!F.data.isPeriodic&&(F.cancelFn=void 0);try{return this._zoneDelegate.invokeTask(this,F,ae,Et)}catch(Ue){if(this._zoneDelegate.handleError(this,Ue))throw Ue}}finally{F.state!==sr&&F.state!==et&&(F.type==ts||F.data&&F.data.isPeriodic?Xt&&F._transitionTo(ki,lt):(F.runCount=0,this._updateTaskCount(F,-1),Xt&&F._transitionTo(sr,lt,sr))),Ur=Ur.parent,Do=Un}}scheduleTask(F){if(F.zone&&F.zone!==this){let Et=this;for(;Et;){if(Et===F.zone)throw Error(`can not reschedule task to ${this.name} which is descendants of the original zone ${F.zone.name}`);Et=Et.parent}}F._transitionTo(Zr,sr);const ae=[];F._zoneDelegates=ae,F._zone=this;try{F=this._zoneDelegate.scheduleTask(this,F)}catch(Et){throw F._transitionTo(et,Zr,sr),this._zoneDelegate.handleError(this,Et),Et}return F._zoneDelegates===ae&&this._updateTaskCount(F,1),F.state==Zr&&F._transitionTo(ki,Zr),F}scheduleMicroTask(F,ae,Et,Xt){return this.scheduleTask(new ft(vi,F,ae,Et,Xt,void 0))}scheduleMacroTask(F,ae,Et,Xt,Un){return this.scheduleTask(new ft(Pt,F,ae,Et,Xt,Un))}scheduleEventTask(F,ae,Et,Xt,Un){return this.scheduleTask(new ft(ts,F,ae,Et,Xt,Un))}cancelTask(F){if(F.zone!=this)throw new Error("A task can only be cancelled in the zone of creation! (Creation: "+(F.zone||_n).name+"; Execution: "+this.name+")");if(F.state===ki||F.state===lt){F._transitionTo(dr,ki,lt);try{this._zoneDelegate.cancelTask(this,F)}catch(ae){throw F._transitionTo(et,dr),this._zoneDelegate.handleError(this,ae),ae}return this._updateTaskCount(F,-1),F._transitionTo(sr,dr),F.runCount=0,F}}_updateTaskCount(F,ae){const Et=F._zoneDelegates;-1==ae&&(F._zoneDelegates=null);for(let Xt=0;XtPi.hasTask(F,ae),onScheduleTask:(Pi,ht,F,ae)=>Pi.scheduleTask(F,ae),onInvokeTask:(Pi,ht,F,ae,Et,Xt)=>Pi.invokeTask(F,ae,Et,Xt),onCancelTask:(Pi,ht,F,ae)=>Pi.cancelTask(F,ae)};class Lt{constructor(ht,F,ae){this._taskCounts={microTask:0,macroTask:0,eventTask:0},this.zone=ht,this._parentDelegate=F,this._forkZS=ae&&(ae&&ae.onFork?ae:F._forkZS),this._forkDlgt=ae&&(ae.onFork?F:F._forkDlgt),this._forkCurrZone=ae&&(ae.onFork?this.zone:F._forkCurrZone),this._interceptZS=ae&&(ae.onIntercept?ae:F._interceptZS),this._interceptDlgt=ae&&(ae.onIntercept?F:F._interceptDlgt),this._interceptCurrZone=ae&&(ae.onIntercept?this.zone:F._interceptCurrZone),this._invokeZS=ae&&(ae.onInvoke?ae:F._invokeZS),this._invokeDlgt=ae&&(ae.onInvoke?F:F._invokeDlgt),this._invokeCurrZone=ae&&(ae.onInvoke?this.zone:F._invokeCurrZone),this._handleErrorZS=ae&&(ae.onHandleError?ae:F._handleErrorZS),this._handleErrorDlgt=ae&&(ae.onHandleError?F:F._handleErrorDlgt),this._handleErrorCurrZone=ae&&(ae.onHandleError?this.zone:F._handleErrorCurrZone),this._scheduleTaskZS=ae&&(ae.onScheduleTask?ae:F._scheduleTaskZS),this._scheduleTaskDlgt=ae&&(ae.onScheduleTask?F:F._scheduleTaskDlgt),this._scheduleTaskCurrZone=ae&&(ae.onScheduleTask?this.zone:F._scheduleTaskCurrZone),this._invokeTaskZS=ae&&(ae.onInvokeTask?ae:F._invokeTaskZS),this._invokeTaskDlgt=ae&&(ae.onInvokeTask?F:F._invokeTaskDlgt),this._invokeTaskCurrZone=ae&&(ae.onInvokeTask?this.zone:F._invokeTaskCurrZone),this._cancelTaskZS=ae&&(ae.onCancelTask?ae:F._cancelTaskZS),this._cancelTaskDlgt=ae&&(ae.onCancelTask?F:F._cancelTaskDlgt),this._cancelTaskCurrZone=ae&&(ae.onCancelTask?this.zone:F._cancelTaskCurrZone),this._hasTaskZS=null,this._hasTaskDlgt=null,this._hasTaskDlgtOwner=null,this._hasTaskCurrZone=null;const Et=ae&&ae.onHasTask;(Et||F&&F._hasTaskZS)&&(this._hasTaskZS=Et?ae:At,this._hasTaskDlgt=F,this._hasTaskDlgtOwner=this,this._hasTaskCurrZone=ht,ae.onScheduleTask||(this._scheduleTaskZS=At,this._scheduleTaskDlgt=F,this._scheduleTaskCurrZone=this.zone),ae.onInvokeTask||(this._invokeTaskZS=At,this._invokeTaskDlgt=F,this._invokeTaskCurrZone=this.zone),ae.onCancelTask||(this._cancelTaskZS=At,this._cancelTaskDlgt=F,this._cancelTaskCurrZone=this.zone))}fork(ht,F){return this._forkZS?this._forkZS.onFork(this._forkDlgt,this.zone,ht,F):new tt(ht,F)}intercept(ht,F,ae){return this._interceptZS?this._interceptZS.onIntercept(this._interceptDlgt,this._interceptCurrZone,ht,F,ae):F}invoke(ht,F,ae,Et,Xt){return this._invokeZS?this._invokeZS.onInvoke(this._invokeDlgt,this._invokeCurrZone,ht,F,ae,Et,Xt):F.apply(ae,Et)}handleError(ht,F){return!this._handleErrorZS||this._handleErrorZS.onHandleError(this._handleErrorDlgt,this._handleErrorCurrZone,ht,F)}scheduleTask(ht,F){let ae=F;if(this._scheduleTaskZS)this._hasTaskZS&&ae._zoneDelegates.push(this._hasTaskDlgtOwner),ae=this._scheduleTaskZS.onScheduleTask(this._scheduleTaskDlgt,this._scheduleTaskCurrZone,ht,F),ae||(ae=F);else if(F.scheduleFn)F.scheduleFn(F);else{if(F.type!=vi)throw new Error("Task is missing scheduleFn.");Wt(F)}return ae}invokeTask(ht,F,ae,Et){return this._invokeTaskZS?this._invokeTaskZS.onInvokeTask(this._invokeTaskDlgt,this._invokeTaskCurrZone,ht,F,ae,Et):F.callback.apply(ae,Et)}cancelTask(ht,F){let ae;if(this._cancelTaskZS)ae=this._cancelTaskZS.onCancelTask(this._cancelTaskDlgt,this._cancelTaskCurrZone,ht,F);else{if(!F.cancelFn)throw Error("Task is not cancelable");ae=F.cancelFn(F)}return ae}hasTask(ht,F){try{this._hasTaskZS&&this._hasTaskZS.onHasTask(this._hasTaskDlgt,this._hasTaskCurrZone,ht,F)}catch(ae){this.handleError(ht,ae)}}_updateTaskCount(ht,F){const ae=this._taskCounts,Et=ae[ht],Xt=ae[ht]=Et+F;if(Xt<0)throw new Error("More tasks executed then were scheduled.");0!=Et&&0!=Xt||this.hasTask(this.zone,{microTask:ae.microTask>0,macroTask:ae.macroTask>0,eventTask:ae.eventTask>0,change:ht})}}class ft{constructor(ht,F,ae,Et,Xt,Un){if(this._zone=null,this.runCount=0,this._zoneDelegates=null,this._state="notScheduled",this.type=ht,this.source=F,this.data=Et,this.scheduleFn=Xt,this.cancelFn=Un,!ae)throw new Error("callback is not defined");this.callback=ae;const Ue=this;this.invoke=ht===ts&&Et&&Et.useG?ft.invokeTask:function(){return ft.invokeTask.call(Z,Ue,this,arguments)}}static invokeTask(ht,F,ae){ht||(ht=this),Ls++;try{return ht.runCount++,ht.zone.runTask(ht,F,ae)}finally{1==Ls&&ct(),Ls--}}get zone(){return this._zone}get state(){return this._state}cancelScheduleRequest(){this._transitionTo(sr,Zr)}_transitionTo(ht,F,ae){if(this._state!==F&&this._state!==ae)throw new Error(`${this.type} '${this.source}': can not transition to '${ht}', expecting state '${F}'${ae?" or '"+ae+"'":""}, was '${this._state}'.`);this._state=ht,ht==sr&&(this._zoneDelegates=null)}toString(){return this.data&&typeof this.data.handleId<"u"?this.data.handleId.toString():Object.prototype.toString.call(this)}toJSON(){return{type:this.type,state:this.state,source:this.source,zone:this.zone.name,runCount:this.runCount}}}const Ei=ke("setTimeout"),ti=ke("Promise"),gi=ke("then");let es,cr=[],Oi=!1;function kr(Pi){if(es||Z[ti]&&(es=Z[ti].resolve(0)),es){let ht=es[gi];ht||(ht=es.then),ht.call(es,Pi)}else Z[Ei](Pi,0)}function Wt(Pi){0===Ls&&0===cr.length&&kr(ct),Pi&&cr.push(Pi)}function ct(){if(!Oi){for(Oi=!0;cr.length;){const Pi=cr;cr=[];for(let ht=0;htUr,onUnhandledError:jr,microtaskDrainDone:jr,scheduleMicroTask:Wt,showUncaughtError:()=>!tt[ke("ignoreConsoleErrorUncaughtError")],patchEventTarget:()=>[],patchOnProperties:jr,patchMethod:()=>jr,bindArguments:()=>[],patchThen:()=>jr,patchMacroTask:()=>jr,patchEventPrototype:()=>jr,isIEOrEdge:()=>!1,getGlobalObjects:()=>{},ObjectDefineProperty:()=>jr,ObjectGetOwnPropertyDescriptor:()=>{},ObjectCreate:()=>{},ArraySlice:()=>[],patchClass:()=>jr,wrapWithCurrentZone:()=>jr,filterProperties:()=>[],attachOriginToPatched:()=>jr,_redefineProperty:()=>jr,patchCallbacks:()=>jr,nativeScheduleMicroTask:kr};let Ur={parent:null,zone:new tt(null,null)},Do=null,Ls=0;function jr(){}fe("Zone","Zone"),Z.Zone=tt}(globalThis);const _l=Object.getOwnPropertyDescriptor,jd=Object.defineProperty,Vd=Object.getPrototypeOf,Wd=Object.create,Sb=Array.prototype.slice,gm="addEventListener",$r="removeEventListener",Ul=Zone.__symbol__(gm),Fh=Zone.__symbol__($r),Ts="true",Wi="false",Yd=Zone.__symbol__("");function hf(Z,se){return Zone.current.wrap(Z,se)}function vm(Z,se,ye,fe,be){return Zone.current.scheduleMacroTask(Z,se,ye,fe,be)}const Ji=Zone.__symbol__,_h=typeof window<"u",Uh=_h?window:void 0,gn=_h&&Uh||globalThis,mm="removeAttribute";function Qd(Z,se){for(let ye=Z.length-1;ye>=0;ye--)"function"==typeof Z[ye]&&(Z[ye]=hf(Z[ye],se+"_"+ye));return Z}function cf(Z){return!Z||!1!==Z.writable&&!("function"==typeof Z.get&&typeof Z.set>"u")}const df=typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope,jh=!("nw"in gn)&&typeof gn.process<"u"&&"[object process]"==={}.toString.call(gn.process),Gd=!jh&&!df&&!(!_h||!Uh.HTMLElement),uf=typeof gn.process<"u"&&"[object process]"==={}.toString.call(gn.process)&&!df&&!(!_h||!Uh.HTMLElement),jl={},Vh=function(Z){if(!(Z=Z||gn.event))return;let se=jl[Z.type];se||(se=jl[Z.type]=Ji("ON_PROPERTY"+Z.type));const ye=this||Z.target||gn,fe=ye[se];let be;return Gd&&ye===Uh&&"error"===Z.type?(be=fe&&fe.call(this,Z.message,Z.filename,Z.lineno,Z.colno,Z.error),!0===be&&Z.preventDefault()):(be=fe&&fe.apply(this,arguments),null!=be&&!be&&Z.preventDefault()),be};function Vl(Z,se,ye){let fe=_l(Z,se);if(!fe&&ye&&_l(ye,se)&&(fe={enumerable:!0,configurable:!0}),!fe||!fe.configurable)return;const be=Ji("on"+se+"patched");if(Z.hasOwnProperty(be)&&Z[be])return;delete fe.writable,delete fe.value;const ke=fe.get,at=fe.set,tt=se.slice(2);let At=jl[tt];At||(At=jl[tt]=Ji("ON_PROPERTY"+tt)),fe.set=function(Lt){let ft=this;!ft&&Z===gn&&(ft=gn),ft&&("function"==typeof ft[At]&&ft.removeEventListener(tt,Vh),at&&at.call(ft,null),ft[At]=Lt,"function"==typeof Lt&&ft.addEventListener(tt,Vh,!1))},fe.get=function(){let Lt=this;if(!Lt&&Z===gn&&(Lt=gn),!Lt)return null;const ft=Lt[At];if(ft)return ft;if(ke){let Ei=ke.call(this);if(Ei)return fe.set.call(this,Ei),"function"==typeof Lt[mm]&&Lt.removeAttribute(se),Ei}return null},jd(Z,se,fe),Z[be]=!0}function pf(Z,se,ye){if(se)for(let fe=0;fefunction(at,tt){const At=ye(at,tt);return At.cbIdx>=0&&"function"==typeof tt[At.cbIdx]?vm(At.name,tt[At.cbIdx],At,be):ke.apply(at,tt)})}function Sa(Z,se){Z[Ji("OriginalDelegate")]=se}let bb=!1,qd=!1;function Mb(){if(bb)return qd;bb=!0;try{const Z=Uh.navigator.userAgent;(-1!==Z.indexOf("MSIE ")||-1!==Z.indexOf("Trident/")||-1!==Z.indexOf("Edge/"))&&(qd=!0)}catch{}return qd}Zone.__load_patch("ZoneAwarePromise",(Z,se,ye)=>{const fe=Object.getOwnPropertyDescriptor,be=Object.defineProperty,at=ye.symbol,tt=[],At=!1!==Z[at("DISABLE_WRAPPING_UNCAUGHT_PROMISE_REJECTION")],Lt=at("Promise"),ft=at("then"),Ei="__creationTrace__";ye.onUnhandledError=Ue=>{if(ye.showUncaughtError()){const He=Ue&&Ue.rejection;He?console.error("Unhandled Promise rejection:",He instanceof Error?He.message:He,"; Zone:",Ue.zone.name,"; Task:",Ue.task&&Ue.task.source,"; Value:",He,He instanceof Error?He.stack:void 0):console.error(Ue)}},ye.microtaskDrainDone=()=>{for(;tt.length;){const Ue=tt.shift();try{Ue.zone.runGuarded(()=>{throw Ue.throwOriginal?Ue.rejection:Ue})}catch(He){gi(He)}}};const ti=at("unhandledPromiseRejectionHandler");function gi(Ue){ye.onUnhandledError(Ue);try{const He=se[ti];"function"==typeof He&&He.call(this,Ue)}catch{}}function cr(Ue){return Ue&&Ue.then}function Oi(Ue){return Ue}function es(Ue){return F.reject(Ue)}const kr=at("state"),Wt=at("value"),ct=at("finally"),_n=at("parentPromiseValue"),sr=at("parentPromiseState"),Zr="Promise.then",ki=null,lt=!0,dr=!1,et=0;function vi(Ue,He){return ge=>{try{cn(Ue,He,ge)}catch(We){cn(Ue,!1,We)}}}const Pt=function(){let Ue=!1;return function(ge){return function(){Ue||(Ue=!0,ge.apply(null,arguments))}}},ts="Promise resolved with itself",_o=at("currentTaskTrace");function cn(Ue,He,ge){const We=Pt();if(Ue===ge)throw new TypeError(ts);if(Ue[kr]===ki){let wt=null;try{("object"==typeof ge||"function"==typeof ge)&&(wt=ge&&ge.then)}catch(Xe){return We(()=>{cn(Ue,!1,Xe)})(),Ue}if(He!==dr&&ge instanceof F&&ge.hasOwnProperty(kr)&&ge.hasOwnProperty(Wt)&&ge[kr]!==ki)Do(ge),cn(Ue,ge[kr],ge[Wt]);else if(He!==dr&&"function"==typeof wt)try{wt.call(ge,We(vi(Ue,He)),We(vi(Ue,!1)))}catch(Xe){We(()=>{cn(Ue,!1,Xe)})()}else{Ue[kr]=He;const Xe=Ue[Wt];if(Ue[Wt]=ge,Ue[ct]===ct&&He===lt&&(Ue[kr]=Ue[sr],Ue[Wt]=Ue[_n]),He===dr&&ge instanceof Error){const mt=se.currentTask&&se.currentTask.data&&se.currentTask.data[Ei];mt&&be(ge,_o,{configurable:!0,enumerable:!1,writable:!0,value:mt})}for(let mt=0;mt{try{const dt=Ue[Wt],qt=!!ge&&ct===ge[ct];qt&&(ge[_n]=dt,ge[sr]=Xe);const ai=He.run(mt,void 0,qt&&mt!==es&&mt!==Oi?[]:[dt]);cn(ge,!0,ai)}catch(dt){cn(ge,!1,dt)}},ge)}const Pi=function(){},ht=Z.AggregateError;class F{static toString(){return"function ZoneAwarePromise() { [native code] }"}static resolve(He){return He instanceof F?He:cn(new this(null),lt,He)}static reject(He){return cn(new this(null),dr,He)}static withResolvers(){const He={};return He.promise=new F((ge,We)=>{He.resolve=ge,He.reject=We}),He}static any(He){if(!He||"function"!=typeof He[Symbol.iterator])return Promise.reject(new ht([],"All promises were rejected"));const ge=[];let We=0;try{for(let mt of He)We++,ge.push(F.resolve(mt))}catch{return Promise.reject(new ht([],"All promises were rejected"))}if(0===We)return Promise.reject(new ht([],"All promises were rejected"));let wt=!1;const Xe=[];return new F((mt,dt)=>{for(let qt=0;qt{wt||(wt=!0,mt(ai))},ai=>{Xe.push(ai),We--,0===We&&(wt=!0,dt(new ht(Xe,"All promises were rejected")))})})}static race(He){let ge,We,wt=new this((dt,qt)=>{ge=dt,We=qt});function Xe(dt){ge(dt)}function mt(dt){We(dt)}for(let dt of He)cr(dt)||(dt=this.resolve(dt)),dt.then(Xe,mt);return wt}static all(He){return F.allWithCallback(He)}static allSettled(He){return(this&&this.prototype instanceof F?this:F).allWithCallback(He,{thenCallback:We=>({status:"fulfilled",value:We}),errorCallback:We=>({status:"rejected",reason:We})})}static allWithCallback(He,ge){let We,wt,Xe=new this((ai,ur)=>{We=ai,wt=ur}),mt=2,dt=0;const qt=[];for(let ai of He){cr(ai)||(ai=this.resolve(ai));const ur=dt;try{ai.then(ir=>{qt[ur]=ge?ge.thenCallback(ir):ir,mt--,0===mt&&We(qt)},ir=>{ge?(qt[ur]=ge.errorCallback(ir),mt--,0===mt&&We(qt)):wt(ir)})}catch(ir){wt(ir)}mt++,dt++}return mt-=2,0===mt&&We(qt),Xe}constructor(He){const ge=this;if(!(ge instanceof F))throw new Error("Must be an instanceof Promise.");ge[kr]=ki,ge[Wt]=[];try{const We=Pt();He&&He(We(vi(ge,lt)),We(vi(ge,dr)))}catch(We){cn(ge,!1,We)}}get[Symbol.toStringTag](){return"Promise"}get[Symbol.species](){return F}then(He,ge){let We=this.constructor?.[Symbol.species];(!We||"function"!=typeof We)&&(We=this.constructor||F);const wt=new We(Pi),Xe=se.current;return this[kr]==ki?this[Wt].push(Xe,wt,He,ge):Ls(this,Xe,wt,He,ge),wt}catch(He){return this.then(null,He)}finally(He){let ge=this.constructor?.[Symbol.species];(!ge||"function"!=typeof ge)&&(ge=F);const We=new ge(Pi);We[ct]=ct;const wt=se.current;return this[kr]==ki?this[Wt].push(wt,We,He,He):Ls(this,wt,We,He,He),We}}F.resolve=F.resolve,F.reject=F.reject,F.race=F.race,F.all=F.all;const ae=Z[Lt]=Z.Promise;Z.Promise=F;const Et=at("thenPatched");function Xt(Ue){const He=Ue.prototype,ge=fe(He,"then");if(ge&&(!1===ge.writable||!ge.configurable))return;const We=He.then;He[ft]=We,Ue.prototype.then=function(wt,Xe){return new F((dt,qt)=>{We.call(this,dt,qt)}).then(wt,Xe)},Ue[Et]=!0}return ye.patchThen=Xt,ae&&(Xt(ae),Ka(Z,"fetch",Ue=>function Un(Ue){return function(He,ge){let We=Ue.apply(He,ge);if(We instanceof F)return We;let wt=We.constructor;return wt[Et]||Xt(wt),We}}(Ue))),Promise[se.__symbol__("uncaughtPromiseErrors")]=tt,F}),Zone.__load_patch("toString",Z=>{const se=Function.prototype.toString,ye=Ji("OriginalDelegate"),fe=Ji("Promise"),be=Ji("Error"),ke=function(){if("function"==typeof this){const Lt=this[ye];if(Lt)return"function"==typeof Lt?se.call(Lt):Object.prototype.toString.call(Lt);if(this===Promise){const ft=Z[fe];if(ft)return se.call(ft)}if(this===Error){const ft=Z[be];if(ft)return se.call(ft)}}return se.call(this)};ke[ye]=se,Function.prototype.toString=ke;const at=Object.prototype.toString;Object.prototype.toString=function(){return"function"==typeof Promise&&this instanceof Promise?"[object Promise]":at.call(this)}});let el=!1;if(typeof window<"u")try{const Z=Object.defineProperty({},"passive",{get:function(){el=!0}});window.addEventListener("test",Z,Z),window.removeEventListener("test",Z,Z)}catch{el=!1}const zT={useG:!0},Co={},wb={},Im=new RegExp("^"+Yd+"(\\w+)(true|false)$"),Cb=Ji("propagationStopped");function bm(Z,se){const ye=(se?se(Z):Z)+Wi,fe=(se?se(Z):Z)+Ts,be=Yd+ye,ke=Yd+fe;Co[Z]={},Co[Z][Wi]=be,Co[Z][Ts]=ke}function Eb(Z,se,ye,fe){const be=fe&&fe.add||gm,ke=fe&&fe.rm||$r,at=fe&&fe.listeners||"eventListeners",tt=fe&&fe.rmAll||"removeAllListeners",At=Ji(be),Lt="."+be+":",ft="prependListener",Ei="."+ft+":",ti=function(Wt,ct,_n){if(Wt.isRemoved)return;const sr=Wt.callback;let Zr;"object"==typeof sr&&sr.handleEvent&&(Wt.callback=lt=>sr.handleEvent(lt),Wt.originalDelegate=sr);try{Wt.invoke(Wt,ct,[_n])}catch(lt){Zr=lt}const ki=Wt.options;return ki&&"object"==typeof ki&&ki.once&&ct[ke].call(ct,_n.type,Wt.originalDelegate?Wt.originalDelegate:Wt.callback,ki),Zr};function gi(Wt,ct,_n){if(!(ct=ct||Z.event))return;const sr=Wt||ct.target||Z,Zr=sr[Co[ct.type][_n?Ts:Wi]];if(Zr){const ki=[];if(1===Zr.length){const lt=ti(Zr[0],sr,ct);lt&&ki.push(lt)}else{const lt=Zr.slice();for(let dr=0;dr{throw dr})}}}const cr=function(Wt){return gi(this,Wt,!1)},Oi=function(Wt){return gi(this,Wt,!0)};function es(Wt,ct){if(!Wt)return!1;let _n=!0;ct&&void 0!==ct.useG&&(_n=ct.useG);const sr=ct&&ct.vh;let Zr=!0;ct&&void 0!==ct.chkDup&&(Zr=ct.chkDup);let ki=!1;ct&&void 0!==ct.rt&&(ki=ct.rt);let lt=Wt;for(;lt&&!lt.hasOwnProperty(be);)lt=Vd(lt);if(!lt&&Wt[be]&&(lt=Wt),!lt||lt[At])return!1;const dr=ct&&ct.eventNameToString,et={},vi=lt[At]=lt[be],Pt=lt[Ji(ke)]=lt[ke],ts=lt[Ji(at)]=lt[at],_o=lt[Ji(tt)]=lt[tt];let cn;ct&&ct.prepend&&(cn=lt[Ji(ct.prepend)]=lt[ct.prepend]);const F=_n?function(ge){if(!et.isExisting)return vi.call(et.target,et.eventName,et.capture?Oi:cr,et.options)}:function(ge){return vi.call(et.target,et.eventName,ge.invoke,et.options)},ae=_n?function(ge){if(!ge.isRemoved){const We=Co[ge.eventName];let wt;We&&(wt=We[ge.capture?Ts:Wi]);const Xe=wt&&ge.target[wt];if(Xe)for(let mt=0;mt{Vo.zone.cancelTask(Vo)},{once:!0})),et.target=null,Uc&&(Uc.taskData=null),Zd&&(Dn.once=!0),!el&&"boolean"==typeof Vo.options||(Vo.options=Dn),Vo.target=qt,Vo.capture=Gl,Vo.eventName=ai,ir&&(Vo.originalDelegate=ur),dt?jo.unshift(Vo):jo.push(Vo),mt?qt:void 0}};return lt[be]=He(vi,Lt,F,ae,ki),cn&&(lt[ft]=He(cn,Ei,function(ge){return cn.call(et.target,et.eventName,ge.invoke,et.options)},ae,ki,!0)),lt[ke]=function(){const ge=this||Z;let We=arguments[0];ct&&ct.transferEventName&&(We=ct.transferEventName(We));const wt=arguments[2],Xe=!!wt&&("boolean"==typeof wt||wt.capture),mt=arguments[1];if(!mt)return Pt.apply(this,arguments);if(sr&&!sr(Pt,mt,ge,arguments))return;const dt=Co[We];let qt;dt&&(qt=dt[Xe?Ts:Wi]);const ai=qt&&ge[qt];if(ai)for(let ur=0;urfunction(be,ke){be[Cb]=!0,fe&&fe.apply(be,ke)})}function xb(Z,se,ye,fe,be){const ke=Zone.__symbol__(fe);if(se[ke])return;const at=se[ke]=se[fe];se[fe]=function(tt,At,Lt){return At&&At.prototype&&be.forEach(function(ft){const Ei=`${ye}.${fe}::`+ft,ti=At.prototype;try{if(ti.hasOwnProperty(ft)){const gi=Z.ObjectGetOwnPropertyDescriptor(ti,ft);gi&&gi.value?(gi.value=Z.wrapWithCurrentZone(gi.value,Ei),Z._redefineProperty(At.prototype,ft,gi)):ti[ft]&&(ti[ft]=Z.wrapWithCurrentZone(ti[ft],Ei))}else ti[ft]&&(ti[ft]=Z.wrapWithCurrentZone(ti[ft],Ei))}catch{}}),at.call(se,tt,At,Lt)},Z.attachOriginToPatched(se[fe],at)}function Tb(Z,se,ye){if(!ye||0===ye.length)return se;const fe=ye.filter(ke=>ke.target===Z);if(!fe||0===fe.length)return se;const be=fe[0].ignoreProperties;return se.filter(ke=>-1===be.indexOf(ke))}function Eo(Z,se,ye,fe){Z&&pf(Z,Tb(Z,se,ye),fe)}function $d(Z){return Object.getOwnPropertyNames(Z).filter(se=>se.startsWith("on")&&se.length>2).map(se=>se.substring(2))}Zone.__load_patch("util",(Z,se,ye)=>{const fe=$d(Z);ye.patchOnProperties=pf,ye.patchMethod=Ka,ye.bindArguments=Qd,ye.patchMacroTask=Ib;const be=se.__symbol__("BLACK_LISTED_EVENTS"),ke=se.__symbol__("UNPATCHED_EVENTS");Z[ke]&&(Z[be]=Z[ke]),Z[be]&&(se[be]=se[ke]=Z[be]),ye.patchEventPrototype=Mm,ye.patchEventTarget=Eb,ye.isIEOrEdge=Mb,ye.ObjectDefineProperty=jd,ye.ObjectGetOwnPropertyDescriptor=_l,ye.ObjectCreate=Wd,ye.ArraySlice=Sb,ye.patchClass=Xd,ye.wrapWithCurrentZone=hf,ye.filterProperties=Tb,ye.attachOriginToPatched=Sa,ye._redefineProperty=Object.defineProperty,ye.patchCallbacks=xb,ye.getGlobalObjects=()=>({globalSources:wb,zoneSymbolEventNames:Co,eventNames:fe,isBrowser:Gd,isMix:uf,isNode:jh,TRUE_STR:Ts,FALSE_STR:Wi,ZONE_SYMBOL_PREFIX:Yd,ADD_EVENT_LISTENER_STR:gm,REMOVE_EVENT_LISTENER_STR:$r})});const As=Ji("zoneTask");function Wl(Z,se,ye,fe){let be=null,ke=null;ye+=fe;const at={};function tt(Lt){const ft=Lt.data;return ft.args[0]=function(){return Lt.invoke.apply(this,arguments)},ft.handleId=be.apply(Z,ft.args),Lt}function At(Lt){return ke.call(Z,Lt.data.handleId)}be=Ka(Z,se+=fe,Lt=>function(ft,Ei){if("function"==typeof Ei[0]){const ti={isPeriodic:"Interval"===fe,delay:"Timeout"===fe||"Interval"===fe?Ei[1]||0:void 0,args:Ei},gi=Ei[0];Ei[0]=function(){try{return gi.apply(this,arguments)}finally{ti.isPeriodic||("number"==typeof ti.handleId?delete at[ti.handleId]:ti.handleId&&(ti.handleId[As]=null))}};const cr=vm(se,Ei[0],ti,tt,At);if(!cr)return cr;const Oi=cr.data.handleId;return"number"==typeof Oi?at[Oi]=cr:Oi&&(Oi[As]=cr),Oi&&Oi.ref&&Oi.unref&&"function"==typeof Oi.ref&&"function"==typeof Oi.unref&&(cr.ref=Oi.ref.bind(Oi),cr.unref=Oi.unref.bind(Oi)),"number"==typeof Oi||Oi?Oi:cr}return Lt.apply(Z,Ei)}),ke=Ka(Z,ye,Lt=>function(ft,Ei){const ti=Ei[0];let gi;"number"==typeof ti?gi=at[ti]:(gi=ti&&ti[As],gi||(gi=ti)),gi&&"string"==typeof gi.type?"notScheduled"!==gi.state&&(gi.cancelFn&&gi.data.isPeriodic||0===gi.runCount)&&("number"==typeof ti?delete at[ti]:ti&&(ti[As]=null),gi.zone.cancelTask(gi)):Lt.apply(Z,Ei)})}Zone.__load_patch("legacy",Z=>{const se=Z[Zone.__symbol__("legacyPatch")];se&&se()}),Zone.__load_patch("timers",Z=>{const ye="clear";Wl(Z,"set",ye,"Timeout"),Wl(Z,"set",ye,"Interval"),Wl(Z,"set",ye,"Immediate")}),Zone.__load_patch("requestAnimationFrame",Z=>{Wl(Z,"request","cancel","AnimationFrame"),Wl(Z,"mozRequest","mozCancel","AnimationFrame"),Wl(Z,"webkitRequest","webkitCancel","AnimationFrame")}),Zone.__load_patch("blocking",(Z,se)=>{const ye=["alert","prompt","confirm"];for(let fe=0;fefunction(At,Lt){return se.current.run(ke,Z,Lt,tt)})}),Zone.__load_patch("EventTarget",(Z,se,ye)=>{(function Yl(Z,se){se.patchEventPrototype(Z,se)})(Z,ye),function Cm(Z,se){if(Zone[se.symbol("patchEventTarget")])return;const{eventNames:ye,zoneSymbolEventNames:fe,TRUE_STR:be,FALSE_STR:ke,ZONE_SYMBOL_PREFIX:at}=se.getGlobalObjects();for(let At=0;At{Xd("MutationObserver"),Xd("WebKitMutationObserver")}),Zone.__load_patch("IntersectionObserver",(Z,se,ye)=>{Xd("IntersectionObserver")}),Zone.__load_patch("FileReader",(Z,se,ye)=>{Xd("FileReader")}),Zone.__load_patch("on_property",(Z,se,ye)=>{!function ff(Z,se){if(jh&&!uf||Zone[Z.symbol("patchEvents")])return;const ye=se.__Zone_ignore_on_properties;let fe=[];if(Gd){const be=window;fe=fe.concat(["Document","SVGElement","Element","HTMLElement","HTMLBodyElement","HTMLMediaElement","HTMLFrameSetElement","HTMLFrameElement","HTMLIFrameElement","HTMLMarqueeElement","Worker"]);const ke=function Sm(){try{const Z=Uh.navigator.userAgent;if(-1!==Z.indexOf("MSIE ")||-1!==Z.indexOf("Trident/"))return!0}catch{}return!1}()?[{target:be,ignoreProperties:["error"]}]:[];Eo(be,$d(be),ye&&ye.concat(ke),Vd(be))}fe=fe.concat(["XMLHttpRequest","XMLHttpRequestEventTarget","IDBIndex","IDBRequest","IDBOpenDBRequest","IDBDatabase","IDBTransaction","IDBCursor","WebSocket"]);for(let be=0;be{!function wm(Z,se){const{isBrowser:ye,isMix:fe}=se.getGlobalObjects();(ye||fe)&&Z.customElements&&"customElements"in Z&&se.patchCallbacks(se,Z.customElements,"customElements","define",["connectedCallback","disconnectedCallback","adoptedCallback","attributeChangedCallback"])}(Z,ye)}),Zone.__load_patch("XHR",(Z,se)=>{!function At(Lt){const ft=Lt.XMLHttpRequest;if(!ft)return;const Ei=ft.prototype;let gi=Ei[Ul],cr=Ei[Fh];if(!gi){const et=Lt.XMLHttpRequestEventTarget;if(et){const vi=et.prototype;gi=vi[Ul],cr=vi[Fh]}}const Oi="readystatechange",es="scheduled";function kr(et){const vi=et.data,Pt=vi.target;Pt[ke]=!1,Pt[tt]=!1;const ts=Pt[be];gi||(gi=Pt[Ul],cr=Pt[Fh]),ts&&cr.call(Pt,Oi,ts);const _o=Pt[be]=()=>{if(Pt.readyState===Pt.DONE)if(!vi.aborted&&Pt[ke]&&et.state===es){const Ur=Pt[se.__symbol__("loadfalse")];if(0!==Pt.status&&Ur&&Ur.length>0){const Do=et.invoke;et.invoke=function(){const Ls=Pt[se.__symbol__("loadfalse")];for(let jr=0;jrfunction(et,vi){return et[fe]=0==vi[2],et[at]=vi[1],_n.apply(et,vi)}),Zr=Ji("fetchTaskAborting"),ki=Ji("fetchTaskScheduling"),lt=Ka(Ei,"send",()=>function(et,vi){if(!0===se.current[ki]||et[fe])return lt.apply(et,vi);{const Pt={target:et,url:et[at],isPeriodic:!1,args:vi,aborted:!1},ts=vm("XMLHttpRequest.send",Wt,Pt,kr,ct);et&&!0===et[tt]&&!Pt.aborted&&ts.state===es&&ts.invoke()}}),dr=Ka(Ei,"abort",()=>function(et,vi){const Pt=function ti(et){return et[ye]}(et);if(Pt&&"string"==typeof Pt.type){if(null==Pt.cancelFn||Pt.data&&Pt.data.aborted)return;Pt.zone.cancelTask(Pt)}else if(!0===se.current[Zr])return dr.apply(et,vi)})}(Z);const ye=Ji("xhrTask"),fe=Ji("xhrSync"),be=Ji("xhrListener"),ke=Ji("xhrScheduled"),at=Ji("xhrURL"),tt=Ji("xhrErrorBeforeScheduled")}),Zone.__load_patch("geolocation",Z=>{Z.navigator&&Z.navigator.geolocation&&function ym(Z,se){const ye=Z.constructor.name;for(let fe=0;fe{const At=function(){return tt.apply(this,Qd(arguments,ye+"."+be))};return Sa(At,tt),At})(ke)}}}(Z.navigator.geolocation,["getCurrentPosition","watchPosition"])}),Zone.__load_patch("PromiseRejectionEvent",(Z,se)=>{function ye(fe){return function(be){Db(Z,fe).forEach(at=>{const tt=Z.PromiseRejectionEvent;if(tt){const At=new tt(fe,{promise:be.promise,reason:be.rejection});at.invoke(At)}})}}Z.PromiseRejectionEvent&&(se[Ji("unhandledPromiseRejectionHandler")]=ye("unhandledrejection"),se[Ji("rejectionHandledHandler")]=ye("rejectionhandled"))}),Zone.__load_patch("queueMicrotask",(Z,se,ye)=>{!function gf(Z,se){se.patchMethod(Z,"queueMicrotask",ye=>function(fe,be){Zone.current.scheduleMicroTask("queueMicrotask",be[0])})}(Z,ye)})}},_l=>{_l(_l.s=51)}]); \ No newline at end of file diff --git a/ej2-angular/samples/diagram/layers/layers-cs8/index.html b/ej2-angular/samples/diagram/layers/layers-cs8/index.html index be2d50fe03..98e0b69d9d 100644 --- a/ej2-angular/samples/diagram/layers/layers-cs8/index.html +++ b/ej2-angular/samples/diagram/layers/layers-cs8/index.html @@ -19,5 +19,5 @@
Loading....
- + \ No newline at end of file diff --git a/ej2-angular/samples/diagram/layers/layers-cs8/main.1c8c09371bc3e3ce.js b/ej2-angular/samples/diagram/layers/layers-cs8/main.1c8c09371bc3e3ce.js deleted file mode 100644 index d9e2f318d0..0000000000 --- a/ej2-angular/samples/diagram/layers/layers-cs8/main.1c8c09371bc3e3ce.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";(self.webpackChunksyncfusion_component=self.webpackChunksyncfusion_component||[]).push([[179],{51:(_l,jd,Vd)=>{let $r=null,Fh=1;const Ts=Symbol("SIGNAL");function Wi(n){const t=$r;return $r=n,t}function gn(n){if((!Vh(n)||n.dirty)&&(n.dirty||n.lastCleanEpoch!==Fh)){if(!n.producerMustRecompute(n)&&!jh(n))return n.dirty=!1,void(n.lastCleanEpoch=Fh);n.producerRecomputeValue(n),n.dirty=!1,n.lastCleanEpoch=Fh}}function jh(n){Vl(n);for(let t=0;t0}function Vl(n){n.producerNode??=[],n.producerIndexOfThis??=[],n.producerLastReadVersion??=[]}let qd=null;function Eo(n){return"function"==typeof n}function $d(n){const e=n(i=>{Error.call(i),i.stack=(new Error).stack});return e.prototype=Object.create(Error.prototype),e.prototype.constructor=e,e}const ff=$d(n=>function(e){n(this),this.message=e?`${e.length} errors occurred during unsubscription:\n${e.map((i,r)=>`${r+1}) ${i.toString()}`).join("\n ")}`:"",this.name="UnsubscriptionError",this.errors=e});function gf(n,t){if(n){const e=n.indexOf(t);0<=e&&n.splice(e,1)}}class As{constructor(t){this.initialTeardown=t,this.closed=!1,this._parentage=null,this._finalizers=null}unsubscribe(){let t;if(!this.closed){this.closed=!0;const{_parentage:e}=this;if(e)if(this._parentage=null,Array.isArray(e))for(const s of e)s.remove(this);else e.remove(this);const{initialTeardown:i}=this;if(Eo(i))try{i()}catch(s){t=s instanceof ff?s.errors:[s]}const{_finalizers:r}=this;if(r){this._finalizers=null;for(const s of r)try{Cm(s)}catch(o){t=t??[],o instanceof ff?t=[...t,...o.errors]:t.push(o)}}if(t)throw new ff(t)}}add(t){var e;if(t&&t!==this)if(this.closed)Cm(t);else{if(t instanceof As){if(t.closed||t._hasParent(this))return;t._addParent(this)}(this._finalizers=null!==(e=this._finalizers)&&void 0!==e?e:[]).push(t)}}_hasParent(t){const{_parentage:e}=this;return e===t||Array.isArray(e)&&e.includes(t)}_addParent(t){const{_parentage:e}=this;this._parentage=Array.isArray(e)?(e.push(t),e):e?[e,t]:t}_removeParent(t){const{_parentage:e}=this;e===t?this._parentage=null:Array.isArray(e)&&gf(e,t)}remove(t){const{_finalizers:e}=this;e&&gf(e,t),t instanceof As&&t._removeParent(this)}}As.EMPTY=(()=>{const n=new As;return n.closed=!0,n})();const Wl=As.EMPTY;function wm(n){return n instanceof As||n&&"closed"in n&&Eo(n.remove)&&Eo(n.add)&&Eo(n.unsubscribe)}function Cm(n){Eo(n)?n():n.unsubscribe()}const Yl={onUnhandledError:null,onStoppedNotification:null,Promise:void 0,useDeprecatedSynchronousErrorHandling:!1,useDeprecatedNextContext:!1},Z={setTimeout(n,t,...e){const{delegate:i}=Z;return i?.setTimeout?i.setTimeout(n,t,...e):setTimeout(n,t,...e)},clearTimeout(n){const{delegate:t}=Z;return(t?.clearTimeout||clearTimeout)(n)},delegate:void 0};function ye(){}const fe=at("C",void 0,void 0);function at(n,t,e){return{kind:n,value:t,error:e}}let tt=null;function At(n){if(Yl.useDeprecatedSynchronousErrorHandling){const t=!tt;if(t&&(tt={errorThrown:!1,error:null}),n(),t){const{errorThrown:e,error:i}=tt;if(tt=null,e)throw i}}else n()}class ft extends As{constructor(t){super(),this.isStopped=!1,t?(this.destination=t,wm(t)&&t.add(this)):this.destination=Wt}static create(t,e,i){return new cr(t,e,i)}next(t){this.isStopped?kr(function ke(n){return at("N",n,void 0)}(t),this):this._next(t)}error(t){this.isStopped?kr(function be(n){return at("E",void 0,n)}(t),this):(this.isStopped=!0,this._error(t))}complete(){this.isStopped?kr(fe,this):(this.isStopped=!0,this._complete())}unsubscribe(){this.closed||(this.isStopped=!0,super.unsubscribe(),this.destination=null)}_next(t){this.destination.next(t)}_error(t){try{this.destination.error(t)}finally{this.unsubscribe()}}_complete(){try{this.destination.complete()}finally{this.unsubscribe()}}}const Ei=Function.prototype.bind;function ti(n,t){return Ei.call(n,t)}class gi{constructor(t){this.partialObserver=t}next(t){const{partialObserver:e}=this;if(e.next)try{e.next(t)}catch(i){Oi(i)}}error(t){const{partialObserver:e}=this;if(e.error)try{e.error(t)}catch(i){Oi(i)}else Oi(t)}complete(){const{partialObserver:t}=this;if(t.complete)try{t.complete()}catch(e){Oi(e)}}}class cr extends ft{constructor(t,e,i){let r;if(super(),Eo(t)||!t)r={next:t??void 0,error:e??void 0,complete:i??void 0};else{let s;this&&Yl.useDeprecatedNextContext?(s=Object.create(t),s.unsubscribe=()=>this.unsubscribe(),r={next:t.next&&ti(t.next,s),error:t.error&&ti(t.error,s),complete:t.complete&&ti(t.complete,s)}):r=t}this.destination=new gi(r)}}function Oi(n){Yl.useDeprecatedSynchronousErrorHandling?function Lt(n){Yl.useDeprecatedSynchronousErrorHandling&&tt&&(tt.errorThrown=!0,tt.error=n)}(n):function se(n){Z.setTimeout(()=>{const{onUnhandledError:t}=Yl;if(!t)throw n;t(n)})}(n)}function kr(n,t){const{onStoppedNotification:e}=Yl;e&&Z.setTimeout(()=>e(n,t))}const Wt={closed:!0,next:ye,error:function es(n){throw n},complete:ye},ct="function"==typeof Symbol&&Symbol.observable||"@@observable";function _n(n){return n}let ki=(()=>{class n{constructor(e){e&&(this._subscribe=e)}lift(e){const i=new n;return i.source=this,i.operator=e,i}subscribe(e,i,r){const s=function et(n){return n&&n instanceof ft||function dr(n){return n&&Eo(n.next)&&Eo(n.error)&&Eo(n.complete)}(n)&&wm(n)}(e)?e:new cr(e,i,r);return At(()=>{const{operator:o,source:a}=this;s.add(o?o.call(s,a):a?this._subscribe(s):this._trySubscribe(s))}),s}_trySubscribe(e){try{return this._subscribe(e)}catch(i){e.error(i)}}forEach(e,i){return new(i=lt(i))((r,s)=>{const o=new cr({next:a=>{try{e(a)}catch(l){s(l),o.unsubscribe()}},error:s,complete:r});this.subscribe(o)})}_subscribe(e){var i;return null===(i=this.source)||void 0===i?void 0:i.subscribe(e)}[ct](){return this}pipe(...e){return function Zr(n){return 0===n.length?_n:1===n.length?n[0]:function(e){return n.reduce((i,r)=>r(i),e)}}(e)(this)}toPromise(e){return new(e=lt(e))((i,r)=>{let s;this.subscribe(o=>s=o,o=>r(o),()=>i(s))})}}return n.create=t=>new n(t),n})();function lt(n){var t;return null!==(t=n??Yl.Promise)&&void 0!==t?t:Promise}const vi=$d(n=>function(){n(this),this.name="ObjectUnsubscribedError",this.message="object unsubscribed"});let Pt=(()=>{class n extends ki{constructor(){super(),this.closed=!1,this.currentObservers=null,this.observers=[],this.isStopped=!1,this.hasError=!1,this.thrownError=null}lift(e){const i=new ts(this,this);return i.operator=e,i}_throwIfClosed(){if(this.closed)throw new vi}next(e){At(()=>{if(this._throwIfClosed(),!this.isStopped){this.currentObservers||(this.currentObservers=Array.from(this.observers));for(const i of this.currentObservers)i.next(e)}})}error(e){At(()=>{if(this._throwIfClosed(),!this.isStopped){this.hasError=this.isStopped=!0,this.thrownError=e;const{observers:i}=this;for(;i.length;)i.shift().error(e)}})}complete(){At(()=>{if(this._throwIfClosed(),!this.isStopped){this.isStopped=!0;const{observers:e}=this;for(;e.length;)e.shift().complete()}})}unsubscribe(){this.isStopped=this.closed=!0,this.observers=this.currentObservers=null}get observed(){var e;return(null===(e=this.observers)||void 0===e?void 0:e.length)>0}_trySubscribe(e){return this._throwIfClosed(),super._trySubscribe(e)}_subscribe(e){return this._throwIfClosed(),this._checkFinalizedStatuses(e),this._innerSubscribe(e)}_innerSubscribe(e){const{hasError:i,isStopped:r,observers:s}=this;return i||r?Wl:(this.currentObservers=null,s.push(e),new As(()=>{this.currentObservers=null,gf(s,e)}))}_checkFinalizedStatuses(e){const{hasError:i,thrownError:r,isStopped:s}=this;i?e.error(r):s&&e.complete()}asObservable(){const e=new ki;return e.source=this,e}}return n.create=(t,e)=>new ts(t,e),n})();class ts extends Pt{constructor(t,e){super(),this.destination=t,this.source=e}next(t){var e,i;null===(i=null===(e=this.destination)||void 0===e?void 0:e.next)||void 0===i||i.call(e,t)}error(t){var e,i;null===(i=null===(e=this.destination)||void 0===e?void 0:e.error)||void 0===i||i.call(e,t)}complete(){var t,e;null===(e=null===(t=this.destination)||void 0===t?void 0:t.complete)||void 0===e||e.call(t)}_subscribe(t){var e,i;return null!==(i=null===(e=this.source)||void 0===e?void 0:e.subscribe(t))&&void 0!==i?i:Wl}}class _o extends Pt{constructor(t){super(),this._value=t}get value(){return this.getValue()}_subscribe(t){const e=super._subscribe(t);return!e.closed&&t.next(this._value),e}getValue(){const{hasError:t,thrownError:e,_value:i}=this;if(t)throw e;return this._throwIfClosed(),i}next(t){super.next(this._value=t)}}class Ls extends ft{constructor(t,e,i,r,s,o){super(t),this.onFinalize=s,this.shouldUnsubscribe=o,this._next=e?function(a){try{e(a)}catch(l){t.error(l)}}:super._next,this._error=r?function(a){try{r(a)}catch(l){t.error(l)}finally{this.unsubscribe()}}:super._error,this._complete=i?function(){try{i()}catch(a){t.error(a)}finally{this.unsubscribe()}}:super._complete}unsubscribe(){var t;if(!this.shouldUnsubscribe||this.shouldUnsubscribe()){const{closed:e}=this;super.unsubscribe(),!e&&(null===(t=this.onFinalize)||void 0===t||t.call(this))}}}function jr(n,t){return function Ur(n){return t=>{if(function cn(n){return Eo(n?.lift)}(t))return t.lift(function(e){try{return n(e,this)}catch(i){this.error(i)}});throw new TypeError("Unable to lift unknown Observable type")}}((e,i)=>{let r=0;e.subscribe(function Do(n,t,e,i,r){return new Ls(n,t,e,i,r)}(i,s=>{i.next(n.call(t,s,r++))}))})}class F extends Error{constructor(t,e){super(function ae(n,t){return`NG0${Math.abs(n)}${t?": "+t:""}`}(t,e)),this.code=t}}function Xe(n){for(let t in n)if(n[t]===Xe)return t;throw Error("Could not find renamed property on target object.")}function mt(n,t){for(const e in t)t.hasOwnProperty(e)&&!n.hasOwnProperty(e)&&(n[e]=t[e])}function dt(n){if("string"==typeof n)return n;if(Array.isArray(n))return"["+n.map(dt).join(", ")+"]";if(null==n)return""+n;if(n.overriddenName)return`${n.overriddenName}`;if(n.name)return`${n.name}`;const t=n.toString();if(null==t)return""+t;const e=t.indexOf("\n");return-1===e?t:t.substring(0,e)}function qt(n,t){return null==n||""===n?null===t?"":t:null==t||""===t?n:n+" "+t}const ur=Xe({__forward_ref__:Xe});function ir(n){return n.__forward_ref__=ir,n.toString=function(){return dt(this())},n}function vt(n){return function Dn(n){return"function"==typeof n&&n.hasOwnProperty(ur)&&n.__forward_ref__===ir}(n)?n():n}function Ql(n){return n&&!!n.\u0275providers}const Gl=Xe({\u0275cmp:Xe}),Zd=Xe({\u0275dir:Xe}),vf=Xe({\u0275pipe:Xe}),Uo=Xe({\u0275fac:Xe}),jo=Xe({__NG_ELEMENT_ID__:Xe}),mf=Xe({__NG_ENV_ID__:Xe});function zi(n){return"function"==typeof n?n.name||n.toString():"object"==typeof n&&null!=n&&"function"==typeof n.type?n.type.name||n.type.toString():function Nt(n){return"string"==typeof n?n:null==n?"":String(n)}(n)}function Ab(n,t){throw new F(-201,!1)}function ro(n,t){null==n&&function zt(n,t,e,i){throw new Error(`ASSERTION ERROR: ${n}`+(null==i?"":` [Expected=> ${e} ${i} ${t} <=Actual]`))}(t,n,null,"!=")}function Yi(n){return{token:n.token,providedIn:n.providedIn||null,factory:n.factory,value:void 0}}function yf(n){return{providers:n.providers||[],imports:n.imports||[]}}function Em(n){return zT(n,xm)||zT(n,RT)}function zT(n,t){return n.hasOwnProperty(t)?n[t]:null}function Dm(n){return n&&(n.hasOwnProperty(Lb)||n.hasOwnProperty(x_))?n[Lb]:null}const xm=Xe({\u0275prov:Xe}),Lb=Xe({\u0275inj:Xe}),RT=Xe({ngInjectableDef:Xe}),x_=Xe({ngInjectorDef:Xe});var Di=function(n){return n[n.Default=0]="Default",n[n.Host=1]="Host",n[n.Self=2]="Self",n[n.SkipSelf=4]="SkipSelf",n[n.Optional=8]="Optional",n}(Di||{});let Nb;function no(n){const t=Nb;return Nb=n,t}function BT(n,t,e){const i=Em(n);return i&&"root"==i.providedIn?void 0===i.value?i.value=i.factory():i.value:e&Di.Optional?null:void 0!==t?t:void Ab()}const rr=globalThis;class Ht{constructor(t,e){this._desc=t,this.ngMetadataName="InjectionToken",this.\u0275prov=void 0,"number"==typeof e?this.__NG_ELEMENT_ID__=e:void 0!==e&&(this.\u0275prov=Yi({token:this,providedIn:e.providedIn||"root",factory:e.factory}))}get multi(){return this}toString(){return`InjectionToken ${this._desc}`}}const Sf={},Rb="__NG_DI_FLAG__",Tm="ngTempTokenPath",L_=/\n/gm,_T="__source";let Kd;function Qh(n){const t=Kd;return Kd=n,t}function k_(n,t=Di.Default){if(void 0===Kd)throw new F(-203,!1);return null===Kd?BT(n,void 0,t):Kd.get(n,t&Di.Optional?null:void 0,t)}function Fi(n,t=Di.Default){return(function HT(){return Nb}()||k_)(vt(n),t)}function Ri(n,t=Di.Default){return Fi(n,Am(t))}function Am(n){return typeof n>"u"||"number"==typeof n?n:0|(n.optional&&8)|(n.host&&1)|(n.self&&2)|(n.skipSelf&&4)}function Hb(n){const t=[];for(let e=0;et){o=s-1;break}}}for(;ss?"":r[d+1].toLowerCase();const p=8&i?u:null;if(p&&-1!==jT(p,h,0)||2&i&&h!==u){if(ba(i))return!1;o=!0}}}}else{if(!o&&!ba(i)&&!ba(l))return!1;if(o&&ba(l))continue;o=!1,i=l|1&i}}return ba(i)||o}function ba(n){return 0==(1&n)}function __(n,t,e,i){if(null===t)return-1;let r=0;if(i||!e){let s=!1;for(;r-1)for(e++;e0?'="'+a+'"':"")+"]"}else 8&i?r+="."+o:4&i&&(r+=" "+o);else""!==r&&!ba(o)&&(t+=qT(s,r),r=""),i=o,s=s||!ba(i);e++}return""!==r&&(t+=qT(s,r)),t}function Fb(n){return Xl(()=>{const t=ZT(n),e={...t,decls:n.decls,vars:n.vars,template:n.template,consts:n.consts||null,ngContentSelectors:n.ngContentSelectors,onPush:n.changeDetection===Lm.OnPush,directiveDefs:null,pipeDefs:null,dependencies:t.standalone&&n.dependencies||null,getStandaloneInjector:null,signals:n.signals??!1,data:n.data||{},encapsulation:n.encapsulation||Ia.Emulated,styles:n.styles||Qi,_:null,schemas:n.schemas||null,tView:null,id:""};JT(e);const i=n.dependencies;return e.directiveDefs=Om(i,!1),e.pipeDefs=Om(i,!0),e.id=function Z_(n){let t=0;const e=[n.selectors,n.ngContentSelectors,n.hostVars,n.hostAttrs,n.consts,n.vars,n.decls,n.encapsulation,n.standalone,n.signals,n.exportAs,JSON.stringify(n.inputs),JSON.stringify(n.outputs),Object.getOwnPropertyNames(n.type.prototype),!!n.contentQueries,!!n.viewQuery].join("|");for(const r of e)t=Math.imul(31,t)+r.charCodeAt(0)<<0;return t+=2147483648,"c"+t}(e),e})}function X_(n){return ci(n)||jn(n)}function q_(n){return null!==n}function Nm(n){return Xl(()=>({type:n.type,bootstrap:n.bootstrap||Qi,declarations:n.declarations||Qi,imports:n.imports||Qi,exports:n.exports||Qi,transitiveCompileScopes:null,schemas:n.schemas||null,id:n.id||null}))}function $T(n,t){if(null==n)return tl;const e={};for(const i in n)if(n.hasOwnProperty(i)){const r=n[i];let s,o,a=Gh.None;Array.isArray(r)?(a=r[0],s=r[1],o=r[2]??s):(s=r,o=r),t?(e[s]=a!==Gh.None?[i,a]:i,t[s]=o):e[s]=i}return e}function nr(n){return Xl(()=>{const t=ZT(n);return JT(t),t})}function ci(n){return n[Gl]||null}function jn(n){return n[Zd]||null}function gs(n){return n[vf]||null}function ZT(n){const t={};return{type:n.type,providersResolver:null,factory:null,hostBindings:n.hostBindings||null,hostVars:n.hostVars||0,hostAttrs:n.hostAttrs||null,contentQueries:n.contentQueries||null,declaredInputs:t,inputTransforms:null,inputConfig:n.inputs||tl,exportAs:n.exportAs||null,standalone:!0===n.standalone,signals:!0===n.signals,selectors:n.selectors||Qi,viewQuery:n.viewQuery||null,features:n.features||null,setInput:null,findHostDirectiveDefs:null,hostDirectives:null,inputs:$T(n.inputs,t),outputs:$T(n.outputs),debugInfo:null}}function JT(n){n.features?.forEach(t=>t(n))}function Om(n,t){if(!n)return null;const e=t?gs:X_;return()=>("function"==typeof n?n():n).map(i=>e(i)).filter(q_)}const Vr=0,Be=1,Ct=2,vn=3,Ma=4,Os=5,wa=6,eu=7,Er=8,Xs=9,ql=10,Yt=11,Mf=12,KT=13,tu=14,Jr=15,wf=16,iu=17,il=18,Cf=19,eA=20,Xh=21,km=22,Uc=23,Ut=25,_b=1,rl=7,ru=9,mn=10;var Ub=function(n){return n[n.None=0]="None",n[n.HasTransplantedViews=2]="HasTransplantedViews",n}(Ub||{});function ks(n){return Array.isArray(n)&&"object"==typeof n[_b]}function Ps(n){return Array.isArray(n)&&!0===n[_b]}function jb(n){return 0!=(4&n.flags)}function jc(n){return n.componentOffset>-1}function zm(n){return 1==(1&n.flags)}function Ca(n){return!!n.template}function Vb(n){return 0!=(512&n[Ct])}function Vc(n,t){return n.hasOwnProperty(Uo)?n[Uo]:null}class tU{constructor(t,e,i){this.previousValue=t,this.currentValue=e,this.firstChange=i}isFirstChange(){return this.firstChange}}function nA(n,t,e,i){null!==t?t.applyValueToInputSignal(t,i):n[e]=i}function sA(n){return n.type.prototype.ngOnChanges&&(n.setInput=rU),iU}function iU(){const n=aA(this),t=n?.current;if(t){const e=n.previous;if(e===tl)n.previous=t;else for(let i in t)e[i]=t[i];n.current=null,this.ngOnChanges(t)}}function rU(n,t,e,i,r){const s=this.declaredInputs[i],o=aA(n)||function nU(n,t){return n[oA]=t}(n,{previous:tl,current:null}),a=o.current||(o.current={}),l=o.previous,h=l[s];a[s]=new tU(h&&h.currentValue,e,l===tl),nA(n,t,r,e)}const oA="__ngSimpleChanges__";function aA(n){return n[oA]||null}const nl=function(n,t,e){};let cA=!1;function pr(n){for(;Array.isArray(n);)n=n[Vr];return n}function qs(n,t){return pr(t[n.index])}function xf(n,t){return n.data[t]}function To(n,t){const e=t[n];return ks(e)?e:e[Vr]}function Xb(n){return 128==(128&n[Ct])}function sl(n,t){return null==t?null:n[t]}function dA(n){n[iu]=0}function cU(n){1024&n[Ct]||(n[Ct]|=1024,Xb(n)&&Tf(n))}function pA(n){return 9216&n[Ct]||n[Uc]?.dirty}function qb(n){pA(n)?Tf(n):64&n[Ct]&&(function oU(){return cA}()?(n[Ct]|=1024,Tf(n)):n[ql].changeDetectionScheduler?.notify())}function Tf(n){n[ql].changeDetectionScheduler?.notify();let t=Wc(n);for(;null!==t&&!(8192&t[Ct])&&(t[Ct]|=8192,Xb(t));)t=Wc(t)}function Wc(n){const t=n[vn];return Ps(t)?t[vn]:t}const Rt={lFrame:wA(null),bindingsEnabled:!0,skipHydrationRootTNode:null};function gA(){return Rt.bindingsEnabled}function Se(){return Rt.lFrame.lView}function xi(){return Rt.lFrame.tView}function fr(){let n=vA();for(;null!==n&&64===n.type;)n=n.parent;return n}function vA(){return Rt.lFrame.currentTNode}function ol(n,t){const e=Rt.lFrame;e.currentTNode=n,e.isParent=t}function Zb(){return Rt.lFrame.isParent}function wU(n,t){const e=Rt.lFrame;e.bindingIndex=e.bindingRootIndex=n,Kb(t)}function Kb(n){Rt.lFrame.currentDirectiveIndex=n}function IA(){return Rt.lFrame.currentQueryIndex}function t1(n){Rt.lFrame.currentQueryIndex=n}function EU(n){const t=n[Be];return 2===t.type?t.declTNode:1===t.type?n[Os]:null}function bA(n,t,e){if(e&Di.SkipSelf){let r=t,s=n;for(;!(r=r.parent,null!==r||e&Di.Host||(r=EU(s),null===r||(s=s[tu],10&r.type))););if(null===r)return!1;t=r,n=s}const i=Rt.lFrame=MA();return i.currentTNode=t,i.lView=n,!0}function i1(n){const t=MA(),e=n[Be];Rt.lFrame=t,t.currentTNode=e.firstChild,t.lView=n,t.tView=e,t.contextLView=n,t.bindingIndex=e.bindingStartIndex,t.inI18n=!1}function MA(){const n=Rt.lFrame,t=null===n?null:n.child;return null===t?wA(n):t}function wA(n){const t={currentTNode:null,isParent:!0,lView:null,tView:null,selectedIndex:-1,contextLView:null,elementDepthCount:0,currentNamespace:null,currentDirectiveIndex:-1,bindingRootIndex:-1,bindingIndex:-1,currentQueryIndex:0,parent:n,child:null,inI18n:!1};return null!==n&&(n.child=t),t}function CA(){const n=Rt.lFrame;return Rt.lFrame=n.parent,n.currentTNode=null,n.lView=null,n}const EA=CA;function r1(){const n=CA();n.isParent=!0,n.tView=null,n.selectedIndex=-1,n.contextLView=null,n.elementDepthCount=0,n.currentDirectiveIndex=-1,n.currentNamespace=null,n.bindingRootIndex=-1,n.bindingIndex=-1,n.currentQueryIndex=0}function zs(){return Rt.lFrame.selectedIndex}function Yc(n){Rt.lFrame.selectedIndex=n}let xA=!0;function Bm(){return xA}function qh(n){xA=n}function Fm(n,t){for(let e=t.directiveStart,i=t.directiveEnd;e=i)break}else t[l]<0&&(n[iu]+=65536),(a>14>16&&(3&n[Ct])===t&&(n[Ct]+=16384,AA(a,s)):AA(a,s)}const ou=-1;class Lf{constructor(t,e,i){this.factory=t,this.resolving=!1,this.canSeeViewProviders=e,this.injectImpl=i}}function o1(n){return n!==ou}function Nf(n){return 32767&n}function Of(n,t){let e=function HU(n){return n>>16}(n),i=t;for(;e>0;)i=i[tu],e--;return i}let a1=!0;function jm(n){const t=a1;return a1=n,t}const LA=255,NA=5;let BU=0;const ll={};function Vm(n,t){const e=OA(n,t);if(-1!==e)return e;const i=t[Be];i.firstCreatePass&&(n.injectorIndex=t.length,l1(i.data,n),l1(t,null),l1(i.blueprint,null));const r=Wm(n,t),s=n.injectorIndex;if(o1(r)){const o=Nf(r),a=Of(r,t),l=a[Be].data;for(let h=0;h<8;h++)t[s+h]=a[o+h]|l[o+h]}return t[s+8]=r,s}function l1(n,t){n.push(0,0,0,0,0,0,0,0,t)}function OA(n,t){return-1===n.injectorIndex||n.parent&&n.parent.injectorIndex===n.injectorIndex||null===t[n.injectorIndex+8]?-1:n.injectorIndex}function Wm(n,t){if(n.parent&&-1!==n.parent.injectorIndex)return n.parent.injectorIndex;let e=0,i=null,r=t;for(;null!==r;){if(i=FA(r),null===i)return ou;if(e++,r=r[tu],-1!==i.injectorIndex)return i.injectorIndex|e<<16}return ou}function h1(n,t,e){!function FU(n,t,e){let i;"string"==typeof e?i=e.charCodeAt(0)||0:e.hasOwnProperty(jo)&&(i=e[jo]),null==i&&(i=e[jo]=BU++);const r=i&LA;t.data[n+(r>>NA)]|=1<=0?t&LA:VU:t}(e);if("function"==typeof s){if(!bA(t,n,i))return i&Di.Host?kA(r,0,i):PA(t,e,i,r);try{let o;if(o=s(i),null!=o||i&Di.Optional)return o;Ab()}finally{EA()}}else if("number"==typeof s){let o=null,a=OA(n,t),l=ou,h=i&Di.Host?t[Jr][Os]:null;for((-1===a||i&Di.SkipSelf)&&(l=-1===a?Wm(n,t):t[a+8],l!==ou&&BA(i,!1)?(o=t[Be],a=Nf(l),t=Of(l,t)):a=-1);-1!==a;){const c=t[Be];if(HA(s,a,c.data)){const d=UU(a,t,e,o,i,h);if(d!==ll)return d}l=t[a+8],l!==ou&&BA(i,t[Be].data[a+8]===h)&&HA(s,a,t)?(o=c,a=Nf(l),t=Of(l,t)):a=-1}}return r}function UU(n,t,e,i,r,s){const o=t[Be],a=o.data[n+8],c=Ym(a,o,e,null==i?jc(a)&&a1:i!=o&&0!=(3&a.type),r&Di.Host&&s===a);return null!==c?Qc(t,o,c,a):ll}function Ym(n,t,e,i,r){const s=n.providerIndexes,o=t.data,a=1048575&s,l=n.directiveStart,c=s>>20,u=r?a+c:n.directiveEnd;for(let p=i?a:a+c;p=l&&f.type===e)return p}if(r){const p=o[l];if(p&&Ca(p)&&p.type===e)return l}return null}function Qc(n,t,e,i){let r=n[e];const s=t.data;if(function kU(n){return n instanceof Lf}(r)){const o=r;o.resolving&&function Vo(n,t){const e=t?`. Dependency path: ${t.join(" > ")} > ${n}`:"";throw new F(-200,`Circular dependency in DI detected for ${n}${e}`)}(zi(s[e]));const a=jm(o.canSeeViewProviders);o.resolving=!0;const h=o.injectImpl?no(o.injectImpl):null;bA(n,i,Di.Default);try{r=n[e]=o.factory(void 0,s,n,i),t.firstCreatePass&&e>=i.directiveStart&&function NU(n,t,e){const{ngOnChanges:i,ngOnInit:r,ngDoCheck:s}=t.type.prototype;if(i){const o=sA(t);(e.preOrderHooks??=[]).push(n,o),(e.preOrderCheckHooks??=[]).push(n,o)}r&&(e.preOrderHooks??=[]).push(0-n,r),s&&((e.preOrderHooks??=[]).push(n,s),(e.preOrderCheckHooks??=[]).push(n,s))}(e,s[e],t)}finally{null!==h&&no(h),jm(a),o.resolving=!1,EA()}}return r}function HA(n,t,e){return!!(e[t+(n>>NA)]&1<Array.isArray(e)?fu(e,t):t(e))}function UA(n,t,e){t>=n.length?n.push(e):n.splice(t,0,e)}function Qm(n,t){return t>=n.length-1?n.pop():n.splice(t,1)[0]}const mu=new Ht(""),GA=new Ht("",-1),S1=new Ht("");class $m{get(t,e=Sf){if(e===Sf){const i=new Error(`NullInjectorError: No provider for ${dt(t)}!`);throw i.name="NullInjectorError",i}return e}}function pj(...n){return{\u0275providers:XA(0,n),\u0275fromNgModule:!0}}function XA(n,...t){const e=[],i=new Set;let r;const s=o=>{e.push(o)};return fu(t,o=>{const a=o;Zm(a,s,[],i)&&(r||=[],r.push(a))}),void 0!==r&&qA(r,s),e}function qA(n,t){for(let e=0;e{t(s,i)})}}function Zm(n,t,e,i){if(!(n=vt(n)))return!1;let r=null,s=Dm(n);const o=!s&&ci(n);if(s||o){if(o&&!o.standalone)return!1;r=n}else{const l=n.ngModule;if(s=Dm(l),!s)return!1;r=l}const a=i.has(r);if(o){if(a)return!1;if(i.add(r),o.dependencies){const l="function"==typeof o.dependencies?o.dependencies():o.dependencies;for(const h of l)Zm(h,t,e,i)}}else{if(!s)return!1;{if(null!=s.imports&&!a){let h;i.add(r);try{fu(s.imports,c=>{Zm(c,t,e,i)&&(h||=[],h.push(c))})}finally{}void 0!==h&&qA(h,t)}if(!a){const h=Vc(r)||(()=>new r);t({provide:r,useFactory:h,deps:Qi},r),t({provide:S1,useValue:r,multi:!0},r),t({provide:mu,useValue:()=>Fi(r),multi:!0},r)}const l=s.providers;if(null!=l&&!a){const h=n;b1(l,c=>{t(c,h)})}}}return r!==n&&void 0!==n.providers}function b1(n,t){for(let e of n)Ql(e)&&(e=e.\u0275providers),Array.isArray(e)?b1(e,t):t(e)}const fj=Xe({provide:String,useValue:Xe});function M1(n){return null!==n&&"object"==typeof n&&fj in n}function Gc(n){return"function"==typeof n}const w1=new Ht(""),Jm={},vj={};let C1;function Km(){return void 0===C1&&(C1=new $m),C1}class Jl{}class yu extends Jl{get destroyed(){return this._destroyed}constructor(t,e,i,r){super(),this.parent=e,this.source=i,this.scopes=r,this.records=new Map,this._ngOnDestroyHooks=new Set,this._onDestroyHooks=[],this._destroyed=!1,D1(t,o=>this.processProvider(o)),this.records.set(GA,Su(void 0,this)),r.has("environment")&&this.records.set(Jl,Su(void 0,this));const s=this.records.get(w1);null!=s&&"string"==typeof s.value&&this.scopes.add(s.value),this.injectorDefTypes=new Set(this.get(S1,Qi,Di.Self))}destroy(){this.assertNotDestroyed(),this._destroyed=!0;try{for(const e of this._ngOnDestroyHooks)e.ngOnDestroy();const t=this._onDestroyHooks;this._onDestroyHooks=[];for(const e of t)e()}finally{this.records.clear(),this._ngOnDestroyHooks.clear(),this.injectorDefTypes.clear()}}onDestroy(t){return this.assertNotDestroyed(),this._onDestroyHooks.push(t),()=>this.removeOnDestroy(t)}runInContext(t){this.assertNotDestroyed();const e=Qh(this),i=no(void 0);try{return t()}finally{Qh(e),no(i)}}get(t,e=Sf,i=Di.Default){if(this.assertNotDestroyed(),t.hasOwnProperty(mf))return t[mf](this);i=Am(i);const s=Qh(this),o=no(void 0);try{if(!(i&Di.SkipSelf)){let l=this.records.get(t);if(void 0===l){const h=function bj(n){return"function"==typeof n||"object"==typeof n&&n instanceof Ht}(t)&&Em(t);l=h&&this.injectableDefInScope(h)?Su(E1(t),Jm):null,this.records.set(t,l)}if(null!=l)return this.hydrate(t,l)}return(i&Di.Self?Km():this.parent).get(t,e=i&Di.Optional&&e===Sf?null:e)}catch(a){if("NullInjectorError"===a.name){if((a[Tm]=a[Tm]||[]).unshift(dt(t)),s)throw a;return function z_(n,t,e,i){const r=n[Tm];throw t[_T]&&r.unshift(t[_T]),n.message=function R_(n,t,e,i=null){n=n&&"\n"===n.charAt(0)&&"\u0275"==n.charAt(1)?n.slice(2):n;let r=dt(t);if(Array.isArray(t))r=t.map(dt).join(" -> ");else if("object"==typeof t){let s=[];for(let o in t)if(t.hasOwnProperty(o)){let a=t[o];s.push(o+":"+("string"==typeof a?JSON.stringify(a):dt(a)))}r=`{${s.join(", ")}}`}return`${e}${i?"("+i+")":""}[${r}]: ${n.replace(L_,"\n ")}`}("\n"+n.message,r,e,i),n.ngTokenPath=r,n[Tm]=null,n}(a,t,"R3InjectorError",this.source)}throw a}finally{no(o),Qh(s)}}resolveInjectorInitializers(){const t=Qh(this),e=no(void 0);try{const r=this.get(mu,Qi,Di.Self);for(const s of r)s()}finally{Qh(t),no(e)}}toString(){const t=[],e=this.records;for(const i of e.keys())t.push(dt(i));return`R3Injector[${t.join(", ")}]`}assertNotDestroyed(){if(this._destroyed)throw new F(205,!1)}processProvider(t){let e=Gc(t=vt(t))?t:vt(t&&t.provide);const i=function yj(n){return M1(n)?Su(void 0,n.useValue):Su(JA(n),Jm)}(t);if(!Gc(t)&&!0===t.multi){let r=this.records.get(e);r||(r=Su(void 0,Jm,!0),r.factory=()=>Hb(r.multi),this.records.set(e,r)),e=t,r.multi.push(t)}this.records.set(e,i)}hydrate(t,e){return e.value===Jm&&(e.value=vj,e.value=e.factory()),"object"==typeof e.value&&e.value&&function Ij(n){return null!==n&&"object"==typeof n&&"function"==typeof n.ngOnDestroy}(e.value)&&this._ngOnDestroyHooks.add(e.value),e.value}injectableDefInScope(t){if(!t.providedIn)return!1;const e=vt(t.providedIn);return"string"==typeof e?"any"===e||this.scopes.has(e):this.injectorDefTypes.has(e)}removeOnDestroy(t){const e=this._onDestroyHooks.indexOf(t);-1!==e&&this._onDestroyHooks.splice(e,1)}}function E1(n){const t=Em(n),e=null!==t?t.factory:Vc(n);if(null!==e)return e;if(n instanceof Ht)throw new F(204,!1);if(n instanceof Function)return function mj(n){if(n.length>0)throw new F(204,!1);const e=function D_(n){return n&&(n[xm]||n[RT])||null}(n);return null!==e?()=>e.factory(n):()=>new n}(n);throw new F(204,!1)}function JA(n,t,e){let i;if(Gc(n)){const r=vt(n);return Vc(r)||E1(r)}if(M1(n))i=()=>vt(n.useValue);else if(function ZA(n){return!(!n||!n.useFactory)}(n))i=()=>n.useFactory(...Hb(n.deps||[]));else if(function $A(n){return!(!n||!n.useExisting)}(n))i=()=>Fi(vt(n.useExisting));else{const r=vt(n&&(n.useClass||n.provide));if(!function Sj(n){return!!n.deps}(n))return Vc(r)||E1(r);i=()=>new r(...Hb(n.deps))}return i}function Su(n,t,e=!1){return{factory:n,value:t,multi:e?[]:void 0}}function D1(n,t){for(const e of n)Array.isArray(e)?D1(e,t):e&&Ql(e)?D1(e.\u0275providers,t):t(e)}function iL(n,t=null,e=null,i){const r=function rL(n,t=null,e=null,i,r=new Set){const s=[e||Qi,pj(n)];return i=i||("object"==typeof n?void 0:dt(n)),new yu(s,t||Km(),i||null,r)}(n,t,e,i);return r.resolveInjectorInitializers(),r}let A1,Wo=(()=>{class n{static{this.THROW_IF_NOT_FOUND=Sf}static{this.NULL=new $m}static create(e,i){if(Array.isArray(e))return iL({name:""},i,e,"");{const r=e.name??"";return iL({name:r},e.parent,e.providers,r)}}static{this.\u0275prov=Yi({token:n,providedIn:"any",factory:()=>Fi(GA)})}static{this.__NG_ELEMENT_ID__=-1}}return n})();const L1=new Ht("",{providedIn:"root",factory:()=>Lj}),Lj="ng",sL=new Ht(""),Iu=new Ht("",{providedIn:"platform",factory:()=>"unknown"}),oL=new Ht("",{providedIn:"root",factory:()=>function $h(){if(void 0!==A1)return A1;if(typeof document<"u")return document;throw new F(210,!1)}().body?.querySelector("[ngCspNonce]")?.getAttribute("ngCspNonce")||null});function ny(n){return 128==(128&n.flags)}var Kh=function(n){return n[n.Important=1]="Important",n[n.DashCase=2]="DashCase",n}(Kh||{});const z1=new Map;let Vj=0;const H1="__ngContext__";function Rs(n,t){ks(t)?(n[H1]=t[Cf],function Yj(n){z1.set(n[Cf],n)}(t)):n[H1]=t}let B1;function F1(n,t){return B1(n,t)}function Mu(n,t,e,i,r){if(null!=i){let s,o=!1;Ps(i)?s=i:ks(i)&&(o=!0,i=i[Vr]);const a=pr(i);0===n&&null!==e?null==r?TL(t,e,a):qc(t,e,a,r||null,!0):1===n&&null!==e?qc(t,e,a,r||null,!0):2===n?function dy(n,t,e){const i=hy(n,t);i&&function a6(n,t,e,i){n.removeChild(t,e,i)}(n,i,t,e)}(t,a,o):3===n&&t.destroyNode(a),null!=s&&function c6(n,t,e,i,r){const s=e[rl];s!==pr(e)&&Mu(t,n,i,s,r);for(let a=mn;a0&&(n[e-1][Ma]=i[Ma]);const s=Qm(n,mn+t);!function e6(n,t){EL(n,t),t[Vr]=null,t[Os]=null}(i[Be],i);const o=s[il];null!==o&&o.detachView(s[Be]),i[vn]=null,i[Ma]=null,i[Ct]&=-129}return i}function ly(n,t){if(!(256&t[Ct])){const e=t[Yt];e.destroyNode&&uy(n,t,e,3,null,null),function i6(n){let t=n[Mf];if(!t)return U1(n[Be],n);for(;t;){let e=null;if(ks(t))e=t[Mf];else{const i=t[mn];i&&(e=i)}if(!e){for(;t&&!t[Ma]&&t!==n;)ks(t)&&U1(t[Be],t),t=t[vn];null===t&&(t=n),ks(t)&&U1(t[Be],t),e=t&&t[Ma]}t=e}}(t)}}function U1(n,t){if(!(256&t[Ct])){t[Ct]&=-129,t[Ct]|=256,t[Uc]&&function Gd(n){if(Vl(n),Vh(n))for(let t=0;t=0?i[o]():i[-o].unsubscribe(),s+=2}else e[s].call(i[e[s+1]]);null!==i&&(t[eu]=null);const r=t[Xh];if(null!==r){t[Xh]=null;for(let s=0;s-1){const{encapsulation:s}=n.data[i.directiveStart+r];if(s===Ia.None||s===Ia.Emulated)return null}return qs(i,e)}}(n,t.parent,e)}function qc(n,t,e,i,r){n.insertBefore(t,e,i,r)}function TL(n,t,e){n.appendChild(t,e)}function AL(n,t,e,i,r){null!==i?qc(n,t,e,i,r):TL(n,t,e)}function hy(n,t){return n.parentNode(t)}let V1,OL=function NL(n,t,e){return 40&n.type?qs(n,e):null};function cy(n,t,e,i){const r=j1(n,i,t),s=t[Yt],a=function LL(n,t,e){return OL(n,t,e)}(i.parent||t[Os],i,t);if(null!=r)if(Array.isArray(e))for(let l=0;lnull;function sM(n,t,e=!1){return JL(n,t,e)}class G6{}class rN{}class q6{resolveComponentFactory(t){throw function X6(n){const t=Error(`No component factory found for ${dt(n)}.`);return t.ngComponent=n,t}(t)}}let by=(()=>{class n{static{this.NULL=new q6}}return n})();function $6(){return Tu(fr(),Se())}function Tu(n,t){return new $c(qs(n,t))}let $c=(()=>{class n{constructor(e){this.nativeElement=e}static{this.__NG_ELEMENT_ID__=$6}}return n})();function Z6(n){return n instanceof $c?n.nativeElement:n}class sN{}let hM=(()=>{class n{constructor(){this.destroyNode=null}static{this.__NG_ELEMENT_ID__=()=>function J6(){const n=Se(),e=To(fr().index,n);return(ks(e)?e:n)[Yt]}()}}return n})(),K6=(()=>{class n{static{this.\u0275prov=Yi({token:n,providedIn:"root",factory:()=>null})}}return n})();const cM={};function Gf(n,t,e,i,r=!1){for(;null!==e;){const s=t[e.index];null!==s&&i.push(pr(s)),Ps(s)&&pN(s,i);const o=e.type;if(8&o)Gf(n,t,e.child,i);else if(32&o){const a=F1(e,t);let l;for(;l=a();)i.push(l)}else if(16&o){const a=PL(t,e);if(Array.isArray(a))i.push(...a);else{const l=Wc(t[Jr]);Gf(l[Be],l,a,i,!0)}}e=r?e.projectionNext:e.next}return i}function pN(n,t){for(let e=mn;e!1,producerRecomputeValue:()=>{},consumerMarkedDirty:()=>{},consumerOnSignalRead:()=>{},consumerIsAlwaysLive:!0,consumerMarkedDirty:n=>{Tf(n.lView)},consumerOnSignalRead(){this.lView[Uc]=this}};function gN(n){return mN(n[Mf])}function vN(n){return mN(n[Ma])}function mN(n){for(;null!==n&&!Ps(n);)n=n[Ma];return n}function pM(n){return n.ngOriginalError}class eh{constructor(){this._console=console}handleError(t){const e=this._findOriginalError(t);this._console.error("ERROR",t),e&&this._console.error("ORIGINAL ERROR",e)}_findOriginalError(t){let e=t&&pM(t);for(;e&&pM(e);)e=pM(e);return e||null}}const SN=new Ht("",{providedIn:"root",factory:()=>Ri(eh).handleError.bind(void 0)}),bN=new Ht("",{providedIn:"root",factory:()=>!1}),Qt={};function Ey(n=1){EN(xi(),Se(),zs()+n,!1)}function EN(n,t,e,i){if(!i)if(3==(3&t[Ct])){const s=n.preOrderCheckHooks;null!==s&&_m(t,s,e)}else{const s=n.preOrderHooks;null!==s&&Um(t,s,0,e)}Yc(e)}function Ot(n,t=Di.Default){const e=Se();return null===e?Fi(n,t):zA(fr(),e,vt(n),t)}function DN(n,t,e,i,r,s){const o=Wi(null);try{let a=null;r&Gh.SignalBased&&(a=t[i][Ts]),null!==a&&void 0!==a.transformFn&&(s=a.transformFn(s)),r&Gh.HasDecoratorInputTransform&&(s=n.inputTransforms[i].call(t,s)),null!==n.setInput?n.setInput(t,a,s,e,i):nA(t,a,i,s)}finally{Wi(o)}}function Dy(n,t,e,i,r,s,o,a,l,h,c){const d=t.blueprint.slice();return d[Vr]=r,d[Ct]=204|i,(null!==h||n&&2048&n[Ct])&&(d[Ct]|=2048),dA(d),d[vn]=d[tu]=n,d[Er]=e,d[ql]=o||n&&n[ql],d[Yt]=a||n&&n[Yt],d[Xs]=l||n&&n[Xs]||null,d[Os]=s,d[Cf]=function Wj(){return Vj++}(),d[wa]=c,d[eA]=h,d[Jr]=2==t.type?n[Jr]:d,d}function Au(n,t,e,i,r){let s=n.data[t];if(null===s)s=function fM(n,t,e,i,r){const s=vA(),o=Zb(),l=n.data[t]=function LV(n,t,e,i,r,s){let o=t?t.injectorIndex:-1,a=0;return function su(){return null!==Rt.skipHydrationRootTNode}()&&(a|=128),{type:e,index:i,insertBeforeIndex:null,injectorIndex:o,directiveStart:-1,directiveEnd:-1,directiveStylingLast:-1,componentOffset:-1,propertyBindings:null,flags:a,providerIndexes:0,value:r,attrs:s,mergedAttrs:null,localNames:null,initialInputs:void 0,inputs:null,outputs:null,tView:null,next:null,prev:null,projectionNext:null,child:null,parent:t,projection:null,styles:null,stylesWithoutHost:null,residualStyles:void 0,classes:null,classesWithoutHost:null,residualClasses:void 0,classBindings:0,styleBindings:0}}(0,o?s:s&&s.parent,e,t,i,r);return null===n.firstChild&&(n.firstChild=l),null!==s&&(o?null==s.child&&null!==l.parent&&(s.child=l):null===s.next&&(s.next=l,l.prev=s)),l}(n,t,e,i,r),function MU(){return Rt.lFrame.inI18n}()&&(s.flags|=32);else if(64&s.type){s.type=e,s.value=i,s.attrs=r;const o=function Af(){const n=Rt.lFrame,t=n.currentTNode;return n.isParent?t:t.parent}();s.injectorIndex=null===o?-1:o.injectorIndex}return ol(s,!0),s}function Xf(n,t,e,i){if(0===e)return-1;const r=t.length;for(let s=0;sUt&&EN(n,t,Ut,!1),nl(o?2:0,r),e(i,r)}finally{Yc(s),nl(o?3:1,r)}}function gM(n,t,e){if(jb(t)){const i=Wi(null);try{const s=t.directiveEnd;for(let o=t.directiveStart;onull;function LN(n,t,e,i,r){for(let s in t){if(!t.hasOwnProperty(s))continue;const o=t[s];if(void 0===o)continue;i??={};let a,l=Gh.None;Array.isArray(o)?(a=o[0],l=o[1]):a=o;let h=s;if(null!==r){if(!r.hasOwnProperty(s))continue;h=r[s]}0===n?NN(i,e,h,a,l):NN(i,e,h,a)}return i}function NN(n,t,e,i,r){let s;n.hasOwnProperty(e)?(s=n[e]).push(t,i):s=n[e]=[t,i],void 0!==r&&s.push(r)}function ON(n,t,e,i,r,s){for(let h=0;h0;){const e=n[--t];if("number"==typeof e&&e<0)return e}return 0})(o)!=a&&o.push(a),o.push(e,i,s)}}(n,t,i,Xf(n,e,r.hostVars,Qt),r)}function YV(n,t,e,i,r,s){const o=s[t];if(null!==o)for(let a=0;an.nextProducerIndex;)n.producerNode.pop(),n.producerLastReadVersion.pop(),n.producerIndexOfThis.pop()}}(a,o),function pV(n){n.lView[Uc]!==n&&(n.lView=null,fN.push(n))}(a)),r1()}}function FN(n,t){for(let e=gN(n);null!==e;e=vN(e))for(let i=mn;i-1&&(Ff(t,i),Qm(e,i))}this._attachedToViewContainer=!1}ly(this._lView[Be],this._lView)}onDestroy(t){!function Hm(n,t){if(256==(256&n[Ct]))throw new F(911,!1);null===n[Xh]&&(n[Xh]=[]),n[Xh].push(t)}(this._lView,t)}markForCheck(){qf(this._cdRefInjectingView||this._lView)}detach(){this._lView[Ct]&=-129}reattach(){qb(this._lView),this._lView[Ct]|=128}detectChanges(){this._lView[Ct]|=1024,function CM(n,t=!0){const e=n[ql],i=e.rendererFactory;i.begin?.();try{!function XV(n){EM(n,0);let t=0;for(;pA(n);){if(100===t)throw new F(103,!1);t++,EM(n,1)}}(n)}catch(s){throw t&&Ty(n,s),s}finally{i.end?.(),e.inlineEffectRunner?.flush()}}(this._lView,this.notifyErrorHandler)}checkNoChanges(){}attachToViewContainerRef(){if(this._appRef)throw new F(902,!1);this._attachedToViewContainer=!0}detachFromAppRef(){this._appRef=null,EL(this._lView[Be],this._lView)}attachToAppRef(t){if(this._attachedToViewContainer)throw new F(902,!1);this._appRef=t,qb(this._lView)}}const VN=new Set;function xM(n){return t=>{setTimeout(n,void 0,t)}}const Yo=class h7 extends Pt{constructor(t=!1){super(),this.__isAsync=t}emit(t){super.next(t)}subscribe(t,e,i){let r=t,s=e||(()=>null),o=i;if(t&&"object"==typeof t){const l=t;r=l.next?.bind(l),s=l.error?.bind(l),o=l.complete?.bind(l)}this.__isAsync&&(s=xM(s),r&&(r=xM(r)),o&&(o=xM(o)));const a=super.subscribe({next:r,error:s,complete:o});return t instanceof As&&t.add(a),a}};function WN(...n){}class zr{constructor({enableLongStackTrace:t=!1,shouldCoalesceEventChangeDetection:e=!1,shouldCoalesceRunChangeDetection:i=!1}){if(this.hasPendingMacrotasks=!1,this.hasPendingMicrotasks=!1,this.isStable=!0,this.onUnstable=new Yo(!1),this.onMicrotaskEmpty=new Yo(!1),this.onStable=new Yo(!1),this.onError=new Yo(!1),typeof Zone>"u")throw new F(908,!1);Zone.assertZonePatched();const r=this;r._nesting=0,r._outer=r._inner=Zone.current,Zone.TaskTrackingZoneSpec&&(r._inner=r._inner.fork(new Zone.TaskTrackingZoneSpec)),t&&Zone.longStackTraceZoneSpec&&(r._inner=r._inner.fork(Zone.longStackTraceZoneSpec)),r.shouldCoalesceEventChangeDetection=!i&&e,r.shouldCoalesceRunChangeDetection=i,r.lastRequestAnimationFrameId=-1,r.nativeRequestAnimationFrame=function c7(){const n="function"==typeof rr.requestAnimationFrame;let t=rr[n?"requestAnimationFrame":"setTimeout"],e=rr[n?"cancelAnimationFrame":"clearTimeout"];if(typeof Zone<"u"&&t&&e){const i=t[Zone.__symbol__("OriginalDelegate")];i&&(t=i);const r=e[Zone.__symbol__("OriginalDelegate")];r&&(e=r)}return{nativeRequestAnimationFrame:t,nativeCancelAnimationFrame:e}}().nativeRequestAnimationFrame,function p7(n){const t=()=>{!function u7(n){n.isCheckStableRunning||-1!==n.lastRequestAnimationFrameId||(n.lastRequestAnimationFrameId=n.nativeRequestAnimationFrame.call(rr,()=>{n.fakeTopEventTask||(n.fakeTopEventTask=Zone.root.scheduleEventTask("fakeTopEventTask",()=>{n.lastRequestAnimationFrameId=-1,AM(n),n.isCheckStableRunning=!0,TM(n),n.isCheckStableRunning=!1},void 0,()=>{},()=>{})),n.fakeTopEventTask.invoke()}),AM(n))}(n)};n._inner=n._inner.fork({name:"angular",properties:{isAngularZone:!0},onInvokeTask:(e,i,r,s,o,a)=>{if(function f7(n){return!(!Array.isArray(n)||1!==n.length)&&!0===n[0].data?.__ignore_ng_zone__}(a))return e.invokeTask(r,s,o,a);try{return YN(n),e.invokeTask(r,s,o,a)}finally{(n.shouldCoalesceEventChangeDetection&&"eventTask"===s.type||n.shouldCoalesceRunChangeDetection)&&t(),QN(n)}},onInvoke:(e,i,r,s,o,a,l)=>{try{return YN(n),e.invoke(r,s,o,a,l)}finally{n.shouldCoalesceRunChangeDetection&&t(),QN(n)}},onHasTask:(e,i,r,s)=>{e.hasTask(r,s),i===r&&("microTask"==s.change?(n._hasPendingMicrotasks=s.microTask,AM(n),TM(n)):"macroTask"==s.change&&(n.hasPendingMacrotasks=s.macroTask))},onHandleError:(e,i,r,s)=>(e.handleError(r,s),n.runOutsideAngular(()=>n.onError.emit(s)),!1)})}(r)}static isInAngularZone(){return typeof Zone<"u"&&!0===Zone.current.get("isAngularZone")}static assertInAngularZone(){if(!zr.isInAngularZone())throw new F(909,!1)}static assertNotInAngularZone(){if(zr.isInAngularZone())throw new F(909,!1)}run(t,e,i){return this._inner.run(t,e,i)}runTask(t,e,i,r){const s=this._inner,o=s.scheduleEventTask("NgZoneEvent: "+r,t,d7,WN,WN);try{return s.runTask(o,e,i)}finally{s.cancelTask(o)}}runGuarded(t,e,i){return this._inner.runGuarded(t,e,i)}runOutsideAngular(t){return this._outer.run(t)}}const d7={};function TM(n){if(0==n._nesting&&!n.hasPendingMicrotasks&&!n.isStable)try{n._nesting++,n.onMicrotaskEmpty.emit(null)}finally{if(n._nesting--,!n.hasPendingMicrotasks)try{n.runOutsideAngular(()=>n.onStable.emit(null))}finally{n.isStable=!0}}}function AM(n){n.hasPendingMicrotasks=!!(n._hasPendingMicrotasks||(n.shouldCoalesceEventChangeDetection||n.shouldCoalesceRunChangeDetection)&&-1!==n.lastRequestAnimationFrameId)}function YN(n){n._nesting++,n.isStable&&(n.isStable=!1,n.onUnstable.emit(null))}function QN(n){n._nesting--,TM(n)}let Zf=(()=>{class n{constructor(){this.handler=null,this.internalCallbacks=[]}execute(){const e=[...this.internalCallbacks];this.internalCallbacks.length=0;for(const r of e)r();return!!this.handler?.execute()||e.length>0}ngOnDestroy(){this.handler?.destroy(),this.handler=null,this.internalCallbacks.length=0}static{this.\u0275prov=Yi({token:n,providedIn:"root",factory:()=>new n})}}return n})();function y7(n,t){const e=To(t,n),i=e[Be];!function S7(n,t){for(let e=t.length;e0&&HL(n,e,s.join(" "))}}(u,w,f,i),void 0!==e&&function A7(n,t,e){const i=n.projection=[];for(let r=0;r=0;i--){const r=n[i];r.hostVars=t+=r.hostVars,r.hostAttrs=bf(r.hostAttrs,e=bf(e,r.hostAttrs))}}(i)}function N7(n,t){for(const e in t.inputs){if(!t.inputs.hasOwnProperty(e)||n.inputs.hasOwnProperty(e))continue;const i=t.inputs[e];if(void 0!==i&&(n.inputs[e]=i,n.declaredInputs[e]=t.declaredInputs[e],null!==t.inputTransforms)){const r=Array.isArray(i)?i[0]:i;if(!t.inputTransforms.hasOwnProperty(r))continue;n.inputTransforms??={},n.inputTransforms[r]=t.inputTransforms[r]}}}function Ly(n){return n===tl?{}:n===Qi?[]:n}function k7(n,t){const e=n.viewQuery;n.viewQuery=e?(i,r)=>{t(i,r),e(i,r)}:t}function P7(n,t){const e=n.contentQueries;n.contentQueries=e?(i,r,s)=>{t(i,r,s),e(i,r,s)}:t}function z7(n,t){const e=n.hostBindings;n.hostBindings=e?(i,r)=>{t(i,r),e(i,r)}:t}function Nu(n,t){return!t||null===t.firstChild||ny(n)}function ng(n,t,e,i=!0){const r=t[Be];if(function r6(n,t,e,i){const r=mn+i,s=e.length;i>0&&(e[r-1][Ma]=t),i{class n{static{this.__NG_ELEMENT_ID__=h9}}return n})();function h9(){return pO(fr(),Se())}const c9=xn,dO=class extends c9{constructor(t,e,i){super(),this._lContainer=t,this._hostTNode=e,this._hostLView=i}get element(){return Tu(this._hostTNode,this._hostLView)}get injector(){return new Vn(this._hostTNode,this._hostLView)}get parentInjector(){const t=Wm(this._hostTNode,this._hostLView);if(o1(t)){const e=Of(t,this._hostLView),i=Nf(t);return new Vn(e[Be].data[i+8],e)}return new Vn(null,this._hostLView)}clear(){for(;this.length>0;)this.remove(this.length-1)}get(t){const e=uO(this._lContainer);return null!==e&&e[t]||null}get length(){return this._lContainer.length-mn}createEmbeddedView(t,e,i){let r,s;"number"==typeof i?r=i:null!=i&&(r=i.index,s=i.injector);const a=t.createEmbeddedViewImpl(e||{},s,null);return this.insertImpl(a,r,Nu(this._hostTNode,null)),a}createComponent(t,e,i,r,s){const o=t&&!function kf(n){return"function"==typeof n}(t);let a;if(o)a=e;else{const f=e||{};a=f.index,i=f.injector,r=f.projectableNodes,s=f.environmentInjector||f.ngModuleRef}const l=o?t:new Jf(ci(t)),h=i||this.parentInjector;if(!s&&null==l.ngModule){const g=(o?h:this.parentInjector).get(Jl,null);g&&(s=g)}ci(l.componentType??{});const p=l.create(h,r,null,s);return this.insertImpl(p.hostView,a,Nu(this._hostTNode,null)),p}insert(t,e){return this.insertImpl(t,e,!0)}insertImpl(t,e,i){const r=t._lView;if(function hU(n){return Ps(n[vn])}(r)){const a=this.indexOf(t);if(-1!==a)this.detach(a);else{const l=r[vn],h=new dO(l,l[Os],l[vn]);h.detach(h.indexOf(t))}}const s=this._adjustIndex(e),o=this._lContainer;return ng(o,r,s,i),t.attachToViewContainerRef(),UA(HM(o),s,t),t}move(t,e){return this.insert(t,e)}indexOf(t){const e=uO(this._lContainer);return null!==e?e.indexOf(t):-1}remove(t){const e=this._adjustIndex(t,-1),i=Ff(this._lContainer,e);i&&(Qm(HM(this._lContainer),e),ly(i[Be],i))}detach(t){const e=this._adjustIndex(t,-1),i=Ff(this._lContainer,e);return i&&null!=Qm(HM(this._lContainer),e)?new $f(i):null}_adjustIndex(t,e=0){return t??this.length+e}};function uO(n){return n[8]}function HM(n){return n[8]||(n[8]=[])}function pO(n,t){let e;const i=t[n.index];return Ps(i)?e=i:(e=function PN(n,t,e,i){return[n,!0,0,t,null,i,null,e,null,null]}(i,t,null,n),t[n.index]=e,xy(t,e)),fO(e,t,n,i),new dO(e,n,t)}let fO=function vO(n,t,e,i){if(n[rl])return;let r;r=8&e.type?pr(i):function d9(n,t){const e=n[Yt],i=e.createComment(""),r=qs(t,n);return qc(e,hy(e,r),i,function l6(n,t){return n.nextSibling(t)}(e,r),!1),i}(t,e),n[rl]=r};function Xu(n,t,e){const i=Se();return function Tn(n,t,e){return!Object.is(n[t],e)&&(n[t]=e,!0)}(i,function al(){return Rt.lFrame.bindingIndex++}(),t)&&function No(n,t,e,i,r,s,o,a){const l=qs(t,e);let c,h=t.inputs;!a&&null!=h&&(c=h[i])?(wM(n,e,c,i,r),jc(t)&&function kV(n,t){const e=To(t,n);16&e[Ct]||(e[Ct]|=64)}(e,t.index)):3&t.type&&(i=function OV(n){return"class"===n?"className":"for"===n?"htmlFor":"formaction"===n?"formAction":"innerHtml"===n?"innerHTML":"readonly"===n?"readOnly":"tabindex"===n?"tabIndex":n}(i),r=null!=o?o(r,t.value||"",i):r,s.setProperty(l,i,r))}(xi(),function Pr(){const n=Rt.lFrame;return xf(n.tView,n.selectedIndex)}(),i,n,t,i[Yt],e,!1),Xu}function $M(n,t,e,i,r){const o=r?"class":"style";wM(n,e,t.inputs[o],o,i)}function id(n,t,e,i){const r=Se(),s=xi(),o=Ut+n,a=r[Yt],l=s.firstCreatePass?function B8(n,t,e,i,r,s){const o=t.consts,l=Au(t,n,2,i,sl(o,r));return function SM(n,t,e,i){if(gA()){const r=null===i?null:{"":-1},s=function FV(n,t){const e=n.directiveRegistry;let i=null,r=null;if(e)for(let s=0;s(qh(!0),ay(i,r,function DA(){return Rt.lFrame.currentNamespace}()));const $u="en-US";let Mk=$u;function ow(n){return!!n&&"function"==typeof n.then}function Gk(n){return!!n&&"function"==typeof n.subscribe}function aw(n,t,e,i){const r=Se(),s=xi(),o=fr();return function qk(n,t,e,i,r,s,o){const a=zm(i),h=n.firstCreatePass&&HN(n),c=t[Er],d=RN(t);let u=!0;if(3&i.type||o){const g=qs(i,t),v=o?o(g):g,y=d.length,S=o?M=>o(pr(M[i.index])):i.index;let b=null;if(!o&&a&&(b=function UW(n,t,e,i){const r=n.cleanup;if(null!=r)for(let s=0;sl?a[l]:null}"string"==typeof o&&(s+=2)}return null}(n,t,r,i.index)),null!==b)(b.__ngLastListenerFn__||b).__ngNextListenerFn__=s,b.__ngLastListenerFn__=s,u=!1;else{s=Zk(i,t,c,s,!1);const M=e.listen(v,r,s);d.push(s,M),h&&h.push(r,S,y,y+1)}}else s=Zk(i,t,c,s,!1);const p=i.outputs;let f;if(u&&null!==p&&(f=p[r])){const g=f.length;if(g)for(let v=0;v-1?To(n.index,t):t);let l=$k(t,e,i,o),h=s.__ngNextListenerFn__;for(;h;)l=$k(t,e,h,o)&&l,h=h.__ngNextListenerFn__;return r&&!1===l&&o.preventDefault(),l}}function QW(){return this._results[Symbol.iterator]()}class hw{get changes(){return this._changes??=new Yo}constructor(t=!1){this._emitDistinctChangesOnly=t,this.dirty=!0,this._results=[],this._changesDetected=!1,this._changes=void 0,this.length=0,this.first=void 0,this.last=void 0;const e=hw.prototype;e[Symbol.iterator]||(e[Symbol.iterator]=QW)}get(t){return this._results[t]}map(t){return this._results.map(t)}filter(t){return this._results.filter(t)}find(t){return this._results.find(t)}reduce(t,e){return this._results.reduce(t,e)}forEach(t){this._results.forEach(t)}some(t){return this._results.some(t)}toArray(){return this._results.slice()}toString(){return this._results.toString()}reset(t,e){this.dirty=!1;const i=function oo(n){return n.flat(Number.POSITIVE_INFINITY)}(t);(this._changesDetected=!function $U(n,t,e){if(n.length!==t.length)return!1;for(let i=0;i{class n{static{this.__NG_ELEMENT_ID__=qW}}return n})();const GW=ih,XW=class extends GW{constructor(t,e,i){super(),this._declarationLView=t,this._declarationTContainer=e,this.elementRef=i}get ssrId(){return this._declarationTContainer.tView?.ssrId||null}createEmbeddedView(t,e){return this.createEmbeddedViewImpl(t,e)}createEmbeddedViewImpl(t,e,i){const r=function rg(n,t,e,i){const r=t.tView,a=Dy(n,r,e,4096&n[Ct]?4096:16,null,t,null,null,null,i?.injector??null,i?.dehydratedView??null);a[wf]=n[t.index];const h=n[il];return null!==h&&(a[il]=h.createEmbeddedView(r)),LM(r,a,e),a}(this._declarationLView,this._declarationTContainer,t,{injector:e,dehydratedView:i});return new $f(r)}};function qW(){return Gy(fr(),Se())}function Gy(n,t){return 4&n.type?new XW(t,n,Tu(n,t)):null}class cw{constructor(t){this.queryList=t,this.matches=null}clone(){return new cw(this.queryList)}setDirty(){this.queryList.setDirty()}}class dw{constructor(t=[]){this.queries=t}createEmbeddedView(t){const e=t.queries;if(null!==e){const i=null!==t.contentQueries?t.contentQueries[0]:e.length,r=[];for(let s=0;s0)i.push(o[a/2]);else{const h=s[a+1],c=t[-l];for(let d=mn;d(qh(!0),function oy(n,t){return n.createText(t)}(t[Yt],i));function vw(n,t,e,i,r){if(n=vt(n),Array.isArray(n))for(let s=0;s>20;if(Gc(n)||!n.multi){const p=new Lf(h,r,Ot),f=yw(l,t,r?c:c+u,d);-1===f?(h1(Vm(a,o),s,l),mw(s,n,t.length),t.push(l),a.directiveStart++,a.directiveEnd++,r&&(a.providerIndexes+=1048576),e.push(p),o.push(p)):(e[f]=p,o[f]=p)}else{const p=yw(l,t,c+u,d),f=yw(l,t,c,c+u),v=f>=0&&e[f];if(r&&!v||!r&&!(p>=0&&e[p])){h1(Vm(a,o),s,l);const y=function yY(n,t,e,i,r){const s=new Lf(n,e,Ot);return s.multi=[],s.index=t,s.componentProviders=0,kP(s,r,i&&!e),s}(r?mY:vY,e.length,r,i,h);!r&&v&&(e[f].providerFactory=y),mw(s,n,t.length,0),t.push(l),a.directiveStart++,a.directiveEnd++,r&&(a.providerIndexes+=1048576),e.push(y),o.push(y)}else mw(s,n,p>-1?p:f,kP(e[r?f:p],h,!r&&i));!r&&i&&v&&e[f].componentProviders++}}}function mw(n,t,e,i){const r=Gc(t),s=function gj(n){return!!n.useClass}(t);if(r||s){const l=(s?vt(t.useClass):t).prototype.ngOnDestroy;if(l){const h=n.destroyHooks||(n.destroyHooks=[]);if(!r&&t.multi){const c=h.indexOf(e);-1===c?h.push(e,[i,l]):h[c+1].push(i,l)}else h.push(e,l)}}}function kP(n,t,e){return e&&n.componentProviders++,n.multi.push(t)-1}function yw(n,t,e,i){for(let r=e;r{e.providersResolver=(i,r)=>function gY(n,t,e){const i=xi();if(i.firstCreatePass){const r=Ca(n);vw(e,i.data,i.blueprint,r,!0),vw(t,i.data,i.blueprint,r,!1)}}(i,r?r(n):n,t)}}class sd{}class zP extends sd{constructor(t){super(),this.componentFactoryResolver=new JN(this),this.instance=null;const e=new yu([...t.providers,{provide:sd,useValue:this},{provide:by,useValue:this.componentFactoryResolver}],t.parent||Km(),t.debugName,new Set(["environment"]));this.injector=e,t.runEnvironmentInitializers&&e.resolveInjectorInitializers()}destroy(){this.injector.destroy()}onDestroy(t){this.injector.onDestroy(t)}}let wY=(()=>{class n{constructor(e){this._injector=e,this.cachedInjectors=new Map}getOrCreateStandaloneInjector(e){if(!e.standalone)return null;if(!this.cachedInjectors.has(e)){const i=XA(0,e.type),r=i.length>0?function MY(n,t,e=null){return new zP({providers:n,parent:t,debugName:e,runEnvironmentInitializers:!0}).injector}([i],this._injector,`Standalone[${e.type.name}]`):null;this.cachedInjectors.set(e,r)}return this.cachedInjectors.get(e)}ngOnDestroy(){try{for(const e of this.cachedInjectors.values())null!==e&&e.destroy()}finally{this.cachedInjectors.clear()}}static{this.\u0275prov=Yi({token:n,providedIn:"environment",factory:()=>new n(Fi(Jl))})}}return n})();function RP(n){(function Zc(n){VN.has(n)||(VN.add(n),performance?.mark?.("mark_feature_usage",{detail:{feature:n}}))})("NgStandalone"),n.getStandaloneInjector=t=>t.get(wY).getOrCreateStandaloneInjector(n)}let Tw=(()=>{class n{constructor(){this.taskId=0,this.pendingTasks=new Set,this.hasPendingTasks=new _o(!1)}get _hasPendingTasks(){return this.hasPendingTasks.value}add(){this._hasPendingTasks||this.hasPendingTasks.next(!0);const e=this.taskId++;return this.pendingTasks.add(e),e}remove(e){this.pendingTasks.delete(e),0===this.pendingTasks.size&&this._hasPendingTasks&&this.hasPendingTasks.next(!1)}ngOnDestroy(){this.pendingTasks.clear(),this._hasPendingTasks&&this.hasPendingTasks.next(!1)}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();const g2=new Ht(""),XQ=new Ht("");let kw=(()=>{class n{constructor(){this.initialized=!1,this.done=!1,this.donePromise=new Promise((e,i)=>{this.resolve=e,this.reject=i}),this.appInits=Ri(XQ,{optional:!0})??[]}runInitializers(){if(this.initialized)return;const e=[];for(const r of this.appInits){const s=r();if(ow(s))e.push(s);else if(Gk(s)){const o=new Promise((a,l)=>{s.subscribe({complete:a,error:l})});e.push(o)}}const i=()=>{this.done=!0,this.resolve()};Promise.all(e).then(()=>{i()}).catch(r=>{this.reject(r)}),0===e.length&&i(),this.initialized=!0}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();const v2=new Ht("");let Ku=(()=>{class n{constructor(){this._bootstrapListeners=[],this._runningTick=!1,this._destroyed=!1,this._destroyListeners=[],this._views=[],this.internalErrorHandler=Ri(SN),this.afterRenderEffectManager=Ri(Zf),this.componentTypes=[],this.components=[],this.isStable=Ri(Tw).hasPendingTasks.pipe(jr(e=>!e)),this._injector=Ri(Jl)}get destroyed(){return this._destroyed}get injector(){return this._injector}bootstrap(e,i){const r=e instanceof rN;if(!this._injector.get(kw).done)throw!r&&function _c(n){const t=ci(n)||jn(n)||gs(n);return null!==t&&t.standalone}(e),new F(405,!1);let o;o=r?e:this._injector.get(by).resolveComponentFactory(e),this.componentTypes.push(o.componentType);const a=function $Q(n){return n.isBoundToModule}(o)?void 0:this._injector.get(sd),h=o.create(Wo.NULL,[],i||o.selector,a),c=h.location.nativeElement,d=h.injector.get(g2,null);return d?.registerApplication(c),h.onDestroy(()=>{this.detachView(h.hostView),Ky(this.components,h),d?.unregisterApplication(c)}),this._loadComponent(h),h}tick(){if(this._runningTick)throw new F(101,!1);try{this._runningTick=!0;for(let e of this._views)e.detectChanges()}catch(e){this.internalErrorHandler(e)}finally{try{this.afterRenderEffectManager.execute()}catch(e){this.internalErrorHandler(e)}this._runningTick=!1}}attachView(e){const i=e;this._views.push(i),i.attachToAppRef(this)}detachView(e){const i=e;Ky(this._views,i),i.detachFromAppRef()}_loadComponent(e){this.attachView(e.hostView),this.tick(),this.components.push(e);const i=this._injector.get(v2,[]);[...this._bootstrapListeners,...i].forEach(r=>r(e))}ngOnDestroy(){if(!this._destroyed)try{this._destroyListeners.forEach(e=>e()),this._views.slice().forEach(e=>e.destroy())}finally{this._destroyed=!0,this._views=[],this._bootstrapListeners=[],this._destroyListeners=[]}}onDestroy(e){return this._destroyListeners.push(e),()=>Ky(this._destroyListeners,e)}destroy(){if(this._destroyed)throw new F(406,!1);const e=this._injector;e.destroy&&!e.destroyed&&e.destroy()}get viewCount(){return this._views.length}warnIfDestroyed(){}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();function Ky(n,t){const e=n.indexOf(t);e>-1&&n.splice(e,1)}let JQ=(()=>{class n{constructor(){this.zone=Ri(zr),this.applicationRef=Ri(Ku)}initialize(){this._onMicrotaskEmptySubscription||(this._onMicrotaskEmptySubscription=this.zone.onMicrotaskEmpty.subscribe({next:()=>{this.zone.run(()=>{this.applicationRef.tick()})}}))}ngOnDestroy(){this._onMicrotaskEmptySubscription?.unsubscribe()}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();function b2(n){return[{provide:zr,useFactory:n},{provide:mu,multi:!0,useFactory:()=>{const t=Ri(JQ,{optional:!0});return()=>t.initialize()}},{provide:mu,multi:!0,useFactory:()=>{const t=Ri(tG);return()=>{t.initialize()}}},{provide:SN,useFactory:KQ}]}function KQ(){const n=Ri(zr),t=Ri(eh);return e=>n.runOutsideAngular(()=>t.handleError(e))}function eG(n){return function I1(n){return{\u0275providers:n}}([[],b2(()=>new zr(function M2(n){return{enableLongStackTrace:!1,shouldCoalesceEventChangeDetection:n?.eventCoalescing??!1,shouldCoalesceRunChangeDetection:n?.runCoalescing??!1}}(n)))])}let tG=(()=>{class n{constructor(){this.subscription=new As,this.initialized=!1,this.zone=Ri(zr),this.pendingTasks=Ri(Tw)}initialize(){if(this.initialized)return;this.initialized=!0;let e=null;!this.zone.isStable&&!this.zone.hasPendingMacrotasks&&!this.zone.hasPendingMicrotasks&&(e=this.pendingTasks.add()),this.zone.runOutsideAngular(()=>{this.subscription.add(this.zone.onStable.subscribe(()=>{zr.assertNotInAngularZone(),queueMicrotask(()=>{null!==e&&!this.zone.hasPendingMacrotasks&&!this.zone.hasPendingMicrotasks&&(this.pendingTasks.remove(e),e=null)})}))}),this.subscription.add(this.zone.onUnstable.subscribe(()=>{zr.assertInAngularZone(),e??=this.pendingTasks.add()}))}ngOnDestroy(){this.subscription.unsubscribe()}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();const rh=new Ht("",{providedIn:"root",factory:()=>Ri(rh,Di.Optional|Di.SkipSelf)||function iG(){return typeof $localize<"u"&&$localize.locale||$u}()}),Pw=new Ht("");let rc=null;function DG(n){try{const{rootComponent:t,appProviders:e,platformProviders:i}=n,r=function aG(n=[]){if(rc)return rc;const t=function E2(n=[],t){return Wo.create({name:t,providers:[{provide:w1,useValue:"platform"},{provide:Pw,useValue:new Set([()=>rc=null])},...n]})}(n);return rc=t,function m2(){!function bb(n){qd=n}(()=>{throw new F(600,!1)})}(),function D2(n){n.get(sL,null)?.forEach(e=>e())}(t),t}(i),s=[eG(),...e||[]],a=new zP({providers:s,parent:r,debugName:"",runEnvironmentInitializers:!1}).injector,l=a.get(zr);return l.run(()=>{a.resolveInjectorInitializers();const h=a.get(eh,null);let c;l.runOutsideAngular(()=>{c=l.onError.subscribe({next:p=>{h.handleError(p)}})});const d=()=>a.destroy(),u=r.get(Pw);return u.add(d),a.onDestroy(()=>{c.unsubscribe(),u.delete(d)}),function y2(n,t,e){try{const i=e();return ow(i)?i.catch(r=>{throw t.runOutsideAngular(()=>n.handleError(r)),r}):i}catch(i){throw t.runOutsideAngular(()=>n.handleError(i)),i}}(h,l,()=>{const p=a.get(kw);return p.runInitializers(),p.donePromise.then(()=>{!function wk(n){ro(n,"Expected localeId to be defined"),"string"==typeof n&&(Mk=n.toLowerCase().replace(/_/g,"-"))}(a.get(rh,$u)||$u);const g=a.get(Ku);return void 0!==t&&g.bootstrap(t),g})})})}catch(t){return Promise.reject(t)}}let $2=null;function jw(){return $2}class UG{}const ad=new Ht("");let sq=(()=>{class n{static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275mod=Nm({type:n})}static{this.\u0275inj=yf({})}}return n})();function uz(n){return"server"===n}class kq extends UG{constructor(){super(...arguments),this.supportsDOMEvents=!0}}class sC extends kq{static makeCurrent(){!function _G(n){$2??=n}(new sC)}onAndCancel(t,e,i){return t.addEventListener(e,i),()=>{t.removeEventListener(e,i)}}dispatchEvent(t,e){t.dispatchEvent(e)}remove(t){t.parentNode&&t.parentNode.removeChild(t)}createElement(t,e){return(e=e||this.getDefaultDocument()).createElement(t)}createHtmlDocument(){return document.implementation.createHTMLDocument("fakeTitle")}getDefaultDocument(){return document}isElementNode(t){return t.nodeType===Node.ELEMENT_NODE}isShadowRoot(t){return t instanceof DocumentFragment}getGlobalEventTarget(t,e){return"window"===e?window:"document"===e?t:"body"===e?t.body:null}getBaseHref(t){const e=function Pq(){return Eg=Eg||document.querySelector("base"),Eg?Eg.getAttribute("href"):null}();return null==e?null:function zq(n){return new URL(n,document.baseURI).pathname}(e)}resetBaseElement(){Eg=null}getUserAgent(){return window.navigator.userAgent}getCookie(t){return function xX(n,t){t=encodeURIComponent(t);for(const e of n.split(";")){const i=e.indexOf("="),[r,s]=-1==i?[e,""]:[e.slice(0,i),e.slice(i+1)];if(r.trim()===t)return decodeURIComponent(s)}return null}(document.cookie,t)}}let Eg=null,Hq=(()=>{class n{build(){return new XMLHttpRequest}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();const oC=new Ht("");let vz=(()=>{class n{constructor(e,i){this._zone=i,this._eventNameToPlugin=new Map,e.forEach(r=>{r.manager=this}),this._plugins=e.slice().reverse()}addEventListener(e,i,r){return this._findPluginFor(i).addEventListener(e,i,r)}getZone(){return this._zone}_findPluginFor(e){let i=this._eventNameToPlugin.get(e);if(i)return i;if(i=this._plugins.find(s=>s.supports(e)),!i)throw new F(5101,!1);return this._eventNameToPlugin.set(e,i),i}static{this.\u0275fac=function(i){return new(i||n)(Fi(oC),Fi(zr))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();class mz{constructor(t){this._doc=t}}const aC="ng-app-id";let yz=(()=>{class n{constructor(e,i,r,s={}){this.doc=e,this.appId=i,this.nonce=r,this.platformId=s,this.styleRef=new Map,this.hostNodes=new Set,this.styleNodesInDOM=this.collectServerRenderedStyles(),this.platformIsServer=uz(s),this.resetHostNodes()}addStyles(e){for(const i of e)1===this.changeUsageCount(i,1)&&this.onStyleAdded(i)}removeStyles(e){for(const i of e)this.changeUsageCount(i,-1)<=0&&this.onStyleRemoved(i)}ngOnDestroy(){const e=this.styleNodesInDOM;e&&(e.forEach(i=>i.remove()),e.clear());for(const i of this.getAllStyles())this.onStyleRemoved(i);this.resetHostNodes()}addHost(e){this.hostNodes.add(e);for(const i of this.getAllStyles())this.addStyleToHost(e,i)}removeHost(e){this.hostNodes.delete(e)}getAllStyles(){return this.styleRef.keys()}onStyleAdded(e){for(const i of this.hostNodes)this.addStyleToHost(i,e)}onStyleRemoved(e){const i=this.styleRef;i.get(e)?.elements?.forEach(r=>r.remove()),i.delete(e)}collectServerRenderedStyles(){const e=this.doc.head?.querySelectorAll(`style[${aC}="${this.appId}"]`);if(e?.length){const i=new Map;return e.forEach(r=>{null!=r.textContent&&i.set(r.textContent,r)}),i}return null}changeUsageCount(e,i){const r=this.styleRef;if(r.has(e)){const s=r.get(e);return s.usage+=i,s.usage}return r.set(e,{usage:i,elements:[]}),i}getStyleElement(e,i){const r=this.styleNodesInDOM,s=r?.get(i);if(s?.parentNode===e)return r.delete(i),s.removeAttribute(aC),s;{const o=this.doc.createElement("style");return this.nonce&&o.setAttribute("nonce",this.nonce),o.textContent=i,this.platformIsServer&&o.setAttribute(aC,this.appId),e.appendChild(o),o}}addStyleToHost(e,i){const r=this.getStyleElement(e,i),s=this.styleRef,o=s.get(i)?.elements;o?o.push(r):s.set(i,{elements:[r],usage:1})}resetHostNodes(){const e=this.hostNodes;e.clear(),e.add(this.doc.head)}static{this.\u0275fac=function(i){return new(i||n)(Fi(ad),Fi(L1),Fi(oL,8),Fi(Iu))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();const lC={svg:"http://www.w3.org/2000/svg",xhtml:"http://www.w3.org/1999/xhtml",xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/",math:"http://www.w3.org/1998/MathML/"},hC=/%COMP%/g,Uq=new Ht("",{providedIn:"root",factory:()=>!0});function Iz(n,t){return t.map(e=>e.replace(hC,n))}let bz=(()=>{class n{constructor(e,i,r,s,o,a,l,h=null){this.eventManager=e,this.sharedStylesHost=i,this.appId=r,this.removeStylesOnCompDestroy=s,this.doc=o,this.platformId=a,this.ngZone=l,this.nonce=h,this.rendererByCompId=new Map,this.platformIsServer=uz(a),this.defaultRenderer=new cC(e,o,l,this.platformIsServer)}createRenderer(e,i){if(!e||!i)return this.defaultRenderer;this.platformIsServer&&i.encapsulation===Ia.ShadowDom&&(i={...i,encapsulation:Ia.Emulated});const r=this.getOrCreateRenderer(e,i);return r instanceof wz?r.applyToHost(e):r instanceof dC&&r.applyStyles(),r}getOrCreateRenderer(e,i){const r=this.rendererByCompId;let s=r.get(i.id);if(!s){const o=this.doc,a=this.ngZone,l=this.eventManager,h=this.sharedStylesHost,c=this.removeStylesOnCompDestroy,d=this.platformIsServer;switch(i.encapsulation){case Ia.Emulated:s=new wz(l,h,i,this.appId,c,o,a,d);break;case Ia.ShadowDom:return new Yq(l,h,e,i,o,a,this.nonce,d);default:s=new dC(l,h,i,c,o,a,d)}r.set(i.id,s)}return s}ngOnDestroy(){this.rendererByCompId.clear()}static{this.\u0275fac=function(i){return new(i||n)(Fi(vz),Fi(yz),Fi(L1),Fi(Uq),Fi(ad),Fi(Iu),Fi(zr),Fi(oL))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();class cC{constructor(t,e,i,r){this.eventManager=t,this.doc=e,this.ngZone=i,this.platformIsServer=r,this.data=Object.create(null),this.throwOnSyntheticProps=!0,this.destroyNode=null}destroy(){}createElement(t,e){return e?this.doc.createElementNS(lC[e]||e,t):this.doc.createElement(t)}createComment(t){return this.doc.createComment(t)}createText(t){return this.doc.createTextNode(t)}appendChild(t,e){(Mz(t)?t.content:t).appendChild(e)}insertBefore(t,e,i){t&&(Mz(t)?t.content:t).insertBefore(e,i)}removeChild(t,e){t&&t.removeChild(e)}selectRootElement(t,e){let i="string"==typeof t?this.doc.querySelector(t):t;if(!i)throw new F(-5104,!1);return e||(i.textContent=""),i}parentNode(t){return t.parentNode}nextSibling(t){return t.nextSibling}setAttribute(t,e,i,r){if(r){e=r+":"+e;const s=lC[r];s?t.setAttributeNS(s,e,i):t.setAttribute(e,i)}else t.setAttribute(e,i)}removeAttribute(t,e,i){if(i){const r=lC[i];r?t.removeAttributeNS(r,e):t.removeAttribute(`${i}:${e}`)}else t.removeAttribute(e)}addClass(t,e){t.classList.add(e)}removeClass(t,e){t.classList.remove(e)}setStyle(t,e,i,r){r&(Kh.DashCase|Kh.Important)?t.style.setProperty(e,i,r&Kh.Important?"important":""):t.style[e]=i}removeStyle(t,e,i){i&Kh.DashCase?t.style.removeProperty(e):t.style[e]=""}setProperty(t,e,i){null!=t&&(t[e]=i)}setValue(t,e){t.nodeValue=e}listen(t,e,i){if("string"==typeof t&&!(t=jw().getGlobalEventTarget(this.doc,t)))throw new Error(`Unsupported event target ${t} for event ${e}`);return this.eventManager.addEventListener(t,e,this.decoratePreventDefault(i))}decoratePreventDefault(t){return e=>{if("__ngUnwrap__"===e)return t;!1===(this.platformIsServer?this.ngZone.runGuarded(()=>t(e)):t(e))&&e.preventDefault()}}}function Mz(n){return"TEMPLATE"===n.tagName&&void 0!==n.content}class Yq extends cC{constructor(t,e,i,r,s,o,a,l){super(t,s,o,l),this.sharedStylesHost=e,this.hostEl=i,this.shadowRoot=i.attachShadow({mode:"open"}),this.sharedStylesHost.addHost(this.shadowRoot);const h=Iz(r.id,r.styles);for(const c of h){const d=document.createElement("style");a&&d.setAttribute("nonce",a),d.textContent=c,this.shadowRoot.appendChild(d)}}nodeOrShadowRoot(t){return t===this.hostEl?this.shadowRoot:t}appendChild(t,e){return super.appendChild(this.nodeOrShadowRoot(t),e)}insertBefore(t,e,i){return super.insertBefore(this.nodeOrShadowRoot(t),e,i)}removeChild(t,e){return super.removeChild(this.nodeOrShadowRoot(t),e)}parentNode(t){return this.nodeOrShadowRoot(super.parentNode(this.nodeOrShadowRoot(t)))}destroy(){this.sharedStylesHost.removeHost(this.shadowRoot)}}class dC extends cC{constructor(t,e,i,r,s,o,a,l){super(t,s,o,a),this.sharedStylesHost=e,this.removeStylesOnCompDestroy=r,this.styles=l?Iz(l,i.styles):i.styles}applyStyles(){this.sharedStylesHost.addStyles(this.styles)}destroy(){this.removeStylesOnCompDestroy&&this.sharedStylesHost.removeStyles(this.styles)}}class wz extends dC{constructor(t,e,i,r,s,o,a,l){const h=r+"-"+i.id;super(t,e,i,s,o,a,l,h),this.contentAttr=function jq(n){return"_ngcontent-%COMP%".replace(hC,n)}(h),this.hostAttr=function Vq(n){return"_nghost-%COMP%".replace(hC,n)}(h)}applyToHost(t){this.applyStyles(),this.setAttribute(t,this.hostAttr,"")}createElement(t,e){const i=super.createElement(t,e);return super.setAttribute(i,this.contentAttr,""),i}}let Qq=(()=>{class n extends mz{constructor(e){super(e)}supports(e){return!0}addEventListener(e,i,r){return e.addEventListener(i,r,!1),()=>this.removeEventListener(e,i,r)}removeEventListener(e,i,r){return e.removeEventListener(i,r)}static{this.\u0275fac=function(i){return new(i||n)(Fi(ad))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();const Cz=["alt","control","meta","shift"],Gq={"\b":"Backspace","\t":"Tab","\x7f":"Delete","\x1b":"Escape",Del:"Delete",Esc:"Escape",Left:"ArrowLeft",Right:"ArrowRight",Up:"ArrowUp",Down:"ArrowDown",Menu:"ContextMenu",Scroll:"ScrollLock",Win:"OS"},Xq={alt:n=>n.altKey,control:n=>n.ctrlKey,meta:n=>n.metaKey,shift:n=>n.shiftKey};let qq=(()=>{class n extends mz{constructor(e){super(e)}supports(e){return null!=n.parseEventName(e)}addEventListener(e,i,r){const s=n.parseEventName(i),o=n.eventCallback(s.fullKey,r,this.manager.getZone());return this.manager.getZone().runOutsideAngular(()=>jw().onAndCancel(e,s.domEventName,o))}static parseEventName(e){const i=e.toLowerCase().split("."),r=i.shift();if(0===i.length||"keydown"!==r&&"keyup"!==r)return null;const s=n._normalizeKey(i.pop());let o="",a=i.indexOf("code");if(a>-1&&(i.splice(a,1),o="code."),Cz.forEach(h=>{const c=i.indexOf(h);c>-1&&(i.splice(c,1),o+=h+".")}),o+=s,0!=i.length||0===s.length)return null;const l={};return l.domEventName=r,l.fullKey=o,l}static matchEventFullKeyCode(e,i){let r=Gq[e.key]||e.key,s="";return i.indexOf("code.")>-1&&(r=e.code,s="code."),!(null==r||!r)&&(r=r.toLowerCase()," "===r?r="space":"."===r&&(r="dot"),Cz.forEach(o=>{o!==r&&(0,Xq[o])(e)&&(s+=o+".")}),s+=r,s===i)}static eventCallback(e,i,r){return s=>{n.matchEventFullKeyCode(s,e)&&r.runGuarded(()=>i(s))}}static _normalizeKey(e){return"esc"===e?"escape":e}static{this.\u0275fac=function(i){return new(i||n)(Fi(ad))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();function Ez(n){return{appProviders:[...i$,...n?.providers??[]],platformProviders:e$}}const e$=[{provide:Iu,useValue:"browser"},{provide:sL,useValue:function Zq(){sC.makeCurrent()},multi:!0},{provide:ad,useFactory:function Kq(){return function Aj(n){A1=n}(document),document},deps:[]}],i$=[{provide:w1,useValue:"root"},{provide:eh,useFactory:function Jq(){return new eh},deps:[]},{provide:oC,useClass:Qq,multi:!0,deps:[ad,zr,Iu]},{provide:oC,useClass:qq,multi:!0,deps:[ad]},bz,yz,vz,{provide:sN,useExisting:bz},{provide:class cq{},useClass:Hq,deps:[]},[]];var o$=0,uC=!1;function M0(n,t){var e=t;return e.unshift(void 0),new(Function.prototype.bind.apply(n,e))}function Y(n,t){for(var e=t,i=n.replace(/\[/g,".").replace(/\]/g,"").split("."),r=0;r"u"}function wi(n){return n+"_"+o$++}function C0(n,t){return n===t||!(n===document||!n)&&C0(n.parentNode,t)}function Tg(n){try{throw new Error(n)}catch(t){throw new Error(t.message+"\n"+t.stack)}}function Re(n){var t=n+"";return t.match(/auto|cm|mm|in|px|pt|pc|%|em|ex|ch|rem|vw|vh|vmin|vmax/)?t:t+"px"}function ce(){return uC}var Ag,n,t,d$={latn:{_digits:"0123456789",_type:"numeric"}},Lz={decimal:".",group:",",percentSign:"%",plusSign:"+",minusSign:"-",infinity:"\u221e",nan:"NaN",exponential:"E"},Nz=[0,1,2,3,4,5,6,7,8,9],Rr=function(){function n(){}return n.getMainObject=function(t,e){return Y(ce()?e:"main."+e,t)},n.getNumberingSystem=function(t){return Y("supplemental.numberingSystems",t)||this.numberingSystems},n.reverseObject=function(t,e){for(var r={},s=0,o=e||Object.keys(t);s13&&(f+=1,o-=12),o-=1,a=f-4716;var y=u-24e5,S=10631/30,b=u-1948084,M=Math.floor(b/10631);b-=10631*M;var w=Math.floor((b-.1335)/S),C=30*M+w;b-=Math.floor(w*S+.1335);var D=Math.floor((b+28.5001)/29.5);13===D&&(D=12);for(var A=b-Math.floor(29.5001*D-29),x=0;xy);x++);var R=x+16260,L=Math.floor((R-1)/12),O=L+1,N=R-12*L,T=y-t[x-1]+1;return(T+"").length>2&&(T=A,N=D,O=C),{year:O,month:N,date:T}},n.toGregorian=function i(r,s,o){var g=Math.floor(o+t[12*(r-1)+1+(s-1)-16260-1]-1+24e5+.5),v=Math.floor((g-1867216.25)/36524.25),y=1524+(v=g+1+v-Math.floor(v/4)),S=Math.floor((y-122.1)/365.25),b=Math.floor(365.25*S),M=Math.floor((y-b)/30.6001),w=y-b-Math.floor(30.6001*M),C=M-(M>13.5?13:1),D=S-(C>2.5?4716:4715);return D<=0&&C--,new Date(D+"/"+C+"/"+w)};var ut,f$=/\/MMMMM|MMMM|MMM|a|LLLL|LLL|EEEEE|EEEE|E|K|cccc|ccc|WW|W|G+|z+/gi,Oz="stand-alone",g$=["sun","mon","tue","wed","thu","fri","sat"],kz={m:"getMinutes",h:"getHours",H:"getHours",s:"getSeconds",d:"getDate",f:"getMilliseconds"},Pz=function(){function n(){}return n.dateFormat=function(t,e,i){var r=this,s=ut.getDependables(i,t,e.calendar),o=Y("parserObject.numbers",s),a=s.dateObject,l={isIslamic:ut.islamicRegex.test(e.calendar)};ce()&&e.isServerRendered&&(e=ut.compareBlazorDateFormats(e,t));var h=e.format||ut.getResultantPattern(e.skeleton,s.dateObject,e.type,!1,ce()?t:"");if(l.dateSeperator=ce()?Y("dateSeperator",a):ut.getDateSeparator(s.dateObject),st(h))Tg("Format options or type given must be invalid");else{h=ut.ConvertDateToWeekFormat(h),ce()&&(h=h.replace(/tt/,"a")),l.pattern=h,l.numMapper=ce()?ze({},o):Rr.getNumberMapper(s.parserObject,Rr.getNumberingSystem(i));for(var d=0,u=h.match(f$)||[];d2?r+=e.month[""+u]:f=!0;break;case"E":case"c":r+=e.weekday[""+g$[t.getDay()]];break;case"H":case"h":case"m":case"s":case"d":case"f":if(f=!0,"d"===d)u=o.date;else if("f"===d){f=!1,g=!0;var y=(p=(p=t[""+kz[""+d]]().toString()).substring(0,c)).length;if(c!==y){if(c>3)continue;for(var S=0;S0?1:0],o=Math.abs(t);return s.replace(/HH?|mm/g,function(a){var l=a.length,h=-1!==a.indexOf("H");return i.checkTwodigitNumber(Math.floor(h?o/60:o%60),l)})},n}(),zz={ms:"minimumSignificantDigits",ls:"maximumSignificantDigits",mf:"minimumFractionDigits",lf:"maximumFractionDigits"},rp=["infinity","nan","group","decimal","exponential"],Rz=function(){function n(){}return n.numberFormatter=function(t,e,i){var l,r=this,s=ze({},e),o={},a={},h=ut.getDependables(i,t,"",!0),c=h.numericObject;a.numberMapper=ce()?ze({},c):Rr.getNumberMapper(h.parserObject,Rr.getNumberingSystem(i),!0),a.currencySymbol=ce()?Y("currencySymbol",c):ut.getCurrencySymbol(h.numericObject,s.currency||Og,e.altSymbol,e.ignoreCurrency),a.percentSymbol=ce()?Y("numberSymbols.percentSign",c):a.numberMapper.numberSymbols.percentSign,a.minusSymbol=ce()?Y("numberSymbols.minusSign",c):a.numberMapper.numberSymbols.minusSign;var d=a.numberMapper.numberSymbols;if(e.format&&!ut.formatRegex.test(e.format))o=ut.customFormat(e.format,a,h.numericObject),!st(s.useGrouping)&&s.useGrouping&&(s.useGrouping=o.pData.useGrouping);else{if(ze(s,ut.getProperNumericSkeleton(e.format||"N")),s.isCurrency="currency"===s.type,s.isPercent="percent"===s.type,ce()||(l=ut.getSymbolPattern(s.type,a.numberMapper.numberSystem,h.numericObject,s.isAccount)),s.groupOne=this.checkValueRange(s.maximumSignificantDigits,s.minimumSignificantDigits,!0),this.checkValueRange(s.maximumFractionDigits,s.minimumFractionDigits,!1,!0),st(s.fractionDigits)||(s.minimumFractionDigits=s.maximumFractionDigits=s.fractionDigits),st(s.useGrouping)&&(s.useGrouping=!0),s.isCurrency&&!ce()&&(l=l.replace(/\u00A4/g,ut.defaultCurrency)),ce())o.nData=ze({},{},Y(s.type+"nData",c)),o.pData=ze({},{},Y(s.type+"pData",c)),"currency"===s.type&&e.currency&&ut.replaceBlazorCurrency([o.pData,o.nData],a.currencySymbol,e.currency);else{var u=l.split(";");o.nData=ut.getFormatData(u[1]||"-"+u[0],!0,a.currencySymbol),o.pData=ut.getFormatData(u[0],!1,a.currencySymbol),s.useGrouping&&(s.groupSeparator=d[rp[2]],s.groupData=this.getGroupingDetails(u[0]))}if(st(s.minimumFractionDigits)&&(s.minimumFractionDigits=o.nData.minimumFraction),st(s.maximumFractionDigits)){var f=o.nData.maximumFraction;s.maximumFractionDigits=st(f)&&s.isPercent?0:f}var g=s.minimumFractionDigits,v=s.maximumFractionDigits;!st(g)&&!st(v)&&g>v&&(s.maximumFractionDigits=g)}return ze(o.nData,s),ze(o.pData,s),function(y){return isNaN(y)?d[rp[1]]:isFinite(y)?r.intNumberFormatter(y,o,a,e):d[rp[0]]}},n.getGroupingDetails=function(t){var e={},i=t.match(ut.negativeDataRegex);if(i&&i[4]){var r=i[4],s=r.lastIndexOf(",");if(-1!==s){var o=r.split(".")[0];e.primary=o.length-s-1;var a=r.lastIndexOf(",",s-1);-1!==a&&(e.secondary=s-1-a)}}return e},n.checkValueRange=function(t,e,i,r){var s=r?"f":"s",o=0,a=zz["l"+s],l=zz["m"+s];if(st(t)||(this.checkRange(t,a,r),o++),st(e)||(this.checkRange(e,l,r),o++),2===o){if(!(tr[1])&&Tg(e+"value must be within the range"+r[0]+"to"+r[1])},n.intNumberFormatter=function(t,e,i,r){var s;if(!st(e.nData.type)){t<0?(t*=-1,s=e.nData):s=0===t&&e.zeroData||e.pData;var o="";if(s.isPercent&&(t*=100),s.groupOne)o=this.processSignificantDigits(t,s.minimumSignificantDigits,s.maximumSignificantDigits);else if(o=this.processFraction(t,s.minimumFractionDigits,s.maximumFractionDigits,r),s.minimumIntegerDigits&&(o=this.processMinimumIntegers(o,s.minimumIntegerDigits)),i.isCustomFormat&&s.minimumFractionDigits=0&&"0"===l[parseInt(c.toString(),10)]&&c>=s.minimumFractionDigits;c--)l=l.slice(0,c);o=a[0]+"."+l}return"scientific"===s.type&&(o=(o=t.toExponential(s.maximumFractionDigits)).replace("e",i.numberMapper.numberSymbols[rp[4]])),o=o.replace(".",i.numberMapper.numberSymbols[rp[3]]),o="#,###,,;(#,###,,)"===s.format?this.customPivotFormat(parseInt(o,10)):o,s.useGrouping&&(o=this.groupNumbers(o,s.groupData.primary,s.groupSeparator||",",i.numberMapper.numberSymbols[rp[3]]||".",s.groupData.secondary)),o=Rr.convertValueParts(o,ut.latnParseRegex,i.numberMapper.mapper),"N/A"===s.nlead?s.nlead:"0"===o&&r&&"0"===r.format?o+s.nend:s.nlead+o+s.nend}},n.processSignificantDigits=function(t,e,i){var r=t+"";return r.lengthe;)c=l.slice(h-e,h)+(c.length?i+c:""),h-=e,o&&(e=s,o=!1);return a[0]=l.slice(0,h)+(c.length?i:"")+c,a.join(r)},n.processFraction=function(t,e,i,r){var s=(t+"").split(".")[1],o=s?s.length:0;if(e&&oi||0===i))return t.toFixed(i);var h=t+"";return"0"===h[0]&&r&&"###.00"===r.format&&(h=h.slice(1)),h},n.processMinimumIntegers=function(t,e){var i=t.split("."),r=i[0],s=r.length;if(s=5e5){var r=(t/=1e6).toString().split(".")[1];return r&&+r.substring(0,1)>=5?Math.ceil(t).toString():Math.floor(t).toString()}return""},n}(),Lg=(new RegExp("^([^0-9]*)(([0-9,]*[0-9]+)(.[0-9]+)?)([Ee][+-]?[0-9]+)?([^0-9]*)$"),function(){function n(t){this.ranArray=[],this.boundedEvents={},!m(t)&&(this.context=t)}return n.prototype.on=function(t,e,i,r){if(!m(e)){var s=i||this.context;if(this.notExist(t))return void(this.boundedEvents[""+t]=[{handler:e,context:s,id:r}]);m(r)?this.isHandlerPresent(this.boundedEvents[""+t],e)||this.boundedEvents[""+t].push({handler:e,context:s}):-1===this.ranArray.indexOf(r)&&(this.ranArray.push(r),this.boundedEvents[""+t].push({handler:e,context:s,id:r}))}},n.prototype.off=function(t,e,i){if(!this.notExist(t)){var r=Y(t,this.boundedEvents);if(e){for(var s=0;s1&&(_.fractionDigits=parseInt(P[2],10)),_}function f(T,P,_,B){var j=B?{}:{nlead:"",nend:""},Q=T.match(n.customRegex);if(Q){B||(j.nlead=g(Q[1],_),j.nend=g(Q[10],_),j.groupPattern=Q[4]);var oe=Q[7];if(oe&&P){var ue=oe.match(t);j.minimumFraction=m(ue)?0:ue.length,j.maximumFraction=oe.length-1}}return j}function g(T,P){return T?(T=T.replace(n.defaultCurrency,P),""===P?T.trim():T):""}function v(T,P,_,B){return B?"$":Y("currencies."+P+(_?"."+_:".symbol"),T)||Y("currencies."+P+".symbol-alt-narrow",T)||"$"}function S(T,P,_){var B={type:"decimal",minimumFractionDigits:0,maximumFractionDigits:0},j=T.match(n.customRegex);if(m(j)||""===j[5]&&"N/A"!==T)return B.type=void 0,B;B.nlead=j[1],B.nend=j[10];var Q=j[6],oe=!!Q.match(/ $/g),ue=-1!==Q.replace(/ $/g,"").indexOf(" ");B.useGrouping=-1!==Q.indexOf(",")||ue,Q=Q.replace(/,/g,"");var pe=j[7];if(-1!==Q.indexOf("0")&&(B.minimumIntegerDigits=Q.length-Q.indexOf("0")),m(pe)||(B.minimumFractionDigits=pe.lastIndexOf("0"),B.maximumFractionDigits=pe.lastIndexOf("#"),-1===B.minimumFractionDigits&&(B.minimumFractionDigits=0),(-1===B.maximumFractionDigits||B.maximumFractionDigitsQ.lastIndexOf("'"))){B[""+a[parseInt(j.toString(),10)]]=Q.substr(0,oe)+_+Q.substr(oe+1),B[""+a[""+P]]=!0,B.type=B.isCurrency?"currency":"percent";break}}return B}function C(T,P){if(-1!==T.indexOf(",")){var _=T.split(",");T=_[0]+Y("numberMapper.numberSymbols.group",P)+_[1].replace(".",Y("numberMapper.numberSymbols.decimal",P))}else T=T.replace(".",Y("numberMapper.numberSymbols.decimal",P));return T}function A(T,P,_){T+=".";for(var B=0;B0;Q-=3)T=","+_[Q-2]+_[Q-1]+_[parseInt(Q.toString(),10)]+T;return T=T.slice(1),P[1]?T+"."+P[1]:T}n.dateParseRegex=/([a-z])\1*|'([^']|'')+'|''|./gi,n.basicPatterns=["short","medium","long","full"],n.defaultObject={dates:{calendars:{gregorian:{months:{"stand-alone":{abbreviated:{1:"Jan",2:"Feb",3:"Mar",4:"Apr",5:"May",6:"Jun",7:"Jul",8:"Aug",9:"Sep",10:"Oct",11:"Nov",12:"Dec"},narrow:{1:"J",2:"F",3:"M",4:"A",5:"M",6:"J",7:"J",8:"A",9:"S",10:"O",11:"N",12:"D"},wide:{1:"January",2:"February",3:"March",4:"April",5:"May",6:"June",7:"July",8:"August",9:"September",10:"October",11:"November",12:"December"}}},days:{"stand-alone":{abbreviated:{sun:"Sun",mon:"Mon",tue:"Tue",wed:"Wed",thu:"Thu",fri:"Fri",sat:"Sat"},narrow:{sun:"S",mon:"M",tue:"T",wed:"W",thu:"T",fri:"F",sat:"S"},short:{sun:"Su",mon:"Mo",tue:"Tu",wed:"We",thu:"Th",fri:"Fr",sat:"Sa"},wide:{sun:"Sunday",mon:"Monday",tue:"Tuesday",wed:"Wednesday",thu:"Thursday",fri:"Friday",sat:"Saturday"}}},dayPeriods:{format:{wide:{am:"AM",pm:"PM"}}},eras:{eraNames:{0:"Before Christ","0-alt-variant":"Before Common Era",1:"Anno Domini","1-alt-variant":"Common Era"},eraAbbr:{0:"BC","0-alt-variant":"BCE",1:"AD","1-alt-variant":"CE"},eraNarrow:{0:"B","0-alt-variant":"BCE",1:"A","1-alt-variant":"CE"}},dateFormats:{full:"EEEE, MMMM d, y",long:"MMMM d, y",medium:"MMM d, y",short:"M/d/yy"},timeFormats:{full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},dateTimeFormats:{full:"{1} 'at' {0}",long:"{1} 'at' {0}",medium:"{1}, {0}",short:"{1}, {0}",availableFormats:{d:"d",E:"ccc",Ed:"d E",Ehm:"E h:mm a",EHm:"E HH:mm",Ehms:"E h:mm:ss a",EHms:"E HH:mm:ss",Gy:"y G",GyMMM:"MMM y G",GyMMMd:"MMM d, y G",GyMMMEd:"E, MMM d, y G",h:"h a",H:"HH",hm:"h:mm a",Hm:"HH:mm",hms:"h:mm:ss a",Hms:"HH:mm:ss",hmsv:"h:mm:ss a v",Hmsv:"HH:mm:ss v",hmv:"h:mm a v",Hmv:"HH:mm v",M:"L",Md:"M/d",MEd:"E, M/d",MMM:"LLL",MMMd:"MMM d",MMMEd:"E, MMM d",MMMMd:"MMMM d",ms:"mm:ss",y:"y",yM:"M/y",yMd:"M/d/y",yMEd:"E, M/d/y",yMMM:"MMM y",yMMMd:"MMM d, y",yMMMEd:"E, MMM d, y",yMMMM:"MMMM y"}}},islamic:{months:{"stand-alone":{abbreviated:{1:"Muh.",2:"Saf.",3:"Rab. I",4:"Rab. II",5:"Jum. I",6:"Jum. II",7:"Raj.",8:"Sha.",9:"Ram.",10:"Shaw.",11:"Dhu\u02bbl-Q.",12:"Dhu\u02bbl-H."},narrow:{1:"1",2:"2",3:"3",4:"4",5:"5",6:"6",7:"7",8:"8",9:"9",10:"10",11:"11",12:"12"},wide:{1:"Muharram",2:"Safar",3:"Rabi\u02bb I",4:"Rabi\u02bb II",5:"Jumada I",6:"Jumada II",7:"Rajab",8:"Sha\u02bbban",9:"Ramadan",10:"Shawwal",11:"Dhu\u02bbl-Qi\u02bbdah",12:"Dhu\u02bbl-Hijjah"}}},days:{"stand-alone":{abbreviated:{sun:"Sun",mon:"Mon",tue:"Tue",wed:"Wed",thu:"Thu",fri:"Fri",sat:"Sat"},narrow:{sun:"S",mon:"M",tue:"T",wed:"W",thu:"T",fri:"F",sat:"S"},short:{sun:"Su",mon:"Mo",tue:"Tu",wed:"We",thu:"Th",fri:"Fr",sat:"Sa"},wide:{sun:"Sunday",mon:"Monday",tue:"Tuesday",wed:"Wednesday",thu:"Thursday",fri:"Friday",sat:"Saturday"}}},dayPeriods:{format:{wide:{am:"AM",pm:"PM"}}},eras:{eraNames:{0:"AH"},eraAbbr:{0:"AH"},eraNarrow:{0:"AH"}},dateFormats:{full:"EEEE, MMMM d, y G",long:"MMMM d, y G",medium:"MMM d, y G",short:"M/d/y GGGGG"},timeFormats:{full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},dateTimeFormats:{full:"{1} 'at' {0}",long:"{1} 'at' {0}",medium:"{1}, {0}",short:"{1}, {0}",availableFormats:{d:"d",E:"ccc",Ed:"d E",Ehm:"E h:mm a",EHm:"E HH:mm",Ehms:"E h:mm:ss a",EHms:"E HH:mm:ss",Gy:"y G",GyMMM:"MMM y G",GyMMMd:"MMM d, y G",GyMMMEd:"E, MMM d, y G",h:"h a",H:"HH",hm:"h:mm a",Hm:"HH:mm",hms:"h:mm:ss a",Hms:"HH:mm:ss",M:"L",Md:"M/d",MEd:"E, M/d",MMM:"LLL",MMMd:"MMM d",MMMEd:"E, MMM d",MMMMd:"MMMM d",ms:"mm:ss",y:"y G",yyyy:"y G",yyyyM:"M/y GGGGG",yyyyMd:"M/d/y GGGGG",yyyyMEd:"E, M/d/y GGGGG",yyyyMMM:"MMM y G",yyyyMMMd:"MMM d, y G",yyyyMMMEd:"E, MMM d, y G",yyyyMMMM:"MMMM y G",yyyyQQQ:"QQQ y G",yyyyQQQQ:"QQQQ y G"}}}},timeZoneNames:{hourFormat:"+HH:mm;-HH:mm",gmtFormat:"GMT{0}",gmtZeroFormat:"GMT"}},numbers:{currencies:{USD:{displayName:"US Dollar",symbol:"$","symbol-alt-narrow":"$"},EUR:{displayName:"Euro",symbol:"\u20ac","symbol-alt-narrow":"\u20ac"},GBP:{displayName:"British Pound","symbol-alt-narrow":"\xa3"}},defaultNumberingSystem:"latn",minimumGroupingDigits:"1","symbols-numberSystem-latn":{decimal:".",group:",",list:";",percentSign:"%",plusSign:"+",minusSign:"-",exponential:"E",superscriptingExponent:"\xd7",perMille:"\u2030",infinity:"\u221e",nan:"NaN",timeSeparator:":"},"decimalFormats-numberSystem-latn":{standard:"#,##0.###"},"percentFormats-numberSystem-latn":{standard:"#,##0%"},"currencyFormats-numberSystem-latn":{standard:"\xa4#,##0.00",accounting:"\xa4#,##0.00;(\xa4#,##0.00)"},"scientificFormats-numberSystem-latn":{standard:"#E0"}}},n.blazorDefaultObject={numbers:{mapper:{0:"0",1:"1",2:"2",3:"3",4:"4",5:"5",6:"6",7:"7",8:"8",9:"9"},mapperDigits:"0123456789",numberSymbols:{decimal:".",group:",",plusSign:"+",minusSign:"-",percentSign:"%",nan:"NaN",timeSeparator:":",infinity:"\u221e"},timeSeparator:":",currencySymbol:"$",currencypData:{nlead:"$",nend:"",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},percentpData:{nlead:"",nend:"%",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},percentnData:{nlead:"-",nend:"%",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},currencynData:{nlead:"($",nend:")",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},decimalnData:{nlead:"-",nend:"",groupData:{primary:3},maximumFraction:2,minimumFraction:2},decimalpData:{nlead:"",nend:"",groupData:{primary:3},maximumFraction:2,minimumFraction:2}},dates:{dayPeriods:{am:"AM",pm:"PM"},dateSeperator:"/",days:{abbreviated:{sun:"Sun",mon:"Mon",tue:"Tue",wed:"Wed",thu:"Thu",fri:"Fri",sat:"Sat"},short:{sun:"Su",mon:"Mo",tue:"Tu",wed:"We",thu:"Th",fri:"Fr",sat:"Sa"},wide:{sun:"Sunday",mon:"Monday",tue:"Tuesday",wed:"Wednesday",thu:"Thursday",fri:"Friday",sat:"Saturday"}},months:{abbreviated:{1:"Jan",2:"Feb",3:"Mar",4:"Apr",5:"May",6:"Jun",7:"Jul",8:"Aug",9:"Sep",10:"Oct",11:"Nov",12:"Dec"},wide:{1:"January",2:"February",3:"March",4:"April",5:"May",6:"June",7:"July",8:"August",9:"September",10:"October",11:"November",12:"December"}},eras:{1:"AD"}}},n.monthIndex={3:"abbreviated",4:"wide",5:"narrow",1:"abbreviated"},n.month="months",n.days="days",n.patternMatcher={C:"currency",P:"percent",N:"decimal",A:"currency",E:"scientific"},n.getResultantPattern=l,n.getDependables=h,n.getSymbolPattern=c,n.ConvertDateToWeekFormat=d,n.compareBlazorDateFormats=u,n.getProperNumericSkeleton=p,n.getFormatData=f,n.changeCurrencySymbol=g,n.getCurrencySymbol=v,n.customFormat=function y(T,P,_){for(var B={},j=T.split(";"),Q=["pData","nData","zeroData"],oe=0;oe1,pe.nData=ce()?Y(De.type+"nData",oe):f(ot[1]||"-"+ot[0],!0,Ie),pe.pData=ce()?Y(De.type+"pData",oe):f(ot[0],!1,Ie),!Me[2]&&!P.minimumFractionDigits&&!P.maximumFractionDigits&&(ue=f(Ve.split(";")[0],!0,"",!0).minimumFraction)}if(n.formatRegex.test(P.format)||!P.format){if(ze(Q,p(P.format||"N")),Q.custom=!1,$e="###0",(Q.fractionDigits||P.minimumFractionDigits||P.maximumFractionDigits||ue)&&(Q.fractionDigits&&(P.minimumFractionDigits=P.maximumFractionDigits=Q.fractionDigits),$e=A($e,ue||Q.fractionDigits||P.minimumFractionDigits||0,P.maximumFractionDigits||0)),P.minimumIntegerDigits&&($e=x($e,P.minimumIntegerDigits)),P.useGrouping&&($e=R($e)),"currency"===Q.type||Q.type&&ce()){ce()&&"currency"!==Q.type&&(pe.pData=Y(Q.type+"pData",oe),pe.nData=Y(Q.type+"nData",oe));var hr=$e;$e=pe.pData.nlead+hr+pe.pData.nend,(pe.hasNegativePattern||ce())&&($e+=";"+pe.nData.nlead+hr+pe.nData.nend)}"percent"===Q.type&&!ce()&&($e+=" %")}else $e=P.format.replace(/'/g,'"');return Object.keys(xe).length>0&&($e=B?$e:C($e,xe)),$e},n.fractionDigitsPattern=A,n.minimumIntegerPattern=x,n.groupingPattern=R,n.getWeekData=function L(T,P){var _="sun",B=Y("supplemental.weekData.firstDay",P),j=T;return/en-/.test(j)&&(j=j.slice(3)),j=j.slice(0,2).toUpperCase()+j.substr(2),B&&(_=B[""+j]||B[j.slice(0,2)]||"sun"),o[""+_]},n.replaceBlazorCurrency=function O(T,P,_){var B=function p$(n){return Y(n||"",u$)}(_);if(P!==B)for(var j=0,Q=T;j=0?_:_+7;var j=Math.floor((T.getTime()-P.getTime()-6e4*(T.getTimezoneOffset()-P.getTimezoneOffset()))/864e5)+1;if(_<4){if((B=Math.floor((j+_-1)/7)+1)>52){var oe=new Date(T.getFullYear()+1,0,1).getDay();B=(oe=oe>=0?oe:oe+7)<4?1:53}}else B=Math.floor((j+_-1)/7);return B}}(ut||(ut={}));var np=function(){function n(t,e,i){this.type="GET",this.emitError=!0,"string"==typeof t?(this.url=t,this.type=m(e)?this.type:e.toUpperCase(),this.contentType=i):Aa(t)&&Object.keys(t).length>0&&Nn(this,t),this.contentType=m(this.contentType)?"application/json; charset=utf-8":this.contentType}return n.prototype.send=function(t){var e=this,i={"application/json":"json","multipart/form-data":"formData","application/octet-stream":"blob","application/x-www-form-urlencoded":"formData"};try{m(this.fetchRequest)&&"GET"===this.type?this.fetchRequest=new Request(this.url,{method:this.type}):m(this.fetchRequest)&&(this.data=m(t)?this.data:t,this.fetchRequest=new Request(this.url,{method:this.type,headers:{"Content-Type":this.contentType},body:this.data}));var r={cancel:!1,fetchRequest:this.fetchRequest};return this.triggerEvent(this.beforeSend,r),r.cancel?null:(this.fetchResponse=fetch(this.fetchRequest),this.fetchResponse.then(function(s){if(e.triggerEvent(e.onLoad,s),!s.ok)throw s;for(var o="text",a=0,l=Object.keys(i);a-1},n.getValue=function(t,e){var i=typeof window<"u"?window.browserDetails:{};return typeof navigator<"u"&&"MacIntel"===navigator.platform&&navigator.maxTouchPoints>1&&!0===n.isTouch&&!gC.CHROME.test(navigator.userAgent)&&(i.isIos=!0,i.isDevice=!0,i.isTouch=!0,i.isPointer=!0),typeof window<"u"&&window.Capacitor&&"ios"===window.Capacitor.getPlatform()&&(i.isPointer=!1),typeof i[""+t]>"u"?i[""+t]=e.test(n.userAgent):i[""+t]},Object.defineProperty(n,"userAgent",{get:function(){return n.uA},set:function(t){n.uA=t,window.browserDetails={}},enumerable:!0,configurable:!0}),Object.defineProperty(n,"info",{get:function(){return st(window.browserDetails.info)?window.browserDetails.info=n.extractBrowserDetail():window.browserDetails.info},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isIE",{get:function(){return n.getValue("isIE",A$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isTouch",{get:function(){return st(window.browserDetails.isTouch)?window.browserDetails.isTouch="ontouchstart"in window.navigator||window&&window.navigator&&window.navigator.maxTouchPoints>0||"ontouchstart"in window:window.browserDetails.isTouch},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isPointer",{get:function(){return st(window.browserDetails.isPointer)?window.browserDetails.isPointer="pointerEnabled"in window.navigator:window.browserDetails.isPointer},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isMSPointer",{get:function(){return st(window.browserDetails.isMSPointer)?window.browserDetails.isMSPointer="msPointerEnabled"in window.navigator:window.browserDetails.isMSPointer},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isDevice",{get:function(){return n.getValue("isDevice",T$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isIos",{get:function(){return n.getValue("isIos",N$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isIos7",{get:function(){return n.getValue("isIos7",O$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isAndroid",{get:function(){return n.getValue("isAndroid",k$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isWebView",{get:function(){return st(window.browserDetails.isWebView)&&(window.browserDetails.isWebView=!(st(window.cordova)&&st(window.PhoneGap)&&st(window.phonegap)&&"object"!==window.forge)),window.browserDetails.isWebView},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isWindows",{get:function(){return n.getValue("isWindows",P$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"touchStartEvent",{get:function(){return st(window.browserDetails.touchStartEvent)?window.browserDetails.touchStartEvent=n.getTouchStartEvent():window.browserDetails.touchStartEvent},enumerable:!0,configurable:!0}),Object.defineProperty(n,"touchMoveEvent",{get:function(){return st(window.browserDetails.touchMoveEvent)?window.browserDetails.touchMoveEvent=n.getTouchMoveEvent():window.browserDetails.touchMoveEvent},enumerable:!0,configurable:!0}),Object.defineProperty(n,"touchEndEvent",{get:function(){return st(window.browserDetails.touchEndEvent)?window.browserDetails.touchEndEvent=n.getTouchEndEvent():window.browserDetails.touchEndEvent},enumerable:!0,configurable:!0}),Object.defineProperty(n,"touchCancelEvent",{get:function(){return st(window.browserDetails.touchCancelEvent)?window.browserDetails.touchCancelEvent=n.getTouchCancelEvent():window.browserDetails.touchCancelEvent},enumerable:!0,configurable:!0}),n.uA=typeof navigator<"u"?navigator.userAgent:"",n}(),E=function(){function n(){}return n.addOrGetEventData=function(t){return"__eventList"in t?t.__eventList.events:(t.__eventList={},t.__eventList.events=[])},n.add=function(t,e,i,r,s){var a,o=n.addOrGetEventData(t);a=s?function l$(n,t){var e;return function(){for(var i=this,r=[],s=0;s"u"||(e.innerHTML=t.innerHTML?t.innerHTML:"",void 0!==t.className&&(e.className=t.className),void 0!==t.id&&(e.id=t.id),void 0!==t.styles&&e.setAttribute("style",t.styles),void 0!==t.attrs&&Fe(e,t.attrs)),e}function V(n,t){for(var e=Vz(t),i=RegExp,r=0,s=n;r0}function pl(n,t,e){for(var i=document.createDocumentFragment(),r=0,s=n;r0;)i.appendChild(n[0]);else for(var r=0,s=n;r-1&&!r[parseInt(s.toString(),10)].match(/\[.*\]/)){var o=r[parseInt(s.toString(),10)].split("#");if(o[1].match(/^\d/)||o[1].match(t)){var a=r[parseInt(s.toString(),10)].split(".");a[0]=a[0].replace(/#/,"[id='")+"']",r[parseInt(s.toString(),10)]=a.join(".")}}e[parseInt(i.toString(),10)]=r.join(" ")}return e.join(",")}return n}function J(n,t){var e=n;if("function"==typeof e.closest)return e.closest(t);for(;e&&1===e.nodeType;){if(vC(e,t))return e;e=e.parentNode}return null}function je(n,t){void 0!==t&&Object.keys(t).forEach(function(e){n.style[""+e]=t[""+e]})}function vC(n,t){var e=n.matches||n.msMatchesSelector||n.webkitMatchesSelector;return e?e.call(n,t):-1!==[].indexOf.call(document.querySelectorAll(t),n)}var H$=new RegExp("]"),ah=function(){function n(t,e){this.isRendered=!1,this.isComplexArraySetter=!1,this.isServerRendered=!1,this.allowServerDataBinding=!0,this.isProtectedOnChange=!0,this.properties={},this.changedProperties={},this.oldProperties={},this.bulkChanges={},this.refreshing=!1,this.ignoreCollectionWatch=!1,this.finalUpdate=function(){},this.childChangedProperties={},this.modelObserver=new Lg(this),st(e)||(this.element="string"==typeof e?document.querySelector(e):e,m(this.element)||(this.isProtectedOnChange=!1,this.addInstance())),st(t)||this.setProperties(t,!0),this.isDestroyed=!1}return n.prototype.setProperties=function(t,e){var i=this.isProtectedOnChange;this.isProtectedOnChange=!!e,Nn(this,t),!0!==e?(Nn(this.changedProperties,t),this.dataBind()):ce()&&this.isRendered&&this.serverDataBind(t),this.finalUpdate(),this.changedProperties={},this.oldProperties={},this.isProtectedOnChange=i},n.callChildDataBind=function(t,e){for(var r=0,s=Object.keys(t);r=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Hs=function(n){function t(i){var r=n.call(this,i,void 0)||this;return r.easing={ease:"cubic-bezier(0.250, 0.100, 0.250, 1.000)",linear:"cubic-bezier(0.250, 0.250, 0.750, 0.750)",easeIn:"cubic-bezier(0.420, 0.000, 1.000, 1.000)",easeOut:"cubic-bezier(0.000, 0.000, 0.580, 1.000)",easeInOut:"cubic-bezier(0.420, 0.000, 0.580, 1.000)",elasticInOut:"cubic-bezier(0.5,-0.58,0.38,1.81)",elasticIn:"cubic-bezier(0.17,0.67,0.59,1.81)",elasticOut:"cubic-bezier(0.7,-0.75,0.99,1.01)"},r}var e;return X$(t,n),e=t,t.prototype.animate=function(i,r){var s=this.getModel(r=r||{});if("string"==typeof i)for(var a=0,l=Array.prototype.slice.call(we(i,document));a0?r-1:0,i+=e=-1!==e?"-"+e:"-"+r}return this.controlParent!==this.parentObj&&(i=this.parentObj.getParentKey()+"."+this.propName+e),i},n}(),J$=["grid","pivotview","treegrid","spreadsheet","rangeNavigator","DocumentEditor","listbox","inplaceeditor","PdfViewer","richtexteditor","DashboardLayout","chart","stockChart","circulargauge","diagram","heatmap","lineargauge","maps","slider","smithchart","barcode","sparkline","treemap","bulletChart","kanban","daterangepicker","schedule","gantt","signature","query-builder","drop-down-tree","carousel","filemanager","uploader","accordion","tab","treeview"],tR=[115,121,110,99,102,117,115,105,111,110,46,105,115,76,105,99,86,97,108,105,100,97,116,101,100],iR=function(){function n(t){this.isValidated=!1,this.isLicensed=!0,this.version="27",this.platform=/JavaScript|ASPNET|ASPNETCORE|ASPNETMVC|FileFormats|essentialstudio/i,this.errors={noLicense:"This application was built using a trial version of Syncfusion Essential Studio. To remove the license validation message permanently, a valid license key must be included.",trailExpired:"This application was built using a trial version of Syncfusion Essential Studio. To remove the license validation message permanently, a valid license key must be included.",versionMismatched:"The included Syncfusion license key is invalid.",platformMismatched:"The included Syncfusion license key is invalid.",invalidKey:"The included Syncfusion license key is invalid."},this.manager=function(){var e=null;return{setKey:function i(s){e=s},getKey:function r(){return e}}}(),this.npxManager=function(){return{getKey:function i(){return"npxKeyReplace"}}}(),this.manager.setKey(t)}return n.prototype.validate=function(){if(!this.isValidated&&ip&&!Y(T0(tR),ip)&&!Y("Blazor",ip)){var i=void 0,r=void 0;if(this.manager&&this.manager.getKey()||this.npxManager&&"npxKeyReplace"!==this.npxManager.getKey()){var s=this.getInfoFromKey();if(s&&s.length)for(var o=0,a=s;o"+i+' Claim your FREE account\n
have a Syncfusion account? Sign In
\n
\n ';if(typeof document<"u"&&!m(document)){var t=mi("div",{innerHTML:n});document.body.appendChild(t)}}(),oR=!0),this.render(),this.mount?this.accessMount():this.trigger("created")}},t.prototype.renderComplete=function(e){ce()&&window.sfBlazor.renderComplete(this.element,e),this.isRendered=!0},t.prototype.dataBind=function(){this.injectModules(),n.prototype.dataBind.call(this)},t.prototype.on=function(e,i,r){if("string"==typeof e)this.localObserver.on(e,i,r);else for(var s=0,o=e;s=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},rZ={left:0,top:0,bottom:0,right:0},bC={isDragged:!1},nZ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return aR(t,n),gr([I(0)],t.prototype,"left",void 0),gr([I(0)],t.prototype,"top",void 0),t}(Ee),ap=function(n){function t(i,r){var s=n.call(this,r,i)||this;return s.dragLimit=e.getDefaultPosition(),s.borderWidth=e.getDefaultPosition(),s.padding=e.getDefaultPosition(),s.diffX=0,s.prevLeft=0,s.prevTop=0,s.dragProcessStarted=!1,s.eleTop=0,s.tapHoldTimer=0,s.externalInitialize=!1,s.diffY=0,s.parentScrollX=0,s.parentScrollY=0,s.droppables={},s.bind(),s}var e;return aR(t,n),e=t,t.prototype.bind=function(){this.toggleEvents(),X.isIE&&V([this.element],"e-block-touch"),this.droppables[this.scope]={}},t.getDefaultPosition=function(){return ze({},rZ)},t.prototype.toggleEvents=function(i){var r;st(this.handle)||(r=U(this.handle,this.element));var s=this.enableTapHold&&X.isDevice&&X.isTouch?this.mobileInitialize:this.initialize;i?E.remove(r||this.element,X.isSafari()?"touchstart":X.touchStartEvent,s):E.add(r||this.element,X.isSafari()?"touchstart":X.touchStartEvent,s,this)},t.prototype.mobileInitialize=function(i){var r=this,s=i.currentTarget;this.tapHoldTimer=setTimeout(function(){r.externalInitialize=!0,r.removeTapholdTimer(),r.initialize(i,s)},this.tapHoldThreshold),E.add(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.removeTapholdTimer,this),E.add(document,X.isSafari()?"touchend":X.touchEndEvent,this.removeTapholdTimer,this)},t.prototype.removeTapholdTimer=function(){clearTimeout(this.tapHoldTimer),E.remove(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.removeTapholdTimer),E.remove(document,X.isSafari()?"touchend":X.touchEndEvent,this.removeTapholdTimer)},t.prototype.getScrollableParent=function(i,r){return m(i)?null:i[{vertical:"scrollHeight",horizontal:"scrollWidth"}[""+r]]>i[{vertical:"clientHeight",horizontal:"clientWidth"}[""+r]]&&("vertical"===r?i.scrollTop>0:i.scrollLeft>0)?("vertical"===r?(this.parentScrollY=this.parentScrollY+(0===this.parentScrollY?i.scrollTop:i.scrollTop-this.parentScrollY),this.tempScrollHeight=i.scrollHeight):(this.parentScrollX=this.parentScrollX+(0===this.parentScrollX?i.scrollLeft:i.scrollLeft-this.parentScrollX),this.tempScrollWidth=i.scrollWidth),m(i)?i:this.getScrollableParent(i.parentNode,r)):this.getScrollableParent(i.parentNode,r)},t.prototype.getScrollableValues=function(){this.parentScrollX=0,this.parentScrollY=0,this.element.classList.contains("e-dialog")&&this.element.classList.contains("e-dlg-modal"),this.getScrollableParent(this.element.parentNode,"vertical"),this.getScrollableParent(this.element.parentNode,"horizontal")},t.prototype.initialize=function(i,r){if(this.currentStateTarget=i.target,!this.isDragStarted()){if(this.isDragStarted(!0),this.externalInitialize=!1,this.target=i.currentTarget||r,this.dragProcessStarted=!1,this.abort){var s=this.abort;"string"==typeof s&&(s=[s]);for(var o=0;o=this.distance||this.externalInitialize){var p=this.getHelperElement(i);if(!p||m(p))return;r&&i.preventDefault();var f=this.helperElement=p;if(this.parentClientRect=this.calculateParentPosition(f.offsetParent),this.dragStart){var v={event:i,element:l,target:this.getProperTargetElement(i),bindEvents:ce()?this.bindDragEvents.bind(this):null,dragElement:f};this.trigger("dragStart",v)}this.dragArea?this.setDragArea():(this.dragLimit={left:0,right:0,bottom:0,top:0},this.borderWidth={top:0,left:0}),o={left:this.position.left-this.parentClientRect.left,top:this.position.top-this.parentClientRect.top},this.clone&&!this.enableTailMode&&(this.diffX=this.position.left-this.offset.left,this.diffY=this.position.top-this.offset.top),this.getScrollableValues();var y=getComputedStyle(l),S=parseFloat(y.marginTop);this.clone&&0!==S&&(o.top+=S),this.eleTop=isNaN(parseFloat(y.top))?0:parseFloat(y.top)-this.offset.top,this.enableScrollHandler&&!this.clone&&(o.top-=this.parentScrollY,o.left-=this.parentScrollX);var b=this.getProcessedPositionValue({top:o.top-this.diffY+"px",left:o.left-this.diffX+"px"});this.dragArea&&"string"!=typeof this.dragArea&&this.dragArea.classList.contains("e-kanban-content")&&"relative"===this.dragArea.style.position&&(o.top+=this.dragArea.scrollTop),this.dragElePosition={top:o.top,left:o.left},je(f,this.getDragPosition({position:"absolute",left:b.left,top:b.top})),E.remove(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.intDragStart),E.remove(document,X.isSafari()?"touchend":X.touchEndEvent,this.intDestroy),ce()||this.bindDragEvents(f)}}},t.prototype.bindDragEvents=function(i){Tr(i)?(E.add(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.intDrag,this),E.add(document,X.isSafari()?"touchend":X.touchEndEvent,this.intDragStop,this),this.setGlobalDroppables(!1,this.element,i)):(this.toggleEvents(),document.body.classList.remove("e-prevent-select"))},t.prototype.elementInViewport=function(i){for(this.top=i.offsetTop,this.left=i.offsetLeft,this.width=i.offsetWidth,this.height=i.offsetHeight;i.offsetParent;)this.top+=(i=i.offsetParent).offsetTop,this.left+=i.offsetLeft;return this.top>=window.pageYOffset&&this.left>=window.pageXOffset&&this.top+this.height<=window.pageYOffset+window.innerHeight&&this.left+this.width<=window.pageXOffset+window.innerWidth},t.prototype.getProcessedPositionValue=function(i){return this.queryPositionInfo?this.queryPositionInfo(i):i},t.prototype.calculateParentPosition=function(i){if(m(i))return{left:0,top:0};var r=i.getBoundingClientRect(),s=getComputedStyle(i);return{left:r.left+window.pageXOffset-parseInt(s.marginLeft,10),top:r.top+window.pageYOffset-parseInt(s.marginTop,10)}},t.prototype.intDrag=function(i){if(st(i.changedTouches)||1===i.changedTouches.length){var r,s;this.clone&&i.changedTouches&&X.isDevice&&X.isTouch&&i.preventDefault(),this.position=this.getMousePosition(i,this.isDragScroll);var o=this.getDocumentWidthHeight("Height");oy&&y>0?this.dragLimit.left:this.dragLimit.right+window.pageXOffset0?y-(y-this.dragLimit.right)+window.pageXOffset-M:y<0?this.dragLimit.left:y}if(this.pageY!==v||this.skipDistanceCheck){var w=d.offsetHeight+(parseFloat(b.marginTop)+parseFloat(b.marginBottom));s=this.dragLimit.top>S&&S>0?this.dragLimit.top:this.dragLimit.bottom+window.pageYOffset0?S-(S-this.dragLimit.bottom)+window.pageYOffset-w:S<0?this.dragLimit.top:S}}else r=y,s=S;var A,x,C=p+this.borderWidth.top,D=u+this.borderWidth.left;if(this.dragProcessStarted&&(m(s)&&(s=this.prevTop),m(r)&&(r=this.prevLeft)),this.helperElement.classList.contains("e-treeview"))this.dragArea?(this.dragLimit.top=this.clone?this.dragLimit.top:0,A=s-C<0?this.dragLimit.top:s-this.borderWidth.top,x=r-D<0?this.dragLimit.left:r-this.borderWidth.left):(A=s-this.borderWidth.top,x=r-this.borderWidth.left);else if(this.dragArea){var R=this.helperElement.classList.contains("e-dialog");this.dragLimit.top=this.clone?this.dragLimit.top:0,A=s-C<0?this.dragLimit.top:s-C,x=r-D<0?R?r-(D-this.borderWidth.left):this.dragElePosition.left:r-D}else A=s-C,x=r-D;var L=parseFloat(getComputedStyle(this.element).marginTop);if(L>0&&(this.clone&&(A+=L,S<0&&(L+S>=0?A=L+S:A-=L),this.dragArea&&(A=this.dragLimit.bottom=0){var O=this.dragLimit.top+S-C;O+L+C<0?A-=L+C:A=O}else A-=L+C;this.dragArea&&this.helperElement.classList.contains("e-treeview")&&(A=A+(w=d.offsetHeight+(parseFloat(b.marginTop)+parseFloat(b.marginBottom)))>this.dragLimit.bottom?this.dragLimit.bottom-w:A),this.enableScrollHandler&&!this.clone&&(A-=this.parentScrollY,x-=this.parentScrollX),this.dragArea&&"string"!=typeof this.dragArea&&this.dragArea.classList.contains("e-kanban-content")&&"relative"===this.dragArea.style.position&&(A+=this.dragArea.scrollTop);var N=this.getProcessedPositionValue({top:A+"px",left:x+"px"});this.isPreventScroll&&(N=this.getProcessedPositionValue({top:this.position.top-this.parentClientRect.top-2+"px",left:this.position.left-this.parentClientRect.left-2+"px"})),je(d,this.getDragPosition(N)),!this.elementInViewport(d)&&this.enableAutoScroll&&!this.helperElement.classList.contains("e-treeview")&&this.helperElement.scrollIntoView();var T=document.querySelectorAll(":hover");if(this.enableAutoScroll&&this.helperElement.classList.contains("e-treeview")){0===T.length&&(T=this.getPathElements(i));var P=this.getScrollParent(T,!1);this.elementInViewport(this.helperElement)?this.getScrollPosition(P,A):this.elementInViewport(this.helperElement)||(0===(T=[].slice.call(document.querySelectorAll(":hover"))).length&&(T=this.getPathElements(i)),P=this.getScrollParent(T,!0),this.getScrollPosition(P,A))}this.dragProcessStarted=!0,this.prevLeft=r,this.prevTop=s,this.position.left=r,this.position.top=s,this.pageX=g,this.pageY=v}},t.prototype.getScrollParent=function(i,r){for(var o,s=r?i.reverse():i,a=s.length-1;a>=0;a--)if(("auto"===(o=window.getComputedStyle(s[parseInt(a.toString(),10)])["overflow-y"])||"scroll"===o)&&s[parseInt(a.toString(),10)].scrollHeight>s[parseInt(a.toString(),10)].clientHeight)return s[parseInt(a.toString(),10)];if("visible"===(o=window.getComputedStyle(document.scrollingElement)["overflow-y"]))return document.scrollingElement.style.overflow="auto",document.scrollingElement},t.prototype.getScrollPosition=function(i,r){if(i&&i===document.scrollingElement)i.clientHeight+document.scrollingElement.scrollTop-this.helperElement.clientHeightr?i.scrollTop+=this.helperElement.clientHeight:i.scrollTop>r-this.helperElement.clientHeight&&(i.scrollTop-=this.helperElement.clientHeight);else if(i&&i!==document.scrollingElement){var s=document.scrollingElement.scrollTop,o=this.helperElement.clientHeight;i.clientHeight+i.getBoundingClientRect().top-o+sr-o-s&&(i.scrollTop-=this.helperElement.clientHeight)}},t.prototype.getPathElements=function(i){return document.elementsFromPoint(i.clientX>0?i.clientX:0,i.clientY>0?i.clientY:0)},t.prototype.triggerOutFunction=function(i,r){this.hoverObject.instance.intOut(i,r.target),this.hoverObject.instance.dragData[this.scope]=null,this.hoverObject=null},t.prototype.getDragPosition=function(i){var r=ze({},i);return this.axis&&("x"===this.axis?delete r.top:"y"===this.axis&&delete r.left),r},t.prototype.getDocumentWidthHeight=function(i){var r=document.body,s=document.documentElement;return Math.max(r["scroll"+i],s["scroll"+i],r["offset"+i],s["offset"+i],s["client"+i])},t.prototype.intDragStop=function(i){if(this.dragProcessStarted=!1,st(i.changedTouches)||1===i.changedTouches.length){if(-1!==["touchend","pointerup","mouseup"].indexOf(i.type)){if(this.dragStop){var s=this.getProperTargetElement(i);this.trigger("dragStop",{event:i,element:this.element,target:s,helper:this.helperElement})}this.intDestroy(i)}else this.element.setAttribute("aria-grabbed","false");var o=this.checkTargetElement(i);o.target&&o.instance&&(o.instance.dragStopCalled=!0,o.instance.dragData[this.scope]=this.droppables[this.scope],o.instance.intDrop(i,o.target)),this.setGlobalDroppables(!0),document.body.classList.remove("e-prevent-select")}},t.prototype.intDestroy=function(i){this.dragProcessStarted=!1,this.toggleEvents(),document.body.classList.remove("e-prevent-select"),this.element.setAttribute("aria-grabbed","false"),E.remove(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.intDragStart),E.remove(document,X.isSafari()?"touchend":X.touchEndEvent,this.intDragStop),E.remove(document,X.isSafari()?"touchend":X.touchEndEvent,this.intDestroy),E.remove(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.intDrag),this.isDragStarted()&&this.isDragStarted(!0)},t.prototype.onPropertyChanged=function(i,r){},t.prototype.getModuleName=function(){return"draggable"},t.prototype.isDragStarted=function(i){return i&&(bC.isDragged=!bC.isDragged),bC.isDragged},t.prototype.setDragArea=function(){var i,r,a,s=0,o=0;if(a="string"==typeof this.dragArea?U(this.dragArea):this.dragArea){var h=a.getBoundingClientRect();i=a.scrollWidth?a.scrollWidth:h.right-h.left,r=a.scrollHeight?this.dragArea&&!m(this.helperElement)&&this.helperElement.classList.contains("e-treeview")?a.clientHeight:a.scrollHeight:h.bottom-h.top;for(var c=["Top","Left","Bottom","Right"],d=getComputedStyle(a),u=0;u12;return C0(i.target,this.helperElement)||-1!==i.type.indexOf("touch")||a?(this.helperElement.style.pointerEvents="none",s=document.elementFromPoint(r.clientX,r.clientY),this.helperElement.style.pointerEvents=o):s=i.target,s},t.prototype.currentStateCheck=function(i,r){return m(this.currentStateTarget)||this.currentStateTarget===i?m(r)?i:r:this.currentStateTarget},t.prototype.getMousePosition=function(i,r){var a,l,s=void 0!==i.srcElement?i.srcElement:i.target,o=this.getCoordinates(i),h=m(s.offsetParent);if(r?(a=this.clone?o.pageX:o.pageX+(h?0:s.offsetParent.scrollLeft)-this.relativeXPosition,l=this.clone?o.pageY:o.pageY+(h?0:s.offsetParent.scrollTop)-this.relativeYPosition):(a=this.clone?o.pageX:o.pageX+window.pageXOffset-this.relativeXPosition,l=this.clone?o.pageY:o.pageY+window.pageYOffset-this.relativeYPosition),document.scrollingElement&&!r&&!this.clone){var c=document.scrollingElement;a=c.scrollWidth>0&&c.scrollWidth>c.clientWidth&&c.scrollLeft>0?a-c.scrollLeft:a,l=c.scrollHeight>0&&c.scrollHeight>c.clientHeight&&c.scrollTop>0?l-c.scrollTop:l}return{left:a-(this.margin.left+this.cursorAt.left),top:l-(this.margin.top+this.cursorAt.top)}},t.prototype.getCoordinates=function(i){return i.type.indexOf("touch")>-1?i.changedTouches[0]:i},t.prototype.getHelperElement=function(i){var r;return this.clone?this.helper?r=this.helper({sender:i,element:this.target}):(r=mi("div",{className:"e-drag-helper e-block-touch",innerHTML:"Draggable"}),document.body.appendChild(r)):r=this.element,r},t.prototype.setGlobalDroppables=function(i,r,s){this.droppables[this.scope]=i?null:{draggable:r,helper:s,draggedElement:this.element}},t.prototype.checkTargetElement=function(i){var r=this.getProperTargetElement(i),s=this.getDropInstance(r);if(!s&&r&&!m(r.parentNode)){var o=J(r.parentNode,".e-droppable")||r.parentElement;o&&(s=this.getDropInstance(o))}return{target:r,instance:s}},t.prototype.getDropInstance=function(i){var s,o=i&&i.ej2_instances;if(o)for(var a=0,l=o;a=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},lR=function(n){function t(e,i){var r=n.call(this,i,e)||this;return r.mouseOver=!1,r.dragData={},r.dragStopCalled=!1,r.bind(),r}return sZ(t,n),t.prototype.bind=function(){this.wireEvents()},t.prototype.wireEvents=function(){E.add(this.element,X.isSafari()?"touchend":X.touchEndEvent,this.intDrop,this)},t.prototype.onPropertyChanged=function(e,i){},t.prototype.getModuleName=function(){return"droppable"},t.prototype.intOver=function(e,i){this.mouseOver||(this.trigger("over",{event:e,target:i,dragData:this.dragData[this.scope]}),this.mouseOver=!0)},t.prototype.intOut=function(e,i){this.mouseOver&&(this.trigger("out",{evt:e,target:i}),this.mouseOver=!1)},t.prototype.intDrop=function(e,i){if(this.dragStopCalled){this.dragStopCalled=!1;var a,r=!0,s=this.dragData[this.scope],o=!!s&&s.helper&&Tr(s.helper);o&&(a=this.isDropArea(e,s.helper,i),this.accept&&(r=vC(s.helper,this.accept))),o&&this.drop&&a.canDrop&&r&&this.trigger("drop",{event:e,target:a.target,droppedElement:s.helper,dragData:s}),this.mouseOver=!1}},t.prototype.isDropArea=function(e,i,r){var s={canDrop:!0,target:r||e.target},o="touchend"===e.type;if(o||s.target===i){i.style.display="none";var a=o?e.changedTouches[0]:e,l=document.elementFromPoint(a.clientX,a.clientY);s.canDrop=!1,s.canDrop=C0(l,this.element),s.canDrop&&(s.target=l),i.style.display=""}return s},t.prototype.destroy=function(){E.remove(this.element,X.isSafari()?"touchend":X.touchEndEvent,this.intDrop),n.prototype.destroy.call(this)},lp([I()],t.prototype,"accept",void 0),lp([I("default")],t.prototype,"scope",void 0),lp([H()],t.prototype,"drop",void 0),lp([H()],t.prototype,"over",void 0),lp([H()],t.prototype,"out",void 0),lp([Ft],t)}(ah),ho=function(){function n(t,e,i){this.controlName=t,this.localeStrings=e,this.setLocale(i||"en-US")}return n.prototype.setLocale=function(t){var e=this.intGetControlConstant(n.locale,t);this.currentLocale=e||this.localeStrings},n.load=function(t){this.locale=ze(this.locale,t,{},!0)},n.prototype.getConstant=function(t){return m(this.currentLocale[""+t])?this.localeStrings[""+t]||"":this.currentLocale[""+t]},n.prototype.intGetControlConstant=function(t,e){return t[""+e]?t[""+e][this.controlName]:null},n.locale={},n}(),hR=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),hh=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},lZ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return hR(t,n),hh([I(50)],t.prototype,"swipeThresholdDistance",void 0),t}(Ee),hZ=/(Up|Down)/,Fs=function(n){function t(e,i){var r=n.call(this,i,e)||this;return r.touchAction=!0,r.tapCount=0,r.startEvent=function(s){if(!0===r.touchAction){var o=r.updateChangeTouches(s);void 0!==s.changedTouches&&(r.touchAction=!1),r.isTouchMoved=!1,r.movedDirection="",r.startPoint=r.lastMovedPoint={clientX:o.clientX,clientY:o.clientY},r.startEventData=o,r.hScrollLocked=r.vScrollLocked=!1,r.tStampStart=Date.now(),r.timeOutTapHold=setTimeout(function(){r.tapHoldEvent(s)},r.tapHoldThreshold),E.add(r.element,X.touchMoveEvent,r.moveEvent,r),E.add(r.element,X.touchEndEvent,r.endEvent,r),E.add(r.element,X.touchCancelEvent,r.cancelEvent,r)}},r.moveEvent=function(s){var o=r.updateChangeTouches(s);r.movedPoint=o,r.isTouchMoved=!(o.clientX===r.startPoint.clientX&&o.clientY===r.startPoint.clientY);var a={};r.isTouchMoved&&(clearTimeout(r.timeOutTapHold),r.calcScrollPoints(s),a=ze(a,{},{startEvents:r.startEventData,originalEvent:s,startX:r.startPoint.clientX,startY:r.startPoint.clientY,distanceX:r.distanceX,distanceY:r.distanceY,scrollDirection:r.scrollDirection,velocity:r.getVelocity(o)}),r.trigger("scroll",a),r.lastMovedPoint={clientX:o.clientX,clientY:o.clientY})},r.cancelEvent=function(s){clearTimeout(r.timeOutTapHold),clearTimeout(r.timeOutTap),r.tapCount=0,r.swipeFn(s),E.remove(r.element,X.touchCancelEvent,r.cancelEvent)},r.endEvent=function(s){r.swipeFn(s),r.isTouchMoved||"function"==typeof r.tap&&(r.trigger("tap",{originalEvent:s,tapCount:++r.tapCount}),r.timeOutTap=setTimeout(function(){r.tapCount=0},r.tapThreshold)),r.modeclear()},r.swipeFn=function(s){clearTimeout(r.timeOutTapHold),clearTimeout(r.timeOutTap);var o=r.updateChangeTouches(s),a=o.clientX-r.startPoint.clientX,l=o.clientY-r.startPoint.clientY;a=Math.floor(a<0?-1*a:a),l=Math.floor(l<0?-1*l:a),r.isTouchMoved=a>1||l>1,/Firefox/.test(X.userAgent)&&0===o.clientX&&0===o.clientY&&"mouseup"===s.type&&(r.isTouchMoved=!1),r.endPoint=o,r.calcPoints(s);var c={originalEvent:s,startEvents:r.startEventData,startX:r.startPoint.clientX,startY:r.startPoint.clientY,distanceX:r.distanceX,distanceY:r.distanceY,swipeDirection:r.movedDirection,velocity:r.getVelocity(o)};if(r.isTouchMoved){var d=r.swipeSettings.swipeThresholdDistance,u=ze(void 0,r.defaultArgs,c),p=!1,f=r.element,g=r.isScrollable(f),v=hZ.test(r.movedDirection);(dthis.distanceY?i.clientX>this.startPoint.clientX?"Right":"Left":i.clientYthis.distanceY||!0===this.hScrollLocked)&&!1===this.vScrollLocked?(this.scrollDirection=i.clientX>this.lastMovedPoint.clientX?"Right":"Left",this.hScrollLocked=!0):(this.scrollDirection=i.clientY=e[r[0]+s[0]]},t.prototype.updateChangeTouches=function(e){return e.changedTouches&&0!==e.changedTouches.length?e.changedTouches[0]:e},hh([H()],t.prototype,"tap",void 0),hh([H()],t.prototype,"tapHold",void 0),hh([H()],t.prototype,"swipe",void 0),hh([H()],t.prototype,"scroll",void 0),hh([I(350)],t.prototype,"tapThreshold",void 0),hh([I(750)],t.prototype,"tapHoldThreshold",void 0),hh([re({},lZ)],t.prototype,"swipeSettings",void 0),hh([Ft],t)}(ah),cZ=new RegExp("\\n|\\r|\\s\\s+","g"),dZ=new RegExp(/'|"/g),uZ=new RegExp("if ?\\("),pZ=new RegExp("else if ?\\("),cR=new RegExp("else"),fZ=new RegExp("for ?\\("),dR=new RegExp("(/if|/for)"),gZ=new RegExp("\\((.*)\\)",""),MC=new RegExp("^[0-9]+$","g"),vZ=new RegExp("[\\w\"'.\\s+]+","g"),mZ=new RegExp('"(.*?)"',"g"),yZ=new RegExp("[\\w\"'@#$.\\s-+]+","g"),uR=new RegExp("\\${([^}]*)}","g"),SZ=/^\..*/gm,wC=/\\/gi,IZ=/\\\\/gi,bZ=new RegExp("[\\w\"'@#$.\\s+]+","g"),MZ=/\window\./gm;function hp(n,t,e,i,r){return!t||MC.test(n)||-1!==i.indexOf(n.split(".")[0])||r||"true"===n||"false"===n?n:e+"."+n}function CC(n,t,e,i){return t&&!MC.test(n)&&-1===i.indexOf(n.split(".")[0])?e+'["'+n:n}function pR(n){return n.match(IZ)?n:n.replace(wC,"\\\\")}function fR(n,t,e,i){if(n=n.trim(),/\window\./gm.test(n))return n;var s=/'|"/gm;return/@|\$|#/gm.test(n)&&(n=CC(n,-1===e.indexOf(n),t,e)+'"]'),SZ.test(n)?function EZ(n,t,e,i){return!t||MC.test(n)||-1!==i.indexOf(n.split(".")[0])||/^\..*/gm.test(n)?n:e+"."+n}(n,!s.test(n)&&-1===e.indexOf(n),t,e):hp(n,!s.test(n)&&-1===e.indexOf(n),t,e,i)}var DZ=/^[\n\r.]+0&&t.forEach(function(e){he(e)})},n.removeJsEvents=function(){var t=this.wrapElement.querySelectorAll("["+vR.join("],[")+"]");t.length>0&&t.forEach(function(e){vR.forEach(function(i){e.hasAttribute(i)&&e.removeAttribute(i)})})},n.removeXssAttrs=function(){var t=this;this.removeAttrs.forEach(function(e,i){var r=t.wrapElement.querySelectorAll(e.selector);r.length>0&&r.forEach("a[href]"===e.selector?function(s){-1!==s.getAttribute(e.attribute).replace(/\t|\s|&/,"").indexOf("javascript:alert")&&s.removeAttribute(e.attribute)}:function(s){s.removeAttribute(e.attribute)})})},n}();function PZ(n){return function(t){!function kZ(n,t){t.forEach(function(e){Object.getOwnPropertyNames(e.prototype).forEach(function(i){(!Object.prototype.hasOwnProperty.call(n.prototype,i)||e.isFormBase&&"constructor"!==i)&&(n.prototype["".concat(i)]=e.prototype["".concat(i)])})})}(t,n)}}function mR(n,t,e){var i={};if(n&&n.length){for(var r=0,s=n;r"u"||(y.innerHTML=v.innerHTML?v.innerHTML:"",void 0!==v.className&&(y.className=v.className),void 0!==v.id&&(y.id=v.id),void 0!==v.styles&&y.setAttribute("style",v.styles),void 0!==e.ngAttr&&y.setAttribute(e.ngAttr,""),void 0!==v.attrs&&Fe(y,v.attrs)),y};for(var i=0,r=e.tags;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s}function jZ(n){for(var t,e=n.childNodes,i=0;i"u"&&(c["".concat(o)]=[]),c["".concat(o)].push(h),h.rootNodes}}});var ml,hd,ph,Vg,sc,uo,YZ=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),La=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Jo_RTL=(new Lg,"e-rtl"),ys=function(n){function t(e,i){return n.call(this,e,i)||this}return YZ(t,n),t.prototype.preRender=function(){},t.prototype.render=function(){this.initialize(),this.removeRippleEffect=function ms(n,t,e){var i=function q$(n){return{selector:n&&n.selector?n.selector:null,ignore:n&&n.ignore?n.ignore:null,rippleFlag:n&&n.rippleFlag,isCenterRipple:n&&n.isCenterRipple,duration:n&&n.duration?n.duration:350}}(t);return!1===i.rippleFlag||void 0===i.rippleFlag&&!Zo?function(){}:(n.setAttribute("data-ripple","true"),E.add(n,"mousedown",Zz,{parent:n,rippleOptions:i}),E.add(n,"mouseup",Jz,{parent:n,rippleOptions:i,done:e}),E.add(n,"mouseleave",op,{parent:n,rippleOptions:i}),X.isPointer&&E.add(n,"transitionend",op,{parent:n,rippleOptions:i}),function(){n.removeAttribute("data-ripple"),E.remove(n,"mousedown",Zz),E.remove(n,"mouseup",Jz),E.remove(n,"mouseleave",op),E.remove(n,"transitionend",op)})}(this.element,{selector:".e-btn"}),this.renderComplete()},t.prototype.initialize=function(){if(this.cssClass&&V([this.element],this.cssClass.replace(/\s+/g," ").trim().split(" ")),this.isPrimary&&this.element.classList.add("e-primary"),!ce()||ce()&&"progress-btn"!==this.getModuleName()){if(this.content){var e=this.enableHtmlSanitizer?Ti.sanitize(this.content):this.content;this.element.innerHTML=e}this.setIconCss()}this.enableRtl&&this.element.classList.add(Jo_RTL),this.disabled?this.controlStatus(this.disabled):this.wireEvents()},t.prototype.controlStatus=function(e){this.element.disabled=e},t.prototype.setIconCss=function(){if(this.iconCss){var e=this.createElement("span",{className:"e-btn-icon "+this.iconCss});this.element.textContent.trim()?(e.classList.add("e-icon-"+this.iconPosition.toLowerCase()),("Top"===this.iconPosition||"Bottom"===this.iconPosition)&&this.element.classList.add("e-"+this.iconPosition.toLowerCase()+"-icon-btn")):this.element.classList.add("e-icon-btn");var i=this.element.childNodes[0];!i||"Left"!==this.iconPosition&&"Top"!==this.iconPosition?this.element.appendChild(e):this.element.insertBefore(e,i)}},t.prototype.wireEvents=function(){this.isToggle&&E.add(this.element,"click",this.btnClickHandler,this)},t.prototype.unWireEvents=function(){this.isToggle&&E.remove(this.element,"click",this.btnClickHandler)},t.prototype.btnClickHandler=function(){this.element.classList.contains("e-active")?this.element.classList.remove("e-active"):this.element.classList.add("e-active")},t.prototype.destroy=function(){var e=["e-primary",Jo_RTL,"e-icon-btn","e-success","e-info","e-danger","e-warning","e-flat","e-outline","e-small","e-bigger","e-active","e-round","e-top-icon-btn","e-bottom-icon-btn"];this.cssClass&&(e=e.concat(this.cssClass.split(" "))),n.prototype.destroy.call(this),K([this.element],e),this.element.getAttribute("class")||this.element.removeAttribute("class"),this.disabled&&this.element.removeAttribute("disabled"),this.content&&(this.element.innerHTML=this.element.innerHTML.replace(this.content,""));var i=this.element.querySelector("span.e-btn-icon");i&&he(i),this.unWireEvents(),Zo&&this.removeRippleEffect()},t.prototype.getModuleName=function(){return"btn"},t.prototype.getPersistData=function(){return this.addOnPersist([])},t.Inject=function(){},t.prototype.onPropertyChanged=function(e,i){for(var r=this.element.querySelector("span.e-btn-icon"),s=0,o=Object.keys(e);s=hd.width?hd.width:0;return ml.right+JR()-n}function dE(){return U0()+ml.width/2}function uE(n,t,e,i){if(void 0===t&&(t=null),void 0===e&&(e={X:!1,Y:!1}),!e.Y&&!e.X)return{left:0,top:0};var r=n.getBoundingClientRect();if(uo=t,sc=n.ownerDocument,i||(i=is(n,"left","top")),e.X){var s=uo?r4():l4(),o=mE(),a=yE(),l=o-i.left,h=i.left+r.width-a;r.width>s?i.left=l>0&&h<=0?a-r.width:h>0&&l<=0?o:l>h?a-r.width:o:l>0?i.left+=l:h>0&&(i.left-=h)}if(e.Y){var c=uo?n4():a4(),d=vE(),u=SE(),p=d-i.top,f=i.top+r.height-u;r.height>c?i.top=p>0&&f<=0?u-r.height:f>0&&p<=0?d:p>f?u-r.height:d:p>0?i.top+=p:f>0&&(i.top-=f)}return i}function oc(n,t,e,i){void 0===t&&(t=null);var r=is(n,"left","top");e&&(r.left=e),i&&(r.top=i);var s=[];uo=t,sc=n.ownerDocument;var o=n.getBoundingClientRect(),l=r.left,h=r.left+o.width,d=gE(r.top,r.top+o.height),u=e4(l,h);return d.topSide&&s.push("top"),u.rightSide&&s.push("right"),u.leftSide&&s.push("left"),d.bottomSide&&s.push("bottom"),s}function bJ(n,t,e,i,r,s,o,a,l){if(void 0===o&&(o=null),void 0===a&&(a={X:!0,Y:!0}),t&&n&&r&&s&&(a.X||a.Y)){var d,h={TL:null,TR:null,BL:null,BR:null},c={TL:null,TR:null,BL:null,BR:null};if("none"===window.getComputedStyle(n).display){var u=n.style.visibility;n.style.visibility="hidden",n.style.display="block",d=n.getBoundingClientRect(),n.style.removeProperty("display"),n.style.visibility=u}else d=n.getBoundingClientRect();var p={posX:r,posY:s,offsetX:e,offsetY:i,position:{left:0,top:0}};uo=o,sc=t.ownerDocument,function wJ(n,t,e,i,r){e.position=is(n,e.posX,e.posY,i,r),t.TL=is(n,"left","top",i,r),t.TR=is(n,"right","top",i,r),t.BR=is(n,"left","bottom",i,r),t.BL=is(n,"right","bottom",i,r)}(t,h,p,l,d),fE(c,p,d),a.X&&t4(t,c,h,p,d,!0),a.Y&&h.TL.top>-1&&i4(t,c,h,p,d,!0),function MJ(n,t,e){var i=0,r=0;if(null!=n.offsetParent&&("absolute"===getComputedStyle(n.offsetParent).position||"relative"===getComputedStyle(n.offsetParent).position)){var s=is(n.offsetParent,"left","top",!1,e);i=s.left,r=s.top}var o=1,a=1,l=KR(n);if(l){var h=getComputedStyle(l).transform;if("none"!==h){var c=new DOMMatrix(h);o=c.a,a=c.d}if("none"!==getComputedStyle(l).zoom){var u=pE(document.body);o*=u,a*=u}}n.style.top=t.position.top/a+t.offsetY-r/a+"px",n.style.left=t.position.left/o+t.offsetX-i/o+"px"}(n,p,d)}}function pE(n){var t=getComputedStyle(n).zoom;return parseFloat(t)||1}function KR(n){for(;n;){var t=window.getComputedStyle(n).transform,e=pE(document.body);if(t&&"none"!==t||e&&1!==e)return n;if(n===document.body)return null;n=n.offsetParent||n.parentElement}return null}function fE(n,t,e){n.TL={top:t.position.top+t.offsetY,left:t.position.left+t.offsetX},n.TR={top:n.TL.top,left:n.TL.left+e.width},n.BL={top:n.TL.top+e.height,left:n.TL.left},n.BR={top:n.TL.top+e.height,left:n.TL.left+e.width}}function e4(n,t){var e=!1,i=!1;return n-V0()yE()&&(i=!0),{leftSide:e,rightSide:i}}function t4(n,t,e,i,r,s){var o=e4(t.TL.left,t.TR.left),a=gE(t.TL.top,t.BL.top);e.TL.left-V0()<=mE()&&(o.leftSide=!1),e.TR.left>yE()&&(o.rightSide=!1),(o.leftSide&&!o.rightSide||!o.leftSide&&o.rightSide)&&(i.posX="right"===i.posX?"left":"right",i.offsetX=i.offsetX+r.width,i.offsetX=-1*i.offsetX,i.position=is(n,i.posX,i.posY,!1),fE(t,i,r),s&&t4(n,t,e,i,r,!1),!o.leftSide&&o.rightSide&&a.bottomSide&&(i.offsetX=0))}function i4(n,t,e,i,r,s){var o=gE(t.TL.top,t.BL.top);e.TL.top-j0()<=vE()&&(o.topSide=!1),e.BL.top>=SE()&&n.getBoundingClientRect().bottomSE()&&(i=!0),{topSide:e,bottomSide:i}}function r4(){return uo.getBoundingClientRect().width}function n4(){return uo.getBoundingClientRect().height}function s4(){return uo.getBoundingClientRect().left}function o4(){return uo.getBoundingClientRect().top}function vE(){return uo?o4():0}function mE(){return uo?s4():0}function yE(){return uo?V0()+s4()+r4():V0()+l4()}function SE(){return uo?j0()+o4()+n4():j0()+a4()}function j0(){return sc.documentElement.scrollTop||sc.body.scrollTop}function V0(){return sc.documentElement.scrollLeft||sc.body.scrollLeft}function a4(){return window.innerHeight}function l4(){var n=window.innerWidth,t=document.documentElement.getBoundingClientRect();return n-(n-(m(document.documentElement)?0:t.width))}function h4(){uo=null,sc=null}var c4=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),bn=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},d4=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return c4(t,n),bn([I("left")],t.prototype,"X",void 0),bn([I("top")],t.prototype,"Y",void 0),t}(Ee),Gn_OPEN="e-popup-open",Gn_CLOSE="e-popup-close",ac=function(n){function t(e,i){return n.call(this,i,e)||this}return c4(t,n),t.prototype.onPropertyChanged=function(e,i){for(var r=0,s=Object.keys(e);r0&&c.left>0&&c.right>0&&c.bottom>0}var s=i.getBoundingClientRect();return!(r.bottoms.bottom||r.right>s.right||r.leftr.top?this.element.style.top="0px":s.bottomr.left&&(this.element.style.left=parseInt(this.element.style.left,10)+(s.left-r.left)+"px"))}},t.prototype.checkCollision=function(){var e=this.collision.X,i=this.collision.Y;"none"===e&&"none"===i||("flip"===e&&"flip"===i?this.callFlip({X:!0,Y:!0}):"fit"===e&&"fit"===i?this.callFit({X:!0,Y:!0}):("flip"===e?this.callFlip({X:!0,Y:!1}):"flip"===i&&this.callFlip({Y:!0,X:!1}),"fit"===e?this.callFit({X:!0,Y:!1}):"fit"===i&&this.callFit({X:!1,Y:!0})))},t.prototype.show=function(e,i){var r=this;if(this.getRelateToElement().classList.contains("e-filemanager")&&(this.fmDialogContainer=this.element.getElementsByClassName("e-file-select-wrap")[0]),this.wireEvents(),!m(this.fmDialogContainer)&&X.isIos&&(this.fmDialogContainer.style.display="block"),1e3===this.zIndex||!m(i)){var o=m(i)?this.element:i;this.zIndex=lc(o),je(this.element,{zIndex:this.zIndex})}e=m(e)||"object"!=typeof e?this.showAnimation:e,("none"!==this.collision.X||"none"!==this.collision.Y)&&(K([this.element],Gn_CLOSE),V([this.element],Gn_OPEN),this.checkCollision(),K([this.element],Gn_OPEN),V([this.element],Gn_CLOSE)),m(e)?(K([this.element],Gn_CLOSE),V([this.element],Gn_OPEN),this.trigger("open")):(e.begin=function(){r.isDestroyed||(K([r.element],Gn_CLOSE),V([r.element],Gn_OPEN))},e.end=function(){r.isDestroyed||r.trigger("open")},new Hs(e).animate(this.element))},t.prototype.hide=function(e){var i=this;e=m(e)||"object"!=typeof e?this.hideAnimation:e,m(e)?(K([this.element],Gn_OPEN),V([this.element],Gn_CLOSE),this.trigger("close")):(e.end=function(){i.isDestroyed||(K([i.element],Gn_OPEN),V([i.element],Gn_CLOSE),i.trigger("close"))},new Hs(e).animate(this.element)),this.unwireEvents()},t.prototype.getScrollableParent=function(e){return this.checkFixedParent(e),function IE(n,t){for(var e=getComputedStyle(n),i=[],r=/(auto|scroll)/,s=n.parentElement;s&&"HTML"!==s.tagName;){var o=getComputedStyle(s);!("absolute"===e.position&&"static"===o.position)&&r.test(o.overflow+o.overflowY+o.overflowX)&&i.push(s),s=s.parentElement}return t||i.push(document),i}(e,this.fixedParent)},t.prototype.checkFixedParent=function(e){for(var i=e.parentElement;i&&"HTML"!==i.tagName;){var r=getComputedStyle(i);("fixed"===r.position||"sticky"===r.position)&&!m(this.element)&&this.element.offsetParent&&"BODY"===this.element.offsetParent.tagName&&"hidden"!==getComputedStyle(this.element.offsetParent).overflow&&(this.element.style.top=window.scrollY>parseInt(this.element.style.top,10)?Re(window.scrollY-parseInt(this.element.style.top,10)):Re(parseInt(this.element.style.top,10)-window.scrollY),this.element.style.position="fixed",this.fixedParent=!0),i=i.parentElement,!m(this.element)&&m(this.element.offsetParent)&&"fixed"===r.position&&"fixed"===this.element.style.position&&(this.fixedParent=!0)}},bn([I("auto")],t.prototype,"height",void 0),bn([I("auto")],t.prototype,"width",void 0),bn([I(null)],t.prototype,"content",void 0),bn([I("container")],t.prototype,"targetType",void 0),bn([I(null)],t.prototype,"viewPortElement",void 0),bn([I({X:"none",Y:"none"})],t.prototype,"collision",void 0),bn([I("")],t.prototype,"relateTo",void 0),bn([re({},d4)],t.prototype,"position",void 0),bn([I(0)],t.prototype,"offsetX",void 0),bn([I(0)],t.prototype,"offsetY",void 0),bn([I(1e3)],t.prototype,"zIndex",void 0),bn([I(!1)],t.prototype,"enableRtl",void 0),bn([I("reposition")],t.prototype,"actionOnScroll",void 0),bn([I(null)],t.prototype,"showAnimation",void 0),bn([I(null)],t.prototype,"hideAnimation",void 0),bn([H()],t.prototype,"open",void 0),bn([H()],t.prototype,"close",void 0),bn([H()],t.prototype,"targetExitViewport",void 0),bn([Ft],t)}(yi);function lc(n){for(var t=n.parentElement,e=[];t&&"BODY"!==t.tagName;){var i=document.defaultView.getComputedStyle(t,null).getPropertyValue("z-index"),r=document.defaultView.getComputedStyle(t,null).getPropertyValue("position");"auto"!==i&&"static"!==r&&e.push(i),t=t.parentElement}for(var s=[],o=0;o2147483647?2147483647:c}var _i,Oa,cp,vh,CE,mh,$t,yh,bE=["north-west","north","north-east","west","east","south-west","south","south-east"],Wg="e-resize-handle",hc="e-focused-handle",CJ="e-dlg-resizable",u4=["e-restrict-left"],p4="e-resize-viewport",EJ=["north","west","east","south"],ME=0,wE=0,f4=0,g4=0,Yg=0,Qg=0,Gg=null,EE=null,DE=null,W0=!0,v4=0,xE=!0;function xJ(n){TE();var t=mi("span",{attrs:{unselectable:"on",contenteditable:"false"}});t.setAttribute("class","e-dialog-border-resize e-"+n),"south"===n&&(t.style.height="2px",t.style.width="100%",t.style.bottom="0px",t.style.left="0px"),"north"===n&&(t.style.height="2px",t.style.width="100%",t.style.top="0px",t.style.left="0px"),"east"===n&&(t.style.height="100%",t.style.width="2px",t.style.right="0px",t.style.top="0px"),"west"===n&&(t.style.height="100%",t.style.width="2px",t.style.left="0px",t.style.top="0px"),_i.appendChild(t)}function m4(n){var t;return m(n)||(t="string"==typeof n?document.querySelector(n):n),t}function y4(n){for(var t=n||this,e=_i.querySelectorAll("."+Wg),i=0;i-1?"mouse":"touch"}function I4(n){if(n.preventDefault(),_i=n.target.parentElement,TE(),Yg=n.pageX,Qg=n.pageY,n.target.classList.add(hc),m(Gg)||!0!==Gg(n,this)){this.targetEle&&_i&&_i.querySelector("."+CJ)&&($t="body"===this.target?null:this.targetEle,mh=this.targetEle.clientWidth,vh=this.targetEle.clientHeight);var e=m($t)?document:$t;E.add(e,"mousemove",Xg,this),E.add(document,"mouseup",Y0,this);for(var i=0;i=0||s.top<0)&&(e=!0):e=!0;var a=wE+(r-Qg);a=a>cp?a:cp;var l=0;m($t)||(l=o.top);var h=m($t)?0:$t.offsetHeight-$t.clientHeight,c=s.top-l-h/2;if(c=c<0?0:c,s.top>0&&c+a>vh){if(e=!1,_i.classList.contains(p4))return;_i.style.height=vh-parseInt(c.toString(),10)+"px"}else{var d=0;if(e){s.top<0&&t+(s.height+s.top)>0&&a+(d=s.top)<=30&&(a=s.height-(s.height+s.top)+30),a+s.top>=vh&&(_i.style.height=s.height+(t-(s.height+s.top))+"px");var u=m($t)?d:c;a>=cp&&a+u<=vh&&(_i.style.height=a+"px")}}}function LE(n){var e,t=!1,i="mouse"===S4(n.type)?n.pageY:n.touches[0].pageY,r=cc(_i),s=m($t)?0:$t.offsetHeight-$t.clientHeight;m($t)||(e=cc($t)),(!m($t)&&r.top-e.top>0||m($t)&&i>0||!m($t)&&Math.floor(r.top-e.top+r.height+(e.bottom-r.bottom))-s<=vh)&&(t=!0);var o=wE-(i-Qg);if(t&&o>=cp&&o<=vh){var a=0;m($t)||(a=e.top);var l=g4-a+(i-Qg);l=l>0?l:1,_i.style.height=o+"px",_i.style.top=l+"px"}}function NE(n){var i,t=document.documentElement.clientWidth,e=!1;m($t)||(i=cc($t));var r="mouse"===S4(n.type)?n.pageX:n.touches[0].pageX,s=cc(_i),o=m($t)?0:$t.offsetWidth-$t.clientWidth,a=m($t)?0:i.left,l=m($t)?0:i.width;m(yh)&&(m($t)?yh=t:(yh=s.left-a-o/2+s.width,yh+=l-o-yh)),(!m($t)&&Math.floor(s.left-i.left+s.width+(i.right-s.right))-o<=mh||m($t)&&r>=0)&&(e=!0);var h=ME-(r-Yg);if(W0&&(h=h>yh?yh:h),e&&h>=CE&&h<=mh){var c=0;m($t)||(c=i.left);var d=f4-c+(r-Yg);d=d>0?d:1,h!==v4&&xE&&(_i.style.width=h+"px"),W0&&(_i.style.left=d+"px",xE=1!==d)}v4=h}function OE(n){var i,t=document.documentElement.clientWidth,e=!1;m($t)||(i=cc($t));var s=(n.touches?n.changedTouches[0]:n).pageX,o=cc(_i);(!m($t)&&(o.left-i.left+o.width<=mh||o.right-i.left>=o.width)||m($t)&&t-s>0)&&(e=!0);var a=ME+(s-Yg),l=0;if(m($t)||(l=i.left),o.left-l+a>mh){if(e=!1,_i.classList.contains(p4))return;_i.style.width=mh-(o.left-l)+"px"}e&&a>=CE&&a<=mh&&(_i.style.width=a+"px")}function M4(){for(var n=_i.querySelectorAll("."+Wg),t=0;t=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},OJ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return kE(t,n),Zt([I(!0)],t.prototype,"isFlat",void 0),Zt([I()],t.prototype,"buttonModel",void 0),Zt([I("Button")],t.prototype,"type",void 0),Zt([H()],t.prototype,"click",void 0),t}(Ee),kJ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return kE(t,n),Zt([I("Fade")],t.prototype,"effect",void 0),Zt([I(400)],t.prototype,"duration",void 0),Zt([I(0)],t.prototype,"delay",void 0),t}(Ee),Q0="e-dialog",PE="e-rtl",zE="e-dlg-header-content",w4="e-dlg-header",G0="e-footer-content",X0="e-dlg-modal",C4="e-icon-dlg-close",yl="e-dlg-target",ka="e-scroll-disabled",E4="e-device",q0="e-dlg-fullscreen",D4="e-dlg-closeicon-btn",x4="e-popup-open",T4="Information",A4="e-scroll-disabled",L4="e-alert-dialog",N4="e-confirm-dialog",RE="e-dlg-resizable",dp="e-restrict-left",O4="e-resize-viewport",HE="user action",QJ=function(n){function t(e,i){var r=n.call(this,e,i)||this;return r.needsID=!0,r}return kE(t,n),t.prototype.render=function(){this.initialize(),this.initRender(),this.wireEvents(),"100%"===this.width&&(this.element.style.width=""),""!==this.minHeight&&(this.element.style.minHeight=Re(this.minHeight)),this.enableResize&&(this.setResize(),this.isModal&&(this.isModelResize=!0),"None"===this.animationSettings.effect&&this.getMinHeight()),this.renderComplete()},t.prototype.initializeValue=function(){this.dlgClosedBy=HE},t.prototype.preRender=function(){var e=this;if(this.initializeValue(),this.headerContent=null,this.allowMaxHeight=!0,this.preventVisibility=!0,this.clonedEle=this.element.cloneNode(!0),this.closeIconClickEventHandler=function(s){e.dlgClosedBy="close icon",e.hide(s)},this.dlgOverlayClickEventHandler=function(s){e.dlgClosedBy="overlayClick",s.preventFocus=!1,e.trigger("overlayClick",s,function(o){o.preventFocus||e.focusContent(),e.dlgClosedBy=HE})},this.l10n=new ho("dialog",{close:"Close"},this.locale),this.checkPositionData(),m(this.target)){var r=this.isProtectedOnChange;this.isProtectedOnChange=!0,this.target=document.body,this.isProtectedOnChange=r}},t.prototype.updatePersistData=function(){this.enablePersistence&&this.setProperties({width:parseFloat(this.element.style.width),height:parseFloat(this.element.style.height),position:{X:parseFloat(this.dragObj.element.style.left),Y:parseFloat(this.dragObj.element.style.top)}},!0)},t.prototype.isNumberValue=function(e){return/^[-+]?\d*\.?\d+$/.test(e)},t.prototype.checkPositionData=function(){if(!m(this.position)){if(!m(this.position.X)&&"number"!=typeof this.position.X&&this.isNumberValue(this.position.X)){var i=this.isProtectedOnChange;this.isProtectedOnChange=!0,this.position.X=parseFloat(this.position.X),this.isProtectedOnChange=i}m(this.position.Y)||"number"==typeof this.position.Y||this.isNumberValue(this.position.Y)&&(i=this.isProtectedOnChange,this.isProtectedOnChange=!0,this.position.Y=parseFloat(this.position.Y),this.isProtectedOnChange=i)}},t.prototype.getEle=function(e,i){for(var r=void 0,s=0;s=0&&t[e])xJ(t[e]);else if(""!==t[e].trim()){var i=mi("div",{className:"e-icons "+Wg+" e-"+t[e]});_i.appendChild(i)}cp=n.minHeight,CE=n.minWidth,mh=n.maxWidth,vh=n.maxHeight,n.proxy&&n.proxy.element&&n.proxy.element.classList.contains("e-dialog")?y4(n.proxy):y4()}({element:this.element,direction:r,minHeight:parseInt(e.slice(0,i.indexOf("p")),10),maxHeight:this.targetEle.clientHeight,minWidth:parseInt(i.slice(0,i.indexOf("p")),10),maxWidth:this.targetEle.clientWidth,boundary:this.target===document.body?null:this.targetEle,resizeBegin:this.onResizeStart.bind(this),resizeComplete:this.onResizeComplete.bind(this),resizing:this.onResizing.bind(this),proxy:this}),this.wireWindowResizeEvent()}else M4(),this.unWireWindowResizeEvent(),this.element.classList.remove(this.isModal?dp:O4),this.element.classList.remove(RE)},t.prototype.getFocusElement=function(e){var r=e.querySelectorAll('input,select,textarea,button:enabled,a,[contenteditable="true"],[tabindex]');return{element:r[r.length-1]}},t.prototype.keyDown=function(e){var i=this;if(9===e.keyCode&&this.isModal){var r=void 0;m(this.btnObj)||(r=this.btnObj[this.btnObj.length-1]),m(this.btnObj)&&!m(this.ftrTemplateContent)&&(r=this.getFocusElement(this.ftrTemplateContent)),m(this.btnObj)&&m(this.ftrTemplateContent)&&!m(this.contentEle)&&(r=this.getFocusElement(this.contentEle)),!m(r)&&document.activeElement===r.element&&!e.shiftKey&&(e.preventDefault(),this.focusableElements(this.element).focus()),document.activeElement===this.focusableElements(this.element)&&e.shiftKey&&(e.preventDefault(),m(r)||r.element.focus())}var h,s=document.activeElement,o=["input","textarea"].indexOf(s.tagName.toLowerCase())>-1,a=!1;if(o||(a=s.hasAttribute("contenteditable")&&"true"===s.getAttribute("contenteditable")),27===e.keyCode&&this.closeOnEscape){this.dlgClosedBy="escape";var l=document.querySelector(".e-popup-open:not(.e-dialog)");!m(l)&&!l.classList.contains("e-toolbar-pop")||this.hide(e)}(13===e.keyCode&&!e.ctrlKey&&"textarea"!==s.tagName.toLowerCase()&&o&&!m(this.primaryButtonEle)||13===e.keyCode&&e.ctrlKey&&("textarea"===s.tagName.toLowerCase()||a)&&!m(this.primaryButtonEle))&&this.buttons.some(function(d,u){h=u;var p=d.buttonModel;return!m(p)&&!0===p.isPrimary})&&"function"==typeof this.buttons[h].click&&setTimeout(function(){i.buttons[h].click.call(i,e)})},t.prototype.initialize=function(){m(this.target)||(this.targetEle="string"==typeof this.target?document.querySelector(this.target):this.target),this.isBlazorServerRender()||V([this.element],Q0),X.isDevice&&V([this.element],E4),this.isBlazorServerRender()||this.setCSSClass(),this.setMaxHeight()},t.prototype.initRender=function(){var e=this;if(this.initialRender=!0,this.isBlazorServerRender()||Fe(this.element,{role:"dialog"}),1e3===this.zIndex?(this.setzIndex(this.element,!1),this.calculatezIndex=!0):this.calculatezIndex=!1,this.setTargetContent(),""!==this.header&&!m(this.header)&&this.setHeader(),this.renderCloseIcon(),this.setContent(),""===this.footerTemplate||m(this.footerTemplate)?!m(this.buttons[0])&&!m(this.buttons[0].buttonModel)&&this.setButton():this.setFooterTemplate(),this.allowDragging&&!m(this.headerContent)&&this.setAllowDragging(),Fe(this.element,{"aria-modal":this.isModal?"true":"false"}),this.isModal&&this.setIsModal(),!0!==this.element.classList.contains(L4)&&!0!==this.element.classList.contains(N4)&&!m(this.element.parentElement)){var i=this.isModal?this.dlgContainer.parentElement:this.element.parentElement;this.refElement=this.createElement("div",{className:"e-dlg-ref-element"}),i.insertBefore(this.refElement,this.isModal?this.dlgContainer:this.element)}if(m(this.targetEle)||this.targetEle.appendChild(this.isModal?this.dlgContainer:this.element),this.popupObj=new ac(this.element,{height:this.height,width:this.width,zIndex:this.zIndex,relateTo:this.target,actionOnScroll:"none",enableRtl:this.enableRtl,open:function(o){var a={container:e.isModal?e.dlgContainer:e.element,element:e.element,target:e.target,preventFocus:!1};e.enableResize&&e.resetResizeIcon(),e.trigger("open",a,function(l){l.preventFocus||e.focusContent()})},close:function(o){e.isModal&&V([e.dlgOverlay],"e-fade"),e.unBindEvent(e.element),e.isModal&&(e.dlgContainer.style.display="none"),e.trigger("close",e.closeArgs);var a=document.activeElement;!m(a)&&!m(a.blur)&&a.blur(),!m(e.storeActiveElement)&&!m(e.storeActiveElement.focus)&&e.storeActiveElement.focus()}}),this.positionChange(),this.setEnableRTL(),this.isBlazorServerRender()||(V([this.element],"e-popup-close"),this.isModal&&this.setOverlayZindex()),this.visible){if(this.show(),this.isModal){var r=this.getTargetContainer(this.target);r instanceof Element&&"rtl"===window.getComputedStyle(r).getPropertyValue("direction")&&this.setPopupPosition()}}else this.isModal&&(this.dlgOverlay.style.display="none");this.initialRender=!1},t.prototype.getTargetContainer=function(e){var i=null;if("string"==typeof e)if(e.startsWith("#"))i=document.getElementById(e.substring(1));else if(e.startsWith(".")){var r=document.getElementsByClassName(e.substring(1));i=r.length>0?r[0]:null}else!(e instanceof HTMLElement)&&e!==document.body&&(i=document.querySelector(e));else e instanceof HTMLElement&&(i=e);return i},t.prototype.resetResizeIcon=function(){var e=this.getMinHeight();if(this.targetEle.offsetHeight0&&("function"==typeof this.buttons[e].click&&E.add(s[e],"click",this.buttons[e].click,this),"object"==typeof this.buttons[e].click&&E.add(s[e],"click",this.buttonClickHandler.bind(this,e),this)),!this.isBlazorServerRender()&&!m(this.ftrTemplateContent)&&(this.btnObj[e].appendTo(this.ftrTemplateContent.children[e]),this.buttons[e].isFlat&&this.btnObj[e].element.classList.add("e-flat"),this.primaryButtonEle=this.element.getElementsByClassName("e-primary")[0]))},t.prototype.buttonClickHandler=function(e){this.trigger("buttons["+e+"].click",{})},t.prototype.setContent=function(){this.contentEle=this.createElement("div",{className:"e-dlg-content",id:this.element.id+"_dialog-content"}),Fe(this.element,this.headerEle?{"aria-describedby":this.element.id+"_title "+this.element.id+"_dialog-content"}:{"aria-describedby":this.element.id+"_dialog-content"}),this.innerContentElement?this.contentEle.appendChild(this.innerContentElement):(!m(this.content)&&""!==this.content||!this.initialRender)&&(("string"!=typeof this.content||ce())&&this.content instanceof HTMLElement?this.contentEle.appendChild(this.content):this.setTemplate(this.content,this.contentEle,"content")),m(this.headerContent)?this.element.insertBefore(this.contentEle,this.element.children[0]):this.element.insertBefore(this.contentEle,this.element.children[1]),"auto"===this.height&&(!this.isBlazorServerRender()&&X.isIE&&""===this.element.style.width&&!m(this.width)&&(this.element.style.width=Re(this.width)),this.setMaxHeight())},t.prototype.setTemplate=function(e,i,r){var s,o,a;o=i.classList.contains(w4)?this.element.id+"header":i.classList.contains(G0)?this.element.id+"footerTemplate":this.element.id+"content",m(e.outerHTML)?("string"==typeof e||"string"!=typeof e||ce()&&!this.isStringTemplate)&&("string"==typeof e&&(e=this.sanitizeHelper(e)),this.isVue||"string"!=typeof e?(s=ii(e),a=e):i.innerHTML=e):i.appendChild(e);var l=[];if(!m(s)){for(var c=0,d=s({},this,r,o,!(ce()&&!this.isStringTemplate&&0===a.indexOf("
Blazor"))||this.isStringTemplate);c/g,"");(this.element.children.length>0||i)&&(this.innerContentElement=document.createDocumentFragment(),[].slice.call(this.element.childNodes).forEach(function(r){8!==r.nodeType&&e.innerContentElement.appendChild(r)}))}},t.prototype.setHeader=function(){this.headerEle?this.headerEle.innerHTML="":this.headerEle=this.createElement("div",{id:this.element.id+"_title",className:w4}),this.createHeaderContent(),this.headerContent.appendChild(this.headerEle),this.setTemplate(this.header,this.headerEle,"header"),Fe(this.element,{"aria-describedby":this.element.id+"_title"}),Fe(this.element,{"aria-labelledby":this.element.id+"_dialog-header"}),this.element.insertBefore(this.headerContent,this.element.children[0]),this.allowDragging&&!m(this.headerContent)&&this.setAllowDragging()},t.prototype.setFooterTemplate=function(){this.ftrTemplateContent?this.ftrTemplateContent.innerHTML="":this.ftrTemplateContent=this.createElement("div",{className:G0}),""===this.footerTemplate||m(this.footerTemplate)?this.ftrTemplateContent.innerHTML=this.buttonContent.join(""):this.setTemplate(this.footerTemplate,this.ftrTemplateContent,"footerTemplate"),this.element.appendChild(this.ftrTemplateContent)},t.prototype.createHeaderContent=function(){m(this.headerContent)&&(this.headerContent=this.createElement("div",{id:this.element.id+"_dialog-header",className:zE}))},t.prototype.renderCloseIcon=function(){this.showCloseIcon&&(this.closeIcon=this.createElement("button",{className:D4,attrs:{type:"button"}}),this.closeIconBtnObj=new ys({cssClass:"e-flat",iconCss:C4+" e-icons"}),this.closeIconTitle(),m(this.headerContent)?(this.createHeaderContent(),pl([this.closeIcon],this.headerContent),this.element.insertBefore(this.headerContent,this.element.children[0])):pl([this.closeIcon],this.headerContent),this.closeIconBtnObj.appendTo(this.closeIcon))},t.prototype.closeIconTitle=function(){this.l10n.setLocale(this.locale);var e=this.l10n.getConstant("close");this.closeIcon.setAttribute("title",e),this.closeIcon.setAttribute("aria-label",e)},t.prototype.setCSSClass=function(e){e&&(K([this.element],e.split(" ")),this.isModal&&!m(this.dlgContainer)&&K([this.dlgContainer],e.split(" "))),this.cssClass&&(V([this.element],this.cssClass.split(" ")),this.isModal&&!m(this.dlgContainer)&&V([this.dlgContainer],this.cssClass.split(" ")))},t.prototype.setIsModal=function(){this.dlgContainer=this.createElement("div",{className:"e-dlg-container"}),this.setCSSClass(),this.element.classList.remove(x4),this.element.parentNode.insertBefore(this.dlgContainer,this.element),this.dlgContainer.appendChild(this.element),V([this.element],X0),this.dlgOverlay=this.createElement("div",{className:"e-dlg-overlay"}),this.dlgOverlay.style.zIndex=(this.zIndex-1).toString(),this.dlgContainer.appendChild(this.dlgOverlay)},t.prototype.getValidFocusNode=function(e){for(var i,r=0;r0||"a"===i.tagName.toLowerCase()&&i.hasAttribute("href"))&&i.tabIndex>-1&&!i.disabled&&!this.disableElement(i,'[disabled],[aria-disabled="true"],[type="hidden"]'))return i;i=null}return i},t.prototype.focusableElements=function(e){if(!m(e)){var r=e.querySelectorAll('input,select,textarea,button,a,[contenteditable="true"],[tabindex]');return this.getValidFocusNode(r)}return null},t.prototype.getAutoFocusNode=function(e){var i=e.querySelector("."+D4),s=e.querySelectorAll("[autofocus]"),o=this.getValidFocusNode(s);if(ce()&&(this.primaryButtonEle=this.element.getElementsByClassName("e-primary")[0]),m(o)){if(!m(o=this.focusableElements(this.contentEle)))return o;if(!m(this.primaryButtonEle))return this.element.querySelector(".e-primary")}else i=o;return i},t.prototype.disableElement=function(e,i){var r=e?e.matches||e.webkitMatchesSelector||e.msGetRegionContent:null;if(r)for(;e;e=e.parentNode)if(e instanceof Element&&r.call(e,i))return e;return null},t.prototype.focusContent=function(){var e=this.getAutoFocusNode(this.element),i=m(e)?this.element:e,r=X.userAgent;(r.indexOf("MSIE ")>0||r.indexOf("Trident/")>0)&&this.element.focus(),i.focus(),this.unBindEvent(this.element),this.bindEvent(this.element)},t.prototype.bindEvent=function(e){E.add(e,"keydown",this.keyDown,this)},t.prototype.unBindEvent=function(e){E.remove(e,"keydown",this.keyDown)},t.prototype.updateSanitizeContent=function(){this.isBlazorServerRender()||(this.contentEle.innerHTML=this.sanitizeHelper(this.content))},t.prototype.isBlazorServerRender=function(){return ce()&&this.isServerRendered},t.prototype.getModuleName=function(){return"dialog"},t.prototype.onPropertyChanged=function(e,i){if(this.element.classList.contains(Q0))for(var r=0,s=Object.keys(e);r0?this.showCloseIcon||""!==this.header&&!m(this.header)?this.showCloseIcon||he(this.closeIcon):(he(this.headerContent),this.headerContent=null):(this.renderCloseIcon(),this.wireEvents());break;case"locale":this.showCloseIcon&&this.closeIconTitle();break;case"visible":this.visible?this.show():this.hide();break;case"isModal":this.updateIsModal();break;case"height":je(this.element,{height:Re(e.height)}),this.updatePersistData();break;case"width":je(this.element,{width:Re(e.width)}),this.updatePersistData();break;case"zIndex":this.popupObj.zIndex=this.zIndex,this.isModal&&this.setOverlayZindex(this.zIndex),this.element.style.zIndex!==this.zIndex.toString()&&(this.calculatezIndex=!1);break;case"cssClass":this.setCSSClass(i.cssClass);break;case"buttons":this.unWireButtonEvents(),this.destroyButtons(),m(this.ftrTemplateContent)||(he(this.ftrTemplateContent),this.ftrTemplateContent=null),this.footerTemplate="",this.setButton();break;case"allowDragging":this.allowDragging&&!m(this.headerContent)?this.setAllowDragging():this.dragObj.destroy();break;case"target":this.setTarget(e.target);break;case"position":if(this.checkPositionData(),this.isModal){var a=this.position.X,l=this.position.Y;m(i.position)||(m(i.position.X)||(a=i.position.X),m(i.position.Y)||(l=i.position.Y)),this.dlgContainer.classList.contains("e-dlg-"+a+"-"+l)&&this.dlgContainer.classList.remove("e-dlg-"+a+"-"+l)}this.positionChange(),this.updatePersistData();break;case"enableRtl":this.setEnableRTL();break;case"enableResize":this.setResize();break;case"minHeight":""!==this.minHeight&&(this.element.style.minHeight=Re(this.minHeight))}},t.prototype.setTarget=function(e){this.popupObj.relateTo=e,this.target=e,this.targetEle="string"==typeof this.target?document.querySelector(this.target):this.target,this.dragObj&&(this.dragObj.dragArea=this.targetEle),this.setMaxHeight(),this.isModal&&this.updateIsModal(),this.enableResize&&this.setResize()},t.prototype.updateIsModal=function(){if(this.element.setAttribute("aria-modal",this.isModal?"true":"false"),this.isModal)m(this.dlgOverlay)&&(this.setIsModal(),this.element.style.top="0px",this.element.style.left="0px",m(this.targetEle)||this.targetEle.appendChild(this.dlgContainer));else{for(K([this.element],X0),K([document.body],[yl,ka]),he(this.dlgOverlay);this.dlgContainer.firstChild;)this.dlgContainer.parentElement.insertBefore(this.dlgContainer.firstChild,this.dlgContainer);this.dlgContainer.parentElement.removeChild(this.dlgContainer)}this.visible&&this.show(),this.positionChange(),this.isModal&&this.dlgOverlay&&E.add(this.dlgOverlay,"click",this.dlgOverlayClickEventHandler,this)},t.prototype.setzIndex=function(e,i){var r=this.isProtectedOnChange;this.isProtectedOnChange=!0;var s=lc(e);this.zIndex=s>this.zIndex?s:this.zIndex,this.isProtectedOnChange=r,i&&(this.popupObj.zIndex=this.zIndex)},t.prototype.windowResizeHandler=function(){(function AJ(n){mh=n})(this.targetEle.clientWidth),function LJ(n){vh=n}(this.targetEle.clientHeight),this.setMaxHeight()},t.prototype.getPersistData=function(){return this.addOnPersist(["width","height","position"])},t.prototype.removeAllChildren=function(e){for(;e.children[0];)this.removeAllChildren(e.children[0]),e.removeChild(e.children[0])},t.prototype.destroy=function(){if(!this.isDestroyed){var e=[PE,X0,RE,dp,q0,E4],i=["role","aria-modal","aria-labelledby","aria-describedby","aria-grabbed","tabindex","style"];K([this.targetEle],[yl,ka]),!m(this.element)&&this.element.classList.contains(q0)&&K([document.body],[yl,ka]),this.isModal&&K([m(this.targetEle)?document.body:this.targetEle],ka),this.unWireEvents(),this.unWireButtonEvents(),this.destroyButtons(),m(this.closeIconBtnObj)||this.closeIconBtnObj.destroy(),m(this.dragObj)||this.dragObj.destroy(),!m(this.popupObj.element)&&this.popupObj.element.classList.contains("e-popup")&&this.popupObj.destroy(),K([this.element],e),!m(this.cssClass)&&""!==this.cssClass&&K([this.element],this.cssClass.split(" ")),!m(this.refElement)&&!m(this.refElement.parentElement)&&(this.refElement.parentElement.insertBefore(this.isModal?this.dlgContainer:this.element,this.refElement),he(this.refElement),this.refElement=void 0),this.isModal&&(he(this.dlgOverlay),this.dlgContainer.parentNode.insertBefore(this.element,this.dlgContainer),he(this.dlgContainer)),this.element.innerHTML=this.clonedEle.innerHTML;for(var r=0;r0&&""===this.footerTemplate&&this.ftrTemplateContent)for(var e=0;e=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},BE="e-tooltip",B4="e-icons",F4="e-tooltip-close",FE="e-tooltip-wrap",_4="e-tip-content",up="e-arrow-tip",U4="e-arrow-tip-outer",$0="e-arrow-tip-inner",qg="e-tip-bottom",_E="e-tip-top",j4="e-tip-left",UE="e-tip-right",jE="e-popup",$g="e-popup-open",VE="e-popup-close",Z0="e-lib",V4="e-tooltip-popup-container",JJ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return P4(t,n),Gi([I({effect:"FadeIn",duration:150,delay:0})],t.prototype,"open",void 0),Gi([I({effect:"FadeOut",duration:150,delay:0})],t.prototype,"close",void 0),t}(Ee),Sh=function(n){function t(e,i){var r=n.call(this,e,i)||this;return r.mouseMoveEvent=null,r.mouseMoveTarget=null,r.containerElement=null,r.isBodyContainer=!0,r}return P4(t,n),t.prototype.initialize=function(){this.formatPosition(),V([this.element],BE)},t.prototype.formatPosition=function(){var e,i;this.position&&(0===this.position.indexOf("Top")||0===this.position.indexOf("Bottom")?(e=this.position.split(/(?=[A-Z])/),this.tooltipPositionY=e[0],this.tooltipPositionX=e[1]):(i=this.position.split(/(?=[A-Z])/),this.tooltipPositionX=i[0],this.tooltipPositionY=i[1]))},t.prototype.renderArrow=function(){this.setTipClass(this.position);var e=this.createElement("div",{className:up+" "+this.tipClass});e.appendChild(this.createElement("div",{className:U4+" "+this.tipClass})),e.appendChild(this.createElement("div",{className:$0+" "+this.tipClass})),this.tooltipEle.appendChild(e)},t.prototype.setTipClass=function(e){this.tipClass=0===e.indexOf("Right")?j4:0===e.indexOf("Bottom")?_E:0===e.indexOf("Left")?UE:qg},t.prototype.renderPopup=function(e){var i=this.mouseTrail?{top:0,left:0}:this.getTooltipPosition(e);this.tooltipEle.classList.remove(Z0),this.popupObj=new ac(this.tooltipEle,{height:this.height,width:this.width,position:{X:i.left,Y:i.top},enableRtl:this.enableRtl,open:this.openPopupHandler.bind(this),close:this.closePopupHandler.bind(this)})},t.prototype.getScalingFactor=function(e){if(!e)return{x:1,y:1};var i={x:1,y:1},r=e.closest('[style*="transform: scale"]');if(r&&r!==this.tooltipEle&&r.contains(this.tooltipEle)){var a=window.getComputedStyle(r).getPropertyValue("transform").match(/matrix\(([^)]+)\)/)[1].split(",").map(parseFloat);i.x=a[0],i.y=a[3]}return i},t.prototype.getTooltipPosition=function(e){this.tooltipEle.style.display="block";var i=this.element.closest('[style*="zoom"]');i&&(i.contains(this.tooltipEle)||(this.tooltipEle.style.zoom=getComputedStyle(i).zoom));var r=is(e,this.tooltipPositionX,this.tooltipPositionY,!this.isBodyContainer,this.isBodyContainer?null:this.containerElement.getBoundingClientRect()),s=this.getScalingFactor(e),o=this.calculateTooltipOffset(this.position,s.x,s.y),a=this.calculateElementPosition(r,o),c=this.collisionFlipFit(e,a[0],a[1]);return c.left=c.left/s.x,c.top=c.top/s.y,this.tooltipEle.style.display="",c},t.prototype.windowResize=function(){this.reposition(this.findTarget())},t.prototype.reposition=function(e){if(this.popupObj&&e){var i=this.getTooltipPosition(e);this.popupObj.position={X:i.left,Y:i.top},this.popupObj.dataBind()}},t.prototype.openPopupHandler=function(){!this.mouseTrail&&this.needTemplateReposition()&&this.reposition(this.findTarget()),this.trigger("afterOpen",this.tooltipEventArgs),this.tooltipEventArgs=null},t.prototype.closePopupHandler=function(){this.isReact&&!("Click"===this.opensOn||"function"==typeof this.content)&&this.clearTemplate(["content"]),this.clear();var e={type:this.tooltipEventArgs.event?this.tooltipEventArgs.event.type:null,cancel:!1,target:this.tooltipEventArgs.target,event:this.tooltipEventArgs.event?this.tooltipEventArgs.event:null,element:this.tooltipEle,isInteracted:!m(this.tooltipEventArgs.event)};this.trigger("afterClose",e),e=null},t.prototype.calculateTooltipOffset=function(e,i,r){void 0===i&&(i=1),void 0===r&&(r=1);var o,a,l,h,c,d,u,p,s={top:0,left:0};if(1!==i||1!==r){var f=this.tooltipEle.getBoundingClientRect(),g=void 0;l=Math.round(f.width),h=Math.round(f.height),(c=U("."+up,this.tooltipEle))&&(g=c.getBoundingClientRect()),o=c?Math.round(g.width):0,a=c?Math.round(g.height):0,d=this.showTipPointer?0:8,u=a/2+2+(h-this.tooltipEle.clientHeight*r),p=o/2+2+(l-this.tooltipEle.clientWidth*i)}else l=this.tooltipEle.offsetWidth,h=this.tooltipEle.offsetHeight,c=U("."+up,this.tooltipEle),d=this.showTipPointer?0:8,u=(a=c?c.offsetHeight:0)/2+2+(this.tooltipEle.offsetHeight-this.tooltipEle.clientHeight),p=(o=c?c.offsetWidth:0)/2+2+(this.tooltipEle.offsetWidth-this.tooltipEle.clientWidth);switch(this.mouseTrail&&(d+=2),e){case"RightTop":s.left+=o+d,s.top-=h-u;break;case"RightCenter":s.left+=o+d,s.top-=h/2;break;case"RightBottom":s.left+=o+d,s.top-=u;break;case"BottomRight":s.top+=a+d,s.left-=p;break;case"BottomCenter":s.top+=a+d,s.left-=l/2;break;case"BottomLeft":s.top+=a+d,s.left-=l-p;break;case"LeftBottom":s.left-=o+l+d,s.top-=u;break;case"LeftCenter":s.left-=o+l+d,s.top-=h/2;break;case"LeftTop":s.left-=o+l+d,s.top-=h-u;break;case"TopLeft":s.top-=h+a+d,s.left-=l-p;break;case"TopRight":s.top-=h+a+d,s.left-=p;break;default:s.top-=h+a+d,s.left-=l/2}return s.left+=this.offsetX,s.top+=this.offsetY,s},t.prototype.updateTipPosition=function(e){var i=we("."+up+",."+U4+",."+$0,this.tooltipEle);K(i,[qg,_E,j4,UE]),this.setTipClass(e),V(i,this.tipClass)},t.prototype.adjustArrow=function(e,i,r,s){var o=U("."+up,this.tooltipEle);if(!1!==this.showTipPointer&&null!==o){var a,l;this.updateTipPosition(i),this.tooltipEle.style.display="block";var f,h=this.tooltipEle.clientWidth,c=this.tooltipEle.clientHeight,d=U("."+$0,this.tooltipEle),u=o.offsetWidth,p=o.offsetHeight;this.tooltipEle.style.display="",this.tipClass===qg||this.tipClass===_E?(this.tipClass===qg?(l="99.9%",d.style.top="-"+(p-2)+"px"):(l=-(p-1)+"px",d.style.top="-"+(p-6)+"px"),e&&(a=(f="Center"!==r||h>e.offsetWidth||this.mouseTrail)&&"Left"===r||!f&&"End"===this.tipPointerPosition?h-u-2+"px":f&&"Right"===r||!f&&"Start"===this.tipPointerPosition?"2px":!f||"End"!==this.tipPointerPosition&&"Start"!==this.tipPointerPosition?h/2-u/2+"px":"End"===this.tipPointerPosition?e.offsetWidth+(this.tooltipEle.offsetWidth-e.offsetWidth)/2-u/2-2+"px":(this.tooltipEle.offsetWidth-e.offsetWidth)/2-u/2+2+"px")):(this.tipClass===UE?(a="99.9%",d.style.left="-"+(u-2)+"px"):(a=-(u-1)+"px",d.style.left=u-2-u+"px"),l=(f="Center"!==s||c>e.offsetHeight||this.mouseTrail)&&"Top"===s||!f&&"End"===this.tipPointerPosition?c-p-2+"px":f&&"Bottom"===s||!f&&"Start"===this.tipPointerPosition?"2px":c/2-p/2+"px"),o.style.top=l,o.style.left=a}},t.prototype.renderContent=function(e){var i=this,r=U("."+_4,this.tooltipEle);if(this.cssClass&&V([this.tooltipEle],this.cssClass.split(" ")),e&&!m(e.getAttribute("title"))&&(e.setAttribute("data-content",e.getAttribute("title")),e.removeAttribute("title")),m(this.content))e&&!m(e.getAttribute("data-content"))&&(r.innerHTML=e.getAttribute("data-content"));else if(r.innerHTML="",this.content instanceof HTMLElement)r.appendChild(this.content);else if("string"==typeof this.content)this.isAngular?this.setProperties({content:Ti.sanitize(this.content)},!0):this.content=this.enableHtmlSanitizer?Ti.sanitize(this.content):this.content,this.enableHtmlParse?(o=ii(this.content)({},this,"content",this.element.id+"content",void 0,void 0,r,this.root))&&Dt(o,r):r.textContent=this.content;else{var o;(o=ii(this.content)({},this,"content",this.element.id+"content",void 0,void 0,r))&&(this.isAngular&&setTimeout(function(){i.reposition(e)},1),Dt(o,r)),this.renderReactTemplates()}},t.prototype.renderCloseIcon=function(){if(this.isSticky){var i=this.createElement("div",{className:B4+" "+F4});this.tooltipEle.appendChild(i),E.add(i,X.touchStartEvent,this.onStickyClose,this)}else{var e=this.tooltipEle.querySelector("."+B4+"."+F4);e&>(e)}},t.prototype.addDescribedBy=function(e,i){var r=(e.getAttribute("aria-describedby")||"").split(/\s+/);r.indexOf(i)<0&&r.push(i),Fe(e,{"aria-describedby":r.join(" ").trim(),"data-tooltip-id":i})},t.prototype.removeDescribedBy=function(e){var i=e.getAttribute("data-tooltip-id"),r=(e.getAttribute("aria-describedby")||"").split(/\s+/),s=r.indexOf(i);-1!==s&&r.splice(s,1),e.removeAttribute("data-tooltip-id");var o=r.join(" ").trim();o?e.setAttribute("aria-describedby",o):e.removeAttribute("aria-describedby")},t.prototype.tapHoldHandler=function(e){clearTimeout(this.autoCloseTimer),this.targetHover(e.originalEvent)},t.prototype.touchEndHandler=function(){var e=this;this.isSticky||(this.autoCloseTimer=setTimeout(function(){e.close()},1500))},t.prototype.targetClick=function(e){var i;!m(i=this.target?J(e.target,this.target):this.element)&&(null===i.getAttribute("data-tooltip-id")?this.targetHover(e):this.isSticky||this.hideTooltip(this.animation.close,e,i))},t.prototype.targetHover=function(e){var i;if(!(m(i=this.target?J(e.target,this.target):this.element)||null!==i.getAttribute("data-tooltip-id")&&0===this.closeDelay)){for(var s=0,o=[].slice.call(we('[data-tooltip-id= "'+this.ctrlId+'_content"]',document));s0?this.showTimer=setTimeout(function(){o.mouseTrail&&E.add(i,"mousemove touchstart mouseenter",o.onMouseMove,o),o.popupObj&&(o.popupObj.show(a,i),o.mouseMoveEvent&&o.mouseTrail&&o.onMouseMove(o.mouseMoveEvent))},this.openDelay):this.popupObj&&this.popupObj.show(a,i)}s&&this.wireMouseEvents(s,i)},t.prototype.needTemplateReposition=function(){return!m(this.viewContainerRef)&&"string"!=typeof this.viewContainerRef||this.isReact},t.prototype.checkCollision=function(e,i,r){var s={left:i,top:r,position:this.position,horizontal:this.tooltipPositionX,vertical:this.tooltipPositionY},o=oc(this.tooltipEle,this.checkCollideTarget(),i,r);return o.length>0&&(s.horizontal=o.indexOf("left")>=0?"Right":o.indexOf("right")>=0?"Left":this.tooltipPositionX,s.vertical=o.indexOf("top")>=0?"Bottom":o.indexOf("bottom")>=0?"Top":this.tooltipPositionY),s},t.prototype.calculateElementPosition=function(e,i){return[this.isBodyContainer?e.left+i.left:e.left-this.containerElement.getBoundingClientRect().left+i.left+window.pageXOffset+this.containerElement.scrollLeft,this.isBodyContainer?e.top+i.top:e.top-this.containerElement.getBoundingClientRect().top+i.top+window.pageYOffset+this.containerElement.scrollTop]},t.prototype.collisionFlipFit=function(e,i,r){var s=this.checkCollision(e,i,r),o=s.position;if(this.tooltipPositionY!==s.vertical&&(o=0===this.position.indexOf("Bottom")||0===this.position.indexOf("Top")?s.vertical+this.tooltipPositionX:this.tooltipPositionX+s.vertical),this.tooltipPositionX!==s.horizontal&&(0===o.indexOf("Left")&&(s.vertical="LeftTop"===o||"LeftCenter"===o?"Top":"Bottom",o=s.vertical+"Left"),0===o.indexOf("Right")&&(s.vertical="RightTop"===o||"RightCenter"===o?"Top":"Bottom",o=s.vertical+"Right"),s.horizontal=this.tooltipPositionX),this.tooltipEventArgs={type:null,cancel:!1,target:e,event:null,element:this.tooltipEle,collidedPosition:o},this.trigger("beforeCollision",this.tooltipEventArgs),this.tooltipEventArgs.cancel)o=this.position;else{var a=s.vertical,l=s.horizontal;if(s.position!==o){var h=is(e,l,a,!this.isBodyContainer,this.isBodyContainer?null:this.containerElement.getBoundingClientRect());this.adjustArrow(e,o,l,a);var c=this.getScalingFactor(e),d=this.calculateTooltipOffset(o,c.x,c.y);d.top-=this.getOffSetPosition("TopBottom",o,this.offsetY),d.left-=this.getOffSetPosition("RightLeft",o,this.offsetX),s.position=o;var u=this.calculateElementPosition(h,d);s.left=u[0],s.top=u[1]}else this.adjustArrow(e,o,l,a)}var p={left:s.left,top:s.top},f=this.isBodyContainer?uE(this.tooltipEle,this.checkCollideTarget(),{X:!0,Y:this.windowCollision},p):p;this.tooltipEle.style.display="block";var g=U("."+up,this.tooltipEle);if(this.showTipPointer&&null!=g&&(0===o.indexOf("Bottom")||0===o.indexOf("Top"))){var v=parseInt(g.style.left,10)-(f.left-s.left);v<0?v=0:v+g.offsetWidth>this.tooltipEle.clientWidth&&(v=this.tooltipEle.clientWidth-g.offsetWidth),g.style.left=v.toString()+"px"}return this.tooltipEle.style.display="",p.left=f.left,p.top=f.top,p},t.prototype.getOffSetPosition=function(e,i,r){return-1!==e.indexOf(this.position.split(/(?=[A-Z])/)[0])&&-1!==e.indexOf(i.split(/(?=[A-Z])/)[0])?2*r:0},t.prototype.checkCollideTarget=function(){return!this.windowCollision&&this.target?this.element:null},t.prototype.hideTooltip=function(e,i,r){var s=this;this.closeDelay>0?(clearTimeout(this.hideTimer),clearTimeout(this.showTimer),this.hideTimer=setTimeout(function(){s.closeDelay&&s.tooltipEle&&s.isTooltipOpen||s.tooltipHide(e,i,r)},this.closeDelay)):this.tooltipHide(e,i,r)},t.prototype.tooltipHide=function(e,i,r){var o,s=this;o=i?this.target?r||i.target:this.element:U('[data-tooltip-id= "'+this.ctrlId+'_content"]',document),this.tooltipEventArgs={type:i?i.type:null,cancel:!1,target:o,event:i||null,element:this.tooltipEle,isInteracted:!m(i)},this.trigger("beforeClose",this.tooltipEventArgs,function(a){a.cancel?s.isHidden=!1:(s.mouseMoveBeforeRemove(),s.popupHide(e,o,i))})},t.prototype.popupHide=function(e,i,r){i&&r&&this.restoreElement(i),this.isHidden=!0;var s={name:this.animation.close.effect,duration:e.duration,delay:e.delay,timingFunction:"easeIn"};"None"===e.effect&&(s=void 0),this.popupObj&&this.popupObj.hide(s)},t.prototype.restoreElement=function(e){this.unwireMouseEvents(e),m(e.getAttribute("data-content"))||(e.setAttribute("title",e.getAttribute("data-content")),e.removeAttribute("data-content")),this.removeDescribedBy(e)},t.prototype.clear=function(){var e=this.findTarget();e&&this.restoreElement(e),this.tooltipEle&&(K([this.tooltipEle],VE),V([this.tooltipEle],$g)),this.isHidden&&(this.popupObj&&this.popupObj.destroy(),this.tooltipEle&>(this.tooltipEle),this.tooltipEle=null,this.popupObj=null)},t.prototype.tooltipHover=function(){this.tooltipEle&&(this.isTooltipOpen=!0)},t.prototype.tooltipMouseOut=function(e){this.isTooltipOpen=!1,this.hideTooltip(this.animation.close,e,this.findTarget())},t.prototype.onMouseOut=function(e){var i=e.relatedTarget;if(i&&!this.mouseTrail){var r=J(i,"."+FE+"."+Z0+"."+jE);r?E.add(r,"mouseleave",this.tooltipElementMouseOut,this):(this.hideTooltip(this.animation.close,e,this.findTarget()),0===this.closeDelay&&("None"===this.animation.close.effect||this.isReact&&"string"!=typeof this.content)&&this.clear())}else this.hideTooltip(this.animation.close,e,this.findTarget()),this.clear();this.popupObj&&!this.popupObj.element.classList.contains($g)&&this.clear()},t.prototype.tooltipElementMouseOut=function(e){this.hideTooltip(this.animation.close,e,this.findTarget()),E.remove(this.element,"mouseleave",this.tooltipElementMouseOut),this.clear()},t.prototype.onStickyClose=function(){this.close()},t.prototype.onMouseMove=function(e){var i=0,r=0;e.type.indexOf("touch")>-1?(e.preventDefault(),i=e.touches[0].pageX,r=e.touches[0].pageY):(i=e.pageX,r=e.pageY),Hs.stop(this.tooltipEle),K([this.tooltipEle],VE),V([this.tooltipEle],$g),this.adjustArrow(e.target,this.position,this.tooltipPositionX,this.tooltipPositionY);var s=this.getScalingFactor(e.target),o=this.calculateTooltipOffset(this.position,s.x,s.y),h=this.checkCollision(e.target,i+o.left+this.offsetX,r+o.top+this.offsetY);if(this.tooltipPositionX!==h.horizontal||this.tooltipPositionY!==h.vertical){var c=0===this.position.indexOf("Bottom")||0===this.position.indexOf("Top")?h.vertical+h.horizontal:h.horizontal+h.vertical;h.position=c,this.adjustArrow(e.target,h.position,h.horizontal,h.vertical);var d=this.calculateTooltipOffset(h.position,s.x,s.y);h.left=i+d.left-this.offsetX,h.top=r+d.top-this.offsetY}this.tooltipEle.style.left=h.left+"px",this.tooltipEle.style.top=h.top+"px"},t.prototype.keyDown=function(e){this.tooltipEle&&27===e.keyCode&&this.close()},t.prototype.touchEnd=function(e){this.tooltipEle&&null===J(e.target,"."+BE)&&!this.isSticky&&this.close()},t.prototype.scrollHandler=function(e){this.tooltipEle&&!this.isSticky&&!J(e.target,"."+FE+"."+Z0+"."+jE)&&!this.isSticky&&this.close()},t.prototype.render=function(){this.initialize(),this.wireEvents(this.opensOn),this.renderComplete()},t.prototype.preRender=function(){this.tipClass=qg,this.tooltipPositionX="Center",this.tooltipPositionY="Top",this.isHidden=!0},t.prototype.wireEvents=function(e){for(var r=0,s=this.getTriggerList(e);r0)for(var i=0,r=e;i0)for(var i=0,r=e;i0&&this.condition&&-1!==this.condition.indexOf("not")&&(e[s].condition=e[s].condition?e[s].condition+"not":"not"),i=e[s].validate(t),r){if(!i)return!1}else if(i)return!0;return r},n.prototype.toJson=function(){var t,e;if(this.isComplex){t=[],e=this.predicates;for(var i=0;ie.length-3?(e=e.substring(0,e.length-1),n.endsWith(n.toLowerCase(t),n.toLowerCase(e))):(e.lastIndexOf("%")!==e.indexOf("%")&&e.lastIndexOf("%")>e.indexOf("%")+1&&(e=e.substring(e.indexOf("%")+1,e.lastIndexOf("%"))),-1!==t.indexOf(e)))},n.fnSort=function(t){return"ascending"===(t=t?n.toLowerCase(t):"ascending")?this.fnAscending:this.fnDescending},n.fnAscending=function(t,e){return m(t)&&m(e)||null==e?-1:"string"==typeof t?t.localeCompare(e):null==t?1:t-e},n.fnDescending=function(t,e){return m(t)&&m(e)?-1:null==e?1:"string"==typeof t?-1*t.localeCompare(e):null==t?-1:e-t},n.extractFields=function(t,e){for(var i={},r=0;r0||e.length>0;)o=t.length>0&&e.length>0?r?r(this.getVal(t,0,i),this.getVal(e,0,i),t[0],e[0])<=0?t:e:t[0][i]0?t:e,s.push(o.shift());return s},n.getVal=function(t,e,i){return i?this.getObject(i,t[e]):t[e]},n.toLowerCase=function(t){return t?"string"==typeof t?t.toLowerCase():t.toString():0===t||!1===t?t.toString():""},n.callAdaptorFunction=function(t,e,i,r){if(e in t){var s=t[e](i,r);m(s)||(i=s)}return i},n.getAddParams=function(t,e,i){var r={};return n.callAdaptorFunction(t,"addParams",{dm:e,query:i,params:i?i.params:[],reqParams:r}),r},n.isPlainObject=function(t){return!!t&&t.constructor===Object},n.isCors=function(){var t=null;try{t=new window.XMLHttpRequest}catch{}return!!t&&"withCredentials"in t},n.getGuid=function(t){var i;return(t||"")+"00000000-0000-4000-0000-000000000000".replace(/0/g,function(r,s){if("crypto"in window&&"getRandomValues"in crypto){var o=new Uint8Array(1);window.crypto.getRandomValues(o),i=o[0]%16|0}else i=16*Math.random()|0;return"0123456789abcdef"[19===s?3&i|8:i]})},n.isNull=function(t){return null==t},n.getItemFromComparer=function(t,e,i){var r,s,o,a=0,l="string"==typeof n.getVal(t,0,e);if(t.length)for(;m(r)&&a0&&(r=s,o=t[a]));return o},n.distinct=function(t,e,i){i=!m(i)&&i;var s,r=[],o={};return t.forEach(function(a,l){(s="object"==typeof t[l]?n.getVal(t,l,e):t[l])in o||(r.push(i?t[l]:s),o[s]=1)}),r},n.processData=function(t,e){var i=this.prepareQuery(t),r=new nt(e);t.requiresCounts&&i.requiresCount();var s=r.executeLocal(i),o={result:t.requiresCounts?s.result:s,count:s.count,aggregates:JSON.stringify(s.aggregates)};return t.requiresCounts?o:s},n.prepareQuery=function(t){var e=this,i=new jt;return t.select&&i.select(t.select),t.where&&n.parse.parseJson(t.where).filter(function(o){if(m(o.condition))i.where(o.field,o.operator,o.value,o.ignoreCase,o.ignoreAccent);else{var a=[];o.field?a.push(new Ss(o.field,o.operator,o.value,o.ignoreCase,o.ignoreAccent)):a=a.concat(e.getPredicate(o.predicates)),"or"===o.condition?i.where(Ss.or(a)):"and"===o.condition&&i.where(Ss.and(a))}}),t.search&&n.parse.parseJson(t.search).filter(function(o){return i.search(o.key,o.fields,o.operator,o.ignoreCase,o.ignoreAccent)}),t.aggregates&&t.aggregates.filter(function(o){return i.aggregate(o.type,o.field)}),t.sorted&&t.sorted.filter(function(o){return i.sortBy(o.name,o.direction)}),t.skip&&i.skip(t.skip),t.take&&i.take(t.take),t.group&&t.group.filter(function(o){return i.group(o)}),i},n.getPredicate=function(t){for(var e=[],i=0;i":"greaterthan","<=":"lessthanorequal",">=":"greaterthanorequal","==":"equal","!=":"notequal","*=":"contains","$=":"endswith","^=":"startswith"},n.odBiOperator={"<":" lt ",">":" gt ","<=":" le ",">=":" ge ","==":" eq ","!=":" ne ",lessthan:" lt ",lessthanorequal:" le ",greaterthan:" gt ",greaterthanorequal:" ge ",equal:" eq ",notequal:" ne "},n.odUniOperator={"$=":"endswith","^=":"startswith","*=":"substringof",endswith:"endswith",startswith:"startswith",contains:"substringof",doesnotendwith:"not endswith",doesnotstartwith:"not startswith",doesnotcontain:"not substringof",wildcard:"wildcard",like:"like"},n.odv4UniOperator={"$=":"endswith","^=":"startswith","*=":"contains",endswith:"endswith",startswith:"startswith",contains:"contains",doesnotendwith:"not endswith",doesnotstartwith:"not startswith",doesnotcontain:"not contains",wildcard:"wildcard",like:"like"},n.diacritics={"\u24b6":"A",\uff21:"A",\u00c0:"A",\u00c1:"A",\u00c2:"A",\u1ea6:"A",\u1ea4:"A",\u1eaa:"A",\u1ea8:"A",\u00c3:"A",\u0100:"A",\u0102:"A",\u1eb0:"A",\u1eae:"A",\u1eb4:"A",\u1eb2:"A",\u0226:"A",\u01e0:"A",\u00c4:"A",\u01de:"A",\u1ea2:"A",\u00c5:"A",\u01fa:"A",\u01cd:"A",\u0200:"A",\u0202:"A",\u1ea0:"A",\u1eac:"A",\u1eb6:"A",\u1e00:"A",\u0104:"A",\u023a:"A",\u2c6f:"A",\ua732:"AA",\u00c6:"AE",\u01fc:"AE",\u01e2:"AE",\ua734:"AO",\ua736:"AU",\ua738:"AV",\ua73a:"AV",\ua73c:"AY","\u24b7":"B",\uff22:"B",\u1e02:"B",\u1e04:"B",\u1e06:"B",\u0243:"B",\u0182:"B",\u0181:"B","\u24b8":"C",\uff23:"C",\u0106:"C",\u0108:"C",\u010a:"C",\u010c:"C",\u00c7:"C",\u1e08:"C",\u0187:"C",\u023b:"C",\ua73e:"C","\u24b9":"D",\uff24:"D",\u1e0a:"D",\u010e:"D",\u1e0c:"D",\u1e10:"D",\u1e12:"D",\u1e0e:"D",\u0110:"D",\u018b:"D",\u018a:"D",\u0189:"D",\ua779:"D",\u01f1:"DZ",\u01c4:"DZ",\u01f2:"Dz",\u01c5:"Dz","\u24ba":"E",\uff25:"E",\u00c8:"E",\u00c9:"E",\u00ca:"E",\u1ec0:"E",\u1ebe:"E",\u1ec4:"E",\u1ec2:"E",\u1ebc:"E",\u0112:"E",\u1e14:"E",\u1e16:"E",\u0114:"E",\u0116:"E",\u00cb:"E",\u1eba:"E",\u011a:"E",\u0204:"E",\u0206:"E",\u1eb8:"E",\u1ec6:"E",\u0228:"E",\u1e1c:"E",\u0118:"E",\u1e18:"E",\u1e1a:"E",\u0190:"E",\u018e:"E","\u24bb":"F",\uff26:"F",\u1e1e:"F",\u0191:"F",\ua77b:"F","\u24bc":"G",\uff27:"G",\u01f4:"G",\u011c:"G",\u1e20:"G",\u011e:"G",\u0120:"G",\u01e6:"G",\u0122:"G",\u01e4:"G",\u0193:"G",\ua7a0:"G",\ua77d:"G",\ua77e:"G","\u24bd":"H",\uff28:"H",\u0124:"H",\u1e22:"H",\u1e26:"H",\u021e:"H",\u1e24:"H",\u1e28:"H",\u1e2a:"H",\u0126:"H",\u2c67:"H",\u2c75:"H",\ua78d:"H","\u24be":"I",\uff29:"I",\u00cc:"I",\u00cd:"I",\u00ce:"I",\u0128:"I",\u012a:"I",\u012c:"I",\u0130:"I",\u00cf:"I",\u1e2e:"I",\u1ec8:"I",\u01cf:"I",\u0208:"I",\u020a:"I",\u1eca:"I",\u012e:"I",\u1e2c:"I",\u0197:"I","\u24bf":"J",\uff2a:"J",\u0134:"J",\u0248:"J","\u24c0":"K",\uff2b:"K",\u1e30:"K",\u01e8:"K",\u1e32:"K",\u0136:"K",\u1e34:"K",\u0198:"K",\u2c69:"K",\ua740:"K",\ua742:"K",\ua744:"K",\ua7a2:"K","\u24c1":"L",\uff2c:"L",\u013f:"L",\u0139:"L",\u013d:"L",\u1e36:"L",\u1e38:"L",\u013b:"L",\u1e3c:"L",\u1e3a:"L",\u0141:"L",\u023d:"L",\u2c62:"L",\u2c60:"L",\ua748:"L",\ua746:"L",\ua780:"L",\u01c7:"LJ",\u01c8:"Lj","\u24c2":"M",\uff2d:"M",\u1e3e:"M",\u1e40:"M",\u1e42:"M",\u2c6e:"M",\u019c:"M","\u24c3":"N",\uff2e:"N",\u01f8:"N",\u0143:"N",\u00d1:"N",\u1e44:"N",\u0147:"N",\u1e46:"N",\u0145:"N",\u1e4a:"N",\u1e48:"N",\u0220:"N",\u019d:"N",\ua790:"N",\ua7a4:"N",\u01ca:"NJ",\u01cb:"Nj","\u24c4":"O",\uff2f:"O",\u00d2:"O",\u00d3:"O",\u00d4:"O",\u1ed2:"O",\u1ed0:"O",\u1ed6:"O",\u1ed4:"O",\u00d5:"O",\u1e4c:"O",\u022c:"O",\u1e4e:"O",\u014c:"O",\u1e50:"O",\u1e52:"O",\u014e:"O",\u022e:"O",\u0230:"O",\u00d6:"O",\u022a:"O",\u1ece:"O",\u0150:"O",\u01d1:"O",\u020c:"O",\u020e:"O",\u01a0:"O",\u1edc:"O",\u1eda:"O",\u1ee0:"O",\u1ede:"O",\u1ee2:"O",\u1ecc:"O",\u1ed8:"O",\u01ea:"O",\u01ec:"O",\u00d8:"O",\u01fe:"O",\u0186:"O",\u019f:"O",\ua74a:"O",\ua74c:"O",\u01a2:"OI",\ua74e:"OO",\u0222:"OU","\u24c5":"P",\uff30:"P",\u1e54:"P",\u1e56:"P",\u01a4:"P",\u2c63:"P",\ua750:"P",\ua752:"P",\ua754:"P","\u24c6":"Q",\uff31:"Q",\ua756:"Q",\ua758:"Q",\u024a:"Q","\u24c7":"R",\uff32:"R",\u0154:"R",\u1e58:"R",\u0158:"R",\u0210:"R",\u0212:"R",\u1e5a:"R",\u1e5c:"R",\u0156:"R",\u1e5e:"R",\u024c:"R",\u2c64:"R",\ua75a:"R",\ua7a6:"R",\ua782:"R","\u24c8":"S",\uff33:"S",\u1e9e:"S",\u015a:"S",\u1e64:"S",\u015c:"S",\u1e60:"S",\u0160:"S",\u1e66:"S",\u1e62:"S",\u1e68:"S",\u0218:"S",\u015e:"S",\u2c7e:"S",\ua7a8:"S",\ua784:"S","\u24c9":"T",\uff34:"T",\u1e6a:"T",\u0164:"T",\u1e6c:"T",\u021a:"T",\u0162:"T",\u1e70:"T",\u1e6e:"T",\u0166:"T",\u01ac:"T",\u01ae:"T",\u023e:"T",\ua786:"T",\ua728:"TZ","\u24ca":"U",\uff35:"U",\u00d9:"U",\u00da:"U",\u00db:"U",\u0168:"U",\u1e78:"U",\u016a:"U",\u1e7a:"U",\u016c:"U",\u00dc:"U",\u01db:"U",\u01d7:"U",\u01d5:"U",\u01d9:"U",\u1ee6:"U",\u016e:"U",\u0170:"U",\u01d3:"U",\u0214:"U",\u0216:"U",\u01af:"U",\u1eea:"U",\u1ee8:"U",\u1eee:"U",\u1eec:"U",\u1ef0:"U",\u1ee4:"U",\u1e72:"U",\u0172:"U",\u1e76:"U",\u1e74:"U",\u0244:"U","\u24cb":"V",\uff36:"V",\u1e7c:"V",\u1e7e:"V",\u01b2:"V",\ua75e:"V",\u0245:"V",\ua760:"VY","\u24cc":"W",\uff37:"W",\u1e80:"W",\u1e82:"W",\u0174:"W",\u1e86:"W",\u1e84:"W",\u1e88:"W",\u2c72:"W","\u24cd":"X",\uff38:"X",\u1e8a:"X",\u1e8c:"X","\u24ce":"Y",\uff39:"Y",\u1ef2:"Y",\u00dd:"Y",\u0176:"Y",\u1ef8:"Y",\u0232:"Y",\u1e8e:"Y",\u0178:"Y",\u1ef6:"Y",\u1ef4:"Y",\u01b3:"Y",\u024e:"Y",\u1efe:"Y","\u24cf":"Z",\uff3a:"Z",\u0179:"Z",\u1e90:"Z",\u017b:"Z",\u017d:"Z",\u1e92:"Z",\u1e94:"Z",\u01b5:"Z",\u0224:"Z",\u2c7f:"Z",\u2c6b:"Z",\ua762:"Z","\u24d0":"a",\uff41:"a",\u1e9a:"a",\u00e0:"a",\u00e1:"a",\u00e2:"a",\u1ea7:"a",\u1ea5:"a",\u1eab:"a",\u1ea9:"a",\u00e3:"a",\u0101:"a",\u0103:"a",\u1eb1:"a",\u1eaf:"a",\u1eb5:"a",\u1eb3:"a",\u0227:"a",\u01e1:"a",\u00e4:"a",\u01df:"a",\u1ea3:"a",\u00e5:"a",\u01fb:"a",\u01ce:"a",\u0201:"a",\u0203:"a",\u1ea1:"a",\u1ead:"a",\u1eb7:"a",\u1e01:"a",\u0105:"a",\u2c65:"a",\u0250:"a",\ua733:"aa",\u00e6:"ae",\u01fd:"ae",\u01e3:"ae",\ua735:"ao",\ua737:"au",\ua739:"av",\ua73b:"av",\ua73d:"ay","\u24d1":"b",\uff42:"b",\u1e03:"b",\u1e05:"b",\u1e07:"b",\u0180:"b",\u0183:"b",\u0253:"b","\u24d2":"c",\uff43:"c",\u0107:"c",\u0109:"c",\u010b:"c",\u010d:"c",\u00e7:"c",\u1e09:"c",\u0188:"c",\u023c:"c",\ua73f:"c",\u2184:"c","\u24d3":"d",\uff44:"d",\u1e0b:"d",\u010f:"d",\u1e0d:"d",\u1e11:"d",\u1e13:"d",\u1e0f:"d",\u0111:"d",\u018c:"d",\u0256:"d",\u0257:"d",\ua77a:"d",\u01f3:"dz",\u01c6:"dz","\u24d4":"e",\uff45:"e",\u00e8:"e",\u00e9:"e",\u00ea:"e",\u1ec1:"e",\u1ebf:"e",\u1ec5:"e",\u1ec3:"e",\u1ebd:"e",\u0113:"e",\u1e15:"e",\u1e17:"e",\u0115:"e",\u0117:"e",\u00eb:"e",\u1ebb:"e",\u011b:"e",\u0205:"e",\u0207:"e",\u1eb9:"e",\u1ec7:"e",\u0229:"e",\u1e1d:"e",\u0119:"e",\u1e19:"e",\u1e1b:"e",\u0247:"e",\u025b:"e",\u01dd:"e","\u24d5":"f",\uff46:"f",\u1e1f:"f",\u0192:"f",\ua77c:"f","\u24d6":"g",\uff47:"g",\u01f5:"g",\u011d:"g",\u1e21:"g",\u011f:"g",\u0121:"g",\u01e7:"g",\u0123:"g",\u01e5:"g",\u0260:"g",\ua7a1:"g",\u1d79:"g",\ua77f:"g","\u24d7":"h",\uff48:"h",\u0125:"h",\u1e23:"h",\u1e27:"h",\u021f:"h",\u1e25:"h",\u1e29:"h",\u1e2b:"h",\u1e96:"h",\u0127:"h",\u2c68:"h",\u2c76:"h",\u0265:"h",\u0195:"hv","\u24d8":"i",\uff49:"i",\u00ec:"i",\u00ed:"i",\u00ee:"i",\u0129:"i",\u012b:"i",\u012d:"i",\u00ef:"i",\u1e2f:"i",\u1ec9:"i",\u01d0:"i",\u0209:"i",\u020b:"i",\u1ecb:"i",\u012f:"i",\u1e2d:"i",\u0268:"i",\u0131:"i","\u24d9":"j",\uff4a:"j",\u0135:"j",\u01f0:"j",\u0249:"j","\u24da":"k",\uff4b:"k",\u1e31:"k",\u01e9:"k",\u1e33:"k",\u0137:"k",\u1e35:"k",\u0199:"k",\u2c6a:"k",\ua741:"k",\ua743:"k",\ua745:"k",\ua7a3:"k","\u24db":"l",\uff4c:"l",\u0140:"l",\u013a:"l",\u013e:"l",\u1e37:"l",\u1e39:"l",\u013c:"l",\u1e3d:"l",\u1e3b:"l",\u017f:"l",\u0142:"l",\u019a:"l",\u026b:"l",\u2c61:"l",\ua749:"l",\ua781:"l",\ua747:"l",\u01c9:"lj","\u24dc":"m",\uff4d:"m",\u1e3f:"m",\u1e41:"m",\u1e43:"m",\u0271:"m",\u026f:"m","\u24dd":"n",\uff4e:"n",\u01f9:"n",\u0144:"n",\u00f1:"n",\u1e45:"n",\u0148:"n",\u1e47:"n",\u0146:"n",\u1e4b:"n",\u1e49:"n",\u019e:"n",\u0272:"n",\u0149:"n",\ua791:"n",\ua7a5:"n",\u01cc:"nj","\u24de":"o",\uff4f:"o",\u00f2:"o",\u00f3:"o",\u00f4:"o",\u1ed3:"o",\u1ed1:"o",\u1ed7:"o",\u1ed5:"o",\u00f5:"o",\u1e4d:"o",\u022d:"o",\u1e4f:"o",\u014d:"o",\u1e51:"o",\u1e53:"o",\u014f:"o",\u022f:"o",\u0231:"o",\u00f6:"o",\u022b:"o",\u1ecf:"o",\u0151:"o",\u01d2:"o",\u020d:"o",\u020f:"o",\u01a1:"o",\u1edd:"o",\u1edb:"o",\u1ee1:"o",\u1edf:"o",\u1ee3:"o",\u1ecd:"o",\u1ed9:"o",\u01eb:"o",\u01ed:"o",\u00f8:"o",\u01ff:"o",\u0254:"o",\ua74b:"o",\ua74d:"o",\u0275:"o",\u01a3:"oi",\u0223:"ou",\ua74f:"oo","\u24df":"p",\uff50:"p",\u1e55:"p",\u1e57:"p",\u01a5:"p",\u1d7d:"p",\ua751:"p",\ua753:"p",\ua755:"p","\u24e0":"q",\uff51:"q",\u024b:"q",\ua757:"q",\ua759:"q","\u24e1":"r",\uff52:"r",\u0155:"r",\u1e59:"r",\u0159:"r",\u0211:"r",\u0213:"r",\u1e5b:"r",\u1e5d:"r",\u0157:"r",\u1e5f:"r",\u024d:"r",\u027d:"r",\ua75b:"r",\ua7a7:"r",\ua783:"r","\u24e2":"s",\uff53:"s",\u00df:"s",\u015b:"s",\u1e65:"s",\u015d:"s",\u1e61:"s",\u0161:"s",\u1e67:"s",\u1e63:"s",\u1e69:"s",\u0219:"s",\u015f:"s",\u023f:"s",\ua7a9:"s",\ua785:"s",\u1e9b:"s","\u24e3":"t",\uff54:"t",\u1e6b:"t",\u1e97:"t",\u0165:"t",\u1e6d:"t",\u021b:"t",\u0163:"t",\u1e71:"t",\u1e6f:"t",\u0167:"t",\u01ad:"t",\u0288:"t",\u2c66:"t",\ua787:"t",\ua729:"tz","\u24e4":"u",\uff55:"u",\u00f9:"u",\u00fa:"u",\u00fb:"u",\u0169:"u",\u1e79:"u",\u016b:"u",\u1e7b:"u",\u016d:"u",\u00fc:"u",\u01dc:"u",\u01d8:"u",\u01d6:"u",\u01da:"u",\u1ee7:"u",\u016f:"u",\u0171:"u",\u01d4:"u",\u0215:"u",\u0217:"u",\u01b0:"u",\u1eeb:"u",\u1ee9:"u",\u1eef:"u",\u1eed:"u",\u1ef1:"u",\u1ee5:"u",\u1e73:"u",\u0173:"u",\u1e77:"u",\u1e75:"u",\u0289:"u","\u24e5":"v",\uff56:"v",\u1e7d:"v",\u1e7f:"v",\u028b:"v",\ua75f:"v",\u028c:"v",\ua761:"vy","\u24e6":"w",\uff57:"w",\u1e81:"w",\u1e83:"w",\u0175:"w",\u1e87:"w",\u1e85:"w",\u1e98:"w",\u1e89:"w",\u2c73:"w","\u24e7":"x",\uff58:"x",\u1e8b:"x",\u1e8d:"x","\u24e8":"y",\uff59:"y",\u1ef3:"y",\u00fd:"y",\u0177:"y",\u1ef9:"y",\u0233:"y",\u1e8f:"y",\u00ff:"y",\u1ef7:"y",\u1e99:"y",\u1ef5:"y",\u01b4:"y",\u024f:"y",\u1eff:"y","\u24e9":"z",\uff5a:"z",\u017a:"z",\u1e91:"z",\u017c:"z",\u017e:"z",\u1e93:"z",\u1e95:"z",\u01b6:"z",\u0225:"z",\u0240:"z",\u2c6c:"z",\ua763:"z",\u0386:"\u0391",\u0388:"\u0395",\u0389:"\u0397",\u038a:"\u0399",\u03aa:"\u0399",\u038c:"\u039f",\u038e:"\u03a5",\u03ab:"\u03a5",\u038f:"\u03a9",\u03ac:"\u03b1",\u03ad:"\u03b5",\u03ae:"\u03b7",\u03af:"\u03b9",\u03ca:"\u03b9",\u0390:"\u03b9",\u03cc:"\u03bf",\u03cd:"\u03c5",\u03cb:"\u03c5",\u03b0:"\u03c5",\u03c9:"\u03c9",\u03c2:"\u03c3"},n.fnOperators={equal:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?n.toLowerCase(t)===n.toLowerCase(e):t===e},notequal:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),!n.fnOperators.equal(t,e,i)},lessthan:function(t,e,i){return i?n.toLowerCase(t)n.toLowerCase(e):t>e},lessthanorequal:function(t,e,i){return i?n.toLowerCase(t)<=n.toLowerCase(e):(m(t)&&(t=void 0),t<=e)},greaterthanorequal:function(t,e,i){return i?n.toLowerCase(t)>=n.toLowerCase(e):t>=e},contains:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?!m(t)&&!m(e)&&-1!==n.toLowerCase(t).indexOf(n.toLowerCase(e)):!m(t)&&!m(e)&&-1!==t.toString().indexOf(e)},doesnotcontain:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?!m(t)&&!m(e)&&-1===n.toLowerCase(t).indexOf(n.toLowerCase(e)):!m(t)&&!m(e)&&-1===t.toString().indexOf(e)},isnotnull:function(t){return null!=t},isnull:function(t){return null==t},startswith:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.startsWith(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.startsWith(t,e)},doesnotstartwith:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.notStartsWith(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.notStartsWith(t,e)},like:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.like(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.like(t,e)},isempty:function(t){return void 0===t||""===t},isnotempty:function(t){return void 0!==t&&""!==t},wildcard:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?(t||"boolean"==typeof t)&&e&&"object"!=typeof t&&n.wildCard(n.toLowerCase(t),n.toLowerCase(e)):(t||"boolean"==typeof t)&&e&&n.wildCard(t,e)},endswith:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.endsWith(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.endsWith(t,e)},doesnotendwith:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.notEndsWith(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.notEndsWith(t,e)},processSymbols:function(t){var e=n.operatorSymbols[t];return e?n.fnOperators[e]:n.throwError("Query - Process Operator : Invalid operator")},processOperator:function(t){return n.fnOperators[t]||n.fnOperators.processSymbols(t)}},n.parse={parseJson:function(t){return"string"!=typeof t||!/^[\s]*\[|^[\s]*\{(.)+:/g.test(t)&&-1!==t.indexOf('"')?t instanceof Array?n.parse.iterateAndReviveArray(t):"object"==typeof t&&null!==t&&n.parse.iterateAndReviveJson(t):t=JSON.parse(t,n.parse.jsonReviver),t},iterateAndReviveArray:function(t){for(var e=0;e-1||e.indexOf("z")>-1,o=e.split(/[^0-9.]/);if(s){if(o[5].indexOf(".")>-1){var a=o[5].split(".");o[5]=a[0],o[6]=new Date(e).getUTCMilliseconds().toString()}else o[6]="00";e=n.dateParse.toTimeZone(new Date(parseInt(o[0],10),parseInt(o[1],10)-1,parseInt(o[2],10),parseInt(o[3],10),parseInt(o[4],10),parseInt(o[5]?o[5]:"00",10),parseInt(o[6],10)),n.serverTimezoneOffset,!1)}else{var l=new Date(parseInt(o[0],10),parseInt(o[1],10)-1,parseInt(o[2],10),parseInt(o[3],10),parseInt(o[4],10),parseInt(o[5]?o[5]:"00",10)),h=parseInt(o[6],10),c=parseInt(o[7],10);if(isNaN(h)&&isNaN(c))return l;e.indexOf("+")>-1?l.setHours(l.getHours()-h,l.getMinutes()-c):l.setHours(l.getHours()+h,l.getMinutes()+c),e=n.dateParse.toTimeZone(l,n.serverTimezoneOffset,!1)}null==n.serverTimezoneOffset&&(e=n.dateParse.addSelfOffset(e))}}return e},isJson:function(t){return"string"==typeof t[0]?t:n.parse.parseJson(t)},isGuid:function(t){return null!=/[A-Fa-f0-9]{8}(?:-[A-Fa-f0-9]{4}){3}-[A-Fa-f0-9]{12}/i.exec(t)},replacer:function(t,e){return n.isPlainObject(t)?n.parse.jsonReplacer(t,e):t instanceof Array?n.parse.arrayReplacer(t):t instanceof Date?n.parse.jsonReplacer({val:t},e).val:t},jsonReplacer:function(t,e){for(var i,s=0,o=Object.keys(t);s=0?"+":"-",s=function(a){var l=Math.floor(Math.abs(a));return(l<10?"0":"")+l};return e.getFullYear()+"-"+s(e.getMonth()+1)+"-"+s(e.getDate())+"T"+s(e.getHours())+":"+s(e.getMinutes())+":"+s(e.getSeconds())+r+s(i/60)+":"+s(i%60)}},n}(),Ml=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),BK={GroupGuid:"{271bbba0-1ee7}"},a5=function(){function n(t){this.options={from:"table",requestType:"json",sortBy:"sorted",select:"select",skip:"skip",group:"group",take:"take",search:"search",count:"requiresCounts",where:"where",aggregates:"aggregates",expand:"expand"},this.type=n,this.dataSource=t,this.pvt={}}return n.prototype.processResponse=function(t,e,i,r){return t},n}(),QE=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ml(t,n),t.prototype.processQuery=function(e,i){for(var a,l,p,r=e.dataSource.json.slice(0),s=r.length,o=!0,h={},c=0,d=[],u=[],f=0;f1?e.sort.filter(function(p){return p.fieldName===c})[0]:e.sort[0];s=this.onSortBy(s,d,e.query,!0)}e.page&&(s=this.onPage(s,e.page,e.query)),this.formGroupResult(s,h)}else{for(var o=e.lazyLoad.onDemandGroupInfo,a=o.where.length-1;a>=0;a--)s=this.onWhere(s,o.where[a]);if(e.group.length!==o.level)s=le.group(s,e.group[o.level].fieldName,r,null,null,e.group[o.level].comparer,!0),e.sort.length&&(s=this.onSortBy(s,e.sort[parseInt(o.level.toString(),10)],e.query,!0));else for(a=e.sort.length-1;a>=o.level;a--)s=this.onSortBy(s,e.sort[parseInt(a.toString(),10)],e.query,!1);i=s.length,h=s,s=(s=s.slice(o.skip)).slice(0,o.take),e.group.length!==o.level&&this.formGroupResult(s,h)}return{result:s,count:i}},t.prototype.formGroupResult=function(e,i){if(e.length&&i.length){var r="GroupGuid",s="childLevels",o="level",a="records";e[r]=i[r],e[s]=i[s],e[o]=i[o],e[a]=i[a]}return e},t.prototype.getAggregate=function(e){var i=jt.filterQueries(e.queries,"onAggregates"),r=[];if(i.length)for(var s=void 0,o=0;o=0;l--)a[l]&&(o=i.comparer,le.endsWith(a[l]," desc")&&(o=le.fnSort("descending"),a[l]=a[l].replace(" desc","")),e=le.sort(e,a[l],o));return e}return le.sort(e,s?"key":a,i.comparer)},t.prototype.onGroup=function(e,i,r){if(!e||!e.length)return e;var s=this.getAggregate(r);return le.group(e,le.getValue(i.fieldName,r),s,null,null,i.comparer)},t.prototype.onPage=function(e,i,r){var s=le.getValue(i.pageSize,r),o=(le.getValue(i.pageIndex,r)-1)*s;return e&&e.length?e.slice(o,o+s):e},t.prototype.onRange=function(e,i){return e&&e.length?e.slice(le.getValue(i.start),le.getValue(i.end)):e},t.prototype.onTake=function(e,i){return e&&e.length?e.slice(0,le.getValue(i.nos)):e},t.prototype.onSkip=function(e,i){return e&&e.length?e.slice(le.getValue(i.nos)):e},t.prototype.onSelect=function(e,i){return e&&e.length?le.select(e,le.getValue(i.fieldNames)):e},t.prototype.insert=function(e,i,r,s,o){return m(o)?e.dataSource.json.push(i):e.dataSource.json.splice(o,0,i)},t.prototype.remove=function(e,i,r,s){var a,o=e.dataSource.json;for("object"==typeof r&&!(r instanceof Date)&&(r=le.getObject(i,r)),a=0;a1&&(g="("+g+")"),p.filters.push(g);for(var y=0,S="object"==typeof p.filters[f]?Object.keys(p.filters[f]):[];y-1&&this.formRemoteGroupedData(e[s].items,i+1,r-1);var o="GroupGuid",h="records";return e[o]=BK[o],e.level=i,e.childLevels=r,e[h]=e[0].items.length?this.getGroupedRecords(e,!m(e[0].items[h])):[],e},t.prototype.getGroupedRecords=function(e,i){for(var r=[],o=0;ol.length-3?(l=l.substring(0,l.length-1),o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.endswith:le.odv4UniOperator.endswith):l.lastIndexOf("%")!==l.indexOf("%")&&l.lastIndexOf("%")>l.indexOf("%")+1?(l=l.substring(l.indexOf("%")+1,l.lastIndexOf("%")),o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains):o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains),l="'"+(l=encodeURIComponent(l))+"'";else if("wildcard"===o)if(-1!==l.indexOf("*")){var d=l.split("*"),u=void 0,p=0;if(0!==l.indexOf("*")&&-1===d[0].indexOf("%3f")&&-1===d[0].indexOf("?")&&(u="'"+(u=d[0])+"'",s+=(o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.startswith:le.odv4UniOperator.startswith)+"(",s+=c+",",a&&(s+=a),s+=u+")",p++),l.lastIndexOf("*")!==l.length-1&&-1===d[d.length-1].indexOf("%3f")&&-1===d[d.length-1].indexOf("?")&&(u="'"+(u=d[d.length-1])+"'",p>0&&(s+=" and "),s+=(o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.endswith:le.odv4UniOperator.endswith)+"(",s+=c+",",a&&(s+=a),s+=u+")",p++),d.length>2)for(var f=1;f0&&(s+=" and "),"substringof"===(o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains)||"not substringof"===o){var g=u;u=c,c=g}s+=o+"(",s+=c+",",a&&(s+=a),s+=u+")",p++}0===p?(o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains,(-1!==l.indexOf("?")||-1!==l.indexOf("%3f"))&&(l=-1!==l.indexOf("?")?l.split("?").join(""):l.split("%3f").join("")),l="'"+l+"'"):o="wildcard"}else o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains,(-1!==l.indexOf("?")||-1!==l.indexOf("%3f"))&&(l=-1!==l.indexOf("?")?l.split("?").join(""):l.split("%3f").join("")),l="'"+l+"'";return"substringof"!==o&&"not substringof"!==o||(g=l,l=c,c=g),"wildcard"!==o&&(s+=o+"(",s+=c+",",a&&(s+=a),s+=l+")"),s},t.prototype.addParams=function(e){n.prototype.addParams.call(this,e),delete e.reqParams.params},t.prototype.onComplexPredicate=function(e,i,r){for(var s=[],o=0;o-1;p--)!/\bContent-ID:/i.test(c[p])||!/\bHTTP.+201/.test(c[p])||(l=parseInt(/\bContent-ID: (\d+)/i.exec(c[p])[1],10),o.addedRecords[l]&&(h=le.parse.parseJson(/^\{.+\}/m.exec(c[p])[0]),ze({},o.addedRecords[l],this.processResponse(h))));return o}return null},t.prototype.compareAndRemove=function(e,i,r){var s=this;return m(i)||Object.keys(e).forEach(function(o){o!==r&&"@odata.etag"!==o&&(le.isPlainObject(e[o])?(s.compareAndRemove(e[o],i[o]),0===Object.keys(e[o]).filter(function(l){return"@odata.etag"!==l}).length&&delete e[o]):(e[o]===i[o]||e[o]&&i[o]&&e[o].valueOf()===i[o].valueOf())&&delete e[o])}),e},t}(uc),FK=function(n){function t(){var e=n.call(this)||this;return yt("beforeSend",uc.prototype.beforeSend,e),e}return Ml(t,n),t.prototype.insert=function(e,i,r,s,o){return this.pvt.position=o,this.updateType="add",{url:e.dataSource.insertUrl||e.dataSource.crudUrl||e.dataSource.url,data:JSON.stringify(ze({},{value:i,table:r,action:"insert"},le.getAddParams(this,e,s)))}},t.prototype.remove=function(e,i,r,s,o){return n.prototype.remove.call(this,e,i,r),{type:"POST",url:e.dataSource.removeUrl||e.dataSource.crudUrl||e.dataSource.url,data:JSON.stringify(ze({},{key:r,keyColumn:i,table:s,action:"remove"},le.getAddParams(this,e,o)))}},t.prototype.update=function(e,i,r,s,o){return this.updateType="update",this.updateKey=i,{type:"POST",url:e.dataSource.updateUrl||e.dataSource.crudUrl||e.dataSource.url,data:JSON.stringify(ze({},{value:r,action:"update",keyColumn:i,key:r[i],table:s},le.getAddParams(this,e,o)))}},t.prototype.processResponse=function(e,i,r,s,o,a,l){var h;if(e="batch"===(o?JSON.parse(o.data):e).action?le.parse.parseJson(e):e,"add"===this.updateType&&n.prototype.insert.call(this,i,e,null,null,this.pvt.position),"update"===this.updateType&&n.prototype.update.call(this,i,this.updateKey,e),this.updateType=void 0,e.added)for(h=0;hi&&h.push(c)}for(c=0;cthis.pageSize;)h.results.splice(0,1),h.keys.splice(0,1);return window.localStorage.setItem(this.guidId,JSON.stringify(h)),e},t.prototype.beforeSend=function(e,i,r){!m(this.cacheAdaptor.options.batch)&&le.endsWith(r.url,this.cacheAdaptor.options.batch)&&"post"===r.type.toLowerCase()&&i.headers.set("Accept",this.cacheAdaptor.options.multipartAccept),e.dataSource.crossDomain||i.headers.set("Accept",this.cacheAdaptor.options.accept)},t.prototype.update=function(e,i,r,s){return this.isCrudAction=!0,this.cacheAdaptor.update(e,i,r,s)},t.prototype.insert=function(e,i,r){return this.isInsertAction=!0,this.cacheAdaptor.insert(e,i,r)},t.prototype.remove=function(e,i,r,s){return this.isCrudAction=!0,this.cacheAdaptor.remove(e,i,r,s)},t.prototype.batchRequest=function(e,i,r){return this.cacheAdaptor.batchRequest(e,i,r)},t}(uc),nt=function(){function n(t,e,i){var s,r=this;return this.dateParse=!0,this.timeZoneHandling=!0,this.persistQuery={},this.isInitialLoad=!1,this.requests=[],this.isInitialLoad=!0,!t&&!this.dataSource&&(t=[]),i=i||t.adaptor,t&&!1===t.timeZoneHandling&&(this.timeZoneHandling=t.timeZoneHandling),t instanceof Array?s={json:t,offline:!0}:"object"==typeof t?(t.json||(t.json=[]),t.enablePersistence||(t.enablePersistence=!1),t.id||(t.id=""),t.ignoreOnPersist||(t.ignoreOnPersist=[]),s={url:t.url,insertUrl:t.insertUrl,removeUrl:t.removeUrl,updateUrl:t.updateUrl,crudUrl:t.crudUrl,batchUrl:t.batchUrl,json:t.json,headers:t.headers,accept:t.accept,data:t.data,timeTillExpiration:t.timeTillExpiration,cachingPageSize:t.cachingPageSize,enableCaching:t.enableCaching,requestType:t.requestType,key:t.key,crossDomain:t.crossDomain,jsonp:t.jsonp,dataType:t.dataType,offline:void 0!==t.offline?t.offline:!(t.adaptor instanceof FK||t.adaptor instanceof _K||t.url),requiresFormat:t.requiresFormat,enablePersistence:t.enablePersistence,id:t.id,ignoreOnPersist:t.ignoreOnPersist}):le.throwError("DataManager: Invalid arguments"),void 0===s.requiresFormat&&!le.isCors()&&(s.requiresFormat=!!m(s.crossDomain)||s.crossDomain),void 0===s.dataType&&(s.dataType="json"),this.dataSource=s,this.defaultQuery=e,this.dataSource.enablePersistence&&this.dataSource.id&&window.addEventListener("unload",this.setPersistData.bind(this)),s.url&&s.offline&&!s.json.length?(this.isDataAvailable=!1,this.adaptor=i||new gp,this.dataSource.offline=!1,this.ready=this.executeQuery(e||new jt),this.ready.then(function(o){r.dataSource.offline=!0,r.isDataAvailable=!0,s.json=o.result,r.adaptor=new QE})):this.adaptor=s.offline?new QE:new gp,!s.jsonp&&this.adaptor instanceof gp&&(s.jsonp="callback"),this.adaptor=i||this.adaptor,s.enableCaching&&(this.adaptor=new UK(this.adaptor,s.timeTillExpiration,s.cachingPageSize)),this}return Object.defineProperty(n.prototype,"moduleName",{get:function(){return"datamanager"},enumerable:!0,configurable:!0}),n.prototype.getPersistedData=function(t){var e=localStorage.getItem(t||this.dataSource.id);return JSON.parse(e)},n.prototype.setPersistData=function(t,e,i){localStorage.setItem(e||this.dataSource.id,JSON.stringify(i||this.persistQuery))},n.prototype.setPersistQuery=function(t){var e=this,i=this.getPersistedData();if(this.isInitialLoad&&i&&Object.keys(i).length){this.persistQuery=i,this.persistQuery.queries=this.persistQuery.queries.filter(function(s){if(e.dataSource.ignoreOnPersist&&e.dataSource.ignoreOnPersist.length&&s.fn&&e.dataSource.ignoreOnPersist.some(function(l){return s.fn===l}))return!1;if("onWhere"===s.fn){var o=s.e;if(o&&o.isComplex&&o.predicates instanceof Array){var a=o.predicates.map(function(l){if(l.predicates&&l.predicates instanceof Array){var h=l.predicates.map(function(v){return new Ss(v.field,v.operator,v.value,v.ignoreCase,v.ignoreAccent,v.matchCase)});return"and"===l.condition?Ss.and(h):Ss.or(h)}return new Ss(l.field,l.operator,l.value,l.ignoreCase,l.ignoreAccent,l.matchCase)});s.e=new Ss(a[0],o.condition,a.slice(1))}}return!0});var r=ze(new jt,this.persistQuery);return this.isInitialLoad=!1,r}return this.persistQuery=t,this.isInitialLoad=!1,t},n.prototype.setDefaultQuery=function(t){return this.defaultQuery=t,this},n.prototype.executeLocal=function(t){!this.defaultQuery&&!(t instanceof jt)&&le.throwError("DataManager - executeLocal() : A query is required to execute"),this.dataSource.json||le.throwError("DataManager - executeLocal() : Json data is required to execute"),this.dataSource.enablePersistence&&this.dataSource.id&&(t=this.setPersistQuery(t));var e=this.adaptor.processQuery(this,t=t||this.defaultQuery);if(t.subQuery){var i=t.subQuery.fromTable,r=t.subQuery.lookups,s=t.isCountRequired?e.result:e;r&&r instanceof Array&&le.buildHierarchy(t.subQuery.fKey,i,s,r,t.subQuery.key);for(var o=0;oli");P.classList.remove("json-parent");for(var j=0;j',W=ve.children[0].placeholder}return W}function Q(k,W,ve){!m(ve)&&""!==ve&&K(W,ve.split(" ")),!m(k)&&""!==k&&V(W,k.split(" "))}function oe(k,W,ve){if("multiselect"===ve||function Mo(k){if(!k)return!1;for(var W=k;W&&W!==document.body;){if("none"===window.getComputedStyle(W).display)return!1;W=W.parentElement}return!0}(k)){var Te="multiselect"===ve?k:k.clientWidth-parseInt(getComputedStyle(k,null).getPropertyValue("padding-left"),10);!m(W)&&!m(W.getElementsByClassName("e-float-text-content")[0])&&(W.getElementsByClassName("e-float-text-content")[0].classList.contains("e-float-text-overflow")&&W.getElementsByClassName("e-float-text-content")[0].classList.remove("e-float-text-overflow"),(Te0)for(var Ye=0;Ye<_e.length;Ye++)_e[parseInt(Ye.toString(),10)].addEventListener("mousedown",wo,!1),_e[parseInt(Ye.toString(),10)].addEventListener("mouseup",Hl,!1);else if(_e.length>0)for(Ye=0;Ye<_e.length;Ye++)_e[parseInt(Ye.toString(),10)].removeEventListener("mousedown",wo,this),_e[parseInt(Ye.toString(),10)].removeEventListener("mouseup",Hl,this)}function wo(){for(var W=this.parentElement;!W.classList.contains("e-input-group");)W=W.parentElement;!function ya(k,W){!k.classList.contains("e-disabled")&&!k.querySelector("input").readOnly&&W.classList.add("e-input-btn-ripple")}(W,this)}function Hl(){var k=this;setTimeout(function(){k.classList.remove("e-input-btn-ripple")},500)}function mb(k,W){var ve=W("span",{className:k});return ve.classList.add("e-input-group-icon"),ve}function I_(k,W,ve,Te){var _e=m(Te)?mi:Te,Ye=mb(k,_e);W.classList.add("e-float-icon-left");var fi=W.querySelector(".e-input-in-wrap");if(m(fi)){fi=_e("span",{className:"e-input-in-wrap"}),ve.parentNode.insertBefore(fi,ve);var Gs=W.querySelectorAll(ve.tagName+" ~ *");fi.appendChild(ve);for(var Kn=0;Kn-1)if("class"===_e){var Ye=this.getInputValidClassList(k[""+_e]);""!==Ye&&V([W],Ye.split(" "))}else if("style"===_e){var fi=W.getAttribute(_e);fi=m(fi)?k[""+_e]:fi+k[""+_e],W.setAttribute(_e,fi)}else W.setAttribute(_e,k[""+_e])}},n.isBlank=function Hle(k){return!k||/^\s*$/.test(k)}}(Le||(Le={})),new RegExp("^(-)?(\\d*)$"),new RegExp("^[A-Za-z0-9._%+-]{1,}@[A-Za-z0-9._%+-]{1,}([.]{1}[a-zA-Z0-9]{2,}|[.]{1}[a-zA-Z0-9]{2,4}[.]{1}[a-zA-Z0-9]{2,4})$"),new RegExp("^([0-9]{4})-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])$"),new RegExp("^[0-9]*$"),new RegExp("^[+]?[0-9]{9,13}$"),new RegExp("^\\d{13,16}$");var me=function(){function n(t,e){this.width=t,this.height=e}return n.prototype.isEmpty=function(){return 0===this.height&&0===this.width},n.prototype.clone=function(){return new n(this.width,this.height)},n}(),Rie=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),KB=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},z=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Rie(t,n),t.equals=function(e,i){return e===i||!(!e||!i)&&(!e||!i||e.x===i.x&&e.y===i.y)},t.isEmptyPoint=function(e){return!(e.x&&e.y)},t.transform=function(e,i,r){var s={x:0,y:0};return s.x=Math.round(100*(e.x+r*Math.cos(i*Math.PI/180)))/100,s.y=Math.round(100*(e.y+r*Math.sin(i*Math.PI/180)))/100,s},t.findLength=function(e,i){return Math.sqrt(Math.pow(e.x-i.x,2)+Math.pow(e.y-i.y,2))},t.findAngle=function(e,i){var r=Math.atan2(i.y-e.y,i.x-e.x);return r=180*r/Math.PI,(r%=360)<0&&(r+=360),r},t.distancePoints=function(e,i){return Math.sqrt(Math.pow(i.x-e.x,2)+Math.pow(i.y-e.y,2))},t.getLengthFromListOfPoints=function(e){for(var i=0,r=0;ri.y&&!r?o.y+=s:o.y-=s:e.y===i.y?e.xi.x&&!r?o.x+=s:o.x-=s:r?(a=this.findAngle(e,i),o=this.transform(e,a,s)):(a=this.findAngle(i,e),o=this.transform(i,a,s)),o},t.direction=function(e,i){return Math.abs(i.x-e.x)>Math.abs(i.y-e.y)?e.x0)for(var r=0;rt.right||this.top>t.bottom||this.bottom=t.right&&this.top<=t.top&&this.bottom>=t.bottom},n.prototype.containsPoint=function(t,e){return void 0===e&&(e=0),this.left-e<=t.x&&this.right+e>=t.x&&this.top-e<=t.y&&this.bottom+e>=t.y},n.toBounds=function(t){for(var e=new n,i=0,r=t;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},s3=function(n){if(n)switch(n.type){case"Linear":default:return bI;case"Radial":return Gie}return bI},Yie=function(){return function n(t,e,i,r){this.left=t,this.right=e,this.top=i,this.bottom=r}}(),$n=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),it([I(0)],t.prototype,"left",void 0),it([I(0)],t.prototype,"right",void 0),it([I(0)],t.prototype,"top",void 0),it([I(0)],t.prototype,"bottom",void 0),t}(Ee),Qie=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),it([I(45)],t.prototype,"angle",void 0),it([I(5)],t.prototype,"distance",void 0),it([I(.7)],t.prototype,"opacity",void 0),it([I("lightgrey")],t.prototype,"color",void 0),t}(Ee),o3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),t.prototype.getClassName=function(){return"Stop"},it([I("")],t.prototype,"color",void 0),it([I(0)],t.prototype,"offset",void 0),it([I(1)],t.prototype,"opacity",void 0),t}(Ee),wx=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),it([Bt([],o3)],t.prototype,"stops",void 0),it([I("None")],t.prototype,"type",void 0),it([I("")],t.prototype,"id",void 0),t}(Ee),bI=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),it([I(0)],t.prototype,"x1",void 0),it([I(0)],t.prototype,"x2",void 0),it([I(0)],t.prototype,"y1",void 0),it([I(0)],t.prototype,"y2",void 0),t}(wx),Gie=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),it([I(0)],t.prototype,"cx",void 0),it([I(0)],t.prototype,"cy",void 0),it([I(0)],t.prototype,"fx",void 0),it([I(0)],t.prototype,"fy",void 0),it([I(50)],t.prototype,"r",void 0),t}(wx),Ll=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),it([I("white")],t.prototype,"fill",void 0),it([I("black")],t.prototype,"strokeColor",void 0),it([I("")],t.prototype,"strokeDashArray",void 0),it([I(1)],t.prototype,"strokeWidth",void 0),it([I(1)],t.prototype,"opacity",void 0),it([x0(s3)],t.prototype,"gradient",void 0),t}(Ee),a3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),it([I("transparent")],t.prototype,"fill",void 0),t}(Ll),Xp=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),it([I("black")],t.prototype,"color",void 0),it([I("Arial")],t.prototype,"fontFamily",void 0),it([I(12)],t.prototype,"fontSize",void 0),it([I(!1)],t.prototype,"italic",void 0),it([I(!1)],t.prototype,"bold",void 0),it([I("CollapseSpace")],t.prototype,"whiteSpace",void 0),it([I("WrapWithOverflow")],t.prototype,"textWrapping",void 0),it([I("Center")],t.prototype,"textAlign",void 0),it([I("None")],t.prototype,"textDecoration",void 0),it([I("Wrap")],t.prototype,"textOverflow",void 0),it([I("transparent")],t.prototype,"fill",void 0),t}(Ll),on=function(n){return n[n.Default=0]="Default",n[n.expandNode=2]="expandNode",n[n.interaction=4]="interaction",n[n.GroupingInProgress=8]="GroupingInProgress",n[n.GroupClipboardInProcess=16]="GroupClipboardInProcess",n[n.ClearObject=32]="ClearObject",n}(on||{}),hi=function(n){return n[n.Visible=1]="Visible",n[n.Hidden=2]="Hidden",n[n.Hover=4]="Hover",n[n.Connect=8]="Connect",n}(hi||{}),Kt=function(n){return n[n.None=0]="None",n[n.ShowHorizontalLines=1]="ShowHorizontalLines",n[n.ShowVerticalLines=2]="ShowVerticalLines",n[n.ShowLines=3]="ShowLines",n[n.SnapToHorizontalLines=4]="SnapToHorizontalLines",n[n.SnapToVerticalLines=8]="SnapToVerticalLines",n[n.SnapToLines=12]="SnapToLines",n[n.SnapToObject=16]="SnapToObject",n[n.All=31]="All",n}(Kt||{}),mr=function(n){return n[n.None=1]="None",n[n.ConnectorSourceThumb=2]="ConnectorSourceThumb",n[n.ConnectorTargetThumb=4]="ConnectorTargetThumb",n[n.ResizeSouthEast=8]="ResizeSouthEast",n[n.ResizeSouthWest=16]="ResizeSouthWest",n[n.ResizeNorthEast=32]="ResizeNorthEast",n[n.ResizeNorthWest=64]="ResizeNorthWest",n[n.ResizeEast=128]="ResizeEast",n[n.ResizeWest=256]="ResizeWest",n[n.ResizeSouth=512]="ResizeSouth",n[n.ResizeNorth=1024]="ResizeNorth",n[n.Rotate=2048]="Rotate",n[n.UserHandle=4096]="UserHandle",n[n.ToolTip=8192]="ToolTip",n[n.ResizeAll=2046]="ResizeAll",n[n.All=16382]="All",n}(mr||{}),qe=function(n){return n[n.None=1]="None",n[n.Select=2]="Select",n[n.Delete=4]="Delete",n[n.Drag=8]="Drag",n[n.DragSourceEnd=16]="DragSourceEnd",n[n.DragTargetEnd=32]="DragTargetEnd",n[n.DragSegmentThumb=64]="DragSegmentThumb",n[n.AllowDrop=128]="AllowDrop",n[n.Bridging=256]="Bridging",n[n.BridgeObstacle=512]="BridgeObstacle",n[n.InheritBridging=1024]="InheritBridging",n[n.PointerEvents=2048]="PointerEvents",n[n.Tooltip=4096]="Tooltip",n[n.InheritTooltip=8192]="InheritTooltip",n[n.Interaction=4218]="Interaction",n[n.ReadOnly=16384]="ReadOnly",n[n.LineRouting=32768]="LineRouting",n[n.InheritLineRouting=65536]="InheritLineRouting",n[n.ConnectToNearByNode=131072]="ConnectToNearByNode",n[n.ConnectToNearByPort=262144]="ConnectToNearByPort",n[n.ConnectToNearByElement=393216]="ConnectToNearByElement",n[n.InheritSegmentThumbShape=524288]="InheritSegmentThumbShape",n[n.InheritSegmentThumbSize=1048576]="InheritSegmentThumbSize",n[n.Default=2043454]="Default",n}(qe||{}),Lr=function(n){return n[n.ReadOnly=2]="ReadOnly",n[n.InheritReadOnly=4]="InheritReadOnly",n[n.Select=8]="Select",n[n.Drag=16]="Drag",n[n.Resize=32]="Resize",n[n.Rotate=64]="Rotate",n[n.Tooltip=128]="Tooltip",n[n.Interaction=120]="Interaction",n[n.None=0]="None",n}(Lr||{}),ie=function(n){return n[n.None=0]="None",n[n.Select=2]="Select",n[n.Drag=4]="Drag",n[n.Rotate=8]="Rotate",n[n.Shadow=16]="Shadow",n[n.PointerEvents=32]="PointerEvents",n[n.Delete=64]="Delete",n[n.InConnect=128]="InConnect",n[n.OutConnect=256]="OutConnect",n[n.Individual=512]="Individual",n[n.Expandable=1024]="Expandable",n[n.AllowDrop=2048]="AllowDrop",n[n.Inherit=78]="Inherit",n[n.ResizeNorthEast=4096]="ResizeNorthEast",n[n.ResizeEast=8192]="ResizeEast",n[n.ResizeSouthEast=16384]="ResizeSouthEast",n[n.ResizeSouth=32768]="ResizeSouth",n[n.ResizeSouthWest=65536]="ResizeSouthWest",n[n.ResizeWest=131072]="ResizeWest",n[n.ResizeNorthWest=262144]="ResizeNorthWest",n[n.ResizeNorth=524288]="ResizeNorth",n[n.Resize=1044480]="Resize",n[n.AspectRatio=1048576]="AspectRatio",n[n.Tooltip=2097152]="Tooltip",n[n.InheritTooltip=4194304]="InheritTooltip",n[n.ReadOnly=8388608]="ReadOnly",n[n.HideThumbs=16777216]="HideThumbs",n[n.AllowMovingOutsideLane=33554432]="AllowMovingOutsideLane",n[n.Default=5240814]="Default",n}(ie||{}),Xr=function(n){return n[n.None=0]="None",n[n.ElementIsPort=2]="ElementIsPort",n[n.ElementIsGroup=4]="ElementIsGroup",n[n.HorizontalLaneHeader=8]="HorizontalLaneHeader",n}(Xr||{}),bt=function(n){return n[n.Rotate=2]="Rotate",n[n.ConnectorSource=4]="ConnectorSource",n[n.ConnectorTarget=8]="ConnectorTarget",n[n.ResizeNorthEast=16]="ResizeNorthEast",n[n.ResizeEast=32]="ResizeEast",n[n.ResizeSouthEast=64]="ResizeSouthEast",n[n.ResizeSouth=128]="ResizeSouth",n[n.ResizeSouthWest=256]="ResizeSouthWest",n[n.ResizeWest=512]="ResizeWest",n[n.ResizeNorthWest=1024]="ResizeNorthWest",n[n.ResizeNorth=2048]="ResizeNorth",n[n.Default=4094]="Default",n}(bt||{}),rt=function(n){return n[n.None=1]="None",n[n.Bridging=2]="Bridging",n[n.UndoRedo=4]="UndoRedo",n[n.Tooltip=8]="Tooltip",n[n.UserInteraction=16]="UserInteraction",n[n.ApiUpdate=32]="ApiUpdate",n[n.PageEditable=48]="PageEditable",n[n.Zoom=64]="Zoom",n[n.PanX=128]="PanX",n[n.PanY=256]="PanY",n[n.Pan=384]="Pan",n[n.ZoomTextEdit=512]="ZoomTextEdit",n[n.Virtualization=1024]="Virtualization",n[n.LineRouting=2048]="LineRouting",n[n.Default=500]="Default",n}(rt||{}),Ci=function(n){return n[n.None=0]="None",n[n.SingleSelect=1]="SingleSelect",n[n.MultipleSelect=2]="MultipleSelect",n[n.ZoomPan=4]="ZoomPan",n[n.DrawOnce=8]="DrawOnce",n[n.ContinuousDraw=16]="ContinuousDraw",n[n.Default=3]="Default",n}(Ci||{}),Ya=function(n){return n[n.Self=1]="Self",n[n.Parent=2]="Parent",n}(Ya||{}),pt=function(n){return n[n.None=0]="None",n[n.Control=1]="Control",n[n.Meta=1]="Meta",n[n.Alt=2]="Alt",n[n.Shift=4]="Shift",n}(pt||{}),Mt=function(n){return n[n.None=null]="None",n[n.Number0=0]="Number0",n[n.Number1=1]="Number1",n[n.Number2=2]="Number2",n[n.Number3=3]="Number3",n[n.Number4=4]="Number4",n[n.Number5=5]="Number5",n[n.Number6=6]="Number6",n[n.Number7=7]="Number7",n[n.Number8=8]="Number8",n[n.Number9=9]="Number9",n[n.A=65]="A",n[n.B=66]="B",n[n.C=67]="C",n[n.D=68]="D",n[n.E=69]="E",n[n.F=70]="F",n[n.G=71]="G",n[n.H=72]="H",n[n.I=73]="I",n[n.J=74]="J",n[n.K=75]="K",n[n.L=76]="L",n[n.M=77]="M",n[n.N=78]="N",n[n.O=79]="O",n[n.P=80]="P",n[n.Q=81]="Q",n[n.R=82]="R",n[n.S=83]="S",n[n.T=84]="T",n[n.U=85]="U",n[n.V=86]="V",n[n.W=87]="W",n[n.X=88]="X",n[n.Y=89]="Y",n[n.Z=90]="Z",n[n.Left=37]="Left",n[n.Up=38]="Up",n[n.Right=39]="Right",n[n.Down=40]="Down",n[n.Escape=27]="Escape",n[n.Space=32]="Space",n[n.PageUp=33]="PageUp",n[n.PageDown=34]="PageDown",n[n.End=35]="End",n[n.Home=36]="Home",n[n.Delete=46]="Delete",n[n.Tab=9]="Tab",n[n.Enter=13]="Enter",n[n.BackSpace=8]="BackSpace",n[n.F1=112]="F1",n[n.F2=113]="F2",n[n.F3=114]="F3",n[n.F4=115]="F4",n[n.F5=116]="F5",n[n.F6=117]="F6",n[n.F7=118]="F7",n[n.F8=119]="F8",n[n.F9=120]="F9",n[n.F10=121]="F10",n[n.F11=122]="F11",n[n.F12=123]="F12",n[n.Star=56]="Star",n[n.Plus=187]="Plus",n[n.Minus=189]="Minus",n[n.BracketLeft=219]="BracketLeft",n[n.BracketRight=221]="BracketRight",n}(Mt||{}),ee=function(n){return n[n.Render=2]="Render",n[n.PublicMethod=4]="PublicMethod",n[n.ToolAction=8]="ToolAction",n[n.UndoRedo=16]="UndoRedo",n[n.TextEdit=32]="TextEdit",n[n.Group=64]="Group",n[n.Clear=128]="Clear",n[n.PreventClearSelection=256]="PreventClearSelection",n[n.Interactions=512]="Interactions",n[n.PreventHistory=1024]="PreventHistory",n[n.PreventIconsUpdate=2048]="PreventIconsUpdate",n[n.PreventCollectionChangeOnDragOver=4096]="PreventCollectionChangeOnDragOver",n[n.PreventZIndexOnDragging=8192]="PreventZIndexOnDragging",n[n.isGroupDragging=16384]="isGroupDragging",n[n.DragUsingMouse=32768]="DragUsingMouse",n[n.DecoratorPropertyChange=65536]="DecoratorPropertyChange",n[n.PreventLaneContainerUpdate=131072]="PreventLaneContainerUpdate",n}(ee||{}),Qa=function(n){return n[n.None=2]="None",n[n.DrawSelectorBorder=4]="DrawSelectorBorder",n[n.PreventRenderSelector=8]="PreventRenderSelector",n}(Qa||{}),$i=function(n){return n[n.None=0]="None",n[n.PreventDrag=2]="PreventDrag",n[n.PreventScale=4]="PreventScale",n[n.PreventDataInit=8]="PreventDataInit",n[n.hScrollbarMoved=16]="hScrollbarMoved",n[n.vScrollbarMoved=32]="vScrollbarMoved",n[n.AnimationClick=64]="AnimationClick",n[n.EnableGroupAction=128]="EnableGroupAction",n[n.PanInProgress=256]="PanInProgress",n[n.OverViewAction=512]="OverViewAction",n}($i||{}),ca=function(n){return n[n.None=0]="None",n[n.PropertyChange=1024]="PropertyChange",n[n.Interaction=2048]="Interaction",n}(ca||{}),Ae=function(n){return n[n.Zero=0]="Zero",n[n.One=1]="One",n[n.Two=2]="Two",n[n.Three=3]="Three",n[n.Four=4]="Four",n[n.Five=5]="Five",n}(Ae||{}),Ce=function(n){return n[n.collectionChange=0]="collectionChange",n[n.rotateChange=1]="rotateChange",n[n.positionChange=2]="positionChange",n[n.propertyChange=3]="propertyChange",n[n.selectionChange=4]="selectionChange",n[n.sizeChange=5]="sizeChange",n[n.drop=6]="drop",n[n.sourcePointChange=7]="sourcePointChange",n[n.targetPointChange=8]="targetPointChange",n[n.connectionChange=9]="connectionChange",n[n.animationComplete=10]="animationComplete",n[n.click=11]="click",n[n.doubleClick=12]="doubleClick",n[n.scrollChange=13]="scrollChange",n[n.dragEnter=14]="dragEnter",n[n.dragLeave=15]="dragLeave",n[n.dragOver=16]="dragOver",n[n.textEdit=17]="textEdit",n[n.paletteSelectionChange=18]="paletteSelectionChange",n[n.historyChange=19]="historyChange",n[n.mouseEnter=20]="mouseEnter",n[n.mouseLeave=21]="mouseLeave",n[n.mouseOver=22]="mouseOver",n[n.expandStateChange=23]="expandStateChange",n[n.segmentCollectionChange=24]="segmentCollectionChange",n[n.commandExecute=25]="commandExecute",n[n.historyStateChange=26]="historyStateChange",n[n.onUserHandleMouseDown=27]="onUserHandleMouseDown",n[n.onUserHandleMouseUp=28]="onUserHandleMouseUp",n[n.onUserHandleMouseEnter=29]="onUserHandleMouseEnter",n[n.onUserHandleMouseLeave=30]="onUserHandleMouseLeave",n[n.onImageLoad=31]="onImageLoad",n[n.onDoBindingInit=32]="onDoBindingInit",n[n.keyUp=33]="keyUp",n[n.keyDown=34]="keyDown",n[n.fixedUserHandleClick=35]="fixedUserHandleClick",n[n.elementDraw=36]="elementDraw",n[n.mouseWheel=37]="mouseWheel",n[n.segmentChange=38]="segmentChange",n[n.onFixedUserHandleMouseDown=39]="onFixedUserHandleMouseDown",n[n.onFixedUserHandleMouseUp=40]="onFixedUserHandleMouseUp",n[n.onFixedUserHandleMouseEnter=41]="onFixedUserHandleMouseEnter",n[n.onFixedUserHandleMouseLeave=42]="onFixedUserHandleMouseLeave",n[n.loaded=43]="loaded",n}(Ce||{}),ri=function(n){return n[n.None=1]="None",n[n.Drag=2]="Drag",n[n.Draw=4]="Draw",n[n.InConnect=8]="InConnect",n[n.OutConnect=16]="OutConnect",n[n.ToolTip=32]="ToolTip",n[n.InheritTooltip=64]="InheritTooltip",n[n.Default=24]="Default",n}(ri||{}),Cx=function(n){return n[n.None=1]="None",n[n.Source=2]="Source",n[n.Target=4]="Target",n[n.Intermediate=8]="Intermediate",n[n.All=14]="All",n}(Cx||{}),MI=function(n){return n[n.None=0]="None",n[n.SymmetricAngle=2]="SymmetricAngle",n[n.SymmetricDistance=4]="SymmetricDistance",n[n.Default=6]="Default",n}(MI||{}),as=function(){function n(){this.pivot={x:.5,y:.5},this.isDirt=!0,this.isExport=!1,this.exportScaleValue={x:0,y:0},this.exportScaleOffset={x:0,y:0},this.canApplyStyle=!0,this.visible=!0,this.offsetX=0,this.offsetY=0,this.cornerRadius=0,this.minHeight=void 0,this.minWidth=void 0,this.maxWidth=void 0,this.maxHeight=void 0,this.width=void 0,this.height=void 0,this.rotateAngle=0,this.margin={left:0,right:0,top:0,bottom:0},this.connectionDirection="Auto",this.horizontalAlignment="Auto",this.verticalAlignment="Auto",this.flip="None",this.flipMode="All",this.relativeMode="Point",this.transform=Ya.Self|Ya.Parent,this.style={fill:"white",strokeColor:"black",opacity:1,strokeWidth:1},this.desiredSize=new me,this.actualSize=new me,this.parentTransform=0,this.preventContainer=!1,this.isSvgRender=!1,this.bounds=new Ne(0,0,0,0),this.shadow=null,this.description="",this.staticSize=!1,this.shapeType="",this.isRectElement=!1,this.isCalculateDesiredSize=!0,this.flipOffset={x:0,y:0},this.elementActions=Xr.None,this.inversedAlignment=!0,this.position=void 0,this.unitMode=void 0,this.float=!1,this.floatingBounds=void 0}return n.prototype.setOffsetWithRespectToBounds=function(t,e,i){this.unitMode=i,this.position={x:t,y:e}},n.prototype.getAbsolutePosition=function(t){if(void 0!==this.position)return"Absolute"===this.unitMode?this.position:{x:this.position.x*t.width,y:this.position.y*t.height}},Object.defineProperty(n.prototype,"outerBounds",{get:function(){return this.floatingBounds||this.bounds},set:function(t){this.floatingBounds=t},enumerable:!0,configurable:!0}),n.prototype.measure=function(t,e,i){var s=void 0!==this.height?this.height:(t.height||0)-this.margin.top-this.margin.bottom;return this.id&&0===s&&this.elementActions&Xr.HorizontalLaneHeader&&(s=this.actualSize.height),this.desiredSize=new me(void 0!==this.width?this.width:(t.width||0)-this.margin.left-this.margin.right,s),this.isCalculateDesiredSize&&(this.desiredSize=this.validateDesiredSize(this.desiredSize,t)),this.desiredSize},n.prototype.arrange=function(t){return this.actualSize=t,this.updateBounds(),this.actualSize},n.prototype.updateBounds=function(){this.bounds=yr(this)},n.prototype.validateDesiredSize=function(t,e){return this.isRectElement&&!this.width&&!this.minWidth&&!this.maxWidth&&(t.width=50),this.isRectElement&&!this.height&&!this.minHeight&&!this.maxHeight&&(t.height=50),(void 0===t||void 0!==this.width&&void 0!==this.height)&&((t=t||new me).width=void 0===this.width?(e.width||0)-this.margin.left-this.margin.right:this.width,t.height=void 0===this.height?(e.height||0)-this.margin.top-this.margin.bottom:this.height),void 0!==this.minWidth&&(t.width=Math.max(t.width,this.minWidth)),void 0!==this.minHeight&&(t.height=Math.max(t.height,this.minHeight)),void 0!==this.maxWidth&&0!==this.maxWidth&&(t.width=Math.min(t.width,this.maxWidth)),void 0!==this.maxHeight&&0!==this.maxHeight&&(t.height=Math.min(t.height,this.maxHeight)),t},n}(),ere=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Cs=function(n){function t(){var e=null!==n&&n.apply(this,arguments)||this;return e.padding=new Yie(0,0,0,0),e.desiredBounds=void 0,e.measureChildren=!0,e.prevRotateAngle=0,e}return ere(t,n),t.prototype.hasChildren=function(){return void 0!==this.children&&this.children.length>0},t.prototype.measure=function(e,i,r){this.desiredBounds=void 0;var o,a,s=void 0;if(this.hasChildren()){for(var l=0;l=n.width&&s.length>0)i[i.length]={text:s,x:0,dy:0,width:o},s="";else{(s+=a[r+1]||"").indexOf("\n")>-1&&(i[i.length]={text:s,x:0,dy:0,width:Bc(s,n)},s="");var l=Bc(s,n);Math.ceil(l)+2>=n.width&&s.length>0&&(i[i.length]={text:s,x:0,dy:0,width:l},s=""),r===a.length-1&&s.length>0&&(i[i.length]={text:s,x:0,dy:0,width:l},s="")}else i=function Soe(n,t,e){var c,d,u,p,i=[],r="",s=0,o=0,a="nowrap"!==n.whiteSpace,h=(t||n.content).split("\n");for(s=0;s0?" ":"")+c[parseInt(o.toString(),10)];var f=Bc(d=c[o+1]?r+" "+c[o+1]:r,n);Math.floor(f)>(e||n.width)-2&&r.length>0?(i[i.length]={text:r,x:0,dy:0,width:d===r?f:r===p?u:Bc(r,n)},r=""):o===c.length-1&&(i[i.length]={text:r,x:0,dy:0,width:f},r=""),p=d,u=f}return i}(n,t,e);else i[i.length]={text:a,x:0,dy:0,width:Bc(a,n)};return i}(l,r,n.isLaneOrientation?i:void 0),n.wrapBounds=a=function Ioe(n,t){var r,s,e={x:0,width:0},i=0;for(i=0;in.width&&("Ellipsis"===n.textOverflow||"Clip"===n.textOverflow)?0:-r/2:"right"===n.textAlign?-r:t.length>1?0:-r/2,t[parseInt(i.toString(),10)].dy=1.2*n.fontSize,t[parseInt(i.toString(),10)].x=r,e.x=Math.min(e.x,r),e.width=Math.max(e.width,s);return e}(l,o),s.width=a.width,n.wrapBounds.width>=i&&"Wrap"!==l.textOverflow&&(s.width=i),s.height=o.length*n.style.fontSize*1.2,s}(this,0,0,this.isLaneOrientation?e.height:this.width||e.width):this.desiredSize,this.desiredSize=void 0===this.width||void 0===this.height?new me(i.width,i.height):new me(this.width,this.height),this.desiredSize=this.validateDesiredSize(this.desiredSize,e),this.desiredSize},t.prototype.arrange=function(e){return(e.width!==this.actualSize.width||e.height!==this.actualSize.height||this.isDirt)&&(this.doWrap=!0),this.actualSize=e,this.updateBounds(),this.isDirt=!1,this.actualSize},t}(as),ire=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Ii=function(n){function t(){var e=null!==n&&n.apply(this,arguments)||this;return e.measureChildren=void 0,e}return ire(t,n),t.prototype.measure=function(e,i,r){var s=void 0,o=void 0;if(this.hasChildren()){for(var a=0,l=this.children;a=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},xd=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return are(t,n),Lh([I("")],t.prototype,"content",void 0),Lh([I("TopLeft")],t.prototype,"position",void 0),Lh([I("Mouse")],t.prototype,"relativeMode",void 0),Lh([I(!0)],t.prototype,"showTipPointer",void 0),Lh([I("auto")],t.prototype,"width",void 0),Lh([I("auto")],t.prototype,"height",void 0),Lh([I("Auto")],t.prototype,"openOn",void 0),Lh([I()],t.prototype,"animation",void 0),Lh([I(!1)],t.prototype,"isSticky",void 0),t}(Ee);function l3(n){var t=new Sh;t=h3(n.tooltip,t);var e=new Sh(t);return e.beforeCollision=hre,e.beforeOpen=lre,e.cssClass="e-diagram-tooltip",e.opensOn="custom",e.appendTo("#"+n.element.id),e.close(),e}function lre(n){(""===this.content||void 0===this.content)&&(n.element.style.display="none")}function hre(n){n.collidedPosition&&n.collidedPosition!==this.position&&(n.element.style.display="none")}function Ex(n,t){var e=n.tooltipObject;return h3(t?t.tooltip:n.tooltip,e),e}function h3(n,t){return n.content?(t.content=n.content,"string"==typeof n.content&&(t.content=ko(function(){return n.content})),t.position=n.position,t.showTipPointer=n.showTipPointer,t.width=n.width,t.height=n.height,t.animation=n.animation?n.animation:{close:{effect:"None"}}):t.close(),t}var Dx=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Hn=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},xx=function(n){function t(e,i,r,s){var o=n.call(this,e,i,r,s)||this;return o.inEdges=[],o.outEdges=[],o}return Dx(t,n),Hn([I("")],t.prototype,"id",void 0),Hn([I("Center")],t.prototype,"horizontalAlignment",void 0),Hn([I("Center")],t.prototype,"verticalAlignment",void 0),Hn([re({},$n)],t.prototype,"margin",void 0),Hn([I(12)],t.prototype,"width",void 0),Hn([I(12)],t.prototype,"height",void 0),Hn([re({},Ll)],t.prototype,"style",void 0),Hn([I("Square")],t.prototype,"shape",void 0),Hn([I("Auto")],t.prototype,"connectionDirection",void 0),Hn([I(hi.Connect)],t.prototype,"visibility",void 0),Hn([I("")],t.prototype,"pathData",void 0),Hn([I(ri.Default)],t.prototype,"constraints",void 0),Hn([I()],t.prototype,"addInfo",void 0),Hn([I()],t.prototype,"outEdges",void 0),Hn([I()],t.prototype,"inEdges",void 0),Hn([re({},xd)],t.prototype,"tooltip",void 0),t}(Ee),Es=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return Dx(t,n),t.prototype.getClassName=function(){return"PointPort"},Hn([re({x:.5,y:.5},z)],t.prototype,"offset",void 0),t}(xx),xc=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return Dx(t,n),t.prototype.getClassName=function(){return"PathPort"},Hn([I(.5)],t.prototype,"offset",void 0),Hn([re({x:0,y:0},z)],t.prototype,"displacement",void 0),Hn([I("Center")],t.prototype,"alignment",void 0),t}(xx),EI=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),lr=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},cre=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return EI(t,n),lr([I("blue")],t.prototype,"color",void 0),lr([I("")],t.prototype,"content",void 0),lr([I("")],t.prototype,"link",void 0),lr([I("None")],t.prototype,"textDecoration",void 0),lr([I("NewTab")],t.prototype,"hyperlinkOpenState",void 0),t}(Ee),Tx=function(n){function t(e,i,r,s){var o=n.call(this,e,i,r,s)||this;return r.id||(o.id=e.parentObj&&e.parentObj.propName&&"phases"===e.parentObj.propName?e.parentObj.id:Qe()),o}return EI(t,n),lr([I("")],t.prototype,"content",void 0),lr([I(void 0)],t.prototype,"template",void 0),lr([I("String")],t.prototype,"annotationType",void 0),lr([I(!0)],t.prototype,"visibility",void 0),lr([I(Lr.InheritReadOnly)],t.prototype,"constraints",void 0),lr([re(void 0,cre)],t.prototype,"hyperlink",void 0),lr([I("")],t.prototype,"id",void 0),lr([I()],t.prototype,"width",void 0),lr([I()],t.prototype,"height",void 0),lr([I(0)],t.prototype,"rotateAngle",void 0),lr([I("Parent")],t.prototype,"rotationReference",void 0),lr([re({strokeWidth:0,strokeColor:"transparent",fill:"transparent"},Xp)],t.prototype,"style",void 0),lr([I("Center")],t.prototype,"horizontalAlignment",void 0),lr([I("Center")],t.prototype,"verticalAlignment",void 0),lr([re({},$n)],t.prototype,"margin",void 0),lr([re({top:void 0,bottom:void 0,left:void 0,right:void 0},$n)],t.prototype,"dragLimit",void 0),lr([I("Shape")],t.prototype,"type",void 0),lr([re({},xd)],t.prototype,"tooltip",void 0),lr([I()],t.prototype,"addInfo",void 0),t}(Ee),Zn=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return EI(t,n),t.prototype.getClassName=function(){return"ShapeAnnotation"},lr([re({x:.5,y:.5},z)],t.prototype,"offset",void 0),t}(Tx),Nr=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return EI(t,n),t.prototype.getClassName=function(){return"PathAnnotation"},lr([I(.5)],t.prototype,"offset",void 0),lr([re({x:0,y:0},z)],t.prototype,"displacement",void 0),lr([I("Center")],t.prototype,"alignment",void 0),lr([I(!1)],t.prototype,"segmentAngle",void 0),t}(Tx);function Ax(n){return fre[n.toString()]}function c3(n){return mre[""+n]}var fre={X:"M14,14 L106,106 M106,14 L14,106",Circle:"M0,50 A50,50,0 1 1 100,50 A50,50,0 1 1 0,50 Z",Square:"M0,0 L10,0 L10,10 L0,10 z"},gre={OpenArrow:"M15.9,23 L5,16 L15.9,9 L17,10.7 L8.7,16 L17,21.3Z",Square:"M0,0 L10,0 L10,10 L0,10 z",Fletch:"M14.8,10c0,0-3.5,6,0.2,12c0,0-2.5-6-10.9-6C4.1,16,11.3,16,14.8,10z",OpenFetch:"M6,17c-0.6,0-1-0.4-1-1s0.4-1,1-1c10.9,0,11-5,11-5c0-0.6,0.4-1,1-1s1,0.4,1,1C19,10.3,18.9,17,6,17C6,17,6,17,6,17z M18,23c-0.5,0-1-0.4-1-1c0-0.2-0.3-5-11-5c-0.6,0-1-0.5-1-1s0.4-1,1-1c0,0,0,0,0,0c12.9,0,13,6.7,13,7 C19,22.6,18.6,23,18,23z",IndentedArrow:"M17,10c0,0-4.5,5.5,0,12L5,16L17,10z",OutdentedArrow:"M14.6,10c0,0,5.4,6,0,12L5,16L14.6,10z",DoubleArrow:"M19,10 L19,22 L13,16Z M12,10 L12,22 L6,16Z",Arrow:"M15,10 L15,22 L5,16Z",Diamond:"M12,23l-7-7l7-7l6.9,7L12,23z",Circle:"M0,50 A50,50,0 1 1 100,50 A50,50,0 1 1 0,50 Z"},vre={Square:"M0,0 L10,0 L10,10 L0,10 z",Rhombus:"M10,5 L5,10 L0,5 L5,0 L10,5 Z ",Rectangle:"M0,0 L15,0 L15,10 L0,10 z ",OpenArrow:"M15.9,23 L5,16 L15.9,9 L17,10.7 L8.7,16 L17,21.3Z",Fletch:"M9.82,0 C9.82,0,6.61,5,10,10 C10,10,7.71,5,0,5 C0,5,6.61,5,9.82,0 Z ",OpenFetch:"M0.71,5.71 C0.29,5.71,0,5.43,0,5 C0,4.57,0.29,4.29,0.71,4.29 C8.5,4.29,8.57,0.71,8.57,0.71 C8.57,0.29,8.86,0,9.29,0 C9.719999999999999,0,10,0.29,10,0.71 C10,0.93,9.93,5.71,0.71,5.71 C0.71,5.71,0.71,5.71,0.71,5.71 Z M9.29,10 C8.93,10,8.57,9.71,8.57,9.29 C8.57,9.14,8.36,5.71,0.71,5.71 C0.29,5.71,0,5.36,0,5 C0,4.64,0.29,4.29,0.71,4.29 C0.71,4.29,0.71,4.29,0.71,4.29 C9.93,4.29,10,9.07,10,9.29 C10,9.71,9.71,10,9.29,10 Z ",IndentedArrow:"M10,0 C10,0,6.25,4.58,10,10 L0,5 L10,0 Z ",OutdentedArrow:"M8,0 C8,0,12.5,5,8,10 L0,5 L8,0 Z ",DoubleArrow:"M19,10 L19,22 L13,16Z M12,10 L12,22 L6,16Z",Arrow:"M15,10 L15,22 L5,16Z",Diamond:"M10,5 L5,10 L0,5 L5,0 L10,5 Z ",Circle:"M10,5 C10,7.76,7.76,10,5,10 C2.24,10,0,7.76,0,5 C0,2.24,2.24,0,5,0 C7.76,0,10,2.24,10,5 Z ",Ellipse:"M15,5 C15,7.76,11.64,10,7.5,10 C3.36,10,0,7.76,0,5 C0,2.24,3.36,0,7.5,0 C11.64,0,15,2.24,15,5 Z "},mre={Square:"M0,0 L10,0 L10,10 L0,10 z",Rhombus:"M10,5 L5,10 L0,5 L5,0 L10,5 Z ",Rectangle:"M0,0 L15,0 L15,10 L0,10 z",OpenArrow:"M23,15.9 L16,5 L9,15.9 L10.7,17 L16,8.7 L21,17.3Z",Fletch:"M9.82,0 C9.82,0,6.61,5,10,10 C10,10,7.71,5,0,5 C0,5,6.61,5,9.82,0 Z ",OpenFetch:"M0.71,5.71 C0.29,5.71,0,5.43,0,5 C0,4.57,0.29,4.29,0.71,4.29 C8.5,4.29,8.57,0.71,8.57,0.71 C8.57,0.29,8.86,0,9.29,0 C9.719999999999999,0,10,0.29,10,0.71 C10,0.93,9.93,5.71,0.71,5.71 C0.71,5.71,0.71,5.71,0.71,5.71 Z M9.29,10 C8.93,10,8.57,9.71,8.57,9.29 C8.57,9.14,8.36,5.71,0.71,5.71 C0.29,5.71,0,5.36,0,5 C0,4.64,0.29,4.29,0.71,4.29 C0.71,4.29,0.71,4.29,0.71,4.29 C9.93,4.29,10,9.07,10,9.29 C10,9.71,9.71,10,9.29,10 Z ",IndentedArrow:"M10,0 C10,0,6.25,4.58,10,10 L0,5 L10,0 Z ",OutdentedArrow:"M8,0 C8,0,12.5,5,8,10 L0,5 L8,0 Z ",DoubleArrow:"M10,19 L22,19 L16,13Z M10,12 L22,12 L16,6Z",Arrow:"M10,15 L22,15 L16,5Z",Diamond:"M10,5 L5,10 L0,5 L5,0 L10,5 Z ",Circle:"M10,5 C10,7.76,7.76,10,5,10 C2.24,10,0,7.76,0,5 C0,2.24,2.24,0,5,0 C7.76,0,10,2.24,10,5 Z ",Ellipse:"M15,5 C15,7.76,11.64,10,7.5,10 C3.36,10,0,7.76,0,5 C0,2.24,3.36,0,7.5,0 C11.64,0,15,2.24,15,5 Z "};function Lx(n){return yre[n.toString()]}var yre={Process:"M419.511,76.687L359.511,76.687L359.511,43.086L419.511,43.086z",Decision:"M 253.005,115.687L 200.567,146.071L 148.097,115.687L 200.534,85.304L 253.005,115.687 Z",Document:"M 60 31.9 c 0 0 -11 -7.7 -30 0 s -30 0 -30 0 V 0 h 60 V 31.9 Z",PreDefinedProcess:"M 0,0 L 50,0 L 50,50 L 0,50 Z M 8.334,0 L 8.334,50 M 41.667,0 L 41.667,50",Terminator:"M 269.711,29.33C 269.71,44.061 257.77,56 243.04,56L 158.058,56C 143.33,56 131.39,44.061 131.39,29.33L 131.39,29.33C 131.391,14.6057 143.33,2.669 158.058,2.669L 243.044,2.669C 257.772,2.669 269.711,14.6057 269.711,29.333 Z",PaperTap:"M0.0009,17.2042 L0.0009,47.165 C0.001,47.165 14.403,53.5455 25.00,47.165 C35.599,40.7852 44.403,43.5087 50.00,47.165L50.001,17.2042 M50.001,32.7987 L50.001,2.8405 C50.001,2.8405 35.599,-3.5427 25.001,2.8405C14.403,9.2237 5.599,6.494 0.0009,2.8405 L0.0009,32.7987",DirectData:"M 132.62 0 L 17.38 0 C 7.78 0 0 13.43 0 30 C 0 46.57 7.78 60 17.38 60 L 132.62 60 M 132.62 0C 123.02 0 115.24 13.43 115.24 30 C 115.24 46.57 123.02 60 132.62 60 C 142.22 60 150 46.57 150 30 C 150 13.43 142.22 0 132.62 0 z ",SequentialData:"M0.0029,24.999 C0.0029,11.1922 10.433,0.0021 23.295,0.0021 C36.159,0.00216 46.585,11.1922 46.585,24.999C46.585,38.8057 36.159,49.9979 23.295,49.9979 C10.433,49.9979 0.0029,38.8057 0.0029,24.999 z M23.294,49.999 L50.002,49.999",Sort:"M50.001,24.9971 L25.001,49.9971 L0.00097,24.9971 L25.001,-0.00286865 L50.001,24.9971 z M0.000976562,24.9971 L50.001,24.9971",MultiDocument:"M43.6826,40 C44.8746,40.6183 45.8586,41.3502 46.8366,42.1122 L46.8366,4.74487 L3.09857,4.74487 L3.09857,10.9544 M46.837,35.143 C48.027,35.765 49.025,36.604 50.003,37.369 L50.003,0.002 L6.264,0.002 L6.264,4.744 M43.682,47.113 L43.682,10.765 L0.0025,10.7652 L0.0025,47.1132 C0.0025,47.1132 12.5846,53.6101 21.8426,47.1132 C31.1006,40.6163 38.792,43.393 43.6826,47.1132 z",Collate:"M50.001,0.0028 L25.001,25.0029 L0.00097,0.0028 L50.001,0.002 z M0.0009,50.002 L25.001,25.002L50.001,50.002 L0.0009,50.0029 z",SummingJunction:"M7.3252,42.6768 L42.6772,7.3247 M42.6768,42.6768 L7.3248,7.3247 M0.0009,25.001 C0.0009,11.193 11.197,0.0009 25.001,0.0009 C38.809,0.0009 50.001,11.193 50.001,25.001 C50.001,38.809 38.809,50.001 25.001,50.001 C11.197,50.00 0.0009,38.809 0.0009,25.00 z",Or:"M 0 50 L 100 50 M 50 100 L 50 0.0 M 0 50 C 0 22.384 22.392 0 50 0 C 77.616 0 100 22.384 100 50 C 100 77.616 77.616 100 50 100 C 22.392 100 0 77.616 0 50 Z",InternalStorage:"M 0 3.81946A 2.5,3.81946 0 0,1 2.5,0L 47.5 0A 2.5,3.81946 0 0,1 50,3.81946L 50 45.836A 2.5,3.819446 0 0,1 47.5,49.652778L 2.5 49.652778A 2.5,3.819446 0 0,1 0,45.8336L 0 3.819446ZM 0 11.45834L 50 11.4583334M 12.5 0L 12.5 49.652778",Extract:"M0,35 L30,0 L60,35 Z",ManualOperation:"M46.4,28.8 L14.8,28.8 L0,0 L60,0 Z",Merge:"M60,0 L30,35 L0,0 Z",OffPageReference:"M60,33.3 L30.1,39 L0,33.3 L0,0 L60,0 Z",SequentialAccessStorage:"M 60 30 C 60 13.4 46.6 0 30 0 S 0 13.4 0 30 s 13.4 30 30 30 h 28.6 v -6.5 h -9.9C 55.5 48 60 39.5 60 30 Z",Annotation:"M49.9984,50.0029 L-0.00271199,50.0029 L-0.00271199,0.00286865 L49.9984,0.00286865",Annotation2:"M49.9977,50.0029 L25.416,50.0029 L25.416,0.00286865 L49.9977,0.00286865 M25.4166,25.0029 L-0.00227869,25.0029",Data:"M 10 0 L 40 0 L 30 40 L 0 40 Z",Card:"M275,60 L400,60 L400,110 L260,110 L260,75 Z",Delay:"M0,0 L12.029,0 C14.212999,0 16,1.7869979 16,3.9709952 C16,6.1549926 14.212999,7.9409904 12.029,7.9409904 L0,7.9409904 z",Preparation:"M 1048.17 572 C 1051.06 568.86 1055.17 567.05 1059.5 567 L 1094.51 567 C 1098.84 567.05 1102.95 568.86 1105.84 572 L 1126.43 595 C 1127.01 596.28 1127.01 597.72 1126.43 599 L 1105.84 622 C 1102.95 625.14 1098.84 626.95 1094.51 627 L 1059.5 627 C 1055.17 626.95 1051.06 625.14 1048.17 622 L 1027.58 599 C 1027 597.72 1027 596.28 1027.58 595 L 1048.17 572 Z",Display:"M47.8809,19.2914 L32.7968,-0.00594145 L11.3902,-0.00594145 C7.93166,-0.00594145 0.00124586,11.187 0.00124586,24.9968C0.00124586,38.8032 7.93166,49.9962 11.3902,49.9962 L32.7968,49.99 L47.615,31.038 C47.615,31.0388 52.798,24.9968 47.880,19.2914 z",ManualInput:"M 912 732 L 1006.85 707 C 1008.2 707 1009.5 707.53 1010.46 708.46 C 1011.41 709.4 1011.95 710.67 1011.95 712 L 1011.95 762C 1012 764.41 1010.28 766.52 1007.87 767 L 917.1 767 C 915.75 767 914.45 766.47 913.49 765.54 C 912.54 764.6 912 763.33 912 762 L 912 732 Z",LoopLimit:"M 8 9 L 27 9 L 33 15 L 33 26 C 33 27 33 27 32 27 L 4 27 C 3 27 2 27 2 26 L 2 15 L 8 9 Z",StoredData:"M 5.55 0L 50 0A 1.5,30 0 0,1 50,0A 5.555,25 0 0,0 50,50A 1.5,30 0 0,1 50,50L 5.555 50A 5.55,25 0 0,1 5.555,0Z"};function d3(n,t,e){var i;i="Straight"!==n.type&&n.sourceWrapper?n.sourceWrapper.corners.center:function Sre(n){var t;if(n.sourcePortWrapper){var e=n.sourcePortWrapper;t={x:e.offsetX,y:e.offsetY}}else t=n.sourceID&&n.sourceWrapper&&n.targetWrapper?Nh(n,0,n.sourceWrapper.corners.center,n.targetWrapper.corners.center,!1):n.sourcePoint;return t}(n);var r=function bre(n,t,e,i,r){var b,M,s=n.sourceWrapper,o=n.targetWrapper,a=n.sourcePortWrapper,l=n.targetPortWrapper,d=[],f=Ga(n),y={corners:undefined,point:t,direction:undefined,margin:{left:5,right:5,bottom:5,top:5}},S={corners:undefined,point:e,direction:undefined,margin:{left:5,right:5,bottom:5,top:5}};if(void 0!==s&&void 0!==o&&(b=En(s),M=En(o),y.corners=s.corners,S.corners=o.corners),void 0!==a&&(y.direction="Left"===a.connectionDirection||"Top"===a.connectionDirection||"Bottom"===a.connectionDirection||"Right"===a.connectionDirection?a.connectionDirection:zo({x:a.offsetX,y:a.offsetY},b,s.bounds)),void 0!==l&&(S.direction="Left"===l.connectionDirection||"Right"===l.connectionDirection||"Bottom"===l.connectionDirection||"Top"===l.connectionDirection?l.connectionDirection:zo({x:l.offsetX,y:l.offsetY},M,o.bounds)),"Bezier"===n.type&&!n.isBezierEditing&&n.segments.length>0)for(var D=n.segments.length-1;D>=0;)n.segments[parseInt(D.toString(),10)].isInternalSegment&&n.segments.pop(),D--;if(void 0!==s&&void 0!==o)return(void 0===y.direction||void 0===S.direction)&&(i?function Ire(n,t,e){"LeftToRight"===e?(n.direction=n.direction?n.direction:"Right",t.direction=t.direction?t.direction:"Left"):"RightToLeft"===e?(n.direction=n.direction?n.direction:"Left",t.direction=t.direction?t.direction:"Right"):"TopToBottom"===e?(n.direction=n.direction?n.direction:"Bottom",t.direction=t.direction?t.direction:"Top"):"BottomToTop"===e&&(n.direction=n.direction?n.direction:"Top",t.direction=t.direction?t.direction:"Bottom")}(y,S,i):y.corners.top>S.corners.bottom&&Math.abs(y.corners.top-S.corners.bottom)>f?(y.direction=y.direction?y.direction:"Top",S.direction=S.direction?S.direction:"Bottom"):y.corners.bottomf?(y.direction=y.direction?y.direction:"Bottom",S.direction=S.direction?S.direction:"Top"):y.corners.rightf||y.corners.right+f=y.corners.left-f&&y.corners.left>S.corners.left?(y.direction=y.direction?y.direction:"Right",S.direction=S.direction?S.direction:"Left"):y.corners.left>S.corners.right&&Math.abs(y.corners.left-S.corners.right)>y.margin.left+y.margin.right||S.corners.right+f=S.corners.left-f&&y.corners.left0&&n.segments[0].direction&&(y.direction=n.segments[0].direction),y.point=Tc(b,y.direction),d=Tc(b,ls(y.direction)),y.point=Nh(n,0,y.point,d,!1)):y.point=o.corners.center;if(void 0!==h){switch(S.point={x:h.offsetX,y:h.offsetY},S.direction){case"Bottom":case"Top":S.point.y=S.point.y;break;case"Left":case"Right":S.point.x=S.point.x}n.targetPadding&&!w&&(S.point=DI(n,y,S,!0))}else"Orthogonal"===n.type||"Bezier"===n.type?(S.point=Tc(M,S.direction),d=Tc(M,ls(S.direction)),S.point=Nh(n,0,S.point,d,!0)):S.point=a.corners.center;if("Orthogonal"!==n.type){var C=void 0,D=void 0;if("Bezier"===n.type){if(n.bezierSettings.allowSegmentsReset||0===n.segments.length||!z.isEmptyPoint(n.segments[n.segments.length-1].point))return c=b3(n,y,S,void 0,s),Nx(n,y,S);_v(n)}else _v(n);if(void 0===n.sourcePortWrapper){y.point=y.corners.center,n.segments&&n.segments.length>0&&(C=z.isEmptyPoint((D=n.segments[0]).point)?void 0:D);var A=void 0!==C?C.point:S.point;if("Bezier"===n.type&&n.segments.length>0&&n.segments[0].vector1.angle&&n.segments[0].vector1.distance){var x=Math.max(y.corners.width,y.corners.height);A=z.transform(y.point,n.segments[0].vector1.angle,x/2)}y.point=w?n.sourceWrapper.bounds.center:Nh(n,0,y.point,A,!1)}if(void 0===n.targetPortWrapper){S.point=S.corners.center,n.segments&&n.segments.length>1&&(C=z.isEmptyPoint((D=n.segments[n.segments.length-2]).point)?void 0:D);var R=C?C.point:y.point;"Bezier"===n.type&&n.segments.length>0&&n.segments[n.segments.length-1].vector2.angle&&n.segments[n.segments.length-1].vector2.distance&&(x=Math.max(y.corners.width,y.corners.height),R=z.transform(S.point,n.segments[0].vector2.angle,x/2)),S.point=w?n.targetWrapper.bounds.center:Nh(n,0,R,S.point,!0)}c=Nx(n,y,S)}else"Orthogonal"===n.type&&n.segments&&n.segments.length>0&&null!==n.segments[0].direction?c=function Nre(n,t,e,i,r,s,o){var a,h,c,d;_v(n);for(var u=0;u0&&n.segments[u-1].direction===h.direction?u=y3(n,u,t):h.direction?t.point=u3(t,n.segments[parseInt(u.toString(),10)]):(p=n.segments[u-1])&&p.points&&(t.point=p.points[p.points.length-1]),u===n.segments.length-1)if(S3(n,t),v3(a=void 0===r?Lre(n,t,e):f3(n,t,e),n),h.points=[],a.length>=2)for(c=0;c2&&n.segments.length>2){var f={x:a[parseInt(c.toString(),10)].x,y:t.point.y};h.points=[],h.points.push(f),h.points.push(a[parseInt(c.toString(),10)]);var p=n.segments[u-1];n.segments.length<4&&p.points.pop(),p.points=p.points.concat(h.points)}else h.points.push(a[parseInt(c.toString(),10)]);else h.points.push(a[parseInt(c.toString(),10)]);else d=u;if(void 0!==d&&!n.selectedSegmentIndex&&(d===n.segments.length-1&&(n.segments[d-1].direction=null,n.segments[d-1].length=null),n.segments.splice(d,1)),i&&0===u){var g=g3(n,i,s);g&&(t.point=g)}}return I3(n,[])}(n,y,S,l,h,o):(n.segments[0]||(C=new bi(n,"segments",{type:"Orthogonal"},!0),n.segments.push(C)),n.segments[0].points=c=b3(n,y,S,void 0,s));return c}(n,y.direction,S.direction,y.point,S.point,r);if(_v(n),(n.sourceWrapper||n.targetWrapper)&&function Dre(n,t,e){var i=n.sourcePortWrapper,r=n.targetPortWrapper,s=n.sourceWrapper,o=t.point,a={left:0,right:0,top:0,bottom:0},l={x:0,y:0},c="Top";if(s?(o=e.point,a=t.margin):(s=n.targetWrapper,a=e.margin),"Orthogonal"===n.type)if(n.segments&&n.segments.length>0&&n.sourceWrapper&&n.segments[0].direction)t.direction=n.segments[0].direction,l=Nh(n,0,l=Tc(s.corners,t.direction),Tc(s.corners,ls(t.direction)),!1);else{var u={corners:null,direction:null,point:null,margin:null};Uv(s,{corners:null,direction:null,point:o,margin:a},u,n),l=u.point,c=u.direction}else{var p=void 0;n.segments&&n.segments.length>1&&(p=s===n.sourceWrapper?n.segments[0].point:n.segments[n.segments.length-2].point),l=Nh(n,0,s.bounds.center,n.segments&&n.segments.length>1?p:o,s===n.targetWrapper)}s===n.sourceWrapper?(t.direction=t.direction||c,t.point=l,n.sourcePortWrapper&&(t.point={x:i.offsetX,y:i.offsetY},n.sourcePadding&&(t.point=DI(n,t,e,!1)))):(e.direction=e.direction||c,e.point=l,n.targetPortWrapper&&(e.point={x:r.offsetX,y:r.offsetY},n.targetPadding&&(e.point=DI(n,t,e,!0))))}(n,y,S),"Straight"===n.type||"Bezier"===n.type)d=Nx(n,y,S);else if("Orthogonal"===n.type&&n.segments&&n.segments.length>0&&null!==n.segments[0].length&&null!==n.segments[0].direction)d=function Ere(n,t,e,i,r,s,o){var a,l,c,u,h=[];if(_v(n),n.segments.length>0){for(var p=0;p0&&n.segments[p-1].direction===f.direction)p=y3(n,p,t);else{var g=n.segments[p-1];t.point=f.direction?u3(t,f):g.points[g.points.length-1]}if(p===n.segments.length-1&&(o||r?n.targetWrapper&&void 0===n.targetPortWrapper?(S3(n,t),l=wre(n,t,e)):l=f3(n,t,e):l=Mre(n,t,e),l))if(v3(l,n),f.points=[],l.length>=2)for(a=0;at.corners.top&&e.point.ye.point.x?"Left":"Right"):e.point.x>t.corners.left&&e.point.xe.point.y?"Top":"Bottom")),n.sourcePortWrapper&&s===ls(r)?(("Left"===s||"Right"===s)&&t.point.y>=t.corners.top&&t.point.y<=t.corners.center.y&&e.point.y>=t.corners.top&&e.point.y<=t.corners.center.y?(t.direction="Top",a=t.point.y-t.corners.top+20):("Left"===s||"Right"===s)&&t.point.y>t.corners.center.y&&t.point.y<=t.corners.bottom&&e.point.y>t.corners.center.y&&e.point.y<=t.corners.bottom?(t.direction="Bottom",a=t.corners.bottom-t.point.y+20):("Top"===s||"Bottom"===s)&&t.point.x>=t.corners.left&&t.point.x<=t.corners.center.x&&e.point.x>=t.corners.left&&e.point.x<=t.corners.center.x?(t.direction="Left",a=t.point.x-t.corners.left+20):("Top"===s||"Bottom"===s)&&t.point.x<=t.corners.right&&t.point.x>t.corners.center.x&&e.point.x<=t.corners.right&&e.point.xt.point.y&&t.point.y>=e.corners.top?(i="Top",r=t.point.y-e.corners.top+20):e.corners.center.y===t.point.y&&"Top"===n.segments[n.segments.length-2].direction||e.corners.center.ye.point.y?t.point.y-t.corners.top+20:t.corners.bottom-t.point.y+20):(i="Top",r=e.corners.height/2+20):e.corners.center.x!==t.point.x||e.corners.topt.point.x&&t.point.x>=e.corners.left?(i="Left",r=t.point.x-e.corners.left+20):e.corners.center.x===t.point.x&&"Left"===n.segments[n.segments.length-2].direction||e.corners.center.x<=t.point.x&&t.point.x<=e.corners.right?(i="Right",r=e.corners.right-t.point.x+20):void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&t.corners.left<=t.point.x&&t.point.x<=t.corners.right&&(i=t.direction,r=t.point.x>e.point.x?t.point.x-t.corners.left+20:t.corners.right-t.point.x+20):(i="Left",r=e.corners.width/2+20);var a=t.point;t.point=Bn(t.point,"Left"===i||"Top"===i?-r:r,"Left"===i||"Right"===i?0:90),t.direction=z.direction(t.point,e.point),void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&(t.corners.center.x===e.corners.center.x||t.corners.center.y===e.corners.center.y)&&(t.direction=e.direction);var l=Ys(n,t,e);return l.splice(0,0,a),l}function f3(n,t,e){var i,r;e.corners=n.targetWrapper.corners,void 0!==n.sourcePortWrapper&&(r=zo({x:n.sourcePortWrapper.offsetX,y:n.sourcePortWrapper.offsetY},En(n.sourceWrapper),n.sourceWrapper.bounds));var a=function Cre(n,t,e,i){var r=!1;switch(e.direction){case"Left":void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&"Right"===i&&t.point.x>e.point.x&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom||("Bottom"===i&&t.point.y>e.point.y||"Top"===i&&t.point.y=t.corners.left&&t.point.x<=t.corners.right?(t.direction="Right"===i?t.point.y>e.point.y?"Top":"Bottom":t.point.xe.point.x&&(t.point.y>e.point.y||t.point.yt.point.y&&e.corners.bottome.point.y||t.point.x>e.point.x&&t.point.y<=e.point.y&&e.corners.top=t.point.y?t.direction="Top":t.point.xe.point.x&&t.point.y>e.point.y&&e.corners.bottomt.point.y?t.direction="Bottom":t.point.y===e.point.y&&t.point.xe.point.y||"Top"===i&&t.point.ye.point.x&&t.point.x>=t.corners.left&&t.point.x<=t.corners.right?(t.direction=t.point.x>e.point.x?"Left":"Right",r=!0):void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&"Left"===i&&t.point.x=t.corners.top&&t.point.y<=t.corners.bottom?(t.direction=t.point.y>e.point.y?"Top":"Bottom",r=!0):t.point.x=t.point.y&&t.point.y===e.point.y||t.point.y>e.point.y&&t.point.x>e.point.x?t.direction="Top":t.point.ye.point.x?t.direction="Bottom":t.point.xe.point.y||t.point.ye.point.x&&(t.direction="Left");break;case"Top":void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&"Bottom"===i&&t.point.y>e.point.y&&t.point.x>=t.corners.left&&t.point.x<=t.corners.right||("Right"===i&&t.point.x>e.point.x||"Left"===i&&e.point.y>t.point.y&&e.point.x>t.point.x)&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom?(t.direction="Bottom"===i?t.point.x>e.point.x?"Left":"Right":t.point.ye.point.y&&t.point.x>e.corners.left&&t.point.x=e.point.y?t.direction="Top":t.point.ye.point.x?t.direction="Left":t.point.yt.point.x)&&t.point.y>e.point.y&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom||"Top"===i&&t.point.y=t.corners.left&&t.point.x<=t.corners.right)?(t.direction="Right"===i||"Left"===i?t.point.y>e.point.y?"Top":"Bottom":t.point.x>e.point.x?"Left":"Right",r=!0):t.point.ye.corners.left&&e.corners.right>t.point.x?t.point.ye.corners.left&&e.corners.center.x>=t.point.x?t.direction="Left":t.point.ye.point.y&&t.point.x>e.point.x?t.direction="Left":t.point.y>e.point.y&&t.point.xe.point.x||e.point.x>t.point.x)&&(t.direction="Bottom")}return r}(n,t,e,r);return!n.selectedSegmentIndex&&void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&e.direction===ls(r)&&(("Left"===e.direction&&t.point.x>e.point.x||"Right"===e.direction&&t.point.x=t.corners.top&&t.point.y<=t.corners.bottom||"Bottom"===e.direction&&t.point.y=t.corners.left&&t.point.x<=t.corners.right)?i=p3(n,t,e):n.selectedSegmentIndex||t.direction!==e.direction?!n.selectedSegmentIndex&&("Left"===e.direction&&t.point.x>e.point.x||"Right"===e.direction&&t.point.x=t.point.y||"Top"===e.direction&&t.point.y>e.point.y||"Bottom"===e.direction&&t.point.y=t.point.x?i=n.selectedSegmentIndex?Nl(t,e):p3(n,t,e):!n.selectedSegmentIndex&&void 0!==n.sourceWrapper&&void 0!==n.targetWrapper&&void 0!==n.targetPortWrapper&&("Left"===t.direction||"Right"===t.direction)&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom&&("Top"===e.direction||"Bottom"===e.direction)&&e.corners.center.x===t.corners.center.x?(t.direction="Top"===e.direction?"Bottom":"Top",i=Ys(n,t,e,"Top"===e.direction?t.corners.bottom-t.point.y+20:t.point.y-t.corners.top+20)):!n.selectedSegmentIndex&&void 0!==n.sourceWrapper&&void 0!==n.targetWrapper&&void 0!==n.targetPortWrapper&&("Top"===t.direction||"Bottom"===t.direction)&&t.point.x>=t.corners.left&&t.point.x<=t.corners.right&&("Left"===e.direction||"Right"===e.direction)&&e.corners.center.y===t.corners.center.y?(t.direction="Left"===e.direction?"Right":"Left",i=Ys(n,t,e,"Left"===e.direction?t.corners.right-t.point.x+20:t.point.x-t.corners.left+20)):i=a?Ys(n,t,e,"Left"===t.direction||"Right"===t.direction?"Left"===t.direction?t.point.x-t.corners.left+20:t.corners.right-t.point.x+20:"Top"===t.direction?t.point.y-t.corners.top+20:t.corners.bottom-t.point.y+20):Nl(t,e):i=Ys(n,t,e),i}function g3(n,t,e){var r,i={x:t.offsetX,y:t.offsetY},s=En(e),o=zo(i,s,e.bounds),a=n.segments[0];return a.direction!==o&&(function Ore(n,t,e,i,r,s){var a,h,o=13,l=[];l.push(i),i.y===r.y&&("Left"===t&&r.xi.x)||i.x===r.x&&("Top"===t&&r.yi.y)||("Top"===t||"Bottom"===t?"Top"===t&&r.yi.y-o||"Bottom"===t&&r.y>i.y&&r.yo&&("Top"===t&&r.yi.y)?l.push({x:i.x,y:r.y}):(a=r.xi.x-o||"right"===t&&r.x>i.x&&r.xo&&("Left"===t&&r.xi.x)?l.push({x:r.x,y:i.y}):(l.push({x:a="Left"===t?e.left-o:e.right+o,y:i.y}),l.push({x:a,y:r.y})),s&&(l.push(n.points[0]),l.reverse()),n.points=l)}(a,o,s,a.points[0],a.points[a.points.length-1],!1),r=a.points[a.points.length-1],a.direction=z.direction(a.points[a.points.length-2],a.points[a.points.length-1])),r}function v3(n,t,e){var s,i=t.segments[t.segments.length-2],r=i.points[i.points.length-1];(("Top"===i.direction||"Bottom"===i.direction)&&r.x===n[1].x||("Left"===i.direction||"Right"===i.direction)&&r.y===n[1].y)&&(i.points[i.points.length-1]=n[1],s=z.direction(i.points[0],i.points[i.points.length-1]),void 0!==t.sourceWrapper&&void 0===t.sourcePortWrapper&&s===ls(i.direction)&&("Left"===i.direction||"Right"===i.direction?i.points[0].x="Right"===i.direction?i.points[0].x-t.sourceWrapper.corners.width:i.points[0].x+t.sourceWrapper.corners.width:i.points[0].y="Bottom"===i.direction?i.points[0].y-t.sourceWrapper.corners.height:i.points[0].y+t.sourceWrapper.corners.height),i.direction=s,i.length=z.distancePoints(i.points[0],i.points[i.points.length-1]),n.splice(0,1))}function DI(n,t,e,i){var o=i?n.targetPadding:n.sourcePadding,a=i?n.targetPortWrapper:n.sourcePortWrapper,l=new Ne(a.bounds.x-o,a.bounds.y-o,a.actualSize.width+2*o,a.actualSize.height+2*o),h=[l.topLeft,l.topRight,l.bottomRight,l.bottomLeft];h[h.length]=h[0];var d=i?e.point:t.point;return kx({x1:t.point.x,y1:t.point.y,x2:e.point.x,y2:e.point.y},h,0,d)||d}function m3(n,t){var e=[],i=mF(0,n.corners,t);i.push(i[0]);for(var r=0;r0){var r=void 0,s=[],o=t.point;for(r=0;r1&&z.equals(a.points[0],a.points[1])&&n.segments.splice(r,1),a)for(var l=0;l0||0===r)&&i.push(a.points[parseInt(l.toString(),10)])}}return i}function Ox(n,t,e){return"Top"===n||"Bottom"===n?e.x>t.x?"Right":"Left":e.y>t.y?"Bottom":"Top"}function _v(n){if("Straight"===n.type||"Bezier"===n.type){if(0===n.segments.length||n.segments.length>0&&!z.isEmptyPoint(n.segments[n.segments.length-1].point))if("Bezier"===n.type){var t=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0},!0);n.segments.push(t)}else t=new Pl(n,"segments",{type:"Straight"},!0),n.segments.push(t)}else{if(n.segments.length>0)for(var e=!1,i=0;i=t.corners.left&&e.point.x<=t.corners.right&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom)t.direction=e.point.y>t.point.y?"Bottom":"Top",i=Ys(n,t,e,"Top"===t.direction?t.point.y-t.corners.top+20:t.corners.bottom-t.point.y+20);else if(n.sourcePortWrapper&&r===ls(o)){var h;("Left"===r||"Right"===r)&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom?(t.direction=e.point.y>t.point.y?"Bottom":"Top",h=t.corners.height/2+20):("Top"===r||"Bottom"===r)&&t.point.x>=t.corners.left&&t.point.x<=t.corners.right&&(t.direction=e.point.x>t.point.x?"Right":"Left",h=t.corners.width/2+20),t.direction&&h?i=Ys(n,t,e,h,!0):(t.direction=o,i=Nl(t,e))}else if(!n.sourcePortWrapper||r!==e.direction||"Top"!==r&&"Bottom"!==r||t.corners.center.x!==e.corners.center.x)if(t.direction===e.direction)if(("Left"===t.direction||"Right"===t.direction)&&e.point.y>t.corners.top-20&&e.point.yt.corners.left-20&&e.point.xt.point.y?"Bottom":"Top",i=Ys(n,t,e,"Bottom"===t.direction?t.corners.bottom-t.point.y+20:t.point.y-t.corners.top+20);else t.direction=o,i=Ys(n,t,e,"Top"===o||"Bottom"===o?n.sourceWrapper.height/2+20:n.sourceWrapper.width/2+20),t.point=i[1],"Left"===o||"Right"===o?(e.direction=o,e.point="Left"===o?e.corners.middleLeft:e.corners.middleRight):Uv(n.targetWrapper,t,e,n),i=Ys(n,t,e);return i}function S3(n,t){if(void 0!==n.targetWrapper&&void 0===n.targetPortWrapper&&En(n.targetWrapper).containsPoint(t.point,1)){var i=n.targetWrapper,r=n.segments[n.segments.length-2],s=r.points[r.points.length-1],o=ls(r.direction);"Bottom"===o?s.yi.corners.top-1&&(r.points[r.points.length-1].y=i.corners.top-20,r.length=z.distancePoints(r.points[0],r.points[r.points.length-1])):"Left"===o?s.x>i.corners.left-1&&(r.points[r.points.length-1].x=i.corners.left-20,r.length=z.distancePoints(r.points[0],r.points[r.points.length-1])):"Right"===o&&s.x0||0===e)&&t.push(i.points[parseInt(r.toString(),10)]);return t}function Uv(n,t,e,i){var r,s={x:0,y:0},o=xI(n,n.corners,n.bounds),a=t.margin,l=t.point;if(o.bottomCenter.y+a.bottoml.y)r="Top",s=o.topCenter;else if(o.middleLeft.x-a.left>l.x)r="Left",s=o.middleLeft;else if(o.middleRight.x+a.rightc&&(p=c,r="Right",s=o.middleRight),p>d&&(p=d,r="Bottom",s=o.bottomCenter),p>u&&(r="Left",s=o.middleLeft)}e.point=s,e.direction=r;var f=Tc(o,ls(e.direction));e.point=Nh(i,0,e.point,f,n===i.targetWrapper)}function b3(n,t,e,i,r){var s,o,a;if(s=function Qre(n,t){var e=!1;switch(n){case"Left":switch(t){case"Right":case"Bottom":e=!0}break;case"Top":switch(t){case"Left":case"Right":case"Bottom":e=!0}break;case"Bottom":"Right"===t&&(e=!0)}return e}(t.direction,e.direction),s&&x3(t,e),"Right"===t.direction&&"Left"===e.direction)a=function kre(n,t,e,i){var o=Math.round(Math.abs(t.point.y-e.point.y)),a={x:Math.max(t.point.x,t.corners.right),y:t.point.y},l={x:Math.min(e.point.x,e.corners.left),y:e.point.y},h=Ga(n);if(i){var c=l;l=a,a=c}return t.corners.bottom+he.corners.bottom+h||("Bezier"!==n.type||e.corners.left-t.corners.right<=2*h&&e.corners.left-t.corners.right>=5)&&(h=0),t.margin={left:h,right:h,top:h,bottom:h},e.margin={left:h,right:h,top:h,bottom:h},0===o&&(t.corners.right=e.corners.right?void 0!==i&&(i.offsetYe.corners.bottom+e.margin.bottom)||void 0===i&&t.corners.middleRight.ye.corners.bottom+e.margin.bottom&&t.corners.top>e.corners.bottom||void 0===i&&t.corners.middleRight.y>e.corners.bottom||void 0!==i&&i.offsetYe.corners.top||void 0===i&&t.corners.middleRight.y>e.corners.bottom?Ae.Three:t.corners.rightr.offsetY+e.margin.right||void 0===r&&t.corners.top>e.corners.middleRight.y||void 0!==r&&(void 0!==i&&i.offsetXr.offsetX||void 0===r&&t.corners.left>e.corners.topCenter.x?Ae.Four:Ae.Two:void 0!==s&&Math.abs(t.corners.right-e.corners.left)<=5&&Math.abs(s.offsetY-e.corners.top)<=5||void 0!==r&&t.corners.right=25&&t.corners.middleRight.y+t.margin.righte.corners.bottom+e.margin.bottom||void 0===o&&t.corners.middleRight.y>e.corners.bottom+e.margin.bottom?t.corners.top>e.corners.bottom?void 0!==a&&t.corners.right+t.margin.righta.offsetX||void 0===a&&t.corners.left>e.corners.bottomCenter.x?Ae.Four:Ae.Two:void 0!==o&&Math.abs(t.corners.right-e.corners.left)<=25&&Math.abs(o.offsetY-e.corners.bottom)<=25?Ae.Two:Ae.Four}(n,t,e,s);else if("Bottom"===t.direction&&"Top"===e.direction)a=function Hre(n,t,e){var r=t.point.x-e.point.x,s=Ga(n);return t.corners.right+se.corners.right+s||("Bezier"!==n.type||e.corners.top-t.corners.bottom<=2*s&&e.corners.top-t.corners.bottom>=5)&&(s=0),t.margin={left:s,right:s,top:s,bottom:s},e.margin={left:s,right:s,top:s,bottom:s},0===r&&t.corners.bottome.corners.right+e.margin.right||void 0===i&&t.corners.bottomCenter.x>e.corners.right+e.margin.right?Ae.Three:t.corners.bottomr.offsetX||void 0===r&&t.corners.left>e.corners.left||void 0!==r&&t.corners.right+t.margin.righte.corners.bottom?Ae.Five:0===s||0===o?Ae.One:Ae.Three}(n,t,e)}else"Bottom"===t.direction&&"Left"===e.direction?a=function Bre(n,t,e,i){var r=n.sourcePortWrapper,s=n.targetPortWrapper,o=Ga(n);if(e.margin={left:o,right:o,top:o,bottom:o},t.margin={top:o,bottom:o,left:o,right:o},i){var l=r;r=s,s=l}return void 0!==r&&r.offsetXs.offsetY||void 0===s&&t.corners.top>e.corners.middleLeft.y?Ae.Four:Ae.Two:void 0!==s&&Math.abs(t.corners.right-e.corners.left)<=25&&Math.abs(s.offsetY-t.corners.bottom)<=25?Ae.Two:Ae.Four}(n,t,e,s):"Left"===t.direction&&"Left"===e.direction?a=function Ure(n,t,e){var i=n.sourcePortWrapper,r=n.targetPortWrapper,s=Ga(n);t.margin={left:s,right:s,top:s,bottom:s},e.margin={left:s,right:s,top:s,bottom:s};var o=Math.round(Math.abs(t.point.x-e.point.x)),a=Math.round(Math.abs(t.point.y-e.point.y));return t.corners.leftr.offsetY||void 0===r&&t.corners.top-t.margin.top>e.corners.middleLeft.y?Ae.Three:t.corners.righte.corners.bottom+e.margin.bottom||void 0===i&&t.corners.middleLeft.y>e.corners.bottom+e.margin.bottom?Ae.Three:t.corners.left>e.corners.right?Ae.Five:0===o||0===a?Ae.One:Ae.Three}(n,t,e):"Left"===t.direction&&"Top"===e.direction?a=function _re(n,t,e,i){var s=n.sourcePortWrapper,o=Ga(n);e.margin={left:o,right:o,top:o,bottom:o},t.margin={top:o,bottom:o,left:o,right:o};var a=n.targetPortWrapper,l={x:Math.min(t.point.x,t.corners.left),y:t.point.y},h={x:e.point.x,y:Math.min(e.point.y,e.corners.top)};if(i){var c=s;s=a,a=c;var d=l;l=h,h=d}return void 0!==s&&s.offsetYa.offsetX||void 0===a&&t.corners.left-t.margin.left>e.corners.topCenter.x?Ae.Two:Ae.Four:void 0!==a&&t.corners.rightr.offsetX||void 0===r&&t.corners.left>e.corners.left||void 0!==r&&t.corners.right+t.margin.righte.corners.right+e.margin.right||void 0===i&&t.corners.left>e.corners.right||void 0!==i&&i.offsetXe.corners.bottom?Ae.Five:0===s||0===o?Ae.One:Ae.Three}(n,t,e));return s&&x3(t,e),o=function Vre(n,t,e,i,r,s){var l,d,h=n.sourceWrapper.corners,c=n.targetWrapper.corners,u=20,p={corners:e.corners,point:e.point,direction:e.direction,margin:e.margin},f={corners:i.corners,point:i.point,direction:i.direction,margin:i.margin};if(!(p.direction===f.direction&&t!==Ae.Five||p.direction!==ls(f.direction)&&t!==Ae.Three))switch(p.direction){case"Left":h.middleLeft.x>c.middleRight.x&&(d=(h.middleLeft.x-c.middleRight.x)/2,u=s?d:Math.min(u,d));break;case"Right":h.middleRight.xc.bottomCenter.y&&(d=(h.topCenter.y-c.bottomCenter.y)/2,u=s?d:Math.min(u,d));break;case"Bottom":h.bottomCenter.yp&&hp)&&o>c&&o<=d&&e>=20&&(s=n.point.x-t.corners.left+s),i&&n.direction===t.direction&&n.corners.left>t.corners.left&&n.corners.left-t.corners.right>=20&&(s=(n.corners.left-t.corners.right)/2),f=Bn(n.point,s,180);break;case"Top":(o>c&&oc)&&h>p&&h<=u&&e>=20&&(s=n.point.y-t.corners.top+s),i&&n.direction===t.direction&&n.corners.top>t.corners.top&&n.corners.top-t.corners.bottom>=20&&(s=(n.corners.top-t.corners.bottom)/2),f=Bn(n.point,s,270);break;case"Right":(h>p&&hp)&&a=c&&e>=20&&(s=t.corners.right-n.point.x+s),i&&n.direction===t.direction&&n.corners.right=20&&(s=(t.corners.left-n.corners.right)/2),f=Bn(n.point,s,0);break;case"Bottom":(o>c&&oc)&&l=p&&e>=20&&(s=t.corners.bottom-n.point.y+s),i&&n.direction===t.direction&&n.corners.bottom=20&&(s=(t.corners.top-n.corners.bottom)/2),f=Bn(n.point,s,90)}r=[n.point,f];var g=void 0;if("Top"===n.direction||"Bottom"===n.direction){var v=n.direction;n.direction=f.x>t.point.x?"Left":"Right",n.point=f,r=TI(n,t,v,r,g=i?.5*Math.abs(f.x-t.point.x):g,i)}else v=n.direction,n.direction=f.y>t.point.y?"Top":"Bottom",n.point=f,r=TI(n,t,v,r,g=i?.5*Math.abs(f.y-t.point.y):g,i);return r}(p,f,u,g)),l}(n,a,t,e,i,r),"Bezier"===n.type&&function Yre(n,t,e){if("Bezier"===n.type)if(0===n.segments.length){var i=e[0],r=e[e.length-1];if(t===Ae.One){var s=Math.min(20,.5*z.findLength(i,r)),o={angle:Gt(i,r),distance:s},a={angle:Gt(r,i),distance:s},l=z.direction(i,r),c=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,orientation:"Left"===l||"Right"===l?"Horizontal":"Vertical"},!0);n.segments.push(c)}else if(t===Ae.Two)o={angle:Gt(i,d=e[1]),distance:.5*z.findLength(i,d)},a={angle:Gt(r,d),distance:.5*z.findLength(r,d)},l=z.direction(i,d),c=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,orientation:"Left"===l||"Right"===l?"Horizontal":"Vertical"},!0),n.segments.push(c);else if(t===Ae.Three){var d={x:.5*((u=e[1]).x+(p=e[e.length-2]).x),y:.5*(u.y+p.y)},f=(o={angle:Gt(i,u),distance:.5*z.findLength(i,u)},a={angle:Gt(d,u),distance:.5*z.findLength(d,u)},z.direction(i,u)),v=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,point:d,orientation:"Left"===f||"Right"===f?"Horizontal":"Vertical"},!0);n.segments.push(v);var y={angle:Gt(d,p),distance:.5*z.findLength(d,p)},S={angle:Gt(r,p),distance:.5*z.findLength(r,p)},b=z.direction(d,p),w=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:y,vector2:S,orientation:"Left"===b||"Right"===b?"Horizontal":"Vertical"},!0);n.segments.push(w)}else if(t===Ae.Four){var D={x:.5*((u=e[1]).x+(p=e[2]).x),y:.5*(u.y+p.y)},A={x:.5*(p.x+(C=e[3]).x),y:.5*(p.y+C.y)};o={angle:Gt(i,u),distance:.5*z.findLength(i,u)},a={angle:Gt(D,u),distance:.5*z.findLength(D,u)},f=z.direction(i,u),v=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,point:D,orientation:"Left"===f||"Right"===f?"Horizontal":"Vertical"},!0),n.segments.push(v),y={angle:Gt(D,p),distance:.5*z.findLength(D,p)},S={angle:Gt(A,p),distance:.5*z.findLength(A,p)},b=z.direction(D,p),w=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:y,vector2:S,point:A,orientation:"Left"===b||"Right"===b?"Horizontal":"Vertical"},!0),n.segments.push(w);var x={angle:Gt(A,C),distance:.5*z.findLength(A,C)},R={angle:Gt(r,C),distance:.5*z.findLength(r,C)},L=z.direction(A,C),N=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:x,vector2:R,orientation:"Left"===L||"Right"===L?"Horizontal":"Vertical"},!0);n.segments.push(N)}else if(t===Ae.Five){var u,p,C,T=e[4],P=(D={x:.5*((u=e[1]).x+(p=e[2]).x),y:.5*(u.y+p.y)},A={x:.5*(p.x+(C=e[3]).x),y:.5*(p.y+C.y)},{x:.5*(C.x+T.x),y:.5*(C.y+T.y)});o={angle:Gt(i,u),distance:.5*z.findLength(i,u)},a={angle:Gt(D,u),distance:.5*z.findLength(D,u)},f=z.direction(i,u),v=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,point:D,orientation:"Left"===f||"Right"===f?"Horizontal":"Vertical"},!0),n.segments.push(v),y={angle:Gt(D,p),distance:.5*z.findLength(D,p)},S={angle:Gt(A,p),distance:.5*z.findLength(A,p)},b=z.direction(D,p),w=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:y,vector2:S,point:A,orientation:"Left"===b||"Right"===b?"Horizontal":"Vertical"},!0),n.segments.push(w),x={angle:Gt(A,C),distance:.5*z.findLength(A,C)},R={angle:Gt(P,C),distance:.5*z.findLength(P,C)},L=z.direction(A,C),N=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:x,vector2:R,point:P,orientation:"Left"===L||"Right"===L?"Horizontal":"Vertical"},!0),n.segments.push(N);var _={angle:Gt(P,T),distance:.5*z.findLength(P,T)},B={angle:Gt(r,T),distance:.5*z.findLength(r,T)},j=z.direction(P,T),oe=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:_,vector2:B,orientation:"Left"===j||"Right"===j?"Horizontal":"Vertical"},!0);n.segments.push(oe)}else c=new ps(n,"segments",{type:"Bezier"},!0),n.segments.push(c)}else for(var ue=0;ue=13?13:n.connectorSpacing<=1?1:n.connectorSpacing}function Gt(n,t){var i=z.findLength({x:t.x,y:n.y},t),r=z.findLength(t,n),s=Math.asin(i/r);return s=180*s/Math.PI,n.xt.y&&(s=360-s):s=n.y0)for(var l=1;lc)&&(s=c,a=h),s>=0&&s<=1)break}}return a}function w3(n,t){var c,d,u,p,f,g,S,b,M,w,D,e=n.x1,i=n.y1,r=n.x2,s=n.y2,o=t.x1,a=t.y1,l=t.x2,h=t.y2;if(w=(c=s-i)*l+(u=e-r)*h+(f=r*i-e*s),0!==(M=c*o+u*a+f)&&0!==w&&C3(M,w)||(b=(d=h-a)*r+(p=o-l)*s+(g=l*a-o*h),0!==(S=d*e+p*i+g)&&0!==b&&C3(S,b)))return null;var A=c*p-d*u;return 0===A?null:(A<0?-A/2:A/2,0,{x:(D=u*g-p*f)<0?(D-0)/A:(D+0)/A,y:(D=d*f-c*g)<0?(D-0)/A:(D+0)/A})}function C3(n,t){return n*t>=0}function E3(n,t,e){switch(t.direction){case"Left":t.point.x>n.left&&(e=t.point.x-n.left>e?t.point.x-n.left+e:e);break;case"Right":t.point.xe?n.right-t.point.x+e:e);break;case"Top":t.point.y>n.top&&(e=t.point.y-n.top>e?t.point.y-n.top+e:e);break;case"Bottom":t.point.ye?n.bottom-t.point.y+e:e)}return e}function Nl(n,t){var e;switch(n.direction){case"Left":case"Right":var i={x:t.point.x,y:n.point.y};e=z.equals(n.point,i)||z.equals(t.point,i)?[n.point,t.point]:[n.point,i,t.point];break;case"Top":case"Bottom":var r={x:n.point.x,y:t.point.y};e=z.equals(n.point,r)||z.equals(t.point,r)?[n.point,t.point]:[n.point,r,t.point]}return e}function Ys(n,t,e,i,r,s){void 0===s&&(s=!1),i||(i=20),s&&t.direction!==e.direction&&(i="Left"===t.direction||"Right"===t.direction?Math.floor(.5*Math.abs(t.point.x-e.point.x)):Math.floor(.5*Math.abs(t.point.y-e.point.y)));var l,h,u,o=n.sourcePortWrapper,c=e.point.x-t.point.x,d=e.point.y-t.point.y;if(!r&&(Math.abs(c)<.001||Math.abs(d)<.001)&&void 0===e.direction)return[t.point,e.point];if(void 0===n.targetWrapper&&Math.abs(c)<=31&&Math.abs(d)<=31){if("Left"===t.direction||"Right"===t.direction?Math.abs(d)<12&&(t.direction=t.point.y>e.point.y?"Top":"Bottom"):Math.abs(c)<12&&(t.direction=t.point.x>e.point.x?"Left":"Right"),Math.abs(c)>12||Math.abs(d)>12)return Nl(t,e);i+=5}return"Left"===t.direction||"Right"===t.direction?("Right"===t.direction?(void 0!==e.direction&&"Right"===e.direction&&(i=Math.max(t.point.x,e.point.x)-t.point.x+i),t.point.x>e.point.x&&void 0===o&&(i=-i)):(void 0!==e.direction&&"Left"===e.direction&&(i=t.point.x-Math.min(t.point.x,e.point.x)+i),(t.point.x>e.point.x||void 0!==o||"Left"===t.direction)&&(i=-i)),u=e.point.y-t.point.y,l=Bn(t.point,i,0),0!=(u=e.point.y-l.y)&&(h=Bn(l,e.point.y-l.y,90))):("Top"===t.direction||"Bottom"===t.direction)&&("Bottom"===t.direction?void 0!==e.direction&&"Bottom"===e.direction&&(i=Math.max(t.point.y,e.point.y)-t.point.y+i):(void 0!==e.direction&&"Top"===e.direction&&(i=t.point.y-Math.min(t.point.y,e.point.y)+i),(t.point.y>e.point.y||void 0!==o||"Top"===t.direction)&&(i=-i)),u=e.point.x-t.point.x,l=Bn(t.point,i,90),0!=(u=e.point.x-l.x)&&(h=Bn(l,e.point.x-l.x,0))),0===u?[t.point,e.point]:[t.point,l,h,e.point]}function TI(n,t,e,i,r,s){var o;switch(void 0===r&&(r=20),void 0===s&&(s=!1),void 0===e?(n.margin={left:2,right:2,top:2,bottom:2},t.margin={left:0,right:5,top:0,bottom:5},s&&(n.margin={left:10,right:10,top:10,bottom:10},t.margin={left:10,right:10,top:10,bottom:10},"Left"===n.direction?(r=zx(n,t,e,r),n.corners.left-t.corners.right>=5&&(r=Math.abs(n.point.x-n.corners.left)+.5*Math.floor(n.corners.left-t.corners.right))):"Right"===n.direction?(r=Rx(n,t,r,e),t.corners.left-n.corners.right>=5&&(r=Math.abs(n.point.x-n.corners.right)+.5*Math.floor(t.corners.left-n.corners.right))):"Top"===n.direction?(r=Px(n,t,e,r),n.corners.top-t.corners.bottom>=5&&(r=Math.abs(n.point.y-n.corners.top)+.5*Math.floor(n.corners.top-t.corners.bottom))):"Bottom"===n.direction&&(r=Hx(n,t,r,e),t.corners.top-n.corners.bottom>=5&&(r=Math.abs(n.point.y-n.corners.bottom)+.5*Math.floor(t.corners.top-n.corners.bottom))))):("Bottom"===n.direction?s?t.corners.top-n.corners.bottom<20&&(r=t.corners.bottom-n.point.y+25):t.corners.top>n.corners.bottom&&t.corners.top-n.corners.bottom<20&&(r=(t.corners.top-n.corners.bottom)/2):"Top"===n.direction?s?n.corners.top-t.corners.bottom<20&&(r=n.point.y-t.corners.top+25):t.corners.bottomn.corners.right&&t.corners.left-n.corners.right<20&&(r=(t.corners.left-n.corners.right)/2):"Left"===n.direction&&(s?n.corners.left-t.corners.right<20&&(r=n.point.x-t.corners.left+25):t.corners.rightt.point.y||"Top"===t.direction&&n.point.yt.point.x||"Left"===t.direction&&n.point.xh||e.corners.top-e.margin.top<=i.point.y&&e.corners.bottom+e.margin.bottom>=i.point.y))if(!s||"Top"!==e.direction&&"Bottom"!==e.direction)c=Math.min(Math.abs(i.corners.left-e.corners.right)/2,20),h=e.corners.right-n.x+c;else{var c=Math.abs(i.corners.left-e.corners.right)/2;h=e.corners.right-n.x+c}else h="Top"===e.direction&&n.y>i.point.y||"Bottom"===e.direction&&n.y=e.corners.left-e.margin.left&&n.x<=e.corners.right+e.margin.right?Math.min(i.corners.left,e.corners.left)-n.x-20:i.corners.left-n.x-20;break;case"Right":if(e.corners.left-e.margin.left>i.corners.right+i.margin.right&&(e.corners.left-e.margin.right-i.corners.right>h||e.corners.top-e.margin.top<=i.point.y&&e.corners.bottom+e.margin.bottom>=i.point.y))if(!s||"Top"!==e.direction&&"Bottom"!==e.direction)c=Math.min(Math.abs(e.corners.left-i.corners.right)/2,20),h=e.corners.left-n.x-c;else{c=Math.abs(e.corners.left-i.corners.right)/2;h=e.corners.left-n.x-c}else h="Top"===e.direction&&n.y>i.point.y||"Bottom"===e.direction&&n.y=e.corners.left-e.margin.left&&n.x<=e.corners.right+e.margin.right?Math.max(i.corners.right,e.corners.right)-n.x+20:i.corners.right-n.x+20}o=Bn(n,h,0),a=Bn(o,i.point.y-n.y,90),l=i.point}else if("vertical"===t){switch(i.direction){case"Top":e.corners.bottom+e.margin.bottomh||e.corners.left-e.margin.left<=i.point.x&&e.corners.right+e.margin.right>=i.point.x)?!s||"Right"!==e.direction&&"Left"!==e.direction?(c=Math.min(Math.abs(i.corners.top-e.corners.bottom)/2,20),h=e.corners.bottom-n.y+c):(c=Math.abs(i.corners.top-e.corners.bottom)/2,h=e.corners.bottom-n.y+c):h="Left"===e.direction&&n.x>i.point.x||"Right"===e.direction&&n.x=e.corners.top-e.margin.top&&n.y<=e.corners.bottom+e.margin.bottom?Math.min(i.corners.top,e.corners.top)-n.y-20:i.corners.top-n.y-20;break;case"Bottom":e.corners.top-e.margin.top>i.corners.bottom+i.margin.bottom&&(e.corners.top-e.margin.top-i.corners.bottom>h||e.corners.left-e.margin.left<=i.point.x&&e.corners.right+e.margin.right>=i.point.x)?!s||"Right"!==e.direction&&"Left"!==e.direction?(c=Math.min(Math.abs(e.corners.top-i.corners.bottom)/2,20),h=e.corners.top-n.y-c):(c=Math.abs(e.corners.top-i.corners.bottom)/2,h=e.corners.top-n.y-c):h="Left"===e.direction&&n.x>i.point.x||"Right"===e.direction&&n.x=e.corners.top-e.margin.top&&n.y<=e.corners.bottom+e.margin.bottom?Math.max(i.corners.bottom,e.corners.bottom)-n.y+20:i.corners.bottom-n.y+20}o=Bn(n,h,90),a=Bn(o,i.point.x-n.x,0),l=i.point}r.push(o),r.push(a),r.push(l)}function Px(n,t,e,i){return n.corners.top-n.margin.top>t.corners.top+t.margin.top&&n.corners.top-n.margin.top<=t.corners.bottom+t.margin.bottom?(("Right"===t.direction&&n.point.xt.point.x)&&(i+=n.corners.top-t.corners.top),i+=n.point.y-n.corners.top):i+=void 0!==e&&"Left"!==e&&"Right"===t.direction&&n.point.xt.corners.left-t.margin.left&&n.corners.left-n.margin.left<=t.corners.right+t.margin.right?(("Bottom"===t.direction&&n.point.yt.point.y)&&(i+=n.corners.left-t.corners.left),i+=n.point.x-n.corners.left):i+=void 0!==e&&"Top"!==e&&"Bottom"===t.direction&&n.point.y=t.corners.left-t.margin.left?(("Bottom"===t.direction&&n.point.yt.point.y)&&(e+=t.corners.right-n.corners.right),e+=n.corners.right-n.point.x):e+=void 0!==i&&"Top"!==i&&"Bottom"===t.direction&&n.point.y=t.corners.top-t.margin.top?(("Right"===t.direction&&n.point.xt.point.x)&&(e+=t.corners.bottom-n.corners.bottom),e+=n.corners.bottom-n.point.y):e+=void 0!==i&&"Left"!==i&&"Right"===t.direction&&n.point.xf&&d=u&&d=p&&d<=f?"Left":"Right"}function ls(n){switch(n){case"Top":return"Bottom";case"Bottom":return"Top";case"Left":return"Right";case"Right":return"Left"}return"auto"}var A3=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Ac=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},AI=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return A3(t,n),Ac([I()],t.prototype,"width",void 0),Ac([I()],t.prototype,"height",void 0),t}(Ee),Gre=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return A3(t,n),Ac([I()],t.prototype,"width",void 0),Ac([I()],t.prototype,"height",void 0),Ac([I()],t.prototype,"fit",void 0),Ac([I()],t.prototype,"description",void 0),Ac([I()],t.prototype,"template",void 0),Ac([I()],t.prototype,"tooltip",void 0),t}(Ee),Xre=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Ol=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},L3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Xre(t,n),Ol([I("")],t.prototype,"id",void 0),Ol([I(Number.MIN_VALUE)],t.prototype,"zIndex",void 0),Ol([re({},$n)],t.prototype,"margin",void 0),Ol([I(!0)],t.prototype,"visible",void 0),Ol([re({},xd)],t.prototype,"tooltip",void 0),Ol([I(!1)],t.prototype,"excludeFromLayout",void 0),Ol([I()],t.prototype,"addInfo",void 0),Ol([I("None")],t.prototype,"flip",void 0),Ol([I("All")],t.prototype,"flipMode",void 0),Ol([re({},Gre)],t.prototype,"symbolInfo",void 0),t}(Ee),qre=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Jn=function(n){function t(e,i,r,s){var o=n.call(this)||this;return o.data="",o.nodeId="",o.annotationId="",o.diagramId="",o.diagramId=i,o.nodeId=e,o.annotationId=r,o.templateFn=GF(s),o}return qre(t,n),t.prototype.getNodeTemplate=function(){return this.templateFn},Object.defineProperty(t.prototype,"content",{get:function(){return this.data},set:function(e){this.data=e,this.canReset||(this.canReset=!0,this.isTemplate||(this.template=Bh(this,!0)),this.canReset=!1,this.isDirt=!0)},enumerable:!0,configurable:!0}),t}(as),Bx=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),hs=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},N3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Bx(t,n),hs([I("")],t.prototype,"id",void 0),hs([I("transparent")],t.prototype,"fill",void 0),hs([I("black")],t.prototype,"iconStrokeColor",void 0),hs([I(0)],t.prototype,"iconStrokeWidth",void 0),hs([I(!0)],t.prototype,"visibility",void 0),hs([I(10)],t.prototype,"width",void 0),hs([I(10)],t.prototype,"height",void 0),hs([I("transparent")],t.prototype,"handleStrokeColor",void 0),hs([I(1)],t.prototype,"handleStrokeWidth",void 0),hs([I("")],t.prototype,"pathData",void 0),hs([I(0)],t.prototype,"cornerRadius",void 0),hs([re({left:0,right:0,top:0,bottom:0},$n)],t.prototype,"padding",void 0),hs([re({},xd)],t.prototype,"tooltip",void 0),t}(Ee),O3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Bx(t,n),hs([re({x:0,y:0},z)],t.prototype,"offset",void 0),hs([re({},$n)],t.prototype,"margin",void 0),t}(N3),LI=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Bx(t,n),hs([I(.5)],t.prototype,"offset",void 0),hs([I("Center")],t.prototype,"alignment",void 0),hs([re({x:0,y:0},z)],t.prototype,"displacement",void 0),t}(N3);function Td(n){return n?n instanceof Zn||n instanceof Nr?n.constraints&Lr.Select:n instanceof de?n.constraints&qe.Select:n.constraints&ie.Select:1}function to(n){return n?n instanceof Zn||n instanceof Nr?n.constraints&Lr.Drag:n instanceof de?n.constraints&qe.Drag:n instanceof si?1:n.constraints&ie.Drag:1}function $re(n,t){return n instanceof de?n.constraints&qe.PointerEvents:n.constraints&ie.PointerEvents}function NI(n){return n instanceof de?n.constraints&qe.Delete:n.constraints&ie.Delete}function OI(n){return n.constraints&qe.DragSourceEnd}function kI(n){return n.constraints&qe.DragTargetEnd}function PI(n){return n.constraints&qe.DragSegmentThumb}function zI(n){return n instanceof Zn||n instanceof Nr?n.constraints&Lr.Rotate:n.constraints&ie.Rotate}function RI(n){return n.constraints&ie.Shadow}function da(n){return n instanceof te&&n.constraints&ie.InConnect?n.constraints&ie.InConnect:0}function Oh(n){return n&&n.constraints&&!(n.constraints&ri.None)&&n.constraints&ri.InConnect?n.constraints&ri.InConnect:0}function kh(n){return n instanceof te&&n.constraints&ie.OutConnect?n.constraints&ie.OutConnect:0}function Ad(n){return n&&n.constraints&&!(n.constraints&ri.None)&&n.constraints&ri.OutConnect?n.constraints&ri.OutConnect:0}function kl(n,t){var e=0;return n instanceof Zn||n instanceof Nr?e=n.constraints&Lr.Resize:n&&("SouthEast"===t?e=n.constraints&ie.ResizeSouthEast:"East"===t?e=n.constraints&ie.ResizeEast:"NorthEast"===t?e=n.constraints&ie.ResizeNorthEast:"South"===t?e=n.constraints&ie.ResizeSouth:"North"===t?e=n.constraints&ie.ResizeNorth:"SouthWest"===t?e=n.constraints&ie.ResizeSouthWest:"West"===t?e=n.constraints&ie.ResizeWest:"NorthWest"===t&&(e=n.constraints&ie.ResizeNorthWest)),e}function HI(n){return n instanceof de?n.constraints&qe.AllowDrop:n.constraints&ie.AllowDrop}function Ds(n){return n.constraints&rt.Virtualization}function jv(n){return n.tool&Ci.SingleSelect}function Vv(n){return n.tool&Ci.MultipleSelect}function Lc(n){return n.tool&Ci.ZoomPan}function BI(n){return n.tool&Ci.ContinuousDraw}function k3(n){return n.tool&Ci.DrawOnce}function FI(n){return n.tool&Ci.SingleSelect||n.tool&Ci.MultipleSelect}function Wv(n){return n.constraints&rt.UserInteraction}function P3(n){return n.constraints&rt.ZoomTextEdit}function Yv(n){return function ine(n){return n.constraints&rt.ApiUpdate}(n)||n.diagramActions&ee.ToolAction}function Fx(n,t){return n.constraints&ri.Draw}function _x(n,t){return n.constraints&ri.Drag}function _I(n){return!(n&Qa.DrawSelectorBorder)}function z3(n){return!!(n&Qa.PreventRenderSelector)}var Ux=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Qv=function(n){function t(){var e=null!==n&&n.apply(this,arguments)||this;return e.childTable=[],e.cellStyle={},e.desiredRowHeight=[],e.desiredCellWidth=[],e}return Ux(t,n),t.prototype.rowDefinitions=function(){return this.rowDefns},t.prototype.columnDefinitions=function(){return this.colDefns},t.prototype.addObject=function(e,i,r,s,o){if(this.rows.length>=i){var a=this.rows[parseInt(i.toString(),10)];if(a.cells.length>r){o=o||1,s=s||1;var l=a.cells[parseInt(r.toString(),10)];l.columnSpan=Math.max(o,l.columnSpan),l.rowSpan=Math.max(s,l.rowSpan);var h=new ane;(h=e).rowId=i,h.columnId=r,h.columnSpan=o,this.childTable[h.id]=h,this.addObjectToCell(h,l)}}},t.prototype.addObjectToCell=function(e,i){i.children||(i.children=[]),e.style.strokeColor="black",e.style.strokeWidth=1,i.children.push(e)},t.prototype.updateProperties=function(e,i,r,s){this.offsetX=e,this.offsetY=i,this.width=r,this.height=s},t.prototype.setDefinitions=function(e,i){this.rowDefns=e,this.colDefns=i,this.children=[],this.rows=this.rows||[];for(var r=0;r0){for(var h=0;hi&&this.updateRowHeight(e,l,!1)}},t.prototype.setTextRefresh=function(e){if(e.children&&e.children.length)for(var i=e.children,r=0;ri&&this.updateColumnWidth(e,a,!1)}},t.prototype.calculateCellWidth=function(e){for(var i,r,s,o=0;os.bounds.width&&(0===s.children.length||void 0===s.children[0].maxWidth)?s.outerBounds.width:s.bounds.width,i=i?is.bounds.height?s.outerBounds.height:s.bounds.height,i=i?i0?e.children[0]:void 0;if(a&&1===e.columnSpan){o="Width"===i?a.bounds.right:a.bounds.bottom,s||(s="Width"===i?a.bounds.width:a.bounds.height);for(var l=0;lo){var d=c-o+("Width"===i?a.bounds.width:a.bounds.height);s&&(s=s0?this.rowDefns.splice(e,0,i):this.rowDefns.push(i);var s=new R3;s.cells=[],(new Ld).width=this.width,this.addCellInRow(this.colDefns,i,s),e>this.rows.length-1?this.rows.push(s):this.rows.splice(e,0,s),r&&(this.measure(new me(this.width,this.height)),this.arrange(this.desiredSize))},t.prototype.addColumn=function(e,i,r){var s,o,a,l,h=this.rows;this.colDefns.length>0?this.colDefns.splice(e,0,i):this.colDefns.push(i),void 0!==this.width&&(this.width+=i.width);for(var c=0;cs.cells.length-1?s.cells.push(l):s.cells.splice(e,0,l),this.children.push(l);r&&(this.measure(new me(this.width,this.height)),this.arrange(this.desiredSize))},t.prototype.removeRow=function(e){var i,r,o=this.rows[parseInt(e.toString(),10)];this.height-=this.rowDefns[parseInt(e.toString(),10)].height;for(var a=0;a0){var r=0,s=0;i=new me(0,0),this.calculateSize();for(var o=0,a=this.rows;o0){for(var o=this.offsetX-e.width*this.pivot.x,a=this.offsetY-e.height*this.pivot.y,l=o,h=0,c=this.rows;h1&&this.children.splice(this.children.indexOf(f)+1,f.columnSpan-1),f.rowSpan>1)for(y=s,S=0;y+f.rowSpan-10){for(var c=0;c0?1:0,v=0;v0||a.outEdges.length>0))for(p=a.inEdges.concat(a.outEdges),s=0;s0)for(o=0;o1)for(a=1;a0))if(h=n.wrapper.children[0],"Horizontal"===e.orientation)for(o=e.header&&e.hasHeader?h.rows[1]:h.rows[0],r=0;r0){var e=void 0;t.lineRoutingModule&&t.constraints&rt.LineRouting&&t.lineRoutingModule.renderVirtualRegion(t,!0);for(var i=0;i0?o+1:o)].height=t.wrapper.height;else if(t.isPhase)for(l[t.rowIndex-o].offset=t.wrapper.height,f=0;f0?1:0)].width=t.wrapper.width}function jI(n,t){var i=n.shape,r=i.header&&i.hasHeader?1:0;return"Horizontal"===i.orientation?t.rowIndex-(r+=i.phases.length>0?1:0):t.columnIndex-(i.phaseSize&&i.phases.length>0?1:0)}function VI(n){var t=0,e=n.shape;return"Horizontal"===e.orientation&&(t=e.header&&e.hasHeader?1:0),e.phases.length>0&&e.phaseSize&&(t+=1),t}function WI(n,t,e,i){var r=n.shape;if(r.phases.length>0){var s=t.nameTable[r.phases[parseInt(i.toString(),10)].header.id];s&&s.maxWidth0?u+1:u);var w=Nc(n,o),C=void 0!==i?i:l.lanes.length;if(u+=C,r={element:M,cause:n.diagramActions,diagramAction:n.getDiagramAction(n.diagramActions),state:"Changing",type:"Addition",cancel:!1,laneIndex:C},n.triggerEvent(Ce.collectionChange,r),!r.cancel){if(c){var D=new Gv;D.height=e.height,o.addRow(u,D,!1),s.height=void 0!==s.height?s.height+e.height:s.height,s.wrapper.height=o.height=s.height}else{var A=new Ld;A.width=e.width,o.addColumn(C+1,A,!1),s.width&&(s.width+=e.width,s.wrapper.width=o.width=s.width),n.diagramActions&ee.UndoRedo||(o.rows[0].cells[0].columnSpan+=1)}n.diagramActions&ee.UndoRedo||(M.id=""===M.id?Qe():M.id),void 0!==i?l.lanes.splice(i,0,M):l.lanes.push(M),r={element:M,cause:n.diagramActions,diagramAction:n.getDiagramAction(n.diagramActions),state:"Changed",type:"Addition",cancel:!1,laneIndex:C},n.triggerEvent(Ce.collectionChange,r),B3(o,n,s,u,C,c),h="Horizontal"===l.orientation?n.nameTable[o.rows[parseInt(u.toString(),10)].cells[0].children[0].id]:l.header&&l.hasHeader?n.nameTable[o.rows[1].cells[parseInt(u.toString(),10)].children[0].id]:n.nameTable[o.rows[0].cells[parseInt(u.toString(),10)].children[0].id],n.diagramActions&ee.UndoRedo||(d={type:"LaneCollectionChanged",changeType:"Insert",undoObject:$(M),redoObject:$(h),category:"Internal"},n.addHistoryEntry(d)),$p(n,s,"Horizontal"===l.orientation?u:l.header&&l.hasHeader?1:0),qp(s),Oc(n,s);var R=!1;if((p=e.children)&&p.length>0)for(f=0;f0){var o=t.children[0],a=n.nameTable[o.id];(function vne(n,t,e){return n.left-(e.left||0)<=t.x&&n.right+(e.right||0)>=t.x&&n.top-(e.top||0)<=t.y&&n.bottom+(e.bottom||0)>=t.y})(o.bounds,e,r)&&(n.addChild(a,i),s=!0)}return s}function mne(n,t,e){if("SwimLane"===t.shape.type){var i=void 0,r=void 0,s=void 0,a=void 0,l=void 0,h=void 0,c=t.wrapper.bounds.x,d=t.wrapper.bounds.y,u=t.shape,p=u.padding,f=u.phases,g=void 0,v=t.wrapper.children[0],y="Horizontal"===u.orientation;if(i=u.header&&u.hasHeader?0:-1,u.phases.length>0&&(i+=1),e.offset>(y?u.lanes[0].header.width:u.lanes[0].header.height)){for(h=0;he.offset){if(g=h>0?e.offset-(h>0?f[h-1]:s).offset:e.offset,y){var b=v.columnDefinitions()[parseInt(h.toString(),10)];b.width-=g,(a=n.nameTable[u.phases[parseInt(h.toString(),10)].header.id]).maxWidth=a.wrapper.maxWidth=b.width,v.updateColumnWidth(h,b.width,!1);var M=new Ld;M.width=g,l=h,v.addColumn(h,M,!1);break}var w=v.rowDefinitions()[h+i];w.height-=g,a=n.nameTable[u.phases[parseInt(h.toString(),10)].header.id],v.updateRowHeight(h+i,w.height,!1);var C=new Gv;C.height=g,l=h,v.addRow(h+i,C,!1);break}if(n.diagramActions&ee.UndoRedo&&void 0===l&&(D=n.historyManager.currentEntry.next).isLastPhase&&function yne(n,t,e,i,r,s){var a=t.shape.phases[n-2],l=e.previousPhase.offset;if(r){var h=i.columnDefinitions()[n-1],c=new Ld;n>1?(c.width=h.width-(l-a.offset),h.width=l-a.offset):(c.width=h.width-l,h.width=l),i.updateColumnWidth(n-1,h.width,!1),i.addColumn(n,c,!1)}else{h=i.rowDefinitions()[parseInt(n.toString(),10)];var d=new Gv;n>1?(d.height=e.undoObject.offset-l,h.height=l-a.offset):(d.height=h.height-l,h.height=l),i.updateRowHeight(n,h.height,!1),i.addRow(1+n,d,!1)}}(l=f.length,t,D,v,y),l>=0){var A=new ub(t.shape,"phases",e,!0);if(n.diagramActions&ee.UndoRedo||(A.id+=Qe()),u.phases.splice(l,0,A),jx(v,n,t,i,y,l),y){if(r=n.nameTable[v.rows[parseInt(i.toString(),10)].cells[parseInt(l.toString(),10)].children[0].id],0===l&&u.header&&u.hasHeader){v.rows[0].cells[0].children=v.rows[0].cells[1].children,v.rows[0].cells[1].children=[];for(var x=v.rows[0],R=0;Rl+1){var O=n.nameTable[v.rows[parseInt(i.toString(),10)].cells[l+1].children[0].id];v.updateColumnWidth(l+1,L[l+1].width,!0,p),O.maxWidth=O.wrapper.maxWidth=L[l+1].width}t.width=t.wrapper.width=t.wrapper.children[0].width=v.width}else{r=n.nameTable[v.rows[i+l].cells[0].children[0].id];var N=v.rowDefinitions(),T=N[i+l].height;(function Ine(n,t,e,i,r){for(var o,a,l=e.rows[parseInt(i.toString(),10)],h=e.rows[i+1],c=e.rows[i-1],d=1;di+l+1&&v.updateRowHeight(i+l+1,T=N[i+l+1].height,!0,p),t.height=t.wrapper.height=t.wrapper.children[0].height=v.actualSize.height}if(qp(t),t.width=t.wrapper.actualSize.width,Oc(n,t),n.drag(t,c-t.wrapper.bounds.x,d-t.wrapper.bounds.y),UI(t,n),n.commandHandler.select(r),!(n.diagramActions&ee.UndoRedo)){var D={type:"PhaseCollectionChanged",changeType:"Insert",undoObject:$(A),redoObject:$(r),category:"Internal"};n.addHistoryEntry(D)}n.updateDiagramObject(t)}}}}function V3(n,t,e,i,r,s,o){var a,l,f,h=t.shape,c="Horizontal"===h.orientation,d=t.wrapper.children[0],g=c?s:o;e?(a=c?e.bounds.x+e.bounds.width:e.bounds.x,l=c?e.bounds.y:e.bounds.y+e.bounds.height):(a=d.bounds.x,l=r.bounds.y);var v=new Ne(a,l,i.desiredCellWidth,i.desiredCellHeight),S=Xv(n,0,t,{id:t.id+(c?h.lanes[g-2]:h.lanes[g-1]).id+Qe()[0],rowIndex:s,columnIndex:o,width:i.minWidth,height:i.minHeight,style:(c?h.lanes[g-2]:h.lanes[g-1]).style,constraints:ie.Default|ie.AllowDrop,container:{type:"Canvas",orientation:c?"Horizontal":"Vertical"}},!1,!1,!0);if(S.children[0].isCalculateDesiredSize=!1,d.addObject(S,s,o),r&&r.children&&r.children.length)for(f=0;f1)for(var f=1;fh.margin.left&&(h.margin.left=p)):(h.margin.top-=e.desiredCellHeight,p>h.margin.top&&(h.margin.top=p)))}(n,r,i,v,S,c,e)}function W3(n,t,e){if("SwimLane"===t.shape.type&&("ResizeSouth"===e||"ResizeEast"===e)){var i=t.shape,r=t.wrapper.children[0],s=void 0,o=void 0;"ResizeSouth"===e?"Vertical"===i.orientation?s=r.rows[r.rows.length-1].cells[0]:(o=r.rows.length-1,s=r.rows[parseInt(o.toString(),10)].cells[r.rows[parseInt(o.toString(),10)].cells.length-1]):(o=i.header&&i.hasHeader?1:0,s=r.rows[parseInt(o.toString(),10)].cells[r.rows[parseInt(o.toString(),10)].cells.length-1]),n.commandHandler.select(n.nameTable[s.children[0].id])}}function YI(n,t,e,i,r,s){var o,a,l,c,u,p,f,d=Qe(),g=n.shape,v=g.phases,y=n.offsetX-n.wrapper.actualSize.width/2,S=n.offsetY-n.wrapper.actualSize.height/2;if("Vertical"===g.orientation&&(S+=g.header&&g.hasHeader?g.header.height:0),!s)for(r||(n.id+=d,g&&g.header&&g.hasHeader?g.header.id+=d:g.header=void 0),o=0;v&&o0&&s.columnIndex>0||s.isLane)?(a=function Lne(n,t,e){for(var i=new Ne,r="SwimLane"===n.shape.type?n.wrapper.children[0].rows:n.wrapper.rows,s=e?1:0;s=0;a--)i?i.id===o.children[parseInt(a.toString(),10)].id&&o.children.splice(a,1):(n.removeDependentConnector(o.children[parseInt(a.toString(),10)]),n.diagramActions&ee.UndoRedo||(n.diagramActions=n.diagramActions|ee.UndoRedo,s=!0),n.remove(o.children[parseInt(a.toString(),10)]),o.children.splice(a,1),s&&(n.diagramActions=n.diagramActions&~ee.UndoRedo))}function Mne(n){return n.children[0]}function Zv(n,t){t&&(n.nodes.splice(n.nodes.indexOf(t),1),n.removeFromAQuad(t),n.removeObjectsFromLayer(t),delete n.nameTable[t.id],n.removeElements(t))}function Q3(n,t,e,i){var r;if("SwimLane"===e.shape.type){var s=e.shape,o=void 0;if(1===s.lanes.length)n.remove(e);else{var a=e.wrapper.bounds.x,l=e.wrapper.bounds.y,h=void 0,c=void 0,d=void 0,u=void 0,f=e.wrapper.children[0];if(o=i?s.lanes.indexOf(i):jI(e,t),r={element:t,cause:n.diagramActions,diagramAction:n.getDiagramAction(n.diagramActions),state:"Changing",type:"Removal",cancel:!1,laneIndex:o},n.triggerEvent(Ce.collectionChange,r),!r.cancel){var g=s.lanes[parseInt(o.toString(),10)],v=g.children;g.children=[];for(var y=0;y0)for(u=0;u0)for(u=0;u0)for(e=0;e1){c===l.phases.length-1&&(o=!0,a=$(l.phases[c-1]));var u=$(l.phases[parseInt(c.toString(),10)]);if(l.phases.splice(c,1),!(n.diagramActions&ee.UndoRedo)){var p={type:"PhaseCollectionChanged",changeType:"Remove",undoObject:u,previousPhase:a,redoObject:$(t),category:"Internal",isLastPhase:o};n.addHistoryEntry(p)}"Horizontal"===l.orientation?function Cne(n,t,e,i){var r,s,o,a,l,h,c,d,u,p,f,g;for(i=void 0!==i?i:e.columnIndex,c=0;c1&&(s=r.cells[parseInt(i.toString(),10)],l=(o=r.cells.length-1===i?r.cells[i-1]:r.cells[i+1]).children[0],s.children.length>0))if(f=n.nameTable[(a=s.children[0]).id],0===o.children.length&&s.children.length>0)o.children=s.children,o.columnSpan=s.columnSpan-1;else{for(d=0;d0){var M=s.children[0],w=n.nameTable[M.id];if(i=e.x&&a.bounds.y<=e.y&&a.bounds.bottom>=e.y)&&!(t.constraints&ie.AllowMovingOutsideLane)){var l=$(t);n.clearSelection(),$3(n,t),t.parentId="",t.parentObj=n,t.propName="nodes";var h={type:"ChildCollectionChanged",category:"Internal",undoObject:l,redoObject:$(t)};n.addHistoryEntry(h),n.commandHandler.isContainer&&(n.commandHandler.isContainer=!1,n.endGroupAction()),Z3(t,n)}n.protectPropertyChange(o)}}function QI(n,t){var e,i,r;return n.enableServerDataBinding(!1),ce()||(n.selectedObject.helperObject?r=n.selectedObject.helperObject:(n.selectedItems.nodes.length>0||n.selectedItems.connectors.length>0)&&(t instanceof si&&t.nodes.length+t.connectors.length===1?(e=t.nodes.length>0?t.nodes[0]:t.connectors[0],i=n.selectedItems.wrapper.children[0]):(e=t,i=n.selectedItems.wrapper),n.selectedObject.actualObject=e,!n.currentSymbol&&(e.isLane&&Qx(e,n)&&cs(n,e)||!e.isLane&&cs(n,e)||n.constraints&rt.LineRouting&&n.selectedItems.nodes.length>0))&&(r=function Nne(n,t){for(var e,i={},r=0,s=Object.keys(t);r=t.x-e&&n.x<=t.x+e&&n.y>=t.y-e&&n.y<=t.y+e}function Xa(n){return n.selectedItems.nodes.length>0||n.selectedItems.connectors.length>0}function K3(n){return 1===n.selectedItems.connectors.length&&!n.selectedItems.nodes.length}function _r(n,t,e,i){if(void 0===e&&(e=!0),t instanceof si)return!0;if(t instanceof te)for(;t;){if(-1!==n.selectedItems.nodes.indexOf(t)&&void 0===n.selectedItems.annotation)return!0;if(e)break;t=n.nameTable[t.parentId]}else if(t instanceof de){if(-1!==n.selectedItems.connectors.indexOf(t)&&void 0===n.selectedItems.annotation)return!0}else if((t instanceof Zn||t instanceof Nr)&&n.selectedItems.annotation&&n.selectedItems.wrapper.children[0].id===i.id)return!0;return!1}var Gx={None:"default",Rotate:"crosshair",Select:"default",Drag:"move",ResizeWest:"w-resize",ResizeEast:"e-resize",ResizeSouth:"s-resize",ResizeNorth:"n-resize",Draw:"crosshair",PortDraw:"crosshair",ResizeNorthEast:"ne-resize",ResizeNorthWest:"nw-resize",ResizeSouthEast:"se-resize",ResizeSouthWest:"sw-resize",ConnectorSourceEnd:"move",ConnectorTargetEnd:"move",BezierSourceThumb:"move",BezierTargetThumb:"move",OrthoThumb:"move",SegmentEnd:"move",Pan:"grab",Hyperlink:"pointer",PortDrag:"pointer",LabelSelect:"pointer",LabelDrag:"move",LabelRotate:"crosshair",LabelResizeWest:"w-resize",LabelResizeEast:"e-resize",LabelResizeSouth:"s-resize",LabelResizeNorth:"n-resize",LabelResizeNorthEast:"ne-resize",LabelResizeNorthWest:"nw-resize",LabelResizeSouthEast:"se-resize",LabelResizeSouthWest:"sw-resize"},ds=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Od=function(n,t,e,i){return new(e||(e=Promise))(function(r,s){function o(h){try{l(i.next(h))}catch(c){s(c)}}function a(h){try{l(i.throw(h))}catch(c){s(c)}}function l(h){h.done?r(h.value):new e(function(c){c(h.value)}).then(o,a)}l((i=i.apply(n,t||[])).next())})},kd=function(n,t){var i,r,s,o,e={label:0,sent:function(){if(1&s[0])throw s[1];return s[1]},trys:[],ops:[]};return o={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function a(h){return function(c){return function l(h){if(i)throw new TypeError("Generator is already executing.");for(;e;)try{if(i=1,r&&(s=2&h[0]?r.return:h[0]?r.throw||((s=r.return)&&s.call(r),0):r.next)&&!(s=s.call(r,h[1])).done)return s;switch(r=0,s&&(h=[2&h[0],s.value]),h[0]){case 0:case 1:s=h;break;case 4:return e.label++,{value:h[1],done:!1};case 5:e.label++,r=h[1],h=[0];continue;case 7:h=e.ops.pop(),e.trys.pop();continue;default:if(!(s=(s=e.trys).length>0&&s[s.length-1])&&(6===h[0]||2===h[0])){e=0;continue}if(3===h[0]&&(!s||h[1]>s[0]&&h[1]-1&&(r=i.fixedUserHandles[parseInt(o.toString(),10)]);this.commandHandler.triggerEvent(Ce.fixedUserHandleClick,{fixedUserHandle:r,element:e.source}),n.prototype.mouseUp.call(this,e)},t}(us),Pd=function(n){function t(e,i){var r=n.call(this,e,!0)||this;return r.isConnected=!1,r.endPoint=i,r}return ds(t,n),t.prototype.mouseDown=function(e){return Od(this,void 0,void 0,function(){var r,s,o,a,l;return kd(this,function(h){if(this.inAction=!0,this.undoElement=void 0,this instanceof pa||(this.undoElement=$(e.source)),n.prototype.mouseDown.call(this,e),e.source&&e.source.connectors&&(this.oldConnector=$(r=e.source.connectors[0])),"BezierSourceThumb"===this.endPoint||"BezierTargetThumb"===this.endPoint)for(s=0;s0))},t.prototype.endAction=function(){n.prototype.endAction.call(this),this.prevPosition=null,this.endPoint=null},t}(us),ua=function(n){function t(e,i){var r=n.call(this,e,!0)||this;return r.currentTarget=null,r.isStartAction=!1,r.canCancel=!1,r.canTrigger=!1,r.objectType=i,r}return ds(t,n),t.prototype.mouseDown=function(e){if(e.source instanceof te||e.source instanceof de){var i=this.commandHandler.getSelectedObject();this.commandHandler.selectObjects([e.source],e.info&&e.info.ctrlKey,i);var r={nodes:[],connectors:[]};e.source instanceof te?r.nodes.push($(e.source)):r.connectors.push($(e.source)),this.undoElement=$(r)}else this.undoElement=$(e.source);this.undoParentElement=this.commandHandler.getSubProcess(e.source),"Port"===this.objectType&&(this.portId=e.sourceWrapper.id),this.commandHandler.insertBlazorConnector(e.source),n.prototype.mouseDown.call(this,e),this.initialOffset={x:0,y:0}},t.prototype.mouseUp=function(e,i){return Od(this,void 0,void 0,function(){var s,o,a,l,h,c,d,u,f,g,v,y,S,b,M;return kd(this,function(w){if(this.checkPropertyValue(),a=!1,h={nodes:[],connectors:[]},"Port"!==this.objectType){if(e.source instanceof te||e.source instanceof de?(e.source instanceof te?h.nodes.push($(e.source)):h.connectors.push($(e.source)),(o=$(h)).offsetX=(c=e.source.wrapper).offsetX,o.offsetY=c.offsetY):o=$(e.source),("helper"===(l=this.commandHandler.renderContainerHelper(e.source)||e.source||this.commandHandler.renderContainerHelper(e.source)).id||"helper"!==l.id)&&((l instanceof si&&(Math.round(l.width)===Math.round(this.undoElement.width)&&Math.round(l.height)===Math.round(this.undoElement.height)||l.selectedObjects&&1===l.selectedObjects.length)||!(l instanceof si))&&(l.offsetX!==this.undoElement.offsetX||l.offsetY!==this.undoElement.offsetY||l.sourcePoint!==this.undoElement.sourcePoint||l.targetPoint!==this.undoElement.targetPoint)||this.isSelectionHasConnector(l))&&(e.source&&(s={offsetX:e.source.wrapper.offsetX,offsetY:e.source.wrapper.offsetY}),g={source:e.source,state:"Completed",oldValue:this.intialValue,newValue:s,target:this.currentTarget,targetPosition:this.currentPosition,allowDrop:(g={source:e.source,state:"Completed",oldValue:this.intialValue,newValue:s,target:this.currentTarget,targetPosition:this.currentPosition,allowDrop:!0,cancel:!1}).allowDrop,cancel:g.cancel},d=!0,"helper"===l.id?this.canTrigger?(this.commandHandler.triggerEvent(Ce.positionChange,g),this.connectorEndPointChangeEvent(g),d=!0):d=!1:(this.commandHandler.triggerEvent(Ce.positionChange,g),this.connectorEndPointChangeEvent(g)),!i&&d&&(this.commandHandler.startGroupAction(),a=!0,M={type:"PositionChanged",redoObject:$(o),undoObject:$(this.undoElement),category:"Internal"},o.nodes[0]&&o.nodes[0].processId&&(u={type:"SizeChanged",category:"Internal",undoObject:this.undoParentElement,redoObject:this.commandHandler.getSubProcess(e.source)},this.commandHandler.addHistoryEntry(u)),this.commandHandler.addHistoryEntry(M))),this.commandHandler.snapPoint(this.prevPosition,this.currentPosition,0,0),this.commandHandler.removeSnap(),this.commandHandler.removeHighlighter(),e.source&&this.currentTarget&&HI(this.currentTarget)&&this.commandHandler.isDroppable(e.source,this.currentTarget)){if(f=!0,this.commandHandler.drop(this.currentElement,this.currentTarget,this.currentPosition),this.currentTarget&&this.currentTarget instanceof de&&!0===this.commandHandler.diagram.enableConnectorSplit)if(this.currentElement&&this.currentElement instanceof te){if(void 0!==this.currentElement.children)for(b=0;b0)for(var s=0;s0)for(var a=0;a0)for(a=0;a0&&e.connectors.length>0)||e.width===this.undoElement.width&&e.height===this.undoElement.height)},t.prototype.mouseMove=function(e){n.prototype.mouseMove.call(this,e);var r,s,i=!1;(r=this.commandHandler.renderContainerHelper(e.source)||e.source)instanceof te||r instanceof de?r instanceof te?r.offsetX===this.undoElement.nodes[0].offsetX&&r.offsetY===this.undoElement.nodes[0].offsetY&&(i=!0):z.equals(r.sourcePoint,this.undoElement.connectors[0].sourcePoint)&&z.equals(r.targetPoint,this.undoElement.connectors[0].targetPoint)&&(i=!0):r.wrapper.offsetX===this.undoElement.wrapper.offsetX&&r.wrapper.offsetY===this.undoElement.wrapper.offsetY&&(i=!0),r&&(s={offsetX:r.wrapper.offsetX,offsetY:r.wrapper.offsetY});var o={source:r,state:"Start",oldValue:s,newValue:s,target:e.target,targetPosition:e.position,allowDrop:!0,cancel:!1};if(o={source:r,state:"Start",oldValue:s,newValue:s,target:e.target,targetPosition:e.position,allowDrop:o.allowDrop,cancel:o.cancel},this.isStartAction||(this.intialValue={offsetX:r.wrapper.offsetX,offsetY:r.wrapper.offsetY}),i&&!ce()&&(this.commandHandler.triggerEvent(Ce.positionChange,o),this.connectorEndPointChangeEvent(o),this.isStartAction=!0),this.currentPosition=e.position,"Port"!==this.objectType){var h=this.initialOffset.x+(this.currentPosition.x-this.prevPosition.x),c=this.initialOffset.y+(this.currentPosition.y-this.prevPosition.y);this.commandHandler.dragOverElement(e,this.currentPosition),this.commandHandler.disConnect(e.source),this.commandHandler.removeSnap();var d,u=void 0,p=this.commandHandler.snapPoint(this.prevPosition,this.currentPosition,h,c);this.initialOffset.x=h-p.x,this.initialOffset.y=c-p.y,r&&(d={offsetX:r.wrapper.offsetX,offsetY:r.wrapper.offsetY},u={offsetX:r.wrapper.offsetX+p.x,offsetY:r.wrapper.offsetY+p.y}),this.currentTarget&&e.target!==this.currentTarget&&this.commandHandler.removeChildFromBPmn(e.source,e.target,this.currentTarget),this.currentTarget=e.target;var f={source:r,state:"Progress",oldValue:d,newValue:u,target:e.target,targetPosition:e.position,allowDrop:!0,cancel:!1};if(this.commandHandler.triggerEvent(Ce.positionChange,f),this.canTrigger=!0,this.connectorEndPointChangeEvent(f,p),!f.cancel&&!this.canCancel){this.blocked=!this.commandHandler.dragSelectedObjects(p.x,p.y);var g=!this.commandHandler.mouseOver(this.currentElement,this.currentTarget,this.currentPosition);this.blocked=this.blocked||g}if(this.commandHandler.removeStackHighlighter(),this.commandHandler.renderStackHighlighter(e),this.currentTarget&&e.source!==this.currentTarget&&this.commandHandler.isDroppable(e.source,this.currentTarget)&&"helper"!==e.source.id){var v=e.source instanceof si?e.source.nodes[0]:e.source;!this.commandHandler.isParentAsContainer(v,!0)&&"SwimLane"!==v.shape.type&&!v.shape.isPhase&&(this.currentTarget.isLane?this.commandHandler.renderStackHighlighter(e,this.currentTarget):this.commandHandler.drawHighlighter(this.currentTarget))}else this.commandHandler.removeHighlighter();if(this.commandHandler.canEnableDefaultTooltip()){var y=this.getTooltipContent(e.source);this.commandHandler.showTooltip(e.source,e.position,ko(function(){return y}),"MoveTool",this.isTooltipVisible),this.isTooltipVisible=!1}}else{var b=Hi(),M=e.source;qi(b,-M.rotateAngle||-M.wrapper.rotateAngle,M.offsetX||M.wrapper.offsetX,M.offsetY||M.wrapper.offsetY);var w=Je(b,{x:this.prevPosition.x,y:this.prevPosition.y}),C=Je(b,{x:e.position.x,y:e.position.y});this.commandHandler.portDrag(e.source,e.sourceWrapper,C.x-w.x,C.y-w.y)}return this.prevPosition=this.currentPosition,!this.blocked},t.prototype.getTooltipContent=function(e){return"X:"+Math.round(e.wrapper.bounds.x)+" Y:"+Math.round(e.wrapper.bounds.y)},t.prototype.mouseLeave=function(e){this.mouseUp(e)},t.prototype.endAction=function(){n.prototype.endAction.call(this),this.currentTarget=null,this.prevPosition=null},t}(us),Xx=function(n){function t(e){var i=n.call(this,e,!0)||this;return i.rotateStart=!1,i}return ds(t,n),t.prototype.mouseDown=function(e){if(this.undoElement=$(e.source),this.undoElement.nodes[0]&&this.undoElement.nodes[0].children)for(var r=this.commandHandler.getAllDescendants(this.undoElement.nodes[0],[]),s=0;s=2){var s=e.startTouches[0],o=e.startTouches[1],a=e.moveTouches[0],l=e.moveTouches[1],h=this.getDistance(a,l)/this.getDistance(s,o);this.commandHandler.zoom(h,0,0,e.position),this.updateTouch(s,a),this.updateTouch(o,l)}}else this.commandHandler.scroll(this.currentPosition.x-this.prevPosition.x,this.currentPosition.y-this.prevPosition.y,this.currentPosition);return this.commandHandler.dataBinding(),!this.blocked},t.prototype.mouseUp=function(e){this.commandHandler.setBlazorDiagramProps(!1),this.checkPropertyValue(),this.commandHandler.updatePanState(!1),n.prototype.mouseUp.call(this,e),this.inAction=!1},t.prototype.endAction=function(){n.prototype.endAction.call(this)},t.prototype.getDistance=function(e,i){var r=i.pageX-e.pageX,s=i.pageY-e.pageY;return Math.sqrt(r*r+s*s)},t.prototype.updateTouch=function(e,i){e.pageX=i.pageX,e.pageY=i.pageY},t}(us),Une=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseUp=function(e){this.checkPropertyValue(),this.commandHandler.initExpand(e),n.prototype.mouseUp.call(this,e)},t}(us),eF=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseUp=function(e){this.checkPropertyValue();var i="_blank",r="",s=window.innerHeight,o=window.innerWidth,a=window.screenTop,l=window.screenLeft;"CurrentTab"===e.sourceWrapper.hyperlink.hyperlinkOpenState?i="_self":"NewWindow"===e.sourceWrapper.hyperlink.hyperlinkOpenState&&(r="height="+s+",width="+o+",top="+a+",left="+l),window.open(e.sourceWrapper.hyperlink.link,i,r).focus(),n.prototype.mouseUp.call(this,e)},t}(us),Ph=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseDown=function(e){if(n.prototype.mouseDown.call(this,e),this.inAction=!0,this.drawingObject){var r=void 0,s=this.drawingObject.shape;this.drawingObject.shape.points.push(r={x:(r=s.points[s.points.length-1]).x,y:r.y})}else this.startPoint={x:this.startPosition.x,y:this.startPosition.y},this.drawingObject=this.commandHandler.drawObject({offsetX:this.currentPosition.x,offsetY:this.currentPosition.y,width:5,height:5,style:{strokeColor:"black",strokeWidth:1},shape:{type:"Basic",shape:"Polygon",points:[{x:this.startPoint.x,y:this.startPoint.y},{x:this.currentPosition.x,y:this.currentPosition.y}]}})},t.prototype.mouseMove=function(e){if(n.prototype.mouseMove.call(this,e),this.inAction){var i=this.drawingObject.shape;if(i.points[i.points.length-1].x=this.currentPosition.x,i.points[i.points.length-1].y=this.currentPosition.y,this.drawingObject.wrapper.children[0].data=Sx(this.drawingObject.shape.points),this.inAction&&!1===z.equals(this.currentPosition,this.prevPosition)){var r=Ne.toBounds(this.drawingObject.shape.points);this.commandHandler.updateNodeDimension(this.drawingObject,r)}}return!0},t.prototype.mouseUp=function(e,i){this.checkPropertyValue(),n.prototype.mouseMove.call(this,e),this.inAction&&(this.inAction=!1,this.commandHandler.addObjectToDiagram(this.drawingObject)),this.endAction()},t.prototype.mouseWheel=function(e){n.prototype.mouseWheel.call(this,e),this.mouseMove(e)},t.prototype.endAction=function(){this.inAction=!1,this.drawingObject=null},t}(us),zh=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseMove=function(e){if(n.prototype.mouseMove.call(this,e),this.inAction){var i=this.drawingObject;i.targetPoint=this.currentPosition,this.commandHandler.updateConnectorPoints(i)}return!0},t.prototype.mouseDown=function(e){if(n.prototype.mouseDown.call(this,e),this.inAction=!0,this.drawingObject){var r=this.drawingObject,s=void 0;(s=new Pl(r,"segments",{type:"Straight"},!0)).point=this.currentPosition,r.segments[r.segments.length-1]=s}else this.drawingObject=this.commandHandler.drawObject({id:"Connector",type:"Straight",sourcePoint:this.currentPosition,targetPoint:this.currentPosition})},t.prototype.mouseWheel=function(e){n.prototype.mouseWheel.call(this,e),this.mouseMove(e)},t.prototype.mouseUp=function(e){if(this.checkPropertyValue(),n.prototype.mouseMove.call(this,e),this.inAction&&this.drawingObject){var i=this.drawingObject;i.segments[i.segments.length-1].point={x:0,y:0},this.commandHandler.addObjectToDiagram(this.drawingObject)}this.endAction()},t.prototype.endAction=function(){this.drawingObject=null,this.inAction=!1},t}(us),jne=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseDown=function(e){this.inAction=!0,this.undoElement=$(e.source),this.annotationId=e.sourceWrapper.id,n.prototype.mouseDown.call(this,e)},t.prototype.mouseMove=function(e){n.prototype.mouseMove.call(this,e);var i=this.currentPosition.x-this.prevPosition.x,r=this.currentPosition.y-this.prevPosition.y,s=e.source;if(s instanceof te){var o=Hi();qi(o,-s.rotateAngle,0,0);var a=Je(o,{x:i,y:r});i=a.x,r=a.y}return this.inAction&&(this.commandHandler.labelDrag(e.source,e.sourceWrapper,i,r),this.commandHandler.updateSelector()),this.prevPosition=this.currentPosition,!this.blocked},t.prototype.mouseUp=function(e){this.checkPropertyValue();var i=e.source;this.inAction=!1;var r={type:"AnnotationPropertyChanged",objectId:this.annotationId,undoObject:$(this.undoElement),category:"Internal",redoObject:$(i)};this.commandHandler.addHistoryEntry(r),n.prototype.mouseUp.call(this,e)},t.prototype.mouseLeave=function(e){this.mouseUp(e)},t}(us),Vne=function(n){function t(e,i){var r=n.call(this,e,!0)||this;return r.corner=i,r}return ds(t,n),t.prototype.mouseDown=function(e){this.inAction=!0;var i=e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0];this.annotationId=e.source.wrapper.children[0].id,this.undoElement=$(i);var r=e.source.wrapper.children[0];this.initialBounds={x:r.offsetX,y:r.offsetY,width:r.actualSize.width,height:r.actualSize.height},n.prototype.mouseDown.call(this,e)},t.prototype.mouseMove=function(e){return n.prototype.mouseMove.call(this,e),this.inAction&&this.resizeObject(e),!this.blocked},t.prototype.mouseUp=function(e){this.checkPropertyValue();var i=e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0];this.inAction=!1;var r={type:"AnnotationPropertyChanged",objectId:this.annotationId,redoObject:$(i),undoObject:$(this.undoElement),category:"Internal"};this.commandHandler.addHistoryEntry(r),n.prototype.mouseUp.call(this,e)},t.prototype.mouseLeave=function(e){this.mouseUp(e)},t.prototype.resizeObject=function(e){var i,s,o,r=e.source.wrapper.children[0],a={x:r.offsetX,y:r.offsetY},l=r.rotateAngle;l=((l+=(i=e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0])instanceof te?i.rotateAngle:0)+360)%360;var h=Hi();qi(h,l,a.x,a.y);var c=this.corner.slice(5),d=this.updateSize(r,this.startPosition,this.currentPosition,c,this.initialBounds,l),u=r.offsetX-r.actualSize.width*r.pivot.x,p=r.offsetY-r.actualSize.height*r.pivot.y,f=this.getPivot(c),g=Je(h,f={x:u+r.actualSize.width*f.x,y:p+r.actualSize.height*f.y});d.x=g.x,d.y=g.y,this.commandHandler.labelResize(i,e.source.annotation,s=(s=d.width)<0?1:s,o=(o=d.height)<0?1:o,d,e.source),this.commandHandler.updateSelector()},t}(us),Wne=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseDown=function(e){this.inAction=!0,this.annotationId=e.source.wrapper.children[0].id,this.undoElement=$(e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0]),n.prototype.mouseDown.call(this,e)},t.prototype.mouseMove=function(e){return n.prototype.mouseMove.call(this,e),e.source&&this.inAction&&(this.commandHandler.labelRotate(e.source.nodes[0]?e.source.nodes[0]:e.source.connectors[0],e.source.annotation,this.currentPosition,e.source),this.commandHandler.updateSelector()),this.prevPosition=this.currentPosition,!this.blocked},t.prototype.mouseUp=function(e){this.checkPropertyValue(),this.inAction=!1;var r={type:"AnnotationPropertyChanged",objectId:this.annotationId,redoObject:$(e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0]),undoObject:$(this.undoElement),category:"Internal"};this.commandHandler.addHistoryEntry(r),n.prototype.mouseUp.call(this,e)},t.prototype.mouseLeave=function(e){this.mouseUp(e)},t}(us),Yne=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseMove=function(e){if(n.prototype.mouseMove.call(this,e),this.inAction){var i=this.drawingObject.shape;if(i.points.push(this.currentPosition),this.drawingObject.wrapper.children[0].data=Ix(this.drawingObject.shape.points),i.data=Ix(i.points),this.inAction&&!1===z.equals(this.currentPosition,this.prevPosition)){var s=Ne.toBounds(this.drawingObject.shape.points);this.commandHandler.updateNodeDimension(this.drawingObject,s)}}return!0},t.prototype.mouseDown=function(e){n.prototype.mouseDown.call(this,e),this.inAction=!0,this.startPoint={x:this.startPosition.x,y:this.startPosition.y},this.drawingObject=this.commandHandler.drawObject({offsetX:this.currentPosition.x,offsetY:this.currentPosition.y,width:5,height:5,style:{strokeColor:"black",strokeWidth:1,fill:"transparent"},shape:{type:"Path",points:[{x:this.startPoint.x,y:this.startPoint.y},{x:this.currentPosition.x,y:this.currentPosition.y}]}})},t.prototype.mouseUp=function(e){if(this.checkPropertyValue(),this.inAction){this.inAction=!1;var s=this.drawingObject.shape,o=s.points;this.commandHandler.addObjectToDiagram(this.drawingObject),this.commandHandler.diagram.remove(this.commandHandler.diagram.nameTable[""+this.drawingObject.id]),o=this.pointReduction(o,10);var h={id:"newConnector"+Qe(),type:"Bezier",sourcePoint:{x:o[0].x,y:o[0].y},targetPoint:{x:o[o.length-1].x,y:o[o.length-1].y},segments:[],bezierSettings:{allowSegmentsReset:!1}};this.drawingObject=this.commandHandler.drawObject(h),this.drawingObject=this.bezierCurveSmoothness(o,.5,this.drawingObject,s),this.commandHandler.updateConnectorPoints(this.drawingObject),this.commandHandler.addObjectToDiagram(this.drawingObject),n.prototype.mouseUp.call(this,e)}},t.prototype.pointReduction=function(e,i){if(null===e||e.length<3)return e;var s=e.length-1,o=[];for(o.push(0),o.push(s);e[parseInt((0).toString(),10)]===e[parseInt(s.toString(),10)];)s--;this.reduction(e,0,s,i,o);var a=[];return o.sort(function(l,h){return l-h}),o.forEach(function(l){a.push(e[parseInt(l.toString(),10)])}),a},t.prototype.reduction=function(e,i,r,s,o){for(var a=0,l=0,h=i;ha&&(a=c,l=h)}a>s&&0!==l&&(o.push(l),this.reduction(e,i,l,s,o),this.reduction(e,l,r,s,o))},t.prototype.perpendicularDistance=function(e,i,r){return Math.abs(.5*(e.x*i.y-i.x*e.y+(i.x*r.y-r.x*i.y)+(r.x*e.y-e.x*r.y)))/Math.sqrt(Math.pow(e.x-i.x,2)+Math.pow(e.y-i.y,2))*2},t.prototype.bezierCurveSmoothness=function(e,i,r,s){if(e.length<3)return r;for(var o=0;o=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Qne=function(n){if(n)switch(n.type){case"Bpmn":return $ne;case"UmlActivity":return qne;case"UmlClassifier":return Kne;default:return tm}return tm},Gne=function(n){if(n)switch(n.type){case"Straight":default:return Pl;case"Bezier":return ps;case"Orthogonal":return bi}},tF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I(10)],t.prototype,"width",void 0),Pe([I(10)],t.prototype,"height",void 0),Pe([I("Arrow")],t.prototype,"shape",void 0),Pe([re({fill:"black",strokeColor:"black",strokeWidth:1},Ll)],t.prototype,"style",void 0),Pe([re({x:0,y:.5},z)],t.prototype,"pivot",void 0),Pe([I("")],t.prototype,"pathData",void 0),t}(Ee),$I=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I(0)],t.prototype,"angle",void 0),Pe([I(0)],t.prototype,"distance",void 0),t}(Ee),Xne=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I(Cx.All)],t.prototype,"controlPointsVisibility",void 0),Pe([I("FreeForm")],t.prototype,"segmentEditOrientation",void 0),Pe([I(MI.Default)],t.prototype,"smoothness",void 0),Pe([I(!0)],t.prototype,"allowSegmentsReset",void 0),t}(Ee),tm=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I("None")],t.prototype,"type",void 0),t}(Ee),qne=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I("Object")],t.prototype,"flow",void 0),Pe([I(30)],t.prototype,"exceptionFlowHeight",void 0),t}(tm),$ne=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I("Sequence")],t.prototype,"flow",void 0),Pe([I("Normal")],t.prototype,"sequence",void 0),Pe([I("Default")],t.prototype,"message",void 0),Pe([I("Default")],t.prototype,"association",void 0),t}(tm),iF=function(n){function t(e,i,r,s){var o=n.call(this,e,i,r,s)||this;return o.points=[],o}return Qs(t,n),Pe([I("Straight")],t.prototype,"type",void 0),Pe([I(!0)],t.prototype,"allowDrag",void 0),t}(Ee),Pl=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),t.prototype.getClassName=function(){return"StraightSegment"},Pe([re({x:0,y:0},z)],t.prototype,"point",void 0),t}(iF),ps=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),t.prototype.getClassName=function(){return"BezierSegment"},t.prototype.getPoints=function(e,i){var r=[];if(r.length>0||null!=i){var o=this.bezireToPoly(r.length>0?r[r.length-1]:i,e);r.push.apply(r,o)}return r},t.prototype.bezireToPoly=function(e,i){var r=[];return i&&this.flattenCubicBezier(r,e,i.bezierPoint1,i.bezierPoint2,{x:i.points[1].x,y:i.points[1].y},10),r},t.prototype.flattenCubicBezier=function(e,i,r,s,o,a){var h,l=(z.findLength(i,r)+z.findLength(r,s)+z.findLength(s,o))/a;for(h=0;h<=l;h++){var c=h/l;e.push({x:(1-c)*(1-c)*(1-c)*i.x+3*c*(1-c)*(1-c)*r.x+3*c*c*(1-c)*s.x+c*c*c*o.x,y:(1-c)*(1-c)*(1-c)*i.y+3*c*(1-c)*(1-c)*r.y+3*c*c*(1-c)*s.y+c*c*c*o.y})}},Pe([I("Horizontal")],t.prototype,"orientation",void 0),Pe([re({x:0,y:0},z)],t.prototype,"point1",void 0),Pe([re({x:0,y:0},z)],t.prototype,"point2",void 0),Pe([re({angle:0,distance:0},$I)],t.prototype,"vector1",void 0),Pe([re({angle:0,distance:0},$I)],t.prototype,"vector2",void 0),t}(Pl),bi=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),t.prototype.getClassName=function(){return"OrthogonalSegment"},Pe([I(null)],t.prototype,"length",void 0),Pe([I(null)],t.prototype,"direction",void 0),t}(iF);function rF(n,t,e){var s=e?45:180/(2+2/(n.height/n.width)),o=s,a=180-s,l=a+2*s,h=360-s,c=Gt(t,n.center);return c>o&&ca&&cl&&cMath.abs(t.y-n.y)?n.x=c)return s=z.findAngle(n[parseInt(d.toString(),10)],n[d+1]),{point:r=z.transform(n[parseInt(d.toString(),10)],s,c-(a||0)),index:l=d};a=o[parseInt(d.toString(),10)]}return{point:r,index:l}}(n,t),r=z.findAngle(n[i.index],n[i.index+1]),s=function xse(n){var e=0;switch(n.alignment){case"Center":case"After":e=0;break;case"Before":e=-0}return e}(t),o=z.transform(i.point,r+45,s);return i.point=o,i.angle=r,i}(i,e),h=l.point;s.id=this.id+"_"+e.id;var c=e.style;s.style={fill:c.fill,strokeColor:c.strokeColor,gradient:null,opacity:c.opacity,strokeDashArray:c.strokeDashArray,strokeWidth:c.strokeWidth},0===r.width&&(r.width=this.style.strokeWidth),0===r.height&&(r.height=this.style.strokeWidth);var d_y=(h.y-r.y)/r.height;a.x=r.width*((h.x-r.x)/r.width),a.y=r.height*d_y;var g,v,u=SF(e,l.angle,i),p=u.hAlign,f=u.vAlign;return"left"===p?(g="Left",a.x+=e.displacement.x):"right"===p?(g="Right",a.x-=e.displacement.x):"center"===p&&(g="Center"),"top"===f?(v="Top",a.y+=e.displacement.y):"bottom"===f?(v="Bottom",a.y-=e.displacement.y):"center"===f&&(v="Center"),s.horizontalAlignment=g,s.verticalAlignment=v,(s=nm(s,o&&"Label"!==o.flipMode&&"None"!==o.flipMode?this.flip:"None",e)).float=!0,s.connectionDirection=e.connectionDirection,s.setOffsetWithRespectToBounds(a.x,a.y,"Absolute"),s.relativeMode="Point",s.visible=!(!ga(e,hi.Visible)||ga(e,hi.Hover)||ga(e,hi.Connect)),s.elementActions=s.elementActions|Xr.ElementIsPort,s},t.prototype.getConnectorRelation=function(){var e=this.shape;"Association"===e.relationship?(this.segments[0].type="Straight",this.sourceDecorator.shape="None",this.targetDecorator.shape="Arrow"):"Inheritance"===e.relationship?(this.segments[0].type="Orthogonal",this.sourceDecorator.shape="None",this.targetDecorator.shape="Arrow"):"Composition"===e.relationship||"Aggregation"===e.relationship?(this.segments[0].type="Orthogonal",this.sourceDecorator.shape="Diamond",this.targetDecorator.shape="None"):"Dependency"===e.relationship?(this.segments[0].type="Orthogonal",this.sourceDecorator.shape="None",this.targetDecorator.shape="OpenArrow"):"Realization"===e.relationship&&(this.segments[0].type="Orthogonal",this.sourceDecorator.shape="None",this.targetDecorator.shape="Arrow"),"BiDirectional"===e.associationType&&(this.sourceDecorator.shape="None",this.targetDecorator.shape="None");var i,o,r="",s="";e.multiplicity.source&&(e.multiplicity.source.lowerBounds=e.multiplicity.source.lowerBounds,e.multiplicity.source.upperBounds=e.multiplicity.source.upperBounds),e.multiplicity.target&&(e.multiplicity.target.lowerBounds=e.multiplicity.target.lowerBounds,e.multiplicity.target.upperBounds=e.multiplicity.target.upperBounds);var a=e.multiplicity.source,l=e.multiplicity.target;o=a.upperBounds?a.lowerBounds+"..."+a.upperBounds:a.lowerBounds,i=l.upperBounds?l.lowerBounds+"..."+l.upperBounds:l.lowerBounds,"ManyToOne"===e.multiplicity.type&&(e.multiplicity.target.optional=!1,r=o||"*",s="1"),"OneToMany"===e.multiplicity.type&&(e.multiplicity.source.optional=!1,s=i||"*",r="1"),"ManyToMany"===e.multiplicity.type&&(r=o||"*",s=i||"*"),"OneToOne"===e.multiplicity.type&&(e.multiplicity.target.optional=!1,e.multiplicity.source.optional=!1,r="1",s="1"),this.annotations=[{id:this.id+"sourcelabel",content:r,offset:0,alignment:"Before",margin:{right:5,bottom:5}},{id:this.id+"targetlabel",content:s,offset:1,alignment:"Before",margin:{right:5,bottom:5}}]},t.prototype.getBpmnSequenceFlow=function(){var e=new Ke,i=new Ke;return"Normal"===this.shape.sequence&&"Bezier"!==this.type&&(this.targetDecorator.shape="Arrow"),"Default"===this.shape.sequence&&(e=this.getSegmentElement(this,e),i=DF(this.intermediatePoints,this),this.targetDecorator.shape="Arrow"),"Conditional"===this.shape.sequence&&(this.targetDecorator.shape="Arrow",this.sourceDecorator.shape="Diamond",i.id=this.id+this.shape.type),i},t.prototype.getUMLObjectFlow=function(){if(this.annotations)for(var e=0;e0&&(this.sourcePoint=o[0],this.targetPoint=o[o.length-1]),o},t.prototype.clipDecorator=function(e,i,r,s){var a,l,o={x:0,y:0},h=i.length,c=z.distancePoints(a=r?i[0]:i[h-1],l=r?i[1]:i[h-2]);c=0===c?1:c;var d=1,u=r?e.sourceWrapper:e.targetWrapper;u&&(d=u.style.strokeWidth,s&&s&ee.DecoratorPropertyChange&&(d=1));var p=d-1;return o.x=Math.round(a.x+p*(l.x-a.x)/c),o.y=Math.round(a.y+p*(l.y-a.y)/c),(r&&"None"!==e.sourceDecorator.shape||!r&&"None"!==e.targetDecorator.shape)&&(o=z.adjustPoint(o,l,!0,s&ee.DecoratorPropertyChange?0:d/2)),o},t.prototype.clipDecorators=function(e,i,r){return"None"!==e.sourceDecorator.shape&&(i[0]=this.clipDecorator(e,i,!0,r)),"None"!==e.targetDecorator.shape&&(i[i.length-1]=this.clipDecorator(e,i,!1,r)),i},t.prototype.updateSegmentElement=function(e,i,r,s){var o=new Ne,a=this.getSegmentPath(e,i,s);if("Bezier"===e.type){if(this.segments.length>0)for(var l=0;l0)if("Straight"===e.type&&e.segments.length<2)for(var o=0;o1)for(o=0;o0&&"Bezier"!==this.type)for(var p=0;p0&&(a=p0&&(f<2*this.cornerRadius?(l=z.adjustPoint(h[parseInt(p.toString(),10)],h[p+1],!0,f/2),p0&&(s=this.bridgePath(e,s,p),"Orthogonal"===e.type&&(s=this.bridgePath(e,s,p+1))),s+=" L"+a.x+" "+a.y))}else if("Bezier"===this.type){var g=void 0,v=void 0;if(this.parentObj.element){var y=this.parentObj.element.ej2_instances[0].eventHandler.action;g=this.parentObj.element.ej2_instances[0].eventHandler.tool instanceof zd,v=y.includes("PortDraw")||y.includes("Drag")}for(var S=void 0,b=this.segments,M=0;M2&&(b[parseInt(M.toString(),10)].bezierPoint1={x:0,y:0},b[parseInt(M.toString(),10)].bezierPoint2={x:0,y:0}),!z.isEmptyPoint(b[parseInt(M.toString(),10)].point1)||b[parseInt(M.toString(),10)].vector1.angle||b[parseInt(M.toString(),10)].vector1.distance?b[parseInt(M.toString(),10)].vector1.angle||b[parseInt(M.toString(),10)].vector1.distance?b[parseInt(M.toString(),10)].bezierPoint1=z.transform(h[parseInt(M.toString(),10)],b[parseInt(M.toString(),10)].vector1.angle,b[parseInt(M.toString(),10)].vector1.distance):b[parseInt(M.toString(),10)].bezierPoint1={x:b[parseInt(M.toString(),10)].point1.x||b[parseInt(M.toString(),10)].bezierPoint1.x,y:b[parseInt(M.toString(),10)].point1.y||b[parseInt(M.toString(),10)].bezierPoint1.y}:((e.sourceID||this.sourcePortID)&&this.sourceWrapper&&!v&&!g&&(S=rF(this.sourceWrapper.bounds,h[parseInt(M.toString(),10)],!0)),b[parseInt(M.toString(),10)].bezierPoint1=JI(h[parseInt(M.toString(),10)],h[M+1],S)),!z.isEmptyPoint(b[parseInt(M.toString(),10)].point2)||b[parseInt(M.toString(),10)].vector2.angle||b[parseInt(M.toString(),10)].vector2.distance?b[parseInt(M.toString(),10)].vector2.angle||b[parseInt(M.toString(),10)].vector2.distance?b[parseInt(M.toString(),10)].bezierPoint2=z.transform(h[M+1],b[parseInt(M.toString(),10)].vector2.angle,b[parseInt(M.toString(),10)].vector2.distance):b[parseInt(M.toString(),10)].bezierPoint2={x:b[parseInt(M.toString(),10)].point2.x||b[parseInt(M.toString(),10)].bezierPoint2.x,y:b[parseInt(M.toString(),10)].point2.y||b[parseInt(M.toString(),10)].bezierPoint2.y}:((e.targetID||this.targetPortID)&&this.targetWrapper&&!v&&!g&&(S=rF(this.targetWrapper.bounds,h[M+1],!0)),b[parseInt(M.toString(),10)].bezierPoint2=JI(h[M+1],h[parseInt(M.toString(),10)],S));h.splice(1,0,{x:b[0].bezierPoint1.x,y:b[0].bezierPoint1.y}),h.splice(h.length-1,0,{x:b[b.length-1].bezierPoint2.x,y:b[b.length-1].bezierPoint2.y}),h=this.clipDecorators(e,h,r);for(var w=0;w0&&(s=this.bridgePath(e,s,D),s+=" L"+o.x+" "+o.y);return s},t.prototype.updateShapeElement=function(e){var i;switch(e.shape.type){case"Bpmn":e.wrapper.children[3]instanceof Ke&&(i=e.wrapper.children[3]),"Message"===e.shape.flow&&this.updateShapePosition(e,i);break;case"UmlActivity":"Exception"===e.shape.flow&&this.getUMLExceptionFlow(e.wrapper.children[0])}},t.prototype.updateShapePosition=function(e,i){var o=xF(this.intermediatePoints,i,.5);i.offsetX=o.x,i.offsetY=o.y},t.prototype.scale=function(e,i,r,s,o){var a=0,l=0;if(this.wrapper&&this.wrapper.outerBounds){var h=function T3(n){var t=n.wrapper.children[0].bounds;return"None"!==n.sourceDecorator.shape&&t.uniteRect(n.wrapper.children[1].bounds),"None"!==n.targetDecorator.shape&&t.uniteRect(n.wrapper.children[2].bounds),t}(this),c=Math.abs((this.wrapper.bounds.width||this.style.strokeWidth||1)-2),d=Math.abs((this.wrapper.bounds.height||this.style.strokeWidth||1)-2);a=h.width-c,l=h.height-d,e=Math.abs((r-Math.max(a,l))/c),i=Math.abs((s-Math.max(a,l))/d),a=l=Math.min(a,l)}e=i=Math.min(e,i);var u=Hi();qi(u,-(o=o||this.wrapper).rotateAngle,o.offsetX,o.offsetY),Gp(u,e,i,o.offsetX,o.offsetY),qi(u,o.rotateAngle,o.offsetX,o.offsetY);var p=function Uie(n,t){for(var e=[],i=0,r=t;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},tse=function(n){function t(e,i){var r=n.call(this,e,i)||this;return r.offset=0,r.scale=1,r}return ese(t,n),t.prototype.preRender=function(){this.unWireEvents(),this.wireEvents()},t.prototype.render=function(){this.updateRulerGeometry(),this.renderComplete()},t.prototype.getModuleName=function(){return"Ruler"},t.prototype.destroy=function(){this.unWireEvents(),this.notify("destroy",{}),n.prototype.destroy.call(this),this.element.classList.remove("e-ruler")},t.prototype.getPersistData=function(){return this.addOnPersist(["loaded"])},t.prototype.onPropertyChanged=function(e,i){for(var r=0,s=Object.keys(e);r100;)r/=10,s/=10;for(;s<25;)r*=10,s*=10;return s>=25&&s%25!=0&&(s=25*Math.round(s/25)),s*e/r},t.prototype.createMarkerLine=function(e,i,r){var s;return i&&((s=e.getElementById(i.id+"_marker"))&&s.parentNode.removeChild(s),s=Bi("line",r)),s},t.prototype.drawRulerMarker=function(e,i,r){var s,o,h,d,u="Horizontal"===this.orientation,p=e.getElementsByTagName("svg");for(h=0;h0)for(var a=i.childNodes.length-1;a>=0;a--)i.childNodes[parseInt(a.toString(),10)].parentNode.removeChild(i.childNodes[parseInt(a.toString(),10)]);i.appendChild(s)}return s},t.prototype.wireEvents=function(){},t.prototype.unWireEvents=function(){},kc([I(5)],t.prototype,"interval",void 0),kc([I(100)],t.prototype,"segmentWidth",void 0),kc([I("Horizontal")],t.prototype,"orientation",void 0),kc([I("RightOrBottom")],t.prototype,"tickAlignment",void 0),kc([I("red")],t.prototype,"markerColor",void 0),kc([I(25)],t.prototype,"thickness",void 0),kc([I(null)],t.prototype,"arrangeTick",void 0),kc([I(400)],t.prototype,"length",void 0),t}(yi);function oF(n,t){var e=document.getElementById(n.element.id+(t?"_hRuler":"_vRuler")),i=qa(n),r=aF(n);e||(e=Tt("div",{id:n.element.id+(t?"_hRuler":"_vRuler"),style:"height:"+(t?i.height:r.height+100)+"px;overflow:hidden;width:"+(t?r.width+100:i.width)+"px;position:absolute;font-size:11px;"+(t?"margin-left:"+i.width+"px;":"margin-top:"+i.height+"px;")})),n.element.insertBefore(e,n.element.firstChild);var l=t?n.rulerSettings.horizontalRuler:n.rulerSettings.verticalRuler,h=new tse(l);h.orientation=t?"Horizontal":"Vertical",h.length=(t?r.width:r.height)+l.segmentWidth,h.appendTo("#"+n.element.id+(t?"_hRuler":"_vRuler")),t?n.hRuler=h:n.vRuler=h;var c=document.getElementById(n.element.id+(t?"_hRuler":"_vRuler"));t?n.hRuler.element=c:n.vRuler.element=c}function KI(n){var t=-n.scroller.horizontalOffset,e=-n.scroller.verticalOffset;n&&n.rulerSettings.showRulers?(n.hRuler.length=0,n.vRuler.length=0,void 0!==t&&n.hRuler.element&&lF(n,n.hRuler,t,!0),void 0!==e&&n.vRuler.element&&lF(n,n.vRuler,e,!1)):qx(n)}function qx(n){an(n.element.id+"_hRuler"),an(n.element.id+"_vRuler"),an(n.element.id+"_overlapRuler")}function qa(n){var t=0,e=0;return n.rulerSettings.showRulers&&(t=n.rulerSettings.horizontalRuler.thickness,e=n.rulerSettings.verticalRuler.thickness),new me(e,t)}function aF(n){var t=qa(n),e=n.scroller.viewPortHeight,i=n.scroller.viewPortWidth;return i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},hF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return ase(t,n),t.prototype.getClassName=function(){return"UserHandle"},Fn([I("")],t.prototype,"name",void 0),Fn([I("")],t.prototype,"pathData",void 0),Fn([I("")],t.prototype,"content",void 0),Fn([I("")],t.prototype,"source",void 0),Fn([I("#000000")],t.prototype,"backgroundColor",void 0),Fn([I("Top")],t.prototype,"side",void 0),Fn([I("")],t.prototype,"borderColor",void 0),Fn([I(.5)],t.prototype,"borderWidth",void 0),Fn([I(25)],t.prototype,"size",void 0),Fn([I("white")],t.prototype,"pathColor",void 0),Fn([I(10)],t.prototype,"displacement",void 0),Fn([I(!0)],t.prototype,"visible",void 0),Fn([I(0)],t.prototype,"offset",void 0),Fn([re({},$n)],t.prototype,"margin",void 0),Fn([I("Center")],t.prototype,"horizontalAlignment",void 0),Fn([I("Center")],t.prototype,"verticalAlignment",void 0),Fn([I(!1)],t.prototype,"disableNodes",void 0),Fn([I(!1)],t.prototype,"disableConnectors",void 0),Fn([re({},xd)],t.prototype,"tooltip",void 0),Fn([I("")],t.prototype,"template",void 0),t}(Ee);function cF(n){return lse[n.toString()]}var lse={Action:"M 90 82.895 C 90 86.819 86.776 90 82.8 90 H 7.2 C 3.224 90 0 86.819 0 82.895 V 7.105 C 0 3.181 3.224 0 7.2 0 h 75.6 C 86.776 0 90 3.181 90 7.105 V 82.895 Z",Decision:"M10,19.707L0.293,10L10,0.293L19.707,10L10,19.707z",MergeNode:"M10,19.707L0.293,10L10,0.293L19.707,10L10,19.707z",InitialNode:"M10,19.5c-5.238,0-9.5-4.262-9.5-9.5S4.762,0.5,10,0.5s9.5,4.262,9.5,9.5S15.238,19.5,10,19.5z",ForkNode:"m0.75,0.75l636.00002,0l0,290l-636.00002,0l0,-290z",JoinNode:"m0.75,0.75l636.00002,0l0,290l-636.00002,0l0,-290z",TimeEvent:"M50.001,0.00286865 L25.001,25.0029 L0.000976562,0.00286865 L50.001,0.00286865 z M0.000976562,50.0029 L25.001,25.0029 L50.001,50.0029 L0.000976562,50.0029 z",AcceptingEvent:"M17.8336 32.164 L29.64 24 L17.32 16 L48.1664 16 L48.5 32 Z",SendSignal:"M48.164 31.8336 L56 23.832 L47.836 16 L16.168 16 L16.1668 31.8336 Z",ReceiveSignal:"M48.1664 31.8336 L39.836 24 L47.836 16 L16.168 16 L16.168 31.836 Z",StructuredNode:"M0,0 L50,0 L50,50 L0,50 z",Note:"M20 12 L4 12 L4 22 L22 22 L22 14 L20 14 L20 12 L22 14 Z"},eb=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),$a=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},hse=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return eb(t,n),$a([I()],t.prototype,"key",void 0),$a([I()],t.prototype,"keyModifiers",void 0),t}(Ee),dF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return eb(t,n),t.prototype.getClassName=function(){return"Command"},$a([I("")],t.prototype,"name",void 0),$a([I()],t.prototype,"canExecute",void 0),$a([I()],t.prototype,"execute",void 0),$a([re({},hse)],t.prototype,"gesture",void 0),$a([I("")],t.prototype,"parameter",void 0),t}(Ee),cse=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return eb(t,n),$a([Bt([],dF)],t.prototype,"commands",void 0),t}(Ee),dse=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return eb(t,n),$a([I()],t.prototype,"show",void 0),$a([I()],t.prototype,"showCustomMenuOnly",void 0),$a([I()],t.prototype,"items",void 0),t}(Ee),Jp=function(){function n(){}return n.prototype.renderShadow=function(t,e,i,r){void 0===i&&(i=null);var l,o=z.transform({x:0,y:0},t.shadow.angle,t.shadow.distance);r&&(l=r.getElementById(e.id+"_shadow")),l||(l=document.createElementNS("http://www.w3.org/2000/svg",i?"path":"rect"),e.appendChild(l));var h={id:e.id+"_shadow",fill:t.shadow.color,stroke:t.shadow.color,opacity:t.shadow.opacity.toString(),transform:"rotate("+t.angle+","+(t.x+t.width*t.pivotX)+","+(t.y+t.height*t.pivotY)+")translate("+(t.x+o.x)+","+(t.y+o.y)+")"};if(r){var c=r.getElementById(e.id);c&&c.insertBefore(l,c.firstChild)}oi(l,h),i?i&&this.renderPath(l,t,i):oi(l,{width:t.width,height:t.height})},n.prototype.parseDashArray=function(t){return[]},n.prototype.drawRectangle=function(t,e,i,r,s,o,a,l,h){var c,d,u,p;e.shadow&&!r&&this.renderShadow(e,t,void 0,o),c=e.id===t.id?e.id+"_container":e.id,o&&(d=o.getElementById(c)),(!d||s)&&(d=document.createElementNS("http://www.w3.org/2000/svg","rect"),t.appendChild(d)),o&&!e.shadow&&(u=o.getElementById(e.id+"_groupElement_shadow"))&&u.parentNode.removeChild(u),p=l?{id:c,x:e.x.toString(),y:e.y.toString(),width:e.width.toString(),height:e.height.toString(),visibility:e.visible?"visible":"hidden",transform:"rotate("+e.angle+","+(e.x+e.width/2)+","+(e.y+e.height/2)+")",rx:e.cornerRadius||0,ry:e.cornerRadius||0,opacity:e.opacity}:{id:c,x:e.x.toString(),y:e.y.toString(),width:e.width.toString(),height:e.height.toString(),visibility:e.visible?"visible":"hidden",transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")",rx:e.cornerRadius||0,ry:e.cornerRadius||0,opacity:e.opacity},a&&(p.role="img",p["aria-label"]=a);var f=e.class||"";h||(f.includes("e-diagram-resize-handle")||f.includes("e-diagram-endpoint-handle")||f.includes("e-diagram-bezier-control-handle"))&&(f+=" e-disabled"),e.class&&(p.class=f),a||(p["pointer-events"]="none"),oi(d,p),this.setSvgStyle(d,e,i)},n.prototype.updateSelectionRegion=function(t,e){var i;i=t.parentNode.getElementById(e.id);var r={id:e.id,x:e.x.toString(),y:e.y.toString(),width:e.width.toString(),height:e.height.toString(),transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")",class:"e-diagram-selected-region"};i||(i=document.createElementNS("http://www.w3.org/2000/svg","rect"),t.appendChild(i)),this.setSvgStyle(i,e),oi(i,r)},n.prototype.createGElement=function(t,e){return Bi(t,e)},n.prototype.drawLine=function(t,e){var i=document.createElementNS("http://www.w3.org/2000/svg","line");this.setSvgStyle(i,e);var r=e.x+e.width*e.pivotX,s=e.y+e.height*e.pivotY,o={id:e.id,x1:e.startPoint.x+e.x,y1:e.startPoint.y+e.y,x2:e.endPoint.x+e.x,y2:e.endPoint.y+e.y,stroke:e.stroke,"stroke-width":e.strokeWidth.toString(),opacity:e.opacity.toString(),transform:"rotate("+e.angle+" "+r+" "+s+")",visibility:e.visible?"visible":"hidden"};e.class&&(o.class=e.class),oi(i,o),t.appendChild(i)},n.prototype.drawCircle=function(t,e,i,r){var s=document.createElementNS("http://www.w3.org/2000/svg","circle");this.setSvgStyle(s,e);var o=e.class||"";i||(o+=" e-disabled");var a={id:e.id,cx:e.centerX,cy:e.centerY,r:e.radius,visibility:e.visible?"visible":"hidden",class:o};r&&(a.role="img",a["aria-label"]=r),s.style.display=e.visible?"block":"none",oi(s,a),t.appendChild(s)},n.prototype.drawPath=function(t,e,i,r,s,o,a){var h,c,l=[];l=e3(l=Dd(e.data)),e.shadow&&this.renderShadow(e,t,l,s),s&&!e.shadow&&(h=s.getElementById(e.id+"_groupElement_shadow"))&&h.parentNode.removeChild(h),s&&(c=s.getElementById(e.id)),(!c||r)&&(c=document.createElementNS("http://www.w3.org/2000/svg","path"),t.appendChild(c)),this.renderPath(c,e,l);var d={};d=a?{id:e.id,transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")translate("+e.x+","+e.y+"),scale("+a+")",visibility:e.visible?"visible":"hidden",opacity:e.opacity}:{id:e.id,transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")translate("+e.x+","+e.y+")",visibility:e.visible?"visible":"hidden",opacity:e.opacity},o&&(d.role="img",d["aria-label"]=o),e.class&&(d.class=e.class),oi(c,d),this.setSvgStyle(c,e,i)},n.prototype.renderPath=function(t,e,i){var r,s,o,a,l,h,c,d,u=i,p="";for(l=0,h=0,d=0,c=u.length;de.width&&"Wrap"!==e.textOverflow&&"NoWrap"===e.textWrapping&&(h[0].text=qF(e.content,e)),v=0;vD&&(u.text=u.text.slice(0,u.text.length-3),u.text=u.text.concat("..."),l.data=u.text),this.alignText(y,p,u,l,f,g,v,e,h),C+=u.dy}}C&&e.isHorizontalLane&&(M=e.parentOffsetX+e.pivotX,w=e.parentOffsetY+e.pivotY,e.y=e.parentOffsetY-C*e.pivotY+.5),e.textDecoration&&"LineThrough"===e.textDecoration&&(e.textDecoration=fb(e.textDecoration));var R={id:e.id+"_text",fill:e.color,visibility:e.visible?"visible":"hidden","text-decoration":e.textDecoration,transform:"rotate("+e.angle+","+M+","+w+")translate("+e.x+","+e.y+")",opacity:e.opacity};r&&(R.role="img",R["aria-label"]=r),oi(y,R)}},n.prototype.alignText=function(t,e,i,r,s,o,a,l,h){"justify"!==l.textAlign?this.setText(t,e,i,r,s,o,l):a!==h.length-1?this.setText(t,e,i,r,s,o,l,l.width,"spacing"):this.setText(t,e,i,r,s,o,l)},n.prototype.setText=function(t,e,i,r,s,o,a,l,h){oi(e,"justify"!==a.textAlign?{x:s.toString(),y:o.toString()}:{x:s.toString(),y:o.toString(),textLength:l||0,lengthAdjust:h||"spacing"}),t.setAttribute("fill",i.text),e.appendChild(r),t.appendChild(e)},n.prototype.drawImage=function(t,e,i,r){var s;i&&(s=i.getElementById(e.id+"image")),s||(s=document.createElementNS("http://www.w3.org/2000/svg","image"),t.appendChild(s));var o=new Image;o.src=e.source;var a="None"!==e.scale?e.scale:"",l=e.alignment,h=l.charAt(0).toLowerCase()+l.slice(1);"Stretch"!==a&&(h+=" "+a.charAt(0).toLowerCase()+a.slice(1)),oi(s,{id:e.id+"image",x:e.x.toString(),y:e.y.toString(),transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")",width:e.width.toString(),visibility:e.visible?"visible":"hidden",height:e.height.toString(),preserveAspectRatio:h,opacity:e.opacity.toString()}),s.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",o.src.toString())},n.prototype.drawHTMLContent=function(t,e,i,r,s){var o,a;if(e&&(o=e.querySelector("#"+t.id+"_html_element")),!o){(a=e.querySelector("#"+t.id+"_html_element")||e.querySelector("#"+t.nodeId+"_html_element"))||(a=Tt("div",{id:t.nodeId+"_html_element",class:"foreign-object"})),o=Tt("div",{id:t.id+"_html_element",class:"foreign-object"});var c=document.getElementById(t.diagramId).ej2_instances[0],d=!1;if(e.parentNode&&e.parentNode.parentNode&&e.parentNode.parentNode.parentNode&&e.parentNode.parentNode.parentNode.classList.contains("e-overview")&&(d=!0),d)c.isReact?c.renderReactTemplates(function(){o.appendChild(t.template.cloneNode(!0))}):o.appendChild(t.template.cloneNode(!0));else{if("string"==typeof t.template){var u=document.createElement("div");u.innerHTML=t.template,t.template=u,c.selectedItems.userHandles.filter(function(g){return g.name===t.id.split("_shape")[0]&&""!==g.template})[0].template=t.template}t.isTemplate&&t.template?o.appendChild(t.template):t.template&&o.appendChild(t.template.cloneNode(!0))}void 0!==s&&e.childNodes.length>s&&e.insertBefore(o,e.childNodes[parseInt(s.toString(),10)]),a.appendChild(o),e.appendChild(a)}var f=En(t).topLeft;o.setAttribute("style","height:"+t.actualSize.height+"px; width:"+t.actualSize.width+"px;left:"+f.x+"px; top:"+f.y+"px;position:absolute;transform:rotate("+(t.rotateAngle+t.parentTransform)+"deg);pointer-events:"+(r?"all":"none")+";visibility:"+(t.visible?"visible":"hidden")+";opacity:"+t.style.opacity+";")},n.prototype.drawNativeContent=function(t,e,i,r,s){var o,a;if(s&&(o=s.getElementById(t.id+"_native_element"),a=s.getElementById(t.id+"_clip")),!o){(o=document.createElementNS("http://www.w3.org/2000/svg","g")).setAttribute("id",t.id+"_native_element"),o.appendChild(t.template.cloneNode(!0));var l=this.createGElement("g",{id:t.id+"_inner_native_element"});l.appendChild(o),e.appendChild(l)}a&&o.removeChild(a),o.setAttribute("style","visibility:"+(t.visible?"visible":"hidden")+";opacity:"+t.style.opacity+";"),this.setNativTransform(t,o,i,r),"Slice"===t.scale&&this.drawClipPath(t,o,i,r,s),oi(o,t.description?{role:"img","aria-label":t.description}:{})},n.prototype.setNativTransform=function(t,e,i,r){var s=0!==t.contentSize.width?t.contentSize.width:1,o=0!==t.contentSize.height?t.contentSize.height:1;e.setAttribute("transform","rotate("+t.parentTransform+","+t.offsetX+","+t.offsetY+") translate("+(t.offsetX-t.templatePosition.x*r/s-r*t.pivot.x)+","+(t.offsetY-t.templatePosition.y*i/o-i*t.pivot.y)+") scale("+r/s+","+i/o+")")},n.prototype.drawClipPath=function(t,e,i,r,s){var o=t.contentSize.width,a=t.contentSize.height,l=t.width/(r/o),h=t.height/(i/a),c=t.templatePosition.x+(t.width>=t.height?0:(o-l)/2),d=t.templatePosition.y+(t.height>=t.width?0:(a-h)/2),u=s.getElementById(t.id+"_clip");(u=document.createElementNS("http://www.w3.org/2000/svg","clipPath")).setAttribute("id",t.id+"_clip"),e.appendChild(u);var p=s.getElementById(t.id+"_clip_rect");return p=document.createElementNS("http://www.w3.org/2000/svg","rect"),u.appendChild(p),oi(p,{id:t.id+"_clip_rect",width:l.toString(),height:h.toString(),x:c.toString(),y:d.toString()}),om()?e.setAttribute("clip-path","url("+location.protocol+"//"+location.host+location.pathname+"#"+t.id+"_clip)"):e.setAttribute("clip-path","url(#"+t.id+"_clip)"),e},n.prototype.renderGradient=function(t,e,i){var r,s,o,h,c,a=IT(i),l=a.getElementById(i+"gradient_pattern");if(l||(l=Bi("defs",{id:i+"gradient_pattern"}),a.insertBefore(l,a.firstChild)),bF(e.id),"None"!==t.gradient.type){for(var d=0;dt.width&&("Ellipsis"===t.textOverflow||"Clip"===t.textOverflow)&&"NoWrap"===t.textWrapping?0:.5*t.width:"right"===t.textAlign&&(c=1*t.width),s.x=0+c+(e?e.x:0),s.y=1.2+d-r.height/2,s},n}(),Pc=function(){function n(t,e,i){this.renderer=null,this.isSvgMode=!0,this.transform={x:0,y:0},this.diagramId=t,this.element=xt(this.diagramId),this.svgRenderer=e,this.isSvgMode=i,this.renderer=i?new Jp:new bo}return n.prototype.setCursor=function(t,e){t.style.cursor=e},n.prototype.setLayers=function(){this.iconSvgLayer=this.element.getElementsByClassName("e-ports-expand-layer")[0],this.adornerSvgLayer=this.element.getElementsByClassName("e-adorner-layer")[0],this.nativeSvgLayer=this.element.getElementsByClassName("e-native-layer")[0],this.diagramSvgLayer=this.element.getElementsByClassName("e-diagram-layer")[0]},n.prototype.getAdornerLayer=function(){return yT(this.diagramId)},n.prototype.getParentSvg=function(t,e,i){return this.diagramId&&t&&t.id?t.id.split("_icon_content").length>1||t.id.split("_nodeport").length>1||t.elementActions&Xr.ElementIsPort?this.iconSvgLayer:e&&"selector"===e?this.adornerSvgLayer:t instanceof Cn?this.nativeSvgLayer:this.diagramSvgLayer:i},n.prototype.getParentElement=function(t,e,i,r){var s=e;if(i&&this.diagramId&&t&&t.id){t.id.split("_icon_content").length>1?(s=i.getElementById(this.diagramId+"_diagramExpander"),e=null):t.id.split("_nodeport").length>1?s=i.getElementById(this.diagramId+"_diagramPorts"):t instanceof Cn?(s=i.getElementById(this.diagramId+"_nativeLayer"),e=null):t.elementActions&Xr.ElementIsPort?(s=i.getElementById(this.diagramId+"_diagramPorts"),e=null):s=i.getElementById(this.diagramId+"_diagramLayer");var o=this.getGroupElement(t,e||s,r);s=o.g,o.svg&&(i=o.svg)}return{g:s,svg:i}},n.prototype.getGroupElement=function(t,e,i){var r,o,s=this.getParentSvg(t);if(e&&s){if(s&&!(r=s.getElementById(t.id+"_groupElement"))&&s!==this.nativeSvgLayer){var a=this.nativeSvgLayer;r=a.getElementById(t.id+"_groupElement"),o=a}r||(r=this.svgRenderer.createGElement("g",{id:t.id+"_groupElement"}),void 0!==i&&e.childNodes.length>i?e.insertBefore(r,e.childNodes[parseInt(i.toString(),10)]):e.appendChild(r))}return{g:r,svg:o}},n.prototype.renderElement=function(t,e,i,r,s,o,a,l,h,c,d){t instanceof Cs?(t.id=t.id?t.id:Qe(),this.renderContainer(t,e,i,r,s,o,a,l,h,c,d)):t instanceof CI?this.renderImageElement(t,e,r,s,a):t instanceof Ke?this.renderPathElement(t,e,r,s,a,h,d):t instanceof ni?this.renderTextElement(t,e,r,s,a,c):t instanceof Cn?this.renderNativeElement(t,e,r,s,a):t instanceof Jn?this.renderHTMLElement(t,e,i,r,s,a,l):this.renderRect(t,e,r,s,h)},n.prototype.drawSelectionRectangle=function(t,e,i,r,s,o){var a={width:i*o.scale,height:r*o.scale,x:.5+(t=(t+o.tx)*o.scale),y:.5+(e=(e+o.ty)*o.scale),fill:"transparent",stroke:"gray",angle:0,pivotX:.5,pivotY:.5,strokeWidth:1,dashArray:"6 3",opacity:1,visible:!0,id:s.id+"_selected_region"},l=this.getAdornerLayer();this.svgRenderer.updateSelectionRegion(l,a)},n.prototype.renderHighlighter=function(t,e,i){var r=t.actualSize.width||2,s=t.actualSize.height||2,o=t.offsetX-r*t.pivot.x,a=t.offsetY-s*t.pivot.y;this.svgRenderer.drawRectangle(e,{width:r*i.scale,height:s*i.scale,x:o=(o+i.tx)*i.scale,y:a=(a+i.ty)*i.scale,fill:"transparent",stroke:"#8CC63F",angle:t.rotateAngle,pivotX:t.pivot.x,pivotY:t.pivot.y,strokeWidth:4,dashArray:"",opacity:1,cornerRadius:0,visible:!0,id:e.id+"_highlighter",class:"e-diagram-highlighter"},this.diagramId,void 0,void 0,e)},n.prototype.renderSelectionRectangle=function(t,e,i,r){var s=t.actualSize.width||2,o=t.actualSize.height||2,a=t.offsetX-s*t.pivot.x,l=t.offsetY-o*t.pivot.y,h={width:s*i.scale,height:o*i.scale,x:a=(a+i.tx)*i.scale,y:l=(l+i.ty)*i.scale,fill:"transparent",stroke:"#00cc00",angle:t.rotateAngle,pivotX:t.pivot.x,pivotY:t.pivot.y,strokeWidth:r?2:1,dashArray:"",opacity:1,cornerRadius:0,visible:!0,id:t.id+"_highlighter",class:r?"e-diagram-first-selection-indicator e-diagram-selection-indicator":"e-diagram-selection-indicator"},c=this.getParentSvg(t,"selector");this.svgRenderer.drawRectangle(e,h,this.diagramId,void 0,void 0,c)},n.prototype.renderSelectionLine=function(t,e,i,r){var s=this.getBaseAttributes(t,i);s.data=t.absolutePath,s.id=s.id+"_highlighter";var o=t.description?t.description:t.id;this.isSvgMode||(s.x=t.flipOffset.x?t.flipOffset.x:s.x,s.y=t.flipOffset.y?t.flipOffset.y:s.y),i&&(s.x=s.x*i.scale,s.y=s.y*i.scale),s.stroke="#00cc00",s.strokeWidth=r?2:1,s.class=r?"e-diagram-first-selection-indicator e-diagram-selection-indicator":"e-diagram-selection-indicator";var a=this.getParentSvg(t,"selector");this.svgRenderer.drawPath(e,s,this.diagramId,void 0,a,o,i.scale)},n.prototype.renderStackHighlighter=function(t,e,i,r,s,o,a){var l=t.actualSize.width||2,h=t.offsetX-l*t.pivot.x,c=t.actualSize.height||2,d=t.offsetY-c*t.pivot.y;h=(h+i.tx)*i.scale;var u,p=t.bounds,f="";if(d=(d+i.ty)*i.scale,r)if(o){var v,y;u="M 0 0 L "+(2+(g=l*i.scale))+" 0 Z",v=t.actualSize.width/Number(p.width?p.width:1)*i.scale,y=t.actualSize.height/Number(p.height?p.height:1)*i.scale,f=SI(II(Dd("M7,4 L8,4 8,7 11,7 11,8 8,8 8,11 7,11 7,8 4,8 4,7 7,7 z M7.5,0.99999994C3.9160004,1 1,3.9160004 0.99999994,7.5 1,11.084 3.9160004,14 7.5,14 11.084,14 14,11.084 14,7.5 14,3.9160004 11.084,1 7.5,0.99999994 z M7.5,0 C11.636002,0 15,3.3639984 15,7.5 15,11.636002 11.636002,15 7.5,15 3.3640003,15 0,11.636002 0,7.5 0,3.3639984 3.3640003,0 7.5,0 z")),v+g+2,y-8,!1,p.x,p.y,0,0),s.y>=t.offsetY&&(d+=c)}else{var g;a&&s.y>=t.offsetY&&(d+=c*i.scale),u="M -10 -10 L 0 0 Z M -10 10 L 0 0 Z M 0 0 L "+(g=l*i.scale)+" 0 Z M "+g+" 0 L "+(g+10)+" 10 Z L "+(g+10)+" -10 Z"}else u="M 10 -10 L 0 0 Z M -10 -10 L 0 0 Z M 0 0 L 0 "+(g=c*i.scale)+" Z M 0 "+g+" L -10 "+(g+10)+" Z L 10 "+(g+10)+" Z",s.x>=t.offsetX&&(h+=l*i.scale);this.svgRenderer.drawPath(e,{data:u+f,width:l*i.scale,height:c*i.scale,x:h,y:d,fill:"transparent",stroke:"#8CC63F",angle:t.rotateAngle,pivotX:t.pivot.x,pivotY:t.pivot.y,strokeWidth:1,dashArray:"",opacity:1,visible:!0,id:e.id+"_stack_highlighter",class:"e-diagram-highlighter"},this.diagramId)},n.prototype.drawLine=function(t,e){this.svgRenderer.drawLine(t,e)},n.prototype.drawPath=function(t,e){this.svgRenderer.drawPath(t,e,this.diagramId)},n.prototype.renderResizeHandle=function(t,e,i,r,s,o,a,l,h,c,d){var u=t.offsetX-t.actualSize.width*t.pivot.x,p=t.offsetY-t.actualSize.height*t.pivot.y,f=t.actualSize.height,g=t.actualSize.width;!c&&i&bt.Rotate&&_I(this.rendererActions)&&!z3(this.rendererActions)&&(this.renderPivotLine(t,e,o,s,a),this.renderRotateThumb(t,e,o,s,a)),this.renderBorder(t,e,o,l,h,c);var v=t.actualSize.width*r,y=t.actualSize.height*r;!h&&_I(this.rendererActions)&&!z3(this.rendererActions)&&(t.isTextAnnotation||(v>=40&&y>=40&&(s&mr.ResizeNorthWest&&this.renderCircularHandle("resizeNorthWest",t,u,p,e,qr(s,"ResizeNorthWest"),i&bt.ResizeNorthWest,o,void 0,a,{"aria-label":"Thumb to resize the selected object on top left side direction"},void 0,"e-diagram-resize-handle e-northwest",d),s&mr.ResizeNorthEast&&this.renderCircularHandle("resizeNorthEast",t,u+g,p,e,qr(s,"ResizeNorthEast"),i&bt.ResizeNorthEast,o,void 0,a,{"aria-label":"Thumb to resize the selected object on top right side direction"},void 0,"e-diagram-resize-handle e-northeast",d),s&mr.ResizeSouthWest&&this.renderCircularHandle("resizeSouthWest",t,u,p+f,e,qr(s,"ResizeSouthWest"),i&bt.ResizeSouthWest,o,void 0,a,{"aria-label":"Thumb to resize the selected object on bottom left side direction"},void 0,"e-diagram-resize-handle e-southwest",d),s&mr.ResizeSouthEast&&this.renderCircularHandle("resizeSouthEast",t,u+g,p+f,e,qr(s,"ResizeSouthEast"),i&bt.ResizeSouthEast,o,void 0,a,{"aria-label":"Thumb to resize the selected object on bottom right side direction"},void 0,"e-diagram-resize-handle e-southeast",d)),s&mr.ResizeNorth&&this.renderCircularHandle("resizeNorth",t,u+g/2,p,e,qr(s,"ResizeNorth"),i&bt.ResizeNorth,o,void 0,a,{"aria-label":"Thumb to resize the selected object on top side direction"},void 0,"e-diagram-resize-handle e-north",d),s&mr.ResizeSouth&&this.renderCircularHandle("resizeSouth",t,u+g/2,p+f,e,qr(s,"ResizeSouth"),i&bt.ResizeSouth,o,void 0,a,{"aria-label":"Thumb to resize the selected object on bottom side direction"},void 0,"e-diagram-resize-handle e-south",d),s&mr.ResizeWest&&this.renderCircularHandle("resizeWest",t,u,p+f/2,e,qr(s,"ResizeWest"),i&bt.ResizeWest,o,void 0,a,{"aria-label":"Thumb to resize the selected object on left side direction"},void 0,"e-diagram-resize-handle e-west",d),s&mr.ResizeEast&&this.renderCircularHandle("resizeEast",t,u+g,p+f/2,e,qr(s,"ResizeEast"),i&bt.ResizeEast,o,void 0,a,{"aria-label":"Thumb to resize the selected object on right side direction"},void 0,"e-diagram-resize-handle e-east",d)))},n.prototype.renderEndPointHandle=function(t,e,i,r,s,o,a,l,h,c){var f,g,d=t.sourcePoint,u=t.targetPoint,p=t.wrapper;if(this.renderCircularHandle("connectorSourceThumb",p,d.x,d.y,e,qr(r,"ConnectorSourceThumb"),i&bt.ConnectorSource,s,o,void 0,{"aria-label":"Thumb to move the source point of the connector"},void 0,"e-diagram-endpoint-handle e-sourceend",c),this.renderCircularHandle("connectorTargetThumb",p,u.x,u.y,e,qr(r,"ConnectorTargetThumb"),i&bt.ConnectorTarget,s,a,void 0,{"aria-label":"Thumb to move the target point of the connector"},void 0,"e-diagram-endpoint-handle e-targetend",c),l)if("Straight"===t.type&&t.segments.length>0)for(f=0;f0)for(f=0;f=3&&3===t.segments.length&&(S=1,b=t.segments.length-1),S=t.segments.length>t.maxSegmentThumb+2?2:S,b=t.segments.length>t.maxSegmentThumb+2?t.segments.length-2:b,1===t.segments.length&&t.segments[0].points.length<=2&&(S=1,b=t.segments.length),f=S;f=50&&i.allowDrag),this.renderOrthogonalThumb(t+"_"+(d+1),e,(i.points[parseInt(d.toString(),10)].x+i.points[d+1].x)/2,(i.points[parseInt(d.toString(),10)].y+i.points[d+1].y)/2,r,h,l,o,a,u)}else for(d=0;d=50&&i.allowDrag),this.renderOrthogonalThumb(t+"_"+(d+1),e,(i.points[parseInt(d.toString(),10)].x+i.points[d+1].x)/2,(i.points[parseInt(d.toString(),10)].y+i.points[d+1].y)/2,r,h,l,o,a,u)},n.prototype.renderOrthogonalThumb=function(t,e,i,r,s,o,a,l,h,c){var d,g,u=0,p=document.getElementById(this.diagramId);p&&(g=p.ej2_instances[0]);var y=h.constraints&qe.InheritSegmentThumbShape?g.segmentThumbShape:h.segmentThumbShape,b=h.constraints&qe.InheritSegmentThumbSize?g.segmentThumbSize:h.segmentThumbSize;if(d="horizontal"===a?function ure(n){return vre[""+n]}(y):c3(y),"Arrow"===y||"DoubleArrow"===y||"OpenArrow"===y)switch(c){case"Bottom":case"Right":u=180;break;default:u=0}else if("Fletch"===y||"OpenFetch"===y||"IndentedArrow"===y||"OutdentedArrow"===y)switch(c){case"Bottom":u=-90;break;case"Top":u=90;break;case"Right":u=180;break;default:u=0}var M={x:(i+l.tx)*l.scale-b/2,y:(r+l.ty)*l.scale-b/2,angle:u,fill:"#e2e2e2",stroke:"black",strokeWidth:1,dashArray:"",data:d,width:b,height:b,pivotX:.5,pivotY:.5,opacity:1,visible:o,id:t,class:"e-diagram-ortho-segment-handle"},w=af(M.data),C=new me(M.width,M.height),D=new Ke;M.data=D.updatePath(M.data,w,C),this.svgRenderer.drawPath(s,M,this.diagramId)},n.prototype.renderPivotLine=function(t,e,i,r,s){var o=t,l=!!(r&mr.Rotate);s&&(l=!1);var h=this.getBaseAttributes(o,i);h.fill="None",h.stroke="black",h.strokeWidth=1,h.dashArray="2,3",h.visible=l;var c=i.scale;h.x*=c,h.y*=c,h.width*=c,h.height*=c,h.id="pivotLine",h.class="e-diagram-pivot-line";var u={x:o.actualSize.width*o.pivot.x*c,y:0};h.startPoint={x:o.actualSize.width*o.pivot.x*c,y:-20},h.endPoint=u,this.svgRenderer.drawLine(e,h)},n.prototype.renderBezierLine=function(t,e,i,r,s,o){var l=this.getBaseAttributes(e,o);l.id=t,l.stroke="black",l.strokeWidth=1,l.dashArray="3,3",l.fill="None",l.class="e-diagram-bezier-control-line",l.x=0,l.y=0;var h=o.scale,g={x:(s.x+o.tx)*h,y:(s.y+o.ty)*h};l.startPoint={x:(r.x+o.tx)*h,y:(r.y+o.ty)*h},l.endPoint=g,this.svgRenderer.drawLine(i,l)},n.prototype.renderCircularHandle=function(t,e,i,r,s,o,a,l,h,c,d,u,p,f){var g=e,v={x:i,y:r};if(0!==g.rotateAngle||0!==g.parentTransform){var y=Hi();qi(y,g.rotateAngle+g.parentTransform,g.offsetX,g.offsetY),v=Je(y,v)}var S=this.getBaseAttributes(g);S.stroke="black",S.strokeWidth=1,void 0!==u?(S.id="segmentEnd_"+u,S.fill="#e2e2e2"):S.fill=h?"#8CC63F":"white",S.cornerRadius=f/2,S.angle=e.rotateAngle,S.id=t,S.visible=o,S.class=p,S.width=f,S.height=f,S.x=(v.x+l.tx)*l.scale,S.y=(v.y+l.ty)*l.scale,S.x=S.x-S.width/2,S.y=S.y-S.height/2,h&&(S.class+=" e-connected"),c&&(S.visible=!1);var b=this.getParentSvg(e,"selector");this.svgRenderer.drawRectangle(s,S,this.diagramId,!0,!0,b,d,!0,a)},n.prototype.renderBezierHandle=function(t,e,i,r,s,o,a,l,h,c,d,u,p){var v,f=document.getElementById(this.diagramId);f&&(v=f.ej2_instances[0]);var y=e,S={x:i,y:r};if(0!==y.rotateAngle||0!==y.parentTransform){var b=Hi();qi(b,y.rotateAngle+y.parentTransform,y.offsetX,y.offsetY),S=Je(b,S)}var D=a.constraints&qe.InheritSegmentThumbSize?v.segmentThumbSize:a.segmentThumbSize,A=c3(a.constraints&qe.InheritSegmentThumbShape?v.segmentThumbShape:a.segmentThumbShape),x=this.getBaseAttributes(y);x.stroke="black",x.strokeWidth=1,void 0!==d?(x.id="segmentEnd_"+d,x.fill="#e2e2e2"):x.fill=h?"#8CC63F":"white",x.angle=e.rotateAngle,x.id=t,x.visible=o,x.class=u,x.width=D,x.height=D,x.data=A,x.x=(S.x+l.tx)*l.scale,x.y=(S.y+l.ty)*l.scale,x.x=x.x-x.width/2,x.y=x.y-x.height/2,h&&(x.class+=" e-connected"),c&&(x.visible=!1);var R=af(x.data),L=new me(x.width,x.height),O=new Ke;x.data=O.updatePath(x.data,R,L);var N=this.getParentSvg(e,"selector");this.svgRenderer.drawPath(s,x,this.diagramId,!0,N)},n.prototype.renderBorder=function(t,e,i,r,s,o){var l=this.getBaseAttributes(t,i);l.x*=i.scale,l.y*=i.scale,l.width*=i.scale,l.height*=i.scale,l.fill="transparent",l.stroke="#097F7F",l.strokeWidth=1.2,l.gradient=null,l.dashArray="6,3",l.class="e-diagram-selector",o&&(l.class+=" e-diagram-lane"),l.id="borderRect",l.id=this.rendererActions&Qa.DrawSelectorBorder?"borderRect_symbol":"borderRect",r||(l.class+=" e-disabled"),s&&(l.class+=" e-thick-border"),l.cornerRadius=0;var h=this.getParentSvg(t,"selector");this.svgRenderer.drawRectangle(e,l,this.diagramId,void 0,!0,h)},n.prototype.renderUserHandler=function(t,e,i,r,s,o){for(var l,a=t.wrapper,h=0,c=t.userHandles;h0||d.disableNodes&&t.nodes.length>0||"Drag"===s&&o)&&(l=!1);var u=document.getElementById(d.name+"_template_hiddenUserHandle");u&&(d.template=u.childNodes[0].cloneNode(!0));var p=iT(t,d,i);if(p.x=(p.x+i.tx)*i.scale,p.y=(p.y+i.ty)*i.scale,d.visible&&(d.visible=!!(t.constraints&mr.UserHandle)),l)if(d.pathData){var f=d.pathData?d.pathData:d.content,g=this.getBaseAttributes(a);g.id=d.name+"_userhandle",g.fill=d.backgroundColor,g.stroke=d.borderColor,g.strokeWidth=d.borderWidth,g.centerX=p.x,g.centerY=p.y,g.radius=.5*d.size,g.class="e-diagram-userhandle-circle",g.angle=0,g.visible=d.visible,g.opacity=1,this.svgRenderer.drawCircle(e,g,1,{"aria-label":d.name+"user handle"});var y=[];y=II(y=Dd(f));var S=af(f),w=SI(y,(d.size-.45*d.size)/S.width,(d.size-.45*d.size)/S.height,!0,S.x,S.y,0,0);S=af(w),this.svgRenderer.drawPath(e,C={x:p.x-S.width/2,y:p.y-S.height/2,angle:0,id:"",class:"e-diagram-userhandle-path",fill:d.pathColor,stroke:d.backgroundColor,strokeWidth:.5,dashArray:"",data:w,width:d.size-5,height:d.size-5,pivotX:0,pivotY:0,opacity:1,visible:d.visible},this.diagramId,void 0,void 0,{"aria-label":d.name+"user handle"})}else if(d.content){var D=new Cn(d.name,this.diagramId);D.content=d.content,D.offsetX=p.x,D.offsetY=p.y,D.id=d.name+"_shape",D.horizontalAlignment="Center",D.verticalAlignment="Center",D.visible=d.visible,D.setOffsetWithRespectToBounds(p.x,p.y,"Fraction"),D.relativeMode="Object",D.description=d.name||"User handle",D.measure(new me(d.size,d.size)),D.arrange(D.desiredSize),this.svgRenderer.drawNativeContent(D,e,d.size,d.size,this.adornerSvgLayer)}else if(d.source){var C,A=new CI;(C=this.getBaseAttributes(A,i)).width=d.size,C.height=d.size,C.x=p.x-d.size/2,C.y=p.y-d.size/2,C.sourceWidth=d.size,C.sourceHeight=d.size,C.alignment=A.imageAlign,C.source=d.source,C.scale=A.imageScale,C.visible=d.visible,C.description=d.name||"User handle",C.id=d.name+"_",this.renderer.drawImage(e,C,this.adornerSvgLayer,!1)}else{var x=new Jn(d.name,this.diagramId);x.offsetX=p.x,x.offsetY=p.y,x.id=d.name+"_shape",x.visible=d.visible,x.relativeMode="Object",x.template=d.template,x.measure(new me(d.size,d.size)),x.arrange(x.desiredSize),this.svgRenderer.drawHTMLContent(x,r,void 0,!0,void 0)}}},n.prototype.renderRotateThumb=function(t,e,i,r,s){new Ke;var a,l=new me;l.width=18,l.height=16;var d=!!(r&mr.Rotate);s&&(d=!1);var p=t.offsetX-t.actualSize.width*t.pivot.x+t.pivot.x*t.actualSize.width,f=t.offsetY-t.actualSize.height*t.pivot.y;if(a={x:(p=(p+i.tx)*i.scale)-.5*l.width,y:(f=(f+i.ty)*i.scale)-30-.5*l.height},0!==t.rotateAngle||0!==t.parentTransform){var g=Hi();qi(g,t.rotateAngle+t.parentTransform,(i.tx+t.offsetX)*i.scale,(i.ty+t.offsetY)*i.scale),a=Je(g,a)}this.svgRenderer.drawPath(e,{x:a.x,y:a.y,angle:t.rotateAngle+t.parentTransform,fill:"#231f20",stroke:"black",strokeWidth:.5,dashArray:"",data:"M 16.856144362449648 10.238890446662904 L 18.000144362449646 3.437890446662903L 15.811144362449646 4.254890446662903 C 14.837144362449646 2.5608904466629028 13.329144362449647 1.2598904466629026 11.485144362449645 0.5588904466629026 C 9.375144362449646 - 0.24510955333709716 7.071144362449646 - 0.18010955333709716 5.010144362449646 0.7438904466629028 C 2.942144362449646 1.6678904466629028 1.365144362449646 3.341890446662903 0.558144362449646 5.452890446662903 C - 0.244855637550354 7.567890446662903 - 0.17985563755035394 9.866890446662904 0.7431443624496461 11.930890446662904 C 1.6681443624496461 13.994890446662904 3.343144362449646 15.575890446662903 5.457144362449647 16.380890446662903 C 6.426144362449647 16.7518904466629 7.450144362449647 16.9348904466629 8.470144362449647 16.9348904466629 C 9.815144362449647 16.9348904466629 11.155144362449647 16.6178904466629 12.367144362449647 15.986890446662901 L 11.351144362449647 14.024890446662901 C 9.767144362449647 14.8468904466629 7.906144362449647 14.953890446662902 6.237144362449647 14.3178904466629 C 4.677144362449647 13.7218904466629 3.444144362449647 12.5558904466629 2.758144362449647 11.028890446662901 C 2.078144362449646 9.501890446662903 2.031144362449646 7.802890446662903 2.622144362449646 6.243890446662903 C 3.216144362449646 4.6798904466629025 4.387144362449646 3.442890446662903 5.914144362449646 2.760890446662903 C 7.437144362449646 2.078890446662903 9.137144362449646 2.0298904466629026 10.700144362449645 2.6258904466629027 C 11.946144362449646 3.100890446662903 12.971144362449646 3.9538904466629026 13.686144362449646 5.049890446662903 L 11.540144362449645 5.850890446662903 L 16.856144362449648 10.238890446662904 Z",width:20,height:20,pivotX:0,pivotY:0,opacity:1,visible:d,id:"rotateThumb",class:"e-diagram-rotate-handle"},this.diagramId,!0,void 0,{"aria-label":"Thumb to rotate the selected object"})},n.prototype.renderPathElement=function(t,e,i,r,s,o,a){var l=this.getBaseAttributes(t,i,o);if(l.data=t.absolutePath,l.data=t.absolutePath,t.isPathPort&&a){l.x=a[t.id]?a[t.id].cx:l.x,l.y=a[t.id]?a[t.id].cy:l.y,t.bounds.x=l.x,t.bounds.y=l.y;var h=document.getElementById(this.diagramId);h&&"PortDrag"!==h.ej2_instances[0].eventHandler.currentAction&&(t.offsetX=l.x+t.width/2,t.offsetY=l.y+t.height/2)}var u=t.description?t.description:t.id;if(this.isSvgMode||(l.x=t.flipOffset.x?t.flipOffset.x:l.x,l.y=t.flipOffset.y?t.flipOffset.y:l.y),t.isExport){var p=t.absoluteBounds,f=Dd(l.data),g=this.findAndStoreArcValues(f);l.arc=g,l.data=BF(t,p,0,l)}this.renderer.drawPath(e,l,this.diagramId,void 0,r,u)},n.prototype.findAndStoreArcValues=function(t){var e=[];return t.forEach(function(i){"A"===i.command&&e.push({r1:i.r1/2,r2:i.r2/2})}),e},n.prototype.renderSvgGridlines=function(t,e,i,r,s,o){var a=document.createElementNS("http://www.w3.org/2000/svg","pattern"),l=document.createElementNS("http://www.w3.org/2000/svg","defs");l.setAttribute("id",this.diagramId+"_grid_pattern_defn"),(t.constraints&Kt.ShowHorizontalLines||t.constraints&Kt.ShowVerticalLines)&&a.setAttribute("id",this.diagramId+"_pattern");var h=0,c=0,d=0,u=0,p=1,f=!1,g="Lines"===t.gridType,v=g?t.verticalGridlines.lineIntervals:t.verticalGridlines.dotIntervals,y=g?t.horizontalGridlines.lineIntervals:t.horizontalGridlines.dotIntervals;if(r.showRulers&&r.dynamicGrid&&s&&o)d=o.updateSegmentWidth(i.scale),u=s.updateSegmentWidth(i.scale),t.horizontalGridlines.scaledIntervals=[d/s.interval],t.verticalGridlines.scaledIntervals=[u/o.interval],f=!0;else{for(var S=0;S=2)for(;e>=2;)e/=2;else if(e<=.5)for(;e<=.5;)e*=2;var i;if(t.horizontalGridlines.scaledIntervals=t.horizontalGridlines.snapIntervals,t.verticalGridlines.scaledIntervals=t.verticalGridlines.snapIntervals,1!==e){var r=t.horizontalGridlines;for(r.scaledIntervals=[],i=0;ithis.groupElement.actualSize.height&&("Clip"===t.style.textOverflow||"Ellipsis"===t.style.textOverflow)&&(a.y=a.y+(a.height-this.groupElement.actualSize.height)/2),this.renderer.drawRectangle(e,a,this.diagramId,void 0,void 0,r),this.renderer.drawText(e,a,r,l,this.diagramId,t.isExport&&Math.min(t.exportScaleValue.x||t.exportScaleValue.y),this.groupElement),this.isSvgMode&&(t.doWrap=!1)},n.prototype.renderNativeElement=function(t,e,i,r,s){var o,a,l=this.getParentSvg(t,void 0,e)||r,h=this.getParentElement(t,e,l).g||e,c=this.getBaseAttributes(t,i);switch(c.fill="transparent",c.cornerRadius=t.cornerRadius,c.stroke="transparent",this.renderer.drawRectangle(e,c,this.diagramId,void 0,void 0,r),t.scale){case"None":o=t.contentSize.width,a=t.contentSize.height;break;case"Stretch":o=t.actualSize.width,a=t.actualSize.height;break;case"Meet":o=a=t.actualSize.width<=t.actualSize.height?t.actualSize.width:t.actualSize.height;break;case"Slice":o=a=t.actualSize.width>=t.actualSize.height?t.actualSize.width:t.actualSize.height}this.svgRenderer&&this.svgRenderer.drawNativeContent(t,h,a,o,l)},n.prototype.renderHTMLElement=function(t,e,i,r,s,o,a){var l=this.getBaseAttributes(t,r);l.fill="transparent",l.cornerRadius=t.cornerRadius,l.stroke="transparent",this.renderer.drawRectangle(e,l,this.diagramId,void 0,void 0,s),this.svgRenderer&&this.svgRenderer.drawHTMLContent(t,i.children[0],r,function Sse(n){var t=n.parentElement;do{if(pm(t,"e-diagram"))return!0;t=t.parentElement}while(t);return!1}(i),a)},n.prototype.renderImageElement=function(t,e,i,r,s){var o=this.getBaseAttributes(t,i);o.cornerRadius=0,this.renderer.drawRectangle(e,o,this.diagramId,void 0,void 0,r);var a,l,h,c,g,d=t.contentSize.width,u=t.contentSize.height,p=o.width/d,f=o.height/u;if("Stretch"===t.stretch)a=d*(g=Math.min(p,f)),l=u*g;else switch(t.stretch){case"Meet":a=d*(g=Math.min(p,f)),l=u*g,o.x+=Math.abs(o.width-a)/2,o.y+=Math.abs(o.height-l)/2;break;case"Slice":g=Math.max(p,f),h=o.width/(a=d*g)*d,c=o.height/(l=u*g)*u;break;case"None":a=d,l=u}o.width=a,o.height=l,o.sourceWidth=h,o.sourceHeight=c,o.source=t.source,o.alignment=t.imageAlign,o.scale=t.imageScale,o.description=t.description?t.description:t.id,this.renderer.drawImage(e,o,r,s)},n.prototype.renderContainer=function(t,e,i,r,s,o,a,l,h,c,d){var g,u={svg:s,g:e},p=document.getElementById(this.diagramId);if(p&&(g=p.ej2_instances[0]),this.diagramId&&(s=this.getParentSvg(t)||s,this.isSvgMode)){var v=this.getParentElement(t,e,s,l).g||e;s=this.getParentSvg(this.hasNativeParent(t.children))||s;var y=this.getParentElement(this.hasNativeParent(t.children),v,s,l);u.svg=y.svg||s,u.g=y.g||v,o&&s&&(s.getElementById(u.g.id)||e.appendChild(u.g)),e=u.g}if(this.renderRect(t,e,r,s),this.groupElement=t,t.hasChildren()){for(var b,S=void 0,M=0,w=t.children;M0&&(D=g.selectedItems.nodes[0]);var L,A=void 0,x=void 0,R=!1;if(g&&g.selectedItems&&(L=g.getObject(t.id)),"None"!==t.flip&&(D=L),"None"===t.flip&&(D=L),D&&D.flipMode&&(R=!0),!(t.elementActions&Xr.ElementIsGroup)&&g instanceof Rl&&g.nameTable[t.id]&&"connectors"!==g.nameTable[t.id].propName&&R&&D){if(A=t.children&&t.children[0]instanceof Cn?document.getElementById(D.id+"_content_inner_native_element"):document.getElementById(D.id+"_content_groupElement"),!(t.children[0]instanceof Cn)&&"Text"!==D.shape.type&&"None"!==D.flipMode&&"Label"!==D.flipMode&&"All"!==D.flipMode&&"PortAndLabel"!==D.flipMode&&"LabelText"!==D.flipMode&&"PortAndLabelText"!==D.flipMode&&"LabelAndLabelText"!==D.flipMode||t.children[0]instanceof Cn&&"Port"===D.flipMode)return void this.renderFlipElement(t,A,D.flip);if((t.children[0]instanceof Cn&&("All"===D.flipMode||"Label"===D.flipMode)||"Label"===D.flipMode||"PortAndLabel"===D.flipMode||"LabelText"===D.flipMode||"PortAndLabelText"===D.flipMode||"LabelAndLabelText"===D.flipMode||"Image"===D.shape.type&&"Label"===D.flipMode)&&this.renderFlipElement(t,A,t.flip),"None"!==t.flip&&"None"===D.flipMode)this.renderFlipElement(t,A,t.flip);else if("None"!==t.flip&&("Label"===D.flipMode||"PortAndLabel"===D.flipMode||"LabelText"===D.flipMode||"PortAndLabelText"===D.flipMode||"LabelAndLabelText"===D.flipMode)||t.children[0]instanceof Cn&&"None"!==t.flip&&D&&("None"===D.flipMode||"All"===D.flipMode)){for(var O=0;O0){var i=t[0];if(i instanceof Cn)return i;i.children&&i.children.length&&this.hasNativeParent(i.children,e++||0)}},n.prototype.renderRect=function(t,e,i,r,s){var o=this.getBaseAttributes(t,i,s);o.cornerRadius=t.cornerRadius||0,t.isExport&&(o.cornerRadius*=t.exportScaleValue.x),this.renderer.drawRectangle(e,o,this.diagramId,t.isExport,void 0,r,t.description?t.description:t.id)},n.prototype.drawRect=function(t,e){e.cornerRadius=0,this.svgRenderer.drawRectangle(t,e,this.diagramId)},n.prototype.getBaseAttributes=function(t,e,i){var r={width:t.actualSize.width,height:t.actualSize.height,x:t.offsetX-t.actualSize.width*t.pivot.x,y:t.offsetY-t.actualSize.height*t.pivot.y,fill:t.style.fill,stroke:t.style.strokeColor,angle:t.rotateAngle+t.parentTransform,pivotX:t.pivot.x,pivotY:t.pivot.y,strokeWidth:t.style.strokeWidth,dashArray:t.style.strokeDashArray||"",opacity:t.style.opacity,shadow:t.shadow,gradient:t.style.gradient,visible:t.visible,id:t.id,description:t.description,canApplyStyle:t.canApplyStyle,shapeType:t.shapeType};return"Page"===t.rotationReference&&(r.angle=t.rotateAngle),i&&(r.x=r.x-.5,r.y=r.y-.5),t.isExport&&(r.width*=t.exportScaleValue.x,r.height*=t.exportScaleValue.y,r.x*=t.exportScaleValue.x,r.y*=t.exportScaleValue.y,r.strokeWidth*=t.exportScaleValue.x),t.flip&&(r.flip=t.flip),e&&(r.x+=e.tx,r.y+=e.ty),r},n.renderSvgBackGroundImage=function(t,e,i,r,s,o){if(t.source){var l=IT(e.id).getElementById(e.id+"_image");if(!l){var h=function Toe(n){return xt(n).getElementsByClassName("e-background-image-layer")[0]}(e.id);(l=document.createElementNS("http://www.w3.org/2000/svg","image")).setAttribute("id",e.id+"_image"),h.appendChild(l)}var c=new Image;c.src=t.source,l.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",c.src.toString());var d="None"!==t.scale?t.scale:"",u=t.align,p=u.charAt(0).toLowerCase()+u.slice(1);d&&(p+=" "+d.charAt(0).toLowerCase()+d.slice(1)),oi(l,{id:e.id+"_image",x:i,y:r,width:s,height:o,preserveAspectRatio:p})}},n.prototype.transformLayers=function(t,e){var i=t.tx*t.scale,r=t.ty*t.scale,s="domTable";if(i!==this.transform.x||r!==this.transform.y||0===i||0===r){e&&(window[""+s][this.diagramId+"_diagramLayer"]||(window[""+s][this.diagramId+"_diagramLayer"]=this.diagramSvgLayer.getElementById(this.diagramId+"_diagramLayer")),window[""+s][this.diagramId+"_diagramLayer"].setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+"),scale("+t.scale+")"));var a=function Aoe(n){var t="domTable",e=null;return window[t][n+"_gridline"]?e=window[t][n+"_gridline"]:(e=_d(n).getElementById(n+"_gridline"),window[t][n+"_gridline"]=e),e}(this.diagramId);return a.setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+")"),window[""+s][this.diagramId+"_diagramPorts"]||(window[""+s][this.diagramId+"_diagramPorts"]=this.iconSvgLayer.getElementById(this.diagramId+"_diagramPorts")),window[""+s][this.diagramId+"_diagramPorts"].setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+"),scale("+t.scale+")"),window[""+s][this.diagramId+"_diagramExpander"]||(window[""+s][this.diagramId+"_diagramExpander"]=this.iconSvgLayer.getElementById(this.diagramId+"_diagramExpander")),window[""+s][this.diagramId+"_diagramExpander"].setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+"),scale("+t.scale+")"),window[""+s][this.diagramId+"_nativeLayer"]||(window[""+s][this.diagramId+"_nativeLayer"]=this.nativeSvgLayer.getElementById(this.diagramId+"_nativeLayer")),window[""+s][this.diagramId+"_nativeLayer"].setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+"),scale("+t.scale+")"),Io(this.diagramId).children[0].style.transform="translate("+t.tx*t.scale+"px,"+t.ty*t.scale+"px)scale("+t.scale+")",this.transform={x:t.tx*t.scale,y:t.ty*t.scale},!0}return!1},n.prototype.updateNode=function(t,e,i,r,s,o,a){this.renderElement(t,e,i,r,this.getParentSvg(t),void 0,void 0,s,null,o,a)},n}(),use=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),tb=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},uF=function(n){function t(e,i){var r=n.call(this,e,i)||this;return r.mode="Canvas",r.id="overview",r.actionName="",r.startPoint=null,r.currentPoint=null,r.prevPoint=null,r.scale=null,r.inAction=!1,r.viewPortRatio=1,r.horizontalOffset=0,r.verticalOffset=0,r.model={},r.event=!0,r.overviewid=88123,r.model={width:r.width,height:r.height},r}return use(t,n),t.prototype.onPropertyChanged=function(e,i){for(var r=0,s=Object.keys(e);r0||e.toString().indexOf("%")>0?e.toString():e.toString()+"px"},t.prototype.renderCanvas=function(e){var i=document.getElementById(this.element.id+"_canvas");i||(i=Tt("div",{}),this.element.appendChild(i)),Ho(i,{id:this.element.id+"_canvas",class:"drawing",style:"position:relative; height:"+this.getSizeValue(this.model.height)+"; width:"+this.getSizeValue(this.model.width)+";style:-ms-touch-action: none;touch-action: none;"}),this.element.setAttribute("tabindex",String(-1)),this.element.style.overflow="hidden",this.element.style.height=String(this.model.height),this.element.style.width=String(this.model.width),this.canvas=i},t.prototype.setParent=function(e){var i=document.getElementById(e);if(this.parent){var s=this.parent;this.parent=null,s.setOverview(null,this.element.id),this.removeDocument(this)}this.parent=this.getDiagram(i,"ej2_instances"),this.parent&&this.parent.setOverview(this)},t.prototype.getDiagram=function(e,i){for(var r,s=e[""+i].length,o=0;o0?p:Math.floor(window.innerWidth)}if(0===h){var f=Math.floor(window.innerHeight-u-Math.floor(c.top));h=f>0?f:Math.floor(window.innerHeight)}l>0&&(s.setAttribute("width",String(l)),this.model.height=h),h>0&&(s.setAttribute("height",String(h)),this.model.width=l),e.diagramLayerDiv||(e.diagramLayerDiv=Tt("div",{}),e.diagramLayer=bo.createCanvas(this.element.id+"_diagramLayer",this.model.width,this.model.height),e.diagramLayer.setAttribute("style","position:absolute; left:0px; top:0px "),e.diagramLayerDiv.appendChild(e.diagramLayer),e.canvas.appendChild(e.diagramLayerDiv)),Ho(e.diagramLayerDiv,{id:this.element.id+"_diagramLayer_div",style:"width:"+this.model.width+"px; height:"+this.model.height+"px;position:absolute;top:0px;left:0px"}),this.renderHtmlLayer(e.canvas),this.renderNativeLayer(e.canvas,e),this.addOverviewRectPanel(e)},t.prototype.removeDocument=function(e){var i=document.getElementById(this.canvas.id+"_svg");this.canvas.removeChild(i);var r=document.getElementById(this.element.id+"_htmlLayer");this.canvas.removeChild(r);var s=document.getElementById(this.element.id+"_diagramLayer_div");this.canvas.removeChild(s),e.diagramLayerDiv=null,e.diagramLayer=null,window.domTable[this.id+"html_layer"]=null},t.prototype.renderHtmlLayer=function(e){var i=Tt("div",{id:this.element.id+"_htmlLayer",class:"e-html-layer",style:"pointer-events:none;position:absolute;top:0px;left:0px;"}),s=Tt("div",{id:this.element.id+"_htmlLayer_div",style:"position:absolute;top:0px;left:0px;"});return i.appendChild(s),e.appendChild(i),i},t.prototype.renderNativeLayer=function(e,i){if(!document.getElementById(this.element.id+"_nativeLayer_svg")){var r=this.parent.createSvg(this.element.id+"_nativeLayer_svg",this.model.width,this.model.height),s=Bi("g",{id:this.element.id+"_nativeLayer"});r.appendChild(s),i.diagramLayerDiv.appendChild(r),oi(r,{class:"e-native-layer"})}},t.prototype.addOverviewRectPanel=function(e){var i=document.getElementById(this.canvas.id+"_overviewsvg");i&&i.parentNode.removeChild(i),i=Bi("svg",{id:this.canvas.id+"_overviewsvg",class:"overviewsvg",version:"1.1",style:"position:absolute;left:0px;top:0px; aria-label:Specifies overview",width:this.model.width,height:this.model.height}),e.canvas.appendChild(i);var s=Bi("g",{id:this.element.id+"_overviewlayer",style:"pointer-events:none"});i.appendChild(s);var o=Bi("rect",{fill:"transparent",width:"100%",height:"100%",class:"overviewbackrect",id:this.canvas.id+"overviewbackrect"});o.setAttribute("style"," pointer-events: none; "),s.appendChild(o);var a=Bi("g",{id:this.canvas.id+"overviewhandle",style:"pointer-events:all"});s.appendChild(a);var l=Bi("rect",{id:this.canvas.id+"overviewrect",fill:"transparent"});a.appendChild(l),this.renderOverviewCorner("left",a),this.renderOverviewCorner("right",a),this.renderOverviewCorner("top",a),this.renderOverviewCorner("bottom",a),this.renderOverviewCorner("topleft",a),this.renderOverviewCorner("topright",a),this.renderOverviewCorner("bottomleft",a),this.renderOverviewCorner("bottomright",a)},t.prototype.renderOverviewCorner=function(e,i){var s,o=Bi(s="top"===e||"bottom"===e||"right"===e||"left"===e?"rect":"circle",{id:this.canvas.id+"visible"+e,class:"overview-resizer"});i.appendChild(o);var a=Bi(s,{id:this.canvas.id+e,class:"overviewresizer",fill:"transparent"});i.appendChild(a)},t.prototype.updateOverviewRectangle=function(){var e=this.currentPoint.x-this.prevPoint.x,i=this.currentPoint.y-this.prevPoint.y,r=new me;r.width=0,r.height=0;var s=0,o=0;switch(this.resizeDirection){case"left":r.width-=e,r.height-=e/this.viewPortRatio,s=e,o=e/this.viewPortRatio,o/=2;break;case"right":r.width+=e,r.height+=e/this.viewPortRatio,o=e/this.viewPortRatio,o/=-2;break;case"top":r.height-=i,r.width-=i*this.viewPortRatio,o=i,s=i*this.viewPortRatio,s/=2;break;case"bottom":r.height+=i,r.width+=i*this.viewPortRatio,s=i*this.viewPortRatio,s/=-2;break;case"topleft":Math.abs(i)>Math.abs(e)?e=i*this.viewPortRatio:i=e/this.viewPortRatio,r.width-=e,r.height-=i,s=e,o=i;break;case"topright":Math.abs(i)>Math.abs(e)?e=-i*this.viewPortRatio:i=-e/this.viewPortRatio,o=i,r.width+=e,r.height-=i;break;case"bottomleft":Math.abs(i)>Math.abs(e)?e=-i*this.viewPortRatio:i=-e/this.viewPortRatio,s=e,r.width-=e,r.height+=i;break;case"bottomright":Math.abs(i)>Math.abs(e)?e=i*this.viewPortRatio:i=e/this.viewPortRatio,r.width+=e,r.height+=i}this.updateHelper(s,o,r,void 0,void 0)},t.prototype.updateHelper=function(e,i,r,s,o){var a,l,h,u,p,d=this.element.getElementsByTagName("svg")[2].getElementById("helper");r?(a=(h=d.getBBox()).x+e,l=h.y+i,s=h.width+r.width,o=h.height+r.height):(u=this.currentPoint.x>this.startPoint.x?this.currentPoint.x-this.prevPoint.x:this.prevPoint.x-this.currentPoint.x,p=this.currentPoint.y>this.startPoint.y?this.currentPoint.y-this.prevPoint.y:this.prevPoint.y-this.currentPoint.y,Math.abs(p)>Math.abs(u)?u=this.viewPortRatio*p:p=u/this.viewPortRatio,h=d.getBBox(),a=this.startPoint.x>this.currentPoint.x?h.x-u:h.x,l=this.startPoint.y>this.currentPoint.y?h.y-p:h.y,s=h.width+u,o=h.height+p),oi(this.helper,{id:this.helper.id,x:a,y:l,width:Math.max(0,s),height:Math.max(0,o)})},t.prototype.updateOverviewrect=function(e,i,r,s){Ho(document.getElementById(this.canvas.id+"overviewrect"),{x:e,y:i,width:Math.max(1,r),height:Math.max(1,s)}),this.updateOverviewCorner("top",e+8,i+1,Math.max(0,r-16),2),this.updateOverviewCorner("bottom",e+8,i+s+3,Math.max(0,r-16),2),this.updateOverviewCorner("left",e-2,i+11,2,Math.max(0,s-16)),this.updateOverviewCorner("right",e+r,i+11,2,Math.max(0,s-16)),this.updateOverviewCorner("topleft",e,i+3,5,5),this.updateOverviewCorner("topright",e+r,i+3,5,5),this.updateOverviewCorner("bottomleft",e,i+s+3,5,5),this.updateOverviewCorner("bottomright",e+r,i+s+3,5,5)},t.prototype.updateOverviewCorner=function(e,i,r,s,o){var a,l;"top"===e||"bottom"===e||"right"===e||"left"===e?(a={x:i,y:r,width:s,height:o,fill:"#ED1C24"},l={x:i-2,y:r-2,width:2===s?4:s,height:2===o?4:o}):(a={cx:i,cy:r,r:4,fill:"#ED1C24"},l={cx:i,cy:r,r:6,fill:"transparent"}),Ho(document.getElementById(this.canvas.id+"visible"+e),a),Ho(document.getElementById(this.canvas.id+e),l)},t.prototype.translateOverviewRectangle=function(){Number(this.model.width),Number(this.model.height);var r=this.currentPoint.x-this.prevPoint.x,s=this.currentPoint.y-this.prevPoint.y,l=this.element.getElementsByClassName("overviewsvg")[0].getElementById(this.canvas.id+"overviewrect").getBBox(),h=l.x+r,c=l.y+s,d=l.width,u=l.height;this.updateOverviewrect(h,c,d,u),this.updateParentView(this.parent.scroller.currentZoom,h,c,d,u,null)},t.prototype.renderOverviewRect=function(e,i,r,s){var o=Number(this.model.width),a=Number(this.model.height),c=Math.max(this.parent.scroller.viewPortWidth/(r/o*this.contentWidth),this.parent.scroller.viewPortHeight/(s/a*this.contentHeight));if(c>=.25&&c<=30){this.updateParentView(c,e,i,r,s,{x:0,y:0});var u=this.scrollOverviewRect(this.parent.scroller.horizontalOffset,this.parent.scroller.verticalOffset,this.parent.scroller.currentZoom,!0);if(this.helper){var f=this.element.getElementsByTagName("rect")[10].getBBox();u.x=f.x,u.y=f.y}"pan"===this.actionName?this.updateOverviewrect(-u.x,-u.y,u.width,u.height):this.updateOverviewrect(u.x,u.y,u.width,u.height)}},t.prototype.scrollOverviewRect=function(e,i,r,s){if(!this.actionName||s){var o=Number(this.model.width),a=Number(this.model.height),l=Math.min(this.contentWidth/o,this.contentHeight/a),h=new Ne,c=h.x=e/r/l,d=h.y=i/r/l,u=0;this.parent.rulerSettings.showRulers&&(u=25);var p=document.getElementById(this.parent.element.id+"content"),f=0,g=0;p&&(f=p.offsetWidth-p.clientWidth,g=p.offsetHeight-p.clientHeight);var v=h.width=(this.parent.scroller.viewPortWidth-u-f)/r/l,y=h.height=(this.parent.scroller.viewPortHeight-u-g)/r/l;if(s){var S=new Ne;return S.x=c,S.y=d,S.width=v,S.height=y,S}this.updateOverviewrect(-c,-d,v,y)}return null},t.prototype.updateParentView=function(e,i,r,s,o,a){var f,g,l=Number(this.model.width),h=Number(this.model.height),u=i*(this.contentWidth/l)*e,p=r*(this.contentHeight/h)*e;this.parent.scroller.getPageBounds(),(1!==e||"pan"===this.actionName)&&(f=-u-this.parent.scroller.horizontalOffset,g=-p-this.parent.scroller.verticalOffset),this.parent.setBlazorDiagramProps(!0),this.parent.realActions|=$i.OverViewAction,"scale"===this.actionName||"draw"===this.actionName?this.parent.scroller.zoom(e/this.parent.scroller.currentZoom,f,g,a):ce()?this.parent.scroller.zoom(1,f,g,a):this.parent.pan(f,g,a,!0)},t.prototype.updateHtmlLayer=function(e){var i=Io(e.element.id),r=this.parent.scroller.getPageBounds(!0),o=r.height,a=Math.max(r.width,this.parent.scroller.viewPortWidth),l=Math.max(o,this.parent.scroller.viewPortHeight/this.parent.scroller.currentZoom),h=Math.min(Number(this.model.width)/a,Number(this.model.height)/l);i.style.transform="scale("+h+") translate("+this.parent.scroller.transform.tx+"px,"+this.parent.scroller.transform.ty+"px)"},t.prototype.updateView=function(e){var i=this.parent.scroller.getPageBounds(),r=i.width,s=i.height,o=Number(this.model.width),a=Number(this.model.height),l=Math.max(r,this.parent.scroller.viewPortWidth),h=Math.max(s,this.parent.scroller.viewPortHeight);this.contentWidth=l=Math.max(l,o/a*h),this.contentHeight=h=Math.max(h,a/o*l);var c=Math.min(o/l,a/h),d=document.getElementById(this.element.id+"_htmlLayer");d.style.webkitTransform="scale("+c+") translate("+-i.x+"px,"+-i.y+"px)",d.style.transform="scale("+c+") translate("+-i.x+"px,"+-i.y+"px)",document.getElementById(this.element.id+"_overviewlayer").setAttribute("transform","translate("+-i.x*c+","+-i.y*c+")"),this.horizontalOffset=i.x*c,this.verticalOffset=i.y*c;var p=document.getElementById(this.element.id+"_diagramLayer"),f=UF(this.element.id),g=p.getContext("2d"),v=Number(this.model.width)/this.contentWidth,y=Number(this.model.height)/this.contentHeight;v=Math.min(v,y);var S=this.parent.scroller.transform;f.setAttribute("transform","translate("+S.tx*v+","+S.ty*y+"),scale("+v+")"),g.setTransform(v,0,0,v,0,0),g.fillStyle="red",this.scrollOverviewRect(this.parent.scroller.horizontalOffset,this.parent.scroller.verticalOffset,this.parent.scroller.currentZoom)},t.prototype.scrolled=function(e){if(this.event){var i=this.scrollOverviewRect(this.parent.scroller.horizontalOffset,this.parent.scroller.verticalOffset,this.parent.scroller.currentZoom,!0);this.updateOverviewrect(-i.x,-i.y,i.width,i.height),this.updateView(this)}},t.prototype.updateCursor=function(e){if(pm(e.target,"overviewresizer"))switch(e.target.id){case this.canvas.id+"left":this.canvas.style.cursor="w-resize";break;case this.canvas.id+"right":this.canvas.style.cursor="e-resize";break;case this.canvas.id+"top":this.canvas.style.cursor="n-resize";break;case this.canvas.id+"bottom":this.canvas.style.cursor="s-resize";break;case this.canvas.id+"topleft":this.canvas.style.cursor="nw-resize";break;case this.canvas.id+"topright":this.canvas.style.cursor="ne-resize";break;case this.canvas.id+"bottomleft":this.canvas.style.cursor="sw-resize";break;case this.canvas.id+"bottomright":this.canvas.style.cursor="se-resize"}else this.canvas.style.cursor="default"},t.prototype.mouseMove=function(e){if(this.event=!1,this.updateCursor(e),this.currentPoint=this.mousePosition(e),this.actionName)switch(this.actionName){case"draw":!this.inAction&&(this.startPoint.x!==this.currentPoint.x||this.startPoint.y!==this.currentPoint.y)&&(this.initHelper(),this.inAction=!0),this.inAction&&this.updateHelper();break;case"scale":this.inAction||(this.initHelper(),this.inAction=!0),this.updateOverviewRectangle();break;case"pan":(this.startPoint.x!==this.currentPoint.x||this.startPoint.y===this.currentPoint.y||this.inAction)&&(this.inAction=!0,this.translateOverviewRectangle())}this.prevPoint=this.currentPoint},t.prototype.documentMouseUp=function(e){this.inAction=!1,this.actionName="",this.helper&&(this.helper.parentNode.removeChild(this.helper),this.helper=null),this.event=!0,document.getElementById(this.canvas.id+"overviewhandle").style.pointerEvents="all"},t.prototype.windowResize=function(e){var i=this;return this.resizeTo&&clearTimeout(this.resizeTo),this.resizeTo=setTimeout(function(){var s=document.getElementById(i.element.id).getBoundingClientRect();i.model.width=s.width>0?s.width:i.model.width,i.model.height=s.height>0?s.height:i.model.height,i.renderCanvas(),i.setParent(i.sourceID)},10),!1},t.prototype.mouseDown=function(e){if(e.target.id===this.canvas.id+"_overviewsvg"&&(this.actionName="draw"),e.target.id===this.canvas.id+"overviewrect"&&(this.actionName="pan"),pm(e.target,"overviewresizer"))switch(this.actionName="scale",e.target.id){case this.canvas.id+"left":this.resizeDirection="left";break;case this.canvas.id+"right":this.resizeDirection="right";break;case this.canvas.id+"top":this.resizeDirection="top";break;case this.canvas.id+"bottom":this.resizeDirection="bottom";break;case this.canvas.id+"topleft":this.resizeDirection="topleft";break;case this.canvas.id+"topright":this.resizeDirection="topright";break;case this.canvas.id+"bottomleft":this.resizeDirection="bottomleft";break;case this.canvas.id+"bottomright":this.resizeDirection="bottomright"}this.startPoint=this.prevPoint=this.mousePosition(e),this.viewPortRatio=this.parent.scroller.viewPortWidth/this.parent.scroller.viewPortHeight,document.getElementById(this.canvas.id+"overviewhandle").style.pointerEvents="none"},t.prototype.mouseUp=function(e){if(this.currentPoint=this.mousePosition(e),this.actionName)if(this.startPoint.x!==this.currentPoint.x||this.startPoint.y!==this.currentPoint.y){if("pan"!==this.actionName&&this.helper){var i=this.element.getElementsByTagName("rect")[10].getBBox();this.resizeDirection=this.resizeDirection||"",this.renderOverviewRect(i.x,i.y,o=i.width,a=i.height)}}else if(e.target.id===this.canvas.id+"_overviewsvg"||"helper"===e.target.id){var o=(i=this.element.getElementsByTagName("svg")[2].getElementById(this.canvas.id+"overviewrect").getBBox()).width,a=i.height;this.inAction=!0,this.actionName="pan",this.renderOverviewRect(this.currentPoint.x-o/2,this.currentPoint.y-a/2,o,a),this.inAction=!1}this.helper&&(this.helper.parentNode.removeChild(this.helper),this.helper=null),this.actionName="",this.startPoint=null,this.currentPoint=null,this.prevPoint=null,this.helper=null,this.viewPortRatio=1,this.resizeDirection="",this.inAction=!1,this.event=!0,document.getElementById(this.canvas.id+"overviewhandle").style.pointerEvents="all"},t.prototype.initHelper=function(){var e=this.element.getElementsByTagName("svg")[2],i=this.startPoint.x,r=this.startPoint.y,s=1,o=1;if("scale"===this.actionName){var l=e.getElementById(this.canvas.id+"overviewrect").getBBox();i=l.x,r=l.y,s=l.width,o=l.height}var h=Bi("rect",{id:"helper",x:i,y:r,width:s,height:o,fill:"transparent",stroke:"gray","stroke-dasharray":"2 2","shape-rendering":"crispEdges"});e.getElementById(this.element.id+"_overviewlayer").appendChild(h),this.helper=h},t.prototype.mousePosition=function(e){var i,r,s;-1!==e.type.indexOf("touch")?(r=(i=e).changedTouches[0].clientX-this.element.offsetLeft,s=i.changedTouches[0].clientY-this.element.offsetTop):(r=e.clientX,s=e.clientY);var l=this.element.getBoundingClientRect();return{x:(r-=l.left)+this.horizontalOffset,y:(s-=l.top)+this.verticalOffset}},t.prototype.destroy=function(){if(this.unWireEvents(),this.notify("destroy",{}),n.prototype.destroy.call(this),document.getElementById(this.element.id)){this.element.classList.remove("e-overview");var e=document.getElementById(this.element.id+"_canvas");e&&this.element.removeChild(e)}this.parent.views.splice(this.parent.views.indexOf(this.element.id),1),this.diagramLayerDiv=null,this.canvas=null,this.parent=null},t.prototype.getModuleName=function(){return"Overview"},tb([I("100%")],t.prototype,"width",void 0),tb([I("100%")],t.prototype,"height",void 0),tb([I("")],t.prototype,"sourceID",void 0),tb([H()],t.prototype,"created",void 0),t}(yi);function fse(n,t){for(var e=0;ez.findLength(e,n)?e:t;var o=z.findAngle(t,e),a=z.findAngle(i,n),l=z.findLength(i,n),h=a+2*(o-a);return{x:i.x+l*Math.cos(h*Math.PI/180),y:i.y+l*Math.sin(h*Math.PI/180)}}function Kp(n,t,e){if(n&&n.children&&n.children.length>0)for(var r=void 0,s=0;s0&&"annotations"!==r&&"ports"!==r)if(n[""+l].length>0)for(var h=0;h<=n[""+l].length;h++)Ro(n[""+l],t?t[""+l]:void 0,e[""+l],"annotations"===l||"ports"===l?n:void 0,l);else Ro(n[""+l],t?t[""+l]:void 0,e[""+l],"annotations"===l||"ports"===l?n:void 0,l);else if(s instanceof Object&&t&&"annotations"!==r&&"ports"!==r)Ro(n[""+l],t[""+l],e[""+l]);else if("annotations"!==r&&"ports"!==r&&t&&!t[""+l]||!t&&n&&(n[""+l]||void 0!==n[""+l]))n[""+l]=e[""+l];else{var c=void 0;("annotations"===r||"ports"===r)&&("annotations"===r?(n[""+l]&&Ro(n[""+l],t[""+l],e[""+l]),n[""+l]||(fs(i)===de?(c=new Nr(i,"annotations",e[""+l]),i.annotations.push(c)):(c=new Zn(i,"annotations",e[""+l]),i.annotations.push(c)))):n[""+l]?Ro(n[""+l],t[""+l],e[""+l]):(c=new Es(i,"ports",e[""+l]),i.ports.push(c)))}}}function bse(n,t){for(var e="Bezier"===n.type?function yse(n){var t=[];if("Bezier"===n.type)for(var e=0,i=0;i0||n.ports.length>0){var p=n.wrapper.children;for(i=3;i0)return{enabled:!1,intersectPt:e};var l=o/s,h=a/s;return l>=0&&l<=1&&h>=0&&h<=1?(e.x=i.x1+l*(i.x2-i.x1),e.y=i.y1+l*(i.y2-i.y1),{enabled:!0,intersectPt:e}):{enabled:!1,intersectPt:e}}function rb(n,t,e,i){var a=im(vF(n.x,n.y,t.x,t.y),vF(e.x,e.y,i.x,i.y));return a.enabled?a.intersectPt:{x:0,y:0}}function vF(n,t,e,i){return{x1:Number(n)||0,y1:Number(t)||0,x2:Number(e)||0,y2:Number(i)||0}}function mF(n,t,e){var i=[],s={x:t.topRight.x+(e=e||0),y:t.topRight.y},o={x:t.bottomRight.x,y:t.bottomRight.y-e},a={x:t.bottomLeft.x,y:t.bottomLeft.y+e};return i.push({x:t.topLeft.x-e,y:t.topLeft.y}),i.push(s),i.push(o),i.push(a),i}function zc(n,t,e,i,r,s){var o={},a=e.scroller.transform.scale,h=e.scroller.verticalOffset;return o.x=(i?n.x:t.x)*a+e.scroller.horizontalOffset-r,o.y=(i?n.y:t.y)*a+h-s,o}function yF(n,t){var e=new Ke;return e.data=n.pathData,e.height=n.height>10?n.height-(n.padding.bottom+n.padding.top):n.height,e.width=n.width>10?n.width-(n.padding.left+n.padding.right):n.width,e.visible=n.visibility,e.id=t.id+"_shape",e.inversedAlignment=!1,e.horizontalAlignment="Center",e.verticalAlignment="Center",e.style={fill:n.iconStrokeColor,strokeColor:n.iconStrokeColor,strokeWidth:n.iconStrokeWidth},e.setOffsetWithRespectToBounds(.5,.5,"Fraction"),e.relativeMode="Object",e.description=t.description||"",e}function Zx(n,t,e){var i=Jx(n,t),r=z.findAngle(n[i.index],n[i.index+1]),s=function Tse(n){var t;t=n instanceof LI?0:void 0===n.content?10:0;var e=0;switch(n.alignment){case"Center":e=0;break;case"Before":e=-(0+t);break;case"After":e=0+t}return e}(t),o=z.transform(i.point,r+45,s);return i.point=o,i.angle=r,i}function Jx(n,t){for(var r,s,a,l,e=0,i=t.offset,o=[],h=0;h=c)return s=z.findAngle(n[parseInt(d.toString(),10)],n[d+1]),{point:r=z.transform(n[parseInt(d.toString(),10)],s,c-(a||0)),index:l=d};a=o[parseInt(d.toString(),10)]}return{point:r,index:l}}function SF(n,t,e){t%=360;var a,l,s=225;switch(n.alignment){case"Before":t>=45&&t<=135?(l="right",a=.5===n.offset?"center":"top"):t>=s&&t<=315?(l="left",a=.5===n.offset?"center":"bottom"):t>45&&t=45&&t<=135?(l="left",a=.5===n.offset?"center":"top"):t>=s&&t<=315?(l="right",a=.5===n.offset?"center":"bottom"):t>45&&tMath.abs(t.y-n.y)?n.x0)for(var e=0;e=0;r--)("nodes"===i||"connectors"===i)&&(n[""+i][parseInt(r.toString(),10)].wrapper=null),"dataManager"!==i&&(n[""+i][parseInt(r.toString(),10)]=tT(n[""+i][parseInt(r.toString(),10)],e[""+i][parseInt(r.toString(),10)],void 0!==t[""+i]?t[""+i][parseInt(r.toString(),10)]:[]),("[]"===JSON.stringify(n[""+i][parseInt(r.toString(),10)])||"{}"===JSON.stringify(n[""+i][parseInt(r.toString(),10)])||void 0===n[""+i][parseInt(r.toString(),10)])&&n[""+i].splice(r,1));n=void 0}function Rh(n,t){var e=t.style,i=t;t.canApplyStyle=!0;for(var r=0,s=Object.keys(n);r=0&&n.splice(e,1)}function ef(n,t,e){var i;n.intermediatePoints=t,n.updateSegmentElement(n,t,n.wrapper.children[0],e);var r=n.sourceDecorator;if("Bezier"===n.type){var s=n.segments[0],o=n.segments[n.segments.length-1];i=[z.isEmptyPoint(o.point2)?o.bezierPoint2:o.point2,z.isEmptyPoint(s.point1)?s.bezierPoint1:s.point1]}else i=n.intermediatePoints;t=n.clipDecorators(n,t,e);var a=n.wrapper.children[0];a.canMeasurePath=!0,n.updateDecoratorElement(a=n.wrapper.children[1],t[0],i[1],r),n.updateDecoratorElement(a=n.wrapper.children[2],t[t.length-1],i[i.length-2],n.targetDecorator),n.updateShapeElement(n)}function iT(n,t,e){var l,i=n.wrapper,s=t.offset,o=t.size/e.scale,a=t.margin,h=i.offsetX-i.actualSize.width*i.pivot.x,c=i.offsetY-i.actualSize.height*i.pivot.y;if(l={x:0,y:0},n.nodes.length>0){switch(t.side){case"Top":l.x+=h+s*i.actualSize.width,l.y+=c-o;break;case"Bottom":l.x+=h+s*i.actualSize.width,l.y+=c+i.actualSize.height+o;break;case"Left":l.x+=h-o,l.y+=c+s*i.actualSize.height;break;case"Right":l.x+=h+i.actualSize.width+o,l.y+=c+s*i.actualSize.height}l.x+=(a.left-a.right)/e.scale+o/2*("Center"===t.horizontalAlignment?0:"Right"===t.horizontalAlignment?-1:1),l.y+=(a.top-a.bottom)/e.scale+o/2*("Center"===t.verticalAlignment?0:"Top"===t.verticalAlignment?-1:1)}else if(n.connectors.length>0){var d=n.connectors[0],u={offset:s},p=Jx(d.intermediatePoints,u),f=p.index;l=p.point;var y,v=Zx(d.intermediatePoints,u).angle;qi(y=Hi(),-v,d.intermediatePoints[parseInt(f.toString(),10)].x,d.intermediatePoints[parseInt(f.toString(),10)].y),(l=Je(y,l)).x+=a.left-a.right+o/2*("Center"===t.horizontalAlignment?0:"Right"===t.horizontalAlignment?-1:1),l.y+=a.top-a.bottom+o/2*("Center"===t.verticalAlignment?0:"Top"===t.verticalAlignment?-1:1),qi(y=Hi(),v,d.intermediatePoints[parseInt(f.toString(),10)].x,d.intermediatePoints[parseInt(f.toString(),10)].y),l=Je(y,l)}return 0===i.rotateAngle&&0===i.parentTransform||(qi(y=Hi(),i.rotateAngle+i.parentTransform,i.offsetX,i.offsetY),l=Je(y,l)),l}function fa(n,t,e,i){if(i.annotation){if(kl(i.annotation))return!0}else if(mr[""+t]&n&&bt[""+t]&e)return!0;return!1}function qr(n,t){return!!(mr[""+t]&n)}function Hc(n,t){return!!(Cx[""+t]&n)}function ga(n,t){return n.visibility&t}function nb(n,t){var e;if("Text"===n.shape.type)e=n.shape;else{var i=t.split("_");t=i[i.length-1];for(var r=0;rn[""+t]?e.splice(0,0,n):e.push(n);else if(e.length>1){for(var i=0,r=e.length-1,s=Math.floor((i+r)/2);s!==i;)if(e[parseInt(s.toString(),10)][""+t]n[""+t]))break;r=s,s=Math.floor((i+r)/2)}e[parseInt(r.toString(),10)][""+t]n[""+t]?e.splice(i,0,n):e[parseInt(i.toString(),10)][""+t]n[""+t]&&e.splice(r,0,n)}}function Qse(n){var t=document.getElementById(n.diagramId),e="ej2_instances",i=t[""+e][0].nodes;void 0===i&&(i=function Gse(n){for(var t=[],e=0;e30?10:o/2;for(var h=0,c=0;c=l){var u=l-h;r=Gt(n[c],n[c+1]),s=z.transform(n[c],r,u);break}h+=d}return s},ab=function(n,t){if(n instanceof te||n instanceof de)for(var e=0;e=0||navigator.platform.indexOf("iPad")>=0||navigator.platform.indexOf("iPhone")>=0||navigator.platform.indexOf("MacIntel")>=0)&&("safari"===X.info.name||"webkit"===X.info.name)}function AF(n,t,e,i){return void 0!==t.previewSize[""+i]?t.previewSize[""+i]:void 0!==n.symbolPreview[""+i]?n.symbolPreview[""+i]:t[""+i]||e.actualSize[""+i]}function am(n,t,e){return n&&n.parentId&&(e=(n=t.nameTable[n.parentId]).parentId?am(n,t,e):n.id),e}function lm(n,t){return n.selectedItems.connectors.length>1&&0===n.selectedItems.nodes.length&&0!==t.rotateAngle}function Zse(n){if(n.arrowType&&""!==n.arrowType.trim())switch(n.arrowType){case"single-line-arrow":default:return{targetDecorator:"Arrow",strokeWidth:1};case"double-line-arrow":return{targetDecorator:"Arrow",strokeWidth:2};case"dotted-arrow":return{targetDecorator:"Arrow",strokeDashArray:"2,2"};case"single-line":return{targetDecorator:"None",strokeWidth:1};case"double-line":return{targetDecorator:"None",strokeWidth:2};case"dotted":return{targetDecorator:"None",strokeDashArray:"2,2"};case"wiggly-arrow":return{targetDecorator:"None",strokeWidth:1,opacity:0}}return{targetDecorator:"Arrow",strokeWidth:1}}var Jse=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),io=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},LF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Jse(t,n),io([I("None")],t.prototype,"shape",void 0),io([I("white")],t.prototype,"fill",void 0),io([I("Auto")],t.prototype,"horizontalAlignment",void 0),io([I("Auto")],t.prototype,"verticalAlignment",void 0),io([I(10)],t.prototype,"width",void 0),io([I(10)],t.prototype,"height",void 0),io([re({x:.5,y:1},z)],t.prototype,"offset",void 0),io([I("#1a1a1a")],t.prototype,"borderColor",void 0),io([I(1)],t.prototype,"borderWidth",void 0),io([re({},$n)],t.prototype,"margin",void 0),io([I("")],t.prototype,"pathData",void 0),io([I("")],t.prototype,"content",void 0),io([I(0)],t.prototype,"cornerRadius",void 0),io([re({left:2,right:2,top:2,bottom:2},$n)],t.prototype,"padding",void 0),io([I("#1a1a1a")],t.prototype,"iconColor",void 0),t}(Ee),Kse=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),oT=function(n){function t(){var e=null!==n&&n.apply(this,arguments)||this;return e.orientation="Vertical",e.measureChildren=void 0,e.considerPadding=!0,e}return Kse(t,n),t.prototype.measure=function(e){return this.desiredSize=this.measureStackPanel(e,"Horizontal"===this.orientation?this.updateHorizontalStack:this.updateVerticalStack),this.desiredSize},t.prototype.arrange=function(e){return this.actualSize=this.arrangeStackPanel(e,"Horizontal"===this.orientation?this.arrangeHorizontalStack:this.arrangeVerticalStack),this.updateBounds(),this.actualSize},t.prototype.measureStackPanel=function(e,i){var r=void 0;if(void 0!==this.children&&this.children.length>0)for(var s=0,o=this.children;s0){var r=void 0,s=void 0;r=this.offsetX-e.width*this.pivot.x+this.padding.left,s=this.offsetY-e.height*this.pivot.y+this.padding.top;for(var o=0,a=this.children;o0)for(var i=0,r=this.children;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},aoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return ooe(t,n),Hh([I("Horizontal")],t.prototype,"orientation",void 0),Hh([I("Center")],t.prototype,"type",void 0),Hh([I(void 0)],t.prototype,"offset",void 0),Hh([I(!1)],t.prototype,"enableRouting",void 0),Hh([I([])],t.prototype,"children",void 0),Hh([I("")],t.prototype,"assistants",void 0),Hh([I("")],t.prototype,"level",void 0),Hh([I("")],t.prototype,"hasSubTree",void 0),Hh([I("")],t.prototype,"rows",void 0),t}(Ee),Li=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),q=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},loe=function(n){if(n)switch(n.type){case"Basic":default:return lb;case"Flow":return PF;case"Path":return NF;case"Image":return kF;case"Text":return Rd;case"Bpmn":return uT;case"Native":return hm;case"HTML":return OF;case"UmlActivity":return zF;case"UmlClassifier":return RF;case"SwimLane":return Fd}return lb},va=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),q([I("Basic")],t.prototype,"type",void 0),t}(Ee),NF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"Path"},q([I("Path")],t.prototype,"type",void 0),q([I("")],t.prototype,"data",void 0),t}(va),hm=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"Native"},q([I("Native")],t.prototype,"type",void 0),q([I("")],t.prototype,"content",void 0),q([I("Stretch")],t.prototype,"scale",void 0),t}(va),OF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"Html"},q([I("HTML")],t.prototype,"type",void 0),q([I("")],t.prototype,"content",void 0),t}(va),kF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"Image"},q([I("Image")],t.prototype,"type",void 0),q([I("")],t.prototype,"source",void 0),q([I("None")],t.prototype,"scale",void 0),q([I("None")],t.prototype,"align",void 0),t}(va),Rd=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"Text"},q([I("Text")],t.prototype,"type",void 0),q([I("")],t.prototype,"content",void 0),q([re({},$n)],t.prototype,"margin",void 0),t}(va),lb=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"BasicShape"},q([I("Basic")],t.prototype,"type",void 0),q([I("Rectangle")],t.prototype,"shape",void 0),q([I(0)],t.prototype,"cornerRadius",void 0),q([Bt([],z)],t.prototype,"points",void 0),t}(va),PF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"FlowShape"},q([I("Flow")],t.prototype,"type",void 0),q([I("Terminator")],t.prototype,"shape",void 0),t}(va),lT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"BpmnGateway"},q([I("None")],t.prototype,"type",void 0),t}(Ee),hT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"BpmnDataObject"},q([I("None")],t.prototype,"type",void 0),q([I(!1)],t.prototype,"collection",void 0),t}(Ee),hoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),q([I("None")],t.prototype,"type",void 0),q([I("None")],t.prototype,"loop",void 0),q([I(!1)],t.prototype,"call",void 0),q([I(!1)],t.prototype,"compensation",void 0),t}(Ee),cT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"BpmnEvent"},q([I("Start")],t.prototype,"event",void 0),q([I("None")],t.prototype,"trigger",void 0),t}(Ee),Hd=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"BpmnSubEvent"},q([I("None")],t.prototype,"trigger",void 0),q([I("Start")],t.prototype,"event",void 0),q([I("")],t.prototype,"id",void 0),q([re({},z)],t.prototype,"offset",void 0),q([Bt([],Zn)],t.prototype,"annotations",void 0),q([Bt([],Es)],t.prototype,"ports",void 0),q([I()],t.prototype,"width",void 0),q([I()],t.prototype,"height",void 0),q([re({},$n)],t.prototype,"margin",void 0),q([I("Center")],t.prototype,"horizontalAlignment",void 0),q([I("Center")],t.prototype,"verticalAlignment",void 0),q([I(!0)],t.prototype,"visible",void 0),t}(Ee),coe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),q([re({id:"success",event:"End",offset:{x:1,y:.5}},Hd)],t.prototype,"success",void 0),q([re({id:"failure",event:"Intermediate",trigger:"Error",offset:{x:.25,y:1}},Hd)],t.prototype,"failure",void 0),q([re({id:"cancel",event:"Intermediate",trigger:"Cancel",offset:{x:.75,y:1}},Hd)],t.prototype,"cancel",void 0),t}(Ee),doe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),q([I("None")],t.prototype,"type",void 0),q([I(!1)],t.prototype,"adhoc",void 0),q([I("Default")],t.prototype,"boundary",void 0),q([I(!1)],t.prototype,"compensation",void 0),q([I("None")],t.prototype,"loop",void 0),q([I(!0)],t.prototype,"collapsed",void 0),q([Bt([],Hd)],t.prototype,"events",void 0),q([re({},coe)],t.prototype,"transaction",void 0),q([I(void 0)],t.prototype,"processes",void 0),t}(Ee),dT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"BpmnActivity"},q([I("Task")],t.prototype,"activity",void 0),q([re({},hoe)],t.prototype,"task",void 0),q([re({},doe)],t.prototype,"subProcess",void 0),t}(Ee),cm=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return Li(t,n),t.prototype.getClassName=function(){return"BpmnAnnotation"},q([I("")],t.prototype,"text",void 0),q([I("")],t.prototype,"id",void 0),q([I(0)],t.prototype,"angle",void 0),q([I()],t.prototype,"height",void 0),q([I()],t.prototype,"width",void 0),q([I(0)],t.prototype,"length",void 0),t}(Ee),uoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),q([I("")],t.prototype,"textAnnotationTarget",void 0),q([I("Auto")],t.prototype,"textAnnotationDirection",void 0),t}(Ee),uT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"BpmnShape"},q([I("Bpmn")],t.prototype,"type",void 0),q([I("Event")],t.prototype,"shape",void 0),q([re({},cT)],t.prototype,"event",void 0),q([re({},lT)],t.prototype,"gateway",void 0),q([re({},hT)],t.prototype,"dataObject",void 0),q([re({},dT)],t.prototype,"activity",void 0),q([re({},cm)],t.prototype,"annotation",void 0),q([Bt([],cm)],t.prototype,"annotations",void 0),q([re({},uoe)],t.prototype,"textAnnotation",void 0),t}(va),zF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"UmlActivityShape"},q([I("UmlActivity")],t.prototype,"type",void 0),q([I("Action")],t.prototype,"shape",void 0),t}(va),pT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"MethodArguments"},q([I("")],t.prototype,"name",void 0),q([I("")],t.prototype,"type",void 0),q([re({},Xp)],t.prototype,"style",void 0),t}(Ee),of=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"UmlClassAttribute"},q([I("Public")],t.prototype,"scope",void 0),q([I(!1)],t.prototype,"isSeparator",void 0),q([re({fill:"#F9F9F9",strokeColor:"#CCCCCC"},Ll)],t.prototype,"separatorStyle",void 0),t}(pT),dm=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"UmlClassMethod"},q([Bt([],pT)],t.prototype,"parameters",void 0),t}(of),hb=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"UmlClass"},q([I("")],t.prototype,"name",void 0),q([Bt([],of)],t.prototype,"attributes",void 0),q([Bt([],dm)],t.prototype,"methods",void 0),q([re({},Xp)],t.prototype,"style",void 0),t}(Ee),fT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"UmlInterface"},q([I(!1)],t.prototype,"isSeparator",void 0),q([re({fill:"#F9F9F9",strokeColor:"#CCCCCC"},Ll)],t.prototype,"separatorStyle",void 0),t}(hb),cb=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"UmlEnumerationMember"},q([I("")],t.prototype,"name",void 0),q([I("")],t.prototype,"value",void 0),q([I(!1)],t.prototype,"isSeparator",void 0),q([re({fill:"#F9F9F9",strokeColor:"#CCCCCC"},Ll)],t.prototype,"separatorStyle",void 0),q([re({},Xp)],t.prototype,"style",void 0),t}(Ee),gT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"UmlEnumeration"},q([I("")],t.prototype,"name",void 0),q([Bt([],cb)],t.prototype,"members",void 0),q([re({},Xp)],t.prototype,"style",void 0),t}(Ee),RF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"UmlClassifierShape"},q([I("UmlClassifier")],t.prototype,"type",void 0),q([re({},hb)],t.prototype,"classShape",void 0),q([re({},fT)],t.prototype,"interfaceShape",void 0),q([re({},gT)],t.prototype,"enumerationShape",void 0),q([I("Class")],t.prototype,"classifier",void 0),t}(va),te=function(n){function t(e,i,r,s){var a,o=n.call(this,e,i,r,s)||this;return o.isCanvasUpdate=!1,o.status="None",o.parentId="",o.processId="",o.umlIndex=-1,o.outEdges=[],o.inEdges=[],o.isHeader=!1,o.isLane=!1,o.isPhase=!1,o.children&&o.children.length>0&&((!(a=r).style||!a.style.fill)&&(o.style.fill="transparent"),(!a.style||!a.style.strokeColor)&&(o.style.strokeColor="transparent")),o.shape&&"UmlActivity"===o.shape.type&&ib(r,o),o.shape&&"SwimLane"===o.shape.type&&pF(r,o),o.ports&&o.ports.length&&function vse(n){for(var t=0;t>";t=n;break;case"FinalNode":t=IF(e)}return t}(new Ke,i,this);break;case"Bpmn":if(e.bpmnModule){i=e.bpmnModule.initBPMNContent(i,this,e),this.wrapper.elementActions=this.wrapper.elementActions|Xr.ElementIsGroup;var v=this.shape.activity.subProcess;if(v.processes&&v.processes.length)for(var S=0,b=this.shape.activity.subProcess.processes;S>",margin:{left:10,right:10},id:"class",style:{fontSize:i.style.fontSize,color:i.style.color,fill:i.style.fill,textWrapping:r},offset:{x:.5,y:.3},constraints:Lr.ReadOnly}],constraints:(ie.Default|ie.HideThumbs)&~(ie.Rotate|ie.Drag|ie.Resize),verticalAlignment:"Stretch",horizontalAlignment:"Stretch",style:{fill:t.style.fill,strokeColor:"black"===t.style.strokeColor?"#ffffff00":t.style.strokeColor}},!0);return e.initObject(s),e.nodes.push(s),e.UpdateBlazorDiagramModel(s,"Node"),t.children.push(s.id),function toe(n,t,e,i){if("Enumeration"===n.shape.classifier){var r=e.members;if(r&&r.length){nf(n,t);for(var s="",o=0;o0)for(var o=0;o0&&s.phaseSize&&(i+=s.phaseSize,qv(n,s.phaseSize)),s.lanes.length>0)for(o=0;o0){var a=0;for(o=0;o0&&"Horizontal"===r.orientation)for(l=0;l0&&(i+=r.phaseSize,o=$v(r.phaseSize),n.push(o)),a=0;a0&&o.phaseSize){for(var l=0;l0)for(l=0;l0?e.nameTable[this.nodes[0].id].wrapper:e.nameTable[this.connectors[0].id].wrapper,this.annotation.id);i.children.push(s)}else if(this.nodes||this.connectors){for(var o=0;o-1}function VF(n,t,e){n=[];for(var i=0,r=e.length;i0?c.getElementsByTagName("svg")[0].outerHTML:c.getElementsByTagName("g").length>0?c.getElementsByTagName("g")[0].outerHTML:"",s.shape.content=h,n.content=h,c.parentElement.removeChild(c)}l="nodeTemplate"}else a=s,l="annotationTemplate";var f=document.getElementById(n.diagramId).ej2_instances[0];if("string"!=typeof n.content&&"function"!=typeof n.content||n.isTemplate)if(n.isTemplate){if(v=void 0,v=f.isReact?n.getNodeTemplate()($(e),f,l+"_"+("nodeTemplate"===l?e.id:n.nodeId+e.id),void 0,void 0,!1,i):f.isVue||f.isVue3?n.getNodeTemplate()?n.getNodeTemplate()($(e),f,l+"_"+("nodeTemplate"===l?e.id:n.nodeId+e.id),void 0,void 0,!1,i):(v=ii("nodeTemplate"===l?f.nodeTemplate:f.annotationTemplate))($(e),f,l+"_"+("nodeTemplate"===l?e.id:n.nodeId+e.id),void 0,void 0,!1,i):n.getNodeTemplate()($(e),f,l+"_"+("nodeTemplate"===l?e.id:n.nodeId+e.id),void 0,void 0,!1))for(var M=0;M=1&&0===n.x&&("Clip"===i.textOverflow||"Ellipsis"===i.textOverflow)&&("Wrap"===i.textWrapping||"WrapWithOverflow"===i.textWrapping)&&(n.x=t[e-1]?t[e-1].x:-n.width/2),n.x}function QF(n,t,e,i){return e&&!t.template||t.template&&"function"==typeof t.template&&i.isReact?(n.isTemplate=!0,n.template=n.content=Bh(n,!0,t)):n.content=t.template,n}function Qe(){for(var e,t="",i=0;i<5;i++){if(typeof window<"u"&&"crypto"in window&&"getRandomValues"in crypto){var r=new Uint16Array(1);e=(window.msCrypto||window.crypto).getRandomValues(r)[0]%60}else e=Math.floor(61*Math.random());0===i&&e<10?i--:t+="0123456789ABCDEFGHIJKLMNOPQRSTUVWXTZabcdefghiklmnopqrstuvwxyz".substring(e,e+1)}return t}function GF(n){if(n)try{return"function"!=typeof n&&document.querySelectorAll(n).length?ii(document.querySelector(n).innerHTML.trim()):ii(n)}catch{return ii(n)}}function En(n){new Ne;var e=n.offsetY-n.actualSize.height*n.pivot.y,i=n.offsetY+n.actualSize.height*(1-n.pivot.y),r=n.offsetX-n.actualSize.width*n.pivot.x,s=n.offsetX+n.actualSize.width*(1-n.pivot.x);return Ne.toBounds([{x:r,y:e},{x:s,y:e},{x:r,y:i},{x:s,y:i}])}function yr(n){var t=new Ne,e=En(n),i=e.middleLeft,r=e.topCenter,s=e.bottomCenter,o=e.middleRight,a=e.topLeft,l=e.topRight,h=e.bottomLeft,c=e.bottomRight;if(n.corners={topLeft:a,topCenter:r,topRight:l,middleLeft:i,middleRight:o,bottomLeft:h,bottomCenter:s,bottomRight:c},0!==n.rotateAngle||0!==n.parentTransform){var d=Hi();qi(d,n.rotateAngle+n.parentTransform,n.offsetX,n.offsetY),n.corners.topLeft=a=Je(d,a),n.corners.topCenter=r=Je(d,r),n.corners.topRight=l=Je(d,l),n.corners.middleLeft=i=Je(d,i),n.corners.middleRight=o=Je(d,o),n.corners.bottomLeft=h=Je(d,h),n.corners.bottomCenter=s=Je(d,s),n.corners.bottomRight=c=Je(d,c)}return t=Ne.toBounds([a,l,h,c]),n.corners.left=t.left,n.corners.right=t.right,n.corners.top=t.top,n.corners.bottom=t.bottom,n.corners.center=t.center,n.corners.width=t.width,n.corners.height=t.height,t}function $(n,t,e,i){var r={},s="properties";if(n){e=n.propName;var l=[],h=[];if((l=l.concat(Object.keys(n[""+s]||n))).push("version"),e){var c=Zi(t);h=c?c(e):[],l=l.concat(h)}for(var d=function Ooe(n){switch(n){case"nodes":case"children":return["inEdges","outEdges","parentId","processId","nodeId","umlIndex","isPhase","isLane"];case"connectors":return["parentId"];case"annotation":case"annotations":return["nodeId"];case"shape":return["hasHeader"];case"layers":return["objectZIndex"]}return[]}(e),u=0,p=l=l.concat(d);u0&&(e=r),r=Math.floor(Poe(e,i)),s=Bc(o+=n.substr(e,r),t)}while(s<=t.width);for(o=o.substr(0,e),a=e;a=t.width){n=n.substr(0,o.length-1);break}return"Ellipsis"===t.textOverflow?(n=n.substr(0,n.length-3),n+="..."):n=n.substr(0,n.length),n}function MT(n,t){if("NoWrap"===t&&"PreserveAll"===n)return"pre";var e="";switch(n){case"CollapseAll":e="nowrap";break;case"CollapseSpace":e="pre-line";break;case"PreserveAll":e="pre-wrap"}return e}function wT(n,t){var e=Hi();qi(e,t,0,0);var i=Je(e,{x:0,y:0}),r=Je(e,{x:n.width,y:0}),s=Je(e,{x:0,y:n.height}),o=Je(e,{x:n.width,y:n.height}),a=Math.min(i.x,r.x,s.x,o.x),l=Math.min(i.y,r.y,s.y,o.y),h=Math.max(i.x,r.x,s.x,o.x),c=Math.max(i.y,r.y,s.y,o.y);return new me(h-a,c-l)}function xs(n,t,e,i){if(0!==n){var r=Hi();return qi(r,n,t,e),Je(r,i)}return i}function Zi(n){return void 0!==n&&"string"==typeof n&&(n=Y(n,window)),n}var bo=function(){function n(){}return n.getContext=function(t){return t.getContext("2d")},n.setCanvasSize=function(t,e,i){t&&(t.setAttribute("width",e.toString()),t.setAttribute("height",i.toString()))},n.prototype.renderGradient=function(t,e,i,r){var s,o,a;if("None"!==t.gradient.type){for(var l=0;l0?(w=0===S.r1?e.arc[parseInt(r.toString(),10)].r1:S.r1,C=0===S.r2?e.arc[parseInt(r.toString(),10)].r2:S.r2,r++):(w=S.r1,C=S.r2);var D=S.angle*(Math.PI/180),A=S.largeArc,x=S.sweep,R={x:u,y:p},L={x:Math.cos(D)*(M.x-R.x)/2+Math.sin(D)*(M.y-R.y)/2,y:-Math.sin(D)*(M.x-R.x)/2+Math.cos(D)*(M.y-R.y)/2},O=Math.pow(L.x,2)/Math.pow(w,2)+Math.pow(L.y,2)/Math.pow(C,2);O>1&&(w*=Math.sqrt(O),C*=Math.sqrt(O));var N=Math.pow(C,2)*Math.pow(L.x,2),T=(A===x?-1:1)*Math.sqrt((Math.pow(w,2)*Math.pow(C,2)-Math.pow(w,2)*Math.pow(L.y,2)-N)/(Math.pow(w,2)*Math.pow(L.y,2)+Math.pow(C,2)*Math.pow(L.x,2)));isNaN(T)&&(T=0);var P={x:T*w*L.y/C,y:T*-C*L.x/w},_={x:(M.x+R.x)/2+Math.cos(D)*P.x-Math.sin(D)*P.y,y:(M.y+R.y)/2+Math.sin(D)*P.x+Math.cos(D)*P.y},B=this.a([1,0],[(L.x-P.x)/w,(L.y-P.y)/C]),j=[(L.x-P.x)/w,(L.y-P.y)/C],Q=[(-L.x-P.x)/w,(-L.y-P.y)/C],oe=this.a(j,Q);this.r(j,Q)<=-1&&(oe=Math.PI),this.r(j,Q)>=1&&(oe=0);var pe=B+oe/2*(x?1:-1);if(Math.cos(pe),Math.sin(pe),S.centp=_,S.xAxisRotation=D,S.rx=w,S.ry=C,S.a1=B,S.ad=oe,S.sweep=x,null!=s){var De=w>C?w:C,xe=w>C?1:w/C,Ie=w>C?C/w:1;s.save(),s.translate(_.x,_.y),s.rotate(D),s.scale(xe,Ie),s.arc(0,0,De,B,B+oe,!x),s.scale(1/xe,1/Ie),s.rotate(-D),s.translate(-_.x,-_.y),s.restore()}break;case"Z":case"z":s.closePath(),u=o,p=a}o=u,a=p}}},n.prototype.drawText=function(t,e,i,r,s,o,a){if(e.content&&!0===e.visible){var l=n.getContext(t);l.save(),this.setStyle(t,e),o&&(e.fontSize*=o),this.rotateContext(t,e.angle,e.x+e.width*e.pivotX,e.y+e.height*e.pivotY),this.setFontStyle(t,e);var u,d=0;u=e.childNodes;var p=e.wrapBounds;if(l.fillStyle=e.color,p){var f=this.labelAlign(e,p,u);for(d=0;de.width&&"Wrap"!==e.textOverflow&&"NoWrap"===e.textWrapping&&(g.text=qF(g.text,e)),"Clip"!==e.textOverflow&&"Ellipsis"!==e.textOverflow||"Wrap"!==e.textWrapping?l.fillText(g.text,v,y):ya.actualSize.height+a.bounds.y&&(g.text=g.text.slice(0,g.text.length-3),g.text=g.text.concat("...")),l.fillText(g.text,v,y)),"Underline"===e.textDecoration||"Overline"===e.textDecoration||"LineThrough"===e.textDecoration){var M=v,w=void 0,D=v+l.measureText(g.text).width,A=void 0;switch(e.textDecoration){case"Underline":w=y+2,A=y+2;break;case"Overline":w=f.y+g.dy*d,A=f.y+g.dy*d;break;case"LineThrough":w=(y+f.y+g.dy*d)/2+2,A=(y+f.y+g.dy*d)/2+2}l.beginPath(),l.moveTo(M,w),l.lineTo(D,A),l.strokeStyle=e.color,l.lineWidth=.08*e.fontSize,l.globalAlpha=e.opacity,l.stroke()}}}l.restore()}},n.prototype.loadImage=function(t,e,i,r,s){this.rotateContext(i,e.angle,r,s);var o=new Image;o.src=e.source,this.image(t,o,e.x,e.y,e.width,e.height,e)},n.prototype.drawImage=function(t,e,i,r){var s=this;if(e.visible){var o=n.getContext(t);o.save();var a=e.x+e.width*e.pivotX,l=e.y+e.height*e.pivotY,h=new Image;h.src=e.source,o.canvas.id.split("_"),r?h.onload=function(){s.loadImage(o,e,t,a,l)}:this.loadImage(o,e,t,a,l),o.restore()}},n.prototype.image=function(t,e,i,r,s,o,a){t.beginPath();var l=e.width,h=e.height,c=s,d=o,u=0,p=0;if(a&&"None"!==a.alignment){var f=a.alignment.toLowerCase().substr(1,3),g=a.alignment.toLowerCase().substr(5,3);if("Slice"===a.scale){var v=function(){u=c,p=h*c/l},y=function(){u=l*d/h,p=d};c>d?(v(),d>p&&y()):c===d?l>h?y():v():(y(),c>u&&v());var S=this.getSliceOffset(f,u,c,l),b=this.getSliceOffset(g,p,d,h),M=l-S,w=h-b,C=u-S*(u/l),D=p-b*(p/h),A=Tt("canvas",{width:s.toString(),height:o.toString()});A.getContext("2d").drawImage(e,S,b,M,w,0,0,C,D),t.drawImage(A,i,r,s,o)}else if("Meet"===a.scale){var R=h/l,L=d/c;p=L>R?c*R:d,i+=this.getMeetOffset(f,u=L>R?c:d/R,c),r+=this.getMeetOffset(g,p,d),t.drawImage(e,0,0,l,h,i,r,u,p)}else t.drawImage(e,i,r,s,o)}else if("None"!==a.flip){var O=1,N=1;("Horizontal"===a.flip||"Both"===a.flip)&&(i=-i,s=-s,O=-1),("Vertical"===a.flip||"Both"===a.flip)&&(r=-r,o=-o,N=-1),t.scale(O,N),t.drawImage(e,i,r,s,o)}else t.drawImage(e,i,r,s,o);t.closePath()},n.prototype.getSliceOffset=function(t,e,i,r){switch(t){case"min":default:return 0;case"mid":return(e-i)/2*r/e;case"max":return(e-i)*r/e}},n.prototype.getMeetOffset=function(t,e,i){var r=Math.max(e,i),s=Math.min(e,i);switch(t){case"min":default:return 0;case"mid":return(r-s)/2;case"max":return r-s}},n.prototype.m=function(t){return Math.sqrt(Math.pow(t[0],2)+Math.pow(t[1],2))},n.prototype.r=function(t,e){return(t[0]*e[0]+t[1]*e[1])/(this.m(t)*this.m(e))},n.prototype.a=function(t,e){return(t[0]*e[1]t.width&&("Ellipsis"===t.textOverflow||"Clip"===t.textOverflow)&&"NoWrap"===t.textWrapping?0:.5*t.width:"right"===t.textAlign&&(c=1*t.width),s.x=t.x+c+(e?e.x:0),s.y=a+d-r.height/2,s},n}(),gb=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Vi=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Roe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return gb(t,n),Vi([I("")],t.prototype,"source",void 0),Vi([I("transparent")],t.prototype,"color",void 0),Vi([I("None")],t.prototype,"scale",void 0),Vi([I("None")],t.prototype,"align",void 0),t}(Ee),Hoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return gb(t,n),Vi([I("Page")],t.prototype,"mode",void 0),Vi([I("PageSettings")],t.prototype,"region",void 0),Vi([re({top:25,bottom:25,left:25,right:25},$n)],t.prototype,"margin",void 0),Vi([I(!1)],t.prototype,"canZoomIn",void 0),Vi([I(void 0)],t.prototype,"customBounds",void 0),Vi([I(!1)],t.prototype,"canFit",void 0),t}(Ee),Boe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return gb(t,n),Vi([I(null)],t.prototype,"width",void 0),Vi([I(null)],t.prototype,"height",void 0),Vi([re({},$n)],t.prototype,"margin",void 0),Vi([I("Landscape")],t.prototype,"orientation",void 0),Vi([I("Infinity")],t.prototype,"boundaryConstraints",void 0),Vi([re({},Roe)],t.prototype,"background",void 0),Vi([I(!1)],t.prototype,"multiplePage",void 0),Vi([I(!1)],t.prototype,"showPageBreaks",void 0),Vi([re({},Hoe)],t.prototype,"fitOptions",void 0),t}(Ee),Foe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return gb(t,n),Vi([I(0)],t.prototype,"horizontalOffset",void 0),Vi([I(0)],t.prototype,"verticalOffset",void 0),Vi([I(1)],t.prototype,"currentZoom",void 0),Vi([I(0)],t.prototype,"viewPortWidth",void 0),Vi([I(0)],t.prototype,"viewPortHeight",void 0),Vi([I(.2)],t.prototype,"minZoom",void 0),Vi([I(30)],t.prototype,"maxZoom",void 0),Vi([I("Diagram")],t.prototype,"scrollLimit",void 0),Vi([I()],t.prototype,"scrollableArea",void 0),Vi([I(!1)],t.prototype,"canAutoScroll",void 0),Vi([I(100)],t.prototype,"autoScrollFrequency",void 0),Vi([re({left:15,right:15,top:15,bottom:15},$n)],t.prototype,"autoScrollBorder",void 0),Vi([re({left:0,right:0,top:0,bottom:0},$n)],t.prototype,"padding",void 0),Vi([I(.2)],t.prototype,"zoomFactor",void 0),t}(Ee),_oe=function(){function n(){this.services={}}return n.prototype.register=function(t,e){this.services[""+t]=e},n.prototype.getService=function(t){return this.services[""+t]},n}(),$F=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),ma=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},ZF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return $F(t,n),ma([I("lightgray")],t.prototype,"lineColor",void 0),ma([I("")],t.prototype,"lineDashArray",void 0),ma([I([1.25,18.75,.25,19.75,.25,19.75,.25,19.75,.25,19.75])],t.prototype,"lineIntervals",void 0),ma([I([1,19,.5,19.5,.5,19.5,.5,19.5,.5,19.5])],t.prototype,"dotIntervals",void 0),ma([I([20])],t.prototype,"snapIntervals",void 0),t}(Ee),Uoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return $F(t,n),ma([re({},ZF)],t.prototype,"horizontalGridlines",void 0),ma([re({},ZF)],t.prototype,"verticalGridlines",void 0),ma([I(Kt.All)],t.prototype,"constraints",void 0),ma([I(5)],t.prototype,"snapAngle",void 0),ma([I("Lines")],t.prototype,"gridType",void 0),ma([I(5)],t.prototype,"snapObjectDistance",void 0),ma([I("#07EDE1")],t.prototype,"snapLineColor",void 0),t}(Ee),JF=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Ja=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},KF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return JF(t,n),Ja([I(5)],t.prototype,"interval",void 0),Ja([I(100)],t.prototype,"segmentWidth",void 0),Ja([I("Horizontal")],t.prototype,"orientation",void 0),Ja([I("RightOrBottom")],t.prototype,"tickAlignment",void 0),Ja([I("red")],t.prototype,"markerColor",void 0),Ja([I(25)],t.prototype,"thickness",void 0),Ja([I(null)],t.prototype,"arrangeTick",void 0),t}(Ee),joe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return JF(t,n),Ja([I(!1)],t.prototype,"showRulers",void 0),Ja([I(!0)],t.prototype,"dynamicGrid",void 0),Ja([re({orientation:"Horizontal"},KF)],t.prototype,"horizontalRuler",void 0),Ja([re({orientation:"Vertical"},KF)],t.prototype,"verticalRuler",void 0),t}(Ee),Voe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),e_=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Woe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Voe(t,n),e_([I("")],t.prototype,"property",void 0),e_([I("")],t.prototype,"field",void 0),t}(Ee),CT=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),ln=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},t_=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return CT(t,n),ln([I("")],t.prototype,"read",void 0),ln([I("")],t.prototype,"create",void 0),ln([I("")],t.prototype,"update",void 0),ln([I("")],t.prototype,"destroy",void 0),ln([I()],t.prototype,"customFields",void 0),t}(Ee),Yoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return CT(t,n),ln([I("")],t.prototype,"id",void 0),ln([I("")],t.prototype,"sourceID",void 0),ln([I("")],t.prototype,"targetID",void 0),ln([I(null)],t.prototype,"sourcePointX",void 0),ln([I(null)],t.prototype,"sourcePointY",void 0),ln([I(null)],t.prototype,"targetPointX",void 0),ln([I(null)],t.prototype,"targetPointY",void 0),ln([I(null)],t.prototype,"dataManager",void 0),ln([re({},t_)],t.prototype,"crudAction",void 0),t}(Ee),Qoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return CT(t,n),ln([I("")],t.prototype,"id",void 0),ln([I(null)],t.prototype,"dataManager",void 0),ln([I(null)],t.prototype,"dataSource",void 0),ln([I("")],t.prototype,"root",void 0),ln([I("")],t.prototype,"parentId",void 0),ln([I()],t.prototype,"doBinding",void 0),ln([Bt([],Woe)],t.prototype,"dataMapSettings",void 0),ln([re({},t_)],t.prototype,"crudAction",void 0),ln([re({},Yoe)],t.prototype,"connectionDataSource",void 0),t}(Ee),i_=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Cr=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Goe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return i_(t,n),Cr([I("LeftInFlow")],t.prototype,"yesBranchDirection",void 0),Cr([I("RightInFlow")],t.prototype,"noBranchDirection",void 0),Cr([I(["Yes","True"])],t.prototype,"yesBranchValues",void 0),Cr([I(["No","False"])],t.prototype,"noBranchValues",void 0),t}(Ee),Xoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return i_(t,n),Cr([I("")],t.prototype,"fixedNode",void 0),Cr([I(30)],t.prototype,"horizontalSpacing",void 0),Cr([I("SamePoint")],t.prototype,"connectionPointOrigin",void 0),Cr([I("Nonlinear")],t.prototype,"arrangement",void 0),Cr([I(30)],t.prototype,"verticalSpacing",void 0),Cr([I(30)],t.prototype,"maxIteration",void 0),Cr([I(40)],t.prototype,"springFactor",void 0),Cr([I(50)],t.prototype,"springLength",void 0),Cr([re({left:50,top:50,right:0,bottom:0},$n)],t.prototype,"margin",void 0),Cr([I("Auto")],t.prototype,"horizontalAlignment",void 0),Cr([I("Auto")],t.prototype,"verticalAlignment",void 0),Cr([I("TopToBottom")],t.prototype,"orientation",void 0),Cr([I("Auto")],t.prototype,"connectionDirection",void 0),Cr([I("Default")],t.prototype,"connectorSegments",void 0),Cr([I("None")],t.prototype,"type",void 0),Cr([I()],t.prototype,"getLayoutInfo",void 0),Cr([I()],t.prototype,"layoutInfo",void 0),Cr([I()],t.prototype,"getBranch",void 0),Cr([I()],t.prototype,"bounds",void 0),Cr([I(!0)],t.prototype,"enableAnimation",void 0),Cr([I(!1)],t.prototype,"enableRouting",void 0),Cr([I("")],t.prototype,"root",void 0),Cr([re({},Goe)],t.prototype,"flowchartLayoutSettings",void 0),t}(Ee),qoe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),r_=function(n){function t(e,i){var r=n.call(this,e,!0)||this;return r.oldValue=null,r.endPoint=i,r}return qoe(t,n),t.prototype.mouseDown=function(e){var i,r=!0;if(e.source&&e.source.connectors&&(i=e.source.connectors[0]),e.info&&e.actualObject&&(r=e.info.ctrlKey&&"Orthogonal"!==e.actualObject.type),i&&r){this.inAction=!0,this.undoElement=$(e.source),n.prototype.mouseDown.call(this,e);for(var s=0;s0)1!==s&&this.removePrevSegment(i,s);else if(a){var l=z.distancePoints(a.points[0],a.points[1]);Math.abs(a.length||0===a.length?a.length:l)<=5&&this.removeNextSegment(i,s)}this.commandHandler.updateEndPoint(i,r),i.selectedSegmentIndex=0}if(this.undoElement){var c=$(e.source);this.commandHandler.addHistoryEntry({type:"SegmentChanged",redoObject:c,undoObject:this.undoElement,category:"Internal"})}if(i.isBezierEditing&&(i.isBezierEditing=!1),this.prevPosition!==this.startPosition){var u={source:i,state:"Completed",oldValue:this.oldValue,newValue:$(this.selectedSegment),cancel:!1,segment:this.selectedSegment};this.commandHandler.triggerEvent(Ce.segmentChange,u)}n.prototype.mouseUp.call(this,e)},t.prototype.removePrevSegment=function(e,i){var r=e.segments[i-2],s=e.segments[i+1];if(s&&!((s.length||0===s.length?s.length:z.distancePoints(s.points[0],s.points[1]))<=5)){var a=e.segments.slice(i-1,i+1),l={element:e,removeSegments:a,type:"Removal",cancel:!1};if(this.commandHandler.triggerEvent(Ce.segmentCollectionChange,l),!l.cancel){var h=e.segments[i+1];e.segments.splice(i-1,2);var c=this.selectedSegment;"Left"===c.direction||"Right"===c.direction?(r.points[r.points.length-1].x=h.points[0].x,h.points[0].y=r.points[r.points.length-1].y):(r.points[r.points.length-1].y=h.points[0].y,h.points[0].x=r.points[r.points.length-1].x),(c.length||0===c.length)&&this.findSegmentDirection(r),this.findSegmentDirection(h)}}},t.prototype.findSegmentDirection=function(e){e.direction&&(e.length||0===e.length)&&(e.length=z.distancePoints(e.points[0],e.points[e.points.length-1]),e.direction=z.direction(e.points[0],e.points[e.points.length-1]))},t.prototype.removeNextSegment=function(e,i){var l,h,r=this.selectedSegment,s=e.segments[i-1],o=e.segments[i+2],a=e.segments[i+1];if(a.length||0===a.length?(l=e.segments.slice(i,2),h={element:e,removeSegments:l,type:"Removal",cancel:!1},this.commandHandler.triggerEvent(Ce.segmentCollectionChange,h={element:e,removeSegments:l,type:"Removal",cancel:!1}),h.cancel||(e.segments.splice(i,2),"Top"===r.direction||"Bottom"===r.direction?(o.points[0].y=r.points[0].y,s.points[s.points.length-1].x=o.points[0].x):(o.points[0].x=r.points[0].x,s.points[s.points.length-1].y=o.points[0].y))):(l=e.segments.slice(i+1,1),this.commandHandler.triggerEvent(Ce.segmentCollectionChange,h={element:e,removeSegments:l,type:"Removal",cancel:!1}),h.cancel||(e.segments.splice(i+1,1),"Top"===r.direction||"Bottom"===r.direction?s.points[s.points.length-1].x=a.points[a.points.length-1].x:s.points[s.points.length-1].y=a.points[a.points.length-1].y,this.findSegmentDirection(s),r.length=r.direction=null)),s&&o&&!h.cancel&&(s.length=z.distancePoints(s.points[0],o.points[0]),s.direction=z.direction(s.points[0],o.points[0]),o.length||0===o.length)){o.length=z.distancePoints(s.points[s.points.length-1],o.points[o.points.length-1]);var c=s.points,d=o.points;o.direction=z.direction(c[c.length-1],d[d.length-1])}},t.prototype.addOrRemoveSegment=function(e,i,r){for(var s,o,a=[],l={segments:e.segments},h=0;h0?"Bottom":"Top":r>0?"Right":"Left",length:i.points[0].x===i.points[1].x?s:r},!0)),l.push(new bi(e,"segments",{type:"Orthogonal",direction:c,length:h/2},!0));var p={element:e,addSegments:l,type:"Addition",cancel:!1};return this.commandHandler.triggerEvent(Ce.segmentCollectionChange,p),p.cancel||(e.segments=l.concat(e.segments),a=o+2),a},t.prototype.insertFirstSegment=function(e,i,r,s,o){var a,l,d,u,h=[];if(e.sourcePortID&&i.length&&e.segments[0].points.length>2)for(var p=void 0,f=0;f0?"Bottom":"Top":r>0?"Right":"Left"),p=u,h.push(u)}else h.push(new bi(e,"segments",{type:"Orthogonal",direction:i.direction,length:i.length/3},!0)),"Bottom"===i.direction||"Top"===i.direction?(l=Math.abs(r),a=r>0?"Right":"Left"):(l=Math.abs(s),a=s>0?"Bottom":"Top"),u=new bi(e,"segments",{type:"Orthogonal",direction:a,length:l},!0),h.push(u);var y={element:e,addSegments:h,type:"Addition",cancel:!1};if(this.commandHandler.triggerEvent(Ce.segmentCollectionChange,y),!y.cancel){if(e.sourcePortID&&i.length&&e.segments[0].points.length>2)e.segments.splice(0,1),d=1;else{var S=e.segments[1];S&&S.length&&(S.length=a!==S.direction?S.length+l:S.length-l),d=2,i.length=2*i.length/3}e.segments=h.concat(e.segments)}return d},t.prototype.updateAdjacentSegments=function(e,i,r,s){var o=e.segments[parseInt(i.toString(),10)],a=o.points[o.points.length-1],h=!0;"Orthogonal"===o.type&&(o.points[0]=o.points[0],o.points[o.points.length-1]=a,e.segments[i-1]&&(h=this.updatePreviousSegment(r,s,e,i)),e.segments.length-1>i&&h&&this.updateNextSegment(e,o,e.segments[i+1],r,s))},t.prototype.addTerminalSegment=function(e,i,r,s,o){var l,h,c,d,a=e.segments.indexOf(i),u=[],p=e.segments.pop(),f=e.segments[e.segments.length-1];l=f&&"Orthogonal"===f.type?f:null;for(var g=0;g0&&"Left"===o.direction?c.middleLeft:c.middleRight,o.length>c.width/2?Math.abs(a.length)0&&"Top"===o.direction?c.topCenter:c.bottomCenter,o.length>c.height/2?Math.abs(a.length)1)for(var a=0,l=this.diagram.views;a0)for(var e=t===Ce.onUserHandleMouseLeave?this.previousAction:this.action,i={element:void 0},r=0;r0)for(var r={element:void 0},s=void 0,o=void 0,a=0;a-1&&(o=s,this.previousTarget=i,this.targetItem=e),o===e.fixedUserHandles[parseInt(a.toString(),10)].id&&(r.element=e.fixedUserHandles[parseInt(a.toString(),10)],this.userHandle(t,a,r,e))},n.prototype.mouseDown=function(t){if(!0!==this.inAction||!(this.tool instanceof XI||this.tool instanceof pa)){this.focus=!0;var e=t.touches,i=!!document.getElementsByClassName("e-dragclone")[0];if(this.isMouseOnScrollBar(t)&&!i)return this.isScrolling=!0,void t.preventDefault();if(this.checkFixedUserHandleEvent(Ce.onFixedUserHandleMouseDown,this.targetItem,this.previousTarget),this.checkUserHandleEvent(Ce.onUserHandleMouseDown),!this.checkEditBoxAsTarget(t)&&Wv(this.diagram)||Lc(this.diagram)&&!FI(this.diagram))if(("Select"===this.action||"Drag"===this.action)&&this.diagram.updatePortVisibility(this.hoverElement,hi.Hover,!0),!(this.tool instanceof Ph||this.tool instanceof zh)||2!==t.button&&2!==t.buttons)if(!0===this.inAction&&!0===this.isMouseDown&&(this.tool instanceof Ph||this.tool instanceof zh))this.isMouseDown=!0,this.eventArgs={},this.getMouseEventArgs(this.currentPosition,this.eventArgs),this.eventArgs.position=this.currentPosition,this.tool.mouseDown(this.eventArgs);else{this.isMouseDown=!0,this.currentPosition=this.prevPosition=this.getMousePosition(t),this.eventArgs={},this.diagram.textEditing&&!this.isMouseOnScrollBar(t)&&(this.diagram.endEdit(),this.diagram.textEditing=!1,"Canvas"===this.diagram.mode&&1!==this.diagram.scroller.currentZoom&&this.diagram.refreshDiagramLayer());var s=this.getTargetElement();this.action=this.diagram.findActionToBeDone(s.obj,s.sourceElement,this.currentPosition,s.target);var o=this.isMetaKey(t);o&&t.shiftKey&&this.diagram.connectorEditingToolModule?this.action="SegmentEnd":(o||t.shiftKey)&&(jv(this.diagram)||Vv(this.diagram))&&(this.action="Select"),this.tool=this.diagram.getTool(this.action),this.tool||(this.action="Select",this.tool=this.diagram.getTool(this.action)),this.getMouseEventArgs(this.currentPosition,this.eventArgs),(o||t.shiftKey)&&(this.eventArgs.info=o&&t.shiftKey?{ctrlKey:o,shiftKey:t.shiftKey}:{ctrlKey:!0}),this.eventArgs.position=this.currentPosition;var l=this.diagram.selectedItems.nodes;if(this.tool.mouseDown(this.eventArgs),this.diagram.selectedItems.canToggleSelection&&l&&this.diagram.selectedItems.nodes&&this.tool instanceof ua)for(var h=0;h=2&&(this.touchStartList=VF(this.touchStartList,0,e)),e||t.preventDefault())}else this.inAction=!1,this.tool.mouseUp(this.eventArgs);!this.isForeignObject(t.target)&&!this.isForeignObject(t.target,!0)&&!e&&t.preventDefault()}},n.prototype.mouseMoveExtend=function(t,e){(this.tool instanceof Ph||this.tool instanceof zh)&&this.tool.mouseMove(this.eventArgs),this.diagram.scrollSettings.canAutoScroll?this.checkAutoScroll(t):this.blocked||this.tool.mouseMove(this.eventArgs),this.eventArgs.target&&(this.hoverElement=this.eventArgs.target);var i=!((this.eventArgs.target instanceof te||this.eventArgs.target instanceof de)&&(e instanceof te||e instanceof de));this.tool instanceof Pd&&this.diagram.updatePortVisibility(this.hoverElement instanceof te||this.hoverElement instanceof de?this.hoverElement:this.hoverNode,hi.Connect|hi.Hover,i),this.hoverElement instanceof te&&this.hoverNode instanceof te&&this.hoverNode&&this.hoverNode.id!==this.hoverElement.id&&this.diagram.updatePortVisibility(this.hoverNode,hi.Connect|hi.Hover,!0),this.hoverElement instanceof de&&this.hoverElement.ports.length>0&&this.diagram.updatePortVisibility(this.hoverElement,hi.Connect|hi.Hover,!0),this.previousElement instanceof te&&this.hoverElement&&this.previousElement.id!==this.hoverElement.id&&this.diagram.updatePortVisibility(this.previousElement,hi.Connect|hi.Hover,!0),this.previousElement=this.hoverElement,""!==this.diagram.tooltip.content&&(this.hoverElement=null),this.hoverNode=i?null:e},n.prototype.checkAction=function(t){if("LabelSelect"===this.action&&this.eventArgs.sourceWrapper&&(this.eventArgs.sourceWrapper instanceof ni||this.eventArgs.sourceWrapper instanceof Jn)){var e=this.commandHandler.findTarget(this.eventArgs.sourceWrapper,this.eventArgs.source);!_r(this.diagram,e,!1,this.eventArgs.sourceWrapper)&&to(e)&&(this.action="LabelDrag",this.tool=this.getTool(this.action),this.tool.mouseDown(this.initialEventArgs))}else to(t)&&Td(t)&&this.initialEventArgs&&this.initialEventArgs.source&&"Select"===this.action&&(!_r(this.diagram,this.eventArgs.source,!1)&&this.eventArgs.source instanceof si&&this.getMouseEventArgs(this.currentPosition,this.eventArgs),(!(t instanceof de)||t instanceof de&&!(wr(this.currentPosition,t.sourcePoint,t.hitPadding)||wr(this.currentPosition,t.targetPoint,t.hitPadding)))&&(this.action="Drag"),this.tool=this.getTool(this.action),this.tool.mouseDown(this.initialEventArgs))},n.prototype.isSwimlaneElements=function(t){return!(t&&(t.isLane||t.isPhase||t.isHeader))},n.prototype.mouseMove=function(t,e){if(this.focus=!0,this.isScrolling)t.preventDefault();else if(Wv(this.diagram)||Lc(this.diagram)&&!FI(this.diagram)){this.currentPosition=this.getMousePosition(t);var i=this.diagram.findObjectsUnderMouse(this.currentPosition),r=this.diagram.findObjectUnderMouse(i,this.action,this.inAction);!function nse(n,t){n.rulerSettings.showRulers&&(n.hRuler.drawRulerMarker(n.hRuler.element,t,n.scroller.horizontalOffset),n.vRuler.drawRulerMarker(n.vRuler.element,t,n.scroller.verticalOffset))}(this.diagram,this.currentPosition);var s=!1,o=void 0;if("touchmove"===t.type&&(e=t.touches)&&e.length>1&&(this.touchMoveList=VF(this.touchMoveList,0,e),"PinchZoom"!==this.action&&(s=!0)),!1===z.equals(this.currentPosition,this.prevPosition)||this.inAction){if(!1===this.isMouseDown||s){this.eventArgs={};var a=null,l=void 0;if(null!==r){if((a=this.diagram.findElementUnderMouse(r,this.currentPosition,this.diagram))&&(l=this.commandHandler.findTarget(a,r)),(l instanceof Zn||l instanceof Nr)&&(l.tooltip&&""!==l.tooltip.content||(l=r)),l!==this.hoverElement){var h=this.getContent();this.hoverElement&&"Auto"===this.hoverElement.tooltip.openOn&&""!==h&&this.elementLeave(),this.diagram.updatePortVisibility(this.hoverElement,hi.Hover,!0),r instanceof te&&(this.hoverNode=r);var c=!0;!this.isSwimlaneElements(r)&&this.hoverElement&&this.isSwimlaneElements(this.hoverElement)&&(c=!1),this.hoverElement=c?r:this.hoverElement;var d,u=void 0;(d=this.diagram.findElementUnderMouse(r,this.currentPosition,this.diagram))instanceof Ke&&((u=this.commandHandler.findTarget(d,r))instanceof Es||u instanceof xc)&&this.hoverElement.constraints&ri.ToolTip&&(this.hoverElement=u);var p=void 0;d instanceof ni&&((p=this.commandHandler.findTarget(d,r))instanceof Zn||p instanceof Nr)&&p.constraints&Lr.Tooltip&&(this.hoverElement=p),c?this.elementEnter(this.currentPosition,!1):this.hoverElement=r}else this.hoverElement&&this.hoverElement===l&&this.hoverElement.tooltip.content&&void 0!==this.diagram.tooltipObject&&"Mouse"===this.hoverElement.tooltip.relativeMode&&this.setTooltipOffset(this.currentPosition);a&&(o=this.commandHandler.findTarget(a,r))}this.action=this.diagram.findActionToBeDone(r,a,this.currentPosition,o),this.checkFixedUserHandleEvent(Ce.onFixedUserHandleMouseEnter,r,a),this.checkUserHandleEvent(Ce.onUserHandleMouseEnter),this.checkPreviousAction(),this.getMouseEventArgs(this.currentPosition,this.eventArgs),this.tool=this.getTool(this.action),this.mouseEvents(),this.tool instanceof pa||this.tool instanceof zh||this.tool instanceof Ph?this.tool.mouseMove(this.eventArgs):e&&this.tool instanceof em&&this.tool.mouseDown(this.eventArgs),this.updateCursor(),this.renderUmlHighLighter(this.eventArgs);var f=!1;this.hoverElement&&!(this.tool instanceof em)&&r instanceof te&&this.isSwimlaneElements(r)&&(0===this.diagram.selectedItems.nodes.length||!_r(this.diagram,this.hoverElement))||this.hoverElement instanceof de||(f=!0),this.hoverElement&&!(this.tool instanceof em)&&r instanceof de&&(0===this.diagram.selectedItems.connectors.length||!_r(this.diagram,this.hoverElement))||this.hoverElement instanceof te||(f=!0),this.diagram.updatePortVisibility(this.hoverElement,hi.Hover,f);var g=this.getContent();null===r&&this.hoverElement&&"Auto"===this.hoverElement.tooltip.openOn&&g&&(this.hoverElement=null,this.elementLeave()),s=!1}else{this.eventArgs.position=this.currentPosition,"Drag"===this.action&&!_r(this.diagram,this.eventArgs.source,!1)&&this.eventArgs.source instanceof si&&this.getMouseEventArgs(this.currentPosition,this.eventArgs),this.mouseEvents(),(t.ctrlKey||t.shiftKey)&&(this.eventArgs.info=t.ctrlKey&&t.shiftKey?{ctrlKey:t.ctrlKey,shiftKey:t.shiftKey}:{ctrlKey:!0}),this.checkAction(r);var y=this.getConnectorPadding(this.eventArgs);this.getMouseEventArgs(this.currentPosition,this.eventArgs,this.eventArgs.source,y),this.updateCursor(),this.inAction=!0,this.initialEventArgs=null,("Drag"===this.action||"Rotate"===this.action)&&(this.diagram.diagramActions=this.diagram.diagramActions|ee.Interactions);var S=this.diagram.scroller.getPageBounds();this.mouseMoveExtend(t,r);var b=this.diagram.scroller.getPageBounds();if(r&&(S.width!==b.width||S.height!==b.height||S.x!==b.x||S.y!==b.y)&&this.diagram.views&&this.diagram.views.overview){var M=this.diagram.views.overview;M.updateView(M)}}this.prevPosition=this.currentPosition,this.isForeignObject(t.target,!0)||t.preventDefault()}}},n.prototype.getContent=function(){var i,t=this.hoverElement instanceof te&&this.hoverElement.constraints&ie.Tooltip||this.hoverElement instanceof de&&this.hoverElement.constraints&qe.Tooltip||(this.hoverElement instanceof Es||this.hoverElement instanceof xc)&&this.hoverElement.constraints&ri.ToolTip||(this.hoverElement instanceof Zn||this.hoverElement instanceof Nr)&&this.hoverElement.constraints&Lr.Tooltip,e=this.hoverElement;e instanceof te&&e.children&&e.children.length>0&&(i=this.findIntersectChild(e));var r=t?this.hoverElement.tooltip.content:this.diagram.tooltip.content;return i?i.tooltip.content:r},n.prototype.findIntersectChild=function(t){for(var e,i=new Ne(this.currentPosition.x,this.currentPosition.y,8,8),r=0;r1&&1===t.which&&!function one(n){return!!(n&ee.PreventClearSelection)}(this.diagram.diagramActions)&&(c=!1,this.commandHandler.clearSelection()),(!_r(this.diagram,h)||!c)&&(this.commandHandler.selectObjects([h],void 0,a),this.diagram.selectedItems.canToggleSelection)){var d=this.diagram.selectedItems.nodes;d?d[0].parentObj instanceof Bd&&(s=!0):this.diagram.selectedItems.connectors.length>0&&(s=!0)}}var u=!1,p=this.updateContainerProperties(),f=void 0;if(this.addUmlNode(),this.inAction=!1,this.isMouseDown=!1,this.diagram.selectedObject.helperObject&&(f=this.updateContainerBounds()),this.tool&&(this.tool.prevPosition||this.tool instanceof eF)){this.eventArgs.position=this.currentPosition;var g=this.getConnectorPadding(this.eventArgs);this.getMouseEventArgs(this.currentPosition,this.eventArgs,this.eventArgs.source,g);var v=this.isMetaKey(t);if((v||t.shiftKey)&&(this.eventArgs.info=v&&t.shiftKey?{ctrlKey:v,shiftKey:t.shiftKey}:{ctrlKey:!0}),this.diagram.diagramActions&ee.Interactions&&(this.diagram.diagramActions=this.diagram.diagramActions&~ee.Interactions),this.eventArgs.clickCount=t.detail,this.diagram.selectedObject.helperObject&&(this.tool instanceof ua||this.tool instanceof zd)){if(this.diagram.selectedObject.actualObject&&""!==this.diagram.selectedObject.actualObject.parentId){var S=this.diagram.getObject(this.diagram.selectedObject.actualObject.parentId);S&&S.isLane&&(this.commandHandler.isContainer=!0)}(u=this.diagram.lineRoutingModule&&this.diagram.nameTable.helper&&this.eventArgs.target&&this.eventArgs.target.isLane&&(this.eventArgs.source instanceof si&&this.eventArgs.source.nodes.length>0&&""===this.eventArgs.source.nodes[0].parentId||""===this.eventArgs.source.parentId))&&(this.diagram.diagramActions=this.diagram.diagramActions|ee.PreventLaneContainerUpdate),this.tool.mouseUp(this.eventArgs,p.isPreventHistory)}else{if(this.diagram.selectedItems.canToggleSelection){var b=void 0,M=void 0;if(this.diagram.selectedItems.nodes.length>0)for(var w=0;w1&&D[0].id===i[parseInt(w.toString(),10)].id||r.length>0)&&(M=!0);!this.isSwimlaneSelected&&!s&&!M&&this.tool instanceof ua&&"Select"===this.currentAction&&(!b||this.diagram.selectedItems.connectors.length>0)&&this.commandHandler.clearSelection(!0)}this.isSwimlaneSelected=!1,this.tool.mouseUp(this.eventArgs),this.diagram.checkMenu&&(-1!==window.navigator.userAgent.indexOf("Linux")||-1!==window.navigator.userAgent.indexOf("X11"))&&(!t.pageY&&t instanceof TouchEvent&&t.changedTouches?(window.getSelection().removeAllRanges(),this.diagram.contextMenuModule.contextMenu.open(t.changedTouches[0].pageY,t.changedTouches[0].pageX,this.diagram.element),t.preventDefault()):this.diagram.contextMenuModule.contextMenu.open(t.pageY,t.pageX,this.diagram.element),this.diagram.checkMenu=!1)}p.hasStack&&this.diagram.endGroupAction()}if(f&&this.diagram.endGroupAction(),this.updateContainerBounds(!0),2!==this.eventArgs.clickCount&&(this.commandHandler.updateSelectedNodeProperties(this.eventArgs.source),u)){this.diagram.diagramActions=this.diagram.diagramActions&~ee.PreventLaneContainerUpdate;var A=this.eventArgs.source instanceof si?this.eventArgs.source.nodes:[this.eventArgs.source];if(A)for(w=0;w0&&!N&&this.diagram.renderSelector(!0),!this.inAction&&!this.diagram.currentSymbol&&this.eventArgs){var T=this.getTargetElement();this.diagram.tool!==Ci.ZoomPan&&this.diagram.triggerEvent(Ce.click,{element:T.target instanceof Es?T.target:this.eventArgs.source||this.diagram,position:this.eventArgs.position,count:t.detail,actualObject:this.eventArgs.actualObject,button:0===t.button?"Left":1===t.button?"Middle":"Right"})}this.eventArgs={}}this.diagram.diagramActions=this.diagram.diagramActions&~ee.PreventLaneContainerUpdate,e&&this.updateAnnotation(this.diagram.selectedItems),this.eventArgs={},this.diagram.commandHandler.removeStackHighlighter()},n.prototype.isSwimlaneChild=function(t){if(t.shape&&"SwimLane"!==t.shape.type){var e=this.diagram.nameTable[t.parentId];if(!e)return!1;var i=e.parentId?this.diagram.nameTable[e.parentId]:e;return i&&i.shape&&"SwimLane"===i.shape.type}return!1},n.prototype.updateAnnotation=function(t){var e=t.nodes;if(e.length>0)for(var i=0;i0&&(a+=1),h.isPhase){l="Horizontal"===r.orientation?this.currentPosition.x-e.wrapper.bounds.x:this.currentPosition.y-(e.wrapper.bounds.y+r.header.height);var g={id:Qe(),offset:l,header:{annotation:{content:void 0===h.phases[0].header?"Phase":h.phases[0].header.annotation.content,style:void 0===h.phases[0].header?{}:h.phases[0].header.annotation.style}},style:void 0===h.phases[0]?{}:h.phases[0].style};this.diagram.addPhases(e,[g])}else{var v={id:Qe(),style:h.lanes[0].style,header:{annotation:{content:h.lanes[0].header.annotation.content,style:h.lanes[0].header.annotation.style},style:h.lanes[0].header.style}};if("Horizontal"===h.orientation?v.height=h.lanes[0].height:v.width=h.lanes[0].width,"Horizontal"===r.orientation?(s=i.rowIndex?i.rowIndex:this.diagram.nameTable[i.parentId].rowIndex,i.wrapper.offsetYs)v.header.width=r.lanes[parseInt(s.toString(),10)].header.width,v.header.height=r.lanes[parseInt(s.toString(),10)].header.height;else{var S=void 0;S="Horizontal"===r.orientation?i.rowIndex<3?0:s-a-1:s-1,v.header.width=r.lanes[parseInt(S.toString(),10)].header.width,v.header.height=r.lanes[parseInt(S.toString(),10)].header.height}f&&("height"===f?(v.width=v.height,delete v.height):(v.height=v.width,delete v.width)),this.diagram.addLanes(e,[v],"Horizontal"===r.orientation?s-a:s)}this.commandHandler.select(e)}else if(h.isLane){var b={id:Qe(),width:t.width,height:t.height,addInfo:t.addInfo,shape:{type:"SwimLane",header:{annotation:{content:void 0===h.header?"Header":h.header.annotation.content,style:void 0===h.header?{}:h.header.annotation.style},height:50,style:h.header?h.header.style:h.lanes[0].header.style},phases:[{id:Qe(),header:{annotation:{content:void 0===h.phases||void 0===h.phases[0].header?"Phase":h.phases[0].header.annotation.content,style:void 0===h.phases||void 0===h.phases[0].header?{}:h.phases[0].header.annotation.style},style:void 0===h.phases||void 0===h.phases[0].header?{}:h.phases[0].header.style},style:void 0===h.phases?{}:h.phases[0].style}],lanes:[{id:Qe(),height:t.height,width:t.width,style:h.lanes[0].style,header:{annotation:{content:h.lanes[0].header.annotation.content,style:h.lanes[0].header.annotation.style},style:h.lanes[0].header.style}}],orientation:h.orientation}};"Vertical"===h.orientation&&(b.width+=20),b.offsetX=this.currentPosition.x+b.width/2,b.offsetY=this.currentPosition.y+b.height/2,b.style=t.style,this.diagram.add(b)}},n.prototype.mouseLeave=function(t){this.tool&&this.inAction&&this.tool.mouseLeave(this.eventArgs),this.diagram.selectedObject.helperObject&&(this.updateContainerProperties(),this.updateContainerBounds()&&this.diagram.endGroupAction()),this.eventArgs&&this.eventArgs.source&&(this.diagram.updatePortVisibility(this.eventArgs.source,hi.Hover,!0),this.hoverElement=null),this.eventArgs&&!this.eventArgs.source&&this.hoverElement&&(this.hoverElement=null),this.tool instanceof Pd&&this.eventArgs&&this.eventArgs.target&&this.eventArgs.target instanceof te&&(this.diagram.updatePortVisibility(this.eventArgs.target,hi.Hover|hi.Connect,!0),this.hoverElement=null);var i=this.diagram.selectedItems;i&&i.wrapper&&(lm(this.diagram,i)||this.diagram.renderSelector(!0)),(this.diagram.diagramActions&ee.Interactions||this.diagram.diagramActions&ee.ToolAction)&&(this.diagram.diagramActions=this.diagram.diagramActions&~ee.ToolAction),this.isMouseDown=!1,this.focus=!1,this.touchStartList=null,this.touchMoveList=null,this.elementLeave(),this.commandHandler.removeSnap(),this.inAction=!1,this.eventArgs={},this.diagram.selectedObject&&this.diagram.selectedObject.helperObject&&(this.diagram.remove(this.diagram.selectedObject.helperObject),this.diagram.selectedObject={helperObject:void 0,actualObject:void 0}),this.tool=null,function rse(){var t,e,n=document.getElementsByClassName("e-d-ruler-marker");if(n&&n.length>0)for(e=n.length-1;e>=0;e--)(t=n[parseInt(e.toString(),10)])&&t.parentNode.removeChild(t)}(),"Rotate"===this.action&&this.diagram.diagramCanvas.classList.remove("e-diagram-rotate"),t.preventDefault()},n.prototype.mouseWheel=function(t){this.diagram.blazorActions|=on.interaction;var e={event:t,cancel:!1};if(this.diagram.triggerEvent(Ce.mouseWheel,e),!e.cancel){var i=t.wheelDelta>0||-40*t.detail>0,r=this.getMousePosition(t);if(this.diagram.tooltipObject.close(),this.isMetaKey(t)){var o=this.diagram.scrollSettings.zoomFactor;this.diagram.zoomTo(i?{type:"ZoomIn",zoomFactor:o,focusPoint:r}:{type:"ZoomOut",zoomFactor:o,focusPoint:r}),t.preventDefault()}else{var a=this.diagram.scroller.horizontalOffset,l=this.diagram.scroller.verticalOffset,h=i?10:-10;this.tool&&(this.tool instanceof Ph||this.tool instanceof zh)&&(this.eventArgs={},this.getMouseEventArgs(r,this.eventArgs),this.eventArgs.position=r,this.tool.mouseWheel(this.eventArgs)),this.diagram.scrollActions|=ca.Interaction;var c=!0;if(t.isTrusted){var d=!1;(Math.abs(t.deltaY)<100&&-0===Math.abs(t.deltaX)||Math.abs(t.deltaX)<100&&-0===Math.abs(t.deltaY))&&(d=!0);var u=!1;(0!==t.deltaX||0!==t.deltaY)&&(u=navigator.userAgent.includes("Macintosh")),u?Math.abs(t.deltaX)>Math.abs(t.deltaY)?(t.shiftKey||t.deltaX&&-0!==t.deltaX&&(d||!u))&&this.diagram.scroller.zoom(1,h,0,r,c,void 0,d):t.deltaY&&-0!==t.deltaY&&(d||!u)&&this.diagram.scroller.zoom(1,0,h,r,c,void 0,d):t.shiftKey||t.deltaX&&-0!==t.deltaX&&(d||!u)?this.diagram.scroller.zoom(1,h,0,r,c,void 0,d):t.deltaY&&-0!==t.deltaY&&(d||!u)&&this.diagram.scroller.zoom(1,0,h,r,c,void 0,d)}else t.shiftKey||t.deltaX&&-0!==t.deltaX?this.diagram.scroller.zoom(1,h,0,r,c):this.diagram.scroller.zoom(1,0,h,r,c);this.diagram.scrollActions&=~ca.Interaction,(a!==this.diagram.scroller.horizontalOffset||l!==this.diagram.scroller.verticalOffset)&&t.preventDefault()}if(this.diagram.textEditing){if(this.diagram.isTriggerEvent=!0,this.diagram.activeLabel.parentId){var f=this.diagram.getObject(this.diagram.activeLabel.parentId);this.diagram.startTextEdit(f,this.diagram.activeLabel.id)}this.diagram.isTriggerEvent=!1}this.diagram.blazorActions=this.diagram.blazorActions&~on.interaction}},n.prototype.keyDown=function(t){if(t.fromMouseEvents&&(t.ctrlKey&&(this.keyArgs.keyModifiers=1),t.shiftKey&&(this.keyArgs.keyModifiers=4),t.shiftKey&&t.ctrlKey&&(this.keyArgs.keyModifiers=5)),!(this.diagram.diagramActions&ee.TextEdit)&&!this.checkEditBoxAsTarget(t)||"Escape"===t.key||27===t.keyCode){var i=void 0,r=t.keyCode?t.keyCode:t.which,s=t.key;("ArrowDown"===s||"ArrowUp"===s||"ArrowLeft"===s||"ArrowRight"===s)&&(this.isNudgeKey=!0);var o=this.isMetaKey(t);if(this.diagram.commandManager&&this.diagram.commands)for(var l=0,h=Object.keys(this.diagram.commands);l4&&(S({keyDownEventArgs:KeyboardEvent,parameter:i.parameter,type:"KEYDOWN"}),this.keyCount=0)),this.isKeyUp=!1):S({keyDownEventArgs:KeyboardEvent,parameter:i.parameter})}break}}}}this.keyArgs={element:this.diagram.selectedItems,key:t.key,keyCode:t.keyCode?t.keyCode:t.which},this.getKeyModifier(this.keyArgs,t),this.diagram.diagramActions&ee.TextEdit&&this.getlabel(this.keyArgs,t),this.diagram.triggerEvent(Ce.keyDown,this.keyArgs)},n.prototype.getlabel=function(t,e){var i=this.diagram.activeLabel;t.target=this.diagram.element.id+"_editBox";var r=this.diagram.nameTable[i.parentId];if(document.getElementById(this.diagram.element.id+"_editBox")){t.text=document.getElementById(this.diagram.element.id+"_editBox").value;for(var s=0;s=this.diagram.scroller.viewPortWidth-18?r="right":e.x+this.diagram.scroller.horizontalOffsetthis.diagram.scroller.viewPortHeight-18?r="bottom":e.y+this.diagram.scroller.verticalOffset0&&(s=this.findIntersectChild(this.hoverElement)),"Auto"===this.hoverElement.tooltip.openOn&&""!==r&&Ex(this.diagram,s||(i?this.hoverElement:void 0)),this.hoverElement.tooltip.content&&("Mouse"===this.hoverElement.tooltip.relativeMode?this.setTooltipOffset(t):(this.diagram.tooltipObject.offsetX=0,this.diagram.tooltipObject.offsetY=0));var o=this.diagram.findObjectsUnderMouse(this.currentPosition),a=this.diagram.findObjectUnderMouse(o,this.action,this.inAction);if(null!==a){var l=void 0;this.hoverElement.tooltip.isSticky&&(this.diagram.tooltipObject.isSticky=!0),a instanceof te&&a.children&&a.children.length>0&&(a=s||a),l=a.ports&&(this.hoverElement instanceof Es||this.hoverElement instanceof xc)||a.annotations&&(this.hoverElement instanceof Zn||this.hoverElement instanceof Nr)?document.getElementById(a.id+"_"+this.hoverElement.id):document.getElementById(a.id+(a.shape&&a.shape instanceof hm?"_content_native_element":"_groupElement")),"Auto"===this.hoverElement.tooltip.openOn&&""!==r&&(this.diagram.tooltipObject.close(),this.diagram.tooltipObject.openOn=this.hoverElement.tooltip.openOn,this.diagram.tooltipObject.dataBind()),function Kre(n,t){var e=0;return n instanceof de?n.constraints&qe.Tooltip?e=n.constraints&qe.Tooltip:n.constraints&qe.InheritTooltip&&(e=t.constraints&rt.Tooltip):n instanceof Es||n instanceof xc?n.constraints&ri.ToolTip?e=n.constraints&ri.ToolTip:n.constraints&ri.InheritTooltip&&(e=t.constraints&rt.Tooltip):n instanceof Zn||n instanceof Nr?n.constraints&Lr.Tooltip&&(e=n.constraints&Lr.Tooltip):n.constraints&ie.Tooltip?e=n.constraints&ie.Tooltip:n.constraints&ie.InheritTooltip&&(e=t.constraints&rt.Tooltip),e}(this.hoverElement,this.diagram)&&"Auto"===this.hoverElement.tooltip.openOn&&(this.diagram.tooltipObject.target=this.hoverElement.id,this.diagram.tooltipObject.open("Mouse"===this.hoverElement.tooltip.relativeMode?this.diagram.element:l))}}},n.prototype.elementLeave=function(){this.diagram.tooltipObject&&!this.diagram.tooltipObject.isSticky&&"Custom"!==this.diagram.tooltipObject.openOn&&this.diagram.tooltipObject.close()},n.prototype.setTooltipOffset=function(t){var e=function Mse(n,t,e,i){var o="Mouse"===(!(e instanceof te?e.constraints&ie.InheritTooltip:e instanceof de?e.constraints&qe.InheritTooltip:e.constraints&ri.InheritTooltip)&&(e instanceof te?e.constraints&ie.Tooltip:e instanceof de?e.constraints&qe.Tooltip:e.constraints&ri.ToolTip)?e.tooltip.relativeMode:n.tooltip.relativeMode);"Mouse"===i?o=!0:"Object"===i&&(o=!1);var a=function wse(n,t,e,i){var o,r={},s=document.getElementById(e.element.id);if(n instanceof te||n instanceof de)o=n.wrapper.bounds;else{var a=e.findObjectsUnderMouse(t),l=e.findObjectUnderMouse(a,"Select",!1);o=e.findElementUnderMouse(l,t,e).bounds}var c=s.getBoundingClientRect();switch(e.tooltipObject.position){case"BottomCenter":r=zc(t,o.bottomCenter,e,i,c.width/2,c.height);break;case"BottomLeft":case"LeftBottom":r=zc(t,o.bottomLeft,e,i,0,c.height);break;case"BottomRight":case"RightBottom":r=zc(t,o.bottomRight,e,i,c.width,c.height);break;case"LeftCenter":r=zc(t,o.middleLeft,e,i,0,c.height/2);break;case"LeftTop":case"TopLeft":r=zc(t,o.topLeft,e,i,0,0);break;case"RightCenter":r=zc(t,o.middleRight,e,i,c.width,c.height/2);break;case"RightTop":case"TopRight":r=zc(t,o.topRight,e,i,c.width,0);break;case"TopCenter":r=zc(t,o.topCenter,e,i,c.width/2,0)}return r}(e,t,n,o),l=qa(n);return{x:a.x+l.width,y:a.y+l.height}}(this.diagram,t,this.hoverElement);this.diagram.tooltipObject.offsetX=e.x,this.diagram.tooltipObject.offsetY=e.y},n.prototype.altKeyPressed=function(t){return!!(t&pt.Alt)},n.prototype.ctrlKeyPressed=function(t){return!!(t&pt.Control)},n.prototype.shiftKeyPressed=function(t){return!!(t&pt.Shift)},n.prototype.scrolled=function(t){this.diagram.updateScrollOffset()},n.prototype.doubleClick=function(t){if(Wv(this.diagram)){var e=void 0,i=this.diagram.findObjectsUnderMouse(this.currentPosition),r=this.diagram.findObjectUnderMouse(i,this.action,this.inAction);if(null!==r&&Wv(this.diagram))if(e=this.diagram.findElementUnderMouse(r,this.currentPosition,this.diagram),this.tool&&(this.tool instanceof Ph||this.tool instanceof zh))this.tool.mouseUp(this.eventArgs),this.isMouseDown=!1,this.eventArgs={},this.tool=null,t.preventDefault();else{var o=this.diagram.commandHandler.getObjectLayer(r.id);!o||o.lock||!o.visible||this.diagram.diagramActions&ee.TextEdit||this.diagram.startTextEdit(r,e instanceof ni?e.id.split(r.id+"_")[1]:void 0)}this.diagram.triggerEvent(Ce.doubleClick,{source:r||this.diagram,position:this.currentPosition,count:t.detail})}},n.prototype.itemClick=function(t,e){var i=t;return cs(this.diagram,i,!0)?i:null},n.prototype.inputChange=function(t){var i,s,o,a,l,h,c,d,u,p=document.getElementById(this.diagram.element.id+"_editBox"),f=document.getElementById(this.diagram.element.id+"_editTextBoxDiv"),g=p.value,v=g.split("\n");(!(a=this.diagram.selectedItems.nodes[0]?this.diagram.selectedItems.nodes[0]:this.diagram.selectedItems.connectors[0])&&this.tool instanceof qI||a&&"SwimLane"===a.shape.type)&&(a=this.diagram.nameTable[this.diagram.activeLabel.parentId]),a&&("Text"!==a.shape.type&&a.annotations.length>0||"Text"===a.shape.type)&&(c=HF((o=this.diagram.getWrapper(a.wrapper,this.diagram.activeLabel.id)).style,g,void 0,void 0,i=(i=a.wrapper.bounds.width90?i:90),s=Number(p.style.fontSize.split("px")[0]),v.length>1&&""===v[v.length-1]&&(c.height=c.height+s),d=this.diagram.scroller.transform,u=P3(this.diagram)?d.scale:1,l=(12>c.height?12:c.height)*u,f.style.left=(o.bounds.center.x+d.tx)*d.scale-(h=(90>(h=c.width)?90:h)*u)/2-2.5+"px",f.style.top=(o.bounds.center.y+d.ty)*d.scale-l/2-3+"px",f.style.width=h+"px",f.style.height=l+"px",p.style.minHeight="12px",p.style.minWidth="90px",p.style.width=h+"px",p.style.height=l+"px")},n.prototype.isAddTextNode=function(t,e){return!(!(this.tool instanceof qI||e)||(this.tool=null,t&&!BI(this.diagram)&&(this.diagram.drawingObject=void 0,this.diagram.currentDrawingObject=void 0),MF(this.diagram.nodes,t.id)||MF(this.diagram.connectors,t.id)))},n.prototype.checkEditBoxAsTarget=function(t){return!(!t.target||t.target.id!==this.diagram.element.id+"_editBox")},n.prototype.getMouseEventArgs=function(t,e,i,r){var s,o,a;if(e.position=t,i?(o=this.diagram.findObjectsUnderMouse(this.currentPosition,i),s=this.diagram.findTargetObjectUnderMouse(o,this.action,this.inAction,e.position,i)):"Drag"===this.action||"ConnectorSourceEnd"===this.action||"SegmentEnd"===this.action||"OrthoThumb"===this.action||"BezierSourceThumb"===this.action||"BezierTargetThumb"===this.action||"ConnectorTargetEnd"===this.action||-1!==this.action.indexOf("Rotate")||-1!==this.action.indexOf("Resize")?(s=this.diagram.selectedItems,!this.diagram.currentSymbol&&"Drag"===this.action&&s&&this.diagram.selectedItems.nodes.length>0&&"SwimLane"===this.diagram.selectedItems.nodes[0].shape.type&&(o=this.diagram.findObjectsUnderMouse(this.currentPosition),s=this.diagram.findObjectUnderMouse(o,this.action,this.inAction))):(o=this.diagram.findObjectsUnderMouse(this.currentPosition),s=this.diagram.findObjectUnderMouse(o,this.action,this.inAction)),s&&s.isHeader&&(this.eventArgs.actualObject=s=this.diagram.nameTable[s.parentId]),s){var l=void 0,h=void 0,c=void 0;if(((a=this.diagram.findElementUnderMouse(s,this.currentPosition,this.diagram,r))&&s.ports&&s.ports.length&&!ab(s,a)||!a||!s)&&o&&o.length&&i instanceof si)for(l=i.connectors[0],c=o.length-1;c>=0;c--)if(((h=o[parseInt(c.toString(),10)])instanceof te||h instanceof de)&&l&&l.connectionPadding){if(a=this.diagram.findElementUnderMouse(s=h,this.currentPosition,this.diagram,r),l.constraints&qe.ConnectToNearByPort&&s&&s.ports&&s.ports.length&&ab(s,a))break;if((h instanceof te||h instanceof de)&&l&&l.connectionPadding&&h.wrapper.outerBounds.containsPoint(this.currentPosition)&&l.constraints&qe.ConnectToNearByNode&&!(l.constraints&qe.ConnectToNearByPort)){a=this.diagram.findElementUnderMouse(s=h,this.currentPosition,this.diagram,0);break}}}return i?(e.target=s,e.targetWrapper=a):(e.source=s,e.sourceWrapper=a),e.actualObject=this.eventArgs.actualObject,e.source instanceof si&&void 0===e.actualObject&&(e.source.nodes.length>0||e.source.connectors.length>0)&&(e.actualObject=e.source.nodes.length>0?this.diagram.nameTable[e.source.nodes[0].id]:this.diagram.nameTable[e.source.connectors[0].id]),e.startTouches=this.touchStartList,e.moveTouches=this.touchMoveList,e},n.prototype.resetTool=function(){this.action="Select",this.hoverElement=null,this.hoverNode=null,this.tool=this.diagram.getTool(this.action),this.updateCursor()},n.prototype.updateTool=function(){this.eventArgs&&!this.eventArgs.position&&(this.action="Select")},n.prototype.getTool=function(t){switch(t){case"Select":return new Kv(this.commandHandler,!0);case"Drag":return new ua(this.commandHandler);case"Rotate":return new Xx(this.commandHandler);case"LayoutAnimation":return new Une(this.commandHandler);case"FixedUserHandle":return new _ne(this.commandHandler,!0);case"Hyperlink":return new eF(this.commandHandler);case"ResizeSouthEast":case"ResizeSouthWest":case"ResizeNorthEast":case"ResizeNorthWest":case"ResizeSouth":case"ResizeNorth":case"ResizeWest":case"ResizeEast":return new zd(this.commandHandler,t);case"ConnectorSourceEnd":case"ConnectorTargetEnd":case"BezierSourceThumb":case"BezierTargetThumb":return new Pd(this.commandHandler,t);case"SegmentEnd":case"OrthoThumb":return new r_(this.commandHandler,t);case"Draw":var e="shape",i=function gse(n){var t;return n&&(n.type?t="Connector":n.shape&&!n.type&&(t="Node")),t}(this.diagram.drawingObject);if("Node"===i&&"Text"===this.diagram.drawingObject.shape.type)return new qI(this.commandHandler);if("Connector"===i&&"Freehand"===this.diagram.drawingObject.type)return new Yne(this.commandHandler);if("Node"===i&&"Polygon"===this.diagram.drawingObject.shape[""+e]&&!this.diagram.drawingObject.shape.points)return new Ph(this.commandHandler);if("Node"===i||"Node"===i&&"Polygon"===this.diagram.drawingObject.shape[""+e]&&this.diagram.drawingObject.shape.points)return new XI(this.commandHandler,this.diagram.drawingObject);if("Connector"===i&&"Polyline"===this.diagram.drawingObject.type)return new zh(this.commandHandler);if("Connector"===i)return new pa(this.commandHandler,"ConnectorSourceEnd",this.diagram.drawingObject);break;case"Pan":return new em(this.commandHandler,!1);case"PinchZoom":return new em(this.commandHandler,!0);case"PortDrag":return new ua(this.commandHandler,"Port");case"PortDraw":return new pa(this.commandHandler,"ConnectorSourceEnd",this.diagram.drawingObject);case"LabelSelect":return new Kv(this.commandHandler,!0,"LabelSelect");case"LabelDrag":return new jne(this.commandHandler);case"LabelResizeSouthEast":case"LabelResizeSouthWest":case"LabelResizeNorthEast":case"LabelResizeNorthWest":case"LabelResizeSouth":case"LabelResizeNorth":case"LabelResizeWest":case"LabelResizeEast":return new Vne(this.commandHandler,t);case"LabelRotate":return new Wne(this.commandHandler)}return null},n.prototype.getCursor=function(t){var e=this.diagram.selectedItems.annotation?this.diagram.selectedItems.wrapper.children[0]:this.diagram.selectedItems;return function Fne(n,t){if(t+=360,t%=360,-1===n.indexOf("Resize"))return Gx[""+n];var e=Gx[""+n];return t>=0&&t<25||t>=160&&t<=205||t>=340&&t<=360?e:t>=25&&t<=70||t>=205&&t<=250?"n-resize"===e||"s-resize"===e?"ne-resize":"nw-resize"===e||"se-resize"===e?"n-resize":"e-resize"===e||"w-resize"===e?"nw-resize":"e-resize":t>=70&&t<=115||t>=250&&t<=295?"n-resize"===e||"s-resize"===e?"e-resize":"nw-resize"===e||"se-resize"===e?"ne-resize":"e-resize"===e||"w-resize"===e?"n-resize":"nw-resize":t>=115&&t<=155||t>=295&&t<=340?"n-resize"===e||"s-resize"===e?"nw-resize":"nw-resize"===e||"se-resize"===e?"e-resize":"e-resize"===e||"w-resize"===e?"ne-resize":Gx[""+n]:"n-resize"}(t,this.diagram.selectedItems.annotation?e.rotateAngle+e.parentTransform:e.rotateAngle)},n.prototype.findElementUnderMouse=function(t,e,i,r){return this.objectFinder.findElementUnderSelectedItem(t,e,i,r)},n.prototype.findObjectsUnderMouse=function(t,e){return this.objectFinder.findObjectsUnderMouse(t,this.diagram,this.eventArgs,e)},n.prototype.findObjectUnderMouse=function(t,e,i){return this.objectFinder.findObjectUnderMouse(this.diagram,t,e,i,this.eventArgs,this.currentPosition)},n.prototype.findTargetUnderMouse=function(t,e,i,r,s){return this.objectFinder.findObjectUnderMouse(this.diagram,t,e,i,this.eventArgs,r,s)},n.prototype.findActionToBeDone=function(t,e,i,r){return function kne(n,t,e,i,r,s,o){if(s&&s.length>1&&r&&r.length>1)return"PinchZoom";if(i.currentSymbol)return"Drag";if("PortDraw"===i.eventHandler.action&&(i.tool&=~Ci.DrawOnce),(k3(i)||BI(i))&&i.drawingObject)return"Draw";if(Xa(i)&&(l=i.selectedItems).wrapper&&qr(l.constraints,"UserHandle"))for(var h=0,c=l.userHandles;h=50&&(l.x=(a.points[parseInt(h.toString(),10)].x+a.points[h+1].x)/2,l.y=(a.points[parseInt(h.toString(),10)].y+a.points[h+1].y)/2,wr(e,l,n.hitPadding?n.hitPadding:10)))return"OrthoThumb"}else PI(n)&&console.warn('[WARNING] :: Module "ConnectorEditing" is not available in Diagram component! You either misspelled the module name or forgot to load it.');return null}(g,l,e,i);if("OrthoThumb"===S)return S;if(qr(l.constraints,"ConnectorSourceThumb")&&OI(g)&&S||qr(l.constraints,"ConnectorTargetThumb")&&kI(g)&&S)return S}}else{var b=i.selectedItems.handleSize/2/i.scroller.currentZoom,M=10/i.scroller.currentZoom,w=Hi();qi(w,p.rotateAngle+p.parentTransform,p.offsetX,p.offsetY);var C=p.offsetX-p.pivot.x*p.actualSize.width,D=p.offsetY-p.pivot.y*p.actualSize.height,A={x:C+(.5===p.pivot.x?2*p.pivot.x:p.pivot.x)*p.actualSize.width/2,y:D-30/i.scroller.currentZoom};A=Je(w,A);var x=!!i.selectedItems.annotation,R=!(!x||!zI(i.selectedItems.annotation));if(qr(l.constraints,"Rotate")&&wr(e,A,M)&&i.selectedItems.thumbsConstraints&bt.Rotate){if(x&&R)return"LabelRotate";if(!x)return"Rotate"}if(u.Inflate(b),u.containsPoint(e)&&(S=function Pne(n,t,e,i,r,s){var o;return 1===n.selectedItems.nodes.length&&0===n.selectedItems.connectors.length&&n.selectedItems.nodes[0].container&&(o=function Hne(n,t,e,i,r){var s=10/n.scroller.currentZoom,o=40/n.scroller.currentZoom,a=n.selectedItems,l=t.actualSize.width,h=t.actualSize.height,c=new Ne(i,r,t.style.strokeWidth,h),d=new Ne(i+l,r,t.style.strokeWidth,h),u=new Ne(i,r,l,t.style.strokeWidth),p=new Ne(i,r+h,l,t.style.strokeWidth),f=cs(n,n.selectedItems.nodes[0],!0)?n.nameTable[n.selectedItems.nodes[0].parentId]:n.selectedItems.nodes[0];if(l>=o&&h>=o){if(fa(a.constraints,"ResizeEast",a.thumbsConstraints,a)&&d.containsPoint(e,s))return"ResizeEast";if(fa(a.constraints,"ResizeSouth",a.thumbsConstraints,a)&&p.containsPoint(e,s))return"ResizeSouth";if("Grid"!==f.container.type){if(fa(a.constraints,"ResizeWest",a.thumbsConstraints,a)&&c.containsPoint(e,s))return"ResizeWest";if(fa(a.constraints,"ResizeNorth",a.thumbsConstraints,a)&&u.containsPoint(e,s))return"ResizeNorth"}}return null}(n,t,e,r,s)),!o&&(!n.selectedItems.nodes[0]||!n.selectedItems.nodes[0].isPhase&&!n.selectedItems.nodes[0].isLane&&"SwimLane"!==n.selectedItems.nodes[0].shape.type)&&(o=function Bne(n,t,e,i,r,s){var o=40/n.scroller.currentZoom,a=n.selectedItems.handleSize/2/n.scroller.currentZoom,l=n.selectedItems,h=!!l.annotation;if(t.actualSize.width>=o&&t.actualSize.height>=o){if(fa(l.constraints,"ResizeSouthEast",l.thumbsConstraints,l)&&wr(e,Je(i,{x:r+t.actualSize.width,y:s+t.actualSize.height}),a))return h?"LabelResizeSouthEast":"ResizeSouthEast";if(fa(l.constraints,"ResizeSouthWest",l.thumbsConstraints,l)&&wr(e,Je(i,{x:r,y:s+t.actualSize.height}),a))return h?"LabelResizeSouthWest":"ResizeSouthWest";if(fa(l.constraints,"ResizeNorthEast",l.thumbsConstraints,l)&&wr(e,Je(i,{x:r+t.actualSize.width,y:s}),a))return h?"LabelResizeNorthEast":"ResizeNorthEast";if(fa(l.constraints,"ResizeNorthWest",l.thumbsConstraints,l)&&wr(e,Je(i,{x:r,y:s}),a))return h?"LabelResizeNorthWest":"ResizeNorthWest"}return fa(l.constraints,"ResizeEast",l.thumbsConstraints,l)&&wr(e,Je(i,{x:r+t.actualSize.width,y:s+t.actualSize.height/2}),a)?h?"LabelResizeEast":"ResizeEast":fa(l.constraints,"ResizeWest",l.thumbsConstraints,l)&&wr(e,Je(i,{x:r,y:s+t.actualSize.height/2}),a)?h?"LabelResizeWest":"ResizeWest":fa(l.constraints,"ResizeSouth",l.thumbsConstraints,l)&&wr(e,Je(i,{x:r+t.actualSize.width/2,y:s+t.actualSize.height}),a)?h?"LabelResizeSouth":"ResizeSouth":fa(l.constraints,"ResizeNorth",l.thumbsConstraints,l)&&wr(e,Je(i,{x:r+t.actualSize.width/2,y:s}),a)?h?"LabelResizeNorth":"ResizeNorth":null}(n,t,e,i,r,s)),o||null}(i,p,e,w,C,D),S))return S}}if(Lc(i)&&!n)return"Pan";if((o instanceof Es||o instanceof xc)&&(!Lc(i)||jv(i)||Vv(i))&&(S=function Rne(n,t,e,i){if(_x(t)&&(ga(t,hi.Hover)||ga(t,hi.Visible))){if(t.constraints&ri.Drag)return"PortDrag"}else if(Fx(t)&&(ga(t,hi.Hover)||ga(t,hi.Visible))&&t.constraints&ri.Draw){n.drawingObject={};var r={type:"Orthogonal",sourcePortID:t.id};return n.drawingObject=r,n.tool|=Ci.DrawOnce,n.currentDrawingObject=r,"PortDraw"}return"None"}(i,o),"None"!==S))return S;if((o instanceof Zn||o instanceof Nr)&&!Lc(i)&&Td(o))return _r(i,o,void 0,t)&&to(o)?"LabelDrag":"LabelSelect";if(null!==n){if(!(n instanceof te||n instanceof de))return"Select";if(t&&t.id){var L=t.id.split(n.id)[1];if(L&&L.match("^_icon"))return"LayoutAnimation"}if(t&&t.id)for(var O=void 0,N=0;N-1)return"FixedUserHandle";if(t instanceof ni&&t.hyperlink.link)return"Hyperlink";if(!to(n)||!_r(i,n,!1)||void 0!==i.selectedItems.annotation)return n&&Lc(i)&&!FI(i)?"Pan":i.selectedItems.nodes.length&&i.selectedItems.nodes[0].isLane&&i.selectedItems.wrapper&&i.selectedItems.wrapper.bounds.containsPoint(e)?"Drag":"Select";if(n instanceof de&&!wr(e,n.sourcePoint,n.hitPadding)&&!wr(e,n.targetPoint,n.hitPadding)||!(n instanceof de))return"Drag"}return"Select"}(t,e,this.currentPosition,this.diagram,this.touchStartList,this.touchMoveList,r)},n.prototype.updateContainerBounds=function(t){var e=!1;if(this.diagram.selectedObject.helperObject&&this.diagram.selectedObject.actualObject instanceof te){var i=this.tool instanceof zd,r=this.diagram.selectedObject.actualObject,s=this.diagram.nameTable[r.parentId];t?q3(this.diagram,r,this.currentPosition,i):((!s||s&&"SwimLane"!==s.shape.type)&&this.diagram.updateDiagramObject(r),e=function Ane(n,t,e,i){var r,o=!1;if(cs(n,t,!0)){n.protectPropertyChange(!0);var a=(r=n.nameTable[t.parentId]).wrapper;if(r&&"Canvas"===r.container.type){if(i||a.bounds.x<=e.x&&a.bounds.right>=e.x&&a.bounds.y<=e.y&&a.bounds.bottom>=e.y){var l=void 0,h=a.bounds.y,c=a.bounds.x,d=n.nameTable[r.parentId]||r;if("SwimLane"===d.shape.type)o=Jv(r,d,t,n,!0);else{var p=n.nameTable[r.parentId]||r,f=p.shape;l=p.wrapper,a.actualSize.widtha.outerBounds.x)&&(void 0!==r.rowIndex?(l.updateColumnWidth(r.columnIndex,a.outerBounds.width,!0),"Horizontal"===f.orientation&&f.phaseSize&&WI(p,n,a,r.columnIndex),Oc(n,p),n.drag(p,c-a.bounds.x,h-a.bounds.y)):n.scale(r,1+(a.outerBounds.width-a.actualSize.width)/a.actualSize.width,1,a.outerBounds.xa.outerBounds.y)&&(void 0!==r.rowIndex?(l.updateRowHeight(r.rowIndex,a.outerBounds.height,!0),n.drag(p,c-a.bounds.x,h-a.bounds.y)):n.scale(r,1,1+(a.outerBounds.height-a.actualSize.height)/a.actualSize.height,a.outerBounds.yi.y&&(h+=u>0?-1:1,u+=u>0?-1:1):i&&e.wrapper.offsetYi.x&&(h+=u>0?-1:1,u+=u>0?-1:1):i&&e.wrapper.offsetX1&&!(this.diagram.lineRoutingModule&&this.diagram.constraints&rt.LineRouting))for(var b=t.offsetX-this.diagram.selectedItems.offsetX,M=t.offsetY-this.diagram.selectedItems.offsetY,w=t.rotateAngle-this.diagram.selectedItems.rotateAngle,C=0;C-1){var x=c.children;x.splice(x.indexOf(o.id),1),this.diagram.nameTable[o.id].parentId="",i=!0,c.wrapper.children.splice(A,1)}}if(function One(n,t,e,i){var r=n,s=e.nameTable[r.parentId],o=e.nameTable[r.parentId];if(t&&o&&o.container&&"Stack"===o.container.type&&t.container&&"Stack"===t.container.type&&o.id!==t.parentId){var a=o.wrapper.children.indexOf(r.wrapper);a>-1&&(e.nameTable[r.id].parentId=t.id,o.wrapper.children.splice(a,1))}if(t&&t.parentId&&r.parentId&&"Drag"===i&&o.container&&"Stack"===o.container.type){var l=s.wrapper.children.indexOf(t.wrapper),h=s.wrapper.children.indexOf(r.wrapper),c={targetIndex:l,target:t,sourceIndex:h,source:n};s.wrapper.children.splice(h,1),s.wrapper.children.splice(l,0,r.wrapper),e.commandHandler.addHistoryEntry({type:"StackChildPositionChanged",redoObject:{targetIndex:h,target:t,sourceIndex:l,source:n},undoObject:c,category:"Internal"})}}(o,h,this.diagram,this.action),(c=cs(this.diagram,o)?this.diagram.nameTable[o.parentId]:this.diagram.nameTable[o.parentId]||o)&&c.container&&"Canvas"===c.container.type&&(c.wrapper.maxWidth=c.maxWidth=c.wrapper.actualSize.width,c.wrapper.maxHeight=c.maxHeight=c.wrapper.actualSize.height,e=!0),cs(this.diagram,o,!0)&&c&&"Canvas"===c.container.type)if(this.diagram.selectedItems.nodes.length>1)for(C=0;C0)for(var i=0;i0&&e.columnIndex>0||l&&e.isLane)){if("Horizontal"===t.container.orientation&&e.isPhase&&e.wrapper.width>e.maxWidth&&(e.maxWidth=e.wrapper.width,e.wrapper.maxWidth=e.wrapper.width),h.updateColumnWidth(e.columnIndex,r.width,!0,c),Vx(this.diagram,e,t),e.isPhase){var f=this.diagram.nameTable[""+t.shape.phases[e.columnIndex].header.id];f.maxWidth0?(r=new of(t,"",u),t.shape.classShape.attributes.push(r)):i.id.includes("_umlMethods")&&t.shape.classShape.methods.length>0&&(s=new dm(t,"",u),t.shape.classShape.methods.push(s))),"Interface"===t.shape.classifier&&(i.id.includes("_umlProperty")&&t.shape.interfaceShape.attributes.length>0?(r=new of(t,"",u),t.shape.classShape.attributes.push(r)):i.id.includes("_umlMethods")&&t.shape.interfaceShape.methods.length>0&&(s=new dm(t,"",u),t.shape.interfaceShape.methods.push(s))),"Enumeration"===t.shape.classifier&&i.id.includes("_umlMember")&&t.shape.enumerationShape.members.length>0){var p=new cb(t,"",u);t.shape.enumerationShape.members.push(p)}t.wrapper.children.indexOf(c.wrapper),this.diagram.enableServerDataBinding(!0),this.diagram.add(c),this.diagram.updateConnectorEdges(t),this.diagram.clearSelection(),this.diagram.select([this.diagram.nameTable[c.id]]),this.diagram.endGroupAction(),this.diagram.startTextEdit()}}},n}(),Zoe=function(){function n(){}return n.prototype.findObjectsUnderMouse=function(t,e,i,r,s){var o=[];r&&r instanceof si&&r.nodes.length+r.connectors.length===1&&(r=r.nodes[0]||r.connectors[0]).children&&0===r.children.length&&(i.actualObject=r);for(var a,l,h,c,f,d=r&&r instanceof de&&(r.constraints&qe.ConnectToNearByNode||r.constraints&qe.ConnectToNearByPort)&&r.connectionPadding||0,p={},g=0,v=e.spatialSearch.findObjects(new Ne(t.x-50-d,t.y-50-d,100+d,100+d));g-1&&o.splice(T,1),"UmlClassifier"===y.shape.type&&y.container&&"Stack"===y.container.type&&(T=o.indexOf(e.nameTable[e.nameTable[y.id].wrapper.children[0].id]))>-1&&o.splice(T,1)}for(var P=0;Ps.zIndex&&(t[parseInt(r.toString(),10)]=l),r>0&&i&&a&&(a.isLane||a.isPhase||a.isHeader)&&t[parseInt(r.toString(),10)].zIndex=2)for(var d=t.length-1;d>=0;d--)if(t[parseInt(d.toString(),10)].parentId){var u=am(t[parseInt(d.toString(),10)],e,""),p=am(t[d-1],e,""),g=e.nameTable[""+p];g&&u!==p&&e.nameTable[""+u].zIndex=0;f--){d=tf(e[parseInt(f.toString(),10)],!1),c=tf(e[parseInt(f.toString(),10)],!0);var g=t[""+l].tool,v=this.findTargetElement(e[parseInt(f.toString(),10)].wrapper,o,t,void 0);if("Draw"===i&&v&&(e[parseInt(f.toString(),10)]instanceof te||e[parseInt(f.toString(),10)]instanceof de)&&!ab(e[parseInt(f.toString(),10)],v)&&(g&&"ConnectorSourceEnd"===g[""+h]&&!kh(e[parseInt(f.toString(),10)])||g&&"ConnectorTargetEnd"===g[""+h]&&!da(e[parseInt(f.toString(),10)])))return u;if(e[parseInt(f.toString(),10)]instanceof te||e[parseInt(f.toString(),10)]instanceof de&&(kh(e[parseInt(f.toString(),10)])||Ad(d)||da(e[parseInt(f.toString(),10)])||Oh(c)||"PortDraw"===i&&g instanceof Pd&&"ConnectorTargetEnd"===g[""+h]&&(da(e[parseInt(f.toString(),10)])||Oh(c))))return u=e[parseInt(f.toString(),10)],p&&(u=this.isTarget(u,t,i)),s.actualObject=u,u}else if("ConnectorTargetEnd"===i&&a){for(f=e.length-1;f>=0;f--)if(c=tf(e[parseInt(f.toString(),10)],!0),(e[parseInt(f.toString(),10)]instanceof te||e[parseInt(f.toString(),10)]instanceof de)&&(da(e[parseInt(f.toString(),10)])||Oh(c)))return u=e[parseInt(f.toString(),10)],u=this.isTarget(u,t,i),s.actualObject=u,u}else{if(a&&("Drag"===i||t[""+l].tool instanceof ua)){var y=0;for(f=0;f=S.zIndex?u:S,y=Math.max(y,S.zIndex)):y=(u=S).zIndex)}return u&&"Bpmn"===u.shape.type&&(t.selectedItems.nodes.length>0&&"Bpmn"===t.selectedItems.nodes[0].shape.type||(u=null)),u&&(s.actualObject=u),u}if("Select"!==i&&"Pan"!==i||!t[""+l].tool)if("Pan"===i||"LayoutAnimation"===i){for(f=e.length-1;f>=0;f--)if((e[parseInt(f.toString(),10)]instanceof te||e[parseInt(f.toString(),10)]instanceof de)&&(v=this.findTargetElement(e[parseInt(f.toString(),10)].wrapper,o,t,void 0),"Pan"===i||v&&(v.id.match("_icon_content_shape$")||v.id.match("_icon_content_rect$"))))return e[parseInt(f.toString(),10)]}else u=e[e.length-1],s&&u&&(s.actualObject=u);else{for(f=e.length-1;f>=0;f--)if(e[parseInt(f.toString(),10)]instanceof de){var b=e[f-1];if(e[f-1]instanceof te&&b.ports){if((v=this.findTargetElement(b.wrapper,o,t,void 0))&&(v.id.match("_icon_content_shape$")||v.id.match("_icon_content_rect$")))return b;for(var M=0;M=0;s--){var o=t.children[parseInt(s.toString(),10)];if(o&&o.outerBounds.containsPoint(e,r||0))if(o.visible){if(o instanceof Cs){var a=this.findTargetElement(o,e,i);if(a)return a}var l="Clip"===o.style.textOverflow||"Ellipsis"===o.style.textOverflow;if(o.bounds.containsPoint(e,r||0)&&!l)return o;if(t.bounds.containsPoint(e,r||0)&&l)return o}else if(o instanceof Ke&&t&&t.id){var h=void 0;if(t.id.includes("group_container")){var c=t.id.slice(0,-15);h=i.getObject(c)}else h=i.getObject(t.id);if(sb(h,o.id))return o}}return t.bounds.containsPoint(e,r)&&"none"!==t.style.fill?t:null},n}(),Joe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),lf=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},n_=function(n){function t(e,i,r,s){var o=n.call(this,e,i,r,s)||this;return o.objectZIndex=-1,o.zIndexTable={},o.objects=[],o}return Joe(t,n),lf([I("")],t.prototype,"id",void 0),lf([I(!0)],t.prototype,"visible",void 0),lf([I(!1)],t.prototype,"lock",void 0),lf([I()],t.prototype,"objects",void 0),lf([I()],t.prototype,"addInfo",void 0),lf([I(-1)],t.prototype,"zIndex",void 0),t}(Ee),ET=function(n,t,e,i){return new(e||(e=Promise))(function(r,s){function o(h){try{l(i.next(h))}catch(c){s(c)}}function a(h){try{l(i.throw(h))}catch(c){s(c)}}function l(h){h.done?r(h.value):new e(function(c){c(h.value)}).then(o,a)}l((i=i.apply(n,t||[])).next())})},DT=function(n,t){var i,r,s,o,e={label:0,sent:function(){if(1&s[0])throw s[1];return s[1]},trys:[],ops:[]};return o={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function a(h){return function(c){return function l(h){if(i)throw new TypeError("Generator is already executing.");for(;e;)try{if(i=1,r&&(s=2&h[0]?r.return:h[0]?r.throw||((s=r.return)&&s.call(r),0):r.next)&&!(s=s.call(r,h[1])).done)return s;switch(r=0,s&&(h=[2&h[0],s.value]),h[0]){case 0:case 1:s=h;break;case 4:return e.label++,{value:h[1],done:!1};case 5:e.label++,r=h[1],h=[0];continue;case 7:h=e.ops.pop(),e.trys.pop();continue;default:if(!(s=(s=e.trys).length>0&&s[s.length-1])&&(6===h[0]||2===h[0])){e=0;continue}if(3===h[0]&&(!s||h[1]>s[0]&&h[1]1)for(var i=0;i-1)return e[parseInt(i.toString(),10)];return this.diagram.activeLayer},n.prototype.getLayer=function(t){for(var e=this.diagram.layers,i=0;i=0;o--)this.diagram.unSelect(this.diagram.nameTable[s[parseInt(o.toString(),10)]]),this.diagram.remove(this.diagram.nameTable[s[parseInt(o.toString(),10)]]),"default_layer"!==i.id&&this.diagram.activeLayer.id===t&&(this.diagram.activeLayer=this.diagram.layers[this.diagram.layers.length-1]);delete this.diagram.layerZIndexTable[i.zIndex],this.diagram.layers.splice(r,1),"SVG"!==this.diagram.mode&&this.diagram.refreshDiagramLayer()}},n.prototype.moveObjects=function(t,e){this.diagram.startGroupAction();for(var i={},r=[],s=0;s-1){if(r=[],(h=this.diagram.nameTable[""+s]).children)for(var f=0,g=h.children;f0){for(var y=void 0,S=0,b=r;S0)for(var r=0;r0)for(r=0;r0){t=t.concat(this.diagram.selectedItems.connectors);for(var i=0;i0)for(t=t.concat(this.diagram.selectedItems.nodes),i=0;i0){for(var i=0,r=t.shape.activity.subProcess.processes;i0&&this.copyProcesses(this.processTable[""+s])}this.clipboardData.processTable=this.processTable}},n.prototype.group=function(){this.oldSelectedObjects=sm(this.diagram);var e=this.diagram.isProtectedOnChange;this.diagram.protectPropertyChange(!0),this.diagram.diagramActions=this.diagram.diagramActions|ee.Group;var r={};r.id="group"+Qe(),(r=new te(this.diagram,"nodes",r,!0)).children=[];for(var s=this.diagram.selectedItems.nodes.concat(this.diagram.selectedItems.connectors).sort(function(h,c){return h.zIndex-c.zIndex}),o=0;o0){var a=this.diagram.add(r);a&&this.select(a),this.addHistoryEntry({type:"Group",undoObject:r,redoObject:r,category:"Internal"}),this.diagram.diagramActions=this.diagram.diagramActions&~ee.Group,this.diagram.protectPropertyChange(e)}},n.prototype.unGroup=function(t){var i=this.diagram.isProtectedOnChange;this.diagram.protectPropertyChange(!0),this.diagram.diagramActions=this.diagram.diagramActions|ee.Group;var r=[];t?r.push(t):r=this.diagram.selectedItems.nodes,this.diagram.startGroupAction();for(var s=0;s0&&this.diagram.removePorts(o,o.ports),o.annotations&&o.annotations.length>0&&!ce()&&this.diagram.removeLabels(o,o.annotations);for(var c=this.diagram.nameTable[o.parentId],d=o.children.length-1;d>=0;d--)this.diagram.nameTable[o.children[parseInt(d.toString(),10)]].parentId="",this.diagram.deleteChild(this.diagram.nameTable[o.children[parseInt(d.toString(),10)]],o),o.parentId&&o.children[parseInt(d.toString(),10)]&&this.diagram.addChild(c,o.children[parseInt(d.toString(),10)]);this.resetDependentConnectors(o.inEdges,!0),this.resetDependentConnectors(o.outEdges,!1),this.diagram.diagramActions&ee.UndoRedo||this.addHistoryEntry({type:"UnGroup",undoObject:a,redoObject:a,category:"Internal"}),o.parentId&&this.diagram.deleteChild(o,c)}this.diagram.removeNode(o,l),this.clearSelection()}this.diagram.endGroupAction(),this.diagram.diagramActions=this.diagram.diagramActions&~ee.Group,this.diagram.protectPropertyChange(i)},n.prototype.resetDependentConnectors=function(t,e){for(var i=0;i0&&(g=!1)}if(g){var y=this.cloneConnector(p,i);c.push(y),o[h.id]=y.id}}else{var S=this.cloneNode(h,i);if(c.push(S),S){o[h.id]=S.id;var b=h.inEdges;if(b)for(var M=0,w=b;M0)for(var u=0;u0)for(r=t.segments,s=0;s0&&this.diagram.drawingObject&&"Bezier"===this.diagram.drawingObject.type&&(t.segments=[]);var e=this.diagram.add(t);"SVG"!==this.diagram.mode&&this.diagram.refreshDiagramLayer(),this.selectObjects([e]),t&&!BI(this.diagram)&&(this.diagram.tool&=~Ci.DrawOnce,this.diagram.currentDrawingObject=void 0)},n.prototype.enableServerDataBinding=function(t){this.diagram.enableServerDataBinding(t)},n.prototype.addText=function(t,e){var i=this.diagram.findElementUnderMouse(t,e,this.diagram);this.diagram.startTextEdit(t,i instanceof ni?i.id.split("_")[1]:void 0)},n.prototype.isUserHandle=function(t){var e=this.diagram.selectedItems;if(e.wrapper&&qr(e.constraints,"UserHandle"))for(var i=0,r=e.userHandles;i0&&t[0]&&t[0].isLane)for(s=this.diagram.getObject(t[0].parentId),t[0].shape.header=[],a=0;a1||e&&1===t.length)){if(1!==t.length)return[2];this.clearSelection()}if(!(u||d||1!==t.length||e&&Xa(this.diagram)))return this.clearSelection(),[2]}if(!r.cancel){for(p=0;p0||e)&&f.children&&!f.parentId)for(g=0;g0||e,!0)}else this.select(f,p>0||e,!0);void 0===i&&(i=c),r={oldValue:i||[],newValue:this.getSelectedObject(),cause:this.diagram.diagramActions,state:"Changed",type:"Addition",cancel:!1},this.diagram.renderSelector(e||t&&t.length>1),ce()||this.diagram.triggerEvent(Ce.selectionChange,r),this.diagram.enableServerDataBinding(!0)}return[2]})})},n.prototype.findParent=function(t){return t.parentId&&this.findParent(t=this.diagram.nameTable[t.parentId]),t},n.prototype.selectProcesses=function(t){if(this.hasProcesses(t))for(var e=t.shape.activity.subProcess.processes,i=0;i0)},n.prototype.select=function(t,e,i){var r=this.getObjectLayer(t.id);if(Td(t)&&!(t instanceof si)&&!_r(this.diagram,t)&&r&&!r.lock&&r.visible&&t.wrapper.visible){(e=!!Xa(this.diagram)&&e)||this.clearSelection(),this.diagram.enableServerDataBinding(!1);var s=this.diagram.selectedItems;if(t instanceof te?s.nodes.push(t.isHeader?this.diagram.nameTable[t.parentId]:t):s.connectors.push(t),s.selectedObjects.push(t),e)s.wrapper.rotateAngle=s.rotateAngle=0,s.wrapper.children.push(t.wrapper);else if(s.init(this.diagram),1===s.nodes.length&&0===s.connectors.length){var l=Wx(this.diagram,s);l&&(s.wrapper.children[0]=l),s.rotateAngle=s.nodes[0].rotateAngle,s.wrapper.rotateAngle=s.nodes[0].rotateAngle,s.wrapper.pivot=s.nodes[0].pivot}i||this.diagram.renderSelector(e),this.diagram.enableServerDataBinding(!0)}},n.prototype.labelSelect=function(t,e){this.oldSelectedObjects=sm(this.diagram);var i=this.diagram.selectedItems,r=this.diagram.allowServerDataBinding;this.diagram.allowServerDataBinding=!1,i.nodes=i.connectors=[],this.diagram.allowServerDataBinding=r,t instanceof te?i.nodes[0]=t:i.connectors[0]=t,i.annotation=this.findTarget(e,t),i.init(this.diagram),this.diagram.renderSelector(!1)},n.prototype.unSelect=function(t){var e=this.diagram.selectedItems.nodes.concat(this.diagram.selectedItems.connectors),i=e.filter(function(a){return a.id!==t.id}),r={oldValue:e,newValue:i,cause:this.diagram.diagramActions,state:"Changing",type:"Removal",cancel:!1};if(this.diagram.currentSymbol||ce()||this.diagram.triggerEvent(Ce.selectionChange,r),_r(this.diagram,t)){var s=this.diagram.selectedItems,o=void 0;t instanceof te?(o=s.nodes.indexOf(t,0),s.nodes.splice(o,1)):(o=s.connectors.indexOf(t,0),s.connectors.splice(o,1)),o=s.selectedObjects.indexOf(t,0),s.selectedObjects.splice(o,1),(r={oldValue:e,newValue:i,cause:this.diagram.diagramActions,state:"Changed",type:"Removal",cancel:(r={oldValue:e,newValue:i,cause:this.diagram.diagramActions,state:"Changed",type:"Removal",cancel:!1}).cancel}).cancel||(o=s.wrapper.children.indexOf(t.wrapper,0),s.wrapper.children.splice(o,1),this.diagram.updateSelector(),this.diagram.currentSymbol||this.diagram.triggerEvent(Ce.selectionChange,r))}},n.prototype.moveSvgNode=function(t,e){var i=xt(e+"_groupElement",this.diagram.element.id),r=xt(t+"_groupElement",this.diagram.element.id);i.parentNode.insertBefore(r,i)},n.prototype.moveAfterSvgNode=function(t,e){var i=xt(e+"_groupElement",this.diagram.element.id),r=xt(t+"_groupElement",this.diagram.element.id);i.insertAdjacentElement("afterend",r)},n.prototype.sendLayerBackward=function(t){var e=this.getLayer(t);if(e&&0!==e.zIndex){var i=e.zIndex;if("SVG"===this.diagram.mode){var r=e.objects,s=this.getLayer(this.diagram.layerZIndexTable[i-1]).objects[0];if(s)for(var o=0,a=r;od&&"SwimLane"!==f.shape.type){var S=$(f);f.zIndex=d-((-1!==i.indexOf(f)?i.indexOf(f):0)+1),f.children&&(d=this.findLowestZIndex(f,c)||d),this.triggerOrderCommand(S,f,f),f.children&&this.updateGroupZindex(f,"SendToBack",d)}else"SwimLane"===f.shape.type&&(y=this.swapZIndexObjects(a,h,r,g));if("SVG"===this.diagram.mode){for(var M="SwimLane"!==this.diagram.nameTable[""+r].shape.type?d:y,w=h[parseInt(M.toString(),10)];!w&&Md)&&(d=p.zIndex)}for(var f=JSON.parse(JSON.stringify(l)),v=Number(Object.keys(l).sort(function(wo,Hl){return Number(wo)-Number(Hl)}).reverse()[0]),y=this.diagram.nameTable[""+e].zIndex,S=[],M=0;M<=v;M++)S.push(l[parseInt(M.toString(),10)]);if("SwimLane"===this.diagram.nameTable[""+e].shape.type)for(var C=v;C>=y;C--)if(l[parseInt(C.toString(),10)]&&this.diagram.nameTable[l[parseInt(C.toString(),10)]].parentId!==e){v=C;break}var D=this.diagram.nameTable[""+e];if(D.zIndexx&&(x=L.zIndex)}}else x=d;D.zIndex=x+((-1!==r.indexOf(D)?r.indexOf(D):0)+1),this.triggerOrderCommand(A,D,D)}else if("SwimLane"===D.shape.type){for(var O=0,N=-1,T=0,P=0,_=JSON.parse(JSON.stringify(l)),B=0;B<=y;B++)if(l[parseInt(B.toString(),10)]&&this.diagram.nameTable[l[parseInt(B.toString(),10)]].parentId===e&&-1===N){N=B,T=B;break}for(var j=0;j<=v;j++)f[parseInt(j.toString(),10)]&&f[parseInt(j.toString(),10)]!==e&&this.diagram.nameTable[f[parseInt(j.toString(),10)]].parentId!==e&&this.diagram.nameTable[f[parseInt(j.toString(),10)]].zIndex>=this.diagram.nameTable[""+e].zIndex&&O++;for(var ue=N,pe=0;pe<=O;pe++){for(;!l[parseInt(ue.toString(),10)];)ue++;P=this.diagram.nameTable[l[parseInt(ue.toString(),10)]].zIndex,ue++}for(var Me=P;Me<=v;Me++){for(;!_[parseInt(N.toString(),10)];)N++;for(;!l[parseInt(Me.toString(),10)];)Me++;l[parseInt(Me.toString(),10)]=_[parseInt(N.toString(),10)],this.diagram.nameTable[l[parseInt(Me.toString(),10)]].zIndex=Me,N++}l[parseInt(v.toString(),10)]=this.diagram.nameTable[""+e].id,this.diagram.nameTable[""+e].zIndex=v,ue=y+1;for(var De=T,xe=0;xe0&&("Native"===hr[0].shape.type||"HTML"===hr[0].shape.type)){for(Mi.parentNode.removeChild(Mi),De=0;De0?r[0]:null},n.prototype.findLowestZIndex=function(t,e){var r=this.diagram.nodes.filter(function(s){return-1!==e.indexOf(s.id)}).filter(function(s){return""===s.parentId&&s.id!==t.id}).map(function(s){return s.zIndex});return r.sort(function(s,o){return s-o}),r.length>0?r[0]:null},n.prototype.triggerOrderCommand=function(t,e,i){var s={zIndex:$(t).zIndex},o={zIndex:e.zIndex},a={element:i,cause:this.diagram.diagramActions,diagramAction:this.diagram.getDiagramAction(this.diagram.diagramActions),oldValue:s,newValue:o};this.diagram.triggerEvent(Ce.propertyChange,a)},n.prototype.checkGroupNode=function(t,e,i){return i[""+e].parentId===i[""+t].parentId},n.prototype.sortByZIndex=function(t,e,i){if("BringForward"===i){var r=e||"zIndex";t=t.sort(function(o,a){return a[""+r]-o[""+r]})}else{var s=e||"zIndex";t=t.sort(function(o,a){return o[""+s]-a[""+s]})}return t},n.prototype.orderCommands=function(t,e,i){var r=this,s=e.nodes;if(s=s.concat(e.connectors),t)if("SendBackward"===i)for(var o=0;oa}),S=v.filter(function(D){return D0?Math.max.apply(Math,S):a,M=y.length>0?Math.min.apply(Math,y):a;if(a!==M){var w=c.zIndexTable[parseInt(M.toString(),10)],C=c.zIndexTable[parseInt(a.toString(),10)];this.moveSvgNode(C,w)}else"SendToBack"===i&&(w=c.zIndexTable[parseInt(a.toString(),10)],C=c.zIndexTable[parseInt(b.toString(),10)],this.moveAfterSvgNode(w,C))}}else this.diagram.refreshCanvasLayers()}},n.prototype.sendForward=function(t){var e=this;if(this.diagram.protectPropertyChange(!0),Xa(this.diagram)||t){$(t||(this.diagram.selectedItems.nodes.length?this.diagram.selectedItems.nodes[0]:this.diagram.selectedItems.connectors[0]));var s=t&&t.id,o=this.diagram.layers.indexOf(this.getObjectLayer(s=s||(this.diagram.selectedItems.nodes.length?this.diagram.selectedItems.nodes[0].id:this.diagram.selectedItems.connectors[0].id))),a=$(this.diagram.nameTable),h=(parseInt(o.toString(),10),this.diagram.nameTable[""+s]),c=[],d=this.diagram.spatialSearch.findObjects(h.wrapper.bounds);d.length>2&&(d=this.sortByZIndex(d,void 0,"BringForward"));for(var u=0,p=d;u=0;f--)this.diagram.nameTable[c[parseInt(f.toString(),10)].id].parentId===s&&c.splice(f,1);if(c.length>0){var y=this.diagram.nameTable[c[c.length-1].id];if(y.parentId){var b=am(y,this.diagram,""),M=this.diagram.nameTable[""+b];M.id!==s&&(c[0]=M)}var w={};for(f=0;f0&&(Object.values(O).forEach(function(ue){ue>=T&&N.push(ue)}),0!==N.length&&this.updateZIndexBySendForward(h,N,o))}var P=[];if(Object.keys(this.changedNodeZIndexes).forEach(function(ue){if((a[""+ue]?a[""+ue].zIndex:null)!==e.changedNodeZIndexes[""+ue]){var De=$(a[""+ue]);P.push(De)}}),this.updateLayerZindexTable(o),L.nodes.splice(0,L.nodes.length),P.forEach(function(ue){var pe=$(ue);L.nodes.push(pe)}),"SVG"===this.diagram.mode){var _=c[c.length-1].id,B=c[c.length-1];B&&!("HTML"===B.shape.type||"Native"===B.shape.type)&&this.moveAfterSvgNode(s,_),this.updateNativeNodeIndex(_,s)}else this.diagram.refreshCanvasLayers();var j=[];Object.keys(this.changedNodeZIndexes).forEach(function(ue){if((a[""+ue]?a[""+ue].zIndex:null)!==e.changedNodeZIndexes[""+ue]){var De=$(e.diagram.nameTable[""+ue]);j.push(De)}});var Q=$(this.diagram.selectedItems);Q.nodes.splice(0,Q.nodes.length),j.forEach(function(ue){var pe=$(ue);Q.nodes.push(pe)}),this.diagram.diagramActions&ee.UndoRedo||this.addHistoryEntry({type:"SendForward",category:"Internal",undoObject:L,redoObject:Q}),this.diagram.endGroupAction()}}this.diagram.protectPropertyChange(!1)},n.prototype.updateZIndexBySendForward=function(t,e,i){var r=$(t);t.zIndex=Math.min.apply(Math,e);var a,s=Math.min.apply(Math,e),o=Math.min.apply(Math,e),l=this.diagram.layers[parseInt(i.toString(),10)].objects,h=this.diagram.nodes.filter(function(S){return-1!==l.indexOf(S.id)});t.children&&this.updateGroupZindex(t,"BringForward",t.zIndex);var c=h.filter(function(S){return S.zIndex===Math.min.apply(Math,e)&&S.id!==t.id});if(c&&c.length>0&&c[0].children){for(var d=Math.min.apply(Math,e),u=0;uo&&g!==t&&g.parentId!==t.id&&c&&c.length>0&&g.parentId!==c[0].id){var v=$(g);g.zIndex=a+1,a++,this.triggerOrderCommand(v,g,g)}var y=g.zIndex;this.changedNodeZIndexes[g.id]=(this.changedNodeZIndexes.hasOwnProperty(g.id),y)}},n.prototype.arrangeZIndexForLowerNodes=function(t,e,i){var r=i.filter(function(o){return o.zIndex<=t&&o.parentId!==e.id});r.sort(function(o,a){return a.zIndex-o.zIndex});for(var s=0;se&&(e=r.zIndex)}return e},n.prototype.sendBackward=function(t){var e=this;if(this.diagram.protectPropertyChange(!0),Xa(this.diagram)||t){$(t||(this.diagram.selectedItems.nodes.length?this.diagram.selectedItems.nodes[0]:this.diagram.selectedItems.connectors[0]));var s=t&&t.id,o=this.diagram.layers.indexOf(this.getObjectLayer(s=s||(this.diagram.selectedItems.nodes.length?this.diagram.selectedItems.nodes[0].id:this.diagram.selectedItems.connectors[0].id))),a=$(this.diagram.nameTable),h=(parseInt(o.toString(),10),this.diagram.nameTable[""+s]),c=[],d=this.diagram.spatialSearch.findObjects(h.wrapper.bounds);d.length>2&&(d=this.sortByZIndex(d));for(var u=0,p=d;uNumber(f.zIndex)&&""===f.parentId&&h.wrapper.bounds.intersects(f.wrapper.bounds)&&c.push(f);for(var f=c.length-1;f>=0;f--)(v=this.diagram.nameTable[c[parseInt(f.toString(),10)].id]).parentId===s&&c.splice(f,1);if(c.length>0){var v;if((v=this.diagram.nameTable[c[c.length-1].id]).parentId){var S=am(v,this.diagram,""),b=this.diagram.nameTable[""+S];s!==b.id&&(c[c.length-1]=b)}var M={};for(f=0;f0&&(Object.values(L).forEach(function(pe){pe<=N&&O.push(pe)}),0!==O.length&&this.updateZIndexBySendBackward(h,O,o))}var T=[];if(Object.keys(this.changedNodeZIndexes).forEach(function(pe){if((a[""+pe]?a[""+pe].zIndex:null)!==e.changedNodeZIndexes[""+pe]){var xe=$(a[""+pe]);T.push(xe)}}),this.updateLayerZindexTable(o),R.nodes.splice(0,R.nodes.length),T.forEach(function(pe){var Me=$(pe);R.nodes.push(Me)}),"SVG"===this.diagram.mode){var P=c[c.length-1].id,_=c[c.length-1];_&&"HTML"!==_.shape.type&&"Native"!==_.shape.type&&this.moveSvgNode(s,P);var B=this.diagram.nameTable[""+P];B.children&&B.children.length>0?this.updateNativeNodeIndex(s):this.updateNativeNodeIndex(s,P)}else this.diagram.refreshCanvasLayers();var j=[];Object.keys(this.changedNodeZIndexes).forEach(function(pe){if((a[""+pe]?a[""+pe].zIndex:null)!==e.changedNodeZIndexes[""+pe]){var xe=$(e.diagram.nameTable[""+pe]);j.push(xe)}});var Q=$(this.diagram.selectedItems);Q.nodes.splice(0,Q.nodes.length),j.forEach(function(pe){var Me=$(pe);Q.nodes.push(Me)}),this.diagram.diagramActions&ee.UndoRedo||this.addHistoryEntry({type:"SendBackward",category:"Internal",undoObject:R,redoObject:Q}),this.diagram.endGroupAction()}}this.diagram.protectPropertyChange(!1)},n.prototype.updateZIndexBySendBackward=function(t,e,i){var r=$(t);t.zIndex=Math.max.apply(Math,e);var p,s=t.zIndex,o=Math.max.apply(Math,e),a=this.diagram.layers[parseInt(i.toString(),10)].objects,l=this.diagram.nodes.filter(function(S){return-1!==a.indexOf(S.id)}),h=l.filter(function(S){return S.zIndex===Math.max.apply(Math,e)&&S.id!==t.id});if(h&&h.length>0&&h[0].children)for(var c=Math.max.apply(Math,e),d=0;d0&&g.parentId!==h[0].id){var v=$(g);g.zIndex=p-1,p--,this.triggerOrderCommand(v,g,g)}var y=g.zIndex;this.changedNodeZIndexes[""+g.id]=(this.changedNodeZIndexes.hasOwnProperty(g.id),y)}},n.prototype.findLowestChildZIndex=function(t){for(var e=t.zIndex,i=0;i0),this.selectObjects([t],!0))},n.prototype.clearSelection=function(t,e){return ET(this,void 0,void 0,function(){var i,r,s,o;return DT(this,function(a){return i=this.diagram.allowServerDataBinding,this.diagram.enableServerDataBinding(!1),Xa(this.diagram)&&(r=this.diagram.selectedItems,s=this.getSelectedObject(),this.diagram.currentSymbol&&(this.diagram.previousSelectedObject=s),o={oldValue:s,newValue:[],cause:this.diagram.diagramActions,state:"Changing",type:"Removal",cancel:!1},t&&(ce()||this.diagram.triggerEvent(Ce.selectionChange,o)),o.cancel||(r.offsetX=0,r.offsetY=0,r.width=0,r.height=0,r.rotateAngle=0,r.nodes=[],r.connectors=[],r.wrapper=null,r.annotation=void 0,r.selectedObjects=[],this.diagram.clearSelectorLayer(),t&&(o={oldValue:s,newValue:[],cause:this.diagram.diagramActions,state:"Changed",type:"Removal",cancel:!1},ce()||this.diagram.triggerEvent(Ce.selectionChange,o))),this.diagram.enableServerDataBinding(i)),[2]})})},n.prototype.clearSelectedItems=function(){this.clearSelection((this.diagram.selectedItems.nodes?this.diagram.selectedItems.nodes.length:0)+(this.diagram.selectedItems.connectors?this.diagram.selectedItems.connectors.length:0)>0)},n.prototype.removeStackHighlighter=function(){var t=zl(this.diagram.element.id),e=t.getElementById(t.id+"_stack_highlighter");e&&e.parentNode.removeChild(e)},n.prototype.renderStackHighlighter=function(t,e){var r,s,o,i=this.diagram.selectedItems.nodes[0];if(!e){var a=this.diagram.findObjectsUnderMouse(t.position);if((e=this.diagram.findObjectUnderMouse(a,"Drag",!0))&&!(e.isLane||e.isPhase||e.isHeader))for(var l=0;l0)for(var a=0;a1)if(i){var h=l.segments[0],c=l.segments[1],u=Tc(xI(t.wrapper,t.wrapper.corners,t.wrapper.bounds),h.direction),g=Nl({corners:void 0,point:u=Nh(l,0,u,{x:l.sourceWrapper.offsetX,y:l.sourceWrapper.offsetY},!1),margin:void 0,direction:h.direction},{corners:void 0,point:c.points[1],margin:void 0,direction:void 0});h.length=z.distancePoints(g[0],g[1]),c.direction&&c.length&&(c.length=z.distancePoints(g[1],g[2]))}else if(o){switch(l.segments[0].direction){case"Bottom":r=t.wrapper.bounds.bottomCenter.x-e.bottomCenter.x,s=t.wrapper.bounds.bottomCenter.y-e.bottomCenter.y;break;case"Top":r=t.wrapper.bounds.topCenter.x-e.topCenter.x,s=t.wrapper.bounds.topCenter.y-e.topCenter.y;break;case"Left":r=t.wrapper.bounds.middleLeft.x-e.middleLeft.x,s=t.wrapper.bounds.middleLeft.y-e.middleLeft.y;break;case"Right":r=t.wrapper.bounds.middleRight.x-e.middleRight.x,s=t.wrapper.bounds.middleRight.y-e.middleRight.y}this.dragSourceEnd(l,r,s,!0,null,"ConnectorSourceEnd",void 0,void 0,void 0,!(t.parentId&&this.diagram.diagramActions&ee.isGroupDragging))}}},n.prototype.updateEndPoint=function(t,e){var r={sourcePoint:t.sourcePoint,targetPoint:t.targetPoint};t.sourceID&&(r.sourceID=t.sourceID),t.targetID&&(r.targetID=t.targetID),t.sourcePortID&&(r.sourcePortID=t.sourcePortID),t.targetPortID&&(r.targetPortID=t.targetPortID),t.segments&&(r.segments=t.segments),this.diagram.connectorPropertyChange(t,e||{},r),this.diagram.updateSelector()},n.prototype.dragSourceEnd=function(t,e,i,r,s,o,a,l,h,c,d){var u=this.diagram.nameTable[t.id],p={},f=this.checkBoundaryConstraints(e,i,u.wrapper.bounds);if(OI(u)&&f&&"BezierSourceThumb"!==o&&Yv(this.diagram)&&(p=$(p={sourcePoint:u.sourcePoint}),u.sourcePoint.x+=e,u.sourcePoint.y+=i,"ConnectorSourceEnd"===o&&"Orthogonal"===u.type&&this.changeSegmentLength(u,l,h,c),"Bpmn"===u.shape.type&&"Default"===u.shape.sequence&&"Sequence"===u.shape.flow&&this.updatePathElementOffset(u)),"Bezier"===u.type)if(p={sourcePoint:u.sourcePoint},d)this.translateBezierPoints(t,""===o?"ConnectorSourceEnd":o,e,i,d,s,!a);else for(var g=0;g2){var d=z.direction((c=t.segments[2]).points[0],c.points[1]);o.direction===ls(d)?("Right"===o.direction?c.points[0].x=o.points[o.points.length-1].x=l.wrapper.corners.middleRight.x+20:"Left"===o.direction?c.points[0].x=o.points[o.points.length-1].x=l.wrapper.corners.middleLeft.x-20:c.points[0].y=o.points[o.points.length-1].y="Top"===o.direction?l.wrapper.corners.topCenter.y-20:l.wrapper.corners.bottomCenter.y+20,c.direction&&c.length&&(c.length=z.distancePoints(c.points[0],c.points[c.points.length-1])),o.length=z.distancePoints(o.points[0],o.points[o.points.length-1])):o.direction===d&&c.direction&&c.length?("Top"===o.direction||"Bottom"===o.direction?(c.points[0]=o.points[0],c.points[c.points.length-1].x=c.points[0].x):(c.points[0]=o.points[0],c.points[c.points.length-1].y=c.points[0].y),c.length=z.distancePoints(c.points[0],c.points[c.points.length-1]),t.segments.splice(0,2)):o.length=20}else o.length=20;else if(o.length<1)if(""!==t.sourceID){var c;"Right"===a.direction?a.points[a.points.length-1].y=(h=l.wrapper.corners.middleRight).y:"Left"===a.direction?a.points[a.points.length-1].y=(h=l.wrapper.corners.middleLeft).y:a.points[a.points.length-1].x="Top"===a.direction?(h=l.wrapper.corners.topCenter).x:(h=l.wrapper.corners.bottomCenter).x,a.length=z.distancePoints(h,a.points[a.points.length-1]),t.segments.length>2&&(c=t.segments[2]).direction&&c.length&&(c.length=z.distancePoints(a.points[a.points.length-1],c.points[c.points.length-1])),t.segments.splice(0,1)}else t.segments.splice(0,1)}else e&&!i&&t.sourceID!==e.id&&t.segments&&null!==t.segments[0].direction&&e&&e instanceof te&&s&&this.changeSourceEndToNode(t,e),e&&i&&t.sourcePortID!==i&&t.segments&&null!==t.segments[0].direction&&e&&e instanceof te&&s&&this.changeSourceEndToPort(t,e,i)},n.prototype.canConnect=function(t,e){return!(!da(e)||!kh(e))},n.prototype.changeSourceEndToPort=function(t,e,i){var r=this.diagram.getWrapper(e.wrapper,i),s={x:r.offsetX,y:r.offsetY},o=zo(s,En(e.wrapper),e.wrapper.bounds),a=t.segments[0],l=t.segments[1];if(a.direction!==o){var h=[],c={};if(a.direction===ls(o)){c={};var d=void 0;"Top"===o||"Bottom"===o?(d="Top"===o?{type:"Orthogonal",isTerminal:!0,direction:o,length:Math.abs(a.points[0].y-s.y)}:{type:"Orthogonal",isTerminal:!0,direction:o,length:Math.abs(s.y-a.points[0].y)},c=a.points[0].x>s.x?{type:"Orthogonal",isTerminal:!0,direction:"Right",length:a.points[0].x-s.x}:{type:"Orthogonal",isTerminal:!0,direction:"Left",length:s.x-a.points[0].x}):(d="Right"===o?{type:"Orthogonal",isTerminal:!0,direction:o,length:Math.abs(a.points[0].x-s.x)}:{type:"Orthogonal",isTerminal:!0,direction:o,length:Math.abs(s.x-a.points[0].x)},c=a.points[0].y>s.y?{type:"Orthogonal",direction:"Top",isTerminal:!0,length:a.points[0].y-s.y}:{type:"Orthogonal",direction:"Bottom",isTerminal:!0,length:s.y-a.points[0].y}),h.push(new bi(t,"segments",d,!0)),h.push(new bi(t,"segments",c,!0))}else h.push(new bi(t,"segments",c={type:"Orthogonal",direction:o,length:20,isTerminal:!0},!0));a.direction!==ls(o)&&("Top"===o||"Bottom"===o?(a.points[0].x=s.x,a.points[0].y=a.points[a.points.length-1].y="Top"===o?s.y-20:s.y+20):(a.points[0].y=s.y,a.points[0].x=a.points[a.points.length-1].x="Right"===o?s.x+20:s.x-20),a.length=z.distancePoints(a.points[0],a.points[a.points.length-1]),l.length=z.distancePoints(a.points[a.points.length-1],l.points[l.points.length-1])),t.segments=h.concat(t.segments)}else a.points[0]=s,"Top"===o||"Bottom"===o?a.points[a.points.length-1].x=s.x:a.points[a.points.length-1].y=s.y,a.length=z.distancePoints(a.points[0],a.points[a.points.length-1]),l.length=z.distancePoints(a.points[a.points.length-1],l.points[l.points.length-1])},n.prototype.removeTerminalSegment=function(t,e){for(var i=0;ii.width||"Left"===o.direction&&r.x>=o.points[0].x||"Right"===o.direction&&r.x<=o.points[0].x)o.points[0].y=o.points[o.points.length-1].y=r.y,o.points[0].x=r.x,o.length=z.distancePoints(o.points[0],o.points[o.points.length-1]),a.length=z.distancePoints(o.points[o.points.length-1],a.points[a.points.length-1]);else{var h=void 0;s="Bottom"===(h=a.direction?a.direction:z.direction(a.points[0],a.points[a.points.length-1]))?i.bottomCenter:i.topCenter,a.length&&a.direction&&(a.length="Top"===h?o.points[o.points.length-1].y-(s.y+20):s.y+20-o.points[o.points.length-1].y),o.length=o.points[o.points.length-1].x-s.x,o.direction=o.length>0?"Right":"Left",l.push(new bi(t,"segments",{type:"Orthogonal",direction:h,length:20},!0)),t.segments=l.concat(t.segments)}else r="Bottom"===o.direction?i.bottomCenter:i.topCenter,o.length>i.height||"Top"===o.direction&&r.y>=o.points[0].y||"Bottom"===o.direction&&r.y<=o.points[0].y?(o.points[0].x=o.points[o.points.length-1].x=r.x,o.points[0].y=r.y,o.length=z.distancePoints(o.points[0],o.points[o.points.length-1]),a.length=z.distancePoints(o.points[o.points.length-1],a.points[a.points.length-1])):(s="Left"===a.direction?i.middleLeft:i.middleRight,h=void 0,h=a.direction?a.direction:z.direction(a.points[0],a.points[a.points.length-1]),a.length&&a.direction&&(a.length="Left"===h?o.points[o.points.length-1].x-(s.x+20):s.x+20-o.points[o.points.length-1].x),o.length=o.points[o.points.length-1].y-s.y,o.direction=o.length>0?"Bottom":"Top",l.push(new bi(t,"segments",{type:"Orthogonal",direction:h,length:20},!0)),t.segments=l.concat(t.segments))},n.prototype.translateBezierPoints=function(t,e,i,r,s,o,a){var l=t.segments.indexOf(s),h=t.segments[parseInt(l.toString(),10)],c=l>0?t.segments[l-1]:null,d=null!==c?c.point:t.sourcePoint,u=l===t.segments.length-1?t.targetPoint:h.point;if(h)if("BezierSourceThumb"===e&&(h.vector1.angle||h.vector1.distance)){var p=h.vector1.distance,f=h.vector1.angle;h.vector1={distance:t.distance(d,o),angle:z.findAngle(d,o)},this.translateSubsequentSegment(t,s,!0,h.vector1.distance-p,h.vector1.angle-f)}else"BezierTargetThumb"===e&&(h.vector2.angle||h.vector2.distance)?(p=h.vector2.distance,f=h.vector2.angle,h.vector2={distance:t.distance(u,o),angle:z.findAngle(u,o)},this.translateSubsequentSegment(t,s,!1,h.vector2.distance-p,h.vector2.angle-f)):("ConnectorSourceEnd"===e&&!t.sourceID||"ConnectorTargetEnd"===e&&!t.targetID)&&a&&ZI(h.vector1)&&ZI(h.vector2)?(z.isEmptyPoint(h.point1)&&(h.bezierPoint1=JI(t.sourcePoint,t.targetPoint)),z.isEmptyPoint(h.point2)&&(h.bezierPoint2=JI(t.targetPoint,t.sourcePoint))):"BezierSourceThumb"===e||"ConnectorSourceEnd"===e&&!a&&ZI(h.vector1)?(h.bezierPoint1.x+=i,h.bezierPoint1.y+=r,(!z.isEmptyPoint(h.point1)||a)&&(h.point1={x:h.bezierPoint1.x,y:h.bezierPoint1.y})):("BezierTargetThumb"===e||"ConnectorTargetEnd"===e&&!a&&ZI(h.vector2))&&(h.bezierPoint2.x+=i,h.bezierPoint2.y+=r,(!z.isEmptyPoint(h.point2)||a)&&(h.point2={x:h.bezierPoint2.x,y:h.bezierPoint2.y}))},n.prototype.translateSubsequentSegment=function(t,e,i,r,s){var o=t.segments.indexOf(e);parseInt(o.toString(),10),t.bezierSettings.smoothness&MI.SymmetricAngle||(s=null),t.bezierSettings.smoothness&MI.SymmetricDistance||(r=null),(null!=r||null!=s)&&(i?0!==o&&this.updatePreviousBezierSegment(t,o,r,s):o!==t.segments.length-1&&this.updateNextBezierSegment(t,o,r,s))},n.prototype.updatePreviousBezierSegment=function(t,e,i,r){var s=t.segments[e-1],a=(s.vector2.angle+r)%360;a<0&&(a+=360),s.vector2={distance:s.vector2.distance+i,angle:a}},n.prototype.updateNextBezierSegment=function(t,e,i,r){var s=t.segments[e+1],a=(s.vector1.angle+r)%360;a<0&&(a+=360),s.vector1={distance:s.vector1.distance+i,angle:a}},n.prototype.dragTargetEnd=function(t,e,i,r,s,o,a,l){var c,h=this.diagram.nameTable[t.id],d=this.checkBoundaryConstraints(e,i,h.wrapper.bounds);if(kI(h)&&"BezierTargetThumb"!==o&&d&&Yv(this.diagram)){if(c=$(c={targetPoint:h.targetPoint}),h.targetPoint.x+=e,h.targetPoint.y+=i,"ConnectorTargetEnd"===o&&"Orthogonal"===h.type&&h.segments&&h.segments.length>0){var u=h.segments[h.segments.length-2];u&&2===h.segments[h.segments.length-1].points.length&&("Left"===u.direction||"Right"===u.direction?u.points[u.points.length-1].x=h.targetPoint.x:u.points[u.points.length-1].y=h.targetPoint.y,u.length=z.distancePoints(u.points[0],u.points[u.points.length-1]),u.direction=z.direction(u.points[0],u.points[u.points.length-1]))}"Bpmn"===h.shape.type&&"Default"===h.shape.sequence&&"Sequence"===h.shape.flow&&this.updatePathElementOffset(h)}if("Bezier"===h.type)if(c={targetPoint:h.targetPoint},l)this.translateBezierPoints(t,""===o?"ConnectorTargetEnd":o,e,i,l,s,!a);else for(var p=0;p0){if(void 0!==s&&o.segments[parseInt(s.toString(),10)])if("Bezier"===o.type){var a=o.segments[parseInt(s.toString(),10)],l=a.isInternalSegment;l&&null!==o.bezierSettings&&"FreeForm"!==o.bezierSettings.segmentEditOrientation?("Horizontal"===a.orientation?a.point.x+=e:a.point.y+=i,this.updateDirectionalBezierCurve(o)):(a.point.x+=e,a.point.y+=i),l&&(o.isBezierEditing=!0)}else o.segments[parseInt(s.toString(),10)].point.x+=e,o.segments[parseInt(s.toString(),10)].point.y+=i;else for(var h=0;h1){var a=e[1],l=e[2],h={x:.5*(a.x+l.x),y:.5*(a.y+l.y)},c=t.segments[0];c.vector1.angle=Gt(s,a),c.vector1.distance=.5*z.findLength(s,a),c.vector2.angle=Gt(h,a),c.vector2.distance=.5*z.findLength(h,a),c.point=h;var d=t.segments[1];if(d.vector1.angle=Gt(h,l),d.vector1.distance=.5*z.findLength(h,l),t.segments.length>2){var u=e[3],p={x:.5*(l.x+u.x),y:.5*(l.y+u.y)};d.vector2.angle=Gt(p,l),d.vector2.distance=.5*z.findLength(p,l),d.point=p;var f=t.segments[2];if(f.vector1.angle=Gt(p,u),f.vector1.distance=.5*z.findLength(p,u),t.segments.length>3){var g=e[4],v={x:.5*(u.x+g.x),y:.5*(u.y+g.y)};f.vector2.angle=Gt(v,u),f.vector2.distance=.5*z.findLength(v,u),f.point=v;var y=t.segments[3];y.vector1.angle=Gt(v,g),y.vector1.distance=.5*z.findLength(v,g),y.vector2.angle=Gt(o,g),y.vector2.distance=.5*z.findLength(o,g)}else f.vector2.angle=Gt(o,u),f.vector2.distance=.5*z.findLength(o,u)}else d.vector2.angle=Gt(o,l),d.vector2.distance=.5*z.findLength(o,l)}},n.prototype.rotateObjects=function(t,e,i,r,s){r=r||{};var o=Hi();qi(o,i,r.x,r.y);for(var l=0,h=e;l0){this.diagram.protectPropertyChange(!0);var o=t;o.segments=[],this.diagram.connectorPropertyChange(o,{},{segments:o.segments}),this.diagram.protectPropertyChange(!1)}}},n.prototype.updateInnerParentProperties=function(t){var r=this.diagram.isProtectedOnChange;this.diagram.protectPropertyChange(!0);for(var s=this.getAllDescendants(t,[],!1,!0),o=0;o0&&(p=this.diagram.bpmnModule.getChildrenBound(d,d.id,this.diagram),u=d.wrapper.bounds.containsRect(p)),h=d.wrapper.actualSize.width*t,c=d.wrapper.actualSize.height*e,void 0!==d.maxWidth&&0!==d.maxWidth&&(h=Math.min(d.maxWidth,h)),void 0!==d.minWidth&&0!==d.minWidth&&(h=Math.max(d.minWidth,h)),void 0!==d.maxHeight&&0!==d.maxHeight&&(c=Math.min(d.maxHeight,c)),void 0!==d.minHeight&&0!==d.minHeight&&(c=Math.max(d.minHeight,c)),u&&(h=Math.max(h,p.right-d.wrapper.bounds.x),c=Math.max(c,p.bottom-d.wrapper.bounds.y)),t=h/d.actualSize.width,e=c/d.actualSize.height}var f=Hi();o||(o=r);var g=o.wrapper;if(qi(f,-g.rotateAngle,i.x,i.y),Gp(f,t,e,i.x,i.y),qi(f,g.rotateAngle,i.x,i.y),r instanceof te){var d,v=Je(f,{x:(d=r).wrapper.offsetX,y:d.wrapper.offsetY}),y=d.wrapper.offsetX-d.wrapper.actualSize.width*d.pivot.x,S=d.wrapper.offsetY-d.wrapper.actualSize.height*d.pivot.y;if(h>0)if(d.processId){var b=this.diagram.nameTable[d.processId];(!b.maxWidth||d.margin.left+h0)if(d.processId){var M=this.diagram.nameTable[d.processId];(!M.maxHeight||d.margin.top+c0){if(e.dragLimit=e.dragLimit?e.dragLimit:{},e.dragLimit.top||e.dragLimit.bottom||e.dragLimit.left||e.dragLimit.right){var b={minDistance:null};S=this.getRelativeOffset(v,d,b);var M={minDistance:null};g=this.getRelativeOffset(v,y,M),S=null!=b&&M.minDistance0){if(S=y[y.length-1]){var b=void 0;for(b=0;b=e.x-t.dragLimit.left-r.width/2&&i.x<=e.x+t.dragLimit.right+r.width/2&&(s=!0),i.y>=e.y-t.dragLimit.top-r.height/2&&i.y<=e.y+t.dragLimit.bottom+r.height/2&&(o=!0),{x:s,y:o}},n.prototype.updateLabelMargin=function(t,e,i,r,s,o,a){if(i=i||{x:e.offset,y:0},e&&i&&i.x>0&&i.x<1){var l=z.getLengthFromListOfPoints(t.intermediatePoints),h=this.getPointAtLength(l*i.x,t.intermediatePoints,0),c=this.diagram.scrollSettings.currentZoom,d=e.dragLimit?e.dragLimit:{left:0,right:0,top:0,bottom:0};if(d.top||d.bottom||d.left||d.right){this.diagram.getWrapper(t.wrapper,e.id);var p=new Ne(0,0,0,0),f=this.diagram.getWrapper(t.wrapper,e.id);p.x=f.offsetX/c+o,p.y=f.offsetY/c+a,p.width=f.bounds.width/c,p.height=f.bounds.height/c;var g=new Ne(h.x-(d.left||0)-p.width/2,h.y-(d.top||0)-p.height/2,(d.left||0)+(d.right||0)+p.width,(d.top||0)+(d.bottom||0)+p.height);if(g.containsPoint(r));else for(var S=0,b=this.boundsInterSects([h,r],g,!1);S=t){c=t-r,d=z.findAngle(s,a),u=c*Math.cos(d*Math.PI/180),p=c*Math.sin(d*Math.PI/180),o={x:s.x+u,y:s.y+p};break}r+=h,s=a}else s=a;return o},n.prototype.getInterceptWithSegment=function(t,e){for(var o,a,i=[],r=[],s=[],l=z.findLength({x:0,y:0},{x:this.diagram.scroller.viewPortWidth,y:this.diagram.scroller.viewPortHeight}),h=1;h0&&a<=90||a>180&&a<=270?90:-90;r.push(z.transform(t,a+c,l)),r.push(z.transform(t,o+c,l));var p=im({x1:s[0].x,y1:s[0].y,x2:s[1].x,y2:s[1].y},{x1:r[0].x,y1:r[0].y,x2:r[1].x,y2:r[1].y});p.enabled&&i.push(p.intersectPt)}return i},n.prototype.getAnnotationChanges=function(t,e){var r={};return r[ob(t,e.id,!0)]={width:e.width,height:e.height,offset:t instanceof te?{x:e.offset.x,y:e.offset.y}:e.offset,rotateAngle:e.rotateAngle,margin:{left:e.margin.left,right:e.margin.right,top:e.margin.top,bottom:e.margin.bottom},horizontalAlignment:e.horizontalAlignment,verticalAlignment:e.verticalAlignment,alignment:t instanceof de?e.alignment:void 0},{annotations:r}},n.prototype.getConnectorPortChanges=function(t,e){var i=function Wse(n,t,e){for(var i=n.ports,r=0;r1&&(v.width=g,v.offset.x=1/S),f>1&&(v.height=f,v.offset.y=1/b)}}e instanceof Nr&&(e.alignment="Center"),l=this.getAnnotationChanges(t,e),t instanceof te?this.diagram.nodePropertyChange(t,a,l):this.diagram.connectorPropertyChange(t,a,l),this.diagram.updateDiagramObject(t)},n.prototype.getSubProcess=function(t){var i,e={nodes:[],connectors:[]};return t instanceof te?i=t.processId:t&&t.nodes&&t.nodes.length&&t.nodes[0].processId&&(i=t.nodes[0].processId),i&&e.nodes.push($(this.diagram.nameTable[i])),e},n.prototype.checkBoundaryConstraints=function(t,e,i,r){var s=this.diagram.pageSettings,o=this.diagram.pageSettings.boundaryConstraints,a=this.diagram.scroller;if("Page"===o||"Diagram"===o){var l=i?void 0:this.diagram.selectedItems.wrapper.bounds;return!!((i?i.right:l.right)+(t||0)<=("Page"===o?s.width:a.viewPortWidth)&&(i?i.left:l.left)+(t||0)>=0&&(i?i.bottom:l.bottom)+(e||0)<=("Page"===o?s.height:a.viewPortHeight)&&(i?i.top:l.top)+(e||0)>=0||"None"!==this.diagram.layout.type&&r)}return!0},n.prototype.dragSelectedObjects=function(t,e){var i=this,r=this.diagram.selectedItems;this.state&&!this.state.backup&&(this.state.backup={},this.state.backup.offsetX=r.offsetX,this.state.backup.offsetY=r.offsetY),r=QI(this.diagram,r)||r;var s=this.diagram.selectedItems.nodes.filter(function(c){return"SwimLane"===c.shape.type});if(s.length>0&&!this.diagram.currentSymbol&&this.diagram.selectedItems.nodes.length>1){var o=this.diagram.selectedItems.nodes.filter(function(c){return""===c.parentId||"SwimLane"!==i.diagram.nameTable[c.parentId].shape.type});if(o.length>0){for(var a=0;a0||l.length>1)&&(o=o.concat(l),this.diagram.selectedItems.nodes.splice(0,this.diagram.selectedItems.nodes.length),o.forEach(function(c){i.diagram.selectedItems.nodes.push(c)}),r=this.diagram.selectedItems,this.diagram.selectedObject.helperObject=void 0)}}if(this.checkBoundaryConstraints(t,e)){this.diagram.diagramActions=this.diagram.diagramActions|ee.PreventZIndexOnDragging|ee.DragUsingMouse;var h=this.diagram.selectedObject.actualObject;return(h&&h instanceof te&&h.isLane&&Qx(h,this.diagram)||!h||!h.isLane)&&this.diagram.drag(r,t,e),this.diagram.diagramActions=this.diagram.diagramActions&~(ee.PreventZIndexOnDragging|ee.DragUsingMouse),this.diagram.refreshCanvasLayers(),this.checkHtmlObjectDrag(r),!0}return!1},n.prototype.checkHtmlObjectDrag=function(t){var e=!1;this.diagram.views&&this.diagram.views.length>1&&(t instanceof si?e=t.nodes.some(function(i){return i.shape&&"HTML"===i.shape.type}):t.shape&&"HTML"===t.shape.type&&(e=!0),e&&this.resetOverviewCanvas())},n.prototype.resetOverviewCanvas=function(){for(var t=0,e=this.diagram.views;t0&&(this.layoutAnimateModule.stopCurrentAnimation(this.objectStore[0],e,t),this.objectStore=[]),a=this.diagram.doLayout(),this.objectStore.push(a)),this.canUpdateTemplate=!1,this.diagram.blazorActions&=~on.expandNode,this.diagram.preventNodesUpdate=r,this.diagram.layoutAnimateModule&&this.diagram.organizationalChartModule&&!i)this.diagram.allowServerDataBinding=!1,this.layoutAnimateModule.expand(this.diagram.layout.enableAnimation,a,t,this.diagram);else{var l={element:$(t),state:!!t.isExpanded};this.triggerEvent(Ce.expandStateChange,l),this.diagram.lineRoutingModule&&this.diagram.constraints&rt.LineRouting&&"ComplexHierarchicalTree"!==this.diagram.layout.type&&this.diagram.resetSegments()}return this.diagram.layout.fixedNode=""===o?"":this.diagram.layout.fixedNode,a},n.prototype.getparentexpand=function(t,e,i,r){for(var s,o=0;o0&&(this.diagram.selectedItems.wrapper.rotateAngle=this.diagram.selectedItems.rotateAngle=s.rotateAngle),r instanceof te&&"SwimLane"!==r.shape.type&&!r.isLane&&!r.isPhase&&!r.isHeader)(r.offsetX!==r.wrapper.offsetX||r.offsetY!==r.wrapper.offsetY||r.width!==r.wrapper.width||r.height!==r.wrapper.height||r.rotateAngle!==r.wrapper.rotateAngle)&&(r.offsetX+=o,r.offsetY+=a,r.width+=l,r.height+=h,r.rotateAngle+=c,this.diagram.nodePropertyChange(r,{},{offsetX:r.offsetX,offsetY:r.offsetY,width:r.width,height:r.height,rotateAngle:r.rotateAngle})),e=this.diagram.spatialSearch.findObjects(r.wrapper.outerBounds);else if(r instanceof si)for(var d=0;d30||g.wrapper.outerBounds.topCenter.y-f.wrapper.outerBounds.bottomCenter.y>30)&&this.diagram.lineRoutingModule.refreshConnectorSegments(this.diagram,p,!0)}}this.updateSelector(),this.diagram.protectPropertyChange(!1)}},n.prototype.drawSelectionRectangle=function(t,e,i,r){this.diagram.drawSelectionRectangle(t,e,i,r)},n.prototype.startGroupAction=function(){this.diagram.startGroupAction()},n.prototype.endGroupAction=function(){this.diagram.endGroupAction()},n.prototype.removeChildFromBPmn=function(t,e,i){var r=this.diagram.nameTable[t.id]||t.nodes[0];if(i&&r&&r.processId&&r.processId===i.wrapper.id){var s=$(r);s.processId=r.processId,this.diagram.startGroupAction();var o=this.diagram.nameTable[r.processId].shape.activity.subProcess.processes||[];o.splice(o.indexOf(r.id),1),this.diagram.bpmnModule.removeChildFromBPMN(this.diagram.nameTable[r.processId].wrapper,r.id,this.diagram),this.diagram.nameTable[r.id].processId="",r.offsetX=r.wrapper.offsetX,r.offsetY=r.wrapper.offsetY;var a=$(r);this.addHistoryEntry({type:"PositionChanged",redoObject:{nodes:[a]},undoObject:{nodes:[s]},category:"Internal"}),this.diagram.endGroupAction()}},n.prototype.isDroppable=function(t,e){var i=this.diagram.nameTable[t.id]||t.nodes[0];return i instanceof te&&(!ce()&&"TextAnnotation"===i.shape.shape||("Group"===e.shape.shape&&(e.shape.activity.subProcess.collapsed=!1),!(i&&"Bpmn"===i.shape.type&&(i.processId===e.id||i.id===e.processId||"Bpmn"===e.shape.type&&!(e instanceof de)&&e.shape.activity&&e.shape.activity.subProcess&&e.shape.activity.subProcess.collapsed))))},n.prototype.renderHighlighter=function(t,e,i){if(new Ne,t.target instanceof te||t.target instanceof de||e&&(t.source instanceof te||t.source instanceof de)){var a=this.findTarget(e?t.sourceWrapper:t.targetWrapper,e?t.source:t.target,i,!0),l=void 0;if(a instanceof Hd)for(var h=a.id,c=t.target,u=0,p=c.wrapper.children[0].children[0].children[2].children;u0){var r=0;t[0]=this.diagram.nameTable[t[0].id]||t[0];var s="Object"===i?yr(t[0].wrapper):this.diagram.selectedItems.wrapper.bounds,o={nodes:[],connectors:[]},a={nodes:[],connectors:[]};for(r="Object"===i?r+1:r;r0){var i=0,r=0,s=0,o=0,a=0,l=0,h=0,c=0,d={nodes:[],connectors:[]},u={nodes:[],connectors:[]};for(i=0;io.center.y&&(r=n[parseInt(e.toString(),10)],n[parseInt(e.toString(),10)]=n[parseInt(i.toString(),10)],n[parseInt(i.toString(),10)]=r):s.center.x>o.center.x&&(r=n[parseInt(e.toString(),10)],n[parseInt(e.toString(),10)]=n[parseInt(i.toString(),10)],n[parseInt(i.toString(),10)]=r)}}return n}(t,e),i=1;i0){var i=0,r={x:.5,y:.5};t[0]=this.diagram.nameTable[t[0].id]||t[0];var s=yr(t[0].wrapper),o={nodes:[],connectors:[]},a={nodes:[],connectors:[]};for(i=1;ii.zIndex){for(var s=this.diagram.layers.indexOf(this.diagram.getActiveLayer()),o=this.diagram.layers[parseInt(s.toString(),10)].zIndexTable,a=JSON.parse(JSON.stringify(o)),l=i.zIndex,h=r.zIndex,c=h;c>=l;c--)l!==c?o[c-1]?(o[parseInt(c.toString(),10)]=o[c-1],this.diagram.nameTable[o[parseInt(c.toString(),10)]].zIndex=c):(o[c-1]=o[parseInt(c.toString(),10)],this.diagram.nameTable[o[c-1]].zIndex=c,delete o[parseInt(c.toString(),10)]):this.swapZIndexObjects(h,o,r.id,a);"SVG"===this.diagram.mode?(this.moveSvgNode(e.parentId,i.id),this.updateNativeNodeIndex(e.parentId,i.id)):this.diagram.refreshCanvasLayers()}},n.prototype.findLeastIndexConnector=function(t,e,i){for(var r=0;rs.zIndex&&(i=s)}return i},n.prototype.findLeastIndexObject=function(t,e){var i=t;return t instanceof te&&(i=this.findLeastIndexConnector(t.inEdges,e,i),i=this.findLeastIndexConnector(t.outEdges,e,i)),i},n.prototype.checkSelection=function(t,e){var i;if(1===t.nodes.length&&0===t.connectors.length)if(cs(this.diagram,t.nodes[0],!0)){var r=t.nodes[0];if("SwimLane"===(i="SwimLane"===t.nodes[0].shape?t.nodes[0]:this.diagram.nameTable[t.nodes[0].parentId]).shape.type){var s="Horizontal"===i.shape.orientation;(r.isPhase&&(s&&"ResizeSouth"===e||!s&&"ResizeEast"===e)||r.isLane&&(s&&"ResizeEast"===e||!s&&"ResizeSouth"===e))&&W3(this.diagram,i,e)}else if("Grid"===i.container.type)if("Horizontal"===i.container.orientation&&1===r.rowIndex||"Vertical"===i.container.orientation&&r.rowIndex>0&&r.columnIndex>0){if("ResizeSouth"===e)for(var o=0;o1&&(this.diagram.realActions=this.diagram.realActions|$i.hScrollbarMoved,this.scrolled=!0),this.diagram.scrollSettings.horizontalOffset=t},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"verticalOffset",{get:function(){return this.vOffset},set:function(t){this.vOffset=t,Math.abs(this.vOffset-this.diagram.scrollSettings.verticalOffset)>1&&(this.diagram.realActions=this.diagram.realActions|$i.vScrollbarMoved,this.scrolled=!0),this.diagram.scrollSettings.verticalOffset=t},enumerable:!0,configurable:!0}),n.prototype.getBounds=function(){var e=this.diagram.spatialSearch.getPageBounds(0,0);return(e.x<0||e.y<0)&&!this.diagram.pageSettings.multiplePage?this.getPageBounds(void 0,void 0,!0,!0):this.getPageBounds(void 0,void 0,!0)},n.prototype.updateScrollOffsets=function(t,e){var i,r,s=this.getBounds();s.x*=this.currentZoom,s.y*=this.currentZoom,s.width*=this.currentZoom,s.height*=this.currentZoom,i=Math.max(0,t-s.left),r=Math.max(0,e-s.top),void 0!==t&&void 0!==e?(this.horizontalOffset=i,this.verticalOffset=r,this.diagram.setOffset(i,r)):this.diagram.setOffset(-this.horizontalOffset-s.x,-this.verticalOffset-s.y),this.transform={tx:Math.max(this.horizontalOffset,-s.left)/this.currentZoom,ty:Math.max(this.verticalOffset,-s.top)/this.currentZoom,scale:this.currentZoom}},n.prototype.setScrollOffset=function(t,e){this.scrolled=!1;var i=this.getBounds();i.x*=this.currentZoom,i.y*=this.currentZoom,i.width*=this.currentZoom,i.height*=this.currentZoom;var r=-i.left,s=-i.top,o=!1,a=this.viewPortWidth*this.currentZoom,l=this.viewPortHeight*this.currentZoom,h=r-t;if(h!==this.horizontalOffset){rh?this.horizontalOffset-=t:this.horizontalOffset=h,o=!0);var c=Math.max(i.right+this.vScrollSize,a);if(!o&&c<-h+this.viewPortWidth){var d=-h+a-this.vScrollSize,u=-this.horizontalOffset+a-this.vScrollSize;this.horizontalOffset=dd-u?h:-(i.right+this.vScrollSize-a),o=!0}o||(this.horizontalOffset=r-t)}o=!1;var p=s-e;if(p!==this.verticalOffset){sp?this.verticalOffset-=e:this.verticalOffset=p,o=!0);var f=Math.max(i.bottom+this.hScrollSize,l);if(!o&&f<-p+l){var g=-p+l-this.hScrollSize,v=-this.verticalOffset+l-this.hScrollSize;this.verticalOffset=gg-v?p:-(i.bottom+this.hScrollSize-l),o=!0}o||(this.verticalOffset=s-e)}this.transform={tx:Math.max(this.horizontalOffset,-i.left)/this.currentZoom,ty:Math.max(this.verticalOffset,-i.top)/this.currentZoom,scale:this.currentZoom},this.setSize()},n.prototype.getObjects=function(t,e){for(var i=[],r=0;r0){for(var l=0;l0){h.push(i[parseInt(o.toString(),10)].id);for(var d=0;d=e.bottom&&(l=0),-this.horizontalOffset<=e.x&&-this.horizontalOffset+this.viewPortWidth>=e.right&&(a=0),this.hScrollSize=a,this.vScrollSize=l;var h=this.diagramWidth,c=this.diagramHeight;this.diagramWidth=Math.max(e.right,-this.horizontalOffset+this.viewPortWidth-l)-i,this.diagramHeight=Math.max(e.bottom,-this.verticalOffset+this.viewPortHeight-a)-r,(h!==this.diagramWidth||c!==this.diagramHeight)&&"Diagram"!==this.diagram.scrollSettings.scrollLimit&&this.diagram.setSize(this.diagramWidth,this.diagramHeight),"Diagram"===this.diagram.scrollSettings.scrollLimit&&(h===this.diagramWidth&&c===this.diagramHeight&&1===this.currentZoom||this.diagram.diagramActions&&t&&(!this.diagram.diagramActions||!t||0===this.verticalOffset&&this.verticalOffset!==t.y||0===this.horizontalOffset&&this.horizontalOffset!==t.x)?t&&h===this.diagramWidth&&c===this.diagramHeight&&(this.diagram.diagramCanvas.scrollHeight>this.viewPortHeight&&t.y<0&&this.horizontalOffset===t.x&&0===this.verticalOffset||this.diagram.diagramCanvas.scrollWidth>this.viewPortWidth&&t.x<0&&this.verticalOffset===t.y&&0===this.horizontalOffset)&&(this.verticalOffset=t.y,this.horizontalOffset=t.x,this.transform={tx:Math.max(t.x,-e.left)/this.currentZoom,ty:Math.max(t.y,-e.top)/this.currentZoom,scale:this.currentZoom}):(this.diagram.scrollActions&ca.Interaction&&t&&(this.transform={tx:Math.max(t.x,-e.left/this.currentZoom)/this.currentZoom,ty:Math.max(t.y,-e.top/this.currentZoom)/this.currentZoom,scale:this.currentZoom},this.horizontalOffset=t.x,this.verticalOffset=t.y),this.diagram.setSize(this.diagramWidth,this.diagramHeight),!(this.diagram.scrollActions&ca.PropertyChange)&&t&&(this.horizontalOffset=t.x,this.verticalOffset=t.y,this.transform={tx:Math.max(t.x,-e.left)/this.currentZoom,ty:Math.max(t.y,-e.top)/this.currentZoom,scale:this.currentZoom}))),this.diagram.transformLayers(),this.diagram.element.style.overflow="hidden"},n.prototype.setViewPortSize=function(t,e){this.viewPortWidth=t,this.viewPortHeight=e},n.prototype.getPageBounds=function(t,e,i,r){var o,s=new Ne;if("Content"===e||r||null===this.diagram.pageSettings.width||null===this.diagram.pageSettings.height){var u=t?void 0:0;o=this.diagram.spatialSearch.getPageBounds(u,u)}else{var a=this.diagram.pageSettings.width,l=this.diagram.pageSettings.height,h=0,c=0;if(this.diagram.pageSettings.multiplePage){if((s=this.diagram.spatialSearch.getPageBounds(0,0)).right>a&&(a*=d=Math.ceil(s.right/a)),s.bottom>l&&(l*=d=Math.ceil(s.bottom/l)),s.left<0&&Math.abs(s.left)>h){var d=Math.ceil(Math.abs(s.left)/this.diagram.pageSettings.width);h=this.diagram.pageSettings.width*d}s.top<0&&Math.abs(s.top)>c&&(d=Math.ceil(Math.abs(s.top)/this.diagram.pageSettings.height),c=this.diagram.pageSettings.height*d)}o=new Ne(-h,-c,a+h,l+c)}if(i){var p=this.diagram.scrollSettings.padding;o.x-=p.left,o.y-=p.top,o.width+=p.left+p.right,o.height+=p.top+p.bottom}return o},n.prototype.getPageBreak=function(t){for(var e=0,i=0,r=-1,s=[],c=this.diagram.pageSettings.margin.left,d=this.diagram.pageSettings.margin.right,u=this.diagram.pageSettings.margin.top,p=this.diagram.pageSettings.margin.bottom,f=1,g=1;t.width>e;)(e+=this.diagram.pageSettings.width?this.diagram.pageSettings.width:t.width)===this.diagram.pageSettings.width&&(s[++r]={x1:t.left+c,y1:t.top+u,x2:t.left+c,y2:t.bottom-p}),ei;)(i+=this.diagram.pageSettings.height?this.diagram.pageSettings.height:t.height)===this.diagram.pageSettings.height&&(s[++r]={x1:t.left+c,y1:t.top+u,x2:t.right-d,y2:t.top+u}),i=this.diagram.scrollSettings.minZoom||l||t>=1)){this.currentZoom*=t;var c=this.getPageBounds(void 0,void 0,!0);c.x*=this.currentZoom,c.y*=this.currentZoom;var d=Hi();Gp(d,t,t,r.x,r.y),r3(d,e||0,i||0),bx(h,d);var u=Je(h,{x:0,y:0});if(1===t&&(u=this.applyScrollLimit(u.x,u.y,s,o,a)),a=-c.y>=u.y&&-c.x>=u.x&&a,(this.diagram.scrollActions&ca.PropertyChange||!(this.diagram.scrollActions&ca.Interaction)||"Diagram"!==this.diagram.scrollSettings.scrollLimit||a)&&(this.transform={tx:Math.max(u.x,-c.left)/this.currentZoom,ty:Math.max(u.y,-c.top)/this.currentZoom,scale:this.currentZoom},this.horizontalOffset=u.x,this.verticalOffset=u.y),this.setSize(u),"SVG"!==this.diagram.mode&&Ds(this.diagram)&&this.diagram.scroller.virtualizeElements(),"SVG"!==this.diagram.mode&&!Ds(this.diagram)&&this.diagram.refreshDiagramLayer(),this.diagram.setOffset(-this.horizontalOffset-c.x,-this.verticalOffset-c.y),KI(this.diagram),this.diagram.views&&this.diagram.views.overview){var p=this.diagram.views.overview,f=p.scrollOverviewRect(p.parent.scroller.horizontalOffset,p.parent.scroller.verticalOffset,p.parent.scroller.currentZoom,!0);p.updateOverviewrect(-f.x,-f.y,f.width,f.height),p.updateView(p)}}}},n.prototype.fitToPage=function(t){var e=(t=t||{}).mode,i=t.region,r=t.margin||{},s=t.canZoomIn,o=t.customBounds,a=t.canZoomOut;r.bottom=r.bottom||25,r.top=r.top||25,r.left=r.left||25,r.right=r.right||25;var h,l=o,c=-this.horizontalOffset,d=-this.verticalOffset;if("PageSettings"===(i=i||"PageSettings")&&this.diagram.pageSettings.width&&this.diagram.pageSettings.height||this.diagram.nodes.length>0||this.diagram.connectors.length>0){e=e||"Page","CustomBounds"!==i&&(l=this.getPageBounds(!0,i,!0));var u={x:0,y:0};r.left+r.right>this.viewPortWidth&&(this.viewPortWidth<=100?(r.left=5,r.right=5):(r.left=25,r.right=25)),r.top+r.bottom>this.viewPortHeight&&(this.viewPortHeight<=100?(r.top=5,r.bottom=5):(r.top=25,r.bottom=25)),u.x=(this.viewPortWidth-(r.left+r.right))/l.width,u.y=(this.viewPortHeight-(r.top+r.bottom))/l.height,!s&&l.width-this.horizontalOffset-a+this.viewPortWidth&&(i=o.right-this.viewPortWidth,i+=20),o.x<-a&&(i=o.x),o.bottom>-l+this.viewPortHeight&&(r=o.bottom-this.viewPortHeight,r+=20),o.y<-l&&(r=o.y),this.zoom(1,-this.horizontalOffset-i,-this.verticalOffset-r,null,void 0,e))},n.prototype.bringToCenter=function(t){var e=this.currentZoom,i=new Ne(t.x*e,t.y*e,t.width*e,t.height*e),r=i.x+i.width/2-this.viewPortWidth/2,s=i.y+i.height/2-this.viewPortHeight/2;this.zoom(1,-this.horizontalOffset-(r*=-1),-this.verticalOffset-(s*=-1),null)},n.prototype.applyScrollLimit=function(t,e,i,r,s){if("Infinity"===this.diagram.scrollSettings.scrollLimit&&void 0===i&&!r&&(t=-t,e=-e),"Infinity"!==this.diagram.scrollSettings.scrollLimit){var o=void 0;if("Limited"===this.diagram.scrollSettings.scrollLimit){var a=this.diagram.scrollSettings.scrollableArea;o=new Ne(a.x,a.y,a.width,a.height)}(o=o||(s?this.getPageBounds():this.getPageBounds(!0))).x*=this.currentZoom,o.y*=this.currentZoom,o.width*=this.currentZoom,o.height*=this.currentZoom,void 0!==i&&(t*=-1,e*=-1),r&&(t*=-1,e*=-1);var l=Math.max(o.right,this.viewPortWidth);if(!r&&!(t<=o.x&&(t+this.viewPortWidth>=o.right||t>=o.right-this.viewPortWidth)||t>=o.x&&t+this.viewPortWidth<=l))if(t>=o.x)t=Math.max(o.x,Math.min(t,t-(t+this.viewPortWidth-this.vScrollSize-l)));else{var h=o.right-this.viewPortWidth;t=Math.min(h,o.x)}var c=Math.max(o.bottom,this.viewPortHeight);r||e<=o.y&&e+this.viewPortHeight>=o.bottom||e>=o.y&&e+this.viewPortHeight<=c||(e>=o.y?e=Math.max(o.y,Math.min(e,e-(e+this.viewPortHeight-this.hScrollSize-c))):(h=o.bottom-this.viewPortHeight,e=Math.min(o.y,h))),t*=-1,e*=-1}return{x:t,y:e}},n}(),tae=function(){function n(t,e,i,r,s){this.objects=[],this.left=t,this.top=e,this.width=i,this.height=r,this.spatialSearch=s}return n.prototype.findQuads=function(t,e){null!=this.first&&this.first.isIntersect(t)&&this.first.findQuads(t,e),null!=this.second&&this.second.isIntersect(t)&&this.second.findQuads(t,e),null!=this.third&&this.third.isIntersect(t)&&this.third.findQuads(t,e),null!=this.fourth&&this.fourth.isIntersect(t)&&this.fourth.findQuads(t,e),this.objects.length>0&&e.push(this)},n.prototype.isIntersect=function(t){return!(this.left+this.widtht.right||this.top>t.bottom)},n.prototype.selectQuad=function(){for(var i,t=null,e=this;null!=e;)i=e.getQuad(t),e=i.source,t=i.target||t;return t},n.prototype.getQuad=function(t){var e=this.width/2,i=this.height/2;if(e>=1e3&&i>=1e3){var r=this.left+e,s=this.top+i;if(this.spatialSearch.childRight<=r){if(this.spatialSearch.childBottom<=s)return this.first||((o=new n(this.left,this.top,e,i,this.spatialSearch)).parent=this,this.first=o),{source:this.first};if(this.spatialSearch.childTop>=s)return this.third||((o=new n(this.left,s,e,i,this.spatialSearch)).parent=this,this.third=o),{source:this.third}}else if(this.spatialSearch.childLeft>=r){if(this.spatialSearch.childBottom<=s)return this.second||((o=new n(r,this.top,e,i,this.spatialSearch)).parent=this,this.second=o),{source:this.second};var o;if(this.spatialSearch.childTop>=s)return this.fourth||((o=new n(r,s,e,i,this.spatialSearch)).parent=this,this.fourth=o),{source:this.fourth}}}return this.objects.push(this.spatialSearch.childNode),{target:this}},n.prototype.isContained=function(){return this.spatialSearch.childLeft>=this.left&&this.spatialSearch.childRight<=this.left+this.width&&this.spatialSearch.childTop>=this.top&&this.spatialSearch.childBottom<=this.top+this.height},n.prototype.addIntoAQuad=function(t){var e={};this.spatialSearch.setCurrentNode(t);for(var i=null;!e.isAdded;)i=(e=this.spatialSearch.parentQuad.add(i)).quad;return i},n.prototype.add=function(t){if(t=null,this.isContained())return{isAdded:!0,quad:t=this.selectQuad()};var e=void 0,i=!(0!==this.objects.length||this.first||this.second||this.third||this.fourth),r=2*this.width,s=2*this.height;return this.spatialSearch.childLeft=this.childLeft?(this.pageLeft=this.childLeft,this.leftElement=t,r=!0):t===this.leftElement&&(this.pageLeft=Number.MAX_VALUE,this.findLeft(this.parentQuad),r=!0)),(this.pageTop!==this.childTop||t!==this.topElement)&&(this.pageTop>=this.childTop?(this.pageTop=this.childTop,this.topElement=t,r=!0):t===this.topElement&&(this.pageTop=Number.MAX_VALUE,this.findTop(this.parentQuad),r=!0)),(this.pageBottom!==this.childBottom||t!==this.bottomElement)&&(this.pageBottom<=this.childBottom?(r=!0,this.pageBottom=this.childBottom,this.bottomElement=t):t===this.bottomElement&&(this.pageBottom=-Number.MAX_VALUE,this.findBottom(this.parentQuad),r=!0)),(this.pageRight!==this.childRight||t!==this.rightElement)&&(this.pageRight<=this.childRight?(this.pageRight=this.childRight,this.rightElement=t,r=!0):t===this.rightElement&&(this.pageRight=-Number.MAX_VALUE,this.findRight(this.parentQuad),r=!0)),r}return this.setCurrentNode(null),!1},n.prototype.isWithinPageBounds=function(t){return t.left>=this.pageLeft&&t.right<=this.pageRight&&t.top>=this.pageTop&&t.bottom<=this.pageBottom},n.prototype.findQuads=function(t){var e=[];return this.parentQuad.findQuads(t,e),e},n.prototype.findObjects=function(t){for(var i=[],r=0,s=this.findQuads(t);r=r.outerBounds.left&&(this.pageLeft=r.outerBounds.left,this.leftElement=r)}},n.prototype.findTop=function(t){t.first||t.second?(t.first&&this.findTop(t.first),t.second&&this.findTop(t.second)):(t.third&&this.findTop(t.third),t.fourth&&this.findTop(t.fourth));for(var e=0,i=t.objects;e=r.outerBounds.top&&(this.pageTop=r.outerBounds.top,this.topElement=r)}},n.prototype.setCurrentNode=function(t){if(this.childNode=t,t){var e=t.outerBounds;this.childLeft=Number(e.left),this.childTop=Number(e.top),this.childRight=Number(e.right),this.childBottom=Number(e.bottom)}else this.childLeft=Number.MAX_VALUE,this.childTop=Number.MAX_VALUE,this.childRight=-Number.MAX_VALUE,this.childBottom=-Number.MAX_VALUE},n.prototype.getPageBounds=function(t,e){if(this.pageLeft===Number.MAX_VALUE)return new Ne(0,0,0,0);var i=void 0!==t?Math.min(this.pageLeft,0):this.pageLeft,r=void 0!==e?Math.min(this.pageTop,0):this.pageTop;return new Ne(Math.round(i),Math.round(r),Math.round(this.pageRight-i),Math.round(this.pageBottom-r))},n.prototype.getQuad=function(t){return this.quadTable[t.id]},n}(),iae=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),nae=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return iae(t,n),function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);r>3&&s&&Object.defineProperty(t,e,s)}([I(!1)],t.prototype,"preventDefaults",void 0),t}(Ee),sae=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),o_=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},oae=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return sae(t,n),o_([I("")],t.prototype,"action",void 0),o_([I("")],t.prototype,"cursor",void 0),t}(Ee),a_=function(){function n(){this.size=20,this.intermediatePoints=[],this.gridCollection=[],this.startArray=[],this.targetGridCollection=[],this.sourceGridCollection=[],this.considerWalkable=[]}return n.prototype.lineRouting=function(t){var e=t.connectors.length;if(this.renderVirtualRegion(t),e>0)for(var i=0;i=t.right||e.right<=t.left||e.top>=t.bottom||e.bottom<=t.top)},n.prototype.findEndPoint=function(t,e,i){var r,s;if(e&&""!==t.sourcePortID&&t.sourcePortWrapper||!e&&""!==t.targetPortID&&t.targetPortWrapper){s=zo(r=e?{x:t.sourcePortWrapper.offsetX,y:t.sourcePortWrapper.offsetY}:{x:t.targetPortWrapper.offsetX,y:t.targetPortWrapper.offsetY},void 0,e?t.sourceWrapper.bounds:t.targetWrapper.bounds);var o=e?t.sourcePortWrapper.bounds:t.targetPortWrapper.bounds;r=i?"Top"===s?{x:o.topCenter.x,y:o.topCenter.y}:"Left"===s?{x:o.middleLeft.x,y:o.middleLeft.y}:"Right"===s?{x:o.middleRight.x,y:o.middleRight.y}:{x:o.bottomCenter.x,y:o.bottomCenter.y}:{x:o.center.x,y:o.center.y}}else r=e&&this.startNode||!e&&this.targetNode?e?{x:this.startNode.wrapper.offsetX,y:this.startNode.wrapper.offsetY}:{x:this.targetNode.wrapper.offsetX,y:this.targetNode.wrapper.offsetY}:e?{x:t.sourcePoint.x,y:t.sourcePoint.y}:{x:t.targetPoint.x,y:t.targetPoint.y};return r},n.prototype.refreshConnectorSegments=function(t,e,i,r){var h,c,p,f,g,y,S,b,M,w,C,s=e.sourceID,o=e.targetID,a=e.sourcePortID,l=e.targetPortID;if(function Jre(n,t){var e=0;return n.constraints&qe.LineRouting?e=n.constraints&qe.LineRouting:n.constraints&qe.InheritLineRouting&&(e=t.constraints&rt.LineRouting),e}(e,t)||r){this.startNode=t.nameTable[""+s],this.targetNode=t.nameTable[""+o],this.intermediatePoints=[],this.startArray=[],this.targetGridCollection=[],this.sourceGridCollection=[],this.startGrid=void 0,this.targetGrid=void 0;for(var D=0;D0;){var L=this.startArray.pop();if(L){for(D=0;D1&&(e.segments=[]),this.updateConnectorSegments(t,this.intermediatePoints,this.gridCollection,e,i)){this.considerWalkable=[];break e}this.targetGridCollection.splice(this.targetGridCollection.indexOf(O),1),L=this.startArray.pop()}}L&&this.findPath(L)}}}},n.prototype.checkChildNodes=function(t,e){var i=!1,r=!1;if(t.nodeId.length>=1&&!e)for(var s=0;s1&&this.targetGridCollection[0].nodeId.length>1)for(var c=0;c<=1;c++){for(var d=this.targetGridCollection[parseInt(c.toString(),10)].gridX,u=this.targetGridCollection[parseInt(c.toString(),10)].gridY,p=this.targetGridCollection[parseInt(c.toString(),10)].nodeId,f=void 0,g=0;g=e.right&&t.top<=e.top&&t.bottom>=e.bottom},n.prototype.getEndvalue=function(t,e){return this.gridCollection[t.gridX][t.gridY].walkable?t:"left"===e?this.getEndvalue(this.gridCollection[t.gridX-1][t.gridY],e):"right"===e?this.getEndvalue(this.gridCollection[t.gridX+1][t.gridY],e):"top"===e?this.getEndvalue(this.gridCollection[t.gridX][t.gridY-1],e):"bottom"===e?this.getEndvalue(this.gridCollection[t.gridX][t.gridY+1],e):t},n.prototype.changeValue=function(t,e,i){t.walkable||this.considerWalkable.push(t);for(var r,s=0;s<=e;s++)"left"===i?r=this.gridCollection[t.gridX-s][t.gridY]:"right"===i?r=this.gridCollection[t.gridX+s][t.gridY]:"top"===i?r=this.gridCollection[t.gridX][t.gridY-s]:"bottom"===i&&(r=this.gridCollection[t.gridX][t.gridY+s]),r.walkable||this.considerWalkable.push(r)},n.prototype.getIntermediatePoints=function(t){var e;for(this.intermediatePoints=[];t;)this.intermediatePoints.push({x:t.gridX,y:t.gridY}),t=t.parent;this.intermediatePoints.reverse(),this.intermediatePoints.length>=1&&void 0!==this.intermediatePoints[0]&&void 0!==this.intermediatePoints[1]&&(this.intermediatePoints[0].x===this.intermediatePoints[1].x?this.intermediatePoints[0].y=1&&u.length>1&&(g=u[u.length-2].x!==u[u.length-1].x?u[u.length-2].x>u[u.length-1].x?"Left":"Right":u[u.length-2].y>u[u.length-1].y?"Top":"Bottom"),M>=2&&v===g&&u.length>1&&u.splice(u.length-2,1),v=g);if(u&&u.length>1){for(var w=0;wD.x?S.bounds.middleLeft:S.bounds.middleRight),w===u.length-2&&""===r.targetPortID&&y&&(l=C.x>D.x?y.bounds.middleRight:y.bounds.middleLeft),0===w&&b&&(C.x=b.x,C.y=D.y=b.y),w===u.length-2&&l&&(w>0&&r.targetDecorator&&l.x-D.x<0&&Math.abs(l.x-C.x)0&&r.targetDecorator&&l.x-D.x>0&&Math.abs(l.x-C.x)D.y?S.bounds.topCenter:S.bounds.bottomCenter),w===u.length-2&&""===r.targetPortID&&y&&(l=C.y>D.y?y.bounds.bottomCenter:y.bounds.topCenter),0===w&&b&&(C.y=b.y,C.x=D.x=b.x),w===u.length-2&&l&&(w>0&&r.targetDecorator&&l.y-D.y<0&&Math.abs(l.y-C.y)0&&r.targetDecorator&&l.y-D.y>0&&Math.abs(l.y-C.y)D.x?(p="Left",f=C.x-D.x):(p="Right",f=D.x-C.x):C.y>D.y?(p="Top",f=C.y-D.y):(p="Bottom",f=D.y-C.y),o.push({type:"Orthogonal",length:f,direction:p})}}if(o&&o.length>0){var A=o[o.length-1];if(1===o.length&&(A.length-=20),A.length<10&&2===o.length&&(o.pop(),o.length>0&&(o[0].length-=20,A=o[0])),r.targetDecorator&&("Top"===A.direction||"Bottom"===A.direction)&&A.length>r.targetDecorator.height+1||("Right"===A.direction||"Left"===A.direction)&&A.length>r.targetDecorator.width+1)return r.segments=o,s&&t.connectorPropertyChange(r,{},{type:"Orthogonal",segments:o}),!0}return!1},n.prototype.findPath=function(t){for(var e,i=[],r=this.findNearestNeigbours(t,this.gridCollection,!0),s=0;sl)&&(e.x!==t.gridX||e.y!==t.gridY)&&(i.push(e),o.previousDistance=l,o.afterDistance=o.afterDistance||this.manhattan(Math.abs(e.x-this.targetGrid.gridX),Math.abs(e.y-this.targetGrid.gridY)),o.totalDistance=o.previousDistance+o.afterDistance,o.parent=t)}if(i.length>0)for(s=0;st?i*t+e:i*e+t},n.prototype.manhattan=function(t,e){return t+e},n.prototype.findNearestNeigbours=function(t,e,i){var r=[],s=t.parent;if(s){var o=(t.gridX-s.gridX)/Math.max(Math.abs(t.gridX-s.gridX),1),a=(t.gridY-s.gridY)/Math.max(Math.abs(t.gridY-s.gridY),1);0!==o?(this.isWalkable(t.gridX,t.gridY-1,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX][t.gridY-1])&&r.push(e[t.gridX][t.gridY-1]),this.isWalkable(t.gridX,t.gridY+1,!0)&&this.sourceGridCollection.indexOf(e[t.gridX][t.gridY+1])&&r.push(e[t.gridX][t.gridY+1]),this.isWalkable(t.gridX+o,t.gridY,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX+o][t.gridY])&&r.push(e[t.gridX+o][t.gridY])):0!==a&&(this.isWalkable(t.gridX-1,t.gridY,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX-1][t.gridY])&&r.push(e[t.gridX-1][t.gridY]),this.isWalkable(t.gridX+1,t.gridY,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX+1][t.gridY])&&r.push(e[t.gridX+1][t.gridY]),this.isWalkable(t.gridX,t.gridY+a,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX][t.gridY+a])&&r.push(e[t.gridX][t.gridY+a]))}else this.neigbour(t,"top",r,i),this.neigbour(t,"right",r,i),this.neigbour(t,"bottom",r,i),this.neigbour(t,"left",r,i);return r},n.prototype.neigbour=function(t,e,i,r){for(var o,s=1;s>0;){var a="top"===e||"bottom"===e?t.gridX:"left"===e?t.gridX-s:t.gridX+s,l="right"===e||"left"===e?t.gridY:"top"===e?t.gridY-s:t.gridY+s;if((o=this.gridCollection[parseInt(a.toString(),10)][parseInt(l.toString(),10)])&&(r&&-1===this.sourceGridCollection.indexOf(o)||!r&&-1===this.targetGridCollection.indexOf(o)))return i&&this.isWalkable(a,l)&&i.push(o),s;if(!(a>0&&l>0))break;s++}return null},n.prototype.resetGridColl=function(t,e,i){for(var s,r=1;r>0;){var o="top"===e||"bottom"===e?t.gridX:"left"===e?t.gridX-r:t.gridX+r,a="right"===e||"left"===e?t.gridY:"top"===e?t.gridY-r:t.gridY+r;if((s=this.gridCollection[parseInt(o.toString(),10)][parseInt(a.toString(),10)])&&(i&&-1===this.sourceGridCollection.indexOf(s)||!i&&-1===this.targetGridCollection.indexOf(s))){if(this.isWalkable(o,a))break;var l=this.gridCollection[parseInt(o.toString(),10)][parseInt(a.toString(),10)];this.considerWalkable.push(l)}if(!(o>0&&a>0))break;"top"===e||"left"===e?r--:r++}return null},n.prototype.isWalkable=function(t,e,i){if(t>=0&&t=0&&e0?1:-1,this.isWalkable(h,c-1)&&!this.isWalkable(h-a,c-1)||this.isWalkable(h,c+1)&&!this.isWalkable(h-a,c+1)))return{x:t,y:e};if(0!==l){if(l=l>0?1:-1,this.isWalkable(h-1,c)&&!this.isWalkable(h-1,c-l)||this.isWalkable(h+1,c)&&!this.isWalkable(h+1,c-l))return{x:t,y:e};if(this.findIntermediatePoints(h+1,c,h,c,s,o)||this.findIntermediatePoints(h-1,c,h,c,s,o))return{x:t,y:e}}return this.findIntermediatePoints(h+a,c+l,h,c,s,o)},n.prototype.destroy=function(){},n.prototype.getModuleName=function(){return"LineRouting"},n}(),aae=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),hae=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return aae(t,n),function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);r>3&&s&&Object.defineProperty(t,e,s)}([I(!0)],t.prototype,"inversedAlignment",void 0),t}(Ee),cae=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Oe=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},xT=function(n,t,e,i){return new(e||(e=Promise))(function(r,s){function o(h){try{l(i.next(h))}catch(c){s(c)}}function a(h){try{l(i.throw(h))}catch(c){s(c)}}function l(h){h.done?r(h.value):new e(function(c){c(h.value)}).then(o,a)}l((i=i.apply(n,t||[])).next())})},TT=function(n,t){var i,r,s,o,e={label:0,sent:function(){if(1&s[0])throw s[1];return s[1]},trys:[],ops:[]};return o={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function a(h){return function(c){return function l(h){if(i)throw new TypeError("Generator is already executing.");for(;e;)try{if(i=1,r&&(s=2&h[0]?r.return:h[0]?r.throw||((s=r.return)&&s.call(r),0):r.next)&&!(s=s.call(r,h[1])).done)return s;switch(r=0,s&&(h=[2&h[0],s.value]),h[0]){case 0:case 1:s=h;break;case 4:return e.label++,{value:h[1],done:!1};case 5:e.label++,r=h[1],h=[0];continue;case 7:h=e.ops.pop(),e.trys.pop();continue;default:if(!(s=(s=e.trys).length>0&&s[s.length-1])&&(6===h[0]||2===h[0])){e=0;continue}if(3===h[0]&&(!s||h[1]>s[0]&&h[1]0&&((!s.style||!s.style.fill)&&(o.style.fill="transparent"),(!s.style||!s.style.strokeColor)&&(o.style.strokeColor="transparent")),s.shape&&"UmlActivity"===s.shape.type&&ib(s,o),s.shape&&"SwimLane"===s.shape.type&&pF(s,o),r.nodeDefaults&&Ro(o,s,r.nodeDefaults),r.updateAnnotationText(o.annotations);if(e&&e.connectors)for(a=0;e&&e.connectors&&a0&&0===i.nodes.length)this.clearCollection(),a=!0;else{for(var g=0,v=Object.keys(e.nodes);g0&&0===i.connectors.length)this.clearCollection(!0),a=!0;else{for(var C=0,D=Object.keys(e.connectors);C0){this.renderSelector(!0);break}if(e.selectedItems.constraints){this.renderSelector(!0);break}break;case"snapSettings":this.updateSnapSettings(e);break;case"commandManager":this.initCommands();break;case"layout":o=!0;break;case"segmentThumbShape":this.updateSelector();break;case"dataSourceSettings":this.clear(),"None"===this.layout.type?a=!0:(this.initObjects(),o=!0);break;case"tooltip":l3(this);break;case"rulerSettings":this.updateRulerSettings(e);break;case"layers":this.updateLayer(e);break;case"scrollSettings":this.scrollActions|=ca.PropertyChange,this.updateScrollSettings(e),this.scrollActions&=~ca.PropertyChange,this.scrollSettings.horizontalOffset=-this.scroller.horizontalOffset||0,this.scrollSettings.verticalOffset=-this.scroller.verticalOffset||0;break;case"locale":e.locale!==i.locale&&(this.realActions|=$i.PreventDataInit,n.prototype.refresh.call(this),this.realActions&=~$i.PreventDataInit);break;case"contextMenuSettings":if(void 0!==e.contextMenuSettings.showCustomMenuOnly&&(this.contextMenuSettings.showCustomMenuOnly=e.contextMenuSettings.showCustomMenuOnly),void 0!==e.contextMenuSettings.show&&(this.contextMenuSettings.show=e.contextMenuSettings.show),e.contextMenuSettings.items){for(var A=e.contextMenuSettings.items,x=0,R=Object.keys(A);x0){for(var N=[],T=O.ports.length-1;T>=0;T--)"LineDistribution"===O.ports[parseInt(T.toString(),10)].id.split("_")[1]&&N.push(O.ports[parseInt(T.toString(),10)]);this.removePorts(O,N)}}for(T=0;T0)for(var ue=0,pe=Object.keys(e.nodes);ue0)for(var De=0,xe=Object.keys(e.connectors);De=0;o--)this.commandHandler.expandNode(r[parseInt(o.toString(),10)],this,0!==o);this.canLayout&&this.doLayout(),this.lineRoutingModule?this.connectors.sourceID!==this.connectors.targetID&&this.lineRoutingModule.lineRouting(this):this.constraints&rt.LineRouting&&console.warn('[WARNING] :: Module "LineRouting" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),this.validatePageSize(),this.renderPageBreaks(),this.diagramRenderer.renderSvgGridlines(this.snapSettings,_d(this.element.id),this.scroller.transform,this.rulerSettings,this.hRuler,this.vRuler),this.commandHandler.initSelectorWrapper(),this.notify("initial-load",{}),this.trigger("load"),this.scroller.setSize(),this.scroller.updateScrollOffsets(),this.isRefreshed||this.refreshDiagramLayer(),(this.scrollSettings.verticalOffset>0||this.scrollSettings.horizontalOffset>0)&&this.updateScrollOffset(),X.isDevice&&(this.tool=Ci.ZoomPan|Ci.SingleSelect),this.notify("initial-end",{}),this.isProtectedOnChange=!1,this.tooltipObject=l3(this),this.diagramActions=ee.Render,this.initCommands();var a=document.getElementsByClassName(this.element.id+"_hiddenUserHandleTemplate");(function Noe(n,t,e,i){var r,s,o,a,l,d=document.getElementById(i).ej2_instances[0];if(n&&t){r=GF(n);for(var u=0,p=e.userHandles;u0;)e[0].parentNode.removeChild(e[0]);var i=document.getElementById(this.element.id+"content");i&&this.element.removeChild(i);var r="measureElement";if(window[""+r]){window[""+r].usageCount-=1;var s="measureElementCount";window[""+s]--,0===window[""+s]&&(window[""+r].parentNode.removeChild(window[""+r]),window[""+r]=null)}}window.domTable={};for(var a=0;a1&&(this.callBlazorModel=!1,this.insertBlazorDiagramObjects(this.selectedItems),this.commandHandler.group(),this.callBlazorModel=!0,this.commandHandler.getBlazorOldValues())},t.prototype.unGroup=function(){this.callBlazorModel=!1,this.insertBlazorDiagramObjects(this.selectedItems),this.commandHandler.unGroup(),this.callBlazorModel=!0,this.commandHandler.getBlazorOldValues()},t.prototype.sendToBack=function(){this.commandHandler.sendToBack()},t.prototype.setActiveLayer=function(e){var i=this.commandHandler.getLayer(e);this.activeLayer=i},t.prototype.addLayer=function(e,i){this.commandHandler.addLayer(e,i)},t.prototype.removeLayer=function(e){this.commandHandler.removeLayer(e,ce())},t.prototype.moveObjects=function(e,i){$(this.layers),this.enableServerDataBinding(!1),this.commandHandler.moveObjects(e,i)},t.prototype.layerObjectUpdate=function(){},t.prototype.sendLayerBackward=function(e){this.layerObjectUpdate(),this.commandHandler.sendLayerBackward(e)},t.prototype.bringLayerForward=function(e){this.layerObjectUpdate(),this.commandHandler.bringLayerForward(e)},t.prototype.cloneLayer=function(e){this.commandHandler.cloneLayer(e)},t.prototype.bringToFront=function(){this.commandHandler.bringToFront()},t.prototype.moveForward=function(){this.commandHandler.sendForward()},t.prototype.sendBackward=function(){this.commandHandler.sendBackward()},t.prototype.getObject=function(e){return this.nameTable[""+e]},t.prototype.getNodeObject=function(e){return $(this.nameTable[""+e])},t.prototype.getConnectorObject=function(e){return $(this.nameTable[""+e])},t.prototype.getActiveLayer=function(){return this.activeLayer},t.prototype.nudgeCommand=function(e,i,r){if("object"!=typeof e&&(this.selectedItems.nodes.length||this.selectedItems.connectors.length)>0){var s=void 0;i.type&&"KEYDOWN"===i.type&&(s=i.type),this.nudge(e,void 0,void 0,s)}},t.prototype.nudge=function(e,i,r,s){var o=0,a=0;"Left"===e||"Right"===e?o=("Left"===e?-1:1)*(i||1):a=("Up"===e?-1:1)*(r||1),"KEYDOWN"===s&&(o*=5,a*=5);var h=this.selectedItems,c=this.selectedItems.wrapper.children[0];if(c instanceof ni)this.commandHandler.labelDrag(h.nodes[0],c,o,a);else{var d=$(this.selectedItems);this.protectPropertyChange(!0),this.drag(h,o,a),this.protectPropertyChange(!1);var u={type:"PositionChanged",redoObject:$(this.selectedItems),undoObject:d,category:"Internal"};this.addHistoryEntry(u)}this.refreshCanvasLayers()},t.prototype.insertBlazorDiagramObjects=function(e){},t.prototype.drag=function(e,i,r){if(this.insertBlazorDiagramObjects(e),!(this.bpmnModule&&e instanceof te&&this.bpmnModule.updateAnnotationDrag(e,this,i,r))){if(e instanceof si){if(this.preventConnectorsUpdate=!0,e.nodes&&e.nodes.length){for(var o=0,a=e.nodes;o0&&o.nodes[0].children){this.fromUndo||(this.rotateUsingButton=!0);for(var h=this.commandHandler.getAllDescendants(o.nodes[0],[]),c=0;c0&&o.nodes[0].children){var g={type:"RotationChanged",redoObject:$(e),undoObject:$(o),category:"Internal",childTable:a};this.commandHandler.addHistoryEntry(g),this.commandHandler.updateSelector()}return u},t.prototype.dragSourceEnd=function(e,i,r){this.insertBlazorDiagramObjects(e),this.commandHandler.dragSourceEnd(e,i,r),this.callBlazorModel&&this.commandHandler.getBlazorOldValues()},t.prototype.dragTargetEnd=function(e,i,r){this.insertBlazorDiagramObjects(e),this.commandHandler.dragTargetEnd(e,i,r),this.callBlazorModel&&this.commandHandler.getBlazorOldValues()},t.prototype.findObjectsUnderMouse=function(e,i){return this.eventHandler.findObjectsUnderMouse(e,i)},t.prototype.findObjectUnderMouse=function(e,i,r){return this.eventHandler.findObjectUnderMouse(e,i,r)},t.prototype.findTargetObjectUnderMouse=function(e,i,r,s,o){return this.eventHandler.findTargetUnderMouse(e,i,r,s,o)},t.prototype.findElementUnderMouse=function(e,i,r,s){return this.eventHandler.findElementUnderMouse(e,i,r,s)},t.prototype.findActionToBeDone=function(e,i,r,s){return this.eventHandler.findActionToBeDone(e,i,r,s)},t.prototype.updateConnectorPort=function(e){if(e.ports.length)for(var i=void 0,r=0,s=e.ports;r=0;s--)if(i.push(r[parseInt(s.toString(),10)]),i.length>this.historyManager.stackLimit)return i}else i=r;return i},t.prototype.getEdges=function(e){return e.outEdge?this.nameTable[e.id].outEdges:this.nameTable[e.id].inEdges},t.prototype.getParentId=function(e){return this.nameTable[""+e].parentId},t.prototype.addConnector=function(e){return this.add(e)},t.prototype.UpdateBlazorDiagramModelCollection=function(e,i,r,s){},t.prototype.UpdateBlazorDiagramModel=function(e,i,r,s){},t.prototype.UpdateBlazorLabelOrPortObjects=function(e,i,r,s){},t.prototype.addBlazorDiagramObjects=function(){},t.prototype.removeNodeEdges=function(e,i,r){var s=this.nameTable[""+e],o=r?s.outEdges:s.inEdges;if(o.length>0)for(var a=0;a0)){for(var c=0;c0))}this.removePortEdges(l,a.element.sourcePortID,a.element.id,h)}a.element.targetID&&this.removeNodeEdges(a.element.targetID,a.element.id,!1)}}this.diagramActions=this.diagramActions|ee.PublicMethod,e.id=e.id||Qe();var u=this.activeLayer;if(!a.cancel&&u&&!u.lock){if(u.objects.indexOf(e.id)<0&&!u.lock&&(u.visible||(u.visible=!0,this.dataBind()),u.objects.push(e.id)),fs(e)===de)(r=new de(this,"connectors",e,!0)).status="New",this.nameTable[r.targetID]&&"TextAnnotation"===this.nameTable[r.targetID].shape.shape&&(r.isBpmnAnnotationConnector=!0,r.constraints=r.constraints&~qe.Delete),Ro(r,e,this.connectorDefaults),this.connectors.push(r),this.initObject(r),!1===e.visible&&this.updateElementVisibility(r.wrapper,r,e.visible),this.updateEdges(r),this.insertBlazorConnector(r);else{if(Ro(r=new te(this,"nodes",e,!0),e,this.nodeDefaults),r.parentId=e.parentId?e.parentId:r.parentId,r.umlIndex=e.umlIndex,r.status="New",(o="TextAnnotation"===r.shape.shape)&&!e.isTextAnnotationCopied&&(r.inEdges=e.inEdges?e.inEdges:r.inEdges),this.nodes.push(r),this.initObject(r,u,void 0,i),o&&this.bpmnModule)for(c=0;c-1&&e.parentId&&this.nameTable[e.parentId]&&"UmlClassifier"===this.nameTable[e.parentId].shape.type){var g=this.nameTable[e.parentId];g.children.splice(r.umlIndex,0,r.id),g.wrapper.children.splice(r.umlIndex,0,r.wrapper),g.wrapper.measure(new me),g.wrapper.arrange(g.wrapper.desiredSize),this.updateDiagramObject(g)}}if(a={element:r,cause:this.diagramActions,diagramAction:this.getDiagramAction(this.diagramActions),state:"Changed",type:"Addition",cancel:!1},this.parentObject&&(a.parentId=this.parentObject.id),"helper"!==e.id&&!(this.diagramActions&ee.PreventCollectionChangeOnDragOver)&&this.triggerEvent(Ce.collectionChange,a),!(this.diagramActions&ee.UndoRedo||this.diagramActions&ee.Group||this.diagramActions&ee.PreventHistory)){var v={type:"CollectionChanged",changeType:"Insert",undoObject:$(e),redoObject:$(e),category:"Internal"};this.addHistoryEntry(v)}this.parentObject=void 0,"SVG"===this.mode&&(this.updateSvgNodes(r),this.updateTextElementValue(r),this.updateDiagramObject(r),o&&this.updateDiagramObject(this.nameTable[r.inEdges[0]]),r.shape.activity&&r.shape.activity.subProcess.processes&&r.shape.activity.subProcess.processes.length&&this.updateProcesses(r),this.updateBridging())}}if(this.protectPropertyChange(s),this.resetDiagramActions(ee.PublicMethod),r&&this.layers.length>1&&this.moveNode(r),this.views)for(var S=0,b=this.views;S=0;l--)this.moveSvgNode(a[parseInt(l.toString(),10)])}for(var h=0,c=i;h=0;o--)r[parseInt(o.toString(),10)]===e.id&&r.splice(o,1);for(var a=0;s.ports&&a=0;s--)if(i=this.nameTable[r[parseInt(s.toString(),10)]])if(this.connectorTable[i.id]=$(i),i.isBpmnAnnotationConnector){var o=this.nameTable[i.targetID];this.removeObjectsFromLayer(i);var a=this.connectors.indexOf(i);-1!==a&&this.connectors.splice(a,1),this.removeElements(i),this.removeFromAQuad(i),delete this.nameTable[i.id];var l=this.nameTable[i.sourceID];if(l){var h=l.outEdges.indexOf(i.id);-1!==h&&l.outEdges.splice(h,1)}e.id!==i.targetID&&this.remove(o)}else this.remove(i)},t.prototype.removeObjectsFromLayer=function(e){if(e.children)for(var i=0;i-1&&(_r(this,e)&&this.unSelect(e),this.layers[parseInt(s.toString(),10)].objects.splice(a,1),delete this.layers[parseInt(s.toString(),10)].zIndexTable[this.nameTable[e.id].zIndex])},t.prototype.removeElements=function(e){if("SVG"===this.mode||"Canvas"===this.mode&&"Native"===e.shape.type){var i=xt(e.id+"_groupElement",this.element.id),r=e;if(r.ports&&r.ports.length>0)for(var s=0;s0){l[parseInt(s.toString(),10)].id.indexOf("icon_content")>0&&"SVG"===this.mode&&((h=xt(l[parseInt(s.toString(),10)].id+"_shape_groupElement",this.element.id))&&h.parentNode.removeChild(h),(h=xt(l[parseInt(s.toString(),10)].id+"_rect_groupElement",this.element.id))&&h.parentNode.removeChild(h));for(var c=0,d=this.views;c=0;o--)a.children[parseInt(o.toString(),10)].children&&(l=n.nameTable[a.children[parseInt(o.toString(),10)].id])&&(l.isLane?Zv(n,l):(n.removeDependentConnector(l),n.diagramActions|=ee.PreventHistory,l.constraints&ie.Delete?n.remove(l):q3(n,l,{},!1),n.diagramActions&=~ee.PreventHistory));a&&(i=n.nameTable[a.id])&&Zv(n,i)}}(this,e),!(this.diagramActions&ee.UndoRedo||this.diagramActions&ee.PreventHistory)&&(e instanceof te||e instanceof de)){var o={type:"CollectionChanged",changeType:"Remove",undoObject:$(e),redoObject:$(e),category:"Internal"};this.diagramActions&ee.Clear||e.children&&!e.isLane&&!e.isPhase&&e.children.length>0&&this.undoRedoModule&&"None"===this.layout.type&&(this.historyManager.startGroupAction(),s=!0),(e instanceof te||e instanceof de)&&this.deleteDependentConnector&&this.removeDependentConnector(e),!e.isLane&&!e.isPhase&&!(this.diagramActions&ee.Clear)&&!this.isStackChild(e)&&this.addHistoryEntry(o)}"TextAnnotation"===e.shape.shape&&this.removeDependentConnector(e),e.children&&!e.isLane&&!e.isPhase&&(!(this.diagramActions&ee.UndoRedo)||!ce())&&this.deleteGroup(e),e.parentId&&(this.deleteChild(e,void 0,!0),this.nameTable[e.parentId]&&"UmlClassifier"===this.nameTable[e.parentId].shape.type&&(this.updateDiagramObject(this.nameTable[e.parentId]),this.updateConnectorEdges(this.nameTable[e.parentId])));var a=void 0;this.diagramActions=this.diagramActions|ee.PublicMethod;var l=this.nameTable[e.id];if(l instanceof te?("Bpmn"===l.shape.type&&this.bpmnModule&&this.bpmnModule.removeBpmnProcesses(l,this),(l.isLane||l.isPhase||"SwimLane"===l.shape.type)&&(h=l.isLane||l.isPhase?this.nameTable[l.parentId]:this.nameTable[l.id],l.isLane?Q3(this,l,h):l.isPhase&&G3(this,l,h)),-1!==(a=this.nodes.indexOf(l))&&(this.crudDeleteNodes.push(this.nameTable[l.id]),this.nodes.splice(a,1),this.updateNodeEdges(l))):(-1!==(a=this.connectors.indexOf(l))&&(this.crudDeleteNodes.push(this.nameTable[l.id]),this.connectors.splice(a,1)),this.updateEdges(l),this.spliceConnectorEdges(e,!0),this.spliceConnectorEdges(e,!1)),!this.isServerUpdate&&!(this.blazorActions&on.GroupClipboardInProcess)&&this.commandHandler.getBlazorOldValues(),s&&this.historyManager.endGroupAction(),_r(this,l)&&this.unSelect(l),!l.isPhase){if(this.removeObjectsFromLayer(e),this.currentDrawingObject&&(this.currentDrawingObject.wrapper=void 0),delete this.nameTable[e.id],i.length>0&&i[0].id===l.id&&l.parentId){var h,d=this.nameTable[l.parentId];d&&d.isLane&&"SwimLane"===this.nameTable[d.parentId].shape.type&&Y3(this,h=this.nameTable[d.parentId],d,l)}this.removeElements(l),this.updateBridging(),"SVG"!==this.mode&&this.refreshDiagramLayer(),this.diagramActions&ee.Clear||(this.removeFromAQuad(l),r={element:e,cause:this.diagramActions,diagramAction:this.getDiagramAction(this.diagramActions),state:"Changed",type:"Removal",cancel:!1},"helper"!==e.id&&this.triggerEvent(Ce.collectionChange,r),this.resetTool())}}}else if(i.length>0){this.undoRedoModule&&(this.historyManager.startGroupAction(),this.blazorActions|=on.GroupingInProgress,s=!0);for(var u=0;u=f.wrapper.bounds.width&&"Horizontal"===f.shape.orientation||this.selectedItems.wrapper.bounds.y<=f.wrapper.bounds.y+g&&this.selectedItems.wrapper.bounds.height>=f.wrapper.bounds.height-g&&"Vertical"===f.shape.orientation)&&(NI(f)||f.shape.lanes.length>1)&&this.remove(i[parseInt(u.toString(),10)])}}else this.remove(i[parseInt(u.toString(),10)])}s&&(this.blazorActions&=~on.GroupingInProgress,this.isServerUpdate=!0,this.commandHandler.getBlazorOldValues(),this.UpdateBlazorDiagramModelCollection(void 0,void 0,void 0,!0),this.historyManager.endGroupAction(),this.isServerUpdate=!1),this.clearSelection()}e&&(NI(e)||this.diagramActions&ee.Clear)||this.diagramActions&ee.UndoRedo||this.diagramActions&ee.PreventHistory||!(e instanceof te||e instanceof de)||(o={type:"ConnectionChanged",undoObject:$(e),redoObject:$(e),category:"Internal"},!e.isLane&&!e.isPhase&&!(this.diagramActions&ee.Clear)&&!this.isStackChild(e)&&this.addHistoryEntry(o)),this.tooltipObject.close()},t.prototype.isStackChild=function(e){var i,r=this.nameTable[e.parentId];if(e&&e.parentId&&r.container&&"Stack"===r.container.type&&"UmlClassifier"!==this.nameTable[e.parentId].shape.type){i=!0;var s={sourceIndex:r.wrapper.children.indexOf(e.wrapper),source:e,target:void 0,targetIndex:void 0};this.diagramActions&ee.UndoRedo||this.addHistoryEntry({type:"StackChildPositionChanged",redoObject:{sourceIndex:void 0,source:e,target:void 0,targetIndex:void 0},undoObject:s,category:"Internal"})}return i},t.prototype.deleteChild=function(e,i,r){var s;if(s="string"==typeof e?e:e.id,(i=i?this.nameTable[i.id]:this.nameTable[e.parentId])&&i.children){for(var o=0;o=0;i--)this.removeLayer(this.layers[parseInt(i.toString(),10)].id);this.commandHandler.addLayer({id:"default_layer",visible:!0,lock:!1,objects:[],zIndex:0,objectZIndex:-1,zIndexTable:{}},null,!0),this.setActiveLayer(this.layers[this.layers.length-1].id)},t.prototype.clearObjects=function(e){var i=[];i=e||(i=i.concat(this.nodes)).concat(this.connectors),this.diagramActions=this.diagramActions|ee.Clear;for(var r=0,s=i;r0||"Text"===e.shape.type))if("Text"===e.shape.type)i=e.wrapper.children[0].id.split("_")[1];else for(var f=e.annotations.length-1;f>=0;f--)e.annotations[parseInt(f.toString(),10)].visibility&&(i=e.annotations[parseInt(f.toString(),10)].id);i&&(u=this.getWrapper(e.wrapper,i))}if(e&&u&&!(u instanceof Jn)&&(!function sne(n,t){return"Text"===t.shape.type?t.constraints&ie.ReadOnly:t.constraints&(t instanceof de?qe.ReadOnly:ie.ReadOnly)?n.constraints&Lr.InheritReadOnly?1:0:n.constraints&Lr.ReadOnly?1:0}(u,e)||p)){var g=u.style,v=void 0;v=90>(v=u.bounds.width50?50:e.width,u.style.fontSize)),e.parentId&&"UmlClassifier"===this.nameTable[e.parentId].shape.type?(l.width=e.wrapper.bounds.width-20,c=(e.wrapper.bounds.center.x+r.tx)*r.scale-l.width/2*s-2.5,d=(e.wrapper.bounds.center.y+r.ty)*r.scale-l.height/2*s-3,u.style.textAlign="Left"):(l.width=Math.max(l.width,50),c=(u.bounds.center.x+r.tx)*r.scale-l.width/2*s-2.5,d=(u.bounds.center.y+r.ty)*r.scale-l.height/2*s-3),Ho(y,{id:this.element.id+"_editTextBoxDiv",style:"position: absolute;left:"+c+"px;top:"+d+"px;width:"+(l.width+1)*s+"px;height:"+l.height*s+"px; containerName:"+e.id+";"}),Ho(S,{"aria-label":a,id:this.element.id+"_editBox",style:"width:"+(l.width+1)*s+"px;height:"+l.height*s+"px;resize: none;outline: none;overflow: hidden;;font-family:"+g.fontFamily+";font-size:"+g.fontSize*s+"px;text-align:"+u.style.textAlign.toLocaleLowerCase()+";",class:"e-diagram-text-edit"}),S.style.fontWeight=g.bold?"bold":"",S.style.fontStyle=g.italic?"italic":"",S.style.lineHeight=(1.2*g.fontSize+"px;").toString(),S.style.textDecoration=g.textDecoration?g.textDecoration:"",this.activeLabel.parentId=e.id,this.activeLabel.id=i,u.visible=!1,this.updateDiagramObject(e),this.diagramActions=this.diagramActions|ee.TextEdit,this.isTriggerEvent||(E.add(S,"input",this.eventHandler.inputChange,this.eventHandler),E.add(S,"focusout",this.focusOutEdit,this),S.select())}}}},t.prototype.updateConnectorfixedUserHandles=function(e){if(e.fixedUserHandles.length)for(var i=void 0,r=0,s=e.fixedUserHandles;r0&&this.mindMapChartModule.updateLayout(o,this.nameTable,this.layout,l,this.dataSourceSettings.id,this.dataSourceSettings.root),e=!0;else if(this.radialTreeModule)this.radialTreeModule.updateLayout(o,this.nameTable,this.layout,l),e=!0;else if(this.symmetricalLayoutModule)this.symmetricalLayoutModule.maxIteration=this.layout.maxIteration,this.symmetricalLayoutModule.springLength=this.layout.springLength,this.symmetricalLayoutModule.springFactor=this.layout.springFactor,this.symmetricalLayoutModule.updateLayout(o,this.connectors,this.symmetricalLayoutModule,this.nameTable,this.layout,l),e=!0;else if(this.complexHierarchicalTreeModule){this.canDistribute(a,r)&&(this.lineDistributionModule.diagram=this,this.connectors.forEach(function(R){R.obstaclePointCollection=[]}));var c=this.complexHierarchicalTreeModule.getLayoutNodesCollection(this.nodes);c.length>0&&this.complexHierarchicalTreeModule.doLayout(c,this.nameTable,this.layout,l,this),e=!0,this.canDistribute(a,r)&&this.lineDistributionModule.initLineDistribution(this.layout,this)}else this.flowchartLayoutModule?(this.flowchartLayoutModule.updateLayout(this.nodes,this),e=!0):console.warn("[WARNING] :: Module "+("OrganizationalChart"===this.layout.type?"HierarchicalTree":this.layout.type)+" is not available in Diagram component! You either misspelled the module name or forgot to load it.");if(e){this.preventDiagramUpdate=!0;for(var u={},f=0,g=o;f0)for(var S=0;S0)for(var M=0;M0)for(var s=0,o=r.ports;s0&&function Rse(n){var t,e,i,r=[];for(t=0;t0&&y.connectors[w].bezierSettings&&y.connectors[w].bezierSettings.allowSegmentsReset&&(y.connectors[w].segments=[]);if(t.connectors=y.connectors||[],t.dataSourceSettings=y.dataSourceSettings||{},t.dataSourceSettings.doBinding=i,t.height=y.height||"100%",t.setNodeTemplate=r,t.getConnectorDefaults=v,t.getNodeDefaults=g,t.getCustomProperty=o,t.mode=y.mode||"SVG",y.nodes)for(w=0;w0)){var r=this.nodes.filter(function(a){return 0===a.inEdges.length})[0],s=this.convertMindmapToMermaid(r,0);i.push(s),this.updateTextDataSource(i,r.outEdges,1),e=(i=i.filter(function(a){return""!==a.trim()})).join("\n")}return e},t.prototype.updateTextDataSource=function(e,i,r){for(var s=0;s0&&this.updateTextDataSource(e,h,r+1),s++}},t.prototype.convertMindmapToMermaid=function(e,i){var r=e.id,o=" ".repeat(2*(i+1)),a=e.annotations.length>0?e.annotations[0].content.replace(/\n/g," "):"",l=o+a,h=o+r;if(e.shape&&"Basic"===e.shape.type){var c=e.shape;"Rectangle"===c.shape?l=h+"["+a+"]":"Ellipse"===c.shape?l=h+"(("+a+"))":"Hexagon"===c.shape&&(l=h+"{{"+a+"}}")}else if(e.shape&&"Flow"===e.shape.type)"Terminator"===e.shape.shape&&(l=h+"("+a+")");else if(e.shape&&"Path"===e.shape.type){var u=e.shape;u.data===this.bangShape?l=h+"))"+a+"((":u.data===this.cloudShape&&(l=h+")"+a+"(")}return l},t.prototype.saveFlowDiagramInMermaidFormat=function(){var e=this,i=[],r="graph TD\n",s={nodes:this.nodes,edges:this.connectors};return s.nodes.reduce(function(a,l){return a[l.id]=l.annotations.length?l.annotations[0].content:"",a},{}),s.edges.forEach(function(a){var l=a.sourceID,h=a.targetID,p=e.nameTable[""+h],f=e.getNodeShape(e.nameTable[""+l]),g=e.getNodeShape(p),v=a.annotations[0]&&""!==a.annotations[0].content?"|"+a.annotations[0].content+"|":"";-1===i.indexOf(l)?i.push(l):f="",-1===i.indexOf(h)?i.push(h):g="";var y=e.arrowType(a);r+=" "+l+f+" "+y+v+" "+h+g+"\n"}),s.nodes.forEach(function(a){r+=" style "+a.id+" fill:"+a.style.fill+",stroke:"+a.style.strokeColor+",stroke-width:"+a.style.strokeWidth+"px;\n"}),r},t.prototype.arrowType=function(e){var i=e.targetDecorator.shape;return e.style.opacity<1?"~~~":""!==e.style.strokeDashArray?"-.->":"Arrow"===i?e.style.strokeWidth>1?"==>":"--\x3e":"None"===i?"---":"--\x3e"},t.prototype.getNodeShape=function(e){var i=e.annotations.length>0?e.annotations[0].content:"",r=e.shape.shape;if(!r){var s=e.shape.data;return"M 0 0 A 1 1 0 0 0 7 0 A 1 1 0 0 0 0 0 M -1 0 A 1 1 0 0 0 8 0 A 1 1 0 0 0 -1 0"===s?"((("+i+")))":"M 0 0 L 1 -1 L 5 -1 L 6 0 L 0 0"===s?"[/"+i+"\\]":"M 0 1 L 0 6 C 2 7 4 7 6 6 L 6 1 C 5 0 1 0 0 1 C 1 2 5 2 6 1"===s?"[("+i+")]":"M 0 0 L 12 0 L 14 2 L 2 2 L 0 0"===s?"[\\"+i+"\\]":"M 0 0 L 5 0 L 4 1 L 1 1 L 0 0"===s?"[\\"+i+"/]":"M 0 0 L 2 -2 L 11 -2 L 13 0 L 11 2 L 2 2 L 0 0"===s?"{{"+i+"}}":">"+i+"]"}switch(r){case"Terminator":return"(["+i+"])";case"Process":default:return"["+i+"]";case"Decision":return"{"+i+"}";case"Parallelogram":return"[/"+i+"/]";case"Ellipse":return"(("+i+"))";case"PreDefinedProcess":return"[["+i+"]]"}},t.prototype.loadDiagramFromMermaid=function(e){this.layout&&"Flowchart"===this.layout.type&&this.flowchartLayoutModule?this.convertMermaidToFlowChart(e):this.layout&&"MindMap"===this.layout.type&&this.mindMapChartModule?this.convertMermaidToMindmap(e):console.warn('[WARNING] :: Module "FlowchartLayout" or "MindMap" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.countLeadingSpaces=function(e){for(var i=0,r=e.length;i0});this.clear(),this.mermaidNodeBaseCollection=[];var r=[],s={text:"",children:[],currentLevel:0,branch:"Left"},o=[],l=!1,h=!1,c=!1;if(i.length>0){for(var d=function(M){var w=i[parseInt(M.toString(),10)],C=0,D="",A=u.countLeadingSpaces(w),x=w.includes('"`');if(h=w.includes('`"'),c=(l=!!x||l)||c?c:0===A&&M>0,l&&h&&!x)return s.text+="\n"+w,l=!1,"continue";if(!x&&l)return s.text+="\n"+w,"continue";if(l=!h&&l,w.length>0&&(/\s/.test(w[0])&&M>0||0===A)){if(-1!==o.findIndex(function(B){return B.space===A.toString()}))for(var L=o.length-1;L>=0;L--){var O=o[parseInt(L.toString(),10)];if((N=parseFloat(O.space))>A)o.splice(L,1);else{if(N=0;L--){var N,T=o[parseInt(L.toString(),10)];if(!((N=parseFloat(T.space))>A)){var P=o[o.length-1];o.push({space:A.toString(),level:P.level+1});break}o.splice(L,1)}C=o[o.length-1].level}D=w.trim().replace(/^[+-]/,"")}var _={text:D,branch:void 0,children:[],currentLevel:0===M?0:C-1};if(r.length>0){for(;r.length>=C&&0!==r.length;)r.pop();r.length>0&&r[r.length-1].children.push(_)}r.push(_),s=_},u=this,p=0;p0){var c=h[h.length-1];c.arrowType=a[2],""!==a[3]&&(c.label&&c.label.some(function(d){return d.trim().length>0})?c.label.push(a[3]):(c.label=[],c.label[c.parentId.length-1]=a[3]))}h.filter(function(d){return d.parentId&&0===d.parentId.length}).forEach(function(d){d.parentId=null}),i=i.concat(h)}}this.createFlowChart(i),this.doLayout(),this.clearHistory()},t.prototype.createFlowChart=function(e){for(var i=[],r=0;r1)for(var h=0;h|---|--\s*.*?\s*-->|~~~|==>|===|==\s*.*?\s*==>|\s*-\.\s*->|\s*-\.\s*-|\s*-\.\s*.*?\s*\.\s*->|\s*-\..*?\.\s*->)(.*)$/);if(l){i=l[1].trim();var h=l[2].trim();r=l[3].trim();var d=h.match(/(-\.|\\-\\-|==|--|~~)(.*?)(\1>|\.->|==>|\\->|~~>)/),u=void 0,p="";o=null!==(u=d?{text:d[2].trim()||null,arrowType:d[1]+d[3]}:{text:null,arrowType:h}).text?u.text:"",s=(p=u.arrowType).includes("--\x3e")?"single-line-arrow":p.includes("---")?"single-line":p.includes("==>")?"double-line-arrow":p.includes("==")?"double-line":p.includes("~~~")?"wiggly-arrow":p.includes("-.->")||p.includes(".->")?"dotted-arrow":p.includes("-.-")||p.includes(".-")?"dotted":"single-line-arrow"}return[i,r,s,o]},t.prototype.parseStyle=function(e,i){if(e.startsWith("style")){var s=e.match(/^style\s+(\w+)\s+fill:([^,]+),stroke:([^,]+),stroke-width:(\d+)px;/);if(s){var c={id:s[1],fill:s[2],stroke:s[3],strokeWidth:parseInt(s[4],10)},d=i.filter(function(u){return u.id===c.id});d[0].color=c.fill,d[0].stroke=c.stroke,d[0].strokeWidth=c.strokeWidth}}},t.prototype.getNodeData=function(e,i,r){for(var s=[],o=null,a=null,l=0,h="",c=function(v){var y=e[parseInt(v.toString(),10)],S=d.splitNested(y);if(S[0].includes("|")){var b=S[0].match(/\|([^|]*)\|/);b&&(h=b[1]);var M=S[0].split("|");M.length>=3&&(S[0]=M[2].trim())}var w=S[0].trim();if(0===v?o=w:a=w,i.find(function(L){return L.id===w}))l++;else{var D=S.length>1?S[1]:S[0],A=d.getShape(D),x=D.replace(/[\\[\]\\(\\)\\{\\}\\{\\}\\/>]/g,"");s.push({id:w,name:x,shape:A,color:"white",parentId:[]})}},d=this,u=0;u"===h?0===s?(r.trim().length>0&&i.push(r.trim()),r=h,o=h,s++):(r+=h,s++):"]"===h||"}"===h||")"===h?1===s&&h===o?(i.push((r+=h).trim()),r="",s--):s>1?(r+=h,s--):r+=h:r+=h}return r.trim().length>0&&i.push(r.trim()),i},t.prototype.getShape=function(e){var i={};return e.startsWith("(((")?i={type:"Path",data:"M 0 0 A 1 1 0 0 0 7 0 A 1 1 0 0 0 0 0 M -1 0 A 1 1 0 0 0 8 0 A 1 1 0 0 0 -1 0"}:e.startsWith("((")?i={shape:"Ellipse",type:"Basic"}:e.startsWith("([")?i={type:"Flow",shape:"Terminator"}:e.startsWith("(")?i={type:"Flow",shape:"Process"}:e.startsWith("[[")?i={type:"Flow",shape:"PreDefinedProcess"}:e.startsWith("[/")?i=e.endsWith("/]")?{type:"Basic",shape:"Parallelogram"}:{type:"Path",data:"M 0 0 L 1 -1 L 5 -1 L 6 0 L 0 0"}:e.startsWith("[(")?i={type:"Path",data:"M 0 1 L 0 6 C 2 7 4 7 6 6 L 6 1 C 5 0 1 0 0 1 C 1 2 5 2 6 1"}:e.startsWith("[\\")?i=e.endsWith("\\]")?{type:"Path",data:"M 0 0 L 12 0 L 14 2 L 2 2 L 0 0"}:{type:"Path",data:"M 0 0 L 5 0 L 4 1 L 1 1 L 0 0"}:e.startsWith("[")?i={type:"Basic",shape:"Rectangle"}:e.startsWith("{{")?i={type:"Path",data:"M 0 0 L 2 -2 L 11 -2 L 13 0 L 11 2 L 2 2 L 0 0"}:e.startsWith("{")?i={type:"Flow",shape:"Decision"}:e.startsWith(">")&&(i={type:"Path",data:"M 0 0 L 8 0 L 8 2 L 0 2 L 2 1 L 0 0"}),i},t.prototype.getDiagramContent=function(e){return this.printandExportModule?this.printandExportModule.getDiagramContent(e):(console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),"")},t.prototype.exportImage=function(e,i){this.printandExportModule?this.printandExportModule.exportImages(e,i):console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.printImage=function(e,i){this.printandExportModule?(i.printOptions=!0,this.printandExportModule.exportImages(e,i)):console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.setStackLimit=function(e){this.undoRedoModule&&e&&(this.historyManager.stackLimit=e,this.undoRedoModule.applyLimit(this.historyManager.currentEntry,e,this,!0))},t.prototype.clearHistory=function(){this.undoRedoModule&&this.undoRedoModule.clearHistory(this)},t.prototype.getDiagramBounds=function(){if(this.printandExportModule){var e=this.printandExportModule.getDiagramBounds("",{});return e.width=e.width>this.scrollSettings.viewPortWidth?e.width+(e.x>0?e.x:0):this.scrollSettings.viewPortWidth,e.height=e.height>this.scrollSettings.viewPortHeight?e.height+(e.y>0?e.y:0):this.scrollSettings.viewPortHeight,e.x=e.x>0?0:e.x,e.y=e.y>0?0:e.y,e}return console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),new Ne},t.prototype.exportDiagram=function(e){return this.printandExportModule?this.printandExportModule.exportDiagram(e):(console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),"")},t.prototype.print=function(e){this.printandExportModule?this.printandExportModule.print(e):console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.addPorts=function(e,i){var s;this.protectPropertyChange(!0),e=this.nameTable[e.id]||e,i.length>1&&this.startGroupAction();for(var o=function(h){if(e.ports.some(function(y){return y.id===i[parseInt(h.toString(),10)].id}))return"continue";if(e instanceof te?(s=new Es(e,"ports",i[parseInt(h.toString(),10)],!0),e.ports.push(s)):e instanceof de&&(s=new xc(e,"ports",i[parseInt(h.toString(),10)],!0),e.ports.push(s)),e.children)for(var c=e.wrapper,d=0;d1&&this.endGroupAction(),e.wrapper.measure(new me(e.width,e.height)),e.wrapper.arrange(e.wrapper.desiredSize),this.updateDiagramObject(e),this.protectPropertyChange(!1)},t.prototype.addConstraints=function(e,i){return e|i},t.prototype.removeConstraints=function(e,i){return e&~i},t.prototype.addNodeLabels=function(e,i){this.addLabels(e,i)},t.prototype.addConnectorLabels=function(e,i){this.addLabels(e,i)},t.prototype.addLabels=function(e,i){this.protectPropertyChange(!0);var s,r=(e=this.nameTable[e.id]||e).wrapper;i.length>1&&this.startGroupAction();for(var o=0;o1&&this.endGroupAction(),e.wrapper.measure(new me(r.width,r.height)),e.wrapper.arrange(r.desiredSize),this.updateDiagramObject(e),this.protectPropertyChange(!1),this.refreshCanvasLayers()},t.prototype.addChildToUmlNode=function(e,i,r){var s,o,a,l,h="NoWrap";"Class"===e.shape.classifier||"Interface"===e.shape.classifier?"Method"===r?(o=new dm(e,"",i),"Class"===e.shape.classifier?(e.shape.classShape.methods.push(o),s=e.shape.classShape):"Interface"===e.shape.classifier&&(e.shape.interfaceShape.methods.push(o),s=e.shape.interfaceShape),function soe(n,t,e,i){if(e.methods&&e.methods.length){var r=e.methods,s="",o="",a=void 0,l=1,h=void 0,c=0,d=0,u=n.shape,g="Class"===u.classifier?u.classShape:u.interfaceShape;1===r.length?g.attributes.length>0?(c=g.attributes.filter(function(w){return w.isSeparator}).length,h=(l=2+g.attributes.length+c)+1,aT(n,t,l)):h=l+1:(c=g.attributes.filter(function(w){return w.isSeparator}).length,d=g.methods.filter(function(w){return w.isSeparator}).length,h=(l=2+g.attributes.length+c+g.methods.length+d)+1);for(var v=0;v1&&this.startGroupAction();for(var r=i.length-1;r>=0;r--)if(e.children&&e.children.length>0){var s=e.wrapper.children.filter(function(o){return o.id===e.id+"group_container"});s&&s.length>0&&this.removelabelExtension(e,i,r,s[0])}else this.removelabelExtension(e,i,r,e.wrapper);i.length>1&&this.endGroupAction(),this.refreshCanvasLayers()},t.prototype.removePortsExtenion=function(e,i,r,s){for(var o=0;o1&&this.startGroupAction();for(var r=i.length-1;r>=0;r--)if(e.children&&e.children.length>0)for(var s=0;s1&&this.endGroupAction()},t.prototype.getSizeValue=function(e,i){var r;return r=e.toString().indexOf("px")>0?e.toString():e.toString().indexOf("%")>0?void 0!==i?"100%":e.toString():e.toString()+"px",i&&(qa(this),r="calc("+r+" - "+i+"px)"),r},t.prototype.renderRulers=function(){this.rulerSettings.showRulers?(function ise(n){var t=qa(n),i=Tt("div",{id:n.element.id+"_overlapRuler",style:"height:"+t.height+"px;width:"+t.width+"px;position:absolute;left:0;top:0",class:"e-ruler-overlap"});n.element.insertBefore(i,n.element.firstChild)}(this),oF(this,!0),oF(this,!1)):qx(this)},t.prototype.intOffPageBackground=function(){var e=new me;e=qa(this);var i=document.getElementById(this.element.id+"content"),r=this.getSizeValue(this.width,e.width),s=this.getSizeValue(this.height,e.height),o=this.rulerSettings.showRulers?"width:"+r+"; height:"+s+";top:"+e.height+"px;left:"+e.width+"px;overflow: scroll;position:absolute;overflow:auto;":"width:"+r+"; height:"+s+";position:absolute; left:0px; top:0px;overflow: auto;",a={id:this.element.id+"content",tabindex:"0",style:o};i?(this.diagramCanvas=i,Za(this.diagramCanvas,o)):(this.diagramCanvas=Tt("div",a),this.element.appendChild(this.diagramCanvas)),this.diagramCanvas.style.background=this.backgroundColor},t.prototype.initDiagram=function(){this.intOffPageBackground(),Ho(this.element,{style:"width:"+this.getSizeValue(this.width)+"; height:"+this.getSizeValue(this.height)+";position:relative;overflow:hidden;"})},t.prototype.renderHiddenUserHandleTemplateLayer=function(e){var r=Tt("div",{class:this.element.id+"_hiddenUserHandleTemplate",style:"width:"+e.width+"px; height:"+e.height+"px;visibility:hidden ; overflow: hidden;"});this.element.appendChild(r)},t.prototype.renderBackgroundLayer=function(e,i){var r=this.createSvg(this.element.id+"_backgroundLayer_svg",e.width,e.height);Za(r,i);var s=Bi("g",{id:this.element.id+"_backgroundImageLayer",class:"e-background-image-layer"});r.appendChild(s);var a=Bi("g",{id:this.element.id+"_backgroundLayer",class:"e-background-layer"});r.appendChild(a),this.diagramCanvas.appendChild(r)},t.prototype.renderGridLayer=function(e,i){var r=this.createSvg(this.element.id+"_gridline_svg",e.width,e.height);r.setAttribute("class","e-grid-layer");var s=Bi("g",{id:this.element.id+"_gridline"}),o=Bi("rect",{id:this.element.id+"_grid_rect",x:"0",y:"0",width:"100%",height:"100%"});if(om()){var a=new URL(window.location.href);o.setAttribute("fill",""!==a.search?"url(#"+this.element.id+"_pattern)":"url("+location.protocol+"//"+location.host+location.pathname+"#"+this.element.id+"_pattern)")}else o.setAttribute("fill","url(#"+this.element.id+"_pattern)");s.appendChild(o),r.appendChild(s),this.diagramCanvas.appendChild(r),oi(r,{style:i})},t.prototype.renderDiagramLayer=function(e,i){if(this.diagramLayerDiv=Tt("div",{id:this.element.id+"_diagramLayer_div",style:"width:"+e.width+"px; height:"+e.height+"px;"+i}),"SVG"===this.mode){var s=this.createSvg(this.element.id+"_diagramLayer_svg",e.width,e.height);s.style["pointer-events"]="none",s.setAttribute("class","e-diagram-layer");var o=Bi("g",{id:this.element.id+"_diagramLayer"}),a=Bi("g",{});this.diagramLayer=o,s.style["pointer-events"]="all",a.appendChild(o),s.appendChild(a),this.diagramLayerDiv.appendChild(s)}else this.diagramLayer=bo.createCanvas(this.element.id+"_diagram",e.width,e.height),Za(this.diagramLayer,"position:absolute;left:0px;top:0px;"),this.diagramLayerDiv.appendChild(this.diagramLayer);this.diagramCanvas.appendChild(this.diagramLayerDiv)},t.prototype.initLayers=function(){var e="position:absolute;top:0px;left:0px;overflow:hidden;pointer-events:none;",r=document.getElementById(this.element.id).getBoundingClientRect(),s=function Loe(){var n=Tt("div",{style:"visibility:hidden; width: 100px"});document.body.appendChild(n);var t=n.getBoundingClientRect().width;n.style.overflow="scroll";var e=Tt("div",{style:"width:100%"});n.appendChild(e);var i=e.getBoundingClientRect().width;return n.parentNode.removeChild(n),t-i}();this.scroller.scrollerWidth=s,this.scroller.setViewPortSize(r.width,r.height),this.renderRulers();var o="measureElement";window[""+o]&&(window[""+o]=null,document.getElementById("measureElement").remove()),function WF(){var n="measureElement";if(window[""+n])window[""+n].usageCount+=1;else{var t=Tt("div",{id:"measureElement",style:"visibility:hidden ; height: 0px ; width: 0px; overflow: hidden;"}),e=Tt("span",{style:"display:inline-block ; line-height: normal"});t.appendChild(e);var i=Tt("img",{alt:"measureElementImage",src:"data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7"});t.appendChild(i);var r=document.createElementNS("http://www.w3.org/2000/svg","svg");r.setAttribute("xmlns:xlink","http://www.w3.org/1999/xlink"),t.appendChild(r);var s=document.createElementNS("http://www.w3.org/2000/svg","path");s.setAttribute("d",""),r.appendChild(s),document.createTextNode("");var a=document.createElementNS("http://www.w3.org/2000/svg","text");a.setAttributeNS("http://www.w3.org/XML/1998/namespace","xml:space","preserve"),r.appendChild(a),window[""+n]=t,window[""+n].usageCount=1,document.body.appendChild(t);var l="measureElementCount";window[""+l]?window[""+l]++:window[""+l]=1}}(),this.renderBackgroundLayer(r,e),this.renderGridLayer(r,e),this.renderDiagramLayer(r,e),this.renderHTMLLayer(r,e),this.renderPortsExpandLayer(r,e),this.renderNativeLayer(r,e),this.renderAdornerLayer(r,e),this.renderHiddenUserHandleTemplateLayer(r)},t.prototype.renderAdornerLayer=function(e,i){var r=Tt("div",{id:this.element.id+"_diagramAdornerLayer",style:"width:"+e.width+"px;height:"+e.height+"px;"+i}),s=Tt("div",{id:this.element.id+"_diagramUserHandleLayer",style:"width:"+e.width+"px;height:"+e.height+"px;"+i});s.setAttribute("class","e-userHandle-layer"),r.appendChild(s);var o=this.createSvg(this.element.id+"_diagramAdorner_svg",e.width,e.height);o.setAttribute("class","e-adorner-layer"),o.style["pointer-events"]="none",this.adornerLayer=Bi("g",{id:this.element.id+"_diagramAdorner"}),this.adornerLayer.style[" pointer-events"]="all",o.appendChild(this.adornerLayer),r.appendChild(o),this.diagramCanvas.appendChild(r);var a=Bi("g",{id:this.element.id+"_SelectorElement"});this.adornerLayer.appendChild(a),oi(o,{style:"pointer-events:none;"})},t.prototype.renderPortsExpandLayer=function(e,i){var r=this.createSvg(this.element.id+"_diagramPorts_svg",e.width,e.height);r.setAttribute("class","e-ports-expand-layer");var s=Bi("g",{id:this.element.id+"_diagramPorts",class:"e-ports-layer",style:"pointer-events: all;"});r.appendChild(s);var o=Bi("g",{id:this.element.id+"_diagramExpander",class:"e-expand-layer",style:"pointer-events: all;"});r.appendChild(o),this.diagramCanvas.appendChild(r),oi(r,{style:i})},t.prototype.renderHTMLLayer=function(e,i){this.htmlLayer=Tt("div",{id:this.element.id+"_htmlLayer",style:"width:"+e.width+"px; height:"+e.height+"px;position:absolute;top:0px;left:0px;overflow:hidden;pointer-events:none;",class:"e-html-layer"});var r=Tt("div",{id:this.element.id+"_htmlLayer_div",style:"position:absolute;top:0px;left:0px;pointer-events:all;"});this.htmlLayer.appendChild(r),this.diagramCanvas.appendChild(this.htmlLayer)},t.prototype.renderNativeLayer=function(e,i){var r=this.createSvg(this.element.id+"_nativeLayer_svg",e.width,e.height),s=Bi("g",{id:this.element.id+"_nativeLayer",style:"pointer-events:all;"});r.appendChild(s),this.diagramLayerDiv.appendChild(r),oi(r,{class:"e-native-layer",style:i})},t.prototype.createSvg=function(e,i,r){var s=document.createElementNS("http://www.w3.org/2000/svg","svg");return oi(s,{id:e,width:i,height:r}),s},t.prototype.updateBazorShape=function(){for(var e=0;e1,i=[],r={},s={},o=[],a=0,l=this.nodes;a0||b&&b.children&&b.children.length>0)&&(M=!1),S&&S.wrapper&&b&&b.wrapper&&M?this.initConnectors(r[""+h],f):i.push(r[""+h])}else b=r[y.targetID],(S=r[y.sourceID])&&S.children&&S.children.length>0||b&&b.children&&b.children.length>0?i.push(r[""+h]):this.initConnectors(r[""+h],f);else r[""+h].children?o.push(h):r[""+h].shape instanceof uT&&r[""+h].shape.activity.subProcess.processes&&r[""+h].shape.activity.subProcess.processes.length>0?s[r[""+h].id]=h:this.initNodes(r[""+h],f);if(this.bpmnModule)for(var w=0,C=this.bpmnModule.bpmnTextAnnotationConnector;w-1&&-1===r.indexOf(c)&&-1===s.indexOf(c)&&r.splice(0,0,c);-1===r.indexOf(o)&&s.push(o)}return r.concat(s)},t.prototype.addToLayer=function(e,i){var r;if(i&&(r=this.commandHandler.getObjectLayer(e.id)),(!i||!r)&&-1===this.activeLayer.objects.indexOf(e.id)&&this.activeLayer.objects.push(e.id),(e instanceof te||e instanceof de)&&("SwimLane"!==e.shape.type||e.children&&e.children.length>0)){if(e.parentId){var s=this.swimlaneZIndexTable[e.parentId],o=this.swimlaneChildTable[e.id];(s&&-1!==s||o&&-1!==o)&&(e.zIndex=this.swimlaneChildTable[e.id])}e instanceof de&&e.sourceID&&e.targetID?-1!==this.activeLayer.objects.indexOf(e.sourceID)&&-1!==this.activeLayer.objects.indexOf(e.targetID)&&this.setZIndex(r||this.activeLayer,e):this.setZIndex(r||this.activeLayer,e)}},t.prototype.updateLayer=function(e){for(var i=0,r=Object.keys(e.layers);i0)for(r=0;rs;l--)r.zIndexTable[parseInt(l.toString(),10)]=r.zIndexTable[l-1],this.nameTable[r.zIndexTable[parseInt(l.toString(),10)]]&&(this.nameTable[r.zIndexTable[parseInt(l.toString(),10)]].zIndex=l);r.zIndexTable[parseInt(a.toString(),10)]=i.id}}},t.prototype.initializeDiagramLayers=function(){for(var e=0;ethis.layers[parseInt(a.toString(),10)].zIndex&&(i=this.layers[parseInt(e.toString(),10)],this.layers[parseInt(e.toString(),10)]=this.layers[parseInt(a.toString(),10)],this.layers[parseInt(a.toString(),10)]=i);0===this.layers.length&&this.commandHandler.addLayer({id:"default_layer",visible:!0,lock:!1,objects:[],zIndex:0,objectZIndex:-1,zIndexTable:{}},null,!0),this.setActiveLayer(this.layers[this.layers.length-1].id)},t.prototype.resetTool=function(){this.eventHandler.resetTool()},t.prototype.initObjectExtend=function(e,i,r){if(r){var s=this.commandHandler.checkBoundaryConstraints(void 0,void 0,e.wrapper.bounds,!0);if("SwimLane"===e.shape.type)for(var o=0,a=Object.keys(i.zIndexTable);o0)&&this.setZIndex(i,e)),e instanceof te){if(r){if("helper"!==e.id&&(o=Zi(this.getNodeDefaults))){if((a=o(e,this))&&a.ports)for(var l=0;l0)for(l=0;l0&&!e.container||e.processId){var r=this.nameTable[e.id];if(!(this.realActions&$i.PreventScale||this.realActions&$i.PreventDrag)){if(r.offsetX&&(this.realActions&$i.EnableGroupAction||!(this.diagramActions&ee.UndoRedo||this.diagramActions&ee.ToolAction||this.diagramActions&ee.PublicMethod))){this.realActions|=$i.PreventScale;var s=r.offsetX-e.wrapper.offsetX;r.offsetX=e.wrapper.offsetX;var o=r.offsetY-e.wrapper.offsetY;r.offsetY=e.wrapper.offsetY,s+o!==0&&this.drag(r,s,o),this.realActions&=~$i.PreventScale}else r.offsetX=e.wrapper.offsetX;r.offsetY&&(this.realActions&$i.EnableGroupAction||!(this.diagramActions&ee.UndoRedo||this.diagramActions&ee.ToolAction||this.diagramActions&ee.PublicMethod))?(this.realActions|=$i.PreventScale,o=r.offsetY-e.wrapper.offsetY,r.offsetY=e.wrapper.offsetY,this.drag(r,0,o),this.realActions&=~$i.PreventScale):r.offsetY=e.wrapper.offsetY,this.diagramActions&&(r.width=e.wrapper.actualSize.width,r.height=e.wrapper.actualSize.height)}}i&&e.children&&e.children.length>0&&(void 0!==this.nameTable[e.id].width?this.scaleObject(e,this.nameTable[e.id].width,!0):this.nameTable[e.id].width=e.wrapper.actualSize.width,void 0!==this.nameTable[e.id].height?this.scaleObject(e,this.nameTable[e.id].height,!1):this.nameTable[e.id].height=e.wrapper.actualSize.height)},t.prototype.initNode=function(e,i,r){var a,p,s=e.initContainer(),o=new Ii;if(this.diagramSettings.inversedAlignment||(s.inversedAlignment=!1),s.children||(s.children=[]),e.children){s.measureChildren=!1,o.id=e.id+"group_container",o.style.fill=e.shape&&"SwimLane"===e.shape.type?e.style.fill:"none",o.style.strokeColor="none",o.horizontalAlignment="Stretch",o.verticalAlignment="Stretch",o.pivot=e.pivot,s.style=e.style,s.padding.left=e.padding.left,s.padding.right=e.padding.right,s.padding.top=e.padding.top,s.padding.bottom=e.padding.bottom,o.children=[],o.preventContainer=!0,e.container&&(o.relativeMode="Object");var l=!!(e.ports&&e.ports.length>0);if(m(e.container)&&!l&&s.children.push(o),e.container&&"Grid"===e.container.type)for(var h=0;h0&&e.wrapper.children[0]instanceof Qv){if(this.setZIndex(this.activeLayer,e),this.connectors.length>0)for(h=0;h0?i.phases.length:0,v="Horizontal"===i.orientation,y=v?i.phases.length||1:s.length+1,S=v?(i.header&&i.hasHeader?1:0)+(i.phases.length>0?1:0)+i.lanes.length:(i.header&&i.hasHeader?1:0)+i.phases.length;if(0===h&&!v&&i.lanes.length&&(S+=1),v?(a=(i.header&&i.hasHeader?1:0)+(h>0?1:0),l=0):(a=i.header&&i.hasHeader?1:0,l=h>0?1:0),s.length>0)for(o+=i.header&&i.hasHeader?i.header.height:0,p=0;pl?d.margin.left=d.margin.left-(u.bounds.left-e.bounds.left):u.children[0].children[1].actualSize.width+r>=d.margin.left&&(d.margin.left=u.children[0].children[1].actualSize.width+r),d.margin.lefta?d.margin.top=d.margin.top-(u.bounds.top-o):u.children[0].children[1].actualSize.height+r>=d.margin.top&&(d.margin.top=u.children[0].children[1].actualSize.height+r),d.margin.left0)for(o=0;o0&&this.updateChildPosition(e)},t.prototype.addBpmnAnnotationConnector=function(e,i){if(e.parentObj instanceof t||e.parentObj instanceof Bd){var r=e.shape,o=""!==r.textAnnotation.textAnnotationTarget&&this.nameTable[r.textAnnotation.textAnnotationTarget],a=o?this.nameTable[r.textAnnotation.textAnnotationTarget]:null,l=null!=a?a.wrapper:null,h=e.ports[0],c={x:0,y:0};switch(r.textAnnotation.textAnnotationDirection){case"Left":h.offset={x:0,y:.5},c.x=i.bounds.left-40,c.y=i.bounds.bottom+30;break;case"Right":h.offset={x:1,y:.5},c.x=i.bounds.right+40,c.y=i.bounds.bottom+30;break;case"Top":h.offset={x:.5,y:0},c.x=i.bounds.right+30,c.y=i.bounds.top-40;break;case"Bottom":h.offset={x:.5,y:1},c.x=i.bounds.right+30,c.y=i.bounds.bottom+40;break;default:h.offset={x:0,y:.5},c.x=i.bounds.left-40,c.y=i.bounds.bottom+30,o&&null!=i&&null!=l&&(i.bounds.left>l.bounds.right?h.offset={x:0,y:.5}:i.bounds.rightl.bounds.top?h.offset={x:.5,y:0}:i.bounds.top0&&this.updateChildPosition(r)}},t.prototype.canExecute=function(){return!0},t.prototype.updateStackProperty=function(e,i,r){e.container&&"Stack"===e.container.type&&(i.width||(i.wrapper.horizontalAlignment="Stretch",i.horizontalAlignment="Stretch"),i.height||(i.verticalAlignment="Stretch",i.wrapper.verticalAlignment="Stretch"),r&&"UmlClassifier"===e.shape.type&&(i.umlIndex=r))},t.prototype.initViews=function(){this.isLoading||(this.views.push(this.element.id),this.views[this.element.id]=this)},t.prototype.initCommands=function(){var e=this.commandManager.commands,i={copy:{execute:this.copyCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.C,keyModifiers:pt.Control}},paste:{execute:this.pasteCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.V,keyModifiers:pt.Control}},cut:{execute:this.cutCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.X,keyModifiers:pt.Control}},delete:{execute:this.removeCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Delete}},selectAll:{execute:this.selectAll.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.A,keyModifiers:pt.Control}},undo:{execute:this.undo.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Z,keyModifiers:pt.Control}},redo:{execute:this.redo.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Y,keyModifiers:pt.Control}},nudgeUp:{execute:this.nudgeCommand.bind(this,"Up"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Up},parameter:"up"},nudgeRight:{execute:this.nudgeCommand.bind(this,"Right"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Right},parameter:"right"},nudgeDown:{execute:this.nudgeCommand.bind(this,"Down"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Down},parameter:"down"},nudgeLeft:{execute:this.nudgeCommand.bind(this,"Left"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Left},parameter:"left"},startEdit:{execute:this.startEditCommad.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.F2}},endEdit:{execute:this.endEditCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Escape}},focusToNextItem:{execute:this.navigateItems.bind(this,!0),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Tab}},focusToPreviousItem:{execute:this.navigateItems.bind(this,!1),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Tab,keyModifiers:pt.Shift}},selectFocusedItem:{execute:this.startEditCommad.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Enter}},bold:{execute:this.fontStyleCommand.bind(this,"bold"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.B,keyModifiers:pt.Control}},italic:{execute:this.fontStyleCommand.bind(this,"italic"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.I,keyModifiers:pt.Control}},underline:{execute:this.fontStyleCommand.bind(this,"underline"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.U,keyModifiers:pt.Control}},duplicate:{execute:this.duplicateCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.D,keyModifiers:pt.Control}},group:{execute:this.groupCommand.bind(this,"group"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.G,keyModifiers:pt.Control}},ungroup:{execute:this.groupCommand.bind(this,"ungroup"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.U,keyModifiers:pt.Control|pt.Shift}},rotateClockwise:{execute:this.rotateCommand.bind(this,"clockwise"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.R,keyModifiers:pt.Control}},rotateAntiClockwise:{execute:this.rotateCommand.bind(this,"antiClockwise"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.L,keyModifiers:pt.Control}},flipHorizontal:{execute:this.flipCommand.bind(this,"horizontal"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.H,keyModifiers:pt.Control}},flipVertical:{execute:this.flipCommand.bind(this,"vertical"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.J,keyModifiers:pt.Control}},pointerTool:{execute:this.toolCommand.bind(this,"pointer"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number1,keyModifiers:pt.Control}},textTool:{execute:this.toolCommand.bind(this,"text"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number2,keyModifiers:pt.Control}},connectTool:{execute:this.toolCommand.bind(this,"connect"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number3,keyModifiers:pt.Control}},freeForm:{execute:this.toolCommand.bind(this,"freeForm"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number5,keyModifiers:pt.Control}},lineTool:{execute:this.toolCommand.bind(this,"line"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number6,keyModifiers:pt.Control}},rectangleTool:{execute:this.toolCommand.bind(this,"rectangle"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number8,keyModifiers:pt.Control}},ellipseTool:{execute:this.toolCommand.bind(this,"ellipse"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number9,keyModifiers:pt.Control}},zoomIn:{execute:this.zoomCommand.bind(this,"zoomIn"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Plus,keyModifiers:pt.Control}},zoomOut:{execute:this.zoomCommand.bind(this,"zoomOut"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Minus,keyModifiers:pt.Control}},shiftUp:{execute:this.shiftCommand.bind(this,"Up"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Up,keyModifiers:pt.Shift}},shiftDown:{execute:this.shiftCommand.bind(this,"Down"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Down,keyModifiers:pt.Shift}},shiftLeft:{execute:this.shiftCommand.bind(this,"Left"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Left,keyModifiers:pt.Shift}},shiftRight:{execute:this.shiftCommand.bind(this,"Right"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Right,keyModifiers:pt.Shift}},alignTextCenter:{execute:this.alignCommand.bind(this,"center"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.C,keyModifiers:pt.Control|pt.Shift}},alignTextLeft:{execute:this.alignCommand.bind(this,"right"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.L,keyModifiers:pt.Control|pt.Shift}},alignTextRight:{execute:this.alignCommand.bind(this,"left"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.R,keyModifiers:pt.Control|pt.Shift}},alignTextTop:{execute:this.alignCommand.bind(this,"top"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.E,keyModifiers:pt.Control|pt.Shift}},alignTextCenterVertical:{execute:this.alignCommand.bind(this,"centerVertical"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.M,keyModifiers:pt.Control|pt.Shift}},alignTextBottom:{execute:this.alignCommand.bind(this,"bottom"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.V,keyModifiers:pt.Control|pt.Shift}},alignJustify:{execute:this.alignCommand.bind(this,"justify"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.J,keyModifiers:pt.Control|pt.Shift}},sendToBack:{execute:this.orderCommand.bind(this,"sendToBack"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.B,keyModifiers:pt.Control|pt.Shift}},bringToFront:{execute:this.orderCommand.bind(this,"bringToFront"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.F,keyModifiers:pt.Control|pt.Shift}},sendBackward:{execute:this.orderCommand.bind(this,"sendBackward"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.BracketLeft,keyModifiers:pt.Control}},bringForward:{execute:this.orderCommand.bind(this,"bringForward"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.BracketRight,keyModifiers:pt.Control}}};this.initCommandManager(e,i)},t.prototype.overrideCommands=function(e,i){for(var r,s=0,o=Object.keys(i);se.zIndex){("HTML"===e.shape.type||"Native"===e.shape.type)&&(o="HTML"===e.shape.type?"html":"native"),s=Eoe(i,r[parseInt(a.toString(),10)].id,o);break}return s},t.prototype.updateDiagramObject=function(e,i,r){for(var s,o="domTable",a=0,l=this.views;a1&&(d=this.commandHandler.getObjectLayer(e.id)),void 0===d||d&&d.visible||r){var u=Io(this.element.id);window[""+o][s.element.id+"_diagramLayer"]||(window[""+o][s.element.id+"_diagramLayer"]=document.getElementById(s.element.id+"_diagramLayer"));var p=window[""+o][s.element.id+"_diagramLayer"];this.diagramActions&ee.Interactions&&this.updateCanupdateStyle(e.wrapper.children,!0);var f=this.getMidPoint(e);this.diagramRenderer.updateNode(e.wrapper,p,u,void 0,i?void 0:this.getZindexPosition(e,s.element.id),f,this.portCenterPoint),this.updateCanupdateStyle(e.wrapper.children,!0)}}},t.prototype.applyMarginBezier=function(e,i){i.cx=i.cx+e.margin.left,i.cx=i.cx-e.margin.right,i.cy=i.cy+e.margin.top,i.cy=i.cy-e.margin.bottom},t.prototype.getMidPoint=function(e){var i;if(e instanceof de&&"Bezier"===e.type){i=[];for(var r=this.getBezierPoints(e),s=z.getLengthFromListOfPoints(r),o=0;o0&&e.updateView(e));var s=Io(e.element.id);this.renderDiagramElements(e.diagramLayer,e.diagramRenderer,s,void 0,void 0,i);for(var o=0;o0&&this.renderBasicElement(e),!this.diagramActions||!(this.diagramActions&ee.Render)||ee.ToolAction&this.diagramActions||Ds(this)||1!==this.scroller.currentZoom?this.refreshElements(e):this.renderTimer||(this.renderTimer=setTimeout(function(){i.refreshElements(e)},40)))},t.prototype.updatePortVisibility=function(e,i,r){var s;if((e instanceof te||e instanceof de)&&(!this.drawingObject||!this.drawingObject.shape)&&to(e)){for(var a=e.ports,l=!1,h=0;h=0&&this.scroller.removeCollection.splice(l,1);var h=this.nameTable[e[parseInt(a.toString(),10)]];this.updateTextElementValue(h),this.diagramRenderer.renderElement(h.wrapper,s,o,void 0,void 0,void 0,void 0,h.zIndex)}for(var c=0;c0?this.scroller.oldCollectionObjects:void 0,b=Object.keys(S||g.zIndexTable);b.sort(function(N,T){return parseInt(""+N,10)-parseInt(""+T,10)});for(var M=0,w=b;M0?h:0)+"px",y=(this.realActions&$i.vScrollbarMoved?0:-(this.scroller.verticalOffset<0?this.scroller.verticalOffset:0))+"px"):(v="0px",y="0px"),this.realActions&$i.hScrollbarMoved&&(this.realActions=this.realActions&~$i.hScrollbarMoved),this.realActions&$i.vScrollbarMoved&&(this.realActions=this.realActions&~$i.vScrollbarMoved)):(v=(l.x<0?h:-this.scroller.horizontalOffset)+"px",y=(l.y<0?c:-this.scroller.verticalOffset)+"px"),this.diagramLayer.style.left=v,this.diagramLayer.style.top=y,A.tx=-l.x/A.scale,A.ty=-l.y/A.scale);var R=!0;if(o&&(R=!1),this.updateTextElementValue(D),this.refreshing&&D.shape.activity&&D.shape.activity.subProcess&&D.shape.activity.subProcess.processes){for(var L=0;L0){var o=s.children[0],a=o.data;(r.isBezierEditing&&this.selectedItems.connectors[0].id===r.id||"Bezier"!==r.type)&&r.getSegmentElement(r,o,"ComplexHierarchicalTree"===this.layout.type||"HierarchicalTree"===this.layout.type?this.layout.orientation:void 0,void 0,!1),o.data!==a&&(s.measure(new me),s.arrange(s.desiredSize),"SVG"===this.mode&&!e&&this.updateDiagramObject(r))}}else this.constraints&rt.Bridging&&console.warn('[WARNING] :: Module "ConnectorBridging" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.setCursor=function(e){this.diagramRenderer.setCursor(this.diagramCanvas,e)},t.prototype.clearCanvas=function(e){var i=e.contentWidth||e.diagramLayer.width/this.scroller.currentZoom,r=e.contentHeight||e.diagramLayer.height/this.scroller.currentZoom;"SVG"!==e.mode&&bo.getContext(e.diagramLayer).clearRect(0,0,i,r)},t.prototype.updateScrollOffset=function(){this.scroller.setScrollOffset(this.diagramCanvas.scrollLeft,this.diagramCanvas.scrollTop),KI(this),Ds(this)&&this.scroller.virtualizeElements()},t.prototype.setOffset=function(e,i){var r="domTable";window[""+r][this.element.id+"content"]||(window[""+r][this.element.id+"content"]=document.getElementById(this.element.id+"content"));var s=window[""+r][this.element.id+"content"];s&&(s.scrollLeft=e,s.scrollTop=i)},t.prototype.setSize=function(e,i){if(this.diagramLayer&&!this.preventDiagramUpdate){var r=qa(this);e-=r.width,i-=r.height;var s=this.spatialSearch.getPageBounds();s.x*=this.scroller.currentZoom,s.y*=this.scroller.currentZoom,s.width*=this.scroller.currentZoom,s.height*=this.scroller.currentZoom;var o="SVG"===this.mode?1:1.5,a="SVG"===this.mode?mT(this.element.id):this.diagramLayer,h="Canvas"===this.mode&&this.constraints&rt.Virtualization?this.scroller.viewPortHeight:i;a.setAttribute("width",(o*("Canvas"===this.mode&&this.constraints&rt.Virtualization?this.scroller.viewPortWidth:e)).toString()),a.setAttribute("height",(o*h).toString());var c=document.getElementById(this.element.id+"_diagramUserHandleLayer");c&&(c.style.width=e+"px",c.style.height=i+"px");var d={width:e.toString(),height:i.toString()};this.diagramLayerDiv.style.width=e+"px",this.diagramLayerDiv.style.height=i+"px",oi(FF(this.element.id),d),oi(function xoe(n){return xt(n).getElementsByClassName("e-ports-expand-layer")[0]}(this.element.id),d);var u=zl(this.element.id);oi(u,d),u.parentNode.style.width=e+"px",u.parentNode.style.height=i+"px";var p=_d(this.element.id);oi(p,d),this.diagramRenderer.updateGrid(this.snapSettings,p,this.scroller.transform,this.rulerSettings,this.hRuler,this.vRuler),oi(IT(this.element.id),d),this.htmlLayer.style.width=e+"px",this.htmlLayer.style.height=i+"px","SVG"!==this.mode&&!Ds(this)&&this.refreshDiagramLayer(),"SVG"===this.mode&&Ds(this)&&this.scroller.virtualizeElements()}},t.prototype.transformLayers=function(){var e=this.spatialSearch.getPageBounds();e.x*=this.scroller.currentZoom,e.y*=this.scroller.currentZoom,e.width*=this.scroller.currentZoom,e.height*=this.scroller.currentZoom,this.diagramRenderer.updateGrid(this.snapSettings,_d(this.element.id),this.scroller.transform,this.rulerSettings,this.hRuler,this.vRuler),this.diagramRenderer.transformLayers(this.scroller.transform,"SVG"===this.mode),this.diagramActions&ee.DragUsingMouse||this.updateSelector(),this.renderPageBreaks(e)},t.prototype.removePageBreaks=function(){if(this.diagramLayer){var e=_F(this.element.id);if(e&&e.childNodes)for(var i=e.childNodes.length,r=0;rthis.pageSettings.height&&(e=this.pageSettings.height,this.pageSettings.height=this.pageSettings.width,this.pageSettings.width=e):this.pageSettings.height>this.pageSettings.width&&(e=this.pageSettings.width,this.pageSettings.width=this.pageSettings.height,this.pageSettings.height=e)},t.prototype.setOverview=function(e,i){if(e)e&&(this.views.push(e.id),this.views[e.id]=e,e.renderDocument(e),e.diagramRenderer.setLayers(),e.updateView(e),this.renderNodes(e));else{for(var r=0;r1&&this.updateSelectionRectangle(),this.isProtectedOnChange=s},t.prototype.updateSelectionRectangle=function(){for(var e=um(this.element.id),i=!1,r=0;r1&&this.updateSelectionRectangle(),this.enableServerDataBinding(e)},t.prototype.renderSelectorForAnnotation=function(e,i){this.diagramRenderer.renderResizeHandle(e.wrapper.children[0],i,e.thumbsConstraints,this.scroller.currentZoom,e.constraints,this.scroller.transform,void 0,to(e.annotation),void 0,void 0,e.handleSize)},t.prototype.drawSelectionRectangle=function(e,i,r,s){this.clearSelectorLayer(),this.diagramRenderer.drawSelectionRectangle(e,i,r,s,this.adornerLayer,this.scroller.transform)},t.prototype.renderHighlighter=function(e){var i=zl(this.element.id);this.diagramRenderer.renderHighlighter(e,i,this.scroller.transform)},t.prototype.clearHighlighter=function(){var e=zl(this.element.id),i=e.getElementById(e.id+"_highlighter");i&&i.parentNode.removeChild(i)},t.prototype.getNodesConnectors=function(e){for(var i=0;i0;l--)(a=o[l-1]).parentNode.removeChild(a);if(!ce()){var h=ST(this.element.id).childNodes;for(r=h.length;r>0;r--)h[r-1].parentNode.removeChild(h[r-1])}}},t.prototype.getWrapper=function(e,i){var r;i=e.id+"_"+i;for(var s=e instanceof Ii?e:this.getPortContainer(this.nameTable[e.id]),o=0;o0&&this.applyStyle(e,a=r.annotations)}for(i=0;i0){var a=this.selectedItems.connectors[parseInt(i.toString(),10)].annotations;this.applyStyle(e,a)}},t.prototype.applyStyle=function(e,i){for(var r=0;r0)for(var i=0;i0?r[0].zIndex+(e?1:-1):e?0:this.nodes.length+this.connectors.length-1)<0?i=this.nodes.length+this.connectors.length-1:i===this.nodes.length+this.connectors.length&&(i=0);for(var s=0;s0)for(var s=void 0,o=r.children.length-1;o>=0;o--){var a=r.children[parseInt(o.toString(),10)];i.length>0&&-1!==i.indexOf(a.id.split("_groupElement")[0])&&(r.parentNode.insertBefore(a,s||r),s=a)}r&&r.parentNode.removeChild(r)},t.prototype.deleteGroup=function(e){var r=[];e.children&&(r=this.commandHandler.getChildren(e,[])),this.UpdateBlazorDiagramModelCollection(e);for(var s=0,o=r;s0)for(var xe=0;xe0)if("Path"===t.shape.type&&void 0!==n.shape.data)t.wrapper.children[0].data=n.shape.data;else if("Text"===t.shape.type&&void 0!==n.shape.content)t.wrapper.children[0].content=n.shape.content;else if("Image"===t.shape.type&&void 0!==n.shape.source)t.wrapper.children[0].source=n.shape.source;else if("Native"===t.shape.type){for(var r=void 0,s=0;s-1)&&(this.diagramActions&ee.PreventZIndexOnDragging?this.updateDiagramObject(e,!0):this.updateDiagramObject(e)),!s&&d&&(this.lineRoutingModule&&this.diagramActions&&this.constraints&rt.LineRouting&&"helper"!==e.id?this.diagramActions&ee.ToolAction||this.lineRoutingModule.renderVirtualRegion(this,!0):this.diagramActions&&this.constraints&rt.LineRouting&&"helper"!==e.id&&console.warn('[WARNING] :: Module "LineRouting" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),this.updateConnectorEdges(e),"helper"!==e.id&&!(this.diagramActions&ee.ToolAction))))for(var ya=this.spatialSearch.findObjects(e.wrapper.outerBounds),Mo=0;Moe?Math.abs(r-e):Math.abs(e-r),d=s>i?Math.abs(s-i):Math.abs(i-s);(0===c&&0===d||Number.isNaN(c)&&Number.isNaN(d))&&o.laneMargin&&(u=o.margin.left-o.laneMargin.left,p=o.margin.top-o.laneMargin.top);var f=o.width,g=o.height,v=new Ne(0,0,0,0);if(0!==f&&0!==g&&(v=new Ne((0!==r?r:o.offsetX)-f/2,(0!==s?s:o.offsetY)-g/2,f,g)),h){var y=l,b=this.selectedItems.nodes?this.selectedItems.nodes[0]:void 0;if(""!==y.textAnnotation.textAnnotationTarget&&this.nameTable[y.textAnnotation.textAnnotationTarget])if(""===o.parentId||b&&b.shape&&"TextAnnotation"===b.shape.shape){if("Auto"===y.textAnnotation.textAnnotationDirection&&a.children[0]instanceof Ii&&a.children[0].children[0]instanceof Ke){var w=a.children[0],C=document.getElementById(w.id+"_groupElement"),D=document.getElementById(w.children[0].id+"_groupElement");C.removeChild(D),w.children.splice(0,1),this.isProtectedOnChange=!0,this.bpmnModule.setAnnotationPath(v,w,o,y,y.textAnnotation.textAnnotationDirection,this),this.isProtectedOnChange=!1}}else this.isPositionUndo=!0,this.updateTextAnnotationInSwimlane(o,o),this.isPositionUndo=!1;else o.inEdges.length>0&&(x=this.nameTable[""+o.inEdges[0]])&&x.isBpmnAnnotationConnector&&(x.sourcePoint={x:r>e?x.sourcePoint.x+c:x.sourcePoint.x-c,y:s>i?x.sourcePoint.y+d:x.sourcePoint.y-d});this.nodePropertyChange(o,{},R={ports:[{offset:o.ports[0].offset}]})}else for(var L=0,O=o.outEdges;Le?T.offsetX+c:T.offsetX-c,T.offsetY=s>i?T.offsetY+d:T.offsetY-d,R={offsetX:T.offsetX,offsetY:T.offsetY}),this.nodePropertyChange(T,P,R)}}}},t.prototype.updatePorts=function(e,i){if(e&&e.ports.length>0)for(var r=0,s=Object.keys(e.ports);r0)for(var i=0;i0)for(var r=0;r0&&void 0===r.segments&&(e.segments=[]),void 0!==r.shape&&void 0!==e.shape&&e.shape&&"Bpmn"===e.shape.type&&this.bpmnModule&&this.bpmnModule.updateBPMNConnector(e,i,r,this),void 0!==e.constraints?(this.updateThumbConstraints(this.selectedItems.connectors,this.selectedItems),s=!0):s},t.prototype.connectorPropertyChange=function(e,i,r,s,o){if(this.canEnableBlazorObject){var a=$(e);this.insertValue(a,!1)}var d,u,p,f,l=e.wrapper.bounds,h=!1,c=[];if(h=this.connectorProprtyChangeExtend(e,i,r,h),void 0!==r.visible&&this.updateElementVisibility(e.wrapper,e,e.visible),void 0!==r.sourcePoint||void 0!==r.targetPoint||void 0!==r.sourceID||void 0!==r.targetID||void 0!==r.targetPadding||void 0!==r.sourcePortID||void 0!==r.targetPortID||void 0!==r.sourcePadding||void 0!==r.type||void 0!==r.segments||void 0!==r.flip){if(void 0!==r.sourceID&&r.sourceID!==i.sourceID||r.sourcePortID){if(u=this.findInOutConnectPorts(g=this.nameTable[e.sourceID],!1),(!g||kh(g)||""!==e.sourcePortID&&Ad(u))&&(e.sourceWrapper=g?this.getEndNodeWrapper(g,e,!0):void 0,e.sourcePortID&&void 0===r.sourcePortID&&(e.sourcePortWrapper=g?this.getWrapper(g.wrapper,e.sourcePortID):void 0),this.removePortEdges(this.nameTable[i.sourceID]||g,i.sourcePortID||e.sourcePortID,e.id,!1)),void 0!==r.sourceID&&void 0!==i.sourceID&&""!==i.sourceID){var v=this.nameTable[i.sourceID];void 0!==v&&v.outEdges&&-1!==v.outEdges.indexOf(e.id)&&rm(v.outEdges,e.id)}this.updateEdges(e)}if(void 0!==r.targetID&&r.targetID!==i.targetID){if(d=this.findInOutConnectPorts(y=this.nameTable[r.targetID],!0),(!y||da(y)||""!==e.targetPortID&&Oh(d))&&(e.targetWrapper=y?this.getEndNodeWrapper(y,e,!1):void 0,e.targetPortID&&void 0===r.targetPortID&&(e.targetPortWrapper=y?this.getWrapper(y.wrapper,e.targetPortID):void 0),this.removePortEdges(this.nameTable[i.targetID]||y,i.targetPortID||e.targetPortID,e.id,!0)),void 0!==i&&void 0!==i.targetID&&""!==i.targetID){var S=this.nameTable[i.targetID];void 0!==S&&S.inEdges&&-1!==S.inEdges.indexOf(e.id)&&rm(S.inEdges,e.id)}this.updateEdges(e)}var g,y;void 0!==r.sourcePortID&&r.sourcePortID!==i.sourcePortID&&(e.sourceID&&this.nameTable[e.sourceID]&&(p=this.nameTable[e.sourceID].wrapper),!(g=this.nameTable[e.sourceID])||kh(g)||""!==e.sourcePortID&&Ad(u)?e.sourcePortWrapper=p?this.getWrapper(p,r.sourcePortID):void 0:""===e.sourcePortID&&!kh(g)&&(e.sourcePortWrapper=void 0)),void 0!==r.targetPortID&&r.targetPortID!==i.targetPortID&&(e.targetID&&this.nameTable[e.targetID]&&(f=this.nameTable[e.targetID].wrapper),!(y=this.nameTable[e.targetID])||da(y)||""!==e.targetPortID&&Oh(d)?e.targetPortWrapper=f?this.getWrapper(f,r.targetPortID):void 0:""===e.targetPortID&&!da(y)&&(e.targetPortWrapper=void 0)),void 0!==r.flip&&(e.flip=r.flip,EF(e)),"Orthogonal"===e.type&&this.lineRoutingModule&&this.diagramActions&&this.constraints&rt.LineRouting&&!(this.diagramActions&ee.ToolAction)&&"ComplexHierarchicalTree"!==this.layout.type&&(this.lineRoutingModule.renderVirtualRegion(this,!0),e.sourceID!==e.targetID&&e.segments.length>1&&this.lineRoutingModule.refreshConnectorSegments(this,e,!1)),c=this.getPoints(e)}void 0!==r.style&&Rh(r.style,e.wrapper.children[0]),(c.length>0||void 0!==r.sourceDecorator||void 0!==r.targetDecorator&&function qse(n){return-1!==n.indexOf("shape")||-1!==n.indexOf("pathData")||-1!==n.indexOf("width")||-1!==n.indexOf("height")}(Object.keys(r.targetDecorator))||void 0!==r.cornerRadius)&&(ef(e,c.length>0?c:e.intermediatePoints,this.diagramActions),void 0!==r.type&&(h=!0),c.length>0&&(e.wrapper.measure(new me(e.wrapper.width,e.wrapper.height)),e.wrapper.arrange(e.wrapper.desiredSize),this.updateConnectorAnnotation(e),this.updateConnectorPort(e),this.updateConnectorfixedUserHandles(e),this.updateObject(e,i,r))),(r.sourcePoint||r.targetPoint||r.segments)&&this.diagramActions===ee.Render&&(h=!0),"Bpmn"===e.shape.type&&"Default"===e.shape.sequence&&"Sequence"===e.shape.flow&&this.commandHandler.updatePathElementOffset(e),s||this.updateBridging(),this.updateAnnotations(r,e),this.updateConnectorPorts(r,e),this.updatefixedUserHandle(r,e),e.wrapper.measure(new me(e.wrapper.width,e.wrapper.height)),e.wrapper.arrange(e.wrapper.desiredSize),!1===l.equals(l,e.wrapper.bounds)&&(this.updateQuad(e),"Drag"!==this.eventHandler.currentAction&&this.updateGroupSize(e)),!0===h&&this.checkSelectedItem(e)&&(!(this.diagramActions&ee.ToolAction)||this.diagramActions&ee.UndoRedo)&&this.updateSelector(),this.preventConnectorsUpdate||(!Ds(this)||Ds(this)&&this.scroller.oldCollectionObjects.indexOf(e.id)>-1)&&(this.diagramActions&ee.PreventZIndexOnDragging?this.updateDiagramObject(e,!0):this.updateDiagramObject(e)),this.updateConnectorEdges(e),this.diagramActions&&"New"!==e.status&&(e.status="Update"),this.triggerPropertyChange(o,e,i,r)},t.prototype.removePortEdges=function(e,i,r,s){if(e)for(var o=0;o0&&e.id===s[s.length-1].id&&(r=!0),r},t.prototype.updateDiagramContainerVisibility=function(e,i){if(e instanceof Cs)for(var r=0;r>"),r instanceof Jn&&this.updateAnnotationWrapper(r,s,o,a)),void 0!==e.template&&(r.content=e.template,this.updateAnnotationWrapper(r,s,o,a))},t.prototype.updateAnnotationWrapper=function(e,i,r,s){for(var o=0,a=this.views;o=0&&this.nodes.splice(s,1),delete this.nameTable[""+r]}var o=this.nodes.indexOf(this.nameTable[this.currentSymbol.id]);o>=0&&this.nodes.splice(o,1)}},t.prototype.selectDragedNode=function(e,i,r){this.currentSymbol=e,"SVG"!==this.mode&&this.refreshDiagramLayer(),this.commandHandler.oldSelectedObjects=sm(this),this.commandHandler.select(e),this.eventHandler.mouseDown(i.event),this.eventHandler.mouseMove(i.event,i),this.preventDiagramUpdate=!1,this.updatePage(),r.style.opacity="0"},t.prototype.initDroppables=function(){var s,o,e=this,i={},r={},a="selectedSymbols";this.droppable=new lR(this.element);var l=5;this.droppable.over=function(h){if(e.rulerSettings.showRulers){var c=document.getElementById(e.element.id+"_vRuler"),d=parseFloat(c.style.width);l=d+1}if(0===e.previousSelectedObjects.length&&!e.currentSymbol&&(e.previousSelectedObjects=e.commandHandler.getSelectedObject()),e.commandHandler.PreventConnectorSplit=!0,e.currentSymbol)h.event.touches&&h.event.touches.length&&e.eventHandler.mouseMove(h.event,h.event.touches);else{var u=null;if(!h.dragData&&"drag"===h.name){var p=document.getElementsByClassName("e-dragclone")[0];p&&(u=p)}if(h.dragData||u){var f=void 0,g=void 0;document.getElementById(e.element.id+"content").focus();var v=e.eventHandler.getMousePosition(h.event),y=void 0,S=u||h.dragData.helper,b=S.getAttribute("paletteId"),M=void 0,w=void 0,C=void 0,D=void 0;if(!b&&h.dragData){e.triggerEvent(Ce.dragEnter,A={source:null,element:f,cancel:!1,diagram:e,dragData:h.dragData.draggedElement.ej2_instances[0].dragData,dragItem:f});var x=void 0,R=void 0;if(A.dragItem){if(A.dragItem.sourcePoint&&A.dragItem.targetPoint?R=new de(e,"connectors",A.dragItem,!0):x=new te(e,"nodes",A.dragItem,!0),e.initObject(f=x||R,void 0,void 0,!0),e.enterObject=f,e.enterTable=r,f instanceof te)x.offsetX=v.x+5+x.width*x.pivot.x,x.offsetY=v.y+x.height*x.pivot.y;else if(f instanceof de){var L=Ne.toBounds([f.sourcePoint,f.targetPoint]),O=v.x-L.left,N=v.y-L.top;f.sourcePoint.x+=O,f.sourcePoint.y+=N,f.targetPoint.x+=O,f.targetPoint.y+=N}e.preventDiagramUpdate=!0,e.currentSymbol=f,"SVG"!==e.mode&&e.refreshDiagramLayer(),e.selectDragedNode(f,h,S),delete e.enterObject,delete e.enterTable,e.droppable[""+a]=S,e.allowServerDataBinding=!0}}if(b){var T=document.getElementById(b).ej2_instances[0];if(e.droppable.sourceElement=T,T){var B=T[""+a];e.allowServerDataBinding=!1,y=$(T[""+a]),i=T.childTable;var j=B.wrapper.children[0].children[0];if(D=function $se(n,t,e){var i=AF(n,t,e,"width"),r=AF(n,t,e,"height");return new me(i,r)}(T,y,j),T[""+a]instanceof te){"TextAnnotation"===B.shape.shape?(y.offsetX=v.x+11+D.width*y.pivot.x,y.offsetY=v.y+11+D.height*y.pivot.y):(y.offsetX=v.x+5+D.width*y.pivot.x,y.offsetY=v.y+D.height*y.pivot.y),"Bpmn"===(x=new te(e,"nodes",y,!0)).shape.type&&x.shape.activity.subProcess.processes&&x.shape.activity.subProcess.processes.length&&(x.shape.activity.subProcess.processes=[]),w=x.previewSize,C=T.symbolDragSize;var Q=T.symbolPreview;if(x.width=(M=x.dragSize).width||C.width||w.width||Q.width||x.width,x.height=M.height||C.height||w.height||Q.height||x.height,"SwimLane"===x.shape.type){if(e.diagramActions|=ee.PreventHistory,x.shape.isLane){x.children=[],s={id:"header"+Qe()},"Horizontal"===x.shape.orientation?(s.width=x.shape.lanes[0].header.width,s.height=x.shape.lanes[0].height):(s.width=x.shape.lanes[0].width,s.height=x.shape.lanes[0].header.height),s.style=x.shape.lanes[0].header.style,s.offsetX=v.x+l+s.width/2,s.offsetY=v.y+s.height/2,e.diagramActions|=ee.PreventCollectionChangeOnDragOver,s=e.add(s),o={id:"body"+Qe()},"Horizontal"===x.shape.orientation?(o.width=x.shape.lanes[0].width-s.width,o.height=x.shape.lanes[0].height,o.offsetX=v.x+l+(x.shape.lanes[0].header.width+o.width/2),o.offsetY=v.y+o.height/2):(o.width=x.shape.lanes[0].width,o.height=x.shape.lanes[0].height-s.height,o.offsetX=v.x+l+o.width/2,o.offsetY=v.y+(x.shape.lanes[0].header.height+o.height/2)),o.style=x.shape.lanes[0].style,o=e.add(o);var oe={id:"group"+Qe(),children:[s.id,o.id]};oe.shape=x.shape,oe.width=x.shape.lanes[0].width,oe.height=x.shape.lanes[0].height,oe.previewSize=x.previewSize,oe.dragSize=x.dragSize,oe.addInfo=x.addInfo,x=e.add(oe),e.diagramActions&=~ee.PreventCollectionChangeOnDragOver}e.diagramActions&=~ee.PreventHistory}if(x.shape.isPhase&&((g="Horizontal"===x.shape.orientation)?(x.offsetX=v.x+l+(x.width||j.actualSize.width)/2,x.offsetY=v.y,x.shape.data="M20,"+x.height/2+" L"+(x.width-20)+","+x.height/2+"z",x.height=1):(x.offsetX=v.x+5,x.offsetY=v.y+(x.height||j.actualSize.height)/2,x.shape.data="M"+x.width/2+",20 L"+x.width/2+","+(x.height-20)+"z",x.width=1)),"UmlClassifier"===x.shape.type&&(x.children=x.width=x.height=void 0,y.children=void 0,"Class"===x.shape.classifier&&x.shape.classShape.methods.length<=0&&x.shape.classShape.attributes.length<=0&&(x.shape.classShape.attributes=[{name:"Name",type:"Type",style:{}}]),"Enumeration"===x.shape.classifier&&x.shape.enumerationShape.members.length<=0&&(x.shape.enumerationShape.members=[{name:"Name"}]),"Interface"===x.shape.classifier&&x.shape.interfaceShape.methods.length<=0&&x.shape.interfaceShape.attributes.length<=0&&(x.shape.interfaceShape.attributes=[{name:"Name",type:"Type",style:{}}])),f=x,y.children){var ue=y;r=e.getChildren(ue,{},i),rT(ue,-ue.offsetX,-ue.offsetY,r,!0,e)}}else if(T[""+a]instanceof de){f=new de(e,"connectors",y,!0);var Me=Ne.toBounds([f.sourcePoint,f.targetPoint]),De=v.x-Me.left,xe=v.y-Me.top;f.sourcePoint.x+=De,f.sourcePoint.y+=xe,f.targetPoint.x+=De,f.targetPoint.y+=xe}f.shape.isLane||(f.id+=Qe());var A={source:T,element:f,cancel:!1,diagram:e,dragData:null,dragItem:f};if(e.enterObject=f,e.enterTable=r,e.triggerEvent(Ce.dragEnter,A),f instanceof te&&"SwimLane"===f.shape.type&&f.shape.isLane){var Ie=A.element,Ve=Ie.shape.lanes[0];g="Horizontal"===Ie.shape.orientation;var ot=e.nameTable[f.children[0]],$e=e.nameTable[f.children[1]];w=f.previewSize,C=T.symbolDragSize,Ve.width=(M=f.dragSize).width||C.width||w.width||Ve.width,Ve.height=M.height||C.height||w.height||Ve.height,g?(s.width=Ve.header.width,s.height=Ve.height,o.width=Ve.width-s.width,o.height=Ve.height,o.offsetX=v.x+l+(Ve.header.width+$e.width/2),o.offsetY=v.y+$e.height/2):(s.width=Ve.width,s.height=Ve.header.height,o.width=Ve.width,o.height=Ve.height-s.height,o.offsetX=v.x+l+$e.width/2,o.offsetY=v.y+(Ve.header.height+$e.height/2)),s.offsetX=v.x+l+ot.width/2,s.offsetY=v.y+ot.height/2,f.width=Ve.width,f.height=Ve.height}if(f instanceof te&&f.shape.isPhase&&(g?f.height=1:f.width=1),!e.activeLayer.lock&&!A.cancel){if(e.preventDiagramUpdate=!0,f.children&&e.findChild(f,r),e.preventDiagramUpdate=!0,f.zIndex!==Number.MIN_VALUE&&(f.zIndex=Number.MIN_VALUE),e.initObject(f,void 0,void 0,!0),e.bpmnModule)for(var Mi=0;Mi0&&(S.segments=[]),d=this.add(S,!0)),(S||d)&&(jv(this)||Vv(this))&&this.select([this.nameTable[S[""+b]]],!1,this.previousSelectedObjects),y.target&&y.target instanceof de&&!0===this.enableConnectorSplit&&this.nameTable[S[""+b]]instanceof te&&(this.commandHandler.connectorSplit(this.nameTable[S[""+b]],y.target),this.commandHandler.PreventConnectorSplit=!1))),this.protectPropertyChange(!1),v=this.nameTable[S[""+b]],S.hasTarget&&(S.nodeId=S.hasTarget,this.remove(S)),this.bpmnModule&&v instanceof te&&S.processId&&(v.processId=S.processId,this.bpmnModule.dropBPMNchild(this.nameTable[v.processId],v,this)),y.cancel||this.endGroupAction(),"SVG"!==this.mode&&this.refreshDiagramLayer(),delete this.droppable[""+c]):(this.triggerEvent(Ce.drop,y={source:h.droppedElement,element:void 0,target:this.eventHandler.hoverNode||this.eventHandler.lastObjectUnderMouse||this,cancel:!1,position:void 0}),S=void 0,b="id"),this.droppable[M="selectedSymbols"]&&this.droppable[""+M].parentNode)gt(this.droppable[""+M]);else for(w=document.getElementsByClassName("e-dragclone"),C=0;C0)for(var p=0;p1),e.previousSelectedObject=null}}},t.prototype.getDropEventArgs=function(e){if(this.eventHandler.lastObjectUnderMouse||this.eventHandler.hoverNode){var i=this.eventHandler.lastObjectUnderMouse||this.eventHandler.hoverNode;e.target=fs(i)===de?{connector:i}:{node:i}}else e.target.diagramId=this.element.id},t.prototype.removeChildInNodes=function(e){if(e){if(e.children)for(var i=0;i1){var l=2;if(e.children&&e.children.length>0)for(;e.children.indexOf(i.objects[s-l])>-1;)l++;this.commandHandler.moveSvgNode(e.id,i.objects[s-l]),this.commandHandler.moveSvgNode(i.objects[s-l],e.id)}else if(o){var h=this.commandHandler.getLayer(this.layerZIndexTable[o.zIndex]).objects[0];h?(this.commandHandler.moveSvgNode(e.id,h),this.commandHandler.updateNativeNodeIndex(e.id,h)):this.moveObjectsUp(e,i)}else this.moveObjectsUp(e,i)},t.prototype.moveObjectsUp=function(e,i){for(var r,s=this.layers.length-1;s>=0;s--)if(r=this.layers[parseInt(s.toString(),10)],i.id!==r.id){var o=this.commandHandler.getLayer(this.layerZIndexTable[r.zIndex]).objects[r.objects.length-1];if(o){this.commandHandler.moveSvgNode(e.id,o),this.commandHandler.moveSvgNode(o,e.id);break}}},t.prototype.insertData=function(e){return this.crudOperation(e,"create",this.getNewUpdateNodes("New"))},t.prototype.updateData=function(e){return this.crudOperation(e,"update",this.getNewUpdateNodes("Update"))},t.prototype.removeData=function(e){return this.crudOperation(e,"destroy",this.getDeletedNodes())},t.prototype.crudOperation=function(e,i,r){if(e){var s=this.parameterMap(e,!(e instanceof de));if(s){var o=e instanceof de?this.dataSourceSettings.connectionDataSource.crudAction[""+i]:this.dataSourceSettings.crudAction[""+i];this.raiseAjaxPost(JSON.stringify(s),o)}return s}var a=r;return this.processCrudCollection(a,this.dataSourceSettings.crudAction[""+i],this.dataSourceSettings.connectionDataSource.crudAction[""+i]),a},t.prototype.processCrudCollection=function(e,i,r){if(e.nodes){var s=[],o=void 0;for(o=0;o0&&this.raiseAjaxPost(JSON.stringify(s),i)}if(e.connectors){for(s=[],o=void 0,o=0;o0&&this.raiseAjaxPost(JSON.stringify(s),r)}},t.prototype.parameterMap=function(e,i){var s,r={},o=i?this.dataSourceSettings:this.dataSourceSettings.connectionDataSource;if(o.id&&(r[o.id]=e.id),o.sourcePointX&&o.sourcePointY&&(r[o.sourcePointX]=e.sourcePoint.x,r[o.sourcePointY]=e.sourcePoint.y),o.targetPointX&&o.targetPointY&&(r[o.targetPointX]=e.targetPoint.x,r[o.targetPointY]=e.targetPoint.y),o.sourceID&&(r[o.sourceID]=e.sourceID),o.targetID&&(r[o.targetID]=e.targetID),o.crudAction&&o.crudAction.customFields&&o.crudAction.customFields.length>0)for(s=0;s{class n extends ch{constructor(e){super(),this.viewContainerRef=e,gl("currentInstance",this,this.viewContainerRef),this.registerEvents($ae),this.directivePropList=qae}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-layer"]],inputs:{addInfo:"addInfo",id:"id",lock:"lock",objects:"objects",visible:"visible",zIndex:"zIndex"},features:[yn]}),n})(),Jae=(()=>{class n extends dh{constructor(){super("layers")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-layers"]],contentQueries:function(e,i,r){if(1&e&&dn(r,Zae,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),Kae=["action","cursor"],ele=[],tle=(()=>{class n extends ch{constructor(e){super(),this.viewContainerRef=e,gl("currentInstance",this,this.viewContainerRef),this.registerEvents(ele),this.directivePropList=Kae}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-cursormap"]],inputs:{action:"action",cursor:"cursor"},features:[yn]}),n})(),ile=(()=>{class n extends dh{constructor(){super("customcursor")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-cursormaps"]],contentQueries:function(e,i,r){if(1&e&&dn(r,tle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),rle=["alignment","cornerRadius","displacement","fill","handleStrokeColor","handleStrokeWidth","height","iconStrokeColor","iconStrokeWidth","id","offset","padding","pathData","tooltip","visibility","width"],nle=[],sle=(()=>{class n extends ch{constructor(e){super(),this.viewContainerRef=e,gl("currentInstance",this,this.viewContainerRef),this.registerEvents(nle),this.directivePropList=rle}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-connector-fixeduserhandle"]],inputs:{alignment:"alignment",cornerRadius:"cornerRadius",displacement:"displacement",fill:"fill",handleStrokeColor:"handleStrokeColor",handleStrokeWidth:"handleStrokeWidth",height:"height",iconStrokeColor:"iconStrokeColor",iconStrokeWidth:"iconStrokeWidth",id:"id",offset:"offset",padding:"padding",pathData:"pathData",tooltip:"tooltip",visibility:"visibility",width:"width"},features:[yn]}),n})(),ole=(()=>{class n extends dh{constructor(){super("fixeduserhandles")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-connector-fixeduserhandles"]],contentQueries:function(e,i,r){if(1&e&&dn(r,sle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),ale=["addInfo","alignment","annotationType","constraints","content","displacement","dragLimit","height","horizontalAlignment","hyperlink","id","margin","offset","rotateAngle","rotationReference","segmentAngle","style","template","tooltip","type","verticalAlignment","visibility","width"],lle=[],hle=(()=>{class n extends ch{constructor(e){super(),this.viewContainerRef=e,gl("currentInstance",this,this.viewContainerRef),this.registerEvents(lle),this.directivePropList=ale}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-connector-annotation"]],inputs:{addInfo:"addInfo",alignment:"alignment",annotationType:"annotationType",constraints:"constraints",content:"content",displacement:"displacement",dragLimit:"dragLimit",height:"height",horizontalAlignment:"horizontalAlignment",hyperlink:"hyperlink",id:"id",margin:"margin",offset:"offset",rotateAngle:"rotateAngle",rotationReference:"rotationReference",segmentAngle:"segmentAngle",style:"style",template:"template",tooltip:"tooltip",type:"type",verticalAlignment:"verticalAlignment",visibility:"visibility",width:"width"},features:[yn]}),n})(),cle=(()=>{class n extends dh{constructor(){super("annotations")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-connector-annotations"]],contentQueries:function(e,i,r){if(1&e&&dn(r,hle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),dle=["addInfo","allowNodeOverlap","annotations","bezierSettings","bridgeSpace","connectionPadding","connectorSpacing","constraints","cornerRadius","dragSize","excludeFromLayout","fixedUserHandles","flip","flipMode","hitPadding","id","margin","maxSegmentThumb","ports","previewSize","segmentThumbShape","segmentThumbSize","segments","shape","sourceDecorator","sourceID","sourcePadding","sourcePoint","sourcePortID","style","symbolInfo","targetDecorator","targetID","targetPadding","targetPoint","targetPortID","tooltip","type","visible","wrapper","zIndex"],ule=[],ple=(()=>{class n extends ch{constructor(e){super(),this.viewContainerRef=e,this.tags=["fixedUserHandles","annotations"],gl("currentInstance",this,this.viewContainerRef),this.registerEvents(ule),this.directivePropList=dle}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-connector"]],contentQueries:function(e,i,r){if(1&e&&(dn(r,ole,5),dn(r,cle,5)),2&e){let s;Kr(s=en())&&(i.childFixedUserHandles=s.first),Kr(s=en())&&(i.childAnnotations=s.first)}},inputs:{addInfo:"addInfo",allowNodeOverlap:"allowNodeOverlap",annotations:"annotations",bezierSettings:"bezierSettings",bridgeSpace:"bridgeSpace",connectionPadding:"connectionPadding",connectorSpacing:"connectorSpacing",constraints:"constraints",cornerRadius:"cornerRadius",dragSize:"dragSize",excludeFromLayout:"excludeFromLayout",fixedUserHandles:"fixedUserHandles",flip:"flip",flipMode:"flipMode",hitPadding:"hitPadding",id:"id",margin:"margin",maxSegmentThumb:"maxSegmentThumb",ports:"ports",previewSize:"previewSize",segmentThumbShape:"segmentThumbShape",segmentThumbSize:"segmentThumbSize",segments:"segments",shape:"shape",sourceDecorator:"sourceDecorator",sourceID:"sourceID",sourcePadding:"sourcePadding",sourcePoint:"sourcePoint",sourcePortID:"sourcePortID",style:"style",symbolInfo:"symbolInfo",targetDecorator:"targetDecorator",targetID:"targetID",targetPadding:"targetPadding",targetPoint:"targetPoint",targetPortID:"targetPortID",tooltip:"tooltip",type:"type",visible:"visible",wrapper:"wrapper",zIndex:"zIndex"},features:[yn]}),n})(),fle=(()=>{class n extends dh{constructor(){super("connectors")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-connectors"]],contentQueries:function(e,i,r){if(1&e&&dn(r,ple,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),gle=["cornerRadius","fill","handleStrokeColor","handleStrokeWidth","height","iconStrokeColor","iconStrokeWidth","id","margin","offset","padding","pathData","tooltip","visibility","width"],vle=[],mle=(()=>{class n extends ch{constructor(e){super(),this.viewContainerRef=e,gl("currentInstance",this,this.viewContainerRef),this.registerEvents(vle),this.directivePropList=gle}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-node-fixeduserhandle"]],inputs:{cornerRadius:"cornerRadius",fill:"fill",handleStrokeColor:"handleStrokeColor",handleStrokeWidth:"handleStrokeWidth",height:"height",iconStrokeColor:"iconStrokeColor",iconStrokeWidth:"iconStrokeWidth",id:"id",margin:"margin",offset:"offset",padding:"padding",pathData:"pathData",tooltip:"tooltip",visibility:"visibility",width:"width"},features:[yn]}),n})(),yle=(()=>{class n extends dh{constructor(){super("fixeduserhandles")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-node-fixeduserhandles"]],contentQueries:function(e,i,r){if(1&e&&dn(r,mle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),Sle=["addInfo","annotationType","constraints","content","dragLimit","height","horizontalAlignment","hyperlink","id","margin","offset","rotateAngle","rotationReference","style","template","tooltip","type","verticalAlignment","visibility","width"],Ile=[],v_=(()=>{class n extends ch{constructor(e){super(),this.viewContainerRef=e,gl("currentInstance",this,this.viewContainerRef),this.registerEvents(Ile),this.directivePropList=Sle}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-node-annotation"]],inputs:{addInfo:"addInfo",annotationType:"annotationType",constraints:"constraints",content:"content",dragLimit:"dragLimit",height:"height",horizontalAlignment:"horizontalAlignment",hyperlink:"hyperlink",id:"id",margin:"margin",offset:"offset",rotateAngle:"rotateAngle",rotationReference:"rotationReference",style:"style",template:"template",tooltip:"tooltip",type:"type",verticalAlignment:"verticalAlignment",visibility:"visibility",width:"width"},features:[yn]}),n})(),m_=(()=>{class n extends dh{constructor(){super("annotations")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-node-annotations"]],contentQueries:function(e,i,r){if(1&e&&dn(r,v_,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),ble=["addInfo","connectionDirection","constraints","height","horizontalAlignment","id","inEdges","margin","offset","outEdges","pathData","shape","style","tooltip","verticalAlignment","visibility","width"],Mle=[],wle=(()=>{class n extends ch{constructor(e){super(),this.viewContainerRef=e,gl("currentInstance",this,this.viewContainerRef),this.registerEvents(Mle),this.directivePropList=ble}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-node-port"]],inputs:{addInfo:"addInfo",connectionDirection:"connectionDirection",constraints:"constraints",height:"height",horizontalAlignment:"horizontalAlignment",id:"id",inEdges:"inEdges",margin:"margin",offset:"offset",outEdges:"outEdges",pathData:"pathData",shape:"shape",style:"style",tooltip:"tooltip",verticalAlignment:"verticalAlignment",visibility:"visibility",width:"width"},features:[yn]}),n})(),Cle=(()=>{class n extends dh{constructor(){super("ports")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-node-ports"]],contentQueries:function(e,i,r){if(1&e&&dn(r,wle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),Ele=["addInfo","annotations","backgroundColor","borderColor","borderWidth","branch","children","collapseIcon","columnIndex","columnSpan","columns","constraints","container","data","dragSize","excludeFromLayout","expandIcon","fixedUserHandles","flip","flipMode","height","horizontalAlignment","id","isExpanded","layoutInfo","margin","maxHeight","maxWidth","minHeight","minWidth","offsetX","offsetY","padding","pivot","ports","previewSize","rotateAngle","rowIndex","rowSpan","rows","shadow","shape","style","symbolInfo","tooltip","verticalAlignment","visible","width","wrapper","zIndex"],Dle=[],y_=(()=>{class n extends ch{constructor(e){super(),this.viewContainerRef=e,this.tags=["fixedUserHandles","annotations","ports"],gl("currentInstance",this,this.viewContainerRef),this.registerEvents(Dle),this.directivePropList=Ele}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-node"]],contentQueries:function(e,i,r){if(1&e&&(dn(r,yle,5),dn(r,m_,5),dn(r,Cle,5)),2&e){let s;Kr(s=en())&&(i.childFixedUserHandles=s.first),Kr(s=en())&&(i.childAnnotations=s.first),Kr(s=en())&&(i.childPorts=s.first)}},inputs:{addInfo:"addInfo",annotations:"annotations",backgroundColor:"backgroundColor",borderColor:"borderColor",borderWidth:"borderWidth",branch:"branch",children:"children",collapseIcon:"collapseIcon",columnIndex:"columnIndex",columnSpan:"columnSpan",columns:"columns",constraints:"constraints",container:"container",data:"data",dragSize:"dragSize",excludeFromLayout:"excludeFromLayout",expandIcon:"expandIcon",fixedUserHandles:"fixedUserHandles",flip:"flip",flipMode:"flipMode",height:"height",horizontalAlignment:"horizontalAlignment",id:"id",isExpanded:"isExpanded",layoutInfo:"layoutInfo",margin:"margin",maxHeight:"maxHeight",maxWidth:"maxWidth",minHeight:"minHeight",minWidth:"minWidth",offsetX:"offsetX",offsetY:"offsetY",padding:"padding",pivot:"pivot",ports:"ports",previewSize:"previewSize",rotateAngle:"rotateAngle",rowIndex:"rowIndex",rowSpan:"rowSpan",rows:"rows",shadow:"shadow",shape:"shape",style:"style",symbolInfo:"symbolInfo",tooltip:"tooltip",verticalAlignment:"verticalAlignment",visible:"visible",width:"width",wrapper:"wrapper",zIndex:"zIndex"},features:[yn]}),n})(),S_=(()=>{class n extends dh{constructor(){super("nodes")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-nodes"]],contentQueries:function(e,i,r){if(1&e&&dn(r,y_,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})();const xle=["animationComplete","click","collectionChange","commandExecute","connectionChange","contextMenuBeforeItemRender","contextMenuClick","contextMenuOpen","created","dataLoaded","doubleClick","dragEnter","dragLeave","dragOver","drop","elementDraw","expandStateChange","fixedUserHandleClick","historyChange","historyStateChange","keyDown","keyUp","load","loaded","mouseEnter","mouseLeave","mouseOver","mouseWheel","onFixedUserHandleMouseDown","onFixedUserHandleMouseEnter","onFixedUserHandleMouseLeave","onFixedUserHandleMouseUp","onImageLoad","onUserHandleMouseDown","onUserHandleMouseEnter","onUserHandleMouseLeave","onUserHandleMouseUp","positionChange","propertyChange","rotateChange","scrollChange","segmentChange","segmentCollectionChange","selectionChange","sizeChange","sourcePointChange","targetPointChange","textEdit"],Tle=[""];let Ale=(()=>{let n=class extends Rl{constructor(e,i,r,s){super(),this.ngEle=e,this.srenderer=i,this.viewContainerRef=r,this.injector=s,this.tags=["layers","customCursor","connectors","nodes"],this.element=this.ngEle.nativeElement,this.injectedModules=this.injectedModules||[];try{let o=this.injector.get("DiagramsHierarchicalTree");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsMindMap");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsRadialTree");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsComplexHierarchicalTree");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsDataBinding");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsSnapping");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsPrintAndExport");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsBpmnDiagrams");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsSymmetricLayout");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsConnectorBridging");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsUndoRedo");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsLayoutAnimation");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsDiagramContextMenu");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsLineRouting");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsConnectorEditing");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsLineDistribution");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsEj1Serialization");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsFlowchartLayout");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}this.registerEvents(xle),this.addTwoWay.call(this,Tle),gl("currentInstance",this,this.viewContainerRef),this.context=new SR}ngOnInit(){this.context.ngOnInit(this)}ngAfterViewInit(){this.context.ngAfterViewInit(this)}ngOnDestroy(){this.context.ngOnDestroy(this)}ngAfterContentChecked(){this.tagObjects[0].instance=this.childLayers,this.childCustomCursor&&(this.tagObjects[1].instance=this.childCustomCursor),this.childConnectors&&(this.tagObjects[2].instance=this.childConnectors),this.childNodes&&(this.tagObjects[3].instance=this.childNodes),this.context.ngAfterContentChecked(this)}};return n.\u0275fac=function(e){return new(e||n)(Ot($c),Ot(hM),Ot(xn),Ot(Wo))},n.\u0275cmp=Fb({type:n,selectors:[["ejs-diagram"]],contentQueries:function(e,i,r){if(1&e&&(dn(r,Qae,5),dn(r,Gae,5),dn(r,Xae,5),dn(r,Jae,5),dn(r,ile,5),dn(r,fle,5),dn(r,S_,5)),2&e){let s;Kr(s=en())&&(i.annotationTemplate=s.first),Kr(s=en())&&(i.nodeTemplate=s.first),Kr(s=en())&&(i.userHandleTemplate=s.first),Kr(s=en())&&(i.childLayers=s.first),Kr(s=en())&&(i.childCustomCursor=s.first),Kr(s=en())&&(i.childConnectors=s.first),Kr(s=en())&&(i.childNodes=s.first)}},inputs:{addInfo:"addInfo",annotationTemplate:"annotationTemplate",backgroundColor:"backgroundColor",bridgeDirection:"bridgeDirection",commandManager:"commandManager",connectorDefaults:"connectorDefaults",connectors:"connectors",constraints:"constraints",contextMenuSettings:"contextMenuSettings",customCursor:"customCursor",dataSourceSettings:"dataSourceSettings",diagramSettings:"diagramSettings",drawingObject:"drawingObject",enableConnectorSplit:"enableConnectorSplit",enablePersistence:"enablePersistence",enableRtl:"enableRtl",fixedUserHandleTemplate:"fixedUserHandleTemplate",getConnectorDefaults:"getConnectorDefaults",getCustomCursor:"getCustomCursor",getCustomProperty:"getCustomProperty",getCustomTool:"getCustomTool",getDescription:"getDescription",getNodeDefaults:"getNodeDefaults",height:"height",historyManager:"historyManager",layers:"layers",layout:"layout",locale:"locale",mode:"mode",nodeDefaults:"nodeDefaults",nodeTemplate:"nodeTemplate",nodes:"nodes",pageSettings:"pageSettings",rulerSettings:"rulerSettings",scrollSettings:"scrollSettings",segmentThumbShape:"segmentThumbShape",segmentThumbSize:"segmentThumbSize",selectedItems:"selectedItems",serializationSettings:"serializationSettings",setNodeTemplate:"setNodeTemplate",snapSettings:"snapSettings",tool:"tool",tooltip:"tooltip",updateSelection:"updateSelection",userHandleTemplate:"userHandleTemplate",width:"width"},outputs:{animationComplete:"animationComplete",click:"click",collectionChange:"collectionChange",commandExecute:"commandExecute",connectionChange:"connectionChange",contextMenuBeforeItemRender:"contextMenuBeforeItemRender",contextMenuClick:"contextMenuClick",contextMenuOpen:"contextMenuOpen",created:"created",dataLoaded:"dataLoaded",doubleClick:"doubleClick",dragEnter:"dragEnter",dragLeave:"dragLeave",dragOver:"dragOver",drop:"drop",elementDraw:"elementDraw",expandStateChange:"expandStateChange",fixedUserHandleClick:"fixedUserHandleClick",historyChange:"historyChange",historyStateChange:"historyStateChange",keyDown:"keyDown",keyUp:"keyUp",load:"load",loaded:"loaded",mouseEnter:"mouseEnter",mouseLeave:"mouseLeave",mouseOver:"mouseOver",mouseWheel:"mouseWheel",onFixedUserHandleMouseDown:"onFixedUserHandleMouseDown",onFixedUserHandleMouseEnter:"onFixedUserHandleMouseEnter",onFixedUserHandleMouseLeave:"onFixedUserHandleMouseLeave",onFixedUserHandleMouseUp:"onFixedUserHandleMouseUp",onImageLoad:"onImageLoad",onUserHandleMouseDown:"onUserHandleMouseDown",onUserHandleMouseEnter:"onUserHandleMouseEnter",onUserHandleMouseLeave:"onUserHandleMouseLeave",onUserHandleMouseUp:"onUserHandleMouseUp",positionChange:"positionChange",propertyChange:"propertyChange",rotateChange:"rotateChange",scrollChange:"scrollChange",segmentChange:"segmentChange",segmentCollectionChange:"segmentCollectionChange",selectionChange:"selectionChange",sizeChange:"sizeChange",sourcePointChange:"sourcePointChange",targetPointChange:"targetPointChange",textEdit:"textEdit"},features:[yn],decls:0,vars:0,template:function(e,i){},encapsulation:2,changeDetection:0}),O0([DC()],n.prototype,"annotationTemplate",void 0),O0([DC()],n.prototype,"nodeTemplate",void 0),O0([DC()],n.prototype,"userHandleTemplate",void 0),n=O0([PZ([SR])],n),n})(),Lle=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Nm({type:n}),n.\u0275inj=yf({imports:[[sq]]}),n})();const Nle=["diagram"];let Ole=(()=>{class n{constructor(){this.layers=[]}ngOnInit(){this.layers=[{id:"layer1",objects:["node1","node3"]},{id:"layers2",objects:["node2"]}]}clonelayer(){this.diagram.cloneLayer("layer1")}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275cmp=Fb({type:n,selectors:[["app-container"]],viewQuery:function(i,r){if(1&i&&function uP(n,t,e){const i=xi();i.firstCreatePass&&(cP(i,new aP(n,t,e),-1),2==(2&t)&&(i.staticViewQueries=!0)),hP(i,Se(),t)}(Nle,5),2&i){let s;Kr(s=en())&&(r.diagram=s.first)}},standalone:!0,features:[PP([]),RP],decls:14,vars:13,consts:[["id","diagram","width","100%","height","580px",3,"layers"],["diagram",""],["id","node1",3,"width","height","offsetX","offsetY"],["content","Layer 1 Object"],["id","node2",3,"width","height","offsetX","offsetY"],["content","Layer 2 Object"],["id","node3",3,"width","height","offsetX","offsetY"],[3,"click"]],template:function(i,r){1&i&&(id(0,"ejs-diagram",0,1)(2,"e-nodes")(3,"e-node",2)(4,"e-node-annotations"),dg(5,"e-node-annotation",3),rd()(),id(6,"e-node",4)(7,"e-node-annotations"),dg(8,"e-node-annotation",5),rd()(),id(9,"e-node",6)(10,"e-node-annotations"),dg(11,"e-node-annotation",3),rd()()()(),id(12,"button",7),aw("click",function(){return r.clonelayer()}),function MP(n,t=""){const e=Se(),i=xi(),r=n+Ut,s=i.firstCreatePass?Au(i,r,1,t,null):i.data[r],o=wP(i,e,s,t,n);e[r]=o,Bm()&&cy(i,e,o,s),ol(s,!1)}(13,"clonelayer"),rd()),2&i&&(Xu("layers",r.layers),Ey(3),Xu("width",100)("height",100)("offsetX",100)("offsetY",100),Ey(3),Xu("width",100)("height",100)("offsetX",160)("offsetY",360),Ey(3),Xu("width",100)("height",100)("offsetX",300)("offsetY",100))},dependencies:[Lle,Ale,v_,m_,y_,S_],encapsulation:2})}}return n})();Vd(332),function $q(n,t){return DG({rootComponent:n,...Ez(t)})}(Ole).catch(n=>console.error(n))},332:()=>{!function(Z){const se=Z.performance;function ye(Pi){se&&se.mark&&se.mark(Pi)}function fe(Pi,ht){se&&se.measure&&se.measure(Pi,ht)}ye("Zone");const be=Z.__Zone_symbol_prefix||"__zone_symbol__";function ke(Pi){return be+Pi}const at=!0===Z[ke("forceDuplicateZoneCheck")];if(Z.Zone){if(at||"function"!=typeof Z.Zone.__symbol__)throw new Error("Zone already loaded.");return Z.Zone}let tt=(()=>{class Pi{static{this.__symbol__=ke}static assertZonePatched(){if(Z.Promise!==_o.ZoneAwarePromise)throw new Error("Zone.js has detected that ZoneAwarePromise `(window|global).Promise` has been overwritten.\nMost likely cause is that a Promise polyfill has been loaded after Zone.js (Polyfilling Promise api is not necessary when zone.js is loaded. If you must load one, do so before loading zone.js.)")}static get root(){let F=Pi.current;for(;F.parent;)F=F.parent;return F}static get current(){return Ur.zone}static get currentTask(){return Do}static __load_patch(F,ae,Et=!1){if(_o.hasOwnProperty(F)){if(!Et&&at)throw Error("Already loaded patch: "+F)}else if(!Z["__Zone_disable_"+F]){const Xt="Zone:"+F;ye(Xt),_o[F]=ae(Z,Pi,cn),fe(Xt,Xt)}}get parent(){return this._parent}get name(){return this._name}constructor(F,ae){this._parent=F,this._name=ae?ae.name||"unnamed":"",this._properties=ae&&ae.properties||{},this._zoneDelegate=new Lt(this,this._parent&&this._parent._zoneDelegate,ae)}get(F){const ae=this.getZoneWith(F);if(ae)return ae._properties[F]}getZoneWith(F){let ae=this;for(;ae;){if(ae._properties.hasOwnProperty(F))return ae;ae=ae._parent}return null}fork(F){if(!F)throw new Error("ZoneSpec required!");return this._zoneDelegate.fork(this,F)}wrap(F,ae){if("function"!=typeof F)throw new Error("Expecting function got: "+F);const Et=this._zoneDelegate.intercept(this,F,ae),Xt=this;return function(){return Xt.runGuarded(Et,this,arguments,ae)}}run(F,ae,Et,Xt){Ur={parent:Ur,zone:this};try{return this._zoneDelegate.invoke(this,F,ae,Et,Xt)}finally{Ur=Ur.parent}}runGuarded(F,ae=null,Et,Xt){Ur={parent:Ur,zone:this};try{try{return this._zoneDelegate.invoke(this,F,ae,Et,Xt)}catch(Un){if(this._zoneDelegate.handleError(this,Un))throw Un}}finally{Ur=Ur.parent}}runTask(F,ae,Et){if(F.zone!=this)throw new Error("A task can only be run in the zone of creation! (Creation: "+(F.zone||_n).name+"; Execution: "+this.name+")");if(F.state===sr&&(F.type===ts||F.type===Pt))return;const Xt=F.state!=lt;Xt&&F._transitionTo(lt,ki),F.runCount++;const Un=Do;Do=F,Ur={parent:Ur,zone:this};try{F.type==Pt&&F.data&&!F.data.isPeriodic&&(F.cancelFn=void 0);try{return this._zoneDelegate.invokeTask(this,F,ae,Et)}catch(Ue){if(this._zoneDelegate.handleError(this,Ue))throw Ue}}finally{F.state!==sr&&F.state!==et&&(F.type==ts||F.data&&F.data.isPeriodic?Xt&&F._transitionTo(ki,lt):(F.runCount=0,this._updateTaskCount(F,-1),Xt&&F._transitionTo(sr,lt,sr))),Ur=Ur.parent,Do=Un}}scheduleTask(F){if(F.zone&&F.zone!==this){let Et=this;for(;Et;){if(Et===F.zone)throw Error(`can not reschedule task to ${this.name} which is descendants of the original zone ${F.zone.name}`);Et=Et.parent}}F._transitionTo(Zr,sr);const ae=[];F._zoneDelegates=ae,F._zone=this;try{F=this._zoneDelegate.scheduleTask(this,F)}catch(Et){throw F._transitionTo(et,Zr,sr),this._zoneDelegate.handleError(this,Et),Et}return F._zoneDelegates===ae&&this._updateTaskCount(F,1),F.state==Zr&&F._transitionTo(ki,Zr),F}scheduleMicroTask(F,ae,Et,Xt){return this.scheduleTask(new ft(vi,F,ae,Et,Xt,void 0))}scheduleMacroTask(F,ae,Et,Xt,Un){return this.scheduleTask(new ft(Pt,F,ae,Et,Xt,Un))}scheduleEventTask(F,ae,Et,Xt,Un){return this.scheduleTask(new ft(ts,F,ae,Et,Xt,Un))}cancelTask(F){if(F.zone!=this)throw new Error("A task can only be cancelled in the zone of creation! (Creation: "+(F.zone||_n).name+"; Execution: "+this.name+")");if(F.state===ki||F.state===lt){F._transitionTo(dr,ki,lt);try{this._zoneDelegate.cancelTask(this,F)}catch(ae){throw F._transitionTo(et,dr),this._zoneDelegate.handleError(this,ae),ae}return this._updateTaskCount(F,-1),F._transitionTo(sr,dr),F.runCount=0,F}}_updateTaskCount(F,ae){const Et=F._zoneDelegates;-1==ae&&(F._zoneDelegates=null);for(let Xt=0;XtPi.hasTask(F,ae),onScheduleTask:(Pi,ht,F,ae)=>Pi.scheduleTask(F,ae),onInvokeTask:(Pi,ht,F,ae,Et,Xt)=>Pi.invokeTask(F,ae,Et,Xt),onCancelTask:(Pi,ht,F,ae)=>Pi.cancelTask(F,ae)};class Lt{constructor(ht,F,ae){this._taskCounts={microTask:0,macroTask:0,eventTask:0},this.zone=ht,this._parentDelegate=F,this._forkZS=ae&&(ae&&ae.onFork?ae:F._forkZS),this._forkDlgt=ae&&(ae.onFork?F:F._forkDlgt),this._forkCurrZone=ae&&(ae.onFork?this.zone:F._forkCurrZone),this._interceptZS=ae&&(ae.onIntercept?ae:F._interceptZS),this._interceptDlgt=ae&&(ae.onIntercept?F:F._interceptDlgt),this._interceptCurrZone=ae&&(ae.onIntercept?this.zone:F._interceptCurrZone),this._invokeZS=ae&&(ae.onInvoke?ae:F._invokeZS),this._invokeDlgt=ae&&(ae.onInvoke?F:F._invokeDlgt),this._invokeCurrZone=ae&&(ae.onInvoke?this.zone:F._invokeCurrZone),this._handleErrorZS=ae&&(ae.onHandleError?ae:F._handleErrorZS),this._handleErrorDlgt=ae&&(ae.onHandleError?F:F._handleErrorDlgt),this._handleErrorCurrZone=ae&&(ae.onHandleError?this.zone:F._handleErrorCurrZone),this._scheduleTaskZS=ae&&(ae.onScheduleTask?ae:F._scheduleTaskZS),this._scheduleTaskDlgt=ae&&(ae.onScheduleTask?F:F._scheduleTaskDlgt),this._scheduleTaskCurrZone=ae&&(ae.onScheduleTask?this.zone:F._scheduleTaskCurrZone),this._invokeTaskZS=ae&&(ae.onInvokeTask?ae:F._invokeTaskZS),this._invokeTaskDlgt=ae&&(ae.onInvokeTask?F:F._invokeTaskDlgt),this._invokeTaskCurrZone=ae&&(ae.onInvokeTask?this.zone:F._invokeTaskCurrZone),this._cancelTaskZS=ae&&(ae.onCancelTask?ae:F._cancelTaskZS),this._cancelTaskDlgt=ae&&(ae.onCancelTask?F:F._cancelTaskDlgt),this._cancelTaskCurrZone=ae&&(ae.onCancelTask?this.zone:F._cancelTaskCurrZone),this._hasTaskZS=null,this._hasTaskDlgt=null,this._hasTaskDlgtOwner=null,this._hasTaskCurrZone=null;const Et=ae&&ae.onHasTask;(Et||F&&F._hasTaskZS)&&(this._hasTaskZS=Et?ae:At,this._hasTaskDlgt=F,this._hasTaskDlgtOwner=this,this._hasTaskCurrZone=ht,ae.onScheduleTask||(this._scheduleTaskZS=At,this._scheduleTaskDlgt=F,this._scheduleTaskCurrZone=this.zone),ae.onInvokeTask||(this._invokeTaskZS=At,this._invokeTaskDlgt=F,this._invokeTaskCurrZone=this.zone),ae.onCancelTask||(this._cancelTaskZS=At,this._cancelTaskDlgt=F,this._cancelTaskCurrZone=this.zone))}fork(ht,F){return this._forkZS?this._forkZS.onFork(this._forkDlgt,this.zone,ht,F):new tt(ht,F)}intercept(ht,F,ae){return this._interceptZS?this._interceptZS.onIntercept(this._interceptDlgt,this._interceptCurrZone,ht,F,ae):F}invoke(ht,F,ae,Et,Xt){return this._invokeZS?this._invokeZS.onInvoke(this._invokeDlgt,this._invokeCurrZone,ht,F,ae,Et,Xt):F.apply(ae,Et)}handleError(ht,F){return!this._handleErrorZS||this._handleErrorZS.onHandleError(this._handleErrorDlgt,this._handleErrorCurrZone,ht,F)}scheduleTask(ht,F){let ae=F;if(this._scheduleTaskZS)this._hasTaskZS&&ae._zoneDelegates.push(this._hasTaskDlgtOwner),ae=this._scheduleTaskZS.onScheduleTask(this._scheduleTaskDlgt,this._scheduleTaskCurrZone,ht,F),ae||(ae=F);else if(F.scheduleFn)F.scheduleFn(F);else{if(F.type!=vi)throw new Error("Task is missing scheduleFn.");Wt(F)}return ae}invokeTask(ht,F,ae,Et){return this._invokeTaskZS?this._invokeTaskZS.onInvokeTask(this._invokeTaskDlgt,this._invokeTaskCurrZone,ht,F,ae,Et):F.callback.apply(ae,Et)}cancelTask(ht,F){let ae;if(this._cancelTaskZS)ae=this._cancelTaskZS.onCancelTask(this._cancelTaskDlgt,this._cancelTaskCurrZone,ht,F);else{if(!F.cancelFn)throw Error("Task is not cancelable");ae=F.cancelFn(F)}return ae}hasTask(ht,F){try{this._hasTaskZS&&this._hasTaskZS.onHasTask(this._hasTaskDlgt,this._hasTaskCurrZone,ht,F)}catch(ae){this.handleError(ht,ae)}}_updateTaskCount(ht,F){const ae=this._taskCounts,Et=ae[ht],Xt=ae[ht]=Et+F;if(Xt<0)throw new Error("More tasks executed then were scheduled.");0!=Et&&0!=Xt||this.hasTask(this.zone,{microTask:ae.microTask>0,macroTask:ae.macroTask>0,eventTask:ae.eventTask>0,change:ht})}}class ft{constructor(ht,F,ae,Et,Xt,Un){if(this._zone=null,this.runCount=0,this._zoneDelegates=null,this._state="notScheduled",this.type=ht,this.source=F,this.data=Et,this.scheduleFn=Xt,this.cancelFn=Un,!ae)throw new Error("callback is not defined");this.callback=ae;const Ue=this;this.invoke=ht===ts&&Et&&Et.useG?ft.invokeTask:function(){return ft.invokeTask.call(Z,Ue,this,arguments)}}static invokeTask(ht,F,ae){ht||(ht=this),Ls++;try{return ht.runCount++,ht.zone.runTask(ht,F,ae)}finally{1==Ls&&ct(),Ls--}}get zone(){return this._zone}get state(){return this._state}cancelScheduleRequest(){this._transitionTo(sr,Zr)}_transitionTo(ht,F,ae){if(this._state!==F&&this._state!==ae)throw new Error(`${this.type} '${this.source}': can not transition to '${ht}', expecting state '${F}'${ae?" or '"+ae+"'":""}, was '${this._state}'.`);this._state=ht,ht==sr&&(this._zoneDelegates=null)}toString(){return this.data&&typeof this.data.handleId<"u"?this.data.handleId.toString():Object.prototype.toString.call(this)}toJSON(){return{type:this.type,state:this.state,source:this.source,zone:this.zone.name,runCount:this.runCount}}}const Ei=ke("setTimeout"),ti=ke("Promise"),gi=ke("then");let es,cr=[],Oi=!1;function kr(Pi){if(es||Z[ti]&&(es=Z[ti].resolve(0)),es){let ht=es[gi];ht||(ht=es.then),ht.call(es,Pi)}else Z[Ei](Pi,0)}function Wt(Pi){0===Ls&&0===cr.length&&kr(ct),Pi&&cr.push(Pi)}function ct(){if(!Oi){for(Oi=!0;cr.length;){const Pi=cr;cr=[];for(let ht=0;htUr,onUnhandledError:jr,microtaskDrainDone:jr,scheduleMicroTask:Wt,showUncaughtError:()=>!tt[ke("ignoreConsoleErrorUncaughtError")],patchEventTarget:()=>[],patchOnProperties:jr,patchMethod:()=>jr,bindArguments:()=>[],patchThen:()=>jr,patchMacroTask:()=>jr,patchEventPrototype:()=>jr,isIEOrEdge:()=>!1,getGlobalObjects:()=>{},ObjectDefineProperty:()=>jr,ObjectGetOwnPropertyDescriptor:()=>{},ObjectCreate:()=>{},ArraySlice:()=>[],patchClass:()=>jr,wrapWithCurrentZone:()=>jr,filterProperties:()=>[],attachOriginToPatched:()=>jr,_redefineProperty:()=>jr,patchCallbacks:()=>jr,nativeScheduleMicroTask:kr};let Ur={parent:null,zone:new tt(null,null)},Do=null,Ls=0;function jr(){}fe("Zone","Zone"),Z.Zone=tt}(globalThis);const _l=Object.getOwnPropertyDescriptor,jd=Object.defineProperty,Vd=Object.getPrototypeOf,Wd=Object.create,yb=Array.prototype.slice,gm="addEventListener",$r="removeEventListener",Ul=Zone.__symbol__(gm),Fh=Zone.__symbol__($r),Ts="true",Wi="false",Yd=Zone.__symbol__("");function hf(Z,se){return Zone.current.wrap(Z,se)}function vm(Z,se,ye,fe,be){return Zone.current.scheduleMacroTask(Z,se,ye,fe,be)}const Ji=Zone.__symbol__,_h=typeof window<"u",Uh=_h?window:void 0,gn=_h&&Uh||globalThis,mm="removeAttribute";function Qd(Z,se){for(let ye=Z.length-1;ye>=0;ye--)"function"==typeof Z[ye]&&(Z[ye]=hf(Z[ye],se+"_"+ye));return Z}function cf(Z){return!Z||!1!==Z.writable&&!("function"==typeof Z.get&&typeof Z.set>"u")}const df=typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope,jh=!("nw"in gn)&&typeof gn.process<"u"&&"[object process]"==={}.toString.call(gn.process),Gd=!jh&&!df&&!(!_h||!Uh.HTMLElement),uf=typeof gn.process<"u"&&"[object process]"==={}.toString.call(gn.process)&&!df&&!(!_h||!Uh.HTMLElement),jl={},Vh=function(Z){if(!(Z=Z||gn.event))return;let se=jl[Z.type];se||(se=jl[Z.type]=Ji("ON_PROPERTY"+Z.type));const ye=this||Z.target||gn,fe=ye[se];let be;return Gd&&ye===Uh&&"error"===Z.type?(be=fe&&fe.call(this,Z.message,Z.filename,Z.lineno,Z.colno,Z.error),!0===be&&Z.preventDefault()):(be=fe&&fe.apply(this,arguments),null!=be&&!be&&Z.preventDefault()),be};function Vl(Z,se,ye){let fe=_l(Z,se);if(!fe&&ye&&_l(ye,se)&&(fe={enumerable:!0,configurable:!0}),!fe||!fe.configurable)return;const be=Ji("on"+se+"patched");if(Z.hasOwnProperty(be)&&Z[be])return;delete fe.writable,delete fe.value;const ke=fe.get,at=fe.set,tt=se.slice(2);let At=jl[tt];At||(At=jl[tt]=Ji("ON_PROPERTY"+tt)),fe.set=function(Lt){let ft=this;!ft&&Z===gn&&(ft=gn),ft&&("function"==typeof ft[At]&&ft.removeEventListener(tt,Vh),at&&at.call(ft,null),ft[At]=Lt,"function"==typeof Lt&&ft.addEventListener(tt,Vh,!1))},fe.get=function(){let Lt=this;if(!Lt&&Z===gn&&(Lt=gn),!Lt)return null;const ft=Lt[At];if(ft)return ft;if(ke){let Ei=ke.call(this);if(Ei)return fe.set.call(this,Ei),"function"==typeof Lt[mm]&&Lt.removeAttribute(se),Ei}return null},jd(Z,se,fe),Z[be]=!0}function pf(Z,se,ye){if(se)for(let fe=0;fefunction(at,tt){const At=ye(at,tt);return At.cbIdx>=0&&"function"==typeof tt[At.cbIdx]?vm(At.name,tt[At.cbIdx],At,be):ke.apply(at,tt)})}function Sa(Z,se){Z[Ji("OriginalDelegate")]=se}let Ib=!1,qd=!1;function bb(){if(Ib)return qd;Ib=!0;try{const Z=Uh.navigator.userAgent;(-1!==Z.indexOf("MSIE ")||-1!==Z.indexOf("Trident/")||-1!==Z.indexOf("Edge/"))&&(qd=!0)}catch{}return qd}Zone.__load_patch("ZoneAwarePromise",(Z,se,ye)=>{const fe=Object.getOwnPropertyDescriptor,be=Object.defineProperty,at=ye.symbol,tt=[],At=!1!==Z[at("DISABLE_WRAPPING_UNCAUGHT_PROMISE_REJECTION")],Lt=at("Promise"),ft=at("then"),Ei="__creationTrace__";ye.onUnhandledError=Ue=>{if(ye.showUncaughtError()){const He=Ue&&Ue.rejection;He?console.error("Unhandled Promise rejection:",He instanceof Error?He.message:He,"; Zone:",Ue.zone.name,"; Task:",Ue.task&&Ue.task.source,"; Value:",He,He instanceof Error?He.stack:void 0):console.error(Ue)}},ye.microtaskDrainDone=()=>{for(;tt.length;){const Ue=tt.shift();try{Ue.zone.runGuarded(()=>{throw Ue.throwOriginal?Ue.rejection:Ue})}catch(He){gi(He)}}};const ti=at("unhandledPromiseRejectionHandler");function gi(Ue){ye.onUnhandledError(Ue);try{const He=se[ti];"function"==typeof He&&He.call(this,Ue)}catch{}}function cr(Ue){return Ue&&Ue.then}function Oi(Ue){return Ue}function es(Ue){return F.reject(Ue)}const kr=at("state"),Wt=at("value"),ct=at("finally"),_n=at("parentPromiseValue"),sr=at("parentPromiseState"),Zr="Promise.then",ki=null,lt=!0,dr=!1,et=0;function vi(Ue,He){return ge=>{try{cn(Ue,He,ge)}catch(We){cn(Ue,!1,We)}}}const Pt=function(){let Ue=!1;return function(ge){return function(){Ue||(Ue=!0,ge.apply(null,arguments))}}},ts="Promise resolved with itself",_o=at("currentTaskTrace");function cn(Ue,He,ge){const We=Pt();if(Ue===ge)throw new TypeError(ts);if(Ue[kr]===ki){let wt=null;try{("object"==typeof ge||"function"==typeof ge)&&(wt=ge&&ge.then)}catch(Xe){return We(()=>{cn(Ue,!1,Xe)})(),Ue}if(He!==dr&&ge instanceof F&&ge.hasOwnProperty(kr)&&ge.hasOwnProperty(Wt)&&ge[kr]!==ki)Do(ge),cn(Ue,ge[kr],ge[Wt]);else if(He!==dr&&"function"==typeof wt)try{wt.call(ge,We(vi(Ue,He)),We(vi(Ue,!1)))}catch(Xe){We(()=>{cn(Ue,!1,Xe)})()}else{Ue[kr]=He;const Xe=Ue[Wt];if(Ue[Wt]=ge,Ue[ct]===ct&&He===lt&&(Ue[kr]=Ue[sr],Ue[Wt]=Ue[_n]),He===dr&&ge instanceof Error){const mt=se.currentTask&&se.currentTask.data&&se.currentTask.data[Ei];mt&&be(ge,_o,{configurable:!0,enumerable:!1,writable:!0,value:mt})}for(let mt=0;mt{try{const dt=Ue[Wt],qt=!!ge&&ct===ge[ct];qt&&(ge[_n]=dt,ge[sr]=Xe);const ai=He.run(mt,void 0,qt&&mt!==es&&mt!==Oi?[]:[dt]);cn(ge,!0,ai)}catch(dt){cn(ge,!1,dt)}},ge)}const Pi=function(){},ht=Z.AggregateError;class F{static toString(){return"function ZoneAwarePromise() { [native code] }"}static resolve(He){return He instanceof F?He:cn(new this(null),lt,He)}static reject(He){return cn(new this(null),dr,He)}static withResolvers(){const He={};return He.promise=new F((ge,We)=>{He.resolve=ge,He.reject=We}),He}static any(He){if(!He||"function"!=typeof He[Symbol.iterator])return Promise.reject(new ht([],"All promises were rejected"));const ge=[];let We=0;try{for(let mt of He)We++,ge.push(F.resolve(mt))}catch{return Promise.reject(new ht([],"All promises were rejected"))}if(0===We)return Promise.reject(new ht([],"All promises were rejected"));let wt=!1;const Xe=[];return new F((mt,dt)=>{for(let qt=0;qt{wt||(wt=!0,mt(ai))},ai=>{Xe.push(ai),We--,0===We&&(wt=!0,dt(new ht(Xe,"All promises were rejected")))})})}static race(He){let ge,We,wt=new this((dt,qt)=>{ge=dt,We=qt});function Xe(dt){ge(dt)}function mt(dt){We(dt)}for(let dt of He)cr(dt)||(dt=this.resolve(dt)),dt.then(Xe,mt);return wt}static all(He){return F.allWithCallback(He)}static allSettled(He){return(this&&this.prototype instanceof F?this:F).allWithCallback(He,{thenCallback:We=>({status:"fulfilled",value:We}),errorCallback:We=>({status:"rejected",reason:We})})}static allWithCallback(He,ge){let We,wt,Xe=new this((ai,ur)=>{We=ai,wt=ur}),mt=2,dt=0;const qt=[];for(let ai of He){cr(ai)||(ai=this.resolve(ai));const ur=dt;try{ai.then(ir=>{qt[ur]=ge?ge.thenCallback(ir):ir,mt--,0===mt&&We(qt)},ir=>{ge?(qt[ur]=ge.errorCallback(ir),mt--,0===mt&&We(qt)):wt(ir)})}catch(ir){wt(ir)}mt++,dt++}return mt-=2,0===mt&&We(qt),Xe}constructor(He){const ge=this;if(!(ge instanceof F))throw new Error("Must be an instanceof Promise.");ge[kr]=ki,ge[Wt]=[];try{const We=Pt();He&&He(We(vi(ge,lt)),We(vi(ge,dr)))}catch(We){cn(ge,!1,We)}}get[Symbol.toStringTag](){return"Promise"}get[Symbol.species](){return F}then(He,ge){let We=this.constructor?.[Symbol.species];(!We||"function"!=typeof We)&&(We=this.constructor||F);const wt=new We(Pi),Xe=se.current;return this[kr]==ki?this[Wt].push(Xe,wt,He,ge):Ls(this,Xe,wt,He,ge),wt}catch(He){return this.then(null,He)}finally(He){let ge=this.constructor?.[Symbol.species];(!ge||"function"!=typeof ge)&&(ge=F);const We=new ge(Pi);We[ct]=ct;const wt=se.current;return this[kr]==ki?this[Wt].push(wt,We,He,He):Ls(this,wt,We,He,He),We}}F.resolve=F.resolve,F.reject=F.reject,F.race=F.race,F.all=F.all;const ae=Z[Lt]=Z.Promise;Z.Promise=F;const Et=at("thenPatched");function Xt(Ue){const He=Ue.prototype,ge=fe(He,"then");if(ge&&(!1===ge.writable||!ge.configurable))return;const We=He.then;He[ft]=We,Ue.prototype.then=function(wt,Xe){return new F((dt,qt)=>{We.call(this,dt,qt)}).then(wt,Xe)},Ue[Et]=!0}return ye.patchThen=Xt,ae&&(Xt(ae),Ka(Z,"fetch",Ue=>function Un(Ue){return function(He,ge){let We=Ue.apply(He,ge);if(We instanceof F)return We;let wt=We.constructor;return wt[Et]||Xt(wt),We}}(Ue))),Promise[se.__symbol__("uncaughtPromiseErrors")]=tt,F}),Zone.__load_patch("toString",Z=>{const se=Function.prototype.toString,ye=Ji("OriginalDelegate"),fe=Ji("Promise"),be=Ji("Error"),ke=function(){if("function"==typeof this){const Lt=this[ye];if(Lt)return"function"==typeof Lt?se.call(Lt):Object.prototype.toString.call(Lt);if(this===Promise){const ft=Z[fe];if(ft)return se.call(ft)}if(this===Error){const ft=Z[be];if(ft)return se.call(ft)}}return se.call(this)};ke[ye]=se,Function.prototype.toString=ke;const at=Object.prototype.toString;Object.prototype.toString=function(){return"function"==typeof Promise&&this instanceof Promise?"[object Promise]":at.call(this)}});let el=!1;if(typeof window<"u")try{const Z=Object.defineProperty({},"passive",{get:function(){el=!0}});window.addEventListener("test",Z,Z),window.removeEventListener("test",Z,Z)}catch{el=!1}const PT={useG:!0},Co={},Mb={},Im=new RegExp("^"+Yd+"(\\w+)(true|false)$"),wb=Ji("propagationStopped");function bm(Z,se){const ye=(se?se(Z):Z)+Wi,fe=(se?se(Z):Z)+Ts,be=Yd+ye,ke=Yd+fe;Co[Z]={},Co[Z][Wi]=be,Co[Z][Ts]=ke}function Cb(Z,se,ye,fe){const be=fe&&fe.add||gm,ke=fe&&fe.rm||$r,at=fe&&fe.listeners||"eventListeners",tt=fe&&fe.rmAll||"removeAllListeners",At=Ji(be),Lt="."+be+":",ft="prependListener",Ei="."+ft+":",ti=function(Wt,ct,_n){if(Wt.isRemoved)return;const sr=Wt.callback;let Zr;"object"==typeof sr&&sr.handleEvent&&(Wt.callback=lt=>sr.handleEvent(lt),Wt.originalDelegate=sr);try{Wt.invoke(Wt,ct,[_n])}catch(lt){Zr=lt}const ki=Wt.options;return ki&&"object"==typeof ki&&ki.once&&ct[ke].call(ct,_n.type,Wt.originalDelegate?Wt.originalDelegate:Wt.callback,ki),Zr};function gi(Wt,ct,_n){if(!(ct=ct||Z.event))return;const sr=Wt||ct.target||Z,Zr=sr[Co[ct.type][_n?Ts:Wi]];if(Zr){const ki=[];if(1===Zr.length){const lt=ti(Zr[0],sr,ct);lt&&ki.push(lt)}else{const lt=Zr.slice();for(let dr=0;dr{throw dr})}}}const cr=function(Wt){return gi(this,Wt,!1)},Oi=function(Wt){return gi(this,Wt,!0)};function es(Wt,ct){if(!Wt)return!1;let _n=!0;ct&&void 0!==ct.useG&&(_n=ct.useG);const sr=ct&&ct.vh;let Zr=!0;ct&&void 0!==ct.chkDup&&(Zr=ct.chkDup);let ki=!1;ct&&void 0!==ct.rt&&(ki=ct.rt);let lt=Wt;for(;lt&&!lt.hasOwnProperty(be);)lt=Vd(lt);if(!lt&&Wt[be]&&(lt=Wt),!lt||lt[At])return!1;const dr=ct&&ct.eventNameToString,et={},vi=lt[At]=lt[be],Pt=lt[Ji(ke)]=lt[ke],ts=lt[Ji(at)]=lt[at],_o=lt[Ji(tt)]=lt[tt];let cn;ct&&ct.prepend&&(cn=lt[Ji(ct.prepend)]=lt[ct.prepend]);const F=_n?function(ge){if(!et.isExisting)return vi.call(et.target,et.eventName,et.capture?Oi:cr,et.options)}:function(ge){return vi.call(et.target,et.eventName,ge.invoke,et.options)},ae=_n?function(ge){if(!ge.isRemoved){const We=Co[ge.eventName];let wt;We&&(wt=We[ge.capture?Ts:Wi]);const Xe=wt&&ge.target[wt];if(Xe)for(let mt=0;mt{Vo.zone.cancelTask(Vo)},{once:!0})),et.target=null,Fc&&(Fc.taskData=null),Zd&&(Dn.once=!0),!el&&"boolean"==typeof Vo.options||(Vo.options=Dn),Vo.target=qt,Vo.capture=Gl,Vo.eventName=ai,ir&&(Vo.originalDelegate=ur),dt?jo.unshift(Vo):jo.push(Vo),mt?qt:void 0}};return lt[be]=He(vi,Lt,F,ae,ki),cn&&(lt[ft]=He(cn,Ei,function(ge){return cn.call(et.target,et.eventName,ge.invoke,et.options)},ae,ki,!0)),lt[ke]=function(){const ge=this||Z;let We=arguments[0];ct&&ct.transferEventName&&(We=ct.transferEventName(We));const wt=arguments[2],Xe=!!wt&&("boolean"==typeof wt||wt.capture),mt=arguments[1];if(!mt)return Pt.apply(this,arguments);if(sr&&!sr(Pt,mt,ge,arguments))return;const dt=Co[We];let qt;dt&&(qt=dt[Xe?Ts:Wi]);const ai=qt&&ge[qt];if(ai)for(let ur=0;urfunction(be,ke){be[wb]=!0,fe&&fe.apply(be,ke)})}function Db(Z,se,ye,fe,be){const ke=Zone.__symbol__(fe);if(se[ke])return;const at=se[ke]=se[fe];se[fe]=function(tt,At,Lt){return At&&At.prototype&&be.forEach(function(ft){const Ei=`${ye}.${fe}::`+ft,ti=At.prototype;try{if(ti.hasOwnProperty(ft)){const gi=Z.ObjectGetOwnPropertyDescriptor(ti,ft);gi&&gi.value?(gi.value=Z.wrapWithCurrentZone(gi.value,Ei),Z._redefineProperty(At.prototype,ft,gi)):ti[ft]&&(ti[ft]=Z.wrapWithCurrentZone(ti[ft],Ei))}else ti[ft]&&(ti[ft]=Z.wrapWithCurrentZone(ti[ft],Ei))}catch{}}),at.call(se,tt,At,Lt)},Z.attachOriginToPatched(se[fe],at)}function xb(Z,se,ye){if(!ye||0===ye.length)return se;const fe=ye.filter(ke=>ke.target===Z);if(!fe||0===fe.length)return se;const be=fe[0].ignoreProperties;return se.filter(ke=>-1===be.indexOf(ke))}function Eo(Z,se,ye,fe){Z&&pf(Z,xb(Z,se,ye),fe)}function $d(Z){return Object.getOwnPropertyNames(Z).filter(se=>se.startsWith("on")&&se.length>2).map(se=>se.substring(2))}Zone.__load_patch("util",(Z,se,ye)=>{const fe=$d(Z);ye.patchOnProperties=pf,ye.patchMethod=Ka,ye.bindArguments=Qd,ye.patchMacroTask=Sb;const be=se.__symbol__("BLACK_LISTED_EVENTS"),ke=se.__symbol__("UNPATCHED_EVENTS");Z[ke]&&(Z[be]=Z[ke]),Z[be]&&(se[be]=se[ke]=Z[be]),ye.patchEventPrototype=Mm,ye.patchEventTarget=Cb,ye.isIEOrEdge=bb,ye.ObjectDefineProperty=jd,ye.ObjectGetOwnPropertyDescriptor=_l,ye.ObjectCreate=Wd,ye.ArraySlice=yb,ye.patchClass=Xd,ye.wrapWithCurrentZone=hf,ye.filterProperties=xb,ye.attachOriginToPatched=Sa,ye._redefineProperty=Object.defineProperty,ye.patchCallbacks=Db,ye.getGlobalObjects=()=>({globalSources:Mb,zoneSymbolEventNames:Co,eventNames:fe,isBrowser:Gd,isMix:uf,isNode:jh,TRUE_STR:Ts,FALSE_STR:Wi,ZONE_SYMBOL_PREFIX:Yd,ADD_EVENT_LISTENER_STR:gm,REMOVE_EVENT_LISTENER_STR:$r})});const As=Ji("zoneTask");function Wl(Z,se,ye,fe){let be=null,ke=null;ye+=fe;const at={};function tt(Lt){const ft=Lt.data;return ft.args[0]=function(){return Lt.invoke.apply(this,arguments)},ft.handleId=be.apply(Z,ft.args),Lt}function At(Lt){return ke.call(Z,Lt.data.handleId)}be=Ka(Z,se+=fe,Lt=>function(ft,Ei){if("function"==typeof Ei[0]){const ti={isPeriodic:"Interval"===fe,delay:"Timeout"===fe||"Interval"===fe?Ei[1]||0:void 0,args:Ei},gi=Ei[0];Ei[0]=function(){try{return gi.apply(this,arguments)}finally{ti.isPeriodic||("number"==typeof ti.handleId?delete at[ti.handleId]:ti.handleId&&(ti.handleId[As]=null))}};const cr=vm(se,Ei[0],ti,tt,At);if(!cr)return cr;const Oi=cr.data.handleId;return"number"==typeof Oi?at[Oi]=cr:Oi&&(Oi[As]=cr),Oi&&Oi.ref&&Oi.unref&&"function"==typeof Oi.ref&&"function"==typeof Oi.unref&&(cr.ref=Oi.ref.bind(Oi),cr.unref=Oi.unref.bind(Oi)),"number"==typeof Oi||Oi?Oi:cr}return Lt.apply(Z,Ei)}),ke=Ka(Z,ye,Lt=>function(ft,Ei){const ti=Ei[0];let gi;"number"==typeof ti?gi=at[ti]:(gi=ti&&ti[As],gi||(gi=ti)),gi&&"string"==typeof gi.type?"notScheduled"!==gi.state&&(gi.cancelFn&&gi.data.isPeriodic||0===gi.runCount)&&("number"==typeof ti?delete at[ti]:ti&&(ti[As]=null),gi.zone.cancelTask(gi)):Lt.apply(Z,Ei)})}Zone.__load_patch("legacy",Z=>{const se=Z[Zone.__symbol__("legacyPatch")];se&&se()}),Zone.__load_patch("timers",Z=>{const ye="clear";Wl(Z,"set",ye,"Timeout"),Wl(Z,"set",ye,"Interval"),Wl(Z,"set",ye,"Immediate")}),Zone.__load_patch("requestAnimationFrame",Z=>{Wl(Z,"request","cancel","AnimationFrame"),Wl(Z,"mozRequest","mozCancel","AnimationFrame"),Wl(Z,"webkitRequest","webkitCancel","AnimationFrame")}),Zone.__load_patch("blocking",(Z,se)=>{const ye=["alert","prompt","confirm"];for(let fe=0;fefunction(At,Lt){return se.current.run(ke,Z,Lt,tt)})}),Zone.__load_patch("EventTarget",(Z,se,ye)=>{(function Yl(Z,se){se.patchEventPrototype(Z,se)})(Z,ye),function Cm(Z,se){if(Zone[se.symbol("patchEventTarget")])return;const{eventNames:ye,zoneSymbolEventNames:fe,TRUE_STR:be,FALSE_STR:ke,ZONE_SYMBOL_PREFIX:at}=se.getGlobalObjects();for(let At=0;At{Xd("MutationObserver"),Xd("WebKitMutationObserver")}),Zone.__load_patch("IntersectionObserver",(Z,se,ye)=>{Xd("IntersectionObserver")}),Zone.__load_patch("FileReader",(Z,se,ye)=>{Xd("FileReader")}),Zone.__load_patch("on_property",(Z,se,ye)=>{!function ff(Z,se){if(jh&&!uf||Zone[Z.symbol("patchEvents")])return;const ye=se.__Zone_ignore_on_properties;let fe=[];if(Gd){const be=window;fe=fe.concat(["Document","SVGElement","Element","HTMLElement","HTMLBodyElement","HTMLMediaElement","HTMLFrameSetElement","HTMLFrameElement","HTMLIFrameElement","HTMLMarqueeElement","Worker"]);const ke=function Sm(){try{const Z=Uh.navigator.userAgent;if(-1!==Z.indexOf("MSIE ")||-1!==Z.indexOf("Trident/"))return!0}catch{}return!1}()?[{target:be,ignoreProperties:["error"]}]:[];Eo(be,$d(be),ye&&ye.concat(ke),Vd(be))}fe=fe.concat(["XMLHttpRequest","XMLHttpRequestEventTarget","IDBIndex","IDBRequest","IDBOpenDBRequest","IDBDatabase","IDBTransaction","IDBCursor","WebSocket"]);for(let be=0;be{!function wm(Z,se){const{isBrowser:ye,isMix:fe}=se.getGlobalObjects();(ye||fe)&&Z.customElements&&"customElements"in Z&&se.patchCallbacks(se,Z.customElements,"customElements","define",["connectedCallback","disconnectedCallback","adoptedCallback","attributeChangedCallback"])}(Z,ye)}),Zone.__load_patch("XHR",(Z,se)=>{!function At(Lt){const ft=Lt.XMLHttpRequest;if(!ft)return;const Ei=ft.prototype;let gi=Ei[Ul],cr=Ei[Fh];if(!gi){const et=Lt.XMLHttpRequestEventTarget;if(et){const vi=et.prototype;gi=vi[Ul],cr=vi[Fh]}}const Oi="readystatechange",es="scheduled";function kr(et){const vi=et.data,Pt=vi.target;Pt[ke]=!1,Pt[tt]=!1;const ts=Pt[be];gi||(gi=Pt[Ul],cr=Pt[Fh]),ts&&cr.call(Pt,Oi,ts);const _o=Pt[be]=()=>{if(Pt.readyState===Pt.DONE)if(!vi.aborted&&Pt[ke]&&et.state===es){const Ur=Pt[se.__symbol__("loadfalse")];if(0!==Pt.status&&Ur&&Ur.length>0){const Do=et.invoke;et.invoke=function(){const Ls=Pt[se.__symbol__("loadfalse")];for(let jr=0;jrfunction(et,vi){return et[fe]=0==vi[2],et[at]=vi[1],_n.apply(et,vi)}),Zr=Ji("fetchTaskAborting"),ki=Ji("fetchTaskScheduling"),lt=Ka(Ei,"send",()=>function(et,vi){if(!0===se.current[ki]||et[fe])return lt.apply(et,vi);{const Pt={target:et,url:et[at],isPeriodic:!1,args:vi,aborted:!1},ts=vm("XMLHttpRequest.send",Wt,Pt,kr,ct);et&&!0===et[tt]&&!Pt.aborted&&ts.state===es&&ts.invoke()}}),dr=Ka(Ei,"abort",()=>function(et,vi){const Pt=function ti(et){return et[ye]}(et);if(Pt&&"string"==typeof Pt.type){if(null==Pt.cancelFn||Pt.data&&Pt.data.aborted)return;Pt.zone.cancelTask(Pt)}else if(!0===se.current[Zr])return dr.apply(et,vi)})}(Z);const ye=Ji("xhrTask"),fe=Ji("xhrSync"),be=Ji("xhrListener"),ke=Ji("xhrScheduled"),at=Ji("xhrURL"),tt=Ji("xhrErrorBeforeScheduled")}),Zone.__load_patch("geolocation",Z=>{Z.navigator&&Z.navigator.geolocation&&function ym(Z,se){const ye=Z.constructor.name;for(let fe=0;fe{const At=function(){return tt.apply(this,Qd(arguments,ye+"."+be))};return Sa(At,tt),At})(ke)}}}(Z.navigator.geolocation,["getCurrentPosition","watchPosition"])}),Zone.__load_patch("PromiseRejectionEvent",(Z,se)=>{function ye(fe){return function(be){Eb(Z,fe).forEach(at=>{const tt=Z.PromiseRejectionEvent;if(tt){const At=new tt(fe,{promise:be.promise,reason:be.rejection});at.invoke(At)}})}}Z.PromiseRejectionEvent&&(se[Ji("unhandledPromiseRejectionHandler")]=ye("unhandledrejection"),se[Ji("rejectionHandledHandler")]=ye("rejectionhandled"))}),Zone.__load_patch("queueMicrotask",(Z,se,ye)=>{!function gf(Z,se){se.patchMethod(Z,"queueMicrotask",ye=>function(fe,be){Zone.current.scheduleMicroTask("queueMicrotask",be[0])})}(Z,ye)})}},_l=>{_l(_l.s=51)}]); \ No newline at end of file diff --git a/ej2-angular/samples/diagram/layers/layers-cs8/main.df0256789227b196.js b/ej2-angular/samples/diagram/layers/layers-cs8/main.df0256789227b196.js new file mode 100644 index 0000000000..eea7f18b04 --- /dev/null +++ b/ej2-angular/samples/diagram/layers/layers-cs8/main.df0256789227b196.js @@ -0,0 +1 @@ +"use strict";(self.webpackChunksyncfusion_component=self.webpackChunksyncfusion_component||[]).push([[179],{51:(Wl,Vd,Wd)=>{let $r=null,_h=1;const Ts=Symbol("SIGNAL");function Wi(n){const t=$r;return $r=n,t}function gn(n){if((!Wh(n)||n.dirty)&&(n.dirty||n.lastCleanEpoch!==_h)){if(!n.producerMustRecompute(n)&&!Vh(n))return n.dirty=!1,void(n.lastCleanEpoch=_h);n.producerRecomputeValue(n),n.dirty=!1,n.lastCleanEpoch=_h}}function Vh(n){Gl(n);for(let t=0;t0}function Gl(n){n.producerNode??=[],n.producerIndexOfThis??=[],n.producerLastReadVersion??=[]}let $d=null;function Eo(n){return"function"==typeof n}function Zd(n){const e=n(i=>{Error.call(i),i.stack=(new Error).stack});return e.prototype=Object.create(Error.prototype),e.prototype.constructor=e,e}const pp=Zd(n=>function(e){n(this),this.message=e?`${e.length} errors occurred during unsubscription:\n${e.map((i,r)=>`${r+1}) ${i.toString()}`).join("\n ")}`:"",this.name="UnsubscriptionError",this.errors=e});function gp(n,t){if(n){const e=n.indexOf(t);0<=e&&n.splice(e,1)}}class As{constructor(t){this.initialTeardown=t,this.closed=!1,this._parentage=null,this._finalizers=null}unsubscribe(){let t;if(!this.closed){this.closed=!0;const{_parentage:e}=this;if(e)if(this._parentage=null,Array.isArray(e))for(const s of e)s.remove(this);else e.remove(this);const{initialTeardown:i}=this;if(Eo(i))try{i()}catch(s){t=s instanceof pp?s.errors:[s]}const{_finalizers:r}=this;if(r){this._finalizers=null;for(const s of r)try{Dm(s)}catch(o){t=t??[],o instanceof pp?t=[...t,...o.errors]:t.push(o)}}if(t)throw new pp(t)}}add(t){var e;if(t&&t!==this)if(this.closed)Dm(t);else{if(t instanceof As){if(t.closed||t._hasParent(this))return;t._addParent(this)}(this._finalizers=null!==(e=this._finalizers)&&void 0!==e?e:[]).push(t)}}_hasParent(t){const{_parentage:e}=this;return e===t||Array.isArray(e)&&e.includes(t)}_addParent(t){const{_parentage:e}=this;this._parentage=Array.isArray(e)?(e.push(t),e):e?[e,t]:t}_removeParent(t){const{_parentage:e}=this;e===t?this._parentage=null:Array.isArray(e)&&gp(e,t)}remove(t){const{_finalizers:e}=this;e&&gp(e,t),t instanceof As&&t._removeParent(this)}}As.EMPTY=(()=>{const n=new As;return n.closed=!0,n})();const Xl=As.EMPTY;function Em(n){return n instanceof As||n&&"closed"in n&&Eo(n.remove)&&Eo(n.add)&&Eo(n.unsubscribe)}function Dm(n){Eo(n)?n():n.unsubscribe()}const ql={onUnhandledError:null,onStoppedNotification:null,Promise:void 0,useDeprecatedSynchronousErrorHandling:!1,useDeprecatedNextContext:!1},Z={setTimeout(n,t,...e){const{delegate:i}=Z;return i?.setTimeout?i.setTimeout(n,t,...e):setTimeout(n,t,...e)},clearTimeout(n){const{delegate:t}=Z;return(t?.clearTimeout||clearTimeout)(n)},delegate:void 0};function ye(){}const pe=at("C",void 0,void 0);function at(n,t,e){return{kind:n,value:t,error:e}}let tt=null;function At(n){if(ql.useDeprecatedSynchronousErrorHandling){const t=!tt;if(t&&(tt={errorThrown:!1,error:null}),n(),t){const{errorThrown:e,error:i}=tt;if(tt=null,e)throw i}}else n()}class pt extends As{constructor(t){super(),this.isStopped=!1,t?(this.destination=t,Em(t)&&t.add(this)):this.destination=Wt}static create(t,e,i){return new cr(t,e,i)}next(t){this.isStopped?Pr(function ke(n){return at("N",n,void 0)}(t),this):this._next(t)}error(t){this.isStopped?Pr(function be(n){return at("E",void 0,n)}(t),this):(this.isStopped=!0,this._error(t))}complete(){this.isStopped?Pr(pe,this):(this.isStopped=!0,this._complete())}unsubscribe(){this.closed||(this.isStopped=!0,super.unsubscribe(),this.destination=null)}_next(t){this.destination.next(t)}_error(t){try{this.destination.error(t)}finally{this.unsubscribe()}}_complete(){try{this.destination.complete()}finally{this.unsubscribe()}}}const Di=Function.prototype.bind;function ni(n,t){return Di.call(n,t)}class mi{constructor(t){this.partialObserver=t}next(t){const{partialObserver:e}=this;if(e.next)try{e.next(t)}catch(i){ki(i)}}error(t){const{partialObserver:e}=this;if(e.error)try{e.error(t)}catch(i){ki(i)}else ki(t)}complete(){const{partialObserver:t}=this;if(t.complete)try{t.complete()}catch(e){ki(e)}}}class cr extends pt{constructor(t,e,i){let r;if(super(),Eo(t)||!t)r={next:t??void 0,error:e??void 0,complete:i??void 0};else{let s;this&&ql.useDeprecatedNextContext?(s=Object.create(t),s.unsubscribe=()=>this.unsubscribe(),r={next:t.next&&ni(t.next,s),error:t.error&&ni(t.error,s),complete:t.complete&&ni(t.complete,s)}):r=t}this.destination=new mi(r)}}function ki(n){ql.useDeprecatedSynchronousErrorHandling?function Lt(n){ql.useDeprecatedSynchronousErrorHandling&&tt&&(tt.errorThrown=!0,tt.error=n)}(n):function se(n){Z.setTimeout(()=>{const{onUnhandledError:t}=ql;if(!t)throw n;t(n)})}(n)}function Pr(n,t){const{onStoppedNotification:e}=ql;e&&Z.setTimeout(()=>e(n,t))}const Wt={closed:!0,next:ye,error:function is(n){throw n},complete:ye},ct="function"==typeof Symbol&&Symbol.observable||"@@observable";function jn(n){return n}let Pi=(()=>{class n{constructor(e){e&&(this._subscribe=e)}lift(e){const i=new n;return i.source=this,i.operator=e,i}subscribe(e,i,r){const s=function et(n){return n&&n instanceof pt||function dr(n){return n&&Eo(n.next)&&Eo(n.error)&&Eo(n.complete)}(n)&&Em(n)}(e)?e:new cr(e,i,r);return At(()=>{const{operator:o,source:a}=this;s.add(o?o.call(s,a):a?this._subscribe(s):this._trySubscribe(s))}),s}_trySubscribe(e){try{return this._subscribe(e)}catch(i){e.error(i)}}forEach(e,i){return new(i=lt(i))((r,s)=>{const o=new cr({next:a=>{try{e(a)}catch(l){s(l),o.unsubscribe()}},error:s,complete:r});this.subscribe(o)})}_subscribe(e){var i;return null===(i=this.source)||void 0===i?void 0:i.subscribe(e)}[ct](){return this}pipe(...e){return function Zr(n){return 0===n.length?jn:1===n.length?n[0]:function(e){return n.reduce((i,r)=>r(i),e)}}(e)(this)}toPromise(e){return new(e=lt(e))((i,r)=>{let s;this.subscribe(o=>s=o,o=>r(o),()=>i(s))})}}return n.create=t=>new n(t),n})();function lt(n){var t;return null!==(t=n??ql.Promise)&&void 0!==t?t:Promise}const yi=Zd(n=>function(){n(this),this.name="ObjectUnsubscribedError",this.message="object unsubscribed"});let Pt=(()=>{class n extends Pi{constructor(){super(),this.closed=!1,this.currentObservers=null,this.observers=[],this.isStopped=!1,this.hasError=!1,this.thrownError=null}lift(e){const i=new rs(this,this);return i.operator=e,i}_throwIfClosed(){if(this.closed)throw new yi}next(e){At(()=>{if(this._throwIfClosed(),!this.isStopped){this.currentObservers||(this.currentObservers=Array.from(this.observers));for(const i of this.currentObservers)i.next(e)}})}error(e){At(()=>{if(this._throwIfClosed(),!this.isStopped){this.hasError=this.isStopped=!0,this.thrownError=e;const{observers:i}=this;for(;i.length;)i.shift().error(e)}})}complete(){At(()=>{if(this._throwIfClosed(),!this.isStopped){this.isStopped=!0;const{observers:e}=this;for(;e.length;)e.shift().complete()}})}unsubscribe(){this.isStopped=this.closed=!0,this.observers=this.currentObservers=null}get observed(){var e;return(null===(e=this.observers)||void 0===e?void 0:e.length)>0}_trySubscribe(e){return this._throwIfClosed(),super._trySubscribe(e)}_subscribe(e){return this._throwIfClosed(),this._checkFinalizedStatuses(e),this._innerSubscribe(e)}_innerSubscribe(e){const{hasError:i,isStopped:r,observers:s}=this;return i||r?Xl:(this.currentObservers=null,s.push(e),new As(()=>{this.currentObservers=null,gp(s,e)}))}_checkFinalizedStatuses(e){const{hasError:i,thrownError:r,isStopped:s}=this;i?e.error(r):s&&e.complete()}asObservable(){const e=new Pi;return e.source=this,e}}return n.create=(t,e)=>new rs(t,e),n})();class rs extends Pt{constructor(t,e){super(),this.destination=t,this.source=e}next(t){var e,i;null===(i=null===(e=this.destination)||void 0===e?void 0:e.next)||void 0===i||i.call(e,t)}error(t){var e,i;null===(i=null===(e=this.destination)||void 0===e?void 0:e.error)||void 0===i||i.call(e,t)}complete(){var t,e;null===(e=null===(t=this.destination)||void 0===t?void 0:t.complete)||void 0===e||e.call(t)}_subscribe(t){var e,i;return null!==(i=null===(e=this.source)||void 0===e?void 0:e.subscribe(t))&&void 0!==i?i:Xl}}class _o extends Pt{constructor(t){super(),this._value=t}get value(){return this.getValue()}_subscribe(t){const e=super._subscribe(t);return!e.closed&&t.next(this._value),e}getValue(){const{hasError:t,thrownError:e,_value:i}=this;if(t)throw e;return this._throwIfClosed(),i}next(t){super.next(this._value=t)}}class Ls extends pt{constructor(t,e,i,r,s,o){super(t),this.onFinalize=s,this.shouldUnsubscribe=o,this._next=e?function(a){try{e(a)}catch(l){t.error(l)}}:super._next,this._error=r?function(a){try{r(a)}catch(l){t.error(l)}finally{this.unsubscribe()}}:super._error,this._complete=i?function(){try{i()}catch(a){t.error(a)}finally{this.unsubscribe()}}:super._complete}unsubscribe(){var t;if(!this.shouldUnsubscribe||this.shouldUnsubscribe()){const{closed:e}=this;super.unsubscribe(),!e&&(null===(t=this.onFinalize)||void 0===t||t.call(this))}}}function jr(n,t){return function Ur(n){return t=>{if(function cn(n){return Eo(n?.lift)}(t))return t.lift(function(e){try{return n(e,this)}catch(i){this.error(i)}});throw new TypeError("Unable to lift unknown Observable type")}}((e,i)=>{let r=0;e.subscribe(function Do(n,t,e,i,r){return new Ls(n,t,e,i,r)}(i,s=>{i.next(n.call(t,s,r++))}))})}class F extends Error{constructor(t,e){super(function ae(n,t){return`NG0${Math.abs(n)}${t?": "+t:""}`}(t,e)),this.code=t}}function Xe(n){for(let t in n)if(n[t]===Xe)return t;throw Error("Could not find renamed property on target object.")}function mt(n,t){for(const e in t)t.hasOwnProperty(e)&&!n.hasOwnProperty(e)&&(n[e]=t[e])}function dt(n){if("string"==typeof n)return n;if(Array.isArray(n))return"["+n.map(dt).join(", ")+"]";if(null==n)return""+n;if(n.overriddenName)return`${n.overriddenName}`;if(n.name)return`${n.name}`;const t=n.toString();if(null==t)return""+t;const e=t.indexOf("\n");return-1===e?t:t.substring(0,e)}function qt(n,t){return null==n||""===n?null===t?"":t:null==t||""===t?n:n+" "+t}const ur=Xe({__forward_ref__:Xe});function ir(n){return n.__forward_ref__=ir,n.toString=function(){return dt(this())},n}function vt(n){return function Tn(n){return"function"==typeof n&&n.hasOwnProperty(ur)&&n.__forward_ref__===ir}(n)?n():n}function $l(n){return n&&!!n.\u0275providers}const Zl=Xe({\u0275cmp:Xe}),Jd=Xe({\u0275dir:Xe}),vp=Xe({\u0275pipe:Xe}),Uo=Xe({\u0275fac:Xe}),jo=Xe({__NG_ELEMENT_ID__:Xe}),mp=Xe({__NG_ENV_ID__:Xe});function Ri(n){return"function"==typeof n?n.name||n.toString():"object"==typeof n&&null!=n&&"function"==typeof n.type?n.type.name||n.type.toString():function Nt(n){return"string"==typeof n?n:null==n?"":String(n)}(n)}function Lb(n,t){throw new F(-201,!1)}function so(n,t){null==n&&function zt(n,t,e,i){throw new Error(`ASSERTION ERROR: ${n}`+(null==i?"":` [Expected=> ${e} ${i} ${t} <=Actual]`))}(t,n,null,"!=")}function Yi(n){return{token:n.token,providedIn:n.providedIn||null,factory:n.factory,value:void 0}}function yp(n){return{providers:n.providers||[],imports:n.imports||[]}}function xm(n){return zT(n,Am)||zT(n,RT)}function zT(n,t){return n.hasOwnProperty(t)?n[t]:null}function Tm(n){return n&&(n.hasOwnProperty(Nb)||n.hasOwnProperty(x_))?n[Nb]:null}const Am=Xe({\u0275prov:Xe}),Nb=Xe({\u0275inj:Xe}),RT=Xe({ngInjectableDef:Xe}),x_=Xe({ngInjectorDef:Xe});var xi=function(n){return n[n.Default=0]="Default",n[n.Host=1]="Host",n[n.Self=2]="Self",n[n.SkipSelf=4]="SkipSelf",n[n.Optional=8]="Optional",n}(xi||{});let Ob;function oo(n){const t=Ob;return Ob=n,t}function BT(n,t,e){const i=xm(n);return i&&"root"==i.providedIn?void 0===i.value?i.value=i.factory():i.value:e&xi.Optional?null:void 0!==t?t:void Lb()}const rr=globalThis;class Ht{constructor(t,e){this._desc=t,this.ngMetadataName="InjectionToken",this.\u0275prov=void 0,"number"==typeof e?this.__NG_ELEMENT_ID__=e:void 0!==e&&(this.\u0275prov=Yi({token:this,providedIn:e.providedIn||"root",factory:e.factory}))}get multi(){return this}toString(){return`InjectionToken ${this._desc}`}}const Sp={},Hb="__NG_DI_FLAG__",Lm="ngTempTokenPath",L_=/\n/gm,_T="__source";let eu;function Gh(n){const t=eu;return eu=n,t}function k_(n,t=xi.Default){if(void 0===eu)throw new F(-203,!1);return null===eu?BT(n,void 0,t):eu.get(n,t&xi.Optional?null:void 0,t)}function _i(n,t=xi.Default){return(function HT(){return Ob}()||k_)(vt(n),t)}function Hi(n,t=xi.Default){return _i(n,Nm(t))}function Nm(n){return typeof n>"u"||"number"==typeof n?n:0|(n.optional&&8)|(n.host&&1)|(n.self&&2)|(n.skipSelf&&4)}function Bb(n){const t=[];for(let e=0;et){o=s-1;break}}}for(;ss?"":r[d+1].toLowerCase();const f=8&i?u:null;if(f&&-1!==jT(f,h,0)||2&i&&h!==u){if(Ma(i))return!1;o=!0}}}}else{if(!o&&!Ma(i)&&!Ma(l))return!1;if(o&&Ma(l))continue;o=!1,i=l|1&i}}return Ma(i)||o}function Ma(n){return 0==(1&n)}function __(n,t,e,i){if(null===t)return-1;let r=0;if(i||!e){let s=!1;for(;r-1)for(e++;e0?'="'+a+'"':"")+"]"}else 8&i?r+="."+o:4&i&&(r+=" "+o);else""!==r&&!Ma(o)&&(t+=qT(s,r),r=""),i=o,s=s||!Ma(i);e++}return""!==r&&(t+=qT(s,r)),t}function _b(n){return Jl(()=>{const t=ZT(n),e={...t,decls:n.decls,vars:n.vars,template:n.template,consts:n.consts||null,ngContentSelectors:n.ngContentSelectors,onPush:n.changeDetection===Om.OnPush,directiveDefs:null,pipeDefs:null,dependencies:t.standalone&&n.dependencies||null,getStandaloneInjector:null,signals:n.signals??!1,data:n.data||{},encapsulation:n.encapsulation||ba.Emulated,styles:n.styles||Qi,_:null,schemas:n.schemas||null,tView:null,id:""};JT(e);const i=n.dependencies;return e.directiveDefs=Pm(i,!1),e.pipeDefs=Pm(i,!0),e.id=function Z_(n){let t=0;const e=[n.selectors,n.ngContentSelectors,n.hostVars,n.hostAttrs,n.consts,n.vars,n.decls,n.encapsulation,n.standalone,n.signals,n.exportAs,JSON.stringify(n.inputs),JSON.stringify(n.outputs),Object.getOwnPropertyNames(n.type.prototype),!!n.contentQueries,!!n.viewQuery].join("|");for(const r of e)t=Math.imul(31,t)+r.charCodeAt(0)<<0;return t+=2147483648,"c"+t}(e),e})}function X_(n){return di(n)||Wn(n)}function q_(n){return null!==n}function km(n){return Jl(()=>({type:n.type,bootstrap:n.bootstrap||Qi,declarations:n.declarations||Qi,imports:n.imports||Qi,exports:n.exports||Qi,transitiveCompileScopes:null,schemas:n.schemas||null,id:n.id||null}))}function $T(n,t){if(null==n)return rl;const e={};for(const i in n)if(n.hasOwnProperty(i)){const r=n[i];let s,o,a=Xh.None;Array.isArray(r)?(a=r[0],s=r[1],o=r[2]??s):(s=r,o=r),t?(e[s]=a!==Xh.None?[i,a]:i,t[s]=o):e[s]=i}return e}function nr(n){return Jl(()=>{const t=ZT(n);return JT(t),t})}function di(n){return n[Zl]||null}function Wn(n){return n[Jd]||null}function gs(n){return n[vp]||null}function ZT(n){const t={};return{type:n.type,providersResolver:null,factory:null,hostBindings:n.hostBindings||null,hostVars:n.hostVars||0,hostAttrs:n.hostAttrs||null,contentQueries:n.contentQueries||null,declaredInputs:t,inputTransforms:null,inputConfig:n.inputs||rl,exportAs:n.exportAs||null,standalone:!0===n.standalone,signals:!0===n.signals,selectors:n.selectors||Qi,viewQuery:n.viewQuery||null,features:n.features||null,setInput:null,findHostDirectiveDefs:null,hostDirectives:null,inputs:$T(n.inputs,t),outputs:$T(n.outputs),debugInfo:null}}function JT(n){n.features?.forEach(t=>t(n))}function Pm(n,t){if(!n)return null;const e=t?gs:X_;return()=>("function"==typeof n?n():n).map(i=>e(i)).filter(q_)}const Vr=0,Be=1,Ct=2,vn=3,wa=4,Os=5,Ca=6,tu=7,Er=8,Xs=9,Kl=10,Yt=11,Mp=12,KT=13,iu=14,Jr=15,wp=16,ru=17,nl=18,Cp=19,eA=20,qh=21,zm=22,Uc=23,jt=25,Ub=1,sl=7,nu=9,mn=10;var jb=function(n){return n[n.None=0]="None",n[n.HasTransplantedViews=2]="HasTransplantedViews",n}(jb||{});function ks(n){return Array.isArray(n)&&"object"==typeof n[Ub]}function Ps(n){return Array.isArray(n)&&!0===n[Ub]}function Vb(n){return 0!=(4&n.flags)}function jc(n){return n.componentOffset>-1}function Hm(n){return 1==(1&n.flags)}function Ea(n){return!!n.template}function Wb(n){return 0!=(512&n[Ct])}function Vc(n,t){return n.hasOwnProperty(Uo)?n[Uo]:null}class tU{constructor(t,e,i){this.previousValue=t,this.currentValue=e,this.firstChange=i}isFirstChange(){return this.firstChange}}function nA(n,t,e,i){null!==t?t.applyValueToInputSignal(t,i):n[e]=i}function sA(n){return n.type.prototype.ngOnChanges&&(n.setInput=rU),iU}function iU(){const n=aA(this),t=n?.current;if(t){const e=n.previous;if(e===rl)n.previous=t;else for(let i in t)e[i]=t[i];n.current=null,this.ngOnChanges(t)}}function rU(n,t,e,i,r){const s=this.declaredInputs[i],o=aA(n)||function nU(n,t){return n[oA]=t}(n,{previous:rl,current:null}),a=o.current||(o.current={}),l=o.previous,h=l[s];a[s]=new tU(h&&h.currentValue,e,l===rl),nA(n,t,r,e)}const oA="__ngSimpleChanges__";function aA(n){return n[oA]||null}const ol=function(n,t,e){};let cA=!1;function fr(n){for(;Array.isArray(n);)n=n[Vr];return n}function qs(n,t){return fr(t[n.index])}function xp(n,t){return n.data[t]}function To(n,t){const e=t[n];return ks(e)?e:e[Vr]}function qb(n){return 128==(128&n[Ct])}function al(n,t){return null==t?null:n[t]}function dA(n){n[ru]=0}function cU(n){1024&n[Ct]||(n[Ct]|=1024,qb(n)&&Tp(n))}function fA(n){return 9216&n[Ct]||n[Uc]?.dirty}function $b(n){fA(n)?Tp(n):64&n[Ct]&&(function oU(){return cA}()?(n[Ct]|=1024,Tp(n)):n[Kl].changeDetectionScheduler?.notify())}function Tp(n){n[Kl].changeDetectionScheduler?.notify();let t=Wc(n);for(;null!==t&&!(8192&t[Ct])&&(t[Ct]|=8192,qb(t));)t=Wc(t)}function Wc(n){const t=n[vn];return Ps(t)?t[vn]:t}const Rt={lFrame:wA(null),bindingsEnabled:!0,skipHydrationRootTNode:null};function gA(){return Rt.bindingsEnabled}function Se(){return Rt.lFrame.lView}function Ti(){return Rt.lFrame.tView}function pr(){let n=vA();for(;null!==n&&64===n.type;)n=n.parent;return n}function vA(){return Rt.lFrame.currentTNode}function ll(n,t){const e=Rt.lFrame;e.currentTNode=n,e.isParent=t}function Jb(){return Rt.lFrame.isParent}function wU(n,t){const e=Rt.lFrame;e.bindingIndex=e.bindingRootIndex=n,e1(t)}function e1(n){Rt.lFrame.currentDirectiveIndex=n}function IA(){return Rt.lFrame.currentQueryIndex}function i1(n){Rt.lFrame.currentQueryIndex=n}function EU(n){const t=n[Be];return 2===t.type?t.declTNode:1===t.type?n[Os]:null}function bA(n,t,e){if(e&xi.SkipSelf){let r=t,s=n;for(;!(r=r.parent,null!==r||e&xi.Host||(r=EU(s),null===r||(s=s[iu],10&r.type))););if(null===r)return!1;t=r,n=s}const i=Rt.lFrame=MA();return i.currentTNode=t,i.lView=n,!0}function r1(n){const t=MA(),e=n[Be];Rt.lFrame=t,t.currentTNode=e.firstChild,t.lView=n,t.tView=e,t.contextLView=n,t.bindingIndex=e.bindingStartIndex,t.inI18n=!1}function MA(){const n=Rt.lFrame,t=null===n?null:n.child;return null===t?wA(n):t}function wA(n){const t={currentTNode:null,isParent:!0,lView:null,tView:null,selectedIndex:-1,contextLView:null,elementDepthCount:0,currentNamespace:null,currentDirectiveIndex:-1,bindingRootIndex:-1,bindingIndex:-1,currentQueryIndex:0,parent:n,child:null,inI18n:!1};return null!==n&&(n.child=t),t}function CA(){const n=Rt.lFrame;return Rt.lFrame=n.parent,n.currentTNode=null,n.lView=null,n}const EA=CA;function n1(){const n=CA();n.isParent=!0,n.tView=null,n.selectedIndex=-1,n.contextLView=null,n.elementDepthCount=0,n.currentDirectiveIndex=-1,n.currentNamespace=null,n.bindingRootIndex=-1,n.bindingIndex=-1,n.currentQueryIndex=0}function zs(){return Rt.lFrame.selectedIndex}function Yc(n){Rt.lFrame.selectedIndex=n}let xA=!0;function _m(){return xA}function $h(n){xA=n}function Um(n,t){for(let e=t.directiveStart,i=t.directiveEnd;e=i)break}else t[l]<0&&(n[ru]+=65536),(a>14>16&&(3&n[Ct])===t&&(n[Ct]+=16384,AA(a,s)):AA(a,s)}const au=-1;class Lp{constructor(t,e,i){this.factory=t,this.resolving=!1,this.canSeeViewProviders=e,this.injectImpl=i}}function a1(n){return n!==au}function Np(n){return 32767&n}function Op(n,t){let e=function HU(n){return n>>16}(n),i=t;for(;e>0;)i=i[iu],e--;return i}let l1=!0;function Wm(n){const t=l1;return l1=n,t}const LA=255,NA=5;let BU=0;const cl={};function Ym(n,t){const e=OA(n,t);if(-1!==e)return e;const i=t[Be];i.firstCreatePass&&(n.injectorIndex=t.length,h1(i.data,n),h1(t,null),h1(i.blueprint,null));const r=Qm(n,t),s=n.injectorIndex;if(a1(r)){const o=Np(r),a=Op(r,t),l=a[Be].data;for(let h=0;h<8;h++)t[s+h]=a[o+h]|l[o+h]}return t[s+8]=r,s}function h1(n,t){n.push(0,0,0,0,0,0,0,0,t)}function OA(n,t){return-1===n.injectorIndex||n.parent&&n.parent.injectorIndex===n.injectorIndex||null===t[n.injectorIndex+8]?-1:n.injectorIndex}function Qm(n,t){if(n.parent&&-1!==n.parent.injectorIndex)return n.parent.injectorIndex;let e=0,i=null,r=t;for(;null!==r;){if(i=FA(r),null===i)return au;if(e++,r=r[iu],-1!==i.injectorIndex)return i.injectorIndex|e<<16}return au}function c1(n,t,e){!function FU(n,t,e){let i;"string"==typeof e?i=e.charCodeAt(0)||0:e.hasOwnProperty(jo)&&(i=e[jo]),null==i&&(i=e[jo]=BU++);const r=i&LA;t.data[n+(r>>NA)]|=1<=0?t&LA:VU:t}(e);if("function"==typeof s){if(!bA(t,n,i))return i&xi.Host?kA(r,0,i):PA(t,e,i,r);try{let o;if(o=s(i),null!=o||i&xi.Optional)return o;Lb()}finally{EA()}}else if("number"==typeof s){let o=null,a=OA(n,t),l=au,h=i&xi.Host?t[Jr][Os]:null;for((-1===a||i&xi.SkipSelf)&&(l=-1===a?Qm(n,t):t[a+8],l!==au&&BA(i,!1)?(o=t[Be],a=Np(l),t=Op(l,t)):a=-1);-1!==a;){const c=t[Be];if(HA(s,a,c.data)){const d=UU(a,t,e,o,i,h);if(d!==cl)return d}l=t[a+8],l!==au&&BA(i,t[Be].data[a+8]===h)&&HA(s,a,t)?(o=c,a=Np(l),t=Op(l,t)):a=-1}}return r}function UU(n,t,e,i,r,s){const o=t[Be],a=o.data[n+8],c=Gm(a,o,e,null==i?jc(a)&&l1:i!=o&&0!=(3&a.type),r&xi.Host&&s===a);return null!==c?Qc(t,o,c,a):cl}function Gm(n,t,e,i,r){const s=n.providerIndexes,o=t.data,a=1048575&s,l=n.directiveStart,c=s>>20,u=r?a+c:n.directiveEnd;for(let f=i?a:a+c;f=l&&p.type===e)return f}if(r){const f=o[l];if(f&&Ea(f)&&f.type===e)return l}return null}function Qc(n,t,e,i){let r=n[e];const s=t.data;if(function kU(n){return n instanceof Lp}(r)){const o=r;o.resolving&&function Vo(n,t){const e=t?`. Dependency path: ${t.join(" > ")} > ${n}`:"";throw new F(-200,`Circular dependency in DI detected for ${n}${e}`)}(Ri(s[e]));const a=Wm(o.canSeeViewProviders);o.resolving=!0;const h=o.injectImpl?oo(o.injectImpl):null;bA(n,i,xi.Default);try{r=n[e]=o.factory(void 0,s,n,i),t.firstCreatePass&&e>=i.directiveStart&&function NU(n,t,e){const{ngOnChanges:i,ngOnInit:r,ngDoCheck:s}=t.type.prototype;if(i){const o=sA(t);(e.preOrderHooks??=[]).push(n,o),(e.preOrderCheckHooks??=[]).push(n,o)}r&&(e.preOrderHooks??=[]).push(0-n,r),s&&((e.preOrderHooks??=[]).push(n,s),(e.preOrderCheckHooks??=[]).push(n,s))}(e,s[e],t)}finally{null!==h&&oo(h),Wm(a),o.resolving=!1,EA()}}return r}function HA(n,t,e){return!!(e[t+(n>>NA)]&1<Array.isArray(e)?gu(e,t):t(e))}function UA(n,t,e){t>=n.length?n.push(e):n.splice(t,0,e)}function Xm(n,t){return t>=n.length-1?n.pop():n.splice(t,1)[0]}const yu=new Ht(""),GA=new Ht("",-1),I1=new Ht("");class Jm{get(t,e=Sp){if(e===Sp){const i=new Error(`NullInjectorError: No provider for ${dt(t)}!`);throw i.name="NullInjectorError",i}return e}}function fj(...n){return{\u0275providers:XA(0,n),\u0275fromNgModule:!0}}function XA(n,...t){const e=[],i=new Set;let r;const s=o=>{e.push(o)};return gu(t,o=>{const a=o;Km(a,s,[],i)&&(r||=[],r.push(a))}),void 0!==r&&qA(r,s),e}function qA(n,t){for(let e=0;e{t(s,i)})}}function Km(n,t,e,i){if(!(n=vt(n)))return!1;let r=null,s=Tm(n);const o=!s&&di(n);if(s||o){if(o&&!o.standalone)return!1;r=n}else{const l=n.ngModule;if(s=Tm(l),!s)return!1;r=l}const a=i.has(r);if(o){if(a)return!1;if(i.add(r),o.dependencies){const l="function"==typeof o.dependencies?o.dependencies():o.dependencies;for(const h of l)Km(h,t,e,i)}}else{if(!s)return!1;{if(null!=s.imports&&!a){let h;i.add(r);try{gu(s.imports,c=>{Km(c,t,e,i)&&(h||=[],h.push(c))})}finally{}void 0!==h&&qA(h,t)}if(!a){const h=Vc(r)||(()=>new r);t({provide:r,useFactory:h,deps:Qi},r),t({provide:I1,useValue:r,multi:!0},r),t({provide:yu,useValue:()=>_i(r),multi:!0},r)}const l=s.providers;if(null!=l&&!a){const h=n;M1(l,c=>{t(c,h)})}}}return r!==n&&void 0!==n.providers}function M1(n,t){for(let e of n)$l(e)&&(e=e.\u0275providers),Array.isArray(e)?M1(e,t):t(e)}const pj=Xe({provide:String,useValue:Xe});function w1(n){return null!==n&&"object"==typeof n&&pj in n}function Gc(n){return"function"==typeof n}const C1=new Ht(""),ey={},vj={};let E1;function ty(){return void 0===E1&&(E1=new Jm),E1}class ih{}class Su extends ih{get destroyed(){return this._destroyed}constructor(t,e,i,r){super(),this.parent=e,this.source=i,this.scopes=r,this.records=new Map,this._ngOnDestroyHooks=new Set,this._onDestroyHooks=[],this._destroyed=!1,x1(t,o=>this.processProvider(o)),this.records.set(GA,Iu(void 0,this)),r.has("environment")&&this.records.set(ih,Iu(void 0,this));const s=this.records.get(C1);null!=s&&"string"==typeof s.value&&this.scopes.add(s.value),this.injectorDefTypes=new Set(this.get(I1,Qi,xi.Self))}destroy(){this.assertNotDestroyed(),this._destroyed=!0;try{for(const e of this._ngOnDestroyHooks)e.ngOnDestroy();const t=this._onDestroyHooks;this._onDestroyHooks=[];for(const e of t)e()}finally{this.records.clear(),this._ngOnDestroyHooks.clear(),this.injectorDefTypes.clear()}}onDestroy(t){return this.assertNotDestroyed(),this._onDestroyHooks.push(t),()=>this.removeOnDestroy(t)}runInContext(t){this.assertNotDestroyed();const e=Gh(this),i=oo(void 0);try{return t()}finally{Gh(e),oo(i)}}get(t,e=Sp,i=xi.Default){if(this.assertNotDestroyed(),t.hasOwnProperty(mp))return t[mp](this);i=Nm(i);const s=Gh(this),o=oo(void 0);try{if(!(i&xi.SkipSelf)){let l=this.records.get(t);if(void 0===l){const h=function bj(n){return"function"==typeof n||"object"==typeof n&&n instanceof Ht}(t)&&xm(t);l=h&&this.injectableDefInScope(h)?Iu(D1(t),ey):null,this.records.set(t,l)}if(null!=l)return this.hydrate(t,l)}return(i&xi.Self?ty():this.parent).get(t,e=i&xi.Optional&&e===Sp?null:e)}catch(a){if("NullInjectorError"===a.name){if((a[Lm]=a[Lm]||[]).unshift(dt(t)),s)throw a;return function z_(n,t,e,i){const r=n[Lm];throw t[_T]&&r.unshift(t[_T]),n.message=function R_(n,t,e,i=null){n=n&&"\n"===n.charAt(0)&&"\u0275"==n.charAt(1)?n.slice(2):n;let r=dt(t);if(Array.isArray(t))r=t.map(dt).join(" -> ");else if("object"==typeof t){let s=[];for(let o in t)if(t.hasOwnProperty(o)){let a=t[o];s.push(o+":"+("string"==typeof a?JSON.stringify(a):dt(a)))}r=`{${s.join(", ")}}`}return`${e}${i?"("+i+")":""}[${r}]: ${n.replace(L_,"\n ")}`}("\n"+n.message,r,e,i),n.ngTokenPath=r,n[Lm]=null,n}(a,t,"R3InjectorError",this.source)}throw a}finally{oo(o),Gh(s)}}resolveInjectorInitializers(){const t=Gh(this),e=oo(void 0);try{const r=this.get(yu,Qi,xi.Self);for(const s of r)s()}finally{Gh(t),oo(e)}}toString(){const t=[],e=this.records;for(const i of e.keys())t.push(dt(i));return`R3Injector[${t.join(", ")}]`}assertNotDestroyed(){if(this._destroyed)throw new F(205,!1)}processProvider(t){let e=Gc(t=vt(t))?t:vt(t&&t.provide);const i=function yj(n){return w1(n)?Iu(void 0,n.useValue):Iu(JA(n),ey)}(t);if(!Gc(t)&&!0===t.multi){let r=this.records.get(e);r||(r=Iu(void 0,ey,!0),r.factory=()=>Bb(r.multi),this.records.set(e,r)),e=t,r.multi.push(t)}this.records.set(e,i)}hydrate(t,e){return e.value===ey&&(e.value=vj,e.value=e.factory()),"object"==typeof e.value&&e.value&&function Ij(n){return null!==n&&"object"==typeof n&&"function"==typeof n.ngOnDestroy}(e.value)&&this._ngOnDestroyHooks.add(e.value),e.value}injectableDefInScope(t){if(!t.providedIn)return!1;const e=vt(t.providedIn);return"string"==typeof e?"any"===e||this.scopes.has(e):this.injectorDefTypes.has(e)}removeOnDestroy(t){const e=this._onDestroyHooks.indexOf(t);-1!==e&&this._onDestroyHooks.splice(e,1)}}function D1(n){const t=xm(n),e=null!==t?t.factory:Vc(n);if(null!==e)return e;if(n instanceof Ht)throw new F(204,!1);if(n instanceof Function)return function mj(n){if(n.length>0)throw new F(204,!1);const e=function D_(n){return n&&(n[Am]||n[RT])||null}(n);return null!==e?()=>e.factory(n):()=>new n}(n);throw new F(204,!1)}function JA(n,t,e){let i;if(Gc(n)){const r=vt(n);return Vc(r)||D1(r)}if(w1(n))i=()=>vt(n.useValue);else if(function ZA(n){return!(!n||!n.useFactory)}(n))i=()=>n.useFactory(...Bb(n.deps||[]));else if(function $A(n){return!(!n||!n.useExisting)}(n))i=()=>_i(vt(n.useExisting));else{const r=vt(n&&(n.useClass||n.provide));if(!function Sj(n){return!!n.deps}(n))return Vc(r)||D1(r);i=()=>new r(...Bb(n.deps))}return i}function Iu(n,t,e=!1){return{factory:n,value:t,multi:e?[]:void 0}}function x1(n,t){for(const e of n)Array.isArray(e)?x1(e,t):e&&$l(e)?x1(e.\u0275providers,t):t(e)}function iL(n,t=null,e=null,i){const r=function rL(n,t=null,e=null,i,r=new Set){const s=[e||Qi,fj(n)];return i=i||("object"==typeof n?void 0:dt(n)),new Su(s,t||ty(),i||null,r)}(n,t,e,i);return r.resolveInjectorInitializers(),r}let L1,Wo=(()=>{class n{static{this.THROW_IF_NOT_FOUND=Sp}static{this.NULL=new Jm}static create(e,i){if(Array.isArray(e))return iL({name:""},i,e,"");{const r=e.name??"";return iL({name:r},e.parent,e.providers,r)}}static{this.\u0275prov=Yi({token:n,providedIn:"any",factory:()=>_i(GA)})}static{this.__NG_ELEMENT_ID__=-1}}return n})();const N1=new Ht("",{providedIn:"root",factory:()=>Lj}),Lj="ng",sL=new Ht(""),bu=new Ht("",{providedIn:"platform",factory:()=>"unknown"}),oL=new Ht("",{providedIn:"root",factory:()=>function Zh(){if(void 0!==L1)return L1;if(typeof document<"u")return document;throw new F(210,!1)}().body?.querySelector("[ngCspNonce]")?.getAttribute("ngCspNonce")||null});function oy(n){return 128==(128&n.flags)}var ec=function(n){return n[n.Important=1]="Important",n[n.DashCase=2]="DashCase",n}(ec||{});const R1=new Map;let Vj=0;const B1="__ngContext__";function Rs(n,t){ks(t)?(n[B1]=t[Cp],function Yj(n){R1.set(n[Cp],n)}(t)):n[B1]=t}let F1;function _1(n,t){return F1(n,t)}function wu(n,t,e,i,r){if(null!=i){let s,o=!1;Ps(i)?s=i:ks(i)&&(o=!0,i=i[Vr]);const a=fr(i);0===n&&null!==e?null==r?TL(t,e,a):qc(t,e,a,r||null,!0):1===n&&null!==e?qc(t,e,a,r||null,!0):2===n?function fy(n,t,e){const i=dy(n,t);i&&function a6(n,t,e,i){n.removeChild(t,e,i)}(n,i,t,e)}(t,a,o):3===n&&t.destroyNode(a),null!=s&&function c6(n,t,e,i,r){const s=e[sl];s!==fr(e)&&wu(t,n,i,s,r);for(let a=mn;a0&&(n[e-1][wa]=i[wa]);const s=Xm(n,mn+t);!function e6(n,t){EL(n,t),t[Vr]=null,t[Os]=null}(i[Be],i);const o=s[nl];null!==o&&o.detachView(s[Be]),i[vn]=null,i[wa]=null,i[Ct]&=-129}return i}function cy(n,t){if(!(256&t[Ct])){const e=t[Yt];e.destroyNode&&py(n,t,e,3,null,null),function i6(n){let t=n[Mp];if(!t)return j1(n[Be],n);for(;t;){let e=null;if(ks(t))e=t[Mp];else{const i=t[mn];i&&(e=i)}if(!e){for(;t&&!t[wa]&&t!==n;)ks(t)&&j1(t[Be],t),t=t[vn];null===t&&(t=n),ks(t)&&j1(t[Be],t),e=t&&t[wa]}t=e}}(t)}}function j1(n,t){if(!(256&t[Ct])){t[Ct]&=-129,t[Ct]|=256,t[Uc]&&function Xd(n){if(Gl(n),Wh(n))for(let t=0;t=0?i[o]():i[-o].unsubscribe(),s+=2}else e[s].call(i[e[s+1]]);null!==i&&(t[tu]=null);const r=t[qh];if(null!==r){t[qh]=null;for(let s=0;s-1){const{encapsulation:s}=n.data[i.directiveStart+r];if(s===ba.None||s===ba.Emulated)return null}return qs(i,e)}}(n,t.parent,e)}function qc(n,t,e,i,r){n.insertBefore(t,e,i,r)}function TL(n,t,e){n.appendChild(t,e)}function AL(n,t,e,i,r){null!==i?qc(n,t,e,i,r):TL(n,t,e)}function dy(n,t){return n.parentNode(t)}let W1,OL=function NL(n,t,e){return 40&n.type?qs(n,e):null};function uy(n,t,e,i){const r=V1(n,i,t),s=t[Yt],a=function LL(n,t,e){return OL(n,t,e)}(i.parent||t[Os],i,t);if(null!=r)if(Array.isArray(e))for(let l=0;lnull;function oM(n,t,e=!1){return JL(n,t,e)}class G6{}class rN{}class q6{resolveComponentFactory(t){throw function X6(n){const t=Error(`No component factory found for ${dt(n)}.`);return t.ngComponent=n,t}(t)}}let wy=(()=>{class n{static{this.NULL=new q6}}return n})();function $6(){return Au(pr(),Se())}function Au(n,t){return new $c(qs(n,t))}let $c=(()=>{class n{constructor(e){this.nativeElement=e}static{this.__NG_ELEMENT_ID__=$6}}return n})();function Z6(n){return n instanceof $c?n.nativeElement:n}class sN{}let cM=(()=>{class n{constructor(){this.destroyNode=null}static{this.__NG_ELEMENT_ID__=()=>function J6(){const n=Se(),e=To(pr().index,n);return(ks(e)?e:n)[Yt]}()}}return n})(),K6=(()=>{class n{static{this.\u0275prov=Yi({token:n,providedIn:"root",factory:()=>null})}}return n})();const dM={};function Gp(n,t,e,i,r=!1){for(;null!==e;){const s=t[e.index];null!==s&&i.push(fr(s)),Ps(s)&&fN(s,i);const o=e.type;if(8&o)Gp(n,t,e.child,i);else if(32&o){const a=_1(e,t);let l;for(;l=a();)i.push(l)}else if(16&o){const a=PL(t,e);if(Array.isArray(a))i.push(...a);else{const l=Wc(t[Jr]);Gp(l[Be],l,a,i,!0)}}e=r?e.projectionNext:e.next}return i}function fN(n,t){for(let e=mn;e!1,producerRecomputeValue:()=>{},consumerMarkedDirty:()=>{},consumerOnSignalRead:()=>{},consumerIsAlwaysLive:!0,consumerMarkedDirty:n=>{Tp(n.lView)},consumerOnSignalRead(){this.lView[Uc]=this}};function gN(n){return mN(n[Mp])}function vN(n){return mN(n[wa])}function mN(n){for(;null!==n&&!Ps(n);)n=n[wa];return n}function pM(n){return n.ngOriginalError}class nh{constructor(){this._console=console}handleError(t){const e=this._findOriginalError(t);this._console.error("ERROR",t),e&&this._console.error("ORIGINAL ERROR",e)}_findOriginalError(t){let e=t&&pM(t);for(;e&&pM(e);)e=pM(e);return e||null}}const SN=new Ht("",{providedIn:"root",factory:()=>Hi(nh).handleError.bind(void 0)}),bN=new Ht("",{providedIn:"root",factory:()=>!1}),Qt={};function Xp(n=1){EN(Ti(),Se(),zs()+n,!1)}function EN(n,t,e,i){if(!i)if(3==(3&t[Ct])){const s=n.preOrderCheckHooks;null!==s&&jm(t,s,e)}else{const s=n.preOrderHooks;null!==s&&Vm(t,s,0,e)}Yc(e)}function Ot(n,t=xi.Default){const e=Se();return null===e?_i(n,t):zA(pr(),e,vt(n),t)}function DN(n,t,e,i,r,s){const o=Wi(null);try{let a=null;r&Xh.SignalBased&&(a=t[i][Ts]),null!==a&&void 0!==a.transformFn&&(s=a.transformFn(s)),r&Xh.HasDecoratorInputTransform&&(s=n.inputTransforms[i].call(t,s)),null!==n.setInput?n.setInput(t,a,s,e,i):nA(t,a,i,s)}finally{Wi(o)}}function xy(n,t,e,i,r,s,o,a,l,h,c){const d=t.blueprint.slice();return d[Vr]=r,d[Ct]=204|i,(null!==h||n&&2048&n[Ct])&&(d[Ct]|=2048),dA(d),d[vn]=d[iu]=n,d[Er]=e,d[Kl]=o||n&&n[Kl],d[Yt]=a||n&&n[Yt],d[Xs]=l||n&&n[Xs]||null,d[Os]=s,d[Cp]=function Wj(){return Vj++}(),d[Ca]=c,d[eA]=h,d[Jr]=2==t.type?n[Jr]:d,d}function Lu(n,t,e,i,r){let s=n.data[t];if(null===s)s=function gM(n,t,e,i,r){const s=vA(),o=Jb(),l=n.data[t]=function LV(n,t,e,i,r,s){let o=t?t.injectorIndex:-1,a=0;return function ou(){return null!==Rt.skipHydrationRootTNode}()&&(a|=128),{type:e,index:i,insertBeforeIndex:null,injectorIndex:o,directiveStart:-1,directiveEnd:-1,directiveStylingLast:-1,componentOffset:-1,propertyBindings:null,flags:a,providerIndexes:0,value:r,attrs:s,mergedAttrs:null,localNames:null,initialInputs:void 0,inputs:null,outputs:null,tView:null,next:null,prev:null,projectionNext:null,child:null,parent:t,projection:null,styles:null,stylesWithoutHost:null,residualStyles:void 0,classes:null,classesWithoutHost:null,residualClasses:void 0,classBindings:0,styleBindings:0}}(0,o?s:s&&s.parent,e,t,i,r);return null===n.firstChild&&(n.firstChild=l),null!==s&&(o?null==s.child&&null!==l.parent&&(s.child=l):null===s.next&&(s.next=l,l.prev=s)),l}(n,t,e,i,r),function MU(){return Rt.lFrame.inI18n}()&&(s.flags|=32);else if(64&s.type){s.type=e,s.value=i,s.attrs=r;const o=function Ap(){const n=Rt.lFrame,t=n.currentTNode;return n.isParent?t:t.parent}();s.injectorIndex=null===o?-1:o.injectorIndex}return ll(s,!0),s}function qp(n,t,e,i){if(0===e)return-1;const r=t.length;for(let s=0;sjt&&EN(n,t,jt,!1),ol(o?2:0,r),e(i,r)}finally{Yc(s),ol(o?3:1,r)}}function vM(n,t,e){if(Vb(t)){const i=Wi(null);try{const s=t.directiveEnd;for(let o=t.directiveStart;onull;function LN(n,t,e,i,r){for(let s in t){if(!t.hasOwnProperty(s))continue;const o=t[s];if(void 0===o)continue;i??={};let a,l=Xh.None;Array.isArray(o)?(a=o[0],l=o[1]):a=o;let h=s;if(null!==r){if(!r.hasOwnProperty(s))continue;h=r[s]}0===n?NN(i,e,h,a,l):NN(i,e,h,a)}return i}function NN(n,t,e,i,r){let s;n.hasOwnProperty(e)?(s=n[e]).push(t,i):s=n[e]=[t,i],void 0!==r&&s.push(r)}function ON(n,t,e,i,r,s){for(let h=0;h0;){const e=n[--t];if("number"==typeof e&&e<0)return e}return 0})(o)!=a&&o.push(a),o.push(e,i,s)}}(n,t,i,qp(n,e,r.hostVars,Qt),r)}function YV(n,t,e,i,r,s){const o=s[t];if(null!==o)for(let a=0;an.nextProducerIndex;)n.producerNode.pop(),n.producerLastReadVersion.pop(),n.producerIndexOfThis.pop()}}(a,o),function fV(n){n.lView[Uc]!==n&&(n.lView=null,pN.push(n))}(a)),n1()}}function FN(n,t){for(let e=gN(n);null!==e;e=vN(e))for(let i=mn;i-1&&(Fp(t,i),Xm(e,i))}this._attachedToViewContainer=!1}cy(this._lView[Be],this._lView)}onDestroy(t){!function Fm(n,t){if(256==(256&n[Ct]))throw new F(911,!1);null===n[qh]&&(n[qh]=[]),n[qh].push(t)}(this._lView,t)}markForCheck(){$p(this._cdRefInjectingView||this._lView)}detach(){this._lView[Ct]&=-129}reattach(){$b(this._lView),this._lView[Ct]|=128}detectChanges(){this._lView[Ct]|=1024,function EM(n,t=!0){const e=n[Kl],i=e.rendererFactory;i.begin?.();try{!function XV(n){DM(n,0);let t=0;for(;fA(n);){if(100===t)throw new F(103,!1);t++,DM(n,1)}}(n)}catch(s){throw t&&Ay(n,s),s}finally{i.end?.(),e.inlineEffectRunner?.flush()}}(this._lView,this.notifyErrorHandler)}checkNoChanges(){}attachToViewContainerRef(){if(this._appRef)throw new F(902,!1);this._attachedToViewContainer=!0}detachFromAppRef(){this._appRef=null,EL(this._lView[Be],this._lView)}attachToAppRef(t){if(this._attachedToViewContainer)throw new F(902,!1);this._appRef=t,$b(this._lView)}}const VN=new Set;function TM(n){return t=>{setTimeout(n,void 0,t)}}const Yo=class h7 extends Pt{constructor(t=!1){super(),this.__isAsync=t}emit(t){super.next(t)}subscribe(t,e,i){let r=t,s=e||(()=>null),o=i;if(t&&"object"==typeof t){const l=t;r=l.next?.bind(l),s=l.error?.bind(l),o=l.complete?.bind(l)}this.__isAsync&&(s=TM(s),r&&(r=TM(r)),o&&(o=TM(o)));const a=super.subscribe({next:r,error:s,complete:o});return t instanceof As&&t.add(a),a}};function WN(...n){}class Rr{constructor({enableLongStackTrace:t=!1,shouldCoalesceEventChangeDetection:e=!1,shouldCoalesceRunChangeDetection:i=!1}){if(this.hasPendingMacrotasks=!1,this.hasPendingMicrotasks=!1,this.isStable=!0,this.onUnstable=new Yo(!1),this.onMicrotaskEmpty=new Yo(!1),this.onStable=new Yo(!1),this.onError=new Yo(!1),typeof Zone>"u")throw new F(908,!1);Zone.assertZonePatched();const r=this;r._nesting=0,r._outer=r._inner=Zone.current,Zone.TaskTrackingZoneSpec&&(r._inner=r._inner.fork(new Zone.TaskTrackingZoneSpec)),t&&Zone.longStackTraceZoneSpec&&(r._inner=r._inner.fork(Zone.longStackTraceZoneSpec)),r.shouldCoalesceEventChangeDetection=!i&&e,r.shouldCoalesceRunChangeDetection=i,r.lastRequestAnimationFrameId=-1,r.nativeRequestAnimationFrame=function c7(){const n="function"==typeof rr.requestAnimationFrame;let t=rr[n?"requestAnimationFrame":"setTimeout"],e=rr[n?"cancelAnimationFrame":"clearTimeout"];if(typeof Zone<"u"&&t&&e){const i=t[Zone.__symbol__("OriginalDelegate")];i&&(t=i);const r=e[Zone.__symbol__("OriginalDelegate")];r&&(e=r)}return{nativeRequestAnimationFrame:t,nativeCancelAnimationFrame:e}}().nativeRequestAnimationFrame,function f7(n){const t=()=>{!function u7(n){n.isCheckStableRunning||-1!==n.lastRequestAnimationFrameId||(n.lastRequestAnimationFrameId=n.nativeRequestAnimationFrame.call(rr,()=>{n.fakeTopEventTask||(n.fakeTopEventTask=Zone.root.scheduleEventTask("fakeTopEventTask",()=>{n.lastRequestAnimationFrameId=-1,LM(n),n.isCheckStableRunning=!0,AM(n),n.isCheckStableRunning=!1},void 0,()=>{},()=>{})),n.fakeTopEventTask.invoke()}),LM(n))}(n)};n._inner=n._inner.fork({name:"angular",properties:{isAngularZone:!0},onInvokeTask:(e,i,r,s,o,a)=>{if(function p7(n){return!(!Array.isArray(n)||1!==n.length)&&!0===n[0].data?.__ignore_ng_zone__}(a))return e.invokeTask(r,s,o,a);try{return YN(n),e.invokeTask(r,s,o,a)}finally{(n.shouldCoalesceEventChangeDetection&&"eventTask"===s.type||n.shouldCoalesceRunChangeDetection)&&t(),QN(n)}},onInvoke:(e,i,r,s,o,a,l)=>{try{return YN(n),e.invoke(r,s,o,a,l)}finally{n.shouldCoalesceRunChangeDetection&&t(),QN(n)}},onHasTask:(e,i,r,s)=>{e.hasTask(r,s),i===r&&("microTask"==s.change?(n._hasPendingMicrotasks=s.microTask,LM(n),AM(n)):"macroTask"==s.change&&(n.hasPendingMacrotasks=s.macroTask))},onHandleError:(e,i,r,s)=>(e.handleError(r,s),n.runOutsideAngular(()=>n.onError.emit(s)),!1)})}(r)}static isInAngularZone(){return typeof Zone<"u"&&!0===Zone.current.get("isAngularZone")}static assertInAngularZone(){if(!Rr.isInAngularZone())throw new F(909,!1)}static assertNotInAngularZone(){if(Rr.isInAngularZone())throw new F(909,!1)}run(t,e,i){return this._inner.run(t,e,i)}runTask(t,e,i,r){const s=this._inner,o=s.scheduleEventTask("NgZoneEvent: "+r,t,d7,WN,WN);try{return s.runTask(o,e,i)}finally{s.cancelTask(o)}}runGuarded(t,e,i){return this._inner.runGuarded(t,e,i)}runOutsideAngular(t){return this._outer.run(t)}}const d7={};function AM(n){if(0==n._nesting&&!n.hasPendingMicrotasks&&!n.isStable)try{n._nesting++,n.onMicrotaskEmpty.emit(null)}finally{if(n._nesting--,!n.hasPendingMicrotasks)try{n.runOutsideAngular(()=>n.onStable.emit(null))}finally{n.isStable=!0}}}function LM(n){n.hasPendingMicrotasks=!!(n._hasPendingMicrotasks||(n.shouldCoalesceEventChangeDetection||n.shouldCoalesceRunChangeDetection)&&-1!==n.lastRequestAnimationFrameId)}function YN(n){n._nesting++,n.isStable&&(n.isStable=!1,n.onUnstable.emit(null))}function QN(n){n._nesting--,AM(n)}let Jp=(()=>{class n{constructor(){this.handler=null,this.internalCallbacks=[]}execute(){const e=[...this.internalCallbacks];this.internalCallbacks.length=0;for(const r of e)r();return!!this.handler?.execute()||e.length>0}ngOnDestroy(){this.handler?.destroy(),this.handler=null,this.internalCallbacks.length=0}static{this.\u0275prov=Yi({token:n,providedIn:"root",factory:()=>new n})}}return n})();function y7(n,t){const e=To(t,n),i=e[Be];!function S7(n,t){for(let e=t.length;e0&&HL(n,e,s.join(" "))}}(u,w,p,i),void 0!==e&&function A7(n,t,e){const i=n.projection=[];for(let r=0;r=0;i--){const r=n[i];r.hostVars=t+=r.hostVars,r.hostAttrs=bp(r.hostAttrs,e=bp(e,r.hostAttrs))}}(i)}function N7(n,t){for(const e in t.inputs){if(!t.inputs.hasOwnProperty(e)||n.inputs.hasOwnProperty(e))continue;const i=t.inputs[e];if(void 0!==i&&(n.inputs[e]=i,n.declaredInputs[e]=t.declaredInputs[e],null!==t.inputTransforms)){const r=Array.isArray(i)?i[0]:i;if(!t.inputTransforms.hasOwnProperty(r))continue;n.inputTransforms??={},n.inputTransforms[r]=t.inputTransforms[r]}}}function Ny(n){return n===rl?{}:n===Qi?[]:n}function k7(n,t){const e=n.viewQuery;n.viewQuery=e?(i,r)=>{t(i,r),e(i,r)}:t}function P7(n,t){const e=n.contentQueries;n.contentQueries=e?(i,r,s)=>{t(i,r,s),e(i,r,s)}:t}function z7(n,t){const e=n.hostBindings;n.hostBindings=e?(i,r)=>{t(i,r),e(i,r)}:t}function Ou(n,t){return!t||null===t.firstChild||oy(n)}function sg(n,t,e,i=!0){const r=t[Be];if(function r6(n,t,e,i){const r=mn+i,s=e.length;i>0&&(e[r-1][wa]=t),i{class n{static{this.__NG_ELEMENT_ID__=h9}}return n})();function h9(){return fO(pr(),Se())}const c9=An,dO=class extends c9{constructor(t,e,i){super(),this._lContainer=t,this._hostTNode=e,this._hostLView=i}get element(){return Au(this._hostTNode,this._hostLView)}get injector(){return new Yn(this._hostTNode,this._hostLView)}get parentInjector(){const t=Qm(this._hostTNode,this._hostLView);if(a1(t)){const e=Op(t,this._hostLView),i=Np(t);return new Yn(e[Be].data[i+8],e)}return new Yn(null,this._hostLView)}clear(){for(;this.length>0;)this.remove(this.length-1)}get(t){const e=uO(this._lContainer);return null!==e&&e[t]||null}get length(){return this._lContainer.length-mn}createEmbeddedView(t,e,i){let r,s;"number"==typeof i?r=i:null!=i&&(r=i.index,s=i.injector);const a=t.createEmbeddedViewImpl(e||{},s,null);return this.insertImpl(a,r,Ou(this._hostTNode,null)),a}createComponent(t,e,i,r,s){const o=t&&!function kp(n){return"function"==typeof n}(t);let a;if(o)a=e;else{const p=e||{};a=p.index,i=p.injector,r=p.projectableNodes,s=p.environmentInjector||p.ngModuleRef}const l=o?t:new Kp(di(t)),h=i||this.parentInjector;if(!s&&null==l.ngModule){const g=(o?h:this.parentInjector).get(ih,null);g&&(s=g)}di(l.componentType??{});const f=l.create(h,r,null,s);return this.insertImpl(f.hostView,a,Ou(this._hostTNode,null)),f}insert(t,e){return this.insertImpl(t,e,!0)}insertImpl(t,e,i){const r=t._lView;if(function hU(n){return Ps(n[vn])}(r)){const a=this.indexOf(t);if(-1!==a)this.detach(a);else{const l=r[vn],h=new dO(l,l[Os],l[vn]);h.detach(h.indexOf(t))}}const s=this._adjustIndex(e),o=this._lContainer;return sg(o,r,s,i),t.attachToViewContainerRef(),UA(BM(o),s,t),t}move(t,e){return this.insert(t,e)}indexOf(t){const e=uO(this._lContainer);return null!==e?e.indexOf(t):-1}remove(t){const e=this._adjustIndex(t,-1),i=Fp(this._lContainer,e);i&&(Xm(BM(this._lContainer),e),cy(i[Be],i))}detach(t){const e=this._adjustIndex(t,-1),i=Fp(this._lContainer,e);return i&&null!=Xm(BM(this._lContainer),e)?new Zp(i):null}_adjustIndex(t,e=0){return t??this.length+e}};function uO(n){return n[8]}function BM(n){return n[8]||(n[8]=[])}function fO(n,t){let e;const i=t[n.index];return Ps(i)?e=i:(e=function PN(n,t,e,i){return[n,!0,0,t,null,i,null,e,null,null]}(i,t,null,n),t[n.index]=e,Ty(t,e)),pO(e,t,n,i),new dO(e,n,t)}let pO=function vO(n,t,e,i){if(n[sl])return;let r;r=8&e.type?fr(i):function d9(n,t){const e=n[Yt],i=e.createComment(""),r=qs(t,n);return qc(e,dy(e,r),i,function l6(n,t){return n.nextSibling(t)}(e,r),!1),i}(t,e),n[sl]=r};function qu(n,t,e){const i=Se();return function Ln(n,t,e){return!Object.is(n[t],e)&&(n[t]=e,!0)}(i,function hl(){return Rt.lFrame.bindingIndex++}(),t)&&function No(n,t,e,i,r,s,o,a){const l=qs(t,e);let c,h=t.inputs;!a&&null!=h&&(c=h[i])?(CM(n,e,c,i,r),jc(t)&&function kV(n,t){const e=To(t,n);16&e[Ct]||(e[Ct]|=64)}(e,t.index)):3&t.type&&(i=function OV(n){return"class"===n?"className":"for"===n?"htmlFor":"formaction"===n?"formAction":"innerHtml"===n?"innerHTML":"readonly"===n?"readOnly":"tabindex"===n?"tabIndex":n}(i),r=null!=o?o(r,t.value||"",i):r,s.setProperty(l,i,r))}(Ti(),function zr(){const n=Rt.lFrame;return xp(n.tView,n.selectedIndex)}(),i,n,t,i[Yt],e,!1),qu}function ZM(n,t,e,i,r){const o=r?"class":"style";CM(n,e,t.inputs[o],o,i)}function id(n,t,e,i){const r=Se(),s=Ti(),o=jt+n,a=r[Yt],l=s.firstCreatePass?function B8(n,t,e,i,r,s){const o=t.consts,l=Lu(t,n,2,i,al(o,r));return function IM(n,t,e,i){if(gA()){const r=null===i?null:{"":-1},s=function FV(n,t){const e=n.directiveRegistry;let i=null,r=null;if(e)for(let s=0;s($h(!0),hy(i,r,function DA(){return Rt.lFrame.currentNamespace}()));const Zu="en-US";let Mk=Zu;function aw(n){return!!n&&"function"==typeof n.then}function Gk(n){return!!n&&"function"==typeof n.subscribe}function lw(n,t,e,i){const r=Se(),s=Ti(),o=pr();return function qk(n,t,e,i,r,s,o){const a=Hm(i),h=n.firstCreatePass&&HN(n),c=t[Er],d=RN(t);let u=!0;if(3&i.type||o){const g=qs(i,t),v=o?o(g):g,y=d.length,S=o?M=>o(fr(M[i.index])):i.index;let b=null;if(!o&&a&&(b=function UW(n,t,e,i){const r=n.cleanup;if(null!=r)for(let s=0;sl?a[l]:null}"string"==typeof o&&(s+=2)}return null}(n,t,r,i.index)),null!==b)(b.__ngLastListenerFn__||b).__ngNextListenerFn__=s,b.__ngLastListenerFn__=s,u=!1;else{s=Zk(i,t,c,s,!1);const M=e.listen(v,r,s);d.push(s,M),h&&h.push(r,S,y,y+1)}}else s=Zk(i,t,c,s,!1);const f=i.outputs;let p;if(u&&null!==f&&(p=f[r])){const g=p.length;if(g)for(let v=0;v-1?To(n.index,t):t);let l=$k(t,e,i,o),h=s.__ngNextListenerFn__;for(;h;)l=$k(t,e,h,o)&&l,h=h.__ngNextListenerFn__;return r&&!1===l&&o.preventDefault(),l}}function QW(){return this._results[Symbol.iterator]()}class cw{get changes(){return this._changes??=new Yo}constructor(t=!1){this._emitDistinctChangesOnly=t,this.dirty=!0,this._results=[],this._changesDetected=!1,this._changes=void 0,this.length=0,this.first=void 0,this.last=void 0;const e=cw.prototype;e[Symbol.iterator]||(e[Symbol.iterator]=QW)}get(t){return this._results[t]}map(t){return this._results.map(t)}filter(t){return this._results.filter(t)}find(t){return this._results.find(t)}reduce(t,e){return this._results.reduce(t,e)}forEach(t){this._results.forEach(t)}some(t){return this._results.some(t)}toArray(){return this._results.slice()}toString(){return this._results.toString()}reset(t,e){this.dirty=!1;const i=function lo(n){return n.flat(Number.POSITIVE_INFINITY)}(t);(this._changesDetected=!function $U(n,t,e){if(n.length!==t.length)return!1;for(let i=0;i{class n{static{this.__NG_ELEMENT_ID__=qW}}return n})();const GW=oh,XW=class extends GW{constructor(t,e,i){super(),this._declarationLView=t,this._declarationTContainer=e,this.elementRef=i}get ssrId(){return this._declarationTContainer.tView?.ssrId||null}createEmbeddedView(t,e){return this.createEmbeddedViewImpl(t,e)}createEmbeddedViewImpl(t,e,i){const r=function ng(n,t,e,i){const r=t.tView,a=xy(n,r,e,4096&n[Ct]?4096:16,null,t,null,null,null,i?.injector??null,i?.dehydratedView??null);a[wp]=n[t.index];const h=n[nl];return null!==h&&(a[nl]=h.createEmbeddedView(r)),NM(r,a,e),a}(this._declarationLView,this._declarationTContainer,t,{injector:e,dehydratedView:i});return new Zp(r)}};function qW(){return Xy(pr(),Se())}function Xy(n,t){return 4&n.type?new XW(t,n,Au(n,t)):null}class dw{constructor(t){this.queryList=t,this.matches=null}clone(){return new dw(this.queryList)}setDirty(){this.queryList.setDirty()}}class uw{constructor(t=[]){this.queries=t}createEmbeddedView(t){const e=t.queries;if(null!==e){const i=null!==t.contentQueries?t.contentQueries[0]:e.length,r=[];for(let s=0;s0)i.push(o[a/2]);else{const h=s[a+1],c=t[-l];for(let d=mn;d($h(!0),function ly(n,t){return n.createText(t)}(t[Yt],i));function mw(n,t,e,i,r){if(n=vt(n),Array.isArray(n))for(let s=0;s>20;if(Gc(n)||!n.multi){const f=new Lp(h,r,Ot),p=Sw(l,t,r?c:c+u,d);-1===p?(c1(Ym(a,o),s,l),yw(s,n,t.length),t.push(l),a.directiveStart++,a.directiveEnd++,r&&(a.providerIndexes+=1048576),e.push(f),o.push(f)):(e[p]=f,o[p]=f)}else{const f=Sw(l,t,c+u,d),p=Sw(l,t,c,c+u),v=p>=0&&e[p];if(r&&!v||!r&&!(f>=0&&e[f])){c1(Ym(a,o),s,l);const y=function yY(n,t,e,i,r){const s=new Lp(n,e,Ot);return s.multi=[],s.index=t,s.componentProviders=0,kP(s,r,i&&!e),s}(r?mY:vY,e.length,r,i,h);!r&&v&&(e[p].providerFactory=y),yw(s,n,t.length,0),t.push(l),a.directiveStart++,a.directiveEnd++,r&&(a.providerIndexes+=1048576),e.push(y),o.push(y)}else yw(s,n,f>-1?f:p,kP(e[r?p:f],h,!r&&i));!r&&i&&v&&e[p].componentProviders++}}}function yw(n,t,e,i){const r=Gc(t),s=function gj(n){return!!n.useClass}(t);if(r||s){const l=(s?vt(t.useClass):t).prototype.ngOnDestroy;if(l){const h=n.destroyHooks||(n.destroyHooks=[]);if(!r&&t.multi){const c=h.indexOf(e);-1===c?h.push(e,[i,l]):h[c+1].push(i,l)}else h.push(e,l)}}}function kP(n,t,e){return e&&n.componentProviders++,n.multi.push(t)-1}function Sw(n,t,e,i){for(let r=e;r{e.providersResolver=(i,r)=>function gY(n,t,e){const i=Ti();if(i.firstCreatePass){const r=Ea(n);mw(e,i.data,i.blueprint,r,!0),mw(t,i.data,i.blueprint,r,!1)}}(i,r?r(n):n,t)}}class sd{}class zP extends sd{constructor(t){super(),this.componentFactoryResolver=new JN(this),this.instance=null;const e=new Su([...t.providers,{provide:sd,useValue:this},{provide:wy,useValue:this.componentFactoryResolver}],t.parent||ty(),t.debugName,new Set(["environment"]));this.injector=e,t.runEnvironmentInitializers&&e.resolveInjectorInitializers()}destroy(){this.injector.destroy()}onDestroy(t){this.injector.onDestroy(t)}}let wY=(()=>{class n{constructor(e){this._injector=e,this.cachedInjectors=new Map}getOrCreateStandaloneInjector(e){if(!e.standalone)return null;if(!this.cachedInjectors.has(e)){const i=XA(0,e.type),r=i.length>0?function MY(n,t,e=null){return new zP({providers:n,parent:t,debugName:e,runEnvironmentInitializers:!0}).injector}([i],this._injector,`Standalone[${e.type.name}]`):null;this.cachedInjectors.set(e,r)}return this.cachedInjectors.get(e)}ngOnDestroy(){try{for(const e of this.cachedInjectors.values())null!==e&&e.destroy()}finally{this.cachedInjectors.clear()}}static{this.\u0275prov=Yi({token:n,providedIn:"environment",factory:()=>new n(_i(ih))})}}return n})();function RP(n){(function Zc(n){VN.has(n)||(VN.add(n),performance?.mark?.("mark_feature_usage",{detail:{feature:n}}))})("NgStandalone"),n.getStandaloneInjector=t=>t.get(wY).getOrCreateStandaloneInjector(n)}let Aw=(()=>{class n{constructor(){this.taskId=0,this.pendingTasks=new Set,this.hasPendingTasks=new _o(!1)}get _hasPendingTasks(){return this.hasPendingTasks.value}add(){this._hasPendingTasks||this.hasPendingTasks.next(!0);const e=this.taskId++;return this.pendingTasks.add(e),e}remove(e){this.pendingTasks.delete(e),0===this.pendingTasks.size&&this._hasPendingTasks&&this.hasPendingTasks.next(!1)}ngOnDestroy(){this.pendingTasks.clear(),this._hasPendingTasks&&this.hasPendingTasks.next(!1)}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();const g2=new Ht(""),XQ=new Ht("");let Pw=(()=>{class n{constructor(){this.initialized=!1,this.done=!1,this.donePromise=new Promise((e,i)=>{this.resolve=e,this.reject=i}),this.appInits=Hi(XQ,{optional:!0})??[]}runInitializers(){if(this.initialized)return;const e=[];for(const r of this.appInits){const s=r();if(aw(s))e.push(s);else if(Gk(s)){const o=new Promise((a,l)=>{s.subscribe({complete:a,error:l})});e.push(o)}}const i=()=>{this.done=!0,this.resolve()};Promise.all(e).then(()=>{i()}).catch(r=>{this.reject(r)}),0===e.length&&i(),this.initialized=!0}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();const v2=new Ht("");let ef=(()=>{class n{constructor(){this._bootstrapListeners=[],this._runningTick=!1,this._destroyed=!1,this._destroyListeners=[],this._views=[],this.internalErrorHandler=Hi(SN),this.afterRenderEffectManager=Hi(Jp),this.componentTypes=[],this.components=[],this.isStable=Hi(Aw).hasPendingTasks.pipe(jr(e=>!e)),this._injector=Hi(ih)}get destroyed(){return this._destroyed}get injector(){return this._injector}bootstrap(e,i){const r=e instanceof rN;if(!this._injector.get(Pw).done)throw!r&&function _c(n){const t=di(n)||Wn(n)||gs(n);return null!==t&&t.standalone}(e),new F(405,!1);let o;o=r?e:this._injector.get(wy).resolveComponentFactory(e),this.componentTypes.push(o.componentType);const a=function $Q(n){return n.isBoundToModule}(o)?void 0:this._injector.get(sd),h=o.create(Wo.NULL,[],i||o.selector,a),c=h.location.nativeElement,d=h.injector.get(g2,null);return d?.registerApplication(c),h.onDestroy(()=>{this.detachView(h.hostView),e0(this.components,h),d?.unregisterApplication(c)}),this._loadComponent(h),h}tick(){if(this._runningTick)throw new F(101,!1);try{this._runningTick=!0;for(let e of this._views)e.detectChanges()}catch(e){this.internalErrorHandler(e)}finally{try{this.afterRenderEffectManager.execute()}catch(e){this.internalErrorHandler(e)}this._runningTick=!1}}attachView(e){const i=e;this._views.push(i),i.attachToAppRef(this)}detachView(e){const i=e;e0(this._views,i),i.detachFromAppRef()}_loadComponent(e){this.attachView(e.hostView),this.tick(),this.components.push(e);const i=this._injector.get(v2,[]);[...this._bootstrapListeners,...i].forEach(r=>r(e))}ngOnDestroy(){if(!this._destroyed)try{this._destroyListeners.forEach(e=>e()),this._views.slice().forEach(e=>e.destroy())}finally{this._destroyed=!0,this._views=[],this._bootstrapListeners=[],this._destroyListeners=[]}}onDestroy(e){return this._destroyListeners.push(e),()=>e0(this._destroyListeners,e)}destroy(){if(this._destroyed)throw new F(406,!1);const e=this._injector;e.destroy&&!e.destroyed&&e.destroy()}get viewCount(){return this._views.length}warnIfDestroyed(){}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();function e0(n,t){const e=n.indexOf(t);e>-1&&n.splice(e,1)}let JQ=(()=>{class n{constructor(){this.zone=Hi(Rr),this.applicationRef=Hi(ef)}initialize(){this._onMicrotaskEmptySubscription||(this._onMicrotaskEmptySubscription=this.zone.onMicrotaskEmpty.subscribe({next:()=>{this.zone.run(()=>{this.applicationRef.tick()})}}))}ngOnDestroy(){this._onMicrotaskEmptySubscription?.unsubscribe()}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();function b2(n){return[{provide:Rr,useFactory:n},{provide:yu,multi:!0,useFactory:()=>{const t=Hi(JQ,{optional:!0});return()=>t.initialize()}},{provide:yu,multi:!0,useFactory:()=>{const t=Hi(tG);return()=>{t.initialize()}}},{provide:SN,useFactory:KQ}]}function KQ(){const n=Hi(Rr),t=Hi(nh);return e=>n.runOutsideAngular(()=>t.handleError(e))}function eG(n){return function b1(n){return{\u0275providers:n}}([[],b2(()=>new Rr(function M2(n){return{enableLongStackTrace:!1,shouldCoalesceEventChangeDetection:n?.eventCoalescing??!1,shouldCoalesceRunChangeDetection:n?.runCoalescing??!1}}(n)))])}let tG=(()=>{class n{constructor(){this.subscription=new As,this.initialized=!1,this.zone=Hi(Rr),this.pendingTasks=Hi(Aw)}initialize(){if(this.initialized)return;this.initialized=!0;let e=null;!this.zone.isStable&&!this.zone.hasPendingMacrotasks&&!this.zone.hasPendingMicrotasks&&(e=this.pendingTasks.add()),this.zone.runOutsideAngular(()=>{this.subscription.add(this.zone.onStable.subscribe(()=>{Rr.assertNotInAngularZone(),queueMicrotask(()=>{null!==e&&!this.zone.hasPendingMacrotasks&&!this.zone.hasPendingMicrotasks&&(this.pendingTasks.remove(e),e=null)})}))}),this.subscription.add(this.zone.onUnstable.subscribe(()=>{Rr.assertInAngularZone(),e??=this.pendingTasks.add()}))}ngOnDestroy(){this.subscription.unsubscribe()}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();const ah=new Ht("",{providedIn:"root",factory:()=>Hi(ah,xi.Optional|xi.SkipSelf)||function iG(){return typeof $localize<"u"&&$localize.locale||Zu}()}),zw=new Ht("");let nc=null;function DG(n){try{const{rootComponent:t,appProviders:e,platformProviders:i}=n,r=function aG(n=[]){if(nc)return nc;const t=function E2(n=[],t){return Wo.create({name:t,providers:[{provide:C1,useValue:"platform"},{provide:zw,useValue:new Set([()=>nc=null])},...n]})}(n);return nc=t,function m2(){!function Mb(n){$d=n}(()=>{throw new F(600,!1)})}(),function D2(n){n.get(sL,null)?.forEach(e=>e())}(t),t}(i),s=[eG(),...e||[]],a=new zP({providers:s,parent:r,debugName:"",runEnvironmentInitializers:!1}).injector,l=a.get(Rr);return l.run(()=>{a.resolveInjectorInitializers();const h=a.get(nh,null);let c;l.runOutsideAngular(()=>{c=l.onError.subscribe({next:f=>{h.handleError(f)}})});const d=()=>a.destroy(),u=r.get(zw);return u.add(d),a.onDestroy(()=>{c.unsubscribe(),u.delete(d)}),function y2(n,t,e){try{const i=e();return aw(i)?i.catch(r=>{throw t.runOutsideAngular(()=>n.handleError(r)),r}):i}catch(i){throw t.runOutsideAngular(()=>n.handleError(i)),i}}(h,l,()=>{const f=a.get(Pw);return f.runInitializers(),f.donePromise.then(()=>{!function wk(n){so(n,"Expected localeId to be defined"),"string"==typeof n&&(Mk=n.toLowerCase().replace(/_/g,"-"))}(a.get(ah,Zu)||Zu);const g=a.get(ef);return void 0!==t&&g.bootstrap(t),g})})})}catch(t){return Promise.reject(t)}}let $2=null;function Vw(){return $2}class UG{}const ad=new Ht("");let sq=(()=>{class n{static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275mod=km({type:n})}static{this.\u0275inj=yp({})}}return n})();function uz(n){return"server"===n}class kq extends UG{constructor(){super(...arguments),this.supportsDOMEvents=!0}}class oC extends kq{static makeCurrent(){!function _G(n){$2??=n}(new oC)}onAndCancel(t,e,i){return t.addEventListener(e,i),()=>{t.removeEventListener(e,i)}}dispatchEvent(t,e){t.dispatchEvent(e)}remove(t){t.parentNode&&t.parentNode.removeChild(t)}createElement(t,e){return(e=e||this.getDefaultDocument()).createElement(t)}createHtmlDocument(){return document.implementation.createHTMLDocument("fakeTitle")}getDefaultDocument(){return document}isElementNode(t){return t.nodeType===Node.ELEMENT_NODE}isShadowRoot(t){return t instanceof DocumentFragment}getGlobalEventTarget(t,e){return"window"===e?window:"document"===e?t:"body"===e?t.body:null}getBaseHref(t){const e=function Pq(){return Dg=Dg||document.querySelector("base"),Dg?Dg.getAttribute("href"):null}();return null==e?null:function zq(n){return new URL(n,document.baseURI).pathname}(e)}resetBaseElement(){Dg=null}getUserAgent(){return window.navigator.userAgent}getCookie(t){return function xX(n,t){t=encodeURIComponent(t);for(const e of n.split(";")){const i=e.indexOf("="),[r,s]=-1==i?[e,""]:[e.slice(0,i),e.slice(i+1)];if(r.trim()===t)return decodeURIComponent(s)}return null}(document.cookie,t)}}let Dg=null,Hq=(()=>{class n{build(){return new XMLHttpRequest}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();const aC=new Ht("");let vz=(()=>{class n{constructor(e,i){this._zone=i,this._eventNameToPlugin=new Map,e.forEach(r=>{r.manager=this}),this._plugins=e.slice().reverse()}addEventListener(e,i,r){return this._findPluginFor(i).addEventListener(e,i,r)}getZone(){return this._zone}_findPluginFor(e){let i=this._eventNameToPlugin.get(e);if(i)return i;if(i=this._plugins.find(s=>s.supports(e)),!i)throw new F(5101,!1);return this._eventNameToPlugin.set(e,i),i}static{this.\u0275fac=function(i){return new(i||n)(_i(aC),_i(Rr))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();class mz{constructor(t){this._doc=t}}const lC="ng-app-id";let yz=(()=>{class n{constructor(e,i,r,s={}){this.doc=e,this.appId=i,this.nonce=r,this.platformId=s,this.styleRef=new Map,this.hostNodes=new Set,this.styleNodesInDOM=this.collectServerRenderedStyles(),this.platformIsServer=uz(s),this.resetHostNodes()}addStyles(e){for(const i of e)1===this.changeUsageCount(i,1)&&this.onStyleAdded(i)}removeStyles(e){for(const i of e)this.changeUsageCount(i,-1)<=0&&this.onStyleRemoved(i)}ngOnDestroy(){const e=this.styleNodesInDOM;e&&(e.forEach(i=>i.remove()),e.clear());for(const i of this.getAllStyles())this.onStyleRemoved(i);this.resetHostNodes()}addHost(e){this.hostNodes.add(e);for(const i of this.getAllStyles())this.addStyleToHost(e,i)}removeHost(e){this.hostNodes.delete(e)}getAllStyles(){return this.styleRef.keys()}onStyleAdded(e){for(const i of this.hostNodes)this.addStyleToHost(i,e)}onStyleRemoved(e){const i=this.styleRef;i.get(e)?.elements?.forEach(r=>r.remove()),i.delete(e)}collectServerRenderedStyles(){const e=this.doc.head?.querySelectorAll(`style[${lC}="${this.appId}"]`);if(e?.length){const i=new Map;return e.forEach(r=>{null!=r.textContent&&i.set(r.textContent,r)}),i}return null}changeUsageCount(e,i){const r=this.styleRef;if(r.has(e)){const s=r.get(e);return s.usage+=i,s.usage}return r.set(e,{usage:i,elements:[]}),i}getStyleElement(e,i){const r=this.styleNodesInDOM,s=r?.get(i);if(s?.parentNode===e)return r.delete(i),s.removeAttribute(lC),s;{const o=this.doc.createElement("style");return this.nonce&&o.setAttribute("nonce",this.nonce),o.textContent=i,this.platformIsServer&&o.setAttribute(lC,this.appId),e.appendChild(o),o}}addStyleToHost(e,i){const r=this.getStyleElement(e,i),s=this.styleRef,o=s.get(i)?.elements;o?o.push(r):s.set(i,{elements:[r],usage:1})}resetHostNodes(){const e=this.hostNodes;e.clear(),e.add(this.doc.head)}static{this.\u0275fac=function(i){return new(i||n)(_i(ad),_i(N1),_i(oL,8),_i(bu))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();const hC={svg:"http://www.w3.org/2000/svg",xhtml:"http://www.w3.org/1999/xhtml",xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/",math:"http://www.w3.org/1998/MathML/"},cC=/%COMP%/g,Uq=new Ht("",{providedIn:"root",factory:()=>!0});function Iz(n,t){return t.map(e=>e.replace(cC,n))}let bz=(()=>{class n{constructor(e,i,r,s,o,a,l,h=null){this.eventManager=e,this.sharedStylesHost=i,this.appId=r,this.removeStylesOnCompDestroy=s,this.doc=o,this.platformId=a,this.ngZone=l,this.nonce=h,this.rendererByCompId=new Map,this.platformIsServer=uz(a),this.defaultRenderer=new dC(e,o,l,this.platformIsServer)}createRenderer(e,i){if(!e||!i)return this.defaultRenderer;this.platformIsServer&&i.encapsulation===ba.ShadowDom&&(i={...i,encapsulation:ba.Emulated});const r=this.getOrCreateRenderer(e,i);return r instanceof wz?r.applyToHost(e):r instanceof uC&&r.applyStyles(),r}getOrCreateRenderer(e,i){const r=this.rendererByCompId;let s=r.get(i.id);if(!s){const o=this.doc,a=this.ngZone,l=this.eventManager,h=this.sharedStylesHost,c=this.removeStylesOnCompDestroy,d=this.platformIsServer;switch(i.encapsulation){case ba.Emulated:s=new wz(l,h,i,this.appId,c,o,a,d);break;case ba.ShadowDom:return new Yq(l,h,e,i,o,a,this.nonce,d);default:s=new uC(l,h,i,c,o,a,d)}r.set(i.id,s)}return s}ngOnDestroy(){this.rendererByCompId.clear()}static{this.\u0275fac=function(i){return new(i||n)(_i(vz),_i(yz),_i(N1),_i(Uq),_i(ad),_i(bu),_i(Rr),_i(oL))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();class dC{constructor(t,e,i,r){this.eventManager=t,this.doc=e,this.ngZone=i,this.platformIsServer=r,this.data=Object.create(null),this.throwOnSyntheticProps=!0,this.destroyNode=null}destroy(){}createElement(t,e){return e?this.doc.createElementNS(hC[e]||e,t):this.doc.createElement(t)}createComment(t){return this.doc.createComment(t)}createText(t){return this.doc.createTextNode(t)}appendChild(t,e){(Mz(t)?t.content:t).appendChild(e)}insertBefore(t,e,i){t&&(Mz(t)?t.content:t).insertBefore(e,i)}removeChild(t,e){t&&t.removeChild(e)}selectRootElement(t,e){let i="string"==typeof t?this.doc.querySelector(t):t;if(!i)throw new F(-5104,!1);return e||(i.textContent=""),i}parentNode(t){return t.parentNode}nextSibling(t){return t.nextSibling}setAttribute(t,e,i,r){if(r){e=r+":"+e;const s=hC[r];s?t.setAttributeNS(s,e,i):t.setAttribute(e,i)}else t.setAttribute(e,i)}removeAttribute(t,e,i){if(i){const r=hC[i];r?t.removeAttributeNS(r,e):t.removeAttribute(`${i}:${e}`)}else t.removeAttribute(e)}addClass(t,e){t.classList.add(e)}removeClass(t,e){t.classList.remove(e)}setStyle(t,e,i,r){r&(ec.DashCase|ec.Important)?t.style.setProperty(e,i,r&ec.Important?"important":""):t.style[e]=i}removeStyle(t,e,i){i&ec.DashCase?t.style.removeProperty(e):t.style[e]=""}setProperty(t,e,i){null!=t&&(t[e]=i)}setValue(t,e){t.nodeValue=e}listen(t,e,i){if("string"==typeof t&&!(t=Vw().getGlobalEventTarget(this.doc,t)))throw new Error(`Unsupported event target ${t} for event ${e}`);return this.eventManager.addEventListener(t,e,this.decoratePreventDefault(i))}decoratePreventDefault(t){return e=>{if("__ngUnwrap__"===e)return t;!1===(this.platformIsServer?this.ngZone.runGuarded(()=>t(e)):t(e))&&e.preventDefault()}}}function Mz(n){return"TEMPLATE"===n.tagName&&void 0!==n.content}class Yq extends dC{constructor(t,e,i,r,s,o,a,l){super(t,s,o,l),this.sharedStylesHost=e,this.hostEl=i,this.shadowRoot=i.attachShadow({mode:"open"}),this.sharedStylesHost.addHost(this.shadowRoot);const h=Iz(r.id,r.styles);for(const c of h){const d=document.createElement("style");a&&d.setAttribute("nonce",a),d.textContent=c,this.shadowRoot.appendChild(d)}}nodeOrShadowRoot(t){return t===this.hostEl?this.shadowRoot:t}appendChild(t,e){return super.appendChild(this.nodeOrShadowRoot(t),e)}insertBefore(t,e,i){return super.insertBefore(this.nodeOrShadowRoot(t),e,i)}removeChild(t,e){return super.removeChild(this.nodeOrShadowRoot(t),e)}parentNode(t){return this.nodeOrShadowRoot(super.parentNode(this.nodeOrShadowRoot(t)))}destroy(){this.sharedStylesHost.removeHost(this.shadowRoot)}}class uC extends dC{constructor(t,e,i,r,s,o,a,l){super(t,s,o,a),this.sharedStylesHost=e,this.removeStylesOnCompDestroy=r,this.styles=l?Iz(l,i.styles):i.styles}applyStyles(){this.sharedStylesHost.addStyles(this.styles)}destroy(){this.removeStylesOnCompDestroy&&this.sharedStylesHost.removeStyles(this.styles)}}class wz extends uC{constructor(t,e,i,r,s,o,a,l){const h=r+"-"+i.id;super(t,e,i,s,o,a,l,h),this.contentAttr=function jq(n){return"_ngcontent-%COMP%".replace(cC,n)}(h),this.hostAttr=function Vq(n){return"_nghost-%COMP%".replace(cC,n)}(h)}applyToHost(t){this.applyStyles(),this.setAttribute(t,this.hostAttr,"")}createElement(t,e){const i=super.createElement(t,e);return super.setAttribute(i,this.contentAttr,""),i}}let Qq=(()=>{class n extends mz{constructor(e){super(e)}supports(e){return!0}addEventListener(e,i,r){return e.addEventListener(i,r,!1),()=>this.removeEventListener(e,i,r)}removeEventListener(e,i,r){return e.removeEventListener(i,r)}static{this.\u0275fac=function(i){return new(i||n)(_i(ad))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();const Cz=["alt","control","meta","shift"],Gq={"\b":"Backspace","\t":"Tab","\x7f":"Delete","\x1b":"Escape",Del:"Delete",Esc:"Escape",Left:"ArrowLeft",Right:"ArrowRight",Up:"ArrowUp",Down:"ArrowDown",Menu:"ContextMenu",Scroll:"ScrollLock",Win:"OS"},Xq={alt:n=>n.altKey,control:n=>n.ctrlKey,meta:n=>n.metaKey,shift:n=>n.shiftKey};let qq=(()=>{class n extends mz{constructor(e){super(e)}supports(e){return null!=n.parseEventName(e)}addEventListener(e,i,r){const s=n.parseEventName(i),o=n.eventCallback(s.fullKey,r,this.manager.getZone());return this.manager.getZone().runOutsideAngular(()=>Vw().onAndCancel(e,s.domEventName,o))}static parseEventName(e){const i=e.toLowerCase().split("."),r=i.shift();if(0===i.length||"keydown"!==r&&"keyup"!==r)return null;const s=n._normalizeKey(i.pop());let o="",a=i.indexOf("code");if(a>-1&&(i.splice(a,1),o="code."),Cz.forEach(h=>{const c=i.indexOf(h);c>-1&&(i.splice(c,1),o+=h+".")}),o+=s,0!=i.length||0===s.length)return null;const l={};return l.domEventName=r,l.fullKey=o,l}static matchEventFullKeyCode(e,i){let r=Gq[e.key]||e.key,s="";return i.indexOf("code.")>-1&&(r=e.code,s="code."),!(null==r||!r)&&(r=r.toLowerCase()," "===r?r="space":"."===r&&(r="dot"),Cz.forEach(o=>{o!==r&&(0,Xq[o])(e)&&(s+=o+".")}),s+=r,s===i)}static eventCallback(e,i,r){return s=>{n.matchEventFullKeyCode(s,e)&&r.runGuarded(()=>i(s))}}static _normalizeKey(e){return"esc"===e?"escape":e}static{this.\u0275fac=function(i){return new(i||n)(_i(ad))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();function Ez(n){return{appProviders:[...i$,...n?.providers??[]],platformProviders:e$}}const e$=[{provide:bu,useValue:"browser"},{provide:sL,useValue:function Zq(){oC.makeCurrent()},multi:!0},{provide:ad,useFactory:function Kq(){return function Aj(n){L1=n}(document),document},deps:[]}],i$=[{provide:C1,useValue:"root"},{provide:nh,useFactory:function Jq(){return new nh},deps:[]},{provide:aC,useClass:Qq,multi:!0,deps:[ad,Rr,bu]},{provide:aC,useClass:qq,multi:!0,deps:[ad]},bz,yz,vz,{provide:sN,useExisting:bz},{provide:class cq{},useClass:Hq,deps:[]},[]];var o$=0,fC=!1;function w0(n,t){var e=t;return e.unshift(void 0),new(Function.prototype.bind.apply(n,e))}function Y(n,t){for(var e=t,i=n.replace(/\[/g,".").replace(/\]/g,"").split("."),r=0;r"u"}function Ei(n){return n+"_"+o$++}function E0(n,t){return n===t||!(n===document||!n)&&E0(n.parentNode,t)}function Ag(n){try{throw new Error(n)}catch(t){throw new Error(t.message+"\n"+t.stack)}}function Re(n){var t=n+"";return t.match(/auto|cm|mm|in|px|pt|pc|%|em|ex|ch|rem|vw|vh|vmin|vmax/)?t:t+"px"}function ce(){return fC}var Lg,n,t,d$={latn:{_digits:"0123456789",_type:"numeric"}},Lz={decimal:".",group:",",percentSign:"%",plusSign:"+",minusSign:"-",infinity:"\u221e",nan:"NaN",exponential:"E"},Nz=[0,1,2,3,4,5,6,7,8,9],Hr=function(){function n(){}return n.getMainObject=function(t,e){return Y(ce()?e:"main."+e,t)},n.getNumberingSystem=function(t){return Y("supplemental.numberingSystems",t)||this.numberingSystems},n.reverseObject=function(t,e){for(var r={},s=0,o=e||Object.keys(t);s13&&(p+=1,o-=12),o-=1,a=p-4716;var y=u-24e5,S=10631/30,b=u-1948084,M=Math.floor(b/10631);b-=10631*M;var w=Math.floor((b-.1335)/S),C=30*M+w;b-=Math.floor(w*S+.1335);var D=Math.floor((b+28.5001)/29.5);13===D&&(D=12);for(var A=b-Math.floor(29.5001*D-29),x=0;xy);x++);var P=x+16260,L=Math.floor((P-1)/12),O=L+1,N=P-12*L,T=y-t[x-1]+1;return(T+"").length>2&&(T=A,N=D,O=C),{year:O,month:N,date:T}},n.toGregorian=function i(r,s,o){var g=Math.floor(o+t[12*(r-1)+1+(s-1)-16260-1]-1+24e5+.5),v=Math.floor((g-1867216.25)/36524.25),y=1524+(v=g+1+v-Math.floor(v/4)),S=Math.floor((y-122.1)/365.25),b=Math.floor(365.25*S),M=Math.floor((y-b)/30.6001),w=y-b-Math.floor(30.6001*M),C=M-(M>13.5?13:1),D=S-(C>2.5?4716:4715);return D<=0&&C--,new Date(D+"/"+C+"/"+w)};var ut,p$=/\/MMMMM|MMMM|MMM|a|LLLL|LLL|EEEEE|EEEE|E|K|cccc|ccc|WW|W|G+|z+/gi,Oz="stand-alone",g$=["sun","mon","tue","wed","thu","fri","sat"],kz={m:"getMinutes",h:"getHours",H:"getHours",s:"getSeconds",d:"getDate",f:"getMilliseconds"},Pz=function(){function n(){}return n.dateFormat=function(t,e,i){var r=this,s=ut.getDependables(i,t,e.calendar),o=Y("parserObject.numbers",s),a=s.dateObject,l={isIslamic:ut.islamicRegex.test(e.calendar)};ce()&&e.isServerRendered&&(e=ut.compareBlazorDateFormats(e,t));var h=e.format||ut.getResultantPattern(e.skeleton,s.dateObject,e.type,!1,ce()?t:"");if(l.dateSeperator=ce()?Y("dateSeperator",a):ut.getDateSeparator(s.dateObject),st(h))Ag("Format options or type given must be invalid");else{h=ut.ConvertDateToWeekFormat(h),ce()&&(h=h.replace(/tt/,"a")),l.pattern=h,l.numMapper=ce()?ze({},o):Hr.getNumberMapper(s.parserObject,Hr.getNumberingSystem(i));for(var d=0,u=h.match(p$)||[];d2?r+=e.month[""+u]:p=!0;break;case"E":case"c":r+=e.weekday[""+g$[t.getDay()]];break;case"H":case"h":case"m":case"s":case"d":case"f":if(p=!0,"d"===d)u=o.date;else if("f"===d){p=!1,g=!0;var y=(f=(f=t[""+kz[""+d]]().toString()).substring(0,c)).length;if(c!==y){if(c>3)continue;for(var S=0;S0?1:0],o=Math.abs(t);return s.replace(/HH?|mm/g,function(a){var l=a.length,h=-1!==a.indexOf("H");return i.checkTwodigitNumber(Math.floor(h?o/60:o%60),l)})},n}(),zz={ms:"minimumSignificantDigits",ls:"maximumSignificantDigits",mf:"minimumFractionDigits",lf:"maximumFractionDigits"},sf=["infinity","nan","group","decimal","exponential"],Rz=function(){function n(){}return n.numberFormatter=function(t,e,i){var l,r=this,s=ze({},e),o={},a={},h=ut.getDependables(i,t,"",!0),c=h.numericObject;a.numberMapper=ce()?ze({},c):Hr.getNumberMapper(h.parserObject,Hr.getNumberingSystem(i),!0),a.currencySymbol=ce()?Y("currencySymbol",c):ut.getCurrencySymbol(h.numericObject,s.currency||kg,e.altSymbol,e.ignoreCurrency),a.percentSymbol=ce()?Y("numberSymbols.percentSign",c):a.numberMapper.numberSymbols.percentSign,a.minusSymbol=ce()?Y("numberSymbols.minusSign",c):a.numberMapper.numberSymbols.minusSign;var d=a.numberMapper.numberSymbols;if(e.format&&!ut.formatRegex.test(e.format))o=ut.customFormat(e.format,a,h.numericObject),!st(s.useGrouping)&&s.useGrouping&&(s.useGrouping=o.pData.useGrouping);else{if(ze(s,ut.getProperNumericSkeleton(e.format||"N")),s.isCurrency="currency"===s.type,s.isPercent="percent"===s.type,ce()||(l=ut.getSymbolPattern(s.type,a.numberMapper.numberSystem,h.numericObject,s.isAccount)),s.groupOne=this.checkValueRange(s.maximumSignificantDigits,s.minimumSignificantDigits,!0),this.checkValueRange(s.maximumFractionDigits,s.minimumFractionDigits,!1,!0),st(s.fractionDigits)||(s.minimumFractionDigits=s.maximumFractionDigits=s.fractionDigits),st(s.useGrouping)&&(s.useGrouping=!0),s.isCurrency&&!ce()&&(l=l.replace(/\u00A4/g,ut.defaultCurrency)),ce())o.nData=ze({},{},Y(s.type+"nData",c)),o.pData=ze({},{},Y(s.type+"pData",c)),"currency"===s.type&&e.currency&&ut.replaceBlazorCurrency([o.pData,o.nData],a.currencySymbol,e.currency);else{var u=l.split(";");o.nData=ut.getFormatData(u[1]||"-"+u[0],!0,a.currencySymbol),o.pData=ut.getFormatData(u[0],!1,a.currencySymbol),s.useGrouping&&(s.groupSeparator=d[sf[2]],s.groupData=this.getGroupingDetails(u[0]))}if(st(s.minimumFractionDigits)&&(s.minimumFractionDigits=o.nData.minimumFraction),st(s.maximumFractionDigits)){var p=o.nData.maximumFraction;s.maximumFractionDigits=st(p)&&s.isPercent?0:p}var g=s.minimumFractionDigits,v=s.maximumFractionDigits;!st(g)&&!st(v)&&g>v&&(s.maximumFractionDigits=g)}return ze(o.nData,s),ze(o.pData,s),function(y){return isNaN(y)?d[sf[1]]:isFinite(y)?r.intNumberFormatter(y,o,a,e):d[sf[0]]}},n.getGroupingDetails=function(t){var e={},i=t.match(ut.negativeDataRegex);if(i&&i[4]){var r=i[4],s=r.lastIndexOf(",");if(-1!==s){var o=r.split(".")[0];e.primary=o.length-s-1;var a=r.lastIndexOf(",",s-1);-1!==a&&(e.secondary=s-1-a)}}return e},n.checkValueRange=function(t,e,i,r){var s=r?"f":"s",o=0,a=zz["l"+s],l=zz["m"+s];if(st(t)||(this.checkRange(t,a,r),o++),st(e)||(this.checkRange(e,l,r),o++),2===o){if(!(tr[1])&&Ag(e+"value must be within the range"+r[0]+"to"+r[1])},n.intNumberFormatter=function(t,e,i,r){var s;if(!st(e.nData.type)){t<0?(t*=-1,s=e.nData):s=0===t&&e.zeroData||e.pData;var o="";if(s.isPercent&&(t*=100),s.groupOne)o=this.processSignificantDigits(t,s.minimumSignificantDigits,s.maximumSignificantDigits);else if(o=this.processFraction(t,s.minimumFractionDigits,s.maximumFractionDigits,r),s.minimumIntegerDigits&&(o=this.processMinimumIntegers(o,s.minimumIntegerDigits)),i.isCustomFormat&&s.minimumFractionDigits=0&&"0"===l[parseInt(c.toString(),10)]&&c>=s.minimumFractionDigits;c--)l=l.slice(0,c);o=a[0]+"."+l}return"scientific"===s.type&&(o=(o=t.toExponential(s.maximumFractionDigits)).replace("e",i.numberMapper.numberSymbols[sf[4]])),o=o.replace(".",i.numberMapper.numberSymbols[sf[3]]),o="#,###,,;(#,###,,)"===s.format?this.customPivotFormat(parseInt(o,10)):o,s.useGrouping&&(o=this.groupNumbers(o,s.groupData.primary,s.groupSeparator||",",i.numberMapper.numberSymbols[sf[3]]||".",s.groupData.secondary)),o=Hr.convertValueParts(o,ut.latnParseRegex,i.numberMapper.mapper),"N/A"===s.nlead?s.nlead:"0"===o&&r&&"0"===r.format?o+s.nend:s.nlead+o+s.nend}},n.processSignificantDigits=function(t,e,i){var r=t+"";return r.lengthe;)c=l.slice(h-e,h)+(c.length?i+c:""),h-=e,o&&(e=s,o=!1);return a[0]=l.slice(0,h)+(c.length?i:"")+c,a.join(r)},n.processFraction=function(t,e,i,r){var s=(t+"").split(".")[1],o=s?s.length:0;if(e&&oi||0===i))return t.toFixed(i);var h=t+"";return"0"===h[0]&&r&&"###.00"===r.format&&(h=h.slice(1)),h},n.processMinimumIntegers=function(t,e){var i=t.split("."),r=i[0],s=r.length;if(s=5e5){var r=(t/=1e6).toString().split(".")[1];return r&&+r.substring(0,1)>=5?Math.ceil(t).toString():Math.floor(t).toString()}return""},n}(),Ng=(new RegExp("^([^0-9]*)(([0-9,]*[0-9]+)(.[0-9]+)?)([Ee][+-]?[0-9]+)?([^0-9]*)$"),function(){function n(t){this.ranArray=[],this.boundedEvents={},!m(t)&&(this.context=t)}return n.prototype.on=function(t,e,i,r){if(!m(e)){var s=i||this.context;if(this.notExist(t))return void(this.boundedEvents[""+t]=[{handler:e,context:s,id:r}]);m(r)?this.isHandlerPresent(this.boundedEvents[""+t],e)||this.boundedEvents[""+t].push({handler:e,context:s}):-1===this.ranArray.indexOf(r)&&(this.ranArray.push(r),this.boundedEvents[""+t].push({handler:e,context:s,id:r}))}},n.prototype.off=function(t,e,i){if(!this.notExist(t)){var r=Y(t,this.boundedEvents);if(e){for(var s=0;s1&&(U.fractionDigits=parseInt(z[2],10)),U}function p(T,z,U,B){var j=B?{}:{nlead:"",nend:""},Q=T.match(n.customRegex);if(Q){B||(j.nlead=g(Q[1],U),j.nend=g(Q[10],U),j.groupPattern=Q[4]);var oe=Q[7];if(oe&&z){var ue=oe.match(t);j.minimumFraction=m(ue)?0:ue.length,j.maximumFraction=oe.length-1}}return j}function g(T,z){return T?(T=T.replace(n.defaultCurrency,z),""===z?T.trim():T):""}function v(T,z,U,B){return B?"$":Y("currencies."+z+(U?"."+U:".symbol"),T)||Y("currencies."+z+".symbol-alt-narrow",T)||"$"}function S(T,z,U){var B={type:"decimal",minimumFractionDigits:0,maximumFractionDigits:0},j=T.match(n.customRegex);if(m(j)||""===j[5]&&"N/A"!==T)return B.type=void 0,B;B.nlead=j[1],B.nend=j[10];var Q=j[6],oe=!!Q.match(/ $/g),ue=-1!==Q.replace(/ $/g,"").indexOf(" ");B.useGrouping=-1!==Q.indexOf(",")||ue,Q=Q.replace(/,/g,"");var fe=j[7];if(-1!==Q.indexOf("0")&&(B.minimumIntegerDigits=Q.length-Q.indexOf("0")),m(fe)||(B.minimumFractionDigits=fe.lastIndexOf("0"),B.maximumFractionDigits=fe.lastIndexOf("#"),-1===B.minimumFractionDigits&&(B.minimumFractionDigits=0),(-1===B.maximumFractionDigits||B.maximumFractionDigitsQ.lastIndexOf("'"))){B[""+a[parseInt(j.toString(),10)]]=Q.substr(0,oe)+U+Q.substr(oe+1),B[""+a[""+z]]=!0,B.type=B.isCurrency?"currency":"percent";break}}return B}function C(T,z){if(-1!==T.indexOf(",")){var U=T.split(",");T=U[0]+Y("numberMapper.numberSymbols.group",z)+U[1].replace(".",Y("numberMapper.numberSymbols.decimal",z))}else T=T.replace(".",Y("numberMapper.numberSymbols.decimal",z));return T}function A(T,z,U){T+=".";for(var B=0;B0;Q-=3)T=","+U[Q-2]+U[Q-1]+U[parseInt(Q.toString(),10)]+T;return T=T.slice(1),z[1]?T+"."+z[1]:T}n.dateParseRegex=/([a-z])\1*|'([^']|'')+'|''|./gi,n.basicPatterns=["short","medium","long","full"],n.defaultObject={dates:{calendars:{gregorian:{months:{"stand-alone":{abbreviated:{1:"Jan",2:"Feb",3:"Mar",4:"Apr",5:"May",6:"Jun",7:"Jul",8:"Aug",9:"Sep",10:"Oct",11:"Nov",12:"Dec"},narrow:{1:"J",2:"F",3:"M",4:"A",5:"M",6:"J",7:"J",8:"A",9:"S",10:"O",11:"N",12:"D"},wide:{1:"January",2:"February",3:"March",4:"April",5:"May",6:"June",7:"July",8:"August",9:"September",10:"October",11:"November",12:"December"}}},days:{"stand-alone":{abbreviated:{sun:"Sun",mon:"Mon",tue:"Tue",wed:"Wed",thu:"Thu",fri:"Fri",sat:"Sat"},narrow:{sun:"S",mon:"M",tue:"T",wed:"W",thu:"T",fri:"F",sat:"S"},short:{sun:"Su",mon:"Mo",tue:"Tu",wed:"We",thu:"Th",fri:"Fr",sat:"Sa"},wide:{sun:"Sunday",mon:"Monday",tue:"Tuesday",wed:"Wednesday",thu:"Thursday",fri:"Friday",sat:"Saturday"}}},dayPeriods:{format:{wide:{am:"AM",pm:"PM"}}},eras:{eraNames:{0:"Before Christ","0-alt-variant":"Before Common Era",1:"Anno Domini","1-alt-variant":"Common Era"},eraAbbr:{0:"BC","0-alt-variant":"BCE",1:"AD","1-alt-variant":"CE"},eraNarrow:{0:"B","0-alt-variant":"BCE",1:"A","1-alt-variant":"CE"}},dateFormats:{full:"EEEE, MMMM d, y",long:"MMMM d, y",medium:"MMM d, y",short:"M/d/yy"},timeFormats:{full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},dateTimeFormats:{full:"{1} 'at' {0}",long:"{1} 'at' {0}",medium:"{1}, {0}",short:"{1}, {0}",availableFormats:{d:"d",E:"ccc",Ed:"d E",Ehm:"E h:mm a",EHm:"E HH:mm",Ehms:"E h:mm:ss a",EHms:"E HH:mm:ss",Gy:"y G",GyMMM:"MMM y G",GyMMMd:"MMM d, y G",GyMMMEd:"E, MMM d, y G",h:"h a",H:"HH",hm:"h:mm a",Hm:"HH:mm",hms:"h:mm:ss a",Hms:"HH:mm:ss",hmsv:"h:mm:ss a v",Hmsv:"HH:mm:ss v",hmv:"h:mm a v",Hmv:"HH:mm v",M:"L",Md:"M/d",MEd:"E, M/d",MMM:"LLL",MMMd:"MMM d",MMMEd:"E, MMM d",MMMMd:"MMMM d",ms:"mm:ss",y:"y",yM:"M/y",yMd:"M/d/y",yMEd:"E, M/d/y",yMMM:"MMM y",yMMMd:"MMM d, y",yMMMEd:"E, MMM d, y",yMMMM:"MMMM y"}}},islamic:{months:{"stand-alone":{abbreviated:{1:"Muh.",2:"Saf.",3:"Rab. I",4:"Rab. II",5:"Jum. I",6:"Jum. II",7:"Raj.",8:"Sha.",9:"Ram.",10:"Shaw.",11:"Dhu\u02bbl-Q.",12:"Dhu\u02bbl-H."},narrow:{1:"1",2:"2",3:"3",4:"4",5:"5",6:"6",7:"7",8:"8",9:"9",10:"10",11:"11",12:"12"},wide:{1:"Muharram",2:"Safar",3:"Rabi\u02bb I",4:"Rabi\u02bb II",5:"Jumada I",6:"Jumada II",7:"Rajab",8:"Sha\u02bbban",9:"Ramadan",10:"Shawwal",11:"Dhu\u02bbl-Qi\u02bbdah",12:"Dhu\u02bbl-Hijjah"}}},days:{"stand-alone":{abbreviated:{sun:"Sun",mon:"Mon",tue:"Tue",wed:"Wed",thu:"Thu",fri:"Fri",sat:"Sat"},narrow:{sun:"S",mon:"M",tue:"T",wed:"W",thu:"T",fri:"F",sat:"S"},short:{sun:"Su",mon:"Mo",tue:"Tu",wed:"We",thu:"Th",fri:"Fr",sat:"Sa"},wide:{sun:"Sunday",mon:"Monday",tue:"Tuesday",wed:"Wednesday",thu:"Thursday",fri:"Friday",sat:"Saturday"}}},dayPeriods:{format:{wide:{am:"AM",pm:"PM"}}},eras:{eraNames:{0:"AH"},eraAbbr:{0:"AH"},eraNarrow:{0:"AH"}},dateFormats:{full:"EEEE, MMMM d, y G",long:"MMMM d, y G",medium:"MMM d, y G",short:"M/d/y GGGGG"},timeFormats:{full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},dateTimeFormats:{full:"{1} 'at' {0}",long:"{1} 'at' {0}",medium:"{1}, {0}",short:"{1}, {0}",availableFormats:{d:"d",E:"ccc",Ed:"d E",Ehm:"E h:mm a",EHm:"E HH:mm",Ehms:"E h:mm:ss a",EHms:"E HH:mm:ss",Gy:"y G",GyMMM:"MMM y G",GyMMMd:"MMM d, y G",GyMMMEd:"E, MMM d, y G",h:"h a",H:"HH",hm:"h:mm a",Hm:"HH:mm",hms:"h:mm:ss a",Hms:"HH:mm:ss",M:"L",Md:"M/d",MEd:"E, M/d",MMM:"LLL",MMMd:"MMM d",MMMEd:"E, MMM d",MMMMd:"MMMM d",ms:"mm:ss",y:"y G",yyyy:"y G",yyyyM:"M/y GGGGG",yyyyMd:"M/d/y GGGGG",yyyyMEd:"E, M/d/y GGGGG",yyyyMMM:"MMM y G",yyyyMMMd:"MMM d, y G",yyyyMMMEd:"E, MMM d, y G",yyyyMMMM:"MMMM y G",yyyyQQQ:"QQQ y G",yyyyQQQQ:"QQQQ y G"}}}},timeZoneNames:{hourFormat:"+HH:mm;-HH:mm",gmtFormat:"GMT{0}",gmtZeroFormat:"GMT"}},numbers:{currencies:{USD:{displayName:"US Dollar",symbol:"$","symbol-alt-narrow":"$"},EUR:{displayName:"Euro",symbol:"\u20ac","symbol-alt-narrow":"\u20ac"},GBP:{displayName:"British Pound","symbol-alt-narrow":"\xa3"}},defaultNumberingSystem:"latn",minimumGroupingDigits:"1","symbols-numberSystem-latn":{decimal:".",group:",",list:";",percentSign:"%",plusSign:"+",minusSign:"-",exponential:"E",superscriptingExponent:"\xd7",perMille:"\u2030",infinity:"\u221e",nan:"NaN",timeSeparator:":"},"decimalFormats-numberSystem-latn":{standard:"#,##0.###"},"percentFormats-numberSystem-latn":{standard:"#,##0%"},"currencyFormats-numberSystem-latn":{standard:"\xa4#,##0.00",accounting:"\xa4#,##0.00;(\xa4#,##0.00)"},"scientificFormats-numberSystem-latn":{standard:"#E0"}}},n.blazorDefaultObject={numbers:{mapper:{0:"0",1:"1",2:"2",3:"3",4:"4",5:"5",6:"6",7:"7",8:"8",9:"9"},mapperDigits:"0123456789",numberSymbols:{decimal:".",group:",",plusSign:"+",minusSign:"-",percentSign:"%",nan:"NaN",timeSeparator:":",infinity:"\u221e"},timeSeparator:":",currencySymbol:"$",currencypData:{nlead:"$",nend:"",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},percentpData:{nlead:"",nend:"%",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},percentnData:{nlead:"-",nend:"%",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},currencynData:{nlead:"($",nend:")",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},decimalnData:{nlead:"-",nend:"",groupData:{primary:3},maximumFraction:2,minimumFraction:2},decimalpData:{nlead:"",nend:"",groupData:{primary:3},maximumFraction:2,minimumFraction:2}},dates:{dayPeriods:{am:"AM",pm:"PM"},dateSeperator:"/",days:{abbreviated:{sun:"Sun",mon:"Mon",tue:"Tue",wed:"Wed",thu:"Thu",fri:"Fri",sat:"Sat"},short:{sun:"Su",mon:"Mo",tue:"Tu",wed:"We",thu:"Th",fri:"Fr",sat:"Sa"},wide:{sun:"Sunday",mon:"Monday",tue:"Tuesday",wed:"Wednesday",thu:"Thursday",fri:"Friday",sat:"Saturday"}},months:{abbreviated:{1:"Jan",2:"Feb",3:"Mar",4:"Apr",5:"May",6:"Jun",7:"Jul",8:"Aug",9:"Sep",10:"Oct",11:"Nov",12:"Dec"},wide:{1:"January",2:"February",3:"March",4:"April",5:"May",6:"June",7:"July",8:"August",9:"September",10:"October",11:"November",12:"December"}},eras:{1:"AD"}}},n.monthIndex={3:"abbreviated",4:"wide",5:"narrow",1:"abbreviated"},n.month="months",n.days="days",n.patternMatcher={C:"currency",P:"percent",N:"decimal",A:"currency",E:"scientific"},n.getResultantPattern=l,n.getDependables=h,n.getSymbolPattern=c,n.ConvertDateToWeekFormat=d,n.compareBlazorDateFormats=u,n.getProperNumericSkeleton=f,n.getFormatData=p,n.changeCurrencySymbol=g,n.getCurrencySymbol=v,n.customFormat=function y(T,z,U){for(var B={},j=T.split(";"),Q=["pData","nData","zeroData"],oe=0;oe1,fe.nData=ce()?Y(De.type+"nData",oe):p(ot[1]||"-"+ot[0],!0,Ie),fe.pData=ce()?Y(De.type+"pData",oe):p(ot[0],!1,Ie),!Me[2]&&!z.minimumFractionDigits&&!z.maximumFractionDigits&&(ue=p(Ve.split(";")[0],!0,"",!0).minimumFraction)}if(n.formatRegex.test(z.format)||!z.format){if(ze(Q,f(z.format||"N")),Q.custom=!1,$e="###0",(Q.fractionDigits||z.minimumFractionDigits||z.maximumFractionDigits||ue)&&(Q.fractionDigits&&(z.minimumFractionDigits=z.maximumFractionDigits=Q.fractionDigits),$e=A($e,ue||Q.fractionDigits||z.minimumFractionDigits||0,z.maximumFractionDigits||0)),z.minimumIntegerDigits&&($e=x($e,z.minimumIntegerDigits)),z.useGrouping&&($e=P($e)),"currency"===Q.type||Q.type&&ce()){ce()&&"currency"!==Q.type&&(fe.pData=Y(Q.type+"pData",oe),fe.nData=Y(Q.type+"nData",oe));var hr=$e;$e=fe.pData.nlead+hr+fe.pData.nend,(fe.hasNegativePattern||ce())&&($e+=";"+fe.nData.nlead+hr+fe.nData.nend)}"percent"===Q.type&&!ce()&&($e+=" %")}else $e=z.format.replace(/'/g,'"');return Object.keys(xe).length>0&&($e=B?$e:C($e,xe)),$e},n.fractionDigitsPattern=A,n.minimumIntegerPattern=x,n.groupingPattern=P,n.getWeekData=function L(T,z){var U="sun",B=Y("supplemental.weekData.firstDay",z),j=T;return/en-/.test(j)&&(j=j.slice(3)),j=j.slice(0,2).toUpperCase()+j.substr(2),B&&(U=B[""+j]||B[j.slice(0,2)]||"sun"),o[""+U]},n.replaceBlazorCurrency=function O(T,z,U){var B=function f$(n){return Y(n||"",u$)}(U);if(z!==B)for(var j=0,Q=T;j=0?U:U+7;var j=Math.floor((T.getTime()-z.getTime()-6e4*(T.getTimezoneOffset()-z.getTimezoneOffset()))/864e5)+1;if(U<4){if((B=Math.floor((j+U-1)/7)+1)>52){var oe=new Date(T.getFullYear()+1,0,1).getDay();B=(oe=oe>=0?oe:oe+7)<4?1:53}}else B=Math.floor((j+U-1)/7);return B}}(ut||(ut={}));var of=function(){function n(t,e,i){this.type="GET",this.emitError=!0,"string"==typeof t?(this.url=t,this.type=m(e)?this.type:e.toUpperCase(),this.contentType=i):La(t)&&Object.keys(t).length>0&&kn(this,t),this.contentType=m(this.contentType)?"application/json; charset=utf-8":this.contentType}return n.prototype.send=function(t){var e=this,i={"application/json":"json","multipart/form-data":"formData","application/octet-stream":"blob","application/x-www-form-urlencoded":"formData"};try{m(this.fetchRequest)&&"GET"===this.type?this.fetchRequest=new Request(this.url,{method:this.type}):m(this.fetchRequest)&&(this.data=m(t)?this.data:t,this.fetchRequest=new Request(this.url,{method:this.type,headers:{"Content-Type":this.contentType},body:this.data}));var r={cancel:!1,fetchRequest:this.fetchRequest};return this.triggerEvent(this.beforeSend,r),r.cancel?null:(this.fetchResponse=fetch(this.fetchRequest),this.fetchResponse.then(function(s){if(e.triggerEvent(e.onLoad,s),!s.ok)throw s;for(var o="text",a=0,l=Object.keys(i);a-1},n.getValue=function(t,e){var i=typeof window<"u"?window.browserDetails:{};return typeof navigator<"u"&&"MacIntel"===navigator.platform&&navigator.maxTouchPoints>1&&!0===n.isTouch&&!vC.CHROME.test(navigator.userAgent)&&(i.isIos=!0,i.isDevice=!0,i.isTouch=!0,i.isPointer=!0,i.isPointer="pointerEnabled"in window.navigator),typeof window<"u"&&window.Capacitor&&"ios"===window.Capacitor.getPlatform()&&(i.isPointer=!1),typeof i[""+t]>"u"?i[""+t]=e.test(n.userAgent):i[""+t]},Object.defineProperty(n,"userAgent",{get:function(){return n.uA},set:function(t){n.uA=t,window.browserDetails={}},enumerable:!0,configurable:!0}),Object.defineProperty(n,"info",{get:function(){return st(window.browserDetails.info)?window.browserDetails.info=n.extractBrowserDetail():window.browserDetails.info},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isIE",{get:function(){return n.getValue("isIE",A$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isTouch",{get:function(){return st(window.browserDetails.isTouch)?window.browserDetails.isTouch="ontouchstart"in window.navigator||window&&window.navigator&&window.navigator.maxTouchPoints>0||"ontouchstart"in window:window.browserDetails.isTouch},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isPointer",{get:function(){return st(window.browserDetails.isPointer)?window.browserDetails.isPointer="pointerEnabled"in window.navigator:window.browserDetails.isPointer},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isMSPointer",{get:function(){return st(window.browserDetails.isMSPointer)?window.browserDetails.isMSPointer="msPointerEnabled"in window.navigator:window.browserDetails.isMSPointer},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isDevice",{get:function(){return n.getValue("isDevice",T$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isIos",{get:function(){return n.getValue("isIos",N$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isIos7",{get:function(){return n.getValue("isIos7",O$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isAndroid",{get:function(){return n.getValue("isAndroid",k$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isWebView",{get:function(){return st(window.browserDetails.isWebView)&&(window.browserDetails.isWebView=!(st(window.cordova)&&st(window.PhoneGap)&&st(window.phonegap)&&"object"!==window.forge)),window.browserDetails.isWebView},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isWindows",{get:function(){return n.getValue("isWindows",P$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"touchStartEvent",{get:function(){return st(window.browserDetails.touchStartEvent)?window.browserDetails.touchStartEvent=n.getTouchStartEvent():window.browserDetails.touchStartEvent},enumerable:!0,configurable:!0}),Object.defineProperty(n,"touchMoveEvent",{get:function(){return st(window.browserDetails.touchMoveEvent)?window.browserDetails.touchMoveEvent=n.getTouchMoveEvent():window.browserDetails.touchMoveEvent},enumerable:!0,configurable:!0}),Object.defineProperty(n,"touchEndEvent",{get:function(){return st(window.browserDetails.touchEndEvent)?window.browserDetails.touchEndEvent=n.getTouchEndEvent():window.browserDetails.touchEndEvent},enumerable:!0,configurable:!0}),Object.defineProperty(n,"touchCancelEvent",{get:function(){return st(window.browserDetails.touchCancelEvent)?window.browserDetails.touchCancelEvent=n.getTouchCancelEvent():window.browserDetails.touchCancelEvent},enumerable:!0,configurable:!0}),n.uA=typeof navigator<"u"?navigator.userAgent:"",n}(),E=function(){function n(){}return n.addOrGetEventData=function(t){return"__eventList"in t?t.__eventList.events:(t.__eventList={},t.__eventList.events=[])},n.add=function(t,e,i,r,s){var a,o=n.addOrGetEventData(t);a=s?function l$(n,t){var e;return function(){for(var i=this,r=[],s=0;s"u"||(e.innerHTML=t.innerHTML?t.innerHTML:"",void 0!==t.className&&(e.className=t.className),void 0!==t.id&&(e.id=t.id),void 0!==t.styles&&e.setAttribute("style",t.styles),void 0!==t.attrs&&Fe(e,t.attrs)),e}function V(n,t){for(var e=Vz(t),i=RegExp,r=0,s=n;r0}function gl(n,t,e){for(var i=document.createDocumentFragment(),r=0,s=n;r0;)i.appendChild(n[0]);else for(var r=0,s=n;r-1&&!r[parseInt(s.toString(),10)].match(/\[.*\]/)){var o=r[parseInt(s.toString(),10)].split("#");if(o[1].match(/^\d/)||o[1].match(t)){var a=r[parseInt(s.toString(),10)].split(".");a[0]=a[0].replace(/#/,"[id='")+"']",r[parseInt(s.toString(),10)]=a.join(".")}}e[parseInt(i.toString(),10)]=r.join(" ")}return e.join(",")}return n}function J(n,t){var e=n;if("function"==typeof e.closest)return e.closest(t);for(;e&&1===e.nodeType;){if(mC(e,t))return e;e=e.parentNode}return null}function je(n,t){void 0!==t&&Object.keys(t).forEach(function(e){n.style[""+e]=t[""+e]})}function mC(n,t){var e=n.matches||n.msMatchesSelector||n.webkitMatchesSelector;return e?e.call(n,t):-1!==[].indexOf.call(document.querySelectorAll(t),n)}var H$=new RegExp("]"),dh=function(){function n(t,e){this.isRendered=!1,this.isComplexArraySetter=!1,this.isServerRendered=!1,this.allowServerDataBinding=!0,this.isProtectedOnChange=!0,this.properties={},this.changedProperties={},this.oldProperties={},this.bulkChanges={},this.refreshing=!1,this.ignoreCollectionWatch=!1,this.finalUpdate=function(){},this.childChangedProperties={},this.modelObserver=new Ng(this),st(e)||(this.element="string"==typeof e?document.querySelector(e):e,m(this.element)||(this.isProtectedOnChange=!1,this.addInstance())),st(t)||this.setProperties(t,!0),this.isDestroyed=!1}return n.prototype.setProperties=function(t,e){var i=this.isProtectedOnChange;this.isProtectedOnChange=!!e,kn(this,t),!0!==e?(kn(this.changedProperties,t),this.dataBind()):ce()&&this.isRendered&&this.serverDataBind(t),this.finalUpdate(),this.changedProperties={},this.oldProperties={},this.isProtectedOnChange=i},n.callChildDataBind=function(t,e){for(var r=0,s=Object.keys(t);r=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Hs=function(n){function t(i){var r=n.call(this,i,void 0)||this;return r.easing={ease:"cubic-bezier(0.250, 0.100, 0.250, 1.000)",linear:"cubic-bezier(0.250, 0.250, 0.750, 0.750)",easeIn:"cubic-bezier(0.420, 0.000, 1.000, 1.000)",easeOut:"cubic-bezier(0.000, 0.000, 0.580, 1.000)",easeInOut:"cubic-bezier(0.420, 0.000, 0.580, 1.000)",elasticInOut:"cubic-bezier(0.5,-0.58,0.38,1.81)",elasticIn:"cubic-bezier(0.17,0.67,0.59,1.81)",elasticOut:"cubic-bezier(0.7,-0.75,0.99,1.01)"},r}var e;return X$(t,n),e=t,t.prototype.animate=function(i,r){var s=this.getModel(r=r||{});if("string"==typeof i)for(var a=0,l=Array.prototype.slice.call(we(i,document));a0?r-1:0,i+=e=-1!==e?"-"+e:"-"+r}return this.controlParent!==this.parentObj&&(i=this.parentObj.getParentKey()+"."+this.propName+e),i},n}(),J$=["grid","pivotview","treegrid","spreadsheet","rangeNavigator","DocumentEditor","listbox","inplaceeditor","PdfViewer","richtexteditor","DashboardLayout","chart","stockChart","circulargauge","diagram","heatmap","lineargauge","maps","slider","smithchart","barcode","sparkline","treemap","bulletChart","kanban","daterangepicker","schedule","gantt","signature","query-builder","drop-down-tree","carousel","filemanager","uploader","accordion","tab","treeview"],tR=[115,121,110,99,102,117,115,105,111,110,46,105,115,76,105,99,86,97,108,105,100,97,116,101,100],iR=function(){function n(t){this.isValidated=!1,this.isLicensed=!0,this.version="27",this.platform=/JavaScript|ASPNET|ASPNETCORE|ASPNETMVC|FileFormats|essentialstudio/i,this.errors={noLicense:"This application was built using a trial version of Syncfusion Essential Studio. To remove the license validation message permanently, a valid license key must be included.",trailExpired:"This application was built using a trial version of Syncfusion Essential Studio. To remove the license validation message permanently, a valid license key must be included.",versionMismatched:"The included Syncfusion license key is invalid.",platformMismatched:"The included Syncfusion license key is invalid.",invalidKey:"The included Syncfusion license key is invalid."},this.manager=function(){var e=null;return{setKey:function i(s){e=s},getKey:function r(){return e}}}(),this.npxManager=function(){return{getKey:function i(){return"npxKeyReplace"}}}(),this.manager.setKey(t)}return n.prototype.validate=function(){if(!this.isValidated&&nf&&!Y(A0(tR),nf)&&!Y("Blazor",nf)){var i=void 0,r=void 0;if(this.manager&&this.manager.getKey()||this.npxManager&&"npxKeyReplace"!==this.npxManager.getKey()){var s=this.getInfoFromKey();if(s&&s.length)for(var o=0,a=s;o"+i+' Claim your FREE account\n
have a Syncfusion account? Sign In
\n
\n ';if(typeof document<"u"&&!m(document)){var t=Si("div",{innerHTML:n});document.body.appendChild(t)}}(),oR=!0),this.render(),this.mount?this.accessMount():this.trigger("created")}},t.prototype.renderComplete=function(e){ce()&&window.sfBlazor.renderComplete(this.element,e),this.isRendered=!0},t.prototype.dataBind=function(){this.injectModules(),n.prototype.dataBind.call(this)},t.prototype.on=function(e,i,r){if("string"==typeof e)this.localObserver.on(e,i,r);else for(var s=0,o=e;s=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},rZ={left:0,top:0,bottom:0,right:0},MC={isDragged:!1},nZ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return aR(t,n),gr([I(0)],t.prototype,"left",void 0),gr([I(0)],t.prototype,"top",void 0),t}(Ee),hf=function(n){function t(i,r){var s=n.call(this,r,i)||this;return s.dragLimit=e.getDefaultPosition(),s.borderWidth=e.getDefaultPosition(),s.padding=e.getDefaultPosition(),s.diffX=0,s.prevLeft=0,s.prevTop=0,s.dragProcessStarted=!1,s.eleTop=0,s.tapHoldTimer=0,s.externalInitialize=!1,s.diffY=0,s.parentScrollX=0,s.parentScrollY=0,s.droppables={},s.bind(),s}var e;return aR(t,n),e=t,t.prototype.bind=function(){this.toggleEvents(),X.isIE&&V([this.element],"e-block-touch"),this.droppables[this.scope]={}},t.getDefaultPosition=function(){return ze({},rZ)},t.prototype.toggleEvents=function(i){var r;st(this.handle)||(r=_(this.handle,this.element));var s=this.enableTapHold&&X.isDevice&&X.isTouch?this.mobileInitialize:this.initialize;i?E.remove(r||this.element,X.isSafari()?"touchstart":X.touchStartEvent,s):E.add(r||this.element,X.isSafari()?"touchstart":X.touchStartEvent,s,this)},t.prototype.mobileInitialize=function(i){var r=this,s=i.currentTarget;this.tapHoldTimer=setTimeout(function(){r.externalInitialize=!0,r.removeTapholdTimer(),r.initialize(i,s)},this.tapHoldThreshold),E.add(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.removeTapholdTimer,this),E.add(document,X.isSafari()?"touchend":X.touchEndEvent,this.removeTapholdTimer,this)},t.prototype.removeTapholdTimer=function(){clearTimeout(this.tapHoldTimer),E.remove(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.removeTapholdTimer),E.remove(document,X.isSafari()?"touchend":X.touchEndEvent,this.removeTapholdTimer)},t.prototype.getScrollableParent=function(i,r){return m(i)?null:i[{vertical:"scrollHeight",horizontal:"scrollWidth"}[""+r]]>i[{vertical:"clientHeight",horizontal:"clientWidth"}[""+r]]&&("vertical"===r?i.scrollTop>0:i.scrollLeft>0)?("vertical"===r?(this.parentScrollY=this.parentScrollY+(0===this.parentScrollY?i.scrollTop:i.scrollTop-this.parentScrollY),this.tempScrollHeight=i.scrollHeight):(this.parentScrollX=this.parentScrollX+(0===this.parentScrollX?i.scrollLeft:i.scrollLeft-this.parentScrollX),this.tempScrollWidth=i.scrollWidth),m(i)?i:this.getScrollableParent(i.parentNode,r)):this.getScrollableParent(i.parentNode,r)},t.prototype.getScrollableValues=function(){this.parentScrollX=0,this.parentScrollY=0,this.element.classList.contains("e-dialog")&&this.element.classList.contains("e-dlg-modal"),this.getScrollableParent(this.element.parentNode,"vertical"),this.getScrollableParent(this.element.parentNode,"horizontal")},t.prototype.initialize=function(i,r){if(this.currentStateTarget=i.target,!this.isDragStarted()){if(this.isDragStarted(!0),this.externalInitialize=!1,this.target=i.currentTarget||r,this.dragProcessStarted=!1,this.abort){var s=this.abort;"string"==typeof s&&(s=[s]);for(var o=0;o=this.distance||this.externalInitialize){var f=this.getHelperElement(i);if(!f||m(f))return;r&&i.preventDefault();var p=this.helperElement=f;if(this.parentClientRect=this.calculateParentPosition(p.offsetParent),this.dragStart){var v={event:i,element:l,target:this.getProperTargetElement(i),bindEvents:ce()?this.bindDragEvents.bind(this):null,dragElement:p};this.trigger("dragStart",v)}this.dragArea?this.setDragArea():(this.dragLimit={left:0,right:0,bottom:0,top:0},this.borderWidth={top:0,left:0}),o={left:this.position.left-this.parentClientRect.left,top:this.position.top-this.parentClientRect.top},this.clone&&!this.enableTailMode&&(this.diffX=this.position.left-this.offset.left,this.diffY=this.position.top-this.offset.top),this.getScrollableValues();var y=getComputedStyle(l),S=parseFloat(y.marginTop);this.clone&&0!==S&&(o.top+=S),this.eleTop=isNaN(parseFloat(y.top))?0:parseFloat(y.top)-this.offset.top,this.enableScrollHandler&&!this.clone&&(o.top-=this.parentScrollY,o.left-=this.parentScrollX);var b=this.getProcessedPositionValue({top:o.top-this.diffY+"px",left:o.left-this.diffX+"px"});this.dragArea&&"string"!=typeof this.dragArea&&this.dragArea.classList.contains("e-kanban-content")&&"relative"===this.dragArea.style.position&&(o.top+=this.dragArea.scrollTop),this.dragElePosition={top:o.top,left:o.left},je(p,this.getDragPosition({position:"absolute",left:b.left,top:b.top})),E.remove(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.intDragStart),E.remove(document,X.isSafari()?"touchend":X.touchEndEvent,this.intDestroy),ce()||this.bindDragEvents(p)}}},t.prototype.bindDragEvents=function(i){Tr(i)?(E.add(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.intDrag,this),E.add(document,X.isSafari()?"touchend":X.touchEndEvent,this.intDragStop,this),this.setGlobalDroppables(!1,this.element,i)):(this.toggleEvents(),document.body.classList.remove("e-prevent-select"))},t.prototype.elementInViewport=function(i){for(this.top=i.offsetTop,this.left=i.offsetLeft,this.width=i.offsetWidth,this.height=i.offsetHeight;i.offsetParent;)this.top+=(i=i.offsetParent).offsetTop,this.left+=i.offsetLeft;return this.top>=window.pageYOffset&&this.left>=window.pageXOffset&&this.top+this.height<=window.pageYOffset+window.innerHeight&&this.left+this.width<=window.pageXOffset+window.innerWidth},t.prototype.getProcessedPositionValue=function(i){return this.queryPositionInfo?this.queryPositionInfo(i):i},t.prototype.calculateParentPosition=function(i){if(m(i))return{left:0,top:0};var r=i.getBoundingClientRect(),s=getComputedStyle(i);return{left:r.left+window.pageXOffset-parseInt(s.marginLeft,10),top:r.top+window.pageYOffset-parseInt(s.marginTop,10)}},t.prototype.intDrag=function(i){if(st(i.changedTouches)||1===i.changedTouches.length){var r,s;this.clone&&i.changedTouches&&X.isDevice&&X.isTouch&&i.preventDefault(),this.position=this.getMousePosition(i,this.isDragScroll);var o=this.getDocumentWidthHeight("Height");oy&&y>0?this.dragLimit.left:this.dragLimit.right+window.pageXOffset0?y-(y-this.dragLimit.right)+window.pageXOffset-M:y<0?this.dragLimit.left:y}if(this.pageY!==v||this.skipDistanceCheck){var w=d.offsetHeight+(parseFloat(b.marginTop)+parseFloat(b.marginBottom));s=this.dragLimit.top>S&&S>0?this.dragLimit.top:this.dragLimit.bottom+window.pageYOffset0?S-(S-this.dragLimit.bottom)+window.pageYOffset-w:S<0?this.dragLimit.top:S}}else r=y,s=S;var A,x,C=f+this.borderWidth.top,D=u+this.borderWidth.left;if(this.dragProcessStarted&&(m(s)&&(s=this.prevTop),m(r)&&(r=this.prevLeft)),this.helperElement.classList.contains("e-treeview"))this.dragArea?(this.dragLimit.top=this.clone?this.dragLimit.top:0,A=s-C<0?this.dragLimit.top:s-this.borderWidth.top,x=r-D<0?this.dragLimit.left:r-this.borderWidth.left):(A=s-this.borderWidth.top,x=r-this.borderWidth.left);else if(this.dragArea){var P=this.helperElement.classList.contains("e-dialog");this.dragLimit.top=this.clone?this.dragLimit.top:0,A=s-C<0?this.dragLimit.top:s-C,x=r-D<0?P?r-(D-this.borderWidth.left):this.dragElePosition.left:r-D}else A=s-C,x=r-D;var L=parseFloat(getComputedStyle(this.element).marginTop);if(L>0&&(this.clone&&(A+=L,S<0&&(L+S>=0?A=L+S:A-=L),this.dragArea&&(A=this.dragLimit.bottom=0){var O=this.dragLimit.top+S-C;O+L+C<0?A-=L+C:A=O}else A-=L+C;this.dragArea&&this.helperElement.classList.contains("e-treeview")&&(A=A+(w=d.offsetHeight+(parseFloat(b.marginTop)+parseFloat(b.marginBottom)))>this.dragLimit.bottom?this.dragLimit.bottom-w:A),this.enableScrollHandler&&!this.clone&&(A-=this.parentScrollY,x-=this.parentScrollX),this.dragArea&&"string"!=typeof this.dragArea&&this.dragArea.classList.contains("e-kanban-content")&&"relative"===this.dragArea.style.position&&(A+=this.dragArea.scrollTop);var N=this.getProcessedPositionValue({top:A+"px",left:x+"px"});this.isPreventScroll&&(N=this.getProcessedPositionValue({top:this.position.top-this.parentClientRect.top-2+"px",left:this.position.left-this.parentClientRect.left-2+"px"})),je(d,this.getDragPosition(N)),!this.elementInViewport(d)&&this.enableAutoScroll&&!this.helperElement.classList.contains("e-treeview")&&this.helperElement.scrollIntoView();var T=document.querySelectorAll(":hover");if(this.enableAutoScroll&&this.helperElement.classList.contains("e-treeview")){0===T.length&&(T=this.getPathElements(i));var z=this.getScrollParent(T,!1);this.elementInViewport(this.helperElement)?this.getScrollPosition(z,A):this.elementInViewport(this.helperElement)||(0===(T=[].slice.call(document.querySelectorAll(":hover"))).length&&(T=this.getPathElements(i)),z=this.getScrollParent(T,!0),this.getScrollPosition(z,A))}this.dragProcessStarted=!0,this.prevLeft=r,this.prevTop=s,this.position.left=r,this.position.top=s,this.pageX=g,this.pageY=v}},t.prototype.getScrollParent=function(i,r){for(var o,s=r?i.reverse():i,a=s.length-1;a>=0;a--)if(("auto"===(o=window.getComputedStyle(s[parseInt(a.toString(),10)])["overflow-y"])||"scroll"===o)&&s[parseInt(a.toString(),10)].scrollHeight>s[parseInt(a.toString(),10)].clientHeight)return s[parseInt(a.toString(),10)];if("visible"===(o=window.getComputedStyle(document.scrollingElement)["overflow-y"]))return document.scrollingElement.style.overflow="auto",document.scrollingElement},t.prototype.getScrollPosition=function(i,r){if(i&&i===document.scrollingElement)i.clientHeight+document.scrollingElement.scrollTop-this.helperElement.clientHeightr?i.scrollTop+=this.helperElement.clientHeight:i.scrollTop>r-this.helperElement.clientHeight&&(i.scrollTop-=this.helperElement.clientHeight);else if(i&&i!==document.scrollingElement){var s=document.scrollingElement.scrollTop,o=this.helperElement.clientHeight;i.clientHeight+i.getBoundingClientRect().top-o+sr-o-s&&(i.scrollTop-=this.helperElement.clientHeight)}},t.prototype.getPathElements=function(i){return document.elementsFromPoint(i.clientX>0?i.clientX:0,i.clientY>0?i.clientY:0)},t.prototype.triggerOutFunction=function(i,r){this.hoverObject.instance.intOut(i,r.target),this.hoverObject.instance.dragData[this.scope]=null,this.hoverObject=null},t.prototype.getDragPosition=function(i){var r=ze({},i);return this.axis&&("x"===this.axis?delete r.top:"y"===this.axis&&delete r.left),r},t.prototype.getDocumentWidthHeight=function(i){var r=document.body,s=document.documentElement;return Math.max(r["scroll"+i],s["scroll"+i],r["offset"+i],s["offset"+i],s["client"+i])},t.prototype.intDragStop=function(i){if(this.dragProcessStarted=!1,st(i.changedTouches)||1===i.changedTouches.length){if(-1!==["touchend","pointerup","mouseup"].indexOf(i.type)){if(this.dragStop){var s=this.getProperTargetElement(i);this.trigger("dragStop",{event:i,element:this.element,target:s,helper:this.helperElement})}this.intDestroy(i)}else this.element.setAttribute("aria-grabbed","false");var o=this.checkTargetElement(i);o.target&&o.instance&&(o.instance.dragStopCalled=!0,o.instance.dragData[this.scope]=this.droppables[this.scope],o.instance.intDrop(i,o.target)),this.setGlobalDroppables(!0),document.body.classList.remove("e-prevent-select")}},t.prototype.intDestroy=function(i){this.dragProcessStarted=!1,this.toggleEvents(),document.body.classList.remove("e-prevent-select"),this.element.setAttribute("aria-grabbed","false"),E.remove(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.intDragStart),E.remove(document,X.isSafari()?"touchend":X.touchEndEvent,this.intDragStop),E.remove(document,X.isSafari()?"touchend":X.touchEndEvent,this.intDestroy),E.remove(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.intDrag),this.isDragStarted()&&this.isDragStarted(!0)},t.prototype.onPropertyChanged=function(i,r){},t.prototype.getModuleName=function(){return"draggable"},t.prototype.isDragStarted=function(i){return i&&(MC.isDragged=!MC.isDragged),MC.isDragged},t.prototype.setDragArea=function(){var i,r,a,s=0,o=0;if(a="string"==typeof this.dragArea?_(this.dragArea):this.dragArea){var h=a.getBoundingClientRect();i=a.scrollWidth?a.scrollWidth:h.right-h.left,r=a.scrollHeight?this.dragArea&&!m(this.helperElement)&&this.helperElement.classList.contains("e-treeview")?a.clientHeight:a.scrollHeight:h.bottom-h.top;for(var c=["Top","Left","Bottom","Right"],d=getComputedStyle(a),u=0;u12;return E0(i.target,this.helperElement)||-1!==i.type.indexOf("touch")||a?(this.helperElement.style.pointerEvents="none",s=document.elementFromPoint(r.clientX,r.clientY),this.helperElement.style.pointerEvents=o):s=i.target,s},t.prototype.currentStateCheck=function(i,r){return m(this.currentStateTarget)||this.currentStateTarget===i?m(r)?i:r:this.currentStateTarget},t.prototype.getMousePosition=function(i,r){var a,l,s=void 0!==i.srcElement?i.srcElement:i.target,o=this.getCoordinates(i),h=m(s.offsetParent);if(r?(a=this.clone?o.pageX:o.pageX+(h?0:s.offsetParent.scrollLeft)-this.relativeXPosition,l=this.clone?o.pageY:o.pageY+(h?0:s.offsetParent.scrollTop)-this.relativeYPosition):(a=this.clone?o.pageX:o.pageX+window.pageXOffset-this.relativeXPosition,l=this.clone?o.pageY:o.pageY+window.pageYOffset-this.relativeYPosition),document.scrollingElement&&!r&&!this.clone){var c=document.scrollingElement;a=c.scrollWidth>0&&c.scrollWidth>c.clientWidth&&c.scrollLeft>0?a-c.scrollLeft:a,l=c.scrollHeight>0&&c.scrollHeight>c.clientHeight&&c.scrollTop>0?l-c.scrollTop:l}return{left:a-(this.margin.left+this.cursorAt.left),top:l-(this.margin.top+this.cursorAt.top)}},t.prototype.getCoordinates=function(i){return i.type.indexOf("touch")>-1?i.changedTouches[0]:i},t.prototype.getHelperElement=function(i){var r;return this.clone?this.helper?r=this.helper({sender:i,element:this.target}):(r=Si("div",{className:"e-drag-helper e-block-touch",innerHTML:"Draggable"}),document.body.appendChild(r)):r=this.element,r},t.prototype.setGlobalDroppables=function(i,r,s){this.droppables[this.scope]=i?null:{draggable:r,helper:s,draggedElement:this.element}},t.prototype.checkTargetElement=function(i){var r=this.getProperTargetElement(i),s=this.getDropInstance(r);if(!s&&r&&!m(r.parentNode)){var o=J(r.parentNode,".e-droppable")||r.parentElement;o&&(s=this.getDropInstance(o))}return{target:r,instance:s}},t.prototype.getDropInstance=function(i){var s,o=i&&i.ej2_instances;if(o)for(var a=0,l=o;a=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},lR=function(n){function t(e,i){var r=n.call(this,i,e)||this;return r.mouseOver=!1,r.dragData={},r.dragStopCalled=!1,r.bind(),r}return sZ(t,n),t.prototype.bind=function(){this.wireEvents()},t.prototype.wireEvents=function(){E.add(this.element,X.isSafari()?"touchend":X.touchEndEvent,this.intDrop,this)},t.prototype.onPropertyChanged=function(e,i){},t.prototype.getModuleName=function(){return"droppable"},t.prototype.intOver=function(e,i){this.mouseOver||(this.trigger("over",{event:e,target:i,dragData:this.dragData[this.scope]}),this.mouseOver=!0)},t.prototype.intOut=function(e,i){this.mouseOver&&(this.trigger("out",{evt:e,target:i}),this.mouseOver=!1)},t.prototype.intDrop=function(e,i){if(this.dragStopCalled){this.dragStopCalled=!1;var a,r=!0,s=this.dragData[this.scope],o=!!s&&s.helper&&Tr(s.helper);o&&(a=this.isDropArea(e,s.helper,i),this.accept&&(r=mC(s.helper,this.accept))),o&&this.drop&&a.canDrop&&r&&this.trigger("drop",{event:e,target:a.target,droppedElement:s.helper,dragData:s}),this.mouseOver=!1}},t.prototype.isDropArea=function(e,i,r){var s={canDrop:!0,target:r||e.target},o="touchend"===e.type;if(o||s.target===i){i.style.display="none";var a=o?e.changedTouches[0]:e,l=document.elementFromPoint(a.clientX,a.clientY);s.canDrop=!1,s.canDrop=E0(l,this.element),s.canDrop&&(s.target=l),i.style.display=""}return s},t.prototype.destroy=function(){E.remove(this.element,X.isSafari()?"touchend":X.touchEndEvent,this.intDrop),n.prototype.destroy.call(this)},cf([I()],t.prototype,"accept",void 0),cf([I("default")],t.prototype,"scope",void 0),cf([H()],t.prototype,"drop",void 0),cf([H()],t.prototype,"over",void 0),cf([H()],t.prototype,"out",void 0),cf([Ft],t)}(dh),uo=function(){function n(t,e,i){this.controlName=t,this.localeStrings=e,this.setLocale(i||"en-US")}return n.prototype.setLocale=function(t){var e=this.intGetControlConstant(n.locale,t);this.currentLocale=e||this.localeStrings},n.load=function(t){this.locale=ze(this.locale,t,{},!0)},n.prototype.getConstant=function(t){return m(this.currentLocale[""+t])?this.localeStrings[""+t]||"":this.currentLocale[""+t]},n.prototype.intGetControlConstant=function(t,e){return t[""+e]?t[""+e][this.controlName]:null},n.locale={},n}(),hR=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),fh=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},lZ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return hR(t,n),fh([I(50)],t.prototype,"swipeThresholdDistance",void 0),t}(Ee),hZ=/(Up|Down)/,Fs=function(n){function t(e,i){var r=n.call(this,i,e)||this;return r.touchAction=!0,r.tapCount=0,r.startEvent=function(s){if(!0===r.touchAction){var o=r.updateChangeTouches(s);void 0!==s.changedTouches&&(r.touchAction=!1),r.isTouchMoved=!1,r.movedDirection="",r.startPoint=r.lastMovedPoint={clientX:o.clientX,clientY:o.clientY},r.startEventData=o,r.hScrollLocked=r.vScrollLocked=!1,r.tStampStart=Date.now(),r.timeOutTapHold=setTimeout(function(){r.tapHoldEvent(s)},r.tapHoldThreshold),E.add(r.element,X.touchMoveEvent,r.moveEvent,r),E.add(r.element,X.touchEndEvent,r.endEvent,r),E.add(r.element,X.touchCancelEvent,r.cancelEvent,r)}},r.moveEvent=function(s){var o=r.updateChangeTouches(s);r.movedPoint=o,r.isTouchMoved=!(o.clientX===r.startPoint.clientX&&o.clientY===r.startPoint.clientY);var a={};r.isTouchMoved&&(clearTimeout(r.timeOutTapHold),r.calcScrollPoints(s),a=ze(a,{},{startEvents:r.startEventData,originalEvent:s,startX:r.startPoint.clientX,startY:r.startPoint.clientY,distanceX:r.distanceX,distanceY:r.distanceY,scrollDirection:r.scrollDirection,velocity:r.getVelocity(o)}),r.trigger("scroll",a),r.lastMovedPoint={clientX:o.clientX,clientY:o.clientY})},r.cancelEvent=function(s){clearTimeout(r.timeOutTapHold),clearTimeout(r.timeOutTap),r.tapCount=0,r.swipeFn(s),E.remove(r.element,X.touchCancelEvent,r.cancelEvent)},r.endEvent=function(s){r.swipeFn(s),r.isTouchMoved||"function"==typeof r.tap&&(r.trigger("tap",{originalEvent:s,tapCount:++r.tapCount}),r.timeOutTap=setTimeout(function(){r.tapCount=0},r.tapThreshold)),r.modeclear()},r.swipeFn=function(s){clearTimeout(r.timeOutTapHold),clearTimeout(r.timeOutTap);var o=r.updateChangeTouches(s),a=o.clientX-r.startPoint.clientX,l=o.clientY-r.startPoint.clientY;a=Math.floor(a<0?-1*a:a),l=Math.floor(l<0?-1*l:a),r.isTouchMoved=a>1||l>1,/Firefox/.test(X.userAgent)&&0===o.clientX&&0===o.clientY&&"mouseup"===s.type&&(r.isTouchMoved=!1),r.endPoint=o,r.calcPoints(s);var c={originalEvent:s,startEvents:r.startEventData,startX:r.startPoint.clientX,startY:r.startPoint.clientY,distanceX:r.distanceX,distanceY:r.distanceY,swipeDirection:r.movedDirection,velocity:r.getVelocity(o)};if(r.isTouchMoved){var d=r.swipeSettings.swipeThresholdDistance,u=ze(void 0,r.defaultArgs,c),f=!1,p=r.element,g=r.isScrollable(p),v=hZ.test(r.movedDirection);(dthis.distanceY?i.clientX>this.startPoint.clientX?"Right":"Left":i.clientYthis.distanceY||!0===this.hScrollLocked)&&!1===this.vScrollLocked?(this.scrollDirection=i.clientX>this.lastMovedPoint.clientX?"Right":"Left",this.hScrollLocked=!0):(this.scrollDirection=i.clientY=e[r[0]+s[0]]},t.prototype.updateChangeTouches=function(e){return e.changedTouches&&0!==e.changedTouches.length?e.changedTouches[0]:e},fh([H()],t.prototype,"tap",void 0),fh([H()],t.prototype,"tapHold",void 0),fh([H()],t.prototype,"swipe",void 0),fh([H()],t.prototype,"scroll",void 0),fh([I(350)],t.prototype,"tapThreshold",void 0),fh([I(750)],t.prototype,"tapHoldThreshold",void 0),fh([re({},lZ)],t.prototype,"swipeSettings",void 0),fh([Ft],t)}(dh),cZ=new RegExp("\\n|\\r|\\s\\s+","g"),dZ=new RegExp(/'|"/g),uZ=new RegExp("if ?\\("),fZ=new RegExp("else if ?\\("),cR=new RegExp("else"),pZ=new RegExp("for ?\\("),dR=new RegExp("(/if|/for)"),gZ=new RegExp("\\((.*)\\)",""),wC=new RegExp("^[0-9]+$","g"),vZ=new RegExp("[\\w\"'.\\s+]+","g"),mZ=new RegExp('"(.*?)"',"g"),yZ=new RegExp("[\\w\"'@#$.\\s-+]+","g"),uR=new RegExp("\\${([^}]*)}","g"),SZ=/^\..*/gm,CC=/\\/gi,IZ=/\\\\/gi,bZ=new RegExp("[\\w\"'@#$.\\s+]+","g"),MZ=/\window\./gm;function df(n,t,e,i,r){return!t||wC.test(n)||-1!==i.indexOf(n.split(".")[0])||r||"true"===n||"false"===n?n:e+"."+n}function EC(n,t,e,i){return t&&!wC.test(n)&&-1===i.indexOf(n.split(".")[0])?e+'["'+n:n}function fR(n){return n.match(IZ)?n:n.replace(CC,"\\\\")}function pR(n,t,e,i){if(n=n.trim(),/\window\./gm.test(n))return n;var s=/'|"/gm;return/@|\$|#/gm.test(n)&&(n=EC(n,-1===e.indexOf(n),t,e)+'"]'),SZ.test(n)?function EZ(n,t,e,i){return!t||wC.test(n)||-1!==i.indexOf(n.split(".")[0])||/^\..*/gm.test(n)?n:e+"."+n}(n,!s.test(n)&&-1===e.indexOf(n),t,e):df(n,!s.test(n)&&-1===e.indexOf(n),t,e,i)}var DZ=/^[\n\r.]+0&&t.forEach(function(e){he(e)})},n.removeJsEvents=function(){var t=this.wrapElement.querySelectorAll("["+vR.join("],[")+"]");t.length>0&&t.forEach(function(e){vR.forEach(function(i){e.hasAttribute(i)&&e.removeAttribute(i)})})},n.removeXssAttrs=function(){var t=this;this.removeAttrs.forEach(function(e,i){var r=t.wrapElement.querySelectorAll(e.selector);r.length>0&&r.forEach("a[href]"===e.selector?function(s){-1!==s.getAttribute(e.attribute).replace(/\t|\s|&/,"").indexOf("javascript:alert")&&s.removeAttribute(e.attribute)}:function(s){s.removeAttribute(e.attribute)})})},n}();function PZ(n){return function(t){!function kZ(n,t){t.forEach(function(e){Object.getOwnPropertyNames(e.prototype).forEach(function(i){(!Object.prototype.hasOwnProperty.call(n.prototype,i)||e.isFormBase&&"constructor"!==i)&&(n.prototype["".concat(i)]=e.prototype["".concat(i)])})})}(t,n)}}function mR(n,t,e){var i={};if(n&&n.length){for(var r=0,s=n;r"u"||(y.innerHTML=v.innerHTML?v.innerHTML:"",void 0!==v.className&&(y.className=v.className),void 0!==v.id&&(y.id=v.id),void 0!==v.styles&&y.setAttribute("style",v.styles),void 0!==e.ngAttr&&y.setAttribute(e.ngAttr,""),void 0!==v.attrs&&Fe(y,v.attrs)),y};for(var i=0,r=e.tags;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s}function jZ(n){for(var t,e=n.childNodes,i=0;i"u"&&(c["".concat(o)]=[]),c["".concat(o)].push(h),h.rootNodes}}});var Sl,hd,mh,Wg,oc,po,YZ=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Na=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Jo_RTL=(new Ng,"e-rtl"),ys=function(n){function t(e,i){return n.call(this,e,i)||this}return YZ(t,n),t.prototype.preRender=function(){},t.prototype.render=function(){this.initialize(),this.removeRippleEffect=function ms(n,t,e){var i=function q$(n){return{selector:n&&n.selector?n.selector:null,ignore:n&&n.ignore?n.ignore:null,rippleFlag:n&&n.rippleFlag,isCenterRipple:n&&n.isCenterRipple,duration:n&&n.duration?n.duration:350}}(t);return!1===i.rippleFlag||void 0===i.rippleFlag&&!Zo?function(){}:(n.setAttribute("data-ripple","true"),E.add(n,"mousedown",Zz,{parent:n,rippleOptions:i}),E.add(n,"mouseup",Jz,{parent:n,rippleOptions:i,done:e}),E.add(n,"mouseleave",lf,{parent:n,rippleOptions:i}),X.isPointer&&E.add(n,"transitionend",lf,{parent:n,rippleOptions:i}),function(){n.removeAttribute("data-ripple"),E.remove(n,"mousedown",Zz),E.remove(n,"mouseup",Jz),E.remove(n,"mouseleave",lf),E.remove(n,"transitionend",lf)})}(this.element,{selector:".e-btn"}),this.renderComplete()},t.prototype.initialize=function(){if(this.cssClass&&V([this.element],this.cssClass.replace(/\s+/g," ").trim().split(" ")),this.isPrimary&&this.element.classList.add("e-primary"),!ce()||ce()&&"progress-btn"!==this.getModuleName()){if(this.content){var e=this.enableHtmlSanitizer?Ai.sanitize(this.content):this.content;this.element.innerHTML=e}this.setIconCss()}this.enableRtl&&this.element.classList.add(Jo_RTL),this.disabled?this.controlStatus(this.disabled):this.wireEvents()},t.prototype.controlStatus=function(e){this.element.disabled=e},t.prototype.setIconCss=function(){if(this.iconCss){var e=this.createElement("span",{className:"e-btn-icon "+this.iconCss});this.element.textContent.trim()?(e.classList.add("e-icon-"+this.iconPosition.toLowerCase()),("Top"===this.iconPosition||"Bottom"===this.iconPosition)&&this.element.classList.add("e-"+this.iconPosition.toLowerCase()+"-icon-btn")):this.element.classList.add("e-icon-btn");var i=this.element.childNodes[0];!i||"Left"!==this.iconPosition&&"Top"!==this.iconPosition?this.element.appendChild(e):this.element.insertBefore(e,i)}},t.prototype.wireEvents=function(){this.isToggle&&E.add(this.element,"click",this.btnClickHandler,this)},t.prototype.unWireEvents=function(){this.isToggle&&E.remove(this.element,"click",this.btnClickHandler)},t.prototype.btnClickHandler=function(){this.element.classList.contains("e-active")?this.element.classList.remove("e-active"):this.element.classList.add("e-active")},t.prototype.destroy=function(){var e=["e-primary",Jo_RTL,"e-icon-btn","e-success","e-info","e-danger","e-warning","e-flat","e-outline","e-small","e-bigger","e-active","e-round","e-top-icon-btn","e-bottom-icon-btn"];this.cssClass&&(e=e.concat(this.cssClass.split(" "))),n.prototype.destroy.call(this),K([this.element],e),this.element.getAttribute("class")||this.element.removeAttribute("class"),this.disabled&&this.element.removeAttribute("disabled"),this.content&&(this.element.innerHTML=this.element.innerHTML.replace(this.content,""));var i=this.element.querySelector("span.e-btn-icon");i&&he(i),this.unWireEvents(),Zo&&this.removeRippleEffect()},t.prototype.getModuleName=function(){return"btn"},t.prototype.getPersistData=function(){return this.addOnPersist([])},t.Inject=function(){},t.prototype.onPropertyChanged=function(e,i){for(var r=this.element.querySelector("span.e-btn-icon"),s=0,o=Object.keys(e);s=hd.width?hd.width:0;return Sl.right+JR()-n}function uE(){return j0()+Sl.width/2}function fE(n,t,e,i){if(void 0===t&&(t=null),void 0===e&&(e={X:!1,Y:!1}),!e.Y&&!e.X)return{left:0,top:0};var r=n.getBoundingClientRect();if(po=t,oc=n.ownerDocument,i||(i=ns(n,"left","top")),e.X){var s=po?r4():l4(),o=yE(),a=SE(),l=o-i.left,h=i.left+r.width-a;r.width>s?i.left=l>0&&h<=0?a-r.width:h>0&&l<=0?o:l>h?a-r.width:o:l>0?i.left+=l:h>0&&(i.left-=h)}if(e.Y){var c=po?n4():a4(),d=mE(),u=IE(),f=d-i.top,p=i.top+r.height-u;r.height>c?i.top=f>0&&p<=0?u-r.height:p>0&&f<=0?d:f>p?u-r.height:d:f>0?i.top+=f:p>0&&(i.top-=p)}return i}function ac(n,t,e,i){void 0===t&&(t=null);var r=ns(n,"left","top");e&&(r.left=e),i&&(r.top=i);var s=[];po=t,oc=n.ownerDocument;var o=n.getBoundingClientRect(),l=r.left,h=r.left+o.width,d=vE(r.top,r.top+o.height),u=e4(l,h);return d.topSide&&s.push("top"),u.rightSide&&s.push("right"),u.leftSide&&s.push("left"),d.bottomSide&&s.push("bottom"),s}function bJ(n,t,e,i,r,s,o,a,l){if(void 0===o&&(o=null),void 0===a&&(a={X:!0,Y:!0}),t&&n&&r&&s&&(a.X||a.Y)){var d,h={TL:null,TR:null,BL:null,BR:null},c={TL:null,TR:null,BL:null,BR:null};if("none"===window.getComputedStyle(n).display){var u=n.style.visibility;n.style.visibility="hidden",n.style.display="block",d=n.getBoundingClientRect(),n.style.removeProperty("display"),n.style.visibility=u}else d=n.getBoundingClientRect();var f={posX:r,posY:s,offsetX:e,offsetY:i,position:{left:0,top:0}};po=o,oc=t.ownerDocument,function wJ(n,t,e,i,r){e.position=ns(n,e.posX,e.posY,i,r),t.TL=ns(n,"left","top",i,r),t.TR=ns(n,"right","top",i,r),t.BR=ns(n,"left","bottom",i,r),t.BL=ns(n,"right","bottom",i,r)}(t,h,f,l,d),gE(c,f,d),a.X&&t4(t,c,h,f,d,!0),a.Y&&h.TL.top>-1&&i4(t,c,h,f,d,!0),function MJ(n,t,e){var i=0,r=0;if(null!=n.offsetParent&&("absolute"===getComputedStyle(n.offsetParent).position||"relative"===getComputedStyle(n.offsetParent).position)){var s=ns(n.offsetParent,"left","top",!1,e);i=s.left,r=s.top}var o=1,a=1,l=KR(n);if(l){var h=getComputedStyle(l).transform;if("none"!==h){var c=new DOMMatrix(h);o=c.a,a=c.d}if("none"!==getComputedStyle(l).zoom){var u=pE(document.body);o*=u,a*=u}}n.style.top=t.position.top/a+t.offsetY-r/a+"px",n.style.left=t.position.left/o+t.offsetX-i/o+"px"}(n,f,d)}}function pE(n){var t=getComputedStyle(n).zoom;return parseFloat(t)||1}function KR(n){for(;n;){var t=window.getComputedStyle(n).transform,e=pE(document.body);if(t&&"none"!==t||e&&1!==e)return n;if(n===document.body)return null;n=n.offsetParent||n.parentElement}return null}function gE(n,t,e){n.TL={top:t.position.top+t.offsetY,left:t.position.left+t.offsetX},n.TR={top:n.TL.top,left:n.TL.left+e.width},n.BL={top:n.TL.top+e.height,left:n.TL.left},n.BR={top:n.TL.top+e.height,left:n.TL.left+e.width}}function e4(n,t){var e=!1,i=!1;return n-W0()SE()&&(i=!0),{leftSide:e,rightSide:i}}function t4(n,t,e,i,r,s){var o=e4(t.TL.left,t.TR.left),a=vE(t.TL.top,t.BL.top);e.TL.left-W0()<=yE()&&(o.leftSide=!1),e.TR.left>SE()&&(o.rightSide=!1),(o.leftSide&&!o.rightSide||!o.leftSide&&o.rightSide)&&(i.posX="right"===i.posX?"left":"right",i.offsetX=i.offsetX+r.width,i.offsetX=-1*i.offsetX,i.position=ns(n,i.posX,i.posY,!1),gE(t,i,r),s&&t4(n,t,e,i,r,!1),!o.leftSide&&o.rightSide&&a.bottomSide&&(i.offsetX=0))}function i4(n,t,e,i,r,s){var o=vE(t.TL.top,t.BL.top);e.TL.top-V0()<=mE()&&(o.topSide=!1),e.BL.top>=IE()&&n.getBoundingClientRect().bottomIE()&&(i=!0),{topSide:e,bottomSide:i}}function r4(){return po.getBoundingClientRect().width}function n4(){return po.getBoundingClientRect().height}function s4(){return po.getBoundingClientRect().left}function o4(){return po.getBoundingClientRect().top}function mE(){return po?o4():0}function yE(){return po?s4():0}function SE(){return po?W0()+s4()+r4():W0()+l4()}function IE(){return po?V0()+o4()+n4():V0()+a4()}function V0(){return oc.documentElement.scrollTop||oc.body.scrollTop}function W0(){return oc.documentElement.scrollLeft||oc.body.scrollLeft}function a4(){return window.innerHeight}function l4(){var n=window.innerWidth,t=document.documentElement.getBoundingClientRect();return n-(n-(m(document.documentElement)?0:t.width))}function h4(){po=null,oc=null}var c4=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),bn=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},d4=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return c4(t,n),bn([I("left")],t.prototype,"X",void 0),bn([I("top")],t.prototype,"Y",void 0),t}(Ee),qn_OPEN="e-popup-open",qn_CLOSE="e-popup-close",lc=function(n){function t(e,i){return n.call(this,i,e)||this}return c4(t,n),t.prototype.onPropertyChanged=function(e,i){for(var r=0,s=Object.keys(e);r0&&c.left>0&&c.right>0&&c.bottom>0}var s=i.getBoundingClientRect();return!(r.bottoms.bottom||r.right>s.right||r.leftr.top?this.element.style.top="0px":s.bottomr.left&&(this.element.style.left=parseInt(this.element.style.left,10)+(s.left-r.left)+"px"))}},t.prototype.checkCollision=function(){var e=this.collision.X,i=this.collision.Y;"none"===e&&"none"===i||("flip"===e&&"flip"===i?this.callFlip({X:!0,Y:!0}):"fit"===e&&"fit"===i?this.callFit({X:!0,Y:!0}):("flip"===e?this.callFlip({X:!0,Y:!1}):"flip"===i&&this.callFlip({Y:!0,X:!1}),"fit"===e?this.callFit({X:!0,Y:!1}):"fit"===i&&this.callFit({X:!1,Y:!0})))},t.prototype.show=function(e,i){var r=this;if(this.getRelateToElement().classList.contains("e-filemanager")&&(this.fmDialogContainer=this.element.getElementsByClassName("e-file-select-wrap")[0]),this.wireEvents(),!m(this.fmDialogContainer)&&X.isIos&&(this.fmDialogContainer.style.display="block"),1e3===this.zIndex||!m(i)){var o=m(i)?this.element:i;this.zIndex=hc(o),je(this.element,{zIndex:this.zIndex})}e=m(e)||"object"!=typeof e?this.showAnimation:e,("none"!==this.collision.X||"none"!==this.collision.Y)&&(K([this.element],qn_CLOSE),V([this.element],qn_OPEN),this.checkCollision(),K([this.element],qn_OPEN),V([this.element],qn_CLOSE)),m(e)?(K([this.element],qn_CLOSE),V([this.element],qn_OPEN),this.trigger("open")):(e.begin=function(){r.isDestroyed||(K([r.element],qn_CLOSE),V([r.element],qn_OPEN))},e.end=function(){r.isDestroyed||r.trigger("open")},new Hs(e).animate(this.element))},t.prototype.hide=function(e){var i=this;e=m(e)||"object"!=typeof e?this.hideAnimation:e,m(e)?(K([this.element],qn_OPEN),V([this.element],qn_CLOSE),this.trigger("close")):(e.end=function(){i.isDestroyed||(K([i.element],qn_OPEN),V([i.element],qn_CLOSE),i.trigger("close"))},new Hs(e).animate(this.element)),this.unwireEvents()},t.prototype.getScrollableParent=function(e){return this.checkFixedParent(e),function bE(n,t){for(var e=getComputedStyle(n),i=[],r=/(auto|scroll)/,s=n.parentElement;s&&"HTML"!==s.tagName;){var o=getComputedStyle(s);!("absolute"===e.position&&"static"===o.position)&&r.test(o.overflow+o.overflowY+o.overflowX)&&i.push(s),s=s.parentElement}return t||i.push(document),i}(e,this.fixedParent)},t.prototype.checkFixedParent=function(e){for(var i=e.parentElement;i&&"HTML"!==i.tagName;){var r=getComputedStyle(i);("fixed"===r.position||"sticky"===r.position)&&!m(this.element)&&this.element.offsetParent&&"BODY"===this.element.offsetParent.tagName&&"hidden"!==getComputedStyle(this.element.offsetParent).overflow&&(this.element.style.top=window.scrollY>parseInt(this.element.style.top,10)?Re(window.scrollY-parseInt(this.element.style.top,10)):Re(parseInt(this.element.style.top,10)-window.scrollY),this.element.style.position="fixed",this.fixedParent=!0),i=i.parentElement,!m(this.element)&&m(this.element.offsetParent)&&"fixed"===r.position&&"fixed"===this.element.style.position&&(this.fixedParent=!0)}},bn([I("auto")],t.prototype,"height",void 0),bn([I("auto")],t.prototype,"width",void 0),bn([I(null)],t.prototype,"content",void 0),bn([I("container")],t.prototype,"targetType",void 0),bn([I(null)],t.prototype,"viewPortElement",void 0),bn([I({X:"none",Y:"none"})],t.prototype,"collision",void 0),bn([I("")],t.prototype,"relateTo",void 0),bn([re({},d4)],t.prototype,"position",void 0),bn([I(0)],t.prototype,"offsetX",void 0),bn([I(0)],t.prototype,"offsetY",void 0),bn([I(1e3)],t.prototype,"zIndex",void 0),bn([I(!1)],t.prototype,"enableRtl",void 0),bn([I("reposition")],t.prototype,"actionOnScroll",void 0),bn([I(null)],t.prototype,"showAnimation",void 0),bn([I(null)],t.prototype,"hideAnimation",void 0),bn([H()],t.prototype,"open",void 0),bn([H()],t.prototype,"close",void 0),bn([H()],t.prototype,"targetExitViewport",void 0),bn([Ft],t)}(Ii);function hc(n){for(var t=n.parentElement,e=[];t&&"BODY"!==t.tagName;){var i=document.defaultView.getComputedStyle(t,null).getPropertyValue("z-index"),r=document.defaultView.getComputedStyle(t,null).getPropertyValue("position");"auto"!==i&&"static"!==r&&e.push(i),t=t.parentElement}for(var s=[],o=0;o2147483647?2147483647:c}var Ui,ka,uf,Ih,EE,bh,$t,Mh,ME=["north-west","north","north-east","west","east","south-west","south","south-east"],Yg="e-resize-handle",cc="e-focused-handle",CJ="e-dlg-resizable",u4=["e-restrict-left"],f4="e-resize-viewport",EJ=["north","west","east","south"],wE=0,CE=0,p4=0,g4=0,Qg=0,Gg=0,Xg=null,DE=null,xE=null,Y0=!0,v4=0,TE=!0;function xJ(n){AE();var t=Si("span",{attrs:{unselectable:"on",contenteditable:"false"}});t.setAttribute("class","e-dialog-border-resize e-"+n),"south"===n&&(t.style.height="2px",t.style.width="100%",t.style.bottom="0px",t.style.left="0px"),"north"===n&&(t.style.height="2px",t.style.width="100%",t.style.top="0px",t.style.left="0px"),"east"===n&&(t.style.height="100%",t.style.width="2px",t.style.right="0px",t.style.top="0px"),"west"===n&&(t.style.height="100%",t.style.width="2px",t.style.left="0px",t.style.top="0px"),Ui.appendChild(t)}function m4(n){var t;return m(n)||(t="string"==typeof n?document.querySelector(n):n),t}function y4(n){for(var t=n||this,e=Ui.querySelectorAll("."+Yg),i=0;i-1?"mouse":"touch"}function I4(n){if(n.preventDefault(),Ui=n.target.parentElement,AE(),Qg=n.pageX,Gg=n.pageY,n.target.classList.add(cc),m(Xg)||!0!==Xg(n,this)){this.targetEle&&Ui&&Ui.querySelector("."+CJ)&&($t="body"===this.target?null:this.targetEle,bh=this.targetEle.clientWidth,Ih=this.targetEle.clientHeight);var e=m($t)?document:$t;E.add(e,"mousemove",qg,this),E.add(document,"mouseup",Q0,this);for(var i=0;i=0||s.top<0)&&(e=!0):e=!0;var a=CE+(r-Gg);a=a>uf?a:uf;var l=0;m($t)||(l=o.top);var h=m($t)?0:$t.offsetHeight-$t.clientHeight,c=s.top-l-h/2;if(c=c<0?0:c,s.top>0&&c+a>Ih){if(e=!1,Ui.classList.contains(f4))return;Ui.style.height=Ih-parseInt(c.toString(),10)+"px"}else{var d=0;if(e){s.top<0&&t+(s.height+s.top)>0&&a+(d=s.top)<=30&&(a=s.height-(s.height+s.top)+30),a+s.top>=Ih&&(Ui.style.height=s.height+(t-(s.height+s.top))+"px");var u=m($t)?d:c;a>=uf&&a+u<=Ih&&(Ui.style.height=a+"px")}}}function NE(n){var e,t=!1,i="mouse"===S4(n.type)?n.pageY:n.touches[0].pageY,r=dc(Ui),s=m($t)?0:$t.offsetHeight-$t.clientHeight;m($t)||(e=dc($t)),(!m($t)&&r.top-e.top>0||m($t)&&i>0||!m($t)&&Math.floor(r.top-e.top+r.height+(e.bottom-r.bottom))-s<=Ih)&&(t=!0);var o=CE-(i-Gg);if(t&&o>=uf&&o<=Ih){var a=0;m($t)||(a=e.top);var l=g4-a+(i-Gg);l=l>0?l:1,Ui.style.height=o+"px",Ui.style.top=l+"px"}}function OE(n){var i,t=document.documentElement.clientWidth,e=!1;m($t)||(i=dc($t));var r="mouse"===S4(n.type)?n.pageX:n.touches[0].pageX,s=dc(Ui),o=m($t)?0:$t.offsetWidth-$t.clientWidth,a=m($t)?0:i.left,l=m($t)?0:i.width;m(Mh)&&(m($t)?Mh=t:(Mh=s.left-a-o/2+s.width,Mh+=l-o-Mh)),(!m($t)&&Math.floor(s.left-i.left+s.width+(i.right-s.right))-o<=bh||m($t)&&r>=0)&&(e=!0);var h=wE-(r-Qg);if(Y0&&(h=h>Mh?Mh:h),e&&h>=EE&&h<=bh){var c=0;m($t)||(c=i.left);var d=p4-c+(r-Qg);d=d>0?d:1,h!==v4&&TE&&(Ui.style.width=h+"px"),Y0&&(Ui.style.left=d+"px",TE=1!==d)}v4=h}function kE(n){var i,t=document.documentElement.clientWidth,e=!1;m($t)||(i=dc($t));var s=(n.touches?n.changedTouches[0]:n).pageX,o=dc(Ui);(!m($t)&&(o.left-i.left+o.width<=bh||o.right-i.left>=o.width)||m($t)&&t-s>0)&&(e=!0);var a=wE+(s-Qg),l=0;if(m($t)||(l=i.left),o.left-l+a>bh){if(e=!1,Ui.classList.contains(f4))return;Ui.style.width=bh-(o.left-l)+"px"}e&&a>=EE&&a<=bh&&(Ui.style.width=a+"px")}function M4(){for(var n=Ui.querySelectorAll("."+Yg),t=0;t=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},OJ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return PE(t,n),Zt([I(!0)],t.prototype,"isFlat",void 0),Zt([I()],t.prototype,"buttonModel",void 0),Zt([I("Button")],t.prototype,"type",void 0),Zt([H()],t.prototype,"click",void 0),t}(Ee),kJ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return PE(t,n),Zt([I("Fade")],t.prototype,"effect",void 0),Zt([I(400)],t.prototype,"duration",void 0),Zt([I(0)],t.prototype,"delay",void 0),t}(Ee),G0="e-dialog",zE="e-rtl",RE="e-dlg-header-content",w4="e-dlg-header",X0="e-footer-content",q0="e-dlg-modal",C4="e-icon-dlg-close",Pa="e-dlg-target",ea="e-scroll-disabled",E4="e-device",$0="e-dlg-fullscreen",D4="e-dlg-closeicon-btn",x4="e-popup-open",T4="Information",A4="e-scroll-disabled",L4="e-alert-dialog",N4="e-confirm-dialog",HE="e-dlg-resizable",ff="e-restrict-left",O4="e-resize-viewport",BE="user action",QJ=function(n){function t(e,i){var r=n.call(this,e,i)||this;return r.needsID=!0,r}return PE(t,n),t.prototype.render=function(){this.initialize(),this.initRender(),this.wireEvents(),"100%"===this.width&&(this.element.style.width=""),""!==this.minHeight&&(this.element.style.minHeight=Re(this.minHeight)),this.enableResize&&(this.setResize(),this.isModal&&(this.isModelResize=!0),"None"===this.animationSettings.effect&&this.getMinHeight()),this.renderComplete()},t.prototype.initializeValue=function(){this.dlgClosedBy=BE},t.prototype.preRender=function(){var e=this;if(this.initializeValue(),this.headerContent=null,this.allowMaxHeight=!0,this.preventVisibility=!0,this.clonedEle=this.element.cloneNode(!0),this.closeIconClickEventHandler=function(s){e.dlgClosedBy="close icon",e.hide(s)},this.dlgOverlayClickEventHandler=function(s){e.dlgClosedBy="overlayClick",s.preventFocus=!1,e.trigger("overlayClick",s,function(o){o.preventFocus||e.focusContent(),e.dlgClosedBy=BE})},this.l10n=new uo("dialog",{close:"Close"},this.locale),this.checkPositionData(),m(this.target)){var r=this.isProtectedOnChange;this.isProtectedOnChange=!0,this.target=document.body,this.isProtectedOnChange=r}},t.prototype.updatePersistData=function(){this.enablePersistence&&this.setProperties({width:parseFloat(this.element.style.width),height:parseFloat(this.element.style.height),position:{X:parseFloat(this.dragObj.element.style.left),Y:parseFloat(this.dragObj.element.style.top)}},!0)},t.prototype.isNumberValue=function(e){return/^[-+]?\d*\.?\d+$/.test(e)},t.prototype.checkPositionData=function(){if(!m(this.position)){if(!m(this.position.X)&&"number"!=typeof this.position.X&&this.isNumberValue(this.position.X)){var i=this.isProtectedOnChange;this.isProtectedOnChange=!0,this.position.X=parseFloat(this.position.X),this.isProtectedOnChange=i}m(this.position.Y)||"number"==typeof this.position.Y||this.isNumberValue(this.position.Y)&&(i=this.isProtectedOnChange,this.isProtectedOnChange=!0,this.position.Y=parseFloat(this.position.Y),this.isProtectedOnChange=i)}},t.prototype.getEle=function(e,i){for(var r=void 0,s=0;s=0&&t[e])xJ(t[e]);else if(""!==t[e].trim()){var i=Si("div",{className:"e-icons "+Yg+" e-"+t[e]});Ui.appendChild(i)}uf=n.minHeight,EE=n.minWidth,bh=n.maxWidth,Ih=n.maxHeight,n.proxy&&n.proxy.element&&n.proxy.element.classList.contains("e-dialog")?y4(n.proxy):y4()}({element:this.element,direction:r,minHeight:parseInt(e.slice(0,i.indexOf("p")),10),maxHeight:this.targetEle.clientHeight,minWidth:parseInt(i.slice(0,i.indexOf("p")),10),maxWidth:this.targetEle.clientWidth,boundary:this.target===document.body?null:this.targetEle,resizeBegin:this.onResizeStart.bind(this),resizeComplete:this.onResizeComplete.bind(this),resizing:this.onResizing.bind(this),proxy:this}),this.wireWindowResizeEvent()}else M4(),this.unWireWindowResizeEvent(),this.element.classList.remove(this.isModal?ff:O4),this.element.classList.remove(HE)},t.prototype.getFocusElement=function(e){var r=e.querySelectorAll('input,select,textarea,button:enabled,a,[contenteditable="true"],[tabindex]');return{element:r[r.length-1]}},t.prototype.keyDown=function(e){var i=this;if(9===e.keyCode&&this.isModal){var r=void 0;m(this.btnObj)||(r=this.btnObj[this.btnObj.length-1]),m(this.btnObj)&&!m(this.ftrTemplateContent)&&(r=this.getFocusElement(this.ftrTemplateContent)),m(this.btnObj)&&m(this.ftrTemplateContent)&&!m(this.contentEle)&&(r=this.getFocusElement(this.contentEle)),!m(r)&&document.activeElement===r.element&&!e.shiftKey&&(e.preventDefault(),this.focusableElements(this.element).focus()),document.activeElement===this.focusableElements(this.element)&&e.shiftKey&&(e.preventDefault(),m(r)||r.element.focus())}var h,s=document.activeElement,o=["input","textarea"].indexOf(s.tagName.toLowerCase())>-1,a=!1;if(o||(a=s.hasAttribute("contenteditable")&&"true"===s.getAttribute("contenteditable")),27===e.keyCode&&this.closeOnEscape){this.dlgClosedBy="escape";var l=document.querySelector(".e-popup-open:not(.e-dialog)");!m(l)&&!l.classList.contains("e-toolbar-pop")&&!l.classList.contains("e-slider-tooltip")||this.hide(e)}(13===e.keyCode&&!e.ctrlKey&&"textarea"!==s.tagName.toLowerCase()&&o&&!m(this.primaryButtonEle)||13===e.keyCode&&e.ctrlKey&&("textarea"===s.tagName.toLowerCase()||a)&&!m(this.primaryButtonEle))&&this.buttons.some(function(d,u){h=u;var f=d.buttonModel;return!m(f)&&!0===f.isPrimary})&&"function"==typeof this.buttons[h].click&&setTimeout(function(){i.buttons[h].click.call(i,e)})},t.prototype.initialize=function(){m(this.target)||(this.targetEle="string"==typeof this.target?document.querySelector(this.target):this.target),this.isBlazorServerRender()||V([this.element],G0),X.isDevice&&V([this.element],E4),this.isBlazorServerRender()||this.setCSSClass(),this.setMaxHeight()},t.prototype.initRender=function(){var e=this;if(this.initialRender=!0,this.isBlazorServerRender()||Fe(this.element,{role:"dialog"}),1e3===this.zIndex?(this.setzIndex(this.element,!1),this.calculatezIndex=!0):this.calculatezIndex=!1,this.setTargetContent(),""!==this.header&&!m(this.header)&&this.setHeader(),this.renderCloseIcon(),this.setContent(),""===this.footerTemplate||m(this.footerTemplate)?!m(this.buttons[0])&&!m(this.buttons[0].buttonModel)&&this.setButton():this.setFooterTemplate(),this.allowDragging&&!m(this.headerContent)&&this.setAllowDragging(),Fe(this.element,{"aria-modal":this.isModal?"true":"false"}),this.isModal&&this.setIsModal(),!0!==this.element.classList.contains(L4)&&!0!==this.element.classList.contains(N4)&&!m(this.element.parentElement)){var i=this.isModal?this.dlgContainer.parentElement:this.element.parentElement;this.refElement=this.createElement("div",{className:"e-dlg-ref-element"}),i.insertBefore(this.refElement,this.isModal?this.dlgContainer:this.element)}if(m(this.targetEle)||this.targetEle.appendChild(this.isModal?this.dlgContainer:this.element),this.popupObj=new lc(this.element,{height:this.height,width:this.width,zIndex:this.zIndex,relateTo:this.target,actionOnScroll:"none",enableRtl:this.enableRtl,open:function(o){var a={container:e.isModal?e.dlgContainer:e.element,element:e.element,target:e.target,preventFocus:!1};e.enableResize&&e.resetResizeIcon(),e.trigger("open",a,function(l){l.preventFocus||e.focusContent()})},close:function(o){e.isModal&&V([e.dlgOverlay],"e-fade"),e.unBindEvent(e.element),e.isModal&&(e.dlgContainer.style.display="none"),e.trigger("close",e.closeArgs);var a=document.activeElement;!m(a)&&!m(a.blur)&&a.blur(),!m(e.storeActiveElement)&&!m(e.storeActiveElement.focus)&&e.storeActiveElement.focus()}}),this.positionChange(),this.setEnableRTL(),this.isBlazorServerRender()||(V([this.element],"e-popup-close"),this.isModal&&this.setOverlayZindex()),this.visible){if(this.show(),this.isModal){var r=this.getTargetContainer(this.target);r instanceof Element&&"rtl"===window.getComputedStyle(r).getPropertyValue("direction")&&this.setPopupPosition()}}else this.isModal&&(this.dlgOverlay.style.display="none");this.initialRender=!1},t.prototype.getTargetContainer=function(e){var i=null;if("string"==typeof e)if(e.startsWith("#"))i=document.getElementById(e.substring(1));else if(e.startsWith(".")){var r=document.getElementsByClassName(e.substring(1));i=r.length>0?r[0]:null}else!(e instanceof HTMLElement)&&e!==document.body&&(i=document.querySelector(e));else e instanceof HTMLElement&&(i=e);return i},t.prototype.resetResizeIcon=function(){var e=this.getMinHeight();if(this.targetEle.offsetHeight0&&("function"==typeof this.buttons[e].click&&E.add(s[e],"click",this.buttons[e].click,this),"object"==typeof this.buttons[e].click&&E.add(s[e],"click",this.buttonClickHandler.bind(this,e),this)),!this.isBlazorServerRender()&&!m(this.ftrTemplateContent)&&(this.btnObj[e].appendTo(this.ftrTemplateContent.children[e]),this.buttons[e].isFlat&&this.btnObj[e].element.classList.add("e-flat"),this.primaryButtonEle=this.element.getElementsByClassName("e-primary")[0]))},t.prototype.buttonClickHandler=function(e){this.trigger("buttons["+e+"].click",{})},t.prototype.setContent=function(){this.contentEle=this.createElement("div",{className:"e-dlg-content",id:this.element.id+"_dialog-content"}),Fe(this.element,this.headerEle?{"aria-describedby":this.element.id+"_title "+this.element.id+"_dialog-content"}:{"aria-describedby":this.element.id+"_dialog-content"}),this.innerContentElement?this.contentEle.appendChild(this.innerContentElement):(!m(this.content)&&""!==this.content||!this.initialRender)&&(("string"!=typeof this.content||ce())&&this.content instanceof HTMLElement?this.contentEle.appendChild(this.content):this.setTemplate(this.content,this.contentEle,"content")),m(this.headerContent)?this.element.insertBefore(this.contentEle,this.element.children[0]):this.element.insertBefore(this.contentEle,this.element.children[1]),"auto"===this.height&&(!this.isBlazorServerRender()&&X.isIE&&""===this.element.style.width&&!m(this.width)&&(this.element.style.width=Re(this.width)),this.setMaxHeight())},t.prototype.setTemplate=function(e,i,r){var s,o,a;o=i.classList.contains(w4)?this.element.id+"header":i.classList.contains(X0)?this.element.id+"footerTemplate":this.element.id+"content",m(e.outerHTML)?("string"==typeof e||"string"!=typeof e||ce()&&!this.isStringTemplate)&&("string"==typeof e&&(e=this.sanitizeHelper(e)),this.isVue||"string"!=typeof e?(s=si(e),a=e):i.innerHTML=e):i.appendChild(e);var l=[];if(!m(s)){for(var c=0,d=s({},this,r,o,!(ce()&&!this.isStringTemplate&&0===a.indexOf("
Blazor"))||this.isStringTemplate);c/g,"");(this.element.children.length>0||i)&&(this.innerContentElement=document.createDocumentFragment(),[].slice.call(this.element.childNodes).forEach(function(r){8!==r.nodeType&&e.innerContentElement.appendChild(r)}))}},t.prototype.setHeader=function(){this.headerEle?this.headerEle.innerHTML="":this.headerEle=this.createElement("div",{id:this.element.id+"_title",className:w4}),this.createHeaderContent(),this.headerContent.appendChild(this.headerEle),this.setTemplate(this.header,this.headerEle,"header"),Fe(this.element,{"aria-describedby":this.element.id+"_title"}),Fe(this.element,{"aria-labelledby":this.element.id+"_dialog-header"}),this.element.insertBefore(this.headerContent,this.element.children[0]),this.allowDragging&&!m(this.headerContent)&&this.setAllowDragging()},t.prototype.setFooterTemplate=function(){this.ftrTemplateContent?this.ftrTemplateContent.innerHTML="":this.ftrTemplateContent=this.createElement("div",{className:X0}),""===this.footerTemplate||m(this.footerTemplate)?this.ftrTemplateContent.innerHTML=this.buttonContent.join(""):this.setTemplate(this.footerTemplate,this.ftrTemplateContent,"footerTemplate"),this.element.appendChild(this.ftrTemplateContent)},t.prototype.createHeaderContent=function(){m(this.headerContent)&&(this.headerContent=this.createElement("div",{id:this.element.id+"_dialog-header",className:RE}))},t.prototype.renderCloseIcon=function(){this.showCloseIcon&&(this.closeIcon=this.createElement("button",{className:D4,attrs:{type:"button"}}),this.closeIconBtnObj=new ys({cssClass:"e-flat",iconCss:C4+" e-icons"}),this.closeIconTitle(),m(this.headerContent)?(this.createHeaderContent(),gl([this.closeIcon],this.headerContent),this.element.insertBefore(this.headerContent,this.element.children[0])):gl([this.closeIcon],this.headerContent),this.closeIconBtnObj.appendTo(this.closeIcon))},t.prototype.closeIconTitle=function(){this.l10n.setLocale(this.locale);var e=this.l10n.getConstant("close");this.closeIcon.setAttribute("title",e),this.closeIcon.setAttribute("aria-label",e)},t.prototype.setCSSClass=function(e){e&&(K([this.element],e.split(" ")),this.isModal&&!m(this.dlgContainer)&&K([this.dlgContainer],e.split(" "))),this.cssClass&&(V([this.element],this.cssClass.split(" ")),this.isModal&&!m(this.dlgContainer)&&V([this.dlgContainer],this.cssClass.split(" ")))},t.prototype.setIsModal=function(){this.dlgContainer=this.createElement("div",{className:"e-dlg-container"}),this.setCSSClass(),this.element.classList.remove(x4),this.element.parentNode.insertBefore(this.dlgContainer,this.element),this.dlgContainer.appendChild(this.element),V([this.element],q0),this.dlgOverlay=this.createElement("div",{className:"e-dlg-overlay"}),this.dlgOverlay.style.zIndex=(this.zIndex-1).toString(),this.dlgContainer.appendChild(this.dlgOverlay)},t.prototype.getValidFocusNode=function(e){for(var i,r=0;r0||"a"===i.tagName.toLowerCase()&&i.hasAttribute("href"))&&i.tabIndex>-1&&!i.disabled&&!this.disableElement(i,'[disabled],[aria-disabled="true"],[type="hidden"]'))return i;i=null}return i},t.prototype.focusableElements=function(e){if(!m(e)){var r=e.querySelectorAll('input,select,textarea,button,a,[contenteditable="true"],[tabindex]');return this.getValidFocusNode(r)}return null},t.prototype.getAutoFocusNode=function(e){var i=e.querySelector("."+D4),s=e.querySelectorAll("[autofocus]"),o=this.getValidFocusNode(s);if(ce()&&(this.primaryButtonEle=this.element.getElementsByClassName("e-primary")[0]),m(o)){if(!m(o=this.focusableElements(this.contentEle)))return o;if(!m(this.primaryButtonEle))return this.element.querySelector(".e-primary")}else i=o;return i},t.prototype.disableElement=function(e,i){var r=e?e.matches||e.webkitMatchesSelector||e.msGetRegionContent:null;if(r)for(;e;e=e.parentNode)if(e instanceof Element&&r.call(e,i))return e;return null},t.prototype.focusContent=function(){var e=this.getAutoFocusNode(this.element),i=m(e)?this.element:e,r=X.userAgent;(r.indexOf("MSIE ")>0||r.indexOf("Trident/")>0)&&this.element.focus(),i.focus(),this.unBindEvent(this.element),this.bindEvent(this.element)},t.prototype.bindEvent=function(e){E.add(e,"keydown",this.keyDown,this)},t.prototype.unBindEvent=function(e){E.remove(e,"keydown",this.keyDown)},t.prototype.updateSanitizeContent=function(){this.isBlazorServerRender()||(this.contentEle.innerHTML=this.sanitizeHelper(this.content))},t.prototype.isBlazorServerRender=function(){return ce()&&this.isServerRendered},t.prototype.getModuleName=function(){return"dialog"},t.prototype.onPropertyChanged=function(e,i){if(this.element.classList.contains(G0))for(var r=0,s=Object.keys(e);r0?this.showCloseIcon||""!==this.header&&!m(this.header)?this.showCloseIcon||he(this.closeIcon):(he(this.headerContent),this.headerContent=null):(this.renderCloseIcon(),this.wireEvents());break;case"locale":this.showCloseIcon&&this.closeIconTitle();break;case"visible":this.visible?this.show():this.hide();break;case"isModal":this.updateIsModal();break;case"height":je(this.element,{height:Re(e.height)}),this.updatePersistData();break;case"width":je(this.element,{width:Re(e.width)}),this.updatePersistData();break;case"zIndex":this.popupObj.zIndex=this.zIndex,this.isModal&&this.setOverlayZindex(this.zIndex),this.element.style.zIndex!==this.zIndex.toString()&&(this.calculatezIndex=!1);break;case"cssClass":this.setCSSClass(i.cssClass);break;case"buttons":this.unWireButtonEvents(),this.destroyButtons(),m(this.ftrTemplateContent)||(he(this.ftrTemplateContent),this.ftrTemplateContent=null),this.footerTemplate="",this.setButton();break;case"allowDragging":this.allowDragging&&!m(this.headerContent)?this.setAllowDragging():this.dragObj.destroy();break;case"target":this.setTarget(e.target);break;case"position":if(this.checkPositionData(),this.isModal){var a=this.position.X,l=this.position.Y;m(i.position)||(m(i.position.X)||(a=i.position.X),m(i.position.Y)||(l=i.position.Y)),this.dlgContainer.classList.contains("e-dlg-"+a+"-"+l)&&this.dlgContainer.classList.remove("e-dlg-"+a+"-"+l)}this.positionChange(),this.updatePersistData();break;case"enableRtl":this.setEnableRTL();break;case"enableResize":this.setResize(),this.isModelResize=this.enableResize&&this.isModal,this.enableResize&&this.dialogOpen&&this.resetResizeIcon();break;case"minHeight":""!==this.minHeight&&(this.element.style.minHeight=Re(this.minHeight))}},t.prototype.setTarget=function(e){this.popupObj.relateTo=e,this.target=e,this.targetEle="string"==typeof this.target?document.querySelector(this.target):this.target,this.dragObj&&(this.dragObj.dragArea=this.targetEle),this.setMaxHeight(),this.isModal&&this.updateIsModal(),this.enableResize&&this.setResize(),m(this.targetEle)||(this.isModal&&!m(this.dlgContainer)?this.targetEle.appendChild(this.dlgContainer):m(this.element)||this.targetEle.appendChild(this.element))},t.prototype.updateIsModal=function(){if(this.element.setAttribute("aria-modal",this.isModal?"true":"false"),this.isModal)m(this.dlgOverlay)&&(this.setIsModal(),this.element.style.top="0px",this.element.style.left="0px",m(this.targetEle)||this.targetEle.appendChild(this.dlgContainer));else{for(K([this.element],q0),K([document.body],[Pa,ea]),he(this.dlgOverlay);this.dlgContainer.firstChild;)this.dlgContainer.parentElement.insertBefore(this.dlgContainer.firstChild,this.dlgContainer);this.dlgContainer.parentElement.removeChild(this.dlgContainer)}this.visible&&this.show(),this.positionChange(),this.isModal&&this.dlgOverlay&&E.add(this.dlgOverlay,"click",this.dlgOverlayClickEventHandler,this)},t.prototype.setzIndex=function(e,i){var r=this.isProtectedOnChange;this.isProtectedOnChange=!0;var s=hc(e);this.zIndex=s>this.zIndex?s:this.zIndex,this.isProtectedOnChange=r,i&&(this.popupObj.zIndex=this.zIndex)},t.prototype.windowResizeHandler=function(){(function AJ(n){bh=n})(this.targetEle.clientWidth),function LJ(n){Ih=n}(this.targetEle.clientHeight),this.setMaxHeight()},t.prototype.getPersistData=function(){return this.addOnPersist(["width","height","position"])},t.prototype.removeAllChildren=function(e){for(;e.children[0];)this.removeAllChildren(e.children[0]),e.removeChild(e.children[0])},t.prototype.destroy=function(){if(!this.isDestroyed){var e=[zE,q0,HE,ff,$0,E4],i=["role","aria-modal","aria-labelledby","aria-describedby","aria-grabbed","tabindex","style"];K([this.targetEle],[Pa,ea]),!m(this.element)&&this.element.classList.contains($0)&&K([document.body],[Pa,ea]),this.isModal&&K([m(this.targetEle)?document.body:this.targetEle],ea),this.unWireEvents(),this.unWireButtonEvents(),this.destroyButtons(),m(this.closeIconBtnObj)||this.closeIconBtnObj.destroy(),m(this.dragObj)||this.dragObj.destroy(),!m(this.popupObj.element)&&this.popupObj.element.classList.contains("e-popup")&&this.popupObj.destroy(),K([this.element],e),!m(this.cssClass)&&""!==this.cssClass&&K([this.element],this.cssClass.split(" ")),!m(this.refElement)&&!m(this.refElement.parentElement)&&(this.refElement.parentElement.insertBefore(this.isModal?this.dlgContainer:this.element,this.refElement),he(this.refElement),this.refElement=void 0),this.isModal&&(he(this.dlgOverlay),this.dlgContainer.parentNode.insertBefore(this.element,this.dlgContainer),he(this.dlgContainer)),this.element.innerHTML=this.clonedEle.innerHTML;for(var r=0;r0&&""===this.footerTemplate&&this.ftrTemplateContent)for(var e=0;e=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},FE="e-tooltip",B4="e-icons",F4="e-tooltip-close",_E="e-tooltip-wrap",_4="e-tip-content",pf="e-arrow-tip",U4="e-arrow-tip-outer",Z0="e-arrow-tip-inner",$g="e-tip-bottom",UE="e-tip-top",j4="e-tip-left",jE="e-tip-right",VE="e-popup",Zg="e-popup-open",WE="e-popup-close",J0="e-lib",V4="e-tooltip-popup-container",JJ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return P4(t,n),Gi([I({effect:"FadeIn",duration:150,delay:0})],t.prototype,"open",void 0),Gi([I({effect:"FadeOut",duration:150,delay:0})],t.prototype,"close",void 0),t}(Ee),wh=function(n){function t(e,i){var r=n.call(this,e,i)||this;return r.mouseMoveEvent=null,r.mouseMoveTarget=null,r.containerElement=null,r.isBodyContainer=!0,r}return P4(t,n),t.prototype.initialize=function(){this.formatPosition(),V([this.element],FE)},t.prototype.formatPosition=function(){var e,i;this.position&&(0===this.position.indexOf("Top")||0===this.position.indexOf("Bottom")?(e=this.position.split(/(?=[A-Z])/),this.tooltipPositionY=e[0],this.tooltipPositionX=e[1]):(i=this.position.split(/(?=[A-Z])/),this.tooltipPositionX=i[0],this.tooltipPositionY=i[1]))},t.prototype.renderArrow=function(){this.setTipClass(this.position);var e=this.createElement("div",{className:pf+" "+this.tipClass});e.appendChild(this.createElement("div",{className:U4+" "+this.tipClass})),e.appendChild(this.createElement("div",{className:Z0+" "+this.tipClass})),this.tooltipEle.appendChild(e)},t.prototype.setTipClass=function(e){this.tipClass=0===e.indexOf("Right")?j4:0===e.indexOf("Bottom")?UE:0===e.indexOf("Left")?jE:$g},t.prototype.renderPopup=function(e){var i=this.mouseTrail?{top:0,left:0}:this.getTooltipPosition(e);this.tooltipEle.classList.remove(J0),this.popupObj=new lc(this.tooltipEle,{height:this.height,width:this.width,position:{X:i.left,Y:i.top},enableRtl:this.enableRtl,open:this.openPopupHandler.bind(this),close:this.closePopupHandler.bind(this)})},t.prototype.getScalingFactor=function(e){if(!e)return{x:1,y:1};var i={x:1,y:1},r=e.closest('[style*="transform: scale"]');if(r&&r!==this.tooltipEle&&r.contains(this.tooltipEle)){var a=window.getComputedStyle(r).getPropertyValue("transform").match(/matrix\(([^)]+)\)/)[1].split(",").map(parseFloat);i.x=a[0],i.y=a[3]}return i},t.prototype.getTooltipPosition=function(e){this.tooltipEle.style.display="block";var i=this.element.closest('[style*="zoom"]');i&&(i.contains(this.tooltipEle)||(this.tooltipEle.style.zoom=getComputedStyle(i).zoom));var r=ns(e,this.tooltipPositionX,this.tooltipPositionY,!this.isBodyContainer,this.isBodyContainer?null:this.containerElement.getBoundingClientRect()),s=this.getScalingFactor(e),o=this.calculateTooltipOffset(this.position,s.x,s.y),a=this.calculateElementPosition(r,o),c=this.collisionFlipFit(e,a[0],a[1]);return c.left=c.left/s.x,c.top=c.top/s.y,this.tooltipEle.style.display="",c},t.prototype.windowResize=function(){this.reposition(this.findTarget())},t.prototype.reposition=function(e){if(this.popupObj&&e){var i=this.getTooltipPosition(e);this.popupObj.position={X:i.left,Y:i.top},this.popupObj.dataBind()}},t.prototype.openPopupHandler=function(){!this.mouseTrail&&this.needTemplateReposition()&&this.reposition(this.findTarget()),this.trigger("afterOpen",this.tooltipEventArgs),this.tooltipEventArgs=null},t.prototype.closePopupHandler=function(){this.isReact&&!("Click"===this.opensOn||"function"==typeof this.content)&&this.clearTemplate(["content"]),this.clear();var e={type:this.tooltipEventArgs.event?this.tooltipEventArgs.event.type:null,cancel:!1,target:this.tooltipEventArgs.target,event:this.tooltipEventArgs.event?this.tooltipEventArgs.event:null,element:this.tooltipEle,isInteracted:!m(this.tooltipEventArgs.event)};this.trigger("afterClose",e),e=null},t.prototype.calculateTooltipOffset=function(e,i,r){void 0===i&&(i=1),void 0===r&&(r=1);var o,a,l,h,c,d,u,f,s={top:0,left:0};if(1!==i||1!==r){var p=this.tooltipEle.getBoundingClientRect(),g=void 0;l=Math.round(p.width),h=Math.round(p.height),(c=_("."+pf,this.tooltipEle))&&(g=c.getBoundingClientRect()),o=c?Math.round(g.width):0,a=c?Math.round(g.height):0,d=this.showTipPointer?0:8,u=a/2+2+(h-this.tooltipEle.clientHeight*r),f=o/2+2+(l-this.tooltipEle.clientWidth*i)}else l=this.tooltipEle.offsetWidth,h=this.tooltipEle.offsetHeight,c=_("."+pf,this.tooltipEle),d=this.showTipPointer?0:8,u=(a=c?c.offsetHeight:0)/2+2+(this.tooltipEle.offsetHeight-this.tooltipEle.clientHeight),f=(o=c?c.offsetWidth:0)/2+2+(this.tooltipEle.offsetWidth-this.tooltipEle.clientWidth);switch(this.mouseTrail&&(d+=2),e){case"RightTop":s.left+=o+d,s.top-=h-u;break;case"RightCenter":s.left+=o+d,s.top-=h/2;break;case"RightBottom":s.left+=o+d,s.top-=u;break;case"BottomRight":s.top+=a+d,s.left-=f;break;case"BottomCenter":s.top+=a+d,s.left-=l/2;break;case"BottomLeft":s.top+=a+d,s.left-=l-f;break;case"LeftBottom":s.left-=o+l+d,s.top-=u;break;case"LeftCenter":s.left-=o+l+d,s.top-=h/2;break;case"LeftTop":s.left-=o+l+d,s.top-=h-u;break;case"TopLeft":s.top-=h+a+d,s.left-=l-f;break;case"TopRight":s.top-=h+a+d,s.left-=f;break;default:s.top-=h+a+d,s.left-=l/2}return s.left+=this.offsetX,s.top+=this.offsetY,s},t.prototype.updateTipPosition=function(e){var i=we("."+pf+",."+U4+",."+Z0,this.tooltipEle);K(i,[$g,UE,j4,jE]),this.setTipClass(e),V(i,this.tipClass)},t.prototype.adjustArrow=function(e,i,r,s){var o=_("."+pf,this.tooltipEle);if(!1!==this.showTipPointer&&null!==o){var a,l;this.updateTipPosition(i),this.tooltipEle.style.display="block";var p,h=this.tooltipEle.clientWidth,c=this.tooltipEle.clientHeight,d=_("."+Z0,this.tooltipEle),u=o.offsetWidth,f=o.offsetHeight;this.tooltipEle.style.display="",this.tipClass===$g||this.tipClass===UE?(this.tipClass===$g?(l="99.9%",d.style.top="-"+(f-2)+"px"):(l=-(f-1)+"px",d.style.top="-"+(f-6)+"px"),e&&(a=(p="Center"!==r||h>e.offsetWidth||this.mouseTrail)&&"Left"===r||!p&&"End"===this.tipPointerPosition?h-u-2+"px":p&&"Right"===r||!p&&"Start"===this.tipPointerPosition?"2px":!p||"End"!==this.tipPointerPosition&&"Start"!==this.tipPointerPosition?h/2-u/2+"px":"End"===this.tipPointerPosition?e.offsetWidth+(this.tooltipEle.offsetWidth-e.offsetWidth)/2-u/2-2+"px":(this.tooltipEle.offsetWidth-e.offsetWidth)/2-u/2+2+"px")):(this.tipClass===jE?(a="99.9%",d.style.left="-"+(u-2)+"px"):(a=-(u-1)+"px",d.style.left=u-2-u+"px"),l=(p="Center"!==s||c>e.offsetHeight||this.mouseTrail)&&"Top"===s||!p&&"End"===this.tipPointerPosition?c-f-2+"px":p&&"Bottom"===s||!p&&"Start"===this.tipPointerPosition?"2px":c/2-f/2+"px"),o.style.top=l,o.style.left=a}},t.prototype.renderContent=function(e){var i=this,r=_("."+_4,this.tooltipEle);if(this.cssClass&&V([this.tooltipEle],this.cssClass.split(" ")),e&&!m(e.getAttribute("title"))&&(e.setAttribute("data-content",e.getAttribute("title")),e.removeAttribute("title")),m(this.content))e&&!m(e.getAttribute("data-content"))&&(r.innerHTML=e.getAttribute("data-content"));else if(r.innerHTML="",this.content instanceof HTMLElement)r.appendChild(this.content);else if("string"==typeof this.content)this.isAngular?this.setProperties({content:Ai.sanitize(this.content)},!0):this.content=this.enableHtmlSanitizer?Ai.sanitize(this.content):this.content,this.enableHtmlParse?(o=si(this.content)({},this,"content",this.element.id+"content",void 0,void 0,r,this.root))&&Dt(o,r):r.textContent=this.content;else{var o;(o=si(this.content)({},this,"content",this.element.id+"content",void 0,void 0,r))&&(this.isAngular&&setTimeout(function(){i.reposition(e)},1),Dt(o,r)),this.renderReactTemplates()}},t.prototype.renderCloseIcon=function(){if(this.isSticky){var i=this.createElement("div",{className:B4+" "+F4});this.tooltipEle.appendChild(i),E.add(i,X.touchStartEvent,this.onStickyClose,this)}else{var e=this.tooltipEle.querySelector("."+B4+"."+F4);e&>(e)}},t.prototype.addDescribedBy=function(e,i){var r=(e.getAttribute("aria-describedby")||"").split(/\s+/);r.indexOf(i)<0&&r.push(i),Fe(e,{"aria-describedby":r.join(" ").trim(),"data-tooltip-id":i})},t.prototype.removeDescribedBy=function(e){var i=e.getAttribute("data-tooltip-id"),r=(e.getAttribute("aria-describedby")||"").split(/\s+/),s=r.indexOf(i);-1!==s&&r.splice(s,1),e.removeAttribute("data-tooltip-id");var o=r.join(" ").trim();o?e.setAttribute("aria-describedby",o):e.removeAttribute("aria-describedby")},t.prototype.tapHoldHandler=function(e){clearTimeout(this.autoCloseTimer),this.targetHover(e.originalEvent)},t.prototype.touchEndHandler=function(){var e=this;this.isSticky||(this.autoCloseTimer=setTimeout(function(){e.close()},1500))},t.prototype.targetClick=function(e){var i;!m(i=this.target?J(e.target,this.target):this.element)&&(null===i.getAttribute("data-tooltip-id")?this.targetHover(e):this.isSticky||this.hideTooltip(this.animation.close,e,i))},t.prototype.targetHover=function(e){var i;if(!(m(i=this.target?J(e.target,this.target):this.element)||null!==i.getAttribute("data-tooltip-id")&&0===this.closeDelay)){for(var s=0,o=[].slice.call(we('[data-tooltip-id= "'+this.ctrlId+'_content"]',document));s0?this.showTimer=setTimeout(function(){o.mouseTrail&&E.add(i,"mousemove touchstart mouseenter",o.onMouseMove,o),o.popupObj&&(o.popupObj.show(a,i),o.mouseMoveEvent&&o.mouseTrail&&o.onMouseMove(o.mouseMoveEvent))},this.openDelay):this.popupObj&&this.popupObj.show(a,i)}s&&this.wireMouseEvents(s,i)},t.prototype.needTemplateReposition=function(){return!m(this.viewContainerRef)&&"string"!=typeof this.viewContainerRef||this.isReact},t.prototype.checkCollision=function(e,i,r){var s={left:i,top:r,position:this.position,horizontal:this.tooltipPositionX,vertical:this.tooltipPositionY},o=ac(this.tooltipEle,this.checkCollideTarget(),i,r);return o.length>0&&(s.horizontal=o.indexOf("left")>=0?"Right":o.indexOf("right")>=0?"Left":this.tooltipPositionX,s.vertical=o.indexOf("top")>=0?"Bottom":o.indexOf("bottom")>=0?"Top":this.tooltipPositionY),s},t.prototype.calculateElementPosition=function(e,i){return[this.isBodyContainer?e.left+i.left:e.left-this.containerElement.getBoundingClientRect().left+i.left+window.pageXOffset+this.containerElement.scrollLeft,this.isBodyContainer?e.top+i.top:e.top-this.containerElement.getBoundingClientRect().top+i.top+window.pageYOffset+this.containerElement.scrollTop]},t.prototype.collisionFlipFit=function(e,i,r){var s=this.checkCollision(e,i,r),o=s.position;if(this.tooltipPositionY!==s.vertical&&(o=0===this.position.indexOf("Bottom")||0===this.position.indexOf("Top")?s.vertical+this.tooltipPositionX:this.tooltipPositionX+s.vertical),this.tooltipPositionX!==s.horizontal&&(0===o.indexOf("Left")&&(s.vertical="LeftTop"===o||"LeftCenter"===o?"Top":"Bottom",o=s.vertical+"Left"),0===o.indexOf("Right")&&(s.vertical="RightTop"===o||"RightCenter"===o?"Top":"Bottom",o=s.vertical+"Right"),s.horizontal=this.tooltipPositionX),this.tooltipEventArgs={type:null,cancel:!1,target:e,event:null,element:this.tooltipEle,collidedPosition:o},this.trigger("beforeCollision",this.tooltipEventArgs),this.tooltipEventArgs.cancel)o=this.position;else{var a=s.vertical,l=s.horizontal;if(s.position!==o){var h=ns(e,l,a,!this.isBodyContainer,this.isBodyContainer?null:this.containerElement.getBoundingClientRect());this.adjustArrow(e,o,l,a);var c=this.getScalingFactor(e),d=this.calculateTooltipOffset(o,c.x,c.y);d.top-=this.getOffSetPosition("TopBottom",o,this.offsetY),d.left-=this.getOffSetPosition("RightLeft",o,this.offsetX),s.position=o;var u=this.calculateElementPosition(h,d);s.left=u[0],s.top=u[1]}else this.adjustArrow(e,o,l,a)}var f={left:s.left,top:s.top},p=this.isBodyContainer?fE(this.tooltipEle,this.checkCollideTarget(),{X:!0,Y:this.windowCollision},f):f;this.tooltipEle.style.display="block";var g=_("."+pf,this.tooltipEle);if(this.showTipPointer&&null!=g&&(0===o.indexOf("Bottom")||0===o.indexOf("Top"))){var v=parseInt(g.style.left,10)-(p.left-s.left);v<0?v=0:v+g.offsetWidth>this.tooltipEle.clientWidth&&(v=this.tooltipEle.clientWidth-g.offsetWidth),g.style.left=v.toString()+"px"}return this.tooltipEle.style.display="",f.left=p.left,f.top=p.top,f},t.prototype.getOffSetPosition=function(e,i,r){return-1!==e.indexOf(this.position.split(/(?=[A-Z])/)[0])&&-1!==e.indexOf(i.split(/(?=[A-Z])/)[0])?2*r:0},t.prototype.checkCollideTarget=function(){return!this.windowCollision&&this.target?this.element:null},t.prototype.hideTooltip=function(e,i,r){var s=this;this.closeDelay>0?(clearTimeout(this.hideTimer),clearTimeout(this.showTimer),this.hideTimer=setTimeout(function(){s.closeDelay&&s.tooltipEle&&s.isTooltipOpen||s.tooltipHide(e,i,r)},this.closeDelay)):this.tooltipHide(e,i,r)},t.prototype.tooltipHide=function(e,i,r){var o,s=this;o=i?this.target?r||i.target:this.element:_('[data-tooltip-id= "'+this.ctrlId+'_content"]',document),this.tooltipEventArgs={type:i?i.type:null,cancel:!1,target:o,event:i||null,element:this.tooltipEle,isInteracted:!m(i)},this.trigger("beforeClose",this.tooltipEventArgs,function(a){a.cancel?s.isHidden=!1:(s.mouseMoveBeforeRemove(),s.popupHide(e,o,i))})},t.prototype.popupHide=function(e,i,r){i&&r&&this.restoreElement(i),this.isHidden=!0;var s={name:this.animation.close.effect,duration:e.duration,delay:e.delay,timingFunction:"easeIn"};"None"===e.effect&&(s=void 0),this.popupObj&&this.popupObj.hide(s)},t.prototype.restoreElement=function(e){this.unwireMouseEvents(e),m(e.getAttribute("data-content"))||(e.setAttribute("title",e.getAttribute("data-content")),e.removeAttribute("data-content")),this.removeDescribedBy(e)},t.prototype.clear=function(){var e=this.findTarget();e&&this.restoreElement(e),this.tooltipEle&&(K([this.tooltipEle],WE),V([this.tooltipEle],Zg)),this.isHidden&&(this.popupObj&&this.popupObj.destroy(),this.tooltipEle&>(this.tooltipEle),this.tooltipEle=null,this.popupObj=null)},t.prototype.tooltipHover=function(){this.tooltipEle&&(this.isTooltipOpen=!0)},t.prototype.tooltipMouseOut=function(e){this.isTooltipOpen=!1,this.hideTooltip(this.animation.close,e,this.findTarget())},t.prototype.onMouseOut=function(e){var i=e.relatedTarget;if(i&&!this.mouseTrail){var r=J(i,"."+_E+"."+J0+"."+VE);r?E.add(r,"mouseleave",this.tooltipElementMouseOut,this):(this.hideTooltip(this.animation.close,e,this.findTarget()),0===this.closeDelay&&("None"===this.animation.close.effect||this.isReact&&"string"!=typeof this.content)&&this.clear())}else this.hideTooltip(this.animation.close,e,this.findTarget()),this.clear();this.popupObj&&!this.popupObj.element.classList.contains(Zg)&&this.clear()},t.prototype.tooltipElementMouseOut=function(e){this.hideTooltip(this.animation.close,e,this.findTarget()),E.remove(this.element,"mouseleave",this.tooltipElementMouseOut),this.clear()},t.prototype.onStickyClose=function(){this.close()},t.prototype.onMouseMove=function(e){var i=0,r=0;e.type.indexOf("touch")>-1?(e.preventDefault(),i=e.touches[0].pageX,r=e.touches[0].pageY):(i=e.pageX,r=e.pageY),Hs.stop(this.tooltipEle),K([this.tooltipEle],WE),V([this.tooltipEle],Zg),this.adjustArrow(e.target,this.position,this.tooltipPositionX,this.tooltipPositionY);var s=this.getScalingFactor(e.target),o=this.calculateTooltipOffset(this.position,s.x,s.y),h=this.checkCollision(e.target,i+o.left+this.offsetX,r+o.top+this.offsetY);if(this.tooltipPositionX!==h.horizontal||this.tooltipPositionY!==h.vertical){var c=0===this.position.indexOf("Bottom")||0===this.position.indexOf("Top")?h.vertical+h.horizontal:h.horizontal+h.vertical;h.position=c,this.adjustArrow(e.target,h.position,h.horizontal,h.vertical);var d=this.calculateTooltipOffset(h.position,s.x,s.y);h.left=i+d.left-this.offsetX,h.top=r+d.top-this.offsetY}this.tooltipEle.style.left=h.left+"px",this.tooltipEle.style.top=h.top+"px"},t.prototype.keyDown=function(e){this.tooltipEle&&27===e.keyCode&&this.close()},t.prototype.touchEnd=function(e){this.tooltipEle&&null===J(e.target,"."+FE)&&!this.isSticky&&this.close()},t.prototype.scrollHandler=function(e){this.tooltipEle&&!this.isSticky&&!J(e.target,"."+_E+"."+J0+"."+VE)&&!this.isSticky&&this.close()},t.prototype.render=function(){this.initialize(),this.wireEvents(this.opensOn),this.renderComplete()},t.prototype.preRender=function(){this.tipClass=$g,this.tooltipPositionX="Center",this.tooltipPositionY="Top",this.isHidden=!0},t.prototype.wireEvents=function(e){for(var r=0,s=this.getTriggerList(e);r0)for(var i=0,r=e;i0)for(var i=0,r=e;i0&&this.condition&&-1!==this.condition.indexOf("not")&&(e[s].condition=e[s].condition?e[s].condition+"not":"not"),i=e[s].validate(t),r){if(!i)return!1}else if(i)return!0;return r},n.prototype.toJson=function(){var t,e;if(this.isComplex){t=[],e=this.predicates;for(var i=0;ie.length-3?(e=e.substring(0,e.length-1),n.endsWith(n.toLowerCase(t),n.toLowerCase(e))):(e.lastIndexOf("%")!==e.indexOf("%")&&e.lastIndexOf("%")>e.indexOf("%")+1&&(e=e.substring(e.indexOf("%")+1,e.lastIndexOf("%"))),-1!==t.indexOf(e)))},n.fnSort=function(t){return"ascending"===(t=t?n.toLowerCase(t):"ascending")?this.fnAscending:this.fnDescending},n.fnAscending=function(t,e){return m(t)&&m(e)||null==e?-1:"string"==typeof t?t.localeCompare(e):null==t?1:t-e},n.fnDescending=function(t,e){return m(t)&&m(e)?-1:null==e?1:"string"==typeof t?-1*t.localeCompare(e):null==t?-1:e-t},n.extractFields=function(t,e){for(var i={},r=0;r0||e.length>0;)o=t.length>0&&e.length>0?r?r(this.getVal(t,0,i),this.getVal(e,0,i),t[0],e[0])<=0?t:e:t[0][i]0?t:e,s.push(o.shift());return s},n.getVal=function(t,e,i){return i?this.getObject(i,t[e]):t[e]},n.toLowerCase=function(t){return t?"string"==typeof t?t.toLowerCase():t.toString():0===t||!1===t?t.toString():""},n.callAdaptorFunction=function(t,e,i,r){if(e in t){var s=t[e](i,r);m(s)||(i=s)}return i},n.getAddParams=function(t,e,i){var r={};return n.callAdaptorFunction(t,"addParams",{dm:e,query:i,params:i?i.params:[],reqParams:r}),r},n.isPlainObject=function(t){return!!t&&t.constructor===Object},n.isCors=function(){var t=null;try{t=new window.XMLHttpRequest}catch{}return!!t&&"withCredentials"in t},n.getGuid=function(t){var i;return(t||"")+"00000000-0000-4000-0000-000000000000".replace(/0/g,function(r,s){if("crypto"in window&&"getRandomValues"in crypto){var o=new Uint8Array(1);window.crypto.getRandomValues(o),i=o[0]%16|0}else i=16*Math.random()|0;return"0123456789abcdef"[19===s?3&i|8:i]})},n.isNull=function(t){return null==t},n.getItemFromComparer=function(t,e,i){var r,s,o,a=0,l="string"==typeof n.getVal(t,0,e);if(t.length)for(;m(r)&&a0&&(r=s,o=t[a]));return o},n.distinct=function(t,e,i){i=!m(i)&&i;var s,r=[],o={};return t.forEach(function(a,l){(s="object"==typeof t[l]?n.getVal(t,l,e):t[l])in o||(r.push(i?t[l]:s),o[s]=1)}),r},n.processData=function(t,e){var i=this.prepareQuery(t),r=new it(e);t.requiresCounts&&i.requiresCount();var s=r.executeLocal(i),o={result:t.requiresCounts?s.result:s,count:s.count,aggregates:JSON.stringify(s.aggregates)};return t.requiresCounts?o:s},n.prepareQuery=function(t){var e=this,i=new _t;return t.select&&i.select(t.select),t.where&&n.parse.parseJson(t.where).filter(function(o){if(m(o.condition))i.where(o.field,o.operator,o.value,o.ignoreCase,o.ignoreAccent);else{var a=[];o.field?a.push(new Ss(o.field,o.operator,o.value,o.ignoreCase,o.ignoreAccent)):a=a.concat(e.getPredicate(o.predicates)),"or"===o.condition?i.where(Ss.or(a)):"and"===o.condition&&i.where(Ss.and(a))}}),t.search&&n.parse.parseJson(t.search).filter(function(o){return i.search(o.key,o.fields,o.operator,o.ignoreCase,o.ignoreAccent)}),t.aggregates&&t.aggregates.filter(function(o){return i.aggregate(o.type,o.field)}),t.sorted&&t.sorted.filter(function(o){return i.sortBy(o.name,o.direction)}),t.skip&&i.skip(t.skip),t.take&&i.take(t.take),t.group&&t.group.filter(function(o){return i.group(o)}),i},n.getPredicate=function(t){for(var e=[],i=0;i":"greaterthan","<=":"lessthanorequal",">=":"greaterthanorequal","==":"equal","!=":"notequal","*=":"contains","$=":"endswith","^=":"startswith"},n.odBiOperator={"<":" lt ",">":" gt ","<=":" le ",">=":" ge ","==":" eq ","!=":" ne ",lessthan:" lt ",lessthanorequal:" le ",greaterthan:" gt ",greaterthanorequal:" ge ",equal:" eq ",notequal:" ne "},n.odUniOperator={"$=":"endswith","^=":"startswith","*=":"substringof",endswith:"endswith",startswith:"startswith",contains:"substringof",doesnotendwith:"not endswith",doesnotstartwith:"not startswith",doesnotcontain:"not substringof",wildcard:"wildcard",like:"like"},n.odv4UniOperator={"$=":"endswith","^=":"startswith","*=":"contains",endswith:"endswith",startswith:"startswith",contains:"contains",doesnotendwith:"not endswith",doesnotstartwith:"not startswith",doesnotcontain:"not contains",wildcard:"wildcard",like:"like"},n.diacritics={"\u24b6":"A",\uff21:"A",\u00c0:"A",\u00c1:"A",\u00c2:"A",\u1ea6:"A",\u1ea4:"A",\u1eaa:"A",\u1ea8:"A",\u00c3:"A",\u0100:"A",\u0102:"A",\u1eb0:"A",\u1eae:"A",\u1eb4:"A",\u1eb2:"A",\u0226:"A",\u01e0:"A",\u00c4:"A",\u01de:"A",\u1ea2:"A",\u00c5:"A",\u01fa:"A",\u01cd:"A",\u0200:"A",\u0202:"A",\u1ea0:"A",\u1eac:"A",\u1eb6:"A",\u1e00:"A",\u0104:"A",\u023a:"A",\u2c6f:"A",\ua732:"AA",\u00c6:"AE",\u01fc:"AE",\u01e2:"AE",\ua734:"AO",\ua736:"AU",\ua738:"AV",\ua73a:"AV",\ua73c:"AY","\u24b7":"B",\uff22:"B",\u1e02:"B",\u1e04:"B",\u1e06:"B",\u0243:"B",\u0182:"B",\u0181:"B","\u24b8":"C",\uff23:"C",\u0106:"C",\u0108:"C",\u010a:"C",\u010c:"C",\u00c7:"C",\u1e08:"C",\u0187:"C",\u023b:"C",\ua73e:"C","\u24b9":"D",\uff24:"D",\u1e0a:"D",\u010e:"D",\u1e0c:"D",\u1e10:"D",\u1e12:"D",\u1e0e:"D",\u0110:"D",\u018b:"D",\u018a:"D",\u0189:"D",\ua779:"D",\u01f1:"DZ",\u01c4:"DZ",\u01f2:"Dz",\u01c5:"Dz","\u24ba":"E",\uff25:"E",\u00c8:"E",\u00c9:"E",\u00ca:"E",\u1ec0:"E",\u1ebe:"E",\u1ec4:"E",\u1ec2:"E",\u1ebc:"E",\u0112:"E",\u1e14:"E",\u1e16:"E",\u0114:"E",\u0116:"E",\u00cb:"E",\u1eba:"E",\u011a:"E",\u0204:"E",\u0206:"E",\u1eb8:"E",\u1ec6:"E",\u0228:"E",\u1e1c:"E",\u0118:"E",\u1e18:"E",\u1e1a:"E",\u0190:"E",\u018e:"E","\u24bb":"F",\uff26:"F",\u1e1e:"F",\u0191:"F",\ua77b:"F","\u24bc":"G",\uff27:"G",\u01f4:"G",\u011c:"G",\u1e20:"G",\u011e:"G",\u0120:"G",\u01e6:"G",\u0122:"G",\u01e4:"G",\u0193:"G",\ua7a0:"G",\ua77d:"G",\ua77e:"G","\u24bd":"H",\uff28:"H",\u0124:"H",\u1e22:"H",\u1e26:"H",\u021e:"H",\u1e24:"H",\u1e28:"H",\u1e2a:"H",\u0126:"H",\u2c67:"H",\u2c75:"H",\ua78d:"H","\u24be":"I",\uff29:"I",\u00cc:"I",\u00cd:"I",\u00ce:"I",\u0128:"I",\u012a:"I",\u012c:"I",\u0130:"I",\u00cf:"I",\u1e2e:"I",\u1ec8:"I",\u01cf:"I",\u0208:"I",\u020a:"I",\u1eca:"I",\u012e:"I",\u1e2c:"I",\u0197:"I","\u24bf":"J",\uff2a:"J",\u0134:"J",\u0248:"J","\u24c0":"K",\uff2b:"K",\u1e30:"K",\u01e8:"K",\u1e32:"K",\u0136:"K",\u1e34:"K",\u0198:"K",\u2c69:"K",\ua740:"K",\ua742:"K",\ua744:"K",\ua7a2:"K","\u24c1":"L",\uff2c:"L",\u013f:"L",\u0139:"L",\u013d:"L",\u1e36:"L",\u1e38:"L",\u013b:"L",\u1e3c:"L",\u1e3a:"L",\u0141:"L",\u023d:"L",\u2c62:"L",\u2c60:"L",\ua748:"L",\ua746:"L",\ua780:"L",\u01c7:"LJ",\u01c8:"Lj","\u24c2":"M",\uff2d:"M",\u1e3e:"M",\u1e40:"M",\u1e42:"M",\u2c6e:"M",\u019c:"M","\u24c3":"N",\uff2e:"N",\u01f8:"N",\u0143:"N",\u00d1:"N",\u1e44:"N",\u0147:"N",\u1e46:"N",\u0145:"N",\u1e4a:"N",\u1e48:"N",\u0220:"N",\u019d:"N",\ua790:"N",\ua7a4:"N",\u01ca:"NJ",\u01cb:"Nj","\u24c4":"O",\uff2f:"O",\u00d2:"O",\u00d3:"O",\u00d4:"O",\u1ed2:"O",\u1ed0:"O",\u1ed6:"O",\u1ed4:"O",\u00d5:"O",\u1e4c:"O",\u022c:"O",\u1e4e:"O",\u014c:"O",\u1e50:"O",\u1e52:"O",\u014e:"O",\u022e:"O",\u0230:"O",\u00d6:"O",\u022a:"O",\u1ece:"O",\u0150:"O",\u01d1:"O",\u020c:"O",\u020e:"O",\u01a0:"O",\u1edc:"O",\u1eda:"O",\u1ee0:"O",\u1ede:"O",\u1ee2:"O",\u1ecc:"O",\u1ed8:"O",\u01ea:"O",\u01ec:"O",\u00d8:"O",\u01fe:"O",\u0186:"O",\u019f:"O",\ua74a:"O",\ua74c:"O",\u01a2:"OI",\ua74e:"OO",\u0222:"OU","\u24c5":"P",\uff30:"P",\u1e54:"P",\u1e56:"P",\u01a4:"P",\u2c63:"P",\ua750:"P",\ua752:"P",\ua754:"P","\u24c6":"Q",\uff31:"Q",\ua756:"Q",\ua758:"Q",\u024a:"Q","\u24c7":"R",\uff32:"R",\u0154:"R",\u1e58:"R",\u0158:"R",\u0210:"R",\u0212:"R",\u1e5a:"R",\u1e5c:"R",\u0156:"R",\u1e5e:"R",\u024c:"R",\u2c64:"R",\ua75a:"R",\ua7a6:"R",\ua782:"R","\u24c8":"S",\uff33:"S",\u1e9e:"S",\u015a:"S",\u1e64:"S",\u015c:"S",\u1e60:"S",\u0160:"S",\u1e66:"S",\u1e62:"S",\u1e68:"S",\u0218:"S",\u015e:"S",\u2c7e:"S",\ua7a8:"S",\ua784:"S","\u24c9":"T",\uff34:"T",\u1e6a:"T",\u0164:"T",\u1e6c:"T",\u021a:"T",\u0162:"T",\u1e70:"T",\u1e6e:"T",\u0166:"T",\u01ac:"T",\u01ae:"T",\u023e:"T",\ua786:"T",\ua728:"TZ","\u24ca":"U",\uff35:"U",\u00d9:"U",\u00da:"U",\u00db:"U",\u0168:"U",\u1e78:"U",\u016a:"U",\u1e7a:"U",\u016c:"U",\u00dc:"U",\u01db:"U",\u01d7:"U",\u01d5:"U",\u01d9:"U",\u1ee6:"U",\u016e:"U",\u0170:"U",\u01d3:"U",\u0214:"U",\u0216:"U",\u01af:"U",\u1eea:"U",\u1ee8:"U",\u1eee:"U",\u1eec:"U",\u1ef0:"U",\u1ee4:"U",\u1e72:"U",\u0172:"U",\u1e76:"U",\u1e74:"U",\u0244:"U","\u24cb":"V",\uff36:"V",\u1e7c:"V",\u1e7e:"V",\u01b2:"V",\ua75e:"V",\u0245:"V",\ua760:"VY","\u24cc":"W",\uff37:"W",\u1e80:"W",\u1e82:"W",\u0174:"W",\u1e86:"W",\u1e84:"W",\u1e88:"W",\u2c72:"W","\u24cd":"X",\uff38:"X",\u1e8a:"X",\u1e8c:"X","\u24ce":"Y",\uff39:"Y",\u1ef2:"Y",\u00dd:"Y",\u0176:"Y",\u1ef8:"Y",\u0232:"Y",\u1e8e:"Y",\u0178:"Y",\u1ef6:"Y",\u1ef4:"Y",\u01b3:"Y",\u024e:"Y",\u1efe:"Y","\u24cf":"Z",\uff3a:"Z",\u0179:"Z",\u1e90:"Z",\u017b:"Z",\u017d:"Z",\u1e92:"Z",\u1e94:"Z",\u01b5:"Z",\u0224:"Z",\u2c7f:"Z",\u2c6b:"Z",\ua762:"Z","\u24d0":"a",\uff41:"a",\u1e9a:"a",\u00e0:"a",\u00e1:"a",\u00e2:"a",\u1ea7:"a",\u1ea5:"a",\u1eab:"a",\u1ea9:"a",\u00e3:"a",\u0101:"a",\u0103:"a",\u1eb1:"a",\u1eaf:"a",\u1eb5:"a",\u1eb3:"a",\u0227:"a",\u01e1:"a",\u00e4:"a",\u01df:"a",\u1ea3:"a",\u00e5:"a",\u01fb:"a",\u01ce:"a",\u0201:"a",\u0203:"a",\u1ea1:"a",\u1ead:"a",\u1eb7:"a",\u1e01:"a",\u0105:"a",\u2c65:"a",\u0250:"a",\ua733:"aa",\u00e6:"ae",\u01fd:"ae",\u01e3:"ae",\ua735:"ao",\ua737:"au",\ua739:"av",\ua73b:"av",\ua73d:"ay","\u24d1":"b",\uff42:"b",\u1e03:"b",\u1e05:"b",\u1e07:"b",\u0180:"b",\u0183:"b",\u0253:"b","\u24d2":"c",\uff43:"c",\u0107:"c",\u0109:"c",\u010b:"c",\u010d:"c",\u00e7:"c",\u1e09:"c",\u0188:"c",\u023c:"c",\ua73f:"c",\u2184:"c","\u24d3":"d",\uff44:"d",\u1e0b:"d",\u010f:"d",\u1e0d:"d",\u1e11:"d",\u1e13:"d",\u1e0f:"d",\u0111:"d",\u018c:"d",\u0256:"d",\u0257:"d",\ua77a:"d",\u01f3:"dz",\u01c6:"dz","\u24d4":"e",\uff45:"e",\u00e8:"e",\u00e9:"e",\u00ea:"e",\u1ec1:"e",\u1ebf:"e",\u1ec5:"e",\u1ec3:"e",\u1ebd:"e",\u0113:"e",\u1e15:"e",\u1e17:"e",\u0115:"e",\u0117:"e",\u00eb:"e",\u1ebb:"e",\u011b:"e",\u0205:"e",\u0207:"e",\u1eb9:"e",\u1ec7:"e",\u0229:"e",\u1e1d:"e",\u0119:"e",\u1e19:"e",\u1e1b:"e",\u0247:"e",\u025b:"e",\u01dd:"e","\u24d5":"f",\uff46:"f",\u1e1f:"f",\u0192:"f",\ua77c:"f","\u24d6":"g",\uff47:"g",\u01f5:"g",\u011d:"g",\u1e21:"g",\u011f:"g",\u0121:"g",\u01e7:"g",\u0123:"g",\u01e5:"g",\u0260:"g",\ua7a1:"g",\u1d79:"g",\ua77f:"g","\u24d7":"h",\uff48:"h",\u0125:"h",\u1e23:"h",\u1e27:"h",\u021f:"h",\u1e25:"h",\u1e29:"h",\u1e2b:"h",\u1e96:"h",\u0127:"h",\u2c68:"h",\u2c76:"h",\u0265:"h",\u0195:"hv","\u24d8":"i",\uff49:"i",\u00ec:"i",\u00ed:"i",\u00ee:"i",\u0129:"i",\u012b:"i",\u012d:"i",\u00ef:"i",\u1e2f:"i",\u1ec9:"i",\u01d0:"i",\u0209:"i",\u020b:"i",\u1ecb:"i",\u012f:"i",\u1e2d:"i",\u0268:"i",\u0131:"i","\u24d9":"j",\uff4a:"j",\u0135:"j",\u01f0:"j",\u0249:"j","\u24da":"k",\uff4b:"k",\u1e31:"k",\u01e9:"k",\u1e33:"k",\u0137:"k",\u1e35:"k",\u0199:"k",\u2c6a:"k",\ua741:"k",\ua743:"k",\ua745:"k",\ua7a3:"k","\u24db":"l",\uff4c:"l",\u0140:"l",\u013a:"l",\u013e:"l",\u1e37:"l",\u1e39:"l",\u013c:"l",\u1e3d:"l",\u1e3b:"l",\u017f:"l",\u0142:"l",\u019a:"l",\u026b:"l",\u2c61:"l",\ua749:"l",\ua781:"l",\ua747:"l",\u01c9:"lj","\u24dc":"m",\uff4d:"m",\u1e3f:"m",\u1e41:"m",\u1e43:"m",\u0271:"m",\u026f:"m","\u24dd":"n",\uff4e:"n",\u01f9:"n",\u0144:"n",\u00f1:"n",\u1e45:"n",\u0148:"n",\u1e47:"n",\u0146:"n",\u1e4b:"n",\u1e49:"n",\u019e:"n",\u0272:"n",\u0149:"n",\ua791:"n",\ua7a5:"n",\u01cc:"nj","\u24de":"o",\uff4f:"o",\u00f2:"o",\u00f3:"o",\u00f4:"o",\u1ed3:"o",\u1ed1:"o",\u1ed7:"o",\u1ed5:"o",\u00f5:"o",\u1e4d:"o",\u022d:"o",\u1e4f:"o",\u014d:"o",\u1e51:"o",\u1e53:"o",\u014f:"o",\u022f:"o",\u0231:"o",\u00f6:"o",\u022b:"o",\u1ecf:"o",\u0151:"o",\u01d2:"o",\u020d:"o",\u020f:"o",\u01a1:"o",\u1edd:"o",\u1edb:"o",\u1ee1:"o",\u1edf:"o",\u1ee3:"o",\u1ecd:"o",\u1ed9:"o",\u01eb:"o",\u01ed:"o",\u00f8:"o",\u01ff:"o",\u0254:"o",\ua74b:"o",\ua74d:"o",\u0275:"o",\u01a3:"oi",\u0223:"ou",\ua74f:"oo","\u24df":"p",\uff50:"p",\u1e55:"p",\u1e57:"p",\u01a5:"p",\u1d7d:"p",\ua751:"p",\ua753:"p",\ua755:"p","\u24e0":"q",\uff51:"q",\u024b:"q",\ua757:"q",\ua759:"q","\u24e1":"r",\uff52:"r",\u0155:"r",\u1e59:"r",\u0159:"r",\u0211:"r",\u0213:"r",\u1e5b:"r",\u1e5d:"r",\u0157:"r",\u1e5f:"r",\u024d:"r",\u027d:"r",\ua75b:"r",\ua7a7:"r",\ua783:"r","\u24e2":"s",\uff53:"s",\u00df:"s",\u015b:"s",\u1e65:"s",\u015d:"s",\u1e61:"s",\u0161:"s",\u1e67:"s",\u1e63:"s",\u1e69:"s",\u0219:"s",\u015f:"s",\u023f:"s",\ua7a9:"s",\ua785:"s",\u1e9b:"s","\u24e3":"t",\uff54:"t",\u1e6b:"t",\u1e97:"t",\u0165:"t",\u1e6d:"t",\u021b:"t",\u0163:"t",\u1e71:"t",\u1e6f:"t",\u0167:"t",\u01ad:"t",\u0288:"t",\u2c66:"t",\ua787:"t",\ua729:"tz","\u24e4":"u",\uff55:"u",\u00f9:"u",\u00fa:"u",\u00fb:"u",\u0169:"u",\u1e79:"u",\u016b:"u",\u1e7b:"u",\u016d:"u",\u00fc:"u",\u01dc:"u",\u01d8:"u",\u01d6:"u",\u01da:"u",\u1ee7:"u",\u016f:"u",\u0171:"u",\u01d4:"u",\u0215:"u",\u0217:"u",\u01b0:"u",\u1eeb:"u",\u1ee9:"u",\u1eef:"u",\u1eed:"u",\u1ef1:"u",\u1ee5:"u",\u1e73:"u",\u0173:"u",\u1e77:"u",\u1e75:"u",\u0289:"u","\u24e5":"v",\uff56:"v",\u1e7d:"v",\u1e7f:"v",\u028b:"v",\ua75f:"v",\u028c:"v",\ua761:"vy","\u24e6":"w",\uff57:"w",\u1e81:"w",\u1e83:"w",\u0175:"w",\u1e87:"w",\u1e85:"w",\u1e98:"w",\u1e89:"w",\u2c73:"w","\u24e7":"x",\uff58:"x",\u1e8b:"x",\u1e8d:"x","\u24e8":"y",\uff59:"y",\u1ef3:"y",\u00fd:"y",\u0177:"y",\u1ef9:"y",\u0233:"y",\u1e8f:"y",\u00ff:"y",\u1ef7:"y",\u1e99:"y",\u1ef5:"y",\u01b4:"y",\u024f:"y",\u1eff:"y","\u24e9":"z",\uff5a:"z",\u017a:"z",\u1e91:"z",\u017c:"z",\u017e:"z",\u1e93:"z",\u1e95:"z",\u01b6:"z",\u0225:"z",\u0240:"z",\u2c6c:"z",\ua763:"z",\u0386:"\u0391",\u0388:"\u0395",\u0389:"\u0397",\u038a:"\u0399",\u03aa:"\u0399",\u038c:"\u039f",\u038e:"\u03a5",\u03ab:"\u03a5",\u038f:"\u03a9",\u03ac:"\u03b1",\u03ad:"\u03b5",\u03ae:"\u03b7",\u03af:"\u03b9",\u03ca:"\u03b9",\u0390:"\u03b9",\u03cc:"\u03bf",\u03cd:"\u03c5",\u03cb:"\u03c5",\u03b0:"\u03c5",\u03c9:"\u03c9",\u03c2:"\u03c3"},n.fnOperators={equal:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?n.toLowerCase(t)===n.toLowerCase(e):t===e},notequal:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),!n.fnOperators.equal(t,e,i)},lessthan:function(t,e,i){return i?n.toLowerCase(t)n.toLowerCase(e):t>e},lessthanorequal:function(t,e,i){return i?n.toLowerCase(t)<=n.toLowerCase(e):(m(t)&&(t=void 0),t<=e)},greaterthanorequal:function(t,e,i){return i?n.toLowerCase(t)>=n.toLowerCase(e):t>=e},contains:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?!m(t)&&!m(e)&&-1!==n.toLowerCase(t).indexOf(n.toLowerCase(e)):!m(t)&&!m(e)&&-1!==t.toString().indexOf(e)},doesnotcontain:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?!m(t)&&!m(e)&&-1===n.toLowerCase(t).indexOf(n.toLowerCase(e)):!m(t)&&!m(e)&&-1===t.toString().indexOf(e)},isnotnull:function(t){return null!=t},isnull:function(t){return null==t},startswith:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.startsWith(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.startsWith(t,e)},doesnotstartwith:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.notStartsWith(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.notStartsWith(t,e)},like:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.like(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.like(t,e)},isempty:function(t){return void 0===t||""===t},isnotempty:function(t){return void 0!==t&&""!==t},wildcard:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?(t||"boolean"==typeof t)&&e&&"object"!=typeof t&&n.wildCard(n.toLowerCase(t),n.toLowerCase(e)):(t||"boolean"==typeof t)&&e&&n.wildCard(t,e)},endswith:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.endsWith(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.endsWith(t,e)},doesnotendwith:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.notEndsWith(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.notEndsWith(t,e)},processSymbols:function(t){var e=n.operatorSymbols[t];return e?n.fnOperators[e]:n.throwError("Query - Process Operator : Invalid operator")},processOperator:function(t){return n.fnOperators[t]||n.fnOperators.processSymbols(t)}},n.parse={parseJson:function(t){return"string"!=typeof t||!/^[\s]*\[|^[\s]*\{(.)+:/g.test(t)&&-1!==t.indexOf('"')?t instanceof Array?n.parse.iterateAndReviveArray(t):"object"==typeof t&&null!==t&&n.parse.iterateAndReviveJson(t):t=JSON.parse(t,n.parse.jsonReviver),t},iterateAndReviveArray:function(t){for(var e=0;e-1||e.indexOf("z")>-1,o=e.split(/[^0-9.]/);if(s){if(o[5].indexOf(".")>-1){var a=o[5].split(".");o[5]=a[0],o[6]=new Date(e).getUTCMilliseconds().toString()}else o[6]="00";e=n.dateParse.toTimeZone(new Date(parseInt(o[0],10),parseInt(o[1],10)-1,parseInt(o[2],10),parseInt(o[3],10),parseInt(o[4],10),parseInt(o[5]?o[5]:"00",10),parseInt(o[6],10)),n.serverTimezoneOffset,!1)}else{var l=new Date(parseInt(o[0],10),parseInt(o[1],10)-1,parseInt(o[2],10),parseInt(o[3],10),parseInt(o[4],10),parseInt(o[5]?o[5]:"00",10)),h=parseInt(o[6],10),c=parseInt(o[7],10);if(isNaN(h)&&isNaN(c))return l;e.indexOf("+")>-1?l.setHours(l.getHours()-h,l.getMinutes()-c):l.setHours(l.getHours()+h,l.getMinutes()+c),e=n.dateParse.toTimeZone(l,n.serverTimezoneOffset,!1)}null==n.serverTimezoneOffset&&(e=n.dateParse.addSelfOffset(e))}}return e},isJson:function(t){return"string"==typeof t[0]?t:n.parse.parseJson(t)},isGuid:function(t){return null!=/[A-Fa-f0-9]{8}(?:-[A-Fa-f0-9]{4}){3}-[A-Fa-f0-9]{12}/i.exec(t)},replacer:function(t,e){return n.isPlainObject(t)?n.parse.jsonReplacer(t,e):t instanceof Array?n.parse.arrayReplacer(t):t instanceof Date?n.parse.jsonReplacer({val:t},e).val:t},jsonReplacer:function(t,e){for(var i,s=0,o=Object.keys(t);s=0?"+":"-",s=function(a){var l=Math.floor(Math.abs(a));return(l<10?"0":"")+l};return e.getFullYear()+"-"+s(e.getMonth()+1)+"-"+s(e.getDate())+"T"+s(e.getHours())+":"+s(e.getMinutes())+":"+s(e.getSeconds())+r+s(i/60)+":"+s(i%60)}},n}(),wl=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),BK={GroupGuid:"{271bbba0-1ee7}"},a5=function(){function n(t){this.options={from:"table",requestType:"json",sortBy:"sorted",select:"select",skip:"skip",group:"group",take:"take",search:"search",count:"requiresCounts",where:"where",aggregates:"aggregates",expand:"expand"},this.type=n,this.dataSource=t,this.pvt={}}return n.prototype.processResponse=function(t,e,i,r){return t},n}(),GE=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return wl(t,n),t.prototype.processQuery=function(e,i){for(var a,l,f,r=e.dataSource.json.slice(0),s=r.length,o=!0,h={},c=0,d=[],u=[],p=0;p1?e.sort.filter(function(f){return f.fieldName===c})[0]:e.sort[0];s=this.onSortBy(s,d,e.query,!0)}e.page&&(s=this.onPage(s,e.page,e.query)),this.formGroupResult(s,h)}else{for(var o=e.lazyLoad.onDemandGroupInfo,a=o.where.length-1;a>=0;a--)s=this.onWhere(s,o.where[a]);if(e.group.length!==o.level)s=le.group(s,e.group[o.level].fieldName,r,null,null,e.group[o.level].comparer,!0),e.sort.length&&(s=this.onSortBy(s,e.sort[parseInt(o.level.toString(),10)],e.query,!0));else for(a=e.sort.length-1;a>=o.level;a--)s=this.onSortBy(s,e.sort[parseInt(a.toString(),10)],e.query,!1);i=s.length,h=s,s=(s=s.slice(o.skip)).slice(0,o.take),e.group.length!==o.level&&this.formGroupResult(s,h)}return{result:s,count:i}},t.prototype.formGroupResult=function(e,i){if(e.length&&i.length){var r="GroupGuid",s="childLevels",o="level",a="records";e[r]=i[r],e[s]=i[s],e[o]=i[o],e[a]=i[a]}return e},t.prototype.getAggregate=function(e){var i=_t.filterQueries(e.queries,"onAggregates"),r=[];if(i.length)for(var s=void 0,o=0;o=0;l--)a[l]&&(o=i.comparer,le.endsWith(a[l]," desc")&&(o=le.fnSort("descending"),a[l]=a[l].replace(" desc","")),e=le.sort(e,a[l],o));return e}return le.sort(e,s?"key":a,i.comparer)},t.prototype.onGroup=function(e,i,r){if(!e||!e.length)return e;var s=this.getAggregate(r);return le.group(e,le.getValue(i.fieldName,r),s,null,null,i.comparer)},t.prototype.onPage=function(e,i,r){var s=le.getValue(i.pageSize,r),o=(le.getValue(i.pageIndex,r)-1)*s;return e&&e.length?e.slice(o,o+s):e},t.prototype.onRange=function(e,i){return e&&e.length?e.slice(le.getValue(i.start),le.getValue(i.end)):e},t.prototype.onTake=function(e,i){return e&&e.length?e.slice(0,le.getValue(i.nos)):e},t.prototype.onSkip=function(e,i){return e&&e.length?e.slice(le.getValue(i.nos)):e},t.prototype.onSelect=function(e,i){return e&&e.length?le.select(e,le.getValue(i.fieldNames)):e},t.prototype.insert=function(e,i,r,s,o){return m(o)?e.dataSource.json.push(i):e.dataSource.json.splice(o,0,i)},t.prototype.remove=function(e,i,r,s){var a,o=e.dataSource.json;for("object"==typeof r&&!(r instanceof Date)&&(r=le.getObject(i,r)),a=0;a1&&(g="("+g+")"),f.filters.push(g);for(var y=0,S="object"==typeof f.filters[p]?Object.keys(f.filters[p]):[];y-1&&this.formRemoteGroupedData(e[s].items,i+1,r-1);var o="GroupGuid",h="records";return e[o]=BK[o],e.level=i,e.childLevels=r,e[h]=e[0].items.length?this.getGroupedRecords(e,!m(e[0].items[h])):[],e},t.prototype.getGroupedRecords=function(e,i){for(var r=[],o=0;ol.length-3?(l=l.substring(0,l.length-1),o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.endswith:le.odv4UniOperator.endswith):l.lastIndexOf("%")!==l.indexOf("%")&&l.lastIndexOf("%")>l.indexOf("%")+1?(l=l.substring(l.indexOf("%")+1,l.lastIndexOf("%")),o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains):o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains),l="'"+(l=encodeURIComponent(l))+"'";else if("wildcard"===o)if(-1!==l.indexOf("*")){var d=l.split("*"),u=void 0,f=0;if(0!==l.indexOf("*")&&-1===d[0].indexOf("%3f")&&-1===d[0].indexOf("?")&&(u="'"+(u=d[0])+"'",s+=(o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.startswith:le.odv4UniOperator.startswith)+"(",s+=c+",",a&&(s+=a),s+=u+")",f++),l.lastIndexOf("*")!==l.length-1&&-1===d[d.length-1].indexOf("%3f")&&-1===d[d.length-1].indexOf("?")&&(u="'"+(u=d[d.length-1])+"'",f>0&&(s+=" and "),s+=(o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.endswith:le.odv4UniOperator.endswith)+"(",s+=c+",",a&&(s+=a),s+=u+")",f++),d.length>2)for(var p=1;p0&&(s+=" and "),"substringof"===(o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains)||"not substringof"===o){var g=u;u=c,c=g}s+=o+"(",s+=c+",",a&&(s+=a),s+=u+")",f++}0===f?(o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains,(-1!==l.indexOf("?")||-1!==l.indexOf("%3f"))&&(l=-1!==l.indexOf("?")?l.split("?").join(""):l.split("%3f").join("")),l="'"+l+"'"):o="wildcard"}else o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains,(-1!==l.indexOf("?")||-1!==l.indexOf("%3f"))&&(l=-1!==l.indexOf("?")?l.split("?").join(""):l.split("%3f").join("")),l="'"+l+"'";return"substringof"!==o&&"not substringof"!==o||(g=l,l=c,c=g),"wildcard"!==o&&(s+=o+"(",s+=c+",",a&&(s+=a),s+=l+")"),s},t.prototype.addParams=function(e){n.prototype.addParams.call(this,e),delete e.reqParams.params},t.prototype.onComplexPredicate=function(e,i,r){for(var s=[],o=0;o-1;f--)!/\bContent-ID:/i.test(c[f])||!/\bHTTP.+201/.test(c[f])||(l=parseInt(/\bContent-ID: (\d+)/i.exec(c[f])[1],10),o.addedRecords[l]&&(h=le.parse.parseJson(/^\{.+\}/m.exec(c[f])[0]),ze({},o.addedRecords[l],this.processResponse(h))));return o}return null},t.prototype.compareAndRemove=function(e,i,r){var s=this;return m(i)||Object.keys(e).forEach(function(o){o!==r&&"@odata.etag"!==o&&(le.isPlainObject(e[o])?(s.compareAndRemove(e[o],i[o]),0===Object.keys(e[o]).filter(function(l){return"@odata.etag"!==l}).length&&delete e[o]):(e[o]===i[o]||e[o]&&i[o]&&e[o].valueOf()===i[o].valueOf())&&delete e[o])}),e},t}(fc),FK=function(n){function t(){var e=n.call(this)||this;return yt("beforeSend",fc.prototype.beforeSend,e),e}return wl(t,n),t.prototype.insert=function(e,i,r,s,o){return this.pvt.position=o,this.updateType="add",{url:e.dataSource.insertUrl||e.dataSource.crudUrl||e.dataSource.url,data:JSON.stringify(ze({},{value:i,table:r,action:"insert"},le.getAddParams(this,e,s)))}},t.prototype.remove=function(e,i,r,s,o){return n.prototype.remove.call(this,e,i,r),{type:"POST",url:e.dataSource.removeUrl||e.dataSource.crudUrl||e.dataSource.url,data:JSON.stringify(ze({},{key:r,keyColumn:i,table:s,action:"remove"},le.getAddParams(this,e,o)))}},t.prototype.update=function(e,i,r,s,o){return this.updateType="update",this.updateKey=i,{type:"POST",url:e.dataSource.updateUrl||e.dataSource.crudUrl||e.dataSource.url,data:JSON.stringify(ze({},{value:r,action:"update",keyColumn:i,key:r[i],table:s},le.getAddParams(this,e,o)))}},t.prototype.processResponse=function(e,i,r,s,o,a,l){var h;if(e="batch"===(o?JSON.parse(o.data):e).action?le.parse.parseJson(e):e,"add"===this.updateType&&n.prototype.insert.call(this,i,e,null,null,this.pvt.position),"update"===this.updateType&&n.prototype.update.call(this,i,this.updateKey,e),this.updateType=void 0,e.added)for(h=0;hi&&h.push(c)}for(c=0;cthis.pageSize;)h.results.splice(0,1),h.keys.splice(0,1);return window.localStorage.setItem(this.guidId,JSON.stringify(h)),e},t.prototype.beforeSend=function(e,i,r){!m(this.cacheAdaptor.options.batch)&&le.endsWith(r.url,this.cacheAdaptor.options.batch)&&"post"===r.type.toLowerCase()&&i.headers.set("Accept",this.cacheAdaptor.options.multipartAccept),e.dataSource.crossDomain||i.headers.set("Accept",this.cacheAdaptor.options.accept)},t.prototype.update=function(e,i,r,s){return this.isCrudAction=!0,this.cacheAdaptor.update(e,i,r,s)},t.prototype.insert=function(e,i,r){return this.isInsertAction=!0,this.cacheAdaptor.insert(e,i,r)},t.prototype.remove=function(e,i,r,s){return this.isCrudAction=!0,this.cacheAdaptor.remove(e,i,r,s)},t.prototype.batchRequest=function(e,i,r){return this.cacheAdaptor.batchRequest(e,i,r)},t}(fc),it=function(){function n(t,e,i){var s,r=this;return this.dateParse=!0,this.timeZoneHandling=!0,this.persistQuery={},this.isInitialLoad=!1,this.requests=[],this.isInitialLoad=!0,!t&&!this.dataSource&&(t=[]),i=i||t.adaptor,t&&!1===t.timeZoneHandling&&(this.timeZoneHandling=t.timeZoneHandling),t instanceof Array?s={json:t,offline:!0}:"object"==typeof t?(t.json||(t.json=[]),t.enablePersistence||(t.enablePersistence=!1),t.id||(t.id=""),t.ignoreOnPersist||(t.ignoreOnPersist=[]),s={url:t.url,insertUrl:t.insertUrl,removeUrl:t.removeUrl,updateUrl:t.updateUrl,crudUrl:t.crudUrl,batchUrl:t.batchUrl,json:t.json,headers:t.headers,accept:t.accept,data:t.data,timeTillExpiration:t.timeTillExpiration,cachingPageSize:t.cachingPageSize,enableCaching:t.enableCaching,requestType:t.requestType,key:t.key,crossDomain:t.crossDomain,jsonp:t.jsonp,dataType:t.dataType,offline:void 0!==t.offline?t.offline:!(t.adaptor instanceof FK||t.adaptor instanceof _K||t.url),requiresFormat:t.requiresFormat,enablePersistence:t.enablePersistence,id:t.id,ignoreOnPersist:t.ignoreOnPersist}):le.throwError("DataManager: Invalid arguments"),void 0===s.requiresFormat&&!le.isCors()&&(s.requiresFormat=!!m(s.crossDomain)||s.crossDomain),void 0===s.dataType&&(s.dataType="json"),this.dataSource=s,this.defaultQuery=e,this.dataSource.enablePersistence&&this.dataSource.id&&window.addEventListener("unload",this.setPersistData.bind(this)),s.url&&s.offline&&!s.json.length?(this.isDataAvailable=!1,this.adaptor=i||new mf,this.dataSource.offline=!1,this.ready=this.executeQuery(e||new _t),this.ready.then(function(o){r.dataSource.offline=!0,r.isDataAvailable=!0,s.json=o.result,r.adaptor=new GE})):this.adaptor=s.offline?new GE:new mf,!s.jsonp&&this.adaptor instanceof mf&&(s.jsonp="callback"),this.adaptor=i||this.adaptor,s.enableCaching&&(this.adaptor=new UK(this.adaptor,s.timeTillExpiration,s.cachingPageSize)),this}return Object.defineProperty(n.prototype,"moduleName",{get:function(){return"datamanager"},enumerable:!0,configurable:!0}),n.prototype.getPersistedData=function(t){var e=localStorage.getItem(t||this.dataSource.id);return JSON.parse(e)},n.prototype.setPersistData=function(t,e,i){localStorage.setItem(e||this.dataSource.id,JSON.stringify(i||this.persistQuery))},n.prototype.setPersistQuery=function(t){var e=this,i=this.getPersistedData();if(this.isInitialLoad&&i&&Object.keys(i).length){this.persistQuery=i,this.persistQuery.queries=this.persistQuery.queries.filter(function(s){if(e.dataSource.ignoreOnPersist&&e.dataSource.ignoreOnPersist.length&&s.fn&&e.dataSource.ignoreOnPersist.some(function(l){return s.fn===l}))return!1;if("onWhere"===s.fn){var o=s.e;if(o&&o.isComplex&&o.predicates instanceof Array){var a=o.predicates.map(function(l){if(l.predicates&&l.predicates instanceof Array){var h=l.predicates.map(function(v){return new Ss(v.field,v.operator,v.value,v.ignoreCase,v.ignoreAccent,v.matchCase)});return"and"===l.condition?Ss.and(h):Ss.or(h)}return new Ss(l.field,l.operator,l.value,l.ignoreCase,l.ignoreAccent,l.matchCase)});s.e=new Ss(a[0],o.condition,a.slice(1))}}return!0});var r=ze(new _t,this.persistQuery);return this.isInitialLoad=!1,r}return this.persistQuery=t,this.isInitialLoad=!1,t},n.prototype.setDefaultQuery=function(t){return this.defaultQuery=t,this},n.prototype.executeLocal=function(t){!this.defaultQuery&&!(t instanceof _t)&&le.throwError("DataManager - executeLocal() : A query is required to execute"),this.dataSource.json||le.throwError("DataManager - executeLocal() : Json data is required to execute"),this.dataSource.enablePersistence&&this.dataSource.id&&(t=this.setPersistQuery(t));var e=this.adaptor.processQuery(this,t=t||this.defaultQuery);if(t.subQuery){var i=t.subQuery.fromTable,r=t.subQuery.lookups,s=t.isCountRequired?e.result:e;r&&r instanceof Array&&le.buildHierarchy(t.subQuery.fKey,i,s,r,t.subQuery.key);for(var o=0;oli");z.classList.remove("json-parent");for(var j=0;j',W=ve.children[0].placeholder}return W}function Q(k,W,ve){!m(ve)&&""!==ve&&K(W,ve.split(" ")),!m(k)&&""!==k&&V(W,k.split(" "))}function oe(k,W,ve){if("multiselect"===ve||function Mo(k){if(!k)return!1;for(var W=k;W&&W!==document.body;){if("none"===window.getComputedStyle(W).display)return!1;W=W.parentElement}return!0}(k)){var Te="multiselect"===ve?k:k.clientWidth-parseInt(getComputedStyle(k,null).getPropertyValue("padding-left"),10);!m(W)&&!m(W.getElementsByClassName("e-float-text-content")[0])&&(W.getElementsByClassName("e-float-text-content")[0].classList.contains("e-float-text-overflow")&&W.getElementsByClassName("e-float-text-content")[0].classList.remove("e-float-text-overflow"),(Te0)for(var Ye=0;Ye<_e.length;Ye++)_e[parseInt(Ye.toString(),10)].addEventListener("mousedown",wo,!1),_e[parseInt(Ye.toString(),10)].addEventListener("mouseup",Ul,!1);else if(_e.length>0)for(Ye=0;Ye<_e.length;Ye++)_e[parseInt(Ye.toString(),10)].removeEventListener("mousedown",wo,this),_e[parseInt(Ye.toString(),10)].removeEventListener("mouseup",Ul,this)}function wo(){for(var W=this.parentElement;!W.classList.contains("e-input-group");)W=W.parentElement;!function Sa(k,W){!k.classList.contains("e-disabled")&&!k.querySelector("input").readOnly&&W.classList.add("e-input-btn-ripple")}(W,this)}function Ul(){var k=this;setTimeout(function(){k.classList.remove("e-input-btn-ripple")},500)}function yb(k,W){var ve=W("span",{className:k});return ve.classList.add("e-input-group-icon"),ve}function I_(k,W,ve,Te){var _e=m(Te)?Si:Te,Ye=yb(k,_e);W.classList.add("e-float-icon-left");var vi=W.querySelector(".e-input-in-wrap");if(m(vi)){vi=_e("span",{className:"e-input-in-wrap"}),ve.parentNode.insertBefore(vi,ve);var Gs=W.querySelectorAll(ve.tagName+" ~ *");vi.appendChild(ve);for(var ts=0;ts-1)if("class"===_e){var Ye=this.getInputValidClassList(k[""+_e]);""!==Ye&&V([W],Ye.split(" "))}else if("style"===_e){var vi=W.getAttribute(_e);vi=m(vi)?k[""+_e]:vi+k[""+_e],W.setAttribute(_e,vi)}else W.setAttribute(_e,k[""+_e])}},n.isBlank=function Hle(k){return!k||/^\s*$/.test(k)}}(Le||(Le={})),new RegExp("^(-)?(\\d*)$"),new RegExp("^[A-Za-z0-9._%+-]{1,}@[A-Za-z0-9._%+-]{1,}([.]{1}[a-zA-Z0-9]{2,}|[.]{1}[a-zA-Z0-9]{2,4}[.]{1}[a-zA-Z0-9]{2,4})$"),new RegExp("^([0-9]{4})-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])$"),new RegExp("^[0-9]*$"),new RegExp("^[+]?[0-9]{9,13}$"),new RegExp("^\\d{13,16}$");var me=function(){function n(t,e){this.width=t,this.height=e}return n.prototype.isEmpty=function(){return 0===this.height&&0===this.width},n.prototype.clone=function(){return new n(this.width,this.height)},n}(),Rie=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),KB=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},R=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Rie(t,n),t.equals=function(e,i){return e===i||!(!e||!i)&&(!e||!i||e.x===i.x&&e.y===i.y)},t.isEmptyPoint=function(e){return!(e.x&&e.y)},t.transform=function(e,i,r){var s={x:0,y:0};return s.x=Math.round(100*(e.x+r*Math.cos(i*Math.PI/180)))/100,s.y=Math.round(100*(e.y+r*Math.sin(i*Math.PI/180)))/100,s},t.findLength=function(e,i){return Math.sqrt(Math.pow(e.x-i.x,2)+Math.pow(e.y-i.y,2))},t.findAngle=function(e,i){var r=Math.atan2(i.y-e.y,i.x-e.x);return r=180*r/Math.PI,(r%=360)<0&&(r+=360),r},t.distancePoints=function(e,i){return Math.sqrt(Math.pow(i.x-e.x,2)+Math.pow(i.y-e.y,2))},t.getLengthFromListOfPoints=function(e){for(var i=0,r=0;ri.y&&!r?o.y+=s:o.y-=s:e.y===i.y?e.xi.x&&!r?o.x+=s:o.x-=s:r?(a=this.findAngle(e,i),o=this.transform(e,a,s)):(a=this.findAngle(i,e),o=this.transform(i,a,s)),o},t.direction=function(e,i){return Math.abs(i.x-e.x)>Math.abs(i.y-e.y)?e.x0)for(var r=0;rt.right||this.top>t.bottom||this.bottom=t.right&&this.top<=t.top&&this.bottom>=t.bottom},n.prototype.containsPoint=function(t,e){return void 0===e&&(e=0),this.left-e<=t.x&&this.right+e>=t.x&&this.top-e<=t.y&&this.bottom+e>=t.y},n.toBounds=function(t){for(var e=new n,i=0,r=t;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},s3=function(n){if(n)switch(n.type){case"Linear":default:return wI;case"Radial":return Gie}return wI},Yie=function(){return function n(t,e,i,r){this.left=t,this.right=e,this.top=i,this.bottom=r}}(),Jn=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),rt([I(0)],t.prototype,"left",void 0),rt([I(0)],t.prototype,"right",void 0),rt([I(0)],t.prototype,"top",void 0),rt([I(0)],t.prototype,"bottom",void 0),t}(Ee),Qie=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),rt([I(45)],t.prototype,"angle",void 0),rt([I(5)],t.prototype,"distance",void 0),rt([I(.7)],t.prototype,"opacity",void 0),rt([I("lightgrey")],t.prototype,"color",void 0),t}(Ee),o3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),t.prototype.getClassName=function(){return"Stop"},rt([I("")],t.prototype,"color",void 0),rt([I(0)],t.prototype,"offset",void 0),rt([I(1)],t.prototype,"opacity",void 0),t}(Ee),wx=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),rt([Bt([],o3)],t.prototype,"stops",void 0),rt([I("None")],t.prototype,"type",void 0),rt([I("")],t.prototype,"id",void 0),t}(Ee),wI=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),rt([I(0)],t.prototype,"x1",void 0),rt([I(0)],t.prototype,"x2",void 0),rt([I(0)],t.prototype,"y1",void 0),rt([I(0)],t.prototype,"y2",void 0),t}(wx),Gie=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),rt([I(0)],t.prototype,"cx",void 0),rt([I(0)],t.prototype,"cy",void 0),rt([I(0)],t.prototype,"fx",void 0),rt([I(0)],t.prototype,"fy",void 0),rt([I(50)],t.prototype,"r",void 0),t}(wx),Nl=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),rt([I("white")],t.prototype,"fill",void 0),rt([I("black")],t.prototype,"strokeColor",void 0),rt([I("")],t.prototype,"strokeDashArray",void 0),rt([I(1)],t.prototype,"strokeWidth",void 0),rt([I(1)],t.prototype,"opacity",void 0),rt([T0(s3)],t.prototype,"gradient",void 0),t}(Ee),a3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),rt([I("transparent")],t.prototype,"fill",void 0),t}(Nl),qf=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),rt([I("black")],t.prototype,"color",void 0),rt([I("Arial")],t.prototype,"fontFamily",void 0),rt([I(12)],t.prototype,"fontSize",void 0),rt([I(!1)],t.prototype,"italic",void 0),rt([I(!1)],t.prototype,"bold",void 0),rt([I("CollapseSpace")],t.prototype,"whiteSpace",void 0),rt([I("WrapWithOverflow")],t.prototype,"textWrapping",void 0),rt([I("Center")],t.prototype,"textAlign",void 0),rt([I("None")],t.prototype,"textDecoration",void 0),rt([I("Wrap")],t.prototype,"textOverflow",void 0),rt([I("transparent")],t.prototype,"fill",void 0),t}(Nl),on=function(n){return n[n.Default=0]="Default",n[n.expandNode=2]="expandNode",n[n.interaction=4]="interaction",n[n.GroupingInProgress=8]="GroupingInProgress",n[n.GroupClipboardInProcess=16]="GroupClipboardInProcess",n[n.ClearObject=32]="ClearObject",n}(on||{}),ci=function(n){return n[n.Visible=1]="Visible",n[n.Hidden=2]="Hidden",n[n.Hover=4]="Hover",n[n.Connect=8]="Connect",n}(ci||{}),Kt=function(n){return n[n.None=0]="None",n[n.ShowHorizontalLines=1]="ShowHorizontalLines",n[n.ShowVerticalLines=2]="ShowVerticalLines",n[n.ShowLines=3]="ShowLines",n[n.SnapToHorizontalLines=4]="SnapToHorizontalLines",n[n.SnapToVerticalLines=8]="SnapToVerticalLines",n[n.SnapToLines=12]="SnapToLines",n[n.SnapToObject=16]="SnapToObject",n[n.All=31]="All",n}(Kt||{}),mr=function(n){return n[n.None=1]="None",n[n.ConnectorSourceThumb=2]="ConnectorSourceThumb",n[n.ConnectorTargetThumb=4]="ConnectorTargetThumb",n[n.ResizeSouthEast=8]="ResizeSouthEast",n[n.ResizeSouthWest=16]="ResizeSouthWest",n[n.ResizeNorthEast=32]="ResizeNorthEast",n[n.ResizeNorthWest=64]="ResizeNorthWest",n[n.ResizeEast=128]="ResizeEast",n[n.ResizeWest=256]="ResizeWest",n[n.ResizeSouth=512]="ResizeSouth",n[n.ResizeNorth=1024]="ResizeNorth",n[n.Rotate=2048]="Rotate",n[n.UserHandle=4096]="UserHandle",n[n.ToolTip=8192]="ToolTip",n[n.ResizeAll=2046]="ResizeAll",n[n.All=16382]="All",n}(mr||{}),qe=function(n){return n[n.None=1]="None",n[n.Select=2]="Select",n[n.Delete=4]="Delete",n[n.Drag=8]="Drag",n[n.DragSourceEnd=16]="DragSourceEnd",n[n.DragTargetEnd=32]="DragTargetEnd",n[n.DragSegmentThumb=64]="DragSegmentThumb",n[n.AllowDrop=128]="AllowDrop",n[n.Bridging=256]="Bridging",n[n.BridgeObstacle=512]="BridgeObstacle",n[n.InheritBridging=1024]="InheritBridging",n[n.PointerEvents=2048]="PointerEvents",n[n.Tooltip=4096]="Tooltip",n[n.InheritTooltip=8192]="InheritTooltip",n[n.Interaction=4218]="Interaction",n[n.ReadOnly=16384]="ReadOnly",n[n.LineRouting=32768]="LineRouting",n[n.InheritLineRouting=65536]="InheritLineRouting",n[n.ConnectToNearByNode=131072]="ConnectToNearByNode",n[n.ConnectToNearByPort=262144]="ConnectToNearByPort",n[n.ConnectToNearByElement=393216]="ConnectToNearByElement",n[n.InheritSegmentThumbShape=524288]="InheritSegmentThumbShape",n[n.InheritSegmentThumbSize=1048576]="InheritSegmentThumbSize",n[n.Default=2043454]="Default",n}(qe||{}),Nr=function(n){return n[n.ReadOnly=2]="ReadOnly",n[n.InheritReadOnly=4]="InheritReadOnly",n[n.Select=8]="Select",n[n.Drag=16]="Drag",n[n.Resize=32]="Resize",n[n.Rotate=64]="Rotate",n[n.Tooltip=128]="Tooltip",n[n.Interaction=120]="Interaction",n[n.None=0]="None",n}(Nr||{}),ie=function(n){return n[n.None=0]="None",n[n.Select=2]="Select",n[n.Drag=4]="Drag",n[n.Rotate=8]="Rotate",n[n.Shadow=16]="Shadow",n[n.PointerEvents=32]="PointerEvents",n[n.Delete=64]="Delete",n[n.InConnect=128]="InConnect",n[n.OutConnect=256]="OutConnect",n[n.Individual=512]="Individual",n[n.Expandable=1024]="Expandable",n[n.AllowDrop=2048]="AllowDrop",n[n.Inherit=78]="Inherit",n[n.ResizeNorthEast=4096]="ResizeNorthEast",n[n.ResizeEast=8192]="ResizeEast",n[n.ResizeSouthEast=16384]="ResizeSouthEast",n[n.ResizeSouth=32768]="ResizeSouth",n[n.ResizeSouthWest=65536]="ResizeSouthWest",n[n.ResizeWest=131072]="ResizeWest",n[n.ResizeNorthWest=262144]="ResizeNorthWest",n[n.ResizeNorth=524288]="ResizeNorth",n[n.Resize=1044480]="Resize",n[n.AspectRatio=1048576]="AspectRatio",n[n.Tooltip=2097152]="Tooltip",n[n.InheritTooltip=4194304]="InheritTooltip",n[n.ReadOnly=8388608]="ReadOnly",n[n.HideThumbs=16777216]="HideThumbs",n[n.AllowMovingOutsideLane=33554432]="AllowMovingOutsideLane",n[n.Default=5240814]="Default",n}(ie||{}),Xr=function(n){return n[n.None=0]="None",n[n.ElementIsPort=2]="ElementIsPort",n[n.ElementIsGroup=4]="ElementIsGroup",n[n.HorizontalLaneHeader=8]="HorizontalLaneHeader",n}(Xr||{}),bt=function(n){return n[n.Rotate=2]="Rotate",n[n.ConnectorSource=4]="ConnectorSource",n[n.ConnectorTarget=8]="ConnectorTarget",n[n.ResizeNorthEast=16]="ResizeNorthEast",n[n.ResizeEast=32]="ResizeEast",n[n.ResizeSouthEast=64]="ResizeSouthEast",n[n.ResizeSouth=128]="ResizeSouth",n[n.ResizeSouthWest=256]="ResizeSouthWest",n[n.ResizeWest=512]="ResizeWest",n[n.ResizeNorthWest=1024]="ResizeNorthWest",n[n.ResizeNorth=2048]="ResizeNorth",n[n.Default=4094]="Default",n}(bt||{}),nt=function(n){return n[n.None=1]="None",n[n.Bridging=2]="Bridging",n[n.UndoRedo=4]="UndoRedo",n[n.Tooltip=8]="Tooltip",n[n.UserInteraction=16]="UserInteraction",n[n.ApiUpdate=32]="ApiUpdate",n[n.PageEditable=48]="PageEditable",n[n.Zoom=64]="Zoom",n[n.PanX=128]="PanX",n[n.PanY=256]="PanY",n[n.Pan=384]="Pan",n[n.ZoomTextEdit=512]="ZoomTextEdit",n[n.Virtualization=1024]="Virtualization",n[n.LineRouting=2048]="LineRouting",n[n.Default=500]="Default",n}(nt||{}),ri=function(n){return n[n.None=0]="None",n[n.SingleSelect=1]="SingleSelect",n[n.MultipleSelect=2]="MultipleSelect",n[n.ZoomPan=4]="ZoomPan",n[n.DrawOnce=8]="DrawOnce",n[n.ContinuousDraw=16]="ContinuousDraw",n[n.Default=3]="Default",n}(ri||{}),Qa=function(n){return n[n.Self=1]="Self",n[n.Parent=2]="Parent",n}(Qa||{}),ft=function(n){return n[n.None=0]="None",n[n.Control=1]="Control",n[n.Meta=1]="Meta",n[n.Alt=2]="Alt",n[n.Shift=4]="Shift",n}(ft||{}),Mt=function(n){return n[n.None=null]="None",n[n.Number0=0]="Number0",n[n.Number1=1]="Number1",n[n.Number2=2]="Number2",n[n.Number3=3]="Number3",n[n.Number4=4]="Number4",n[n.Number5=5]="Number5",n[n.Number6=6]="Number6",n[n.Number7=7]="Number7",n[n.Number8=8]="Number8",n[n.Number9=9]="Number9",n[n.A=65]="A",n[n.B=66]="B",n[n.C=67]="C",n[n.D=68]="D",n[n.E=69]="E",n[n.F=70]="F",n[n.G=71]="G",n[n.H=72]="H",n[n.I=73]="I",n[n.J=74]="J",n[n.K=75]="K",n[n.L=76]="L",n[n.M=77]="M",n[n.N=78]="N",n[n.O=79]="O",n[n.P=80]="P",n[n.Q=81]="Q",n[n.R=82]="R",n[n.S=83]="S",n[n.T=84]="T",n[n.U=85]="U",n[n.V=86]="V",n[n.W=87]="W",n[n.X=88]="X",n[n.Y=89]="Y",n[n.Z=90]="Z",n[n.Left=37]="Left",n[n.Up=38]="Up",n[n.Right=39]="Right",n[n.Down=40]="Down",n[n.Escape=27]="Escape",n[n.Space=32]="Space",n[n.PageUp=33]="PageUp",n[n.PageDown=34]="PageDown",n[n.End=35]="End",n[n.Home=36]="Home",n[n.Delete=46]="Delete",n[n.Tab=9]="Tab",n[n.Enter=13]="Enter",n[n.BackSpace=8]="BackSpace",n[n.F1=112]="F1",n[n.F2=113]="F2",n[n.F3=114]="F3",n[n.F4=115]="F4",n[n.F5=116]="F5",n[n.F6=117]="F6",n[n.F7=118]="F7",n[n.F8=119]="F8",n[n.F9=120]="F9",n[n.F10=121]="F10",n[n.F11=122]="F11",n[n.F12=123]="F12",n[n.Star=56]="Star",n[n.Plus=187]="Plus",n[n.Minus=189]="Minus",n[n.BracketLeft=219]="BracketLeft",n[n.BracketRight=221]="BracketRight",n}(Mt||{}),ee=function(n){return n[n.Render=2]="Render",n[n.PublicMethod=4]="PublicMethod",n[n.ToolAction=8]="ToolAction",n[n.UndoRedo=16]="UndoRedo",n[n.TextEdit=32]="TextEdit",n[n.Group=64]="Group",n[n.Clear=128]="Clear",n[n.PreventClearSelection=256]="PreventClearSelection",n[n.Interactions=512]="Interactions",n[n.PreventHistory=1024]="PreventHistory",n[n.PreventIconsUpdate=2048]="PreventIconsUpdate",n[n.PreventCollectionChangeOnDragOver=4096]="PreventCollectionChangeOnDragOver",n[n.PreventZIndexOnDragging=8192]="PreventZIndexOnDragging",n[n.isGroupDragging=16384]="isGroupDragging",n[n.DragUsingMouse=32768]="DragUsingMouse",n[n.DecoratorPropertyChange=65536]="DecoratorPropertyChange",n[n.PreventLaneContainerUpdate=131072]="PreventLaneContainerUpdate",n}(ee||{}),Ga=function(n){return n[n.None=2]="None",n[n.DrawSelectorBorder=4]="DrawSelectorBorder",n[n.PreventRenderSelector=8]="PreventRenderSelector",n}(Ga||{}),$i=function(n){return n[n.None=0]="None",n[n.PreventDrag=2]="PreventDrag",n[n.PreventScale=4]="PreventScale",n[n.PreventDataInit=8]="PreventDataInit",n[n.hScrollbarMoved=16]="hScrollbarMoved",n[n.vScrollbarMoved=32]="vScrollbarMoved",n[n.AnimationClick=64]="AnimationClick",n[n.EnableGroupAction=128]="EnableGroupAction",n[n.PanInProgress=256]="PanInProgress",n[n.OverViewAction=512]="OverViewAction",n}($i||{}),da=function(n){return n[n.None=0]="None",n[n.PropertyChange=1024]="PropertyChange",n[n.Interaction=2048]="Interaction",n}(da||{}),Ae=function(n){return n[n.Zero=0]="Zero",n[n.One=1]="One",n[n.Two=2]="Two",n[n.Three=3]="Three",n[n.Four=4]="Four",n[n.Five=5]="Five",n}(Ae||{}),Ce=function(n){return n[n.collectionChange=0]="collectionChange",n[n.rotateChange=1]="rotateChange",n[n.positionChange=2]="positionChange",n[n.propertyChange=3]="propertyChange",n[n.selectionChange=4]="selectionChange",n[n.sizeChange=5]="sizeChange",n[n.drop=6]="drop",n[n.sourcePointChange=7]="sourcePointChange",n[n.targetPointChange=8]="targetPointChange",n[n.connectionChange=9]="connectionChange",n[n.animationComplete=10]="animationComplete",n[n.click=11]="click",n[n.doubleClick=12]="doubleClick",n[n.scrollChange=13]="scrollChange",n[n.dragEnter=14]="dragEnter",n[n.dragLeave=15]="dragLeave",n[n.dragOver=16]="dragOver",n[n.textEdit=17]="textEdit",n[n.paletteSelectionChange=18]="paletteSelectionChange",n[n.historyChange=19]="historyChange",n[n.mouseEnter=20]="mouseEnter",n[n.mouseLeave=21]="mouseLeave",n[n.mouseOver=22]="mouseOver",n[n.expandStateChange=23]="expandStateChange",n[n.segmentCollectionChange=24]="segmentCollectionChange",n[n.commandExecute=25]="commandExecute",n[n.historyStateChange=26]="historyStateChange",n[n.onUserHandleMouseDown=27]="onUserHandleMouseDown",n[n.onUserHandleMouseUp=28]="onUserHandleMouseUp",n[n.onUserHandleMouseEnter=29]="onUserHandleMouseEnter",n[n.onUserHandleMouseLeave=30]="onUserHandleMouseLeave",n[n.onImageLoad=31]="onImageLoad",n[n.onDoBindingInit=32]="onDoBindingInit",n[n.keyUp=33]="keyUp",n[n.keyDown=34]="keyDown",n[n.fixedUserHandleClick=35]="fixedUserHandleClick",n[n.elementDraw=36]="elementDraw",n[n.mouseWheel=37]="mouseWheel",n[n.segmentChange=38]="segmentChange",n[n.onFixedUserHandleMouseDown=39]="onFixedUserHandleMouseDown",n[n.onFixedUserHandleMouseUp=40]="onFixedUserHandleMouseUp",n[n.onFixedUserHandleMouseEnter=41]="onFixedUserHandleMouseEnter",n[n.onFixedUserHandleMouseLeave=42]="onFixedUserHandleMouseLeave",n[n.loaded=43]="loaded",n}(Ce||{}),oi=function(n){return n[n.None=1]="None",n[n.Drag=2]="Drag",n[n.Draw=4]="Draw",n[n.InConnect=8]="InConnect",n[n.OutConnect=16]="OutConnect",n[n.ToolTip=32]="ToolTip",n[n.InheritTooltip=64]="InheritTooltip",n[n.Default=24]="Default",n}(oi||{}),Cx=function(n){return n[n.None=1]="None",n[n.Source=2]="Source",n[n.Target=4]="Target",n[n.Intermediate=8]="Intermediate",n[n.All=14]="All",n}(Cx||{}),CI=function(n){return n[n.None=0]="None",n[n.SymmetricAngle=2]="SymmetricAngle",n[n.SymmetricDistance=4]="SymmetricDistance",n[n.Default=6]="Default",n}(CI||{}),hs=function(){function n(){this.pivot={x:.5,y:.5},this.isDirt=!0,this.isExport=!1,this.exportScaleValue={x:0,y:0},this.exportScaleOffset={x:0,y:0},this.canApplyStyle=!0,this.visible=!0,this.offsetX=0,this.offsetY=0,this.cornerRadius=0,this.minHeight=void 0,this.minWidth=void 0,this.maxWidth=void 0,this.maxHeight=void 0,this.width=void 0,this.height=void 0,this.rotateAngle=0,this.margin={left:0,right:0,top:0,bottom:0},this.connectionDirection="Auto",this.horizontalAlignment="Auto",this.verticalAlignment="Auto",this.flip="None",this.flipMode="All",this.relativeMode="Point",this.transform=Qa.Self|Qa.Parent,this.style={fill:"white",strokeColor:"black",opacity:1,strokeWidth:1},this.desiredSize=new me,this.actualSize=new me,this.parentTransform=0,this.preventContainer=!1,this.isSvgRender=!1,this.bounds=new Ne(0,0,0,0),this.shadow=null,this.description="",this.staticSize=!1,this.shapeType="",this.isRectElement=!1,this.isCalculateDesiredSize=!0,this.flipOffset={x:0,y:0},this.elementActions=Xr.None,this.inversedAlignment=!0,this.position=void 0,this.unitMode=void 0,this.float=!1,this.floatingBounds=void 0}return n.prototype.setOffsetWithRespectToBounds=function(t,e,i){this.unitMode=i,this.position={x:t,y:e}},n.prototype.getAbsolutePosition=function(t){if(void 0!==this.position)return"Absolute"===this.unitMode?this.position:{x:this.position.x*t.width,y:this.position.y*t.height}},Object.defineProperty(n.prototype,"outerBounds",{get:function(){return this.floatingBounds||this.bounds},set:function(t){this.floatingBounds=t},enumerable:!0,configurable:!0}),n.prototype.measure=function(t,e,i){var s=void 0!==this.height?this.height:(t.height||0)-this.margin.top-this.margin.bottom;return this.id&&0===s&&this.elementActions&Xr.HorizontalLaneHeader&&(s=this.actualSize.height),this.desiredSize=new me(void 0!==this.width?this.width:(t.width||0)-this.margin.left-this.margin.right,s),this.isCalculateDesiredSize&&(this.desiredSize=this.validateDesiredSize(this.desiredSize,t)),this.desiredSize},n.prototype.arrange=function(t){return this.actualSize=t,this.updateBounds(),this.actualSize},n.prototype.updateBounds=function(){this.bounds=yr(this)},n.prototype.validateDesiredSize=function(t,e){return this.isRectElement&&!this.width&&!this.minWidth&&!this.maxWidth&&(t.width=50),this.isRectElement&&!this.height&&!this.minHeight&&!this.maxHeight&&(t.height=50),(void 0===t||void 0!==this.width&&void 0!==this.height)&&((t=t||new me).width=void 0===this.width?(e.width||0)-this.margin.left-this.margin.right:this.width,t.height=void 0===this.height?(e.height||0)-this.margin.top-this.margin.bottom:this.height),void 0!==this.minWidth&&(t.width=Math.max(t.width,this.minWidth)),void 0!==this.minHeight&&(t.height=Math.max(t.height,this.minHeight)),void 0!==this.maxWidth&&0!==this.maxWidth&&(t.width=Math.min(t.width,this.maxWidth)),void 0!==this.maxHeight&&0!==this.maxHeight&&(t.height=Math.min(t.height,this.maxHeight)),t},n}(),ere=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Cs=function(n){function t(){var e=null!==n&&n.apply(this,arguments)||this;return e.padding=new Yie(0,0,0,0),e.desiredBounds=void 0,e.measureChildren=!0,e.prevRotateAngle=0,e}return ere(t,n),t.prototype.hasChildren=function(){return void 0!==this.children&&this.children.length>0},t.prototype.measure=function(e,i,r){this.desiredBounds=void 0;var o,a,s=void 0;if(this.hasChildren()){for(var l=0;l=n.width&&s.length>0)i[i.length]={text:s,x:0,dy:0,width:o},s="";else{(s+=a[r+1]||"").indexOf("\n")>-1&&(i[i.length]={text:s,x:0,dy:0,width:Bc(s,n)},s="");var l=Bc(s,n);Math.ceil(l)+2>=n.width&&s.length>0&&(i[i.length]={text:s,x:0,dy:0,width:l},s=""),r===a.length-1&&s.length>0&&(i[i.length]={text:s,x:0,dy:0,width:l},s="")}else i=function Soe(n,t,e){var c,d,u,f,i=[],r="",s=0,o=0,a="nowrap"!==n.whiteSpace,h=(t||n.content).split("\n");for(s=0;s0?" ":"")+c[parseInt(o.toString(),10)];var p=Bc(d=c[o+1]?r+" "+c[o+1]:r,n);Math.floor(p)>(e||n.width)-2&&r.length>0?(i[i.length]={text:r,x:0,dy:0,width:d===r?p:r===f?u:Bc(r,n)},r=""):o===c.length-1&&(i[i.length]={text:r,x:0,dy:0,width:p},r=""),f=d,u=p}return i}(n,t,e);else i[i.length]={text:a,x:0,dy:0,width:Bc(a,n)};return i}(l,r,n.isLaneOrientation?i:void 0),n.wrapBounds=a=function Ioe(n,t){var r,s,e={x:0,width:0},i=0;for(i=0;in.width&&("Ellipsis"===n.textOverflow||"Clip"===n.textOverflow)?0:-r/2:"right"===n.textAlign?-r:t.length>1?0:-r/2,t[parseInt(i.toString(),10)].dy=1.2*n.fontSize,t[parseInt(i.toString(),10)].x=r,e.x=Math.min(e.x,r),e.width=Math.max(e.width,s);return e}(l,o),s.width=a.width,n.wrapBounds.width>=i&&"Wrap"!==l.textOverflow&&(s.width=i),s.height=o.length*n.style.fontSize*1.2,s}(this,0,0,this.isLaneOrientation?e.height:this.width||e.width):this.desiredSize,this.desiredSize=void 0===this.width||void 0===this.height?new me(i.width,i.height):new me(this.width,this.height),this.desiredSize=this.validateDesiredSize(this.desiredSize,e),this.desiredSize},t.prototype.arrange=function(e){return(e.width!==this.actualSize.width||e.height!==this.actualSize.height||this.isDirt)&&(this.doWrap=!0),this.actualSize=e,this.updateBounds(),this.isDirt=!1,this.actualSize},t}(hs),ire=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Mi=function(n){function t(){var e=null!==n&&n.apply(this,arguments)||this;return e.measureChildren=void 0,e}return ire(t,n),t.prototype.measure=function(e,i,r){var s=void 0,o=void 0;if(this.hasChildren()){for(var a=0,l=this.children;a=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Td=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return are(t,n),Ph([I("")],t.prototype,"content",void 0),Ph([I("TopLeft")],t.prototype,"position",void 0),Ph([I("Mouse")],t.prototype,"relativeMode",void 0),Ph([I(!0)],t.prototype,"showTipPointer",void 0),Ph([I("auto")],t.prototype,"width",void 0),Ph([I("auto")],t.prototype,"height",void 0),Ph([I("Auto")],t.prototype,"openOn",void 0),Ph([I()],t.prototype,"animation",void 0),Ph([I(!1)],t.prototype,"isSticky",void 0),t}(Ee);function l3(n){var t=new wh;t=h3(n.tooltip,t);var e=new wh(t);return e.beforeCollision=hre,e.beforeOpen=lre,e.cssClass="e-diagram-tooltip",e.opensOn="custom",e.appendTo("#"+n.element.id),e.close(),e}function lre(n){(""===this.content||void 0===this.content)&&(n.element.style.display="none")}function hre(n){n.collidedPosition&&n.collidedPosition!==this.position&&(n.element.style.display="none")}function Ex(n,t){var e=n.tooltipObject;return h3(t?t.tooltip:n.tooltip,e),e}function h3(n,t){return n.content?(t.content=n.content,"string"==typeof n.content&&(t.content=ko(function(){return n.content})),t.position=n.position,t.showTipPointer=n.showTipPointer,t.width=n.width,t.height=n.height,t.animation=n.animation?n.animation:{close:{effect:"None"}}):t.close(),t}var Dx=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Bn=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},xx=function(n){function t(e,i,r,s){var o=n.call(this,e,i,r,s)||this;return o.inEdges=[],o.outEdges=[],o}return Dx(t,n),Bn([I("")],t.prototype,"id",void 0),Bn([I("Center")],t.prototype,"horizontalAlignment",void 0),Bn([I("Center")],t.prototype,"verticalAlignment",void 0),Bn([re({},Jn)],t.prototype,"margin",void 0),Bn([I(12)],t.prototype,"width",void 0),Bn([I(12)],t.prototype,"height",void 0),Bn([re({},Nl)],t.prototype,"style",void 0),Bn([I("Square")],t.prototype,"shape",void 0),Bn([I("Auto")],t.prototype,"connectionDirection",void 0),Bn([I(ci.Connect)],t.prototype,"visibility",void 0),Bn([I("")],t.prototype,"pathData",void 0),Bn([I(oi.Default)],t.prototype,"constraints",void 0),Bn([I()],t.prototype,"addInfo",void 0),Bn([I()],t.prototype,"outEdges",void 0),Bn([I()],t.prototype,"inEdges",void 0),Bn([re({},Td)],t.prototype,"tooltip",void 0),t}(Ee),Es=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return Dx(t,n),t.prototype.getClassName=function(){return"PointPort"},Bn([re({x:.5,y:.5},R)],t.prototype,"offset",void 0),t}(xx),Tc=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return Dx(t,n),t.prototype.getClassName=function(){return"PathPort"},Bn([I(.5)],t.prototype,"offset",void 0),Bn([re({x:0,y:0},R)],t.prototype,"displacement",void 0),Bn([I("Center")],t.prototype,"alignment",void 0),t}(xx),xI=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),lr=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},cre=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return xI(t,n),lr([I("blue")],t.prototype,"color",void 0),lr([I("")],t.prototype,"content",void 0),lr([I("")],t.prototype,"link",void 0),lr([I("None")],t.prototype,"textDecoration",void 0),lr([I("NewTab")],t.prototype,"hyperlinkOpenState",void 0),t}(Ee),Tx=function(n){function t(e,i,r,s){var o=n.call(this,e,i,r,s)||this;return r.id||(o.id=e.parentObj&&e.parentObj.propName&&"phases"===e.parentObj.propName?e.parentObj.id:Qe()),o}return xI(t,n),lr([I("")],t.prototype,"content",void 0),lr([I(void 0)],t.prototype,"template",void 0),lr([I("String")],t.prototype,"annotationType",void 0),lr([I(!0)],t.prototype,"visibility",void 0),lr([I(Nr.InheritReadOnly)],t.prototype,"constraints",void 0),lr([re(void 0,cre)],t.prototype,"hyperlink",void 0),lr([I("")],t.prototype,"id",void 0),lr([I()],t.prototype,"width",void 0),lr([I()],t.prototype,"height",void 0),lr([I(0)],t.prototype,"rotateAngle",void 0),lr([I("Parent")],t.prototype,"rotationReference",void 0),lr([re({strokeWidth:0,strokeColor:"transparent",fill:"transparent"},qf)],t.prototype,"style",void 0),lr([I("Center")],t.prototype,"horizontalAlignment",void 0),lr([I("Center")],t.prototype,"verticalAlignment",void 0),lr([re({},Jn)],t.prototype,"margin",void 0),lr([re({top:void 0,bottom:void 0,left:void 0,right:void 0},Jn)],t.prototype,"dragLimit",void 0),lr([I("Shape")],t.prototype,"type",void 0),lr([re({},Td)],t.prototype,"tooltip",void 0),lr([I()],t.prototype,"addInfo",void 0),t}(Ee),Kn=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return xI(t,n),t.prototype.getClassName=function(){return"ShapeAnnotation"},lr([re({x:.5,y:.5},R)],t.prototype,"offset",void 0),t}(Tx),Or=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return xI(t,n),t.prototype.getClassName=function(){return"PathAnnotation"},lr([I(.5)],t.prototype,"offset",void 0),lr([re({x:0,y:0},R)],t.prototype,"displacement",void 0),lr([I("Center")],t.prototype,"alignment",void 0),lr([I(!1)],t.prototype,"segmentAngle",void 0),t}(Tx);function Ax(n){return pre[n.toString()]}function c3(n){return mre[""+n]}var pre={X:"M14,14 L106,106 M106,14 L14,106",Circle:"M0,50 A50,50,0 1 1 100,50 A50,50,0 1 1 0,50 Z",Square:"M0,0 L10,0 L10,10 L0,10 z"},gre={OpenArrow:"M15.9,23 L5,16 L15.9,9 L17,10.7 L8.7,16 L17,21.3Z",Square:"M0,0 L10,0 L10,10 L0,10 z",Fletch:"M14.8,10c0,0-3.5,6,0.2,12c0,0-2.5-6-10.9-6C4.1,16,11.3,16,14.8,10z",OpenFetch:"M6,17c-0.6,0-1-0.4-1-1s0.4-1,1-1c10.9,0,11-5,11-5c0-0.6,0.4-1,1-1s1,0.4,1,1C19,10.3,18.9,17,6,17C6,17,6,17,6,17z M18,23c-0.5,0-1-0.4-1-1c0-0.2-0.3-5-11-5c-0.6,0-1-0.5-1-1s0.4-1,1-1c0,0,0,0,0,0c12.9,0,13,6.7,13,7 C19,22.6,18.6,23,18,23z",IndentedArrow:"M17,10c0,0-4.5,5.5,0,12L5,16L17,10z",OutdentedArrow:"M14.6,10c0,0,5.4,6,0,12L5,16L14.6,10z",DoubleArrow:"M19,10 L19,22 L13,16Z M12,10 L12,22 L6,16Z",Arrow:"M15,10 L15,22 L5,16Z",Diamond:"M12,23l-7-7l7-7l6.9,7L12,23z",Circle:"M0,50 A50,50,0 1 1 100,50 A50,50,0 1 1 0,50 Z"},vre={Square:"M0,0 L10,0 L10,10 L0,10 z",Rhombus:"M10,5 L5,10 L0,5 L5,0 L10,5 Z ",Rectangle:"M0,0 L15,0 L15,10 L0,10 z ",OpenArrow:"M15.9,23 L5,16 L15.9,9 L17,10.7 L8.7,16 L17,21.3Z",Fletch:"M9.82,0 C9.82,0,6.61,5,10,10 C10,10,7.71,5,0,5 C0,5,6.61,5,9.82,0 Z ",OpenFetch:"M0.71,5.71 C0.29,5.71,0,5.43,0,5 C0,4.57,0.29,4.29,0.71,4.29 C8.5,4.29,8.57,0.71,8.57,0.71 C8.57,0.29,8.86,0,9.29,0 C9.719999999999999,0,10,0.29,10,0.71 C10,0.93,9.93,5.71,0.71,5.71 C0.71,5.71,0.71,5.71,0.71,5.71 Z M9.29,10 C8.93,10,8.57,9.71,8.57,9.29 C8.57,9.14,8.36,5.71,0.71,5.71 C0.29,5.71,0,5.36,0,5 C0,4.64,0.29,4.29,0.71,4.29 C0.71,4.29,0.71,4.29,0.71,4.29 C9.93,4.29,10,9.07,10,9.29 C10,9.71,9.71,10,9.29,10 Z ",IndentedArrow:"M10,0 C10,0,6.25,4.58,10,10 L0,5 L10,0 Z ",OutdentedArrow:"M8,0 C8,0,12.5,5,8,10 L0,5 L8,0 Z ",DoubleArrow:"M19,10 L19,22 L13,16Z M12,10 L12,22 L6,16Z",Arrow:"M15,10 L15,22 L5,16Z",Diamond:"M10,5 L5,10 L0,5 L5,0 L10,5 Z ",Circle:"M10,5 C10,7.76,7.76,10,5,10 C2.24,10,0,7.76,0,5 C0,2.24,2.24,0,5,0 C7.76,0,10,2.24,10,5 Z ",Ellipse:"M15,5 C15,7.76,11.64,10,7.5,10 C3.36,10,0,7.76,0,5 C0,2.24,3.36,0,7.5,0 C11.64,0,15,2.24,15,5 Z "},mre={Square:"M0,0 L10,0 L10,10 L0,10 z",Rhombus:"M10,5 L5,10 L0,5 L5,0 L10,5 Z ",Rectangle:"M0,0 L15,0 L15,10 L0,10 z",OpenArrow:"M23,15.9 L16,5 L9,15.9 L10.7,17 L16,8.7 L21,17.3Z",Fletch:"M9.82,0 C9.82,0,6.61,5,10,10 C10,10,7.71,5,0,5 C0,5,6.61,5,9.82,0 Z ",OpenFetch:"M0.71,5.71 C0.29,5.71,0,5.43,0,5 C0,4.57,0.29,4.29,0.71,4.29 C8.5,4.29,8.57,0.71,8.57,0.71 C8.57,0.29,8.86,0,9.29,0 C9.719999999999999,0,10,0.29,10,0.71 C10,0.93,9.93,5.71,0.71,5.71 C0.71,5.71,0.71,5.71,0.71,5.71 Z M9.29,10 C8.93,10,8.57,9.71,8.57,9.29 C8.57,9.14,8.36,5.71,0.71,5.71 C0.29,5.71,0,5.36,0,5 C0,4.64,0.29,4.29,0.71,4.29 C0.71,4.29,0.71,4.29,0.71,4.29 C9.93,4.29,10,9.07,10,9.29 C10,9.71,9.71,10,9.29,10 Z ",IndentedArrow:"M10,0 C10,0,6.25,4.58,10,10 L0,5 L10,0 Z ",OutdentedArrow:"M8,0 C8,0,12.5,5,8,10 L0,5 L8,0 Z ",DoubleArrow:"M10,19 L22,19 L16,13Z M10,12 L22,12 L16,6Z",Arrow:"M10,15 L22,15 L16,5Z",Diamond:"M10,5 L5,10 L0,5 L5,0 L10,5 Z ",Circle:"M10,5 C10,7.76,7.76,10,5,10 C2.24,10,0,7.76,0,5 C0,2.24,2.24,0,5,0 C7.76,0,10,2.24,10,5 Z ",Ellipse:"M15,5 C15,7.76,11.64,10,7.5,10 C3.36,10,0,7.76,0,5 C0,2.24,3.36,0,7.5,0 C11.64,0,15,2.24,15,5 Z "};function Lx(n){return yre[n.toString()]}var yre={Process:"M419.511,76.687L359.511,76.687L359.511,43.086L419.511,43.086z",Decision:"M 253.005,115.687L 200.567,146.071L 148.097,115.687L 200.534,85.304L 253.005,115.687 Z",Document:"M 60 31.9 c 0 0 -11 -7.7 -30 0 s -30 0 -30 0 V 0 h 60 V 31.9 Z",PreDefinedProcess:"M 0,0 L 50,0 L 50,50 L 0,50 Z M 8.334,0 L 8.334,50 M 41.667,0 L 41.667,50",Terminator:"M 269.711,29.33C 269.71,44.061 257.77,56 243.04,56L 158.058,56C 143.33,56 131.39,44.061 131.39,29.33L 131.39,29.33C 131.391,14.6057 143.33,2.669 158.058,2.669L 243.044,2.669C 257.772,2.669 269.711,14.6057 269.711,29.333 Z",PaperTap:"M0.0009,17.2042 L0.0009,47.165 C0.001,47.165 14.403,53.5455 25.00,47.165 C35.599,40.7852 44.403,43.5087 50.00,47.165L50.001,17.2042 M50.001,32.7987 L50.001,2.8405 C50.001,2.8405 35.599,-3.5427 25.001,2.8405C14.403,9.2237 5.599,6.494 0.0009,2.8405 L0.0009,32.7987",DirectData:"M 132.62 0 L 17.38 0 C 7.78 0 0 13.43 0 30 C 0 46.57 7.78 60 17.38 60 L 132.62 60 M 132.62 0C 123.02 0 115.24 13.43 115.24 30 C 115.24 46.57 123.02 60 132.62 60 C 142.22 60 150 46.57 150 30 C 150 13.43 142.22 0 132.62 0 z ",SequentialData:"M0.0029,24.999 C0.0029,11.1922 10.433,0.0021 23.295,0.0021 C36.159,0.00216 46.585,11.1922 46.585,24.999C46.585,38.8057 36.159,49.9979 23.295,49.9979 C10.433,49.9979 0.0029,38.8057 0.0029,24.999 z M23.294,49.999 L50.002,49.999",Sort:"M50.001,24.9971 L25.001,49.9971 L0.00097,24.9971 L25.001,-0.00286865 L50.001,24.9971 z M0.000976562,24.9971 L50.001,24.9971",MultiDocument:"M43.6826,40 C44.8746,40.6183 45.8586,41.3502 46.8366,42.1122 L46.8366,4.74487 L3.09857,4.74487 L3.09857,10.9544 M46.837,35.143 C48.027,35.765 49.025,36.604 50.003,37.369 L50.003,0.002 L6.264,0.002 L6.264,4.744 M43.682,47.113 L43.682,10.765 L0.0025,10.7652 L0.0025,47.1132 C0.0025,47.1132 12.5846,53.6101 21.8426,47.1132 C31.1006,40.6163 38.792,43.393 43.6826,47.1132 z",Collate:"M50.001,0.0028 L25.001,25.0029 L0.00097,0.0028 L50.001,0.002 z M0.0009,50.002 L25.001,25.002L50.001,50.002 L0.0009,50.0029 z",SummingJunction:"M7.3252,42.6768 L42.6772,7.3247 M42.6768,42.6768 L7.3248,7.3247 M0.0009,25.001 C0.0009,11.193 11.197,0.0009 25.001,0.0009 C38.809,0.0009 50.001,11.193 50.001,25.001 C50.001,38.809 38.809,50.001 25.001,50.001 C11.197,50.00 0.0009,38.809 0.0009,25.00 z",Or:"M 0 50 L 100 50 M 50 100 L 50 0.0 M 0 50 C 0 22.384 22.392 0 50 0 C 77.616 0 100 22.384 100 50 C 100 77.616 77.616 100 50 100 C 22.392 100 0 77.616 0 50 Z",InternalStorage:"M 0 3.81946A 2.5,3.81946 0 0,1 2.5,0L 47.5 0A 2.5,3.81946 0 0,1 50,3.81946L 50 45.836A 2.5,3.819446 0 0,1 47.5,49.652778L 2.5 49.652778A 2.5,3.819446 0 0,1 0,45.8336L 0 3.819446ZM 0 11.45834L 50 11.4583334M 12.5 0L 12.5 49.652778",Extract:"M0,35 L30,0 L60,35 Z",ManualOperation:"M46.4,28.8 L14.8,28.8 L0,0 L60,0 Z",Merge:"M60,0 L30,35 L0,0 Z",OffPageReference:"M60,33.3 L30.1,39 L0,33.3 L0,0 L60,0 Z",SequentialAccessStorage:"M 60 30 C 60 13.4 46.6 0 30 0 S 0 13.4 0 30 s 13.4 30 30 30 h 28.6 v -6.5 h -9.9C 55.5 48 60 39.5 60 30 Z",Annotation:"M49.9984,50.0029 L-0.00271199,50.0029 L-0.00271199,0.00286865 L49.9984,0.00286865",Annotation2:"M49.9977,50.0029 L25.416,50.0029 L25.416,0.00286865 L49.9977,0.00286865 M25.4166,25.0029 L-0.00227869,25.0029",Data:"M 10 0 L 40 0 L 30 40 L 0 40 Z",Card:"M275,60 L400,60 L400,110 L260,110 L260,75 Z",Delay:"M0,0 L12.029,0 C14.212999,0 16,1.7869979 16,3.9709952 C16,6.1549926 14.212999,7.9409904 12.029,7.9409904 L0,7.9409904 z",Preparation:"M 1048.17 572 C 1051.06 568.86 1055.17 567.05 1059.5 567 L 1094.51 567 C 1098.84 567.05 1102.95 568.86 1105.84 572 L 1126.43 595 C 1127.01 596.28 1127.01 597.72 1126.43 599 L 1105.84 622 C 1102.95 625.14 1098.84 626.95 1094.51 627 L 1059.5 627 C 1055.17 626.95 1051.06 625.14 1048.17 622 L 1027.58 599 C 1027 597.72 1027 596.28 1027.58 595 L 1048.17 572 Z",Display:"M47.8809,19.2914 L32.7968,-0.00594145 L11.3902,-0.00594145 C7.93166,-0.00594145 0.00124586,11.187 0.00124586,24.9968C0.00124586,38.8032 7.93166,49.9962 11.3902,49.9962 L32.7968,49.99 L47.615,31.038 C47.615,31.0388 52.798,24.9968 47.880,19.2914 z",ManualInput:"M 912 732 L 1006.85 707 C 1008.2 707 1009.5 707.53 1010.46 708.46 C 1011.41 709.4 1011.95 710.67 1011.95 712 L 1011.95 762C 1012 764.41 1010.28 766.52 1007.87 767 L 917.1 767 C 915.75 767 914.45 766.47 913.49 765.54 C 912.54 764.6 912 763.33 912 762 L 912 732 Z",LoopLimit:"M 8 9 L 27 9 L 33 15 L 33 26 C 33 27 33 27 32 27 L 4 27 C 3 27 2 27 2 26 L 2 15 L 8 9 Z",StoredData:"M 5.55 0L 50 0A 1.5,30 0 0,1 50,0A 5.555,25 0 0,0 50,50A 1.5,30 0 0,1 50,50L 5.555 50A 5.55,25 0 0,1 5.555,0Z"};function d3(n,t,e){var i;i="Straight"!==n.type&&n.sourceWrapper?n.sourceWrapper.corners.center:function Sre(n){var t;if(n.sourcePortWrapper){var e=n.sourcePortWrapper;t={x:e.offsetX,y:e.offsetY}}else t=n.sourceID&&n.sourceWrapper&&n.targetWrapper?qa(n,0,n.sourceWrapper.corners.center,n.targetWrapper.corners.center,!1):n.sourcePoint;return t}(n);var r=function bre(n,t,e,i,r){var b,M,s=n.sourceWrapper,o=n.targetWrapper,a=n.sourcePortWrapper,l=n.targetPortWrapper,d=[],p=Xa(n),y={corners:undefined,point:t,direction:undefined,margin:{left:5,right:5,bottom:5,top:5}},S={corners:undefined,point:e,direction:undefined,margin:{left:5,right:5,bottom:5,top:5}};if(void 0!==s&&void 0!==o&&(b=xn(s),M=xn(o),y.corners=s.corners,S.corners=o.corners),void 0!==a&&(y.direction="Left"===a.connectionDirection||"Top"===a.connectionDirection||"Bottom"===a.connectionDirection||"Right"===a.connectionDirection?a.connectionDirection:zo({x:a.offsetX,y:a.offsetY},b,s.bounds)),void 0!==l&&(S.direction="Left"===l.connectionDirection||"Right"===l.connectionDirection||"Bottom"===l.connectionDirection||"Top"===l.connectionDirection?l.connectionDirection:zo({x:l.offsetX,y:l.offsetY},M,o.bounds)),"Bezier"===n.type&&!n.isBezierEditing&&n.segments.length>0)for(var D=n.segments.length-1;D>=0;)n.segments[parseInt(D.toString(),10)].isInternalSegment&&n.segments.pop(),D--;if(void 0!==s&&void 0!==o)return(void 0===y.direction||void 0===S.direction)&&(i?function Ire(n,t,e){"LeftToRight"===e?(n.direction=n.direction?n.direction:"Right",t.direction=t.direction?t.direction:"Left"):"RightToLeft"===e?(n.direction=n.direction?n.direction:"Left",t.direction=t.direction?t.direction:"Right"):"TopToBottom"===e?(n.direction=n.direction?n.direction:"Bottom",t.direction=t.direction?t.direction:"Top"):"BottomToTop"===e&&(n.direction=n.direction?n.direction:"Top",t.direction=t.direction?t.direction:"Bottom")}(y,S,i):y.corners.top>S.corners.bottom&&Math.abs(y.corners.top-S.corners.bottom)>p?(y.direction=y.direction?y.direction:"Top",S.direction=S.direction?S.direction:"Bottom"):y.corners.bottomp?(y.direction=y.direction?y.direction:"Bottom",S.direction=S.direction?S.direction:"Top"):y.corners.rightp||y.corners.right+p=y.corners.left-p&&y.corners.left>S.corners.left?(y.direction=y.direction?y.direction:"Right",S.direction=S.direction?S.direction:"Left"):y.corners.left>S.corners.right&&Math.abs(y.corners.left-S.corners.right)>y.margin.left+y.margin.right||S.corners.right+p=S.corners.left-p&&y.corners.left0&&n.segments[0].direction&&(y.direction=n.segments[0].direction),y.point=Ol(b,y.direction),d=Ol(b,_n(y.direction)),y.point=qa(n,0,y.point,d,!1)):y.point=o.corners.center;if(void 0!==h){switch(S.point={x:h.offsetX,y:h.offsetY},S.direction){case"Bottom":case"Top":S.point.y=S.point.y;break;case"Left":case"Right":S.point.x=S.point.x}n.targetPadding&&!w&&(S.point=TI(n,y,S,!0))}else"Orthogonal"===n.type||"Bezier"===n.type?(S.point=Ol(M,S.direction),d=Ol(M,_n(S.direction)),S.point=qa(n,0,S.point,d,!0)):S.point=a.corners.center;if("Orthogonal"!==n.type){var C=void 0,D=void 0;if("Bezier"===n.type){if(n.bezierSettings.allowSegmentsReset||0===n.segments.length||!R.isEmptyPoint(n.segments[n.segments.length-1].point))return c=b3(n,y,S,void 0,s),Nx(n,y,S);Uv(n)}else Uv(n);if(void 0===n.sourcePortWrapper){y.point=y.corners.center,n.segments&&n.segments.length>0&&(C=R.isEmptyPoint((D=n.segments[0]).point)?void 0:D);var A=void 0!==C?C.point:S.point;if("Bezier"===n.type&&n.segments.length>0&&n.segments[0].vector1.angle&&n.segments[0].vector1.distance){var x=Math.max(y.corners.width,y.corners.height);A=R.transform(y.point,n.segments[0].vector1.angle,x/2)}y.point=w?n.sourceWrapper.bounds.center:qa(n,0,y.point,A,!1)}if(void 0===n.targetPortWrapper){S.point=S.corners.center,n.segments&&n.segments.length>1&&(C=R.isEmptyPoint((D=n.segments[n.segments.length-2]).point)?void 0:D);var P=C?C.point:y.point;"Bezier"===n.type&&n.segments.length>0&&n.segments[n.segments.length-1].vector2.angle&&n.segments[n.segments.length-1].vector2.distance&&(x=Math.max(y.corners.width,y.corners.height),P=R.transform(S.point,n.segments[0].vector2.angle,x/2)),S.point=w?n.targetWrapper.bounds.center:qa(n,0,P,S.point,!0)}c=Nx(n,y,S)}else"Orthogonal"===n.type&&n.segments&&n.segments.length>0&&null!==n.segments[0].direction?c=function Nre(n,t,e,i,r,s,o){var a,h,c,d;Uv(n);for(var u=0;u0&&n.segments[u-1].direction===h.direction?u=y3(n,u,t):h.direction?t.point=u3(t,n.segments[parseInt(u.toString(),10)]):(f=n.segments[u-1])&&f.points&&f.points.length>0&&(t.point=f.points[f.points.length-1]),u===n.segments.length-1)if(S3(n,t),v3(a=void 0===r?Lre(n,t,e):p3(n,t,e),n),h.points=[],a.length>=2)for(c=0;c2&&n.segments.length>2){var p={x:a[parseInt(c.toString(),10)].x,y:t.point.y};h.points=[],h.points.push(p),h.points.push(a[parseInt(c.toString(),10)]);var f=n.segments[u-1];n.segments.length<4&&f.points.pop(),f.points=f.points.concat(h.points)}else h.points.push(a[parseInt(c.toString(),10)]);else h.points.push(a[parseInt(c.toString(),10)]);else d=u;if(void 0!==d&&!n.selectedSegmentIndex&&(d===n.segments.length-1&&(n.segments[d-1].direction=null,n.segments[d-1].length=null),n.segments.splice(d,1)),i&&0===u){var g=g3(n,i,s);g&&(t.point=g)}}return I3(n,[])}(n,y,S,l,h,o):(n.segments[0]||(C=new wi(n,"segments",{type:"Orthogonal"},!0),n.segments.push(C)),n.segments[0].points=c=b3(n,y,S,void 0,s));return c}(n,y.direction,S.direction,y.point,S.point,r);if(Uv(n),(n.sourceWrapper||n.targetWrapper)&&function Dre(n,t,e){var i=n.sourcePortWrapper,r=n.targetPortWrapper,s=n.sourceWrapper,o=t.point,a={left:0,right:0,top:0,bottom:0},l={x:0,y:0},c="Top";if(s?(o=e.point,a=t.margin):(s=n.targetWrapper,a=e.margin),"Orthogonal"===n.type)if(n.segments&&n.segments.length>0&&n.sourceWrapper&&n.segments[0].direction)t.direction=n.segments[0].direction,l=qa(n,0,l=Ol(s.corners,t.direction),Ol(s.corners,_n(t.direction)),!1);else{var u={corners:null,direction:null,point:null,margin:null};jv(s,{corners:null,direction:null,point:o,margin:a},u,n),l=u.point,c=u.direction}else{var f=void 0;n.segments&&n.segments.length>1&&(f=s===n.sourceWrapper?n.segments[0].point:n.segments[n.segments.length-2].point),l=qa(n,0,s.bounds.center,n.segments&&n.segments.length>1?f:o,s===n.targetWrapper)}s===n.sourceWrapper?(t.direction=t.direction||c,t.point=l,n.sourcePortWrapper&&(t.point={x:i.offsetX,y:i.offsetY},n.sourcePadding&&(t.point=TI(n,t,e,!1)))):(e.direction=e.direction||c,e.point=l,n.targetPortWrapper&&(e.point={x:r.offsetX,y:r.offsetY},n.targetPadding&&(e.point=TI(n,t,e,!0))))}(n,y,S),"Straight"===n.type||"Bezier"===n.type)d=Nx(n,y,S);else if("Orthogonal"===n.type&&n.segments&&n.segments.length>0&&null!==n.segments[0].length&&null!==n.segments[0].direction)d=function Ere(n,t,e,i,r,s,o){var a,l,c,u,h=[];if(Uv(n),n.segments.length>0){for(var f=0;f0&&n.segments[f-1].direction===p.direction)f=y3(n,f,t);else{var g=n.segments[f-1];t.point=p.direction?u3(t,p):g.points[g.points.length-1]}if(f===n.segments.length-1&&(o||r?n.targetWrapper&&void 0===n.targetPortWrapper?(S3(n,t),l=wre(n,t,e)):l=p3(n,t,e):l=Mre(n,t,e),l))if(v3(l,n),p.points=[],l.length>=2)for(a=0;at.corners.top&&e.point.ye.point.x?"Left":"Right"):e.point.x>t.corners.left&&e.point.xe.point.y?"Top":"Bottom")),n.sourcePortWrapper&&s===_n(r)?(("Left"===s||"Right"===s)&&t.point.y>=t.corners.top&&t.point.y<=t.corners.center.y&&e.point.y>=t.corners.top&&e.point.y<=t.corners.center.y?(t.direction="Top",a=t.point.y-t.corners.top+20):("Left"===s||"Right"===s)&&t.point.y>t.corners.center.y&&t.point.y<=t.corners.bottom&&e.point.y>t.corners.center.y&&e.point.y<=t.corners.bottom?(t.direction="Bottom",a=t.corners.bottom-t.point.y+20):("Top"===s||"Bottom"===s)&&t.point.x>=t.corners.left&&t.point.x<=t.corners.center.x&&e.point.x>=t.corners.left&&e.point.x<=t.corners.center.x?(t.direction="Left",a=t.point.x-t.corners.left+20):("Top"===s||"Bottom"===s)&&t.point.x<=t.corners.right&&t.point.x>t.corners.center.x&&e.point.x<=t.corners.right&&e.point.xt.point.y&&t.point.y>=e.corners.top?(i="Top",r=t.point.y-e.corners.top+20):e.corners.center.y===t.point.y&&"Top"===n.segments[n.segments.length-2].direction||e.corners.center.ye.point.y?t.point.y-t.corners.top+20:t.corners.bottom-t.point.y+20):(i="Top",r=e.corners.height/2+20):e.corners.center.x!==t.point.x||e.corners.topt.point.x&&t.point.x>=e.corners.left?(i="Left",r=t.point.x-e.corners.left+20):e.corners.center.x===t.point.x&&"Left"===n.segments[n.segments.length-2].direction||e.corners.center.x<=t.point.x&&t.point.x<=e.corners.right?(i="Right",r=e.corners.right-t.point.x+20):void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&t.corners.left<=t.point.x&&t.point.x<=t.corners.right&&(i=t.direction,r=t.point.x>e.point.x?t.point.x-t.corners.left+20:t.corners.right-t.point.x+20):(i="Left",r=e.corners.width/2+20);var a=t.point;t.point=Fn(t.point,"Left"===i||"Top"===i?-r:r,"Left"===i||"Right"===i?0:90),t.direction=R.direction(t.point,e.point),void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&(t.corners.center.x===e.corners.center.x||t.corners.center.y===e.corners.center.y)&&(t.direction=e.direction);var l=Ys(n,t,e);return l.splice(0,0,a),l}function p3(n,t,e){var i,r;e.corners=n.targetWrapper.corners,void 0!==n.sourcePortWrapper&&(r=zo({x:n.sourcePortWrapper.offsetX,y:n.sourcePortWrapper.offsetY},xn(n.sourceWrapper),n.sourceWrapper.bounds));var a=function Cre(n,t,e,i){var r=!1;switch(e.direction){case"Left":void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&"Right"===i&&t.point.x>e.point.x&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom||("Bottom"===i&&t.point.y>e.point.y||"Top"===i&&t.point.y=t.corners.left&&t.point.x<=t.corners.right?(t.direction="Right"===i?t.point.y>e.point.y?"Top":"Bottom":t.point.xe.point.x&&(t.point.y>e.point.y||t.point.yt.point.y&&e.corners.bottome.point.y||t.point.x>e.point.x&&t.point.y<=e.point.y&&e.corners.top=t.point.y?t.direction="Top":t.point.xe.point.x&&t.point.y>e.point.y&&e.corners.bottomt.point.y?t.direction="Bottom":t.point.y===e.point.y&&t.point.xe.point.y||"Top"===i&&t.point.ye.point.x&&t.point.x>=t.corners.left&&t.point.x<=t.corners.right?(t.direction=t.point.x>e.point.x?"Left":"Right",r=!0):void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&"Left"===i&&t.point.x=t.corners.top&&t.point.y<=t.corners.bottom?(t.direction=t.point.y>e.point.y?"Top":"Bottom",r=!0):t.point.x=t.point.y&&t.point.y===e.point.y||t.point.y>e.point.y&&t.point.x>e.point.x?t.direction="Top":t.point.ye.point.x?t.direction="Bottom":t.point.xe.point.y||t.point.ye.point.x&&(t.direction="Left");break;case"Top":void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&"Bottom"===i&&t.point.y>e.point.y&&t.point.x>=t.corners.left&&t.point.x<=t.corners.right||("Right"===i&&t.point.x>e.point.x||"Left"===i&&e.point.y>t.point.y&&e.point.x>t.point.x)&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom?(t.direction="Bottom"===i?t.point.x>e.point.x?"Left":"Right":t.point.ye.point.y&&t.point.x>e.corners.left&&t.point.x=e.point.y?t.direction="Top":t.point.ye.point.x?t.direction="Left":t.point.yt.point.x)&&t.point.y>e.point.y&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom||"Top"===i&&t.point.y=t.corners.left&&t.point.x<=t.corners.right)?(t.direction="Right"===i||"Left"===i?t.point.y>e.point.y?"Top":"Bottom":t.point.x>e.point.x?"Left":"Right",r=!0):t.point.ye.corners.left&&e.corners.right>t.point.x?t.point.ye.corners.left&&e.corners.center.x>=t.point.x?t.direction="Left":t.point.ye.point.y&&t.point.x>e.point.x?t.direction="Left":t.point.y>e.point.y&&t.point.xe.point.x||e.point.x>t.point.x)&&(t.direction="Bottom")}return r}(n,t,e,r);return!n.selectedSegmentIndex&&void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&e.direction===_n(r)&&(("Left"===e.direction&&t.point.x>e.point.x||"Right"===e.direction&&t.point.x=t.corners.top&&t.point.y<=t.corners.bottom||"Bottom"===e.direction&&t.point.y=t.corners.left&&t.point.x<=t.corners.right)?i=f3(n,t,e):n.selectedSegmentIndex||t.direction!==e.direction?!n.selectedSegmentIndex&&("Left"===e.direction&&t.point.x>e.point.x||"Right"===e.direction&&t.point.x=t.point.y||"Top"===e.direction&&t.point.y>e.point.y||"Bottom"===e.direction&&t.point.y=t.point.x?i=n.selectedSegmentIndex?kl(t,e):f3(n,t,e):!n.selectedSegmentIndex&&void 0!==n.sourceWrapper&&void 0!==n.targetWrapper&&void 0!==n.targetPortWrapper&&("Left"===t.direction||"Right"===t.direction)&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom&&("Top"===e.direction||"Bottom"===e.direction)&&e.corners.center.x===t.corners.center.x?(t.direction="Top"===e.direction?"Bottom":"Top",i=Ys(n,t,e,"Top"===e.direction?t.corners.bottom-t.point.y+20:t.point.y-t.corners.top+20)):!n.selectedSegmentIndex&&void 0!==n.sourceWrapper&&void 0!==n.targetWrapper&&void 0!==n.targetPortWrapper&&("Top"===t.direction||"Bottom"===t.direction)&&t.point.x>=t.corners.left&&t.point.x<=t.corners.right&&("Left"===e.direction||"Right"===e.direction)&&e.corners.center.y===t.corners.center.y?(t.direction="Left"===e.direction?"Right":"Left",i=Ys(n,t,e,"Left"===e.direction?t.corners.right-t.point.x+20:t.point.x-t.corners.left+20)):i=a?Ys(n,t,e,"Left"===t.direction||"Right"===t.direction?"Left"===t.direction?t.point.x-t.corners.left+20:t.corners.right-t.point.x+20:"Top"===t.direction?t.point.y-t.corners.top+20:t.corners.bottom-t.point.y+20):kl(t,e):i=Ys(n,t,e),i}function g3(n,t,e){var r,i={x:t.offsetX,y:t.offsetY},s=xn(e),o=zo(i,s,e.bounds),a=n.segments[0];return a.direction!==o&&(function Ore(n,t,e,i,r,s){var a,h,o=13,l=[];l.push(i),i.y===r.y&&("Left"===t&&r.xi.x)||i.x===r.x&&("Top"===t&&r.yi.y)||("Top"===t||"Bottom"===t?"Top"===t&&r.yi.y-o||"Bottom"===t&&r.y>i.y&&r.yo&&("Top"===t&&r.yi.y)?l.push({x:i.x,y:r.y}):(a=r.xi.x-o||"right"===t&&r.x>i.x&&r.xo&&("Left"===t&&r.xi.x)?l.push({x:r.x,y:i.y}):(l.push({x:a="Left"===t?e.left-o:e.right+o,y:i.y}),l.push({x:a,y:r.y})),s&&(l.push(n.points[0]),l.reverse()),n.points=l)}(a,o,s,a.points[0],a.points[a.points.length-1],!1),r=a.points[a.points.length-1],a.direction=R.direction(a.points[a.points.length-2],a.points[a.points.length-1])),r}function v3(n,t,e){var s,i=t.segments[t.segments.length-2],r=i.points[i.points.length-1];(("Top"===i.direction||"Bottom"===i.direction)&&r.x===n[1].x||("Left"===i.direction||"Right"===i.direction)&&r.y===n[1].y)&&(i.points[i.points.length-1]=n[1],s=R.direction(i.points[0],i.points[i.points.length-1]),void 0!==t.sourceWrapper&&void 0===t.sourcePortWrapper&&s===_n(i.direction)&&("Left"===i.direction||"Right"===i.direction?i.points[0].x="Right"===i.direction?i.points[0].x-t.sourceWrapper.corners.width:i.points[0].x+t.sourceWrapper.corners.width:i.points[0].y="Bottom"===i.direction?i.points[0].y-t.sourceWrapper.corners.height:i.points[0].y+t.sourceWrapper.corners.height),i.direction=s,i.length=R.distancePoints(i.points[0],i.points[i.points.length-1]),n.splice(0,1))}function TI(n,t,e,i){var o=i?n.targetPadding:n.sourcePadding,a=i?n.targetPortWrapper:n.sourcePortWrapper,l=new Ne(a.bounds.x-o,a.bounds.y-o,a.actualSize.width+2*o,a.actualSize.height+2*o),h=[l.topLeft,l.topRight,l.bottomRight,l.bottomLeft];h[h.length]=h[0];var d=i?e.point:t.point;return kx({x1:t.point.x,y1:t.point.y,x2:e.point.x,y2:e.point.y},h,0,d)||d}function m3(n,t){var e=[],i=mF(0,n.corners,t);i.push(i[0]);for(var r=0;r0){var r=void 0,s=[],o=t.point;for(r=0;r1&&R.equals(a.points[0],a.points[1])&&n.segments.splice(r,1),a)for(var l=0;l0||0===r)&&i.push(a.points[parseInt(l.toString(),10)])}}return i}function Ox(n,t,e){return"Top"===n||"Bottom"===n?e.x>t.x?"Right":"Left":e.y>t.y?"Bottom":"Top"}function Uv(n){if("Straight"===n.type||"Bezier"===n.type){if(0===n.segments.length||n.segments.length>0&&!R.isEmptyPoint(n.segments[n.segments.length-1].point))if("Bezier"===n.type){var t=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0},!0);n.segments.push(t)}else t=new Bl(n,"segments",{type:"Straight"},!0),n.segments.push(t)}else{if(n.segments.length>0)for(var e=!1,i=0;i=t.corners.left&&e.point.x<=t.corners.right&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom)t.direction=e.point.y>t.point.y?"Bottom":"Top",i=Ys(n,t,e,"Top"===t.direction?t.point.y-t.corners.top+20:t.corners.bottom-t.point.y+20);else if(n.sourcePortWrapper&&r===_n(o)){var h;("Left"===r||"Right"===r)&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom?(t.direction=e.point.y>t.point.y?"Bottom":"Top",h=t.corners.height/2+20):("Top"===r||"Bottom"===r)&&t.point.x>=t.corners.left&&t.point.x<=t.corners.right&&(t.direction=e.point.x>t.point.x?"Right":"Left",h=t.corners.width/2+20),t.direction&&h?i=Ys(n,t,e,h,!0):(t.direction=o,i=kl(t,e))}else if(!n.sourcePortWrapper||r!==e.direction||"Top"!==r&&"Bottom"!==r||t.corners.center.x!==e.corners.center.x)if(t.direction===e.direction)if(("Left"===t.direction||"Right"===t.direction)&&e.point.y>t.corners.top-20&&e.point.yt.corners.left-20&&e.point.xt.point.y?"Bottom":"Top",i=Ys(n,t,e,"Bottom"===t.direction?t.corners.bottom-t.point.y+20:t.point.y-t.corners.top+20);else t.direction=o,i=Ys(n,t,e,"Top"===o||"Bottom"===o?n.sourceWrapper.height/2+20:n.sourceWrapper.width/2+20),t.point=i[1],"Left"===o||"Right"===o?(e.direction=o,e.point="Left"===o?e.corners.middleLeft:e.corners.middleRight):jv(n.targetWrapper,t,e,n),i=Ys(n,t,e);return i}function S3(n,t){if(void 0!==n.targetWrapper&&void 0===n.targetPortWrapper&&xn(n.targetWrapper).containsPoint(t.point,1)){var i=n.targetWrapper,r=n.segments[n.segments.length-2],s=r.points[r.points.length-1],o=_n(r.direction);"Bottom"===o?s.yi.corners.top-1&&(r.points[r.points.length-1].y=i.corners.top-20,r.length=R.distancePoints(r.points[0],r.points[r.points.length-1])):"Left"===o?s.x>i.corners.left-1&&(r.points[r.points.length-1].x=i.corners.left-20,r.length=R.distancePoints(r.points[0],r.points[r.points.length-1])):"Right"===o&&s.x0||0===e)&&t.push(i.points[parseInt(r.toString(),10)]);return t}function jv(n,t,e,i){var r,s={x:0,y:0},o=AI(n,n.corners,n.bounds),a=t.margin,l=t.point;if(o.bottomCenter.y+a.bottoml.y)r="Top",s=o.topCenter;else if(o.middleLeft.x-a.left>l.x)r="Left",s=o.middleLeft;else if(o.middleRight.x+a.rightc&&(f=c,r="Right",s=o.middleRight),f>d&&(f=d,r="Bottom",s=o.bottomCenter),f>u&&(r="Left",s=o.middleLeft)}e.point=s,e.direction=r;var p=Ol(o,_n(e.direction));e.point=qa(i,0,e.point,p,n===i.targetWrapper)}function b3(n,t,e,i,r){var s,o,a;if(s=function Qre(n,t){var e=!1;switch(n){case"Left":switch(t){case"Right":case"Bottom":e=!0}break;case"Top":switch(t){case"Left":case"Right":case"Bottom":e=!0}break;case"Bottom":"Right"===t&&(e=!0)}return e}(t.direction,e.direction),s&&x3(t,e),"Right"===t.direction&&"Left"===e.direction)a=function kre(n,t,e,i){var o=Math.round(Math.abs(t.point.y-e.point.y)),a={x:Math.max(t.point.x,t.corners.right),y:t.point.y},l={x:Math.min(e.point.x,e.corners.left),y:e.point.y},h=Xa(n);if(i){var c=l;l=a,a=c}return t.corners.bottom+he.corners.bottom+h||("Bezier"!==n.type||e.corners.left-t.corners.right<=2*h&&e.corners.left-t.corners.right>=5)&&(h=0),t.margin={left:h,right:h,top:h,bottom:h},e.margin={left:h,right:h,top:h,bottom:h},0===o&&(t.corners.right=e.corners.right?void 0!==i&&(i.offsetYe.corners.bottom+e.margin.bottom)||void 0===i&&t.corners.middleRight.ye.corners.bottom+e.margin.bottom&&t.corners.top>e.corners.bottom||void 0===i&&t.corners.middleRight.y>e.corners.bottom||void 0!==i&&i.offsetYe.corners.top||void 0===i&&t.corners.middleRight.y>e.corners.bottom?Ae.Three:t.corners.rightr.offsetY+e.margin.right||void 0===r&&t.corners.top>e.corners.middleRight.y||void 0!==r&&(void 0!==i&&i.offsetXr.offsetX||void 0===r&&t.corners.left>e.corners.topCenter.x?Ae.Four:Ae.Two:void 0!==s&&Math.abs(t.corners.right-e.corners.left)<=5&&Math.abs(s.offsetY-e.corners.top)<=5||void 0!==r&&t.corners.right=25&&t.corners.middleRight.y+t.margin.righte.corners.bottom+e.margin.bottom||void 0===o&&t.corners.middleRight.y>e.corners.bottom+e.margin.bottom?t.corners.top>e.corners.bottom?void 0!==a&&t.corners.right+t.margin.righta.offsetX||void 0===a&&t.corners.left>e.corners.bottomCenter.x?Ae.Four:Ae.Two:void 0!==o&&Math.abs(t.corners.right-e.corners.left)<=25&&Math.abs(o.offsetY-e.corners.bottom)<=25?Ae.Two:Ae.Four}(n,t,e,s);else if("Bottom"===t.direction&&"Top"===e.direction)a=function Hre(n,t,e){var r=t.point.x-e.point.x,s=Xa(n);return t.corners.right+se.corners.right+s||("Bezier"!==n.type||e.corners.top-t.corners.bottom<=2*s&&e.corners.top-t.corners.bottom>=5)&&(s=0),t.margin={left:s,right:s,top:s,bottom:s},e.margin={left:s,right:s,top:s,bottom:s},0===r&&t.corners.bottome.corners.right+e.margin.right||void 0===i&&t.corners.bottomCenter.x>e.corners.right+e.margin.right?Ae.Three:t.corners.bottomr.offsetX||void 0===r&&t.corners.left>e.corners.left||void 0!==r&&t.corners.right+t.margin.righte.corners.bottom?Ae.Five:0===s||0===o?Ae.One:Ae.Three}(n,t,e)}else"Bottom"===t.direction&&"Left"===e.direction?a=function Bre(n,t,e,i){var r=n.sourcePortWrapper,s=n.targetPortWrapper,o=Xa(n);if(e.margin={left:o,right:o,top:o,bottom:o},t.margin={top:o,bottom:o,left:o,right:o},i){var l=r;r=s,s=l}return void 0!==r&&r.offsetXs.offsetY||void 0===s&&t.corners.top>e.corners.middleLeft.y?Ae.Four:Ae.Two:void 0!==s&&Math.abs(t.corners.right-e.corners.left)<=25&&Math.abs(s.offsetY-t.corners.bottom)<=25?Ae.Two:Ae.Four}(n,t,e,s):"Left"===t.direction&&"Left"===e.direction?a=function Ure(n,t,e){var i=n.sourcePortWrapper,r=n.targetPortWrapper,s=Xa(n);t.margin={left:s,right:s,top:s,bottom:s},e.margin={left:s,right:s,top:s,bottom:s};var o=Math.round(Math.abs(t.point.x-e.point.x)),a=Math.round(Math.abs(t.point.y-e.point.y));return t.corners.leftr.offsetY||void 0===r&&t.corners.top-t.margin.top>e.corners.middleLeft.y?Ae.Three:t.corners.righte.corners.bottom+e.margin.bottom||void 0===i&&t.corners.middleLeft.y>e.corners.bottom+e.margin.bottom?Ae.Three:t.corners.left>e.corners.right?Ae.Five:0===o||0===a?Ae.One:Ae.Three}(n,t,e):"Left"===t.direction&&"Top"===e.direction?a=function _re(n,t,e,i){var s=n.sourcePortWrapper,o=Xa(n);e.margin={left:o,right:o,top:o,bottom:o},t.margin={top:o,bottom:o,left:o,right:o};var a=n.targetPortWrapper,l={x:Math.min(t.point.x,t.corners.left),y:t.point.y},h={x:e.point.x,y:Math.min(e.point.y,e.corners.top)};if(i){var c=s;s=a,a=c;var d=l;l=h,h=d}return void 0!==s&&s.offsetYa.offsetX||void 0===a&&t.corners.left-t.margin.left>e.corners.topCenter.x?Ae.Two:Ae.Four:void 0!==a&&t.corners.rightr.offsetX||void 0===r&&t.corners.left>e.corners.left||void 0!==r&&t.corners.right+t.margin.righte.corners.right+e.margin.right||void 0===i&&t.corners.left>e.corners.right||void 0!==i&&i.offsetXe.corners.bottom?Ae.Five:0===s||0===o?Ae.One:Ae.Three}(n,t,e));return s&&x3(t,e),o=function Vre(n,t,e,i,r,s){var l,d,h=n.sourceWrapper.corners,c=n.targetWrapper.corners,u=20,f={corners:e.corners,point:e.point,direction:e.direction,margin:e.margin},p={corners:i.corners,point:i.point,direction:i.direction,margin:i.margin};if(!(f.direction===p.direction&&t!==Ae.Five||f.direction!==_n(p.direction)&&t!==Ae.Three))switch(f.direction){case"Left":h.middleLeft.x>c.middleRight.x&&(d=(h.middleLeft.x-c.middleRight.x)/2,u=s?d:Math.min(u,d));break;case"Right":h.middleRight.xc.bottomCenter.y&&(d=(h.topCenter.y-c.bottomCenter.y)/2,u=s?d:Math.min(u,d));break;case"Bottom":h.bottomCenter.yf&&hf)&&o>c&&o<=d&&e>=20&&(s=n.point.x-t.corners.left+s),i&&n.direction===t.direction&&n.corners.left>t.corners.left&&n.corners.left-t.corners.right>=20&&(s=(n.corners.left-t.corners.right)/2),p=Fn(n.point,s,180);break;case"Top":(o>c&&oc)&&h>f&&h<=u&&e>=20&&(s=n.point.y-t.corners.top+s),i&&n.direction===t.direction&&n.corners.top>t.corners.top&&n.corners.top-t.corners.bottom>=20&&(s=(n.corners.top-t.corners.bottom)/2),p=Fn(n.point,s,270);break;case"Right":(h>f&&hf)&&a=c&&e>=20&&(s=t.corners.right-n.point.x+s),i&&n.direction===t.direction&&n.corners.right=20&&(s=(t.corners.left-n.corners.right)/2),p=Fn(n.point,s,0);break;case"Bottom":(o>c&&oc)&&l=f&&e>=20&&(s=t.corners.bottom-n.point.y+s),i&&n.direction===t.direction&&n.corners.bottom=20&&(s=(t.corners.top-n.corners.bottom)/2),p=Fn(n.point,s,90)}r=[n.point,p];var g=void 0;if("Top"===n.direction||"Bottom"===n.direction){var v=n.direction;n.direction=p.x>t.point.x?"Left":"Right",n.point=p,r=LI(n,t,v,r,g=i?.5*Math.abs(p.x-t.point.x):g,i)}else v=n.direction,n.direction=p.y>t.point.y?"Top":"Bottom",n.point=p,r=LI(n,t,v,r,g=i?.5*Math.abs(p.y-t.point.y):g,i);return r}(f,p,u,g)),l}(n,a,t,e,i,r),"Bezier"===n.type&&function Yre(n,t,e){if("Bezier"===n.type)if(0===n.segments.length){var i=e[0],r=e[e.length-1];if(t===Ae.One){var s=Math.min(20,.5*R.findLength(i,r)),o={angle:Gt(i,r),distance:s},a={angle:Gt(r,i),distance:s},l=R.direction(i,r),c=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,orientation:"Left"===l||"Right"===l?"Horizontal":"Vertical"},!0);n.segments.push(c)}else if(t===Ae.Two)o={angle:Gt(i,d=e[1]),distance:.5*R.findLength(i,d)},a={angle:Gt(r,d),distance:.5*R.findLength(r,d)},l=R.direction(i,d),c=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,orientation:"Left"===l||"Right"===l?"Horizontal":"Vertical"},!0),n.segments.push(c);else if(t===Ae.Three){var d={x:.5*((u=e[1]).x+(f=e[e.length-2]).x),y:.5*(u.y+f.y)},p=(o={angle:Gt(i,u),distance:.5*R.findLength(i,u)},a={angle:Gt(d,u),distance:.5*R.findLength(d,u)},R.direction(i,u)),v=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,point:d,orientation:"Left"===p||"Right"===p?"Horizontal":"Vertical"},!0);n.segments.push(v);var y={angle:Gt(d,f),distance:.5*R.findLength(d,f)},S={angle:Gt(r,f),distance:.5*R.findLength(r,f)},b=R.direction(d,f),w=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:y,vector2:S,orientation:"Left"===b||"Right"===b?"Horizontal":"Vertical"},!0);n.segments.push(w)}else if(t===Ae.Four){var D={x:.5*((u=e[1]).x+(f=e[2]).x),y:.5*(u.y+f.y)},A={x:.5*(f.x+(C=e[3]).x),y:.5*(f.y+C.y)};o={angle:Gt(i,u),distance:.5*R.findLength(i,u)},a={angle:Gt(D,u),distance:.5*R.findLength(D,u)},p=R.direction(i,u),v=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,point:D,orientation:"Left"===p||"Right"===p?"Horizontal":"Vertical"},!0),n.segments.push(v),y={angle:Gt(D,f),distance:.5*R.findLength(D,f)},S={angle:Gt(A,f),distance:.5*R.findLength(A,f)},b=R.direction(D,f),w=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:y,vector2:S,point:A,orientation:"Left"===b||"Right"===b?"Horizontal":"Vertical"},!0),n.segments.push(w);var x={angle:Gt(A,C),distance:.5*R.findLength(A,C)},P={angle:Gt(r,C),distance:.5*R.findLength(r,C)},L=R.direction(A,C),N=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:x,vector2:P,orientation:"Left"===L||"Right"===L?"Horizontal":"Vertical"},!0);n.segments.push(N)}else if(t===Ae.Five){var u,f,C,T=e[4],z=(D={x:.5*((u=e[1]).x+(f=e[2]).x),y:.5*(u.y+f.y)},A={x:.5*(f.x+(C=e[3]).x),y:.5*(f.y+C.y)},{x:.5*(C.x+T.x),y:.5*(C.y+T.y)});o={angle:Gt(i,u),distance:.5*R.findLength(i,u)},a={angle:Gt(D,u),distance:.5*R.findLength(D,u)},p=R.direction(i,u),v=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,point:D,orientation:"Left"===p||"Right"===p?"Horizontal":"Vertical"},!0),n.segments.push(v),y={angle:Gt(D,f),distance:.5*R.findLength(D,f)},S={angle:Gt(A,f),distance:.5*R.findLength(A,f)},b=R.direction(D,f),w=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:y,vector2:S,point:A,orientation:"Left"===b||"Right"===b?"Horizontal":"Vertical"},!0),n.segments.push(w),x={angle:Gt(A,C),distance:.5*R.findLength(A,C)},P={angle:Gt(z,C),distance:.5*R.findLength(z,C)},L=R.direction(A,C),N=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:x,vector2:P,point:z,orientation:"Left"===L||"Right"===L?"Horizontal":"Vertical"},!0),n.segments.push(N);var U={angle:Gt(z,T),distance:.5*R.findLength(z,T)},B={angle:Gt(r,T),distance:.5*R.findLength(r,T)},j=R.direction(z,T),oe=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:U,vector2:B,orientation:"Left"===j||"Right"===j?"Horizontal":"Vertical"},!0);n.segments.push(oe)}else c=new fs(n,"segments",{type:"Bezier"},!0),n.segments.push(c)}else for(var ue=0;ue=13?13:n.connectorSpacing<=1?1:n.connectorSpacing}function Gt(n,t){var i=R.findLength({x:t.x,y:n.y},t),r=R.findLength(t,n),s=Math.asin(i/r);return s=180*s/Math.PI,n.xt.y&&(s=360-s):s=n.y0)for(var l=1;lc)&&(s=c,a=h),s>=0&&s<=1)break}}return a}function w3(n,t){var c,d,u,f,p,g,S,b,M,w,D,e=n.x1,i=n.y1,r=n.x2,s=n.y2,o=t.x1,a=t.y1,l=t.x2,h=t.y2;if(w=(c=s-i)*l+(u=e-r)*h+(p=r*i-e*s),0!==(M=c*o+u*a+p)&&0!==w&&C3(M,w)||(b=(d=h-a)*r+(f=o-l)*s+(g=l*a-o*h),0!==(S=d*e+f*i+g)&&0!==b&&C3(S,b)))return null;var A=c*f-d*u;return 0===A?null:(A<0?-A/2:A/2,0,{x:(D=u*g-f*p)<0?(D-0)/A:(D+0)/A,y:(D=d*p-c*g)<0?(D-0)/A:(D+0)/A})}function C3(n,t){return n*t>=0}function E3(n,t,e){switch(t.direction){case"Left":t.point.x>n.left&&(e=t.point.x-n.left>e?t.point.x-n.left+e:e);break;case"Right":t.point.xe?n.right-t.point.x+e:e);break;case"Top":t.point.y>n.top&&(e=t.point.y-n.top>e?t.point.y-n.top+e:e);break;case"Bottom":t.point.ye?n.bottom-t.point.y+e:e)}return e}function kl(n,t){var e;switch(n.direction){case"Left":case"Right":var i={x:t.point.x,y:n.point.y};e=R.equals(n.point,i)||R.equals(t.point,i)?[n.point,t.point]:[n.point,i,t.point];break;case"Top":case"Bottom":var r={x:n.point.x,y:t.point.y};e=R.equals(n.point,r)||R.equals(t.point,r)?[n.point,t.point]:[n.point,r,t.point]}return e}function Ys(n,t,e,i,r,s){void 0===s&&(s=!1),i||(i=20),s&&t.direction!==e.direction&&(i="Left"===t.direction||"Right"===t.direction?Math.floor(.5*Math.abs(t.point.x-e.point.x)):Math.floor(.5*Math.abs(t.point.y-e.point.y)));var l,h,u,o=n.sourcePortWrapper,c=e.point.x-t.point.x,d=e.point.y-t.point.y;if(!r&&(Math.abs(c)<.001||Math.abs(d)<.001)&&void 0===e.direction)return[t.point,e.point];if(void 0===n.targetWrapper&&Math.abs(c)<=31&&Math.abs(d)<=31){if("Left"===t.direction||"Right"===t.direction?Math.abs(d)<12&&(t.direction=t.point.y>e.point.y?"Top":"Bottom"):Math.abs(c)<12&&(t.direction=t.point.x>e.point.x?"Left":"Right"),Math.abs(c)>12||Math.abs(d)>12)return kl(t,e);i+=5}return"Left"===t.direction||"Right"===t.direction?("Right"===t.direction?(void 0!==e.direction&&"Right"===e.direction&&(i=Math.max(t.point.x,e.point.x)-t.point.x+i),t.point.x>e.point.x&&void 0===o&&(i=-i)):(void 0!==e.direction&&"Left"===e.direction&&(i=t.point.x-Math.min(t.point.x,e.point.x)+i),(t.point.x>e.point.x||void 0!==o||"Left"===t.direction)&&(i=-i)),u=e.point.y-t.point.y,l=Fn(t.point,i,0),0!=(u=e.point.y-l.y)&&(h=Fn(l,e.point.y-l.y,90))):("Top"===t.direction||"Bottom"===t.direction)&&("Bottom"===t.direction?void 0!==e.direction&&"Bottom"===e.direction&&(i=Math.max(t.point.y,e.point.y)-t.point.y+i):(void 0!==e.direction&&"Top"===e.direction&&(i=t.point.y-Math.min(t.point.y,e.point.y)+i),(t.point.y>e.point.y||void 0!==o||"Top"===t.direction)&&(i=-i)),u=e.point.x-t.point.x,l=Fn(t.point,i,90),0!=(u=e.point.x-l.x)&&(h=Fn(l,e.point.x-l.x,0))),0===u?[t.point,e.point]:[t.point,l,h,e.point]}function LI(n,t,e,i,r,s){var o;switch(void 0===r&&(r=20),void 0===s&&(s=!1),void 0===e?(n.margin={left:2,right:2,top:2,bottom:2},t.margin={left:0,right:5,top:0,bottom:5},s&&(n.margin={left:10,right:10,top:10,bottom:10},t.margin={left:10,right:10,top:10,bottom:10},"Left"===n.direction?(r=zx(n,t,e,r),n.corners.left-t.corners.right>=5&&(r=Math.abs(n.point.x-n.corners.left)+.5*Math.floor(n.corners.left-t.corners.right))):"Right"===n.direction?(r=Rx(n,t,r,e),t.corners.left-n.corners.right>=5&&(r=Math.abs(n.point.x-n.corners.right)+.5*Math.floor(t.corners.left-n.corners.right))):"Top"===n.direction?(r=Px(n,t,e,r),n.corners.top-t.corners.bottom>=5&&(r=Math.abs(n.point.y-n.corners.top)+.5*Math.floor(n.corners.top-t.corners.bottom))):"Bottom"===n.direction&&(r=Hx(n,t,r,e),t.corners.top-n.corners.bottom>=5&&(r=Math.abs(n.point.y-n.corners.bottom)+.5*Math.floor(t.corners.top-n.corners.bottom))))):("Bottom"===n.direction?s?t.corners.top-n.corners.bottom<20&&(r=t.corners.bottom-n.point.y+25):t.corners.top>n.corners.bottom&&t.corners.top-n.corners.bottom<20&&(r=(t.corners.top-n.corners.bottom)/2):"Top"===n.direction?s?n.corners.top-t.corners.bottom<20&&(r=n.point.y-t.corners.top+25):t.corners.bottomn.corners.right&&t.corners.left-n.corners.right<20&&(r=(t.corners.left-n.corners.right)/2):"Left"===n.direction&&(s?n.corners.left-t.corners.right<20&&(r=n.point.x-t.corners.left+25):t.corners.rightt.point.y||"Top"===t.direction&&n.point.yt.point.x||"Left"===t.direction&&n.point.xh||e.corners.top-e.margin.top<=i.point.y&&e.corners.bottom+e.margin.bottom>=i.point.y))if(!s||"Top"!==e.direction&&"Bottom"!==e.direction)c=Math.min(Math.abs(i.corners.left-e.corners.right)/2,20),h=e.corners.right-n.x+c;else{var c=Math.abs(i.corners.left-e.corners.right)/2;h=e.corners.right-n.x+c}else h="Top"===e.direction&&n.y>i.point.y||"Bottom"===e.direction&&n.y=e.corners.left-e.margin.left&&n.x<=e.corners.right+e.margin.right?Math.min(i.corners.left,e.corners.left)-n.x-20:i.corners.left-n.x-20;break;case"Right":if(e.corners.left-e.margin.left>i.corners.right+i.margin.right&&(e.corners.left-e.margin.right-i.corners.right>h||e.corners.top-e.margin.top<=i.point.y&&e.corners.bottom+e.margin.bottom>=i.point.y))if(!s||"Top"!==e.direction&&"Bottom"!==e.direction)c=Math.min(Math.abs(e.corners.left-i.corners.right)/2,20),h=e.corners.left-n.x-c;else{c=Math.abs(e.corners.left-i.corners.right)/2;h=e.corners.left-n.x-c}else h="Top"===e.direction&&n.y>i.point.y||"Bottom"===e.direction&&n.y=e.corners.left-e.margin.left&&n.x<=e.corners.right+e.margin.right?Math.max(i.corners.right,e.corners.right)-n.x+20:i.corners.right-n.x+20}o=Fn(n,h,0),a=Fn(o,i.point.y-n.y,90),l=i.point}else if("vertical"===t){switch(i.direction){case"Top":e.corners.bottom+e.margin.bottomh||e.corners.left-e.margin.left<=i.point.x&&e.corners.right+e.margin.right>=i.point.x)?!s||"Right"!==e.direction&&"Left"!==e.direction?(c=Math.min(Math.abs(i.corners.top-e.corners.bottom)/2,20),h=e.corners.bottom-n.y+c):(c=Math.abs(i.corners.top-e.corners.bottom)/2,h=e.corners.bottom-n.y+c):h="Left"===e.direction&&n.x>i.point.x||"Right"===e.direction&&n.x=e.corners.top-e.margin.top&&n.y<=e.corners.bottom+e.margin.bottom?Math.min(i.corners.top,e.corners.top)-n.y-20:i.corners.top-n.y-20;break;case"Bottom":e.corners.top-e.margin.top>i.corners.bottom+i.margin.bottom&&(e.corners.top-e.margin.top-i.corners.bottom>h||e.corners.left-e.margin.left<=i.point.x&&e.corners.right+e.margin.right>=i.point.x)?!s||"Right"!==e.direction&&"Left"!==e.direction?(c=Math.min(Math.abs(e.corners.top-i.corners.bottom)/2,20),h=e.corners.top-n.y-c):(c=Math.abs(e.corners.top-i.corners.bottom)/2,h=e.corners.top-n.y-c):h="Left"===e.direction&&n.x>i.point.x||"Right"===e.direction&&n.x=e.corners.top-e.margin.top&&n.y<=e.corners.bottom+e.margin.bottom?Math.max(i.corners.bottom,e.corners.bottom)-n.y+20:i.corners.bottom-n.y+20}o=Fn(n,h,90),a=Fn(o,i.point.x-n.x,0),l=i.point}r.push(o),r.push(a),r.push(l)}function Px(n,t,e,i){return n.corners.top-n.margin.top>t.corners.top+t.margin.top&&n.corners.top-n.margin.top<=t.corners.bottom+t.margin.bottom?(("Right"===t.direction&&n.point.xt.point.x)&&(i+=n.corners.top-t.corners.top),i+=n.point.y-n.corners.top):i+=void 0!==e&&"Left"!==e&&"Right"===t.direction&&n.point.xt.corners.left-t.margin.left&&n.corners.left-n.margin.left<=t.corners.right+t.margin.right?(("Bottom"===t.direction&&n.point.yt.point.y)&&(i+=n.corners.left-t.corners.left),i+=n.point.x-n.corners.left):i+=void 0!==e&&"Top"!==e&&"Bottom"===t.direction&&n.point.y=t.corners.left-t.margin.left?(("Bottom"===t.direction&&n.point.yt.point.y)&&(e+=t.corners.right-n.corners.right),e+=n.corners.right-n.point.x):e+=void 0!==i&&"Top"!==i&&"Bottom"===t.direction&&n.point.y=t.corners.top-t.margin.top?(("Right"===t.direction&&n.point.xt.point.x)&&(e+=t.corners.bottom-n.corners.bottom),e+=n.corners.bottom-n.point.y):e+=void 0!==i&&"Left"!==i&&"Right"===t.direction&&n.point.xp&&d=u&&d=f&&d<=p?"Left":"Right"}function _n(n){switch(n){case"Top":return"Bottom";case"Bottom":return"Top";case"Left":return"Right";case"Right":return"Left"}return"auto"}var A3=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Ac=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},NI=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return A3(t,n),Ac([I()],t.prototype,"width",void 0),Ac([I()],t.prototype,"height",void 0),t}(Ee),Gre=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return A3(t,n),Ac([I()],t.prototype,"width",void 0),Ac([I()],t.prototype,"height",void 0),Ac([I()],t.prototype,"fit",void 0),Ac([I()],t.prototype,"description",void 0),Ac([I()],t.prototype,"template",void 0),Ac([I()],t.prototype,"tooltip",void 0),t}(Ee),Xre=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Pl=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},L3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Xre(t,n),Pl([I("")],t.prototype,"id",void 0),Pl([I(Number.MIN_VALUE)],t.prototype,"zIndex",void 0),Pl([re({},Jn)],t.prototype,"margin",void 0),Pl([I(!0)],t.prototype,"visible",void 0),Pl([re({},Td)],t.prototype,"tooltip",void 0),Pl([I(!1)],t.prototype,"excludeFromLayout",void 0),Pl([I()],t.prototype,"addInfo",void 0),Pl([I("None")],t.prototype,"flip",void 0),Pl([I("All")],t.prototype,"flipMode",void 0),Pl([re({},Gre)],t.prototype,"symbolInfo",void 0),t}(Ee),qre=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),es=function(n){function t(e,i,r,s){var o=n.call(this)||this;return o.data="",o.nodeId="",o.annotationId="",o.diagramId="",o.diagramId=i,o.nodeId=e,o.annotationId=r,o.templateFn=GF(s),o}return qre(t,n),t.prototype.getNodeTemplate=function(){return this.templateFn},Object.defineProperty(t.prototype,"content",{get:function(){return this.data},set:function(e){this.data=e,this.canReset||(this.canReset=!0,this.isTemplate||(this.template=Fh(this,!0)),this.canReset=!1,this.isDirt=!0)},enumerable:!0,configurable:!0}),t}(hs),Bx=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),cs=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},N3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Bx(t,n),cs([I("")],t.prototype,"id",void 0),cs([I("transparent")],t.prototype,"fill",void 0),cs([I("black")],t.prototype,"iconStrokeColor",void 0),cs([I(0)],t.prototype,"iconStrokeWidth",void 0),cs([I(!0)],t.prototype,"visibility",void 0),cs([I(10)],t.prototype,"width",void 0),cs([I(10)],t.prototype,"height",void 0),cs([I("transparent")],t.prototype,"handleStrokeColor",void 0),cs([I(1)],t.prototype,"handleStrokeWidth",void 0),cs([I("")],t.prototype,"pathData",void 0),cs([I(0)],t.prototype,"cornerRadius",void 0),cs([re({left:0,right:0,top:0,bottom:0},Jn)],t.prototype,"padding",void 0),cs([re({},Td)],t.prototype,"tooltip",void 0),t}(Ee),O3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Bx(t,n),cs([re({x:0,y:0},R)],t.prototype,"offset",void 0),cs([re({},Jn)],t.prototype,"margin",void 0),t}(N3),OI=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Bx(t,n),cs([I(.5)],t.prototype,"offset",void 0),cs([I("Center")],t.prototype,"alignment",void 0),cs([re({x:0,y:0},R)],t.prototype,"displacement",void 0),t}(N3);function Ad(n){return n?n instanceof Kn||n instanceof Or?n.constraints&Nr.Select:n instanceof de?n.constraints&qe.Select:n.constraints&ie.Select:1}function ro(n){return n?n instanceof Kn||n instanceof Or?n.constraints&Nr.Drag:n instanceof de?n.constraints&qe.Drag:n instanceof ei?1:n.constraints&ie.Drag:1}function $re(n,t){return n instanceof de?n.constraints&qe.PointerEvents:n.constraints&ie.PointerEvents}function kI(n){return n instanceof de?n.constraints&qe.Delete:n.constraints&ie.Delete}function PI(n){return n.constraints&qe.DragSourceEnd}function zI(n){return n.constraints&qe.DragTargetEnd}function RI(n){return n.constraints&qe.DragSegmentThumb}function HI(n){return n instanceof Kn||n instanceof Or?n.constraints&Nr.Rotate:n.constraints&ie.Rotate}function BI(n){return n.constraints&ie.Shadow}function ua(n){return n instanceof te&&n.constraints&ie.InConnect?n.constraints&ie.InConnect:0}function zh(n){return n&&n.constraints&&!(n.constraints&oi.None)&&n.constraints&oi.InConnect?n.constraints&oi.InConnect:0}function Rh(n){return n instanceof te&&n.constraints&ie.OutConnect?n.constraints&ie.OutConnect:0}function Ld(n){return n&&n.constraints&&!(n.constraints&oi.None)&&n.constraints&oi.OutConnect?n.constraints&oi.OutConnect:0}function zl(n,t){var e=0;return n instanceof Kn||n instanceof Or?e=n.constraints&Nr.Resize:n&&("SouthEast"===t?e=n.constraints&ie.ResizeSouthEast:"East"===t?e=n.constraints&ie.ResizeEast:"NorthEast"===t?e=n.constraints&ie.ResizeNorthEast:"South"===t?e=n.constraints&ie.ResizeSouth:"North"===t?e=n.constraints&ie.ResizeNorth:"SouthWest"===t?e=n.constraints&ie.ResizeSouthWest:"West"===t?e=n.constraints&ie.ResizeWest:"NorthWest"===t&&(e=n.constraints&ie.ResizeNorthWest)),e}function FI(n){return n instanceof de?n.constraints&qe.AllowDrop:n.constraints&ie.AllowDrop}function Ds(n){return n.constraints&nt.Virtualization}function Vv(n){return n.tool&ri.SingleSelect}function Wv(n){return n.tool&ri.MultipleSelect}function Lc(n){return n.tool&ri.ZoomPan}function _I(n){return n.tool&ri.ContinuousDraw}function k3(n){return n.tool&ri.DrawOnce}function UI(n){return n.tool&ri.SingleSelect||n.tool&ri.MultipleSelect}function Yv(n){return n.constraints&nt.UserInteraction}function P3(n){return n.constraints&nt.ZoomTextEdit}function Qv(n){return function ine(n){return n.constraints&nt.ApiUpdate}(n)||n.diagramActions&ee.ToolAction}function Fx(n,t){return n.constraints&oi.Draw}function _x(n,t){return n.constraints&oi.Drag}function jI(n){return!(n&Ga.DrawSelectorBorder)}function z3(n){return!!(n&Ga.PreventRenderSelector)}var Ux=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Gv=function(n){function t(){var e=null!==n&&n.apply(this,arguments)||this;return e.childTable=[],e.cellStyle={},e.desiredRowHeight=[],e.desiredCellWidth=[],e}return Ux(t,n),t.prototype.rowDefinitions=function(){return this.rowDefns},t.prototype.columnDefinitions=function(){return this.colDefns},t.prototype.addObject=function(e,i,r,s,o){if(this.rows.length>=i){var a=this.rows[parseInt(i.toString(),10)];if(a.cells.length>r){o=o||1,s=s||1;var l=a.cells[parseInt(r.toString(),10)];l.columnSpan=Math.max(o,l.columnSpan),l.rowSpan=Math.max(s,l.rowSpan);var h=new ane;(h=e).rowId=i,h.columnId=r,h.columnSpan=o,this.childTable[h.id]=h,this.addObjectToCell(h,l)}}},t.prototype.addObjectToCell=function(e,i){i.children||(i.children=[]),e.style.strokeColor="black",e.style.strokeWidth=1,i.children.push(e)},t.prototype.updateProperties=function(e,i,r,s){this.offsetX=e,this.offsetY=i,this.width=r,this.height=s},t.prototype.setDefinitions=function(e,i){this.rowDefns=e,this.colDefns=i,this.children=[],this.rows=this.rows||[];for(var r=0;r0){for(var h=0;hi&&this.updateRowHeight(e,l,!1)}},t.prototype.setTextRefresh=function(e){if(e.children&&e.children.length)for(var i=e.children,r=0;ri&&this.updateColumnWidth(e,a,!1)}},t.prototype.calculateCellWidth=function(e){for(var i,r,s,o=0;os.bounds.width&&(0===s.children.length||void 0===s.children[0].maxWidth)?s.outerBounds.width:s.bounds.width,i=i?is.bounds.height?s.outerBounds.height:s.bounds.height,i=i?i0?e.children[0]:void 0;if(a&&1===e.columnSpan){o="Width"===i?a.bounds.right:a.bounds.bottom,s||(s="Width"===i?a.bounds.width:a.bounds.height);for(var l=0;lo){var d=c-o+("Width"===i?a.bounds.width:a.bounds.height);s&&(s=s0?this.rowDefns.splice(e,0,i):this.rowDefns.push(i);var s=new R3;s.cells=[],(new Nd).width=this.width,this.addCellInRow(this.colDefns,i,s),e>this.rows.length-1?this.rows.push(s):this.rows.splice(e,0,s),r&&(this.measure(new me(this.width,this.height)),this.arrange(this.desiredSize))},t.prototype.addColumn=function(e,i,r){var s,o,a,l,h=this.rows;this.colDefns.length>0?this.colDefns.splice(e,0,i):this.colDefns.push(i),void 0!==this.width&&(this.width+=i.width);for(var c=0;cs.cells.length-1?s.cells.push(l):s.cells.splice(e,0,l),this.children.push(l);r&&(this.measure(new me(this.width,this.height)),this.arrange(this.desiredSize))},t.prototype.removeRow=function(e){var i,r,o=this.rows[parseInt(e.toString(),10)];this.height-=this.rowDefns[parseInt(e.toString(),10)].height;for(var a=0;a0){var r=0,s=0;i=new me(0,0),this.calculateSize();for(var o=0,a=this.rows;o0){for(var o=this.offsetX-e.width*this.pivot.x,a=this.offsetY-e.height*this.pivot.y,l=o,h=0,c=this.rows;h1&&this.children.splice(this.children.indexOf(p)+1,p.columnSpan-1),p.rowSpan>1)for(y=s,S=0;y+p.rowSpan-10){for(var c=0;c0?1:0,v=0;v0||a.outEdges.length>0))for(f=a.inEdges.concat(a.outEdges),s=0;s0)for(o=0;o1)for(a=1;a0))if(h=n.wrapper.children[0],"Horizontal"===e.orientation)for(o=e.header&&e.hasHeader?h.rows[1]:h.rows[0],r=0;r0){var e=void 0;t.lineRoutingModule&&t.constraints&nt.LineRouting&&t.lineRoutingModule.renderVirtualRegion(t,!0);for(var i=0;i0?o+1:o)].height=t.wrapper.height;else if(t.isPhase)for(l[t.rowIndex-o].offset=t.wrapper.height,p=0;p0?1:0)].width=t.wrapper.width}function WI(n,t){var i=n.shape,r=i.header&&i.hasHeader?1:0;return"Horizontal"===i.orientation?t.rowIndex-(r+=i.phases.length>0?1:0):t.columnIndex-(i.phaseSize&&i.phases.length>0?1:0)}function YI(n){var t=0,e=n.shape;return"Horizontal"===e.orientation&&(t=e.header&&e.hasHeader?1:0),e.phases.length>0&&e.phaseSize&&(t+=1),t}function QI(n,t,e,i){var r=n.shape;if(r.phases.length>0){var s=t.nameTable[r.phases[parseInt(i.toString(),10)].header.id];s&&s.maxWidth0?u+1:u);var w=Nc(n,o),C=void 0!==i?i:l.lanes.length;if(u+=C,r={element:M,cause:n.diagramActions,diagramAction:n.getDiagramAction(n.diagramActions),state:"Changing",type:"Addition",cancel:!1,laneIndex:C},n.triggerEvent(Ce.collectionChange,r),!r.cancel){if(c){var D=new Xv;D.height=e.height,o.addRow(u,D,!1),s.height=void 0!==s.height?s.height+e.height:s.height,s.wrapper.height=o.height=s.height}else{var A=new Nd;A.width=e.width,o.addColumn(C+1,A,!1),s.width&&(s.width+=e.width,s.wrapper.width=o.width=s.width),n.diagramActions&ee.UndoRedo||(o.rows[0].cells[0].columnSpan+=1)}n.diagramActions&ee.UndoRedo||(M.id=""===M.id?Qe():M.id),void 0!==i?l.lanes.splice(i,0,M):l.lanes.push(M),r={element:M,cause:n.diagramActions,diagramAction:n.getDiagramAction(n.diagramActions),state:"Changed",type:"Addition",cancel:!1,laneIndex:C},n.triggerEvent(Ce.collectionChange,r),B3(o,n,s,u,C,c),h="Horizontal"===l.orientation?n.nameTable[o.rows[parseInt(u.toString(),10)].cells[0].children[0].id]:l.header&&l.hasHeader?n.nameTable[o.rows[1].cells[parseInt(u.toString(),10)].children[0].id]:n.nameTable[o.rows[0].cells[parseInt(u.toString(),10)].children[0].id],n.diagramActions&ee.UndoRedo||(d={type:"LaneCollectionChanged",changeType:"Insert",undoObject:$(M),redoObject:$(h),category:"Internal"},n.addHistoryEntry(d)),Zf(n,s,"Horizontal"===l.orientation?u:l.header&&l.hasHeader?1:0),$f(s),Oc(n,s);var P=!1;if((f=e.children)&&f.length>0)for(p=0;p0){var o=t.children[0],a=n.nameTable[o.id];(function vne(n,t,e){return n.left-(e.left||0)<=t.x&&n.right+(e.right||0)>=t.x&&n.top-(e.top||0)<=t.y&&n.bottom+(e.bottom||0)>=t.y})(o.bounds,e,r)&&(n.addChild(a,i),s=!0)}return s}function mne(n,t,e){if("SwimLane"===t.shape.type){var i=void 0,r=void 0,s=void 0,a=void 0,l=void 0,h=void 0,c=t.wrapper.bounds.x,d=t.wrapper.bounds.y,u=t.shape,f=u.padding,p=u.phases,g=void 0,v=t.wrapper.children[0],y="Horizontal"===u.orientation;if(i=u.header&&u.hasHeader?0:-1,u.phases.length>0&&(i+=1),e.offset>(y?u.lanes[0].header.width:u.lanes[0].header.height)){for(h=0;he.offset){if(g=h>0?e.offset-(h>0?p[h-1]:s).offset:e.offset,y){var b=v.columnDefinitions()[parseInt(h.toString(),10)];b.width-=g,(a=n.nameTable[u.phases[parseInt(h.toString(),10)].header.id]).maxWidth=a.wrapper.maxWidth=b.width,v.updateColumnWidth(h,b.width,!1);var M=new Nd;M.width=g,l=h,v.addColumn(h,M,!1);break}var w=v.rowDefinitions()[h+i];w.height-=g,a=n.nameTable[u.phases[parseInt(h.toString(),10)].header.id],v.updateRowHeight(h+i,w.height,!1);var C=new Xv;C.height=g,l=h,v.addRow(h+i,C,!1);break}if(n.diagramActions&ee.UndoRedo&&void 0===l&&(D=n.historyManager.currentEntry.next).isLastPhase&&function yne(n,t,e,i,r,s){var a=t.shape.phases[n-2],l=e.previousPhase.offset;if(r){var h=i.columnDefinitions()[n-1],c=new Nd;n>1?(c.width=h.width-(l-a.offset),h.width=l-a.offset):(c.width=h.width-l,h.width=l),i.updateColumnWidth(n-1,h.width,!1),i.addColumn(n,c,!1)}else{h=i.rowDefinitions()[parseInt(n.toString(),10)];var d=new Xv;n>1?(d.height=e.undoObject.offset-l,h.height=l-a.offset):(d.height=h.height-l,h.height=l),i.updateRowHeight(n,h.height,!1),i.addRow(1+n,d,!1)}}(l=p.length,t,D,v,y),l>=0){var A=new fb(t.shape,"phases",e,!0);if(n.diagramActions&ee.UndoRedo||(A.id+=Qe()),u.phases.splice(l,0,A),jx(v,n,t,i,y,l),y){if(r=n.nameTable[v.rows[parseInt(i.toString(),10)].cells[parseInt(l.toString(),10)].children[0].id],0===l&&u.header&&u.hasHeader){v.rows[0].cells[0].children=v.rows[0].cells[1].children,v.rows[0].cells[1].children=[];for(var x=v.rows[0],P=0;Pl+1){var O=n.nameTable[v.rows[parseInt(i.toString(),10)].cells[l+1].children[0].id];v.updateColumnWidth(l+1,L[l+1].width,!0,f),O.maxWidth=O.wrapper.maxWidth=L[l+1].width}t.width=t.wrapper.width=t.wrapper.children[0].width=v.width}else{r=n.nameTable[v.rows[i+l].cells[0].children[0].id];var N=v.rowDefinitions(),T=N[i+l].height;(function Ine(n,t,e,i,r){for(var o,a,l=e.rows[parseInt(i.toString(),10)],h=e.rows[i+1],c=e.rows[i-1],d=1;di+l+1&&v.updateRowHeight(i+l+1,T=N[i+l+1].height,!0,f),t.height=t.wrapper.height=t.wrapper.children[0].height=v.actualSize.height}if($f(t),t.width=t.wrapper.actualSize.width,Oc(n,t),n.drag(t,c-t.wrapper.bounds.x,d-t.wrapper.bounds.y),VI(t,n),n.commandHandler.select(r),!(n.diagramActions&ee.UndoRedo)){var D={type:"PhaseCollectionChanged",changeType:"Insert",undoObject:$(A),redoObject:$(r),category:"Internal"};n.addHistoryEntry(D)}n.updateDiagramObject(t)}}}}function V3(n,t,e,i,r,s,o){var a,l,p,h=t.shape,c="Horizontal"===h.orientation,d=t.wrapper.children[0],g=c?s:o;e?(a=c?e.bounds.x+e.bounds.width:e.bounds.x,l=c?e.bounds.y:e.bounds.y+e.bounds.height):(a=d.bounds.x,l=r.bounds.y);var v=new Ne(a,l,i.desiredCellWidth,i.desiredCellHeight),S=qv(n,0,t,{id:t.id+(c?h.lanes[g-2]:h.lanes[g-1]).id+Qe()[0],rowIndex:s,columnIndex:o,width:i.minWidth,height:i.minHeight,style:(c?h.lanes[g-2]:h.lanes[g-1]).style,constraints:ie.Default|ie.AllowDrop,container:{type:"Canvas",orientation:c?"Horizontal":"Vertical"}},!1,!1,!0);if(S.children[0].isCalculateDesiredSize=!1,d.addObject(S,s,o),r&&r.children&&r.children.length)for(p=0;p1)for(var p=1;ph.margin.left&&(h.margin.left=f)):(h.margin.top-=e.desiredCellHeight,f>h.margin.top&&(h.margin.top=f)))}(n,r,i,v,S,c,e)}function W3(n,t,e){if("SwimLane"===t.shape.type&&("ResizeSouth"===e||"ResizeEast"===e)){var i=t.shape,r=t.wrapper.children[0],s=void 0,o=void 0;"ResizeSouth"===e?"Vertical"===i.orientation?s=r.rows[r.rows.length-1].cells[0]:(o=r.rows.length-1,s=r.rows[parseInt(o.toString(),10)].cells[r.rows[parseInt(o.toString(),10)].cells.length-1]):(o=i.header&&i.hasHeader?1:0,s=r.rows[parseInt(o.toString(),10)].cells[r.rows[parseInt(o.toString(),10)].cells.length-1]),n.commandHandler.select(n.nameTable[s.children[0].id])}}function GI(n,t,e,i,r,s){var o,a,l,c,u,f,p,d=Qe(),g=n.shape,v=g.phases,y=n.offsetX-n.wrapper.actualSize.width/2,S=n.offsetY-n.wrapper.actualSize.height/2;if("Vertical"===g.orientation&&(S+=g.header&&g.hasHeader?g.header.height:0),!s)for(r||(n.id+=d,g&&g.header&&g.hasHeader?g.header.id+=d:g.header=void 0),o=0;v&&o0&&s.columnIndex>0||s.isLane)?(a=function Lne(n,t,e){for(var i=new Ne,r="SwimLane"===n.shape.type?n.wrapper.children[0].rows:n.wrapper.rows,s=e?1:0;s=0;a--)i?i.id===o.children[parseInt(a.toString(),10)].id&&o.children.splice(a,1):(n.removeDependentConnector(o.children[parseInt(a.toString(),10)]),n.diagramActions&ee.UndoRedo||(n.diagramActions=n.diagramActions|ee.UndoRedo,s=!0),n.remove(o.children[parseInt(a.toString(),10)]),o.children.splice(a,1),s&&(n.diagramActions=n.diagramActions&~ee.UndoRedo))}function Mne(n){return n.children[0]}function Jv(n,t){t&&(n.nodes.splice(n.nodes.indexOf(t),1),n.removeFromAQuad(t),n.removeObjectsFromLayer(t),delete n.nameTable[t.id],n.removeElements(t))}function Q3(n,t,e,i){var r;if("SwimLane"===e.shape.type){var s=e.shape,o=void 0;if(1===s.lanes.length)n.remove(e);else{var a=e.wrapper.bounds.x,l=e.wrapper.bounds.y,h=void 0,c=void 0,d=void 0,u=void 0,p=e.wrapper.children[0];if(o=i?s.lanes.indexOf(i):WI(e,t),r={element:t,cause:n.diagramActions,diagramAction:n.getDiagramAction(n.diagramActions),state:"Changing",type:"Removal",cancel:!1,laneIndex:o},n.triggerEvent(Ce.collectionChange,r),!r.cancel){var g=s.lanes[parseInt(o.toString(),10)],v=g.children;g.children=[];for(var y=0;y0)for(u=0;u0)for(u=0;u0)for(e=0;e1){c===l.phases.length-1&&(o=!0,a=$(l.phases[c-1]));var u=$(l.phases[parseInt(c.toString(),10)]);if(l.phases.splice(c,1),!(n.diagramActions&ee.UndoRedo)){var f={type:"PhaseCollectionChanged",changeType:"Remove",undoObject:u,previousPhase:a,redoObject:$(t),category:"Internal",isLastPhase:o};n.addHistoryEntry(f)}"Horizontal"===l.orientation?function Cne(n,t,e,i){var r,s,o,a,l,h,c,d,u,f,p,g;for(i=void 0!==i?i:e.columnIndex,c=0;c1&&(s=r.cells[parseInt(i.toString(),10)],l=(o=r.cells.length-1===i?r.cells[i-1]:r.cells[i+1]).children[0],s.children.length>0))if(p=n.nameTable[(a=s.children[0]).id],0===o.children.length&&s.children.length>0)o.children=s.children,o.columnSpan=s.columnSpan-1;else{for(d=0;d0){var M=s.children[0],w=n.nameTable[M.id];if(i=e.x&&a.bounds.y<=e.y&&a.bounds.bottom>=e.y){var l=void 0,h=a.bounds.y,c=a.bounds.x,d=n.nameTable[r.parentId]||r;if("SwimLane"===d.shape.type)o=em(r,d,t,n,!0);else{var f=n.nameTable[r.parentId]||r,p=f.shape;l=f.wrapper,a.actualSize.widtha.outerBounds.x)&&(void 0!==r.rowIndex?(l.updateColumnWidth(r.columnIndex,a.outerBounds.width,!0),"Horizontal"===p.orientation&&p.phaseSize&&QI(f,n,a,r.columnIndex),Oc(n,f),n.drag(f,c-a.bounds.x,h-a.bounds.y)):n.scale(r,1+(a.outerBounds.width-a.actualSize.width)/a.actualSize.width,1,a.outerBounds.xa.outerBounds.y)&&(void 0!==r.rowIndex?(l.updateRowHeight(r.rowIndex,a.outerBounds.height,!0),n.drag(f,c-a.bounds.x,h-a.bounds.y)):n.scale(r,1,1+(a.outerBounds.height-a.actualSize.height)/a.actualSize.height,a.outerBounds.y=e.x&&a.bounds.y<=e.y&&a.bounds.bottom>=e.y)&&!(t.constraints&ie.AllowMovingOutsideLane)){var l=$(t);n.clearSelection(),$3(n,t),t.parentId="",t.parentObj=n,t.propName="nodes";var h={type:"ChildCollectionChanged",category:"Internal",undoObject:l,redoObject:$(t)};n.addHistoryEntry(h),n.commandHandler.isContainer&&(n.commandHandler.isContainer=!1,n.endGroupAction()),Z3(t,n)}n.protectPropertyChange(o)}}function XI(n,t){var e,i,r;return n.enableServerDataBinding(!1),ce()||(n.selectedObject.helperObject?r=n.selectedObject.helperObject:(n.selectedItems.nodes.length>0||n.selectedItems.connectors.length>0)&&(t instanceof ei&&t.nodes.length+t.connectors.length===1?(e=t.nodes.length>0?t.nodes[0]:t.connectors[0],i=n.selectedItems.wrapper.children[0]):(e=t,i=n.selectedItems.wrapper),n.selectedObject.actualObject=e,!n.currentSymbol&&(e.isLane&&Qx(e,n)&&Dn(n,e)||!e.isLane&&Dn(n,e)||n.constraints&nt.LineRouting&&n.selectedItems.nodes.length>0))&&(r=function Nne(n,t){for(var e,i={},r=0,s=Object.keys(t);r=t.x-e&&n.x<=t.x+e&&n.y>=t.y-e&&n.y<=t.y+e}function $a(n){return n.selectedItems.nodes.length>0||n.selectedItems.connectors.length>0}function K3(n){return 1===n.selectedItems.connectors.length&&!n.selectedItems.nodes.length}function _r(n,t,e,i){if(void 0===e&&(e=!0),t instanceof ei)return!0;if(t instanceof te)for(;t;){if(-1!==n.selectedItems.nodes.indexOf(t)&&void 0===n.selectedItems.annotation)return!0;if(e)break;t=n.nameTable[t.parentId]}else if(t instanceof de){if(-1!==n.selectedItems.connectors.indexOf(t)&&void 0===n.selectedItems.annotation)return!0}else if((t instanceof Kn||t instanceof Or)&&n.selectedItems.annotation&&n.selectedItems.wrapper.children[0].id===i.id)return!0;return!1}var Gx={None:"default",Rotate:"crosshair",Select:"default",Drag:"move",ResizeWest:"w-resize",ResizeEast:"e-resize",ResizeSouth:"s-resize",ResizeNorth:"n-resize",Draw:"crosshair",PortDraw:"crosshair",ResizeNorthEast:"ne-resize",ResizeNorthWest:"nw-resize",ResizeSouthEast:"se-resize",ResizeSouthWest:"sw-resize",ConnectorSourceEnd:"move",ConnectorTargetEnd:"move",BezierSourceThumb:"move",BezierTargetThumb:"move",OrthoThumb:"move",SegmentEnd:"move",Pan:"grab",Hyperlink:"pointer",PortDrag:"pointer",LabelSelect:"pointer",LabelDrag:"move",LabelRotate:"crosshair",LabelResizeWest:"w-resize",LabelResizeEast:"e-resize",LabelResizeSouth:"s-resize",LabelResizeNorth:"n-resize",LabelResizeNorthEast:"ne-resize",LabelResizeNorthWest:"nw-resize",LabelResizeSouthEast:"se-resize",LabelResizeSouthWest:"sw-resize"},ds=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),kd=function(n,t,e,i){return new(e||(e=Promise))(function(r,s){function o(h){try{l(i.next(h))}catch(c){s(c)}}function a(h){try{l(i.throw(h))}catch(c){s(c)}}function l(h){h.done?r(h.value):new e(function(c){c(h.value)}).then(o,a)}l((i=i.apply(n,t||[])).next())})},Pd=function(n,t){var i,r,s,o,e={label:0,sent:function(){if(1&s[0])throw s[1];return s[1]},trys:[],ops:[]};return o={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function a(h){return function(c){return function l(h){if(i)throw new TypeError("Generator is already executing.");for(;e;)try{if(i=1,r&&(s=2&h[0]?r.return:h[0]?r.throw||((s=r.return)&&s.call(r),0):r.next)&&!(s=s.call(r,h[1])).done)return s;switch(r=0,s&&(h=[2&h[0],s.value]),h[0]){case 0:case 1:s=h;break;case 4:return e.label++,{value:h[1],done:!1};case 5:e.label++,r=h[1],h=[0];continue;case 7:h=e.ops.pop(),e.trys.pop();continue;default:if(!(s=(s=e.trys).length>0&&s[s.length-1])&&(6===h[0]||2===h[0])){e=0;continue}if(3===h[0]&&(!s||h[1]>s[0]&&h[1]-1&&(r=i.fixedUserHandles[parseInt(o.toString(),10)]);this.commandHandler.triggerEvent(Ce.fixedUserHandleClick,{fixedUserHandle:r,element:e.source}),n.prototype.mouseUp.call(this,e)},t}(us),zd=function(n){function t(e,i){var r=n.call(this,e,!0)||this;return r.isConnected=!1,r.endPoint=i,r}return ds(t,n),t.prototype.mouseDown=function(e){return kd(this,void 0,void 0,function(){var r,s,o,a,l;return Pd(this,function(h){if(this.inAction=!0,this.undoElement=void 0,this instanceof pa||(this.undoElement=$(e.source)),n.prototype.mouseDown.call(this,e),e.source&&e.source.connectors&&(this.oldConnector=$(r=e.source.connectors[0])),"BezierSourceThumb"===this.endPoint||"BezierTargetThumb"===this.endPoint)for(s=0;s0))},t.prototype.endAction=function(){n.prototype.endAction.call(this),this.prevPosition=null,this.endPoint=null},t}(us),fa=function(n){function t(e,i){var r=n.call(this,e,!0)||this;return r.currentTarget=null,r.isStartAction=!1,r.canCancel=!1,r.canTrigger=!1,r.objectType=i,r}return ds(t,n),t.prototype.mouseDown=function(e){if(e.source instanceof te||e.source instanceof de){var i=this.commandHandler.getSelectedObject();this.commandHandler.selectObjects([e.source],e.info&&e.info.ctrlKey,i);var r={nodes:[],connectors:[]};e.source instanceof te?r.nodes.push($(e.source)):r.connectors.push($(e.source)),this.undoElement=$(r)}else this.undoElement=$(e.source);this.undoParentElement=this.commandHandler.getSubProcess(e.source),"Port"===this.objectType&&(this.portId=e.sourceWrapper.id),this.commandHandler.insertBlazorConnector(e.source),n.prototype.mouseDown.call(this,e),this.initialOffset={x:0,y:0}},t.prototype.mouseUp=function(e,i){return kd(this,void 0,void 0,function(){var s,o,a,l,h,c,d,u,p,g,v,y,S,b,M;return Pd(this,function(w){if(this.checkPropertyValue(),a=!1,h={nodes:[],connectors:[]},"Port"!==this.objectType){if(e.source instanceof te||e.source instanceof de?(e.source instanceof te?h.nodes.push($(e.source)):h.connectors.push($(e.source)),(o=$(h)).offsetX=(c=e.source.wrapper).offsetX,o.offsetY=c.offsetY):o=$(e.source),("helper"===(l=this.commandHandler.renderContainerHelper(e.source)||e.source||this.commandHandler.renderContainerHelper(e.source)).id||"helper"!==l.id)&&((l instanceof ei&&(Math.round(l.width)===Math.round(this.undoElement.width)&&Math.round(l.height)===Math.round(this.undoElement.height)||l.selectedObjects&&1===l.selectedObjects.length)||!(l instanceof ei))&&(l.offsetX!==this.undoElement.offsetX||l.offsetY!==this.undoElement.offsetY||l.sourcePoint!==this.undoElement.sourcePoint||l.targetPoint!==this.undoElement.targetPoint)||this.isSelectionHasConnector(l))&&(e.source&&(s={offsetX:e.source.wrapper.offsetX,offsetY:e.source.wrapper.offsetY}),g={source:e.source,state:"Completed",oldValue:this.intialValue,newValue:s,target:this.currentTarget,targetPosition:this.currentPosition,allowDrop:(g={source:e.source,state:"Completed",oldValue:this.intialValue,newValue:s,target:this.currentTarget,targetPosition:this.currentPosition,allowDrop:!0,cancel:!1}).allowDrop,cancel:g.cancel},d=!0,"helper"===l.id?this.canTrigger?(this.commandHandler.triggerEvent(Ce.positionChange,g),this.connectorEndPointChangeEvent(g),d=!0):d=!1:(this.commandHandler.triggerEvent(Ce.positionChange,g),this.connectorEndPointChangeEvent(g)),!i&&d&&(this.commandHandler.startGroupAction(),a=!0,M={type:"PositionChanged",redoObject:$(o),undoObject:$(this.undoElement),category:"Internal"},o.nodes[0]&&o.nodes[0].processId&&(u={type:"SizeChanged",category:"Internal",undoObject:this.undoParentElement,redoObject:this.commandHandler.getSubProcess(e.source)},this.commandHandler.addHistoryEntry(u)),this.commandHandler.addHistoryEntry(M))),this.commandHandler.snapPoint(this.prevPosition,this.currentPosition,0,0),this.commandHandler.removeSnap(),this.commandHandler.removeHighlighter(),e.source&&this.currentTarget&&FI(this.currentTarget)&&this.commandHandler.isDroppable(e.source,this.currentTarget)){if(p=!0,this.commandHandler.drop(this.currentElement,this.currentTarget,this.currentPosition),this.currentTarget&&this.currentTarget instanceof de&&!0===this.commandHandler.diagram.enableConnectorSplit)if(this.currentElement&&this.currentElement instanceof te){if(void 0!==this.currentElement.children)for(b=0;b0)for(var s=0;s0)for(var a=0;a0)for(a=0;a0&&e.connectors.length>0)||e.width===this.undoElement.width&&e.height===this.undoElement.height)},t.prototype.mouseMove=function(e){n.prototype.mouseMove.call(this,e);var r,s,i=!1;(r=this.commandHandler.renderContainerHelper(e.source)||e.source)instanceof te||r instanceof de?r instanceof te?r.offsetX===this.undoElement.nodes[0].offsetX&&r.offsetY===this.undoElement.nodes[0].offsetY&&(i=!0):R.equals(r.sourcePoint,this.undoElement.connectors[0].sourcePoint)&&R.equals(r.targetPoint,this.undoElement.connectors[0].targetPoint)&&(i=!0):r.wrapper.offsetX===this.undoElement.wrapper.offsetX&&r.wrapper.offsetY===this.undoElement.wrapper.offsetY&&(i=!0),r&&(s={offsetX:r.wrapper.offsetX,offsetY:r.wrapper.offsetY});var o={source:r,state:"Start",oldValue:s,newValue:s,target:e.target,targetPosition:e.position,allowDrop:!0,cancel:!1};if(o={source:r,state:"Start",oldValue:s,newValue:s,target:e.target,targetPosition:e.position,allowDrop:o.allowDrop,cancel:o.cancel},this.isStartAction||(this.intialValue={offsetX:r.wrapper.offsetX,offsetY:r.wrapper.offsetY}),i&&!ce()&&(this.commandHandler.triggerEvent(Ce.positionChange,o),this.connectorEndPointChangeEvent(o),this.isStartAction=!0),this.currentPosition=e.position,"Port"!==this.objectType){var h=this.initialOffset.x+(this.currentPosition.x-this.prevPosition.x),c=this.initialOffset.y+(this.currentPosition.y-this.prevPosition.y);this.commandHandler.dragOverElement(e,this.currentPosition),this.commandHandler.disConnect(e.source),this.commandHandler.removeSnap();var d,u=void 0,f=this.commandHandler.snapPoint(this.prevPosition,this.currentPosition,h,c);this.initialOffset.x=h-f.x,this.initialOffset.y=c-f.y,r&&(d={offsetX:r.wrapper.offsetX,offsetY:r.wrapper.offsetY},u={offsetX:r.wrapper.offsetX+f.x,offsetY:r.wrapper.offsetY+f.y}),this.currentTarget&&e.target!==this.currentTarget&&this.commandHandler.removeChildFromBPmn(e.source,e.target,this.currentTarget),this.currentTarget=e.target;var p={source:r,state:"Progress",oldValue:d,newValue:u,target:e.target,targetPosition:e.position,allowDrop:!0,cancel:!1};if(this.commandHandler.triggerEvent(Ce.positionChange,p),this.canTrigger=!0,this.connectorEndPointChangeEvent(p,f),!p.cancel&&!this.canCancel){this.blocked=!this.commandHandler.dragSelectedObjects(f.x,f.y);var g=!this.commandHandler.mouseOver(this.currentElement,this.currentTarget,this.currentPosition);this.blocked=this.blocked||g}if(this.commandHandler.removeStackHighlighter(),this.commandHandler.renderStackHighlighter(e),this.currentTarget&&e.source!==this.currentTarget&&this.commandHandler.isDroppable(e.source,this.currentTarget)&&"helper"!==e.source.id){var v=e.source instanceof ei?e.source.nodes[0]:e.source;!this.commandHandler.isParentAsContainer(v,!0)&&"SwimLane"!==v.shape.type&&!v.shape.isPhase&&(this.currentTarget.isLane?this.commandHandler.renderStackHighlighter(e,this.currentTarget):this.commandHandler.drawHighlighter(this.currentTarget))}else this.commandHandler.removeHighlighter();if(this.commandHandler.canEnableDefaultTooltip()){var y=this.getTooltipContent(e.source);this.commandHandler.showTooltip(e.source,e.position,ko(function(){return y}),"MoveTool",this.isTooltipVisible),this.isTooltipVisible=!1}}else{var b=Bi(),M=e.source;qi(b,-M.rotateAngle||-M.wrapper.rotateAngle,M.offsetX||M.wrapper.offsetX,M.offsetY||M.wrapper.offsetY);var w=Ke(b,{x:this.prevPosition.x,y:this.prevPosition.y}),C=Ke(b,{x:e.position.x,y:e.position.y});this.commandHandler.portDrag(e.source,e.sourceWrapper,C.x-w.x,C.y-w.y)}return this.prevPosition=this.currentPosition,!this.blocked},t.prototype.getTooltipContent=function(e){return"X:"+Math.round(e.wrapper.bounds.x)+" Y:"+Math.round(e.wrapper.bounds.y)},t.prototype.mouseLeave=function(e){this.mouseUp(e)},t.prototype.endAction=function(){n.prototype.endAction.call(this),this.currentTarget=null,this.prevPosition=null},t}(us),Xx=function(n){function t(e){var i=n.call(this,e,!0)||this;return i.rotateStart=!1,i}return ds(t,n),t.prototype.mouseDown=function(e){if(this.undoElement=$(e.source),this.undoElement.nodes[0]&&this.undoElement.nodes[0].children)for(var r=this.commandHandler.getAllDescendants(this.undoElement.nodes[0],[]),s=0;s=2){var s=e.startTouches[0],o=e.startTouches[1],a=e.moveTouches[0],l=e.moveTouches[1],h=this.getDistance(a,l)/this.getDistance(s,o);this.commandHandler.zoom(h,0,0,e.position),this.updateTouch(s,a),this.updateTouch(o,l)}}else this.commandHandler.scroll(this.currentPosition.x-this.prevPosition.x,this.currentPosition.y-this.prevPosition.y,this.currentPosition);return this.commandHandler.dataBinding(),!this.blocked},t.prototype.mouseUp=function(e){this.commandHandler.setBlazorDiagramProps(!1),this.checkPropertyValue(),this.commandHandler.updatePanState(!1),n.prototype.mouseUp.call(this,e),this.inAction=!1},t.prototype.endAction=function(){n.prototype.endAction.call(this)},t.prototype.getDistance=function(e,i){var r=i.pageX-e.pageX,s=i.pageY-e.pageY;return Math.sqrt(r*r+s*s)},t.prototype.updateTouch=function(e,i){e.pageX=i.pageX,e.pageY=i.pageY},t}(us),Une=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseUp=function(e){this.checkPropertyValue(),this.commandHandler.initExpand(e),n.prototype.mouseUp.call(this,e)},t}(us),eF=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseUp=function(e){this.checkPropertyValue();var i="_blank",r="",s=window.innerHeight,o=window.innerWidth,a=window.screenTop,l=window.screenLeft;"CurrentTab"===e.sourceWrapper.hyperlink.hyperlinkOpenState?i="_self":"NewWindow"===e.sourceWrapper.hyperlink.hyperlinkOpenState&&(r="height="+s+",width="+o+",top="+a+",left="+l),window.open(e.sourceWrapper.hyperlink.link,i,r).focus(),n.prototype.mouseUp.call(this,e)},t}(us),Rl=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseDown=function(e){if(n.prototype.mouseDown.call(this,e),this.inAction=!0,this.drawingObject){var r=void 0,s=this.drawingObject.shape;this.drawingObject.shape.points.push(r={x:(r=s.points[s.points.length-1]).x,y:r.y})}else{this.startPoint={x:this.startPosition.x,y:this.startPosition.y};var i={offsetX:this.currentPosition.x,offsetY:this.currentPosition.y,width:5,height:5,shape:{type:"Basic",shape:"Polygon",points:[{x:this.startPoint.x,y:this.startPoint.y},{x:this.currentPosition.x,y:this.currentPosition.y}]}};this.triggerElementDrawEvent(e.source,"Start","Node",this.getShapeType(),!0),this.drawingObject=this.commandHandler.drawObject(i)}},t.prototype.mouseMove=function(e){if(n.prototype.mouseMove.call(this,e),this.inAction){var i=this.drawingObject.shape;if(i.points[i.points.length-1].x=this.currentPosition.x,i.points[i.points.length-1].y=this.currentPosition.y,this.drawingObject.wrapper.children[0].data=Sx(this.drawingObject.shape.points),this.triggerElementDrawEvent(this.drawingObject,"Progress","Node",this.getShapeType(),!1),this.inAction&&!1===R.equals(this.currentPosition,this.prevPosition)){var r=Ne.toBounds(this.drawingObject.shape.points);this.commandHandler.updateNodeDimension(this.drawingObject,r)}}return!0},t.prototype.mouseUp=function(e,i){this.checkPropertyValue(),n.prototype.mouseMove.call(this,e),this.inAction&&(this.inAction=!1,this.commandHandler.addObjectToDiagram(this.drawingObject),this.triggerElementDrawEvent(this.drawingObject,"Completed","Node",this.getShapeType(),!1)),this.endAction()},t.prototype.mouseWheel=function(e){n.prototype.mouseWheel.call(this,e),this.mouseMove(e)},t.prototype.endAction=function(){this.inAction=!1,this.drawingObject=null},t}(us),Hl=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseMove=function(e){if(n.prototype.mouseMove.call(this,e),this.inAction){var i=this.drawingObject;i.targetPoint=this.currentPosition,this.triggerElementDrawEvent(this.drawingObject,"Progress","Connector",this.drawingObject.type,!1),this.commandHandler.updateConnectorPoints(i)}return!0},t.prototype.mouseDown=function(e){if(n.prototype.mouseDown.call(this,e),this.inAction=!0,this.drawingObject){var r=this.drawingObject,s=void 0;(s=new Bl(r,"segments",{type:"Straight"},!0)).point=this.currentPosition,r.segments[r.segments.length-1]=s}else{var i={id:"Connector",type:"Straight",sourcePoint:this.currentPosition,targetPoint:this.currentPosition};this.triggerElementDrawEvent(e.source,"Start","Connector",this.commandHandler.diagram.drawingObject.type,!0),this.inAction&&(this.drawingObject=this.commandHandler.drawObject(i))}},t.prototype.mouseWheel=function(e){n.prototype.mouseWheel.call(this,e),this.mouseMove(e)},t.prototype.mouseUp=function(e){if(this.checkPropertyValue(),n.prototype.mouseMove.call(this,e),this.inAction&&this.drawingObject){var i=this.drawingObject;i.segments[i.segments.length-1].point={x:0,y:0},this.commandHandler.addObjectToDiagram(this.drawingObject),this.triggerElementDrawEvent(this.drawingObject,"Completed","Connector",this.drawingObject.type,!1)}this.endAction()},t.prototype.endAction=function(){this.drawingObject=null,this.inAction=!1},t}(us),jne=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseDown=function(e){this.inAction=!0,this.undoElement=$(e.source),this.annotationId=e.sourceWrapper.id,n.prototype.mouseDown.call(this,e)},t.prototype.mouseMove=function(e){n.prototype.mouseMove.call(this,e);var i=this.currentPosition.x-this.prevPosition.x,r=this.currentPosition.y-this.prevPosition.y,s=e.source;if(s instanceof te){var o=Bi();qi(o,-s.rotateAngle,0,0);var a=Ke(o,{x:i,y:r});i=a.x,r=a.y}return this.inAction&&(this.commandHandler.labelDrag(e.source,e.sourceWrapper,i,r),this.commandHandler.updateSelector()),this.prevPosition=this.currentPosition,!this.blocked},t.prototype.mouseUp=function(e){this.checkPropertyValue();var i=e.source;this.inAction=!1;var r={type:"AnnotationPropertyChanged",objectId:this.annotationId,undoObject:$(this.undoElement),category:"Internal",redoObject:$(i)};this.commandHandler.addHistoryEntry(r),n.prototype.mouseUp.call(this,e)},t.prototype.mouseLeave=function(e){this.mouseUp(e)},t}(us),Vne=function(n){function t(e,i){var r=n.call(this,e,!0)||this;return r.corner=i,r}return ds(t,n),t.prototype.mouseDown=function(e){this.inAction=!0;var i=e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0];this.annotationId=e.source.wrapper.children[0].id,this.undoElement=$(i);var r=e.source.wrapper.children[0];this.initialBounds={x:r.offsetX,y:r.offsetY,width:r.actualSize.width,height:r.actualSize.height},n.prototype.mouseDown.call(this,e)},t.prototype.mouseMove=function(e){return n.prototype.mouseMove.call(this,e),this.inAction&&this.resizeObject(e),!this.blocked},t.prototype.mouseUp=function(e){this.checkPropertyValue();var i=e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0];this.inAction=!1;var r={type:"AnnotationPropertyChanged",objectId:this.annotationId,redoObject:$(i),undoObject:$(this.undoElement),category:"Internal"};this.commandHandler.addHistoryEntry(r),n.prototype.mouseUp.call(this,e)},t.prototype.mouseLeave=function(e){this.mouseUp(e)},t.prototype.resizeObject=function(e){var i,s,o,r=e.source.wrapper.children[0],a={x:r.offsetX,y:r.offsetY},l=r.rotateAngle;l=((l+=(i=e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0])instanceof te?i.rotateAngle:0)+360)%360;var h=Bi();qi(h,l,a.x,a.y);var c=this.corner.slice(5),d=this.updateSize(r,this.startPosition,this.currentPosition,c,this.initialBounds,l),u=r.offsetX-r.actualSize.width*r.pivot.x,f=r.offsetY-r.actualSize.height*r.pivot.y,p=this.getPivot(c),g=Ke(h,p={x:u+r.actualSize.width*p.x,y:f+r.actualSize.height*p.y});d.x=g.x,d.y=g.y,this.commandHandler.labelResize(i,e.source.annotation,s=(s=d.width)<0?1:s,o=(o=d.height)<0?1:o,d,e.source),this.commandHandler.updateSelector()},t}(us),Wne=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseDown=function(e){this.inAction=!0,this.annotationId=e.source.wrapper.children[0].id,this.undoElement=$(e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0]),n.prototype.mouseDown.call(this,e)},t.prototype.mouseMove=function(e){return n.prototype.mouseMove.call(this,e),e.source&&this.inAction&&(this.commandHandler.labelRotate(e.source.nodes[0]?e.source.nodes[0]:e.source.connectors[0],e.source.annotation,this.currentPosition,e.source),this.commandHandler.updateSelector()),this.prevPosition=this.currentPosition,!this.blocked},t.prototype.mouseUp=function(e){this.checkPropertyValue(),this.inAction=!1;var r={type:"AnnotationPropertyChanged",objectId:this.annotationId,redoObject:$(e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0]),undoObject:$(this.undoElement),category:"Internal"};this.commandHandler.addHistoryEntry(r),n.prototype.mouseUp.call(this,e)},t.prototype.mouseLeave=function(e){this.mouseUp(e)},t}(us),Yne=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseMove=function(e){if(n.prototype.mouseMove.call(this,e),this.inAction){var i=this.drawingObject.shape;if(i.points.push(this.currentPosition),this.drawingObject.wrapper.children[0].data=Ix(this.drawingObject.shape.points),i.data=Ix(i.points),this.triggerElementDrawEvent(e.source,"Progress","Connector",this.drawingObject.type,!1),this.inAction&&!1===R.equals(this.currentPosition,this.prevPosition)){var s=Ne.toBounds(this.drawingObject.shape.points);this.commandHandler.updateNodeDimension(this.drawingObject,s)}}return!0},t.prototype.mouseDown=function(e){n.prototype.mouseDown.call(this,e),this.inAction=!0,this.startPoint={x:this.startPosition.x,y:this.startPosition.y};var i={offsetX:this.currentPosition.x,offsetY:this.currentPosition.y,width:5,height:5,style:{strokeColor:"black",strokeWidth:1,fill:"transparent"},shape:{type:"Path",points:[{x:this.startPoint.x,y:this.startPoint.y},{x:this.currentPosition.x,y:this.currentPosition.y}]}};this.triggerElementDrawEvent(e.source,"Start","Connector",this.commandHandler.diagram.drawingObject.type,!0),this.drawingObject=this.commandHandler.drawObject(i)},t.prototype.mouseUp=function(e){if(this.checkPropertyValue(),this.inAction){this.inAction=!1;var s=this.drawingObject.shape,o=s.points;this.commandHandler.addObjectToDiagram(this.drawingObject),this.commandHandler.diagram.remove(this.commandHandler.diagram.nameTable[""+this.drawingObject.id]),o=this.pointReduction(o,10);var h={id:"newConnector"+Qe(),type:"Bezier",sourcePoint:{x:o[0].x,y:o[0].y},targetPoint:{x:o[o.length-1].x,y:o[o.length-1].y},segments:[],bezierSettings:{allowSegmentsReset:!1}};this.drawingObject=this.commandHandler.drawObject(h),this.drawingObject=this.bezierCurveSmoothness(o,.5,this.drawingObject,s),this.commandHandler.updateConnectorPoints(this.drawingObject),this.commandHandler.addObjectToDiagram(this.drawingObject),this.triggerElementDrawEvent(this.drawingObject,"Completed","Connector",this.drawingObject.type,!1),n.prototype.mouseUp.call(this,e)}},t.prototype.pointReduction=function(e,i){if(null===e||e.length<3)return e;var s=e.length-1,o=[];for(o.push(0),o.push(s);e[parseInt((0).toString(),10)]===e[parseInt(s.toString(),10)];)s--;this.reduction(e,0,s,i,o);var a=[];return o.sort(function(l,h){return l-h}),o.forEach(function(l){a.push(e[parseInt(l.toString(),10)])}),a},t.prototype.reduction=function(e,i,r,s,o){for(var a=0,l=0,h=i;ha&&(a=c,l=h)}a>s&&0!==l&&(o.push(l),this.reduction(e,i,l,s,o),this.reduction(e,l,r,s,o))},t.prototype.perpendicularDistance=function(e,i,r){return Math.abs(.5*(e.x*i.y-i.x*e.y+(i.x*r.y-r.x*i.y)+(r.x*e.y-e.x*r.y)))/Math.sqrt(Math.pow(e.x-i.x,2)+Math.pow(e.y-i.y,2))*2},t.prototype.bezierCurveSmoothness=function(e,i,r,s){if(e.length<3)return r;for(var o=0;o=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Qne=function(n){if(n)switch(n.type){case"Bpmn":return $ne;case"UmlActivity":return qne;case"UmlClassifier":return Kne;default:return rm}return rm},Gne=function(n){if(n)switch(n.type){case"Straight":default:return Bl;case"Bezier":return fs;case"Orthogonal":return wi}},tF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I(10)],t.prototype,"width",void 0),Pe([I(10)],t.prototype,"height",void 0),Pe([I("Arrow")],t.prototype,"shape",void 0),Pe([re({fill:"black",strokeColor:"black",strokeWidth:1},Nl)],t.prototype,"style",void 0),Pe([re({x:0,y:.5},R)],t.prototype,"pivot",void 0),Pe([I("")],t.prototype,"pathData",void 0),t}(Ee),ZI=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I(0)],t.prototype,"angle",void 0),Pe([I(0)],t.prototype,"distance",void 0),t}(Ee),Xne=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I(Cx.All)],t.prototype,"controlPointsVisibility",void 0),Pe([I("FreeForm")],t.prototype,"segmentEditOrientation",void 0),Pe([I(CI.Default)],t.prototype,"smoothness",void 0),Pe([I(!0)],t.prototype,"allowSegmentsReset",void 0),t}(Ee),rm=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I("None")],t.prototype,"type",void 0),t}(Ee),qne=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I("Object")],t.prototype,"flow",void 0),Pe([I(30)],t.prototype,"exceptionFlowHeight",void 0),t}(rm),$ne=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I("Sequence")],t.prototype,"flow",void 0),Pe([I("Normal")],t.prototype,"sequence",void 0),Pe([I("Default")],t.prototype,"message",void 0),Pe([I("Default")],t.prototype,"association",void 0),t}(rm),iF=function(n){function t(e,i,r,s){var o=n.call(this,e,i,r,s)||this;return o.points=[],o}return Qs(t,n),Pe([I("Straight")],t.prototype,"type",void 0),Pe([I(!0)],t.prototype,"allowDrag",void 0),t}(Ee),Bl=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),t.prototype.getClassName=function(){return"StraightSegment"},Pe([re({x:0,y:0},R)],t.prototype,"point",void 0),t}(iF),fs=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),t.prototype.getClassName=function(){return"BezierSegment"},t.prototype.getPoints=function(e,i){var r=[];if(r.length>0||null!=i){var o=this.bezireToPoly(r.length>0?r[r.length-1]:i,e);r.push.apply(r,o)}return r},t.prototype.bezireToPoly=function(e,i){var r=[];return i&&this.flattenCubicBezier(r,e,i.bezierPoint1,i.bezierPoint2,{x:i.points[1].x,y:i.points[1].y},10),r},t.prototype.flattenCubicBezier=function(e,i,r,s,o,a){var h,l=(R.findLength(i,r)+R.findLength(r,s)+R.findLength(s,o))/a;for(h=0;h<=l;h++){var c=h/l;e.push({x:(1-c)*(1-c)*(1-c)*i.x+3*c*(1-c)*(1-c)*r.x+3*c*c*(1-c)*s.x+c*c*c*o.x,y:(1-c)*(1-c)*(1-c)*i.y+3*c*(1-c)*(1-c)*r.y+3*c*c*(1-c)*s.y+c*c*c*o.y})}},Pe([I("Horizontal")],t.prototype,"orientation",void 0),Pe([re({x:0,y:0},R)],t.prototype,"point1",void 0),Pe([re({x:0,y:0},R)],t.prototype,"point2",void 0),Pe([re({angle:0,distance:0},ZI)],t.prototype,"vector1",void 0),Pe([re({angle:0,distance:0},ZI)],t.prototype,"vector2",void 0),t}(Bl),wi=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),t.prototype.getClassName=function(){return"OrthogonalSegment"},Pe([I(null)],t.prototype,"length",void 0),Pe([I(null)],t.prototype,"direction",void 0),t}(iF);function rF(n,t,e){var s=e?45:180/(2+2/(n.height/n.width)),o=s,a=180-s,l=a+2*s,h=360-s,c=Gt(t,n.center);return c>o&&ca&&cl&&cMath.abs(t.y-n.y)?n.x=c)return s=R.findAngle(n[parseInt(d.toString(),10)],n[d+1]),{point:r=R.transform(n[parseInt(d.toString(),10)],s,c-(a||0)),index:l=d};a=o[parseInt(d.toString(),10)]}return{point:r,index:l}}(n,t),r=R.findAngle(n[i.index],n[i.index+1]),s=function xse(n){var e=0;switch(n.alignment){case"Center":case"After":e=0;break;case"Before":e=-0}return e}(t),o=R.transform(i.point,r+45,s);return i.point=o,i.angle=r,i}(i,e),h=l.point;s.id=this.id+"_"+e.id;var c=e.style;s.style={fill:c.fill,strokeColor:c.strokeColor,gradient:null,opacity:c.opacity,strokeDashArray:c.strokeDashArray,strokeWidth:c.strokeWidth},0===r.width&&(r.width=this.style.strokeWidth),0===r.height&&(r.height=this.style.strokeWidth);var d_y=(h.y-r.y)/r.height;a.x=r.width*((h.x-r.x)/r.width),a.y=r.height*d_y;var g,v,u=SF(e,l.angle,i),f=u.hAlign,p=u.vAlign;return"left"===f?(g="Left",a.x+=e.displacement.x):"right"===f?(g="Right",a.x-=e.displacement.x):"center"===f&&(g="Center"),"top"===p?(v="Top",a.y+=e.displacement.y):"bottom"===p?(v="Bottom",a.y-=e.displacement.y):"center"===p&&(v="Center"),s.horizontalAlignment=g,s.verticalAlignment=v,(s=om(s,o&&"Label"!==o.flipMode&&"None"!==o.flipMode?this.flip:"None",e)).float=!0,s.connectionDirection=e.connectionDirection,s.setOffsetWithRespectToBounds(a.x,a.y,"Absolute"),s.relativeMode="Point",s.visible=!(!va(e,ci.Visible)||va(e,ci.Hover)||va(e,ci.Connect)),s.elementActions=s.elementActions|Xr.ElementIsPort,s},t.prototype.getConnectorRelation=function(){var e=this.shape;"Association"===e.relationship?(this.segments[0].type="Straight",this.sourceDecorator.shape="None",this.targetDecorator.shape="Arrow"):"Inheritance"===e.relationship?(this.segments[0].type="Orthogonal",this.sourceDecorator.shape="None",this.targetDecorator.shape="Arrow"):"Composition"===e.relationship||"Aggregation"===e.relationship?(this.segments[0].type="Orthogonal",this.sourceDecorator.shape="Diamond",this.targetDecorator.shape="None"):"Dependency"===e.relationship?(this.segments[0].type="Orthogonal",this.sourceDecorator.shape="None",this.targetDecorator.shape="OpenArrow"):"Realization"===e.relationship&&(this.segments[0].type="Orthogonal",this.sourceDecorator.shape="None",this.targetDecorator.shape="Arrow"),"BiDirectional"===e.associationType&&(this.sourceDecorator.shape="None",this.targetDecorator.shape="None");var i,o,r="",s="";e.multiplicity.source&&(e.multiplicity.source.lowerBounds=e.multiplicity.source.lowerBounds,e.multiplicity.source.upperBounds=e.multiplicity.source.upperBounds),e.multiplicity.target&&(e.multiplicity.target.lowerBounds=e.multiplicity.target.lowerBounds,e.multiplicity.target.upperBounds=e.multiplicity.target.upperBounds);var a=e.multiplicity.source,l=e.multiplicity.target;o=a.upperBounds?a.lowerBounds+"..."+a.upperBounds:a.lowerBounds,i=l.upperBounds?l.lowerBounds+"..."+l.upperBounds:l.lowerBounds,"ManyToOne"===e.multiplicity.type&&(e.multiplicity.target.optional=!1,r=o||"*",s="1"),"OneToMany"===e.multiplicity.type&&(e.multiplicity.source.optional=!1,s=i||"*",r="1"),"ManyToMany"===e.multiplicity.type&&(r=o||"*",s=i||"*"),"OneToOne"===e.multiplicity.type&&(e.multiplicity.target.optional=!1,e.multiplicity.source.optional=!1,r="1",s="1"),this.annotations=[{id:this.id+"sourcelabel",content:r,offset:0,alignment:"Before",margin:{right:5,bottom:5}},{id:this.id+"targetlabel",content:s,offset:1,alignment:"Before",margin:{right:5,bottom:5}}]},t.prototype.getBpmnSequenceFlow=function(){var e=new Ze,i=new Ze;return"Normal"===this.shape.sequence&&"Bezier"!==this.type&&(this.targetDecorator.shape="Arrow"),"Default"===this.shape.sequence&&(e=this.getSegmentElement(this,e),i=DF(this.intermediatePoints,this),this.targetDecorator.shape="Arrow"),"Conditional"===this.shape.sequence&&(this.targetDecorator.shape="Arrow",this.sourceDecorator.shape="Diamond",i.id=this.id+this.shape.type),i},t.prototype.getUMLObjectFlow=function(){if(this.annotations)for(var e=0;e0&&(this.sourcePoint=o[0],this.targetPoint=o[o.length-1]),o},t.prototype.clipDecorator=function(e,i,r,s){var a,l,o={x:0,y:0},h=i.length,c=R.distancePoints(a=r?i[0]:i[h-1],l=r?i[1]:i[h-2]);c=0===c?1:c;var d=1,u=r?e.sourceWrapper:e.targetWrapper;u&&(d=u.style.strokeWidth,s&&s&ee.DecoratorPropertyChange&&(d=1));var f=d-1;return o.x=Math.round(a.x+f*(l.x-a.x)/c),o.y=Math.round(a.y+f*(l.y-a.y)/c),(r&&"None"!==e.sourceDecorator.shape||!r&&"None"!==e.targetDecorator.shape)&&(o=R.adjustPoint(o,l,!0,s&ee.DecoratorPropertyChange?0:d/2)),o},t.prototype.clipDecorators=function(e,i,r){return"None"!==e.sourceDecorator.shape&&(i[0]=this.clipDecorator(e,i,!0,r)),"None"!==e.targetDecorator.shape&&(i[i.length-1]=this.clipDecorator(e,i,!1,r)),i},t.prototype.updateSegmentElement=function(e,i,r,s){var o=new Ne,a=this.getSegmentPath(e,i,s);if("Bezier"===e.type){if(this.segments.length>0)for(var l=0;l0)if("Straight"===e.type&&e.segments.length<2)for(var o=0;o1)for(o=0;o0&&"Bezier"!==this.type)for(var f=0;f0&&(a=f0&&(p<2*this.cornerRadius?(l=R.adjustPoint(h[parseInt(f.toString(),10)],h[f+1],!0,p/2),f0&&(s=this.bridgePath(e,s,f),"Orthogonal"===e.type&&(s=this.bridgePath(e,s,f+1))),s+=" L"+a.x+" "+a.y))}else if("Bezier"===this.type){var g=void 0,v=void 0;if(this.parentObj.element){var y=this.parentObj.element.ej2_instances[0].eventHandler.action;g=this.parentObj.element.ej2_instances[0].eventHandler.tool instanceof Rd,v=y.includes("PortDraw")||y.includes("Drag")}for(var S=void 0,b=this.segments,M=0;M2&&(b[parseInt(M.toString(),10)].bezierPoint1={x:0,y:0},b[parseInt(M.toString(),10)].bezierPoint2={x:0,y:0}),!R.isEmptyPoint(b[parseInt(M.toString(),10)].point1)||b[parseInt(M.toString(),10)].vector1.angle||b[parseInt(M.toString(),10)].vector1.distance?b[parseInt(M.toString(),10)].vector1.angle||b[parseInt(M.toString(),10)].vector1.distance?b[parseInt(M.toString(),10)].bezierPoint1=R.transform(h[parseInt(M.toString(),10)],b[parseInt(M.toString(),10)].vector1.angle,b[parseInt(M.toString(),10)].vector1.distance):b[parseInt(M.toString(),10)].bezierPoint1={x:b[parseInt(M.toString(),10)].point1.x||b[parseInt(M.toString(),10)].bezierPoint1.x,y:b[parseInt(M.toString(),10)].point1.y||b[parseInt(M.toString(),10)].bezierPoint1.y}:((e.sourceID||this.sourcePortID)&&this.sourceWrapper&&!v&&!g&&(S=rF(this.sourceWrapper.bounds,h[parseInt(M.toString(),10)],!0)),b[parseInt(M.toString(),10)].bezierPoint1=KI(h[parseInt(M.toString(),10)],h[M+1],S)),!R.isEmptyPoint(b[parseInt(M.toString(),10)].point2)||b[parseInt(M.toString(),10)].vector2.angle||b[parseInt(M.toString(),10)].vector2.distance?b[parseInt(M.toString(),10)].vector2.angle||b[parseInt(M.toString(),10)].vector2.distance?b[parseInt(M.toString(),10)].bezierPoint2=R.transform(h[M+1],b[parseInt(M.toString(),10)].vector2.angle,b[parseInt(M.toString(),10)].vector2.distance):b[parseInt(M.toString(),10)].bezierPoint2={x:b[parseInt(M.toString(),10)].point2.x||b[parseInt(M.toString(),10)].bezierPoint2.x,y:b[parseInt(M.toString(),10)].point2.y||b[parseInt(M.toString(),10)].bezierPoint2.y}:((e.targetID||this.targetPortID)&&this.targetWrapper&&!v&&!g&&(S=rF(this.targetWrapper.bounds,h[M+1],!0)),b[parseInt(M.toString(),10)].bezierPoint2=KI(h[M+1],h[parseInt(M.toString(),10)],S));h.splice(1,0,{x:b[0].bezierPoint1.x,y:b[0].bezierPoint1.y}),h.splice(h.length-1,0,{x:b[b.length-1].bezierPoint2.x,y:b[b.length-1].bezierPoint2.y}),h=this.clipDecorators(e,h,r);for(var w=0;w0&&(s=this.bridgePath(e,s,D),s+=" L"+o.x+" "+o.y);return s},t.prototype.updateShapeElement=function(e){var i;switch(e.shape.type){case"Bpmn":e.wrapper.children[3]instanceof Ze&&(i=e.wrapper.children[3]),"Message"===e.shape.flow&&this.updateShapePosition(e,i);break;case"UmlActivity":"Exception"===e.shape.flow&&this.getUMLExceptionFlow(e.wrapper.children[0])}},t.prototype.updateShapePosition=function(e,i){var o=xF(this.intermediatePoints,i,.5);i.offsetX=o.x,i.offsetY=o.y},t.prototype.scale=function(e,i,r,s,o){var a=0,l=0;if(this.wrapper&&this.wrapper.outerBounds){var h=function T3(n){var t=n.wrapper.children[0].bounds;return"None"!==n.sourceDecorator.shape&&t.uniteRect(n.wrapper.children[1].bounds),"None"!==n.targetDecorator.shape&&t.uniteRect(n.wrapper.children[2].bounds),t}(this),c=Math.abs((this.wrapper.bounds.width||this.style.strokeWidth||1)-2),d=Math.abs((this.wrapper.bounds.height||this.style.strokeWidth||1)-2);a=h.width-c,l=h.height-d,e=Math.abs((r-Math.max(a,l))/c),i=Math.abs((s-Math.max(a,l))/d),a=l=Math.min(a,l)}e=i=Math.min(e,i);var u=Bi();qi(u,-(o=o||this.wrapper).rotateAngle,o.offsetX,o.offsetY),Xf(u,e,i,o.offsetX,o.offsetY),qi(u,o.rotateAngle,o.offsetX,o.offsetY);var f=function Uie(n,t){for(var e=[],i=0,r=t;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},tse=function(n){function t(e,i){var r=n.call(this,e,i)||this;return r.offset=0,r.scale=1,r}return ese(t,n),t.prototype.preRender=function(){this.unWireEvents(),this.wireEvents()},t.prototype.render=function(){this.updateRulerGeometry(),this.renderComplete()},t.prototype.getModuleName=function(){return"Ruler"},t.prototype.destroy=function(){this.unWireEvents(),this.notify("destroy",{}),n.prototype.destroy.call(this),this.element.classList.remove("e-ruler")},t.prototype.getPersistData=function(){return this.addOnPersist(["loaded"])},t.prototype.onPropertyChanged=function(e,i){for(var r=0,s=Object.keys(e);r100;)r/=10,s/=10;for(;s<25;)r*=10,s*=10;return s>=25&&s%25!=0&&(s=25*Math.round(s/25)),s*e/r},t.prototype.createMarkerLine=function(e,i,r){var s;return i&&((s=e.getElementById(i.id+"_marker"))&&s.parentNode.removeChild(s),s=Fi("line",r)),s},t.prototype.drawRulerMarker=function(e,i,r){var s,o,h,d,u="Horizontal"===this.orientation,f=e.getElementsByTagName("svg");for(h=0;h0)for(var a=i.childNodes.length-1;a>=0;a--)i.childNodes[parseInt(a.toString(),10)].parentNode.removeChild(i.childNodes[parseInt(a.toString(),10)]);i.appendChild(s)}return s},t.prototype.wireEvents=function(){},t.prototype.unWireEvents=function(){},kc([I(5)],t.prototype,"interval",void 0),kc([I(100)],t.prototype,"segmentWidth",void 0),kc([I("Horizontal")],t.prototype,"orientation",void 0),kc([I("RightOrBottom")],t.prototype,"tickAlignment",void 0),kc([I("red")],t.prototype,"markerColor",void 0),kc([I(25)],t.prototype,"thickness",void 0),kc([I(null)],t.prototype,"arrangeTick",void 0),kc([I(400)],t.prototype,"length",void 0),t}(Ii);function oF(n,t){var e=document.getElementById(n.element.id+(t?"_hRuler":"_vRuler")),i=Za(n),r=aF(n);e||(e=Tt("div",{id:n.element.id+(t?"_hRuler":"_vRuler"),style:"height:"+(t?i.height:r.height+100)+"px;overflow:hidden;width:"+(t?r.width+100:i.width)+"px;position:absolute;font-size:11px;"+(t?"margin-left:"+i.width+"px;":"margin-top:"+i.height+"px;")})),n.element.insertBefore(e,n.element.firstChild);var l=t?n.rulerSettings.horizontalRuler:n.rulerSettings.verticalRuler,h=new tse(l);h.orientation=t?"Horizontal":"Vertical",h.length=(t?r.width:r.height)+l.segmentWidth,h.appendTo("#"+n.element.id+(t?"_hRuler":"_vRuler")),t?n.hRuler=h:n.vRuler=h;var c=document.getElementById(n.element.id+(t?"_hRuler":"_vRuler"));t?n.hRuler.element=c:n.vRuler.element=c}function eb(n){var t=-n.scroller.horizontalOffset,e=-n.scroller.verticalOffset;n&&n.rulerSettings.showRulers?(n.hRuler.length=0,n.vRuler.length=0,void 0!==t&&n.hRuler.element&&lF(n,n.hRuler,t,!0),void 0!==e&&n.vRuler.element&&lF(n,n.vRuler,e,!1)):qx(n)}function qx(n){an(n.element.id+"_hRuler"),an(n.element.id+"_vRuler"),an(n.element.id+"_overlapRuler")}function Za(n){var t=0,e=0;return n.rulerSettings.showRulers&&(t=n.rulerSettings.horizontalRuler.thickness,e=n.rulerSettings.verticalRuler.thickness),new me(e,t)}function aF(n){var t=Za(n),e=n.scroller.viewPortHeight,i=n.scroller.viewPortWidth;return i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},hF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return ase(t,n),t.prototype.getClassName=function(){return"UserHandle"},Un([I("")],t.prototype,"name",void 0),Un([I("")],t.prototype,"pathData",void 0),Un([I("")],t.prototype,"content",void 0),Un([I("")],t.prototype,"source",void 0),Un([I("#000000")],t.prototype,"backgroundColor",void 0),Un([I("Top")],t.prototype,"side",void 0),Un([I("")],t.prototype,"borderColor",void 0),Un([I(.5)],t.prototype,"borderWidth",void 0),Un([I(25)],t.prototype,"size",void 0),Un([I("white")],t.prototype,"pathColor",void 0),Un([I(10)],t.prototype,"displacement",void 0),Un([I(!0)],t.prototype,"visible",void 0),Un([I(0)],t.prototype,"offset",void 0),Un([re({},Jn)],t.prototype,"margin",void 0),Un([I("Center")],t.prototype,"horizontalAlignment",void 0),Un([I("Center")],t.prototype,"verticalAlignment",void 0),Un([I(!1)],t.prototype,"disableNodes",void 0),Un([I(!1)],t.prototype,"disableConnectors",void 0),Un([re({},Td)],t.prototype,"tooltip",void 0),Un([I("")],t.prototype,"template",void 0),t}(Ee);function cF(n){return lse[n.toString()]}var lse={Action:"M 90 82.895 C 90 86.819 86.776 90 82.8 90 H 7.2 C 3.224 90 0 86.819 0 82.895 V 7.105 C 0 3.181 3.224 0 7.2 0 h 75.6 C 86.776 0 90 3.181 90 7.105 V 82.895 Z",Decision:"M10,19.707L0.293,10L10,0.293L19.707,10L10,19.707z",MergeNode:"M10,19.707L0.293,10L10,0.293L19.707,10L10,19.707z",InitialNode:"M10,19.5c-5.238,0-9.5-4.262-9.5-9.5S4.762,0.5,10,0.5s9.5,4.262,9.5,9.5S15.238,19.5,10,19.5z",ForkNode:"m0.75,0.75l636.00002,0l0,290l-636.00002,0l0,-290z",JoinNode:"m0.75,0.75l636.00002,0l0,290l-636.00002,0l0,-290z",TimeEvent:"M50.001,0.00286865 L25.001,25.0029 L0.000976562,0.00286865 L50.001,0.00286865 z M0.000976562,50.0029 L25.001,25.0029 L50.001,50.0029 L0.000976562,50.0029 z",AcceptingEvent:"M17.8336 32.164 L29.64 24 L17.32 16 L48.1664 16 L48.5 32 Z",SendSignal:"M48.164 31.8336 L56 23.832 L47.836 16 L16.168 16 L16.1668 31.8336 Z",ReceiveSignal:"M48.1664 31.8336 L39.836 24 L47.836 16 L16.168 16 L16.168 31.836 Z",StructuredNode:"M0,0 L50,0 L50,50 L0,50 z",Note:"M20 12 L4 12 L4 22 L22 22 L22 14 L20 14 L20 12 L22 14 Z"},tb=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Ja=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},hse=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return tb(t,n),Ja([I()],t.prototype,"key",void 0),Ja([I()],t.prototype,"keyModifiers",void 0),t}(Ee),dF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return tb(t,n),t.prototype.getClassName=function(){return"Command"},Ja([I("")],t.prototype,"name",void 0),Ja([I()],t.prototype,"canExecute",void 0),Ja([I()],t.prototype,"execute",void 0),Ja([re({},hse)],t.prototype,"gesture",void 0),Ja([I("")],t.prototype,"parameter",void 0),t}(Ee),cse=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return tb(t,n),Ja([Bt([],dF)],t.prototype,"commands",void 0),t}(Ee),dse=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return tb(t,n),Ja([I()],t.prototype,"show",void 0),Ja([I()],t.prototype,"showCustomMenuOnly",void 0),Ja([I()],t.prototype,"items",void 0),t}(Ee),Kf=function(){function n(){}return n.prototype.renderShadow=function(t,e,i,r){void 0===i&&(i=null);var l,o=R.transform({x:0,y:0},t.shadow.angle,t.shadow.distance);r&&(l=r.getElementById(e.id+"_shadow")),l||(l=document.createElementNS("http://www.w3.org/2000/svg",i?"path":"rect"),e.appendChild(l));var h={id:e.id+"_shadow",fill:t.shadow.color,stroke:t.shadow.color,opacity:t.shadow.opacity.toString(),transform:"rotate("+t.angle+","+(t.x+t.width*t.pivotX)+","+(t.y+t.height*t.pivotY)+")translate("+(t.x+o.x)+","+(t.y+o.y)+")"};if(r){var c=r.getElementById(e.id);c&&c.insertBefore(l,c.firstChild)}ti(l,h),i?i&&this.renderPath(l,t,i):ti(l,{width:t.width,height:t.height})},n.prototype.parseDashArray=function(t){return[]},n.prototype.drawRectangle=function(t,e,i,r,s,o,a,l,h){var c,d,u,f;e.shadow&&!r&&this.renderShadow(e,t,void 0,o),c=e.id===t.id?e.id+"_container":e.id,o&&(d=o.getElementById(c)),(!d||s)&&(d=document.createElementNS("http://www.w3.org/2000/svg","rect"),t.appendChild(d)),o&&!e.shadow&&(u=o.getElementById(e.id+"_groupElement_shadow"))&&u.parentNode.removeChild(u),f=l?{id:c,x:e.x.toString(),y:e.y.toString(),width:e.width.toString(),height:e.height.toString(),visibility:e.visible?"visible":"hidden",transform:"rotate("+e.angle+","+(e.x+e.width/2)+","+(e.y+e.height/2)+")",rx:e.cornerRadius||0,ry:e.cornerRadius||0,opacity:e.opacity}:{id:c,x:e.x.toString(),y:e.y.toString(),width:e.width.toString(),height:e.height.toString(),visibility:e.visible?"visible":"hidden",transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")",rx:e.cornerRadius||0,ry:e.cornerRadius||0,opacity:e.opacity},a&&(f.role="img",f["aria-label"]=a);var p=e.class||"";h||(p.includes("e-diagram-resize-handle")||p.includes("e-diagram-endpoint-handle")||p.includes("e-diagram-bezier-control-handle"))&&(p+=" e-disabled"),e.class&&(f.class=p),a||(f["pointer-events"]="none"),ti(d,f),this.setSvgStyle(d,e,i)},n.prototype.updateSelectionRegion=function(t,e){var i;i=t.parentNode.getElementById(e.id);var r={id:e.id,x:e.x.toString(),y:e.y.toString(),width:e.width.toString(),height:e.height.toString(),transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")",class:"e-diagram-selected-region"};i||(i=document.createElementNS("http://www.w3.org/2000/svg","rect"),t.appendChild(i)),this.setSvgStyle(i,e),ti(i,r)},n.prototype.createGElement=function(t,e){return Fi(t,e)},n.prototype.drawLine=function(t,e){var i=document.createElementNS("http://www.w3.org/2000/svg","line");this.setSvgStyle(i,e);var r=e.x+e.width*e.pivotX,s=e.y+e.height*e.pivotY,o={id:e.id,x1:e.startPoint.x+e.x,y1:e.startPoint.y+e.y,x2:e.endPoint.x+e.x,y2:e.endPoint.y+e.y,stroke:e.stroke,"stroke-width":e.strokeWidth.toString(),opacity:e.opacity.toString(),transform:"rotate("+e.angle+" "+r+" "+s+")",visibility:e.visible?"visible":"hidden"};e.class&&(o.class=e.class),ti(i,o),t.appendChild(i)},n.prototype.drawCircle=function(t,e,i,r){var s=document.createElementNS("http://www.w3.org/2000/svg","circle");this.setSvgStyle(s,e);var o=e.class||"";i||(o+=" e-disabled");var a={id:e.id,cx:e.centerX,cy:e.centerY,r:e.radius,visibility:e.visible?"visible":"hidden",class:o};r&&(a.role="img",a["aria-label"]=r),s.style.display=e.visible?"block":"none",ti(s,a),t.appendChild(s)},n.prototype.drawPath=function(t,e,i,r,s,o,a){var h,c,l=[];l=e3(l=xd(e.data)),e.shadow&&this.renderShadow(e,t,l,s),s&&!e.shadow&&(h=s.getElementById(e.id+"_groupElement_shadow"))&&h.parentNode.removeChild(h),s&&(c=s.getElementById(e.id)),(!c||r)&&(c=document.createElementNS("http://www.w3.org/2000/svg","path"),t.appendChild(c)),this.renderPath(c,e,l);var d={};d=a?{id:e.id,transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")translate("+e.x+","+e.y+"),scale("+a+")",visibility:e.visible?"visible":"hidden",opacity:e.opacity}:{id:e.id,transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")translate("+e.x+","+e.y+")",visibility:e.visible?"visible":"hidden",opacity:e.opacity},o&&(d.role="img",d["aria-label"]=o),e.class&&(d.class=e.class),ti(c,d),this.setSvgStyle(c,e,i)},n.prototype.renderPath=function(t,e,i){var r,s,o,a,l,h,c,d,u=i,f="";for(l=0,h=0,d=0,c=u.length;de.width&&"Wrap"!==e.textOverflow&&"NoWrap"===e.textWrapping&&(h[0].text=qF(e.content,e)),v=0;vD&&(u.text=u.text.slice(0,u.text.length-3),u.text=u.text.concat("..."),l.data=u.text),this.alignText(y,f,u,l,p,g,v,e,h),C+=u.dy}}C&&e.isHorizontalLane&&(M=e.parentOffsetX+e.pivotX,w=e.parentOffsetY+e.pivotY,e.y=e.parentOffsetY-C*e.pivotY+.5),e.textDecoration&&"LineThrough"===e.textDecoration&&(e.textDecoration=gb(e.textDecoration));var P={id:e.id+"_text",fill:e.color,visibility:e.visible?"visible":"hidden","text-decoration":e.textDecoration,transform:"rotate("+e.angle+","+M+","+w+")translate("+e.x+","+e.y+")",opacity:e.opacity};r&&(P.role="img",P["aria-label"]=r),ti(y,P)}},n.prototype.alignText=function(t,e,i,r,s,o,a,l,h){"justify"!==l.textAlign?this.setText(t,e,i,r,s,o,l):a!==h.length-1?this.setText(t,e,i,r,s,o,l,l.width,"spacing"):this.setText(t,e,i,r,s,o,l)},n.prototype.setText=function(t,e,i,r,s,o,a,l,h){ti(e,"justify"!==a.textAlign?{x:s.toString(),y:o.toString()}:{x:s.toString(),y:o.toString(),textLength:l||0,lengthAdjust:h||"spacing"}),t.setAttribute("fill",i.text),e.appendChild(r),t.appendChild(e)},n.prototype.drawImage=function(t,e,i,r){var s;i&&(s=i.getElementById(e.id+"image")),s||(s=document.createElementNS("http://www.w3.org/2000/svg","image"),t.appendChild(s));var o=new Image;o.src=e.source;var a="None"!==e.scale?e.scale:"",l=e.alignment,h=l.charAt(0).toLowerCase()+l.slice(1);"Stretch"!==a&&(h+=" "+a.charAt(0).toLowerCase()+a.slice(1)),ti(s,{id:e.id+"image",x:e.x.toString(),y:e.y.toString(),transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")",width:e.width.toString(),visibility:e.visible?"visible":"hidden",height:e.height.toString(),preserveAspectRatio:h,opacity:e.opacity.toString()}),s.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",o.src.toString())},n.prototype.drawHTMLContent=function(t,e,i,r,s){var o,a;if(e&&(o=e.querySelector("#"+t.id+"_html_element")),!o){(a=e.querySelector("#"+t.id+"_html_element")||e.querySelector("#"+t.nodeId+"_html_element"))||(a=Tt("div",{id:t.nodeId+"_html_element",class:"foreign-object"})),o=Tt("div",{id:t.id+"_html_element",class:"foreign-object"});var c=document.getElementById(t.diagramId).ej2_instances[0],d=!1;if(e.parentNode&&e.parentNode.parentNode&&e.parentNode.parentNode.parentNode&&e.parentNode.parentNode.parentNode.classList.contains("e-overview")&&(d=!0),d)c.isReact?c.renderReactTemplates(function(){o.appendChild(t.template.cloneNode(!0))}):o.appendChild(t.template.cloneNode(!0));else{if("string"==typeof t.template){var u=document.createElement("div");u.innerHTML=t.template,t.template=u,c.selectedItems.userHandles.filter(function(g){return g.name===t.id.split("_shape")[0]&&""!==g.template})[0].template=t.template}t.isTemplate&&t.template?o.appendChild(t.template):t.template&&o.appendChild(t.template.cloneNode(!0))}void 0!==s&&e.childNodes.length>s&&e.insertBefore(o,e.childNodes[parseInt(s.toString(),10)]),a.appendChild(o),e.appendChild(a)}var p=xn(t).topLeft;o.setAttribute("style","height:"+t.actualSize.height+"px; width:"+t.actualSize.width+"px;left:"+p.x+"px; top:"+p.y+"px;position:absolute;transform:rotate("+(t.rotateAngle+t.parentTransform)+"deg);pointer-events:"+(r?"all":"none")+";visibility:"+(t.visible?"visible":"hidden")+";opacity:"+t.style.opacity+";")},n.prototype.drawNativeContent=function(t,e,i,r,s){var o,a;if(s&&(o=s.getElementById(t.id+"_native_element"),a=s.getElementById(t.id+"_clip")),!o){(o=document.createElementNS("http://www.w3.org/2000/svg","g")).setAttribute("id",t.id+"_native_element"),o.appendChild(t.template.cloneNode(!0));var l=this.createGElement("g",{id:t.id+"_inner_native_element"});l.appendChild(o),e.appendChild(l)}a&&o.removeChild(a),o.setAttribute("style","visibility:"+(t.visible?"visible":"hidden")+";opacity:"+t.style.opacity+";"),this.setNativTransform(t,o,i,r),"Slice"===t.scale&&this.drawClipPath(t,o,i,r,s),ti(o,t.description?{role:"img","aria-label":t.description}:{})},n.prototype.setNativTransform=function(t,e,i,r){var s=0!==t.contentSize.width?t.contentSize.width:1,o=0!==t.contentSize.height?t.contentSize.height:1;e.setAttribute("transform","rotate("+t.parentTransform+","+t.offsetX+","+t.offsetY+") translate("+(t.offsetX-t.templatePosition.x*r/s-r*t.pivot.x)+","+(t.offsetY-t.templatePosition.y*i/o-i*t.pivot.y)+") scale("+r/s+","+i/o+")")},n.prototype.drawClipPath=function(t,e,i,r,s){var o=t.contentSize.width,a=t.contentSize.height,l=t.width/(r/o),h=t.height/(i/a),c=t.templatePosition.x+(t.width>=t.height?0:(o-l)/2),d=t.templatePosition.y+(t.height>=t.width?0:(a-h)/2),u=s.getElementById(t.id+"_clip");(u=document.createElementNS("http://www.w3.org/2000/svg","clipPath")).setAttribute("id",t.id+"_clip"),e.appendChild(u);var f=s.getElementById(t.id+"_clip_rect");return f=document.createElementNS("http://www.w3.org/2000/svg","rect"),u.appendChild(f),ti(f,{id:t.id+"_clip_rect",width:l.toString(),height:h.toString(),x:c.toString(),y:d.toString()}),lm()?e.setAttribute("clip-path","url("+location.protocol+"//"+location.host+location.pathname+"#"+t.id+"_clip)"):e.setAttribute("clip-path","url(#"+t.id+"_clip)"),e},n.prototype.renderGradient=function(t,e,i){var r,s,o,h,c,a=IT(i),l=a.getElementById(i+"gradient_pattern");if(l||(l=Fi("defs",{id:i+"gradient_pattern"}),a.insertBefore(l,a.firstChild)),bF(e.id),"None"!==t.gradient.type){for(var d=0;dt.width&&("Ellipsis"===t.textOverflow||"Clip"===t.textOverflow)&&"NoWrap"===t.textWrapping?0:.5*t.width:"right"===t.textAlign&&(c=1*t.width),s.x=0+c+(e?e.x:0),s.y=1.2+d-r.height/2,s},n}(),Pc=function(){function n(t,e,i){this.renderer=null,this.isSvgMode=!0,this.touchMove=void 0,this.transform={x:0,y:0},this.diagramId=t,this.element=xt(this.diagramId),this.svgRenderer=e,this.isSvgMode=i,this.renderer=i?new Kf:new bo}return n.prototype.setCursor=function(t,e){t.style.cursor=e},n.prototype.setLayers=function(){this.iconSvgLayer=this.element.getElementsByClassName("e-ports-expand-layer")[0],this.adornerSvgLayer=this.element.getElementsByClassName("e-adorner-layer")[0],this.nativeSvgLayer=this.element.getElementsByClassName("e-native-layer")[0],this.diagramSvgLayer=this.element.getElementsByClassName("e-diagram-layer")[0]},n.prototype.getAdornerLayer=function(){return yT(this.diagramId)},n.prototype.getParentSvg=function(t,e,i){return this.diagramId&&t&&t.id?t.id.split("_icon_content").length>1||t.id.split("_nodeport").length>1||t.elementActions&Xr.ElementIsPort?this.iconSvgLayer:e&&"selector"===e?this.adornerSvgLayer:t instanceof En?this.nativeSvgLayer:this.diagramSvgLayer:i},n.prototype.getParentElement=function(t,e,i,r){var s=e;if(i&&this.diagramId&&t&&t.id){t.id.split("_icon_content").length>1?(s=i.getElementById(this.diagramId+"_diagramExpander"),e=null):t.id.split("_nodeport").length>1?s=i.getElementById(this.diagramId+"_diagramPorts"):t instanceof En?(s=i.getElementById(this.diagramId+"_nativeLayer"),e=null):t.elementActions&Xr.ElementIsPort?(s=i.getElementById(this.diagramId+"_diagramPorts"),e=null):s=i.getElementById(this.diagramId+"_diagramLayer");var o=this.getGroupElement(t,e||s,r);s=o.g,o.svg&&(i=o.svg)}return{g:s,svg:i}},n.prototype.getGroupElement=function(t,e,i){var r,o,s=this.getParentSvg(t);if(e&&s){if(s&&!(r=s.getElementById(t.id+"_groupElement"))&&s!==this.nativeSvgLayer){var a=this.nativeSvgLayer;r=a.getElementById(t.id+"_groupElement"),o=a}r||(r=this.svgRenderer.createGElement("g",{id:t.id+"_groupElement"}),void 0!==i&&e.childNodes.length>i?e.insertBefore(r,e.childNodes[parseInt(i.toString(),10)]):e.appendChild(r))}return{g:r,svg:o}},n.prototype.renderElement=function(t,e,i,r,s,o,a,l,h,c,d){t instanceof Cs?(t.id=t.id?t.id:Qe(),this.renderContainer(t,e,i,r,s,o,a,l,h,c,d)):t instanceof DI?this.renderImageElement(t,e,r,s,a):t instanceof Ze?this.renderPathElement(t,e,r,s,a,h,d):t instanceof ai?this.renderTextElement(t,e,r,s,a,c):t instanceof En?this.renderNativeElement(t,e,r,s,a):t instanceof es?this.renderHTMLElement(t,e,i,r,s,a,l):this.renderRect(t,e,r,s,h)},n.prototype.drawSelectionRectangle=function(t,e,i,r,s,o){var a={width:i*o.scale,height:r*o.scale,x:.5+(t=(t+o.tx)*o.scale),y:.5+(e=(e+o.ty)*o.scale),fill:"transparent",stroke:"gray",angle:0,pivotX:.5,pivotY:.5,strokeWidth:1,dashArray:"6 3",opacity:1,visible:!0,id:s.id+"_selected_region"},l=this.getAdornerLayer();this.svgRenderer.updateSelectionRegion(l,a)},n.prototype.renderHighlighter=function(t,e,i){var r=t.actualSize.width||2,s=t.actualSize.height||2,o=t.offsetX-r*t.pivot.x,a=t.offsetY-s*t.pivot.y;this.svgRenderer.drawRectangle(e,{width:r*i.scale,height:s*i.scale,x:o=(o+i.tx)*i.scale,y:a=(a+i.ty)*i.scale,fill:"transparent",stroke:"#8CC63F",angle:t.rotateAngle,pivotX:t.pivot.x,pivotY:t.pivot.y,strokeWidth:4,dashArray:"",opacity:1,cornerRadius:0,visible:!0,id:e.id+"_highlighter",class:"e-diagram-highlighter"},this.diagramId,void 0,void 0,e)},n.prototype.renderSelectionRectangle=function(t,e,i,r){var s=t.actualSize.width||2,o=t.actualSize.height||2,a=t.offsetX-s*t.pivot.x,l=t.offsetY-o*t.pivot.y,h={width:s*i.scale,height:o*i.scale,x:a=(a+i.tx)*i.scale,y:l=(l+i.ty)*i.scale,fill:"transparent",stroke:"#00cc00",angle:t.rotateAngle,pivotX:t.pivot.x,pivotY:t.pivot.y,strokeWidth:r?2:1,dashArray:"",opacity:1,cornerRadius:0,visible:!0,id:t.id+"_highlighter",class:r?"e-diagram-first-selection-indicator e-diagram-selection-indicator":"e-diagram-selection-indicator"},c=this.getParentSvg(t,"selector");this.svgRenderer.drawRectangle(e,h,this.diagramId,void 0,void 0,c)},n.prototype.renderSelectionLine=function(t,e,i,r){var s=this.getBaseAttributes(t,i);s.data=t.absolutePath,s.id=s.id+"_highlighter";var o=t.description?t.description:t.id;this.isSvgMode||(s.x=t.flipOffset.x?t.flipOffset.x:s.x,s.y=t.flipOffset.y?t.flipOffset.y:s.y),i&&(s.x=s.x*i.scale,s.y=s.y*i.scale),s.stroke="#00cc00",s.strokeWidth=r?2:1,s.class=r?"e-diagram-first-selection-indicator e-diagram-selection-indicator":"e-diagram-selection-indicator";var a=this.getParentSvg(t,"selector");this.svgRenderer.drawPath(e,s,this.diagramId,void 0,a,o,i.scale)},n.prototype.renderStackHighlighter=function(t,e,i,r,s,o,a){var l=t.actualSize.width||2,h=t.offsetX-l*t.pivot.x,c=t.actualSize.height||2,d=t.offsetY-c*t.pivot.y;h=(h+i.tx)*i.scale;var u,f=t.bounds,p="";if(d=(d+i.ty)*i.scale,r)if(o){var v,y;u="M 0 0 L "+(2+(g=l*i.scale))+" 0 Z",v=t.actualSize.width/Number(f.width?f.width:1)*i.scale,y=t.actualSize.height/Number(f.height?f.height:1)*i.scale,p=bI(MI(xd("M7,4 L8,4 8,7 11,7 11,8 8,8 8,11 7,11 7,8 4,8 4,7 7,7 z M7.5,0.99999994C3.9160004,1 1,3.9160004 0.99999994,7.5 1,11.084 3.9160004,14 7.5,14 11.084,14 14,11.084 14,7.5 14,3.9160004 11.084,1 7.5,0.99999994 z M7.5,0 C11.636002,0 15,3.3639984 15,7.5 15,11.636002 11.636002,15 7.5,15 3.3640003,15 0,11.636002 0,7.5 0,3.3639984 3.3640003,0 7.5,0 z")),v+g+2,y-8,!1,f.x,f.y,0,0),s.y>=t.offsetY&&(d+=c)}else{var g;a&&s.y>=t.offsetY&&(d+=c*i.scale),u="M -10 -10 L 0 0 Z M -10 10 L 0 0 Z M 0 0 L "+(g=l*i.scale)+" 0 Z M "+g+" 0 L "+(g+10)+" 10 Z L "+(g+10)+" -10 Z"}else u="M 10 -10 L 0 0 Z M -10 -10 L 0 0 Z M 0 0 L 0 "+(g=c*i.scale)+" Z M 0 "+g+" L -10 "+(g+10)+" Z L 10 "+(g+10)+" Z",s.x>=t.offsetX&&(h+=l*i.scale);this.svgRenderer.drawPath(e,{data:u+p,width:l*i.scale,height:c*i.scale,x:h,y:d,fill:"transparent",stroke:"#8CC63F",angle:t.rotateAngle,pivotX:t.pivot.x,pivotY:t.pivot.y,strokeWidth:1,dashArray:"",opacity:1,visible:!0,id:e.id+"_stack_highlighter",class:"e-diagram-highlighter"},this.diagramId)},n.prototype.drawLine=function(t,e){this.svgRenderer.drawLine(t,e)},n.prototype.drawPath=function(t,e){this.svgRenderer.drawPath(t,e,this.diagramId)},n.prototype.renderResizeHandle=function(t,e,i,r,s,o,a,l,h,c,d){var u=t.offsetX-t.actualSize.width*t.pivot.x,f=t.offsetY-t.actualSize.height*t.pivot.y,p=t.actualSize.height,g=t.actualSize.width;if(!c&&i&bt.Rotate&&jI(this.rendererActions)&&!z3(this.rendererActions))this.renderPivotLine(t,e,o,s,a),this.renderRotateThumb(t,e,o,s,a);else if(this.touchMove){var v=document.getElementById("rotateThumb");v&&v.setAttribute("visibility","hidden")}this.renderBorder(t,e,o,l,h,c);var y=t.actualSize.width*r,S=t.actualSize.height*r;!h&&jI(this.rendererActions)&&!z3(this.rendererActions)&&(t.isTextAnnotation||(y>=40&&S>=40&&(s&mr.ResizeNorthWest&&this.renderCircularHandle("resizeNorthWest",t,u,f,e,qr(s,"ResizeNorthWest"),i&bt.ResizeNorthWest,o,void 0,a,{"aria-label":"Thumb to resize the selected object on top left side direction"},void 0,"e-diagram-resize-handle e-northwest",d),s&mr.ResizeNorthEast&&this.renderCircularHandle("resizeNorthEast",t,u+g,f,e,qr(s,"ResizeNorthEast"),i&bt.ResizeNorthEast,o,void 0,a,{"aria-label":"Thumb to resize the selected object on top right side direction"},void 0,"e-diagram-resize-handle e-northeast",d),s&mr.ResizeSouthWest&&this.renderCircularHandle("resizeSouthWest",t,u,f+p,e,qr(s,"ResizeSouthWest"),i&bt.ResizeSouthWest,o,void 0,a,{"aria-label":"Thumb to resize the selected object on bottom left side direction"},void 0,"e-diagram-resize-handle e-southwest",d),s&mr.ResizeSouthEast&&this.renderCircularHandle("resizeSouthEast",t,u+g,f+p,e,qr(s,"ResizeSouthEast"),i&bt.ResizeSouthEast,o,void 0,a,{"aria-label":"Thumb to resize the selected object on bottom right side direction"},void 0,"e-diagram-resize-handle e-southeast",d)),s&mr.ResizeNorth&&this.renderCircularHandle("resizeNorth",t,u+g/2,f,e,qr(s,"ResizeNorth"),i&bt.ResizeNorth,o,void 0,a,{"aria-label":"Thumb to resize the selected object on top side direction"},void 0,"e-diagram-resize-handle e-north",d),s&mr.ResizeSouth&&this.renderCircularHandle("resizeSouth",t,u+g/2,f+p,e,qr(s,"ResizeSouth"),i&bt.ResizeSouth,o,void 0,a,{"aria-label":"Thumb to resize the selected object on bottom side direction"},void 0,"e-diagram-resize-handle e-south",d),s&mr.ResizeWest&&this.renderCircularHandle("resizeWest",t,u,f+p/2,e,qr(s,"ResizeWest"),i&bt.ResizeWest,o,void 0,a,{"aria-label":"Thumb to resize the selected object on left side direction"},void 0,"e-diagram-resize-handle e-west",d),s&mr.ResizeEast&&this.renderCircularHandle("resizeEast",t,u+g,f+p/2,e,qr(s,"ResizeEast"),i&bt.ResizeEast,o,void 0,a,{"aria-label":"Thumb to resize the selected object on right side direction"},void 0,"e-diagram-resize-handle e-east",d)))},n.prototype.renderEndPointHandle=function(t,e,i,r,s,o,a,l,h,c){var p,g,d=t.sourcePoint,u=t.targetPoint,f=t.wrapper;if(this.renderCircularHandle("connectorSourceThumb",f,d.x,d.y,e,qr(r,"ConnectorSourceThumb"),i&bt.ConnectorSource,s,o,void 0,{"aria-label":"Thumb to move the source point of the connector"},void 0,"e-diagram-endpoint-handle e-sourceend",c),this.renderCircularHandle("connectorTargetThumb",f,u.x,u.y,e,qr(r,"ConnectorTargetThumb"),i&bt.ConnectorTarget,s,a,void 0,{"aria-label":"Thumb to move the target point of the connector"},void 0,"e-diagram-endpoint-handle e-targetend",c),l)if("Straight"===t.type&&t.segments.length>0)for(p=0;p0)for(p=0;p=3&&3===t.segments.length&&(S=1,b=t.segments.length-1),S=t.segments.length>t.maxSegmentThumb+2?2:S,b=t.segments.length>t.maxSegmentThumb+2?t.segments.length-2:b,1===t.segments.length&&t.segments[0].points.length<=2&&(S=1,b=t.segments.length),p=S;p=50&&i.allowDrag),this.renderOrthogonalThumb(t+"_"+(d+1),e,(i.points[parseInt(d.toString(),10)].x+i.points[d+1].x)/2,(i.points[parseInt(d.toString(),10)].y+i.points[d+1].y)/2,r,h,l,o,a,u)}else for(d=0;d=50&&i.allowDrag),this.renderOrthogonalThumb(t+"_"+(d+1),e,(i.points[parseInt(d.toString(),10)].x+i.points[d+1].x)/2,(i.points[parseInt(d.toString(),10)].y+i.points[d+1].y)/2,r,h,l,o,a,u)},n.prototype.renderOrthogonalThumb=function(t,e,i,r,s,o,a,l,h,c){var d,g,u=0,f=document.getElementById(this.diagramId);f&&(g=f.ej2_instances[0]);var y=h.constraints&qe.InheritSegmentThumbShape?g.segmentThumbShape:h.segmentThumbShape,b=h.constraints&qe.InheritSegmentThumbSize?g.segmentThumbSize:h.segmentThumbSize;if(d="horizontal"===a?function ure(n){return vre[""+n]}(y):c3(y),"Arrow"===y||"DoubleArrow"===y||"OpenArrow"===y)switch(c){case"Bottom":case"Right":u=180;break;default:u=0}else if("Fletch"===y||"OpenFetch"===y||"IndentedArrow"===y||"OutdentedArrow"===y)switch(c){case"Bottom":u=-90;break;case"Top":u=90;break;case"Right":u=180;break;default:u=0}var M={x:(i+l.tx)*l.scale-b/2,y:(r+l.ty)*l.scale-b/2,angle:u,fill:"#e2e2e2",stroke:"black",strokeWidth:1,dashArray:"",data:d,width:b,height:b,pivotX:.5,pivotY:.5,opacity:1,visible:o,id:t,class:"e-diagram-ortho-segment-handle"},w=ap(M.data),C=new me(M.width,M.height),D=new Ze;if(M.data=D.updatePath(M.data,w,C),this.touchMove){var A=document.getElementById(t);A?this.updateSegmentPosition(A,M):this.svgRenderer.drawPath(s,M,this.diagramId)}else this.svgRenderer.drawPath(s,M,this.diagramId)},n.prototype.renderPivotLine=function(t,e,i,r,s){var o=t,l=!!(r&mr.Rotate);s&&(l=!1);var h=this.getBaseAttributes(o,i);h.fill="None",h.stroke="black",h.strokeWidth=1,h.dashArray="2,3",h.visible=l;var c=i.scale;h.x*=c,h.y*=c,h.width*=c,h.height*=c,h.id="pivotLine",h.class="e-diagram-pivot-line";var u={x:o.actualSize.width*o.pivot.x*c,y:0};h.startPoint={x:o.actualSize.width*o.pivot.x*c,y:-20},h.endPoint=u,this.svgRenderer.drawLine(e,h)},n.prototype.renderBezierLine=function(t,e,i,r,s,o){var l=this.getBaseAttributes(e,o);l.id=t,l.stroke="black",l.strokeWidth=1,l.dashArray="3,3",l.fill="None",l.class="e-diagram-bezier-control-line",l.x=0,l.y=0;var h=o.scale,g={x:(s.x+o.tx)*h,y:(s.y+o.ty)*h};l.startPoint={x:(r.x+o.tx)*h,y:(r.y+o.ty)*h},l.endPoint=g,this.svgRenderer.drawLine(i,l)},n.prototype.renderCircularHandle=function(t,e,i,r,s,o,a,l,h,c,d,u,f,p){var g=e,v={x:i,y:r};if(0!==g.rotateAngle||0!==g.parentTransform){var y=Bi();qi(y,g.rotateAngle+g.parentTransform,g.offsetX,g.offsetY),v=Ke(y,v)}var S=this.getBaseAttributes(g);if(S.stroke="black",S.strokeWidth=1,void 0!==u?(S.id="segmentEnd_"+u,S.fill="#e2e2e2"):S.fill=h?"#8CC63F":"white",S.cornerRadius=p/2,S.angle=e.rotateAngle,S.id=t,S.visible=o,S.class=f,S.width=p,S.height=p,S.x=(v.x+l.tx)*l.scale,S.y=(v.y+l.ty)*l.scale,S.x=S.x-S.width/2,S.y=S.y-S.height/2,h&&(S.class+=" e-connected"),c&&(S.visible=!1),this.touchMove){var b=document.getElementById(t);if(b)this.updateResizeHandle(b,S);else{var M=this.getParentSvg(e,"selector");this.svgRenderer.drawRectangle(s,S,this.diagramId,!0,!0,M,d,!0,a)}}else M=this.getParentSvg(e,"selector"),this.svgRenderer.drawRectangle(s,S,this.diagramId,!0,!0,M,d,!0,a)},n.prototype.updateResizeHandle=function(t,e){ti(t,{id:e.id,x:e.x.toString(),y:e.y.toString(),width:e.width.toString(),height:e.height.toString(),visibility:e.visible?"visible":"hidden",transform:"rotate("+e.angle+","+(e.x+e.width/2)+","+(e.y+e.height/2)+")",rx:e.cornerRadius||0,ry:e.cornerRadius||0,opacity:e.opacity})},n.prototype.renderBezierHandle=function(t,e,i,r,s,o,a,l,h,c,d,u,f){var v,p=document.getElementById(this.diagramId);p&&(v=p.ej2_instances[0]);var y=e,S={x:i,y:r};if(0!==y.rotateAngle||0!==y.parentTransform){var b=Bi();qi(b,y.rotateAngle+y.parentTransform,y.offsetX,y.offsetY),S=Ke(b,S)}var D=a.constraints&qe.InheritSegmentThumbSize?v.segmentThumbSize:a.segmentThumbSize,A=c3(a.constraints&qe.InheritSegmentThumbShape?v.segmentThumbShape:a.segmentThumbShape),x=this.getBaseAttributes(y);x.stroke="black",x.strokeWidth=1,void 0!==d?(x.id="segmentEnd_"+d,x.fill="#e2e2e2"):x.fill=h?"#8CC63F":"white",x.angle=e.rotateAngle,x.id=t,x.visible=o,x.class=u,x.width=D,x.height=D,x.data=A,x.x=(S.x+l.tx)*l.scale,x.y=(S.y+l.ty)*l.scale,x.x=x.x-x.width/2,x.y=x.y-x.height/2,h&&(x.class+=" e-connected"),c&&(x.visible=!1);var P=ap(x.data),L=new me(x.width,x.height),O=new Ze;if(x.data=O.updatePath(x.data,P,L),this.touchMove){var N=document.getElementById(t);if(N)this.updateSegmentPosition(N,x);else{var T=this.getParentSvg(e,"selector");this.svgRenderer.drawPath(s,x,this.diagramId,!0,T)}}else T=this.getParentSvg(e,"selector"),this.svgRenderer.drawPath(s,x,this.diagramId,!0,T)},n.prototype.updateSegmentPosition=function(t,e){ti(t,{id:e.id,transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")translate("+e.x+","+e.y+")",visibility:e.visible?"visible":"hidden",opacity:e.opacity})},n.prototype.renderBorder=function(t,e,i,r,s,o){var l=this.getBaseAttributes(t,i);l.x*=i.scale,l.y*=i.scale,l.width*=i.scale,l.height*=i.scale,l.fill="transparent",l.stroke="#097F7F",l.strokeWidth=1.2,l.gradient=null,l.dashArray="6,3",l.class="e-diagram-selector",o&&(l.class+=" e-diagram-lane"),l.id="borderRect",l.id=this.rendererActions&Ga.DrawSelectorBorder?"borderRect_symbol":"borderRect",r||(l.class+=" e-disabled"),s&&(l.class+=" e-thick-border"),l.cornerRadius=0;var h=this.getParentSvg(t,"selector");this.svgRenderer.drawRectangle(e,l,this.diagramId,void 0,!0,h)},n.prototype.renderUserHandler=function(t,e,i,r,s,o){for(var l,a=t.wrapper,h=0,c=t.userHandles;h0||d.disableNodes&&t.nodes.length>0||"Drag"===s&&o)&&(l=!1);var u=document.getElementById(d.name+"_template_hiddenUserHandle");u&&(d.template=u.childNodes[0].cloneNode(!0));var f=iT(t,d,i);if(f.x=(f.x+i.tx)*i.scale,f.y=(f.y+i.ty)*i.scale,d.visible&&(d.visible=!!(t.constraints&mr.UserHandle)),l)if(d.pathData){var p=d.pathData?d.pathData:d.content,g=this.getBaseAttributes(a);g.id=d.name+"_userhandle",g.fill=d.backgroundColor,g.stroke=d.borderColor,g.strokeWidth=d.borderWidth,g.centerX=f.x,g.centerY=f.y,g.radius=.5*d.size,g.class="e-diagram-userhandle-circle",g.angle=0,g.visible=d.visible,g.opacity=1,this.svgRenderer.drawCircle(e,g,1,{"aria-label":d.name+"user handle"});var y=[];y=MI(y=xd(p));var S=ap(p),w=bI(y,(d.size-.45*d.size)/S.width,(d.size-.45*d.size)/S.height,!0,S.x,S.y,0,0);S=ap(w),this.svgRenderer.drawPath(e,C={x:f.x-S.width/2,y:f.y-S.height/2,angle:0,id:"",class:"e-diagram-userhandle-path",fill:d.pathColor,stroke:d.backgroundColor,strokeWidth:.5,dashArray:"",data:w,width:d.size-5,height:d.size-5,pivotX:0,pivotY:0,opacity:1,visible:d.visible},this.diagramId,void 0,void 0,{"aria-label":d.name+"user handle"})}else if(d.content){var D=new En(d.name,this.diagramId);D.content=d.content,D.offsetX=f.x,D.offsetY=f.y,D.id=d.name+"_shape",D.horizontalAlignment="Center",D.verticalAlignment="Center",D.visible=d.visible,D.setOffsetWithRespectToBounds(f.x,f.y,"Fraction"),D.relativeMode="Object",D.description=d.name||"User handle",D.measure(new me(d.size,d.size)),D.arrange(D.desiredSize),this.svgRenderer.drawNativeContent(D,e,d.size,d.size,this.adornerSvgLayer)}else if(d.source){var C,A=new DI;(C=this.getBaseAttributes(A,i)).width=d.size,C.height=d.size,C.x=f.x-d.size/2,C.y=f.y-d.size/2,C.sourceWidth=d.size,C.sourceHeight=d.size,C.alignment=A.imageAlign,C.source=d.source,C.scale=A.imageScale,C.visible=d.visible,C.description=d.name||"User handle",C.id=d.name+"_",this.renderer.drawImage(e,C,this.adornerSvgLayer,!1)}else{var x=new es(d.name,this.diagramId);x.offsetX=f.x,x.offsetY=f.y,x.id=d.name+"_shape",x.visible=d.visible,x.relativeMode="Object",x.template=d.template,x.measure(new me(d.size,d.size)),x.arrange(x.desiredSize),this.svgRenderer.drawHTMLContent(x,r,void 0,!0,void 0)}}},n.prototype.renderRotateThumb=function(t,e,i,r,s){new Ze;var a,l=new me;l.width=18,l.height=16;var d=!!(r&mr.Rotate);s&&(d=!1);var f=t.offsetX-t.actualSize.width*t.pivot.x+t.pivot.x*t.actualSize.width,p=t.offsetY-t.actualSize.height*t.pivot.y;if(a={x:(f=(f+i.tx)*i.scale)-.5*l.width,y:(p=(p+i.ty)*i.scale)-30-.5*l.height},0!==t.rotateAngle||0!==t.parentTransform){var g=Bi();qi(g,t.rotateAngle+t.parentTransform,(i.tx+t.offsetX)*i.scale,(i.ty+t.offsetY)*i.scale),a=Ke(g,a)}var v={x:a.x,y:a.y,angle:t.rotateAngle+t.parentTransform,fill:"#231f20",stroke:"black",strokeWidth:.5,dashArray:"",data:"M 16.856144362449648 10.238890446662904 L 18.000144362449646 3.437890446662903L 15.811144362449646 4.254890446662903 C 14.837144362449646 2.5608904466629028 13.329144362449647 1.2598904466629026 11.485144362449645 0.5588904466629026 C 9.375144362449646 - 0.24510955333709716 7.071144362449646 - 0.18010955333709716 5.010144362449646 0.7438904466629028 C 2.942144362449646 1.6678904466629028 1.365144362449646 3.341890446662903 0.558144362449646 5.452890446662903 C - 0.244855637550354 7.567890446662903 - 0.17985563755035394 9.866890446662904 0.7431443624496461 11.930890446662904 C 1.6681443624496461 13.994890446662904 3.343144362449646 15.575890446662903 5.457144362449647 16.380890446662903 C 6.426144362449647 16.7518904466629 7.450144362449647 16.9348904466629 8.470144362449647 16.9348904466629 C 9.815144362449647 16.9348904466629 11.155144362449647 16.6178904466629 12.367144362449647 15.986890446662901 L 11.351144362449647 14.024890446662901 C 9.767144362449647 14.8468904466629 7.906144362449647 14.953890446662902 6.237144362449647 14.3178904466629 C 4.677144362449647 13.7218904466629 3.444144362449647 12.5558904466629 2.758144362449647 11.028890446662901 C 2.078144362449646 9.501890446662903 2.031144362449646 7.802890446662903 2.622144362449646 6.243890446662903 C 3.216144362449646 4.6798904466629025 4.387144362449646 3.442890446662903 5.914144362449646 2.760890446662903 C 7.437144362449646 2.078890446662903 9.137144362449646 2.0298904466629026 10.700144362449645 2.6258904466629027 C 11.946144362449646 3.100890446662903 12.971144362449646 3.9538904466629026 13.686144362449646 5.049890446662903 L 11.540144362449645 5.850890446662903 L 16.856144362449648 10.238890446662904 Z",width:20,height:20,pivotX:0,pivotY:0,opacity:1,visible:d,id:"rotateThumb",class:"e-diagram-rotate-handle"};if(this.touchMove){var y=document.getElementById("rotateThumb");y?this.updateSegmentPosition(y,v):this.svgRenderer.drawPath(e,v,this.diagramId,!0,void 0,{"aria-label":"Thumb to rotate the selected object"})}else this.svgRenderer.drawPath(e,v,this.diagramId,!0,void 0,{"aria-label":"Thumb to rotate the selected object"})},n.prototype.renderPathElement=function(t,e,i,r,s,o,a){var l=this.getBaseAttributes(t,i,o);if(l.data=t.absolutePath,l.data=t.absolutePath,t.isPathPort&&a){l.x=a[t.id]?a[t.id].cx:l.x,l.y=a[t.id]?a[t.id].cy:l.y,t.bounds.x=l.x,t.bounds.y=l.y;var h=document.getElementById(this.diagramId);h&&"PortDrag"!==h.ej2_instances[0].eventHandler.currentAction&&(t.offsetX=l.x+t.width/2,t.offsetY=l.y+t.height/2)}var u=t.description?t.description:t.id;if(this.isSvgMode||(l.x=t.flipOffset.x?t.flipOffset.x:l.x,l.y=t.flipOffset.y?t.flipOffset.y:l.y),t.isExport){var f=t.absoluteBounds,p=xd(l.data),g=this.findAndStoreArcValues(p);l.arc=g,l.data=BF(t,f,0,l)}this.renderer.drawPath(e,l,this.diagramId,void 0,r,u)},n.prototype.findAndStoreArcValues=function(t){var e=[];return t.forEach(function(i){"A"===i.command&&e.push({r1:i.r1/2,r2:i.r2/2})}),e},n.prototype.renderSvgGridlines=function(t,e,i,r,s,o){var a=document.createElementNS("http://www.w3.org/2000/svg","pattern"),l=document.createElementNS("http://www.w3.org/2000/svg","defs");l.setAttribute("id",this.diagramId+"_grid_pattern_defn"),(t.constraints&Kt.ShowHorizontalLines||t.constraints&Kt.ShowVerticalLines)&&a.setAttribute("id",this.diagramId+"_pattern");var h=0,c=0,d=0,u=0,f=1,p=!1,g="Lines"===t.gridType,v=g?t.verticalGridlines.lineIntervals:t.verticalGridlines.dotIntervals,y=g?t.horizontalGridlines.lineIntervals:t.horizontalGridlines.dotIntervals;if(r.showRulers&&r.dynamicGrid&&s&&o)d=o.updateSegmentWidth(i.scale),u=s.updateSegmentWidth(i.scale),t.horizontalGridlines.scaledIntervals=[d/s.interval],t.verticalGridlines.scaledIntervals=[u/o.interval],p=!0;else{for(var S=0;S=2)for(;e>=2;)e/=2;else if(e<=.5)for(;e<=.5;)e*=2;var i;if(t.horizontalGridlines.scaledIntervals=t.horizontalGridlines.snapIntervals,t.verticalGridlines.scaledIntervals=t.verticalGridlines.snapIntervals,1!==e){var r=t.horizontalGridlines;for(r.scaledIntervals=[],i=0;ithis.groupElement.actualSize.height&&("Clip"===t.style.textOverflow||"Ellipsis"===t.style.textOverflow)&&(a.y=a.y+(a.height-this.groupElement.actualSize.height)/2),this.renderer.drawRectangle(e,a,this.diagramId,void 0,void 0,r),this.renderer.drawText(e,a,r,l,this.diagramId,t.isExport&&Math.min(t.exportScaleValue.x||t.exportScaleValue.y),this.groupElement),this.isSvgMode&&(t.doWrap=!1)},n.prototype.renderNativeElement=function(t,e,i,r,s){var o,a,l=this.getParentSvg(t,void 0,e)||r,h=this.getParentElement(t,e,l).g||e,c=this.getBaseAttributes(t,i);switch(c.fill="transparent",c.cornerRadius=t.cornerRadius,c.stroke="transparent",this.renderer.drawRectangle(e,c,this.diagramId,void 0,void 0,r),t.scale){case"None":o=t.contentSize.width,a=t.contentSize.height;break;case"Stretch":o=t.actualSize.width,a=t.actualSize.height;break;case"Meet":o=a=t.actualSize.width<=t.actualSize.height?t.actualSize.width:t.actualSize.height;break;case"Slice":o=a=t.actualSize.width>=t.actualSize.height?t.actualSize.width:t.actualSize.height}this.svgRenderer&&this.svgRenderer.drawNativeContent(t,h,a,o,l)},n.prototype.renderHTMLElement=function(t,e,i,r,s,o,a){var l=this.getBaseAttributes(t,r);l.fill="transparent",l.cornerRadius=t.cornerRadius,l.stroke="transparent",this.renderer.drawRectangle(e,l,this.diagramId,void 0,void 0,s),this.svgRenderer&&this.svgRenderer.drawHTMLContent(t,i.children[0],r,function Sse(n){var t=n.parentElement;do{if(gm(t,"e-diagram"))return!0;t=t.parentElement}while(t);return!1}(i),a)},n.prototype.renderImageElement=function(t,e,i,r,s){var o=this.getBaseAttributes(t,i);o.cornerRadius=0,this.renderer.drawRectangle(e,o,this.diagramId,void 0,void 0,r);var a,l,h,c,g,d=t.contentSize.width,u=t.contentSize.height,f=o.width/d,p=o.height/u;if("Stretch"===t.stretch)a=d*(g=Math.min(f,p)),l=u*g;else switch(t.stretch){case"Meet":a=d*(g=Math.min(f,p)),l=u*g,o.x+=Math.abs(o.width-a)/2,o.y+=Math.abs(o.height-l)/2;break;case"Slice":g=Math.max(f,p),h=o.width/(a=d*g)*d,c=o.height/(l=u*g)*u;break;case"None":a=d,l=u}o.width=a,o.height=l,o.sourceWidth=h,o.sourceHeight=c,o.source=t.source,o.alignment=t.imageAlign,o.scale=t.imageScale,o.description=t.description?t.description:t.id,this.renderer.drawImage(e,o,r,s)},n.prototype.renderContainer=function(t,e,i,r,s,o,a,l,h,c,d){var g,u={svg:s,g:e},f=document.getElementById(this.diagramId);if(f&&(g=f.ej2_instances[0]),this.diagramId&&(s=this.getParentSvg(t)||s,this.isSvgMode)){var v=this.getParentElement(t,e,s,l).g||e;s=this.getParentSvg(this.hasNativeParent(t.children))||s;var y=this.getParentElement(this.hasNativeParent(t.children),v,s,l);u.svg=y.svg||s,u.g=y.g||v,o&&s&&(s.getElementById(u.g.id)||e.appendChild(u.g)),e=u.g}if(this.renderRect(t,e,r,s),this.groupElement=t,t.hasChildren()){for(var b,S=void 0,M=0,w=t.children;M0&&(D=g.selectedItems.nodes[0]);var L,A=void 0,x=void 0,P=!1;if(g&&g.selectedItems&&(L=g.getObject(t.id)),"None"!==t.flip&&(D=L),"None"===t.flip&&(D=L),D&&D.flipMode&&(P=!0),!(t.elementActions&Xr.ElementIsGroup)&&g instanceof _l&&g.nameTable[t.id]&&"connectors"!==g.nameTable[t.id].propName&&P&&D){if(A=t.children&&t.children[0]instanceof En?document.getElementById(D.id+"_content_inner_native_element"):document.getElementById(D.id+"_content_groupElement"),!(t.children[0]instanceof En)&&"Text"!==D.shape.type&&"None"!==D.flipMode&&"Label"!==D.flipMode&&"All"!==D.flipMode&&"PortAndLabel"!==D.flipMode&&"LabelText"!==D.flipMode&&"PortAndLabelText"!==D.flipMode&&"LabelAndLabelText"!==D.flipMode||t.children[0]instanceof En&&"Port"===D.flipMode)return void this.renderFlipElement(t,A,D.flip);if((t.children[0]instanceof En&&("All"===D.flipMode||"Label"===D.flipMode)||"Label"===D.flipMode||"PortAndLabel"===D.flipMode||"LabelText"===D.flipMode||"PortAndLabelText"===D.flipMode||"LabelAndLabelText"===D.flipMode||"Image"===D.shape.type&&"Label"===D.flipMode)&&this.renderFlipElement(t,A,t.flip),"None"!==t.flip&&"None"===D.flipMode)this.renderFlipElement(t,A,t.flip);else if("None"!==t.flip&&("Label"===D.flipMode||"PortAndLabel"===D.flipMode||"LabelText"===D.flipMode||"PortAndLabelText"===D.flipMode||"LabelAndLabelText"===D.flipMode)||t.children[0]instanceof En&&"None"!==t.flip&&D&&("None"===D.flipMode||"All"===D.flipMode)){for(var O=0;O0){var i=t[0];if(i instanceof En)return i;i.children&&i.children.length&&this.hasNativeParent(i.children,e++||0)}},n.prototype.renderRect=function(t,e,i,r,s){var o=this.getBaseAttributes(t,i,s);o.cornerRadius=t.cornerRadius||0,t.isExport&&(o.cornerRadius*=t.exportScaleValue.x),this.renderer.drawRectangle(e,o,this.diagramId,t.isExport,void 0,r,t.description?t.description:t.id)},n.prototype.drawRect=function(t,e){e.cornerRadius=0,this.svgRenderer.drawRectangle(t,e,this.diagramId)},n.prototype.getBaseAttributes=function(t,e,i){var r={width:t.actualSize.width,height:t.actualSize.height,x:t.offsetX-t.actualSize.width*t.pivot.x,y:t.offsetY-t.actualSize.height*t.pivot.y,fill:t.style.fill,stroke:t.style.strokeColor,angle:t.rotateAngle+t.parentTransform,pivotX:t.pivot.x,pivotY:t.pivot.y,strokeWidth:t.style.strokeWidth,dashArray:t.style.strokeDashArray||"",opacity:t.style.opacity,shadow:t.shadow,gradient:t.style.gradient,visible:t.visible,id:t.id,description:t.description,canApplyStyle:t.canApplyStyle,shapeType:t.shapeType};return"Page"===t.rotationReference&&(r.angle=t.rotateAngle),i&&(r.x=r.x-.5,r.y=r.y-.5),t.isExport&&(r.width*=t.exportScaleValue.x,r.height*=t.exportScaleValue.y,r.x*=t.exportScaleValue.x,r.y*=t.exportScaleValue.y,r.strokeWidth*=t.exportScaleValue.x),t.flip&&(r.flip=t.flip),e&&(r.x+=e.tx,r.y+=e.ty),r},n.renderSvgBackGroundImage=function(t,e,i,r,s,o){if(t.source){var l=IT(e.id).getElementById(e.id+"_image");if(!l){var h=function Toe(n){return xt(n).getElementsByClassName("e-background-image-layer")[0]}(e.id);(l=document.createElementNS("http://www.w3.org/2000/svg","image")).setAttribute("id",e.id+"_image"),h.appendChild(l)}var c=new Image;c.src=t.source,l.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",c.src.toString());var d="None"!==t.scale?t.scale:"",u=t.align,f=u.charAt(0).toLowerCase()+u.slice(1);d&&(f+=" "+d.charAt(0).toLowerCase()+d.slice(1)),ti(l,{id:e.id+"_image",x:i,y:r,width:s,height:o,preserveAspectRatio:f})}},n.prototype.transformLayers=function(t,e){var i=t.tx*t.scale,r=t.ty*t.scale,s="domTable";if(i!==this.transform.x||r!==this.transform.y||0===i||0===r){e&&(window[""+s][this.diagramId+"_diagramLayer"]||(window[""+s][this.diagramId+"_diagramLayer"]=this.diagramSvgLayer.getElementById(this.diagramId+"_diagramLayer")),window[""+s][this.diagramId+"_diagramLayer"].setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+"),scale("+t.scale+")"));var a=function Aoe(n){var t="domTable",e=null;return window[t][n+"_gridline"]?e=window[t][n+"_gridline"]:(e=Ud(n).getElementById(n+"_gridline"),window[t][n+"_gridline"]=e),e}(this.diagramId);return a.setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+")"),window[""+s][this.diagramId+"_diagramPorts"]||(window[""+s][this.diagramId+"_diagramPorts"]=this.iconSvgLayer.getElementById(this.diagramId+"_diagramPorts")),window[""+s][this.diagramId+"_diagramPorts"].setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+"),scale("+t.scale+")"),window[""+s][this.diagramId+"_diagramExpander"]||(window[""+s][this.diagramId+"_diagramExpander"]=this.iconSvgLayer.getElementById(this.diagramId+"_diagramExpander")),window[""+s][this.diagramId+"_diagramExpander"].setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+"),scale("+t.scale+")"),window[""+s][this.diagramId+"_nativeLayer"]||(window[""+s][this.diagramId+"_nativeLayer"]=this.nativeSvgLayer.getElementById(this.diagramId+"_nativeLayer")),window[""+s][this.diagramId+"_nativeLayer"].setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+"),scale("+t.scale+")"),Io(this.diagramId).children[0].style.transform="translate("+t.tx*t.scale+"px,"+t.ty*t.scale+"px)scale("+t.scale+")",this.transform={x:t.tx*t.scale,y:t.ty*t.scale},!0}return!1},n.prototype.updateNode=function(t,e,i,r,s,o,a){this.renderElement(t,e,i,r,this.getParentSvg(t),void 0,void 0,s,null,o,a)},n}(),use=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),ib=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},uF=function(n){function t(e,i){var r=n.call(this,e,i)||this;return r.mode="Canvas",r.id="overview",r.actionName="",r.startPoint=null,r.currentPoint=null,r.prevPoint=null,r.scale=null,r.inAction=!1,r.viewPortRatio=1,r.horizontalOffset=0,r.verticalOffset=0,r.model={},r.event=!0,r.overviewid=88123,r.model={width:r.width,height:r.height},r}return use(t,n),t.prototype.onPropertyChanged=function(e,i){for(var r=0,s=Object.keys(e);r0||e.toString().indexOf("%")>0?e.toString():e.toString()+"px"},t.prototype.renderCanvas=function(e){var i=document.getElementById(this.element.id+"_canvas");i||(i=Tt("div",{}),this.element.appendChild(i)),Ho(i,{id:this.element.id+"_canvas",class:"drawing",style:"position:relative; height:"+this.getSizeValue(this.model.height)+"; width:"+this.getSizeValue(this.model.width)+";style:-ms-touch-action: none;touch-action: none;"}),this.element.setAttribute("tabindex",String(-1)),this.element.style.overflow="hidden",this.element.style.height=String(this.model.height),this.element.style.width=String(this.model.width),this.canvas=i},t.prototype.setParent=function(e){var i=document.getElementById(e);if(this.parent){var s=this.parent;this.parent=null,s.setOverview(null,this.element.id),this.removeDocument(this)}this.parent=this.getDiagram(i,"ej2_instances"),this.parent&&this.parent.setOverview(this)},t.prototype.getDiagram=function(e,i){for(var r,s=e[""+i].length,o=0;o0?f:Math.floor(window.innerWidth)}if(0===h){var p=Math.floor(window.innerHeight-u-Math.floor(c.top));h=p>0?p:Math.floor(window.innerHeight)}l>0&&(s.setAttribute("width",String(l)),this.model.height=h),h>0&&(s.setAttribute("height",String(h)),this.model.width=l),e.diagramLayerDiv||(e.diagramLayerDiv=Tt("div",{}),e.diagramLayer=bo.createCanvas(this.element.id+"_diagramLayer",this.model.width,this.model.height),e.diagramLayer.setAttribute("style","position:absolute; left:0px; top:0px "),e.diagramLayerDiv.appendChild(e.diagramLayer),e.canvas.appendChild(e.diagramLayerDiv)),Ho(e.diagramLayerDiv,{id:this.element.id+"_diagramLayer_div",style:"width:"+this.model.width+"px; height:"+this.model.height+"px;position:absolute;top:0px;left:0px"}),this.renderHtmlLayer(e.canvas),this.renderNativeLayer(e.canvas,e),this.addOverviewRectPanel(e)},t.prototype.removeDocument=function(e){var i=document.getElementById(this.canvas.id+"_svg");this.canvas.removeChild(i);var r=document.getElementById(this.element.id+"_htmlLayer");this.canvas.removeChild(r);var s=document.getElementById(this.element.id+"_diagramLayer_div");this.canvas.removeChild(s),e.diagramLayerDiv=null,e.diagramLayer=null,window.domTable[this.id+"html_layer"]=null},t.prototype.renderHtmlLayer=function(e){var i=Tt("div",{id:this.element.id+"_htmlLayer",class:"e-html-layer",style:"pointer-events:none;position:absolute;top:0px;left:0px;"}),s=Tt("div",{id:this.element.id+"_htmlLayer_div",style:"position:absolute;top:0px;left:0px;"});return i.appendChild(s),e.appendChild(i),i},t.prototype.renderNativeLayer=function(e,i){if(!document.getElementById(this.element.id+"_nativeLayer_svg")){var r=this.parent.createSvg(this.element.id+"_nativeLayer_svg",this.model.width,this.model.height),s=Fi("g",{id:this.element.id+"_nativeLayer"});r.appendChild(s),i.diagramLayerDiv.appendChild(r),ti(r,{class:"e-native-layer"})}},t.prototype.addOverviewRectPanel=function(e){var i=document.getElementById(this.canvas.id+"_overviewsvg");i&&i.parentNode.removeChild(i),i=Fi("svg",{id:this.canvas.id+"_overviewsvg",class:"overviewsvg",version:"1.1",style:"position:absolute;left:0px;top:0px; aria-label:Specifies overview",width:this.model.width,height:this.model.height}),e.canvas.appendChild(i);var s=Fi("g",{id:this.element.id+"_overviewlayer",style:"pointer-events:none"});i.appendChild(s);var o=Fi("rect",{fill:"transparent",width:"100%",height:"100%",class:"overviewbackrect",id:this.canvas.id+"overviewbackrect"});o.setAttribute("style"," pointer-events: none; "),s.appendChild(o);var a=Fi("g",{id:this.canvas.id+"overviewhandle",style:"pointer-events:all"});s.appendChild(a);var l=Fi("rect",{id:this.canvas.id+"overviewrect",fill:"transparent"});a.appendChild(l),this.renderOverviewCorner("left",a),this.renderOverviewCorner("right",a),this.renderOverviewCorner("top",a),this.renderOverviewCorner("bottom",a),this.renderOverviewCorner("topleft",a),this.renderOverviewCorner("topright",a),this.renderOverviewCorner("bottomleft",a),this.renderOverviewCorner("bottomright",a)},t.prototype.renderOverviewCorner=function(e,i){var s,o=Fi(s="top"===e||"bottom"===e||"right"===e||"left"===e?"rect":"circle",{id:this.canvas.id+"visible"+e,class:"overview-resizer"});i.appendChild(o);var a=Fi(s,{id:this.canvas.id+e,class:"overviewresizer",fill:"transparent"});i.appendChild(a)},t.prototype.updateOverviewRectangle=function(){var e=this.currentPoint.x-this.prevPoint.x,i=this.currentPoint.y-this.prevPoint.y,r=new me;r.width=0,r.height=0;var s=0,o=0;switch(this.resizeDirection){case"left":r.width-=e,r.height-=e/this.viewPortRatio,s=e,o=e/this.viewPortRatio,o/=2;break;case"right":r.width+=e,r.height+=e/this.viewPortRatio,o=e/this.viewPortRatio,o/=-2;break;case"top":r.height-=i,r.width-=i*this.viewPortRatio,o=i,s=i*this.viewPortRatio,s/=2;break;case"bottom":r.height+=i,r.width+=i*this.viewPortRatio,s=i*this.viewPortRatio,s/=-2;break;case"topleft":Math.abs(i)>Math.abs(e)?e=i*this.viewPortRatio:i=e/this.viewPortRatio,r.width-=e,r.height-=i,s=e,o=i;break;case"topright":Math.abs(i)>Math.abs(e)?e=-i*this.viewPortRatio:i=-e/this.viewPortRatio,o=i,r.width+=e,r.height-=i;break;case"bottomleft":Math.abs(i)>Math.abs(e)?e=-i*this.viewPortRatio:i=-e/this.viewPortRatio,s=e,r.width-=e,r.height+=i;break;case"bottomright":Math.abs(i)>Math.abs(e)?e=i*this.viewPortRatio:i=e/this.viewPortRatio,r.width+=e,r.height+=i}this.updateHelper(s,o,r,void 0,void 0)},t.prototype.updateHelper=function(e,i,r,s,o){var a,l,h,u,f,d=this.element.getElementsByTagName("svg")[2].getElementById("helper");r?(a=(h=d.getBBox()).x+e,l=h.y+i,s=h.width+r.width,o=h.height+r.height):(u=this.currentPoint.x>this.startPoint.x?this.currentPoint.x-this.prevPoint.x:this.prevPoint.x-this.currentPoint.x,f=this.currentPoint.y>this.startPoint.y?this.currentPoint.y-this.prevPoint.y:this.prevPoint.y-this.currentPoint.y,Math.abs(f)>Math.abs(u)?u=this.viewPortRatio*f:f=u/this.viewPortRatio,h=d.getBBox(),a=this.startPoint.x>this.currentPoint.x?h.x-u:h.x,l=this.startPoint.y>this.currentPoint.y?h.y-f:h.y,s=h.width+u,o=h.height+f),ti(this.helper,{id:this.helper.id,x:a,y:l,width:Math.max(0,s),height:Math.max(0,o)})},t.prototype.updateOverviewrect=function(e,i,r,s){Ho(document.getElementById(this.canvas.id+"overviewrect"),{x:e,y:i,width:Math.max(1,r),height:Math.max(1,s)}),this.updateOverviewCorner("top",e+8,i+1,Math.max(0,r-16),2),this.updateOverviewCorner("bottom",e+8,i+s+3,Math.max(0,r-16),2),this.updateOverviewCorner("left",e-2,i+11,2,Math.max(0,s-16)),this.updateOverviewCorner("right",e+r,i+11,2,Math.max(0,s-16)),this.updateOverviewCorner("topleft",e,i+3,5,5),this.updateOverviewCorner("topright",e+r,i+3,5,5),this.updateOverviewCorner("bottomleft",e,i+s+3,5,5),this.updateOverviewCorner("bottomright",e+r,i+s+3,5,5)},t.prototype.updateOverviewCorner=function(e,i,r,s,o){var a,l;"top"===e||"bottom"===e||"right"===e||"left"===e?(a={x:i,y:r,width:s,height:o,fill:"#ED1C24"},l={x:i-2,y:r-2,width:2===s?4:s,height:2===o?4:o}):(a={cx:i,cy:r,r:4,fill:"#ED1C24"},l={cx:i,cy:r,r:6,fill:"transparent"}),Ho(document.getElementById(this.canvas.id+"visible"+e),a),Ho(document.getElementById(this.canvas.id+e),l)},t.prototype.translateOverviewRectangle=function(){Number(this.model.width),Number(this.model.height);var r=this.currentPoint.x-this.prevPoint.x,s=this.currentPoint.y-this.prevPoint.y,l=this.element.getElementsByClassName("overviewsvg")[0].getElementById(this.canvas.id+"overviewrect").getBBox(),h=l.x+r,c=l.y+s,d=l.width,u=l.height;this.updateOverviewrect(h,c,d,u),this.updateParentView(this.parent.scroller.currentZoom,h,c,d,u,null)},t.prototype.renderOverviewRect=function(e,i,r,s){var o=Number(this.model.width),a=Number(this.model.height),c=Math.max(this.parent.scroller.viewPortWidth/(r/o*this.contentWidth),this.parent.scroller.viewPortHeight/(s/a*this.contentHeight));if(c>=.25&&c<=30){this.updateParentView(c,e,i,r,s,{x:0,y:0});var u=this.scrollOverviewRect(this.parent.scroller.horizontalOffset,this.parent.scroller.verticalOffset,this.parent.scroller.currentZoom,!0);if(this.helper){var p=this.element.getElementsByTagName("rect")[10].getBBox();u.x=p.x,u.y=p.y}"pan"===this.actionName?this.updateOverviewrect(-u.x,-u.y,u.width,u.height):this.updateOverviewrect(u.x,u.y,u.width,u.height)}},t.prototype.scrollOverviewRect=function(e,i,r,s){if(!this.actionName||s){var o=Number(this.model.width),a=Number(this.model.height),l=Math.min(this.contentWidth/o,this.contentHeight/a),h=new Ne,c=h.x=e/r/l,d=h.y=i/r/l,u=0;this.parent.rulerSettings.showRulers&&(u=25);var f=document.getElementById(this.parent.element.id+"content"),p=0,g=0;f&&(p=f.offsetWidth-f.clientWidth,g=f.offsetHeight-f.clientHeight);var v=h.width=(this.parent.scroller.viewPortWidth-u-p)/r/l,y=h.height=(this.parent.scroller.viewPortHeight-u-g)/r/l;if(s){var S=new Ne;return S.x=c,S.y=d,S.width=v,S.height=y,S}this.updateOverviewrect(-c,-d,v,y)}return null},t.prototype.updateParentView=function(e,i,r,s,o,a){var p,g,l=Number(this.model.width),h=Number(this.model.height),u=i*(this.contentWidth/l)*e,f=r*(this.contentHeight/h)*e;this.parent.scroller.getPageBounds(),(1!==e||"pan"===this.actionName)&&(p=-u-this.parent.scroller.horizontalOffset,g=-f-this.parent.scroller.verticalOffset),this.parent.setBlazorDiagramProps(!0),this.parent.realActions|=$i.OverViewAction,"scale"===this.actionName||"draw"===this.actionName?this.parent.scroller.zoom(e/this.parent.scroller.currentZoom,p,g,a):ce()?this.parent.scroller.zoom(1,p,g,a):this.parent.pan(p,g,a,!0)},t.prototype.updateHtmlLayer=function(e){var i=Io(e.element.id),r=this.parent.scroller.getPageBounds(!0),o=r.height,a=Math.max(r.width,this.parent.scroller.viewPortWidth),l=Math.max(o,this.parent.scroller.viewPortHeight/this.parent.scroller.currentZoom),h=Math.min(Number(this.model.width)/a,Number(this.model.height)/l);i.style.transform="scale("+h+") translate("+this.parent.scroller.transform.tx+"px,"+this.parent.scroller.transform.ty+"px)"},t.prototype.updateView=function(e){var i=this.parent.scroller.getPageBounds(),r=i.width,s=i.height,o=Number(this.model.width),a=Number(this.model.height),l=Math.max(r,this.parent.scroller.viewPortWidth),h=Math.max(s,this.parent.scroller.viewPortHeight);this.contentWidth=l=Math.max(l,o/a*h),this.contentHeight=h=Math.max(h,a/o*l);var c=Math.min(o/l,a/h),d=document.getElementById(this.element.id+"_htmlLayer");d.style.webkitTransform="scale("+c+") translate("+-i.x+"px,"+-i.y+"px)",d.style.transform="scale("+c+") translate("+-i.x+"px,"+-i.y+"px)",document.getElementById(this.element.id+"_overviewlayer").setAttribute("transform","translate("+-i.x*c+","+-i.y*c+")"),this.horizontalOffset=i.x*c,this.verticalOffset=i.y*c;var f=document.getElementById(this.element.id+"_diagramLayer"),p=UF(this.element.id),g=f.getContext("2d"),v=Number(this.model.width)/this.contentWidth,y=Number(this.model.height)/this.contentHeight;v=Math.min(v,y);var S=this.parent.scroller.transform;p.setAttribute("transform","translate("+S.tx*v+","+S.ty*y+"),scale("+v+")"),g.setTransform(v,0,0,v,0,0),g.fillStyle="red",this.scrollOverviewRect(this.parent.scroller.horizontalOffset,this.parent.scroller.verticalOffset,this.parent.scroller.currentZoom)},t.prototype.scrolled=function(e){if(this.event){var i=this.scrollOverviewRect(this.parent.scroller.horizontalOffset,this.parent.scroller.verticalOffset,this.parent.scroller.currentZoom,!0);this.updateOverviewrect(-i.x,-i.y,i.width,i.height),this.updateView(this)}},t.prototype.updateCursor=function(e){if(gm(e.target,"overviewresizer"))switch(e.target.id){case this.canvas.id+"left":this.canvas.style.cursor="w-resize";break;case this.canvas.id+"right":this.canvas.style.cursor="e-resize";break;case this.canvas.id+"top":this.canvas.style.cursor="n-resize";break;case this.canvas.id+"bottom":this.canvas.style.cursor="s-resize";break;case this.canvas.id+"topleft":this.canvas.style.cursor="nw-resize";break;case this.canvas.id+"topright":this.canvas.style.cursor="ne-resize";break;case this.canvas.id+"bottomleft":this.canvas.style.cursor="sw-resize";break;case this.canvas.id+"bottomright":this.canvas.style.cursor="se-resize"}else this.canvas.style.cursor="default"},t.prototype.mouseMove=function(e){if(this.event=!1,this.updateCursor(e),this.currentPoint=this.mousePosition(e),this.actionName)switch(this.actionName){case"draw":!this.inAction&&(this.startPoint.x!==this.currentPoint.x||this.startPoint.y!==this.currentPoint.y)&&(this.initHelper(),this.inAction=!0),this.inAction&&this.updateHelper();break;case"scale":this.inAction||(this.initHelper(),this.inAction=!0),this.updateOverviewRectangle();break;case"pan":(this.startPoint.x!==this.currentPoint.x||this.startPoint.y===this.currentPoint.y||this.inAction)&&(this.inAction=!0,this.translateOverviewRectangle())}this.prevPoint=this.currentPoint},t.prototype.documentMouseUp=function(e){this.inAction=!1,this.actionName="",this.helper&&(this.helper.parentNode.removeChild(this.helper),this.helper=null),this.event=!0,document.getElementById(this.canvas.id+"overviewhandle").style.pointerEvents="all"},t.prototype.windowResize=function(e){var i=this;return this.resizeTo&&clearTimeout(this.resizeTo),this.resizeTo=setTimeout(function(){var s=document.getElementById(i.element.id).getBoundingClientRect();i.model.width=s.width>0?s.width:i.model.width,i.model.height=s.height>0?s.height:i.model.height,i.renderCanvas(),i.setParent(i.sourceID)},10),!1},t.prototype.mouseDown=function(e){if(e.target.id===this.canvas.id+"_overviewsvg"&&(this.actionName="draw"),e.target.id===this.canvas.id+"overviewrect"&&(this.actionName="pan"),gm(e.target,"overviewresizer"))switch(this.actionName="scale",e.target.id){case this.canvas.id+"left":this.resizeDirection="left";break;case this.canvas.id+"right":this.resizeDirection="right";break;case this.canvas.id+"top":this.resizeDirection="top";break;case this.canvas.id+"bottom":this.resizeDirection="bottom";break;case this.canvas.id+"topleft":this.resizeDirection="topleft";break;case this.canvas.id+"topright":this.resizeDirection="topright";break;case this.canvas.id+"bottomleft":this.resizeDirection="bottomleft";break;case this.canvas.id+"bottomright":this.resizeDirection="bottomright"}this.startPoint=this.prevPoint=this.mousePosition(e),this.viewPortRatio=this.parent.scroller.viewPortWidth/this.parent.scroller.viewPortHeight,document.getElementById(this.canvas.id+"overviewhandle").style.pointerEvents="none"},t.prototype.mouseUp=function(e){if(this.currentPoint=this.mousePosition(e),this.actionName)if(this.startPoint.x!==this.currentPoint.x||this.startPoint.y!==this.currentPoint.y){if("pan"!==this.actionName&&this.helper){var i=this.element.getElementsByTagName("rect")[10].getBBox();this.resizeDirection=this.resizeDirection||"",this.renderOverviewRect(i.x,i.y,o=i.width,a=i.height)}}else if(e.target.id===this.canvas.id+"_overviewsvg"||"helper"===e.target.id){var o=(i=this.element.getElementsByTagName("svg")[2].getElementById(this.canvas.id+"overviewrect").getBBox()).width,a=i.height;this.inAction=!0,this.actionName="pan",this.renderOverviewRect(this.currentPoint.x-o/2,this.currentPoint.y-a/2,o,a),this.inAction=!1}this.helper&&(this.helper.parentNode.removeChild(this.helper),this.helper=null),this.actionName="",this.startPoint=null,this.currentPoint=null,this.prevPoint=null,this.helper=null,this.viewPortRatio=1,this.resizeDirection="",this.inAction=!1,this.event=!0,document.getElementById(this.canvas.id+"overviewhandle").style.pointerEvents="all"},t.prototype.initHelper=function(){var e=this.element.getElementsByTagName("svg")[2],i=this.startPoint.x,r=this.startPoint.y,s=1,o=1;if("scale"===this.actionName){var l=e.getElementById(this.canvas.id+"overviewrect").getBBox();i=l.x,r=l.y,s=l.width,o=l.height}var h=Fi("rect",{id:"helper",x:i,y:r,width:s,height:o,fill:"transparent",stroke:"gray","stroke-dasharray":"2 2","shape-rendering":"crispEdges"});e.getElementById(this.element.id+"_overviewlayer").appendChild(h),this.helper=h},t.prototype.mousePosition=function(e){var i,r,s;-1!==e.type.indexOf("touch")?(r=(i=e).changedTouches[0].clientX-this.element.offsetLeft,s=i.changedTouches[0].clientY-this.element.offsetTop):(r=e.clientX,s=e.clientY);var l=this.element.getBoundingClientRect();return{x:(r-=l.left)+this.horizontalOffset,y:(s-=l.top)+this.verticalOffset}},t.prototype.destroy=function(){if(this.unWireEvents(),this.notify("destroy",{}),n.prototype.destroy.call(this),document.getElementById(this.element.id)){this.element.classList.remove("e-overview");var e=document.getElementById(this.element.id+"_canvas");e&&this.element.removeChild(e)}this.parent.views.splice(this.parent.views.indexOf(this.element.id),1),this.diagramLayerDiv=null,this.canvas=null,this.parent=null},t.prototype.getModuleName=function(){return"Overview"},ib([I("100%")],t.prototype,"width",void 0),ib([I("100%")],t.prototype,"height",void 0),ib([I("")],t.prototype,"sourceID",void 0),ib([H()],t.prototype,"created",void 0),t}(Ii);function pse(n,t){for(var e=0;eR.findLength(e,n)?e:t;var o=R.findAngle(t,e),a=R.findAngle(i,n),l=R.findLength(i,n),h=a+2*(o-a);return{x:i.x+l*Math.cos(h*Math.PI/180),y:i.y+l*Math.sin(h*Math.PI/180)}}function ep(n,t,e){if(n&&n.children&&n.children.length>0)for(var r=void 0,s=0;s0&&"annotations"!==r&&"ports"!==r)if(n[""+l].length>0)for(var h=0;h<=n[""+l].length;h++)Ro(n[""+l],t?t[""+l]:void 0,e[""+l],"annotations"===l||"ports"===l?n:void 0,l);else Ro(n[""+l],t?t[""+l]:void 0,e[""+l],"annotations"===l||"ports"===l?n:void 0,l);else if(s instanceof Object&&t&&"annotations"!==r&&"ports"!==r)Ro(n[""+l],t[""+l],e[""+l]);else if("annotations"!==r&&"ports"!==r&&t&&!t[""+l]||!t&&n&&(n[""+l]||void 0!==n[""+l]))n[""+l]=e[""+l];else{var c=void 0;("annotations"===r||"ports"===r)&&("annotations"===r?(n[""+l]&&Ro(n[""+l],t[""+l],e[""+l]),n[""+l]||(ps(i)===de?(c=new Or(i,"annotations",e[""+l]),i.annotations.push(c)):(c=new Kn(i,"annotations",e[""+l]),i.annotations.push(c)))):n[""+l]?Ro(n[""+l],t[""+l],e[""+l]):(c=new Es(i,"ports",e[""+l]),i.ports.push(c)))}}}function bse(n,t){for(var e="Bezier"===n.type?function yse(n){var t=[];if("Bezier"===n.type)for(var e=0,i=0;i0||n.ports.length>0){var f=n.wrapper.children;for(i=3;i0)return{enabled:!1,intersectPt:e};var l=o/s,h=a/s;return l>=0&&l<=1&&h>=0&&h<=1?(e.x=i.x1+l*(i.x2-i.x1),e.y=i.y1+l*(i.y2-i.y1),{enabled:!0,intersectPt:e}):{enabled:!1,intersectPt:e}}function nb(n,t,e,i){var a=nm(vF(n.x,n.y,t.x,t.y),vF(e.x,e.y,i.x,i.y));return a.enabled?a.intersectPt:{x:0,y:0}}function vF(n,t,e,i){return{x1:Number(n)||0,y1:Number(t)||0,x2:Number(e)||0,y2:Number(i)||0}}function mF(n,t,e){var i=[],s={x:t.topRight.x+(e=e||0),y:t.topRight.y},o={x:t.bottomRight.x,y:t.bottomRight.y-e},a={x:t.bottomLeft.x,y:t.bottomLeft.y+e};return i.push({x:t.topLeft.x-e,y:t.topLeft.y}),i.push(s),i.push(o),i.push(a),i}function zc(n,t,e,i,r,s){var o={},a=e.scroller.transform.scale,h=e.scroller.verticalOffset;return o.x=(i?n.x:t.x)*a+e.scroller.horizontalOffset-r,o.y=(i?n.y:t.y)*a+h-s,o}function yF(n,t){var e=new Ze;return e.data=n.pathData,e.height=n.height>10?n.height-(n.padding.bottom+n.padding.top):n.height,e.width=n.width>10?n.width-(n.padding.left+n.padding.right):n.width,e.visible=n.visibility,e.id=t.id+"_shape",e.inversedAlignment=!1,e.horizontalAlignment="Center",e.verticalAlignment="Center",e.style={fill:n.iconStrokeColor,strokeColor:n.iconStrokeColor,strokeWidth:n.iconStrokeWidth},e.setOffsetWithRespectToBounds(.5,.5,"Fraction"),e.relativeMode="Object",e.description=t.description||"",e}function Zx(n,t,e){var i=Jx(n,t),r=R.findAngle(n[i.index],n[i.index+1]),s=function Tse(n){var t;t=n instanceof OI?0:void 0===n.content?10:0;var e=0;switch(n.alignment){case"Center":e=0;break;case"Before":e=-(0+t);break;case"After":e=0+t}return e}(t),o=R.transform(i.point,r+45,s);return i.point=o,i.angle=r,i}function Jx(n,t){for(var r,s,a,l,e=0,i=t.offset,o=[],h=0;h=c)return s=R.findAngle(n[parseInt(d.toString(),10)],n[d+1]),{point:r=R.transform(n[parseInt(d.toString(),10)],s,c-(a||0)),index:l=d};a=o[parseInt(d.toString(),10)]}return{point:r,index:l}}function SF(n,t,e){t%=360;var a,l,s=225;switch(n.alignment){case"Before":t>=45&&t<=135?(l="right",a=.5===n.offset?"center":"top"):t>=s&&t<=315?(l="left",a=.5===n.offset?"center":"bottom"):t>45&&t=45&&t<=135?(l="left",a=.5===n.offset?"center":"top"):t>=s&&t<=315?(l="right",a=.5===n.offset?"center":"bottom"):t>45&&tMath.abs(t.y-n.y)?n.x0)for(var e=0;e=0;r--)("nodes"===i||"connectors"===i)&&(n[""+i][parseInt(r.toString(),10)].wrapper=null),"dataManager"!==i&&(n[""+i][parseInt(r.toString(),10)]=tT(n[""+i][parseInt(r.toString(),10)],e[""+i][parseInt(r.toString(),10)],void 0!==t[""+i]?t[""+i][parseInt(r.toString(),10)]:[]),("[]"===JSON.stringify(n[""+i][parseInt(r.toString(),10)])||"{}"===JSON.stringify(n[""+i][parseInt(r.toString(),10)])||void 0===n[""+i][parseInt(r.toString(),10)])&&n[""+i].splice(r,1));n=void 0}function Hh(n,t){var e=t.style,i=t;t.canApplyStyle=!0;for(var r=0,s=Object.keys(n);r=0&&n.splice(e,1)}function tp(n,t,e){var i;n.intermediatePoints=t,n.updateSegmentElement(n,t,n.wrapper.children[0],e);var r=n.sourceDecorator;if("Bezier"===n.type){var s=n.segments[0],o=n.segments[n.segments.length-1];i=[R.isEmptyPoint(o.point2)?o.bezierPoint2:o.point2,R.isEmptyPoint(s.point1)?s.bezierPoint1:s.point1]}else i=n.intermediatePoints;t=n.clipDecorators(n,t,e);var a=n.wrapper.children[0];a.canMeasurePath=!0,n.updateDecoratorElement(a=n.wrapper.children[1],t[0],i[1],r),n.updateDecoratorElement(a=n.wrapper.children[2],t[t.length-1],i[i.length-2],n.targetDecorator),n.updateShapeElement(n)}function iT(n,t,e){var l,i=n.wrapper,s=t.offset,o=t.size/e.scale,a=t.margin,h=i.offsetX-i.actualSize.width*i.pivot.x,c=i.offsetY-i.actualSize.height*i.pivot.y;if(l={x:0,y:0},n.nodes.length>0){switch(t.side){case"Top":l.x+=h+s*i.actualSize.width,l.y+=c-o;break;case"Bottom":l.x+=h+s*i.actualSize.width,l.y+=c+i.actualSize.height+o;break;case"Left":l.x+=h-o,l.y+=c+s*i.actualSize.height;break;case"Right":l.x+=h+i.actualSize.width+o,l.y+=c+s*i.actualSize.height}l.x+=(a.left-a.right)/e.scale+o/2*("Center"===t.horizontalAlignment?0:"Right"===t.horizontalAlignment?-1:1),l.y+=(a.top-a.bottom)/e.scale+o/2*("Center"===t.verticalAlignment?0:"Top"===t.verticalAlignment?-1:1)}else if(n.connectors.length>0){var d=n.connectors[0],u={offset:s},f=Jx(d.intermediatePoints,u),p=f.index;l=f.point;var y,v=Zx(d.intermediatePoints,u).angle;qi(y=Bi(),-v,d.intermediatePoints[parseInt(p.toString(),10)].x,d.intermediatePoints[parseInt(p.toString(),10)].y),(l=Ke(y,l)).x+=a.left-a.right+o/2*("Center"===t.horizontalAlignment?0:"Right"===t.horizontalAlignment?-1:1),l.y+=a.top-a.bottom+o/2*("Center"===t.verticalAlignment?0:"Top"===t.verticalAlignment?-1:1),qi(y=Bi(),v,d.intermediatePoints[parseInt(p.toString(),10)].x,d.intermediatePoints[parseInt(p.toString(),10)].y),l=Ke(y,l)}return 0===i.rotateAngle&&0===i.parentTransform||(qi(y=Bi(),i.rotateAngle+i.parentTransform,i.offsetX,i.offsetY),l=Ke(y,l)),l}function ga(n,t,e,i){if(i.annotation){if(zl(i.annotation))return!0}else if(mr[""+t]&n&&bt[""+t]&e)return!0;return!1}function qr(n,t){return!!(mr[""+t]&n)}function Hc(n,t){return!!(Cx[""+t]&n)}function va(n,t){return n.visibility&t}function sb(n,t){var e;if("Text"===n.shape.type)e=n.shape;else{var i=t.split("_");t=i[i.length-1];for(var r=0;rn[""+t]?e.splice(0,0,n):e.push(n);else if(e.length>1){for(var i=0,r=e.length-1,s=Math.floor((i+r)/2);s!==i;)if(e[parseInt(s.toString(),10)][""+t]n[""+t]))break;r=s,s=Math.floor((i+r)/2)}e[parseInt(r.toString(),10)][""+t]n[""+t]?e.splice(i,0,n):e[parseInt(i.toString(),10)][""+t]n[""+t]&&e.splice(r,0,n)}}function Qse(n){var t=document.getElementById(n.diagramId),e="ej2_instances",i=t[""+e][0].nodes;void 0===i&&(i=function Gse(n){for(var t=[],e=0;e30?10:o/2;for(var h=0,c=0;c=l){var u=l-h;r=Gt(n[c],n[c+1]),s=R.transform(n[c],r,u);break}h+=d}return s},lb=function(n,t){if(n instanceof te||n instanceof de)for(var e=0;e=0||navigator.platform.indexOf("iPad")>=0||navigator.platform.indexOf("iPhone")>=0||navigator.platform.indexOf("MacIntel")>=0)&&("safari"===X.info.name||"webkit"===X.info.name)}function AF(n,t,e,i){return void 0!==t.previewSize[""+i]?t.previewSize[""+i]:void 0!==n.symbolPreview[""+i]?n.symbolPreview[""+i]:t[""+i]||e.actualSize[""+i]}function hm(n,t,e){return n&&n.parentId&&(e=(n=t.nameTable[n.parentId]).parentId?hm(n,t,e):n.id),e}function cm(n,t){return n.selectedItems.connectors.length>1&&0===n.selectedItems.nodes.length&&0!==t.rotateAngle}function Zse(n){if(n.arrowType&&""!==n.arrowType.trim())switch(n.arrowType){case"single-line-arrow":default:return{targetDecorator:"Arrow",strokeWidth:1};case"double-line-arrow":return{targetDecorator:"Arrow",strokeWidth:2};case"dotted-arrow":return{targetDecorator:"Arrow",strokeDashArray:"2,2"};case"single-line":return{targetDecorator:"None",strokeWidth:1};case"double-line":return{targetDecorator:"None",strokeWidth:2};case"dotted":return{targetDecorator:"None",strokeDashArray:"2,2"};case"wiggly-arrow":return{targetDecorator:"None",strokeWidth:1,opacity:0}}return{targetDecorator:"Arrow",strokeWidth:1}}var Jse=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),no=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},LF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Jse(t,n),no([I("None")],t.prototype,"shape",void 0),no([I("white")],t.prototype,"fill",void 0),no([I("Auto")],t.prototype,"horizontalAlignment",void 0),no([I("Auto")],t.prototype,"verticalAlignment",void 0),no([I(10)],t.prototype,"width",void 0),no([I(10)],t.prototype,"height",void 0),no([re({x:.5,y:1},R)],t.prototype,"offset",void 0),no([I("#1a1a1a")],t.prototype,"borderColor",void 0),no([I(1)],t.prototype,"borderWidth",void 0),no([re({},Jn)],t.prototype,"margin",void 0),no([I("")],t.prototype,"pathData",void 0),no([I("")],t.prototype,"content",void 0),no([I(0)],t.prototype,"cornerRadius",void 0),no([re({left:2,right:2,top:2,bottom:2},Jn)],t.prototype,"padding",void 0),no([I("#1a1a1a")],t.prototype,"iconColor",void 0),t}(Ee),Kse=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),oT=function(n){function t(){var e=null!==n&&n.apply(this,arguments)||this;return e.orientation="Vertical",e.measureChildren=void 0,e.considerPadding=!0,e}return Kse(t,n),t.prototype.measure=function(e){return this.desiredSize=this.measureStackPanel(e,"Horizontal"===this.orientation?this.updateHorizontalStack:this.updateVerticalStack),this.desiredSize},t.prototype.arrange=function(e){return this.actualSize=this.arrangeStackPanel(e,"Horizontal"===this.orientation?this.arrangeHorizontalStack:this.arrangeVerticalStack),this.updateBounds(),this.actualSize},t.prototype.measureStackPanel=function(e,i){var r=void 0;if(void 0!==this.children&&this.children.length>0)for(var s=0,o=this.children;s0){var r=void 0,s=void 0;r=this.offsetX-e.width*this.pivot.x+this.padding.left,s=this.offsetY-e.height*this.pivot.y+this.padding.top;for(var o=0,a=this.children;o0)for(var i=0,r=this.children;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},aoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return ooe(t,n),Bh([I("Horizontal")],t.prototype,"orientation",void 0),Bh([I("Center")],t.prototype,"type",void 0),Bh([I(void 0)],t.prototype,"offset",void 0),Bh([I(!1)],t.prototype,"enableRouting",void 0),Bh([I([])],t.prototype,"children",void 0),Bh([I("")],t.prototype,"assistants",void 0),Bh([I("")],t.prototype,"level",void 0),Bh([I("")],t.prototype,"hasSubTree",void 0),Bh([I("")],t.prototype,"rows",void 0),t}(Ee),Ni=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),q=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},loe=function(n){if(n)switch(n.type){case"Basic":default:return hb;case"Flow":return PF;case"Path":return NF;case"Image":return kF;case"Text":return Hd;case"Bpmn":return uT;case"Native":return dm;case"HTML":return OF;case"UmlActivity":return zF;case"UmlClassifier":return RF;case"SwimLane":return _d}return hb},ma=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),q([I("Basic")],t.prototype,"type",void 0),t}(Ee),NF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"Path"},q([I("Path")],t.prototype,"type",void 0),q([I("")],t.prototype,"data",void 0),t}(ma),dm=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"Native"},q([I("Native")],t.prototype,"type",void 0),q([I("")],t.prototype,"content",void 0),q([I("Stretch")],t.prototype,"scale",void 0),t}(ma),OF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"Html"},q([I("HTML")],t.prototype,"type",void 0),q([I("")],t.prototype,"content",void 0),t}(ma),kF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"Image"},q([I("Image")],t.prototype,"type",void 0),q([I("")],t.prototype,"source",void 0),q([I("None")],t.prototype,"scale",void 0),q([I("None")],t.prototype,"align",void 0),t}(ma),Hd=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"Text"},q([I("Text")],t.prototype,"type",void 0),q([I("")],t.prototype,"content",void 0),q([re({},Jn)],t.prototype,"margin",void 0),t}(ma),hb=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"BasicShape"},q([I("Basic")],t.prototype,"type",void 0),q([I("Rectangle")],t.prototype,"shape",void 0),q([I(0)],t.prototype,"cornerRadius",void 0),q([Bt([],R)],t.prototype,"points",void 0),t}(ma),PF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"FlowShape"},q([I("Flow")],t.prototype,"type",void 0),q([I("Terminator")],t.prototype,"shape",void 0),t}(ma),lT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"BpmnGateway"},q([I("None")],t.prototype,"type",void 0),t}(Ee),hT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"BpmnDataObject"},q([I("None")],t.prototype,"type",void 0),q([I(!1)],t.prototype,"collection",void 0),t}(Ee),hoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),q([I("None")],t.prototype,"type",void 0),q([I("None")],t.prototype,"loop",void 0),q([I(!1)],t.prototype,"call",void 0),q([I(!1)],t.prototype,"compensation",void 0),t}(Ee),cT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"BpmnEvent"},q([I("Start")],t.prototype,"event",void 0),q([I("None")],t.prototype,"trigger",void 0),t}(Ee),Bd=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"BpmnSubEvent"},q([I("None")],t.prototype,"trigger",void 0),q([I("Start")],t.prototype,"event",void 0),q([I("")],t.prototype,"id",void 0),q([re({},R)],t.prototype,"offset",void 0),q([Bt([],Kn)],t.prototype,"annotations",void 0),q([Bt([],Es)],t.prototype,"ports",void 0),q([I()],t.prototype,"width",void 0),q([I()],t.prototype,"height",void 0),q([re({},Jn)],t.prototype,"margin",void 0),q([I("Center")],t.prototype,"horizontalAlignment",void 0),q([I("Center")],t.prototype,"verticalAlignment",void 0),q([I(!0)],t.prototype,"visible",void 0),t}(Ee),coe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),q([re({id:"success",event:"End",offset:{x:1,y:.5}},Bd)],t.prototype,"success",void 0),q([re({id:"failure",event:"Intermediate",trigger:"Error",offset:{x:.25,y:1}},Bd)],t.prototype,"failure",void 0),q([re({id:"cancel",event:"Intermediate",trigger:"Cancel",offset:{x:.75,y:1}},Bd)],t.prototype,"cancel",void 0),t}(Ee),doe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),q([I("None")],t.prototype,"type",void 0),q([I(!1)],t.prototype,"adhoc",void 0),q([I("Default")],t.prototype,"boundary",void 0),q([I(!1)],t.prototype,"compensation",void 0),q([I("None")],t.prototype,"loop",void 0),q([I(!0)],t.prototype,"collapsed",void 0),q([Bt([],Bd)],t.prototype,"events",void 0),q([re({},coe)],t.prototype,"transaction",void 0),q([I(void 0)],t.prototype,"processes",void 0),t}(Ee),dT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"BpmnActivity"},q([I("Task")],t.prototype,"activity",void 0),q([re({},hoe)],t.prototype,"task",void 0),q([re({},doe)],t.prototype,"subProcess",void 0),t}(Ee),um=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return Ni(t,n),t.prototype.getClassName=function(){return"BpmnAnnotation"},q([I("")],t.prototype,"text",void 0),q([I("")],t.prototype,"id",void 0),q([I(0)],t.prototype,"angle",void 0),q([I()],t.prototype,"height",void 0),q([I()],t.prototype,"width",void 0),q([I(0)],t.prototype,"length",void 0),t}(Ee),uoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),q([I("")],t.prototype,"textAnnotationTarget",void 0),q([I("Auto")],t.prototype,"textAnnotationDirection",void 0),t}(Ee),uT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"BpmnShape"},q([I("Bpmn")],t.prototype,"type",void 0),q([I("Event")],t.prototype,"shape",void 0),q([re({},cT)],t.prototype,"event",void 0),q([re({},lT)],t.prototype,"gateway",void 0),q([re({},hT)],t.prototype,"dataObject",void 0),q([re({},dT)],t.prototype,"activity",void 0),q([re({},um)],t.prototype,"annotation",void 0),q([Bt([],um)],t.prototype,"annotations",void 0),q([re({},uoe)],t.prototype,"textAnnotation",void 0),t}(ma),zF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"UmlActivityShape"},q([I("UmlActivity")],t.prototype,"type",void 0),q([I("Action")],t.prototype,"shape",void 0),t}(ma),fT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"MethodArguments"},q([I("")],t.prototype,"name",void 0),q([I("")],t.prototype,"type",void 0),q([re({},qf)],t.prototype,"style",void 0),t}(Ee),op=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"UmlClassAttribute"},q([I("Public")],t.prototype,"scope",void 0),q([I(!1)],t.prototype,"isSeparator",void 0),q([re({fill:"#F9F9F9",strokeColor:"#CCCCCC"},Nl)],t.prototype,"separatorStyle",void 0),t}(fT),fm=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"UmlClassMethod"},q([Bt([],fT)],t.prototype,"parameters",void 0),t}(op),cb=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"UmlClass"},q([I("")],t.prototype,"name",void 0),q([Bt([],op)],t.prototype,"attributes",void 0),q([Bt([],fm)],t.prototype,"methods",void 0),q([re({},qf)],t.prototype,"style",void 0),t}(Ee),pT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"UmlInterface"},q([I(!1)],t.prototype,"isSeparator",void 0),q([re({fill:"#F9F9F9",strokeColor:"#CCCCCC"},Nl)],t.prototype,"separatorStyle",void 0),t}(cb),db=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"UmlEnumerationMember"},q([I("")],t.prototype,"name",void 0),q([I("")],t.prototype,"value",void 0),q([I(!1)],t.prototype,"isSeparator",void 0),q([re({fill:"#F9F9F9",strokeColor:"#CCCCCC"},Nl)],t.prototype,"separatorStyle",void 0),q([re({},qf)],t.prototype,"style",void 0),t}(Ee),gT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"UmlEnumeration"},q([I("")],t.prototype,"name",void 0),q([Bt([],db)],t.prototype,"members",void 0),q([re({},qf)],t.prototype,"style",void 0),t}(Ee),RF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"UmlClassifierShape"},q([I("UmlClassifier")],t.prototype,"type",void 0),q([re({},cb)],t.prototype,"classShape",void 0),q([re({},pT)],t.prototype,"interfaceShape",void 0),q([re({},gT)],t.prototype,"enumerationShape",void 0),q([I("Class")],t.prototype,"classifier",void 0),t}(ma),te=function(n){function t(e,i,r,s){var a,o=n.call(this,e,i,r,s)||this;return o.isCanvasUpdate=!1,o.status="None",o.parentId="",o.processId="",o.umlIndex=-1,o.outEdges=[],o.inEdges=[],o.isHeader=!1,o.isLane=!1,o.isPhase=!1,o.children&&o.children.length>0&&((!(a=r).style||!a.style.fill)&&(o.style.fill="transparent"),(!a.style||!a.style.strokeColor)&&(o.style.strokeColor="transparent")),o.shape&&"UmlActivity"===o.shape.type&&rb(r,o),o.shape&&"SwimLane"===o.shape.type&&fF(r,o),o.ports&&o.ports.length&&function vse(n){for(var t=0;t>";t=n;break;case"FinalNode":t=IF(e)}return t}(new Ze,i,this);break;case"Bpmn":if(e.bpmnModule){i=e.bpmnModule.initBPMNContent(i,this,e),this.wrapper.elementActions=this.wrapper.elementActions|Xr.ElementIsGroup;var v=this.shape.activity.subProcess;if(v.processes&&v.processes.length)for(var S=0,b=this.shape.activity.subProcess.processes;S>",margin:{left:10,right:10},id:"class",style:{fontSize:i.style.fontSize,color:i.style.color,fill:i.style.fill,textWrapping:r},offset:{x:.5,y:.3},constraints:Nr.ReadOnly}],constraints:(ie.Default|ie.HideThumbs)&~(ie.Rotate|ie.Drag|ie.Resize),verticalAlignment:"Stretch",horizontalAlignment:"Stretch",style:{fill:t.style.fill,strokeColor:"black"===t.style.strokeColor?"#ffffff00":t.style.strokeColor}},!0);return e.initObject(s),e.nodes.push(s),e.UpdateBlazorDiagramModel(s,"Node"),t.children.push(s.id),function toe(n,t,e,i){if("Enumeration"===n.shape.classifier){var r=e.members;if(r&&r.length){np(n,t);for(var s="",o=0;o0)for(var o=0;o0&&s.phaseSize&&(i+=s.phaseSize,$v(n,s.phaseSize)),s.lanes.length>0)for(o=0;o0){var a=0;for(o=0;o0&&"Horizontal"===r.orientation)for(l=0;l0&&(i+=r.phaseSize,o=Zv(r.phaseSize),n.push(o)),a=0;a0&&o.phaseSize){for(var l=0;l0)for(l=0;l0?e.nameTable[this.nodes[0].id].wrapper:e.nameTable[this.connectors[0].id].wrapper,this.annotation.id);i.children.push(s)}else if(this.nodes||this.connectors){for(var o=0;o-1}function VF(n,t,e){n=[];for(var i=0,r=e.length;i0?c.getElementsByTagName("svg")[0].outerHTML:c.getElementsByTagName("g").length>0?c.getElementsByTagName("g")[0].outerHTML:"",s.shape.content=h,n.content=h,c.parentElement.removeChild(c)}l="nodeTemplate"}else a=s,l="annotationTemplate";var p=document.getElementById(n.diagramId).ej2_instances[0];if("string"!=typeof n.content&&"function"!=typeof n.content||n.isTemplate)if(n.isTemplate){if(v=void 0,v=p.isReact?n.getNodeTemplate()($(e),p,l+"_"+("nodeTemplate"===l?e.id:n.nodeId+e.id),void 0,void 0,!1,i):p.isVue||p.isVue3?n.getNodeTemplate()?n.getNodeTemplate()($(e),p,l+"_"+("nodeTemplate"===l?e.id:n.nodeId+e.id),void 0,void 0,!1,i):(v=si("nodeTemplate"===l?p.nodeTemplate:p.annotationTemplate))($(e),p,l+"_"+("nodeTemplate"===l?e.id:n.nodeId+e.id),void 0,void 0,!1,i):n.getNodeTemplate()($(e),p,l+"_"+("nodeTemplate"===l?e.id:n.nodeId+e.id),void 0,void 0,!1))for(var M=0;M=1&&0===n.x&&("Clip"===i.textOverflow||"Ellipsis"===i.textOverflow)&&("Wrap"===i.textWrapping||"WrapWithOverflow"===i.textWrapping)&&(n.x=t[e-1]?t[e-1].x:-n.width/2),n.x}function QF(n,t,e,i){return e&&!t.template||t.template&&"function"==typeof t.template&&i.isReact?(n.isTemplate=!0,n.template=n.content=Fh(n,!0,t)):n.content=t.template,n}function Qe(){for(var e,t="",i=0;i<5;i++){if(typeof window<"u"&&"crypto"in window&&"getRandomValues"in crypto){var r=new Uint16Array(1);e=(window.msCrypto||window.crypto).getRandomValues(r)[0]%60}else e=Math.floor(61*Math.random());0===i&&e<10?i--:t+="0123456789ABCDEFGHIJKLMNOPQRSTUVWXTZabcdefghiklmnopqrstuvwxyz".substring(e,e+1)}return t}function GF(n){if(n)try{return"function"!=typeof n&&document.querySelectorAll(n).length?si(document.querySelector(n).innerHTML.trim()):si(n)}catch{return si(n)}}function xn(n){new Ne;var e=n.offsetY-n.actualSize.height*n.pivot.y,i=n.offsetY+n.actualSize.height*(1-n.pivot.y),r=n.offsetX-n.actualSize.width*n.pivot.x,s=n.offsetX+n.actualSize.width*(1-n.pivot.x);return Ne.toBounds([{x:r,y:e},{x:s,y:e},{x:r,y:i},{x:s,y:i}])}function yr(n){var t=new Ne,e=xn(n),i=e.middleLeft,r=e.topCenter,s=e.bottomCenter,o=e.middleRight,a=e.topLeft,l=e.topRight,h=e.bottomLeft,c=e.bottomRight;if(n.corners={topLeft:a,topCenter:r,topRight:l,middleLeft:i,middleRight:o,bottomLeft:h,bottomCenter:s,bottomRight:c},0!==n.rotateAngle||0!==n.parentTransform){var d=Bi();qi(d,n.rotateAngle+n.parentTransform,n.offsetX,n.offsetY),n.corners.topLeft=a=Ke(d,a),n.corners.topCenter=r=Ke(d,r),n.corners.topRight=l=Ke(d,l),n.corners.middleLeft=i=Ke(d,i),n.corners.middleRight=o=Ke(d,o),n.corners.bottomLeft=h=Ke(d,h),n.corners.bottomCenter=s=Ke(d,s),n.corners.bottomRight=c=Ke(d,c)}return t=Ne.toBounds([a,l,h,c]),n.corners.left=t.left,n.corners.right=t.right,n.corners.top=t.top,n.corners.bottom=t.bottom,n.corners.center=t.center,n.corners.width=t.width,n.corners.height=t.height,t}function $(n,t,e,i){var r={},s="properties";if(n){e=n.propName;var l=[],h=[];if((l=l.concat(Object.keys(n[""+s]||n))).push("version"),e){var c=Zi(t);h=c?c(e):[],l=l.concat(h)}for(var d=function Ooe(n){switch(n){case"nodes":case"children":return["inEdges","outEdges","parentId","processId","nodeId","umlIndex","isPhase","isLane"];case"connectors":return["parentId"];case"annotation":case"annotations":return["nodeId"];case"shape":return["hasHeader"];case"layers":return["objectZIndex"]}return[]}(e),u=0,f=l=l.concat(d);u0&&(e=r),r=Math.floor(Poe(e,i)),s=Bc(o+=n.substr(e,r),t)}while(s<=t.width);for(o=o.substr(0,e),a=e;a=t.width){n=n.substr(0,o.length-1);break}return"Ellipsis"===t.textOverflow?(n=n.substr(0,n.length-3),n+="..."):n=n.substr(0,n.length),n}function MT(n,t){if("NoWrap"===t&&"PreserveAll"===n)return"pre";var e="";switch(n){case"CollapseAll":e="nowrap";break;case"CollapseSpace":e="pre-line";break;case"PreserveAll":e="pre-wrap"}return e}function wT(n,t){var e=Bi();qi(e,t,0,0);var i=Ke(e,{x:0,y:0}),r=Ke(e,{x:n.width,y:0}),s=Ke(e,{x:0,y:n.height}),o=Ke(e,{x:n.width,y:n.height}),a=Math.min(i.x,r.x,s.x,o.x),l=Math.min(i.y,r.y,s.y,o.y),h=Math.max(i.x,r.x,s.x,o.x),c=Math.max(i.y,r.y,s.y,o.y);return new me(h-a,c-l)}function xs(n,t,e,i){if(0!==n){var r=Bi();return qi(r,n,t,e),Ke(r,i)}return i}function Zi(n){return void 0!==n&&"string"==typeof n&&(n=Y(n,window)),n}var bo=function(){function n(){}return n.getContext=function(t){return t.getContext("2d")},n.setCanvasSize=function(t,e,i){t&&(t.setAttribute("width",e.toString()),t.setAttribute("height",i.toString()))},n.prototype.renderGradient=function(t,e,i,r){var s,o,a;if("None"!==t.gradient.type){for(var l=0;l0?(w=0===S.r1?e.arc[parseInt(r.toString(),10)].r1:S.r1,C=0===S.r2?e.arc[parseInt(r.toString(),10)].r2:S.r2,r++):(w=S.r1,C=S.r2);var D=S.angle*(Math.PI/180),A=S.largeArc,x=S.sweep,P={x:u,y:f},L={x:Math.cos(D)*(M.x-P.x)/2+Math.sin(D)*(M.y-P.y)/2,y:-Math.sin(D)*(M.x-P.x)/2+Math.cos(D)*(M.y-P.y)/2},O=Math.pow(L.x,2)/Math.pow(w,2)+Math.pow(L.y,2)/Math.pow(C,2);O>1&&(w*=Math.sqrt(O),C*=Math.sqrt(O));var N=Math.pow(C,2)*Math.pow(L.x,2),T=(A===x?-1:1)*Math.sqrt((Math.pow(w,2)*Math.pow(C,2)-Math.pow(w,2)*Math.pow(L.y,2)-N)/(Math.pow(w,2)*Math.pow(L.y,2)+Math.pow(C,2)*Math.pow(L.x,2)));isNaN(T)&&(T=0);var z={x:T*w*L.y/C,y:T*-C*L.x/w},U={x:(M.x+P.x)/2+Math.cos(D)*z.x-Math.sin(D)*z.y,y:(M.y+P.y)/2+Math.sin(D)*z.x+Math.cos(D)*z.y},B=this.a([1,0],[(L.x-z.x)/w,(L.y-z.y)/C]),j=[(L.x-z.x)/w,(L.y-z.y)/C],Q=[(-L.x-z.x)/w,(-L.y-z.y)/C],oe=this.a(j,Q);this.r(j,Q)<=-1&&(oe=Math.PI),this.r(j,Q)>=1&&(oe=0);var fe=B+oe/2*(x?1:-1);if(Math.cos(fe),Math.sin(fe),S.centp=U,S.xAxisRotation=D,S.rx=w,S.ry=C,S.a1=B,S.ad=oe,S.sweep=x,null!=s){var De=w>C?w:C,xe=w>C?1:w/C,Ie=w>C?C/w:1;s.save(),s.translate(U.x,U.y),s.rotate(D),s.scale(xe,Ie),s.arc(0,0,De,B,B+oe,!x),s.scale(1/xe,1/Ie),s.rotate(-D),s.translate(-U.x,-U.y),s.restore()}break;case"Z":case"z":s.closePath(),u=o,f=a}o=u,a=f}}},n.prototype.drawText=function(t,e,i,r,s,o,a){if(e.content&&!0===e.visible){var l=n.getContext(t);l.save(),this.setStyle(t,e),o&&(e.fontSize*=o),this.applyFlipAndRotate(l,e,t,e.x+e.width*e.pivotX,e.y+e.height*e.pivotY),this.setFontStyle(t,e);var u,d=0;u=e.childNodes;var f=e.wrapBounds;if(l.fillStyle=e.color,f){var p=this.labelAlign(e,f,u);for(d=0;de.width&&"Wrap"!==e.textOverflow&&"NoWrap"===e.textWrapping&&(g.text=qF(g.text,e)),"Clip"!==e.textOverflow&&"Ellipsis"!==e.textOverflow||"Wrap"!==e.textWrapping?l.fillText(g.text,v,y):ya.actualSize.height+a.bounds.y&&(g.text=g.text.slice(0,g.text.length-3),g.text=g.text.concat("...")),l.fillText(g.text,v,y)),"Underline"===e.textDecoration||"Overline"===e.textDecoration||"LineThrough"===e.textDecoration){var M=v,w=void 0,D=v+l.measureText(g.text).width,A=void 0;switch(e.textDecoration){case"Underline":w=y+2,A=y+2;break;case"Overline":w=p.y+g.dy*d,A=p.y+g.dy*d;break;case"LineThrough":w=(y+p.y+g.dy*d)/2+2,A=(y+p.y+g.dy*d)/2+2}l.beginPath(),l.moveTo(M,w),l.lineTo(D,A),l.strokeStyle=e.color,l.lineWidth=.08*e.fontSize,l.globalAlpha=e.opacity,l.stroke()}}}l.restore()}},n.prototype.applyFlipAndRotate=function(t,e,i,r,s){"Horizontal"===e.flip||"Vertical"===e.flip?(t.translate(e.x+e.width/2,e.y+e.height/2),t.rotate(-e.angle*Math.PI/180),t.translate(-e.x-e.width/2,-e.y-e.height/2)):this.rotateContext(i,e.angle,r,s),t.translate(e.x,e.y),"Horizontal"===e.flip?(t.scale(-1,1),t.translate(-1*e.width,0)):"Vertical"===e.flip?(t.scale(1,-1),t.translate(0,-1*e.height)):"Both"===e.flip&&(t.scale(-1,-1),t.translate(-1*e.width,-1*e.height)),t.translate(-e.x,-e.y)},n.prototype.loadImage=function(t,e,i,r,s){var o=new Image;o.src=e.source,this.image(t,o,e.x,e.y,e.width,e.height,e)},n.prototype.drawImage=function(t,e,i,r){var s=this;if(e.visible){var o=n.getContext(t);o.save();var a=e.x+e.width*e.pivotX,l=e.y+e.height*e.pivotY,h=new Image;h.src=e.source,this.setStyle(t,e),o.canvas.id.split("_"),this.applyFlipAndRotate(o,e,t,a,l),r?h.onload=function(){s.loadImage(o,e,t,a,l)}:this.loadImage(o,e,t,a,l),o.restore()}},n.prototype.image=function(t,e,i,r,s,o,a){t.beginPath();var l=e.width,h=e.height,c=s,d=o,u=0,f=0;if(a&&"None"!==a.alignment){var p=a.alignment.toLowerCase().substr(1,3),g=a.alignment.toLowerCase().substr(5,3);if("Slice"===a.scale){var v=function(){u=c,f=h*c/l},y=function(){u=l*d/h,f=d};c>d?(v(),d>f&&y()):c===d?l>h?y():v():(y(),c>u&&v());var S=this.getSliceOffset(p,u,c,l),b=this.getSliceOffset(g,f,d,h),M=l-S,w=h-b,C=u-S*(u/l),D=f-b*(f/h),A=Tt("canvas",{width:s.toString(),height:o.toString()});A.getContext("2d").drawImage(e,S,b,M,w,0,0,C,D),t.drawImage(A,i,r,s,o)}else if("Meet"===a.scale){var P=h/l,L=d/c;f=L>P?c*P:d,i+=this.getMeetOffset(p,u=L>P?c:d/P,c),r+=this.getMeetOffset(g,f,d),t.drawImage(e,0,0,l,h,i,r,u,f)}else t.drawImage(e,i,r,s,o)}else if("None"!==a.flip){var O=1,N=1;("Horizontal"===a.flip||"Both"===a.flip)&&(i=-i,s=-s,O=-1),("Vertical"===a.flip||"Both"===a.flip)&&(r=-r,o=-o,N=-1),t.scale(O,N),t.drawImage(e,i,r,s,o)}else t.drawImage(e,i,r,s,o);t.closePath()},n.prototype.getSliceOffset=function(t,e,i,r){switch(t){case"min":default:return 0;case"mid":return(e-i)/2*r/e;case"max":return(e-i)*r/e}},n.prototype.getMeetOffset=function(t,e,i){var r=Math.max(e,i),s=Math.min(e,i);switch(t){case"min":default:return 0;case"mid":return(r-s)/2;case"max":return r-s}},n.prototype.m=function(t){return Math.sqrt(Math.pow(t[0],2)+Math.pow(t[1],2))},n.prototype.r=function(t,e){return(t[0]*e[0]+t[1]*e[1])/(this.m(t)*this.m(e))},n.prototype.a=function(t,e){return(t[0]*e[1]t.width&&("Ellipsis"===t.textOverflow||"Clip"===t.textOverflow)&&"NoWrap"===t.textWrapping?0:.5*t.width:"right"===t.textAlign&&(c=1*t.width),s.x=t.x+c+(e?e.x:0),s.y=a+d-r.height/2,s},n}(),vb=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Vi=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Roe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return vb(t,n),Vi([I("")],t.prototype,"source",void 0),Vi([I("transparent")],t.prototype,"color",void 0),Vi([I("None")],t.prototype,"scale",void 0),Vi([I("None")],t.prototype,"align",void 0),t}(Ee),Hoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return vb(t,n),Vi([I("Page")],t.prototype,"mode",void 0),Vi([I("PageSettings")],t.prototype,"region",void 0),Vi([re({top:25,bottom:25,left:25,right:25},Jn)],t.prototype,"margin",void 0),Vi([I(!1)],t.prototype,"canZoomIn",void 0),Vi([I(void 0)],t.prototype,"customBounds",void 0),Vi([I(!1)],t.prototype,"canFit",void 0),t}(Ee),Boe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return vb(t,n),Vi([I(null)],t.prototype,"width",void 0),Vi([I(null)],t.prototype,"height",void 0),Vi([re({},Jn)],t.prototype,"margin",void 0),Vi([I("Landscape")],t.prototype,"orientation",void 0),Vi([I("Infinity")],t.prototype,"boundaryConstraints",void 0),Vi([re({},Roe)],t.prototype,"background",void 0),Vi([I(!1)],t.prototype,"multiplePage",void 0),Vi([I(!1)],t.prototype,"showPageBreaks",void 0),Vi([re({},Hoe)],t.prototype,"fitOptions",void 0),t}(Ee),Foe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return vb(t,n),Vi([I(0)],t.prototype,"horizontalOffset",void 0),Vi([I(0)],t.prototype,"verticalOffset",void 0),Vi([I(1)],t.prototype,"currentZoom",void 0),Vi([I(0)],t.prototype,"viewPortWidth",void 0),Vi([I(0)],t.prototype,"viewPortHeight",void 0),Vi([I(.2)],t.prototype,"minZoom",void 0),Vi([I(30)],t.prototype,"maxZoom",void 0),Vi([I("Diagram")],t.prototype,"scrollLimit",void 0),Vi([I()],t.prototype,"scrollableArea",void 0),Vi([I(!1)],t.prototype,"canAutoScroll",void 0),Vi([I(100)],t.prototype,"autoScrollFrequency",void 0),Vi([re({left:15,right:15,top:15,bottom:15},Jn)],t.prototype,"autoScrollBorder",void 0),Vi([re({left:0,right:0,top:0,bottom:0},Jn)],t.prototype,"padding",void 0),Vi([I(.2)],t.prototype,"zoomFactor",void 0),t}(Ee),_oe=function(){function n(){this.services={}}return n.prototype.register=function(t,e){this.services[""+t]=e},n.prototype.getService=function(t){return this.services[""+t]},n}(),$F=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),ya=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},ZF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return $F(t,n),ya([I("lightgray")],t.prototype,"lineColor",void 0),ya([I("")],t.prototype,"lineDashArray",void 0),ya([I([1.25,18.75,.25,19.75,.25,19.75,.25,19.75,.25,19.75])],t.prototype,"lineIntervals",void 0),ya([I([1,19,.5,19.5,.5,19.5,.5,19.5,.5,19.5])],t.prototype,"dotIntervals",void 0),ya([I([20])],t.prototype,"snapIntervals",void 0),t}(Ee),Uoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return $F(t,n),ya([re({},ZF)],t.prototype,"horizontalGridlines",void 0),ya([re({},ZF)],t.prototype,"verticalGridlines",void 0),ya([I(Kt.All)],t.prototype,"constraints",void 0),ya([I(5)],t.prototype,"snapAngle",void 0),ya([I("Lines")],t.prototype,"gridType",void 0),ya([I(5)],t.prototype,"snapObjectDistance",void 0),ya([I("#07EDE1")],t.prototype,"snapLineColor",void 0),t}(Ee),JF=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),el=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},KF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return JF(t,n),el([I(5)],t.prototype,"interval",void 0),el([I(100)],t.prototype,"segmentWidth",void 0),el([I("Horizontal")],t.prototype,"orientation",void 0),el([I("RightOrBottom")],t.prototype,"tickAlignment",void 0),el([I("red")],t.prototype,"markerColor",void 0),el([I(25)],t.prototype,"thickness",void 0),el([I(null)],t.prototype,"arrangeTick",void 0),t}(Ee),joe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return JF(t,n),el([I(!1)],t.prototype,"showRulers",void 0),el([I(!0)],t.prototype,"dynamicGrid",void 0),el([re({orientation:"Horizontal"},KF)],t.prototype,"horizontalRuler",void 0),el([re({orientation:"Vertical"},KF)],t.prototype,"verticalRuler",void 0),t}(Ee),Voe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),e_=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Woe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Voe(t,n),e_([I("")],t.prototype,"property",void 0),e_([I("")],t.prototype,"field",void 0),t}(Ee),CT=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),ln=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},t_=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return CT(t,n),ln([I("")],t.prototype,"read",void 0),ln([I("")],t.prototype,"create",void 0),ln([I("")],t.prototype,"update",void 0),ln([I("")],t.prototype,"destroy",void 0),ln([I()],t.prototype,"customFields",void 0),t}(Ee),Yoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return CT(t,n),ln([I("")],t.prototype,"id",void 0),ln([I("")],t.prototype,"sourceID",void 0),ln([I("")],t.prototype,"targetID",void 0),ln([I(null)],t.prototype,"sourcePointX",void 0),ln([I(null)],t.prototype,"sourcePointY",void 0),ln([I(null)],t.prototype,"targetPointX",void 0),ln([I(null)],t.prototype,"targetPointY",void 0),ln([I(null)],t.prototype,"dataManager",void 0),ln([re({},t_)],t.prototype,"crudAction",void 0),t}(Ee),Qoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return CT(t,n),ln([I("")],t.prototype,"id",void 0),ln([I(null)],t.prototype,"dataManager",void 0),ln([I(null)],t.prototype,"dataSource",void 0),ln([I("")],t.prototype,"root",void 0),ln([I("")],t.prototype,"parentId",void 0),ln([I()],t.prototype,"doBinding",void 0),ln([Bt([],Woe)],t.prototype,"dataMapSettings",void 0),ln([re({},t_)],t.prototype,"crudAction",void 0),ln([re({},Yoe)],t.prototype,"connectionDataSource",void 0),t}(Ee),i_=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Cr=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Goe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return i_(t,n),Cr([I("LeftInFlow")],t.prototype,"yesBranchDirection",void 0),Cr([I("RightInFlow")],t.prototype,"noBranchDirection",void 0),Cr([I(["Yes","True"])],t.prototype,"yesBranchValues",void 0),Cr([I(["No","False"])],t.prototype,"noBranchValues",void 0),t}(Ee),Xoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return i_(t,n),Cr([I("")],t.prototype,"fixedNode",void 0),Cr([I(30)],t.prototype,"horizontalSpacing",void 0),Cr([I("SamePoint")],t.prototype,"connectionPointOrigin",void 0),Cr([I("Nonlinear")],t.prototype,"arrangement",void 0),Cr([I(30)],t.prototype,"verticalSpacing",void 0),Cr([I(30)],t.prototype,"maxIteration",void 0),Cr([I(40)],t.prototype,"springFactor",void 0),Cr([I(50)],t.prototype,"springLength",void 0),Cr([re({left:50,top:50,right:0,bottom:0},Jn)],t.prototype,"margin",void 0),Cr([I("Auto")],t.prototype,"horizontalAlignment",void 0),Cr([I("Auto")],t.prototype,"verticalAlignment",void 0),Cr([I("TopToBottom")],t.prototype,"orientation",void 0),Cr([I("Auto")],t.prototype,"connectionDirection",void 0),Cr([I("Default")],t.prototype,"connectorSegments",void 0),Cr([I("None")],t.prototype,"type",void 0),Cr([I()],t.prototype,"getLayoutInfo",void 0),Cr([I()],t.prototype,"layoutInfo",void 0),Cr([I()],t.prototype,"getBranch",void 0),Cr([I()],t.prototype,"bounds",void 0),Cr([I(!0)],t.prototype,"enableAnimation",void 0),Cr([I(!1)],t.prototype,"enableRouting",void 0),Cr([I("")],t.prototype,"root",void 0),Cr([re({},Goe)],t.prototype,"flowchartLayoutSettings",void 0),t}(Ee),qoe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),r_=function(n){function t(e,i){var r=n.call(this,e,!0)||this;return r.oldValue=null,r.endPoint=i,r}return qoe(t,n),t.prototype.mouseDown=function(e){var i,r=!0;if(e.source&&e.source.connectors&&(i=e.source.connectors[0]),e.info&&e.actualObject&&(r=e.info.ctrlKey&&"Orthogonal"!==e.actualObject.type),i&&r){this.inAction=!0,this.undoElement=$(e.source),n.prototype.mouseDown.call(this,e);for(var s=0;s0)1!==s&&this.removePrevSegment(i,s);else if(a){var l=R.distancePoints(a.points[0],a.points[1]);Math.abs(a.length||0===a.length?a.length:l)<=5&&this.removeNextSegment(i,s)}this.commandHandler.updateEndPoint(i,r),i.selectedSegmentIndex=0}if(this.undoElement){var c=$(e.source);this.commandHandler.addHistoryEntry({type:"SegmentChanged",redoObject:c,undoObject:this.undoElement,category:"Internal"})}if(i.isBezierEditing&&(i.isBezierEditing=!1),this.prevPosition!==this.startPosition){var u={source:i,state:"Completed",oldValue:this.oldValue,newValue:$(this.selectedSegment),cancel:!1,segment:this.selectedSegment};this.commandHandler.triggerEvent(Ce.segmentChange,u)}n.prototype.mouseUp.call(this,e)},t.prototype.removePrevSegment=function(e,i){var r=e.segments[i-2],s=e.segments[i+1];if(s&&!((s.length||0===s.length?s.length:R.distancePoints(s.points[0],s.points[1]))<=5)){var a=e.segments.slice(i-1,i+1),l={element:e,removeSegments:a,type:"Removal",cancel:!1};if(this.commandHandler.triggerEvent(Ce.segmentCollectionChange,l),!l.cancel){var h=e.segments[i+1];e.segments.splice(i-1,2);var c=this.selectedSegment;"Left"===c.direction||"Right"===c.direction?(r.points[r.points.length-1].x=h.points[0].x,h.points[0].y=r.points[r.points.length-1].y):(r.points[r.points.length-1].y=h.points[0].y,h.points[0].x=r.points[r.points.length-1].x),(c.length||0===c.length)&&this.findSegmentDirection(r),this.findSegmentDirection(h)}}},t.prototype.findSegmentDirection=function(e){e.direction&&(e.length||0===e.length)&&(e.length=R.distancePoints(e.points[0],e.points[e.points.length-1]),e.direction=R.direction(e.points[0],e.points[e.points.length-1]))},t.prototype.removeNextSegment=function(e,i){var l,h,r=this.selectedSegment,s=e.segments[i-1],o=e.segments[i+2],a=e.segments[i+1];if(a.length||0===a.length?(l=e.segments.slice(i,2),h={element:e,removeSegments:l,type:"Removal",cancel:!1},this.commandHandler.triggerEvent(Ce.segmentCollectionChange,h={element:e,removeSegments:l,type:"Removal",cancel:!1}),h.cancel||(e.segments.splice(i,2),"Top"===r.direction||"Bottom"===r.direction?(o.points[0].y=r.points[0].y,s.points[s.points.length-1].x=o.points[0].x):(o.points[0].x=r.points[0].x,s.points[s.points.length-1].y=o.points[0].y))):(l=e.segments.slice(i+1,1),this.commandHandler.triggerEvent(Ce.segmentCollectionChange,h={element:e,removeSegments:l,type:"Removal",cancel:!1}),h.cancel||(e.segments.splice(i+1,1),"Top"===r.direction||"Bottom"===r.direction?s.points[s.points.length-1].x=a.points[a.points.length-1].x:s.points[s.points.length-1].y=a.points[a.points.length-1].y,this.findSegmentDirection(s),r.length=r.direction=null)),s&&o&&!h.cancel&&(s.length=R.distancePoints(s.points[0],o.points[0]),s.direction=R.direction(s.points[0],o.points[0]),o.length||0===o.length)){o.length=R.distancePoints(s.points[s.points.length-1],o.points[o.points.length-1]);var c=s.points,d=o.points;o.direction=R.direction(c[c.length-1],d[d.length-1])}},t.prototype.addOrRemoveSegment=function(e,i,r){for(var s,o,a=[],l={segments:e.segments},h=0;h0?"Bottom":"Top":r>0?"Right":"Left",length:i.points[0].x===i.points[1].x?s:r},!0)),l.push(new wi(e,"segments",{type:"Orthogonal",direction:c,length:h/2},!0));var f={element:e,addSegments:l,type:"Addition",cancel:!1};return this.commandHandler.triggerEvent(Ce.segmentCollectionChange,f),f.cancel||(e.segments=l.concat(e.segments),a=o+2),a},t.prototype.insertFirstSegment=function(e,i,r,s,o){var a,l,d,u,h=[];if(e.sourcePortID&&i.length&&e.segments[0].points.length>2)for(var f=void 0,p=0;p0?"Bottom":"Top":r>0?"Right":"Left"),f=u,h.push(u)}else h.push(new wi(e,"segments",{type:"Orthogonal",direction:i.direction,length:i.length/3},!0)),"Bottom"===i.direction||"Top"===i.direction?(l=Math.abs(r),a=r>0?"Right":"Left"):(l=Math.abs(s),a=s>0?"Bottom":"Top"),u=new wi(e,"segments",{type:"Orthogonal",direction:a,length:l},!0),h.push(u);var y={element:e,addSegments:h,type:"Addition",cancel:!1};if(this.commandHandler.triggerEvent(Ce.segmentCollectionChange,y),!y.cancel){if(e.sourcePortID&&i.length&&e.segments[0].points.length>2)e.segments.splice(0,1),d=1;else{var S=e.segments[1];S&&S.length&&(S.length=a!==S.direction?S.length+l:S.length-l),d=2,i.length=2*i.length/3}e.segments=h.concat(e.segments)}return d},t.prototype.updateAdjacentSegments=function(e,i,r,s){var o=e.segments[parseInt(i.toString(),10)],a=o.points[o.points.length-1],h=!0;"Orthogonal"===o.type&&(o.points[0]=o.points[0],o.points[o.points.length-1]=a,e.segments[i-1]&&(h=this.updatePreviousSegment(r,s,e,i)),e.segments.length-1>i&&h&&this.updateNextSegment(e,o,e.segments[i+1],r,s))},t.prototype.addTerminalSegment=function(e,i,r,s,o){var l,h,c,d,a=e.segments.indexOf(i),u=[],f=e.segments.pop(),p=e.segments[e.segments.length-1];l=p&&"Orthogonal"===p.type?p:null;for(var g=0;g0&&"Left"===o.direction?c.middleLeft:c.middleRight,o.length>c.width/2?Math.abs(a.length)0&&"Top"===o.direction?c.topCenter:c.bottomCenter,o.length>c.height/2?Math.abs(a.length)1)for(var a=0,l=this.diagram.views;a0)for(var e=t===Ce.onUserHandleMouseLeave?this.previousAction:this.action,i={element:void 0},r=0;r0)for(var r={element:void 0},s=void 0,o=void 0,a=0;a-1&&(o=s,this.previousTarget=i,this.targetItem=e),o===e.fixedUserHandles[parseInt(a.toString(),10)].id&&(r.element=e.fixedUserHandles[parseInt(a.toString(),10)],this.userHandle(t,a,r,e))},n.prototype.mouseDown=function(t){var e=this;if("touchstart"===t.type&&(this.timeOutTapHold=setTimeout(function(){("Select"===e.action||"Drag"===e.action)&&e.mouseMove(t,void 0)},500)),!0!==this.inAction||!(this.tool instanceof qI||this.tool instanceof pa)){this.focus=!0;var i=t.touches,r=!!document.getElementsByClassName("e-dragclone")[0];if(this.isMouseOnScrollBar(t)&&!r)return this.isScrolling=!0,void t.preventDefault();if(this.checkFixedUserHandleEvent(Ce.onFixedUserHandleMouseDown,this.targetItem,this.previousTarget),this.checkUserHandleEvent(Ce.onUserHandleMouseDown),!this.checkEditBoxAsTarget(t)&&Yv(this.diagram)||Lc(this.diagram)&&!UI(this.diagram))if(("Select"===this.action||"Drag"===this.action)&&this.diagram.updatePortVisibility(this.hoverElement,ci.Hover,!0),!(this.tool instanceof Rl||this.tool instanceof Hl)||2!==t.button&&2!==t.buttons)if(!0===this.inAction&&!0===this.isMouseDown&&(this.tool instanceof Rl||this.tool instanceof Hl))this.isMouseDown=!0,this.eventArgs={},this.getMouseEventArgs(this.currentPosition,this.eventArgs),this.eventArgs.position=this.currentPosition,this.tool.mouseDown(this.eventArgs);else{this.isMouseDown=!0,this.currentPosition=this.prevPosition=this.getMousePosition(t),this.eventArgs={},this.diagram.textEditing&&!this.isMouseOnScrollBar(t)&&(this.diagram.endEdit(),this.diagram.textEditing=!1,"Canvas"===this.diagram.mode&&1!==this.diagram.scroller.currentZoom&&this.diagram.refreshDiagramLayer());var o=this.getTargetElement();this.action=this.diagram.findActionToBeDone(o.obj,o.sourceElement,this.currentPosition,o.target);var a=this.isMetaKey(t);a&&t.shiftKey&&this.diagram.connectorEditingToolModule?this.action="SegmentEnd":(a||t.shiftKey)&&(Vv(this.diagram)||Wv(this.diagram))&&(this.action="Select"),this.tool=this.diagram.getTool(this.action),this.tool||(this.action="Select",this.tool=this.diagram.getTool(this.action)),this.getMouseEventArgs(this.currentPosition,this.eventArgs),(a||t.shiftKey)&&(this.eventArgs.info=a&&t.shiftKey?{ctrlKey:a,shiftKey:t.shiftKey}:{ctrlKey:!0}),this.eventArgs.position=this.currentPosition;var h=this.diagram.selectedItems.nodes;if(this.tool.mouseDown(this.eventArgs),this.diagram.selectedItems.canToggleSelection&&h&&this.diagram.selectedItems.nodes&&this.tool instanceof fa)for(var c=0;c=2&&(this.touchStartList=VF(this.touchStartList,0,i)),i||t.preventDefault())}else this.inAction=!1,this.tool.mouseUp(this.eventArgs);!this.isForeignObject(t.target)&&!this.isForeignObject(t.target,!0)&&!i&&t.preventDefault()}},n.prototype.mouseMoveExtend=function(t,e){(this.tool instanceof Rl||this.tool instanceof Hl)&&this.tool.mouseMove(this.eventArgs),this.diagram.scrollSettings.canAutoScroll?this.checkAutoScroll(t):this.blocked||this.tool.mouseMove(this.eventArgs),this.eventArgs.target&&(this.hoverElement=this.eventArgs.target);var i=!((this.eventArgs.target instanceof te||this.eventArgs.target instanceof de)&&(e instanceof te||e instanceof de));this.tool instanceof zd&&this.diagram.updatePortVisibility(this.hoverElement instanceof te||this.hoverElement instanceof de?this.hoverElement:this.hoverNode,ci.Connect|ci.Hover,i),this.hoverElement instanceof te&&this.hoverNode instanceof te&&this.hoverNode&&this.hoverNode.id!==this.hoverElement.id&&this.diagram.updatePortVisibility(this.hoverNode,ci.Connect|ci.Hover,!0),this.hoverElement instanceof de&&this.hoverElement.ports.length>0&&this.diagram.updatePortVisibility(this.hoverElement,ci.Connect|ci.Hover,!0),this.previousElement instanceof te&&this.hoverElement&&this.previousElement.id!==this.hoverElement.id&&this.diagram.updatePortVisibility(this.previousElement,ci.Connect|ci.Hover,!0),this.previousElement=this.hoverElement,""!==this.diagram.tooltip.content&&(this.hoverElement=null),this.hoverNode=i?null:e},n.prototype.checkAction=function(t){if("LabelSelect"===this.action&&this.eventArgs.sourceWrapper&&(this.eventArgs.sourceWrapper instanceof ai||this.eventArgs.sourceWrapper instanceof es)){var e=this.commandHandler.findTarget(this.eventArgs.sourceWrapper,this.eventArgs.source);!_r(this.diagram,e,!1,this.eventArgs.sourceWrapper)&&ro(e)&&(this.action="LabelDrag",this.tool=this.getTool(this.action),this.tool.mouseDown(this.initialEventArgs))}else ro(t)&&Ad(t)&&this.initialEventArgs&&this.initialEventArgs.source&&"Select"===this.action&&(!_r(this.diagram,this.eventArgs.source,!1)&&this.eventArgs.source instanceof ei&&this.getMouseEventArgs(this.currentPosition,this.eventArgs),(!(t instanceof de)||t instanceof de&&!(wr(this.currentPosition,t.sourcePoint,t.hitPadding)||wr(this.currentPosition,t.targetPoint,t.hitPadding)))&&(this.action="Drag"),this.tool=this.getTool(this.action),this.tool.mouseDown(this.initialEventArgs))},n.prototype.isSwimlaneElements=function(t){return!(t&&(t.isLane||t.isPhase||t.isHeader))},n.prototype.canShowTouchTooltip=function(t){return!!("touchstart"===t.type&&this.diagram.tool&ri.SingleSelect&&this.diagram.tool&ri.ZoomPan)&&(this.isMouseDown=!1,!0)},n.prototype.mouseMove=function(t,e){if(this.focus=!0,"touchmove"===t.type&&(this.touchArgs={target:t.target,type:"touchmove"}),this.isScrolling)t.preventDefault();else if(Yv(this.diagram)||Lc(this.diagram)&&!UI(this.diagram)){this.currentPosition=this.getMousePosition(t);var i=this.diagram.findObjectsUnderMouse(this.currentPosition),r=this.diagram.findObjectUnderMouse(i,this.action,this.inAction);!function nse(n,t){n.rulerSettings.showRulers&&(n.hRuler.drawRulerMarker(n.hRuler.element,t,n.scroller.horizontalOffset),n.vRuler.drawRulerMarker(n.vRuler.element,t,n.scroller.verticalOffset))}(this.diagram,this.currentPosition);var s=!1,o=void 0;if("touchmove"===t.type&&(e=t.touches)&&e.length>1&&(this.touchMoveList=VF(this.touchMoveList,0,e),"PinchZoom"!==this.action&&(s=!0)),!1===R.equals(this.currentPosition,this.prevPosition)||this.inAction||this.canShowTouchTooltip(t)){if(!1===this.isMouseDown||s){this.eventArgs={};var a=null,l=void 0;if(null!==r){if((a=this.diagram.findElementUnderMouse(r,this.currentPosition,this.diagram))&&(l=this.commandHandler.findTarget(a,r)),(l instanceof Kn||l instanceof Or)&&(l.tooltip&&""!==l.tooltip.content||(l=r)),l!==this.hoverElement){var h=this.getContent();this.hoverElement&&"Auto"===this.hoverElement.tooltip.openOn&&""!==h&&this.elementLeave(),this.diagram.updatePortVisibility(this.hoverElement,ci.Hover,!0),r instanceof te&&(this.hoverNode=r);var c=!0;!this.isSwimlaneElements(r)&&this.hoverElement&&this.isSwimlaneElements(this.hoverElement)&&(c=!1),this.hoverElement=c?r:this.hoverElement;var d,u=void 0;(d=this.diagram.findElementUnderMouse(r,this.currentPosition,this.diagram))instanceof Ze&&((u=this.commandHandler.findTarget(d,r))instanceof Es||u instanceof Tc)&&this.hoverElement.constraints&oi.ToolTip&&(this.hoverElement=u);var f=void 0;d instanceof ai&&((f=this.commandHandler.findTarget(d,r))instanceof Kn||f instanceof Or)&&f.constraints&Nr.Tooltip&&(this.hoverElement=f),c?this.elementEnter(this.currentPosition,!1):this.hoverElement=r}else this.hoverElement&&this.hoverElement===l&&this.hoverElement.tooltip.content&&void 0!==this.diagram.tooltipObject&&"Mouse"===this.hoverElement.tooltip.relativeMode&&this.setTooltipOffset(this.currentPosition);a&&(o=this.commandHandler.findTarget(a,r))}this.action=this.diagram.findActionToBeDone(r,a,this.currentPosition,o),this.checkFixedUserHandleEvent(Ce.onFixedUserHandleMouseEnter,r,a),this.checkUserHandleEvent(Ce.onUserHandleMouseEnter),this.checkPreviousAction(),this.getMouseEventArgs(this.currentPosition,this.eventArgs),this.tool=this.getTool(this.action),this.mouseEvents(),this.tool instanceof pa||this.tool instanceof Hl||this.tool instanceof Rl?this.tool.mouseMove(this.eventArgs):e&&this.tool instanceof im&&this.tool.mouseDown(this.eventArgs),this.updateCursor(),this.renderUmlHighLighter(this.eventArgs);var p=!1;this.hoverElement&&!(this.tool instanceof im)&&r instanceof te&&this.isSwimlaneElements(r)&&(0===this.diagram.selectedItems.nodes.length||!_r(this.diagram,this.hoverElement))||this.hoverElement instanceof de||(p=!0),this.hoverElement&&!(this.tool instanceof im)&&r instanceof de&&(0===this.diagram.selectedItems.connectors.length||!_r(this.diagram,this.hoverElement))||this.hoverElement instanceof te||(p=!0),this.diagram.updatePortVisibility(this.hoverElement,ci.Hover,p);var g=this.getContent();null===r&&this.hoverElement&&"Auto"===this.hoverElement.tooltip.openOn&&g&&(this.hoverElement=null,this.elementLeave()),s=!1}else{this.eventArgs.position=this.currentPosition,"Drag"===this.action&&!_r(this.diagram,this.eventArgs.source,!1)&&this.eventArgs.source instanceof ei&&this.getMouseEventArgs(this.currentPosition,this.eventArgs),this.mouseEvents(),(t.ctrlKey||t.shiftKey)&&(this.eventArgs.info=t.ctrlKey&&t.shiftKey?{ctrlKey:t.ctrlKey,shiftKey:t.shiftKey}:{ctrlKey:!0}),this.checkAction(r);var y=this.getConnectorPadding(this.eventArgs);this.getMouseEventArgs(this.currentPosition,this.eventArgs,this.eventArgs.source,y),this.updateCursor(),this.inAction=!0,this.initialEventArgs=null,("Drag"===this.action||"Rotate"===this.action)&&(this.diagram.diagramActions=this.diagram.diagramActions|ee.Interactions);var S=this.diagram.scroller.getPageBounds();this.mouseMoveExtend(t,r);var b=this.diagram.scroller.getPageBounds();if(r&&(S.width!==b.width||S.height!==b.height||S.x!==b.x||S.y!==b.y)&&this.diagram.views&&this.diagram.views.overview){var M=this.diagram.views.overview;M.updateView(M)}}this.prevPosition=this.currentPosition,this.isForeignObject(t.target,!0)||t.preventDefault()}}},n.prototype.getContent=function(){var i,t=this.hoverElement instanceof te&&this.hoverElement.constraints&ie.Tooltip||this.hoverElement instanceof de&&this.hoverElement.constraints&qe.Tooltip||(this.hoverElement instanceof Es||this.hoverElement instanceof Tc)&&this.hoverElement.constraints&oi.ToolTip||(this.hoverElement instanceof Kn||this.hoverElement instanceof Or)&&this.hoverElement.constraints&Nr.Tooltip,e=this.hoverElement;e instanceof te&&e.children&&e.children.length>0&&(i=this.findIntersectChild(e));var r=t?this.hoverElement.tooltip.content:this.diagram.tooltip.content;return i?i.tooltip.content:r},n.prototype.findIntersectChild=function(t){for(var e,i=new Ne(this.currentPosition.x,this.currentPosition.y,8,8),r=0;r1&&1===t.which&&!function one(n){return!!(n&ee.PreventClearSelection)}(this.diagram.diagramActions)&&(c=!1,this.commandHandler.clearSelection()),(!_r(this.diagram,h)||!c)&&(this.commandHandler.selectObjects([h],void 0,a),this.diagram.selectedItems.canToggleSelection)){var d=this.diagram.selectedItems.nodes;d?d[0].parentObj instanceof Fd&&(s=!0):this.diagram.selectedItems.connectors.length>0&&(s=!0)}}var u=!1,f=this.updateContainerProperties(),p=void 0;if(this.addUmlNode(),this.inAction=!1,this.isMouseDown=!1,this.diagram.selectedObject.helperObject&&(p=this.updateContainerBounds()),this.tool&&(this.tool.prevPosition||this.tool instanceof eF)){this.eventArgs.position=this.currentPosition;var g=this.getConnectorPadding(this.eventArgs);this.getMouseEventArgs(this.currentPosition,this.eventArgs,this.eventArgs.source,g);var v=this.isMetaKey(t);if((v||t.shiftKey)&&(this.eventArgs.info=v&&t.shiftKey?{ctrlKey:v,shiftKey:t.shiftKey}:{ctrlKey:!0}),this.diagram.diagramActions&ee.Interactions&&(this.diagram.diagramActions=this.diagram.diagramActions&~ee.Interactions),this.eventArgs.clickCount=t.detail,this.diagram.selectedObject.helperObject&&(this.tool instanceof fa||this.tool instanceof Rd)){if(this.diagram.selectedObject.actualObject&&""!==this.diagram.selectedObject.actualObject.parentId){var S=this.diagram.getObject(this.diagram.selectedObject.actualObject.parentId);S&&S.isLane&&(this.commandHandler.isContainer=!0)}(u=this.diagram.lineRoutingModule&&this.diagram.nameTable.helper&&this.eventArgs.target&&this.eventArgs.target.isLane&&(this.eventArgs.source instanceof ei&&this.eventArgs.source.nodes.length>0&&""===this.eventArgs.source.nodes[0].parentId||""===this.eventArgs.source.parentId))&&(this.diagram.diagramActions=this.diagram.diagramActions|ee.PreventLaneContainerUpdate),this.tool.mouseUp(this.eventArgs,f.isPreventHistory)}else{if(this.diagram.selectedItems.canToggleSelection){var b=void 0,M=void 0;if(this.diagram.selectedItems.nodes.length>0)for(var w=0;w1&&D[0].id===i[parseInt(w.toString(),10)].id||r.length>0)&&(M=!0);!this.isSwimlaneSelected&&!s&&!M&&this.tool instanceof fa&&"Select"===this.currentAction&&(!b||this.diagram.selectedItems.connectors.length>0)&&this.commandHandler.clearSelection(!0)}this.isSwimlaneSelected=!1,this.tool.mouseUp(this.eventArgs),this.diagram.checkMenu&&(-1!==window.navigator.userAgent.indexOf("Linux")||-1!==window.navigator.userAgent.indexOf("X11"))&&(!t.pageY&&t instanceof TouchEvent&&t.changedTouches?(window.getSelection().removeAllRanges(),this.diagram.contextMenuModule.contextMenu.open(t.changedTouches[0].pageY,t.changedTouches[0].pageX,this.diagram.element),t.preventDefault()):this.diagram.contextMenuModule.contextMenu.open(t.pageY,t.pageX,this.diagram.element),this.diagram.checkMenu=!1)}f.hasStack&&this.diagram.endGroupAction()}if(p&&this.diagram.endGroupAction(),this.updateContainerBounds(!0),2!==this.eventArgs.clickCount&&(this.commandHandler.updateSelectedNodeProperties(this.eventArgs.source),u)){this.diagram.diagramActions=this.diagram.diagramActions&~ee.PreventLaneContainerUpdate;var A=this.eventArgs.source instanceof ei?this.eventArgs.source.nodes:[this.eventArgs.source];if(A)for(w=0;w0&&!N&&this.diagram.renderSelector(!0),!this.inAction&&!this.diagram.currentSymbol&&this.eventArgs){var T=this.getTargetElement();this.diagram.tool!==ri.ZoomPan&&this.diagram.triggerEvent(Ce.click,{element:T.target instanceof Es?T.target:this.eventArgs.source||this.diagram,position:this.eventArgs.position,count:t.detail,actualObject:this.eventArgs.actualObject,button:0===t.button?"Left":1===t.button?"Middle":"Right"})}this.eventArgs={}}this.diagram.diagramActions=this.diagram.diagramActions&~ee.PreventLaneContainerUpdate,e&&this.updateAnnotation(this.diagram.selectedItems),this.previousElement=null,this.eventArgs={},this.diagram.commandHandler.removeStackHighlighter()},n.prototype.isSwimlaneChild=function(t){if(t.shape&&"SwimLane"!==t.shape.type){var e=this.diagram.nameTable[t.parentId];if(!e)return!1;var i=e.parentId?this.diagram.nameTable[e.parentId]:e;return i&&i.shape&&"SwimLane"===i.shape.type}return!1},n.prototype.updateAnnotation=function(t){var e=t.nodes;if(e.length>0)for(var i=0;i0&&(a+=1),h.isPhase){l="Horizontal"===r.orientation?this.currentPosition.x-e.wrapper.bounds.x:this.currentPosition.y-(e.wrapper.bounds.y+r.header.height);var g={id:Qe(),offset:l,header:{annotation:{content:void 0===h.phases[0].header?"Phase":h.phases[0].header.annotation.content,style:void 0===h.phases[0].header?{}:h.phases[0].header.annotation.style}},style:void 0===h.phases[0]?{}:h.phases[0].style};this.diagram.addPhases(e,[g])}else{var v={id:Qe(),style:h.lanes[0].style,header:{annotation:{content:h.lanes[0].header.annotation.content,style:h.lanes[0].header.annotation.style},style:h.lanes[0].header.style}};if("Horizontal"===h.orientation?v.height=h.lanes[0].height:v.width=h.lanes[0].width,"Horizontal"===r.orientation?(s=i.rowIndex?i.rowIndex:this.diagram.nameTable[i.parentId].rowIndex,i.wrapper.offsetYs)v.header.width=r.lanes[parseInt(s.toString(),10)].header.width,v.header.height=r.lanes[parseInt(s.toString(),10)].header.height;else{var S=void 0;S="Horizontal"===r.orientation?i.rowIndex<3?0:s-a-1:s-1,v.header.width=r.lanes[parseInt(S.toString(),10)].header.width,v.header.height=r.lanes[parseInt(S.toString(),10)].header.height}p&&("height"===p?(v.width=v.height,delete v.height):(v.height=v.width,delete v.width)),this.diagram.addLanes(e,[v],"Horizontal"===r.orientation?s-a:s)}this.commandHandler.select(e)}else if(h.isLane){var b={id:Qe(),width:t.width,height:t.height,addInfo:t.addInfo,shape:{type:"SwimLane",header:{annotation:{content:void 0===h.header?"Header":h.header.annotation.content,style:void 0===h.header?{}:h.header.annotation.style},height:50,style:h.header?h.header.style:h.lanes[0].header.style},phases:[{id:Qe(),header:{annotation:{content:void 0===h.phases||void 0===h.phases[0].header?"Phase":h.phases[0].header.annotation.content,style:void 0===h.phases||void 0===h.phases[0].header?{}:h.phases[0].header.annotation.style},style:void 0===h.phases||void 0===h.phases[0].header?{}:h.phases[0].header.style},style:void 0===h.phases?{}:h.phases[0].style}],lanes:[{id:Qe(),height:t.height,width:t.width,style:h.lanes[0].style,header:{annotation:{content:h.lanes[0].header.annotation.content,style:h.lanes[0].header.annotation.style},style:h.lanes[0].header.style}}],orientation:h.orientation}};"Vertical"===h.orientation&&(b.width+=20),b.offsetX=this.currentPosition.x+b.width/2,b.offsetY=this.currentPosition.y+b.height/2,b.style=t.style,this.diagram.add(b)}},n.prototype.mouseLeave=function(t){this.tool&&this.inAction&&this.tool.mouseLeave(this.eventArgs),this.diagram.selectedObject.helperObject&&(this.updateContainerProperties(),this.updateContainerBounds()&&this.diagram.endGroupAction()),this.eventArgs&&this.eventArgs.source&&(this.diagram.updatePortVisibility(this.eventArgs.source,ci.Hover,!0),this.hoverElement=null),this.eventArgs&&!this.eventArgs.source&&this.hoverElement&&(this.hoverElement=null),this.tool instanceof zd&&this.eventArgs&&this.eventArgs.target&&this.eventArgs.target instanceof te&&(this.diagram.updatePortVisibility(this.eventArgs.target,ci.Hover|ci.Connect,!0),this.hoverElement=null);var i=this.diagram.selectedItems;i&&i.wrapper&&(cm(this.diagram,i)||this.diagram.renderSelector(!0)),(this.diagram.diagramActions&ee.Interactions||this.diagram.diagramActions&ee.ToolAction)&&(this.diagram.diagramActions=this.diagram.diagramActions&~ee.ToolAction),this.isMouseDown=!1,this.focus=!1,this.touchStartList=null,this.touchMoveList=null,this.elementLeave(),this.commandHandler.removeSnap(),this.inAction=!1,this.eventArgs={},this.diagram.selectedObject&&this.diagram.selectedObject.helperObject&&(this.diagram.remove(this.diagram.selectedObject.helperObject),this.diagram.selectedObject={helperObject:void 0,actualObject:void 0}),this.tool=null,function rse(){var t,e,n=document.getElementsByClassName("e-d-ruler-marker");if(n&&n.length>0)for(e=n.length-1;e>=0;e--)(t=n[parseInt(e.toString(),10)])&&t.parentNode.removeChild(t)}(),"Rotate"===this.action&&this.diagram.diagramCanvas.classList.remove("e-diagram-rotate"),t.preventDefault()},n.prototype.mouseWheel=function(t){this.diagram.blazorActions|=on.interaction;var e={event:t,cancel:!1};if(this.diagram.triggerEvent(Ce.mouseWheel,e),!e.cancel){var i=t.wheelDelta>0||-40*t.detail>0,r=this.getMousePosition(t);if(this.diagram.tooltipObject.close(),this.isMetaKey(t)){var o=this.diagram.scrollSettings.zoomFactor;this.diagram.zoomTo(i?{type:"ZoomIn",zoomFactor:o,focusPoint:r}:{type:"ZoomOut",zoomFactor:o,focusPoint:r}),t.preventDefault()}else{var a=this.diagram.scroller.horizontalOffset,l=this.diagram.scroller.verticalOffset,h=i?10:-10;this.tool&&(this.tool instanceof Rl||this.tool instanceof Hl)&&(this.eventArgs={},this.getMouseEventArgs(r,this.eventArgs),this.eventArgs.position=r,this.tool.mouseWheel(this.eventArgs)),this.diagram.scrollActions|=da.Interaction;var c=!0;if(t.isTrusted){var d=!1;(Math.abs(t.deltaY)<100&&-0===Math.abs(t.deltaX)||Math.abs(t.deltaX)<100&&-0===Math.abs(t.deltaY))&&(d=!0);var u=!1;(0!==t.deltaX||0!==t.deltaY)&&(u=navigator.userAgent.includes("Macintosh")),u?Math.abs(t.deltaX)>Math.abs(t.deltaY)?(t.shiftKey||t.deltaX&&-0!==t.deltaX&&(d||!u))&&this.diagram.scroller.zoom(1,h,0,r,c,void 0,d):t.deltaY&&-0!==t.deltaY&&(d||!u)&&this.diagram.scroller.zoom(1,0,h,r,c,void 0,d):t.shiftKey||t.deltaX&&-0!==t.deltaX&&(d||!u)?this.diagram.scroller.zoom(1,h,0,r,c,void 0,d):t.deltaY&&-0!==t.deltaY&&(d||!u)&&this.diagram.scroller.zoom(1,0,h,r,c,void 0,d)}else t.shiftKey||t.deltaX&&-0!==t.deltaX?this.diagram.scroller.zoom(1,h,0,r,c):this.diagram.scroller.zoom(1,0,h,r,c);this.diagram.scrollActions&=~da.Interaction,(a!==this.diagram.scroller.horizontalOffset||l!==this.diagram.scroller.verticalOffset)&&t.preventDefault()}if(this.diagram.textEditing){if(this.diagram.isTriggerEvent=!0,this.diagram.activeLabel.parentId){var p=this.diagram.getObject(this.diagram.activeLabel.parentId);this.diagram.startTextEdit(p,this.diagram.activeLabel.id)}this.diagram.isTriggerEvent=!1}this.diagram.blazorActions=this.diagram.blazorActions&~on.interaction}},n.prototype.keyDown=function(t){if(t.fromMouseEvents&&(t.ctrlKey&&(this.keyArgs.keyModifiers=1),t.shiftKey&&(this.keyArgs.keyModifiers=4),t.shiftKey&&t.ctrlKey&&(this.keyArgs.keyModifiers=5)),!(this.diagram.diagramActions&ee.TextEdit)&&!this.checkEditBoxAsTarget(t)||"Escape"===t.key||27===t.keyCode){var i=void 0,r=t.keyCode?t.keyCode:t.which,s=t.key;("ArrowDown"===s||"ArrowUp"===s||"ArrowLeft"===s||"ArrowRight"===s)&&(this.isNudgeKey=!0);var o=this.isMetaKey(t);if(this.diagram.commandManager&&this.diagram.commands)for(var l=0,h=Object.keys(this.diagram.commands);l4&&(S({keyDownEventArgs:KeyboardEvent,parameter:i.parameter,type:"KEYDOWN"}),this.keyCount=0,this.keyArgs.newValue={offsetX:this.diagram.selectedItems.offsetX,offsetY:this.diagram.selectedItems.offsetY},this.diagram.triggerEvent(Ce.positionChange,this.keyArgs))),this.isKeyUp=!1):S({keyDownEventArgs:KeyboardEvent,parameter:i.parameter})}break}}}}this.keyArgs={element:this.diagram.selectedItems,key:t.key,keyCode:t.keyCode?t.keyCode:t.which},this.getKeyModifier(this.keyArgs,t),this.diagram.diagramActions&ee.TextEdit&&this.getlabel(this.keyArgs,t),this.diagram.triggerEvent(Ce.keyDown,this.keyArgs)},n.prototype.getlabel=function(t,e){var i=this.diagram.activeLabel;t.target=this.diagram.element.id+"_editBox";var r=this.diagram.nameTable[i.parentId];if(document.getElementById(this.diagram.element.id+"_editBox")){t.text=document.getElementById(this.diagram.element.id+"_editBox").value;for(var s=0;s=this.diagram.scroller.viewPortWidth-18?r="right":e.x+this.diagram.scroller.horizontalOffsetthis.diagram.scroller.viewPortHeight-18?r="bottom":e.y+this.diagram.scroller.verticalOffset0&&(s=this.findIntersectChild(this.hoverElement)),"Auto"===this.hoverElement.tooltip.openOn&&""!==r&&Ex(this.diagram,s||(i?this.hoverElement:void 0)),this.hoverElement.tooltip.content&&("Mouse"===this.hoverElement.tooltip.relativeMode?this.setTooltipOffset(t):(this.diagram.tooltipObject.offsetX=0,this.diagram.tooltipObject.offsetY=0));var o=this.diagram.findObjectsUnderMouse(this.currentPosition),a=this.diagram.findObjectUnderMouse(o,this.action,this.inAction);if(null!==a){var l=void 0;this.hoverElement.tooltip.isSticky&&(this.diagram.tooltipObject.isSticky=!0),a instanceof te&&a.children&&a.children.length>0&&(a=s||a),l=a.ports&&(this.hoverElement instanceof Es||this.hoverElement instanceof Tc)||a.annotations&&(this.hoverElement instanceof Kn||this.hoverElement instanceof Or)?document.getElementById(a.id+"_"+this.hoverElement.id):document.getElementById(a.id+(a.shape&&a.shape instanceof dm?"_content_native_element":"_groupElement")),"Auto"===this.hoverElement.tooltip.openOn&&""!==r&&(this.diagram.tooltipObject.close(),this.diagram.tooltipObject.openOn=this.hoverElement.tooltip.openOn,this.diagram.tooltipObject.dataBind()),function Kre(n,t){var e=0;return n instanceof de?n.constraints&qe.Tooltip?e=n.constraints&qe.Tooltip:n.constraints&qe.InheritTooltip&&(e=t.constraints&nt.Tooltip):n instanceof Es||n instanceof Tc?n.constraints&oi.ToolTip?e=n.constraints&oi.ToolTip:n.constraints&oi.InheritTooltip&&(e=t.constraints&nt.Tooltip):n instanceof Kn||n instanceof Or?n.constraints&Nr.Tooltip&&(e=n.constraints&Nr.Tooltip):n.constraints&ie.Tooltip?e=n.constraints&ie.Tooltip:n.constraints&ie.InheritTooltip&&(e=t.constraints&nt.Tooltip),e}(this.hoverElement,this.diagram)&&"Auto"===this.hoverElement.tooltip.openOn&&(this.diagram.tooltipObject.target=this.hoverElement.id,this.diagram.tooltipObject.open("Mouse"===this.hoverElement.tooltip.relativeMode?this.diagram.element:l))}}},n.prototype.elementLeave=function(){this.diagram.tooltipObject&&!this.diagram.tooltipObject.isSticky&&"Custom"!==this.diagram.tooltipObject.openOn&&this.diagram.tooltipObject.close()},n.prototype.setTooltipOffset=function(t){var e=function Mse(n,t,e,i){var o="Mouse"===(!(e instanceof te?e.constraints&ie.InheritTooltip:e instanceof de?e.constraints&qe.InheritTooltip:e.constraints&oi.InheritTooltip)&&(e instanceof te?e.constraints&ie.Tooltip:e instanceof de?e.constraints&qe.Tooltip:e.constraints&oi.ToolTip)?e.tooltip.relativeMode:n.tooltip.relativeMode);"Mouse"===i?o=!0:"Object"===i&&(o=!1);var a=function wse(n,t,e,i){var o,r={},s=document.getElementById(e.element.id);if(n instanceof te||n instanceof de)o=n.wrapper.bounds;else{var a=e.findObjectsUnderMouse(t),l=e.findObjectUnderMouse(a,"Select",!1);o=e.findElementUnderMouse(l,t,e).bounds}var c=s.getBoundingClientRect();switch(e.tooltipObject.position){case"BottomCenter":r=zc(t,o.bottomCenter,e,i,c.width/2,c.height);break;case"BottomLeft":case"LeftBottom":r=zc(t,o.bottomLeft,e,i,0,c.height);break;case"BottomRight":case"RightBottom":r=zc(t,o.bottomRight,e,i,c.width,c.height);break;case"LeftCenter":r=zc(t,o.middleLeft,e,i,0,c.height/2);break;case"LeftTop":case"TopLeft":r=zc(t,o.topLeft,e,i,0,0);break;case"RightCenter":r=zc(t,o.middleRight,e,i,c.width,c.height/2);break;case"RightTop":case"TopRight":r=zc(t,o.topRight,e,i,c.width,0);break;case"TopCenter":r=zc(t,o.topCenter,e,i,c.width/2,0)}return r}(e,t,n,o),l=Za(n);return{x:a.x+l.width,y:a.y+l.height}}(this.diagram,t,this.hoverElement);this.diagram.tooltipObject.offsetX=e.x,this.diagram.tooltipObject.offsetY=e.y},n.prototype.altKeyPressed=function(t){return!!(t&ft.Alt)},n.prototype.ctrlKeyPressed=function(t){return!!(t&ft.Control)},n.prototype.shiftKeyPressed=function(t){return!!(t&ft.Shift)},n.prototype.scrolled=function(t){this.diagram.updateScrollOffset()},n.prototype.isMobileOrIPadDevice=function(){var t=navigator.userAgent||navigator.vendor||window.opera;return/iPhone|iPad|iPod/.test(t)&&!window.MSStream?"iOS":/android/i.test(t)?"Android":/Mobile|Tablet/.test(t)?"Mobile":"Desktop"},n.prototype.doubleClick=function(t){if(Yv(this.diagram)){var e=this.isMobileOrIPadDevice(),i=this.diagram.tool;"Desktop"!==e&&this.tool&&(this.tool instanceof Rl||this.tool instanceof Hl)&&(this.diagram.tool=0);var r=void 0,s=this.diagram.findObjectsUnderMouse(this.currentPosition),o=this.diagram.findObjectUnderMouse(s,this.action,this.inAction);if(null!==o&&Yv(this.diagram))if(r=this.diagram.findElementUnderMouse(o,this.currentPosition,this.diagram),this.tool&&(this.tool instanceof Rl||this.tool instanceof Hl))this.diagram.tool=i,this.tool.mouseUp(this.eventArgs),this.isMouseDown=!1,this.eventArgs={},this.tool=null,t.preventDefault();else{var l=this.diagram.commandHandler.getObjectLayer(o.id);!l||l.lock||!l.visible||this.diagram.diagramActions&ee.TextEdit||this.diagram.startTextEdit(o,r instanceof ai?r.id.split(o.id+"_")[1]:void 0)}this.diagram.triggerEvent(Ce.doubleClick,{source:o||this.diagram,position:this.currentPosition,count:t.detail})}},n.prototype.itemClick=function(t,e){var i=t;return Dn(this.diagram,i,!0)?i:null},n.prototype.inputChange=function(t){var i,s,o,a,l,h,c,d,u,f=document.getElementById(this.diagram.element.id+"_editBox"),p=document.getElementById(this.diagram.element.id+"_editTextBoxDiv"),g=f.value,v=g.split("\n");(!(a=this.diagram.selectedItems.nodes[0]?this.diagram.selectedItems.nodes[0]:this.diagram.selectedItems.connectors[0])&&this.tool instanceof $I||a&&"SwimLane"===a.shape.type)&&(a=this.diagram.nameTable[this.diagram.activeLabel.parentId]),a&&("Text"!==a.shape.type&&a.annotations.length>0||"Text"===a.shape.type)&&(c=HF((o=this.diagram.getWrapper(a.wrapper,this.diagram.activeLabel.id)).style,g,void 0,void 0,i=(i=a.wrapper.bounds.width90?i:90),s=Number(f.style.fontSize.split("px")[0]),v.length>1&&""===v[v.length-1]&&(c.height=c.height+s),d=this.diagram.scroller.transform,u=P3(this.diagram)?d.scale:1,l=(12>c.height?12:c.height)*u,p.style.left=(o.bounds.center.x+d.tx)*d.scale-(h=(90>(h=c.width)?90:h)*u)/2-2.5+"px",p.style.top=(o.bounds.center.y+d.ty)*d.scale-l/2-3+"px",p.style.width=h+"px",p.style.height=l+"px",f.style.minHeight="12px",f.style.minWidth="90px",f.style.width=h+"px",f.style.height=l+"px")},n.prototype.isAddTextNode=function(t,e){return!(!(this.tool instanceof $I||e)||(this.tool=null,t&&!_I(this.diagram)&&(this.diagram.drawingObject=void 0,this.diagram.currentDrawingObject=void 0),MF(this.diagram.nodes,t.id)||MF(this.diagram.connectors,t.id)))},n.prototype.checkEditBoxAsTarget=function(t){return!(!t.target||t.target.id!==this.diagram.element.id+"_editBox")},n.prototype.getMouseEventArgs=function(t,e,i,r){var s,o,a;if(e.position=t,i?(o=this.diagram.findObjectsUnderMouse(this.currentPosition,i),s=this.diagram.findTargetObjectUnderMouse(o,this.action,this.inAction,e.position,i)):"Drag"===this.action||"ConnectorSourceEnd"===this.action||"SegmentEnd"===this.action||"OrthoThumb"===this.action||"BezierSourceThumb"===this.action||"BezierTargetThumb"===this.action||"ConnectorTargetEnd"===this.action||-1!==this.action.indexOf("Rotate")||-1!==this.action.indexOf("Resize")?(s=this.diagram.selectedItems,!this.diagram.currentSymbol&&"Drag"===this.action&&s&&this.diagram.selectedItems.nodes.length>0&&"SwimLane"===this.diagram.selectedItems.nodes[0].shape.type&&(o=this.diagram.findObjectsUnderMouse(this.currentPosition),s=this.diagram.findObjectUnderMouse(o,this.action,this.inAction))):(o=this.diagram.findObjectsUnderMouse(this.currentPosition),s=this.diagram.findObjectUnderMouse(o,this.action,this.inAction)),s&&s.isHeader&&(this.eventArgs.actualObject=s=this.diagram.nameTable[s.parentId]),s){var l=void 0,h=void 0,c=void 0;if(((a=this.diagram.findElementUnderMouse(s,this.currentPosition,this.diagram,r))&&s.ports&&s.ports.length&&!lb(s,a)||!a||!s)&&o&&o.length&&i instanceof ei)for(l=i.connectors[0],c=o.length-1;c>=0;c--)if(((h=o[parseInt(c.toString(),10)])instanceof te||h instanceof de)&&l&&l.connectionPadding){if(a=this.diagram.findElementUnderMouse(s=h,this.currentPosition,this.diagram,r),l.constraints&qe.ConnectToNearByPort&&s&&s.ports&&s.ports.length&&lb(s,a))break;if((h instanceof te||h instanceof de)&&l&&l.connectionPadding&&h.wrapper.outerBounds.containsPoint(this.currentPosition)&&l.constraints&qe.ConnectToNearByNode&&!(l.constraints&qe.ConnectToNearByPort)){a=this.diagram.findElementUnderMouse(s=h,this.currentPosition,this.diagram,0);break}}}return i?(e.target=s,e.targetWrapper=a):(e.source=s,e.sourceWrapper=a),e.actualObject=this.eventArgs.actualObject,e.source instanceof ei&&void 0===e.actualObject&&(e.source.nodes.length>0||e.source.connectors.length>0)&&(e.actualObject=e.source.nodes.length>0?this.diagram.nameTable[e.source.nodes[0].id]:this.diagram.nameTable[e.source.connectors[0].id]),e.startTouches=this.touchStartList,e.moveTouches=this.touchMoveList,e},n.prototype.resetTool=function(){this.action="Select",this.hoverElement=null,this.hoverNode=null,this.tool=this.diagram.getTool(this.action),this.updateCursor()},n.prototype.updateTool=function(){this.action=this.currentPosition&&"Pan"!==this.action?"Pan":"Select"},n.prototype.getTool=function(t){switch(t){case"Select":return new tm(this.commandHandler,!0);case"Drag":return new fa(this.commandHandler);case"Rotate":return new Xx(this.commandHandler);case"LayoutAnimation":return new Une(this.commandHandler);case"FixedUserHandle":return new _ne(this.commandHandler,!0);case"Hyperlink":return new eF(this.commandHandler);case"ResizeSouthEast":case"ResizeSouthWest":case"ResizeNorthEast":case"ResizeNorthWest":case"ResizeSouth":case"ResizeNorth":case"ResizeWest":case"ResizeEast":return new Rd(this.commandHandler,t);case"ConnectorSourceEnd":case"ConnectorTargetEnd":case"BezierSourceThumb":case"BezierTargetThumb":return new zd(this.commandHandler,t);case"SegmentEnd":case"OrthoThumb":return new r_(this.commandHandler,t);case"Draw":var e="shape",i=function gse(n){var t;return n&&(n.type?t="Connector":n.shape&&!n.type&&(t="Node")),t}(this.diagram.drawingObject);if("Node"===i&&"Text"===this.diagram.drawingObject.shape.type)return new $I(this.commandHandler);if("Connector"===i&&"Freehand"===this.diagram.drawingObject.type)return new Yne(this.commandHandler);if("Node"===i&&"Polygon"===this.diagram.drawingObject.shape[""+e]&&!this.diagram.drawingObject.shape.points)return new Rl(this.commandHandler);if("Node"===i||"Node"===i&&"Polygon"===this.diagram.drawingObject.shape[""+e]&&this.diagram.drawingObject.shape.points)return new qI(this.commandHandler,this.diagram.drawingObject);if("Connector"===i&&"Polyline"===this.diagram.drawingObject.type)return new Hl(this.commandHandler);if("Connector"===i)return new pa(this.commandHandler,"ConnectorSourceEnd",this.diagram.drawingObject);break;case"Pan":return new im(this.commandHandler,!1);case"PinchZoom":return new im(this.commandHandler,!0);case"PortDrag":return new fa(this.commandHandler,"Port");case"PortDraw":return new pa(this.commandHandler,"ConnectorSourceEnd",this.diagram.drawingObject);case"LabelSelect":return new tm(this.commandHandler,!0,"LabelSelect");case"LabelDrag":return new jne(this.commandHandler);case"LabelResizeSouthEast":case"LabelResizeSouthWest":case"LabelResizeNorthEast":case"LabelResizeNorthWest":case"LabelResizeSouth":case"LabelResizeNorth":case"LabelResizeWest":case"LabelResizeEast":return new Vne(this.commandHandler,t);case"LabelRotate":return new Wne(this.commandHandler)}return null},n.prototype.getCursor=function(t){var e=this.diagram.selectedItems.annotation?this.diagram.selectedItems.wrapper.children[0]:this.diagram.selectedItems;return function Fne(n,t){if(t+=360,t%=360,-1===n.indexOf("Resize"))return Gx[""+n];var e=Gx[""+n];return t>=0&&t<25||t>=160&&t<=205||t>=340&&t<=360?e:t>=25&&t<=70||t>=205&&t<=250?"n-resize"===e||"s-resize"===e?"ne-resize":"nw-resize"===e||"se-resize"===e?"n-resize":"e-resize"===e||"w-resize"===e?"nw-resize":"e-resize":t>=70&&t<=115||t>=250&&t<=295?"n-resize"===e||"s-resize"===e?"e-resize":"nw-resize"===e||"se-resize"===e?"ne-resize":"e-resize"===e||"w-resize"===e?"n-resize":"nw-resize":t>=115&&t<=155||t>=295&&t<=340?"n-resize"===e||"s-resize"===e?"nw-resize":"nw-resize"===e||"se-resize"===e?"e-resize":"e-resize"===e||"w-resize"===e?"ne-resize":Gx[""+n]:"n-resize"}(t,this.diagram.selectedItems.annotation?e.rotateAngle+e.parentTransform:e.rotateAngle)},n.prototype.findElementUnderMouse=function(t,e,i,r){return this.objectFinder.findElementUnderSelectedItem(t,e,i,r)},n.prototype.findObjectsUnderMouse=function(t,e){return this.objectFinder.findObjectsUnderMouse(t,this.diagram,this.eventArgs,e)},n.prototype.findObjectUnderMouse=function(t,e,i){return this.objectFinder.findObjectUnderMouse(this.diagram,t,e,i,this.eventArgs,this.currentPosition)},n.prototype.findTargetUnderMouse=function(t,e,i,r,s){return this.objectFinder.findObjectUnderMouse(this.diagram,t,e,i,this.eventArgs,r,s)},n.prototype.findActionToBeDone=function(t,e,i,r){return function kne(n,t,e,i,r,s,o){if(s&&s.length>1&&r&&r.length>1)return"PinchZoom";if(i.currentSymbol)return"Drag";if("PortDraw"===i.eventHandler.action&&(i.tool&=~ri.DrawOnce),(k3(i)||_I(i))&&i.drawingObject)return"Draw";if($a(i)&&(l=i.selectedItems).wrapper&&qr(l.constraints,"UserHandle"))for(var h=0,c=l.userHandles;h=50&&(l.x=(a.points[parseInt(h.toString(),10)].x+a.points[h+1].x)/2,l.y=(a.points[parseInt(h.toString(),10)].y+a.points[h+1].y)/2,wr(e,l,n.hitPadding?n.hitPadding:10)))return"OrthoThumb"}else RI(n)&&console.warn('[WARNING] :: Module "ConnectorEditing" is not available in Diagram component! You either misspelled the module name or forgot to load it.');return null}(g,l,e,i);if("OrthoThumb"===S)return S;if(qr(l.constraints,"ConnectorSourceThumb")&&PI(g)&&S||qr(l.constraints,"ConnectorTargetThumb")&&zI(g)&&S)return S}}else{var b=i.selectedItems.handleSize/2/i.scroller.currentZoom,M=10/i.scroller.currentZoom,w=Bi();qi(w,f.rotateAngle+f.parentTransform,f.offsetX,f.offsetY);var C=f.offsetX-f.pivot.x*f.actualSize.width,D=f.offsetY-f.pivot.y*f.actualSize.height,A={x:C+(.5===f.pivot.x?2*f.pivot.x:f.pivot.x)*f.actualSize.width/2,y:D-30/i.scroller.currentZoom};A=Ke(w,A);var x=!!i.selectedItems.annotation,P=!(!x||!HI(i.selectedItems.annotation));if(qr(l.constraints,"Rotate")&&wr(e,A,M)&&i.selectedItems.thumbsConstraints&bt.Rotate){if(x&&P)return"LabelRotate";if(!x)return"Rotate"}if(u.Inflate(b),u.containsPoint(e)&&(S=function Pne(n,t,e,i,r,s){var o;return 1===n.selectedItems.nodes.length&&0===n.selectedItems.connectors.length&&n.selectedItems.nodes[0].container&&(o=function Hne(n,t,e,i,r){var s=10/n.scroller.currentZoom,o=n.selectedItems,a=t.actualSize.width,l=t.actualSize.height,h=new Ne(i,r,t.style.strokeWidth,l),c=new Ne(i+a,r,t.style.strokeWidth,l),d=new Ne(i,r,a,t.style.strokeWidth),u=new Ne(i,r+l,a,t.style.strokeWidth),f=Dn(n,n.selectedItems.nodes[0],!0)?n.nameTable[n.selectedItems.nodes[0].parentId]:n.selectedItems.nodes[0];if(ga(o.constraints,"ResizeEast",o.thumbsConstraints,o)&&c.containsPoint(e,s))return"ResizeEast";if(ga(o.constraints,"ResizeSouth",o.thumbsConstraints,o)&&u.containsPoint(e,s))return"ResizeSouth";if("Grid"!==f.container.type){if(ga(o.constraints,"ResizeWest",o.thumbsConstraints,o)&&h.containsPoint(e,s))return"ResizeWest";if(ga(o.constraints,"ResizeNorth",o.thumbsConstraints,o)&&d.containsPoint(e,s))return"ResizeNorth"}return null}(n,t,e,r,s)),!o&&(!n.selectedItems.nodes[0]||!n.selectedItems.nodes[0].isPhase&&!n.selectedItems.nodes[0].isLane&&"SwimLane"!==n.selectedItems.nodes[0].shape.type)&&(o=function Bne(n,t,e,i,r,s){var o=40/n.scroller.currentZoom,a=n.selectedItems.handleSize/2/n.scroller.currentZoom,l=n.selectedItems,h=!!l.annotation;if(t.actualSize.width>=o&&t.actualSize.height>=o){if(ga(l.constraints,"ResizeSouthEast",l.thumbsConstraints,l)&&wr(e,Ke(i,{x:r+t.actualSize.width,y:s+t.actualSize.height}),a))return h?"LabelResizeSouthEast":"ResizeSouthEast";if(ga(l.constraints,"ResizeSouthWest",l.thumbsConstraints,l)&&wr(e,Ke(i,{x:r,y:s+t.actualSize.height}),a))return h?"LabelResizeSouthWest":"ResizeSouthWest";if(ga(l.constraints,"ResizeNorthEast",l.thumbsConstraints,l)&&wr(e,Ke(i,{x:r+t.actualSize.width,y:s}),a))return h?"LabelResizeNorthEast":"ResizeNorthEast";if(ga(l.constraints,"ResizeNorthWest",l.thumbsConstraints,l)&&wr(e,Ke(i,{x:r,y:s}),a))return h?"LabelResizeNorthWest":"ResizeNorthWest"}return ga(l.constraints,"ResizeEast",l.thumbsConstraints,l)&&wr(e,Ke(i,{x:r+t.actualSize.width,y:s+t.actualSize.height/2}),a)?h?"LabelResizeEast":"ResizeEast":ga(l.constraints,"ResizeWest",l.thumbsConstraints,l)&&wr(e,Ke(i,{x:r,y:s+t.actualSize.height/2}),a)?h?"LabelResizeWest":"ResizeWest":ga(l.constraints,"ResizeSouth",l.thumbsConstraints,l)&&wr(e,Ke(i,{x:r+t.actualSize.width/2,y:s+t.actualSize.height}),a)?h?"LabelResizeSouth":"ResizeSouth":ga(l.constraints,"ResizeNorth",l.thumbsConstraints,l)&&wr(e,Ke(i,{x:r+t.actualSize.width/2,y:s}),a)?h?"LabelResizeNorth":"ResizeNorth":null}(n,t,e,i,r,s)),o||null}(i,f,e,w,C,D),S))return S}}if(Lc(i)&&!n)return"Pan";if((o instanceof Es||o instanceof Tc)&&(!Lc(i)||Vv(i)||Wv(i))&&(S=function Rne(n,t,e,i){if(_x(t)&&(va(t,ci.Hover)||va(t,ci.Visible))){if(t.constraints&oi.Drag)return"PortDrag"}else if(Fx(t)&&(va(t,ci.Hover)||va(t,ci.Visible))&&t.constraints&oi.Draw){n.drawingObject={};var r={type:"Orthogonal",sourcePortID:t.id};return n.drawingObject=r,n.tool|=ri.DrawOnce,n.currentDrawingObject=r,"PortDraw"}return"None"}(i,o),"None"!==S))return S;if((o instanceof Kn||o instanceof Or)&&!Lc(i)&&Ad(o))return _r(i,o,void 0,t)&&ro(o)?"LabelDrag":"LabelSelect";if(null!==n){if(!(n instanceof te||n instanceof de))return"Select";if(t&&t.id){var L=t.id.split(n.id)[1];if(L&&L.match("^_icon"))return"LayoutAnimation"}if(t&&t.id)for(var O=void 0,N=0;N-1)return"FixedUserHandle";if(t instanceof ai&&t.hyperlink.link)return"Hyperlink";if(!ro(n)||!_r(i,n,!1)||void 0!==i.selectedItems.annotation)return n&&Lc(i)&&!UI(i)?"Pan":i.selectedItems.nodes.length&&i.selectedItems.nodes[0].isLane&&i.selectedItems.wrapper&&i.selectedItems.wrapper.bounds.containsPoint(e)?"Drag":"Select";if(n instanceof de&&!wr(e,n.sourcePoint,n.hitPadding)&&!wr(e,n.targetPoint,n.hitPadding)||!(n instanceof de))return"Drag"}return"Select"}(t,e,this.currentPosition,this.diagram,this.touchStartList,this.touchMoveList,r)},n.prototype.updateContainerBounds=function(t){var e=!1;if(this.diagram.selectedObject.helperObject&&this.diagram.selectedObject.actualObject)for(var i=this.diagram.selectedObject.actualObject,r=this.diagram.selectedObject.actualObject instanceof ei?i.nodes:[i],s=0;si.y&&(h+=u>0?-1:1,u+=u>0?-1:1):i&&e.wrapper.offsetYi.x&&(h+=u>0?-1:1,u+=u>0?-1:1):i&&e.wrapper.offsetX1)for(var S=t.offsetX-this.diagram.selectedItems.offsetX,b=t.offsetY-this.diagram.selectedItems.offsetY,M=t.rotateAngle-this.diagram.selectedItems.rotateAngle,w=0;w-1){var A=c.children;A.splice(A.indexOf(o.id),1),this.diagram.nameTable[o.id].parentId="",i=!0,c.wrapper.children.splice(D,1)}}if(function One(n,t,e,i){var r=n,s=e.nameTable[r.parentId],o=e.nameTable[r.parentId];if(t&&o&&o.container&&"Stack"===o.container.type&&t.container&&"Stack"===t.container.type&&o.id!==t.parentId){var a=o.wrapper.children.indexOf(r.wrapper);a>-1&&(e.nameTable[r.id].parentId=t.id,o.wrapper.children.splice(a,1))}if(t&&t.parentId&&r.parentId&&"Drag"===i&&o.container&&"Stack"===o.container.type){var l=s.wrapper.children.indexOf(t.wrapper),h=s.wrapper.children.indexOf(r.wrapper),c={targetIndex:l,target:t,sourceIndex:h,source:n};s.wrapper.children.splice(h,1),s.wrapper.children.splice(l,0,r.wrapper),e.commandHandler.addHistoryEntry({type:"StackChildPositionChanged",redoObject:{targetIndex:h,target:t,sourceIndex:l,source:n},undoObject:c,category:"Internal"})}}(o,h,this.diagram,this.action),(c=Dn(this.diagram,o)?this.diagram.nameTable[o.parentId]:this.diagram.nameTable[o.parentId]||o)&&c.container&&"Canvas"===c.container.type&&(c.wrapper.maxWidth=c.maxWidth=c.wrapper.actualSize.width,c.wrapper.maxHeight=c.maxHeight=c.wrapper.actualSize.height,e=!0),Dn(this.diagram,o,!0)&&c&&"Canvas"===c.container.type)if(this.diagram.selectedItems.nodes.length>1)for(w=0;w0)for(var i=0;i0&&e.columnIndex>0||l&&e.isLane)){if("Horizontal"===t.container.orientation&&e.isPhase&&e.wrapper.width>e.maxWidth&&(e.maxWidth=e.wrapper.width,e.wrapper.maxWidth=e.wrapper.width),h.updateColumnWidth(e.columnIndex,r.width,!0,c),Vx(this.diagram,e,t),e.isPhase){var p=this.diagram.nameTable[""+t.shape.phases[e.columnIndex].header.id];p.maxWidth0?(r=new op(t,"",u),t.shape.classShape.attributes.push(r)):i.id.includes("_umlMethods")&&t.shape.classShape.methods.length>0&&(s=new fm(t,"",u),t.shape.classShape.methods.push(s))),"Interface"===t.shape.classifier&&(i.id.includes("_umlProperty")&&t.shape.interfaceShape.attributes.length>0?(r=new op(t,"",u),t.shape.classShape.attributes.push(r)):i.id.includes("_umlMethods")&&t.shape.interfaceShape.methods.length>0&&(s=new fm(t,"",u),t.shape.interfaceShape.methods.push(s))),"Enumeration"===t.shape.classifier&&i.id.includes("_umlMember")&&t.shape.enumerationShape.members.length>0){var f=new db(t,"",u);t.shape.enumerationShape.members.push(f)}t.wrapper.children.indexOf(c.wrapper),this.diagram.enableServerDataBinding(!0),this.diagram.add(c),this.diagram.updateConnectorEdges(t),this.diagram.clearSelection(),this.diagram.select([this.diagram.nameTable[c.id]]),this.diagram.endGroupAction(),this.diagram.startTextEdit()}}},n}(),Zoe=function(){function n(){}return n.prototype.findObjectsUnderMouse=function(t,e,i,r,s){var o=[];r&&r instanceof ei&&r.nodes.length+r.connectors.length===1&&(r=r.nodes[0]||r.connectors[0]).children&&0===r.children.length&&(i.actualObject=r);for(var a,l,h,c,p,d=r&&r instanceof de&&(r.constraints&qe.ConnectToNearByNode||r.constraints&qe.ConnectToNearByPort)&&r.connectionPadding||0,f={},g=0,v=e.spatialSearch.findObjects(new Ne(t.x-50-d,t.y-50-d,100+d,100+d));g-1&&o.splice(T,1),"UmlClassifier"===y.shape.type&&y.container&&"Stack"===y.container.type&&(T=o.indexOf(e.nameTable[e.nameTable[y.id].wrapper.children[0].id]))>-1&&o.splice(T,1)}for(var z=0;zs.zIndex&&(t[parseInt(r.toString(),10)]=l),r>0&&i&&a&&(a.isLane||a.isPhase||a.isHeader)&&t[parseInt(r.toString(),10)].zIndex=2)for(var d=t.length-1;d>=0;d--)if(t[parseInt(d.toString(),10)].parentId){var u=hm(t[parseInt(d.toString(),10)],e,""),f=hm(t[d-1],e,""),g=e.nameTable[""+f];g&&u!==f&&e.nameTable[""+u].zIndex=0;p--){d=ip(e[parseInt(p.toString(),10)],!1),c=ip(e[parseInt(p.toString(),10)],!0);var g=t[""+l].tool,v=this.findTargetElement(e[parseInt(p.toString(),10)].wrapper,o,t,void 0);if("Draw"===i&&v&&(e[parseInt(p.toString(),10)]instanceof te||e[parseInt(p.toString(),10)]instanceof de)&&!lb(e[parseInt(p.toString(),10)],v)&&(g&&"ConnectorSourceEnd"===g[""+h]&&!Rh(e[parseInt(p.toString(),10)])||g&&"ConnectorTargetEnd"===g[""+h]&&!ua(e[parseInt(p.toString(),10)])))return u;if(e[parseInt(p.toString(),10)]instanceof te||e[parseInt(p.toString(),10)]instanceof de&&(Rh(e[parseInt(p.toString(),10)])||Ld(d)||ua(e[parseInt(p.toString(),10)])||zh(c)||"PortDraw"===i&&g instanceof zd&&"ConnectorTargetEnd"===g[""+h]&&(ua(e[parseInt(p.toString(),10)])||zh(c))))return u=e[parseInt(p.toString(),10)],f&&(u=this.isTarget(u,t,i)),s.actualObject=u,u}else if("ConnectorTargetEnd"===i&&a){for(p=e.length-1;p>=0;p--)if(c=ip(e[parseInt(p.toString(),10)],!0),(e[parseInt(p.toString(),10)]instanceof te||e[parseInt(p.toString(),10)]instanceof de)&&(ua(e[parseInt(p.toString(),10)])||zh(c)))return u=e[parseInt(p.toString(),10)],u=this.isTarget(u,t,i),s.actualObject=u,u}else{if(a&&("Drag"===i||t[""+l].tool instanceof fa)){var y=0;for(p=0;p=S.zIndex?u:S,y=Math.max(y,S.zIndex)):y=(u=S).zIndex)}return u&&"Bpmn"===u.shape.type&&(t.selectedItems.nodes.length>0&&"Bpmn"===t.selectedItems.nodes[0].shape.type||(u=null)),u&&(s.actualObject=u),u}if("Select"!==i&&"Pan"!==i||!t[""+l].tool)if("Pan"===i||"LayoutAnimation"===i){for(p=e.length-1;p>=0;p--)if((e[parseInt(p.toString(),10)]instanceof te||e[parseInt(p.toString(),10)]instanceof de)&&(v=this.findTargetElement(e[parseInt(p.toString(),10)].wrapper,o,t,void 0),"Pan"===i||v&&(v.id.match("_icon_content_shape$")||v.id.match("_icon_content_rect$"))))return e[parseInt(p.toString(),10)]}else u=e[e.length-1],s&&u&&(s.actualObject=u);else{for(p=e.length-1;p>=0;p--)if(e[parseInt(p.toString(),10)]instanceof de){var b=e[p-1];if(e[p-1]instanceof te&&b.ports){if((v=this.findTargetElement(b.wrapper,o,t,void 0))&&(v.id.match("_icon_content_shape$")||v.id.match("_icon_content_rect$")))return b;for(var M=0;M=0;s--){var o=t.children[parseInt(s.toString(),10)];if(o&&o.outerBounds.containsPoint(e,r||0))if(o.visible){if(o instanceof Cs){var a=this.findTargetElement(o,e,i);if(a)return a}var l="Clip"===o.style.textOverflow||"Ellipsis"===o.style.textOverflow;if(o.bounds.containsPoint(e,r||0)&&!l)return o;if(t.bounds.containsPoint(e,r||0)&&l)return o}else if(o instanceof Ze&&t&&t.id){var h=void 0;if(t.id.includes("group_container")){var c=t.id.slice(0,-15);h=i.getObject(c)}else h=i.getObject(t.id);if(ob(h,o.id))return o}}return t.bounds.containsPoint(e,r)&&"none"!==t.style.fill?t:null},n}(),Joe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),lp=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},n_=function(n){function t(e,i,r,s){var o=n.call(this,e,i,r,s)||this;return o.objectZIndex=-1,o.zIndexTable={},o.objects=[],o}return Joe(t,n),lp([I("")],t.prototype,"id",void 0),lp([I(!0)],t.prototype,"visible",void 0),lp([I(!1)],t.prototype,"lock",void 0),lp([I()],t.prototype,"objects",void 0),lp([I()],t.prototype,"addInfo",void 0),lp([I(-1)],t.prototype,"zIndex",void 0),t}(Ee),ET=function(n,t,e,i){return new(e||(e=Promise))(function(r,s){function o(h){try{l(i.next(h))}catch(c){s(c)}}function a(h){try{l(i.throw(h))}catch(c){s(c)}}function l(h){h.done?r(h.value):new e(function(c){c(h.value)}).then(o,a)}l((i=i.apply(n,t||[])).next())})},DT=function(n,t){var i,r,s,o,e={label:0,sent:function(){if(1&s[0])throw s[1];return s[1]},trys:[],ops:[]};return o={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function a(h){return function(c){return function l(h){if(i)throw new TypeError("Generator is already executing.");for(;e;)try{if(i=1,r&&(s=2&h[0]?r.return:h[0]?r.throw||((s=r.return)&&s.call(r),0):r.next)&&!(s=s.call(r,h[1])).done)return s;switch(r=0,s&&(h=[2&h[0],s.value]),h[0]){case 0:case 1:s=h;break;case 4:return e.label++,{value:h[1],done:!1};case 5:e.label++,r=h[1],h=[0];continue;case 7:h=e.ops.pop(),e.trys.pop();continue;default:if(!(s=(s=e.trys).length>0&&s[s.length-1])&&(6===h[0]||2===h[0])){e=0;continue}if(3===h[0]&&(!s||h[1]>s[0]&&h[1]1)for(var i=0;i-1)return e[parseInt(i.toString(),10)];return this.diagram.activeLayer},n.prototype.getLayer=function(t){for(var e=this.diagram.layers,i=0;i=0;o--)this.diagram.unSelect(this.diagram.nameTable[s[parseInt(o.toString(),10)]]),this.diagram.remove(this.diagram.nameTable[s[parseInt(o.toString(),10)]]),"default_layer"!==i.id&&this.diagram.activeLayer.id===t&&(this.diagram.activeLayer=this.diagram.layers[this.diagram.layers.length-1]);delete this.diagram.layerZIndexTable[i.zIndex],this.diagram.layers.splice(r,1),"SVG"!==this.diagram.mode&&this.diagram.refreshDiagramLayer()}},n.prototype.moveObjects=function(t,e){this.diagram.startGroupAction();for(var i={},r=[],s=0;s-1){if(r=[],(h=this.diagram.nameTable[""+s]).children)for(var p=0,g=h.children;p0){for(var y=void 0,S=0,b=r;S0)for(var r=0;r0)for(r=0;r0){t=t.concat(this.diagram.selectedItems.connectors);for(var i=0;i0)for(t=t.concat(this.diagram.selectedItems.nodes),i=0;i0){for(var i=0,r=t.shape.activity.subProcess.processes;i0&&this.copyProcesses(this.processTable[""+s])}this.clipboardData.processTable=this.processTable}},n.prototype.group=function(){this.oldSelectedObjects=am(this.diagram);var e=this.diagram.isProtectedOnChange;this.diagram.protectPropertyChange(!0),this.diagram.diagramActions=this.diagram.diagramActions|ee.Group;var r={};r.id="group"+Qe(),(r=new te(this.diagram,"nodes",r,!0)).children=[];for(var s=this.diagram.selectedItems.nodes.concat(this.diagram.selectedItems.connectors).sort(function(h,c){return h.zIndex-c.zIndex}),o=0;o0){var a=this.diagram.add(r);a&&this.select(a),this.addHistoryEntry({type:"Group",undoObject:r,redoObject:r,category:"Internal"}),this.diagram.diagramActions=this.diagram.diagramActions&~ee.Group,this.diagram.protectPropertyChange(e)}},n.prototype.unGroup=function(t){var i=this.diagram.isProtectedOnChange;this.diagram.protectPropertyChange(!0),this.diagram.diagramActions=this.diagram.diagramActions|ee.Group;var r=[];t?r.push(t):r=this.diagram.selectedItems.nodes,this.diagram.startGroupAction();for(var s=0;s0&&this.diagram.removePorts(o,o.ports),o.annotations&&o.annotations.length>0&&!ce()&&this.diagram.removeLabels(o,o.annotations);for(var c=this.diagram.nameTable[o.parentId],d=o.children.length-1;d>=0;d--)this.diagram.nameTable[o.children[parseInt(d.toString(),10)]].parentId="",this.diagram.deleteChild(this.diagram.nameTable[o.children[parseInt(d.toString(),10)]],o),o.parentId&&o.children[parseInt(d.toString(),10)]&&this.diagram.addChild(c,o.children[parseInt(d.toString(),10)]);this.resetDependentConnectors(o.inEdges,!0),this.resetDependentConnectors(o.outEdges,!1),this.diagram.diagramActions&ee.UndoRedo||this.addHistoryEntry({type:"UnGroup",undoObject:a,redoObject:a,category:"Internal"}),o.parentId&&this.diagram.deleteChild(o,c)}this.diagram.removeNode(o,l),this.clearSelection()}this.diagram.endGroupAction(),this.diagram.diagramActions=this.diagram.diagramActions&~ee.Group,this.diagram.protectPropertyChange(i)},n.prototype.resetDependentConnectors=function(t,e){for(var i=0;i0&&(g=!1)}if(g){var y=this.cloneConnector(f,i);c.push(y),o[h.id]=y.id}}else{var S=this.cloneNode(h,i);if(c.push(S),S){o[h.id]=S.id;var b=h.inEdges;if(b)for(var M=0,w=b;M0)for(var u=0;u0)for(r=t.segments,s=0;s0&&this.diagram.drawingObject&&"Bezier"===this.diagram.drawingObject.type&&(t.segments=[]);var e=this.diagram.add(t);"SVG"!==this.diagram.mode&&this.diagram.refreshDiagramLayer(),this.selectObjects([e]),t&&!_I(this.diagram)&&(this.diagram.tool&=~ri.DrawOnce,this.diagram.currentDrawingObject=void 0)},n.prototype.enableServerDataBinding=function(t){this.diagram.enableServerDataBinding(t)},n.prototype.addText=function(t,e){var i=this.diagram.findElementUnderMouse(t,e,this.diagram);this.diagram.startTextEdit(t,i instanceof ai?i.id.split("_")[1]:void 0)},n.prototype.isUserHandle=function(t){var e=this.diagram.selectedItems;if(e.wrapper&&qr(e.constraints,"UserHandle"))for(var i=0,r=e.userHandles;i0&&t[0]&&t[0].isLane)for(s=this.diagram.getObject(t[0].parentId),t[0].shape.header=[],a=0;a1||e&&1===t.length)){if(1!==t.length)return[2];this.clearSelection()}if(!(u||d||1!==t.length||e&&$a(this.diagram)))return this.clearSelection(),[2]}if(!r.cancel){for(f=0;f0||e)&&p.children&&!p.parentId)for(g=0;g0||e,!0)}else this.select(p,f>0||e,!0);void 0===i&&(i=c),r={oldValue:i||[],newValue:this.getSelectedObject(),cause:this.diagram.diagramActions,state:"Changed",type:"Addition",cancel:!1},this.diagram.renderSelector(e||t&&t.length>1),ce()||this.diagram.triggerEvent(Ce.selectionChange,r),this.diagram.enableServerDataBinding(!0)}return[2]})})},n.prototype.findParent=function(t){return t.parentId&&this.findParent(t=this.diagram.nameTable[t.parentId]),t},n.prototype.selectProcesses=function(t){if(this.hasProcesses(t))for(var e=t.shape.activity.subProcess.processes,i=0;i0)},n.prototype.select=function(t,e,i){var r=this.getObjectLayer(t.id);if(Ad(t)&&!(t instanceof ei)&&!_r(this.diagram,t)&&r&&!r.lock&&r.visible&&t.wrapper.visible){(e=!!$a(this.diagram)&&e)||this.clearSelection(),this.diagram.enableServerDataBinding(!1);var s=this.diagram.selectedItems;if(t instanceof te?s.nodes.push(t.isHeader?this.diagram.nameTable[t.parentId]:t):s.connectors.push(t),s.selectedObjects.push(t),e)s.wrapper.rotateAngle=s.rotateAngle=0,s.wrapper.children.push(t.wrapper);else if(s.init(this.diagram),1===s.nodes.length&&0===s.connectors.length){var l=Wx(this.diagram,s);l&&(s.wrapper.children[0]=l),s.rotateAngle=s.nodes[0].rotateAngle,s.wrapper.rotateAngle=s.nodes[0].rotateAngle,s.wrapper.pivot=s.nodes[0].pivot}i||this.diagram.renderSelector(e),this.diagram.enableServerDataBinding(!0)}},n.prototype.labelSelect=function(t,e){this.oldSelectedObjects=am(this.diagram);var i=this.diagram.selectedItems,r=this.diagram.allowServerDataBinding;this.diagram.allowServerDataBinding=!1,i.nodes=i.connectors=[],this.diagram.allowServerDataBinding=r,t instanceof te?i.nodes[0]=t:i.connectors[0]=t,i.annotation=this.findTarget(e,t),i.init(this.diagram),this.diagram.renderSelector(!1)},n.prototype.unSelect=function(t){var e=this.diagram.selectedItems.nodes.concat(this.diagram.selectedItems.connectors),i=e.filter(function(a){return a.id!==t.id}),r={oldValue:e,newValue:i,cause:this.diagram.diagramActions,state:"Changing",type:"Removal",cancel:!1};if(this.diagram.currentSymbol||ce()||this.diagram.triggerEvent(Ce.selectionChange,r),_r(this.diagram,t)){var s=this.diagram.selectedItems,o=void 0;t instanceof te?(o=s.nodes.indexOf(t,0),s.nodes.splice(o,1)):(o=s.connectors.indexOf(t,0),s.connectors.splice(o,1)),o=s.selectedObjects.indexOf(t,0),s.selectedObjects.splice(o,1),(r={oldValue:e,newValue:i,cause:this.diagram.diagramActions,state:"Changed",type:"Removal",cancel:(r={oldValue:e,newValue:i,cause:this.diagram.diagramActions,state:"Changed",type:"Removal",cancel:!1}).cancel}).cancel||(o=s.wrapper.children.indexOf(t.wrapper,0),s.wrapper.children.splice(o,1),this.diagram.updateSelector(),this.diagram.currentSymbol||this.diagram.triggerEvent(Ce.selectionChange,r))}},n.prototype.moveSvgNode=function(t,e){var i=this.diagram.nameTable[""+e];if("Native"===i.shape.type||"HTML"===i.shape.type)this.updateNativeNodeIndex(t,e);else{var r=xt(e+"_groupElement",this.diagram.element.id),s=xt(t+"_groupElement",this.diagram.element.id);r.parentNode.insertBefore(s,r)}},n.prototype.moveAfterSvgNode=function(t,e){var i=this.diagram.nameTable[""+e];if(!i||"HTML"!==i.shape.type&&"Native"!==i.shape.type)a=xt(e+"_groupElement",this.diagram.element.id),o=xt(t+"_groupElement",this.diagram.element.id),a.insertAdjacentElement("afterend",o);else for(var r=0;rd&&"SwimLane"!==p.shape.type){var S=$(p);p.zIndex=d-((-1!==i.indexOf(p)?i.indexOf(p):0)+1),p.children&&(d=this.findLowestZIndex(p,c)||d),this.triggerOrderCommand(S,p,p),p.children&&this.updateGroupZindex(p,"SendToBack",d)}else"SwimLane"===p.shape.type&&(y=this.swapZIndexObjects(a,h,r,g));if("SVG"===this.diagram.mode){for(var M="SwimLane"!==this.diagram.nameTable[""+r].shape.type?d:y,w=h[parseInt(M.toString(),10)];!w&&Md)&&(d=f.zIndex)}for(var p=JSON.parse(JSON.stringify(l)),v=Number(Object.keys(l).sort(function(wo,Ul){return Number(wo)-Number(Ul)}).reverse()[0]),y=this.diagram.nameTable[""+e].zIndex,S=[],M=0;M<=v;M++)S.push(l[parseInt(M.toString(),10)]);if("SwimLane"===this.diagram.nameTable[""+e].shape.type)for(var C=v;C>=y;C--)if(l[parseInt(C.toString(),10)]&&this.diagram.nameTable[l[parseInt(C.toString(),10)]].parentId!==e){v=C;break}var D=this.diagram.nameTable[""+e];if(D.zIndexx&&(x=L.zIndex)}}else x=d;D.zIndex=x+((-1!==r.indexOf(D)?r.indexOf(D):0)+1),this.triggerOrderCommand(A,D,D)}else if("SwimLane"===D.shape.type){for(var O=0,N=-1,T=0,z=0,U=JSON.parse(JSON.stringify(l)),B=0;B<=y;B++)if(l[parseInt(B.toString(),10)]&&this.diagram.nameTable[l[parseInt(B.toString(),10)]].parentId===e&&-1===N){N=B,T=B;break}for(var j=0;j<=v;j++)p[parseInt(j.toString(),10)]&&p[parseInt(j.toString(),10)]!==e&&this.diagram.nameTable[p[parseInt(j.toString(),10)]].parentId!==e&&this.diagram.nameTable[p[parseInt(j.toString(),10)]].zIndex>=this.diagram.nameTable[""+e].zIndex&&O++;for(var ue=N,fe=0;fe<=O;fe++){for(;!l[parseInt(ue.toString(),10)];)ue++;z=this.diagram.nameTable[l[parseInt(ue.toString(),10)]].zIndex,ue++}for(var Me=z;Me<=v;Me++){for(;!U[parseInt(N.toString(),10)];)N++;for(;!l[parseInt(Me.toString(),10)];)Me++;l[parseInt(Me.toString(),10)]=U[parseInt(N.toString(),10)],this.diagram.nameTable[l[parseInt(Me.toString(),10)]].zIndex=Me,N++}l[parseInt(v.toString(),10)]=this.diagram.nameTable[""+e].id,this.diagram.nameTable[""+e].zIndex=v,ue=y+1;for(var De=T,xe=0;xe0&&("Native"===hr[0].shape.type||"HTML"===hr[0].shape.type)){for(Ci.parentNode.removeChild(Ci),De=0;De0?r[0]:null},n.prototype.findLowestZIndex=function(t,e){var r=this.diagram.nodes.filter(function(s){return-1!==e.indexOf(s.id)}).filter(function(s){return""===s.parentId&&s.id!==t.id}).map(function(s){return s.zIndex});return r.sort(function(s,o){return s-o}),r.length>0?r[0]:null},n.prototype.triggerOrderCommand=function(t,e,i){var s={zIndex:$(t).zIndex},o={zIndex:e.zIndex},a={element:i,cause:this.diagram.diagramActions,diagramAction:this.diagram.getDiagramAction(this.diagram.diagramActions),oldValue:s,newValue:o};this.diagram.triggerEvent(Ce.propertyChange,a)},n.prototype.checkGroupNode=function(t,e,i){return i[""+e].parentId===i[""+t].parentId},n.prototype.sortByZIndex=function(t,e,i){if("BringForward"===i){var r=e||"zIndex";t=t.sort(function(o,a){return a[""+r]-o[""+r]})}else{var s=e||"zIndex";t=t.sort(function(o,a){return o[""+s]-a[""+s]})}return t},n.prototype.orderCommands=function(t,e,i){var r=this,s=e.nodes;if(s=s.concat(e.connectors),t)if("SendBackward"===i)for(var o=0;oa}),S=v.filter(function(D){return D0?Math.max.apply(Math,S):a,M=y.length>0?Math.min.apply(Math,y):a;if(a!==M){var w=c.zIndexTable[parseInt(M.toString(),10)],C=c.zIndexTable[parseInt(a.toString(),10)];this.moveSvgNode(C,w)}else"SendToBack"===i&&(w=c.zIndexTable[parseInt(a.toString(),10)],C=c.zIndexTable[parseInt(b.toString(),10)],this.moveAfterSvgNode(w,C))}}else this.diagram.refreshCanvasLayers()}},n.prototype.swapDomOrder=function(t,e){if(t){var i=this.diagram.getObject(e);if("Native"===i.shape.type||"HTML"===i.shape.type)this.updateNativeNodeIndex(e,t),this.updateNativeNodeIndex(t,e);else{var r=xt(e+"_groupElement",this.diagram.element.id),s=xt(t+"_groupElement",this.diagram.element.id);r.parentNode.insertBefore(r,s),r.parentNode.insertBefore(s,r)}}},n.prototype.sendForward=function(t){var e=this;if(this.diagram.protectPropertyChange(!0),$a(this.diagram)||t){$(t||(this.diagram.selectedItems.nodes.length?this.diagram.selectedItems.nodes[0]:this.diagram.selectedItems.connectors[0]));var s=t&&t.id,o=this.diagram.layers.indexOf(this.getObjectLayer(s=s||(this.diagram.selectedItems.nodes.length?this.diagram.selectedItems.nodes[0].id:this.diagram.selectedItems.connectors[0].id))),a=$(this.diagram.nameTable),h=(parseInt(o.toString(),10),this.diagram.nameTable[""+s]),c=[],d=this.diagram.spatialSearch.findObjects(h.wrapper.bounds);d.length>2&&(d=this.sortByZIndex(d,void 0,"BringForward"));for(var u=0,f=d;u=0;p--)this.diagram.nameTable[c[parseInt(p.toString(),10)].id].parentId===s&&c.splice(p,1);if(c.length>0){var y=this.diagram.nameTable[c[c.length-1].id];if(y.parentId){var b=hm(y,this.diagram,""),M=this.diagram.nameTable[""+b];M.id!==s&&(c[0]=M)}var w={};for(p=0;p0&&(Object.values(O).forEach(function(ue){ue>=T&&N.push(ue)}),0!==N.length&&this.updateZIndexBySendForward(h,N,o))}var z=[];if(Object.keys(this.changedNodeZIndexes).forEach(function(ue){if((a[""+ue]?a[""+ue].zIndex:null)!==e.changedNodeZIndexes[""+ue]){var De=$(a[""+ue]);z.push(De)}}),this.updateLayerZindexTable(o),L.nodes.splice(0,L.nodes.length),z.forEach(function(ue){var fe=$(ue);L.nodes.push(fe)}),"SVG"===this.diagram.mode){var U=c[c.length-1].id,B=c[c.length-1];B&&!("HTML"===B.shape.type||"Native"===B.shape.type)&&this.moveAfterSvgNode(s,U),this.updateNativeNodeIndex(U,s)}else this.diagram.refreshCanvasLayers();var j=[];Object.keys(this.changedNodeZIndexes).forEach(function(ue){if((a[""+ue]?a[""+ue].zIndex:null)!==e.changedNodeZIndexes[""+ue]){var De=$(e.diagram.nameTable[""+ue]);j.push(De)}});var Q=$(this.diagram.selectedItems);Q.nodes.splice(0,Q.nodes.length),j.forEach(function(ue){var fe=$(ue);Q.nodes.push(fe)}),this.diagram.diagramActions&ee.UndoRedo||this.addHistoryEntry({type:"SendForward",category:"Internal",undoObject:L,redoObject:Q}),this.diagram.endGroupAction()}}this.diagram.protectPropertyChange(!1)},n.prototype.updateZIndexBySendForward=function(t,e,i){var r=$(t);t.zIndex=Math.min.apply(Math,e);var a,s=Math.min.apply(Math,e),o=Math.min.apply(Math,e),l=this.diagram.layers[parseInt(i.toString(),10)].objects,h=this.diagram.nodes.filter(function(S){return-1!==l.indexOf(S.id)});t.children&&this.updateGroupZindex(t,"BringForward",t.zIndex);var c=h.filter(function(S){return S.zIndex===Math.min.apply(Math,e)&&S.id!==t.id});if(c&&c.length>0&&c[0].children){for(var d=Math.min.apply(Math,e),u=0;uo&&g!==t&&g.parentId!==t.id&&c&&c.length>0&&g.parentId!==c[0].id){var v=$(g);g.zIndex=a+1,a++,this.triggerOrderCommand(v,g,g)}var y=g.zIndex;this.changedNodeZIndexes[g.id]=(this.changedNodeZIndexes.hasOwnProperty(g.id),y)}},n.prototype.arrangeZIndexForLowerNodes=function(t,e,i){var r=i.filter(function(o){return o.zIndex<=t&&o.parentId!==e.id});r.sort(function(o,a){return a.zIndex-o.zIndex});for(var s=0;se&&(e=r.zIndex)}return e},n.prototype.sendBackward=function(t){var e=this;if(this.diagram.protectPropertyChange(!0),$a(this.diagram)||t){$(t||(this.diagram.selectedItems.nodes.length?this.diagram.selectedItems.nodes[0]:this.diagram.selectedItems.connectors[0]));var s=t&&t.id,o=this.diagram.layers.indexOf(this.getObjectLayer(s=s||(this.diagram.selectedItems.nodes.length?this.diagram.selectedItems.nodes[0].id:this.diagram.selectedItems.connectors[0].id))),a=$(this.diagram.nameTable),h=(parseInt(o.toString(),10),this.diagram.nameTable[""+s]),c=[],d=this.diagram.spatialSearch.findObjects(h.wrapper.bounds);d.length>2&&(d=this.sortByZIndex(d));for(var u=0,f=d;uNumber(p.zIndex)&&""===p.parentId&&h.wrapper.bounds.intersects(p.wrapper.bounds)&&c.push(p);for(var p=c.length-1;p>=0;p--)(v=this.diagram.nameTable[c[parseInt(p.toString(),10)].id]).parentId===s&&c.splice(p,1);if(c.length>0){var v;if((v=this.diagram.nameTable[c[c.length-1].id]).parentId){var S=hm(v,this.diagram,""),b=this.diagram.nameTable[""+S];s!==b.id&&(c[c.length-1]=b)}var M={};for(p=0;p0&&(Object.values(L).forEach(function(fe){fe<=N&&O.push(fe)}),0!==O.length&&this.updateZIndexBySendBackward(h,O,o))}var T=[];if(Object.keys(this.changedNodeZIndexes).forEach(function(fe){if((a[""+fe]?a[""+fe].zIndex:null)!==e.changedNodeZIndexes[""+fe]){var xe=$(a[""+fe]);T.push(xe)}}),this.updateLayerZindexTable(o),P.nodes.splice(0,P.nodes.length),T.forEach(function(fe){var Me=$(fe);P.nodes.push(Me)}),"SVG"===this.diagram.mode){var z=c[c.length-1].id,U=c[c.length-1];U&&"HTML"!==U.shape.type&&"Native"!==U.shape.type&&this.moveSvgNode(s,z);var B=this.diagram.nameTable[""+z];B.children&&B.children.length>0?this.updateNativeNodeIndex(s):this.updateNativeNodeIndex(s,z)}else this.diagram.refreshCanvasLayers();var j=[];Object.keys(this.changedNodeZIndexes).forEach(function(fe){if((a[""+fe]?a[""+fe].zIndex:null)!==e.changedNodeZIndexes[""+fe]){var xe=$(e.diagram.nameTable[""+fe]);j.push(xe)}});var Q=$(this.diagram.selectedItems);Q.nodes.splice(0,Q.nodes.length),j.forEach(function(fe){var Me=$(fe);Q.nodes.push(Me)}),this.diagram.diagramActions&ee.UndoRedo||this.addHistoryEntry({type:"SendBackward",category:"Internal",undoObject:P,redoObject:Q}),this.diagram.endGroupAction()}}this.diagram.protectPropertyChange(!1)},n.prototype.updateZIndexBySendBackward=function(t,e,i){var r=$(t);t.zIndex=Math.max.apply(Math,e);var f,s=t.zIndex,o=Math.max.apply(Math,e),a=this.diagram.layers[parseInt(i.toString(),10)].objects,l=this.diagram.nodes.filter(function(S){return-1!==a.indexOf(S.id)}),h=l.filter(function(S){return S.zIndex===Math.max.apply(Math,e)&&S.id!==t.id});if(h&&h.length>0&&h[0].children)for(var c=Math.max.apply(Math,e),d=0;d0&&g.parentId!==h[0].id){var v=$(g);g.zIndex=f-1,f--,this.triggerOrderCommand(v,g,g)}var y=g.zIndex;this.changedNodeZIndexes[""+g.id]=(this.changedNodeZIndexes.hasOwnProperty(g.id),y)}},n.prototype.findLowestChildZIndex=function(t){for(var e=t.zIndex,i=0;i0),this.selectObjects([t],!0))},n.prototype.clearSelection=function(t,e){return ET(this,void 0,void 0,function(){var i,r,s,o;return DT(this,function(a){return i=this.diagram.allowServerDataBinding,this.diagram.enableServerDataBinding(!1),$a(this.diagram)&&(r=this.diagram.selectedItems,s=this.getSelectedObject(),this.diagram.currentSymbol&&(this.diagram.previousSelectedObject=s),o={oldValue:s,newValue:[],cause:this.diagram.diagramActions,state:"Changing",type:"Removal",cancel:!1},t&&(ce()||this.diagram.triggerEvent(Ce.selectionChange,o)),o.cancel||(r.offsetX=0,r.offsetY=0,r.width=0,r.height=0,r.rotateAngle=0,r.nodes=[],r.connectors=[],r.wrapper=null,r.annotation=void 0,r.selectedObjects=[],this.diagram.clearSelectorLayer(),t&&(o={oldValue:s,newValue:[],cause:this.diagram.diagramActions,state:"Changed",type:"Removal",cancel:!1},ce()||this.diagram.triggerEvent(Ce.selectionChange,o))),this.diagram.enableServerDataBinding(i)),[2]})})},n.prototype.clearSelectedItems=function(){this.clearSelection((this.diagram.selectedItems.nodes?this.diagram.selectedItems.nodes.length:0)+(this.diagram.selectedItems.connectors?this.diagram.selectedItems.connectors.length:0)>0)},n.prototype.removeStackHighlighter=function(){var t=Fl(this.diagram.element.id),e=t.getElementById(t.id+"_stack_highlighter");e&&e.parentNode.removeChild(e)},n.prototype.renderStackHighlighter=function(t,e){var r,s,o,i=this.diagram.selectedItems.nodes[0];if(!e){var a=this.diagram.findObjectsUnderMouse(t.position);if((e=this.diagram.findObjectUnderMouse(a,"Drag",!0))&&!(e.isLane||e.isPhase||e.isHeader))for(var l=0;l0)for(var a=0;a1)if(i){var h=l.segments[0],c=l.segments[1],u=Ol(AI(t.wrapper,t.wrapper.corners,t.wrapper.bounds),h.direction),g=kl({corners:void 0,point:u=qa(l,0,u,{x:l.sourceWrapper.offsetX,y:l.sourceWrapper.offsetY},!1),margin:void 0,direction:h.direction},{corners:void 0,point:c.points[1],margin:void 0,direction:void 0});h.length=R.distancePoints(g[0],g[1]),c.direction&&c.length&&(c.length=R.distancePoints(g[1],g[2]))}else if(o){switch(l.segments[0].direction){case"Bottom":r=t.wrapper.bounds.bottomCenter.x-e.bottomCenter.x,s=t.wrapper.bounds.bottomCenter.y-e.bottomCenter.y;break;case"Top":r=t.wrapper.bounds.topCenter.x-e.topCenter.x,s=t.wrapper.bounds.topCenter.y-e.topCenter.y;break;case"Left":r=t.wrapper.bounds.middleLeft.x-e.middleLeft.x,s=t.wrapper.bounds.middleLeft.y-e.middleLeft.y;break;case"Right":r=t.wrapper.bounds.middleRight.x-e.middleRight.x,s=t.wrapper.bounds.middleRight.y-e.middleRight.y}this.dragSourceEnd(l,r,s,!0,null,"ConnectorSourceEnd",void 0,void 0,void 0,!(t.parentId&&this.diagram.diagramActions&ee.isGroupDragging))}}},n.prototype.updateEndPoint=function(t,e){var r={sourcePoint:t.sourcePoint,targetPoint:t.targetPoint};t.sourceID&&(r.sourceID=t.sourceID),t.targetID&&(r.targetID=t.targetID),t.sourcePortID&&(r.sourcePortID=t.sourcePortID),t.targetPortID&&(r.targetPortID=t.targetPortID),t.segments&&(r.segments=t.segments),this.diagram.connectorPropertyChange(t,e||{},r),this.diagram.updateSelector()},n.prototype.dragSourceEnd=function(t,e,i,r,s,o,a,l,h,c,d){var u=this.diagram.nameTable[t.id],f={},p=this.checkBoundaryConstraints(e,i,u.wrapper.bounds);if(PI(u)&&p&&"BezierSourceThumb"!==o&&Qv(this.diagram)&&(f=$(f={sourcePoint:u.sourcePoint}),u.sourcePoint.x+=e,u.sourcePoint.y+=i,"ConnectorSourceEnd"===o&&"Orthogonal"===u.type&&this.changeSegmentLength(u,l,h,c),"Bpmn"===u.shape.type&&"Default"===u.shape.sequence&&"Sequence"===u.shape.flow&&this.updatePathElementOffset(u)),"Bezier"===u.type)if(f={sourcePoint:u.sourcePoint},d)this.translateBezierPoints(t,""===o?"ConnectorSourceEnd":o,e,i,d,s,!a);else for(var g=0;g2){var d=R.direction((c=t.segments[2]).points[0],c.points[1]);o.direction===_n(d)?("Right"===o.direction?c.points[0].x=o.points[o.points.length-1].x=l.wrapper.corners.middleRight.x+20:"Left"===o.direction?c.points[0].x=o.points[o.points.length-1].x=l.wrapper.corners.middleLeft.x-20:c.points[0].y=o.points[o.points.length-1].y="Top"===o.direction?l.wrapper.corners.topCenter.y-20:l.wrapper.corners.bottomCenter.y+20,c.direction&&c.length&&(c.length=R.distancePoints(c.points[0],c.points[c.points.length-1])),o.length=R.distancePoints(o.points[0],o.points[o.points.length-1])):o.direction===d&&c.direction&&c.length?("Top"===o.direction||"Bottom"===o.direction?(c.points[0]=o.points[0],c.points[c.points.length-1].x=c.points[0].x):(c.points[0]=o.points[0],c.points[c.points.length-1].y=c.points[0].y),c.length=R.distancePoints(c.points[0],c.points[c.points.length-1]),t.segments.splice(0,2)):o.length=20}else o.length=20;else if(o.length<1)if(""!==t.sourceID){var c;"Right"===a.direction?a.points[a.points.length-1].y=(h=l.wrapper.corners.middleRight).y:"Left"===a.direction?a.points[a.points.length-1].y=(h=l.wrapper.corners.middleLeft).y:a.points[a.points.length-1].x="Top"===a.direction?(h=l.wrapper.corners.topCenter).x:(h=l.wrapper.corners.bottomCenter).x,a.length=R.distancePoints(h,a.points[a.points.length-1]),t.segments.length>2&&(c=t.segments[2]).direction&&c.length&&(c.length=R.distancePoints(a.points[a.points.length-1],c.points[c.points.length-1])),t.segments.splice(0,1)}else t.segments.splice(0,1)}else e&&!i&&t.sourceID!==e.id&&t.segments&&null!==t.segments[0].direction&&e&&e instanceof te&&s&&this.changeSourceEndToNode(t,e),e&&i&&t.sourcePortID!==i&&t.segments&&null!==t.segments[0].direction&&e&&e instanceof te&&s&&this.changeSourceEndToPort(t,e,i)},n.prototype.canConnect=function(t,e){return!(!ua(e)||!Rh(e))},n.prototype.changeSourceEndToPort=function(t,e,i){var r=this.diagram.getWrapper(e.wrapper,i),s={x:r.offsetX,y:r.offsetY},o=zo(s,xn(e.wrapper),e.wrapper.bounds),a=t.segments[0],l=t.segments[1];if(a.direction!==o){var h=[],c={};if(a.direction===_n(o)){c={};var d=void 0;"Top"===o||"Bottom"===o?(d="Top"===o?{type:"Orthogonal",isTerminal:!0,direction:o,length:Math.abs(a.points[0].y-s.y)}:{type:"Orthogonal",isTerminal:!0,direction:o,length:Math.abs(s.y-a.points[0].y)},c=a.points[0].x>s.x?{type:"Orthogonal",isTerminal:!0,direction:"Right",length:a.points[0].x-s.x}:{type:"Orthogonal",isTerminal:!0,direction:"Left",length:s.x-a.points[0].x}):(d="Right"===o?{type:"Orthogonal",isTerminal:!0,direction:o,length:Math.abs(a.points[0].x-s.x)}:{type:"Orthogonal",isTerminal:!0,direction:o,length:Math.abs(s.x-a.points[0].x)},c=a.points[0].y>s.y?{type:"Orthogonal",direction:"Top",isTerminal:!0,length:a.points[0].y-s.y}:{type:"Orthogonal",direction:"Bottom",isTerminal:!0,length:s.y-a.points[0].y}),h.push(new wi(t,"segments",d,!0)),h.push(new wi(t,"segments",c,!0))}else h.push(new wi(t,"segments",c={type:"Orthogonal",direction:o,length:20,isTerminal:!0},!0));a.direction!==_n(o)&&("Top"===o||"Bottom"===o?(a.points[0].x=s.x,a.points[0].y=a.points[a.points.length-1].y="Top"===o?s.y-20:s.y+20):(a.points[0].y=s.y,a.points[0].x=a.points[a.points.length-1].x="Right"===o?s.x+20:s.x-20),a.length=R.distancePoints(a.points[0],a.points[a.points.length-1]),l.length=R.distancePoints(a.points[a.points.length-1],l.points[l.points.length-1])),t.segments=h.concat(t.segments)}else a.points[0]=s,"Top"===o||"Bottom"===o?a.points[a.points.length-1].x=s.x:a.points[a.points.length-1].y=s.y,a.length=R.distancePoints(a.points[0],a.points[a.points.length-1]),l.length=R.distancePoints(a.points[a.points.length-1],l.points[l.points.length-1])},n.prototype.removeTerminalSegment=function(t,e){for(var i=0;ii.width||"Left"===o.direction&&r.x>=o.points[0].x||"Right"===o.direction&&r.x<=o.points[0].x)o.points[0].y=o.points[o.points.length-1].y=r.y,o.points[0].x=r.x,o.length=R.distancePoints(o.points[0],o.points[o.points.length-1]),a.length=R.distancePoints(o.points[o.points.length-1],a.points[a.points.length-1]);else{var h=void 0;s="Bottom"===(h=a.direction?a.direction:R.direction(a.points[0],a.points[a.points.length-1]))?i.bottomCenter:i.topCenter,a.length&&a.direction&&(a.length="Top"===h?o.points[o.points.length-1].y-(s.y+20):s.y+20-o.points[o.points.length-1].y),o.length=o.points[o.points.length-1].x-s.x,o.direction=o.length>0?"Right":"Left",l.push(new wi(t,"segments",{type:"Orthogonal",direction:h,length:20},!0)),t.segments=l.concat(t.segments)}else r="Bottom"===o.direction?i.bottomCenter:i.topCenter,o.length>i.height||"Top"===o.direction&&r.y>=o.points[0].y||"Bottom"===o.direction&&r.y<=o.points[0].y?(o.points[0].x=o.points[o.points.length-1].x=r.x,o.points[0].y=r.y,o.length=R.distancePoints(o.points[0],o.points[o.points.length-1]),a.length=R.distancePoints(o.points[o.points.length-1],a.points[a.points.length-1])):(s="Left"===a.direction?i.middleLeft:i.middleRight,h=void 0,h=a.direction?a.direction:R.direction(a.points[0],a.points[a.points.length-1]),a.length&&a.direction&&(a.length="Left"===h?o.points[o.points.length-1].x-(s.x+20):s.x+20-o.points[o.points.length-1].x),o.length=o.points[o.points.length-1].y-s.y,o.direction=o.length>0?"Bottom":"Top",l.push(new wi(t,"segments",{type:"Orthogonal",direction:h,length:20},!0)),t.segments=l.concat(t.segments))},n.prototype.translateBezierPoints=function(t,e,i,r,s,o,a){var l=t.segments.indexOf(s),h=t.segments[parseInt(l.toString(),10)],c=l>0?t.segments[l-1]:null,d=null!==c?c.point:t.sourcePoint,u=l===t.segments.length-1?t.targetPoint:h.point;if(h)if("BezierSourceThumb"===e&&(h.vector1.angle||h.vector1.distance)){var f=h.vector1.distance,p=h.vector1.angle;h.vector1={distance:t.distance(d,o),angle:R.findAngle(d,o)},this.translateSubsequentSegment(t,s,!0,h.vector1.distance-f,h.vector1.angle-p)}else"BezierTargetThumb"===e&&(h.vector2.angle||h.vector2.distance)?(f=h.vector2.distance,p=h.vector2.angle,h.vector2={distance:t.distance(u,o),angle:R.findAngle(u,o)},this.translateSubsequentSegment(t,s,!1,h.vector2.distance-f,h.vector2.angle-p)):("ConnectorSourceEnd"===e&&!t.sourceID||"ConnectorTargetEnd"===e&&!t.targetID)&&a&&JI(h.vector1)&&JI(h.vector2)?(R.isEmptyPoint(h.point1)&&(h.bezierPoint1=KI(t.sourcePoint,t.targetPoint)),R.isEmptyPoint(h.point2)&&(h.bezierPoint2=KI(t.targetPoint,t.sourcePoint))):"BezierSourceThumb"===e||"ConnectorSourceEnd"===e&&!a&&JI(h.vector1)?(h.bezierPoint1.x+=i,h.bezierPoint1.y+=r,(!R.isEmptyPoint(h.point1)||a)&&(h.point1={x:h.bezierPoint1.x,y:h.bezierPoint1.y})):("BezierTargetThumb"===e||"ConnectorTargetEnd"===e&&!a&&JI(h.vector2))&&(h.bezierPoint2.x+=i,h.bezierPoint2.y+=r,(!R.isEmptyPoint(h.point2)||a)&&(h.point2={x:h.bezierPoint2.x,y:h.bezierPoint2.y}))},n.prototype.translateSubsequentSegment=function(t,e,i,r,s){var o=t.segments.indexOf(e);parseInt(o.toString(),10),t.bezierSettings.smoothness&CI.SymmetricAngle||(s=null),t.bezierSettings.smoothness&CI.SymmetricDistance||(r=null),(null!=r||null!=s)&&(i?0!==o&&this.updatePreviousBezierSegment(t,o,r,s):o!==t.segments.length-1&&this.updateNextBezierSegment(t,o,r,s))},n.prototype.updatePreviousBezierSegment=function(t,e,i,r){var s=t.segments[e-1],a=(s.vector2.angle+r)%360;a<0&&(a+=360),s.vector2={distance:s.vector2.distance+i,angle:a}},n.prototype.updateNextBezierSegment=function(t,e,i,r){var s=t.segments[e+1],a=(s.vector1.angle+r)%360;a<0&&(a+=360),s.vector1={distance:s.vector1.distance+i,angle:a}},n.prototype.dragTargetEnd=function(t,e,i,r,s,o,a,l){var c,h=this.diagram.nameTable[t.id],d=this.checkBoundaryConstraints(e,i,h.wrapper.bounds);if(zI(h)&&"BezierTargetThumb"!==o&&d&&Qv(this.diagram)){if(c=$(c={targetPoint:h.targetPoint}),h.targetPoint.x+=e,h.targetPoint.y+=i,"ConnectorTargetEnd"===o&&"Orthogonal"===h.type&&h.segments&&h.segments.length>0){var u=h.segments[h.segments.length-2];u&&2===h.segments[h.segments.length-1].points.length&&("Left"===u.direction||"Right"===u.direction?u.points[u.points.length-1].x=h.targetPoint.x:u.points[u.points.length-1].y=h.targetPoint.y,u.length=R.distancePoints(u.points[0],u.points[u.points.length-1]),u.direction=R.direction(u.points[0],u.points[u.points.length-1]))}"Bpmn"===h.shape.type&&"Default"===h.shape.sequence&&"Sequence"===h.shape.flow&&this.updatePathElementOffset(h)}if("Bezier"===h.type)if(c={targetPoint:h.targetPoint},l)this.translateBezierPoints(t,""===o?"ConnectorTargetEnd":o,e,i,l,s,!a);else for(var f=0;f0){if(void 0!==s&&o.segments[parseInt(s.toString(),10)])if("Bezier"===o.type){var a=o.segments[parseInt(s.toString(),10)],l=a.isInternalSegment;l&&null!==o.bezierSettings&&"FreeForm"!==o.bezierSettings.segmentEditOrientation?("Horizontal"===a.orientation?a.point.x+=e:a.point.y+=i,this.updateDirectionalBezierCurve(o)):(a.point.x+=e,a.point.y+=i),l&&(o.isBezierEditing=!0)}else o.segments[parseInt(s.toString(),10)].point.x+=e,o.segments[parseInt(s.toString(),10)].point.y+=i;else for(var h=0;h1){var a=e[1],l=e[2],h={x:.5*(a.x+l.x),y:.5*(a.y+l.y)},c=t.segments[0];c.vector1.angle=Gt(s,a),c.vector1.distance=.5*R.findLength(s,a),c.vector2.angle=Gt(h,a),c.vector2.distance=.5*R.findLength(h,a),c.point=h;var d=t.segments[1];if(d.vector1.angle=Gt(h,l),d.vector1.distance=.5*R.findLength(h,l),t.segments.length>2){var u=e[3],f={x:.5*(l.x+u.x),y:.5*(l.y+u.y)};d.vector2.angle=Gt(f,l),d.vector2.distance=.5*R.findLength(f,l),d.point=f;var p=t.segments[2];if(p.vector1.angle=Gt(f,u),p.vector1.distance=.5*R.findLength(f,u),t.segments.length>3){var g=e[4],v={x:.5*(u.x+g.x),y:.5*(u.y+g.y)};p.vector2.angle=Gt(v,u),p.vector2.distance=.5*R.findLength(v,u),p.point=v;var y=t.segments[3];y.vector1.angle=Gt(v,g),y.vector1.distance=.5*R.findLength(v,g),y.vector2.angle=Gt(o,g),y.vector2.distance=.5*R.findLength(o,g)}else p.vector2.angle=Gt(o,u),p.vector2.distance=.5*R.findLength(o,u)}else d.vector2.angle=Gt(o,l),d.vector2.distance=.5*R.findLength(o,l)}},n.prototype.rotateObjects=function(t,e,i,r,s){r=r||{};var o=Bi();qi(o,i,r.x,r.y);for(var l=0,h=e;l0){this.diagram.protectPropertyChange(!0);var o=t;o.segments=[],this.diagram.connectorPropertyChange(o,{},{segments:o.segments}),this.diagram.protectPropertyChange(!1)}}},n.prototype.updateInnerParentProperties=function(t){var r=this.diagram.isProtectedOnChange;this.diagram.protectPropertyChange(!0);for(var s=this.getAllDescendants(t,[],!1,!0),o=0;o0&&(f=this.diagram.bpmnModule.getChildrenBound(d,d.id,this.diagram),u=d.wrapper.bounds.containsRect(f)),h=d.wrapper.actualSize.width*t,c=d.wrapper.actualSize.height*e,void 0!==d.maxWidth&&0!==d.maxWidth&&(h=Math.min(d.maxWidth,h)),void 0!==d.minWidth&&0!==d.minWidth&&(h=Math.max(d.minWidth,h)),void 0!==d.maxHeight&&0!==d.maxHeight&&(c=Math.min(d.maxHeight,c)),void 0!==d.minHeight&&0!==d.minHeight&&(c=Math.max(d.minHeight,c)),u&&(h=Math.max(h,f.right-d.wrapper.bounds.x),c=Math.max(c,f.bottom-d.wrapper.bounds.y)),t=h/d.actualSize.width,e=c/d.actualSize.height}var p=Bi();o||(o=r);var g=o.wrapper;if(qi(p,-g.rotateAngle,i.x,i.y),Xf(p,t,e,i.x,i.y),qi(p,g.rotateAngle,i.x,i.y),r instanceof te){var d,v=Ke(p,{x:(d=r).wrapper.offsetX,y:d.wrapper.offsetY}),y=d.wrapper.offsetX-d.wrapper.actualSize.width*d.pivot.x,S=d.wrapper.offsetY-d.wrapper.actualSize.height*d.pivot.y;if(h>0)if(d.processId){var b=this.diagram.nameTable[d.processId];(!b.maxWidth||d.margin.left+h0)if(d.processId){var M=this.diagram.nameTable[d.processId];(!M.maxHeight||d.margin.top+c0){if(e.dragLimit=e.dragLimit?e.dragLimit:{},e.dragLimit.top||e.dragLimit.bottom||e.dragLimit.left||e.dragLimit.right){var b={minDistance:null};S=this.getRelativeOffset(v,d,b);var M={minDistance:null};g=this.getRelativeOffset(v,y,M),S=null!=b&&M.minDistance0){if(S=y[y.length-1]){var b=void 0;for(b=0;b=e.x-t.dragLimit.left-r.width/2&&i.x<=e.x+t.dragLimit.right+r.width/2&&(s=!0),i.y>=e.y-t.dragLimit.top-r.height/2&&i.y<=e.y+t.dragLimit.bottom+r.height/2&&(o=!0),{x:s,y:o}},n.prototype.updateLabelMargin=function(t,e,i,r,s,o,a){if(i=i||{x:e.offset,y:0},e&&i&&i.x>0&&i.x<1){var l=R.getLengthFromListOfPoints(t.intermediatePoints),h=this.getPointAtLength(l*i.x,t.intermediatePoints,0),c=this.diagram.scrollSettings.currentZoom,d=e.dragLimit?e.dragLimit:{left:0,right:0,top:0,bottom:0};if(d.top||d.bottom||d.left||d.right){this.diagram.getWrapper(t.wrapper,e.id);var f=new Ne(0,0,0,0),p=this.diagram.getWrapper(t.wrapper,e.id);f.x=p.offsetX/c+o,f.y=p.offsetY/c+a,f.width=p.bounds.width/c,f.height=p.bounds.height/c;var g=new Ne(h.x-(d.left||0)-f.width/2,h.y-(d.top||0)-f.height/2,(d.left||0)+(d.right||0)+f.width,(d.top||0)+(d.bottom||0)+f.height);if(g.containsPoint(r));else for(var S=0,b=this.boundsInterSects([h,r],g,!1);S=t){c=t-r,d=R.findAngle(s,a),u=c*Math.cos(d*Math.PI/180),f=c*Math.sin(d*Math.PI/180),o={x:s.x+u,y:s.y+f};break}r+=h,s=a}else s=a;return o},n.prototype.getInterceptWithSegment=function(t,e){for(var o,a,i=[],r=[],s=[],l=R.findLength({x:0,y:0},{x:this.diagram.scroller.viewPortWidth,y:this.diagram.scroller.viewPortHeight}),h=1;h0&&a<=90||a>180&&a<=270?90:-90;r.push(R.transform(t,a+c,l)),r.push(R.transform(t,o+c,l));var f=nm({x1:s[0].x,y1:s[0].y,x2:s[1].x,y2:s[1].y},{x1:r[0].x,y1:r[0].y,x2:r[1].x,y2:r[1].y});f.enabled&&i.push(f.intersectPt)}return i},n.prototype.getAnnotationChanges=function(t,e){var r={};return r[ab(t,e.id,!0)]={width:e.width,height:e.height,offset:t instanceof te?{x:e.offset.x,y:e.offset.y}:e.offset,rotateAngle:e.rotateAngle,margin:{left:e.margin.left,right:e.margin.right,top:e.margin.top,bottom:e.margin.bottom},horizontalAlignment:e.horizontalAlignment,verticalAlignment:e.verticalAlignment,alignment:t instanceof de?e.alignment:void 0},{annotations:r}},n.prototype.getConnectorPortChanges=function(t,e){var i=function Wse(n,t,e){for(var i=n.ports,r=0;r1&&(v.width=g,v.offset.x=1/S),p>1&&(v.height=p,v.offset.y=1/b)}}e instanceof Or&&(e.alignment="Center"),l=this.getAnnotationChanges(t,e),t instanceof te?this.diagram.nodePropertyChange(t,a,l):this.diagram.connectorPropertyChange(t,a,l),this.diagram.updateDiagramObject(t)},n.prototype.getSubProcess=function(t){var i,e={nodes:[],connectors:[]};return t instanceof te?i=t.processId:t&&t.nodes&&t.nodes.length&&t.nodes[0].processId&&(i=t.nodes[0].processId),i&&e.nodes.push($(this.diagram.nameTable[i])),e},n.prototype.checkBoundaryConstraints=function(t,e,i,r){var s=this.diagram.pageSettings,o=this.diagram.pageSettings.boundaryConstraints,a=this.diagram.scroller;if("Page"===o||"Diagram"===o){var l=i?void 0:this.diagram.selectedItems.wrapper.bounds;return!!((i?i.right:l.right)+(t||0)<=("Page"===o?s.width:a.viewPortWidth)&&(i?i.left:l.left)+(t||0)>=0&&(i?i.bottom:l.bottom)+(e||0)<=("Page"===o?s.height:a.viewPortHeight)&&(i?i.top:l.top)+(e||0)>=0||"None"!==this.diagram.layout.type&&r)}return!0},n.prototype.dragSelectedObjects=function(t,e){var i=this,r=this.diagram.selectedItems;this.state&&!this.state.backup&&(this.state.backup={},this.state.backup.offsetX=r.offsetX,this.state.backup.offsetY=r.offsetY),r=XI(this.diagram,r)||r;var s=this.diagram.selectedItems.nodes.filter(function(c){return"SwimLane"===c.shape.type});if(s.length>0&&!this.diagram.currentSymbol&&this.diagram.selectedItems.nodes.length>1){var o=this.diagram.selectedItems.nodes.filter(function(c){return""===c.parentId||"SwimLane"!==i.diagram.nameTable[c.parentId].shape.type});if(o.length>0){for(var a=0;a0||l.length>1)&&(o=o.concat(l),this.diagram.selectedItems.nodes.splice(0,this.diagram.selectedItems.nodes.length),o.forEach(function(c){i.diagram.selectedItems.nodes.push(c)}),r=this.diagram.selectedItems,this.diagram.selectedObject.helperObject=void 0)}}if(this.checkBoundaryConstraints(t,e)){this.diagram.diagramActions=this.diagram.diagramActions|ee.PreventZIndexOnDragging|ee.DragUsingMouse;var h=this.diagram.selectedObject.actualObject;return(h&&h instanceof te&&h.isLane&&Qx(h,this.diagram)||!h||!h.isLane)&&this.diagram.drag(r,t,e),this.diagram.diagramActions=this.diagram.diagramActions&~(ee.PreventZIndexOnDragging|ee.DragUsingMouse),this.diagram.refreshCanvasLayers(),this.checkHtmlObjectDrag(r),!0}return!1},n.prototype.checkHtmlObjectDrag=function(t){var e=!1;this.diagram.views&&this.diagram.views.length>1&&(t instanceof ei?e=t.nodes.some(function(i){return i.shape&&"HTML"===i.shape.type}):t.shape&&"HTML"===t.shape.type&&(e=!0),e&&this.resetOverviewCanvas())},n.prototype.resetOverviewCanvas=function(){for(var t=0,e=this.diagram.views;t0&&(this.layoutAnimateModule.stopCurrentAnimation(this.objectStore[0],e,t),this.objectStore=[]),a=this.diagram.doLayout(),this.objectStore.push(a)),this.canUpdateTemplate=!1,this.diagram.blazorActions&=~on.expandNode,this.diagram.preventNodesUpdate=r,this.diagram.layoutAnimateModule&&this.diagram.organizationalChartModule&&!i)this.diagram.allowServerDataBinding=!1,this.layoutAnimateModule.expand(this.diagram.layout.enableAnimation,a,t,this.diagram);else{var l={element:$(t),state:!!t.isExpanded};this.triggerEvent(Ce.expandStateChange,l),this.diagram.lineRoutingModule&&this.diagram.constraints&nt.LineRouting&&"ComplexHierarchicalTree"!==this.diagram.layout.type&&this.diagram.resetSegments()}return this.diagram.layout.fixedNode=""===o?"":this.diagram.layout.fixedNode,a},n.prototype.getparentexpand=function(t,e,i,r){for(var s,o=0;o0&&(this.diagram.selectedItems.wrapper.rotateAngle=this.diagram.selectedItems.rotateAngle=s.rotateAngle),!(r instanceof te&&"SwimLane"!==r.shape.type)||r.isLane||r.isPhase||r.isHeader||Dn(this.diagram,r)){if(r instanceof ei)for(var d=0;d30||g.wrapper.outerBounds.topCenter.y-p.wrapper.outerBounds.bottomCenter.y>30)&&this.diagram.lineRoutingModule.refreshConnectorSegments(this.diagram,f,!0)}}this.updateSelector(),this.diagram.protectPropertyChange(!1)}},n.prototype.drawSelectionRectangle=function(t,e,i,r){this.diagram.drawSelectionRectangle(t,e,i,r)},n.prototype.startGroupAction=function(){this.diagram.startGroupAction()},n.prototype.endGroupAction=function(){this.diagram.endGroupAction()},n.prototype.removeChildFromBPmn=function(t,e,i){var r=this.diagram.nameTable[t.id]||t.nodes[0];if(i&&r&&r.processId&&r.processId===i.wrapper.id){var s=$(r);s.processId=r.processId,this.diagram.startGroupAction();var o=this.diagram.nameTable[r.processId].shape.activity.subProcess.processes||[];o.splice(o.indexOf(r.id),1),this.diagram.bpmnModule.removeChildFromBPMN(this.diagram.nameTable[r.processId].wrapper,r.id,this.diagram),this.diagram.nameTable[r.id].processId="",r.offsetX=r.wrapper.offsetX,r.offsetY=r.wrapper.offsetY;var a=$(r);this.addHistoryEntry({type:"PositionChanged",redoObject:{nodes:[a]},undoObject:{nodes:[s]},category:"Internal"}),this.diagram.endGroupAction()}},n.prototype.isDroppable=function(t,e){var i=this.diagram.nameTable[t.id]||t.nodes[0];return i instanceof te&&(!ce()&&"TextAnnotation"===i.shape.shape||("Group"===e.shape.shape&&(e.shape.activity.subProcess.collapsed=!1),!(i&&"Bpmn"===i.shape.type&&(i.processId===e.id||i.id===e.processId||"Bpmn"===e.shape.type&&!(e instanceof de)&&e.shape.activity&&e.shape.activity.subProcess&&e.shape.activity.subProcess.collapsed))))},n.prototype.renderHighlighter=function(t,e,i){if(new Ne,t.target instanceof te||t.target instanceof de||e&&(t.source instanceof te||t.source instanceof de)){var a=this.findTarget(e?t.sourceWrapper:t.targetWrapper,e?t.source:t.target,i,!0),l=void 0;if(a instanceof Bd)for(var h=a.id,c=t.target,u=0,f=c.wrapper.children[0].children[0].children[2].children;u0){var r=0;t[0]=this.diagram.nameTable[t[0].id]||t[0];var s="Object"===i?yr(t[0].wrapper):this.diagram.selectedItems.wrapper.bounds,o={nodes:[],connectors:[]},a={nodes:[],connectors:[]};for(r="Object"===i?r+1:r;r0){var i=0,r=0,s=0,o=0,a=0,l=0,h=0,c=0,d={nodes:[],connectors:[]},u={nodes:[],connectors:[]};for(i=0;io.center.y&&(r=n[parseInt(e.toString(),10)],n[parseInt(e.toString(),10)]=n[parseInt(i.toString(),10)],n[parseInt(i.toString(),10)]=r):s.center.x>o.center.x&&(r=n[parseInt(e.toString(),10)],n[parseInt(e.toString(),10)]=n[parseInt(i.toString(),10)],n[parseInt(i.toString(),10)]=r)}}return n}(t,e),i=1;i0){var i=0,r={x:.5,y:.5};t[0]=this.diagram.nameTable[t[0].id]||t[0];var s=yr(t[0].wrapper),o={nodes:[],connectors:[]},a={nodes:[],connectors:[]};for(i=1;ii.zIndex){for(var s=this.diagram.layers.indexOf(this.diagram.getActiveLayer()),o=this.diagram.layers[parseInt(s.toString(),10)].zIndexTable,a=JSON.parse(JSON.stringify(o)),l=i.zIndex,h=r.zIndex,c=h;c>=l;c--)l!==c?o[c-1]?(o[parseInt(c.toString(),10)]=o[c-1],this.diagram.nameTable[o[parseInt(c.toString(),10)]].zIndex=c):(o[c-1]=o[parseInt(c.toString(),10)],this.diagram.nameTable[o[c-1]].zIndex=c,delete o[parseInt(c.toString(),10)]):this.swapZIndexObjects(h,o,r.id,a);"SVG"===this.diagram.mode?(this.moveSvgNode(e.parentId,i.id),this.updateNativeNodeIndex(e.parentId,i.id)):this.diagram.refreshCanvasLayers()}},n.prototype.findLeastIndexConnector=function(t,e,i){for(var r=0;rs.zIndex&&(i=s)}return i},n.prototype.findLeastIndexObject=function(t,e){var i=t;return t instanceof te&&(i=this.findLeastIndexConnector(t.inEdges,e,i),i=this.findLeastIndexConnector(t.outEdges,e,i)),i},n.prototype.checkSelection=function(t,e){var i;if(1===t.nodes.length&&0===t.connectors.length)if(Dn(this.diagram,t.nodes[0],!0)){var r=t.nodes[0];if("SwimLane"===(i="SwimLane"===t.nodes[0].shape?t.nodes[0]:this.diagram.nameTable[t.nodes[0].parentId]).shape.type){var s="Horizontal"===i.shape.orientation;(r.isPhase&&(s&&"ResizeSouth"===e||!s&&"ResizeEast"===e)||r.isLane&&(s&&"ResizeEast"===e||!s&&"ResizeSouth"===e))&&W3(this.diagram,i,e)}else if("Grid"===i.container.type)if("Horizontal"===i.container.orientation&&1===r.rowIndex||"Vertical"===i.container.orientation&&r.rowIndex>0&&r.columnIndex>0){if("ResizeSouth"===e)for(var o=0;o1&&(this.diagram.realActions=this.diagram.realActions|$i.hScrollbarMoved,this.scrolled=!0),this.diagram.scrollSettings.horizontalOffset=t},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"verticalOffset",{get:function(){return this.vOffset},set:function(t){this.vOffset=t,Math.abs(this.vOffset-this.diagram.scrollSettings.verticalOffset)>1&&(this.diagram.realActions=this.diagram.realActions|$i.vScrollbarMoved,this.scrolled=!0),this.diagram.scrollSettings.verticalOffset=t},enumerable:!0,configurable:!0}),n.prototype.getBounds=function(){var e=this.diagram.spatialSearch.getPageBounds(0,0);return(e.x<0||e.y<0)&&!this.diagram.pageSettings.multiplePage?this.getPageBounds(void 0,void 0,!0,!0):this.getPageBounds(void 0,void 0,!0)},n.prototype.updateScrollOffsets=function(t,e){var i,r,s=this.getBounds();s.x*=this.currentZoom,s.y*=this.currentZoom,s.width*=this.currentZoom,s.height*=this.currentZoom,i=Math.max(0,t-s.left),r=Math.max(0,e-s.top),void 0!==t&&void 0!==e?(this.horizontalOffset=i,this.verticalOffset=r,this.diagram.setOffset(i,r)):this.diagram.setOffset(-this.horizontalOffset-s.x,-this.verticalOffset-s.y),this.transform={tx:Math.max(this.horizontalOffset,-s.left)/this.currentZoom,ty:Math.max(this.verticalOffset,-s.top)/this.currentZoom,scale:this.currentZoom}},n.prototype.setScrollOffset=function(t,e){this.scrolled=!1;var i=this.getBounds();i.x*=this.currentZoom,i.y*=this.currentZoom,i.width*=this.currentZoom,i.height*=this.currentZoom;var r=-i.left,s=-i.top,o=!1,a=this.viewPortWidth*this.currentZoom,l=this.viewPortHeight*this.currentZoom,h=r-t;if(h!==this.horizontalOffset){rh?this.horizontalOffset-=t:this.horizontalOffset=h,o=!0);var c=Math.max(i.right+this.vScrollSize,a);if(!o&&c<-h+this.viewPortWidth){var d=-h+a-this.vScrollSize,u=-this.horizontalOffset+a-this.vScrollSize;this.horizontalOffset=dd-u?h:-(i.right+this.vScrollSize-a),o=!0}o||(this.horizontalOffset=r-t)}o=!1;var f=s-e;if(f!==this.verticalOffset){sf?this.verticalOffset-=e:this.verticalOffset=f,o=!0);var p=Math.max(i.bottom+this.hScrollSize,l);if(!o&&p<-f+l){var g=-f+l-this.hScrollSize,v=-this.verticalOffset+l-this.hScrollSize;this.verticalOffset=gg-v?f:-(i.bottom+this.hScrollSize-l),o=!0}o||(this.verticalOffset=s-e)}this.transform={tx:Math.max(this.horizontalOffset,-i.left)/this.currentZoom,ty:Math.max(this.verticalOffset,-i.top)/this.currentZoom,scale:this.currentZoom},this.setSize()},n.prototype.getObjects=function(t,e){for(var i=[],r=0;r0){for(var l=0;l0){h.push(i[parseInt(o.toString(),10)].id);for(var d=0;d=e.bottom&&(l=0),-this.horizontalOffset<=e.x&&-this.horizontalOffset+this.viewPortWidth>=e.right&&(a=0),this.hScrollSize=a,this.vScrollSize=l;var h=this.diagramWidth,c=this.diagramHeight;this.diagramWidth=Math.max(e.right,-this.horizontalOffset+this.viewPortWidth-l)-i,this.diagramHeight=Math.max(e.bottom,-this.verticalOffset+this.viewPortHeight-a)-r,(h!==this.diagramWidth||c!==this.diagramHeight)&&"Diagram"!==this.diagram.scrollSettings.scrollLimit&&this.diagram.setSize(this.diagramWidth,this.diagramHeight),"Diagram"===this.diagram.scrollSettings.scrollLimit&&(h===this.diagramWidth&&c===this.diagramHeight&&1===this.currentZoom||this.diagram.diagramActions&&t&&(!this.diagram.diagramActions||!t||0===this.verticalOffset&&this.verticalOffset!==t.y||0===this.horizontalOffset&&this.horizontalOffset!==t.x)?t&&h===this.diagramWidth&&c===this.diagramHeight&&(this.diagram.diagramCanvas.scrollHeight>this.viewPortHeight&&t.y<0&&this.horizontalOffset===t.x&&0===this.verticalOffset||this.diagram.diagramCanvas.scrollWidth>this.viewPortWidth&&t.x<0&&this.verticalOffset===t.y&&0===this.horizontalOffset)&&(this.verticalOffset=t.y,this.horizontalOffset=t.x,this.transform={tx:Math.max(t.x,-e.left)/this.currentZoom,ty:Math.max(t.y,-e.top)/this.currentZoom,scale:this.currentZoom}):(this.diagram.scrollActions&da.Interaction&&t&&(this.transform={tx:Math.max(t.x,-e.left/this.currentZoom)/this.currentZoom,ty:Math.max(t.y,-e.top/this.currentZoom)/this.currentZoom,scale:this.currentZoom},this.horizontalOffset=t.x,this.verticalOffset=t.y),this.diagram.setSize(this.diagramWidth,this.diagramHeight),!(this.diagram.scrollActions&da.PropertyChange)&&t&&(this.horizontalOffset=t.x,this.verticalOffset=t.y,this.transform={tx:Math.max(t.x,-e.left)/this.currentZoom,ty:Math.max(t.y,-e.top)/this.currentZoom,scale:this.currentZoom}))),this.diagram.transformLayers(),this.diagram.element.style.overflow="hidden"},n.prototype.setViewPortSize=function(t,e){this.viewPortWidth=t,this.viewPortHeight=e},n.prototype.getPageBounds=function(t,e,i,r){var o,s=new Ne;if("Content"===e||r||null===this.diagram.pageSettings.width||null===this.diagram.pageSettings.height){var u=t?void 0:0;o=this.diagram.spatialSearch.getPageBounds(u,u)}else{var a=this.diagram.pageSettings.width,l=this.diagram.pageSettings.height,h=0,c=0;if(this.diagram.pageSettings.multiplePage){if((s=this.diagram.spatialSearch.getPageBounds(0,0)).right>a&&(a*=d=Math.ceil(s.right/a)),s.bottom>l&&(l*=d=Math.ceil(s.bottom/l)),s.left<0&&Math.abs(s.left)>h){var d=Math.ceil(Math.abs(s.left)/this.diagram.pageSettings.width);h=this.diagram.pageSettings.width*d}s.top<0&&Math.abs(s.top)>c&&(d=Math.ceil(Math.abs(s.top)/this.diagram.pageSettings.height),c=this.diagram.pageSettings.height*d)}o=new Ne(-h,-c,a+h,l+c)}if(i){var f=this.diagram.scrollSettings.padding;o.x-=f.left,o.y-=f.top,o.width+=f.left+f.right,o.height+=f.top+f.bottom}return o},n.prototype.getPageBreak=function(t){for(var e=0,i=0,r=-1,s=[],c=this.diagram.pageSettings.margin.left,d=this.diagram.pageSettings.margin.right,u=this.diagram.pageSettings.margin.top,f=this.diagram.pageSettings.margin.bottom,p=1,g=1;t.width>e;)(e+=this.diagram.pageSettings.width?this.diagram.pageSettings.width:t.width)===this.diagram.pageSettings.width&&(s[++r]={x1:t.left+c,y1:t.top+u,x2:t.left+c,y2:t.bottom-f}),ei;)(i+=this.diagram.pageSettings.height?this.diagram.pageSettings.height:t.height)===this.diagram.pageSettings.height&&(s[++r]={x1:t.left+c,y1:t.top+u,x2:t.right-d,y2:t.top+u}),i=this.diagram.scrollSettings.minZoom||l||t>=1)){this.currentZoom*=t;var c=this.getPageBounds(void 0,void 0,!0);c.x*=this.currentZoom,c.y*=this.currentZoom;var d=Bi();Xf(d,t,t,r.x,r.y),r3(d,e||0,i||0),bx(h,d);var u=Ke(h,{x:0,y:0});if(1===t&&(u=this.applyScrollLimit(u.x,u.y,s,o,a)),a=-c.y>=u.y&&-c.x>=u.x&&a,(this.diagram.scrollActions&da.PropertyChange||!(this.diagram.scrollActions&da.Interaction)||"Diagram"!==this.diagram.scrollSettings.scrollLimit||a)&&(this.transform={tx:Math.max(u.x,-c.left)/this.currentZoom,ty:Math.max(u.y,-c.top)/this.currentZoom,scale:this.currentZoom},this.horizontalOffset=u.x,this.verticalOffset=u.y),this.setSize(u),"SVG"!==this.diagram.mode&&Ds(this.diagram)&&this.diagram.scroller.virtualizeElements(),"SVG"!==this.diagram.mode&&!Ds(this.diagram)&&this.diagram.refreshDiagramLayer(),this.diagram.setOffset(-this.horizontalOffset-c.x,-this.verticalOffset-c.y),eb(this.diagram),this.diagram.views&&this.diagram.views.overview){var f=this.diagram.views.overview,p=f.scrollOverviewRect(f.parent.scroller.horizontalOffset,f.parent.scroller.verticalOffset,f.parent.scroller.currentZoom,!0);f.updateOverviewrect(-p.x,-p.y,p.width,p.height),f.updateView(f)}}}},n.prototype.fitToPage=function(t){var e=(t=t||{}).mode,i=t.region,r=t.margin||{},s=t.canZoomIn,o=t.customBounds,a=t.canZoomOut;r.bottom=r.bottom||25,r.top=r.top||25,r.left=r.left||25,r.right=r.right||25;var h,l=o,c=-this.horizontalOffset,d=-this.verticalOffset;if("PageSettings"===(i=i||"PageSettings")&&this.diagram.pageSettings.width&&this.diagram.pageSettings.height||this.diagram.nodes.length>0||this.diagram.connectors.length>0){e=e||"Page","CustomBounds"!==i&&(l=this.getPageBounds(!0,i,!0));var u={x:0,y:0};r.left+r.right>this.viewPortWidth&&(this.viewPortWidth<=100?(r.left=5,r.right=5):(r.left=25,r.right=25)),r.top+r.bottom>this.viewPortHeight&&(this.viewPortHeight<=100?(r.top=5,r.bottom=5):(r.top=25,r.bottom=25)),u.x=(this.viewPortWidth-(r.left+r.right))/l.width,u.y=(this.viewPortHeight-(r.top+r.bottom))/l.height,!s&&l.width-this.horizontalOffset-a+this.viewPortWidth&&(i=o.right-this.viewPortWidth,i+=20),o.x<-a&&(i=o.x),o.bottom>-l+this.viewPortHeight&&(r=o.bottom-this.viewPortHeight,r+=20),o.y<-l&&(r=o.y),this.zoom(1,-this.horizontalOffset-i,-this.verticalOffset-r,null,void 0,e))},n.prototype.bringToCenter=function(t){var e=this.currentZoom,i=new Ne(t.x*e,t.y*e,t.width*e,t.height*e),r=i.x+i.width/2-this.viewPortWidth/2,s=i.y+i.height/2-this.viewPortHeight/2;this.zoom(1,-this.horizontalOffset-(r*=-1),-this.verticalOffset-(s*=-1),null)},n.prototype.applyScrollLimit=function(t,e,i,r,s){if("Infinity"===this.diagram.scrollSettings.scrollLimit&&void 0===i&&!r&&(t=-t,e=-e),"Infinity"!==this.diagram.scrollSettings.scrollLimit){var o=void 0;if("Limited"===this.diagram.scrollSettings.scrollLimit){var a=this.diagram.scrollSettings.scrollableArea;o=new Ne(a.x,a.y,a.width,a.height)}(o=o||(s?this.getPageBounds():this.getPageBounds(!0))).x*=this.currentZoom,o.y*=this.currentZoom,o.width*=this.currentZoom,o.height*=this.currentZoom,void 0!==i&&(t*=-1,e*=-1),r&&(t*=-1,e*=-1);var l=Math.max(o.right,this.viewPortWidth);if(!r&&!(t<=o.x&&(t+this.viewPortWidth>=o.right||t>=o.right-this.viewPortWidth)||t>=o.x&&t+this.viewPortWidth<=l))if(t>=o.x)t=Math.max(o.x,Math.min(t,t-(t+this.viewPortWidth-this.vScrollSize-l)));else{var h=o.right-this.viewPortWidth;t=Math.min(h,o.x)}var c=Math.max(o.bottom,this.viewPortHeight);r||e<=o.y&&e+this.viewPortHeight>=o.bottom||e>=o.y&&e+this.viewPortHeight<=c||(e>=o.y?e=Math.max(o.y,Math.min(e,e-(e+this.viewPortHeight-this.hScrollSize-c))):(h=o.bottom-this.viewPortHeight,e=Math.min(o.y,h))),t*=-1,e*=-1}return{x:t,y:e}},n}(),tae=function(){function n(t,e,i,r,s){this.objects=[],this.left=t,this.top=e,this.width=i,this.height=r,this.spatialSearch=s}return n.prototype.findQuads=function(t,e){null!=this.first&&this.first.isIntersect(t)&&this.first.findQuads(t,e),null!=this.second&&this.second.isIntersect(t)&&this.second.findQuads(t,e),null!=this.third&&this.third.isIntersect(t)&&this.third.findQuads(t,e),null!=this.fourth&&this.fourth.isIntersect(t)&&this.fourth.findQuads(t,e),this.objects.length>0&&e.push(this)},n.prototype.isIntersect=function(t){return!(this.left+this.widtht.right||this.top>t.bottom)},n.prototype.selectQuad=function(){for(var i,t=null,e=this;null!=e;)i=e.getQuad(t),e=i.source,t=i.target||t;return t},n.prototype.getQuad=function(t){var e=this.width/2,i=this.height/2;if(e>=1e3&&i>=1e3){var r=this.left+e,s=this.top+i;if(this.spatialSearch.childRight<=r){if(this.spatialSearch.childBottom<=s)return this.first||((o=new n(this.left,this.top,e,i,this.spatialSearch)).parent=this,this.first=o),{source:this.first};if(this.spatialSearch.childTop>=s)return this.third||((o=new n(this.left,s,e,i,this.spatialSearch)).parent=this,this.third=o),{source:this.third}}else if(this.spatialSearch.childLeft>=r){if(this.spatialSearch.childBottom<=s)return this.second||((o=new n(r,this.top,e,i,this.spatialSearch)).parent=this,this.second=o),{source:this.second};var o;if(this.spatialSearch.childTop>=s)return this.fourth||((o=new n(r,s,e,i,this.spatialSearch)).parent=this,this.fourth=o),{source:this.fourth}}}return this.objects.push(this.spatialSearch.childNode),{target:this}},n.prototype.isContained=function(){return this.spatialSearch.childLeft>=this.left&&this.spatialSearch.childRight<=this.left+this.width&&this.spatialSearch.childTop>=this.top&&this.spatialSearch.childBottom<=this.top+this.height},n.prototype.addIntoAQuad=function(t){var e={};this.spatialSearch.setCurrentNode(t);for(var i=null;!e.isAdded;)i=(e=this.spatialSearch.parentQuad.add(i)).quad;return i},n.prototype.add=function(t){if(t=null,this.isContained())return{isAdded:!0,quad:t=this.selectQuad()};var e=void 0,i=!(0!==this.objects.length||this.first||this.second||this.third||this.fourth),r=2*this.width,s=2*this.height;return this.spatialSearch.childLeft=this.childLeft?(this.pageLeft=this.childLeft,this.leftElement=t,r=!0):t===this.leftElement&&(this.pageLeft=Number.MAX_VALUE,this.findLeft(this.parentQuad),r=!0)),(this.pageTop!==this.childTop||t!==this.topElement)&&(this.pageTop>=this.childTop?(this.pageTop=this.childTop,this.topElement=t,r=!0):t===this.topElement&&(this.pageTop=Number.MAX_VALUE,this.findTop(this.parentQuad),r=!0)),(this.pageBottom!==this.childBottom||t!==this.bottomElement)&&(this.pageBottom<=this.childBottom?(r=!0,this.pageBottom=this.childBottom,this.bottomElement=t):t===this.bottomElement&&(this.pageBottom=-Number.MAX_VALUE,this.findBottom(this.parentQuad),r=!0)),(this.pageRight!==this.childRight||t!==this.rightElement)&&(this.pageRight<=this.childRight?(this.pageRight=this.childRight,this.rightElement=t,r=!0):t===this.rightElement&&(this.pageRight=-Number.MAX_VALUE,this.findRight(this.parentQuad),r=!0)),r}return this.setCurrentNode(null),!1},n.prototype.isWithinPageBounds=function(t){return t.left>=this.pageLeft&&t.right<=this.pageRight&&t.top>=this.pageTop&&t.bottom<=this.pageBottom},n.prototype.findQuads=function(t){var e=[];return this.parentQuad.findQuads(t,e),e},n.prototype.findObjects=function(t){for(var i=[],r=0,s=this.findQuads(t);r=r.outerBounds.left&&(this.pageLeft=r.outerBounds.left,this.leftElement=r)}},n.prototype.findTop=function(t){t.first||t.second?(t.first&&this.findTop(t.first),t.second&&this.findTop(t.second)):(t.third&&this.findTop(t.third),t.fourth&&this.findTop(t.fourth));for(var e=0,i=t.objects;e=r.outerBounds.top&&(this.pageTop=r.outerBounds.top,this.topElement=r)}},n.prototype.setCurrentNode=function(t){if(this.childNode=t,t){var e=t.outerBounds;this.childLeft=Number(e.left),this.childTop=Number(e.top),this.childRight=Number(e.right),this.childBottom=Number(e.bottom)}else this.childLeft=Number.MAX_VALUE,this.childTop=Number.MAX_VALUE,this.childRight=-Number.MAX_VALUE,this.childBottom=-Number.MAX_VALUE},n.prototype.getPageBounds=function(t,e){if(this.pageLeft===Number.MAX_VALUE)return new Ne(0,0,0,0);var i=void 0!==t?Math.min(this.pageLeft,0):this.pageLeft,r=void 0!==e?Math.min(this.pageTop,0):this.pageTop;return new Ne(Math.round(i),Math.round(r),Math.round(this.pageRight-i),Math.round(this.pageBottom-r))},n.prototype.getQuad=function(t){return this.quadTable[t.id]},n}(),iae=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),nae=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return iae(t,n),function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);r>3&&s&&Object.defineProperty(t,e,s)}([I(!1)],t.prototype,"preventDefaults",void 0),t}(Ee),sae=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),o_=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},oae=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return sae(t,n),o_([I("")],t.prototype,"action",void 0),o_([I("")],t.prototype,"cursor",void 0),t}(Ee),a_=function(){function n(){this.size=20,this.intermediatePoints=[],this.gridCollection=[],this.startArray=[],this.targetGridCollection=[],this.sourceGridCollection=[],this.considerWalkable=[]}return n.prototype.lineRouting=function(t){var e=t.connectors.length;if(this.renderVirtualRegion(t),e>0)for(var i=0;i=t.right||e.right<=t.left||e.top>=t.bottom||e.bottom<=t.top)},n.prototype.findEndPoint=function(t,e,i){var r,s;if(e&&""!==t.sourcePortID&&t.sourcePortWrapper||!e&&""!==t.targetPortID&&t.targetPortWrapper){s=zo(r=e?{x:t.sourcePortWrapper.offsetX,y:t.sourcePortWrapper.offsetY}:{x:t.targetPortWrapper.offsetX,y:t.targetPortWrapper.offsetY},void 0,e?t.sourceWrapper.bounds:t.targetWrapper.bounds);var o=e?t.sourcePortWrapper.bounds:t.targetPortWrapper.bounds;r=i?"Top"===s?{x:o.topCenter.x,y:o.topCenter.y}:"Left"===s?{x:o.middleLeft.x,y:o.middleLeft.y}:"Right"===s?{x:o.middleRight.x,y:o.middleRight.y}:{x:o.bottomCenter.x,y:o.bottomCenter.y}:{x:o.center.x,y:o.center.y}}else r=e&&this.startNode||!e&&this.targetNode?e?{x:this.startNode.wrapper.offsetX,y:this.startNode.wrapper.offsetY}:{x:this.targetNode.wrapper.offsetX,y:this.targetNode.wrapper.offsetY}:e?{x:t.sourcePoint.x,y:t.sourcePoint.y}:{x:t.targetPoint.x,y:t.targetPoint.y};return r},n.prototype.refreshConnectorSegments=function(t,e,i,r){var h,c,f,p,g,y,S,b,M,w,C,s=e.sourceID,o=e.targetID,a=e.sourcePortID,l=e.targetPortID;if(function Jre(n,t){var e=0;return n.constraints&qe.LineRouting?e=n.constraints&qe.LineRouting:n.constraints&qe.InheritLineRouting&&(e=t.constraints&nt.LineRouting),e}(e,t)||r){this.startNode=t.nameTable[""+s],this.targetNode=t.nameTable[""+o],this.intermediatePoints=[],this.startArray=[],this.targetGridCollection=[],this.sourceGridCollection=[],this.startGrid=void 0,this.targetGrid=void 0;for(var D=0;D0;){var L=this.startArray.pop();if(L){for(D=0;D1&&(e.segments=[]),this.updateConnectorSegments(t,this.intermediatePoints,this.gridCollection,e,i)){this.considerWalkable=[];break e}this.targetGridCollection.splice(this.targetGridCollection.indexOf(O),1),L=this.startArray.pop()}}L&&this.findPath(L)}}}},n.prototype.checkChildNodes=function(t,e){var i=!1,r=!1;if(t.nodeId.length>=1&&!e)for(var s=0;s1&&this.targetGridCollection[0].nodeId.length>1)for(var c=0;c<=1;c++){for(var d=this.targetGridCollection[parseInt(c.toString(),10)].gridX,u=this.targetGridCollection[parseInt(c.toString(),10)].gridY,f=this.targetGridCollection[parseInt(c.toString(),10)].nodeId,p=void 0,g=0;g=e.right&&t.top<=e.top&&t.bottom>=e.bottom},n.prototype.getEndvalue=function(t,e){return this.gridCollection[t.gridX][t.gridY].walkable?t:"left"===e?this.getEndvalue(this.gridCollection[t.gridX-1][t.gridY],e):"right"===e?this.getEndvalue(this.gridCollection[t.gridX+1][t.gridY],e):"top"===e?this.getEndvalue(this.gridCollection[t.gridX][t.gridY-1],e):"bottom"===e?this.getEndvalue(this.gridCollection[t.gridX][t.gridY+1],e):t},n.prototype.changeValue=function(t,e,i){t.walkable||this.considerWalkable.push(t);for(var r,s=0;s<=e;s++)"left"===i?r=this.gridCollection[t.gridX-s][t.gridY]:"right"===i?r=this.gridCollection[t.gridX+s][t.gridY]:"top"===i?r=this.gridCollection[t.gridX][t.gridY-s]:"bottom"===i&&(r=this.gridCollection[t.gridX][t.gridY+s]),r.walkable||this.considerWalkable.push(r)},n.prototype.getIntermediatePoints=function(t){var e;for(this.intermediatePoints=[];t;)this.intermediatePoints.push({x:t.gridX,y:t.gridY}),t=t.parent;this.intermediatePoints.reverse(),this.intermediatePoints.length>=1&&void 0!==this.intermediatePoints[0]&&void 0!==this.intermediatePoints[1]&&(this.intermediatePoints[0].x===this.intermediatePoints[1].x?this.intermediatePoints[0].yi.y&&o.y>s.y){for(var a=i.xi.x&&o.x>s.x)){for(var u=i.y=1&&u.length>1&&(g=u[u.length-2].x!==u[u.length-1].x?u[u.length-2].x>u[u.length-1].x?"Left":"Right":u[u.length-2].y>u[u.length-1].y?"Top":"Bottom"),M>=2&&v===g&&u.length>1&&u.splice(u.length-2,1),v=g);if(u&&u.length>1){for(var w=0;wD.x?S.bounds.middleLeft:S.bounds.middleRight),w===u.length-2&&""===r.targetPortID&&y&&(l=C.x>D.x?y.bounds.middleRight:y.bounds.middleLeft),0===w&&b&&(C.x=b.x,C.y=D.y=b.y,b=qa(r,0,b,Ol(S.bounds,_n(C.x>D.x?"Left":"Right")),!1),C.x=b.x),w===u.length-2&&l&&(w>0&&r.targetDecorator&&l.x-D.x<0&&Math.abs(l.x-C.x)0&&r.targetDecorator&&l.x-D.x>0&&Math.abs(l.x-C.x)D.y?S.bounds.topCenter:S.bounds.bottomCenter),w===u.length-2&&""===r.targetPortID&&y&&(l=C.y>D.y?y.bounds.bottomCenter:y.bounds.topCenter),0===w&&b&&(C.y=b.y,C.x=D.x=b.x,b=qa(r,0,b,Ol(S.bounds,_n(C.y>D.y?"Top":"Bottom")),!1),C.y=b.y),w===u.length-2&&l&&(w>0&&r.targetDecorator&&l.y-D.y<0&&Math.abs(l.y-C.y)0&&r.targetDecorator&&l.y-D.y>0&&Math.abs(l.y-C.y)D.x?(f="Left",p=C.x-D.x):(f="Right",p=D.x-C.x):C.y>D.y?(f="Top",p=C.y-D.y):(f="Bottom",p=D.y-C.y),o.push({type:"Orthogonal",length:p,direction:f})}}if(o&&o.length>0){var L=o[o.length-1];if(1===o.length&&(L.length-=20),L.length<10&&2===o.length&&(o.pop(),o.length>0&&(o[0].length-=20,L=o[0])),r.targetDecorator&&("Top"===L.direction||"Bottom"===L.direction)&&L.length>r.targetDecorator.height+1||("Right"===L.direction||"Left"===L.direction)&&L.length>r.targetDecorator.width+1)return r.segments=o,s&&t.connectorPropertyChange(r,{},{type:"Orthogonal",segments:o}),!0}return!1},n.prototype.findPath=function(t){for(var e,i=[],r=this.findNearestNeigbours(t,this.gridCollection,!0),s=0;sl)&&(e.x!==t.gridX||e.y!==t.gridY)&&(i.push(e),o.previousDistance=l,o.afterDistance=o.afterDistance||this.manhattan(Math.abs(e.x-this.targetGrid.gridX),Math.abs(e.y-this.targetGrid.gridY)),o.totalDistance=o.previousDistance+o.afterDistance,o.parent=t)}if(i.length>0)for(s=0;st?i*t+e:i*e+t},n.prototype.manhattan=function(t,e){return t+e},n.prototype.findNearestNeigbours=function(t,e,i){var r=[],s=t.parent;if(s){var o=(t.gridX-s.gridX)/Math.max(Math.abs(t.gridX-s.gridX),1),a=(t.gridY-s.gridY)/Math.max(Math.abs(t.gridY-s.gridY),1);0!==o?(this.isWalkable(t.gridX,t.gridY-1,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX][t.gridY-1])&&r.push(e[t.gridX][t.gridY-1]),this.isWalkable(t.gridX,t.gridY+1,!0)&&this.sourceGridCollection.indexOf(e[t.gridX][t.gridY+1])&&r.push(e[t.gridX][t.gridY+1]),this.isWalkable(t.gridX+o,t.gridY,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX+o][t.gridY])&&r.push(e[t.gridX+o][t.gridY])):0!==a&&(this.isWalkable(t.gridX-1,t.gridY,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX-1][t.gridY])&&r.push(e[t.gridX-1][t.gridY]),this.isWalkable(t.gridX+1,t.gridY,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX+1][t.gridY])&&r.push(e[t.gridX+1][t.gridY]),this.isWalkable(t.gridX,t.gridY+a,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX][t.gridY+a])&&r.push(e[t.gridX][t.gridY+a]))}else this.neigbour(t,"top",r,i),this.neigbour(t,"right",r,i),this.neigbour(t,"bottom",r,i),this.neigbour(t,"left",r,i);return r},n.prototype.neigbour=function(t,e,i,r){for(var o,s=1;s>0;){var a="top"===e||"bottom"===e?t.gridX:"left"===e?t.gridX-s:t.gridX+s,l="right"===e||"left"===e?t.gridY:"top"===e?t.gridY-s:t.gridY+s;if((o=this.gridCollection[parseInt(a.toString(),10)][parseInt(l.toString(),10)])&&(r&&-1===this.sourceGridCollection.indexOf(o)||!r&&-1===this.targetGridCollection.indexOf(o)))return i&&this.isWalkable(a,l)&&i.push(o),s;if(!(a>0&&l>0))break;s++}return null},n.prototype.resetGridColl=function(t,e,i){for(var s,r=1;r>0;){var o="top"===e||"bottom"===e?t.gridX:"left"===e?t.gridX-r:t.gridX+r,a="right"===e||"left"===e?t.gridY:"top"===e?t.gridY-r:t.gridY+r;if((s=this.gridCollection[parseInt(o.toString(),10)][parseInt(a.toString(),10)])&&(i&&-1===this.sourceGridCollection.indexOf(s)||!i&&-1===this.targetGridCollection.indexOf(s))){if(this.isWalkable(o,a))break;var l=this.gridCollection[parseInt(o.toString(),10)][parseInt(a.toString(),10)];this.considerWalkable.push(l)}if(!(o>0&&a>0))break;"top"===e||"left"===e?r--:r++}return null},n.prototype.isWalkable=function(t,e,i){if(t>=0&&t=0&&e0?1:-1,this.isWalkable(h,c-1)&&!this.isWalkable(h-a,c-1)||this.isWalkable(h,c+1)&&!this.isWalkable(h-a,c+1)))return{x:t,y:e};if(0!==l){if(l=l>0?1:-1,this.isWalkable(h-1,c)&&!this.isWalkable(h-1,c-l)||this.isWalkable(h+1,c)&&!this.isWalkable(h+1,c-l))return{x:t,y:e};if(this.findIntermediatePoints(h+1,c,h,c,s,o)||this.findIntermediatePoints(h-1,c,h,c,s,o))return{x:t,y:e}}return this.findIntermediatePoints(h+a,c+l,h,c,s,o)},n.prototype.destroy=function(){},n.prototype.getModuleName=function(){return"LineRouting"},n}(),aae=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),hae=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return aae(t,n),function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);r>3&&s&&Object.defineProperty(t,e,s)}([I(!0)],t.prototype,"inversedAlignment",void 0),t}(Ee),cae=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Oe=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},xT=function(n,t,e,i){return new(e||(e=Promise))(function(r,s){function o(h){try{l(i.next(h))}catch(c){s(c)}}function a(h){try{l(i.throw(h))}catch(c){s(c)}}function l(h){h.done?r(h.value):new e(function(c){c(h.value)}).then(o,a)}l((i=i.apply(n,t||[])).next())})},TT=function(n,t){var i,r,s,o,e={label:0,sent:function(){if(1&s[0])throw s[1];return s[1]},trys:[],ops:[]};return o={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function a(h){return function(c){return function l(h){if(i)throw new TypeError("Generator is already executing.");for(;e;)try{if(i=1,r&&(s=2&h[0]?r.return:h[0]?r.throw||((s=r.return)&&s.call(r),0):r.next)&&!(s=s.call(r,h[1])).done)return s;switch(r=0,s&&(h=[2&h[0],s.value]),h[0]){case 0:case 1:s=h;break;case 4:return e.label++,{value:h[1],done:!1};case 5:e.label++,r=h[1],h=[0];continue;case 7:h=e.ops.pop(),e.trys.pop();continue;default:if(!(s=(s=e.trys).length>0&&s[s.length-1])&&(6===h[0]||2===h[0])){e=0;continue}if(3===h[0]&&(!s||h[1]>s[0]&&h[1]0&&((!s.style||!s.style.fill)&&(o.style.fill="transparent"),(!s.style||!s.style.strokeColor)&&(o.style.strokeColor="transparent")),s.shape&&"UmlActivity"===s.shape.type&&rb(s,o),s.shape&&"SwimLane"===s.shape.type&&fF(s,o),r.nodeDefaults&&Ro(o,s,r.nodeDefaults),r.updateAnnotationText(o.annotations);if(e&&e.connectors)for(a=0;e&&e.connectors&&a0&&0===i.nodes.length)this.clearCollection(),a=!0;else{for(var g=0,v=Object.keys(e.nodes);g0&&0===i.connectors.length)this.clearCollection(!0),a=!0;else{for(var C=0,D=Object.keys(e.connectors);C0){this.renderSelector(!0);break}if(e.selectedItems.constraints){this.renderSelector(!0);break}break;case"snapSettings":this.updateSnapSettings(e);break;case"commandManager":this.initCommands();break;case"layout":o=!0;break;case"segmentThumbShape":this.updateSelector();break;case"dataSourceSettings":this.clear(),"None"===this.layout.type?a=!0:(this.initObjects(),o=!0);break;case"tooltip":l3(this);break;case"rulerSettings":this.updateRulerSettings(e);break;case"layers":this.updateLayer(e);break;case"scrollSettings":this.scrollActions|=da.PropertyChange,this.updateScrollSettings(e),this.scrollActions&=~da.PropertyChange,this.scrollSettings.horizontalOffset=-this.scroller.horizontalOffset||0,this.scrollSettings.verticalOffset=-this.scroller.verticalOffset||0;break;case"locale":e.locale!==i.locale&&(this.realActions|=$i.PreventDataInit,n.prototype.refresh.call(this),this.realActions&=~$i.PreventDataInit);break;case"contextMenuSettings":if(void 0!==e.contextMenuSettings.showCustomMenuOnly&&(this.contextMenuSettings.showCustomMenuOnly=e.contextMenuSettings.showCustomMenuOnly),void 0!==e.contextMenuSettings.show&&(this.contextMenuSettings.show=e.contextMenuSettings.show),e.contextMenuSettings.items){for(var A=e.contextMenuSettings.items,x=0,P=Object.keys(A);x0){for(var N=[],T=O.ports.length-1;T>=0;T--)"LineDistribution"===O.ports[parseInt(T.toString(),10)].id.split("_")[1]&&N.push(O.ports[parseInt(T.toString(),10)]);this.removePorts(O,N)}}for(T=0;T0)for(var ue=0,fe=Object.keys(e.nodes);ue0)for(var De=0,xe=Object.keys(e.connectors);De=0;o--)this.commandHandler.expandNode(r[parseInt(o.toString(),10)],this,0!==o);this.canLayout&&this.doLayout(),this.lineRoutingModule?this.connectors.sourceID!==this.connectors.targetID&&this.lineRoutingModule.lineRouting(this):this.constraints&nt.LineRouting&&console.warn('[WARNING] :: Module "LineRouting" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),this.validatePageSize(),this.renderPageBreaks(),this.diagramRenderer.renderSvgGridlines(this.snapSettings,Ud(this.element.id),this.scroller.transform,this.rulerSettings,this.hRuler,this.vRuler),this.commandHandler.initSelectorWrapper(),this.notify("initial-load",{}),this.trigger("load"),this.scroller.setSize(),this.scroller.updateScrollOffsets(),this.isRefreshed||this.refreshDiagramLayer(),(this.scrollSettings.verticalOffset>0||this.scrollSettings.horizontalOffset>0)&&this.updateScrollOffset(),X.isDevice&&(this.tool=ri.ZoomPan|ri.SingleSelect),this.notify("initial-end",{}),this.isProtectedOnChange=!1,this.tooltipObject=l3(this),this.diagramActions=ee.Render,this.initCommands();var a=document.getElementsByClassName(this.element.id+"_hiddenUserHandleTemplate");(function Noe(n,t,e,i){var r,s,o,a,l,d=document.getElementById(i).ej2_instances[0];if(n&&t){r=GF(n);for(var u=0,f=e.userHandles;u0;)e[0].parentNode.removeChild(e[0]);var i=document.getElementById(this.element.id+"content");i&&this.element.removeChild(i);var r="measureElement";if(window[""+r]){window[""+r].usageCount-=1;var s="measureElementCount";window[""+s]--,0===window[""+s]&&(window[""+r].parentNode.removeChild(window[""+r]),window[""+r]=null)}}window.domTable={};for(var a=0;a1&&(this.callBlazorModel=!1,this.insertBlazorDiagramObjects(this.selectedItems),this.commandHandler.group(),this.callBlazorModel=!0,this.commandHandler.getBlazorOldValues())},t.prototype.unGroup=function(){this.callBlazorModel=!1,this.insertBlazorDiagramObjects(this.selectedItems),this.commandHandler.unGroup(),this.callBlazorModel=!0,this.commandHandler.getBlazorOldValues()},t.prototype.sendToBack=function(){this.commandHandler.sendToBack()},t.prototype.setActiveLayer=function(e){var i=this.commandHandler.getLayer(e);this.activeLayer=i},t.prototype.addLayer=function(e,i){this.commandHandler.addLayer(e,i)},t.prototype.removeLayer=function(e){this.commandHandler.removeLayer(e,ce())},t.prototype.moveObjects=function(e,i){$(this.layers),this.enableServerDataBinding(!1),this.commandHandler.moveObjects(e,i)},t.prototype.layerObjectUpdate=function(){},t.prototype.sendLayerBackward=function(e){this.layerObjectUpdate(),this.commandHandler.sendLayerBackward(e)},t.prototype.bringLayerForward=function(e){this.layerObjectUpdate(),this.commandHandler.bringLayerForward(e)},t.prototype.cloneLayer=function(e){this.commandHandler.cloneLayer(e)},t.prototype.bringToFront=function(){this.commandHandler.bringToFront()},t.prototype.moveForward=function(){this.commandHandler.sendForward()},t.prototype.sendBackward=function(){this.commandHandler.sendBackward()},t.prototype.getObject=function(e){return this.nameTable[""+e]},t.prototype.getNodeObject=function(e){return $(this.nameTable[""+e])},t.prototype.getConnectorObject=function(e){return $(this.nameTable[""+e])},t.prototype.getActiveLayer=function(){return this.activeLayer},t.prototype.nudgeCommand=function(e,i,r){if("object"!=typeof e&&(this.selectedItems.nodes.length||this.selectedItems.connectors.length)>0){var s=void 0;i.type&&"KEYDOWN"===i.type&&(s=i.type),this.nudge(e,void 0,void 0,s)}},t.prototype.nudge=function(e,i,r,s){var o=0,a=0;"Left"===e||"Right"===e?o=("Left"===e?-1:1)*(i||1):a=("Up"===e?-1:1)*(r||1),"KEYDOWN"===s&&(o*=5,a*=5);var h=this.selectedItems,c=this.selectedItems.wrapper.children[0];if(c instanceof ai)this.commandHandler.labelDrag(h.nodes[0],c,o,a);else{var d=$(this.selectedItems);this.protectPropertyChange(!0),this.drag(h,o,a),this.protectPropertyChange(!1);var u={type:"PositionChanged",redoObject:$(this.selectedItems),undoObject:d,category:"Internal"};this.addHistoryEntry(u)}this.refreshCanvasLayers()},t.prototype.insertBlazorDiagramObjects=function(e){},t.prototype.drag=function(e,i,r){if(this.insertBlazorDiagramObjects(e),!(this.bpmnModule&&e instanceof te&&this.bpmnModule.updateAnnotationDrag(e,this,i,r))){if(e instanceof ei){if(this.preventConnectorsUpdate=!0,e.nodes&&e.nodes.length){for(var o=0,a=e.nodes;o0&&o.nodes[0].children){this.fromUndo||(this.rotateUsingButton=!0);for(var h=this.commandHandler.getAllDescendants(o.nodes[0],[]),c=0;c0&&o.nodes[0].children){var g={type:"RotationChanged",redoObject:$(e),undoObject:$(o),category:"Internal",childTable:a};this.commandHandler.addHistoryEntry(g),this.commandHandler.updateSelector()}return u},t.prototype.dragSourceEnd=function(e,i,r){this.insertBlazorDiagramObjects(e),this.commandHandler.dragSourceEnd(e,i,r),this.callBlazorModel&&this.commandHandler.getBlazorOldValues()},t.prototype.dragTargetEnd=function(e,i,r){this.insertBlazorDiagramObjects(e),this.commandHandler.dragTargetEnd(e,i,r),this.callBlazorModel&&this.commandHandler.getBlazorOldValues()},t.prototype.findObjectsUnderMouse=function(e,i){return this.eventHandler.findObjectsUnderMouse(e,i)},t.prototype.findObjectUnderMouse=function(e,i,r){return this.eventHandler.findObjectUnderMouse(e,i,r)},t.prototype.findTargetObjectUnderMouse=function(e,i,r,s,o){return this.eventHandler.findTargetUnderMouse(e,i,r,s,o)},t.prototype.findElementUnderMouse=function(e,i,r,s){return this.eventHandler.findElementUnderMouse(e,i,r,s)},t.prototype.findActionToBeDone=function(e,i,r,s){return this.eventHandler.findActionToBeDone(e,i,r,s)},t.prototype.updateConnectorPort=function(e){if(e.ports.length)for(var i=void 0,r=0,s=e.ports;r=0;s--)if(i.push(r[parseInt(s.toString(),10)]),i.length>this.historyManager.stackLimit)return i}else i=r;return i},t.prototype.getEdges=function(e){return e.outEdge?this.nameTable[e.id].outEdges:this.nameTable[e.id].inEdges},t.prototype.getParentId=function(e){return this.nameTable[""+e].parentId},t.prototype.addConnector=function(e){return this.add(e)},t.prototype.UpdateBlazorDiagramModelCollection=function(e,i,r,s){},t.prototype.UpdateBlazorDiagramModel=function(e,i,r,s){},t.prototype.UpdateBlazorLabelOrPortObjects=function(e,i,r,s){},t.prototype.addBlazorDiagramObjects=function(){},t.prototype.removeNodeEdges=function(e,i,r){var s=this.nameTable[""+e],o=r?s.outEdges:s.inEdges;if(o.length>0)for(var a=0;a0)){for(var c=0;c0))}this.removePortEdges(l,a.element.sourcePortID,a.element.id,h)}a.element.targetID&&this.removeNodeEdges(a.element.targetID,a.element.id,!1)}}this.diagramActions=this.diagramActions|ee.PublicMethod,e.id=e.id||Qe();var u=this.activeLayer;if(!a.cancel&&u&&!u.lock){if(u.objects.indexOf(e.id)<0&&!u.lock&&(u.visible||(u.visible=!0,this.dataBind()),u.objects.push(e.id)),ps(e)===de)(r=new de(this,"connectors",e,!0)).status="New",this.nameTable[r.targetID]&&"TextAnnotation"===this.nameTable[r.targetID].shape.shape&&(r.isBpmnAnnotationConnector=!0,r.constraints=r.constraints&~qe.Delete),Ro(r,e,this.connectorDefaults),this.connectors.push(r),this.initObject(r),!1===e.visible&&this.updateElementVisibility(r.wrapper,r,e.visible),this.updateEdges(r),this.insertBlazorConnector(r);else{if(Ro(r=new te(this,"nodes",e,!0),e,this.nodeDefaults),r.parentId=e.parentId?e.parentId:r.parentId,r.umlIndex=e.umlIndex,r.status="New",(o="TextAnnotation"===r.shape.shape)&&!e.isTextAnnotationCopied&&(r.inEdges=e.inEdges?e.inEdges:r.inEdges),this.nodes.push(r),this.initObject(r,u,void 0,i),o&&this.bpmnModule)for(c=0;c-1&&e.parentId&&this.nameTable[e.parentId]&&"UmlClassifier"===this.nameTable[e.parentId].shape.type){var g=this.nameTable[e.parentId];g.children.splice(r.umlIndex,0,r.id),g.wrapper.children.splice(r.umlIndex,0,r.wrapper),g.wrapper.measure(new me),g.wrapper.arrange(g.wrapper.desiredSize),this.updateDiagramObject(g)}}if(a={element:r,cause:this.diagramActions,diagramAction:this.getDiagramAction(this.diagramActions),state:"Changed",type:"Addition",cancel:!1},this.parentObject&&(a.parentId=this.parentObject.id),"helper"!==e.id&&!(this.diagramActions&ee.PreventCollectionChangeOnDragOver)&&this.triggerEvent(Ce.collectionChange,a),!(this.diagramActions&ee.UndoRedo||this.diagramActions&ee.Group||this.diagramActions&ee.PreventHistory)){var v={type:"CollectionChanged",changeType:"Insert",undoObject:$(e),redoObject:$(e),category:"Internal"};this.addHistoryEntry(v)}this.parentObject=void 0,"SVG"===this.mode&&(this.updateSvgNodes(r),this.updateTextElementValue(r),this.updateDiagramObject(r),o&&this.updateDiagramObject(this.nameTable[r.inEdges[0]]),r.shape.activity&&r.shape.activity.subProcess.processes&&r.shape.activity.subProcess.processes.length&&this.updateProcesses(r),this.updateBridging())}}if(this.protectPropertyChange(s),this.resetDiagramActions(ee.PublicMethod),r&&this.layers.length>1&&this.moveNode(r),this.views)for(var S=0,b=this.views;S=0;l--)this.moveSvgNode(a[parseInt(l.toString(),10)])}for(var h=0,c=i;h=0;o--)r[parseInt(o.toString(),10)]===e.id&&r.splice(o,1);for(var a=0;s.ports&&a=0;s--)if(i=this.nameTable[r[parseInt(s.toString(),10)]])if(this.connectorTable[i.id]=$(i),i.isBpmnAnnotationConnector){var o=this.nameTable[i.targetID];this.removeObjectsFromLayer(i);var a=this.connectors.indexOf(i);-1!==a&&this.connectors.splice(a,1),this.removeElements(i),this.removeFromAQuad(i),delete this.nameTable[i.id];var l=this.nameTable[i.sourceID];if(l){var h=l.outEdges.indexOf(i.id);-1!==h&&l.outEdges.splice(h,1)}e.id!==i.targetID&&this.remove(o)}else this.remove(i)},t.prototype.removeObjectsFromLayer=function(e){if(e.children)for(var i=0;i-1&&(_r(this,e)&&this.unSelect(e),this.layers[parseInt(s.toString(),10)].objects.splice(a,1),delete this.layers[parseInt(s.toString(),10)].zIndexTable[this.nameTable[e.id].zIndex])},t.prototype.removeElements=function(e){if("SVG"===this.mode||"Canvas"===this.mode&&"Native"===e.shape.type){var i=xt(e.id+"_groupElement",this.element.id),r=e;if(r.ports&&r.ports.length>0)for(var s=0;s0){l[parseInt(s.toString(),10)].id.indexOf("icon_content")>0&&"SVG"===this.mode&&((h=xt(l[parseInt(s.toString(),10)].id+"_shape_groupElement",this.element.id))&&h.parentNode.removeChild(h),(h=xt(l[parseInt(s.toString(),10)].id+"_rect_groupElement",this.element.id))&&h.parentNode.removeChild(h));for(var c=0,d=this.views;c=0;o--)a.children[parseInt(o.toString(),10)].children&&(l=n.nameTable[a.children[parseInt(o.toString(),10)].id])&&(l.isLane?Jv(n,l):(n.removeDependentConnector(l),n.diagramActions|=ee.PreventHistory,l.constraints&ie.Delete?n.remove(l):q3(n,l,{},!1),n.diagramActions&=~ee.PreventHistory));a&&(i=n.nameTable[a.id])&&Jv(n,i)}}(this,e),!(this.diagramActions&ee.UndoRedo||this.diagramActions&ee.PreventHistory)&&(e instanceof te||e instanceof de)){var o={type:"CollectionChanged",changeType:"Remove",undoObject:$(e),redoObject:$(e),category:"Internal"};this.diagramActions&ee.Clear||e.children&&!e.isLane&&!e.isPhase&&e.children.length>0&&this.undoRedoModule&&"None"===this.layout.type&&(this.historyManager.startGroupAction(),s=!0),(e instanceof te||e instanceof de)&&this.deleteDependentConnector&&this.removeDependentConnector(e),!e.isLane&&!e.isPhase&&!(this.diagramActions&ee.Clear)&&!this.isStackChild(e)&&this.addHistoryEntry(o)}"TextAnnotation"===e.shape.shape&&this.removeDependentConnector(e),e.children&&!e.isLane&&!e.isPhase&&(!(this.diagramActions&ee.UndoRedo)||!ce())&&this.deleteGroup(e),e.parentId&&(this.deleteChild(e,void 0,!0),this.nameTable[e.parentId]&&"UmlClassifier"===this.nameTable[e.parentId].shape.type&&(this.updateDiagramObject(this.nameTable[e.parentId]),this.updateConnectorEdges(this.nameTable[e.parentId])));var a=void 0;this.diagramActions=this.diagramActions|ee.PublicMethod;var l=this.nameTable[e.id];if(l instanceof te?("Bpmn"===l.shape.type&&this.bpmnModule&&this.bpmnModule.removeBpmnProcesses(l,this),(l.isLane||l.isPhase||"SwimLane"===l.shape.type)&&(h=l.isLane||l.isPhase?this.nameTable[l.parentId]:this.nameTable[l.id],l.isLane?Q3(this,l,h):l.isPhase&&G3(this,l,h)),-1!==(a=this.nodes.indexOf(l))&&(this.crudDeleteNodes.push(this.nameTable[l.id]),this.nodes.splice(a,1),this.updateNodeEdges(l))):(-1!==(a=this.connectors.indexOf(l))&&(this.crudDeleteNodes.push(this.nameTable[l.id]),this.connectors.splice(a,1)),this.updateEdges(l),this.spliceConnectorEdges(e,!0),this.spliceConnectorEdges(e,!1)),!this.isServerUpdate&&!(this.blazorActions&on.GroupClipboardInProcess)&&this.commandHandler.getBlazorOldValues(),s&&this.historyManager.endGroupAction(),_r(this,l)&&this.unSelect(l),!l.isPhase){if(this.removeObjectsFromLayer(e),this.currentDrawingObject&&(this.currentDrawingObject.wrapper=void 0),delete this.nameTable[e.id],i.length>0&&i[0].id===l.id&&l.parentId){var h,d=this.nameTable[l.parentId];d&&d.isLane&&"SwimLane"===this.nameTable[d.parentId].shape.type&&Y3(this,h=this.nameTable[d.parentId],d,l)}this.removeElements(l),this.updateBridging(),"SVG"!==this.mode&&this.refreshDiagramLayer(),this.diagramActions&ee.Clear||(this.removeFromAQuad(l),r={element:e,cause:this.diagramActions,diagramAction:this.getDiagramAction(this.diagramActions),state:"Changed",type:"Removal",cancel:!1},"helper"!==e.id&&this.triggerEvent(Ce.collectionChange,r),this.resetTool())}}}else if(i.length>0){this.undoRedoModule&&(this.historyManager.startGroupAction(),this.blazorActions|=on.GroupingInProgress,s=!0);for(var u=0;u=p.wrapper.bounds.width&&"Horizontal"===p.shape.orientation||this.selectedItems.wrapper.bounds.y<=p.wrapper.bounds.y+g&&this.selectedItems.wrapper.bounds.height>=p.wrapper.bounds.height-g&&"Vertical"===p.shape.orientation)&&(kI(p)||p.shape.lanes.length>1)&&this.remove(i[parseInt(u.toString(),10)])}}else this.remove(i[parseInt(u.toString(),10)])}s&&(this.blazorActions&=~on.GroupingInProgress,this.isServerUpdate=!0,this.commandHandler.getBlazorOldValues(),this.UpdateBlazorDiagramModelCollection(void 0,void 0,void 0,!0),this.historyManager.endGroupAction(),this.isServerUpdate=!1),this.clearSelection()}e&&(kI(e)||this.diagramActions&ee.Clear)||this.diagramActions&ee.UndoRedo||this.diagramActions&ee.PreventHistory||!(e instanceof te||e instanceof de)||(o={type:"ConnectionChanged",undoObject:$(e),redoObject:$(e),category:"Internal"},!e.isLane&&!e.isPhase&&!(this.diagramActions&ee.Clear)&&!this.isStackChild(e)&&this.addHistoryEntry(o)),this.tooltipObject.close()},t.prototype.isStackChild=function(e){var i,r=this.nameTable[e.parentId];if(e&&e.parentId&&r.container&&"Stack"===r.container.type&&"UmlClassifier"!==this.nameTable[e.parentId].shape.type){i=!0;var s={sourceIndex:r.wrapper.children.indexOf(e.wrapper),source:e,target:void 0,targetIndex:void 0};this.diagramActions&ee.UndoRedo||this.addHistoryEntry({type:"StackChildPositionChanged",redoObject:{sourceIndex:void 0,source:e,target:void 0,targetIndex:void 0},undoObject:s,category:"Internal"})}return i},t.prototype.deleteChild=function(e,i,r){var s;if(s="string"==typeof e?e:e.id,(i=i?this.nameTable[i.id]:this.nameTable[e.parentId])&&i.children){for(var o=0;o=0;i--)this.removeLayer(this.layers[parseInt(i.toString(),10)].id);this.commandHandler.addLayer({id:"default_layer",visible:!0,lock:!1,objects:[],zIndex:0,objectZIndex:-1,zIndexTable:{}},null,!0),this.setActiveLayer(this.layers[this.layers.length-1].id)},t.prototype.clearObjects=function(e){var i=[];i=e||(i=i.concat(this.nodes)).concat(this.connectors),this.diagramActions=this.diagramActions|ee.Clear;for(var r=0,s=i;r0||"Text"===e.shape.type))if("Text"===e.shape.type)i=e.wrapper.children[0].id.split("_")[1];else for(var p=e.annotations.length-1;p>=0;p--)e.annotations[parseInt(p.toString(),10)].visibility&&(i=e.annotations[parseInt(p.toString(),10)].id);i&&(u=this.getWrapper(e.wrapper,i))}if(e&&u&&!(u instanceof es)&&(!function sne(n,t){return"Text"===t.shape.type?t.constraints&ie.ReadOnly:t.constraints&(t instanceof de?qe.ReadOnly:ie.ReadOnly)?n.constraints&Nr.InheritReadOnly?1:0:n.constraints&Nr.ReadOnly?1:0}(u,e)||f)){var g=u.style,v=void 0;v=90>(v=u.bounds.width50?50:e.width,u.style.fontSize)),e.parentId&&"UmlClassifier"===this.nameTable[e.parentId].shape.type?(l.width=e.wrapper.bounds.width-20,c=(e.wrapper.bounds.center.x+r.tx)*r.scale-l.width/2*s-2.5,d=(e.wrapper.bounds.center.y+r.ty)*r.scale-l.height/2*s-3,u.style.textAlign="Left"):(l.width=Math.max(l.width,50),c=(u.bounds.center.x+r.tx)*r.scale-l.width/2*s-2.5,d=(u.bounds.center.y+r.ty)*r.scale-l.height/2*s-3),Ho(y,{id:this.element.id+"_editTextBoxDiv",style:"position: absolute;left:"+c+"px;top:"+d+"px;width:"+(l.width+1)*s+"px;height:"+l.height*s+"px; containerName:"+e.id+";"}),Ho(S,{"aria-label":a,id:this.element.id+"_editBox",style:"width:"+(l.width+1)*s+"px;height:"+l.height*s+"px;resize: none;outline: none;overflow: hidden;;font-family:"+g.fontFamily+";font-size:"+g.fontSize*s+"px;text-align:"+u.style.textAlign.toLocaleLowerCase()+";",class:"e-diagram-text-edit"}),S.style.fontWeight=g.bold?"bold":"",S.style.fontStyle=g.italic?"italic":"",S.style.lineHeight=(1.2*g.fontSize+"px;").toString(),S.style.textDecoration=g.textDecoration?g.textDecoration:"",this.activeLabel.parentId=e.id,this.activeLabel.id=i,u.visible=!1,this.updateDiagramObject(e),this.diagramActions=this.diagramActions|ee.TextEdit,this.isTriggerEvent||(E.add(S,"input",this.eventHandler.inputChange,this.eventHandler),E.add(S,"focusout",this.focusOutEdit,this),S.select())}}}},t.prototype.updateConnectorfixedUserHandles=function(e){if(e.fixedUserHandles.length)for(var i=void 0,r=0,s=e.fixedUserHandles;r0&&this.mindMapChartModule.updateLayout(o,this.nameTable,this.layout,l,this.dataSourceSettings.id,this.dataSourceSettings.root),e=!0;else if(this.radialTreeModule)this.radialTreeModule.updateLayout(o,this.nameTable,this.layout,l),e=!0;else if(this.symmetricalLayoutModule)this.symmetricalLayoutModule.maxIteration=this.layout.maxIteration,this.symmetricalLayoutModule.springLength=this.layout.springLength,this.symmetricalLayoutModule.springFactor=this.layout.springFactor,this.symmetricalLayoutModule.updateLayout(o,this.connectors,this.symmetricalLayoutModule,this.nameTable,this.layout,l),e=!0;else if(this.complexHierarchicalTreeModule){this.canDistribute(a,r)&&(this.lineDistributionModule.diagram=this,this.connectors.forEach(function(P){P.obstaclePointCollection=[]}));var c=this.complexHierarchicalTreeModule.getLayoutNodesCollection(this.nodes);c.length>0&&this.complexHierarchicalTreeModule.doLayout(c,this.nameTable,this.layout,l,this),e=!0,this.canDistribute(a,r)&&this.lineDistributionModule.initLineDistribution(this.layout,this)}else this.flowchartLayoutModule?(this.flowchartLayoutModule.updateLayout(this.nodes,this),e=!0):console.warn("[WARNING] :: Module "+("OrganizationalChart"===this.layout.type?"HierarchicalTree":this.layout.type)+" is not available in Diagram component! You either misspelled the module name or forgot to load it.");if(e){this.preventDiagramUpdate=!0;for(var u={},p=0,g=o;p0)for(var S=0;S0)for(var M=0;M0)for(var s=0,o=r.ports;s0&&function Rse(n){var t,e,i,r=[];for(t=0;t0&&y.connectors[w].bezierSettings&&y.connectors[w].bezierSettings.allowSegmentsReset&&(y.connectors[w].segments=[]);if(t.connectors=y.connectors||[],t.dataSourceSettings=y.dataSourceSettings||{},t.dataSourceSettings.doBinding=i,t.height=y.height||"100%",t.setNodeTemplate=r,t.getConnectorDefaults=v,t.getNodeDefaults=g,t.getCustomProperty=o,t.mode=y.mode||"SVG",y.nodes)for(w=0;w0)){var r=this.nodes.filter(function(a){return 0===a.inEdges.length})[0],s=this.convertMindmapToMermaid(r,0);i.push(s),this.updateTextDataSource(i,r.outEdges,1),e=(i=i.filter(function(a){return""!==a.trim()})).join("\n")}return e},t.prototype.updateTextDataSource=function(e,i,r){for(var s=0;s0&&this.updateTextDataSource(e,h,r+1),s++}},t.prototype.convertMindmapToMermaid=function(e,i){var r=e.id,o=" ".repeat(2*(i+1)),a=e.annotations.length>0?e.annotations[0].content.replace(/\n/g," "):"",l=o+a,h=o+r;if(e.shape&&"Basic"===e.shape.type){var c=e.shape;"Rectangle"===c.shape?l=h+"["+a+"]":"Ellipse"===c.shape?l=h+"(("+a+"))":"Hexagon"===c.shape&&(l=h+"{{"+a+"}}")}else if(e.shape&&"Flow"===e.shape.type)"Terminator"===e.shape.shape&&(l=h+"("+a+")");else if(e.shape&&"Path"===e.shape.type){var u=e.shape;u.data===this.bangShape?l=h+"))"+a+"((":u.data===this.cloudShape&&(l=h+")"+a+"(")}return l},t.prototype.saveFlowDiagramInMermaidFormat=function(){var e=this,i=[],r="graph TD\n",s={nodes:this.nodes,edges:this.connectors};return s.nodes.reduce(function(a,l){return a[l.id]=l.annotations.length?l.annotations[0].content:"",a},{}),s.edges.forEach(function(a){var l=a.sourceID,h=a.targetID,f=e.nameTable[""+h],p=e.getNodeShape(e.nameTable[""+l]),g=e.getNodeShape(f),v=a.annotations[0]&&""!==a.annotations[0].content?"|"+a.annotations[0].content+"|":"";-1===i.indexOf(l)?i.push(l):p="",-1===i.indexOf(h)?i.push(h):g="";var y=e.arrowType(a);r+=" "+l+p+" "+y+v+" "+h+g+"\n"}),s.nodes.forEach(function(a){r+=" style "+a.id+" fill:"+a.style.fill+",stroke:"+a.style.strokeColor+",stroke-width:"+a.style.strokeWidth+"px;\n"}),r},t.prototype.arrowType=function(e){var i=e.targetDecorator.shape;return e.style.opacity<1?"~~~":""!==e.style.strokeDashArray?"-.->":"Arrow"===i?e.style.strokeWidth>1?"==>":"--\x3e":"None"===i?"---":"--\x3e"},t.prototype.getNodeShape=function(e){var i=e.annotations.length>0?e.annotations[0].content:"",r=e.shape.shape;if(!r){var s=e.shape.data;return"M 0 0 A 1 1 0 0 0 7 0 A 1 1 0 0 0 0 0 M -1 0 A 1 1 0 0 0 8 0 A 1 1 0 0 0 -1 0"===s?"((("+i+")))":"M 0 0 L 1 -1 L 5 -1 L 6 0 L 0 0"===s?"[/"+i+"\\]":"M 0 1 L 0 6 C 2 7 4 7 6 6 L 6 1 C 5 0 1 0 0 1 C 1 2 5 2 6 1"===s?"[("+i+")]":"M 0 0 L 12 0 L 14 2 L 2 2 L 0 0"===s?"[\\"+i+"\\]":"M 0 0 L 5 0 L 4 1 L 1 1 L 0 0"===s?"[\\"+i+"/]":"M 0 0 L 2 -2 L 11 -2 L 13 0 L 11 2 L 2 2 L 0 0"===s?"{{"+i+"}}":">"+i+"]"}switch(r){case"Terminator":return"(["+i+"])";case"Process":default:return"["+i+"]";case"Decision":return"{"+i+"}";case"Parallelogram":return"[/"+i+"/]";case"Ellipse":return"(("+i+"))";case"PreDefinedProcess":return"[["+i+"]]"}},t.prototype.loadDiagramFromMermaid=function(e){this.layout&&"Flowchart"===this.layout.type&&this.flowchartLayoutModule?this.convertMermaidToFlowChart(e):this.layout&&"MindMap"===this.layout.type&&this.mindMapChartModule?this.convertMermaidToMindmap(e):console.warn('[WARNING] :: Module "FlowchartLayout" or "MindMap" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.countLeadingSpaces=function(e){for(var i=0,r=e.length;i0});this.clear(),this.mermaidNodeBaseCollection=[];var r=[],s={text:"",children:[],currentLevel:0,branch:"Left"},o=[],l=!1,h=!1,c=!1;if(i.length>0){for(var d=function(M){var w=i[parseInt(M.toString(),10)],C=0,D="",A=u.countLeadingSpaces(w),x=w.includes('"`');if(h=w.includes('`"'),c=(l=!!x||l)||c?c:0===A&&M>0,l&&h&&!x)return s.text+="\n"+w,l=!1,"continue";if(!x&&l)return s.text+="\n"+w,"continue";if(l=!h&&l,w.length>0&&(/\s/.test(w[0])&&M>0||0===A)){if(-1!==o.findIndex(function(B){return B.space===A.toString()}))for(var L=o.length-1;L>=0;L--){var O=o[parseInt(L.toString(),10)];if((N=parseFloat(O.space))>A)o.splice(L,1);else{if(N=0;L--){var N,T=o[parseInt(L.toString(),10)];if(!((N=parseFloat(T.space))>A)){var z=o[o.length-1];o.push({space:A.toString(),level:z.level+1});break}o.splice(L,1)}C=o[o.length-1].level}D=w.trim().replace(/^[+-]/,"")}var U={text:D,branch:void 0,children:[],currentLevel:0===M?0:C-1};if(r.length>0){for(;r.length>=C&&0!==r.length;)r.pop();r.length>0&&r[r.length-1].children.push(U)}r.push(U),s=U},u=this,f=0;f0){var c=h[h.length-1];c.arrowType=a[2],""!==a[3]&&(c.label&&c.label.some(function(d){return d.trim().length>0})?c.label.push(a[3]):(c.label=[],c.label[c.parentId.length-1]=a[3]))}h.filter(function(d){return d.parentId&&0===d.parentId.length}).forEach(function(d){d.parentId=null}),i=i.concat(h)}}this.createFlowChart(i),this.doLayout(),this.clearHistory()},t.prototype.createFlowChart=function(e){for(var i=[],r=0;r1)for(var h=0;h|---|--\s*.*?\s*-->|~~~|==>|===|==\s*.*?\s*==>|\s*-\.\s*->|\s*-\.\s*-|\s*-\.\s*.*?\s*\.\s*->|\s*-\..*?\.\s*->)(.*)$/);if(l){i=l[1].trim();var h=l[2].trim();r=l[3].trim();var d=h.match(/(-\.|\\-\\-|==|--|~~)(.*?)(\1>|\.->|==>|\\->|~~>)/),u=void 0,f="";o=null!==(u=d?{text:d[2].trim()||null,arrowType:d[1]+d[3]}:{text:null,arrowType:h}).text?u.text:"",s=(f=u.arrowType).includes("--\x3e")?"single-line-arrow":f.includes("---")?"single-line":f.includes("==>")?"double-line-arrow":f.includes("==")?"double-line":f.includes("~~~")?"wiggly-arrow":f.includes("-.->")||f.includes(".->")?"dotted-arrow":f.includes("-.-")||f.includes(".-")?"dotted":"single-line-arrow"}return[i,r,s,o]},t.prototype.parseStyle=function(e,i){if(e.startsWith("style")){var s=e.match(/^style\s+(\w+)\s+fill:([^,]+),stroke:([^,]+),stroke-width:(\d+)px;/);if(s){var c={id:s[1],fill:s[2],stroke:s[3],strokeWidth:parseInt(s[4],10)},d=i.filter(function(u){return u.id===c.id});d[0].color=c.fill,d[0].stroke=c.stroke,d[0].strokeWidth=c.strokeWidth}}},t.prototype.getNodeData=function(e,i,r){for(var s=[],o=null,a=null,l=0,h="",c=function(v){var y=e[parseInt(v.toString(),10)],S=d.splitNested(y);if(S[0].includes("|")){var b=S[0].match(/\|([^|]*)\|/);b&&(h=b[1]);var M=S[0].split("|");M.length>=3&&(S[0]=M[2].trim())}var w=S[0].trim();if(0===v?o=w:a=w,i.find(function(L){return L.id===w}))l++;else{var D=S.length>1?S[1]:S[0],A=d.getShape(D),x=D.replace(/[\\[\]\\(\\)\\{\\}\\{\\}\\/>]/g,"");s.push({id:w,name:x,shape:A,color:"white",parentId:[]})}},d=this,u=0;u"===h?0===s?(r.trim().length>0&&i.push(r.trim()),r=h,o=h,s++):(r+=h,s++):"]"===h||"}"===h||")"===h?1===s&&h===o?(i.push((r+=h).trim()),r="",s--):s>1?(r+=h,s--):r+=h:r+=h}return r.trim().length>0&&i.push(r.trim()),i},t.prototype.getShape=function(e){var i={};return e.startsWith("(((")?i={type:"Path",data:"M 0 0 A 1 1 0 0 0 7 0 A 1 1 0 0 0 0 0 M -1 0 A 1 1 0 0 0 8 0 A 1 1 0 0 0 -1 0"}:e.startsWith("((")?i={shape:"Ellipse",type:"Basic"}:e.startsWith("([")?i={type:"Flow",shape:"Terminator"}:e.startsWith("(")?i={type:"Flow",shape:"Process"}:e.startsWith("[[")?i={type:"Flow",shape:"PreDefinedProcess"}:e.startsWith("[/")?i=e.endsWith("/]")?{type:"Basic",shape:"Parallelogram"}:{type:"Path",data:"M 0 0 L 1 -1 L 5 -1 L 6 0 L 0 0"}:e.startsWith("[(")?i={type:"Path",data:"M 0 1 L 0 6 C 2 7 4 7 6 6 L 6 1 C 5 0 1 0 0 1 C 1 2 5 2 6 1"}:e.startsWith("[\\")?i=e.endsWith("\\]")?{type:"Path",data:"M 0 0 L 12 0 L 14 2 L 2 2 L 0 0"}:{type:"Path",data:"M 0 0 L 5 0 L 4 1 L 1 1 L 0 0"}:e.startsWith("[")?i={type:"Basic",shape:"Rectangle"}:e.startsWith("{{")?i={type:"Path",data:"M 0 0 L 2 -2 L 11 -2 L 13 0 L 11 2 L 2 2 L 0 0"}:e.startsWith("{")?i={type:"Flow",shape:"Decision"}:e.startsWith(">")&&(i={type:"Path",data:"M 0 0 L 8 0 L 8 2 L 0 2 L 2 1 L 0 0"}),i},t.prototype.getDiagramContent=function(e){return this.printandExportModule?this.printandExportModule.getDiagramContent(e):(console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),"")},t.prototype.exportImage=function(e,i){this.printandExportModule?this.printandExportModule.exportImages(e,i):console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.printImage=function(e,i){this.printandExportModule?(i.printOptions=!0,this.printandExportModule.exportImages(e,i)):console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.setStackLimit=function(e){this.undoRedoModule&&e&&(this.historyManager.stackLimit=e,this.undoRedoModule.applyLimit(this.historyManager.currentEntry,e,this,!0))},t.prototype.clearHistory=function(){this.undoRedoModule&&this.undoRedoModule.clearHistory(this)},t.prototype.getDiagramBounds=function(){if(this.printandExportModule){var e=this.printandExportModule.getDiagramBounds("",{});return e.width=e.width>this.scrollSettings.viewPortWidth?e.width+(e.x>0?e.x:0):this.scrollSettings.viewPortWidth,e.height=e.height>this.scrollSettings.viewPortHeight?e.height+(e.y>0?e.y:0):this.scrollSettings.viewPortHeight,e.x=e.x>0?0:e.x,e.y=e.y>0?0:e.y,e}return console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),new Ne},t.prototype.exportDiagram=function(e){return this.printandExportModule?this.printandExportModule.exportDiagram(e):(console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),"")},t.prototype.print=function(e){this.printandExportModule?this.printandExportModule.print(e):console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.addPorts=function(e,i){var s;this.protectPropertyChange(!0),e=this.nameTable[e.id]||e,i.length>1&&this.startGroupAction();for(var o=function(h){if(e.ports.some(function(y){return y.id===i[parseInt(h.toString(),10)].id}))return"continue";if(e instanceof te?(s=new Es(e,"ports",i[parseInt(h.toString(),10)],!0),e.ports.push(s)):e instanceof de&&(s=new Tc(e,"ports",i[parseInt(h.toString(),10)],!0),e.ports.push(s)),e.children)for(var c=e.wrapper,d=0;d1&&this.endGroupAction(),e.wrapper.measure(new me(e.width,e.height)),e.wrapper.arrange(e.wrapper.desiredSize),this.updateDiagramObject(e),this.protectPropertyChange(!1)},t.prototype.addConstraints=function(e,i){return e|i},t.prototype.removeConstraints=function(e,i){return e&~i},t.prototype.addNodeLabels=function(e,i){this.addLabels(e,i)},t.prototype.addConnectorLabels=function(e,i){this.addLabels(e,i)},t.prototype.addLabels=function(e,i){this.protectPropertyChange(!0);var s,r=(e=this.nameTable[e.id]||e).wrapper;i.length>1&&this.startGroupAction();for(var o=0;o1&&this.endGroupAction(),e.wrapper.measure(new me(r.width,r.height)),e.wrapper.arrange(r.desiredSize),this.updateDiagramObject(e),this.protectPropertyChange(!1),this.refreshCanvasLayers()},t.prototype.addChildToUmlNode=function(e,i,r){var s,o,a,l,h="NoWrap";"Class"===e.shape.classifier||"Interface"===e.shape.classifier?"Method"===r?(o=new fm(e,"",i),"Class"===e.shape.classifier?(e.shape.classShape.methods.push(o),s=e.shape.classShape):"Interface"===e.shape.classifier&&(e.shape.interfaceShape.methods.push(o),s=e.shape.interfaceShape),function soe(n,t,e,i){if(e.methods&&e.methods.length){var r=e.methods,s="",o="",a=void 0,l=1,h=void 0,c=0,d=0,u=n.shape,g="Class"===u.classifier?u.classShape:u.interfaceShape;1===r.length?g.attributes.length>0?(c=g.attributes.filter(function(w){return w.isSeparator}).length,h=(l=2+g.attributes.length+c)+1,aT(n,t,l)):h=l+1:(c=g.attributes.filter(function(w){return w.isSeparator}).length,d=g.methods.filter(function(w){return w.isSeparator}).length,h=(l=2+g.attributes.length+c+g.methods.length+d)+1);for(var v=0;v1&&this.startGroupAction();for(var r=i.length-1;r>=0;r--)if(e.children&&e.children.length>0){var s=e.wrapper.children.filter(function(o){return o.id===e.id+"group_container"});s&&s.length>0&&this.removelabelExtension(e,i,r,s[0])}else this.removelabelExtension(e,i,r,e.wrapper);i.length>1&&this.endGroupAction(),this.refreshCanvasLayers()},t.prototype.removePortsExtenion=function(e,i,r,s){for(var o=0;o1&&this.startGroupAction();for(var r=i.length-1;r>=0;r--)if(e.children&&e.children.length>0)for(var s=0;s1&&this.endGroupAction()},t.prototype.getSizeValue=function(e,i){var r;return r=e.toString().indexOf("px")>0?e.toString():e.toString().indexOf("%")>0?void 0!==i?"100%":e.toString():e.toString()+"px",i&&(Za(this),r="calc("+r+" - "+i+"px)"),r},t.prototype.renderRulers=function(){this.rulerSettings.showRulers?(function ise(n){var t=Za(n),i=Tt("div",{id:n.element.id+"_overlapRuler",style:"height:"+t.height+"px;width:"+t.width+"px;position:absolute;left:0;top:0",class:"e-ruler-overlap"});n.element.insertBefore(i,n.element.firstChild)}(this),oF(this,!0),oF(this,!1)):qx(this)},t.prototype.intOffPageBackground=function(){var e=new me;e=Za(this);var i=document.getElementById(this.element.id+"content"),r=this.getSizeValue(this.width,e.width),s=this.getSizeValue(this.height,e.height),o=this.rulerSettings.showRulers?"width:"+r+"; height:"+s+";top:"+e.height+"px;left:"+e.width+"px;overflow: scroll;position:absolute;overflow:auto;":"width:"+r+"; height:"+s+";position:absolute; left:0px; top:0px;overflow: auto;",a={id:this.element.id+"content",tabindex:"0",style:o};i?(this.diagramCanvas=i,Ka(this.diagramCanvas,o)):(this.diagramCanvas=Tt("div",a),this.element.appendChild(this.diagramCanvas)),this.diagramCanvas.style.background=this.backgroundColor},t.prototype.initDiagram=function(){this.intOffPageBackground(),Ho(this.element,{style:"width:"+this.getSizeValue(this.width)+"; height:"+this.getSizeValue(this.height)+";position:relative;overflow:hidden;"})},t.prototype.renderHiddenUserHandleTemplateLayer=function(e){var r=Tt("div",{class:this.element.id+"_hiddenUserHandleTemplate",style:"width:"+e.width+"px; height:"+e.height+"px;visibility:hidden ; overflow: hidden;"});this.element.appendChild(r)},t.prototype.renderBackgroundLayer=function(e,i){var r=this.createSvg(this.element.id+"_backgroundLayer_svg",e.width,e.height);Ka(r,i);var s=Fi("g",{id:this.element.id+"_backgroundImageLayer",class:"e-background-image-layer"});r.appendChild(s);var a=Fi("g",{id:this.element.id+"_backgroundLayer",class:"e-background-layer"});r.appendChild(a),this.diagramCanvas.appendChild(r)},t.prototype.renderGridLayer=function(e,i){var r=this.createSvg(this.element.id+"_gridline_svg",e.width,e.height);r.setAttribute("class","e-grid-layer");var s=Fi("g",{id:this.element.id+"_gridline"}),o=Fi("rect",{id:this.element.id+"_grid_rect",x:"0",y:"0",width:"100%",height:"100%"});if(lm()){var a=new URL(window.location.href);o.setAttribute("fill",""!==a.search?"url(#"+this.element.id+"_pattern)":"url("+location.protocol+"//"+location.host+location.pathname+"#"+this.element.id+"_pattern)")}else o.setAttribute("fill","url(#"+this.element.id+"_pattern)");s.appendChild(o),r.appendChild(s),this.diagramCanvas.appendChild(r),ti(r,{style:i})},t.prototype.renderDiagramLayer=function(e,i){if(this.diagramLayerDiv=Tt("div",{id:this.element.id+"_diagramLayer_div",style:"width:"+e.width+"px; height:"+e.height+"px;"+i}),"SVG"===this.mode){var s=this.createSvg(this.element.id+"_diagramLayer_svg",e.width,e.height);s.style["pointer-events"]="none",s.setAttribute("class","e-diagram-layer");var o=Fi("g",{id:this.element.id+"_diagramLayer"}),a=Fi("g",{});this.diagramLayer=o,s.style["pointer-events"]="all",a.appendChild(o),s.appendChild(a),this.diagramLayerDiv.appendChild(s)}else this.diagramLayer=bo.createCanvas(this.element.id+"_diagram",e.width,e.height),Ka(this.diagramLayer,"position:absolute;left:0px;top:0px;"),this.diagramLayerDiv.appendChild(this.diagramLayer);this.diagramCanvas.appendChild(this.diagramLayerDiv)},t.prototype.initLayers=function(){var e="position:absolute;top:0px;left:0px;overflow:hidden;pointer-events:none;",r=document.getElementById(this.element.id).getBoundingClientRect(),s=function Loe(){var n=Tt("div",{style:"visibility:hidden; width: 100px"});document.body.appendChild(n);var t=n.getBoundingClientRect().width;n.style.overflow="scroll";var e=Tt("div",{style:"width:100%"});n.appendChild(e);var i=e.getBoundingClientRect().width;return n.parentNode.removeChild(n),t-i}();this.scroller.scrollerWidth=s,this.scroller.setViewPortSize(r.width,r.height),this.renderRulers();var o="measureElement";window[""+o]&&(window[""+o]=null,document.getElementById("measureElement").remove()),function WF(){var n="measureElement";if(window[""+n])window[""+n].usageCount+=1;else{var t=Tt("div",{id:"measureElement",style:"visibility:hidden ; height: 0px ; width: 0px; overflow: hidden;"}),e=Tt("span",{style:"display:inline-block ; line-height: normal"});t.appendChild(e);var i=Tt("img",{alt:"measureElementImage",src:"data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7"});t.appendChild(i);var r=document.createElementNS("http://www.w3.org/2000/svg","svg");r.setAttribute("xmlns:xlink","http://www.w3.org/1999/xlink"),t.appendChild(r);var s=document.createElementNS("http://www.w3.org/2000/svg","path");s.setAttribute("d",""),r.appendChild(s),document.createTextNode("");var a=document.createElementNS("http://www.w3.org/2000/svg","text");a.setAttributeNS("http://www.w3.org/XML/1998/namespace","xml:space","preserve"),r.appendChild(a),window[""+n]=t,window[""+n].usageCount=1,document.body.appendChild(t);var l="measureElementCount";window[""+l]?window[""+l]++:window[""+l]=1}}(),this.renderBackgroundLayer(r,e),this.renderGridLayer(r,e),this.renderDiagramLayer(r,e),this.renderHTMLLayer(r,e),this.renderPortsExpandLayer(r,e),this.renderNativeLayer(r,e),this.renderAdornerLayer(r,e),this.renderHiddenUserHandleTemplateLayer(r)},t.prototype.renderAdornerLayer=function(e,i){var r=Tt("div",{id:this.element.id+"_diagramAdornerLayer",style:"width:"+e.width+"px;height:"+e.height+"px;"+i}),s=Tt("div",{id:this.element.id+"_diagramUserHandleLayer",style:"width:"+e.width+"px;height:"+e.height+"px;"+i});s.setAttribute("class","e-userHandle-layer"),r.appendChild(s);var o=this.createSvg(this.element.id+"_diagramAdorner_svg",e.width,e.height);o.setAttribute("class","e-adorner-layer"),o.style["pointer-events"]="none",this.adornerLayer=Fi("g",{id:this.element.id+"_diagramAdorner"}),this.adornerLayer.style[" pointer-events"]="all",o.appendChild(this.adornerLayer),r.appendChild(o),this.diagramCanvas.appendChild(r);var a=Fi("g",{id:this.element.id+"_SelectorElement"});this.adornerLayer.appendChild(a),ti(o,{style:"pointer-events:none;"})},t.prototype.renderPortsExpandLayer=function(e,i){var r=this.createSvg(this.element.id+"_diagramPorts_svg",e.width,e.height);r.setAttribute("class","e-ports-expand-layer");var s=Fi("g",{id:this.element.id+"_diagramPorts",class:"e-ports-layer",style:"pointer-events: all;"});r.appendChild(s);var o=Fi("g",{id:this.element.id+"_diagramExpander",class:"e-expand-layer",style:"pointer-events: all;"});r.appendChild(o),this.diagramCanvas.appendChild(r),ti(r,{style:i})},t.prototype.renderHTMLLayer=function(e,i){this.htmlLayer=Tt("div",{id:this.element.id+"_htmlLayer",style:"width:"+e.width+"px; height:"+e.height+"px;position:absolute;top:0px;left:0px;overflow:hidden;pointer-events:none;",class:"e-html-layer"});var r=Tt("div",{id:this.element.id+"_htmlLayer_div",style:"position:absolute;top:0px;left:0px;pointer-events:all;"});this.htmlLayer.appendChild(r),this.diagramCanvas.appendChild(this.htmlLayer)},t.prototype.renderNativeLayer=function(e,i){var r=this.createSvg(this.element.id+"_nativeLayer_svg",e.width,e.height),s=Fi("g",{id:this.element.id+"_nativeLayer",style:"pointer-events:all;"});r.appendChild(s),this.diagramLayerDiv.appendChild(r),ti(r,{class:"e-native-layer",style:i})},t.prototype.createSvg=function(e,i,r){var s=document.createElementNS("http://www.w3.org/2000/svg","svg");return ti(s,{id:e,width:i,height:r}),s},t.prototype.updateBazorShape=function(){for(var e=0;e1,i=[],r={},s={},o=[],a=0,l=this.nodes;a0||b&&b.children&&b.children.length>0)&&(M=!1),S&&S.wrapper&&b&&b.wrapper&&M?this.initConnectors(r[""+h],p):i.push(r[""+h])}else b=r[y.targetID],(S=r[y.sourceID])&&S.children&&S.children.length>0||b&&b.children&&b.children.length>0?i.push(r[""+h]):this.initConnectors(r[""+h],p);else r[""+h].children?o.push(h):r[""+h].shape instanceof uT&&r[""+h].shape.activity.subProcess.processes&&r[""+h].shape.activity.subProcess.processes.length>0?s[r[""+h].id]=h:this.initNodes(r[""+h],p);if(this.bpmnModule)for(var w=0,C=this.bpmnModule.bpmnTextAnnotationConnector;w-1&&-1===r.indexOf(c)&&-1===s.indexOf(c)&&r.splice(0,0,c);-1===r.indexOf(o)&&s.push(o)}return r.concat(s)},t.prototype.addToLayer=function(e,i){var r;if(i&&(r=this.commandHandler.getObjectLayer(e.id)),(!i||!r)&&-1===this.activeLayer.objects.indexOf(e.id)&&this.activeLayer.objects.push(e.id),(e instanceof te||e instanceof de)&&("SwimLane"!==e.shape.type||e.children&&e.children.length>0)){if(e.parentId){var s=this.swimlaneZIndexTable[e.parentId],o=this.swimlaneChildTable[e.id];(s&&-1!==s||o&&-1!==o)&&(e.zIndex=this.swimlaneChildTable[e.id])}e instanceof de&&e.sourceID&&e.targetID?-1!==this.activeLayer.objects.indexOf(e.sourceID)&&-1!==this.activeLayer.objects.indexOf(e.targetID)&&this.setZIndex(r||this.activeLayer,e):this.setZIndex(r||this.activeLayer,e)}},t.prototype.updateLayer=function(e){for(var i=0,r=Object.keys(e.layers);i0)for(r=0;rs;l--)r.zIndexTable[parseInt(l.toString(),10)]=r.zIndexTable[l-1],this.nameTable[r.zIndexTable[parseInt(l.toString(),10)]]&&(this.nameTable[r.zIndexTable[parseInt(l.toString(),10)]].zIndex=l);r.zIndexTable[parseInt(a.toString(),10)]=i.id}}},t.prototype.initializeDiagramLayers=function(){for(var e=0;ethis.layers[parseInt(a.toString(),10)].zIndex&&(i=this.layers[parseInt(e.toString(),10)],this.layers[parseInt(e.toString(),10)]=this.layers[parseInt(a.toString(),10)],this.layers[parseInt(a.toString(),10)]=i);0===this.layers.length&&this.commandHandler.addLayer({id:"default_layer",visible:!0,lock:!1,objects:[],zIndex:0,objectZIndex:-1,zIndexTable:{}},null,!0),this.setActiveLayer(this.layers[this.layers.length-1].id)},t.prototype.resetTool=function(){this.eventHandler.resetTool()},t.prototype.initObjectExtend=function(e,i,r){if(r){var s=this.commandHandler.checkBoundaryConstraints(void 0,void 0,e.wrapper.bounds,!0);if("SwimLane"===e.shape.type)for(var o=0,a=Object.keys(i.zIndexTable);o0)&&this.setZIndex(i,e)),e instanceof te){if(r){if("helper"!==e.id&&(o=Zi(this.getNodeDefaults))){if((a=o(e,this))&&a.ports)for(var l=0;l0)for(l=0;l0&&!e.container||e.processId){var r=this.nameTable[e.id];if(!(this.realActions&$i.PreventScale||this.realActions&$i.PreventDrag)){if(r.offsetX&&(this.realActions&$i.EnableGroupAction||!(this.diagramActions&ee.UndoRedo||this.diagramActions&ee.ToolAction||this.diagramActions&ee.PublicMethod))){this.realActions|=$i.PreventScale;var s=r.offsetX-e.wrapper.offsetX;r.offsetX=e.wrapper.offsetX;var o=r.offsetY-e.wrapper.offsetY;r.offsetY=e.wrapper.offsetY,s+o!==0&&this.drag(r,s,o),this.realActions&=~$i.PreventScale}else r.offsetX=e.wrapper.offsetX;r.offsetY&&(this.realActions&$i.EnableGroupAction||!(this.diagramActions&ee.UndoRedo||this.diagramActions&ee.ToolAction||this.diagramActions&ee.PublicMethod))?(this.realActions|=$i.PreventScale,o=r.offsetY-e.wrapper.offsetY,r.offsetY=e.wrapper.offsetY,this.drag(r,0,o),this.realActions&=~$i.PreventScale):r.offsetY=e.wrapper.offsetY,this.diagramActions&&(r.width=e.wrapper.actualSize.width,r.height=e.wrapper.actualSize.height)}}i&&e.children&&e.children.length>0&&(void 0!==this.nameTable[e.id].width?this.scaleObject(e,this.nameTable[e.id].width,!0):this.nameTable[e.id].width=e.wrapper.actualSize.width,void 0!==this.nameTable[e.id].height?this.scaleObject(e,this.nameTable[e.id].height,!1):this.nameTable[e.id].height=e.wrapper.actualSize.height)},t.prototype.initNode=function(e,i,r){var a,f,s=e.initContainer(),o=new Mi;if(this.diagramSettings.inversedAlignment||(s.inversedAlignment=!1),s.children||(s.children=[]),e.children){s.measureChildren=!1,o.id=e.id+"group_container",o.style.fill=e.shape&&"SwimLane"===e.shape.type?e.style.fill:"none",o.style.strokeColor="none",o.horizontalAlignment="Stretch",o.verticalAlignment="Stretch",o.pivot=e.pivot,s.style=e.style,s.padding.left=e.padding.left,s.padding.right=e.padding.right,s.padding.top=e.padding.top,s.padding.bottom=e.padding.bottom,o.children=[],o.preventContainer=!0,e.container&&(o.relativeMode="Object");var l=!!(e.ports&&e.ports.length>0);if(m(e.container)&&!l&&s.children.push(o),e.container&&"Grid"===e.container.type)for(var h=0;h0&&e.wrapper.children[0]instanceof Gv){if(this.setZIndex(this.activeLayer,e),this.connectors.length>0)for(h=0;h0?i.phases.length:0,v="Horizontal"===i.orientation,y=v?i.phases.length||1:s.length+1,S=v?(i.header&&i.hasHeader?1:0)+(i.phases.length>0?1:0)+i.lanes.length:(i.header&&i.hasHeader?1:0)+i.phases.length;if(0===h&&!v&&i.lanes.length&&(S+=1),v?(a=(i.header&&i.hasHeader?1:0)+(h>0?1:0),l=0):(a=i.header&&i.hasHeader?1:0,l=h>0?1:0),s.length>0)for(o+=i.header&&i.hasHeader?i.header.height:0,f=0;fl?d.margin.left=d.margin.left-(u.bounds.left-e.bounds.left):u.children[0].children[1].actualSize.width+r>=d.margin.left&&(d.margin.left=u.children[0].children[1].actualSize.width+r),d.margin.lefta?d.margin.top=d.margin.top-(u.bounds.top-o):u.children[0].children[1].actualSize.height+r>=d.margin.top&&(d.margin.top=u.children[0].children[1].actualSize.height+r),d.margin.left0)for(o=0;o0&&this.updateChildPosition(e)},t.prototype.addBpmnAnnotationConnector=function(e,i){if(e.parentObj instanceof t||e.parentObj instanceof Fd){var r=e.shape,o=""!==r.textAnnotation.textAnnotationTarget&&this.nameTable[r.textAnnotation.textAnnotationTarget],a=o?this.nameTable[r.textAnnotation.textAnnotationTarget]:null,l=null!=a?a.wrapper:null,h=e.ports[0],c={x:0,y:0};switch(r.textAnnotation.textAnnotationDirection){case"Left":h.offset={x:0,y:.5},c.x=i.bounds.left-40,c.y=i.bounds.bottom+30;break;case"Right":h.offset={x:1,y:.5},c.x=i.bounds.right+40,c.y=i.bounds.bottom+30;break;case"Top":h.offset={x:.5,y:0},c.x=i.bounds.right+30,c.y=i.bounds.top-40;break;case"Bottom":h.offset={x:.5,y:1},c.x=i.bounds.right+30,c.y=i.bounds.bottom+40;break;default:h.offset={x:0,y:.5},c.x=i.bounds.left-40,c.y=i.bounds.bottom+30,o&&null!=i&&null!=l&&(i.bounds.left>l.bounds.right?h.offset={x:0,y:.5}:i.bounds.rightl.bounds.top?h.offset={x:.5,y:0}:i.bounds.top0&&this.updateChildPosition(r)}},t.prototype.canExecute=function(){return!0},t.prototype.updateStackProperty=function(e,i,r){e.container&&"Stack"===e.container.type&&(i.width||(i.wrapper.horizontalAlignment="Stretch",i.horizontalAlignment="Stretch"),i.height||(i.verticalAlignment="Stretch",i.wrapper.verticalAlignment="Stretch"),r&&"UmlClassifier"===e.shape.type&&(i.umlIndex=r))},t.prototype.initViews=function(){this.isLoading||(this.views.push(this.element.id),this.views[this.element.id]=this)},t.prototype.initCommands=function(){var e=this.commandManager.commands,i={copy:{execute:this.copyCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.C,keyModifiers:ft.Control}},paste:{execute:this.pasteCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.V,keyModifiers:ft.Control}},cut:{execute:this.cutCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.X,keyModifiers:ft.Control}},delete:{execute:this.removeCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Delete}},selectAll:{execute:this.selectAll.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.A,keyModifiers:ft.Control}},undo:{execute:this.undo.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Z,keyModifiers:ft.Control}},redo:{execute:this.redo.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Y,keyModifiers:ft.Control}},nudgeUp:{execute:this.nudgeCommand.bind(this,"Up"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Up},parameter:"up"},nudgeRight:{execute:this.nudgeCommand.bind(this,"Right"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Right},parameter:"right"},nudgeDown:{execute:this.nudgeCommand.bind(this,"Down"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Down},parameter:"down"},nudgeLeft:{execute:this.nudgeCommand.bind(this,"Left"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Left},parameter:"left"},startEdit:{execute:this.startEditCommad.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.F2}},endEdit:{execute:this.endEditCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Escape}},focusToNextItem:{execute:this.navigateItems.bind(this,!0),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Tab}},focusToPreviousItem:{execute:this.navigateItems.bind(this,!1),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Tab,keyModifiers:ft.Shift}},selectFocusedItem:{execute:this.startEditCommad.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Enter}},bold:{execute:this.fontStyleCommand.bind(this,"bold"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.B,keyModifiers:ft.Control}},italic:{execute:this.fontStyleCommand.bind(this,"italic"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.I,keyModifiers:ft.Control}},underline:{execute:this.fontStyleCommand.bind(this,"underline"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.U,keyModifiers:ft.Control}},duplicate:{execute:this.duplicateCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.D,keyModifiers:ft.Control}},group:{execute:this.groupCommand.bind(this,"group"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.G,keyModifiers:ft.Control}},ungroup:{execute:this.groupCommand.bind(this,"ungroup"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.U,keyModifiers:ft.Control|ft.Shift}},rotateClockwise:{execute:this.rotateCommand.bind(this,"clockwise"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.R,keyModifiers:ft.Control}},rotateAntiClockwise:{execute:this.rotateCommand.bind(this,"antiClockwise"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.L,keyModifiers:ft.Control}},flipHorizontal:{execute:this.flipCommand.bind(this,"horizontal"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.H,keyModifiers:ft.Control}},flipVertical:{execute:this.flipCommand.bind(this,"vertical"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.J,keyModifiers:ft.Control}},pointerTool:{execute:this.toolCommand.bind(this,"pointer"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number1,keyModifiers:ft.Control}},textTool:{execute:this.toolCommand.bind(this,"text"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number2,keyModifiers:ft.Control}},connectTool:{execute:this.toolCommand.bind(this,"connect"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number3,keyModifiers:ft.Control}},freeForm:{execute:this.toolCommand.bind(this,"freeForm"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number5,keyModifiers:ft.Control}},lineTool:{execute:this.toolCommand.bind(this,"line"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number6,keyModifiers:ft.Control}},rectangleTool:{execute:this.toolCommand.bind(this,"rectangle"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number8,keyModifiers:ft.Control}},ellipseTool:{execute:this.toolCommand.bind(this,"ellipse"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number9,keyModifiers:ft.Control}},zoomIn:{execute:this.zoomCommand.bind(this,"zoomIn"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Plus,keyModifiers:ft.Control}},zoomOut:{execute:this.zoomCommand.bind(this,"zoomOut"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Minus,keyModifiers:ft.Control}},shiftUp:{execute:this.shiftCommand.bind(this,"Up"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Up,keyModifiers:ft.Shift}},shiftDown:{execute:this.shiftCommand.bind(this,"Down"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Down,keyModifiers:ft.Shift}},shiftLeft:{execute:this.shiftCommand.bind(this,"Left"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Left,keyModifiers:ft.Shift}},shiftRight:{execute:this.shiftCommand.bind(this,"Right"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Right,keyModifiers:ft.Shift}},alignTextCenter:{execute:this.alignCommand.bind(this,"center"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.C,keyModifiers:ft.Control|ft.Shift}},alignTextLeft:{execute:this.alignCommand.bind(this,"right"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.L,keyModifiers:ft.Control|ft.Shift}},alignTextRight:{execute:this.alignCommand.bind(this,"left"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.R,keyModifiers:ft.Control|ft.Shift}},alignTextTop:{execute:this.alignCommand.bind(this,"top"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.E,keyModifiers:ft.Control|ft.Shift}},alignTextCenterVertical:{execute:this.alignCommand.bind(this,"centerVertical"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.M,keyModifiers:ft.Control|ft.Shift}},alignTextBottom:{execute:this.alignCommand.bind(this,"bottom"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.V,keyModifiers:ft.Control|ft.Shift}},alignJustify:{execute:this.alignCommand.bind(this,"justify"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.J,keyModifiers:ft.Control|ft.Shift}},sendToBack:{execute:this.orderCommand.bind(this,"sendToBack"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.B,keyModifiers:ft.Control|ft.Shift}},bringToFront:{execute:this.orderCommand.bind(this,"bringToFront"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.F,keyModifiers:ft.Control|ft.Shift}},sendBackward:{execute:this.orderCommand.bind(this,"sendBackward"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.BracketLeft,keyModifiers:ft.Control}},bringForward:{execute:this.orderCommand.bind(this,"bringForward"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.BracketRight,keyModifiers:ft.Control}}};this.initCommandManager(e,i)},t.prototype.overrideCommands=function(e,i){for(var r,s=0,o=Object.keys(i);se.zIndex){("HTML"===e.shape.type||"Native"===e.shape.type)&&(o="HTML"===e.shape.type?"html":"native"),s=Eoe(i,r[parseInt(a.toString(),10)].id,o);break}return s},t.prototype.updateDiagramObject=function(e,i,r){for(var s,o="domTable",a=0,l=this.views;a1&&(d=this.commandHandler.getObjectLayer(e.id)),void 0===d||d&&d.visible||r){var u=Io(this.element.id);window[""+o][s.element.id+"_diagramLayer"]||(window[""+o][s.element.id+"_diagramLayer"]=document.getElementById(s.element.id+"_diagramLayer"));var f=window[""+o][s.element.id+"_diagramLayer"];this.diagramActions&ee.Interactions&&this.updateCanupdateStyle(e.wrapper.children,!0);var p=this.getMidPoint(e);this.diagramRenderer.updateNode(e.wrapper,f,u,void 0,i?void 0:this.getZindexPosition(e,s.element.id),p,this.portCenterPoint),this.updateCanupdateStyle(e.wrapper.children,!0)}}},t.prototype.applyMarginBezier=function(e,i){i.cx=i.cx+e.margin.left,i.cx=i.cx-e.margin.right,i.cy=i.cy+e.margin.top,i.cy=i.cy-e.margin.bottom},t.prototype.getMidPoint=function(e){var i;if(e instanceof de&&"Bezier"===e.type){i=[];for(var r=this.getBezierPoints(e),s=R.getLengthFromListOfPoints(r),o=0;o0&&e.updateView(e));var s=Io(e.element.id);this.renderDiagramElements(e.diagramLayer,e.diagramRenderer,s,void 0,void 0,i);for(var o=0;o0&&this.renderBasicElement(e),!this.diagramActions||!(this.diagramActions&ee.Render)||ee.ToolAction&this.diagramActions||Ds(this)||1!==this.scroller.currentZoom?this.refreshElements(e):this.renderTimer||(this.renderTimer=setTimeout(function(){i.refreshElements(e)},40)))},t.prototype.updatePortVisibility=function(e,i,r){var s;if((e instanceof te||e instanceof de)&&(!this.drawingObject||!this.drawingObject.shape)&&ro(e)){for(var a=e.ports,l=!1,h=0;h=0&&this.scroller.removeCollection.splice(l,1);var h=this.nameTable[e[parseInt(a.toString(),10)]];this.updateTextElementValue(h),this.diagramRenderer.renderElement(h.wrapper,s,o,void 0,void 0,void 0,void 0,h.zIndex)}for(var c=0;c0?this.scroller.oldCollectionObjects:void 0,b=Object.keys(S||g.zIndexTable);b.sort(function(N,T){return parseInt(""+N,10)-parseInt(""+T,10)});for(var M=0,w=b;M0?h:0)+"px",y=(this.realActions&$i.vScrollbarMoved?0:-(this.scroller.verticalOffset<0?this.scroller.verticalOffset:0))+"px"):(v="0px",y="0px"),this.realActions&$i.hScrollbarMoved&&(this.realActions=this.realActions&~$i.hScrollbarMoved),this.realActions&$i.vScrollbarMoved&&(this.realActions=this.realActions&~$i.vScrollbarMoved)):(v=(l.x<0?h:-this.scroller.horizontalOffset)+"px",y=(l.y<0?c:-this.scroller.verticalOffset)+"px"),this.diagramLayer.style.left=v,this.diagramLayer.style.top=y,A.tx=-l.x/A.scale,A.ty=-l.y/A.scale);var P=!0;if(o&&(P=!1),this.updateTextElementValue(D),this.refreshing&&D.shape.activity&&D.shape.activity.subProcess&&D.shape.activity.subProcess.processes){for(var L=0;L0){var o=s.children[0],a=o.data;(r.isBezierEditing&&this.selectedItems.connectors[0].id===r.id||"Bezier"!==r.type)&&r.getSegmentElement(r,o,"ComplexHierarchicalTree"===this.layout.type||"HierarchicalTree"===this.layout.type?this.layout.orientation:void 0,void 0,!1),o.data!==a&&(s.measure(new me),s.arrange(s.desiredSize),"SVG"===this.mode&&!e&&this.updateDiagramObject(r))}}else this.constraints&nt.Bridging&&console.warn('[WARNING] :: Module "ConnectorBridging" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.setCursor=function(e){this.diagramRenderer.setCursor(this.diagramCanvas,e)},t.prototype.clearCanvas=function(e){var i=e.contentWidth||e.diagramLayer.width/this.scroller.currentZoom,r=e.contentHeight||e.diagramLayer.height/this.scroller.currentZoom;"SVG"!==e.mode&&bo.getContext(e.diagramLayer).clearRect(0,0,i,r)},t.prototype.updateScrollOffset=function(){this.scroller.setScrollOffset(this.diagramCanvas.scrollLeft,this.diagramCanvas.scrollTop),eb(this),Ds(this)&&this.scroller.virtualizeElements()},t.prototype.setOffset=function(e,i){var r="domTable";window[""+r][this.element.id+"content"]||(window[""+r][this.element.id+"content"]=document.getElementById(this.element.id+"content"));var s=window[""+r][this.element.id+"content"];s&&(s.scrollLeft=e,s.scrollTop=i)},t.prototype.setSize=function(e,i){if(this.diagramLayer&&!this.preventDiagramUpdate){var r=Za(this);e-=r.width,i-=r.height;var s=this.spatialSearch.getPageBounds();s.x*=this.scroller.currentZoom,s.y*=this.scroller.currentZoom,s.width*=this.scroller.currentZoom,s.height*=this.scroller.currentZoom;var o="SVG"===this.mode?1:1.5,a="SVG"===this.mode?mT(this.element.id):this.diagramLayer,h="Canvas"===this.mode&&this.constraints&nt.Virtualization?this.scroller.viewPortHeight:i;a.setAttribute("width",(o*("Canvas"===this.mode&&this.constraints&nt.Virtualization?this.scroller.viewPortWidth:e)).toString()),a.setAttribute("height",(o*h).toString());var c=document.getElementById(this.element.id+"_diagramUserHandleLayer");c&&(c.style.width=e+"px",c.style.height=i+"px");var d={width:e.toString(),height:i.toString()};this.diagramLayerDiv.style.width=e+"px",this.diagramLayerDiv.style.height=i+"px",ti(FF(this.element.id),d),ti(function xoe(n){return xt(n).getElementsByClassName("e-ports-expand-layer")[0]}(this.element.id),d);var u=Fl(this.element.id);ti(u,d),u.parentNode.style.width=e+"px",u.parentNode.style.height=i+"px";var f=Ud(this.element.id);ti(f,d),this.diagramRenderer.updateGrid(this.snapSettings,f,this.scroller.transform,this.rulerSettings,this.hRuler,this.vRuler),ti(IT(this.element.id),d),this.htmlLayer.style.width=e+"px",this.htmlLayer.style.height=i+"px","SVG"!==this.mode&&!Ds(this)&&this.refreshDiagramLayer(),"SVG"===this.mode&&Ds(this)&&this.scroller.virtualizeElements()}},t.prototype.transformLayers=function(){var e=this.spatialSearch.getPageBounds();e.x*=this.scroller.currentZoom,e.y*=this.scroller.currentZoom,e.width*=this.scroller.currentZoom,e.height*=this.scroller.currentZoom,this.diagramRenderer.updateGrid(this.snapSettings,Ud(this.element.id),this.scroller.transform,this.rulerSettings,this.hRuler,this.vRuler),this.diagramRenderer.transformLayers(this.scroller.transform,"SVG"===this.mode),this.diagramActions&ee.DragUsingMouse||this.updateSelector(),this.renderPageBreaks(e)},t.prototype.removePageBreaks=function(){if(this.diagramLayer){var e=_F(this.element.id);if(e&&e.childNodes)for(var i=e.childNodes.length,r=0;rthis.pageSettings.height&&(e=this.pageSettings.height,this.pageSettings.height=this.pageSettings.width,this.pageSettings.width=e):this.pageSettings.height>this.pageSettings.width&&(e=this.pageSettings.width,this.pageSettings.width=this.pageSettings.height,this.pageSettings.height=e)},t.prototype.setOverview=function(e,i){if(e)e&&(this.views.push(e.id),this.views[e.id]=e,e.renderDocument(e),e.diagramRenderer.setLayers(),e.updateView(e),this.renderNodes(e));else{for(var r=0;r1&&this.updateSelectionRectangle(),this.isProtectedOnChange=s},t.prototype.updateSelectionRectangle=function(){for(var e=pm(this.element.id),i=!1,r=0;r1&&this.updateSelectionRectangle(),this.enableServerDataBinding(e)},t.prototype.renderSelectorForAnnotation=function(e,i){this.diagramRenderer.renderResizeHandle(e.wrapper.children[0],i,e.thumbsConstraints,this.scroller.currentZoom,e.constraints,this.scroller.transform,void 0,ro(e.annotation),void 0,void 0,e.handleSize)},t.prototype.drawSelectionRectangle=function(e,i,r,s){this.clearSelectorLayer(),this.diagramRenderer.drawSelectionRectangle(e,i,r,s,this.adornerLayer,this.scroller.transform)},t.prototype.renderHighlighter=function(e){var i=Fl(this.element.id);this.diagramRenderer.renderHighlighter(e,i,this.scroller.transform)},t.prototype.clearHighlighter=function(){var e=Fl(this.element.id),i=e.getElementById(e.id+"_highlighter");i&&i.parentNode.removeChild(i)},t.prototype.getNodesConnectors=function(e){for(var i=0;i0;h--)this.eventHandler&&this.eventHandler.touchArgs&&"touchmove"===this.eventHandler.touchArgs.type?(this.diagramRenderer.touchMove=!0,l&&l===o[h-1].id||(a=o[h-1]).parentNode.removeChild(a)):(a=o[h-1]).parentNode.removeChild(a);if(!ce()){var c=ST(this.element.id).childNodes;for(r=c.length;r>0;r--)c[r-1].parentNode.removeChild(c[r-1])}}},t.prototype.getWrapper=function(e,i){var r;i=e.id+"_"+i;for(var s=e instanceof Mi?e:this.getPortContainer(this.nameTable[e.id]),o=0;o0&&this.applyStyle(e,a=r.annotations)}for(i=0;i0){var a=this.selectedItems.connectors[parseInt(i.toString(),10)].annotations;this.applyStyle(e,a)}},t.prototype.applyStyle=function(e,i){for(var r=0;r0)for(var i=0;i0?r[0].zIndex+(e?1:-1):e?0:this.nodes.length+this.connectors.length-1)<0?i=this.nodes.length+this.connectors.length-1:i===this.nodes.length+this.connectors.length&&(i=0);for(var s=0;s0)for(var s=void 0,o=r.children.length-1;o>=0;o--){var a=r.children[parseInt(o.toString(),10)];i.length>0&&-1!==i.indexOf(a.id.split("_groupElement")[0])&&(r.parentNode.insertBefore(a,s||r),s=a)}r&&r.parentNode.removeChild(r)},t.prototype.deleteGroup=function(e){var r=[];e.children&&(r=this.commandHandler.getChildren(e,[])),this.UpdateBlazorDiagramModelCollection(e);for(var s=0,o=r;s0)for(var xe=0;xe0)if("Path"===t.shape.type&&void 0!==n.shape.data)t.wrapper.children[0].data=n.shape.data;else if("Text"===t.shape.type&&void 0!==n.shape.content)t.wrapper.children[0].content=n.shape.content;else if("Image"===t.shape.type&&void 0!==n.shape.source)t.wrapper.children[0].source=n.shape.source;else if("Native"===t.shape.type){for(var r=void 0,s=0;s-1)&&(this.diagramActions&ee.PreventZIndexOnDragging?this.updateDiagramObject(e,!0):this.updateDiagramObject(e)),!s&&d&&(this.lineRoutingModule&&this.diagramActions&&this.constraints&nt.LineRouting&&"helper"!==e.id?this.diagramActions&ee.ToolAction||this.lineRoutingModule.renderVirtualRegion(this,!0):this.diagramActions&&this.constraints&nt.LineRouting&&"helper"!==e.id&&console.warn('[WARNING] :: Module "LineRouting" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),this.updateConnectorEdges(e),"helper"!==e.id&&!(this.diagramActions&ee.ToolAction))))for(var Sa=this.spatialSearch.findObjects(e.wrapper.outerBounds),Mo=0;Moe?Math.abs(r-e):Math.abs(e-r),d=s>i?Math.abs(s-i):Math.abs(i-s);(0===c&&0===d||Number.isNaN(c)&&Number.isNaN(d))&&o.laneMargin&&(u=o.margin.left-o.laneMargin.left,f=o.margin.top-o.laneMargin.top);var p=o.width,g=o.height,v=new Ne(0,0,0,0);if(0!==p&&0!==g&&(v=new Ne((0!==r?r:o.offsetX)-p/2,(0!==s?s:o.offsetY)-g/2,p,g)),h){var y=l,b=this.selectedItems.nodes?this.selectedItems.nodes[0]:void 0;if(""!==y.textAnnotation.textAnnotationTarget&&this.nameTable[y.textAnnotation.textAnnotationTarget])if(""===o.parentId||b&&b.shape&&"TextAnnotation"===b.shape.shape){if("Auto"===y.textAnnotation.textAnnotationDirection&&a.children[0]instanceof Mi&&a.children[0].children[0]instanceof Ze){var w=a.children[0],C=document.getElementById(w.id+"_groupElement"),D=document.getElementById(w.children[0].id+"_groupElement");C.removeChild(D),w.children.splice(0,1),this.isProtectedOnChange=!0,this.bpmnModule.setAnnotationPath(v,w,o,y,y.textAnnotation.textAnnotationDirection,this),this.isProtectedOnChange=!1}}else this.isPositionUndo=!0,this.updateTextAnnotationInSwimlane(o,o),this.isPositionUndo=!1;else o.inEdges.length>0&&(x=this.nameTable[""+o.inEdges[0]])&&x.isBpmnAnnotationConnector&&(x.sourcePoint={x:r>e?x.sourcePoint.x+c:x.sourcePoint.x-c,y:s>i?x.sourcePoint.y+d:x.sourcePoint.y-d});this.nodePropertyChange(o,{},P={ports:[{offset:o.ports[0].offset}]})}else for(var L=0,O=o.outEdges;Le?T.offsetX+c:T.offsetX-c,T.offsetY=s>i?T.offsetY+d:T.offsetY-d,P={offsetX:T.offsetX,offsetY:T.offsetY}),this.nodePropertyChange(T,z,P)}}}},t.prototype.updatePorts=function(e,i){if(e&&e.ports.length>0)for(var r=0,s=Object.keys(e.ports);r0)for(var i=0;i0)for(var r=0;r0&&void 0===r.segments&&(e.segments=[]),void 0!==r.shape&&void 0!==e.shape&&e.shape&&"Bpmn"===e.shape.type&&this.bpmnModule&&this.bpmnModule.updateBPMNConnector(e,i,r,this),void 0!==e.constraints?(this.updateThumbConstraints(this.selectedItems.connectors,this.selectedItems),s=!0):s},t.prototype.connectorPropertyChange=function(e,i,r,s,o){if(this.canEnableBlazorObject){var a=$(e);this.insertValue(a,!1)}var d,u,f,p,l=e.wrapper.bounds,h=!1,c=[];if(h=this.connectorProprtyChangeExtend(e,i,r,h),void 0!==r.visible&&this.updateElementVisibility(e.wrapper,e,e.visible),void 0!==r.sourcePoint||void 0!==r.targetPoint||void 0!==r.sourceID||void 0!==r.targetID||void 0!==r.targetPadding||void 0!==r.sourcePortID||void 0!==r.targetPortID||void 0!==r.sourcePadding||void 0!==r.type||void 0!==r.segments||void 0!==r.flip){if(void 0!==r.sourceID&&r.sourceID!==i.sourceID||r.sourcePortID){if(u=this.findInOutConnectPorts(g=this.nameTable[e.sourceID],!1),(!g||Rh(g)||""!==e.sourcePortID&&Ld(u))&&(e.sourceWrapper=g?this.getEndNodeWrapper(g,e,!0):void 0,e.sourcePortID&&void 0===r.sourcePortID&&(e.sourcePortWrapper=g?this.getWrapper(g.wrapper,e.sourcePortID):void 0),this.removePortEdges(this.nameTable[i.sourceID]||g,i.sourcePortID||e.sourcePortID,e.id,!1)),void 0!==r.sourceID&&void 0!==i.sourceID&&""!==i.sourceID){var v=this.nameTable[i.sourceID];void 0!==v&&v.outEdges&&-1!==v.outEdges.indexOf(e.id)&&sm(v.outEdges,e.id)}this.updateEdges(e)}if(void 0!==r.targetID&&r.targetID!==i.targetID){if(d=this.findInOutConnectPorts(y=this.nameTable[r.targetID],!0),(!y||ua(y)||""!==e.targetPortID&&zh(d))&&(e.targetWrapper=y?this.getEndNodeWrapper(y,e,!1):void 0,e.targetPortID&&void 0===r.targetPortID&&(e.targetPortWrapper=y?this.getWrapper(y.wrapper,e.targetPortID):void 0),this.removePortEdges(this.nameTable[i.targetID]||y,i.targetPortID||e.targetPortID,e.id,!0)),void 0!==i&&void 0!==i.targetID&&""!==i.targetID){var S=this.nameTable[i.targetID];void 0!==S&&S.inEdges&&-1!==S.inEdges.indexOf(e.id)&&sm(S.inEdges,e.id)}this.updateEdges(e)}var g,y;void 0!==r.sourcePortID&&r.sourcePortID!==i.sourcePortID&&(e.sourceID&&this.nameTable[e.sourceID]&&(f=this.nameTable[e.sourceID].wrapper),!(g=this.nameTable[e.sourceID])||Rh(g)||""!==e.sourcePortID&&Ld(u)?e.sourcePortWrapper=f?this.getWrapper(f,r.sourcePortID):void 0:""===e.sourcePortID&&!Rh(g)&&(e.sourcePortWrapper=void 0)),void 0!==r.targetPortID&&r.targetPortID!==i.targetPortID&&(e.targetID&&this.nameTable[e.targetID]&&(p=this.nameTable[e.targetID].wrapper),!(y=this.nameTable[e.targetID])||ua(y)||""!==e.targetPortID&&zh(d)?e.targetPortWrapper=p?this.getWrapper(p,r.targetPortID):void 0:""===e.targetPortID&&!ua(y)&&(e.targetPortWrapper=void 0)),void 0!==r.flip&&(e.flip=r.flip,EF(e)),"Orthogonal"===e.type&&this.lineRoutingModule&&this.diagramActions&&this.constraints&nt.LineRouting&&!(this.diagramActions&ee.ToolAction)&&"ComplexHierarchicalTree"!==this.layout.type&&(this.lineRoutingModule.renderVirtualRegion(this,!0),e.sourceID!==e.targetID&&e.segments.length>1&&this.lineRoutingModule.refreshConnectorSegments(this,e,!1)),c=this.getPoints(e)}void 0!==r.style&&Hh(r.style,e.wrapper.children[0]),(c.length>0||void 0!==r.sourceDecorator||void 0!==r.targetDecorator&&function qse(n){return-1!==n.indexOf("shape")||-1!==n.indexOf("pathData")||-1!==n.indexOf("width")||-1!==n.indexOf("height")}(Object.keys(r.targetDecorator))||void 0!==r.cornerRadius)&&(tp(e,c.length>0?c:e.intermediatePoints,this.diagramActions),void 0!==r.type&&(h=!0),c.length>0&&(e.wrapper.measure(new me(e.wrapper.width,e.wrapper.height)),e.wrapper.arrange(e.wrapper.desiredSize),this.updateConnectorAnnotation(e),this.updateConnectorPort(e),this.updateConnectorfixedUserHandles(e),this.updateObject(e,i,r))),(r.sourcePoint||r.targetPoint||r.segments)&&this.diagramActions===ee.Render&&(h=!0),"Bpmn"===e.shape.type&&"Default"===e.shape.sequence&&"Sequence"===e.shape.flow&&this.commandHandler.updatePathElementOffset(e),s||this.updateBridging(),this.updateAnnotations(r,e),this.updateConnectorPorts(r,e),this.updatefixedUserHandle(r,e),e.wrapper.measure(new me(e.wrapper.width,e.wrapper.height)),e.wrapper.arrange(e.wrapper.desiredSize),!1===l.equals(l,e.wrapper.bounds)&&(this.updateQuad(e),"Drag"!==this.eventHandler.currentAction&&this.updateGroupSize(e)),!0===h&&this.checkSelectedItem(e)&&(!(this.diagramActions&ee.ToolAction)||this.diagramActions&ee.UndoRedo)&&this.updateSelector(),this.preventConnectorsUpdate||(!Ds(this)||Ds(this)&&this.scroller.oldCollectionObjects.indexOf(e.id)>-1)&&(this.diagramActions&ee.PreventZIndexOnDragging?this.updateDiagramObject(e,!0):this.updateDiagramObject(e)),this.updateConnectorEdges(e),this.diagramActions&&"New"!==e.status&&(e.status="Update"),this.triggerPropertyChange(o,e,i,r)},t.prototype.removePortEdges=function(e,i,r,s){if(e)for(var o=0;o0&&e.id===s[s.length-1].id&&(r=!0),r},t.prototype.updateDiagramContainerVisibility=function(e,i){if(e instanceof Cs)for(var r=0;r>"),r instanceof es&&this.updateAnnotationWrapper(r,s,o,a)),void 0!==e.template&&(r.content=e.template,this.updateAnnotationWrapper(r,s,o,a))},t.prototype.updateAnnotationWrapper=function(e,i,r,s){for(var o=0,a=this.views;o=0&&this.nodes.splice(s,1),delete this.nameTable[""+r]}var o=this.nodes.indexOf(this.nameTable[this.currentSymbol.id]);o>=0&&this.nodes.splice(o,1)}},t.prototype.selectDragedNode=function(e,i,r){this.currentSymbol=e,"SVG"!==this.mode&&this.refreshDiagramLayer(),this.commandHandler.oldSelectedObjects=am(this),this.commandHandler.select(e),this.eventHandler.mouseDown(i.event),this.eventHandler.mouseMove(i.event,i),this.preventDiagramUpdate=!1,this.updatePage(),r.style.opacity="0"},t.prototype.initDroppables=function(){var s,o,e=this,i={},r={},a="selectedSymbols";this.droppable=new lR(this.element);var l=5;this.droppable.over=function(h){if(e.rulerSettings.showRulers){var c=document.getElementById(e.element.id+"_vRuler"),d=parseFloat(c.style.width);l=d+1}if(0===e.previousSelectedObjects.length&&!e.currentSymbol&&(e.previousSelectedObjects=e.commandHandler.getSelectedObject()),e.commandHandler.PreventConnectorSplit=!0,e.currentSymbol)h.event.touches&&h.event.touches.length&&e.eventHandler.mouseMove(h.event,h.event.touches);else{var u=null;if(!h.dragData&&"drag"===h.name){var f=document.getElementsByClassName("e-dragclone")[0];f&&(u=f)}if(h.dragData||u){var p=void 0,g=void 0;document.getElementById(e.element.id+"content").focus();var v=e.eventHandler.getMousePosition(h.event),y=void 0,S=u||h.dragData.helper,b=S.getAttribute("paletteId"),M=void 0,w=void 0,C=void 0,D=void 0;if(!b&&h.dragData){e.triggerEvent(Ce.dragEnter,A={source:null,element:p,cancel:!1,diagram:e,dragData:h.dragData.draggedElement.ej2_instances[0].dragData,dragItem:p});var x=void 0,P=void 0;if(A.dragItem){if(A.dragItem.sourcePoint&&A.dragItem.targetPoint?P=new de(e,"connectors",A.dragItem,!0):x=new te(e,"nodes",A.dragItem,!0),e.initObject(p=x||P,void 0,void 0,!0),e.enterObject=p,e.enterTable=r,p instanceof te)x.offsetX=v.x+5+x.width*x.pivot.x,x.offsetY=v.y+x.height*x.pivot.y;else if(p instanceof de){var L=Ne.toBounds([p.sourcePoint,p.targetPoint]),O=v.x-L.left,N=v.y-L.top;p.sourcePoint.x+=O,p.sourcePoint.y+=N,p.targetPoint.x+=O,p.targetPoint.y+=N}e.preventDiagramUpdate=!0,e.currentSymbol=p,"SVG"!==e.mode&&e.refreshDiagramLayer(),e.selectDragedNode(p,h,S),delete e.enterObject,delete e.enterTable,e.droppable[""+a]=S,e.allowServerDataBinding=!0}}if(b){var T=document.getElementById(b).ej2_instances[0];if(e.droppable.sourceElement=T,T){var B=T[""+a];e.allowServerDataBinding=!1,y=$(T[""+a]),i=T.childTable;var j=B.wrapper.children[0].children[0];if(D=function $se(n,t,e){var i=AF(n,t,e,"width"),r=AF(n,t,e,"height");return new me(i,r)}(T,y,j),T[""+a]instanceof te){"TextAnnotation"===B.shape.shape?(y.offsetX=v.x+11+D.width*y.pivot.x,y.offsetY=v.y+11+D.height*y.pivot.y):(y.offsetX=v.x+5+D.width*y.pivot.x,y.offsetY=v.y+D.height*y.pivot.y),"Bpmn"===(x=new te(e,"nodes",y,!0)).shape.type&&x.shape.activity.subProcess.processes&&x.shape.activity.subProcess.processes.length&&(x.shape.activity.subProcess.processes=[]),w=x.previewSize,C=T.symbolDragSize;var Q=T.symbolPreview;if(x.width=(M=x.dragSize).width||C.width||w.width||Q.width||x.width,x.height=M.height||C.height||w.height||Q.height||x.height,"SwimLane"===x.shape.type){if(e.diagramActions|=ee.PreventHistory,x.shape.isLane){x.children=[],s={id:"header"+Qe()},"Horizontal"===x.shape.orientation?(s.width=x.shape.lanes[0].header.width,s.height=x.shape.lanes[0].height):(s.width=x.shape.lanes[0].width,s.height=x.shape.lanes[0].header.height),s.style=x.shape.lanes[0].header.style,s.offsetX=v.x+l+s.width/2,s.offsetY=v.y+s.height/2,e.diagramActions|=ee.PreventCollectionChangeOnDragOver,s=e.add(s),o={id:"body"+Qe()},"Horizontal"===x.shape.orientation?(o.width=x.shape.lanes[0].width-s.width,o.height=x.shape.lanes[0].height,o.offsetX=v.x+l+(x.shape.lanes[0].header.width+o.width/2),o.offsetY=v.y+o.height/2):(o.width=x.shape.lanes[0].width,o.height=x.shape.lanes[0].height-s.height,o.offsetX=v.x+l+o.width/2,o.offsetY=v.y+(x.shape.lanes[0].header.height+o.height/2)),o.style=x.shape.lanes[0].style,o=e.add(o);var oe={id:"group"+Qe(),children:[s.id,o.id]};oe.shape=x.shape,oe.width=x.shape.lanes[0].width,oe.height=x.shape.lanes[0].height,oe.previewSize=x.previewSize,oe.dragSize=x.dragSize,oe.addInfo=x.addInfo,x=e.add(oe),e.diagramActions&=~ee.PreventCollectionChangeOnDragOver}e.diagramActions&=~ee.PreventHistory}if(x.shape.isPhase&&((g="Horizontal"===x.shape.orientation)?(x.offsetX=v.x+l+(x.width||j.actualSize.width)/2,x.offsetY=v.y,x.shape.data="M20,"+x.height/2+" L"+(x.width-20)+","+x.height/2+"z",x.height=1):(x.offsetX=v.x+5,x.offsetY=v.y+(x.height||j.actualSize.height)/2,x.shape.data="M"+x.width/2+",20 L"+x.width/2+","+(x.height-20)+"z",x.width=1)),"UmlClassifier"===x.shape.type&&(x.children=x.width=x.height=void 0,y.children=void 0,"Class"===x.shape.classifier&&x.shape.classShape.methods.length<=0&&x.shape.classShape.attributes.length<=0&&(x.shape.classShape.attributes=[{name:"Name",type:"Type",style:{}}]),"Enumeration"===x.shape.classifier&&x.shape.enumerationShape.members.length<=0&&(x.shape.enumerationShape.members=[{name:"Name"}]),"Interface"===x.shape.classifier&&x.shape.interfaceShape.methods.length<=0&&x.shape.interfaceShape.attributes.length<=0&&(x.shape.interfaceShape.attributes=[{name:"Name",type:"Type",style:{}}])),p=x,y.children){var ue=y;r=e.getChildren(ue,{},i),rT(ue,-ue.offsetX,-ue.offsetY,r,!0,e)}}else if(T[""+a]instanceof de){p=new de(e,"connectors",y,!0);var Me=Ne.toBounds([p.sourcePoint,p.targetPoint]),De=v.x-Me.left,xe=v.y-Me.top;p.sourcePoint.x+=De,p.sourcePoint.y+=xe,p.targetPoint.x+=De,p.targetPoint.y+=xe}p.shape.isLane||(p.id+=Qe());var A={source:T,element:p,cancel:!1,diagram:e,dragData:null,dragItem:p};if(e.enterObject=p,e.enterTable=r,e.triggerEvent(Ce.dragEnter,A),p instanceof te&&"SwimLane"===p.shape.type&&p.shape.isLane){var Ie=A.element,Ve=Ie.shape.lanes[0];g="Horizontal"===Ie.shape.orientation;var ot=e.nameTable[p.children[0]],$e=e.nameTable[p.children[1]];w=p.previewSize,C=T.symbolDragSize,Ve.width=(M=p.dragSize).width||C.width||w.width||Ve.width,Ve.height=M.height||C.height||w.height||Ve.height,g?(s.width=Ve.header.width,s.height=Ve.height,o.width=Ve.width-s.width,o.height=Ve.height,o.offsetX=v.x+l+(Ve.header.width+$e.width/2),o.offsetY=v.y+$e.height/2):(s.width=Ve.width,s.height=Ve.header.height,o.width=Ve.width,o.height=Ve.height-s.height,o.offsetX=v.x+l+$e.width/2,o.offsetY=v.y+(Ve.header.height+$e.height/2)),s.offsetX=v.x+l+ot.width/2,s.offsetY=v.y+ot.height/2,p.width=Ve.width,p.height=Ve.height}if(p instanceof te&&p.shape.isPhase&&(g?p.height=1:p.width=1),!e.activeLayer.lock&&!A.cancel){if(e.preventDiagramUpdate=!0,p.children&&e.findChild(p,r),e.preventDiagramUpdate=!0,p.zIndex!==Number.MIN_VALUE&&(p.zIndex=Number.MIN_VALUE),e.initObject(p,void 0,void 0,!0),e.bpmnModule)for(var Ci=0;Ci0&&(S.segments=[]),d=this.add(S,!0)),(S||d)&&(Vv(this)||Wv(this))&&this.select([this.nameTable[S[""+b]]],!1,this.previousSelectedObjects),y.target&&y.target instanceof de&&!0===this.enableConnectorSplit&&this.nameTable[S[""+b]]instanceof te&&(this.commandHandler.connectorSplit(this.nameTable[S[""+b]],y.target),this.commandHandler.PreventConnectorSplit=!1))),this.protectPropertyChange(!1),v=this.nameTable[S[""+b]],S.hasTarget&&(S.nodeId=S.hasTarget,this.remove(S)),this.bpmnModule&&v instanceof te&&S.processId&&(v.processId=S.processId,this.bpmnModule.dropBPMNchild(this.nameTable[v.processId],v,this)),y.cancel||this.endGroupAction(),"SVG"!==this.mode&&this.refreshDiagramLayer(),delete this.droppable[""+c]):(this.triggerEvent(Ce.drop,y={source:h.droppedElement,element:void 0,target:this.eventHandler.hoverNode||this.eventHandler.lastObjectUnderMouse||this,cancel:!1,position:void 0}),S=void 0,b="id"),this.droppable[M="selectedSymbols"]&&this.droppable[""+M].parentNode)gt(this.droppable[""+M]);else for(w=document.getElementsByClassName("e-dragclone"),C=0;C0)for(var f=0;f1),e.previousSelectedObject=null}}},t.prototype.getDropEventArgs=function(e){if(this.eventHandler.lastObjectUnderMouse||this.eventHandler.hoverNode){var i=this.eventHandler.lastObjectUnderMouse||this.eventHandler.hoverNode;e.target=ps(i)===de?{connector:i}:{node:i}}else e.target.diagramId=this.element.id},t.prototype.removeChildInNodes=function(e){if(e){if(e.children)for(var i=0;i1){var l=2;if(e.children&&e.children.length>0)for(;e.children.indexOf(i.objects[s-l])>-1;)l++;this.commandHandler.moveSvgNode(e.id,i.objects[s-l]),this.commandHandler.moveSvgNode(i.objects[s-l],e.id)}else if(o){var h=this.commandHandler.getLayer(this.layerZIndexTable[o.zIndex]).objects[0];h?(this.commandHandler.moveSvgNode(e.id,h),this.commandHandler.updateNativeNodeIndex(e.id,h)):this.moveObjectsUp(e,i)}else this.moveObjectsUp(e,i)},t.prototype.moveObjectsUp=function(e,i){for(var r,s=this.layers.length-1;s>=0;s--)if(r=this.layers[parseInt(s.toString(),10)],i.id!==r.id){var o=this.commandHandler.getLayer(this.layerZIndexTable[r.zIndex]).objects[r.objects.length-1];if(o){this.commandHandler.moveSvgNode(e.id,o),this.commandHandler.moveSvgNode(o,e.id);break}}},t.prototype.insertData=function(e){return this.crudOperation(e,"create",this.getNewUpdateNodes("New"))},t.prototype.updateData=function(e){return this.crudOperation(e,"update",this.getNewUpdateNodes("Update"))},t.prototype.removeData=function(e){return this.crudOperation(e,"destroy",this.getDeletedNodes())},t.prototype.crudOperation=function(e,i,r){if(e){var s=this.parameterMap(e,!(e instanceof de));if(s){var o=e instanceof de?this.dataSourceSettings.connectionDataSource.crudAction[""+i]:this.dataSourceSettings.crudAction[""+i];this.raiseAjaxPost(JSON.stringify(s),o)}return s}var a=r;return this.processCrudCollection(a,this.dataSourceSettings.crudAction[""+i],this.dataSourceSettings.connectionDataSource.crudAction[""+i]),a},t.prototype.processCrudCollection=function(e,i,r){if(e.nodes){var s=[],o=void 0;for(o=0;o0&&this.raiseAjaxPost(JSON.stringify(s),i)}if(e.connectors){for(s=[],o=void 0,o=0;o0&&this.raiseAjaxPost(JSON.stringify(s),r)}},t.prototype.parameterMap=function(e,i){var s,r={},o=i?this.dataSourceSettings:this.dataSourceSettings.connectionDataSource;if(o.id&&(r[o.id]=e.id),o.sourcePointX&&o.sourcePointY&&(r[o.sourcePointX]=e.sourcePoint.x,r[o.sourcePointY]=e.sourcePoint.y),o.targetPointX&&o.targetPointY&&(r[o.targetPointX]=e.targetPoint.x,r[o.targetPointY]=e.targetPoint.y),o.sourceID&&(r[o.sourceID]=e.sourceID),o.targetID&&(r[o.targetID]=e.targetID),o.crudAction&&o.crudAction.customFields&&o.crudAction.customFields.length>0)for(s=0;s{class n extends ph{constructor(e){super(),this.viewContainerRef=e,ml("currentInstance",this,this.viewContainerRef),this.registerEvents($ae),this.directivePropList=qae}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-layer"]],inputs:{addInfo:"addInfo",id:"id",lock:"lock",objects:"objects",visible:"visible",zIndex:"zIndex"},features:[yn]}),n})(),Jae=(()=>{class n extends gh{constructor(){super("layers")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-layers"]],contentQueries:function(e,i,r){if(1&e&&dn(r,Zae,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),Kae=["action","cursor"],ele=[],tle=(()=>{class n extends ph{constructor(e){super(),this.viewContainerRef=e,ml("currentInstance",this,this.viewContainerRef),this.registerEvents(ele),this.directivePropList=Kae}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-cursormap"]],inputs:{action:"action",cursor:"cursor"},features:[yn]}),n})(),ile=(()=>{class n extends gh{constructor(){super("customcursor")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-cursormaps"]],contentQueries:function(e,i,r){if(1&e&&dn(r,tle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),rle=["alignment","cornerRadius","displacement","fill","handleStrokeColor","handleStrokeWidth","height","iconStrokeColor","iconStrokeWidth","id","offset","padding","pathData","tooltip","visibility","width"],nle=[],sle=(()=>{class n extends ph{constructor(e){super(),this.viewContainerRef=e,ml("currentInstance",this,this.viewContainerRef),this.registerEvents(nle),this.directivePropList=rle}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-connector-fixeduserhandle"]],inputs:{alignment:"alignment",cornerRadius:"cornerRadius",displacement:"displacement",fill:"fill",handleStrokeColor:"handleStrokeColor",handleStrokeWidth:"handleStrokeWidth",height:"height",iconStrokeColor:"iconStrokeColor",iconStrokeWidth:"iconStrokeWidth",id:"id",offset:"offset",padding:"padding",pathData:"pathData",tooltip:"tooltip",visibility:"visibility",width:"width"},features:[yn]}),n})(),ole=(()=>{class n extends gh{constructor(){super("fixeduserhandles")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-connector-fixeduserhandles"]],contentQueries:function(e,i,r){if(1&e&&dn(r,sle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),ale=["addInfo","alignment","annotationType","constraints","content","displacement","dragLimit","height","horizontalAlignment","hyperlink","id","margin","offset","rotateAngle","rotationReference","segmentAngle","style","template","tooltip","type","verticalAlignment","visibility","width"],lle=[],hle=(()=>{class n extends ph{constructor(e){super(),this.viewContainerRef=e,ml("currentInstance",this,this.viewContainerRef),this.registerEvents(lle),this.directivePropList=ale}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-connector-annotation"]],inputs:{addInfo:"addInfo",alignment:"alignment",annotationType:"annotationType",constraints:"constraints",content:"content",displacement:"displacement",dragLimit:"dragLimit",height:"height",horizontalAlignment:"horizontalAlignment",hyperlink:"hyperlink",id:"id",margin:"margin",offset:"offset",rotateAngle:"rotateAngle",rotationReference:"rotationReference",segmentAngle:"segmentAngle",style:"style",template:"template",tooltip:"tooltip",type:"type",verticalAlignment:"verticalAlignment",visibility:"visibility",width:"width"},features:[yn]}),n})(),cle=(()=>{class n extends gh{constructor(){super("annotations")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-connector-annotations"]],contentQueries:function(e,i,r){if(1&e&&dn(r,hle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),dle=["addInfo","allowNodeOverlap","annotations","bezierSettings","bridgeSpace","connectionPadding","connectorSpacing","constraints","cornerRadius","dragSize","excludeFromLayout","fixedUserHandles","flip","flipMode","hitPadding","id","margin","maxSegmentThumb","ports","previewSize","segmentThumbShape","segmentThumbSize","segments","shape","sourceDecorator","sourceID","sourcePadding","sourcePoint","sourcePortID","style","symbolInfo","targetDecorator","targetID","targetPadding","targetPoint","targetPortID","tooltip","type","visible","wrapper","zIndex"],ule=[],fle=(()=>{class n extends ph{constructor(e){super(),this.viewContainerRef=e,this.tags=["fixedUserHandles","annotations"],ml("currentInstance",this,this.viewContainerRef),this.registerEvents(ule),this.directivePropList=dle}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-connector"]],contentQueries:function(e,i,r){if(1&e&&(dn(r,ole,5),dn(r,cle,5)),2&e){let s;Kr(s=en())&&(i.childFixedUserHandles=s.first),Kr(s=en())&&(i.childAnnotations=s.first)}},inputs:{addInfo:"addInfo",allowNodeOverlap:"allowNodeOverlap",annotations:"annotations",bezierSettings:"bezierSettings",bridgeSpace:"bridgeSpace",connectionPadding:"connectionPadding",connectorSpacing:"connectorSpacing",constraints:"constraints",cornerRadius:"cornerRadius",dragSize:"dragSize",excludeFromLayout:"excludeFromLayout",fixedUserHandles:"fixedUserHandles",flip:"flip",flipMode:"flipMode",hitPadding:"hitPadding",id:"id",margin:"margin",maxSegmentThumb:"maxSegmentThumb",ports:"ports",previewSize:"previewSize",segmentThumbShape:"segmentThumbShape",segmentThumbSize:"segmentThumbSize",segments:"segments",shape:"shape",sourceDecorator:"sourceDecorator",sourceID:"sourceID",sourcePadding:"sourcePadding",sourcePoint:"sourcePoint",sourcePortID:"sourcePortID",style:"style",symbolInfo:"symbolInfo",targetDecorator:"targetDecorator",targetID:"targetID",targetPadding:"targetPadding",targetPoint:"targetPoint",targetPortID:"targetPortID",tooltip:"tooltip",type:"type",visible:"visible",wrapper:"wrapper",zIndex:"zIndex"},features:[yn]}),n})(),ple=(()=>{class n extends gh{constructor(){super("connectors")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-connectors"]],contentQueries:function(e,i,r){if(1&e&&dn(r,fle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),gle=["cornerRadius","fill","handleStrokeColor","handleStrokeWidth","height","iconStrokeColor","iconStrokeWidth","id","margin","offset","padding","pathData","tooltip","visibility","width"],vle=[],mle=(()=>{class n extends ph{constructor(e){super(),this.viewContainerRef=e,ml("currentInstance",this,this.viewContainerRef),this.registerEvents(vle),this.directivePropList=gle}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-node-fixeduserhandle"]],inputs:{cornerRadius:"cornerRadius",fill:"fill",handleStrokeColor:"handleStrokeColor",handleStrokeWidth:"handleStrokeWidth",height:"height",iconStrokeColor:"iconStrokeColor",iconStrokeWidth:"iconStrokeWidth",id:"id",margin:"margin",offset:"offset",padding:"padding",pathData:"pathData",tooltip:"tooltip",visibility:"visibility",width:"width"},features:[yn]}),n})(),yle=(()=>{class n extends gh{constructor(){super("fixeduserhandles")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-node-fixeduserhandles"]],contentQueries:function(e,i,r){if(1&e&&dn(r,mle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),Sle=["addInfo","annotationType","constraints","content","dragLimit","height","horizontalAlignment","hyperlink","id","margin","offset","rotateAngle","rotationReference","style","template","tooltip","type","verticalAlignment","visibility","width"],Ile=[],v_=(()=>{class n extends ph{constructor(e){super(),this.viewContainerRef=e,ml("currentInstance",this,this.viewContainerRef),this.registerEvents(Ile),this.directivePropList=Sle}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-node-annotation"]],inputs:{addInfo:"addInfo",annotationType:"annotationType",constraints:"constraints",content:"content",dragLimit:"dragLimit",height:"height",horizontalAlignment:"horizontalAlignment",hyperlink:"hyperlink",id:"id",margin:"margin",offset:"offset",rotateAngle:"rotateAngle",rotationReference:"rotationReference",style:"style",template:"template",tooltip:"tooltip",type:"type",verticalAlignment:"verticalAlignment",visibility:"visibility",width:"width"},features:[yn]}),n})(),m_=(()=>{class n extends gh{constructor(){super("annotations")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-node-annotations"]],contentQueries:function(e,i,r){if(1&e&&dn(r,v_,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),ble=["addInfo","connectionDirection","constraints","height","horizontalAlignment","id","inEdges","margin","offset","outEdges","pathData","shape","style","tooltip","verticalAlignment","visibility","width"],Mle=[],wle=(()=>{class n extends ph{constructor(e){super(),this.viewContainerRef=e,ml("currentInstance",this,this.viewContainerRef),this.registerEvents(Mle),this.directivePropList=ble}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-node-port"]],inputs:{addInfo:"addInfo",connectionDirection:"connectionDirection",constraints:"constraints",height:"height",horizontalAlignment:"horizontalAlignment",id:"id",inEdges:"inEdges",margin:"margin",offset:"offset",outEdges:"outEdges",pathData:"pathData",shape:"shape",style:"style",tooltip:"tooltip",verticalAlignment:"verticalAlignment",visibility:"visibility",width:"width"},features:[yn]}),n})(),Cle=(()=>{class n extends gh{constructor(){super("ports")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-node-ports"]],contentQueries:function(e,i,r){if(1&e&&dn(r,wle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),Ele=["addInfo","annotations","backgroundColor","borderColor","borderWidth","branch","children","collapseIcon","columnIndex","columnSpan","columns","constraints","container","data","dragSize","excludeFromLayout","expandIcon","fixedUserHandles","flip","flipMode","height","horizontalAlignment","id","isExpanded","layoutInfo","margin","maxHeight","maxWidth","minHeight","minWidth","offsetX","offsetY","padding","pivot","ports","previewSize","rotateAngle","rowIndex","rowSpan","rows","shadow","shape","style","symbolInfo","tooltip","verticalAlignment","visible","width","wrapper","zIndex"],Dle=[],y_=(()=>{class n extends ph{constructor(e){super(),this.viewContainerRef=e,this.tags=["fixedUserHandles","annotations","ports"],ml("currentInstance",this,this.viewContainerRef),this.registerEvents(Dle),this.directivePropList=Ele}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-node"]],contentQueries:function(e,i,r){if(1&e&&(dn(r,yle,5),dn(r,m_,5),dn(r,Cle,5)),2&e){let s;Kr(s=en())&&(i.childFixedUserHandles=s.first),Kr(s=en())&&(i.childAnnotations=s.first),Kr(s=en())&&(i.childPorts=s.first)}},inputs:{addInfo:"addInfo",annotations:"annotations",backgroundColor:"backgroundColor",borderColor:"borderColor",borderWidth:"borderWidth",branch:"branch",children:"children",collapseIcon:"collapseIcon",columnIndex:"columnIndex",columnSpan:"columnSpan",columns:"columns",constraints:"constraints",container:"container",data:"data",dragSize:"dragSize",excludeFromLayout:"excludeFromLayout",expandIcon:"expandIcon",fixedUserHandles:"fixedUserHandles",flip:"flip",flipMode:"flipMode",height:"height",horizontalAlignment:"horizontalAlignment",id:"id",isExpanded:"isExpanded",layoutInfo:"layoutInfo",margin:"margin",maxHeight:"maxHeight",maxWidth:"maxWidth",minHeight:"minHeight",minWidth:"minWidth",offsetX:"offsetX",offsetY:"offsetY",padding:"padding",pivot:"pivot",ports:"ports",previewSize:"previewSize",rotateAngle:"rotateAngle",rowIndex:"rowIndex",rowSpan:"rowSpan",rows:"rows",shadow:"shadow",shape:"shape",style:"style",symbolInfo:"symbolInfo",tooltip:"tooltip",verticalAlignment:"verticalAlignment",visible:"visible",width:"width",wrapper:"wrapper",zIndex:"zIndex"},features:[yn]}),n})(),S_=(()=>{class n extends gh{constructor(){super("nodes")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-nodes"]],contentQueries:function(e,i,r){if(1&e&&dn(r,y_,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})();const xle=["animationComplete","click","collectionChange","commandExecute","connectionChange","contextMenuBeforeItemRender","contextMenuClick","contextMenuOpen","created","dataLoaded","doubleClick","dragEnter","dragLeave","dragOver","drop","elementDraw","expandStateChange","fixedUserHandleClick","historyChange","historyStateChange","keyDown","keyUp","load","loaded","mouseEnter","mouseLeave","mouseOver","mouseWheel","onFixedUserHandleMouseDown","onFixedUserHandleMouseEnter","onFixedUserHandleMouseLeave","onFixedUserHandleMouseUp","onImageLoad","onUserHandleMouseDown","onUserHandleMouseEnter","onUserHandleMouseLeave","onUserHandleMouseUp","positionChange","propertyChange","rotateChange","scrollChange","segmentChange","segmentCollectionChange","selectionChange","sizeChange","sourcePointChange","targetPointChange","textEdit"],Tle=[""];let Ale=(()=>{let n=class extends _l{constructor(e,i,r,s){super(),this.ngEle=e,this.srenderer=i,this.viewContainerRef=r,this.injector=s,this.tags=["layers","customCursor","connectors","nodes"],this.element=this.ngEle.nativeElement,this.injectedModules=this.injectedModules||[];try{let o=this.injector.get("DiagramsHierarchicalTree");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsMindMap");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsRadialTree");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsComplexHierarchicalTree");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsDataBinding");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsSnapping");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsPrintAndExport");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsBpmnDiagrams");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsSymmetricLayout");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsConnectorBridging");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsUndoRedo");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsLayoutAnimation");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsDiagramContextMenu");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsLineRouting");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsConnectorEditing");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsLineDistribution");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsEj1Serialization");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsFlowchartLayout");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}this.registerEvents(xle),this.addTwoWay.call(this,Tle),ml("currentInstance",this,this.viewContainerRef),this.context=new SR}ngOnInit(){this.context.ngOnInit(this)}ngAfterViewInit(){this.context.ngAfterViewInit(this)}ngOnDestroy(){this.context.ngOnDestroy(this)}ngAfterContentChecked(){this.tagObjects[0].instance=this.childLayers,this.childCustomCursor&&(this.tagObjects[1].instance=this.childCustomCursor),this.childConnectors&&(this.tagObjects[2].instance=this.childConnectors),this.childNodes&&(this.tagObjects[3].instance=this.childNodes),this.context.ngAfterContentChecked(this)}};return n.\u0275fac=function(e){return new(e||n)(Ot($c),Ot(cM),Ot(An),Ot(Wo))},n.\u0275cmp=_b({type:n,selectors:[["ejs-diagram"]],contentQueries:function(e,i,r){if(1&e&&(dn(r,Qae,5),dn(r,Gae,5),dn(r,Xae,5),dn(r,Jae,5),dn(r,ile,5),dn(r,ple,5),dn(r,S_,5)),2&e){let s;Kr(s=en())&&(i.annotationTemplate=s.first),Kr(s=en())&&(i.nodeTemplate=s.first),Kr(s=en())&&(i.userHandleTemplate=s.first),Kr(s=en())&&(i.childLayers=s.first),Kr(s=en())&&(i.childCustomCursor=s.first),Kr(s=en())&&(i.childConnectors=s.first),Kr(s=en())&&(i.childNodes=s.first)}},inputs:{addInfo:"addInfo",annotationTemplate:"annotationTemplate",backgroundColor:"backgroundColor",bridgeDirection:"bridgeDirection",commandManager:"commandManager",connectorDefaults:"connectorDefaults",connectors:"connectors",constraints:"constraints",contextMenuSettings:"contextMenuSettings",customCursor:"customCursor",dataSourceSettings:"dataSourceSettings",diagramSettings:"diagramSettings",drawingObject:"drawingObject",enableConnectorSplit:"enableConnectorSplit",enablePersistence:"enablePersistence",enableRtl:"enableRtl",fixedUserHandleTemplate:"fixedUserHandleTemplate",getConnectorDefaults:"getConnectorDefaults",getCustomCursor:"getCustomCursor",getCustomProperty:"getCustomProperty",getCustomTool:"getCustomTool",getDescription:"getDescription",getNodeDefaults:"getNodeDefaults",height:"height",historyManager:"historyManager",layers:"layers",layout:"layout",locale:"locale",mode:"mode",nodeDefaults:"nodeDefaults",nodeTemplate:"nodeTemplate",nodes:"nodes",pageSettings:"pageSettings",rulerSettings:"rulerSettings",scrollSettings:"scrollSettings",segmentThumbShape:"segmentThumbShape",segmentThumbSize:"segmentThumbSize",selectedItems:"selectedItems",serializationSettings:"serializationSettings",setNodeTemplate:"setNodeTemplate",snapSettings:"snapSettings",tool:"tool",tooltip:"tooltip",updateSelection:"updateSelection",userHandleTemplate:"userHandleTemplate",width:"width"},outputs:{animationComplete:"animationComplete",click:"click",collectionChange:"collectionChange",commandExecute:"commandExecute",connectionChange:"connectionChange",contextMenuBeforeItemRender:"contextMenuBeforeItemRender",contextMenuClick:"contextMenuClick",contextMenuOpen:"contextMenuOpen",created:"created",dataLoaded:"dataLoaded",doubleClick:"doubleClick",dragEnter:"dragEnter",dragLeave:"dragLeave",dragOver:"dragOver",drop:"drop",elementDraw:"elementDraw",expandStateChange:"expandStateChange",fixedUserHandleClick:"fixedUserHandleClick",historyChange:"historyChange",historyStateChange:"historyStateChange",keyDown:"keyDown",keyUp:"keyUp",load:"load",loaded:"loaded",mouseEnter:"mouseEnter",mouseLeave:"mouseLeave",mouseOver:"mouseOver",mouseWheel:"mouseWheel",onFixedUserHandleMouseDown:"onFixedUserHandleMouseDown",onFixedUserHandleMouseEnter:"onFixedUserHandleMouseEnter",onFixedUserHandleMouseLeave:"onFixedUserHandleMouseLeave",onFixedUserHandleMouseUp:"onFixedUserHandleMouseUp",onImageLoad:"onImageLoad",onUserHandleMouseDown:"onUserHandleMouseDown",onUserHandleMouseEnter:"onUserHandleMouseEnter",onUserHandleMouseLeave:"onUserHandleMouseLeave",onUserHandleMouseUp:"onUserHandleMouseUp",positionChange:"positionChange",propertyChange:"propertyChange",rotateChange:"rotateChange",scrollChange:"scrollChange",segmentChange:"segmentChange",segmentCollectionChange:"segmentCollectionChange",selectionChange:"selectionChange",sizeChange:"sizeChange",sourcePointChange:"sourcePointChange",targetPointChange:"targetPointChange",textEdit:"textEdit"},features:[yn],decls:0,vars:0,template:function(e,i){},encapsulation:2,changeDetection:0}),k0([xC()],n.prototype,"annotationTemplate",void 0),k0([xC()],n.prototype,"nodeTemplate",void 0),k0([xC()],n.prototype,"userHandleTemplate",void 0),n=k0([PZ([SR])],n),n})(),Lle=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=km({type:n}),n.\u0275inj=yp({imports:[[sq]]}),n})();const Nle=["diagram"];let Ole=(()=>{class n{constructor(){this.layers=[]}ngOnInit(){this.layers=[{id:"layer1",objects:["node1","node3"]},{id:"layers2",objects:["node2"]}]}clonelayer(){this.diagram.cloneLayer("layer1")}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275cmp=_b({type:n,selectors:[["app-container"]],viewQuery:function(i,r){if(1&i&&function uP(n,t,e){const i=Ti();i.firstCreatePass&&(cP(i,new aP(n,t,e),-1),2==(2&t)&&(i.staticViewQueries=!0)),hP(i,Se(),t)}(Nle,5),2&i){let s;Kr(s=en())&&(r.diagram=s.first)}},standalone:!0,features:[PP([]),RP],decls:14,vars:13,consts:[[3,"click"],["id","diagram","width","100%","height","580px",3,"layers"],["diagram",""],["id","node1",3,"width","height","offsetX","offsetY"],["content","Layer 1 Object"],["id","node2",3,"width","height","offsetX","offsetY"],["content","Layer 2 Object"],["id","node3",3,"width","height","offsetX","offsetY"]],template:function(i,r){1&i&&(id(0,"button",0),lw("click",function(){return r.clonelayer()}),function MP(n,t=""){const e=Se(),i=Ti(),r=n+jt,s=i.firstCreatePass?Lu(i,r,1,t,null):i.data[r],o=wP(i,e,s,t,n);e[r]=o,_m()&&uy(i,e,o,s),ll(s,!1)}(1,"clonelayer"),rd(),id(2,"ejs-diagram",1,2)(4,"e-nodes")(5,"e-node",3)(6,"e-node-annotations"),ug(7,"e-node-annotation",4),rd()(),id(8,"e-node",5)(9,"e-node-annotations"),ug(10,"e-node-annotation",6),rd()(),id(11,"e-node",7)(12,"e-node-annotations"),ug(13,"e-node-annotation",4),rd()()()()),2&i&&(Xp(2),qu("layers",r.layers),Xp(3),qu("width",100)("height",100)("offsetX",100)("offsetY",100),Xp(3),qu("width",100)("height",100)("offsetX",160)("offsetY",360),Xp(3),qu("width",100)("height",100)("offsetX",300)("offsetY",100))},dependencies:[Lle,Ale,v_,m_,y_,S_],encapsulation:2})}}return n})();Wd(332),function $q(n,t){return DG({rootComponent:n,...Ez(t)})}(Ole).catch(n=>console.error(n))},332:()=>{!function(Z){const se=Z.performance;function ye(zi){se&&se.mark&&se.mark(zi)}function pe(zi,ht){se&&se.measure&&se.measure(zi,ht)}ye("Zone");const be=Z.__Zone_symbol_prefix||"__zone_symbol__";function ke(zi){return be+zi}const at=!0===Z[ke("forceDuplicateZoneCheck")];if(Z.Zone){if(at||"function"!=typeof Z.Zone.__symbol__)throw new Error("Zone already loaded.");return Z.Zone}let tt=(()=>{class zi{static{this.__symbol__=ke}static assertZonePatched(){if(Z.Promise!==_o.ZoneAwarePromise)throw new Error("Zone.js has detected that ZoneAwarePromise `(window|global).Promise` has been overwritten.\nMost likely cause is that a Promise polyfill has been loaded after Zone.js (Polyfilling Promise api is not necessary when zone.js is loaded. If you must load one, do so before loading zone.js.)")}static get root(){let F=zi.current;for(;F.parent;)F=F.parent;return F}static get current(){return Ur.zone}static get currentTask(){return Do}static __load_patch(F,ae,Et=!1){if(_o.hasOwnProperty(F)){if(!Et&&at)throw Error("Already loaded patch: "+F)}else if(!Z["__Zone_disable_"+F]){const Xt="Zone:"+F;ye(Xt),_o[F]=ae(Z,zi,cn),pe(Xt,Xt)}}get parent(){return this._parent}get name(){return this._name}constructor(F,ae){this._parent=F,this._name=ae?ae.name||"unnamed":"",this._properties=ae&&ae.properties||{},this._zoneDelegate=new Lt(this,this._parent&&this._parent._zoneDelegate,ae)}get(F){const ae=this.getZoneWith(F);if(ae)return ae._properties[F]}getZoneWith(F){let ae=this;for(;ae;){if(ae._properties.hasOwnProperty(F))return ae;ae=ae._parent}return null}fork(F){if(!F)throw new Error("ZoneSpec required!");return this._zoneDelegate.fork(this,F)}wrap(F,ae){if("function"!=typeof F)throw new Error("Expecting function got: "+F);const Et=this._zoneDelegate.intercept(this,F,ae),Xt=this;return function(){return Xt.runGuarded(Et,this,arguments,ae)}}run(F,ae,Et,Xt){Ur={parent:Ur,zone:this};try{return this._zoneDelegate.invoke(this,F,ae,Et,Xt)}finally{Ur=Ur.parent}}runGuarded(F,ae=null,Et,Xt){Ur={parent:Ur,zone:this};try{try{return this._zoneDelegate.invoke(this,F,ae,Et,Xt)}catch(Vn){if(this._zoneDelegate.handleError(this,Vn))throw Vn}}finally{Ur=Ur.parent}}runTask(F,ae,Et){if(F.zone!=this)throw new Error("A task can only be run in the zone of creation! (Creation: "+(F.zone||jn).name+"; Execution: "+this.name+")");if(F.state===sr&&(F.type===rs||F.type===Pt))return;const Xt=F.state!=lt;Xt&&F._transitionTo(lt,Pi),F.runCount++;const Vn=Do;Do=F,Ur={parent:Ur,zone:this};try{F.type==Pt&&F.data&&!F.data.isPeriodic&&(F.cancelFn=void 0);try{return this._zoneDelegate.invokeTask(this,F,ae,Et)}catch(Ue){if(this._zoneDelegate.handleError(this,Ue))throw Ue}}finally{F.state!==sr&&F.state!==et&&(F.type==rs||F.data&&F.data.isPeriodic?Xt&&F._transitionTo(Pi,lt):(F.runCount=0,this._updateTaskCount(F,-1),Xt&&F._transitionTo(sr,lt,sr))),Ur=Ur.parent,Do=Vn}}scheduleTask(F){if(F.zone&&F.zone!==this){let Et=this;for(;Et;){if(Et===F.zone)throw Error(`can not reschedule task to ${this.name} which is descendants of the original zone ${F.zone.name}`);Et=Et.parent}}F._transitionTo(Zr,sr);const ae=[];F._zoneDelegates=ae,F._zone=this;try{F=this._zoneDelegate.scheduleTask(this,F)}catch(Et){throw F._transitionTo(et,Zr,sr),this._zoneDelegate.handleError(this,Et),Et}return F._zoneDelegates===ae&&this._updateTaskCount(F,1),F.state==Zr&&F._transitionTo(Pi,Zr),F}scheduleMicroTask(F,ae,Et,Xt){return this.scheduleTask(new pt(yi,F,ae,Et,Xt,void 0))}scheduleMacroTask(F,ae,Et,Xt,Vn){return this.scheduleTask(new pt(Pt,F,ae,Et,Xt,Vn))}scheduleEventTask(F,ae,Et,Xt,Vn){return this.scheduleTask(new pt(rs,F,ae,Et,Xt,Vn))}cancelTask(F){if(F.zone!=this)throw new Error("A task can only be cancelled in the zone of creation! (Creation: "+(F.zone||jn).name+"; Execution: "+this.name+")");if(F.state===Pi||F.state===lt){F._transitionTo(dr,Pi,lt);try{this._zoneDelegate.cancelTask(this,F)}catch(ae){throw F._transitionTo(et,dr),this._zoneDelegate.handleError(this,ae),ae}return this._updateTaskCount(F,-1),F._transitionTo(sr,dr),F.runCount=0,F}}_updateTaskCount(F,ae){const Et=F._zoneDelegates;-1==ae&&(F._zoneDelegates=null);for(let Xt=0;Xtzi.hasTask(F,ae),onScheduleTask:(zi,ht,F,ae)=>zi.scheduleTask(F,ae),onInvokeTask:(zi,ht,F,ae,Et,Xt)=>zi.invokeTask(F,ae,Et,Xt),onCancelTask:(zi,ht,F,ae)=>zi.cancelTask(F,ae)};class Lt{constructor(ht,F,ae){this._taskCounts={microTask:0,macroTask:0,eventTask:0},this.zone=ht,this._parentDelegate=F,this._forkZS=ae&&(ae&&ae.onFork?ae:F._forkZS),this._forkDlgt=ae&&(ae.onFork?F:F._forkDlgt),this._forkCurrZone=ae&&(ae.onFork?this.zone:F._forkCurrZone),this._interceptZS=ae&&(ae.onIntercept?ae:F._interceptZS),this._interceptDlgt=ae&&(ae.onIntercept?F:F._interceptDlgt),this._interceptCurrZone=ae&&(ae.onIntercept?this.zone:F._interceptCurrZone),this._invokeZS=ae&&(ae.onInvoke?ae:F._invokeZS),this._invokeDlgt=ae&&(ae.onInvoke?F:F._invokeDlgt),this._invokeCurrZone=ae&&(ae.onInvoke?this.zone:F._invokeCurrZone),this._handleErrorZS=ae&&(ae.onHandleError?ae:F._handleErrorZS),this._handleErrorDlgt=ae&&(ae.onHandleError?F:F._handleErrorDlgt),this._handleErrorCurrZone=ae&&(ae.onHandleError?this.zone:F._handleErrorCurrZone),this._scheduleTaskZS=ae&&(ae.onScheduleTask?ae:F._scheduleTaskZS),this._scheduleTaskDlgt=ae&&(ae.onScheduleTask?F:F._scheduleTaskDlgt),this._scheduleTaskCurrZone=ae&&(ae.onScheduleTask?this.zone:F._scheduleTaskCurrZone),this._invokeTaskZS=ae&&(ae.onInvokeTask?ae:F._invokeTaskZS),this._invokeTaskDlgt=ae&&(ae.onInvokeTask?F:F._invokeTaskDlgt),this._invokeTaskCurrZone=ae&&(ae.onInvokeTask?this.zone:F._invokeTaskCurrZone),this._cancelTaskZS=ae&&(ae.onCancelTask?ae:F._cancelTaskZS),this._cancelTaskDlgt=ae&&(ae.onCancelTask?F:F._cancelTaskDlgt),this._cancelTaskCurrZone=ae&&(ae.onCancelTask?this.zone:F._cancelTaskCurrZone),this._hasTaskZS=null,this._hasTaskDlgt=null,this._hasTaskDlgtOwner=null,this._hasTaskCurrZone=null;const Et=ae&&ae.onHasTask;(Et||F&&F._hasTaskZS)&&(this._hasTaskZS=Et?ae:At,this._hasTaskDlgt=F,this._hasTaskDlgtOwner=this,this._hasTaskCurrZone=ht,ae.onScheduleTask||(this._scheduleTaskZS=At,this._scheduleTaskDlgt=F,this._scheduleTaskCurrZone=this.zone),ae.onInvokeTask||(this._invokeTaskZS=At,this._invokeTaskDlgt=F,this._invokeTaskCurrZone=this.zone),ae.onCancelTask||(this._cancelTaskZS=At,this._cancelTaskDlgt=F,this._cancelTaskCurrZone=this.zone))}fork(ht,F){return this._forkZS?this._forkZS.onFork(this._forkDlgt,this.zone,ht,F):new tt(ht,F)}intercept(ht,F,ae){return this._interceptZS?this._interceptZS.onIntercept(this._interceptDlgt,this._interceptCurrZone,ht,F,ae):F}invoke(ht,F,ae,Et,Xt){return this._invokeZS?this._invokeZS.onInvoke(this._invokeDlgt,this._invokeCurrZone,ht,F,ae,Et,Xt):F.apply(ae,Et)}handleError(ht,F){return!this._handleErrorZS||this._handleErrorZS.onHandleError(this._handleErrorDlgt,this._handleErrorCurrZone,ht,F)}scheduleTask(ht,F){let ae=F;if(this._scheduleTaskZS)this._hasTaskZS&&ae._zoneDelegates.push(this._hasTaskDlgtOwner),ae=this._scheduleTaskZS.onScheduleTask(this._scheduleTaskDlgt,this._scheduleTaskCurrZone,ht,F),ae||(ae=F);else if(F.scheduleFn)F.scheduleFn(F);else{if(F.type!=yi)throw new Error("Task is missing scheduleFn.");Wt(F)}return ae}invokeTask(ht,F,ae,Et){return this._invokeTaskZS?this._invokeTaskZS.onInvokeTask(this._invokeTaskDlgt,this._invokeTaskCurrZone,ht,F,ae,Et):F.callback.apply(ae,Et)}cancelTask(ht,F){let ae;if(this._cancelTaskZS)ae=this._cancelTaskZS.onCancelTask(this._cancelTaskDlgt,this._cancelTaskCurrZone,ht,F);else{if(!F.cancelFn)throw Error("Task is not cancelable");ae=F.cancelFn(F)}return ae}hasTask(ht,F){try{this._hasTaskZS&&this._hasTaskZS.onHasTask(this._hasTaskDlgt,this._hasTaskCurrZone,ht,F)}catch(ae){this.handleError(ht,ae)}}_updateTaskCount(ht,F){const ae=this._taskCounts,Et=ae[ht],Xt=ae[ht]=Et+F;if(Xt<0)throw new Error("More tasks executed then were scheduled.");0!=Et&&0!=Xt||this.hasTask(this.zone,{microTask:ae.microTask>0,macroTask:ae.macroTask>0,eventTask:ae.eventTask>0,change:ht})}}class pt{constructor(ht,F,ae,Et,Xt,Vn){if(this._zone=null,this.runCount=0,this._zoneDelegates=null,this._state="notScheduled",this.type=ht,this.source=F,this.data=Et,this.scheduleFn=Xt,this.cancelFn=Vn,!ae)throw new Error("callback is not defined");this.callback=ae;const Ue=this;this.invoke=ht===rs&&Et&&Et.useG?pt.invokeTask:function(){return pt.invokeTask.call(Z,Ue,this,arguments)}}static invokeTask(ht,F,ae){ht||(ht=this),Ls++;try{return ht.runCount++,ht.zone.runTask(ht,F,ae)}finally{1==Ls&&ct(),Ls--}}get zone(){return this._zone}get state(){return this._state}cancelScheduleRequest(){this._transitionTo(sr,Zr)}_transitionTo(ht,F,ae){if(this._state!==F&&this._state!==ae)throw new Error(`${this.type} '${this.source}': can not transition to '${ht}', expecting state '${F}'${ae?" or '"+ae+"'":""}, was '${this._state}'.`);this._state=ht,ht==sr&&(this._zoneDelegates=null)}toString(){return this.data&&typeof this.data.handleId<"u"?this.data.handleId.toString():Object.prototype.toString.call(this)}toJSON(){return{type:this.type,state:this.state,source:this.source,zone:this.zone.name,runCount:this.runCount}}}const Di=ke("setTimeout"),ni=ke("Promise"),mi=ke("then");let is,cr=[],ki=!1;function Pr(zi){if(is||Z[ni]&&(is=Z[ni].resolve(0)),is){let ht=is[mi];ht||(ht=is.then),ht.call(is,zi)}else Z[Di](zi,0)}function Wt(zi){0===Ls&&0===cr.length&&Pr(ct),zi&&cr.push(zi)}function ct(){if(!ki){for(ki=!0;cr.length;){const zi=cr;cr=[];for(let ht=0;htUr,onUnhandledError:jr,microtaskDrainDone:jr,scheduleMicroTask:Wt,showUncaughtError:()=>!tt[ke("ignoreConsoleErrorUncaughtError")],patchEventTarget:()=>[],patchOnProperties:jr,patchMethod:()=>jr,bindArguments:()=>[],patchThen:()=>jr,patchMacroTask:()=>jr,patchEventPrototype:()=>jr,isIEOrEdge:()=>!1,getGlobalObjects:()=>{},ObjectDefineProperty:()=>jr,ObjectGetOwnPropertyDescriptor:()=>{},ObjectCreate:()=>{},ArraySlice:()=>[],patchClass:()=>jr,wrapWithCurrentZone:()=>jr,filterProperties:()=>[],attachOriginToPatched:()=>jr,_redefineProperty:()=>jr,patchCallbacks:()=>jr,nativeScheduleMicroTask:Pr};let Ur={parent:null,zone:new tt(null,null)},Do=null,Ls=0;function jr(){}pe("Zone","Zone"),Z.Zone=tt}(globalThis);const Wl=Object.getOwnPropertyDescriptor,Vd=Object.defineProperty,Wd=Object.getPrototypeOf,Yd=Object.create,Sb=Array.prototype.slice,mm="addEventListener",$r="removeEventListener",Yl=Zone.__symbol__(mm),_h=Zone.__symbol__($r),Ts="true",Wi="false",Qd=Zone.__symbol__("");function hp(Z,se){return Zone.current.wrap(Z,se)}function ym(Z,se,ye,pe,be){return Zone.current.scheduleMacroTask(Z,se,ye,pe,be)}const Ji=Zone.__symbol__,Uh=typeof window<"u",jh=Uh?window:void 0,gn=Uh&&jh||globalThis,Sm="removeAttribute";function Gd(Z,se){for(let ye=Z.length-1;ye>=0;ye--)"function"==typeof Z[ye]&&(Z[ye]=hp(Z[ye],se+"_"+ye));return Z}function cp(Z){return!Z||!1!==Z.writable&&!("function"==typeof Z.get&&typeof Z.set>"u")}const dp=typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope,Vh=!("nw"in gn)&&typeof gn.process<"u"&&"[object process]"==={}.toString.call(gn.process),Xd=!Vh&&!dp&&!(!Uh||!jh.HTMLElement),up=typeof gn.process<"u"&&"[object process]"==={}.toString.call(gn.process)&&!dp&&!(!Uh||!jh.HTMLElement),Ql={},Wh=function(Z){if(!(Z=Z||gn.event))return;let se=Ql[Z.type];se||(se=Ql[Z.type]=Ji("ON_PROPERTY"+Z.type));const ye=this||Z.target||gn,pe=ye[se];let be;return Xd&&ye===jh&&"error"===Z.type?(be=pe&&pe.call(this,Z.message,Z.filename,Z.lineno,Z.colno,Z.error),!0===be&&Z.preventDefault()):(be=pe&&pe.apply(this,arguments),null!=be&&!be&&Z.preventDefault()),be};function Gl(Z,se,ye){let pe=Wl(Z,se);if(!pe&&ye&&Wl(ye,se)&&(pe={enumerable:!0,configurable:!0}),!pe||!pe.configurable)return;const be=Ji("on"+se+"patched");if(Z.hasOwnProperty(be)&&Z[be])return;delete pe.writable,delete pe.value;const ke=pe.get,at=pe.set,tt=se.slice(2);let At=Ql[tt];At||(At=Ql[tt]=Ji("ON_PROPERTY"+tt)),pe.set=function(Lt){let pt=this;!pt&&Z===gn&&(pt=gn),pt&&("function"==typeof pt[At]&&pt.removeEventListener(tt,Wh),at&&at.call(pt,null),pt[At]=Lt,"function"==typeof Lt&&pt.addEventListener(tt,Wh,!1))},pe.get=function(){let Lt=this;if(!Lt&&Z===gn&&(Lt=gn),!Lt)return null;const pt=Lt[At];if(pt)return pt;if(ke){let Di=ke.call(this);if(Di)return pe.set.call(this,Di),"function"==typeof Lt[Sm]&&Lt.removeAttribute(se),Di}return null},Vd(Z,se,pe),Z[be]=!0}function fp(Z,se,ye){if(se)for(let pe=0;pefunction(at,tt){const At=ye(at,tt);return At.cbIdx>=0&&"function"==typeof tt[At.cbIdx]?ym(At.name,tt[At.cbIdx],At,be):ke.apply(at,tt)})}function Ia(Z,se){Z[Ji("OriginalDelegate")]=se}let bb=!1,$d=!1;function Mb(){if(bb)return $d;bb=!0;try{const Z=jh.navigator.userAgent;(-1!==Z.indexOf("MSIE ")||-1!==Z.indexOf("Trident/")||-1!==Z.indexOf("Edge/"))&&($d=!0)}catch{}return $d}Zone.__load_patch("ZoneAwarePromise",(Z,se,ye)=>{const pe=Object.getOwnPropertyDescriptor,be=Object.defineProperty,at=ye.symbol,tt=[],At=!1!==Z[at("DISABLE_WRAPPING_UNCAUGHT_PROMISE_REJECTION")],Lt=at("Promise"),pt=at("then"),Di="__creationTrace__";ye.onUnhandledError=Ue=>{if(ye.showUncaughtError()){const He=Ue&&Ue.rejection;He?console.error("Unhandled Promise rejection:",He instanceof Error?He.message:He,"; Zone:",Ue.zone.name,"; Task:",Ue.task&&Ue.task.source,"; Value:",He,He instanceof Error?He.stack:void 0):console.error(Ue)}},ye.microtaskDrainDone=()=>{for(;tt.length;){const Ue=tt.shift();try{Ue.zone.runGuarded(()=>{throw Ue.throwOriginal?Ue.rejection:Ue})}catch(He){mi(He)}}};const ni=at("unhandledPromiseRejectionHandler");function mi(Ue){ye.onUnhandledError(Ue);try{const He=se[ni];"function"==typeof He&&He.call(this,Ue)}catch{}}function cr(Ue){return Ue&&Ue.then}function ki(Ue){return Ue}function is(Ue){return F.reject(Ue)}const Pr=at("state"),Wt=at("value"),ct=at("finally"),jn=at("parentPromiseValue"),sr=at("parentPromiseState"),Zr="Promise.then",Pi=null,lt=!0,dr=!1,et=0;function yi(Ue,He){return ge=>{try{cn(Ue,He,ge)}catch(We){cn(Ue,!1,We)}}}const Pt=function(){let Ue=!1;return function(ge){return function(){Ue||(Ue=!0,ge.apply(null,arguments))}}},rs="Promise resolved with itself",_o=at("currentTaskTrace");function cn(Ue,He,ge){const We=Pt();if(Ue===ge)throw new TypeError(rs);if(Ue[Pr]===Pi){let wt=null;try{("object"==typeof ge||"function"==typeof ge)&&(wt=ge&&ge.then)}catch(Xe){return We(()=>{cn(Ue,!1,Xe)})(),Ue}if(He!==dr&&ge instanceof F&&ge.hasOwnProperty(Pr)&&ge.hasOwnProperty(Wt)&&ge[Pr]!==Pi)Do(ge),cn(Ue,ge[Pr],ge[Wt]);else if(He!==dr&&"function"==typeof wt)try{wt.call(ge,We(yi(Ue,He)),We(yi(Ue,!1)))}catch(Xe){We(()=>{cn(Ue,!1,Xe)})()}else{Ue[Pr]=He;const Xe=Ue[Wt];if(Ue[Wt]=ge,Ue[ct]===ct&&He===lt&&(Ue[Pr]=Ue[sr],Ue[Wt]=Ue[jn]),He===dr&&ge instanceof Error){const mt=se.currentTask&&se.currentTask.data&&se.currentTask.data[Di];mt&&be(ge,_o,{configurable:!0,enumerable:!1,writable:!0,value:mt})}for(let mt=0;mt{try{const dt=Ue[Wt],qt=!!ge&&ct===ge[ct];qt&&(ge[jn]=dt,ge[sr]=Xe);const li=He.run(mt,void 0,qt&&mt!==is&&mt!==ki?[]:[dt]);cn(ge,!0,li)}catch(dt){cn(ge,!1,dt)}},ge)}const zi=function(){},ht=Z.AggregateError;class F{static toString(){return"function ZoneAwarePromise() { [native code] }"}static resolve(He){return He instanceof F?He:cn(new this(null),lt,He)}static reject(He){return cn(new this(null),dr,He)}static withResolvers(){const He={};return He.promise=new F((ge,We)=>{He.resolve=ge,He.reject=We}),He}static any(He){if(!He||"function"!=typeof He[Symbol.iterator])return Promise.reject(new ht([],"All promises were rejected"));const ge=[];let We=0;try{for(let mt of He)We++,ge.push(F.resolve(mt))}catch{return Promise.reject(new ht([],"All promises were rejected"))}if(0===We)return Promise.reject(new ht([],"All promises were rejected"));let wt=!1;const Xe=[];return new F((mt,dt)=>{for(let qt=0;qt{wt||(wt=!0,mt(li))},li=>{Xe.push(li),We--,0===We&&(wt=!0,dt(new ht(Xe,"All promises were rejected")))})})}static race(He){let ge,We,wt=new this((dt,qt)=>{ge=dt,We=qt});function Xe(dt){ge(dt)}function mt(dt){We(dt)}for(let dt of He)cr(dt)||(dt=this.resolve(dt)),dt.then(Xe,mt);return wt}static all(He){return F.allWithCallback(He)}static allSettled(He){return(this&&this.prototype instanceof F?this:F).allWithCallback(He,{thenCallback:We=>({status:"fulfilled",value:We}),errorCallback:We=>({status:"rejected",reason:We})})}static allWithCallback(He,ge){let We,wt,Xe=new this((li,ur)=>{We=li,wt=ur}),mt=2,dt=0;const qt=[];for(let li of He){cr(li)||(li=this.resolve(li));const ur=dt;try{li.then(ir=>{qt[ur]=ge?ge.thenCallback(ir):ir,mt--,0===mt&&We(qt)},ir=>{ge?(qt[ur]=ge.errorCallback(ir),mt--,0===mt&&We(qt)):wt(ir)})}catch(ir){wt(ir)}mt++,dt++}return mt-=2,0===mt&&We(qt),Xe}constructor(He){const ge=this;if(!(ge instanceof F))throw new Error("Must be an instanceof Promise.");ge[Pr]=Pi,ge[Wt]=[];try{const We=Pt();He&&He(We(yi(ge,lt)),We(yi(ge,dr)))}catch(We){cn(ge,!1,We)}}get[Symbol.toStringTag](){return"Promise"}get[Symbol.species](){return F}then(He,ge){let We=this.constructor?.[Symbol.species];(!We||"function"!=typeof We)&&(We=this.constructor||F);const wt=new We(zi),Xe=se.current;return this[Pr]==Pi?this[Wt].push(Xe,wt,He,ge):Ls(this,Xe,wt,He,ge),wt}catch(He){return this.then(null,He)}finally(He){let ge=this.constructor?.[Symbol.species];(!ge||"function"!=typeof ge)&&(ge=F);const We=new ge(zi);We[ct]=ct;const wt=se.current;return this[Pr]==Pi?this[Wt].push(wt,We,He,He):Ls(this,wt,We,He,He),We}}F.resolve=F.resolve,F.reject=F.reject,F.race=F.race,F.all=F.all;const ae=Z[Lt]=Z.Promise;Z.Promise=F;const Et=at("thenPatched");function Xt(Ue){const He=Ue.prototype,ge=pe(He,"then");if(ge&&(!1===ge.writable||!ge.configurable))return;const We=He.then;He[pt]=We,Ue.prototype.then=function(wt,Xe){return new F((dt,qt)=>{We.call(this,dt,qt)}).then(wt,Xe)},Ue[Et]=!0}return ye.patchThen=Xt,ae&&(Xt(ae),tl(Z,"fetch",Ue=>function Vn(Ue){return function(He,ge){let We=Ue.apply(He,ge);if(We instanceof F)return We;let wt=We.constructor;return wt[Et]||Xt(wt),We}}(Ue))),Promise[se.__symbol__("uncaughtPromiseErrors")]=tt,F}),Zone.__load_patch("toString",Z=>{const se=Function.prototype.toString,ye=Ji("OriginalDelegate"),pe=Ji("Promise"),be=Ji("Error"),ke=function(){if("function"==typeof this){const Lt=this[ye];if(Lt)return"function"==typeof Lt?se.call(Lt):Object.prototype.toString.call(Lt);if(this===Promise){const pt=Z[pe];if(pt)return se.call(pt)}if(this===Error){const pt=Z[be];if(pt)return se.call(pt)}}return se.call(this)};ke[ye]=se,Function.prototype.toString=ke;const at=Object.prototype.toString;Object.prototype.toString=function(){return"function"==typeof Promise&&this instanceof Promise?"[object Promise]":at.call(this)}});let il=!1;if(typeof window<"u")try{const Z=Object.defineProperty({},"passive",{get:function(){il=!0}});window.addEventListener("test",Z,Z),window.removeEventListener("test",Z,Z)}catch{il=!1}const PT={useG:!0},Co={},wb={},Mm=new RegExp("^"+Qd+"(\\w+)(true|false)$"),Cb=Ji("propagationStopped");function wm(Z,se){const ye=(se?se(Z):Z)+Wi,pe=(se?se(Z):Z)+Ts,be=Qd+ye,ke=Qd+pe;Co[Z]={},Co[Z][Wi]=be,Co[Z][Ts]=ke}function Eb(Z,se,ye,pe){const be=pe&&pe.add||mm,ke=pe&&pe.rm||$r,at=pe&&pe.listeners||"eventListeners",tt=pe&&pe.rmAll||"removeAllListeners",At=Ji(be),Lt="."+be+":",pt="prependListener",Di="."+pt+":",ni=function(Wt,ct,jn){if(Wt.isRemoved)return;const sr=Wt.callback;let Zr;"object"==typeof sr&&sr.handleEvent&&(Wt.callback=lt=>sr.handleEvent(lt),Wt.originalDelegate=sr);try{Wt.invoke(Wt,ct,[jn])}catch(lt){Zr=lt}const Pi=Wt.options;return Pi&&"object"==typeof Pi&&Pi.once&&ct[ke].call(ct,jn.type,Wt.originalDelegate?Wt.originalDelegate:Wt.callback,Pi),Zr};function mi(Wt,ct,jn){if(!(ct=ct||Z.event))return;const sr=Wt||ct.target||Z,Zr=sr[Co[ct.type][jn?Ts:Wi]];if(Zr){const Pi=[];if(1===Zr.length){const lt=ni(Zr[0],sr,ct);lt&&Pi.push(lt)}else{const lt=Zr.slice();for(let dr=0;dr{throw dr})}}}const cr=function(Wt){return mi(this,Wt,!1)},ki=function(Wt){return mi(this,Wt,!0)};function is(Wt,ct){if(!Wt)return!1;let jn=!0;ct&&void 0!==ct.useG&&(jn=ct.useG);const sr=ct&&ct.vh;let Zr=!0;ct&&void 0!==ct.chkDup&&(Zr=ct.chkDup);let Pi=!1;ct&&void 0!==ct.rt&&(Pi=ct.rt);let lt=Wt;for(;lt&&!lt.hasOwnProperty(be);)lt=Wd(lt);if(!lt&&Wt[be]&&(lt=Wt),!lt||lt[At])return!1;const dr=ct&&ct.eventNameToString,et={},yi=lt[At]=lt[be],Pt=lt[Ji(ke)]=lt[ke],rs=lt[Ji(at)]=lt[at],_o=lt[Ji(tt)]=lt[tt];let cn;ct&&ct.prepend&&(cn=lt[Ji(ct.prepend)]=lt[ct.prepend]);const F=jn?function(ge){if(!et.isExisting)return yi.call(et.target,et.eventName,et.capture?ki:cr,et.options)}:function(ge){return yi.call(et.target,et.eventName,ge.invoke,et.options)},ae=jn?function(ge){if(!ge.isRemoved){const We=Co[ge.eventName];let wt;We&&(wt=We[ge.capture?Ts:Wi]);const Xe=wt&&ge.target[wt];if(Xe)for(let mt=0;mt{Vo.zone.cancelTask(Vo)},{once:!0})),et.target=null,Fc&&(Fc.taskData=null),Jd&&(Tn.once=!0),!il&&"boolean"==typeof Vo.options||(Vo.options=Tn),Vo.target=qt,Vo.capture=Zl,Vo.eventName=li,ir&&(Vo.originalDelegate=ur),dt?jo.unshift(Vo):jo.push(Vo),mt?qt:void 0}};return lt[be]=He(yi,Lt,F,ae,Pi),cn&&(lt[pt]=He(cn,Di,function(ge){return cn.call(et.target,et.eventName,ge.invoke,et.options)},ae,Pi,!0)),lt[ke]=function(){const ge=this||Z;let We=arguments[0];ct&&ct.transferEventName&&(We=ct.transferEventName(We));const wt=arguments[2],Xe=!!wt&&("boolean"==typeof wt||wt.capture),mt=arguments[1];if(!mt)return Pt.apply(this,arguments);if(sr&&!sr(Pt,mt,ge,arguments))return;const dt=Co[We];let qt;dt&&(qt=dt[Xe?Ts:Wi]);const li=qt&&ge[qt];if(li)for(let ur=0;urfunction(be,ke){be[Cb]=!0,pe&&pe.apply(be,ke)})}function xb(Z,se,ye,pe,be){const ke=Zone.__symbol__(pe);if(se[ke])return;const at=se[ke]=se[pe];se[pe]=function(tt,At,Lt){return At&&At.prototype&&be.forEach(function(pt){const Di=`${ye}.${pe}::`+pt,ni=At.prototype;try{if(ni.hasOwnProperty(pt)){const mi=Z.ObjectGetOwnPropertyDescriptor(ni,pt);mi&&mi.value?(mi.value=Z.wrapWithCurrentZone(mi.value,Di),Z._redefineProperty(At.prototype,pt,mi)):ni[pt]&&(ni[pt]=Z.wrapWithCurrentZone(ni[pt],Di))}else ni[pt]&&(ni[pt]=Z.wrapWithCurrentZone(ni[pt],Di))}catch{}}),at.call(se,tt,At,Lt)},Z.attachOriginToPatched(se[pe],at)}function Tb(Z,se,ye){if(!ye||0===ye.length)return se;const pe=ye.filter(ke=>ke.target===Z);if(!pe||0===pe.length)return se;const be=pe[0].ignoreProperties;return se.filter(ke=>-1===be.indexOf(ke))}function Eo(Z,se,ye,pe){Z&&fp(Z,Tb(Z,se,ye),pe)}function Zd(Z){return Object.getOwnPropertyNames(Z).filter(se=>se.startsWith("on")&&se.length>2).map(se=>se.substring(2))}Zone.__load_patch("util",(Z,se,ye)=>{const pe=Zd(Z);ye.patchOnProperties=fp,ye.patchMethod=tl,ye.bindArguments=Gd,ye.patchMacroTask=Ib;const be=se.__symbol__("BLACK_LISTED_EVENTS"),ke=se.__symbol__("UNPATCHED_EVENTS");Z[ke]&&(Z[be]=Z[ke]),Z[be]&&(se[be]=se[ke]=Z[be]),ye.patchEventPrototype=Cm,ye.patchEventTarget=Eb,ye.isIEOrEdge=Mb,ye.ObjectDefineProperty=Vd,ye.ObjectGetOwnPropertyDescriptor=Wl,ye.ObjectCreate=Yd,ye.ArraySlice=Sb,ye.patchClass=qd,ye.wrapWithCurrentZone=hp,ye.filterProperties=Tb,ye.attachOriginToPatched=Ia,ye._redefineProperty=Object.defineProperty,ye.patchCallbacks=xb,ye.getGlobalObjects=()=>({globalSources:wb,zoneSymbolEventNames:Co,eventNames:pe,isBrowser:Xd,isMix:up,isNode:Vh,TRUE_STR:Ts,FALSE_STR:Wi,ZONE_SYMBOL_PREFIX:Qd,ADD_EVENT_LISTENER_STR:mm,REMOVE_EVENT_LISTENER_STR:$r})});const As=Ji("zoneTask");function Xl(Z,se,ye,pe){let be=null,ke=null;ye+=pe;const at={};function tt(Lt){const pt=Lt.data;return pt.args[0]=function(){return Lt.invoke.apply(this,arguments)},pt.handleId=be.apply(Z,pt.args),Lt}function At(Lt){return ke.call(Z,Lt.data.handleId)}be=tl(Z,se+=pe,Lt=>function(pt,Di){if("function"==typeof Di[0]){const ni={isPeriodic:"Interval"===pe,delay:"Timeout"===pe||"Interval"===pe?Di[1]||0:void 0,args:Di},mi=Di[0];Di[0]=function(){try{return mi.apply(this,arguments)}finally{ni.isPeriodic||("number"==typeof ni.handleId?delete at[ni.handleId]:ni.handleId&&(ni.handleId[As]=null))}};const cr=ym(se,Di[0],ni,tt,At);if(!cr)return cr;const ki=cr.data.handleId;return"number"==typeof ki?at[ki]=cr:ki&&(ki[As]=cr),ki&&ki.ref&&ki.unref&&"function"==typeof ki.ref&&"function"==typeof ki.unref&&(cr.ref=ki.ref.bind(ki),cr.unref=ki.unref.bind(ki)),"number"==typeof ki||ki?ki:cr}return Lt.apply(Z,Di)}),ke=tl(Z,ye,Lt=>function(pt,Di){const ni=Di[0];let mi;"number"==typeof ni?mi=at[ni]:(mi=ni&&ni[As],mi||(mi=ni)),mi&&"string"==typeof mi.type?"notScheduled"!==mi.state&&(mi.cancelFn&&mi.data.isPeriodic||0===mi.runCount)&&("number"==typeof ni?delete at[ni]:ni&&(ni[As]=null),mi.zone.cancelTask(mi)):Lt.apply(Z,Di)})}Zone.__load_patch("legacy",Z=>{const se=Z[Zone.__symbol__("legacyPatch")];se&&se()}),Zone.__load_patch("timers",Z=>{const ye="clear";Xl(Z,"set",ye,"Timeout"),Xl(Z,"set",ye,"Interval"),Xl(Z,"set",ye,"Immediate")}),Zone.__load_patch("requestAnimationFrame",Z=>{Xl(Z,"request","cancel","AnimationFrame"),Xl(Z,"mozRequest","mozCancel","AnimationFrame"),Xl(Z,"webkitRequest","webkitCancel","AnimationFrame")}),Zone.__load_patch("blocking",(Z,se)=>{const ye=["alert","prompt","confirm"];for(let pe=0;pefunction(At,Lt){return se.current.run(ke,Z,Lt,tt)})}),Zone.__load_patch("EventTarget",(Z,se,ye)=>{(function ql(Z,se){se.patchEventPrototype(Z,se)})(Z,ye),function Dm(Z,se){if(Zone[se.symbol("patchEventTarget")])return;const{eventNames:ye,zoneSymbolEventNames:pe,TRUE_STR:be,FALSE_STR:ke,ZONE_SYMBOL_PREFIX:at}=se.getGlobalObjects();for(let At=0;At{qd("MutationObserver"),qd("WebKitMutationObserver")}),Zone.__load_patch("IntersectionObserver",(Z,se,ye)=>{qd("IntersectionObserver")}),Zone.__load_patch("FileReader",(Z,se,ye)=>{qd("FileReader")}),Zone.__load_patch("on_property",(Z,se,ye)=>{!function pp(Z,se){if(Vh&&!up||Zone[Z.symbol("patchEvents")])return;const ye=se.__Zone_ignore_on_properties;let pe=[];if(Xd){const be=window;pe=pe.concat(["Document","SVGElement","Element","HTMLElement","HTMLBodyElement","HTMLMediaElement","HTMLFrameSetElement","HTMLFrameElement","HTMLIFrameElement","HTMLMarqueeElement","Worker"]);const ke=function bm(){try{const Z=jh.navigator.userAgent;if(-1!==Z.indexOf("MSIE ")||-1!==Z.indexOf("Trident/"))return!0}catch{}return!1}()?[{target:be,ignoreProperties:["error"]}]:[];Eo(be,Zd(be),ye&&ye.concat(ke),Wd(be))}pe=pe.concat(["XMLHttpRequest","XMLHttpRequestEventTarget","IDBIndex","IDBRequest","IDBOpenDBRequest","IDBDatabase","IDBTransaction","IDBCursor","WebSocket"]);for(let be=0;be{!function Em(Z,se){const{isBrowser:ye,isMix:pe}=se.getGlobalObjects();(ye||pe)&&Z.customElements&&"customElements"in Z&&se.patchCallbacks(se,Z.customElements,"customElements","define",["connectedCallback","disconnectedCallback","adoptedCallback","attributeChangedCallback"])}(Z,ye)}),Zone.__load_patch("XHR",(Z,se)=>{!function At(Lt){const pt=Lt.XMLHttpRequest;if(!pt)return;const Di=pt.prototype;let mi=Di[Yl],cr=Di[_h];if(!mi){const et=Lt.XMLHttpRequestEventTarget;if(et){const yi=et.prototype;mi=yi[Yl],cr=yi[_h]}}const ki="readystatechange",is="scheduled";function Pr(et){const yi=et.data,Pt=yi.target;Pt[ke]=!1,Pt[tt]=!1;const rs=Pt[be];mi||(mi=Pt[Yl],cr=Pt[_h]),rs&&cr.call(Pt,ki,rs);const _o=Pt[be]=()=>{if(Pt.readyState===Pt.DONE)if(!yi.aborted&&Pt[ke]&&et.state===is){const Ur=Pt[se.__symbol__("loadfalse")];if(0!==Pt.status&&Ur&&Ur.length>0){const Do=et.invoke;et.invoke=function(){const Ls=Pt[se.__symbol__("loadfalse")];for(let jr=0;jrfunction(et,yi){return et[pe]=0==yi[2],et[at]=yi[1],jn.apply(et,yi)}),Zr=Ji("fetchTaskAborting"),Pi=Ji("fetchTaskScheduling"),lt=tl(Di,"send",()=>function(et,yi){if(!0===se.current[Pi]||et[pe])return lt.apply(et,yi);{const Pt={target:et,url:et[at],isPeriodic:!1,args:yi,aborted:!1},rs=ym("XMLHttpRequest.send",Wt,Pt,Pr,ct);et&&!0===et[tt]&&!Pt.aborted&&rs.state===is&&rs.invoke()}}),dr=tl(Di,"abort",()=>function(et,yi){const Pt=function ni(et){return et[ye]}(et);if(Pt&&"string"==typeof Pt.type){if(null==Pt.cancelFn||Pt.data&&Pt.data.aborted)return;Pt.zone.cancelTask(Pt)}else if(!0===se.current[Zr])return dr.apply(et,yi)})}(Z);const ye=Ji("xhrTask"),pe=Ji("xhrSync"),be=Ji("xhrListener"),ke=Ji("xhrScheduled"),at=Ji("xhrURL"),tt=Ji("xhrErrorBeforeScheduled")}),Zone.__load_patch("geolocation",Z=>{Z.navigator&&Z.navigator.geolocation&&function Im(Z,se){const ye=Z.constructor.name;for(let pe=0;pe{const At=function(){return tt.apply(this,Gd(arguments,ye+"."+be))};return Ia(At,tt),At})(ke)}}}(Z.navigator.geolocation,["getCurrentPosition","watchPosition"])}),Zone.__load_patch("PromiseRejectionEvent",(Z,se)=>{function ye(pe){return function(be){Db(Z,pe).forEach(at=>{const tt=Z.PromiseRejectionEvent;if(tt){const At=new tt(pe,{promise:be.promise,reason:be.rejection});at.invoke(At)}})}}Z.PromiseRejectionEvent&&(se[Ji("unhandledPromiseRejectionHandler")]=ye("unhandledrejection"),se[Ji("rejectionHandledHandler")]=ye("rejectionhandled"))}),Zone.__load_patch("queueMicrotask",(Z,se,ye)=>{!function gp(Z,se){se.patchMethod(Z,"queueMicrotask",ye=>function(pe,be){Zone.current.scheduleMicroTask("queueMicrotask",be[0])})}(Z,ye)})}},Wl=>{Wl(Wl.s=51)}]); \ No newline at end of file diff --git a/ej2-angular/samples/diagram/nodes/node-expandAndCollapse-cs1/index.html b/ej2-angular/samples/diagram/nodes/node-expandAndCollapse-cs1/index.html index 41a6252c14..eda19c55ee 100644 --- a/ej2-angular/samples/diagram/nodes/node-expandAndCollapse-cs1/index.html +++ b/ej2-angular/samples/diagram/nodes/node-expandAndCollapse-cs1/index.html @@ -19,5 +19,5 @@
Loading....
- + \ No newline at end of file diff --git a/ej2-angular/samples/diagram/nodes/node-expandAndCollapse-cs1/main.4c4feb775a3c1aa7.js b/ej2-angular/samples/diagram/nodes/node-expandAndCollapse-cs1/main.4c4feb775a3c1aa7.js new file mode 100644 index 0000000000..2276fc1f23 --- /dev/null +++ b/ej2-angular/samples/diagram/nodes/node-expandAndCollapse-cs1/main.4c4feb775a3c1aa7.js @@ -0,0 +1 @@ +"use strict";(self.webpackChunksyncfusion_component=self.webpackChunksyncfusion_component||[]).push([[179],{51:(Wl,Ud,jd)=>{let $r=null,_h=1;const Ts=Symbol("SIGNAL");function Wi(n){const t=$r;return $r=n,t}function gn(n){if((!Wh(n)||n.dirty)&&(n.dirty||n.lastCleanEpoch!==_h)){if(!n.producerMustRecompute(n)&&!Vh(n))return n.dirty=!1,void(n.lastCleanEpoch=_h);n.producerRecomputeValue(n),n.dirty=!1,n.lastCleanEpoch=_h}}function Vh(n){Gl(n);for(let t=0;t0}function Gl(n){n.producerNode??=[],n.producerIndexOfThis??=[],n.producerLastReadVersion??=[]}let Xd=null;function Eo(n){return"function"==typeof n}function qd(n){const e=n(i=>{Error.call(i),i.stack=(new Error).stack});return e.prototype=Object.create(Error.prototype),e.prototype.constructor=e,e}const dp=qd(n=>function(e){n(this),this.message=e?`${e.length} errors occurred during unsubscription:\n${e.map((i,r)=>`${r+1}) ${i.toString()}`).join("\n ")}`:"",this.name="UnsubscriptionError",this.errors=e});function up(n,t){if(n){const e=n.indexOf(t);0<=e&&n.splice(e,1)}}class As{constructor(t){this.initialTeardown=t,this.closed=!1,this._parentage=null,this._finalizers=null}unsubscribe(){let t;if(!this.closed){this.closed=!0;const{_parentage:e}=this;if(e)if(this._parentage=null,Array.isArray(e))for(const s of e)s.remove(this);else e.remove(this);const{initialTeardown:i}=this;if(Eo(i))try{i()}catch(s){t=s instanceof dp?s.errors:[s]}const{_finalizers:r}=this;if(r){this._finalizers=null;for(const s of r)try{bm(s)}catch(o){t=t??[],o instanceof dp?t=[...t,...o.errors]:t.push(o)}}if(t)throw new dp(t)}}add(t){var e;if(t&&t!==this)if(this.closed)bm(t);else{if(t instanceof As){if(t.closed||t._hasParent(this))return;t._addParent(this)}(this._finalizers=null!==(e=this._finalizers)&&void 0!==e?e:[]).push(t)}}_hasParent(t){const{_parentage:e}=this;return e===t||Array.isArray(e)&&e.includes(t)}_addParent(t){const{_parentage:e}=this;this._parentage=Array.isArray(e)?(e.push(t),e):e?[e,t]:t}_removeParent(t){const{_parentage:e}=this;e===t?this._parentage=null:Array.isArray(e)&&up(e,t)}remove(t){const{_finalizers:e}=this;e&&up(e,t),t instanceof As&&t._removeParent(this)}}As.EMPTY=(()=>{const n=new As;return n.closed=!0,n})();const Xl=As.EMPTY;function Im(n){return n instanceof As||n&&"closed"in n&&Eo(n.remove)&&Eo(n.add)&&Eo(n.unsubscribe)}function bm(n){Eo(n)?n():n.unsubscribe()}const ql={onUnhandledError:null,onStoppedNotification:null,Promise:void 0,useDeprecatedSynchronousErrorHandling:!1,useDeprecatedNextContext:!1},Z={setTimeout(n,t,...e){const{delegate:i}=Z;return i?.setTimeout?i.setTimeout(n,t,...e):setTimeout(n,t,...e)},clearTimeout(n){const{delegate:t}=Z;return(t?.clearTimeout||clearTimeout)(n)},delegate:void 0};function ye(){}const pe=at("C",void 0,void 0);function at(n,t,e){return{kind:n,value:t,error:e}}let it=null;function At(n){if(ql.useDeprecatedSynchronousErrorHandling){const t=!it;if(t&&(it={errorThrown:!1,error:null}),n(),t){const{errorThrown:e,error:i}=it;if(it=null,e)throw i}}else n()}class pt extends As{constructor(t){super(),this.isStopped=!1,t?(this.destination=t,Im(t)&&t.add(this)):this.destination=Wt}static create(t,e,i){return new dr(t,e,i)}next(t){this.isStopped?Pr(function ke(n){return at("N",n,void 0)}(t),this):this._next(t)}error(t){this.isStopped?Pr(function be(n){return at("E",void 0,n)}(t),this):(this.isStopped=!0,this._error(t))}complete(){this.isStopped?Pr(pe,this):(this.isStopped=!0,this._complete())}unsubscribe(){this.closed||(this.isStopped=!0,super.unsubscribe(),this.destination=null)}_next(t){this.destination.next(t)}_error(t){try{this.destination.error(t)}finally{this.unsubscribe()}}_complete(){try{this.destination.complete()}finally{this.unsubscribe()}}}const Di=Function.prototype.bind;function ni(n,t){return Di.call(n,t)}class mi{constructor(t){this.partialObserver=t}next(t){const{partialObserver:e}=this;if(e.next)try{e.next(t)}catch(i){ki(i)}}error(t){const{partialObserver:e}=this;if(e.error)try{e.error(t)}catch(i){ki(i)}else ki(t)}complete(){const{partialObserver:t}=this;if(t.complete)try{t.complete()}catch(e){ki(e)}}}class dr extends pt{constructor(t,e,i){let r;if(super(),Eo(t)||!t)r={next:t??void 0,error:e??void 0,complete:i??void 0};else{let s;this&&ql.useDeprecatedNextContext?(s=Object.create(t),s.unsubscribe=()=>this.unsubscribe(),r={next:t.next&&ni(t.next,s),error:t.error&&ni(t.error,s),complete:t.complete&&ni(t.complete,s)}):r=t}this.destination=new mi(r)}}function ki(n){ql.useDeprecatedSynchronousErrorHandling?function Lt(n){ql.useDeprecatedSynchronousErrorHandling&&it&&(it.errorThrown=!0,it.error=n)}(n):function se(n){Z.setTimeout(()=>{const{onUnhandledError:t}=ql;if(!t)throw n;t(n)})}(n)}function Pr(n,t){const{onStoppedNotification:e}=ql;e&&Z.setTimeout(()=>e(n,t))}const Wt={closed:!0,next:ye,error:function is(n){throw n},complete:ye},ct="function"==typeof Symbol&&Symbol.observable||"@@observable";function jn(n){return n}let Pi=(()=>{class n{constructor(e){e&&(this._subscribe=e)}lift(e){const i=new n;return i.source=this,i.operator=e,i}subscribe(e,i,r){const s=function et(n){return n&&n instanceof pt||function ur(n){return n&&Eo(n.next)&&Eo(n.error)&&Eo(n.complete)}(n)&&Im(n)}(e)?e:new dr(e,i,r);return At(()=>{const{operator:o,source:a}=this;s.add(o?o.call(s,a):a?this._subscribe(s):this._trySubscribe(s))}),s}_trySubscribe(e){try{return this._subscribe(e)}catch(i){e.error(i)}}forEach(e,i){return new(i=lt(i))((r,s)=>{const o=new dr({next:a=>{try{e(a)}catch(l){s(l),o.unsubscribe()}},error:s,complete:r});this.subscribe(o)})}_subscribe(e){var i;return null===(i=this.source)||void 0===i?void 0:i.subscribe(e)}[ct](){return this}pipe(...e){return function Zr(n){return 0===n.length?jn:1===n.length?n[0]:function(e){return n.reduce((i,r)=>r(i),e)}}(e)(this)}toPromise(e){return new(e=lt(e))((i,r)=>{let s;this.subscribe(o=>s=o,o=>r(o),()=>i(s))})}}return n.create=t=>new n(t),n})();function lt(n){var t;return null!==(t=n??ql.Promise)&&void 0!==t?t:Promise}const yi=qd(n=>function(){n(this),this.name="ObjectUnsubscribedError",this.message="object unsubscribed"});let Pt=(()=>{class n extends Pi{constructor(){super(),this.closed=!1,this.currentObservers=null,this.observers=[],this.isStopped=!1,this.hasError=!1,this.thrownError=null}lift(e){const i=new rs(this,this);return i.operator=e,i}_throwIfClosed(){if(this.closed)throw new yi}next(e){At(()=>{if(this._throwIfClosed(),!this.isStopped){this.currentObservers||(this.currentObservers=Array.from(this.observers));for(const i of this.currentObservers)i.next(e)}})}error(e){At(()=>{if(this._throwIfClosed(),!this.isStopped){this.hasError=this.isStopped=!0,this.thrownError=e;const{observers:i}=this;for(;i.length;)i.shift().error(e)}})}complete(){At(()=>{if(this._throwIfClosed(),!this.isStopped){this.isStopped=!0;const{observers:e}=this;for(;e.length;)e.shift().complete()}})}unsubscribe(){this.isStopped=this.closed=!0,this.observers=this.currentObservers=null}get observed(){var e;return(null===(e=this.observers)||void 0===e?void 0:e.length)>0}_trySubscribe(e){return this._throwIfClosed(),super._trySubscribe(e)}_subscribe(e){return this._throwIfClosed(),this._checkFinalizedStatuses(e),this._innerSubscribe(e)}_innerSubscribe(e){const{hasError:i,isStopped:r,observers:s}=this;return i||r?Xl:(this.currentObservers=null,s.push(e),new As(()=>{this.currentObservers=null,up(s,e)}))}_checkFinalizedStatuses(e){const{hasError:i,thrownError:r,isStopped:s}=this;i?e.error(r):s&&e.complete()}asObservable(){const e=new Pi;return e.source=this,e}}return n.create=(t,e)=>new rs(t,e),n})();class rs extends Pt{constructor(t,e){super(),this.destination=t,this.source=e}next(t){var e,i;null===(i=null===(e=this.destination)||void 0===e?void 0:e.next)||void 0===i||i.call(e,t)}error(t){var e,i;null===(i=null===(e=this.destination)||void 0===e?void 0:e.error)||void 0===i||i.call(e,t)}complete(){var t,e;null===(e=null===(t=this.destination)||void 0===t?void 0:t.complete)||void 0===e||e.call(t)}_subscribe(t){var e,i;return null!==(i=null===(e=this.source)||void 0===e?void 0:e.subscribe(t))&&void 0!==i?i:Xl}}class _o extends Pt{constructor(t){super(),this._value=t}get value(){return this.getValue()}_subscribe(t){const e=super._subscribe(t);return!e.closed&&t.next(this._value),e}getValue(){const{hasError:t,thrownError:e,_value:i}=this;if(t)throw e;return this._throwIfClosed(),i}next(t){super.next(this._value=t)}}class Ls extends pt{constructor(t,e,i,r,s,o){super(t),this.onFinalize=s,this.shouldUnsubscribe=o,this._next=e?function(a){try{e(a)}catch(l){t.error(l)}}:super._next,this._error=r?function(a){try{r(a)}catch(l){t.error(l)}finally{this.unsubscribe()}}:super._error,this._complete=i?function(){try{i()}catch(a){t.error(a)}finally{this.unsubscribe()}}:super._complete}unsubscribe(){var t;if(!this.shouldUnsubscribe||this.shouldUnsubscribe()){const{closed:e}=this;super.unsubscribe(),!e&&(null===(t=this.onFinalize)||void 0===t||t.call(this))}}}function jr(n,t){return function Ur(n){return t=>{if(function cn(n){return Eo(n?.lift)}(t))return t.lift(function(e){try{return n(e,this)}catch(i){this.error(i)}});throw new TypeError("Unable to lift unknown Observable type")}}((e,i)=>{let r=0;e.subscribe(function Do(n,t,e,i,r){return new Ls(n,t,e,i,r)}(i,s=>{i.next(n.call(t,s,r++))}))})}class F extends Error{constructor(t,e){super(function ae(n,t){return`NG0${Math.abs(n)}${t?": "+t:""}`}(t,e)),this.code=t}}function Xe(n){for(let t in n)if(n[t]===Xe)return t;throw Error("Could not find renamed property on target object.")}function mt(n,t){for(const e in t)t.hasOwnProperty(e)&&!n.hasOwnProperty(e)&&(n[e]=t[e])}function dt(n){if("string"==typeof n)return n;if(Array.isArray(n))return"["+n.map(dt).join(", ")+"]";if(null==n)return""+n;if(n.overriddenName)return`${n.overriddenName}`;if(n.name)return`${n.name}`;const t=n.toString();if(null==t)return""+t;const e=t.indexOf("\n");return-1===e?t:t.substring(0,e)}function qt(n,t){return null==n||""===n?null===t?"":t:null==t||""===t?n:n+" "+t}const fr=Xe({__forward_ref__:Xe});function ir(n){return n.__forward_ref__=ir,n.toString=function(){return dt(this())},n}function vt(n){return function Tn(n){return"function"==typeof n&&n.hasOwnProperty(fr)&&n.__forward_ref__===ir}(n)?n():n}function $l(n){return n&&!!n.\u0275providers}const Zl=Xe({\u0275cmp:Xe}),$d=Xe({\u0275dir:Xe}),fp=Xe({\u0275pipe:Xe}),Uo=Xe({\u0275fac:Xe}),jo=Xe({__NG_ELEMENT_ID__:Xe}),pp=Xe({__NG_ENV_ID__:Xe});function Ri(n){return"function"==typeof n?n.name||n.toString():"object"==typeof n&&null!=n&&"function"==typeof n.type?n.type.name||n.type.toString():function Nt(n){return"string"==typeof n?n:null==n?"":String(n)}(n)}function Eb(n,t){throw new F(-201,!1)}function so(n,t){null==n&&function zt(n,t,e,i){throw new Error(`ASSERTION ERROR: ${n}`+(null==i?"":` [Expected=> ${e} ${i} ${t} <=Actual]`))}(t,n,null,"!=")}function Yi(n){return{token:n.token,providedIn:n.providedIn||null,factory:n.factory,value:void 0}}function gp(n){return{providers:n.providers||[],imports:n.imports||[]}}function Mm(n){return kT(n,Cm)||kT(n,PT)}function kT(n,t){return n.hasOwnProperty(t)?n[t]:null}function wm(n){return n&&(n.hasOwnProperty(Db)||n.hasOwnProperty(b_))?n[Db]:null}const Cm=Xe({\u0275prov:Xe}),Db=Xe({\u0275inj:Xe}),PT=Xe({ngInjectableDef:Xe}),b_=Xe({ngInjectorDef:Xe});var xi=function(n){return n[n.Default=0]="Default",n[n.Host=1]="Host",n[n.Self=2]="Self",n[n.SkipSelf=4]="SkipSelf",n[n.Optional=8]="Optional",n}(xi||{});let xb;function oo(n){const t=xb;return xb=n,t}function RT(n,t,e){const i=Mm(n);return i&&"root"==i.providedIn?void 0===i.value?i.value=i.factory():i.value:e&xi.Optional?null:void 0!==t?t:void Eb()}const rr=globalThis;class Bt{constructor(t,e){this._desc=t,this.ngMetadataName="InjectionToken",this.\u0275prov=void 0,"number"==typeof e?this.__NG_ELEMENT_ID__=e:void 0!==e&&(this.\u0275prov=Yi({token:this,providedIn:e.providedIn||"root",factory:e.factory}))}get multi(){return this}toString(){return`InjectionToken ${this._desc}`}}const vp={},Ob="__NG_DI_FLAG__",Em="ngTempTokenPath",C_=/\n/gm,BT="__source";let Jd;function Gh(n){const t=Jd;return Jd=n,t}function x_(n,t=xi.Default){if(void 0===Jd)throw new F(-203,!1);return null===Jd?RT(n,void 0,t):Jd.get(n,t&xi.Optional?null:void 0,t)}function _i(n,t=xi.Default){return(function zT(){return xb}()||x_)(vt(n),t)}function Hi(n,t=xi.Default){return _i(n,Dm(t))}function Dm(n){return typeof n>"u"||"number"==typeof n?n:0|(n.optional&&8)|(n.host&&1)|(n.self&&2)|(n.skipSelf&&4)}function kb(n){const t=[];for(let e=0;et){o=s-1;break}}}for(;ss?"":r[d+1].toLowerCase();const f=8&i?u:null;if(f&&-1!==_T(f,h,0)||2&i&&h!==u){if(Ma(i))return!1;o=!0}}}}else{if(!o&&!Ma(i)&&!Ma(l))return!1;if(o&&Ma(l))continue;o=!1,i=l|1&i}}return Ma(i)||o}function Ma(n){return 0==(1&n)}function P_(n,t,e,i){if(null===t)return-1;let r=0;if(i||!e){let s=!1;for(;r-1)for(e++;e0?'="'+a+'"':"")+"]"}else 8&i?r+="."+o:4&i&&(r+=" "+o);else""!==r&&!Ma(o)&&(t+=GT(s,r),r=""),i=o,s=s||!Ma(i);e++}return""!==r&&(t+=GT(s,r)),t}function zb(n){return Jl(()=>{const t=qT(n),e={...t,decls:n.decls,vars:n.vars,template:n.template,consts:n.consts||null,ngContentSelectors:n.ngContentSelectors,onPush:n.changeDetection===xm.OnPush,directiveDefs:null,pipeDefs:null,dependencies:t.standalone&&n.dependencies||null,getStandaloneInjector:null,signals:n.signals??!1,data:n.data||{},encapsulation:n.encapsulation||ba.Emulated,styles:n.styles||Qi,_:null,schemas:n.schemas||null,tView:null,id:""};$T(e);const i=n.dependencies;return e.directiveDefs=Am(i,!1),e.pipeDefs=Am(i,!0),e.id=function Y_(n){let t=0;const e=[n.selectors,n.ngContentSelectors,n.hostVars,n.hostAttrs,n.consts,n.vars,n.decls,n.encapsulation,n.standalone,n.signals,n.exportAs,JSON.stringify(n.inputs),JSON.stringify(n.outputs),Object.getOwnPropertyNames(n.type.prototype),!!n.contentQueries,!!n.viewQuery].join("|");for(const r of e)t=Math.imul(31,t)+r.charCodeAt(0)<<0;return t+=2147483648,"c"+t}(e),e})}function j_(n){return di(n)||Wn(n)}function V_(n){return null!==n}function Tm(n){return Jl(()=>({type:n.type,bootstrap:n.bootstrap||Qi,declarations:n.declarations||Qi,imports:n.imports||Qi,exports:n.exports||Qi,transitiveCompileScopes:null,schemas:n.schemas||null,id:n.id||null}))}function XT(n,t){if(null==n)return rl;const e={};for(const i in n)if(n.hasOwnProperty(i)){const r=n[i];let s,o,a=Xh.None;Array.isArray(r)?(a=r[0],s=r[1],o=r[2]??s):(s=r,o=r),t?(e[s]=a!==Xh.None?[i,a]:i,t[s]=o):e[s]=i}return e}function nr(n){return Jl(()=>{const t=qT(n);return $T(t),t})}function di(n){return n[Zl]||null}function Wn(n){return n[$d]||null}function gs(n){return n[fp]||null}function qT(n){const t={};return{type:n.type,providersResolver:null,factory:null,hostBindings:n.hostBindings||null,hostVars:n.hostVars||0,hostAttrs:n.hostAttrs||null,contentQueries:n.contentQueries||null,declaredInputs:t,inputTransforms:null,inputConfig:n.inputs||rl,exportAs:n.exportAs||null,standalone:!0===n.standalone,signals:!0===n.signals,selectors:n.selectors||Qi,viewQuery:n.viewQuery||null,features:n.features||null,setInput:null,findHostDirectiveDefs:null,hostDirectives:null,inputs:XT(n.inputs,t),outputs:XT(n.outputs),debugInfo:null}}function $T(n){n.features?.forEach(t=>t(n))}function Am(n,t){if(!n)return null;const e=t?gs:j_;return()=>("function"==typeof n?n():n).map(i=>e(i)).filter(V_)}const Vr=0,Be=1,Ct=2,vn=3,wa=4,Os=5,Ca=6,Kd=7,Er=8,Xs=9,Kl=10,Yt=11,Sp=12,ZT=13,eu=14,Jr=15,Ip=16,tu=17,nl=18,bp=19,JT=20,qh=21,Lm=22,Uc=23,jt=25,Rb=1,sl=7,iu=9,mn=10;var Hb=function(n){return n[n.None=0]="None",n[n.HasTransplantedViews=2]="HasTransplantedViews",n}(Hb||{});function ks(n){return Array.isArray(n)&&"object"==typeof n[Rb]}function Ps(n){return Array.isArray(n)&&!0===n[Rb]}function Bb(n){return 0!=(4&n.flags)}function jc(n){return n.componentOffset>-1}function Ea(n){return!!n.template}function Fb(n){return 0!=(512&n[Ct])}function Vc(n,t){return n.hasOwnProperty(Uo)?n[Uo]:null}class q_{constructor(t,e,i){this.previousValue=t,this.currentValue=e,this.firstChange=i}isFirstChange(){return this.firstChange}}function iA(n,t,e,i){null!==t?t.applyValueToInputSignal(t,i):n[e]=i}function rA(n){return n.type.prototype.ngOnChanges&&(n.setInput=Z_),$_}function $_(){const n=sA(this),t=n?.current;if(t){const e=n.previous;if(e===rl)n.previous=t;else for(let i in t)e[i]=t[i];n.current=null,this.ngOnChanges(t)}}function Z_(n,t,e,i,r){const s=this.declaredInputs[i],o=sA(n)||function J_(n,t){return n[nA]=t}(n,{previous:rl,current:null}),a=o.current||(o.current={}),l=o.previous,h=l[s];a[s]=new q_(h&&h.currentValue,e,l===rl),iA(n,t,r,e)}const nA="__ngSimpleChanges__";function sA(n){return n[nA]||null}const ol=function(n,t,e){};let lA=!1;function pr(n){for(;Array.isArray(n);)n=n[Vr];return n}function qs(n,t){return pr(t[n.index])}function Cp(n,t){return n.data[t]}function To(n,t){const e=t[n];return ks(e)?e:e[Vr]}function Wb(n){return 128==(128&n[Ct])}function al(n,t){return null==t?null:n[t]}function hA(n){n[tu]=0}function nU(n){1024&n[Ct]||(n[Ct]|=1024,Wb(n)&&Ep(n))}function dA(n){return 9216&n[Ct]||n[Uc]?.dirty}function Yb(n){dA(n)?Ep(n):64&n[Ct]&&(function eU(){return lA}()?(n[Ct]|=1024,Ep(n)):n[Kl].changeDetectionScheduler?.notify())}function Ep(n){n[Kl].changeDetectionScheduler?.notify();let t=Wc(n);for(;null!==t&&!(8192&t[Ct])&&(t[Ct]|=8192,Wb(t));)t=Wc(t)}function Wc(n){const t=n[vn];return Ps(t)?t[vn]:t}const Rt={lFrame:bA(null),bindingsEnabled:!0,skipHydrationRootTNode:null};function fA(){return Rt.bindingsEnabled}function Se(){return Rt.lFrame.lView}function Ti(){return Rt.lFrame.tView}function gr(){let n=pA();for(;null!==n&&64===n.type;)n=n.parent;return n}function pA(){return Rt.lFrame.currentTNode}function ll(n,t){const e=Rt.lFrame;e.currentTNode=n,e.isParent=t}function Gb(){return Rt.lFrame.isParent}function mU(n,t){const e=Rt.lFrame;e.bindingIndex=e.bindingRootIndex=n,qb(t)}function qb(n){Rt.lFrame.currentDirectiveIndex=n}function yA(){return Rt.lFrame.currentQueryIndex}function Zb(n){Rt.lFrame.currentQueryIndex=n}function SU(n){const t=n[Be];return 2===t.type?t.declTNode:1===t.type?n[Os]:null}function SA(n,t,e){if(e&xi.SkipSelf){let r=t,s=n;for(;!(r=r.parent,null!==r||e&xi.Host||(r=SU(s),null===r||(s=s[eu],10&r.type))););if(null===r)return!1;t=r,n=s}const i=Rt.lFrame=IA();return i.currentTNode=t,i.lView=n,!0}function Jb(n){const t=IA(),e=n[Be];Rt.lFrame=t,t.currentTNode=e.firstChild,t.lView=n,t.tView=e,t.contextLView=n,t.bindingIndex=e.bindingStartIndex,t.inI18n=!1}function IA(){const n=Rt.lFrame,t=null===n?null:n.child;return null===t?bA(n):t}function bA(n){const t={currentTNode:null,isParent:!0,lView:null,tView:null,selectedIndex:-1,contextLView:null,elementDepthCount:0,currentNamespace:null,currentDirectiveIndex:-1,bindingRootIndex:-1,bindingIndex:-1,currentQueryIndex:0,parent:n,child:null,inI18n:!1};return null!==n&&(n.child=t),t}function MA(){const n=Rt.lFrame;return Rt.lFrame=n.parent,n.currentTNode=null,n.lView=null,n}const wA=MA;function Kb(){const n=MA();n.isParent=!0,n.tView=null,n.selectedIndex=-1,n.contextLView=null,n.elementDepthCount=0,n.currentDirectiveIndex=-1,n.currentNamespace=null,n.bindingRootIndex=-1,n.bindingIndex=-1,n.currentQueryIndex=0}function Yc(n){Rt.lFrame.selectedIndex=n}let EA=!0;function Rm(n,t){for(let e=t.directiveStart,i=t.directiveEnd;e=i)break}else t[l]<0&&(n[tu]+=65536),(a>14>16&&(3&n[Ct])===t&&(n[Ct]+=16384,xA(a,s)):xA(a,s)}const su=-1;class xp{constructor(t,e,i){this.factory=t,this.resolving=!1,this.canSeeViewProviders=e,this.injectImpl=i}}function i1(n){return n!==su}function Tp(n){return 32767&n}function Ap(n,t){let e=function NU(n){return n>>16}(n),i=t;for(;e>0;)i=i[eu],e--;return i}let r1=!0;function Fm(n){const t=r1;return r1=n,t}const TA=255,AA=5;let OU=0;const cl={};function _m(n,t){const e=LA(n,t);if(-1!==e)return e;const i=t[Be];i.firstCreatePass&&(n.injectorIndex=t.length,n1(i.data,n),n1(t,null),n1(i.blueprint,null));const r=Um(n,t),s=n.injectorIndex;if(i1(r)){const o=Tp(r),a=Ap(r,t),l=a[Be].data;for(let h=0;h<8;h++)t[s+h]=a[o+h]|l[o+h]}return t[s+8]=r,s}function n1(n,t){n.push(0,0,0,0,0,0,0,0,t)}function LA(n,t){return-1===n.injectorIndex||n.parent&&n.parent.injectorIndex===n.injectorIndex||null===t[n.injectorIndex+8]?-1:n.injectorIndex}function Um(n,t){if(n.parent&&-1!==n.parent.injectorIndex)return n.parent.injectorIndex;let e=0,i=null,r=t;for(;null!==r;){if(i=HA(r),null===i)return su;if(e++,r=r[eu],-1!==i.injectorIndex)return i.injectorIndex|e<<16}return su}function s1(n,t,e){!function kU(n,t,e){let i;"string"==typeof e?i=e.charCodeAt(0)||0:e.hasOwnProperty(jo)&&(i=e[jo]),null==i&&(i=e[jo]=OU++);const r=i&TA;t.data[n+(r>>AA)]|=1<=0?t&TA:HU:t}(e);if("function"==typeof s){if(!SA(t,n,i))return i&xi.Host?NA(r,0,i):OA(t,e,i,r);try{let o;if(o=s(i),null!=o||i&xi.Optional)return o;Eb()}finally{wA()}}else if("number"==typeof s){let o=null,a=LA(n,t),l=su,h=i&xi.Host?t[Jr][Os]:null;for((-1===a||i&xi.SkipSelf)&&(l=-1===a?Um(n,t):t[a+8],l!==su&&RA(i,!1)?(o=t[Be],a=Tp(l),t=Ap(l,t)):a=-1);-1!==a;){const c=t[Be];if(zA(s,a,c.data)){const d=zU(a,t,e,o,i,h);if(d!==cl)return d}l=t[a+8],l!==su&&RA(i,t[Be].data[a+8]===h)&&zA(s,a,t)?(o=c,a=Tp(l),t=Ap(l,t)):a=-1}}return r}function zU(n,t,e,i,r,s){const o=t[Be],a=o.data[n+8],c=jm(a,o,e,null==i?jc(a)&&r1:i!=o&&0!=(3&a.type),r&xi.Host&&s===a);return null!==c?Qc(t,o,c,a):cl}function jm(n,t,e,i,r){const s=n.providerIndexes,o=t.data,a=1048575&s,l=n.directiveStart,c=s>>20,u=r?a+c:n.directiveEnd;for(let f=i?a:a+c;f=l&&p.type===e)return f}if(r){const f=o[l];if(f&&Ea(f)&&f.type===e)return l}return null}function Qc(n,t,e,i){let r=n[e];const s=t.data;if(function xU(n){return n instanceof xp}(r)){const o=r;o.resolving&&function Vo(n,t){const e=t?`. Dependency path: ${t.join(" > ")} > ${n}`:"";throw new F(-200,`Circular dependency in DI detected for ${n}${e}`)}(Ri(s[e]));const a=Fm(o.canSeeViewProviders);o.resolving=!0;const h=o.injectImpl?oo(o.injectImpl):null;SA(n,i,xi.Default);try{r=n[e]=o.factory(void 0,s,n,i),t.firstCreatePass&&e>=i.directiveStart&&function EU(n,t,e){const{ngOnChanges:i,ngOnInit:r,ngDoCheck:s}=t.type.prototype;if(i){const o=rA(t);(e.preOrderHooks??=[]).push(n,o),(e.preOrderCheckHooks??=[]).push(n,o)}r&&(e.preOrderHooks??=[]).push(0-n,r),s&&((e.preOrderHooks??=[]).push(n,s),(e.preOrderCheckHooks??=[]).push(n,s))}(e,s[e],t)}finally{null!==h&&oo(h),Fm(a),o.resolving=!1,wA()}}return r}function zA(n,t,e){return!!(e[t+(n>>AA)]&1<Array.isArray(e)?fu(e,t):t(e))}function FA(n,t,e){t>=n.length?n.push(e):n.splice(t,0,e)}function Vm(n,t){return t>=n.length-1?n.pop():n.splice(t,1)[0]}const vu=new Bt(""),YA=new Bt("",-1),g1=new Bt("");class Gm{get(t,e=vp){if(e===vp){const i=new Error(`NullInjectorError: No provider for ${dt(t)}!`);throw i.name="NullInjectorError",i}return e}}function aj(...n){return{\u0275providers:QA(0,n),\u0275fromNgModule:!0}}function QA(n,...t){const e=[],i=new Set;let r;const s=o=>{e.push(o)};return fu(t,o=>{const a=o;Xm(a,s,[],i)&&(r||=[],r.push(a))}),void 0!==r&&GA(r,s),e}function GA(n,t){for(let e=0;e{t(s,i)})}}function Xm(n,t,e,i){if(!(n=vt(n)))return!1;let r=null,s=wm(n);const o=!s&&di(n);if(s||o){if(o&&!o.standalone)return!1;r=n}else{const l=n.ngModule;if(s=wm(l),!s)return!1;r=l}const a=i.has(r);if(o){if(a)return!1;if(i.add(r),o.dependencies){const l="function"==typeof o.dependencies?o.dependencies():o.dependencies;for(const h of l)Xm(h,t,e,i)}}else{if(!s)return!1;{if(null!=s.imports&&!a){let h;i.add(r);try{fu(s.imports,c=>{Xm(c,t,e,i)&&(h||=[],h.push(c))})}finally{}void 0!==h&&GA(h,t)}if(!a){const h=Vc(r)||(()=>new r);t({provide:r,useFactory:h,deps:Qi},r),t({provide:g1,useValue:r,multi:!0},r),t({provide:vu,useValue:()=>_i(r),multi:!0},r)}const l=s.providers;if(null!=l&&!a){const h=n;m1(l,c=>{t(c,h)})}}}return r!==n&&void 0!==n.providers}function m1(n,t){for(let e of n)$l(e)&&(e=e.\u0275providers),Array.isArray(e)?m1(e,t):t(e)}const lj=Xe({provide:String,useValue:Xe});function y1(n){return null!==n&&"object"==typeof n&&lj in n}function Gc(n){return"function"==typeof n}const S1=new Bt(""),qm={},cj={};let I1;function $m(){return void 0===I1&&(I1=new Gm),I1}class ih{}class mu extends ih{get destroyed(){return this._destroyed}constructor(t,e,i,r){super(),this.parent=e,this.source=i,this.scopes=r,this.records=new Map,this._ngOnDestroyHooks=new Set,this._onDestroyHooks=[],this._destroyed=!1,M1(t,o=>this.processProvider(o)),this.records.set(YA,yu(void 0,this)),r.has("environment")&&this.records.set(ih,yu(void 0,this));const s=this.records.get(S1);null!=s&&"string"==typeof s.value&&this.scopes.add(s.value),this.injectorDefTypes=new Set(this.get(g1,Qi,xi.Self))}destroy(){this.assertNotDestroyed(),this._destroyed=!0;try{for(const e of this._ngOnDestroyHooks)e.ngOnDestroy();const t=this._onDestroyHooks;this._onDestroyHooks=[];for(const e of t)e()}finally{this.records.clear(),this._ngOnDestroyHooks.clear(),this.injectorDefTypes.clear()}}onDestroy(t){return this.assertNotDestroyed(),this._onDestroyHooks.push(t),()=>this.removeOnDestroy(t)}runInContext(t){this.assertNotDestroyed();const e=Gh(this),i=oo(void 0);try{return t()}finally{Gh(e),oo(i)}}get(t,e=vp,i=xi.Default){if(this.assertNotDestroyed(),t.hasOwnProperty(pp))return t[pp](this);i=Dm(i);const s=Gh(this),o=oo(void 0);try{if(!(i&xi.SkipSelf)){let l=this.records.get(t);if(void 0===l){const h=function gj(n){return"function"==typeof n||"object"==typeof n&&n instanceof Bt}(t)&&Mm(t);l=h&&this.injectableDefInScope(h)?yu(b1(t),qm):null,this.records.set(t,l)}if(null!=l)return this.hydrate(t,l)}return(i&xi.Self?$m():this.parent).get(t,e=i&xi.Optional&&e===vp?null:e)}catch(a){if("NullInjectorError"===a.name){if((a[Em]=a[Em]||[]).unshift(dt(t)),s)throw a;return function A_(n,t,e,i){const r=n[Em];throw t[BT]&&r.unshift(t[BT]),n.message=function L_(n,t,e,i=null){n=n&&"\n"===n.charAt(0)&&"\u0275"==n.charAt(1)?n.slice(2):n;let r=dt(t);if(Array.isArray(t))r=t.map(dt).join(" -> ");else if("object"==typeof t){let s=[];for(let o in t)if(t.hasOwnProperty(o)){let a=t[o];s.push(o+":"+("string"==typeof a?JSON.stringify(a):dt(a)))}r=`{${s.join(", ")}}`}return`${e}${i?"("+i+")":""}[${r}]: ${n.replace(C_,"\n ")}`}("\n"+n.message,r,e,i),n.ngTokenPath=r,n[Em]=null,n}(a,t,"R3InjectorError",this.source)}throw a}finally{oo(o),Gh(s)}}resolveInjectorInitializers(){const t=Gh(this),e=oo(void 0);try{const r=this.get(vu,Qi,xi.Self);for(const s of r)s()}finally{Gh(t),oo(e)}}toString(){const t=[],e=this.records;for(const i of e.keys())t.push(dt(i));return`R3Injector[${t.join(", ")}]`}assertNotDestroyed(){if(this._destroyed)throw new F(205,!1)}processProvider(t){let e=Gc(t=vt(t))?t:vt(t&&t.provide);const i=function uj(n){return y1(n)?yu(void 0,n.useValue):yu($A(n),qm)}(t);if(!Gc(t)&&!0===t.multi){let r=this.records.get(e);r||(r=yu(void 0,qm,!0),r.factory=()=>kb(r.multi),this.records.set(e,r)),e=t,r.multi.push(t)}this.records.set(e,i)}hydrate(t,e){return e.value===qm&&(e.value=cj,e.value=e.factory()),"object"==typeof e.value&&e.value&&function pj(n){return null!==n&&"object"==typeof n&&"function"==typeof n.ngOnDestroy}(e.value)&&this._ngOnDestroyHooks.add(e.value),e.value}injectableDefInScope(t){if(!t.providedIn)return!1;const e=vt(t.providedIn);return"string"==typeof e?"any"===e||this.scopes.has(e):this.injectorDefTypes.has(e)}removeOnDestroy(t){const e=this._onDestroyHooks.indexOf(t);-1!==e&&this._onDestroyHooks.splice(e,1)}}function b1(n){const t=Mm(n),e=null!==t?t.factory:Vc(n);if(null!==e)return e;if(n instanceof Bt)throw new F(204,!1);if(n instanceof Function)return function dj(n){if(n.length>0)throw new F(204,!1);const e=function I_(n){return n&&(n[Cm]||n[PT])||null}(n);return null!==e?()=>e.factory(n):()=>new n}(n);throw new F(204,!1)}function $A(n,t,e){let i;if(Gc(n)){const r=vt(n);return Vc(r)||b1(r)}if(y1(n))i=()=>vt(n.useValue);else if(function qA(n){return!(!n||!n.useFactory)}(n))i=()=>n.useFactory(...kb(n.deps||[]));else if(function XA(n){return!(!n||!n.useExisting)}(n))i=()=>_i(vt(n.useExisting));else{const r=vt(n&&(n.useClass||n.provide));if(!function fj(n){return!!n.deps}(n))return Vc(r)||b1(r);i=()=>new r(...kb(n.deps))}return i}function yu(n,t,e=!1){return{factory:n,value:t,multi:e?[]:void 0}}function M1(n,t){for(const e of n)Array.isArray(e)?M1(e,t):e&&$l(e)?M1(e.\u0275providers,t):t(e)}function eL(n,t=null,e=null,i){const r=function tL(n,t=null,e=null,i,r=new Set){const s=[e||Qi,aj(n)];return i=i||("object"==typeof n?void 0:dt(n)),new mu(s,t||$m(),i||null,r)}(n,t,e,i);return r.resolveInjectorInitializers(),r}let E1,Wo=(()=>{class n{static{this.THROW_IF_NOT_FOUND=vp}static{this.NULL=new Gm}static create(e,i){if(Array.isArray(e))return eL({name:""},i,e,"");{const r=e.name??"";return eL({name:r},e.parent,e.providers,r)}}static{this.\u0275prov=Yi({token:n,providedIn:"any",factory:()=>_i(YA)})}static{this.__NG_ELEMENT_ID__=-1}}return n})();const D1=new Bt("",{providedIn:"root",factory:()=>Cj}),Cj="ng",rL=new Bt(""),Su=new Bt("",{providedIn:"platform",factory:()=>"unknown"}),nL=new Bt("",{providedIn:"root",factory:()=>function Zh(){if(void 0!==E1)return E1;if(typeof document<"u")return document;throw new F(210,!1)}().body?.querySelector("[ngCspNonce]")?.getAttribute("ngCspNonce")||null});function ty(n){return 128==(128&n.flags)}var ec=function(n){return n[n.Important=1]="Important",n[n.DashCase=2]="DashCase",n}(ec||{});const N1=new Map;let Hj=0;const k1="__ngContext__";function Rs(n,t){ks(t)?(n[k1]=t[bp],function Fj(n){N1.set(n[bp],n)}(t)):n[k1]=t}let P1;function z1(n,t){return P1(n,t)}function bu(n,t,e,i,r){if(null!=i){let s,o=!1;Ps(i)?s=i:ks(i)&&(o=!0,i=i[Vr]);const a=pr(i);0===n&&null!==e?null==r?DL(t,e,a):qc(t,e,a,r||null,!0):1===n&&null!==e?qc(t,e,a,r||null,!0):2===n?function ly(n,t,e){const i=oy(n,t);i&&function t6(n,t,e,i){n.removeChild(t,e,i)}(n,i,t,e)}(t,a,o):3===n&&t.destroyNode(a),null!=s&&function n6(n,t,e,i,r){const s=e[sl];s!==pr(e)&&bu(t,n,i,s,r);for(let a=mn;a0&&(n[e-1][wa]=i[wa]);const s=Vm(n,mn+t);!function Xj(n,t){wL(n,t),t[Vr]=null,t[Os]=null}(i[Be],i);const o=s[nl];null!==o&&o.detachView(s[Be]),i[vn]=null,i[wa]=null,i[Ct]&=-129}return i}function sy(n,t){if(!(256&t[Ct])){const e=t[Yt];e.destroyNode&&hy(n,t,e,3,null,null),function $j(n){let t=n[Sp];if(!t)return H1(n[Be],n);for(;t;){let e=null;if(ks(t))e=t[Sp];else{const i=t[mn];i&&(e=i)}if(!e){for(;t&&!t[wa]&&t!==n;)ks(t)&&H1(t[Be],t),t=t[vn];null===t&&(t=n),ks(t)&&H1(t[Be],t),e=t&&t[wa]}t=e}}(t)}}function H1(n,t){if(!(256&t[Ct])){t[Ct]&=-129,t[Ct]|=256,t[Uc]&&function Qd(n){if(Gl(n),Wh(n))for(let t=0;t=0?i[o]():i[-o].unsubscribe(),s+=2}else e[s].call(i[e[s+1]]);null!==i&&(t[Kd]=null);const r=t[qh];if(null!==r){t[qh]=null;for(let s=0;s-1){const{encapsulation:s}=n.data[i.directiveStart+r];if(s===ba.None||s===ba.Emulated)return null}return qs(i,e)}}(n,t.parent,e)}function qc(n,t,e,i,r){n.insertBefore(t,e,i,r)}function DL(n,t,e){n.appendChild(t,e)}function xL(n,t,e,i,r){null!==i?qc(n,t,e,i,r):DL(n,t,e)}function oy(n,t){return n.parentNode(t)}let F1,LL=function AL(n,t,e){return 40&n.type?qs(n,e):null};function ay(n,t,e,i){const r=B1(n,i,t),s=t[Yt],a=function TL(n,t,e){return LL(n,t,e)}(i.parent||t[Os],i,t);if(null!=r)if(Array.isArray(e))for(let l=0;lnull;function tM(n,t,e=!1){return $L(n,t,e)}class U6{}class tN{}class V6{resolveComponentFactory(t){throw function j6(n){const t=Error(`No component factory found for ${dt(n)}.`);return t.ngComponent=n,t}(t)}}let yy=(()=>{class n{static{this.NULL=new V6}}return n})();function W6(){return xu(gr(),Se())}function xu(n,t){return new $c(qs(n,t))}let $c=(()=>{class n{constructor(e){this.nativeElement=e}static{this.__NG_ELEMENT_ID__=W6}}return n})();function Y6(n){return n instanceof $c?n.nativeElement:n}class rN{}let sM=(()=>{class n{constructor(){this.destroyNode=null}static{this.__NG_ELEMENT_ID__=()=>function Q6(){const n=Se(),e=To(gr().index,n);return(ks(e)?e:n)[Yt]}()}}return n})(),G6=(()=>{class n{static{this.\u0275prov=Yi({token:n,providedIn:"root",factory:()=>null})}}return n})();const oM={};function Wp(n,t,e,i,r=!1){for(;null!==e;){const s=t[e.index];null!==s&&i.push(pr(s)),Ps(s)&&dN(s,i);const o=e.type;if(8&o)Wp(n,t,e.child,i);else if(32&o){const a=z1(e,t);let l;for(;l=a();)i.push(l)}else if(16&o){const a=OL(t,e);if(Array.isArray(a))i.push(...a);else{const l=Wc(t[Jr]);Wp(l[Be],l,a,i,!0)}}e=r?e.projectionNext:e.next}return i}function dN(n,t){for(let e=mn;e!1,producerRecomputeValue:()=>{},consumerMarkedDirty:()=>{},consumerOnSignalRead:()=>{},consumerIsAlwaysLive:!0,consumerMarkedDirty:n=>{Ep(n.lView)},consumerOnSignalRead(){this.lView[Uc]=this}};function fN(n){return gN(n[Sp])}function pN(n){return gN(n[wa])}function gN(n){for(;null!==n&&!Ps(n);)n=n[wa];return n}function hM(n){return n.ngOriginalError}class nh{constructor(){this._console=console}handleError(t){const e=this._findOriginalError(t);this._console.error("ERROR",t),e&&this._console.error("ORIGINAL ERROR",e)}_findOriginalError(t){let e=t&&hM(t);for(;e&&hM(e);)e=hM(e);return e||null}}const mN=new Bt("",{providedIn:"root",factory:()=>Hi(nh).handleError.bind(void 0)}),SN=new Bt("",{providedIn:"root",factory:()=>!1}),Qt={};function Ot(n,t=xi.Default){const e=Se();return null===e?_i(n,t):kA(gr(),e,vt(n),t)}function CN(n,t,e,i,r,s){const o=Wi(null);try{let a=null;r&Xh.SignalBased&&(a=t[i][Ts]),null!==a&&void 0!==a.transformFn&&(s=a.transformFn(s)),r&Xh.HasDecoratorInputTransform&&(s=n.inputTransforms[i].call(t,s)),null!==n.setInput?n.setInput(t,a,s,e,i):iA(t,a,i,s)}finally{Wi(o)}}function My(n,t,e,i,r,s,o,a,l,h,c){const d=t.blueprint.slice();return d[Vr]=r,d[Ct]=204|i,(null!==h||n&&2048&n[Ct])&&(d[Ct]|=2048),hA(d),d[vn]=d[eu]=n,d[Er]=e,d[Kl]=o||n&&n[Kl],d[Yt]=a||n&&n[Yt],d[Xs]=l||n&&n[Xs]||null,d[Os]=s,d[bp]=function Bj(){return Hj++}(),d[Ca]=c,d[JT]=h,d[Jr]=2==t.type?n[Jr]:d,d}function Tu(n,t,e,i,r){let s=n.data[t];if(null===s)s=function cM(n,t,e,i,r){const s=pA(),o=Gb(),l=n.data[t]=function EV(n,t,e,i,r,s){let o=t?t.injectorIndex:-1,a=0;return function nu(){return null!==Rt.skipHydrationRootTNode}()&&(a|=128),{type:e,index:i,insertBeforeIndex:null,injectorIndex:o,directiveStart:-1,directiveEnd:-1,directiveStylingLast:-1,componentOffset:-1,propertyBindings:null,flags:a,providerIndexes:0,value:r,attrs:s,mergedAttrs:null,localNames:null,initialInputs:void 0,inputs:null,outputs:null,tView:null,next:null,prev:null,projectionNext:null,child:null,parent:t,projection:null,styles:null,stylesWithoutHost:null,residualStyles:void 0,classes:null,classesWithoutHost:null,residualClasses:void 0,classBindings:0,styleBindings:0}}(0,o?s:s&&s.parent,e,t,i,r);return null===n.firstChild&&(n.firstChild=l),null!==s&&(o?null==s.child&&null!==l.parent&&(s.child=l):null===s.next&&(s.next=l,l.prev=s)),l}(n,t,e,i,r),function vU(){return Rt.lFrame.inI18n}()&&(s.flags|=32);else if(64&s.type){s.type=e,s.value=i,s.attrs=r;const o=function Dp(){const n=Rt.lFrame,t=n.currentTNode;return n.isParent?t:t.parent}();s.injectorIndex=null===o?-1:o.injectorIndex}return ll(s,!0),s}function Yp(n,t,e,i){if(0===e)return-1;const r=t.length;for(let s=0;sjt&&function wN(n,t,e,i){if(!i)if(3==(3&t[Ct])){const s=n.preOrderCheckHooks;null!==s&&Hm(t,s,e)}else{const s=n.preOrderHooks;null!==s&&Bm(t,s,0,e)}Yc(e)}(n,t,jt,!1),ol(o?2:0,r),e(i,r)}finally{Yc(s),ol(o?3:1,r)}}function dM(n,t,e){if(Bb(t)){const i=Wi(null);try{const s=t.directiveEnd;for(let o=t.directiveStart;onull;function TN(n,t,e,i,r){for(let s in t){if(!t.hasOwnProperty(s))continue;const o=t[s];if(void 0===o)continue;i??={};let a,l=Xh.None;Array.isArray(o)?(a=o[0],l=o[1]):a=o;let h=s;if(null!==r){if(!r.hasOwnProperty(s))continue;h=r[s]}0===n?AN(i,e,h,a,l):AN(i,e,h,a)}return i}function AN(n,t,e,i,r){let s;n.hasOwnProperty(e)?(s=n[e]).push(t,i):s=n[e]=[t,i],void 0!==r&&s.push(r)}function LN(n,t,e,i,r,s){for(let h=0;h0;){const e=n[--t];if("number"==typeof e&&e<0)return e}return 0})(o)!=a&&o.push(a),o.push(e,i,s)}}(n,t,i,Yp(n,e,r.hostVars,Qt),r)}function _V(n,t,e,i,r,s){const o=s[t];if(null!==o)for(let a=0;an.nextProducerIndex;)n.producerNode.pop(),n.producerLastReadVersion.pop(),n.producerIndexOfThis.pop()}}(a,o),function aV(n){n.lView[Uc]!==n&&(n.lView=null,uN.push(n))}(a)),Kb()}}function HN(n,t){for(let e=fN(n);null!==e;e=pN(e))for(let i=mn;i-1&&(Rp(t,i),Vm(e,i))}this._attachedToViewContainer=!1}sy(this._lView[Be],this._lView)}onDestroy(t){!function Pm(n,t){if(256==(256&n[Ct]))throw new F(911,!1);null===n[qh]&&(n[qh]=[]),n[qh].push(t)}(this._lView,t)}markForCheck(){Qp(this._cdRefInjectingView||this._lView)}detach(){this._lView[Ct]&=-129}reattach(){Yb(this._lView),this._lView[Ct]|=128}detectChanges(){this._lView[Ct]|=1024,IM(this._lView,this.notifyErrorHandler)}checkNoChanges(){}attachToViewContainerRef(){if(this._appRef)throw new F(902,!1);this._attachedToViewContainer=!0}detachFromAppRef(){this._appRef=null,wL(this._lView[Be],this._lView)}attachToAppRef(t){if(this._attachedToViewContainer)throw new F(902,!1);this._appRef=t,Yb(this._lView)}}const UN=new Set;function wM(n){return t=>{setTimeout(n,void 0,t)}}const Yo=class n7 extends Pt{constructor(t=!1){super(),this.__isAsync=t}emit(t){super.next(t)}subscribe(t,e,i){let r=t,s=e||(()=>null),o=i;if(t&&"object"==typeof t){const l=t;r=l.next?.bind(l),s=l.error?.bind(l),o=l.complete?.bind(l)}this.__isAsync&&(s=wM(s),r&&(r=wM(r)),o&&(o=wM(o)));const a=super.subscribe({next:r,error:s,complete:o});return t instanceof As&&t.add(a),a}};function jN(...n){}class Rr{constructor({enableLongStackTrace:t=!1,shouldCoalesceEventChangeDetection:e=!1,shouldCoalesceRunChangeDetection:i=!1}){if(this.hasPendingMacrotasks=!1,this.hasPendingMicrotasks=!1,this.isStable=!0,this.onUnstable=new Yo(!1),this.onMicrotaskEmpty=new Yo(!1),this.onStable=new Yo(!1),this.onError=new Yo(!1),typeof Zone>"u")throw new F(908,!1);Zone.assertZonePatched();const r=this;r._nesting=0,r._outer=r._inner=Zone.current,Zone.TaskTrackingZoneSpec&&(r._inner=r._inner.fork(new Zone.TaskTrackingZoneSpec)),t&&Zone.longStackTraceZoneSpec&&(r._inner=r._inner.fork(Zone.longStackTraceZoneSpec)),r.shouldCoalesceEventChangeDetection=!i&&e,r.shouldCoalesceRunChangeDetection=i,r.lastRequestAnimationFrameId=-1,r.nativeRequestAnimationFrame=function s7(){const n="function"==typeof rr.requestAnimationFrame;let t=rr[n?"requestAnimationFrame":"setTimeout"],e=rr[n?"cancelAnimationFrame":"clearTimeout"];if(typeof Zone<"u"&&t&&e){const i=t[Zone.__symbol__("OriginalDelegate")];i&&(t=i);const r=e[Zone.__symbol__("OriginalDelegate")];r&&(e=r)}return{nativeRequestAnimationFrame:t,nativeCancelAnimationFrame:e}}().nativeRequestAnimationFrame,function l7(n){const t=()=>{!function a7(n){n.isCheckStableRunning||-1!==n.lastRequestAnimationFrameId||(n.lastRequestAnimationFrameId=n.nativeRequestAnimationFrame.call(rr,()=>{n.fakeTopEventTask||(n.fakeTopEventTask=Zone.root.scheduleEventTask("fakeTopEventTask",()=>{n.lastRequestAnimationFrameId=-1,EM(n),n.isCheckStableRunning=!0,CM(n),n.isCheckStableRunning=!1},void 0,()=>{},()=>{})),n.fakeTopEventTask.invoke()}),EM(n))}(n)};n._inner=n._inner.fork({name:"angular",properties:{isAngularZone:!0},onInvokeTask:(e,i,r,s,o,a)=>{if(function h7(n){return!(!Array.isArray(n)||1!==n.length)&&!0===n[0].data?.__ignore_ng_zone__}(a))return e.invokeTask(r,s,o,a);try{return VN(n),e.invokeTask(r,s,o,a)}finally{(n.shouldCoalesceEventChangeDetection&&"eventTask"===s.type||n.shouldCoalesceRunChangeDetection)&&t(),WN(n)}},onInvoke:(e,i,r,s,o,a,l)=>{try{return VN(n),e.invoke(r,s,o,a,l)}finally{n.shouldCoalesceRunChangeDetection&&t(),WN(n)}},onHasTask:(e,i,r,s)=>{e.hasTask(r,s),i===r&&("microTask"==s.change?(n._hasPendingMicrotasks=s.microTask,EM(n),CM(n)):"macroTask"==s.change&&(n.hasPendingMacrotasks=s.macroTask))},onHandleError:(e,i,r,s)=>(e.handleError(r,s),n.runOutsideAngular(()=>n.onError.emit(s)),!1)})}(r)}static isInAngularZone(){return typeof Zone<"u"&&!0===Zone.current.get("isAngularZone")}static assertInAngularZone(){if(!Rr.isInAngularZone())throw new F(909,!1)}static assertNotInAngularZone(){if(Rr.isInAngularZone())throw new F(909,!1)}run(t,e,i){return this._inner.run(t,e,i)}runTask(t,e,i,r){const s=this._inner,o=s.scheduleEventTask("NgZoneEvent: "+r,t,o7,jN,jN);try{return s.runTask(o,e,i)}finally{s.cancelTask(o)}}runGuarded(t,e,i){return this._inner.runGuarded(t,e,i)}runOutsideAngular(t){return this._outer.run(t)}}const o7={};function CM(n){if(0==n._nesting&&!n.hasPendingMicrotasks&&!n.isStable)try{n._nesting++,n.onMicrotaskEmpty.emit(null)}finally{if(n._nesting--,!n.hasPendingMicrotasks)try{n.runOutsideAngular(()=>n.onStable.emit(null))}finally{n.isStable=!0}}}function EM(n){n.hasPendingMicrotasks=!!(n._hasPendingMicrotasks||(n.shouldCoalesceEventChangeDetection||n.shouldCoalesceRunChangeDetection)&&-1!==n.lastRequestAnimationFrameId)}function VN(n){n._nesting++,n.isStable&&(n.isStable=!1,n.onUnstable.emit(null))}function WN(n){n._nesting--,CM(n)}let Xp=(()=>{class n{constructor(){this.handler=null,this.internalCallbacks=[]}execute(){const e=[...this.internalCallbacks];this.internalCallbacks.length=0;for(const r of e)r();return!!this.handler?.execute()||e.length>0}ngOnDestroy(){this.handler?.destroy(),this.handler=null,this.internalCallbacks.length=0}static{this.\u0275prov=Yi({token:n,providedIn:"root",factory:()=>new n})}}return n})();function f7(n,t){const e=To(t,n),i=e[Be];!function p7(n,t){for(let e=t.length;e0&&zL(n,e,s.join(" "))}}(u,w,p,i),void 0!==e&&function C7(n,t,e){const i=n.projection=[];for(let r=0;r=0;i--){const r=n[i];r.hostVars=t+=r.hostVars,r.hostAttrs=yp(r.hostAttrs,e=yp(e,r.hostAttrs))}}(i)}function D7(n,t){for(const e in t.inputs){if(!t.inputs.hasOwnProperty(e)||n.inputs.hasOwnProperty(e))continue;const i=t.inputs[e];if(void 0!==i&&(n.inputs[e]=i,n.declaredInputs[e]=t.declaredInputs[e],null!==t.inputTransforms)){const r=Array.isArray(i)?i[0]:i;if(!t.inputTransforms.hasOwnProperty(r))continue;n.inputTransforms??={},n.inputTransforms[r]=t.inputTransforms[r]}}}function Dy(n){return n===rl?{}:n===Qi?[]:n}function T7(n,t){const e=n.viewQuery;n.viewQuery=e?(i,r)=>{t(i,r),e(i,r)}:t}function A7(n,t){const e=n.contentQueries;n.contentQueries=e?(i,r,s)=>{t(i,r,s),e(i,r,s)}:t}function L7(n,t){const e=n.hostBindings;n.hostBindings=e?(i,r)=>{t(i,r),e(i,r)}:t}function Lu(n,t){return!t||null===t.firstChild||ty(n)}function tg(n,t,e,i=!0){const r=t[Be];if(function Zj(n,t,e,i){const r=mn+i,s=e.length;i>0&&(e[r-1][wa]=t),i{class n{static{this.__NG_ELEMENT_ID__=n9}}return n})();function n9(){return dO(gr(),Se())}const s9=An,hO=class extends s9{constructor(t,e,i){super(),this._lContainer=t,this._hostTNode=e,this._hostLView=i}get element(){return xu(this._hostTNode,this._hostLView)}get injector(){return new Yn(this._hostTNode,this._hostLView)}get parentInjector(){const t=Um(this._hostTNode,this._hostLView);if(i1(t)){const e=Ap(t,this._hostLView),i=Tp(t);return new Yn(e[Be].data[i+8],e)}return new Yn(null,this._hostLView)}clear(){for(;this.length>0;)this.remove(this.length-1)}get(t){const e=cO(this._lContainer);return null!==e&&e[t]||null}get length(){return this._lContainer.length-mn}createEmbeddedView(t,e,i){let r,s;"number"==typeof i?r=i:null!=i&&(r=i.index,s=i.injector);const a=t.createEmbeddedViewImpl(e||{},s,null);return this.insertImpl(a,r,Lu(this._hostTNode,null)),a}createComponent(t,e,i,r,s){const o=t&&!function Lp(n){return"function"==typeof n}(t);let a;if(o)a=e;else{const p=e||{};a=p.index,i=p.injector,r=p.projectableNodes,s=p.environmentInjector||p.ngModuleRef}const l=o?t:new qp(di(t)),h=i||this.parentInjector;if(!s&&null==l.ngModule){const g=(o?h:this.parentInjector).get(ih,null);g&&(s=g)}di(l.componentType??{});const f=l.create(h,r,null,s);return this.insertImpl(f.hostView,a,Lu(this._hostTNode,null)),f}insert(t,e){return this.insertImpl(t,e,!0)}insertImpl(t,e,i){const r=t._lView;if(function rU(n){return Ps(n[vn])}(r)){const a=this.indexOf(t);if(-1!==a)this.detach(a);else{const l=r[vn],h=new hO(l,l[Os],l[vn]);h.detach(h.indexOf(t))}}const s=this._adjustIndex(e),o=this._lContainer;return tg(o,r,s,i),t.attachToViewContainerRef(),FA(kM(o),s,t),t}move(t,e){return this.insert(t,e)}indexOf(t){const e=cO(this._lContainer);return null!==e?e.indexOf(t):-1}remove(t){const e=this._adjustIndex(t,-1),i=Rp(this._lContainer,e);i&&(Vm(kM(this._lContainer),e),sy(i[Be],i))}detach(t){const e=this._adjustIndex(t,-1),i=Rp(this._lContainer,e);return i&&null!=Vm(kM(this._lContainer),e)?new Gp(i):null}_adjustIndex(t,e=0){return t??this.length+e}};function cO(n){return n[8]}function kM(n){return n[8]||(n[8]=[])}function dO(n,t){let e;const i=t[n.index];return Ps(i)?e=i:(e=function ON(n,t,e,i){return[n,!0,0,t,null,i,null,e,null,null]}(i,t,null,n),t[n.index]=e,wy(t,e)),uO(e,t,n,i),new hO(e,n,t)}let uO=function pO(n,t,e,i){if(n[sl])return;let r;r=8&e.type?pr(i):function o9(n,t){const e=n[Yt],i=e.createComment(""),r=qs(t,n);return qc(e,oy(e,r),i,function i6(n,t){return n.nextSibling(t)}(e,r),!1),i}(t,e),n[sl]=r};function QM(n,t,e){const i=Se();return function Ln(n,t,e){return!Object.is(n[t],e)&&(n[t]=e,!0)}(i,function hl(){return Rt.lFrame.bindingIndex++}(),t)&&function No(n,t,e,i,r,s,o,a){const l=qs(t,e);let c,h=t.inputs;!a&&null!=h&&(c=h[i])?(SM(n,e,c,i,r),jc(t)&&function TV(n,t){const e=To(t,n);16&e[Ct]||(e[Ct]|=64)}(e,t.index)):3&t.type&&(i=function xV(n){return"class"===n?"className":"for"===n?"htmlFor":"formaction"===n?"formAction":"innerHtml"===n?"innerHTML":"readonly"===n?"readOnly":"tabindex"===n?"tabIndex":n}(i),r=null!=o?o(r,t.value||"",i):r,s.setProperty(l,i,r))}(Ti(),function zr(){const n=Rt.lFrame;return Cp(n.tView,n.selectedIndex)}(),i,n,t,i[Yt],e,!1),QM}function GM(n,t,e,i,r){const o=r?"class":"style";SM(n,e,t.inputs[o],o,i)}function KM(n,t,e,i){const r=Se(),s=Ti(),o=jt+n,a=r[Yt],l=s.firstCreatePass?function k8(n,t,e,i,r,s){const o=t.consts,l=Tu(t,n,2,i,al(o,r));return function gM(n,t,e,i){if(fA()){const r=null===i?null:{"":-1},s=function PV(n,t){const e=n.directiveRegistry;let i=null,r=null;if(e)for(let s=0;s(function $h(n){EA=n}(!0),ny(i,r,function CA(){return Rt.lFrame.currentNamespace}()));const Xu="en-US";let Ik=Xu;function ow(n){return!!n&&"function"==typeof n.then}function Yk(n){return!!n&&"function"==typeof n.subscribe}function UW(){return this._results[Symbol.iterator]()}class lw{get changes(){return this._changes??=new Yo}constructor(t=!1){this._emitDistinctChangesOnly=t,this.dirty=!0,this._results=[],this._changesDetected=!1,this._changes=void 0,this.length=0,this.first=void 0,this.last=void 0;const e=lw.prototype;e[Symbol.iterator]||(e[Symbol.iterator]=UW)}get(t){return this._results[t]}map(t){return this._results.map(t)}filter(t){return this._results.filter(t)}find(t){return this._results.find(t)}reduce(t,e){return this._results.reduce(t,e)}forEach(t){this._results.forEach(t)}some(t){return this._results.some(t)}toArray(){return this._results.slice()}toString(){return this._results.toString()}reset(t,e){this.dirty=!1;const i=function lo(n){return n.flat(Number.POSITIVE_INFINITY)}(t);(this._changesDetected=!function WU(n,t,e){if(n.length!==t.length)return!1;for(let i=0;i{class n{static{this.__NG_ELEMENT_ID__=WW}}return n})();const jW=oh,VW=class extends jW{constructor(t,e,i){super(),this._declarationLView=t,this._declarationTContainer=e,this.elementRef=i}get ssrId(){return this._declarationTContainer.tView?.ssrId||null}createEmbeddedView(t,e){return this.createEmbeddedViewImpl(t,e)}createEmbeddedViewImpl(t,e,i){const r=function eg(n,t,e,i){const r=t.tView,a=My(n,r,e,4096&n[Ct]?4096:16,null,t,null,null,null,i?.injector??null,i?.dehydratedView??null);a[Ip]=n[t.index];const h=n[nl];return null!==h&&(a[nl]=h.createEmbeddedView(r)),DM(r,a,e),a}(this._declarationLView,this._declarationTContainer,t,{injector:e,dehydratedView:i});return new Gp(r)}};function WW(){return Vy(gr(),Se())}function Vy(n,t){return 4&n.type?new VW(t,n,xu(n,t)):null}class hw{constructor(t){this.queryList=t,this.matches=null}clone(){return new hw(this.queryList)}setDirty(){this.queryList.setDirty()}}class cw{constructor(t=[]){this.queries=t}createEmbeddedView(t){const e=t.queries;if(null!==e){const i=null!==t.contentQueries?t.contentQueries[0]:e.length,r=[];for(let s=0;s0)i.push(o[a/2]);else{const h=s[a+1],c=t[-l];for(let d=mn;d>20;if(Gc(n)||!n.multi){const f=new xp(h,r,Ot),p=mw(l,t,r?c:c+u,d);-1===p?(s1(_m(a,o),s,l),vw(s,n,t.length),t.push(l),a.directiveStart++,a.directiveEnd++,r&&(a.providerIndexes+=1048576),e.push(f),o.push(f)):(e[p]=f,o[p]=f)}else{const f=mw(l,t,c+u,d),p=mw(l,t,c,c+u),v=p>=0&&e[p];if(r&&!v||!r&&!(f>=0&&e[f])){s1(_m(a,o),s,l);const y=function pY(n,t,e,i,r){const s=new xp(n,e,Ot);return s.multi=[],s.index=t,s.componentProviders=0,NP(s,r,i&&!e),s}(r?fY:uY,e.length,r,i,h);!r&&v&&(e[p].providerFactory=y),vw(s,n,t.length,0),t.push(l),a.directiveStart++,a.directiveEnd++,r&&(a.providerIndexes+=1048576),e.push(y),o.push(y)}else vw(s,n,f>-1?f:p,NP(e[r?p:f],h,!r&&i));!r&&i&&v&&e[p].componentProviders++}}}function vw(n,t,e,i){const r=Gc(t),s=function hj(n){return!!n.useClass}(t);if(r||s){const l=(s?vt(t.useClass):t).prototype.ngOnDestroy;if(l){const h=n.destroyHooks||(n.destroyHooks=[]);if(!r&&t.multi){const c=h.indexOf(e);-1===c?h.push(e,[i,l]):h[c+1].push(i,l)}else h.push(e,l)}}}function NP(n,t,e){return e&&n.componentProviders++,n.multi.push(t)-1}function mw(n,t,e,i){for(let r=e;r{e.providersResolver=(i,r)=>function dY(n,t,e){const i=Ti();if(i.firstCreatePass){const r=Ea(n);gw(e,i.data,i.blueprint,r,!0),gw(t,i.data,i.blueprint,r,!1)}}(i,r?r(n):n,t)}}class rd{}class kP extends rd{constructor(t){super(),this.componentFactoryResolver=new $N(this),this.instance=null;const e=new mu([...t.providers,{provide:rd,useValue:this},{provide:yy,useValue:this.componentFactoryResolver}],t.parent||$m(),t.debugName,new Set(["environment"]));this.injector=e,t.runEnvironmentInitializers&&e.resolveInjectorInitializers()}destroy(){this.injector.destroy()}onDestroy(t){this.injector.onDestroy(t)}}let SY=(()=>{class n{constructor(e){this._injector=e,this.cachedInjectors=new Map}getOrCreateStandaloneInjector(e){if(!e.standalone)return null;if(!this.cachedInjectors.has(e)){const i=QA(0,e.type),r=i.length>0?function yY(n,t,e=null){return new kP({providers:n,parent:t,debugName:e,runEnvironmentInitializers:!0}).injector}([i],this._injector,`Standalone[${e.type.name}]`):null;this.cachedInjectors.set(e,r)}return this.cachedInjectors.get(e)}ngOnDestroy(){try{for(const e of this.cachedInjectors.values())null!==e&&e.destroy()}finally{this.cachedInjectors.clear()}}static{this.\u0275prov=Yi({token:n,providedIn:"environment",factory:()=>new n(_i(ih))})}}return n})();function PP(n){(function Zc(n){UN.has(n)||(UN.add(n),performance?.mark?.("mark_feature_usage",{detail:{feature:n}}))})("NgStandalone"),n.getStandaloneInjector=t=>t.get(SY).getOrCreateStandaloneInjector(n)}let xw=(()=>{class n{constructor(){this.taskId=0,this.pendingTasks=new Set,this.hasPendingTasks=new _o(!1)}get _hasPendingTasks(){return this.hasPendingTasks.value}add(){this._hasPendingTasks||this.hasPendingTasks.next(!0);const e=this.taskId++;return this.pendingTasks.add(e),e}remove(e){this.pendingTasks.delete(e),0===this.pendingTasks.size&&this._hasPendingTasks&&this.hasPendingTasks.next(!1)}ngOnDestroy(){this.pendingTasks.clear(),this._hasPendingTasks&&this.hasPendingTasks.next(!1)}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();const f2=new Bt(""),WQ=new Bt("");let Ow=(()=>{class n{constructor(){this.initialized=!1,this.done=!1,this.donePromise=new Promise((e,i)=>{this.resolve=e,this.reject=i}),this.appInits=Hi(WQ,{optional:!0})??[]}runInitializers(){if(this.initialized)return;const e=[];for(const r of this.appInits){const s=r();if(ow(s))e.push(s);else if(Yk(s)){const o=new Promise((a,l)=>{s.subscribe({complete:a,error:l})});e.push(o)}}const i=()=>{this.done=!0,this.resolve()};Promise.all(e).then(()=>{i()}).catch(r=>{this.reject(r)}),0===e.length&&i(),this.initialized=!0}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();const p2=new Bt("");let Zu=(()=>{class n{constructor(){this._bootstrapListeners=[],this._runningTick=!1,this._destroyed=!1,this._destroyListeners=[],this._views=[],this.internalErrorHandler=Hi(mN),this.afterRenderEffectManager=Hi(Xp),this.componentTypes=[],this.components=[],this.isStable=Hi(xw).hasPendingTasks.pipe(jr(e=>!e)),this._injector=Hi(ih)}get destroyed(){return this._destroyed}get injector(){return this._injector}bootstrap(e,i){const r=e instanceof tN;if(!this._injector.get(Ow).done)throw!r&&function _c(n){const t=di(n)||Wn(n)||gs(n);return null!==t&&t.standalone}(e),new F(405,!1);let o;o=r?e:this._injector.get(yy).resolveComponentFactory(e),this.componentTypes.push(o.componentType);const a=function QQ(n){return n.isBoundToModule}(o)?void 0:this._injector.get(rd),h=o.create(Wo.NULL,[],i||o.selector,a),c=h.location.nativeElement,d=h.injector.get(f2,null);return d?.registerApplication(c),h.onDestroy(()=>{this.detachView(h.hostView),qy(this.components,h),d?.unregisterApplication(c)}),this._loadComponent(h),h}tick(){if(this._runningTick)throw new F(101,!1);try{this._runningTick=!0;for(let e of this._views)e.detectChanges()}catch(e){this.internalErrorHandler(e)}finally{try{this.afterRenderEffectManager.execute()}catch(e){this.internalErrorHandler(e)}this._runningTick=!1}}attachView(e){const i=e;this._views.push(i),i.attachToAppRef(this)}detachView(e){const i=e;qy(this._views,i),i.detachFromAppRef()}_loadComponent(e){this.attachView(e.hostView),this.tick(),this.components.push(e);const i=this._injector.get(p2,[]);[...this._bootstrapListeners,...i].forEach(r=>r(e))}ngOnDestroy(){if(!this._destroyed)try{this._destroyListeners.forEach(e=>e()),this._views.slice().forEach(e=>e.destroy())}finally{this._destroyed=!0,this._views=[],this._bootstrapListeners=[],this._destroyListeners=[]}}onDestroy(e){return this._destroyListeners.push(e),()=>qy(this._destroyListeners,e)}destroy(){if(this._destroyed)throw new F(406,!1);const e=this._injector;e.destroy&&!e.destroyed&&e.destroy()}get viewCount(){return this._views.length}warnIfDestroyed(){}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();function qy(n,t){const e=n.indexOf(t);e>-1&&n.splice(e,1)}let XQ=(()=>{class n{constructor(){this.zone=Hi(Rr),this.applicationRef=Hi(Zu)}initialize(){this._onMicrotaskEmptySubscription||(this._onMicrotaskEmptySubscription=this.zone.onMicrotaskEmpty.subscribe({next:()=>{this.zone.run(()=>{this.applicationRef.tick()})}}))}ngOnDestroy(){this._onMicrotaskEmptySubscription?.unsubscribe()}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();function S2(n){return[{provide:Rr,useFactory:n},{provide:vu,multi:!0,useFactory:()=>{const t=Hi(XQ,{optional:!0});return()=>t.initialize()}},{provide:vu,multi:!0,useFactory:()=>{const t=Hi(ZQ);return()=>{t.initialize()}}},{provide:mN,useFactory:qQ}]}function qQ(){const n=Hi(Rr),t=Hi(nh);return e=>n.runOutsideAngular(()=>t.handleError(e))}function $Q(n){return function v1(n){return{\u0275providers:n}}([[],S2(()=>new Rr(function I2(n){return{enableLongStackTrace:!1,shouldCoalesceEventChangeDetection:n?.eventCoalescing??!1,shouldCoalesceRunChangeDetection:n?.runCoalescing??!1}}(n)))])}let ZQ=(()=>{class n{constructor(){this.subscription=new As,this.initialized=!1,this.zone=Hi(Rr),this.pendingTasks=Hi(xw)}initialize(){if(this.initialized)return;this.initialized=!0;let e=null;!this.zone.isStable&&!this.zone.hasPendingMacrotasks&&!this.zone.hasPendingMicrotasks&&(e=this.pendingTasks.add()),this.zone.runOutsideAngular(()=>{this.subscription.add(this.zone.onStable.subscribe(()=>{Rr.assertNotInAngularZone(),queueMicrotask(()=>{null!==e&&!this.zone.hasPendingMacrotasks&&!this.zone.hasPendingMicrotasks&&(this.pendingTasks.remove(e),e=null)})}))}),this.subscription.add(this.zone.onUnstable.subscribe(()=>{Rr.assertInAngularZone(),e??=this.pendingTasks.add()}))}ngOnDestroy(){this.subscription.unsubscribe()}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();const ah=new Bt("",{providedIn:"root",factory:()=>Hi(ah,xi.Optional|xi.SkipSelf)||function JQ(){return typeof $localize<"u"&&$localize.locale||Xu}()}),kw=new Bt("");let nc=null;function MG(n){try{const{rootComponent:t,appProviders:e,platformProviders:i}=n,r=function rG(n=[]){if(nc)return nc;const t=function w2(n=[],t){return Wo.create({name:t,providers:[{provide:S1,useValue:"platform"},{provide:kw,useValue:new Set([()=>nc=null])},...n]})}(n);return nc=t,function g2(){!function mb(n){Xd=n}(()=>{throw new F(600,!1)})}(),function C2(n){n.get(rL,null)?.forEach(e=>e())}(t),t}(i),s=[$Q(),...e||[]],a=new kP({providers:s,parent:r,debugName:"",runEnvironmentInitializers:!1}).injector,l=a.get(Rr);return l.run(()=>{a.resolveInjectorInitializers();const h=a.get(nh,null);let c;l.runOutsideAngular(()=>{c=l.onError.subscribe({next:f=>{h.handleError(f)}})});const d=()=>a.destroy(),u=r.get(kw);return u.add(d),a.onDestroy(()=>{c.unsubscribe(),u.delete(d)}),function v2(n,t,e){try{const i=e();return ow(i)?i.catch(r=>{throw t.runOutsideAngular(()=>n.handleError(r)),r}):i}catch(i){throw t.runOutsideAngular(()=>n.handleError(i)),i}}(h,l,()=>{const f=a.get(Ow);return f.runInitializers(),f.donePromise.then(()=>{!function bk(n){so(n,"Expected localeId to be defined"),"string"==typeof n&&(Ik=n.toLowerCase().replace(/_/g,"-"))}(a.get(ah,Xu)||Xu);const g=a.get(Zu);return void 0!==t&&g.bootstrap(t),g})})})}catch(t){return Promise.reject(t)}}let X2=null;function Uw(){return X2}class HG{}const sd=new Bt("");let tq=(()=>{class n{static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275mod=Tm({type:n})}static{this.\u0275inj=gp({})}}return n})();function cz(n){return"server"===n}class Aq extends HG{constructor(){super(...arguments),this.supportsDOMEvents=!0}}class nC extends Aq{static makeCurrent(){!function RG(n){X2??=n}(new nC)}onAndCancel(t,e,i){return t.addEventListener(e,i),()=>{t.removeEventListener(e,i)}}dispatchEvent(t,e){t.dispatchEvent(e)}remove(t){t.parentNode&&t.parentNode.removeChild(t)}createElement(t,e){return(e=e||this.getDefaultDocument()).createElement(t)}createHtmlDocument(){return document.implementation.createHTMLDocument("fakeTitle")}getDefaultDocument(){return document}isElementNode(t){return t.nodeType===Node.ELEMENT_NODE}isShadowRoot(t){return t instanceof DocumentFragment}getGlobalEventTarget(t,e){return"window"===e?window:"document"===e?t:"body"===e?t.body:null}getBaseHref(t){const e=function Lq(){return bg=bg||document.querySelector("base"),bg?bg.getAttribute("href"):null}();return null==e?null:function Nq(n){return new URL(n,document.baseURI).pathname}(e)}resetBaseElement(){bg=null}getUserAgent(){return window.navigator.userAgent}getCookie(t){return function wX(n,t){t=encodeURIComponent(t);for(const e of n.split(";")){const i=e.indexOf("="),[r,s]=-1==i?[e,""]:[e.slice(0,i),e.slice(i+1)];if(r.trim()===t)return decodeURIComponent(s)}return null}(document.cookie,t)}}let bg=null,kq=(()=>{class n{build(){return new XMLHttpRequest}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();const sC=new Bt("");let pz=(()=>{class n{constructor(e,i){this._zone=i,this._eventNameToPlugin=new Map,e.forEach(r=>{r.manager=this}),this._plugins=e.slice().reverse()}addEventListener(e,i,r){return this._findPluginFor(i).addEventListener(e,i,r)}getZone(){return this._zone}_findPluginFor(e){let i=this._eventNameToPlugin.get(e);if(i)return i;if(i=this._plugins.find(s=>s.supports(e)),!i)throw new F(5101,!1);return this._eventNameToPlugin.set(e,i),i}static{this.\u0275fac=function(i){return new(i||n)(_i(sC),_i(Rr))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();class gz{constructor(t){this._doc=t}}const oC="ng-app-id";let vz=(()=>{class n{constructor(e,i,r,s={}){this.doc=e,this.appId=i,this.nonce=r,this.platformId=s,this.styleRef=new Map,this.hostNodes=new Set,this.styleNodesInDOM=this.collectServerRenderedStyles(),this.platformIsServer=cz(s),this.resetHostNodes()}addStyles(e){for(const i of e)1===this.changeUsageCount(i,1)&&this.onStyleAdded(i)}removeStyles(e){for(const i of e)this.changeUsageCount(i,-1)<=0&&this.onStyleRemoved(i)}ngOnDestroy(){const e=this.styleNodesInDOM;e&&(e.forEach(i=>i.remove()),e.clear());for(const i of this.getAllStyles())this.onStyleRemoved(i);this.resetHostNodes()}addHost(e){this.hostNodes.add(e);for(const i of this.getAllStyles())this.addStyleToHost(e,i)}removeHost(e){this.hostNodes.delete(e)}getAllStyles(){return this.styleRef.keys()}onStyleAdded(e){for(const i of this.hostNodes)this.addStyleToHost(i,e)}onStyleRemoved(e){const i=this.styleRef;i.get(e)?.elements?.forEach(r=>r.remove()),i.delete(e)}collectServerRenderedStyles(){const e=this.doc.head?.querySelectorAll(`style[${oC}="${this.appId}"]`);if(e?.length){const i=new Map;return e.forEach(r=>{null!=r.textContent&&i.set(r.textContent,r)}),i}return null}changeUsageCount(e,i){const r=this.styleRef;if(r.has(e)){const s=r.get(e);return s.usage+=i,s.usage}return r.set(e,{usage:i,elements:[]}),i}getStyleElement(e,i){const r=this.styleNodesInDOM,s=r?.get(i);if(s?.parentNode===e)return r.delete(i),s.removeAttribute(oC),s;{const o=this.doc.createElement("style");return this.nonce&&o.setAttribute("nonce",this.nonce),o.textContent=i,this.platformIsServer&&o.setAttribute(oC,this.appId),e.appendChild(o),o}}addStyleToHost(e,i){const r=this.getStyleElement(e,i),s=this.styleRef,o=s.get(i)?.elements;o?o.push(r):s.set(i,{elements:[r],usage:1})}resetHostNodes(){const e=this.hostNodes;e.clear(),e.add(this.doc.head)}static{this.\u0275fac=function(i){return new(i||n)(_i(sd),_i(D1),_i(nL,8),_i(Su))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();const aC={svg:"http://www.w3.org/2000/svg",xhtml:"http://www.w3.org/1999/xhtml",xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/",math:"http://www.w3.org/1998/MathML/"},lC=/%COMP%/g,Hq=new Bt("",{providedIn:"root",factory:()=>!0});function yz(n,t){return t.map(e=>e.replace(lC,n))}let Sz=(()=>{class n{constructor(e,i,r,s,o,a,l,h=null){this.eventManager=e,this.sharedStylesHost=i,this.appId=r,this.removeStylesOnCompDestroy=s,this.doc=o,this.platformId=a,this.ngZone=l,this.nonce=h,this.rendererByCompId=new Map,this.platformIsServer=cz(a),this.defaultRenderer=new hC(e,o,l,this.platformIsServer)}createRenderer(e,i){if(!e||!i)return this.defaultRenderer;this.platformIsServer&&i.encapsulation===ba.ShadowDom&&(i={...i,encapsulation:ba.Emulated});const r=this.getOrCreateRenderer(e,i);return r instanceof bz?r.applyToHost(e):r instanceof cC&&r.applyStyles(),r}getOrCreateRenderer(e,i){const r=this.rendererByCompId;let s=r.get(i.id);if(!s){const o=this.doc,a=this.ngZone,l=this.eventManager,h=this.sharedStylesHost,c=this.removeStylesOnCompDestroy,d=this.platformIsServer;switch(i.encapsulation){case ba.Emulated:s=new bz(l,h,i,this.appId,c,o,a,d);break;case ba.ShadowDom:return new Uq(l,h,e,i,o,a,this.nonce,d);default:s=new cC(l,h,i,c,o,a,d)}r.set(i.id,s)}return s}ngOnDestroy(){this.rendererByCompId.clear()}static{this.\u0275fac=function(i){return new(i||n)(_i(pz),_i(vz),_i(D1),_i(Hq),_i(sd),_i(Su),_i(Rr),_i(nL))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();class hC{constructor(t,e,i,r){this.eventManager=t,this.doc=e,this.ngZone=i,this.platformIsServer=r,this.data=Object.create(null),this.throwOnSyntheticProps=!0,this.destroyNode=null}destroy(){}createElement(t,e){return e?this.doc.createElementNS(aC[e]||e,t):this.doc.createElement(t)}createComment(t){return this.doc.createComment(t)}createText(t){return this.doc.createTextNode(t)}appendChild(t,e){(Iz(t)?t.content:t).appendChild(e)}insertBefore(t,e,i){t&&(Iz(t)?t.content:t).insertBefore(e,i)}removeChild(t,e){t&&t.removeChild(e)}selectRootElement(t,e){let i="string"==typeof t?this.doc.querySelector(t):t;if(!i)throw new F(-5104,!1);return e||(i.textContent=""),i}parentNode(t){return t.parentNode}nextSibling(t){return t.nextSibling}setAttribute(t,e,i,r){if(r){e=r+":"+e;const s=aC[r];s?t.setAttributeNS(s,e,i):t.setAttribute(e,i)}else t.setAttribute(e,i)}removeAttribute(t,e,i){if(i){const r=aC[i];r?t.removeAttributeNS(r,e):t.removeAttribute(`${i}:${e}`)}else t.removeAttribute(e)}addClass(t,e){t.classList.add(e)}removeClass(t,e){t.classList.remove(e)}setStyle(t,e,i,r){r&(ec.DashCase|ec.Important)?t.style.setProperty(e,i,r&ec.Important?"important":""):t.style[e]=i}removeStyle(t,e,i){i&ec.DashCase?t.style.removeProperty(e):t.style[e]=""}setProperty(t,e,i){null!=t&&(t[e]=i)}setValue(t,e){t.nodeValue=e}listen(t,e,i){if("string"==typeof t&&!(t=Uw().getGlobalEventTarget(this.doc,t)))throw new Error(`Unsupported event target ${t} for event ${e}`);return this.eventManager.addEventListener(t,e,this.decoratePreventDefault(i))}decoratePreventDefault(t){return e=>{if("__ngUnwrap__"===e)return t;!1===(this.platformIsServer?this.ngZone.runGuarded(()=>t(e)):t(e))&&e.preventDefault()}}}function Iz(n){return"TEMPLATE"===n.tagName&&void 0!==n.content}class Uq extends hC{constructor(t,e,i,r,s,o,a,l){super(t,s,o,l),this.sharedStylesHost=e,this.hostEl=i,this.shadowRoot=i.attachShadow({mode:"open"}),this.sharedStylesHost.addHost(this.shadowRoot);const h=yz(r.id,r.styles);for(const c of h){const d=document.createElement("style");a&&d.setAttribute("nonce",a),d.textContent=c,this.shadowRoot.appendChild(d)}}nodeOrShadowRoot(t){return t===this.hostEl?this.shadowRoot:t}appendChild(t,e){return super.appendChild(this.nodeOrShadowRoot(t),e)}insertBefore(t,e,i){return super.insertBefore(this.nodeOrShadowRoot(t),e,i)}removeChild(t,e){return super.removeChild(this.nodeOrShadowRoot(t),e)}parentNode(t){return this.nodeOrShadowRoot(super.parentNode(this.nodeOrShadowRoot(t)))}destroy(){this.sharedStylesHost.removeHost(this.shadowRoot)}}class cC extends hC{constructor(t,e,i,r,s,o,a,l){super(t,s,o,a),this.sharedStylesHost=e,this.removeStylesOnCompDestroy=r,this.styles=l?yz(l,i.styles):i.styles}applyStyles(){this.sharedStylesHost.addStyles(this.styles)}destroy(){this.removeStylesOnCompDestroy&&this.sharedStylesHost.removeStyles(this.styles)}}class bz extends cC{constructor(t,e,i,r,s,o,a,l){const h=r+"-"+i.id;super(t,e,i,s,o,a,l,h),this.contentAttr=function Bq(n){return"_ngcontent-%COMP%".replace(lC,n)}(h),this.hostAttr=function Fq(n){return"_nghost-%COMP%".replace(lC,n)}(h)}applyToHost(t){this.applyStyles(),this.setAttribute(t,this.hostAttr,"")}createElement(t,e){const i=super.createElement(t,e);return super.setAttribute(i,this.contentAttr,""),i}}let jq=(()=>{class n extends gz{constructor(e){super(e)}supports(e){return!0}addEventListener(e,i,r){return e.addEventListener(i,r,!1),()=>this.removeEventListener(e,i,r)}removeEventListener(e,i,r){return e.removeEventListener(i,r)}static{this.\u0275fac=function(i){return new(i||n)(_i(sd))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();const Mz=["alt","control","meta","shift"],Vq={"\b":"Backspace","\t":"Tab","\x7f":"Delete","\x1b":"Escape",Del:"Delete",Esc:"Escape",Left:"ArrowLeft",Right:"ArrowRight",Up:"ArrowUp",Down:"ArrowDown",Menu:"ContextMenu",Scroll:"ScrollLock",Win:"OS"},Wq={alt:n=>n.altKey,control:n=>n.ctrlKey,meta:n=>n.metaKey,shift:n=>n.shiftKey};let Yq=(()=>{class n extends gz{constructor(e){super(e)}supports(e){return null!=n.parseEventName(e)}addEventListener(e,i,r){const s=n.parseEventName(i),o=n.eventCallback(s.fullKey,r,this.manager.getZone());return this.manager.getZone().runOutsideAngular(()=>Uw().onAndCancel(e,s.domEventName,o))}static parseEventName(e){const i=e.toLowerCase().split("."),r=i.shift();if(0===i.length||"keydown"!==r&&"keyup"!==r)return null;const s=n._normalizeKey(i.pop());let o="",a=i.indexOf("code");if(a>-1&&(i.splice(a,1),o="code."),Mz.forEach(h=>{const c=i.indexOf(h);c>-1&&(i.splice(c,1),o+=h+".")}),o+=s,0!=i.length||0===s.length)return null;const l={};return l.domEventName=r,l.fullKey=o,l}static matchEventFullKeyCode(e,i){let r=Vq[e.key]||e.key,s="";return i.indexOf("code.")>-1&&(r=e.code,s="code."),!(null==r||!r)&&(r=r.toLowerCase()," "===r?r="space":"."===r&&(r="dot"),Mz.forEach(o=>{o!==r&&(0,Wq[o])(e)&&(s+=o+".")}),s+=r,s===i)}static eventCallback(e,i,r){return s=>{n.matchEventFullKeyCode(s,e)&&r.runGuarded(()=>i(s))}}static _normalizeKey(e){return"esc"===e?"escape":e}static{this.\u0275fac=function(i){return new(i||n)(_i(sd))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();function wz(n){return{appProviders:[...Jq,...n?.providers??[]],platformProviders:$q}}const $q=[{provide:Su,useValue:"browser"},{provide:rL,useValue:function Gq(){nC.makeCurrent()},multi:!0},{provide:sd,useFactory:function qq(){return function wj(n){E1=n}(document),document},deps:[]}],Jq=[{provide:S1,useValue:"root"},{provide:nh,useFactory:function Xq(){return new nh},deps:[]},{provide:sC,useClass:jq,multi:!0,deps:[sd,Rr,Su]},{provide:sC,useClass:Yq,multi:!0,deps:[sd]},Sz,vz,pz,{provide:rN,useExisting:Sz},{provide:class oq{},useClass:kq,deps:[]},[]];var i$=0,dC=!1;function y0(n,t){var e=t;return e.unshift(void 0),new(Function.prototype.bind.apply(n,e))}function Y(n,t){for(var e=t,i=n.replace(/\[/g,".").replace(/\]/g,"").split("."),r=0;r"u"}function Ei(n){return n+"_"+i$++}function I0(n,t){return n===t||!(n===document||!n)&&I0(n.parentNode,t)}function Cg(n){try{throw new Error(n)}catch(t){throw new Error(t.message+"\n"+t.stack)}}function Re(n){var t=n+"";return t.match(/auto|cm|mm|in|px|pt|pc|%|em|ex|ch|rem|vw|vh|vmin|vmax/)?t:t+"px"}function ce(){return dC}var Eg,n,t,a$={latn:{_digits:"0123456789",_type:"numeric"}},Tz={decimal:".",group:",",percentSign:"%",plusSign:"+",minusSign:"-",infinity:"\u221e",nan:"NaN",exponential:"E"},Az=[0,1,2,3,4,5,6,7,8,9],Hr=function(){function n(){}return n.getMainObject=function(t,e){return Y(ce()?e:"main."+e,t)},n.getNumberingSystem=function(t){return Y("supplemental.numberingSystems",t)||this.numberingSystems},n.reverseObject=function(t,e){for(var r={},s=0,o=e||Object.keys(t);s13&&(p+=1,o-=12),o-=1,a=p-4716;var y=u-24e5,S=10631/30,b=u-1948084,M=Math.floor(b/10631);b-=10631*M;var w=Math.floor((b-.1335)/S),C=30*M+w;b-=Math.floor(w*S+.1335);var D=Math.floor((b+28.5001)/29.5);13===D&&(D=12);for(var A=b-Math.floor(29.5001*D-29),x=0;xy);x++);var P=x+16260,L=Math.floor((P-1)/12),O=L+1,N=P-12*L,T=y-t[x-1]+1;return(T+"").length>2&&(T=A,N=D,O=C),{year:O,month:N,date:T}},n.toGregorian=function i(r,s,o){var g=Math.floor(o+t[12*(r-1)+1+(s-1)-16260-1]-1+24e5+.5),v=Math.floor((g-1867216.25)/36524.25),y=1524+(v=g+1+v-Math.floor(v/4)),S=Math.floor((y-122.1)/365.25),b=Math.floor(365.25*S),M=Math.floor((y-b)/30.6001),w=y-b-Math.floor(30.6001*M),C=M-(M>13.5?13:1),D=S-(C>2.5?4716:4715);return D<=0&&C--,new Date(D+"/"+C+"/"+w)};var ut,c$=/\/MMMMM|MMMM|MMM|a|LLLL|LLL|EEEEE|EEEE|E|K|cccc|ccc|WW|W|G+|z+/gi,Lz="stand-alone",d$=["sun","mon","tue","wed","thu","fri","sat"],Nz={m:"getMinutes",h:"getHours",H:"getHours",s:"getSeconds",d:"getDate",f:"getMilliseconds"},Oz=function(){function n(){}return n.dateFormat=function(t,e,i){var r=this,s=ut.getDependables(i,t,e.calendar),o=Y("parserObject.numbers",s),a=s.dateObject,l={isIslamic:ut.islamicRegex.test(e.calendar)};ce()&&e.isServerRendered&&(e=ut.compareBlazorDateFormats(e,t));var h=e.format||ut.getResultantPattern(e.skeleton,s.dateObject,e.type,!1,ce()?t:"");if(l.dateSeperator=ce()?Y("dateSeperator",a):ut.getDateSeparator(s.dateObject),st(h))Cg("Format options or type given must be invalid");else{h=ut.ConvertDateToWeekFormat(h),ce()&&(h=h.replace(/tt/,"a")),l.pattern=h,l.numMapper=ce()?ze({},o):Hr.getNumberMapper(s.parserObject,Hr.getNumberingSystem(i));for(var d=0,u=h.match(c$)||[];d2?r+=e.month[""+u]:p=!0;break;case"E":case"c":r+=e.weekday[""+d$[t.getDay()]];break;case"H":case"h":case"m":case"s":case"d":case"f":if(p=!0,"d"===d)u=o.date;else if("f"===d){p=!1,g=!0;var y=(f=(f=t[""+Nz[""+d]]().toString()).substring(0,c)).length;if(c!==y){if(c>3)continue;for(var S=0;S0?1:0],o=Math.abs(t);return s.replace(/HH?|mm/g,function(a){var l=a.length,h=-1!==a.indexOf("H");return i.checkTwodigitNumber(Math.floor(h?o/60:o%60),l)})},n}(),kz={ms:"minimumSignificantDigits",ls:"maximumSignificantDigits",mf:"minimumFractionDigits",lf:"maximumFractionDigits"},tf=["infinity","nan","group","decimal","exponential"],Pz=function(){function n(){}return n.numberFormatter=function(t,e,i){var l,r=this,s=ze({},e),o={},a={},h=ut.getDependables(i,t,"",!0),c=h.numericObject;a.numberMapper=ce()?ze({},c):Hr.getNumberMapper(h.parserObject,Hr.getNumberingSystem(i),!0),a.currencySymbol=ce()?Y("currencySymbol",c):ut.getCurrencySymbol(h.numericObject,s.currency||Tg,e.altSymbol,e.ignoreCurrency),a.percentSymbol=ce()?Y("numberSymbols.percentSign",c):a.numberMapper.numberSymbols.percentSign,a.minusSymbol=ce()?Y("numberSymbols.minusSign",c):a.numberMapper.numberSymbols.minusSign;var d=a.numberMapper.numberSymbols;if(e.format&&!ut.formatRegex.test(e.format))o=ut.customFormat(e.format,a,h.numericObject),!st(s.useGrouping)&&s.useGrouping&&(s.useGrouping=o.pData.useGrouping);else{if(ze(s,ut.getProperNumericSkeleton(e.format||"N")),s.isCurrency="currency"===s.type,s.isPercent="percent"===s.type,ce()||(l=ut.getSymbolPattern(s.type,a.numberMapper.numberSystem,h.numericObject,s.isAccount)),s.groupOne=this.checkValueRange(s.maximumSignificantDigits,s.minimumSignificantDigits,!0),this.checkValueRange(s.maximumFractionDigits,s.minimumFractionDigits,!1,!0),st(s.fractionDigits)||(s.minimumFractionDigits=s.maximumFractionDigits=s.fractionDigits),st(s.useGrouping)&&(s.useGrouping=!0),s.isCurrency&&!ce()&&(l=l.replace(/\u00A4/g,ut.defaultCurrency)),ce())o.nData=ze({},{},Y(s.type+"nData",c)),o.pData=ze({},{},Y(s.type+"pData",c)),"currency"===s.type&&e.currency&&ut.replaceBlazorCurrency([o.pData,o.nData],a.currencySymbol,e.currency);else{var u=l.split(";");o.nData=ut.getFormatData(u[1]||"-"+u[0],!0,a.currencySymbol),o.pData=ut.getFormatData(u[0],!1,a.currencySymbol),s.useGrouping&&(s.groupSeparator=d[tf[2]],s.groupData=this.getGroupingDetails(u[0]))}if(st(s.minimumFractionDigits)&&(s.minimumFractionDigits=o.nData.minimumFraction),st(s.maximumFractionDigits)){var p=o.nData.maximumFraction;s.maximumFractionDigits=st(p)&&s.isPercent?0:p}var g=s.minimumFractionDigits,v=s.maximumFractionDigits;!st(g)&&!st(v)&&g>v&&(s.maximumFractionDigits=g)}return ze(o.nData,s),ze(o.pData,s),function(y){return isNaN(y)?d[tf[1]]:isFinite(y)?r.intNumberFormatter(y,o,a,e):d[tf[0]]}},n.getGroupingDetails=function(t){var e={},i=t.match(ut.negativeDataRegex);if(i&&i[4]){var r=i[4],s=r.lastIndexOf(",");if(-1!==s){var o=r.split(".")[0];e.primary=o.length-s-1;var a=r.lastIndexOf(",",s-1);-1!==a&&(e.secondary=s-1-a)}}return e},n.checkValueRange=function(t,e,i,r){var s=r?"f":"s",o=0,a=kz["l"+s],l=kz["m"+s];if(st(t)||(this.checkRange(t,a,r),o++),st(e)||(this.checkRange(e,l,r),o++),2===o){if(!(tr[1])&&Cg(e+"value must be within the range"+r[0]+"to"+r[1])},n.intNumberFormatter=function(t,e,i,r){var s;if(!st(e.nData.type)){t<0?(t*=-1,s=e.nData):s=0===t&&e.zeroData||e.pData;var o="";if(s.isPercent&&(t*=100),s.groupOne)o=this.processSignificantDigits(t,s.minimumSignificantDigits,s.maximumSignificantDigits);else if(o=this.processFraction(t,s.minimumFractionDigits,s.maximumFractionDigits,r),s.minimumIntegerDigits&&(o=this.processMinimumIntegers(o,s.minimumIntegerDigits)),i.isCustomFormat&&s.minimumFractionDigits=0&&"0"===l[parseInt(c.toString(),10)]&&c>=s.minimumFractionDigits;c--)l=l.slice(0,c);o=a[0]+"."+l}return"scientific"===s.type&&(o=(o=t.toExponential(s.maximumFractionDigits)).replace("e",i.numberMapper.numberSymbols[tf[4]])),o=o.replace(".",i.numberMapper.numberSymbols[tf[3]]),o="#,###,,;(#,###,,)"===s.format?this.customPivotFormat(parseInt(o,10)):o,s.useGrouping&&(o=this.groupNumbers(o,s.groupData.primary,s.groupSeparator||",",i.numberMapper.numberSymbols[tf[3]]||".",s.groupData.secondary)),o=Hr.convertValueParts(o,ut.latnParseRegex,i.numberMapper.mapper),"N/A"===s.nlead?s.nlead:"0"===o&&r&&"0"===r.format?o+s.nend:s.nlead+o+s.nend}},n.processSignificantDigits=function(t,e,i){var r=t+"";return r.lengthe;)c=l.slice(h-e,h)+(c.length?i+c:""),h-=e,o&&(e=s,o=!1);return a[0]=l.slice(0,h)+(c.length?i:"")+c,a.join(r)},n.processFraction=function(t,e,i,r){var s=(t+"").split(".")[1],o=s?s.length:0;if(e&&oi||0===i))return t.toFixed(i);var h=t+"";return"0"===h[0]&&r&&"###.00"===r.format&&(h=h.slice(1)),h},n.processMinimumIntegers=function(t,e){var i=t.split("."),r=i[0],s=r.length;if(s=5e5){var r=(t/=1e6).toString().split(".")[1];return r&&+r.substring(0,1)>=5?Math.ceil(t).toString():Math.floor(t).toString()}return""},n}(),Dg=(new RegExp("^([^0-9]*)(([0-9,]*[0-9]+)(.[0-9]+)?)([Ee][+-]?[0-9]+)?([^0-9]*)$"),function(){function n(t){this.ranArray=[],this.boundedEvents={},!m(t)&&(this.context=t)}return n.prototype.on=function(t,e,i,r){if(!m(e)){var s=i||this.context;if(this.notExist(t))return void(this.boundedEvents[""+t]=[{handler:e,context:s,id:r}]);m(r)?this.isHandlerPresent(this.boundedEvents[""+t],e)||this.boundedEvents[""+t].push({handler:e,context:s}):-1===this.ranArray.indexOf(r)&&(this.ranArray.push(r),this.boundedEvents[""+t].push({handler:e,context:s,id:r}))}},n.prototype.off=function(t,e,i){if(!this.notExist(t)){var r=Y(t,this.boundedEvents);if(e){for(var s=0;s1&&(U.fractionDigits=parseInt(z[2],10)),U}function p(T,z,U,B){var j=B?{}:{nlead:"",nend:""},Q=T.match(n.customRegex);if(Q){B||(j.nlead=g(Q[1],U),j.nend=g(Q[10],U),j.groupPattern=Q[4]);var oe=Q[7];if(oe&&z){var ue=oe.match(t);j.minimumFraction=m(ue)?0:ue.length,j.maximumFraction=oe.length-1}}return j}function g(T,z){return T?(T=T.replace(n.defaultCurrency,z),""===z?T.trim():T):""}function v(T,z,U,B){return B?"$":Y("currencies."+z+(U?"."+U:".symbol"),T)||Y("currencies."+z+".symbol-alt-narrow",T)||"$"}function S(T,z,U){var B={type:"decimal",minimumFractionDigits:0,maximumFractionDigits:0},j=T.match(n.customRegex);if(m(j)||""===j[5]&&"N/A"!==T)return B.type=void 0,B;B.nlead=j[1],B.nend=j[10];var Q=j[6],oe=!!Q.match(/ $/g),ue=-1!==Q.replace(/ $/g,"").indexOf(" ");B.useGrouping=-1!==Q.indexOf(",")||ue,Q=Q.replace(/,/g,"");var fe=j[7];if(-1!==Q.indexOf("0")&&(B.minimumIntegerDigits=Q.length-Q.indexOf("0")),m(fe)||(B.minimumFractionDigits=fe.lastIndexOf("0"),B.maximumFractionDigits=fe.lastIndexOf("#"),-1===B.minimumFractionDigits&&(B.minimumFractionDigits=0),(-1===B.maximumFractionDigits||B.maximumFractionDigitsQ.lastIndexOf("'"))){B[""+a[parseInt(j.toString(),10)]]=Q.substr(0,oe)+U+Q.substr(oe+1),B[""+a[""+z]]=!0,B.type=B.isCurrency?"currency":"percent";break}}return B}function C(T,z){if(-1!==T.indexOf(",")){var U=T.split(",");T=U[0]+Y("numberMapper.numberSymbols.group",z)+U[1].replace(".",Y("numberMapper.numberSymbols.decimal",z))}else T=T.replace(".",Y("numberMapper.numberSymbols.decimal",z));return T}function A(T,z,U){T+=".";for(var B=0;B0;Q-=3)T=","+U[Q-2]+U[Q-1]+U[parseInt(Q.toString(),10)]+T;return T=T.slice(1),z[1]?T+"."+z[1]:T}n.dateParseRegex=/([a-z])\1*|'([^']|'')+'|''|./gi,n.basicPatterns=["short","medium","long","full"],n.defaultObject={dates:{calendars:{gregorian:{months:{"stand-alone":{abbreviated:{1:"Jan",2:"Feb",3:"Mar",4:"Apr",5:"May",6:"Jun",7:"Jul",8:"Aug",9:"Sep",10:"Oct",11:"Nov",12:"Dec"},narrow:{1:"J",2:"F",3:"M",4:"A",5:"M",6:"J",7:"J",8:"A",9:"S",10:"O",11:"N",12:"D"},wide:{1:"January",2:"February",3:"March",4:"April",5:"May",6:"June",7:"July",8:"August",9:"September",10:"October",11:"November",12:"December"}}},days:{"stand-alone":{abbreviated:{sun:"Sun",mon:"Mon",tue:"Tue",wed:"Wed",thu:"Thu",fri:"Fri",sat:"Sat"},narrow:{sun:"S",mon:"M",tue:"T",wed:"W",thu:"T",fri:"F",sat:"S"},short:{sun:"Su",mon:"Mo",tue:"Tu",wed:"We",thu:"Th",fri:"Fr",sat:"Sa"},wide:{sun:"Sunday",mon:"Monday",tue:"Tuesday",wed:"Wednesday",thu:"Thursday",fri:"Friday",sat:"Saturday"}}},dayPeriods:{format:{wide:{am:"AM",pm:"PM"}}},eras:{eraNames:{0:"Before Christ","0-alt-variant":"Before Common Era",1:"Anno Domini","1-alt-variant":"Common Era"},eraAbbr:{0:"BC","0-alt-variant":"BCE",1:"AD","1-alt-variant":"CE"},eraNarrow:{0:"B","0-alt-variant":"BCE",1:"A","1-alt-variant":"CE"}},dateFormats:{full:"EEEE, MMMM d, y",long:"MMMM d, y",medium:"MMM d, y",short:"M/d/yy"},timeFormats:{full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},dateTimeFormats:{full:"{1} 'at' {0}",long:"{1} 'at' {0}",medium:"{1}, {0}",short:"{1}, {0}",availableFormats:{d:"d",E:"ccc",Ed:"d E",Ehm:"E h:mm a",EHm:"E HH:mm",Ehms:"E h:mm:ss a",EHms:"E HH:mm:ss",Gy:"y G",GyMMM:"MMM y G",GyMMMd:"MMM d, y G",GyMMMEd:"E, MMM d, y G",h:"h a",H:"HH",hm:"h:mm a",Hm:"HH:mm",hms:"h:mm:ss a",Hms:"HH:mm:ss",hmsv:"h:mm:ss a v",Hmsv:"HH:mm:ss v",hmv:"h:mm a v",Hmv:"HH:mm v",M:"L",Md:"M/d",MEd:"E, M/d",MMM:"LLL",MMMd:"MMM d",MMMEd:"E, MMM d",MMMMd:"MMMM d",ms:"mm:ss",y:"y",yM:"M/y",yMd:"M/d/y",yMEd:"E, M/d/y",yMMM:"MMM y",yMMMd:"MMM d, y",yMMMEd:"E, MMM d, y",yMMMM:"MMMM y"}}},islamic:{months:{"stand-alone":{abbreviated:{1:"Muh.",2:"Saf.",3:"Rab. I",4:"Rab. II",5:"Jum. I",6:"Jum. II",7:"Raj.",8:"Sha.",9:"Ram.",10:"Shaw.",11:"Dhu\u02bbl-Q.",12:"Dhu\u02bbl-H."},narrow:{1:"1",2:"2",3:"3",4:"4",5:"5",6:"6",7:"7",8:"8",9:"9",10:"10",11:"11",12:"12"},wide:{1:"Muharram",2:"Safar",3:"Rabi\u02bb I",4:"Rabi\u02bb II",5:"Jumada I",6:"Jumada II",7:"Rajab",8:"Sha\u02bbban",9:"Ramadan",10:"Shawwal",11:"Dhu\u02bbl-Qi\u02bbdah",12:"Dhu\u02bbl-Hijjah"}}},days:{"stand-alone":{abbreviated:{sun:"Sun",mon:"Mon",tue:"Tue",wed:"Wed",thu:"Thu",fri:"Fri",sat:"Sat"},narrow:{sun:"S",mon:"M",tue:"T",wed:"W",thu:"T",fri:"F",sat:"S"},short:{sun:"Su",mon:"Mo",tue:"Tu",wed:"We",thu:"Th",fri:"Fr",sat:"Sa"},wide:{sun:"Sunday",mon:"Monday",tue:"Tuesday",wed:"Wednesday",thu:"Thursday",fri:"Friday",sat:"Saturday"}}},dayPeriods:{format:{wide:{am:"AM",pm:"PM"}}},eras:{eraNames:{0:"AH"},eraAbbr:{0:"AH"},eraNarrow:{0:"AH"}},dateFormats:{full:"EEEE, MMMM d, y G",long:"MMMM d, y G",medium:"MMM d, y G",short:"M/d/y GGGGG"},timeFormats:{full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},dateTimeFormats:{full:"{1} 'at' {0}",long:"{1} 'at' {0}",medium:"{1}, {0}",short:"{1}, {0}",availableFormats:{d:"d",E:"ccc",Ed:"d E",Ehm:"E h:mm a",EHm:"E HH:mm",Ehms:"E h:mm:ss a",EHms:"E HH:mm:ss",Gy:"y G",GyMMM:"MMM y G",GyMMMd:"MMM d, y G",GyMMMEd:"E, MMM d, y G",h:"h a",H:"HH",hm:"h:mm a",Hm:"HH:mm",hms:"h:mm:ss a",Hms:"HH:mm:ss",M:"L",Md:"M/d",MEd:"E, M/d",MMM:"LLL",MMMd:"MMM d",MMMEd:"E, MMM d",MMMMd:"MMMM d",ms:"mm:ss",y:"y G",yyyy:"y G",yyyyM:"M/y GGGGG",yyyyMd:"M/d/y GGGGG",yyyyMEd:"E, M/d/y GGGGG",yyyyMMM:"MMM y G",yyyyMMMd:"MMM d, y G",yyyyMMMEd:"E, MMM d, y G",yyyyMMMM:"MMMM y G",yyyyQQQ:"QQQ y G",yyyyQQQQ:"QQQQ y G"}}}},timeZoneNames:{hourFormat:"+HH:mm;-HH:mm",gmtFormat:"GMT{0}",gmtZeroFormat:"GMT"}},numbers:{currencies:{USD:{displayName:"US Dollar",symbol:"$","symbol-alt-narrow":"$"},EUR:{displayName:"Euro",symbol:"\u20ac","symbol-alt-narrow":"\u20ac"},GBP:{displayName:"British Pound","symbol-alt-narrow":"\xa3"}},defaultNumberingSystem:"latn",minimumGroupingDigits:"1","symbols-numberSystem-latn":{decimal:".",group:",",list:";",percentSign:"%",plusSign:"+",minusSign:"-",exponential:"E",superscriptingExponent:"\xd7",perMille:"\u2030",infinity:"\u221e",nan:"NaN",timeSeparator:":"},"decimalFormats-numberSystem-latn":{standard:"#,##0.###"},"percentFormats-numberSystem-latn":{standard:"#,##0%"},"currencyFormats-numberSystem-latn":{standard:"\xa4#,##0.00",accounting:"\xa4#,##0.00;(\xa4#,##0.00)"},"scientificFormats-numberSystem-latn":{standard:"#E0"}}},n.blazorDefaultObject={numbers:{mapper:{0:"0",1:"1",2:"2",3:"3",4:"4",5:"5",6:"6",7:"7",8:"8",9:"9"},mapperDigits:"0123456789",numberSymbols:{decimal:".",group:",",plusSign:"+",minusSign:"-",percentSign:"%",nan:"NaN",timeSeparator:":",infinity:"\u221e"},timeSeparator:":",currencySymbol:"$",currencypData:{nlead:"$",nend:"",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},percentpData:{nlead:"",nend:"%",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},percentnData:{nlead:"-",nend:"%",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},currencynData:{nlead:"($",nend:")",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},decimalnData:{nlead:"-",nend:"",groupData:{primary:3},maximumFraction:2,minimumFraction:2},decimalpData:{nlead:"",nend:"",groupData:{primary:3},maximumFraction:2,minimumFraction:2}},dates:{dayPeriods:{am:"AM",pm:"PM"},dateSeperator:"/",days:{abbreviated:{sun:"Sun",mon:"Mon",tue:"Tue",wed:"Wed",thu:"Thu",fri:"Fri",sat:"Sat"},short:{sun:"Su",mon:"Mo",tue:"Tu",wed:"We",thu:"Th",fri:"Fr",sat:"Sa"},wide:{sun:"Sunday",mon:"Monday",tue:"Tuesday",wed:"Wednesday",thu:"Thursday",fri:"Friday",sat:"Saturday"}},months:{abbreviated:{1:"Jan",2:"Feb",3:"Mar",4:"Apr",5:"May",6:"Jun",7:"Jul",8:"Aug",9:"Sep",10:"Oct",11:"Nov",12:"Dec"},wide:{1:"January",2:"February",3:"March",4:"April",5:"May",6:"June",7:"July",8:"August",9:"September",10:"October",11:"November",12:"December"}},eras:{1:"AD"}}},n.monthIndex={3:"abbreviated",4:"wide",5:"narrow",1:"abbreviated"},n.month="months",n.days="days",n.patternMatcher={C:"currency",P:"percent",N:"decimal",A:"currency",E:"scientific"},n.getResultantPattern=l,n.getDependables=h,n.getSymbolPattern=c,n.ConvertDateToWeekFormat=d,n.compareBlazorDateFormats=u,n.getProperNumericSkeleton=f,n.getFormatData=p,n.changeCurrencySymbol=g,n.getCurrencySymbol=v,n.customFormat=function y(T,z,U){for(var B={},j=T.split(";"),Q=["pData","nData","zeroData"],oe=0;oe1,fe.nData=ce()?Y(De.type+"nData",oe):p(ot[1]||"-"+ot[0],!0,Ie),fe.pData=ce()?Y(De.type+"pData",oe):p(ot[0],!1,Ie),!Me[2]&&!z.minimumFractionDigits&&!z.maximumFractionDigits&&(ue=p(Ve.split(";")[0],!0,"",!0).minimumFraction)}if(n.formatRegex.test(z.format)||!z.format){if(ze(Q,f(z.format||"N")),Q.custom=!1,$e="###0",(Q.fractionDigits||z.minimumFractionDigits||z.maximumFractionDigits||ue)&&(Q.fractionDigits&&(z.minimumFractionDigits=z.maximumFractionDigits=Q.fractionDigits),$e=A($e,ue||Q.fractionDigits||z.minimumFractionDigits||0,z.maximumFractionDigits||0)),z.minimumIntegerDigits&&($e=x($e,z.minimumIntegerDigits)),z.useGrouping&&($e=P($e)),"currency"===Q.type||Q.type&&ce()){ce()&&"currency"!==Q.type&&(fe.pData=Y(Q.type+"pData",oe),fe.nData=Y(Q.type+"nData",oe));var cr=$e;$e=fe.pData.nlead+cr+fe.pData.nend,(fe.hasNegativePattern||ce())&&($e+=";"+fe.nData.nlead+cr+fe.nData.nend)}"percent"===Q.type&&!ce()&&($e+=" %")}else $e=z.format.replace(/'/g,'"');return Object.keys(xe).length>0&&($e=B?$e:C($e,xe)),$e},n.fractionDigitsPattern=A,n.minimumIntegerPattern=x,n.groupingPattern=P,n.getWeekData=function L(T,z){var U="sun",B=Y("supplemental.weekData.firstDay",z),j=T;return/en-/.test(j)&&(j=j.slice(3)),j=j.slice(0,2).toUpperCase()+j.substr(2),B&&(U=B[""+j]||B[j.slice(0,2)]||"sun"),o[""+U]},n.replaceBlazorCurrency=function O(T,z,U){var B=function h$(n){return Y(n||"",l$)}(U);if(z!==B)for(var j=0,Q=T;j=0?U:U+7;var j=Math.floor((T.getTime()-z.getTime()-6e4*(T.getTimezoneOffset()-z.getTimezoneOffset()))/864e5)+1;if(U<4){if((B=Math.floor((j+U-1)/7)+1)>52){var oe=new Date(T.getFullYear()+1,0,1).getDay();B=(oe=oe>=0?oe:oe+7)<4?1:53}}else B=Math.floor((j+U-1)/7);return B}}(ut||(ut={}));var rf=function(){function n(t,e,i){this.type="GET",this.emitError=!0,"string"==typeof t?(this.url=t,this.type=m(e)?this.type:e.toUpperCase(),this.contentType=i):La(t)&&Object.keys(t).length>0&&kn(this,t),this.contentType=m(this.contentType)?"application/json; charset=utf-8":this.contentType}return n.prototype.send=function(t){var e=this,i={"application/json":"json","multipart/form-data":"formData","application/octet-stream":"blob","application/x-www-form-urlencoded":"formData"};try{m(this.fetchRequest)&&"GET"===this.type?this.fetchRequest=new Request(this.url,{method:this.type}):m(this.fetchRequest)&&(this.data=m(t)?this.data:t,this.fetchRequest=new Request(this.url,{method:this.type,headers:{"Content-Type":this.contentType},body:this.data}));var r={cancel:!1,fetchRequest:this.fetchRequest};return this.triggerEvent(this.beforeSend,r),r.cancel?null:(this.fetchResponse=fetch(this.fetchRequest),this.fetchResponse.then(function(s){if(e.triggerEvent(e.onLoad,s),!s.ok)throw s;for(var o="text",a=0,l=Object.keys(i);a-1},n.getValue=function(t,e){var i=typeof window<"u"?window.browserDetails:{};return typeof navigator<"u"&&"MacIntel"===navigator.platform&&navigator.maxTouchPoints>1&&!0===n.isTouch&&!pC.CHROME.test(navigator.userAgent)&&(i.isIos=!0,i.isDevice=!0,i.isTouch=!0,i.isPointer=!0,i.isPointer="pointerEnabled"in window.navigator),typeof window<"u"&&window.Capacitor&&"ios"===window.Capacitor.getPlatform()&&(i.isPointer=!1),typeof i[""+t]>"u"?i[""+t]=e.test(n.userAgent):i[""+t]},Object.defineProperty(n,"userAgent",{get:function(){return n.uA},set:function(t){n.uA=t,window.browserDetails={}},enumerable:!0,configurable:!0}),Object.defineProperty(n,"info",{get:function(){return st(window.browserDetails.info)?window.browserDetails.info=n.extractBrowserDetail():window.browserDetails.info},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isIE",{get:function(){return n.getValue("isIE",E$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isTouch",{get:function(){return st(window.browserDetails.isTouch)?window.browserDetails.isTouch="ontouchstart"in window.navigator||window&&window.navigator&&window.navigator.maxTouchPoints>0||"ontouchstart"in window:window.browserDetails.isTouch},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isPointer",{get:function(){return st(window.browserDetails.isPointer)?window.browserDetails.isPointer="pointerEnabled"in window.navigator:window.browserDetails.isPointer},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isMSPointer",{get:function(){return st(window.browserDetails.isMSPointer)?window.browserDetails.isMSPointer="msPointerEnabled"in window.navigator:window.browserDetails.isMSPointer},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isDevice",{get:function(){return n.getValue("isDevice",C$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isIos",{get:function(){return n.getValue("isIos",x$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isIos7",{get:function(){return n.getValue("isIos7",T$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isAndroid",{get:function(){return n.getValue("isAndroid",A$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isWebView",{get:function(){return st(window.browserDetails.isWebView)&&(window.browserDetails.isWebView=!(st(window.cordova)&&st(window.PhoneGap)&&st(window.phonegap)&&"object"!==window.forge)),window.browserDetails.isWebView},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isWindows",{get:function(){return n.getValue("isWindows",L$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"touchStartEvent",{get:function(){return st(window.browserDetails.touchStartEvent)?window.browserDetails.touchStartEvent=n.getTouchStartEvent():window.browserDetails.touchStartEvent},enumerable:!0,configurable:!0}),Object.defineProperty(n,"touchMoveEvent",{get:function(){return st(window.browserDetails.touchMoveEvent)?window.browserDetails.touchMoveEvent=n.getTouchMoveEvent():window.browserDetails.touchMoveEvent},enumerable:!0,configurable:!0}),Object.defineProperty(n,"touchEndEvent",{get:function(){return st(window.browserDetails.touchEndEvent)?window.browserDetails.touchEndEvent=n.getTouchEndEvent():window.browserDetails.touchEndEvent},enumerable:!0,configurable:!0}),Object.defineProperty(n,"touchCancelEvent",{get:function(){return st(window.browserDetails.touchCancelEvent)?window.browserDetails.touchCancelEvent=n.getTouchCancelEvent():window.browserDetails.touchCancelEvent},enumerable:!0,configurable:!0}),n.uA=typeof navigator<"u"?navigator.userAgent:"",n}(),E=function(){function n(){}return n.addOrGetEventData=function(t){return"__eventList"in t?t.__eventList.events:(t.__eventList={},t.__eventList.events=[])},n.add=function(t,e,i,r,s){var a,o=n.addOrGetEventData(t);a=s?function n$(n,t){var e;return function(){for(var i=this,r=[],s=0;s"u"||(e.innerHTML=t.innerHTML?t.innerHTML:"",void 0!==t.className&&(e.className=t.className),void 0!==t.id&&(e.id=t.id),void 0!==t.styles&&e.setAttribute("style",t.styles),void 0!==t.attrs&&Fe(e,t.attrs)),e}function V(n,t){for(var e=Uz(t),i=RegExp,r=0,s=n;r0}function gl(n,t,e){for(var i=document.createDocumentFragment(),r=0,s=n;r0;)i.appendChild(n[0]);else for(var r=0,s=n;r-1&&!r[parseInt(s.toString(),10)].match(/\[.*\]/)){var o=r[parseInt(s.toString(),10)].split("#");if(o[1].match(/^\d/)||o[1].match(t)){var a=r[parseInt(s.toString(),10)].split(".");a[0]=a[0].replace(/#/,"[id='")+"']",r[parseInt(s.toString(),10)]=a.join(".")}}e[parseInt(i.toString(),10)]=r.join(" ")}return e.join(",")}return n}function J(n,t){var e=n;if("function"==typeof e.closest)return e.closest(t);for(;e&&1===e.nodeType;){if(gC(e,t))return e;e=e.parentNode}return null}function je(n,t){void 0!==t&&Object.keys(t).forEach(function(e){n.style[""+e]=t[""+e]})}function gC(n,t){var e=n.matches||n.msMatchesSelector||n.webkitMatchesSelector;return e?e.call(n,t):-1!==[].indexOf.call(document.querySelectorAll(t),n)}var k$=new RegExp("]"),dh=function(){function n(t,e){this.isRendered=!1,this.isComplexArraySetter=!1,this.isServerRendered=!1,this.allowServerDataBinding=!0,this.isProtectedOnChange=!0,this.properties={},this.changedProperties={},this.oldProperties={},this.bulkChanges={},this.refreshing=!1,this.ignoreCollectionWatch=!1,this.finalUpdate=function(){},this.childChangedProperties={},this.modelObserver=new Dg(this),st(e)||(this.element="string"==typeof e?document.querySelector(e):e,m(this.element)||(this.isProtectedOnChange=!1,this.addInstance())),st(t)||this.setProperties(t,!0),this.isDestroyed=!1}return n.prototype.setProperties=function(t,e){var i=this.isProtectedOnChange;this.isProtectedOnChange=!!e,kn(this,t),!0!==e?(kn(this.changedProperties,t),this.dataBind()):ce()&&this.isRendered&&this.serverDataBind(t),this.finalUpdate(),this.changedProperties={},this.oldProperties={},this.isProtectedOnChange=i},n.callChildDataBind=function(t,e){for(var r=0,s=Object.keys(t);r=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Hs=function(n){function t(i){var r=n.call(this,i,void 0)||this;return r.easing={ease:"cubic-bezier(0.250, 0.100, 0.250, 1.000)",linear:"cubic-bezier(0.250, 0.250, 0.750, 0.750)",easeIn:"cubic-bezier(0.420, 0.000, 1.000, 1.000)",easeOut:"cubic-bezier(0.000, 0.000, 0.580, 1.000)",easeInOut:"cubic-bezier(0.420, 0.000, 0.580, 1.000)",elasticInOut:"cubic-bezier(0.5,-0.58,0.38,1.81)",elasticIn:"cubic-bezier(0.17,0.67,0.59,1.81)",elasticOut:"cubic-bezier(0.7,-0.75,0.99,1.01)"},r}var e;return W$(t,n),e=t,t.prototype.animate=function(i,r){var s=this.getModel(r=r||{});if("string"==typeof i)for(var a=0,l=Array.prototype.slice.call(we(i,document));a0?r-1:0,i+=e=-1!==e?"-"+e:"-"+r}return this.controlParent!==this.parentObj&&(i=this.parentObj.getParentKey()+"."+this.propName+e),i},n}(),X$=["grid","pivotview","treegrid","spreadsheet","rangeNavigator","DocumentEditor","listbox","inplaceeditor","PdfViewer","richtexteditor","DashboardLayout","chart","stockChart","circulargauge","diagram","heatmap","lineargauge","maps","slider","smithchart","barcode","sparkline","treemap","bulletChart","kanban","daterangepicker","schedule","gantt","signature","query-builder","drop-down-tree","carousel","filemanager","uploader","accordion","tab","treeview"],Kz=[115,121,110,99,102,117,115,105,111,110,46,105,115,76,105,99,86,97,108,105,100,97,116,101,100],eR=function(){function n(t){this.isValidated=!1,this.isLicensed=!0,this.version="27",this.platform=/JavaScript|ASPNET|ASPNETCORE|ASPNETMVC|FileFormats|essentialstudio/i,this.errors={noLicense:"This application was built using a trial version of Syncfusion Essential Studio. To remove the license validation message permanently, a valid license key must be included.",trailExpired:"This application was built using a trial version of Syncfusion Essential Studio. To remove the license validation message permanently, a valid license key must be included.",versionMismatched:"The included Syncfusion license key is invalid.",platformMismatched:"The included Syncfusion license key is invalid.",invalidKey:"The included Syncfusion license key is invalid."},this.manager=function(){var e=null;return{setKey:function i(s){e=s},getKey:function r(){return e}}}(),this.npxManager=function(){return{getKey:function i(){return"npxKeyReplace"}}}(),this.manager.setKey(t)}return n.prototype.validate=function(){if(!this.isValidated&&ef&&!Y(C0(Kz),ef)&&!Y("Blazor",ef)){var i=void 0,r=void 0;if(this.manager&&this.manager.getKey()||this.npxManager&&"npxKeyReplace"!==this.npxManager.getKey()){var s=this.getInfoFromKey();if(s&&s.length)for(var o=0,a=s;o"+i+' Claim your FREE account\n
have a Syncfusion account? Sign In
\n
\n ';if(typeof document<"u"&&!m(document)){var t=Si("div",{innerHTML:n});document.body.appendChild(t)}}(),nR=!0),this.render(),this.mount?this.accessMount():this.trigger("created")}},t.prototype.renderComplete=function(e){ce()&&window.sfBlazor.renderComplete(this.element,e),this.isRendered=!0},t.prototype.dataBind=function(){this.injectModules(),n.prototype.dataBind.call(this)},t.prototype.on=function(e,i,r){if("string"==typeof e)this.localObserver.on(e,i,r);else for(var s=0,o=e;s=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},K$={left:0,top:0,bottom:0,right:0},IC={isDragged:!1},eZ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return sR(t,n),vr([I(0)],t.prototype,"left",void 0),vr([I(0)],t.prototype,"top",void 0),t}(Ee),of=function(n){function t(i,r){var s=n.call(this,r,i)||this;return s.dragLimit=e.getDefaultPosition(),s.borderWidth=e.getDefaultPosition(),s.padding=e.getDefaultPosition(),s.diffX=0,s.prevLeft=0,s.prevTop=0,s.dragProcessStarted=!1,s.eleTop=0,s.tapHoldTimer=0,s.externalInitialize=!1,s.diffY=0,s.parentScrollX=0,s.parentScrollY=0,s.droppables={},s.bind(),s}var e;return sR(t,n),e=t,t.prototype.bind=function(){this.toggleEvents(),X.isIE&&V([this.element],"e-block-touch"),this.droppables[this.scope]={}},t.getDefaultPosition=function(){return ze({},K$)},t.prototype.toggleEvents=function(i){var r;st(this.handle)||(r=_(this.handle,this.element));var s=this.enableTapHold&&X.isDevice&&X.isTouch?this.mobileInitialize:this.initialize;i?E.remove(r||this.element,X.isSafari()?"touchstart":X.touchStartEvent,s):E.add(r||this.element,X.isSafari()?"touchstart":X.touchStartEvent,s,this)},t.prototype.mobileInitialize=function(i){var r=this,s=i.currentTarget;this.tapHoldTimer=setTimeout(function(){r.externalInitialize=!0,r.removeTapholdTimer(),r.initialize(i,s)},this.tapHoldThreshold),E.add(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.removeTapholdTimer,this),E.add(document,X.isSafari()?"touchend":X.touchEndEvent,this.removeTapholdTimer,this)},t.prototype.removeTapholdTimer=function(){clearTimeout(this.tapHoldTimer),E.remove(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.removeTapholdTimer),E.remove(document,X.isSafari()?"touchend":X.touchEndEvent,this.removeTapholdTimer)},t.prototype.getScrollableParent=function(i,r){return m(i)?null:i[{vertical:"scrollHeight",horizontal:"scrollWidth"}[""+r]]>i[{vertical:"clientHeight",horizontal:"clientWidth"}[""+r]]&&("vertical"===r?i.scrollTop>0:i.scrollLeft>0)?("vertical"===r?(this.parentScrollY=this.parentScrollY+(0===this.parentScrollY?i.scrollTop:i.scrollTop-this.parentScrollY),this.tempScrollHeight=i.scrollHeight):(this.parentScrollX=this.parentScrollX+(0===this.parentScrollX?i.scrollLeft:i.scrollLeft-this.parentScrollX),this.tempScrollWidth=i.scrollWidth),m(i)?i:this.getScrollableParent(i.parentNode,r)):this.getScrollableParent(i.parentNode,r)},t.prototype.getScrollableValues=function(){this.parentScrollX=0,this.parentScrollY=0,this.element.classList.contains("e-dialog")&&this.element.classList.contains("e-dlg-modal"),this.getScrollableParent(this.element.parentNode,"vertical"),this.getScrollableParent(this.element.parentNode,"horizontal")},t.prototype.initialize=function(i,r){if(this.currentStateTarget=i.target,!this.isDragStarted()){if(this.isDragStarted(!0),this.externalInitialize=!1,this.target=i.currentTarget||r,this.dragProcessStarted=!1,this.abort){var s=this.abort;"string"==typeof s&&(s=[s]);for(var o=0;o=this.distance||this.externalInitialize){var f=this.getHelperElement(i);if(!f||m(f))return;r&&i.preventDefault();var p=this.helperElement=f;if(this.parentClientRect=this.calculateParentPosition(p.offsetParent),this.dragStart){var v={event:i,element:l,target:this.getProperTargetElement(i),bindEvents:ce()?this.bindDragEvents.bind(this):null,dragElement:p};this.trigger("dragStart",v)}this.dragArea?this.setDragArea():(this.dragLimit={left:0,right:0,bottom:0,top:0},this.borderWidth={top:0,left:0}),o={left:this.position.left-this.parentClientRect.left,top:this.position.top-this.parentClientRect.top},this.clone&&!this.enableTailMode&&(this.diffX=this.position.left-this.offset.left,this.diffY=this.position.top-this.offset.top),this.getScrollableValues();var y=getComputedStyle(l),S=parseFloat(y.marginTop);this.clone&&0!==S&&(o.top+=S),this.eleTop=isNaN(parseFloat(y.top))?0:parseFloat(y.top)-this.offset.top,this.enableScrollHandler&&!this.clone&&(o.top-=this.parentScrollY,o.left-=this.parentScrollX);var b=this.getProcessedPositionValue({top:o.top-this.diffY+"px",left:o.left-this.diffX+"px"});this.dragArea&&"string"!=typeof this.dragArea&&this.dragArea.classList.contains("e-kanban-content")&&"relative"===this.dragArea.style.position&&(o.top+=this.dragArea.scrollTop),this.dragElePosition={top:o.top,left:o.left},je(p,this.getDragPosition({position:"absolute",left:b.left,top:b.top})),E.remove(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.intDragStart),E.remove(document,X.isSafari()?"touchend":X.touchEndEvent,this.intDestroy),ce()||this.bindDragEvents(p)}}},t.prototype.bindDragEvents=function(i){Tr(i)?(E.add(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.intDrag,this),E.add(document,X.isSafari()?"touchend":X.touchEndEvent,this.intDragStop,this),this.setGlobalDroppables(!1,this.element,i)):(this.toggleEvents(),document.body.classList.remove("e-prevent-select"))},t.prototype.elementInViewport=function(i){for(this.top=i.offsetTop,this.left=i.offsetLeft,this.width=i.offsetWidth,this.height=i.offsetHeight;i.offsetParent;)this.top+=(i=i.offsetParent).offsetTop,this.left+=i.offsetLeft;return this.top>=window.pageYOffset&&this.left>=window.pageXOffset&&this.top+this.height<=window.pageYOffset+window.innerHeight&&this.left+this.width<=window.pageXOffset+window.innerWidth},t.prototype.getProcessedPositionValue=function(i){return this.queryPositionInfo?this.queryPositionInfo(i):i},t.prototype.calculateParentPosition=function(i){if(m(i))return{left:0,top:0};var r=i.getBoundingClientRect(),s=getComputedStyle(i);return{left:r.left+window.pageXOffset-parseInt(s.marginLeft,10),top:r.top+window.pageYOffset-parseInt(s.marginTop,10)}},t.prototype.intDrag=function(i){if(st(i.changedTouches)||1===i.changedTouches.length){var r,s;this.clone&&i.changedTouches&&X.isDevice&&X.isTouch&&i.preventDefault(),this.position=this.getMousePosition(i,this.isDragScroll);var o=this.getDocumentWidthHeight("Height");oy&&y>0?this.dragLimit.left:this.dragLimit.right+window.pageXOffset0?y-(y-this.dragLimit.right)+window.pageXOffset-M:y<0?this.dragLimit.left:y}if(this.pageY!==v||this.skipDistanceCheck){var w=d.offsetHeight+(parseFloat(b.marginTop)+parseFloat(b.marginBottom));s=this.dragLimit.top>S&&S>0?this.dragLimit.top:this.dragLimit.bottom+window.pageYOffset0?S-(S-this.dragLimit.bottom)+window.pageYOffset-w:S<0?this.dragLimit.top:S}}else r=y,s=S;var A,x,C=f+this.borderWidth.top,D=u+this.borderWidth.left;if(this.dragProcessStarted&&(m(s)&&(s=this.prevTop),m(r)&&(r=this.prevLeft)),this.helperElement.classList.contains("e-treeview"))this.dragArea?(this.dragLimit.top=this.clone?this.dragLimit.top:0,A=s-C<0?this.dragLimit.top:s-this.borderWidth.top,x=r-D<0?this.dragLimit.left:r-this.borderWidth.left):(A=s-this.borderWidth.top,x=r-this.borderWidth.left);else if(this.dragArea){var P=this.helperElement.classList.contains("e-dialog");this.dragLimit.top=this.clone?this.dragLimit.top:0,A=s-C<0?this.dragLimit.top:s-C,x=r-D<0?P?r-(D-this.borderWidth.left):this.dragElePosition.left:r-D}else A=s-C,x=r-D;var L=parseFloat(getComputedStyle(this.element).marginTop);if(L>0&&(this.clone&&(A+=L,S<0&&(L+S>=0?A=L+S:A-=L),this.dragArea&&(A=this.dragLimit.bottom=0){var O=this.dragLimit.top+S-C;O+L+C<0?A-=L+C:A=O}else A-=L+C;this.dragArea&&this.helperElement.classList.contains("e-treeview")&&(A=A+(w=d.offsetHeight+(parseFloat(b.marginTop)+parseFloat(b.marginBottom)))>this.dragLimit.bottom?this.dragLimit.bottom-w:A),this.enableScrollHandler&&!this.clone&&(A-=this.parentScrollY,x-=this.parentScrollX),this.dragArea&&"string"!=typeof this.dragArea&&this.dragArea.classList.contains("e-kanban-content")&&"relative"===this.dragArea.style.position&&(A+=this.dragArea.scrollTop);var N=this.getProcessedPositionValue({top:A+"px",left:x+"px"});this.isPreventScroll&&(N=this.getProcessedPositionValue({top:this.position.top-this.parentClientRect.top-2+"px",left:this.position.left-this.parentClientRect.left-2+"px"})),je(d,this.getDragPosition(N)),!this.elementInViewport(d)&&this.enableAutoScroll&&!this.helperElement.classList.contains("e-treeview")&&this.helperElement.scrollIntoView();var T=document.querySelectorAll(":hover");if(this.enableAutoScroll&&this.helperElement.classList.contains("e-treeview")){0===T.length&&(T=this.getPathElements(i));var z=this.getScrollParent(T,!1);this.elementInViewport(this.helperElement)?this.getScrollPosition(z,A):this.elementInViewport(this.helperElement)||(0===(T=[].slice.call(document.querySelectorAll(":hover"))).length&&(T=this.getPathElements(i)),z=this.getScrollParent(T,!0),this.getScrollPosition(z,A))}this.dragProcessStarted=!0,this.prevLeft=r,this.prevTop=s,this.position.left=r,this.position.top=s,this.pageX=g,this.pageY=v}},t.prototype.getScrollParent=function(i,r){for(var o,s=r?i.reverse():i,a=s.length-1;a>=0;a--)if(("auto"===(o=window.getComputedStyle(s[parseInt(a.toString(),10)])["overflow-y"])||"scroll"===o)&&s[parseInt(a.toString(),10)].scrollHeight>s[parseInt(a.toString(),10)].clientHeight)return s[parseInt(a.toString(),10)];if("visible"===(o=window.getComputedStyle(document.scrollingElement)["overflow-y"]))return document.scrollingElement.style.overflow="auto",document.scrollingElement},t.prototype.getScrollPosition=function(i,r){if(i&&i===document.scrollingElement)i.clientHeight+document.scrollingElement.scrollTop-this.helperElement.clientHeightr?i.scrollTop+=this.helperElement.clientHeight:i.scrollTop>r-this.helperElement.clientHeight&&(i.scrollTop-=this.helperElement.clientHeight);else if(i&&i!==document.scrollingElement){var s=document.scrollingElement.scrollTop,o=this.helperElement.clientHeight;i.clientHeight+i.getBoundingClientRect().top-o+sr-o-s&&(i.scrollTop-=this.helperElement.clientHeight)}},t.prototype.getPathElements=function(i){return document.elementsFromPoint(i.clientX>0?i.clientX:0,i.clientY>0?i.clientY:0)},t.prototype.triggerOutFunction=function(i,r){this.hoverObject.instance.intOut(i,r.target),this.hoverObject.instance.dragData[this.scope]=null,this.hoverObject=null},t.prototype.getDragPosition=function(i){var r=ze({},i);return this.axis&&("x"===this.axis?delete r.top:"y"===this.axis&&delete r.left),r},t.prototype.getDocumentWidthHeight=function(i){var r=document.body,s=document.documentElement;return Math.max(r["scroll"+i],s["scroll"+i],r["offset"+i],s["offset"+i],s["client"+i])},t.prototype.intDragStop=function(i){if(this.dragProcessStarted=!1,st(i.changedTouches)||1===i.changedTouches.length){if(-1!==["touchend","pointerup","mouseup"].indexOf(i.type)){if(this.dragStop){var s=this.getProperTargetElement(i);this.trigger("dragStop",{event:i,element:this.element,target:s,helper:this.helperElement})}this.intDestroy(i)}else this.element.setAttribute("aria-grabbed","false");var o=this.checkTargetElement(i);o.target&&o.instance&&(o.instance.dragStopCalled=!0,o.instance.dragData[this.scope]=this.droppables[this.scope],o.instance.intDrop(i,o.target)),this.setGlobalDroppables(!0),document.body.classList.remove("e-prevent-select")}},t.prototype.intDestroy=function(i){this.dragProcessStarted=!1,this.toggleEvents(),document.body.classList.remove("e-prevent-select"),this.element.setAttribute("aria-grabbed","false"),E.remove(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.intDragStart),E.remove(document,X.isSafari()?"touchend":X.touchEndEvent,this.intDragStop),E.remove(document,X.isSafari()?"touchend":X.touchEndEvent,this.intDestroy),E.remove(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.intDrag),this.isDragStarted()&&this.isDragStarted(!0)},t.prototype.onPropertyChanged=function(i,r){},t.prototype.getModuleName=function(){return"draggable"},t.prototype.isDragStarted=function(i){return i&&(IC.isDragged=!IC.isDragged),IC.isDragged},t.prototype.setDragArea=function(){var i,r,a,s=0,o=0;if(a="string"==typeof this.dragArea?_(this.dragArea):this.dragArea){var h=a.getBoundingClientRect();i=a.scrollWidth?a.scrollWidth:h.right-h.left,r=a.scrollHeight?this.dragArea&&!m(this.helperElement)&&this.helperElement.classList.contains("e-treeview")?a.clientHeight:a.scrollHeight:h.bottom-h.top;for(var c=["Top","Left","Bottom","Right"],d=getComputedStyle(a),u=0;u12;return I0(i.target,this.helperElement)||-1!==i.type.indexOf("touch")||a?(this.helperElement.style.pointerEvents="none",s=document.elementFromPoint(r.clientX,r.clientY),this.helperElement.style.pointerEvents=o):s=i.target,s},t.prototype.currentStateCheck=function(i,r){return m(this.currentStateTarget)||this.currentStateTarget===i?m(r)?i:r:this.currentStateTarget},t.prototype.getMousePosition=function(i,r){var a,l,s=void 0!==i.srcElement?i.srcElement:i.target,o=this.getCoordinates(i),h=m(s.offsetParent);if(r?(a=this.clone?o.pageX:o.pageX+(h?0:s.offsetParent.scrollLeft)-this.relativeXPosition,l=this.clone?o.pageY:o.pageY+(h?0:s.offsetParent.scrollTop)-this.relativeYPosition):(a=this.clone?o.pageX:o.pageX+window.pageXOffset-this.relativeXPosition,l=this.clone?o.pageY:o.pageY+window.pageYOffset-this.relativeYPosition),document.scrollingElement&&!r&&!this.clone){var c=document.scrollingElement;a=c.scrollWidth>0&&c.scrollWidth>c.clientWidth&&c.scrollLeft>0?a-c.scrollLeft:a,l=c.scrollHeight>0&&c.scrollHeight>c.clientHeight&&c.scrollTop>0?l-c.scrollTop:l}return{left:a-(this.margin.left+this.cursorAt.left),top:l-(this.margin.top+this.cursorAt.top)}},t.prototype.getCoordinates=function(i){return i.type.indexOf("touch")>-1?i.changedTouches[0]:i},t.prototype.getHelperElement=function(i){var r;return this.clone?this.helper?r=this.helper({sender:i,element:this.target}):(r=Si("div",{className:"e-drag-helper e-block-touch",innerHTML:"Draggable"}),document.body.appendChild(r)):r=this.element,r},t.prototype.setGlobalDroppables=function(i,r,s){this.droppables[this.scope]=i?null:{draggable:r,helper:s,draggedElement:this.element}},t.prototype.checkTargetElement=function(i){var r=this.getProperTargetElement(i),s=this.getDropInstance(r);if(!s&&r&&!m(r.parentNode)){var o=J(r.parentNode,".e-droppable")||r.parentElement;o&&(s=this.getDropInstance(o))}return{target:r,instance:s}},t.prototype.getDropInstance=function(i){var s,o=i&&i.ej2_instances;if(o)for(var a=0,l=o;a=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},oR=function(n){function t(e,i){var r=n.call(this,i,e)||this;return r.mouseOver=!1,r.dragData={},r.dragStopCalled=!1,r.bind(),r}return tZ(t,n),t.prototype.bind=function(){this.wireEvents()},t.prototype.wireEvents=function(){E.add(this.element,X.isSafari()?"touchend":X.touchEndEvent,this.intDrop,this)},t.prototype.onPropertyChanged=function(e,i){},t.prototype.getModuleName=function(){return"droppable"},t.prototype.intOver=function(e,i){this.mouseOver||(this.trigger("over",{event:e,target:i,dragData:this.dragData[this.scope]}),this.mouseOver=!0)},t.prototype.intOut=function(e,i){this.mouseOver&&(this.trigger("out",{evt:e,target:i}),this.mouseOver=!1)},t.prototype.intDrop=function(e,i){if(this.dragStopCalled){this.dragStopCalled=!1;var a,r=!0,s=this.dragData[this.scope],o=!!s&&s.helper&&Tr(s.helper);o&&(a=this.isDropArea(e,s.helper,i),this.accept&&(r=gC(s.helper,this.accept))),o&&this.drop&&a.canDrop&&r&&this.trigger("drop",{event:e,target:a.target,droppedElement:s.helper,dragData:s}),this.mouseOver=!1}},t.prototype.isDropArea=function(e,i,r){var s={canDrop:!0,target:r||e.target},o="touchend"===e.type;if(o||s.target===i){i.style.display="none";var a=o?e.changedTouches[0]:e,l=document.elementFromPoint(a.clientX,a.clientY);s.canDrop=!1,s.canDrop=I0(l,this.element),s.canDrop&&(s.target=l),i.style.display=""}return s},t.prototype.destroy=function(){E.remove(this.element,X.isSafari()?"touchend":X.touchEndEvent,this.intDrop),n.prototype.destroy.call(this)},af([I()],t.prototype,"accept",void 0),af([I("default")],t.prototype,"scope",void 0),af([H()],t.prototype,"drop",void 0),af([H()],t.prototype,"over",void 0),af([H()],t.prototype,"out",void 0),af([_t],t)}(dh),uo=function(){function n(t,e,i){this.controlName=t,this.localeStrings=e,this.setLocale(i||"en-US")}return n.prototype.setLocale=function(t){var e=this.intGetControlConstant(n.locale,t);this.currentLocale=e||this.localeStrings},n.load=function(t){this.locale=ze(this.locale,t,{},!0)},n.prototype.getConstant=function(t){return m(this.currentLocale[""+t])?this.localeStrings[""+t]||"":this.currentLocale[""+t]},n.prototype.intGetControlConstant=function(t,e){return t[""+e]?t[""+e][this.controlName]:null},n.locale={},n}(),aR=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),fh=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},nZ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return aR(t,n),fh([I(50)],t.prototype,"swipeThresholdDistance",void 0),t}(Ee),sZ=/(Up|Down)/,Fs=function(n){function t(e,i){var r=n.call(this,i,e)||this;return r.touchAction=!0,r.tapCount=0,r.startEvent=function(s){if(!0===r.touchAction){var o=r.updateChangeTouches(s);void 0!==s.changedTouches&&(r.touchAction=!1),r.isTouchMoved=!1,r.movedDirection="",r.startPoint=r.lastMovedPoint={clientX:o.clientX,clientY:o.clientY},r.startEventData=o,r.hScrollLocked=r.vScrollLocked=!1,r.tStampStart=Date.now(),r.timeOutTapHold=setTimeout(function(){r.tapHoldEvent(s)},r.tapHoldThreshold),E.add(r.element,X.touchMoveEvent,r.moveEvent,r),E.add(r.element,X.touchEndEvent,r.endEvent,r),E.add(r.element,X.touchCancelEvent,r.cancelEvent,r)}},r.moveEvent=function(s){var o=r.updateChangeTouches(s);r.movedPoint=o,r.isTouchMoved=!(o.clientX===r.startPoint.clientX&&o.clientY===r.startPoint.clientY);var a={};r.isTouchMoved&&(clearTimeout(r.timeOutTapHold),r.calcScrollPoints(s),a=ze(a,{},{startEvents:r.startEventData,originalEvent:s,startX:r.startPoint.clientX,startY:r.startPoint.clientY,distanceX:r.distanceX,distanceY:r.distanceY,scrollDirection:r.scrollDirection,velocity:r.getVelocity(o)}),r.trigger("scroll",a),r.lastMovedPoint={clientX:o.clientX,clientY:o.clientY})},r.cancelEvent=function(s){clearTimeout(r.timeOutTapHold),clearTimeout(r.timeOutTap),r.tapCount=0,r.swipeFn(s),E.remove(r.element,X.touchCancelEvent,r.cancelEvent)},r.endEvent=function(s){r.swipeFn(s),r.isTouchMoved||"function"==typeof r.tap&&(r.trigger("tap",{originalEvent:s,tapCount:++r.tapCount}),r.timeOutTap=setTimeout(function(){r.tapCount=0},r.tapThreshold)),r.modeclear()},r.swipeFn=function(s){clearTimeout(r.timeOutTapHold),clearTimeout(r.timeOutTap);var o=r.updateChangeTouches(s),a=o.clientX-r.startPoint.clientX,l=o.clientY-r.startPoint.clientY;a=Math.floor(a<0?-1*a:a),l=Math.floor(l<0?-1*l:a),r.isTouchMoved=a>1||l>1,/Firefox/.test(X.userAgent)&&0===o.clientX&&0===o.clientY&&"mouseup"===s.type&&(r.isTouchMoved=!1),r.endPoint=o,r.calcPoints(s);var c={originalEvent:s,startEvents:r.startEventData,startX:r.startPoint.clientX,startY:r.startPoint.clientY,distanceX:r.distanceX,distanceY:r.distanceY,swipeDirection:r.movedDirection,velocity:r.getVelocity(o)};if(r.isTouchMoved){var d=r.swipeSettings.swipeThresholdDistance,u=ze(void 0,r.defaultArgs,c),f=!1,p=r.element,g=r.isScrollable(p),v=sZ.test(r.movedDirection);(dthis.distanceY?i.clientX>this.startPoint.clientX?"Right":"Left":i.clientYthis.distanceY||!0===this.hScrollLocked)&&!1===this.vScrollLocked?(this.scrollDirection=i.clientX>this.lastMovedPoint.clientX?"Right":"Left",this.hScrollLocked=!0):(this.scrollDirection=i.clientY=e[r[0]+s[0]]},t.prototype.updateChangeTouches=function(e){return e.changedTouches&&0!==e.changedTouches.length?e.changedTouches[0]:e},fh([H()],t.prototype,"tap",void 0),fh([H()],t.prototype,"tapHold",void 0),fh([H()],t.prototype,"swipe",void 0),fh([H()],t.prototype,"scroll",void 0),fh([I(350)],t.prototype,"tapThreshold",void 0),fh([I(750)],t.prototype,"tapHoldThreshold",void 0),fh([re({},nZ)],t.prototype,"swipeSettings",void 0),fh([_t],t)}(dh),oZ=new RegExp("\\n|\\r|\\s\\s+","g"),aZ=new RegExp(/'|"/g),lZ=new RegExp("if ?\\("),hZ=new RegExp("else if ?\\("),lR=new RegExp("else"),cZ=new RegExp("for ?\\("),hR=new RegExp("(/if|/for)"),dZ=new RegExp("\\((.*)\\)",""),bC=new RegExp("^[0-9]+$","g"),uZ=new RegExp("[\\w\"'.\\s+]+","g"),fZ=new RegExp('"(.*?)"',"g"),pZ=new RegExp("[\\w\"'@#$.\\s-+]+","g"),cR=new RegExp("\\${([^}]*)}","g"),gZ=/^\..*/gm,MC=/\\/gi,vZ=/\\\\/gi,mZ=new RegExp("[\\w\"'@#$.\\s+]+","g"),yZ=/\window\./gm;function lf(n,t,e,i,r){return!t||bC.test(n)||-1!==i.indexOf(n.split(".")[0])||r||"true"===n||"false"===n?n:e+"."+n}function wC(n,t,e,i){return t&&!bC.test(n)&&-1===i.indexOf(n.split(".")[0])?e+'["'+n:n}function dR(n){return n.match(vZ)?n:n.replace(MC,"\\\\")}function uR(n,t,e,i){if(n=n.trim(),/\window\./gm.test(n))return n;var s=/'|"/gm;return/@|\$|#/gm.test(n)&&(n=wC(n,-1===e.indexOf(n),t,e)+'"]'),gZ.test(n)?function bZ(n,t,e,i){return!t||bC.test(n)||-1!==i.indexOf(n.split(".")[0])||/^\..*/gm.test(n)?n:e+"."+n}(n,!s.test(n)&&-1===e.indexOf(n),t,e):lf(n,!s.test(n)&&-1===e.indexOf(n),t,e,i)}var MZ=/^[\n\r.]+0&&t.forEach(function(e){he(e)})},n.removeJsEvents=function(){var t=this.wrapElement.querySelectorAll("["+pR.join("],[")+"]");t.length>0&&t.forEach(function(e){pR.forEach(function(i){e.hasAttribute(i)&&e.removeAttribute(i)})})},n.removeXssAttrs=function(){var t=this;this.removeAttrs.forEach(function(e,i){var r=t.wrapElement.querySelectorAll(e.selector);r.length>0&&r.forEach("a[href]"===e.selector?function(s){-1!==s.getAttribute(e.attribute).replace(/\t|\s|&/,"").indexOf("javascript:alert")&&s.removeAttribute(e.attribute)}:function(s){s.removeAttribute(e.attribute)})})},n}();function AZ(n){for(var t,e=n.childNodes,i=0;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Jo_RTL=(new Dg,"e-rtl"),ys=function(n){function t(e,i){return n.call(this,e,i)||this}return OZ(t,n),t.prototype.preRender=function(){},t.prototype.render=function(){this.initialize(),this.removeRippleEffect=function ms(n,t,e){var i=function Y$(n){return{selector:n&&n.selector?n.selector:null,ignore:n&&n.ignore?n.ignore:null,rippleFlag:n&&n.rippleFlag,isCenterRipple:n&&n.isCenterRipple,duration:n&&n.duration?n.duration:350}}(t);return!1===i.rippleFlag||void 0===i.rippleFlag&&!Zo?function(){}:(n.setAttribute("data-ripple","true"),E.add(n,"mousedown",qz,{parent:n,rippleOptions:i}),E.add(n,"mouseup",$z,{parent:n,rippleOptions:i,done:e}),E.add(n,"mouseleave",sf,{parent:n,rippleOptions:i}),X.isPointer&&E.add(n,"transitionend",sf,{parent:n,rippleOptions:i}),function(){n.removeAttribute("data-ripple"),E.remove(n,"mousedown",qz),E.remove(n,"mouseup",$z),E.remove(n,"mouseleave",sf),E.remove(n,"transitionend",sf)})}(this.element,{selector:".e-btn"}),this.renderComplete()},t.prototype.initialize=function(){if(this.cssClass&&V([this.element],this.cssClass.replace(/\s+/g," ").trim().split(" ")),this.isPrimary&&this.element.classList.add("e-primary"),!ce()||ce()&&"progress-btn"!==this.getModuleName()){if(this.content){var e=this.enableHtmlSanitizer?Ai.sanitize(this.content):this.content;this.element.innerHTML=e}this.setIconCss()}this.enableRtl&&this.element.classList.add(Jo_RTL),this.disabled?this.controlStatus(this.disabled):this.wireEvents()},t.prototype.controlStatus=function(e){this.element.disabled=e},t.prototype.setIconCss=function(){if(this.iconCss){var e=this.createElement("span",{className:"e-btn-icon "+this.iconCss});this.element.textContent.trim()?(e.classList.add("e-icon-"+this.iconPosition.toLowerCase()),("Top"===this.iconPosition||"Bottom"===this.iconPosition)&&this.element.classList.add("e-"+this.iconPosition.toLowerCase()+"-icon-btn")):this.element.classList.add("e-icon-btn");var i=this.element.childNodes[0];!i||"Left"!==this.iconPosition&&"Top"!==this.iconPosition?this.element.appendChild(e):this.element.insertBefore(e,i)}},t.prototype.wireEvents=function(){this.isToggle&&E.add(this.element,"click",this.btnClickHandler,this)},t.prototype.unWireEvents=function(){this.isToggle&&E.remove(this.element,"click",this.btnClickHandler)},t.prototype.btnClickHandler=function(){this.element.classList.contains("e-active")?this.element.classList.remove("e-active"):this.element.classList.add("e-active")},t.prototype.destroy=function(){var e=["e-primary",Jo_RTL,"e-icon-btn","e-success","e-info","e-danger","e-warning","e-flat","e-outline","e-small","e-bigger","e-active","e-round","e-top-icon-btn","e-bottom-icon-btn"];this.cssClass&&(e=e.concat(this.cssClass.split(" "))),n.prototype.destroy.call(this),K([this.element],e),this.element.getAttribute("class")||this.element.removeAttribute("class"),this.disabled&&this.element.removeAttribute("disabled"),this.content&&(this.element.innerHTML=this.element.innerHTML.replace(this.content,""));var i=this.element.querySelector("span.e-btn-icon");i&&he(i),this.unWireEvents(),Zo&&this.removeRippleEffect()},t.prototype.getModuleName=function(){return"btn"},t.prototype.getPersistData=function(){return this.addOnPersist([])},t.Inject=function(){},t.prototype.onPropertyChanged=function(e,i){for(var r=this.element.querySelector("span.e-btn-icon"),s=0,o=Object.keys(e);s=ad.width?ad.width:0;return yl.right+WR()-n}function lE(){return z0()+yl.width/2}function hE(n,t,e,i){if(void 0===t&&(t=null),void 0===e&&(e={X:!1,Y:!1}),!e.Y&&!e.X)return{left:0,top:0};var r=n.getBoundingClientRect();if(po=t,oc=n.ownerDocument,i||(i=ns(n,"left","top")),e.X){var s=po?qR():e4(),o=pE(),a=gE(),l=o-i.left,h=i.left+r.width-a;r.width>s?i.left=l>0&&h<=0?a-r.width:h>0&&l<=0?o:l>h?a-r.width:o:l>0?i.left+=l:h>0&&(i.left-=h)}if(e.Y){var c=po?$R():KR(),d=fE(),u=vE(),f=d-i.top,p=i.top+r.height-u;r.height>c?i.top=f>0&&p<=0?u-r.height:p>0&&f<=0?d:f>p?u-r.height:d:f>0?i.top+=f:p>0&&(i.top-=p)}return i}function ac(n,t,e,i){void 0===t&&(t=null);var r=ns(n,"left","top");e&&(r.left=e),i&&(r.top=i);var s=[];po=t,oc=n.ownerDocument;var o=n.getBoundingClientRect(),l=r.left,h=r.left+o.width,d=uE(r.top,r.top+o.height),u=QR(l,h);return d.topSide&&s.push("top"),u.rightSide&&s.push("right"),u.leftSide&&s.push("left"),d.bottomSide&&s.push("bottom"),s}function lJ(n,t,e,i,r,s,o,a,l){if(void 0===o&&(o=null),void 0===a&&(a={X:!0,Y:!0}),t&&n&&r&&s&&(a.X||a.Y)){var d,h={TL:null,TR:null,BL:null,BR:null},c={TL:null,TR:null,BL:null,BR:null};if("none"===window.getComputedStyle(n).display){var u=n.style.visibility;n.style.visibility="hidden",n.style.display="block",d=n.getBoundingClientRect(),n.style.removeProperty("display"),n.style.visibility=u}else d=n.getBoundingClientRect();var f={posX:r,posY:s,offsetX:e,offsetY:i,position:{left:0,top:0}};po=o,oc=t.ownerDocument,function cJ(n,t,e,i,r){e.position=ns(n,e.posX,e.posY,i,r),t.TL=ns(n,"left","top",i,r),t.TR=ns(n,"right","top",i,r),t.BR=ns(n,"left","bottom",i,r),t.BL=ns(n,"right","bottom",i,r)}(t,h,f,l,d),dE(c,f,d),a.X&&GR(t,c,h,f,d,!0),a.Y&&h.TL.top>-1&&XR(t,c,h,f,d,!0),function hJ(n,t,e){var i=0,r=0;if(null!=n.offsetParent&&("absolute"===getComputedStyle(n.offsetParent).position||"relative"===getComputedStyle(n.offsetParent).position)){var s=ns(n.offsetParent,"left","top",!1,e);i=s.left,r=s.top}var o=1,a=1,l=YR(n);if(l){var h=getComputedStyle(l).transform;if("none"!==h){var c=new DOMMatrix(h);o=c.a,a=c.d}if("none"!==getComputedStyle(l).zoom){var u=cE(document.body);o*=u,a*=u}}n.style.top=t.position.top/a+t.offsetY-r/a+"px",n.style.left=t.position.left/o+t.offsetX-i/o+"px"}(n,f,d)}}function cE(n){var t=getComputedStyle(n).zoom;return parseFloat(t)||1}function YR(n){for(;n;){var t=window.getComputedStyle(n).transform,e=cE(document.body);if(t&&"none"!==t||e&&1!==e)return n;if(n===document.body)return null;n=n.offsetParent||n.parentElement}return null}function dE(n,t,e){n.TL={top:t.position.top+t.offsetY,left:t.position.left+t.offsetX},n.TR={top:n.TL.top,left:n.TL.left+e.width},n.BL={top:n.TL.top+e.height,left:n.TL.left},n.BR={top:n.TL.top+e.height,left:n.TL.left+e.width}}function QR(n,t){var e=!1,i=!1;return n-H0()gE()&&(i=!0),{leftSide:e,rightSide:i}}function GR(n,t,e,i,r,s){var o=QR(t.TL.left,t.TR.left),a=uE(t.TL.top,t.BL.top);e.TL.left-H0()<=pE()&&(o.leftSide=!1),e.TR.left>gE()&&(o.rightSide=!1),(o.leftSide&&!o.rightSide||!o.leftSide&&o.rightSide)&&(i.posX="right"===i.posX?"left":"right",i.offsetX=i.offsetX+r.width,i.offsetX=-1*i.offsetX,i.position=ns(n,i.posX,i.posY,!1),dE(t,i,r),s&&GR(n,t,e,i,r,!1),!o.leftSide&&o.rightSide&&a.bottomSide&&(i.offsetX=0))}function XR(n,t,e,i,r,s){var o=uE(t.TL.top,t.BL.top);e.TL.top-R0()<=fE()&&(o.topSide=!1),e.BL.top>=vE()&&n.getBoundingClientRect().bottomvE()&&(i=!0),{topSide:e,bottomSide:i}}function qR(){return po.getBoundingClientRect().width}function $R(){return po.getBoundingClientRect().height}function ZR(){return po.getBoundingClientRect().left}function JR(){return po.getBoundingClientRect().top}function fE(){return po?JR():0}function pE(){return po?ZR():0}function gE(){return po?H0()+ZR()+qR():H0()+e4()}function vE(){return po?R0()+JR()+$R():R0()+KR()}function R0(){return oc.documentElement.scrollTop||oc.body.scrollTop}function H0(){return oc.documentElement.scrollLeft||oc.body.scrollLeft}function KR(){return window.innerHeight}function e4(){var n=window.innerWidth,t=document.documentElement.getBoundingClientRect();return n-(n-(m(document.documentElement)?0:t.width))}function t4(){po=null,oc=null}var i4=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),bn=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},r4=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return i4(t,n),bn([I("left")],t.prototype,"X",void 0),bn([I("top")],t.prototype,"Y",void 0),t}(Ee),qn_OPEN="e-popup-open",qn_CLOSE="e-popup-close",lc=function(n){function t(e,i){return n.call(this,i,e)||this}return i4(t,n),t.prototype.onPropertyChanged=function(e,i){for(var r=0,s=Object.keys(e);r0&&c.left>0&&c.right>0&&c.bottom>0}var s=i.getBoundingClientRect();return!(r.bottoms.bottom||r.right>s.right||r.leftr.top?this.element.style.top="0px":s.bottomr.left&&(this.element.style.left=parseInt(this.element.style.left,10)+(s.left-r.left)+"px"))}},t.prototype.checkCollision=function(){var e=this.collision.X,i=this.collision.Y;"none"===e&&"none"===i||("flip"===e&&"flip"===i?this.callFlip({X:!0,Y:!0}):"fit"===e&&"fit"===i?this.callFit({X:!0,Y:!0}):("flip"===e?this.callFlip({X:!0,Y:!1}):"flip"===i&&this.callFlip({Y:!0,X:!1}),"fit"===e?this.callFit({X:!0,Y:!1}):"fit"===i&&this.callFit({X:!1,Y:!0})))},t.prototype.show=function(e,i){var r=this;if(this.getRelateToElement().classList.contains("e-filemanager")&&(this.fmDialogContainer=this.element.getElementsByClassName("e-file-select-wrap")[0]),this.wireEvents(),!m(this.fmDialogContainer)&&X.isIos&&(this.fmDialogContainer.style.display="block"),1e3===this.zIndex||!m(i)){var o=m(i)?this.element:i;this.zIndex=hc(o),je(this.element,{zIndex:this.zIndex})}e=m(e)||"object"!=typeof e?this.showAnimation:e,("none"!==this.collision.X||"none"!==this.collision.Y)&&(K([this.element],qn_CLOSE),V([this.element],qn_OPEN),this.checkCollision(),K([this.element],qn_OPEN),V([this.element],qn_CLOSE)),m(e)?(K([this.element],qn_CLOSE),V([this.element],qn_OPEN),this.trigger("open")):(e.begin=function(){r.isDestroyed||(K([r.element],qn_CLOSE),V([r.element],qn_OPEN))},e.end=function(){r.isDestroyed||r.trigger("open")},new Hs(e).animate(this.element))},t.prototype.hide=function(e){var i=this;e=m(e)||"object"!=typeof e?this.hideAnimation:e,m(e)?(K([this.element],qn_OPEN),V([this.element],qn_CLOSE),this.trigger("close")):(e.end=function(){i.isDestroyed||(K([i.element],qn_OPEN),V([i.element],qn_CLOSE),i.trigger("close"))},new Hs(e).animate(this.element)),this.unwireEvents()},t.prototype.getScrollableParent=function(e){return this.checkFixedParent(e),function mE(n,t){for(var e=getComputedStyle(n),i=[],r=/(auto|scroll)/,s=n.parentElement;s&&"HTML"!==s.tagName;){var o=getComputedStyle(s);!("absolute"===e.position&&"static"===o.position)&&r.test(o.overflow+o.overflowY+o.overflowX)&&i.push(s),s=s.parentElement}return t||i.push(document),i}(e,this.fixedParent)},t.prototype.checkFixedParent=function(e){for(var i=e.parentElement;i&&"HTML"!==i.tagName;){var r=getComputedStyle(i);("fixed"===r.position||"sticky"===r.position)&&!m(this.element)&&this.element.offsetParent&&"BODY"===this.element.offsetParent.tagName&&"hidden"!==getComputedStyle(this.element.offsetParent).overflow&&(this.element.style.top=window.scrollY>parseInt(this.element.style.top,10)?Re(window.scrollY-parseInt(this.element.style.top,10)):Re(parseInt(this.element.style.top,10)-window.scrollY),this.element.style.position="fixed",this.fixedParent=!0),i=i.parentElement,!m(this.element)&&m(this.element.offsetParent)&&"fixed"===r.position&&"fixed"===this.element.style.position&&(this.fixedParent=!0)}},bn([I("auto")],t.prototype,"height",void 0),bn([I("auto")],t.prototype,"width",void 0),bn([I(null)],t.prototype,"content",void 0),bn([I("container")],t.prototype,"targetType",void 0),bn([I(null)],t.prototype,"viewPortElement",void 0),bn([I({X:"none",Y:"none"})],t.prototype,"collision",void 0),bn([I("")],t.prototype,"relateTo",void 0),bn([re({},r4)],t.prototype,"position",void 0),bn([I(0)],t.prototype,"offsetX",void 0),bn([I(0)],t.prototype,"offsetY",void 0),bn([I(1e3)],t.prototype,"zIndex",void 0),bn([I(!1)],t.prototype,"enableRtl",void 0),bn([I("reposition")],t.prototype,"actionOnScroll",void 0),bn([I(null)],t.prototype,"showAnimation",void 0),bn([I(null)],t.prototype,"hideAnimation",void 0),bn([H()],t.prototype,"open",void 0),bn([H()],t.prototype,"close",void 0),bn([H()],t.prototype,"targetExitViewport",void 0),bn([_t],t)}(Ii);function hc(n){for(var t=n.parentElement,e=[];t&&"BODY"!==t.tagName;){var i=document.defaultView.getComputedStyle(t,null).getPropertyValue("z-index"),r=document.defaultView.getComputedStyle(t,null).getPropertyValue("position");"auto"!==i&&"static"!==r&&e.push(i),t=t.parentElement}for(var s=[],o=0;o2147483647?2147483647:c}var Ui,ka,hf,yh,bE,Sh,$t,Ih,yE=["north-west","north","north-east","west","east","south-west","south","south-east"],_g="e-resize-handle",cc="e-focused-handle",dJ="e-dlg-resizable",n4=["e-restrict-left"],s4="e-resize-viewport",uJ=["north","west","east","south"],SE=0,IE=0,o4=0,a4=0,Ug=0,jg=0,Vg=null,ME=null,wE=null,B0=!0,l4=0,CE=!0;function pJ(n){EE();var t=Si("span",{attrs:{unselectable:"on",contenteditable:"false"}});t.setAttribute("class","e-dialog-border-resize e-"+n),"south"===n&&(t.style.height="2px",t.style.width="100%",t.style.bottom="0px",t.style.left="0px"),"north"===n&&(t.style.height="2px",t.style.width="100%",t.style.top="0px",t.style.left="0px"),"east"===n&&(t.style.height="100%",t.style.width="2px",t.style.right="0px",t.style.top="0px"),"west"===n&&(t.style.height="100%",t.style.width="2px",t.style.left="0px",t.style.top="0px"),Ui.appendChild(t)}function h4(n){var t;return m(n)||(t="string"==typeof n?document.querySelector(n):n),t}function c4(n){for(var t=n||this,e=Ui.querySelectorAll("."+_g),i=0;i-1?"mouse":"touch"}function u4(n){if(n.preventDefault(),Ui=n.target.parentElement,EE(),Ug=n.pageX,jg=n.pageY,n.target.classList.add(cc),m(Vg)||!0!==Vg(n,this)){this.targetEle&&Ui&&Ui.querySelector("."+dJ)&&($t="body"===this.target?null:this.targetEle,Sh=this.targetEle.clientWidth,yh=this.targetEle.clientHeight);var e=m($t)?document:$t;E.add(e,"mousemove",Wg,this),E.add(document,"mouseup",F0,this);for(var i=0;i=0||s.top<0)&&(e=!0):e=!0;var a=IE+(r-jg);a=a>hf?a:hf;var l=0;m($t)||(l=o.top);var h=m($t)?0:$t.offsetHeight-$t.clientHeight,c=s.top-l-h/2;if(c=c<0?0:c,s.top>0&&c+a>yh){if(e=!1,Ui.classList.contains(s4))return;Ui.style.height=yh-parseInt(c.toString(),10)+"px"}else{var d=0;if(e){s.top<0&&t+(s.height+s.top)>0&&a+(d=s.top)<=30&&(a=s.height-(s.height+s.top)+30),a+s.top>=yh&&(Ui.style.height=s.height+(t-(s.height+s.top))+"px");var u=m($t)?d:c;a>=hf&&a+u<=yh&&(Ui.style.height=a+"px")}}}function xE(n){var e,t=!1,i="mouse"===d4(n.type)?n.pageY:n.touches[0].pageY,r=dc(Ui),s=m($t)?0:$t.offsetHeight-$t.clientHeight;m($t)||(e=dc($t)),(!m($t)&&r.top-e.top>0||m($t)&&i>0||!m($t)&&Math.floor(r.top-e.top+r.height+(e.bottom-r.bottom))-s<=yh)&&(t=!0);var o=IE-(i-jg);if(t&&o>=hf&&o<=yh){var a=0;m($t)||(a=e.top);var l=a4-a+(i-jg);l=l>0?l:1,Ui.style.height=o+"px",Ui.style.top=l+"px"}}function TE(n){var i,t=document.documentElement.clientWidth,e=!1;m($t)||(i=dc($t));var r="mouse"===d4(n.type)?n.pageX:n.touches[0].pageX,s=dc(Ui),o=m($t)?0:$t.offsetWidth-$t.clientWidth,a=m($t)?0:i.left,l=m($t)?0:i.width;m(Ih)&&(m($t)?Ih=t:(Ih=s.left-a-o/2+s.width,Ih+=l-o-Ih)),(!m($t)&&Math.floor(s.left-i.left+s.width+(i.right-s.right))-o<=Sh||m($t)&&r>=0)&&(e=!0);var h=SE-(r-Ug);if(B0&&(h=h>Ih?Ih:h),e&&h>=bE&&h<=Sh){var c=0;m($t)||(c=i.left);var d=o4-c+(r-Ug);d=d>0?d:1,h!==l4&&CE&&(Ui.style.width=h+"px"),B0&&(Ui.style.left=d+"px",CE=1!==d)}l4=h}function AE(n){var i,t=document.documentElement.clientWidth,e=!1;m($t)||(i=dc($t));var s=(n.touches?n.changedTouches[0]:n).pageX,o=dc(Ui);(!m($t)&&(o.left-i.left+o.width<=Sh||o.right-i.left>=o.width)||m($t)&&t-s>0)&&(e=!0);var a=SE+(s-Ug),l=0;if(m($t)||(l=i.left),o.left-l+a>Sh){if(e=!1,Ui.classList.contains(s4))return;Ui.style.width=Sh-(o.left-l)+"px"}e&&a>=bE&&a<=Sh&&(Ui.style.width=a+"px")}function p4(){for(var n=Ui.querySelectorAll("."+_g),t=0;t=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},SJ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return LE(t,n),Zt([I(!0)],t.prototype,"isFlat",void 0),Zt([I()],t.prototype,"buttonModel",void 0),Zt([I("Button")],t.prototype,"type",void 0),Zt([H()],t.prototype,"click",void 0),t}(Ee),IJ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return LE(t,n),Zt([I("Fade")],t.prototype,"effect",void 0),Zt([I(400)],t.prototype,"duration",void 0),Zt([I(0)],t.prototype,"delay",void 0),t}(Ee),_0="e-dialog",NE="e-rtl",OE="e-dlg-header-content",g4="e-dlg-header",U0="e-footer-content",j0="e-dlg-modal",v4="e-icon-dlg-close",Pa="e-dlg-target",ea="e-scroll-disabled",m4="e-device",V0="e-dlg-fullscreen",y4="e-dlg-closeicon-btn",S4="e-popup-open",I4="Information",b4="e-scroll-disabled",M4="e-alert-dialog",w4="e-confirm-dialog",kE="e-dlg-resizable",cf="e-restrict-left",C4="e-resize-viewport",PE="user action",kJ=function(n){function t(e,i){var r=n.call(this,e,i)||this;return r.needsID=!0,r}return LE(t,n),t.prototype.render=function(){this.initialize(),this.initRender(),this.wireEvents(),"100%"===this.width&&(this.element.style.width=""),""!==this.minHeight&&(this.element.style.minHeight=Re(this.minHeight)),this.enableResize&&(this.setResize(),this.isModal&&(this.isModelResize=!0),"None"===this.animationSettings.effect&&this.getMinHeight()),this.renderComplete()},t.prototype.initializeValue=function(){this.dlgClosedBy=PE},t.prototype.preRender=function(){var e=this;if(this.initializeValue(),this.headerContent=null,this.allowMaxHeight=!0,this.preventVisibility=!0,this.clonedEle=this.element.cloneNode(!0),this.closeIconClickEventHandler=function(s){e.dlgClosedBy="close icon",e.hide(s)},this.dlgOverlayClickEventHandler=function(s){e.dlgClosedBy="overlayClick",s.preventFocus=!1,e.trigger("overlayClick",s,function(o){o.preventFocus||e.focusContent(),e.dlgClosedBy=PE})},this.l10n=new uo("dialog",{close:"Close"},this.locale),this.checkPositionData(),m(this.target)){var r=this.isProtectedOnChange;this.isProtectedOnChange=!0,this.target=document.body,this.isProtectedOnChange=r}},t.prototype.updatePersistData=function(){this.enablePersistence&&this.setProperties({width:parseFloat(this.element.style.width),height:parseFloat(this.element.style.height),position:{X:parseFloat(this.dragObj.element.style.left),Y:parseFloat(this.dragObj.element.style.top)}},!0)},t.prototype.isNumberValue=function(e){return/^[-+]?\d*\.?\d+$/.test(e)},t.prototype.checkPositionData=function(){if(!m(this.position)){if(!m(this.position.X)&&"number"!=typeof this.position.X&&this.isNumberValue(this.position.X)){var i=this.isProtectedOnChange;this.isProtectedOnChange=!0,this.position.X=parseFloat(this.position.X),this.isProtectedOnChange=i}m(this.position.Y)||"number"==typeof this.position.Y||this.isNumberValue(this.position.Y)&&(i=this.isProtectedOnChange,this.isProtectedOnChange=!0,this.position.Y=parseFloat(this.position.Y),this.isProtectedOnChange=i)}},t.prototype.getEle=function(e,i){for(var r=void 0,s=0;s=0&&t[e])pJ(t[e]);else if(""!==t[e].trim()){var i=Si("div",{className:"e-icons "+_g+" e-"+t[e]});Ui.appendChild(i)}hf=n.minHeight,bE=n.minWidth,Sh=n.maxWidth,yh=n.maxHeight,n.proxy&&n.proxy.element&&n.proxy.element.classList.contains("e-dialog")?c4(n.proxy):c4()}({element:this.element,direction:r,minHeight:parseInt(e.slice(0,i.indexOf("p")),10),maxHeight:this.targetEle.clientHeight,minWidth:parseInt(i.slice(0,i.indexOf("p")),10),maxWidth:this.targetEle.clientWidth,boundary:this.target===document.body?null:this.targetEle,resizeBegin:this.onResizeStart.bind(this),resizeComplete:this.onResizeComplete.bind(this),resizing:this.onResizing.bind(this),proxy:this}),this.wireWindowResizeEvent()}else p4(),this.unWireWindowResizeEvent(),this.element.classList.remove(this.isModal?cf:C4),this.element.classList.remove(kE)},t.prototype.getFocusElement=function(e){var r=e.querySelectorAll('input,select,textarea,button:enabled,a,[contenteditable="true"],[tabindex]');return{element:r[r.length-1]}},t.prototype.keyDown=function(e){var i=this;if(9===e.keyCode&&this.isModal){var r=void 0;m(this.btnObj)||(r=this.btnObj[this.btnObj.length-1]),m(this.btnObj)&&!m(this.ftrTemplateContent)&&(r=this.getFocusElement(this.ftrTemplateContent)),m(this.btnObj)&&m(this.ftrTemplateContent)&&!m(this.contentEle)&&(r=this.getFocusElement(this.contentEle)),!m(r)&&document.activeElement===r.element&&!e.shiftKey&&(e.preventDefault(),this.focusableElements(this.element).focus()),document.activeElement===this.focusableElements(this.element)&&e.shiftKey&&(e.preventDefault(),m(r)||r.element.focus())}var h,s=document.activeElement,o=["input","textarea"].indexOf(s.tagName.toLowerCase())>-1,a=!1;if(o||(a=s.hasAttribute("contenteditable")&&"true"===s.getAttribute("contenteditable")),27===e.keyCode&&this.closeOnEscape){this.dlgClosedBy="escape";var l=document.querySelector(".e-popup-open:not(.e-dialog)");!m(l)&&!l.classList.contains("e-toolbar-pop")&&!l.classList.contains("e-slider-tooltip")||this.hide(e)}(13===e.keyCode&&!e.ctrlKey&&"textarea"!==s.tagName.toLowerCase()&&o&&!m(this.primaryButtonEle)||13===e.keyCode&&e.ctrlKey&&("textarea"===s.tagName.toLowerCase()||a)&&!m(this.primaryButtonEle))&&this.buttons.some(function(d,u){h=u;var f=d.buttonModel;return!m(f)&&!0===f.isPrimary})&&"function"==typeof this.buttons[h].click&&setTimeout(function(){i.buttons[h].click.call(i,e)})},t.prototype.initialize=function(){m(this.target)||(this.targetEle="string"==typeof this.target?document.querySelector(this.target):this.target),this.isBlazorServerRender()||V([this.element],_0),X.isDevice&&V([this.element],m4),this.isBlazorServerRender()||this.setCSSClass(),this.setMaxHeight()},t.prototype.initRender=function(){var e=this;if(this.initialRender=!0,this.isBlazorServerRender()||Fe(this.element,{role:"dialog"}),1e3===this.zIndex?(this.setzIndex(this.element,!1),this.calculatezIndex=!0):this.calculatezIndex=!1,this.setTargetContent(),""!==this.header&&!m(this.header)&&this.setHeader(),this.renderCloseIcon(),this.setContent(),""===this.footerTemplate||m(this.footerTemplate)?!m(this.buttons[0])&&!m(this.buttons[0].buttonModel)&&this.setButton():this.setFooterTemplate(),this.allowDragging&&!m(this.headerContent)&&this.setAllowDragging(),Fe(this.element,{"aria-modal":this.isModal?"true":"false"}),this.isModal&&this.setIsModal(),!0!==this.element.classList.contains(M4)&&!0!==this.element.classList.contains(w4)&&!m(this.element.parentElement)){var i=this.isModal?this.dlgContainer.parentElement:this.element.parentElement;this.refElement=this.createElement("div",{className:"e-dlg-ref-element"}),i.insertBefore(this.refElement,this.isModal?this.dlgContainer:this.element)}if(m(this.targetEle)||this.targetEle.appendChild(this.isModal?this.dlgContainer:this.element),this.popupObj=new lc(this.element,{height:this.height,width:this.width,zIndex:this.zIndex,relateTo:this.target,actionOnScroll:"none",enableRtl:this.enableRtl,open:function(o){var a={container:e.isModal?e.dlgContainer:e.element,element:e.element,target:e.target,preventFocus:!1};e.enableResize&&e.resetResizeIcon(),e.trigger("open",a,function(l){l.preventFocus||e.focusContent()})},close:function(o){e.isModal&&V([e.dlgOverlay],"e-fade"),e.unBindEvent(e.element),e.isModal&&(e.dlgContainer.style.display="none"),e.trigger("close",e.closeArgs);var a=document.activeElement;!m(a)&&!m(a.blur)&&a.blur(),!m(e.storeActiveElement)&&!m(e.storeActiveElement.focus)&&e.storeActiveElement.focus()}}),this.positionChange(),this.setEnableRTL(),this.isBlazorServerRender()||(V([this.element],"e-popup-close"),this.isModal&&this.setOverlayZindex()),this.visible){if(this.show(),this.isModal){var r=this.getTargetContainer(this.target);r instanceof Element&&"rtl"===window.getComputedStyle(r).getPropertyValue("direction")&&this.setPopupPosition()}}else this.isModal&&(this.dlgOverlay.style.display="none");this.initialRender=!1},t.prototype.getTargetContainer=function(e){var i=null;if("string"==typeof e)if(e.startsWith("#"))i=document.getElementById(e.substring(1));else if(e.startsWith(".")){var r=document.getElementsByClassName(e.substring(1));i=r.length>0?r[0]:null}else!(e instanceof HTMLElement)&&e!==document.body&&(i=document.querySelector(e));else e instanceof HTMLElement&&(i=e);return i},t.prototype.resetResizeIcon=function(){var e=this.getMinHeight();if(this.targetEle.offsetHeight0&&("function"==typeof this.buttons[e].click&&E.add(s[e],"click",this.buttons[e].click,this),"object"==typeof this.buttons[e].click&&E.add(s[e],"click",this.buttonClickHandler.bind(this,e),this)),!this.isBlazorServerRender()&&!m(this.ftrTemplateContent)&&(this.btnObj[e].appendTo(this.ftrTemplateContent.children[e]),this.buttons[e].isFlat&&this.btnObj[e].element.classList.add("e-flat"),this.primaryButtonEle=this.element.getElementsByClassName("e-primary")[0]))},t.prototype.buttonClickHandler=function(e){this.trigger("buttons["+e+"].click",{})},t.prototype.setContent=function(){this.contentEle=this.createElement("div",{className:"e-dlg-content",id:this.element.id+"_dialog-content"}),Fe(this.element,this.headerEle?{"aria-describedby":this.element.id+"_title "+this.element.id+"_dialog-content"}:{"aria-describedby":this.element.id+"_dialog-content"}),this.innerContentElement?this.contentEle.appendChild(this.innerContentElement):(!m(this.content)&&""!==this.content||!this.initialRender)&&(("string"!=typeof this.content||ce())&&this.content instanceof HTMLElement?this.contentEle.appendChild(this.content):this.setTemplate(this.content,this.contentEle,"content")),m(this.headerContent)?this.element.insertBefore(this.contentEle,this.element.children[0]):this.element.insertBefore(this.contentEle,this.element.children[1]),"auto"===this.height&&(!this.isBlazorServerRender()&&X.isIE&&""===this.element.style.width&&!m(this.width)&&(this.element.style.width=Re(this.width)),this.setMaxHeight())},t.prototype.setTemplate=function(e,i,r){var s,o,a;o=i.classList.contains(g4)?this.element.id+"header":i.classList.contains(U0)?this.element.id+"footerTemplate":this.element.id+"content",m(e.outerHTML)?("string"==typeof e||"string"!=typeof e||ce()&&!this.isStringTemplate)&&("string"==typeof e&&(e=this.sanitizeHelper(e)),this.isVue||"string"!=typeof e?(s=si(e),a=e):i.innerHTML=e):i.appendChild(e);var l=[];if(!m(s)){for(var c=0,d=s({},this,r,o,!(ce()&&!this.isStringTemplate&&0===a.indexOf("
Blazor"))||this.isStringTemplate);c/g,"");(this.element.children.length>0||i)&&(this.innerContentElement=document.createDocumentFragment(),[].slice.call(this.element.childNodes).forEach(function(r){8!==r.nodeType&&e.innerContentElement.appendChild(r)}))}},t.prototype.setHeader=function(){this.headerEle?this.headerEle.innerHTML="":this.headerEle=this.createElement("div",{id:this.element.id+"_title",className:g4}),this.createHeaderContent(),this.headerContent.appendChild(this.headerEle),this.setTemplate(this.header,this.headerEle,"header"),Fe(this.element,{"aria-describedby":this.element.id+"_title"}),Fe(this.element,{"aria-labelledby":this.element.id+"_dialog-header"}),this.element.insertBefore(this.headerContent,this.element.children[0]),this.allowDragging&&!m(this.headerContent)&&this.setAllowDragging()},t.prototype.setFooterTemplate=function(){this.ftrTemplateContent?this.ftrTemplateContent.innerHTML="":this.ftrTemplateContent=this.createElement("div",{className:U0}),""===this.footerTemplate||m(this.footerTemplate)?this.ftrTemplateContent.innerHTML=this.buttonContent.join(""):this.setTemplate(this.footerTemplate,this.ftrTemplateContent,"footerTemplate"),this.element.appendChild(this.ftrTemplateContent)},t.prototype.createHeaderContent=function(){m(this.headerContent)&&(this.headerContent=this.createElement("div",{id:this.element.id+"_dialog-header",className:OE}))},t.prototype.renderCloseIcon=function(){this.showCloseIcon&&(this.closeIcon=this.createElement("button",{className:y4,attrs:{type:"button"}}),this.closeIconBtnObj=new ys({cssClass:"e-flat",iconCss:v4+" e-icons"}),this.closeIconTitle(),m(this.headerContent)?(this.createHeaderContent(),gl([this.closeIcon],this.headerContent),this.element.insertBefore(this.headerContent,this.element.children[0])):gl([this.closeIcon],this.headerContent),this.closeIconBtnObj.appendTo(this.closeIcon))},t.prototype.closeIconTitle=function(){this.l10n.setLocale(this.locale);var e=this.l10n.getConstant("close");this.closeIcon.setAttribute("title",e),this.closeIcon.setAttribute("aria-label",e)},t.prototype.setCSSClass=function(e){e&&(K([this.element],e.split(" ")),this.isModal&&!m(this.dlgContainer)&&K([this.dlgContainer],e.split(" "))),this.cssClass&&(V([this.element],this.cssClass.split(" ")),this.isModal&&!m(this.dlgContainer)&&V([this.dlgContainer],this.cssClass.split(" ")))},t.prototype.setIsModal=function(){this.dlgContainer=this.createElement("div",{className:"e-dlg-container"}),this.setCSSClass(),this.element.classList.remove(S4),this.element.parentNode.insertBefore(this.dlgContainer,this.element),this.dlgContainer.appendChild(this.element),V([this.element],j0),this.dlgOverlay=this.createElement("div",{className:"e-dlg-overlay"}),this.dlgOverlay.style.zIndex=(this.zIndex-1).toString(),this.dlgContainer.appendChild(this.dlgOverlay)},t.prototype.getValidFocusNode=function(e){for(var i,r=0;r0||"a"===i.tagName.toLowerCase()&&i.hasAttribute("href"))&&i.tabIndex>-1&&!i.disabled&&!this.disableElement(i,'[disabled],[aria-disabled="true"],[type="hidden"]'))return i;i=null}return i},t.prototype.focusableElements=function(e){if(!m(e)){var r=e.querySelectorAll('input,select,textarea,button,a,[contenteditable="true"],[tabindex]');return this.getValidFocusNode(r)}return null},t.prototype.getAutoFocusNode=function(e){var i=e.querySelector("."+y4),s=e.querySelectorAll("[autofocus]"),o=this.getValidFocusNode(s);if(ce()&&(this.primaryButtonEle=this.element.getElementsByClassName("e-primary")[0]),m(o)){if(!m(o=this.focusableElements(this.contentEle)))return o;if(!m(this.primaryButtonEle))return this.element.querySelector(".e-primary")}else i=o;return i},t.prototype.disableElement=function(e,i){var r=e?e.matches||e.webkitMatchesSelector||e.msGetRegionContent:null;if(r)for(;e;e=e.parentNode)if(e instanceof Element&&r.call(e,i))return e;return null},t.prototype.focusContent=function(){var e=this.getAutoFocusNode(this.element),i=m(e)?this.element:e,r=X.userAgent;(r.indexOf("MSIE ")>0||r.indexOf("Trident/")>0)&&this.element.focus(),i.focus(),this.unBindEvent(this.element),this.bindEvent(this.element)},t.prototype.bindEvent=function(e){E.add(e,"keydown",this.keyDown,this)},t.prototype.unBindEvent=function(e){E.remove(e,"keydown",this.keyDown)},t.prototype.updateSanitizeContent=function(){this.isBlazorServerRender()||(this.contentEle.innerHTML=this.sanitizeHelper(this.content))},t.prototype.isBlazorServerRender=function(){return ce()&&this.isServerRendered},t.prototype.getModuleName=function(){return"dialog"},t.prototype.onPropertyChanged=function(e,i){if(this.element.classList.contains(_0))for(var r=0,s=Object.keys(e);r0?this.showCloseIcon||""!==this.header&&!m(this.header)?this.showCloseIcon||he(this.closeIcon):(he(this.headerContent),this.headerContent=null):(this.renderCloseIcon(),this.wireEvents());break;case"locale":this.showCloseIcon&&this.closeIconTitle();break;case"visible":this.visible?this.show():this.hide();break;case"isModal":this.updateIsModal();break;case"height":je(this.element,{height:Re(e.height)}),this.updatePersistData();break;case"width":je(this.element,{width:Re(e.width)}),this.updatePersistData();break;case"zIndex":this.popupObj.zIndex=this.zIndex,this.isModal&&this.setOverlayZindex(this.zIndex),this.element.style.zIndex!==this.zIndex.toString()&&(this.calculatezIndex=!1);break;case"cssClass":this.setCSSClass(i.cssClass);break;case"buttons":this.unWireButtonEvents(),this.destroyButtons(),m(this.ftrTemplateContent)||(he(this.ftrTemplateContent),this.ftrTemplateContent=null),this.footerTemplate="",this.setButton();break;case"allowDragging":this.allowDragging&&!m(this.headerContent)?this.setAllowDragging():this.dragObj.destroy();break;case"target":this.setTarget(e.target);break;case"position":if(this.checkPositionData(),this.isModal){var a=this.position.X,l=this.position.Y;m(i.position)||(m(i.position.X)||(a=i.position.X),m(i.position.Y)||(l=i.position.Y)),this.dlgContainer.classList.contains("e-dlg-"+a+"-"+l)&&this.dlgContainer.classList.remove("e-dlg-"+a+"-"+l)}this.positionChange(),this.updatePersistData();break;case"enableRtl":this.setEnableRTL();break;case"enableResize":this.setResize(),this.isModelResize=this.enableResize&&this.isModal,this.enableResize&&this.dialogOpen&&this.resetResizeIcon();break;case"minHeight":""!==this.minHeight&&(this.element.style.minHeight=Re(this.minHeight))}},t.prototype.setTarget=function(e){this.popupObj.relateTo=e,this.target=e,this.targetEle="string"==typeof this.target?document.querySelector(this.target):this.target,this.dragObj&&(this.dragObj.dragArea=this.targetEle),this.setMaxHeight(),this.isModal&&this.updateIsModal(),this.enableResize&&this.setResize(),m(this.targetEle)||(this.isModal&&!m(this.dlgContainer)?this.targetEle.appendChild(this.dlgContainer):m(this.element)||this.targetEle.appendChild(this.element))},t.prototype.updateIsModal=function(){if(this.element.setAttribute("aria-modal",this.isModal?"true":"false"),this.isModal)m(this.dlgOverlay)&&(this.setIsModal(),this.element.style.top="0px",this.element.style.left="0px",m(this.targetEle)||this.targetEle.appendChild(this.dlgContainer));else{for(K([this.element],j0),K([document.body],[Pa,ea]),he(this.dlgOverlay);this.dlgContainer.firstChild;)this.dlgContainer.parentElement.insertBefore(this.dlgContainer.firstChild,this.dlgContainer);this.dlgContainer.parentElement.removeChild(this.dlgContainer)}this.visible&&this.show(),this.positionChange(),this.isModal&&this.dlgOverlay&&E.add(this.dlgOverlay,"click",this.dlgOverlayClickEventHandler,this)},t.prototype.setzIndex=function(e,i){var r=this.isProtectedOnChange;this.isProtectedOnChange=!0;var s=hc(e);this.zIndex=s>this.zIndex?s:this.zIndex,this.isProtectedOnChange=r,i&&(this.popupObj.zIndex=this.zIndex)},t.prototype.windowResizeHandler=function(){(function vJ(n){Sh=n})(this.targetEle.clientWidth),function mJ(n){yh=n}(this.targetEle.clientHeight),this.setMaxHeight()},t.prototype.getPersistData=function(){return this.addOnPersist(["width","height","position"])},t.prototype.removeAllChildren=function(e){for(;e.children[0];)this.removeAllChildren(e.children[0]),e.removeChild(e.children[0])},t.prototype.destroy=function(){if(!this.isDestroyed){var e=[NE,j0,kE,cf,V0,m4],i=["role","aria-modal","aria-labelledby","aria-describedby","aria-grabbed","tabindex","style"];K([this.targetEle],[Pa,ea]),!m(this.element)&&this.element.classList.contains(V0)&&K([document.body],[Pa,ea]),this.isModal&&K([m(this.targetEle)?document.body:this.targetEle],ea),this.unWireEvents(),this.unWireButtonEvents(),this.destroyButtons(),m(this.closeIconBtnObj)||this.closeIconBtnObj.destroy(),m(this.dragObj)||this.dragObj.destroy(),!m(this.popupObj.element)&&this.popupObj.element.classList.contains("e-popup")&&this.popupObj.destroy(),K([this.element],e),!m(this.cssClass)&&""!==this.cssClass&&K([this.element],this.cssClass.split(" ")),!m(this.refElement)&&!m(this.refElement.parentElement)&&(this.refElement.parentElement.insertBefore(this.isModal?this.dlgContainer:this.element,this.refElement),he(this.refElement),this.refElement=void 0),this.isModal&&(he(this.dlgOverlay),this.dlgContainer.parentNode.insertBefore(this.element,this.dlgContainer),he(this.dlgContainer)),this.element.innerHTML=this.clonedEle.innerHTML;for(var r=0;r0&&""===this.footerTemplate&&this.ftrTemplateContent)for(var e=0;e=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},zE="e-tooltip",L4="e-icons",N4="e-tooltip-close",RE="e-tooltip-wrap",O4="e-tip-content",df="e-arrow-tip",k4="e-arrow-tip-outer",W0="e-arrow-tip-inner",Yg="e-tip-bottom",HE="e-tip-top",P4="e-tip-left",BE="e-tip-right",FE="e-popup",Qg="e-popup-open",_E="e-popup-close",Y0="e-lib",z4="e-tooltip-popup-container",FJ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return D4(t,n),Gi([I({effect:"FadeIn",duration:150,delay:0})],t.prototype,"open",void 0),Gi([I({effect:"FadeOut",duration:150,delay:0})],t.prototype,"close",void 0),t}(Ee),bh=function(n){function t(e,i){var r=n.call(this,e,i)||this;return r.mouseMoveEvent=null,r.mouseMoveTarget=null,r.containerElement=null,r.isBodyContainer=!0,r}return D4(t,n),t.prototype.initialize=function(){this.formatPosition(),V([this.element],zE)},t.prototype.formatPosition=function(){var e,i;this.position&&(0===this.position.indexOf("Top")||0===this.position.indexOf("Bottom")?(e=this.position.split(/(?=[A-Z])/),this.tooltipPositionY=e[0],this.tooltipPositionX=e[1]):(i=this.position.split(/(?=[A-Z])/),this.tooltipPositionX=i[0],this.tooltipPositionY=i[1]))},t.prototype.renderArrow=function(){this.setTipClass(this.position);var e=this.createElement("div",{className:df+" "+this.tipClass});e.appendChild(this.createElement("div",{className:k4+" "+this.tipClass})),e.appendChild(this.createElement("div",{className:W0+" "+this.tipClass})),this.tooltipEle.appendChild(e)},t.prototype.setTipClass=function(e){this.tipClass=0===e.indexOf("Right")?P4:0===e.indexOf("Bottom")?HE:0===e.indexOf("Left")?BE:Yg},t.prototype.renderPopup=function(e){var i=this.mouseTrail?{top:0,left:0}:this.getTooltipPosition(e);this.tooltipEle.classList.remove(Y0),this.popupObj=new lc(this.tooltipEle,{height:this.height,width:this.width,position:{X:i.left,Y:i.top},enableRtl:this.enableRtl,open:this.openPopupHandler.bind(this),close:this.closePopupHandler.bind(this)})},t.prototype.getScalingFactor=function(e){if(!e)return{x:1,y:1};var i={x:1,y:1},r=e.closest('[style*="transform: scale"]');if(r&&r!==this.tooltipEle&&r.contains(this.tooltipEle)){var a=window.getComputedStyle(r).getPropertyValue("transform").match(/matrix\(([^)]+)\)/)[1].split(",").map(parseFloat);i.x=a[0],i.y=a[3]}return i},t.prototype.getTooltipPosition=function(e){this.tooltipEle.style.display="block";var i=this.element.closest('[style*="zoom"]');i&&(i.contains(this.tooltipEle)||(this.tooltipEle.style.zoom=getComputedStyle(i).zoom));var r=ns(e,this.tooltipPositionX,this.tooltipPositionY,!this.isBodyContainer,this.isBodyContainer?null:this.containerElement.getBoundingClientRect()),s=this.getScalingFactor(e),o=this.calculateTooltipOffset(this.position,s.x,s.y),a=this.calculateElementPosition(r,o),c=this.collisionFlipFit(e,a[0],a[1]);return c.left=c.left/s.x,c.top=c.top/s.y,this.tooltipEle.style.display="",c},t.prototype.windowResize=function(){this.reposition(this.findTarget())},t.prototype.reposition=function(e){if(this.popupObj&&e){var i=this.getTooltipPosition(e);this.popupObj.position={X:i.left,Y:i.top},this.popupObj.dataBind()}},t.prototype.openPopupHandler=function(){!this.mouseTrail&&this.needTemplateReposition()&&this.reposition(this.findTarget()),this.trigger("afterOpen",this.tooltipEventArgs),this.tooltipEventArgs=null},t.prototype.closePopupHandler=function(){this.isReact&&!("Click"===this.opensOn||"function"==typeof this.content)&&this.clearTemplate(["content"]),this.clear();var e={type:this.tooltipEventArgs.event?this.tooltipEventArgs.event.type:null,cancel:!1,target:this.tooltipEventArgs.target,event:this.tooltipEventArgs.event?this.tooltipEventArgs.event:null,element:this.tooltipEle,isInteracted:!m(this.tooltipEventArgs.event)};this.trigger("afterClose",e),e=null},t.prototype.calculateTooltipOffset=function(e,i,r){void 0===i&&(i=1),void 0===r&&(r=1);var o,a,l,h,c,d,u,f,s={top:0,left:0};if(1!==i||1!==r){var p=this.tooltipEle.getBoundingClientRect(),g=void 0;l=Math.round(p.width),h=Math.round(p.height),(c=_("."+df,this.tooltipEle))&&(g=c.getBoundingClientRect()),o=c?Math.round(g.width):0,a=c?Math.round(g.height):0,d=this.showTipPointer?0:8,u=a/2+2+(h-this.tooltipEle.clientHeight*r),f=o/2+2+(l-this.tooltipEle.clientWidth*i)}else l=this.tooltipEle.offsetWidth,h=this.tooltipEle.offsetHeight,c=_("."+df,this.tooltipEle),d=this.showTipPointer?0:8,u=(a=c?c.offsetHeight:0)/2+2+(this.tooltipEle.offsetHeight-this.tooltipEle.clientHeight),f=(o=c?c.offsetWidth:0)/2+2+(this.tooltipEle.offsetWidth-this.tooltipEle.clientWidth);switch(this.mouseTrail&&(d+=2),e){case"RightTop":s.left+=o+d,s.top-=h-u;break;case"RightCenter":s.left+=o+d,s.top-=h/2;break;case"RightBottom":s.left+=o+d,s.top-=u;break;case"BottomRight":s.top+=a+d,s.left-=f;break;case"BottomCenter":s.top+=a+d,s.left-=l/2;break;case"BottomLeft":s.top+=a+d,s.left-=l-f;break;case"LeftBottom":s.left-=o+l+d,s.top-=u;break;case"LeftCenter":s.left-=o+l+d,s.top-=h/2;break;case"LeftTop":s.left-=o+l+d,s.top-=h-u;break;case"TopLeft":s.top-=h+a+d,s.left-=l-f;break;case"TopRight":s.top-=h+a+d,s.left-=f;break;default:s.top-=h+a+d,s.left-=l/2}return s.left+=this.offsetX,s.top+=this.offsetY,s},t.prototype.updateTipPosition=function(e){var i=we("."+df+",."+k4+",."+W0,this.tooltipEle);K(i,[Yg,HE,P4,BE]),this.setTipClass(e),V(i,this.tipClass)},t.prototype.adjustArrow=function(e,i,r,s){var o=_("."+df,this.tooltipEle);if(!1!==this.showTipPointer&&null!==o){var a,l;this.updateTipPosition(i),this.tooltipEle.style.display="block";var p,h=this.tooltipEle.clientWidth,c=this.tooltipEle.clientHeight,d=_("."+W0,this.tooltipEle),u=o.offsetWidth,f=o.offsetHeight;this.tooltipEle.style.display="",this.tipClass===Yg||this.tipClass===HE?(this.tipClass===Yg?(l="99.9%",d.style.top="-"+(f-2)+"px"):(l=-(f-1)+"px",d.style.top="-"+(f-6)+"px"),e&&(a=(p="Center"!==r||h>e.offsetWidth||this.mouseTrail)&&"Left"===r||!p&&"End"===this.tipPointerPosition?h-u-2+"px":p&&"Right"===r||!p&&"Start"===this.tipPointerPosition?"2px":!p||"End"!==this.tipPointerPosition&&"Start"!==this.tipPointerPosition?h/2-u/2+"px":"End"===this.tipPointerPosition?e.offsetWidth+(this.tooltipEle.offsetWidth-e.offsetWidth)/2-u/2-2+"px":(this.tooltipEle.offsetWidth-e.offsetWidth)/2-u/2+2+"px")):(this.tipClass===BE?(a="99.9%",d.style.left="-"+(u-2)+"px"):(a=-(u-1)+"px",d.style.left=u-2-u+"px"),l=(p="Center"!==s||c>e.offsetHeight||this.mouseTrail)&&"Top"===s||!p&&"End"===this.tipPointerPosition?c-f-2+"px":p&&"Bottom"===s||!p&&"Start"===this.tipPointerPosition?"2px":c/2-f/2+"px"),o.style.top=l,o.style.left=a}},t.prototype.renderContent=function(e){var i=this,r=_("."+O4,this.tooltipEle);if(this.cssClass&&V([this.tooltipEle],this.cssClass.split(" ")),e&&!m(e.getAttribute("title"))&&(e.setAttribute("data-content",e.getAttribute("title")),e.removeAttribute("title")),m(this.content))e&&!m(e.getAttribute("data-content"))&&(r.innerHTML=e.getAttribute("data-content"));else if(r.innerHTML="",this.content instanceof HTMLElement)r.appendChild(this.content);else if("string"==typeof this.content)this.isAngular?this.setProperties({content:Ai.sanitize(this.content)},!0):this.content=this.enableHtmlSanitizer?Ai.sanitize(this.content):this.content,this.enableHtmlParse?(o=si(this.content)({},this,"content",this.element.id+"content",void 0,void 0,r,this.root))&&Dt(o,r):r.textContent=this.content;else{var o;(o=si(this.content)({},this,"content",this.element.id+"content",void 0,void 0,r))&&(this.isAngular&&setTimeout(function(){i.reposition(e)},1),Dt(o,r)),this.renderReactTemplates()}},t.prototype.renderCloseIcon=function(){if(this.isSticky){var i=this.createElement("div",{className:L4+" "+N4});this.tooltipEle.appendChild(i),E.add(i,X.touchStartEvent,this.onStickyClose,this)}else{var e=this.tooltipEle.querySelector("."+L4+"."+N4);e&>(e)}},t.prototype.addDescribedBy=function(e,i){var r=(e.getAttribute("aria-describedby")||"").split(/\s+/);r.indexOf(i)<0&&r.push(i),Fe(e,{"aria-describedby":r.join(" ").trim(),"data-tooltip-id":i})},t.prototype.removeDescribedBy=function(e){var i=e.getAttribute("data-tooltip-id"),r=(e.getAttribute("aria-describedby")||"").split(/\s+/),s=r.indexOf(i);-1!==s&&r.splice(s,1),e.removeAttribute("data-tooltip-id");var o=r.join(" ").trim();o?e.setAttribute("aria-describedby",o):e.removeAttribute("aria-describedby")},t.prototype.tapHoldHandler=function(e){clearTimeout(this.autoCloseTimer),this.targetHover(e.originalEvent)},t.prototype.touchEndHandler=function(){var e=this;this.isSticky||(this.autoCloseTimer=setTimeout(function(){e.close()},1500))},t.prototype.targetClick=function(e){var i;!m(i=this.target?J(e.target,this.target):this.element)&&(null===i.getAttribute("data-tooltip-id")?this.targetHover(e):this.isSticky||this.hideTooltip(this.animation.close,e,i))},t.prototype.targetHover=function(e){var i;if(!(m(i=this.target?J(e.target,this.target):this.element)||null!==i.getAttribute("data-tooltip-id")&&0===this.closeDelay)){for(var s=0,o=[].slice.call(we('[data-tooltip-id= "'+this.ctrlId+'_content"]',document));s0?this.showTimer=setTimeout(function(){o.mouseTrail&&E.add(i,"mousemove touchstart mouseenter",o.onMouseMove,o),o.popupObj&&(o.popupObj.show(a,i),o.mouseMoveEvent&&o.mouseTrail&&o.onMouseMove(o.mouseMoveEvent))},this.openDelay):this.popupObj&&this.popupObj.show(a,i)}s&&this.wireMouseEvents(s,i)},t.prototype.needTemplateReposition=function(){return!m(this.viewContainerRef)&&"string"!=typeof this.viewContainerRef||this.isReact},t.prototype.checkCollision=function(e,i,r){var s={left:i,top:r,position:this.position,horizontal:this.tooltipPositionX,vertical:this.tooltipPositionY},o=ac(this.tooltipEle,this.checkCollideTarget(),i,r);return o.length>0&&(s.horizontal=o.indexOf("left")>=0?"Right":o.indexOf("right")>=0?"Left":this.tooltipPositionX,s.vertical=o.indexOf("top")>=0?"Bottom":o.indexOf("bottom")>=0?"Top":this.tooltipPositionY),s},t.prototype.calculateElementPosition=function(e,i){return[this.isBodyContainer?e.left+i.left:e.left-this.containerElement.getBoundingClientRect().left+i.left+window.pageXOffset+this.containerElement.scrollLeft,this.isBodyContainer?e.top+i.top:e.top-this.containerElement.getBoundingClientRect().top+i.top+window.pageYOffset+this.containerElement.scrollTop]},t.prototype.collisionFlipFit=function(e,i,r){var s=this.checkCollision(e,i,r),o=s.position;if(this.tooltipPositionY!==s.vertical&&(o=0===this.position.indexOf("Bottom")||0===this.position.indexOf("Top")?s.vertical+this.tooltipPositionX:this.tooltipPositionX+s.vertical),this.tooltipPositionX!==s.horizontal&&(0===o.indexOf("Left")&&(s.vertical="LeftTop"===o||"LeftCenter"===o?"Top":"Bottom",o=s.vertical+"Left"),0===o.indexOf("Right")&&(s.vertical="RightTop"===o||"RightCenter"===o?"Top":"Bottom",o=s.vertical+"Right"),s.horizontal=this.tooltipPositionX),this.tooltipEventArgs={type:null,cancel:!1,target:e,event:null,element:this.tooltipEle,collidedPosition:o},this.trigger("beforeCollision",this.tooltipEventArgs),this.tooltipEventArgs.cancel)o=this.position;else{var a=s.vertical,l=s.horizontal;if(s.position!==o){var h=ns(e,l,a,!this.isBodyContainer,this.isBodyContainer?null:this.containerElement.getBoundingClientRect());this.adjustArrow(e,o,l,a);var c=this.getScalingFactor(e),d=this.calculateTooltipOffset(o,c.x,c.y);d.top-=this.getOffSetPosition("TopBottom",o,this.offsetY),d.left-=this.getOffSetPosition("RightLeft",o,this.offsetX),s.position=o;var u=this.calculateElementPosition(h,d);s.left=u[0],s.top=u[1]}else this.adjustArrow(e,o,l,a)}var f={left:s.left,top:s.top},p=this.isBodyContainer?hE(this.tooltipEle,this.checkCollideTarget(),{X:!0,Y:this.windowCollision},f):f;this.tooltipEle.style.display="block";var g=_("."+df,this.tooltipEle);if(this.showTipPointer&&null!=g&&(0===o.indexOf("Bottom")||0===o.indexOf("Top"))){var v=parseInt(g.style.left,10)-(p.left-s.left);v<0?v=0:v+g.offsetWidth>this.tooltipEle.clientWidth&&(v=this.tooltipEle.clientWidth-g.offsetWidth),g.style.left=v.toString()+"px"}return this.tooltipEle.style.display="",f.left=p.left,f.top=p.top,f},t.prototype.getOffSetPosition=function(e,i,r){return-1!==e.indexOf(this.position.split(/(?=[A-Z])/)[0])&&-1!==e.indexOf(i.split(/(?=[A-Z])/)[0])?2*r:0},t.prototype.checkCollideTarget=function(){return!this.windowCollision&&this.target?this.element:null},t.prototype.hideTooltip=function(e,i,r){var s=this;this.closeDelay>0?(clearTimeout(this.hideTimer),clearTimeout(this.showTimer),this.hideTimer=setTimeout(function(){s.closeDelay&&s.tooltipEle&&s.isTooltipOpen||s.tooltipHide(e,i,r)},this.closeDelay)):this.tooltipHide(e,i,r)},t.prototype.tooltipHide=function(e,i,r){var o,s=this;o=i?this.target?r||i.target:this.element:_('[data-tooltip-id= "'+this.ctrlId+'_content"]',document),this.tooltipEventArgs={type:i?i.type:null,cancel:!1,target:o,event:i||null,element:this.tooltipEle,isInteracted:!m(i)},this.trigger("beforeClose",this.tooltipEventArgs,function(a){a.cancel?s.isHidden=!1:(s.mouseMoveBeforeRemove(),s.popupHide(e,o,i))})},t.prototype.popupHide=function(e,i,r){i&&r&&this.restoreElement(i),this.isHidden=!0;var s={name:this.animation.close.effect,duration:e.duration,delay:e.delay,timingFunction:"easeIn"};"None"===e.effect&&(s=void 0),this.popupObj&&this.popupObj.hide(s)},t.prototype.restoreElement=function(e){this.unwireMouseEvents(e),m(e.getAttribute("data-content"))||(e.setAttribute("title",e.getAttribute("data-content")),e.removeAttribute("data-content")),this.removeDescribedBy(e)},t.prototype.clear=function(){var e=this.findTarget();e&&this.restoreElement(e),this.tooltipEle&&(K([this.tooltipEle],_E),V([this.tooltipEle],Qg)),this.isHidden&&(this.popupObj&&this.popupObj.destroy(),this.tooltipEle&>(this.tooltipEle),this.tooltipEle=null,this.popupObj=null)},t.prototype.tooltipHover=function(){this.tooltipEle&&(this.isTooltipOpen=!0)},t.prototype.tooltipMouseOut=function(e){this.isTooltipOpen=!1,this.hideTooltip(this.animation.close,e,this.findTarget())},t.prototype.onMouseOut=function(e){var i=e.relatedTarget;if(i&&!this.mouseTrail){var r=J(i,"."+RE+"."+Y0+"."+FE);r?E.add(r,"mouseleave",this.tooltipElementMouseOut,this):(this.hideTooltip(this.animation.close,e,this.findTarget()),0===this.closeDelay&&("None"===this.animation.close.effect||this.isReact&&"string"!=typeof this.content)&&this.clear())}else this.hideTooltip(this.animation.close,e,this.findTarget()),this.clear();this.popupObj&&!this.popupObj.element.classList.contains(Qg)&&this.clear()},t.prototype.tooltipElementMouseOut=function(e){this.hideTooltip(this.animation.close,e,this.findTarget()),E.remove(this.element,"mouseleave",this.tooltipElementMouseOut),this.clear()},t.prototype.onStickyClose=function(){this.close()},t.prototype.onMouseMove=function(e){var i=0,r=0;e.type.indexOf("touch")>-1?(e.preventDefault(),i=e.touches[0].pageX,r=e.touches[0].pageY):(i=e.pageX,r=e.pageY),Hs.stop(this.tooltipEle),K([this.tooltipEle],_E),V([this.tooltipEle],Qg),this.adjustArrow(e.target,this.position,this.tooltipPositionX,this.tooltipPositionY);var s=this.getScalingFactor(e.target),o=this.calculateTooltipOffset(this.position,s.x,s.y),h=this.checkCollision(e.target,i+o.left+this.offsetX,r+o.top+this.offsetY);if(this.tooltipPositionX!==h.horizontal||this.tooltipPositionY!==h.vertical){var c=0===this.position.indexOf("Bottom")||0===this.position.indexOf("Top")?h.vertical+h.horizontal:h.horizontal+h.vertical;h.position=c,this.adjustArrow(e.target,h.position,h.horizontal,h.vertical);var d=this.calculateTooltipOffset(h.position,s.x,s.y);h.left=i+d.left-this.offsetX,h.top=r+d.top-this.offsetY}this.tooltipEle.style.left=h.left+"px",this.tooltipEle.style.top=h.top+"px"},t.prototype.keyDown=function(e){this.tooltipEle&&27===e.keyCode&&this.close()},t.prototype.touchEnd=function(e){this.tooltipEle&&null===J(e.target,"."+zE)&&!this.isSticky&&this.close()},t.prototype.scrollHandler=function(e){this.tooltipEle&&!this.isSticky&&!J(e.target,"."+RE+"."+Y0+"."+FE)&&!this.isSticky&&this.close()},t.prototype.render=function(){this.initialize(),this.wireEvents(this.opensOn),this.renderComplete()},t.prototype.preRender=function(){this.tipClass=Yg,this.tooltipPositionX="Center",this.tooltipPositionY="Top",this.isHidden=!0},t.prototype.wireEvents=function(e){for(var r=0,s=this.getTriggerList(e);r0)for(var i=0,r=e;i0)for(var i=0,r=e;i0&&this.condition&&-1!==this.condition.indexOf("not")&&(e[s].condition=e[s].condition?e[s].condition+"not":"not"),i=e[s].validate(t),r){if(!i)return!1}else if(i)return!0;return r},n.prototype.toJson=function(){var t,e;if(this.isComplex){t=[],e=this.predicates;for(var i=0;ie.length-3?(e=e.substring(0,e.length-1),n.endsWith(n.toLowerCase(t),n.toLowerCase(e))):(e.lastIndexOf("%")!==e.indexOf("%")&&e.lastIndexOf("%")>e.indexOf("%")+1&&(e=e.substring(e.indexOf("%")+1,e.lastIndexOf("%"))),-1!==t.indexOf(e)))},n.fnSort=function(t){return"ascending"===(t=t?n.toLowerCase(t):"ascending")?this.fnAscending:this.fnDescending},n.fnAscending=function(t,e){return m(t)&&m(e)||null==e?-1:"string"==typeof t?t.localeCompare(e):null==t?1:t-e},n.fnDescending=function(t,e){return m(t)&&m(e)?-1:null==e?1:"string"==typeof t?-1*t.localeCompare(e):null==t?-1:e-t},n.extractFields=function(t,e){for(var i={},r=0;r0||e.length>0;)o=t.length>0&&e.length>0?r?r(this.getVal(t,0,i),this.getVal(e,0,i),t[0],e[0])<=0?t:e:t[0][i]0?t:e,s.push(o.shift());return s},n.getVal=function(t,e,i){return i?this.getObject(i,t[e]):t[e]},n.toLowerCase=function(t){return t?"string"==typeof t?t.toLowerCase():t.toString():0===t||!1===t?t.toString():""},n.callAdaptorFunction=function(t,e,i,r){if(e in t){var s=t[e](i,r);m(s)||(i=s)}return i},n.getAddParams=function(t,e,i){var r={};return n.callAdaptorFunction(t,"addParams",{dm:e,query:i,params:i?i.params:[],reqParams:r}),r},n.isPlainObject=function(t){return!!t&&t.constructor===Object},n.isCors=function(){var t=null;try{t=new window.XMLHttpRequest}catch{}return!!t&&"withCredentials"in t},n.getGuid=function(t){var i;return(t||"")+"00000000-0000-4000-0000-000000000000".replace(/0/g,function(r,s){if("crypto"in window&&"getRandomValues"in crypto){var o=new Uint8Array(1);window.crypto.getRandomValues(o),i=o[0]%16|0}else i=16*Math.random()|0;return"0123456789abcdef"[19===s?3&i|8:i]})},n.isNull=function(t){return null==t},n.getItemFromComparer=function(t,e,i){var r,s,o,a=0,l="string"==typeof n.getVal(t,0,e);if(t.length)for(;m(r)&&a0&&(r=s,o=t[a]));return o},n.distinct=function(t,e,i){i=!m(i)&&i;var s,r=[],o={};return t.forEach(function(a,l){(s="object"==typeof t[l]?n.getVal(t,l,e):t[l])in o||(r.push(i?t[l]:s),o[s]=1)}),r},n.processData=function(t,e){var i=this.prepareQuery(t),r=new tt(e);t.requiresCounts&&i.requiresCount();var s=r.executeLocal(i),o={result:t.requiresCounts?s.result:s,count:s.count,aggregates:JSON.stringify(s.aggregates)};return t.requiresCounts?o:s},n.prepareQuery=function(t){var e=this,i=new Ht;return t.select&&i.select(t.select),t.where&&n.parse.parseJson(t.where).filter(function(o){if(m(o.condition))i.where(o.field,o.operator,o.value,o.ignoreCase,o.ignoreAccent);else{var a=[];o.field?a.push(new Ss(o.field,o.operator,o.value,o.ignoreCase,o.ignoreAccent)):a=a.concat(e.getPredicate(o.predicates)),"or"===o.condition?i.where(Ss.or(a)):"and"===o.condition&&i.where(Ss.and(a))}}),t.search&&n.parse.parseJson(t.search).filter(function(o){return i.search(o.key,o.fields,o.operator,o.ignoreCase,o.ignoreAccent)}),t.aggregates&&t.aggregates.filter(function(o){return i.aggregate(o.type,o.field)}),t.sorted&&t.sorted.filter(function(o){return i.sortBy(o.name,o.direction)}),t.skip&&i.skip(t.skip),t.take&&i.take(t.take),t.group&&t.group.filter(function(o){return i.group(o)}),i},n.getPredicate=function(t){for(var e=[],i=0;i":"greaterthan","<=":"lessthanorequal",">=":"greaterthanorequal","==":"equal","!=":"notequal","*=":"contains","$=":"endswith","^=":"startswith"},n.odBiOperator={"<":" lt ",">":" gt ","<=":" le ",">=":" ge ","==":" eq ","!=":" ne ",lessthan:" lt ",lessthanorequal:" le ",greaterthan:" gt ",greaterthanorequal:" ge ",equal:" eq ",notequal:" ne "},n.odUniOperator={"$=":"endswith","^=":"startswith","*=":"substringof",endswith:"endswith",startswith:"startswith",contains:"substringof",doesnotendwith:"not endswith",doesnotstartwith:"not startswith",doesnotcontain:"not substringof",wildcard:"wildcard",like:"like"},n.odv4UniOperator={"$=":"endswith","^=":"startswith","*=":"contains",endswith:"endswith",startswith:"startswith",contains:"contains",doesnotendwith:"not endswith",doesnotstartwith:"not startswith",doesnotcontain:"not contains",wildcard:"wildcard",like:"like"},n.diacritics={"\u24b6":"A",\uff21:"A",\u00c0:"A",\u00c1:"A",\u00c2:"A",\u1ea6:"A",\u1ea4:"A",\u1eaa:"A",\u1ea8:"A",\u00c3:"A",\u0100:"A",\u0102:"A",\u1eb0:"A",\u1eae:"A",\u1eb4:"A",\u1eb2:"A",\u0226:"A",\u01e0:"A",\u00c4:"A",\u01de:"A",\u1ea2:"A",\u00c5:"A",\u01fa:"A",\u01cd:"A",\u0200:"A",\u0202:"A",\u1ea0:"A",\u1eac:"A",\u1eb6:"A",\u1e00:"A",\u0104:"A",\u023a:"A",\u2c6f:"A",\ua732:"AA",\u00c6:"AE",\u01fc:"AE",\u01e2:"AE",\ua734:"AO",\ua736:"AU",\ua738:"AV",\ua73a:"AV",\ua73c:"AY","\u24b7":"B",\uff22:"B",\u1e02:"B",\u1e04:"B",\u1e06:"B",\u0243:"B",\u0182:"B",\u0181:"B","\u24b8":"C",\uff23:"C",\u0106:"C",\u0108:"C",\u010a:"C",\u010c:"C",\u00c7:"C",\u1e08:"C",\u0187:"C",\u023b:"C",\ua73e:"C","\u24b9":"D",\uff24:"D",\u1e0a:"D",\u010e:"D",\u1e0c:"D",\u1e10:"D",\u1e12:"D",\u1e0e:"D",\u0110:"D",\u018b:"D",\u018a:"D",\u0189:"D",\ua779:"D",\u01f1:"DZ",\u01c4:"DZ",\u01f2:"Dz",\u01c5:"Dz","\u24ba":"E",\uff25:"E",\u00c8:"E",\u00c9:"E",\u00ca:"E",\u1ec0:"E",\u1ebe:"E",\u1ec4:"E",\u1ec2:"E",\u1ebc:"E",\u0112:"E",\u1e14:"E",\u1e16:"E",\u0114:"E",\u0116:"E",\u00cb:"E",\u1eba:"E",\u011a:"E",\u0204:"E",\u0206:"E",\u1eb8:"E",\u1ec6:"E",\u0228:"E",\u1e1c:"E",\u0118:"E",\u1e18:"E",\u1e1a:"E",\u0190:"E",\u018e:"E","\u24bb":"F",\uff26:"F",\u1e1e:"F",\u0191:"F",\ua77b:"F","\u24bc":"G",\uff27:"G",\u01f4:"G",\u011c:"G",\u1e20:"G",\u011e:"G",\u0120:"G",\u01e6:"G",\u0122:"G",\u01e4:"G",\u0193:"G",\ua7a0:"G",\ua77d:"G",\ua77e:"G","\u24bd":"H",\uff28:"H",\u0124:"H",\u1e22:"H",\u1e26:"H",\u021e:"H",\u1e24:"H",\u1e28:"H",\u1e2a:"H",\u0126:"H",\u2c67:"H",\u2c75:"H",\ua78d:"H","\u24be":"I",\uff29:"I",\u00cc:"I",\u00cd:"I",\u00ce:"I",\u0128:"I",\u012a:"I",\u012c:"I",\u0130:"I",\u00cf:"I",\u1e2e:"I",\u1ec8:"I",\u01cf:"I",\u0208:"I",\u020a:"I",\u1eca:"I",\u012e:"I",\u1e2c:"I",\u0197:"I","\u24bf":"J",\uff2a:"J",\u0134:"J",\u0248:"J","\u24c0":"K",\uff2b:"K",\u1e30:"K",\u01e8:"K",\u1e32:"K",\u0136:"K",\u1e34:"K",\u0198:"K",\u2c69:"K",\ua740:"K",\ua742:"K",\ua744:"K",\ua7a2:"K","\u24c1":"L",\uff2c:"L",\u013f:"L",\u0139:"L",\u013d:"L",\u1e36:"L",\u1e38:"L",\u013b:"L",\u1e3c:"L",\u1e3a:"L",\u0141:"L",\u023d:"L",\u2c62:"L",\u2c60:"L",\ua748:"L",\ua746:"L",\ua780:"L",\u01c7:"LJ",\u01c8:"Lj","\u24c2":"M",\uff2d:"M",\u1e3e:"M",\u1e40:"M",\u1e42:"M",\u2c6e:"M",\u019c:"M","\u24c3":"N",\uff2e:"N",\u01f8:"N",\u0143:"N",\u00d1:"N",\u1e44:"N",\u0147:"N",\u1e46:"N",\u0145:"N",\u1e4a:"N",\u1e48:"N",\u0220:"N",\u019d:"N",\ua790:"N",\ua7a4:"N",\u01ca:"NJ",\u01cb:"Nj","\u24c4":"O",\uff2f:"O",\u00d2:"O",\u00d3:"O",\u00d4:"O",\u1ed2:"O",\u1ed0:"O",\u1ed6:"O",\u1ed4:"O",\u00d5:"O",\u1e4c:"O",\u022c:"O",\u1e4e:"O",\u014c:"O",\u1e50:"O",\u1e52:"O",\u014e:"O",\u022e:"O",\u0230:"O",\u00d6:"O",\u022a:"O",\u1ece:"O",\u0150:"O",\u01d1:"O",\u020c:"O",\u020e:"O",\u01a0:"O",\u1edc:"O",\u1eda:"O",\u1ee0:"O",\u1ede:"O",\u1ee2:"O",\u1ecc:"O",\u1ed8:"O",\u01ea:"O",\u01ec:"O",\u00d8:"O",\u01fe:"O",\u0186:"O",\u019f:"O",\ua74a:"O",\ua74c:"O",\u01a2:"OI",\ua74e:"OO",\u0222:"OU","\u24c5":"P",\uff30:"P",\u1e54:"P",\u1e56:"P",\u01a4:"P",\u2c63:"P",\ua750:"P",\ua752:"P",\ua754:"P","\u24c6":"Q",\uff31:"Q",\ua756:"Q",\ua758:"Q",\u024a:"Q","\u24c7":"R",\uff32:"R",\u0154:"R",\u1e58:"R",\u0158:"R",\u0210:"R",\u0212:"R",\u1e5a:"R",\u1e5c:"R",\u0156:"R",\u1e5e:"R",\u024c:"R",\u2c64:"R",\ua75a:"R",\ua7a6:"R",\ua782:"R","\u24c8":"S",\uff33:"S",\u1e9e:"S",\u015a:"S",\u1e64:"S",\u015c:"S",\u1e60:"S",\u0160:"S",\u1e66:"S",\u1e62:"S",\u1e68:"S",\u0218:"S",\u015e:"S",\u2c7e:"S",\ua7a8:"S",\ua784:"S","\u24c9":"T",\uff34:"T",\u1e6a:"T",\u0164:"T",\u1e6c:"T",\u021a:"T",\u0162:"T",\u1e70:"T",\u1e6e:"T",\u0166:"T",\u01ac:"T",\u01ae:"T",\u023e:"T",\ua786:"T",\ua728:"TZ","\u24ca":"U",\uff35:"U",\u00d9:"U",\u00da:"U",\u00db:"U",\u0168:"U",\u1e78:"U",\u016a:"U",\u1e7a:"U",\u016c:"U",\u00dc:"U",\u01db:"U",\u01d7:"U",\u01d5:"U",\u01d9:"U",\u1ee6:"U",\u016e:"U",\u0170:"U",\u01d3:"U",\u0214:"U",\u0216:"U",\u01af:"U",\u1eea:"U",\u1ee8:"U",\u1eee:"U",\u1eec:"U",\u1ef0:"U",\u1ee4:"U",\u1e72:"U",\u0172:"U",\u1e76:"U",\u1e74:"U",\u0244:"U","\u24cb":"V",\uff36:"V",\u1e7c:"V",\u1e7e:"V",\u01b2:"V",\ua75e:"V",\u0245:"V",\ua760:"VY","\u24cc":"W",\uff37:"W",\u1e80:"W",\u1e82:"W",\u0174:"W",\u1e86:"W",\u1e84:"W",\u1e88:"W",\u2c72:"W","\u24cd":"X",\uff38:"X",\u1e8a:"X",\u1e8c:"X","\u24ce":"Y",\uff39:"Y",\u1ef2:"Y",\u00dd:"Y",\u0176:"Y",\u1ef8:"Y",\u0232:"Y",\u1e8e:"Y",\u0178:"Y",\u1ef6:"Y",\u1ef4:"Y",\u01b3:"Y",\u024e:"Y",\u1efe:"Y","\u24cf":"Z",\uff3a:"Z",\u0179:"Z",\u1e90:"Z",\u017b:"Z",\u017d:"Z",\u1e92:"Z",\u1e94:"Z",\u01b5:"Z",\u0224:"Z",\u2c7f:"Z",\u2c6b:"Z",\ua762:"Z","\u24d0":"a",\uff41:"a",\u1e9a:"a",\u00e0:"a",\u00e1:"a",\u00e2:"a",\u1ea7:"a",\u1ea5:"a",\u1eab:"a",\u1ea9:"a",\u00e3:"a",\u0101:"a",\u0103:"a",\u1eb1:"a",\u1eaf:"a",\u1eb5:"a",\u1eb3:"a",\u0227:"a",\u01e1:"a",\u00e4:"a",\u01df:"a",\u1ea3:"a",\u00e5:"a",\u01fb:"a",\u01ce:"a",\u0201:"a",\u0203:"a",\u1ea1:"a",\u1ead:"a",\u1eb7:"a",\u1e01:"a",\u0105:"a",\u2c65:"a",\u0250:"a",\ua733:"aa",\u00e6:"ae",\u01fd:"ae",\u01e3:"ae",\ua735:"ao",\ua737:"au",\ua739:"av",\ua73b:"av",\ua73d:"ay","\u24d1":"b",\uff42:"b",\u1e03:"b",\u1e05:"b",\u1e07:"b",\u0180:"b",\u0183:"b",\u0253:"b","\u24d2":"c",\uff43:"c",\u0107:"c",\u0109:"c",\u010b:"c",\u010d:"c",\u00e7:"c",\u1e09:"c",\u0188:"c",\u023c:"c",\ua73f:"c",\u2184:"c","\u24d3":"d",\uff44:"d",\u1e0b:"d",\u010f:"d",\u1e0d:"d",\u1e11:"d",\u1e13:"d",\u1e0f:"d",\u0111:"d",\u018c:"d",\u0256:"d",\u0257:"d",\ua77a:"d",\u01f3:"dz",\u01c6:"dz","\u24d4":"e",\uff45:"e",\u00e8:"e",\u00e9:"e",\u00ea:"e",\u1ec1:"e",\u1ebf:"e",\u1ec5:"e",\u1ec3:"e",\u1ebd:"e",\u0113:"e",\u1e15:"e",\u1e17:"e",\u0115:"e",\u0117:"e",\u00eb:"e",\u1ebb:"e",\u011b:"e",\u0205:"e",\u0207:"e",\u1eb9:"e",\u1ec7:"e",\u0229:"e",\u1e1d:"e",\u0119:"e",\u1e19:"e",\u1e1b:"e",\u0247:"e",\u025b:"e",\u01dd:"e","\u24d5":"f",\uff46:"f",\u1e1f:"f",\u0192:"f",\ua77c:"f","\u24d6":"g",\uff47:"g",\u01f5:"g",\u011d:"g",\u1e21:"g",\u011f:"g",\u0121:"g",\u01e7:"g",\u0123:"g",\u01e5:"g",\u0260:"g",\ua7a1:"g",\u1d79:"g",\ua77f:"g","\u24d7":"h",\uff48:"h",\u0125:"h",\u1e23:"h",\u1e27:"h",\u021f:"h",\u1e25:"h",\u1e29:"h",\u1e2b:"h",\u1e96:"h",\u0127:"h",\u2c68:"h",\u2c76:"h",\u0265:"h",\u0195:"hv","\u24d8":"i",\uff49:"i",\u00ec:"i",\u00ed:"i",\u00ee:"i",\u0129:"i",\u012b:"i",\u012d:"i",\u00ef:"i",\u1e2f:"i",\u1ec9:"i",\u01d0:"i",\u0209:"i",\u020b:"i",\u1ecb:"i",\u012f:"i",\u1e2d:"i",\u0268:"i",\u0131:"i","\u24d9":"j",\uff4a:"j",\u0135:"j",\u01f0:"j",\u0249:"j","\u24da":"k",\uff4b:"k",\u1e31:"k",\u01e9:"k",\u1e33:"k",\u0137:"k",\u1e35:"k",\u0199:"k",\u2c6a:"k",\ua741:"k",\ua743:"k",\ua745:"k",\ua7a3:"k","\u24db":"l",\uff4c:"l",\u0140:"l",\u013a:"l",\u013e:"l",\u1e37:"l",\u1e39:"l",\u013c:"l",\u1e3d:"l",\u1e3b:"l",\u017f:"l",\u0142:"l",\u019a:"l",\u026b:"l",\u2c61:"l",\ua749:"l",\ua781:"l",\ua747:"l",\u01c9:"lj","\u24dc":"m",\uff4d:"m",\u1e3f:"m",\u1e41:"m",\u1e43:"m",\u0271:"m",\u026f:"m","\u24dd":"n",\uff4e:"n",\u01f9:"n",\u0144:"n",\u00f1:"n",\u1e45:"n",\u0148:"n",\u1e47:"n",\u0146:"n",\u1e4b:"n",\u1e49:"n",\u019e:"n",\u0272:"n",\u0149:"n",\ua791:"n",\ua7a5:"n",\u01cc:"nj","\u24de":"o",\uff4f:"o",\u00f2:"o",\u00f3:"o",\u00f4:"o",\u1ed3:"o",\u1ed1:"o",\u1ed7:"o",\u1ed5:"o",\u00f5:"o",\u1e4d:"o",\u022d:"o",\u1e4f:"o",\u014d:"o",\u1e51:"o",\u1e53:"o",\u014f:"o",\u022f:"o",\u0231:"o",\u00f6:"o",\u022b:"o",\u1ecf:"o",\u0151:"o",\u01d2:"o",\u020d:"o",\u020f:"o",\u01a1:"o",\u1edd:"o",\u1edb:"o",\u1ee1:"o",\u1edf:"o",\u1ee3:"o",\u1ecd:"o",\u1ed9:"o",\u01eb:"o",\u01ed:"o",\u00f8:"o",\u01ff:"o",\u0254:"o",\ua74b:"o",\ua74d:"o",\u0275:"o",\u01a3:"oi",\u0223:"ou",\ua74f:"oo","\u24df":"p",\uff50:"p",\u1e55:"p",\u1e57:"p",\u01a5:"p",\u1d7d:"p",\ua751:"p",\ua753:"p",\ua755:"p","\u24e0":"q",\uff51:"q",\u024b:"q",\ua757:"q",\ua759:"q","\u24e1":"r",\uff52:"r",\u0155:"r",\u1e59:"r",\u0159:"r",\u0211:"r",\u0213:"r",\u1e5b:"r",\u1e5d:"r",\u0157:"r",\u1e5f:"r",\u024d:"r",\u027d:"r",\ua75b:"r",\ua7a7:"r",\ua783:"r","\u24e2":"s",\uff53:"s",\u00df:"s",\u015b:"s",\u1e65:"s",\u015d:"s",\u1e61:"s",\u0161:"s",\u1e67:"s",\u1e63:"s",\u1e69:"s",\u0219:"s",\u015f:"s",\u023f:"s",\ua7a9:"s",\ua785:"s",\u1e9b:"s","\u24e3":"t",\uff54:"t",\u1e6b:"t",\u1e97:"t",\u0165:"t",\u1e6d:"t",\u021b:"t",\u0163:"t",\u1e71:"t",\u1e6f:"t",\u0167:"t",\u01ad:"t",\u0288:"t",\u2c66:"t",\ua787:"t",\ua729:"tz","\u24e4":"u",\uff55:"u",\u00f9:"u",\u00fa:"u",\u00fb:"u",\u0169:"u",\u1e79:"u",\u016b:"u",\u1e7b:"u",\u016d:"u",\u00fc:"u",\u01dc:"u",\u01d8:"u",\u01d6:"u",\u01da:"u",\u1ee7:"u",\u016f:"u",\u0171:"u",\u01d4:"u",\u0215:"u",\u0217:"u",\u01b0:"u",\u1eeb:"u",\u1ee9:"u",\u1eef:"u",\u1eed:"u",\u1ef1:"u",\u1ee5:"u",\u1e73:"u",\u0173:"u",\u1e77:"u",\u1e75:"u",\u0289:"u","\u24e5":"v",\uff56:"v",\u1e7d:"v",\u1e7f:"v",\u028b:"v",\ua75f:"v",\u028c:"v",\ua761:"vy","\u24e6":"w",\uff57:"w",\u1e81:"w",\u1e83:"w",\u0175:"w",\u1e87:"w",\u1e85:"w",\u1e98:"w",\u1e89:"w",\u2c73:"w","\u24e7":"x",\uff58:"x",\u1e8b:"x",\u1e8d:"x","\u24e8":"y",\uff59:"y",\u1ef3:"y",\u00fd:"y",\u0177:"y",\u1ef9:"y",\u0233:"y",\u1e8f:"y",\u00ff:"y",\u1ef7:"y",\u1e99:"y",\u1ef5:"y",\u01b4:"y",\u024f:"y",\u1eff:"y","\u24e9":"z",\uff5a:"z",\u017a:"z",\u1e91:"z",\u017c:"z",\u017e:"z",\u1e93:"z",\u1e95:"z",\u01b6:"z",\u0225:"z",\u0240:"z",\u2c6c:"z",\ua763:"z",\u0386:"\u0391",\u0388:"\u0395",\u0389:"\u0397",\u038a:"\u0399",\u03aa:"\u0399",\u038c:"\u039f",\u038e:"\u03a5",\u03ab:"\u03a5",\u038f:"\u03a9",\u03ac:"\u03b1",\u03ad:"\u03b5",\u03ae:"\u03b7",\u03af:"\u03b9",\u03ca:"\u03b9",\u0390:"\u03b9",\u03cc:"\u03bf",\u03cd:"\u03c5",\u03cb:"\u03c5",\u03b0:"\u03c5",\u03c9:"\u03c9",\u03c2:"\u03c3"},n.fnOperators={equal:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?n.toLowerCase(t)===n.toLowerCase(e):t===e},notequal:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),!n.fnOperators.equal(t,e,i)},lessthan:function(t,e,i){return i?n.toLowerCase(t)n.toLowerCase(e):t>e},lessthanorequal:function(t,e,i){return i?n.toLowerCase(t)<=n.toLowerCase(e):(m(t)&&(t=void 0),t<=e)},greaterthanorequal:function(t,e,i){return i?n.toLowerCase(t)>=n.toLowerCase(e):t>=e},contains:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?!m(t)&&!m(e)&&-1!==n.toLowerCase(t).indexOf(n.toLowerCase(e)):!m(t)&&!m(e)&&-1!==t.toString().indexOf(e)},doesnotcontain:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?!m(t)&&!m(e)&&-1===n.toLowerCase(t).indexOf(n.toLowerCase(e)):!m(t)&&!m(e)&&-1===t.toString().indexOf(e)},isnotnull:function(t){return null!=t},isnull:function(t){return null==t},startswith:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.startsWith(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.startsWith(t,e)},doesnotstartwith:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.notStartsWith(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.notStartsWith(t,e)},like:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.like(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.like(t,e)},isempty:function(t){return void 0===t||""===t},isnotempty:function(t){return void 0!==t&&""!==t},wildcard:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?(t||"boolean"==typeof t)&&e&&"object"!=typeof t&&n.wildCard(n.toLowerCase(t),n.toLowerCase(e)):(t||"boolean"==typeof t)&&e&&n.wildCard(t,e)},endswith:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.endsWith(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.endsWith(t,e)},doesnotendwith:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.notEndsWith(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.notEndsWith(t,e)},processSymbols:function(t){var e=n.operatorSymbols[t];return e?n.fnOperators[e]:n.throwError("Query - Process Operator : Invalid operator")},processOperator:function(t){return n.fnOperators[t]||n.fnOperators.processSymbols(t)}},n.parse={parseJson:function(t){return"string"!=typeof t||!/^[\s]*\[|^[\s]*\{(.)+:/g.test(t)&&-1!==t.indexOf('"')?t instanceof Array?n.parse.iterateAndReviveArray(t):"object"==typeof t&&null!==t&&n.parse.iterateAndReviveJson(t):t=JSON.parse(t,n.parse.jsonReviver),t},iterateAndReviveArray:function(t){for(var e=0;e-1||e.indexOf("z")>-1,o=e.split(/[^0-9.]/);if(s){if(o[5].indexOf(".")>-1){var a=o[5].split(".");o[5]=a[0],o[6]=new Date(e).getUTCMilliseconds().toString()}else o[6]="00";e=n.dateParse.toTimeZone(new Date(parseInt(o[0],10),parseInt(o[1],10)-1,parseInt(o[2],10),parseInt(o[3],10),parseInt(o[4],10),parseInt(o[5]?o[5]:"00",10),parseInt(o[6],10)),n.serverTimezoneOffset,!1)}else{var l=new Date(parseInt(o[0],10),parseInt(o[1],10)-1,parseInt(o[2],10),parseInt(o[3],10),parseInt(o[4],10),parseInt(o[5]?o[5]:"00",10)),h=parseInt(o[6],10),c=parseInt(o[7],10);if(isNaN(h)&&isNaN(c))return l;e.indexOf("+")>-1?l.setHours(l.getHours()-h,l.getMinutes()-c):l.setHours(l.getHours()+h,l.getMinutes()+c),e=n.dateParse.toTimeZone(l,n.serverTimezoneOffset,!1)}null==n.serverTimezoneOffset&&(e=n.dateParse.addSelfOffset(e))}}return e},isJson:function(t){return"string"==typeof t[0]?t:n.parse.parseJson(t)},isGuid:function(t){return null!=/[A-Fa-f0-9]{8}(?:-[A-Fa-f0-9]{4}){3}-[A-Fa-f0-9]{12}/i.exec(t)},replacer:function(t,e){return n.isPlainObject(t)?n.parse.jsonReplacer(t,e):t instanceof Array?n.parse.arrayReplacer(t):t instanceof Date?n.parse.jsonReplacer({val:t},e).val:t},jsonReplacer:function(t,e){for(var i,s=0,o=Object.keys(t);s=0?"+":"-",s=function(a){var l=Math.floor(Math.abs(a));return(l<10?"0":"")+l};return e.getFullYear()+"-"+s(e.getMonth()+1)+"-"+s(e.getDate())+"T"+s(e.getHours())+":"+s(e.getMinutes())+":"+s(e.getSeconds())+r+s(i/60)+":"+s(i%60)}},n}(),Ml=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),EK={GroupGuid:"{271bbba0-1ee7}"},K4=function(){function n(t){this.options={from:"table",requestType:"json",sortBy:"sorted",select:"select",skip:"skip",group:"group",take:"take",search:"search",count:"requiresCounts",where:"where",aggregates:"aggregates",expand:"expand"},this.type=n,this.dataSource=t,this.pvt={}}return n.prototype.processResponse=function(t,e,i,r){return t},n}(),VE=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ml(t,n),t.prototype.processQuery=function(e,i){for(var a,l,f,r=e.dataSource.json.slice(0),s=r.length,o=!0,h={},c=0,d=[],u=[],p=0;p1?e.sort.filter(function(f){return f.fieldName===c})[0]:e.sort[0];s=this.onSortBy(s,d,e.query,!0)}e.page&&(s=this.onPage(s,e.page,e.query)),this.formGroupResult(s,h)}else{for(var o=e.lazyLoad.onDemandGroupInfo,a=o.where.length-1;a>=0;a--)s=this.onWhere(s,o.where[a]);if(e.group.length!==o.level)s=le.group(s,e.group[o.level].fieldName,r,null,null,e.group[o.level].comparer,!0),e.sort.length&&(s=this.onSortBy(s,e.sort[parseInt(o.level.toString(),10)],e.query,!0));else for(a=e.sort.length-1;a>=o.level;a--)s=this.onSortBy(s,e.sort[parseInt(a.toString(),10)],e.query,!1);i=s.length,h=s,s=(s=s.slice(o.skip)).slice(0,o.take),e.group.length!==o.level&&this.formGroupResult(s,h)}return{result:s,count:i}},t.prototype.formGroupResult=function(e,i){if(e.length&&i.length){var r="GroupGuid",s="childLevels",o="level",a="records";e[r]=i[r],e[s]=i[s],e[o]=i[o],e[a]=i[a]}return e},t.prototype.getAggregate=function(e){var i=Ht.filterQueries(e.queries,"onAggregates"),r=[];if(i.length)for(var s=void 0,o=0;o=0;l--)a[l]&&(o=i.comparer,le.endsWith(a[l]," desc")&&(o=le.fnSort("descending"),a[l]=a[l].replace(" desc","")),e=le.sort(e,a[l],o));return e}return le.sort(e,s?"key":a,i.comparer)},t.prototype.onGroup=function(e,i,r){if(!e||!e.length)return e;var s=this.getAggregate(r);return le.group(e,le.getValue(i.fieldName,r),s,null,null,i.comparer)},t.prototype.onPage=function(e,i,r){var s=le.getValue(i.pageSize,r),o=(le.getValue(i.pageIndex,r)-1)*s;return e&&e.length?e.slice(o,o+s):e},t.prototype.onRange=function(e,i){return e&&e.length?e.slice(le.getValue(i.start),le.getValue(i.end)):e},t.prototype.onTake=function(e,i){return e&&e.length?e.slice(0,le.getValue(i.nos)):e},t.prototype.onSkip=function(e,i){return e&&e.length?e.slice(le.getValue(i.nos)):e},t.prototype.onSelect=function(e,i){return e&&e.length?le.select(e,le.getValue(i.fieldNames)):e},t.prototype.insert=function(e,i,r,s,o){return m(o)?e.dataSource.json.push(i):e.dataSource.json.splice(o,0,i)},t.prototype.remove=function(e,i,r,s){var a,o=e.dataSource.json;for("object"==typeof r&&!(r instanceof Date)&&(r=le.getObject(i,r)),a=0;a1&&(g="("+g+")"),f.filters.push(g);for(var y=0,S="object"==typeof f.filters[p]?Object.keys(f.filters[p]):[];y-1&&this.formRemoteGroupedData(e[s].items,i+1,r-1);var o="GroupGuid",h="records";return e[o]=EK[o],e.level=i,e.childLevels=r,e[h]=e[0].items.length?this.getGroupedRecords(e,!m(e[0].items[h])):[],e},t.prototype.getGroupedRecords=function(e,i){for(var r=[],o=0;ol.length-3?(l=l.substring(0,l.length-1),o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.endswith:le.odv4UniOperator.endswith):l.lastIndexOf("%")!==l.indexOf("%")&&l.lastIndexOf("%")>l.indexOf("%")+1?(l=l.substring(l.indexOf("%")+1,l.lastIndexOf("%")),o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains):o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains),l="'"+(l=encodeURIComponent(l))+"'";else if("wildcard"===o)if(-1!==l.indexOf("*")){var d=l.split("*"),u=void 0,f=0;if(0!==l.indexOf("*")&&-1===d[0].indexOf("%3f")&&-1===d[0].indexOf("?")&&(u="'"+(u=d[0])+"'",s+=(o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.startswith:le.odv4UniOperator.startswith)+"(",s+=c+",",a&&(s+=a),s+=u+")",f++),l.lastIndexOf("*")!==l.length-1&&-1===d[d.length-1].indexOf("%3f")&&-1===d[d.length-1].indexOf("?")&&(u="'"+(u=d[d.length-1])+"'",f>0&&(s+=" and "),s+=(o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.endswith:le.odv4UniOperator.endswith)+"(",s+=c+",",a&&(s+=a),s+=u+")",f++),d.length>2)for(var p=1;p0&&(s+=" and "),"substringof"===(o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains)||"not substringof"===o){var g=u;u=c,c=g}s+=o+"(",s+=c+",",a&&(s+=a),s+=u+")",f++}0===f?(o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains,(-1!==l.indexOf("?")||-1!==l.indexOf("%3f"))&&(l=-1!==l.indexOf("?")?l.split("?").join(""):l.split("%3f").join("")),l="'"+l+"'"):o="wildcard"}else o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains,(-1!==l.indexOf("?")||-1!==l.indexOf("%3f"))&&(l=-1!==l.indexOf("?")?l.split("?").join(""):l.split("%3f").join("")),l="'"+l+"'";return"substringof"!==o&&"not substringof"!==o||(g=l,l=c,c=g),"wildcard"!==o&&(s+=o+"(",s+=c+",",a&&(s+=a),s+=l+")"),s},t.prototype.addParams=function(e){n.prototype.addParams.call(this,e),delete e.reqParams.params},t.prototype.onComplexPredicate=function(e,i,r){for(var s=[],o=0;o-1;f--)!/\bContent-ID:/i.test(c[f])||!/\bHTTP.+201/.test(c[f])||(l=parseInt(/\bContent-ID: (\d+)/i.exec(c[f])[1],10),o.addedRecords[l]&&(h=le.parse.parseJson(/^\{.+\}/m.exec(c[f])[0]),ze({},o.addedRecords[l],this.processResponse(h))));return o}return null},t.prototype.compareAndRemove=function(e,i,r){var s=this;return m(i)||Object.keys(e).forEach(function(o){o!==r&&"@odata.etag"!==o&&(le.isPlainObject(e[o])?(s.compareAndRemove(e[o],i[o]),0===Object.keys(e[o]).filter(function(l){return"@odata.etag"!==l}).length&&delete e[o]):(e[o]===i[o]||e[o]&&i[o]&&e[o].valueOf()===i[o].valueOf())&&delete e[o])}),e},t}(fc),DK=function(n){function t(){var e=n.call(this)||this;return yt("beforeSend",fc.prototype.beforeSend,e),e}return Ml(t,n),t.prototype.insert=function(e,i,r,s,o){return this.pvt.position=o,this.updateType="add",{url:e.dataSource.insertUrl||e.dataSource.crudUrl||e.dataSource.url,data:JSON.stringify(ze({},{value:i,table:r,action:"insert"},le.getAddParams(this,e,s)))}},t.prototype.remove=function(e,i,r,s,o){return n.prototype.remove.call(this,e,i,r),{type:"POST",url:e.dataSource.removeUrl||e.dataSource.crudUrl||e.dataSource.url,data:JSON.stringify(ze({},{key:r,keyColumn:i,table:s,action:"remove"},le.getAddParams(this,e,o)))}},t.prototype.update=function(e,i,r,s,o){return this.updateType="update",this.updateKey=i,{type:"POST",url:e.dataSource.updateUrl||e.dataSource.crudUrl||e.dataSource.url,data:JSON.stringify(ze({},{value:r,action:"update",keyColumn:i,key:r[i],table:s},le.getAddParams(this,e,o)))}},t.prototype.processResponse=function(e,i,r,s,o,a,l){var h;if(e="batch"===(o?JSON.parse(o.data):e).action?le.parse.parseJson(e):e,"add"===this.updateType&&n.prototype.insert.call(this,i,e,null,null,this.pvt.position),"update"===this.updateType&&n.prototype.update.call(this,i,this.updateKey,e),this.updateType=void 0,e.added)for(h=0;hi&&h.push(c)}for(c=0;cthis.pageSize;)h.results.splice(0,1),h.keys.splice(0,1);return window.localStorage.setItem(this.guidId,JSON.stringify(h)),e},t.prototype.beforeSend=function(e,i,r){!m(this.cacheAdaptor.options.batch)&&le.endsWith(r.url,this.cacheAdaptor.options.batch)&&"post"===r.type.toLowerCase()&&i.headers.set("Accept",this.cacheAdaptor.options.multipartAccept),e.dataSource.crossDomain||i.headers.set("Accept",this.cacheAdaptor.options.accept)},t.prototype.update=function(e,i,r,s){return this.isCrudAction=!0,this.cacheAdaptor.update(e,i,r,s)},t.prototype.insert=function(e,i,r){return this.isInsertAction=!0,this.cacheAdaptor.insert(e,i,r)},t.prototype.remove=function(e,i,r,s){return this.isCrudAction=!0,this.cacheAdaptor.remove(e,i,r,s)},t.prototype.batchRequest=function(e,i,r){return this.cacheAdaptor.batchRequest(e,i,r)},t}(fc),tt=function(){function n(t,e,i){var s,r=this;return this.dateParse=!0,this.timeZoneHandling=!0,this.persistQuery={},this.isInitialLoad=!1,this.requests=[],this.isInitialLoad=!0,!t&&!this.dataSource&&(t=[]),i=i||t.adaptor,t&&!1===t.timeZoneHandling&&(this.timeZoneHandling=t.timeZoneHandling),t instanceof Array?s={json:t,offline:!0}:"object"==typeof t?(t.json||(t.json=[]),t.enablePersistence||(t.enablePersistence=!1),t.id||(t.id=""),t.ignoreOnPersist||(t.ignoreOnPersist=[]),s={url:t.url,insertUrl:t.insertUrl,removeUrl:t.removeUrl,updateUrl:t.updateUrl,crudUrl:t.crudUrl,batchUrl:t.batchUrl,json:t.json,headers:t.headers,accept:t.accept,data:t.data,timeTillExpiration:t.timeTillExpiration,cachingPageSize:t.cachingPageSize,enableCaching:t.enableCaching,requestType:t.requestType,key:t.key,crossDomain:t.crossDomain,jsonp:t.jsonp,dataType:t.dataType,offline:void 0!==t.offline?t.offline:!(t.adaptor instanceof DK||t.adaptor instanceof xK||t.url),requiresFormat:t.requiresFormat,enablePersistence:t.enablePersistence,id:t.id,ignoreOnPersist:t.ignoreOnPersist}):le.throwError("DataManager: Invalid arguments"),void 0===s.requiresFormat&&!le.isCors()&&(s.requiresFormat=!!m(s.crossDomain)||s.crossDomain),void 0===s.dataType&&(s.dataType="json"),this.dataSource=s,this.defaultQuery=e,this.dataSource.enablePersistence&&this.dataSource.id&&window.addEventListener("unload",this.setPersistData.bind(this)),s.url&&s.offline&&!s.json.length?(this.isDataAvailable=!1,this.adaptor=i||new pf,this.dataSource.offline=!1,this.ready=this.executeQuery(e||new Ht),this.ready.then(function(o){r.dataSource.offline=!0,r.isDataAvailable=!0,s.json=o.result,r.adaptor=new VE})):this.adaptor=s.offline?new VE:new pf,!s.jsonp&&this.adaptor instanceof pf&&(s.jsonp="callback"),this.adaptor=i||this.adaptor,s.enableCaching&&(this.adaptor=new TK(this.adaptor,s.timeTillExpiration,s.cachingPageSize)),this}return Object.defineProperty(n.prototype,"moduleName",{get:function(){return"datamanager"},enumerable:!0,configurable:!0}),n.prototype.getPersistedData=function(t){var e=localStorage.getItem(t||this.dataSource.id);return JSON.parse(e)},n.prototype.setPersistData=function(t,e,i){localStorage.setItem(e||this.dataSource.id,JSON.stringify(i||this.persistQuery))},n.prototype.setPersistQuery=function(t){var e=this,i=this.getPersistedData();if(this.isInitialLoad&&i&&Object.keys(i).length){this.persistQuery=i,this.persistQuery.queries=this.persistQuery.queries.filter(function(s){if(e.dataSource.ignoreOnPersist&&e.dataSource.ignoreOnPersist.length&&s.fn&&e.dataSource.ignoreOnPersist.some(function(l){return s.fn===l}))return!1;if("onWhere"===s.fn){var o=s.e;if(o&&o.isComplex&&o.predicates instanceof Array){var a=o.predicates.map(function(l){if(l.predicates&&l.predicates instanceof Array){var h=l.predicates.map(function(v){return new Ss(v.field,v.operator,v.value,v.ignoreCase,v.ignoreAccent,v.matchCase)});return"and"===l.condition?Ss.and(h):Ss.or(h)}return new Ss(l.field,l.operator,l.value,l.ignoreCase,l.ignoreAccent,l.matchCase)});s.e=new Ss(a[0],o.condition,a.slice(1))}}return!0});var r=ze(new Ht,this.persistQuery);return this.isInitialLoad=!1,r}return this.persistQuery=t,this.isInitialLoad=!1,t},n.prototype.setDefaultQuery=function(t){return this.defaultQuery=t,this},n.prototype.executeLocal=function(t){!this.defaultQuery&&!(t instanceof Ht)&&le.throwError("DataManager - executeLocal() : A query is required to execute"),this.dataSource.json||le.throwError("DataManager - executeLocal() : Json data is required to execute"),this.dataSource.enablePersistence&&this.dataSource.id&&(t=this.setPersistQuery(t));var e=this.adaptor.processQuery(this,t=t||this.defaultQuery);if(t.subQuery){var i=t.subQuery.fromTable,r=t.subQuery.lookups,s=t.isCountRequired?e.result:e;r&&r instanceof Array&&le.buildHierarchy(t.subQuery.fKey,i,s,r,t.subQuery.key);for(var o=0;oli");z.classList.remove("json-parent");for(var j=0;j',W=ve.children[0].placeholder}return W}function Q(k,W,ve){!m(ve)&&""!==ve&&K(W,ve.split(" ")),!m(k)&&""!==k&&V(W,k.split(" "))}function oe(k,W,ve){if("multiselect"===ve||function Mo(k){if(!k)return!1;for(var W=k;W&&W!==document.body;){if("none"===window.getComputedStyle(W).display)return!1;W=W.parentElement}return!0}(k)){var Te="multiselect"===ve?k:k.clientWidth-parseInt(getComputedStyle(k,null).getPropertyValue("padding-left"),10);!m(W)&&!m(W.getElementsByClassName("e-float-text-content")[0])&&(W.getElementsByClassName("e-float-text-content")[0].classList.contains("e-float-text-overflow")&&W.getElementsByClassName("e-float-text-content")[0].classList.remove("e-float-text-overflow"),(Te0)for(var Ye=0;Ye<_e.length;Ye++)_e[parseInt(Ye.toString(),10)].addEventListener("mousedown",wo,!1),_e[parseInt(Ye.toString(),10)].addEventListener("mouseup",Ul,!1);else if(_e.length>0)for(Ye=0;Ye<_e.length;Ye++)_e[parseInt(Ye.toString(),10)].removeEventListener("mousedown",wo,this),_e[parseInt(Ye.toString(),10)].removeEventListener("mouseup",Ul,this)}function wo(){for(var W=this.parentElement;!W.classList.contains("e-input-group");)W=W.parentElement;!function Sa(k,W){!k.classList.contains("e-disabled")&&!k.querySelector("input").readOnly&&W.classList.add("e-input-btn-ripple")}(W,this)}function Ul(){var k=this;setTimeout(function(){k.classList.remove("e-input-btn-ripple")},500)}function fb(k,W){var ve=W("span",{className:k});return ve.classList.add("e-input-group-icon"),ve}function p_(k,W,ve,Te){var _e=m(Te)?Si:Te,Ye=fb(k,_e);W.classList.add("e-float-icon-left");var vi=W.querySelector(".e-input-in-wrap");if(m(vi)){vi=_e("span",{className:"e-input-in-wrap"}),ve.parentNode.insertBefore(vi,ve);var Gs=W.querySelectorAll(ve.tagName+" ~ *");vi.appendChild(ve);for(var ts=0;ts-1)if("class"===_e){var Ye=this.getInputValidClassList(k[""+_e]);""!==Ye&&V([W],Ye.split(" "))}else if("style"===_e){var vi=W.getAttribute(_e);vi=m(vi)?k[""+_e]:vi+k[""+_e],W.setAttribute(_e,vi)}else W.setAttribute(_e,k[""+_e])}},n.isBlank=function _le(k){return!k||/^\s*$/.test(k)}}(Le||(Le={})),new RegExp("^(-)?(\\d*)$"),new RegExp("^[A-Za-z0-9._%+-]{1,}@[A-Za-z0-9._%+-]{1,}([.]{1}[a-zA-Z0-9]{2,}|[.]{1}[a-zA-Z0-9]{2,4}[.]{1}[a-zA-Z0-9]{2,4})$"),new RegExp("^([0-9]{4})-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])$"),new RegExp("^[0-9]*$"),new RegExp("^[+]?[0-9]{9,13}$"),new RegExp("^\\d{13,16}$");var me=function(){function n(t,e){this.width=t,this.height=e}return n.prototype.isEmpty=function(){return 0===this.height&&0===this.width},n.prototype.clone=function(){return new n(this.width,this.height)},n}(),wie=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),YB=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},R=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return wie(t,n),t.equals=function(e,i){return e===i||!(!e||!i)&&(!e||!i||e.x===i.x&&e.y===i.y)},t.isEmptyPoint=function(e){return!(e.x&&e.y)},t.transform=function(e,i,r){var s={x:0,y:0};return s.x=Math.round(100*(e.x+r*Math.cos(i*Math.PI/180)))/100,s.y=Math.round(100*(e.y+r*Math.sin(i*Math.PI/180)))/100,s},t.findLength=function(e,i){return Math.sqrt(Math.pow(e.x-i.x,2)+Math.pow(e.y-i.y,2))},t.findAngle=function(e,i){var r=Math.atan2(i.y-e.y,i.x-e.x);return r=180*r/Math.PI,(r%=360)<0&&(r+=360),r},t.distancePoints=function(e,i){return Math.sqrt(Math.pow(i.x-e.x,2)+Math.pow(i.y-e.y,2))},t.getLengthFromListOfPoints=function(e){for(var i=0,r=0;ri.y&&!r?o.y+=s:o.y-=s:e.y===i.y?e.xi.x&&!r?o.x+=s:o.x-=s:r?(a=this.findAngle(e,i),o=this.transform(e,a,s)):(a=this.findAngle(i,e),o=this.transform(i,a,s)),o},t.direction=function(e,i){return Math.abs(i.x-e.x)>Math.abs(i.y-e.y)?e.x0)for(var r=0;rt.right||this.top>t.bottom||this.bottom=t.right&&this.top<=t.top&&this.bottom>=t.bottom},n.prototype.containsPoint=function(t,e){return void 0===e&&(e=0),this.left-e<=t.x&&this.right+e>=t.x&&this.top-e<=t.y&&this.bottom+e>=t.y},n.toBounds=function(t){for(var e=new n,i=0,r=t;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},ZB=function(n){if(n)switch(n.type){case"Linear":default:return vI;case"Radial":return Pie}return vI},Oie=function(){return function n(t,e,i,r){this.left=t,this.right=e,this.top=i,this.bottom=r}}(),Jn=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),rt([I(0)],t.prototype,"left",void 0),rt([I(0)],t.prototype,"right",void 0),rt([I(0)],t.prototype,"top",void 0),rt([I(0)],t.prototype,"bottom",void 0),t}(Ee),kie=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),rt([I(45)],t.prototype,"angle",void 0),rt([I(5)],t.prototype,"distance",void 0),rt([I(.7)],t.prototype,"opacity",void 0),rt([I("lightgrey")],t.prototype,"color",void 0),t}(Ee),JB=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),t.prototype.getClassName=function(){return"Stop"},rt([I("")],t.prototype,"color",void 0),rt([I(0)],t.prototype,"offset",void 0),rt([I(1)],t.prototype,"opacity",void 0),t}(Ee),Sx=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),rt([Ft([],JB)],t.prototype,"stops",void 0),rt([I("None")],t.prototype,"type",void 0),rt([I("")],t.prototype,"id",void 0),t}(Ee),vI=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),rt([I(0)],t.prototype,"x1",void 0),rt([I(0)],t.prototype,"x2",void 0),rt([I(0)],t.prototype,"y1",void 0),rt([I(0)],t.prototype,"y2",void 0),t}(Sx),Pie=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),rt([I(0)],t.prototype,"cx",void 0),rt([I(0)],t.prototype,"cy",void 0),rt([I(0)],t.prototype,"fx",void 0),rt([I(0)],t.prototype,"fy",void 0),rt([I(50)],t.prototype,"r",void 0),t}(Sx),Ll=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),rt([I("white")],t.prototype,"fill",void 0),rt([I("black")],t.prototype,"strokeColor",void 0),rt([I("")],t.prototype,"strokeDashArray",void 0),rt([I(1)],t.prototype,"strokeWidth",void 0),rt([I(1)],t.prototype,"opacity",void 0),rt([w0(ZB)],t.prototype,"gradient",void 0),t}(Ee),KB=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),rt([I("transparent")],t.prototype,"fill",void 0),t}(Ll),Qf=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),rt([I("black")],t.prototype,"color",void 0),rt([I("Arial")],t.prototype,"fontFamily",void 0),rt([I(12)],t.prototype,"fontSize",void 0),rt([I(!1)],t.prototype,"italic",void 0),rt([I(!1)],t.prototype,"bold",void 0),rt([I("CollapseSpace")],t.prototype,"whiteSpace",void 0),rt([I("WrapWithOverflow")],t.prototype,"textWrapping",void 0),rt([I("Center")],t.prototype,"textAlign",void 0),rt([I("None")],t.prototype,"textDecoration",void 0),rt([I("Wrap")],t.prototype,"textOverflow",void 0),rt([I("transparent")],t.prototype,"fill",void 0),t}(Ll),on=function(n){return n[n.Default=0]="Default",n[n.expandNode=2]="expandNode",n[n.interaction=4]="interaction",n[n.GroupingInProgress=8]="GroupingInProgress",n[n.GroupClipboardInProcess=16]="GroupClipboardInProcess",n[n.ClearObject=32]="ClearObject",n}(on||{}),ci=function(n){return n[n.Visible=1]="Visible",n[n.Hidden=2]="Hidden",n[n.Hover=4]="Hover",n[n.Connect=8]="Connect",n}(ci||{}),Kt=function(n){return n[n.None=0]="None",n[n.ShowHorizontalLines=1]="ShowHorizontalLines",n[n.ShowVerticalLines=2]="ShowVerticalLines",n[n.ShowLines=3]="ShowLines",n[n.SnapToHorizontalLines=4]="SnapToHorizontalLines",n[n.SnapToVerticalLines=8]="SnapToVerticalLines",n[n.SnapToLines=12]="SnapToLines",n[n.SnapToObject=16]="SnapToObject",n[n.All=31]="All",n}(Kt||{}),lr=function(n){return n[n.None=1]="None",n[n.ConnectorSourceThumb=2]="ConnectorSourceThumb",n[n.ConnectorTargetThumb=4]="ConnectorTargetThumb",n[n.ResizeSouthEast=8]="ResizeSouthEast",n[n.ResizeSouthWest=16]="ResizeSouthWest",n[n.ResizeNorthEast=32]="ResizeNorthEast",n[n.ResizeNorthWest=64]="ResizeNorthWest",n[n.ResizeEast=128]="ResizeEast",n[n.ResizeWest=256]="ResizeWest",n[n.ResizeSouth=512]="ResizeSouth",n[n.ResizeNorth=1024]="ResizeNorth",n[n.Rotate=2048]="Rotate",n[n.UserHandle=4096]="UserHandle",n[n.ToolTip=8192]="ToolTip",n[n.ResizeAll=2046]="ResizeAll",n[n.All=16382]="All",n}(lr||{}),qe=function(n){return n[n.None=1]="None",n[n.Select=2]="Select",n[n.Delete=4]="Delete",n[n.Drag=8]="Drag",n[n.DragSourceEnd=16]="DragSourceEnd",n[n.DragTargetEnd=32]="DragTargetEnd",n[n.DragSegmentThumb=64]="DragSegmentThumb",n[n.AllowDrop=128]="AllowDrop",n[n.Bridging=256]="Bridging",n[n.BridgeObstacle=512]="BridgeObstacle",n[n.InheritBridging=1024]="InheritBridging",n[n.PointerEvents=2048]="PointerEvents",n[n.Tooltip=4096]="Tooltip",n[n.InheritTooltip=8192]="InheritTooltip",n[n.Interaction=4218]="Interaction",n[n.ReadOnly=16384]="ReadOnly",n[n.LineRouting=32768]="LineRouting",n[n.InheritLineRouting=65536]="InheritLineRouting",n[n.ConnectToNearByNode=131072]="ConnectToNearByNode",n[n.ConnectToNearByPort=262144]="ConnectToNearByPort",n[n.ConnectToNearByElement=393216]="ConnectToNearByElement",n[n.InheritSegmentThumbShape=524288]="InheritSegmentThumbShape",n[n.InheritSegmentThumbSize=1048576]="InheritSegmentThumbSize",n[n.Default=2043454]="Default",n}(qe||{}),Nr=function(n){return n[n.ReadOnly=2]="ReadOnly",n[n.InheritReadOnly=4]="InheritReadOnly",n[n.Select=8]="Select",n[n.Drag=16]="Drag",n[n.Resize=32]="Resize",n[n.Rotate=64]="Rotate",n[n.Tooltip=128]="Tooltip",n[n.Interaction=120]="Interaction",n[n.None=0]="None",n}(Nr||{}),ie=function(n){return n[n.None=0]="None",n[n.Select=2]="Select",n[n.Drag=4]="Drag",n[n.Rotate=8]="Rotate",n[n.Shadow=16]="Shadow",n[n.PointerEvents=32]="PointerEvents",n[n.Delete=64]="Delete",n[n.InConnect=128]="InConnect",n[n.OutConnect=256]="OutConnect",n[n.Individual=512]="Individual",n[n.Expandable=1024]="Expandable",n[n.AllowDrop=2048]="AllowDrop",n[n.Inherit=78]="Inherit",n[n.ResizeNorthEast=4096]="ResizeNorthEast",n[n.ResizeEast=8192]="ResizeEast",n[n.ResizeSouthEast=16384]="ResizeSouthEast",n[n.ResizeSouth=32768]="ResizeSouth",n[n.ResizeSouthWest=65536]="ResizeSouthWest",n[n.ResizeWest=131072]="ResizeWest",n[n.ResizeNorthWest=262144]="ResizeNorthWest",n[n.ResizeNorth=524288]="ResizeNorth",n[n.Resize=1044480]="Resize",n[n.AspectRatio=1048576]="AspectRatio",n[n.Tooltip=2097152]="Tooltip",n[n.InheritTooltip=4194304]="InheritTooltip",n[n.ReadOnly=8388608]="ReadOnly",n[n.HideThumbs=16777216]="HideThumbs",n[n.AllowMovingOutsideLane=33554432]="AllowMovingOutsideLane",n[n.Default=5240814]="Default",n}(ie||{}),Xr=function(n){return n[n.None=0]="None",n[n.ElementIsPort=2]="ElementIsPort",n[n.ElementIsGroup=4]="ElementIsGroup",n[n.HorizontalLaneHeader=8]="HorizontalLaneHeader",n}(Xr||{}),bt=function(n){return n[n.Rotate=2]="Rotate",n[n.ConnectorSource=4]="ConnectorSource",n[n.ConnectorTarget=8]="ConnectorTarget",n[n.ResizeNorthEast=16]="ResizeNorthEast",n[n.ResizeEast=32]="ResizeEast",n[n.ResizeSouthEast=64]="ResizeSouthEast",n[n.ResizeSouth=128]="ResizeSouth",n[n.ResizeSouthWest=256]="ResizeSouthWest",n[n.ResizeWest=512]="ResizeWest",n[n.ResizeNorthWest=1024]="ResizeNorthWest",n[n.ResizeNorth=2048]="ResizeNorth",n[n.Default=4094]="Default",n}(bt||{}),nt=function(n){return n[n.None=1]="None",n[n.Bridging=2]="Bridging",n[n.UndoRedo=4]="UndoRedo",n[n.Tooltip=8]="Tooltip",n[n.UserInteraction=16]="UserInteraction",n[n.ApiUpdate=32]="ApiUpdate",n[n.PageEditable=48]="PageEditable",n[n.Zoom=64]="Zoom",n[n.PanX=128]="PanX",n[n.PanY=256]="PanY",n[n.Pan=384]="Pan",n[n.ZoomTextEdit=512]="ZoomTextEdit",n[n.Virtualization=1024]="Virtualization",n[n.LineRouting=2048]="LineRouting",n[n.Default=500]="Default",n}(nt||{}),ri=function(n){return n[n.None=0]="None",n[n.SingleSelect=1]="SingleSelect",n[n.MultipleSelect=2]="MultipleSelect",n[n.ZoomPan=4]="ZoomPan",n[n.DrawOnce=8]="DrawOnce",n[n.ContinuousDraw=16]="ContinuousDraw",n[n.Default=3]="Default",n}(ri||{}),Qa=function(n){return n[n.Self=1]="Self",n[n.Parent=2]="Parent",n}(Qa||{}),ft=function(n){return n[n.None=0]="None",n[n.Control=1]="Control",n[n.Meta=1]="Meta",n[n.Alt=2]="Alt",n[n.Shift=4]="Shift",n}(ft||{}),Mt=function(n){return n[n.None=null]="None",n[n.Number0=0]="Number0",n[n.Number1=1]="Number1",n[n.Number2=2]="Number2",n[n.Number3=3]="Number3",n[n.Number4=4]="Number4",n[n.Number5=5]="Number5",n[n.Number6=6]="Number6",n[n.Number7=7]="Number7",n[n.Number8=8]="Number8",n[n.Number9=9]="Number9",n[n.A=65]="A",n[n.B=66]="B",n[n.C=67]="C",n[n.D=68]="D",n[n.E=69]="E",n[n.F=70]="F",n[n.G=71]="G",n[n.H=72]="H",n[n.I=73]="I",n[n.J=74]="J",n[n.K=75]="K",n[n.L=76]="L",n[n.M=77]="M",n[n.N=78]="N",n[n.O=79]="O",n[n.P=80]="P",n[n.Q=81]="Q",n[n.R=82]="R",n[n.S=83]="S",n[n.T=84]="T",n[n.U=85]="U",n[n.V=86]="V",n[n.W=87]="W",n[n.X=88]="X",n[n.Y=89]="Y",n[n.Z=90]="Z",n[n.Left=37]="Left",n[n.Up=38]="Up",n[n.Right=39]="Right",n[n.Down=40]="Down",n[n.Escape=27]="Escape",n[n.Space=32]="Space",n[n.PageUp=33]="PageUp",n[n.PageDown=34]="PageDown",n[n.End=35]="End",n[n.Home=36]="Home",n[n.Delete=46]="Delete",n[n.Tab=9]="Tab",n[n.Enter=13]="Enter",n[n.BackSpace=8]="BackSpace",n[n.F1=112]="F1",n[n.F2=113]="F2",n[n.F3=114]="F3",n[n.F4=115]="F4",n[n.F5=116]="F5",n[n.F6=117]="F6",n[n.F7=118]="F7",n[n.F8=119]="F8",n[n.F9=120]="F9",n[n.F10=121]="F10",n[n.F11=122]="F11",n[n.F12=123]="F12",n[n.Star=56]="Star",n[n.Plus=187]="Plus",n[n.Minus=189]="Minus",n[n.BracketLeft=219]="BracketLeft",n[n.BracketRight=221]="BracketRight",n}(Mt||{}),ee=function(n){return n[n.Render=2]="Render",n[n.PublicMethod=4]="PublicMethod",n[n.ToolAction=8]="ToolAction",n[n.UndoRedo=16]="UndoRedo",n[n.TextEdit=32]="TextEdit",n[n.Group=64]="Group",n[n.Clear=128]="Clear",n[n.PreventClearSelection=256]="PreventClearSelection",n[n.Interactions=512]="Interactions",n[n.PreventHistory=1024]="PreventHistory",n[n.PreventIconsUpdate=2048]="PreventIconsUpdate",n[n.PreventCollectionChangeOnDragOver=4096]="PreventCollectionChangeOnDragOver",n[n.PreventZIndexOnDragging=8192]="PreventZIndexOnDragging",n[n.isGroupDragging=16384]="isGroupDragging",n[n.DragUsingMouse=32768]="DragUsingMouse",n[n.DecoratorPropertyChange=65536]="DecoratorPropertyChange",n[n.PreventLaneContainerUpdate=131072]="PreventLaneContainerUpdate",n}(ee||{}),Ga=function(n){return n[n.None=2]="None",n[n.DrawSelectorBorder=4]="DrawSelectorBorder",n[n.PreventRenderSelector=8]="PreventRenderSelector",n}(Ga||{}),$i=function(n){return n[n.None=0]="None",n[n.PreventDrag=2]="PreventDrag",n[n.PreventScale=4]="PreventScale",n[n.PreventDataInit=8]="PreventDataInit",n[n.hScrollbarMoved=16]="hScrollbarMoved",n[n.vScrollbarMoved=32]="vScrollbarMoved",n[n.AnimationClick=64]="AnimationClick",n[n.EnableGroupAction=128]="EnableGroupAction",n[n.PanInProgress=256]="PanInProgress",n[n.OverViewAction=512]="OverViewAction",n}($i||{}),da=function(n){return n[n.None=0]="None",n[n.PropertyChange=1024]="PropertyChange",n[n.Interaction=2048]="Interaction",n}(da||{}),Ae=function(n){return n[n.Zero=0]="Zero",n[n.One=1]="One",n[n.Two=2]="Two",n[n.Three=3]="Three",n[n.Four=4]="Four",n[n.Five=5]="Five",n}(Ae||{}),Ce=function(n){return n[n.collectionChange=0]="collectionChange",n[n.rotateChange=1]="rotateChange",n[n.positionChange=2]="positionChange",n[n.propertyChange=3]="propertyChange",n[n.selectionChange=4]="selectionChange",n[n.sizeChange=5]="sizeChange",n[n.drop=6]="drop",n[n.sourcePointChange=7]="sourcePointChange",n[n.targetPointChange=8]="targetPointChange",n[n.connectionChange=9]="connectionChange",n[n.animationComplete=10]="animationComplete",n[n.click=11]="click",n[n.doubleClick=12]="doubleClick",n[n.scrollChange=13]="scrollChange",n[n.dragEnter=14]="dragEnter",n[n.dragLeave=15]="dragLeave",n[n.dragOver=16]="dragOver",n[n.textEdit=17]="textEdit",n[n.paletteSelectionChange=18]="paletteSelectionChange",n[n.historyChange=19]="historyChange",n[n.mouseEnter=20]="mouseEnter",n[n.mouseLeave=21]="mouseLeave",n[n.mouseOver=22]="mouseOver",n[n.expandStateChange=23]="expandStateChange",n[n.segmentCollectionChange=24]="segmentCollectionChange",n[n.commandExecute=25]="commandExecute",n[n.historyStateChange=26]="historyStateChange",n[n.onUserHandleMouseDown=27]="onUserHandleMouseDown",n[n.onUserHandleMouseUp=28]="onUserHandleMouseUp",n[n.onUserHandleMouseEnter=29]="onUserHandleMouseEnter",n[n.onUserHandleMouseLeave=30]="onUserHandleMouseLeave",n[n.onImageLoad=31]="onImageLoad",n[n.onDoBindingInit=32]="onDoBindingInit",n[n.keyUp=33]="keyUp",n[n.keyDown=34]="keyDown",n[n.fixedUserHandleClick=35]="fixedUserHandleClick",n[n.elementDraw=36]="elementDraw",n[n.mouseWheel=37]="mouseWheel",n[n.segmentChange=38]="segmentChange",n[n.onFixedUserHandleMouseDown=39]="onFixedUserHandleMouseDown",n[n.onFixedUserHandleMouseUp=40]="onFixedUserHandleMouseUp",n[n.onFixedUserHandleMouseEnter=41]="onFixedUserHandleMouseEnter",n[n.onFixedUserHandleMouseLeave=42]="onFixedUserHandleMouseLeave",n[n.loaded=43]="loaded",n}(Ce||{}),oi=function(n){return n[n.None=1]="None",n[n.Drag=2]="Drag",n[n.Draw=4]="Draw",n[n.InConnect=8]="InConnect",n[n.OutConnect=16]="OutConnect",n[n.ToolTip=32]="ToolTip",n[n.InheritTooltip=64]="InheritTooltip",n[n.Default=24]="Default",n}(oi||{}),Ix=function(n){return n[n.None=1]="None",n[n.Source=2]="Source",n[n.Target=4]="Target",n[n.Intermediate=8]="Intermediate",n[n.All=14]="All",n}(Ix||{}),mI=function(n){return n[n.None=0]="None",n[n.SymmetricAngle=2]="SymmetricAngle",n[n.SymmetricDistance=4]="SymmetricDistance",n[n.Default=6]="Default",n}(mI||{}),hs=function(){function n(){this.pivot={x:.5,y:.5},this.isDirt=!0,this.isExport=!1,this.exportScaleValue={x:0,y:0},this.exportScaleOffset={x:0,y:0},this.canApplyStyle=!0,this.visible=!0,this.offsetX=0,this.offsetY=0,this.cornerRadius=0,this.minHeight=void 0,this.minWidth=void 0,this.maxWidth=void 0,this.maxHeight=void 0,this.width=void 0,this.height=void 0,this.rotateAngle=0,this.margin={left:0,right:0,top:0,bottom:0},this.connectionDirection="Auto",this.horizontalAlignment="Auto",this.verticalAlignment="Auto",this.flip="None",this.flipMode="All",this.relativeMode="Point",this.transform=Qa.Self|Qa.Parent,this.style={fill:"white",strokeColor:"black",opacity:1,strokeWidth:1},this.desiredSize=new me,this.actualSize=new me,this.parentTransform=0,this.preventContainer=!1,this.isSvgRender=!1,this.bounds=new Ne(0,0,0,0),this.shadow=null,this.description="",this.staticSize=!1,this.shapeType="",this.isRectElement=!1,this.isCalculateDesiredSize=!0,this.flipOffset={x:0,y:0},this.elementActions=Xr.None,this.inversedAlignment=!0,this.position=void 0,this.unitMode=void 0,this.float=!1,this.floatingBounds=void 0}return n.prototype.setOffsetWithRespectToBounds=function(t,e,i){this.unitMode=i,this.position={x:t,y:e}},n.prototype.getAbsolutePosition=function(t){if(void 0!==this.position)return"Absolute"===this.unitMode?this.position:{x:this.position.x*t.width,y:this.position.y*t.height}},Object.defineProperty(n.prototype,"outerBounds",{get:function(){return this.floatingBounds||this.bounds},set:function(t){this.floatingBounds=t},enumerable:!0,configurable:!0}),n.prototype.measure=function(t,e,i){var s=void 0!==this.height?this.height:(t.height||0)-this.margin.top-this.margin.bottom;return this.id&&0===s&&this.elementActions&Xr.HorizontalLaneHeader&&(s=this.actualSize.height),this.desiredSize=new me(void 0!==this.width?this.width:(t.width||0)-this.margin.left-this.margin.right,s),this.isCalculateDesiredSize&&(this.desiredSize=this.validateDesiredSize(this.desiredSize,t)),this.desiredSize},n.prototype.arrange=function(t){return this.actualSize=t,this.updateBounds(),this.actualSize},n.prototype.updateBounds=function(){this.bounds=yr(this)},n.prototype.validateDesiredSize=function(t,e){return this.isRectElement&&!this.width&&!this.minWidth&&!this.maxWidth&&(t.width=50),this.isRectElement&&!this.height&&!this.minHeight&&!this.maxHeight&&(t.height=50),(void 0===t||void 0!==this.width&&void 0!==this.height)&&((t=t||new me).width=void 0===this.width?(e.width||0)-this.margin.left-this.margin.right:this.width,t.height=void 0===this.height?(e.height||0)-this.margin.top-this.margin.bottom:this.height),void 0!==this.minWidth&&(t.width=Math.max(t.width,this.minWidth)),void 0!==this.minHeight&&(t.height=Math.max(t.height,this.minHeight)),void 0!==this.maxWidth&&0!==this.maxWidth&&(t.width=Math.min(t.width,this.maxWidth)),void 0!==this.maxHeight&&0!==this.maxHeight&&(t.height=Math.min(t.height,this.maxHeight)),t},n}(),Uie=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Cs=function(n){function t(){var e=null!==n&&n.apply(this,arguments)||this;return e.padding=new Oie(0,0,0,0),e.desiredBounds=void 0,e.measureChildren=!0,e.prevRotateAngle=0,e}return Uie(t,n),t.prototype.hasChildren=function(){return void 0!==this.children&&this.children.length>0},t.prototype.measure=function(e,i,r){this.desiredBounds=void 0;var o,a,s=void 0;if(this.hasChildren()){for(var l=0;l=n.width&&s.length>0)i[i.length]={text:s,x:0,dy:0,width:o},s="";else{(s+=a[r+1]||"").indexOf("\n")>-1&&(i[i.length]={text:s,x:0,dy:0,width:Bc(s,n)},s="");var l=Bc(s,n);Math.ceil(l)+2>=n.width&&s.length>0&&(i[i.length]={text:s,x:0,dy:0,width:l},s=""),r===a.length-1&&s.length>0&&(i[i.length]={text:s,x:0,dy:0,width:l},s="")}else i=function ooe(n,t,e){var c,d,u,f,i=[],r="",s=0,o=0,a="nowrap"!==n.whiteSpace,h=(t||n.content).split("\n");for(s=0;s0?" ":"")+c[parseInt(o.toString(),10)];var p=Bc(d=c[o+1]?r+" "+c[o+1]:r,n);Math.floor(p)>(e||n.width)-2&&r.length>0?(i[i.length]={text:r,x:0,dy:0,width:d===r?p:r===f?u:Bc(r,n)},r=""):o===c.length-1&&(i[i.length]={text:r,x:0,dy:0,width:p},r=""),f=d,u=p}return i}(n,t,e);else i[i.length]={text:a,x:0,dy:0,width:Bc(a,n)};return i}(l,r,n.isLaneOrientation?i:void 0),n.wrapBounds=a=function aoe(n,t){var r,s,e={x:0,width:0},i=0;for(i=0;in.width&&("Ellipsis"===n.textOverflow||"Clip"===n.textOverflow)?0:-r/2:"right"===n.textAlign?-r:t.length>1?0:-r/2,t[parseInt(i.toString(),10)].dy=1.2*n.fontSize,t[parseInt(i.toString(),10)].x=r,e.x=Math.min(e.x,r),e.width=Math.max(e.width,s);return e}(l,o),s.width=a.width,n.wrapBounds.width>=i&&"Wrap"!==l.textOverflow&&(s.width=i),s.height=o.length*n.style.fontSize*1.2,s}(this,0,0,this.isLaneOrientation?e.height:this.width||e.width):this.desiredSize,this.desiredSize=void 0===this.width||void 0===this.height?new me(i.width,i.height):new me(this.width,this.height),this.desiredSize=this.validateDesiredSize(this.desiredSize,e),this.desiredSize},t.prototype.arrange=function(e){return(e.width!==this.actualSize.width||e.height!==this.actualSize.height||this.isDirt)&&(this.doWrap=!0),this.actualSize=e,this.updateBounds(),this.isDirt=!1,this.actualSize},t}(hs),Vie=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Mi=function(n){function t(){var e=null!==n&&n.apply(this,arguments)||this;return e.measureChildren=void 0,e}return Vie(t,n),t.prototype.measure=function(e,i,r){var s=void 0,o=void 0;if(this.hasChildren()){for(var a=0,l=this.children;a=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Dd=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Xie(t,n),Oh([I("")],t.prototype,"content",void 0),Oh([I("TopLeft")],t.prototype,"position",void 0),Oh([I("Mouse")],t.prototype,"relativeMode",void 0),Oh([I(!0)],t.prototype,"showTipPointer",void 0),Oh([I("auto")],t.prototype,"width",void 0),Oh([I("auto")],t.prototype,"height",void 0),Oh([I("Auto")],t.prototype,"openOn",void 0),Oh([I()],t.prototype,"animation",void 0),Oh([I(!1)],t.prototype,"isSticky",void 0),t}(Ee);function e3(n){var t=new bh;t=t3(n.tooltip,t);var e=new bh(t);return e.beforeCollision=$ie,e.beforeOpen=qie,e.cssClass="e-diagram-tooltip",e.opensOn="custom",e.appendTo("#"+n.element.id),e.close(),e}function qie(n){(""===this.content||void 0===this.content)&&(n.element.style.display="none")}function $ie(n){n.collidedPosition&&n.collidedPosition!==this.position&&(n.element.style.display="none")}function bx(n,t){var e=n.tooltipObject;return t3(t?t.tooltip:n.tooltip,e),e}function t3(n,t){return n.content?(t.content=n.content,"string"==typeof n.content&&(t.content=ko(function(){return n.content})),t.position=n.position,t.showTipPointer=n.showTipPointer,t.width=n.width,t.height=n.height,t.animation=n.animation?n.animation:{close:{effect:"None"}}):t.close(),t}var Mx=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Bn=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},wx=function(n){function t(e,i,r,s){var o=n.call(this,e,i,r,s)||this;return o.inEdges=[],o.outEdges=[],o}return Mx(t,n),Bn([I("")],t.prototype,"id",void 0),Bn([I("Center")],t.prototype,"horizontalAlignment",void 0),Bn([I("Center")],t.prototype,"verticalAlignment",void 0),Bn([re({},Jn)],t.prototype,"margin",void 0),Bn([I(12)],t.prototype,"width",void 0),Bn([I(12)],t.prototype,"height",void 0),Bn([re({},Ll)],t.prototype,"style",void 0),Bn([I("Square")],t.prototype,"shape",void 0),Bn([I("Auto")],t.prototype,"connectionDirection",void 0),Bn([I(ci.Connect)],t.prototype,"visibility",void 0),Bn([I("")],t.prototype,"pathData",void 0),Bn([I(oi.Default)],t.prototype,"constraints",void 0),Bn([I()],t.prototype,"addInfo",void 0),Bn([I()],t.prototype,"outEdges",void 0),Bn([I()],t.prototype,"inEdges",void 0),Bn([re({},Dd)],t.prototype,"tooltip",void 0),t}(Ee),Es=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return Mx(t,n),t.prototype.getClassName=function(){return"PointPort"},Bn([re({x:.5,y:.5},R)],t.prototype,"offset",void 0),t}(wx),Tc=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return Mx(t,n),t.prototype.getClassName=function(){return"PathPort"},Bn([I(.5)],t.prototype,"offset",void 0),Bn([re({x:0,y:0},R)],t.prototype,"displacement",void 0),Bn([I("Center")],t.prototype,"alignment",void 0),t}(wx),II=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),hr=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Zie=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return II(t,n),hr([I("blue")],t.prototype,"color",void 0),hr([I("")],t.prototype,"content",void 0),hr([I("")],t.prototype,"link",void 0),hr([I("None")],t.prototype,"textDecoration",void 0),hr([I("NewTab")],t.prototype,"hyperlinkOpenState",void 0),t}(Ee),Cx=function(n){function t(e,i,r,s){var o=n.call(this,e,i,r,s)||this;return r.id||(o.id=e.parentObj&&e.parentObj.propName&&"phases"===e.parentObj.propName?e.parentObj.id:Qe()),o}return II(t,n),hr([I("")],t.prototype,"content",void 0),hr([I(void 0)],t.prototype,"template",void 0),hr([I("String")],t.prototype,"annotationType",void 0),hr([I(!0)],t.prototype,"visibility",void 0),hr([I(Nr.InheritReadOnly)],t.prototype,"constraints",void 0),hr([re(void 0,Zie)],t.prototype,"hyperlink",void 0),hr([I("")],t.prototype,"id",void 0),hr([I()],t.prototype,"width",void 0),hr([I()],t.prototype,"height",void 0),hr([I(0)],t.prototype,"rotateAngle",void 0),hr([I("Parent")],t.prototype,"rotationReference",void 0),hr([re({strokeWidth:0,strokeColor:"transparent",fill:"transparent"},Qf)],t.prototype,"style",void 0),hr([I("Center")],t.prototype,"horizontalAlignment",void 0),hr([I("Center")],t.prototype,"verticalAlignment",void 0),hr([re({},Jn)],t.prototype,"margin",void 0),hr([re({top:void 0,bottom:void 0,left:void 0,right:void 0},Jn)],t.prototype,"dragLimit",void 0),hr([I("Shape")],t.prototype,"type",void 0),hr([re({},Dd)],t.prototype,"tooltip",void 0),hr([I()],t.prototype,"addInfo",void 0),t}(Ee),Kn=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return II(t,n),t.prototype.getClassName=function(){return"ShapeAnnotation"},hr([re({x:.5,y:.5},R)],t.prototype,"offset",void 0),t}(Cx),Or=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return II(t,n),t.prototype.getClassName=function(){return"PathAnnotation"},hr([I(.5)],t.prototype,"offset",void 0),hr([re({x:0,y:0},R)],t.prototype,"displacement",void 0),hr([I("Center")],t.prototype,"alignment",void 0),hr([I(!1)],t.prototype,"segmentAngle",void 0),t}(Cx);function Ex(n){return tre[n.toString()]}function i3(n){return nre[""+n]}var tre={X:"M14,14 L106,106 M106,14 L14,106",Circle:"M0,50 A50,50,0 1 1 100,50 A50,50,0 1 1 0,50 Z",Square:"M0,0 L10,0 L10,10 L0,10 z"},ire={OpenArrow:"M15.9,23 L5,16 L15.9,9 L17,10.7 L8.7,16 L17,21.3Z",Square:"M0,0 L10,0 L10,10 L0,10 z",Fletch:"M14.8,10c0,0-3.5,6,0.2,12c0,0-2.5-6-10.9-6C4.1,16,11.3,16,14.8,10z",OpenFetch:"M6,17c-0.6,0-1-0.4-1-1s0.4-1,1-1c10.9,0,11-5,11-5c0-0.6,0.4-1,1-1s1,0.4,1,1C19,10.3,18.9,17,6,17C6,17,6,17,6,17z M18,23c-0.5,0-1-0.4-1-1c0-0.2-0.3-5-11-5c-0.6,0-1-0.5-1-1s0.4-1,1-1c0,0,0,0,0,0c12.9,0,13,6.7,13,7 C19,22.6,18.6,23,18,23z",IndentedArrow:"M17,10c0,0-4.5,5.5,0,12L5,16L17,10z",OutdentedArrow:"M14.6,10c0,0,5.4,6,0,12L5,16L14.6,10z",DoubleArrow:"M19,10 L19,22 L13,16Z M12,10 L12,22 L6,16Z",Arrow:"M15,10 L15,22 L5,16Z",Diamond:"M12,23l-7-7l7-7l6.9,7L12,23z",Circle:"M0,50 A50,50,0 1 1 100,50 A50,50,0 1 1 0,50 Z"},rre={Square:"M0,0 L10,0 L10,10 L0,10 z",Rhombus:"M10,5 L5,10 L0,5 L5,0 L10,5 Z ",Rectangle:"M0,0 L15,0 L15,10 L0,10 z ",OpenArrow:"M15.9,23 L5,16 L15.9,9 L17,10.7 L8.7,16 L17,21.3Z",Fletch:"M9.82,0 C9.82,0,6.61,5,10,10 C10,10,7.71,5,0,5 C0,5,6.61,5,9.82,0 Z ",OpenFetch:"M0.71,5.71 C0.29,5.71,0,5.43,0,5 C0,4.57,0.29,4.29,0.71,4.29 C8.5,4.29,8.57,0.71,8.57,0.71 C8.57,0.29,8.86,0,9.29,0 C9.719999999999999,0,10,0.29,10,0.71 C10,0.93,9.93,5.71,0.71,5.71 C0.71,5.71,0.71,5.71,0.71,5.71 Z M9.29,10 C8.93,10,8.57,9.71,8.57,9.29 C8.57,9.14,8.36,5.71,0.71,5.71 C0.29,5.71,0,5.36,0,5 C0,4.64,0.29,4.29,0.71,4.29 C0.71,4.29,0.71,4.29,0.71,4.29 C9.93,4.29,10,9.07,10,9.29 C10,9.71,9.71,10,9.29,10 Z ",IndentedArrow:"M10,0 C10,0,6.25,4.58,10,10 L0,5 L10,0 Z ",OutdentedArrow:"M8,0 C8,0,12.5,5,8,10 L0,5 L8,0 Z ",DoubleArrow:"M19,10 L19,22 L13,16Z M12,10 L12,22 L6,16Z",Arrow:"M15,10 L15,22 L5,16Z",Diamond:"M10,5 L5,10 L0,5 L5,0 L10,5 Z ",Circle:"M10,5 C10,7.76,7.76,10,5,10 C2.24,10,0,7.76,0,5 C0,2.24,2.24,0,5,0 C7.76,0,10,2.24,10,5 Z ",Ellipse:"M15,5 C15,7.76,11.64,10,7.5,10 C3.36,10,0,7.76,0,5 C0,2.24,3.36,0,7.5,0 C11.64,0,15,2.24,15,5 Z "},nre={Square:"M0,0 L10,0 L10,10 L0,10 z",Rhombus:"M10,5 L5,10 L0,5 L5,0 L10,5 Z ",Rectangle:"M0,0 L15,0 L15,10 L0,10 z",OpenArrow:"M23,15.9 L16,5 L9,15.9 L10.7,17 L16,8.7 L21,17.3Z",Fletch:"M9.82,0 C9.82,0,6.61,5,10,10 C10,10,7.71,5,0,5 C0,5,6.61,5,9.82,0 Z ",OpenFetch:"M0.71,5.71 C0.29,5.71,0,5.43,0,5 C0,4.57,0.29,4.29,0.71,4.29 C8.5,4.29,8.57,0.71,8.57,0.71 C8.57,0.29,8.86,0,9.29,0 C9.719999999999999,0,10,0.29,10,0.71 C10,0.93,9.93,5.71,0.71,5.71 C0.71,5.71,0.71,5.71,0.71,5.71 Z M9.29,10 C8.93,10,8.57,9.71,8.57,9.29 C8.57,9.14,8.36,5.71,0.71,5.71 C0.29,5.71,0,5.36,0,5 C0,4.64,0.29,4.29,0.71,4.29 C0.71,4.29,0.71,4.29,0.71,4.29 C9.93,4.29,10,9.07,10,9.29 C10,9.71,9.71,10,9.29,10 Z ",IndentedArrow:"M10,0 C10,0,6.25,4.58,10,10 L0,5 L10,0 Z ",OutdentedArrow:"M8,0 C8,0,12.5,5,8,10 L0,5 L8,0 Z ",DoubleArrow:"M10,19 L22,19 L16,13Z M10,12 L22,12 L16,6Z",Arrow:"M10,15 L22,15 L16,5Z",Diamond:"M10,5 L5,10 L0,5 L5,0 L10,5 Z ",Circle:"M10,5 C10,7.76,7.76,10,5,10 C2.24,10,0,7.76,0,5 C0,2.24,2.24,0,5,0 C7.76,0,10,2.24,10,5 Z ",Ellipse:"M15,5 C15,7.76,11.64,10,7.5,10 C3.36,10,0,7.76,0,5 C0,2.24,3.36,0,7.5,0 C11.64,0,15,2.24,15,5 Z "};function Dx(n){return sre[n.toString()]}var sre={Process:"M419.511,76.687L359.511,76.687L359.511,43.086L419.511,43.086z",Decision:"M 253.005,115.687L 200.567,146.071L 148.097,115.687L 200.534,85.304L 253.005,115.687 Z",Document:"M 60 31.9 c 0 0 -11 -7.7 -30 0 s -30 0 -30 0 V 0 h 60 V 31.9 Z",PreDefinedProcess:"M 0,0 L 50,0 L 50,50 L 0,50 Z M 8.334,0 L 8.334,50 M 41.667,0 L 41.667,50",Terminator:"M 269.711,29.33C 269.71,44.061 257.77,56 243.04,56L 158.058,56C 143.33,56 131.39,44.061 131.39,29.33L 131.39,29.33C 131.391,14.6057 143.33,2.669 158.058,2.669L 243.044,2.669C 257.772,2.669 269.711,14.6057 269.711,29.333 Z",PaperTap:"M0.0009,17.2042 L0.0009,47.165 C0.001,47.165 14.403,53.5455 25.00,47.165 C35.599,40.7852 44.403,43.5087 50.00,47.165L50.001,17.2042 M50.001,32.7987 L50.001,2.8405 C50.001,2.8405 35.599,-3.5427 25.001,2.8405C14.403,9.2237 5.599,6.494 0.0009,2.8405 L0.0009,32.7987",DirectData:"M 132.62 0 L 17.38 0 C 7.78 0 0 13.43 0 30 C 0 46.57 7.78 60 17.38 60 L 132.62 60 M 132.62 0C 123.02 0 115.24 13.43 115.24 30 C 115.24 46.57 123.02 60 132.62 60 C 142.22 60 150 46.57 150 30 C 150 13.43 142.22 0 132.62 0 z ",SequentialData:"M0.0029,24.999 C0.0029,11.1922 10.433,0.0021 23.295,0.0021 C36.159,0.00216 46.585,11.1922 46.585,24.999C46.585,38.8057 36.159,49.9979 23.295,49.9979 C10.433,49.9979 0.0029,38.8057 0.0029,24.999 z M23.294,49.999 L50.002,49.999",Sort:"M50.001,24.9971 L25.001,49.9971 L0.00097,24.9971 L25.001,-0.00286865 L50.001,24.9971 z M0.000976562,24.9971 L50.001,24.9971",MultiDocument:"M43.6826,40 C44.8746,40.6183 45.8586,41.3502 46.8366,42.1122 L46.8366,4.74487 L3.09857,4.74487 L3.09857,10.9544 M46.837,35.143 C48.027,35.765 49.025,36.604 50.003,37.369 L50.003,0.002 L6.264,0.002 L6.264,4.744 M43.682,47.113 L43.682,10.765 L0.0025,10.7652 L0.0025,47.1132 C0.0025,47.1132 12.5846,53.6101 21.8426,47.1132 C31.1006,40.6163 38.792,43.393 43.6826,47.1132 z",Collate:"M50.001,0.0028 L25.001,25.0029 L0.00097,0.0028 L50.001,0.002 z M0.0009,50.002 L25.001,25.002L50.001,50.002 L0.0009,50.0029 z",SummingJunction:"M7.3252,42.6768 L42.6772,7.3247 M42.6768,42.6768 L7.3248,7.3247 M0.0009,25.001 C0.0009,11.193 11.197,0.0009 25.001,0.0009 C38.809,0.0009 50.001,11.193 50.001,25.001 C50.001,38.809 38.809,50.001 25.001,50.001 C11.197,50.00 0.0009,38.809 0.0009,25.00 z",Or:"M 0 50 L 100 50 M 50 100 L 50 0.0 M 0 50 C 0 22.384 22.392 0 50 0 C 77.616 0 100 22.384 100 50 C 100 77.616 77.616 100 50 100 C 22.392 100 0 77.616 0 50 Z",InternalStorage:"M 0 3.81946A 2.5,3.81946 0 0,1 2.5,0L 47.5 0A 2.5,3.81946 0 0,1 50,3.81946L 50 45.836A 2.5,3.819446 0 0,1 47.5,49.652778L 2.5 49.652778A 2.5,3.819446 0 0,1 0,45.8336L 0 3.819446ZM 0 11.45834L 50 11.4583334M 12.5 0L 12.5 49.652778",Extract:"M0,35 L30,0 L60,35 Z",ManualOperation:"M46.4,28.8 L14.8,28.8 L0,0 L60,0 Z",Merge:"M60,0 L30,35 L0,0 Z",OffPageReference:"M60,33.3 L30.1,39 L0,33.3 L0,0 L60,0 Z",SequentialAccessStorage:"M 60 30 C 60 13.4 46.6 0 30 0 S 0 13.4 0 30 s 13.4 30 30 30 h 28.6 v -6.5 h -9.9C 55.5 48 60 39.5 60 30 Z",Annotation:"M49.9984,50.0029 L-0.00271199,50.0029 L-0.00271199,0.00286865 L49.9984,0.00286865",Annotation2:"M49.9977,50.0029 L25.416,50.0029 L25.416,0.00286865 L49.9977,0.00286865 M25.4166,25.0029 L-0.00227869,25.0029",Data:"M 10 0 L 40 0 L 30 40 L 0 40 Z",Card:"M275,60 L400,60 L400,110 L260,110 L260,75 Z",Delay:"M0,0 L12.029,0 C14.212999,0 16,1.7869979 16,3.9709952 C16,6.1549926 14.212999,7.9409904 12.029,7.9409904 L0,7.9409904 z",Preparation:"M 1048.17 572 C 1051.06 568.86 1055.17 567.05 1059.5 567 L 1094.51 567 C 1098.84 567.05 1102.95 568.86 1105.84 572 L 1126.43 595 C 1127.01 596.28 1127.01 597.72 1126.43 599 L 1105.84 622 C 1102.95 625.14 1098.84 626.95 1094.51 627 L 1059.5 627 C 1055.17 626.95 1051.06 625.14 1048.17 622 L 1027.58 599 C 1027 597.72 1027 596.28 1027.58 595 L 1048.17 572 Z",Display:"M47.8809,19.2914 L32.7968,-0.00594145 L11.3902,-0.00594145 C7.93166,-0.00594145 0.00124586,11.187 0.00124586,24.9968C0.00124586,38.8032 7.93166,49.9962 11.3902,49.9962 L32.7968,49.99 L47.615,31.038 C47.615,31.0388 52.798,24.9968 47.880,19.2914 z",ManualInput:"M 912 732 L 1006.85 707 C 1008.2 707 1009.5 707.53 1010.46 708.46 C 1011.41 709.4 1011.95 710.67 1011.95 712 L 1011.95 762C 1012 764.41 1010.28 766.52 1007.87 767 L 917.1 767 C 915.75 767 914.45 766.47 913.49 765.54 C 912.54 764.6 912 763.33 912 762 L 912 732 Z",LoopLimit:"M 8 9 L 27 9 L 33 15 L 33 26 C 33 27 33 27 32 27 L 4 27 C 3 27 2 27 2 26 L 2 15 L 8 9 Z",StoredData:"M 5.55 0L 50 0A 1.5,30 0 0,1 50,0A 5.555,25 0 0,0 50,50A 1.5,30 0 0,1 50,50L 5.555 50A 5.55,25 0 0,1 5.555,0Z"};function r3(n,t,e){var i;i="Straight"!==n.type&&n.sourceWrapper?n.sourceWrapper.corners.center:function ore(n){var t;if(n.sourcePortWrapper){var e=n.sourcePortWrapper;t={x:e.offsetX,y:e.offsetY}}else t=n.sourceID&&n.sourceWrapper&&n.targetWrapper?qa(n,0,n.sourceWrapper.corners.center,n.targetWrapper.corners.center,!1):n.sourcePoint;return t}(n);var r=function lre(n,t,e,i,r){var b,M,s=n.sourceWrapper,o=n.targetWrapper,a=n.sourcePortWrapper,l=n.targetPortWrapper,d=[],p=Xa(n),y={corners:undefined,point:t,direction:undefined,margin:{left:5,right:5,bottom:5,top:5}},S={corners:undefined,point:e,direction:undefined,margin:{left:5,right:5,bottom:5,top:5}};if(void 0!==s&&void 0!==o&&(b=xn(s),M=xn(o),y.corners=s.corners,S.corners=o.corners),void 0!==a&&(y.direction="Left"===a.connectionDirection||"Top"===a.connectionDirection||"Bottom"===a.connectionDirection||"Right"===a.connectionDirection?a.connectionDirection:zo({x:a.offsetX,y:a.offsetY},b,s.bounds)),void 0!==l&&(S.direction="Left"===l.connectionDirection||"Right"===l.connectionDirection||"Bottom"===l.connectionDirection||"Top"===l.connectionDirection?l.connectionDirection:zo({x:l.offsetX,y:l.offsetY},M,o.bounds)),"Bezier"===n.type&&!n.isBezierEditing&&n.segments.length>0)for(var D=n.segments.length-1;D>=0;)n.segments[parseInt(D.toString(),10)].isInternalSegment&&n.segments.pop(),D--;if(void 0!==s&&void 0!==o)return(void 0===y.direction||void 0===S.direction)&&(i?function are(n,t,e){"LeftToRight"===e?(n.direction=n.direction?n.direction:"Right",t.direction=t.direction?t.direction:"Left"):"RightToLeft"===e?(n.direction=n.direction?n.direction:"Left",t.direction=t.direction?t.direction:"Right"):"TopToBottom"===e?(n.direction=n.direction?n.direction:"Bottom",t.direction=t.direction?t.direction:"Top"):"BottomToTop"===e&&(n.direction=n.direction?n.direction:"Top",t.direction=t.direction?t.direction:"Bottom")}(y,S,i):y.corners.top>S.corners.bottom&&Math.abs(y.corners.top-S.corners.bottom)>p?(y.direction=y.direction?y.direction:"Top",S.direction=S.direction?S.direction:"Bottom"):y.corners.bottomp?(y.direction=y.direction?y.direction:"Bottom",S.direction=S.direction?S.direction:"Top"):y.corners.rightp||y.corners.right+p=y.corners.left-p&&y.corners.left>S.corners.left?(y.direction=y.direction?y.direction:"Right",S.direction=S.direction?S.direction:"Left"):y.corners.left>S.corners.right&&Math.abs(y.corners.left-S.corners.right)>y.margin.left+y.margin.right||S.corners.right+p=S.corners.left-p&&y.corners.left0&&n.segments[0].direction&&(y.direction=n.segments[0].direction),y.point=Nl(b,y.direction),d=Nl(b,_n(y.direction)),y.point=qa(n,0,y.point,d,!1)):y.point=o.corners.center;if(void 0!==h){switch(S.point={x:h.offsetX,y:h.offsetY},S.direction){case"Bottom":case"Top":S.point.y=S.point.y;break;case"Left":case"Right":S.point.x=S.point.x}n.targetPadding&&!w&&(S.point=bI(n,y,S,!0))}else"Orthogonal"===n.type||"Bezier"===n.type?(S.point=Nl(M,S.direction),d=Nl(M,_n(S.direction)),S.point=qa(n,0,S.point,d,!0)):S.point=a.corners.center;if("Orthogonal"!==n.type){var C=void 0,D=void 0;if("Bezier"===n.type){if(n.bezierSettings.allowSegmentsReset||0===n.segments.length||!R.isEmptyPoint(n.segments[n.segments.length-1].point))return c=f3(n,y,S,void 0,s),xx(n,y,S);Rv(n)}else Rv(n);if(void 0===n.sourcePortWrapper){y.point=y.corners.center,n.segments&&n.segments.length>0&&(C=R.isEmptyPoint((D=n.segments[0]).point)?void 0:D);var A=void 0!==C?C.point:S.point;if("Bezier"===n.type&&n.segments.length>0&&n.segments[0].vector1.angle&&n.segments[0].vector1.distance){var x=Math.max(y.corners.width,y.corners.height);A=R.transform(y.point,n.segments[0].vector1.angle,x/2)}y.point=w?n.sourceWrapper.bounds.center:qa(n,0,y.point,A,!1)}if(void 0===n.targetPortWrapper){S.point=S.corners.center,n.segments&&n.segments.length>1&&(C=R.isEmptyPoint((D=n.segments[n.segments.length-2]).point)?void 0:D);var P=C?C.point:y.point;"Bezier"===n.type&&n.segments.length>0&&n.segments[n.segments.length-1].vector2.angle&&n.segments[n.segments.length-1].vector2.distance&&(x=Math.max(y.corners.width,y.corners.height),P=R.transform(S.point,n.segments[0].vector2.angle,x/2)),S.point=w?n.targetWrapper.bounds.center:qa(n,0,P,S.point,!0)}c=xx(n,y,S)}else"Orthogonal"===n.type&&n.segments&&n.segments.length>0&&null!==n.segments[0].direction?c=function yre(n,t,e,i,r,s,o){var a,h,c,d;Rv(n);for(var u=0;u0&&n.segments[u-1].direction===h.direction?u=c3(n,u,t):h.direction?t.point=n3(t,n.segments[parseInt(u.toString(),10)]):(f=n.segments[u-1])&&f.points&&f.points.length>0&&(t.point=f.points[f.points.length-1]),u===n.segments.length-1)if(d3(n,t),l3(a=void 0===r?mre(n,t,e):o3(n,t,e),n),h.points=[],a.length>=2)for(c=0;c2&&n.segments.length>2){var p={x:a[parseInt(c.toString(),10)].x,y:t.point.y};h.points=[],h.points.push(p),h.points.push(a[parseInt(c.toString(),10)]);var f=n.segments[u-1];n.segments.length<4&&f.points.pop(),f.points=f.points.concat(h.points)}else h.points.push(a[parseInt(c.toString(),10)]);else h.points.push(a[parseInt(c.toString(),10)]);else d=u;if(void 0!==d&&!n.selectedSegmentIndex&&(d===n.segments.length-1&&(n.segments[d-1].direction=null,n.segments[d-1].length=null),n.segments.splice(d,1)),i&&0===u){var g=a3(n,i,s);g&&(t.point=g)}}return u3(n,[])}(n,y,S,l,h,o):(n.segments[0]||(C=new wi(n,"segments",{type:"Orthogonal"},!0),n.segments.push(C)),n.segments[0].points=c=f3(n,y,S,void 0,s));return c}(n,y.direction,S.direction,y.point,S.point,r);if(Rv(n),(n.sourceWrapper||n.targetWrapper)&&function fre(n,t,e){var i=n.sourcePortWrapper,r=n.targetPortWrapper,s=n.sourceWrapper,o=t.point,a={left:0,right:0,top:0,bottom:0},l={x:0,y:0},c="Top";if(s?(o=e.point,a=t.margin):(s=n.targetWrapper,a=e.margin),"Orthogonal"===n.type)if(n.segments&&n.segments.length>0&&n.sourceWrapper&&n.segments[0].direction)t.direction=n.segments[0].direction,l=qa(n,0,l=Nl(s.corners,t.direction),Nl(s.corners,_n(t.direction)),!1);else{var u={corners:null,direction:null,point:null,margin:null};Hv(s,{corners:null,direction:null,point:o,margin:a},u,n),l=u.point,c=u.direction}else{var f=void 0;n.segments&&n.segments.length>1&&(f=s===n.sourceWrapper?n.segments[0].point:n.segments[n.segments.length-2].point),l=qa(n,0,s.bounds.center,n.segments&&n.segments.length>1?f:o,s===n.targetWrapper)}s===n.sourceWrapper?(t.direction=t.direction||c,t.point=l,n.sourcePortWrapper&&(t.point={x:i.offsetX,y:i.offsetY},n.sourcePadding&&(t.point=bI(n,t,e,!1)))):(e.direction=e.direction||c,e.point=l,n.targetPortWrapper&&(e.point={x:r.offsetX,y:r.offsetY},n.targetPadding&&(e.point=bI(n,t,e,!0))))}(n,y,S),"Straight"===n.type||"Bezier"===n.type)d=xx(n,y,S);else if("Orthogonal"===n.type&&n.segments&&n.segments.length>0&&null!==n.segments[0].length&&null!==n.segments[0].direction)d=function ure(n,t,e,i,r,s,o){var a,l,c,u,h=[];if(Rv(n),n.segments.length>0){for(var f=0;f0&&n.segments[f-1].direction===p.direction)f=c3(n,f,t);else{var g=n.segments[f-1];t.point=p.direction?n3(t,p):g.points[g.points.length-1]}if(f===n.segments.length-1&&(o||r?n.targetWrapper&&void 0===n.targetPortWrapper?(d3(n,t),l=cre(n,t,e)):l=o3(n,t,e):l=hre(n,t,e),l))if(l3(l,n),p.points=[],l.length>=2)for(a=0;at.corners.top&&e.point.ye.point.x?"Left":"Right"):e.point.x>t.corners.left&&e.point.xe.point.y?"Top":"Bottom")),n.sourcePortWrapper&&s===_n(r)?(("Left"===s||"Right"===s)&&t.point.y>=t.corners.top&&t.point.y<=t.corners.center.y&&e.point.y>=t.corners.top&&e.point.y<=t.corners.center.y?(t.direction="Top",a=t.point.y-t.corners.top+20):("Left"===s||"Right"===s)&&t.point.y>t.corners.center.y&&t.point.y<=t.corners.bottom&&e.point.y>t.corners.center.y&&e.point.y<=t.corners.bottom?(t.direction="Bottom",a=t.corners.bottom-t.point.y+20):("Top"===s||"Bottom"===s)&&t.point.x>=t.corners.left&&t.point.x<=t.corners.center.x&&e.point.x>=t.corners.left&&e.point.x<=t.corners.center.x?(t.direction="Left",a=t.point.x-t.corners.left+20):("Top"===s||"Bottom"===s)&&t.point.x<=t.corners.right&&t.point.x>t.corners.center.x&&e.point.x<=t.corners.right&&e.point.xt.point.y&&t.point.y>=e.corners.top?(i="Top",r=t.point.y-e.corners.top+20):e.corners.center.y===t.point.y&&"Top"===n.segments[n.segments.length-2].direction||e.corners.center.ye.point.y?t.point.y-t.corners.top+20:t.corners.bottom-t.point.y+20):(i="Top",r=e.corners.height/2+20):e.corners.center.x!==t.point.x||e.corners.topt.point.x&&t.point.x>=e.corners.left?(i="Left",r=t.point.x-e.corners.left+20):e.corners.center.x===t.point.x&&"Left"===n.segments[n.segments.length-2].direction||e.corners.center.x<=t.point.x&&t.point.x<=e.corners.right?(i="Right",r=e.corners.right-t.point.x+20):void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&t.corners.left<=t.point.x&&t.point.x<=t.corners.right&&(i=t.direction,r=t.point.x>e.point.x?t.point.x-t.corners.left+20:t.corners.right-t.point.x+20):(i="Left",r=e.corners.width/2+20);var a=t.point;t.point=Fn(t.point,"Left"===i||"Top"===i?-r:r,"Left"===i||"Right"===i?0:90),t.direction=R.direction(t.point,e.point),void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&(t.corners.center.x===e.corners.center.x||t.corners.center.y===e.corners.center.y)&&(t.direction=e.direction);var l=Ys(n,t,e);return l.splice(0,0,a),l}function o3(n,t,e){var i,r;e.corners=n.targetWrapper.corners,void 0!==n.sourcePortWrapper&&(r=zo({x:n.sourcePortWrapper.offsetX,y:n.sourcePortWrapper.offsetY},xn(n.sourceWrapper),n.sourceWrapper.bounds));var a=function dre(n,t,e,i){var r=!1;switch(e.direction){case"Left":void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&"Right"===i&&t.point.x>e.point.x&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom||("Bottom"===i&&t.point.y>e.point.y||"Top"===i&&t.point.y=t.corners.left&&t.point.x<=t.corners.right?(t.direction="Right"===i?t.point.y>e.point.y?"Top":"Bottom":t.point.xe.point.x&&(t.point.y>e.point.y||t.point.yt.point.y&&e.corners.bottome.point.y||t.point.x>e.point.x&&t.point.y<=e.point.y&&e.corners.top=t.point.y?t.direction="Top":t.point.xe.point.x&&t.point.y>e.point.y&&e.corners.bottomt.point.y?t.direction="Bottom":t.point.y===e.point.y&&t.point.xe.point.y||"Top"===i&&t.point.ye.point.x&&t.point.x>=t.corners.left&&t.point.x<=t.corners.right?(t.direction=t.point.x>e.point.x?"Left":"Right",r=!0):void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&"Left"===i&&t.point.x=t.corners.top&&t.point.y<=t.corners.bottom?(t.direction=t.point.y>e.point.y?"Top":"Bottom",r=!0):t.point.x=t.point.y&&t.point.y===e.point.y||t.point.y>e.point.y&&t.point.x>e.point.x?t.direction="Top":t.point.ye.point.x?t.direction="Bottom":t.point.xe.point.y||t.point.ye.point.x&&(t.direction="Left");break;case"Top":void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&"Bottom"===i&&t.point.y>e.point.y&&t.point.x>=t.corners.left&&t.point.x<=t.corners.right||("Right"===i&&t.point.x>e.point.x||"Left"===i&&e.point.y>t.point.y&&e.point.x>t.point.x)&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom?(t.direction="Bottom"===i?t.point.x>e.point.x?"Left":"Right":t.point.ye.point.y&&t.point.x>e.corners.left&&t.point.x=e.point.y?t.direction="Top":t.point.ye.point.x?t.direction="Left":t.point.yt.point.x)&&t.point.y>e.point.y&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom||"Top"===i&&t.point.y=t.corners.left&&t.point.x<=t.corners.right)?(t.direction="Right"===i||"Left"===i?t.point.y>e.point.y?"Top":"Bottom":t.point.x>e.point.x?"Left":"Right",r=!0):t.point.ye.corners.left&&e.corners.right>t.point.x?t.point.ye.corners.left&&e.corners.center.x>=t.point.x?t.direction="Left":t.point.ye.point.y&&t.point.x>e.point.x?t.direction="Left":t.point.y>e.point.y&&t.point.xe.point.x||e.point.x>t.point.x)&&(t.direction="Bottom")}return r}(n,t,e,r);return!n.selectedSegmentIndex&&void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&e.direction===_n(r)&&(("Left"===e.direction&&t.point.x>e.point.x||"Right"===e.direction&&t.point.x=t.corners.top&&t.point.y<=t.corners.bottom||"Bottom"===e.direction&&t.point.y=t.corners.left&&t.point.x<=t.corners.right)?i=s3(n,t,e):n.selectedSegmentIndex||t.direction!==e.direction?!n.selectedSegmentIndex&&("Left"===e.direction&&t.point.x>e.point.x||"Right"===e.direction&&t.point.x=t.point.y||"Top"===e.direction&&t.point.y>e.point.y||"Bottom"===e.direction&&t.point.y=t.point.x?i=n.selectedSegmentIndex?Ol(t,e):s3(n,t,e):!n.selectedSegmentIndex&&void 0!==n.sourceWrapper&&void 0!==n.targetWrapper&&void 0!==n.targetPortWrapper&&("Left"===t.direction||"Right"===t.direction)&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom&&("Top"===e.direction||"Bottom"===e.direction)&&e.corners.center.x===t.corners.center.x?(t.direction="Top"===e.direction?"Bottom":"Top",i=Ys(n,t,e,"Top"===e.direction?t.corners.bottom-t.point.y+20:t.point.y-t.corners.top+20)):!n.selectedSegmentIndex&&void 0!==n.sourceWrapper&&void 0!==n.targetWrapper&&void 0!==n.targetPortWrapper&&("Top"===t.direction||"Bottom"===t.direction)&&t.point.x>=t.corners.left&&t.point.x<=t.corners.right&&("Left"===e.direction||"Right"===e.direction)&&e.corners.center.y===t.corners.center.y?(t.direction="Left"===e.direction?"Right":"Left",i=Ys(n,t,e,"Left"===e.direction?t.corners.right-t.point.x+20:t.point.x-t.corners.left+20)):i=a?Ys(n,t,e,"Left"===t.direction||"Right"===t.direction?"Left"===t.direction?t.point.x-t.corners.left+20:t.corners.right-t.point.x+20:"Top"===t.direction?t.point.y-t.corners.top+20:t.corners.bottom-t.point.y+20):Ol(t,e):i=Ys(n,t,e),i}function a3(n,t,e){var r,i={x:t.offsetX,y:t.offsetY},s=xn(e),o=zo(i,s,e.bounds),a=n.segments[0];return a.direction!==o&&(function Sre(n,t,e,i,r,s){var a,h,o=13,l=[];l.push(i),i.y===r.y&&("Left"===t&&r.xi.x)||i.x===r.x&&("Top"===t&&r.yi.y)||("Top"===t||"Bottom"===t?"Top"===t&&r.yi.y-o||"Bottom"===t&&r.y>i.y&&r.yo&&("Top"===t&&r.yi.y)?l.push({x:i.x,y:r.y}):(a=r.xi.x-o||"right"===t&&r.x>i.x&&r.xo&&("Left"===t&&r.xi.x)?l.push({x:r.x,y:i.y}):(l.push({x:a="Left"===t?e.left-o:e.right+o,y:i.y}),l.push({x:a,y:r.y})),s&&(l.push(n.points[0]),l.reverse()),n.points=l)}(a,o,s,a.points[0],a.points[a.points.length-1],!1),r=a.points[a.points.length-1],a.direction=R.direction(a.points[a.points.length-2],a.points[a.points.length-1])),r}function l3(n,t,e){var s,i=t.segments[t.segments.length-2],r=i.points[i.points.length-1];(("Top"===i.direction||"Bottom"===i.direction)&&r.x===n[1].x||("Left"===i.direction||"Right"===i.direction)&&r.y===n[1].y)&&(i.points[i.points.length-1]=n[1],s=R.direction(i.points[0],i.points[i.points.length-1]),void 0!==t.sourceWrapper&&void 0===t.sourcePortWrapper&&s===_n(i.direction)&&("Left"===i.direction||"Right"===i.direction?i.points[0].x="Right"===i.direction?i.points[0].x-t.sourceWrapper.corners.width:i.points[0].x+t.sourceWrapper.corners.width:i.points[0].y="Bottom"===i.direction?i.points[0].y-t.sourceWrapper.corners.height:i.points[0].y+t.sourceWrapper.corners.height),i.direction=s,i.length=R.distancePoints(i.points[0],i.points[i.points.length-1]),n.splice(0,1))}function bI(n,t,e,i){var o=i?n.targetPadding:n.sourcePadding,a=i?n.targetPortWrapper:n.sourcePortWrapper,l=new Ne(a.bounds.x-o,a.bounds.y-o,a.actualSize.width+2*o,a.actualSize.height+2*o),h=[l.topLeft,l.topRight,l.bottomRight,l.bottomLeft];h[h.length]=h[0];var d=i?e.point:t.point;return Ax({x1:t.point.x,y1:t.point.y,x2:e.point.x,y2:e.point.y},h,0,d)||d}function h3(n,t){var e=[],i=hF(0,n.corners,t);i.push(i[0]);for(var r=0;r0){var r=void 0,s=[],o=t.point;for(r=0;r1&&R.equals(a.points[0],a.points[1])&&n.segments.splice(r,1),a)for(var l=0;l0||0===r)&&i.push(a.points[parseInt(l.toString(),10)])}}return i}function Tx(n,t,e){return"Top"===n||"Bottom"===n?e.x>t.x?"Right":"Left":e.y>t.y?"Bottom":"Top"}function Rv(n){if("Straight"===n.type||"Bezier"===n.type){if(0===n.segments.length||n.segments.length>0&&!R.isEmptyPoint(n.segments[n.segments.length-1].point))if("Bezier"===n.type){var t=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0},!0);n.segments.push(t)}else t=new Hl(n,"segments",{type:"Straight"},!0),n.segments.push(t)}else{if(n.segments.length>0)for(var e=!1,i=0;i=t.corners.left&&e.point.x<=t.corners.right&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom)t.direction=e.point.y>t.point.y?"Bottom":"Top",i=Ys(n,t,e,"Top"===t.direction?t.point.y-t.corners.top+20:t.corners.bottom-t.point.y+20);else if(n.sourcePortWrapper&&r===_n(o)){var h;("Left"===r||"Right"===r)&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom?(t.direction=e.point.y>t.point.y?"Bottom":"Top",h=t.corners.height/2+20):("Top"===r||"Bottom"===r)&&t.point.x>=t.corners.left&&t.point.x<=t.corners.right&&(t.direction=e.point.x>t.point.x?"Right":"Left",h=t.corners.width/2+20),t.direction&&h?i=Ys(n,t,e,h,!0):(t.direction=o,i=Ol(t,e))}else if(!n.sourcePortWrapper||r!==e.direction||"Top"!==r&&"Bottom"!==r||t.corners.center.x!==e.corners.center.x)if(t.direction===e.direction)if(("Left"===t.direction||"Right"===t.direction)&&e.point.y>t.corners.top-20&&e.point.yt.corners.left-20&&e.point.xt.point.y?"Bottom":"Top",i=Ys(n,t,e,"Bottom"===t.direction?t.corners.bottom-t.point.y+20:t.point.y-t.corners.top+20);else t.direction=o,i=Ys(n,t,e,"Top"===o||"Bottom"===o?n.sourceWrapper.height/2+20:n.sourceWrapper.width/2+20),t.point=i[1],"Left"===o||"Right"===o?(e.direction=o,e.point="Left"===o?e.corners.middleLeft:e.corners.middleRight):Hv(n.targetWrapper,t,e,n),i=Ys(n,t,e);return i}function d3(n,t){if(void 0!==n.targetWrapper&&void 0===n.targetPortWrapper&&xn(n.targetWrapper).containsPoint(t.point,1)){var i=n.targetWrapper,r=n.segments[n.segments.length-2],s=r.points[r.points.length-1],o=_n(r.direction);"Bottom"===o?s.yi.corners.top-1&&(r.points[r.points.length-1].y=i.corners.top-20,r.length=R.distancePoints(r.points[0],r.points[r.points.length-1])):"Left"===o?s.x>i.corners.left-1&&(r.points[r.points.length-1].x=i.corners.left-20,r.length=R.distancePoints(r.points[0],r.points[r.points.length-1])):"Right"===o&&s.x0||0===e)&&t.push(i.points[parseInt(r.toString(),10)]);return t}function Hv(n,t,e,i){var r,s={x:0,y:0},o=MI(n,n.corners,n.bounds),a=t.margin,l=t.point;if(o.bottomCenter.y+a.bottoml.y)r="Top",s=o.topCenter;else if(o.middleLeft.x-a.left>l.x)r="Left",s=o.middleLeft;else if(o.middleRight.x+a.rightc&&(f=c,r="Right",s=o.middleRight),f>d&&(f=d,r="Bottom",s=o.bottomCenter),f>u&&(r="Left",s=o.middleLeft)}e.point=s,e.direction=r;var p=Nl(o,_n(e.direction));e.point=qa(i,0,e.point,p,n===i.targetWrapper)}function f3(n,t,e,i,r){var s,o,a;if(s=function kre(n,t){var e=!1;switch(n){case"Left":switch(t){case"Right":case"Bottom":e=!0}break;case"Top":switch(t){case"Left":case"Right":case"Bottom":e=!0}break;case"Bottom":"Right"===t&&(e=!0)}return e}(t.direction,e.direction),s&&S3(t,e),"Right"===t.direction&&"Left"===e.direction)a=function Ire(n,t,e,i){var o=Math.round(Math.abs(t.point.y-e.point.y)),a={x:Math.max(t.point.x,t.corners.right),y:t.point.y},l={x:Math.min(e.point.x,e.corners.left),y:e.point.y},h=Xa(n);if(i){var c=l;l=a,a=c}return t.corners.bottom+he.corners.bottom+h||("Bezier"!==n.type||e.corners.left-t.corners.right<=2*h&&e.corners.left-t.corners.right>=5)&&(h=0),t.margin={left:h,right:h,top:h,bottom:h},e.margin={left:h,right:h,top:h,bottom:h},0===o&&(t.corners.right=e.corners.right?void 0!==i&&(i.offsetYe.corners.bottom+e.margin.bottom)||void 0===i&&t.corners.middleRight.ye.corners.bottom+e.margin.bottom&&t.corners.top>e.corners.bottom||void 0===i&&t.corners.middleRight.y>e.corners.bottom||void 0!==i&&i.offsetYe.corners.top||void 0===i&&t.corners.middleRight.y>e.corners.bottom?Ae.Three:t.corners.rightr.offsetY+e.margin.right||void 0===r&&t.corners.top>e.corners.middleRight.y||void 0!==r&&(void 0!==i&&i.offsetXr.offsetX||void 0===r&&t.corners.left>e.corners.topCenter.x?Ae.Four:Ae.Two:void 0!==s&&Math.abs(t.corners.right-e.corners.left)<=5&&Math.abs(s.offsetY-e.corners.top)<=5||void 0!==r&&t.corners.right=25&&t.corners.middleRight.y+t.margin.righte.corners.bottom+e.margin.bottom||void 0===o&&t.corners.middleRight.y>e.corners.bottom+e.margin.bottom?t.corners.top>e.corners.bottom?void 0!==a&&t.corners.right+t.margin.righta.offsetX||void 0===a&&t.corners.left>e.corners.bottomCenter.x?Ae.Four:Ae.Two:void 0!==o&&Math.abs(t.corners.right-e.corners.left)<=25&&Math.abs(o.offsetY-e.corners.bottom)<=25?Ae.Two:Ae.Four}(n,t,e,s);else if("Bottom"===t.direction&&"Top"===e.direction)a=function Cre(n,t,e){var r=t.point.x-e.point.x,s=Xa(n);return t.corners.right+se.corners.right+s||("Bezier"!==n.type||e.corners.top-t.corners.bottom<=2*s&&e.corners.top-t.corners.bottom>=5)&&(s=0),t.margin={left:s,right:s,top:s,bottom:s},e.margin={left:s,right:s,top:s,bottom:s},0===r&&t.corners.bottome.corners.right+e.margin.right||void 0===i&&t.corners.bottomCenter.x>e.corners.right+e.margin.right?Ae.Three:t.corners.bottomr.offsetX||void 0===r&&t.corners.left>e.corners.left||void 0!==r&&t.corners.right+t.margin.righte.corners.bottom?Ae.Five:0===s||0===o?Ae.One:Ae.Three}(n,t,e)}else"Bottom"===t.direction&&"Left"===e.direction?a=function Ere(n,t,e,i){var r=n.sourcePortWrapper,s=n.targetPortWrapper,o=Xa(n);if(e.margin={left:o,right:o,top:o,bottom:o},t.margin={top:o,bottom:o,left:o,right:o},i){var l=r;r=s,s=l}return void 0!==r&&r.offsetXs.offsetY||void 0===s&&t.corners.top>e.corners.middleLeft.y?Ae.Four:Ae.Two:void 0!==s&&Math.abs(t.corners.right-e.corners.left)<=25&&Math.abs(s.offsetY-t.corners.bottom)<=25?Ae.Two:Ae.Four}(n,t,e,s):"Left"===t.direction&&"Left"===e.direction?a=function Tre(n,t,e){var i=n.sourcePortWrapper,r=n.targetPortWrapper,s=Xa(n);t.margin={left:s,right:s,top:s,bottom:s},e.margin={left:s,right:s,top:s,bottom:s};var o=Math.round(Math.abs(t.point.x-e.point.x)),a=Math.round(Math.abs(t.point.y-e.point.y));return t.corners.leftr.offsetY||void 0===r&&t.corners.top-t.margin.top>e.corners.middleLeft.y?Ae.Three:t.corners.righte.corners.bottom+e.margin.bottom||void 0===i&&t.corners.middleLeft.y>e.corners.bottom+e.margin.bottom?Ae.Three:t.corners.left>e.corners.right?Ae.Five:0===o||0===a?Ae.One:Ae.Three}(n,t,e):"Left"===t.direction&&"Top"===e.direction?a=function xre(n,t,e,i){var s=n.sourcePortWrapper,o=Xa(n);e.margin={left:o,right:o,top:o,bottom:o},t.margin={top:o,bottom:o,left:o,right:o};var a=n.targetPortWrapper,l={x:Math.min(t.point.x,t.corners.left),y:t.point.y},h={x:e.point.x,y:Math.min(e.point.y,e.corners.top)};if(i){var c=s;s=a,a=c;var d=l;l=h,h=d}return void 0!==s&&s.offsetYa.offsetX||void 0===a&&t.corners.left-t.margin.left>e.corners.topCenter.x?Ae.Two:Ae.Four:void 0!==a&&t.corners.rightr.offsetX||void 0===r&&t.corners.left>e.corners.left||void 0!==r&&t.corners.right+t.margin.righte.corners.right+e.margin.right||void 0===i&&t.corners.left>e.corners.right||void 0!==i&&i.offsetXe.corners.bottom?Ae.Five:0===s||0===o?Ae.One:Ae.Three}(n,t,e));return s&&S3(t,e),o=function Lre(n,t,e,i,r,s){var l,d,h=n.sourceWrapper.corners,c=n.targetWrapper.corners,u=20,f={corners:e.corners,point:e.point,direction:e.direction,margin:e.margin},p={corners:i.corners,point:i.point,direction:i.direction,margin:i.margin};if(!(f.direction===p.direction&&t!==Ae.Five||f.direction!==_n(p.direction)&&t!==Ae.Three))switch(f.direction){case"Left":h.middleLeft.x>c.middleRight.x&&(d=(h.middleLeft.x-c.middleRight.x)/2,u=s?d:Math.min(u,d));break;case"Right":h.middleRight.xc.bottomCenter.y&&(d=(h.topCenter.y-c.bottomCenter.y)/2,u=s?d:Math.min(u,d));break;case"Bottom":h.bottomCenter.yf&&hf)&&o>c&&o<=d&&e>=20&&(s=n.point.x-t.corners.left+s),i&&n.direction===t.direction&&n.corners.left>t.corners.left&&n.corners.left-t.corners.right>=20&&(s=(n.corners.left-t.corners.right)/2),p=Fn(n.point,s,180);break;case"Top":(o>c&&oc)&&h>f&&h<=u&&e>=20&&(s=n.point.y-t.corners.top+s),i&&n.direction===t.direction&&n.corners.top>t.corners.top&&n.corners.top-t.corners.bottom>=20&&(s=(n.corners.top-t.corners.bottom)/2),p=Fn(n.point,s,270);break;case"Right":(h>f&&hf)&&a=c&&e>=20&&(s=t.corners.right-n.point.x+s),i&&n.direction===t.direction&&n.corners.right=20&&(s=(t.corners.left-n.corners.right)/2),p=Fn(n.point,s,0);break;case"Bottom":(o>c&&oc)&&l=f&&e>=20&&(s=t.corners.bottom-n.point.y+s),i&&n.direction===t.direction&&n.corners.bottom=20&&(s=(t.corners.top-n.corners.bottom)/2),p=Fn(n.point,s,90)}r=[n.point,p];var g=void 0;if("Top"===n.direction||"Bottom"===n.direction){var v=n.direction;n.direction=p.x>t.point.x?"Left":"Right",n.point=p,r=wI(n,t,v,r,g=i?.5*Math.abs(p.x-t.point.x):g,i)}else v=n.direction,n.direction=p.y>t.point.y?"Top":"Bottom",n.point=p,r=wI(n,t,v,r,g=i?.5*Math.abs(p.y-t.point.y):g,i);return r}(f,p,u,g)),l}(n,a,t,e,i,r),"Bezier"===n.type&&function Ore(n,t,e){if("Bezier"===n.type)if(0===n.segments.length){var i=e[0],r=e[e.length-1];if(t===Ae.One){var s=Math.min(20,.5*R.findLength(i,r)),o={angle:Gt(i,r),distance:s},a={angle:Gt(r,i),distance:s},l=R.direction(i,r),c=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,orientation:"Left"===l||"Right"===l?"Horizontal":"Vertical"},!0);n.segments.push(c)}else if(t===Ae.Two)o={angle:Gt(i,d=e[1]),distance:.5*R.findLength(i,d)},a={angle:Gt(r,d),distance:.5*R.findLength(r,d)},l=R.direction(i,d),c=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,orientation:"Left"===l||"Right"===l?"Horizontal":"Vertical"},!0),n.segments.push(c);else if(t===Ae.Three){var d={x:.5*((u=e[1]).x+(f=e[e.length-2]).x),y:.5*(u.y+f.y)},p=(o={angle:Gt(i,u),distance:.5*R.findLength(i,u)},a={angle:Gt(d,u),distance:.5*R.findLength(d,u)},R.direction(i,u)),v=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,point:d,orientation:"Left"===p||"Right"===p?"Horizontal":"Vertical"},!0);n.segments.push(v);var y={angle:Gt(d,f),distance:.5*R.findLength(d,f)},S={angle:Gt(r,f),distance:.5*R.findLength(r,f)},b=R.direction(d,f),w=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:y,vector2:S,orientation:"Left"===b||"Right"===b?"Horizontal":"Vertical"},!0);n.segments.push(w)}else if(t===Ae.Four){var D={x:.5*((u=e[1]).x+(f=e[2]).x),y:.5*(u.y+f.y)},A={x:.5*(f.x+(C=e[3]).x),y:.5*(f.y+C.y)};o={angle:Gt(i,u),distance:.5*R.findLength(i,u)},a={angle:Gt(D,u),distance:.5*R.findLength(D,u)},p=R.direction(i,u),v=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,point:D,orientation:"Left"===p||"Right"===p?"Horizontal":"Vertical"},!0),n.segments.push(v),y={angle:Gt(D,f),distance:.5*R.findLength(D,f)},S={angle:Gt(A,f),distance:.5*R.findLength(A,f)},b=R.direction(D,f),w=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:y,vector2:S,point:A,orientation:"Left"===b||"Right"===b?"Horizontal":"Vertical"},!0),n.segments.push(w);var x={angle:Gt(A,C),distance:.5*R.findLength(A,C)},P={angle:Gt(r,C),distance:.5*R.findLength(r,C)},L=R.direction(A,C),N=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:x,vector2:P,orientation:"Left"===L||"Right"===L?"Horizontal":"Vertical"},!0);n.segments.push(N)}else if(t===Ae.Five){var u,f,C,T=e[4],z=(D={x:.5*((u=e[1]).x+(f=e[2]).x),y:.5*(u.y+f.y)},A={x:.5*(f.x+(C=e[3]).x),y:.5*(f.y+C.y)},{x:.5*(C.x+T.x),y:.5*(C.y+T.y)});o={angle:Gt(i,u),distance:.5*R.findLength(i,u)},a={angle:Gt(D,u),distance:.5*R.findLength(D,u)},p=R.direction(i,u),v=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,point:D,orientation:"Left"===p||"Right"===p?"Horizontal":"Vertical"},!0),n.segments.push(v),y={angle:Gt(D,f),distance:.5*R.findLength(D,f)},S={angle:Gt(A,f),distance:.5*R.findLength(A,f)},b=R.direction(D,f),w=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:y,vector2:S,point:A,orientation:"Left"===b||"Right"===b?"Horizontal":"Vertical"},!0),n.segments.push(w),x={angle:Gt(A,C),distance:.5*R.findLength(A,C)},P={angle:Gt(z,C),distance:.5*R.findLength(z,C)},L=R.direction(A,C),N=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:x,vector2:P,point:z,orientation:"Left"===L||"Right"===L?"Horizontal":"Vertical"},!0),n.segments.push(N);var U={angle:Gt(z,T),distance:.5*R.findLength(z,T)},B={angle:Gt(r,T),distance:.5*R.findLength(r,T)},j=R.direction(z,T),oe=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:U,vector2:B,orientation:"Left"===j||"Right"===j?"Horizontal":"Vertical"},!0);n.segments.push(oe)}else c=new fs(n,"segments",{type:"Bezier"},!0),n.segments.push(c)}else for(var ue=0;ue=13?13:n.connectorSpacing<=1?1:n.connectorSpacing}function Gt(n,t){var i=R.findLength({x:t.x,y:n.y},t),r=R.findLength(t,n),s=Math.asin(i/r);return s=180*s/Math.PI,n.xt.y&&(s=360-s):s=n.y0)for(var l=1;lc)&&(s=c,a=h),s>=0&&s<=1)break}}return a}function g3(n,t){var c,d,u,f,p,g,S,b,M,w,D,e=n.x1,i=n.y1,r=n.x2,s=n.y2,o=t.x1,a=t.y1,l=t.x2,h=t.y2;if(w=(c=s-i)*l+(u=e-r)*h+(p=r*i-e*s),0!==(M=c*o+u*a+p)&&0!==w&&v3(M,w)||(b=(d=h-a)*r+(f=o-l)*s+(g=l*a-o*h),0!==(S=d*e+f*i+g)&&0!==b&&v3(S,b)))return null;var A=c*f-d*u;return 0===A?null:(A<0?-A/2:A/2,0,{x:(D=u*g-f*p)<0?(D-0)/A:(D+0)/A,y:(D=d*p-c*g)<0?(D-0)/A:(D+0)/A})}function v3(n,t){return n*t>=0}function m3(n,t,e){switch(t.direction){case"Left":t.point.x>n.left&&(e=t.point.x-n.left>e?t.point.x-n.left+e:e);break;case"Right":t.point.xe?n.right-t.point.x+e:e);break;case"Top":t.point.y>n.top&&(e=t.point.y-n.top>e?t.point.y-n.top+e:e);break;case"Bottom":t.point.ye?n.bottom-t.point.y+e:e)}return e}function Ol(n,t){var e;switch(n.direction){case"Left":case"Right":var i={x:t.point.x,y:n.point.y};e=R.equals(n.point,i)||R.equals(t.point,i)?[n.point,t.point]:[n.point,i,t.point];break;case"Top":case"Bottom":var r={x:n.point.x,y:t.point.y};e=R.equals(n.point,r)||R.equals(t.point,r)?[n.point,t.point]:[n.point,r,t.point]}return e}function Ys(n,t,e,i,r,s){void 0===s&&(s=!1),i||(i=20),s&&t.direction!==e.direction&&(i="Left"===t.direction||"Right"===t.direction?Math.floor(.5*Math.abs(t.point.x-e.point.x)):Math.floor(.5*Math.abs(t.point.y-e.point.y)));var l,h,u,o=n.sourcePortWrapper,c=e.point.x-t.point.x,d=e.point.y-t.point.y;if(!r&&(Math.abs(c)<.001||Math.abs(d)<.001)&&void 0===e.direction)return[t.point,e.point];if(void 0===n.targetWrapper&&Math.abs(c)<=31&&Math.abs(d)<=31){if("Left"===t.direction||"Right"===t.direction?Math.abs(d)<12&&(t.direction=t.point.y>e.point.y?"Top":"Bottom"):Math.abs(c)<12&&(t.direction=t.point.x>e.point.x?"Left":"Right"),Math.abs(c)>12||Math.abs(d)>12)return Ol(t,e);i+=5}return"Left"===t.direction||"Right"===t.direction?("Right"===t.direction?(void 0!==e.direction&&"Right"===e.direction&&(i=Math.max(t.point.x,e.point.x)-t.point.x+i),t.point.x>e.point.x&&void 0===o&&(i=-i)):(void 0!==e.direction&&"Left"===e.direction&&(i=t.point.x-Math.min(t.point.x,e.point.x)+i),(t.point.x>e.point.x||void 0!==o||"Left"===t.direction)&&(i=-i)),u=e.point.y-t.point.y,l=Fn(t.point,i,0),0!=(u=e.point.y-l.y)&&(h=Fn(l,e.point.y-l.y,90))):("Top"===t.direction||"Bottom"===t.direction)&&("Bottom"===t.direction?void 0!==e.direction&&"Bottom"===e.direction&&(i=Math.max(t.point.y,e.point.y)-t.point.y+i):(void 0!==e.direction&&"Top"===e.direction&&(i=t.point.y-Math.min(t.point.y,e.point.y)+i),(t.point.y>e.point.y||void 0!==o||"Top"===t.direction)&&(i=-i)),u=e.point.x-t.point.x,l=Fn(t.point,i,90),0!=(u=e.point.x-l.x)&&(h=Fn(l,e.point.x-l.x,0))),0===u?[t.point,e.point]:[t.point,l,h,e.point]}function wI(n,t,e,i,r,s){var o;switch(void 0===r&&(r=20),void 0===s&&(s=!1),void 0===e?(n.margin={left:2,right:2,top:2,bottom:2},t.margin={left:0,right:5,top:0,bottom:5},s&&(n.margin={left:10,right:10,top:10,bottom:10},t.margin={left:10,right:10,top:10,bottom:10},"Left"===n.direction?(r=Nx(n,t,e,r),n.corners.left-t.corners.right>=5&&(r=Math.abs(n.point.x-n.corners.left)+.5*Math.floor(n.corners.left-t.corners.right))):"Right"===n.direction?(r=Ox(n,t,r,e),t.corners.left-n.corners.right>=5&&(r=Math.abs(n.point.x-n.corners.right)+.5*Math.floor(t.corners.left-n.corners.right))):"Top"===n.direction?(r=Lx(n,t,e,r),n.corners.top-t.corners.bottom>=5&&(r=Math.abs(n.point.y-n.corners.top)+.5*Math.floor(n.corners.top-t.corners.bottom))):"Bottom"===n.direction&&(r=kx(n,t,r,e),t.corners.top-n.corners.bottom>=5&&(r=Math.abs(n.point.y-n.corners.bottom)+.5*Math.floor(t.corners.top-n.corners.bottom))))):("Bottom"===n.direction?s?t.corners.top-n.corners.bottom<20&&(r=t.corners.bottom-n.point.y+25):t.corners.top>n.corners.bottom&&t.corners.top-n.corners.bottom<20&&(r=(t.corners.top-n.corners.bottom)/2):"Top"===n.direction?s?n.corners.top-t.corners.bottom<20&&(r=n.point.y-t.corners.top+25):t.corners.bottomn.corners.right&&t.corners.left-n.corners.right<20&&(r=(t.corners.left-n.corners.right)/2):"Left"===n.direction&&(s?n.corners.left-t.corners.right<20&&(r=n.point.x-t.corners.left+25):t.corners.rightt.point.y||"Top"===t.direction&&n.point.yt.point.x||"Left"===t.direction&&n.point.xh||e.corners.top-e.margin.top<=i.point.y&&e.corners.bottom+e.margin.bottom>=i.point.y))if(!s||"Top"!==e.direction&&"Bottom"!==e.direction)c=Math.min(Math.abs(i.corners.left-e.corners.right)/2,20),h=e.corners.right-n.x+c;else{var c=Math.abs(i.corners.left-e.corners.right)/2;h=e.corners.right-n.x+c}else h="Top"===e.direction&&n.y>i.point.y||"Bottom"===e.direction&&n.y=e.corners.left-e.margin.left&&n.x<=e.corners.right+e.margin.right?Math.min(i.corners.left,e.corners.left)-n.x-20:i.corners.left-n.x-20;break;case"Right":if(e.corners.left-e.margin.left>i.corners.right+i.margin.right&&(e.corners.left-e.margin.right-i.corners.right>h||e.corners.top-e.margin.top<=i.point.y&&e.corners.bottom+e.margin.bottom>=i.point.y))if(!s||"Top"!==e.direction&&"Bottom"!==e.direction)c=Math.min(Math.abs(e.corners.left-i.corners.right)/2,20),h=e.corners.left-n.x-c;else{c=Math.abs(e.corners.left-i.corners.right)/2;h=e.corners.left-n.x-c}else h="Top"===e.direction&&n.y>i.point.y||"Bottom"===e.direction&&n.y=e.corners.left-e.margin.left&&n.x<=e.corners.right+e.margin.right?Math.max(i.corners.right,e.corners.right)-n.x+20:i.corners.right-n.x+20}o=Fn(n,h,0),a=Fn(o,i.point.y-n.y,90),l=i.point}else if("vertical"===t){switch(i.direction){case"Top":e.corners.bottom+e.margin.bottomh||e.corners.left-e.margin.left<=i.point.x&&e.corners.right+e.margin.right>=i.point.x)?!s||"Right"!==e.direction&&"Left"!==e.direction?(c=Math.min(Math.abs(i.corners.top-e.corners.bottom)/2,20),h=e.corners.bottom-n.y+c):(c=Math.abs(i.corners.top-e.corners.bottom)/2,h=e.corners.bottom-n.y+c):h="Left"===e.direction&&n.x>i.point.x||"Right"===e.direction&&n.x=e.corners.top-e.margin.top&&n.y<=e.corners.bottom+e.margin.bottom?Math.min(i.corners.top,e.corners.top)-n.y-20:i.corners.top-n.y-20;break;case"Bottom":e.corners.top-e.margin.top>i.corners.bottom+i.margin.bottom&&(e.corners.top-e.margin.top-i.corners.bottom>h||e.corners.left-e.margin.left<=i.point.x&&e.corners.right+e.margin.right>=i.point.x)?!s||"Right"!==e.direction&&"Left"!==e.direction?(c=Math.min(Math.abs(e.corners.top-i.corners.bottom)/2,20),h=e.corners.top-n.y-c):(c=Math.abs(e.corners.top-i.corners.bottom)/2,h=e.corners.top-n.y-c):h="Left"===e.direction&&n.x>i.point.x||"Right"===e.direction&&n.x=e.corners.top-e.margin.top&&n.y<=e.corners.bottom+e.margin.bottom?Math.max(i.corners.bottom,e.corners.bottom)-n.y+20:i.corners.bottom-n.y+20}o=Fn(n,h,90),a=Fn(o,i.point.x-n.x,0),l=i.point}r.push(o),r.push(a),r.push(l)}function Lx(n,t,e,i){return n.corners.top-n.margin.top>t.corners.top+t.margin.top&&n.corners.top-n.margin.top<=t.corners.bottom+t.margin.bottom?(("Right"===t.direction&&n.point.xt.point.x)&&(i+=n.corners.top-t.corners.top),i+=n.point.y-n.corners.top):i+=void 0!==e&&"Left"!==e&&"Right"===t.direction&&n.point.xt.corners.left-t.margin.left&&n.corners.left-n.margin.left<=t.corners.right+t.margin.right?(("Bottom"===t.direction&&n.point.yt.point.y)&&(i+=n.corners.left-t.corners.left),i+=n.point.x-n.corners.left):i+=void 0!==e&&"Top"!==e&&"Bottom"===t.direction&&n.point.y=t.corners.left-t.margin.left?(("Bottom"===t.direction&&n.point.yt.point.y)&&(e+=t.corners.right-n.corners.right),e+=n.corners.right-n.point.x):e+=void 0!==i&&"Top"!==i&&"Bottom"===t.direction&&n.point.y=t.corners.top-t.margin.top?(("Right"===t.direction&&n.point.xt.point.x)&&(e+=t.corners.bottom-n.corners.bottom),e+=n.corners.bottom-n.point.y):e+=void 0!==i&&"Left"!==i&&"Right"===t.direction&&n.point.xp&&d=u&&d=f&&d<=p?"Left":"Right"}function _n(n){switch(n){case"Top":return"Bottom";case"Bottom":return"Top";case"Left":return"Right";case"Right":return"Left"}return"auto"}var b3=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Ac=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},CI=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return b3(t,n),Ac([I()],t.prototype,"width",void 0),Ac([I()],t.prototype,"height",void 0),t}(Ee),Pre=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return b3(t,n),Ac([I()],t.prototype,"width",void 0),Ac([I()],t.prototype,"height",void 0),Ac([I()],t.prototype,"fit",void 0),Ac([I()],t.prototype,"description",void 0),Ac([I()],t.prototype,"template",void 0),Ac([I()],t.prototype,"tooltip",void 0),t}(Ee),zre=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),kl=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},M3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return zre(t,n),kl([I("")],t.prototype,"id",void 0),kl([I(Number.MIN_VALUE)],t.prototype,"zIndex",void 0),kl([re({},Jn)],t.prototype,"margin",void 0),kl([I(!0)],t.prototype,"visible",void 0),kl([re({},Dd)],t.prototype,"tooltip",void 0),kl([I(!1)],t.prototype,"excludeFromLayout",void 0),kl([I()],t.prototype,"addInfo",void 0),kl([I("None")],t.prototype,"flip",void 0),kl([I("All")],t.prototype,"flipMode",void 0),kl([re({},Pre)],t.prototype,"symbolInfo",void 0),t}(Ee),Rre=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),es=function(n){function t(e,i,r,s){var o=n.call(this)||this;return o.data="",o.nodeId="",o.annotationId="",o.diagramId="",o.diagramId=i,o.nodeId=e,o.annotationId=r,o.templateFn=FF(s),o}return Rre(t,n),t.prototype.getNodeTemplate=function(){return this.templateFn},Object.defineProperty(t.prototype,"content",{get:function(){return this.data},set:function(e){this.data=e,this.canReset||(this.canReset=!0,this.isTemplate||(this.template=Hh(this,!0)),this.canReset=!1,this.isDirt=!0)},enumerable:!0,configurable:!0}),t}(hs),Px=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),cs=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},w3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Px(t,n),cs([I("")],t.prototype,"id",void 0),cs([I("transparent")],t.prototype,"fill",void 0),cs([I("black")],t.prototype,"iconStrokeColor",void 0),cs([I(0)],t.prototype,"iconStrokeWidth",void 0),cs([I(!0)],t.prototype,"visibility",void 0),cs([I(10)],t.prototype,"width",void 0),cs([I(10)],t.prototype,"height",void 0),cs([I("transparent")],t.prototype,"handleStrokeColor",void 0),cs([I(1)],t.prototype,"handleStrokeWidth",void 0),cs([I("")],t.prototype,"pathData",void 0),cs([I(0)],t.prototype,"cornerRadius",void 0),cs([re({left:0,right:0,top:0,bottom:0},Jn)],t.prototype,"padding",void 0),cs([re({},Dd)],t.prototype,"tooltip",void 0),t}(Ee),C3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Px(t,n),cs([re({x:0,y:0},R)],t.prototype,"offset",void 0),cs([re({},Jn)],t.prototype,"margin",void 0),t}(w3),EI=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Px(t,n),cs([I(.5)],t.prototype,"offset",void 0),cs([I("Center")],t.prototype,"alignment",void 0),cs([re({x:0,y:0},R)],t.prototype,"displacement",void 0),t}(w3);function xd(n){return n?n instanceof Kn||n instanceof Or?n.constraints&Nr.Select:n instanceof de?n.constraints&qe.Select:n.constraints&ie.Select:1}function ro(n){return n?n instanceof Kn||n instanceof Or?n.constraints&Nr.Drag:n instanceof de?n.constraints&qe.Drag:n instanceof ei?1:n.constraints&ie.Drag:1}function Hre(n,t){return n instanceof de?n.constraints&qe.PointerEvents:n.constraints&ie.PointerEvents}function DI(n){return n instanceof de?n.constraints&qe.Delete:n.constraints&ie.Delete}function xI(n){return n.constraints&qe.DragSourceEnd}function TI(n){return n.constraints&qe.DragTargetEnd}function AI(n){return n.constraints&qe.DragSegmentThumb}function LI(n){return n instanceof Kn||n instanceof Or?n.constraints&Nr.Rotate:n.constraints&ie.Rotate}function NI(n){return n.constraints&ie.Shadow}function ua(n){return n instanceof te&&n.constraints&ie.InConnect?n.constraints&ie.InConnect:0}function kh(n){return n&&n.constraints&&!(n.constraints&oi.None)&&n.constraints&oi.InConnect?n.constraints&oi.InConnect:0}function Ph(n){return n instanceof te&&n.constraints&ie.OutConnect?n.constraints&ie.OutConnect:0}function Td(n){return n&&n.constraints&&!(n.constraints&oi.None)&&n.constraints&oi.OutConnect?n.constraints&oi.OutConnect:0}function Pl(n,t){var e=0;return n instanceof Kn||n instanceof Or?e=n.constraints&Nr.Resize:n&&("SouthEast"===t?e=n.constraints&ie.ResizeSouthEast:"East"===t?e=n.constraints&ie.ResizeEast:"NorthEast"===t?e=n.constraints&ie.ResizeNorthEast:"South"===t?e=n.constraints&ie.ResizeSouth:"North"===t?e=n.constraints&ie.ResizeNorth:"SouthWest"===t?e=n.constraints&ie.ResizeSouthWest:"West"===t?e=n.constraints&ie.ResizeWest:"NorthWest"===t&&(e=n.constraints&ie.ResizeNorthWest)),e}function OI(n){return n instanceof de?n.constraints&qe.AllowDrop:n.constraints&ie.AllowDrop}function Ds(n){return n.constraints&nt.Virtualization}function Bv(n){return n.tool&ri.SingleSelect}function Fv(n){return n.tool&ri.MultipleSelect}function Lc(n){return n.tool&ri.ZoomPan}function kI(n){return n.tool&ri.ContinuousDraw}function E3(n){return n.tool&ri.DrawOnce}function PI(n){return n.tool&ri.SingleSelect||n.tool&ri.MultipleSelect}function _v(n){return n.constraints&nt.UserInteraction}function D3(n){return n.constraints&nt.ZoomTextEdit}function Uv(n){return function Vre(n){return n.constraints&nt.ApiUpdate}(n)||n.diagramActions&ee.ToolAction}function zx(n,t){return n.constraints&oi.Draw}function Rx(n,t){return n.constraints&oi.Drag}function zI(n){return!(n&Ga.DrawSelectorBorder)}function x3(n){return!!(n&Ga.PreventRenderSelector)}var Hx=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),jv=function(n){function t(){var e=null!==n&&n.apply(this,arguments)||this;return e.childTable=[],e.cellStyle={},e.desiredRowHeight=[],e.desiredCellWidth=[],e}return Hx(t,n),t.prototype.rowDefinitions=function(){return this.rowDefns},t.prototype.columnDefinitions=function(){return this.colDefns},t.prototype.addObject=function(e,i,r,s,o){if(this.rows.length>=i){var a=this.rows[parseInt(i.toString(),10)];if(a.cells.length>r){o=o||1,s=s||1;var l=a.cells[parseInt(r.toString(),10)];l.columnSpan=Math.max(o,l.columnSpan),l.rowSpan=Math.max(s,l.rowSpan);var h=new Xre;(h=e).rowId=i,h.columnId=r,h.columnSpan=o,this.childTable[h.id]=h,this.addObjectToCell(h,l)}}},t.prototype.addObjectToCell=function(e,i){i.children||(i.children=[]),e.style.strokeColor="black",e.style.strokeWidth=1,i.children.push(e)},t.prototype.updateProperties=function(e,i,r,s){this.offsetX=e,this.offsetY=i,this.width=r,this.height=s},t.prototype.setDefinitions=function(e,i){this.rowDefns=e,this.colDefns=i,this.children=[],this.rows=this.rows||[];for(var r=0;r0){for(var h=0;hi&&this.updateRowHeight(e,l,!1)}},t.prototype.setTextRefresh=function(e){if(e.children&&e.children.length)for(var i=e.children,r=0;ri&&this.updateColumnWidth(e,a,!1)}},t.prototype.calculateCellWidth=function(e){for(var i,r,s,o=0;os.bounds.width&&(0===s.children.length||void 0===s.children[0].maxWidth)?s.outerBounds.width:s.bounds.width,i=i?is.bounds.height?s.outerBounds.height:s.bounds.height,i=i?i0?e.children[0]:void 0;if(a&&1===e.columnSpan){o="Width"===i?a.bounds.right:a.bounds.bottom,s||(s="Width"===i?a.bounds.width:a.bounds.height);for(var l=0;lo){var d=c-o+("Width"===i?a.bounds.width:a.bounds.height);s&&(s=s0?this.rowDefns.splice(e,0,i):this.rowDefns.push(i);var s=new T3;s.cells=[],(new Ad).width=this.width,this.addCellInRow(this.colDefns,i,s),e>this.rows.length-1?this.rows.push(s):this.rows.splice(e,0,s),r&&(this.measure(new me(this.width,this.height)),this.arrange(this.desiredSize))},t.prototype.addColumn=function(e,i,r){var s,o,a,l,h=this.rows;this.colDefns.length>0?this.colDefns.splice(e,0,i):this.colDefns.push(i),void 0!==this.width&&(this.width+=i.width);for(var c=0;cs.cells.length-1?s.cells.push(l):s.cells.splice(e,0,l),this.children.push(l);r&&(this.measure(new me(this.width,this.height)),this.arrange(this.desiredSize))},t.prototype.removeRow=function(e){var i,r,o=this.rows[parseInt(e.toString(),10)];this.height-=this.rowDefns[parseInt(e.toString(),10)].height;for(var a=0;a0){var r=0,s=0;i=new me(0,0),this.calculateSize();for(var o=0,a=this.rows;o0){for(var o=this.offsetX-e.width*this.pivot.x,a=this.offsetY-e.height*this.pivot.y,l=o,h=0,c=this.rows;h1&&this.children.splice(this.children.indexOf(p)+1,p.columnSpan-1),p.rowSpan>1)for(y=s,S=0;y+p.rowSpan-10){for(var c=0;c0?1:0,v=0;v0||a.outEdges.length>0))for(f=a.inEdges.concat(a.outEdges),s=0;s0)for(o=0;o1)for(a=1;a0))if(h=n.wrapper.children[0],"Horizontal"===e.orientation)for(o=e.header&&e.hasHeader?h.rows[1]:h.rows[0],r=0;r0){var e=void 0;t.lineRoutingModule&&t.constraints&nt.LineRouting&&t.lineRoutingModule.renderVirtualRegion(t,!0);for(var i=0;i0?o+1:o)].height=t.wrapper.height;else if(t.isPhase)for(l[t.rowIndex-o].offset=t.wrapper.height,p=0;p0?1:0)].width=t.wrapper.width}function HI(n,t){var i=n.shape,r=i.header&&i.hasHeader?1:0;return"Horizontal"===i.orientation?t.rowIndex-(r+=i.phases.length>0?1:0):t.columnIndex-(i.phaseSize&&i.phases.length>0?1:0)}function BI(n){var t=0,e=n.shape;return"Horizontal"===e.orientation&&(t=e.header&&e.hasHeader?1:0),e.phases.length>0&&e.phaseSize&&(t+=1),t}function FI(n,t,e,i){var r=n.shape;if(r.phases.length>0){var s=t.nameTable[r.phases[parseInt(i.toString(),10)].header.id];s&&s.maxWidth0?u+1:u);var w=Nc(n,o),C=void 0!==i?i:l.lanes.length;if(u+=C,r={element:M,cause:n.diagramActions,diagramAction:n.getDiagramAction(n.diagramActions),state:"Changing",type:"Addition",cancel:!1,laneIndex:C},n.triggerEvent(Ce.collectionChange,r),!r.cancel){if(c){var D=new Vv;D.height=e.height,o.addRow(u,D,!1),s.height=void 0!==s.height?s.height+e.height:s.height,s.wrapper.height=o.height=s.height}else{var A=new Ad;A.width=e.width,o.addColumn(C+1,A,!1),s.width&&(s.width+=e.width,s.wrapper.width=o.width=s.width),n.diagramActions&ee.UndoRedo||(o.rows[0].cells[0].columnSpan+=1)}n.diagramActions&ee.UndoRedo||(M.id=""===M.id?Qe():M.id),void 0!==i?l.lanes.splice(i,0,M):l.lanes.push(M),r={element:M,cause:n.diagramActions,diagramAction:n.getDiagramAction(n.diagramActions),state:"Changed",type:"Addition",cancel:!1,laneIndex:C},n.triggerEvent(Ce.collectionChange,r),L3(o,n,s,u,C,c),h="Horizontal"===l.orientation?n.nameTable[o.rows[parseInt(u.toString(),10)].cells[0].children[0].id]:l.header&&l.hasHeader?n.nameTable[o.rows[1].cells[parseInt(u.toString(),10)].children[0].id]:n.nameTable[o.rows[0].cells[parseInt(u.toString(),10)].children[0].id],n.diagramActions&ee.UndoRedo||(d={type:"LaneCollectionChanged",changeType:"Insert",undoObject:$(M),redoObject:$(h),category:"Internal"},n.addHistoryEntry(d)),Xf(n,s,"Horizontal"===l.orientation?u:l.header&&l.hasHeader?1:0),Gf(s),Oc(n,s);var P=!1;if((f=e.children)&&f.length>0)for(p=0;p0){var o=t.children[0],a=n.nameTable[o.id];(function rne(n,t,e){return n.left-(e.left||0)<=t.x&&n.right+(e.right||0)>=t.x&&n.top-(e.top||0)<=t.y&&n.bottom+(e.bottom||0)>=t.y})(o.bounds,e,r)&&(n.addChild(a,i),s=!0)}return s}function nne(n,t,e){if("SwimLane"===t.shape.type){var i=void 0,r=void 0,s=void 0,a=void 0,l=void 0,h=void 0,c=t.wrapper.bounds.x,d=t.wrapper.bounds.y,u=t.shape,f=u.padding,p=u.phases,g=void 0,v=t.wrapper.children[0],y="Horizontal"===u.orientation;if(i=u.header&&u.hasHeader?0:-1,u.phases.length>0&&(i+=1),e.offset>(y?u.lanes[0].header.width:u.lanes[0].header.height)){for(h=0;he.offset){if(g=h>0?e.offset-(h>0?p[h-1]:s).offset:e.offset,y){var b=v.columnDefinitions()[parseInt(h.toString(),10)];b.width-=g,(a=n.nameTable[u.phases[parseInt(h.toString(),10)].header.id]).maxWidth=a.wrapper.maxWidth=b.width,v.updateColumnWidth(h,b.width,!1);var M=new Ad;M.width=g,l=h,v.addColumn(h,M,!1);break}var w=v.rowDefinitions()[h+i];w.height-=g,a=n.nameTable[u.phases[parseInt(h.toString(),10)].header.id],v.updateRowHeight(h+i,w.height,!1);var C=new Vv;C.height=g,l=h,v.addRow(h+i,C,!1);break}if(n.diagramActions&ee.UndoRedo&&void 0===l&&(D=n.historyManager.currentEntry.next).isLastPhase&&function sne(n,t,e,i,r,s){var a=t.shape.phases[n-2],l=e.previousPhase.offset;if(r){var h=i.columnDefinitions()[n-1],c=new Ad;n>1?(c.width=h.width-(l-a.offset),h.width=l-a.offset):(c.width=h.width-l,h.width=l),i.updateColumnWidth(n-1,h.width,!1),i.addColumn(n,c,!1)}else{h=i.rowDefinitions()[parseInt(n.toString(),10)];var d=new Vv;n>1?(d.height=e.undoObject.offset-l,h.height=l-a.offset):(d.height=h.height-l,h.height=l),i.updateRowHeight(n,h.height,!1),i.addRow(1+n,d,!1)}}(l=p.length,t,D,v,y),l>=0){var A=new ob(t.shape,"phases",e,!0);if(n.diagramActions&ee.UndoRedo||(A.id+=Qe()),u.phases.splice(l,0,A),Bx(v,n,t,i,y,l),y){if(r=n.nameTable[v.rows[parseInt(i.toString(),10)].cells[parseInt(l.toString(),10)].children[0].id],0===l&&u.header&&u.hasHeader){v.rows[0].cells[0].children=v.rows[0].cells[1].children,v.rows[0].cells[1].children=[];for(var x=v.rows[0],P=0;Pl+1){var O=n.nameTable[v.rows[parseInt(i.toString(),10)].cells[l+1].children[0].id];v.updateColumnWidth(l+1,L[l+1].width,!0,f),O.maxWidth=O.wrapper.maxWidth=L[l+1].width}t.width=t.wrapper.width=t.wrapper.children[0].width=v.width}else{r=n.nameTable[v.rows[i+l].cells[0].children[0].id];var N=v.rowDefinitions(),T=N[i+l].height;(function ane(n,t,e,i,r){for(var o,a,l=e.rows[parseInt(i.toString(),10)],h=e.rows[i+1],c=e.rows[i-1],d=1;di+l+1&&v.updateRowHeight(i+l+1,T=N[i+l+1].height,!0,f),t.height=t.wrapper.height=t.wrapper.children[0].height=v.actualSize.height}if(Gf(t),t.width=t.wrapper.actualSize.width,Oc(n,t),n.drag(t,c-t.wrapper.bounds.x,d-t.wrapper.bounds.y),RI(t,n),n.commandHandler.select(r),!(n.diagramActions&ee.UndoRedo)){var D={type:"PhaseCollectionChanged",changeType:"Insert",undoObject:$(A),redoObject:$(r),category:"Internal"};n.addHistoryEntry(D)}n.updateDiagramObject(t)}}}}function z3(n,t,e,i,r,s,o){var a,l,p,h=t.shape,c="Horizontal"===h.orientation,d=t.wrapper.children[0],g=c?s:o;e?(a=c?e.bounds.x+e.bounds.width:e.bounds.x,l=c?e.bounds.y:e.bounds.y+e.bounds.height):(a=d.bounds.x,l=r.bounds.y);var v=new Ne(a,l,i.desiredCellWidth,i.desiredCellHeight),S=Wv(n,0,t,{id:t.id+(c?h.lanes[g-2]:h.lanes[g-1]).id+Qe()[0],rowIndex:s,columnIndex:o,width:i.minWidth,height:i.minHeight,style:(c?h.lanes[g-2]:h.lanes[g-1]).style,constraints:ie.Default|ie.AllowDrop,container:{type:"Canvas",orientation:c?"Horizontal":"Vertical"}},!1,!1,!0);if(S.children[0].isCalculateDesiredSize=!1,d.addObject(S,s,o),r&&r.children&&r.children.length)for(p=0;p1)for(var p=1;ph.margin.left&&(h.margin.left=f)):(h.margin.top-=e.desiredCellHeight,f>h.margin.top&&(h.margin.top=f)))}(n,r,i,v,S,c,e)}function R3(n,t,e){if("SwimLane"===t.shape.type&&("ResizeSouth"===e||"ResizeEast"===e)){var i=t.shape,r=t.wrapper.children[0],s=void 0,o=void 0;"ResizeSouth"===e?"Vertical"===i.orientation?s=r.rows[r.rows.length-1].cells[0]:(o=r.rows.length-1,s=r.rows[parseInt(o.toString(),10)].cells[r.rows[parseInt(o.toString(),10)].cells.length-1]):(o=i.header&&i.hasHeader?1:0,s=r.rows[parseInt(o.toString(),10)].cells[r.rows[parseInt(o.toString(),10)].cells.length-1]),n.commandHandler.select(n.nameTable[s.children[0].id])}}function _I(n,t,e,i,r,s){var o,a,l,c,u,f,p,d=Qe(),g=n.shape,v=g.phases,y=n.offsetX-n.wrapper.actualSize.width/2,S=n.offsetY-n.wrapper.actualSize.height/2;if("Vertical"===g.orientation&&(S+=g.header&&g.hasHeader?g.header.height:0),!s)for(r||(n.id+=d,g&&g.header&&g.hasHeader?g.header.id+=d:g.header=void 0),o=0;v&&o0&&s.columnIndex>0||s.isLane)?(a=function mne(n,t,e){for(var i=new Ne,r="SwimLane"===n.shape.type?n.wrapper.children[0].rows:n.wrapper.rows,s=e?1:0;s=0;a--)i?i.id===o.children[parseInt(a.toString(),10)].id&&o.children.splice(a,1):(n.removeDependentConnector(o.children[parseInt(a.toString(),10)]),n.diagramActions&ee.UndoRedo||(n.diagramActions=n.diagramActions|ee.UndoRedo,s=!0),n.remove(o.children[parseInt(a.toString(),10)]),o.children.splice(a,1),s&&(n.diagramActions=n.diagramActions&~ee.UndoRedo))}function hne(n){return n.children[0]}function Gv(n,t){t&&(n.nodes.splice(n.nodes.indexOf(t),1),n.removeFromAQuad(t),n.removeObjectsFromLayer(t),delete n.nameTable[t.id],n.removeElements(t))}function B3(n,t,e,i){var r;if("SwimLane"===e.shape.type){var s=e.shape,o=void 0;if(1===s.lanes.length)n.remove(e);else{var a=e.wrapper.bounds.x,l=e.wrapper.bounds.y,h=void 0,c=void 0,d=void 0,u=void 0,p=e.wrapper.children[0];if(o=i?s.lanes.indexOf(i):HI(e,t),r={element:t,cause:n.diagramActions,diagramAction:n.getDiagramAction(n.diagramActions),state:"Changing",type:"Removal",cancel:!1,laneIndex:o},n.triggerEvent(Ce.collectionChange,r),!r.cancel){var g=s.lanes[parseInt(o.toString(),10)],v=g.children;g.children=[];for(var y=0;y0)for(u=0;u0)for(u=0;u0)for(e=0;e1){c===l.phases.length-1&&(o=!0,a=$(l.phases[c-1]));var u=$(l.phases[parseInt(c.toString(),10)]);if(l.phases.splice(c,1),!(n.diagramActions&ee.UndoRedo)){var f={type:"PhaseCollectionChanged",changeType:"Remove",undoObject:u,previousPhase:a,redoObject:$(t),category:"Internal",isLastPhase:o};n.addHistoryEntry(f)}"Horizontal"===l.orientation?function dne(n,t,e,i){var r,s,o,a,l,h,c,d,u,f,p,g;for(i=void 0!==i?i:e.columnIndex,c=0;c1&&(s=r.cells[parseInt(i.toString(),10)],l=(o=r.cells.length-1===i?r.cells[i-1]:r.cells[i+1]).children[0],s.children.length>0))if(p=n.nameTable[(a=s.children[0]).id],0===o.children.length&&s.children.length>0)o.children=s.children,o.columnSpan=s.columnSpan-1;else{for(d=0;d0){var M=s.children[0],w=n.nameTable[M.id];if(i=e.x&&a.bounds.y<=e.y&&a.bounds.bottom>=e.y){var l=void 0,h=a.bounds.y,c=a.bounds.x,d=n.nameTable[r.parentId]||r;if("SwimLane"===d.shape.type)o=qv(r,d,t,n,!0);else{var f=n.nameTable[r.parentId]||r,p=f.shape;l=f.wrapper,a.actualSize.widtha.outerBounds.x)&&(void 0!==r.rowIndex?(l.updateColumnWidth(r.columnIndex,a.outerBounds.width,!0),"Horizontal"===p.orientation&&p.phaseSize&&FI(f,n,a,r.columnIndex),Oc(n,f),n.drag(f,c-a.bounds.x,h-a.bounds.y)):n.scale(r,1+(a.outerBounds.width-a.actualSize.width)/a.actualSize.width,1,a.outerBounds.xa.outerBounds.y)&&(void 0!==r.rowIndex?(l.updateRowHeight(r.rowIndex,a.outerBounds.height,!0),n.drag(f,c-a.bounds.x,h-a.bounds.y)):n.scale(r,1,1+(a.outerBounds.height-a.actualSize.height)/a.actualSize.height,a.outerBounds.y=e.x&&a.bounds.y<=e.y&&a.bounds.bottom>=e.y)&&!(t.constraints&ie.AllowMovingOutsideLane)){var l=$(t);n.clearSelection(),j3(n,t),t.parentId="",t.parentObj=n,t.propName="nodes";var h={type:"ChildCollectionChanged",category:"Internal",undoObject:l,redoObject:$(t)};n.addHistoryEntry(h),n.commandHandler.isContainer&&(n.commandHandler.isContainer=!1,n.endGroupAction()),V3(t,n)}n.protectPropertyChange(o)}}function UI(n,t){var e,i,r;return n.enableServerDataBinding(!1),ce()||(n.selectedObject.helperObject?r=n.selectedObject.helperObject:(n.selectedItems.nodes.length>0||n.selectedItems.connectors.length>0)&&(t instanceof ei&&t.nodes.length+t.connectors.length===1?(e=t.nodes.length>0?t.nodes[0]:t.connectors[0],i=n.selectedItems.wrapper.children[0]):(e=t,i=n.selectedItems.wrapper),n.selectedObject.actualObject=e,!n.currentSymbol&&(e.isLane&&jx(e,n)&&Dn(n,e)||!e.isLane&&Dn(n,e)||n.constraints&nt.LineRouting&&n.selectedItems.nodes.length>0))&&(r=function yne(n,t){for(var e,i={},r=0,s=Object.keys(t);r=t.x-e&&n.x<=t.x+e&&n.y>=t.y-e&&n.y<=t.y+e}function $a(n){return n.selectedItems.nodes.length>0||n.selectedItems.connectors.length>0}function Y3(n){return 1===n.selectedItems.connectors.length&&!n.selectedItems.nodes.length}function _r(n,t,e,i){if(void 0===e&&(e=!0),t instanceof ei)return!0;if(t instanceof te)for(;t;){if(-1!==n.selectedItems.nodes.indexOf(t)&&void 0===n.selectedItems.annotation)return!0;if(e)break;t=n.nameTable[t.parentId]}else if(t instanceof de){if(-1!==n.selectedItems.connectors.indexOf(t)&&void 0===n.selectedItems.annotation)return!0}else if((t instanceof Kn||t instanceof Or)&&n.selectedItems.annotation&&n.selectedItems.wrapper.children[0].id===i.id)return!0;return!1}var Vx={None:"default",Rotate:"crosshair",Select:"default",Drag:"move",ResizeWest:"w-resize",ResizeEast:"e-resize",ResizeSouth:"s-resize",ResizeNorth:"n-resize",Draw:"crosshair",PortDraw:"crosshair",ResizeNorthEast:"ne-resize",ResizeNorthWest:"nw-resize",ResizeSouthEast:"se-resize",ResizeSouthWest:"sw-resize",ConnectorSourceEnd:"move",ConnectorTargetEnd:"move",BezierSourceThumb:"move",BezierTargetThumb:"move",OrthoThumb:"move",SegmentEnd:"move",Pan:"grab",Hyperlink:"pointer",PortDrag:"pointer",LabelSelect:"pointer",LabelDrag:"move",LabelRotate:"crosshair",LabelResizeWest:"w-resize",LabelResizeEast:"e-resize",LabelResizeSouth:"s-resize",LabelResizeNorth:"n-resize",LabelResizeNorthEast:"ne-resize",LabelResizeNorthWest:"nw-resize",LabelResizeSouthEast:"se-resize",LabelResizeSouthWest:"sw-resize"},ds=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Nd=function(n,t,e,i){return new(e||(e=Promise))(function(r,s){function o(h){try{l(i.next(h))}catch(c){s(c)}}function a(h){try{l(i.throw(h))}catch(c){s(c)}}function l(h){h.done?r(h.value):new e(function(c){c(h.value)}).then(o,a)}l((i=i.apply(n,t||[])).next())})},Od=function(n,t){var i,r,s,o,e={label:0,sent:function(){if(1&s[0])throw s[1];return s[1]},trys:[],ops:[]};return o={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function a(h){return function(c){return function l(h){if(i)throw new TypeError("Generator is already executing.");for(;e;)try{if(i=1,r&&(s=2&h[0]?r.return:h[0]?r.throw||((s=r.return)&&s.call(r),0):r.next)&&!(s=s.call(r,h[1])).done)return s;switch(r=0,s&&(h=[2&h[0],s.value]),h[0]){case 0:case 1:s=h;break;case 4:return e.label++,{value:h[1],done:!1};case 5:e.label++,r=h[1],h=[0];continue;case 7:h=e.ops.pop(),e.trys.pop();continue;default:if(!(s=(s=e.trys).length>0&&s[s.length-1])&&(6===h[0]||2===h[0])){e=0;continue}if(3===h[0]&&(!s||h[1]>s[0]&&h[1]-1&&(r=i.fixedUserHandles[parseInt(o.toString(),10)]);this.commandHandler.triggerEvent(Ce.fixedUserHandleClick,{fixedUserHandle:r,element:e.source}),n.prototype.mouseUp.call(this,e)},t}(us),kd=function(n){function t(e,i){var r=n.call(this,e,!0)||this;return r.isConnected=!1,r.endPoint=i,r}return ds(t,n),t.prototype.mouseDown=function(e){return Nd(this,void 0,void 0,function(){var r,s,o,a,l;return Od(this,function(h){if(this.inAction=!0,this.undoElement=void 0,this instanceof pa||(this.undoElement=$(e.source)),n.prototype.mouseDown.call(this,e),e.source&&e.source.connectors&&(this.oldConnector=$(r=e.source.connectors[0])),"BezierSourceThumb"===this.endPoint||"BezierTargetThumb"===this.endPoint)for(s=0;s0))},t.prototype.endAction=function(){n.prototype.endAction.call(this),this.prevPosition=null,this.endPoint=null},t}(us),fa=function(n){function t(e,i){var r=n.call(this,e,!0)||this;return r.currentTarget=null,r.isStartAction=!1,r.canCancel=!1,r.canTrigger=!1,r.objectType=i,r}return ds(t,n),t.prototype.mouseDown=function(e){if(e.source instanceof te||e.source instanceof de){var i=this.commandHandler.getSelectedObject();this.commandHandler.selectObjects([e.source],e.info&&e.info.ctrlKey,i);var r={nodes:[],connectors:[]};e.source instanceof te?r.nodes.push($(e.source)):r.connectors.push($(e.source)),this.undoElement=$(r)}else this.undoElement=$(e.source);this.undoParentElement=this.commandHandler.getSubProcess(e.source),"Port"===this.objectType&&(this.portId=e.sourceWrapper.id),this.commandHandler.insertBlazorConnector(e.source),n.prototype.mouseDown.call(this,e),this.initialOffset={x:0,y:0}},t.prototype.mouseUp=function(e,i){return Nd(this,void 0,void 0,function(){var s,o,a,l,h,c,d,u,p,g,v,y,S,b,M;return Od(this,function(w){if(this.checkPropertyValue(),a=!1,h={nodes:[],connectors:[]},"Port"!==this.objectType){if(e.source instanceof te||e.source instanceof de?(e.source instanceof te?h.nodes.push($(e.source)):h.connectors.push($(e.source)),(o=$(h)).offsetX=(c=e.source.wrapper).offsetX,o.offsetY=c.offsetY):o=$(e.source),("helper"===(l=this.commandHandler.renderContainerHelper(e.source)||e.source||this.commandHandler.renderContainerHelper(e.source)).id||"helper"!==l.id)&&((l instanceof ei&&(Math.round(l.width)===Math.round(this.undoElement.width)&&Math.round(l.height)===Math.round(this.undoElement.height)||l.selectedObjects&&1===l.selectedObjects.length)||!(l instanceof ei))&&(l.offsetX!==this.undoElement.offsetX||l.offsetY!==this.undoElement.offsetY||l.sourcePoint!==this.undoElement.sourcePoint||l.targetPoint!==this.undoElement.targetPoint)||this.isSelectionHasConnector(l))&&(e.source&&(s={offsetX:e.source.wrapper.offsetX,offsetY:e.source.wrapper.offsetY}),g={source:e.source,state:"Completed",oldValue:this.intialValue,newValue:s,target:this.currentTarget,targetPosition:this.currentPosition,allowDrop:(g={source:e.source,state:"Completed",oldValue:this.intialValue,newValue:s,target:this.currentTarget,targetPosition:this.currentPosition,allowDrop:!0,cancel:!1}).allowDrop,cancel:g.cancel},d=!0,"helper"===l.id?this.canTrigger?(this.commandHandler.triggerEvent(Ce.positionChange,g),this.connectorEndPointChangeEvent(g),d=!0):d=!1:(this.commandHandler.triggerEvent(Ce.positionChange,g),this.connectorEndPointChangeEvent(g)),!i&&d&&(this.commandHandler.startGroupAction(),a=!0,M={type:"PositionChanged",redoObject:$(o),undoObject:$(this.undoElement),category:"Internal"},o.nodes[0]&&o.nodes[0].processId&&(u={type:"SizeChanged",category:"Internal",undoObject:this.undoParentElement,redoObject:this.commandHandler.getSubProcess(e.source)},this.commandHandler.addHistoryEntry(u)),this.commandHandler.addHistoryEntry(M))),this.commandHandler.snapPoint(this.prevPosition,this.currentPosition,0,0),this.commandHandler.removeSnap(),this.commandHandler.removeHighlighter(),e.source&&this.currentTarget&&OI(this.currentTarget)&&this.commandHandler.isDroppable(e.source,this.currentTarget)){if(p=!0,this.commandHandler.drop(this.currentElement,this.currentTarget,this.currentPosition),this.currentTarget&&this.currentTarget instanceof de&&!0===this.commandHandler.diagram.enableConnectorSplit)if(this.currentElement&&this.currentElement instanceof te){if(void 0!==this.currentElement.children)for(b=0;b0)for(var s=0;s0)for(var a=0;a0)for(a=0;a0&&e.connectors.length>0)||e.width===this.undoElement.width&&e.height===this.undoElement.height)},t.prototype.mouseMove=function(e){n.prototype.mouseMove.call(this,e);var r,s,i=!1;(r=this.commandHandler.renderContainerHelper(e.source)||e.source)instanceof te||r instanceof de?r instanceof te?r.offsetX===this.undoElement.nodes[0].offsetX&&r.offsetY===this.undoElement.nodes[0].offsetY&&(i=!0):R.equals(r.sourcePoint,this.undoElement.connectors[0].sourcePoint)&&R.equals(r.targetPoint,this.undoElement.connectors[0].targetPoint)&&(i=!0):r.wrapper.offsetX===this.undoElement.wrapper.offsetX&&r.wrapper.offsetY===this.undoElement.wrapper.offsetY&&(i=!0),r&&(s={offsetX:r.wrapper.offsetX,offsetY:r.wrapper.offsetY});var o={source:r,state:"Start",oldValue:s,newValue:s,target:e.target,targetPosition:e.position,allowDrop:!0,cancel:!1};if(o={source:r,state:"Start",oldValue:s,newValue:s,target:e.target,targetPosition:e.position,allowDrop:o.allowDrop,cancel:o.cancel},this.isStartAction||(this.intialValue={offsetX:r.wrapper.offsetX,offsetY:r.wrapper.offsetY}),i&&!ce()&&(this.commandHandler.triggerEvent(Ce.positionChange,o),this.connectorEndPointChangeEvent(o),this.isStartAction=!0),this.currentPosition=e.position,"Port"!==this.objectType){var h=this.initialOffset.x+(this.currentPosition.x-this.prevPosition.x),c=this.initialOffset.y+(this.currentPosition.y-this.prevPosition.y);this.commandHandler.dragOverElement(e,this.currentPosition),this.commandHandler.disConnect(e.source),this.commandHandler.removeSnap();var d,u=void 0,f=this.commandHandler.snapPoint(this.prevPosition,this.currentPosition,h,c);this.initialOffset.x=h-f.x,this.initialOffset.y=c-f.y,r&&(d={offsetX:r.wrapper.offsetX,offsetY:r.wrapper.offsetY},u={offsetX:r.wrapper.offsetX+f.x,offsetY:r.wrapper.offsetY+f.y}),this.currentTarget&&e.target!==this.currentTarget&&this.commandHandler.removeChildFromBPmn(e.source,e.target,this.currentTarget),this.currentTarget=e.target;var p={source:r,state:"Progress",oldValue:d,newValue:u,target:e.target,targetPosition:e.position,allowDrop:!0,cancel:!1};if(this.commandHandler.triggerEvent(Ce.positionChange,p),this.canTrigger=!0,this.connectorEndPointChangeEvent(p,f),!p.cancel&&!this.canCancel){this.blocked=!this.commandHandler.dragSelectedObjects(f.x,f.y);var g=!this.commandHandler.mouseOver(this.currentElement,this.currentTarget,this.currentPosition);this.blocked=this.blocked||g}if(this.commandHandler.removeStackHighlighter(),this.commandHandler.renderStackHighlighter(e),this.currentTarget&&e.source!==this.currentTarget&&this.commandHandler.isDroppable(e.source,this.currentTarget)&&"helper"!==e.source.id){var v=e.source instanceof ei?e.source.nodes[0]:e.source;!this.commandHandler.isParentAsContainer(v,!0)&&"SwimLane"!==v.shape.type&&!v.shape.isPhase&&(this.currentTarget.isLane?this.commandHandler.renderStackHighlighter(e,this.currentTarget):this.commandHandler.drawHighlighter(this.currentTarget))}else this.commandHandler.removeHighlighter();if(this.commandHandler.canEnableDefaultTooltip()){var y=this.getTooltipContent(e.source);this.commandHandler.showTooltip(e.source,e.position,ko(function(){return y}),"MoveTool",this.isTooltipVisible),this.isTooltipVisible=!1}}else{var b=Bi(),M=e.source;qi(b,-M.rotateAngle||-M.wrapper.rotateAngle,M.offsetX||M.wrapper.offsetX,M.offsetY||M.wrapper.offsetY);var w=Ke(b,{x:this.prevPosition.x,y:this.prevPosition.y}),C=Ke(b,{x:e.position.x,y:e.position.y});this.commandHandler.portDrag(e.source,e.sourceWrapper,C.x-w.x,C.y-w.y)}return this.prevPosition=this.currentPosition,!this.blocked},t.prototype.getTooltipContent=function(e){return"X:"+Math.round(e.wrapper.bounds.x)+" Y:"+Math.round(e.wrapper.bounds.y)},t.prototype.mouseLeave=function(e){this.mouseUp(e)},t.prototype.endAction=function(){n.prototype.endAction.call(this),this.currentTarget=null,this.prevPosition=null},t}(us),Wx=function(n){function t(e){var i=n.call(this,e,!0)||this;return i.rotateStart=!1,i}return ds(t,n),t.prototype.mouseDown=function(e){if(this.undoElement=$(e.source),this.undoElement.nodes[0]&&this.undoElement.nodes[0].children)for(var r=this.commandHandler.getAllDescendants(this.undoElement.nodes[0],[]),s=0;s=2){var s=e.startTouches[0],o=e.startTouches[1],a=e.moveTouches[0],l=e.moveTouches[1],h=this.getDistance(a,l)/this.getDistance(s,o);this.commandHandler.zoom(h,0,0,e.position),this.updateTouch(s,a),this.updateTouch(o,l)}}else this.commandHandler.scroll(this.currentPosition.x-this.prevPosition.x,this.currentPosition.y-this.prevPosition.y,this.currentPosition);return this.commandHandler.dataBinding(),!this.blocked},t.prototype.mouseUp=function(e){this.commandHandler.setBlazorDiagramProps(!1),this.checkPropertyValue(),this.commandHandler.updatePanState(!1),n.prototype.mouseUp.call(this,e),this.inAction=!1},t.prototype.endAction=function(){n.prototype.endAction.call(this)},t.prototype.getDistance=function(e,i){var r=i.pageX-e.pageX,s=i.pageY-e.pageY;return Math.sqrt(r*r+s*s)},t.prototype.updateTouch=function(e,i){e.pageX=i.pageX,e.pageY=i.pageY},t}(us),Tne=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseUp=function(e){this.checkPropertyValue(),this.commandHandler.initExpand(e),n.prototype.mouseUp.call(this,e)},t}(us),Q3=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseUp=function(e){this.checkPropertyValue();var i="_blank",r="",s=window.innerHeight,o=window.innerWidth,a=window.screenTop,l=window.screenLeft;"CurrentTab"===e.sourceWrapper.hyperlink.hyperlinkOpenState?i="_self":"NewWindow"===e.sourceWrapper.hyperlink.hyperlinkOpenState&&(r="height="+s+",width="+o+",top="+a+",left="+l),window.open(e.sourceWrapper.hyperlink.link,i,r).focus(),n.prototype.mouseUp.call(this,e)},t}(us),zl=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseDown=function(e){if(n.prototype.mouseDown.call(this,e),this.inAction=!0,this.drawingObject){var r=void 0,s=this.drawingObject.shape;this.drawingObject.shape.points.push(r={x:(r=s.points[s.points.length-1]).x,y:r.y})}else{this.startPoint={x:this.startPosition.x,y:this.startPosition.y};var i={offsetX:this.currentPosition.x,offsetY:this.currentPosition.y,width:5,height:5,shape:{type:"Basic",shape:"Polygon",points:[{x:this.startPoint.x,y:this.startPoint.y},{x:this.currentPosition.x,y:this.currentPosition.y}]}};this.triggerElementDrawEvent(e.source,"Start","Node",this.getShapeType(),!0),this.drawingObject=this.commandHandler.drawObject(i)}},t.prototype.mouseMove=function(e){if(n.prototype.mouseMove.call(this,e),this.inAction){var i=this.drawingObject.shape;if(i.points[i.points.length-1].x=this.currentPosition.x,i.points[i.points.length-1].y=this.currentPosition.y,this.drawingObject.wrapper.children[0].data=gx(this.drawingObject.shape.points),this.triggerElementDrawEvent(this.drawingObject,"Progress","Node",this.getShapeType(),!1),this.inAction&&!1===R.equals(this.currentPosition,this.prevPosition)){var r=Ne.toBounds(this.drawingObject.shape.points);this.commandHandler.updateNodeDimension(this.drawingObject,r)}}return!0},t.prototype.mouseUp=function(e,i){this.checkPropertyValue(),n.prototype.mouseMove.call(this,e),this.inAction&&(this.inAction=!1,this.commandHandler.addObjectToDiagram(this.drawingObject),this.triggerElementDrawEvent(this.drawingObject,"Completed","Node",this.getShapeType(),!1)),this.endAction()},t.prototype.mouseWheel=function(e){n.prototype.mouseWheel.call(this,e),this.mouseMove(e)},t.prototype.endAction=function(){this.inAction=!1,this.drawingObject=null},t}(us),Rl=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseMove=function(e){if(n.prototype.mouseMove.call(this,e),this.inAction){var i=this.drawingObject;i.targetPoint=this.currentPosition,this.triggerElementDrawEvent(this.drawingObject,"Progress","Connector",this.drawingObject.type,!1),this.commandHandler.updateConnectorPoints(i)}return!0},t.prototype.mouseDown=function(e){if(n.prototype.mouseDown.call(this,e),this.inAction=!0,this.drawingObject){var r=this.drawingObject,s=void 0;(s=new Hl(r,"segments",{type:"Straight"},!0)).point=this.currentPosition,r.segments[r.segments.length-1]=s}else{var i={id:"Connector",type:"Straight",sourcePoint:this.currentPosition,targetPoint:this.currentPosition};this.triggerElementDrawEvent(e.source,"Start","Connector",this.commandHandler.diagram.drawingObject.type,!0),this.inAction&&(this.drawingObject=this.commandHandler.drawObject(i))}},t.prototype.mouseWheel=function(e){n.prototype.mouseWheel.call(this,e),this.mouseMove(e)},t.prototype.mouseUp=function(e){if(this.checkPropertyValue(),n.prototype.mouseMove.call(this,e),this.inAction&&this.drawingObject){var i=this.drawingObject;i.segments[i.segments.length-1].point={x:0,y:0},this.commandHandler.addObjectToDiagram(this.drawingObject),this.triggerElementDrawEvent(this.drawingObject,"Completed","Connector",this.drawingObject.type,!1)}this.endAction()},t.prototype.endAction=function(){this.drawingObject=null,this.inAction=!1},t}(us),Ane=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseDown=function(e){this.inAction=!0,this.undoElement=$(e.source),this.annotationId=e.sourceWrapper.id,n.prototype.mouseDown.call(this,e)},t.prototype.mouseMove=function(e){n.prototype.mouseMove.call(this,e);var i=this.currentPosition.x-this.prevPosition.x,r=this.currentPosition.y-this.prevPosition.y,s=e.source;if(s instanceof te){var o=Bi();qi(o,-s.rotateAngle,0,0);var a=Ke(o,{x:i,y:r});i=a.x,r=a.y}return this.inAction&&(this.commandHandler.labelDrag(e.source,e.sourceWrapper,i,r),this.commandHandler.updateSelector()),this.prevPosition=this.currentPosition,!this.blocked},t.prototype.mouseUp=function(e){this.checkPropertyValue();var i=e.source;this.inAction=!1;var r={type:"AnnotationPropertyChanged",objectId:this.annotationId,undoObject:$(this.undoElement),category:"Internal",redoObject:$(i)};this.commandHandler.addHistoryEntry(r),n.prototype.mouseUp.call(this,e)},t.prototype.mouseLeave=function(e){this.mouseUp(e)},t}(us),Lne=function(n){function t(e,i){var r=n.call(this,e,!0)||this;return r.corner=i,r}return ds(t,n),t.prototype.mouseDown=function(e){this.inAction=!0;var i=e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0];this.annotationId=e.source.wrapper.children[0].id,this.undoElement=$(i);var r=e.source.wrapper.children[0];this.initialBounds={x:r.offsetX,y:r.offsetY,width:r.actualSize.width,height:r.actualSize.height},n.prototype.mouseDown.call(this,e)},t.prototype.mouseMove=function(e){return n.prototype.mouseMove.call(this,e),this.inAction&&this.resizeObject(e),!this.blocked},t.prototype.mouseUp=function(e){this.checkPropertyValue();var i=e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0];this.inAction=!1;var r={type:"AnnotationPropertyChanged",objectId:this.annotationId,redoObject:$(i),undoObject:$(this.undoElement),category:"Internal"};this.commandHandler.addHistoryEntry(r),n.prototype.mouseUp.call(this,e)},t.prototype.mouseLeave=function(e){this.mouseUp(e)},t.prototype.resizeObject=function(e){var i,s,o,r=e.source.wrapper.children[0],a={x:r.offsetX,y:r.offsetY},l=r.rotateAngle;l=((l+=(i=e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0])instanceof te?i.rotateAngle:0)+360)%360;var h=Bi();qi(h,l,a.x,a.y);var c=this.corner.slice(5),d=this.updateSize(r,this.startPosition,this.currentPosition,c,this.initialBounds,l),u=r.offsetX-r.actualSize.width*r.pivot.x,f=r.offsetY-r.actualSize.height*r.pivot.y,p=this.getPivot(c),g=Ke(h,p={x:u+r.actualSize.width*p.x,y:f+r.actualSize.height*p.y});d.x=g.x,d.y=g.y,this.commandHandler.labelResize(i,e.source.annotation,s=(s=d.width)<0?1:s,o=(o=d.height)<0?1:o,d,e.source),this.commandHandler.updateSelector()},t}(us),Nne=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseDown=function(e){this.inAction=!0,this.annotationId=e.source.wrapper.children[0].id,this.undoElement=$(e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0]),n.prototype.mouseDown.call(this,e)},t.prototype.mouseMove=function(e){return n.prototype.mouseMove.call(this,e),e.source&&this.inAction&&(this.commandHandler.labelRotate(e.source.nodes[0]?e.source.nodes[0]:e.source.connectors[0],e.source.annotation,this.currentPosition,e.source),this.commandHandler.updateSelector()),this.prevPosition=this.currentPosition,!this.blocked},t.prototype.mouseUp=function(e){this.checkPropertyValue(),this.inAction=!1;var r={type:"AnnotationPropertyChanged",objectId:this.annotationId,redoObject:$(e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0]),undoObject:$(this.undoElement),category:"Internal"};this.commandHandler.addHistoryEntry(r),n.prototype.mouseUp.call(this,e)},t.prototype.mouseLeave=function(e){this.mouseUp(e)},t}(us),One=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseMove=function(e){if(n.prototype.mouseMove.call(this,e),this.inAction){var i=this.drawingObject.shape;if(i.points.push(this.currentPosition),this.drawingObject.wrapper.children[0].data=vx(this.drawingObject.shape.points),i.data=vx(i.points),this.triggerElementDrawEvent(e.source,"Progress","Connector",this.drawingObject.type,!1),this.inAction&&!1===R.equals(this.currentPosition,this.prevPosition)){var s=Ne.toBounds(this.drawingObject.shape.points);this.commandHandler.updateNodeDimension(this.drawingObject,s)}}return!0},t.prototype.mouseDown=function(e){n.prototype.mouseDown.call(this,e),this.inAction=!0,this.startPoint={x:this.startPosition.x,y:this.startPosition.y};var i={offsetX:this.currentPosition.x,offsetY:this.currentPosition.y,width:5,height:5,style:{strokeColor:"black",strokeWidth:1,fill:"transparent"},shape:{type:"Path",points:[{x:this.startPoint.x,y:this.startPoint.y},{x:this.currentPosition.x,y:this.currentPosition.y}]}};this.triggerElementDrawEvent(e.source,"Start","Connector",this.commandHandler.diagram.drawingObject.type,!0),this.drawingObject=this.commandHandler.drawObject(i)},t.prototype.mouseUp=function(e){if(this.checkPropertyValue(),this.inAction){this.inAction=!1;var s=this.drawingObject.shape,o=s.points;this.commandHandler.addObjectToDiagram(this.drawingObject),this.commandHandler.diagram.remove(this.commandHandler.diagram.nameTable[""+this.drawingObject.id]),o=this.pointReduction(o,10);var h={id:"newConnector"+Qe(),type:"Bezier",sourcePoint:{x:o[0].x,y:o[0].y},targetPoint:{x:o[o.length-1].x,y:o[o.length-1].y},segments:[],bezierSettings:{allowSegmentsReset:!1}};this.drawingObject=this.commandHandler.drawObject(h),this.drawingObject=this.bezierCurveSmoothness(o,.5,this.drawingObject,s),this.commandHandler.updateConnectorPoints(this.drawingObject),this.commandHandler.addObjectToDiagram(this.drawingObject),this.triggerElementDrawEvent(this.drawingObject,"Completed","Connector",this.drawingObject.type,!1),n.prototype.mouseUp.call(this,e)}},t.prototype.pointReduction=function(e,i){if(null===e||e.length<3)return e;var s=e.length-1,o=[];for(o.push(0),o.push(s);e[parseInt((0).toString(),10)]===e[parseInt(s.toString(),10)];)s--;this.reduction(e,0,s,i,o);var a=[];return o.sort(function(l,h){return l-h}),o.forEach(function(l){a.push(e[parseInt(l.toString(),10)])}),a},t.prototype.reduction=function(e,i,r,s,o){for(var a=0,l=0,h=i;ha&&(a=c,l=h)}a>s&&0!==l&&(o.push(l),this.reduction(e,i,l,s,o),this.reduction(e,l,r,s,o))},t.prototype.perpendicularDistance=function(e,i,r){return Math.abs(.5*(e.x*i.y-i.x*e.y+(i.x*r.y-r.x*i.y)+(r.x*e.y-e.x*r.y)))/Math.sqrt(Math.pow(e.x-i.x,2)+Math.pow(e.y-i.y,2))*2},t.prototype.bezierCurveSmoothness=function(e,i,r,s){if(e.length<3)return r;for(var o=0;o=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},kne=function(n){if(n)switch(n.type){case"Bpmn":return Hne;case"UmlActivity":return Rne;case"UmlClassifier":return _ne;default:return Jv}return Jv},Pne=function(n){if(n)switch(n.type){case"Straight":default:return Hl;case"Bezier":return fs;case"Orthogonal":return wi}},G3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I(10)],t.prototype,"width",void 0),Pe([I(10)],t.prototype,"height",void 0),Pe([I("Arrow")],t.prototype,"shape",void 0),Pe([re({fill:"black",strokeColor:"black",strokeWidth:1},Ll)],t.prototype,"style",void 0),Pe([re({x:0,y:.5},R)],t.prototype,"pivot",void 0),Pe([I("")],t.prototype,"pathData",void 0),t}(Ee),WI=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I(0)],t.prototype,"angle",void 0),Pe([I(0)],t.prototype,"distance",void 0),t}(Ee),zne=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I(Ix.All)],t.prototype,"controlPointsVisibility",void 0),Pe([I("FreeForm")],t.prototype,"segmentEditOrientation",void 0),Pe([I(mI.Default)],t.prototype,"smoothness",void 0),Pe([I(!0)],t.prototype,"allowSegmentsReset",void 0),t}(Ee),Jv=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I("None")],t.prototype,"type",void 0),t}(Ee),Rne=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I("Object")],t.prototype,"flow",void 0),Pe([I(30)],t.prototype,"exceptionFlowHeight",void 0),t}(Jv),Hne=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I("Sequence")],t.prototype,"flow",void 0),Pe([I("Normal")],t.prototype,"sequence",void 0),Pe([I("Default")],t.prototype,"message",void 0),Pe([I("Default")],t.prototype,"association",void 0),t}(Jv),X3=function(n){function t(e,i,r,s){var o=n.call(this,e,i,r,s)||this;return o.points=[],o}return Qs(t,n),Pe([I("Straight")],t.prototype,"type",void 0),Pe([I(!0)],t.prototype,"allowDrag",void 0),t}(Ee),Hl=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),t.prototype.getClassName=function(){return"StraightSegment"},Pe([re({x:0,y:0},R)],t.prototype,"point",void 0),t}(X3),fs=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),t.prototype.getClassName=function(){return"BezierSegment"},t.prototype.getPoints=function(e,i){var r=[];if(r.length>0||null!=i){var o=this.bezireToPoly(r.length>0?r[r.length-1]:i,e);r.push.apply(r,o)}return r},t.prototype.bezireToPoly=function(e,i){var r=[];return i&&this.flattenCubicBezier(r,e,i.bezierPoint1,i.bezierPoint2,{x:i.points[1].x,y:i.points[1].y},10),r},t.prototype.flattenCubicBezier=function(e,i,r,s,o,a){var h,l=(R.findLength(i,r)+R.findLength(r,s)+R.findLength(s,o))/a;for(h=0;h<=l;h++){var c=h/l;e.push({x:(1-c)*(1-c)*(1-c)*i.x+3*c*(1-c)*(1-c)*r.x+3*c*c*(1-c)*s.x+c*c*c*o.x,y:(1-c)*(1-c)*(1-c)*i.y+3*c*(1-c)*(1-c)*r.y+3*c*c*(1-c)*s.y+c*c*c*o.y})}},Pe([I("Horizontal")],t.prototype,"orientation",void 0),Pe([re({x:0,y:0},R)],t.prototype,"point1",void 0),Pe([re({x:0,y:0},R)],t.prototype,"point2",void 0),Pe([re({angle:0,distance:0},WI)],t.prototype,"vector1",void 0),Pe([re({angle:0,distance:0},WI)],t.prototype,"vector2",void 0),t}(Hl),wi=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),t.prototype.getClassName=function(){return"OrthogonalSegment"},Pe([I(null)],t.prototype,"length",void 0),Pe([I(null)],t.prototype,"direction",void 0),t}(X3);function q3(n,t,e){var s=e?45:180/(2+2/(n.height/n.width)),o=s,a=180-s,l=a+2*s,h=360-s,c=Gt(t,n.center);return c>o&&ca&&cl&&cMath.abs(t.y-n.y)?n.x=c)return s=R.findAngle(n[parseInt(d.toString(),10)],n[d+1]),{point:r=R.transform(n[parseInt(d.toString(),10)],s,c-(a||0)),index:l=d};a=o[parseInt(d.toString(),10)]}return{point:r,index:l}}(n,t),r=R.findAngle(n[i.index],n[i.index+1]),s=function pse(n){var e=0;switch(n.alignment){case"Center":case"After":e=0;break;case"Before":e=-0}return e}(t),o=R.transform(i.point,r+45,s);return i.point=o,i.angle=r,i}(i,e),h=l.point;s.id=this.id+"_"+e.id;var c=e.style;s.style={fill:c.fill,strokeColor:c.strokeColor,gradient:null,opacity:c.opacity,strokeDashArray:c.strokeDashArray,strokeWidth:c.strokeWidth},0===r.width&&(r.width=this.style.strokeWidth),0===r.height&&(r.height=this.style.strokeWidth);var d_y=(h.y-r.y)/r.height;a.x=r.width*((h.x-r.x)/r.width),a.y=r.height*d_y;var g,v,u=dF(e,l.angle,i),f=u.hAlign,p=u.vAlign;return"left"===f?(g="Left",a.x+=e.displacement.x):"right"===f?(g="Right",a.x-=e.displacement.x):"center"===f&&(g="Center"),"top"===p?(v="Top",a.y+=e.displacement.y):"bottom"===p?(v="Bottom",a.y-=e.displacement.y):"center"===p&&(v="Center"),s.horizontalAlignment=g,s.verticalAlignment=v,(s=tm(s,o&&"Label"!==o.flipMode&&"None"!==o.flipMode?this.flip:"None",e)).float=!0,s.connectionDirection=e.connectionDirection,s.setOffsetWithRespectToBounds(a.x,a.y,"Absolute"),s.relativeMode="Point",s.visible=!(!va(e,ci.Visible)||va(e,ci.Hover)||va(e,ci.Connect)),s.elementActions=s.elementActions|Xr.ElementIsPort,s},t.prototype.getConnectorRelation=function(){var e=this.shape;"Association"===e.relationship?(this.segments[0].type="Straight",this.sourceDecorator.shape="None",this.targetDecorator.shape="Arrow"):"Inheritance"===e.relationship?(this.segments[0].type="Orthogonal",this.sourceDecorator.shape="None",this.targetDecorator.shape="Arrow"):"Composition"===e.relationship||"Aggregation"===e.relationship?(this.segments[0].type="Orthogonal",this.sourceDecorator.shape="Diamond",this.targetDecorator.shape="None"):"Dependency"===e.relationship?(this.segments[0].type="Orthogonal",this.sourceDecorator.shape="None",this.targetDecorator.shape="OpenArrow"):"Realization"===e.relationship&&(this.segments[0].type="Orthogonal",this.sourceDecorator.shape="None",this.targetDecorator.shape="Arrow"),"BiDirectional"===e.associationType&&(this.sourceDecorator.shape="None",this.targetDecorator.shape="None");var i,o,r="",s="";e.multiplicity.source&&(e.multiplicity.source.lowerBounds=e.multiplicity.source.lowerBounds,e.multiplicity.source.upperBounds=e.multiplicity.source.upperBounds),e.multiplicity.target&&(e.multiplicity.target.lowerBounds=e.multiplicity.target.lowerBounds,e.multiplicity.target.upperBounds=e.multiplicity.target.upperBounds);var a=e.multiplicity.source,l=e.multiplicity.target;o=a.upperBounds?a.lowerBounds+"..."+a.upperBounds:a.lowerBounds,i=l.upperBounds?l.lowerBounds+"..."+l.upperBounds:l.lowerBounds,"ManyToOne"===e.multiplicity.type&&(e.multiplicity.target.optional=!1,r=o||"*",s="1"),"OneToMany"===e.multiplicity.type&&(e.multiplicity.source.optional=!1,s=i||"*",r="1"),"ManyToMany"===e.multiplicity.type&&(r=o||"*",s=i||"*"),"OneToOne"===e.multiplicity.type&&(e.multiplicity.target.optional=!1,e.multiplicity.source.optional=!1,r="1",s="1"),this.annotations=[{id:this.id+"sourcelabel",content:r,offset:0,alignment:"Before",margin:{right:5,bottom:5}},{id:this.id+"targetlabel",content:s,offset:1,alignment:"Before",margin:{right:5,bottom:5}}]},t.prototype.getBpmnSequenceFlow=function(){var e=new Ze,i=new Ze;return"Normal"===this.shape.sequence&&"Bezier"!==this.type&&(this.targetDecorator.shape="Arrow"),"Default"===this.shape.sequence&&(e=this.getSegmentElement(this,e),i=yF(this.intermediatePoints,this),this.targetDecorator.shape="Arrow"),"Conditional"===this.shape.sequence&&(this.targetDecorator.shape="Arrow",this.sourceDecorator.shape="Diamond",i.id=this.id+this.shape.type),i},t.prototype.getUMLObjectFlow=function(){if(this.annotations)for(var e=0;e0&&(this.sourcePoint=o[0],this.targetPoint=o[o.length-1]),o},t.prototype.clipDecorator=function(e,i,r,s){var a,l,o={x:0,y:0},h=i.length,c=R.distancePoints(a=r?i[0]:i[h-1],l=r?i[1]:i[h-2]);c=0===c?1:c;var d=1,u=r?e.sourceWrapper:e.targetWrapper;u&&(d=u.style.strokeWidth,s&&s&ee.DecoratorPropertyChange&&(d=1));var f=d-1;return o.x=Math.round(a.x+f*(l.x-a.x)/c),o.y=Math.round(a.y+f*(l.y-a.y)/c),(r&&"None"!==e.sourceDecorator.shape||!r&&"None"!==e.targetDecorator.shape)&&(o=R.adjustPoint(o,l,!0,s&ee.DecoratorPropertyChange?0:d/2)),o},t.prototype.clipDecorators=function(e,i,r){return"None"!==e.sourceDecorator.shape&&(i[0]=this.clipDecorator(e,i,!0,r)),"None"!==e.targetDecorator.shape&&(i[i.length-1]=this.clipDecorator(e,i,!1,r)),i},t.prototype.updateSegmentElement=function(e,i,r,s){var o=new Ne,a=this.getSegmentPath(e,i,s);if("Bezier"===e.type){if(this.segments.length>0)for(var l=0;l0)if("Straight"===e.type&&e.segments.length<2)for(var o=0;o1)for(o=0;o0&&"Bezier"!==this.type)for(var f=0;f0&&(a=f0&&(p<2*this.cornerRadius?(l=R.adjustPoint(h[parseInt(f.toString(),10)],h[f+1],!0,p/2),f0&&(s=this.bridgePath(e,s,f),"Orthogonal"===e.type&&(s=this.bridgePath(e,s,f+1))),s+=" L"+a.x+" "+a.y))}else if("Bezier"===this.type){var g=void 0,v=void 0;if(this.parentObj.element){var y=this.parentObj.element.ej2_instances[0].eventHandler.action;g=this.parentObj.element.ej2_instances[0].eventHandler.tool instanceof Pd,v=y.includes("PortDraw")||y.includes("Drag")}for(var S=void 0,b=this.segments,M=0;M2&&(b[parseInt(M.toString(),10)].bezierPoint1={x:0,y:0},b[parseInt(M.toString(),10)].bezierPoint2={x:0,y:0}),!R.isEmptyPoint(b[parseInt(M.toString(),10)].point1)||b[parseInt(M.toString(),10)].vector1.angle||b[parseInt(M.toString(),10)].vector1.distance?b[parseInt(M.toString(),10)].vector1.angle||b[parseInt(M.toString(),10)].vector1.distance?b[parseInt(M.toString(),10)].bezierPoint1=R.transform(h[parseInt(M.toString(),10)],b[parseInt(M.toString(),10)].vector1.angle,b[parseInt(M.toString(),10)].vector1.distance):b[parseInt(M.toString(),10)].bezierPoint1={x:b[parseInt(M.toString(),10)].point1.x||b[parseInt(M.toString(),10)].bezierPoint1.x,y:b[parseInt(M.toString(),10)].point1.y||b[parseInt(M.toString(),10)].bezierPoint1.y}:((e.sourceID||this.sourcePortID)&&this.sourceWrapper&&!v&&!g&&(S=q3(this.sourceWrapper.bounds,h[parseInt(M.toString(),10)],!0)),b[parseInt(M.toString(),10)].bezierPoint1=QI(h[parseInt(M.toString(),10)],h[M+1],S)),!R.isEmptyPoint(b[parseInt(M.toString(),10)].point2)||b[parseInt(M.toString(),10)].vector2.angle||b[parseInt(M.toString(),10)].vector2.distance?b[parseInt(M.toString(),10)].vector2.angle||b[parseInt(M.toString(),10)].vector2.distance?b[parseInt(M.toString(),10)].bezierPoint2=R.transform(h[M+1],b[parseInt(M.toString(),10)].vector2.angle,b[parseInt(M.toString(),10)].vector2.distance):b[parseInt(M.toString(),10)].bezierPoint2={x:b[parseInt(M.toString(),10)].point2.x||b[parseInt(M.toString(),10)].bezierPoint2.x,y:b[parseInt(M.toString(),10)].point2.y||b[parseInt(M.toString(),10)].bezierPoint2.y}:((e.targetID||this.targetPortID)&&this.targetWrapper&&!v&&!g&&(S=q3(this.targetWrapper.bounds,h[M+1],!0)),b[parseInt(M.toString(),10)].bezierPoint2=QI(h[M+1],h[parseInt(M.toString(),10)],S));h.splice(1,0,{x:b[0].bezierPoint1.x,y:b[0].bezierPoint1.y}),h.splice(h.length-1,0,{x:b[b.length-1].bezierPoint2.x,y:b[b.length-1].bezierPoint2.y}),h=this.clipDecorators(e,h,r);for(var w=0;w0&&(s=this.bridgePath(e,s,D),s+=" L"+o.x+" "+o.y);return s},t.prototype.updateShapeElement=function(e){var i;switch(e.shape.type){case"Bpmn":e.wrapper.children[3]instanceof Ze&&(i=e.wrapper.children[3]),"Message"===e.shape.flow&&this.updateShapePosition(e,i);break;case"UmlActivity":"Exception"===e.shape.flow&&this.getUMLExceptionFlow(e.wrapper.children[0])}},t.prototype.updateShapePosition=function(e,i){var o=SF(this.intermediatePoints,i,.5);i.offsetX=o.x,i.offsetY=o.y},t.prototype.scale=function(e,i,r,s,o){var a=0,l=0;if(this.wrapper&&this.wrapper.outerBounds){var h=function I3(n){var t=n.wrapper.children[0].bounds;return"None"!==n.sourceDecorator.shape&&t.uniteRect(n.wrapper.children[1].bounds),"None"!==n.targetDecorator.shape&&t.uniteRect(n.wrapper.children[2].bounds),t}(this),c=Math.abs((this.wrapper.bounds.width||this.style.strokeWidth||1)-2),d=Math.abs((this.wrapper.bounds.height||this.style.strokeWidth||1)-2);a=h.width-c,l=h.height-d,e=Math.abs((r-Math.max(a,l))/c),i=Math.abs((s-Math.max(a,l))/d),a=l=Math.min(a,l)}e=i=Math.min(e,i);var u=Bi();qi(u,-(o=o||this.wrapper).rotateAngle,o.offsetX,o.offsetY),Yf(u,e,i,o.offsetX,o.offsetY),qi(u,o.rotateAngle,o.offsetX,o.offsetY);var f=function Tie(n,t){for(var e=[],i=0,r=t;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},jne=function(n){function t(e,i){var r=n.call(this,e,i)||this;return r.offset=0,r.scale=1,r}return Une(t,n),t.prototype.preRender=function(){this.unWireEvents(),this.wireEvents()},t.prototype.render=function(){this.updateRulerGeometry(),this.renderComplete()},t.prototype.getModuleName=function(){return"Ruler"},t.prototype.destroy=function(){this.unWireEvents(),this.notify("destroy",{}),n.prototype.destroy.call(this),this.element.classList.remove("e-ruler")},t.prototype.getPersistData=function(){return this.addOnPersist(["loaded"])},t.prototype.onPropertyChanged=function(e,i){for(var r=0,s=Object.keys(e);r100;)r/=10,s/=10;for(;s<25;)r*=10,s*=10;return s>=25&&s%25!=0&&(s=25*Math.round(s/25)),s*e/r},t.prototype.createMarkerLine=function(e,i,r){var s;return i&&((s=e.getElementById(i.id+"_marker"))&&s.parentNode.removeChild(s),s=Fi("line",r)),s},t.prototype.drawRulerMarker=function(e,i,r){var s,o,h,d,u="Horizontal"===this.orientation,f=e.getElementsByTagName("svg");for(h=0;h0)for(var a=i.childNodes.length-1;a>=0;a--)i.childNodes[parseInt(a.toString(),10)].parentNode.removeChild(i.childNodes[parseInt(a.toString(),10)]);i.appendChild(s)}return s},t.prototype.wireEvents=function(){},t.prototype.unWireEvents=function(){},kc([I(5)],t.prototype,"interval",void 0),kc([I(100)],t.prototype,"segmentWidth",void 0),kc([I("Horizontal")],t.prototype,"orientation",void 0),kc([I("RightOrBottom")],t.prototype,"tickAlignment",void 0),kc([I("red")],t.prototype,"markerColor",void 0),kc([I(25)],t.prototype,"thickness",void 0),kc([I(null)],t.prototype,"arrangeTick",void 0),kc([I(400)],t.prototype,"length",void 0),t}(Ii);function J3(n,t){var e=document.getElementById(n.element.id+(t?"_hRuler":"_vRuler")),i=Za(n),r=K3(n);e||(e=Tt("div",{id:n.element.id+(t?"_hRuler":"_vRuler"),style:"height:"+(t?i.height:r.height+100)+"px;overflow:hidden;width:"+(t?r.width+100:i.width)+"px;position:absolute;font-size:11px;"+(t?"margin-left:"+i.width+"px;":"margin-top:"+i.height+"px;")})),n.element.insertBefore(e,n.element.firstChild);var l=t?n.rulerSettings.horizontalRuler:n.rulerSettings.verticalRuler,h=new jne(l);h.orientation=t?"Horizontal":"Vertical",h.length=(t?r.width:r.height)+l.segmentWidth,h.appendTo("#"+n.element.id+(t?"_hRuler":"_vRuler")),t?n.hRuler=h:n.vRuler=h;var c=document.getElementById(n.element.id+(t?"_hRuler":"_vRuler"));t?n.hRuler.element=c:n.vRuler.element=c}function GI(n){var t=-n.scroller.horizontalOffset,e=-n.scroller.verticalOffset;n&&n.rulerSettings.showRulers?(n.hRuler.length=0,n.vRuler.length=0,void 0!==t&&n.hRuler.element&&eF(n,n.hRuler,t,!0),void 0!==e&&n.vRuler.element&&eF(n,n.vRuler,e,!1)):Yx(n)}function Yx(n){an(n.element.id+"_hRuler"),an(n.element.id+"_vRuler"),an(n.element.id+"_overlapRuler")}function Za(n){var t=0,e=0;return n.rulerSettings.showRulers&&(t=n.rulerSettings.horizontalRuler.thickness,e=n.rulerSettings.verticalRuler.thickness),new me(e,t)}function K3(n){var t=Za(n),e=n.scroller.viewPortHeight,i=n.scroller.viewPortWidth;return i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},tF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Xne(t,n),t.prototype.getClassName=function(){return"UserHandle"},Un([I("")],t.prototype,"name",void 0),Un([I("")],t.prototype,"pathData",void 0),Un([I("")],t.prototype,"content",void 0),Un([I("")],t.prototype,"source",void 0),Un([I("#000000")],t.prototype,"backgroundColor",void 0),Un([I("Top")],t.prototype,"side",void 0),Un([I("")],t.prototype,"borderColor",void 0),Un([I(.5)],t.prototype,"borderWidth",void 0),Un([I(25)],t.prototype,"size",void 0),Un([I("white")],t.prototype,"pathColor",void 0),Un([I(10)],t.prototype,"displacement",void 0),Un([I(!0)],t.prototype,"visible",void 0),Un([I(0)],t.prototype,"offset",void 0),Un([re({},Jn)],t.prototype,"margin",void 0),Un([I("Center")],t.prototype,"horizontalAlignment",void 0),Un([I("Center")],t.prototype,"verticalAlignment",void 0),Un([I(!1)],t.prototype,"disableNodes",void 0),Un([I(!1)],t.prototype,"disableConnectors",void 0),Un([re({},Dd)],t.prototype,"tooltip",void 0),Un([I("")],t.prototype,"template",void 0),t}(Ee);function iF(n){return qne[n.toString()]}var qne={Action:"M 90 82.895 C 90 86.819 86.776 90 82.8 90 H 7.2 C 3.224 90 0 86.819 0 82.895 V 7.105 C 0 3.181 3.224 0 7.2 0 h 75.6 C 86.776 0 90 3.181 90 7.105 V 82.895 Z",Decision:"M10,19.707L0.293,10L10,0.293L19.707,10L10,19.707z",MergeNode:"M10,19.707L0.293,10L10,0.293L19.707,10L10,19.707z",InitialNode:"M10,19.5c-5.238,0-9.5-4.262-9.5-9.5S4.762,0.5,10,0.5s9.5,4.262,9.5,9.5S15.238,19.5,10,19.5z",ForkNode:"m0.75,0.75l636.00002,0l0,290l-636.00002,0l0,-290z",JoinNode:"m0.75,0.75l636.00002,0l0,290l-636.00002,0l0,-290z",TimeEvent:"M50.001,0.00286865 L25.001,25.0029 L0.000976562,0.00286865 L50.001,0.00286865 z M0.000976562,50.0029 L25.001,25.0029 L50.001,50.0029 L0.000976562,50.0029 z",AcceptingEvent:"M17.8336 32.164 L29.64 24 L17.32 16 L48.1664 16 L48.5 32 Z",SendSignal:"M48.164 31.8336 L56 23.832 L47.836 16 L16.168 16 L16.1668 31.8336 Z",ReceiveSignal:"M48.1664 31.8336 L39.836 24 L47.836 16 L16.168 16 L16.168 31.836 Z",StructuredNode:"M0,0 L50,0 L50,50 L0,50 z",Note:"M20 12 L4 12 L4 22 L22 22 L22 14 L20 14 L20 12 L22 14 Z"},XI=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Ja=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},$ne=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return XI(t,n),Ja([I()],t.prototype,"key",void 0),Ja([I()],t.prototype,"keyModifiers",void 0),t}(Ee),rF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return XI(t,n),t.prototype.getClassName=function(){return"Command"},Ja([I("")],t.prototype,"name",void 0),Ja([I()],t.prototype,"canExecute",void 0),Ja([I()],t.prototype,"execute",void 0),Ja([re({},$ne)],t.prototype,"gesture",void 0),Ja([I("")],t.prototype,"parameter",void 0),t}(Ee),Zne=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return XI(t,n),Ja([Ft([],rF)],t.prototype,"commands",void 0),t}(Ee),Jne=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return XI(t,n),Ja([I()],t.prototype,"show",void 0),Ja([I()],t.prototype,"showCustomMenuOnly",void 0),Ja([I()],t.prototype,"items",void 0),t}(Ee),$f=function(){function n(){}return n.prototype.renderShadow=function(t,e,i,r){void 0===i&&(i=null);var l,o=R.transform({x:0,y:0},t.shadow.angle,t.shadow.distance);r&&(l=r.getElementById(e.id+"_shadow")),l||(l=document.createElementNS("http://www.w3.org/2000/svg",i?"path":"rect"),e.appendChild(l));var h={id:e.id+"_shadow",fill:t.shadow.color,stroke:t.shadow.color,opacity:t.shadow.opacity.toString(),transform:"rotate("+t.angle+","+(t.x+t.width*t.pivotX)+","+(t.y+t.height*t.pivotY)+")translate("+(t.x+o.x)+","+(t.y+o.y)+")"};if(r){var c=r.getElementById(e.id);c&&c.insertBefore(l,c.firstChild)}ti(l,h),i?i&&this.renderPath(l,t,i):ti(l,{width:t.width,height:t.height})},n.prototype.parseDashArray=function(t){return[]},n.prototype.drawRectangle=function(t,e,i,r,s,o,a,l,h){var c,d,u,f;e.shadow&&!r&&this.renderShadow(e,t,void 0,o),c=e.id===t.id?e.id+"_container":e.id,o&&(d=o.getElementById(c)),(!d||s)&&(d=document.createElementNS("http://www.w3.org/2000/svg","rect"),t.appendChild(d)),o&&!e.shadow&&(u=o.getElementById(e.id+"_groupElement_shadow"))&&u.parentNode.removeChild(u),f=l?{id:c,x:e.x.toString(),y:e.y.toString(),width:e.width.toString(),height:e.height.toString(),visibility:e.visible?"visible":"hidden",transform:"rotate("+e.angle+","+(e.x+e.width/2)+","+(e.y+e.height/2)+")",rx:e.cornerRadius||0,ry:e.cornerRadius||0,opacity:e.opacity}:{id:c,x:e.x.toString(),y:e.y.toString(),width:e.width.toString(),height:e.height.toString(),visibility:e.visible?"visible":"hidden",transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")",rx:e.cornerRadius||0,ry:e.cornerRadius||0,opacity:e.opacity},a&&(f.role="img",f["aria-label"]=a);var p=e.class||"";h||(p.includes("e-diagram-resize-handle")||p.includes("e-diagram-endpoint-handle")||p.includes("e-diagram-bezier-control-handle"))&&(p+=" e-disabled"),e.class&&(f.class=p),a||(f["pointer-events"]="none"),ti(d,f),this.setSvgStyle(d,e,i)},n.prototype.updateSelectionRegion=function(t,e){var i;i=t.parentNode.getElementById(e.id);var r={id:e.id,x:e.x.toString(),y:e.y.toString(),width:e.width.toString(),height:e.height.toString(),transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")",class:"e-diagram-selected-region"};i||(i=document.createElementNS("http://www.w3.org/2000/svg","rect"),t.appendChild(i)),this.setSvgStyle(i,e),ti(i,r)},n.prototype.createGElement=function(t,e){return Fi(t,e)},n.prototype.drawLine=function(t,e){var i=document.createElementNS("http://www.w3.org/2000/svg","line");this.setSvgStyle(i,e);var r=e.x+e.width*e.pivotX,s=e.y+e.height*e.pivotY,o={id:e.id,x1:e.startPoint.x+e.x,y1:e.startPoint.y+e.y,x2:e.endPoint.x+e.x,y2:e.endPoint.y+e.y,stroke:e.stroke,"stroke-width":e.strokeWidth.toString(),opacity:e.opacity.toString(),transform:"rotate("+e.angle+" "+r+" "+s+")",visibility:e.visible?"visible":"hidden"};e.class&&(o.class=e.class),ti(i,o),t.appendChild(i)},n.prototype.drawCircle=function(t,e,i,r){var s=document.createElementNS("http://www.w3.org/2000/svg","circle");this.setSvgStyle(s,e);var o=e.class||"";i||(o+=" e-disabled");var a={id:e.id,cx:e.centerX,cy:e.centerY,r:e.radius,visibility:e.visible?"visible":"hidden",class:o};r&&(a.role="img",a["aria-label"]=r),s.style.display=e.visible?"block":"none",ti(s,a),t.appendChild(s)},n.prototype.drawPath=function(t,e,i,r,s,o,a){var h,c,l=[];l=QB(l=Ed(e.data)),e.shadow&&this.renderShadow(e,t,l,s),s&&!e.shadow&&(h=s.getElementById(e.id+"_groupElement_shadow"))&&h.parentNode.removeChild(h),s&&(c=s.getElementById(e.id)),(!c||r)&&(c=document.createElementNS("http://www.w3.org/2000/svg","path"),t.appendChild(c)),this.renderPath(c,e,l);var d={};d=a?{id:e.id,transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")translate("+e.x+","+e.y+"),scale("+a+")",visibility:e.visible?"visible":"hidden",opacity:e.opacity}:{id:e.id,transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")translate("+e.x+","+e.y+")",visibility:e.visible?"visible":"hidden",opacity:e.opacity},o&&(d.role="img",d["aria-label"]=o),e.class&&(d.class=e.class),ti(c,d),this.setSvgStyle(c,e,i)},n.prototype.renderPath=function(t,e,i){var r,s,o,a,l,h,c,d,u=i,f="";for(l=0,h=0,d=0,c=u.length;de.width&&"Wrap"!==e.textOverflow&&"NoWrap"===e.textWrapping&&(h[0].text=UF(e.content,e)),v=0;vD&&(u.text=u.text.slice(0,u.text.length-3),u.text=u.text.concat("..."),l.data=u.text),this.alignText(y,f,u,l,p,g,v,e,h),C+=u.dy}}C&&e.isHorizontalLane&&(M=e.parentOffsetX+e.pivotX,w=e.parentOffsetY+e.pivotY,e.y=e.parentOffsetY-C*e.pivotY+.5),e.textDecoration&&"LineThrough"===e.textDecoration&&(e.textDecoration=lb(e.textDecoration));var P={id:e.id+"_text",fill:e.color,visibility:e.visible?"visible":"hidden","text-decoration":e.textDecoration,transform:"rotate("+e.angle+","+M+","+w+")translate("+e.x+","+e.y+")",opacity:e.opacity};r&&(P.role="img",P["aria-label"]=r),ti(y,P)}},n.prototype.alignText=function(t,e,i,r,s,o,a,l,h){"justify"!==l.textAlign?this.setText(t,e,i,r,s,o,l):a!==h.length-1?this.setText(t,e,i,r,s,o,l,l.width,"spacing"):this.setText(t,e,i,r,s,o,l)},n.prototype.setText=function(t,e,i,r,s,o,a,l,h){ti(e,"justify"!==a.textAlign?{x:s.toString(),y:o.toString()}:{x:s.toString(),y:o.toString(),textLength:l||0,lengthAdjust:h||"spacing"}),t.setAttribute("fill",i.text),e.appendChild(r),t.appendChild(e)},n.prototype.drawImage=function(t,e,i,r){var s;i&&(s=i.getElementById(e.id+"image")),s||(s=document.createElementNS("http://www.w3.org/2000/svg","image"),t.appendChild(s));var o=new Image;o.src=e.source;var a="None"!==e.scale?e.scale:"",l=e.alignment,h=l.charAt(0).toLowerCase()+l.slice(1);"Stretch"!==a&&(h+=" "+a.charAt(0).toLowerCase()+a.slice(1)),ti(s,{id:e.id+"image",x:e.x.toString(),y:e.y.toString(),transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")",width:e.width.toString(),visibility:e.visible?"visible":"hidden",height:e.height.toString(),preserveAspectRatio:h,opacity:e.opacity.toString()}),s.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",o.src.toString())},n.prototype.drawHTMLContent=function(t,e,i,r,s){var o,a;if(e&&(o=e.querySelector("#"+t.id+"_html_element")),!o){(a=e.querySelector("#"+t.id+"_html_element")||e.querySelector("#"+t.nodeId+"_html_element"))||(a=Tt("div",{id:t.nodeId+"_html_element",class:"foreign-object"})),o=Tt("div",{id:t.id+"_html_element",class:"foreign-object"});var c=document.getElementById(t.diagramId).ej2_instances[0],d=!1;if(e.parentNode&&e.parentNode.parentNode&&e.parentNode.parentNode.parentNode&&e.parentNode.parentNode.parentNode.classList.contains("e-overview")&&(d=!0),d)c.isReact?c.renderReactTemplates(function(){o.appendChild(t.template.cloneNode(!0))}):o.appendChild(t.template.cloneNode(!0));else{if("string"==typeof t.template){var u=document.createElement("div");u.innerHTML=t.template,t.template=u,c.selectedItems.userHandles.filter(function(g){return g.name===t.id.split("_shape")[0]&&""!==g.template})[0].template=t.template}t.isTemplate&&t.template?o.appendChild(t.template):t.template&&o.appendChild(t.template.cloneNode(!0))}void 0!==s&&e.childNodes.length>s&&e.insertBefore(o,e.childNodes[parseInt(s.toString(),10)]),a.appendChild(o),e.appendChild(a)}var p=xn(t).topLeft;o.setAttribute("style","height:"+t.actualSize.height+"px; width:"+t.actualSize.width+"px;left:"+p.x+"px; top:"+p.y+"px;position:absolute;transform:rotate("+(t.rotateAngle+t.parentTransform)+"deg);pointer-events:"+(r?"all":"none")+";visibility:"+(t.visible?"visible":"hidden")+";opacity:"+t.style.opacity+";")},n.prototype.drawNativeContent=function(t,e,i,r,s){var o,a;if(s&&(o=s.getElementById(t.id+"_native_element"),a=s.getElementById(t.id+"_clip")),!o){(o=document.createElementNS("http://www.w3.org/2000/svg","g")).setAttribute("id",t.id+"_native_element"),o.appendChild(t.template.cloneNode(!0));var l=this.createGElement("g",{id:t.id+"_inner_native_element"});l.appendChild(o),e.appendChild(l)}a&&o.removeChild(a),o.setAttribute("style","visibility:"+(t.visible?"visible":"hidden")+";opacity:"+t.style.opacity+";"),this.setNativTransform(t,o,i,r),"Slice"===t.scale&&this.drawClipPath(t,o,i,r,s),ti(o,t.description?{role:"img","aria-label":t.description}:{})},n.prototype.setNativTransform=function(t,e,i,r){var s=0!==t.contentSize.width?t.contentSize.width:1,o=0!==t.contentSize.height?t.contentSize.height:1;e.setAttribute("transform","rotate("+t.parentTransform+","+t.offsetX+","+t.offsetY+") translate("+(t.offsetX-t.templatePosition.x*r/s-r*t.pivot.x)+","+(t.offsetY-t.templatePosition.y*i/o-i*t.pivot.y)+") scale("+r/s+","+i/o+")")},n.prototype.drawClipPath=function(t,e,i,r,s){var o=t.contentSize.width,a=t.contentSize.height,l=t.width/(r/o),h=t.height/(i/a),c=t.templatePosition.x+(t.width>=t.height?0:(o-l)/2),d=t.templatePosition.y+(t.height>=t.width?0:(a-h)/2),u=s.getElementById(t.id+"_clip");(u=document.createElementNS("http://www.w3.org/2000/svg","clipPath")).setAttribute("id",t.id+"_clip"),e.appendChild(u);var f=s.getElementById(t.id+"_clip_rect");return f=document.createElementNS("http://www.w3.org/2000/svg","rect"),u.appendChild(f),ti(f,{id:t.id+"_clip_rect",width:l.toString(),height:h.toString(),x:c.toString(),y:d.toString()}),rm()?e.setAttribute("clip-path","url("+location.protocol+"//"+location.host+location.pathname+"#"+t.id+"_clip)"):e.setAttribute("clip-path","url(#"+t.id+"_clip)"),e},n.prototype.renderGradient=function(t,e,i){var r,s,o,h,c,a=vT(i),l=a.getElementById(i+"gradient_pattern");if(l||(l=Fi("defs",{id:i+"gradient_pattern"}),a.insertBefore(l,a.firstChild)),fF(e.id),"None"!==t.gradient.type){for(var d=0;dt.width&&("Ellipsis"===t.textOverflow||"Clip"===t.textOverflow)&&"NoWrap"===t.textWrapping?0:.5*t.width:"right"===t.textAlign&&(c=1*t.width),s.x=0+c+(e?e.x:0),s.y=1.2+d-r.height/2,s},n}(),Pc=function(){function n(t,e,i){this.renderer=null,this.isSvgMode=!0,this.touchMove=void 0,this.transform={x:0,y:0},this.diagramId=t,this.element=xt(this.diagramId),this.svgRenderer=e,this.isSvgMode=i,this.renderer=i?new $f:new bo}return n.prototype.setCursor=function(t,e){t.style.cursor=e},n.prototype.setLayers=function(){this.iconSvgLayer=this.element.getElementsByClassName("e-ports-expand-layer")[0],this.adornerSvgLayer=this.element.getElementsByClassName("e-adorner-layer")[0],this.nativeSvgLayer=this.element.getElementsByClassName("e-native-layer")[0],this.diagramSvgLayer=this.element.getElementsByClassName("e-diagram-layer")[0]},n.prototype.getAdornerLayer=function(){return pT(this.diagramId)},n.prototype.getParentSvg=function(t,e,i){return this.diagramId&&t&&t.id?t.id.split("_icon_content").length>1||t.id.split("_nodeport").length>1||t.elementActions&Xr.ElementIsPort?this.iconSvgLayer:e&&"selector"===e?this.adornerSvgLayer:t instanceof En?this.nativeSvgLayer:this.diagramSvgLayer:i},n.prototype.getParentElement=function(t,e,i,r){var s=e;if(i&&this.diagramId&&t&&t.id){t.id.split("_icon_content").length>1?(s=i.getElementById(this.diagramId+"_diagramExpander"),e=null):t.id.split("_nodeport").length>1?s=i.getElementById(this.diagramId+"_diagramPorts"):t instanceof En?(s=i.getElementById(this.diagramId+"_nativeLayer"),e=null):t.elementActions&Xr.ElementIsPort?(s=i.getElementById(this.diagramId+"_diagramPorts"),e=null):s=i.getElementById(this.diagramId+"_diagramLayer");var o=this.getGroupElement(t,e||s,r);s=o.g,o.svg&&(i=o.svg)}return{g:s,svg:i}},n.prototype.getGroupElement=function(t,e,i){var r,o,s=this.getParentSvg(t);if(e&&s){if(s&&!(r=s.getElementById(t.id+"_groupElement"))&&s!==this.nativeSvgLayer){var a=this.nativeSvgLayer;r=a.getElementById(t.id+"_groupElement"),o=a}r||(r=this.svgRenderer.createGElement("g",{id:t.id+"_groupElement"}),void 0!==i&&e.childNodes.length>i?e.insertBefore(r,e.childNodes[parseInt(i.toString(),10)]):e.appendChild(r))}return{g:r,svg:o}},n.prototype.renderElement=function(t,e,i,r,s,o,a,l,h,c,d){t instanceof Cs?(t.id=t.id?t.id:Qe(),this.renderContainer(t,e,i,r,s,o,a,l,h,c,d)):t instanceof SI?this.renderImageElement(t,e,r,s,a):t instanceof Ze?this.renderPathElement(t,e,r,s,a,h,d):t instanceof ai?this.renderTextElement(t,e,r,s,a,c):t instanceof En?this.renderNativeElement(t,e,r,s,a):t instanceof es?this.renderHTMLElement(t,e,i,r,s,a,l):this.renderRect(t,e,r,s,h)},n.prototype.drawSelectionRectangle=function(t,e,i,r,s,o){var a={width:i*o.scale,height:r*o.scale,x:.5+(t=(t+o.tx)*o.scale),y:.5+(e=(e+o.ty)*o.scale),fill:"transparent",stroke:"gray",angle:0,pivotX:.5,pivotY:.5,strokeWidth:1,dashArray:"6 3",opacity:1,visible:!0,id:s.id+"_selected_region"},l=this.getAdornerLayer();this.svgRenderer.updateSelectionRegion(l,a)},n.prototype.renderHighlighter=function(t,e,i){var r=t.actualSize.width||2,s=t.actualSize.height||2,o=t.offsetX-r*t.pivot.x,a=t.offsetY-s*t.pivot.y;this.svgRenderer.drawRectangle(e,{width:r*i.scale,height:s*i.scale,x:o=(o+i.tx)*i.scale,y:a=(a+i.ty)*i.scale,fill:"transparent",stroke:"#8CC63F",angle:t.rotateAngle,pivotX:t.pivot.x,pivotY:t.pivot.y,strokeWidth:4,dashArray:"",opacity:1,cornerRadius:0,visible:!0,id:e.id+"_highlighter",class:"e-diagram-highlighter"},this.diagramId,void 0,void 0,e)},n.prototype.renderSelectionRectangle=function(t,e,i,r){var s=t.actualSize.width||2,o=t.actualSize.height||2,a=t.offsetX-s*t.pivot.x,l=t.offsetY-o*t.pivot.y,h={width:s*i.scale,height:o*i.scale,x:a=(a+i.tx)*i.scale,y:l=(l+i.ty)*i.scale,fill:"transparent",stroke:"#00cc00",angle:t.rotateAngle,pivotX:t.pivot.x,pivotY:t.pivot.y,strokeWidth:r?2:1,dashArray:"",opacity:1,cornerRadius:0,visible:!0,id:t.id+"_highlighter",class:r?"e-diagram-first-selection-indicator e-diagram-selection-indicator":"e-diagram-selection-indicator"},c=this.getParentSvg(t,"selector");this.svgRenderer.drawRectangle(e,h,this.diagramId,void 0,void 0,c)},n.prototype.renderSelectionLine=function(t,e,i,r){var s=this.getBaseAttributes(t,i);s.data=t.absolutePath,s.id=s.id+"_highlighter";var o=t.description?t.description:t.id;this.isSvgMode||(s.x=t.flipOffset.x?t.flipOffset.x:s.x,s.y=t.flipOffset.y?t.flipOffset.y:s.y),i&&(s.x=s.x*i.scale,s.y=s.y*i.scale),s.stroke="#00cc00",s.strokeWidth=r?2:1,s.class=r?"e-diagram-first-selection-indicator e-diagram-selection-indicator":"e-diagram-selection-indicator";var a=this.getParentSvg(t,"selector");this.svgRenderer.drawPath(e,s,this.diagramId,void 0,a,o,i.scale)},n.prototype.renderStackHighlighter=function(t,e,i,r,s,o,a){var l=t.actualSize.width||2,h=t.offsetX-l*t.pivot.x,c=t.actualSize.height||2,d=t.offsetY-c*t.pivot.y;h=(h+i.tx)*i.scale;var u,f=t.bounds,p="";if(d=(d+i.ty)*i.scale,r)if(o){var v,y;u="M 0 0 L "+(2+(g=l*i.scale))+" 0 Z",v=t.actualSize.width/Number(f.width?f.width:1)*i.scale,y=t.actualSize.height/Number(f.height?f.height:1)*i.scale,p=pI(gI(Ed("M7,4 L8,4 8,7 11,7 11,8 8,8 8,11 7,11 7,8 4,8 4,7 7,7 z M7.5,0.99999994C3.9160004,1 1,3.9160004 0.99999994,7.5 1,11.084 3.9160004,14 7.5,14 11.084,14 14,11.084 14,7.5 14,3.9160004 11.084,1 7.5,0.99999994 z M7.5,0 C11.636002,0 15,3.3639984 15,7.5 15,11.636002 11.636002,15 7.5,15 3.3640003,15 0,11.636002 0,7.5 0,3.3639984 3.3640003,0 7.5,0 z")),v+g+2,y-8,!1,f.x,f.y,0,0),s.y>=t.offsetY&&(d+=c)}else{var g;a&&s.y>=t.offsetY&&(d+=c*i.scale),u="M -10 -10 L 0 0 Z M -10 10 L 0 0 Z M 0 0 L "+(g=l*i.scale)+" 0 Z M "+g+" 0 L "+(g+10)+" 10 Z L "+(g+10)+" -10 Z"}else u="M 10 -10 L 0 0 Z M -10 -10 L 0 0 Z M 0 0 L 0 "+(g=c*i.scale)+" Z M 0 "+g+" L -10 "+(g+10)+" Z L 10 "+(g+10)+" Z",s.x>=t.offsetX&&(h+=l*i.scale);this.svgRenderer.drawPath(e,{data:u+p,width:l*i.scale,height:c*i.scale,x:h,y:d,fill:"transparent",stroke:"#8CC63F",angle:t.rotateAngle,pivotX:t.pivot.x,pivotY:t.pivot.y,strokeWidth:1,dashArray:"",opacity:1,visible:!0,id:e.id+"_stack_highlighter",class:"e-diagram-highlighter"},this.diagramId)},n.prototype.drawLine=function(t,e){this.svgRenderer.drawLine(t,e)},n.prototype.drawPath=function(t,e){this.svgRenderer.drawPath(t,e,this.diagramId)},n.prototype.renderResizeHandle=function(t,e,i,r,s,o,a,l,h,c,d){var u=t.offsetX-t.actualSize.width*t.pivot.x,f=t.offsetY-t.actualSize.height*t.pivot.y,p=t.actualSize.height,g=t.actualSize.width;if(!c&&i&bt.Rotate&&zI(this.rendererActions)&&!x3(this.rendererActions))this.renderPivotLine(t,e,o,s,a),this.renderRotateThumb(t,e,o,s,a);else if(this.touchMove){var v=document.getElementById("rotateThumb");v&&v.setAttribute("visibility","hidden")}this.renderBorder(t,e,o,l,h,c);var y=t.actualSize.width*r,S=t.actualSize.height*r;!h&&zI(this.rendererActions)&&!x3(this.rendererActions)&&(t.isTextAnnotation||(y>=40&&S>=40&&(s&lr.ResizeNorthWest&&this.renderCircularHandle("resizeNorthWest",t,u,f,e,qr(s,"ResizeNorthWest"),i&bt.ResizeNorthWest,o,void 0,a,{"aria-label":"Thumb to resize the selected object on top left side direction"},void 0,"e-diagram-resize-handle e-northwest",d),s&lr.ResizeNorthEast&&this.renderCircularHandle("resizeNorthEast",t,u+g,f,e,qr(s,"ResizeNorthEast"),i&bt.ResizeNorthEast,o,void 0,a,{"aria-label":"Thumb to resize the selected object on top right side direction"},void 0,"e-diagram-resize-handle e-northeast",d),s&lr.ResizeSouthWest&&this.renderCircularHandle("resizeSouthWest",t,u,f+p,e,qr(s,"ResizeSouthWest"),i&bt.ResizeSouthWest,o,void 0,a,{"aria-label":"Thumb to resize the selected object on bottom left side direction"},void 0,"e-diagram-resize-handle e-southwest",d),s&lr.ResizeSouthEast&&this.renderCircularHandle("resizeSouthEast",t,u+g,f+p,e,qr(s,"ResizeSouthEast"),i&bt.ResizeSouthEast,o,void 0,a,{"aria-label":"Thumb to resize the selected object on bottom right side direction"},void 0,"e-diagram-resize-handle e-southeast",d)),s&lr.ResizeNorth&&this.renderCircularHandle("resizeNorth",t,u+g/2,f,e,qr(s,"ResizeNorth"),i&bt.ResizeNorth,o,void 0,a,{"aria-label":"Thumb to resize the selected object on top side direction"},void 0,"e-diagram-resize-handle e-north",d),s&lr.ResizeSouth&&this.renderCircularHandle("resizeSouth",t,u+g/2,f+p,e,qr(s,"ResizeSouth"),i&bt.ResizeSouth,o,void 0,a,{"aria-label":"Thumb to resize the selected object on bottom side direction"},void 0,"e-diagram-resize-handle e-south",d),s&lr.ResizeWest&&this.renderCircularHandle("resizeWest",t,u,f+p/2,e,qr(s,"ResizeWest"),i&bt.ResizeWest,o,void 0,a,{"aria-label":"Thumb to resize the selected object on left side direction"},void 0,"e-diagram-resize-handle e-west",d),s&lr.ResizeEast&&this.renderCircularHandle("resizeEast",t,u+g,f+p/2,e,qr(s,"ResizeEast"),i&bt.ResizeEast,o,void 0,a,{"aria-label":"Thumb to resize the selected object on right side direction"},void 0,"e-diagram-resize-handle e-east",d)))},n.prototype.renderEndPointHandle=function(t,e,i,r,s,o,a,l,h,c){var p,g,d=t.sourcePoint,u=t.targetPoint,f=t.wrapper;if(this.renderCircularHandle("connectorSourceThumb",f,d.x,d.y,e,qr(r,"ConnectorSourceThumb"),i&bt.ConnectorSource,s,o,void 0,{"aria-label":"Thumb to move the source point of the connector"},void 0,"e-diagram-endpoint-handle e-sourceend",c),this.renderCircularHandle("connectorTargetThumb",f,u.x,u.y,e,qr(r,"ConnectorTargetThumb"),i&bt.ConnectorTarget,s,a,void 0,{"aria-label":"Thumb to move the target point of the connector"},void 0,"e-diagram-endpoint-handle e-targetend",c),l)if("Straight"===t.type&&t.segments.length>0)for(p=0;p0)for(p=0;p=3&&3===t.segments.length&&(S=1,b=t.segments.length-1),S=t.segments.length>t.maxSegmentThumb+2?2:S,b=t.segments.length>t.maxSegmentThumb+2?t.segments.length-2:b,1===t.segments.length&&t.segments[0].points.length<=2&&(S=1,b=t.segments.length),p=S;p=50&&i.allowDrag),this.renderOrthogonalThumb(t+"_"+(d+1),e,(i.points[parseInt(d.toString(),10)].x+i.points[d+1].x)/2,(i.points[parseInt(d.toString(),10)].y+i.points[d+1].y)/2,r,h,l,o,a,u)}else for(d=0;d=50&&i.allowDrag),this.renderOrthogonalThumb(t+"_"+(d+1),e,(i.points[parseInt(d.toString(),10)].x+i.points[d+1].x)/2,(i.points[parseInt(d.toString(),10)].y+i.points[d+1].y)/2,r,h,l,o,a,u)},n.prototype.renderOrthogonalThumb=function(t,e,i,r,s,o,a,l,h,c){var d,g,u=0,f=document.getElementById(this.diagramId);f&&(g=f.ej2_instances[0]);var y=h.constraints&qe.InheritSegmentThumbShape?g.segmentThumbShape:h.segmentThumbShape,b=h.constraints&qe.InheritSegmentThumbSize?g.segmentThumbSize:h.segmentThumbSize;if(d="horizontal"===a?function Kie(n){return rre[""+n]}(y):i3(y),"Arrow"===y||"DoubleArrow"===y||"OpenArrow"===y)switch(c){case"Bottom":case"Right":u=180;break;default:u=0}else if("Fletch"===y||"OpenFetch"===y||"IndentedArrow"===y||"OutdentedArrow"===y)switch(c){case"Bottom":u=-90;break;case"Top":u=90;break;case"Right":u=180;break;default:u=0}var M={x:(i+l.tx)*l.scale-b/2,y:(r+l.ty)*l.scale-b/2,angle:u,fill:"#e2e2e2",stroke:"black",strokeWidth:1,dashArray:"",data:d,width:b,height:b,pivotX:.5,pivotY:.5,opacity:1,visible:o,id:t,class:"e-diagram-ortho-segment-handle"},w=np(M.data),C=new me(M.width,M.height),D=new Ze;if(M.data=D.updatePath(M.data,w,C),this.touchMove){var A=document.getElementById(t);A?this.updateSegmentPosition(A,M):this.svgRenderer.drawPath(s,M,this.diagramId)}else this.svgRenderer.drawPath(s,M,this.diagramId)},n.prototype.renderPivotLine=function(t,e,i,r,s){var o=t,l=!!(r&lr.Rotate);s&&(l=!1);var h=this.getBaseAttributes(o,i);h.fill="None",h.stroke="black",h.strokeWidth=1,h.dashArray="2,3",h.visible=l;var c=i.scale;h.x*=c,h.y*=c,h.width*=c,h.height*=c,h.id="pivotLine",h.class="e-diagram-pivot-line";var u={x:o.actualSize.width*o.pivot.x*c,y:0};h.startPoint={x:o.actualSize.width*o.pivot.x*c,y:-20},h.endPoint=u,this.svgRenderer.drawLine(e,h)},n.prototype.renderBezierLine=function(t,e,i,r,s,o){var l=this.getBaseAttributes(e,o);l.id=t,l.stroke="black",l.strokeWidth=1,l.dashArray="3,3",l.fill="None",l.class="e-diagram-bezier-control-line",l.x=0,l.y=0;var h=o.scale,g={x:(s.x+o.tx)*h,y:(s.y+o.ty)*h};l.startPoint={x:(r.x+o.tx)*h,y:(r.y+o.ty)*h},l.endPoint=g,this.svgRenderer.drawLine(i,l)},n.prototype.renderCircularHandle=function(t,e,i,r,s,o,a,l,h,c,d,u,f,p){var g=e,v={x:i,y:r};if(0!==g.rotateAngle||0!==g.parentTransform){var y=Bi();qi(y,g.rotateAngle+g.parentTransform,g.offsetX,g.offsetY),v=Ke(y,v)}var S=this.getBaseAttributes(g);if(S.stroke="black",S.strokeWidth=1,void 0!==u?(S.id="segmentEnd_"+u,S.fill="#e2e2e2"):S.fill=h?"#8CC63F":"white",S.cornerRadius=p/2,S.angle=e.rotateAngle,S.id=t,S.visible=o,S.class=f,S.width=p,S.height=p,S.x=(v.x+l.tx)*l.scale,S.y=(v.y+l.ty)*l.scale,S.x=S.x-S.width/2,S.y=S.y-S.height/2,h&&(S.class+=" e-connected"),c&&(S.visible=!1),this.touchMove){var b=document.getElementById(t);if(b)this.updateResizeHandle(b,S);else{var M=this.getParentSvg(e,"selector");this.svgRenderer.drawRectangle(s,S,this.diagramId,!0,!0,M,d,!0,a)}}else M=this.getParentSvg(e,"selector"),this.svgRenderer.drawRectangle(s,S,this.diagramId,!0,!0,M,d,!0,a)},n.prototype.updateResizeHandle=function(t,e){ti(t,{id:e.id,x:e.x.toString(),y:e.y.toString(),width:e.width.toString(),height:e.height.toString(),visibility:e.visible?"visible":"hidden",transform:"rotate("+e.angle+","+(e.x+e.width/2)+","+(e.y+e.height/2)+")",rx:e.cornerRadius||0,ry:e.cornerRadius||0,opacity:e.opacity})},n.prototype.renderBezierHandle=function(t,e,i,r,s,o,a,l,h,c,d,u,f){var v,p=document.getElementById(this.diagramId);p&&(v=p.ej2_instances[0]);var y=e,S={x:i,y:r};if(0!==y.rotateAngle||0!==y.parentTransform){var b=Bi();qi(b,y.rotateAngle+y.parentTransform,y.offsetX,y.offsetY),S=Ke(b,S)}var D=a.constraints&qe.InheritSegmentThumbSize?v.segmentThumbSize:a.segmentThumbSize,A=i3(a.constraints&qe.InheritSegmentThumbShape?v.segmentThumbShape:a.segmentThumbShape),x=this.getBaseAttributes(y);x.stroke="black",x.strokeWidth=1,void 0!==d?(x.id="segmentEnd_"+d,x.fill="#e2e2e2"):x.fill=h?"#8CC63F":"white",x.angle=e.rotateAngle,x.id=t,x.visible=o,x.class=u,x.width=D,x.height=D,x.data=A,x.x=(S.x+l.tx)*l.scale,x.y=(S.y+l.ty)*l.scale,x.x=x.x-x.width/2,x.y=x.y-x.height/2,h&&(x.class+=" e-connected"),c&&(x.visible=!1);var P=np(x.data),L=new me(x.width,x.height),O=new Ze;if(x.data=O.updatePath(x.data,P,L),this.touchMove){var N=document.getElementById(t);if(N)this.updateSegmentPosition(N,x);else{var T=this.getParentSvg(e,"selector");this.svgRenderer.drawPath(s,x,this.diagramId,!0,T)}}else T=this.getParentSvg(e,"selector"),this.svgRenderer.drawPath(s,x,this.diagramId,!0,T)},n.prototype.updateSegmentPosition=function(t,e){ti(t,{id:e.id,transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")translate("+e.x+","+e.y+")",visibility:e.visible?"visible":"hidden",opacity:e.opacity})},n.prototype.renderBorder=function(t,e,i,r,s,o){var l=this.getBaseAttributes(t,i);l.x*=i.scale,l.y*=i.scale,l.width*=i.scale,l.height*=i.scale,l.fill="transparent",l.stroke="#097F7F",l.strokeWidth=1.2,l.gradient=null,l.dashArray="6,3",l.class="e-diagram-selector",o&&(l.class+=" e-diagram-lane"),l.id="borderRect",l.id=this.rendererActions&Ga.DrawSelectorBorder?"borderRect_symbol":"borderRect",r||(l.class+=" e-disabled"),s&&(l.class+=" e-thick-border"),l.cornerRadius=0;var h=this.getParentSvg(t,"selector");this.svgRenderer.drawRectangle(e,l,this.diagramId,void 0,!0,h)},n.prototype.renderUserHandler=function(t,e,i,r,s,o){for(var l,a=t.wrapper,h=0,c=t.userHandles;h0||d.disableNodes&&t.nodes.length>0||"Drag"===s&&o)&&(l=!1);var u=document.getElementById(d.name+"_template_hiddenUserHandle");u&&(d.template=u.childNodes[0].cloneNode(!0));var f=Jx(t,d,i);if(f.x=(f.x+i.tx)*i.scale,f.y=(f.y+i.ty)*i.scale,d.visible&&(d.visible=!!(t.constraints&lr.UserHandle)),l)if(d.pathData){var p=d.pathData?d.pathData:d.content,g=this.getBaseAttributes(a);g.id=d.name+"_userhandle",g.fill=d.backgroundColor,g.stroke=d.borderColor,g.strokeWidth=d.borderWidth,g.centerX=f.x,g.centerY=f.y,g.radius=.5*d.size,g.class="e-diagram-userhandle-circle",g.angle=0,g.visible=d.visible,g.opacity=1,this.svgRenderer.drawCircle(e,g,1,{"aria-label":d.name+"user handle"});var y=[];y=gI(y=Ed(p));var S=np(p),w=pI(y,(d.size-.45*d.size)/S.width,(d.size-.45*d.size)/S.height,!0,S.x,S.y,0,0);S=np(w),this.svgRenderer.drawPath(e,C={x:f.x-S.width/2,y:f.y-S.height/2,angle:0,id:"",class:"e-diagram-userhandle-path",fill:d.pathColor,stroke:d.backgroundColor,strokeWidth:.5,dashArray:"",data:w,width:d.size-5,height:d.size-5,pivotX:0,pivotY:0,opacity:1,visible:d.visible},this.diagramId,void 0,void 0,{"aria-label":d.name+"user handle"})}else if(d.content){var D=new En(d.name,this.diagramId);D.content=d.content,D.offsetX=f.x,D.offsetY=f.y,D.id=d.name+"_shape",D.horizontalAlignment="Center",D.verticalAlignment="Center",D.visible=d.visible,D.setOffsetWithRespectToBounds(f.x,f.y,"Fraction"),D.relativeMode="Object",D.description=d.name||"User handle",D.measure(new me(d.size,d.size)),D.arrange(D.desiredSize),this.svgRenderer.drawNativeContent(D,e,d.size,d.size,this.adornerSvgLayer)}else if(d.source){var C,A=new SI;(C=this.getBaseAttributes(A,i)).width=d.size,C.height=d.size,C.x=f.x-d.size/2,C.y=f.y-d.size/2,C.sourceWidth=d.size,C.sourceHeight=d.size,C.alignment=A.imageAlign,C.source=d.source,C.scale=A.imageScale,C.visible=d.visible,C.description=d.name||"User handle",C.id=d.name+"_",this.renderer.drawImage(e,C,this.adornerSvgLayer,!1)}else{var x=new es(d.name,this.diagramId);x.offsetX=f.x,x.offsetY=f.y,x.id=d.name+"_shape",x.visible=d.visible,x.relativeMode="Object",x.template=d.template,x.measure(new me(d.size,d.size)),x.arrange(x.desiredSize),this.svgRenderer.drawHTMLContent(x,r,void 0,!0,void 0)}}},n.prototype.renderRotateThumb=function(t,e,i,r,s){new Ze;var a,l=new me;l.width=18,l.height=16;var d=!!(r&lr.Rotate);s&&(d=!1);var f=t.offsetX-t.actualSize.width*t.pivot.x+t.pivot.x*t.actualSize.width,p=t.offsetY-t.actualSize.height*t.pivot.y;if(a={x:(f=(f+i.tx)*i.scale)-.5*l.width,y:(p=(p+i.ty)*i.scale)-30-.5*l.height},0!==t.rotateAngle||0!==t.parentTransform){var g=Bi();qi(g,t.rotateAngle+t.parentTransform,(i.tx+t.offsetX)*i.scale,(i.ty+t.offsetY)*i.scale),a=Ke(g,a)}var v={x:a.x,y:a.y,angle:t.rotateAngle+t.parentTransform,fill:"#231f20",stroke:"black",strokeWidth:.5,dashArray:"",data:"M 16.856144362449648 10.238890446662904 L 18.000144362449646 3.437890446662903L 15.811144362449646 4.254890446662903 C 14.837144362449646 2.5608904466629028 13.329144362449647 1.2598904466629026 11.485144362449645 0.5588904466629026 C 9.375144362449646 - 0.24510955333709716 7.071144362449646 - 0.18010955333709716 5.010144362449646 0.7438904466629028 C 2.942144362449646 1.6678904466629028 1.365144362449646 3.341890446662903 0.558144362449646 5.452890446662903 C - 0.244855637550354 7.567890446662903 - 0.17985563755035394 9.866890446662904 0.7431443624496461 11.930890446662904 C 1.6681443624496461 13.994890446662904 3.343144362449646 15.575890446662903 5.457144362449647 16.380890446662903 C 6.426144362449647 16.7518904466629 7.450144362449647 16.9348904466629 8.470144362449647 16.9348904466629 C 9.815144362449647 16.9348904466629 11.155144362449647 16.6178904466629 12.367144362449647 15.986890446662901 L 11.351144362449647 14.024890446662901 C 9.767144362449647 14.8468904466629 7.906144362449647 14.953890446662902 6.237144362449647 14.3178904466629 C 4.677144362449647 13.7218904466629 3.444144362449647 12.5558904466629 2.758144362449647 11.028890446662901 C 2.078144362449646 9.501890446662903 2.031144362449646 7.802890446662903 2.622144362449646 6.243890446662903 C 3.216144362449646 4.6798904466629025 4.387144362449646 3.442890446662903 5.914144362449646 2.760890446662903 C 7.437144362449646 2.078890446662903 9.137144362449646 2.0298904466629026 10.700144362449645 2.6258904466629027 C 11.946144362449646 3.100890446662903 12.971144362449646 3.9538904466629026 13.686144362449646 5.049890446662903 L 11.540144362449645 5.850890446662903 L 16.856144362449648 10.238890446662904 Z",width:20,height:20,pivotX:0,pivotY:0,opacity:1,visible:d,id:"rotateThumb",class:"e-diagram-rotate-handle"};if(this.touchMove){var y=document.getElementById("rotateThumb");y?this.updateSegmentPosition(y,v):this.svgRenderer.drawPath(e,v,this.diagramId,!0,void 0,{"aria-label":"Thumb to rotate the selected object"})}else this.svgRenderer.drawPath(e,v,this.diagramId,!0,void 0,{"aria-label":"Thumb to rotate the selected object"})},n.prototype.renderPathElement=function(t,e,i,r,s,o,a){var l=this.getBaseAttributes(t,i,o);if(l.data=t.absolutePath,l.data=t.absolutePath,t.isPathPort&&a){l.x=a[t.id]?a[t.id].cx:l.x,l.y=a[t.id]?a[t.id].cy:l.y,t.bounds.x=l.x,t.bounds.y=l.y;var h=document.getElementById(this.diagramId);h&&"PortDrag"!==h.ej2_instances[0].eventHandler.currentAction&&(t.offsetX=l.x+t.width/2,t.offsetY=l.y+t.height/2)}var u=t.description?t.description:t.id;if(this.isSvgMode||(l.x=t.flipOffset.x?t.flipOffset.x:l.x,l.y=t.flipOffset.y?t.flipOffset.y:l.y),t.isExport){var f=t.absoluteBounds,p=Ed(l.data),g=this.findAndStoreArcValues(p);l.arc=g,l.data=LF(t,f,0,l)}this.renderer.drawPath(e,l,this.diagramId,void 0,r,u)},n.prototype.findAndStoreArcValues=function(t){var e=[];return t.forEach(function(i){"A"===i.command&&e.push({r1:i.r1/2,r2:i.r2/2})}),e},n.prototype.renderSvgGridlines=function(t,e,i,r,s,o){var a=document.createElementNS("http://www.w3.org/2000/svg","pattern"),l=document.createElementNS("http://www.w3.org/2000/svg","defs");l.setAttribute("id",this.diagramId+"_grid_pattern_defn"),(t.constraints&Kt.ShowHorizontalLines||t.constraints&Kt.ShowVerticalLines)&&a.setAttribute("id",this.diagramId+"_pattern");var h=0,c=0,d=0,u=0,f=1,p=!1,g="Lines"===t.gridType,v=g?t.verticalGridlines.lineIntervals:t.verticalGridlines.dotIntervals,y=g?t.horizontalGridlines.lineIntervals:t.horizontalGridlines.dotIntervals;if(r.showRulers&&r.dynamicGrid&&s&&o)d=o.updateSegmentWidth(i.scale),u=s.updateSegmentWidth(i.scale),t.horizontalGridlines.scaledIntervals=[d/s.interval],t.verticalGridlines.scaledIntervals=[u/o.interval],p=!0;else{for(var S=0;S=2)for(;e>=2;)e/=2;else if(e<=.5)for(;e<=.5;)e*=2;var i;if(t.horizontalGridlines.scaledIntervals=t.horizontalGridlines.snapIntervals,t.verticalGridlines.scaledIntervals=t.verticalGridlines.snapIntervals,1!==e){var r=t.horizontalGridlines;for(r.scaledIntervals=[],i=0;ithis.groupElement.actualSize.height&&("Clip"===t.style.textOverflow||"Ellipsis"===t.style.textOverflow)&&(a.y=a.y+(a.height-this.groupElement.actualSize.height)/2),this.renderer.drawRectangle(e,a,this.diagramId,void 0,void 0,r),this.renderer.drawText(e,a,r,l,this.diagramId,t.isExport&&Math.min(t.exportScaleValue.x||t.exportScaleValue.y),this.groupElement),this.isSvgMode&&(t.doWrap=!1)},n.prototype.renderNativeElement=function(t,e,i,r,s){var o,a,l=this.getParentSvg(t,void 0,e)||r,h=this.getParentElement(t,e,l).g||e,c=this.getBaseAttributes(t,i);switch(c.fill="transparent",c.cornerRadius=t.cornerRadius,c.stroke="transparent",this.renderer.drawRectangle(e,c,this.diagramId,void 0,void 0,r),t.scale){case"None":o=t.contentSize.width,a=t.contentSize.height;break;case"Stretch":o=t.actualSize.width,a=t.actualSize.height;break;case"Meet":o=a=t.actualSize.width<=t.actualSize.height?t.actualSize.width:t.actualSize.height;break;case"Slice":o=a=t.actualSize.width>=t.actualSize.height?t.actualSize.width:t.actualSize.height}this.svgRenderer&&this.svgRenderer.drawNativeContent(t,h,a,o,l)},n.prototype.renderHTMLElement=function(t,e,i,r,s,o,a){var l=this.getBaseAttributes(t,r);l.fill="transparent",l.cornerRadius=t.cornerRadius,l.stroke="transparent",this.renderer.drawRectangle(e,l,this.diagramId,void 0,void 0,s),this.svgRenderer&&this.svgRenderer.drawHTMLContent(t,i.children[0],r,function ose(n){var t=n.parentElement;do{if(cm(t,"e-diagram"))return!0;t=t.parentElement}while(t);return!1}(i),a)},n.prototype.renderImageElement=function(t,e,i,r,s){var o=this.getBaseAttributes(t,i);o.cornerRadius=0,this.renderer.drawRectangle(e,o,this.diagramId,void 0,void 0,r);var a,l,h,c,g,d=t.contentSize.width,u=t.contentSize.height,f=o.width/d,p=o.height/u;if("Stretch"===t.stretch)a=d*(g=Math.min(f,p)),l=u*g;else switch(t.stretch){case"Meet":a=d*(g=Math.min(f,p)),l=u*g,o.x+=Math.abs(o.width-a)/2,o.y+=Math.abs(o.height-l)/2;break;case"Slice":g=Math.max(f,p),h=o.width/(a=d*g)*d,c=o.height/(l=u*g)*u;break;case"None":a=d,l=u}o.width=a,o.height=l,o.sourceWidth=h,o.sourceHeight=c,o.source=t.source,o.alignment=t.imageAlign,o.scale=t.imageScale,o.description=t.description?t.description:t.id,this.renderer.drawImage(e,o,r,s)},n.prototype.renderContainer=function(t,e,i,r,s,o,a,l,h,c,d){var g,u={svg:s,g:e},f=document.getElementById(this.diagramId);if(f&&(g=f.ej2_instances[0]),this.diagramId&&(s=this.getParentSvg(t)||s,this.isSvgMode)){var v=this.getParentElement(t,e,s,l).g||e;s=this.getParentSvg(this.hasNativeParent(t.children))||s;var y=this.getParentElement(this.hasNativeParent(t.children),v,s,l);u.svg=y.svg||s,u.g=y.g||v,o&&s&&(s.getElementById(u.g.id)||e.appendChild(u.g)),e=u.g}if(this.renderRect(t,e,r,s),this.groupElement=t,t.hasChildren()){for(var b,S=void 0,M=0,w=t.children;M0&&(D=g.selectedItems.nodes[0]);var L,A=void 0,x=void 0,P=!1;if(g&&g.selectedItems&&(L=g.getObject(t.id)),"None"!==t.flip&&(D=L),"None"===t.flip&&(D=L),D&&D.flipMode&&(P=!0),!(t.elementActions&Xr.ElementIsGroup)&&g instanceof Fl&&g.nameTable[t.id]&&"connectors"!==g.nameTable[t.id].propName&&P&&D){if(A=t.children&&t.children[0]instanceof En?document.getElementById(D.id+"_content_inner_native_element"):document.getElementById(D.id+"_content_groupElement"),!(t.children[0]instanceof En)&&"Text"!==D.shape.type&&"None"!==D.flipMode&&"Label"!==D.flipMode&&"All"!==D.flipMode&&"PortAndLabel"!==D.flipMode&&"LabelText"!==D.flipMode&&"PortAndLabelText"!==D.flipMode&&"LabelAndLabelText"!==D.flipMode||t.children[0]instanceof En&&"Port"===D.flipMode)return void this.renderFlipElement(t,A,D.flip);if((t.children[0]instanceof En&&("All"===D.flipMode||"Label"===D.flipMode)||"Label"===D.flipMode||"PortAndLabel"===D.flipMode||"LabelText"===D.flipMode||"PortAndLabelText"===D.flipMode||"LabelAndLabelText"===D.flipMode||"Image"===D.shape.type&&"Label"===D.flipMode)&&this.renderFlipElement(t,A,t.flip),"None"!==t.flip&&"None"===D.flipMode)this.renderFlipElement(t,A,t.flip);else if("None"!==t.flip&&("Label"===D.flipMode||"PortAndLabel"===D.flipMode||"LabelText"===D.flipMode||"PortAndLabelText"===D.flipMode||"LabelAndLabelText"===D.flipMode)||t.children[0]instanceof En&&"None"!==t.flip&&D&&("None"===D.flipMode||"All"===D.flipMode)){for(var O=0;O0){var i=t[0];if(i instanceof En)return i;i.children&&i.children.length&&this.hasNativeParent(i.children,e++||0)}},n.prototype.renderRect=function(t,e,i,r,s){var o=this.getBaseAttributes(t,i,s);o.cornerRadius=t.cornerRadius||0,t.isExport&&(o.cornerRadius*=t.exportScaleValue.x),this.renderer.drawRectangle(e,o,this.diagramId,t.isExport,void 0,r,t.description?t.description:t.id)},n.prototype.drawRect=function(t,e){e.cornerRadius=0,this.svgRenderer.drawRectangle(t,e,this.diagramId)},n.prototype.getBaseAttributes=function(t,e,i){var r={width:t.actualSize.width,height:t.actualSize.height,x:t.offsetX-t.actualSize.width*t.pivot.x,y:t.offsetY-t.actualSize.height*t.pivot.y,fill:t.style.fill,stroke:t.style.strokeColor,angle:t.rotateAngle+t.parentTransform,pivotX:t.pivot.x,pivotY:t.pivot.y,strokeWidth:t.style.strokeWidth,dashArray:t.style.strokeDashArray||"",opacity:t.style.opacity,shadow:t.shadow,gradient:t.style.gradient,visible:t.visible,id:t.id,description:t.description,canApplyStyle:t.canApplyStyle,shapeType:t.shapeType};return"Page"===t.rotationReference&&(r.angle=t.rotateAngle),i&&(r.x=r.x-.5,r.y=r.y-.5),t.isExport&&(r.width*=t.exportScaleValue.x,r.height*=t.exportScaleValue.y,r.x*=t.exportScaleValue.x,r.y*=t.exportScaleValue.y,r.strokeWidth*=t.exportScaleValue.x),t.flip&&(r.flip=t.flip),e&&(r.x+=e.tx,r.y+=e.ty),r},n.renderSvgBackGroundImage=function(t,e,i,r,s,o){if(t.source){var l=vT(e.id).getElementById(e.id+"_image");if(!l){var h=function goe(n){return xt(n).getElementsByClassName("e-background-image-layer")[0]}(e.id);(l=document.createElementNS("http://www.w3.org/2000/svg","image")).setAttribute("id",e.id+"_image"),h.appendChild(l)}var c=new Image;c.src=t.source,l.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",c.src.toString());var d="None"!==t.scale?t.scale:"",u=t.align,f=u.charAt(0).toLowerCase()+u.slice(1);d&&(f+=" "+d.charAt(0).toLowerCase()+d.slice(1)),ti(l,{id:e.id+"_image",x:i,y:r,width:s,height:o,preserveAspectRatio:f})}},n.prototype.transformLayers=function(t,e){var i=t.tx*t.scale,r=t.ty*t.scale,s="domTable";if(i!==this.transform.x||r!==this.transform.y||0===i||0===r){e&&(window[""+s][this.diagramId+"_diagramLayer"]||(window[""+s][this.diagramId+"_diagramLayer"]=this.diagramSvgLayer.getElementById(this.diagramId+"_diagramLayer")),window[""+s][this.diagramId+"_diagramLayer"].setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+"),scale("+t.scale+")"));var a=function voe(n){var t="domTable",e=null;return window[t][n+"_gridline"]?e=window[t][n+"_gridline"]:(e=Fd(n).getElementById(n+"_gridline"),window[t][n+"_gridline"]=e),e}(this.diagramId);return a.setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+")"),window[""+s][this.diagramId+"_diagramPorts"]||(window[""+s][this.diagramId+"_diagramPorts"]=this.iconSvgLayer.getElementById(this.diagramId+"_diagramPorts")),window[""+s][this.diagramId+"_diagramPorts"].setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+"),scale("+t.scale+")"),window[""+s][this.diagramId+"_diagramExpander"]||(window[""+s][this.diagramId+"_diagramExpander"]=this.iconSvgLayer.getElementById(this.diagramId+"_diagramExpander")),window[""+s][this.diagramId+"_diagramExpander"].setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+"),scale("+t.scale+")"),window[""+s][this.diagramId+"_nativeLayer"]||(window[""+s][this.diagramId+"_nativeLayer"]=this.nativeSvgLayer.getElementById(this.diagramId+"_nativeLayer")),window[""+s][this.diagramId+"_nativeLayer"].setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+"),scale("+t.scale+")"),Io(this.diagramId).children[0].style.transform="translate("+t.tx*t.scale+"px,"+t.ty*t.scale+"px)scale("+t.scale+")",this.transform={x:t.tx*t.scale,y:t.ty*t.scale},!0}return!1},n.prototype.updateNode=function(t,e,i,r,s,o,a){this.renderElement(t,e,i,r,this.getParentSvg(t),void 0,void 0,s,null,o,a)},n}(),Kne=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),qI=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},nF=function(n){function t(e,i){var r=n.call(this,e,i)||this;return r.mode="Canvas",r.id="overview",r.actionName="",r.startPoint=null,r.currentPoint=null,r.prevPoint=null,r.scale=null,r.inAction=!1,r.viewPortRatio=1,r.horizontalOffset=0,r.verticalOffset=0,r.model={},r.event=!0,r.overviewid=88123,r.model={width:r.width,height:r.height},r}return Kne(t,n),t.prototype.onPropertyChanged=function(e,i){for(var r=0,s=Object.keys(e);r0||e.toString().indexOf("%")>0?e.toString():e.toString()+"px"},t.prototype.renderCanvas=function(e){var i=document.getElementById(this.element.id+"_canvas");i||(i=Tt("div",{}),this.element.appendChild(i)),Ho(i,{id:this.element.id+"_canvas",class:"drawing",style:"position:relative; height:"+this.getSizeValue(this.model.height)+"; width:"+this.getSizeValue(this.model.width)+";style:-ms-touch-action: none;touch-action: none;"}),this.element.setAttribute("tabindex",String(-1)),this.element.style.overflow="hidden",this.element.style.height=String(this.model.height),this.element.style.width=String(this.model.width),this.canvas=i},t.prototype.setParent=function(e){var i=document.getElementById(e);if(this.parent){var s=this.parent;this.parent=null,s.setOverview(null,this.element.id),this.removeDocument(this)}this.parent=this.getDiagram(i,"ej2_instances"),this.parent&&this.parent.setOverview(this)},t.prototype.getDiagram=function(e,i){for(var r,s=e[""+i].length,o=0;o0?f:Math.floor(window.innerWidth)}if(0===h){var p=Math.floor(window.innerHeight-u-Math.floor(c.top));h=p>0?p:Math.floor(window.innerHeight)}l>0&&(s.setAttribute("width",String(l)),this.model.height=h),h>0&&(s.setAttribute("height",String(h)),this.model.width=l),e.diagramLayerDiv||(e.diagramLayerDiv=Tt("div",{}),e.diagramLayer=bo.createCanvas(this.element.id+"_diagramLayer",this.model.width,this.model.height),e.diagramLayer.setAttribute("style","position:absolute; left:0px; top:0px "),e.diagramLayerDiv.appendChild(e.diagramLayer),e.canvas.appendChild(e.diagramLayerDiv)),Ho(e.diagramLayerDiv,{id:this.element.id+"_diagramLayer_div",style:"width:"+this.model.width+"px; height:"+this.model.height+"px;position:absolute;top:0px;left:0px"}),this.renderHtmlLayer(e.canvas),this.renderNativeLayer(e.canvas,e),this.addOverviewRectPanel(e)},t.prototype.removeDocument=function(e){var i=document.getElementById(this.canvas.id+"_svg");this.canvas.removeChild(i);var r=document.getElementById(this.element.id+"_htmlLayer");this.canvas.removeChild(r);var s=document.getElementById(this.element.id+"_diagramLayer_div");this.canvas.removeChild(s),e.diagramLayerDiv=null,e.diagramLayer=null,window.domTable[this.id+"html_layer"]=null},t.prototype.renderHtmlLayer=function(e){var i=Tt("div",{id:this.element.id+"_htmlLayer",class:"e-html-layer",style:"pointer-events:none;position:absolute;top:0px;left:0px;"}),s=Tt("div",{id:this.element.id+"_htmlLayer_div",style:"position:absolute;top:0px;left:0px;"});return i.appendChild(s),e.appendChild(i),i},t.prototype.renderNativeLayer=function(e,i){if(!document.getElementById(this.element.id+"_nativeLayer_svg")){var r=this.parent.createSvg(this.element.id+"_nativeLayer_svg",this.model.width,this.model.height),s=Fi("g",{id:this.element.id+"_nativeLayer"});r.appendChild(s),i.diagramLayerDiv.appendChild(r),ti(r,{class:"e-native-layer"})}},t.prototype.addOverviewRectPanel=function(e){var i=document.getElementById(this.canvas.id+"_overviewsvg");i&&i.parentNode.removeChild(i),i=Fi("svg",{id:this.canvas.id+"_overviewsvg",class:"overviewsvg",version:"1.1",style:"position:absolute;left:0px;top:0px; aria-label:Specifies overview",width:this.model.width,height:this.model.height}),e.canvas.appendChild(i);var s=Fi("g",{id:this.element.id+"_overviewlayer",style:"pointer-events:none"});i.appendChild(s);var o=Fi("rect",{fill:"transparent",width:"100%",height:"100%",class:"overviewbackrect",id:this.canvas.id+"overviewbackrect"});o.setAttribute("style"," pointer-events: none; "),s.appendChild(o);var a=Fi("g",{id:this.canvas.id+"overviewhandle",style:"pointer-events:all"});s.appendChild(a);var l=Fi("rect",{id:this.canvas.id+"overviewrect",fill:"transparent"});a.appendChild(l),this.renderOverviewCorner("left",a),this.renderOverviewCorner("right",a),this.renderOverviewCorner("top",a),this.renderOverviewCorner("bottom",a),this.renderOverviewCorner("topleft",a),this.renderOverviewCorner("topright",a),this.renderOverviewCorner("bottomleft",a),this.renderOverviewCorner("bottomright",a)},t.prototype.renderOverviewCorner=function(e,i){var s,o=Fi(s="top"===e||"bottom"===e||"right"===e||"left"===e?"rect":"circle",{id:this.canvas.id+"visible"+e,class:"overview-resizer"});i.appendChild(o);var a=Fi(s,{id:this.canvas.id+e,class:"overviewresizer",fill:"transparent"});i.appendChild(a)},t.prototype.updateOverviewRectangle=function(){var e=this.currentPoint.x-this.prevPoint.x,i=this.currentPoint.y-this.prevPoint.y,r=new me;r.width=0,r.height=0;var s=0,o=0;switch(this.resizeDirection){case"left":r.width-=e,r.height-=e/this.viewPortRatio,s=e,o=e/this.viewPortRatio,o/=2;break;case"right":r.width+=e,r.height+=e/this.viewPortRatio,o=e/this.viewPortRatio,o/=-2;break;case"top":r.height-=i,r.width-=i*this.viewPortRatio,o=i,s=i*this.viewPortRatio,s/=2;break;case"bottom":r.height+=i,r.width+=i*this.viewPortRatio,s=i*this.viewPortRatio,s/=-2;break;case"topleft":Math.abs(i)>Math.abs(e)?e=i*this.viewPortRatio:i=e/this.viewPortRatio,r.width-=e,r.height-=i,s=e,o=i;break;case"topright":Math.abs(i)>Math.abs(e)?e=-i*this.viewPortRatio:i=-e/this.viewPortRatio,o=i,r.width+=e,r.height-=i;break;case"bottomleft":Math.abs(i)>Math.abs(e)?e=-i*this.viewPortRatio:i=-e/this.viewPortRatio,s=e,r.width-=e,r.height+=i;break;case"bottomright":Math.abs(i)>Math.abs(e)?e=i*this.viewPortRatio:i=e/this.viewPortRatio,r.width+=e,r.height+=i}this.updateHelper(s,o,r,void 0,void 0)},t.prototype.updateHelper=function(e,i,r,s,o){var a,l,h,u,f,d=this.element.getElementsByTagName("svg")[2].getElementById("helper");r?(a=(h=d.getBBox()).x+e,l=h.y+i,s=h.width+r.width,o=h.height+r.height):(u=this.currentPoint.x>this.startPoint.x?this.currentPoint.x-this.prevPoint.x:this.prevPoint.x-this.currentPoint.x,f=this.currentPoint.y>this.startPoint.y?this.currentPoint.y-this.prevPoint.y:this.prevPoint.y-this.currentPoint.y,Math.abs(f)>Math.abs(u)?u=this.viewPortRatio*f:f=u/this.viewPortRatio,h=d.getBBox(),a=this.startPoint.x>this.currentPoint.x?h.x-u:h.x,l=this.startPoint.y>this.currentPoint.y?h.y-f:h.y,s=h.width+u,o=h.height+f),ti(this.helper,{id:this.helper.id,x:a,y:l,width:Math.max(0,s),height:Math.max(0,o)})},t.prototype.updateOverviewrect=function(e,i,r,s){Ho(document.getElementById(this.canvas.id+"overviewrect"),{x:e,y:i,width:Math.max(1,r),height:Math.max(1,s)}),this.updateOverviewCorner("top",e+8,i+1,Math.max(0,r-16),2),this.updateOverviewCorner("bottom",e+8,i+s+3,Math.max(0,r-16),2),this.updateOverviewCorner("left",e-2,i+11,2,Math.max(0,s-16)),this.updateOverviewCorner("right",e+r,i+11,2,Math.max(0,s-16)),this.updateOverviewCorner("topleft",e,i+3,5,5),this.updateOverviewCorner("topright",e+r,i+3,5,5),this.updateOverviewCorner("bottomleft",e,i+s+3,5,5),this.updateOverviewCorner("bottomright",e+r,i+s+3,5,5)},t.prototype.updateOverviewCorner=function(e,i,r,s,o){var a,l;"top"===e||"bottom"===e||"right"===e||"left"===e?(a={x:i,y:r,width:s,height:o,fill:"#ED1C24"},l={x:i-2,y:r-2,width:2===s?4:s,height:2===o?4:o}):(a={cx:i,cy:r,r:4,fill:"#ED1C24"},l={cx:i,cy:r,r:6,fill:"transparent"}),Ho(document.getElementById(this.canvas.id+"visible"+e),a),Ho(document.getElementById(this.canvas.id+e),l)},t.prototype.translateOverviewRectangle=function(){Number(this.model.width),Number(this.model.height);var r=this.currentPoint.x-this.prevPoint.x,s=this.currentPoint.y-this.prevPoint.y,l=this.element.getElementsByClassName("overviewsvg")[0].getElementById(this.canvas.id+"overviewrect").getBBox(),h=l.x+r,c=l.y+s,d=l.width,u=l.height;this.updateOverviewrect(h,c,d,u),this.updateParentView(this.parent.scroller.currentZoom,h,c,d,u,null)},t.prototype.renderOverviewRect=function(e,i,r,s){var o=Number(this.model.width),a=Number(this.model.height),c=Math.max(this.parent.scroller.viewPortWidth/(r/o*this.contentWidth),this.parent.scroller.viewPortHeight/(s/a*this.contentHeight));if(c>=.25&&c<=30){this.updateParentView(c,e,i,r,s,{x:0,y:0});var u=this.scrollOverviewRect(this.parent.scroller.horizontalOffset,this.parent.scroller.verticalOffset,this.parent.scroller.currentZoom,!0);if(this.helper){var p=this.element.getElementsByTagName("rect")[10].getBBox();u.x=p.x,u.y=p.y}"pan"===this.actionName?this.updateOverviewrect(-u.x,-u.y,u.width,u.height):this.updateOverviewrect(u.x,u.y,u.width,u.height)}},t.prototype.scrollOverviewRect=function(e,i,r,s){if(!this.actionName||s){var o=Number(this.model.width),a=Number(this.model.height),l=Math.min(this.contentWidth/o,this.contentHeight/a),h=new Ne,c=h.x=e/r/l,d=h.y=i/r/l,u=0;this.parent.rulerSettings.showRulers&&(u=25);var f=document.getElementById(this.parent.element.id+"content"),p=0,g=0;f&&(p=f.offsetWidth-f.clientWidth,g=f.offsetHeight-f.clientHeight);var v=h.width=(this.parent.scroller.viewPortWidth-u-p)/r/l,y=h.height=(this.parent.scroller.viewPortHeight-u-g)/r/l;if(s){var S=new Ne;return S.x=c,S.y=d,S.width=v,S.height=y,S}this.updateOverviewrect(-c,-d,v,y)}return null},t.prototype.updateParentView=function(e,i,r,s,o,a){var p,g,l=Number(this.model.width),h=Number(this.model.height),u=i*(this.contentWidth/l)*e,f=r*(this.contentHeight/h)*e;this.parent.scroller.getPageBounds(),(1!==e||"pan"===this.actionName)&&(p=-u-this.parent.scroller.horizontalOffset,g=-f-this.parent.scroller.verticalOffset),this.parent.setBlazorDiagramProps(!0),this.parent.realActions|=$i.OverViewAction,"scale"===this.actionName||"draw"===this.actionName?this.parent.scroller.zoom(e/this.parent.scroller.currentZoom,p,g,a):ce()?this.parent.scroller.zoom(1,p,g,a):this.parent.pan(p,g,a,!0)},t.prototype.updateHtmlLayer=function(e){var i=Io(e.element.id),r=this.parent.scroller.getPageBounds(!0),o=r.height,a=Math.max(r.width,this.parent.scroller.viewPortWidth),l=Math.max(o,this.parent.scroller.viewPortHeight/this.parent.scroller.currentZoom),h=Math.min(Number(this.model.width)/a,Number(this.model.height)/l);i.style.transform="scale("+h+") translate("+this.parent.scroller.transform.tx+"px,"+this.parent.scroller.transform.ty+"px)"},t.prototype.updateView=function(e){var i=this.parent.scroller.getPageBounds(),r=i.width,s=i.height,o=Number(this.model.width),a=Number(this.model.height),l=Math.max(r,this.parent.scroller.viewPortWidth),h=Math.max(s,this.parent.scroller.viewPortHeight);this.contentWidth=l=Math.max(l,o/a*h),this.contentHeight=h=Math.max(h,a/o*l);var c=Math.min(o/l,a/h),d=document.getElementById(this.element.id+"_htmlLayer");d.style.webkitTransform="scale("+c+") translate("+-i.x+"px,"+-i.y+"px)",d.style.transform="scale("+c+") translate("+-i.x+"px,"+-i.y+"px)",document.getElementById(this.element.id+"_overviewlayer").setAttribute("transform","translate("+-i.x*c+","+-i.y*c+")"),this.horizontalOffset=i.x*c,this.verticalOffset=i.y*c;var f=document.getElementById(this.element.id+"_diagramLayer"),p=kF(this.element.id),g=f.getContext("2d"),v=Number(this.model.width)/this.contentWidth,y=Number(this.model.height)/this.contentHeight;v=Math.min(v,y);var S=this.parent.scroller.transform;p.setAttribute("transform","translate("+S.tx*v+","+S.ty*y+"),scale("+v+")"),g.setTransform(v,0,0,v,0,0),g.fillStyle="red",this.scrollOverviewRect(this.parent.scroller.horizontalOffset,this.parent.scroller.verticalOffset,this.parent.scroller.currentZoom)},t.prototype.scrolled=function(e){if(this.event){var i=this.scrollOverviewRect(this.parent.scroller.horizontalOffset,this.parent.scroller.verticalOffset,this.parent.scroller.currentZoom,!0);this.updateOverviewrect(-i.x,-i.y,i.width,i.height),this.updateView(this)}},t.prototype.updateCursor=function(e){if(cm(e.target,"overviewresizer"))switch(e.target.id){case this.canvas.id+"left":this.canvas.style.cursor="w-resize";break;case this.canvas.id+"right":this.canvas.style.cursor="e-resize";break;case this.canvas.id+"top":this.canvas.style.cursor="n-resize";break;case this.canvas.id+"bottom":this.canvas.style.cursor="s-resize";break;case this.canvas.id+"topleft":this.canvas.style.cursor="nw-resize";break;case this.canvas.id+"topright":this.canvas.style.cursor="ne-resize";break;case this.canvas.id+"bottomleft":this.canvas.style.cursor="sw-resize";break;case this.canvas.id+"bottomright":this.canvas.style.cursor="se-resize"}else this.canvas.style.cursor="default"},t.prototype.mouseMove=function(e){if(this.event=!1,this.updateCursor(e),this.currentPoint=this.mousePosition(e),this.actionName)switch(this.actionName){case"draw":!this.inAction&&(this.startPoint.x!==this.currentPoint.x||this.startPoint.y!==this.currentPoint.y)&&(this.initHelper(),this.inAction=!0),this.inAction&&this.updateHelper();break;case"scale":this.inAction||(this.initHelper(),this.inAction=!0),this.updateOverviewRectangle();break;case"pan":(this.startPoint.x!==this.currentPoint.x||this.startPoint.y===this.currentPoint.y||this.inAction)&&(this.inAction=!0,this.translateOverviewRectangle())}this.prevPoint=this.currentPoint},t.prototype.documentMouseUp=function(e){this.inAction=!1,this.actionName="",this.helper&&(this.helper.parentNode.removeChild(this.helper),this.helper=null),this.event=!0,document.getElementById(this.canvas.id+"overviewhandle").style.pointerEvents="all"},t.prototype.windowResize=function(e){var i=this;return this.resizeTo&&clearTimeout(this.resizeTo),this.resizeTo=setTimeout(function(){var s=document.getElementById(i.element.id).getBoundingClientRect();i.model.width=s.width>0?s.width:i.model.width,i.model.height=s.height>0?s.height:i.model.height,i.renderCanvas(),i.setParent(i.sourceID)},10),!1},t.prototype.mouseDown=function(e){if(e.target.id===this.canvas.id+"_overviewsvg"&&(this.actionName="draw"),e.target.id===this.canvas.id+"overviewrect"&&(this.actionName="pan"),cm(e.target,"overviewresizer"))switch(this.actionName="scale",e.target.id){case this.canvas.id+"left":this.resizeDirection="left";break;case this.canvas.id+"right":this.resizeDirection="right";break;case this.canvas.id+"top":this.resizeDirection="top";break;case this.canvas.id+"bottom":this.resizeDirection="bottom";break;case this.canvas.id+"topleft":this.resizeDirection="topleft";break;case this.canvas.id+"topright":this.resizeDirection="topright";break;case this.canvas.id+"bottomleft":this.resizeDirection="bottomleft";break;case this.canvas.id+"bottomright":this.resizeDirection="bottomright"}this.startPoint=this.prevPoint=this.mousePosition(e),this.viewPortRatio=this.parent.scroller.viewPortWidth/this.parent.scroller.viewPortHeight,document.getElementById(this.canvas.id+"overviewhandle").style.pointerEvents="none"},t.prototype.mouseUp=function(e){if(this.currentPoint=this.mousePosition(e),this.actionName)if(this.startPoint.x!==this.currentPoint.x||this.startPoint.y!==this.currentPoint.y){if("pan"!==this.actionName&&this.helper){var i=this.element.getElementsByTagName("rect")[10].getBBox();this.resizeDirection=this.resizeDirection||"",this.renderOverviewRect(i.x,i.y,o=i.width,a=i.height)}}else if(e.target.id===this.canvas.id+"_overviewsvg"||"helper"===e.target.id){var o=(i=this.element.getElementsByTagName("svg")[2].getElementById(this.canvas.id+"overviewrect").getBBox()).width,a=i.height;this.inAction=!0,this.actionName="pan",this.renderOverviewRect(this.currentPoint.x-o/2,this.currentPoint.y-a/2,o,a),this.inAction=!1}this.helper&&(this.helper.parentNode.removeChild(this.helper),this.helper=null),this.actionName="",this.startPoint=null,this.currentPoint=null,this.prevPoint=null,this.helper=null,this.viewPortRatio=1,this.resizeDirection="",this.inAction=!1,this.event=!0,document.getElementById(this.canvas.id+"overviewhandle").style.pointerEvents="all"},t.prototype.initHelper=function(){var e=this.element.getElementsByTagName("svg")[2],i=this.startPoint.x,r=this.startPoint.y,s=1,o=1;if("scale"===this.actionName){var l=e.getElementById(this.canvas.id+"overviewrect").getBBox();i=l.x,r=l.y,s=l.width,o=l.height}var h=Fi("rect",{id:"helper",x:i,y:r,width:s,height:o,fill:"transparent",stroke:"gray","stroke-dasharray":"2 2","shape-rendering":"crispEdges"});e.getElementById(this.element.id+"_overviewlayer").appendChild(h),this.helper=h},t.prototype.mousePosition=function(e){var i,r,s;-1!==e.type.indexOf("touch")?(r=(i=e).changedTouches[0].clientX-this.element.offsetLeft,s=i.changedTouches[0].clientY-this.element.offsetTop):(r=e.clientX,s=e.clientY);var l=this.element.getBoundingClientRect();return{x:(r-=l.left)+this.horizontalOffset,y:(s-=l.top)+this.verticalOffset}},t.prototype.destroy=function(){if(this.unWireEvents(),this.notify("destroy",{}),n.prototype.destroy.call(this),document.getElementById(this.element.id)){this.element.classList.remove("e-overview");var e=document.getElementById(this.element.id+"_canvas");e&&this.element.removeChild(e)}this.parent.views.splice(this.parent.views.indexOf(this.element.id),1),this.diagramLayerDiv=null,this.canvas=null,this.parent=null},t.prototype.getModuleName=function(){return"Overview"},qI([I("100%")],t.prototype,"width",void 0),qI([I("100%")],t.prototype,"height",void 0),qI([I("")],t.prototype,"sourceID",void 0),qI([H()],t.prototype,"created",void 0),t}(Ii);function tse(n,t){for(var e=0;eR.findLength(e,n)?e:t;var o=R.findAngle(t,e),a=R.findAngle(i,n),l=R.findLength(i,n),h=a+2*(o-a);return{x:i.x+l*Math.cos(h*Math.PI/180),y:i.y+l*Math.sin(h*Math.PI/180)}}function Zf(n,t,e){if(n&&n.children&&n.children.length>0)for(var r=void 0,s=0;s0&&"annotations"!==r&&"ports"!==r)if(n[""+l].length>0)for(var h=0;h<=n[""+l].length;h++)Ro(n[""+l],t?t[""+l]:void 0,e[""+l],"annotations"===l||"ports"===l?n:void 0,l);else Ro(n[""+l],t?t[""+l]:void 0,e[""+l],"annotations"===l||"ports"===l?n:void 0,l);else if(s instanceof Object&&t&&"annotations"!==r&&"ports"!==r)Ro(n[""+l],t[""+l],e[""+l]);else if("annotations"!==r&&"ports"!==r&&t&&!t[""+l]||!t&&n&&(n[""+l]||void 0!==n[""+l]))n[""+l]=e[""+l];else{var c=void 0;("annotations"===r||"ports"===r)&&("annotations"===r?(n[""+l]&&Ro(n[""+l],t[""+l],e[""+l]),n[""+l]||(ps(i)===de?(c=new Or(i,"annotations",e[""+l]),i.annotations.push(c)):(c=new Kn(i,"annotations",e[""+l]),i.annotations.push(c)))):n[""+l]?Ro(n[""+l],t[""+l],e[""+l]):(c=new Es(i,"ports",e[""+l]),i.ports.push(c)))}}}function lse(n,t){for(var e="Bezier"===n.type?function sse(n){var t=[];if("Bezier"===n.type)for(var e=0,i=0;i0||n.ports.length>0){var f=n.wrapper.children;for(i=3;i0)return{enabled:!1,intersectPt:e};var l=o/s,h=a/s;return l>=0&&l<=1&&h>=0&&h<=1?(e.x=i.x1+l*(i.x2-i.x1),e.y=i.y1+l*(i.y2-i.y1),{enabled:!0,intersectPt:e}):{enabled:!1,intersectPt:e}}function ZI(n,t,e,i){var a=Kv(lF(n.x,n.y,t.x,t.y),lF(e.x,e.y,i.x,i.y));return a.enabled?a.intersectPt:{x:0,y:0}}function lF(n,t,e,i){return{x1:Number(n)||0,y1:Number(t)||0,x2:Number(e)||0,y2:Number(i)||0}}function hF(n,t,e){var i=[],s={x:t.topRight.x+(e=e||0),y:t.topRight.y},o={x:t.bottomRight.x,y:t.bottomRight.y-e},a={x:t.bottomLeft.x,y:t.bottomLeft.y+e};return i.push({x:t.topLeft.x-e,y:t.topLeft.y}),i.push(s),i.push(o),i.push(a),i}function zc(n,t,e,i,r,s){var o={},a=e.scroller.transform.scale,h=e.scroller.verticalOffset;return o.x=(i?n.x:t.x)*a+e.scroller.horizontalOffset-r,o.y=(i?n.y:t.y)*a+h-s,o}function cF(n,t){var e=new Ze;return e.data=n.pathData,e.height=n.height>10?n.height-(n.padding.bottom+n.padding.top):n.height,e.width=n.width>10?n.width-(n.padding.left+n.padding.right):n.width,e.visible=n.visibility,e.id=t.id+"_shape",e.inversedAlignment=!1,e.horizontalAlignment="Center",e.verticalAlignment="Center",e.style={fill:n.iconStrokeColor,strokeColor:n.iconStrokeColor,strokeWidth:n.iconStrokeWidth},e.setOffsetWithRespectToBounds(.5,.5,"Fraction"),e.relativeMode="Object",e.description=t.description||"",e}function Gx(n,t,e){var i=Xx(n,t),r=R.findAngle(n[i.index],n[i.index+1]),s=function gse(n){var t;t=n instanceof EI?0:void 0===n.content?10:0;var e=0;switch(n.alignment){case"Center":e=0;break;case"Before":e=-(0+t);break;case"After":e=0+t}return e}(t),o=R.transform(i.point,r+45,s);return i.point=o,i.angle=r,i}function Xx(n,t){for(var r,s,a,l,e=0,i=t.offset,o=[],h=0;h=c)return s=R.findAngle(n[parseInt(d.toString(),10)],n[d+1]),{point:r=R.transform(n[parseInt(d.toString(),10)],s,c-(a||0)),index:l=d};a=o[parseInt(d.toString(),10)]}return{point:r,index:l}}function dF(n,t,e){t%=360;var a,l,s=225;switch(n.alignment){case"Before":t>=45&&t<=135?(l="right",a=.5===n.offset?"center":"top"):t>=s&&t<=315?(l="left",a=.5===n.offset?"center":"bottom"):t>45&&t=45&&t<=135?(l="left",a=.5===n.offset?"center":"top"):t>=s&&t<=315?(l="right",a=.5===n.offset?"center":"bottom"):t>45&&tMath.abs(t.y-n.y)?n.x0)for(var e=0;e=0;r--)("nodes"===i||"connectors"===i)&&(n[""+i][parseInt(r.toString(),10)].wrapper=null),"dataManager"!==i&&(n[""+i][parseInt(r.toString(),10)]=Zx(n[""+i][parseInt(r.toString(),10)],e[""+i][parseInt(r.toString(),10)],void 0!==t[""+i]?t[""+i][parseInt(r.toString(),10)]:[]),("[]"===JSON.stringify(n[""+i][parseInt(r.toString(),10)])||"{}"===JSON.stringify(n[""+i][parseInt(r.toString(),10)])||void 0===n[""+i][parseInt(r.toString(),10)])&&n[""+i].splice(r,1));n=void 0}function zh(n,t){var e=t.style,i=t;t.canApplyStyle=!0;for(var r=0,s=Object.keys(n);r=0&&n.splice(e,1)}function Jf(n,t,e){var i;n.intermediatePoints=t,n.updateSegmentElement(n,t,n.wrapper.children[0],e);var r=n.sourceDecorator;if("Bezier"===n.type){var s=n.segments[0],o=n.segments[n.segments.length-1];i=[R.isEmptyPoint(o.point2)?o.bezierPoint2:o.point2,R.isEmptyPoint(s.point1)?s.bezierPoint1:s.point1]}else i=n.intermediatePoints;t=n.clipDecorators(n,t,e);var a=n.wrapper.children[0];a.canMeasurePath=!0,n.updateDecoratorElement(a=n.wrapper.children[1],t[0],i[1],r),n.updateDecoratorElement(a=n.wrapper.children[2],t[t.length-1],i[i.length-2],n.targetDecorator),n.updateShapeElement(n)}function Jx(n,t,e){var l,i=n.wrapper,s=t.offset,o=t.size/e.scale,a=t.margin,h=i.offsetX-i.actualSize.width*i.pivot.x,c=i.offsetY-i.actualSize.height*i.pivot.y;if(l={x:0,y:0},n.nodes.length>0){switch(t.side){case"Top":l.x+=h+s*i.actualSize.width,l.y+=c-o;break;case"Bottom":l.x+=h+s*i.actualSize.width,l.y+=c+i.actualSize.height+o;break;case"Left":l.x+=h-o,l.y+=c+s*i.actualSize.height;break;case"Right":l.x+=h+i.actualSize.width+o,l.y+=c+s*i.actualSize.height}l.x+=(a.left-a.right)/e.scale+o/2*("Center"===t.horizontalAlignment?0:"Right"===t.horizontalAlignment?-1:1),l.y+=(a.top-a.bottom)/e.scale+o/2*("Center"===t.verticalAlignment?0:"Top"===t.verticalAlignment?-1:1)}else if(n.connectors.length>0){var d=n.connectors[0],u={offset:s},f=Xx(d.intermediatePoints,u),p=f.index;l=f.point;var y,v=Gx(d.intermediatePoints,u).angle;qi(y=Bi(),-v,d.intermediatePoints[parseInt(p.toString(),10)].x,d.intermediatePoints[parseInt(p.toString(),10)].y),(l=Ke(y,l)).x+=a.left-a.right+o/2*("Center"===t.horizontalAlignment?0:"Right"===t.horizontalAlignment?-1:1),l.y+=a.top-a.bottom+o/2*("Center"===t.verticalAlignment?0:"Top"===t.verticalAlignment?-1:1),qi(y=Bi(),v,d.intermediatePoints[parseInt(p.toString(),10)].x,d.intermediatePoints[parseInt(p.toString(),10)].y),l=Ke(y,l)}return 0===i.rotateAngle&&0===i.parentTransform||(qi(y=Bi(),i.rotateAngle+i.parentTransform,i.offsetX,i.offsetY),l=Ke(y,l)),l}function ga(n,t,e,i){if(i.annotation){if(Pl(i.annotation))return!0}else if(lr[""+t]&n&&bt[""+t]&e)return!0;return!1}function qr(n,t){return!!(lr[""+t]&n)}function Hc(n,t){return!!(Ix[""+t]&n)}function va(n,t){return n.visibility&t}function JI(n,t){var e;if("Text"===n.shape.type)e=n.shape;else{var i=t.split("_");t=i[i.length-1];for(var r=0;rn[""+t]?e.splice(0,0,n):e.push(n);else if(e.length>1){for(var i=0,r=e.length-1,s=Math.floor((i+r)/2);s!==i;)if(e[parseInt(s.toString(),10)][""+t]n[""+t]))break;r=s,s=Math.floor((i+r)/2)}e[parseInt(r.toString(),10)][""+t]n[""+t]?e.splice(i,0,n):e[parseInt(i.toString(),10)][""+t]n[""+t]&&e.splice(r,0,n)}}function kse(n){var t=document.getElementById(n.diagramId),e="ej2_instances",i=t[""+e][0].nodes;void 0===i&&(i=function Pse(n){for(var t=[],e=0;e30?10:o/2;for(var h=0,c=0;c=l){var u=l-h;r=Gt(n[c],n[c+1]),s=R.transform(n[c],r,u);break}h+=d}return s},tb=function(n,t){if(n instanceof te||n instanceof de)for(var e=0;e=0||navigator.platform.indexOf("iPad")>=0||navigator.platform.indexOf("iPhone")>=0||navigator.platform.indexOf("MacIntel")>=0)&&("safari"===X.info.name||"webkit"===X.info.name)}function bF(n,t,e,i){return void 0!==t.previewSize[""+i]?t.previewSize[""+i]:void 0!==n.symbolPreview[""+i]?n.symbolPreview[""+i]:t[""+i]||e.actualSize[""+i]}function nm(n,t,e){return n&&n.parentId&&(e=(n=t.nameTable[n.parentId]).parentId?nm(n,t,e):n.id),e}function sm(n,t){return n.selectedItems.connectors.length>1&&0===n.selectedItems.nodes.length&&0!==t.rotateAngle}function Bse(n){if(n.arrowType&&""!==n.arrowType.trim())switch(n.arrowType){case"single-line-arrow":default:return{targetDecorator:"Arrow",strokeWidth:1};case"double-line-arrow":return{targetDecorator:"Arrow",strokeWidth:2};case"dotted-arrow":return{targetDecorator:"Arrow",strokeDashArray:"2,2"};case"single-line":return{targetDecorator:"None",strokeWidth:1};case"double-line":return{targetDecorator:"None",strokeWidth:2};case"dotted":return{targetDecorator:"None",strokeDashArray:"2,2"};case"wiggly-arrow":return{targetDecorator:"None",strokeWidth:1,opacity:0}}return{targetDecorator:"Arrow",strokeWidth:1}}var Fse=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),no=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},MF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Fse(t,n),no([I("None")],t.prototype,"shape",void 0),no([I("white")],t.prototype,"fill",void 0),no([I("Auto")],t.prototype,"horizontalAlignment",void 0),no([I("Auto")],t.prototype,"verticalAlignment",void 0),no([I(10)],t.prototype,"width",void 0),no([I(10)],t.prototype,"height",void 0),no([re({x:.5,y:1},R)],t.prototype,"offset",void 0),no([I("#1a1a1a")],t.prototype,"borderColor",void 0),no([I(1)],t.prototype,"borderWidth",void 0),no([re({},Jn)],t.prototype,"margin",void 0),no([I("")],t.prototype,"pathData",void 0),no([I("")],t.prototype,"content",void 0),no([I(0)],t.prototype,"cornerRadius",void 0),no([re({left:2,right:2,top:2,bottom:2},Jn)],t.prototype,"padding",void 0),no([I("#1a1a1a")],t.prototype,"iconColor",void 0),t}(Ee),_se=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),iT=function(n){function t(){var e=null!==n&&n.apply(this,arguments)||this;return e.orientation="Vertical",e.measureChildren=void 0,e.considerPadding=!0,e}return _se(t,n),t.prototype.measure=function(e){return this.desiredSize=this.measureStackPanel(e,"Horizontal"===this.orientation?this.updateHorizontalStack:this.updateVerticalStack),this.desiredSize},t.prototype.arrange=function(e){return this.actualSize=this.arrangeStackPanel(e,"Horizontal"===this.orientation?this.arrangeHorizontalStack:this.arrangeVerticalStack),this.updateBounds(),this.actualSize},t.prototype.measureStackPanel=function(e,i){var r=void 0;if(void 0!==this.children&&this.children.length>0)for(var s=0,o=this.children;s0){var r=void 0,s=void 0;r=this.offsetX-e.width*this.pivot.x+this.padding.left,s=this.offsetY-e.height*this.pivot.y+this.padding.top;for(var o=0,a=this.children;o0)for(var i=0,r=this.children;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Xse=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Gse(t,n),Rh([I("Horizontal")],t.prototype,"orientation",void 0),Rh([I("Center")],t.prototype,"type",void 0),Rh([I(void 0)],t.prototype,"offset",void 0),Rh([I(!1)],t.prototype,"enableRouting",void 0),Rh([I([])],t.prototype,"children",void 0),Rh([I("")],t.prototype,"assistants",void 0),Rh([I("")],t.prototype,"level",void 0),Rh([I("")],t.prototype,"hasSubTree",void 0),Rh([I("")],t.prototype,"rows",void 0),t}(Ee),Ni=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),q=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},qse=function(n){if(n)switch(n.type){case"Basic":default:return ib;case"Flow":return DF;case"Path":return wF;case"Image":return EF;case"Text":return zd;case"Bpmn":return lT;case"Native":return om;case"HTML":return CF;case"UmlActivity":return xF;case"UmlClassifier":return TF;case"SwimLane":return Bd}return ib},ma=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),q([I("Basic")],t.prototype,"type",void 0),t}(Ee),wF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"Path"},q([I("Path")],t.prototype,"type",void 0),q([I("")],t.prototype,"data",void 0),t}(ma),om=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"Native"},q([I("Native")],t.prototype,"type",void 0),q([I("")],t.prototype,"content",void 0),q([I("Stretch")],t.prototype,"scale",void 0),t}(ma),CF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"Html"},q([I("HTML")],t.prototype,"type",void 0),q([I("")],t.prototype,"content",void 0),t}(ma),EF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"Image"},q([I("Image")],t.prototype,"type",void 0),q([I("")],t.prototype,"source",void 0),q([I("None")],t.prototype,"scale",void 0),q([I("None")],t.prototype,"align",void 0),t}(ma),zd=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"Text"},q([I("Text")],t.prototype,"type",void 0),q([I("")],t.prototype,"content",void 0),q([re({},Jn)],t.prototype,"margin",void 0),t}(ma),ib=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"BasicShape"},q([I("Basic")],t.prototype,"type",void 0),q([I("Rectangle")],t.prototype,"shape",void 0),q([I(0)],t.prototype,"cornerRadius",void 0),q([Ft([],R)],t.prototype,"points",void 0),t}(ma),DF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"FlowShape"},q([I("Flow")],t.prototype,"type",void 0),q([I("Terminator")],t.prototype,"shape",void 0),t}(ma),nT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"BpmnGateway"},q([I("None")],t.prototype,"type",void 0),t}(Ee),sT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"BpmnDataObject"},q([I("None")],t.prototype,"type",void 0),q([I(!1)],t.prototype,"collection",void 0),t}(Ee),$se=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),q([I("None")],t.prototype,"type",void 0),q([I("None")],t.prototype,"loop",void 0),q([I(!1)],t.prototype,"call",void 0),q([I(!1)],t.prototype,"compensation",void 0),t}(Ee),oT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"BpmnEvent"},q([I("Start")],t.prototype,"event",void 0),q([I("None")],t.prototype,"trigger",void 0),t}(Ee),Rd=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"BpmnSubEvent"},q([I("None")],t.prototype,"trigger",void 0),q([I("Start")],t.prototype,"event",void 0),q([I("")],t.prototype,"id",void 0),q([re({},R)],t.prototype,"offset",void 0),q([Ft([],Kn)],t.prototype,"annotations",void 0),q([Ft([],Es)],t.prototype,"ports",void 0),q([I()],t.prototype,"width",void 0),q([I()],t.prototype,"height",void 0),q([re({},Jn)],t.prototype,"margin",void 0),q([I("Center")],t.prototype,"horizontalAlignment",void 0),q([I("Center")],t.prototype,"verticalAlignment",void 0),q([I(!0)],t.prototype,"visible",void 0),t}(Ee),Zse=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),q([re({id:"success",event:"End",offset:{x:1,y:.5}},Rd)],t.prototype,"success",void 0),q([re({id:"failure",event:"Intermediate",trigger:"Error",offset:{x:.25,y:1}},Rd)],t.prototype,"failure",void 0),q([re({id:"cancel",event:"Intermediate",trigger:"Cancel",offset:{x:.75,y:1}},Rd)],t.prototype,"cancel",void 0),t}(Ee),Jse=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),q([I("None")],t.prototype,"type",void 0),q([I(!1)],t.prototype,"adhoc",void 0),q([I("Default")],t.prototype,"boundary",void 0),q([I(!1)],t.prototype,"compensation",void 0),q([I("None")],t.prototype,"loop",void 0),q([I(!0)],t.prototype,"collapsed",void 0),q([Ft([],Rd)],t.prototype,"events",void 0),q([re({},Zse)],t.prototype,"transaction",void 0),q([I(void 0)],t.prototype,"processes",void 0),t}(Ee),aT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"BpmnActivity"},q([I("Task")],t.prototype,"activity",void 0),q([re({},$se)],t.prototype,"task",void 0),q([re({},Jse)],t.prototype,"subProcess",void 0),t}(Ee),am=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return Ni(t,n),t.prototype.getClassName=function(){return"BpmnAnnotation"},q([I("")],t.prototype,"text",void 0),q([I("")],t.prototype,"id",void 0),q([I(0)],t.prototype,"angle",void 0),q([I()],t.prototype,"height",void 0),q([I()],t.prototype,"width",void 0),q([I(0)],t.prototype,"length",void 0),t}(Ee),Kse=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),q([I("")],t.prototype,"textAnnotationTarget",void 0),q([I("Auto")],t.prototype,"textAnnotationDirection",void 0),t}(Ee),lT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"BpmnShape"},q([I("Bpmn")],t.prototype,"type",void 0),q([I("Event")],t.prototype,"shape",void 0),q([re({},oT)],t.prototype,"event",void 0),q([re({},nT)],t.prototype,"gateway",void 0),q([re({},sT)],t.prototype,"dataObject",void 0),q([re({},aT)],t.prototype,"activity",void 0),q([re({},am)],t.prototype,"annotation",void 0),q([Ft([],am)],t.prototype,"annotations",void 0),q([re({},Kse)],t.prototype,"textAnnotation",void 0),t}(ma),xF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"UmlActivityShape"},q([I("UmlActivity")],t.prototype,"type",void 0),q([I("Action")],t.prototype,"shape",void 0),t}(ma),hT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"MethodArguments"},q([I("")],t.prototype,"name",void 0),q([I("")],t.prototype,"type",void 0),q([re({},Qf)],t.prototype,"style",void 0),t}(Ee),rp=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"UmlClassAttribute"},q([I("Public")],t.prototype,"scope",void 0),q([I(!1)],t.prototype,"isSeparator",void 0),q([re({fill:"#F9F9F9",strokeColor:"#CCCCCC"},Ll)],t.prototype,"separatorStyle",void 0),t}(hT),lm=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"UmlClassMethod"},q([Ft([],hT)],t.prototype,"parameters",void 0),t}(rp),rb=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"UmlClass"},q([I("")],t.prototype,"name",void 0),q([Ft([],rp)],t.prototype,"attributes",void 0),q([Ft([],lm)],t.prototype,"methods",void 0),q([re({},Qf)],t.prototype,"style",void 0),t}(Ee),cT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"UmlInterface"},q([I(!1)],t.prototype,"isSeparator",void 0),q([re({fill:"#F9F9F9",strokeColor:"#CCCCCC"},Ll)],t.prototype,"separatorStyle",void 0),t}(rb),nb=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"UmlEnumerationMember"},q([I("")],t.prototype,"name",void 0),q([I("")],t.prototype,"value",void 0),q([I(!1)],t.prototype,"isSeparator",void 0),q([re({fill:"#F9F9F9",strokeColor:"#CCCCCC"},Ll)],t.prototype,"separatorStyle",void 0),q([re({},Qf)],t.prototype,"style",void 0),t}(Ee),dT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"UmlEnumeration"},q([I("")],t.prototype,"name",void 0),q([Ft([],nb)],t.prototype,"members",void 0),q([re({},Qf)],t.prototype,"style",void 0),t}(Ee),TF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"UmlClassifierShape"},q([I("UmlClassifier")],t.prototype,"type",void 0),q([re({},rb)],t.prototype,"classShape",void 0),q([re({},cT)],t.prototype,"interfaceShape",void 0),q([re({},dT)],t.prototype,"enumerationShape",void 0),q([I("Class")],t.prototype,"classifier",void 0),t}(ma),te=function(n){function t(e,i,r,s){var a,o=n.call(this,e,i,r,s)||this;return o.isCanvasUpdate=!1,o.status="None",o.parentId="",o.processId="",o.umlIndex=-1,o.outEdges=[],o.inEdges=[],o.isHeader=!1,o.isLane=!1,o.isPhase=!1,o.children&&o.children.length>0&&((!(a=r).style||!a.style.fill)&&(o.style.fill="transparent"),(!a.style||!a.style.strokeColor)&&(o.style.strokeColor="transparent")),o.shape&&"UmlActivity"===o.shape.type&&$I(r,o),o.shape&&"SwimLane"===o.shape.type&&sF(r,o),o.ports&&o.ports.length&&function rse(n){for(var t=0;t>";t=n;break;case"FinalNode":t=uF(e)}return t}(new Ze,i,this);break;case"Bpmn":if(e.bpmnModule){i=e.bpmnModule.initBPMNContent(i,this,e),this.wrapper.elementActions=this.wrapper.elementActions|Xr.ElementIsGroup;var v=this.shape.activity.subProcess;if(v.processes&&v.processes.length)for(var S=0,b=this.shape.activity.subProcess.processes;S>",margin:{left:10,right:10},id:"class",style:{fontSize:i.style.fontSize,color:i.style.color,fill:i.style.fill,textWrapping:r},offset:{x:.5,y:.3},constraints:Nr.ReadOnly}],constraints:(ie.Default|ie.HideThumbs)&~(ie.Rotate|ie.Drag|ie.Resize),verticalAlignment:"Stretch",horizontalAlignment:"Stretch",style:{fill:t.style.fill,strokeColor:"black"===t.style.strokeColor?"#ffffff00":t.style.strokeColor}},!0);return e.initObject(s),e.nodes.push(s),e.UpdateBlazorDiagramModel(s,"Node"),t.children.push(s.id),function jse(n,t,e,i){if("Enumeration"===n.shape.classifier){var r=e.members;if(r&&r.length){tp(n,t);for(var s="",o=0;o0)for(var o=0;o0&&s.phaseSize&&(i+=s.phaseSize,Yv(n,s.phaseSize)),s.lanes.length>0)for(o=0;o0){var a=0;for(o=0;o0&&"Horizontal"===r.orientation)for(l=0;l0&&(i+=r.phaseSize,o=Qv(r.phaseSize),n.push(o)),a=0;a0&&o.phaseSize){for(var l=0;l0)for(l=0;l0?e.nameTable[this.nodes[0].id].wrapper:e.nameTable[this.connectors[0].id].wrapper,this.annotation.id);i.children.push(s)}else if(this.nodes||this.connectors){for(var o=0;o-1}function zF(n,t,e){n=[];for(var i=0,r=e.length;i0?c.getElementsByTagName("svg")[0].outerHTML:c.getElementsByTagName("g").length>0?c.getElementsByTagName("g")[0].outerHTML:"",s.shape.content=h,n.content=h,c.parentElement.removeChild(c)}l="nodeTemplate"}else a=s,l="annotationTemplate";var p=document.getElementById(n.diagramId).ej2_instances[0];if("string"!=typeof n.content&&"function"!=typeof n.content||n.isTemplate)if(n.isTemplate){if(v=void 0,v=p.isReact?n.getNodeTemplate()($(e),p,l+"_"+("nodeTemplate"===l?e.id:n.nodeId+e.id),void 0,void 0,!1,i):p.isVue||p.isVue3?n.getNodeTemplate()?n.getNodeTemplate()($(e),p,l+"_"+("nodeTemplate"===l?e.id:n.nodeId+e.id),void 0,void 0,!1,i):(v=si("nodeTemplate"===l?p.nodeTemplate:p.annotationTemplate))($(e),p,l+"_"+("nodeTemplate"===l?e.id:n.nodeId+e.id),void 0,void 0,!1,i):n.getNodeTemplate()($(e),p,l+"_"+("nodeTemplate"===l?e.id:n.nodeId+e.id),void 0,void 0,!1))for(var M=0;M=1&&0===n.x&&("Clip"===i.textOverflow||"Ellipsis"===i.textOverflow)&&("Wrap"===i.textWrapping||"WrapWithOverflow"===i.textWrapping)&&(n.x=t[e-1]?t[e-1].x:-n.width/2),n.x}function BF(n,t,e,i){return e&&!t.template||t.template&&"function"==typeof t.template&&i.isReact?(n.isTemplate=!0,n.template=n.content=Hh(n,!0,t)):n.content=t.template,n}function Qe(){for(var e,t="",i=0;i<5;i++){if(typeof window<"u"&&"crypto"in window&&"getRandomValues"in crypto){var r=new Uint16Array(1);e=(window.msCrypto||window.crypto).getRandomValues(r)[0]%60}else e=Math.floor(61*Math.random());0===i&&e<10?i--:t+="0123456789ABCDEFGHIJKLMNOPQRSTUVWXTZabcdefghiklmnopqrstuvwxyz".substring(e,e+1)}return t}function FF(n){if(n)try{return"function"!=typeof n&&document.querySelectorAll(n).length?si(document.querySelector(n).innerHTML.trim()):si(n)}catch{return si(n)}}function xn(n){new Ne;var e=n.offsetY-n.actualSize.height*n.pivot.y,i=n.offsetY+n.actualSize.height*(1-n.pivot.y),r=n.offsetX-n.actualSize.width*n.pivot.x,s=n.offsetX+n.actualSize.width*(1-n.pivot.x);return Ne.toBounds([{x:r,y:e},{x:s,y:e},{x:r,y:i},{x:s,y:i}])}function yr(n){var t=new Ne,e=xn(n),i=e.middleLeft,r=e.topCenter,s=e.bottomCenter,o=e.middleRight,a=e.topLeft,l=e.topRight,h=e.bottomLeft,c=e.bottomRight;if(n.corners={topLeft:a,topCenter:r,topRight:l,middleLeft:i,middleRight:o,bottomLeft:h,bottomCenter:s,bottomRight:c},0!==n.rotateAngle||0!==n.parentTransform){var d=Bi();qi(d,n.rotateAngle+n.parentTransform,n.offsetX,n.offsetY),n.corners.topLeft=a=Ke(d,a),n.corners.topCenter=r=Ke(d,r),n.corners.topRight=l=Ke(d,l),n.corners.middleLeft=i=Ke(d,i),n.corners.middleRight=o=Ke(d,o),n.corners.bottomLeft=h=Ke(d,h),n.corners.bottomCenter=s=Ke(d,s),n.corners.bottomRight=c=Ke(d,c)}return t=Ne.toBounds([a,l,h,c]),n.corners.left=t.left,n.corners.right=t.right,n.corners.top=t.top,n.corners.bottom=t.bottom,n.corners.center=t.center,n.corners.width=t.width,n.corners.height=t.height,t}function $(n,t,e,i){var r={},s="properties";if(n){e=n.propName;var l=[],h=[];if((l=l.concat(Object.keys(n[""+s]||n))).push("version"),e){var c=Zi(t);h=c?c(e):[],l=l.concat(h)}for(var d=function Soe(n){switch(n){case"nodes":case"children":return["inEdges","outEdges","parentId","processId","nodeId","umlIndex","isPhase","isLane"];case"connectors":return["parentId"];case"annotation":case"annotations":return["nodeId"];case"shape":return["hasHeader"];case"layers":return["objectZIndex"]}return[]}(e),u=0,f=l=l.concat(d);u0&&(e=r),r=Math.floor(boe(e,i)),s=Bc(o+=n.substr(e,r),t)}while(s<=t.width);for(o=o.substr(0,e),a=e;a=t.width){n=n.substr(0,o.length-1);break}return"Ellipsis"===t.textOverflow?(n=n.substr(0,n.length-3),n+="..."):n=n.substr(0,n.length),n}function yT(n,t){if("NoWrap"===t&&"PreserveAll"===n)return"pre";var e="";switch(n){case"CollapseAll":e="nowrap";break;case"CollapseSpace":e="pre-line";break;case"PreserveAll":e="pre-wrap"}return e}function ST(n,t){var e=Bi();qi(e,t,0,0);var i=Ke(e,{x:0,y:0}),r=Ke(e,{x:n.width,y:0}),s=Ke(e,{x:0,y:n.height}),o=Ke(e,{x:n.width,y:n.height}),a=Math.min(i.x,r.x,s.x,o.x),l=Math.min(i.y,r.y,s.y,o.y),h=Math.max(i.x,r.x,s.x,o.x),c=Math.max(i.y,r.y,s.y,o.y);return new me(h-a,c-l)}function xs(n,t,e,i){if(0!==n){var r=Bi();return qi(r,n,t,e),Ke(r,i)}return i}function Zi(n){return void 0!==n&&"string"==typeof n&&(n=Y(n,window)),n}var bo=function(){function n(){}return n.getContext=function(t){return t.getContext("2d")},n.setCanvasSize=function(t,e,i){t&&(t.setAttribute("width",e.toString()),t.setAttribute("height",i.toString()))},n.prototype.renderGradient=function(t,e,i,r){var s,o,a;if("None"!==t.gradient.type){for(var l=0;l0?(w=0===S.r1?e.arc[parseInt(r.toString(),10)].r1:S.r1,C=0===S.r2?e.arc[parseInt(r.toString(),10)].r2:S.r2,r++):(w=S.r1,C=S.r2);var D=S.angle*(Math.PI/180),A=S.largeArc,x=S.sweep,P={x:u,y:f},L={x:Math.cos(D)*(M.x-P.x)/2+Math.sin(D)*(M.y-P.y)/2,y:-Math.sin(D)*(M.x-P.x)/2+Math.cos(D)*(M.y-P.y)/2},O=Math.pow(L.x,2)/Math.pow(w,2)+Math.pow(L.y,2)/Math.pow(C,2);O>1&&(w*=Math.sqrt(O),C*=Math.sqrt(O));var N=Math.pow(C,2)*Math.pow(L.x,2),T=(A===x?-1:1)*Math.sqrt((Math.pow(w,2)*Math.pow(C,2)-Math.pow(w,2)*Math.pow(L.y,2)-N)/(Math.pow(w,2)*Math.pow(L.y,2)+Math.pow(C,2)*Math.pow(L.x,2)));isNaN(T)&&(T=0);var z={x:T*w*L.y/C,y:T*-C*L.x/w},U={x:(M.x+P.x)/2+Math.cos(D)*z.x-Math.sin(D)*z.y,y:(M.y+P.y)/2+Math.sin(D)*z.x+Math.cos(D)*z.y},B=this.a([1,0],[(L.x-z.x)/w,(L.y-z.y)/C]),j=[(L.x-z.x)/w,(L.y-z.y)/C],Q=[(-L.x-z.x)/w,(-L.y-z.y)/C],oe=this.a(j,Q);this.r(j,Q)<=-1&&(oe=Math.PI),this.r(j,Q)>=1&&(oe=0);var fe=B+oe/2*(x?1:-1);if(Math.cos(fe),Math.sin(fe),S.centp=U,S.xAxisRotation=D,S.rx=w,S.ry=C,S.a1=B,S.ad=oe,S.sweep=x,null!=s){var De=w>C?w:C,xe=w>C?1:w/C,Ie=w>C?C/w:1;s.save(),s.translate(U.x,U.y),s.rotate(D),s.scale(xe,Ie),s.arc(0,0,De,B,B+oe,!x),s.scale(1/xe,1/Ie),s.rotate(-D),s.translate(-U.x,-U.y),s.restore()}break;case"Z":case"z":s.closePath(),u=o,f=a}o=u,a=f}}},n.prototype.drawText=function(t,e,i,r,s,o,a){if(e.content&&!0===e.visible){var l=n.getContext(t);l.save(),this.setStyle(t,e),o&&(e.fontSize*=o),this.applyFlipAndRotate(l,e,t,e.x+e.width*e.pivotX,e.y+e.height*e.pivotY),this.setFontStyle(t,e);var u,d=0;u=e.childNodes;var f=e.wrapBounds;if(l.fillStyle=e.color,f){var p=this.labelAlign(e,f,u);for(d=0;de.width&&"Wrap"!==e.textOverflow&&"NoWrap"===e.textWrapping&&(g.text=UF(g.text,e)),"Clip"!==e.textOverflow&&"Ellipsis"!==e.textOverflow||"Wrap"!==e.textWrapping?l.fillText(g.text,v,y):ya.actualSize.height+a.bounds.y&&(g.text=g.text.slice(0,g.text.length-3),g.text=g.text.concat("...")),l.fillText(g.text,v,y)),"Underline"===e.textDecoration||"Overline"===e.textDecoration||"LineThrough"===e.textDecoration){var M=v,w=void 0,D=v+l.measureText(g.text).width,A=void 0;switch(e.textDecoration){case"Underline":w=y+2,A=y+2;break;case"Overline":w=p.y+g.dy*d,A=p.y+g.dy*d;break;case"LineThrough":w=(y+p.y+g.dy*d)/2+2,A=(y+p.y+g.dy*d)/2+2}l.beginPath(),l.moveTo(M,w),l.lineTo(D,A),l.strokeStyle=e.color,l.lineWidth=.08*e.fontSize,l.globalAlpha=e.opacity,l.stroke()}}}l.restore()}},n.prototype.applyFlipAndRotate=function(t,e,i,r,s){"Horizontal"===e.flip||"Vertical"===e.flip?(t.translate(e.x+e.width/2,e.y+e.height/2),t.rotate(-e.angle*Math.PI/180),t.translate(-e.x-e.width/2,-e.y-e.height/2)):this.rotateContext(i,e.angle,r,s),t.translate(e.x,e.y),"Horizontal"===e.flip?(t.scale(-1,1),t.translate(-1*e.width,0)):"Vertical"===e.flip?(t.scale(1,-1),t.translate(0,-1*e.height)):"Both"===e.flip&&(t.scale(-1,-1),t.translate(-1*e.width,-1*e.height)),t.translate(-e.x,-e.y)},n.prototype.loadImage=function(t,e,i,r,s){var o=new Image;o.src=e.source,this.image(t,o,e.x,e.y,e.width,e.height,e)},n.prototype.drawImage=function(t,e,i,r){var s=this;if(e.visible){var o=n.getContext(t);o.save();var a=e.x+e.width*e.pivotX,l=e.y+e.height*e.pivotY,h=new Image;h.src=e.source,this.setStyle(t,e),o.canvas.id.split("_"),this.applyFlipAndRotate(o,e,t,a,l),r?h.onload=function(){s.loadImage(o,e,t,a,l)}:this.loadImage(o,e,t,a,l),o.restore()}},n.prototype.image=function(t,e,i,r,s,o,a){t.beginPath();var l=e.width,h=e.height,c=s,d=o,u=0,f=0;if(a&&"None"!==a.alignment){var p=a.alignment.toLowerCase().substr(1,3),g=a.alignment.toLowerCase().substr(5,3);if("Slice"===a.scale){var v=function(){u=c,f=h*c/l},y=function(){u=l*d/h,f=d};c>d?(v(),d>f&&y()):c===d?l>h?y():v():(y(),c>u&&v());var S=this.getSliceOffset(p,u,c,l),b=this.getSliceOffset(g,f,d,h),M=l-S,w=h-b,C=u-S*(u/l),D=f-b*(f/h),A=Tt("canvas",{width:s.toString(),height:o.toString()});A.getContext("2d").drawImage(e,S,b,M,w,0,0,C,D),t.drawImage(A,i,r,s,o)}else if("Meet"===a.scale){var P=h/l,L=d/c;f=L>P?c*P:d,i+=this.getMeetOffset(p,u=L>P?c:d/P,c),r+=this.getMeetOffset(g,f,d),t.drawImage(e,0,0,l,h,i,r,u,f)}else t.drawImage(e,i,r,s,o)}else if("None"!==a.flip){var O=1,N=1;("Horizontal"===a.flip||"Both"===a.flip)&&(i=-i,s=-s,O=-1),("Vertical"===a.flip||"Both"===a.flip)&&(r=-r,o=-o,N=-1),t.scale(O,N),t.drawImage(e,i,r,s,o)}else t.drawImage(e,i,r,s,o);t.closePath()},n.prototype.getSliceOffset=function(t,e,i,r){switch(t){case"min":default:return 0;case"mid":return(e-i)/2*r/e;case"max":return(e-i)*r/e}},n.prototype.getMeetOffset=function(t,e,i){var r=Math.max(e,i),s=Math.min(e,i);switch(t){case"min":default:return 0;case"mid":return(r-s)/2;case"max":return r-s}},n.prototype.m=function(t){return Math.sqrt(Math.pow(t[0],2)+Math.pow(t[1],2))},n.prototype.r=function(t,e){return(t[0]*e[0]+t[1]*e[1])/(this.m(t)*this.m(e))},n.prototype.a=function(t,e){return(t[0]*e[1]t.width&&("Ellipsis"===t.textOverflow||"Clip"===t.textOverflow)&&"NoWrap"===t.textWrapping?0:.5*t.width:"right"===t.textAlign&&(c=1*t.width),s.x=t.x+c+(e?e.x:0),s.y=a+d-r.height/2,s},n}(),hb=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Vi=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},woe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return hb(t,n),Vi([I("")],t.prototype,"source",void 0),Vi([I("transparent")],t.prototype,"color",void 0),Vi([I("None")],t.prototype,"scale",void 0),Vi([I("None")],t.prototype,"align",void 0),t}(Ee),Coe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return hb(t,n),Vi([I("Page")],t.prototype,"mode",void 0),Vi([I("PageSettings")],t.prototype,"region",void 0),Vi([re({top:25,bottom:25,left:25,right:25},Jn)],t.prototype,"margin",void 0),Vi([I(!1)],t.prototype,"canZoomIn",void 0),Vi([I(void 0)],t.prototype,"customBounds",void 0),Vi([I(!1)],t.prototype,"canFit",void 0),t}(Ee),Eoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return hb(t,n),Vi([I(null)],t.prototype,"width",void 0),Vi([I(null)],t.prototype,"height",void 0),Vi([re({},Jn)],t.prototype,"margin",void 0),Vi([I("Landscape")],t.prototype,"orientation",void 0),Vi([I("Infinity")],t.prototype,"boundaryConstraints",void 0),Vi([re({},woe)],t.prototype,"background",void 0),Vi([I(!1)],t.prototype,"multiplePage",void 0),Vi([I(!1)],t.prototype,"showPageBreaks",void 0),Vi([re({},Coe)],t.prototype,"fitOptions",void 0),t}(Ee),Doe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return hb(t,n),Vi([I(0)],t.prototype,"horizontalOffset",void 0),Vi([I(0)],t.prototype,"verticalOffset",void 0),Vi([I(1)],t.prototype,"currentZoom",void 0),Vi([I(0)],t.prototype,"viewPortWidth",void 0),Vi([I(0)],t.prototype,"viewPortHeight",void 0),Vi([I(.2)],t.prototype,"minZoom",void 0),Vi([I(30)],t.prototype,"maxZoom",void 0),Vi([I("Diagram")],t.prototype,"scrollLimit",void 0),Vi([I()],t.prototype,"scrollableArea",void 0),Vi([I(!1)],t.prototype,"canAutoScroll",void 0),Vi([I(100)],t.prototype,"autoScrollFrequency",void 0),Vi([re({left:15,right:15,top:15,bottom:15},Jn)],t.prototype,"autoScrollBorder",void 0),Vi([re({left:0,right:0,top:0,bottom:0},Jn)],t.prototype,"padding",void 0),Vi([I(.2)],t.prototype,"zoomFactor",void 0),t}(Ee),xoe=function(){function n(){this.services={}}return n.prototype.register=function(t,e){this.services[""+t]=e},n.prototype.getService=function(t){return this.services[""+t]},n}(),jF=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),ya=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},VF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return jF(t,n),ya([I("lightgray")],t.prototype,"lineColor",void 0),ya([I("")],t.prototype,"lineDashArray",void 0),ya([I([1.25,18.75,.25,19.75,.25,19.75,.25,19.75,.25,19.75])],t.prototype,"lineIntervals",void 0),ya([I([1,19,.5,19.5,.5,19.5,.5,19.5,.5,19.5])],t.prototype,"dotIntervals",void 0),ya([I([20])],t.prototype,"snapIntervals",void 0),t}(Ee),Toe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return jF(t,n),ya([re({},VF)],t.prototype,"horizontalGridlines",void 0),ya([re({},VF)],t.prototype,"verticalGridlines",void 0),ya([I(Kt.All)],t.prototype,"constraints",void 0),ya([I(5)],t.prototype,"snapAngle",void 0),ya([I("Lines")],t.prototype,"gridType",void 0),ya([I(5)],t.prototype,"snapObjectDistance",void 0),ya([I("#07EDE1")],t.prototype,"snapLineColor",void 0),t}(Ee),WF=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),el=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},YF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return WF(t,n),el([I(5)],t.prototype,"interval",void 0),el([I(100)],t.prototype,"segmentWidth",void 0),el([I("Horizontal")],t.prototype,"orientation",void 0),el([I("RightOrBottom")],t.prototype,"tickAlignment",void 0),el([I("red")],t.prototype,"markerColor",void 0),el([I(25)],t.prototype,"thickness",void 0),el([I(null)],t.prototype,"arrangeTick",void 0),t}(Ee),Aoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return WF(t,n),el([I(!1)],t.prototype,"showRulers",void 0),el([I(!0)],t.prototype,"dynamicGrid",void 0),el([re({orientation:"Horizontal"},YF)],t.prototype,"horizontalRuler",void 0),el([re({orientation:"Vertical"},YF)],t.prototype,"verticalRuler",void 0),t}(Ee),Loe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),QF=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Noe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Loe(t,n),QF([I("")],t.prototype,"property",void 0),QF([I("")],t.prototype,"field",void 0),t}(Ee),IT=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),ln=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},GF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return IT(t,n),ln([I("")],t.prototype,"read",void 0),ln([I("")],t.prototype,"create",void 0),ln([I("")],t.prototype,"update",void 0),ln([I("")],t.prototype,"destroy",void 0),ln([I()],t.prototype,"customFields",void 0),t}(Ee),Ooe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return IT(t,n),ln([I("")],t.prototype,"id",void 0),ln([I("")],t.prototype,"sourceID",void 0),ln([I("")],t.prototype,"targetID",void 0),ln([I(null)],t.prototype,"sourcePointX",void 0),ln([I(null)],t.prototype,"sourcePointY",void 0),ln([I(null)],t.prototype,"targetPointX",void 0),ln([I(null)],t.prototype,"targetPointY",void 0),ln([I(null)],t.prototype,"dataManager",void 0),ln([re({},GF)],t.prototype,"crudAction",void 0),t}(Ee),koe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return IT(t,n),ln([I("")],t.prototype,"id",void 0),ln([I(null)],t.prototype,"dataManager",void 0),ln([I(null)],t.prototype,"dataSource",void 0),ln([I("")],t.prototype,"root",void 0),ln([I("")],t.prototype,"parentId",void 0),ln([I()],t.prototype,"doBinding",void 0),ln([Ft([],Noe)],t.prototype,"dataMapSettings",void 0),ln([re({},GF)],t.prototype,"crudAction",void 0),ln([re({},Ooe)],t.prototype,"connectionDataSource",void 0),t}(Ee),XF=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Cr=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Poe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return XF(t,n),Cr([I("LeftInFlow")],t.prototype,"yesBranchDirection",void 0),Cr([I("RightInFlow")],t.prototype,"noBranchDirection",void 0),Cr([I(["Yes","True"])],t.prototype,"yesBranchValues",void 0),Cr([I(["No","False"])],t.prototype,"noBranchValues",void 0),t}(Ee),zoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return XF(t,n),Cr([I("")],t.prototype,"fixedNode",void 0),Cr([I(30)],t.prototype,"horizontalSpacing",void 0),Cr([I("SamePoint")],t.prototype,"connectionPointOrigin",void 0),Cr([I("Nonlinear")],t.prototype,"arrangement",void 0),Cr([I(30)],t.prototype,"verticalSpacing",void 0),Cr([I(30)],t.prototype,"maxIteration",void 0),Cr([I(40)],t.prototype,"springFactor",void 0),Cr([I(50)],t.prototype,"springLength",void 0),Cr([re({left:50,top:50,right:0,bottom:0},Jn)],t.prototype,"margin",void 0),Cr([I("Auto")],t.prototype,"horizontalAlignment",void 0),Cr([I("Auto")],t.prototype,"verticalAlignment",void 0),Cr([I("TopToBottom")],t.prototype,"orientation",void 0),Cr([I("Auto")],t.prototype,"connectionDirection",void 0),Cr([I("Default")],t.prototype,"connectorSegments",void 0),Cr([I("None")],t.prototype,"type",void 0),Cr([I()],t.prototype,"getLayoutInfo",void 0),Cr([I()],t.prototype,"layoutInfo",void 0),Cr([I()],t.prototype,"getBranch",void 0),Cr([I()],t.prototype,"bounds",void 0),Cr([I(!0)],t.prototype,"enableAnimation",void 0),Cr([I(!1)],t.prototype,"enableRouting",void 0),Cr([I("")],t.prototype,"root",void 0),Cr([re({},Poe)],t.prototype,"flowchartLayoutSettings",void 0),t}(Ee),Roe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),qF=function(n){function t(e,i){var r=n.call(this,e,!0)||this;return r.oldValue=null,r.endPoint=i,r}return Roe(t,n),t.prototype.mouseDown=function(e){var i,r=!0;if(e.source&&e.source.connectors&&(i=e.source.connectors[0]),e.info&&e.actualObject&&(r=e.info.ctrlKey&&"Orthogonal"!==e.actualObject.type),i&&r){this.inAction=!0,this.undoElement=$(e.source),n.prototype.mouseDown.call(this,e);for(var s=0;s0)1!==s&&this.removePrevSegment(i,s);else if(a){var l=R.distancePoints(a.points[0],a.points[1]);Math.abs(a.length||0===a.length?a.length:l)<=5&&this.removeNextSegment(i,s)}this.commandHandler.updateEndPoint(i,r),i.selectedSegmentIndex=0}if(this.undoElement){var c=$(e.source);this.commandHandler.addHistoryEntry({type:"SegmentChanged",redoObject:c,undoObject:this.undoElement,category:"Internal"})}if(i.isBezierEditing&&(i.isBezierEditing=!1),this.prevPosition!==this.startPosition){var u={source:i,state:"Completed",oldValue:this.oldValue,newValue:$(this.selectedSegment),cancel:!1,segment:this.selectedSegment};this.commandHandler.triggerEvent(Ce.segmentChange,u)}n.prototype.mouseUp.call(this,e)},t.prototype.removePrevSegment=function(e,i){var r=e.segments[i-2],s=e.segments[i+1];if(s&&!((s.length||0===s.length?s.length:R.distancePoints(s.points[0],s.points[1]))<=5)){var a=e.segments.slice(i-1,i+1),l={element:e,removeSegments:a,type:"Removal",cancel:!1};if(this.commandHandler.triggerEvent(Ce.segmentCollectionChange,l),!l.cancel){var h=e.segments[i+1];e.segments.splice(i-1,2);var c=this.selectedSegment;"Left"===c.direction||"Right"===c.direction?(r.points[r.points.length-1].x=h.points[0].x,h.points[0].y=r.points[r.points.length-1].y):(r.points[r.points.length-1].y=h.points[0].y,h.points[0].x=r.points[r.points.length-1].x),(c.length||0===c.length)&&this.findSegmentDirection(r),this.findSegmentDirection(h)}}},t.prototype.findSegmentDirection=function(e){e.direction&&(e.length||0===e.length)&&(e.length=R.distancePoints(e.points[0],e.points[e.points.length-1]),e.direction=R.direction(e.points[0],e.points[e.points.length-1]))},t.prototype.removeNextSegment=function(e,i){var l,h,r=this.selectedSegment,s=e.segments[i-1],o=e.segments[i+2],a=e.segments[i+1];if(a.length||0===a.length?(l=e.segments.slice(i,2),h={element:e,removeSegments:l,type:"Removal",cancel:!1},this.commandHandler.triggerEvent(Ce.segmentCollectionChange,h={element:e,removeSegments:l,type:"Removal",cancel:!1}),h.cancel||(e.segments.splice(i,2),"Top"===r.direction||"Bottom"===r.direction?(o.points[0].y=r.points[0].y,s.points[s.points.length-1].x=o.points[0].x):(o.points[0].x=r.points[0].x,s.points[s.points.length-1].y=o.points[0].y))):(l=e.segments.slice(i+1,1),this.commandHandler.triggerEvent(Ce.segmentCollectionChange,h={element:e,removeSegments:l,type:"Removal",cancel:!1}),h.cancel||(e.segments.splice(i+1,1),"Top"===r.direction||"Bottom"===r.direction?s.points[s.points.length-1].x=a.points[a.points.length-1].x:s.points[s.points.length-1].y=a.points[a.points.length-1].y,this.findSegmentDirection(s),r.length=r.direction=null)),s&&o&&!h.cancel&&(s.length=R.distancePoints(s.points[0],o.points[0]),s.direction=R.direction(s.points[0],o.points[0]),o.length||0===o.length)){o.length=R.distancePoints(s.points[s.points.length-1],o.points[o.points.length-1]);var c=s.points,d=o.points;o.direction=R.direction(c[c.length-1],d[d.length-1])}},t.prototype.addOrRemoveSegment=function(e,i,r){for(var s,o,a=[],l={segments:e.segments},h=0;h0?"Bottom":"Top":r>0?"Right":"Left",length:i.points[0].x===i.points[1].x?s:r},!0)),l.push(new wi(e,"segments",{type:"Orthogonal",direction:c,length:h/2},!0));var f={element:e,addSegments:l,type:"Addition",cancel:!1};return this.commandHandler.triggerEvent(Ce.segmentCollectionChange,f),f.cancel||(e.segments=l.concat(e.segments),a=o+2),a},t.prototype.insertFirstSegment=function(e,i,r,s,o){var a,l,d,u,h=[];if(e.sourcePortID&&i.length&&e.segments[0].points.length>2)for(var f=void 0,p=0;p0?"Bottom":"Top":r>0?"Right":"Left"),f=u,h.push(u)}else h.push(new wi(e,"segments",{type:"Orthogonal",direction:i.direction,length:i.length/3},!0)),"Bottom"===i.direction||"Top"===i.direction?(l=Math.abs(r),a=r>0?"Right":"Left"):(l=Math.abs(s),a=s>0?"Bottom":"Top"),u=new wi(e,"segments",{type:"Orthogonal",direction:a,length:l},!0),h.push(u);var y={element:e,addSegments:h,type:"Addition",cancel:!1};if(this.commandHandler.triggerEvent(Ce.segmentCollectionChange,y),!y.cancel){if(e.sourcePortID&&i.length&&e.segments[0].points.length>2)e.segments.splice(0,1),d=1;else{var S=e.segments[1];S&&S.length&&(S.length=a!==S.direction?S.length+l:S.length-l),d=2,i.length=2*i.length/3}e.segments=h.concat(e.segments)}return d},t.prototype.updateAdjacentSegments=function(e,i,r,s){var o=e.segments[parseInt(i.toString(),10)],a=o.points[o.points.length-1],h=!0;"Orthogonal"===o.type&&(o.points[0]=o.points[0],o.points[o.points.length-1]=a,e.segments[i-1]&&(h=this.updatePreviousSegment(r,s,e,i)),e.segments.length-1>i&&h&&this.updateNextSegment(e,o,e.segments[i+1],r,s))},t.prototype.addTerminalSegment=function(e,i,r,s,o){var l,h,c,d,a=e.segments.indexOf(i),u=[],f=e.segments.pop(),p=e.segments[e.segments.length-1];l=p&&"Orthogonal"===p.type?p:null;for(var g=0;g0&&"Left"===o.direction?c.middleLeft:c.middleRight,o.length>c.width/2?Math.abs(a.length)0&&"Top"===o.direction?c.topCenter:c.bottomCenter,o.length>c.height/2?Math.abs(a.length)1)for(var a=0,l=this.diagram.views;a0)for(var e=t===Ce.onUserHandleMouseLeave?this.previousAction:this.action,i={element:void 0},r=0;r0)for(var r={element:void 0},s=void 0,o=void 0,a=0;a-1&&(o=s,this.previousTarget=i,this.targetItem=e),o===e.fixedUserHandles[parseInt(a.toString(),10)].id&&(r.element=e.fixedUserHandles[parseInt(a.toString(),10)],this.userHandle(t,a,r,e))},n.prototype.mouseDown=function(t){var e=this;if("touchstart"===t.type&&(this.timeOutTapHold=setTimeout(function(){("Select"===e.action||"Drag"===e.action)&&e.mouseMove(t,void 0)},500)),!0!==this.inAction||!(this.tool instanceof jI||this.tool instanceof pa)){this.focus=!0;var i=t.touches,r=!!document.getElementsByClassName("e-dragclone")[0];if(this.isMouseOnScrollBar(t)&&!r)return this.isScrolling=!0,void t.preventDefault();if(this.checkFixedUserHandleEvent(Ce.onFixedUserHandleMouseDown,this.targetItem,this.previousTarget),this.checkUserHandleEvent(Ce.onUserHandleMouseDown),!this.checkEditBoxAsTarget(t)&&_v(this.diagram)||Lc(this.diagram)&&!PI(this.diagram))if(("Select"===this.action||"Drag"===this.action)&&this.diagram.updatePortVisibility(this.hoverElement,ci.Hover,!0),!(this.tool instanceof zl||this.tool instanceof Rl)||2!==t.button&&2!==t.buttons)if(!0===this.inAction&&!0===this.isMouseDown&&(this.tool instanceof zl||this.tool instanceof Rl))this.isMouseDown=!0,this.eventArgs={},this.getMouseEventArgs(this.currentPosition,this.eventArgs),this.eventArgs.position=this.currentPosition,this.tool.mouseDown(this.eventArgs);else{this.isMouseDown=!0,this.currentPosition=this.prevPosition=this.getMousePosition(t),this.eventArgs={},this.diagram.textEditing&&!this.isMouseOnScrollBar(t)&&(this.diagram.endEdit(),this.diagram.textEditing=!1,"Canvas"===this.diagram.mode&&1!==this.diagram.scroller.currentZoom&&this.diagram.refreshDiagramLayer());var o=this.getTargetElement();this.action=this.diagram.findActionToBeDone(o.obj,o.sourceElement,this.currentPosition,o.target);var a=this.isMetaKey(t);a&&t.shiftKey&&this.diagram.connectorEditingToolModule?this.action="SegmentEnd":(a||t.shiftKey)&&(Bv(this.diagram)||Fv(this.diagram))&&(this.action="Select"),this.tool=this.diagram.getTool(this.action),this.tool||(this.action="Select",this.tool=this.diagram.getTool(this.action)),this.getMouseEventArgs(this.currentPosition,this.eventArgs),(a||t.shiftKey)&&(this.eventArgs.info=a&&t.shiftKey?{ctrlKey:a,shiftKey:t.shiftKey}:{ctrlKey:!0}),this.eventArgs.position=this.currentPosition;var h=this.diagram.selectedItems.nodes;if(this.tool.mouseDown(this.eventArgs),this.diagram.selectedItems.canToggleSelection&&h&&this.diagram.selectedItems.nodes&&this.tool instanceof fa)for(var c=0;c=2&&(this.touchStartList=zF(this.touchStartList,0,i)),i||t.preventDefault())}else this.inAction=!1,this.tool.mouseUp(this.eventArgs);!this.isForeignObject(t.target)&&!this.isForeignObject(t.target,!0)&&!i&&t.preventDefault()}},n.prototype.mouseMoveExtend=function(t,e){(this.tool instanceof zl||this.tool instanceof Rl)&&this.tool.mouseMove(this.eventArgs),this.diagram.scrollSettings.canAutoScroll?this.checkAutoScroll(t):this.blocked||this.tool.mouseMove(this.eventArgs),this.eventArgs.target&&(this.hoverElement=this.eventArgs.target);var i=!((this.eventArgs.target instanceof te||this.eventArgs.target instanceof de)&&(e instanceof te||e instanceof de));this.tool instanceof kd&&this.diagram.updatePortVisibility(this.hoverElement instanceof te||this.hoverElement instanceof de?this.hoverElement:this.hoverNode,ci.Connect|ci.Hover,i),this.hoverElement instanceof te&&this.hoverNode instanceof te&&this.hoverNode&&this.hoverNode.id!==this.hoverElement.id&&this.diagram.updatePortVisibility(this.hoverNode,ci.Connect|ci.Hover,!0),this.hoverElement instanceof de&&this.hoverElement.ports.length>0&&this.diagram.updatePortVisibility(this.hoverElement,ci.Connect|ci.Hover,!0),this.previousElement instanceof te&&this.hoverElement&&this.previousElement.id!==this.hoverElement.id&&this.diagram.updatePortVisibility(this.previousElement,ci.Connect|ci.Hover,!0),this.previousElement=this.hoverElement,""!==this.diagram.tooltip.content&&(this.hoverElement=null),this.hoverNode=i?null:e},n.prototype.checkAction=function(t){if("LabelSelect"===this.action&&this.eventArgs.sourceWrapper&&(this.eventArgs.sourceWrapper instanceof ai||this.eventArgs.sourceWrapper instanceof es)){var e=this.commandHandler.findTarget(this.eventArgs.sourceWrapper,this.eventArgs.source);!_r(this.diagram,e,!1,this.eventArgs.sourceWrapper)&&ro(e)&&(this.action="LabelDrag",this.tool=this.getTool(this.action),this.tool.mouseDown(this.initialEventArgs))}else ro(t)&&xd(t)&&this.initialEventArgs&&this.initialEventArgs.source&&"Select"===this.action&&(!_r(this.diagram,this.eventArgs.source,!1)&&this.eventArgs.source instanceof ei&&this.getMouseEventArgs(this.currentPosition,this.eventArgs),(!(t instanceof de)||t instanceof de&&!(wr(this.currentPosition,t.sourcePoint,t.hitPadding)||wr(this.currentPosition,t.targetPoint,t.hitPadding)))&&(this.action="Drag"),this.tool=this.getTool(this.action),this.tool.mouseDown(this.initialEventArgs))},n.prototype.isSwimlaneElements=function(t){return!(t&&(t.isLane||t.isPhase||t.isHeader))},n.prototype.canShowTouchTooltip=function(t){return!!("touchstart"===t.type&&this.diagram.tool&ri.SingleSelect&&this.diagram.tool&ri.ZoomPan)&&(this.isMouseDown=!1,!0)},n.prototype.mouseMove=function(t,e){if(this.focus=!0,"touchmove"===t.type&&(this.touchArgs={target:t.target,type:"touchmove"}),this.isScrolling)t.preventDefault();else if(_v(this.diagram)||Lc(this.diagram)&&!PI(this.diagram)){this.currentPosition=this.getMousePosition(t);var i=this.diagram.findObjectsUnderMouse(this.currentPosition),r=this.diagram.findObjectUnderMouse(i,this.action,this.inAction);!function Yne(n,t){n.rulerSettings.showRulers&&(n.hRuler.drawRulerMarker(n.hRuler.element,t,n.scroller.horizontalOffset),n.vRuler.drawRulerMarker(n.vRuler.element,t,n.scroller.verticalOffset))}(this.diagram,this.currentPosition);var s=!1,o=void 0;if("touchmove"===t.type&&(e=t.touches)&&e.length>1&&(this.touchMoveList=zF(this.touchMoveList,0,e),"PinchZoom"!==this.action&&(s=!0)),!1===R.equals(this.currentPosition,this.prevPosition)||this.inAction||this.canShowTouchTooltip(t)){if(!1===this.isMouseDown||s){this.eventArgs={};var a=null,l=void 0;if(null!==r){if((a=this.diagram.findElementUnderMouse(r,this.currentPosition,this.diagram))&&(l=this.commandHandler.findTarget(a,r)),(l instanceof Kn||l instanceof Or)&&(l.tooltip&&""!==l.tooltip.content||(l=r)),l!==this.hoverElement){var h=this.getContent();this.hoverElement&&"Auto"===this.hoverElement.tooltip.openOn&&""!==h&&this.elementLeave(),this.diagram.updatePortVisibility(this.hoverElement,ci.Hover,!0),r instanceof te&&(this.hoverNode=r);var c=!0;!this.isSwimlaneElements(r)&&this.hoverElement&&this.isSwimlaneElements(this.hoverElement)&&(c=!1),this.hoverElement=c?r:this.hoverElement;var d,u=void 0;(d=this.diagram.findElementUnderMouse(r,this.currentPosition,this.diagram))instanceof Ze&&((u=this.commandHandler.findTarget(d,r))instanceof Es||u instanceof Tc)&&this.hoverElement.constraints&oi.ToolTip&&(this.hoverElement=u);var f=void 0;d instanceof ai&&((f=this.commandHandler.findTarget(d,r))instanceof Kn||f instanceof Or)&&f.constraints&Nr.Tooltip&&(this.hoverElement=f),c?this.elementEnter(this.currentPosition,!1):this.hoverElement=r}else this.hoverElement&&this.hoverElement===l&&this.hoverElement.tooltip.content&&void 0!==this.diagram.tooltipObject&&"Mouse"===this.hoverElement.tooltip.relativeMode&&this.setTooltipOffset(this.currentPosition);a&&(o=this.commandHandler.findTarget(a,r))}this.action=this.diagram.findActionToBeDone(r,a,this.currentPosition,o),this.checkFixedUserHandleEvent(Ce.onFixedUserHandleMouseEnter,r,a),this.checkUserHandleEvent(Ce.onUserHandleMouseEnter),this.checkPreviousAction(),this.getMouseEventArgs(this.currentPosition,this.eventArgs),this.tool=this.getTool(this.action),this.mouseEvents(),this.tool instanceof pa||this.tool instanceof Rl||this.tool instanceof zl?this.tool.mouseMove(this.eventArgs):e&&this.tool instanceof Zv&&this.tool.mouseDown(this.eventArgs),this.updateCursor(),this.renderUmlHighLighter(this.eventArgs);var p=!1;this.hoverElement&&!(this.tool instanceof Zv)&&r instanceof te&&this.isSwimlaneElements(r)&&(0===this.diagram.selectedItems.nodes.length||!_r(this.diagram,this.hoverElement))||this.hoverElement instanceof de||(p=!0),this.hoverElement&&!(this.tool instanceof Zv)&&r instanceof de&&(0===this.diagram.selectedItems.connectors.length||!_r(this.diagram,this.hoverElement))||this.hoverElement instanceof te||(p=!0),this.diagram.updatePortVisibility(this.hoverElement,ci.Hover,p);var g=this.getContent();null===r&&this.hoverElement&&"Auto"===this.hoverElement.tooltip.openOn&&g&&(this.hoverElement=null,this.elementLeave()),s=!1}else{this.eventArgs.position=this.currentPosition,"Drag"===this.action&&!_r(this.diagram,this.eventArgs.source,!1)&&this.eventArgs.source instanceof ei&&this.getMouseEventArgs(this.currentPosition,this.eventArgs),this.mouseEvents(),(t.ctrlKey||t.shiftKey)&&(this.eventArgs.info=t.ctrlKey&&t.shiftKey?{ctrlKey:t.ctrlKey,shiftKey:t.shiftKey}:{ctrlKey:!0}),this.checkAction(r);var y=this.getConnectorPadding(this.eventArgs);this.getMouseEventArgs(this.currentPosition,this.eventArgs,this.eventArgs.source,y),this.updateCursor(),this.inAction=!0,this.initialEventArgs=null,("Drag"===this.action||"Rotate"===this.action)&&(this.diagram.diagramActions=this.diagram.diagramActions|ee.Interactions);var S=this.diagram.scroller.getPageBounds();this.mouseMoveExtend(t,r);var b=this.diagram.scroller.getPageBounds();if(r&&(S.width!==b.width||S.height!==b.height||S.x!==b.x||S.y!==b.y)&&this.diagram.views&&this.diagram.views.overview){var M=this.diagram.views.overview;M.updateView(M)}}this.prevPosition=this.currentPosition,this.isForeignObject(t.target,!0)||t.preventDefault()}}},n.prototype.getContent=function(){var i,t=this.hoverElement instanceof te&&this.hoverElement.constraints&ie.Tooltip||this.hoverElement instanceof de&&this.hoverElement.constraints&qe.Tooltip||(this.hoverElement instanceof Es||this.hoverElement instanceof Tc)&&this.hoverElement.constraints&oi.ToolTip||(this.hoverElement instanceof Kn||this.hoverElement instanceof Or)&&this.hoverElement.constraints&Nr.Tooltip,e=this.hoverElement;e instanceof te&&e.children&&e.children.length>0&&(i=this.findIntersectChild(e));var r=t?this.hoverElement.tooltip.content:this.diagram.tooltip.content;return i?i.tooltip.content:r},n.prototype.findIntersectChild=function(t){for(var e,i=new Ne(this.currentPosition.x,this.currentPosition.y,8,8),r=0;r1&&1===t.which&&!function Gre(n){return!!(n&ee.PreventClearSelection)}(this.diagram.diagramActions)&&(c=!1,this.commandHandler.clearSelection()),(!_r(this.diagram,h)||!c)&&(this.commandHandler.selectObjects([h],void 0,a),this.diagram.selectedItems.canToggleSelection)){var d=this.diagram.selectedItems.nodes;d?d[0].parentObj instanceof Hd&&(s=!0):this.diagram.selectedItems.connectors.length>0&&(s=!0)}}var u=!1,f=this.updateContainerProperties(),p=void 0;if(this.addUmlNode(),this.inAction=!1,this.isMouseDown=!1,this.diagram.selectedObject.helperObject&&(p=this.updateContainerBounds()),this.tool&&(this.tool.prevPosition||this.tool instanceof Q3)){this.eventArgs.position=this.currentPosition;var g=this.getConnectorPadding(this.eventArgs);this.getMouseEventArgs(this.currentPosition,this.eventArgs,this.eventArgs.source,g);var v=this.isMetaKey(t);if((v||t.shiftKey)&&(this.eventArgs.info=v&&t.shiftKey?{ctrlKey:v,shiftKey:t.shiftKey}:{ctrlKey:!0}),this.diagram.diagramActions&ee.Interactions&&(this.diagram.diagramActions=this.diagram.diagramActions&~ee.Interactions),this.eventArgs.clickCount=t.detail,this.diagram.selectedObject.helperObject&&(this.tool instanceof fa||this.tool instanceof Pd)){if(this.diagram.selectedObject.actualObject&&""!==this.diagram.selectedObject.actualObject.parentId){var S=this.diagram.getObject(this.diagram.selectedObject.actualObject.parentId);S&&S.isLane&&(this.commandHandler.isContainer=!0)}(u=this.diagram.lineRoutingModule&&this.diagram.nameTable.helper&&this.eventArgs.target&&this.eventArgs.target.isLane&&(this.eventArgs.source instanceof ei&&this.eventArgs.source.nodes.length>0&&""===this.eventArgs.source.nodes[0].parentId||""===this.eventArgs.source.parentId))&&(this.diagram.diagramActions=this.diagram.diagramActions|ee.PreventLaneContainerUpdate),this.tool.mouseUp(this.eventArgs,f.isPreventHistory)}else{if(this.diagram.selectedItems.canToggleSelection){var b=void 0,M=void 0;if(this.diagram.selectedItems.nodes.length>0)for(var w=0;w1&&D[0].id===i[parseInt(w.toString(),10)].id||r.length>0)&&(M=!0);!this.isSwimlaneSelected&&!s&&!M&&this.tool instanceof fa&&"Select"===this.currentAction&&(!b||this.diagram.selectedItems.connectors.length>0)&&this.commandHandler.clearSelection(!0)}this.isSwimlaneSelected=!1,this.tool.mouseUp(this.eventArgs),this.diagram.checkMenu&&(-1!==window.navigator.userAgent.indexOf("Linux")||-1!==window.navigator.userAgent.indexOf("X11"))&&(!t.pageY&&t instanceof TouchEvent&&t.changedTouches?(window.getSelection().removeAllRanges(),this.diagram.contextMenuModule.contextMenu.open(t.changedTouches[0].pageY,t.changedTouches[0].pageX,this.diagram.element),t.preventDefault()):this.diagram.contextMenuModule.contextMenu.open(t.pageY,t.pageX,this.diagram.element),this.diagram.checkMenu=!1)}f.hasStack&&this.diagram.endGroupAction()}if(p&&this.diagram.endGroupAction(),this.updateContainerBounds(!0),2!==this.eventArgs.clickCount&&(this.commandHandler.updateSelectedNodeProperties(this.eventArgs.source),u)){this.diagram.diagramActions=this.diagram.diagramActions&~ee.PreventLaneContainerUpdate;var A=this.eventArgs.source instanceof ei?this.eventArgs.source.nodes:[this.eventArgs.source];if(A)for(w=0;w0&&!N&&this.diagram.renderSelector(!0),!this.inAction&&!this.diagram.currentSymbol&&this.eventArgs){var T=this.getTargetElement();this.diagram.tool!==ri.ZoomPan&&this.diagram.triggerEvent(Ce.click,{element:T.target instanceof Es?T.target:this.eventArgs.source||this.diagram,position:this.eventArgs.position,count:t.detail,actualObject:this.eventArgs.actualObject,button:0===t.button?"Left":1===t.button?"Middle":"Right"})}this.eventArgs={}}this.diagram.diagramActions=this.diagram.diagramActions&~ee.PreventLaneContainerUpdate,e&&this.updateAnnotation(this.diagram.selectedItems),this.previousElement=null,this.eventArgs={},this.diagram.commandHandler.removeStackHighlighter()},n.prototype.isSwimlaneChild=function(t){if(t.shape&&"SwimLane"!==t.shape.type){var e=this.diagram.nameTable[t.parentId];if(!e)return!1;var i=e.parentId?this.diagram.nameTable[e.parentId]:e;return i&&i.shape&&"SwimLane"===i.shape.type}return!1},n.prototype.updateAnnotation=function(t){var e=t.nodes;if(e.length>0)for(var i=0;i0&&(a+=1),h.isPhase){l="Horizontal"===r.orientation?this.currentPosition.x-e.wrapper.bounds.x:this.currentPosition.y-(e.wrapper.bounds.y+r.header.height);var g={id:Qe(),offset:l,header:{annotation:{content:void 0===h.phases[0].header?"Phase":h.phases[0].header.annotation.content,style:void 0===h.phases[0].header?{}:h.phases[0].header.annotation.style}},style:void 0===h.phases[0]?{}:h.phases[0].style};this.diagram.addPhases(e,[g])}else{var v={id:Qe(),style:h.lanes[0].style,header:{annotation:{content:h.lanes[0].header.annotation.content,style:h.lanes[0].header.annotation.style},style:h.lanes[0].header.style}};if("Horizontal"===h.orientation?v.height=h.lanes[0].height:v.width=h.lanes[0].width,"Horizontal"===r.orientation?(s=i.rowIndex?i.rowIndex:this.diagram.nameTable[i.parentId].rowIndex,i.wrapper.offsetYs)v.header.width=r.lanes[parseInt(s.toString(),10)].header.width,v.header.height=r.lanes[parseInt(s.toString(),10)].header.height;else{var S=void 0;S="Horizontal"===r.orientation?i.rowIndex<3?0:s-a-1:s-1,v.header.width=r.lanes[parseInt(S.toString(),10)].header.width,v.header.height=r.lanes[parseInt(S.toString(),10)].header.height}p&&("height"===p?(v.width=v.height,delete v.height):(v.height=v.width,delete v.width)),this.diagram.addLanes(e,[v],"Horizontal"===r.orientation?s-a:s)}this.commandHandler.select(e)}else if(h.isLane){var b={id:Qe(),width:t.width,height:t.height,addInfo:t.addInfo,shape:{type:"SwimLane",header:{annotation:{content:void 0===h.header?"Header":h.header.annotation.content,style:void 0===h.header?{}:h.header.annotation.style},height:50,style:h.header?h.header.style:h.lanes[0].header.style},phases:[{id:Qe(),header:{annotation:{content:void 0===h.phases||void 0===h.phases[0].header?"Phase":h.phases[0].header.annotation.content,style:void 0===h.phases||void 0===h.phases[0].header?{}:h.phases[0].header.annotation.style},style:void 0===h.phases||void 0===h.phases[0].header?{}:h.phases[0].header.style},style:void 0===h.phases?{}:h.phases[0].style}],lanes:[{id:Qe(),height:t.height,width:t.width,style:h.lanes[0].style,header:{annotation:{content:h.lanes[0].header.annotation.content,style:h.lanes[0].header.annotation.style},style:h.lanes[0].header.style}}],orientation:h.orientation}};"Vertical"===h.orientation&&(b.width+=20),b.offsetX=this.currentPosition.x+b.width/2,b.offsetY=this.currentPosition.y+b.height/2,b.style=t.style,this.diagram.add(b)}},n.prototype.mouseLeave=function(t){this.tool&&this.inAction&&this.tool.mouseLeave(this.eventArgs),this.diagram.selectedObject.helperObject&&(this.updateContainerProperties(),this.updateContainerBounds()&&this.diagram.endGroupAction()),this.eventArgs&&this.eventArgs.source&&(this.diagram.updatePortVisibility(this.eventArgs.source,ci.Hover,!0),this.hoverElement=null),this.eventArgs&&!this.eventArgs.source&&this.hoverElement&&(this.hoverElement=null),this.tool instanceof kd&&this.eventArgs&&this.eventArgs.target&&this.eventArgs.target instanceof te&&(this.diagram.updatePortVisibility(this.eventArgs.target,ci.Hover|ci.Connect,!0),this.hoverElement=null);var i=this.diagram.selectedItems;i&&i.wrapper&&(sm(this.diagram,i)||this.diagram.renderSelector(!0)),(this.diagram.diagramActions&ee.Interactions||this.diagram.diagramActions&ee.ToolAction)&&(this.diagram.diagramActions=this.diagram.diagramActions&~ee.ToolAction),this.isMouseDown=!1,this.focus=!1,this.touchStartList=null,this.touchMoveList=null,this.elementLeave(),this.commandHandler.removeSnap(),this.inAction=!1,this.eventArgs={},this.diagram.selectedObject&&this.diagram.selectedObject.helperObject&&(this.diagram.remove(this.diagram.selectedObject.helperObject),this.diagram.selectedObject={helperObject:void 0,actualObject:void 0}),this.tool=null,function Wne(){var t,e,n=document.getElementsByClassName("e-d-ruler-marker");if(n&&n.length>0)for(e=n.length-1;e>=0;e--)(t=n[parseInt(e.toString(),10)])&&t.parentNode.removeChild(t)}(),"Rotate"===this.action&&this.diagram.diagramCanvas.classList.remove("e-diagram-rotate"),t.preventDefault()},n.prototype.mouseWheel=function(t){this.diagram.blazorActions|=on.interaction;var e={event:t,cancel:!1};if(this.diagram.triggerEvent(Ce.mouseWheel,e),!e.cancel){var i=t.wheelDelta>0||-40*t.detail>0,r=this.getMousePosition(t);if(this.diagram.tooltipObject.close(),this.isMetaKey(t)){var o=this.diagram.scrollSettings.zoomFactor;this.diagram.zoomTo(i?{type:"ZoomIn",zoomFactor:o,focusPoint:r}:{type:"ZoomOut",zoomFactor:o,focusPoint:r}),t.preventDefault()}else{var a=this.diagram.scroller.horizontalOffset,l=this.diagram.scroller.verticalOffset,h=i?10:-10;this.tool&&(this.tool instanceof zl||this.tool instanceof Rl)&&(this.eventArgs={},this.getMouseEventArgs(r,this.eventArgs),this.eventArgs.position=r,this.tool.mouseWheel(this.eventArgs)),this.diagram.scrollActions|=da.Interaction;var c=!0;if(t.isTrusted){var d=!1;(Math.abs(t.deltaY)<100&&-0===Math.abs(t.deltaX)||Math.abs(t.deltaX)<100&&-0===Math.abs(t.deltaY))&&(d=!0);var u=!1;(0!==t.deltaX||0!==t.deltaY)&&(u=navigator.userAgent.includes("Macintosh")),u?Math.abs(t.deltaX)>Math.abs(t.deltaY)?(t.shiftKey||t.deltaX&&-0!==t.deltaX&&(d||!u))&&this.diagram.scroller.zoom(1,h,0,r,c,void 0,d):t.deltaY&&-0!==t.deltaY&&(d||!u)&&this.diagram.scroller.zoom(1,0,h,r,c,void 0,d):t.shiftKey||t.deltaX&&-0!==t.deltaX&&(d||!u)?this.diagram.scroller.zoom(1,h,0,r,c,void 0,d):t.deltaY&&-0!==t.deltaY&&(d||!u)&&this.diagram.scroller.zoom(1,0,h,r,c,void 0,d)}else t.shiftKey||t.deltaX&&-0!==t.deltaX?this.diagram.scroller.zoom(1,h,0,r,c):this.diagram.scroller.zoom(1,0,h,r,c);this.diagram.scrollActions&=~da.Interaction,(a!==this.diagram.scroller.horizontalOffset||l!==this.diagram.scroller.verticalOffset)&&t.preventDefault()}if(this.diagram.textEditing){if(this.diagram.isTriggerEvent=!0,this.diagram.activeLabel.parentId){var p=this.diagram.getObject(this.diagram.activeLabel.parentId);this.diagram.startTextEdit(p,this.diagram.activeLabel.id)}this.diagram.isTriggerEvent=!1}this.diagram.blazorActions=this.diagram.blazorActions&~on.interaction}},n.prototype.keyDown=function(t){if(t.fromMouseEvents&&(t.ctrlKey&&(this.keyArgs.keyModifiers=1),t.shiftKey&&(this.keyArgs.keyModifiers=4),t.shiftKey&&t.ctrlKey&&(this.keyArgs.keyModifiers=5)),!(this.diagram.diagramActions&ee.TextEdit)&&!this.checkEditBoxAsTarget(t)||"Escape"===t.key||27===t.keyCode){var i=void 0,r=t.keyCode?t.keyCode:t.which,s=t.key;("ArrowDown"===s||"ArrowUp"===s||"ArrowLeft"===s||"ArrowRight"===s)&&(this.isNudgeKey=!0);var o=this.isMetaKey(t);if(this.diagram.commandManager&&this.diagram.commands)for(var l=0,h=Object.keys(this.diagram.commands);l4&&(S({keyDownEventArgs:KeyboardEvent,parameter:i.parameter,type:"KEYDOWN"}),this.keyCount=0,this.keyArgs.newValue={offsetX:this.diagram.selectedItems.offsetX,offsetY:this.diagram.selectedItems.offsetY},this.diagram.triggerEvent(Ce.positionChange,this.keyArgs))),this.isKeyUp=!1):S({keyDownEventArgs:KeyboardEvent,parameter:i.parameter})}break}}}}this.keyArgs={element:this.diagram.selectedItems,key:t.key,keyCode:t.keyCode?t.keyCode:t.which},this.getKeyModifier(this.keyArgs,t),this.diagram.diagramActions&ee.TextEdit&&this.getlabel(this.keyArgs,t),this.diagram.triggerEvent(Ce.keyDown,this.keyArgs)},n.prototype.getlabel=function(t,e){var i=this.diagram.activeLabel;t.target=this.diagram.element.id+"_editBox";var r=this.diagram.nameTable[i.parentId];if(document.getElementById(this.diagram.element.id+"_editBox")){t.text=document.getElementById(this.diagram.element.id+"_editBox").value;for(var s=0;s=this.diagram.scroller.viewPortWidth-18?r="right":e.x+this.diagram.scroller.horizontalOffsetthis.diagram.scroller.viewPortHeight-18?r="bottom":e.y+this.diagram.scroller.verticalOffset0&&(s=this.findIntersectChild(this.hoverElement)),"Auto"===this.hoverElement.tooltip.openOn&&""!==r&&bx(this.diagram,s||(i?this.hoverElement:void 0)),this.hoverElement.tooltip.content&&("Mouse"===this.hoverElement.tooltip.relativeMode?this.setTooltipOffset(t):(this.diagram.tooltipObject.offsetX=0,this.diagram.tooltipObject.offsetY=0));var o=this.diagram.findObjectsUnderMouse(this.currentPosition),a=this.diagram.findObjectUnderMouse(o,this.action,this.inAction);if(null!==a){var l=void 0;this.hoverElement.tooltip.isSticky&&(this.diagram.tooltipObject.isSticky=!0),a instanceof te&&a.children&&a.children.length>0&&(a=s||a),l=a.ports&&(this.hoverElement instanceof Es||this.hoverElement instanceof Tc)||a.annotations&&(this.hoverElement instanceof Kn||this.hoverElement instanceof Or)?document.getElementById(a.id+"_"+this.hoverElement.id):document.getElementById(a.id+(a.shape&&a.shape instanceof om?"_content_native_element":"_groupElement")),"Auto"===this.hoverElement.tooltip.openOn&&""!==r&&(this.diagram.tooltipObject.close(),this.diagram.tooltipObject.openOn=this.hoverElement.tooltip.openOn,this.diagram.tooltipObject.dataBind()),function _re(n,t){var e=0;return n instanceof de?n.constraints&qe.Tooltip?e=n.constraints&qe.Tooltip:n.constraints&qe.InheritTooltip&&(e=t.constraints&nt.Tooltip):n instanceof Es||n instanceof Tc?n.constraints&oi.ToolTip?e=n.constraints&oi.ToolTip:n.constraints&oi.InheritTooltip&&(e=t.constraints&nt.Tooltip):n instanceof Kn||n instanceof Or?n.constraints&Nr.Tooltip&&(e=n.constraints&Nr.Tooltip):n.constraints&ie.Tooltip?e=n.constraints&ie.Tooltip:n.constraints&ie.InheritTooltip&&(e=t.constraints&nt.Tooltip),e}(this.hoverElement,this.diagram)&&"Auto"===this.hoverElement.tooltip.openOn&&(this.diagram.tooltipObject.target=this.hoverElement.id,this.diagram.tooltipObject.open("Mouse"===this.hoverElement.tooltip.relativeMode?this.diagram.element:l))}}},n.prototype.elementLeave=function(){this.diagram.tooltipObject&&!this.diagram.tooltipObject.isSticky&&"Custom"!==this.diagram.tooltipObject.openOn&&this.diagram.tooltipObject.close()},n.prototype.setTooltipOffset=function(t){var e=function hse(n,t,e,i){var o="Mouse"===(!(e instanceof te?e.constraints&ie.InheritTooltip:e instanceof de?e.constraints&qe.InheritTooltip:e.constraints&oi.InheritTooltip)&&(e instanceof te?e.constraints&ie.Tooltip:e instanceof de?e.constraints&qe.Tooltip:e.constraints&oi.ToolTip)?e.tooltip.relativeMode:n.tooltip.relativeMode);"Mouse"===i?o=!0:"Object"===i&&(o=!1);var a=function cse(n,t,e,i){var o,r={},s=document.getElementById(e.element.id);if(n instanceof te||n instanceof de)o=n.wrapper.bounds;else{var a=e.findObjectsUnderMouse(t),l=e.findObjectUnderMouse(a,"Select",!1);o=e.findElementUnderMouse(l,t,e).bounds}var c=s.getBoundingClientRect();switch(e.tooltipObject.position){case"BottomCenter":r=zc(t,o.bottomCenter,e,i,c.width/2,c.height);break;case"BottomLeft":case"LeftBottom":r=zc(t,o.bottomLeft,e,i,0,c.height);break;case"BottomRight":case"RightBottom":r=zc(t,o.bottomRight,e,i,c.width,c.height);break;case"LeftCenter":r=zc(t,o.middleLeft,e,i,0,c.height/2);break;case"LeftTop":case"TopLeft":r=zc(t,o.topLeft,e,i,0,0);break;case"RightCenter":r=zc(t,o.middleRight,e,i,c.width,c.height/2);break;case"RightTop":case"TopRight":r=zc(t,o.topRight,e,i,c.width,0);break;case"TopCenter":r=zc(t,o.topCenter,e,i,c.width/2,0)}return r}(e,t,n,o),l=Za(n);return{x:a.x+l.width,y:a.y+l.height}}(this.diagram,t,this.hoverElement);this.diagram.tooltipObject.offsetX=e.x,this.diagram.tooltipObject.offsetY=e.y},n.prototype.altKeyPressed=function(t){return!!(t&ft.Alt)},n.prototype.ctrlKeyPressed=function(t){return!!(t&ft.Control)},n.prototype.shiftKeyPressed=function(t){return!!(t&ft.Shift)},n.prototype.scrolled=function(t){this.diagram.updateScrollOffset()},n.prototype.isMobileOrIPadDevice=function(){var t=navigator.userAgent||navigator.vendor||window.opera;return/iPhone|iPad|iPod/.test(t)&&!window.MSStream?"iOS":/android/i.test(t)?"Android":/Mobile|Tablet/.test(t)?"Mobile":"Desktop"},n.prototype.doubleClick=function(t){if(_v(this.diagram)){var e=this.isMobileOrIPadDevice(),i=this.diagram.tool;"Desktop"!==e&&this.tool&&(this.tool instanceof zl||this.tool instanceof Rl)&&(this.diagram.tool=0);var r=void 0,s=this.diagram.findObjectsUnderMouse(this.currentPosition),o=this.diagram.findObjectUnderMouse(s,this.action,this.inAction);if(null!==o&&_v(this.diagram))if(r=this.diagram.findElementUnderMouse(o,this.currentPosition,this.diagram),this.tool&&(this.tool instanceof zl||this.tool instanceof Rl))this.diagram.tool=i,this.tool.mouseUp(this.eventArgs),this.isMouseDown=!1,this.eventArgs={},this.tool=null,t.preventDefault();else{var l=this.diagram.commandHandler.getObjectLayer(o.id);!l||l.lock||!l.visible||this.diagram.diagramActions&ee.TextEdit||this.diagram.startTextEdit(o,r instanceof ai?r.id.split(o.id+"_")[1]:void 0)}this.diagram.triggerEvent(Ce.doubleClick,{source:o||this.diagram,position:this.currentPosition,count:t.detail})}},n.prototype.itemClick=function(t,e){var i=t;return Dn(this.diagram,i,!0)?i:null},n.prototype.inputChange=function(t){var i,s,o,a,l,h,c,d,u,f=document.getElementById(this.diagram.element.id+"_editBox"),p=document.getElementById(this.diagram.element.id+"_editTextBoxDiv"),g=f.value,v=g.split("\n");(!(a=this.diagram.selectedItems.nodes[0]?this.diagram.selectedItems.nodes[0]:this.diagram.selectedItems.connectors[0])&&this.tool instanceof VI||a&&"SwimLane"===a.shape.type)&&(a=this.diagram.nameTable[this.diagram.activeLabel.parentId]),a&&("Text"!==a.shape.type&&a.annotations.length>0||"Text"===a.shape.type)&&(c=AF((o=this.diagram.getWrapper(a.wrapper,this.diagram.activeLabel.id)).style,g,void 0,void 0,i=(i=a.wrapper.bounds.width90?i:90),s=Number(f.style.fontSize.split("px")[0]),v.length>1&&""===v[v.length-1]&&(c.height=c.height+s),d=this.diagram.scroller.transform,u=D3(this.diagram)?d.scale:1,l=(12>c.height?12:c.height)*u,p.style.left=(o.bounds.center.x+d.tx)*d.scale-(h=(90>(h=c.width)?90:h)*u)/2-2.5+"px",p.style.top=(o.bounds.center.y+d.ty)*d.scale-l/2-3+"px",p.style.width=h+"px",p.style.height=l+"px",f.style.minHeight="12px",f.style.minWidth="90px",f.style.width=h+"px",f.style.height=l+"px")},n.prototype.isAddTextNode=function(t,e){return!(!(this.tool instanceof VI||e)||(this.tool=null,t&&!kI(this.diagram)&&(this.diagram.drawingObject=void 0,this.diagram.currentDrawingObject=void 0),pF(this.diagram.nodes,t.id)||pF(this.diagram.connectors,t.id)))},n.prototype.checkEditBoxAsTarget=function(t){return!(!t.target||t.target.id!==this.diagram.element.id+"_editBox")},n.prototype.getMouseEventArgs=function(t,e,i,r){var s,o,a;if(e.position=t,i?(o=this.diagram.findObjectsUnderMouse(this.currentPosition,i),s=this.diagram.findTargetObjectUnderMouse(o,this.action,this.inAction,e.position,i)):"Drag"===this.action||"ConnectorSourceEnd"===this.action||"SegmentEnd"===this.action||"OrthoThumb"===this.action||"BezierSourceThumb"===this.action||"BezierTargetThumb"===this.action||"ConnectorTargetEnd"===this.action||-1!==this.action.indexOf("Rotate")||-1!==this.action.indexOf("Resize")?(s=this.diagram.selectedItems,!this.diagram.currentSymbol&&"Drag"===this.action&&s&&this.diagram.selectedItems.nodes.length>0&&"SwimLane"===this.diagram.selectedItems.nodes[0].shape.type&&(o=this.diagram.findObjectsUnderMouse(this.currentPosition),s=this.diagram.findObjectUnderMouse(o,this.action,this.inAction))):(o=this.diagram.findObjectsUnderMouse(this.currentPosition),s=this.diagram.findObjectUnderMouse(o,this.action,this.inAction)),s&&s.isHeader&&(this.eventArgs.actualObject=s=this.diagram.nameTable[s.parentId]),s){var l=void 0,h=void 0,c=void 0;if(((a=this.diagram.findElementUnderMouse(s,this.currentPosition,this.diagram,r))&&s.ports&&s.ports.length&&!tb(s,a)||!a||!s)&&o&&o.length&&i instanceof ei)for(l=i.connectors[0],c=o.length-1;c>=0;c--)if(((h=o[parseInt(c.toString(),10)])instanceof te||h instanceof de)&&l&&l.connectionPadding){if(a=this.diagram.findElementUnderMouse(s=h,this.currentPosition,this.diagram,r),l.constraints&qe.ConnectToNearByPort&&s&&s.ports&&s.ports.length&&tb(s,a))break;if((h instanceof te||h instanceof de)&&l&&l.connectionPadding&&h.wrapper.outerBounds.containsPoint(this.currentPosition)&&l.constraints&qe.ConnectToNearByNode&&!(l.constraints&qe.ConnectToNearByPort)){a=this.diagram.findElementUnderMouse(s=h,this.currentPosition,this.diagram,0);break}}}return i?(e.target=s,e.targetWrapper=a):(e.source=s,e.sourceWrapper=a),e.actualObject=this.eventArgs.actualObject,e.source instanceof ei&&void 0===e.actualObject&&(e.source.nodes.length>0||e.source.connectors.length>0)&&(e.actualObject=e.source.nodes.length>0?this.diagram.nameTable[e.source.nodes[0].id]:this.diagram.nameTable[e.source.connectors[0].id]),e.startTouches=this.touchStartList,e.moveTouches=this.touchMoveList,e},n.prototype.resetTool=function(){this.action="Select",this.hoverElement=null,this.hoverNode=null,this.tool=this.diagram.getTool(this.action),this.updateCursor()},n.prototype.updateTool=function(){this.action=this.currentPosition&&"Pan"!==this.action?"Pan":"Select"},n.prototype.getTool=function(t){switch(t){case"Select":return new $v(this.commandHandler,!0);case"Drag":return new fa(this.commandHandler);case"Rotate":return new Wx(this.commandHandler);case"LayoutAnimation":return new Tne(this.commandHandler);case"FixedUserHandle":return new xne(this.commandHandler,!0);case"Hyperlink":return new Q3(this.commandHandler);case"ResizeSouthEast":case"ResizeSouthWest":case"ResizeNorthEast":case"ResizeNorthWest":case"ResizeSouth":case"ResizeNorth":case"ResizeWest":case"ResizeEast":return new Pd(this.commandHandler,t);case"ConnectorSourceEnd":case"ConnectorTargetEnd":case"BezierSourceThumb":case"BezierTargetThumb":return new kd(this.commandHandler,t);case"SegmentEnd":case"OrthoThumb":return new qF(this.commandHandler,t);case"Draw":var e="shape",i=function ise(n){var t;return n&&(n.type?t="Connector":n.shape&&!n.type&&(t="Node")),t}(this.diagram.drawingObject);if("Node"===i&&"Text"===this.diagram.drawingObject.shape.type)return new VI(this.commandHandler);if("Connector"===i&&"Freehand"===this.diagram.drawingObject.type)return new One(this.commandHandler);if("Node"===i&&"Polygon"===this.diagram.drawingObject.shape[""+e]&&!this.diagram.drawingObject.shape.points)return new zl(this.commandHandler);if("Node"===i||"Node"===i&&"Polygon"===this.diagram.drawingObject.shape[""+e]&&this.diagram.drawingObject.shape.points)return new jI(this.commandHandler,this.diagram.drawingObject);if("Connector"===i&&"Polyline"===this.diagram.drawingObject.type)return new Rl(this.commandHandler);if("Connector"===i)return new pa(this.commandHandler,"ConnectorSourceEnd",this.diagram.drawingObject);break;case"Pan":return new Zv(this.commandHandler,!1);case"PinchZoom":return new Zv(this.commandHandler,!0);case"PortDrag":return new fa(this.commandHandler,"Port");case"PortDraw":return new pa(this.commandHandler,"ConnectorSourceEnd",this.diagram.drawingObject);case"LabelSelect":return new $v(this.commandHandler,!0,"LabelSelect");case"LabelDrag":return new Ane(this.commandHandler);case"LabelResizeSouthEast":case"LabelResizeSouthWest":case"LabelResizeNorthEast":case"LabelResizeNorthWest":case"LabelResizeSouth":case"LabelResizeNorth":case"LabelResizeWest":case"LabelResizeEast":return new Lne(this.commandHandler,t);case"LabelRotate":return new Nne(this.commandHandler)}return null},n.prototype.getCursor=function(t){var e=this.diagram.selectedItems.annotation?this.diagram.selectedItems.wrapper.children[0]:this.diagram.selectedItems;return function Dne(n,t){if(t+=360,t%=360,-1===n.indexOf("Resize"))return Vx[""+n];var e=Vx[""+n];return t>=0&&t<25||t>=160&&t<=205||t>=340&&t<=360?e:t>=25&&t<=70||t>=205&&t<=250?"n-resize"===e||"s-resize"===e?"ne-resize":"nw-resize"===e||"se-resize"===e?"n-resize":"e-resize"===e||"w-resize"===e?"nw-resize":"e-resize":t>=70&&t<=115||t>=250&&t<=295?"n-resize"===e||"s-resize"===e?"e-resize":"nw-resize"===e||"se-resize"===e?"ne-resize":"e-resize"===e||"w-resize"===e?"n-resize":"nw-resize":t>=115&&t<=155||t>=295&&t<=340?"n-resize"===e||"s-resize"===e?"nw-resize":"nw-resize"===e||"se-resize"===e?"e-resize":"e-resize"===e||"w-resize"===e?"ne-resize":Vx[""+n]:"n-resize"}(t,this.diagram.selectedItems.annotation?e.rotateAngle+e.parentTransform:e.rotateAngle)},n.prototype.findElementUnderMouse=function(t,e,i,r){return this.objectFinder.findElementUnderSelectedItem(t,e,i,r)},n.prototype.findObjectsUnderMouse=function(t,e){return this.objectFinder.findObjectsUnderMouse(t,this.diagram,this.eventArgs,e)},n.prototype.findObjectUnderMouse=function(t,e,i){return this.objectFinder.findObjectUnderMouse(this.diagram,t,e,i,this.eventArgs,this.currentPosition)},n.prototype.findTargetUnderMouse=function(t,e,i,r,s){return this.objectFinder.findObjectUnderMouse(this.diagram,t,e,i,this.eventArgs,r,s)},n.prototype.findActionToBeDone=function(t,e,i,r){return function Ine(n,t,e,i,r,s,o){if(s&&s.length>1&&r&&r.length>1)return"PinchZoom";if(i.currentSymbol)return"Drag";if("PortDraw"===i.eventHandler.action&&(i.tool&=~ri.DrawOnce),(E3(i)||kI(i))&&i.drawingObject)return"Draw";if($a(i)&&(l=i.selectedItems).wrapper&&qr(l.constraints,"UserHandle"))for(var h=0,c=l.userHandles;h=50&&(l.x=(a.points[parseInt(h.toString(),10)].x+a.points[h+1].x)/2,l.y=(a.points[parseInt(h.toString(),10)].y+a.points[h+1].y)/2,wr(e,l,n.hitPadding?n.hitPadding:10)))return"OrthoThumb"}else AI(n)&&console.warn('[WARNING] :: Module "ConnectorEditing" is not available in Diagram component! You either misspelled the module name or forgot to load it.');return null}(g,l,e,i);if("OrthoThumb"===S)return S;if(qr(l.constraints,"ConnectorSourceThumb")&&xI(g)&&S||qr(l.constraints,"ConnectorTargetThumb")&&TI(g)&&S)return S}}else{var b=i.selectedItems.handleSize/2/i.scroller.currentZoom,M=10/i.scroller.currentZoom,w=Bi();qi(w,f.rotateAngle+f.parentTransform,f.offsetX,f.offsetY);var C=f.offsetX-f.pivot.x*f.actualSize.width,D=f.offsetY-f.pivot.y*f.actualSize.height,A={x:C+(.5===f.pivot.x?2*f.pivot.x:f.pivot.x)*f.actualSize.width/2,y:D-30/i.scroller.currentZoom};A=Ke(w,A);var x=!!i.selectedItems.annotation,P=!(!x||!LI(i.selectedItems.annotation));if(qr(l.constraints,"Rotate")&&wr(e,A,M)&&i.selectedItems.thumbsConstraints&bt.Rotate){if(x&&P)return"LabelRotate";if(!x)return"Rotate"}if(u.Inflate(b),u.containsPoint(e)&&(S=function bne(n,t,e,i,r,s){var o;return 1===n.selectedItems.nodes.length&&0===n.selectedItems.connectors.length&&n.selectedItems.nodes[0].container&&(o=function Cne(n,t,e,i,r){var s=10/n.scroller.currentZoom,o=n.selectedItems,a=t.actualSize.width,l=t.actualSize.height,h=new Ne(i,r,t.style.strokeWidth,l),c=new Ne(i+a,r,t.style.strokeWidth,l),d=new Ne(i,r,a,t.style.strokeWidth),u=new Ne(i,r+l,a,t.style.strokeWidth),f=Dn(n,n.selectedItems.nodes[0],!0)?n.nameTable[n.selectedItems.nodes[0].parentId]:n.selectedItems.nodes[0];if(ga(o.constraints,"ResizeEast",o.thumbsConstraints,o)&&c.containsPoint(e,s))return"ResizeEast";if(ga(o.constraints,"ResizeSouth",o.thumbsConstraints,o)&&u.containsPoint(e,s))return"ResizeSouth";if("Grid"!==f.container.type){if(ga(o.constraints,"ResizeWest",o.thumbsConstraints,o)&&h.containsPoint(e,s))return"ResizeWest";if(ga(o.constraints,"ResizeNorth",o.thumbsConstraints,o)&&d.containsPoint(e,s))return"ResizeNorth"}return null}(n,t,e,r,s)),!o&&(!n.selectedItems.nodes[0]||!n.selectedItems.nodes[0].isPhase&&!n.selectedItems.nodes[0].isLane&&"SwimLane"!==n.selectedItems.nodes[0].shape.type)&&(o=function Ene(n,t,e,i,r,s){var o=40/n.scroller.currentZoom,a=n.selectedItems.handleSize/2/n.scroller.currentZoom,l=n.selectedItems,h=!!l.annotation;if(t.actualSize.width>=o&&t.actualSize.height>=o){if(ga(l.constraints,"ResizeSouthEast",l.thumbsConstraints,l)&&wr(e,Ke(i,{x:r+t.actualSize.width,y:s+t.actualSize.height}),a))return h?"LabelResizeSouthEast":"ResizeSouthEast";if(ga(l.constraints,"ResizeSouthWest",l.thumbsConstraints,l)&&wr(e,Ke(i,{x:r,y:s+t.actualSize.height}),a))return h?"LabelResizeSouthWest":"ResizeSouthWest";if(ga(l.constraints,"ResizeNorthEast",l.thumbsConstraints,l)&&wr(e,Ke(i,{x:r+t.actualSize.width,y:s}),a))return h?"LabelResizeNorthEast":"ResizeNorthEast";if(ga(l.constraints,"ResizeNorthWest",l.thumbsConstraints,l)&&wr(e,Ke(i,{x:r,y:s}),a))return h?"LabelResizeNorthWest":"ResizeNorthWest"}return ga(l.constraints,"ResizeEast",l.thumbsConstraints,l)&&wr(e,Ke(i,{x:r+t.actualSize.width,y:s+t.actualSize.height/2}),a)?h?"LabelResizeEast":"ResizeEast":ga(l.constraints,"ResizeWest",l.thumbsConstraints,l)&&wr(e,Ke(i,{x:r,y:s+t.actualSize.height/2}),a)?h?"LabelResizeWest":"ResizeWest":ga(l.constraints,"ResizeSouth",l.thumbsConstraints,l)&&wr(e,Ke(i,{x:r+t.actualSize.width/2,y:s+t.actualSize.height}),a)?h?"LabelResizeSouth":"ResizeSouth":ga(l.constraints,"ResizeNorth",l.thumbsConstraints,l)&&wr(e,Ke(i,{x:r+t.actualSize.width/2,y:s}),a)?h?"LabelResizeNorth":"ResizeNorth":null}(n,t,e,i,r,s)),o||null}(i,f,e,w,C,D),S))return S}}if(Lc(i)&&!n)return"Pan";if((o instanceof Es||o instanceof Tc)&&(!Lc(i)||Bv(i)||Fv(i))&&(S=function wne(n,t,e,i){if(Rx(t)&&(va(t,ci.Hover)||va(t,ci.Visible))){if(t.constraints&oi.Drag)return"PortDrag"}else if(zx(t)&&(va(t,ci.Hover)||va(t,ci.Visible))&&t.constraints&oi.Draw){n.drawingObject={};var r={type:"Orthogonal",sourcePortID:t.id};return n.drawingObject=r,n.tool|=ri.DrawOnce,n.currentDrawingObject=r,"PortDraw"}return"None"}(i,o),"None"!==S))return S;if((o instanceof Kn||o instanceof Or)&&!Lc(i)&&xd(o))return _r(i,o,void 0,t)&&ro(o)?"LabelDrag":"LabelSelect";if(null!==n){if(!(n instanceof te||n instanceof de))return"Select";if(t&&t.id){var L=t.id.split(n.id)[1];if(L&&L.match("^_icon"))return"LayoutAnimation"}if(t&&t.id)for(var O=void 0,N=0;N-1)return"FixedUserHandle";if(t instanceof ai&&t.hyperlink.link)return"Hyperlink";if(!ro(n)||!_r(i,n,!1)||void 0!==i.selectedItems.annotation)return n&&Lc(i)&&!PI(i)?"Pan":i.selectedItems.nodes.length&&i.selectedItems.nodes[0].isLane&&i.selectedItems.wrapper&&i.selectedItems.wrapper.bounds.containsPoint(e)?"Drag":"Select";if(n instanceof de&&!wr(e,n.sourcePoint,n.hitPadding)&&!wr(e,n.targetPoint,n.hitPadding)||!(n instanceof de))return"Drag"}return"Select"}(t,e,this.currentPosition,this.diagram,this.touchStartList,this.touchMoveList,r)},n.prototype.updateContainerBounds=function(t){var e=!1;if(this.diagram.selectedObject.helperObject&&this.diagram.selectedObject.actualObject)for(var i=this.diagram.selectedObject.actualObject,r=this.diagram.selectedObject.actualObject instanceof ei?i.nodes:[i],s=0;si.y&&(h+=u>0?-1:1,u+=u>0?-1:1):i&&e.wrapper.offsetYi.x&&(h+=u>0?-1:1,u+=u>0?-1:1):i&&e.wrapper.offsetX1)for(var S=t.offsetX-this.diagram.selectedItems.offsetX,b=t.offsetY-this.diagram.selectedItems.offsetY,M=t.rotateAngle-this.diagram.selectedItems.rotateAngle,w=0;w-1){var A=c.children;A.splice(A.indexOf(o.id),1),this.diagram.nameTable[o.id].parentId="",i=!0,c.wrapper.children.splice(D,1)}}if(function Sne(n,t,e,i){var r=n,s=e.nameTable[r.parentId],o=e.nameTable[r.parentId];if(t&&o&&o.container&&"Stack"===o.container.type&&t.container&&"Stack"===t.container.type&&o.id!==t.parentId){var a=o.wrapper.children.indexOf(r.wrapper);a>-1&&(e.nameTable[r.id].parentId=t.id,o.wrapper.children.splice(a,1))}if(t&&t.parentId&&r.parentId&&"Drag"===i&&o.container&&"Stack"===o.container.type){var l=s.wrapper.children.indexOf(t.wrapper),h=s.wrapper.children.indexOf(r.wrapper),c={targetIndex:l,target:t,sourceIndex:h,source:n};s.wrapper.children.splice(h,1),s.wrapper.children.splice(l,0,r.wrapper),e.commandHandler.addHistoryEntry({type:"StackChildPositionChanged",redoObject:{targetIndex:h,target:t,sourceIndex:l,source:n},undoObject:c,category:"Internal"})}}(o,h,this.diagram,this.action),(c=Dn(this.diagram,o)?this.diagram.nameTable[o.parentId]:this.diagram.nameTable[o.parentId]||o)&&c.container&&"Canvas"===c.container.type&&(c.wrapper.maxWidth=c.maxWidth=c.wrapper.actualSize.width,c.wrapper.maxHeight=c.maxHeight=c.wrapper.actualSize.height,e=!0),Dn(this.diagram,o,!0)&&c&&"Canvas"===c.container.type)if(this.diagram.selectedItems.nodes.length>1)for(w=0;w0)for(var i=0;i0&&e.columnIndex>0||l&&e.isLane)){if("Horizontal"===t.container.orientation&&e.isPhase&&e.wrapper.width>e.maxWidth&&(e.maxWidth=e.wrapper.width,e.wrapper.maxWidth=e.wrapper.width),h.updateColumnWidth(e.columnIndex,r.width,!0,c),Fx(this.diagram,e,t),e.isPhase){var p=this.diagram.nameTable[""+t.shape.phases[e.columnIndex].header.id];p.maxWidth0?(r=new rp(t,"",u),t.shape.classShape.attributes.push(r)):i.id.includes("_umlMethods")&&t.shape.classShape.methods.length>0&&(s=new lm(t,"",u),t.shape.classShape.methods.push(s))),"Interface"===t.shape.classifier&&(i.id.includes("_umlProperty")&&t.shape.interfaceShape.attributes.length>0?(r=new rp(t,"",u),t.shape.classShape.attributes.push(r)):i.id.includes("_umlMethods")&&t.shape.interfaceShape.methods.length>0&&(s=new lm(t,"",u),t.shape.interfaceShape.methods.push(s))),"Enumeration"===t.shape.classifier&&i.id.includes("_umlMember")&&t.shape.enumerationShape.members.length>0){var f=new nb(t,"",u);t.shape.enumerationShape.members.push(f)}t.wrapper.children.indexOf(c.wrapper),this.diagram.enableServerDataBinding(!0),this.diagram.add(c),this.diagram.updateConnectorEdges(t),this.diagram.clearSelection(),this.diagram.select([this.diagram.nameTable[c.id]]),this.diagram.endGroupAction(),this.diagram.startTextEdit()}}},n}(),Boe=function(){function n(){}return n.prototype.findObjectsUnderMouse=function(t,e,i,r,s){var o=[];r&&r instanceof ei&&r.nodes.length+r.connectors.length===1&&(r=r.nodes[0]||r.connectors[0]).children&&0===r.children.length&&(i.actualObject=r);for(var a,l,h,c,p,d=r&&r instanceof de&&(r.constraints&qe.ConnectToNearByNode||r.constraints&qe.ConnectToNearByPort)&&r.connectionPadding||0,f={},g=0,v=e.spatialSearch.findObjects(new Ne(t.x-50-d,t.y-50-d,100+d,100+d));g-1&&o.splice(T,1),"UmlClassifier"===y.shape.type&&y.container&&"Stack"===y.container.type&&(T=o.indexOf(e.nameTable[e.nameTable[y.id].wrapper.children[0].id]))>-1&&o.splice(T,1)}for(var z=0;zs.zIndex&&(t[parseInt(r.toString(),10)]=l),r>0&&i&&a&&(a.isLane||a.isPhase||a.isHeader)&&t[parseInt(r.toString(),10)].zIndex=2)for(var d=t.length-1;d>=0;d--)if(t[parseInt(d.toString(),10)].parentId){var u=nm(t[parseInt(d.toString(),10)],e,""),f=nm(t[d-1],e,""),g=e.nameTable[""+f];g&&u!==f&&e.nameTable[""+u].zIndex=0;p--){d=Kf(e[parseInt(p.toString(),10)],!1),c=Kf(e[parseInt(p.toString(),10)],!0);var g=t[""+l].tool,v=this.findTargetElement(e[parseInt(p.toString(),10)].wrapper,o,t,void 0);if("Draw"===i&&v&&(e[parseInt(p.toString(),10)]instanceof te||e[parseInt(p.toString(),10)]instanceof de)&&!tb(e[parseInt(p.toString(),10)],v)&&(g&&"ConnectorSourceEnd"===g[""+h]&&!Ph(e[parseInt(p.toString(),10)])||g&&"ConnectorTargetEnd"===g[""+h]&&!ua(e[parseInt(p.toString(),10)])))return u;if(e[parseInt(p.toString(),10)]instanceof te||e[parseInt(p.toString(),10)]instanceof de&&(Ph(e[parseInt(p.toString(),10)])||Td(d)||ua(e[parseInt(p.toString(),10)])||kh(c)||"PortDraw"===i&&g instanceof kd&&"ConnectorTargetEnd"===g[""+h]&&(ua(e[parseInt(p.toString(),10)])||kh(c))))return u=e[parseInt(p.toString(),10)],f&&(u=this.isTarget(u,t,i)),s.actualObject=u,u}else if("ConnectorTargetEnd"===i&&a){for(p=e.length-1;p>=0;p--)if(c=Kf(e[parseInt(p.toString(),10)],!0),(e[parseInt(p.toString(),10)]instanceof te||e[parseInt(p.toString(),10)]instanceof de)&&(ua(e[parseInt(p.toString(),10)])||kh(c)))return u=e[parseInt(p.toString(),10)],u=this.isTarget(u,t,i),s.actualObject=u,u}else{if(a&&("Drag"===i||t[""+l].tool instanceof fa)){var y=0;for(p=0;p=S.zIndex?u:S,y=Math.max(y,S.zIndex)):y=(u=S).zIndex)}return u&&"Bpmn"===u.shape.type&&(t.selectedItems.nodes.length>0&&"Bpmn"===t.selectedItems.nodes[0].shape.type||(u=null)),u&&(s.actualObject=u),u}if("Select"!==i&&"Pan"!==i||!t[""+l].tool)if("Pan"===i||"LayoutAnimation"===i){for(p=e.length-1;p>=0;p--)if((e[parseInt(p.toString(),10)]instanceof te||e[parseInt(p.toString(),10)]instanceof de)&&(v=this.findTargetElement(e[parseInt(p.toString(),10)].wrapper,o,t,void 0),"Pan"===i||v&&(v.id.match("_icon_content_shape$")||v.id.match("_icon_content_rect$"))))return e[parseInt(p.toString(),10)]}else u=e[e.length-1],s&&u&&(s.actualObject=u);else{for(p=e.length-1;p>=0;p--)if(e[parseInt(p.toString(),10)]instanceof de){var b=e[p-1];if(e[p-1]instanceof te&&b.ports){if((v=this.findTargetElement(b.wrapper,o,t,void 0))&&(v.id.match("_icon_content_shape$")||v.id.match("_icon_content_rect$")))return b;for(var M=0;M=0;s--){var o=t.children[parseInt(s.toString(),10)];if(o&&o.outerBounds.containsPoint(e,r||0))if(o.visible){if(o instanceof Cs){var a=this.findTargetElement(o,e,i);if(a)return a}var l="Clip"===o.style.textOverflow||"Ellipsis"===o.style.textOverflow;if(o.bounds.containsPoint(e,r||0)&&!l)return o;if(t.bounds.containsPoint(e,r||0)&&l)return o}else if(o instanceof Ze&&t&&t.id){var h=void 0;if(t.id.includes("group_container")){var c=t.id.slice(0,-15);h=i.getObject(c)}else h=i.getObject(t.id);if(KI(h,o.id))return o}}return t.bounds.containsPoint(e,r)&&"none"!==t.style.fill?t:null},n}(),Foe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),sp=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},$F=function(n){function t(e,i,r,s){var o=n.call(this,e,i,r,s)||this;return o.objectZIndex=-1,o.zIndexTable={},o.objects=[],o}return Foe(t,n),sp([I("")],t.prototype,"id",void 0),sp([I(!0)],t.prototype,"visible",void 0),sp([I(!1)],t.prototype,"lock",void 0),sp([I()],t.prototype,"objects",void 0),sp([I()],t.prototype,"addInfo",void 0),sp([I(-1)],t.prototype,"zIndex",void 0),t}(Ee),bT=function(n,t,e,i){return new(e||(e=Promise))(function(r,s){function o(h){try{l(i.next(h))}catch(c){s(c)}}function a(h){try{l(i.throw(h))}catch(c){s(c)}}function l(h){h.done?r(h.value):new e(function(c){c(h.value)}).then(o,a)}l((i=i.apply(n,t||[])).next())})},MT=function(n,t){var i,r,s,o,e={label:0,sent:function(){if(1&s[0])throw s[1];return s[1]},trys:[],ops:[]};return o={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function a(h){return function(c){return function l(h){if(i)throw new TypeError("Generator is already executing.");for(;e;)try{if(i=1,r&&(s=2&h[0]?r.return:h[0]?r.throw||((s=r.return)&&s.call(r),0):r.next)&&!(s=s.call(r,h[1])).done)return s;switch(r=0,s&&(h=[2&h[0],s.value]),h[0]){case 0:case 1:s=h;break;case 4:return e.label++,{value:h[1],done:!1};case 5:e.label++,r=h[1],h=[0];continue;case 7:h=e.ops.pop(),e.trys.pop();continue;default:if(!(s=(s=e.trys).length>0&&s[s.length-1])&&(6===h[0]||2===h[0])){e=0;continue}if(3===h[0]&&(!s||h[1]>s[0]&&h[1]1)for(var i=0;i-1)return e[parseInt(i.toString(),10)];return this.diagram.activeLayer},n.prototype.getLayer=function(t){for(var e=this.diagram.layers,i=0;i=0;o--)this.diagram.unSelect(this.diagram.nameTable[s[parseInt(o.toString(),10)]]),this.diagram.remove(this.diagram.nameTable[s[parseInt(o.toString(),10)]]),"default_layer"!==i.id&&this.diagram.activeLayer.id===t&&(this.diagram.activeLayer=this.diagram.layers[this.diagram.layers.length-1]);delete this.diagram.layerZIndexTable[i.zIndex],this.diagram.layers.splice(r,1),"SVG"!==this.diagram.mode&&this.diagram.refreshDiagramLayer()}},n.prototype.moveObjects=function(t,e){this.diagram.startGroupAction();for(var i={},r=[],s=0;s-1){if(r=[],(h=this.diagram.nameTable[""+s]).children)for(var p=0,g=h.children;p0){for(var y=void 0,S=0,b=r;S0)for(var r=0;r0)for(r=0;r0){t=t.concat(this.diagram.selectedItems.connectors);for(var i=0;i0)for(t=t.concat(this.diagram.selectedItems.nodes),i=0;i0){for(var i=0,r=t.shape.activity.subProcess.processes;i0&&this.copyProcesses(this.processTable[""+s])}this.clipboardData.processTable=this.processTable}},n.prototype.group=function(){this.oldSelectedObjects=im(this.diagram);var e=this.diagram.isProtectedOnChange;this.diagram.protectPropertyChange(!0),this.diagram.diagramActions=this.diagram.diagramActions|ee.Group;var r={};r.id="group"+Qe(),(r=new te(this.diagram,"nodes",r,!0)).children=[];for(var s=this.diagram.selectedItems.nodes.concat(this.diagram.selectedItems.connectors).sort(function(h,c){return h.zIndex-c.zIndex}),o=0;o0){var a=this.diagram.add(r);a&&this.select(a),this.addHistoryEntry({type:"Group",undoObject:r,redoObject:r,category:"Internal"}),this.diagram.diagramActions=this.diagram.diagramActions&~ee.Group,this.diagram.protectPropertyChange(e)}},n.prototype.unGroup=function(t){var i=this.diagram.isProtectedOnChange;this.diagram.protectPropertyChange(!0),this.diagram.diagramActions=this.diagram.diagramActions|ee.Group;var r=[];t?r.push(t):r=this.diagram.selectedItems.nodes,this.diagram.startGroupAction();for(var s=0;s0&&this.diagram.removePorts(o,o.ports),o.annotations&&o.annotations.length>0&&!ce()&&this.diagram.removeLabels(o,o.annotations);for(var c=this.diagram.nameTable[o.parentId],d=o.children.length-1;d>=0;d--)this.diagram.nameTable[o.children[parseInt(d.toString(),10)]].parentId="",this.diagram.deleteChild(this.diagram.nameTable[o.children[parseInt(d.toString(),10)]],o),o.parentId&&o.children[parseInt(d.toString(),10)]&&this.diagram.addChild(c,o.children[parseInt(d.toString(),10)]);this.resetDependentConnectors(o.inEdges,!0),this.resetDependentConnectors(o.outEdges,!1),this.diagram.diagramActions&ee.UndoRedo||this.addHistoryEntry({type:"UnGroup",undoObject:a,redoObject:a,category:"Internal"}),o.parentId&&this.diagram.deleteChild(o,c)}this.diagram.removeNode(o,l),this.clearSelection()}this.diagram.endGroupAction(),this.diagram.diagramActions=this.diagram.diagramActions&~ee.Group,this.diagram.protectPropertyChange(i)},n.prototype.resetDependentConnectors=function(t,e){for(var i=0;i0&&(g=!1)}if(g){var y=this.cloneConnector(f,i);c.push(y),o[h.id]=y.id}}else{var S=this.cloneNode(h,i);if(c.push(S),S){o[h.id]=S.id;var b=h.inEdges;if(b)for(var M=0,w=b;M0)for(var u=0;u0)for(r=t.segments,s=0;s0&&this.diagram.drawingObject&&"Bezier"===this.diagram.drawingObject.type&&(t.segments=[]);var e=this.diagram.add(t);"SVG"!==this.diagram.mode&&this.diagram.refreshDiagramLayer(),this.selectObjects([e]),t&&!kI(this.diagram)&&(this.diagram.tool&=~ri.DrawOnce,this.diagram.currentDrawingObject=void 0)},n.prototype.enableServerDataBinding=function(t){this.diagram.enableServerDataBinding(t)},n.prototype.addText=function(t,e){var i=this.diagram.findElementUnderMouse(t,e,this.diagram);this.diagram.startTextEdit(t,i instanceof ai?i.id.split("_")[1]:void 0)},n.prototype.isUserHandle=function(t){var e=this.diagram.selectedItems;if(e.wrapper&&qr(e.constraints,"UserHandle"))for(var i=0,r=e.userHandles;i0&&t[0]&&t[0].isLane)for(s=this.diagram.getObject(t[0].parentId),t[0].shape.header=[],a=0;a1||e&&1===t.length)){if(1!==t.length)return[2];this.clearSelection()}if(!(u||d||1!==t.length||e&&$a(this.diagram)))return this.clearSelection(),[2]}if(!r.cancel){for(f=0;f0||e)&&p.children&&!p.parentId)for(g=0;g0||e,!0)}else this.select(p,f>0||e,!0);void 0===i&&(i=c),r={oldValue:i||[],newValue:this.getSelectedObject(),cause:this.diagram.diagramActions,state:"Changed",type:"Addition",cancel:!1},this.diagram.renderSelector(e||t&&t.length>1),ce()||this.diagram.triggerEvent(Ce.selectionChange,r),this.diagram.enableServerDataBinding(!0)}return[2]})})},n.prototype.findParent=function(t){return t.parentId&&this.findParent(t=this.diagram.nameTable[t.parentId]),t},n.prototype.selectProcesses=function(t){if(this.hasProcesses(t))for(var e=t.shape.activity.subProcess.processes,i=0;i0)},n.prototype.select=function(t,e,i){var r=this.getObjectLayer(t.id);if(xd(t)&&!(t instanceof ei)&&!_r(this.diagram,t)&&r&&!r.lock&&r.visible&&t.wrapper.visible){(e=!!$a(this.diagram)&&e)||this.clearSelection(),this.diagram.enableServerDataBinding(!1);var s=this.diagram.selectedItems;if(t instanceof te?s.nodes.push(t.isHeader?this.diagram.nameTable[t.parentId]:t):s.connectors.push(t),s.selectedObjects.push(t),e)s.wrapper.rotateAngle=s.rotateAngle=0,s.wrapper.children.push(t.wrapper);else if(s.init(this.diagram),1===s.nodes.length&&0===s.connectors.length){var l=_x(this.diagram,s);l&&(s.wrapper.children[0]=l),s.rotateAngle=s.nodes[0].rotateAngle,s.wrapper.rotateAngle=s.nodes[0].rotateAngle,s.wrapper.pivot=s.nodes[0].pivot}i||this.diagram.renderSelector(e),this.diagram.enableServerDataBinding(!0)}},n.prototype.labelSelect=function(t,e){this.oldSelectedObjects=im(this.diagram);var i=this.diagram.selectedItems,r=this.diagram.allowServerDataBinding;this.diagram.allowServerDataBinding=!1,i.nodes=i.connectors=[],this.diagram.allowServerDataBinding=r,t instanceof te?i.nodes[0]=t:i.connectors[0]=t,i.annotation=this.findTarget(e,t),i.init(this.diagram),this.diagram.renderSelector(!1)},n.prototype.unSelect=function(t){var e=this.diagram.selectedItems.nodes.concat(this.diagram.selectedItems.connectors),i=e.filter(function(a){return a.id!==t.id}),r={oldValue:e,newValue:i,cause:this.diagram.diagramActions,state:"Changing",type:"Removal",cancel:!1};if(this.diagram.currentSymbol||ce()||this.diagram.triggerEvent(Ce.selectionChange,r),_r(this.diagram,t)){var s=this.diagram.selectedItems,o=void 0;t instanceof te?(o=s.nodes.indexOf(t,0),s.nodes.splice(o,1)):(o=s.connectors.indexOf(t,0),s.connectors.splice(o,1)),o=s.selectedObjects.indexOf(t,0),s.selectedObjects.splice(o,1),(r={oldValue:e,newValue:i,cause:this.diagram.diagramActions,state:"Changed",type:"Removal",cancel:(r={oldValue:e,newValue:i,cause:this.diagram.diagramActions,state:"Changed",type:"Removal",cancel:!1}).cancel}).cancel||(o=s.wrapper.children.indexOf(t.wrapper,0),s.wrapper.children.splice(o,1),this.diagram.updateSelector(),this.diagram.currentSymbol||this.diagram.triggerEvent(Ce.selectionChange,r))}},n.prototype.moveSvgNode=function(t,e){var i=this.diagram.nameTable[""+e];if("Native"===i.shape.type||"HTML"===i.shape.type)this.updateNativeNodeIndex(t,e);else{var r=xt(e+"_groupElement",this.diagram.element.id),s=xt(t+"_groupElement",this.diagram.element.id);r.parentNode.insertBefore(s,r)}},n.prototype.moveAfterSvgNode=function(t,e){var i=this.diagram.nameTable[""+e];if(!i||"HTML"!==i.shape.type&&"Native"!==i.shape.type)a=xt(e+"_groupElement",this.diagram.element.id),o=xt(t+"_groupElement",this.diagram.element.id),a.insertAdjacentElement("afterend",o);else for(var r=0;rd&&"SwimLane"!==p.shape.type){var S=$(p);p.zIndex=d-((-1!==i.indexOf(p)?i.indexOf(p):0)+1),p.children&&(d=this.findLowestZIndex(p,c)||d),this.triggerOrderCommand(S,p,p),p.children&&this.updateGroupZindex(p,"SendToBack",d)}else"SwimLane"===p.shape.type&&(y=this.swapZIndexObjects(a,h,r,g));if("SVG"===this.diagram.mode){for(var M="SwimLane"!==this.diagram.nameTable[""+r].shape.type?d:y,w=h[parseInt(M.toString(),10)];!w&&Md)&&(d=f.zIndex)}for(var p=JSON.parse(JSON.stringify(l)),v=Number(Object.keys(l).sort(function(wo,Ul){return Number(wo)-Number(Ul)}).reverse()[0]),y=this.diagram.nameTable[""+e].zIndex,S=[],M=0;M<=v;M++)S.push(l[parseInt(M.toString(),10)]);if("SwimLane"===this.diagram.nameTable[""+e].shape.type)for(var C=v;C>=y;C--)if(l[parseInt(C.toString(),10)]&&this.diagram.nameTable[l[parseInt(C.toString(),10)]].parentId!==e){v=C;break}var D=this.diagram.nameTable[""+e];if(D.zIndexx&&(x=L.zIndex)}}else x=d;D.zIndex=x+((-1!==r.indexOf(D)?r.indexOf(D):0)+1),this.triggerOrderCommand(A,D,D)}else if("SwimLane"===D.shape.type){for(var O=0,N=-1,T=0,z=0,U=JSON.parse(JSON.stringify(l)),B=0;B<=y;B++)if(l[parseInt(B.toString(),10)]&&this.diagram.nameTable[l[parseInt(B.toString(),10)]].parentId===e&&-1===N){N=B,T=B;break}for(var j=0;j<=v;j++)p[parseInt(j.toString(),10)]&&p[parseInt(j.toString(),10)]!==e&&this.diagram.nameTable[p[parseInt(j.toString(),10)]].parentId!==e&&this.diagram.nameTable[p[parseInt(j.toString(),10)]].zIndex>=this.diagram.nameTable[""+e].zIndex&&O++;for(var ue=N,fe=0;fe<=O;fe++){for(;!l[parseInt(ue.toString(),10)];)ue++;z=this.diagram.nameTable[l[parseInt(ue.toString(),10)]].zIndex,ue++}for(var Me=z;Me<=v;Me++){for(;!U[parseInt(N.toString(),10)];)N++;for(;!l[parseInt(Me.toString(),10)];)Me++;l[parseInt(Me.toString(),10)]=U[parseInt(N.toString(),10)],this.diagram.nameTable[l[parseInt(Me.toString(),10)]].zIndex=Me,N++}l[parseInt(v.toString(),10)]=this.diagram.nameTable[""+e].id,this.diagram.nameTable[""+e].zIndex=v,ue=y+1;for(var De=T,xe=0;xe0&&("Native"===cr[0].shape.type||"HTML"===cr[0].shape.type)){for(Ci.parentNode.removeChild(Ci),De=0;De0?r[0]:null},n.prototype.findLowestZIndex=function(t,e){var r=this.diagram.nodes.filter(function(s){return-1!==e.indexOf(s.id)}).filter(function(s){return""===s.parentId&&s.id!==t.id}).map(function(s){return s.zIndex});return r.sort(function(s,o){return s-o}),r.length>0?r[0]:null},n.prototype.triggerOrderCommand=function(t,e,i){var s={zIndex:$(t).zIndex},o={zIndex:e.zIndex},a={element:i,cause:this.diagram.diagramActions,diagramAction:this.diagram.getDiagramAction(this.diagram.diagramActions),oldValue:s,newValue:o};this.diagram.triggerEvent(Ce.propertyChange,a)},n.prototype.checkGroupNode=function(t,e,i){return i[""+e].parentId===i[""+t].parentId},n.prototype.sortByZIndex=function(t,e,i){if("BringForward"===i){var r=e||"zIndex";t=t.sort(function(o,a){return a[""+r]-o[""+r]})}else{var s=e||"zIndex";t=t.sort(function(o,a){return o[""+s]-a[""+s]})}return t},n.prototype.orderCommands=function(t,e,i){var r=this,s=e.nodes;if(s=s.concat(e.connectors),t)if("SendBackward"===i)for(var o=0;oa}),S=v.filter(function(D){return D0?Math.max.apply(Math,S):a,M=y.length>0?Math.min.apply(Math,y):a;if(a!==M){var w=c.zIndexTable[parseInt(M.toString(),10)],C=c.zIndexTable[parseInt(a.toString(),10)];this.moveSvgNode(C,w)}else"SendToBack"===i&&(w=c.zIndexTable[parseInt(a.toString(),10)],C=c.zIndexTable[parseInt(b.toString(),10)],this.moveAfterSvgNode(w,C))}}else this.diagram.refreshCanvasLayers()}},n.prototype.swapDomOrder=function(t,e){if(t){var i=this.diagram.getObject(e);if("Native"===i.shape.type||"HTML"===i.shape.type)this.updateNativeNodeIndex(e,t),this.updateNativeNodeIndex(t,e);else{var r=xt(e+"_groupElement",this.diagram.element.id),s=xt(t+"_groupElement",this.diagram.element.id);r.parentNode.insertBefore(r,s),r.parentNode.insertBefore(s,r)}}},n.prototype.sendForward=function(t){var e=this;if(this.diagram.protectPropertyChange(!0),$a(this.diagram)||t){$(t||(this.diagram.selectedItems.nodes.length?this.diagram.selectedItems.nodes[0]:this.diagram.selectedItems.connectors[0]));var s=t&&t.id,o=this.diagram.layers.indexOf(this.getObjectLayer(s=s||(this.diagram.selectedItems.nodes.length?this.diagram.selectedItems.nodes[0].id:this.diagram.selectedItems.connectors[0].id))),a=$(this.diagram.nameTable),h=(parseInt(o.toString(),10),this.diagram.nameTable[""+s]),c=[],d=this.diagram.spatialSearch.findObjects(h.wrapper.bounds);d.length>2&&(d=this.sortByZIndex(d,void 0,"BringForward"));for(var u=0,f=d;u=0;p--)this.diagram.nameTable[c[parseInt(p.toString(),10)].id].parentId===s&&c.splice(p,1);if(c.length>0){var y=this.diagram.nameTable[c[c.length-1].id];if(y.parentId){var b=nm(y,this.diagram,""),M=this.diagram.nameTable[""+b];M.id!==s&&(c[0]=M)}var w={};for(p=0;p0&&(Object.values(O).forEach(function(ue){ue>=T&&N.push(ue)}),0!==N.length&&this.updateZIndexBySendForward(h,N,o))}var z=[];if(Object.keys(this.changedNodeZIndexes).forEach(function(ue){if((a[""+ue]?a[""+ue].zIndex:null)!==e.changedNodeZIndexes[""+ue]){var De=$(a[""+ue]);z.push(De)}}),this.updateLayerZindexTable(o),L.nodes.splice(0,L.nodes.length),z.forEach(function(ue){var fe=$(ue);L.nodes.push(fe)}),"SVG"===this.diagram.mode){var U=c[c.length-1].id,B=c[c.length-1];B&&!("HTML"===B.shape.type||"Native"===B.shape.type)&&this.moveAfterSvgNode(s,U),this.updateNativeNodeIndex(U,s)}else this.diagram.refreshCanvasLayers();var j=[];Object.keys(this.changedNodeZIndexes).forEach(function(ue){if((a[""+ue]?a[""+ue].zIndex:null)!==e.changedNodeZIndexes[""+ue]){var De=$(e.diagram.nameTable[""+ue]);j.push(De)}});var Q=$(this.diagram.selectedItems);Q.nodes.splice(0,Q.nodes.length),j.forEach(function(ue){var fe=$(ue);Q.nodes.push(fe)}),this.diagram.diagramActions&ee.UndoRedo||this.addHistoryEntry({type:"SendForward",category:"Internal",undoObject:L,redoObject:Q}),this.diagram.endGroupAction()}}this.diagram.protectPropertyChange(!1)},n.prototype.updateZIndexBySendForward=function(t,e,i){var r=$(t);t.zIndex=Math.min.apply(Math,e);var a,s=Math.min.apply(Math,e),o=Math.min.apply(Math,e),l=this.diagram.layers[parseInt(i.toString(),10)].objects,h=this.diagram.nodes.filter(function(S){return-1!==l.indexOf(S.id)});t.children&&this.updateGroupZindex(t,"BringForward",t.zIndex);var c=h.filter(function(S){return S.zIndex===Math.min.apply(Math,e)&&S.id!==t.id});if(c&&c.length>0&&c[0].children){for(var d=Math.min.apply(Math,e),u=0;uo&&g!==t&&g.parentId!==t.id&&c&&c.length>0&&g.parentId!==c[0].id){var v=$(g);g.zIndex=a+1,a++,this.triggerOrderCommand(v,g,g)}var y=g.zIndex;this.changedNodeZIndexes[g.id]=(this.changedNodeZIndexes.hasOwnProperty(g.id),y)}},n.prototype.arrangeZIndexForLowerNodes=function(t,e,i){var r=i.filter(function(o){return o.zIndex<=t&&o.parentId!==e.id});r.sort(function(o,a){return a.zIndex-o.zIndex});for(var s=0;se&&(e=r.zIndex)}return e},n.prototype.sendBackward=function(t){var e=this;if(this.diagram.protectPropertyChange(!0),$a(this.diagram)||t){$(t||(this.diagram.selectedItems.nodes.length?this.diagram.selectedItems.nodes[0]:this.diagram.selectedItems.connectors[0]));var s=t&&t.id,o=this.diagram.layers.indexOf(this.getObjectLayer(s=s||(this.diagram.selectedItems.nodes.length?this.diagram.selectedItems.nodes[0].id:this.diagram.selectedItems.connectors[0].id))),a=$(this.diagram.nameTable),h=(parseInt(o.toString(),10),this.diagram.nameTable[""+s]),c=[],d=this.diagram.spatialSearch.findObjects(h.wrapper.bounds);d.length>2&&(d=this.sortByZIndex(d));for(var u=0,f=d;uNumber(p.zIndex)&&""===p.parentId&&h.wrapper.bounds.intersects(p.wrapper.bounds)&&c.push(p);for(var p=c.length-1;p>=0;p--)(v=this.diagram.nameTable[c[parseInt(p.toString(),10)].id]).parentId===s&&c.splice(p,1);if(c.length>0){var v;if((v=this.diagram.nameTable[c[c.length-1].id]).parentId){var S=nm(v,this.diagram,""),b=this.diagram.nameTable[""+S];s!==b.id&&(c[c.length-1]=b)}var M={};for(p=0;p0&&(Object.values(L).forEach(function(fe){fe<=N&&O.push(fe)}),0!==O.length&&this.updateZIndexBySendBackward(h,O,o))}var T=[];if(Object.keys(this.changedNodeZIndexes).forEach(function(fe){if((a[""+fe]?a[""+fe].zIndex:null)!==e.changedNodeZIndexes[""+fe]){var xe=$(a[""+fe]);T.push(xe)}}),this.updateLayerZindexTable(o),P.nodes.splice(0,P.nodes.length),T.forEach(function(fe){var Me=$(fe);P.nodes.push(Me)}),"SVG"===this.diagram.mode){var z=c[c.length-1].id,U=c[c.length-1];U&&"HTML"!==U.shape.type&&"Native"!==U.shape.type&&this.moveSvgNode(s,z);var B=this.diagram.nameTable[""+z];B.children&&B.children.length>0?this.updateNativeNodeIndex(s):this.updateNativeNodeIndex(s,z)}else this.diagram.refreshCanvasLayers();var j=[];Object.keys(this.changedNodeZIndexes).forEach(function(fe){if((a[""+fe]?a[""+fe].zIndex:null)!==e.changedNodeZIndexes[""+fe]){var xe=$(e.diagram.nameTable[""+fe]);j.push(xe)}});var Q=$(this.diagram.selectedItems);Q.nodes.splice(0,Q.nodes.length),j.forEach(function(fe){var Me=$(fe);Q.nodes.push(Me)}),this.diagram.diagramActions&ee.UndoRedo||this.addHistoryEntry({type:"SendBackward",category:"Internal",undoObject:P,redoObject:Q}),this.diagram.endGroupAction()}}this.diagram.protectPropertyChange(!1)},n.prototype.updateZIndexBySendBackward=function(t,e,i){var r=$(t);t.zIndex=Math.max.apply(Math,e);var f,s=t.zIndex,o=Math.max.apply(Math,e),a=this.diagram.layers[parseInt(i.toString(),10)].objects,l=this.diagram.nodes.filter(function(S){return-1!==a.indexOf(S.id)}),h=l.filter(function(S){return S.zIndex===Math.max.apply(Math,e)&&S.id!==t.id});if(h&&h.length>0&&h[0].children)for(var c=Math.max.apply(Math,e),d=0;d0&&g.parentId!==h[0].id){var v=$(g);g.zIndex=f-1,f--,this.triggerOrderCommand(v,g,g)}var y=g.zIndex;this.changedNodeZIndexes[""+g.id]=(this.changedNodeZIndexes.hasOwnProperty(g.id),y)}},n.prototype.findLowestChildZIndex=function(t){for(var e=t.zIndex,i=0;i0),this.selectObjects([t],!0))},n.prototype.clearSelection=function(t,e){return bT(this,void 0,void 0,function(){var i,r,s,o;return MT(this,function(a){return i=this.diagram.allowServerDataBinding,this.diagram.enableServerDataBinding(!1),$a(this.diagram)&&(r=this.diagram.selectedItems,s=this.getSelectedObject(),this.diagram.currentSymbol&&(this.diagram.previousSelectedObject=s),o={oldValue:s,newValue:[],cause:this.diagram.diagramActions,state:"Changing",type:"Removal",cancel:!1},t&&(ce()||this.diagram.triggerEvent(Ce.selectionChange,o)),o.cancel||(r.offsetX=0,r.offsetY=0,r.width=0,r.height=0,r.rotateAngle=0,r.nodes=[],r.connectors=[],r.wrapper=null,r.annotation=void 0,r.selectedObjects=[],this.diagram.clearSelectorLayer(),t&&(o={oldValue:s,newValue:[],cause:this.diagram.diagramActions,state:"Changed",type:"Removal",cancel:!1},ce()||this.diagram.triggerEvent(Ce.selectionChange,o))),this.diagram.enableServerDataBinding(i)),[2]})})},n.prototype.clearSelectedItems=function(){this.clearSelection((this.diagram.selectedItems.nodes?this.diagram.selectedItems.nodes.length:0)+(this.diagram.selectedItems.connectors?this.diagram.selectedItems.connectors.length:0)>0)},n.prototype.removeStackHighlighter=function(){var t=Bl(this.diagram.element.id),e=t.getElementById(t.id+"_stack_highlighter");e&&e.parentNode.removeChild(e)},n.prototype.renderStackHighlighter=function(t,e){var r,s,o,i=this.diagram.selectedItems.nodes[0];if(!e){var a=this.diagram.findObjectsUnderMouse(t.position);if((e=this.diagram.findObjectUnderMouse(a,"Drag",!0))&&!(e.isLane||e.isPhase||e.isHeader))for(var l=0;l0)for(var a=0;a1)if(i){var h=l.segments[0],c=l.segments[1],u=Nl(MI(t.wrapper,t.wrapper.corners,t.wrapper.bounds),h.direction),g=Ol({corners:void 0,point:u=qa(l,0,u,{x:l.sourceWrapper.offsetX,y:l.sourceWrapper.offsetY},!1),margin:void 0,direction:h.direction},{corners:void 0,point:c.points[1],margin:void 0,direction:void 0});h.length=R.distancePoints(g[0],g[1]),c.direction&&c.length&&(c.length=R.distancePoints(g[1],g[2]))}else if(o){switch(l.segments[0].direction){case"Bottom":r=t.wrapper.bounds.bottomCenter.x-e.bottomCenter.x,s=t.wrapper.bounds.bottomCenter.y-e.bottomCenter.y;break;case"Top":r=t.wrapper.bounds.topCenter.x-e.topCenter.x,s=t.wrapper.bounds.topCenter.y-e.topCenter.y;break;case"Left":r=t.wrapper.bounds.middleLeft.x-e.middleLeft.x,s=t.wrapper.bounds.middleLeft.y-e.middleLeft.y;break;case"Right":r=t.wrapper.bounds.middleRight.x-e.middleRight.x,s=t.wrapper.bounds.middleRight.y-e.middleRight.y}this.dragSourceEnd(l,r,s,!0,null,"ConnectorSourceEnd",void 0,void 0,void 0,!(t.parentId&&this.diagram.diagramActions&ee.isGroupDragging))}}},n.prototype.updateEndPoint=function(t,e){var r={sourcePoint:t.sourcePoint,targetPoint:t.targetPoint};t.sourceID&&(r.sourceID=t.sourceID),t.targetID&&(r.targetID=t.targetID),t.sourcePortID&&(r.sourcePortID=t.sourcePortID),t.targetPortID&&(r.targetPortID=t.targetPortID),t.segments&&(r.segments=t.segments),this.diagram.connectorPropertyChange(t,e||{},r),this.diagram.updateSelector()},n.prototype.dragSourceEnd=function(t,e,i,r,s,o,a,l,h,c,d){var u=this.diagram.nameTable[t.id],f={},p=this.checkBoundaryConstraints(e,i,u.wrapper.bounds);if(xI(u)&&p&&"BezierSourceThumb"!==o&&Uv(this.diagram)&&(f=$(f={sourcePoint:u.sourcePoint}),u.sourcePoint.x+=e,u.sourcePoint.y+=i,"ConnectorSourceEnd"===o&&"Orthogonal"===u.type&&this.changeSegmentLength(u,l,h,c),"Bpmn"===u.shape.type&&"Default"===u.shape.sequence&&"Sequence"===u.shape.flow&&this.updatePathElementOffset(u)),"Bezier"===u.type)if(f={sourcePoint:u.sourcePoint},d)this.translateBezierPoints(t,""===o?"ConnectorSourceEnd":o,e,i,d,s,!a);else for(var g=0;g2){var d=R.direction((c=t.segments[2]).points[0],c.points[1]);o.direction===_n(d)?("Right"===o.direction?c.points[0].x=o.points[o.points.length-1].x=l.wrapper.corners.middleRight.x+20:"Left"===o.direction?c.points[0].x=o.points[o.points.length-1].x=l.wrapper.corners.middleLeft.x-20:c.points[0].y=o.points[o.points.length-1].y="Top"===o.direction?l.wrapper.corners.topCenter.y-20:l.wrapper.corners.bottomCenter.y+20,c.direction&&c.length&&(c.length=R.distancePoints(c.points[0],c.points[c.points.length-1])),o.length=R.distancePoints(o.points[0],o.points[o.points.length-1])):o.direction===d&&c.direction&&c.length?("Top"===o.direction||"Bottom"===o.direction?(c.points[0]=o.points[0],c.points[c.points.length-1].x=c.points[0].x):(c.points[0]=o.points[0],c.points[c.points.length-1].y=c.points[0].y),c.length=R.distancePoints(c.points[0],c.points[c.points.length-1]),t.segments.splice(0,2)):o.length=20}else o.length=20;else if(o.length<1)if(""!==t.sourceID){var c;"Right"===a.direction?a.points[a.points.length-1].y=(h=l.wrapper.corners.middleRight).y:"Left"===a.direction?a.points[a.points.length-1].y=(h=l.wrapper.corners.middleLeft).y:a.points[a.points.length-1].x="Top"===a.direction?(h=l.wrapper.corners.topCenter).x:(h=l.wrapper.corners.bottomCenter).x,a.length=R.distancePoints(h,a.points[a.points.length-1]),t.segments.length>2&&(c=t.segments[2]).direction&&c.length&&(c.length=R.distancePoints(a.points[a.points.length-1],c.points[c.points.length-1])),t.segments.splice(0,1)}else t.segments.splice(0,1)}else e&&!i&&t.sourceID!==e.id&&t.segments&&null!==t.segments[0].direction&&e&&e instanceof te&&s&&this.changeSourceEndToNode(t,e),e&&i&&t.sourcePortID!==i&&t.segments&&null!==t.segments[0].direction&&e&&e instanceof te&&s&&this.changeSourceEndToPort(t,e,i)},n.prototype.canConnect=function(t,e){return!(!ua(e)||!Ph(e))},n.prototype.changeSourceEndToPort=function(t,e,i){var r=this.diagram.getWrapper(e.wrapper,i),s={x:r.offsetX,y:r.offsetY},o=zo(s,xn(e.wrapper),e.wrapper.bounds),a=t.segments[0],l=t.segments[1];if(a.direction!==o){var h=[],c={};if(a.direction===_n(o)){c={};var d=void 0;"Top"===o||"Bottom"===o?(d="Top"===o?{type:"Orthogonal",isTerminal:!0,direction:o,length:Math.abs(a.points[0].y-s.y)}:{type:"Orthogonal",isTerminal:!0,direction:o,length:Math.abs(s.y-a.points[0].y)},c=a.points[0].x>s.x?{type:"Orthogonal",isTerminal:!0,direction:"Right",length:a.points[0].x-s.x}:{type:"Orthogonal",isTerminal:!0,direction:"Left",length:s.x-a.points[0].x}):(d="Right"===o?{type:"Orthogonal",isTerminal:!0,direction:o,length:Math.abs(a.points[0].x-s.x)}:{type:"Orthogonal",isTerminal:!0,direction:o,length:Math.abs(s.x-a.points[0].x)},c=a.points[0].y>s.y?{type:"Orthogonal",direction:"Top",isTerminal:!0,length:a.points[0].y-s.y}:{type:"Orthogonal",direction:"Bottom",isTerminal:!0,length:s.y-a.points[0].y}),h.push(new wi(t,"segments",d,!0)),h.push(new wi(t,"segments",c,!0))}else h.push(new wi(t,"segments",c={type:"Orthogonal",direction:o,length:20,isTerminal:!0},!0));a.direction!==_n(o)&&("Top"===o||"Bottom"===o?(a.points[0].x=s.x,a.points[0].y=a.points[a.points.length-1].y="Top"===o?s.y-20:s.y+20):(a.points[0].y=s.y,a.points[0].x=a.points[a.points.length-1].x="Right"===o?s.x+20:s.x-20),a.length=R.distancePoints(a.points[0],a.points[a.points.length-1]),l.length=R.distancePoints(a.points[a.points.length-1],l.points[l.points.length-1])),t.segments=h.concat(t.segments)}else a.points[0]=s,"Top"===o||"Bottom"===o?a.points[a.points.length-1].x=s.x:a.points[a.points.length-1].y=s.y,a.length=R.distancePoints(a.points[0],a.points[a.points.length-1]),l.length=R.distancePoints(a.points[a.points.length-1],l.points[l.points.length-1])},n.prototype.removeTerminalSegment=function(t,e){for(var i=0;ii.width||"Left"===o.direction&&r.x>=o.points[0].x||"Right"===o.direction&&r.x<=o.points[0].x)o.points[0].y=o.points[o.points.length-1].y=r.y,o.points[0].x=r.x,o.length=R.distancePoints(o.points[0],o.points[o.points.length-1]),a.length=R.distancePoints(o.points[o.points.length-1],a.points[a.points.length-1]);else{var h=void 0;s="Bottom"===(h=a.direction?a.direction:R.direction(a.points[0],a.points[a.points.length-1]))?i.bottomCenter:i.topCenter,a.length&&a.direction&&(a.length="Top"===h?o.points[o.points.length-1].y-(s.y+20):s.y+20-o.points[o.points.length-1].y),o.length=o.points[o.points.length-1].x-s.x,o.direction=o.length>0?"Right":"Left",l.push(new wi(t,"segments",{type:"Orthogonal",direction:h,length:20},!0)),t.segments=l.concat(t.segments)}else r="Bottom"===o.direction?i.bottomCenter:i.topCenter,o.length>i.height||"Top"===o.direction&&r.y>=o.points[0].y||"Bottom"===o.direction&&r.y<=o.points[0].y?(o.points[0].x=o.points[o.points.length-1].x=r.x,o.points[0].y=r.y,o.length=R.distancePoints(o.points[0],o.points[o.points.length-1]),a.length=R.distancePoints(o.points[o.points.length-1],a.points[a.points.length-1])):(s="Left"===a.direction?i.middleLeft:i.middleRight,h=void 0,h=a.direction?a.direction:R.direction(a.points[0],a.points[a.points.length-1]),a.length&&a.direction&&(a.length="Left"===h?o.points[o.points.length-1].x-(s.x+20):s.x+20-o.points[o.points.length-1].x),o.length=o.points[o.points.length-1].y-s.y,o.direction=o.length>0?"Bottom":"Top",l.push(new wi(t,"segments",{type:"Orthogonal",direction:h,length:20},!0)),t.segments=l.concat(t.segments))},n.prototype.translateBezierPoints=function(t,e,i,r,s,o,a){var l=t.segments.indexOf(s),h=t.segments[parseInt(l.toString(),10)],c=l>0?t.segments[l-1]:null,d=null!==c?c.point:t.sourcePoint,u=l===t.segments.length-1?t.targetPoint:h.point;if(h)if("BezierSourceThumb"===e&&(h.vector1.angle||h.vector1.distance)){var f=h.vector1.distance,p=h.vector1.angle;h.vector1={distance:t.distance(d,o),angle:R.findAngle(d,o)},this.translateSubsequentSegment(t,s,!0,h.vector1.distance-f,h.vector1.angle-p)}else"BezierTargetThumb"===e&&(h.vector2.angle||h.vector2.distance)?(f=h.vector2.distance,p=h.vector2.angle,h.vector2={distance:t.distance(u,o),angle:R.findAngle(u,o)},this.translateSubsequentSegment(t,s,!1,h.vector2.distance-f,h.vector2.angle-p)):("ConnectorSourceEnd"===e&&!t.sourceID||"ConnectorTargetEnd"===e&&!t.targetID)&&a&&YI(h.vector1)&&YI(h.vector2)?(R.isEmptyPoint(h.point1)&&(h.bezierPoint1=QI(t.sourcePoint,t.targetPoint)),R.isEmptyPoint(h.point2)&&(h.bezierPoint2=QI(t.targetPoint,t.sourcePoint))):"BezierSourceThumb"===e||"ConnectorSourceEnd"===e&&!a&&YI(h.vector1)?(h.bezierPoint1.x+=i,h.bezierPoint1.y+=r,(!R.isEmptyPoint(h.point1)||a)&&(h.point1={x:h.bezierPoint1.x,y:h.bezierPoint1.y})):("BezierTargetThumb"===e||"ConnectorTargetEnd"===e&&!a&&YI(h.vector2))&&(h.bezierPoint2.x+=i,h.bezierPoint2.y+=r,(!R.isEmptyPoint(h.point2)||a)&&(h.point2={x:h.bezierPoint2.x,y:h.bezierPoint2.y}))},n.prototype.translateSubsequentSegment=function(t,e,i,r,s){var o=t.segments.indexOf(e);parseInt(o.toString(),10),t.bezierSettings.smoothness&mI.SymmetricAngle||(s=null),t.bezierSettings.smoothness&mI.SymmetricDistance||(r=null),(null!=r||null!=s)&&(i?0!==o&&this.updatePreviousBezierSegment(t,o,r,s):o!==t.segments.length-1&&this.updateNextBezierSegment(t,o,r,s))},n.prototype.updatePreviousBezierSegment=function(t,e,i,r){var s=t.segments[e-1],a=(s.vector2.angle+r)%360;a<0&&(a+=360),s.vector2={distance:s.vector2.distance+i,angle:a}},n.prototype.updateNextBezierSegment=function(t,e,i,r){var s=t.segments[e+1],a=(s.vector1.angle+r)%360;a<0&&(a+=360),s.vector1={distance:s.vector1.distance+i,angle:a}},n.prototype.dragTargetEnd=function(t,e,i,r,s,o,a,l){var c,h=this.diagram.nameTable[t.id],d=this.checkBoundaryConstraints(e,i,h.wrapper.bounds);if(TI(h)&&"BezierTargetThumb"!==o&&d&&Uv(this.diagram)){if(c=$(c={targetPoint:h.targetPoint}),h.targetPoint.x+=e,h.targetPoint.y+=i,"ConnectorTargetEnd"===o&&"Orthogonal"===h.type&&h.segments&&h.segments.length>0){var u=h.segments[h.segments.length-2];u&&2===h.segments[h.segments.length-1].points.length&&("Left"===u.direction||"Right"===u.direction?u.points[u.points.length-1].x=h.targetPoint.x:u.points[u.points.length-1].y=h.targetPoint.y,u.length=R.distancePoints(u.points[0],u.points[u.points.length-1]),u.direction=R.direction(u.points[0],u.points[u.points.length-1]))}"Bpmn"===h.shape.type&&"Default"===h.shape.sequence&&"Sequence"===h.shape.flow&&this.updatePathElementOffset(h)}if("Bezier"===h.type)if(c={targetPoint:h.targetPoint},l)this.translateBezierPoints(t,""===o?"ConnectorTargetEnd":o,e,i,l,s,!a);else for(var f=0;f0){if(void 0!==s&&o.segments[parseInt(s.toString(),10)])if("Bezier"===o.type){var a=o.segments[parseInt(s.toString(),10)],l=a.isInternalSegment;l&&null!==o.bezierSettings&&"FreeForm"!==o.bezierSettings.segmentEditOrientation?("Horizontal"===a.orientation?a.point.x+=e:a.point.y+=i,this.updateDirectionalBezierCurve(o)):(a.point.x+=e,a.point.y+=i),l&&(o.isBezierEditing=!0)}else o.segments[parseInt(s.toString(),10)].point.x+=e,o.segments[parseInt(s.toString(),10)].point.y+=i;else for(var h=0;h1){var a=e[1],l=e[2],h={x:.5*(a.x+l.x),y:.5*(a.y+l.y)},c=t.segments[0];c.vector1.angle=Gt(s,a),c.vector1.distance=.5*R.findLength(s,a),c.vector2.angle=Gt(h,a),c.vector2.distance=.5*R.findLength(h,a),c.point=h;var d=t.segments[1];if(d.vector1.angle=Gt(h,l),d.vector1.distance=.5*R.findLength(h,l),t.segments.length>2){var u=e[3],f={x:.5*(l.x+u.x),y:.5*(l.y+u.y)};d.vector2.angle=Gt(f,l),d.vector2.distance=.5*R.findLength(f,l),d.point=f;var p=t.segments[2];if(p.vector1.angle=Gt(f,u),p.vector1.distance=.5*R.findLength(f,u),t.segments.length>3){var g=e[4],v={x:.5*(u.x+g.x),y:.5*(u.y+g.y)};p.vector2.angle=Gt(v,u),p.vector2.distance=.5*R.findLength(v,u),p.point=v;var y=t.segments[3];y.vector1.angle=Gt(v,g),y.vector1.distance=.5*R.findLength(v,g),y.vector2.angle=Gt(o,g),y.vector2.distance=.5*R.findLength(o,g)}else p.vector2.angle=Gt(o,u),p.vector2.distance=.5*R.findLength(o,u)}else d.vector2.angle=Gt(o,l),d.vector2.distance=.5*R.findLength(o,l)}},n.prototype.rotateObjects=function(t,e,i,r,s){r=r||{};var o=Bi();qi(o,i,r.x,r.y);for(var l=0,h=e;l0){this.diagram.protectPropertyChange(!0);var o=t;o.segments=[],this.diagram.connectorPropertyChange(o,{},{segments:o.segments}),this.diagram.protectPropertyChange(!1)}}},n.prototype.updateInnerParentProperties=function(t){var r=this.diagram.isProtectedOnChange;this.diagram.protectPropertyChange(!0);for(var s=this.getAllDescendants(t,[],!1,!0),o=0;o0&&(f=this.diagram.bpmnModule.getChildrenBound(d,d.id,this.diagram),u=d.wrapper.bounds.containsRect(f)),h=d.wrapper.actualSize.width*t,c=d.wrapper.actualSize.height*e,void 0!==d.maxWidth&&0!==d.maxWidth&&(h=Math.min(d.maxWidth,h)),void 0!==d.minWidth&&0!==d.minWidth&&(h=Math.max(d.minWidth,h)),void 0!==d.maxHeight&&0!==d.maxHeight&&(c=Math.min(d.maxHeight,c)),void 0!==d.minHeight&&0!==d.minHeight&&(c=Math.max(d.minHeight,c)),u&&(h=Math.max(h,f.right-d.wrapper.bounds.x),c=Math.max(c,f.bottom-d.wrapper.bounds.y)),t=h/d.actualSize.width,e=c/d.actualSize.height}var p=Bi();o||(o=r);var g=o.wrapper;if(qi(p,-g.rotateAngle,i.x,i.y),Yf(p,t,e,i.x,i.y),qi(p,g.rotateAngle,i.x,i.y),r instanceof te){var d,v=Ke(p,{x:(d=r).wrapper.offsetX,y:d.wrapper.offsetY}),y=d.wrapper.offsetX-d.wrapper.actualSize.width*d.pivot.x,S=d.wrapper.offsetY-d.wrapper.actualSize.height*d.pivot.y;if(h>0)if(d.processId){var b=this.diagram.nameTable[d.processId];(!b.maxWidth||d.margin.left+h0)if(d.processId){var M=this.diagram.nameTable[d.processId];(!M.maxHeight||d.margin.top+c0){if(e.dragLimit=e.dragLimit?e.dragLimit:{},e.dragLimit.top||e.dragLimit.bottom||e.dragLimit.left||e.dragLimit.right){var b={minDistance:null};S=this.getRelativeOffset(v,d,b);var M={minDistance:null};g=this.getRelativeOffset(v,y,M),S=null!=b&&M.minDistance0){if(S=y[y.length-1]){var b=void 0;for(b=0;b=e.x-t.dragLimit.left-r.width/2&&i.x<=e.x+t.dragLimit.right+r.width/2&&(s=!0),i.y>=e.y-t.dragLimit.top-r.height/2&&i.y<=e.y+t.dragLimit.bottom+r.height/2&&(o=!0),{x:s,y:o}},n.prototype.updateLabelMargin=function(t,e,i,r,s,o,a){if(i=i||{x:e.offset,y:0},e&&i&&i.x>0&&i.x<1){var l=R.getLengthFromListOfPoints(t.intermediatePoints),h=this.getPointAtLength(l*i.x,t.intermediatePoints,0),c=this.diagram.scrollSettings.currentZoom,d=e.dragLimit?e.dragLimit:{left:0,right:0,top:0,bottom:0};if(d.top||d.bottom||d.left||d.right){this.diagram.getWrapper(t.wrapper,e.id);var f=new Ne(0,0,0,0),p=this.diagram.getWrapper(t.wrapper,e.id);f.x=p.offsetX/c+o,f.y=p.offsetY/c+a,f.width=p.bounds.width/c,f.height=p.bounds.height/c;var g=new Ne(h.x-(d.left||0)-f.width/2,h.y-(d.top||0)-f.height/2,(d.left||0)+(d.right||0)+f.width,(d.top||0)+(d.bottom||0)+f.height);if(g.containsPoint(r));else for(var S=0,b=this.boundsInterSects([h,r],g,!1);S=t){c=t-r,d=R.findAngle(s,a),u=c*Math.cos(d*Math.PI/180),f=c*Math.sin(d*Math.PI/180),o={x:s.x+u,y:s.y+f};break}r+=h,s=a}else s=a;return o},n.prototype.getInterceptWithSegment=function(t,e){for(var o,a,i=[],r=[],s=[],l=R.findLength({x:0,y:0},{x:this.diagram.scroller.viewPortWidth,y:this.diagram.scroller.viewPortHeight}),h=1;h0&&a<=90||a>180&&a<=270?90:-90;r.push(R.transform(t,a+c,l)),r.push(R.transform(t,o+c,l));var f=Kv({x1:s[0].x,y1:s[0].y,x2:s[1].x,y2:s[1].y},{x1:r[0].x,y1:r[0].y,x2:r[1].x,y2:r[1].y});f.enabled&&i.push(f.intersectPt)}return i},n.prototype.getAnnotationChanges=function(t,e){var r={};return r[eb(t,e.id,!0)]={width:e.width,height:e.height,offset:t instanceof te?{x:e.offset.x,y:e.offset.y}:e.offset,rotateAngle:e.rotateAngle,margin:{left:e.margin.left,right:e.margin.right,top:e.margin.top,bottom:e.margin.bottom},horizontalAlignment:e.horizontalAlignment,verticalAlignment:e.verticalAlignment,alignment:t instanceof de?e.alignment:void 0},{annotations:r}},n.prototype.getConnectorPortChanges=function(t,e){var i=function Nse(n,t,e){for(var i=n.ports,r=0;r1&&(v.width=g,v.offset.x=1/S),p>1&&(v.height=p,v.offset.y=1/b)}}e instanceof Or&&(e.alignment="Center"),l=this.getAnnotationChanges(t,e),t instanceof te?this.diagram.nodePropertyChange(t,a,l):this.diagram.connectorPropertyChange(t,a,l),this.diagram.updateDiagramObject(t)},n.prototype.getSubProcess=function(t){var i,e={nodes:[],connectors:[]};return t instanceof te?i=t.processId:t&&t.nodes&&t.nodes.length&&t.nodes[0].processId&&(i=t.nodes[0].processId),i&&e.nodes.push($(this.diagram.nameTable[i])),e},n.prototype.checkBoundaryConstraints=function(t,e,i,r){var s=this.diagram.pageSettings,o=this.diagram.pageSettings.boundaryConstraints,a=this.diagram.scroller;if("Page"===o||"Diagram"===o){var l=i?void 0:this.diagram.selectedItems.wrapper.bounds;return!!((i?i.right:l.right)+(t||0)<=("Page"===o?s.width:a.viewPortWidth)&&(i?i.left:l.left)+(t||0)>=0&&(i?i.bottom:l.bottom)+(e||0)<=("Page"===o?s.height:a.viewPortHeight)&&(i?i.top:l.top)+(e||0)>=0||"None"!==this.diagram.layout.type&&r)}return!0},n.prototype.dragSelectedObjects=function(t,e){var i=this,r=this.diagram.selectedItems;this.state&&!this.state.backup&&(this.state.backup={},this.state.backup.offsetX=r.offsetX,this.state.backup.offsetY=r.offsetY),r=UI(this.diagram,r)||r;var s=this.diagram.selectedItems.nodes.filter(function(c){return"SwimLane"===c.shape.type});if(s.length>0&&!this.diagram.currentSymbol&&this.diagram.selectedItems.nodes.length>1){var o=this.diagram.selectedItems.nodes.filter(function(c){return""===c.parentId||"SwimLane"!==i.diagram.nameTable[c.parentId].shape.type});if(o.length>0){for(var a=0;a0||l.length>1)&&(o=o.concat(l),this.diagram.selectedItems.nodes.splice(0,this.diagram.selectedItems.nodes.length),o.forEach(function(c){i.diagram.selectedItems.nodes.push(c)}),r=this.diagram.selectedItems,this.diagram.selectedObject.helperObject=void 0)}}if(this.checkBoundaryConstraints(t,e)){this.diagram.diagramActions=this.diagram.diagramActions|ee.PreventZIndexOnDragging|ee.DragUsingMouse;var h=this.diagram.selectedObject.actualObject;return(h&&h instanceof te&&h.isLane&&jx(h,this.diagram)||!h||!h.isLane)&&this.diagram.drag(r,t,e),this.diagram.diagramActions=this.diagram.diagramActions&~(ee.PreventZIndexOnDragging|ee.DragUsingMouse),this.diagram.refreshCanvasLayers(),this.checkHtmlObjectDrag(r),!0}return!1},n.prototype.checkHtmlObjectDrag=function(t){var e=!1;this.diagram.views&&this.diagram.views.length>1&&(t instanceof ei?e=t.nodes.some(function(i){return i.shape&&"HTML"===i.shape.type}):t.shape&&"HTML"===t.shape.type&&(e=!0),e&&this.resetOverviewCanvas())},n.prototype.resetOverviewCanvas=function(){for(var t=0,e=this.diagram.views;t0&&(this.layoutAnimateModule.stopCurrentAnimation(this.objectStore[0],e,t),this.objectStore=[]),a=this.diagram.doLayout(),this.objectStore.push(a)),this.canUpdateTemplate=!1,this.diagram.blazorActions&=~on.expandNode,this.diagram.preventNodesUpdate=r,this.diagram.layoutAnimateModule&&this.diagram.organizationalChartModule&&!i)this.diagram.allowServerDataBinding=!1,this.layoutAnimateModule.expand(this.diagram.layout.enableAnimation,a,t,this.diagram);else{var l={element:$(t),state:!!t.isExpanded};this.triggerEvent(Ce.expandStateChange,l),this.diagram.lineRoutingModule&&this.diagram.constraints&nt.LineRouting&&"ComplexHierarchicalTree"!==this.diagram.layout.type&&this.diagram.resetSegments()}return this.diagram.layout.fixedNode=""===o?"":this.diagram.layout.fixedNode,a},n.prototype.getparentexpand=function(t,e,i,r){for(var s,o=0;o0&&(this.diagram.selectedItems.wrapper.rotateAngle=this.diagram.selectedItems.rotateAngle=s.rotateAngle),!(r instanceof te&&"SwimLane"!==r.shape.type)||r.isLane||r.isPhase||r.isHeader||Dn(this.diagram,r)){if(r instanceof ei)for(var d=0;d30||g.wrapper.outerBounds.topCenter.y-p.wrapper.outerBounds.bottomCenter.y>30)&&this.diagram.lineRoutingModule.refreshConnectorSegments(this.diagram,f,!0)}}this.updateSelector(),this.diagram.protectPropertyChange(!1)}},n.prototype.drawSelectionRectangle=function(t,e,i,r){this.diagram.drawSelectionRectangle(t,e,i,r)},n.prototype.startGroupAction=function(){this.diagram.startGroupAction()},n.prototype.endGroupAction=function(){this.diagram.endGroupAction()},n.prototype.removeChildFromBPmn=function(t,e,i){var r=this.diagram.nameTable[t.id]||t.nodes[0];if(i&&r&&r.processId&&r.processId===i.wrapper.id){var s=$(r);s.processId=r.processId,this.diagram.startGroupAction();var o=this.diagram.nameTable[r.processId].shape.activity.subProcess.processes||[];o.splice(o.indexOf(r.id),1),this.diagram.bpmnModule.removeChildFromBPMN(this.diagram.nameTable[r.processId].wrapper,r.id,this.diagram),this.diagram.nameTable[r.id].processId="",r.offsetX=r.wrapper.offsetX,r.offsetY=r.wrapper.offsetY;var a=$(r);this.addHistoryEntry({type:"PositionChanged",redoObject:{nodes:[a]},undoObject:{nodes:[s]},category:"Internal"}),this.diagram.endGroupAction()}},n.prototype.isDroppable=function(t,e){var i=this.diagram.nameTable[t.id]||t.nodes[0];return i instanceof te&&(!ce()&&"TextAnnotation"===i.shape.shape||("Group"===e.shape.shape&&(e.shape.activity.subProcess.collapsed=!1),!(i&&"Bpmn"===i.shape.type&&(i.processId===e.id||i.id===e.processId||"Bpmn"===e.shape.type&&!(e instanceof de)&&e.shape.activity&&e.shape.activity.subProcess&&e.shape.activity.subProcess.collapsed))))},n.prototype.renderHighlighter=function(t,e,i){if(new Ne,t.target instanceof te||t.target instanceof de||e&&(t.source instanceof te||t.source instanceof de)){var a=this.findTarget(e?t.sourceWrapper:t.targetWrapper,e?t.source:t.target,i,!0),l=void 0;if(a instanceof Rd)for(var h=a.id,c=t.target,u=0,f=c.wrapper.children[0].children[0].children[2].children;u0){var r=0;t[0]=this.diagram.nameTable[t[0].id]||t[0];var s="Object"===i?yr(t[0].wrapper):this.diagram.selectedItems.wrapper.bounds,o={nodes:[],connectors:[]},a={nodes:[],connectors:[]};for(r="Object"===i?r+1:r;r0){var i=0,r=0,s=0,o=0,a=0,l=0,h=0,c=0,d={nodes:[],connectors:[]},u={nodes:[],connectors:[]};for(i=0;io.center.y&&(r=n[parseInt(e.toString(),10)],n[parseInt(e.toString(),10)]=n[parseInt(i.toString(),10)],n[parseInt(i.toString(),10)]=r):s.center.x>o.center.x&&(r=n[parseInt(e.toString(),10)],n[parseInt(e.toString(),10)]=n[parseInt(i.toString(),10)],n[parseInt(i.toString(),10)]=r)}}return n}(t,e),i=1;i0){var i=0,r={x:.5,y:.5};t[0]=this.diagram.nameTable[t[0].id]||t[0];var s=yr(t[0].wrapper),o={nodes:[],connectors:[]},a={nodes:[],connectors:[]};for(i=1;ii.zIndex){for(var s=this.diagram.layers.indexOf(this.diagram.getActiveLayer()),o=this.diagram.layers[parseInt(s.toString(),10)].zIndexTable,a=JSON.parse(JSON.stringify(o)),l=i.zIndex,h=r.zIndex,c=h;c>=l;c--)l!==c?o[c-1]?(o[parseInt(c.toString(),10)]=o[c-1],this.diagram.nameTable[o[parseInt(c.toString(),10)]].zIndex=c):(o[c-1]=o[parseInt(c.toString(),10)],this.diagram.nameTable[o[c-1]].zIndex=c,delete o[parseInt(c.toString(),10)]):this.swapZIndexObjects(h,o,r.id,a);"SVG"===this.diagram.mode?(this.moveSvgNode(e.parentId,i.id),this.updateNativeNodeIndex(e.parentId,i.id)):this.diagram.refreshCanvasLayers()}},n.prototype.findLeastIndexConnector=function(t,e,i){for(var r=0;rs.zIndex&&(i=s)}return i},n.prototype.findLeastIndexObject=function(t,e){var i=t;return t instanceof te&&(i=this.findLeastIndexConnector(t.inEdges,e,i),i=this.findLeastIndexConnector(t.outEdges,e,i)),i},n.prototype.checkSelection=function(t,e){var i;if(1===t.nodes.length&&0===t.connectors.length)if(Dn(this.diagram,t.nodes[0],!0)){var r=t.nodes[0];if("SwimLane"===(i="SwimLane"===t.nodes[0].shape?t.nodes[0]:this.diagram.nameTable[t.nodes[0].parentId]).shape.type){var s="Horizontal"===i.shape.orientation;(r.isPhase&&(s&&"ResizeSouth"===e||!s&&"ResizeEast"===e)||r.isLane&&(s&&"ResizeEast"===e||!s&&"ResizeSouth"===e))&&R3(this.diagram,i,e)}else if("Grid"===i.container.type)if("Horizontal"===i.container.orientation&&1===r.rowIndex||"Vertical"===i.container.orientation&&r.rowIndex>0&&r.columnIndex>0){if("ResizeSouth"===e)for(var o=0;o1&&(this.diagram.realActions=this.diagram.realActions|$i.hScrollbarMoved,this.scrolled=!0),this.diagram.scrollSettings.horizontalOffset=t},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"verticalOffset",{get:function(){return this.vOffset},set:function(t){this.vOffset=t,Math.abs(this.vOffset-this.diagram.scrollSettings.verticalOffset)>1&&(this.diagram.realActions=this.diagram.realActions|$i.vScrollbarMoved,this.scrolled=!0),this.diagram.scrollSettings.verticalOffset=t},enumerable:!0,configurable:!0}),n.prototype.getBounds=function(){var e=this.diagram.spatialSearch.getPageBounds(0,0);return(e.x<0||e.y<0)&&!this.diagram.pageSettings.multiplePage?this.getPageBounds(void 0,void 0,!0,!0):this.getPageBounds(void 0,void 0,!0)},n.prototype.updateScrollOffsets=function(t,e){var i,r,s=this.getBounds();s.x*=this.currentZoom,s.y*=this.currentZoom,s.width*=this.currentZoom,s.height*=this.currentZoom,i=Math.max(0,t-s.left),r=Math.max(0,e-s.top),void 0!==t&&void 0!==e?(this.horizontalOffset=i,this.verticalOffset=r,this.diagram.setOffset(i,r)):this.diagram.setOffset(-this.horizontalOffset-s.x,-this.verticalOffset-s.y),this.transform={tx:Math.max(this.horizontalOffset,-s.left)/this.currentZoom,ty:Math.max(this.verticalOffset,-s.top)/this.currentZoom,scale:this.currentZoom}},n.prototype.setScrollOffset=function(t,e){this.scrolled=!1;var i=this.getBounds();i.x*=this.currentZoom,i.y*=this.currentZoom,i.width*=this.currentZoom,i.height*=this.currentZoom;var r=-i.left,s=-i.top,o=!1,a=this.viewPortWidth*this.currentZoom,l=this.viewPortHeight*this.currentZoom,h=r-t;if(h!==this.horizontalOffset){rh?this.horizontalOffset-=t:this.horizontalOffset=h,o=!0);var c=Math.max(i.right+this.vScrollSize,a);if(!o&&c<-h+this.viewPortWidth){var d=-h+a-this.vScrollSize,u=-this.horizontalOffset+a-this.vScrollSize;this.horizontalOffset=dd-u?h:-(i.right+this.vScrollSize-a),o=!0}o||(this.horizontalOffset=r-t)}o=!1;var f=s-e;if(f!==this.verticalOffset){sf?this.verticalOffset-=e:this.verticalOffset=f,o=!0);var p=Math.max(i.bottom+this.hScrollSize,l);if(!o&&p<-f+l){var g=-f+l-this.hScrollSize,v=-this.verticalOffset+l-this.hScrollSize;this.verticalOffset=gg-v?f:-(i.bottom+this.hScrollSize-l),o=!0}o||(this.verticalOffset=s-e)}this.transform={tx:Math.max(this.horizontalOffset,-i.left)/this.currentZoom,ty:Math.max(this.verticalOffset,-i.top)/this.currentZoom,scale:this.currentZoom},this.setSize()},n.prototype.getObjects=function(t,e){for(var i=[],r=0;r0){for(var l=0;l0){h.push(i[parseInt(o.toString(),10)].id);for(var d=0;d=e.bottom&&(l=0),-this.horizontalOffset<=e.x&&-this.horizontalOffset+this.viewPortWidth>=e.right&&(a=0),this.hScrollSize=a,this.vScrollSize=l;var h=this.diagramWidth,c=this.diagramHeight;this.diagramWidth=Math.max(e.right,-this.horizontalOffset+this.viewPortWidth-l)-i,this.diagramHeight=Math.max(e.bottom,-this.verticalOffset+this.viewPortHeight-a)-r,(h!==this.diagramWidth||c!==this.diagramHeight)&&"Diagram"!==this.diagram.scrollSettings.scrollLimit&&this.diagram.setSize(this.diagramWidth,this.diagramHeight),"Diagram"===this.diagram.scrollSettings.scrollLimit&&(h===this.diagramWidth&&c===this.diagramHeight&&1===this.currentZoom||this.diagram.diagramActions&&t&&(!this.diagram.diagramActions||!t||0===this.verticalOffset&&this.verticalOffset!==t.y||0===this.horizontalOffset&&this.horizontalOffset!==t.x)?t&&h===this.diagramWidth&&c===this.diagramHeight&&(this.diagram.diagramCanvas.scrollHeight>this.viewPortHeight&&t.y<0&&this.horizontalOffset===t.x&&0===this.verticalOffset||this.diagram.diagramCanvas.scrollWidth>this.viewPortWidth&&t.x<0&&this.verticalOffset===t.y&&0===this.horizontalOffset)&&(this.verticalOffset=t.y,this.horizontalOffset=t.x,this.transform={tx:Math.max(t.x,-e.left)/this.currentZoom,ty:Math.max(t.y,-e.top)/this.currentZoom,scale:this.currentZoom}):(this.diagram.scrollActions&da.Interaction&&t&&(this.transform={tx:Math.max(t.x,-e.left/this.currentZoom)/this.currentZoom,ty:Math.max(t.y,-e.top/this.currentZoom)/this.currentZoom,scale:this.currentZoom},this.horizontalOffset=t.x,this.verticalOffset=t.y),this.diagram.setSize(this.diagramWidth,this.diagramHeight),!(this.diagram.scrollActions&da.PropertyChange)&&t&&(this.horizontalOffset=t.x,this.verticalOffset=t.y,this.transform={tx:Math.max(t.x,-e.left)/this.currentZoom,ty:Math.max(t.y,-e.top)/this.currentZoom,scale:this.currentZoom}))),this.diagram.transformLayers(),this.diagram.element.style.overflow="hidden"},n.prototype.setViewPortSize=function(t,e){this.viewPortWidth=t,this.viewPortHeight=e},n.prototype.getPageBounds=function(t,e,i,r){var o,s=new Ne;if("Content"===e||r||null===this.diagram.pageSettings.width||null===this.diagram.pageSettings.height){var u=t?void 0:0;o=this.diagram.spatialSearch.getPageBounds(u,u)}else{var a=this.diagram.pageSettings.width,l=this.diagram.pageSettings.height,h=0,c=0;if(this.diagram.pageSettings.multiplePage){if((s=this.diagram.spatialSearch.getPageBounds(0,0)).right>a&&(a*=d=Math.ceil(s.right/a)),s.bottom>l&&(l*=d=Math.ceil(s.bottom/l)),s.left<0&&Math.abs(s.left)>h){var d=Math.ceil(Math.abs(s.left)/this.diagram.pageSettings.width);h=this.diagram.pageSettings.width*d}s.top<0&&Math.abs(s.top)>c&&(d=Math.ceil(Math.abs(s.top)/this.diagram.pageSettings.height),c=this.diagram.pageSettings.height*d)}o=new Ne(-h,-c,a+h,l+c)}if(i){var f=this.diagram.scrollSettings.padding;o.x-=f.left,o.y-=f.top,o.width+=f.left+f.right,o.height+=f.top+f.bottom}return o},n.prototype.getPageBreak=function(t){for(var e=0,i=0,r=-1,s=[],c=this.diagram.pageSettings.margin.left,d=this.diagram.pageSettings.margin.right,u=this.diagram.pageSettings.margin.top,f=this.diagram.pageSettings.margin.bottom,p=1,g=1;t.width>e;)(e+=this.diagram.pageSettings.width?this.diagram.pageSettings.width:t.width)===this.diagram.pageSettings.width&&(s[++r]={x1:t.left+c,y1:t.top+u,x2:t.left+c,y2:t.bottom-f}),ei;)(i+=this.diagram.pageSettings.height?this.diagram.pageSettings.height:t.height)===this.diagram.pageSettings.height&&(s[++r]={x1:t.left+c,y1:t.top+u,x2:t.right-d,y2:t.top+u}),i=this.diagram.scrollSettings.minZoom||l||t>=1)){this.currentZoom*=t;var c=this.getPageBounds(void 0,void 0,!0);c.x*=this.currentZoom,c.y*=this.currentZoom;var d=Bi();Yf(d,t,t,r.x,r.y),qB(d,e||0,i||0),mx(h,d);var u=Ke(h,{x:0,y:0});if(1===t&&(u=this.applyScrollLimit(u.x,u.y,s,o,a)),a=-c.y>=u.y&&-c.x>=u.x&&a,(this.diagram.scrollActions&da.PropertyChange||!(this.diagram.scrollActions&da.Interaction)||"Diagram"!==this.diagram.scrollSettings.scrollLimit||a)&&(this.transform={tx:Math.max(u.x,-c.left)/this.currentZoom,ty:Math.max(u.y,-c.top)/this.currentZoom,scale:this.currentZoom},this.horizontalOffset=u.x,this.verticalOffset=u.y),this.setSize(u),"SVG"!==this.diagram.mode&&Ds(this.diagram)&&this.diagram.scroller.virtualizeElements(),"SVG"!==this.diagram.mode&&!Ds(this.diagram)&&this.diagram.refreshDiagramLayer(),this.diagram.setOffset(-this.horizontalOffset-c.x,-this.verticalOffset-c.y),GI(this.diagram),this.diagram.views&&this.diagram.views.overview){var f=this.diagram.views.overview,p=f.scrollOverviewRect(f.parent.scroller.horizontalOffset,f.parent.scroller.verticalOffset,f.parent.scroller.currentZoom,!0);f.updateOverviewrect(-p.x,-p.y,p.width,p.height),f.updateView(f)}}}},n.prototype.fitToPage=function(t){var e=(t=t||{}).mode,i=t.region,r=t.margin||{},s=t.canZoomIn,o=t.customBounds,a=t.canZoomOut;r.bottom=r.bottom||25,r.top=r.top||25,r.left=r.left||25,r.right=r.right||25;var h,l=o,c=-this.horizontalOffset,d=-this.verticalOffset;if("PageSettings"===(i=i||"PageSettings")&&this.diagram.pageSettings.width&&this.diagram.pageSettings.height||this.diagram.nodes.length>0||this.diagram.connectors.length>0){e=e||"Page","CustomBounds"!==i&&(l=this.getPageBounds(!0,i,!0));var u={x:0,y:0};r.left+r.right>this.viewPortWidth&&(this.viewPortWidth<=100?(r.left=5,r.right=5):(r.left=25,r.right=25)),r.top+r.bottom>this.viewPortHeight&&(this.viewPortHeight<=100?(r.top=5,r.bottom=5):(r.top=25,r.bottom=25)),u.x=(this.viewPortWidth-(r.left+r.right))/l.width,u.y=(this.viewPortHeight-(r.top+r.bottom))/l.height,!s&&l.width-this.horizontalOffset-a+this.viewPortWidth&&(i=o.right-this.viewPortWidth,i+=20),o.x<-a&&(i=o.x),o.bottom>-l+this.viewPortHeight&&(r=o.bottom-this.viewPortHeight,r+=20),o.y<-l&&(r=o.y),this.zoom(1,-this.horizontalOffset-i,-this.verticalOffset-r,null,void 0,e))},n.prototype.bringToCenter=function(t){var e=this.currentZoom,i=new Ne(t.x*e,t.y*e,t.width*e,t.height*e),r=i.x+i.width/2-this.viewPortWidth/2,s=i.y+i.height/2-this.viewPortHeight/2;this.zoom(1,-this.horizontalOffset-(r*=-1),-this.verticalOffset-(s*=-1),null)},n.prototype.applyScrollLimit=function(t,e,i,r,s){if("Infinity"===this.diagram.scrollSettings.scrollLimit&&void 0===i&&!r&&(t=-t,e=-e),"Infinity"!==this.diagram.scrollSettings.scrollLimit){var o=void 0;if("Limited"===this.diagram.scrollSettings.scrollLimit){var a=this.diagram.scrollSettings.scrollableArea;o=new Ne(a.x,a.y,a.width,a.height)}(o=o||(s?this.getPageBounds():this.getPageBounds(!0))).x*=this.currentZoom,o.y*=this.currentZoom,o.width*=this.currentZoom,o.height*=this.currentZoom,void 0!==i&&(t*=-1,e*=-1),r&&(t*=-1,e*=-1);var l=Math.max(o.right,this.viewPortWidth);if(!r&&!(t<=o.x&&(t+this.viewPortWidth>=o.right||t>=o.right-this.viewPortWidth)||t>=o.x&&t+this.viewPortWidth<=l))if(t>=o.x)t=Math.max(o.x,Math.min(t,t-(t+this.viewPortWidth-this.vScrollSize-l)));else{var h=o.right-this.viewPortWidth;t=Math.min(h,o.x)}var c=Math.max(o.bottom,this.viewPortHeight);r||e<=o.y&&e+this.viewPortHeight>=o.bottom||e>=o.y&&e+this.viewPortHeight<=c||(e>=o.y?e=Math.max(o.y,Math.min(e,e-(e+this.viewPortHeight-this.hScrollSize-c))):(h=o.bottom-this.viewPortHeight,e=Math.min(o.y,h))),t*=-1,e*=-1}return{x:t,y:e}},n}(),joe=function(){function n(t,e,i,r,s){this.objects=[],this.left=t,this.top=e,this.width=i,this.height=r,this.spatialSearch=s}return n.prototype.findQuads=function(t,e){null!=this.first&&this.first.isIntersect(t)&&this.first.findQuads(t,e),null!=this.second&&this.second.isIntersect(t)&&this.second.findQuads(t,e),null!=this.third&&this.third.isIntersect(t)&&this.third.findQuads(t,e),null!=this.fourth&&this.fourth.isIntersect(t)&&this.fourth.findQuads(t,e),this.objects.length>0&&e.push(this)},n.prototype.isIntersect=function(t){return!(this.left+this.widtht.right||this.top>t.bottom)},n.prototype.selectQuad=function(){for(var i,t=null,e=this;null!=e;)i=e.getQuad(t),e=i.source,t=i.target||t;return t},n.prototype.getQuad=function(t){var e=this.width/2,i=this.height/2;if(e>=1e3&&i>=1e3){var r=this.left+e,s=this.top+i;if(this.spatialSearch.childRight<=r){if(this.spatialSearch.childBottom<=s)return this.first||((o=new n(this.left,this.top,e,i,this.spatialSearch)).parent=this,this.first=o),{source:this.first};if(this.spatialSearch.childTop>=s)return this.third||((o=new n(this.left,s,e,i,this.spatialSearch)).parent=this,this.third=o),{source:this.third}}else if(this.spatialSearch.childLeft>=r){if(this.spatialSearch.childBottom<=s)return this.second||((o=new n(r,this.top,e,i,this.spatialSearch)).parent=this,this.second=o),{source:this.second};var o;if(this.spatialSearch.childTop>=s)return this.fourth||((o=new n(r,s,e,i,this.spatialSearch)).parent=this,this.fourth=o),{source:this.fourth}}}return this.objects.push(this.spatialSearch.childNode),{target:this}},n.prototype.isContained=function(){return this.spatialSearch.childLeft>=this.left&&this.spatialSearch.childRight<=this.left+this.width&&this.spatialSearch.childTop>=this.top&&this.spatialSearch.childBottom<=this.top+this.height},n.prototype.addIntoAQuad=function(t){var e={};this.spatialSearch.setCurrentNode(t);for(var i=null;!e.isAdded;)i=(e=this.spatialSearch.parentQuad.add(i)).quad;return i},n.prototype.add=function(t){if(t=null,this.isContained())return{isAdded:!0,quad:t=this.selectQuad()};var e=void 0,i=!(0!==this.objects.length||this.first||this.second||this.third||this.fourth),r=2*this.width,s=2*this.height;return this.spatialSearch.childLeft=this.childLeft?(this.pageLeft=this.childLeft,this.leftElement=t,r=!0):t===this.leftElement&&(this.pageLeft=Number.MAX_VALUE,this.findLeft(this.parentQuad),r=!0)),(this.pageTop!==this.childTop||t!==this.topElement)&&(this.pageTop>=this.childTop?(this.pageTop=this.childTop,this.topElement=t,r=!0):t===this.topElement&&(this.pageTop=Number.MAX_VALUE,this.findTop(this.parentQuad),r=!0)),(this.pageBottom!==this.childBottom||t!==this.bottomElement)&&(this.pageBottom<=this.childBottom?(r=!0,this.pageBottom=this.childBottom,this.bottomElement=t):t===this.bottomElement&&(this.pageBottom=-Number.MAX_VALUE,this.findBottom(this.parentQuad),r=!0)),(this.pageRight!==this.childRight||t!==this.rightElement)&&(this.pageRight<=this.childRight?(this.pageRight=this.childRight,this.rightElement=t,r=!0):t===this.rightElement&&(this.pageRight=-Number.MAX_VALUE,this.findRight(this.parentQuad),r=!0)),r}return this.setCurrentNode(null),!1},n.prototype.isWithinPageBounds=function(t){return t.left>=this.pageLeft&&t.right<=this.pageRight&&t.top>=this.pageTop&&t.bottom<=this.pageBottom},n.prototype.findQuads=function(t){var e=[];return this.parentQuad.findQuads(t,e),e},n.prototype.findObjects=function(t){for(var i=[],r=0,s=this.findQuads(t);r=r.outerBounds.left&&(this.pageLeft=r.outerBounds.left,this.leftElement=r)}},n.prototype.findTop=function(t){t.first||t.second?(t.first&&this.findTop(t.first),t.second&&this.findTop(t.second)):(t.third&&this.findTop(t.third),t.fourth&&this.findTop(t.fourth));for(var e=0,i=t.objects;e=r.outerBounds.top&&(this.pageTop=r.outerBounds.top,this.topElement=r)}},n.prototype.setCurrentNode=function(t){if(this.childNode=t,t){var e=t.outerBounds;this.childLeft=Number(e.left),this.childTop=Number(e.top),this.childRight=Number(e.right),this.childBottom=Number(e.bottom)}else this.childLeft=Number.MAX_VALUE,this.childTop=Number.MAX_VALUE,this.childRight=-Number.MAX_VALUE,this.childBottom=-Number.MAX_VALUE},n.prototype.getPageBounds=function(t,e){if(this.pageLeft===Number.MAX_VALUE)return new Ne(0,0,0,0);var i=void 0!==t?Math.min(this.pageLeft,0):this.pageLeft,r=void 0!==e?Math.min(this.pageTop,0):this.pageTop;return new Ne(Math.round(i),Math.round(r),Math.round(this.pageRight-i),Math.round(this.pageBottom-r))},n.prototype.getQuad=function(t){return this.quadTable[t.id]},n}(),Voe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Yoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Voe(t,n),function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);r>3&&s&&Object.defineProperty(t,e,s)}([I(!1)],t.prototype,"preventDefaults",void 0),t}(Ee),Qoe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),JF=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Goe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qoe(t,n),JF([I("")],t.prototype,"action",void 0),JF([I("")],t.prototype,"cursor",void 0),t}(Ee),KF=function(){function n(){this.size=20,this.intermediatePoints=[],this.gridCollection=[],this.startArray=[],this.targetGridCollection=[],this.sourceGridCollection=[],this.considerWalkable=[]}return n.prototype.lineRouting=function(t){var e=t.connectors.length;if(this.renderVirtualRegion(t),e>0)for(var i=0;i=t.right||e.right<=t.left||e.top>=t.bottom||e.bottom<=t.top)},n.prototype.findEndPoint=function(t,e,i){var r,s;if(e&&""!==t.sourcePortID&&t.sourcePortWrapper||!e&&""!==t.targetPortID&&t.targetPortWrapper){s=zo(r=e?{x:t.sourcePortWrapper.offsetX,y:t.sourcePortWrapper.offsetY}:{x:t.targetPortWrapper.offsetX,y:t.targetPortWrapper.offsetY},void 0,e?t.sourceWrapper.bounds:t.targetWrapper.bounds);var o=e?t.sourcePortWrapper.bounds:t.targetPortWrapper.bounds;r=i?"Top"===s?{x:o.topCenter.x,y:o.topCenter.y}:"Left"===s?{x:o.middleLeft.x,y:o.middleLeft.y}:"Right"===s?{x:o.middleRight.x,y:o.middleRight.y}:{x:o.bottomCenter.x,y:o.bottomCenter.y}:{x:o.center.x,y:o.center.y}}else r=e&&this.startNode||!e&&this.targetNode?e?{x:this.startNode.wrapper.offsetX,y:this.startNode.wrapper.offsetY}:{x:this.targetNode.wrapper.offsetX,y:this.targetNode.wrapper.offsetY}:e?{x:t.sourcePoint.x,y:t.sourcePoint.y}:{x:t.targetPoint.x,y:t.targetPoint.y};return r},n.prototype.refreshConnectorSegments=function(t,e,i,r){var h,c,f,p,g,y,S,b,M,w,C,s=e.sourceID,o=e.targetID,a=e.sourcePortID,l=e.targetPortID;if(function Fre(n,t){var e=0;return n.constraints&qe.LineRouting?e=n.constraints&qe.LineRouting:n.constraints&qe.InheritLineRouting&&(e=t.constraints&nt.LineRouting),e}(e,t)||r){this.startNode=t.nameTable[""+s],this.targetNode=t.nameTable[""+o],this.intermediatePoints=[],this.startArray=[],this.targetGridCollection=[],this.sourceGridCollection=[],this.startGrid=void 0,this.targetGrid=void 0;for(var D=0;D0;){var L=this.startArray.pop();if(L){for(D=0;D1&&(e.segments=[]),this.updateConnectorSegments(t,this.intermediatePoints,this.gridCollection,e,i)){this.considerWalkable=[];break e}this.targetGridCollection.splice(this.targetGridCollection.indexOf(O),1),L=this.startArray.pop()}}L&&this.findPath(L)}}}},n.prototype.checkChildNodes=function(t,e){var i=!1,r=!1;if(t.nodeId.length>=1&&!e)for(var s=0;s1&&this.targetGridCollection[0].nodeId.length>1)for(var c=0;c<=1;c++){for(var d=this.targetGridCollection[parseInt(c.toString(),10)].gridX,u=this.targetGridCollection[parseInt(c.toString(),10)].gridY,f=this.targetGridCollection[parseInt(c.toString(),10)].nodeId,p=void 0,g=0;g=e.right&&t.top<=e.top&&t.bottom>=e.bottom},n.prototype.getEndvalue=function(t,e){return this.gridCollection[t.gridX][t.gridY].walkable?t:"left"===e?this.getEndvalue(this.gridCollection[t.gridX-1][t.gridY],e):"right"===e?this.getEndvalue(this.gridCollection[t.gridX+1][t.gridY],e):"top"===e?this.getEndvalue(this.gridCollection[t.gridX][t.gridY-1],e):"bottom"===e?this.getEndvalue(this.gridCollection[t.gridX][t.gridY+1],e):t},n.prototype.changeValue=function(t,e,i){t.walkable||this.considerWalkable.push(t);for(var r,s=0;s<=e;s++)"left"===i?r=this.gridCollection[t.gridX-s][t.gridY]:"right"===i?r=this.gridCollection[t.gridX+s][t.gridY]:"top"===i?r=this.gridCollection[t.gridX][t.gridY-s]:"bottom"===i&&(r=this.gridCollection[t.gridX][t.gridY+s]),r.walkable||this.considerWalkable.push(r)},n.prototype.getIntermediatePoints=function(t){var e;for(this.intermediatePoints=[];t;)this.intermediatePoints.push({x:t.gridX,y:t.gridY}),t=t.parent;this.intermediatePoints.reverse(),this.intermediatePoints.length>=1&&void 0!==this.intermediatePoints[0]&&void 0!==this.intermediatePoints[1]&&(this.intermediatePoints[0].x===this.intermediatePoints[1].x?this.intermediatePoints[0].yi.y&&o.y>s.y){for(var a=i.xi.x&&o.x>s.x)){for(var u=i.y=1&&u.length>1&&(g=u[u.length-2].x!==u[u.length-1].x?u[u.length-2].x>u[u.length-1].x?"Left":"Right":u[u.length-2].y>u[u.length-1].y?"Top":"Bottom"),M>=2&&v===g&&u.length>1&&u.splice(u.length-2,1),v=g);if(u&&u.length>1){for(var w=0;wD.x?S.bounds.middleLeft:S.bounds.middleRight),w===u.length-2&&""===r.targetPortID&&y&&(l=C.x>D.x?y.bounds.middleRight:y.bounds.middleLeft),0===w&&b&&(C.x=b.x,C.y=D.y=b.y,b=qa(r,0,b,Nl(S.bounds,_n(C.x>D.x?"Left":"Right")),!1),C.x=b.x),w===u.length-2&&l&&(w>0&&r.targetDecorator&&l.x-D.x<0&&Math.abs(l.x-C.x)0&&r.targetDecorator&&l.x-D.x>0&&Math.abs(l.x-C.x)D.y?S.bounds.topCenter:S.bounds.bottomCenter),w===u.length-2&&""===r.targetPortID&&y&&(l=C.y>D.y?y.bounds.bottomCenter:y.bounds.topCenter),0===w&&b&&(C.y=b.y,C.x=D.x=b.x,b=qa(r,0,b,Nl(S.bounds,_n(C.y>D.y?"Top":"Bottom")),!1),C.y=b.y),w===u.length-2&&l&&(w>0&&r.targetDecorator&&l.y-D.y<0&&Math.abs(l.y-C.y)0&&r.targetDecorator&&l.y-D.y>0&&Math.abs(l.y-C.y)D.x?(f="Left",p=C.x-D.x):(f="Right",p=D.x-C.x):C.y>D.y?(f="Top",p=C.y-D.y):(f="Bottom",p=D.y-C.y),o.push({type:"Orthogonal",length:p,direction:f})}}if(o&&o.length>0){var L=o[o.length-1];if(1===o.length&&(L.length-=20),L.length<10&&2===o.length&&(o.pop(),o.length>0&&(o[0].length-=20,L=o[0])),r.targetDecorator&&("Top"===L.direction||"Bottom"===L.direction)&&L.length>r.targetDecorator.height+1||("Right"===L.direction||"Left"===L.direction)&&L.length>r.targetDecorator.width+1)return r.segments=o,s&&t.connectorPropertyChange(r,{},{type:"Orthogonal",segments:o}),!0}return!1},n.prototype.findPath=function(t){for(var e,i=[],r=this.findNearestNeigbours(t,this.gridCollection,!0),s=0;sl)&&(e.x!==t.gridX||e.y!==t.gridY)&&(i.push(e),o.previousDistance=l,o.afterDistance=o.afterDistance||this.manhattan(Math.abs(e.x-this.targetGrid.gridX),Math.abs(e.y-this.targetGrid.gridY)),o.totalDistance=o.previousDistance+o.afterDistance,o.parent=t)}if(i.length>0)for(s=0;st?i*t+e:i*e+t},n.prototype.manhattan=function(t,e){return t+e},n.prototype.findNearestNeigbours=function(t,e,i){var r=[],s=t.parent;if(s){var o=(t.gridX-s.gridX)/Math.max(Math.abs(t.gridX-s.gridX),1),a=(t.gridY-s.gridY)/Math.max(Math.abs(t.gridY-s.gridY),1);0!==o?(this.isWalkable(t.gridX,t.gridY-1,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX][t.gridY-1])&&r.push(e[t.gridX][t.gridY-1]),this.isWalkable(t.gridX,t.gridY+1,!0)&&this.sourceGridCollection.indexOf(e[t.gridX][t.gridY+1])&&r.push(e[t.gridX][t.gridY+1]),this.isWalkable(t.gridX+o,t.gridY,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX+o][t.gridY])&&r.push(e[t.gridX+o][t.gridY])):0!==a&&(this.isWalkable(t.gridX-1,t.gridY,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX-1][t.gridY])&&r.push(e[t.gridX-1][t.gridY]),this.isWalkable(t.gridX+1,t.gridY,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX+1][t.gridY])&&r.push(e[t.gridX+1][t.gridY]),this.isWalkable(t.gridX,t.gridY+a,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX][t.gridY+a])&&r.push(e[t.gridX][t.gridY+a]))}else this.neigbour(t,"top",r,i),this.neigbour(t,"right",r,i),this.neigbour(t,"bottom",r,i),this.neigbour(t,"left",r,i);return r},n.prototype.neigbour=function(t,e,i,r){for(var o,s=1;s>0;){var a="top"===e||"bottom"===e?t.gridX:"left"===e?t.gridX-s:t.gridX+s,l="right"===e||"left"===e?t.gridY:"top"===e?t.gridY-s:t.gridY+s;if((o=this.gridCollection[parseInt(a.toString(),10)][parseInt(l.toString(),10)])&&(r&&-1===this.sourceGridCollection.indexOf(o)||!r&&-1===this.targetGridCollection.indexOf(o)))return i&&this.isWalkable(a,l)&&i.push(o),s;if(!(a>0&&l>0))break;s++}return null},n.prototype.resetGridColl=function(t,e,i){for(var s,r=1;r>0;){var o="top"===e||"bottom"===e?t.gridX:"left"===e?t.gridX-r:t.gridX+r,a="right"===e||"left"===e?t.gridY:"top"===e?t.gridY-r:t.gridY+r;if((s=this.gridCollection[parseInt(o.toString(),10)][parseInt(a.toString(),10)])&&(i&&-1===this.sourceGridCollection.indexOf(s)||!i&&-1===this.targetGridCollection.indexOf(s))){if(this.isWalkable(o,a))break;var l=this.gridCollection[parseInt(o.toString(),10)][parseInt(a.toString(),10)];this.considerWalkable.push(l)}if(!(o>0&&a>0))break;"top"===e||"left"===e?r--:r++}return null},n.prototype.isWalkable=function(t,e,i){if(t>=0&&t=0&&e0?1:-1,this.isWalkable(h,c-1)&&!this.isWalkable(h-a,c-1)||this.isWalkable(h,c+1)&&!this.isWalkable(h-a,c+1)))return{x:t,y:e};if(0!==l){if(l=l>0?1:-1,this.isWalkable(h-1,c)&&!this.isWalkable(h-1,c-l)||this.isWalkable(h+1,c)&&!this.isWalkable(h+1,c-l))return{x:t,y:e};if(this.findIntermediatePoints(h+1,c,h,c,s,o)||this.findIntermediatePoints(h-1,c,h,c,s,o))return{x:t,y:e}}return this.findIntermediatePoints(h+a,c+l,h,c,s,o)},n.prototype.destroy=function(){},n.prototype.getModuleName=function(){return"LineRouting"},n}(),Xoe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),$oe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Xoe(t,n),function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);r>3&&s&&Object.defineProperty(t,e,s)}([I(!0)],t.prototype,"inversedAlignment",void 0),t}(Ee),Zoe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Oe=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},wT=function(n,t,e,i){return new(e||(e=Promise))(function(r,s){function o(h){try{l(i.next(h))}catch(c){s(c)}}function a(h){try{l(i.throw(h))}catch(c){s(c)}}function l(h){h.done?r(h.value):new e(function(c){c(h.value)}).then(o,a)}l((i=i.apply(n,t||[])).next())})},CT=function(n,t){var i,r,s,o,e={label:0,sent:function(){if(1&s[0])throw s[1];return s[1]},trys:[],ops:[]};return o={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function a(h){return function(c){return function l(h){if(i)throw new TypeError("Generator is already executing.");for(;e;)try{if(i=1,r&&(s=2&h[0]?r.return:h[0]?r.throw||((s=r.return)&&s.call(r),0):r.next)&&!(s=s.call(r,h[1])).done)return s;switch(r=0,s&&(h=[2&h[0],s.value]),h[0]){case 0:case 1:s=h;break;case 4:return e.label++,{value:h[1],done:!1};case 5:e.label++,r=h[1],h=[0];continue;case 7:h=e.ops.pop(),e.trys.pop();continue;default:if(!(s=(s=e.trys).length>0&&s[s.length-1])&&(6===h[0]||2===h[0])){e=0;continue}if(3===h[0]&&(!s||h[1]>s[0]&&h[1]0&&((!s.style||!s.style.fill)&&(o.style.fill="transparent"),(!s.style||!s.style.strokeColor)&&(o.style.strokeColor="transparent")),s.shape&&"UmlActivity"===s.shape.type&&$I(s,o),s.shape&&"SwimLane"===s.shape.type&&sF(s,o),r.nodeDefaults&&Ro(o,s,r.nodeDefaults),r.updateAnnotationText(o.annotations);if(e&&e.connectors)for(a=0;e&&e.connectors&&a0&&0===i.nodes.length)this.clearCollection(),a=!0;else{for(var g=0,v=Object.keys(e.nodes);g0&&0===i.connectors.length)this.clearCollection(!0),a=!0;else{for(var C=0,D=Object.keys(e.connectors);C0){this.renderSelector(!0);break}if(e.selectedItems.constraints){this.renderSelector(!0);break}break;case"snapSettings":this.updateSnapSettings(e);break;case"commandManager":this.initCommands();break;case"layout":o=!0;break;case"segmentThumbShape":this.updateSelector();break;case"dataSourceSettings":this.clear(),"None"===this.layout.type?a=!0:(this.initObjects(),o=!0);break;case"tooltip":e3(this);break;case"rulerSettings":this.updateRulerSettings(e);break;case"layers":this.updateLayer(e);break;case"scrollSettings":this.scrollActions|=da.PropertyChange,this.updateScrollSettings(e),this.scrollActions&=~da.PropertyChange,this.scrollSettings.horizontalOffset=-this.scroller.horizontalOffset||0,this.scrollSettings.verticalOffset=-this.scroller.verticalOffset||0;break;case"locale":e.locale!==i.locale&&(this.realActions|=$i.PreventDataInit,n.prototype.refresh.call(this),this.realActions&=~$i.PreventDataInit);break;case"contextMenuSettings":if(void 0!==e.contextMenuSettings.showCustomMenuOnly&&(this.contextMenuSettings.showCustomMenuOnly=e.contextMenuSettings.showCustomMenuOnly),void 0!==e.contextMenuSettings.show&&(this.contextMenuSettings.show=e.contextMenuSettings.show),e.contextMenuSettings.items){for(var A=e.contextMenuSettings.items,x=0,P=Object.keys(A);x0){for(var N=[],T=O.ports.length-1;T>=0;T--)"LineDistribution"===O.ports[parseInt(T.toString(),10)].id.split("_")[1]&&N.push(O.ports[parseInt(T.toString(),10)]);this.removePorts(O,N)}}for(T=0;T0)for(var ue=0,fe=Object.keys(e.nodes);ue0)for(var De=0,xe=Object.keys(e.connectors);De=0;o--)this.commandHandler.expandNode(r[parseInt(o.toString(),10)],this,0!==o);this.canLayout&&this.doLayout(),this.lineRoutingModule?this.connectors.sourceID!==this.connectors.targetID&&this.lineRoutingModule.lineRouting(this):this.constraints&nt.LineRouting&&console.warn('[WARNING] :: Module "LineRouting" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),this.validatePageSize(),this.renderPageBreaks(),this.diagramRenderer.renderSvgGridlines(this.snapSettings,Fd(this.element.id),this.scroller.transform,this.rulerSettings,this.hRuler,this.vRuler),this.commandHandler.initSelectorWrapper(),this.notify("initial-load",{}),this.trigger("load"),this.scroller.setSize(),this.scroller.updateScrollOffsets(),this.isRefreshed||this.refreshDiagramLayer(),(this.scrollSettings.verticalOffset>0||this.scrollSettings.horizontalOffset>0)&&this.updateScrollOffset(),X.isDevice&&(this.tool=ri.ZoomPan|ri.SingleSelect),this.notify("initial-end",{}),this.isProtectedOnChange=!1,this.tooltipObject=e3(this),this.diagramActions=ee.Render,this.initCommands();var a=document.getElementsByClassName(this.element.id+"_hiddenUserHandleTemplate");(function yoe(n,t,e,i){var r,s,o,a,l,d=document.getElementById(i).ej2_instances[0];if(n&&t){r=FF(n);for(var u=0,f=e.userHandles;u0;)e[0].parentNode.removeChild(e[0]);var i=document.getElementById(this.element.id+"content");i&&this.element.removeChild(i);var r="measureElement";if(window[""+r]){window[""+r].usageCount-=1;var s="measureElementCount";window[""+s]--,0===window[""+s]&&(window[""+r].parentNode.removeChild(window[""+r]),window[""+r]=null)}}window.domTable={};for(var a=0;a1&&(this.callBlazorModel=!1,this.insertBlazorDiagramObjects(this.selectedItems),this.commandHandler.group(),this.callBlazorModel=!0,this.commandHandler.getBlazorOldValues())},t.prototype.unGroup=function(){this.callBlazorModel=!1,this.insertBlazorDiagramObjects(this.selectedItems),this.commandHandler.unGroup(),this.callBlazorModel=!0,this.commandHandler.getBlazorOldValues()},t.prototype.sendToBack=function(){this.commandHandler.sendToBack()},t.prototype.setActiveLayer=function(e){var i=this.commandHandler.getLayer(e);this.activeLayer=i},t.prototype.addLayer=function(e,i){this.commandHandler.addLayer(e,i)},t.prototype.removeLayer=function(e){this.commandHandler.removeLayer(e,ce())},t.prototype.moveObjects=function(e,i){$(this.layers),this.enableServerDataBinding(!1),this.commandHandler.moveObjects(e,i)},t.prototype.layerObjectUpdate=function(){},t.prototype.sendLayerBackward=function(e){this.layerObjectUpdate(),this.commandHandler.sendLayerBackward(e)},t.prototype.bringLayerForward=function(e){this.layerObjectUpdate(),this.commandHandler.bringLayerForward(e)},t.prototype.cloneLayer=function(e){this.commandHandler.cloneLayer(e)},t.prototype.bringToFront=function(){this.commandHandler.bringToFront()},t.prototype.moveForward=function(){this.commandHandler.sendForward()},t.prototype.sendBackward=function(){this.commandHandler.sendBackward()},t.prototype.getObject=function(e){return this.nameTable[""+e]},t.prototype.getNodeObject=function(e){return $(this.nameTable[""+e])},t.prototype.getConnectorObject=function(e){return $(this.nameTable[""+e])},t.prototype.getActiveLayer=function(){return this.activeLayer},t.prototype.nudgeCommand=function(e,i,r){if("object"!=typeof e&&(this.selectedItems.nodes.length||this.selectedItems.connectors.length)>0){var s=void 0;i.type&&"KEYDOWN"===i.type&&(s=i.type),this.nudge(e,void 0,void 0,s)}},t.prototype.nudge=function(e,i,r,s){var o=0,a=0;"Left"===e||"Right"===e?o=("Left"===e?-1:1)*(i||1):a=("Up"===e?-1:1)*(r||1),"KEYDOWN"===s&&(o*=5,a*=5);var h=this.selectedItems,c=this.selectedItems.wrapper.children[0];if(c instanceof ai)this.commandHandler.labelDrag(h.nodes[0],c,o,a);else{var d=$(this.selectedItems);this.protectPropertyChange(!0),this.drag(h,o,a),this.protectPropertyChange(!1);var u={type:"PositionChanged",redoObject:$(this.selectedItems),undoObject:d,category:"Internal"};this.addHistoryEntry(u)}this.refreshCanvasLayers()},t.prototype.insertBlazorDiagramObjects=function(e){},t.prototype.drag=function(e,i,r){if(this.insertBlazorDiagramObjects(e),!(this.bpmnModule&&e instanceof te&&this.bpmnModule.updateAnnotationDrag(e,this,i,r))){if(e instanceof ei){if(this.preventConnectorsUpdate=!0,e.nodes&&e.nodes.length){for(var o=0,a=e.nodes;o0&&o.nodes[0].children){this.fromUndo||(this.rotateUsingButton=!0);for(var h=this.commandHandler.getAllDescendants(o.nodes[0],[]),c=0;c0&&o.nodes[0].children){var g={type:"RotationChanged",redoObject:$(e),undoObject:$(o),category:"Internal",childTable:a};this.commandHandler.addHistoryEntry(g),this.commandHandler.updateSelector()}return u},t.prototype.dragSourceEnd=function(e,i,r){this.insertBlazorDiagramObjects(e),this.commandHandler.dragSourceEnd(e,i,r),this.callBlazorModel&&this.commandHandler.getBlazorOldValues()},t.prototype.dragTargetEnd=function(e,i,r){this.insertBlazorDiagramObjects(e),this.commandHandler.dragTargetEnd(e,i,r),this.callBlazorModel&&this.commandHandler.getBlazorOldValues()},t.prototype.findObjectsUnderMouse=function(e,i){return this.eventHandler.findObjectsUnderMouse(e,i)},t.prototype.findObjectUnderMouse=function(e,i,r){return this.eventHandler.findObjectUnderMouse(e,i,r)},t.prototype.findTargetObjectUnderMouse=function(e,i,r,s,o){return this.eventHandler.findTargetUnderMouse(e,i,r,s,o)},t.prototype.findElementUnderMouse=function(e,i,r,s){return this.eventHandler.findElementUnderMouse(e,i,r,s)},t.prototype.findActionToBeDone=function(e,i,r,s){return this.eventHandler.findActionToBeDone(e,i,r,s)},t.prototype.updateConnectorPort=function(e){if(e.ports.length)for(var i=void 0,r=0,s=e.ports;r=0;s--)if(i.push(r[parseInt(s.toString(),10)]),i.length>this.historyManager.stackLimit)return i}else i=r;return i},t.prototype.getEdges=function(e){return e.outEdge?this.nameTable[e.id].outEdges:this.nameTable[e.id].inEdges},t.prototype.getParentId=function(e){return this.nameTable[""+e].parentId},t.prototype.addConnector=function(e){return this.add(e)},t.prototype.UpdateBlazorDiagramModelCollection=function(e,i,r,s){},t.prototype.UpdateBlazorDiagramModel=function(e,i,r,s){},t.prototype.UpdateBlazorLabelOrPortObjects=function(e,i,r,s){},t.prototype.addBlazorDiagramObjects=function(){},t.prototype.removeNodeEdges=function(e,i,r){var s=this.nameTable[""+e],o=r?s.outEdges:s.inEdges;if(o.length>0)for(var a=0;a0)){for(var c=0;c0))}this.removePortEdges(l,a.element.sourcePortID,a.element.id,h)}a.element.targetID&&this.removeNodeEdges(a.element.targetID,a.element.id,!1)}}this.diagramActions=this.diagramActions|ee.PublicMethod,e.id=e.id||Qe();var u=this.activeLayer;if(!a.cancel&&u&&!u.lock){if(u.objects.indexOf(e.id)<0&&!u.lock&&(u.visible||(u.visible=!0,this.dataBind()),u.objects.push(e.id)),ps(e)===de)(r=new de(this,"connectors",e,!0)).status="New",this.nameTable[r.targetID]&&"TextAnnotation"===this.nameTable[r.targetID].shape.shape&&(r.isBpmnAnnotationConnector=!0,r.constraints=r.constraints&~qe.Delete),Ro(r,e,this.connectorDefaults),this.connectors.push(r),this.initObject(r),!1===e.visible&&this.updateElementVisibility(r.wrapper,r,e.visible),this.updateEdges(r),this.insertBlazorConnector(r);else{if(Ro(r=new te(this,"nodes",e,!0),e,this.nodeDefaults),r.parentId=e.parentId?e.parentId:r.parentId,r.umlIndex=e.umlIndex,r.status="New",(o="TextAnnotation"===r.shape.shape)&&!e.isTextAnnotationCopied&&(r.inEdges=e.inEdges?e.inEdges:r.inEdges),this.nodes.push(r),this.initObject(r,u,void 0,i),o&&this.bpmnModule)for(c=0;c-1&&e.parentId&&this.nameTable[e.parentId]&&"UmlClassifier"===this.nameTable[e.parentId].shape.type){var g=this.nameTable[e.parentId];g.children.splice(r.umlIndex,0,r.id),g.wrapper.children.splice(r.umlIndex,0,r.wrapper),g.wrapper.measure(new me),g.wrapper.arrange(g.wrapper.desiredSize),this.updateDiagramObject(g)}}if(a={element:r,cause:this.diagramActions,diagramAction:this.getDiagramAction(this.diagramActions),state:"Changed",type:"Addition",cancel:!1},this.parentObject&&(a.parentId=this.parentObject.id),"helper"!==e.id&&!(this.diagramActions&ee.PreventCollectionChangeOnDragOver)&&this.triggerEvent(Ce.collectionChange,a),!(this.diagramActions&ee.UndoRedo||this.diagramActions&ee.Group||this.diagramActions&ee.PreventHistory)){var v={type:"CollectionChanged",changeType:"Insert",undoObject:$(e),redoObject:$(e),category:"Internal"};this.addHistoryEntry(v)}this.parentObject=void 0,"SVG"===this.mode&&(this.updateSvgNodes(r),this.updateTextElementValue(r),this.updateDiagramObject(r),o&&this.updateDiagramObject(this.nameTable[r.inEdges[0]]),r.shape.activity&&r.shape.activity.subProcess.processes&&r.shape.activity.subProcess.processes.length&&this.updateProcesses(r),this.updateBridging())}}if(this.protectPropertyChange(s),this.resetDiagramActions(ee.PublicMethod),r&&this.layers.length>1&&this.moveNode(r),this.views)for(var S=0,b=this.views;S=0;l--)this.moveSvgNode(a[parseInt(l.toString(),10)])}for(var h=0,c=i;h=0;o--)r[parseInt(o.toString(),10)]===e.id&&r.splice(o,1);for(var a=0;s.ports&&a=0;s--)if(i=this.nameTable[r[parseInt(s.toString(),10)]])if(this.connectorTable[i.id]=$(i),i.isBpmnAnnotationConnector){var o=this.nameTable[i.targetID];this.removeObjectsFromLayer(i);var a=this.connectors.indexOf(i);-1!==a&&this.connectors.splice(a,1),this.removeElements(i),this.removeFromAQuad(i),delete this.nameTable[i.id];var l=this.nameTable[i.sourceID];if(l){var h=l.outEdges.indexOf(i.id);-1!==h&&l.outEdges.splice(h,1)}e.id!==i.targetID&&this.remove(o)}else this.remove(i)},t.prototype.removeObjectsFromLayer=function(e){if(e.children)for(var i=0;i-1&&(_r(this,e)&&this.unSelect(e),this.layers[parseInt(s.toString(),10)].objects.splice(a,1),delete this.layers[parseInt(s.toString(),10)].zIndexTable[this.nameTable[e.id].zIndex])},t.prototype.removeElements=function(e){if("SVG"===this.mode||"Canvas"===this.mode&&"Native"===e.shape.type){var i=xt(e.id+"_groupElement",this.element.id),r=e;if(r.ports&&r.ports.length>0)for(var s=0;s0){l[parseInt(s.toString(),10)].id.indexOf("icon_content")>0&&"SVG"===this.mode&&((h=xt(l[parseInt(s.toString(),10)].id+"_shape_groupElement",this.element.id))&&h.parentNode.removeChild(h),(h=xt(l[parseInt(s.toString(),10)].id+"_rect_groupElement",this.element.id))&&h.parentNode.removeChild(h));for(var c=0,d=this.views;c=0;o--)a.children[parseInt(o.toString(),10)].children&&(l=n.nameTable[a.children[parseInt(o.toString(),10)].id])&&(l.isLane?Gv(n,l):(n.removeDependentConnector(l),n.diagramActions|=ee.PreventHistory,l.constraints&ie.Delete?n.remove(l):U3(n,l,{},!1),n.diagramActions&=~ee.PreventHistory));a&&(i=n.nameTable[a.id])&&Gv(n,i)}}(this,e),!(this.diagramActions&ee.UndoRedo||this.diagramActions&ee.PreventHistory)&&(e instanceof te||e instanceof de)){var o={type:"CollectionChanged",changeType:"Remove",undoObject:$(e),redoObject:$(e),category:"Internal"};this.diagramActions&ee.Clear||e.children&&!e.isLane&&!e.isPhase&&e.children.length>0&&this.undoRedoModule&&"None"===this.layout.type&&(this.historyManager.startGroupAction(),s=!0),(e instanceof te||e instanceof de)&&this.deleteDependentConnector&&this.removeDependentConnector(e),!e.isLane&&!e.isPhase&&!(this.diagramActions&ee.Clear)&&!this.isStackChild(e)&&this.addHistoryEntry(o)}"TextAnnotation"===e.shape.shape&&this.removeDependentConnector(e),e.children&&!e.isLane&&!e.isPhase&&(!(this.diagramActions&ee.UndoRedo)||!ce())&&this.deleteGroup(e),e.parentId&&(this.deleteChild(e,void 0,!0),this.nameTable[e.parentId]&&"UmlClassifier"===this.nameTable[e.parentId].shape.type&&(this.updateDiagramObject(this.nameTable[e.parentId]),this.updateConnectorEdges(this.nameTable[e.parentId])));var a=void 0;this.diagramActions=this.diagramActions|ee.PublicMethod;var l=this.nameTable[e.id];if(l instanceof te?("Bpmn"===l.shape.type&&this.bpmnModule&&this.bpmnModule.removeBpmnProcesses(l,this),(l.isLane||l.isPhase||"SwimLane"===l.shape.type)&&(h=l.isLane||l.isPhase?this.nameTable[l.parentId]:this.nameTable[l.id],l.isLane?B3(this,l,h):l.isPhase&&F3(this,l,h)),-1!==(a=this.nodes.indexOf(l))&&(this.crudDeleteNodes.push(this.nameTable[l.id]),this.nodes.splice(a,1),this.updateNodeEdges(l))):(-1!==(a=this.connectors.indexOf(l))&&(this.crudDeleteNodes.push(this.nameTable[l.id]),this.connectors.splice(a,1)),this.updateEdges(l),this.spliceConnectorEdges(e,!0),this.spliceConnectorEdges(e,!1)),!this.isServerUpdate&&!(this.blazorActions&on.GroupClipboardInProcess)&&this.commandHandler.getBlazorOldValues(),s&&this.historyManager.endGroupAction(),_r(this,l)&&this.unSelect(l),!l.isPhase){if(this.removeObjectsFromLayer(e),this.currentDrawingObject&&(this.currentDrawingObject.wrapper=void 0),delete this.nameTable[e.id],i.length>0&&i[0].id===l.id&&l.parentId){var h,d=this.nameTable[l.parentId];d&&d.isLane&&"SwimLane"===this.nameTable[d.parentId].shape.type&&H3(this,h=this.nameTable[d.parentId],d,l)}this.removeElements(l),this.updateBridging(),"SVG"!==this.mode&&this.refreshDiagramLayer(),this.diagramActions&ee.Clear||(this.removeFromAQuad(l),r={element:e,cause:this.diagramActions,diagramAction:this.getDiagramAction(this.diagramActions),state:"Changed",type:"Removal",cancel:!1},"helper"!==e.id&&this.triggerEvent(Ce.collectionChange,r),this.resetTool())}}}else if(i.length>0){this.undoRedoModule&&(this.historyManager.startGroupAction(),this.blazorActions|=on.GroupingInProgress,s=!0);for(var u=0;u=p.wrapper.bounds.width&&"Horizontal"===p.shape.orientation||this.selectedItems.wrapper.bounds.y<=p.wrapper.bounds.y+g&&this.selectedItems.wrapper.bounds.height>=p.wrapper.bounds.height-g&&"Vertical"===p.shape.orientation)&&(DI(p)||p.shape.lanes.length>1)&&this.remove(i[parseInt(u.toString(),10)])}}else this.remove(i[parseInt(u.toString(),10)])}s&&(this.blazorActions&=~on.GroupingInProgress,this.isServerUpdate=!0,this.commandHandler.getBlazorOldValues(),this.UpdateBlazorDiagramModelCollection(void 0,void 0,void 0,!0),this.historyManager.endGroupAction(),this.isServerUpdate=!1),this.clearSelection()}e&&(DI(e)||this.diagramActions&ee.Clear)||this.diagramActions&ee.UndoRedo||this.diagramActions&ee.PreventHistory||!(e instanceof te||e instanceof de)||(o={type:"ConnectionChanged",undoObject:$(e),redoObject:$(e),category:"Internal"},!e.isLane&&!e.isPhase&&!(this.diagramActions&ee.Clear)&&!this.isStackChild(e)&&this.addHistoryEntry(o)),this.tooltipObject.close()},t.prototype.isStackChild=function(e){var i,r=this.nameTable[e.parentId];if(e&&e.parentId&&r.container&&"Stack"===r.container.type&&"UmlClassifier"!==this.nameTable[e.parentId].shape.type){i=!0;var s={sourceIndex:r.wrapper.children.indexOf(e.wrapper),source:e,target:void 0,targetIndex:void 0};this.diagramActions&ee.UndoRedo||this.addHistoryEntry({type:"StackChildPositionChanged",redoObject:{sourceIndex:void 0,source:e,target:void 0,targetIndex:void 0},undoObject:s,category:"Internal"})}return i},t.prototype.deleteChild=function(e,i,r){var s;if(s="string"==typeof e?e:e.id,(i=i?this.nameTable[i.id]:this.nameTable[e.parentId])&&i.children){for(var o=0;o=0;i--)this.removeLayer(this.layers[parseInt(i.toString(),10)].id);this.commandHandler.addLayer({id:"default_layer",visible:!0,lock:!1,objects:[],zIndex:0,objectZIndex:-1,zIndexTable:{}},null,!0),this.setActiveLayer(this.layers[this.layers.length-1].id)},t.prototype.clearObjects=function(e){var i=[];i=e||(i=i.concat(this.nodes)).concat(this.connectors),this.diagramActions=this.diagramActions|ee.Clear;for(var r=0,s=i;r0||"Text"===e.shape.type))if("Text"===e.shape.type)i=e.wrapper.children[0].id.split("_")[1];else for(var p=e.annotations.length-1;p>=0;p--)e.annotations[parseInt(p.toString(),10)].visibility&&(i=e.annotations[parseInt(p.toString(),10)].id);i&&(u=this.getWrapper(e.wrapper,i))}if(e&&u&&!(u instanceof es)&&(!function Qre(n,t){return"Text"===t.shape.type?t.constraints&ie.ReadOnly:t.constraints&(t instanceof de?qe.ReadOnly:ie.ReadOnly)?n.constraints&Nr.InheritReadOnly?1:0:n.constraints&Nr.ReadOnly?1:0}(u,e)||f)){var g=u.style,v=void 0;v=90>(v=u.bounds.width50?50:e.width,u.style.fontSize)),e.parentId&&"UmlClassifier"===this.nameTable[e.parentId].shape.type?(l.width=e.wrapper.bounds.width-20,c=(e.wrapper.bounds.center.x+r.tx)*r.scale-l.width/2*s-2.5,d=(e.wrapper.bounds.center.y+r.ty)*r.scale-l.height/2*s-3,u.style.textAlign="Left"):(l.width=Math.max(l.width,50),c=(u.bounds.center.x+r.tx)*r.scale-l.width/2*s-2.5,d=(u.bounds.center.y+r.ty)*r.scale-l.height/2*s-3),Ho(y,{id:this.element.id+"_editTextBoxDiv",style:"position: absolute;left:"+c+"px;top:"+d+"px;width:"+(l.width+1)*s+"px;height:"+l.height*s+"px; containerName:"+e.id+";"}),Ho(S,{"aria-label":a,id:this.element.id+"_editBox",style:"width:"+(l.width+1)*s+"px;height:"+l.height*s+"px;resize: none;outline: none;overflow: hidden;;font-family:"+g.fontFamily+";font-size:"+g.fontSize*s+"px;text-align:"+u.style.textAlign.toLocaleLowerCase()+";",class:"e-diagram-text-edit"}),S.style.fontWeight=g.bold?"bold":"",S.style.fontStyle=g.italic?"italic":"",S.style.lineHeight=(1.2*g.fontSize+"px;").toString(),S.style.textDecoration=g.textDecoration?g.textDecoration:"",this.activeLabel.parentId=e.id,this.activeLabel.id=i,u.visible=!1,this.updateDiagramObject(e),this.diagramActions=this.diagramActions|ee.TextEdit,this.isTriggerEvent||(E.add(S,"input",this.eventHandler.inputChange,this.eventHandler),E.add(S,"focusout",this.focusOutEdit,this),S.select())}}}},t.prototype.updateConnectorfixedUserHandles=function(e){if(e.fixedUserHandles.length)for(var i=void 0,r=0,s=e.fixedUserHandles;r0&&this.mindMapChartModule.updateLayout(o,this.nameTable,this.layout,l,this.dataSourceSettings.id,this.dataSourceSettings.root),e=!0;else if(this.radialTreeModule)this.radialTreeModule.updateLayout(o,this.nameTable,this.layout,l),e=!0;else if(this.symmetricalLayoutModule)this.symmetricalLayoutModule.maxIteration=this.layout.maxIteration,this.symmetricalLayoutModule.springLength=this.layout.springLength,this.symmetricalLayoutModule.springFactor=this.layout.springFactor,this.symmetricalLayoutModule.updateLayout(o,this.connectors,this.symmetricalLayoutModule,this.nameTable,this.layout,l),e=!0;else if(this.complexHierarchicalTreeModule){this.canDistribute(a,r)&&(this.lineDistributionModule.diagram=this,this.connectors.forEach(function(P){P.obstaclePointCollection=[]}));var c=this.complexHierarchicalTreeModule.getLayoutNodesCollection(this.nodes);c.length>0&&this.complexHierarchicalTreeModule.doLayout(c,this.nameTable,this.layout,l,this),e=!0,this.canDistribute(a,r)&&this.lineDistributionModule.initLineDistribution(this.layout,this)}else this.flowchartLayoutModule?(this.flowchartLayoutModule.updateLayout(this.nodes,this),e=!0):console.warn("[WARNING] :: Module "+("OrganizationalChart"===this.layout.type?"HierarchicalTree":this.layout.type)+" is not available in Diagram component! You either misspelled the module name or forgot to load it.");if(e){this.preventDiagramUpdate=!0;for(var u={},p=0,g=o;p0)for(var S=0;S0)for(var M=0;M0)for(var s=0,o=r.ports;s0&&function wse(n){var t,e,i,r=[];for(t=0;t0&&y.connectors[w].bezierSettings&&y.connectors[w].bezierSettings.allowSegmentsReset&&(y.connectors[w].segments=[]);if(t.connectors=y.connectors||[],t.dataSourceSettings=y.dataSourceSettings||{},t.dataSourceSettings.doBinding=i,t.height=y.height||"100%",t.setNodeTemplate=r,t.getConnectorDefaults=v,t.getNodeDefaults=g,t.getCustomProperty=o,t.mode=y.mode||"SVG",y.nodes)for(w=0;w0)){var r=this.nodes.filter(function(a){return 0===a.inEdges.length})[0],s=this.convertMindmapToMermaid(r,0);i.push(s),this.updateTextDataSource(i,r.outEdges,1),e=(i=i.filter(function(a){return""!==a.trim()})).join("\n")}return e},t.prototype.updateTextDataSource=function(e,i,r){for(var s=0;s0&&this.updateTextDataSource(e,h,r+1),s++}},t.prototype.convertMindmapToMermaid=function(e,i){var r=e.id,o=" ".repeat(2*(i+1)),a=e.annotations.length>0?e.annotations[0].content.replace(/\n/g," "):"",l=o+a,h=o+r;if(e.shape&&"Basic"===e.shape.type){var c=e.shape;"Rectangle"===c.shape?l=h+"["+a+"]":"Ellipse"===c.shape?l=h+"(("+a+"))":"Hexagon"===c.shape&&(l=h+"{{"+a+"}}")}else if(e.shape&&"Flow"===e.shape.type)"Terminator"===e.shape.shape&&(l=h+"("+a+")");else if(e.shape&&"Path"===e.shape.type){var u=e.shape;u.data===this.bangShape?l=h+"))"+a+"((":u.data===this.cloudShape&&(l=h+")"+a+"(")}return l},t.prototype.saveFlowDiagramInMermaidFormat=function(){var e=this,i=[],r="graph TD\n",s={nodes:this.nodes,edges:this.connectors};return s.nodes.reduce(function(a,l){return a[l.id]=l.annotations.length?l.annotations[0].content:"",a},{}),s.edges.forEach(function(a){var l=a.sourceID,h=a.targetID,f=e.nameTable[""+h],p=e.getNodeShape(e.nameTable[""+l]),g=e.getNodeShape(f),v=a.annotations[0]&&""!==a.annotations[0].content?"|"+a.annotations[0].content+"|":"";-1===i.indexOf(l)?i.push(l):p="",-1===i.indexOf(h)?i.push(h):g="";var y=e.arrowType(a);r+=" "+l+p+" "+y+v+" "+h+g+"\n"}),s.nodes.forEach(function(a){r+=" style "+a.id+" fill:"+a.style.fill+",stroke:"+a.style.strokeColor+",stroke-width:"+a.style.strokeWidth+"px;\n"}),r},t.prototype.arrowType=function(e){var i=e.targetDecorator.shape;return e.style.opacity<1?"~~~":""!==e.style.strokeDashArray?"-.->":"Arrow"===i?e.style.strokeWidth>1?"==>":"--\x3e":"None"===i?"---":"--\x3e"},t.prototype.getNodeShape=function(e){var i=e.annotations.length>0?e.annotations[0].content:"",r=e.shape.shape;if(!r){var s=e.shape.data;return"M 0 0 A 1 1 0 0 0 7 0 A 1 1 0 0 0 0 0 M -1 0 A 1 1 0 0 0 8 0 A 1 1 0 0 0 -1 0"===s?"((("+i+")))":"M 0 0 L 1 -1 L 5 -1 L 6 0 L 0 0"===s?"[/"+i+"\\]":"M 0 1 L 0 6 C 2 7 4 7 6 6 L 6 1 C 5 0 1 0 0 1 C 1 2 5 2 6 1"===s?"[("+i+")]":"M 0 0 L 12 0 L 14 2 L 2 2 L 0 0"===s?"[\\"+i+"\\]":"M 0 0 L 5 0 L 4 1 L 1 1 L 0 0"===s?"[\\"+i+"/]":"M 0 0 L 2 -2 L 11 -2 L 13 0 L 11 2 L 2 2 L 0 0"===s?"{{"+i+"}}":">"+i+"]"}switch(r){case"Terminator":return"(["+i+"])";case"Process":default:return"["+i+"]";case"Decision":return"{"+i+"}";case"Parallelogram":return"[/"+i+"/]";case"Ellipse":return"(("+i+"))";case"PreDefinedProcess":return"[["+i+"]]"}},t.prototype.loadDiagramFromMermaid=function(e){this.layout&&"Flowchart"===this.layout.type&&this.flowchartLayoutModule?this.convertMermaidToFlowChart(e):this.layout&&"MindMap"===this.layout.type&&this.mindMapChartModule?this.convertMermaidToMindmap(e):console.warn('[WARNING] :: Module "FlowchartLayout" or "MindMap" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.countLeadingSpaces=function(e){for(var i=0,r=e.length;i0});this.clear(),this.mermaidNodeBaseCollection=[];var r=[],s={text:"",children:[],currentLevel:0,branch:"Left"},o=[],l=!1,h=!1,c=!1;if(i.length>0){for(var d=function(M){var w=i[parseInt(M.toString(),10)],C=0,D="",A=u.countLeadingSpaces(w),x=w.includes('"`');if(h=w.includes('`"'),c=(l=!!x||l)||c?c:0===A&&M>0,l&&h&&!x)return s.text+="\n"+w,l=!1,"continue";if(!x&&l)return s.text+="\n"+w,"continue";if(l=!h&&l,w.length>0&&(/\s/.test(w[0])&&M>0||0===A)){if(-1!==o.findIndex(function(B){return B.space===A.toString()}))for(var L=o.length-1;L>=0;L--){var O=o[parseInt(L.toString(),10)];if((N=parseFloat(O.space))>A)o.splice(L,1);else{if(N=0;L--){var N,T=o[parseInt(L.toString(),10)];if(!((N=parseFloat(T.space))>A)){var z=o[o.length-1];o.push({space:A.toString(),level:z.level+1});break}o.splice(L,1)}C=o[o.length-1].level}D=w.trim().replace(/^[+-]/,"")}var U={text:D,branch:void 0,children:[],currentLevel:0===M?0:C-1};if(r.length>0){for(;r.length>=C&&0!==r.length;)r.pop();r.length>0&&r[r.length-1].children.push(U)}r.push(U),s=U},u=this,f=0;f0){var c=h[h.length-1];c.arrowType=a[2],""!==a[3]&&(c.label&&c.label.some(function(d){return d.trim().length>0})?c.label.push(a[3]):(c.label=[],c.label[c.parentId.length-1]=a[3]))}h.filter(function(d){return d.parentId&&0===d.parentId.length}).forEach(function(d){d.parentId=null}),i=i.concat(h)}}this.createFlowChart(i),this.doLayout(),this.clearHistory()},t.prototype.createFlowChart=function(e){for(var i=[],r=0;r1)for(var h=0;h|---|--\s*.*?\s*-->|~~~|==>|===|==\s*.*?\s*==>|\s*-\.\s*->|\s*-\.\s*-|\s*-\.\s*.*?\s*\.\s*->|\s*-\..*?\.\s*->)(.*)$/);if(l){i=l[1].trim();var h=l[2].trim();r=l[3].trim();var d=h.match(/(-\.|\\-\\-|==|--|~~)(.*?)(\1>|\.->|==>|\\->|~~>)/),u=void 0,f="";o=null!==(u=d?{text:d[2].trim()||null,arrowType:d[1]+d[3]}:{text:null,arrowType:h}).text?u.text:"",s=(f=u.arrowType).includes("--\x3e")?"single-line-arrow":f.includes("---")?"single-line":f.includes("==>")?"double-line-arrow":f.includes("==")?"double-line":f.includes("~~~")?"wiggly-arrow":f.includes("-.->")||f.includes(".->")?"dotted-arrow":f.includes("-.-")||f.includes(".-")?"dotted":"single-line-arrow"}return[i,r,s,o]},t.prototype.parseStyle=function(e,i){if(e.startsWith("style")){var s=e.match(/^style\s+(\w+)\s+fill:([^,]+),stroke:([^,]+),stroke-width:(\d+)px;/);if(s){var c={id:s[1],fill:s[2],stroke:s[3],strokeWidth:parseInt(s[4],10)},d=i.filter(function(u){return u.id===c.id});d[0].color=c.fill,d[0].stroke=c.stroke,d[0].strokeWidth=c.strokeWidth}}},t.prototype.getNodeData=function(e,i,r){for(var s=[],o=null,a=null,l=0,h="",c=function(v){var y=e[parseInt(v.toString(),10)],S=d.splitNested(y);if(S[0].includes("|")){var b=S[0].match(/\|([^|]*)\|/);b&&(h=b[1]);var M=S[0].split("|");M.length>=3&&(S[0]=M[2].trim())}var w=S[0].trim();if(0===v?o=w:a=w,i.find(function(L){return L.id===w}))l++;else{var D=S.length>1?S[1]:S[0],A=d.getShape(D),x=D.replace(/[\\[\]\\(\\)\\{\\}\\{\\}\\/>]/g,"");s.push({id:w,name:x,shape:A,color:"white",parentId:[]})}},d=this,u=0;u"===h?0===s?(r.trim().length>0&&i.push(r.trim()),r=h,o=h,s++):(r+=h,s++):"]"===h||"}"===h||")"===h?1===s&&h===o?(i.push((r+=h).trim()),r="",s--):s>1?(r+=h,s--):r+=h:r+=h}return r.trim().length>0&&i.push(r.trim()),i},t.prototype.getShape=function(e){var i={};return e.startsWith("(((")?i={type:"Path",data:"M 0 0 A 1 1 0 0 0 7 0 A 1 1 0 0 0 0 0 M -1 0 A 1 1 0 0 0 8 0 A 1 1 0 0 0 -1 0"}:e.startsWith("((")?i={shape:"Ellipse",type:"Basic"}:e.startsWith("([")?i={type:"Flow",shape:"Terminator"}:e.startsWith("(")?i={type:"Flow",shape:"Process"}:e.startsWith("[[")?i={type:"Flow",shape:"PreDefinedProcess"}:e.startsWith("[/")?i=e.endsWith("/]")?{type:"Basic",shape:"Parallelogram"}:{type:"Path",data:"M 0 0 L 1 -1 L 5 -1 L 6 0 L 0 0"}:e.startsWith("[(")?i={type:"Path",data:"M 0 1 L 0 6 C 2 7 4 7 6 6 L 6 1 C 5 0 1 0 0 1 C 1 2 5 2 6 1"}:e.startsWith("[\\")?i=e.endsWith("\\]")?{type:"Path",data:"M 0 0 L 12 0 L 14 2 L 2 2 L 0 0"}:{type:"Path",data:"M 0 0 L 5 0 L 4 1 L 1 1 L 0 0"}:e.startsWith("[")?i={type:"Basic",shape:"Rectangle"}:e.startsWith("{{")?i={type:"Path",data:"M 0 0 L 2 -2 L 11 -2 L 13 0 L 11 2 L 2 2 L 0 0"}:e.startsWith("{")?i={type:"Flow",shape:"Decision"}:e.startsWith(">")&&(i={type:"Path",data:"M 0 0 L 8 0 L 8 2 L 0 2 L 2 1 L 0 0"}),i},t.prototype.getDiagramContent=function(e){return this.printandExportModule?this.printandExportModule.getDiagramContent(e):(console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),"")},t.prototype.exportImage=function(e,i){this.printandExportModule?this.printandExportModule.exportImages(e,i):console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.printImage=function(e,i){this.printandExportModule?(i.printOptions=!0,this.printandExportModule.exportImages(e,i)):console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.setStackLimit=function(e){this.undoRedoModule&&e&&(this.historyManager.stackLimit=e,this.undoRedoModule.applyLimit(this.historyManager.currentEntry,e,this,!0))},t.prototype.clearHistory=function(){this.undoRedoModule&&this.undoRedoModule.clearHistory(this)},t.prototype.getDiagramBounds=function(){if(this.printandExportModule){var e=this.printandExportModule.getDiagramBounds("",{});return e.width=e.width>this.scrollSettings.viewPortWidth?e.width+(e.x>0?e.x:0):this.scrollSettings.viewPortWidth,e.height=e.height>this.scrollSettings.viewPortHeight?e.height+(e.y>0?e.y:0):this.scrollSettings.viewPortHeight,e.x=e.x>0?0:e.x,e.y=e.y>0?0:e.y,e}return console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),new Ne},t.prototype.exportDiagram=function(e){return this.printandExportModule?this.printandExportModule.exportDiagram(e):(console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),"")},t.prototype.print=function(e){this.printandExportModule?this.printandExportModule.print(e):console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.addPorts=function(e,i){var s;this.protectPropertyChange(!0),e=this.nameTable[e.id]||e,i.length>1&&this.startGroupAction();for(var o=function(h){if(e.ports.some(function(y){return y.id===i[parseInt(h.toString(),10)].id}))return"continue";if(e instanceof te?(s=new Es(e,"ports",i[parseInt(h.toString(),10)],!0),e.ports.push(s)):e instanceof de&&(s=new Tc(e,"ports",i[parseInt(h.toString(),10)],!0),e.ports.push(s)),e.children)for(var c=e.wrapper,d=0;d1&&this.endGroupAction(),e.wrapper.measure(new me(e.width,e.height)),e.wrapper.arrange(e.wrapper.desiredSize),this.updateDiagramObject(e),this.protectPropertyChange(!1)},t.prototype.addConstraints=function(e,i){return e|i},t.prototype.removeConstraints=function(e,i){return e&~i},t.prototype.addNodeLabels=function(e,i){this.addLabels(e,i)},t.prototype.addConnectorLabels=function(e,i){this.addLabels(e,i)},t.prototype.addLabels=function(e,i){this.protectPropertyChange(!0);var s,r=(e=this.nameTable[e.id]||e).wrapper;i.length>1&&this.startGroupAction();for(var o=0;o1&&this.endGroupAction(),e.wrapper.measure(new me(r.width,r.height)),e.wrapper.arrange(r.desiredSize),this.updateDiagramObject(e),this.protectPropertyChange(!1),this.refreshCanvasLayers()},t.prototype.addChildToUmlNode=function(e,i,r){var s,o,a,l,h="NoWrap";"Class"===e.shape.classifier||"Interface"===e.shape.classifier?"Method"===r?(o=new lm(e,"",i),"Class"===e.shape.classifier?(e.shape.classShape.methods.push(o),s=e.shape.classShape):"Interface"===e.shape.classifier&&(e.shape.interfaceShape.methods.push(o),s=e.shape.interfaceShape),function Qse(n,t,e,i){if(e.methods&&e.methods.length){var r=e.methods,s="",o="",a=void 0,l=1,h=void 0,c=0,d=0,u=n.shape,g="Class"===u.classifier?u.classShape:u.interfaceShape;1===r.length?g.attributes.length>0?(c=g.attributes.filter(function(w){return w.isSeparator}).length,h=(l=2+g.attributes.length+c)+1,rT(n,t,l)):h=l+1:(c=g.attributes.filter(function(w){return w.isSeparator}).length,d=g.methods.filter(function(w){return w.isSeparator}).length,h=(l=2+g.attributes.length+c+g.methods.length+d)+1);for(var v=0;v1&&this.startGroupAction();for(var r=i.length-1;r>=0;r--)if(e.children&&e.children.length>0){var s=e.wrapper.children.filter(function(o){return o.id===e.id+"group_container"});s&&s.length>0&&this.removelabelExtension(e,i,r,s[0])}else this.removelabelExtension(e,i,r,e.wrapper);i.length>1&&this.endGroupAction(),this.refreshCanvasLayers()},t.prototype.removePortsExtenion=function(e,i,r,s){for(var o=0;o1&&this.startGroupAction();for(var r=i.length-1;r>=0;r--)if(e.children&&e.children.length>0)for(var s=0;s1&&this.endGroupAction()},t.prototype.getSizeValue=function(e,i){var r;return r=e.toString().indexOf("px")>0?e.toString():e.toString().indexOf("%")>0?void 0!==i?"100%":e.toString():e.toString()+"px",i&&(Za(this),r="calc("+r+" - "+i+"px)"),r},t.prototype.renderRulers=function(){this.rulerSettings.showRulers?(function Vne(n){var t=Za(n),i=Tt("div",{id:n.element.id+"_overlapRuler",style:"height:"+t.height+"px;width:"+t.width+"px;position:absolute;left:0;top:0",class:"e-ruler-overlap"});n.element.insertBefore(i,n.element.firstChild)}(this),J3(this,!0),J3(this,!1)):Yx(this)},t.prototype.intOffPageBackground=function(){var e=new me;e=Za(this);var i=document.getElementById(this.element.id+"content"),r=this.getSizeValue(this.width,e.width),s=this.getSizeValue(this.height,e.height),o=this.rulerSettings.showRulers?"width:"+r+"; height:"+s+";top:"+e.height+"px;left:"+e.width+"px;overflow: scroll;position:absolute;overflow:auto;":"width:"+r+"; height:"+s+";position:absolute; left:0px; top:0px;overflow: auto;",a={id:this.element.id+"content",tabindex:"0",style:o};i?(this.diagramCanvas=i,Ka(this.diagramCanvas,o)):(this.diagramCanvas=Tt("div",a),this.element.appendChild(this.diagramCanvas)),this.diagramCanvas.style.background=this.backgroundColor},t.prototype.initDiagram=function(){this.intOffPageBackground(),Ho(this.element,{style:"width:"+this.getSizeValue(this.width)+"; height:"+this.getSizeValue(this.height)+";position:relative;overflow:hidden;"})},t.prototype.renderHiddenUserHandleTemplateLayer=function(e){var r=Tt("div",{class:this.element.id+"_hiddenUserHandleTemplate",style:"width:"+e.width+"px; height:"+e.height+"px;visibility:hidden ; overflow: hidden;"});this.element.appendChild(r)},t.prototype.renderBackgroundLayer=function(e,i){var r=this.createSvg(this.element.id+"_backgroundLayer_svg",e.width,e.height);Ka(r,i);var s=Fi("g",{id:this.element.id+"_backgroundImageLayer",class:"e-background-image-layer"});r.appendChild(s);var a=Fi("g",{id:this.element.id+"_backgroundLayer",class:"e-background-layer"});r.appendChild(a),this.diagramCanvas.appendChild(r)},t.prototype.renderGridLayer=function(e,i){var r=this.createSvg(this.element.id+"_gridline_svg",e.width,e.height);r.setAttribute("class","e-grid-layer");var s=Fi("g",{id:this.element.id+"_gridline"}),o=Fi("rect",{id:this.element.id+"_grid_rect",x:"0",y:"0",width:"100%",height:"100%"});if(rm()){var a=new URL(window.location.href);o.setAttribute("fill",""!==a.search?"url(#"+this.element.id+"_pattern)":"url("+location.protocol+"//"+location.host+location.pathname+"#"+this.element.id+"_pattern)")}else o.setAttribute("fill","url(#"+this.element.id+"_pattern)");s.appendChild(o),r.appendChild(s),this.diagramCanvas.appendChild(r),ti(r,{style:i})},t.prototype.renderDiagramLayer=function(e,i){if(this.diagramLayerDiv=Tt("div",{id:this.element.id+"_diagramLayer_div",style:"width:"+e.width+"px; height:"+e.height+"px;"+i}),"SVG"===this.mode){var s=this.createSvg(this.element.id+"_diagramLayer_svg",e.width,e.height);s.style["pointer-events"]="none",s.setAttribute("class","e-diagram-layer");var o=Fi("g",{id:this.element.id+"_diagramLayer"}),a=Fi("g",{});this.diagramLayer=o,s.style["pointer-events"]="all",a.appendChild(o),s.appendChild(a),this.diagramLayerDiv.appendChild(s)}else this.diagramLayer=bo.createCanvas(this.element.id+"_diagram",e.width,e.height),Ka(this.diagramLayer,"position:absolute;left:0px;top:0px;"),this.diagramLayerDiv.appendChild(this.diagramLayer);this.diagramCanvas.appendChild(this.diagramLayerDiv)},t.prototype.initLayers=function(){var e="position:absolute;top:0px;left:0px;overflow:hidden;pointer-events:none;",r=document.getElementById(this.element.id).getBoundingClientRect(),s=function moe(){var n=Tt("div",{style:"visibility:hidden; width: 100px"});document.body.appendChild(n);var t=n.getBoundingClientRect().width;n.style.overflow="scroll";var e=Tt("div",{style:"width:100%"});n.appendChild(e);var i=e.getBoundingClientRect().width;return n.parentNode.removeChild(n),t-i}();this.scroller.scrollerWidth=s,this.scroller.setViewPortSize(r.width,r.height),this.renderRulers();var o="measureElement";window[""+o]&&(window[""+o]=null,document.getElementById("measureElement").remove()),function RF(){var n="measureElement";if(window[""+n])window[""+n].usageCount+=1;else{var t=Tt("div",{id:"measureElement",style:"visibility:hidden ; height: 0px ; width: 0px; overflow: hidden;"}),e=Tt("span",{style:"display:inline-block ; line-height: normal"});t.appendChild(e);var i=Tt("img",{alt:"measureElementImage",src:"data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7"});t.appendChild(i);var r=document.createElementNS("http://www.w3.org/2000/svg","svg");r.setAttribute("xmlns:xlink","http://www.w3.org/1999/xlink"),t.appendChild(r);var s=document.createElementNS("http://www.w3.org/2000/svg","path");s.setAttribute("d",""),r.appendChild(s),document.createTextNode("");var a=document.createElementNS("http://www.w3.org/2000/svg","text");a.setAttributeNS("http://www.w3.org/XML/1998/namespace","xml:space","preserve"),r.appendChild(a),window[""+n]=t,window[""+n].usageCount=1,document.body.appendChild(t);var l="measureElementCount";window[""+l]?window[""+l]++:window[""+l]=1}}(),this.renderBackgroundLayer(r,e),this.renderGridLayer(r,e),this.renderDiagramLayer(r,e),this.renderHTMLLayer(r,e),this.renderPortsExpandLayer(r,e),this.renderNativeLayer(r,e),this.renderAdornerLayer(r,e),this.renderHiddenUserHandleTemplateLayer(r)},t.prototype.renderAdornerLayer=function(e,i){var r=Tt("div",{id:this.element.id+"_diagramAdornerLayer",style:"width:"+e.width+"px;height:"+e.height+"px;"+i}),s=Tt("div",{id:this.element.id+"_diagramUserHandleLayer",style:"width:"+e.width+"px;height:"+e.height+"px;"+i});s.setAttribute("class","e-userHandle-layer"),r.appendChild(s);var o=this.createSvg(this.element.id+"_diagramAdorner_svg",e.width,e.height);o.setAttribute("class","e-adorner-layer"),o.style["pointer-events"]="none",this.adornerLayer=Fi("g",{id:this.element.id+"_diagramAdorner"}),this.adornerLayer.style[" pointer-events"]="all",o.appendChild(this.adornerLayer),r.appendChild(o),this.diagramCanvas.appendChild(r);var a=Fi("g",{id:this.element.id+"_SelectorElement"});this.adornerLayer.appendChild(a),ti(o,{style:"pointer-events:none;"})},t.prototype.renderPortsExpandLayer=function(e,i){var r=this.createSvg(this.element.id+"_diagramPorts_svg",e.width,e.height);r.setAttribute("class","e-ports-expand-layer");var s=Fi("g",{id:this.element.id+"_diagramPorts",class:"e-ports-layer",style:"pointer-events: all;"});r.appendChild(s);var o=Fi("g",{id:this.element.id+"_diagramExpander",class:"e-expand-layer",style:"pointer-events: all;"});r.appendChild(o),this.diagramCanvas.appendChild(r),ti(r,{style:i})},t.prototype.renderHTMLLayer=function(e,i){this.htmlLayer=Tt("div",{id:this.element.id+"_htmlLayer",style:"width:"+e.width+"px; height:"+e.height+"px;position:absolute;top:0px;left:0px;overflow:hidden;pointer-events:none;",class:"e-html-layer"});var r=Tt("div",{id:this.element.id+"_htmlLayer_div",style:"position:absolute;top:0px;left:0px;pointer-events:all;"});this.htmlLayer.appendChild(r),this.diagramCanvas.appendChild(this.htmlLayer)},t.prototype.renderNativeLayer=function(e,i){var r=this.createSvg(this.element.id+"_nativeLayer_svg",e.width,e.height),s=Fi("g",{id:this.element.id+"_nativeLayer",style:"pointer-events:all;"});r.appendChild(s),this.diagramLayerDiv.appendChild(r),ti(r,{class:"e-native-layer",style:i})},t.prototype.createSvg=function(e,i,r){var s=document.createElementNS("http://www.w3.org/2000/svg","svg");return ti(s,{id:e,width:i,height:r}),s},t.prototype.updateBazorShape=function(){for(var e=0;e1,i=[],r={},s={},o=[],a=0,l=this.nodes;a0||b&&b.children&&b.children.length>0)&&(M=!1),S&&S.wrapper&&b&&b.wrapper&&M?this.initConnectors(r[""+h],p):i.push(r[""+h])}else b=r[y.targetID],(S=r[y.sourceID])&&S.children&&S.children.length>0||b&&b.children&&b.children.length>0?i.push(r[""+h]):this.initConnectors(r[""+h],p);else r[""+h].children?o.push(h):r[""+h].shape instanceof lT&&r[""+h].shape.activity.subProcess.processes&&r[""+h].shape.activity.subProcess.processes.length>0?s[r[""+h].id]=h:this.initNodes(r[""+h],p);if(this.bpmnModule)for(var w=0,C=this.bpmnModule.bpmnTextAnnotationConnector;w-1&&-1===r.indexOf(c)&&-1===s.indexOf(c)&&r.splice(0,0,c);-1===r.indexOf(o)&&s.push(o)}return r.concat(s)},t.prototype.addToLayer=function(e,i){var r;if(i&&(r=this.commandHandler.getObjectLayer(e.id)),(!i||!r)&&-1===this.activeLayer.objects.indexOf(e.id)&&this.activeLayer.objects.push(e.id),(e instanceof te||e instanceof de)&&("SwimLane"!==e.shape.type||e.children&&e.children.length>0)){if(e.parentId){var s=this.swimlaneZIndexTable[e.parentId],o=this.swimlaneChildTable[e.id];(s&&-1!==s||o&&-1!==o)&&(e.zIndex=this.swimlaneChildTable[e.id])}e instanceof de&&e.sourceID&&e.targetID?-1!==this.activeLayer.objects.indexOf(e.sourceID)&&-1!==this.activeLayer.objects.indexOf(e.targetID)&&this.setZIndex(r||this.activeLayer,e):this.setZIndex(r||this.activeLayer,e)}},t.prototype.updateLayer=function(e){for(var i=0,r=Object.keys(e.layers);i0)for(r=0;rs;l--)r.zIndexTable[parseInt(l.toString(),10)]=r.zIndexTable[l-1],this.nameTable[r.zIndexTable[parseInt(l.toString(),10)]]&&(this.nameTable[r.zIndexTable[parseInt(l.toString(),10)]].zIndex=l);r.zIndexTable[parseInt(a.toString(),10)]=i.id}}},t.prototype.initializeDiagramLayers=function(){for(var e=0;ethis.layers[parseInt(a.toString(),10)].zIndex&&(i=this.layers[parseInt(e.toString(),10)],this.layers[parseInt(e.toString(),10)]=this.layers[parseInt(a.toString(),10)],this.layers[parseInt(a.toString(),10)]=i);0===this.layers.length&&this.commandHandler.addLayer({id:"default_layer",visible:!0,lock:!1,objects:[],zIndex:0,objectZIndex:-1,zIndexTable:{}},null,!0),this.setActiveLayer(this.layers[this.layers.length-1].id)},t.prototype.resetTool=function(){this.eventHandler.resetTool()},t.prototype.initObjectExtend=function(e,i,r){if(r){var s=this.commandHandler.checkBoundaryConstraints(void 0,void 0,e.wrapper.bounds,!0);if("SwimLane"===e.shape.type)for(var o=0,a=Object.keys(i.zIndexTable);o0)&&this.setZIndex(i,e)),e instanceof te){if(r){if("helper"!==e.id&&(o=Zi(this.getNodeDefaults))){if((a=o(e,this))&&a.ports)for(var l=0;l0)for(l=0;l0&&!e.container||e.processId){var r=this.nameTable[e.id];if(!(this.realActions&$i.PreventScale||this.realActions&$i.PreventDrag)){if(r.offsetX&&(this.realActions&$i.EnableGroupAction||!(this.diagramActions&ee.UndoRedo||this.diagramActions&ee.ToolAction||this.diagramActions&ee.PublicMethod))){this.realActions|=$i.PreventScale;var s=r.offsetX-e.wrapper.offsetX;r.offsetX=e.wrapper.offsetX;var o=r.offsetY-e.wrapper.offsetY;r.offsetY=e.wrapper.offsetY,s+o!==0&&this.drag(r,s,o),this.realActions&=~$i.PreventScale}else r.offsetX=e.wrapper.offsetX;r.offsetY&&(this.realActions&$i.EnableGroupAction||!(this.diagramActions&ee.UndoRedo||this.diagramActions&ee.ToolAction||this.diagramActions&ee.PublicMethod))?(this.realActions|=$i.PreventScale,o=r.offsetY-e.wrapper.offsetY,r.offsetY=e.wrapper.offsetY,this.drag(r,0,o),this.realActions&=~$i.PreventScale):r.offsetY=e.wrapper.offsetY,this.diagramActions&&(r.width=e.wrapper.actualSize.width,r.height=e.wrapper.actualSize.height)}}i&&e.children&&e.children.length>0&&(void 0!==this.nameTable[e.id].width?this.scaleObject(e,this.nameTable[e.id].width,!0):this.nameTable[e.id].width=e.wrapper.actualSize.width,void 0!==this.nameTable[e.id].height?this.scaleObject(e,this.nameTable[e.id].height,!1):this.nameTable[e.id].height=e.wrapper.actualSize.height)},t.prototype.initNode=function(e,i,r){var a,f,s=e.initContainer(),o=new Mi;if(this.diagramSettings.inversedAlignment||(s.inversedAlignment=!1),s.children||(s.children=[]),e.children){s.measureChildren=!1,o.id=e.id+"group_container",o.style.fill=e.shape&&"SwimLane"===e.shape.type?e.style.fill:"none",o.style.strokeColor="none",o.horizontalAlignment="Stretch",o.verticalAlignment="Stretch",o.pivot=e.pivot,s.style=e.style,s.padding.left=e.padding.left,s.padding.right=e.padding.right,s.padding.top=e.padding.top,s.padding.bottom=e.padding.bottom,o.children=[],o.preventContainer=!0,e.container&&(o.relativeMode="Object");var l=!!(e.ports&&e.ports.length>0);if(m(e.container)&&!l&&s.children.push(o),e.container&&"Grid"===e.container.type)for(var h=0;h0&&e.wrapper.children[0]instanceof jv){if(this.setZIndex(this.activeLayer,e),this.connectors.length>0)for(h=0;h0?i.phases.length:0,v="Horizontal"===i.orientation,y=v?i.phases.length||1:s.length+1,S=v?(i.header&&i.hasHeader?1:0)+(i.phases.length>0?1:0)+i.lanes.length:(i.header&&i.hasHeader?1:0)+i.phases.length;if(0===h&&!v&&i.lanes.length&&(S+=1),v?(a=(i.header&&i.hasHeader?1:0)+(h>0?1:0),l=0):(a=i.header&&i.hasHeader?1:0,l=h>0?1:0),s.length>0)for(o+=i.header&&i.hasHeader?i.header.height:0,f=0;fl?d.margin.left=d.margin.left-(u.bounds.left-e.bounds.left):u.children[0].children[1].actualSize.width+r>=d.margin.left&&(d.margin.left=u.children[0].children[1].actualSize.width+r),d.margin.lefta?d.margin.top=d.margin.top-(u.bounds.top-o):u.children[0].children[1].actualSize.height+r>=d.margin.top&&(d.margin.top=u.children[0].children[1].actualSize.height+r),d.margin.left0)for(o=0;o0&&this.updateChildPosition(e)},t.prototype.addBpmnAnnotationConnector=function(e,i){if(e.parentObj instanceof t||e.parentObj instanceof Hd){var r=e.shape,o=""!==r.textAnnotation.textAnnotationTarget&&this.nameTable[r.textAnnotation.textAnnotationTarget],a=o?this.nameTable[r.textAnnotation.textAnnotationTarget]:null,l=null!=a?a.wrapper:null,h=e.ports[0],c={x:0,y:0};switch(r.textAnnotation.textAnnotationDirection){case"Left":h.offset={x:0,y:.5},c.x=i.bounds.left-40,c.y=i.bounds.bottom+30;break;case"Right":h.offset={x:1,y:.5},c.x=i.bounds.right+40,c.y=i.bounds.bottom+30;break;case"Top":h.offset={x:.5,y:0},c.x=i.bounds.right+30,c.y=i.bounds.top-40;break;case"Bottom":h.offset={x:.5,y:1},c.x=i.bounds.right+30,c.y=i.bounds.bottom+40;break;default:h.offset={x:0,y:.5},c.x=i.bounds.left-40,c.y=i.bounds.bottom+30,o&&null!=i&&null!=l&&(i.bounds.left>l.bounds.right?h.offset={x:0,y:.5}:i.bounds.rightl.bounds.top?h.offset={x:.5,y:0}:i.bounds.top0&&this.updateChildPosition(r)}},t.prototype.canExecute=function(){return!0},t.prototype.updateStackProperty=function(e,i,r){e.container&&"Stack"===e.container.type&&(i.width||(i.wrapper.horizontalAlignment="Stretch",i.horizontalAlignment="Stretch"),i.height||(i.verticalAlignment="Stretch",i.wrapper.verticalAlignment="Stretch"),r&&"UmlClassifier"===e.shape.type&&(i.umlIndex=r))},t.prototype.initViews=function(){this.isLoading||(this.views.push(this.element.id),this.views[this.element.id]=this)},t.prototype.initCommands=function(){var e=this.commandManager.commands,i={copy:{execute:this.copyCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.C,keyModifiers:ft.Control}},paste:{execute:this.pasteCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.V,keyModifiers:ft.Control}},cut:{execute:this.cutCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.X,keyModifiers:ft.Control}},delete:{execute:this.removeCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Delete}},selectAll:{execute:this.selectAll.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.A,keyModifiers:ft.Control}},undo:{execute:this.undo.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Z,keyModifiers:ft.Control}},redo:{execute:this.redo.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Y,keyModifiers:ft.Control}},nudgeUp:{execute:this.nudgeCommand.bind(this,"Up"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Up},parameter:"up"},nudgeRight:{execute:this.nudgeCommand.bind(this,"Right"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Right},parameter:"right"},nudgeDown:{execute:this.nudgeCommand.bind(this,"Down"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Down},parameter:"down"},nudgeLeft:{execute:this.nudgeCommand.bind(this,"Left"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Left},parameter:"left"},startEdit:{execute:this.startEditCommad.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.F2}},endEdit:{execute:this.endEditCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Escape}},focusToNextItem:{execute:this.navigateItems.bind(this,!0),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Tab}},focusToPreviousItem:{execute:this.navigateItems.bind(this,!1),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Tab,keyModifiers:ft.Shift}},selectFocusedItem:{execute:this.startEditCommad.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Enter}},bold:{execute:this.fontStyleCommand.bind(this,"bold"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.B,keyModifiers:ft.Control}},italic:{execute:this.fontStyleCommand.bind(this,"italic"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.I,keyModifiers:ft.Control}},underline:{execute:this.fontStyleCommand.bind(this,"underline"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.U,keyModifiers:ft.Control}},duplicate:{execute:this.duplicateCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.D,keyModifiers:ft.Control}},group:{execute:this.groupCommand.bind(this,"group"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.G,keyModifiers:ft.Control}},ungroup:{execute:this.groupCommand.bind(this,"ungroup"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.U,keyModifiers:ft.Control|ft.Shift}},rotateClockwise:{execute:this.rotateCommand.bind(this,"clockwise"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.R,keyModifiers:ft.Control}},rotateAntiClockwise:{execute:this.rotateCommand.bind(this,"antiClockwise"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.L,keyModifiers:ft.Control}},flipHorizontal:{execute:this.flipCommand.bind(this,"horizontal"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.H,keyModifiers:ft.Control}},flipVertical:{execute:this.flipCommand.bind(this,"vertical"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.J,keyModifiers:ft.Control}},pointerTool:{execute:this.toolCommand.bind(this,"pointer"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number1,keyModifiers:ft.Control}},textTool:{execute:this.toolCommand.bind(this,"text"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number2,keyModifiers:ft.Control}},connectTool:{execute:this.toolCommand.bind(this,"connect"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number3,keyModifiers:ft.Control}},freeForm:{execute:this.toolCommand.bind(this,"freeForm"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number5,keyModifiers:ft.Control}},lineTool:{execute:this.toolCommand.bind(this,"line"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number6,keyModifiers:ft.Control}},rectangleTool:{execute:this.toolCommand.bind(this,"rectangle"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number8,keyModifiers:ft.Control}},ellipseTool:{execute:this.toolCommand.bind(this,"ellipse"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number9,keyModifiers:ft.Control}},zoomIn:{execute:this.zoomCommand.bind(this,"zoomIn"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Plus,keyModifiers:ft.Control}},zoomOut:{execute:this.zoomCommand.bind(this,"zoomOut"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Minus,keyModifiers:ft.Control}},shiftUp:{execute:this.shiftCommand.bind(this,"Up"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Up,keyModifiers:ft.Shift}},shiftDown:{execute:this.shiftCommand.bind(this,"Down"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Down,keyModifiers:ft.Shift}},shiftLeft:{execute:this.shiftCommand.bind(this,"Left"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Left,keyModifiers:ft.Shift}},shiftRight:{execute:this.shiftCommand.bind(this,"Right"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Right,keyModifiers:ft.Shift}},alignTextCenter:{execute:this.alignCommand.bind(this,"center"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.C,keyModifiers:ft.Control|ft.Shift}},alignTextLeft:{execute:this.alignCommand.bind(this,"right"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.L,keyModifiers:ft.Control|ft.Shift}},alignTextRight:{execute:this.alignCommand.bind(this,"left"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.R,keyModifiers:ft.Control|ft.Shift}},alignTextTop:{execute:this.alignCommand.bind(this,"top"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.E,keyModifiers:ft.Control|ft.Shift}},alignTextCenterVertical:{execute:this.alignCommand.bind(this,"centerVertical"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.M,keyModifiers:ft.Control|ft.Shift}},alignTextBottom:{execute:this.alignCommand.bind(this,"bottom"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.V,keyModifiers:ft.Control|ft.Shift}},alignJustify:{execute:this.alignCommand.bind(this,"justify"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.J,keyModifiers:ft.Control|ft.Shift}},sendToBack:{execute:this.orderCommand.bind(this,"sendToBack"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.B,keyModifiers:ft.Control|ft.Shift}},bringToFront:{execute:this.orderCommand.bind(this,"bringToFront"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.F,keyModifiers:ft.Control|ft.Shift}},sendBackward:{execute:this.orderCommand.bind(this,"sendBackward"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.BracketLeft,keyModifiers:ft.Control}},bringForward:{execute:this.orderCommand.bind(this,"bringForward"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.BracketRight,keyModifiers:ft.Control}}};this.initCommandManager(e,i)},t.prototype.overrideCommands=function(e,i){for(var r,s=0,o=Object.keys(i);se.zIndex){("HTML"===e.shape.type||"Native"===e.shape.type)&&(o="HTML"===e.shape.type?"html":"native"),s=uoe(i,r[parseInt(a.toString(),10)].id,o);break}return s},t.prototype.updateDiagramObject=function(e,i,r){for(var s,o="domTable",a=0,l=this.views;a1&&(d=this.commandHandler.getObjectLayer(e.id)),void 0===d||d&&d.visible||r){var u=Io(this.element.id);window[""+o][s.element.id+"_diagramLayer"]||(window[""+o][s.element.id+"_diagramLayer"]=document.getElementById(s.element.id+"_diagramLayer"));var f=window[""+o][s.element.id+"_diagramLayer"];this.diagramActions&ee.Interactions&&this.updateCanupdateStyle(e.wrapper.children,!0);var p=this.getMidPoint(e);this.diagramRenderer.updateNode(e.wrapper,f,u,void 0,i?void 0:this.getZindexPosition(e,s.element.id),p,this.portCenterPoint),this.updateCanupdateStyle(e.wrapper.children,!0)}}},t.prototype.applyMarginBezier=function(e,i){i.cx=i.cx+e.margin.left,i.cx=i.cx-e.margin.right,i.cy=i.cy+e.margin.top,i.cy=i.cy-e.margin.bottom},t.prototype.getMidPoint=function(e){var i;if(e instanceof de&&"Bezier"===e.type){i=[];for(var r=this.getBezierPoints(e),s=R.getLengthFromListOfPoints(r),o=0;o0&&e.updateView(e));var s=Io(e.element.id);this.renderDiagramElements(e.diagramLayer,e.diagramRenderer,s,void 0,void 0,i);for(var o=0;o0&&this.renderBasicElement(e),!this.diagramActions||!(this.diagramActions&ee.Render)||ee.ToolAction&this.diagramActions||Ds(this)||1!==this.scroller.currentZoom?this.refreshElements(e):this.renderTimer||(this.renderTimer=setTimeout(function(){i.refreshElements(e)},40)))},t.prototype.updatePortVisibility=function(e,i,r){var s;if((e instanceof te||e instanceof de)&&(!this.drawingObject||!this.drawingObject.shape)&&ro(e)){for(var a=e.ports,l=!1,h=0;h=0&&this.scroller.removeCollection.splice(l,1);var h=this.nameTable[e[parseInt(a.toString(),10)]];this.updateTextElementValue(h),this.diagramRenderer.renderElement(h.wrapper,s,o,void 0,void 0,void 0,void 0,h.zIndex)}for(var c=0;c0?this.scroller.oldCollectionObjects:void 0,b=Object.keys(S||g.zIndexTable);b.sort(function(N,T){return parseInt(""+N,10)-parseInt(""+T,10)});for(var M=0,w=b;M0?h:0)+"px",y=(this.realActions&$i.vScrollbarMoved?0:-(this.scroller.verticalOffset<0?this.scroller.verticalOffset:0))+"px"):(v="0px",y="0px"),this.realActions&$i.hScrollbarMoved&&(this.realActions=this.realActions&~$i.hScrollbarMoved),this.realActions&$i.vScrollbarMoved&&(this.realActions=this.realActions&~$i.vScrollbarMoved)):(v=(l.x<0?h:-this.scroller.horizontalOffset)+"px",y=(l.y<0?c:-this.scroller.verticalOffset)+"px"),this.diagramLayer.style.left=v,this.diagramLayer.style.top=y,A.tx=-l.x/A.scale,A.ty=-l.y/A.scale);var P=!0;if(o&&(P=!1),this.updateTextElementValue(D),this.refreshing&&D.shape.activity&&D.shape.activity.subProcess&&D.shape.activity.subProcess.processes){for(var L=0;L0){var o=s.children[0],a=o.data;(r.isBezierEditing&&this.selectedItems.connectors[0].id===r.id||"Bezier"!==r.type)&&r.getSegmentElement(r,o,"ComplexHierarchicalTree"===this.layout.type||"HierarchicalTree"===this.layout.type?this.layout.orientation:void 0,void 0,!1),o.data!==a&&(s.measure(new me),s.arrange(s.desiredSize),"SVG"===this.mode&&!e&&this.updateDiagramObject(r))}}else this.constraints&nt.Bridging&&console.warn('[WARNING] :: Module "ConnectorBridging" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.setCursor=function(e){this.diagramRenderer.setCursor(this.diagramCanvas,e)},t.prototype.clearCanvas=function(e){var i=e.contentWidth||e.diagramLayer.width/this.scroller.currentZoom,r=e.contentHeight||e.diagramLayer.height/this.scroller.currentZoom;"SVG"!==e.mode&&bo.getContext(e.diagramLayer).clearRect(0,0,i,r)},t.prototype.updateScrollOffset=function(){this.scroller.setScrollOffset(this.diagramCanvas.scrollLeft,this.diagramCanvas.scrollTop),GI(this),Ds(this)&&this.scroller.virtualizeElements()},t.prototype.setOffset=function(e,i){var r="domTable";window[""+r][this.element.id+"content"]||(window[""+r][this.element.id+"content"]=document.getElementById(this.element.id+"content"));var s=window[""+r][this.element.id+"content"];s&&(s.scrollLeft=e,s.scrollTop=i)},t.prototype.setSize=function(e,i){if(this.diagramLayer&&!this.preventDiagramUpdate){var r=Za(this);e-=r.width,i-=r.height;var s=this.spatialSearch.getPageBounds();s.x*=this.scroller.currentZoom,s.y*=this.scroller.currentZoom,s.width*=this.scroller.currentZoom,s.height*=this.scroller.currentZoom;var o="SVG"===this.mode?1:1.5,a="SVG"===this.mode?fT(this.element.id):this.diagramLayer,h="Canvas"===this.mode&&this.constraints&nt.Virtualization?this.scroller.viewPortHeight:i;a.setAttribute("width",(o*("Canvas"===this.mode&&this.constraints&nt.Virtualization?this.scroller.viewPortWidth:e)).toString()),a.setAttribute("height",(o*h).toString());var c=document.getElementById(this.element.id+"_diagramUserHandleLayer");c&&(c.style.width=e+"px",c.style.height=i+"px");var d={width:e.toString(),height:i.toString()};this.diagramLayerDiv.style.width=e+"px",this.diagramLayerDiv.style.height=i+"px",ti(NF(this.element.id),d),ti(function poe(n){return xt(n).getElementsByClassName("e-ports-expand-layer")[0]}(this.element.id),d);var u=Bl(this.element.id);ti(u,d),u.parentNode.style.width=e+"px",u.parentNode.style.height=i+"px";var f=Fd(this.element.id);ti(f,d),this.diagramRenderer.updateGrid(this.snapSettings,f,this.scroller.transform,this.rulerSettings,this.hRuler,this.vRuler),ti(vT(this.element.id),d),this.htmlLayer.style.width=e+"px",this.htmlLayer.style.height=i+"px","SVG"!==this.mode&&!Ds(this)&&this.refreshDiagramLayer(),"SVG"===this.mode&&Ds(this)&&this.scroller.virtualizeElements()}},t.prototype.transformLayers=function(){var e=this.spatialSearch.getPageBounds();e.x*=this.scroller.currentZoom,e.y*=this.scroller.currentZoom,e.width*=this.scroller.currentZoom,e.height*=this.scroller.currentZoom,this.diagramRenderer.updateGrid(this.snapSettings,Fd(this.element.id),this.scroller.transform,this.rulerSettings,this.hRuler,this.vRuler),this.diagramRenderer.transformLayers(this.scroller.transform,"SVG"===this.mode),this.diagramActions&ee.DragUsingMouse||this.updateSelector(),this.renderPageBreaks(e)},t.prototype.removePageBreaks=function(){if(this.diagramLayer){var e=OF(this.element.id);if(e&&e.childNodes)for(var i=e.childNodes.length,r=0;rthis.pageSettings.height&&(e=this.pageSettings.height,this.pageSettings.height=this.pageSettings.width,this.pageSettings.width=e):this.pageSettings.height>this.pageSettings.width&&(e=this.pageSettings.width,this.pageSettings.width=this.pageSettings.height,this.pageSettings.height=e)},t.prototype.setOverview=function(e,i){if(e)e&&(this.views.push(e.id),this.views[e.id]=e,e.renderDocument(e),e.diagramRenderer.setLayers(),e.updateView(e),this.renderNodes(e));else{for(var r=0;r1&&this.updateSelectionRectangle(),this.isProtectedOnChange=s},t.prototype.updateSelectionRectangle=function(){for(var e=hm(this.element.id),i=!1,r=0;r1&&this.updateSelectionRectangle(),this.enableServerDataBinding(e)},t.prototype.renderSelectorForAnnotation=function(e,i){this.diagramRenderer.renderResizeHandle(e.wrapper.children[0],i,e.thumbsConstraints,this.scroller.currentZoom,e.constraints,this.scroller.transform,void 0,ro(e.annotation),void 0,void 0,e.handleSize)},t.prototype.drawSelectionRectangle=function(e,i,r,s){this.clearSelectorLayer(),this.diagramRenderer.drawSelectionRectangle(e,i,r,s,this.adornerLayer,this.scroller.transform)},t.prototype.renderHighlighter=function(e){var i=Bl(this.element.id);this.diagramRenderer.renderHighlighter(e,i,this.scroller.transform)},t.prototype.clearHighlighter=function(){var e=Bl(this.element.id),i=e.getElementById(e.id+"_highlighter");i&&i.parentNode.removeChild(i)},t.prototype.getNodesConnectors=function(e){for(var i=0;i0;h--)this.eventHandler&&this.eventHandler.touchArgs&&"touchmove"===this.eventHandler.touchArgs.type?(this.diagramRenderer.touchMove=!0,l&&l===o[h-1].id||(a=o[h-1]).parentNode.removeChild(a)):(a=o[h-1]).parentNode.removeChild(a);if(!ce()){var c=gT(this.element.id).childNodes;for(r=c.length;r>0;r--)c[r-1].parentNode.removeChild(c[r-1])}}},t.prototype.getWrapper=function(e,i){var r;i=e.id+"_"+i;for(var s=e instanceof Mi?e:this.getPortContainer(this.nameTable[e.id]),o=0;o0&&this.applyStyle(e,a=r.annotations)}for(i=0;i0){var a=this.selectedItems.connectors[parseInt(i.toString(),10)].annotations;this.applyStyle(e,a)}},t.prototype.applyStyle=function(e,i){for(var r=0;r0)for(var i=0;i0?r[0].zIndex+(e?1:-1):e?0:this.nodes.length+this.connectors.length-1)<0?i=this.nodes.length+this.connectors.length-1:i===this.nodes.length+this.connectors.length&&(i=0);for(var s=0;s0)for(var s=void 0,o=r.children.length-1;o>=0;o--){var a=r.children[parseInt(o.toString(),10)];i.length>0&&-1!==i.indexOf(a.id.split("_groupElement")[0])&&(r.parentNode.insertBefore(a,s||r),s=a)}r&&r.parentNode.removeChild(r)},t.prototype.deleteGroup=function(e){var r=[];e.children&&(r=this.commandHandler.getChildren(e,[])),this.UpdateBlazorDiagramModelCollection(e);for(var s=0,o=r;s0)for(var xe=0;xe0)if("Path"===t.shape.type&&void 0!==n.shape.data)t.wrapper.children[0].data=n.shape.data;else if("Text"===t.shape.type&&void 0!==n.shape.content)t.wrapper.children[0].content=n.shape.content;else if("Image"===t.shape.type&&void 0!==n.shape.source)t.wrapper.children[0].source=n.shape.source;else if("Native"===t.shape.type){for(var r=void 0,s=0;s-1)&&(this.diagramActions&ee.PreventZIndexOnDragging?this.updateDiagramObject(e,!0):this.updateDiagramObject(e)),!s&&d&&(this.lineRoutingModule&&this.diagramActions&&this.constraints&nt.LineRouting&&"helper"!==e.id?this.diagramActions&ee.ToolAction||this.lineRoutingModule.renderVirtualRegion(this,!0):this.diagramActions&&this.constraints&nt.LineRouting&&"helper"!==e.id&&console.warn('[WARNING] :: Module "LineRouting" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),this.updateConnectorEdges(e),"helper"!==e.id&&!(this.diagramActions&ee.ToolAction))))for(var Sa=this.spatialSearch.findObjects(e.wrapper.outerBounds),Mo=0;Moe?Math.abs(r-e):Math.abs(e-r),d=s>i?Math.abs(s-i):Math.abs(i-s);(0===c&&0===d||Number.isNaN(c)&&Number.isNaN(d))&&o.laneMargin&&(u=o.margin.left-o.laneMargin.left,f=o.margin.top-o.laneMargin.top);var p=o.width,g=o.height,v=new Ne(0,0,0,0);if(0!==p&&0!==g&&(v=new Ne((0!==r?r:o.offsetX)-p/2,(0!==s?s:o.offsetY)-g/2,p,g)),h){var y=l,b=this.selectedItems.nodes?this.selectedItems.nodes[0]:void 0;if(""!==y.textAnnotation.textAnnotationTarget&&this.nameTable[y.textAnnotation.textAnnotationTarget])if(""===o.parentId||b&&b.shape&&"TextAnnotation"===b.shape.shape){if("Auto"===y.textAnnotation.textAnnotationDirection&&a.children[0]instanceof Mi&&a.children[0].children[0]instanceof Ze){var w=a.children[0],C=document.getElementById(w.id+"_groupElement"),D=document.getElementById(w.children[0].id+"_groupElement");C.removeChild(D),w.children.splice(0,1),this.isProtectedOnChange=!0,this.bpmnModule.setAnnotationPath(v,w,o,y,y.textAnnotation.textAnnotationDirection,this),this.isProtectedOnChange=!1}}else this.isPositionUndo=!0,this.updateTextAnnotationInSwimlane(o,o),this.isPositionUndo=!1;else o.inEdges.length>0&&(x=this.nameTable[""+o.inEdges[0]])&&x.isBpmnAnnotationConnector&&(x.sourcePoint={x:r>e?x.sourcePoint.x+c:x.sourcePoint.x-c,y:s>i?x.sourcePoint.y+d:x.sourcePoint.y-d});this.nodePropertyChange(o,{},P={ports:[{offset:o.ports[0].offset}]})}else for(var L=0,O=o.outEdges;Le?T.offsetX+c:T.offsetX-c,T.offsetY=s>i?T.offsetY+d:T.offsetY-d,P={offsetX:T.offsetX,offsetY:T.offsetY}),this.nodePropertyChange(T,z,P)}}}},t.prototype.updatePorts=function(e,i){if(e&&e.ports.length>0)for(var r=0,s=Object.keys(e.ports);r0)for(var i=0;i0)for(var r=0;r0&&void 0===r.segments&&(e.segments=[]),void 0!==r.shape&&void 0!==e.shape&&e.shape&&"Bpmn"===e.shape.type&&this.bpmnModule&&this.bpmnModule.updateBPMNConnector(e,i,r,this),void 0!==e.constraints?(this.updateThumbConstraints(this.selectedItems.connectors,this.selectedItems),s=!0):s},t.prototype.connectorPropertyChange=function(e,i,r,s,o){if(this.canEnableBlazorObject){var a=$(e);this.insertValue(a,!1)}var d,u,f,p,l=e.wrapper.bounds,h=!1,c=[];if(h=this.connectorProprtyChangeExtend(e,i,r,h),void 0!==r.visible&&this.updateElementVisibility(e.wrapper,e,e.visible),void 0!==r.sourcePoint||void 0!==r.targetPoint||void 0!==r.sourceID||void 0!==r.targetID||void 0!==r.targetPadding||void 0!==r.sourcePortID||void 0!==r.targetPortID||void 0!==r.sourcePadding||void 0!==r.type||void 0!==r.segments||void 0!==r.flip){if(void 0!==r.sourceID&&r.sourceID!==i.sourceID||r.sourcePortID){if(u=this.findInOutConnectPorts(g=this.nameTable[e.sourceID],!1),(!g||Ph(g)||""!==e.sourcePortID&&Td(u))&&(e.sourceWrapper=g?this.getEndNodeWrapper(g,e,!0):void 0,e.sourcePortID&&void 0===r.sourcePortID&&(e.sourcePortWrapper=g?this.getWrapper(g.wrapper,e.sourcePortID):void 0),this.removePortEdges(this.nameTable[i.sourceID]||g,i.sourcePortID||e.sourcePortID,e.id,!1)),void 0!==r.sourceID&&void 0!==i.sourceID&&""!==i.sourceID){var v=this.nameTable[i.sourceID];void 0!==v&&v.outEdges&&-1!==v.outEdges.indexOf(e.id)&&em(v.outEdges,e.id)}this.updateEdges(e)}if(void 0!==r.targetID&&r.targetID!==i.targetID){if(d=this.findInOutConnectPorts(y=this.nameTable[r.targetID],!0),(!y||ua(y)||""!==e.targetPortID&&kh(d))&&(e.targetWrapper=y?this.getEndNodeWrapper(y,e,!1):void 0,e.targetPortID&&void 0===r.targetPortID&&(e.targetPortWrapper=y?this.getWrapper(y.wrapper,e.targetPortID):void 0),this.removePortEdges(this.nameTable[i.targetID]||y,i.targetPortID||e.targetPortID,e.id,!0)),void 0!==i&&void 0!==i.targetID&&""!==i.targetID){var S=this.nameTable[i.targetID];void 0!==S&&S.inEdges&&-1!==S.inEdges.indexOf(e.id)&&em(S.inEdges,e.id)}this.updateEdges(e)}var g,y;void 0!==r.sourcePortID&&r.sourcePortID!==i.sourcePortID&&(e.sourceID&&this.nameTable[e.sourceID]&&(f=this.nameTable[e.sourceID].wrapper),!(g=this.nameTable[e.sourceID])||Ph(g)||""!==e.sourcePortID&&Td(u)?e.sourcePortWrapper=f?this.getWrapper(f,r.sourcePortID):void 0:""===e.sourcePortID&&!Ph(g)&&(e.sourcePortWrapper=void 0)),void 0!==r.targetPortID&&r.targetPortID!==i.targetPortID&&(e.targetID&&this.nameTable[e.targetID]&&(p=this.nameTable[e.targetID].wrapper),!(y=this.nameTable[e.targetID])||ua(y)||""!==e.targetPortID&&kh(d)?e.targetPortWrapper=p?this.getWrapper(p,r.targetPortID):void 0:""===e.targetPortID&&!ua(y)&&(e.targetPortWrapper=void 0)),void 0!==r.flip&&(e.flip=r.flip,mF(e)),"Orthogonal"===e.type&&this.lineRoutingModule&&this.diagramActions&&this.constraints&nt.LineRouting&&!(this.diagramActions&ee.ToolAction)&&"ComplexHierarchicalTree"!==this.layout.type&&(this.lineRoutingModule.renderVirtualRegion(this,!0),e.sourceID!==e.targetID&&e.segments.length>1&&this.lineRoutingModule.refreshConnectorSegments(this,e,!1)),c=this.getPoints(e)}void 0!==r.style&&zh(r.style,e.wrapper.children[0]),(c.length>0||void 0!==r.sourceDecorator||void 0!==r.targetDecorator&&function Rse(n){return-1!==n.indexOf("shape")||-1!==n.indexOf("pathData")||-1!==n.indexOf("width")||-1!==n.indexOf("height")}(Object.keys(r.targetDecorator))||void 0!==r.cornerRadius)&&(Jf(e,c.length>0?c:e.intermediatePoints,this.diagramActions),void 0!==r.type&&(h=!0),c.length>0&&(e.wrapper.measure(new me(e.wrapper.width,e.wrapper.height)),e.wrapper.arrange(e.wrapper.desiredSize),this.updateConnectorAnnotation(e),this.updateConnectorPort(e),this.updateConnectorfixedUserHandles(e),this.updateObject(e,i,r))),(r.sourcePoint||r.targetPoint||r.segments)&&this.diagramActions===ee.Render&&(h=!0),"Bpmn"===e.shape.type&&"Default"===e.shape.sequence&&"Sequence"===e.shape.flow&&this.commandHandler.updatePathElementOffset(e),s||this.updateBridging(),this.updateAnnotations(r,e),this.updateConnectorPorts(r,e),this.updatefixedUserHandle(r,e),e.wrapper.measure(new me(e.wrapper.width,e.wrapper.height)),e.wrapper.arrange(e.wrapper.desiredSize),!1===l.equals(l,e.wrapper.bounds)&&(this.updateQuad(e),"Drag"!==this.eventHandler.currentAction&&this.updateGroupSize(e)),!0===h&&this.checkSelectedItem(e)&&(!(this.diagramActions&ee.ToolAction)||this.diagramActions&ee.UndoRedo)&&this.updateSelector(),this.preventConnectorsUpdate||(!Ds(this)||Ds(this)&&this.scroller.oldCollectionObjects.indexOf(e.id)>-1)&&(this.diagramActions&ee.PreventZIndexOnDragging?this.updateDiagramObject(e,!0):this.updateDiagramObject(e)),this.updateConnectorEdges(e),this.diagramActions&&"New"!==e.status&&(e.status="Update"),this.triggerPropertyChange(o,e,i,r)},t.prototype.removePortEdges=function(e,i,r,s){if(e)for(var o=0;o0&&e.id===s[s.length-1].id&&(r=!0),r},t.prototype.updateDiagramContainerVisibility=function(e,i){if(e instanceof Cs)for(var r=0;r>"),r instanceof es&&this.updateAnnotationWrapper(r,s,o,a)),void 0!==e.template&&(r.content=e.template,this.updateAnnotationWrapper(r,s,o,a))},t.prototype.updateAnnotationWrapper=function(e,i,r,s){for(var o=0,a=this.views;o=0&&this.nodes.splice(s,1),delete this.nameTable[""+r]}var o=this.nodes.indexOf(this.nameTable[this.currentSymbol.id]);o>=0&&this.nodes.splice(o,1)}},t.prototype.selectDragedNode=function(e,i,r){this.currentSymbol=e,"SVG"!==this.mode&&this.refreshDiagramLayer(),this.commandHandler.oldSelectedObjects=im(this),this.commandHandler.select(e),this.eventHandler.mouseDown(i.event),this.eventHandler.mouseMove(i.event,i),this.preventDiagramUpdate=!1,this.updatePage(),r.style.opacity="0"},t.prototype.initDroppables=function(){var s,o,e=this,i={},r={},a="selectedSymbols";this.droppable=new oR(this.element);var l=5;this.droppable.over=function(h){if(e.rulerSettings.showRulers){var c=document.getElementById(e.element.id+"_vRuler"),d=parseFloat(c.style.width);l=d+1}if(0===e.previousSelectedObjects.length&&!e.currentSymbol&&(e.previousSelectedObjects=e.commandHandler.getSelectedObject()),e.commandHandler.PreventConnectorSplit=!0,e.currentSymbol)h.event.touches&&h.event.touches.length&&e.eventHandler.mouseMove(h.event,h.event.touches);else{var u=null;if(!h.dragData&&"drag"===h.name){var f=document.getElementsByClassName("e-dragclone")[0];f&&(u=f)}if(h.dragData||u){var p=void 0,g=void 0;document.getElementById(e.element.id+"content").focus();var v=e.eventHandler.getMousePosition(h.event),y=void 0,S=u||h.dragData.helper,b=S.getAttribute("paletteId"),M=void 0,w=void 0,C=void 0,D=void 0;if(!b&&h.dragData){e.triggerEvent(Ce.dragEnter,A={source:null,element:p,cancel:!1,diagram:e,dragData:h.dragData.draggedElement.ej2_instances[0].dragData,dragItem:p});var x=void 0,P=void 0;if(A.dragItem){if(A.dragItem.sourcePoint&&A.dragItem.targetPoint?P=new de(e,"connectors",A.dragItem,!0):x=new te(e,"nodes",A.dragItem,!0),e.initObject(p=x||P,void 0,void 0,!0),e.enterObject=p,e.enterTable=r,p instanceof te)x.offsetX=v.x+5+x.width*x.pivot.x,x.offsetY=v.y+x.height*x.pivot.y;else if(p instanceof de){var L=Ne.toBounds([p.sourcePoint,p.targetPoint]),O=v.x-L.left,N=v.y-L.top;p.sourcePoint.x+=O,p.sourcePoint.y+=N,p.targetPoint.x+=O,p.targetPoint.y+=N}e.preventDiagramUpdate=!0,e.currentSymbol=p,"SVG"!==e.mode&&e.refreshDiagramLayer(),e.selectDragedNode(p,h,S),delete e.enterObject,delete e.enterTable,e.droppable[""+a]=S,e.allowServerDataBinding=!0}}if(b){var T=document.getElementById(b).ej2_instances[0];if(e.droppable.sourceElement=T,T){var B=T[""+a];e.allowServerDataBinding=!1,y=$(T[""+a]),i=T.childTable;var j=B.wrapper.children[0].children[0];if(D=function Hse(n,t,e){var i=bF(n,t,e,"width"),r=bF(n,t,e,"height");return new me(i,r)}(T,y,j),T[""+a]instanceof te){"TextAnnotation"===B.shape.shape?(y.offsetX=v.x+11+D.width*y.pivot.x,y.offsetY=v.y+11+D.height*y.pivot.y):(y.offsetX=v.x+5+D.width*y.pivot.x,y.offsetY=v.y+D.height*y.pivot.y),"Bpmn"===(x=new te(e,"nodes",y,!0)).shape.type&&x.shape.activity.subProcess.processes&&x.shape.activity.subProcess.processes.length&&(x.shape.activity.subProcess.processes=[]),w=x.previewSize,C=T.symbolDragSize;var Q=T.symbolPreview;if(x.width=(M=x.dragSize).width||C.width||w.width||Q.width||x.width,x.height=M.height||C.height||w.height||Q.height||x.height,"SwimLane"===x.shape.type){if(e.diagramActions|=ee.PreventHistory,x.shape.isLane){x.children=[],s={id:"header"+Qe()},"Horizontal"===x.shape.orientation?(s.width=x.shape.lanes[0].header.width,s.height=x.shape.lanes[0].height):(s.width=x.shape.lanes[0].width,s.height=x.shape.lanes[0].header.height),s.style=x.shape.lanes[0].header.style,s.offsetX=v.x+l+s.width/2,s.offsetY=v.y+s.height/2,e.diagramActions|=ee.PreventCollectionChangeOnDragOver,s=e.add(s),o={id:"body"+Qe()},"Horizontal"===x.shape.orientation?(o.width=x.shape.lanes[0].width-s.width,o.height=x.shape.lanes[0].height,o.offsetX=v.x+l+(x.shape.lanes[0].header.width+o.width/2),o.offsetY=v.y+o.height/2):(o.width=x.shape.lanes[0].width,o.height=x.shape.lanes[0].height-s.height,o.offsetX=v.x+l+o.width/2,o.offsetY=v.y+(x.shape.lanes[0].header.height+o.height/2)),o.style=x.shape.lanes[0].style,o=e.add(o);var oe={id:"group"+Qe(),children:[s.id,o.id]};oe.shape=x.shape,oe.width=x.shape.lanes[0].width,oe.height=x.shape.lanes[0].height,oe.previewSize=x.previewSize,oe.dragSize=x.dragSize,oe.addInfo=x.addInfo,x=e.add(oe),e.diagramActions&=~ee.PreventCollectionChangeOnDragOver}e.diagramActions&=~ee.PreventHistory}if(x.shape.isPhase&&((g="Horizontal"===x.shape.orientation)?(x.offsetX=v.x+l+(x.width||j.actualSize.width)/2,x.offsetY=v.y,x.shape.data="M20,"+x.height/2+" L"+(x.width-20)+","+x.height/2+"z",x.height=1):(x.offsetX=v.x+5,x.offsetY=v.y+(x.height||j.actualSize.height)/2,x.shape.data="M"+x.width/2+",20 L"+x.width/2+","+(x.height-20)+"z",x.width=1)),"UmlClassifier"===x.shape.type&&(x.children=x.width=x.height=void 0,y.children=void 0,"Class"===x.shape.classifier&&x.shape.classShape.methods.length<=0&&x.shape.classShape.attributes.length<=0&&(x.shape.classShape.attributes=[{name:"Name",type:"Type",style:{}}]),"Enumeration"===x.shape.classifier&&x.shape.enumerationShape.members.length<=0&&(x.shape.enumerationShape.members=[{name:"Name"}]),"Interface"===x.shape.classifier&&x.shape.interfaceShape.methods.length<=0&&x.shape.interfaceShape.attributes.length<=0&&(x.shape.interfaceShape.attributes=[{name:"Name",type:"Type",style:{}}])),p=x,y.children){var ue=y;r=e.getChildren(ue,{},i),Kx(ue,-ue.offsetX,-ue.offsetY,r,!0,e)}}else if(T[""+a]instanceof de){p=new de(e,"connectors",y,!0);var Me=Ne.toBounds([p.sourcePoint,p.targetPoint]),De=v.x-Me.left,xe=v.y-Me.top;p.sourcePoint.x+=De,p.sourcePoint.y+=xe,p.targetPoint.x+=De,p.targetPoint.y+=xe}p.shape.isLane||(p.id+=Qe());var A={source:T,element:p,cancel:!1,diagram:e,dragData:null,dragItem:p};if(e.enterObject=p,e.enterTable=r,e.triggerEvent(Ce.dragEnter,A),p instanceof te&&"SwimLane"===p.shape.type&&p.shape.isLane){var Ie=A.element,Ve=Ie.shape.lanes[0];g="Horizontal"===Ie.shape.orientation;var ot=e.nameTable[p.children[0]],$e=e.nameTable[p.children[1]];w=p.previewSize,C=T.symbolDragSize,Ve.width=(M=p.dragSize).width||C.width||w.width||Ve.width,Ve.height=M.height||C.height||w.height||Ve.height,g?(s.width=Ve.header.width,s.height=Ve.height,o.width=Ve.width-s.width,o.height=Ve.height,o.offsetX=v.x+l+(Ve.header.width+$e.width/2),o.offsetY=v.y+$e.height/2):(s.width=Ve.width,s.height=Ve.header.height,o.width=Ve.width,o.height=Ve.height-s.height,o.offsetX=v.x+l+$e.width/2,o.offsetY=v.y+(Ve.header.height+$e.height/2)),s.offsetX=v.x+l+ot.width/2,s.offsetY=v.y+ot.height/2,p.width=Ve.width,p.height=Ve.height}if(p instanceof te&&p.shape.isPhase&&(g?p.height=1:p.width=1),!e.activeLayer.lock&&!A.cancel){if(e.preventDiagramUpdate=!0,p.children&&e.findChild(p,r),e.preventDiagramUpdate=!0,p.zIndex!==Number.MIN_VALUE&&(p.zIndex=Number.MIN_VALUE),e.initObject(p,void 0,void 0,!0),e.bpmnModule)for(var Ci=0;Ci0&&(S.segments=[]),d=this.add(S,!0)),(S||d)&&(Bv(this)||Fv(this))&&this.select([this.nameTable[S[""+b]]],!1,this.previousSelectedObjects),y.target&&y.target instanceof de&&!0===this.enableConnectorSplit&&this.nameTable[S[""+b]]instanceof te&&(this.commandHandler.connectorSplit(this.nameTable[S[""+b]],y.target),this.commandHandler.PreventConnectorSplit=!1))),this.protectPropertyChange(!1),v=this.nameTable[S[""+b]],S.hasTarget&&(S.nodeId=S.hasTarget,this.remove(S)),this.bpmnModule&&v instanceof te&&S.processId&&(v.processId=S.processId,this.bpmnModule.dropBPMNchild(this.nameTable[v.processId],v,this)),y.cancel||this.endGroupAction(),"SVG"!==this.mode&&this.refreshDiagramLayer(),delete this.droppable[""+c]):(this.triggerEvent(Ce.drop,y={source:h.droppedElement,element:void 0,target:this.eventHandler.hoverNode||this.eventHandler.lastObjectUnderMouse||this,cancel:!1,position:void 0}),S=void 0,b="id"),this.droppable[M="selectedSymbols"]&&this.droppable[""+M].parentNode)gt(this.droppable[""+M]);else for(w=document.getElementsByClassName("e-dragclone"),C=0;C0)for(var f=0;f1),e.previousSelectedObject=null}}},t.prototype.getDropEventArgs=function(e){if(this.eventHandler.lastObjectUnderMouse||this.eventHandler.hoverNode){var i=this.eventHandler.lastObjectUnderMouse||this.eventHandler.hoverNode;e.target=ps(i)===de?{connector:i}:{node:i}}else e.target.diagramId=this.element.id},t.prototype.removeChildInNodes=function(e){if(e){if(e.children)for(var i=0;i1){var l=2;if(e.children&&e.children.length>0)for(;e.children.indexOf(i.objects[s-l])>-1;)l++;this.commandHandler.moveSvgNode(e.id,i.objects[s-l]),this.commandHandler.moveSvgNode(i.objects[s-l],e.id)}else if(o){var h=this.commandHandler.getLayer(this.layerZIndexTable[o.zIndex]).objects[0];h?(this.commandHandler.moveSvgNode(e.id,h),this.commandHandler.updateNativeNodeIndex(e.id,h)):this.moveObjectsUp(e,i)}else this.moveObjectsUp(e,i)},t.prototype.moveObjectsUp=function(e,i){for(var r,s=this.layers.length-1;s>=0;s--)if(r=this.layers[parseInt(s.toString(),10)],i.id!==r.id){var o=this.commandHandler.getLayer(this.layerZIndexTable[r.zIndex]).objects[r.objects.length-1];if(o){this.commandHandler.moveSvgNode(e.id,o),this.commandHandler.moveSvgNode(o,e.id);break}}},t.prototype.insertData=function(e){return this.crudOperation(e,"create",this.getNewUpdateNodes("New"))},t.prototype.updateData=function(e){return this.crudOperation(e,"update",this.getNewUpdateNodes("Update"))},t.prototype.removeData=function(e){return this.crudOperation(e,"destroy",this.getDeletedNodes())},t.prototype.crudOperation=function(e,i,r){if(e){var s=this.parameterMap(e,!(e instanceof de));if(s){var o=e instanceof de?this.dataSourceSettings.connectionDataSource.crudAction[""+i]:this.dataSourceSettings.crudAction[""+i];this.raiseAjaxPost(JSON.stringify(s),o)}return s}var a=r;return this.processCrudCollection(a,this.dataSourceSettings.crudAction[""+i],this.dataSourceSettings.connectionDataSource.crudAction[""+i]),a},t.prototype.processCrudCollection=function(e,i,r){if(e.nodes){var s=[],o=void 0;for(o=0;o0&&this.raiseAjaxPost(JSON.stringify(s),i)}if(e.connectors){for(s=[],o=void 0,o=0;o0&&this.raiseAjaxPost(JSON.stringify(s),r)}},t.prototype.parameterMap=function(e,i){var s,r={},o=i?this.dataSourceSettings:this.dataSourceSettings.connectionDataSource;if(o.id&&(r[o.id]=e.id),o.sourcePointX&&o.sourcePointY&&(r[o.sourcePointX]=e.sourcePoint.x,r[o.sourcePointY]=e.sourcePoint.y),o.targetPointX&&o.targetPointY&&(r[o.targetPointX]=e.targetPoint.x,r[o.targetPointY]=e.targetPoint.y),o.sourceID&&(r[o.sourceID]=e.sourceID),o.targetID&&(r[o.targetID]=e.targetID),o.crudAction&&o.crudAction.customFields&&o.crudAction.customFields.length>0)for(s=0;s0&&(l=a.length),r.annotations=[{content:o.data.label[parseInt(l.toString(),10)]}]}s=this.getConnectorArrowType(o.data)}var h=new de(i,"connectors",r,!0);return s&&(h.style.strokeWidth=s.strokeWidth,h.targetDecorator.shape=s.targetDecorator),Ro(h,r,i.connectorDefaults),h},n.prototype.getConnectorArrowType=function(t){if(""===t.arrowType)return{targetDecorator:"Arrow",strokeWidth:1};switch(t.arrowType){case"None":return{targetDecorator:"None",strokeWidth:1};case"Arrow":default:return{targetDecorator:"Arrow",strokeWidth:1};case"Diamond":return{targetDecorator:"Diamond",strokeWidth:1};case"Circle":return{targetDecorator:"Circle",strokeWidth:1};case"OpenArrow":return{targetDecorator:"OpenArrow",strokeWidth:1};case"Square":return{targetDecorator:"Square",strokeWidth:1};case"Fletch":return{targetDecorator:"Fletch",strokeWidth:1};case"OpenFetch":return{targetDecorator:"OpenFetch",strokeWidth:1};case"IndentedArrow":return{targetDecorator:"IndentedArrow",strokeWidth:1};case"OutdentedArrow":return{targetDecorator:"OutdentedArrow",strokeWidth:1};case"DoubleArrow":return{targetDecorator:"DoubleArrow",strokeWidth:1}}},n}(),uae=function(){function n(){this.protectChange=!1,this.setIntervalObject=[]}return n.prototype.expand=function(t,e,i,r){var s=this,a=0;if(r.realActions=r.realActions|$i.AnimationClick,this.setIntervalObject[parseInt((0).toString(),10)]=setInterval(function(){return a++,s.layoutAnimation(e,s.setIntervalObject,6===a,r,i)},20),i.isExpanded){var l=.2;r.protectPropertyChange(!1);var h={};t&&(this.updateOpacity(i,l,r),h[parseInt((0).toString(),10)]=setInterval(function(){r.allowServerDataBinding=!1,l<=1?s.updateOpacity(i,l,r):clearInterval(h[0]),l+=.2,r.allowServerDataBinding=!0},20))}},n.prototype.stopCurrentAnimation=function(t,e,i){clearInterval(this.setIntervalObject[0]),this.setIntervalObject=[];for(var r=0;r0){t.rootNode=t.firstLevelNodes[0];var u=0,f=0,p=void 0,g=void 0,v=void 0,y=void 0,S=void 0;for(a=0;ad.y||(l.y=d.y),void 0!==l.mid&&(e=l.mid),l.tree.assistants.length&&(y=this.setBreadthSpaceForAssistants(t,r,d,void 0!==e?e:d.x,b,s),u||(e=((g=f=y).x+g.right)/2-d.width/2,f=g),v=y?y.canMoveBy:void 0),l.x=e,l.translate||(l.treeWidth=f.right-f.x),this.translateSubTree({layout:t,shape:r,shapeBounds:{x:e,y:d.y,right:e+d.width,bottom:d.y+d.height},treeBounds:f,dim:d,level:s},v,void 0!==o,a),l.firstChild&&"string"!=typeof l.firstChild&&(l.firstChild.x+=l.subTreeTranslation),r.treeBounds=f,f},n.prototype.updateLeafNode=function(t,e,i,r,s,o){var a=t.graphNodes[e.id];a.x=r.x,a.y&&a.y>r.y||(a.y=r.y,a.maxLevel=Math.max(s,a.maxLevel||0));var l={x:r.x,y:r.y,right:r.x+r.width,bottom:r.y+r.height};return a.maxLevel=Math.max(a.maxLevel||0,s),this.translateSubTree({layout:t,shape:e,shapeBounds:l,treeBounds:l,dim:r,level:s},void 0,void 0!==i,o),{x:a.x,y:a.y,right:a.x+r.width,bottom:a.y+r.height}},n.prototype.setUpLayoutInfo=function(t,e){var i={subTreeTranslation:0};return i.tree="OrganizationalChart"===t.type?{orientation:"Vertical",type:"Alternate",offset:20,enableRouting:!0}:{orientation:"Horizontal",type:"Center",enableRouting:!0},i.tree.children=[],i.tree.assistants=[],i.tree.level=0,i.translate=!0,i},n.prototype.translateSubTree=function(t,e,i,r){var s=t.layout,o=t.shape,a=t.shapeBounds,l=t.treeBounds,h=t.level,c=t.dim,d=s.graphNodes[o.id],u=s.nameTable[d.firstChild?d.firstChild.child:d.tree.children[0]],f=u?s.graphNodes[u.id]:null,p=this.hasChild(s,o),g=this.findIntersectingLevels(s,a,h,d.actualLevel),v=this.findIntersectingLevels(s,l,h,d.actualLevel),y=[];g.length&&d.translate?(d.intersect=g,this.spaceLeftFromPrevSubTree(s,o,a),d.canMoveBy=d.diff,void 0!==e&&(d.canMoveBy=Math.min(e,d.canMoveBy)),u&&void 0!==f.canMoveBy&&(f.canMoveBy>=d.canMoveBy&&(d.translated=!0),d.canMoveBy=Math.min(d.canMoveBy,f.canMoveBy)),i&&(d.x-=d.canMoveBy,d.subTreeTranslation-=d.canMoveBy,p&&(this.shiftSubordinates(s,v,d.canMoveBy),l.x=Math.min(l.x,d.x),l.right=Math.max(l.right,d.x+c.width),l.bottom=Math.max(l.bottom,d.y+c.height),l.x-=d.canMoveBy,l.right-=d.canMoveBy),u&&f.canMoveBy>d.canMoveBy?d.canMoveBy=f.canMoveBy-d.canMoveBy:u&&void 0!==d.canMoveBy&&(d.canMoveBy=0))):(p&&(l.x=Math.min(l.x,a.x),l.right=Math.max(l.right,a.x+c.width),l.bottom=Math.max(l.bottom,d.y+c.height)),d.translate||(d.canMoveBy=0,d.subTreeTranslation=0)),r||(y.push({rBounds:a={x:d.x,y:c.y,right:d.x+c.width,bottom:c.y+c.height}}),this.updateRearBounds(s,o,y,h))},n.prototype.updateRearBounds=function(t,e,i,r,s){var o,a,h,d,l=!0,c={};e&&(s=(c=t.graphNodes[e.id]).intersect,l=!c.tree.children.length&&!c.tree.assistants.length);var u=i[0].rBounds,f=i[i.length-1].rBounds;if(s&&s.length){for(d=(o=t.levels[s[0]].rBounds).bottom,o.yf.bottom?i.push({rBounds:{x:o.x,right:o.right,y:u.bottom,bottom:d}}):(o=t.levels[s[s.length-1]].rBounds,l&&o.bottom>f.bottom&&(o.y=f.bottom,i.push({rBounds:o}))),a=s[0],h=i.length-1;h>=0;h--)t.levels.splice(a,0,i[parseInt(h.toString(),10)]);t.levels.splice(a+=i.length,s.length)}else for(a=this.findLevel(t,i[i.length-1].rBounds,r),h=i.length-1;h>=0;h--)t.levels.splice(a,0,i[parseInt(h.toString(),10)])},n.prototype.shiftSubordinates=function(t,e,i){var r;if(0!==i)for(r=0;rA.right&&(A.right=M.right),A.bottom=M.bottom):A=M,0===x&&(l.firstChild={x:P.x,canMoveBy:P.canMoveBy,child:g.id}),this.hasChild(t,g)&&(!l.firstChild||l.firstChild.x>=P.firstChild.x?(P.firstChild&&l.firstChild.canMoveByP.canMoveBy&&(l.firstChild.canMoveBy=t.graphNodes[l.firstChild.child].canMoveBy=P.canMoveBy)),w=w?Math.max(P.maxLevel,w):P.maxLevel,this.uniteRects(b,v),d=0!==x&&!this.hasChild(t,g)&&P.subTreeTranslation<0?v.right-P.subTreeTranslation+t.horizontalSpacing:v.right+t.horizontalSpacing;isNaN(C)||(L.canMoveBy=C),l.mid=(L.x+A.right)/2-a.width/2,"Left"===h?l.mid=M.right-a.width:"Right"===h&&(l.mid=r)}return b},n.prototype.updateHorizontalTreeWithMultipleRows=function(t,e,i,r,s,o){var a,l,h,c,d,p,g,v,y,S=this.getDimensions(t,e,r,s,o),b=t.graphNodes[e.id],w=o,C=r,D=s,x=(t.levels.slice(0,t.levels.length),0);if(this.hasChild(t,e)){var P=-1!==t.orientation.indexOf("Left"),L=void 0,O=this.splitChildrenInRows(t,e),N=5===b.tree.children.length&&3===O[0].length,T=[],z=[];N?z=O:this.splitRows(O,T,z);var U={leftTree:T,rows:O,rightTree:z,dimensions:S},B=this.updateLeftTree(t,U,e,r,D,w);d=U.bounds;var j=void 0;void 0!==B&&(b.mid=(B||0)+(void 0!==B?t.horizontalSpacing/2:0)-S.width/2,j=B+t.horizontalSpacing),D=s;var oe=void 0;for(oe=[],g=0;gl.canMoveBy)&&(x=Math.min(x,l.canMoveBy||0),b.firstChild={x:l.x,child:a.id,canMoveBy:l.canMoveBy}),U.leftCenter=v,U.rightCenter=y,U.align=L,U.level=w,U.rightBounds=oe,this.alignRowsToCenter(t,g,e,U,j)}return d},n.prototype.updateLeftTree=function(t,e,i,r,s,o){for(var h,d,u,f,p,a=e.leftTree,l=t.graphNodes[i.id],c=[],v=(t.orientation.indexOf("Left"),0);vw.canMoveBy&&(d=Math.min(d,w.canMoveBy||0),l.firstChild={x:w.x,child:S.id,canMoveBy:w.canMoveBy}),h=f.right+t.horizontalSpacing}u=0===v?c[parseInt(v.toString(),10)].right:Math.max(u,c[parseInt(v.toString(),10)].right)}for(v=0;v=g[1].right-g[1].x?0:1),e===c.length-1&&(c[parseInt(e.toString(),10)].length%2==1||S&&1===e)){a=d[parseInt(e.toString(),10)][Math.floor(d[parseInt(e.toString(),10)].length/2)];var M=t.graphNodes[""+a].x,C=this.getDimensions(t,t.nameTable[""+a],M,t.graphNodes[""+a].y,y+1);l=void 0,!p&&S?(1===o&&(e=0),l=(g[parseInt(o.toString(),10)].x+g[parseInt(o.toString(),10)].right)/2-(g[parseInt(e.toString(),10)].x+g[parseInt(e.toString(),10)].right)/2,0===e&&(h.mid+=l)):!S&&void 0!==s&&(l=s-t.horizontalSpacing/2-(M+C.width/2)),void 0!==l&&this.updateRearBoundsOfTree(t,d[parseInt(e.toString(),10)],l,v),S&&(h.mid=(f+u)/2+(0===e?l:0)-v.width/2),void 0===h.mid&&t.graphNodes[""+a]&&(h.mid=M),p=!1,e++}},n.prototype.updateRearBoundsOfTree=function(t,e,i,r){for(var s=0;s2?"Left":"Right",M=A%2==0&&y.tree.children.length>2?-1:0),w=i+this.findOffset(t,e,y,P),a=t.nameTable[y.tree.children[parseInt(A.toString(),10)]],d=b?a.actualSize.width:a.actualSize.height,h=this.updateTree(t,w+M*(c=b?a.actualSize.height:a.actualSize.width),C,a,s+1,void 0,!0),p={x:(l=t.graphNodes[a.id]).x,y:l.y,right:l.x+c,bottom:l.y+d},0===A?(this.uniteRects(h,p),f=h):this.uniteRects(f,h),l.prevBounds&&!("Alternate"===y.tree.type&&A%2==1&&y.tree.children.length>2)&&(N=void 0!==N?Math.min(l.canMoveBy,N):l.canMoveBy),y.maxLevel=Math.max(y.maxLevel||0,l.maxLevel||0),"Alternate"===y.tree.type&&y.tree.children.length>2&&A%2==0?(0!==A&&(C=u.bottom+t.verticalSpacing/2),O.push({rBounds:p}),l.levelBounds&&(O=O.concat(l.levelBounds))):(C="Alternate"===y.tree.type&&y.tree.children.length>2?Math.max(h.bottom,u.bottom)+t.verticalSpacing/2:h.bottom+t.verticalSpacing/2,s=y.maxLevel,L.push({rBounds:p}),v?this.uniteRects(v,p):v={x:l.x,y:l.y,right:l.x+c,bottom:l.y+d},l.levelBounds&&(L=L.concat(l.levelBounds))),0===A&&(y.firstChild={x:l.x,canMoveBy:l.canMoveBy,child:a.id}),this.hasChild(t,a))if(!y.firstChild||y.firstChild.x>=l.firstChild.x){if(l.firstChild&&y.firstChild.canMoveByl.canMoveBy&&(y.firstChild.canMoveBy=t.graphNodes[y.firstChild.child].canMoveBy=l.canMoveBy);u=p}return o?y.levelBounds=L:("Alternate"===y.tree.type&&y.tree.children.length>2&&(x=this.findIntersectingLevels(t,{x:O[0].rBounds.x,y:O[0].rBounds.y,right:O[O.length-1].rBounds.right,bottom:O[O.length-1].rBounds.bottom},D+1),this.updateRearBounds(t,null,O,D+1,x)),x=this.findIntersectingLevels(t,v||f,D+1),this.updateRearBounds(t,null,v?L:[{rBounds:f}],D+1,x)),isNaN(N)||(t.graphNodes[S.id].canMoveBy=N),y.childBounds=f,y.mid=i,f},n.prototype.splitChildrenInRows=function(t,e){var r,i=t.graphNodes[e.id];r=4;var o,s=[];o=i.tree.children.length;var a=this.extend(i.tree.children);if(i.tree.rows){var h=i.tree.rows;r=h%2==0?h:h-1}else 3===i.tree.children.length||4===i.tree.children.length?r=2:5===i.tree.children.length&&(r=3);for(;o>0;)s[s.length]=a.splice(0,r),(o-=r)=t.horizontalSpacing&&(s=t.horizontalSpacing/2),r||i.tree.type){case"Left":s=o/2-s;break;case"Right":s+=o/2}return s},n.prototype.uniteRects=function(t,e){t.x=Math.min(t.x,e.x),t.right=Math.max(t.right,e.right),t.bottom=Math.max(t.bottom,e.bottom)},n.prototype.spaceLeftFromPrevSubTree=function(t,e,i){for(var s,o,r=t.graphNodes[e.id],a=t.horizontalSpacing,l=0;la.y||s.y=a.y&&s.bottom<=a.bottom||s.ya.bottom))o.splice(0,0,l);else if(a&&a.bottom=0);l=(void 0!==r?r:i)+1,a=t.levels[parseInt(l.toString(),10)]?t.levels[parseInt(l.toString(),10)].rBounds:null;do{if(a&&(s.ya.y||s.y=a.y&&s.bottom<=a.bottom||s.ya.bottom))o.push(l);else if(a&&a.y>s.bottom)break;l++,a=t.levels[parseInt(l.toString(),10)]?t.levels[parseInt(l.toString(),10)].rBounds:null}while(l<=t.levels.length);return o},n.prototype.findLevel=function(t,e,i){var s,o,r=e;for(s=0,o=t.levels[parseInt(s.toString(),10)]?t.levels[parseInt(s.toString(),10)].rBounds:null;s=t.level&&(o.tree.hasSubTree=!1)},n.prototype.updateAnchor=function(t,e,i){var r,s,o=0,a=0,l=0,h=0,c=new Ne(0,0,i.x,i.y),d=t.bounds?t.bounds:c,u=t.orientation;if(t.fixedNode){o=(s=t.nameTable[t.fixedNode]).actualSize.width,a=s.actualSize.height,t.anchorX=s.offsetX,t.anchorY=s.offsetY;var f=s.pivot;for(t.anchorX+="RightToLeft"===t.orientation?o*f.x:-o*f.x,t.anchorY+="BottomToTop"===t.orientation?a*f.y:-a*f.y,r=s,l=0;r.inEdges.length;)r=this.getParentNode(t,r),l+=t.graphNodes[r.id].subTreeTranslation||0;-1!==t.orientation.indexOf("Left")?(h=t.graphNodes[s.id].y,"LeftToRight"===u?t.anchorX-=h:t.anchorX+=h,t.anchorY-=t.graphNodes[s.id].x+l):(h=t.graphNodes[s.id].y,t.anchorX-=t.graphNodes[s.id].x+l,"TopToBottom"===u?t.anchorY-=h:t.anchorY+=h)}else if("TopToBottom"===u||"BottomToTop"===u){switch(t.horizontalAlignment){case"Left":t.anchorX=d.x-e.x+t.margin.left;break;case"Right":t.anchorX=d.x+d.width-t.margin.right-e.right;break;case"Auto":case"Center":t.anchorX=d.x+d.width/2-(e.x+e.right)/2}switch(t.verticalAlignment){case"Auto":case"Top":var p;p=d.y+t.margin.top,t.anchorY="TopToBottom"===u?p:e.bottom+p;break;case"Bottom":var g;g=d.y+d.height-t.margin.bottom,t.anchorY="TopToBottom"===u?g-e.bottom:g;break;case"Center":var v=void 0;v=d.y+d.height/2,t.anchorY="TopToBottom"===t.orientation?v-(e.y+e.bottom)/2:v+(e.y+e.bottom)/2}}else{switch(t.horizontalAlignment){case"Auto":case"Left":var y;y=d.x+t.margin.left,t.anchorX="LeftToRight"===u?y:e.bottom+y;break;case"Right":var S;S=d.x+d.width-t.margin.right,t.anchorX="LeftToRight"===u?S-e.bottom:S;break;case"Center":v=void 0,v=d.width/2+d.x,t.anchorX="LeftToRight"===t.orientation?v-(e.y+e.bottom)/2:v+(e.y+e.bottom)/2}switch(t.verticalAlignment){case"Top":t.anchorY=d.y+t.margin.top-e.x;break;case"Auto":case"Center":t.anchorY=d.y+d.height/2-(e.right+e.x)/2;break;case"Bottom":t.anchorY=d.y+d.height-t.margin.bottom-e.right}}},n.prototype.updateConnectors=function(t,e,i){var r,s,o,a=t.graphNodes[e.id];if(e.outEdges.length)for(r=0;r2){l=o.tree.children[1],isNaN(t.graphNodes[""+l].treeWidth)&&(t.graphNodes[""+l].treeWidth=t.nameTable[""+l].actualSize.width);t.orientation.indexOf("Left"),this.getSegmentsForMultipleRows(t,i,r,e)}else o.tree.children.length>5?s<4||si.offsetX?a.middleRight:a.middleLeft).y},h)}else{var h;l=0===t.orientation.indexOf("Left")?o.middleRight:o.middleLeft,s.push(l,{x:a.bottomCenter.x,y:o.middleRight.y},h=e.offsetY>i.offsetY?a.bottomCenter:a.topCenter)}this.getSegmentsFromPoints(s,r)},n.prototype.get5Points=function(t,e,i,r){var l,h,c,d,s=[],o=this.getBounds(e),a=this.getBounds(i);-1!==t.orientation.indexOf("Top")?s.push(l=e.offsetYi.offsetX?a.middleRight:a.middleLeft).x+(c=t.horizontalSpacing/2*(e.offsetX>i.offsetX?1:-1)),y:l.y+d},{x:h.x+c,y:h.y},h):s.push(l=e.offsetX>i.offsetX?o.middleLeft:o.middleRight,{x:l.x+(c=t.horizontalSpacing/4*(e.offsetXi.offsetY?1:-1))},{x:(h=e.offsetY>i.offsetY?a.bottomCenter:a.topCenter).x,y:l.y+d},h),this.getSegmentsFromPoints(s,r)},n.prototype.getSegmentsFromPoints=function(t,e){for(var r,i=[],s=0;s"u"||(y.innerHTML=v.innerHTML?v.innerHTML:"",void 0!==v.className&&(y.className=v.className),void 0!==v.id&&(y.id=v.id),void 0!==v.styles&&y.setAttribute("style",v.styles),void 0!==e.ngAttr&&y.setAttribute(e.ngAttr,""),void 0!==v.attrs&&Fe(y,v.attrs)),y};for(var i=0,r=e.tags;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s}!function CZ(n){CC.compile=n.compile}({compile:function Hae(n,t){if("string"==typeof n||"function"==typeof n&&n.prototype&&n.prototype.CSPTemplate)return Rae(n,t);var e=n.elementRef.nativeElement._viewContainerRef,i=n.elementRef.nativeElement.propName;return function(r,s,o){var l=e||s.viewContainerRef,h=l.createEmbeddedView(n,{$implicit:r});/EJS-MENTION|EJS-DROPDOWNLIST/.test(Y("currentInstance.element.nodeName",l))||/E-TABITEM/.test(Y("element.nativeElement.nodeName",l))?h.detectChanges():h.markForCheck();var c=s&&s.registeredTemplate?s.registeredTemplate:Y("currentInstance.registeredTemplate",l);return typeof c["".concat(o=o&&s.registeredTemplate?o:i)]>"u"&&(c["".concat(o)]=[]),c["".concat(o)].push(h),h.rootNodes}}});const jae=["annotationTemplate"],Vae=["nodeTemplate"],Wae=["userHandleTemplate"];let Yae=["addInfo","id","lock","objects","visible","zIndex"],Qae=[],Gae=(()=>{class n extends Bh{constructor(e){super(),this.viewContainerRef=e,_l("currentInstance",this,this.viewContainerRef),this.registerEvents(Qae),this.directivePropList=Yae}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-layer"]],inputs:{addInfo:"addInfo",id:"id",lock:"lock",objects:"objects",visible:"visible",zIndex:"zIndex"},features:[yn]}),n})(),Xae=(()=>{class n extends Fh{constructor(){super("layers")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-layers"]],contentQueries:function(e,i,r){if(1&e&&dn(r,Gae,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),qae=["action","cursor"],$ae=[],Zae=(()=>{class n extends Bh{constructor(e){super(),this.viewContainerRef=e,_l("currentInstance",this,this.viewContainerRef),this.registerEvents($ae),this.directivePropList=qae}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-cursormap"]],inputs:{action:"action",cursor:"cursor"},features:[yn]}),n})(),Jae=(()=>{class n extends Fh{constructor(){super("customcursor")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-cursormaps"]],contentQueries:function(e,i,r){if(1&e&&dn(r,Zae,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),Kae=["alignment","cornerRadius","displacement","fill","handleStrokeColor","handleStrokeWidth","height","iconStrokeColor","iconStrokeWidth","id","offset","padding","pathData","tooltip","visibility","width"],ele=[],tle=(()=>{class n extends Bh{constructor(e){super(),this.viewContainerRef=e,_l("currentInstance",this,this.viewContainerRef),this.registerEvents(ele),this.directivePropList=Kae}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-connector-fixeduserhandle"]],inputs:{alignment:"alignment",cornerRadius:"cornerRadius",displacement:"displacement",fill:"fill",handleStrokeColor:"handleStrokeColor",handleStrokeWidth:"handleStrokeWidth",height:"height",iconStrokeColor:"iconStrokeColor",iconStrokeWidth:"iconStrokeWidth",id:"id",offset:"offset",padding:"padding",pathData:"pathData",tooltip:"tooltip",visibility:"visibility",width:"width"},features:[yn]}),n})(),ile=(()=>{class n extends Fh{constructor(){super("fixeduserhandles")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-connector-fixeduserhandles"]],contentQueries:function(e,i,r){if(1&e&&dn(r,tle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),rle=["addInfo","alignment","annotationType","constraints","content","displacement","dragLimit","height","horizontalAlignment","hyperlink","id","margin","offset","rotateAngle","rotationReference","segmentAngle","style","template","tooltip","type","verticalAlignment","visibility","width"],nle=[],sle=(()=>{class n extends Bh{constructor(e){super(),this.viewContainerRef=e,_l("currentInstance",this,this.viewContainerRef),this.registerEvents(nle),this.directivePropList=rle}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-connector-annotation"]],inputs:{addInfo:"addInfo",alignment:"alignment",annotationType:"annotationType",constraints:"constraints",content:"content",displacement:"displacement",dragLimit:"dragLimit",height:"height",horizontalAlignment:"horizontalAlignment",hyperlink:"hyperlink",id:"id",margin:"margin",offset:"offset",rotateAngle:"rotateAngle",rotationReference:"rotationReference",segmentAngle:"segmentAngle",style:"style",template:"template",tooltip:"tooltip",type:"type",verticalAlignment:"verticalAlignment",visibility:"visibility",width:"width"},features:[yn]}),n})(),ole=(()=>{class n extends Fh{constructor(){super("annotations")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-connector-annotations"]],contentQueries:function(e,i,r){if(1&e&&dn(r,sle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),ale=["addInfo","allowNodeOverlap","annotations","bezierSettings","bridgeSpace","connectionPadding","connectorSpacing","constraints","cornerRadius","dragSize","excludeFromLayout","fixedUserHandles","flip","flipMode","hitPadding","id","margin","maxSegmentThumb","ports","previewSize","segmentThumbShape","segmentThumbSize","segments","shape","sourceDecorator","sourceID","sourcePadding","sourcePoint","sourcePortID","style","symbolInfo","targetDecorator","targetID","targetPadding","targetPoint","targetPortID","tooltip","type","visible","wrapper","zIndex"],lle=[],hle=(()=>{class n extends Bh{constructor(e){super(),this.viewContainerRef=e,this.tags=["fixedUserHandles","annotations"],_l("currentInstance",this,this.viewContainerRef),this.registerEvents(lle),this.directivePropList=ale}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-connector"]],contentQueries:function(e,i,r){if(1&e&&(dn(r,ile,5),dn(r,ole,5)),2&e){let s;Kr(s=en())&&(i.childFixedUserHandles=s.first),Kr(s=en())&&(i.childAnnotations=s.first)}},inputs:{addInfo:"addInfo",allowNodeOverlap:"allowNodeOverlap",annotations:"annotations",bezierSettings:"bezierSettings",bridgeSpace:"bridgeSpace",connectionPadding:"connectionPadding",connectorSpacing:"connectorSpacing",constraints:"constraints",cornerRadius:"cornerRadius",dragSize:"dragSize",excludeFromLayout:"excludeFromLayout",fixedUserHandles:"fixedUserHandles",flip:"flip",flipMode:"flipMode",hitPadding:"hitPadding",id:"id",margin:"margin",maxSegmentThumb:"maxSegmentThumb",ports:"ports",previewSize:"previewSize",segmentThumbShape:"segmentThumbShape",segmentThumbSize:"segmentThumbSize",segments:"segments",shape:"shape",sourceDecorator:"sourceDecorator",sourceID:"sourceID",sourcePadding:"sourcePadding",sourcePoint:"sourcePoint",sourcePortID:"sourcePortID",style:"style",symbolInfo:"symbolInfo",targetDecorator:"targetDecorator",targetID:"targetID",targetPadding:"targetPadding",targetPoint:"targetPoint",targetPortID:"targetPortID",tooltip:"tooltip",type:"type",visible:"visible",wrapper:"wrapper",zIndex:"zIndex"},features:[yn]}),n})(),cle=(()=>{class n extends Fh{constructor(){super("connectors")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-connectors"]],contentQueries:function(e,i,r){if(1&e&&dn(r,hle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),dle=["cornerRadius","fill","handleStrokeColor","handleStrokeWidth","height","iconStrokeColor","iconStrokeWidth","id","margin","offset","padding","pathData","tooltip","visibility","width"],ule=[],fle=(()=>{class n extends Bh{constructor(e){super(),this.viewContainerRef=e,_l("currentInstance",this,this.viewContainerRef),this.registerEvents(ule),this.directivePropList=dle}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-node-fixeduserhandle"]],inputs:{cornerRadius:"cornerRadius",fill:"fill",handleStrokeColor:"handleStrokeColor",handleStrokeWidth:"handleStrokeWidth",height:"height",iconStrokeColor:"iconStrokeColor",iconStrokeWidth:"iconStrokeWidth",id:"id",margin:"margin",offset:"offset",padding:"padding",pathData:"pathData",tooltip:"tooltip",visibility:"visibility",width:"width"},features:[yn]}),n})(),ple=(()=>{class n extends Fh{constructor(){super("fixeduserhandles")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-node-fixeduserhandles"]],contentQueries:function(e,i,r){if(1&e&&dn(r,fle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),gle=["addInfo","annotationType","constraints","content","dragLimit","height","horizontalAlignment","hyperlink","id","margin","offset","rotateAngle","rotationReference","style","template","tooltip","type","verticalAlignment","visibility","width"],vle=[],mle=(()=>{class n extends Bh{constructor(e){super(),this.viewContainerRef=e,_l("currentInstance",this,this.viewContainerRef),this.registerEvents(vle),this.directivePropList=gle}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-node-annotation"]],inputs:{addInfo:"addInfo",annotationType:"annotationType",constraints:"constraints",content:"content",dragLimit:"dragLimit",height:"height",horizontalAlignment:"horizontalAlignment",hyperlink:"hyperlink",id:"id",margin:"margin",offset:"offset",rotateAngle:"rotateAngle",rotationReference:"rotationReference",style:"style",template:"template",tooltip:"tooltip",type:"type",verticalAlignment:"verticalAlignment",visibility:"visibility",width:"width"},features:[yn]}),n})(),yle=(()=>{class n extends Fh{constructor(){super("annotations")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-node-annotations"]],contentQueries:function(e,i,r){if(1&e&&dn(r,mle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),Sle=["addInfo","connectionDirection","constraints","height","horizontalAlignment","id","inEdges","margin","offset","outEdges","pathData","shape","style","tooltip","verticalAlignment","visibility","width"],Ile=[],ble=(()=>{class n extends Bh{constructor(e){super(),this.viewContainerRef=e,_l("currentInstance",this,this.viewContainerRef),this.registerEvents(Ile),this.directivePropList=Sle}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-node-port"]],inputs:{addInfo:"addInfo",connectionDirection:"connectionDirection",constraints:"constraints",height:"height",horizontalAlignment:"horizontalAlignment",id:"id",inEdges:"inEdges",margin:"margin",offset:"offset",outEdges:"outEdges",pathData:"pathData",shape:"shape",style:"style",tooltip:"tooltip",verticalAlignment:"verticalAlignment",visibility:"visibility",width:"width"},features:[yn]}),n})(),Mle=(()=>{class n extends Fh{constructor(){super("ports")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-node-ports"]],contentQueries:function(e,i,r){if(1&e&&dn(r,ble,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),wle=["addInfo","annotations","backgroundColor","borderColor","borderWidth","branch","children","collapseIcon","columnIndex","columnSpan","columns","constraints","container","data","dragSize","excludeFromLayout","expandIcon","fixedUserHandles","flip","flipMode","height","horizontalAlignment","id","isExpanded","layoutInfo","margin","maxHeight","maxWidth","minHeight","minWidth","offsetX","offsetY","padding","pivot","ports","previewSize","rotateAngle","rowIndex","rowSpan","rows","shadow","shape","style","symbolInfo","tooltip","verticalAlignment","visible","width","wrapper","zIndex"],Cle=[],Ele=(()=>{class n extends Bh{constructor(e){super(),this.viewContainerRef=e,this.tags=["fixedUserHandles","annotations","ports"],_l("currentInstance",this,this.viewContainerRef),this.registerEvents(Cle),this.directivePropList=wle}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-node"]],contentQueries:function(e,i,r){if(1&e&&(dn(r,ple,5),dn(r,yle,5),dn(r,Mle,5)),2&e){let s;Kr(s=en())&&(i.childFixedUserHandles=s.first),Kr(s=en())&&(i.childAnnotations=s.first),Kr(s=en())&&(i.childPorts=s.first)}},inputs:{addInfo:"addInfo",annotations:"annotations",backgroundColor:"backgroundColor",borderColor:"borderColor",borderWidth:"borderWidth",branch:"branch",children:"children",collapseIcon:"collapseIcon",columnIndex:"columnIndex",columnSpan:"columnSpan",columns:"columns",constraints:"constraints",container:"container",data:"data",dragSize:"dragSize",excludeFromLayout:"excludeFromLayout",expandIcon:"expandIcon",fixedUserHandles:"fixedUserHandles",flip:"flip",flipMode:"flipMode",height:"height",horizontalAlignment:"horizontalAlignment",id:"id",isExpanded:"isExpanded",layoutInfo:"layoutInfo",margin:"margin",maxHeight:"maxHeight",maxWidth:"maxWidth",minHeight:"minHeight",minWidth:"minWidth",offsetX:"offsetX",offsetY:"offsetY",padding:"padding",pivot:"pivot",ports:"ports",previewSize:"previewSize",rotateAngle:"rotateAngle",rowIndex:"rowIndex",rowSpan:"rowSpan",rows:"rows",shadow:"shadow",shape:"shape",style:"style",symbolInfo:"symbolInfo",tooltip:"tooltip",verticalAlignment:"verticalAlignment",visible:"visible",width:"width",wrapper:"wrapper",zIndex:"zIndex"},features:[yn]}),n})(),Dle=(()=>{class n extends Fh{constructor(){super("nodes")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-nodes"]],contentQueries:function(e,i,r){if(1&e&&dn(r,Ele,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})();const xle=["animationComplete","click","collectionChange","commandExecute","connectionChange","contextMenuBeforeItemRender","contextMenuClick","contextMenuOpen","created","dataLoaded","doubleClick","dragEnter","dragLeave","dragOver","drop","elementDraw","expandStateChange","fixedUserHandleClick","historyChange","historyStateChange","keyDown","keyUp","load","loaded","mouseEnter","mouseLeave","mouseOver","mouseWheel","onFixedUserHandleMouseDown","onFixedUserHandleMouseEnter","onFixedUserHandleMouseLeave","onFixedUserHandleMouseUp","onImageLoad","onUserHandleMouseDown","onUserHandleMouseEnter","onUserHandleMouseLeave","onUserHandleMouseUp","positionChange","propertyChange","rotateChange","scrollChange","segmentChange","segmentCollectionChange","selectionChange","sizeChange","sourcePointChange","targetPointChange","textEdit"],Tle=[""];let Ale=(()=>{let n=class extends Fl{constructor(e,i,r,s){super(),this.ngEle=e,this.srenderer=i,this.viewContainerRef=r,this.injector=s,this.tags=["layers","customCursor","connectors","nodes"],this.element=this.ngEle.nativeElement,this.injectedModules=this.injectedModules||[];try{let o=this.injector.get("DiagramsHierarchicalTree");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsMindMap");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsRadialTree");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsComplexHierarchicalTree");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsDataBinding");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsSnapping");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsPrintAndExport");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsBpmnDiagrams");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsSymmetricLayout");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsConnectorBridging");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsUndoRedo");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsLayoutAnimation");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsDiagramContextMenu");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsLineRouting");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsConnectorEditing");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsLineDistribution");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsEj1Serialization");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsFlowchartLayout");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}this.registerEvents(xle),this.addTwoWay.call(this,Tle),_l("currentInstance",this,this.viewContainerRef),this.context=new c_}ngOnInit(){this.context.ngOnInit(this)}ngAfterViewInit(){this.context.ngAfterViewInit(this)}ngOnDestroy(){this.context.ngOnDestroy(this)}ngAfterContentChecked(){this.tagObjects[0].instance=this.childLayers,this.childCustomCursor&&(this.tagObjects[1].instance=this.childCustomCursor),this.childConnectors&&(this.tagObjects[2].instance=this.childConnectors),this.childNodes&&(this.tagObjects[3].instance=this.childNodes),this.context.ngAfterContentChecked(this)}};return n.\u0275fac=function(e){return new(e||n)(Ot($c),Ot(sM),Ot(An),Ot(Wo))},n.\u0275cmp=zb({type:n,selectors:[["ejs-diagram"]],contentQueries:function(e,i,r){if(1&e&&(dn(r,jae,5),dn(r,Vae,5),dn(r,Wae,5),dn(r,Xae,5),dn(r,Jae,5),dn(r,cle,5),dn(r,Dle,5)),2&e){let s;Kr(s=en())&&(i.annotationTemplate=s.first),Kr(s=en())&&(i.nodeTemplate=s.first),Kr(s=en())&&(i.userHandleTemplate=s.first),Kr(s=en())&&(i.childLayers=s.first),Kr(s=en())&&(i.childCustomCursor=s.first),Kr(s=en())&&(i.childConnectors=s.first),Kr(s=en())&&(i.childNodes=s.first)}},inputs:{addInfo:"addInfo",annotationTemplate:"annotationTemplate",backgroundColor:"backgroundColor",bridgeDirection:"bridgeDirection",commandManager:"commandManager",connectorDefaults:"connectorDefaults",connectors:"connectors",constraints:"constraints",contextMenuSettings:"contextMenuSettings",customCursor:"customCursor",dataSourceSettings:"dataSourceSettings",diagramSettings:"diagramSettings",drawingObject:"drawingObject",enableConnectorSplit:"enableConnectorSplit",enablePersistence:"enablePersistence",enableRtl:"enableRtl",fixedUserHandleTemplate:"fixedUserHandleTemplate",getConnectorDefaults:"getConnectorDefaults",getCustomCursor:"getCustomCursor",getCustomProperty:"getCustomProperty",getCustomTool:"getCustomTool",getDescription:"getDescription",getNodeDefaults:"getNodeDefaults",height:"height",historyManager:"historyManager",layers:"layers",layout:"layout",locale:"locale",mode:"mode",nodeDefaults:"nodeDefaults",nodeTemplate:"nodeTemplate",nodes:"nodes",pageSettings:"pageSettings",rulerSettings:"rulerSettings",scrollSettings:"scrollSettings",segmentThumbShape:"segmentThumbShape",segmentThumbSize:"segmentThumbSize",selectedItems:"selectedItems",serializationSettings:"serializationSettings",setNodeTemplate:"setNodeTemplate",snapSettings:"snapSettings",tool:"tool",tooltip:"tooltip",updateSelection:"updateSelection",userHandleTemplate:"userHandleTemplate",width:"width"},outputs:{animationComplete:"animationComplete",click:"click",collectionChange:"collectionChange",commandExecute:"commandExecute",connectionChange:"connectionChange",contextMenuBeforeItemRender:"contextMenuBeforeItemRender",contextMenuClick:"contextMenuClick",contextMenuOpen:"contextMenuOpen",created:"created",dataLoaded:"dataLoaded",doubleClick:"doubleClick",dragEnter:"dragEnter",dragLeave:"dragLeave",dragOver:"dragOver",drop:"drop",elementDraw:"elementDraw",expandStateChange:"expandStateChange",fixedUserHandleClick:"fixedUserHandleClick",historyChange:"historyChange",historyStateChange:"historyStateChange",keyDown:"keyDown",keyUp:"keyUp",load:"load",loaded:"loaded",mouseEnter:"mouseEnter",mouseLeave:"mouseLeave",mouseOver:"mouseOver",mouseWheel:"mouseWheel",onFixedUserHandleMouseDown:"onFixedUserHandleMouseDown",onFixedUserHandleMouseEnter:"onFixedUserHandleMouseEnter",onFixedUserHandleMouseLeave:"onFixedUserHandleMouseLeave",onFixedUserHandleMouseUp:"onFixedUserHandleMouseUp",onImageLoad:"onImageLoad",onUserHandleMouseDown:"onUserHandleMouseDown",onUserHandleMouseEnter:"onUserHandleMouseEnter",onUserHandleMouseLeave:"onUserHandleMouseLeave",onUserHandleMouseUp:"onUserHandleMouseUp",positionChange:"positionChange",propertyChange:"propertyChange",rotateChange:"rotateChange",scrollChange:"scrollChange",segmentChange:"segmentChange",segmentCollectionChange:"segmentCollectionChange",selectionChange:"selectionChange",sizeChange:"sizeChange",sourcePointChange:"sourcePointChange",targetPointChange:"targetPointChange",textEdit:"textEdit"},features:[yn],decls:0,vars:0,template:function(e,i){},encapsulation:2,changeDetection:0}),db([xT()],n.prototype,"annotationTemplate",void 0),db([xT()],n.prototype,"nodeTemplate",void 0),db([xT()],n.prototype,"userHandleTemplate",void 0),n=db([Pae([c_])],n),n})(),Lle=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Tm({type:n}),n.\u0275inj=gp({imports:[[tq]]}),n})();const Nle={provide:"DiagramsHierarchicalTree",useValue:n_},Ole={provide:"DiagramsDataBinding",useValue:Koe},kle={provide:"DiagramsLayoutAnimation",useValue:uae},Ple=["diagram"];let zle=(()=>{class n{constructor(){this.data=[{Id:"parent1",Name:"Maria ",Designation:"Managing Director",RatingColor:"#C34444"},{Id:"parent",Name:" sam",Designation:"Managing Director",ReportingPerson:"parent1",RatingColor:"#C34444"}]}getNodeDefaults(e,i){return e.height=40,e.width=100,e.expandIcon={height:15,width:15,shape:"Minus",fill:"lightgray",offset:{x:.5,y:.85}},e.collapseIcon.offset={x:.5,y:.85},e.collapseIcon.height=15,e.collapseIcon.width=15,e.collapseIcon.shape="Plus",e.borderColor="white",e.backgroundColor="#6BA5D7",e.borderWidth=1,e.style={fill:"transparent",strokeWidth:2},e}getConnectorDefaults(e,i){return e.style={strokeColor:"#6BA5D7",strokeWidth:2},e.targetDecorator.style.fill="#6BA5D7",e.targetDecorator.style.strokeColor="#6BA5D7",e.targetDecorator.shape="None",e.type="Orthogonal",e}ngOnInit(){this.selectedItems={constraints:~lr.ResizeAll},this.snapSettings={constraints:0},this.items=new tt(this.data,(new Ht).take(7)),this.layout={enableAnimation:!0,type:"HierarchicalTree",margin:{top:20},getLayoutInfo:(e,i)=>{i.hasSubTree||(i.orientation="vertical",i.type="alternate")}},this.dataSourceSettings={id:"Id",parentId:"ReportingPerson",dataSource:this.items}}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275cmp=zb({type:n,selectors:[["app-container"]],viewQuery:function(i,r){if(1&i&&function dP(n,t,e){const i=Ti();i.firstCreatePass&&(hP(i,new oP(n,t,e),-1),2==(2&t)&&(i.staticViewQueries=!0)),lP(i,Se(),t)}(Ple,5),2&i){let s;Kr(s=en())&&(r.diagram=s.first)}},standalone:!0,features:[OP([Nle,Ole,kle]),PP],decls:2,vars:6,consts:[["id","diagram","width","100%","height","580px",3,"getNodeDefaults","getConnectorDefaults","snapSettings","selectedItems","layout","dataSourceSettings"],["diagram",""]],template:function(i,r){1&i&&tw(0,"ejs-diagram",0,1),2&i&&QM("getNodeDefaults",r.getNodeDefaults)("getConnectorDefaults",r.getConnectorDefaults)("snapSettings",r.snapSettings)("selectedItems",r.selectedItems)("layout",r.layout)("dataSourceSettings",r.dataSourceSettings)},dependencies:[Lle,Ale],encapsulation:2})}}return n})();jd(332),function Qq(n,t){return MG({rootComponent:n,...wz(t)})}(zle).catch(n=>console.error(n))},332:()=>{!function(Z){const se=Z.performance;function ye(zi){se&&se.mark&&se.mark(zi)}function pe(zi,ht){se&&se.measure&&se.measure(zi,ht)}ye("Zone");const be=Z.__Zone_symbol_prefix||"__zone_symbol__";function ke(zi){return be+zi}const at=!0===Z[ke("forceDuplicateZoneCheck")];if(Z.Zone){if(at||"function"!=typeof Z.Zone.__symbol__)throw new Error("Zone already loaded.");return Z.Zone}let it=(()=>{class zi{static{this.__symbol__=ke}static assertZonePatched(){if(Z.Promise!==_o.ZoneAwarePromise)throw new Error("Zone.js has detected that ZoneAwarePromise `(window|global).Promise` has been overwritten.\nMost likely cause is that a Promise polyfill has been loaded after Zone.js (Polyfilling Promise api is not necessary when zone.js is loaded. If you must load one, do so before loading zone.js.)")}static get root(){let F=zi.current;for(;F.parent;)F=F.parent;return F}static get current(){return Ur.zone}static get currentTask(){return Do}static __load_patch(F,ae,Et=!1){if(_o.hasOwnProperty(F)){if(!Et&&at)throw Error("Already loaded patch: "+F)}else if(!Z["__Zone_disable_"+F]){const Xt="Zone:"+F;ye(Xt),_o[F]=ae(Z,zi,cn),pe(Xt,Xt)}}get parent(){return this._parent}get name(){return this._name}constructor(F,ae){this._parent=F,this._name=ae?ae.name||"unnamed":"",this._properties=ae&&ae.properties||{},this._zoneDelegate=new Lt(this,this._parent&&this._parent._zoneDelegate,ae)}get(F){const ae=this.getZoneWith(F);if(ae)return ae._properties[F]}getZoneWith(F){let ae=this;for(;ae;){if(ae._properties.hasOwnProperty(F))return ae;ae=ae._parent}return null}fork(F){if(!F)throw new Error("ZoneSpec required!");return this._zoneDelegate.fork(this,F)}wrap(F,ae){if("function"!=typeof F)throw new Error("Expecting function got: "+F);const Et=this._zoneDelegate.intercept(this,F,ae),Xt=this;return function(){return Xt.runGuarded(Et,this,arguments,ae)}}run(F,ae,Et,Xt){Ur={parent:Ur,zone:this};try{return this._zoneDelegate.invoke(this,F,ae,Et,Xt)}finally{Ur=Ur.parent}}runGuarded(F,ae=null,Et,Xt){Ur={parent:Ur,zone:this};try{try{return this._zoneDelegate.invoke(this,F,ae,Et,Xt)}catch(Vn){if(this._zoneDelegate.handleError(this,Vn))throw Vn}}finally{Ur=Ur.parent}}runTask(F,ae,Et){if(F.zone!=this)throw new Error("A task can only be run in the zone of creation! (Creation: "+(F.zone||jn).name+"; Execution: "+this.name+")");if(F.state===sr&&(F.type===rs||F.type===Pt))return;const Xt=F.state!=lt;Xt&&F._transitionTo(lt,Pi),F.runCount++;const Vn=Do;Do=F,Ur={parent:Ur,zone:this};try{F.type==Pt&&F.data&&!F.data.isPeriodic&&(F.cancelFn=void 0);try{return this._zoneDelegate.invokeTask(this,F,ae,Et)}catch(Ue){if(this._zoneDelegate.handleError(this,Ue))throw Ue}}finally{F.state!==sr&&F.state!==et&&(F.type==rs||F.data&&F.data.isPeriodic?Xt&&F._transitionTo(Pi,lt):(F.runCount=0,this._updateTaskCount(F,-1),Xt&&F._transitionTo(sr,lt,sr))),Ur=Ur.parent,Do=Vn}}scheduleTask(F){if(F.zone&&F.zone!==this){let Et=this;for(;Et;){if(Et===F.zone)throw Error(`can not reschedule task to ${this.name} which is descendants of the original zone ${F.zone.name}`);Et=Et.parent}}F._transitionTo(Zr,sr);const ae=[];F._zoneDelegates=ae,F._zone=this;try{F=this._zoneDelegate.scheduleTask(this,F)}catch(Et){throw F._transitionTo(et,Zr,sr),this._zoneDelegate.handleError(this,Et),Et}return F._zoneDelegates===ae&&this._updateTaskCount(F,1),F.state==Zr&&F._transitionTo(Pi,Zr),F}scheduleMicroTask(F,ae,Et,Xt){return this.scheduleTask(new pt(yi,F,ae,Et,Xt,void 0))}scheduleMacroTask(F,ae,Et,Xt,Vn){return this.scheduleTask(new pt(Pt,F,ae,Et,Xt,Vn))}scheduleEventTask(F,ae,Et,Xt,Vn){return this.scheduleTask(new pt(rs,F,ae,Et,Xt,Vn))}cancelTask(F){if(F.zone!=this)throw new Error("A task can only be cancelled in the zone of creation! (Creation: "+(F.zone||jn).name+"; Execution: "+this.name+")");if(F.state===Pi||F.state===lt){F._transitionTo(ur,Pi,lt);try{this._zoneDelegate.cancelTask(this,F)}catch(ae){throw F._transitionTo(et,ur),this._zoneDelegate.handleError(this,ae),ae}return this._updateTaskCount(F,-1),F._transitionTo(sr,ur),F.runCount=0,F}}_updateTaskCount(F,ae){const Et=F._zoneDelegates;-1==ae&&(F._zoneDelegates=null);for(let Xt=0;Xtzi.hasTask(F,ae),onScheduleTask:(zi,ht,F,ae)=>zi.scheduleTask(F,ae),onInvokeTask:(zi,ht,F,ae,Et,Xt)=>zi.invokeTask(F,ae,Et,Xt),onCancelTask:(zi,ht,F,ae)=>zi.cancelTask(F,ae)};class Lt{constructor(ht,F,ae){this._taskCounts={microTask:0,macroTask:0,eventTask:0},this.zone=ht,this._parentDelegate=F,this._forkZS=ae&&(ae&&ae.onFork?ae:F._forkZS),this._forkDlgt=ae&&(ae.onFork?F:F._forkDlgt),this._forkCurrZone=ae&&(ae.onFork?this.zone:F._forkCurrZone),this._interceptZS=ae&&(ae.onIntercept?ae:F._interceptZS),this._interceptDlgt=ae&&(ae.onIntercept?F:F._interceptDlgt),this._interceptCurrZone=ae&&(ae.onIntercept?this.zone:F._interceptCurrZone),this._invokeZS=ae&&(ae.onInvoke?ae:F._invokeZS),this._invokeDlgt=ae&&(ae.onInvoke?F:F._invokeDlgt),this._invokeCurrZone=ae&&(ae.onInvoke?this.zone:F._invokeCurrZone),this._handleErrorZS=ae&&(ae.onHandleError?ae:F._handleErrorZS),this._handleErrorDlgt=ae&&(ae.onHandleError?F:F._handleErrorDlgt),this._handleErrorCurrZone=ae&&(ae.onHandleError?this.zone:F._handleErrorCurrZone),this._scheduleTaskZS=ae&&(ae.onScheduleTask?ae:F._scheduleTaskZS),this._scheduleTaskDlgt=ae&&(ae.onScheduleTask?F:F._scheduleTaskDlgt),this._scheduleTaskCurrZone=ae&&(ae.onScheduleTask?this.zone:F._scheduleTaskCurrZone),this._invokeTaskZS=ae&&(ae.onInvokeTask?ae:F._invokeTaskZS),this._invokeTaskDlgt=ae&&(ae.onInvokeTask?F:F._invokeTaskDlgt),this._invokeTaskCurrZone=ae&&(ae.onInvokeTask?this.zone:F._invokeTaskCurrZone),this._cancelTaskZS=ae&&(ae.onCancelTask?ae:F._cancelTaskZS),this._cancelTaskDlgt=ae&&(ae.onCancelTask?F:F._cancelTaskDlgt),this._cancelTaskCurrZone=ae&&(ae.onCancelTask?this.zone:F._cancelTaskCurrZone),this._hasTaskZS=null,this._hasTaskDlgt=null,this._hasTaskDlgtOwner=null,this._hasTaskCurrZone=null;const Et=ae&&ae.onHasTask;(Et||F&&F._hasTaskZS)&&(this._hasTaskZS=Et?ae:At,this._hasTaskDlgt=F,this._hasTaskDlgtOwner=this,this._hasTaskCurrZone=ht,ae.onScheduleTask||(this._scheduleTaskZS=At,this._scheduleTaskDlgt=F,this._scheduleTaskCurrZone=this.zone),ae.onInvokeTask||(this._invokeTaskZS=At,this._invokeTaskDlgt=F,this._invokeTaskCurrZone=this.zone),ae.onCancelTask||(this._cancelTaskZS=At,this._cancelTaskDlgt=F,this._cancelTaskCurrZone=this.zone))}fork(ht,F){return this._forkZS?this._forkZS.onFork(this._forkDlgt,this.zone,ht,F):new it(ht,F)}intercept(ht,F,ae){return this._interceptZS?this._interceptZS.onIntercept(this._interceptDlgt,this._interceptCurrZone,ht,F,ae):F}invoke(ht,F,ae,Et,Xt){return this._invokeZS?this._invokeZS.onInvoke(this._invokeDlgt,this._invokeCurrZone,ht,F,ae,Et,Xt):F.apply(ae,Et)}handleError(ht,F){return!this._handleErrorZS||this._handleErrorZS.onHandleError(this._handleErrorDlgt,this._handleErrorCurrZone,ht,F)}scheduleTask(ht,F){let ae=F;if(this._scheduleTaskZS)this._hasTaskZS&&ae._zoneDelegates.push(this._hasTaskDlgtOwner),ae=this._scheduleTaskZS.onScheduleTask(this._scheduleTaskDlgt,this._scheduleTaskCurrZone,ht,F),ae||(ae=F);else if(F.scheduleFn)F.scheduleFn(F);else{if(F.type!=yi)throw new Error("Task is missing scheduleFn.");Wt(F)}return ae}invokeTask(ht,F,ae,Et){return this._invokeTaskZS?this._invokeTaskZS.onInvokeTask(this._invokeTaskDlgt,this._invokeTaskCurrZone,ht,F,ae,Et):F.callback.apply(ae,Et)}cancelTask(ht,F){let ae;if(this._cancelTaskZS)ae=this._cancelTaskZS.onCancelTask(this._cancelTaskDlgt,this._cancelTaskCurrZone,ht,F);else{if(!F.cancelFn)throw Error("Task is not cancelable");ae=F.cancelFn(F)}return ae}hasTask(ht,F){try{this._hasTaskZS&&this._hasTaskZS.onHasTask(this._hasTaskDlgt,this._hasTaskCurrZone,ht,F)}catch(ae){this.handleError(ht,ae)}}_updateTaskCount(ht,F){const ae=this._taskCounts,Et=ae[ht],Xt=ae[ht]=Et+F;if(Xt<0)throw new Error("More tasks executed then were scheduled.");0!=Et&&0!=Xt||this.hasTask(this.zone,{microTask:ae.microTask>0,macroTask:ae.macroTask>0,eventTask:ae.eventTask>0,change:ht})}}class pt{constructor(ht,F,ae,Et,Xt,Vn){if(this._zone=null,this.runCount=0,this._zoneDelegates=null,this._state="notScheduled",this.type=ht,this.source=F,this.data=Et,this.scheduleFn=Xt,this.cancelFn=Vn,!ae)throw new Error("callback is not defined");this.callback=ae;const Ue=this;this.invoke=ht===rs&&Et&&Et.useG?pt.invokeTask:function(){return pt.invokeTask.call(Z,Ue,this,arguments)}}static invokeTask(ht,F,ae){ht||(ht=this),Ls++;try{return ht.runCount++,ht.zone.runTask(ht,F,ae)}finally{1==Ls&&ct(),Ls--}}get zone(){return this._zone}get state(){return this._state}cancelScheduleRequest(){this._transitionTo(sr,Zr)}_transitionTo(ht,F,ae){if(this._state!==F&&this._state!==ae)throw new Error(`${this.type} '${this.source}': can not transition to '${ht}', expecting state '${F}'${ae?" or '"+ae+"'":""}, was '${this._state}'.`);this._state=ht,ht==sr&&(this._zoneDelegates=null)}toString(){return this.data&&typeof this.data.handleId<"u"?this.data.handleId.toString():Object.prototype.toString.call(this)}toJSON(){return{type:this.type,state:this.state,source:this.source,zone:this.zone.name,runCount:this.runCount}}}const Di=ke("setTimeout"),ni=ke("Promise"),mi=ke("then");let is,dr=[],ki=!1;function Pr(zi){if(is||Z[ni]&&(is=Z[ni].resolve(0)),is){let ht=is[mi];ht||(ht=is.then),ht.call(is,zi)}else Z[Di](zi,0)}function Wt(zi){0===Ls&&0===dr.length&&Pr(ct),zi&&dr.push(zi)}function ct(){if(!ki){for(ki=!0;dr.length;){const zi=dr;dr=[];for(let ht=0;htUr,onUnhandledError:jr,microtaskDrainDone:jr,scheduleMicroTask:Wt,showUncaughtError:()=>!it[ke("ignoreConsoleErrorUncaughtError")],patchEventTarget:()=>[],patchOnProperties:jr,patchMethod:()=>jr,bindArguments:()=>[],patchThen:()=>jr,patchMacroTask:()=>jr,patchEventPrototype:()=>jr,isIEOrEdge:()=>!1,getGlobalObjects:()=>{},ObjectDefineProperty:()=>jr,ObjectGetOwnPropertyDescriptor:()=>{},ObjectCreate:()=>{},ArraySlice:()=>[],patchClass:()=>jr,wrapWithCurrentZone:()=>jr,filterProperties:()=>[],attachOriginToPatched:()=>jr,_redefineProperty:()=>jr,patchCallbacks:()=>jr,nativeScheduleMicroTask:Pr};let Ur={parent:null,zone:new it(null,null)},Do=null,Ls=0;function jr(){}pe("Zone","Zone"),Z.Zone=it}(globalThis);const Wl=Object.getOwnPropertyDescriptor,Ud=Object.defineProperty,jd=Object.getPrototypeOf,Vd=Object.create,pb=Array.prototype.slice,um="addEventListener",$r="removeEventListener",Yl=Zone.__symbol__(um),_h=Zone.__symbol__($r),Ts="true",Wi="false",Wd=Zone.__symbol__("");function op(Z,se){return Zone.current.wrap(Z,se)}function fm(Z,se,ye,pe,be){return Zone.current.scheduleMacroTask(Z,se,ye,pe,be)}const Ji=Zone.__symbol__,Uh=typeof window<"u",jh=Uh?window:void 0,gn=Uh&&jh||globalThis,pm="removeAttribute";function Yd(Z,se){for(let ye=Z.length-1;ye>=0;ye--)"function"==typeof Z[ye]&&(Z[ye]=op(Z[ye],se+"_"+ye));return Z}function ap(Z){return!Z||!1!==Z.writable&&!("function"==typeof Z.get&&typeof Z.set>"u")}const lp=typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope,Vh=!("nw"in gn)&&typeof gn.process<"u"&&"[object process]"==={}.toString.call(gn.process),Qd=!Vh&&!lp&&!(!Uh||!jh.HTMLElement),hp=typeof gn.process<"u"&&"[object process]"==={}.toString.call(gn.process)&&!lp&&!(!Uh||!jh.HTMLElement),Ql={},Wh=function(Z){if(!(Z=Z||gn.event))return;let se=Ql[Z.type];se||(se=Ql[Z.type]=Ji("ON_PROPERTY"+Z.type));const ye=this||Z.target||gn,pe=ye[se];let be;return Qd&&ye===jh&&"error"===Z.type?(be=pe&&pe.call(this,Z.message,Z.filename,Z.lineno,Z.colno,Z.error),!0===be&&Z.preventDefault()):(be=pe&&pe.apply(this,arguments),null!=be&&!be&&Z.preventDefault()),be};function Gl(Z,se,ye){let pe=Wl(Z,se);if(!pe&&ye&&Wl(ye,se)&&(pe={enumerable:!0,configurable:!0}),!pe||!pe.configurable)return;const be=Ji("on"+se+"patched");if(Z.hasOwnProperty(be)&&Z[be])return;delete pe.writable,delete pe.value;const ke=pe.get,at=pe.set,it=se.slice(2);let At=Ql[it];At||(At=Ql[it]=Ji("ON_PROPERTY"+it)),pe.set=function(Lt){let pt=this;!pt&&Z===gn&&(pt=gn),pt&&("function"==typeof pt[At]&&pt.removeEventListener(it,Wh),at&&at.call(pt,null),pt[At]=Lt,"function"==typeof Lt&&pt.addEventListener(it,Wh,!1))},pe.get=function(){let Lt=this;if(!Lt&&Z===gn&&(Lt=gn),!Lt)return null;const pt=Lt[At];if(pt)return pt;if(ke){let Di=ke.call(this);if(Di)return pe.set.call(this,Di),"function"==typeof Lt[pm]&&Lt.removeAttribute(se),Di}return null},Ud(Z,se,pe),Z[be]=!0}function cp(Z,se,ye){if(se)for(let pe=0;pefunction(at,it){const At=ye(at,it);return At.cbIdx>=0&&"function"==typeof it[At.cbIdx]?fm(At.name,it[At.cbIdx],At,be):ke.apply(at,it)})}function Ia(Z,se){Z[Ji("OriginalDelegate")]=se}let vb=!1,Xd=!1;function mb(){if(vb)return Xd;vb=!0;try{const Z=jh.navigator.userAgent;(-1!==Z.indexOf("MSIE ")||-1!==Z.indexOf("Trident/")||-1!==Z.indexOf("Edge/"))&&(Xd=!0)}catch{}return Xd}Zone.__load_patch("ZoneAwarePromise",(Z,se,ye)=>{const pe=Object.getOwnPropertyDescriptor,be=Object.defineProperty,at=ye.symbol,it=[],At=!1!==Z[at("DISABLE_WRAPPING_UNCAUGHT_PROMISE_REJECTION")],Lt=at("Promise"),pt=at("then"),Di="__creationTrace__";ye.onUnhandledError=Ue=>{if(ye.showUncaughtError()){const He=Ue&&Ue.rejection;He?console.error("Unhandled Promise rejection:",He instanceof Error?He.message:He,"; Zone:",Ue.zone.name,"; Task:",Ue.task&&Ue.task.source,"; Value:",He,He instanceof Error?He.stack:void 0):console.error(Ue)}},ye.microtaskDrainDone=()=>{for(;it.length;){const Ue=it.shift();try{Ue.zone.runGuarded(()=>{throw Ue.throwOriginal?Ue.rejection:Ue})}catch(He){mi(He)}}};const ni=at("unhandledPromiseRejectionHandler");function mi(Ue){ye.onUnhandledError(Ue);try{const He=se[ni];"function"==typeof He&&He.call(this,Ue)}catch{}}function dr(Ue){return Ue&&Ue.then}function ki(Ue){return Ue}function is(Ue){return F.reject(Ue)}const Pr=at("state"),Wt=at("value"),ct=at("finally"),jn=at("parentPromiseValue"),sr=at("parentPromiseState"),Zr="Promise.then",Pi=null,lt=!0,ur=!1,et=0;function yi(Ue,He){return ge=>{try{cn(Ue,He,ge)}catch(We){cn(Ue,!1,We)}}}const Pt=function(){let Ue=!1;return function(ge){return function(){Ue||(Ue=!0,ge.apply(null,arguments))}}},rs="Promise resolved with itself",_o=at("currentTaskTrace");function cn(Ue,He,ge){const We=Pt();if(Ue===ge)throw new TypeError(rs);if(Ue[Pr]===Pi){let wt=null;try{("object"==typeof ge||"function"==typeof ge)&&(wt=ge&&ge.then)}catch(Xe){return We(()=>{cn(Ue,!1,Xe)})(),Ue}if(He!==ur&&ge instanceof F&&ge.hasOwnProperty(Pr)&&ge.hasOwnProperty(Wt)&&ge[Pr]!==Pi)Do(ge),cn(Ue,ge[Pr],ge[Wt]);else if(He!==ur&&"function"==typeof wt)try{wt.call(ge,We(yi(Ue,He)),We(yi(Ue,!1)))}catch(Xe){We(()=>{cn(Ue,!1,Xe)})()}else{Ue[Pr]=He;const Xe=Ue[Wt];if(Ue[Wt]=ge,Ue[ct]===ct&&He===lt&&(Ue[Pr]=Ue[sr],Ue[Wt]=Ue[jn]),He===ur&&ge instanceof Error){const mt=se.currentTask&&se.currentTask.data&&se.currentTask.data[Di];mt&&be(ge,_o,{configurable:!0,enumerable:!1,writable:!0,value:mt})}for(let mt=0;mt{try{const dt=Ue[Wt],qt=!!ge&&ct===ge[ct];qt&&(ge[jn]=dt,ge[sr]=Xe);const li=He.run(mt,void 0,qt&&mt!==is&&mt!==ki?[]:[dt]);cn(ge,!0,li)}catch(dt){cn(ge,!1,dt)}},ge)}const zi=function(){},ht=Z.AggregateError;class F{static toString(){return"function ZoneAwarePromise() { [native code] }"}static resolve(He){return He instanceof F?He:cn(new this(null),lt,He)}static reject(He){return cn(new this(null),ur,He)}static withResolvers(){const He={};return He.promise=new F((ge,We)=>{He.resolve=ge,He.reject=We}),He}static any(He){if(!He||"function"!=typeof He[Symbol.iterator])return Promise.reject(new ht([],"All promises were rejected"));const ge=[];let We=0;try{for(let mt of He)We++,ge.push(F.resolve(mt))}catch{return Promise.reject(new ht([],"All promises were rejected"))}if(0===We)return Promise.reject(new ht([],"All promises were rejected"));let wt=!1;const Xe=[];return new F((mt,dt)=>{for(let qt=0;qt{wt||(wt=!0,mt(li))},li=>{Xe.push(li),We--,0===We&&(wt=!0,dt(new ht(Xe,"All promises were rejected")))})})}static race(He){let ge,We,wt=new this((dt,qt)=>{ge=dt,We=qt});function Xe(dt){ge(dt)}function mt(dt){We(dt)}for(let dt of He)dr(dt)||(dt=this.resolve(dt)),dt.then(Xe,mt);return wt}static all(He){return F.allWithCallback(He)}static allSettled(He){return(this&&this.prototype instanceof F?this:F).allWithCallback(He,{thenCallback:We=>({status:"fulfilled",value:We}),errorCallback:We=>({status:"rejected",reason:We})})}static allWithCallback(He,ge){let We,wt,Xe=new this((li,fr)=>{We=li,wt=fr}),mt=2,dt=0;const qt=[];for(let li of He){dr(li)||(li=this.resolve(li));const fr=dt;try{li.then(ir=>{qt[fr]=ge?ge.thenCallback(ir):ir,mt--,0===mt&&We(qt)},ir=>{ge?(qt[fr]=ge.errorCallback(ir),mt--,0===mt&&We(qt)):wt(ir)})}catch(ir){wt(ir)}mt++,dt++}return mt-=2,0===mt&&We(qt),Xe}constructor(He){const ge=this;if(!(ge instanceof F))throw new Error("Must be an instanceof Promise.");ge[Pr]=Pi,ge[Wt]=[];try{const We=Pt();He&&He(We(yi(ge,lt)),We(yi(ge,ur)))}catch(We){cn(ge,!1,We)}}get[Symbol.toStringTag](){return"Promise"}get[Symbol.species](){return F}then(He,ge){let We=this.constructor?.[Symbol.species];(!We||"function"!=typeof We)&&(We=this.constructor||F);const wt=new We(zi),Xe=se.current;return this[Pr]==Pi?this[Wt].push(Xe,wt,He,ge):Ls(this,Xe,wt,He,ge),wt}catch(He){return this.then(null,He)}finally(He){let ge=this.constructor?.[Symbol.species];(!ge||"function"!=typeof ge)&&(ge=F);const We=new ge(zi);We[ct]=ct;const wt=se.current;return this[Pr]==Pi?this[Wt].push(wt,We,He,He):Ls(this,wt,We,He,He),We}}F.resolve=F.resolve,F.reject=F.reject,F.race=F.race,F.all=F.all;const ae=Z[Lt]=Z.Promise;Z.Promise=F;const Et=at("thenPatched");function Xt(Ue){const He=Ue.prototype,ge=pe(He,"then");if(ge&&(!1===ge.writable||!ge.configurable))return;const We=He.then;He[pt]=We,Ue.prototype.then=function(wt,Xe){return new F((dt,qt)=>{We.call(this,dt,qt)}).then(wt,Xe)},Ue[Et]=!0}return ye.patchThen=Xt,ae&&(Xt(ae),tl(Z,"fetch",Ue=>function Vn(Ue){return function(He,ge){let We=Ue.apply(He,ge);if(We instanceof F)return We;let wt=We.constructor;return wt[Et]||Xt(wt),We}}(Ue))),Promise[se.__symbol__("uncaughtPromiseErrors")]=it,F}),Zone.__load_patch("toString",Z=>{const se=Function.prototype.toString,ye=Ji("OriginalDelegate"),pe=Ji("Promise"),be=Ji("Error"),ke=function(){if("function"==typeof this){const Lt=this[ye];if(Lt)return"function"==typeof Lt?se.call(Lt):Object.prototype.toString.call(Lt);if(this===Promise){const pt=Z[pe];if(pt)return se.call(pt)}if(this===Error){const pt=Z[be];if(pt)return se.call(pt)}}return se.call(this)};ke[ye]=se,Function.prototype.toString=ke;const at=Object.prototype.toString;Object.prototype.toString=function(){return"function"==typeof Promise&&this instanceof Promise?"[object Promise]":at.call(this)}});let il=!1;if(typeof window<"u")try{const Z=Object.defineProperty({},"passive",{get:function(){il=!0}});window.addEventListener("test",Z,Z),window.removeEventListener("test",Z,Z)}catch{il=!1}const OT={useG:!0},Co={},yb={},mm=new RegExp("^"+Wd+"(\\w+)(true|false)$"),Sb=Ji("propagationStopped");function ym(Z,se){const ye=(se?se(Z):Z)+Wi,pe=(se?se(Z):Z)+Ts,be=Wd+ye,ke=Wd+pe;Co[Z]={},Co[Z][Wi]=be,Co[Z][Ts]=ke}function Ib(Z,se,ye,pe){const be=pe&&pe.add||um,ke=pe&&pe.rm||$r,at=pe&&pe.listeners||"eventListeners",it=pe&&pe.rmAll||"removeAllListeners",At=Ji(be),Lt="."+be+":",pt="prependListener",Di="."+pt+":",ni=function(Wt,ct,jn){if(Wt.isRemoved)return;const sr=Wt.callback;let Zr;"object"==typeof sr&&sr.handleEvent&&(Wt.callback=lt=>sr.handleEvent(lt),Wt.originalDelegate=sr);try{Wt.invoke(Wt,ct,[jn])}catch(lt){Zr=lt}const Pi=Wt.options;return Pi&&"object"==typeof Pi&&Pi.once&&ct[ke].call(ct,jn.type,Wt.originalDelegate?Wt.originalDelegate:Wt.callback,Pi),Zr};function mi(Wt,ct,jn){if(!(ct=ct||Z.event))return;const sr=Wt||ct.target||Z,Zr=sr[Co[ct.type][jn?Ts:Wi]];if(Zr){const Pi=[];if(1===Zr.length){const lt=ni(Zr[0],sr,ct);lt&&Pi.push(lt)}else{const lt=Zr.slice();for(let ur=0;ur{throw ur})}}}const dr=function(Wt){return mi(this,Wt,!1)},ki=function(Wt){return mi(this,Wt,!0)};function is(Wt,ct){if(!Wt)return!1;let jn=!0;ct&&void 0!==ct.useG&&(jn=ct.useG);const sr=ct&&ct.vh;let Zr=!0;ct&&void 0!==ct.chkDup&&(Zr=ct.chkDup);let Pi=!1;ct&&void 0!==ct.rt&&(Pi=ct.rt);let lt=Wt;for(;lt&&!lt.hasOwnProperty(be);)lt=jd(lt);if(!lt&&Wt[be]&&(lt=Wt),!lt||lt[At])return!1;const ur=ct&&ct.eventNameToString,et={},yi=lt[At]=lt[be],Pt=lt[Ji(ke)]=lt[ke],rs=lt[Ji(at)]=lt[at],_o=lt[Ji(it)]=lt[it];let cn;ct&&ct.prepend&&(cn=lt[Ji(ct.prepend)]=lt[ct.prepend]);const F=jn?function(ge){if(!et.isExisting)return yi.call(et.target,et.eventName,et.capture?ki:dr,et.options)}:function(ge){return yi.call(et.target,et.eventName,ge.invoke,et.options)},ae=jn?function(ge){if(!ge.isRemoved){const We=Co[ge.eventName];let wt;We&&(wt=We[ge.capture?Ts:Wi]);const Xe=wt&&ge.target[wt];if(Xe)for(let mt=0;mt{Vo.zone.cancelTask(Vo)},{once:!0})),et.target=null,Fc&&(Fc.taskData=null),$d&&(Tn.once=!0),!il&&"boolean"==typeof Vo.options||(Vo.options=Tn),Vo.target=qt,Vo.capture=Zl,Vo.eventName=li,ir&&(Vo.originalDelegate=fr),dt?jo.unshift(Vo):jo.push(Vo),mt?qt:void 0}};return lt[be]=He(yi,Lt,F,ae,Pi),cn&&(lt[pt]=He(cn,Di,function(ge){return cn.call(et.target,et.eventName,ge.invoke,et.options)},ae,Pi,!0)),lt[ke]=function(){const ge=this||Z;let We=arguments[0];ct&&ct.transferEventName&&(We=ct.transferEventName(We));const wt=arguments[2],Xe=!!wt&&("boolean"==typeof wt||wt.capture),mt=arguments[1];if(!mt)return Pt.apply(this,arguments);if(sr&&!sr(Pt,mt,ge,arguments))return;const dt=Co[We];let qt;dt&&(qt=dt[Xe?Ts:Wi]);const li=qt&&ge[qt];if(li)for(let fr=0;frfunction(be,ke){be[Sb]=!0,pe&&pe.apply(be,ke)})}function Mb(Z,se,ye,pe,be){const ke=Zone.__symbol__(pe);if(se[ke])return;const at=se[ke]=se[pe];se[pe]=function(it,At,Lt){return At&&At.prototype&&be.forEach(function(pt){const Di=`${ye}.${pe}::`+pt,ni=At.prototype;try{if(ni.hasOwnProperty(pt)){const mi=Z.ObjectGetOwnPropertyDescriptor(ni,pt);mi&&mi.value?(mi.value=Z.wrapWithCurrentZone(mi.value,Di),Z._redefineProperty(At.prototype,pt,mi)):ni[pt]&&(ni[pt]=Z.wrapWithCurrentZone(ni[pt],Di))}else ni[pt]&&(ni[pt]=Z.wrapWithCurrentZone(ni[pt],Di))}catch{}}),at.call(se,it,At,Lt)},Z.attachOriginToPatched(se[pe],at)}function wb(Z,se,ye){if(!ye||0===ye.length)return se;const pe=ye.filter(ke=>ke.target===Z);if(!pe||0===pe.length)return se;const be=pe[0].ignoreProperties;return se.filter(ke=>-1===be.indexOf(ke))}function Eo(Z,se,ye,pe){Z&&cp(Z,wb(Z,se,ye),pe)}function qd(Z){return Object.getOwnPropertyNames(Z).filter(se=>se.startsWith("on")&&se.length>2).map(se=>se.substring(2))}Zone.__load_patch("util",(Z,se,ye)=>{const pe=qd(Z);ye.patchOnProperties=cp,ye.patchMethod=tl,ye.bindArguments=Yd,ye.patchMacroTask=gb;const be=se.__symbol__("BLACK_LISTED_EVENTS"),ke=se.__symbol__("UNPATCHED_EVENTS");Z[ke]&&(Z[be]=Z[ke]),Z[be]&&(se[be]=se[ke]=Z[be]),ye.patchEventPrototype=Sm,ye.patchEventTarget=Ib,ye.isIEOrEdge=mb,ye.ObjectDefineProperty=Ud,ye.ObjectGetOwnPropertyDescriptor=Wl,ye.ObjectCreate=Vd,ye.ArraySlice=pb,ye.patchClass=Gd,ye.wrapWithCurrentZone=op,ye.filterProperties=wb,ye.attachOriginToPatched=Ia,ye._redefineProperty=Object.defineProperty,ye.patchCallbacks=Mb,ye.getGlobalObjects=()=>({globalSources:yb,zoneSymbolEventNames:Co,eventNames:pe,isBrowser:Qd,isMix:hp,isNode:Vh,TRUE_STR:Ts,FALSE_STR:Wi,ZONE_SYMBOL_PREFIX:Wd,ADD_EVENT_LISTENER_STR:um,REMOVE_EVENT_LISTENER_STR:$r})});const As=Ji("zoneTask");function Xl(Z,se,ye,pe){let be=null,ke=null;ye+=pe;const at={};function it(Lt){const pt=Lt.data;return pt.args[0]=function(){return Lt.invoke.apply(this,arguments)},pt.handleId=be.apply(Z,pt.args),Lt}function At(Lt){return ke.call(Z,Lt.data.handleId)}be=tl(Z,se+=pe,Lt=>function(pt,Di){if("function"==typeof Di[0]){const ni={isPeriodic:"Interval"===pe,delay:"Timeout"===pe||"Interval"===pe?Di[1]||0:void 0,args:Di},mi=Di[0];Di[0]=function(){try{return mi.apply(this,arguments)}finally{ni.isPeriodic||("number"==typeof ni.handleId?delete at[ni.handleId]:ni.handleId&&(ni.handleId[As]=null))}};const dr=fm(se,Di[0],ni,it,At);if(!dr)return dr;const ki=dr.data.handleId;return"number"==typeof ki?at[ki]=dr:ki&&(ki[As]=dr),ki&&ki.ref&&ki.unref&&"function"==typeof ki.ref&&"function"==typeof ki.unref&&(dr.ref=ki.ref.bind(ki),dr.unref=ki.unref.bind(ki)),"number"==typeof ki||ki?ki:dr}return Lt.apply(Z,Di)}),ke=tl(Z,ye,Lt=>function(pt,Di){const ni=Di[0];let mi;"number"==typeof ni?mi=at[ni]:(mi=ni&&ni[As],mi||(mi=ni)),mi&&"string"==typeof mi.type?"notScheduled"!==mi.state&&(mi.cancelFn&&mi.data.isPeriodic||0===mi.runCount)&&("number"==typeof ni?delete at[ni]:ni&&(ni[As]=null),mi.zone.cancelTask(mi)):Lt.apply(Z,Di)})}Zone.__load_patch("legacy",Z=>{const se=Z[Zone.__symbol__("legacyPatch")];se&&se()}),Zone.__load_patch("timers",Z=>{const ye="clear";Xl(Z,"set",ye,"Timeout"),Xl(Z,"set",ye,"Interval"),Xl(Z,"set",ye,"Immediate")}),Zone.__load_patch("requestAnimationFrame",Z=>{Xl(Z,"request","cancel","AnimationFrame"),Xl(Z,"mozRequest","mozCancel","AnimationFrame"),Xl(Z,"webkitRequest","webkitCancel","AnimationFrame")}),Zone.__load_patch("blocking",(Z,se)=>{const ye=["alert","prompt","confirm"];for(let pe=0;pefunction(At,Lt){return se.current.run(ke,Z,Lt,it)})}),Zone.__load_patch("EventTarget",(Z,se,ye)=>{(function ql(Z,se){se.patchEventPrototype(Z,se)})(Z,ye),function bm(Z,se){if(Zone[se.symbol("patchEventTarget")])return;const{eventNames:ye,zoneSymbolEventNames:pe,TRUE_STR:be,FALSE_STR:ke,ZONE_SYMBOL_PREFIX:at}=se.getGlobalObjects();for(let At=0;At{Gd("MutationObserver"),Gd("WebKitMutationObserver")}),Zone.__load_patch("IntersectionObserver",(Z,se,ye)=>{Gd("IntersectionObserver")}),Zone.__load_patch("FileReader",(Z,se,ye)=>{Gd("FileReader")}),Zone.__load_patch("on_property",(Z,se,ye)=>{!function dp(Z,se){if(Vh&&!hp||Zone[Z.symbol("patchEvents")])return;const ye=se.__Zone_ignore_on_properties;let pe=[];if(Qd){const be=window;pe=pe.concat(["Document","SVGElement","Element","HTMLElement","HTMLBodyElement","HTMLMediaElement","HTMLFrameSetElement","HTMLFrameElement","HTMLIFrameElement","HTMLMarqueeElement","Worker"]);const ke=function vm(){try{const Z=jh.navigator.userAgent;if(-1!==Z.indexOf("MSIE ")||-1!==Z.indexOf("Trident/"))return!0}catch{}return!1}()?[{target:be,ignoreProperties:["error"]}]:[];Eo(be,qd(be),ye&&ye.concat(ke),jd(be))}pe=pe.concat(["XMLHttpRequest","XMLHttpRequestEventTarget","IDBIndex","IDBRequest","IDBOpenDBRequest","IDBDatabase","IDBTransaction","IDBCursor","WebSocket"]);for(let be=0;be{!function Im(Z,se){const{isBrowser:ye,isMix:pe}=se.getGlobalObjects();(ye||pe)&&Z.customElements&&"customElements"in Z&&se.patchCallbacks(se,Z.customElements,"customElements","define",["connectedCallback","disconnectedCallback","adoptedCallback","attributeChangedCallback"])}(Z,ye)}),Zone.__load_patch("XHR",(Z,se)=>{!function At(Lt){const pt=Lt.XMLHttpRequest;if(!pt)return;const Di=pt.prototype;let mi=Di[Yl],dr=Di[_h];if(!mi){const et=Lt.XMLHttpRequestEventTarget;if(et){const yi=et.prototype;mi=yi[Yl],dr=yi[_h]}}const ki="readystatechange",is="scheduled";function Pr(et){const yi=et.data,Pt=yi.target;Pt[ke]=!1,Pt[it]=!1;const rs=Pt[be];mi||(mi=Pt[Yl],dr=Pt[_h]),rs&&dr.call(Pt,ki,rs);const _o=Pt[be]=()=>{if(Pt.readyState===Pt.DONE)if(!yi.aborted&&Pt[ke]&&et.state===is){const Ur=Pt[se.__symbol__("loadfalse")];if(0!==Pt.status&&Ur&&Ur.length>0){const Do=et.invoke;et.invoke=function(){const Ls=Pt[se.__symbol__("loadfalse")];for(let jr=0;jrfunction(et,yi){return et[pe]=0==yi[2],et[at]=yi[1],jn.apply(et,yi)}),Zr=Ji("fetchTaskAborting"),Pi=Ji("fetchTaskScheduling"),lt=tl(Di,"send",()=>function(et,yi){if(!0===se.current[Pi]||et[pe])return lt.apply(et,yi);{const Pt={target:et,url:et[at],isPeriodic:!1,args:yi,aborted:!1},rs=fm("XMLHttpRequest.send",Wt,Pt,Pr,ct);et&&!0===et[it]&&!Pt.aborted&&rs.state===is&&rs.invoke()}}),ur=tl(Di,"abort",()=>function(et,yi){const Pt=function ni(et){return et[ye]}(et);if(Pt&&"string"==typeof Pt.type){if(null==Pt.cancelFn||Pt.data&&Pt.data.aborted)return;Pt.zone.cancelTask(Pt)}else if(!0===se.current[Zr])return ur.apply(et,yi)})}(Z);const ye=Ji("xhrTask"),pe=Ji("xhrSync"),be=Ji("xhrListener"),ke=Ji("xhrScheduled"),at=Ji("xhrURL"),it=Ji("xhrErrorBeforeScheduled")}),Zone.__load_patch("geolocation",Z=>{Z.navigator&&Z.navigator.geolocation&&function gm(Z,se){const ye=Z.constructor.name;for(let pe=0;pe{const At=function(){return it.apply(this,Yd(arguments,ye+"."+be))};return Ia(At,it),At})(ke)}}}(Z.navigator.geolocation,["getCurrentPosition","watchPosition"])}),Zone.__load_patch("PromiseRejectionEvent",(Z,se)=>{function ye(pe){return function(be){bb(Z,pe).forEach(at=>{const it=Z.PromiseRejectionEvent;if(it){const At=new it(pe,{promise:be.promise,reason:be.rejection});at.invoke(At)}})}}Z.PromiseRejectionEvent&&(se[Ji("unhandledPromiseRejectionHandler")]=ye("unhandledrejection"),se[Ji("rejectionHandledHandler")]=ye("rejectionhandled"))}),Zone.__load_patch("queueMicrotask",(Z,se,ye)=>{!function up(Z,se){se.patchMethod(Z,"queueMicrotask",ye=>function(pe,be){Zone.current.scheduleMicroTask("queueMicrotask",be[0])})}(Z,ye)})}},Wl=>{Wl(Wl.s=51)}]); \ No newline at end of file diff --git a/ej2-angular/samples/diagram/nodes/node-expandAndCollapse-cs1/main.55bf572d1a73b49c.js b/ej2-angular/samples/diagram/nodes/node-expandAndCollapse-cs1/main.55bf572d1a73b49c.js deleted file mode 100644 index c34f0fbe91..0000000000 --- a/ej2-angular/samples/diagram/nodes/node-expandAndCollapse-cs1/main.55bf572d1a73b49c.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";(self.webpackChunksyncfusion_component=self.webpackChunksyncfusion_component||[]).push([[179],{51:(_l,_d,Ud)=>{let $r=null,Fh=1;const Ts=Symbol("SIGNAL");function Wi(n){const t=$r;return $r=n,t}function gn(n){if((!Vh(n)||n.dirty)&&(n.dirty||n.lastCleanEpoch!==Fh)){if(!n.producerMustRecompute(n)&&!jh(n))return n.dirty=!1,void(n.lastCleanEpoch=Fh);n.producerRecomputeValue(n),n.dirty=!1,n.lastCleanEpoch=Fh}}function jh(n){Vl(n);for(let t=0;t0}function Vl(n){n.producerNode??=[],n.producerIndexOfThis??=[],n.producerLastReadVersion??=[]}let Gd=null;function Eo(n){return"function"==typeof n}function Xd(n){const e=n(i=>{Error.call(i),i.stack=(new Error).stack});return e.prototype=Object.create(Error.prototype),e.prototype.constructor=e,e}const df=Xd(n=>function(e){n(this),this.message=e?`${e.length} errors occurred during unsubscription:\n${e.map((i,r)=>`${r+1}) ${i.toString()}`).join("\n ")}`:"",this.name="UnsubscriptionError",this.errors=e});function uf(n,t){if(n){const e=n.indexOf(t);0<=e&&n.splice(e,1)}}class As{constructor(t){this.initialTeardown=t,this.closed=!1,this._parentage=null,this._finalizers=null}unsubscribe(){let t;if(!this.closed){this.closed=!0;const{_parentage:e}=this;if(e)if(this._parentage=null,Array.isArray(e))for(const s of e)s.remove(this);else e.remove(this);const{initialTeardown:i}=this;if(Eo(i))try{i()}catch(s){t=s instanceof df?s.errors:[s]}const{_finalizers:r}=this;if(r){this._finalizers=null;for(const s of r)try{Im(s)}catch(o){t=t??[],o instanceof df?t=[...t,...o.errors]:t.push(o)}}if(t)throw new df(t)}}add(t){var e;if(t&&t!==this)if(this.closed)Im(t);else{if(t instanceof As){if(t.closed||t._hasParent(this))return;t._addParent(this)}(this._finalizers=null!==(e=this._finalizers)&&void 0!==e?e:[]).push(t)}}_hasParent(t){const{_parentage:e}=this;return e===t||Array.isArray(e)&&e.includes(t)}_addParent(t){const{_parentage:e}=this;this._parentage=Array.isArray(e)?(e.push(t),e):e?[e,t]:t}_removeParent(t){const{_parentage:e}=this;e===t?this._parentage=null:Array.isArray(e)&&uf(e,t)}remove(t){const{_finalizers:e}=this;e&&uf(e,t),t instanceof As&&t._removeParent(this)}}As.EMPTY=(()=>{const n=new As;return n.closed=!0,n})();const Wl=As.EMPTY;function Sm(n){return n instanceof As||n&&"closed"in n&&Eo(n.remove)&&Eo(n.add)&&Eo(n.unsubscribe)}function Im(n){Eo(n)?n():n.unsubscribe()}const Yl={onUnhandledError:null,onStoppedNotification:null,Promise:void 0,useDeprecatedSynchronousErrorHandling:!1,useDeprecatedNextContext:!1},Z={setTimeout(n,t,...e){const{delegate:i}=Z;return i?.setTimeout?i.setTimeout(n,t,...e):setTimeout(n,t,...e)},clearTimeout(n){const{delegate:t}=Z;return(t?.clearTimeout||clearTimeout)(n)},delegate:void 0};function ye(){}const fe=at("C",void 0,void 0);function at(n,t,e){return{kind:n,value:t,error:e}}let tt=null;function At(n){if(Yl.useDeprecatedSynchronousErrorHandling){const t=!tt;if(t&&(tt={errorThrown:!1,error:null}),n(),t){const{errorThrown:e,error:i}=tt;if(tt=null,e)throw i}}else n()}class ft extends As{constructor(t){super(),this.isStopped=!1,t?(this.destination=t,Sm(t)&&t.add(this)):this.destination=Wt}static create(t,e,i){return new dr(t,e,i)}next(t){this.isStopped?kr(function ke(n){return at("N",n,void 0)}(t),this):this._next(t)}error(t){this.isStopped?kr(function be(n){return at("E",void 0,n)}(t),this):(this.isStopped=!0,this._error(t))}complete(){this.isStopped?kr(fe,this):(this.isStopped=!0,this._complete())}unsubscribe(){this.closed||(this.isStopped=!0,super.unsubscribe(),this.destination=null)}_next(t){this.destination.next(t)}_error(t){try{this.destination.error(t)}finally{this.unsubscribe()}}_complete(){try{this.destination.complete()}finally{this.unsubscribe()}}}const Ei=Function.prototype.bind;function ti(n,t){return Ei.call(n,t)}class gi{constructor(t){this.partialObserver=t}next(t){const{partialObserver:e}=this;if(e.next)try{e.next(t)}catch(i){Oi(i)}}error(t){const{partialObserver:e}=this;if(e.error)try{e.error(t)}catch(i){Oi(i)}else Oi(t)}complete(){const{partialObserver:t}=this;if(t.complete)try{t.complete()}catch(e){Oi(e)}}}class dr extends ft{constructor(t,e,i){let r;if(super(),Eo(t)||!t)r={next:t??void 0,error:e??void 0,complete:i??void 0};else{let s;this&&Yl.useDeprecatedNextContext?(s=Object.create(t),s.unsubscribe=()=>this.unsubscribe(),r={next:t.next&&ti(t.next,s),error:t.error&&ti(t.error,s),complete:t.complete&&ti(t.complete,s)}):r=t}this.destination=new gi(r)}}function Oi(n){Yl.useDeprecatedSynchronousErrorHandling?function Lt(n){Yl.useDeprecatedSynchronousErrorHandling&&tt&&(tt.errorThrown=!0,tt.error=n)}(n):function se(n){Z.setTimeout(()=>{const{onUnhandledError:t}=Yl;if(!t)throw n;t(n)})}(n)}function kr(n,t){const{onStoppedNotification:e}=Yl;e&&Z.setTimeout(()=>e(n,t))}const Wt={closed:!0,next:ye,error:function es(n){throw n},complete:ye},ct="function"==typeof Symbol&&Symbol.observable||"@@observable";function _n(n){return n}let ki=(()=>{class n{constructor(e){e&&(this._subscribe=e)}lift(e){const i=new n;return i.source=this,i.operator=e,i}subscribe(e,i,r){const s=function et(n){return n&&n instanceof ft||function ur(n){return n&&Eo(n.next)&&Eo(n.error)&&Eo(n.complete)}(n)&&Sm(n)}(e)?e:new dr(e,i,r);return At(()=>{const{operator:o,source:a}=this;s.add(o?o.call(s,a):a?this._subscribe(s):this._trySubscribe(s))}),s}_trySubscribe(e){try{return this._subscribe(e)}catch(i){e.error(i)}}forEach(e,i){return new(i=lt(i))((r,s)=>{const o=new dr({next:a=>{try{e(a)}catch(l){s(l),o.unsubscribe()}},error:s,complete:r});this.subscribe(o)})}_subscribe(e){var i;return null===(i=this.source)||void 0===i?void 0:i.subscribe(e)}[ct](){return this}pipe(...e){return function Zr(n){return 0===n.length?_n:1===n.length?n[0]:function(e){return n.reduce((i,r)=>r(i),e)}}(e)(this)}toPromise(e){return new(e=lt(e))((i,r)=>{let s;this.subscribe(o=>s=o,o=>r(o),()=>i(s))})}}return n.create=t=>new n(t),n})();function lt(n){var t;return null!==(t=n??Yl.Promise)&&void 0!==t?t:Promise}const vi=Xd(n=>function(){n(this),this.name="ObjectUnsubscribedError",this.message="object unsubscribed"});let Pt=(()=>{class n extends ki{constructor(){super(),this.closed=!1,this.currentObservers=null,this.observers=[],this.isStopped=!1,this.hasError=!1,this.thrownError=null}lift(e){const i=new ts(this,this);return i.operator=e,i}_throwIfClosed(){if(this.closed)throw new vi}next(e){At(()=>{if(this._throwIfClosed(),!this.isStopped){this.currentObservers||(this.currentObservers=Array.from(this.observers));for(const i of this.currentObservers)i.next(e)}})}error(e){At(()=>{if(this._throwIfClosed(),!this.isStopped){this.hasError=this.isStopped=!0,this.thrownError=e;const{observers:i}=this;for(;i.length;)i.shift().error(e)}})}complete(){At(()=>{if(this._throwIfClosed(),!this.isStopped){this.isStopped=!0;const{observers:e}=this;for(;e.length;)e.shift().complete()}})}unsubscribe(){this.isStopped=this.closed=!0,this.observers=this.currentObservers=null}get observed(){var e;return(null===(e=this.observers)||void 0===e?void 0:e.length)>0}_trySubscribe(e){return this._throwIfClosed(),super._trySubscribe(e)}_subscribe(e){return this._throwIfClosed(),this._checkFinalizedStatuses(e),this._innerSubscribe(e)}_innerSubscribe(e){const{hasError:i,isStopped:r,observers:s}=this;return i||r?Wl:(this.currentObservers=null,s.push(e),new As(()=>{this.currentObservers=null,uf(s,e)}))}_checkFinalizedStatuses(e){const{hasError:i,thrownError:r,isStopped:s}=this;i?e.error(r):s&&e.complete()}asObservable(){const e=new ki;return e.source=this,e}}return n.create=(t,e)=>new ts(t,e),n})();class ts extends Pt{constructor(t,e){super(),this.destination=t,this.source=e}next(t){var e,i;null===(i=null===(e=this.destination)||void 0===e?void 0:e.next)||void 0===i||i.call(e,t)}error(t){var e,i;null===(i=null===(e=this.destination)||void 0===e?void 0:e.error)||void 0===i||i.call(e,t)}complete(){var t,e;null===(e=null===(t=this.destination)||void 0===t?void 0:t.complete)||void 0===e||e.call(t)}_subscribe(t){var e,i;return null!==(i=null===(e=this.source)||void 0===e?void 0:e.subscribe(t))&&void 0!==i?i:Wl}}class _o extends Pt{constructor(t){super(),this._value=t}get value(){return this.getValue()}_subscribe(t){const e=super._subscribe(t);return!e.closed&&t.next(this._value),e}getValue(){const{hasError:t,thrownError:e,_value:i}=this;if(t)throw e;return this._throwIfClosed(),i}next(t){super.next(this._value=t)}}class Ls extends ft{constructor(t,e,i,r,s,o){super(t),this.onFinalize=s,this.shouldUnsubscribe=o,this._next=e?function(a){try{e(a)}catch(l){t.error(l)}}:super._next,this._error=r?function(a){try{r(a)}catch(l){t.error(l)}finally{this.unsubscribe()}}:super._error,this._complete=i?function(){try{i()}catch(a){t.error(a)}finally{this.unsubscribe()}}:super._complete}unsubscribe(){var t;if(!this.shouldUnsubscribe||this.shouldUnsubscribe()){const{closed:e}=this;super.unsubscribe(),!e&&(null===(t=this.onFinalize)||void 0===t||t.call(this))}}}function jr(n,t){return function Ur(n){return t=>{if(function cn(n){return Eo(n?.lift)}(t))return t.lift(function(e){try{return n(e,this)}catch(i){this.error(i)}});throw new TypeError("Unable to lift unknown Observable type")}}((e,i)=>{let r=0;e.subscribe(function Do(n,t,e,i,r){return new Ls(n,t,e,i,r)}(i,s=>{i.next(n.call(t,s,r++))}))})}class F extends Error{constructor(t,e){super(function ae(n,t){return`NG0${Math.abs(n)}${t?": "+t:""}`}(t,e)),this.code=t}}function Xe(n){for(let t in n)if(n[t]===Xe)return t;throw Error("Could not find renamed property on target object.")}function mt(n,t){for(const e in t)t.hasOwnProperty(e)&&!n.hasOwnProperty(e)&&(n[e]=t[e])}function dt(n){if("string"==typeof n)return n;if(Array.isArray(n))return"["+n.map(dt).join(", ")+"]";if(null==n)return""+n;if(n.overriddenName)return`${n.overriddenName}`;if(n.name)return`${n.name}`;const t=n.toString();if(null==t)return""+t;const e=t.indexOf("\n");return-1===e?t:t.substring(0,e)}function qt(n,t){return null==n||""===n?null===t?"":t:null==t||""===t?n:n+" "+t}const pr=Xe({__forward_ref__:Xe});function ir(n){return n.__forward_ref__=ir,n.toString=function(){return dt(this())},n}function vt(n){return function Dn(n){return"function"==typeof n&&n.hasOwnProperty(pr)&&n.__forward_ref__===ir}(n)?n():n}function Ql(n){return n&&!!n.\u0275providers}const Gl=Xe({\u0275cmp:Xe}),qd=Xe({\u0275dir:Xe}),pf=Xe({\u0275pipe:Xe}),Uo=Xe({\u0275fac:Xe}),jo=Xe({__NG_ELEMENT_ID__:Xe}),ff=Xe({__NG_ENV_ID__:Xe});function zi(n){return"function"==typeof n?n.name||n.toString():"object"==typeof n&&null!=n&&"function"==typeof n.type?n.type.name||n.type.toString():function Nt(n){return"string"==typeof n?n:null==n?"":String(n)}(n)}function Cb(n,t){throw new F(-201,!1)}function ro(n,t){null==n&&function zt(n,t,e,i){throw new Error(`ASSERTION ERROR: ${n}`+(null==i?"":` [Expected=> ${e} ${i} ${t} <=Actual]`))}(t,n,null,"!=")}function Yi(n){return{token:n.token,providedIn:n.providedIn||null,factory:n.factory,value:void 0}}function gf(n){return{providers:n.providers||[],imports:n.imports||[]}}function bm(n){return kT(n,wm)||kT(n,PT)}function kT(n,t){return n.hasOwnProperty(t)?n[t]:null}function Mm(n){return n&&(n.hasOwnProperty(Eb)||n.hasOwnProperty(b_))?n[Eb]:null}const wm=Xe({\u0275prov:Xe}),Eb=Xe({\u0275inj:Xe}),PT=Xe({ngInjectableDef:Xe}),b_=Xe({ngInjectorDef:Xe});var Di=function(n){return n[n.Default=0]="Default",n[n.Host=1]="Host",n[n.Self=2]="Self",n[n.SkipSelf=4]="SkipSelf",n[n.Optional=8]="Optional",n}(Di||{});let Db;function no(n){const t=Db;return Db=n,t}function RT(n,t,e){const i=bm(n);return i&&"root"==i.providedIn?void 0===i.value?i.value=i.factory():i.value:e&Di.Optional?null:void 0!==t?t:void Cb()}const rr=globalThis;class Ht{constructor(t,e){this._desc=t,this.ngMetadataName="InjectionToken",this.\u0275prov=void 0,"number"==typeof e?this.__NG_ELEMENT_ID__=e:void 0!==e&&(this.\u0275prov=Yi({token:this,providedIn:e.providedIn||"root",factory:e.factory}))}get multi(){return this}toString(){return`InjectionToken ${this._desc}`}}const vf={},Nb="__NG_DI_FLAG__",Cm="ngTempTokenPath",C_=/\n/gm,BT="__source";let Zd;function Qh(n){const t=Zd;return Zd=n,t}function x_(n,t=Di.Default){if(void 0===Zd)throw new F(-203,!1);return null===Zd?RT(n,void 0,t):Zd.get(n,t&Di.Optional?null:void 0,t)}function Fi(n,t=Di.Default){return(function zT(){return Db}()||x_)(vt(n),t)}function Ri(n,t=Di.Default){return Fi(n,Em(t))}function Em(n){return typeof n>"u"||"number"==typeof n?n:0|(n.optional&&8)|(n.host&&1)|(n.self&&2)|(n.skipSelf&&4)}function Ob(n){const t=[];for(let e=0;et){o=s-1;break}}}for(;ss?"":r[d+1].toLowerCase();const p=8&i?u:null;if(p&&-1!==_T(p,h,0)||2&i&&h!==u){if(ba(i))return!1;o=!0}}}}else{if(!o&&!ba(i)&&!ba(l))return!1;if(o&&ba(l))continue;o=!1,i=l|1&i}}return ba(i)||o}function ba(n){return 0==(1&n)}function P_(n,t,e,i){if(null===t)return-1;let r=0;if(i||!e){let s=!1;for(;r-1)for(e++;e0?'="'+a+'"':"")+"]"}else 8&i?r+="."+o:4&i&&(r+=" "+o);else""!==r&&!ba(o)&&(t+=GT(s,r),r=""),i=o,s=s||!ba(i);e++}return""!==r&&(t+=GT(s,r)),t}function Pb(n){return Xl(()=>{const t=qT(n),e={...t,decls:n.decls,vars:n.vars,template:n.template,consts:n.consts||null,ngContentSelectors:n.ngContentSelectors,onPush:n.changeDetection===Dm.OnPush,directiveDefs:null,pipeDefs:null,dependencies:t.standalone&&n.dependencies||null,getStandaloneInjector:null,signals:n.signals??!1,data:n.data||{},encapsulation:n.encapsulation||Ia.Emulated,styles:n.styles||Qi,_:null,schemas:n.schemas||null,tView:null,id:""};$T(e);const i=n.dependencies;return e.directiveDefs=Tm(i,!1),e.pipeDefs=Tm(i,!0),e.id=function Y_(n){let t=0;const e=[n.selectors,n.ngContentSelectors,n.hostVars,n.hostAttrs,n.consts,n.vars,n.decls,n.encapsulation,n.standalone,n.signals,n.exportAs,JSON.stringify(n.inputs),JSON.stringify(n.outputs),Object.getOwnPropertyNames(n.type.prototype),!!n.contentQueries,!!n.viewQuery].join("|");for(const r of e)t=Math.imul(31,t)+r.charCodeAt(0)<<0;return t+=2147483648,"c"+t}(e),e})}function j_(n){return ci(n)||jn(n)}function V_(n){return null!==n}function xm(n){return Xl(()=>({type:n.type,bootstrap:n.bootstrap||Qi,declarations:n.declarations||Qi,imports:n.imports||Qi,exports:n.exports||Qi,transitiveCompileScopes:null,schemas:n.schemas||null,id:n.id||null}))}function XT(n,t){if(null==n)return tl;const e={};for(const i in n)if(n.hasOwnProperty(i)){const r=n[i];let s,o,a=Gh.None;Array.isArray(r)?(a=r[0],s=r[1],o=r[2]??s):(s=r,o=r),t?(e[s]=a!==Gh.None?[i,a]:i,t[s]=o):e[s]=i}return e}function nr(n){return Xl(()=>{const t=qT(n);return $T(t),t})}function ci(n){return n[Gl]||null}function jn(n){return n[qd]||null}function gs(n){return n[pf]||null}function qT(n){const t={};return{type:n.type,providersResolver:null,factory:null,hostBindings:n.hostBindings||null,hostVars:n.hostVars||0,hostAttrs:n.hostAttrs||null,contentQueries:n.contentQueries||null,declaredInputs:t,inputTransforms:null,inputConfig:n.inputs||tl,exportAs:n.exportAs||null,standalone:!0===n.standalone,signals:!0===n.signals,selectors:n.selectors||Qi,viewQuery:n.viewQuery||null,features:n.features||null,setInput:null,findHostDirectiveDefs:null,hostDirectives:null,inputs:XT(n.inputs,t),outputs:XT(n.outputs),debugInfo:null}}function $T(n){n.features?.forEach(t=>t(n))}function Tm(n,t){if(!n)return null;const e=t?gs:j_;return()=>("function"==typeof n?n():n).map(i=>e(i)).filter(V_)}const Vr=0,Be=1,Ct=2,vn=3,Ma=4,Os=5,wa=6,Jd=7,Er=8,Xs=9,ql=10,Yt=11,Sf=12,ZT=13,Kd=14,Jr=15,If=16,eu=17,il=18,bf=19,JT=20,Xh=21,Am=22,Uc=23,jt=25,zb=1,rl=7,tu=9,mn=10;var Rb=function(n){return n[n.None=0]="None",n[n.HasTransplantedViews=2]="HasTransplantedViews",n}(Rb||{});function ks(n){return Array.isArray(n)&&"object"==typeof n[zb]}function Ps(n){return Array.isArray(n)&&!0===n[zb]}function Hb(n){return 0!=(4&n.flags)}function jc(n){return n.componentOffset>-1}function Ca(n){return!!n.template}function Bb(n){return 0!=(512&n[Ct])}function Vc(n,t){return n.hasOwnProperty(Uo)?n[Uo]:null}class q_{constructor(t,e,i){this.previousValue=t,this.currentValue=e,this.firstChange=i}isFirstChange(){return this.firstChange}}function iA(n,t,e,i){null!==t?t.applyValueToInputSignal(t,i):n[e]=i}function rA(n){return n.type.prototype.ngOnChanges&&(n.setInput=Z_),$_}function $_(){const n=sA(this),t=n?.current;if(t){const e=n.previous;if(e===tl)n.previous=t;else for(let i in t)e[i]=t[i];n.current=null,this.ngOnChanges(t)}}function Z_(n,t,e,i,r){const s=this.declaredInputs[i],o=sA(n)||function J_(n,t){return n[nA]=t}(n,{previous:tl,current:null}),a=o.current||(o.current={}),l=o.previous,h=l[s];a[s]=new q_(h&&h.currentValue,e,l===tl),iA(n,t,r,e)}const nA="__ngSimpleChanges__";function sA(n){return n[nA]||null}const nl=function(n,t,e){};let lA=!1;function fr(n){for(;Array.isArray(n);)n=n[Vr];return n}function qs(n,t){return fr(t[n.index])}function Cf(n,t){return n.data[t]}function To(n,t){const e=t[n];return ks(e)?e:e[Vr]}function Vb(n){return 128==(128&n[Ct])}function sl(n,t){return null==t?null:n[t]}function hA(n){n[eu]=0}function nU(n){1024&n[Ct]||(n[Ct]|=1024,Vb(n)&&Ef(n))}function dA(n){return 9216&n[Ct]||n[Uc]?.dirty}function Wb(n){dA(n)?Ef(n):64&n[Ct]&&(function eU(){return lA}()?(n[Ct]|=1024,Ef(n)):n[ql].changeDetectionScheduler?.notify())}function Ef(n){n[ql].changeDetectionScheduler?.notify();let t=Wc(n);for(;null!==t&&!(8192&t[Ct])&&(t[Ct]|=8192,Vb(t));)t=Wc(t)}function Wc(n){const t=n[vn];return Ps(t)?t[vn]:t}const Rt={lFrame:bA(null),bindingsEnabled:!0,skipHydrationRootTNode:null};function pA(){return Rt.bindingsEnabled}function Se(){return Rt.lFrame.lView}function xi(){return Rt.lFrame.tView}function gr(){let n=fA();for(;null!==n&&64===n.type;)n=n.parent;return n}function fA(){return Rt.lFrame.currentTNode}function ol(n,t){const e=Rt.lFrame;e.currentTNode=n,e.isParent=t}function Qb(){return Rt.lFrame.isParent}function mU(n,t){const e=Rt.lFrame;e.bindingIndex=e.bindingRootIndex=n,Xb(t)}function Xb(n){Rt.lFrame.currentDirectiveIndex=n}function yA(){return Rt.lFrame.currentQueryIndex}function $b(n){Rt.lFrame.currentQueryIndex=n}function SU(n){const t=n[Be];return 2===t.type?t.declTNode:1===t.type?n[Os]:null}function SA(n,t,e){if(e&Di.SkipSelf){let r=t,s=n;for(;!(r=r.parent,null!==r||e&Di.Host||(r=SU(s),null===r||(s=s[Kd],10&r.type))););if(null===r)return!1;t=r,n=s}const i=Rt.lFrame=IA();return i.currentTNode=t,i.lView=n,!0}function Zb(n){const t=IA(),e=n[Be];Rt.lFrame=t,t.currentTNode=e.firstChild,t.lView=n,t.tView=e,t.contextLView=n,t.bindingIndex=e.bindingStartIndex,t.inI18n=!1}function IA(){const n=Rt.lFrame,t=null===n?null:n.child;return null===t?bA(n):t}function bA(n){const t={currentTNode:null,isParent:!0,lView:null,tView:null,selectedIndex:-1,contextLView:null,elementDepthCount:0,currentNamespace:null,currentDirectiveIndex:-1,bindingRootIndex:-1,bindingIndex:-1,currentQueryIndex:0,parent:n,child:null,inI18n:!1};return null!==n&&(n.child=t),t}function MA(){const n=Rt.lFrame;return Rt.lFrame=n.parent,n.currentTNode=null,n.lView=null,n}const wA=MA;function Jb(){const n=MA();n.isParent=!0,n.tView=null,n.selectedIndex=-1,n.contextLView=null,n.elementDepthCount=0,n.currentDirectiveIndex=-1,n.currentNamespace=null,n.bindingRootIndex=-1,n.bindingIndex=-1,n.currentQueryIndex=0}function Yc(n){Rt.lFrame.selectedIndex=n}let EA=!0;function zm(n,t){for(let e=t.directiveStart,i=t.directiveEnd;e=i)break}else t[l]<0&&(n[eu]+=65536),(a>14>16&&(3&n[Ct])===t&&(n[Ct]+=16384,xA(a,s)):xA(a,s)}const nu=-1;class xf{constructor(t,e,i){this.factory=t,this.resolving=!1,this.canSeeViewProviders=e,this.injectImpl=i}}function t1(n){return n!==nu}function Tf(n){return 32767&n}function Af(n,t){let e=function NU(n){return n>>16}(n),i=t;for(;e>0;)i=i[Kd],e--;return i}let i1=!0;function Bm(n){const t=i1;return i1=n,t}const TA=255,AA=5;let OU=0;const ll={};function Fm(n,t){const e=LA(n,t);if(-1!==e)return e;const i=t[Be];i.firstCreatePass&&(n.injectorIndex=t.length,r1(i.data,n),r1(t,null),r1(i.blueprint,null));const r=_m(n,t),s=n.injectorIndex;if(t1(r)){const o=Tf(r),a=Af(r,t),l=a[Be].data;for(let h=0;h<8;h++)t[s+h]=a[o+h]|l[o+h]}return t[s+8]=r,s}function r1(n,t){n.push(0,0,0,0,0,0,0,0,t)}function LA(n,t){return-1===n.injectorIndex||n.parent&&n.parent.injectorIndex===n.injectorIndex||null===t[n.injectorIndex+8]?-1:n.injectorIndex}function _m(n,t){if(n.parent&&-1!==n.parent.injectorIndex)return n.parent.injectorIndex;let e=0,i=null,r=t;for(;null!==r;){if(i=HA(r),null===i)return nu;if(e++,r=r[Kd],-1!==i.injectorIndex)return i.injectorIndex|e<<16}return nu}function n1(n,t,e){!function kU(n,t,e){let i;"string"==typeof e?i=e.charCodeAt(0)||0:e.hasOwnProperty(jo)&&(i=e[jo]),null==i&&(i=e[jo]=OU++);const r=i&TA;t.data[n+(r>>AA)]|=1<=0?t&TA:HU:t}(e);if("function"==typeof s){if(!SA(t,n,i))return i&Di.Host?NA(r,0,i):OA(t,e,i,r);try{let o;if(o=s(i),null!=o||i&Di.Optional)return o;Cb()}finally{wA()}}else if("number"==typeof s){let o=null,a=LA(n,t),l=nu,h=i&Di.Host?t[Jr][Os]:null;for((-1===a||i&Di.SkipSelf)&&(l=-1===a?_m(n,t):t[a+8],l!==nu&&RA(i,!1)?(o=t[Be],a=Tf(l),t=Af(l,t)):a=-1);-1!==a;){const c=t[Be];if(zA(s,a,c.data)){const d=zU(a,t,e,o,i,h);if(d!==ll)return d}l=t[a+8],l!==nu&&RA(i,t[Be].data[a+8]===h)&&zA(s,a,t)?(o=c,a=Tf(l),t=Af(l,t)):a=-1}}return r}function zU(n,t,e,i,r,s){const o=t[Be],a=o.data[n+8],c=Um(a,o,e,null==i?jc(a)&&i1:i!=o&&0!=(3&a.type),r&Di.Host&&s===a);return null!==c?Qc(t,o,c,a):ll}function Um(n,t,e,i,r){const s=n.providerIndexes,o=t.data,a=1048575&s,l=n.directiveStart,c=s>>20,u=r?a+c:n.directiveEnd;for(let p=i?a:a+c;p=l&&f.type===e)return p}if(r){const p=o[l];if(p&&Ca(p)&&p.type===e)return l}return null}function Qc(n,t,e,i){let r=n[e];const s=t.data;if(function xU(n){return n instanceof xf}(r)){const o=r;o.resolving&&function Vo(n,t){const e=t?`. Dependency path: ${t.join(" > ")} > ${n}`:"";throw new F(-200,`Circular dependency in DI detected for ${n}${e}`)}(zi(s[e]));const a=Bm(o.canSeeViewProviders);o.resolving=!0;const h=o.injectImpl?no(o.injectImpl):null;SA(n,i,Di.Default);try{r=n[e]=o.factory(void 0,s,n,i),t.firstCreatePass&&e>=i.directiveStart&&function EU(n,t,e){const{ngOnChanges:i,ngOnInit:r,ngDoCheck:s}=t.type.prototype;if(i){const o=rA(t);(e.preOrderHooks??=[]).push(n,o),(e.preOrderCheckHooks??=[]).push(n,o)}r&&(e.preOrderHooks??=[]).push(0-n,r),s&&((e.preOrderHooks??=[]).push(n,s),(e.preOrderCheckHooks??=[]).push(n,s))}(e,s[e],t)}finally{null!==h&&no(h),Bm(a),o.resolving=!1,wA()}}return r}function zA(n,t,e){return!!(e[t+(n>>AA)]&1<Array.isArray(e)?uu(e,t):t(e))}function FA(n,t,e){t>=n.length?n.push(e):n.splice(t,0,e)}function jm(n,t){return t>=n.length-1?n.pop():n.splice(t,1)[0]}const gu=new Ht(""),YA=new Ht("",-1),f1=new Ht("");class Qm{get(t,e=vf){if(e===vf){const i=new Error(`NullInjectorError: No provider for ${dt(t)}!`);throw i.name="NullInjectorError",i}return e}}function aj(...n){return{\u0275providers:QA(0,n),\u0275fromNgModule:!0}}function QA(n,...t){const e=[],i=new Set;let r;const s=o=>{e.push(o)};return uu(t,o=>{const a=o;Gm(a,s,[],i)&&(r||=[],r.push(a))}),void 0!==r&&GA(r,s),e}function GA(n,t){for(let e=0;e{t(s,i)})}}function Gm(n,t,e,i){if(!(n=vt(n)))return!1;let r=null,s=Mm(n);const o=!s&&ci(n);if(s||o){if(o&&!o.standalone)return!1;r=n}else{const l=n.ngModule;if(s=Mm(l),!s)return!1;r=l}const a=i.has(r);if(o){if(a)return!1;if(i.add(r),o.dependencies){const l="function"==typeof o.dependencies?o.dependencies():o.dependencies;for(const h of l)Gm(h,t,e,i)}}else{if(!s)return!1;{if(null!=s.imports&&!a){let h;i.add(r);try{uu(s.imports,c=>{Gm(c,t,e,i)&&(h||=[],h.push(c))})}finally{}void 0!==h&&GA(h,t)}if(!a){const h=Vc(r)||(()=>new r);t({provide:r,useFactory:h,deps:Qi},r),t({provide:f1,useValue:r,multi:!0},r),t({provide:gu,useValue:()=>Fi(r),multi:!0},r)}const l=s.providers;if(null!=l&&!a){const h=n;v1(l,c=>{t(c,h)})}}}return r!==n&&void 0!==n.providers}function v1(n,t){for(let e of n)Ql(e)&&(e=e.\u0275providers),Array.isArray(e)?v1(e,t):t(e)}const lj=Xe({provide:String,useValue:Xe});function m1(n){return null!==n&&"object"==typeof n&&lj in n}function Gc(n){return"function"==typeof n}const y1=new Ht(""),Xm={},cj={};let S1;function qm(){return void 0===S1&&(S1=new Qm),S1}class Jl{}class vu extends Jl{get destroyed(){return this._destroyed}constructor(t,e,i,r){super(),this.parent=e,this.source=i,this.scopes=r,this.records=new Map,this._ngOnDestroyHooks=new Set,this._onDestroyHooks=[],this._destroyed=!1,b1(t,o=>this.processProvider(o)),this.records.set(YA,mu(void 0,this)),r.has("environment")&&this.records.set(Jl,mu(void 0,this));const s=this.records.get(y1);null!=s&&"string"==typeof s.value&&this.scopes.add(s.value),this.injectorDefTypes=new Set(this.get(f1,Qi,Di.Self))}destroy(){this.assertNotDestroyed(),this._destroyed=!0;try{for(const e of this._ngOnDestroyHooks)e.ngOnDestroy();const t=this._onDestroyHooks;this._onDestroyHooks=[];for(const e of t)e()}finally{this.records.clear(),this._ngOnDestroyHooks.clear(),this.injectorDefTypes.clear()}}onDestroy(t){return this.assertNotDestroyed(),this._onDestroyHooks.push(t),()=>this.removeOnDestroy(t)}runInContext(t){this.assertNotDestroyed();const e=Qh(this),i=no(void 0);try{return t()}finally{Qh(e),no(i)}}get(t,e=vf,i=Di.Default){if(this.assertNotDestroyed(),t.hasOwnProperty(ff))return t[ff](this);i=Em(i);const s=Qh(this),o=no(void 0);try{if(!(i&Di.SkipSelf)){let l=this.records.get(t);if(void 0===l){const h=function gj(n){return"function"==typeof n||"object"==typeof n&&n instanceof Ht}(t)&&bm(t);l=h&&this.injectableDefInScope(h)?mu(I1(t),Xm):null,this.records.set(t,l)}if(null!=l)return this.hydrate(t,l)}return(i&Di.Self?qm():this.parent).get(t,e=i&Di.Optional&&e===vf?null:e)}catch(a){if("NullInjectorError"===a.name){if((a[Cm]=a[Cm]||[]).unshift(dt(t)),s)throw a;return function A_(n,t,e,i){const r=n[Cm];throw t[BT]&&r.unshift(t[BT]),n.message=function L_(n,t,e,i=null){n=n&&"\n"===n.charAt(0)&&"\u0275"==n.charAt(1)?n.slice(2):n;let r=dt(t);if(Array.isArray(t))r=t.map(dt).join(" -> ");else if("object"==typeof t){let s=[];for(let o in t)if(t.hasOwnProperty(o)){let a=t[o];s.push(o+":"+("string"==typeof a?JSON.stringify(a):dt(a)))}r=`{${s.join(", ")}}`}return`${e}${i?"("+i+")":""}[${r}]: ${n.replace(C_,"\n ")}`}("\n"+n.message,r,e,i),n.ngTokenPath=r,n[Cm]=null,n}(a,t,"R3InjectorError",this.source)}throw a}finally{no(o),Qh(s)}}resolveInjectorInitializers(){const t=Qh(this),e=no(void 0);try{const r=this.get(gu,Qi,Di.Self);for(const s of r)s()}finally{Qh(t),no(e)}}toString(){const t=[],e=this.records;for(const i of e.keys())t.push(dt(i));return`R3Injector[${t.join(", ")}]`}assertNotDestroyed(){if(this._destroyed)throw new F(205,!1)}processProvider(t){let e=Gc(t=vt(t))?t:vt(t&&t.provide);const i=function uj(n){return m1(n)?mu(void 0,n.useValue):mu($A(n),Xm)}(t);if(!Gc(t)&&!0===t.multi){let r=this.records.get(e);r||(r=mu(void 0,Xm,!0),r.factory=()=>Ob(r.multi),this.records.set(e,r)),e=t,r.multi.push(t)}this.records.set(e,i)}hydrate(t,e){return e.value===Xm&&(e.value=cj,e.value=e.factory()),"object"==typeof e.value&&e.value&&function fj(n){return null!==n&&"object"==typeof n&&"function"==typeof n.ngOnDestroy}(e.value)&&this._ngOnDestroyHooks.add(e.value),e.value}injectableDefInScope(t){if(!t.providedIn)return!1;const e=vt(t.providedIn);return"string"==typeof e?"any"===e||this.scopes.has(e):this.injectorDefTypes.has(e)}removeOnDestroy(t){const e=this._onDestroyHooks.indexOf(t);-1!==e&&this._onDestroyHooks.splice(e,1)}}function I1(n){const t=bm(n),e=null!==t?t.factory:Vc(n);if(null!==e)return e;if(n instanceof Ht)throw new F(204,!1);if(n instanceof Function)return function dj(n){if(n.length>0)throw new F(204,!1);const e=function I_(n){return n&&(n[wm]||n[PT])||null}(n);return null!==e?()=>e.factory(n):()=>new n}(n);throw new F(204,!1)}function $A(n,t,e){let i;if(Gc(n)){const r=vt(n);return Vc(r)||I1(r)}if(m1(n))i=()=>vt(n.useValue);else if(function qA(n){return!(!n||!n.useFactory)}(n))i=()=>n.useFactory(...Ob(n.deps||[]));else if(function XA(n){return!(!n||!n.useExisting)}(n))i=()=>Fi(vt(n.useExisting));else{const r=vt(n&&(n.useClass||n.provide));if(!function pj(n){return!!n.deps}(n))return Vc(r)||I1(r);i=()=>new r(...Ob(n.deps))}return i}function mu(n,t,e=!1){return{factory:n,value:t,multi:e?[]:void 0}}function b1(n,t){for(const e of n)Array.isArray(e)?b1(e,t):e&&Ql(e)?b1(e.\u0275providers,t):t(e)}function eL(n,t=null,e=null,i){const r=function tL(n,t=null,e=null,i,r=new Set){const s=[e||Qi,aj(n)];return i=i||("object"==typeof n?void 0:dt(n)),new vu(s,t||qm(),i||null,r)}(n,t,e,i);return r.resolveInjectorInitializers(),r}let C1,Wo=(()=>{class n{static{this.THROW_IF_NOT_FOUND=vf}static{this.NULL=new Qm}static create(e,i){if(Array.isArray(e))return eL({name:""},i,e,"");{const r=e.name??"";return eL({name:r},e.parent,e.providers,r)}}static{this.\u0275prov=Yi({token:n,providedIn:"any",factory:()=>Fi(YA)})}static{this.__NG_ELEMENT_ID__=-1}}return n})();const E1=new Ht("",{providedIn:"root",factory:()=>Cj}),Cj="ng",rL=new Ht(""),yu=new Ht("",{providedIn:"platform",factory:()=>"unknown"}),nL=new Ht("",{providedIn:"root",factory:()=>function $h(){if(void 0!==C1)return C1;if(typeof document<"u")return document;throw new F(210,!1)}().body?.querySelector("[ngCspNonce]")?.getAttribute("ngCspNonce")||null});function ey(n){return 128==(128&n.flags)}var Kh=function(n){return n[n.Important=1]="Important",n[n.DashCase=2]="DashCase",n}(Kh||{});const L1=new Map;let Hj=0;const O1="__ngContext__";function Rs(n,t){ks(t)?(n[O1]=t[bf],function Fj(n){L1.set(n[bf],n)}(t)):n[O1]=t}let k1;function P1(n,t){return k1(n,t)}function Iu(n,t,e,i,r){if(null!=i){let s,o=!1;Ps(i)?s=i:ks(i)&&(o=!0,i=i[Vr]);const a=fr(i);0===n&&null!==e?null==r?DL(t,e,a):qc(t,e,a,r||null,!0):1===n&&null!==e?qc(t,e,a,r||null,!0):2===n?function ay(n,t,e){const i=sy(n,t);i&&function t6(n,t,e,i){n.removeChild(t,e,i)}(n,i,t,e)}(t,a,o):3===n&&t.destroyNode(a),null!=s&&function n6(n,t,e,i,r){const s=e[rl];s!==fr(e)&&Iu(t,n,i,s,r);for(let a=mn;a0&&(n[e-1][Ma]=i[Ma]);const s=jm(n,mn+t);!function Xj(n,t){wL(n,t),t[Vr]=null,t[Os]=null}(i[Be],i);const o=s[il];null!==o&&o.detachView(s[Be]),i[vn]=null,i[Ma]=null,i[Ct]&=-129}return i}function ny(n,t){if(!(256&t[Ct])){const e=t[Yt];e.destroyNode&&ly(n,t,e,3,null,null),function $j(n){let t=n[Sf];if(!t)return R1(n[Be],n);for(;t;){let e=null;if(ks(t))e=t[Sf];else{const i=t[mn];i&&(e=i)}if(!e){for(;t&&!t[Ma]&&t!==n;)ks(t)&&R1(t[Be],t),t=t[vn];null===t&&(t=n),ks(t)&&R1(t[Be],t),e=t&&t[Ma]}t=e}}(t)}}function R1(n,t){if(!(256&t[Ct])){t[Ct]&=-129,t[Ct]|=256,t[Uc]&&function Yd(n){if(Vl(n),Vh(n))for(let t=0;t=0?i[o]():i[-o].unsubscribe(),s+=2}else e[s].call(i[e[s+1]]);null!==i&&(t[Jd]=null);const r=t[Xh];if(null!==r){t[Xh]=null;for(let s=0;s-1){const{encapsulation:s}=n.data[i.directiveStart+r];if(s===Ia.None||s===Ia.Emulated)return null}return qs(i,e)}}(n,t.parent,e)}function qc(n,t,e,i,r){n.insertBefore(t,e,i,r)}function DL(n,t,e){n.appendChild(t,e)}function xL(n,t,e,i,r){null!==i?qc(n,t,e,i,r):DL(n,t,e)}function sy(n,t){return n.parentNode(t)}let B1,LL=function AL(n,t,e){return 40&n.type?qs(n,e):null};function oy(n,t,e,i){const r=H1(n,i,t),s=t[Yt],a=function TL(n,t,e){return LL(n,t,e)}(i.parent||t[Os],i,t);if(null!=r)if(Array.isArray(e))for(let l=0;lnull;function eM(n,t,e=!1){return $L(n,t,e)}class U6{}class tN{}class V6{resolveComponentFactory(t){throw function j6(n){const t=Error(`No component factory found for ${dt(n)}.`);return t.ngComponent=n,t}(t)}}let my=(()=>{class n{static{this.NULL=new V6}}return n})();function W6(){return Du(gr(),Se())}function Du(n,t){return new $c(qs(n,t))}let $c=(()=>{class n{constructor(e){this.nativeElement=e}static{this.__NG_ELEMENT_ID__=W6}}return n})();function Y6(n){return n instanceof $c?n.nativeElement:n}class rN{}let nM=(()=>{class n{constructor(){this.destroyNode=null}static{this.__NG_ELEMENT_ID__=()=>function Q6(){const n=Se(),e=To(gr().index,n);return(ks(e)?e:n)[Yt]}()}}return n})(),G6=(()=>{class n{static{this.\u0275prov=Yi({token:n,providedIn:"root",factory:()=>null})}}return n})();const sM={};function Wf(n,t,e,i,r=!1){for(;null!==e;){const s=t[e.index];null!==s&&i.push(fr(s)),Ps(s)&&dN(s,i);const o=e.type;if(8&o)Wf(n,t,e.child,i);else if(32&o){const a=P1(e,t);let l;for(;l=a();)i.push(l)}else if(16&o){const a=OL(t,e);if(Array.isArray(a))i.push(...a);else{const l=Wc(t[Jr]);Wf(l[Be],l,a,i,!0)}}e=r?e.projectionNext:e.next}return i}function dN(n,t){for(let e=mn;e!1,producerRecomputeValue:()=>{},consumerMarkedDirty:()=>{},consumerOnSignalRead:()=>{},consumerIsAlwaysLive:!0,consumerMarkedDirty:n=>{Ef(n.lView)},consumerOnSignalRead(){this.lView[Uc]=this}};function pN(n){return gN(n[Sf])}function fN(n){return gN(n[Ma])}function gN(n){for(;null!==n&&!Ps(n);)n=n[Ma];return n}function lM(n){return n.ngOriginalError}class eh{constructor(){this._console=console}handleError(t){const e=this._findOriginalError(t);this._console.error("ERROR",t),e&&this._console.error("ORIGINAL ERROR",e)}_findOriginalError(t){let e=t&&lM(t);for(;e&&lM(e);)e=lM(e);return e||null}}const mN=new Ht("",{providedIn:"root",factory:()=>Ri(eh).handleError.bind(void 0)}),SN=new Ht("",{providedIn:"root",factory:()=>!1}),Qt={};function Ot(n,t=Di.Default){const e=Se();return null===e?Fi(n,t):kA(gr(),e,vt(n),t)}function CN(n,t,e,i,r,s){const o=Wi(null);try{let a=null;r&Gh.SignalBased&&(a=t[i][Ts]),null!==a&&void 0!==a.transformFn&&(s=a.transformFn(s)),r&Gh.HasDecoratorInputTransform&&(s=n.inputTransforms[i].call(t,s)),null!==n.setInput?n.setInput(t,a,s,e,i):iA(t,a,i,s)}finally{Wi(o)}}function by(n,t,e,i,r,s,o,a,l,h,c){const d=t.blueprint.slice();return d[Vr]=r,d[Ct]=204|i,(null!==h||n&&2048&n[Ct])&&(d[Ct]|=2048),hA(d),d[vn]=d[Kd]=n,d[Er]=e,d[ql]=o||n&&n[ql],d[Yt]=a||n&&n[Yt],d[Xs]=l||n&&n[Xs]||null,d[Os]=s,d[bf]=function Bj(){return Hj++}(),d[wa]=c,d[JT]=h,d[Jr]=2==t.type?n[Jr]:d,d}function xu(n,t,e,i,r){let s=n.data[t];if(null===s)s=function hM(n,t,e,i,r){const s=fA(),o=Qb(),l=n.data[t]=function EV(n,t,e,i,r,s){let o=t?t.injectorIndex:-1,a=0;return function ru(){return null!==Rt.skipHydrationRootTNode}()&&(a|=128),{type:e,index:i,insertBeforeIndex:null,injectorIndex:o,directiveStart:-1,directiveEnd:-1,directiveStylingLast:-1,componentOffset:-1,propertyBindings:null,flags:a,providerIndexes:0,value:r,attrs:s,mergedAttrs:null,localNames:null,initialInputs:void 0,inputs:null,outputs:null,tView:null,next:null,prev:null,projectionNext:null,child:null,parent:t,projection:null,styles:null,stylesWithoutHost:null,residualStyles:void 0,classes:null,classesWithoutHost:null,residualClasses:void 0,classBindings:0,styleBindings:0}}(0,o?s:s&&s.parent,e,t,i,r);return null===n.firstChild&&(n.firstChild=l),null!==s&&(o?null==s.child&&null!==l.parent&&(s.child=l):null===s.next&&(s.next=l,l.prev=s)),l}(n,t,e,i,r),function vU(){return Rt.lFrame.inI18n}()&&(s.flags|=32);else if(64&s.type){s.type=e,s.value=i,s.attrs=r;const o=function Df(){const n=Rt.lFrame,t=n.currentTNode;return n.isParent?t:t.parent}();s.injectorIndex=null===o?-1:o.injectorIndex}return ol(s,!0),s}function Yf(n,t,e,i){if(0===e)return-1;const r=t.length;for(let s=0;sjt&&function wN(n,t,e,i){if(!i)if(3==(3&t[Ct])){const s=n.preOrderCheckHooks;null!==s&&Rm(t,s,e)}else{const s=n.preOrderHooks;null!==s&&Hm(t,s,0,e)}Yc(e)}(n,t,jt,!1),nl(o?2:0,r),e(i,r)}finally{Yc(s),nl(o?3:1,r)}}function cM(n,t,e){if(Hb(t)){const i=Wi(null);try{const s=t.directiveEnd;for(let o=t.directiveStart;onull;function TN(n,t,e,i,r){for(let s in t){if(!t.hasOwnProperty(s))continue;const o=t[s];if(void 0===o)continue;i??={};let a,l=Gh.None;Array.isArray(o)?(a=o[0],l=o[1]):a=o;let h=s;if(null!==r){if(!r.hasOwnProperty(s))continue;h=r[s]}0===n?AN(i,e,h,a,l):AN(i,e,h,a)}return i}function AN(n,t,e,i,r){let s;n.hasOwnProperty(e)?(s=n[e]).push(t,i):s=n[e]=[t,i],void 0!==r&&s.push(r)}function LN(n,t,e,i,r,s){for(let h=0;h0;){const e=n[--t];if("number"==typeof e&&e<0)return e}return 0})(o)!=a&&o.push(a),o.push(e,i,s)}}(n,t,i,Yf(n,e,r.hostVars,Qt),r)}function _V(n,t,e,i,r,s){const o=s[t];if(null!==o)for(let a=0;an.nextProducerIndex;)n.producerNode.pop(),n.producerLastReadVersion.pop(),n.producerIndexOfThis.pop()}}(a,o),function aV(n){n.lView[Uc]!==n&&(n.lView=null,uN.push(n))}(a)),Jb()}}function HN(n,t){for(let e=pN(n);null!==e;e=fN(e))for(let i=mn;i-1&&(Rf(t,i),jm(e,i))}this._attachedToViewContainer=!1}ny(this._lView[Be],this._lView)}onDestroy(t){!function km(n,t){if(256==(256&n[Ct]))throw new F(911,!1);null===n[Xh]&&(n[Xh]=[]),n[Xh].push(t)}(this._lView,t)}markForCheck(){Qf(this._cdRefInjectingView||this._lView)}detach(){this._lView[Ct]&=-129}reattach(){Wb(this._lView),this._lView[Ct]|=128}detectChanges(){this._lView[Ct]|=1024,SM(this._lView,this.notifyErrorHandler)}checkNoChanges(){}attachToViewContainerRef(){if(this._appRef)throw new F(902,!1);this._attachedToViewContainer=!0}detachFromAppRef(){this._appRef=null,wL(this._lView[Be],this._lView)}attachToAppRef(t){if(this._attachedToViewContainer)throw new F(902,!1);this._appRef=t,Wb(this._lView)}}const UN=new Set;function MM(n){return t=>{setTimeout(n,void 0,t)}}const Yo=class n7 extends Pt{constructor(t=!1){super(),this.__isAsync=t}emit(t){super.next(t)}subscribe(t,e,i){let r=t,s=e||(()=>null),o=i;if(t&&"object"==typeof t){const l=t;r=l.next?.bind(l),s=l.error?.bind(l),o=l.complete?.bind(l)}this.__isAsync&&(s=MM(s),r&&(r=MM(r)),o&&(o=MM(o)));const a=super.subscribe({next:r,error:s,complete:o});return t instanceof As&&t.add(a),a}};function jN(...n){}class zr{constructor({enableLongStackTrace:t=!1,shouldCoalesceEventChangeDetection:e=!1,shouldCoalesceRunChangeDetection:i=!1}){if(this.hasPendingMacrotasks=!1,this.hasPendingMicrotasks=!1,this.isStable=!0,this.onUnstable=new Yo(!1),this.onMicrotaskEmpty=new Yo(!1),this.onStable=new Yo(!1),this.onError=new Yo(!1),typeof Zone>"u")throw new F(908,!1);Zone.assertZonePatched();const r=this;r._nesting=0,r._outer=r._inner=Zone.current,Zone.TaskTrackingZoneSpec&&(r._inner=r._inner.fork(new Zone.TaskTrackingZoneSpec)),t&&Zone.longStackTraceZoneSpec&&(r._inner=r._inner.fork(Zone.longStackTraceZoneSpec)),r.shouldCoalesceEventChangeDetection=!i&&e,r.shouldCoalesceRunChangeDetection=i,r.lastRequestAnimationFrameId=-1,r.nativeRequestAnimationFrame=function s7(){const n="function"==typeof rr.requestAnimationFrame;let t=rr[n?"requestAnimationFrame":"setTimeout"],e=rr[n?"cancelAnimationFrame":"clearTimeout"];if(typeof Zone<"u"&&t&&e){const i=t[Zone.__symbol__("OriginalDelegate")];i&&(t=i);const r=e[Zone.__symbol__("OriginalDelegate")];r&&(e=r)}return{nativeRequestAnimationFrame:t,nativeCancelAnimationFrame:e}}().nativeRequestAnimationFrame,function l7(n){const t=()=>{!function a7(n){n.isCheckStableRunning||-1!==n.lastRequestAnimationFrameId||(n.lastRequestAnimationFrameId=n.nativeRequestAnimationFrame.call(rr,()=>{n.fakeTopEventTask||(n.fakeTopEventTask=Zone.root.scheduleEventTask("fakeTopEventTask",()=>{n.lastRequestAnimationFrameId=-1,CM(n),n.isCheckStableRunning=!0,wM(n),n.isCheckStableRunning=!1},void 0,()=>{},()=>{})),n.fakeTopEventTask.invoke()}),CM(n))}(n)};n._inner=n._inner.fork({name:"angular",properties:{isAngularZone:!0},onInvokeTask:(e,i,r,s,o,a)=>{if(function h7(n){return!(!Array.isArray(n)||1!==n.length)&&!0===n[0].data?.__ignore_ng_zone__}(a))return e.invokeTask(r,s,o,a);try{return VN(n),e.invokeTask(r,s,o,a)}finally{(n.shouldCoalesceEventChangeDetection&&"eventTask"===s.type||n.shouldCoalesceRunChangeDetection)&&t(),WN(n)}},onInvoke:(e,i,r,s,o,a,l)=>{try{return VN(n),e.invoke(r,s,o,a,l)}finally{n.shouldCoalesceRunChangeDetection&&t(),WN(n)}},onHasTask:(e,i,r,s)=>{e.hasTask(r,s),i===r&&("microTask"==s.change?(n._hasPendingMicrotasks=s.microTask,CM(n),wM(n)):"macroTask"==s.change&&(n.hasPendingMacrotasks=s.macroTask))},onHandleError:(e,i,r,s)=>(e.handleError(r,s),n.runOutsideAngular(()=>n.onError.emit(s)),!1)})}(r)}static isInAngularZone(){return typeof Zone<"u"&&!0===Zone.current.get("isAngularZone")}static assertInAngularZone(){if(!zr.isInAngularZone())throw new F(909,!1)}static assertNotInAngularZone(){if(zr.isInAngularZone())throw new F(909,!1)}run(t,e,i){return this._inner.run(t,e,i)}runTask(t,e,i,r){const s=this._inner,o=s.scheduleEventTask("NgZoneEvent: "+r,t,o7,jN,jN);try{return s.runTask(o,e,i)}finally{s.cancelTask(o)}}runGuarded(t,e,i){return this._inner.runGuarded(t,e,i)}runOutsideAngular(t){return this._outer.run(t)}}const o7={};function wM(n){if(0==n._nesting&&!n.hasPendingMicrotasks&&!n.isStable)try{n._nesting++,n.onMicrotaskEmpty.emit(null)}finally{if(n._nesting--,!n.hasPendingMicrotasks)try{n.runOutsideAngular(()=>n.onStable.emit(null))}finally{n.isStable=!0}}}function CM(n){n.hasPendingMicrotasks=!!(n._hasPendingMicrotasks||(n.shouldCoalesceEventChangeDetection||n.shouldCoalesceRunChangeDetection)&&-1!==n.lastRequestAnimationFrameId)}function VN(n){n._nesting++,n.isStable&&(n.isStable=!1,n.onUnstable.emit(null))}function WN(n){n._nesting--,wM(n)}let Xf=(()=>{class n{constructor(){this.handler=null,this.internalCallbacks=[]}execute(){const e=[...this.internalCallbacks];this.internalCallbacks.length=0;for(const r of e)r();return!!this.handler?.execute()||e.length>0}ngOnDestroy(){this.handler?.destroy(),this.handler=null,this.internalCallbacks.length=0}static{this.\u0275prov=Yi({token:n,providedIn:"root",factory:()=>new n})}}return n})();function p7(n,t){const e=To(t,n),i=e[Be];!function f7(n,t){for(let e=t.length;e0&&zL(n,e,s.join(" "))}}(u,w,f,i),void 0!==e&&function C7(n,t,e){const i=n.projection=[];for(let r=0;r=0;i--){const r=n[i];r.hostVars=t+=r.hostVars,r.hostAttrs=yf(r.hostAttrs,e=yf(e,r.hostAttrs))}}(i)}function D7(n,t){for(const e in t.inputs){if(!t.inputs.hasOwnProperty(e)||n.inputs.hasOwnProperty(e))continue;const i=t.inputs[e];if(void 0!==i&&(n.inputs[e]=i,n.declaredInputs[e]=t.declaredInputs[e],null!==t.inputTransforms)){const r=Array.isArray(i)?i[0]:i;if(!t.inputTransforms.hasOwnProperty(r))continue;n.inputTransforms??={},n.inputTransforms[r]=t.inputTransforms[r]}}}function Ey(n){return n===tl?{}:n===Qi?[]:n}function T7(n,t){const e=n.viewQuery;n.viewQuery=e?(i,r)=>{t(i,r),e(i,r)}:t}function A7(n,t){const e=n.contentQueries;n.contentQueries=e?(i,r,s)=>{t(i,r,s),e(i,r,s)}:t}function L7(n,t){const e=n.hostBindings;n.hostBindings=e?(i,r)=>{t(i,r),e(i,r)}:t}function Au(n,t){return!t||null===t.firstChild||ey(n)}function tg(n,t,e,i=!0){const r=t[Be];if(function Zj(n,t,e,i){const r=mn+i,s=e.length;i>0&&(e[r-1][Ma]=t),i{class n{static{this.__NG_ELEMENT_ID__=n9}}return n})();function n9(){return dO(gr(),Se())}const s9=xn,hO=class extends s9{constructor(t,e,i){super(),this._lContainer=t,this._hostTNode=e,this._hostLView=i}get element(){return Du(this._hostTNode,this._hostLView)}get injector(){return new Vn(this._hostTNode,this._hostLView)}get parentInjector(){const t=_m(this._hostTNode,this._hostLView);if(t1(t)){const e=Af(t,this._hostLView),i=Tf(t);return new Vn(e[Be].data[i+8],e)}return new Vn(null,this._hostLView)}clear(){for(;this.length>0;)this.remove(this.length-1)}get(t){const e=cO(this._lContainer);return null!==e&&e[t]||null}get length(){return this._lContainer.length-mn}createEmbeddedView(t,e,i){let r,s;"number"==typeof i?r=i:null!=i&&(r=i.index,s=i.injector);const a=t.createEmbeddedViewImpl(e||{},s,null);return this.insertImpl(a,r,Au(this._hostTNode,null)),a}createComponent(t,e,i,r,s){const o=t&&!function Lf(n){return"function"==typeof n}(t);let a;if(o)a=e;else{const f=e||{};a=f.index,i=f.injector,r=f.projectableNodes,s=f.environmentInjector||f.ngModuleRef}const l=o?t:new qf(ci(t)),h=i||this.parentInjector;if(!s&&null==l.ngModule){const g=(o?h:this.parentInjector).get(Jl,null);g&&(s=g)}ci(l.componentType??{});const p=l.create(h,r,null,s);return this.insertImpl(p.hostView,a,Au(this._hostTNode,null)),p}insert(t,e){return this.insertImpl(t,e,!0)}insertImpl(t,e,i){const r=t._lView;if(function rU(n){return Ps(n[vn])}(r)){const a=this.indexOf(t);if(-1!==a)this.detach(a);else{const l=r[vn],h=new hO(l,l[Os],l[vn]);h.detach(h.indexOf(t))}}const s=this._adjustIndex(e),o=this._lContainer;return tg(o,r,s,i),t.attachToViewContainerRef(),FA(OM(o),s,t),t}move(t,e){return this.insert(t,e)}indexOf(t){const e=cO(this._lContainer);return null!==e?e.indexOf(t):-1}remove(t){const e=this._adjustIndex(t,-1),i=Rf(this._lContainer,e);i&&(jm(OM(this._lContainer),e),ny(i[Be],i))}detach(t){const e=this._adjustIndex(t,-1),i=Rf(this._lContainer,e);return i&&null!=jm(OM(this._lContainer),e)?new Gf(i):null}_adjustIndex(t,e=0){return t??this.length+e}};function cO(n){return n[8]}function OM(n){return n[8]||(n[8]=[])}function dO(n,t){let e;const i=t[n.index];return Ps(i)?e=i:(e=function ON(n,t,e,i){return[n,!0,0,t,null,i,null,e,null,null]}(i,t,null,n),t[n.index]=e,My(t,e)),uO(e,t,n,i),new hO(e,n,t)}let uO=function fO(n,t,e,i){if(n[rl])return;let r;r=8&e.type?fr(i):function o9(n,t){const e=n[Yt],i=e.createComment(""),r=qs(t,n);return qc(e,sy(e,r),i,function i6(n,t){return n.nextSibling(t)}(e,r),!1),i}(t,e),n[rl]=r};function YM(n,t,e){const i=Se();return function Tn(n,t,e){return!Object.is(n[t],e)&&(n[t]=e,!0)}(i,function al(){return Rt.lFrame.bindingIndex++}(),t)&&function No(n,t,e,i,r,s,o,a){const l=qs(t,e);let c,h=t.inputs;!a&&null!=h&&(c=h[i])?(yM(n,e,c,i,r),jc(t)&&function TV(n,t){const e=To(t,n);16&e[Ct]||(e[Ct]|=64)}(e,t.index)):3&t.type&&(i=function xV(n){return"class"===n?"className":"for"===n?"htmlFor":"formaction"===n?"formAction":"innerHtml"===n?"innerHTML":"readonly"===n?"readOnly":"tabindex"===n?"tabIndex":n}(i),r=null!=o?o(r,t.value||"",i):r,s.setProperty(l,i,r))}(xi(),function Pr(){const n=Rt.lFrame;return Cf(n.tView,n.selectedIndex)}(),i,n,t,i[Yt],e,!1),YM}function QM(n,t,e,i,r){const o=r?"class":"style";yM(n,e,t.inputs[o],o,i)}function JM(n,t,e,i){const r=Se(),s=xi(),o=jt+n,a=r[Yt],l=s.firstCreatePass?function k8(n,t,e,i,r,s){const o=t.consts,l=xu(t,n,2,i,sl(o,r));return function fM(n,t,e,i){if(pA()){const r=null===i?null:{"":-1},s=function PV(n,t){const e=n.directiveRegistry;let i=null,r=null;if(e)for(let s=0;s(function qh(n){EA=n}(!0),ry(i,r,function CA(){return Rt.lFrame.currentNamespace}()));const Gu="en-US";let Ik=Gu;function sw(n){return!!n&&"function"==typeof n.then}function Yk(n){return!!n&&"function"==typeof n.subscribe}function UW(){return this._results[Symbol.iterator]()}class aw{get changes(){return this._changes??=new Yo}constructor(t=!1){this._emitDistinctChangesOnly=t,this.dirty=!0,this._results=[],this._changesDetected=!1,this._changes=void 0,this.length=0,this.first=void 0,this.last=void 0;const e=aw.prototype;e[Symbol.iterator]||(e[Symbol.iterator]=UW)}get(t){return this._results[t]}map(t){return this._results.map(t)}filter(t){return this._results.filter(t)}find(t){return this._results.find(t)}reduce(t,e){return this._results.reduce(t,e)}forEach(t){this._results.forEach(t)}some(t){return this._results.some(t)}toArray(){return this._results.slice()}toString(){return this._results.toString()}reset(t,e){this.dirty=!1;const i=function oo(n){return n.flat(Number.POSITIVE_INFINITY)}(t);(this._changesDetected=!function WU(n,t,e){if(n.length!==t.length)return!1;for(let i=0;i{class n{static{this.__NG_ELEMENT_ID__=WW}}return n})();const jW=ih,VW=class extends jW{constructor(t,e,i){super(),this._declarationLView=t,this._declarationTContainer=e,this.elementRef=i}get ssrId(){return this._declarationTContainer.tView?.ssrId||null}createEmbeddedView(t,e){return this.createEmbeddedViewImpl(t,e)}createEmbeddedViewImpl(t,e,i){const r=function eg(n,t,e,i){const r=t.tView,a=by(n,r,e,4096&n[Ct]?4096:16,null,t,null,null,null,i?.injector??null,i?.dehydratedView??null);a[If]=n[t.index];const h=n[il];return null!==h&&(a[il]=h.createEmbeddedView(r)),EM(r,a,e),a}(this._declarationLView,this._declarationTContainer,t,{injector:e,dehydratedView:i});return new Gf(r)}};function WW(){return jy(gr(),Se())}function jy(n,t){return 4&n.type?new VW(t,n,Du(n,t)):null}class lw{constructor(t){this.queryList=t,this.matches=null}clone(){return new lw(this.queryList)}setDirty(){this.queryList.setDirty()}}class hw{constructor(t=[]){this.queries=t}createEmbeddedView(t){const e=t.queries;if(null!==e){const i=null!==t.contentQueries?t.contentQueries[0]:e.length,r=[];for(let s=0;s0)i.push(o[a/2]);else{const h=s[a+1],c=t[-l];for(let d=mn;d>20;if(Gc(n)||!n.multi){const p=new xf(h,r,Ot),f=vw(l,t,r?c:c+u,d);-1===f?(n1(Fm(a,o),s,l),gw(s,n,t.length),t.push(l),a.directiveStart++,a.directiveEnd++,r&&(a.providerIndexes+=1048576),e.push(p),o.push(p)):(e[f]=p,o[f]=p)}else{const p=vw(l,t,c+u,d),f=vw(l,t,c,c+u),v=f>=0&&e[f];if(r&&!v||!r&&!(p>=0&&e[p])){n1(Fm(a,o),s,l);const y=function fY(n,t,e,i,r){const s=new xf(n,e,Ot);return s.multi=[],s.index=t,s.componentProviders=0,NP(s,r,i&&!e),s}(r?pY:uY,e.length,r,i,h);!r&&v&&(e[f].providerFactory=y),gw(s,n,t.length,0),t.push(l),a.directiveStart++,a.directiveEnd++,r&&(a.providerIndexes+=1048576),e.push(y),o.push(y)}else gw(s,n,p>-1?p:f,NP(e[r?f:p],h,!r&&i));!r&&i&&v&&e[f].componentProviders++}}}function gw(n,t,e,i){const r=Gc(t),s=function hj(n){return!!n.useClass}(t);if(r||s){const l=(s?vt(t.useClass):t).prototype.ngOnDestroy;if(l){const h=n.destroyHooks||(n.destroyHooks=[]);if(!r&&t.multi){const c=h.indexOf(e);-1===c?h.push(e,[i,l]):h[c+1].push(i,l)}else h.push(e,l)}}}function NP(n,t,e){return e&&n.componentProviders++,n.multi.push(t)-1}function vw(n,t,e,i){for(let r=e;r{e.providersResolver=(i,r)=>function dY(n,t,e){const i=xi();if(i.firstCreatePass){const r=Ca(n);fw(e,i.data,i.blueprint,r,!0),fw(t,i.data,i.blueprint,r,!1)}}(i,r?r(n):n,t)}}class rd{}class kP extends rd{constructor(t){super(),this.componentFactoryResolver=new $N(this),this.instance=null;const e=new vu([...t.providers,{provide:rd,useValue:this},{provide:my,useValue:this.componentFactoryResolver}],t.parent||qm(),t.debugName,new Set(["environment"]));this.injector=e,t.runEnvironmentInitializers&&e.resolveInjectorInitializers()}destroy(){this.injector.destroy()}onDestroy(t){this.injector.onDestroy(t)}}let SY=(()=>{class n{constructor(e){this._injector=e,this.cachedInjectors=new Map}getOrCreateStandaloneInjector(e){if(!e.standalone)return null;if(!this.cachedInjectors.has(e)){const i=QA(0,e.type),r=i.length>0?function yY(n,t,e=null){return new kP({providers:n,parent:t,debugName:e,runEnvironmentInitializers:!0}).injector}([i],this._injector,`Standalone[${e.type.name}]`):null;this.cachedInjectors.set(e,r)}return this.cachedInjectors.get(e)}ngOnDestroy(){try{for(const e of this.cachedInjectors.values())null!==e&&e.destroy()}finally{this.cachedInjectors.clear()}}static{this.\u0275prov=Yi({token:n,providedIn:"environment",factory:()=>new n(Fi(Jl))})}}return n})();function PP(n){(function Zc(n){UN.has(n)||(UN.add(n),performance?.mark?.("mark_feature_usage",{detail:{feature:n}}))})("NgStandalone"),n.getStandaloneInjector=t=>t.get(SY).getOrCreateStandaloneInjector(n)}let Dw=(()=>{class n{constructor(){this.taskId=0,this.pendingTasks=new Set,this.hasPendingTasks=new _o(!1)}get _hasPendingTasks(){return this.hasPendingTasks.value}add(){this._hasPendingTasks||this.hasPendingTasks.next(!0);const e=this.taskId++;return this.pendingTasks.add(e),e}remove(e){this.pendingTasks.delete(e),0===this.pendingTasks.size&&this._hasPendingTasks&&this.hasPendingTasks.next(!1)}ngOnDestroy(){this.pendingTasks.clear(),this._hasPendingTasks&&this.hasPendingTasks.next(!1)}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();const p2=new Ht(""),WQ=new Ht("");let Nw=(()=>{class n{constructor(){this.initialized=!1,this.done=!1,this.donePromise=new Promise((e,i)=>{this.resolve=e,this.reject=i}),this.appInits=Ri(WQ,{optional:!0})??[]}runInitializers(){if(this.initialized)return;const e=[];for(const r of this.appInits){const s=r();if(sw(s))e.push(s);else if(Yk(s)){const o=new Promise((a,l)=>{s.subscribe({complete:a,error:l})});e.push(o)}}const i=()=>{this.done=!0,this.resolve()};Promise.all(e).then(()=>{i()}).catch(r=>{this.reject(r)}),0===e.length&&i(),this.initialized=!0}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();const f2=new Ht("");let $u=(()=>{class n{constructor(){this._bootstrapListeners=[],this._runningTick=!1,this._destroyed=!1,this._destroyListeners=[],this._views=[],this.internalErrorHandler=Ri(mN),this.afterRenderEffectManager=Ri(Xf),this.componentTypes=[],this.components=[],this.isStable=Ri(Dw).hasPendingTasks.pipe(jr(e=>!e)),this._injector=Ri(Jl)}get destroyed(){return this._destroyed}get injector(){return this._injector}bootstrap(e,i){const r=e instanceof tN;if(!this._injector.get(Nw).done)throw!r&&function _c(n){const t=ci(n)||jn(n)||gs(n);return null!==t&&t.standalone}(e),new F(405,!1);let o;o=r?e:this._injector.get(my).resolveComponentFactory(e),this.componentTypes.push(o.componentType);const a=function QQ(n){return n.isBoundToModule}(o)?void 0:this._injector.get(rd),h=o.create(Wo.NULL,[],i||o.selector,a),c=h.location.nativeElement,d=h.injector.get(p2,null);return d?.registerApplication(c),h.onDestroy(()=>{this.detachView(h.hostView),Xy(this.components,h),d?.unregisterApplication(c)}),this._loadComponent(h),h}tick(){if(this._runningTick)throw new F(101,!1);try{this._runningTick=!0;for(let e of this._views)e.detectChanges()}catch(e){this.internalErrorHandler(e)}finally{try{this.afterRenderEffectManager.execute()}catch(e){this.internalErrorHandler(e)}this._runningTick=!1}}attachView(e){const i=e;this._views.push(i),i.attachToAppRef(this)}detachView(e){const i=e;Xy(this._views,i),i.detachFromAppRef()}_loadComponent(e){this.attachView(e.hostView),this.tick(),this.components.push(e);const i=this._injector.get(f2,[]);[...this._bootstrapListeners,...i].forEach(r=>r(e))}ngOnDestroy(){if(!this._destroyed)try{this._destroyListeners.forEach(e=>e()),this._views.slice().forEach(e=>e.destroy())}finally{this._destroyed=!0,this._views=[],this._bootstrapListeners=[],this._destroyListeners=[]}}onDestroy(e){return this._destroyListeners.push(e),()=>Xy(this._destroyListeners,e)}destroy(){if(this._destroyed)throw new F(406,!1);const e=this._injector;e.destroy&&!e.destroyed&&e.destroy()}get viewCount(){return this._views.length}warnIfDestroyed(){}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();function Xy(n,t){const e=n.indexOf(t);e>-1&&n.splice(e,1)}let XQ=(()=>{class n{constructor(){this.zone=Ri(zr),this.applicationRef=Ri($u)}initialize(){this._onMicrotaskEmptySubscription||(this._onMicrotaskEmptySubscription=this.zone.onMicrotaskEmpty.subscribe({next:()=>{this.zone.run(()=>{this.applicationRef.tick()})}}))}ngOnDestroy(){this._onMicrotaskEmptySubscription?.unsubscribe()}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();function S2(n){return[{provide:zr,useFactory:n},{provide:gu,multi:!0,useFactory:()=>{const t=Ri(XQ,{optional:!0});return()=>t.initialize()}},{provide:gu,multi:!0,useFactory:()=>{const t=Ri(ZQ);return()=>{t.initialize()}}},{provide:mN,useFactory:qQ}]}function qQ(){const n=Ri(zr),t=Ri(eh);return e=>n.runOutsideAngular(()=>t.handleError(e))}function $Q(n){return function g1(n){return{\u0275providers:n}}([[],S2(()=>new zr(function I2(n){return{enableLongStackTrace:!1,shouldCoalesceEventChangeDetection:n?.eventCoalescing??!1,shouldCoalesceRunChangeDetection:n?.runCoalescing??!1}}(n)))])}let ZQ=(()=>{class n{constructor(){this.subscription=new As,this.initialized=!1,this.zone=Ri(zr),this.pendingTasks=Ri(Dw)}initialize(){if(this.initialized)return;this.initialized=!0;let e=null;!this.zone.isStable&&!this.zone.hasPendingMacrotasks&&!this.zone.hasPendingMicrotasks&&(e=this.pendingTasks.add()),this.zone.runOutsideAngular(()=>{this.subscription.add(this.zone.onStable.subscribe(()=>{zr.assertNotInAngularZone(),queueMicrotask(()=>{null!==e&&!this.zone.hasPendingMacrotasks&&!this.zone.hasPendingMicrotasks&&(this.pendingTasks.remove(e),e=null)})}))}),this.subscription.add(this.zone.onUnstable.subscribe(()=>{zr.assertInAngularZone(),e??=this.pendingTasks.add()}))}ngOnDestroy(){this.subscription.unsubscribe()}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();const rh=new Ht("",{providedIn:"root",factory:()=>Ri(rh,Di.Optional|Di.SkipSelf)||function JQ(){return typeof $localize<"u"&&$localize.locale||Gu}()}),Ow=new Ht("");let rc=null;function MG(n){try{const{rootComponent:t,appProviders:e,platformProviders:i}=n,r=function rG(n=[]){if(rc)return rc;const t=function w2(n=[],t){return Wo.create({name:t,providers:[{provide:y1,useValue:"platform"},{provide:Ow,useValue:new Set([()=>rc=null])},...n]})}(n);return rc=t,function g2(){!function vb(n){Gd=n}(()=>{throw new F(600,!1)})}(),function C2(n){n.get(rL,null)?.forEach(e=>e())}(t),t}(i),s=[$Q(),...e||[]],a=new kP({providers:s,parent:r,debugName:"",runEnvironmentInitializers:!1}).injector,l=a.get(zr);return l.run(()=>{a.resolveInjectorInitializers();const h=a.get(eh,null);let c;l.runOutsideAngular(()=>{c=l.onError.subscribe({next:p=>{h.handleError(p)}})});const d=()=>a.destroy(),u=r.get(Ow);return u.add(d),a.onDestroy(()=>{c.unsubscribe(),u.delete(d)}),function v2(n,t,e){try{const i=e();return sw(i)?i.catch(r=>{throw t.runOutsideAngular(()=>n.handleError(r)),r}):i}catch(i){throw t.runOutsideAngular(()=>n.handleError(i)),i}}(h,l,()=>{const p=a.get(Nw);return p.runInitializers(),p.donePromise.then(()=>{!function bk(n){ro(n,"Expected localeId to be defined"),"string"==typeof n&&(Ik=n.toLowerCase().replace(/_/g,"-"))}(a.get(rh,Gu)||Gu);const g=a.get($u);return void 0!==t&&g.bootstrap(t),g})})})}catch(t){return Promise.reject(t)}}let X2=null;function _w(){return X2}class HG{}const sd=new Ht("");let tq=(()=>{class n{static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275mod=xm({type:n})}static{this.\u0275inj=gf({})}}return n})();function cz(n){return"server"===n}class Aq extends HG{constructor(){super(...arguments),this.supportsDOMEvents=!0}}class rC extends Aq{static makeCurrent(){!function RG(n){X2??=n}(new rC)}onAndCancel(t,e,i){return t.addEventListener(e,i),()=>{t.removeEventListener(e,i)}}dispatchEvent(t,e){t.dispatchEvent(e)}remove(t){t.parentNode&&t.parentNode.removeChild(t)}createElement(t,e){return(e=e||this.getDefaultDocument()).createElement(t)}createHtmlDocument(){return document.implementation.createHTMLDocument("fakeTitle")}getDefaultDocument(){return document}isElementNode(t){return t.nodeType===Node.ELEMENT_NODE}isShadowRoot(t){return t instanceof DocumentFragment}getGlobalEventTarget(t,e){return"window"===e?window:"document"===e?t:"body"===e?t.body:null}getBaseHref(t){const e=function Lq(){return bg=bg||document.querySelector("base"),bg?bg.getAttribute("href"):null}();return null==e?null:function Nq(n){return new URL(n,document.baseURI).pathname}(e)}resetBaseElement(){bg=null}getUserAgent(){return window.navigator.userAgent}getCookie(t){return function wX(n,t){t=encodeURIComponent(t);for(const e of n.split(";")){const i=e.indexOf("="),[r,s]=-1==i?[e,""]:[e.slice(0,i),e.slice(i+1)];if(r.trim()===t)return decodeURIComponent(s)}return null}(document.cookie,t)}}let bg=null,kq=(()=>{class n{build(){return new XMLHttpRequest}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();const nC=new Ht("");let fz=(()=>{class n{constructor(e,i){this._zone=i,this._eventNameToPlugin=new Map,e.forEach(r=>{r.manager=this}),this._plugins=e.slice().reverse()}addEventListener(e,i,r){return this._findPluginFor(i).addEventListener(e,i,r)}getZone(){return this._zone}_findPluginFor(e){let i=this._eventNameToPlugin.get(e);if(i)return i;if(i=this._plugins.find(s=>s.supports(e)),!i)throw new F(5101,!1);return this._eventNameToPlugin.set(e,i),i}static{this.\u0275fac=function(i){return new(i||n)(Fi(nC),Fi(zr))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();class gz{constructor(t){this._doc=t}}const sC="ng-app-id";let vz=(()=>{class n{constructor(e,i,r,s={}){this.doc=e,this.appId=i,this.nonce=r,this.platformId=s,this.styleRef=new Map,this.hostNodes=new Set,this.styleNodesInDOM=this.collectServerRenderedStyles(),this.platformIsServer=cz(s),this.resetHostNodes()}addStyles(e){for(const i of e)1===this.changeUsageCount(i,1)&&this.onStyleAdded(i)}removeStyles(e){for(const i of e)this.changeUsageCount(i,-1)<=0&&this.onStyleRemoved(i)}ngOnDestroy(){const e=this.styleNodesInDOM;e&&(e.forEach(i=>i.remove()),e.clear());for(const i of this.getAllStyles())this.onStyleRemoved(i);this.resetHostNodes()}addHost(e){this.hostNodes.add(e);for(const i of this.getAllStyles())this.addStyleToHost(e,i)}removeHost(e){this.hostNodes.delete(e)}getAllStyles(){return this.styleRef.keys()}onStyleAdded(e){for(const i of this.hostNodes)this.addStyleToHost(i,e)}onStyleRemoved(e){const i=this.styleRef;i.get(e)?.elements?.forEach(r=>r.remove()),i.delete(e)}collectServerRenderedStyles(){const e=this.doc.head?.querySelectorAll(`style[${sC}="${this.appId}"]`);if(e?.length){const i=new Map;return e.forEach(r=>{null!=r.textContent&&i.set(r.textContent,r)}),i}return null}changeUsageCount(e,i){const r=this.styleRef;if(r.has(e)){const s=r.get(e);return s.usage+=i,s.usage}return r.set(e,{usage:i,elements:[]}),i}getStyleElement(e,i){const r=this.styleNodesInDOM,s=r?.get(i);if(s?.parentNode===e)return r.delete(i),s.removeAttribute(sC),s;{const o=this.doc.createElement("style");return this.nonce&&o.setAttribute("nonce",this.nonce),o.textContent=i,this.platformIsServer&&o.setAttribute(sC,this.appId),e.appendChild(o),o}}addStyleToHost(e,i){const r=this.getStyleElement(e,i),s=this.styleRef,o=s.get(i)?.elements;o?o.push(r):s.set(i,{elements:[r],usage:1})}resetHostNodes(){const e=this.hostNodes;e.clear(),e.add(this.doc.head)}static{this.\u0275fac=function(i){return new(i||n)(Fi(sd),Fi(E1),Fi(nL,8),Fi(yu))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();const oC={svg:"http://www.w3.org/2000/svg",xhtml:"http://www.w3.org/1999/xhtml",xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/",math:"http://www.w3.org/1998/MathML/"},aC=/%COMP%/g,Hq=new Ht("",{providedIn:"root",factory:()=>!0});function yz(n,t){return t.map(e=>e.replace(aC,n))}let Sz=(()=>{class n{constructor(e,i,r,s,o,a,l,h=null){this.eventManager=e,this.sharedStylesHost=i,this.appId=r,this.removeStylesOnCompDestroy=s,this.doc=o,this.platformId=a,this.ngZone=l,this.nonce=h,this.rendererByCompId=new Map,this.platformIsServer=cz(a),this.defaultRenderer=new lC(e,o,l,this.platformIsServer)}createRenderer(e,i){if(!e||!i)return this.defaultRenderer;this.platformIsServer&&i.encapsulation===Ia.ShadowDom&&(i={...i,encapsulation:Ia.Emulated});const r=this.getOrCreateRenderer(e,i);return r instanceof bz?r.applyToHost(e):r instanceof hC&&r.applyStyles(),r}getOrCreateRenderer(e,i){const r=this.rendererByCompId;let s=r.get(i.id);if(!s){const o=this.doc,a=this.ngZone,l=this.eventManager,h=this.sharedStylesHost,c=this.removeStylesOnCompDestroy,d=this.platformIsServer;switch(i.encapsulation){case Ia.Emulated:s=new bz(l,h,i,this.appId,c,o,a,d);break;case Ia.ShadowDom:return new Uq(l,h,e,i,o,a,this.nonce,d);default:s=new hC(l,h,i,c,o,a,d)}r.set(i.id,s)}return s}ngOnDestroy(){this.rendererByCompId.clear()}static{this.\u0275fac=function(i){return new(i||n)(Fi(fz),Fi(vz),Fi(E1),Fi(Hq),Fi(sd),Fi(yu),Fi(zr),Fi(nL))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();class lC{constructor(t,e,i,r){this.eventManager=t,this.doc=e,this.ngZone=i,this.platformIsServer=r,this.data=Object.create(null),this.throwOnSyntheticProps=!0,this.destroyNode=null}destroy(){}createElement(t,e){return e?this.doc.createElementNS(oC[e]||e,t):this.doc.createElement(t)}createComment(t){return this.doc.createComment(t)}createText(t){return this.doc.createTextNode(t)}appendChild(t,e){(Iz(t)?t.content:t).appendChild(e)}insertBefore(t,e,i){t&&(Iz(t)?t.content:t).insertBefore(e,i)}removeChild(t,e){t&&t.removeChild(e)}selectRootElement(t,e){let i="string"==typeof t?this.doc.querySelector(t):t;if(!i)throw new F(-5104,!1);return e||(i.textContent=""),i}parentNode(t){return t.parentNode}nextSibling(t){return t.nextSibling}setAttribute(t,e,i,r){if(r){e=r+":"+e;const s=oC[r];s?t.setAttributeNS(s,e,i):t.setAttribute(e,i)}else t.setAttribute(e,i)}removeAttribute(t,e,i){if(i){const r=oC[i];r?t.removeAttributeNS(r,e):t.removeAttribute(`${i}:${e}`)}else t.removeAttribute(e)}addClass(t,e){t.classList.add(e)}removeClass(t,e){t.classList.remove(e)}setStyle(t,e,i,r){r&(Kh.DashCase|Kh.Important)?t.style.setProperty(e,i,r&Kh.Important?"important":""):t.style[e]=i}removeStyle(t,e,i){i&Kh.DashCase?t.style.removeProperty(e):t.style[e]=""}setProperty(t,e,i){null!=t&&(t[e]=i)}setValue(t,e){t.nodeValue=e}listen(t,e,i){if("string"==typeof t&&!(t=_w().getGlobalEventTarget(this.doc,t)))throw new Error(`Unsupported event target ${t} for event ${e}`);return this.eventManager.addEventListener(t,e,this.decoratePreventDefault(i))}decoratePreventDefault(t){return e=>{if("__ngUnwrap__"===e)return t;!1===(this.platformIsServer?this.ngZone.runGuarded(()=>t(e)):t(e))&&e.preventDefault()}}}function Iz(n){return"TEMPLATE"===n.tagName&&void 0!==n.content}class Uq extends lC{constructor(t,e,i,r,s,o,a,l){super(t,s,o,l),this.sharedStylesHost=e,this.hostEl=i,this.shadowRoot=i.attachShadow({mode:"open"}),this.sharedStylesHost.addHost(this.shadowRoot);const h=yz(r.id,r.styles);for(const c of h){const d=document.createElement("style");a&&d.setAttribute("nonce",a),d.textContent=c,this.shadowRoot.appendChild(d)}}nodeOrShadowRoot(t){return t===this.hostEl?this.shadowRoot:t}appendChild(t,e){return super.appendChild(this.nodeOrShadowRoot(t),e)}insertBefore(t,e,i){return super.insertBefore(this.nodeOrShadowRoot(t),e,i)}removeChild(t,e){return super.removeChild(this.nodeOrShadowRoot(t),e)}parentNode(t){return this.nodeOrShadowRoot(super.parentNode(this.nodeOrShadowRoot(t)))}destroy(){this.sharedStylesHost.removeHost(this.shadowRoot)}}class hC extends lC{constructor(t,e,i,r,s,o,a,l){super(t,s,o,a),this.sharedStylesHost=e,this.removeStylesOnCompDestroy=r,this.styles=l?yz(l,i.styles):i.styles}applyStyles(){this.sharedStylesHost.addStyles(this.styles)}destroy(){this.removeStylesOnCompDestroy&&this.sharedStylesHost.removeStyles(this.styles)}}class bz extends hC{constructor(t,e,i,r,s,o,a,l){const h=r+"-"+i.id;super(t,e,i,s,o,a,l,h),this.contentAttr=function Bq(n){return"_ngcontent-%COMP%".replace(aC,n)}(h),this.hostAttr=function Fq(n){return"_nghost-%COMP%".replace(aC,n)}(h)}applyToHost(t){this.applyStyles(),this.setAttribute(t,this.hostAttr,"")}createElement(t,e){const i=super.createElement(t,e);return super.setAttribute(i,this.contentAttr,""),i}}let jq=(()=>{class n extends gz{constructor(e){super(e)}supports(e){return!0}addEventListener(e,i,r){return e.addEventListener(i,r,!1),()=>this.removeEventListener(e,i,r)}removeEventListener(e,i,r){return e.removeEventListener(i,r)}static{this.\u0275fac=function(i){return new(i||n)(Fi(sd))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();const Mz=["alt","control","meta","shift"],Vq={"\b":"Backspace","\t":"Tab","\x7f":"Delete","\x1b":"Escape",Del:"Delete",Esc:"Escape",Left:"ArrowLeft",Right:"ArrowRight",Up:"ArrowUp",Down:"ArrowDown",Menu:"ContextMenu",Scroll:"ScrollLock",Win:"OS"},Wq={alt:n=>n.altKey,control:n=>n.ctrlKey,meta:n=>n.metaKey,shift:n=>n.shiftKey};let Yq=(()=>{class n extends gz{constructor(e){super(e)}supports(e){return null!=n.parseEventName(e)}addEventListener(e,i,r){const s=n.parseEventName(i),o=n.eventCallback(s.fullKey,r,this.manager.getZone());return this.manager.getZone().runOutsideAngular(()=>_w().onAndCancel(e,s.domEventName,o))}static parseEventName(e){const i=e.toLowerCase().split("."),r=i.shift();if(0===i.length||"keydown"!==r&&"keyup"!==r)return null;const s=n._normalizeKey(i.pop());let o="",a=i.indexOf("code");if(a>-1&&(i.splice(a,1),o="code."),Mz.forEach(h=>{const c=i.indexOf(h);c>-1&&(i.splice(c,1),o+=h+".")}),o+=s,0!=i.length||0===s.length)return null;const l={};return l.domEventName=r,l.fullKey=o,l}static matchEventFullKeyCode(e,i){let r=Vq[e.key]||e.key,s="";return i.indexOf("code.")>-1&&(r=e.code,s="code."),!(null==r||!r)&&(r=r.toLowerCase()," "===r?r="space":"."===r&&(r="dot"),Mz.forEach(o=>{o!==r&&(0,Wq[o])(e)&&(s+=o+".")}),s+=r,s===i)}static eventCallback(e,i,r){return s=>{n.matchEventFullKeyCode(s,e)&&r.runGuarded(()=>i(s))}}static _normalizeKey(e){return"esc"===e?"escape":e}static{this.\u0275fac=function(i){return new(i||n)(Fi(sd))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();function wz(n){return{appProviders:[...Jq,...n?.providers??[]],platformProviders:$q}}const $q=[{provide:yu,useValue:"browser"},{provide:rL,useValue:function Gq(){rC.makeCurrent()},multi:!0},{provide:sd,useFactory:function qq(){return function wj(n){C1=n}(document),document},deps:[]}],Jq=[{provide:y1,useValue:"root"},{provide:eh,useFactory:function Xq(){return new eh},deps:[]},{provide:nC,useClass:jq,multi:!0,deps:[sd,zr,yu]},{provide:nC,useClass:Yq,multi:!0,deps:[sd]},Sz,vz,fz,{provide:rN,useExisting:Sz},{provide:class oq{},useClass:kq,deps:[]},[]];var i$=0,cC=!1;function m0(n,t){var e=t;return e.unshift(void 0),new(Function.prototype.bind.apply(n,e))}function Y(n,t){for(var e=t,i=n.replace(/\[/g,".").replace(/\]/g,"").split("."),r=0;r"u"}function wi(n){return n+"_"+i$++}function S0(n,t){return n===t||!(n===document||!n)&&S0(n.parentNode,t)}function Cg(n){try{throw new Error(n)}catch(t){throw new Error(t.message+"\n"+t.stack)}}function Re(n){var t=n+"";return t.match(/auto|cm|mm|in|px|pt|pc|%|em|ex|ch|rem|vw|vh|vmin|vmax/)?t:t+"px"}function ce(){return cC}var Eg,n,t,a$={latn:{_digits:"0123456789",_type:"numeric"}},Tz={decimal:".",group:",",percentSign:"%",plusSign:"+",minusSign:"-",infinity:"\u221e",nan:"NaN",exponential:"E"},Az=[0,1,2,3,4,5,6,7,8,9],Rr=function(){function n(){}return n.getMainObject=function(t,e){return Y(ce()?e:"main."+e,t)},n.getNumberingSystem=function(t){return Y("supplemental.numberingSystems",t)||this.numberingSystems},n.reverseObject=function(t,e){for(var r={},s=0,o=e||Object.keys(t);s13&&(f+=1,o-=12),o-=1,a=f-4716;var y=u-24e5,S=10631/30,b=u-1948084,M=Math.floor(b/10631);b-=10631*M;var w=Math.floor((b-.1335)/S),C=30*M+w;b-=Math.floor(w*S+.1335);var D=Math.floor((b+28.5001)/29.5);13===D&&(D=12);for(var A=b-Math.floor(29.5001*D-29),x=0;xy);x++);var R=x+16260,L=Math.floor((R-1)/12),O=L+1,N=R-12*L,T=y-t[x-1]+1;return(T+"").length>2&&(T=A,N=D,O=C),{year:O,month:N,date:T}},n.toGregorian=function i(r,s,o){var g=Math.floor(o+t[12*(r-1)+1+(s-1)-16260-1]-1+24e5+.5),v=Math.floor((g-1867216.25)/36524.25),y=1524+(v=g+1+v-Math.floor(v/4)),S=Math.floor((y-122.1)/365.25),b=Math.floor(365.25*S),M=Math.floor((y-b)/30.6001),w=y-b-Math.floor(30.6001*M),C=M-(M>13.5?13:1),D=S-(C>2.5?4716:4715);return D<=0&&C--,new Date(D+"/"+C+"/"+w)};var ut,c$=/\/MMMMM|MMMM|MMM|a|LLLL|LLL|EEEEE|EEEE|E|K|cccc|ccc|WW|W|G+|z+/gi,Lz="stand-alone",d$=["sun","mon","tue","wed","thu","fri","sat"],Nz={m:"getMinutes",h:"getHours",H:"getHours",s:"getSeconds",d:"getDate",f:"getMilliseconds"},Oz=function(){function n(){}return n.dateFormat=function(t,e,i){var r=this,s=ut.getDependables(i,t,e.calendar),o=Y("parserObject.numbers",s),a=s.dateObject,l={isIslamic:ut.islamicRegex.test(e.calendar)};ce()&&e.isServerRendered&&(e=ut.compareBlazorDateFormats(e,t));var h=e.format||ut.getResultantPattern(e.skeleton,s.dateObject,e.type,!1,ce()?t:"");if(l.dateSeperator=ce()?Y("dateSeperator",a):ut.getDateSeparator(s.dateObject),st(h))Cg("Format options or type given must be invalid");else{h=ut.ConvertDateToWeekFormat(h),ce()&&(h=h.replace(/tt/,"a")),l.pattern=h,l.numMapper=ce()?ze({},o):Rr.getNumberMapper(s.parserObject,Rr.getNumberingSystem(i));for(var d=0,u=h.match(c$)||[];d2?r+=e.month[""+u]:f=!0;break;case"E":case"c":r+=e.weekday[""+d$[t.getDay()]];break;case"H":case"h":case"m":case"s":case"d":case"f":if(f=!0,"d"===d)u=o.date;else if("f"===d){f=!1,g=!0;var y=(p=(p=t[""+Nz[""+d]]().toString()).substring(0,c)).length;if(c!==y){if(c>3)continue;for(var S=0;S0?1:0],o=Math.abs(t);return s.replace(/HH?|mm/g,function(a){var l=a.length,h=-1!==a.indexOf("H");return i.checkTwodigitNumber(Math.floor(h?o/60:o%60),l)})},n}(),kz={ms:"minimumSignificantDigits",ls:"maximumSignificantDigits",mf:"minimumFractionDigits",lf:"maximumFractionDigits"},ep=["infinity","nan","group","decimal","exponential"],Pz=function(){function n(){}return n.numberFormatter=function(t,e,i){var l,r=this,s=ze({},e),o={},a={},h=ut.getDependables(i,t,"",!0),c=h.numericObject;a.numberMapper=ce()?ze({},c):Rr.getNumberMapper(h.parserObject,Rr.getNumberingSystem(i),!0),a.currencySymbol=ce()?Y("currencySymbol",c):ut.getCurrencySymbol(h.numericObject,s.currency||Tg,e.altSymbol,e.ignoreCurrency),a.percentSymbol=ce()?Y("numberSymbols.percentSign",c):a.numberMapper.numberSymbols.percentSign,a.minusSymbol=ce()?Y("numberSymbols.minusSign",c):a.numberMapper.numberSymbols.minusSign;var d=a.numberMapper.numberSymbols;if(e.format&&!ut.formatRegex.test(e.format))o=ut.customFormat(e.format,a,h.numericObject),!st(s.useGrouping)&&s.useGrouping&&(s.useGrouping=o.pData.useGrouping);else{if(ze(s,ut.getProperNumericSkeleton(e.format||"N")),s.isCurrency="currency"===s.type,s.isPercent="percent"===s.type,ce()||(l=ut.getSymbolPattern(s.type,a.numberMapper.numberSystem,h.numericObject,s.isAccount)),s.groupOne=this.checkValueRange(s.maximumSignificantDigits,s.minimumSignificantDigits,!0),this.checkValueRange(s.maximumFractionDigits,s.minimumFractionDigits,!1,!0),st(s.fractionDigits)||(s.minimumFractionDigits=s.maximumFractionDigits=s.fractionDigits),st(s.useGrouping)&&(s.useGrouping=!0),s.isCurrency&&!ce()&&(l=l.replace(/\u00A4/g,ut.defaultCurrency)),ce())o.nData=ze({},{},Y(s.type+"nData",c)),o.pData=ze({},{},Y(s.type+"pData",c)),"currency"===s.type&&e.currency&&ut.replaceBlazorCurrency([o.pData,o.nData],a.currencySymbol,e.currency);else{var u=l.split(";");o.nData=ut.getFormatData(u[1]||"-"+u[0],!0,a.currencySymbol),o.pData=ut.getFormatData(u[0],!1,a.currencySymbol),s.useGrouping&&(s.groupSeparator=d[ep[2]],s.groupData=this.getGroupingDetails(u[0]))}if(st(s.minimumFractionDigits)&&(s.minimumFractionDigits=o.nData.minimumFraction),st(s.maximumFractionDigits)){var f=o.nData.maximumFraction;s.maximumFractionDigits=st(f)&&s.isPercent?0:f}var g=s.minimumFractionDigits,v=s.maximumFractionDigits;!st(g)&&!st(v)&&g>v&&(s.maximumFractionDigits=g)}return ze(o.nData,s),ze(o.pData,s),function(y){return isNaN(y)?d[ep[1]]:isFinite(y)?r.intNumberFormatter(y,o,a,e):d[ep[0]]}},n.getGroupingDetails=function(t){var e={},i=t.match(ut.negativeDataRegex);if(i&&i[4]){var r=i[4],s=r.lastIndexOf(",");if(-1!==s){var o=r.split(".")[0];e.primary=o.length-s-1;var a=r.lastIndexOf(",",s-1);-1!==a&&(e.secondary=s-1-a)}}return e},n.checkValueRange=function(t,e,i,r){var s=r?"f":"s",o=0,a=kz["l"+s],l=kz["m"+s];if(st(t)||(this.checkRange(t,a,r),o++),st(e)||(this.checkRange(e,l,r),o++),2===o){if(!(tr[1])&&Cg(e+"value must be within the range"+r[0]+"to"+r[1])},n.intNumberFormatter=function(t,e,i,r){var s;if(!st(e.nData.type)){t<0?(t*=-1,s=e.nData):s=0===t&&e.zeroData||e.pData;var o="";if(s.isPercent&&(t*=100),s.groupOne)o=this.processSignificantDigits(t,s.minimumSignificantDigits,s.maximumSignificantDigits);else if(o=this.processFraction(t,s.minimumFractionDigits,s.maximumFractionDigits,r),s.minimumIntegerDigits&&(o=this.processMinimumIntegers(o,s.minimumIntegerDigits)),i.isCustomFormat&&s.minimumFractionDigits=0&&"0"===l[parseInt(c.toString(),10)]&&c>=s.minimumFractionDigits;c--)l=l.slice(0,c);o=a[0]+"."+l}return"scientific"===s.type&&(o=(o=t.toExponential(s.maximumFractionDigits)).replace("e",i.numberMapper.numberSymbols[ep[4]])),o=o.replace(".",i.numberMapper.numberSymbols[ep[3]]),o="#,###,,;(#,###,,)"===s.format?this.customPivotFormat(parseInt(o,10)):o,s.useGrouping&&(o=this.groupNumbers(o,s.groupData.primary,s.groupSeparator||",",i.numberMapper.numberSymbols[ep[3]]||".",s.groupData.secondary)),o=Rr.convertValueParts(o,ut.latnParseRegex,i.numberMapper.mapper),"N/A"===s.nlead?s.nlead:"0"===o&&r&&"0"===r.format?o+s.nend:s.nlead+o+s.nend}},n.processSignificantDigits=function(t,e,i){var r=t+"";return r.lengthe;)c=l.slice(h-e,h)+(c.length?i+c:""),h-=e,o&&(e=s,o=!1);return a[0]=l.slice(0,h)+(c.length?i:"")+c,a.join(r)},n.processFraction=function(t,e,i,r){var s=(t+"").split(".")[1],o=s?s.length:0;if(e&&oi||0===i))return t.toFixed(i);var h=t+"";return"0"===h[0]&&r&&"###.00"===r.format&&(h=h.slice(1)),h},n.processMinimumIntegers=function(t,e){var i=t.split("."),r=i[0],s=r.length;if(s=5e5){var r=(t/=1e6).toString().split(".")[1];return r&&+r.substring(0,1)>=5?Math.ceil(t).toString():Math.floor(t).toString()}return""},n}(),Dg=(new RegExp("^([^0-9]*)(([0-9,]*[0-9]+)(.[0-9]+)?)([Ee][+-]?[0-9]+)?([^0-9]*)$"),function(){function n(t){this.ranArray=[],this.boundedEvents={},!m(t)&&(this.context=t)}return n.prototype.on=function(t,e,i,r){if(!m(e)){var s=i||this.context;if(this.notExist(t))return void(this.boundedEvents[""+t]=[{handler:e,context:s,id:r}]);m(r)?this.isHandlerPresent(this.boundedEvents[""+t],e)||this.boundedEvents[""+t].push({handler:e,context:s}):-1===this.ranArray.indexOf(r)&&(this.ranArray.push(r),this.boundedEvents[""+t].push({handler:e,context:s,id:r}))}},n.prototype.off=function(t,e,i){if(!this.notExist(t)){var r=Y(t,this.boundedEvents);if(e){for(var s=0;s1&&(_.fractionDigits=parseInt(P[2],10)),_}function f(T,P,_,B){var j=B?{}:{nlead:"",nend:""},Q=T.match(n.customRegex);if(Q){B||(j.nlead=g(Q[1],_),j.nend=g(Q[10],_),j.groupPattern=Q[4]);var oe=Q[7];if(oe&&P){var ue=oe.match(t);j.minimumFraction=m(ue)?0:ue.length,j.maximumFraction=oe.length-1}}return j}function g(T,P){return T?(T=T.replace(n.defaultCurrency,P),""===P?T.trim():T):""}function v(T,P,_,B){return B?"$":Y("currencies."+P+(_?"."+_:".symbol"),T)||Y("currencies."+P+".symbol-alt-narrow",T)||"$"}function S(T,P,_){var B={type:"decimal",minimumFractionDigits:0,maximumFractionDigits:0},j=T.match(n.customRegex);if(m(j)||""===j[5]&&"N/A"!==T)return B.type=void 0,B;B.nlead=j[1],B.nend=j[10];var Q=j[6],oe=!!Q.match(/ $/g),ue=-1!==Q.replace(/ $/g,"").indexOf(" ");B.useGrouping=-1!==Q.indexOf(",")||ue,Q=Q.replace(/,/g,"");var pe=j[7];if(-1!==Q.indexOf("0")&&(B.minimumIntegerDigits=Q.length-Q.indexOf("0")),m(pe)||(B.minimumFractionDigits=pe.lastIndexOf("0"),B.maximumFractionDigits=pe.lastIndexOf("#"),-1===B.minimumFractionDigits&&(B.minimumFractionDigits=0),(-1===B.maximumFractionDigits||B.maximumFractionDigitsQ.lastIndexOf("'"))){B[""+a[parseInt(j.toString(),10)]]=Q.substr(0,oe)+_+Q.substr(oe+1),B[""+a[""+P]]=!0,B.type=B.isCurrency?"currency":"percent";break}}return B}function C(T,P){if(-1!==T.indexOf(",")){var _=T.split(",");T=_[0]+Y("numberMapper.numberSymbols.group",P)+_[1].replace(".",Y("numberMapper.numberSymbols.decimal",P))}else T=T.replace(".",Y("numberMapper.numberSymbols.decimal",P));return T}function A(T,P,_){T+=".";for(var B=0;B0;Q-=3)T=","+_[Q-2]+_[Q-1]+_[parseInt(Q.toString(),10)]+T;return T=T.slice(1),P[1]?T+"."+P[1]:T}n.dateParseRegex=/([a-z])\1*|'([^']|'')+'|''|./gi,n.basicPatterns=["short","medium","long","full"],n.defaultObject={dates:{calendars:{gregorian:{months:{"stand-alone":{abbreviated:{1:"Jan",2:"Feb",3:"Mar",4:"Apr",5:"May",6:"Jun",7:"Jul",8:"Aug",9:"Sep",10:"Oct",11:"Nov",12:"Dec"},narrow:{1:"J",2:"F",3:"M",4:"A",5:"M",6:"J",7:"J",8:"A",9:"S",10:"O",11:"N",12:"D"},wide:{1:"January",2:"February",3:"March",4:"April",5:"May",6:"June",7:"July",8:"August",9:"September",10:"October",11:"November",12:"December"}}},days:{"stand-alone":{abbreviated:{sun:"Sun",mon:"Mon",tue:"Tue",wed:"Wed",thu:"Thu",fri:"Fri",sat:"Sat"},narrow:{sun:"S",mon:"M",tue:"T",wed:"W",thu:"T",fri:"F",sat:"S"},short:{sun:"Su",mon:"Mo",tue:"Tu",wed:"We",thu:"Th",fri:"Fr",sat:"Sa"},wide:{sun:"Sunday",mon:"Monday",tue:"Tuesday",wed:"Wednesday",thu:"Thursday",fri:"Friday",sat:"Saturday"}}},dayPeriods:{format:{wide:{am:"AM",pm:"PM"}}},eras:{eraNames:{0:"Before Christ","0-alt-variant":"Before Common Era",1:"Anno Domini","1-alt-variant":"Common Era"},eraAbbr:{0:"BC","0-alt-variant":"BCE",1:"AD","1-alt-variant":"CE"},eraNarrow:{0:"B","0-alt-variant":"BCE",1:"A","1-alt-variant":"CE"}},dateFormats:{full:"EEEE, MMMM d, y",long:"MMMM d, y",medium:"MMM d, y",short:"M/d/yy"},timeFormats:{full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},dateTimeFormats:{full:"{1} 'at' {0}",long:"{1} 'at' {0}",medium:"{1}, {0}",short:"{1}, {0}",availableFormats:{d:"d",E:"ccc",Ed:"d E",Ehm:"E h:mm a",EHm:"E HH:mm",Ehms:"E h:mm:ss a",EHms:"E HH:mm:ss",Gy:"y G",GyMMM:"MMM y G",GyMMMd:"MMM d, y G",GyMMMEd:"E, MMM d, y G",h:"h a",H:"HH",hm:"h:mm a",Hm:"HH:mm",hms:"h:mm:ss a",Hms:"HH:mm:ss",hmsv:"h:mm:ss a v",Hmsv:"HH:mm:ss v",hmv:"h:mm a v",Hmv:"HH:mm v",M:"L",Md:"M/d",MEd:"E, M/d",MMM:"LLL",MMMd:"MMM d",MMMEd:"E, MMM d",MMMMd:"MMMM d",ms:"mm:ss",y:"y",yM:"M/y",yMd:"M/d/y",yMEd:"E, M/d/y",yMMM:"MMM y",yMMMd:"MMM d, y",yMMMEd:"E, MMM d, y",yMMMM:"MMMM y"}}},islamic:{months:{"stand-alone":{abbreviated:{1:"Muh.",2:"Saf.",3:"Rab. I",4:"Rab. II",5:"Jum. I",6:"Jum. II",7:"Raj.",8:"Sha.",9:"Ram.",10:"Shaw.",11:"Dhu\u02bbl-Q.",12:"Dhu\u02bbl-H."},narrow:{1:"1",2:"2",3:"3",4:"4",5:"5",6:"6",7:"7",8:"8",9:"9",10:"10",11:"11",12:"12"},wide:{1:"Muharram",2:"Safar",3:"Rabi\u02bb I",4:"Rabi\u02bb II",5:"Jumada I",6:"Jumada II",7:"Rajab",8:"Sha\u02bbban",9:"Ramadan",10:"Shawwal",11:"Dhu\u02bbl-Qi\u02bbdah",12:"Dhu\u02bbl-Hijjah"}}},days:{"stand-alone":{abbreviated:{sun:"Sun",mon:"Mon",tue:"Tue",wed:"Wed",thu:"Thu",fri:"Fri",sat:"Sat"},narrow:{sun:"S",mon:"M",tue:"T",wed:"W",thu:"T",fri:"F",sat:"S"},short:{sun:"Su",mon:"Mo",tue:"Tu",wed:"We",thu:"Th",fri:"Fr",sat:"Sa"},wide:{sun:"Sunday",mon:"Monday",tue:"Tuesday",wed:"Wednesday",thu:"Thursday",fri:"Friday",sat:"Saturday"}}},dayPeriods:{format:{wide:{am:"AM",pm:"PM"}}},eras:{eraNames:{0:"AH"},eraAbbr:{0:"AH"},eraNarrow:{0:"AH"}},dateFormats:{full:"EEEE, MMMM d, y G",long:"MMMM d, y G",medium:"MMM d, y G",short:"M/d/y GGGGG"},timeFormats:{full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},dateTimeFormats:{full:"{1} 'at' {0}",long:"{1} 'at' {0}",medium:"{1}, {0}",short:"{1}, {0}",availableFormats:{d:"d",E:"ccc",Ed:"d E",Ehm:"E h:mm a",EHm:"E HH:mm",Ehms:"E h:mm:ss a",EHms:"E HH:mm:ss",Gy:"y G",GyMMM:"MMM y G",GyMMMd:"MMM d, y G",GyMMMEd:"E, MMM d, y G",h:"h a",H:"HH",hm:"h:mm a",Hm:"HH:mm",hms:"h:mm:ss a",Hms:"HH:mm:ss",M:"L",Md:"M/d",MEd:"E, M/d",MMM:"LLL",MMMd:"MMM d",MMMEd:"E, MMM d",MMMMd:"MMMM d",ms:"mm:ss",y:"y G",yyyy:"y G",yyyyM:"M/y GGGGG",yyyyMd:"M/d/y GGGGG",yyyyMEd:"E, M/d/y GGGGG",yyyyMMM:"MMM y G",yyyyMMMd:"MMM d, y G",yyyyMMMEd:"E, MMM d, y G",yyyyMMMM:"MMMM y G",yyyyQQQ:"QQQ y G",yyyyQQQQ:"QQQQ y G"}}}},timeZoneNames:{hourFormat:"+HH:mm;-HH:mm",gmtFormat:"GMT{0}",gmtZeroFormat:"GMT"}},numbers:{currencies:{USD:{displayName:"US Dollar",symbol:"$","symbol-alt-narrow":"$"},EUR:{displayName:"Euro",symbol:"\u20ac","symbol-alt-narrow":"\u20ac"},GBP:{displayName:"British Pound","symbol-alt-narrow":"\xa3"}},defaultNumberingSystem:"latn",minimumGroupingDigits:"1","symbols-numberSystem-latn":{decimal:".",group:",",list:";",percentSign:"%",plusSign:"+",minusSign:"-",exponential:"E",superscriptingExponent:"\xd7",perMille:"\u2030",infinity:"\u221e",nan:"NaN",timeSeparator:":"},"decimalFormats-numberSystem-latn":{standard:"#,##0.###"},"percentFormats-numberSystem-latn":{standard:"#,##0%"},"currencyFormats-numberSystem-latn":{standard:"\xa4#,##0.00",accounting:"\xa4#,##0.00;(\xa4#,##0.00)"},"scientificFormats-numberSystem-latn":{standard:"#E0"}}},n.blazorDefaultObject={numbers:{mapper:{0:"0",1:"1",2:"2",3:"3",4:"4",5:"5",6:"6",7:"7",8:"8",9:"9"},mapperDigits:"0123456789",numberSymbols:{decimal:".",group:",",plusSign:"+",minusSign:"-",percentSign:"%",nan:"NaN",timeSeparator:":",infinity:"\u221e"},timeSeparator:":",currencySymbol:"$",currencypData:{nlead:"$",nend:"",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},percentpData:{nlead:"",nend:"%",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},percentnData:{nlead:"-",nend:"%",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},currencynData:{nlead:"($",nend:")",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},decimalnData:{nlead:"-",nend:"",groupData:{primary:3},maximumFraction:2,minimumFraction:2},decimalpData:{nlead:"",nend:"",groupData:{primary:3},maximumFraction:2,minimumFraction:2}},dates:{dayPeriods:{am:"AM",pm:"PM"},dateSeperator:"/",days:{abbreviated:{sun:"Sun",mon:"Mon",tue:"Tue",wed:"Wed",thu:"Thu",fri:"Fri",sat:"Sat"},short:{sun:"Su",mon:"Mo",tue:"Tu",wed:"We",thu:"Th",fri:"Fr",sat:"Sa"},wide:{sun:"Sunday",mon:"Monday",tue:"Tuesday",wed:"Wednesday",thu:"Thursday",fri:"Friday",sat:"Saturday"}},months:{abbreviated:{1:"Jan",2:"Feb",3:"Mar",4:"Apr",5:"May",6:"Jun",7:"Jul",8:"Aug",9:"Sep",10:"Oct",11:"Nov",12:"Dec"},wide:{1:"January",2:"February",3:"March",4:"April",5:"May",6:"June",7:"July",8:"August",9:"September",10:"October",11:"November",12:"December"}},eras:{1:"AD"}}},n.monthIndex={3:"abbreviated",4:"wide",5:"narrow",1:"abbreviated"},n.month="months",n.days="days",n.patternMatcher={C:"currency",P:"percent",N:"decimal",A:"currency",E:"scientific"},n.getResultantPattern=l,n.getDependables=h,n.getSymbolPattern=c,n.ConvertDateToWeekFormat=d,n.compareBlazorDateFormats=u,n.getProperNumericSkeleton=p,n.getFormatData=f,n.changeCurrencySymbol=g,n.getCurrencySymbol=v,n.customFormat=function y(T,P,_){for(var B={},j=T.split(";"),Q=["pData","nData","zeroData"],oe=0;oe1,pe.nData=ce()?Y(De.type+"nData",oe):f(ot[1]||"-"+ot[0],!0,Ie),pe.pData=ce()?Y(De.type+"pData",oe):f(ot[0],!1,Ie),!Me[2]&&!P.minimumFractionDigits&&!P.maximumFractionDigits&&(ue=f(Ve.split(";")[0],!0,"",!0).minimumFraction)}if(n.formatRegex.test(P.format)||!P.format){if(ze(Q,p(P.format||"N")),Q.custom=!1,$e="###0",(Q.fractionDigits||P.minimumFractionDigits||P.maximumFractionDigits||ue)&&(Q.fractionDigits&&(P.minimumFractionDigits=P.maximumFractionDigits=Q.fractionDigits),$e=A($e,ue||Q.fractionDigits||P.minimumFractionDigits||0,P.maximumFractionDigits||0)),P.minimumIntegerDigits&&($e=x($e,P.minimumIntegerDigits)),P.useGrouping&&($e=R($e)),"currency"===Q.type||Q.type&&ce()){ce()&&"currency"!==Q.type&&(pe.pData=Y(Q.type+"pData",oe),pe.nData=Y(Q.type+"nData",oe));var cr=$e;$e=pe.pData.nlead+cr+pe.pData.nend,(pe.hasNegativePattern||ce())&&($e+=";"+pe.nData.nlead+cr+pe.nData.nend)}"percent"===Q.type&&!ce()&&($e+=" %")}else $e=P.format.replace(/'/g,'"');return Object.keys(xe).length>0&&($e=B?$e:C($e,xe)),$e},n.fractionDigitsPattern=A,n.minimumIntegerPattern=x,n.groupingPattern=R,n.getWeekData=function L(T,P){var _="sun",B=Y("supplemental.weekData.firstDay",P),j=T;return/en-/.test(j)&&(j=j.slice(3)),j=j.slice(0,2).toUpperCase()+j.substr(2),B&&(_=B[""+j]||B[j.slice(0,2)]||"sun"),o[""+_]},n.replaceBlazorCurrency=function O(T,P,_){var B=function h$(n){return Y(n||"",l$)}(_);if(P!==B)for(var j=0,Q=T;j=0?_:_+7;var j=Math.floor((T.getTime()-P.getTime()-6e4*(T.getTimezoneOffset()-P.getTimezoneOffset()))/864e5)+1;if(_<4){if((B=Math.floor((j+_-1)/7)+1)>52){var oe=new Date(T.getFullYear()+1,0,1).getDay();B=(oe=oe>=0?oe:oe+7)<4?1:53}}else B=Math.floor((j+_-1)/7);return B}}(ut||(ut={}));var tp=function(){function n(t,e,i){this.type="GET",this.emitError=!0,"string"==typeof t?(this.url=t,this.type=m(e)?this.type:e.toUpperCase(),this.contentType=i):Aa(t)&&Object.keys(t).length>0&&Nn(this,t),this.contentType=m(this.contentType)?"application/json; charset=utf-8":this.contentType}return n.prototype.send=function(t){var e=this,i={"application/json":"json","multipart/form-data":"formData","application/octet-stream":"blob","application/x-www-form-urlencoded":"formData"};try{m(this.fetchRequest)&&"GET"===this.type?this.fetchRequest=new Request(this.url,{method:this.type}):m(this.fetchRequest)&&(this.data=m(t)?this.data:t,this.fetchRequest=new Request(this.url,{method:this.type,headers:{"Content-Type":this.contentType},body:this.data}));var r={cancel:!1,fetchRequest:this.fetchRequest};return this.triggerEvent(this.beforeSend,r),r.cancel?null:(this.fetchResponse=fetch(this.fetchRequest),this.fetchResponse.then(function(s){if(e.triggerEvent(e.onLoad,s),!s.ok)throw s;for(var o="text",a=0,l=Object.keys(i);a-1},n.getValue=function(t,e){var i=typeof window<"u"?window.browserDetails:{};return typeof navigator<"u"&&"MacIntel"===navigator.platform&&navigator.maxTouchPoints>1&&!0===n.isTouch&&!pC.CHROME.test(navigator.userAgent)&&(i.isIos=!0,i.isDevice=!0,i.isTouch=!0,i.isPointer=!0),typeof window<"u"&&window.Capacitor&&"ios"===window.Capacitor.getPlatform()&&(i.isPointer=!1),typeof i[""+t]>"u"?i[""+t]=e.test(n.userAgent):i[""+t]},Object.defineProperty(n,"userAgent",{get:function(){return n.uA},set:function(t){n.uA=t,window.browserDetails={}},enumerable:!0,configurable:!0}),Object.defineProperty(n,"info",{get:function(){return st(window.browserDetails.info)?window.browserDetails.info=n.extractBrowserDetail():window.browserDetails.info},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isIE",{get:function(){return n.getValue("isIE",E$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isTouch",{get:function(){return st(window.browserDetails.isTouch)?window.browserDetails.isTouch="ontouchstart"in window.navigator||window&&window.navigator&&window.navigator.maxTouchPoints>0||"ontouchstart"in window:window.browserDetails.isTouch},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isPointer",{get:function(){return st(window.browserDetails.isPointer)?window.browserDetails.isPointer="pointerEnabled"in window.navigator:window.browserDetails.isPointer},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isMSPointer",{get:function(){return st(window.browserDetails.isMSPointer)?window.browserDetails.isMSPointer="msPointerEnabled"in window.navigator:window.browserDetails.isMSPointer},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isDevice",{get:function(){return n.getValue("isDevice",C$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isIos",{get:function(){return n.getValue("isIos",x$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isIos7",{get:function(){return n.getValue("isIos7",T$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isAndroid",{get:function(){return n.getValue("isAndroid",A$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isWebView",{get:function(){return st(window.browserDetails.isWebView)&&(window.browserDetails.isWebView=!(st(window.cordova)&&st(window.PhoneGap)&&st(window.phonegap)&&"object"!==window.forge)),window.browserDetails.isWebView},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isWindows",{get:function(){return n.getValue("isWindows",L$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"touchStartEvent",{get:function(){return st(window.browserDetails.touchStartEvent)?window.browserDetails.touchStartEvent=n.getTouchStartEvent():window.browserDetails.touchStartEvent},enumerable:!0,configurable:!0}),Object.defineProperty(n,"touchMoveEvent",{get:function(){return st(window.browserDetails.touchMoveEvent)?window.browserDetails.touchMoveEvent=n.getTouchMoveEvent():window.browserDetails.touchMoveEvent},enumerable:!0,configurable:!0}),Object.defineProperty(n,"touchEndEvent",{get:function(){return st(window.browserDetails.touchEndEvent)?window.browserDetails.touchEndEvent=n.getTouchEndEvent():window.browserDetails.touchEndEvent},enumerable:!0,configurable:!0}),Object.defineProperty(n,"touchCancelEvent",{get:function(){return st(window.browserDetails.touchCancelEvent)?window.browserDetails.touchCancelEvent=n.getTouchCancelEvent():window.browserDetails.touchCancelEvent},enumerable:!0,configurable:!0}),n.uA=typeof navigator<"u"?navigator.userAgent:"",n}(),E=function(){function n(){}return n.addOrGetEventData=function(t){return"__eventList"in t?t.__eventList.events:(t.__eventList={},t.__eventList.events=[])},n.add=function(t,e,i,r,s){var a,o=n.addOrGetEventData(t);a=s?function n$(n,t){var e;return function(){for(var i=this,r=[],s=0;s"u"||(e.innerHTML=t.innerHTML?t.innerHTML:"",void 0!==t.className&&(e.className=t.className),void 0!==t.id&&(e.id=t.id),void 0!==t.styles&&e.setAttribute("style",t.styles),void 0!==t.attrs&&Fe(e,t.attrs)),e}function V(n,t){for(var e=Uz(t),i=RegExp,r=0,s=n;r0}function pl(n,t,e){for(var i=document.createDocumentFragment(),r=0,s=n;r0;)i.appendChild(n[0]);else for(var r=0,s=n;r-1&&!r[parseInt(s.toString(),10)].match(/\[.*\]/)){var o=r[parseInt(s.toString(),10)].split("#");if(o[1].match(/^\d/)||o[1].match(t)){var a=r[parseInt(s.toString(),10)].split(".");a[0]=a[0].replace(/#/,"[id='")+"']",r[parseInt(s.toString(),10)]=a.join(".")}}e[parseInt(i.toString(),10)]=r.join(" ")}return e.join(",")}return n}function J(n,t){var e=n;if("function"==typeof e.closest)return e.closest(t);for(;e&&1===e.nodeType;){if(fC(e,t))return e;e=e.parentNode}return null}function je(n,t){void 0!==t&&Object.keys(t).forEach(function(e){n.style[""+e]=t[""+e]})}function fC(n,t){var e=n.matches||n.msMatchesSelector||n.webkitMatchesSelector;return e?e.call(n,t):-1!==[].indexOf.call(document.querySelectorAll(t),n)}var k$=new RegExp("]"),ah=function(){function n(t,e){this.isRendered=!1,this.isComplexArraySetter=!1,this.isServerRendered=!1,this.allowServerDataBinding=!0,this.isProtectedOnChange=!0,this.properties={},this.changedProperties={},this.oldProperties={},this.bulkChanges={},this.refreshing=!1,this.ignoreCollectionWatch=!1,this.finalUpdate=function(){},this.childChangedProperties={},this.modelObserver=new Dg(this),st(e)||(this.element="string"==typeof e?document.querySelector(e):e,m(this.element)||(this.isProtectedOnChange=!1,this.addInstance())),st(t)||this.setProperties(t,!0),this.isDestroyed=!1}return n.prototype.setProperties=function(t,e){var i=this.isProtectedOnChange;this.isProtectedOnChange=!!e,Nn(this,t),!0!==e?(Nn(this.changedProperties,t),this.dataBind()):ce()&&this.isRendered&&this.serverDataBind(t),this.finalUpdate(),this.changedProperties={},this.oldProperties={},this.isProtectedOnChange=i},n.callChildDataBind=function(t,e){for(var r=0,s=Object.keys(t);r=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Hs=function(n){function t(i){var r=n.call(this,i,void 0)||this;return r.easing={ease:"cubic-bezier(0.250, 0.100, 0.250, 1.000)",linear:"cubic-bezier(0.250, 0.250, 0.750, 0.750)",easeIn:"cubic-bezier(0.420, 0.000, 1.000, 1.000)",easeOut:"cubic-bezier(0.000, 0.000, 0.580, 1.000)",easeInOut:"cubic-bezier(0.420, 0.000, 0.580, 1.000)",elasticInOut:"cubic-bezier(0.5,-0.58,0.38,1.81)",elasticIn:"cubic-bezier(0.17,0.67,0.59,1.81)",elasticOut:"cubic-bezier(0.7,-0.75,0.99,1.01)"},r}var e;return W$(t,n),e=t,t.prototype.animate=function(i,r){var s=this.getModel(r=r||{});if("string"==typeof i)for(var a=0,l=Array.prototype.slice.call(we(i,document));a0?r-1:0,i+=e=-1!==e?"-"+e:"-"+r}return this.controlParent!==this.parentObj&&(i=this.parentObj.getParentKey()+"."+this.propName+e),i},n}(),X$=["grid","pivotview","treegrid","spreadsheet","rangeNavigator","DocumentEditor","listbox","inplaceeditor","PdfViewer","richtexteditor","DashboardLayout","chart","stockChart","circulargauge","diagram","heatmap","lineargauge","maps","slider","smithchart","barcode","sparkline","treemap","bulletChart","kanban","daterangepicker","schedule","gantt","signature","query-builder","drop-down-tree","carousel","filemanager","uploader","accordion","tab","treeview"],Kz=[115,121,110,99,102,117,115,105,111,110,46,105,115,76,105,99,86,97,108,105,100,97,116,101,100],eR=function(){function n(t){this.isValidated=!1,this.isLicensed=!0,this.version="27",this.platform=/JavaScript|ASPNET|ASPNETCORE|ASPNETMVC|FileFormats|essentialstudio/i,this.errors={noLicense:"This application was built using a trial version of Syncfusion Essential Studio. To remove the license validation message permanently, a valid license key must be included.",trailExpired:"This application was built using a trial version of Syncfusion Essential Studio. To remove the license validation message permanently, a valid license key must be included.",versionMismatched:"The included Syncfusion license key is invalid.",platformMismatched:"The included Syncfusion license key is invalid.",invalidKey:"The included Syncfusion license key is invalid."},this.manager=function(){var e=null;return{setKey:function i(s){e=s},getKey:function r(){return e}}}(),this.npxManager=function(){return{getKey:function i(){return"npxKeyReplace"}}}(),this.manager.setKey(t)}return n.prototype.validate=function(){if(!this.isValidated&&Ku&&!Y(w0(Kz),Ku)&&!Y("Blazor",Ku)){var i=void 0,r=void 0;if(this.manager&&this.manager.getKey()||this.npxManager&&"npxKeyReplace"!==this.npxManager.getKey()){var s=this.getInfoFromKey();if(s&&s.length)for(var o=0,a=s;o"+i+' Claim your FREE account\n
have a Syncfusion account? Sign In
\n
\n ';if(typeof document<"u"&&!m(document)){var t=mi("div",{innerHTML:n});document.body.appendChild(t)}}(),nR=!0),this.render(),this.mount?this.accessMount():this.trigger("created")}},t.prototype.renderComplete=function(e){ce()&&window.sfBlazor.renderComplete(this.element,e),this.isRendered=!0},t.prototype.dataBind=function(){this.injectModules(),n.prototype.dataBind.call(this)},t.prototype.on=function(e,i,r){if("string"==typeof e)this.localObserver.on(e,i,r);else for(var s=0,o=e;s=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},K$={left:0,top:0,bottom:0,right:0},SC={isDragged:!1},eZ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return sR(t,n),vr([I(0)],t.prototype,"left",void 0),vr([I(0)],t.prototype,"top",void 0),t}(Ee),np=function(n){function t(i,r){var s=n.call(this,r,i)||this;return s.dragLimit=e.getDefaultPosition(),s.borderWidth=e.getDefaultPosition(),s.padding=e.getDefaultPosition(),s.diffX=0,s.prevLeft=0,s.prevTop=0,s.dragProcessStarted=!1,s.eleTop=0,s.tapHoldTimer=0,s.externalInitialize=!1,s.diffY=0,s.parentScrollX=0,s.parentScrollY=0,s.droppables={},s.bind(),s}var e;return sR(t,n),e=t,t.prototype.bind=function(){this.toggleEvents(),X.isIE&&V([this.element],"e-block-touch"),this.droppables[this.scope]={}},t.getDefaultPosition=function(){return ze({},K$)},t.prototype.toggleEvents=function(i){var r;st(this.handle)||(r=U(this.handle,this.element));var s=this.enableTapHold&&X.isDevice&&X.isTouch?this.mobileInitialize:this.initialize;i?E.remove(r||this.element,X.isSafari()?"touchstart":X.touchStartEvent,s):E.add(r||this.element,X.isSafari()?"touchstart":X.touchStartEvent,s,this)},t.prototype.mobileInitialize=function(i){var r=this,s=i.currentTarget;this.tapHoldTimer=setTimeout(function(){r.externalInitialize=!0,r.removeTapholdTimer(),r.initialize(i,s)},this.tapHoldThreshold),E.add(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.removeTapholdTimer,this),E.add(document,X.isSafari()?"touchend":X.touchEndEvent,this.removeTapholdTimer,this)},t.prototype.removeTapholdTimer=function(){clearTimeout(this.tapHoldTimer),E.remove(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.removeTapholdTimer),E.remove(document,X.isSafari()?"touchend":X.touchEndEvent,this.removeTapholdTimer)},t.prototype.getScrollableParent=function(i,r){return m(i)?null:i[{vertical:"scrollHeight",horizontal:"scrollWidth"}[""+r]]>i[{vertical:"clientHeight",horizontal:"clientWidth"}[""+r]]&&("vertical"===r?i.scrollTop>0:i.scrollLeft>0)?("vertical"===r?(this.parentScrollY=this.parentScrollY+(0===this.parentScrollY?i.scrollTop:i.scrollTop-this.parentScrollY),this.tempScrollHeight=i.scrollHeight):(this.parentScrollX=this.parentScrollX+(0===this.parentScrollX?i.scrollLeft:i.scrollLeft-this.parentScrollX),this.tempScrollWidth=i.scrollWidth),m(i)?i:this.getScrollableParent(i.parentNode,r)):this.getScrollableParent(i.parentNode,r)},t.prototype.getScrollableValues=function(){this.parentScrollX=0,this.parentScrollY=0,this.element.classList.contains("e-dialog")&&this.element.classList.contains("e-dlg-modal"),this.getScrollableParent(this.element.parentNode,"vertical"),this.getScrollableParent(this.element.parentNode,"horizontal")},t.prototype.initialize=function(i,r){if(this.currentStateTarget=i.target,!this.isDragStarted()){if(this.isDragStarted(!0),this.externalInitialize=!1,this.target=i.currentTarget||r,this.dragProcessStarted=!1,this.abort){var s=this.abort;"string"==typeof s&&(s=[s]);for(var o=0;o=this.distance||this.externalInitialize){var p=this.getHelperElement(i);if(!p||m(p))return;r&&i.preventDefault();var f=this.helperElement=p;if(this.parentClientRect=this.calculateParentPosition(f.offsetParent),this.dragStart){var v={event:i,element:l,target:this.getProperTargetElement(i),bindEvents:ce()?this.bindDragEvents.bind(this):null,dragElement:f};this.trigger("dragStart",v)}this.dragArea?this.setDragArea():(this.dragLimit={left:0,right:0,bottom:0,top:0},this.borderWidth={top:0,left:0}),o={left:this.position.left-this.parentClientRect.left,top:this.position.top-this.parentClientRect.top},this.clone&&!this.enableTailMode&&(this.diffX=this.position.left-this.offset.left,this.diffY=this.position.top-this.offset.top),this.getScrollableValues();var y=getComputedStyle(l),S=parseFloat(y.marginTop);this.clone&&0!==S&&(o.top+=S),this.eleTop=isNaN(parseFloat(y.top))?0:parseFloat(y.top)-this.offset.top,this.enableScrollHandler&&!this.clone&&(o.top-=this.parentScrollY,o.left-=this.parentScrollX);var b=this.getProcessedPositionValue({top:o.top-this.diffY+"px",left:o.left-this.diffX+"px"});this.dragArea&&"string"!=typeof this.dragArea&&this.dragArea.classList.contains("e-kanban-content")&&"relative"===this.dragArea.style.position&&(o.top+=this.dragArea.scrollTop),this.dragElePosition={top:o.top,left:o.left},je(f,this.getDragPosition({position:"absolute",left:b.left,top:b.top})),E.remove(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.intDragStart),E.remove(document,X.isSafari()?"touchend":X.touchEndEvent,this.intDestroy),ce()||this.bindDragEvents(f)}}},t.prototype.bindDragEvents=function(i){Tr(i)?(E.add(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.intDrag,this),E.add(document,X.isSafari()?"touchend":X.touchEndEvent,this.intDragStop,this),this.setGlobalDroppables(!1,this.element,i)):(this.toggleEvents(),document.body.classList.remove("e-prevent-select"))},t.prototype.elementInViewport=function(i){for(this.top=i.offsetTop,this.left=i.offsetLeft,this.width=i.offsetWidth,this.height=i.offsetHeight;i.offsetParent;)this.top+=(i=i.offsetParent).offsetTop,this.left+=i.offsetLeft;return this.top>=window.pageYOffset&&this.left>=window.pageXOffset&&this.top+this.height<=window.pageYOffset+window.innerHeight&&this.left+this.width<=window.pageXOffset+window.innerWidth},t.prototype.getProcessedPositionValue=function(i){return this.queryPositionInfo?this.queryPositionInfo(i):i},t.prototype.calculateParentPosition=function(i){if(m(i))return{left:0,top:0};var r=i.getBoundingClientRect(),s=getComputedStyle(i);return{left:r.left+window.pageXOffset-parseInt(s.marginLeft,10),top:r.top+window.pageYOffset-parseInt(s.marginTop,10)}},t.prototype.intDrag=function(i){if(st(i.changedTouches)||1===i.changedTouches.length){var r,s;this.clone&&i.changedTouches&&X.isDevice&&X.isTouch&&i.preventDefault(),this.position=this.getMousePosition(i,this.isDragScroll);var o=this.getDocumentWidthHeight("Height");oy&&y>0?this.dragLimit.left:this.dragLimit.right+window.pageXOffset0?y-(y-this.dragLimit.right)+window.pageXOffset-M:y<0?this.dragLimit.left:y}if(this.pageY!==v||this.skipDistanceCheck){var w=d.offsetHeight+(parseFloat(b.marginTop)+parseFloat(b.marginBottom));s=this.dragLimit.top>S&&S>0?this.dragLimit.top:this.dragLimit.bottom+window.pageYOffset0?S-(S-this.dragLimit.bottom)+window.pageYOffset-w:S<0?this.dragLimit.top:S}}else r=y,s=S;var A,x,C=p+this.borderWidth.top,D=u+this.borderWidth.left;if(this.dragProcessStarted&&(m(s)&&(s=this.prevTop),m(r)&&(r=this.prevLeft)),this.helperElement.classList.contains("e-treeview"))this.dragArea?(this.dragLimit.top=this.clone?this.dragLimit.top:0,A=s-C<0?this.dragLimit.top:s-this.borderWidth.top,x=r-D<0?this.dragLimit.left:r-this.borderWidth.left):(A=s-this.borderWidth.top,x=r-this.borderWidth.left);else if(this.dragArea){var R=this.helperElement.classList.contains("e-dialog");this.dragLimit.top=this.clone?this.dragLimit.top:0,A=s-C<0?this.dragLimit.top:s-C,x=r-D<0?R?r-(D-this.borderWidth.left):this.dragElePosition.left:r-D}else A=s-C,x=r-D;var L=parseFloat(getComputedStyle(this.element).marginTop);if(L>0&&(this.clone&&(A+=L,S<0&&(L+S>=0?A=L+S:A-=L),this.dragArea&&(A=this.dragLimit.bottom=0){var O=this.dragLimit.top+S-C;O+L+C<0?A-=L+C:A=O}else A-=L+C;this.dragArea&&this.helperElement.classList.contains("e-treeview")&&(A=A+(w=d.offsetHeight+(parseFloat(b.marginTop)+parseFloat(b.marginBottom)))>this.dragLimit.bottom?this.dragLimit.bottom-w:A),this.enableScrollHandler&&!this.clone&&(A-=this.parentScrollY,x-=this.parentScrollX),this.dragArea&&"string"!=typeof this.dragArea&&this.dragArea.classList.contains("e-kanban-content")&&"relative"===this.dragArea.style.position&&(A+=this.dragArea.scrollTop);var N=this.getProcessedPositionValue({top:A+"px",left:x+"px"});this.isPreventScroll&&(N=this.getProcessedPositionValue({top:this.position.top-this.parentClientRect.top-2+"px",left:this.position.left-this.parentClientRect.left-2+"px"})),je(d,this.getDragPosition(N)),!this.elementInViewport(d)&&this.enableAutoScroll&&!this.helperElement.classList.contains("e-treeview")&&this.helperElement.scrollIntoView();var T=document.querySelectorAll(":hover");if(this.enableAutoScroll&&this.helperElement.classList.contains("e-treeview")){0===T.length&&(T=this.getPathElements(i));var P=this.getScrollParent(T,!1);this.elementInViewport(this.helperElement)?this.getScrollPosition(P,A):this.elementInViewport(this.helperElement)||(0===(T=[].slice.call(document.querySelectorAll(":hover"))).length&&(T=this.getPathElements(i)),P=this.getScrollParent(T,!0),this.getScrollPosition(P,A))}this.dragProcessStarted=!0,this.prevLeft=r,this.prevTop=s,this.position.left=r,this.position.top=s,this.pageX=g,this.pageY=v}},t.prototype.getScrollParent=function(i,r){for(var o,s=r?i.reverse():i,a=s.length-1;a>=0;a--)if(("auto"===(o=window.getComputedStyle(s[parseInt(a.toString(),10)])["overflow-y"])||"scroll"===o)&&s[parseInt(a.toString(),10)].scrollHeight>s[parseInt(a.toString(),10)].clientHeight)return s[parseInt(a.toString(),10)];if("visible"===(o=window.getComputedStyle(document.scrollingElement)["overflow-y"]))return document.scrollingElement.style.overflow="auto",document.scrollingElement},t.prototype.getScrollPosition=function(i,r){if(i&&i===document.scrollingElement)i.clientHeight+document.scrollingElement.scrollTop-this.helperElement.clientHeightr?i.scrollTop+=this.helperElement.clientHeight:i.scrollTop>r-this.helperElement.clientHeight&&(i.scrollTop-=this.helperElement.clientHeight);else if(i&&i!==document.scrollingElement){var s=document.scrollingElement.scrollTop,o=this.helperElement.clientHeight;i.clientHeight+i.getBoundingClientRect().top-o+sr-o-s&&(i.scrollTop-=this.helperElement.clientHeight)}},t.prototype.getPathElements=function(i){return document.elementsFromPoint(i.clientX>0?i.clientX:0,i.clientY>0?i.clientY:0)},t.prototype.triggerOutFunction=function(i,r){this.hoverObject.instance.intOut(i,r.target),this.hoverObject.instance.dragData[this.scope]=null,this.hoverObject=null},t.prototype.getDragPosition=function(i){var r=ze({},i);return this.axis&&("x"===this.axis?delete r.top:"y"===this.axis&&delete r.left),r},t.prototype.getDocumentWidthHeight=function(i){var r=document.body,s=document.documentElement;return Math.max(r["scroll"+i],s["scroll"+i],r["offset"+i],s["offset"+i],s["client"+i])},t.prototype.intDragStop=function(i){if(this.dragProcessStarted=!1,st(i.changedTouches)||1===i.changedTouches.length){if(-1!==["touchend","pointerup","mouseup"].indexOf(i.type)){if(this.dragStop){var s=this.getProperTargetElement(i);this.trigger("dragStop",{event:i,element:this.element,target:s,helper:this.helperElement})}this.intDestroy(i)}else this.element.setAttribute("aria-grabbed","false");var o=this.checkTargetElement(i);o.target&&o.instance&&(o.instance.dragStopCalled=!0,o.instance.dragData[this.scope]=this.droppables[this.scope],o.instance.intDrop(i,o.target)),this.setGlobalDroppables(!0),document.body.classList.remove("e-prevent-select")}},t.prototype.intDestroy=function(i){this.dragProcessStarted=!1,this.toggleEvents(),document.body.classList.remove("e-prevent-select"),this.element.setAttribute("aria-grabbed","false"),E.remove(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.intDragStart),E.remove(document,X.isSafari()?"touchend":X.touchEndEvent,this.intDragStop),E.remove(document,X.isSafari()?"touchend":X.touchEndEvent,this.intDestroy),E.remove(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.intDrag),this.isDragStarted()&&this.isDragStarted(!0)},t.prototype.onPropertyChanged=function(i,r){},t.prototype.getModuleName=function(){return"draggable"},t.prototype.isDragStarted=function(i){return i&&(SC.isDragged=!SC.isDragged),SC.isDragged},t.prototype.setDragArea=function(){var i,r,a,s=0,o=0;if(a="string"==typeof this.dragArea?U(this.dragArea):this.dragArea){var h=a.getBoundingClientRect();i=a.scrollWidth?a.scrollWidth:h.right-h.left,r=a.scrollHeight?this.dragArea&&!m(this.helperElement)&&this.helperElement.classList.contains("e-treeview")?a.clientHeight:a.scrollHeight:h.bottom-h.top;for(var c=["Top","Left","Bottom","Right"],d=getComputedStyle(a),u=0;u12;return S0(i.target,this.helperElement)||-1!==i.type.indexOf("touch")||a?(this.helperElement.style.pointerEvents="none",s=document.elementFromPoint(r.clientX,r.clientY),this.helperElement.style.pointerEvents=o):s=i.target,s},t.prototype.currentStateCheck=function(i,r){return m(this.currentStateTarget)||this.currentStateTarget===i?m(r)?i:r:this.currentStateTarget},t.prototype.getMousePosition=function(i,r){var a,l,s=void 0!==i.srcElement?i.srcElement:i.target,o=this.getCoordinates(i),h=m(s.offsetParent);if(r?(a=this.clone?o.pageX:o.pageX+(h?0:s.offsetParent.scrollLeft)-this.relativeXPosition,l=this.clone?o.pageY:o.pageY+(h?0:s.offsetParent.scrollTop)-this.relativeYPosition):(a=this.clone?o.pageX:o.pageX+window.pageXOffset-this.relativeXPosition,l=this.clone?o.pageY:o.pageY+window.pageYOffset-this.relativeYPosition),document.scrollingElement&&!r&&!this.clone){var c=document.scrollingElement;a=c.scrollWidth>0&&c.scrollWidth>c.clientWidth&&c.scrollLeft>0?a-c.scrollLeft:a,l=c.scrollHeight>0&&c.scrollHeight>c.clientHeight&&c.scrollTop>0?l-c.scrollTop:l}return{left:a-(this.margin.left+this.cursorAt.left),top:l-(this.margin.top+this.cursorAt.top)}},t.prototype.getCoordinates=function(i){return i.type.indexOf("touch")>-1?i.changedTouches[0]:i},t.prototype.getHelperElement=function(i){var r;return this.clone?this.helper?r=this.helper({sender:i,element:this.target}):(r=mi("div",{className:"e-drag-helper e-block-touch",innerHTML:"Draggable"}),document.body.appendChild(r)):r=this.element,r},t.prototype.setGlobalDroppables=function(i,r,s){this.droppables[this.scope]=i?null:{draggable:r,helper:s,draggedElement:this.element}},t.prototype.checkTargetElement=function(i){var r=this.getProperTargetElement(i),s=this.getDropInstance(r);if(!s&&r&&!m(r.parentNode)){var o=J(r.parentNode,".e-droppable")||r.parentElement;o&&(s=this.getDropInstance(o))}return{target:r,instance:s}},t.prototype.getDropInstance=function(i){var s,o=i&&i.ej2_instances;if(o)for(var a=0,l=o;a=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},oR=function(n){function t(e,i){var r=n.call(this,i,e)||this;return r.mouseOver=!1,r.dragData={},r.dragStopCalled=!1,r.bind(),r}return tZ(t,n),t.prototype.bind=function(){this.wireEvents()},t.prototype.wireEvents=function(){E.add(this.element,X.isSafari()?"touchend":X.touchEndEvent,this.intDrop,this)},t.prototype.onPropertyChanged=function(e,i){},t.prototype.getModuleName=function(){return"droppable"},t.prototype.intOver=function(e,i){this.mouseOver||(this.trigger("over",{event:e,target:i,dragData:this.dragData[this.scope]}),this.mouseOver=!0)},t.prototype.intOut=function(e,i){this.mouseOver&&(this.trigger("out",{evt:e,target:i}),this.mouseOver=!1)},t.prototype.intDrop=function(e,i){if(this.dragStopCalled){this.dragStopCalled=!1;var a,r=!0,s=this.dragData[this.scope],o=!!s&&s.helper&&Tr(s.helper);o&&(a=this.isDropArea(e,s.helper,i),this.accept&&(r=fC(s.helper,this.accept))),o&&this.drop&&a.canDrop&&r&&this.trigger("drop",{event:e,target:a.target,droppedElement:s.helper,dragData:s}),this.mouseOver=!1}},t.prototype.isDropArea=function(e,i,r){var s={canDrop:!0,target:r||e.target},o="touchend"===e.type;if(o||s.target===i){i.style.display="none";var a=o?e.changedTouches[0]:e,l=document.elementFromPoint(a.clientX,a.clientY);s.canDrop=!1,s.canDrop=S0(l,this.element),s.canDrop&&(s.target=l),i.style.display=""}return s},t.prototype.destroy=function(){E.remove(this.element,X.isSafari()?"touchend":X.touchEndEvent,this.intDrop),n.prototype.destroy.call(this)},sp([I()],t.prototype,"accept",void 0),sp([I("default")],t.prototype,"scope",void 0),sp([H()],t.prototype,"drop",void 0),sp([H()],t.prototype,"over",void 0),sp([H()],t.prototype,"out",void 0),sp([Ft],t)}(ah),ho=function(){function n(t,e,i){this.controlName=t,this.localeStrings=e,this.setLocale(i||"en-US")}return n.prototype.setLocale=function(t){var e=this.intGetControlConstant(n.locale,t);this.currentLocale=e||this.localeStrings},n.load=function(t){this.locale=ze(this.locale,t,{},!0)},n.prototype.getConstant=function(t){return m(this.currentLocale[""+t])?this.localeStrings[""+t]||"":this.currentLocale[""+t]},n.prototype.intGetControlConstant=function(t,e){return t[""+e]?t[""+e][this.controlName]:null},n.locale={},n}(),aR=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),hh=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},nZ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return aR(t,n),hh([I(50)],t.prototype,"swipeThresholdDistance",void 0),t}(Ee),sZ=/(Up|Down)/,Fs=function(n){function t(e,i){var r=n.call(this,i,e)||this;return r.touchAction=!0,r.tapCount=0,r.startEvent=function(s){if(!0===r.touchAction){var o=r.updateChangeTouches(s);void 0!==s.changedTouches&&(r.touchAction=!1),r.isTouchMoved=!1,r.movedDirection="",r.startPoint=r.lastMovedPoint={clientX:o.clientX,clientY:o.clientY},r.startEventData=o,r.hScrollLocked=r.vScrollLocked=!1,r.tStampStart=Date.now(),r.timeOutTapHold=setTimeout(function(){r.tapHoldEvent(s)},r.tapHoldThreshold),E.add(r.element,X.touchMoveEvent,r.moveEvent,r),E.add(r.element,X.touchEndEvent,r.endEvent,r),E.add(r.element,X.touchCancelEvent,r.cancelEvent,r)}},r.moveEvent=function(s){var o=r.updateChangeTouches(s);r.movedPoint=o,r.isTouchMoved=!(o.clientX===r.startPoint.clientX&&o.clientY===r.startPoint.clientY);var a={};r.isTouchMoved&&(clearTimeout(r.timeOutTapHold),r.calcScrollPoints(s),a=ze(a,{},{startEvents:r.startEventData,originalEvent:s,startX:r.startPoint.clientX,startY:r.startPoint.clientY,distanceX:r.distanceX,distanceY:r.distanceY,scrollDirection:r.scrollDirection,velocity:r.getVelocity(o)}),r.trigger("scroll",a),r.lastMovedPoint={clientX:o.clientX,clientY:o.clientY})},r.cancelEvent=function(s){clearTimeout(r.timeOutTapHold),clearTimeout(r.timeOutTap),r.tapCount=0,r.swipeFn(s),E.remove(r.element,X.touchCancelEvent,r.cancelEvent)},r.endEvent=function(s){r.swipeFn(s),r.isTouchMoved||"function"==typeof r.tap&&(r.trigger("tap",{originalEvent:s,tapCount:++r.tapCount}),r.timeOutTap=setTimeout(function(){r.tapCount=0},r.tapThreshold)),r.modeclear()},r.swipeFn=function(s){clearTimeout(r.timeOutTapHold),clearTimeout(r.timeOutTap);var o=r.updateChangeTouches(s),a=o.clientX-r.startPoint.clientX,l=o.clientY-r.startPoint.clientY;a=Math.floor(a<0?-1*a:a),l=Math.floor(l<0?-1*l:a),r.isTouchMoved=a>1||l>1,/Firefox/.test(X.userAgent)&&0===o.clientX&&0===o.clientY&&"mouseup"===s.type&&(r.isTouchMoved=!1),r.endPoint=o,r.calcPoints(s);var c={originalEvent:s,startEvents:r.startEventData,startX:r.startPoint.clientX,startY:r.startPoint.clientY,distanceX:r.distanceX,distanceY:r.distanceY,swipeDirection:r.movedDirection,velocity:r.getVelocity(o)};if(r.isTouchMoved){var d=r.swipeSettings.swipeThresholdDistance,u=ze(void 0,r.defaultArgs,c),p=!1,f=r.element,g=r.isScrollable(f),v=sZ.test(r.movedDirection);(dthis.distanceY?i.clientX>this.startPoint.clientX?"Right":"Left":i.clientYthis.distanceY||!0===this.hScrollLocked)&&!1===this.vScrollLocked?(this.scrollDirection=i.clientX>this.lastMovedPoint.clientX?"Right":"Left",this.hScrollLocked=!0):(this.scrollDirection=i.clientY=e[r[0]+s[0]]},t.prototype.updateChangeTouches=function(e){return e.changedTouches&&0!==e.changedTouches.length?e.changedTouches[0]:e},hh([H()],t.prototype,"tap",void 0),hh([H()],t.prototype,"tapHold",void 0),hh([H()],t.prototype,"swipe",void 0),hh([H()],t.prototype,"scroll",void 0),hh([I(350)],t.prototype,"tapThreshold",void 0),hh([I(750)],t.prototype,"tapHoldThreshold",void 0),hh([re({},nZ)],t.prototype,"swipeSettings",void 0),hh([Ft],t)}(ah),oZ=new RegExp("\\n|\\r|\\s\\s+","g"),aZ=new RegExp(/'|"/g),lZ=new RegExp("if ?\\("),hZ=new RegExp("else if ?\\("),lR=new RegExp("else"),cZ=new RegExp("for ?\\("),hR=new RegExp("(/if|/for)"),dZ=new RegExp("\\((.*)\\)",""),IC=new RegExp("^[0-9]+$","g"),uZ=new RegExp("[\\w\"'.\\s+]+","g"),pZ=new RegExp('"(.*?)"',"g"),fZ=new RegExp("[\\w\"'@#$.\\s-+]+","g"),cR=new RegExp("\\${([^}]*)}","g"),gZ=/^\..*/gm,bC=/\\/gi,vZ=/\\\\/gi,mZ=new RegExp("[\\w\"'@#$.\\s+]+","g"),yZ=/\window\./gm;function op(n,t,e,i,r){return!t||IC.test(n)||-1!==i.indexOf(n.split(".")[0])||r||"true"===n||"false"===n?n:e+"."+n}function MC(n,t,e,i){return t&&!IC.test(n)&&-1===i.indexOf(n.split(".")[0])?e+'["'+n:n}function dR(n){return n.match(vZ)?n:n.replace(bC,"\\\\")}function uR(n,t,e,i){if(n=n.trim(),/\window\./gm.test(n))return n;var s=/'|"/gm;return/@|\$|#/gm.test(n)&&(n=MC(n,-1===e.indexOf(n),t,e)+'"]'),gZ.test(n)?function bZ(n,t,e,i){return!t||IC.test(n)||-1!==i.indexOf(n.split(".")[0])||/^\..*/gm.test(n)?n:e+"."+n}(n,!s.test(n)&&-1===e.indexOf(n),t,e):op(n,!s.test(n)&&-1===e.indexOf(n),t,e,i)}var MZ=/^[\n\r.]+0&&t.forEach(function(e){he(e)})},n.removeJsEvents=function(){var t=this.wrapElement.querySelectorAll("["+fR.join("],[")+"]");t.length>0&&t.forEach(function(e){fR.forEach(function(i){e.hasAttribute(i)&&e.removeAttribute(i)})})},n.removeXssAttrs=function(){var t=this;this.removeAttrs.forEach(function(e,i){var r=t.wrapElement.querySelectorAll(e.selector);r.length>0&&r.forEach("a[href]"===e.selector?function(s){-1!==s.getAttribute(e.attribute).replace(/\t|\s|&/,"").indexOf("javascript:alert")&&s.removeAttribute(e.attribute)}:function(s){s.removeAttribute(e.attribute)})})},n}();function AZ(n){for(var t,e=n.childNodes,i=0;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Jo_RTL=(new Dg,"e-rtl"),ys=function(n){function t(e,i){return n.call(this,e,i)||this}return OZ(t,n),t.prototype.preRender=function(){},t.prototype.render=function(){this.initialize(),this.removeRippleEffect=function ms(n,t,e){var i=function Y$(n){return{selector:n&&n.selector?n.selector:null,ignore:n&&n.ignore?n.ignore:null,rippleFlag:n&&n.rippleFlag,isCenterRipple:n&&n.isCenterRipple,duration:n&&n.duration?n.duration:350}}(t);return!1===i.rippleFlag||void 0===i.rippleFlag&&!Zo?function(){}:(n.setAttribute("data-ripple","true"),E.add(n,"mousedown",qz,{parent:n,rippleOptions:i}),E.add(n,"mouseup",$z,{parent:n,rippleOptions:i,done:e}),E.add(n,"mouseleave",rp,{parent:n,rippleOptions:i}),X.isPointer&&E.add(n,"transitionend",rp,{parent:n,rippleOptions:i}),function(){n.removeAttribute("data-ripple"),E.remove(n,"mousedown",qz),E.remove(n,"mouseup",$z),E.remove(n,"mouseleave",rp),E.remove(n,"transitionend",rp)})}(this.element,{selector:".e-btn"}),this.renderComplete()},t.prototype.initialize=function(){if(this.cssClass&&V([this.element],this.cssClass.replace(/\s+/g," ").trim().split(" ")),this.isPrimary&&this.element.classList.add("e-primary"),!ce()||ce()&&"progress-btn"!==this.getModuleName()){if(this.content){var e=this.enableHtmlSanitizer?Ti.sanitize(this.content):this.content;this.element.innerHTML=e}this.setIconCss()}this.enableRtl&&this.element.classList.add(Jo_RTL),this.disabled?this.controlStatus(this.disabled):this.wireEvents()},t.prototype.controlStatus=function(e){this.element.disabled=e},t.prototype.setIconCss=function(){if(this.iconCss){var e=this.createElement("span",{className:"e-btn-icon "+this.iconCss});this.element.textContent.trim()?(e.classList.add("e-icon-"+this.iconPosition.toLowerCase()),("Top"===this.iconPosition||"Bottom"===this.iconPosition)&&this.element.classList.add("e-"+this.iconPosition.toLowerCase()+"-icon-btn")):this.element.classList.add("e-icon-btn");var i=this.element.childNodes[0];!i||"Left"!==this.iconPosition&&"Top"!==this.iconPosition?this.element.appendChild(e):this.element.insertBefore(e,i)}},t.prototype.wireEvents=function(){this.isToggle&&E.add(this.element,"click",this.btnClickHandler,this)},t.prototype.unWireEvents=function(){this.isToggle&&E.remove(this.element,"click",this.btnClickHandler)},t.prototype.btnClickHandler=function(){this.element.classList.contains("e-active")?this.element.classList.remove("e-active"):this.element.classList.add("e-active")},t.prototype.destroy=function(){var e=["e-primary",Jo_RTL,"e-icon-btn","e-success","e-info","e-danger","e-warning","e-flat","e-outline","e-small","e-bigger","e-active","e-round","e-top-icon-btn","e-bottom-icon-btn"];this.cssClass&&(e=e.concat(this.cssClass.split(" "))),n.prototype.destroy.call(this),K([this.element],e),this.element.getAttribute("class")||this.element.removeAttribute("class"),this.disabled&&this.element.removeAttribute("disabled"),this.content&&(this.element.innerHTML=this.element.innerHTML.replace(this.content,""));var i=this.element.querySelector("span.e-btn-icon");i&&he(i),this.unWireEvents(),Zo&&this.removeRippleEffect()},t.prototype.getModuleName=function(){return"btn"},t.prototype.getPersistData=function(){return this.addOnPersist([])},t.Inject=function(){},t.prototype.onPropertyChanged=function(e,i){for(var r=this.element.querySelector("span.e-btn-icon"),s=0,o=Object.keys(e);s=ad.width?ad.width:0;return vl.right+WR()-n}function aE(){return P0()+vl.width/2}function lE(n,t,e,i){if(void 0===t&&(t=null),void 0===e&&(e={X:!1,Y:!1}),!e.Y&&!e.X)return{left:0,top:0};var r=n.getBoundingClientRect();if(uo=t,sc=n.ownerDocument,i||(i=is(n,"left","top")),e.X){var s=uo?qR():e4(),o=pE(),a=fE(),l=o-i.left,h=i.left+r.width-a;r.width>s?i.left=l>0&&h<=0?a-r.width:h>0&&l<=0?o:l>h?a-r.width:o:l>0?i.left+=l:h>0&&(i.left-=h)}if(e.Y){var c=uo?$R():KR(),d=uE(),u=gE(),p=d-i.top,f=i.top+r.height-u;r.height>c?i.top=p>0&&f<=0?u-r.height:f>0&&p<=0?d:p>f?u-r.height:d:p>0?i.top+=p:f>0&&(i.top-=f)}return i}function oc(n,t,e,i){void 0===t&&(t=null);var r=is(n,"left","top");e&&(r.left=e),i&&(r.top=i);var s=[];uo=t,sc=n.ownerDocument;var o=n.getBoundingClientRect(),l=r.left,h=r.left+o.width,d=dE(r.top,r.top+o.height),u=QR(l,h);return d.topSide&&s.push("top"),u.rightSide&&s.push("right"),u.leftSide&&s.push("left"),d.bottomSide&&s.push("bottom"),s}function lJ(n,t,e,i,r,s,o,a,l){if(void 0===o&&(o=null),void 0===a&&(a={X:!0,Y:!0}),t&&n&&r&&s&&(a.X||a.Y)){var d,h={TL:null,TR:null,BL:null,BR:null},c={TL:null,TR:null,BL:null,BR:null};if("none"===window.getComputedStyle(n).display){var u=n.style.visibility;n.style.visibility="hidden",n.style.display="block",d=n.getBoundingClientRect(),n.style.removeProperty("display"),n.style.visibility=u}else d=n.getBoundingClientRect();var p={posX:r,posY:s,offsetX:e,offsetY:i,position:{left:0,top:0}};uo=o,sc=t.ownerDocument,function cJ(n,t,e,i,r){e.position=is(n,e.posX,e.posY,i,r),t.TL=is(n,"left","top",i,r),t.TR=is(n,"right","top",i,r),t.BR=is(n,"left","bottom",i,r),t.BL=is(n,"right","bottom",i,r)}(t,h,p,l,d),cE(c,p,d),a.X&&GR(t,c,h,p,d,!0),a.Y&&h.TL.top>-1&&XR(t,c,h,p,d,!0),function hJ(n,t,e){var i=0,r=0;if(null!=n.offsetParent&&("absolute"===getComputedStyle(n.offsetParent).position||"relative"===getComputedStyle(n.offsetParent).position)){var s=is(n.offsetParent,"left","top",!1,e);i=s.left,r=s.top}var o=1,a=1,l=YR(n);if(l){var h=getComputedStyle(l).transform;if("none"!==h){var c=new DOMMatrix(h);o=c.a,a=c.d}if("none"!==getComputedStyle(l).zoom){var u=hE(document.body);o*=u,a*=u}}n.style.top=t.position.top/a+t.offsetY-r/a+"px",n.style.left=t.position.left/o+t.offsetX-i/o+"px"}(n,p,d)}}function hE(n){var t=getComputedStyle(n).zoom;return parseFloat(t)||1}function YR(n){for(;n;){var t=window.getComputedStyle(n).transform,e=hE(document.body);if(t&&"none"!==t||e&&1!==e)return n;if(n===document.body)return null;n=n.offsetParent||n.parentElement}return null}function cE(n,t,e){n.TL={top:t.position.top+t.offsetY,left:t.position.left+t.offsetX},n.TR={top:n.TL.top,left:n.TL.left+e.width},n.BL={top:n.TL.top+e.height,left:n.TL.left},n.BR={top:n.TL.top+e.height,left:n.TL.left+e.width}}function QR(n,t){var e=!1,i=!1;return n-R0()fE()&&(i=!0),{leftSide:e,rightSide:i}}function GR(n,t,e,i,r,s){var o=QR(t.TL.left,t.TR.left),a=dE(t.TL.top,t.BL.top);e.TL.left-R0()<=pE()&&(o.leftSide=!1),e.TR.left>fE()&&(o.rightSide=!1),(o.leftSide&&!o.rightSide||!o.leftSide&&o.rightSide)&&(i.posX="right"===i.posX?"left":"right",i.offsetX=i.offsetX+r.width,i.offsetX=-1*i.offsetX,i.position=is(n,i.posX,i.posY,!1),cE(t,i,r),s&&GR(n,t,e,i,r,!1),!o.leftSide&&o.rightSide&&a.bottomSide&&(i.offsetX=0))}function XR(n,t,e,i,r,s){var o=dE(t.TL.top,t.BL.top);e.TL.top-z0()<=uE()&&(o.topSide=!1),e.BL.top>=gE()&&n.getBoundingClientRect().bottomgE()&&(i=!0),{topSide:e,bottomSide:i}}function qR(){return uo.getBoundingClientRect().width}function $R(){return uo.getBoundingClientRect().height}function ZR(){return uo.getBoundingClientRect().left}function JR(){return uo.getBoundingClientRect().top}function uE(){return uo?JR():0}function pE(){return uo?ZR():0}function fE(){return uo?R0()+ZR()+qR():R0()+e4()}function gE(){return uo?z0()+JR()+$R():z0()+KR()}function z0(){return sc.documentElement.scrollTop||sc.body.scrollTop}function R0(){return sc.documentElement.scrollLeft||sc.body.scrollLeft}function KR(){return window.innerHeight}function e4(){var n=window.innerWidth,t=document.documentElement.getBoundingClientRect();return n-(n-(m(document.documentElement)?0:t.width))}function t4(){uo=null,sc=null}var i4=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),bn=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},r4=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return i4(t,n),bn([I("left")],t.prototype,"X",void 0),bn([I("top")],t.prototype,"Y",void 0),t}(Ee),Gn_OPEN="e-popup-open",Gn_CLOSE="e-popup-close",ac=function(n){function t(e,i){return n.call(this,i,e)||this}return i4(t,n),t.prototype.onPropertyChanged=function(e,i){for(var r=0,s=Object.keys(e);r0&&c.left>0&&c.right>0&&c.bottom>0}var s=i.getBoundingClientRect();return!(r.bottoms.bottom||r.right>s.right||r.leftr.top?this.element.style.top="0px":s.bottomr.left&&(this.element.style.left=parseInt(this.element.style.left,10)+(s.left-r.left)+"px"))}},t.prototype.checkCollision=function(){var e=this.collision.X,i=this.collision.Y;"none"===e&&"none"===i||("flip"===e&&"flip"===i?this.callFlip({X:!0,Y:!0}):"fit"===e&&"fit"===i?this.callFit({X:!0,Y:!0}):("flip"===e?this.callFlip({X:!0,Y:!1}):"flip"===i&&this.callFlip({Y:!0,X:!1}),"fit"===e?this.callFit({X:!0,Y:!1}):"fit"===i&&this.callFit({X:!1,Y:!0})))},t.prototype.show=function(e,i){var r=this;if(this.getRelateToElement().classList.contains("e-filemanager")&&(this.fmDialogContainer=this.element.getElementsByClassName("e-file-select-wrap")[0]),this.wireEvents(),!m(this.fmDialogContainer)&&X.isIos&&(this.fmDialogContainer.style.display="block"),1e3===this.zIndex||!m(i)){var o=m(i)?this.element:i;this.zIndex=lc(o),je(this.element,{zIndex:this.zIndex})}e=m(e)||"object"!=typeof e?this.showAnimation:e,("none"!==this.collision.X||"none"!==this.collision.Y)&&(K([this.element],Gn_CLOSE),V([this.element],Gn_OPEN),this.checkCollision(),K([this.element],Gn_OPEN),V([this.element],Gn_CLOSE)),m(e)?(K([this.element],Gn_CLOSE),V([this.element],Gn_OPEN),this.trigger("open")):(e.begin=function(){r.isDestroyed||(K([r.element],Gn_CLOSE),V([r.element],Gn_OPEN))},e.end=function(){r.isDestroyed||r.trigger("open")},new Hs(e).animate(this.element))},t.prototype.hide=function(e){var i=this;e=m(e)||"object"!=typeof e?this.hideAnimation:e,m(e)?(K([this.element],Gn_OPEN),V([this.element],Gn_CLOSE),this.trigger("close")):(e.end=function(){i.isDestroyed||(K([i.element],Gn_OPEN),V([i.element],Gn_CLOSE),i.trigger("close"))},new Hs(e).animate(this.element)),this.unwireEvents()},t.prototype.getScrollableParent=function(e){return this.checkFixedParent(e),function vE(n,t){for(var e=getComputedStyle(n),i=[],r=/(auto|scroll)/,s=n.parentElement;s&&"HTML"!==s.tagName;){var o=getComputedStyle(s);!("absolute"===e.position&&"static"===o.position)&&r.test(o.overflow+o.overflowY+o.overflowX)&&i.push(s),s=s.parentElement}return t||i.push(document),i}(e,this.fixedParent)},t.prototype.checkFixedParent=function(e){for(var i=e.parentElement;i&&"HTML"!==i.tagName;){var r=getComputedStyle(i);("fixed"===r.position||"sticky"===r.position)&&!m(this.element)&&this.element.offsetParent&&"BODY"===this.element.offsetParent.tagName&&"hidden"!==getComputedStyle(this.element.offsetParent).overflow&&(this.element.style.top=window.scrollY>parseInt(this.element.style.top,10)?Re(window.scrollY-parseInt(this.element.style.top,10)):Re(parseInt(this.element.style.top,10)-window.scrollY),this.element.style.position="fixed",this.fixedParent=!0),i=i.parentElement,!m(this.element)&&m(this.element.offsetParent)&&"fixed"===r.position&&"fixed"===this.element.style.position&&(this.fixedParent=!0)}},bn([I("auto")],t.prototype,"height",void 0),bn([I("auto")],t.prototype,"width",void 0),bn([I(null)],t.prototype,"content",void 0),bn([I("container")],t.prototype,"targetType",void 0),bn([I(null)],t.prototype,"viewPortElement",void 0),bn([I({X:"none",Y:"none"})],t.prototype,"collision",void 0),bn([I("")],t.prototype,"relateTo",void 0),bn([re({},r4)],t.prototype,"position",void 0),bn([I(0)],t.prototype,"offsetX",void 0),bn([I(0)],t.prototype,"offsetY",void 0),bn([I(1e3)],t.prototype,"zIndex",void 0),bn([I(!1)],t.prototype,"enableRtl",void 0),bn([I("reposition")],t.prototype,"actionOnScroll",void 0),bn([I(null)],t.prototype,"showAnimation",void 0),bn([I(null)],t.prototype,"hideAnimation",void 0),bn([H()],t.prototype,"open",void 0),bn([H()],t.prototype,"close",void 0),bn([H()],t.prototype,"targetExitViewport",void 0),bn([Ft],t)}(yi);function lc(n){for(var t=n.parentElement,e=[];t&&"BODY"!==t.tagName;){var i=document.defaultView.getComputedStyle(t,null).getPropertyValue("z-index"),r=document.defaultView.getComputedStyle(t,null).getPropertyValue("position");"auto"!==i&&"static"!==r&&e.push(i),t=t.parentElement}for(var s=[],o=0;o2147483647?2147483647:c}var _i,Oa,ap,fh,IE,gh,$t,vh,mE=["north-west","north","north-east","west","east","south-west","south","south-east"],_g="e-resize-handle",hc="e-focused-handle",dJ="e-dlg-resizable",n4=["e-restrict-left"],s4="e-resize-viewport",uJ=["north","west","east","south"],yE=0,SE=0,o4=0,a4=0,Ug=0,jg=0,Vg=null,bE=null,ME=null,H0=!0,l4=0,wE=!0;function fJ(n){CE();var t=mi("span",{attrs:{unselectable:"on",contenteditable:"false"}});t.setAttribute("class","e-dialog-border-resize e-"+n),"south"===n&&(t.style.height="2px",t.style.width="100%",t.style.bottom="0px",t.style.left="0px"),"north"===n&&(t.style.height="2px",t.style.width="100%",t.style.top="0px",t.style.left="0px"),"east"===n&&(t.style.height="100%",t.style.width="2px",t.style.right="0px",t.style.top="0px"),"west"===n&&(t.style.height="100%",t.style.width="2px",t.style.left="0px",t.style.top="0px"),_i.appendChild(t)}function h4(n){var t;return m(n)||(t="string"==typeof n?document.querySelector(n):n),t}function c4(n){for(var t=n||this,e=_i.querySelectorAll("."+_g),i=0;i-1?"mouse":"touch"}function u4(n){if(n.preventDefault(),_i=n.target.parentElement,CE(),Ug=n.pageX,jg=n.pageY,n.target.classList.add(hc),m(Vg)||!0!==Vg(n,this)){this.targetEle&&_i&&_i.querySelector("."+dJ)&&($t="body"===this.target?null:this.targetEle,gh=this.targetEle.clientWidth,fh=this.targetEle.clientHeight);var e=m($t)?document:$t;E.add(e,"mousemove",Wg,this),E.add(document,"mouseup",B0,this);for(var i=0;i=0||s.top<0)&&(e=!0):e=!0;var a=SE+(r-jg);a=a>ap?a:ap;var l=0;m($t)||(l=o.top);var h=m($t)?0:$t.offsetHeight-$t.clientHeight,c=s.top-l-h/2;if(c=c<0?0:c,s.top>0&&c+a>fh){if(e=!1,_i.classList.contains(s4))return;_i.style.height=fh-parseInt(c.toString(),10)+"px"}else{var d=0;if(e){s.top<0&&t+(s.height+s.top)>0&&a+(d=s.top)<=30&&(a=s.height-(s.height+s.top)+30),a+s.top>=fh&&(_i.style.height=s.height+(t-(s.height+s.top))+"px");var u=m($t)?d:c;a>=ap&&a+u<=fh&&(_i.style.height=a+"px")}}}function DE(n){var e,t=!1,i="mouse"===d4(n.type)?n.pageY:n.touches[0].pageY,r=cc(_i),s=m($t)?0:$t.offsetHeight-$t.clientHeight;m($t)||(e=cc($t)),(!m($t)&&r.top-e.top>0||m($t)&&i>0||!m($t)&&Math.floor(r.top-e.top+r.height+(e.bottom-r.bottom))-s<=fh)&&(t=!0);var o=SE-(i-jg);if(t&&o>=ap&&o<=fh){var a=0;m($t)||(a=e.top);var l=a4-a+(i-jg);l=l>0?l:1,_i.style.height=o+"px",_i.style.top=l+"px"}}function xE(n){var i,t=document.documentElement.clientWidth,e=!1;m($t)||(i=cc($t));var r="mouse"===d4(n.type)?n.pageX:n.touches[0].pageX,s=cc(_i),o=m($t)?0:$t.offsetWidth-$t.clientWidth,a=m($t)?0:i.left,l=m($t)?0:i.width;m(vh)&&(m($t)?vh=t:(vh=s.left-a-o/2+s.width,vh+=l-o-vh)),(!m($t)&&Math.floor(s.left-i.left+s.width+(i.right-s.right))-o<=gh||m($t)&&r>=0)&&(e=!0);var h=yE-(r-Ug);if(H0&&(h=h>vh?vh:h),e&&h>=IE&&h<=gh){var c=0;m($t)||(c=i.left);var d=o4-c+(r-Ug);d=d>0?d:1,h!==l4&&wE&&(_i.style.width=h+"px"),H0&&(_i.style.left=d+"px",wE=1!==d)}l4=h}function TE(n){var i,t=document.documentElement.clientWidth,e=!1;m($t)||(i=cc($t));var s=(n.touches?n.changedTouches[0]:n).pageX,o=cc(_i);(!m($t)&&(o.left-i.left+o.width<=gh||o.right-i.left>=o.width)||m($t)&&t-s>0)&&(e=!0);var a=yE+(s-Ug),l=0;if(m($t)||(l=i.left),o.left-l+a>gh){if(e=!1,_i.classList.contains(s4))return;_i.style.width=gh-(o.left-l)+"px"}e&&a>=IE&&a<=gh&&(_i.style.width=a+"px")}function f4(){for(var n=_i.querySelectorAll("."+_g),t=0;t=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},SJ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return AE(t,n),Zt([I(!0)],t.prototype,"isFlat",void 0),Zt([I()],t.prototype,"buttonModel",void 0),Zt([I("Button")],t.prototype,"type",void 0),Zt([H()],t.prototype,"click",void 0),t}(Ee),IJ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return AE(t,n),Zt([I("Fade")],t.prototype,"effect",void 0),Zt([I(400)],t.prototype,"duration",void 0),Zt([I(0)],t.prototype,"delay",void 0),t}(Ee),F0="e-dialog",LE="e-rtl",NE="e-dlg-header-content",g4="e-dlg-header",_0="e-footer-content",U0="e-dlg-modal",v4="e-icon-dlg-close",ml="e-dlg-target",ka="e-scroll-disabled",m4="e-device",j0="e-dlg-fullscreen",y4="e-dlg-closeicon-btn",S4="e-popup-open",I4="Information",b4="e-scroll-disabled",M4="e-alert-dialog",w4="e-confirm-dialog",OE="e-dlg-resizable",lp="e-restrict-left",C4="e-resize-viewport",kE="user action",kJ=function(n){function t(e,i){var r=n.call(this,e,i)||this;return r.needsID=!0,r}return AE(t,n),t.prototype.render=function(){this.initialize(),this.initRender(),this.wireEvents(),"100%"===this.width&&(this.element.style.width=""),""!==this.minHeight&&(this.element.style.minHeight=Re(this.minHeight)),this.enableResize&&(this.setResize(),this.isModal&&(this.isModelResize=!0),"None"===this.animationSettings.effect&&this.getMinHeight()),this.renderComplete()},t.prototype.initializeValue=function(){this.dlgClosedBy=kE},t.prototype.preRender=function(){var e=this;if(this.initializeValue(),this.headerContent=null,this.allowMaxHeight=!0,this.preventVisibility=!0,this.clonedEle=this.element.cloneNode(!0),this.closeIconClickEventHandler=function(s){e.dlgClosedBy="close icon",e.hide(s)},this.dlgOverlayClickEventHandler=function(s){e.dlgClosedBy="overlayClick",s.preventFocus=!1,e.trigger("overlayClick",s,function(o){o.preventFocus||e.focusContent(),e.dlgClosedBy=kE})},this.l10n=new ho("dialog",{close:"Close"},this.locale),this.checkPositionData(),m(this.target)){var r=this.isProtectedOnChange;this.isProtectedOnChange=!0,this.target=document.body,this.isProtectedOnChange=r}},t.prototype.updatePersistData=function(){this.enablePersistence&&this.setProperties({width:parseFloat(this.element.style.width),height:parseFloat(this.element.style.height),position:{X:parseFloat(this.dragObj.element.style.left),Y:parseFloat(this.dragObj.element.style.top)}},!0)},t.prototype.isNumberValue=function(e){return/^[-+]?\d*\.?\d+$/.test(e)},t.prototype.checkPositionData=function(){if(!m(this.position)){if(!m(this.position.X)&&"number"!=typeof this.position.X&&this.isNumberValue(this.position.X)){var i=this.isProtectedOnChange;this.isProtectedOnChange=!0,this.position.X=parseFloat(this.position.X),this.isProtectedOnChange=i}m(this.position.Y)||"number"==typeof this.position.Y||this.isNumberValue(this.position.Y)&&(i=this.isProtectedOnChange,this.isProtectedOnChange=!0,this.position.Y=parseFloat(this.position.Y),this.isProtectedOnChange=i)}},t.prototype.getEle=function(e,i){for(var r=void 0,s=0;s=0&&t[e])fJ(t[e]);else if(""!==t[e].trim()){var i=mi("div",{className:"e-icons "+_g+" e-"+t[e]});_i.appendChild(i)}ap=n.minHeight,IE=n.minWidth,gh=n.maxWidth,fh=n.maxHeight,n.proxy&&n.proxy.element&&n.proxy.element.classList.contains("e-dialog")?c4(n.proxy):c4()}({element:this.element,direction:r,minHeight:parseInt(e.slice(0,i.indexOf("p")),10),maxHeight:this.targetEle.clientHeight,minWidth:parseInt(i.slice(0,i.indexOf("p")),10),maxWidth:this.targetEle.clientWidth,boundary:this.target===document.body?null:this.targetEle,resizeBegin:this.onResizeStart.bind(this),resizeComplete:this.onResizeComplete.bind(this),resizing:this.onResizing.bind(this),proxy:this}),this.wireWindowResizeEvent()}else f4(),this.unWireWindowResizeEvent(),this.element.classList.remove(this.isModal?lp:C4),this.element.classList.remove(OE)},t.prototype.getFocusElement=function(e){var r=e.querySelectorAll('input,select,textarea,button:enabled,a,[contenteditable="true"],[tabindex]');return{element:r[r.length-1]}},t.prototype.keyDown=function(e){var i=this;if(9===e.keyCode&&this.isModal){var r=void 0;m(this.btnObj)||(r=this.btnObj[this.btnObj.length-1]),m(this.btnObj)&&!m(this.ftrTemplateContent)&&(r=this.getFocusElement(this.ftrTemplateContent)),m(this.btnObj)&&m(this.ftrTemplateContent)&&!m(this.contentEle)&&(r=this.getFocusElement(this.contentEle)),!m(r)&&document.activeElement===r.element&&!e.shiftKey&&(e.preventDefault(),this.focusableElements(this.element).focus()),document.activeElement===this.focusableElements(this.element)&&e.shiftKey&&(e.preventDefault(),m(r)||r.element.focus())}var h,s=document.activeElement,o=["input","textarea"].indexOf(s.tagName.toLowerCase())>-1,a=!1;if(o||(a=s.hasAttribute("contenteditable")&&"true"===s.getAttribute("contenteditable")),27===e.keyCode&&this.closeOnEscape){this.dlgClosedBy="escape";var l=document.querySelector(".e-popup-open:not(.e-dialog)");!m(l)&&!l.classList.contains("e-toolbar-pop")||this.hide(e)}(13===e.keyCode&&!e.ctrlKey&&"textarea"!==s.tagName.toLowerCase()&&o&&!m(this.primaryButtonEle)||13===e.keyCode&&e.ctrlKey&&("textarea"===s.tagName.toLowerCase()||a)&&!m(this.primaryButtonEle))&&this.buttons.some(function(d,u){h=u;var p=d.buttonModel;return!m(p)&&!0===p.isPrimary})&&"function"==typeof this.buttons[h].click&&setTimeout(function(){i.buttons[h].click.call(i,e)})},t.prototype.initialize=function(){m(this.target)||(this.targetEle="string"==typeof this.target?document.querySelector(this.target):this.target),this.isBlazorServerRender()||V([this.element],F0),X.isDevice&&V([this.element],m4),this.isBlazorServerRender()||this.setCSSClass(),this.setMaxHeight()},t.prototype.initRender=function(){var e=this;if(this.initialRender=!0,this.isBlazorServerRender()||Fe(this.element,{role:"dialog"}),1e3===this.zIndex?(this.setzIndex(this.element,!1),this.calculatezIndex=!0):this.calculatezIndex=!1,this.setTargetContent(),""!==this.header&&!m(this.header)&&this.setHeader(),this.renderCloseIcon(),this.setContent(),""===this.footerTemplate||m(this.footerTemplate)?!m(this.buttons[0])&&!m(this.buttons[0].buttonModel)&&this.setButton():this.setFooterTemplate(),this.allowDragging&&!m(this.headerContent)&&this.setAllowDragging(),Fe(this.element,{"aria-modal":this.isModal?"true":"false"}),this.isModal&&this.setIsModal(),!0!==this.element.classList.contains(M4)&&!0!==this.element.classList.contains(w4)&&!m(this.element.parentElement)){var i=this.isModal?this.dlgContainer.parentElement:this.element.parentElement;this.refElement=this.createElement("div",{className:"e-dlg-ref-element"}),i.insertBefore(this.refElement,this.isModal?this.dlgContainer:this.element)}if(m(this.targetEle)||this.targetEle.appendChild(this.isModal?this.dlgContainer:this.element),this.popupObj=new ac(this.element,{height:this.height,width:this.width,zIndex:this.zIndex,relateTo:this.target,actionOnScroll:"none",enableRtl:this.enableRtl,open:function(o){var a={container:e.isModal?e.dlgContainer:e.element,element:e.element,target:e.target,preventFocus:!1};e.enableResize&&e.resetResizeIcon(),e.trigger("open",a,function(l){l.preventFocus||e.focusContent()})},close:function(o){e.isModal&&V([e.dlgOverlay],"e-fade"),e.unBindEvent(e.element),e.isModal&&(e.dlgContainer.style.display="none"),e.trigger("close",e.closeArgs);var a=document.activeElement;!m(a)&&!m(a.blur)&&a.blur(),!m(e.storeActiveElement)&&!m(e.storeActiveElement.focus)&&e.storeActiveElement.focus()}}),this.positionChange(),this.setEnableRTL(),this.isBlazorServerRender()||(V([this.element],"e-popup-close"),this.isModal&&this.setOverlayZindex()),this.visible){if(this.show(),this.isModal){var r=this.getTargetContainer(this.target);r instanceof Element&&"rtl"===window.getComputedStyle(r).getPropertyValue("direction")&&this.setPopupPosition()}}else this.isModal&&(this.dlgOverlay.style.display="none");this.initialRender=!1},t.prototype.getTargetContainer=function(e){var i=null;if("string"==typeof e)if(e.startsWith("#"))i=document.getElementById(e.substring(1));else if(e.startsWith(".")){var r=document.getElementsByClassName(e.substring(1));i=r.length>0?r[0]:null}else!(e instanceof HTMLElement)&&e!==document.body&&(i=document.querySelector(e));else e instanceof HTMLElement&&(i=e);return i},t.prototype.resetResizeIcon=function(){var e=this.getMinHeight();if(this.targetEle.offsetHeight0&&("function"==typeof this.buttons[e].click&&E.add(s[e],"click",this.buttons[e].click,this),"object"==typeof this.buttons[e].click&&E.add(s[e],"click",this.buttonClickHandler.bind(this,e),this)),!this.isBlazorServerRender()&&!m(this.ftrTemplateContent)&&(this.btnObj[e].appendTo(this.ftrTemplateContent.children[e]),this.buttons[e].isFlat&&this.btnObj[e].element.classList.add("e-flat"),this.primaryButtonEle=this.element.getElementsByClassName("e-primary")[0]))},t.prototype.buttonClickHandler=function(e){this.trigger("buttons["+e+"].click",{})},t.prototype.setContent=function(){this.contentEle=this.createElement("div",{className:"e-dlg-content",id:this.element.id+"_dialog-content"}),Fe(this.element,this.headerEle?{"aria-describedby":this.element.id+"_title "+this.element.id+"_dialog-content"}:{"aria-describedby":this.element.id+"_dialog-content"}),this.innerContentElement?this.contentEle.appendChild(this.innerContentElement):(!m(this.content)&&""!==this.content||!this.initialRender)&&(("string"!=typeof this.content||ce())&&this.content instanceof HTMLElement?this.contentEle.appendChild(this.content):this.setTemplate(this.content,this.contentEle,"content")),m(this.headerContent)?this.element.insertBefore(this.contentEle,this.element.children[0]):this.element.insertBefore(this.contentEle,this.element.children[1]),"auto"===this.height&&(!this.isBlazorServerRender()&&X.isIE&&""===this.element.style.width&&!m(this.width)&&(this.element.style.width=Re(this.width)),this.setMaxHeight())},t.prototype.setTemplate=function(e,i,r){var s,o,a;o=i.classList.contains(g4)?this.element.id+"header":i.classList.contains(_0)?this.element.id+"footerTemplate":this.element.id+"content",m(e.outerHTML)?("string"==typeof e||"string"!=typeof e||ce()&&!this.isStringTemplate)&&("string"==typeof e&&(e=this.sanitizeHelper(e)),this.isVue||"string"!=typeof e?(s=ii(e),a=e):i.innerHTML=e):i.appendChild(e);var l=[];if(!m(s)){for(var c=0,d=s({},this,r,o,!(ce()&&!this.isStringTemplate&&0===a.indexOf("
Blazor"))||this.isStringTemplate);c/g,"");(this.element.children.length>0||i)&&(this.innerContentElement=document.createDocumentFragment(),[].slice.call(this.element.childNodes).forEach(function(r){8!==r.nodeType&&e.innerContentElement.appendChild(r)}))}},t.prototype.setHeader=function(){this.headerEle?this.headerEle.innerHTML="":this.headerEle=this.createElement("div",{id:this.element.id+"_title",className:g4}),this.createHeaderContent(),this.headerContent.appendChild(this.headerEle),this.setTemplate(this.header,this.headerEle,"header"),Fe(this.element,{"aria-describedby":this.element.id+"_title"}),Fe(this.element,{"aria-labelledby":this.element.id+"_dialog-header"}),this.element.insertBefore(this.headerContent,this.element.children[0]),this.allowDragging&&!m(this.headerContent)&&this.setAllowDragging()},t.prototype.setFooterTemplate=function(){this.ftrTemplateContent?this.ftrTemplateContent.innerHTML="":this.ftrTemplateContent=this.createElement("div",{className:_0}),""===this.footerTemplate||m(this.footerTemplate)?this.ftrTemplateContent.innerHTML=this.buttonContent.join(""):this.setTemplate(this.footerTemplate,this.ftrTemplateContent,"footerTemplate"),this.element.appendChild(this.ftrTemplateContent)},t.prototype.createHeaderContent=function(){m(this.headerContent)&&(this.headerContent=this.createElement("div",{id:this.element.id+"_dialog-header",className:NE}))},t.prototype.renderCloseIcon=function(){this.showCloseIcon&&(this.closeIcon=this.createElement("button",{className:y4,attrs:{type:"button"}}),this.closeIconBtnObj=new ys({cssClass:"e-flat",iconCss:v4+" e-icons"}),this.closeIconTitle(),m(this.headerContent)?(this.createHeaderContent(),pl([this.closeIcon],this.headerContent),this.element.insertBefore(this.headerContent,this.element.children[0])):pl([this.closeIcon],this.headerContent),this.closeIconBtnObj.appendTo(this.closeIcon))},t.prototype.closeIconTitle=function(){this.l10n.setLocale(this.locale);var e=this.l10n.getConstant("close");this.closeIcon.setAttribute("title",e),this.closeIcon.setAttribute("aria-label",e)},t.prototype.setCSSClass=function(e){e&&(K([this.element],e.split(" ")),this.isModal&&!m(this.dlgContainer)&&K([this.dlgContainer],e.split(" "))),this.cssClass&&(V([this.element],this.cssClass.split(" ")),this.isModal&&!m(this.dlgContainer)&&V([this.dlgContainer],this.cssClass.split(" ")))},t.prototype.setIsModal=function(){this.dlgContainer=this.createElement("div",{className:"e-dlg-container"}),this.setCSSClass(),this.element.classList.remove(S4),this.element.parentNode.insertBefore(this.dlgContainer,this.element),this.dlgContainer.appendChild(this.element),V([this.element],U0),this.dlgOverlay=this.createElement("div",{className:"e-dlg-overlay"}),this.dlgOverlay.style.zIndex=(this.zIndex-1).toString(),this.dlgContainer.appendChild(this.dlgOverlay)},t.prototype.getValidFocusNode=function(e){for(var i,r=0;r0||"a"===i.tagName.toLowerCase()&&i.hasAttribute("href"))&&i.tabIndex>-1&&!i.disabled&&!this.disableElement(i,'[disabled],[aria-disabled="true"],[type="hidden"]'))return i;i=null}return i},t.prototype.focusableElements=function(e){if(!m(e)){var r=e.querySelectorAll('input,select,textarea,button,a,[contenteditable="true"],[tabindex]');return this.getValidFocusNode(r)}return null},t.prototype.getAutoFocusNode=function(e){var i=e.querySelector("."+y4),s=e.querySelectorAll("[autofocus]"),o=this.getValidFocusNode(s);if(ce()&&(this.primaryButtonEle=this.element.getElementsByClassName("e-primary")[0]),m(o)){if(!m(o=this.focusableElements(this.contentEle)))return o;if(!m(this.primaryButtonEle))return this.element.querySelector(".e-primary")}else i=o;return i},t.prototype.disableElement=function(e,i){var r=e?e.matches||e.webkitMatchesSelector||e.msGetRegionContent:null;if(r)for(;e;e=e.parentNode)if(e instanceof Element&&r.call(e,i))return e;return null},t.prototype.focusContent=function(){var e=this.getAutoFocusNode(this.element),i=m(e)?this.element:e,r=X.userAgent;(r.indexOf("MSIE ")>0||r.indexOf("Trident/")>0)&&this.element.focus(),i.focus(),this.unBindEvent(this.element),this.bindEvent(this.element)},t.prototype.bindEvent=function(e){E.add(e,"keydown",this.keyDown,this)},t.prototype.unBindEvent=function(e){E.remove(e,"keydown",this.keyDown)},t.prototype.updateSanitizeContent=function(){this.isBlazorServerRender()||(this.contentEle.innerHTML=this.sanitizeHelper(this.content))},t.prototype.isBlazorServerRender=function(){return ce()&&this.isServerRendered},t.prototype.getModuleName=function(){return"dialog"},t.prototype.onPropertyChanged=function(e,i){if(this.element.classList.contains(F0))for(var r=0,s=Object.keys(e);r0?this.showCloseIcon||""!==this.header&&!m(this.header)?this.showCloseIcon||he(this.closeIcon):(he(this.headerContent),this.headerContent=null):(this.renderCloseIcon(),this.wireEvents());break;case"locale":this.showCloseIcon&&this.closeIconTitle();break;case"visible":this.visible?this.show():this.hide();break;case"isModal":this.updateIsModal();break;case"height":je(this.element,{height:Re(e.height)}),this.updatePersistData();break;case"width":je(this.element,{width:Re(e.width)}),this.updatePersistData();break;case"zIndex":this.popupObj.zIndex=this.zIndex,this.isModal&&this.setOverlayZindex(this.zIndex),this.element.style.zIndex!==this.zIndex.toString()&&(this.calculatezIndex=!1);break;case"cssClass":this.setCSSClass(i.cssClass);break;case"buttons":this.unWireButtonEvents(),this.destroyButtons(),m(this.ftrTemplateContent)||(he(this.ftrTemplateContent),this.ftrTemplateContent=null),this.footerTemplate="",this.setButton();break;case"allowDragging":this.allowDragging&&!m(this.headerContent)?this.setAllowDragging():this.dragObj.destroy();break;case"target":this.setTarget(e.target);break;case"position":if(this.checkPositionData(),this.isModal){var a=this.position.X,l=this.position.Y;m(i.position)||(m(i.position.X)||(a=i.position.X),m(i.position.Y)||(l=i.position.Y)),this.dlgContainer.classList.contains("e-dlg-"+a+"-"+l)&&this.dlgContainer.classList.remove("e-dlg-"+a+"-"+l)}this.positionChange(),this.updatePersistData();break;case"enableRtl":this.setEnableRTL();break;case"enableResize":this.setResize();break;case"minHeight":""!==this.minHeight&&(this.element.style.minHeight=Re(this.minHeight))}},t.prototype.setTarget=function(e){this.popupObj.relateTo=e,this.target=e,this.targetEle="string"==typeof this.target?document.querySelector(this.target):this.target,this.dragObj&&(this.dragObj.dragArea=this.targetEle),this.setMaxHeight(),this.isModal&&this.updateIsModal(),this.enableResize&&this.setResize()},t.prototype.updateIsModal=function(){if(this.element.setAttribute("aria-modal",this.isModal?"true":"false"),this.isModal)m(this.dlgOverlay)&&(this.setIsModal(),this.element.style.top="0px",this.element.style.left="0px",m(this.targetEle)||this.targetEle.appendChild(this.dlgContainer));else{for(K([this.element],U0),K([document.body],[ml,ka]),he(this.dlgOverlay);this.dlgContainer.firstChild;)this.dlgContainer.parentElement.insertBefore(this.dlgContainer.firstChild,this.dlgContainer);this.dlgContainer.parentElement.removeChild(this.dlgContainer)}this.visible&&this.show(),this.positionChange(),this.isModal&&this.dlgOverlay&&E.add(this.dlgOverlay,"click",this.dlgOverlayClickEventHandler,this)},t.prototype.setzIndex=function(e,i){var r=this.isProtectedOnChange;this.isProtectedOnChange=!0;var s=lc(e);this.zIndex=s>this.zIndex?s:this.zIndex,this.isProtectedOnChange=r,i&&(this.popupObj.zIndex=this.zIndex)},t.prototype.windowResizeHandler=function(){(function vJ(n){gh=n})(this.targetEle.clientWidth),function mJ(n){fh=n}(this.targetEle.clientHeight),this.setMaxHeight()},t.prototype.getPersistData=function(){return this.addOnPersist(["width","height","position"])},t.prototype.removeAllChildren=function(e){for(;e.children[0];)this.removeAllChildren(e.children[0]),e.removeChild(e.children[0])},t.prototype.destroy=function(){if(!this.isDestroyed){var e=[LE,U0,OE,lp,j0,m4],i=["role","aria-modal","aria-labelledby","aria-describedby","aria-grabbed","tabindex","style"];K([this.targetEle],[ml,ka]),!m(this.element)&&this.element.classList.contains(j0)&&K([document.body],[ml,ka]),this.isModal&&K([m(this.targetEle)?document.body:this.targetEle],ka),this.unWireEvents(),this.unWireButtonEvents(),this.destroyButtons(),m(this.closeIconBtnObj)||this.closeIconBtnObj.destroy(),m(this.dragObj)||this.dragObj.destroy(),!m(this.popupObj.element)&&this.popupObj.element.classList.contains("e-popup")&&this.popupObj.destroy(),K([this.element],e),!m(this.cssClass)&&""!==this.cssClass&&K([this.element],this.cssClass.split(" ")),!m(this.refElement)&&!m(this.refElement.parentElement)&&(this.refElement.parentElement.insertBefore(this.isModal?this.dlgContainer:this.element,this.refElement),he(this.refElement),this.refElement=void 0),this.isModal&&(he(this.dlgOverlay),this.dlgContainer.parentNode.insertBefore(this.element,this.dlgContainer),he(this.dlgContainer)),this.element.innerHTML=this.clonedEle.innerHTML;for(var r=0;r0&&""===this.footerTemplate&&this.ftrTemplateContent)for(var e=0;e=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},PE="e-tooltip",L4="e-icons",N4="e-tooltip-close",zE="e-tooltip-wrap",O4="e-tip-content",hp="e-arrow-tip",k4="e-arrow-tip-outer",V0="e-arrow-tip-inner",Yg="e-tip-bottom",RE="e-tip-top",P4="e-tip-left",HE="e-tip-right",BE="e-popup",Qg="e-popup-open",FE="e-popup-close",W0="e-lib",z4="e-tooltip-popup-container",FJ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return D4(t,n),Gi([I({effect:"FadeIn",duration:150,delay:0})],t.prototype,"open",void 0),Gi([I({effect:"FadeOut",duration:150,delay:0})],t.prototype,"close",void 0),t}(Ee),mh=function(n){function t(e,i){var r=n.call(this,e,i)||this;return r.mouseMoveEvent=null,r.mouseMoveTarget=null,r.containerElement=null,r.isBodyContainer=!0,r}return D4(t,n),t.prototype.initialize=function(){this.formatPosition(),V([this.element],PE)},t.prototype.formatPosition=function(){var e,i;this.position&&(0===this.position.indexOf("Top")||0===this.position.indexOf("Bottom")?(e=this.position.split(/(?=[A-Z])/),this.tooltipPositionY=e[0],this.tooltipPositionX=e[1]):(i=this.position.split(/(?=[A-Z])/),this.tooltipPositionX=i[0],this.tooltipPositionY=i[1]))},t.prototype.renderArrow=function(){this.setTipClass(this.position);var e=this.createElement("div",{className:hp+" "+this.tipClass});e.appendChild(this.createElement("div",{className:k4+" "+this.tipClass})),e.appendChild(this.createElement("div",{className:V0+" "+this.tipClass})),this.tooltipEle.appendChild(e)},t.prototype.setTipClass=function(e){this.tipClass=0===e.indexOf("Right")?P4:0===e.indexOf("Bottom")?RE:0===e.indexOf("Left")?HE:Yg},t.prototype.renderPopup=function(e){var i=this.mouseTrail?{top:0,left:0}:this.getTooltipPosition(e);this.tooltipEle.classList.remove(W0),this.popupObj=new ac(this.tooltipEle,{height:this.height,width:this.width,position:{X:i.left,Y:i.top},enableRtl:this.enableRtl,open:this.openPopupHandler.bind(this),close:this.closePopupHandler.bind(this)})},t.prototype.getScalingFactor=function(e){if(!e)return{x:1,y:1};var i={x:1,y:1},r=e.closest('[style*="transform: scale"]');if(r&&r!==this.tooltipEle&&r.contains(this.tooltipEle)){var a=window.getComputedStyle(r).getPropertyValue("transform").match(/matrix\(([^)]+)\)/)[1].split(",").map(parseFloat);i.x=a[0],i.y=a[3]}return i},t.prototype.getTooltipPosition=function(e){this.tooltipEle.style.display="block";var i=this.element.closest('[style*="zoom"]');i&&(i.contains(this.tooltipEle)||(this.tooltipEle.style.zoom=getComputedStyle(i).zoom));var r=is(e,this.tooltipPositionX,this.tooltipPositionY,!this.isBodyContainer,this.isBodyContainer?null:this.containerElement.getBoundingClientRect()),s=this.getScalingFactor(e),o=this.calculateTooltipOffset(this.position,s.x,s.y),a=this.calculateElementPosition(r,o),c=this.collisionFlipFit(e,a[0],a[1]);return c.left=c.left/s.x,c.top=c.top/s.y,this.tooltipEle.style.display="",c},t.prototype.windowResize=function(){this.reposition(this.findTarget())},t.prototype.reposition=function(e){if(this.popupObj&&e){var i=this.getTooltipPosition(e);this.popupObj.position={X:i.left,Y:i.top},this.popupObj.dataBind()}},t.prototype.openPopupHandler=function(){!this.mouseTrail&&this.needTemplateReposition()&&this.reposition(this.findTarget()),this.trigger("afterOpen",this.tooltipEventArgs),this.tooltipEventArgs=null},t.prototype.closePopupHandler=function(){this.isReact&&!("Click"===this.opensOn||"function"==typeof this.content)&&this.clearTemplate(["content"]),this.clear();var e={type:this.tooltipEventArgs.event?this.tooltipEventArgs.event.type:null,cancel:!1,target:this.tooltipEventArgs.target,event:this.tooltipEventArgs.event?this.tooltipEventArgs.event:null,element:this.tooltipEle,isInteracted:!m(this.tooltipEventArgs.event)};this.trigger("afterClose",e),e=null},t.prototype.calculateTooltipOffset=function(e,i,r){void 0===i&&(i=1),void 0===r&&(r=1);var o,a,l,h,c,d,u,p,s={top:0,left:0};if(1!==i||1!==r){var f=this.tooltipEle.getBoundingClientRect(),g=void 0;l=Math.round(f.width),h=Math.round(f.height),(c=U("."+hp,this.tooltipEle))&&(g=c.getBoundingClientRect()),o=c?Math.round(g.width):0,a=c?Math.round(g.height):0,d=this.showTipPointer?0:8,u=a/2+2+(h-this.tooltipEle.clientHeight*r),p=o/2+2+(l-this.tooltipEle.clientWidth*i)}else l=this.tooltipEle.offsetWidth,h=this.tooltipEle.offsetHeight,c=U("."+hp,this.tooltipEle),d=this.showTipPointer?0:8,u=(a=c?c.offsetHeight:0)/2+2+(this.tooltipEle.offsetHeight-this.tooltipEle.clientHeight),p=(o=c?c.offsetWidth:0)/2+2+(this.tooltipEle.offsetWidth-this.tooltipEle.clientWidth);switch(this.mouseTrail&&(d+=2),e){case"RightTop":s.left+=o+d,s.top-=h-u;break;case"RightCenter":s.left+=o+d,s.top-=h/2;break;case"RightBottom":s.left+=o+d,s.top-=u;break;case"BottomRight":s.top+=a+d,s.left-=p;break;case"BottomCenter":s.top+=a+d,s.left-=l/2;break;case"BottomLeft":s.top+=a+d,s.left-=l-p;break;case"LeftBottom":s.left-=o+l+d,s.top-=u;break;case"LeftCenter":s.left-=o+l+d,s.top-=h/2;break;case"LeftTop":s.left-=o+l+d,s.top-=h-u;break;case"TopLeft":s.top-=h+a+d,s.left-=l-p;break;case"TopRight":s.top-=h+a+d,s.left-=p;break;default:s.top-=h+a+d,s.left-=l/2}return s.left+=this.offsetX,s.top+=this.offsetY,s},t.prototype.updateTipPosition=function(e){var i=we("."+hp+",."+k4+",."+V0,this.tooltipEle);K(i,[Yg,RE,P4,HE]),this.setTipClass(e),V(i,this.tipClass)},t.prototype.adjustArrow=function(e,i,r,s){var o=U("."+hp,this.tooltipEle);if(!1!==this.showTipPointer&&null!==o){var a,l;this.updateTipPosition(i),this.tooltipEle.style.display="block";var f,h=this.tooltipEle.clientWidth,c=this.tooltipEle.clientHeight,d=U("."+V0,this.tooltipEle),u=o.offsetWidth,p=o.offsetHeight;this.tooltipEle.style.display="",this.tipClass===Yg||this.tipClass===RE?(this.tipClass===Yg?(l="99.9%",d.style.top="-"+(p-2)+"px"):(l=-(p-1)+"px",d.style.top="-"+(p-6)+"px"),e&&(a=(f="Center"!==r||h>e.offsetWidth||this.mouseTrail)&&"Left"===r||!f&&"End"===this.tipPointerPosition?h-u-2+"px":f&&"Right"===r||!f&&"Start"===this.tipPointerPosition?"2px":!f||"End"!==this.tipPointerPosition&&"Start"!==this.tipPointerPosition?h/2-u/2+"px":"End"===this.tipPointerPosition?e.offsetWidth+(this.tooltipEle.offsetWidth-e.offsetWidth)/2-u/2-2+"px":(this.tooltipEle.offsetWidth-e.offsetWidth)/2-u/2+2+"px")):(this.tipClass===HE?(a="99.9%",d.style.left="-"+(u-2)+"px"):(a=-(u-1)+"px",d.style.left=u-2-u+"px"),l=(f="Center"!==s||c>e.offsetHeight||this.mouseTrail)&&"Top"===s||!f&&"End"===this.tipPointerPosition?c-p-2+"px":f&&"Bottom"===s||!f&&"Start"===this.tipPointerPosition?"2px":c/2-p/2+"px"),o.style.top=l,o.style.left=a}},t.prototype.renderContent=function(e){var i=this,r=U("."+O4,this.tooltipEle);if(this.cssClass&&V([this.tooltipEle],this.cssClass.split(" ")),e&&!m(e.getAttribute("title"))&&(e.setAttribute("data-content",e.getAttribute("title")),e.removeAttribute("title")),m(this.content))e&&!m(e.getAttribute("data-content"))&&(r.innerHTML=e.getAttribute("data-content"));else if(r.innerHTML="",this.content instanceof HTMLElement)r.appendChild(this.content);else if("string"==typeof this.content)this.isAngular?this.setProperties({content:Ti.sanitize(this.content)},!0):this.content=this.enableHtmlSanitizer?Ti.sanitize(this.content):this.content,this.enableHtmlParse?(o=ii(this.content)({},this,"content",this.element.id+"content",void 0,void 0,r,this.root))&&Dt(o,r):r.textContent=this.content;else{var o;(o=ii(this.content)({},this,"content",this.element.id+"content",void 0,void 0,r))&&(this.isAngular&&setTimeout(function(){i.reposition(e)},1),Dt(o,r)),this.renderReactTemplates()}},t.prototype.renderCloseIcon=function(){if(this.isSticky){var i=this.createElement("div",{className:L4+" "+N4});this.tooltipEle.appendChild(i),E.add(i,X.touchStartEvent,this.onStickyClose,this)}else{var e=this.tooltipEle.querySelector("."+L4+"."+N4);e&>(e)}},t.prototype.addDescribedBy=function(e,i){var r=(e.getAttribute("aria-describedby")||"").split(/\s+/);r.indexOf(i)<0&&r.push(i),Fe(e,{"aria-describedby":r.join(" ").trim(),"data-tooltip-id":i})},t.prototype.removeDescribedBy=function(e){var i=e.getAttribute("data-tooltip-id"),r=(e.getAttribute("aria-describedby")||"").split(/\s+/),s=r.indexOf(i);-1!==s&&r.splice(s,1),e.removeAttribute("data-tooltip-id");var o=r.join(" ").trim();o?e.setAttribute("aria-describedby",o):e.removeAttribute("aria-describedby")},t.prototype.tapHoldHandler=function(e){clearTimeout(this.autoCloseTimer),this.targetHover(e.originalEvent)},t.prototype.touchEndHandler=function(){var e=this;this.isSticky||(this.autoCloseTimer=setTimeout(function(){e.close()},1500))},t.prototype.targetClick=function(e){var i;!m(i=this.target?J(e.target,this.target):this.element)&&(null===i.getAttribute("data-tooltip-id")?this.targetHover(e):this.isSticky||this.hideTooltip(this.animation.close,e,i))},t.prototype.targetHover=function(e){var i;if(!(m(i=this.target?J(e.target,this.target):this.element)||null!==i.getAttribute("data-tooltip-id")&&0===this.closeDelay)){for(var s=0,o=[].slice.call(we('[data-tooltip-id= "'+this.ctrlId+'_content"]',document));s0?this.showTimer=setTimeout(function(){o.mouseTrail&&E.add(i,"mousemove touchstart mouseenter",o.onMouseMove,o),o.popupObj&&(o.popupObj.show(a,i),o.mouseMoveEvent&&o.mouseTrail&&o.onMouseMove(o.mouseMoveEvent))},this.openDelay):this.popupObj&&this.popupObj.show(a,i)}s&&this.wireMouseEvents(s,i)},t.prototype.needTemplateReposition=function(){return!m(this.viewContainerRef)&&"string"!=typeof this.viewContainerRef||this.isReact},t.prototype.checkCollision=function(e,i,r){var s={left:i,top:r,position:this.position,horizontal:this.tooltipPositionX,vertical:this.tooltipPositionY},o=oc(this.tooltipEle,this.checkCollideTarget(),i,r);return o.length>0&&(s.horizontal=o.indexOf("left")>=0?"Right":o.indexOf("right")>=0?"Left":this.tooltipPositionX,s.vertical=o.indexOf("top")>=0?"Bottom":o.indexOf("bottom")>=0?"Top":this.tooltipPositionY),s},t.prototype.calculateElementPosition=function(e,i){return[this.isBodyContainer?e.left+i.left:e.left-this.containerElement.getBoundingClientRect().left+i.left+window.pageXOffset+this.containerElement.scrollLeft,this.isBodyContainer?e.top+i.top:e.top-this.containerElement.getBoundingClientRect().top+i.top+window.pageYOffset+this.containerElement.scrollTop]},t.prototype.collisionFlipFit=function(e,i,r){var s=this.checkCollision(e,i,r),o=s.position;if(this.tooltipPositionY!==s.vertical&&(o=0===this.position.indexOf("Bottom")||0===this.position.indexOf("Top")?s.vertical+this.tooltipPositionX:this.tooltipPositionX+s.vertical),this.tooltipPositionX!==s.horizontal&&(0===o.indexOf("Left")&&(s.vertical="LeftTop"===o||"LeftCenter"===o?"Top":"Bottom",o=s.vertical+"Left"),0===o.indexOf("Right")&&(s.vertical="RightTop"===o||"RightCenter"===o?"Top":"Bottom",o=s.vertical+"Right"),s.horizontal=this.tooltipPositionX),this.tooltipEventArgs={type:null,cancel:!1,target:e,event:null,element:this.tooltipEle,collidedPosition:o},this.trigger("beforeCollision",this.tooltipEventArgs),this.tooltipEventArgs.cancel)o=this.position;else{var a=s.vertical,l=s.horizontal;if(s.position!==o){var h=is(e,l,a,!this.isBodyContainer,this.isBodyContainer?null:this.containerElement.getBoundingClientRect());this.adjustArrow(e,o,l,a);var c=this.getScalingFactor(e),d=this.calculateTooltipOffset(o,c.x,c.y);d.top-=this.getOffSetPosition("TopBottom",o,this.offsetY),d.left-=this.getOffSetPosition("RightLeft",o,this.offsetX),s.position=o;var u=this.calculateElementPosition(h,d);s.left=u[0],s.top=u[1]}else this.adjustArrow(e,o,l,a)}var p={left:s.left,top:s.top},f=this.isBodyContainer?lE(this.tooltipEle,this.checkCollideTarget(),{X:!0,Y:this.windowCollision},p):p;this.tooltipEle.style.display="block";var g=U("."+hp,this.tooltipEle);if(this.showTipPointer&&null!=g&&(0===o.indexOf("Bottom")||0===o.indexOf("Top"))){var v=parseInt(g.style.left,10)-(f.left-s.left);v<0?v=0:v+g.offsetWidth>this.tooltipEle.clientWidth&&(v=this.tooltipEle.clientWidth-g.offsetWidth),g.style.left=v.toString()+"px"}return this.tooltipEle.style.display="",p.left=f.left,p.top=f.top,p},t.prototype.getOffSetPosition=function(e,i,r){return-1!==e.indexOf(this.position.split(/(?=[A-Z])/)[0])&&-1!==e.indexOf(i.split(/(?=[A-Z])/)[0])?2*r:0},t.prototype.checkCollideTarget=function(){return!this.windowCollision&&this.target?this.element:null},t.prototype.hideTooltip=function(e,i,r){var s=this;this.closeDelay>0?(clearTimeout(this.hideTimer),clearTimeout(this.showTimer),this.hideTimer=setTimeout(function(){s.closeDelay&&s.tooltipEle&&s.isTooltipOpen||s.tooltipHide(e,i,r)},this.closeDelay)):this.tooltipHide(e,i,r)},t.prototype.tooltipHide=function(e,i,r){var o,s=this;o=i?this.target?r||i.target:this.element:U('[data-tooltip-id= "'+this.ctrlId+'_content"]',document),this.tooltipEventArgs={type:i?i.type:null,cancel:!1,target:o,event:i||null,element:this.tooltipEle,isInteracted:!m(i)},this.trigger("beforeClose",this.tooltipEventArgs,function(a){a.cancel?s.isHidden=!1:(s.mouseMoveBeforeRemove(),s.popupHide(e,o,i))})},t.prototype.popupHide=function(e,i,r){i&&r&&this.restoreElement(i),this.isHidden=!0;var s={name:this.animation.close.effect,duration:e.duration,delay:e.delay,timingFunction:"easeIn"};"None"===e.effect&&(s=void 0),this.popupObj&&this.popupObj.hide(s)},t.prototype.restoreElement=function(e){this.unwireMouseEvents(e),m(e.getAttribute("data-content"))||(e.setAttribute("title",e.getAttribute("data-content")),e.removeAttribute("data-content")),this.removeDescribedBy(e)},t.prototype.clear=function(){var e=this.findTarget();e&&this.restoreElement(e),this.tooltipEle&&(K([this.tooltipEle],FE),V([this.tooltipEle],Qg)),this.isHidden&&(this.popupObj&&this.popupObj.destroy(),this.tooltipEle&>(this.tooltipEle),this.tooltipEle=null,this.popupObj=null)},t.prototype.tooltipHover=function(){this.tooltipEle&&(this.isTooltipOpen=!0)},t.prototype.tooltipMouseOut=function(e){this.isTooltipOpen=!1,this.hideTooltip(this.animation.close,e,this.findTarget())},t.prototype.onMouseOut=function(e){var i=e.relatedTarget;if(i&&!this.mouseTrail){var r=J(i,"."+zE+"."+W0+"."+BE);r?E.add(r,"mouseleave",this.tooltipElementMouseOut,this):(this.hideTooltip(this.animation.close,e,this.findTarget()),0===this.closeDelay&&("None"===this.animation.close.effect||this.isReact&&"string"!=typeof this.content)&&this.clear())}else this.hideTooltip(this.animation.close,e,this.findTarget()),this.clear();this.popupObj&&!this.popupObj.element.classList.contains(Qg)&&this.clear()},t.prototype.tooltipElementMouseOut=function(e){this.hideTooltip(this.animation.close,e,this.findTarget()),E.remove(this.element,"mouseleave",this.tooltipElementMouseOut),this.clear()},t.prototype.onStickyClose=function(){this.close()},t.prototype.onMouseMove=function(e){var i=0,r=0;e.type.indexOf("touch")>-1?(e.preventDefault(),i=e.touches[0].pageX,r=e.touches[0].pageY):(i=e.pageX,r=e.pageY),Hs.stop(this.tooltipEle),K([this.tooltipEle],FE),V([this.tooltipEle],Qg),this.adjustArrow(e.target,this.position,this.tooltipPositionX,this.tooltipPositionY);var s=this.getScalingFactor(e.target),o=this.calculateTooltipOffset(this.position,s.x,s.y),h=this.checkCollision(e.target,i+o.left+this.offsetX,r+o.top+this.offsetY);if(this.tooltipPositionX!==h.horizontal||this.tooltipPositionY!==h.vertical){var c=0===this.position.indexOf("Bottom")||0===this.position.indexOf("Top")?h.vertical+h.horizontal:h.horizontal+h.vertical;h.position=c,this.adjustArrow(e.target,h.position,h.horizontal,h.vertical);var d=this.calculateTooltipOffset(h.position,s.x,s.y);h.left=i+d.left-this.offsetX,h.top=r+d.top-this.offsetY}this.tooltipEle.style.left=h.left+"px",this.tooltipEle.style.top=h.top+"px"},t.prototype.keyDown=function(e){this.tooltipEle&&27===e.keyCode&&this.close()},t.prototype.touchEnd=function(e){this.tooltipEle&&null===J(e.target,"."+PE)&&!this.isSticky&&this.close()},t.prototype.scrollHandler=function(e){this.tooltipEle&&!this.isSticky&&!J(e.target,"."+zE+"."+W0+"."+BE)&&!this.isSticky&&this.close()},t.prototype.render=function(){this.initialize(),this.wireEvents(this.opensOn),this.renderComplete()},t.prototype.preRender=function(){this.tipClass=Yg,this.tooltipPositionX="Center",this.tooltipPositionY="Top",this.isHidden=!0},t.prototype.wireEvents=function(e){for(var r=0,s=this.getTriggerList(e);r0)for(var i=0,r=e;i0)for(var i=0,r=e;i0&&this.condition&&-1!==this.condition.indexOf("not")&&(e[s].condition=e[s].condition?e[s].condition+"not":"not"),i=e[s].validate(t),r){if(!i)return!1}else if(i)return!0;return r},n.prototype.toJson=function(){var t,e;if(this.isComplex){t=[],e=this.predicates;for(var i=0;ie.length-3?(e=e.substring(0,e.length-1),n.endsWith(n.toLowerCase(t),n.toLowerCase(e))):(e.lastIndexOf("%")!==e.indexOf("%")&&e.lastIndexOf("%")>e.indexOf("%")+1&&(e=e.substring(e.indexOf("%")+1,e.lastIndexOf("%"))),-1!==t.indexOf(e)))},n.fnSort=function(t){return"ascending"===(t=t?n.toLowerCase(t):"ascending")?this.fnAscending:this.fnDescending},n.fnAscending=function(t,e){return m(t)&&m(e)||null==e?-1:"string"==typeof t?t.localeCompare(e):null==t?1:t-e},n.fnDescending=function(t,e){return m(t)&&m(e)?-1:null==e?1:"string"==typeof t?-1*t.localeCompare(e):null==t?-1:e-t},n.extractFields=function(t,e){for(var i={},r=0;r0||e.length>0;)o=t.length>0&&e.length>0?r?r(this.getVal(t,0,i),this.getVal(e,0,i),t[0],e[0])<=0?t:e:t[0][i]0?t:e,s.push(o.shift());return s},n.getVal=function(t,e,i){return i?this.getObject(i,t[e]):t[e]},n.toLowerCase=function(t){return t?"string"==typeof t?t.toLowerCase():t.toString():0===t||!1===t?t.toString():""},n.callAdaptorFunction=function(t,e,i,r){if(e in t){var s=t[e](i,r);m(s)||(i=s)}return i},n.getAddParams=function(t,e,i){var r={};return n.callAdaptorFunction(t,"addParams",{dm:e,query:i,params:i?i.params:[],reqParams:r}),r},n.isPlainObject=function(t){return!!t&&t.constructor===Object},n.isCors=function(){var t=null;try{t=new window.XMLHttpRequest}catch{}return!!t&&"withCredentials"in t},n.getGuid=function(t){var i;return(t||"")+"00000000-0000-4000-0000-000000000000".replace(/0/g,function(r,s){if("crypto"in window&&"getRandomValues"in crypto){var o=new Uint8Array(1);window.crypto.getRandomValues(o),i=o[0]%16|0}else i=16*Math.random()|0;return"0123456789abcdef"[19===s?3&i|8:i]})},n.isNull=function(t){return null==t},n.getItemFromComparer=function(t,e,i){var r,s,o,a=0,l="string"==typeof n.getVal(t,0,e);if(t.length)for(;m(r)&&a0&&(r=s,o=t[a]));return o},n.distinct=function(t,e,i){i=!m(i)&&i;var s,r=[],o={};return t.forEach(function(a,l){(s="object"==typeof t[l]?n.getVal(t,l,e):t[l])in o||(r.push(i?t[l]:s),o[s]=1)}),r},n.processData=function(t,e){var i=this.prepareQuery(t),r=new nt(e);t.requiresCounts&&i.requiresCount();var s=r.executeLocal(i),o={result:t.requiresCounts?s.result:s,count:s.count,aggregates:JSON.stringify(s.aggregates)};return t.requiresCounts?o:s},n.prepareQuery=function(t){var e=this,i=new _t;return t.select&&i.select(t.select),t.where&&n.parse.parseJson(t.where).filter(function(o){if(m(o.condition))i.where(o.field,o.operator,o.value,o.ignoreCase,o.ignoreAccent);else{var a=[];o.field?a.push(new Ss(o.field,o.operator,o.value,o.ignoreCase,o.ignoreAccent)):a=a.concat(e.getPredicate(o.predicates)),"or"===o.condition?i.where(Ss.or(a)):"and"===o.condition&&i.where(Ss.and(a))}}),t.search&&n.parse.parseJson(t.search).filter(function(o){return i.search(o.key,o.fields,o.operator,o.ignoreCase,o.ignoreAccent)}),t.aggregates&&t.aggregates.filter(function(o){return i.aggregate(o.type,o.field)}),t.sorted&&t.sorted.filter(function(o){return i.sortBy(o.name,o.direction)}),t.skip&&i.skip(t.skip),t.take&&i.take(t.take),t.group&&t.group.filter(function(o){return i.group(o)}),i},n.getPredicate=function(t){for(var e=[],i=0;i":"greaterthan","<=":"lessthanorequal",">=":"greaterthanorequal","==":"equal","!=":"notequal","*=":"contains","$=":"endswith","^=":"startswith"},n.odBiOperator={"<":" lt ",">":" gt ","<=":" le ",">=":" ge ","==":" eq ","!=":" ne ",lessthan:" lt ",lessthanorequal:" le ",greaterthan:" gt ",greaterthanorequal:" ge ",equal:" eq ",notequal:" ne "},n.odUniOperator={"$=":"endswith","^=":"startswith","*=":"substringof",endswith:"endswith",startswith:"startswith",contains:"substringof",doesnotendwith:"not endswith",doesnotstartwith:"not startswith",doesnotcontain:"not substringof",wildcard:"wildcard",like:"like"},n.odv4UniOperator={"$=":"endswith","^=":"startswith","*=":"contains",endswith:"endswith",startswith:"startswith",contains:"contains",doesnotendwith:"not endswith",doesnotstartwith:"not startswith",doesnotcontain:"not contains",wildcard:"wildcard",like:"like"},n.diacritics={"\u24b6":"A",\uff21:"A",\u00c0:"A",\u00c1:"A",\u00c2:"A",\u1ea6:"A",\u1ea4:"A",\u1eaa:"A",\u1ea8:"A",\u00c3:"A",\u0100:"A",\u0102:"A",\u1eb0:"A",\u1eae:"A",\u1eb4:"A",\u1eb2:"A",\u0226:"A",\u01e0:"A",\u00c4:"A",\u01de:"A",\u1ea2:"A",\u00c5:"A",\u01fa:"A",\u01cd:"A",\u0200:"A",\u0202:"A",\u1ea0:"A",\u1eac:"A",\u1eb6:"A",\u1e00:"A",\u0104:"A",\u023a:"A",\u2c6f:"A",\ua732:"AA",\u00c6:"AE",\u01fc:"AE",\u01e2:"AE",\ua734:"AO",\ua736:"AU",\ua738:"AV",\ua73a:"AV",\ua73c:"AY","\u24b7":"B",\uff22:"B",\u1e02:"B",\u1e04:"B",\u1e06:"B",\u0243:"B",\u0182:"B",\u0181:"B","\u24b8":"C",\uff23:"C",\u0106:"C",\u0108:"C",\u010a:"C",\u010c:"C",\u00c7:"C",\u1e08:"C",\u0187:"C",\u023b:"C",\ua73e:"C","\u24b9":"D",\uff24:"D",\u1e0a:"D",\u010e:"D",\u1e0c:"D",\u1e10:"D",\u1e12:"D",\u1e0e:"D",\u0110:"D",\u018b:"D",\u018a:"D",\u0189:"D",\ua779:"D",\u01f1:"DZ",\u01c4:"DZ",\u01f2:"Dz",\u01c5:"Dz","\u24ba":"E",\uff25:"E",\u00c8:"E",\u00c9:"E",\u00ca:"E",\u1ec0:"E",\u1ebe:"E",\u1ec4:"E",\u1ec2:"E",\u1ebc:"E",\u0112:"E",\u1e14:"E",\u1e16:"E",\u0114:"E",\u0116:"E",\u00cb:"E",\u1eba:"E",\u011a:"E",\u0204:"E",\u0206:"E",\u1eb8:"E",\u1ec6:"E",\u0228:"E",\u1e1c:"E",\u0118:"E",\u1e18:"E",\u1e1a:"E",\u0190:"E",\u018e:"E","\u24bb":"F",\uff26:"F",\u1e1e:"F",\u0191:"F",\ua77b:"F","\u24bc":"G",\uff27:"G",\u01f4:"G",\u011c:"G",\u1e20:"G",\u011e:"G",\u0120:"G",\u01e6:"G",\u0122:"G",\u01e4:"G",\u0193:"G",\ua7a0:"G",\ua77d:"G",\ua77e:"G","\u24bd":"H",\uff28:"H",\u0124:"H",\u1e22:"H",\u1e26:"H",\u021e:"H",\u1e24:"H",\u1e28:"H",\u1e2a:"H",\u0126:"H",\u2c67:"H",\u2c75:"H",\ua78d:"H","\u24be":"I",\uff29:"I",\u00cc:"I",\u00cd:"I",\u00ce:"I",\u0128:"I",\u012a:"I",\u012c:"I",\u0130:"I",\u00cf:"I",\u1e2e:"I",\u1ec8:"I",\u01cf:"I",\u0208:"I",\u020a:"I",\u1eca:"I",\u012e:"I",\u1e2c:"I",\u0197:"I","\u24bf":"J",\uff2a:"J",\u0134:"J",\u0248:"J","\u24c0":"K",\uff2b:"K",\u1e30:"K",\u01e8:"K",\u1e32:"K",\u0136:"K",\u1e34:"K",\u0198:"K",\u2c69:"K",\ua740:"K",\ua742:"K",\ua744:"K",\ua7a2:"K","\u24c1":"L",\uff2c:"L",\u013f:"L",\u0139:"L",\u013d:"L",\u1e36:"L",\u1e38:"L",\u013b:"L",\u1e3c:"L",\u1e3a:"L",\u0141:"L",\u023d:"L",\u2c62:"L",\u2c60:"L",\ua748:"L",\ua746:"L",\ua780:"L",\u01c7:"LJ",\u01c8:"Lj","\u24c2":"M",\uff2d:"M",\u1e3e:"M",\u1e40:"M",\u1e42:"M",\u2c6e:"M",\u019c:"M","\u24c3":"N",\uff2e:"N",\u01f8:"N",\u0143:"N",\u00d1:"N",\u1e44:"N",\u0147:"N",\u1e46:"N",\u0145:"N",\u1e4a:"N",\u1e48:"N",\u0220:"N",\u019d:"N",\ua790:"N",\ua7a4:"N",\u01ca:"NJ",\u01cb:"Nj","\u24c4":"O",\uff2f:"O",\u00d2:"O",\u00d3:"O",\u00d4:"O",\u1ed2:"O",\u1ed0:"O",\u1ed6:"O",\u1ed4:"O",\u00d5:"O",\u1e4c:"O",\u022c:"O",\u1e4e:"O",\u014c:"O",\u1e50:"O",\u1e52:"O",\u014e:"O",\u022e:"O",\u0230:"O",\u00d6:"O",\u022a:"O",\u1ece:"O",\u0150:"O",\u01d1:"O",\u020c:"O",\u020e:"O",\u01a0:"O",\u1edc:"O",\u1eda:"O",\u1ee0:"O",\u1ede:"O",\u1ee2:"O",\u1ecc:"O",\u1ed8:"O",\u01ea:"O",\u01ec:"O",\u00d8:"O",\u01fe:"O",\u0186:"O",\u019f:"O",\ua74a:"O",\ua74c:"O",\u01a2:"OI",\ua74e:"OO",\u0222:"OU","\u24c5":"P",\uff30:"P",\u1e54:"P",\u1e56:"P",\u01a4:"P",\u2c63:"P",\ua750:"P",\ua752:"P",\ua754:"P","\u24c6":"Q",\uff31:"Q",\ua756:"Q",\ua758:"Q",\u024a:"Q","\u24c7":"R",\uff32:"R",\u0154:"R",\u1e58:"R",\u0158:"R",\u0210:"R",\u0212:"R",\u1e5a:"R",\u1e5c:"R",\u0156:"R",\u1e5e:"R",\u024c:"R",\u2c64:"R",\ua75a:"R",\ua7a6:"R",\ua782:"R","\u24c8":"S",\uff33:"S",\u1e9e:"S",\u015a:"S",\u1e64:"S",\u015c:"S",\u1e60:"S",\u0160:"S",\u1e66:"S",\u1e62:"S",\u1e68:"S",\u0218:"S",\u015e:"S",\u2c7e:"S",\ua7a8:"S",\ua784:"S","\u24c9":"T",\uff34:"T",\u1e6a:"T",\u0164:"T",\u1e6c:"T",\u021a:"T",\u0162:"T",\u1e70:"T",\u1e6e:"T",\u0166:"T",\u01ac:"T",\u01ae:"T",\u023e:"T",\ua786:"T",\ua728:"TZ","\u24ca":"U",\uff35:"U",\u00d9:"U",\u00da:"U",\u00db:"U",\u0168:"U",\u1e78:"U",\u016a:"U",\u1e7a:"U",\u016c:"U",\u00dc:"U",\u01db:"U",\u01d7:"U",\u01d5:"U",\u01d9:"U",\u1ee6:"U",\u016e:"U",\u0170:"U",\u01d3:"U",\u0214:"U",\u0216:"U",\u01af:"U",\u1eea:"U",\u1ee8:"U",\u1eee:"U",\u1eec:"U",\u1ef0:"U",\u1ee4:"U",\u1e72:"U",\u0172:"U",\u1e76:"U",\u1e74:"U",\u0244:"U","\u24cb":"V",\uff36:"V",\u1e7c:"V",\u1e7e:"V",\u01b2:"V",\ua75e:"V",\u0245:"V",\ua760:"VY","\u24cc":"W",\uff37:"W",\u1e80:"W",\u1e82:"W",\u0174:"W",\u1e86:"W",\u1e84:"W",\u1e88:"W",\u2c72:"W","\u24cd":"X",\uff38:"X",\u1e8a:"X",\u1e8c:"X","\u24ce":"Y",\uff39:"Y",\u1ef2:"Y",\u00dd:"Y",\u0176:"Y",\u1ef8:"Y",\u0232:"Y",\u1e8e:"Y",\u0178:"Y",\u1ef6:"Y",\u1ef4:"Y",\u01b3:"Y",\u024e:"Y",\u1efe:"Y","\u24cf":"Z",\uff3a:"Z",\u0179:"Z",\u1e90:"Z",\u017b:"Z",\u017d:"Z",\u1e92:"Z",\u1e94:"Z",\u01b5:"Z",\u0224:"Z",\u2c7f:"Z",\u2c6b:"Z",\ua762:"Z","\u24d0":"a",\uff41:"a",\u1e9a:"a",\u00e0:"a",\u00e1:"a",\u00e2:"a",\u1ea7:"a",\u1ea5:"a",\u1eab:"a",\u1ea9:"a",\u00e3:"a",\u0101:"a",\u0103:"a",\u1eb1:"a",\u1eaf:"a",\u1eb5:"a",\u1eb3:"a",\u0227:"a",\u01e1:"a",\u00e4:"a",\u01df:"a",\u1ea3:"a",\u00e5:"a",\u01fb:"a",\u01ce:"a",\u0201:"a",\u0203:"a",\u1ea1:"a",\u1ead:"a",\u1eb7:"a",\u1e01:"a",\u0105:"a",\u2c65:"a",\u0250:"a",\ua733:"aa",\u00e6:"ae",\u01fd:"ae",\u01e3:"ae",\ua735:"ao",\ua737:"au",\ua739:"av",\ua73b:"av",\ua73d:"ay","\u24d1":"b",\uff42:"b",\u1e03:"b",\u1e05:"b",\u1e07:"b",\u0180:"b",\u0183:"b",\u0253:"b","\u24d2":"c",\uff43:"c",\u0107:"c",\u0109:"c",\u010b:"c",\u010d:"c",\u00e7:"c",\u1e09:"c",\u0188:"c",\u023c:"c",\ua73f:"c",\u2184:"c","\u24d3":"d",\uff44:"d",\u1e0b:"d",\u010f:"d",\u1e0d:"d",\u1e11:"d",\u1e13:"d",\u1e0f:"d",\u0111:"d",\u018c:"d",\u0256:"d",\u0257:"d",\ua77a:"d",\u01f3:"dz",\u01c6:"dz","\u24d4":"e",\uff45:"e",\u00e8:"e",\u00e9:"e",\u00ea:"e",\u1ec1:"e",\u1ebf:"e",\u1ec5:"e",\u1ec3:"e",\u1ebd:"e",\u0113:"e",\u1e15:"e",\u1e17:"e",\u0115:"e",\u0117:"e",\u00eb:"e",\u1ebb:"e",\u011b:"e",\u0205:"e",\u0207:"e",\u1eb9:"e",\u1ec7:"e",\u0229:"e",\u1e1d:"e",\u0119:"e",\u1e19:"e",\u1e1b:"e",\u0247:"e",\u025b:"e",\u01dd:"e","\u24d5":"f",\uff46:"f",\u1e1f:"f",\u0192:"f",\ua77c:"f","\u24d6":"g",\uff47:"g",\u01f5:"g",\u011d:"g",\u1e21:"g",\u011f:"g",\u0121:"g",\u01e7:"g",\u0123:"g",\u01e5:"g",\u0260:"g",\ua7a1:"g",\u1d79:"g",\ua77f:"g","\u24d7":"h",\uff48:"h",\u0125:"h",\u1e23:"h",\u1e27:"h",\u021f:"h",\u1e25:"h",\u1e29:"h",\u1e2b:"h",\u1e96:"h",\u0127:"h",\u2c68:"h",\u2c76:"h",\u0265:"h",\u0195:"hv","\u24d8":"i",\uff49:"i",\u00ec:"i",\u00ed:"i",\u00ee:"i",\u0129:"i",\u012b:"i",\u012d:"i",\u00ef:"i",\u1e2f:"i",\u1ec9:"i",\u01d0:"i",\u0209:"i",\u020b:"i",\u1ecb:"i",\u012f:"i",\u1e2d:"i",\u0268:"i",\u0131:"i","\u24d9":"j",\uff4a:"j",\u0135:"j",\u01f0:"j",\u0249:"j","\u24da":"k",\uff4b:"k",\u1e31:"k",\u01e9:"k",\u1e33:"k",\u0137:"k",\u1e35:"k",\u0199:"k",\u2c6a:"k",\ua741:"k",\ua743:"k",\ua745:"k",\ua7a3:"k","\u24db":"l",\uff4c:"l",\u0140:"l",\u013a:"l",\u013e:"l",\u1e37:"l",\u1e39:"l",\u013c:"l",\u1e3d:"l",\u1e3b:"l",\u017f:"l",\u0142:"l",\u019a:"l",\u026b:"l",\u2c61:"l",\ua749:"l",\ua781:"l",\ua747:"l",\u01c9:"lj","\u24dc":"m",\uff4d:"m",\u1e3f:"m",\u1e41:"m",\u1e43:"m",\u0271:"m",\u026f:"m","\u24dd":"n",\uff4e:"n",\u01f9:"n",\u0144:"n",\u00f1:"n",\u1e45:"n",\u0148:"n",\u1e47:"n",\u0146:"n",\u1e4b:"n",\u1e49:"n",\u019e:"n",\u0272:"n",\u0149:"n",\ua791:"n",\ua7a5:"n",\u01cc:"nj","\u24de":"o",\uff4f:"o",\u00f2:"o",\u00f3:"o",\u00f4:"o",\u1ed3:"o",\u1ed1:"o",\u1ed7:"o",\u1ed5:"o",\u00f5:"o",\u1e4d:"o",\u022d:"o",\u1e4f:"o",\u014d:"o",\u1e51:"o",\u1e53:"o",\u014f:"o",\u022f:"o",\u0231:"o",\u00f6:"o",\u022b:"o",\u1ecf:"o",\u0151:"o",\u01d2:"o",\u020d:"o",\u020f:"o",\u01a1:"o",\u1edd:"o",\u1edb:"o",\u1ee1:"o",\u1edf:"o",\u1ee3:"o",\u1ecd:"o",\u1ed9:"o",\u01eb:"o",\u01ed:"o",\u00f8:"o",\u01ff:"o",\u0254:"o",\ua74b:"o",\ua74d:"o",\u0275:"o",\u01a3:"oi",\u0223:"ou",\ua74f:"oo","\u24df":"p",\uff50:"p",\u1e55:"p",\u1e57:"p",\u01a5:"p",\u1d7d:"p",\ua751:"p",\ua753:"p",\ua755:"p","\u24e0":"q",\uff51:"q",\u024b:"q",\ua757:"q",\ua759:"q","\u24e1":"r",\uff52:"r",\u0155:"r",\u1e59:"r",\u0159:"r",\u0211:"r",\u0213:"r",\u1e5b:"r",\u1e5d:"r",\u0157:"r",\u1e5f:"r",\u024d:"r",\u027d:"r",\ua75b:"r",\ua7a7:"r",\ua783:"r","\u24e2":"s",\uff53:"s",\u00df:"s",\u015b:"s",\u1e65:"s",\u015d:"s",\u1e61:"s",\u0161:"s",\u1e67:"s",\u1e63:"s",\u1e69:"s",\u0219:"s",\u015f:"s",\u023f:"s",\ua7a9:"s",\ua785:"s",\u1e9b:"s","\u24e3":"t",\uff54:"t",\u1e6b:"t",\u1e97:"t",\u0165:"t",\u1e6d:"t",\u021b:"t",\u0163:"t",\u1e71:"t",\u1e6f:"t",\u0167:"t",\u01ad:"t",\u0288:"t",\u2c66:"t",\ua787:"t",\ua729:"tz","\u24e4":"u",\uff55:"u",\u00f9:"u",\u00fa:"u",\u00fb:"u",\u0169:"u",\u1e79:"u",\u016b:"u",\u1e7b:"u",\u016d:"u",\u00fc:"u",\u01dc:"u",\u01d8:"u",\u01d6:"u",\u01da:"u",\u1ee7:"u",\u016f:"u",\u0171:"u",\u01d4:"u",\u0215:"u",\u0217:"u",\u01b0:"u",\u1eeb:"u",\u1ee9:"u",\u1eef:"u",\u1eed:"u",\u1ef1:"u",\u1ee5:"u",\u1e73:"u",\u0173:"u",\u1e77:"u",\u1e75:"u",\u0289:"u","\u24e5":"v",\uff56:"v",\u1e7d:"v",\u1e7f:"v",\u028b:"v",\ua75f:"v",\u028c:"v",\ua761:"vy","\u24e6":"w",\uff57:"w",\u1e81:"w",\u1e83:"w",\u0175:"w",\u1e87:"w",\u1e85:"w",\u1e98:"w",\u1e89:"w",\u2c73:"w","\u24e7":"x",\uff58:"x",\u1e8b:"x",\u1e8d:"x","\u24e8":"y",\uff59:"y",\u1ef3:"y",\u00fd:"y",\u0177:"y",\u1ef9:"y",\u0233:"y",\u1e8f:"y",\u00ff:"y",\u1ef7:"y",\u1e99:"y",\u1ef5:"y",\u01b4:"y",\u024f:"y",\u1eff:"y","\u24e9":"z",\uff5a:"z",\u017a:"z",\u1e91:"z",\u017c:"z",\u017e:"z",\u1e93:"z",\u1e95:"z",\u01b6:"z",\u0225:"z",\u0240:"z",\u2c6c:"z",\ua763:"z",\u0386:"\u0391",\u0388:"\u0395",\u0389:"\u0397",\u038a:"\u0399",\u03aa:"\u0399",\u038c:"\u039f",\u038e:"\u03a5",\u03ab:"\u03a5",\u038f:"\u03a9",\u03ac:"\u03b1",\u03ad:"\u03b5",\u03ae:"\u03b7",\u03af:"\u03b9",\u03ca:"\u03b9",\u0390:"\u03b9",\u03cc:"\u03bf",\u03cd:"\u03c5",\u03cb:"\u03c5",\u03b0:"\u03c5",\u03c9:"\u03c9",\u03c2:"\u03c3"},n.fnOperators={equal:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?n.toLowerCase(t)===n.toLowerCase(e):t===e},notequal:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),!n.fnOperators.equal(t,e,i)},lessthan:function(t,e,i){return i?n.toLowerCase(t)n.toLowerCase(e):t>e},lessthanorequal:function(t,e,i){return i?n.toLowerCase(t)<=n.toLowerCase(e):(m(t)&&(t=void 0),t<=e)},greaterthanorequal:function(t,e,i){return i?n.toLowerCase(t)>=n.toLowerCase(e):t>=e},contains:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?!m(t)&&!m(e)&&-1!==n.toLowerCase(t).indexOf(n.toLowerCase(e)):!m(t)&&!m(e)&&-1!==t.toString().indexOf(e)},doesnotcontain:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?!m(t)&&!m(e)&&-1===n.toLowerCase(t).indexOf(n.toLowerCase(e)):!m(t)&&!m(e)&&-1===t.toString().indexOf(e)},isnotnull:function(t){return null!=t},isnull:function(t){return null==t},startswith:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.startsWith(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.startsWith(t,e)},doesnotstartwith:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.notStartsWith(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.notStartsWith(t,e)},like:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.like(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.like(t,e)},isempty:function(t){return void 0===t||""===t},isnotempty:function(t){return void 0!==t&&""!==t},wildcard:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?(t||"boolean"==typeof t)&&e&&"object"!=typeof t&&n.wildCard(n.toLowerCase(t),n.toLowerCase(e)):(t||"boolean"==typeof t)&&e&&n.wildCard(t,e)},endswith:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.endsWith(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.endsWith(t,e)},doesnotendwith:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.notEndsWith(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.notEndsWith(t,e)},processSymbols:function(t){var e=n.operatorSymbols[t];return e?n.fnOperators[e]:n.throwError("Query - Process Operator : Invalid operator")},processOperator:function(t){return n.fnOperators[t]||n.fnOperators.processSymbols(t)}},n.parse={parseJson:function(t){return"string"!=typeof t||!/^[\s]*\[|^[\s]*\{(.)+:/g.test(t)&&-1!==t.indexOf('"')?t instanceof Array?n.parse.iterateAndReviveArray(t):"object"==typeof t&&null!==t&&n.parse.iterateAndReviveJson(t):t=JSON.parse(t,n.parse.jsonReviver),t},iterateAndReviveArray:function(t){for(var e=0;e-1||e.indexOf("z")>-1,o=e.split(/[^0-9.]/);if(s){if(o[5].indexOf(".")>-1){var a=o[5].split(".");o[5]=a[0],o[6]=new Date(e).getUTCMilliseconds().toString()}else o[6]="00";e=n.dateParse.toTimeZone(new Date(parseInt(o[0],10),parseInt(o[1],10)-1,parseInt(o[2],10),parseInt(o[3],10),parseInt(o[4],10),parseInt(o[5]?o[5]:"00",10),parseInt(o[6],10)),n.serverTimezoneOffset,!1)}else{var l=new Date(parseInt(o[0],10),parseInt(o[1],10)-1,parseInt(o[2],10),parseInt(o[3],10),parseInt(o[4],10),parseInt(o[5]?o[5]:"00",10)),h=parseInt(o[6],10),c=parseInt(o[7],10);if(isNaN(h)&&isNaN(c))return l;e.indexOf("+")>-1?l.setHours(l.getHours()-h,l.getMinutes()-c):l.setHours(l.getHours()+h,l.getMinutes()+c),e=n.dateParse.toTimeZone(l,n.serverTimezoneOffset,!1)}null==n.serverTimezoneOffset&&(e=n.dateParse.addSelfOffset(e))}}return e},isJson:function(t){return"string"==typeof t[0]?t:n.parse.parseJson(t)},isGuid:function(t){return null!=/[A-Fa-f0-9]{8}(?:-[A-Fa-f0-9]{4}){3}-[A-Fa-f0-9]{12}/i.exec(t)},replacer:function(t,e){return n.isPlainObject(t)?n.parse.jsonReplacer(t,e):t instanceof Array?n.parse.arrayReplacer(t):t instanceof Date?n.parse.jsonReplacer({val:t},e).val:t},jsonReplacer:function(t,e){for(var i,s=0,o=Object.keys(t);s=0?"+":"-",s=function(a){var l=Math.floor(Math.abs(a));return(l<10?"0":"")+l};return e.getFullYear()+"-"+s(e.getMonth()+1)+"-"+s(e.getDate())+"T"+s(e.getHours())+":"+s(e.getMinutes())+":"+s(e.getSeconds())+r+s(i/60)+":"+s(i%60)}},n}(),bl=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),EK={GroupGuid:"{271bbba0-1ee7}"},K4=function(){function n(t){this.options={from:"table",requestType:"json",sortBy:"sorted",select:"select",skip:"skip",group:"group",take:"take",search:"search",count:"requiresCounts",where:"where",aggregates:"aggregates",expand:"expand"},this.type=n,this.dataSource=t,this.pvt={}}return n.prototype.processResponse=function(t,e,i,r){return t},n}(),jE=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return bl(t,n),t.prototype.processQuery=function(e,i){for(var a,l,p,r=e.dataSource.json.slice(0),s=r.length,o=!0,h={},c=0,d=[],u=[],f=0;f1?e.sort.filter(function(p){return p.fieldName===c})[0]:e.sort[0];s=this.onSortBy(s,d,e.query,!0)}e.page&&(s=this.onPage(s,e.page,e.query)),this.formGroupResult(s,h)}else{for(var o=e.lazyLoad.onDemandGroupInfo,a=o.where.length-1;a>=0;a--)s=this.onWhere(s,o.where[a]);if(e.group.length!==o.level)s=le.group(s,e.group[o.level].fieldName,r,null,null,e.group[o.level].comparer,!0),e.sort.length&&(s=this.onSortBy(s,e.sort[parseInt(o.level.toString(),10)],e.query,!0));else for(a=e.sort.length-1;a>=o.level;a--)s=this.onSortBy(s,e.sort[parseInt(a.toString(),10)],e.query,!1);i=s.length,h=s,s=(s=s.slice(o.skip)).slice(0,o.take),e.group.length!==o.level&&this.formGroupResult(s,h)}return{result:s,count:i}},t.prototype.formGroupResult=function(e,i){if(e.length&&i.length){var r="GroupGuid",s="childLevels",o="level",a="records";e[r]=i[r],e[s]=i[s],e[o]=i[o],e[a]=i[a]}return e},t.prototype.getAggregate=function(e){var i=_t.filterQueries(e.queries,"onAggregates"),r=[];if(i.length)for(var s=void 0,o=0;o=0;l--)a[l]&&(o=i.comparer,le.endsWith(a[l]," desc")&&(o=le.fnSort("descending"),a[l]=a[l].replace(" desc","")),e=le.sort(e,a[l],o));return e}return le.sort(e,s?"key":a,i.comparer)},t.prototype.onGroup=function(e,i,r){if(!e||!e.length)return e;var s=this.getAggregate(r);return le.group(e,le.getValue(i.fieldName,r),s,null,null,i.comparer)},t.prototype.onPage=function(e,i,r){var s=le.getValue(i.pageSize,r),o=(le.getValue(i.pageIndex,r)-1)*s;return e&&e.length?e.slice(o,o+s):e},t.prototype.onRange=function(e,i){return e&&e.length?e.slice(le.getValue(i.start),le.getValue(i.end)):e},t.prototype.onTake=function(e,i){return e&&e.length?e.slice(0,le.getValue(i.nos)):e},t.prototype.onSkip=function(e,i){return e&&e.length?e.slice(le.getValue(i.nos)):e},t.prototype.onSelect=function(e,i){return e&&e.length?le.select(e,le.getValue(i.fieldNames)):e},t.prototype.insert=function(e,i,r,s,o){return m(o)?e.dataSource.json.push(i):e.dataSource.json.splice(o,0,i)},t.prototype.remove=function(e,i,r,s){var a,o=e.dataSource.json;for("object"==typeof r&&!(r instanceof Date)&&(r=le.getObject(i,r)),a=0;a1&&(g="("+g+")"),p.filters.push(g);for(var y=0,S="object"==typeof p.filters[f]?Object.keys(p.filters[f]):[];y-1&&this.formRemoteGroupedData(e[s].items,i+1,r-1);var o="GroupGuid",h="records";return e[o]=EK[o],e.level=i,e.childLevels=r,e[h]=e[0].items.length?this.getGroupedRecords(e,!m(e[0].items[h])):[],e},t.prototype.getGroupedRecords=function(e,i){for(var r=[],o=0;ol.length-3?(l=l.substring(0,l.length-1),o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.endswith:le.odv4UniOperator.endswith):l.lastIndexOf("%")!==l.indexOf("%")&&l.lastIndexOf("%")>l.indexOf("%")+1?(l=l.substring(l.indexOf("%")+1,l.lastIndexOf("%")),o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains):o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains),l="'"+(l=encodeURIComponent(l))+"'";else if("wildcard"===o)if(-1!==l.indexOf("*")){var d=l.split("*"),u=void 0,p=0;if(0!==l.indexOf("*")&&-1===d[0].indexOf("%3f")&&-1===d[0].indexOf("?")&&(u="'"+(u=d[0])+"'",s+=(o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.startswith:le.odv4UniOperator.startswith)+"(",s+=c+",",a&&(s+=a),s+=u+")",p++),l.lastIndexOf("*")!==l.length-1&&-1===d[d.length-1].indexOf("%3f")&&-1===d[d.length-1].indexOf("?")&&(u="'"+(u=d[d.length-1])+"'",p>0&&(s+=" and "),s+=(o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.endswith:le.odv4UniOperator.endswith)+"(",s+=c+",",a&&(s+=a),s+=u+")",p++),d.length>2)for(var f=1;f0&&(s+=" and "),"substringof"===(o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains)||"not substringof"===o){var g=u;u=c,c=g}s+=o+"(",s+=c+",",a&&(s+=a),s+=u+")",p++}0===p?(o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains,(-1!==l.indexOf("?")||-1!==l.indexOf("%3f"))&&(l=-1!==l.indexOf("?")?l.split("?").join(""):l.split("%3f").join("")),l="'"+l+"'"):o="wildcard"}else o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains,(-1!==l.indexOf("?")||-1!==l.indexOf("%3f"))&&(l=-1!==l.indexOf("?")?l.split("?").join(""):l.split("%3f").join("")),l="'"+l+"'";return"substringof"!==o&&"not substringof"!==o||(g=l,l=c,c=g),"wildcard"!==o&&(s+=o+"(",s+=c+",",a&&(s+=a),s+=l+")"),s},t.prototype.addParams=function(e){n.prototype.addParams.call(this,e),delete e.reqParams.params},t.prototype.onComplexPredicate=function(e,i,r){for(var s=[],o=0;o-1;p--)!/\bContent-ID:/i.test(c[p])||!/\bHTTP.+201/.test(c[p])||(l=parseInt(/\bContent-ID: (\d+)/i.exec(c[p])[1],10),o.addedRecords[l]&&(h=le.parse.parseJson(/^\{.+\}/m.exec(c[p])[0]),ze({},o.addedRecords[l],this.processResponse(h))));return o}return null},t.prototype.compareAndRemove=function(e,i,r){var s=this;return m(i)||Object.keys(e).forEach(function(o){o!==r&&"@odata.etag"!==o&&(le.isPlainObject(e[o])?(s.compareAndRemove(e[o],i[o]),0===Object.keys(e[o]).filter(function(l){return"@odata.etag"!==l}).length&&delete e[o]):(e[o]===i[o]||e[o]&&i[o]&&e[o].valueOf()===i[o].valueOf())&&delete e[o])}),e},t}(uc),DK=function(n){function t(){var e=n.call(this)||this;return yt("beforeSend",uc.prototype.beforeSend,e),e}return bl(t,n),t.prototype.insert=function(e,i,r,s,o){return this.pvt.position=o,this.updateType="add",{url:e.dataSource.insertUrl||e.dataSource.crudUrl||e.dataSource.url,data:JSON.stringify(ze({},{value:i,table:r,action:"insert"},le.getAddParams(this,e,s)))}},t.prototype.remove=function(e,i,r,s,o){return n.prototype.remove.call(this,e,i,r),{type:"POST",url:e.dataSource.removeUrl||e.dataSource.crudUrl||e.dataSource.url,data:JSON.stringify(ze({},{key:r,keyColumn:i,table:s,action:"remove"},le.getAddParams(this,e,o)))}},t.prototype.update=function(e,i,r,s,o){return this.updateType="update",this.updateKey=i,{type:"POST",url:e.dataSource.updateUrl||e.dataSource.crudUrl||e.dataSource.url,data:JSON.stringify(ze({},{value:r,action:"update",keyColumn:i,key:r[i],table:s},le.getAddParams(this,e,o)))}},t.prototype.processResponse=function(e,i,r,s,o,a,l){var h;if(e="batch"===(o?JSON.parse(o.data):e).action?le.parse.parseJson(e):e,"add"===this.updateType&&n.prototype.insert.call(this,i,e,null,null,this.pvt.position),"update"===this.updateType&&n.prototype.update.call(this,i,this.updateKey,e),this.updateType=void 0,e.added)for(h=0;hi&&h.push(c)}for(c=0;cthis.pageSize;)h.results.splice(0,1),h.keys.splice(0,1);return window.localStorage.setItem(this.guidId,JSON.stringify(h)),e},t.prototype.beforeSend=function(e,i,r){!m(this.cacheAdaptor.options.batch)&&le.endsWith(r.url,this.cacheAdaptor.options.batch)&&"post"===r.type.toLowerCase()&&i.headers.set("Accept",this.cacheAdaptor.options.multipartAccept),e.dataSource.crossDomain||i.headers.set("Accept",this.cacheAdaptor.options.accept)},t.prototype.update=function(e,i,r,s){return this.isCrudAction=!0,this.cacheAdaptor.update(e,i,r,s)},t.prototype.insert=function(e,i,r){return this.isInsertAction=!0,this.cacheAdaptor.insert(e,i,r)},t.prototype.remove=function(e,i,r,s){return this.isCrudAction=!0,this.cacheAdaptor.remove(e,i,r,s)},t.prototype.batchRequest=function(e,i,r){return this.cacheAdaptor.batchRequest(e,i,r)},t}(uc),nt=function(){function n(t,e,i){var s,r=this;return this.dateParse=!0,this.timeZoneHandling=!0,this.persistQuery={},this.isInitialLoad=!1,this.requests=[],this.isInitialLoad=!0,!t&&!this.dataSource&&(t=[]),i=i||t.adaptor,t&&!1===t.timeZoneHandling&&(this.timeZoneHandling=t.timeZoneHandling),t instanceof Array?s={json:t,offline:!0}:"object"==typeof t?(t.json||(t.json=[]),t.enablePersistence||(t.enablePersistence=!1),t.id||(t.id=""),t.ignoreOnPersist||(t.ignoreOnPersist=[]),s={url:t.url,insertUrl:t.insertUrl,removeUrl:t.removeUrl,updateUrl:t.updateUrl,crudUrl:t.crudUrl,batchUrl:t.batchUrl,json:t.json,headers:t.headers,accept:t.accept,data:t.data,timeTillExpiration:t.timeTillExpiration,cachingPageSize:t.cachingPageSize,enableCaching:t.enableCaching,requestType:t.requestType,key:t.key,crossDomain:t.crossDomain,jsonp:t.jsonp,dataType:t.dataType,offline:void 0!==t.offline?t.offline:!(t.adaptor instanceof DK||t.adaptor instanceof xK||t.url),requiresFormat:t.requiresFormat,enablePersistence:t.enablePersistence,id:t.id,ignoreOnPersist:t.ignoreOnPersist}):le.throwError("DataManager: Invalid arguments"),void 0===s.requiresFormat&&!le.isCors()&&(s.requiresFormat=!!m(s.crossDomain)||s.crossDomain),void 0===s.dataType&&(s.dataType="json"),this.dataSource=s,this.defaultQuery=e,this.dataSource.enablePersistence&&this.dataSource.id&&window.addEventListener("unload",this.setPersistData.bind(this)),s.url&&s.offline&&!s.json.length?(this.isDataAvailable=!1,this.adaptor=i||new up,this.dataSource.offline=!1,this.ready=this.executeQuery(e||new _t),this.ready.then(function(o){r.dataSource.offline=!0,r.isDataAvailable=!0,s.json=o.result,r.adaptor=new jE})):this.adaptor=s.offline?new jE:new up,!s.jsonp&&this.adaptor instanceof up&&(s.jsonp="callback"),this.adaptor=i||this.adaptor,s.enableCaching&&(this.adaptor=new TK(this.adaptor,s.timeTillExpiration,s.cachingPageSize)),this}return Object.defineProperty(n.prototype,"moduleName",{get:function(){return"datamanager"},enumerable:!0,configurable:!0}),n.prototype.getPersistedData=function(t){var e=localStorage.getItem(t||this.dataSource.id);return JSON.parse(e)},n.prototype.setPersistData=function(t,e,i){localStorage.setItem(e||this.dataSource.id,JSON.stringify(i||this.persistQuery))},n.prototype.setPersistQuery=function(t){var e=this,i=this.getPersistedData();if(this.isInitialLoad&&i&&Object.keys(i).length){this.persistQuery=i,this.persistQuery.queries=this.persistQuery.queries.filter(function(s){if(e.dataSource.ignoreOnPersist&&e.dataSource.ignoreOnPersist.length&&s.fn&&e.dataSource.ignoreOnPersist.some(function(l){return s.fn===l}))return!1;if("onWhere"===s.fn){var o=s.e;if(o&&o.isComplex&&o.predicates instanceof Array){var a=o.predicates.map(function(l){if(l.predicates&&l.predicates instanceof Array){var h=l.predicates.map(function(v){return new Ss(v.field,v.operator,v.value,v.ignoreCase,v.ignoreAccent,v.matchCase)});return"and"===l.condition?Ss.and(h):Ss.or(h)}return new Ss(l.field,l.operator,l.value,l.ignoreCase,l.ignoreAccent,l.matchCase)});s.e=new Ss(a[0],o.condition,a.slice(1))}}return!0});var r=ze(new _t,this.persistQuery);return this.isInitialLoad=!1,r}return this.persistQuery=t,this.isInitialLoad=!1,t},n.prototype.setDefaultQuery=function(t){return this.defaultQuery=t,this},n.prototype.executeLocal=function(t){!this.defaultQuery&&!(t instanceof _t)&&le.throwError("DataManager - executeLocal() : A query is required to execute"),this.dataSource.json||le.throwError("DataManager - executeLocal() : Json data is required to execute"),this.dataSource.enablePersistence&&this.dataSource.id&&(t=this.setPersistQuery(t));var e=this.adaptor.processQuery(this,t=t||this.defaultQuery);if(t.subQuery){var i=t.subQuery.fromTable,r=t.subQuery.lookups,s=t.isCountRequired?e.result:e;r&&r instanceof Array&&le.buildHierarchy(t.subQuery.fKey,i,s,r,t.subQuery.key);for(var o=0;oli");P.classList.remove("json-parent");for(var j=0;j',W=ve.children[0].placeholder}return W}function Q(k,W,ve){!m(ve)&&""!==ve&&K(W,ve.split(" ")),!m(k)&&""!==k&&V(W,k.split(" "))}function oe(k,W,ve){if("multiselect"===ve||function Mo(k){if(!k)return!1;for(var W=k;W&&W!==document.body;){if("none"===window.getComputedStyle(W).display)return!1;W=W.parentElement}return!0}(k)){var Te="multiselect"===ve?k:k.clientWidth-parseInt(getComputedStyle(k,null).getPropertyValue("padding-left"),10);!m(W)&&!m(W.getElementsByClassName("e-float-text-content")[0])&&(W.getElementsByClassName("e-float-text-content")[0].classList.contains("e-float-text-overflow")&&W.getElementsByClassName("e-float-text-content")[0].classList.remove("e-float-text-overflow"),(Te0)for(var Ye=0;Ye<_e.length;Ye++)_e[parseInt(Ye.toString(),10)].addEventListener("mousedown",wo,!1),_e[parseInt(Ye.toString(),10)].addEventListener("mouseup",Hl,!1);else if(_e.length>0)for(Ye=0;Ye<_e.length;Ye++)_e[parseInt(Ye.toString(),10)].removeEventListener("mousedown",wo,this),_e[parseInt(Ye.toString(),10)].removeEventListener("mouseup",Hl,this)}function wo(){for(var W=this.parentElement;!W.classList.contains("e-input-group");)W=W.parentElement;!function ya(k,W){!k.classList.contains("e-disabled")&&!k.querySelector("input").readOnly&&W.classList.add("e-input-btn-ripple")}(W,this)}function Hl(){var k=this;setTimeout(function(){k.classList.remove("e-input-btn-ripple")},500)}function ub(k,W){var ve=W("span",{className:k});return ve.classList.add("e-input-group-icon"),ve}function f_(k,W,ve,Te){var _e=m(Te)?mi:Te,Ye=ub(k,_e);W.classList.add("e-float-icon-left");var fi=W.querySelector(".e-input-in-wrap");if(m(fi)){fi=_e("span",{className:"e-input-in-wrap"}),ve.parentNode.insertBefore(fi,ve);var Gs=W.querySelectorAll(ve.tagName+" ~ *");fi.appendChild(ve);for(var Kn=0;Kn-1)if("class"===_e){var Ye=this.getInputValidClassList(k[""+_e]);""!==Ye&&V([W],Ye.split(" "))}else if("style"===_e){var fi=W.getAttribute(_e);fi=m(fi)?k[""+_e]:fi+k[""+_e],W.setAttribute(_e,fi)}else W.setAttribute(_e,k[""+_e])}},n.isBlank=function _le(k){return!k||/^\s*$/.test(k)}}(Le||(Le={})),new RegExp("^(-)?(\\d*)$"),new RegExp("^[A-Za-z0-9._%+-]{1,}@[A-Za-z0-9._%+-]{1,}([.]{1}[a-zA-Z0-9]{2,}|[.]{1}[a-zA-Z0-9]{2,4}[.]{1}[a-zA-Z0-9]{2,4})$"),new RegExp("^([0-9]{4})-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])$"),new RegExp("^[0-9]*$"),new RegExp("^[+]?[0-9]{9,13}$"),new RegExp("^\\d{13,16}$");var me=function(){function n(t,e){this.width=t,this.height=e}return n.prototype.isEmpty=function(){return 0===this.height&&0===this.width},n.prototype.clone=function(){return new n(this.width,this.height)},n}(),wie=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),YB=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},z=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return wie(t,n),t.equals=function(e,i){return e===i||!(!e||!i)&&(!e||!i||e.x===i.x&&e.y===i.y)},t.isEmptyPoint=function(e){return!(e.x&&e.y)},t.transform=function(e,i,r){var s={x:0,y:0};return s.x=Math.round(100*(e.x+r*Math.cos(i*Math.PI/180)))/100,s.y=Math.round(100*(e.y+r*Math.sin(i*Math.PI/180)))/100,s},t.findLength=function(e,i){return Math.sqrt(Math.pow(e.x-i.x,2)+Math.pow(e.y-i.y,2))},t.findAngle=function(e,i){var r=Math.atan2(i.y-e.y,i.x-e.x);return r=180*r/Math.PI,(r%=360)<0&&(r+=360),r},t.distancePoints=function(e,i){return Math.sqrt(Math.pow(i.x-e.x,2)+Math.pow(i.y-e.y,2))},t.getLengthFromListOfPoints=function(e){for(var i=0,r=0;ri.y&&!r?o.y+=s:o.y-=s:e.y===i.y?e.xi.x&&!r?o.x+=s:o.x-=s:r?(a=this.findAngle(e,i),o=this.transform(e,a,s)):(a=this.findAngle(i,e),o=this.transform(i,a,s)),o},t.direction=function(e,i){return Math.abs(i.x-e.x)>Math.abs(i.y-e.y)?e.x0)for(var r=0;rt.right||this.top>t.bottom||this.bottom=t.right&&this.top<=t.top&&this.bottom>=t.bottom},n.prototype.containsPoint=function(t,e){return void 0===e&&(e=0),this.left-e<=t.x&&this.right+e>=t.x&&this.top-e<=t.y&&this.bottom+e>=t.y},n.toBounds=function(t){for(var e=new n,i=0,r=t;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},ZB=function(n){if(n)switch(n.type){case"Linear":default:return fI;case"Radial":return Pie}return fI},Oie=function(){return function n(t,e,i,r){this.left=t,this.right=e,this.top=i,this.bottom=r}}(),$n=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),it([I(0)],t.prototype,"left",void 0),it([I(0)],t.prototype,"right",void 0),it([I(0)],t.prototype,"top",void 0),it([I(0)],t.prototype,"bottom",void 0),t}(Ee),kie=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),it([I(45)],t.prototype,"angle",void 0),it([I(5)],t.prototype,"distance",void 0),it([I(.7)],t.prototype,"opacity",void 0),it([I("lightgrey")],t.prototype,"color",void 0),t}(Ee),JB=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),t.prototype.getClassName=function(){return"Stop"},it([I("")],t.prototype,"color",void 0),it([I(0)],t.prototype,"offset",void 0),it([I(1)],t.prototype,"opacity",void 0),t}(Ee),Sx=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),it([Bt([],JB)],t.prototype,"stops",void 0),it([I("None")],t.prototype,"type",void 0),it([I("")],t.prototype,"id",void 0),t}(Ee),fI=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),it([I(0)],t.prototype,"x1",void 0),it([I(0)],t.prototype,"x2",void 0),it([I(0)],t.prototype,"y1",void 0),it([I(0)],t.prototype,"y2",void 0),t}(Sx),Pie=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),it([I(0)],t.prototype,"cx",void 0),it([I(0)],t.prototype,"cy",void 0),it([I(0)],t.prototype,"fx",void 0),it([I(0)],t.prototype,"fy",void 0),it([I(50)],t.prototype,"r",void 0),t}(Sx),Al=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),it([I("white")],t.prototype,"fill",void 0),it([I("black")],t.prototype,"strokeColor",void 0),it([I("")],t.prototype,"strokeDashArray",void 0),it([I(1)],t.prototype,"strokeWidth",void 0),it([I(1)],t.prototype,"opacity",void 0),it([M0(ZB)],t.prototype,"gradient",void 0),t}(Ee),KB=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),it([I("transparent")],t.prototype,"fill",void 0),t}(Al),Yp=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),it([I("black")],t.prototype,"color",void 0),it([I("Arial")],t.prototype,"fontFamily",void 0),it([I(12)],t.prototype,"fontSize",void 0),it([I(!1)],t.prototype,"italic",void 0),it([I(!1)],t.prototype,"bold",void 0),it([I("CollapseSpace")],t.prototype,"whiteSpace",void 0),it([I("WrapWithOverflow")],t.prototype,"textWrapping",void 0),it([I("Center")],t.prototype,"textAlign",void 0),it([I("None")],t.prototype,"textDecoration",void 0),it([I("Wrap")],t.prototype,"textOverflow",void 0),it([I("transparent")],t.prototype,"fill",void 0),t}(Al),on=function(n){return n[n.Default=0]="Default",n[n.expandNode=2]="expandNode",n[n.interaction=4]="interaction",n[n.GroupingInProgress=8]="GroupingInProgress",n[n.GroupClipboardInProcess=16]="GroupClipboardInProcess",n[n.ClearObject=32]="ClearObject",n}(on||{}),hi=function(n){return n[n.Visible=1]="Visible",n[n.Hidden=2]="Hidden",n[n.Hover=4]="Hover",n[n.Connect=8]="Connect",n}(hi||{}),Kt=function(n){return n[n.None=0]="None",n[n.ShowHorizontalLines=1]="ShowHorizontalLines",n[n.ShowVerticalLines=2]="ShowVerticalLines",n[n.ShowLines=3]="ShowLines",n[n.SnapToHorizontalLines=4]="SnapToHorizontalLines",n[n.SnapToVerticalLines=8]="SnapToVerticalLines",n[n.SnapToLines=12]="SnapToLines",n[n.SnapToObject=16]="SnapToObject",n[n.All=31]="All",n}(Kt||{}),lr=function(n){return n[n.None=1]="None",n[n.ConnectorSourceThumb=2]="ConnectorSourceThumb",n[n.ConnectorTargetThumb=4]="ConnectorTargetThumb",n[n.ResizeSouthEast=8]="ResizeSouthEast",n[n.ResizeSouthWest=16]="ResizeSouthWest",n[n.ResizeNorthEast=32]="ResizeNorthEast",n[n.ResizeNorthWest=64]="ResizeNorthWest",n[n.ResizeEast=128]="ResizeEast",n[n.ResizeWest=256]="ResizeWest",n[n.ResizeSouth=512]="ResizeSouth",n[n.ResizeNorth=1024]="ResizeNorth",n[n.Rotate=2048]="Rotate",n[n.UserHandle=4096]="UserHandle",n[n.ToolTip=8192]="ToolTip",n[n.ResizeAll=2046]="ResizeAll",n[n.All=16382]="All",n}(lr||{}),qe=function(n){return n[n.None=1]="None",n[n.Select=2]="Select",n[n.Delete=4]="Delete",n[n.Drag=8]="Drag",n[n.DragSourceEnd=16]="DragSourceEnd",n[n.DragTargetEnd=32]="DragTargetEnd",n[n.DragSegmentThumb=64]="DragSegmentThumb",n[n.AllowDrop=128]="AllowDrop",n[n.Bridging=256]="Bridging",n[n.BridgeObstacle=512]="BridgeObstacle",n[n.InheritBridging=1024]="InheritBridging",n[n.PointerEvents=2048]="PointerEvents",n[n.Tooltip=4096]="Tooltip",n[n.InheritTooltip=8192]="InheritTooltip",n[n.Interaction=4218]="Interaction",n[n.ReadOnly=16384]="ReadOnly",n[n.LineRouting=32768]="LineRouting",n[n.InheritLineRouting=65536]="InheritLineRouting",n[n.ConnectToNearByNode=131072]="ConnectToNearByNode",n[n.ConnectToNearByPort=262144]="ConnectToNearByPort",n[n.ConnectToNearByElement=393216]="ConnectToNearByElement",n[n.InheritSegmentThumbShape=524288]="InheritSegmentThumbShape",n[n.InheritSegmentThumbSize=1048576]="InheritSegmentThumbSize",n[n.Default=2043454]="Default",n}(qe||{}),Lr=function(n){return n[n.ReadOnly=2]="ReadOnly",n[n.InheritReadOnly=4]="InheritReadOnly",n[n.Select=8]="Select",n[n.Drag=16]="Drag",n[n.Resize=32]="Resize",n[n.Rotate=64]="Rotate",n[n.Tooltip=128]="Tooltip",n[n.Interaction=120]="Interaction",n[n.None=0]="None",n}(Lr||{}),ie=function(n){return n[n.None=0]="None",n[n.Select=2]="Select",n[n.Drag=4]="Drag",n[n.Rotate=8]="Rotate",n[n.Shadow=16]="Shadow",n[n.PointerEvents=32]="PointerEvents",n[n.Delete=64]="Delete",n[n.InConnect=128]="InConnect",n[n.OutConnect=256]="OutConnect",n[n.Individual=512]="Individual",n[n.Expandable=1024]="Expandable",n[n.AllowDrop=2048]="AllowDrop",n[n.Inherit=78]="Inherit",n[n.ResizeNorthEast=4096]="ResizeNorthEast",n[n.ResizeEast=8192]="ResizeEast",n[n.ResizeSouthEast=16384]="ResizeSouthEast",n[n.ResizeSouth=32768]="ResizeSouth",n[n.ResizeSouthWest=65536]="ResizeSouthWest",n[n.ResizeWest=131072]="ResizeWest",n[n.ResizeNorthWest=262144]="ResizeNorthWest",n[n.ResizeNorth=524288]="ResizeNorth",n[n.Resize=1044480]="Resize",n[n.AspectRatio=1048576]="AspectRatio",n[n.Tooltip=2097152]="Tooltip",n[n.InheritTooltip=4194304]="InheritTooltip",n[n.ReadOnly=8388608]="ReadOnly",n[n.HideThumbs=16777216]="HideThumbs",n[n.AllowMovingOutsideLane=33554432]="AllowMovingOutsideLane",n[n.Default=5240814]="Default",n}(ie||{}),Xr=function(n){return n[n.None=0]="None",n[n.ElementIsPort=2]="ElementIsPort",n[n.ElementIsGroup=4]="ElementIsGroup",n[n.HorizontalLaneHeader=8]="HorizontalLaneHeader",n}(Xr||{}),bt=function(n){return n[n.Rotate=2]="Rotate",n[n.ConnectorSource=4]="ConnectorSource",n[n.ConnectorTarget=8]="ConnectorTarget",n[n.ResizeNorthEast=16]="ResizeNorthEast",n[n.ResizeEast=32]="ResizeEast",n[n.ResizeSouthEast=64]="ResizeSouthEast",n[n.ResizeSouth=128]="ResizeSouth",n[n.ResizeSouthWest=256]="ResizeSouthWest",n[n.ResizeWest=512]="ResizeWest",n[n.ResizeNorthWest=1024]="ResizeNorthWest",n[n.ResizeNorth=2048]="ResizeNorth",n[n.Default=4094]="Default",n}(bt||{}),rt=function(n){return n[n.None=1]="None",n[n.Bridging=2]="Bridging",n[n.UndoRedo=4]="UndoRedo",n[n.Tooltip=8]="Tooltip",n[n.UserInteraction=16]="UserInteraction",n[n.ApiUpdate=32]="ApiUpdate",n[n.PageEditable=48]="PageEditable",n[n.Zoom=64]="Zoom",n[n.PanX=128]="PanX",n[n.PanY=256]="PanY",n[n.Pan=384]="Pan",n[n.ZoomTextEdit=512]="ZoomTextEdit",n[n.Virtualization=1024]="Virtualization",n[n.LineRouting=2048]="LineRouting",n[n.Default=500]="Default",n}(rt||{}),Ci=function(n){return n[n.None=0]="None",n[n.SingleSelect=1]="SingleSelect",n[n.MultipleSelect=2]="MultipleSelect",n[n.ZoomPan=4]="ZoomPan",n[n.DrawOnce=8]="DrawOnce",n[n.ContinuousDraw=16]="ContinuousDraw",n[n.Default=3]="Default",n}(Ci||{}),Ya=function(n){return n[n.Self=1]="Self",n[n.Parent=2]="Parent",n}(Ya||{}),pt=function(n){return n[n.None=0]="None",n[n.Control=1]="Control",n[n.Meta=1]="Meta",n[n.Alt=2]="Alt",n[n.Shift=4]="Shift",n}(pt||{}),Mt=function(n){return n[n.None=null]="None",n[n.Number0=0]="Number0",n[n.Number1=1]="Number1",n[n.Number2=2]="Number2",n[n.Number3=3]="Number3",n[n.Number4=4]="Number4",n[n.Number5=5]="Number5",n[n.Number6=6]="Number6",n[n.Number7=7]="Number7",n[n.Number8=8]="Number8",n[n.Number9=9]="Number9",n[n.A=65]="A",n[n.B=66]="B",n[n.C=67]="C",n[n.D=68]="D",n[n.E=69]="E",n[n.F=70]="F",n[n.G=71]="G",n[n.H=72]="H",n[n.I=73]="I",n[n.J=74]="J",n[n.K=75]="K",n[n.L=76]="L",n[n.M=77]="M",n[n.N=78]="N",n[n.O=79]="O",n[n.P=80]="P",n[n.Q=81]="Q",n[n.R=82]="R",n[n.S=83]="S",n[n.T=84]="T",n[n.U=85]="U",n[n.V=86]="V",n[n.W=87]="W",n[n.X=88]="X",n[n.Y=89]="Y",n[n.Z=90]="Z",n[n.Left=37]="Left",n[n.Up=38]="Up",n[n.Right=39]="Right",n[n.Down=40]="Down",n[n.Escape=27]="Escape",n[n.Space=32]="Space",n[n.PageUp=33]="PageUp",n[n.PageDown=34]="PageDown",n[n.End=35]="End",n[n.Home=36]="Home",n[n.Delete=46]="Delete",n[n.Tab=9]="Tab",n[n.Enter=13]="Enter",n[n.BackSpace=8]="BackSpace",n[n.F1=112]="F1",n[n.F2=113]="F2",n[n.F3=114]="F3",n[n.F4=115]="F4",n[n.F5=116]="F5",n[n.F6=117]="F6",n[n.F7=118]="F7",n[n.F8=119]="F8",n[n.F9=120]="F9",n[n.F10=121]="F10",n[n.F11=122]="F11",n[n.F12=123]="F12",n[n.Star=56]="Star",n[n.Plus=187]="Plus",n[n.Minus=189]="Minus",n[n.BracketLeft=219]="BracketLeft",n[n.BracketRight=221]="BracketRight",n}(Mt||{}),ee=function(n){return n[n.Render=2]="Render",n[n.PublicMethod=4]="PublicMethod",n[n.ToolAction=8]="ToolAction",n[n.UndoRedo=16]="UndoRedo",n[n.TextEdit=32]="TextEdit",n[n.Group=64]="Group",n[n.Clear=128]="Clear",n[n.PreventClearSelection=256]="PreventClearSelection",n[n.Interactions=512]="Interactions",n[n.PreventHistory=1024]="PreventHistory",n[n.PreventIconsUpdate=2048]="PreventIconsUpdate",n[n.PreventCollectionChangeOnDragOver=4096]="PreventCollectionChangeOnDragOver",n[n.PreventZIndexOnDragging=8192]="PreventZIndexOnDragging",n[n.isGroupDragging=16384]="isGroupDragging",n[n.DragUsingMouse=32768]="DragUsingMouse",n[n.DecoratorPropertyChange=65536]="DecoratorPropertyChange",n[n.PreventLaneContainerUpdate=131072]="PreventLaneContainerUpdate",n}(ee||{}),Qa=function(n){return n[n.None=2]="None",n[n.DrawSelectorBorder=4]="DrawSelectorBorder",n[n.PreventRenderSelector=8]="PreventRenderSelector",n}(Qa||{}),$i=function(n){return n[n.None=0]="None",n[n.PreventDrag=2]="PreventDrag",n[n.PreventScale=4]="PreventScale",n[n.PreventDataInit=8]="PreventDataInit",n[n.hScrollbarMoved=16]="hScrollbarMoved",n[n.vScrollbarMoved=32]="vScrollbarMoved",n[n.AnimationClick=64]="AnimationClick",n[n.EnableGroupAction=128]="EnableGroupAction",n[n.PanInProgress=256]="PanInProgress",n[n.OverViewAction=512]="OverViewAction",n}($i||{}),ca=function(n){return n[n.None=0]="None",n[n.PropertyChange=1024]="PropertyChange",n[n.Interaction=2048]="Interaction",n}(ca||{}),Ae=function(n){return n[n.Zero=0]="Zero",n[n.One=1]="One",n[n.Two=2]="Two",n[n.Three=3]="Three",n[n.Four=4]="Four",n[n.Five=5]="Five",n}(Ae||{}),Ce=function(n){return n[n.collectionChange=0]="collectionChange",n[n.rotateChange=1]="rotateChange",n[n.positionChange=2]="positionChange",n[n.propertyChange=3]="propertyChange",n[n.selectionChange=4]="selectionChange",n[n.sizeChange=5]="sizeChange",n[n.drop=6]="drop",n[n.sourcePointChange=7]="sourcePointChange",n[n.targetPointChange=8]="targetPointChange",n[n.connectionChange=9]="connectionChange",n[n.animationComplete=10]="animationComplete",n[n.click=11]="click",n[n.doubleClick=12]="doubleClick",n[n.scrollChange=13]="scrollChange",n[n.dragEnter=14]="dragEnter",n[n.dragLeave=15]="dragLeave",n[n.dragOver=16]="dragOver",n[n.textEdit=17]="textEdit",n[n.paletteSelectionChange=18]="paletteSelectionChange",n[n.historyChange=19]="historyChange",n[n.mouseEnter=20]="mouseEnter",n[n.mouseLeave=21]="mouseLeave",n[n.mouseOver=22]="mouseOver",n[n.expandStateChange=23]="expandStateChange",n[n.segmentCollectionChange=24]="segmentCollectionChange",n[n.commandExecute=25]="commandExecute",n[n.historyStateChange=26]="historyStateChange",n[n.onUserHandleMouseDown=27]="onUserHandleMouseDown",n[n.onUserHandleMouseUp=28]="onUserHandleMouseUp",n[n.onUserHandleMouseEnter=29]="onUserHandleMouseEnter",n[n.onUserHandleMouseLeave=30]="onUserHandleMouseLeave",n[n.onImageLoad=31]="onImageLoad",n[n.onDoBindingInit=32]="onDoBindingInit",n[n.keyUp=33]="keyUp",n[n.keyDown=34]="keyDown",n[n.fixedUserHandleClick=35]="fixedUserHandleClick",n[n.elementDraw=36]="elementDraw",n[n.mouseWheel=37]="mouseWheel",n[n.segmentChange=38]="segmentChange",n[n.onFixedUserHandleMouseDown=39]="onFixedUserHandleMouseDown",n[n.onFixedUserHandleMouseUp=40]="onFixedUserHandleMouseUp",n[n.onFixedUserHandleMouseEnter=41]="onFixedUserHandleMouseEnter",n[n.onFixedUserHandleMouseLeave=42]="onFixedUserHandleMouseLeave",n[n.loaded=43]="loaded",n}(Ce||{}),ri=function(n){return n[n.None=1]="None",n[n.Drag=2]="Drag",n[n.Draw=4]="Draw",n[n.InConnect=8]="InConnect",n[n.OutConnect=16]="OutConnect",n[n.ToolTip=32]="ToolTip",n[n.InheritTooltip=64]="InheritTooltip",n[n.Default=24]="Default",n}(ri||{}),Ix=function(n){return n[n.None=1]="None",n[n.Source=2]="Source",n[n.Target=4]="Target",n[n.Intermediate=8]="Intermediate",n[n.All=14]="All",n}(Ix||{}),gI=function(n){return n[n.None=0]="None",n[n.SymmetricAngle=2]="SymmetricAngle",n[n.SymmetricDistance=4]="SymmetricDistance",n[n.Default=6]="Default",n}(gI||{}),as=function(){function n(){this.pivot={x:.5,y:.5},this.isDirt=!0,this.isExport=!1,this.exportScaleValue={x:0,y:0},this.exportScaleOffset={x:0,y:0},this.canApplyStyle=!0,this.visible=!0,this.offsetX=0,this.offsetY=0,this.cornerRadius=0,this.minHeight=void 0,this.minWidth=void 0,this.maxWidth=void 0,this.maxHeight=void 0,this.width=void 0,this.height=void 0,this.rotateAngle=0,this.margin={left:0,right:0,top:0,bottom:0},this.connectionDirection="Auto",this.horizontalAlignment="Auto",this.verticalAlignment="Auto",this.flip="None",this.flipMode="All",this.relativeMode="Point",this.transform=Ya.Self|Ya.Parent,this.style={fill:"white",strokeColor:"black",opacity:1,strokeWidth:1},this.desiredSize=new me,this.actualSize=new me,this.parentTransform=0,this.preventContainer=!1,this.isSvgRender=!1,this.bounds=new Ne(0,0,0,0),this.shadow=null,this.description="",this.staticSize=!1,this.shapeType="",this.isRectElement=!1,this.isCalculateDesiredSize=!0,this.flipOffset={x:0,y:0},this.elementActions=Xr.None,this.inversedAlignment=!0,this.position=void 0,this.unitMode=void 0,this.float=!1,this.floatingBounds=void 0}return n.prototype.setOffsetWithRespectToBounds=function(t,e,i){this.unitMode=i,this.position={x:t,y:e}},n.prototype.getAbsolutePosition=function(t){if(void 0!==this.position)return"Absolute"===this.unitMode?this.position:{x:this.position.x*t.width,y:this.position.y*t.height}},Object.defineProperty(n.prototype,"outerBounds",{get:function(){return this.floatingBounds||this.bounds},set:function(t){this.floatingBounds=t},enumerable:!0,configurable:!0}),n.prototype.measure=function(t,e,i){var s=void 0!==this.height?this.height:(t.height||0)-this.margin.top-this.margin.bottom;return this.id&&0===s&&this.elementActions&Xr.HorizontalLaneHeader&&(s=this.actualSize.height),this.desiredSize=new me(void 0!==this.width?this.width:(t.width||0)-this.margin.left-this.margin.right,s),this.isCalculateDesiredSize&&(this.desiredSize=this.validateDesiredSize(this.desiredSize,t)),this.desiredSize},n.prototype.arrange=function(t){return this.actualSize=t,this.updateBounds(),this.actualSize},n.prototype.updateBounds=function(){this.bounds=yr(this)},n.prototype.validateDesiredSize=function(t,e){return this.isRectElement&&!this.width&&!this.minWidth&&!this.maxWidth&&(t.width=50),this.isRectElement&&!this.height&&!this.minHeight&&!this.maxHeight&&(t.height=50),(void 0===t||void 0!==this.width&&void 0!==this.height)&&((t=t||new me).width=void 0===this.width?(e.width||0)-this.margin.left-this.margin.right:this.width,t.height=void 0===this.height?(e.height||0)-this.margin.top-this.margin.bottom:this.height),void 0!==this.minWidth&&(t.width=Math.max(t.width,this.minWidth)),void 0!==this.minHeight&&(t.height=Math.max(t.height,this.minHeight)),void 0!==this.maxWidth&&0!==this.maxWidth&&(t.width=Math.min(t.width,this.maxWidth)),void 0!==this.maxHeight&&0!==this.maxHeight&&(t.height=Math.min(t.height,this.maxHeight)),t},n}(),Uie=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Cs=function(n){function t(){var e=null!==n&&n.apply(this,arguments)||this;return e.padding=new Oie(0,0,0,0),e.desiredBounds=void 0,e.measureChildren=!0,e.prevRotateAngle=0,e}return Uie(t,n),t.prototype.hasChildren=function(){return void 0!==this.children&&this.children.length>0},t.prototype.measure=function(e,i,r){this.desiredBounds=void 0;var o,a,s=void 0;if(this.hasChildren()){for(var l=0;l=n.width&&s.length>0)i[i.length]={text:s,x:0,dy:0,width:o},s="";else{(s+=a[r+1]||"").indexOf("\n")>-1&&(i[i.length]={text:s,x:0,dy:0,width:Bc(s,n)},s="");var l=Bc(s,n);Math.ceil(l)+2>=n.width&&s.length>0&&(i[i.length]={text:s,x:0,dy:0,width:l},s=""),r===a.length-1&&s.length>0&&(i[i.length]={text:s,x:0,dy:0,width:l},s="")}else i=function ooe(n,t,e){var c,d,u,p,i=[],r="",s=0,o=0,a="nowrap"!==n.whiteSpace,h=(t||n.content).split("\n");for(s=0;s0?" ":"")+c[parseInt(o.toString(),10)];var f=Bc(d=c[o+1]?r+" "+c[o+1]:r,n);Math.floor(f)>(e||n.width)-2&&r.length>0?(i[i.length]={text:r,x:0,dy:0,width:d===r?f:r===p?u:Bc(r,n)},r=""):o===c.length-1&&(i[i.length]={text:r,x:0,dy:0,width:f},r=""),p=d,u=f}return i}(n,t,e);else i[i.length]={text:a,x:0,dy:0,width:Bc(a,n)};return i}(l,r,n.isLaneOrientation?i:void 0),n.wrapBounds=a=function aoe(n,t){var r,s,e={x:0,width:0},i=0;for(i=0;in.width&&("Ellipsis"===n.textOverflow||"Clip"===n.textOverflow)?0:-r/2:"right"===n.textAlign?-r:t.length>1?0:-r/2,t[parseInt(i.toString(),10)].dy=1.2*n.fontSize,t[parseInt(i.toString(),10)].x=r,e.x=Math.min(e.x,r),e.width=Math.max(e.width,s);return e}(l,o),s.width=a.width,n.wrapBounds.width>=i&&"Wrap"!==l.textOverflow&&(s.width=i),s.height=o.length*n.style.fontSize*1.2,s}(this,0,0,this.isLaneOrientation?e.height:this.width||e.width):this.desiredSize,this.desiredSize=void 0===this.width||void 0===this.height?new me(i.width,i.height):new me(this.width,this.height),this.desiredSize=this.validateDesiredSize(this.desiredSize,e),this.desiredSize},t.prototype.arrange=function(e){return(e.width!==this.actualSize.width||e.height!==this.actualSize.height||this.isDirt)&&(this.doWrap=!0),this.actualSize=e,this.updateBounds(),this.isDirt=!1,this.actualSize},t}(as),Vie=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Ii=function(n){function t(){var e=null!==n&&n.apply(this,arguments)||this;return e.measureChildren=void 0,e}return Vie(t,n),t.prototype.measure=function(e,i,r){var s=void 0,o=void 0;if(this.hasChildren()){for(var a=0,l=this.children;a=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Ed=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Xie(t,n),Th([I("")],t.prototype,"content",void 0),Th([I("TopLeft")],t.prototype,"position",void 0),Th([I("Mouse")],t.prototype,"relativeMode",void 0),Th([I(!0)],t.prototype,"showTipPointer",void 0),Th([I("auto")],t.prototype,"width",void 0),Th([I("auto")],t.prototype,"height",void 0),Th([I("Auto")],t.prototype,"openOn",void 0),Th([I()],t.prototype,"animation",void 0),Th([I(!1)],t.prototype,"isSticky",void 0),t}(Ee);function e3(n){var t=new mh;t=t3(n.tooltip,t);var e=new mh(t);return e.beforeCollision=$ie,e.beforeOpen=qie,e.cssClass="e-diagram-tooltip",e.opensOn="custom",e.appendTo("#"+n.element.id),e.close(),e}function qie(n){(""===this.content||void 0===this.content)&&(n.element.style.display="none")}function $ie(n){n.collidedPosition&&n.collidedPosition!==this.position&&(n.element.style.display="none")}function bx(n,t){var e=n.tooltipObject;return t3(t?t.tooltip:n.tooltip,e),e}function t3(n,t){return n.content?(t.content=n.content,"string"==typeof n.content&&(t.content=ko(function(){return n.content})),t.position=n.position,t.showTipPointer=n.showTipPointer,t.width=n.width,t.height=n.height,t.animation=n.animation?n.animation:{close:{effect:"None"}}):t.close(),t}var Mx=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Hn=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},wx=function(n){function t(e,i,r,s){var o=n.call(this,e,i,r,s)||this;return o.inEdges=[],o.outEdges=[],o}return Mx(t,n),Hn([I("")],t.prototype,"id",void 0),Hn([I("Center")],t.prototype,"horizontalAlignment",void 0),Hn([I("Center")],t.prototype,"verticalAlignment",void 0),Hn([re({},$n)],t.prototype,"margin",void 0),Hn([I(12)],t.prototype,"width",void 0),Hn([I(12)],t.prototype,"height",void 0),Hn([re({},Al)],t.prototype,"style",void 0),Hn([I("Square")],t.prototype,"shape",void 0),Hn([I("Auto")],t.prototype,"connectionDirection",void 0),Hn([I(hi.Connect)],t.prototype,"visibility",void 0),Hn([I("")],t.prototype,"pathData",void 0),Hn([I(ri.Default)],t.prototype,"constraints",void 0),Hn([I()],t.prototype,"addInfo",void 0),Hn([I()],t.prototype,"outEdges",void 0),Hn([I()],t.prototype,"inEdges",void 0),Hn([re({},Ed)],t.prototype,"tooltip",void 0),t}(Ee),Es=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return Mx(t,n),t.prototype.getClassName=function(){return"PointPort"},Hn([re({x:.5,y:.5},z)],t.prototype,"offset",void 0),t}(wx),xc=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return Mx(t,n),t.prototype.getClassName=function(){return"PathPort"},Hn([I(.5)],t.prototype,"offset",void 0),Hn([re({x:0,y:0},z)],t.prototype,"displacement",void 0),Hn([I("Center")],t.prototype,"alignment",void 0),t}(wx),yI=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),hr=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Zie=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return yI(t,n),hr([I("blue")],t.prototype,"color",void 0),hr([I("")],t.prototype,"content",void 0),hr([I("")],t.prototype,"link",void 0),hr([I("None")],t.prototype,"textDecoration",void 0),hr([I("NewTab")],t.prototype,"hyperlinkOpenState",void 0),t}(Ee),Cx=function(n){function t(e,i,r,s){var o=n.call(this,e,i,r,s)||this;return r.id||(o.id=e.parentObj&&e.parentObj.propName&&"phases"===e.parentObj.propName?e.parentObj.id:Qe()),o}return yI(t,n),hr([I("")],t.prototype,"content",void 0),hr([I(void 0)],t.prototype,"template",void 0),hr([I("String")],t.prototype,"annotationType",void 0),hr([I(!0)],t.prototype,"visibility",void 0),hr([I(Lr.InheritReadOnly)],t.prototype,"constraints",void 0),hr([re(void 0,Zie)],t.prototype,"hyperlink",void 0),hr([I("")],t.prototype,"id",void 0),hr([I()],t.prototype,"width",void 0),hr([I()],t.prototype,"height",void 0),hr([I(0)],t.prototype,"rotateAngle",void 0),hr([I("Parent")],t.prototype,"rotationReference",void 0),hr([re({strokeWidth:0,strokeColor:"transparent",fill:"transparent"},Yp)],t.prototype,"style",void 0),hr([I("Center")],t.prototype,"horizontalAlignment",void 0),hr([I("Center")],t.prototype,"verticalAlignment",void 0),hr([re({},$n)],t.prototype,"margin",void 0),hr([re({top:void 0,bottom:void 0,left:void 0,right:void 0},$n)],t.prototype,"dragLimit",void 0),hr([I("Shape")],t.prototype,"type",void 0),hr([re({},Ed)],t.prototype,"tooltip",void 0),hr([I()],t.prototype,"addInfo",void 0),t}(Ee),Zn=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return yI(t,n),t.prototype.getClassName=function(){return"ShapeAnnotation"},hr([re({x:.5,y:.5},z)],t.prototype,"offset",void 0),t}(Cx),Nr=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return yI(t,n),t.prototype.getClassName=function(){return"PathAnnotation"},hr([I(.5)],t.prototype,"offset",void 0),hr([re({x:0,y:0},z)],t.prototype,"displacement",void 0),hr([I("Center")],t.prototype,"alignment",void 0),hr([I(!1)],t.prototype,"segmentAngle",void 0),t}(Cx);function Ex(n){return tre[n.toString()]}function i3(n){return nre[""+n]}var tre={X:"M14,14 L106,106 M106,14 L14,106",Circle:"M0,50 A50,50,0 1 1 100,50 A50,50,0 1 1 0,50 Z",Square:"M0,0 L10,0 L10,10 L0,10 z"},ire={OpenArrow:"M15.9,23 L5,16 L15.9,9 L17,10.7 L8.7,16 L17,21.3Z",Square:"M0,0 L10,0 L10,10 L0,10 z",Fletch:"M14.8,10c0,0-3.5,6,0.2,12c0,0-2.5-6-10.9-6C4.1,16,11.3,16,14.8,10z",OpenFetch:"M6,17c-0.6,0-1-0.4-1-1s0.4-1,1-1c10.9,0,11-5,11-5c0-0.6,0.4-1,1-1s1,0.4,1,1C19,10.3,18.9,17,6,17C6,17,6,17,6,17z M18,23c-0.5,0-1-0.4-1-1c0-0.2-0.3-5-11-5c-0.6,0-1-0.5-1-1s0.4-1,1-1c0,0,0,0,0,0c12.9,0,13,6.7,13,7 C19,22.6,18.6,23,18,23z",IndentedArrow:"M17,10c0,0-4.5,5.5,0,12L5,16L17,10z",OutdentedArrow:"M14.6,10c0,0,5.4,6,0,12L5,16L14.6,10z",DoubleArrow:"M19,10 L19,22 L13,16Z M12,10 L12,22 L6,16Z",Arrow:"M15,10 L15,22 L5,16Z",Diamond:"M12,23l-7-7l7-7l6.9,7L12,23z",Circle:"M0,50 A50,50,0 1 1 100,50 A50,50,0 1 1 0,50 Z"},rre={Square:"M0,0 L10,0 L10,10 L0,10 z",Rhombus:"M10,5 L5,10 L0,5 L5,0 L10,5 Z ",Rectangle:"M0,0 L15,0 L15,10 L0,10 z ",OpenArrow:"M15.9,23 L5,16 L15.9,9 L17,10.7 L8.7,16 L17,21.3Z",Fletch:"M9.82,0 C9.82,0,6.61,5,10,10 C10,10,7.71,5,0,5 C0,5,6.61,5,9.82,0 Z ",OpenFetch:"M0.71,5.71 C0.29,5.71,0,5.43,0,5 C0,4.57,0.29,4.29,0.71,4.29 C8.5,4.29,8.57,0.71,8.57,0.71 C8.57,0.29,8.86,0,9.29,0 C9.719999999999999,0,10,0.29,10,0.71 C10,0.93,9.93,5.71,0.71,5.71 C0.71,5.71,0.71,5.71,0.71,5.71 Z M9.29,10 C8.93,10,8.57,9.71,8.57,9.29 C8.57,9.14,8.36,5.71,0.71,5.71 C0.29,5.71,0,5.36,0,5 C0,4.64,0.29,4.29,0.71,4.29 C0.71,4.29,0.71,4.29,0.71,4.29 C9.93,4.29,10,9.07,10,9.29 C10,9.71,9.71,10,9.29,10 Z ",IndentedArrow:"M10,0 C10,0,6.25,4.58,10,10 L0,5 L10,0 Z ",OutdentedArrow:"M8,0 C8,0,12.5,5,8,10 L0,5 L8,0 Z ",DoubleArrow:"M19,10 L19,22 L13,16Z M12,10 L12,22 L6,16Z",Arrow:"M15,10 L15,22 L5,16Z",Diamond:"M10,5 L5,10 L0,5 L5,0 L10,5 Z ",Circle:"M10,5 C10,7.76,7.76,10,5,10 C2.24,10,0,7.76,0,5 C0,2.24,2.24,0,5,0 C7.76,0,10,2.24,10,5 Z ",Ellipse:"M15,5 C15,7.76,11.64,10,7.5,10 C3.36,10,0,7.76,0,5 C0,2.24,3.36,0,7.5,0 C11.64,0,15,2.24,15,5 Z "},nre={Square:"M0,0 L10,0 L10,10 L0,10 z",Rhombus:"M10,5 L5,10 L0,5 L5,0 L10,5 Z ",Rectangle:"M0,0 L15,0 L15,10 L0,10 z",OpenArrow:"M23,15.9 L16,5 L9,15.9 L10.7,17 L16,8.7 L21,17.3Z",Fletch:"M9.82,0 C9.82,0,6.61,5,10,10 C10,10,7.71,5,0,5 C0,5,6.61,5,9.82,0 Z ",OpenFetch:"M0.71,5.71 C0.29,5.71,0,5.43,0,5 C0,4.57,0.29,4.29,0.71,4.29 C8.5,4.29,8.57,0.71,8.57,0.71 C8.57,0.29,8.86,0,9.29,0 C9.719999999999999,0,10,0.29,10,0.71 C10,0.93,9.93,5.71,0.71,5.71 C0.71,5.71,0.71,5.71,0.71,5.71 Z M9.29,10 C8.93,10,8.57,9.71,8.57,9.29 C8.57,9.14,8.36,5.71,0.71,5.71 C0.29,5.71,0,5.36,0,5 C0,4.64,0.29,4.29,0.71,4.29 C0.71,4.29,0.71,4.29,0.71,4.29 C9.93,4.29,10,9.07,10,9.29 C10,9.71,9.71,10,9.29,10 Z ",IndentedArrow:"M10,0 C10,0,6.25,4.58,10,10 L0,5 L10,0 Z ",OutdentedArrow:"M8,0 C8,0,12.5,5,8,10 L0,5 L8,0 Z ",DoubleArrow:"M10,19 L22,19 L16,13Z M10,12 L22,12 L16,6Z",Arrow:"M10,15 L22,15 L16,5Z",Diamond:"M10,5 L5,10 L0,5 L5,0 L10,5 Z ",Circle:"M10,5 C10,7.76,7.76,10,5,10 C2.24,10,0,7.76,0,5 C0,2.24,2.24,0,5,0 C7.76,0,10,2.24,10,5 Z ",Ellipse:"M15,5 C15,7.76,11.64,10,7.5,10 C3.36,10,0,7.76,0,5 C0,2.24,3.36,0,7.5,0 C11.64,0,15,2.24,15,5 Z "};function Dx(n){return sre[n.toString()]}var sre={Process:"M419.511,76.687L359.511,76.687L359.511,43.086L419.511,43.086z",Decision:"M 253.005,115.687L 200.567,146.071L 148.097,115.687L 200.534,85.304L 253.005,115.687 Z",Document:"M 60 31.9 c 0 0 -11 -7.7 -30 0 s -30 0 -30 0 V 0 h 60 V 31.9 Z",PreDefinedProcess:"M 0,0 L 50,0 L 50,50 L 0,50 Z M 8.334,0 L 8.334,50 M 41.667,0 L 41.667,50",Terminator:"M 269.711,29.33C 269.71,44.061 257.77,56 243.04,56L 158.058,56C 143.33,56 131.39,44.061 131.39,29.33L 131.39,29.33C 131.391,14.6057 143.33,2.669 158.058,2.669L 243.044,2.669C 257.772,2.669 269.711,14.6057 269.711,29.333 Z",PaperTap:"M0.0009,17.2042 L0.0009,47.165 C0.001,47.165 14.403,53.5455 25.00,47.165 C35.599,40.7852 44.403,43.5087 50.00,47.165L50.001,17.2042 M50.001,32.7987 L50.001,2.8405 C50.001,2.8405 35.599,-3.5427 25.001,2.8405C14.403,9.2237 5.599,6.494 0.0009,2.8405 L0.0009,32.7987",DirectData:"M 132.62 0 L 17.38 0 C 7.78 0 0 13.43 0 30 C 0 46.57 7.78 60 17.38 60 L 132.62 60 M 132.62 0C 123.02 0 115.24 13.43 115.24 30 C 115.24 46.57 123.02 60 132.62 60 C 142.22 60 150 46.57 150 30 C 150 13.43 142.22 0 132.62 0 z ",SequentialData:"M0.0029,24.999 C0.0029,11.1922 10.433,0.0021 23.295,0.0021 C36.159,0.00216 46.585,11.1922 46.585,24.999C46.585,38.8057 36.159,49.9979 23.295,49.9979 C10.433,49.9979 0.0029,38.8057 0.0029,24.999 z M23.294,49.999 L50.002,49.999",Sort:"M50.001,24.9971 L25.001,49.9971 L0.00097,24.9971 L25.001,-0.00286865 L50.001,24.9971 z M0.000976562,24.9971 L50.001,24.9971",MultiDocument:"M43.6826,40 C44.8746,40.6183 45.8586,41.3502 46.8366,42.1122 L46.8366,4.74487 L3.09857,4.74487 L3.09857,10.9544 M46.837,35.143 C48.027,35.765 49.025,36.604 50.003,37.369 L50.003,0.002 L6.264,0.002 L6.264,4.744 M43.682,47.113 L43.682,10.765 L0.0025,10.7652 L0.0025,47.1132 C0.0025,47.1132 12.5846,53.6101 21.8426,47.1132 C31.1006,40.6163 38.792,43.393 43.6826,47.1132 z",Collate:"M50.001,0.0028 L25.001,25.0029 L0.00097,0.0028 L50.001,0.002 z M0.0009,50.002 L25.001,25.002L50.001,50.002 L0.0009,50.0029 z",SummingJunction:"M7.3252,42.6768 L42.6772,7.3247 M42.6768,42.6768 L7.3248,7.3247 M0.0009,25.001 C0.0009,11.193 11.197,0.0009 25.001,0.0009 C38.809,0.0009 50.001,11.193 50.001,25.001 C50.001,38.809 38.809,50.001 25.001,50.001 C11.197,50.00 0.0009,38.809 0.0009,25.00 z",Or:"M 0 50 L 100 50 M 50 100 L 50 0.0 M 0 50 C 0 22.384 22.392 0 50 0 C 77.616 0 100 22.384 100 50 C 100 77.616 77.616 100 50 100 C 22.392 100 0 77.616 0 50 Z",InternalStorage:"M 0 3.81946A 2.5,3.81946 0 0,1 2.5,0L 47.5 0A 2.5,3.81946 0 0,1 50,3.81946L 50 45.836A 2.5,3.819446 0 0,1 47.5,49.652778L 2.5 49.652778A 2.5,3.819446 0 0,1 0,45.8336L 0 3.819446ZM 0 11.45834L 50 11.4583334M 12.5 0L 12.5 49.652778",Extract:"M0,35 L30,0 L60,35 Z",ManualOperation:"M46.4,28.8 L14.8,28.8 L0,0 L60,0 Z",Merge:"M60,0 L30,35 L0,0 Z",OffPageReference:"M60,33.3 L30.1,39 L0,33.3 L0,0 L60,0 Z",SequentialAccessStorage:"M 60 30 C 60 13.4 46.6 0 30 0 S 0 13.4 0 30 s 13.4 30 30 30 h 28.6 v -6.5 h -9.9C 55.5 48 60 39.5 60 30 Z",Annotation:"M49.9984,50.0029 L-0.00271199,50.0029 L-0.00271199,0.00286865 L49.9984,0.00286865",Annotation2:"M49.9977,50.0029 L25.416,50.0029 L25.416,0.00286865 L49.9977,0.00286865 M25.4166,25.0029 L-0.00227869,25.0029",Data:"M 10 0 L 40 0 L 30 40 L 0 40 Z",Card:"M275,60 L400,60 L400,110 L260,110 L260,75 Z",Delay:"M0,0 L12.029,0 C14.212999,0 16,1.7869979 16,3.9709952 C16,6.1549926 14.212999,7.9409904 12.029,7.9409904 L0,7.9409904 z",Preparation:"M 1048.17 572 C 1051.06 568.86 1055.17 567.05 1059.5 567 L 1094.51 567 C 1098.84 567.05 1102.95 568.86 1105.84 572 L 1126.43 595 C 1127.01 596.28 1127.01 597.72 1126.43 599 L 1105.84 622 C 1102.95 625.14 1098.84 626.95 1094.51 627 L 1059.5 627 C 1055.17 626.95 1051.06 625.14 1048.17 622 L 1027.58 599 C 1027 597.72 1027 596.28 1027.58 595 L 1048.17 572 Z",Display:"M47.8809,19.2914 L32.7968,-0.00594145 L11.3902,-0.00594145 C7.93166,-0.00594145 0.00124586,11.187 0.00124586,24.9968C0.00124586,38.8032 7.93166,49.9962 11.3902,49.9962 L32.7968,49.99 L47.615,31.038 C47.615,31.0388 52.798,24.9968 47.880,19.2914 z",ManualInput:"M 912 732 L 1006.85 707 C 1008.2 707 1009.5 707.53 1010.46 708.46 C 1011.41 709.4 1011.95 710.67 1011.95 712 L 1011.95 762C 1012 764.41 1010.28 766.52 1007.87 767 L 917.1 767 C 915.75 767 914.45 766.47 913.49 765.54 C 912.54 764.6 912 763.33 912 762 L 912 732 Z",LoopLimit:"M 8 9 L 27 9 L 33 15 L 33 26 C 33 27 33 27 32 27 L 4 27 C 3 27 2 27 2 26 L 2 15 L 8 9 Z",StoredData:"M 5.55 0L 50 0A 1.5,30 0 0,1 50,0A 5.555,25 0 0,0 50,50A 1.5,30 0 0,1 50,50L 5.555 50A 5.55,25 0 0,1 5.555,0Z"};function r3(n,t,e){var i;i="Straight"!==n.type&&n.sourceWrapper?n.sourceWrapper.corners.center:function ore(n){var t;if(n.sourcePortWrapper){var e=n.sourcePortWrapper;t={x:e.offsetX,y:e.offsetY}}else t=n.sourceID&&n.sourceWrapper&&n.targetWrapper?Ah(n,0,n.sourceWrapper.corners.center,n.targetWrapper.corners.center,!1):n.sourcePoint;return t}(n);var r=function lre(n,t,e,i,r){var b,M,s=n.sourceWrapper,o=n.targetWrapper,a=n.sourcePortWrapper,l=n.targetPortWrapper,d=[],f=Ga(n),y={corners:undefined,point:t,direction:undefined,margin:{left:5,right:5,bottom:5,top:5}},S={corners:undefined,point:e,direction:undefined,margin:{left:5,right:5,bottom:5,top:5}};if(void 0!==s&&void 0!==o&&(b=En(s),M=En(o),y.corners=s.corners,S.corners=o.corners),void 0!==a&&(y.direction="Left"===a.connectionDirection||"Top"===a.connectionDirection||"Bottom"===a.connectionDirection||"Right"===a.connectionDirection?a.connectionDirection:zo({x:a.offsetX,y:a.offsetY},b,s.bounds)),void 0!==l&&(S.direction="Left"===l.connectionDirection||"Right"===l.connectionDirection||"Bottom"===l.connectionDirection||"Top"===l.connectionDirection?l.connectionDirection:zo({x:l.offsetX,y:l.offsetY},M,o.bounds)),"Bezier"===n.type&&!n.isBezierEditing&&n.segments.length>0)for(var D=n.segments.length-1;D>=0;)n.segments[parseInt(D.toString(),10)].isInternalSegment&&n.segments.pop(),D--;if(void 0!==s&&void 0!==o)return(void 0===y.direction||void 0===S.direction)&&(i?function are(n,t,e){"LeftToRight"===e?(n.direction=n.direction?n.direction:"Right",t.direction=t.direction?t.direction:"Left"):"RightToLeft"===e?(n.direction=n.direction?n.direction:"Left",t.direction=t.direction?t.direction:"Right"):"TopToBottom"===e?(n.direction=n.direction?n.direction:"Bottom",t.direction=t.direction?t.direction:"Top"):"BottomToTop"===e&&(n.direction=n.direction?n.direction:"Top",t.direction=t.direction?t.direction:"Bottom")}(y,S,i):y.corners.top>S.corners.bottom&&Math.abs(y.corners.top-S.corners.bottom)>f?(y.direction=y.direction?y.direction:"Top",S.direction=S.direction?S.direction:"Bottom"):y.corners.bottomf?(y.direction=y.direction?y.direction:"Bottom",S.direction=S.direction?S.direction:"Top"):y.corners.rightf||y.corners.right+f=y.corners.left-f&&y.corners.left>S.corners.left?(y.direction=y.direction?y.direction:"Right",S.direction=S.direction?S.direction:"Left"):y.corners.left>S.corners.right&&Math.abs(y.corners.left-S.corners.right)>y.margin.left+y.margin.right||S.corners.right+f=S.corners.left-f&&y.corners.left0&&n.segments[0].direction&&(y.direction=n.segments[0].direction),y.point=Tc(b,y.direction),d=Tc(b,ls(y.direction)),y.point=Ah(n,0,y.point,d,!1)):y.point=o.corners.center;if(void 0!==h){switch(S.point={x:h.offsetX,y:h.offsetY},S.direction){case"Bottom":case"Top":S.point.y=S.point.y;break;case"Left":case"Right":S.point.x=S.point.x}n.targetPadding&&!w&&(S.point=SI(n,y,S,!0))}else"Orthogonal"===n.type||"Bezier"===n.type?(S.point=Tc(M,S.direction),d=Tc(M,ls(S.direction)),S.point=Ah(n,0,S.point,d,!0)):S.point=a.corners.center;if("Orthogonal"!==n.type){var C=void 0,D=void 0;if("Bezier"===n.type){if(n.bezierSettings.allowSegmentsReset||0===n.segments.length||!z.isEmptyPoint(n.segments[n.segments.length-1].point))return c=p3(n,y,S,void 0,s),xx(n,y,S);Rv(n)}else Rv(n);if(void 0===n.sourcePortWrapper){y.point=y.corners.center,n.segments&&n.segments.length>0&&(C=z.isEmptyPoint((D=n.segments[0]).point)?void 0:D);var A=void 0!==C?C.point:S.point;if("Bezier"===n.type&&n.segments.length>0&&n.segments[0].vector1.angle&&n.segments[0].vector1.distance){var x=Math.max(y.corners.width,y.corners.height);A=z.transform(y.point,n.segments[0].vector1.angle,x/2)}y.point=w?n.sourceWrapper.bounds.center:Ah(n,0,y.point,A,!1)}if(void 0===n.targetPortWrapper){S.point=S.corners.center,n.segments&&n.segments.length>1&&(C=z.isEmptyPoint((D=n.segments[n.segments.length-2]).point)?void 0:D);var R=C?C.point:y.point;"Bezier"===n.type&&n.segments.length>0&&n.segments[n.segments.length-1].vector2.angle&&n.segments[n.segments.length-1].vector2.distance&&(x=Math.max(y.corners.width,y.corners.height),R=z.transform(S.point,n.segments[0].vector2.angle,x/2)),S.point=w?n.targetWrapper.bounds.center:Ah(n,0,R,S.point,!0)}c=xx(n,y,S)}else"Orthogonal"===n.type&&n.segments&&n.segments.length>0&&null!==n.segments[0].direction?c=function yre(n,t,e,i,r,s,o){var a,h,c,d;Rv(n);for(var u=0;u0&&n.segments[u-1].direction===h.direction?u=c3(n,u,t):h.direction?t.point=n3(t,n.segments[parseInt(u.toString(),10)]):(p=n.segments[u-1])&&p.points&&(t.point=p.points[p.points.length-1]),u===n.segments.length-1)if(d3(n,t),l3(a=void 0===r?mre(n,t,e):o3(n,t,e),n),h.points=[],a.length>=2)for(c=0;c2&&n.segments.length>2){var f={x:a[parseInt(c.toString(),10)].x,y:t.point.y};h.points=[],h.points.push(f),h.points.push(a[parseInt(c.toString(),10)]);var p=n.segments[u-1];n.segments.length<4&&p.points.pop(),p.points=p.points.concat(h.points)}else h.points.push(a[parseInt(c.toString(),10)]);else h.points.push(a[parseInt(c.toString(),10)]);else d=u;if(void 0!==d&&!n.selectedSegmentIndex&&(d===n.segments.length-1&&(n.segments[d-1].direction=null,n.segments[d-1].length=null),n.segments.splice(d,1)),i&&0===u){var g=a3(n,i,s);g&&(t.point=g)}}return u3(n,[])}(n,y,S,l,h,o):(n.segments[0]||(C=new bi(n,"segments",{type:"Orthogonal"},!0),n.segments.push(C)),n.segments[0].points=c=p3(n,y,S,void 0,s));return c}(n,y.direction,S.direction,y.point,S.point,r);if(Rv(n),(n.sourceWrapper||n.targetWrapper)&&function pre(n,t,e){var i=n.sourcePortWrapper,r=n.targetPortWrapper,s=n.sourceWrapper,o=t.point,a={left:0,right:0,top:0,bottom:0},l={x:0,y:0},c="Top";if(s?(o=e.point,a=t.margin):(s=n.targetWrapper,a=e.margin),"Orthogonal"===n.type)if(n.segments&&n.segments.length>0&&n.sourceWrapper&&n.segments[0].direction)t.direction=n.segments[0].direction,l=Ah(n,0,l=Tc(s.corners,t.direction),Tc(s.corners,ls(t.direction)),!1);else{var u={corners:null,direction:null,point:null,margin:null};Hv(s,{corners:null,direction:null,point:o,margin:a},u,n),l=u.point,c=u.direction}else{var p=void 0;n.segments&&n.segments.length>1&&(p=s===n.sourceWrapper?n.segments[0].point:n.segments[n.segments.length-2].point),l=Ah(n,0,s.bounds.center,n.segments&&n.segments.length>1?p:o,s===n.targetWrapper)}s===n.sourceWrapper?(t.direction=t.direction||c,t.point=l,n.sourcePortWrapper&&(t.point={x:i.offsetX,y:i.offsetY},n.sourcePadding&&(t.point=SI(n,t,e,!1)))):(e.direction=e.direction||c,e.point=l,n.targetPortWrapper&&(e.point={x:r.offsetX,y:r.offsetY},n.targetPadding&&(e.point=SI(n,t,e,!0))))}(n,y,S),"Straight"===n.type||"Bezier"===n.type)d=xx(n,y,S);else if("Orthogonal"===n.type&&n.segments&&n.segments.length>0&&null!==n.segments[0].length&&null!==n.segments[0].direction)d=function ure(n,t,e,i,r,s,o){var a,l,c,u,h=[];if(Rv(n),n.segments.length>0){for(var p=0;p0&&n.segments[p-1].direction===f.direction)p=c3(n,p,t);else{var g=n.segments[p-1];t.point=f.direction?n3(t,f):g.points[g.points.length-1]}if(p===n.segments.length-1&&(o||r?n.targetWrapper&&void 0===n.targetPortWrapper?(d3(n,t),l=cre(n,t,e)):l=o3(n,t,e):l=hre(n,t,e),l))if(l3(l,n),f.points=[],l.length>=2)for(a=0;at.corners.top&&e.point.ye.point.x?"Left":"Right"):e.point.x>t.corners.left&&e.point.xe.point.y?"Top":"Bottom")),n.sourcePortWrapper&&s===ls(r)?(("Left"===s||"Right"===s)&&t.point.y>=t.corners.top&&t.point.y<=t.corners.center.y&&e.point.y>=t.corners.top&&e.point.y<=t.corners.center.y?(t.direction="Top",a=t.point.y-t.corners.top+20):("Left"===s||"Right"===s)&&t.point.y>t.corners.center.y&&t.point.y<=t.corners.bottom&&e.point.y>t.corners.center.y&&e.point.y<=t.corners.bottom?(t.direction="Bottom",a=t.corners.bottom-t.point.y+20):("Top"===s||"Bottom"===s)&&t.point.x>=t.corners.left&&t.point.x<=t.corners.center.x&&e.point.x>=t.corners.left&&e.point.x<=t.corners.center.x?(t.direction="Left",a=t.point.x-t.corners.left+20):("Top"===s||"Bottom"===s)&&t.point.x<=t.corners.right&&t.point.x>t.corners.center.x&&e.point.x<=t.corners.right&&e.point.xt.point.y&&t.point.y>=e.corners.top?(i="Top",r=t.point.y-e.corners.top+20):e.corners.center.y===t.point.y&&"Top"===n.segments[n.segments.length-2].direction||e.corners.center.ye.point.y?t.point.y-t.corners.top+20:t.corners.bottom-t.point.y+20):(i="Top",r=e.corners.height/2+20):e.corners.center.x!==t.point.x||e.corners.topt.point.x&&t.point.x>=e.corners.left?(i="Left",r=t.point.x-e.corners.left+20):e.corners.center.x===t.point.x&&"Left"===n.segments[n.segments.length-2].direction||e.corners.center.x<=t.point.x&&t.point.x<=e.corners.right?(i="Right",r=e.corners.right-t.point.x+20):void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&t.corners.left<=t.point.x&&t.point.x<=t.corners.right&&(i=t.direction,r=t.point.x>e.point.x?t.point.x-t.corners.left+20:t.corners.right-t.point.x+20):(i="Left",r=e.corners.width/2+20);var a=t.point;t.point=Bn(t.point,"Left"===i||"Top"===i?-r:r,"Left"===i||"Right"===i?0:90),t.direction=z.direction(t.point,e.point),void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&(t.corners.center.x===e.corners.center.x||t.corners.center.y===e.corners.center.y)&&(t.direction=e.direction);var l=Ys(n,t,e);return l.splice(0,0,a),l}function o3(n,t,e){var i,r;e.corners=n.targetWrapper.corners,void 0!==n.sourcePortWrapper&&(r=zo({x:n.sourcePortWrapper.offsetX,y:n.sourcePortWrapper.offsetY},En(n.sourceWrapper),n.sourceWrapper.bounds));var a=function dre(n,t,e,i){var r=!1;switch(e.direction){case"Left":void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&"Right"===i&&t.point.x>e.point.x&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom||("Bottom"===i&&t.point.y>e.point.y||"Top"===i&&t.point.y=t.corners.left&&t.point.x<=t.corners.right?(t.direction="Right"===i?t.point.y>e.point.y?"Top":"Bottom":t.point.xe.point.x&&(t.point.y>e.point.y||t.point.yt.point.y&&e.corners.bottome.point.y||t.point.x>e.point.x&&t.point.y<=e.point.y&&e.corners.top=t.point.y?t.direction="Top":t.point.xe.point.x&&t.point.y>e.point.y&&e.corners.bottomt.point.y?t.direction="Bottom":t.point.y===e.point.y&&t.point.xe.point.y||"Top"===i&&t.point.ye.point.x&&t.point.x>=t.corners.left&&t.point.x<=t.corners.right?(t.direction=t.point.x>e.point.x?"Left":"Right",r=!0):void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&"Left"===i&&t.point.x=t.corners.top&&t.point.y<=t.corners.bottom?(t.direction=t.point.y>e.point.y?"Top":"Bottom",r=!0):t.point.x=t.point.y&&t.point.y===e.point.y||t.point.y>e.point.y&&t.point.x>e.point.x?t.direction="Top":t.point.ye.point.x?t.direction="Bottom":t.point.xe.point.y||t.point.ye.point.x&&(t.direction="Left");break;case"Top":void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&"Bottom"===i&&t.point.y>e.point.y&&t.point.x>=t.corners.left&&t.point.x<=t.corners.right||("Right"===i&&t.point.x>e.point.x||"Left"===i&&e.point.y>t.point.y&&e.point.x>t.point.x)&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom?(t.direction="Bottom"===i?t.point.x>e.point.x?"Left":"Right":t.point.ye.point.y&&t.point.x>e.corners.left&&t.point.x=e.point.y?t.direction="Top":t.point.ye.point.x?t.direction="Left":t.point.yt.point.x)&&t.point.y>e.point.y&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom||"Top"===i&&t.point.y=t.corners.left&&t.point.x<=t.corners.right)?(t.direction="Right"===i||"Left"===i?t.point.y>e.point.y?"Top":"Bottom":t.point.x>e.point.x?"Left":"Right",r=!0):t.point.ye.corners.left&&e.corners.right>t.point.x?t.point.ye.corners.left&&e.corners.center.x>=t.point.x?t.direction="Left":t.point.ye.point.y&&t.point.x>e.point.x?t.direction="Left":t.point.y>e.point.y&&t.point.xe.point.x||e.point.x>t.point.x)&&(t.direction="Bottom")}return r}(n,t,e,r);return!n.selectedSegmentIndex&&void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&e.direction===ls(r)&&(("Left"===e.direction&&t.point.x>e.point.x||"Right"===e.direction&&t.point.x=t.corners.top&&t.point.y<=t.corners.bottom||"Bottom"===e.direction&&t.point.y=t.corners.left&&t.point.x<=t.corners.right)?i=s3(n,t,e):n.selectedSegmentIndex||t.direction!==e.direction?!n.selectedSegmentIndex&&("Left"===e.direction&&t.point.x>e.point.x||"Right"===e.direction&&t.point.x=t.point.y||"Top"===e.direction&&t.point.y>e.point.y||"Bottom"===e.direction&&t.point.y=t.point.x?i=n.selectedSegmentIndex?Ll(t,e):s3(n,t,e):!n.selectedSegmentIndex&&void 0!==n.sourceWrapper&&void 0!==n.targetWrapper&&void 0!==n.targetPortWrapper&&("Left"===t.direction||"Right"===t.direction)&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom&&("Top"===e.direction||"Bottom"===e.direction)&&e.corners.center.x===t.corners.center.x?(t.direction="Top"===e.direction?"Bottom":"Top",i=Ys(n,t,e,"Top"===e.direction?t.corners.bottom-t.point.y+20:t.point.y-t.corners.top+20)):!n.selectedSegmentIndex&&void 0!==n.sourceWrapper&&void 0!==n.targetWrapper&&void 0!==n.targetPortWrapper&&("Top"===t.direction||"Bottom"===t.direction)&&t.point.x>=t.corners.left&&t.point.x<=t.corners.right&&("Left"===e.direction||"Right"===e.direction)&&e.corners.center.y===t.corners.center.y?(t.direction="Left"===e.direction?"Right":"Left",i=Ys(n,t,e,"Left"===e.direction?t.corners.right-t.point.x+20:t.point.x-t.corners.left+20)):i=a?Ys(n,t,e,"Left"===t.direction||"Right"===t.direction?"Left"===t.direction?t.point.x-t.corners.left+20:t.corners.right-t.point.x+20:"Top"===t.direction?t.point.y-t.corners.top+20:t.corners.bottom-t.point.y+20):Ll(t,e):i=Ys(n,t,e),i}function a3(n,t,e){var r,i={x:t.offsetX,y:t.offsetY},s=En(e),o=zo(i,s,e.bounds),a=n.segments[0];return a.direction!==o&&(function Sre(n,t,e,i,r,s){var a,h,o=13,l=[];l.push(i),i.y===r.y&&("Left"===t&&r.xi.x)||i.x===r.x&&("Top"===t&&r.yi.y)||("Top"===t||"Bottom"===t?"Top"===t&&r.yi.y-o||"Bottom"===t&&r.y>i.y&&r.yo&&("Top"===t&&r.yi.y)?l.push({x:i.x,y:r.y}):(a=r.xi.x-o||"right"===t&&r.x>i.x&&r.xo&&("Left"===t&&r.xi.x)?l.push({x:r.x,y:i.y}):(l.push({x:a="Left"===t?e.left-o:e.right+o,y:i.y}),l.push({x:a,y:r.y})),s&&(l.push(n.points[0]),l.reverse()),n.points=l)}(a,o,s,a.points[0],a.points[a.points.length-1],!1),r=a.points[a.points.length-1],a.direction=z.direction(a.points[a.points.length-2],a.points[a.points.length-1])),r}function l3(n,t,e){var s,i=t.segments[t.segments.length-2],r=i.points[i.points.length-1];(("Top"===i.direction||"Bottom"===i.direction)&&r.x===n[1].x||("Left"===i.direction||"Right"===i.direction)&&r.y===n[1].y)&&(i.points[i.points.length-1]=n[1],s=z.direction(i.points[0],i.points[i.points.length-1]),void 0!==t.sourceWrapper&&void 0===t.sourcePortWrapper&&s===ls(i.direction)&&("Left"===i.direction||"Right"===i.direction?i.points[0].x="Right"===i.direction?i.points[0].x-t.sourceWrapper.corners.width:i.points[0].x+t.sourceWrapper.corners.width:i.points[0].y="Bottom"===i.direction?i.points[0].y-t.sourceWrapper.corners.height:i.points[0].y+t.sourceWrapper.corners.height),i.direction=s,i.length=z.distancePoints(i.points[0],i.points[i.points.length-1]),n.splice(0,1))}function SI(n,t,e,i){var o=i?n.targetPadding:n.sourcePadding,a=i?n.targetPortWrapper:n.sourcePortWrapper,l=new Ne(a.bounds.x-o,a.bounds.y-o,a.actualSize.width+2*o,a.actualSize.height+2*o),h=[l.topLeft,l.topRight,l.bottomRight,l.bottomLeft];h[h.length]=h[0];var d=i?e.point:t.point;return Ax({x1:t.point.x,y1:t.point.y,x2:e.point.x,y2:e.point.y},h,0,d)||d}function h3(n,t){var e=[],i=hF(0,n.corners,t);i.push(i[0]);for(var r=0;r0){var r=void 0,s=[],o=t.point;for(r=0;r1&&z.equals(a.points[0],a.points[1])&&n.segments.splice(r,1),a)for(var l=0;l0||0===r)&&i.push(a.points[parseInt(l.toString(),10)])}}return i}function Tx(n,t,e){return"Top"===n||"Bottom"===n?e.x>t.x?"Right":"Left":e.y>t.y?"Bottom":"Top"}function Rv(n){if("Straight"===n.type||"Bezier"===n.type){if(0===n.segments.length||n.segments.length>0&&!z.isEmptyPoint(n.segments[n.segments.length-1].point))if("Bezier"===n.type){var t=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0},!0);n.segments.push(t)}else t=new kl(n,"segments",{type:"Straight"},!0),n.segments.push(t)}else{if(n.segments.length>0)for(var e=!1,i=0;i=t.corners.left&&e.point.x<=t.corners.right&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom)t.direction=e.point.y>t.point.y?"Bottom":"Top",i=Ys(n,t,e,"Top"===t.direction?t.point.y-t.corners.top+20:t.corners.bottom-t.point.y+20);else if(n.sourcePortWrapper&&r===ls(o)){var h;("Left"===r||"Right"===r)&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom?(t.direction=e.point.y>t.point.y?"Bottom":"Top",h=t.corners.height/2+20):("Top"===r||"Bottom"===r)&&t.point.x>=t.corners.left&&t.point.x<=t.corners.right&&(t.direction=e.point.x>t.point.x?"Right":"Left",h=t.corners.width/2+20),t.direction&&h?i=Ys(n,t,e,h,!0):(t.direction=o,i=Ll(t,e))}else if(!n.sourcePortWrapper||r!==e.direction||"Top"!==r&&"Bottom"!==r||t.corners.center.x!==e.corners.center.x)if(t.direction===e.direction)if(("Left"===t.direction||"Right"===t.direction)&&e.point.y>t.corners.top-20&&e.point.yt.corners.left-20&&e.point.xt.point.y?"Bottom":"Top",i=Ys(n,t,e,"Bottom"===t.direction?t.corners.bottom-t.point.y+20:t.point.y-t.corners.top+20);else t.direction=o,i=Ys(n,t,e,"Top"===o||"Bottom"===o?n.sourceWrapper.height/2+20:n.sourceWrapper.width/2+20),t.point=i[1],"Left"===o||"Right"===o?(e.direction=o,e.point="Left"===o?e.corners.middleLeft:e.corners.middleRight):Hv(n.targetWrapper,t,e,n),i=Ys(n,t,e);return i}function d3(n,t){if(void 0!==n.targetWrapper&&void 0===n.targetPortWrapper&&En(n.targetWrapper).containsPoint(t.point,1)){var i=n.targetWrapper,r=n.segments[n.segments.length-2],s=r.points[r.points.length-1],o=ls(r.direction);"Bottom"===o?s.yi.corners.top-1&&(r.points[r.points.length-1].y=i.corners.top-20,r.length=z.distancePoints(r.points[0],r.points[r.points.length-1])):"Left"===o?s.x>i.corners.left-1&&(r.points[r.points.length-1].x=i.corners.left-20,r.length=z.distancePoints(r.points[0],r.points[r.points.length-1])):"Right"===o&&s.x0||0===e)&&t.push(i.points[parseInt(r.toString(),10)]);return t}function Hv(n,t,e,i){var r,s={x:0,y:0},o=II(n,n.corners,n.bounds),a=t.margin,l=t.point;if(o.bottomCenter.y+a.bottoml.y)r="Top",s=o.topCenter;else if(o.middleLeft.x-a.left>l.x)r="Left",s=o.middleLeft;else if(o.middleRight.x+a.rightc&&(p=c,r="Right",s=o.middleRight),p>d&&(p=d,r="Bottom",s=o.bottomCenter),p>u&&(r="Left",s=o.middleLeft)}e.point=s,e.direction=r;var f=Tc(o,ls(e.direction));e.point=Ah(i,0,e.point,f,n===i.targetWrapper)}function p3(n,t,e,i,r){var s,o,a;if(s=function kre(n,t){var e=!1;switch(n){case"Left":switch(t){case"Right":case"Bottom":e=!0}break;case"Top":switch(t){case"Left":case"Right":case"Bottom":e=!0}break;case"Bottom":"Right"===t&&(e=!0)}return e}(t.direction,e.direction),s&&S3(t,e),"Right"===t.direction&&"Left"===e.direction)a=function Ire(n,t,e,i){var o=Math.round(Math.abs(t.point.y-e.point.y)),a={x:Math.max(t.point.x,t.corners.right),y:t.point.y},l={x:Math.min(e.point.x,e.corners.left),y:e.point.y},h=Ga(n);if(i){var c=l;l=a,a=c}return t.corners.bottom+he.corners.bottom+h||("Bezier"!==n.type||e.corners.left-t.corners.right<=2*h&&e.corners.left-t.corners.right>=5)&&(h=0),t.margin={left:h,right:h,top:h,bottom:h},e.margin={left:h,right:h,top:h,bottom:h},0===o&&(t.corners.right=e.corners.right?void 0!==i&&(i.offsetYe.corners.bottom+e.margin.bottom)||void 0===i&&t.corners.middleRight.ye.corners.bottom+e.margin.bottom&&t.corners.top>e.corners.bottom||void 0===i&&t.corners.middleRight.y>e.corners.bottom||void 0!==i&&i.offsetYe.corners.top||void 0===i&&t.corners.middleRight.y>e.corners.bottom?Ae.Three:t.corners.rightr.offsetY+e.margin.right||void 0===r&&t.corners.top>e.corners.middleRight.y||void 0!==r&&(void 0!==i&&i.offsetXr.offsetX||void 0===r&&t.corners.left>e.corners.topCenter.x?Ae.Four:Ae.Two:void 0!==s&&Math.abs(t.corners.right-e.corners.left)<=5&&Math.abs(s.offsetY-e.corners.top)<=5||void 0!==r&&t.corners.right=25&&t.corners.middleRight.y+t.margin.righte.corners.bottom+e.margin.bottom||void 0===o&&t.corners.middleRight.y>e.corners.bottom+e.margin.bottom?t.corners.top>e.corners.bottom?void 0!==a&&t.corners.right+t.margin.righta.offsetX||void 0===a&&t.corners.left>e.corners.bottomCenter.x?Ae.Four:Ae.Two:void 0!==o&&Math.abs(t.corners.right-e.corners.left)<=25&&Math.abs(o.offsetY-e.corners.bottom)<=25?Ae.Two:Ae.Four}(n,t,e,s);else if("Bottom"===t.direction&&"Top"===e.direction)a=function Cre(n,t,e){var r=t.point.x-e.point.x,s=Ga(n);return t.corners.right+se.corners.right+s||("Bezier"!==n.type||e.corners.top-t.corners.bottom<=2*s&&e.corners.top-t.corners.bottom>=5)&&(s=0),t.margin={left:s,right:s,top:s,bottom:s},e.margin={left:s,right:s,top:s,bottom:s},0===r&&t.corners.bottome.corners.right+e.margin.right||void 0===i&&t.corners.bottomCenter.x>e.corners.right+e.margin.right?Ae.Three:t.corners.bottomr.offsetX||void 0===r&&t.corners.left>e.corners.left||void 0!==r&&t.corners.right+t.margin.righte.corners.bottom?Ae.Five:0===s||0===o?Ae.One:Ae.Three}(n,t,e)}else"Bottom"===t.direction&&"Left"===e.direction?a=function Ere(n,t,e,i){var r=n.sourcePortWrapper,s=n.targetPortWrapper,o=Ga(n);if(e.margin={left:o,right:o,top:o,bottom:o},t.margin={top:o,bottom:o,left:o,right:o},i){var l=r;r=s,s=l}return void 0!==r&&r.offsetXs.offsetY||void 0===s&&t.corners.top>e.corners.middleLeft.y?Ae.Four:Ae.Two:void 0!==s&&Math.abs(t.corners.right-e.corners.left)<=25&&Math.abs(s.offsetY-t.corners.bottom)<=25?Ae.Two:Ae.Four}(n,t,e,s):"Left"===t.direction&&"Left"===e.direction?a=function Tre(n,t,e){var i=n.sourcePortWrapper,r=n.targetPortWrapper,s=Ga(n);t.margin={left:s,right:s,top:s,bottom:s},e.margin={left:s,right:s,top:s,bottom:s};var o=Math.round(Math.abs(t.point.x-e.point.x)),a=Math.round(Math.abs(t.point.y-e.point.y));return t.corners.leftr.offsetY||void 0===r&&t.corners.top-t.margin.top>e.corners.middleLeft.y?Ae.Three:t.corners.righte.corners.bottom+e.margin.bottom||void 0===i&&t.corners.middleLeft.y>e.corners.bottom+e.margin.bottom?Ae.Three:t.corners.left>e.corners.right?Ae.Five:0===o||0===a?Ae.One:Ae.Three}(n,t,e):"Left"===t.direction&&"Top"===e.direction?a=function xre(n,t,e,i){var s=n.sourcePortWrapper,o=Ga(n);e.margin={left:o,right:o,top:o,bottom:o},t.margin={top:o,bottom:o,left:o,right:o};var a=n.targetPortWrapper,l={x:Math.min(t.point.x,t.corners.left),y:t.point.y},h={x:e.point.x,y:Math.min(e.point.y,e.corners.top)};if(i){var c=s;s=a,a=c;var d=l;l=h,h=d}return void 0!==s&&s.offsetYa.offsetX||void 0===a&&t.corners.left-t.margin.left>e.corners.topCenter.x?Ae.Two:Ae.Four:void 0!==a&&t.corners.rightr.offsetX||void 0===r&&t.corners.left>e.corners.left||void 0!==r&&t.corners.right+t.margin.righte.corners.right+e.margin.right||void 0===i&&t.corners.left>e.corners.right||void 0!==i&&i.offsetXe.corners.bottom?Ae.Five:0===s||0===o?Ae.One:Ae.Three}(n,t,e));return s&&S3(t,e),o=function Lre(n,t,e,i,r,s){var l,d,h=n.sourceWrapper.corners,c=n.targetWrapper.corners,u=20,p={corners:e.corners,point:e.point,direction:e.direction,margin:e.margin},f={corners:i.corners,point:i.point,direction:i.direction,margin:i.margin};if(!(p.direction===f.direction&&t!==Ae.Five||p.direction!==ls(f.direction)&&t!==Ae.Three))switch(p.direction){case"Left":h.middleLeft.x>c.middleRight.x&&(d=(h.middleLeft.x-c.middleRight.x)/2,u=s?d:Math.min(u,d));break;case"Right":h.middleRight.xc.bottomCenter.y&&(d=(h.topCenter.y-c.bottomCenter.y)/2,u=s?d:Math.min(u,d));break;case"Bottom":h.bottomCenter.yp&&hp)&&o>c&&o<=d&&e>=20&&(s=n.point.x-t.corners.left+s),i&&n.direction===t.direction&&n.corners.left>t.corners.left&&n.corners.left-t.corners.right>=20&&(s=(n.corners.left-t.corners.right)/2),f=Bn(n.point,s,180);break;case"Top":(o>c&&oc)&&h>p&&h<=u&&e>=20&&(s=n.point.y-t.corners.top+s),i&&n.direction===t.direction&&n.corners.top>t.corners.top&&n.corners.top-t.corners.bottom>=20&&(s=(n.corners.top-t.corners.bottom)/2),f=Bn(n.point,s,270);break;case"Right":(h>p&&hp)&&a=c&&e>=20&&(s=t.corners.right-n.point.x+s),i&&n.direction===t.direction&&n.corners.right=20&&(s=(t.corners.left-n.corners.right)/2),f=Bn(n.point,s,0);break;case"Bottom":(o>c&&oc)&&l=p&&e>=20&&(s=t.corners.bottom-n.point.y+s),i&&n.direction===t.direction&&n.corners.bottom=20&&(s=(t.corners.top-n.corners.bottom)/2),f=Bn(n.point,s,90)}r=[n.point,f];var g=void 0;if("Top"===n.direction||"Bottom"===n.direction){var v=n.direction;n.direction=f.x>t.point.x?"Left":"Right",n.point=f,r=bI(n,t,v,r,g=i?.5*Math.abs(f.x-t.point.x):g,i)}else v=n.direction,n.direction=f.y>t.point.y?"Top":"Bottom",n.point=f,r=bI(n,t,v,r,g=i?.5*Math.abs(f.y-t.point.y):g,i);return r}(p,f,u,g)),l}(n,a,t,e,i,r),"Bezier"===n.type&&function Ore(n,t,e){if("Bezier"===n.type)if(0===n.segments.length){var i=e[0],r=e[e.length-1];if(t===Ae.One){var s=Math.min(20,.5*z.findLength(i,r)),o={angle:Gt(i,r),distance:s},a={angle:Gt(r,i),distance:s},l=z.direction(i,r),c=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,orientation:"Left"===l||"Right"===l?"Horizontal":"Vertical"},!0);n.segments.push(c)}else if(t===Ae.Two)o={angle:Gt(i,d=e[1]),distance:.5*z.findLength(i,d)},a={angle:Gt(r,d),distance:.5*z.findLength(r,d)},l=z.direction(i,d),c=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,orientation:"Left"===l||"Right"===l?"Horizontal":"Vertical"},!0),n.segments.push(c);else if(t===Ae.Three){var d={x:.5*((u=e[1]).x+(p=e[e.length-2]).x),y:.5*(u.y+p.y)},f=(o={angle:Gt(i,u),distance:.5*z.findLength(i,u)},a={angle:Gt(d,u),distance:.5*z.findLength(d,u)},z.direction(i,u)),v=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,point:d,orientation:"Left"===f||"Right"===f?"Horizontal":"Vertical"},!0);n.segments.push(v);var y={angle:Gt(d,p),distance:.5*z.findLength(d,p)},S={angle:Gt(r,p),distance:.5*z.findLength(r,p)},b=z.direction(d,p),w=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:y,vector2:S,orientation:"Left"===b||"Right"===b?"Horizontal":"Vertical"},!0);n.segments.push(w)}else if(t===Ae.Four){var D={x:.5*((u=e[1]).x+(p=e[2]).x),y:.5*(u.y+p.y)},A={x:.5*(p.x+(C=e[3]).x),y:.5*(p.y+C.y)};o={angle:Gt(i,u),distance:.5*z.findLength(i,u)},a={angle:Gt(D,u),distance:.5*z.findLength(D,u)},f=z.direction(i,u),v=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,point:D,orientation:"Left"===f||"Right"===f?"Horizontal":"Vertical"},!0),n.segments.push(v),y={angle:Gt(D,p),distance:.5*z.findLength(D,p)},S={angle:Gt(A,p),distance:.5*z.findLength(A,p)},b=z.direction(D,p),w=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:y,vector2:S,point:A,orientation:"Left"===b||"Right"===b?"Horizontal":"Vertical"},!0),n.segments.push(w);var x={angle:Gt(A,C),distance:.5*z.findLength(A,C)},R={angle:Gt(r,C),distance:.5*z.findLength(r,C)},L=z.direction(A,C),N=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:x,vector2:R,orientation:"Left"===L||"Right"===L?"Horizontal":"Vertical"},!0);n.segments.push(N)}else if(t===Ae.Five){var u,p,C,T=e[4],P=(D={x:.5*((u=e[1]).x+(p=e[2]).x),y:.5*(u.y+p.y)},A={x:.5*(p.x+(C=e[3]).x),y:.5*(p.y+C.y)},{x:.5*(C.x+T.x),y:.5*(C.y+T.y)});o={angle:Gt(i,u),distance:.5*z.findLength(i,u)},a={angle:Gt(D,u),distance:.5*z.findLength(D,u)},f=z.direction(i,u),v=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,point:D,orientation:"Left"===f||"Right"===f?"Horizontal":"Vertical"},!0),n.segments.push(v),y={angle:Gt(D,p),distance:.5*z.findLength(D,p)},S={angle:Gt(A,p),distance:.5*z.findLength(A,p)},b=z.direction(D,p),w=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:y,vector2:S,point:A,orientation:"Left"===b||"Right"===b?"Horizontal":"Vertical"},!0),n.segments.push(w),x={angle:Gt(A,C),distance:.5*z.findLength(A,C)},R={angle:Gt(P,C),distance:.5*z.findLength(P,C)},L=z.direction(A,C),N=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:x,vector2:R,point:P,orientation:"Left"===L||"Right"===L?"Horizontal":"Vertical"},!0),n.segments.push(N);var _={angle:Gt(P,T),distance:.5*z.findLength(P,T)},B={angle:Gt(r,T),distance:.5*z.findLength(r,T)},j=z.direction(P,T),oe=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:_,vector2:B,orientation:"Left"===j||"Right"===j?"Horizontal":"Vertical"},!0);n.segments.push(oe)}else c=new ps(n,"segments",{type:"Bezier"},!0),n.segments.push(c)}else for(var ue=0;ue=13?13:n.connectorSpacing<=1?1:n.connectorSpacing}function Gt(n,t){var i=z.findLength({x:t.x,y:n.y},t),r=z.findLength(t,n),s=Math.asin(i/r);return s=180*s/Math.PI,n.xt.y&&(s=360-s):s=n.y0)for(var l=1;lc)&&(s=c,a=h),s>=0&&s<=1)break}}return a}function g3(n,t){var c,d,u,p,f,g,S,b,M,w,D,e=n.x1,i=n.y1,r=n.x2,s=n.y2,o=t.x1,a=t.y1,l=t.x2,h=t.y2;if(w=(c=s-i)*l+(u=e-r)*h+(f=r*i-e*s),0!==(M=c*o+u*a+f)&&0!==w&&v3(M,w)||(b=(d=h-a)*r+(p=o-l)*s+(g=l*a-o*h),0!==(S=d*e+p*i+g)&&0!==b&&v3(S,b)))return null;var A=c*p-d*u;return 0===A?null:(A<0?-A/2:A/2,0,{x:(D=u*g-p*f)<0?(D-0)/A:(D+0)/A,y:(D=d*f-c*g)<0?(D-0)/A:(D+0)/A})}function v3(n,t){return n*t>=0}function m3(n,t,e){switch(t.direction){case"Left":t.point.x>n.left&&(e=t.point.x-n.left>e?t.point.x-n.left+e:e);break;case"Right":t.point.xe?n.right-t.point.x+e:e);break;case"Top":t.point.y>n.top&&(e=t.point.y-n.top>e?t.point.y-n.top+e:e);break;case"Bottom":t.point.ye?n.bottom-t.point.y+e:e)}return e}function Ll(n,t){var e;switch(n.direction){case"Left":case"Right":var i={x:t.point.x,y:n.point.y};e=z.equals(n.point,i)||z.equals(t.point,i)?[n.point,t.point]:[n.point,i,t.point];break;case"Top":case"Bottom":var r={x:n.point.x,y:t.point.y};e=z.equals(n.point,r)||z.equals(t.point,r)?[n.point,t.point]:[n.point,r,t.point]}return e}function Ys(n,t,e,i,r,s){void 0===s&&(s=!1),i||(i=20),s&&t.direction!==e.direction&&(i="Left"===t.direction||"Right"===t.direction?Math.floor(.5*Math.abs(t.point.x-e.point.x)):Math.floor(.5*Math.abs(t.point.y-e.point.y)));var l,h,u,o=n.sourcePortWrapper,c=e.point.x-t.point.x,d=e.point.y-t.point.y;if(!r&&(Math.abs(c)<.001||Math.abs(d)<.001)&&void 0===e.direction)return[t.point,e.point];if(void 0===n.targetWrapper&&Math.abs(c)<=31&&Math.abs(d)<=31){if("Left"===t.direction||"Right"===t.direction?Math.abs(d)<12&&(t.direction=t.point.y>e.point.y?"Top":"Bottom"):Math.abs(c)<12&&(t.direction=t.point.x>e.point.x?"Left":"Right"),Math.abs(c)>12||Math.abs(d)>12)return Ll(t,e);i+=5}return"Left"===t.direction||"Right"===t.direction?("Right"===t.direction?(void 0!==e.direction&&"Right"===e.direction&&(i=Math.max(t.point.x,e.point.x)-t.point.x+i),t.point.x>e.point.x&&void 0===o&&(i=-i)):(void 0!==e.direction&&"Left"===e.direction&&(i=t.point.x-Math.min(t.point.x,e.point.x)+i),(t.point.x>e.point.x||void 0!==o||"Left"===t.direction)&&(i=-i)),u=e.point.y-t.point.y,l=Bn(t.point,i,0),0!=(u=e.point.y-l.y)&&(h=Bn(l,e.point.y-l.y,90))):("Top"===t.direction||"Bottom"===t.direction)&&("Bottom"===t.direction?void 0!==e.direction&&"Bottom"===e.direction&&(i=Math.max(t.point.y,e.point.y)-t.point.y+i):(void 0!==e.direction&&"Top"===e.direction&&(i=t.point.y-Math.min(t.point.y,e.point.y)+i),(t.point.y>e.point.y||void 0!==o||"Top"===t.direction)&&(i=-i)),u=e.point.x-t.point.x,l=Bn(t.point,i,90),0!=(u=e.point.x-l.x)&&(h=Bn(l,e.point.x-l.x,0))),0===u?[t.point,e.point]:[t.point,l,h,e.point]}function bI(n,t,e,i,r,s){var o;switch(void 0===r&&(r=20),void 0===s&&(s=!1),void 0===e?(n.margin={left:2,right:2,top:2,bottom:2},t.margin={left:0,right:5,top:0,bottom:5},s&&(n.margin={left:10,right:10,top:10,bottom:10},t.margin={left:10,right:10,top:10,bottom:10},"Left"===n.direction?(r=Nx(n,t,e,r),n.corners.left-t.corners.right>=5&&(r=Math.abs(n.point.x-n.corners.left)+.5*Math.floor(n.corners.left-t.corners.right))):"Right"===n.direction?(r=Ox(n,t,r,e),t.corners.left-n.corners.right>=5&&(r=Math.abs(n.point.x-n.corners.right)+.5*Math.floor(t.corners.left-n.corners.right))):"Top"===n.direction?(r=Lx(n,t,e,r),n.corners.top-t.corners.bottom>=5&&(r=Math.abs(n.point.y-n.corners.top)+.5*Math.floor(n.corners.top-t.corners.bottom))):"Bottom"===n.direction&&(r=kx(n,t,r,e),t.corners.top-n.corners.bottom>=5&&(r=Math.abs(n.point.y-n.corners.bottom)+.5*Math.floor(t.corners.top-n.corners.bottom))))):("Bottom"===n.direction?s?t.corners.top-n.corners.bottom<20&&(r=t.corners.bottom-n.point.y+25):t.corners.top>n.corners.bottom&&t.corners.top-n.corners.bottom<20&&(r=(t.corners.top-n.corners.bottom)/2):"Top"===n.direction?s?n.corners.top-t.corners.bottom<20&&(r=n.point.y-t.corners.top+25):t.corners.bottomn.corners.right&&t.corners.left-n.corners.right<20&&(r=(t.corners.left-n.corners.right)/2):"Left"===n.direction&&(s?n.corners.left-t.corners.right<20&&(r=n.point.x-t.corners.left+25):t.corners.rightt.point.y||"Top"===t.direction&&n.point.yt.point.x||"Left"===t.direction&&n.point.xh||e.corners.top-e.margin.top<=i.point.y&&e.corners.bottom+e.margin.bottom>=i.point.y))if(!s||"Top"!==e.direction&&"Bottom"!==e.direction)c=Math.min(Math.abs(i.corners.left-e.corners.right)/2,20),h=e.corners.right-n.x+c;else{var c=Math.abs(i.corners.left-e.corners.right)/2;h=e.corners.right-n.x+c}else h="Top"===e.direction&&n.y>i.point.y||"Bottom"===e.direction&&n.y=e.corners.left-e.margin.left&&n.x<=e.corners.right+e.margin.right?Math.min(i.corners.left,e.corners.left)-n.x-20:i.corners.left-n.x-20;break;case"Right":if(e.corners.left-e.margin.left>i.corners.right+i.margin.right&&(e.corners.left-e.margin.right-i.corners.right>h||e.corners.top-e.margin.top<=i.point.y&&e.corners.bottom+e.margin.bottom>=i.point.y))if(!s||"Top"!==e.direction&&"Bottom"!==e.direction)c=Math.min(Math.abs(e.corners.left-i.corners.right)/2,20),h=e.corners.left-n.x-c;else{c=Math.abs(e.corners.left-i.corners.right)/2;h=e.corners.left-n.x-c}else h="Top"===e.direction&&n.y>i.point.y||"Bottom"===e.direction&&n.y=e.corners.left-e.margin.left&&n.x<=e.corners.right+e.margin.right?Math.max(i.corners.right,e.corners.right)-n.x+20:i.corners.right-n.x+20}o=Bn(n,h,0),a=Bn(o,i.point.y-n.y,90),l=i.point}else if("vertical"===t){switch(i.direction){case"Top":e.corners.bottom+e.margin.bottomh||e.corners.left-e.margin.left<=i.point.x&&e.corners.right+e.margin.right>=i.point.x)?!s||"Right"!==e.direction&&"Left"!==e.direction?(c=Math.min(Math.abs(i.corners.top-e.corners.bottom)/2,20),h=e.corners.bottom-n.y+c):(c=Math.abs(i.corners.top-e.corners.bottom)/2,h=e.corners.bottom-n.y+c):h="Left"===e.direction&&n.x>i.point.x||"Right"===e.direction&&n.x=e.corners.top-e.margin.top&&n.y<=e.corners.bottom+e.margin.bottom?Math.min(i.corners.top,e.corners.top)-n.y-20:i.corners.top-n.y-20;break;case"Bottom":e.corners.top-e.margin.top>i.corners.bottom+i.margin.bottom&&(e.corners.top-e.margin.top-i.corners.bottom>h||e.corners.left-e.margin.left<=i.point.x&&e.corners.right+e.margin.right>=i.point.x)?!s||"Right"!==e.direction&&"Left"!==e.direction?(c=Math.min(Math.abs(e.corners.top-i.corners.bottom)/2,20),h=e.corners.top-n.y-c):(c=Math.abs(e.corners.top-i.corners.bottom)/2,h=e.corners.top-n.y-c):h="Left"===e.direction&&n.x>i.point.x||"Right"===e.direction&&n.x=e.corners.top-e.margin.top&&n.y<=e.corners.bottom+e.margin.bottom?Math.max(i.corners.bottom,e.corners.bottom)-n.y+20:i.corners.bottom-n.y+20}o=Bn(n,h,90),a=Bn(o,i.point.x-n.x,0),l=i.point}r.push(o),r.push(a),r.push(l)}function Lx(n,t,e,i){return n.corners.top-n.margin.top>t.corners.top+t.margin.top&&n.corners.top-n.margin.top<=t.corners.bottom+t.margin.bottom?(("Right"===t.direction&&n.point.xt.point.x)&&(i+=n.corners.top-t.corners.top),i+=n.point.y-n.corners.top):i+=void 0!==e&&"Left"!==e&&"Right"===t.direction&&n.point.xt.corners.left-t.margin.left&&n.corners.left-n.margin.left<=t.corners.right+t.margin.right?(("Bottom"===t.direction&&n.point.yt.point.y)&&(i+=n.corners.left-t.corners.left),i+=n.point.x-n.corners.left):i+=void 0!==e&&"Top"!==e&&"Bottom"===t.direction&&n.point.y=t.corners.left-t.margin.left?(("Bottom"===t.direction&&n.point.yt.point.y)&&(e+=t.corners.right-n.corners.right),e+=n.corners.right-n.point.x):e+=void 0!==i&&"Top"!==i&&"Bottom"===t.direction&&n.point.y=t.corners.top-t.margin.top?(("Right"===t.direction&&n.point.xt.point.x)&&(e+=t.corners.bottom-n.corners.bottom),e+=n.corners.bottom-n.point.y):e+=void 0!==i&&"Left"!==i&&"Right"===t.direction&&n.point.xf&&d=u&&d=p&&d<=f?"Left":"Right"}function ls(n){switch(n){case"Top":return"Bottom";case"Bottom":return"Top";case"Left":return"Right";case"Right":return"Left"}return"auto"}var b3=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Ac=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},MI=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return b3(t,n),Ac([I()],t.prototype,"width",void 0),Ac([I()],t.prototype,"height",void 0),t}(Ee),Pre=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return b3(t,n),Ac([I()],t.prototype,"width",void 0),Ac([I()],t.prototype,"height",void 0),Ac([I()],t.prototype,"fit",void 0),Ac([I()],t.prototype,"description",void 0),Ac([I()],t.prototype,"template",void 0),Ac([I()],t.prototype,"tooltip",void 0),t}(Ee),zre=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Nl=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},M3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return zre(t,n),Nl([I("")],t.prototype,"id",void 0),Nl([I(Number.MIN_VALUE)],t.prototype,"zIndex",void 0),Nl([re({},$n)],t.prototype,"margin",void 0),Nl([I(!0)],t.prototype,"visible",void 0),Nl([re({},Ed)],t.prototype,"tooltip",void 0),Nl([I(!1)],t.prototype,"excludeFromLayout",void 0),Nl([I()],t.prototype,"addInfo",void 0),Nl([I("None")],t.prototype,"flip",void 0),Nl([I("All")],t.prototype,"flipMode",void 0),Nl([re({},Pre)],t.prototype,"symbolInfo",void 0),t}(Ee),Rre=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Jn=function(n){function t(e,i,r,s){var o=n.call(this)||this;return o.data="",o.nodeId="",o.annotationId="",o.diagramId="",o.diagramId=i,o.nodeId=e,o.annotationId=r,o.templateFn=FF(s),o}return Rre(t,n),t.prototype.getNodeTemplate=function(){return this.templateFn},Object.defineProperty(t.prototype,"content",{get:function(){return this.data},set:function(e){this.data=e,this.canReset||(this.canReset=!0,this.isTemplate||(this.template=Rh(this,!0)),this.canReset=!1,this.isDirt=!0)},enumerable:!0,configurable:!0}),t}(as),Px=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),hs=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},w3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Px(t,n),hs([I("")],t.prototype,"id",void 0),hs([I("transparent")],t.prototype,"fill",void 0),hs([I("black")],t.prototype,"iconStrokeColor",void 0),hs([I(0)],t.prototype,"iconStrokeWidth",void 0),hs([I(!0)],t.prototype,"visibility",void 0),hs([I(10)],t.prototype,"width",void 0),hs([I(10)],t.prototype,"height",void 0),hs([I("transparent")],t.prototype,"handleStrokeColor",void 0),hs([I(1)],t.prototype,"handleStrokeWidth",void 0),hs([I("")],t.prototype,"pathData",void 0),hs([I(0)],t.prototype,"cornerRadius",void 0),hs([re({left:0,right:0,top:0,bottom:0},$n)],t.prototype,"padding",void 0),hs([re({},Ed)],t.prototype,"tooltip",void 0),t}(Ee),C3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Px(t,n),hs([re({x:0,y:0},z)],t.prototype,"offset",void 0),hs([re({},$n)],t.prototype,"margin",void 0),t}(w3),wI=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Px(t,n),hs([I(.5)],t.prototype,"offset",void 0),hs([I("Center")],t.prototype,"alignment",void 0),hs([re({x:0,y:0},z)],t.prototype,"displacement",void 0),t}(w3);function Dd(n){return n?n instanceof Zn||n instanceof Nr?n.constraints&Lr.Select:n instanceof de?n.constraints&qe.Select:n.constraints&ie.Select:1}function to(n){return n?n instanceof Zn||n instanceof Nr?n.constraints&Lr.Drag:n instanceof de?n.constraints&qe.Drag:n instanceof si?1:n.constraints&ie.Drag:1}function Hre(n,t){return n instanceof de?n.constraints&qe.PointerEvents:n.constraints&ie.PointerEvents}function CI(n){return n instanceof de?n.constraints&qe.Delete:n.constraints&ie.Delete}function EI(n){return n.constraints&qe.DragSourceEnd}function DI(n){return n.constraints&qe.DragTargetEnd}function xI(n){return n.constraints&qe.DragSegmentThumb}function TI(n){return n instanceof Zn||n instanceof Nr?n.constraints&Lr.Rotate:n.constraints&ie.Rotate}function AI(n){return n.constraints&ie.Shadow}function da(n){return n instanceof te&&n.constraints&ie.InConnect?n.constraints&ie.InConnect:0}function Lh(n){return n&&n.constraints&&!(n.constraints&ri.None)&&n.constraints&ri.InConnect?n.constraints&ri.InConnect:0}function Nh(n){return n instanceof te&&n.constraints&ie.OutConnect?n.constraints&ie.OutConnect:0}function xd(n){return n&&n.constraints&&!(n.constraints&ri.None)&&n.constraints&ri.OutConnect?n.constraints&ri.OutConnect:0}function Ol(n,t){var e=0;return n instanceof Zn||n instanceof Nr?e=n.constraints&Lr.Resize:n&&("SouthEast"===t?e=n.constraints&ie.ResizeSouthEast:"East"===t?e=n.constraints&ie.ResizeEast:"NorthEast"===t?e=n.constraints&ie.ResizeNorthEast:"South"===t?e=n.constraints&ie.ResizeSouth:"North"===t?e=n.constraints&ie.ResizeNorth:"SouthWest"===t?e=n.constraints&ie.ResizeSouthWest:"West"===t?e=n.constraints&ie.ResizeWest:"NorthWest"===t&&(e=n.constraints&ie.ResizeNorthWest)),e}function LI(n){return n instanceof de?n.constraints&qe.AllowDrop:n.constraints&ie.AllowDrop}function Ds(n){return n.constraints&rt.Virtualization}function Bv(n){return n.tool&Ci.SingleSelect}function Fv(n){return n.tool&Ci.MultipleSelect}function Lc(n){return n.tool&Ci.ZoomPan}function NI(n){return n.tool&Ci.ContinuousDraw}function E3(n){return n.tool&Ci.DrawOnce}function OI(n){return n.tool&Ci.SingleSelect||n.tool&Ci.MultipleSelect}function _v(n){return n.constraints&rt.UserInteraction}function D3(n){return n.constraints&rt.ZoomTextEdit}function Uv(n){return function Vre(n){return n.constraints&rt.ApiUpdate}(n)||n.diagramActions&ee.ToolAction}function zx(n,t){return n.constraints&ri.Draw}function Rx(n,t){return n.constraints&ri.Drag}function kI(n){return!(n&Qa.DrawSelectorBorder)}function x3(n){return!!(n&Qa.PreventRenderSelector)}var Hx=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),jv=function(n){function t(){var e=null!==n&&n.apply(this,arguments)||this;return e.childTable=[],e.cellStyle={},e.desiredRowHeight=[],e.desiredCellWidth=[],e}return Hx(t,n),t.prototype.rowDefinitions=function(){return this.rowDefns},t.prototype.columnDefinitions=function(){return this.colDefns},t.prototype.addObject=function(e,i,r,s,o){if(this.rows.length>=i){var a=this.rows[parseInt(i.toString(),10)];if(a.cells.length>r){o=o||1,s=s||1;var l=a.cells[parseInt(r.toString(),10)];l.columnSpan=Math.max(o,l.columnSpan),l.rowSpan=Math.max(s,l.rowSpan);var h=new Xre;(h=e).rowId=i,h.columnId=r,h.columnSpan=o,this.childTable[h.id]=h,this.addObjectToCell(h,l)}}},t.prototype.addObjectToCell=function(e,i){i.children||(i.children=[]),e.style.strokeColor="black",e.style.strokeWidth=1,i.children.push(e)},t.prototype.updateProperties=function(e,i,r,s){this.offsetX=e,this.offsetY=i,this.width=r,this.height=s},t.prototype.setDefinitions=function(e,i){this.rowDefns=e,this.colDefns=i,this.children=[],this.rows=this.rows||[];for(var r=0;r0){for(var h=0;hi&&this.updateRowHeight(e,l,!1)}},t.prototype.setTextRefresh=function(e){if(e.children&&e.children.length)for(var i=e.children,r=0;ri&&this.updateColumnWidth(e,a,!1)}},t.prototype.calculateCellWidth=function(e){for(var i,r,s,o=0;os.bounds.width&&(0===s.children.length||void 0===s.children[0].maxWidth)?s.outerBounds.width:s.bounds.width,i=i?is.bounds.height?s.outerBounds.height:s.bounds.height,i=i?i0?e.children[0]:void 0;if(a&&1===e.columnSpan){o="Width"===i?a.bounds.right:a.bounds.bottom,s||(s="Width"===i?a.bounds.width:a.bounds.height);for(var l=0;lo){var d=c-o+("Width"===i?a.bounds.width:a.bounds.height);s&&(s=s0?this.rowDefns.splice(e,0,i):this.rowDefns.push(i);var s=new T3;s.cells=[],(new Td).width=this.width,this.addCellInRow(this.colDefns,i,s),e>this.rows.length-1?this.rows.push(s):this.rows.splice(e,0,s),r&&(this.measure(new me(this.width,this.height)),this.arrange(this.desiredSize))},t.prototype.addColumn=function(e,i,r){var s,o,a,l,h=this.rows;this.colDefns.length>0?this.colDefns.splice(e,0,i):this.colDefns.push(i),void 0!==this.width&&(this.width+=i.width);for(var c=0;cs.cells.length-1?s.cells.push(l):s.cells.splice(e,0,l),this.children.push(l);r&&(this.measure(new me(this.width,this.height)),this.arrange(this.desiredSize))},t.prototype.removeRow=function(e){var i,r,o=this.rows[parseInt(e.toString(),10)];this.height-=this.rowDefns[parseInt(e.toString(),10)].height;for(var a=0;a0){var r=0,s=0;i=new me(0,0),this.calculateSize();for(var o=0,a=this.rows;o0){for(var o=this.offsetX-e.width*this.pivot.x,a=this.offsetY-e.height*this.pivot.y,l=o,h=0,c=this.rows;h1&&this.children.splice(this.children.indexOf(f)+1,f.columnSpan-1),f.rowSpan>1)for(y=s,S=0;y+f.rowSpan-10){for(var c=0;c0?1:0,v=0;v0||a.outEdges.length>0))for(p=a.inEdges.concat(a.outEdges),s=0;s0)for(o=0;o1)for(a=1;a0))if(h=n.wrapper.children[0],"Horizontal"===e.orientation)for(o=e.header&&e.hasHeader?h.rows[1]:h.rows[0],r=0;r0){var e=void 0;t.lineRoutingModule&&t.constraints&rt.LineRouting&&t.lineRoutingModule.renderVirtualRegion(t,!0);for(var i=0;i0?o+1:o)].height=t.wrapper.height;else if(t.isPhase)for(l[t.rowIndex-o].offset=t.wrapper.height,f=0;f0?1:0)].width=t.wrapper.width}function zI(n,t){var i=n.shape,r=i.header&&i.hasHeader?1:0;return"Horizontal"===i.orientation?t.rowIndex-(r+=i.phases.length>0?1:0):t.columnIndex-(i.phaseSize&&i.phases.length>0?1:0)}function RI(n){var t=0,e=n.shape;return"Horizontal"===e.orientation&&(t=e.header&&e.hasHeader?1:0),e.phases.length>0&&e.phaseSize&&(t+=1),t}function HI(n,t,e,i){var r=n.shape;if(r.phases.length>0){var s=t.nameTable[r.phases[parseInt(i.toString(),10)].header.id];s&&s.maxWidth0?u+1:u);var w=Nc(n,o),C=void 0!==i?i:l.lanes.length;if(u+=C,r={element:M,cause:n.diagramActions,diagramAction:n.getDiagramAction(n.diagramActions),state:"Changing",type:"Addition",cancel:!1,laneIndex:C},n.triggerEvent(Ce.collectionChange,r),!r.cancel){if(c){var D=new Vv;D.height=e.height,o.addRow(u,D,!1),s.height=void 0!==s.height?s.height+e.height:s.height,s.wrapper.height=o.height=s.height}else{var A=new Td;A.width=e.width,o.addColumn(C+1,A,!1),s.width&&(s.width+=e.width,s.wrapper.width=o.width=s.width),n.diagramActions&ee.UndoRedo||(o.rows[0].cells[0].columnSpan+=1)}n.diagramActions&ee.UndoRedo||(M.id=""===M.id?Qe():M.id),void 0!==i?l.lanes.splice(i,0,M):l.lanes.push(M),r={element:M,cause:n.diagramActions,diagramAction:n.getDiagramAction(n.diagramActions),state:"Changed",type:"Addition",cancel:!1,laneIndex:C},n.triggerEvent(Ce.collectionChange,r),L3(o,n,s,u,C,c),h="Horizontal"===l.orientation?n.nameTable[o.rows[parseInt(u.toString(),10)].cells[0].children[0].id]:l.header&&l.hasHeader?n.nameTable[o.rows[1].cells[parseInt(u.toString(),10)].children[0].id]:n.nameTable[o.rows[0].cells[parseInt(u.toString(),10)].children[0].id],n.diagramActions&ee.UndoRedo||(d={type:"LaneCollectionChanged",changeType:"Insert",undoObject:$(M),redoObject:$(h),category:"Internal"},n.addHistoryEntry(d)),Gp(n,s,"Horizontal"===l.orientation?u:l.header&&l.hasHeader?1:0),Qp(s),Oc(n,s);var R=!1;if((p=e.children)&&p.length>0)for(f=0;f0){var o=t.children[0],a=n.nameTable[o.id];(function rne(n,t,e){return n.left-(e.left||0)<=t.x&&n.right+(e.right||0)>=t.x&&n.top-(e.top||0)<=t.y&&n.bottom+(e.bottom||0)>=t.y})(o.bounds,e,r)&&(n.addChild(a,i),s=!0)}return s}function nne(n,t,e){if("SwimLane"===t.shape.type){var i=void 0,r=void 0,s=void 0,a=void 0,l=void 0,h=void 0,c=t.wrapper.bounds.x,d=t.wrapper.bounds.y,u=t.shape,p=u.padding,f=u.phases,g=void 0,v=t.wrapper.children[0],y="Horizontal"===u.orientation;if(i=u.header&&u.hasHeader?0:-1,u.phases.length>0&&(i+=1),e.offset>(y?u.lanes[0].header.width:u.lanes[0].header.height)){for(h=0;he.offset){if(g=h>0?e.offset-(h>0?f[h-1]:s).offset:e.offset,y){var b=v.columnDefinitions()[parseInt(h.toString(),10)];b.width-=g,(a=n.nameTable[u.phases[parseInt(h.toString(),10)].header.id]).maxWidth=a.wrapper.maxWidth=b.width,v.updateColumnWidth(h,b.width,!1);var M=new Td;M.width=g,l=h,v.addColumn(h,M,!1);break}var w=v.rowDefinitions()[h+i];w.height-=g,a=n.nameTable[u.phases[parseInt(h.toString(),10)].header.id],v.updateRowHeight(h+i,w.height,!1);var C=new Vv;C.height=g,l=h,v.addRow(h+i,C,!1);break}if(n.diagramActions&ee.UndoRedo&&void 0===l&&(D=n.historyManager.currentEntry.next).isLastPhase&&function sne(n,t,e,i,r,s){var a=t.shape.phases[n-2],l=e.previousPhase.offset;if(r){var h=i.columnDefinitions()[n-1],c=new Td;n>1?(c.width=h.width-(l-a.offset),h.width=l-a.offset):(c.width=h.width-l,h.width=l),i.updateColumnWidth(n-1,h.width,!1),i.addColumn(n,c,!1)}else{h=i.rowDefinitions()[parseInt(n.toString(),10)];var d=new Vv;n>1?(d.height=e.undoObject.offset-l,h.height=l-a.offset):(d.height=h.height-l,h.height=l),i.updateRowHeight(n,h.height,!1),i.addRow(1+n,d,!1)}}(l=f.length,t,D,v,y),l>=0){var A=new sb(t.shape,"phases",e,!0);if(n.diagramActions&ee.UndoRedo||(A.id+=Qe()),u.phases.splice(l,0,A),Bx(v,n,t,i,y,l),y){if(r=n.nameTable[v.rows[parseInt(i.toString(),10)].cells[parseInt(l.toString(),10)].children[0].id],0===l&&u.header&&u.hasHeader){v.rows[0].cells[0].children=v.rows[0].cells[1].children,v.rows[0].cells[1].children=[];for(var x=v.rows[0],R=0;Rl+1){var O=n.nameTable[v.rows[parseInt(i.toString(),10)].cells[l+1].children[0].id];v.updateColumnWidth(l+1,L[l+1].width,!0,p),O.maxWidth=O.wrapper.maxWidth=L[l+1].width}t.width=t.wrapper.width=t.wrapper.children[0].width=v.width}else{r=n.nameTable[v.rows[i+l].cells[0].children[0].id];var N=v.rowDefinitions(),T=N[i+l].height;(function ane(n,t,e,i,r){for(var o,a,l=e.rows[parseInt(i.toString(),10)],h=e.rows[i+1],c=e.rows[i-1],d=1;di+l+1&&v.updateRowHeight(i+l+1,T=N[i+l+1].height,!0,p),t.height=t.wrapper.height=t.wrapper.children[0].height=v.actualSize.height}if(Qp(t),t.width=t.wrapper.actualSize.width,Oc(n,t),n.drag(t,c-t.wrapper.bounds.x,d-t.wrapper.bounds.y),PI(t,n),n.commandHandler.select(r),!(n.diagramActions&ee.UndoRedo)){var D={type:"PhaseCollectionChanged",changeType:"Insert",undoObject:$(A),redoObject:$(r),category:"Internal"};n.addHistoryEntry(D)}n.updateDiagramObject(t)}}}}function z3(n,t,e,i,r,s,o){var a,l,f,h=t.shape,c="Horizontal"===h.orientation,d=t.wrapper.children[0],g=c?s:o;e?(a=c?e.bounds.x+e.bounds.width:e.bounds.x,l=c?e.bounds.y:e.bounds.y+e.bounds.height):(a=d.bounds.x,l=r.bounds.y);var v=new Ne(a,l,i.desiredCellWidth,i.desiredCellHeight),S=Wv(n,0,t,{id:t.id+(c?h.lanes[g-2]:h.lanes[g-1]).id+Qe()[0],rowIndex:s,columnIndex:o,width:i.minWidth,height:i.minHeight,style:(c?h.lanes[g-2]:h.lanes[g-1]).style,constraints:ie.Default|ie.AllowDrop,container:{type:"Canvas",orientation:c?"Horizontal":"Vertical"}},!1,!1,!0);if(S.children[0].isCalculateDesiredSize=!1,d.addObject(S,s,o),r&&r.children&&r.children.length)for(f=0;f1)for(var f=1;fh.margin.left&&(h.margin.left=p)):(h.margin.top-=e.desiredCellHeight,p>h.margin.top&&(h.margin.top=p)))}(n,r,i,v,S,c,e)}function R3(n,t,e){if("SwimLane"===t.shape.type&&("ResizeSouth"===e||"ResizeEast"===e)){var i=t.shape,r=t.wrapper.children[0],s=void 0,o=void 0;"ResizeSouth"===e?"Vertical"===i.orientation?s=r.rows[r.rows.length-1].cells[0]:(o=r.rows.length-1,s=r.rows[parseInt(o.toString(),10)].cells[r.rows[parseInt(o.toString(),10)].cells.length-1]):(o=i.header&&i.hasHeader?1:0,s=r.rows[parseInt(o.toString(),10)].cells[r.rows[parseInt(o.toString(),10)].cells.length-1]),n.commandHandler.select(n.nameTable[s.children[0].id])}}function BI(n,t,e,i,r,s){var o,a,l,c,u,p,f,d=Qe(),g=n.shape,v=g.phases,y=n.offsetX-n.wrapper.actualSize.width/2,S=n.offsetY-n.wrapper.actualSize.height/2;if("Vertical"===g.orientation&&(S+=g.header&&g.hasHeader?g.header.height:0),!s)for(r||(n.id+=d,g&&g.header&&g.hasHeader?g.header.id+=d:g.header=void 0),o=0;v&&o0&&s.columnIndex>0||s.isLane)?(a=function mne(n,t,e){for(var i=new Ne,r="SwimLane"===n.shape.type?n.wrapper.children[0].rows:n.wrapper.rows,s=e?1:0;s=0;a--)i?i.id===o.children[parseInt(a.toString(),10)].id&&o.children.splice(a,1):(n.removeDependentConnector(o.children[parseInt(a.toString(),10)]),n.diagramActions&ee.UndoRedo||(n.diagramActions=n.diagramActions|ee.UndoRedo,s=!0),n.remove(o.children[parseInt(a.toString(),10)]),o.children.splice(a,1),s&&(n.diagramActions=n.diagramActions&~ee.UndoRedo))}function hne(n){return n.children[0]}function Gv(n,t){t&&(n.nodes.splice(n.nodes.indexOf(t),1),n.removeFromAQuad(t),n.removeObjectsFromLayer(t),delete n.nameTable[t.id],n.removeElements(t))}function B3(n,t,e,i){var r;if("SwimLane"===e.shape.type){var s=e.shape,o=void 0;if(1===s.lanes.length)n.remove(e);else{var a=e.wrapper.bounds.x,l=e.wrapper.bounds.y,h=void 0,c=void 0,d=void 0,u=void 0,f=e.wrapper.children[0];if(o=i?s.lanes.indexOf(i):zI(e,t),r={element:t,cause:n.diagramActions,diagramAction:n.getDiagramAction(n.diagramActions),state:"Changing",type:"Removal",cancel:!1,laneIndex:o},n.triggerEvent(Ce.collectionChange,r),!r.cancel){var g=s.lanes[parseInt(o.toString(),10)],v=g.children;g.children=[];for(var y=0;y0)for(u=0;u0)for(u=0;u0)for(e=0;e1){c===l.phases.length-1&&(o=!0,a=$(l.phases[c-1]));var u=$(l.phases[parseInt(c.toString(),10)]);if(l.phases.splice(c,1),!(n.diagramActions&ee.UndoRedo)){var p={type:"PhaseCollectionChanged",changeType:"Remove",undoObject:u,previousPhase:a,redoObject:$(t),category:"Internal",isLastPhase:o};n.addHistoryEntry(p)}"Horizontal"===l.orientation?function dne(n,t,e,i){var r,s,o,a,l,h,c,d,u,p,f,g;for(i=void 0!==i?i:e.columnIndex,c=0;c1&&(s=r.cells[parseInt(i.toString(),10)],l=(o=r.cells.length-1===i?r.cells[i-1]:r.cells[i+1]).children[0],s.children.length>0))if(f=n.nameTable[(a=s.children[0]).id],0===o.children.length&&s.children.length>0)o.children=s.children,o.columnSpan=s.columnSpan-1;else{for(d=0;d0){var M=s.children[0],w=n.nameTable[M.id];if(i=e.x&&a.bounds.y<=e.y&&a.bounds.bottom>=e.y)&&!(t.constraints&ie.AllowMovingOutsideLane)){var l=$(t);n.clearSelection(),j3(n,t),t.parentId="",t.parentObj=n,t.propName="nodes";var h={type:"ChildCollectionChanged",category:"Internal",undoObject:l,redoObject:$(t)};n.addHistoryEntry(h),n.commandHandler.isContainer&&(n.commandHandler.isContainer=!1,n.endGroupAction()),V3(t,n)}n.protectPropertyChange(o)}}function FI(n,t){var e,i,r;return n.enableServerDataBinding(!1),ce()||(n.selectedObject.helperObject?r=n.selectedObject.helperObject:(n.selectedItems.nodes.length>0||n.selectedItems.connectors.length>0)&&(t instanceof si&&t.nodes.length+t.connectors.length===1?(e=t.nodes.length>0?t.nodes[0]:t.connectors[0],i=n.selectedItems.wrapper.children[0]):(e=t,i=n.selectedItems.wrapper),n.selectedObject.actualObject=e,!n.currentSymbol&&(e.isLane&&jx(e,n)&&cs(n,e)||!e.isLane&&cs(n,e)||n.constraints&rt.LineRouting&&n.selectedItems.nodes.length>0))&&(r=function yne(n,t){for(var e,i={},r=0,s=Object.keys(t);r=t.x-e&&n.x<=t.x+e&&n.y>=t.y-e&&n.y<=t.y+e}function Xa(n){return n.selectedItems.nodes.length>0||n.selectedItems.connectors.length>0}function Y3(n){return 1===n.selectedItems.connectors.length&&!n.selectedItems.nodes.length}function _r(n,t,e,i){if(void 0===e&&(e=!0),t instanceof si)return!0;if(t instanceof te)for(;t;){if(-1!==n.selectedItems.nodes.indexOf(t)&&void 0===n.selectedItems.annotation)return!0;if(e)break;t=n.nameTable[t.parentId]}else if(t instanceof de){if(-1!==n.selectedItems.connectors.indexOf(t)&&void 0===n.selectedItems.annotation)return!0}else if((t instanceof Zn||t instanceof Nr)&&n.selectedItems.annotation&&n.selectedItems.wrapper.children[0].id===i.id)return!0;return!1}var Vx={None:"default",Rotate:"crosshair",Select:"default",Drag:"move",ResizeWest:"w-resize",ResizeEast:"e-resize",ResizeSouth:"s-resize",ResizeNorth:"n-resize",Draw:"crosshair",PortDraw:"crosshair",ResizeNorthEast:"ne-resize",ResizeNorthWest:"nw-resize",ResizeSouthEast:"se-resize",ResizeSouthWest:"sw-resize",ConnectorSourceEnd:"move",ConnectorTargetEnd:"move",BezierSourceThumb:"move",BezierTargetThumb:"move",OrthoThumb:"move",SegmentEnd:"move",Pan:"grab",Hyperlink:"pointer",PortDrag:"pointer",LabelSelect:"pointer",LabelDrag:"move",LabelRotate:"crosshair",LabelResizeWest:"w-resize",LabelResizeEast:"e-resize",LabelResizeSouth:"s-resize",LabelResizeNorth:"n-resize",LabelResizeNorthEast:"ne-resize",LabelResizeNorthWest:"nw-resize",LabelResizeSouthEast:"se-resize",LabelResizeSouthWest:"sw-resize"},ds=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Ld=function(n,t,e,i){return new(e||(e=Promise))(function(r,s){function o(h){try{l(i.next(h))}catch(c){s(c)}}function a(h){try{l(i.throw(h))}catch(c){s(c)}}function l(h){h.done?r(h.value):new e(function(c){c(h.value)}).then(o,a)}l((i=i.apply(n,t||[])).next())})},Nd=function(n,t){var i,r,s,o,e={label:0,sent:function(){if(1&s[0])throw s[1];return s[1]},trys:[],ops:[]};return o={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function a(h){return function(c){return function l(h){if(i)throw new TypeError("Generator is already executing.");for(;e;)try{if(i=1,r&&(s=2&h[0]?r.return:h[0]?r.throw||((s=r.return)&&s.call(r),0):r.next)&&!(s=s.call(r,h[1])).done)return s;switch(r=0,s&&(h=[2&h[0],s.value]),h[0]){case 0:case 1:s=h;break;case 4:return e.label++,{value:h[1],done:!1};case 5:e.label++,r=h[1],h=[0];continue;case 7:h=e.ops.pop(),e.trys.pop();continue;default:if(!(s=(s=e.trys).length>0&&s[s.length-1])&&(6===h[0]||2===h[0])){e=0;continue}if(3===h[0]&&(!s||h[1]>s[0]&&h[1]-1&&(r=i.fixedUserHandles[parseInt(o.toString(),10)]);this.commandHandler.triggerEvent(Ce.fixedUserHandleClick,{fixedUserHandle:r,element:e.source}),n.prototype.mouseUp.call(this,e)},t}(us),Od=function(n){function t(e,i){var r=n.call(this,e,!0)||this;return r.isConnected=!1,r.endPoint=i,r}return ds(t,n),t.prototype.mouseDown=function(e){return Ld(this,void 0,void 0,function(){var r,s,o,a,l;return Nd(this,function(h){if(this.inAction=!0,this.undoElement=void 0,this instanceof pa||(this.undoElement=$(e.source)),n.prototype.mouseDown.call(this,e),e.source&&e.source.connectors&&(this.oldConnector=$(r=e.source.connectors[0])),"BezierSourceThumb"===this.endPoint||"BezierTargetThumb"===this.endPoint)for(s=0;s0))},t.prototype.endAction=function(){n.prototype.endAction.call(this),this.prevPosition=null,this.endPoint=null},t}(us),ua=function(n){function t(e,i){var r=n.call(this,e,!0)||this;return r.currentTarget=null,r.isStartAction=!1,r.canCancel=!1,r.canTrigger=!1,r.objectType=i,r}return ds(t,n),t.prototype.mouseDown=function(e){if(e.source instanceof te||e.source instanceof de){var i=this.commandHandler.getSelectedObject();this.commandHandler.selectObjects([e.source],e.info&&e.info.ctrlKey,i);var r={nodes:[],connectors:[]};e.source instanceof te?r.nodes.push($(e.source)):r.connectors.push($(e.source)),this.undoElement=$(r)}else this.undoElement=$(e.source);this.undoParentElement=this.commandHandler.getSubProcess(e.source),"Port"===this.objectType&&(this.portId=e.sourceWrapper.id),this.commandHandler.insertBlazorConnector(e.source),n.prototype.mouseDown.call(this,e),this.initialOffset={x:0,y:0}},t.prototype.mouseUp=function(e,i){return Ld(this,void 0,void 0,function(){var s,o,a,l,h,c,d,u,f,g,v,y,S,b,M;return Nd(this,function(w){if(this.checkPropertyValue(),a=!1,h={nodes:[],connectors:[]},"Port"!==this.objectType){if(e.source instanceof te||e.source instanceof de?(e.source instanceof te?h.nodes.push($(e.source)):h.connectors.push($(e.source)),(o=$(h)).offsetX=(c=e.source.wrapper).offsetX,o.offsetY=c.offsetY):o=$(e.source),("helper"===(l=this.commandHandler.renderContainerHelper(e.source)||e.source||this.commandHandler.renderContainerHelper(e.source)).id||"helper"!==l.id)&&((l instanceof si&&(Math.round(l.width)===Math.round(this.undoElement.width)&&Math.round(l.height)===Math.round(this.undoElement.height)||l.selectedObjects&&1===l.selectedObjects.length)||!(l instanceof si))&&(l.offsetX!==this.undoElement.offsetX||l.offsetY!==this.undoElement.offsetY||l.sourcePoint!==this.undoElement.sourcePoint||l.targetPoint!==this.undoElement.targetPoint)||this.isSelectionHasConnector(l))&&(e.source&&(s={offsetX:e.source.wrapper.offsetX,offsetY:e.source.wrapper.offsetY}),g={source:e.source,state:"Completed",oldValue:this.intialValue,newValue:s,target:this.currentTarget,targetPosition:this.currentPosition,allowDrop:(g={source:e.source,state:"Completed",oldValue:this.intialValue,newValue:s,target:this.currentTarget,targetPosition:this.currentPosition,allowDrop:!0,cancel:!1}).allowDrop,cancel:g.cancel},d=!0,"helper"===l.id?this.canTrigger?(this.commandHandler.triggerEvent(Ce.positionChange,g),this.connectorEndPointChangeEvent(g),d=!0):d=!1:(this.commandHandler.triggerEvent(Ce.positionChange,g),this.connectorEndPointChangeEvent(g)),!i&&d&&(this.commandHandler.startGroupAction(),a=!0,M={type:"PositionChanged",redoObject:$(o),undoObject:$(this.undoElement),category:"Internal"},o.nodes[0]&&o.nodes[0].processId&&(u={type:"SizeChanged",category:"Internal",undoObject:this.undoParentElement,redoObject:this.commandHandler.getSubProcess(e.source)},this.commandHandler.addHistoryEntry(u)),this.commandHandler.addHistoryEntry(M))),this.commandHandler.snapPoint(this.prevPosition,this.currentPosition,0,0),this.commandHandler.removeSnap(),this.commandHandler.removeHighlighter(),e.source&&this.currentTarget&&LI(this.currentTarget)&&this.commandHandler.isDroppable(e.source,this.currentTarget)){if(f=!0,this.commandHandler.drop(this.currentElement,this.currentTarget,this.currentPosition),this.currentTarget&&this.currentTarget instanceof de&&!0===this.commandHandler.diagram.enableConnectorSplit)if(this.currentElement&&this.currentElement instanceof te){if(void 0!==this.currentElement.children)for(b=0;b0)for(var s=0;s0)for(var a=0;a0)for(a=0;a0&&e.connectors.length>0)||e.width===this.undoElement.width&&e.height===this.undoElement.height)},t.prototype.mouseMove=function(e){n.prototype.mouseMove.call(this,e);var r,s,i=!1;(r=this.commandHandler.renderContainerHelper(e.source)||e.source)instanceof te||r instanceof de?r instanceof te?r.offsetX===this.undoElement.nodes[0].offsetX&&r.offsetY===this.undoElement.nodes[0].offsetY&&(i=!0):z.equals(r.sourcePoint,this.undoElement.connectors[0].sourcePoint)&&z.equals(r.targetPoint,this.undoElement.connectors[0].targetPoint)&&(i=!0):r.wrapper.offsetX===this.undoElement.wrapper.offsetX&&r.wrapper.offsetY===this.undoElement.wrapper.offsetY&&(i=!0),r&&(s={offsetX:r.wrapper.offsetX,offsetY:r.wrapper.offsetY});var o={source:r,state:"Start",oldValue:s,newValue:s,target:e.target,targetPosition:e.position,allowDrop:!0,cancel:!1};if(o={source:r,state:"Start",oldValue:s,newValue:s,target:e.target,targetPosition:e.position,allowDrop:o.allowDrop,cancel:o.cancel},this.isStartAction||(this.intialValue={offsetX:r.wrapper.offsetX,offsetY:r.wrapper.offsetY}),i&&!ce()&&(this.commandHandler.triggerEvent(Ce.positionChange,o),this.connectorEndPointChangeEvent(o),this.isStartAction=!0),this.currentPosition=e.position,"Port"!==this.objectType){var h=this.initialOffset.x+(this.currentPosition.x-this.prevPosition.x),c=this.initialOffset.y+(this.currentPosition.y-this.prevPosition.y);this.commandHandler.dragOverElement(e,this.currentPosition),this.commandHandler.disConnect(e.source),this.commandHandler.removeSnap();var d,u=void 0,p=this.commandHandler.snapPoint(this.prevPosition,this.currentPosition,h,c);this.initialOffset.x=h-p.x,this.initialOffset.y=c-p.y,r&&(d={offsetX:r.wrapper.offsetX,offsetY:r.wrapper.offsetY},u={offsetX:r.wrapper.offsetX+p.x,offsetY:r.wrapper.offsetY+p.y}),this.currentTarget&&e.target!==this.currentTarget&&this.commandHandler.removeChildFromBPmn(e.source,e.target,this.currentTarget),this.currentTarget=e.target;var f={source:r,state:"Progress",oldValue:d,newValue:u,target:e.target,targetPosition:e.position,allowDrop:!0,cancel:!1};if(this.commandHandler.triggerEvent(Ce.positionChange,f),this.canTrigger=!0,this.connectorEndPointChangeEvent(f,p),!f.cancel&&!this.canCancel){this.blocked=!this.commandHandler.dragSelectedObjects(p.x,p.y);var g=!this.commandHandler.mouseOver(this.currentElement,this.currentTarget,this.currentPosition);this.blocked=this.blocked||g}if(this.commandHandler.removeStackHighlighter(),this.commandHandler.renderStackHighlighter(e),this.currentTarget&&e.source!==this.currentTarget&&this.commandHandler.isDroppable(e.source,this.currentTarget)&&"helper"!==e.source.id){var v=e.source instanceof si?e.source.nodes[0]:e.source;!this.commandHandler.isParentAsContainer(v,!0)&&"SwimLane"!==v.shape.type&&!v.shape.isPhase&&(this.currentTarget.isLane?this.commandHandler.renderStackHighlighter(e,this.currentTarget):this.commandHandler.drawHighlighter(this.currentTarget))}else this.commandHandler.removeHighlighter();if(this.commandHandler.canEnableDefaultTooltip()){var y=this.getTooltipContent(e.source);this.commandHandler.showTooltip(e.source,e.position,ko(function(){return y}),"MoveTool",this.isTooltipVisible),this.isTooltipVisible=!1}}else{var b=Hi(),M=e.source;qi(b,-M.rotateAngle||-M.wrapper.rotateAngle,M.offsetX||M.wrapper.offsetX,M.offsetY||M.wrapper.offsetY);var w=Je(b,{x:this.prevPosition.x,y:this.prevPosition.y}),C=Je(b,{x:e.position.x,y:e.position.y});this.commandHandler.portDrag(e.source,e.sourceWrapper,C.x-w.x,C.y-w.y)}return this.prevPosition=this.currentPosition,!this.blocked},t.prototype.getTooltipContent=function(e){return"X:"+Math.round(e.wrapper.bounds.x)+" Y:"+Math.round(e.wrapper.bounds.y)},t.prototype.mouseLeave=function(e){this.mouseUp(e)},t.prototype.endAction=function(){n.prototype.endAction.call(this),this.currentTarget=null,this.prevPosition=null},t}(us),Wx=function(n){function t(e){var i=n.call(this,e,!0)||this;return i.rotateStart=!1,i}return ds(t,n),t.prototype.mouseDown=function(e){if(this.undoElement=$(e.source),this.undoElement.nodes[0]&&this.undoElement.nodes[0].children)for(var r=this.commandHandler.getAllDescendants(this.undoElement.nodes[0],[]),s=0;s=2){var s=e.startTouches[0],o=e.startTouches[1],a=e.moveTouches[0],l=e.moveTouches[1],h=this.getDistance(a,l)/this.getDistance(s,o);this.commandHandler.zoom(h,0,0,e.position),this.updateTouch(s,a),this.updateTouch(o,l)}}else this.commandHandler.scroll(this.currentPosition.x-this.prevPosition.x,this.currentPosition.y-this.prevPosition.y,this.currentPosition);return this.commandHandler.dataBinding(),!this.blocked},t.prototype.mouseUp=function(e){this.commandHandler.setBlazorDiagramProps(!1),this.checkPropertyValue(),this.commandHandler.updatePanState(!1),n.prototype.mouseUp.call(this,e),this.inAction=!1},t.prototype.endAction=function(){n.prototype.endAction.call(this)},t.prototype.getDistance=function(e,i){var r=i.pageX-e.pageX,s=i.pageY-e.pageY;return Math.sqrt(r*r+s*s)},t.prototype.updateTouch=function(e,i){e.pageX=i.pageX,e.pageY=i.pageY},t}(us),Tne=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseUp=function(e){this.checkPropertyValue(),this.commandHandler.initExpand(e),n.prototype.mouseUp.call(this,e)},t}(us),Q3=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseUp=function(e){this.checkPropertyValue();var i="_blank",r="",s=window.innerHeight,o=window.innerWidth,a=window.screenTop,l=window.screenLeft;"CurrentTab"===e.sourceWrapper.hyperlink.hyperlinkOpenState?i="_self":"NewWindow"===e.sourceWrapper.hyperlink.hyperlinkOpenState&&(r="height="+s+",width="+o+",top="+a+",left="+l),window.open(e.sourceWrapper.hyperlink.link,i,r).focus(),n.prototype.mouseUp.call(this,e)},t}(us),Oh=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseDown=function(e){if(n.prototype.mouseDown.call(this,e),this.inAction=!0,this.drawingObject){var r=void 0,s=this.drawingObject.shape;this.drawingObject.shape.points.push(r={x:(r=s.points[s.points.length-1]).x,y:r.y})}else this.startPoint={x:this.startPosition.x,y:this.startPosition.y},this.drawingObject=this.commandHandler.drawObject({offsetX:this.currentPosition.x,offsetY:this.currentPosition.y,width:5,height:5,style:{strokeColor:"black",strokeWidth:1},shape:{type:"Basic",shape:"Polygon",points:[{x:this.startPoint.x,y:this.startPoint.y},{x:this.currentPosition.x,y:this.currentPosition.y}]}})},t.prototype.mouseMove=function(e){if(n.prototype.mouseMove.call(this,e),this.inAction){var i=this.drawingObject.shape;if(i.points[i.points.length-1].x=this.currentPosition.x,i.points[i.points.length-1].y=this.currentPosition.y,this.drawingObject.wrapper.children[0].data=gx(this.drawingObject.shape.points),this.inAction&&!1===z.equals(this.currentPosition,this.prevPosition)){var r=Ne.toBounds(this.drawingObject.shape.points);this.commandHandler.updateNodeDimension(this.drawingObject,r)}}return!0},t.prototype.mouseUp=function(e,i){this.checkPropertyValue(),n.prototype.mouseMove.call(this,e),this.inAction&&(this.inAction=!1,this.commandHandler.addObjectToDiagram(this.drawingObject)),this.endAction()},t.prototype.mouseWheel=function(e){n.prototype.mouseWheel.call(this,e),this.mouseMove(e)},t.prototype.endAction=function(){this.inAction=!1,this.drawingObject=null},t}(us),kh=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseMove=function(e){if(n.prototype.mouseMove.call(this,e),this.inAction){var i=this.drawingObject;i.targetPoint=this.currentPosition,this.commandHandler.updateConnectorPoints(i)}return!0},t.prototype.mouseDown=function(e){if(n.prototype.mouseDown.call(this,e),this.inAction=!0,this.drawingObject){var r=this.drawingObject,s=void 0;(s=new kl(r,"segments",{type:"Straight"},!0)).point=this.currentPosition,r.segments[r.segments.length-1]=s}else this.drawingObject=this.commandHandler.drawObject({id:"Connector",type:"Straight",sourcePoint:this.currentPosition,targetPoint:this.currentPosition})},t.prototype.mouseWheel=function(e){n.prototype.mouseWheel.call(this,e),this.mouseMove(e)},t.prototype.mouseUp=function(e){if(this.checkPropertyValue(),n.prototype.mouseMove.call(this,e),this.inAction&&this.drawingObject){var i=this.drawingObject;i.segments[i.segments.length-1].point={x:0,y:0},this.commandHandler.addObjectToDiagram(this.drawingObject)}this.endAction()},t.prototype.endAction=function(){this.drawingObject=null,this.inAction=!1},t}(us),Ane=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseDown=function(e){this.inAction=!0,this.undoElement=$(e.source),this.annotationId=e.sourceWrapper.id,n.prototype.mouseDown.call(this,e)},t.prototype.mouseMove=function(e){n.prototype.mouseMove.call(this,e);var i=this.currentPosition.x-this.prevPosition.x,r=this.currentPosition.y-this.prevPosition.y,s=e.source;if(s instanceof te){var o=Hi();qi(o,-s.rotateAngle,0,0);var a=Je(o,{x:i,y:r});i=a.x,r=a.y}return this.inAction&&(this.commandHandler.labelDrag(e.source,e.sourceWrapper,i,r),this.commandHandler.updateSelector()),this.prevPosition=this.currentPosition,!this.blocked},t.prototype.mouseUp=function(e){this.checkPropertyValue();var i=e.source;this.inAction=!1;var r={type:"AnnotationPropertyChanged",objectId:this.annotationId,undoObject:$(this.undoElement),category:"Internal",redoObject:$(i)};this.commandHandler.addHistoryEntry(r),n.prototype.mouseUp.call(this,e)},t.prototype.mouseLeave=function(e){this.mouseUp(e)},t}(us),Lne=function(n){function t(e,i){var r=n.call(this,e,!0)||this;return r.corner=i,r}return ds(t,n),t.prototype.mouseDown=function(e){this.inAction=!0;var i=e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0];this.annotationId=e.source.wrapper.children[0].id,this.undoElement=$(i);var r=e.source.wrapper.children[0];this.initialBounds={x:r.offsetX,y:r.offsetY,width:r.actualSize.width,height:r.actualSize.height},n.prototype.mouseDown.call(this,e)},t.prototype.mouseMove=function(e){return n.prototype.mouseMove.call(this,e),this.inAction&&this.resizeObject(e),!this.blocked},t.prototype.mouseUp=function(e){this.checkPropertyValue();var i=e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0];this.inAction=!1;var r={type:"AnnotationPropertyChanged",objectId:this.annotationId,redoObject:$(i),undoObject:$(this.undoElement),category:"Internal"};this.commandHandler.addHistoryEntry(r),n.prototype.mouseUp.call(this,e)},t.prototype.mouseLeave=function(e){this.mouseUp(e)},t.prototype.resizeObject=function(e){var i,s,o,r=e.source.wrapper.children[0],a={x:r.offsetX,y:r.offsetY},l=r.rotateAngle;l=((l+=(i=e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0])instanceof te?i.rotateAngle:0)+360)%360;var h=Hi();qi(h,l,a.x,a.y);var c=this.corner.slice(5),d=this.updateSize(r,this.startPosition,this.currentPosition,c,this.initialBounds,l),u=r.offsetX-r.actualSize.width*r.pivot.x,p=r.offsetY-r.actualSize.height*r.pivot.y,f=this.getPivot(c),g=Je(h,f={x:u+r.actualSize.width*f.x,y:p+r.actualSize.height*f.y});d.x=g.x,d.y=g.y,this.commandHandler.labelResize(i,e.source.annotation,s=(s=d.width)<0?1:s,o=(o=d.height)<0?1:o,d,e.source),this.commandHandler.updateSelector()},t}(us),Nne=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseDown=function(e){this.inAction=!0,this.annotationId=e.source.wrapper.children[0].id,this.undoElement=$(e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0]),n.prototype.mouseDown.call(this,e)},t.prototype.mouseMove=function(e){return n.prototype.mouseMove.call(this,e),e.source&&this.inAction&&(this.commandHandler.labelRotate(e.source.nodes[0]?e.source.nodes[0]:e.source.connectors[0],e.source.annotation,this.currentPosition,e.source),this.commandHandler.updateSelector()),this.prevPosition=this.currentPosition,!this.blocked},t.prototype.mouseUp=function(e){this.checkPropertyValue(),this.inAction=!1;var r={type:"AnnotationPropertyChanged",objectId:this.annotationId,redoObject:$(e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0]),undoObject:$(this.undoElement),category:"Internal"};this.commandHandler.addHistoryEntry(r),n.prototype.mouseUp.call(this,e)},t.prototype.mouseLeave=function(e){this.mouseUp(e)},t}(us),One=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseMove=function(e){if(n.prototype.mouseMove.call(this,e),this.inAction){var i=this.drawingObject.shape;if(i.points.push(this.currentPosition),this.drawingObject.wrapper.children[0].data=vx(this.drawingObject.shape.points),i.data=vx(i.points),this.inAction&&!1===z.equals(this.currentPosition,this.prevPosition)){var s=Ne.toBounds(this.drawingObject.shape.points);this.commandHandler.updateNodeDimension(this.drawingObject,s)}}return!0},t.prototype.mouseDown=function(e){n.prototype.mouseDown.call(this,e),this.inAction=!0,this.startPoint={x:this.startPosition.x,y:this.startPosition.y},this.drawingObject=this.commandHandler.drawObject({offsetX:this.currentPosition.x,offsetY:this.currentPosition.y,width:5,height:5,style:{strokeColor:"black",strokeWidth:1,fill:"transparent"},shape:{type:"Path",points:[{x:this.startPoint.x,y:this.startPoint.y},{x:this.currentPosition.x,y:this.currentPosition.y}]}})},t.prototype.mouseUp=function(e){if(this.checkPropertyValue(),this.inAction){this.inAction=!1;var s=this.drawingObject.shape,o=s.points;this.commandHandler.addObjectToDiagram(this.drawingObject),this.commandHandler.diagram.remove(this.commandHandler.diagram.nameTable[""+this.drawingObject.id]),o=this.pointReduction(o,10);var h={id:"newConnector"+Qe(),type:"Bezier",sourcePoint:{x:o[0].x,y:o[0].y},targetPoint:{x:o[o.length-1].x,y:o[o.length-1].y},segments:[],bezierSettings:{allowSegmentsReset:!1}};this.drawingObject=this.commandHandler.drawObject(h),this.drawingObject=this.bezierCurveSmoothness(o,.5,this.drawingObject,s),this.commandHandler.updateConnectorPoints(this.drawingObject),this.commandHandler.addObjectToDiagram(this.drawingObject),n.prototype.mouseUp.call(this,e)}},t.prototype.pointReduction=function(e,i){if(null===e||e.length<3)return e;var s=e.length-1,o=[];for(o.push(0),o.push(s);e[parseInt((0).toString(),10)]===e[parseInt(s.toString(),10)];)s--;this.reduction(e,0,s,i,o);var a=[];return o.sort(function(l,h){return l-h}),o.forEach(function(l){a.push(e[parseInt(l.toString(),10)])}),a},t.prototype.reduction=function(e,i,r,s,o){for(var a=0,l=0,h=i;ha&&(a=c,l=h)}a>s&&0!==l&&(o.push(l),this.reduction(e,i,l,s,o),this.reduction(e,l,r,s,o))},t.prototype.perpendicularDistance=function(e,i,r){return Math.abs(.5*(e.x*i.y-i.x*e.y+(i.x*r.y-r.x*i.y)+(r.x*e.y-e.x*r.y)))/Math.sqrt(Math.pow(e.x-i.x,2)+Math.pow(e.y-i.y,2))*2},t.prototype.bezierCurveSmoothness=function(e,i,r,s){if(e.length<3)return r;for(var o=0;o=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},kne=function(n){if(n)switch(n.type){case"Bpmn":return Hne;case"UmlActivity":return Rne;case"UmlClassifier":return _ne;default:return Zv}return Zv},Pne=function(n){if(n)switch(n.type){case"Straight":default:return kl;case"Bezier":return ps;case"Orthogonal":return bi}},G3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I(10)],t.prototype,"width",void 0),Pe([I(10)],t.prototype,"height",void 0),Pe([I("Arrow")],t.prototype,"shape",void 0),Pe([re({fill:"black",strokeColor:"black",strokeWidth:1},Al)],t.prototype,"style",void 0),Pe([re({x:0,y:.5},z)],t.prototype,"pivot",void 0),Pe([I("")],t.prototype,"pathData",void 0),t}(Ee),VI=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I(0)],t.prototype,"angle",void 0),Pe([I(0)],t.prototype,"distance",void 0),t}(Ee),zne=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I(Ix.All)],t.prototype,"controlPointsVisibility",void 0),Pe([I("FreeForm")],t.prototype,"segmentEditOrientation",void 0),Pe([I(gI.Default)],t.prototype,"smoothness",void 0),Pe([I(!0)],t.prototype,"allowSegmentsReset",void 0),t}(Ee),Zv=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I("None")],t.prototype,"type",void 0),t}(Ee),Rne=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I("Object")],t.prototype,"flow",void 0),Pe([I(30)],t.prototype,"exceptionFlowHeight",void 0),t}(Zv),Hne=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I("Sequence")],t.prototype,"flow",void 0),Pe([I("Normal")],t.prototype,"sequence",void 0),Pe([I("Default")],t.prototype,"message",void 0),Pe([I("Default")],t.prototype,"association",void 0),t}(Zv),X3=function(n){function t(e,i,r,s){var o=n.call(this,e,i,r,s)||this;return o.points=[],o}return Qs(t,n),Pe([I("Straight")],t.prototype,"type",void 0),Pe([I(!0)],t.prototype,"allowDrag",void 0),t}(Ee),kl=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),t.prototype.getClassName=function(){return"StraightSegment"},Pe([re({x:0,y:0},z)],t.prototype,"point",void 0),t}(X3),ps=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),t.prototype.getClassName=function(){return"BezierSegment"},t.prototype.getPoints=function(e,i){var r=[];if(r.length>0||null!=i){var o=this.bezireToPoly(r.length>0?r[r.length-1]:i,e);r.push.apply(r,o)}return r},t.prototype.bezireToPoly=function(e,i){var r=[];return i&&this.flattenCubicBezier(r,e,i.bezierPoint1,i.bezierPoint2,{x:i.points[1].x,y:i.points[1].y},10),r},t.prototype.flattenCubicBezier=function(e,i,r,s,o,a){var h,l=(z.findLength(i,r)+z.findLength(r,s)+z.findLength(s,o))/a;for(h=0;h<=l;h++){var c=h/l;e.push({x:(1-c)*(1-c)*(1-c)*i.x+3*c*(1-c)*(1-c)*r.x+3*c*c*(1-c)*s.x+c*c*c*o.x,y:(1-c)*(1-c)*(1-c)*i.y+3*c*(1-c)*(1-c)*r.y+3*c*c*(1-c)*s.y+c*c*c*o.y})}},Pe([I("Horizontal")],t.prototype,"orientation",void 0),Pe([re({x:0,y:0},z)],t.prototype,"point1",void 0),Pe([re({x:0,y:0},z)],t.prototype,"point2",void 0),Pe([re({angle:0,distance:0},VI)],t.prototype,"vector1",void 0),Pe([re({angle:0,distance:0},VI)],t.prototype,"vector2",void 0),t}(kl),bi=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),t.prototype.getClassName=function(){return"OrthogonalSegment"},Pe([I(null)],t.prototype,"length",void 0),Pe([I(null)],t.prototype,"direction",void 0),t}(X3);function q3(n,t,e){var s=e?45:180/(2+2/(n.height/n.width)),o=s,a=180-s,l=a+2*s,h=360-s,c=Gt(t,n.center);return c>o&&ca&&cl&&cMath.abs(t.y-n.y)?n.x=c)return s=z.findAngle(n[parseInt(d.toString(),10)],n[d+1]),{point:r=z.transform(n[parseInt(d.toString(),10)],s,c-(a||0)),index:l=d};a=o[parseInt(d.toString(),10)]}return{point:r,index:l}}(n,t),r=z.findAngle(n[i.index],n[i.index+1]),s=function fse(n){var e=0;switch(n.alignment){case"Center":case"After":e=0;break;case"Before":e=-0}return e}(t),o=z.transform(i.point,r+45,s);return i.point=o,i.angle=r,i}(i,e),h=l.point;s.id=this.id+"_"+e.id;var c=e.style;s.style={fill:c.fill,strokeColor:c.strokeColor,gradient:null,opacity:c.opacity,strokeDashArray:c.strokeDashArray,strokeWidth:c.strokeWidth},0===r.width&&(r.width=this.style.strokeWidth),0===r.height&&(r.height=this.style.strokeWidth);var d_y=(h.y-r.y)/r.height;a.x=r.width*((h.x-r.x)/r.width),a.y=r.height*d_y;var g,v,u=dF(e,l.angle,i),p=u.hAlign,f=u.vAlign;return"left"===p?(g="Left",a.x+=e.displacement.x):"right"===p?(g="Right",a.x-=e.displacement.x):"center"===p&&(g="Center"),"top"===f?(v="Top",a.y+=e.displacement.y):"bottom"===f?(v="Bottom",a.y-=e.displacement.y):"center"===f&&(v="Center"),s.horizontalAlignment=g,s.verticalAlignment=v,(s=em(s,o&&"Label"!==o.flipMode&&"None"!==o.flipMode?this.flip:"None",e)).float=!0,s.connectionDirection=e.connectionDirection,s.setOffsetWithRespectToBounds(a.x,a.y,"Absolute"),s.relativeMode="Point",s.visible=!(!ga(e,hi.Visible)||ga(e,hi.Hover)||ga(e,hi.Connect)),s.elementActions=s.elementActions|Xr.ElementIsPort,s},t.prototype.getConnectorRelation=function(){var e=this.shape;"Association"===e.relationship?(this.segments[0].type="Straight",this.sourceDecorator.shape="None",this.targetDecorator.shape="Arrow"):"Inheritance"===e.relationship?(this.segments[0].type="Orthogonal",this.sourceDecorator.shape="None",this.targetDecorator.shape="Arrow"):"Composition"===e.relationship||"Aggregation"===e.relationship?(this.segments[0].type="Orthogonal",this.sourceDecorator.shape="Diamond",this.targetDecorator.shape="None"):"Dependency"===e.relationship?(this.segments[0].type="Orthogonal",this.sourceDecorator.shape="None",this.targetDecorator.shape="OpenArrow"):"Realization"===e.relationship&&(this.segments[0].type="Orthogonal",this.sourceDecorator.shape="None",this.targetDecorator.shape="Arrow"),"BiDirectional"===e.associationType&&(this.sourceDecorator.shape="None",this.targetDecorator.shape="None");var i,o,r="",s="";e.multiplicity.source&&(e.multiplicity.source.lowerBounds=e.multiplicity.source.lowerBounds,e.multiplicity.source.upperBounds=e.multiplicity.source.upperBounds),e.multiplicity.target&&(e.multiplicity.target.lowerBounds=e.multiplicity.target.lowerBounds,e.multiplicity.target.upperBounds=e.multiplicity.target.upperBounds);var a=e.multiplicity.source,l=e.multiplicity.target;o=a.upperBounds?a.lowerBounds+"..."+a.upperBounds:a.lowerBounds,i=l.upperBounds?l.lowerBounds+"..."+l.upperBounds:l.lowerBounds,"ManyToOne"===e.multiplicity.type&&(e.multiplicity.target.optional=!1,r=o||"*",s="1"),"OneToMany"===e.multiplicity.type&&(e.multiplicity.source.optional=!1,s=i||"*",r="1"),"ManyToMany"===e.multiplicity.type&&(r=o||"*",s=i||"*"),"OneToOne"===e.multiplicity.type&&(e.multiplicity.target.optional=!1,e.multiplicity.source.optional=!1,r="1",s="1"),this.annotations=[{id:this.id+"sourcelabel",content:r,offset:0,alignment:"Before",margin:{right:5,bottom:5}},{id:this.id+"targetlabel",content:s,offset:1,alignment:"Before",margin:{right:5,bottom:5}}]},t.prototype.getBpmnSequenceFlow=function(){var e=new Ke,i=new Ke;return"Normal"===this.shape.sequence&&"Bezier"!==this.type&&(this.targetDecorator.shape="Arrow"),"Default"===this.shape.sequence&&(e=this.getSegmentElement(this,e),i=yF(this.intermediatePoints,this),this.targetDecorator.shape="Arrow"),"Conditional"===this.shape.sequence&&(this.targetDecorator.shape="Arrow",this.sourceDecorator.shape="Diamond",i.id=this.id+this.shape.type),i},t.prototype.getUMLObjectFlow=function(){if(this.annotations)for(var e=0;e0&&(this.sourcePoint=o[0],this.targetPoint=o[o.length-1]),o},t.prototype.clipDecorator=function(e,i,r,s){var a,l,o={x:0,y:0},h=i.length,c=z.distancePoints(a=r?i[0]:i[h-1],l=r?i[1]:i[h-2]);c=0===c?1:c;var d=1,u=r?e.sourceWrapper:e.targetWrapper;u&&(d=u.style.strokeWidth,s&&s&ee.DecoratorPropertyChange&&(d=1));var p=d-1;return o.x=Math.round(a.x+p*(l.x-a.x)/c),o.y=Math.round(a.y+p*(l.y-a.y)/c),(r&&"None"!==e.sourceDecorator.shape||!r&&"None"!==e.targetDecorator.shape)&&(o=z.adjustPoint(o,l,!0,s&ee.DecoratorPropertyChange?0:d/2)),o},t.prototype.clipDecorators=function(e,i,r){return"None"!==e.sourceDecorator.shape&&(i[0]=this.clipDecorator(e,i,!0,r)),"None"!==e.targetDecorator.shape&&(i[i.length-1]=this.clipDecorator(e,i,!1,r)),i},t.prototype.updateSegmentElement=function(e,i,r,s){var o=new Ne,a=this.getSegmentPath(e,i,s);if("Bezier"===e.type){if(this.segments.length>0)for(var l=0;l0)if("Straight"===e.type&&e.segments.length<2)for(var o=0;o1)for(o=0;o0&&"Bezier"!==this.type)for(var p=0;p0&&(a=p0&&(f<2*this.cornerRadius?(l=z.adjustPoint(h[parseInt(p.toString(),10)],h[p+1],!0,f/2),p0&&(s=this.bridgePath(e,s,p),"Orthogonal"===e.type&&(s=this.bridgePath(e,s,p+1))),s+=" L"+a.x+" "+a.y))}else if("Bezier"===this.type){var g=void 0,v=void 0;if(this.parentObj.element){var y=this.parentObj.element.ej2_instances[0].eventHandler.action;g=this.parentObj.element.ej2_instances[0].eventHandler.tool instanceof kd,v=y.includes("PortDraw")||y.includes("Drag")}for(var S=void 0,b=this.segments,M=0;M2&&(b[parseInt(M.toString(),10)].bezierPoint1={x:0,y:0},b[parseInt(M.toString(),10)].bezierPoint2={x:0,y:0}),!z.isEmptyPoint(b[parseInt(M.toString(),10)].point1)||b[parseInt(M.toString(),10)].vector1.angle||b[parseInt(M.toString(),10)].vector1.distance?b[parseInt(M.toString(),10)].vector1.angle||b[parseInt(M.toString(),10)].vector1.distance?b[parseInt(M.toString(),10)].bezierPoint1=z.transform(h[parseInt(M.toString(),10)],b[parseInt(M.toString(),10)].vector1.angle,b[parseInt(M.toString(),10)].vector1.distance):b[parseInt(M.toString(),10)].bezierPoint1={x:b[parseInt(M.toString(),10)].point1.x||b[parseInt(M.toString(),10)].bezierPoint1.x,y:b[parseInt(M.toString(),10)].point1.y||b[parseInt(M.toString(),10)].bezierPoint1.y}:((e.sourceID||this.sourcePortID)&&this.sourceWrapper&&!v&&!g&&(S=q3(this.sourceWrapper.bounds,h[parseInt(M.toString(),10)],!0)),b[parseInt(M.toString(),10)].bezierPoint1=YI(h[parseInt(M.toString(),10)],h[M+1],S)),!z.isEmptyPoint(b[parseInt(M.toString(),10)].point2)||b[parseInt(M.toString(),10)].vector2.angle||b[parseInt(M.toString(),10)].vector2.distance?b[parseInt(M.toString(),10)].vector2.angle||b[parseInt(M.toString(),10)].vector2.distance?b[parseInt(M.toString(),10)].bezierPoint2=z.transform(h[M+1],b[parseInt(M.toString(),10)].vector2.angle,b[parseInt(M.toString(),10)].vector2.distance):b[parseInt(M.toString(),10)].bezierPoint2={x:b[parseInt(M.toString(),10)].point2.x||b[parseInt(M.toString(),10)].bezierPoint2.x,y:b[parseInt(M.toString(),10)].point2.y||b[parseInt(M.toString(),10)].bezierPoint2.y}:((e.targetID||this.targetPortID)&&this.targetWrapper&&!v&&!g&&(S=q3(this.targetWrapper.bounds,h[M+1],!0)),b[parseInt(M.toString(),10)].bezierPoint2=YI(h[M+1],h[parseInt(M.toString(),10)],S));h.splice(1,0,{x:b[0].bezierPoint1.x,y:b[0].bezierPoint1.y}),h.splice(h.length-1,0,{x:b[b.length-1].bezierPoint2.x,y:b[b.length-1].bezierPoint2.y}),h=this.clipDecorators(e,h,r);for(var w=0;w0&&(s=this.bridgePath(e,s,D),s+=" L"+o.x+" "+o.y);return s},t.prototype.updateShapeElement=function(e){var i;switch(e.shape.type){case"Bpmn":e.wrapper.children[3]instanceof Ke&&(i=e.wrapper.children[3]),"Message"===e.shape.flow&&this.updateShapePosition(e,i);break;case"UmlActivity":"Exception"===e.shape.flow&&this.getUMLExceptionFlow(e.wrapper.children[0])}},t.prototype.updateShapePosition=function(e,i){var o=SF(this.intermediatePoints,i,.5);i.offsetX=o.x,i.offsetY=o.y},t.prototype.scale=function(e,i,r,s,o){var a=0,l=0;if(this.wrapper&&this.wrapper.outerBounds){var h=function I3(n){var t=n.wrapper.children[0].bounds;return"None"!==n.sourceDecorator.shape&&t.uniteRect(n.wrapper.children[1].bounds),"None"!==n.targetDecorator.shape&&t.uniteRect(n.wrapper.children[2].bounds),t}(this),c=Math.abs((this.wrapper.bounds.width||this.style.strokeWidth||1)-2),d=Math.abs((this.wrapper.bounds.height||this.style.strokeWidth||1)-2);a=h.width-c,l=h.height-d,e=Math.abs((r-Math.max(a,l))/c),i=Math.abs((s-Math.max(a,l))/d),a=l=Math.min(a,l)}e=i=Math.min(e,i);var u=Hi();qi(u,-(o=o||this.wrapper).rotateAngle,o.offsetX,o.offsetY),Wp(u,e,i,o.offsetX,o.offsetY),qi(u,o.rotateAngle,o.offsetX,o.offsetY);var p=function Tie(n,t){for(var e=[],i=0,r=t;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},jne=function(n){function t(e,i){var r=n.call(this,e,i)||this;return r.offset=0,r.scale=1,r}return Une(t,n),t.prototype.preRender=function(){this.unWireEvents(),this.wireEvents()},t.prototype.render=function(){this.updateRulerGeometry(),this.renderComplete()},t.prototype.getModuleName=function(){return"Ruler"},t.prototype.destroy=function(){this.unWireEvents(),this.notify("destroy",{}),n.prototype.destroy.call(this),this.element.classList.remove("e-ruler")},t.prototype.getPersistData=function(){return this.addOnPersist(["loaded"])},t.prototype.onPropertyChanged=function(e,i){for(var r=0,s=Object.keys(e);r100;)r/=10,s/=10;for(;s<25;)r*=10,s*=10;return s>=25&&s%25!=0&&(s=25*Math.round(s/25)),s*e/r},t.prototype.createMarkerLine=function(e,i,r){var s;return i&&((s=e.getElementById(i.id+"_marker"))&&s.parentNode.removeChild(s),s=Bi("line",r)),s},t.prototype.drawRulerMarker=function(e,i,r){var s,o,h,d,u="Horizontal"===this.orientation,p=e.getElementsByTagName("svg");for(h=0;h0)for(var a=i.childNodes.length-1;a>=0;a--)i.childNodes[parseInt(a.toString(),10)].parentNode.removeChild(i.childNodes[parseInt(a.toString(),10)]);i.appendChild(s)}return s},t.prototype.wireEvents=function(){},t.prototype.unWireEvents=function(){},kc([I(5)],t.prototype,"interval",void 0),kc([I(100)],t.prototype,"segmentWidth",void 0),kc([I("Horizontal")],t.prototype,"orientation",void 0),kc([I("RightOrBottom")],t.prototype,"tickAlignment",void 0),kc([I("red")],t.prototype,"markerColor",void 0),kc([I(25)],t.prototype,"thickness",void 0),kc([I(null)],t.prototype,"arrangeTick",void 0),kc([I(400)],t.prototype,"length",void 0),t}(yi);function J3(n,t){var e=document.getElementById(n.element.id+(t?"_hRuler":"_vRuler")),i=qa(n),r=K3(n);e||(e=Tt("div",{id:n.element.id+(t?"_hRuler":"_vRuler"),style:"height:"+(t?i.height:r.height+100)+"px;overflow:hidden;width:"+(t?r.width+100:i.width)+"px;position:absolute;font-size:11px;"+(t?"margin-left:"+i.width+"px;":"margin-top:"+i.height+"px;")})),n.element.insertBefore(e,n.element.firstChild);var l=t?n.rulerSettings.horizontalRuler:n.rulerSettings.verticalRuler,h=new jne(l);h.orientation=t?"Horizontal":"Vertical",h.length=(t?r.width:r.height)+l.segmentWidth,h.appendTo("#"+n.element.id+(t?"_hRuler":"_vRuler")),t?n.hRuler=h:n.vRuler=h;var c=document.getElementById(n.element.id+(t?"_hRuler":"_vRuler"));t?n.hRuler.element=c:n.vRuler.element=c}function QI(n){var t=-n.scroller.horizontalOffset,e=-n.scroller.verticalOffset;n&&n.rulerSettings.showRulers?(n.hRuler.length=0,n.vRuler.length=0,void 0!==t&&n.hRuler.element&&eF(n,n.hRuler,t,!0),void 0!==e&&n.vRuler.element&&eF(n,n.vRuler,e,!1)):Yx(n)}function Yx(n){an(n.element.id+"_hRuler"),an(n.element.id+"_vRuler"),an(n.element.id+"_overlapRuler")}function qa(n){var t=0,e=0;return n.rulerSettings.showRulers&&(t=n.rulerSettings.horizontalRuler.thickness,e=n.rulerSettings.verticalRuler.thickness),new me(e,t)}function K3(n){var t=qa(n),e=n.scroller.viewPortHeight,i=n.scroller.viewPortWidth;return i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},tF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Xne(t,n),t.prototype.getClassName=function(){return"UserHandle"},Fn([I("")],t.prototype,"name",void 0),Fn([I("")],t.prototype,"pathData",void 0),Fn([I("")],t.prototype,"content",void 0),Fn([I("")],t.prototype,"source",void 0),Fn([I("#000000")],t.prototype,"backgroundColor",void 0),Fn([I("Top")],t.prototype,"side",void 0),Fn([I("")],t.prototype,"borderColor",void 0),Fn([I(.5)],t.prototype,"borderWidth",void 0),Fn([I(25)],t.prototype,"size",void 0),Fn([I("white")],t.prototype,"pathColor",void 0),Fn([I(10)],t.prototype,"displacement",void 0),Fn([I(!0)],t.prototype,"visible",void 0),Fn([I(0)],t.prototype,"offset",void 0),Fn([re({},$n)],t.prototype,"margin",void 0),Fn([I("Center")],t.prototype,"horizontalAlignment",void 0),Fn([I("Center")],t.prototype,"verticalAlignment",void 0),Fn([I(!1)],t.prototype,"disableNodes",void 0),Fn([I(!1)],t.prototype,"disableConnectors",void 0),Fn([re({},Ed)],t.prototype,"tooltip",void 0),Fn([I("")],t.prototype,"template",void 0),t}(Ee);function iF(n){return qne[n.toString()]}var qne={Action:"M 90 82.895 C 90 86.819 86.776 90 82.8 90 H 7.2 C 3.224 90 0 86.819 0 82.895 V 7.105 C 0 3.181 3.224 0 7.2 0 h 75.6 C 86.776 0 90 3.181 90 7.105 V 82.895 Z",Decision:"M10,19.707L0.293,10L10,0.293L19.707,10L10,19.707z",MergeNode:"M10,19.707L0.293,10L10,0.293L19.707,10L10,19.707z",InitialNode:"M10,19.5c-5.238,0-9.5-4.262-9.5-9.5S4.762,0.5,10,0.5s9.5,4.262,9.5,9.5S15.238,19.5,10,19.5z",ForkNode:"m0.75,0.75l636.00002,0l0,290l-636.00002,0l0,-290z",JoinNode:"m0.75,0.75l636.00002,0l0,290l-636.00002,0l0,-290z",TimeEvent:"M50.001,0.00286865 L25.001,25.0029 L0.000976562,0.00286865 L50.001,0.00286865 z M0.000976562,50.0029 L25.001,25.0029 L50.001,50.0029 L0.000976562,50.0029 z",AcceptingEvent:"M17.8336 32.164 L29.64 24 L17.32 16 L48.1664 16 L48.5 32 Z",SendSignal:"M48.164 31.8336 L56 23.832 L47.836 16 L16.168 16 L16.1668 31.8336 Z",ReceiveSignal:"M48.1664 31.8336 L39.836 24 L47.836 16 L16.168 16 L16.168 31.836 Z",StructuredNode:"M0,0 L50,0 L50,50 L0,50 z",Note:"M20 12 L4 12 L4 22 L22 22 L22 14 L20 14 L20 12 L22 14 Z"},GI=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),$a=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},$ne=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return GI(t,n),$a([I()],t.prototype,"key",void 0),$a([I()],t.prototype,"keyModifiers",void 0),t}(Ee),rF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return GI(t,n),t.prototype.getClassName=function(){return"Command"},$a([I("")],t.prototype,"name",void 0),$a([I()],t.prototype,"canExecute",void 0),$a([I()],t.prototype,"execute",void 0),$a([re({},$ne)],t.prototype,"gesture",void 0),$a([I("")],t.prototype,"parameter",void 0),t}(Ee),Zne=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return GI(t,n),$a([Bt([],rF)],t.prototype,"commands",void 0),t}(Ee),Jne=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return GI(t,n),$a([I()],t.prototype,"show",void 0),$a([I()],t.prototype,"showCustomMenuOnly",void 0),$a([I()],t.prototype,"items",void 0),t}(Ee),qp=function(){function n(){}return n.prototype.renderShadow=function(t,e,i,r){void 0===i&&(i=null);var l,o=z.transform({x:0,y:0},t.shadow.angle,t.shadow.distance);r&&(l=r.getElementById(e.id+"_shadow")),l||(l=document.createElementNS("http://www.w3.org/2000/svg",i?"path":"rect"),e.appendChild(l));var h={id:e.id+"_shadow",fill:t.shadow.color,stroke:t.shadow.color,opacity:t.shadow.opacity.toString(),transform:"rotate("+t.angle+","+(t.x+t.width*t.pivotX)+","+(t.y+t.height*t.pivotY)+")translate("+(t.x+o.x)+","+(t.y+o.y)+")"};if(r){var c=r.getElementById(e.id);c&&c.insertBefore(l,c.firstChild)}oi(l,h),i?i&&this.renderPath(l,t,i):oi(l,{width:t.width,height:t.height})},n.prototype.parseDashArray=function(t){return[]},n.prototype.drawRectangle=function(t,e,i,r,s,o,a,l,h){var c,d,u,p;e.shadow&&!r&&this.renderShadow(e,t,void 0,o),c=e.id===t.id?e.id+"_container":e.id,o&&(d=o.getElementById(c)),(!d||s)&&(d=document.createElementNS("http://www.w3.org/2000/svg","rect"),t.appendChild(d)),o&&!e.shadow&&(u=o.getElementById(e.id+"_groupElement_shadow"))&&u.parentNode.removeChild(u),p=l?{id:c,x:e.x.toString(),y:e.y.toString(),width:e.width.toString(),height:e.height.toString(),visibility:e.visible?"visible":"hidden",transform:"rotate("+e.angle+","+(e.x+e.width/2)+","+(e.y+e.height/2)+")",rx:e.cornerRadius||0,ry:e.cornerRadius||0,opacity:e.opacity}:{id:c,x:e.x.toString(),y:e.y.toString(),width:e.width.toString(),height:e.height.toString(),visibility:e.visible?"visible":"hidden",transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")",rx:e.cornerRadius||0,ry:e.cornerRadius||0,opacity:e.opacity},a&&(p.role="img",p["aria-label"]=a);var f=e.class||"";h||(f.includes("e-diagram-resize-handle")||f.includes("e-diagram-endpoint-handle")||f.includes("e-diagram-bezier-control-handle"))&&(f+=" e-disabled"),e.class&&(p.class=f),a||(p["pointer-events"]="none"),oi(d,p),this.setSvgStyle(d,e,i)},n.prototype.updateSelectionRegion=function(t,e){var i;i=t.parentNode.getElementById(e.id);var r={id:e.id,x:e.x.toString(),y:e.y.toString(),width:e.width.toString(),height:e.height.toString(),transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")",class:"e-diagram-selected-region"};i||(i=document.createElementNS("http://www.w3.org/2000/svg","rect"),t.appendChild(i)),this.setSvgStyle(i,e),oi(i,r)},n.prototype.createGElement=function(t,e){return Bi(t,e)},n.prototype.drawLine=function(t,e){var i=document.createElementNS("http://www.w3.org/2000/svg","line");this.setSvgStyle(i,e);var r=e.x+e.width*e.pivotX,s=e.y+e.height*e.pivotY,o={id:e.id,x1:e.startPoint.x+e.x,y1:e.startPoint.y+e.y,x2:e.endPoint.x+e.x,y2:e.endPoint.y+e.y,stroke:e.stroke,"stroke-width":e.strokeWidth.toString(),opacity:e.opacity.toString(),transform:"rotate("+e.angle+" "+r+" "+s+")",visibility:e.visible?"visible":"hidden"};e.class&&(o.class=e.class),oi(i,o),t.appendChild(i)},n.prototype.drawCircle=function(t,e,i,r){var s=document.createElementNS("http://www.w3.org/2000/svg","circle");this.setSvgStyle(s,e);var o=e.class||"";i||(o+=" e-disabled");var a={id:e.id,cx:e.centerX,cy:e.centerY,r:e.radius,visibility:e.visible?"visible":"hidden",class:o};r&&(a.role="img",a["aria-label"]=r),s.style.display=e.visible?"block":"none",oi(s,a),t.appendChild(s)},n.prototype.drawPath=function(t,e,i,r,s,o,a){var h,c,l=[];l=QB(l=Cd(e.data)),e.shadow&&this.renderShadow(e,t,l,s),s&&!e.shadow&&(h=s.getElementById(e.id+"_groupElement_shadow"))&&h.parentNode.removeChild(h),s&&(c=s.getElementById(e.id)),(!c||r)&&(c=document.createElementNS("http://www.w3.org/2000/svg","path"),t.appendChild(c)),this.renderPath(c,e,l);var d={};d=a?{id:e.id,transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")translate("+e.x+","+e.y+"),scale("+a+")",visibility:e.visible?"visible":"hidden",opacity:e.opacity}:{id:e.id,transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")translate("+e.x+","+e.y+")",visibility:e.visible?"visible":"hidden",opacity:e.opacity},o&&(d.role="img",d["aria-label"]=o),e.class&&(d.class=e.class),oi(c,d),this.setSvgStyle(c,e,i)},n.prototype.renderPath=function(t,e,i){var r,s,o,a,l,h,c,d,u=i,p="";for(l=0,h=0,d=0,c=u.length;de.width&&"Wrap"!==e.textOverflow&&"NoWrap"===e.textWrapping&&(h[0].text=UF(e.content,e)),v=0;vD&&(u.text=u.text.slice(0,u.text.length-3),u.text=u.text.concat("..."),l.data=u.text),this.alignText(y,p,u,l,f,g,v,e,h),C+=u.dy}}C&&e.isHorizontalLane&&(M=e.parentOffsetX+e.pivotX,w=e.parentOffsetY+e.pivotY,e.y=e.parentOffsetY-C*e.pivotY+.5),e.textDecoration&&"LineThrough"===e.textDecoration&&(e.textDecoration=ab(e.textDecoration));var R={id:e.id+"_text",fill:e.color,visibility:e.visible?"visible":"hidden","text-decoration":e.textDecoration,transform:"rotate("+e.angle+","+M+","+w+")translate("+e.x+","+e.y+")",opacity:e.opacity};r&&(R.role="img",R["aria-label"]=r),oi(y,R)}},n.prototype.alignText=function(t,e,i,r,s,o,a,l,h){"justify"!==l.textAlign?this.setText(t,e,i,r,s,o,l):a!==h.length-1?this.setText(t,e,i,r,s,o,l,l.width,"spacing"):this.setText(t,e,i,r,s,o,l)},n.prototype.setText=function(t,e,i,r,s,o,a,l,h){oi(e,"justify"!==a.textAlign?{x:s.toString(),y:o.toString()}:{x:s.toString(),y:o.toString(),textLength:l||0,lengthAdjust:h||"spacing"}),t.setAttribute("fill",i.text),e.appendChild(r),t.appendChild(e)},n.prototype.drawImage=function(t,e,i,r){var s;i&&(s=i.getElementById(e.id+"image")),s||(s=document.createElementNS("http://www.w3.org/2000/svg","image"),t.appendChild(s));var o=new Image;o.src=e.source;var a="None"!==e.scale?e.scale:"",l=e.alignment,h=l.charAt(0).toLowerCase()+l.slice(1);"Stretch"!==a&&(h+=" "+a.charAt(0).toLowerCase()+a.slice(1)),oi(s,{id:e.id+"image",x:e.x.toString(),y:e.y.toString(),transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")",width:e.width.toString(),visibility:e.visible?"visible":"hidden",height:e.height.toString(),preserveAspectRatio:h,opacity:e.opacity.toString()}),s.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",o.src.toString())},n.prototype.drawHTMLContent=function(t,e,i,r,s){var o,a;if(e&&(o=e.querySelector("#"+t.id+"_html_element")),!o){(a=e.querySelector("#"+t.id+"_html_element")||e.querySelector("#"+t.nodeId+"_html_element"))||(a=Tt("div",{id:t.nodeId+"_html_element",class:"foreign-object"})),o=Tt("div",{id:t.id+"_html_element",class:"foreign-object"});var c=document.getElementById(t.diagramId).ej2_instances[0],d=!1;if(e.parentNode&&e.parentNode.parentNode&&e.parentNode.parentNode.parentNode&&e.parentNode.parentNode.parentNode.classList.contains("e-overview")&&(d=!0),d)c.isReact?c.renderReactTemplates(function(){o.appendChild(t.template.cloneNode(!0))}):o.appendChild(t.template.cloneNode(!0));else{if("string"==typeof t.template){var u=document.createElement("div");u.innerHTML=t.template,t.template=u,c.selectedItems.userHandles.filter(function(g){return g.name===t.id.split("_shape")[0]&&""!==g.template})[0].template=t.template}t.isTemplate&&t.template?o.appendChild(t.template):t.template&&o.appendChild(t.template.cloneNode(!0))}void 0!==s&&e.childNodes.length>s&&e.insertBefore(o,e.childNodes[parseInt(s.toString(),10)]),a.appendChild(o),e.appendChild(a)}var f=En(t).topLeft;o.setAttribute("style","height:"+t.actualSize.height+"px; width:"+t.actualSize.width+"px;left:"+f.x+"px; top:"+f.y+"px;position:absolute;transform:rotate("+(t.rotateAngle+t.parentTransform)+"deg);pointer-events:"+(r?"all":"none")+";visibility:"+(t.visible?"visible":"hidden")+";opacity:"+t.style.opacity+";")},n.prototype.drawNativeContent=function(t,e,i,r,s){var o,a;if(s&&(o=s.getElementById(t.id+"_native_element"),a=s.getElementById(t.id+"_clip")),!o){(o=document.createElementNS("http://www.w3.org/2000/svg","g")).setAttribute("id",t.id+"_native_element"),o.appendChild(t.template.cloneNode(!0));var l=this.createGElement("g",{id:t.id+"_inner_native_element"});l.appendChild(o),e.appendChild(l)}a&&o.removeChild(a),o.setAttribute("style","visibility:"+(t.visible?"visible":"hidden")+";opacity:"+t.style.opacity+";"),this.setNativTransform(t,o,i,r),"Slice"===t.scale&&this.drawClipPath(t,o,i,r,s),oi(o,t.description?{role:"img","aria-label":t.description}:{})},n.prototype.setNativTransform=function(t,e,i,r){var s=0!==t.contentSize.width?t.contentSize.width:1,o=0!==t.contentSize.height?t.contentSize.height:1;e.setAttribute("transform","rotate("+t.parentTransform+","+t.offsetX+","+t.offsetY+") translate("+(t.offsetX-t.templatePosition.x*r/s-r*t.pivot.x)+","+(t.offsetY-t.templatePosition.y*i/o-i*t.pivot.y)+") scale("+r/s+","+i/o+")")},n.prototype.drawClipPath=function(t,e,i,r,s){var o=t.contentSize.width,a=t.contentSize.height,l=t.width/(r/o),h=t.height/(i/a),c=t.templatePosition.x+(t.width>=t.height?0:(o-l)/2),d=t.templatePosition.y+(t.height>=t.width?0:(a-h)/2),u=s.getElementById(t.id+"_clip");(u=document.createElementNS("http://www.w3.org/2000/svg","clipPath")).setAttribute("id",t.id+"_clip"),e.appendChild(u);var p=s.getElementById(t.id+"_clip_rect");return p=document.createElementNS("http://www.w3.org/2000/svg","rect"),u.appendChild(p),oi(p,{id:t.id+"_clip_rect",width:l.toString(),height:h.toString(),x:c.toString(),y:d.toString()}),im()?e.setAttribute("clip-path","url("+location.protocol+"//"+location.host+location.pathname+"#"+t.id+"_clip)"):e.setAttribute("clip-path","url(#"+t.id+"_clip)"),e},n.prototype.renderGradient=function(t,e,i){var r,s,o,h,c,a=vT(i),l=a.getElementById(i+"gradient_pattern");if(l||(l=Bi("defs",{id:i+"gradient_pattern"}),a.insertBefore(l,a.firstChild)),pF(e.id),"None"!==t.gradient.type){for(var d=0;dt.width&&("Ellipsis"===t.textOverflow||"Clip"===t.textOverflow)&&"NoWrap"===t.textWrapping?0:.5*t.width:"right"===t.textAlign&&(c=1*t.width),s.x=0+c+(e?e.x:0),s.y=1.2+d-r.height/2,s},n}(),Pc=function(){function n(t,e,i){this.renderer=null,this.isSvgMode=!0,this.transform={x:0,y:0},this.diagramId=t,this.element=xt(this.diagramId),this.svgRenderer=e,this.isSvgMode=i,this.renderer=i?new qp:new bo}return n.prototype.setCursor=function(t,e){t.style.cursor=e},n.prototype.setLayers=function(){this.iconSvgLayer=this.element.getElementsByClassName("e-ports-expand-layer")[0],this.adornerSvgLayer=this.element.getElementsByClassName("e-adorner-layer")[0],this.nativeSvgLayer=this.element.getElementsByClassName("e-native-layer")[0],this.diagramSvgLayer=this.element.getElementsByClassName("e-diagram-layer")[0]},n.prototype.getAdornerLayer=function(){return fT(this.diagramId)},n.prototype.getParentSvg=function(t,e,i){return this.diagramId&&t&&t.id?t.id.split("_icon_content").length>1||t.id.split("_nodeport").length>1||t.elementActions&Xr.ElementIsPort?this.iconSvgLayer:e&&"selector"===e?this.adornerSvgLayer:t instanceof Cn?this.nativeSvgLayer:this.diagramSvgLayer:i},n.prototype.getParentElement=function(t,e,i,r){var s=e;if(i&&this.diagramId&&t&&t.id){t.id.split("_icon_content").length>1?(s=i.getElementById(this.diagramId+"_diagramExpander"),e=null):t.id.split("_nodeport").length>1?s=i.getElementById(this.diagramId+"_diagramPorts"):t instanceof Cn?(s=i.getElementById(this.diagramId+"_nativeLayer"),e=null):t.elementActions&Xr.ElementIsPort?(s=i.getElementById(this.diagramId+"_diagramPorts"),e=null):s=i.getElementById(this.diagramId+"_diagramLayer");var o=this.getGroupElement(t,e||s,r);s=o.g,o.svg&&(i=o.svg)}return{g:s,svg:i}},n.prototype.getGroupElement=function(t,e,i){var r,o,s=this.getParentSvg(t);if(e&&s){if(s&&!(r=s.getElementById(t.id+"_groupElement"))&&s!==this.nativeSvgLayer){var a=this.nativeSvgLayer;r=a.getElementById(t.id+"_groupElement"),o=a}r||(r=this.svgRenderer.createGElement("g",{id:t.id+"_groupElement"}),void 0!==i&&e.childNodes.length>i?e.insertBefore(r,e.childNodes[parseInt(i.toString(),10)]):e.appendChild(r))}return{g:r,svg:o}},n.prototype.renderElement=function(t,e,i,r,s,o,a,l,h,c,d){t instanceof Cs?(t.id=t.id?t.id:Qe(),this.renderContainer(t,e,i,r,s,o,a,l,h,c,d)):t instanceof mI?this.renderImageElement(t,e,r,s,a):t instanceof Ke?this.renderPathElement(t,e,r,s,a,h,d):t instanceof ni?this.renderTextElement(t,e,r,s,a,c):t instanceof Cn?this.renderNativeElement(t,e,r,s,a):t instanceof Jn?this.renderHTMLElement(t,e,i,r,s,a,l):this.renderRect(t,e,r,s,h)},n.prototype.drawSelectionRectangle=function(t,e,i,r,s,o){var a={width:i*o.scale,height:r*o.scale,x:.5+(t=(t+o.tx)*o.scale),y:.5+(e=(e+o.ty)*o.scale),fill:"transparent",stroke:"gray",angle:0,pivotX:.5,pivotY:.5,strokeWidth:1,dashArray:"6 3",opacity:1,visible:!0,id:s.id+"_selected_region"},l=this.getAdornerLayer();this.svgRenderer.updateSelectionRegion(l,a)},n.prototype.renderHighlighter=function(t,e,i){var r=t.actualSize.width||2,s=t.actualSize.height||2,o=t.offsetX-r*t.pivot.x,a=t.offsetY-s*t.pivot.y;this.svgRenderer.drawRectangle(e,{width:r*i.scale,height:s*i.scale,x:o=(o+i.tx)*i.scale,y:a=(a+i.ty)*i.scale,fill:"transparent",stroke:"#8CC63F",angle:t.rotateAngle,pivotX:t.pivot.x,pivotY:t.pivot.y,strokeWidth:4,dashArray:"",opacity:1,cornerRadius:0,visible:!0,id:e.id+"_highlighter",class:"e-diagram-highlighter"},this.diagramId,void 0,void 0,e)},n.prototype.renderSelectionRectangle=function(t,e,i,r){var s=t.actualSize.width||2,o=t.actualSize.height||2,a=t.offsetX-s*t.pivot.x,l=t.offsetY-o*t.pivot.y,h={width:s*i.scale,height:o*i.scale,x:a=(a+i.tx)*i.scale,y:l=(l+i.ty)*i.scale,fill:"transparent",stroke:"#00cc00",angle:t.rotateAngle,pivotX:t.pivot.x,pivotY:t.pivot.y,strokeWidth:r?2:1,dashArray:"",opacity:1,cornerRadius:0,visible:!0,id:t.id+"_highlighter",class:r?"e-diagram-first-selection-indicator e-diagram-selection-indicator":"e-diagram-selection-indicator"},c=this.getParentSvg(t,"selector");this.svgRenderer.drawRectangle(e,h,this.diagramId,void 0,void 0,c)},n.prototype.renderSelectionLine=function(t,e,i,r){var s=this.getBaseAttributes(t,i);s.data=t.absolutePath,s.id=s.id+"_highlighter";var o=t.description?t.description:t.id;this.isSvgMode||(s.x=t.flipOffset.x?t.flipOffset.x:s.x,s.y=t.flipOffset.y?t.flipOffset.y:s.y),i&&(s.x=s.x*i.scale,s.y=s.y*i.scale),s.stroke="#00cc00",s.strokeWidth=r?2:1,s.class=r?"e-diagram-first-selection-indicator e-diagram-selection-indicator":"e-diagram-selection-indicator";var a=this.getParentSvg(t,"selector");this.svgRenderer.drawPath(e,s,this.diagramId,void 0,a,o,i.scale)},n.prototype.renderStackHighlighter=function(t,e,i,r,s,o,a){var l=t.actualSize.width||2,h=t.offsetX-l*t.pivot.x,c=t.actualSize.height||2,d=t.offsetY-c*t.pivot.y;h=(h+i.tx)*i.scale;var u,p=t.bounds,f="";if(d=(d+i.ty)*i.scale,r)if(o){var v,y;u="M 0 0 L "+(2+(g=l*i.scale))+" 0 Z",v=t.actualSize.width/Number(p.width?p.width:1)*i.scale,y=t.actualSize.height/Number(p.height?p.height:1)*i.scale,f=uI(pI(Cd("M7,4 L8,4 8,7 11,7 11,8 8,8 8,11 7,11 7,8 4,8 4,7 7,7 z M7.5,0.99999994C3.9160004,1 1,3.9160004 0.99999994,7.5 1,11.084 3.9160004,14 7.5,14 11.084,14 14,11.084 14,7.5 14,3.9160004 11.084,1 7.5,0.99999994 z M7.5,0 C11.636002,0 15,3.3639984 15,7.5 15,11.636002 11.636002,15 7.5,15 3.3640003,15 0,11.636002 0,7.5 0,3.3639984 3.3640003,0 7.5,0 z")),v+g+2,y-8,!1,p.x,p.y,0,0),s.y>=t.offsetY&&(d+=c)}else{var g;a&&s.y>=t.offsetY&&(d+=c*i.scale),u="M -10 -10 L 0 0 Z M -10 10 L 0 0 Z M 0 0 L "+(g=l*i.scale)+" 0 Z M "+g+" 0 L "+(g+10)+" 10 Z L "+(g+10)+" -10 Z"}else u="M 10 -10 L 0 0 Z M -10 -10 L 0 0 Z M 0 0 L 0 "+(g=c*i.scale)+" Z M 0 "+g+" L -10 "+(g+10)+" Z L 10 "+(g+10)+" Z",s.x>=t.offsetX&&(h+=l*i.scale);this.svgRenderer.drawPath(e,{data:u+f,width:l*i.scale,height:c*i.scale,x:h,y:d,fill:"transparent",stroke:"#8CC63F",angle:t.rotateAngle,pivotX:t.pivot.x,pivotY:t.pivot.y,strokeWidth:1,dashArray:"",opacity:1,visible:!0,id:e.id+"_stack_highlighter",class:"e-diagram-highlighter"},this.diagramId)},n.prototype.drawLine=function(t,e){this.svgRenderer.drawLine(t,e)},n.prototype.drawPath=function(t,e){this.svgRenderer.drawPath(t,e,this.diagramId)},n.prototype.renderResizeHandle=function(t,e,i,r,s,o,a,l,h,c,d){var u=t.offsetX-t.actualSize.width*t.pivot.x,p=t.offsetY-t.actualSize.height*t.pivot.y,f=t.actualSize.height,g=t.actualSize.width;!c&&i&bt.Rotate&&kI(this.rendererActions)&&!x3(this.rendererActions)&&(this.renderPivotLine(t,e,o,s,a),this.renderRotateThumb(t,e,o,s,a)),this.renderBorder(t,e,o,l,h,c);var v=t.actualSize.width*r,y=t.actualSize.height*r;!h&&kI(this.rendererActions)&&!x3(this.rendererActions)&&(t.isTextAnnotation||(v>=40&&y>=40&&(s&lr.ResizeNorthWest&&this.renderCircularHandle("resizeNorthWest",t,u,p,e,qr(s,"ResizeNorthWest"),i&bt.ResizeNorthWest,o,void 0,a,{"aria-label":"Thumb to resize the selected object on top left side direction"},void 0,"e-diagram-resize-handle e-northwest",d),s&lr.ResizeNorthEast&&this.renderCircularHandle("resizeNorthEast",t,u+g,p,e,qr(s,"ResizeNorthEast"),i&bt.ResizeNorthEast,o,void 0,a,{"aria-label":"Thumb to resize the selected object on top right side direction"},void 0,"e-diagram-resize-handle e-northeast",d),s&lr.ResizeSouthWest&&this.renderCircularHandle("resizeSouthWest",t,u,p+f,e,qr(s,"ResizeSouthWest"),i&bt.ResizeSouthWest,o,void 0,a,{"aria-label":"Thumb to resize the selected object on bottom left side direction"},void 0,"e-diagram-resize-handle e-southwest",d),s&lr.ResizeSouthEast&&this.renderCircularHandle("resizeSouthEast",t,u+g,p+f,e,qr(s,"ResizeSouthEast"),i&bt.ResizeSouthEast,o,void 0,a,{"aria-label":"Thumb to resize the selected object on bottom right side direction"},void 0,"e-diagram-resize-handle e-southeast",d)),s&lr.ResizeNorth&&this.renderCircularHandle("resizeNorth",t,u+g/2,p,e,qr(s,"ResizeNorth"),i&bt.ResizeNorth,o,void 0,a,{"aria-label":"Thumb to resize the selected object on top side direction"},void 0,"e-diagram-resize-handle e-north",d),s&lr.ResizeSouth&&this.renderCircularHandle("resizeSouth",t,u+g/2,p+f,e,qr(s,"ResizeSouth"),i&bt.ResizeSouth,o,void 0,a,{"aria-label":"Thumb to resize the selected object on bottom side direction"},void 0,"e-diagram-resize-handle e-south",d),s&lr.ResizeWest&&this.renderCircularHandle("resizeWest",t,u,p+f/2,e,qr(s,"ResizeWest"),i&bt.ResizeWest,o,void 0,a,{"aria-label":"Thumb to resize the selected object on left side direction"},void 0,"e-diagram-resize-handle e-west",d),s&lr.ResizeEast&&this.renderCircularHandle("resizeEast",t,u+g,p+f/2,e,qr(s,"ResizeEast"),i&bt.ResizeEast,o,void 0,a,{"aria-label":"Thumb to resize the selected object on right side direction"},void 0,"e-diagram-resize-handle e-east",d)))},n.prototype.renderEndPointHandle=function(t,e,i,r,s,o,a,l,h,c){var f,g,d=t.sourcePoint,u=t.targetPoint,p=t.wrapper;if(this.renderCircularHandle("connectorSourceThumb",p,d.x,d.y,e,qr(r,"ConnectorSourceThumb"),i&bt.ConnectorSource,s,o,void 0,{"aria-label":"Thumb to move the source point of the connector"},void 0,"e-diagram-endpoint-handle e-sourceend",c),this.renderCircularHandle("connectorTargetThumb",p,u.x,u.y,e,qr(r,"ConnectorTargetThumb"),i&bt.ConnectorTarget,s,a,void 0,{"aria-label":"Thumb to move the target point of the connector"},void 0,"e-diagram-endpoint-handle e-targetend",c),l)if("Straight"===t.type&&t.segments.length>0)for(f=0;f0)for(f=0;f=3&&3===t.segments.length&&(S=1,b=t.segments.length-1),S=t.segments.length>t.maxSegmentThumb+2?2:S,b=t.segments.length>t.maxSegmentThumb+2?t.segments.length-2:b,1===t.segments.length&&t.segments[0].points.length<=2&&(S=1,b=t.segments.length),f=S;f=50&&i.allowDrag),this.renderOrthogonalThumb(t+"_"+(d+1),e,(i.points[parseInt(d.toString(),10)].x+i.points[d+1].x)/2,(i.points[parseInt(d.toString(),10)].y+i.points[d+1].y)/2,r,h,l,o,a,u)}else for(d=0;d=50&&i.allowDrag),this.renderOrthogonalThumb(t+"_"+(d+1),e,(i.points[parseInt(d.toString(),10)].x+i.points[d+1].x)/2,(i.points[parseInt(d.toString(),10)].y+i.points[d+1].y)/2,r,h,l,o,a,u)},n.prototype.renderOrthogonalThumb=function(t,e,i,r,s,o,a,l,h,c){var d,g,u=0,p=document.getElementById(this.diagramId);p&&(g=p.ej2_instances[0]);var y=h.constraints&qe.InheritSegmentThumbShape?g.segmentThumbShape:h.segmentThumbShape,b=h.constraints&qe.InheritSegmentThumbSize?g.segmentThumbSize:h.segmentThumbSize;if(d="horizontal"===a?function Kie(n){return rre[""+n]}(y):i3(y),"Arrow"===y||"DoubleArrow"===y||"OpenArrow"===y)switch(c){case"Bottom":case"Right":u=180;break;default:u=0}else if("Fletch"===y||"OpenFetch"===y||"IndentedArrow"===y||"OutdentedArrow"===y)switch(c){case"Bottom":u=-90;break;case"Top":u=90;break;case"Right":u=180;break;default:u=0}var M={x:(i+l.tx)*l.scale-b/2,y:(r+l.ty)*l.scale-b/2,angle:u,fill:"#e2e2e2",stroke:"black",strokeWidth:1,dashArray:"",data:d,width:b,height:b,pivotX:.5,pivotY:.5,opacity:1,visible:o,id:t,class:"e-diagram-ortho-segment-handle"},w=nf(M.data),C=new me(M.width,M.height),D=new Ke;M.data=D.updatePath(M.data,w,C),this.svgRenderer.drawPath(s,M,this.diagramId)},n.prototype.renderPivotLine=function(t,e,i,r,s){var o=t,l=!!(r&lr.Rotate);s&&(l=!1);var h=this.getBaseAttributes(o,i);h.fill="None",h.stroke="black",h.strokeWidth=1,h.dashArray="2,3",h.visible=l;var c=i.scale;h.x*=c,h.y*=c,h.width*=c,h.height*=c,h.id="pivotLine",h.class="e-diagram-pivot-line";var u={x:o.actualSize.width*o.pivot.x*c,y:0};h.startPoint={x:o.actualSize.width*o.pivot.x*c,y:-20},h.endPoint=u,this.svgRenderer.drawLine(e,h)},n.prototype.renderBezierLine=function(t,e,i,r,s,o){var l=this.getBaseAttributes(e,o);l.id=t,l.stroke="black",l.strokeWidth=1,l.dashArray="3,3",l.fill="None",l.class="e-diagram-bezier-control-line",l.x=0,l.y=0;var h=o.scale,g={x:(s.x+o.tx)*h,y:(s.y+o.ty)*h};l.startPoint={x:(r.x+o.tx)*h,y:(r.y+o.ty)*h},l.endPoint=g,this.svgRenderer.drawLine(i,l)},n.prototype.renderCircularHandle=function(t,e,i,r,s,o,a,l,h,c,d,u,p,f){var g=e,v={x:i,y:r};if(0!==g.rotateAngle||0!==g.parentTransform){var y=Hi();qi(y,g.rotateAngle+g.parentTransform,g.offsetX,g.offsetY),v=Je(y,v)}var S=this.getBaseAttributes(g);S.stroke="black",S.strokeWidth=1,void 0!==u?(S.id="segmentEnd_"+u,S.fill="#e2e2e2"):S.fill=h?"#8CC63F":"white",S.cornerRadius=f/2,S.angle=e.rotateAngle,S.id=t,S.visible=o,S.class=p,S.width=f,S.height=f,S.x=(v.x+l.tx)*l.scale,S.y=(v.y+l.ty)*l.scale,S.x=S.x-S.width/2,S.y=S.y-S.height/2,h&&(S.class+=" e-connected"),c&&(S.visible=!1);var b=this.getParentSvg(e,"selector");this.svgRenderer.drawRectangle(s,S,this.diagramId,!0,!0,b,d,!0,a)},n.prototype.renderBezierHandle=function(t,e,i,r,s,o,a,l,h,c,d,u,p){var v,f=document.getElementById(this.diagramId);f&&(v=f.ej2_instances[0]);var y=e,S={x:i,y:r};if(0!==y.rotateAngle||0!==y.parentTransform){var b=Hi();qi(b,y.rotateAngle+y.parentTransform,y.offsetX,y.offsetY),S=Je(b,S)}var D=a.constraints&qe.InheritSegmentThumbSize?v.segmentThumbSize:a.segmentThumbSize,A=i3(a.constraints&qe.InheritSegmentThumbShape?v.segmentThumbShape:a.segmentThumbShape),x=this.getBaseAttributes(y);x.stroke="black",x.strokeWidth=1,void 0!==d?(x.id="segmentEnd_"+d,x.fill="#e2e2e2"):x.fill=h?"#8CC63F":"white",x.angle=e.rotateAngle,x.id=t,x.visible=o,x.class=u,x.width=D,x.height=D,x.data=A,x.x=(S.x+l.tx)*l.scale,x.y=(S.y+l.ty)*l.scale,x.x=x.x-x.width/2,x.y=x.y-x.height/2,h&&(x.class+=" e-connected"),c&&(x.visible=!1);var R=nf(x.data),L=new me(x.width,x.height),O=new Ke;x.data=O.updatePath(x.data,R,L);var N=this.getParentSvg(e,"selector");this.svgRenderer.drawPath(s,x,this.diagramId,!0,N)},n.prototype.renderBorder=function(t,e,i,r,s,o){var l=this.getBaseAttributes(t,i);l.x*=i.scale,l.y*=i.scale,l.width*=i.scale,l.height*=i.scale,l.fill="transparent",l.stroke="#097F7F",l.strokeWidth=1.2,l.gradient=null,l.dashArray="6,3",l.class="e-diagram-selector",o&&(l.class+=" e-diagram-lane"),l.id="borderRect",l.id=this.rendererActions&Qa.DrawSelectorBorder?"borderRect_symbol":"borderRect",r||(l.class+=" e-disabled"),s&&(l.class+=" e-thick-border"),l.cornerRadius=0;var h=this.getParentSvg(t,"selector");this.svgRenderer.drawRectangle(e,l,this.diagramId,void 0,!0,h)},n.prototype.renderUserHandler=function(t,e,i,r,s,o){for(var l,a=t.wrapper,h=0,c=t.userHandles;h0||d.disableNodes&&t.nodes.length>0||"Drag"===s&&o)&&(l=!1);var u=document.getElementById(d.name+"_template_hiddenUserHandle");u&&(d.template=u.childNodes[0].cloneNode(!0));var p=Jx(t,d,i);if(p.x=(p.x+i.tx)*i.scale,p.y=(p.y+i.ty)*i.scale,d.visible&&(d.visible=!!(t.constraints&lr.UserHandle)),l)if(d.pathData){var f=d.pathData?d.pathData:d.content,g=this.getBaseAttributes(a);g.id=d.name+"_userhandle",g.fill=d.backgroundColor,g.stroke=d.borderColor,g.strokeWidth=d.borderWidth,g.centerX=p.x,g.centerY=p.y,g.radius=.5*d.size,g.class="e-diagram-userhandle-circle",g.angle=0,g.visible=d.visible,g.opacity=1,this.svgRenderer.drawCircle(e,g,1,{"aria-label":d.name+"user handle"});var y=[];y=pI(y=Cd(f));var S=nf(f),w=uI(y,(d.size-.45*d.size)/S.width,(d.size-.45*d.size)/S.height,!0,S.x,S.y,0,0);S=nf(w),this.svgRenderer.drawPath(e,C={x:p.x-S.width/2,y:p.y-S.height/2,angle:0,id:"",class:"e-diagram-userhandle-path",fill:d.pathColor,stroke:d.backgroundColor,strokeWidth:.5,dashArray:"",data:w,width:d.size-5,height:d.size-5,pivotX:0,pivotY:0,opacity:1,visible:d.visible},this.diagramId,void 0,void 0,{"aria-label":d.name+"user handle"})}else if(d.content){var D=new Cn(d.name,this.diagramId);D.content=d.content,D.offsetX=p.x,D.offsetY=p.y,D.id=d.name+"_shape",D.horizontalAlignment="Center",D.verticalAlignment="Center",D.visible=d.visible,D.setOffsetWithRespectToBounds(p.x,p.y,"Fraction"),D.relativeMode="Object",D.description=d.name||"User handle",D.measure(new me(d.size,d.size)),D.arrange(D.desiredSize),this.svgRenderer.drawNativeContent(D,e,d.size,d.size,this.adornerSvgLayer)}else if(d.source){var C,A=new mI;(C=this.getBaseAttributes(A,i)).width=d.size,C.height=d.size,C.x=p.x-d.size/2,C.y=p.y-d.size/2,C.sourceWidth=d.size,C.sourceHeight=d.size,C.alignment=A.imageAlign,C.source=d.source,C.scale=A.imageScale,C.visible=d.visible,C.description=d.name||"User handle",C.id=d.name+"_",this.renderer.drawImage(e,C,this.adornerSvgLayer,!1)}else{var x=new Jn(d.name,this.diagramId);x.offsetX=p.x,x.offsetY=p.y,x.id=d.name+"_shape",x.visible=d.visible,x.relativeMode="Object",x.template=d.template,x.measure(new me(d.size,d.size)),x.arrange(x.desiredSize),this.svgRenderer.drawHTMLContent(x,r,void 0,!0,void 0)}}},n.prototype.renderRotateThumb=function(t,e,i,r,s){new Ke;var a,l=new me;l.width=18,l.height=16;var d=!!(r&lr.Rotate);s&&(d=!1);var p=t.offsetX-t.actualSize.width*t.pivot.x+t.pivot.x*t.actualSize.width,f=t.offsetY-t.actualSize.height*t.pivot.y;if(a={x:(p=(p+i.tx)*i.scale)-.5*l.width,y:(f=(f+i.ty)*i.scale)-30-.5*l.height},0!==t.rotateAngle||0!==t.parentTransform){var g=Hi();qi(g,t.rotateAngle+t.parentTransform,(i.tx+t.offsetX)*i.scale,(i.ty+t.offsetY)*i.scale),a=Je(g,a)}this.svgRenderer.drawPath(e,{x:a.x,y:a.y,angle:t.rotateAngle+t.parentTransform,fill:"#231f20",stroke:"black",strokeWidth:.5,dashArray:"",data:"M 16.856144362449648 10.238890446662904 L 18.000144362449646 3.437890446662903L 15.811144362449646 4.254890446662903 C 14.837144362449646 2.5608904466629028 13.329144362449647 1.2598904466629026 11.485144362449645 0.5588904466629026 C 9.375144362449646 - 0.24510955333709716 7.071144362449646 - 0.18010955333709716 5.010144362449646 0.7438904466629028 C 2.942144362449646 1.6678904466629028 1.365144362449646 3.341890446662903 0.558144362449646 5.452890446662903 C - 0.244855637550354 7.567890446662903 - 0.17985563755035394 9.866890446662904 0.7431443624496461 11.930890446662904 C 1.6681443624496461 13.994890446662904 3.343144362449646 15.575890446662903 5.457144362449647 16.380890446662903 C 6.426144362449647 16.7518904466629 7.450144362449647 16.9348904466629 8.470144362449647 16.9348904466629 C 9.815144362449647 16.9348904466629 11.155144362449647 16.6178904466629 12.367144362449647 15.986890446662901 L 11.351144362449647 14.024890446662901 C 9.767144362449647 14.8468904466629 7.906144362449647 14.953890446662902 6.237144362449647 14.3178904466629 C 4.677144362449647 13.7218904466629 3.444144362449647 12.5558904466629 2.758144362449647 11.028890446662901 C 2.078144362449646 9.501890446662903 2.031144362449646 7.802890446662903 2.622144362449646 6.243890446662903 C 3.216144362449646 4.6798904466629025 4.387144362449646 3.442890446662903 5.914144362449646 2.760890446662903 C 7.437144362449646 2.078890446662903 9.137144362449646 2.0298904466629026 10.700144362449645 2.6258904466629027 C 11.946144362449646 3.100890446662903 12.971144362449646 3.9538904466629026 13.686144362449646 5.049890446662903 L 11.540144362449645 5.850890446662903 L 16.856144362449648 10.238890446662904 Z",width:20,height:20,pivotX:0,pivotY:0,opacity:1,visible:d,id:"rotateThumb",class:"e-diagram-rotate-handle"},this.diagramId,!0,void 0,{"aria-label":"Thumb to rotate the selected object"})},n.prototype.renderPathElement=function(t,e,i,r,s,o,a){var l=this.getBaseAttributes(t,i,o);if(l.data=t.absolutePath,l.data=t.absolutePath,t.isPathPort&&a){l.x=a[t.id]?a[t.id].cx:l.x,l.y=a[t.id]?a[t.id].cy:l.y,t.bounds.x=l.x,t.bounds.y=l.y;var h=document.getElementById(this.diagramId);h&&"PortDrag"!==h.ej2_instances[0].eventHandler.currentAction&&(t.offsetX=l.x+t.width/2,t.offsetY=l.y+t.height/2)}var u=t.description?t.description:t.id;if(this.isSvgMode||(l.x=t.flipOffset.x?t.flipOffset.x:l.x,l.y=t.flipOffset.y?t.flipOffset.y:l.y),t.isExport){var p=t.absoluteBounds,f=Cd(l.data),g=this.findAndStoreArcValues(f);l.arc=g,l.data=LF(t,p,0,l)}this.renderer.drawPath(e,l,this.diagramId,void 0,r,u)},n.prototype.findAndStoreArcValues=function(t){var e=[];return t.forEach(function(i){"A"===i.command&&e.push({r1:i.r1/2,r2:i.r2/2})}),e},n.prototype.renderSvgGridlines=function(t,e,i,r,s,o){var a=document.createElementNS("http://www.w3.org/2000/svg","pattern"),l=document.createElementNS("http://www.w3.org/2000/svg","defs");l.setAttribute("id",this.diagramId+"_grid_pattern_defn"),(t.constraints&Kt.ShowHorizontalLines||t.constraints&Kt.ShowVerticalLines)&&a.setAttribute("id",this.diagramId+"_pattern");var h=0,c=0,d=0,u=0,p=1,f=!1,g="Lines"===t.gridType,v=g?t.verticalGridlines.lineIntervals:t.verticalGridlines.dotIntervals,y=g?t.horizontalGridlines.lineIntervals:t.horizontalGridlines.dotIntervals;if(r.showRulers&&r.dynamicGrid&&s&&o)d=o.updateSegmentWidth(i.scale),u=s.updateSegmentWidth(i.scale),t.horizontalGridlines.scaledIntervals=[d/s.interval],t.verticalGridlines.scaledIntervals=[u/o.interval],f=!0;else{for(var S=0;S=2)for(;e>=2;)e/=2;else if(e<=.5)for(;e<=.5;)e*=2;var i;if(t.horizontalGridlines.scaledIntervals=t.horizontalGridlines.snapIntervals,t.verticalGridlines.scaledIntervals=t.verticalGridlines.snapIntervals,1!==e){var r=t.horizontalGridlines;for(r.scaledIntervals=[],i=0;ithis.groupElement.actualSize.height&&("Clip"===t.style.textOverflow||"Ellipsis"===t.style.textOverflow)&&(a.y=a.y+(a.height-this.groupElement.actualSize.height)/2),this.renderer.drawRectangle(e,a,this.diagramId,void 0,void 0,r),this.renderer.drawText(e,a,r,l,this.diagramId,t.isExport&&Math.min(t.exportScaleValue.x||t.exportScaleValue.y),this.groupElement),this.isSvgMode&&(t.doWrap=!1)},n.prototype.renderNativeElement=function(t,e,i,r,s){var o,a,l=this.getParentSvg(t,void 0,e)||r,h=this.getParentElement(t,e,l).g||e,c=this.getBaseAttributes(t,i);switch(c.fill="transparent",c.cornerRadius=t.cornerRadius,c.stroke="transparent",this.renderer.drawRectangle(e,c,this.diagramId,void 0,void 0,r),t.scale){case"None":o=t.contentSize.width,a=t.contentSize.height;break;case"Stretch":o=t.actualSize.width,a=t.actualSize.height;break;case"Meet":o=a=t.actualSize.width<=t.actualSize.height?t.actualSize.width:t.actualSize.height;break;case"Slice":o=a=t.actualSize.width>=t.actualSize.height?t.actualSize.width:t.actualSize.height}this.svgRenderer&&this.svgRenderer.drawNativeContent(t,h,a,o,l)},n.prototype.renderHTMLElement=function(t,e,i,r,s,o,a){var l=this.getBaseAttributes(t,r);l.fill="transparent",l.cornerRadius=t.cornerRadius,l.stroke="transparent",this.renderer.drawRectangle(e,l,this.diagramId,void 0,void 0,s),this.svgRenderer&&this.svgRenderer.drawHTMLContent(t,i.children[0],r,function ose(n){var t=n.parentElement;do{if(hm(t,"e-diagram"))return!0;t=t.parentElement}while(t);return!1}(i),a)},n.prototype.renderImageElement=function(t,e,i,r,s){var o=this.getBaseAttributes(t,i);o.cornerRadius=0,this.renderer.drawRectangle(e,o,this.diagramId,void 0,void 0,r);var a,l,h,c,g,d=t.contentSize.width,u=t.contentSize.height,p=o.width/d,f=o.height/u;if("Stretch"===t.stretch)a=d*(g=Math.min(p,f)),l=u*g;else switch(t.stretch){case"Meet":a=d*(g=Math.min(p,f)),l=u*g,o.x+=Math.abs(o.width-a)/2,o.y+=Math.abs(o.height-l)/2;break;case"Slice":g=Math.max(p,f),h=o.width/(a=d*g)*d,c=o.height/(l=u*g)*u;break;case"None":a=d,l=u}o.width=a,o.height=l,o.sourceWidth=h,o.sourceHeight=c,o.source=t.source,o.alignment=t.imageAlign,o.scale=t.imageScale,o.description=t.description?t.description:t.id,this.renderer.drawImage(e,o,r,s)},n.prototype.renderContainer=function(t,e,i,r,s,o,a,l,h,c,d){var g,u={svg:s,g:e},p=document.getElementById(this.diagramId);if(p&&(g=p.ej2_instances[0]),this.diagramId&&(s=this.getParentSvg(t)||s,this.isSvgMode)){var v=this.getParentElement(t,e,s,l).g||e;s=this.getParentSvg(this.hasNativeParent(t.children))||s;var y=this.getParentElement(this.hasNativeParent(t.children),v,s,l);u.svg=y.svg||s,u.g=y.g||v,o&&s&&(s.getElementById(u.g.id)||e.appendChild(u.g)),e=u.g}if(this.renderRect(t,e,r,s),this.groupElement=t,t.hasChildren()){for(var b,S=void 0,M=0,w=t.children;M0&&(D=g.selectedItems.nodes[0]);var L,A=void 0,x=void 0,R=!1;if(g&&g.selectedItems&&(L=g.getObject(t.id)),"None"!==t.flip&&(D=L),"None"===t.flip&&(D=L),D&&D.flipMode&&(R=!0),!(t.elementActions&Xr.ElementIsGroup)&&g instanceof zl&&g.nameTable[t.id]&&"connectors"!==g.nameTable[t.id].propName&&R&&D){if(A=t.children&&t.children[0]instanceof Cn?document.getElementById(D.id+"_content_inner_native_element"):document.getElementById(D.id+"_content_groupElement"),!(t.children[0]instanceof Cn)&&"Text"!==D.shape.type&&"None"!==D.flipMode&&"Label"!==D.flipMode&&"All"!==D.flipMode&&"PortAndLabel"!==D.flipMode&&"LabelText"!==D.flipMode&&"PortAndLabelText"!==D.flipMode&&"LabelAndLabelText"!==D.flipMode||t.children[0]instanceof Cn&&"Port"===D.flipMode)return void this.renderFlipElement(t,A,D.flip);if((t.children[0]instanceof Cn&&("All"===D.flipMode||"Label"===D.flipMode)||"Label"===D.flipMode||"PortAndLabel"===D.flipMode||"LabelText"===D.flipMode||"PortAndLabelText"===D.flipMode||"LabelAndLabelText"===D.flipMode||"Image"===D.shape.type&&"Label"===D.flipMode)&&this.renderFlipElement(t,A,t.flip),"None"!==t.flip&&"None"===D.flipMode)this.renderFlipElement(t,A,t.flip);else if("None"!==t.flip&&("Label"===D.flipMode||"PortAndLabel"===D.flipMode||"LabelText"===D.flipMode||"PortAndLabelText"===D.flipMode||"LabelAndLabelText"===D.flipMode)||t.children[0]instanceof Cn&&"None"!==t.flip&&D&&("None"===D.flipMode||"All"===D.flipMode)){for(var O=0;O0){var i=t[0];if(i instanceof Cn)return i;i.children&&i.children.length&&this.hasNativeParent(i.children,e++||0)}},n.prototype.renderRect=function(t,e,i,r,s){var o=this.getBaseAttributes(t,i,s);o.cornerRadius=t.cornerRadius||0,t.isExport&&(o.cornerRadius*=t.exportScaleValue.x),this.renderer.drawRectangle(e,o,this.diagramId,t.isExport,void 0,r,t.description?t.description:t.id)},n.prototype.drawRect=function(t,e){e.cornerRadius=0,this.svgRenderer.drawRectangle(t,e,this.diagramId)},n.prototype.getBaseAttributes=function(t,e,i){var r={width:t.actualSize.width,height:t.actualSize.height,x:t.offsetX-t.actualSize.width*t.pivot.x,y:t.offsetY-t.actualSize.height*t.pivot.y,fill:t.style.fill,stroke:t.style.strokeColor,angle:t.rotateAngle+t.parentTransform,pivotX:t.pivot.x,pivotY:t.pivot.y,strokeWidth:t.style.strokeWidth,dashArray:t.style.strokeDashArray||"",opacity:t.style.opacity,shadow:t.shadow,gradient:t.style.gradient,visible:t.visible,id:t.id,description:t.description,canApplyStyle:t.canApplyStyle,shapeType:t.shapeType};return"Page"===t.rotationReference&&(r.angle=t.rotateAngle),i&&(r.x=r.x-.5,r.y=r.y-.5),t.isExport&&(r.width*=t.exportScaleValue.x,r.height*=t.exportScaleValue.y,r.x*=t.exportScaleValue.x,r.y*=t.exportScaleValue.y,r.strokeWidth*=t.exportScaleValue.x),t.flip&&(r.flip=t.flip),e&&(r.x+=e.tx,r.y+=e.ty),r},n.renderSvgBackGroundImage=function(t,e,i,r,s,o){if(t.source){var l=vT(e.id).getElementById(e.id+"_image");if(!l){var h=function goe(n){return xt(n).getElementsByClassName("e-background-image-layer")[0]}(e.id);(l=document.createElementNS("http://www.w3.org/2000/svg","image")).setAttribute("id",e.id+"_image"),h.appendChild(l)}var c=new Image;c.src=t.source,l.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",c.src.toString());var d="None"!==t.scale?t.scale:"",u=t.align,p=u.charAt(0).toLowerCase()+u.slice(1);d&&(p+=" "+d.charAt(0).toLowerCase()+d.slice(1)),oi(l,{id:e.id+"_image",x:i,y:r,width:s,height:o,preserveAspectRatio:p})}},n.prototype.transformLayers=function(t,e){var i=t.tx*t.scale,r=t.ty*t.scale,s="domTable";if(i!==this.transform.x||r!==this.transform.y||0===i||0===r){e&&(window[""+s][this.diagramId+"_diagramLayer"]||(window[""+s][this.diagramId+"_diagramLayer"]=this.diagramSvgLayer.getElementById(this.diagramId+"_diagramLayer")),window[""+s][this.diagramId+"_diagramLayer"].setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+"),scale("+t.scale+")"));var a=function voe(n){var t="domTable",e=null;return window[t][n+"_gridline"]?e=window[t][n+"_gridline"]:(e=Bd(n).getElementById(n+"_gridline"),window[t][n+"_gridline"]=e),e}(this.diagramId);return a.setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+")"),window[""+s][this.diagramId+"_diagramPorts"]||(window[""+s][this.diagramId+"_diagramPorts"]=this.iconSvgLayer.getElementById(this.diagramId+"_diagramPorts")),window[""+s][this.diagramId+"_diagramPorts"].setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+"),scale("+t.scale+")"),window[""+s][this.diagramId+"_diagramExpander"]||(window[""+s][this.diagramId+"_diagramExpander"]=this.iconSvgLayer.getElementById(this.diagramId+"_diagramExpander")),window[""+s][this.diagramId+"_diagramExpander"].setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+"),scale("+t.scale+")"),window[""+s][this.diagramId+"_nativeLayer"]||(window[""+s][this.diagramId+"_nativeLayer"]=this.nativeSvgLayer.getElementById(this.diagramId+"_nativeLayer")),window[""+s][this.diagramId+"_nativeLayer"].setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+"),scale("+t.scale+")"),Io(this.diagramId).children[0].style.transform="translate("+t.tx*t.scale+"px,"+t.ty*t.scale+"px)scale("+t.scale+")",this.transform={x:t.tx*t.scale,y:t.ty*t.scale},!0}return!1},n.prototype.updateNode=function(t,e,i,r,s,o,a){this.renderElement(t,e,i,r,this.getParentSvg(t),void 0,void 0,s,null,o,a)},n}(),Kne=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),XI=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},nF=function(n){function t(e,i){var r=n.call(this,e,i)||this;return r.mode="Canvas",r.id="overview",r.actionName="",r.startPoint=null,r.currentPoint=null,r.prevPoint=null,r.scale=null,r.inAction=!1,r.viewPortRatio=1,r.horizontalOffset=0,r.verticalOffset=0,r.model={},r.event=!0,r.overviewid=88123,r.model={width:r.width,height:r.height},r}return Kne(t,n),t.prototype.onPropertyChanged=function(e,i){for(var r=0,s=Object.keys(e);r0||e.toString().indexOf("%")>0?e.toString():e.toString()+"px"},t.prototype.renderCanvas=function(e){var i=document.getElementById(this.element.id+"_canvas");i||(i=Tt("div",{}),this.element.appendChild(i)),Ho(i,{id:this.element.id+"_canvas",class:"drawing",style:"position:relative; height:"+this.getSizeValue(this.model.height)+"; width:"+this.getSizeValue(this.model.width)+";style:-ms-touch-action: none;touch-action: none;"}),this.element.setAttribute("tabindex",String(-1)),this.element.style.overflow="hidden",this.element.style.height=String(this.model.height),this.element.style.width=String(this.model.width),this.canvas=i},t.prototype.setParent=function(e){var i=document.getElementById(e);if(this.parent){var s=this.parent;this.parent=null,s.setOverview(null,this.element.id),this.removeDocument(this)}this.parent=this.getDiagram(i,"ej2_instances"),this.parent&&this.parent.setOverview(this)},t.prototype.getDiagram=function(e,i){for(var r,s=e[""+i].length,o=0;o0?p:Math.floor(window.innerWidth)}if(0===h){var f=Math.floor(window.innerHeight-u-Math.floor(c.top));h=f>0?f:Math.floor(window.innerHeight)}l>0&&(s.setAttribute("width",String(l)),this.model.height=h),h>0&&(s.setAttribute("height",String(h)),this.model.width=l),e.diagramLayerDiv||(e.diagramLayerDiv=Tt("div",{}),e.diagramLayer=bo.createCanvas(this.element.id+"_diagramLayer",this.model.width,this.model.height),e.diagramLayer.setAttribute("style","position:absolute; left:0px; top:0px "),e.diagramLayerDiv.appendChild(e.diagramLayer),e.canvas.appendChild(e.diagramLayerDiv)),Ho(e.diagramLayerDiv,{id:this.element.id+"_diagramLayer_div",style:"width:"+this.model.width+"px; height:"+this.model.height+"px;position:absolute;top:0px;left:0px"}),this.renderHtmlLayer(e.canvas),this.renderNativeLayer(e.canvas,e),this.addOverviewRectPanel(e)},t.prototype.removeDocument=function(e){var i=document.getElementById(this.canvas.id+"_svg");this.canvas.removeChild(i);var r=document.getElementById(this.element.id+"_htmlLayer");this.canvas.removeChild(r);var s=document.getElementById(this.element.id+"_diagramLayer_div");this.canvas.removeChild(s),e.diagramLayerDiv=null,e.diagramLayer=null,window.domTable[this.id+"html_layer"]=null},t.prototype.renderHtmlLayer=function(e){var i=Tt("div",{id:this.element.id+"_htmlLayer",class:"e-html-layer",style:"pointer-events:none;position:absolute;top:0px;left:0px;"}),s=Tt("div",{id:this.element.id+"_htmlLayer_div",style:"position:absolute;top:0px;left:0px;"});return i.appendChild(s),e.appendChild(i),i},t.prototype.renderNativeLayer=function(e,i){if(!document.getElementById(this.element.id+"_nativeLayer_svg")){var r=this.parent.createSvg(this.element.id+"_nativeLayer_svg",this.model.width,this.model.height),s=Bi("g",{id:this.element.id+"_nativeLayer"});r.appendChild(s),i.diagramLayerDiv.appendChild(r),oi(r,{class:"e-native-layer"})}},t.prototype.addOverviewRectPanel=function(e){var i=document.getElementById(this.canvas.id+"_overviewsvg");i&&i.parentNode.removeChild(i),i=Bi("svg",{id:this.canvas.id+"_overviewsvg",class:"overviewsvg",version:"1.1",style:"position:absolute;left:0px;top:0px; aria-label:Specifies overview",width:this.model.width,height:this.model.height}),e.canvas.appendChild(i);var s=Bi("g",{id:this.element.id+"_overviewlayer",style:"pointer-events:none"});i.appendChild(s);var o=Bi("rect",{fill:"transparent",width:"100%",height:"100%",class:"overviewbackrect",id:this.canvas.id+"overviewbackrect"});o.setAttribute("style"," pointer-events: none; "),s.appendChild(o);var a=Bi("g",{id:this.canvas.id+"overviewhandle",style:"pointer-events:all"});s.appendChild(a);var l=Bi("rect",{id:this.canvas.id+"overviewrect",fill:"transparent"});a.appendChild(l),this.renderOverviewCorner("left",a),this.renderOverviewCorner("right",a),this.renderOverviewCorner("top",a),this.renderOverviewCorner("bottom",a),this.renderOverviewCorner("topleft",a),this.renderOverviewCorner("topright",a),this.renderOverviewCorner("bottomleft",a),this.renderOverviewCorner("bottomright",a)},t.prototype.renderOverviewCorner=function(e,i){var s,o=Bi(s="top"===e||"bottom"===e||"right"===e||"left"===e?"rect":"circle",{id:this.canvas.id+"visible"+e,class:"overview-resizer"});i.appendChild(o);var a=Bi(s,{id:this.canvas.id+e,class:"overviewresizer",fill:"transparent"});i.appendChild(a)},t.prototype.updateOverviewRectangle=function(){var e=this.currentPoint.x-this.prevPoint.x,i=this.currentPoint.y-this.prevPoint.y,r=new me;r.width=0,r.height=0;var s=0,o=0;switch(this.resizeDirection){case"left":r.width-=e,r.height-=e/this.viewPortRatio,s=e,o=e/this.viewPortRatio,o/=2;break;case"right":r.width+=e,r.height+=e/this.viewPortRatio,o=e/this.viewPortRatio,o/=-2;break;case"top":r.height-=i,r.width-=i*this.viewPortRatio,o=i,s=i*this.viewPortRatio,s/=2;break;case"bottom":r.height+=i,r.width+=i*this.viewPortRatio,s=i*this.viewPortRatio,s/=-2;break;case"topleft":Math.abs(i)>Math.abs(e)?e=i*this.viewPortRatio:i=e/this.viewPortRatio,r.width-=e,r.height-=i,s=e,o=i;break;case"topright":Math.abs(i)>Math.abs(e)?e=-i*this.viewPortRatio:i=-e/this.viewPortRatio,o=i,r.width+=e,r.height-=i;break;case"bottomleft":Math.abs(i)>Math.abs(e)?e=-i*this.viewPortRatio:i=-e/this.viewPortRatio,s=e,r.width-=e,r.height+=i;break;case"bottomright":Math.abs(i)>Math.abs(e)?e=i*this.viewPortRatio:i=e/this.viewPortRatio,r.width+=e,r.height+=i}this.updateHelper(s,o,r,void 0,void 0)},t.prototype.updateHelper=function(e,i,r,s,o){var a,l,h,u,p,d=this.element.getElementsByTagName("svg")[2].getElementById("helper");r?(a=(h=d.getBBox()).x+e,l=h.y+i,s=h.width+r.width,o=h.height+r.height):(u=this.currentPoint.x>this.startPoint.x?this.currentPoint.x-this.prevPoint.x:this.prevPoint.x-this.currentPoint.x,p=this.currentPoint.y>this.startPoint.y?this.currentPoint.y-this.prevPoint.y:this.prevPoint.y-this.currentPoint.y,Math.abs(p)>Math.abs(u)?u=this.viewPortRatio*p:p=u/this.viewPortRatio,h=d.getBBox(),a=this.startPoint.x>this.currentPoint.x?h.x-u:h.x,l=this.startPoint.y>this.currentPoint.y?h.y-p:h.y,s=h.width+u,o=h.height+p),oi(this.helper,{id:this.helper.id,x:a,y:l,width:Math.max(0,s),height:Math.max(0,o)})},t.prototype.updateOverviewrect=function(e,i,r,s){Ho(document.getElementById(this.canvas.id+"overviewrect"),{x:e,y:i,width:Math.max(1,r),height:Math.max(1,s)}),this.updateOverviewCorner("top",e+8,i+1,Math.max(0,r-16),2),this.updateOverviewCorner("bottom",e+8,i+s+3,Math.max(0,r-16),2),this.updateOverviewCorner("left",e-2,i+11,2,Math.max(0,s-16)),this.updateOverviewCorner("right",e+r,i+11,2,Math.max(0,s-16)),this.updateOverviewCorner("topleft",e,i+3,5,5),this.updateOverviewCorner("topright",e+r,i+3,5,5),this.updateOverviewCorner("bottomleft",e,i+s+3,5,5),this.updateOverviewCorner("bottomright",e+r,i+s+3,5,5)},t.prototype.updateOverviewCorner=function(e,i,r,s,o){var a,l;"top"===e||"bottom"===e||"right"===e||"left"===e?(a={x:i,y:r,width:s,height:o,fill:"#ED1C24"},l={x:i-2,y:r-2,width:2===s?4:s,height:2===o?4:o}):(a={cx:i,cy:r,r:4,fill:"#ED1C24"},l={cx:i,cy:r,r:6,fill:"transparent"}),Ho(document.getElementById(this.canvas.id+"visible"+e),a),Ho(document.getElementById(this.canvas.id+e),l)},t.prototype.translateOverviewRectangle=function(){Number(this.model.width),Number(this.model.height);var r=this.currentPoint.x-this.prevPoint.x,s=this.currentPoint.y-this.prevPoint.y,l=this.element.getElementsByClassName("overviewsvg")[0].getElementById(this.canvas.id+"overviewrect").getBBox(),h=l.x+r,c=l.y+s,d=l.width,u=l.height;this.updateOverviewrect(h,c,d,u),this.updateParentView(this.parent.scroller.currentZoom,h,c,d,u,null)},t.prototype.renderOverviewRect=function(e,i,r,s){var o=Number(this.model.width),a=Number(this.model.height),c=Math.max(this.parent.scroller.viewPortWidth/(r/o*this.contentWidth),this.parent.scroller.viewPortHeight/(s/a*this.contentHeight));if(c>=.25&&c<=30){this.updateParentView(c,e,i,r,s,{x:0,y:0});var u=this.scrollOverviewRect(this.parent.scroller.horizontalOffset,this.parent.scroller.verticalOffset,this.parent.scroller.currentZoom,!0);if(this.helper){var f=this.element.getElementsByTagName("rect")[10].getBBox();u.x=f.x,u.y=f.y}"pan"===this.actionName?this.updateOverviewrect(-u.x,-u.y,u.width,u.height):this.updateOverviewrect(u.x,u.y,u.width,u.height)}},t.prototype.scrollOverviewRect=function(e,i,r,s){if(!this.actionName||s){var o=Number(this.model.width),a=Number(this.model.height),l=Math.min(this.contentWidth/o,this.contentHeight/a),h=new Ne,c=h.x=e/r/l,d=h.y=i/r/l,u=0;this.parent.rulerSettings.showRulers&&(u=25);var p=document.getElementById(this.parent.element.id+"content"),f=0,g=0;p&&(f=p.offsetWidth-p.clientWidth,g=p.offsetHeight-p.clientHeight);var v=h.width=(this.parent.scroller.viewPortWidth-u-f)/r/l,y=h.height=(this.parent.scroller.viewPortHeight-u-g)/r/l;if(s){var S=new Ne;return S.x=c,S.y=d,S.width=v,S.height=y,S}this.updateOverviewrect(-c,-d,v,y)}return null},t.prototype.updateParentView=function(e,i,r,s,o,a){var f,g,l=Number(this.model.width),h=Number(this.model.height),u=i*(this.contentWidth/l)*e,p=r*(this.contentHeight/h)*e;this.parent.scroller.getPageBounds(),(1!==e||"pan"===this.actionName)&&(f=-u-this.parent.scroller.horizontalOffset,g=-p-this.parent.scroller.verticalOffset),this.parent.setBlazorDiagramProps(!0),this.parent.realActions|=$i.OverViewAction,"scale"===this.actionName||"draw"===this.actionName?this.parent.scroller.zoom(e/this.parent.scroller.currentZoom,f,g,a):ce()?this.parent.scroller.zoom(1,f,g,a):this.parent.pan(f,g,a,!0)},t.prototype.updateHtmlLayer=function(e){var i=Io(e.element.id),r=this.parent.scroller.getPageBounds(!0),o=r.height,a=Math.max(r.width,this.parent.scroller.viewPortWidth),l=Math.max(o,this.parent.scroller.viewPortHeight/this.parent.scroller.currentZoom),h=Math.min(Number(this.model.width)/a,Number(this.model.height)/l);i.style.transform="scale("+h+") translate("+this.parent.scroller.transform.tx+"px,"+this.parent.scroller.transform.ty+"px)"},t.prototype.updateView=function(e){var i=this.parent.scroller.getPageBounds(),r=i.width,s=i.height,o=Number(this.model.width),a=Number(this.model.height),l=Math.max(r,this.parent.scroller.viewPortWidth),h=Math.max(s,this.parent.scroller.viewPortHeight);this.contentWidth=l=Math.max(l,o/a*h),this.contentHeight=h=Math.max(h,a/o*l);var c=Math.min(o/l,a/h),d=document.getElementById(this.element.id+"_htmlLayer");d.style.webkitTransform="scale("+c+") translate("+-i.x+"px,"+-i.y+"px)",d.style.transform="scale("+c+") translate("+-i.x+"px,"+-i.y+"px)",document.getElementById(this.element.id+"_overviewlayer").setAttribute("transform","translate("+-i.x*c+","+-i.y*c+")"),this.horizontalOffset=i.x*c,this.verticalOffset=i.y*c;var p=document.getElementById(this.element.id+"_diagramLayer"),f=kF(this.element.id),g=p.getContext("2d"),v=Number(this.model.width)/this.contentWidth,y=Number(this.model.height)/this.contentHeight;v=Math.min(v,y);var S=this.parent.scroller.transform;f.setAttribute("transform","translate("+S.tx*v+","+S.ty*y+"),scale("+v+")"),g.setTransform(v,0,0,v,0,0),g.fillStyle="red",this.scrollOverviewRect(this.parent.scroller.horizontalOffset,this.parent.scroller.verticalOffset,this.parent.scroller.currentZoom)},t.prototype.scrolled=function(e){if(this.event){var i=this.scrollOverviewRect(this.parent.scroller.horizontalOffset,this.parent.scroller.verticalOffset,this.parent.scroller.currentZoom,!0);this.updateOverviewrect(-i.x,-i.y,i.width,i.height),this.updateView(this)}},t.prototype.updateCursor=function(e){if(hm(e.target,"overviewresizer"))switch(e.target.id){case this.canvas.id+"left":this.canvas.style.cursor="w-resize";break;case this.canvas.id+"right":this.canvas.style.cursor="e-resize";break;case this.canvas.id+"top":this.canvas.style.cursor="n-resize";break;case this.canvas.id+"bottom":this.canvas.style.cursor="s-resize";break;case this.canvas.id+"topleft":this.canvas.style.cursor="nw-resize";break;case this.canvas.id+"topright":this.canvas.style.cursor="ne-resize";break;case this.canvas.id+"bottomleft":this.canvas.style.cursor="sw-resize";break;case this.canvas.id+"bottomright":this.canvas.style.cursor="se-resize"}else this.canvas.style.cursor="default"},t.prototype.mouseMove=function(e){if(this.event=!1,this.updateCursor(e),this.currentPoint=this.mousePosition(e),this.actionName)switch(this.actionName){case"draw":!this.inAction&&(this.startPoint.x!==this.currentPoint.x||this.startPoint.y!==this.currentPoint.y)&&(this.initHelper(),this.inAction=!0),this.inAction&&this.updateHelper();break;case"scale":this.inAction||(this.initHelper(),this.inAction=!0),this.updateOverviewRectangle();break;case"pan":(this.startPoint.x!==this.currentPoint.x||this.startPoint.y===this.currentPoint.y||this.inAction)&&(this.inAction=!0,this.translateOverviewRectangle())}this.prevPoint=this.currentPoint},t.prototype.documentMouseUp=function(e){this.inAction=!1,this.actionName="",this.helper&&(this.helper.parentNode.removeChild(this.helper),this.helper=null),this.event=!0,document.getElementById(this.canvas.id+"overviewhandle").style.pointerEvents="all"},t.prototype.windowResize=function(e){var i=this;return this.resizeTo&&clearTimeout(this.resizeTo),this.resizeTo=setTimeout(function(){var s=document.getElementById(i.element.id).getBoundingClientRect();i.model.width=s.width>0?s.width:i.model.width,i.model.height=s.height>0?s.height:i.model.height,i.renderCanvas(),i.setParent(i.sourceID)},10),!1},t.prototype.mouseDown=function(e){if(e.target.id===this.canvas.id+"_overviewsvg"&&(this.actionName="draw"),e.target.id===this.canvas.id+"overviewrect"&&(this.actionName="pan"),hm(e.target,"overviewresizer"))switch(this.actionName="scale",e.target.id){case this.canvas.id+"left":this.resizeDirection="left";break;case this.canvas.id+"right":this.resizeDirection="right";break;case this.canvas.id+"top":this.resizeDirection="top";break;case this.canvas.id+"bottom":this.resizeDirection="bottom";break;case this.canvas.id+"topleft":this.resizeDirection="topleft";break;case this.canvas.id+"topright":this.resizeDirection="topright";break;case this.canvas.id+"bottomleft":this.resizeDirection="bottomleft";break;case this.canvas.id+"bottomright":this.resizeDirection="bottomright"}this.startPoint=this.prevPoint=this.mousePosition(e),this.viewPortRatio=this.parent.scroller.viewPortWidth/this.parent.scroller.viewPortHeight,document.getElementById(this.canvas.id+"overviewhandle").style.pointerEvents="none"},t.prototype.mouseUp=function(e){if(this.currentPoint=this.mousePosition(e),this.actionName)if(this.startPoint.x!==this.currentPoint.x||this.startPoint.y!==this.currentPoint.y){if("pan"!==this.actionName&&this.helper){var i=this.element.getElementsByTagName("rect")[10].getBBox();this.resizeDirection=this.resizeDirection||"",this.renderOverviewRect(i.x,i.y,o=i.width,a=i.height)}}else if(e.target.id===this.canvas.id+"_overviewsvg"||"helper"===e.target.id){var o=(i=this.element.getElementsByTagName("svg")[2].getElementById(this.canvas.id+"overviewrect").getBBox()).width,a=i.height;this.inAction=!0,this.actionName="pan",this.renderOverviewRect(this.currentPoint.x-o/2,this.currentPoint.y-a/2,o,a),this.inAction=!1}this.helper&&(this.helper.parentNode.removeChild(this.helper),this.helper=null),this.actionName="",this.startPoint=null,this.currentPoint=null,this.prevPoint=null,this.helper=null,this.viewPortRatio=1,this.resizeDirection="",this.inAction=!1,this.event=!0,document.getElementById(this.canvas.id+"overviewhandle").style.pointerEvents="all"},t.prototype.initHelper=function(){var e=this.element.getElementsByTagName("svg")[2],i=this.startPoint.x,r=this.startPoint.y,s=1,o=1;if("scale"===this.actionName){var l=e.getElementById(this.canvas.id+"overviewrect").getBBox();i=l.x,r=l.y,s=l.width,o=l.height}var h=Bi("rect",{id:"helper",x:i,y:r,width:s,height:o,fill:"transparent",stroke:"gray","stroke-dasharray":"2 2","shape-rendering":"crispEdges"});e.getElementById(this.element.id+"_overviewlayer").appendChild(h),this.helper=h},t.prototype.mousePosition=function(e){var i,r,s;-1!==e.type.indexOf("touch")?(r=(i=e).changedTouches[0].clientX-this.element.offsetLeft,s=i.changedTouches[0].clientY-this.element.offsetTop):(r=e.clientX,s=e.clientY);var l=this.element.getBoundingClientRect();return{x:(r-=l.left)+this.horizontalOffset,y:(s-=l.top)+this.verticalOffset}},t.prototype.destroy=function(){if(this.unWireEvents(),this.notify("destroy",{}),n.prototype.destroy.call(this),document.getElementById(this.element.id)){this.element.classList.remove("e-overview");var e=document.getElementById(this.element.id+"_canvas");e&&this.element.removeChild(e)}this.parent.views.splice(this.parent.views.indexOf(this.element.id),1),this.diagramLayerDiv=null,this.canvas=null,this.parent=null},t.prototype.getModuleName=function(){return"Overview"},XI([I("100%")],t.prototype,"width",void 0),XI([I("100%")],t.prototype,"height",void 0),XI([I("")],t.prototype,"sourceID",void 0),XI([H()],t.prototype,"created",void 0),t}(yi);function tse(n,t){for(var e=0;ez.findLength(e,n)?e:t;var o=z.findAngle(t,e),a=z.findAngle(i,n),l=z.findLength(i,n),h=a+2*(o-a);return{x:i.x+l*Math.cos(h*Math.PI/180),y:i.y+l*Math.sin(h*Math.PI/180)}}function $p(n,t,e){if(n&&n.children&&n.children.length>0)for(var r=void 0,s=0;s0&&"annotations"!==r&&"ports"!==r)if(n[""+l].length>0)for(var h=0;h<=n[""+l].length;h++)Ro(n[""+l],t?t[""+l]:void 0,e[""+l],"annotations"===l||"ports"===l?n:void 0,l);else Ro(n[""+l],t?t[""+l]:void 0,e[""+l],"annotations"===l||"ports"===l?n:void 0,l);else if(s instanceof Object&&t&&"annotations"!==r&&"ports"!==r)Ro(n[""+l],t[""+l],e[""+l]);else if("annotations"!==r&&"ports"!==r&&t&&!t[""+l]||!t&&n&&(n[""+l]||void 0!==n[""+l]))n[""+l]=e[""+l];else{var c=void 0;("annotations"===r||"ports"===r)&&("annotations"===r?(n[""+l]&&Ro(n[""+l],t[""+l],e[""+l]),n[""+l]||(fs(i)===de?(c=new Nr(i,"annotations",e[""+l]),i.annotations.push(c)):(c=new Zn(i,"annotations",e[""+l]),i.annotations.push(c)))):n[""+l]?Ro(n[""+l],t[""+l],e[""+l]):(c=new Es(i,"ports",e[""+l]),i.ports.push(c)))}}}function lse(n,t){for(var e="Bezier"===n.type?function sse(n){var t=[];if("Bezier"===n.type)for(var e=0,i=0;i0||n.ports.length>0){var p=n.wrapper.children;for(i=3;i0)return{enabled:!1,intersectPt:e};var l=o/s,h=a/s;return l>=0&&l<=1&&h>=0&&h<=1?(e.x=i.x1+l*(i.x2-i.x1),e.y=i.y1+l*(i.y2-i.y1),{enabled:!0,intersectPt:e}):{enabled:!1,intersectPt:e}}function $I(n,t,e,i){var a=Jv(lF(n.x,n.y,t.x,t.y),lF(e.x,e.y,i.x,i.y));return a.enabled?a.intersectPt:{x:0,y:0}}function lF(n,t,e,i){return{x1:Number(n)||0,y1:Number(t)||0,x2:Number(e)||0,y2:Number(i)||0}}function hF(n,t,e){var i=[],s={x:t.topRight.x+(e=e||0),y:t.topRight.y},o={x:t.bottomRight.x,y:t.bottomRight.y-e},a={x:t.bottomLeft.x,y:t.bottomLeft.y+e};return i.push({x:t.topLeft.x-e,y:t.topLeft.y}),i.push(s),i.push(o),i.push(a),i}function zc(n,t,e,i,r,s){var o={},a=e.scroller.transform.scale,h=e.scroller.verticalOffset;return o.x=(i?n.x:t.x)*a+e.scroller.horizontalOffset-r,o.y=(i?n.y:t.y)*a+h-s,o}function cF(n,t){var e=new Ke;return e.data=n.pathData,e.height=n.height>10?n.height-(n.padding.bottom+n.padding.top):n.height,e.width=n.width>10?n.width-(n.padding.left+n.padding.right):n.width,e.visible=n.visibility,e.id=t.id+"_shape",e.inversedAlignment=!1,e.horizontalAlignment="Center",e.verticalAlignment="Center",e.style={fill:n.iconStrokeColor,strokeColor:n.iconStrokeColor,strokeWidth:n.iconStrokeWidth},e.setOffsetWithRespectToBounds(.5,.5,"Fraction"),e.relativeMode="Object",e.description=t.description||"",e}function Gx(n,t,e){var i=Xx(n,t),r=z.findAngle(n[i.index],n[i.index+1]),s=function gse(n){var t;t=n instanceof wI?0:void 0===n.content?10:0;var e=0;switch(n.alignment){case"Center":e=0;break;case"Before":e=-(0+t);break;case"After":e=0+t}return e}(t),o=z.transform(i.point,r+45,s);return i.point=o,i.angle=r,i}function Xx(n,t){for(var r,s,a,l,e=0,i=t.offset,o=[],h=0;h=c)return s=z.findAngle(n[parseInt(d.toString(),10)],n[d+1]),{point:r=z.transform(n[parseInt(d.toString(),10)],s,c-(a||0)),index:l=d};a=o[parseInt(d.toString(),10)]}return{point:r,index:l}}function dF(n,t,e){t%=360;var a,l,s=225;switch(n.alignment){case"Before":t>=45&&t<=135?(l="right",a=.5===n.offset?"center":"top"):t>=s&&t<=315?(l="left",a=.5===n.offset?"center":"bottom"):t>45&&t=45&&t<=135?(l="left",a=.5===n.offset?"center":"top"):t>=s&&t<=315?(l="right",a=.5===n.offset?"center":"bottom"):t>45&&tMath.abs(t.y-n.y)?n.x0)for(var e=0;e=0;r--)("nodes"===i||"connectors"===i)&&(n[""+i][parseInt(r.toString(),10)].wrapper=null),"dataManager"!==i&&(n[""+i][parseInt(r.toString(),10)]=Zx(n[""+i][parseInt(r.toString(),10)],e[""+i][parseInt(r.toString(),10)],void 0!==t[""+i]?t[""+i][parseInt(r.toString(),10)]:[]),("[]"===JSON.stringify(n[""+i][parseInt(r.toString(),10)])||"{}"===JSON.stringify(n[""+i][parseInt(r.toString(),10)])||void 0===n[""+i][parseInt(r.toString(),10)])&&n[""+i].splice(r,1));n=void 0}function Ph(n,t){var e=t.style,i=t;t.canApplyStyle=!0;for(var r=0,s=Object.keys(n);r=0&&n.splice(e,1)}function Zp(n,t,e){var i;n.intermediatePoints=t,n.updateSegmentElement(n,t,n.wrapper.children[0],e);var r=n.sourceDecorator;if("Bezier"===n.type){var s=n.segments[0],o=n.segments[n.segments.length-1];i=[z.isEmptyPoint(o.point2)?o.bezierPoint2:o.point2,z.isEmptyPoint(s.point1)?s.bezierPoint1:s.point1]}else i=n.intermediatePoints;t=n.clipDecorators(n,t,e);var a=n.wrapper.children[0];a.canMeasurePath=!0,n.updateDecoratorElement(a=n.wrapper.children[1],t[0],i[1],r),n.updateDecoratorElement(a=n.wrapper.children[2],t[t.length-1],i[i.length-2],n.targetDecorator),n.updateShapeElement(n)}function Jx(n,t,e){var l,i=n.wrapper,s=t.offset,o=t.size/e.scale,a=t.margin,h=i.offsetX-i.actualSize.width*i.pivot.x,c=i.offsetY-i.actualSize.height*i.pivot.y;if(l={x:0,y:0},n.nodes.length>0){switch(t.side){case"Top":l.x+=h+s*i.actualSize.width,l.y+=c-o;break;case"Bottom":l.x+=h+s*i.actualSize.width,l.y+=c+i.actualSize.height+o;break;case"Left":l.x+=h-o,l.y+=c+s*i.actualSize.height;break;case"Right":l.x+=h+i.actualSize.width+o,l.y+=c+s*i.actualSize.height}l.x+=(a.left-a.right)/e.scale+o/2*("Center"===t.horizontalAlignment?0:"Right"===t.horizontalAlignment?-1:1),l.y+=(a.top-a.bottom)/e.scale+o/2*("Center"===t.verticalAlignment?0:"Top"===t.verticalAlignment?-1:1)}else if(n.connectors.length>0){var d=n.connectors[0],u={offset:s},p=Xx(d.intermediatePoints,u),f=p.index;l=p.point;var y,v=Gx(d.intermediatePoints,u).angle;qi(y=Hi(),-v,d.intermediatePoints[parseInt(f.toString(),10)].x,d.intermediatePoints[parseInt(f.toString(),10)].y),(l=Je(y,l)).x+=a.left-a.right+o/2*("Center"===t.horizontalAlignment?0:"Right"===t.horizontalAlignment?-1:1),l.y+=a.top-a.bottom+o/2*("Center"===t.verticalAlignment?0:"Top"===t.verticalAlignment?-1:1),qi(y=Hi(),v,d.intermediatePoints[parseInt(f.toString(),10)].x,d.intermediatePoints[parseInt(f.toString(),10)].y),l=Je(y,l)}return 0===i.rotateAngle&&0===i.parentTransform||(qi(y=Hi(),i.rotateAngle+i.parentTransform,i.offsetX,i.offsetY),l=Je(y,l)),l}function fa(n,t,e,i){if(i.annotation){if(Ol(i.annotation))return!0}else if(lr[""+t]&n&&bt[""+t]&e)return!0;return!1}function qr(n,t){return!!(lr[""+t]&n)}function Hc(n,t){return!!(Ix[""+t]&n)}function ga(n,t){return n.visibility&t}function ZI(n,t){var e;if("Text"===n.shape.type)e=n.shape;else{var i=t.split("_");t=i[i.length-1];for(var r=0;rn[""+t]?e.splice(0,0,n):e.push(n);else if(e.length>1){for(var i=0,r=e.length-1,s=Math.floor((i+r)/2);s!==i;)if(e[parseInt(s.toString(),10)][""+t]n[""+t]))break;r=s,s=Math.floor((i+r)/2)}e[parseInt(r.toString(),10)][""+t]n[""+t]?e.splice(i,0,n):e[parseInt(i.toString(),10)][""+t]n[""+t]&&e.splice(r,0,n)}}function kse(n){var t=document.getElementById(n.diagramId),e="ej2_instances",i=t[""+e][0].nodes;void 0===i&&(i=function Pse(n){for(var t=[],e=0;e30?10:o/2;for(var h=0,c=0;c=l){var u=l-h;r=Gt(n[c],n[c+1]),s=z.transform(n[c],r,u);break}h+=d}return s},eb=function(n,t){if(n instanceof te||n instanceof de)for(var e=0;e=0||navigator.platform.indexOf("iPad")>=0||navigator.platform.indexOf("iPhone")>=0||navigator.platform.indexOf("MacIntel")>=0)&&("safari"===X.info.name||"webkit"===X.info.name)}function bF(n,t,e,i){return void 0!==t.previewSize[""+i]?t.previewSize[""+i]:void 0!==n.symbolPreview[""+i]?n.symbolPreview[""+i]:t[""+i]||e.actualSize[""+i]}function rm(n,t,e){return n&&n.parentId&&(e=(n=t.nameTable[n.parentId]).parentId?rm(n,t,e):n.id),e}function nm(n,t){return n.selectedItems.connectors.length>1&&0===n.selectedItems.nodes.length&&0!==t.rotateAngle}function Bse(n){if(n.arrowType&&""!==n.arrowType.trim())switch(n.arrowType){case"single-line-arrow":default:return{targetDecorator:"Arrow",strokeWidth:1};case"double-line-arrow":return{targetDecorator:"Arrow",strokeWidth:2};case"dotted-arrow":return{targetDecorator:"Arrow",strokeDashArray:"2,2"};case"single-line":return{targetDecorator:"None",strokeWidth:1};case"double-line":return{targetDecorator:"None",strokeWidth:2};case"dotted":return{targetDecorator:"None",strokeDashArray:"2,2"};case"wiggly-arrow":return{targetDecorator:"None",strokeWidth:1,opacity:0}}return{targetDecorator:"Arrow",strokeWidth:1}}var Fse=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),io=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},MF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Fse(t,n),io([I("None")],t.prototype,"shape",void 0),io([I("white")],t.prototype,"fill",void 0),io([I("Auto")],t.prototype,"horizontalAlignment",void 0),io([I("Auto")],t.prototype,"verticalAlignment",void 0),io([I(10)],t.prototype,"width",void 0),io([I(10)],t.prototype,"height",void 0),io([re({x:.5,y:1},z)],t.prototype,"offset",void 0),io([I("#1a1a1a")],t.prototype,"borderColor",void 0),io([I(1)],t.prototype,"borderWidth",void 0),io([re({},$n)],t.prototype,"margin",void 0),io([I("")],t.prototype,"pathData",void 0),io([I("")],t.prototype,"content",void 0),io([I(0)],t.prototype,"cornerRadius",void 0),io([re({left:2,right:2,top:2,bottom:2},$n)],t.prototype,"padding",void 0),io([I("#1a1a1a")],t.prototype,"iconColor",void 0),t}(Ee),_se=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),iT=function(n){function t(){var e=null!==n&&n.apply(this,arguments)||this;return e.orientation="Vertical",e.measureChildren=void 0,e.considerPadding=!0,e}return _se(t,n),t.prototype.measure=function(e){return this.desiredSize=this.measureStackPanel(e,"Horizontal"===this.orientation?this.updateHorizontalStack:this.updateVerticalStack),this.desiredSize},t.prototype.arrange=function(e){return this.actualSize=this.arrangeStackPanel(e,"Horizontal"===this.orientation?this.arrangeHorizontalStack:this.arrangeVerticalStack),this.updateBounds(),this.actualSize},t.prototype.measureStackPanel=function(e,i){var r=void 0;if(void 0!==this.children&&this.children.length>0)for(var s=0,o=this.children;s0){var r=void 0,s=void 0;r=this.offsetX-e.width*this.pivot.x+this.padding.left,s=this.offsetY-e.height*this.pivot.y+this.padding.top;for(var o=0,a=this.children;o0)for(var i=0,r=this.children;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Xse=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Gse(t,n),zh([I("Horizontal")],t.prototype,"orientation",void 0),zh([I("Center")],t.prototype,"type",void 0),zh([I(void 0)],t.prototype,"offset",void 0),zh([I(!1)],t.prototype,"enableRouting",void 0),zh([I([])],t.prototype,"children",void 0),zh([I("")],t.prototype,"assistants",void 0),zh([I("")],t.prototype,"level",void 0),zh([I("")],t.prototype,"hasSubTree",void 0),zh([I("")],t.prototype,"rows",void 0),t}(Ee),Li=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),q=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},qse=function(n){if(n)switch(n.type){case"Basic":default:return tb;case"Flow":return DF;case"Path":return wF;case"Image":return EF;case"Text":return Pd;case"Bpmn":return lT;case"Native":return sm;case"HTML":return CF;case"UmlActivity":return xF;case"UmlClassifier":return TF;case"SwimLane":return Hd}return tb},va=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),q([I("Basic")],t.prototype,"type",void 0),t}(Ee),wF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"Path"},q([I("Path")],t.prototype,"type",void 0),q([I("")],t.prototype,"data",void 0),t}(va),sm=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"Native"},q([I("Native")],t.prototype,"type",void 0),q([I("")],t.prototype,"content",void 0),q([I("Stretch")],t.prototype,"scale",void 0),t}(va),CF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"Html"},q([I("HTML")],t.prototype,"type",void 0),q([I("")],t.prototype,"content",void 0),t}(va),EF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"Image"},q([I("Image")],t.prototype,"type",void 0),q([I("")],t.prototype,"source",void 0),q([I("None")],t.prototype,"scale",void 0),q([I("None")],t.prototype,"align",void 0),t}(va),Pd=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"Text"},q([I("Text")],t.prototype,"type",void 0),q([I("")],t.prototype,"content",void 0),q([re({},$n)],t.prototype,"margin",void 0),t}(va),tb=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"BasicShape"},q([I("Basic")],t.prototype,"type",void 0),q([I("Rectangle")],t.prototype,"shape",void 0),q([I(0)],t.prototype,"cornerRadius",void 0),q([Bt([],z)],t.prototype,"points",void 0),t}(va),DF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"FlowShape"},q([I("Flow")],t.prototype,"type",void 0),q([I("Terminator")],t.prototype,"shape",void 0),t}(va),nT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"BpmnGateway"},q([I("None")],t.prototype,"type",void 0),t}(Ee),sT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"BpmnDataObject"},q([I("None")],t.prototype,"type",void 0),q([I(!1)],t.prototype,"collection",void 0),t}(Ee),$se=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),q([I("None")],t.prototype,"type",void 0),q([I("None")],t.prototype,"loop",void 0),q([I(!1)],t.prototype,"call",void 0),q([I(!1)],t.prototype,"compensation",void 0),t}(Ee),oT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"BpmnEvent"},q([I("Start")],t.prototype,"event",void 0),q([I("None")],t.prototype,"trigger",void 0),t}(Ee),zd=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"BpmnSubEvent"},q([I("None")],t.prototype,"trigger",void 0),q([I("Start")],t.prototype,"event",void 0),q([I("")],t.prototype,"id",void 0),q([re({},z)],t.prototype,"offset",void 0),q([Bt([],Zn)],t.prototype,"annotations",void 0),q([Bt([],Es)],t.prototype,"ports",void 0),q([I()],t.prototype,"width",void 0),q([I()],t.prototype,"height",void 0),q([re({},$n)],t.prototype,"margin",void 0),q([I("Center")],t.prototype,"horizontalAlignment",void 0),q([I("Center")],t.prototype,"verticalAlignment",void 0),q([I(!0)],t.prototype,"visible",void 0),t}(Ee),Zse=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),q([re({id:"success",event:"End",offset:{x:1,y:.5}},zd)],t.prototype,"success",void 0),q([re({id:"failure",event:"Intermediate",trigger:"Error",offset:{x:.25,y:1}},zd)],t.prototype,"failure",void 0),q([re({id:"cancel",event:"Intermediate",trigger:"Cancel",offset:{x:.75,y:1}},zd)],t.prototype,"cancel",void 0),t}(Ee),Jse=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),q([I("None")],t.prototype,"type",void 0),q([I(!1)],t.prototype,"adhoc",void 0),q([I("Default")],t.prototype,"boundary",void 0),q([I(!1)],t.prototype,"compensation",void 0),q([I("None")],t.prototype,"loop",void 0),q([I(!0)],t.prototype,"collapsed",void 0),q([Bt([],zd)],t.prototype,"events",void 0),q([re({},Zse)],t.prototype,"transaction",void 0),q([I(void 0)],t.prototype,"processes",void 0),t}(Ee),aT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"BpmnActivity"},q([I("Task")],t.prototype,"activity",void 0),q([re({},$se)],t.prototype,"task",void 0),q([re({},Jse)],t.prototype,"subProcess",void 0),t}(Ee),om=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return Li(t,n),t.prototype.getClassName=function(){return"BpmnAnnotation"},q([I("")],t.prototype,"text",void 0),q([I("")],t.prototype,"id",void 0),q([I(0)],t.prototype,"angle",void 0),q([I()],t.prototype,"height",void 0),q([I()],t.prototype,"width",void 0),q([I(0)],t.prototype,"length",void 0),t}(Ee),Kse=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),q([I("")],t.prototype,"textAnnotationTarget",void 0),q([I("Auto")],t.prototype,"textAnnotationDirection",void 0),t}(Ee),lT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"BpmnShape"},q([I("Bpmn")],t.prototype,"type",void 0),q([I("Event")],t.prototype,"shape",void 0),q([re({},oT)],t.prototype,"event",void 0),q([re({},nT)],t.prototype,"gateway",void 0),q([re({},sT)],t.prototype,"dataObject",void 0),q([re({},aT)],t.prototype,"activity",void 0),q([re({},om)],t.prototype,"annotation",void 0),q([Bt([],om)],t.prototype,"annotations",void 0),q([re({},Kse)],t.prototype,"textAnnotation",void 0),t}(va),xF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"UmlActivityShape"},q([I("UmlActivity")],t.prototype,"type",void 0),q([I("Action")],t.prototype,"shape",void 0),t}(va),hT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"MethodArguments"},q([I("")],t.prototype,"name",void 0),q([I("")],t.prototype,"type",void 0),q([re({},Yp)],t.prototype,"style",void 0),t}(Ee),rf=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"UmlClassAttribute"},q([I("Public")],t.prototype,"scope",void 0),q([I(!1)],t.prototype,"isSeparator",void 0),q([re({fill:"#F9F9F9",strokeColor:"#CCCCCC"},Al)],t.prototype,"separatorStyle",void 0),t}(hT),am=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"UmlClassMethod"},q([Bt([],hT)],t.prototype,"parameters",void 0),t}(rf),ib=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"UmlClass"},q([I("")],t.prototype,"name",void 0),q([Bt([],rf)],t.prototype,"attributes",void 0),q([Bt([],am)],t.prototype,"methods",void 0),q([re({},Yp)],t.prototype,"style",void 0),t}(Ee),cT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"UmlInterface"},q([I(!1)],t.prototype,"isSeparator",void 0),q([re({fill:"#F9F9F9",strokeColor:"#CCCCCC"},Al)],t.prototype,"separatorStyle",void 0),t}(ib),rb=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"UmlEnumerationMember"},q([I("")],t.prototype,"name",void 0),q([I("")],t.prototype,"value",void 0),q([I(!1)],t.prototype,"isSeparator",void 0),q([re({fill:"#F9F9F9",strokeColor:"#CCCCCC"},Al)],t.prototype,"separatorStyle",void 0),q([re({},Yp)],t.prototype,"style",void 0),t}(Ee),dT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"UmlEnumeration"},q([I("")],t.prototype,"name",void 0),q([Bt([],rb)],t.prototype,"members",void 0),q([re({},Yp)],t.prototype,"style",void 0),t}(Ee),TF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"UmlClassifierShape"},q([I("UmlClassifier")],t.prototype,"type",void 0),q([re({},ib)],t.prototype,"classShape",void 0),q([re({},cT)],t.prototype,"interfaceShape",void 0),q([re({},dT)],t.prototype,"enumerationShape",void 0),q([I("Class")],t.prototype,"classifier",void 0),t}(va),te=function(n){function t(e,i,r,s){var a,o=n.call(this,e,i,r,s)||this;return o.isCanvasUpdate=!1,o.status="None",o.parentId="",o.processId="",o.umlIndex=-1,o.outEdges=[],o.inEdges=[],o.isHeader=!1,o.isLane=!1,o.isPhase=!1,o.children&&o.children.length>0&&((!(a=r).style||!a.style.fill)&&(o.style.fill="transparent"),(!a.style||!a.style.strokeColor)&&(o.style.strokeColor="transparent")),o.shape&&"UmlActivity"===o.shape.type&&qI(r,o),o.shape&&"SwimLane"===o.shape.type&&sF(r,o),o.ports&&o.ports.length&&function rse(n){for(var t=0;t>";t=n;break;case"FinalNode":t=uF(e)}return t}(new Ke,i,this);break;case"Bpmn":if(e.bpmnModule){i=e.bpmnModule.initBPMNContent(i,this,e),this.wrapper.elementActions=this.wrapper.elementActions|Xr.ElementIsGroup;var v=this.shape.activity.subProcess;if(v.processes&&v.processes.length)for(var S=0,b=this.shape.activity.subProcess.processes;S>",margin:{left:10,right:10},id:"class",style:{fontSize:i.style.fontSize,color:i.style.color,fill:i.style.fill,textWrapping:r},offset:{x:.5,y:.3},constraints:Lr.ReadOnly}],constraints:(ie.Default|ie.HideThumbs)&~(ie.Rotate|ie.Drag|ie.Resize),verticalAlignment:"Stretch",horizontalAlignment:"Stretch",style:{fill:t.style.fill,strokeColor:"black"===t.style.strokeColor?"#ffffff00":t.style.strokeColor}},!0);return e.initObject(s),e.nodes.push(s),e.UpdateBlazorDiagramModel(s,"Node"),t.children.push(s.id),function jse(n,t,e,i){if("Enumeration"===n.shape.classifier){var r=e.members;if(r&&r.length){ef(n,t);for(var s="",o=0;o0)for(var o=0;o0&&s.phaseSize&&(i+=s.phaseSize,Yv(n,s.phaseSize)),s.lanes.length>0)for(o=0;o0){var a=0;for(o=0;o0&&"Horizontal"===r.orientation)for(l=0;l0&&(i+=r.phaseSize,o=Qv(r.phaseSize),n.push(o)),a=0;a0&&o.phaseSize){for(var l=0;l0)for(l=0;l0?e.nameTable[this.nodes[0].id].wrapper:e.nameTable[this.connectors[0].id].wrapper,this.annotation.id);i.children.push(s)}else if(this.nodes||this.connectors){for(var o=0;o-1}function zF(n,t,e){n=[];for(var i=0,r=e.length;i0?c.getElementsByTagName("svg")[0].outerHTML:c.getElementsByTagName("g").length>0?c.getElementsByTagName("g")[0].outerHTML:"",s.shape.content=h,n.content=h,c.parentElement.removeChild(c)}l="nodeTemplate"}else a=s,l="annotationTemplate";var f=document.getElementById(n.diagramId).ej2_instances[0];if("string"!=typeof n.content&&"function"!=typeof n.content||n.isTemplate)if(n.isTemplate){if(v=void 0,v=f.isReact?n.getNodeTemplate()($(e),f,l+"_"+("nodeTemplate"===l?e.id:n.nodeId+e.id),void 0,void 0,!1,i):f.isVue||f.isVue3?n.getNodeTemplate()?n.getNodeTemplate()($(e),f,l+"_"+("nodeTemplate"===l?e.id:n.nodeId+e.id),void 0,void 0,!1,i):(v=ii("nodeTemplate"===l?f.nodeTemplate:f.annotationTemplate))($(e),f,l+"_"+("nodeTemplate"===l?e.id:n.nodeId+e.id),void 0,void 0,!1,i):n.getNodeTemplate()($(e),f,l+"_"+("nodeTemplate"===l?e.id:n.nodeId+e.id),void 0,void 0,!1))for(var M=0;M=1&&0===n.x&&("Clip"===i.textOverflow||"Ellipsis"===i.textOverflow)&&("Wrap"===i.textWrapping||"WrapWithOverflow"===i.textWrapping)&&(n.x=t[e-1]?t[e-1].x:-n.width/2),n.x}function BF(n,t,e,i){return e&&!t.template||t.template&&"function"==typeof t.template&&i.isReact?(n.isTemplate=!0,n.template=n.content=Rh(n,!0,t)):n.content=t.template,n}function Qe(){for(var e,t="",i=0;i<5;i++){if(typeof window<"u"&&"crypto"in window&&"getRandomValues"in crypto){var r=new Uint16Array(1);e=(window.msCrypto||window.crypto).getRandomValues(r)[0]%60}else e=Math.floor(61*Math.random());0===i&&e<10?i--:t+="0123456789ABCDEFGHIJKLMNOPQRSTUVWXTZabcdefghiklmnopqrstuvwxyz".substring(e,e+1)}return t}function FF(n){if(n)try{return"function"!=typeof n&&document.querySelectorAll(n).length?ii(document.querySelector(n).innerHTML.trim()):ii(n)}catch{return ii(n)}}function En(n){new Ne;var e=n.offsetY-n.actualSize.height*n.pivot.y,i=n.offsetY+n.actualSize.height*(1-n.pivot.y),r=n.offsetX-n.actualSize.width*n.pivot.x,s=n.offsetX+n.actualSize.width*(1-n.pivot.x);return Ne.toBounds([{x:r,y:e},{x:s,y:e},{x:r,y:i},{x:s,y:i}])}function yr(n){var t=new Ne,e=En(n),i=e.middleLeft,r=e.topCenter,s=e.bottomCenter,o=e.middleRight,a=e.topLeft,l=e.topRight,h=e.bottomLeft,c=e.bottomRight;if(n.corners={topLeft:a,topCenter:r,topRight:l,middleLeft:i,middleRight:o,bottomLeft:h,bottomCenter:s,bottomRight:c},0!==n.rotateAngle||0!==n.parentTransform){var d=Hi();qi(d,n.rotateAngle+n.parentTransform,n.offsetX,n.offsetY),n.corners.topLeft=a=Je(d,a),n.corners.topCenter=r=Je(d,r),n.corners.topRight=l=Je(d,l),n.corners.middleLeft=i=Je(d,i),n.corners.middleRight=o=Je(d,o),n.corners.bottomLeft=h=Je(d,h),n.corners.bottomCenter=s=Je(d,s),n.corners.bottomRight=c=Je(d,c)}return t=Ne.toBounds([a,l,h,c]),n.corners.left=t.left,n.corners.right=t.right,n.corners.top=t.top,n.corners.bottom=t.bottom,n.corners.center=t.center,n.corners.width=t.width,n.corners.height=t.height,t}function $(n,t,e,i){var r={},s="properties";if(n){e=n.propName;var l=[],h=[];if((l=l.concat(Object.keys(n[""+s]||n))).push("version"),e){var c=Zi(t);h=c?c(e):[],l=l.concat(h)}for(var d=function Soe(n){switch(n){case"nodes":case"children":return["inEdges","outEdges","parentId","processId","nodeId","umlIndex","isPhase","isLane"];case"connectors":return["parentId"];case"annotation":case"annotations":return["nodeId"];case"shape":return["hasHeader"];case"layers":return["objectZIndex"]}return[]}(e),u=0,p=l=l.concat(d);u0&&(e=r),r=Math.floor(boe(e,i)),s=Bc(o+=n.substr(e,r),t)}while(s<=t.width);for(o=o.substr(0,e),a=e;a=t.width){n=n.substr(0,o.length-1);break}return"Ellipsis"===t.textOverflow?(n=n.substr(0,n.length-3),n+="..."):n=n.substr(0,n.length),n}function yT(n,t){if("NoWrap"===t&&"PreserveAll"===n)return"pre";var e="";switch(n){case"CollapseAll":e="nowrap";break;case"CollapseSpace":e="pre-line";break;case"PreserveAll":e="pre-wrap"}return e}function ST(n,t){var e=Hi();qi(e,t,0,0);var i=Je(e,{x:0,y:0}),r=Je(e,{x:n.width,y:0}),s=Je(e,{x:0,y:n.height}),o=Je(e,{x:n.width,y:n.height}),a=Math.min(i.x,r.x,s.x,o.x),l=Math.min(i.y,r.y,s.y,o.y),h=Math.max(i.x,r.x,s.x,o.x),c=Math.max(i.y,r.y,s.y,o.y);return new me(h-a,c-l)}function xs(n,t,e,i){if(0!==n){var r=Hi();return qi(r,n,t,e),Je(r,i)}return i}function Zi(n){return void 0!==n&&"string"==typeof n&&(n=Y(n,window)),n}var bo=function(){function n(){}return n.getContext=function(t){return t.getContext("2d")},n.setCanvasSize=function(t,e,i){t&&(t.setAttribute("width",e.toString()),t.setAttribute("height",i.toString()))},n.prototype.renderGradient=function(t,e,i,r){var s,o,a;if("None"!==t.gradient.type){for(var l=0;l0?(w=0===S.r1?e.arc[parseInt(r.toString(),10)].r1:S.r1,C=0===S.r2?e.arc[parseInt(r.toString(),10)].r2:S.r2,r++):(w=S.r1,C=S.r2);var D=S.angle*(Math.PI/180),A=S.largeArc,x=S.sweep,R={x:u,y:p},L={x:Math.cos(D)*(M.x-R.x)/2+Math.sin(D)*(M.y-R.y)/2,y:-Math.sin(D)*(M.x-R.x)/2+Math.cos(D)*(M.y-R.y)/2},O=Math.pow(L.x,2)/Math.pow(w,2)+Math.pow(L.y,2)/Math.pow(C,2);O>1&&(w*=Math.sqrt(O),C*=Math.sqrt(O));var N=Math.pow(C,2)*Math.pow(L.x,2),T=(A===x?-1:1)*Math.sqrt((Math.pow(w,2)*Math.pow(C,2)-Math.pow(w,2)*Math.pow(L.y,2)-N)/(Math.pow(w,2)*Math.pow(L.y,2)+Math.pow(C,2)*Math.pow(L.x,2)));isNaN(T)&&(T=0);var P={x:T*w*L.y/C,y:T*-C*L.x/w},_={x:(M.x+R.x)/2+Math.cos(D)*P.x-Math.sin(D)*P.y,y:(M.y+R.y)/2+Math.sin(D)*P.x+Math.cos(D)*P.y},B=this.a([1,0],[(L.x-P.x)/w,(L.y-P.y)/C]),j=[(L.x-P.x)/w,(L.y-P.y)/C],Q=[(-L.x-P.x)/w,(-L.y-P.y)/C],oe=this.a(j,Q);this.r(j,Q)<=-1&&(oe=Math.PI),this.r(j,Q)>=1&&(oe=0);var pe=B+oe/2*(x?1:-1);if(Math.cos(pe),Math.sin(pe),S.centp=_,S.xAxisRotation=D,S.rx=w,S.ry=C,S.a1=B,S.ad=oe,S.sweep=x,null!=s){var De=w>C?w:C,xe=w>C?1:w/C,Ie=w>C?C/w:1;s.save(),s.translate(_.x,_.y),s.rotate(D),s.scale(xe,Ie),s.arc(0,0,De,B,B+oe,!x),s.scale(1/xe,1/Ie),s.rotate(-D),s.translate(-_.x,-_.y),s.restore()}break;case"Z":case"z":s.closePath(),u=o,p=a}o=u,a=p}}},n.prototype.drawText=function(t,e,i,r,s,o,a){if(e.content&&!0===e.visible){var l=n.getContext(t);l.save(),this.setStyle(t,e),o&&(e.fontSize*=o),this.rotateContext(t,e.angle,e.x+e.width*e.pivotX,e.y+e.height*e.pivotY),this.setFontStyle(t,e);var u,d=0;u=e.childNodes;var p=e.wrapBounds;if(l.fillStyle=e.color,p){var f=this.labelAlign(e,p,u);for(d=0;de.width&&"Wrap"!==e.textOverflow&&"NoWrap"===e.textWrapping&&(g.text=UF(g.text,e)),"Clip"!==e.textOverflow&&"Ellipsis"!==e.textOverflow||"Wrap"!==e.textWrapping?l.fillText(g.text,v,y):ya.actualSize.height+a.bounds.y&&(g.text=g.text.slice(0,g.text.length-3),g.text=g.text.concat("...")),l.fillText(g.text,v,y)),"Underline"===e.textDecoration||"Overline"===e.textDecoration||"LineThrough"===e.textDecoration){var M=v,w=void 0,D=v+l.measureText(g.text).width,A=void 0;switch(e.textDecoration){case"Underline":w=y+2,A=y+2;break;case"Overline":w=f.y+g.dy*d,A=f.y+g.dy*d;break;case"LineThrough":w=(y+f.y+g.dy*d)/2+2,A=(y+f.y+g.dy*d)/2+2}l.beginPath(),l.moveTo(M,w),l.lineTo(D,A),l.strokeStyle=e.color,l.lineWidth=.08*e.fontSize,l.globalAlpha=e.opacity,l.stroke()}}}l.restore()}},n.prototype.loadImage=function(t,e,i,r,s){this.rotateContext(i,e.angle,r,s);var o=new Image;o.src=e.source,this.image(t,o,e.x,e.y,e.width,e.height,e)},n.prototype.drawImage=function(t,e,i,r){var s=this;if(e.visible){var o=n.getContext(t);o.save();var a=e.x+e.width*e.pivotX,l=e.y+e.height*e.pivotY,h=new Image;h.src=e.source,o.canvas.id.split("_"),r?h.onload=function(){s.loadImage(o,e,t,a,l)}:this.loadImage(o,e,t,a,l),o.restore()}},n.prototype.image=function(t,e,i,r,s,o,a){t.beginPath();var l=e.width,h=e.height,c=s,d=o,u=0,p=0;if(a&&"None"!==a.alignment){var f=a.alignment.toLowerCase().substr(1,3),g=a.alignment.toLowerCase().substr(5,3);if("Slice"===a.scale){var v=function(){u=c,p=h*c/l},y=function(){u=l*d/h,p=d};c>d?(v(),d>p&&y()):c===d?l>h?y():v():(y(),c>u&&v());var S=this.getSliceOffset(f,u,c,l),b=this.getSliceOffset(g,p,d,h),M=l-S,w=h-b,C=u-S*(u/l),D=p-b*(p/h),A=Tt("canvas",{width:s.toString(),height:o.toString()});A.getContext("2d").drawImage(e,S,b,M,w,0,0,C,D),t.drawImage(A,i,r,s,o)}else if("Meet"===a.scale){var R=h/l,L=d/c;p=L>R?c*R:d,i+=this.getMeetOffset(f,u=L>R?c:d/R,c),r+=this.getMeetOffset(g,p,d),t.drawImage(e,0,0,l,h,i,r,u,p)}else t.drawImage(e,i,r,s,o)}else if("None"!==a.flip){var O=1,N=1;("Horizontal"===a.flip||"Both"===a.flip)&&(i=-i,s=-s,O=-1),("Vertical"===a.flip||"Both"===a.flip)&&(r=-r,o=-o,N=-1),t.scale(O,N),t.drawImage(e,i,r,s,o)}else t.drawImage(e,i,r,s,o);t.closePath()},n.prototype.getSliceOffset=function(t,e,i,r){switch(t){case"min":default:return 0;case"mid":return(e-i)/2*r/e;case"max":return(e-i)*r/e}},n.prototype.getMeetOffset=function(t,e,i){var r=Math.max(e,i),s=Math.min(e,i);switch(t){case"min":default:return 0;case"mid":return(r-s)/2;case"max":return r-s}},n.prototype.m=function(t){return Math.sqrt(Math.pow(t[0],2)+Math.pow(t[1],2))},n.prototype.r=function(t,e){return(t[0]*e[0]+t[1]*e[1])/(this.m(t)*this.m(e))},n.prototype.a=function(t,e){return(t[0]*e[1]t.width&&("Ellipsis"===t.textOverflow||"Clip"===t.textOverflow)&&"NoWrap"===t.textWrapping?0:.5*t.width:"right"===t.textAlign&&(c=1*t.width),s.x=t.x+c+(e?e.x:0),s.y=a+d-r.height/2,s},n}(),lb=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Vi=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},woe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return lb(t,n),Vi([I("")],t.prototype,"source",void 0),Vi([I("transparent")],t.prototype,"color",void 0),Vi([I("None")],t.prototype,"scale",void 0),Vi([I("None")],t.prototype,"align",void 0),t}(Ee),Coe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return lb(t,n),Vi([I("Page")],t.prototype,"mode",void 0),Vi([I("PageSettings")],t.prototype,"region",void 0),Vi([re({top:25,bottom:25,left:25,right:25},$n)],t.prototype,"margin",void 0),Vi([I(!1)],t.prototype,"canZoomIn",void 0),Vi([I(void 0)],t.prototype,"customBounds",void 0),Vi([I(!1)],t.prototype,"canFit",void 0),t}(Ee),Eoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return lb(t,n),Vi([I(null)],t.prototype,"width",void 0),Vi([I(null)],t.prototype,"height",void 0),Vi([re({},$n)],t.prototype,"margin",void 0),Vi([I("Landscape")],t.prototype,"orientation",void 0),Vi([I("Infinity")],t.prototype,"boundaryConstraints",void 0),Vi([re({},woe)],t.prototype,"background",void 0),Vi([I(!1)],t.prototype,"multiplePage",void 0),Vi([I(!1)],t.prototype,"showPageBreaks",void 0),Vi([re({},Coe)],t.prototype,"fitOptions",void 0),t}(Ee),Doe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return lb(t,n),Vi([I(0)],t.prototype,"horizontalOffset",void 0),Vi([I(0)],t.prototype,"verticalOffset",void 0),Vi([I(1)],t.prototype,"currentZoom",void 0),Vi([I(0)],t.prototype,"viewPortWidth",void 0),Vi([I(0)],t.prototype,"viewPortHeight",void 0),Vi([I(.2)],t.prototype,"minZoom",void 0),Vi([I(30)],t.prototype,"maxZoom",void 0),Vi([I("Diagram")],t.prototype,"scrollLimit",void 0),Vi([I()],t.prototype,"scrollableArea",void 0),Vi([I(!1)],t.prototype,"canAutoScroll",void 0),Vi([I(100)],t.prototype,"autoScrollFrequency",void 0),Vi([re({left:15,right:15,top:15,bottom:15},$n)],t.prototype,"autoScrollBorder",void 0),Vi([re({left:0,right:0,top:0,bottom:0},$n)],t.prototype,"padding",void 0),Vi([I(.2)],t.prototype,"zoomFactor",void 0),t}(Ee),xoe=function(){function n(){this.services={}}return n.prototype.register=function(t,e){this.services[""+t]=e},n.prototype.getService=function(t){return this.services[""+t]},n}(),jF=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),ma=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},VF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return jF(t,n),ma([I("lightgray")],t.prototype,"lineColor",void 0),ma([I("")],t.prototype,"lineDashArray",void 0),ma([I([1.25,18.75,.25,19.75,.25,19.75,.25,19.75,.25,19.75])],t.prototype,"lineIntervals",void 0),ma([I([1,19,.5,19.5,.5,19.5,.5,19.5,.5,19.5])],t.prototype,"dotIntervals",void 0),ma([I([20])],t.prototype,"snapIntervals",void 0),t}(Ee),Toe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return jF(t,n),ma([re({},VF)],t.prototype,"horizontalGridlines",void 0),ma([re({},VF)],t.prototype,"verticalGridlines",void 0),ma([I(Kt.All)],t.prototype,"constraints",void 0),ma([I(5)],t.prototype,"snapAngle",void 0),ma([I("Lines")],t.prototype,"gridType",void 0),ma([I(5)],t.prototype,"snapObjectDistance",void 0),ma([I("#07EDE1")],t.prototype,"snapLineColor",void 0),t}(Ee),WF=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Ja=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},YF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return WF(t,n),Ja([I(5)],t.prototype,"interval",void 0),Ja([I(100)],t.prototype,"segmentWidth",void 0),Ja([I("Horizontal")],t.prototype,"orientation",void 0),Ja([I("RightOrBottom")],t.prototype,"tickAlignment",void 0),Ja([I("red")],t.prototype,"markerColor",void 0),Ja([I(25)],t.prototype,"thickness",void 0),Ja([I(null)],t.prototype,"arrangeTick",void 0),t}(Ee),Aoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return WF(t,n),Ja([I(!1)],t.prototype,"showRulers",void 0),Ja([I(!0)],t.prototype,"dynamicGrid",void 0),Ja([re({orientation:"Horizontal"},YF)],t.prototype,"horizontalRuler",void 0),Ja([re({orientation:"Vertical"},YF)],t.prototype,"verticalRuler",void 0),t}(Ee),Loe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),QF=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Noe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Loe(t,n),QF([I("")],t.prototype,"property",void 0),QF([I("")],t.prototype,"field",void 0),t}(Ee),IT=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),ln=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},GF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return IT(t,n),ln([I("")],t.prototype,"read",void 0),ln([I("")],t.prototype,"create",void 0),ln([I("")],t.prototype,"update",void 0),ln([I("")],t.prototype,"destroy",void 0),ln([I()],t.prototype,"customFields",void 0),t}(Ee),Ooe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return IT(t,n),ln([I("")],t.prototype,"id",void 0),ln([I("")],t.prototype,"sourceID",void 0),ln([I("")],t.prototype,"targetID",void 0),ln([I(null)],t.prototype,"sourcePointX",void 0),ln([I(null)],t.prototype,"sourcePointY",void 0),ln([I(null)],t.prototype,"targetPointX",void 0),ln([I(null)],t.prototype,"targetPointY",void 0),ln([I(null)],t.prototype,"dataManager",void 0),ln([re({},GF)],t.prototype,"crudAction",void 0),t}(Ee),koe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return IT(t,n),ln([I("")],t.prototype,"id",void 0),ln([I(null)],t.prototype,"dataManager",void 0),ln([I(null)],t.prototype,"dataSource",void 0),ln([I("")],t.prototype,"root",void 0),ln([I("")],t.prototype,"parentId",void 0),ln([I()],t.prototype,"doBinding",void 0),ln([Bt([],Noe)],t.prototype,"dataMapSettings",void 0),ln([re({},GF)],t.prototype,"crudAction",void 0),ln([re({},Ooe)],t.prototype,"connectionDataSource",void 0),t}(Ee),XF=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Cr=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Poe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return XF(t,n),Cr([I("LeftInFlow")],t.prototype,"yesBranchDirection",void 0),Cr([I("RightInFlow")],t.prototype,"noBranchDirection",void 0),Cr([I(["Yes","True"])],t.prototype,"yesBranchValues",void 0),Cr([I(["No","False"])],t.prototype,"noBranchValues",void 0),t}(Ee),zoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return XF(t,n),Cr([I("")],t.prototype,"fixedNode",void 0),Cr([I(30)],t.prototype,"horizontalSpacing",void 0),Cr([I("SamePoint")],t.prototype,"connectionPointOrigin",void 0),Cr([I("Nonlinear")],t.prototype,"arrangement",void 0),Cr([I(30)],t.prototype,"verticalSpacing",void 0),Cr([I(30)],t.prototype,"maxIteration",void 0),Cr([I(40)],t.prototype,"springFactor",void 0),Cr([I(50)],t.prototype,"springLength",void 0),Cr([re({left:50,top:50,right:0,bottom:0},$n)],t.prototype,"margin",void 0),Cr([I("Auto")],t.prototype,"horizontalAlignment",void 0),Cr([I("Auto")],t.prototype,"verticalAlignment",void 0),Cr([I("TopToBottom")],t.prototype,"orientation",void 0),Cr([I("Auto")],t.prototype,"connectionDirection",void 0),Cr([I("Default")],t.prototype,"connectorSegments",void 0),Cr([I("None")],t.prototype,"type",void 0),Cr([I()],t.prototype,"getLayoutInfo",void 0),Cr([I()],t.prototype,"layoutInfo",void 0),Cr([I()],t.prototype,"getBranch",void 0),Cr([I()],t.prototype,"bounds",void 0),Cr([I(!0)],t.prototype,"enableAnimation",void 0),Cr([I(!1)],t.prototype,"enableRouting",void 0),Cr([I("")],t.prototype,"root",void 0),Cr([re({},Poe)],t.prototype,"flowchartLayoutSettings",void 0),t}(Ee),Roe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),qF=function(n){function t(e,i){var r=n.call(this,e,!0)||this;return r.oldValue=null,r.endPoint=i,r}return Roe(t,n),t.prototype.mouseDown=function(e){var i,r=!0;if(e.source&&e.source.connectors&&(i=e.source.connectors[0]),e.info&&e.actualObject&&(r=e.info.ctrlKey&&"Orthogonal"!==e.actualObject.type),i&&r){this.inAction=!0,this.undoElement=$(e.source),n.prototype.mouseDown.call(this,e);for(var s=0;s0)1!==s&&this.removePrevSegment(i,s);else if(a){var l=z.distancePoints(a.points[0],a.points[1]);Math.abs(a.length||0===a.length?a.length:l)<=5&&this.removeNextSegment(i,s)}this.commandHandler.updateEndPoint(i,r),i.selectedSegmentIndex=0}if(this.undoElement){var c=$(e.source);this.commandHandler.addHistoryEntry({type:"SegmentChanged",redoObject:c,undoObject:this.undoElement,category:"Internal"})}if(i.isBezierEditing&&(i.isBezierEditing=!1),this.prevPosition!==this.startPosition){var u={source:i,state:"Completed",oldValue:this.oldValue,newValue:$(this.selectedSegment),cancel:!1,segment:this.selectedSegment};this.commandHandler.triggerEvent(Ce.segmentChange,u)}n.prototype.mouseUp.call(this,e)},t.prototype.removePrevSegment=function(e,i){var r=e.segments[i-2],s=e.segments[i+1];if(s&&!((s.length||0===s.length?s.length:z.distancePoints(s.points[0],s.points[1]))<=5)){var a=e.segments.slice(i-1,i+1),l={element:e,removeSegments:a,type:"Removal",cancel:!1};if(this.commandHandler.triggerEvent(Ce.segmentCollectionChange,l),!l.cancel){var h=e.segments[i+1];e.segments.splice(i-1,2);var c=this.selectedSegment;"Left"===c.direction||"Right"===c.direction?(r.points[r.points.length-1].x=h.points[0].x,h.points[0].y=r.points[r.points.length-1].y):(r.points[r.points.length-1].y=h.points[0].y,h.points[0].x=r.points[r.points.length-1].x),(c.length||0===c.length)&&this.findSegmentDirection(r),this.findSegmentDirection(h)}}},t.prototype.findSegmentDirection=function(e){e.direction&&(e.length||0===e.length)&&(e.length=z.distancePoints(e.points[0],e.points[e.points.length-1]),e.direction=z.direction(e.points[0],e.points[e.points.length-1]))},t.prototype.removeNextSegment=function(e,i){var l,h,r=this.selectedSegment,s=e.segments[i-1],o=e.segments[i+2],a=e.segments[i+1];if(a.length||0===a.length?(l=e.segments.slice(i,2),h={element:e,removeSegments:l,type:"Removal",cancel:!1},this.commandHandler.triggerEvent(Ce.segmentCollectionChange,h={element:e,removeSegments:l,type:"Removal",cancel:!1}),h.cancel||(e.segments.splice(i,2),"Top"===r.direction||"Bottom"===r.direction?(o.points[0].y=r.points[0].y,s.points[s.points.length-1].x=o.points[0].x):(o.points[0].x=r.points[0].x,s.points[s.points.length-1].y=o.points[0].y))):(l=e.segments.slice(i+1,1),this.commandHandler.triggerEvent(Ce.segmentCollectionChange,h={element:e,removeSegments:l,type:"Removal",cancel:!1}),h.cancel||(e.segments.splice(i+1,1),"Top"===r.direction||"Bottom"===r.direction?s.points[s.points.length-1].x=a.points[a.points.length-1].x:s.points[s.points.length-1].y=a.points[a.points.length-1].y,this.findSegmentDirection(s),r.length=r.direction=null)),s&&o&&!h.cancel&&(s.length=z.distancePoints(s.points[0],o.points[0]),s.direction=z.direction(s.points[0],o.points[0]),o.length||0===o.length)){o.length=z.distancePoints(s.points[s.points.length-1],o.points[o.points.length-1]);var c=s.points,d=o.points;o.direction=z.direction(c[c.length-1],d[d.length-1])}},t.prototype.addOrRemoveSegment=function(e,i,r){for(var s,o,a=[],l={segments:e.segments},h=0;h0?"Bottom":"Top":r>0?"Right":"Left",length:i.points[0].x===i.points[1].x?s:r},!0)),l.push(new bi(e,"segments",{type:"Orthogonal",direction:c,length:h/2},!0));var p={element:e,addSegments:l,type:"Addition",cancel:!1};return this.commandHandler.triggerEvent(Ce.segmentCollectionChange,p),p.cancel||(e.segments=l.concat(e.segments),a=o+2),a},t.prototype.insertFirstSegment=function(e,i,r,s,o){var a,l,d,u,h=[];if(e.sourcePortID&&i.length&&e.segments[0].points.length>2)for(var p=void 0,f=0;f0?"Bottom":"Top":r>0?"Right":"Left"),p=u,h.push(u)}else h.push(new bi(e,"segments",{type:"Orthogonal",direction:i.direction,length:i.length/3},!0)),"Bottom"===i.direction||"Top"===i.direction?(l=Math.abs(r),a=r>0?"Right":"Left"):(l=Math.abs(s),a=s>0?"Bottom":"Top"),u=new bi(e,"segments",{type:"Orthogonal",direction:a,length:l},!0),h.push(u);var y={element:e,addSegments:h,type:"Addition",cancel:!1};if(this.commandHandler.triggerEvent(Ce.segmentCollectionChange,y),!y.cancel){if(e.sourcePortID&&i.length&&e.segments[0].points.length>2)e.segments.splice(0,1),d=1;else{var S=e.segments[1];S&&S.length&&(S.length=a!==S.direction?S.length+l:S.length-l),d=2,i.length=2*i.length/3}e.segments=h.concat(e.segments)}return d},t.prototype.updateAdjacentSegments=function(e,i,r,s){var o=e.segments[parseInt(i.toString(),10)],a=o.points[o.points.length-1],h=!0;"Orthogonal"===o.type&&(o.points[0]=o.points[0],o.points[o.points.length-1]=a,e.segments[i-1]&&(h=this.updatePreviousSegment(r,s,e,i)),e.segments.length-1>i&&h&&this.updateNextSegment(e,o,e.segments[i+1],r,s))},t.prototype.addTerminalSegment=function(e,i,r,s,o){var l,h,c,d,a=e.segments.indexOf(i),u=[],p=e.segments.pop(),f=e.segments[e.segments.length-1];l=f&&"Orthogonal"===f.type?f:null;for(var g=0;g0&&"Left"===o.direction?c.middleLeft:c.middleRight,o.length>c.width/2?Math.abs(a.length)0&&"Top"===o.direction?c.topCenter:c.bottomCenter,o.length>c.height/2?Math.abs(a.length)1)for(var a=0,l=this.diagram.views;a0)for(var e=t===Ce.onUserHandleMouseLeave?this.previousAction:this.action,i={element:void 0},r=0;r0)for(var r={element:void 0},s=void 0,o=void 0,a=0;a-1&&(o=s,this.previousTarget=i,this.targetItem=e),o===e.fixedUserHandles[parseInt(a.toString(),10)].id&&(r.element=e.fixedUserHandles[parseInt(a.toString(),10)],this.userHandle(t,a,r,e))},n.prototype.mouseDown=function(t){if(!0!==this.inAction||!(this.tool instanceof UI||this.tool instanceof pa)){this.focus=!0;var e=t.touches,i=!!document.getElementsByClassName("e-dragclone")[0];if(this.isMouseOnScrollBar(t)&&!i)return this.isScrolling=!0,void t.preventDefault();if(this.checkFixedUserHandleEvent(Ce.onFixedUserHandleMouseDown,this.targetItem,this.previousTarget),this.checkUserHandleEvent(Ce.onUserHandleMouseDown),!this.checkEditBoxAsTarget(t)&&_v(this.diagram)||Lc(this.diagram)&&!OI(this.diagram))if(("Select"===this.action||"Drag"===this.action)&&this.diagram.updatePortVisibility(this.hoverElement,hi.Hover,!0),!(this.tool instanceof Oh||this.tool instanceof kh)||2!==t.button&&2!==t.buttons)if(!0===this.inAction&&!0===this.isMouseDown&&(this.tool instanceof Oh||this.tool instanceof kh))this.isMouseDown=!0,this.eventArgs={},this.getMouseEventArgs(this.currentPosition,this.eventArgs),this.eventArgs.position=this.currentPosition,this.tool.mouseDown(this.eventArgs);else{this.isMouseDown=!0,this.currentPosition=this.prevPosition=this.getMousePosition(t),this.eventArgs={},this.diagram.textEditing&&!this.isMouseOnScrollBar(t)&&(this.diagram.endEdit(),this.diagram.textEditing=!1,"Canvas"===this.diagram.mode&&1!==this.diagram.scroller.currentZoom&&this.diagram.refreshDiagramLayer());var s=this.getTargetElement();this.action=this.diagram.findActionToBeDone(s.obj,s.sourceElement,this.currentPosition,s.target);var o=this.isMetaKey(t);o&&t.shiftKey&&this.diagram.connectorEditingToolModule?this.action="SegmentEnd":(o||t.shiftKey)&&(Bv(this.diagram)||Fv(this.diagram))&&(this.action="Select"),this.tool=this.diagram.getTool(this.action),this.tool||(this.action="Select",this.tool=this.diagram.getTool(this.action)),this.getMouseEventArgs(this.currentPosition,this.eventArgs),(o||t.shiftKey)&&(this.eventArgs.info=o&&t.shiftKey?{ctrlKey:o,shiftKey:t.shiftKey}:{ctrlKey:!0}),this.eventArgs.position=this.currentPosition;var l=this.diagram.selectedItems.nodes;if(this.tool.mouseDown(this.eventArgs),this.diagram.selectedItems.canToggleSelection&&l&&this.diagram.selectedItems.nodes&&this.tool instanceof ua)for(var h=0;h=2&&(this.touchStartList=zF(this.touchStartList,0,e)),e||t.preventDefault())}else this.inAction=!1,this.tool.mouseUp(this.eventArgs);!this.isForeignObject(t.target)&&!this.isForeignObject(t.target,!0)&&!e&&t.preventDefault()}},n.prototype.mouseMoveExtend=function(t,e){(this.tool instanceof Oh||this.tool instanceof kh)&&this.tool.mouseMove(this.eventArgs),this.diagram.scrollSettings.canAutoScroll?this.checkAutoScroll(t):this.blocked||this.tool.mouseMove(this.eventArgs),this.eventArgs.target&&(this.hoverElement=this.eventArgs.target);var i=!((this.eventArgs.target instanceof te||this.eventArgs.target instanceof de)&&(e instanceof te||e instanceof de));this.tool instanceof Od&&this.diagram.updatePortVisibility(this.hoverElement instanceof te||this.hoverElement instanceof de?this.hoverElement:this.hoverNode,hi.Connect|hi.Hover,i),this.hoverElement instanceof te&&this.hoverNode instanceof te&&this.hoverNode&&this.hoverNode.id!==this.hoverElement.id&&this.diagram.updatePortVisibility(this.hoverNode,hi.Connect|hi.Hover,!0),this.hoverElement instanceof de&&this.hoverElement.ports.length>0&&this.diagram.updatePortVisibility(this.hoverElement,hi.Connect|hi.Hover,!0),this.previousElement instanceof te&&this.hoverElement&&this.previousElement.id!==this.hoverElement.id&&this.diagram.updatePortVisibility(this.previousElement,hi.Connect|hi.Hover,!0),this.previousElement=this.hoverElement,""!==this.diagram.tooltip.content&&(this.hoverElement=null),this.hoverNode=i?null:e},n.prototype.checkAction=function(t){if("LabelSelect"===this.action&&this.eventArgs.sourceWrapper&&(this.eventArgs.sourceWrapper instanceof ni||this.eventArgs.sourceWrapper instanceof Jn)){var e=this.commandHandler.findTarget(this.eventArgs.sourceWrapper,this.eventArgs.source);!_r(this.diagram,e,!1,this.eventArgs.sourceWrapper)&&to(e)&&(this.action="LabelDrag",this.tool=this.getTool(this.action),this.tool.mouseDown(this.initialEventArgs))}else to(t)&&Dd(t)&&this.initialEventArgs&&this.initialEventArgs.source&&"Select"===this.action&&(!_r(this.diagram,this.eventArgs.source,!1)&&this.eventArgs.source instanceof si&&this.getMouseEventArgs(this.currentPosition,this.eventArgs),(!(t instanceof de)||t instanceof de&&!(wr(this.currentPosition,t.sourcePoint,t.hitPadding)||wr(this.currentPosition,t.targetPoint,t.hitPadding)))&&(this.action="Drag"),this.tool=this.getTool(this.action),this.tool.mouseDown(this.initialEventArgs))},n.prototype.isSwimlaneElements=function(t){return!(t&&(t.isLane||t.isPhase||t.isHeader))},n.prototype.mouseMove=function(t,e){if(this.focus=!0,this.isScrolling)t.preventDefault();else if(_v(this.diagram)||Lc(this.diagram)&&!OI(this.diagram)){this.currentPosition=this.getMousePosition(t);var i=this.diagram.findObjectsUnderMouse(this.currentPosition),r=this.diagram.findObjectUnderMouse(i,this.action,this.inAction);!function Yne(n,t){n.rulerSettings.showRulers&&(n.hRuler.drawRulerMarker(n.hRuler.element,t,n.scroller.horizontalOffset),n.vRuler.drawRulerMarker(n.vRuler.element,t,n.scroller.verticalOffset))}(this.diagram,this.currentPosition);var s=!1,o=void 0;if("touchmove"===t.type&&(e=t.touches)&&e.length>1&&(this.touchMoveList=zF(this.touchMoveList,0,e),"PinchZoom"!==this.action&&(s=!0)),!1===z.equals(this.currentPosition,this.prevPosition)||this.inAction){if(!1===this.isMouseDown||s){this.eventArgs={};var a=null,l=void 0;if(null!==r){if((a=this.diagram.findElementUnderMouse(r,this.currentPosition,this.diagram))&&(l=this.commandHandler.findTarget(a,r)),(l instanceof Zn||l instanceof Nr)&&(l.tooltip&&""!==l.tooltip.content||(l=r)),l!==this.hoverElement){var h=this.getContent();this.hoverElement&&"Auto"===this.hoverElement.tooltip.openOn&&""!==h&&this.elementLeave(),this.diagram.updatePortVisibility(this.hoverElement,hi.Hover,!0),r instanceof te&&(this.hoverNode=r);var c=!0;!this.isSwimlaneElements(r)&&this.hoverElement&&this.isSwimlaneElements(this.hoverElement)&&(c=!1),this.hoverElement=c?r:this.hoverElement;var d,u=void 0;(d=this.diagram.findElementUnderMouse(r,this.currentPosition,this.diagram))instanceof Ke&&((u=this.commandHandler.findTarget(d,r))instanceof Es||u instanceof xc)&&this.hoverElement.constraints&ri.ToolTip&&(this.hoverElement=u);var p=void 0;d instanceof ni&&((p=this.commandHandler.findTarget(d,r))instanceof Zn||p instanceof Nr)&&p.constraints&Lr.Tooltip&&(this.hoverElement=p),c?this.elementEnter(this.currentPosition,!1):this.hoverElement=r}else this.hoverElement&&this.hoverElement===l&&this.hoverElement.tooltip.content&&void 0!==this.diagram.tooltipObject&&"Mouse"===this.hoverElement.tooltip.relativeMode&&this.setTooltipOffset(this.currentPosition);a&&(o=this.commandHandler.findTarget(a,r))}this.action=this.diagram.findActionToBeDone(r,a,this.currentPosition,o),this.checkFixedUserHandleEvent(Ce.onFixedUserHandleMouseEnter,r,a),this.checkUserHandleEvent(Ce.onUserHandleMouseEnter),this.checkPreviousAction(),this.getMouseEventArgs(this.currentPosition,this.eventArgs),this.tool=this.getTool(this.action),this.mouseEvents(),this.tool instanceof pa||this.tool instanceof kh||this.tool instanceof Oh?this.tool.mouseMove(this.eventArgs):e&&this.tool instanceof $v&&this.tool.mouseDown(this.eventArgs),this.updateCursor(),this.renderUmlHighLighter(this.eventArgs);var f=!1;this.hoverElement&&!(this.tool instanceof $v)&&r instanceof te&&this.isSwimlaneElements(r)&&(0===this.diagram.selectedItems.nodes.length||!_r(this.diagram,this.hoverElement))||this.hoverElement instanceof de||(f=!0),this.hoverElement&&!(this.tool instanceof $v)&&r instanceof de&&(0===this.diagram.selectedItems.connectors.length||!_r(this.diagram,this.hoverElement))||this.hoverElement instanceof te||(f=!0),this.diagram.updatePortVisibility(this.hoverElement,hi.Hover,f);var g=this.getContent();null===r&&this.hoverElement&&"Auto"===this.hoverElement.tooltip.openOn&&g&&(this.hoverElement=null,this.elementLeave()),s=!1}else{this.eventArgs.position=this.currentPosition,"Drag"===this.action&&!_r(this.diagram,this.eventArgs.source,!1)&&this.eventArgs.source instanceof si&&this.getMouseEventArgs(this.currentPosition,this.eventArgs),this.mouseEvents(),(t.ctrlKey||t.shiftKey)&&(this.eventArgs.info=t.ctrlKey&&t.shiftKey?{ctrlKey:t.ctrlKey,shiftKey:t.shiftKey}:{ctrlKey:!0}),this.checkAction(r);var y=this.getConnectorPadding(this.eventArgs);this.getMouseEventArgs(this.currentPosition,this.eventArgs,this.eventArgs.source,y),this.updateCursor(),this.inAction=!0,this.initialEventArgs=null,("Drag"===this.action||"Rotate"===this.action)&&(this.diagram.diagramActions=this.diagram.diagramActions|ee.Interactions);var S=this.diagram.scroller.getPageBounds();this.mouseMoveExtend(t,r);var b=this.diagram.scroller.getPageBounds();if(r&&(S.width!==b.width||S.height!==b.height||S.x!==b.x||S.y!==b.y)&&this.diagram.views&&this.diagram.views.overview){var M=this.diagram.views.overview;M.updateView(M)}}this.prevPosition=this.currentPosition,this.isForeignObject(t.target,!0)||t.preventDefault()}}},n.prototype.getContent=function(){var i,t=this.hoverElement instanceof te&&this.hoverElement.constraints&ie.Tooltip||this.hoverElement instanceof de&&this.hoverElement.constraints&qe.Tooltip||(this.hoverElement instanceof Es||this.hoverElement instanceof xc)&&this.hoverElement.constraints&ri.ToolTip||(this.hoverElement instanceof Zn||this.hoverElement instanceof Nr)&&this.hoverElement.constraints&Lr.Tooltip,e=this.hoverElement;e instanceof te&&e.children&&e.children.length>0&&(i=this.findIntersectChild(e));var r=t?this.hoverElement.tooltip.content:this.diagram.tooltip.content;return i?i.tooltip.content:r},n.prototype.findIntersectChild=function(t){for(var e,i=new Ne(this.currentPosition.x,this.currentPosition.y,8,8),r=0;r1&&1===t.which&&!function Gre(n){return!!(n&ee.PreventClearSelection)}(this.diagram.diagramActions)&&(c=!1,this.commandHandler.clearSelection()),(!_r(this.diagram,h)||!c)&&(this.commandHandler.selectObjects([h],void 0,a),this.diagram.selectedItems.canToggleSelection)){var d=this.diagram.selectedItems.nodes;d?d[0].parentObj instanceof Rd&&(s=!0):this.diagram.selectedItems.connectors.length>0&&(s=!0)}}var u=!1,p=this.updateContainerProperties(),f=void 0;if(this.addUmlNode(),this.inAction=!1,this.isMouseDown=!1,this.diagram.selectedObject.helperObject&&(f=this.updateContainerBounds()),this.tool&&(this.tool.prevPosition||this.tool instanceof Q3)){this.eventArgs.position=this.currentPosition;var g=this.getConnectorPadding(this.eventArgs);this.getMouseEventArgs(this.currentPosition,this.eventArgs,this.eventArgs.source,g);var v=this.isMetaKey(t);if((v||t.shiftKey)&&(this.eventArgs.info=v&&t.shiftKey?{ctrlKey:v,shiftKey:t.shiftKey}:{ctrlKey:!0}),this.diagram.diagramActions&ee.Interactions&&(this.diagram.diagramActions=this.diagram.diagramActions&~ee.Interactions),this.eventArgs.clickCount=t.detail,this.diagram.selectedObject.helperObject&&(this.tool instanceof ua||this.tool instanceof kd)){if(this.diagram.selectedObject.actualObject&&""!==this.diagram.selectedObject.actualObject.parentId){var S=this.diagram.getObject(this.diagram.selectedObject.actualObject.parentId);S&&S.isLane&&(this.commandHandler.isContainer=!0)}(u=this.diagram.lineRoutingModule&&this.diagram.nameTable.helper&&this.eventArgs.target&&this.eventArgs.target.isLane&&(this.eventArgs.source instanceof si&&this.eventArgs.source.nodes.length>0&&""===this.eventArgs.source.nodes[0].parentId||""===this.eventArgs.source.parentId))&&(this.diagram.diagramActions=this.diagram.diagramActions|ee.PreventLaneContainerUpdate),this.tool.mouseUp(this.eventArgs,p.isPreventHistory)}else{if(this.diagram.selectedItems.canToggleSelection){var b=void 0,M=void 0;if(this.diagram.selectedItems.nodes.length>0)for(var w=0;w1&&D[0].id===i[parseInt(w.toString(),10)].id||r.length>0)&&(M=!0);!this.isSwimlaneSelected&&!s&&!M&&this.tool instanceof ua&&"Select"===this.currentAction&&(!b||this.diagram.selectedItems.connectors.length>0)&&this.commandHandler.clearSelection(!0)}this.isSwimlaneSelected=!1,this.tool.mouseUp(this.eventArgs),this.diagram.checkMenu&&(-1!==window.navigator.userAgent.indexOf("Linux")||-1!==window.navigator.userAgent.indexOf("X11"))&&(!t.pageY&&t instanceof TouchEvent&&t.changedTouches?(window.getSelection().removeAllRanges(),this.diagram.contextMenuModule.contextMenu.open(t.changedTouches[0].pageY,t.changedTouches[0].pageX,this.diagram.element),t.preventDefault()):this.diagram.contextMenuModule.contextMenu.open(t.pageY,t.pageX,this.diagram.element),this.diagram.checkMenu=!1)}p.hasStack&&this.diagram.endGroupAction()}if(f&&this.diagram.endGroupAction(),this.updateContainerBounds(!0),2!==this.eventArgs.clickCount&&(this.commandHandler.updateSelectedNodeProperties(this.eventArgs.source),u)){this.diagram.diagramActions=this.diagram.diagramActions&~ee.PreventLaneContainerUpdate;var A=this.eventArgs.source instanceof si?this.eventArgs.source.nodes:[this.eventArgs.source];if(A)for(w=0;w0&&!N&&this.diagram.renderSelector(!0),!this.inAction&&!this.diagram.currentSymbol&&this.eventArgs){var T=this.getTargetElement();this.diagram.tool!==Ci.ZoomPan&&this.diagram.triggerEvent(Ce.click,{element:T.target instanceof Es?T.target:this.eventArgs.source||this.diagram,position:this.eventArgs.position,count:t.detail,actualObject:this.eventArgs.actualObject,button:0===t.button?"Left":1===t.button?"Middle":"Right"})}this.eventArgs={}}this.diagram.diagramActions=this.diagram.diagramActions&~ee.PreventLaneContainerUpdate,e&&this.updateAnnotation(this.diagram.selectedItems),this.eventArgs={},this.diagram.commandHandler.removeStackHighlighter()},n.prototype.isSwimlaneChild=function(t){if(t.shape&&"SwimLane"!==t.shape.type){var e=this.diagram.nameTable[t.parentId];if(!e)return!1;var i=e.parentId?this.diagram.nameTable[e.parentId]:e;return i&&i.shape&&"SwimLane"===i.shape.type}return!1},n.prototype.updateAnnotation=function(t){var e=t.nodes;if(e.length>0)for(var i=0;i0&&(a+=1),h.isPhase){l="Horizontal"===r.orientation?this.currentPosition.x-e.wrapper.bounds.x:this.currentPosition.y-(e.wrapper.bounds.y+r.header.height);var g={id:Qe(),offset:l,header:{annotation:{content:void 0===h.phases[0].header?"Phase":h.phases[0].header.annotation.content,style:void 0===h.phases[0].header?{}:h.phases[0].header.annotation.style}},style:void 0===h.phases[0]?{}:h.phases[0].style};this.diagram.addPhases(e,[g])}else{var v={id:Qe(),style:h.lanes[0].style,header:{annotation:{content:h.lanes[0].header.annotation.content,style:h.lanes[0].header.annotation.style},style:h.lanes[0].header.style}};if("Horizontal"===h.orientation?v.height=h.lanes[0].height:v.width=h.lanes[0].width,"Horizontal"===r.orientation?(s=i.rowIndex?i.rowIndex:this.diagram.nameTable[i.parentId].rowIndex,i.wrapper.offsetYs)v.header.width=r.lanes[parseInt(s.toString(),10)].header.width,v.header.height=r.lanes[parseInt(s.toString(),10)].header.height;else{var S=void 0;S="Horizontal"===r.orientation?i.rowIndex<3?0:s-a-1:s-1,v.header.width=r.lanes[parseInt(S.toString(),10)].header.width,v.header.height=r.lanes[parseInt(S.toString(),10)].header.height}f&&("height"===f?(v.width=v.height,delete v.height):(v.height=v.width,delete v.width)),this.diagram.addLanes(e,[v],"Horizontal"===r.orientation?s-a:s)}this.commandHandler.select(e)}else if(h.isLane){var b={id:Qe(),width:t.width,height:t.height,addInfo:t.addInfo,shape:{type:"SwimLane",header:{annotation:{content:void 0===h.header?"Header":h.header.annotation.content,style:void 0===h.header?{}:h.header.annotation.style},height:50,style:h.header?h.header.style:h.lanes[0].header.style},phases:[{id:Qe(),header:{annotation:{content:void 0===h.phases||void 0===h.phases[0].header?"Phase":h.phases[0].header.annotation.content,style:void 0===h.phases||void 0===h.phases[0].header?{}:h.phases[0].header.annotation.style},style:void 0===h.phases||void 0===h.phases[0].header?{}:h.phases[0].header.style},style:void 0===h.phases?{}:h.phases[0].style}],lanes:[{id:Qe(),height:t.height,width:t.width,style:h.lanes[0].style,header:{annotation:{content:h.lanes[0].header.annotation.content,style:h.lanes[0].header.annotation.style},style:h.lanes[0].header.style}}],orientation:h.orientation}};"Vertical"===h.orientation&&(b.width+=20),b.offsetX=this.currentPosition.x+b.width/2,b.offsetY=this.currentPosition.y+b.height/2,b.style=t.style,this.diagram.add(b)}},n.prototype.mouseLeave=function(t){this.tool&&this.inAction&&this.tool.mouseLeave(this.eventArgs),this.diagram.selectedObject.helperObject&&(this.updateContainerProperties(),this.updateContainerBounds()&&this.diagram.endGroupAction()),this.eventArgs&&this.eventArgs.source&&(this.diagram.updatePortVisibility(this.eventArgs.source,hi.Hover,!0),this.hoverElement=null),this.eventArgs&&!this.eventArgs.source&&this.hoverElement&&(this.hoverElement=null),this.tool instanceof Od&&this.eventArgs&&this.eventArgs.target&&this.eventArgs.target instanceof te&&(this.diagram.updatePortVisibility(this.eventArgs.target,hi.Hover|hi.Connect,!0),this.hoverElement=null);var i=this.diagram.selectedItems;i&&i.wrapper&&(nm(this.diagram,i)||this.diagram.renderSelector(!0)),(this.diagram.diagramActions&ee.Interactions||this.diagram.diagramActions&ee.ToolAction)&&(this.diagram.diagramActions=this.diagram.diagramActions&~ee.ToolAction),this.isMouseDown=!1,this.focus=!1,this.touchStartList=null,this.touchMoveList=null,this.elementLeave(),this.commandHandler.removeSnap(),this.inAction=!1,this.eventArgs={},this.diagram.selectedObject&&this.diagram.selectedObject.helperObject&&(this.diagram.remove(this.diagram.selectedObject.helperObject),this.diagram.selectedObject={helperObject:void 0,actualObject:void 0}),this.tool=null,function Wne(){var t,e,n=document.getElementsByClassName("e-d-ruler-marker");if(n&&n.length>0)for(e=n.length-1;e>=0;e--)(t=n[parseInt(e.toString(),10)])&&t.parentNode.removeChild(t)}(),"Rotate"===this.action&&this.diagram.diagramCanvas.classList.remove("e-diagram-rotate"),t.preventDefault()},n.prototype.mouseWheel=function(t){this.diagram.blazorActions|=on.interaction;var e={event:t,cancel:!1};if(this.diagram.triggerEvent(Ce.mouseWheel,e),!e.cancel){var i=t.wheelDelta>0||-40*t.detail>0,r=this.getMousePosition(t);if(this.diagram.tooltipObject.close(),this.isMetaKey(t)){var o=this.diagram.scrollSettings.zoomFactor;this.diagram.zoomTo(i?{type:"ZoomIn",zoomFactor:o,focusPoint:r}:{type:"ZoomOut",zoomFactor:o,focusPoint:r}),t.preventDefault()}else{var a=this.diagram.scroller.horizontalOffset,l=this.diagram.scroller.verticalOffset,h=i?10:-10;this.tool&&(this.tool instanceof Oh||this.tool instanceof kh)&&(this.eventArgs={},this.getMouseEventArgs(r,this.eventArgs),this.eventArgs.position=r,this.tool.mouseWheel(this.eventArgs)),this.diagram.scrollActions|=ca.Interaction;var c=!0;if(t.isTrusted){var d=!1;(Math.abs(t.deltaY)<100&&-0===Math.abs(t.deltaX)||Math.abs(t.deltaX)<100&&-0===Math.abs(t.deltaY))&&(d=!0);var u=!1;(0!==t.deltaX||0!==t.deltaY)&&(u=navigator.userAgent.includes("Macintosh")),u?Math.abs(t.deltaX)>Math.abs(t.deltaY)?(t.shiftKey||t.deltaX&&-0!==t.deltaX&&(d||!u))&&this.diagram.scroller.zoom(1,h,0,r,c,void 0,d):t.deltaY&&-0!==t.deltaY&&(d||!u)&&this.diagram.scroller.zoom(1,0,h,r,c,void 0,d):t.shiftKey||t.deltaX&&-0!==t.deltaX&&(d||!u)?this.diagram.scroller.zoom(1,h,0,r,c,void 0,d):t.deltaY&&-0!==t.deltaY&&(d||!u)&&this.diagram.scroller.zoom(1,0,h,r,c,void 0,d)}else t.shiftKey||t.deltaX&&-0!==t.deltaX?this.diagram.scroller.zoom(1,h,0,r,c):this.diagram.scroller.zoom(1,0,h,r,c);this.diagram.scrollActions&=~ca.Interaction,(a!==this.diagram.scroller.horizontalOffset||l!==this.diagram.scroller.verticalOffset)&&t.preventDefault()}if(this.diagram.textEditing){if(this.diagram.isTriggerEvent=!0,this.diagram.activeLabel.parentId){var f=this.diagram.getObject(this.diagram.activeLabel.parentId);this.diagram.startTextEdit(f,this.diagram.activeLabel.id)}this.diagram.isTriggerEvent=!1}this.diagram.blazorActions=this.diagram.blazorActions&~on.interaction}},n.prototype.keyDown=function(t){if(t.fromMouseEvents&&(t.ctrlKey&&(this.keyArgs.keyModifiers=1),t.shiftKey&&(this.keyArgs.keyModifiers=4),t.shiftKey&&t.ctrlKey&&(this.keyArgs.keyModifiers=5)),!(this.diagram.diagramActions&ee.TextEdit)&&!this.checkEditBoxAsTarget(t)||"Escape"===t.key||27===t.keyCode){var i=void 0,r=t.keyCode?t.keyCode:t.which,s=t.key;("ArrowDown"===s||"ArrowUp"===s||"ArrowLeft"===s||"ArrowRight"===s)&&(this.isNudgeKey=!0);var o=this.isMetaKey(t);if(this.diagram.commandManager&&this.diagram.commands)for(var l=0,h=Object.keys(this.diagram.commands);l4&&(S({keyDownEventArgs:KeyboardEvent,parameter:i.parameter,type:"KEYDOWN"}),this.keyCount=0)),this.isKeyUp=!1):S({keyDownEventArgs:KeyboardEvent,parameter:i.parameter})}break}}}}this.keyArgs={element:this.diagram.selectedItems,key:t.key,keyCode:t.keyCode?t.keyCode:t.which},this.getKeyModifier(this.keyArgs,t),this.diagram.diagramActions&ee.TextEdit&&this.getlabel(this.keyArgs,t),this.diagram.triggerEvent(Ce.keyDown,this.keyArgs)},n.prototype.getlabel=function(t,e){var i=this.diagram.activeLabel;t.target=this.diagram.element.id+"_editBox";var r=this.diagram.nameTable[i.parentId];if(document.getElementById(this.diagram.element.id+"_editBox")){t.text=document.getElementById(this.diagram.element.id+"_editBox").value;for(var s=0;s=this.diagram.scroller.viewPortWidth-18?r="right":e.x+this.diagram.scroller.horizontalOffsetthis.diagram.scroller.viewPortHeight-18?r="bottom":e.y+this.diagram.scroller.verticalOffset0&&(s=this.findIntersectChild(this.hoverElement)),"Auto"===this.hoverElement.tooltip.openOn&&""!==r&&bx(this.diagram,s||(i?this.hoverElement:void 0)),this.hoverElement.tooltip.content&&("Mouse"===this.hoverElement.tooltip.relativeMode?this.setTooltipOffset(t):(this.diagram.tooltipObject.offsetX=0,this.diagram.tooltipObject.offsetY=0));var o=this.diagram.findObjectsUnderMouse(this.currentPosition),a=this.diagram.findObjectUnderMouse(o,this.action,this.inAction);if(null!==a){var l=void 0;this.hoverElement.tooltip.isSticky&&(this.diagram.tooltipObject.isSticky=!0),a instanceof te&&a.children&&a.children.length>0&&(a=s||a),l=a.ports&&(this.hoverElement instanceof Es||this.hoverElement instanceof xc)||a.annotations&&(this.hoverElement instanceof Zn||this.hoverElement instanceof Nr)?document.getElementById(a.id+"_"+this.hoverElement.id):document.getElementById(a.id+(a.shape&&a.shape instanceof sm?"_content_native_element":"_groupElement")),"Auto"===this.hoverElement.tooltip.openOn&&""!==r&&(this.diagram.tooltipObject.close(),this.diagram.tooltipObject.openOn=this.hoverElement.tooltip.openOn,this.diagram.tooltipObject.dataBind()),function _re(n,t){var e=0;return n instanceof de?n.constraints&qe.Tooltip?e=n.constraints&qe.Tooltip:n.constraints&qe.InheritTooltip&&(e=t.constraints&rt.Tooltip):n instanceof Es||n instanceof xc?n.constraints&ri.ToolTip?e=n.constraints&ri.ToolTip:n.constraints&ri.InheritTooltip&&(e=t.constraints&rt.Tooltip):n instanceof Zn||n instanceof Nr?n.constraints&Lr.Tooltip&&(e=n.constraints&Lr.Tooltip):n.constraints&ie.Tooltip?e=n.constraints&ie.Tooltip:n.constraints&ie.InheritTooltip&&(e=t.constraints&rt.Tooltip),e}(this.hoverElement,this.diagram)&&"Auto"===this.hoverElement.tooltip.openOn&&(this.diagram.tooltipObject.target=this.hoverElement.id,this.diagram.tooltipObject.open("Mouse"===this.hoverElement.tooltip.relativeMode?this.diagram.element:l))}}},n.prototype.elementLeave=function(){this.diagram.tooltipObject&&!this.diagram.tooltipObject.isSticky&&"Custom"!==this.diagram.tooltipObject.openOn&&this.diagram.tooltipObject.close()},n.prototype.setTooltipOffset=function(t){var e=function hse(n,t,e,i){var o="Mouse"===(!(e instanceof te?e.constraints&ie.InheritTooltip:e instanceof de?e.constraints&qe.InheritTooltip:e.constraints&ri.InheritTooltip)&&(e instanceof te?e.constraints&ie.Tooltip:e instanceof de?e.constraints&qe.Tooltip:e.constraints&ri.ToolTip)?e.tooltip.relativeMode:n.tooltip.relativeMode);"Mouse"===i?o=!0:"Object"===i&&(o=!1);var a=function cse(n,t,e,i){var o,r={},s=document.getElementById(e.element.id);if(n instanceof te||n instanceof de)o=n.wrapper.bounds;else{var a=e.findObjectsUnderMouse(t),l=e.findObjectUnderMouse(a,"Select",!1);o=e.findElementUnderMouse(l,t,e).bounds}var c=s.getBoundingClientRect();switch(e.tooltipObject.position){case"BottomCenter":r=zc(t,o.bottomCenter,e,i,c.width/2,c.height);break;case"BottomLeft":case"LeftBottom":r=zc(t,o.bottomLeft,e,i,0,c.height);break;case"BottomRight":case"RightBottom":r=zc(t,o.bottomRight,e,i,c.width,c.height);break;case"LeftCenter":r=zc(t,o.middleLeft,e,i,0,c.height/2);break;case"LeftTop":case"TopLeft":r=zc(t,o.topLeft,e,i,0,0);break;case"RightCenter":r=zc(t,o.middleRight,e,i,c.width,c.height/2);break;case"RightTop":case"TopRight":r=zc(t,o.topRight,e,i,c.width,0);break;case"TopCenter":r=zc(t,o.topCenter,e,i,c.width/2,0)}return r}(e,t,n,o),l=qa(n);return{x:a.x+l.width,y:a.y+l.height}}(this.diagram,t,this.hoverElement);this.diagram.tooltipObject.offsetX=e.x,this.diagram.tooltipObject.offsetY=e.y},n.prototype.altKeyPressed=function(t){return!!(t&pt.Alt)},n.prototype.ctrlKeyPressed=function(t){return!!(t&pt.Control)},n.prototype.shiftKeyPressed=function(t){return!!(t&pt.Shift)},n.prototype.scrolled=function(t){this.diagram.updateScrollOffset()},n.prototype.doubleClick=function(t){if(_v(this.diagram)){var e=void 0,i=this.diagram.findObjectsUnderMouse(this.currentPosition),r=this.diagram.findObjectUnderMouse(i,this.action,this.inAction);if(null!==r&&_v(this.diagram))if(e=this.diagram.findElementUnderMouse(r,this.currentPosition,this.diagram),this.tool&&(this.tool instanceof Oh||this.tool instanceof kh))this.tool.mouseUp(this.eventArgs),this.isMouseDown=!1,this.eventArgs={},this.tool=null,t.preventDefault();else{var o=this.diagram.commandHandler.getObjectLayer(r.id);!o||o.lock||!o.visible||this.diagram.diagramActions&ee.TextEdit||this.diagram.startTextEdit(r,e instanceof ni?e.id.split(r.id+"_")[1]:void 0)}this.diagram.triggerEvent(Ce.doubleClick,{source:r||this.diagram,position:this.currentPosition,count:t.detail})}},n.prototype.itemClick=function(t,e){var i=t;return cs(this.diagram,i,!0)?i:null},n.prototype.inputChange=function(t){var i,s,o,a,l,h,c,d,u,p=document.getElementById(this.diagram.element.id+"_editBox"),f=document.getElementById(this.diagram.element.id+"_editTextBoxDiv"),g=p.value,v=g.split("\n");(!(a=this.diagram.selectedItems.nodes[0]?this.diagram.selectedItems.nodes[0]:this.diagram.selectedItems.connectors[0])&&this.tool instanceof jI||a&&"SwimLane"===a.shape.type)&&(a=this.diagram.nameTable[this.diagram.activeLabel.parentId]),a&&("Text"!==a.shape.type&&a.annotations.length>0||"Text"===a.shape.type)&&(c=AF((o=this.diagram.getWrapper(a.wrapper,this.diagram.activeLabel.id)).style,g,void 0,void 0,i=(i=a.wrapper.bounds.width90?i:90),s=Number(p.style.fontSize.split("px")[0]),v.length>1&&""===v[v.length-1]&&(c.height=c.height+s),d=this.diagram.scroller.transform,u=D3(this.diagram)?d.scale:1,l=(12>c.height?12:c.height)*u,f.style.left=(o.bounds.center.x+d.tx)*d.scale-(h=(90>(h=c.width)?90:h)*u)/2-2.5+"px",f.style.top=(o.bounds.center.y+d.ty)*d.scale-l/2-3+"px",f.style.width=h+"px",f.style.height=l+"px",p.style.minHeight="12px",p.style.minWidth="90px",p.style.width=h+"px",p.style.height=l+"px")},n.prototype.isAddTextNode=function(t,e){return!(!(this.tool instanceof jI||e)||(this.tool=null,t&&!NI(this.diagram)&&(this.diagram.drawingObject=void 0,this.diagram.currentDrawingObject=void 0),fF(this.diagram.nodes,t.id)||fF(this.diagram.connectors,t.id)))},n.prototype.checkEditBoxAsTarget=function(t){return!(!t.target||t.target.id!==this.diagram.element.id+"_editBox")},n.prototype.getMouseEventArgs=function(t,e,i,r){var s,o,a;if(e.position=t,i?(o=this.diagram.findObjectsUnderMouse(this.currentPosition,i),s=this.diagram.findTargetObjectUnderMouse(o,this.action,this.inAction,e.position,i)):"Drag"===this.action||"ConnectorSourceEnd"===this.action||"SegmentEnd"===this.action||"OrthoThumb"===this.action||"BezierSourceThumb"===this.action||"BezierTargetThumb"===this.action||"ConnectorTargetEnd"===this.action||-1!==this.action.indexOf("Rotate")||-1!==this.action.indexOf("Resize")?(s=this.diagram.selectedItems,!this.diagram.currentSymbol&&"Drag"===this.action&&s&&this.diagram.selectedItems.nodes.length>0&&"SwimLane"===this.diagram.selectedItems.nodes[0].shape.type&&(o=this.diagram.findObjectsUnderMouse(this.currentPosition),s=this.diagram.findObjectUnderMouse(o,this.action,this.inAction))):(o=this.diagram.findObjectsUnderMouse(this.currentPosition),s=this.diagram.findObjectUnderMouse(o,this.action,this.inAction)),s&&s.isHeader&&(this.eventArgs.actualObject=s=this.diagram.nameTable[s.parentId]),s){var l=void 0,h=void 0,c=void 0;if(((a=this.diagram.findElementUnderMouse(s,this.currentPosition,this.diagram,r))&&s.ports&&s.ports.length&&!eb(s,a)||!a||!s)&&o&&o.length&&i instanceof si)for(l=i.connectors[0],c=o.length-1;c>=0;c--)if(((h=o[parseInt(c.toString(),10)])instanceof te||h instanceof de)&&l&&l.connectionPadding){if(a=this.diagram.findElementUnderMouse(s=h,this.currentPosition,this.diagram,r),l.constraints&qe.ConnectToNearByPort&&s&&s.ports&&s.ports.length&&eb(s,a))break;if((h instanceof te||h instanceof de)&&l&&l.connectionPadding&&h.wrapper.outerBounds.containsPoint(this.currentPosition)&&l.constraints&qe.ConnectToNearByNode&&!(l.constraints&qe.ConnectToNearByPort)){a=this.diagram.findElementUnderMouse(s=h,this.currentPosition,this.diagram,0);break}}}return i?(e.target=s,e.targetWrapper=a):(e.source=s,e.sourceWrapper=a),e.actualObject=this.eventArgs.actualObject,e.source instanceof si&&void 0===e.actualObject&&(e.source.nodes.length>0||e.source.connectors.length>0)&&(e.actualObject=e.source.nodes.length>0?this.diagram.nameTable[e.source.nodes[0].id]:this.diagram.nameTable[e.source.connectors[0].id]),e.startTouches=this.touchStartList,e.moveTouches=this.touchMoveList,e},n.prototype.resetTool=function(){this.action="Select",this.hoverElement=null,this.hoverNode=null,this.tool=this.diagram.getTool(this.action),this.updateCursor()},n.prototype.updateTool=function(){this.eventArgs&&!this.eventArgs.position&&(this.action="Select")},n.prototype.getTool=function(t){switch(t){case"Select":return new qv(this.commandHandler,!0);case"Drag":return new ua(this.commandHandler);case"Rotate":return new Wx(this.commandHandler);case"LayoutAnimation":return new Tne(this.commandHandler);case"FixedUserHandle":return new xne(this.commandHandler,!0);case"Hyperlink":return new Q3(this.commandHandler);case"ResizeSouthEast":case"ResizeSouthWest":case"ResizeNorthEast":case"ResizeNorthWest":case"ResizeSouth":case"ResizeNorth":case"ResizeWest":case"ResizeEast":return new kd(this.commandHandler,t);case"ConnectorSourceEnd":case"ConnectorTargetEnd":case"BezierSourceThumb":case"BezierTargetThumb":return new Od(this.commandHandler,t);case"SegmentEnd":case"OrthoThumb":return new qF(this.commandHandler,t);case"Draw":var e="shape",i=function ise(n){var t;return n&&(n.type?t="Connector":n.shape&&!n.type&&(t="Node")),t}(this.diagram.drawingObject);if("Node"===i&&"Text"===this.diagram.drawingObject.shape.type)return new jI(this.commandHandler);if("Connector"===i&&"Freehand"===this.diagram.drawingObject.type)return new One(this.commandHandler);if("Node"===i&&"Polygon"===this.diagram.drawingObject.shape[""+e]&&!this.diagram.drawingObject.shape.points)return new Oh(this.commandHandler);if("Node"===i||"Node"===i&&"Polygon"===this.diagram.drawingObject.shape[""+e]&&this.diagram.drawingObject.shape.points)return new UI(this.commandHandler,this.diagram.drawingObject);if("Connector"===i&&"Polyline"===this.diagram.drawingObject.type)return new kh(this.commandHandler);if("Connector"===i)return new pa(this.commandHandler,"ConnectorSourceEnd",this.diagram.drawingObject);break;case"Pan":return new $v(this.commandHandler,!1);case"PinchZoom":return new $v(this.commandHandler,!0);case"PortDrag":return new ua(this.commandHandler,"Port");case"PortDraw":return new pa(this.commandHandler,"ConnectorSourceEnd",this.diagram.drawingObject);case"LabelSelect":return new qv(this.commandHandler,!0,"LabelSelect");case"LabelDrag":return new Ane(this.commandHandler);case"LabelResizeSouthEast":case"LabelResizeSouthWest":case"LabelResizeNorthEast":case"LabelResizeNorthWest":case"LabelResizeSouth":case"LabelResizeNorth":case"LabelResizeWest":case"LabelResizeEast":return new Lne(this.commandHandler,t);case"LabelRotate":return new Nne(this.commandHandler)}return null},n.prototype.getCursor=function(t){var e=this.diagram.selectedItems.annotation?this.diagram.selectedItems.wrapper.children[0]:this.diagram.selectedItems;return function Dne(n,t){if(t+=360,t%=360,-1===n.indexOf("Resize"))return Vx[""+n];var e=Vx[""+n];return t>=0&&t<25||t>=160&&t<=205||t>=340&&t<=360?e:t>=25&&t<=70||t>=205&&t<=250?"n-resize"===e||"s-resize"===e?"ne-resize":"nw-resize"===e||"se-resize"===e?"n-resize":"e-resize"===e||"w-resize"===e?"nw-resize":"e-resize":t>=70&&t<=115||t>=250&&t<=295?"n-resize"===e||"s-resize"===e?"e-resize":"nw-resize"===e||"se-resize"===e?"ne-resize":"e-resize"===e||"w-resize"===e?"n-resize":"nw-resize":t>=115&&t<=155||t>=295&&t<=340?"n-resize"===e||"s-resize"===e?"nw-resize":"nw-resize"===e||"se-resize"===e?"e-resize":"e-resize"===e||"w-resize"===e?"ne-resize":Vx[""+n]:"n-resize"}(t,this.diagram.selectedItems.annotation?e.rotateAngle+e.parentTransform:e.rotateAngle)},n.prototype.findElementUnderMouse=function(t,e,i,r){return this.objectFinder.findElementUnderSelectedItem(t,e,i,r)},n.prototype.findObjectsUnderMouse=function(t,e){return this.objectFinder.findObjectsUnderMouse(t,this.diagram,this.eventArgs,e)},n.prototype.findObjectUnderMouse=function(t,e,i){return this.objectFinder.findObjectUnderMouse(this.diagram,t,e,i,this.eventArgs,this.currentPosition)},n.prototype.findTargetUnderMouse=function(t,e,i,r,s){return this.objectFinder.findObjectUnderMouse(this.diagram,t,e,i,this.eventArgs,r,s)},n.prototype.findActionToBeDone=function(t,e,i,r){return function Ine(n,t,e,i,r,s,o){if(s&&s.length>1&&r&&r.length>1)return"PinchZoom";if(i.currentSymbol)return"Drag";if("PortDraw"===i.eventHandler.action&&(i.tool&=~Ci.DrawOnce),(E3(i)||NI(i))&&i.drawingObject)return"Draw";if(Xa(i)&&(l=i.selectedItems).wrapper&&qr(l.constraints,"UserHandle"))for(var h=0,c=l.userHandles;h=50&&(l.x=(a.points[parseInt(h.toString(),10)].x+a.points[h+1].x)/2,l.y=(a.points[parseInt(h.toString(),10)].y+a.points[h+1].y)/2,wr(e,l,n.hitPadding?n.hitPadding:10)))return"OrthoThumb"}else xI(n)&&console.warn('[WARNING] :: Module "ConnectorEditing" is not available in Diagram component! You either misspelled the module name or forgot to load it.');return null}(g,l,e,i);if("OrthoThumb"===S)return S;if(qr(l.constraints,"ConnectorSourceThumb")&&EI(g)&&S||qr(l.constraints,"ConnectorTargetThumb")&&DI(g)&&S)return S}}else{var b=i.selectedItems.handleSize/2/i.scroller.currentZoom,M=10/i.scroller.currentZoom,w=Hi();qi(w,p.rotateAngle+p.parentTransform,p.offsetX,p.offsetY);var C=p.offsetX-p.pivot.x*p.actualSize.width,D=p.offsetY-p.pivot.y*p.actualSize.height,A={x:C+(.5===p.pivot.x?2*p.pivot.x:p.pivot.x)*p.actualSize.width/2,y:D-30/i.scroller.currentZoom};A=Je(w,A);var x=!!i.selectedItems.annotation,R=!(!x||!TI(i.selectedItems.annotation));if(qr(l.constraints,"Rotate")&&wr(e,A,M)&&i.selectedItems.thumbsConstraints&bt.Rotate){if(x&&R)return"LabelRotate";if(!x)return"Rotate"}if(u.Inflate(b),u.containsPoint(e)&&(S=function bne(n,t,e,i,r,s){var o;return 1===n.selectedItems.nodes.length&&0===n.selectedItems.connectors.length&&n.selectedItems.nodes[0].container&&(o=function Cne(n,t,e,i,r){var s=10/n.scroller.currentZoom,o=40/n.scroller.currentZoom,a=n.selectedItems,l=t.actualSize.width,h=t.actualSize.height,c=new Ne(i,r,t.style.strokeWidth,h),d=new Ne(i+l,r,t.style.strokeWidth,h),u=new Ne(i,r,l,t.style.strokeWidth),p=new Ne(i,r+h,l,t.style.strokeWidth),f=cs(n,n.selectedItems.nodes[0],!0)?n.nameTable[n.selectedItems.nodes[0].parentId]:n.selectedItems.nodes[0];if(l>=o&&h>=o){if(fa(a.constraints,"ResizeEast",a.thumbsConstraints,a)&&d.containsPoint(e,s))return"ResizeEast";if(fa(a.constraints,"ResizeSouth",a.thumbsConstraints,a)&&p.containsPoint(e,s))return"ResizeSouth";if("Grid"!==f.container.type){if(fa(a.constraints,"ResizeWest",a.thumbsConstraints,a)&&c.containsPoint(e,s))return"ResizeWest";if(fa(a.constraints,"ResizeNorth",a.thumbsConstraints,a)&&u.containsPoint(e,s))return"ResizeNorth"}}return null}(n,t,e,r,s)),!o&&(!n.selectedItems.nodes[0]||!n.selectedItems.nodes[0].isPhase&&!n.selectedItems.nodes[0].isLane&&"SwimLane"!==n.selectedItems.nodes[0].shape.type)&&(o=function Ene(n,t,e,i,r,s){var o=40/n.scroller.currentZoom,a=n.selectedItems.handleSize/2/n.scroller.currentZoom,l=n.selectedItems,h=!!l.annotation;if(t.actualSize.width>=o&&t.actualSize.height>=o){if(fa(l.constraints,"ResizeSouthEast",l.thumbsConstraints,l)&&wr(e,Je(i,{x:r+t.actualSize.width,y:s+t.actualSize.height}),a))return h?"LabelResizeSouthEast":"ResizeSouthEast";if(fa(l.constraints,"ResizeSouthWest",l.thumbsConstraints,l)&&wr(e,Je(i,{x:r,y:s+t.actualSize.height}),a))return h?"LabelResizeSouthWest":"ResizeSouthWest";if(fa(l.constraints,"ResizeNorthEast",l.thumbsConstraints,l)&&wr(e,Je(i,{x:r+t.actualSize.width,y:s}),a))return h?"LabelResizeNorthEast":"ResizeNorthEast";if(fa(l.constraints,"ResizeNorthWest",l.thumbsConstraints,l)&&wr(e,Je(i,{x:r,y:s}),a))return h?"LabelResizeNorthWest":"ResizeNorthWest"}return fa(l.constraints,"ResizeEast",l.thumbsConstraints,l)&&wr(e,Je(i,{x:r+t.actualSize.width,y:s+t.actualSize.height/2}),a)?h?"LabelResizeEast":"ResizeEast":fa(l.constraints,"ResizeWest",l.thumbsConstraints,l)&&wr(e,Je(i,{x:r,y:s+t.actualSize.height/2}),a)?h?"LabelResizeWest":"ResizeWest":fa(l.constraints,"ResizeSouth",l.thumbsConstraints,l)&&wr(e,Je(i,{x:r+t.actualSize.width/2,y:s+t.actualSize.height}),a)?h?"LabelResizeSouth":"ResizeSouth":fa(l.constraints,"ResizeNorth",l.thumbsConstraints,l)&&wr(e,Je(i,{x:r+t.actualSize.width/2,y:s}),a)?h?"LabelResizeNorth":"ResizeNorth":null}(n,t,e,i,r,s)),o||null}(i,p,e,w,C,D),S))return S}}if(Lc(i)&&!n)return"Pan";if((o instanceof Es||o instanceof xc)&&(!Lc(i)||Bv(i)||Fv(i))&&(S=function wne(n,t,e,i){if(Rx(t)&&(ga(t,hi.Hover)||ga(t,hi.Visible))){if(t.constraints&ri.Drag)return"PortDrag"}else if(zx(t)&&(ga(t,hi.Hover)||ga(t,hi.Visible))&&t.constraints&ri.Draw){n.drawingObject={};var r={type:"Orthogonal",sourcePortID:t.id};return n.drawingObject=r,n.tool|=Ci.DrawOnce,n.currentDrawingObject=r,"PortDraw"}return"None"}(i,o),"None"!==S))return S;if((o instanceof Zn||o instanceof Nr)&&!Lc(i)&&Dd(o))return _r(i,o,void 0,t)&&to(o)?"LabelDrag":"LabelSelect";if(null!==n){if(!(n instanceof te||n instanceof de))return"Select";if(t&&t.id){var L=t.id.split(n.id)[1];if(L&&L.match("^_icon"))return"LayoutAnimation"}if(t&&t.id)for(var O=void 0,N=0;N-1)return"FixedUserHandle";if(t instanceof ni&&t.hyperlink.link)return"Hyperlink";if(!to(n)||!_r(i,n,!1)||void 0!==i.selectedItems.annotation)return n&&Lc(i)&&!OI(i)?"Pan":i.selectedItems.nodes.length&&i.selectedItems.nodes[0].isLane&&i.selectedItems.wrapper&&i.selectedItems.wrapper.bounds.containsPoint(e)?"Drag":"Select";if(n instanceof de&&!wr(e,n.sourcePoint,n.hitPadding)&&!wr(e,n.targetPoint,n.hitPadding)||!(n instanceof de))return"Drag"}return"Select"}(t,e,this.currentPosition,this.diagram,this.touchStartList,this.touchMoveList,r)},n.prototype.updateContainerBounds=function(t){var e=!1;if(this.diagram.selectedObject.helperObject&&this.diagram.selectedObject.actualObject instanceof te){var i=this.tool instanceof kd,r=this.diagram.selectedObject.actualObject,s=this.diagram.nameTable[r.parentId];t?U3(this.diagram,r,this.currentPosition,i):((!s||s&&"SwimLane"!==s.shape.type)&&this.diagram.updateDiagramObject(r),e=function vne(n,t,e,i){var r,o=!1;if(cs(n,t,!0)){n.protectPropertyChange(!0);var a=(r=n.nameTable[t.parentId]).wrapper;if(r&&"Canvas"===r.container.type){if(i||a.bounds.x<=e.x&&a.bounds.right>=e.x&&a.bounds.y<=e.y&&a.bounds.bottom>=e.y){var l=void 0,h=a.bounds.y,c=a.bounds.x,d=n.nameTable[r.parentId]||r;if("SwimLane"===d.shape.type)o=Xv(r,d,t,n,!0);else{var p=n.nameTable[r.parentId]||r,f=p.shape;l=p.wrapper,a.actualSize.widtha.outerBounds.x)&&(void 0!==r.rowIndex?(l.updateColumnWidth(r.columnIndex,a.outerBounds.width,!0),"Horizontal"===f.orientation&&f.phaseSize&&HI(p,n,a,r.columnIndex),Oc(n,p),n.drag(p,c-a.bounds.x,h-a.bounds.y)):n.scale(r,1+(a.outerBounds.width-a.actualSize.width)/a.actualSize.width,1,a.outerBounds.xa.outerBounds.y)&&(void 0!==r.rowIndex?(l.updateRowHeight(r.rowIndex,a.outerBounds.height,!0),n.drag(p,c-a.bounds.x,h-a.bounds.y)):n.scale(r,1,1+(a.outerBounds.height-a.actualSize.height)/a.actualSize.height,a.outerBounds.yi.y&&(h+=u>0?-1:1,u+=u>0?-1:1):i&&e.wrapper.offsetYi.x&&(h+=u>0?-1:1,u+=u>0?-1:1):i&&e.wrapper.offsetX1&&!(this.diagram.lineRoutingModule&&this.diagram.constraints&rt.LineRouting))for(var b=t.offsetX-this.diagram.selectedItems.offsetX,M=t.offsetY-this.diagram.selectedItems.offsetY,w=t.rotateAngle-this.diagram.selectedItems.rotateAngle,C=0;C-1){var x=c.children;x.splice(x.indexOf(o.id),1),this.diagram.nameTable[o.id].parentId="",i=!0,c.wrapper.children.splice(A,1)}}if(function Sne(n,t,e,i){var r=n,s=e.nameTable[r.parentId],o=e.nameTable[r.parentId];if(t&&o&&o.container&&"Stack"===o.container.type&&t.container&&"Stack"===t.container.type&&o.id!==t.parentId){var a=o.wrapper.children.indexOf(r.wrapper);a>-1&&(e.nameTable[r.id].parentId=t.id,o.wrapper.children.splice(a,1))}if(t&&t.parentId&&r.parentId&&"Drag"===i&&o.container&&"Stack"===o.container.type){var l=s.wrapper.children.indexOf(t.wrapper),h=s.wrapper.children.indexOf(r.wrapper),c={targetIndex:l,target:t,sourceIndex:h,source:n};s.wrapper.children.splice(h,1),s.wrapper.children.splice(l,0,r.wrapper),e.commandHandler.addHistoryEntry({type:"StackChildPositionChanged",redoObject:{targetIndex:h,target:t,sourceIndex:l,source:n},undoObject:c,category:"Internal"})}}(o,h,this.diagram,this.action),(c=cs(this.diagram,o)?this.diagram.nameTable[o.parentId]:this.diagram.nameTable[o.parentId]||o)&&c.container&&"Canvas"===c.container.type&&(c.wrapper.maxWidth=c.maxWidth=c.wrapper.actualSize.width,c.wrapper.maxHeight=c.maxHeight=c.wrapper.actualSize.height,e=!0),cs(this.diagram,o,!0)&&c&&"Canvas"===c.container.type)if(this.diagram.selectedItems.nodes.length>1)for(C=0;C0)for(var i=0;i0&&e.columnIndex>0||l&&e.isLane)){if("Horizontal"===t.container.orientation&&e.isPhase&&e.wrapper.width>e.maxWidth&&(e.maxWidth=e.wrapper.width,e.wrapper.maxWidth=e.wrapper.width),h.updateColumnWidth(e.columnIndex,r.width,!0,c),Fx(this.diagram,e,t),e.isPhase){var f=this.diagram.nameTable[""+t.shape.phases[e.columnIndex].header.id];f.maxWidth0?(r=new rf(t,"",u),t.shape.classShape.attributes.push(r)):i.id.includes("_umlMethods")&&t.shape.classShape.methods.length>0&&(s=new am(t,"",u),t.shape.classShape.methods.push(s))),"Interface"===t.shape.classifier&&(i.id.includes("_umlProperty")&&t.shape.interfaceShape.attributes.length>0?(r=new rf(t,"",u),t.shape.classShape.attributes.push(r)):i.id.includes("_umlMethods")&&t.shape.interfaceShape.methods.length>0&&(s=new am(t,"",u),t.shape.interfaceShape.methods.push(s))),"Enumeration"===t.shape.classifier&&i.id.includes("_umlMember")&&t.shape.enumerationShape.members.length>0){var p=new rb(t,"",u);t.shape.enumerationShape.members.push(p)}t.wrapper.children.indexOf(c.wrapper),this.diagram.enableServerDataBinding(!0),this.diagram.add(c),this.diagram.updateConnectorEdges(t),this.diagram.clearSelection(),this.diagram.select([this.diagram.nameTable[c.id]]),this.diagram.endGroupAction(),this.diagram.startTextEdit()}}},n}(),Boe=function(){function n(){}return n.prototype.findObjectsUnderMouse=function(t,e,i,r,s){var o=[];r&&r instanceof si&&r.nodes.length+r.connectors.length===1&&(r=r.nodes[0]||r.connectors[0]).children&&0===r.children.length&&(i.actualObject=r);for(var a,l,h,c,f,d=r&&r instanceof de&&(r.constraints&qe.ConnectToNearByNode||r.constraints&qe.ConnectToNearByPort)&&r.connectionPadding||0,p={},g=0,v=e.spatialSearch.findObjects(new Ne(t.x-50-d,t.y-50-d,100+d,100+d));g-1&&o.splice(T,1),"UmlClassifier"===y.shape.type&&y.container&&"Stack"===y.container.type&&(T=o.indexOf(e.nameTable[e.nameTable[y.id].wrapper.children[0].id]))>-1&&o.splice(T,1)}for(var P=0;Ps.zIndex&&(t[parseInt(r.toString(),10)]=l),r>0&&i&&a&&(a.isLane||a.isPhase||a.isHeader)&&t[parseInt(r.toString(),10)].zIndex=2)for(var d=t.length-1;d>=0;d--)if(t[parseInt(d.toString(),10)].parentId){var u=rm(t[parseInt(d.toString(),10)],e,""),p=rm(t[d-1],e,""),g=e.nameTable[""+p];g&&u!==p&&e.nameTable[""+u].zIndex=0;f--){d=Jp(e[parseInt(f.toString(),10)],!1),c=Jp(e[parseInt(f.toString(),10)],!0);var g=t[""+l].tool,v=this.findTargetElement(e[parseInt(f.toString(),10)].wrapper,o,t,void 0);if("Draw"===i&&v&&(e[parseInt(f.toString(),10)]instanceof te||e[parseInt(f.toString(),10)]instanceof de)&&!eb(e[parseInt(f.toString(),10)],v)&&(g&&"ConnectorSourceEnd"===g[""+h]&&!Nh(e[parseInt(f.toString(),10)])||g&&"ConnectorTargetEnd"===g[""+h]&&!da(e[parseInt(f.toString(),10)])))return u;if(e[parseInt(f.toString(),10)]instanceof te||e[parseInt(f.toString(),10)]instanceof de&&(Nh(e[parseInt(f.toString(),10)])||xd(d)||da(e[parseInt(f.toString(),10)])||Lh(c)||"PortDraw"===i&&g instanceof Od&&"ConnectorTargetEnd"===g[""+h]&&(da(e[parseInt(f.toString(),10)])||Lh(c))))return u=e[parseInt(f.toString(),10)],p&&(u=this.isTarget(u,t,i)),s.actualObject=u,u}else if("ConnectorTargetEnd"===i&&a){for(f=e.length-1;f>=0;f--)if(c=Jp(e[parseInt(f.toString(),10)],!0),(e[parseInt(f.toString(),10)]instanceof te||e[parseInt(f.toString(),10)]instanceof de)&&(da(e[parseInt(f.toString(),10)])||Lh(c)))return u=e[parseInt(f.toString(),10)],u=this.isTarget(u,t,i),s.actualObject=u,u}else{if(a&&("Drag"===i||t[""+l].tool instanceof ua)){var y=0;for(f=0;f=S.zIndex?u:S,y=Math.max(y,S.zIndex)):y=(u=S).zIndex)}return u&&"Bpmn"===u.shape.type&&(t.selectedItems.nodes.length>0&&"Bpmn"===t.selectedItems.nodes[0].shape.type||(u=null)),u&&(s.actualObject=u),u}if("Select"!==i&&"Pan"!==i||!t[""+l].tool)if("Pan"===i||"LayoutAnimation"===i){for(f=e.length-1;f>=0;f--)if((e[parseInt(f.toString(),10)]instanceof te||e[parseInt(f.toString(),10)]instanceof de)&&(v=this.findTargetElement(e[parseInt(f.toString(),10)].wrapper,o,t,void 0),"Pan"===i||v&&(v.id.match("_icon_content_shape$")||v.id.match("_icon_content_rect$"))))return e[parseInt(f.toString(),10)]}else u=e[e.length-1],s&&u&&(s.actualObject=u);else{for(f=e.length-1;f>=0;f--)if(e[parseInt(f.toString(),10)]instanceof de){var b=e[f-1];if(e[f-1]instanceof te&&b.ports){if((v=this.findTargetElement(b.wrapper,o,t,void 0))&&(v.id.match("_icon_content_shape$")||v.id.match("_icon_content_rect$")))return b;for(var M=0;M=0;s--){var o=t.children[parseInt(s.toString(),10)];if(o&&o.outerBounds.containsPoint(e,r||0))if(o.visible){if(o instanceof Cs){var a=this.findTargetElement(o,e,i);if(a)return a}var l="Clip"===o.style.textOverflow||"Ellipsis"===o.style.textOverflow;if(o.bounds.containsPoint(e,r||0)&&!l)return o;if(t.bounds.containsPoint(e,r||0)&&l)return o}else if(o instanceof Ke&&t&&t.id){var h=void 0;if(t.id.includes("group_container")){var c=t.id.slice(0,-15);h=i.getObject(c)}else h=i.getObject(t.id);if(JI(h,o.id))return o}}return t.bounds.containsPoint(e,r)&&"none"!==t.style.fill?t:null},n}(),Foe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),sf=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},$F=function(n){function t(e,i,r,s){var o=n.call(this,e,i,r,s)||this;return o.objectZIndex=-1,o.zIndexTable={},o.objects=[],o}return Foe(t,n),sf([I("")],t.prototype,"id",void 0),sf([I(!0)],t.prototype,"visible",void 0),sf([I(!1)],t.prototype,"lock",void 0),sf([I()],t.prototype,"objects",void 0),sf([I()],t.prototype,"addInfo",void 0),sf([I(-1)],t.prototype,"zIndex",void 0),t}(Ee),bT=function(n,t,e,i){return new(e||(e=Promise))(function(r,s){function o(h){try{l(i.next(h))}catch(c){s(c)}}function a(h){try{l(i.throw(h))}catch(c){s(c)}}function l(h){h.done?r(h.value):new e(function(c){c(h.value)}).then(o,a)}l((i=i.apply(n,t||[])).next())})},MT=function(n,t){var i,r,s,o,e={label:0,sent:function(){if(1&s[0])throw s[1];return s[1]},trys:[],ops:[]};return o={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function a(h){return function(c){return function l(h){if(i)throw new TypeError("Generator is already executing.");for(;e;)try{if(i=1,r&&(s=2&h[0]?r.return:h[0]?r.throw||((s=r.return)&&s.call(r),0):r.next)&&!(s=s.call(r,h[1])).done)return s;switch(r=0,s&&(h=[2&h[0],s.value]),h[0]){case 0:case 1:s=h;break;case 4:return e.label++,{value:h[1],done:!1};case 5:e.label++,r=h[1],h=[0];continue;case 7:h=e.ops.pop(),e.trys.pop();continue;default:if(!(s=(s=e.trys).length>0&&s[s.length-1])&&(6===h[0]||2===h[0])){e=0;continue}if(3===h[0]&&(!s||h[1]>s[0]&&h[1]1)for(var i=0;i-1)return e[parseInt(i.toString(),10)];return this.diagram.activeLayer},n.prototype.getLayer=function(t){for(var e=this.diagram.layers,i=0;i=0;o--)this.diagram.unSelect(this.diagram.nameTable[s[parseInt(o.toString(),10)]]),this.diagram.remove(this.diagram.nameTable[s[parseInt(o.toString(),10)]]),"default_layer"!==i.id&&this.diagram.activeLayer.id===t&&(this.diagram.activeLayer=this.diagram.layers[this.diagram.layers.length-1]);delete this.diagram.layerZIndexTable[i.zIndex],this.diagram.layers.splice(r,1),"SVG"!==this.diagram.mode&&this.diagram.refreshDiagramLayer()}},n.prototype.moveObjects=function(t,e){this.diagram.startGroupAction();for(var i={},r=[],s=0;s-1){if(r=[],(h=this.diagram.nameTable[""+s]).children)for(var f=0,g=h.children;f0){for(var y=void 0,S=0,b=r;S0)for(var r=0;r0)for(r=0;r0){t=t.concat(this.diagram.selectedItems.connectors);for(var i=0;i0)for(t=t.concat(this.diagram.selectedItems.nodes),i=0;i0){for(var i=0,r=t.shape.activity.subProcess.processes;i0&&this.copyProcesses(this.processTable[""+s])}this.clipboardData.processTable=this.processTable}},n.prototype.group=function(){this.oldSelectedObjects=tm(this.diagram);var e=this.diagram.isProtectedOnChange;this.diagram.protectPropertyChange(!0),this.diagram.diagramActions=this.diagram.diagramActions|ee.Group;var r={};r.id="group"+Qe(),(r=new te(this.diagram,"nodes",r,!0)).children=[];for(var s=this.diagram.selectedItems.nodes.concat(this.diagram.selectedItems.connectors).sort(function(h,c){return h.zIndex-c.zIndex}),o=0;o0){var a=this.diagram.add(r);a&&this.select(a),this.addHistoryEntry({type:"Group",undoObject:r,redoObject:r,category:"Internal"}),this.diagram.diagramActions=this.diagram.diagramActions&~ee.Group,this.diagram.protectPropertyChange(e)}},n.prototype.unGroup=function(t){var i=this.diagram.isProtectedOnChange;this.diagram.protectPropertyChange(!0),this.diagram.diagramActions=this.diagram.diagramActions|ee.Group;var r=[];t?r.push(t):r=this.diagram.selectedItems.nodes,this.diagram.startGroupAction();for(var s=0;s0&&this.diagram.removePorts(o,o.ports),o.annotations&&o.annotations.length>0&&!ce()&&this.diagram.removeLabels(o,o.annotations);for(var c=this.diagram.nameTable[o.parentId],d=o.children.length-1;d>=0;d--)this.diagram.nameTable[o.children[parseInt(d.toString(),10)]].parentId="",this.diagram.deleteChild(this.diagram.nameTable[o.children[parseInt(d.toString(),10)]],o),o.parentId&&o.children[parseInt(d.toString(),10)]&&this.diagram.addChild(c,o.children[parseInt(d.toString(),10)]);this.resetDependentConnectors(o.inEdges,!0),this.resetDependentConnectors(o.outEdges,!1),this.diagram.diagramActions&ee.UndoRedo||this.addHistoryEntry({type:"UnGroup",undoObject:a,redoObject:a,category:"Internal"}),o.parentId&&this.diagram.deleteChild(o,c)}this.diagram.removeNode(o,l),this.clearSelection()}this.diagram.endGroupAction(),this.diagram.diagramActions=this.diagram.diagramActions&~ee.Group,this.diagram.protectPropertyChange(i)},n.prototype.resetDependentConnectors=function(t,e){for(var i=0;i0&&(g=!1)}if(g){var y=this.cloneConnector(p,i);c.push(y),o[h.id]=y.id}}else{var S=this.cloneNode(h,i);if(c.push(S),S){o[h.id]=S.id;var b=h.inEdges;if(b)for(var M=0,w=b;M0)for(var u=0;u0)for(r=t.segments,s=0;s0&&this.diagram.drawingObject&&"Bezier"===this.diagram.drawingObject.type&&(t.segments=[]);var e=this.diagram.add(t);"SVG"!==this.diagram.mode&&this.diagram.refreshDiagramLayer(),this.selectObjects([e]),t&&!NI(this.diagram)&&(this.diagram.tool&=~Ci.DrawOnce,this.diagram.currentDrawingObject=void 0)},n.prototype.enableServerDataBinding=function(t){this.diagram.enableServerDataBinding(t)},n.prototype.addText=function(t,e){var i=this.diagram.findElementUnderMouse(t,e,this.diagram);this.diagram.startTextEdit(t,i instanceof ni?i.id.split("_")[1]:void 0)},n.prototype.isUserHandle=function(t){var e=this.diagram.selectedItems;if(e.wrapper&&qr(e.constraints,"UserHandle"))for(var i=0,r=e.userHandles;i0&&t[0]&&t[0].isLane)for(s=this.diagram.getObject(t[0].parentId),t[0].shape.header=[],a=0;a1||e&&1===t.length)){if(1!==t.length)return[2];this.clearSelection()}if(!(u||d||1!==t.length||e&&Xa(this.diagram)))return this.clearSelection(),[2]}if(!r.cancel){for(p=0;p0||e)&&f.children&&!f.parentId)for(g=0;g0||e,!0)}else this.select(f,p>0||e,!0);void 0===i&&(i=c),r={oldValue:i||[],newValue:this.getSelectedObject(),cause:this.diagram.diagramActions,state:"Changed",type:"Addition",cancel:!1},this.diagram.renderSelector(e||t&&t.length>1),ce()||this.diagram.triggerEvent(Ce.selectionChange,r),this.diagram.enableServerDataBinding(!0)}return[2]})})},n.prototype.findParent=function(t){return t.parentId&&this.findParent(t=this.diagram.nameTable[t.parentId]),t},n.prototype.selectProcesses=function(t){if(this.hasProcesses(t))for(var e=t.shape.activity.subProcess.processes,i=0;i0)},n.prototype.select=function(t,e,i){var r=this.getObjectLayer(t.id);if(Dd(t)&&!(t instanceof si)&&!_r(this.diagram,t)&&r&&!r.lock&&r.visible&&t.wrapper.visible){(e=!!Xa(this.diagram)&&e)||this.clearSelection(),this.diagram.enableServerDataBinding(!1);var s=this.diagram.selectedItems;if(t instanceof te?s.nodes.push(t.isHeader?this.diagram.nameTable[t.parentId]:t):s.connectors.push(t),s.selectedObjects.push(t),e)s.wrapper.rotateAngle=s.rotateAngle=0,s.wrapper.children.push(t.wrapper);else if(s.init(this.diagram),1===s.nodes.length&&0===s.connectors.length){var l=_x(this.diagram,s);l&&(s.wrapper.children[0]=l),s.rotateAngle=s.nodes[0].rotateAngle,s.wrapper.rotateAngle=s.nodes[0].rotateAngle,s.wrapper.pivot=s.nodes[0].pivot}i||this.diagram.renderSelector(e),this.diagram.enableServerDataBinding(!0)}},n.prototype.labelSelect=function(t,e){this.oldSelectedObjects=tm(this.diagram);var i=this.diagram.selectedItems,r=this.diagram.allowServerDataBinding;this.diagram.allowServerDataBinding=!1,i.nodes=i.connectors=[],this.diagram.allowServerDataBinding=r,t instanceof te?i.nodes[0]=t:i.connectors[0]=t,i.annotation=this.findTarget(e,t),i.init(this.diagram),this.diagram.renderSelector(!1)},n.prototype.unSelect=function(t){var e=this.diagram.selectedItems.nodes.concat(this.diagram.selectedItems.connectors),i=e.filter(function(a){return a.id!==t.id}),r={oldValue:e,newValue:i,cause:this.diagram.diagramActions,state:"Changing",type:"Removal",cancel:!1};if(this.diagram.currentSymbol||ce()||this.diagram.triggerEvent(Ce.selectionChange,r),_r(this.diagram,t)){var s=this.diagram.selectedItems,o=void 0;t instanceof te?(o=s.nodes.indexOf(t,0),s.nodes.splice(o,1)):(o=s.connectors.indexOf(t,0),s.connectors.splice(o,1)),o=s.selectedObjects.indexOf(t,0),s.selectedObjects.splice(o,1),(r={oldValue:e,newValue:i,cause:this.diagram.diagramActions,state:"Changed",type:"Removal",cancel:(r={oldValue:e,newValue:i,cause:this.diagram.diagramActions,state:"Changed",type:"Removal",cancel:!1}).cancel}).cancel||(o=s.wrapper.children.indexOf(t.wrapper,0),s.wrapper.children.splice(o,1),this.diagram.updateSelector(),this.diagram.currentSymbol||this.diagram.triggerEvent(Ce.selectionChange,r))}},n.prototype.moveSvgNode=function(t,e){var i=xt(e+"_groupElement",this.diagram.element.id),r=xt(t+"_groupElement",this.diagram.element.id);i.parentNode.insertBefore(r,i)},n.prototype.moveAfterSvgNode=function(t,e){var i=xt(e+"_groupElement",this.diagram.element.id),r=xt(t+"_groupElement",this.diagram.element.id);i.insertAdjacentElement("afterend",r)},n.prototype.sendLayerBackward=function(t){var e=this.getLayer(t);if(e&&0!==e.zIndex){var i=e.zIndex;if("SVG"===this.diagram.mode){var r=e.objects,s=this.getLayer(this.diagram.layerZIndexTable[i-1]).objects[0];if(s)for(var o=0,a=r;od&&"SwimLane"!==f.shape.type){var S=$(f);f.zIndex=d-((-1!==i.indexOf(f)?i.indexOf(f):0)+1),f.children&&(d=this.findLowestZIndex(f,c)||d),this.triggerOrderCommand(S,f,f),f.children&&this.updateGroupZindex(f,"SendToBack",d)}else"SwimLane"===f.shape.type&&(y=this.swapZIndexObjects(a,h,r,g));if("SVG"===this.diagram.mode){for(var M="SwimLane"!==this.diagram.nameTable[""+r].shape.type?d:y,w=h[parseInt(M.toString(),10)];!w&&Md)&&(d=p.zIndex)}for(var f=JSON.parse(JSON.stringify(l)),v=Number(Object.keys(l).sort(function(wo,Hl){return Number(wo)-Number(Hl)}).reverse()[0]),y=this.diagram.nameTable[""+e].zIndex,S=[],M=0;M<=v;M++)S.push(l[parseInt(M.toString(),10)]);if("SwimLane"===this.diagram.nameTable[""+e].shape.type)for(var C=v;C>=y;C--)if(l[parseInt(C.toString(),10)]&&this.diagram.nameTable[l[parseInt(C.toString(),10)]].parentId!==e){v=C;break}var D=this.diagram.nameTable[""+e];if(D.zIndexx&&(x=L.zIndex)}}else x=d;D.zIndex=x+((-1!==r.indexOf(D)?r.indexOf(D):0)+1),this.triggerOrderCommand(A,D,D)}else if("SwimLane"===D.shape.type){for(var O=0,N=-1,T=0,P=0,_=JSON.parse(JSON.stringify(l)),B=0;B<=y;B++)if(l[parseInt(B.toString(),10)]&&this.diagram.nameTable[l[parseInt(B.toString(),10)]].parentId===e&&-1===N){N=B,T=B;break}for(var j=0;j<=v;j++)f[parseInt(j.toString(),10)]&&f[parseInt(j.toString(),10)]!==e&&this.diagram.nameTable[f[parseInt(j.toString(),10)]].parentId!==e&&this.diagram.nameTable[f[parseInt(j.toString(),10)]].zIndex>=this.diagram.nameTable[""+e].zIndex&&O++;for(var ue=N,pe=0;pe<=O;pe++){for(;!l[parseInt(ue.toString(),10)];)ue++;P=this.diagram.nameTable[l[parseInt(ue.toString(),10)]].zIndex,ue++}for(var Me=P;Me<=v;Me++){for(;!_[parseInt(N.toString(),10)];)N++;for(;!l[parseInt(Me.toString(),10)];)Me++;l[parseInt(Me.toString(),10)]=_[parseInt(N.toString(),10)],this.diagram.nameTable[l[parseInt(Me.toString(),10)]].zIndex=Me,N++}l[parseInt(v.toString(),10)]=this.diagram.nameTable[""+e].id,this.diagram.nameTable[""+e].zIndex=v,ue=y+1;for(var De=T,xe=0;xe0&&("Native"===cr[0].shape.type||"HTML"===cr[0].shape.type)){for(Mi.parentNode.removeChild(Mi),De=0;De0?r[0]:null},n.prototype.findLowestZIndex=function(t,e){var r=this.diagram.nodes.filter(function(s){return-1!==e.indexOf(s.id)}).filter(function(s){return""===s.parentId&&s.id!==t.id}).map(function(s){return s.zIndex});return r.sort(function(s,o){return s-o}),r.length>0?r[0]:null},n.prototype.triggerOrderCommand=function(t,e,i){var s={zIndex:$(t).zIndex},o={zIndex:e.zIndex},a={element:i,cause:this.diagram.diagramActions,diagramAction:this.diagram.getDiagramAction(this.diagram.diagramActions),oldValue:s,newValue:o};this.diagram.triggerEvent(Ce.propertyChange,a)},n.prototype.checkGroupNode=function(t,e,i){return i[""+e].parentId===i[""+t].parentId},n.prototype.sortByZIndex=function(t,e,i){if("BringForward"===i){var r=e||"zIndex";t=t.sort(function(o,a){return a[""+r]-o[""+r]})}else{var s=e||"zIndex";t=t.sort(function(o,a){return o[""+s]-a[""+s]})}return t},n.prototype.orderCommands=function(t,e,i){var r=this,s=e.nodes;if(s=s.concat(e.connectors),t)if("SendBackward"===i)for(var o=0;oa}),S=v.filter(function(D){return D0?Math.max.apply(Math,S):a,M=y.length>0?Math.min.apply(Math,y):a;if(a!==M){var w=c.zIndexTable[parseInt(M.toString(),10)],C=c.zIndexTable[parseInt(a.toString(),10)];this.moveSvgNode(C,w)}else"SendToBack"===i&&(w=c.zIndexTable[parseInt(a.toString(),10)],C=c.zIndexTable[parseInt(b.toString(),10)],this.moveAfterSvgNode(w,C))}}else this.diagram.refreshCanvasLayers()}},n.prototype.sendForward=function(t){var e=this;if(this.diagram.protectPropertyChange(!0),Xa(this.diagram)||t){$(t||(this.diagram.selectedItems.nodes.length?this.diagram.selectedItems.nodes[0]:this.diagram.selectedItems.connectors[0]));var s=t&&t.id,o=this.diagram.layers.indexOf(this.getObjectLayer(s=s||(this.diagram.selectedItems.nodes.length?this.diagram.selectedItems.nodes[0].id:this.diagram.selectedItems.connectors[0].id))),a=$(this.diagram.nameTable),h=(parseInt(o.toString(),10),this.diagram.nameTable[""+s]),c=[],d=this.diagram.spatialSearch.findObjects(h.wrapper.bounds);d.length>2&&(d=this.sortByZIndex(d,void 0,"BringForward"));for(var u=0,p=d;u=0;f--)this.diagram.nameTable[c[parseInt(f.toString(),10)].id].parentId===s&&c.splice(f,1);if(c.length>0){var y=this.diagram.nameTable[c[c.length-1].id];if(y.parentId){var b=rm(y,this.diagram,""),M=this.diagram.nameTable[""+b];M.id!==s&&(c[0]=M)}var w={};for(f=0;f0&&(Object.values(O).forEach(function(ue){ue>=T&&N.push(ue)}),0!==N.length&&this.updateZIndexBySendForward(h,N,o))}var P=[];if(Object.keys(this.changedNodeZIndexes).forEach(function(ue){if((a[""+ue]?a[""+ue].zIndex:null)!==e.changedNodeZIndexes[""+ue]){var De=$(a[""+ue]);P.push(De)}}),this.updateLayerZindexTable(o),L.nodes.splice(0,L.nodes.length),P.forEach(function(ue){var pe=$(ue);L.nodes.push(pe)}),"SVG"===this.diagram.mode){var _=c[c.length-1].id,B=c[c.length-1];B&&!("HTML"===B.shape.type||"Native"===B.shape.type)&&this.moveAfterSvgNode(s,_),this.updateNativeNodeIndex(_,s)}else this.diagram.refreshCanvasLayers();var j=[];Object.keys(this.changedNodeZIndexes).forEach(function(ue){if((a[""+ue]?a[""+ue].zIndex:null)!==e.changedNodeZIndexes[""+ue]){var De=$(e.diagram.nameTable[""+ue]);j.push(De)}});var Q=$(this.diagram.selectedItems);Q.nodes.splice(0,Q.nodes.length),j.forEach(function(ue){var pe=$(ue);Q.nodes.push(pe)}),this.diagram.diagramActions&ee.UndoRedo||this.addHistoryEntry({type:"SendForward",category:"Internal",undoObject:L,redoObject:Q}),this.diagram.endGroupAction()}}this.diagram.protectPropertyChange(!1)},n.prototype.updateZIndexBySendForward=function(t,e,i){var r=$(t);t.zIndex=Math.min.apply(Math,e);var a,s=Math.min.apply(Math,e),o=Math.min.apply(Math,e),l=this.diagram.layers[parseInt(i.toString(),10)].objects,h=this.diagram.nodes.filter(function(S){return-1!==l.indexOf(S.id)});t.children&&this.updateGroupZindex(t,"BringForward",t.zIndex);var c=h.filter(function(S){return S.zIndex===Math.min.apply(Math,e)&&S.id!==t.id});if(c&&c.length>0&&c[0].children){for(var d=Math.min.apply(Math,e),u=0;uo&&g!==t&&g.parentId!==t.id&&c&&c.length>0&&g.parentId!==c[0].id){var v=$(g);g.zIndex=a+1,a++,this.triggerOrderCommand(v,g,g)}var y=g.zIndex;this.changedNodeZIndexes[g.id]=(this.changedNodeZIndexes.hasOwnProperty(g.id),y)}},n.prototype.arrangeZIndexForLowerNodes=function(t,e,i){var r=i.filter(function(o){return o.zIndex<=t&&o.parentId!==e.id});r.sort(function(o,a){return a.zIndex-o.zIndex});for(var s=0;se&&(e=r.zIndex)}return e},n.prototype.sendBackward=function(t){var e=this;if(this.diagram.protectPropertyChange(!0),Xa(this.diagram)||t){$(t||(this.diagram.selectedItems.nodes.length?this.diagram.selectedItems.nodes[0]:this.diagram.selectedItems.connectors[0]));var s=t&&t.id,o=this.diagram.layers.indexOf(this.getObjectLayer(s=s||(this.diagram.selectedItems.nodes.length?this.diagram.selectedItems.nodes[0].id:this.diagram.selectedItems.connectors[0].id))),a=$(this.diagram.nameTable),h=(parseInt(o.toString(),10),this.diagram.nameTable[""+s]),c=[],d=this.diagram.spatialSearch.findObjects(h.wrapper.bounds);d.length>2&&(d=this.sortByZIndex(d));for(var u=0,p=d;uNumber(f.zIndex)&&""===f.parentId&&h.wrapper.bounds.intersects(f.wrapper.bounds)&&c.push(f);for(var f=c.length-1;f>=0;f--)(v=this.diagram.nameTable[c[parseInt(f.toString(),10)].id]).parentId===s&&c.splice(f,1);if(c.length>0){var v;if((v=this.diagram.nameTable[c[c.length-1].id]).parentId){var S=rm(v,this.diagram,""),b=this.diagram.nameTable[""+S];s!==b.id&&(c[c.length-1]=b)}var M={};for(f=0;f0&&(Object.values(L).forEach(function(pe){pe<=N&&O.push(pe)}),0!==O.length&&this.updateZIndexBySendBackward(h,O,o))}var T=[];if(Object.keys(this.changedNodeZIndexes).forEach(function(pe){if((a[""+pe]?a[""+pe].zIndex:null)!==e.changedNodeZIndexes[""+pe]){var xe=$(a[""+pe]);T.push(xe)}}),this.updateLayerZindexTable(o),R.nodes.splice(0,R.nodes.length),T.forEach(function(pe){var Me=$(pe);R.nodes.push(Me)}),"SVG"===this.diagram.mode){var P=c[c.length-1].id,_=c[c.length-1];_&&"HTML"!==_.shape.type&&"Native"!==_.shape.type&&this.moveSvgNode(s,P);var B=this.diagram.nameTable[""+P];B.children&&B.children.length>0?this.updateNativeNodeIndex(s):this.updateNativeNodeIndex(s,P)}else this.diagram.refreshCanvasLayers();var j=[];Object.keys(this.changedNodeZIndexes).forEach(function(pe){if((a[""+pe]?a[""+pe].zIndex:null)!==e.changedNodeZIndexes[""+pe]){var xe=$(e.diagram.nameTable[""+pe]);j.push(xe)}});var Q=$(this.diagram.selectedItems);Q.nodes.splice(0,Q.nodes.length),j.forEach(function(pe){var Me=$(pe);Q.nodes.push(Me)}),this.diagram.diagramActions&ee.UndoRedo||this.addHistoryEntry({type:"SendBackward",category:"Internal",undoObject:R,redoObject:Q}),this.diagram.endGroupAction()}}this.diagram.protectPropertyChange(!1)},n.prototype.updateZIndexBySendBackward=function(t,e,i){var r=$(t);t.zIndex=Math.max.apply(Math,e);var p,s=t.zIndex,o=Math.max.apply(Math,e),a=this.diagram.layers[parseInt(i.toString(),10)].objects,l=this.diagram.nodes.filter(function(S){return-1!==a.indexOf(S.id)}),h=l.filter(function(S){return S.zIndex===Math.max.apply(Math,e)&&S.id!==t.id});if(h&&h.length>0&&h[0].children)for(var c=Math.max.apply(Math,e),d=0;d0&&g.parentId!==h[0].id){var v=$(g);g.zIndex=p-1,p--,this.triggerOrderCommand(v,g,g)}var y=g.zIndex;this.changedNodeZIndexes[""+g.id]=(this.changedNodeZIndexes.hasOwnProperty(g.id),y)}},n.prototype.findLowestChildZIndex=function(t){for(var e=t.zIndex,i=0;i0),this.selectObjects([t],!0))},n.prototype.clearSelection=function(t,e){return bT(this,void 0,void 0,function(){var i,r,s,o;return MT(this,function(a){return i=this.diagram.allowServerDataBinding,this.diagram.enableServerDataBinding(!1),Xa(this.diagram)&&(r=this.diagram.selectedItems,s=this.getSelectedObject(),this.diagram.currentSymbol&&(this.diagram.previousSelectedObject=s),o={oldValue:s,newValue:[],cause:this.diagram.diagramActions,state:"Changing",type:"Removal",cancel:!1},t&&(ce()||this.diagram.triggerEvent(Ce.selectionChange,o)),o.cancel||(r.offsetX=0,r.offsetY=0,r.width=0,r.height=0,r.rotateAngle=0,r.nodes=[],r.connectors=[],r.wrapper=null,r.annotation=void 0,r.selectedObjects=[],this.diagram.clearSelectorLayer(),t&&(o={oldValue:s,newValue:[],cause:this.diagram.diagramActions,state:"Changed",type:"Removal",cancel:!1},ce()||this.diagram.triggerEvent(Ce.selectionChange,o))),this.diagram.enableServerDataBinding(i)),[2]})})},n.prototype.clearSelectedItems=function(){this.clearSelection((this.diagram.selectedItems.nodes?this.diagram.selectedItems.nodes.length:0)+(this.diagram.selectedItems.connectors?this.diagram.selectedItems.connectors.length:0)>0)},n.prototype.removeStackHighlighter=function(){var t=Pl(this.diagram.element.id),e=t.getElementById(t.id+"_stack_highlighter");e&&e.parentNode.removeChild(e)},n.prototype.renderStackHighlighter=function(t,e){var r,s,o,i=this.diagram.selectedItems.nodes[0];if(!e){var a=this.diagram.findObjectsUnderMouse(t.position);if((e=this.diagram.findObjectUnderMouse(a,"Drag",!0))&&!(e.isLane||e.isPhase||e.isHeader))for(var l=0;l0)for(var a=0;a1)if(i){var h=l.segments[0],c=l.segments[1],u=Tc(II(t.wrapper,t.wrapper.corners,t.wrapper.bounds),h.direction),g=Ll({corners:void 0,point:u=Ah(l,0,u,{x:l.sourceWrapper.offsetX,y:l.sourceWrapper.offsetY},!1),margin:void 0,direction:h.direction},{corners:void 0,point:c.points[1],margin:void 0,direction:void 0});h.length=z.distancePoints(g[0],g[1]),c.direction&&c.length&&(c.length=z.distancePoints(g[1],g[2]))}else if(o){switch(l.segments[0].direction){case"Bottom":r=t.wrapper.bounds.bottomCenter.x-e.bottomCenter.x,s=t.wrapper.bounds.bottomCenter.y-e.bottomCenter.y;break;case"Top":r=t.wrapper.bounds.topCenter.x-e.topCenter.x,s=t.wrapper.bounds.topCenter.y-e.topCenter.y;break;case"Left":r=t.wrapper.bounds.middleLeft.x-e.middleLeft.x,s=t.wrapper.bounds.middleLeft.y-e.middleLeft.y;break;case"Right":r=t.wrapper.bounds.middleRight.x-e.middleRight.x,s=t.wrapper.bounds.middleRight.y-e.middleRight.y}this.dragSourceEnd(l,r,s,!0,null,"ConnectorSourceEnd",void 0,void 0,void 0,!(t.parentId&&this.diagram.diagramActions&ee.isGroupDragging))}}},n.prototype.updateEndPoint=function(t,e){var r={sourcePoint:t.sourcePoint,targetPoint:t.targetPoint};t.sourceID&&(r.sourceID=t.sourceID),t.targetID&&(r.targetID=t.targetID),t.sourcePortID&&(r.sourcePortID=t.sourcePortID),t.targetPortID&&(r.targetPortID=t.targetPortID),t.segments&&(r.segments=t.segments),this.diagram.connectorPropertyChange(t,e||{},r),this.diagram.updateSelector()},n.prototype.dragSourceEnd=function(t,e,i,r,s,o,a,l,h,c,d){var u=this.diagram.nameTable[t.id],p={},f=this.checkBoundaryConstraints(e,i,u.wrapper.bounds);if(EI(u)&&f&&"BezierSourceThumb"!==o&&Uv(this.diagram)&&(p=$(p={sourcePoint:u.sourcePoint}),u.sourcePoint.x+=e,u.sourcePoint.y+=i,"ConnectorSourceEnd"===o&&"Orthogonal"===u.type&&this.changeSegmentLength(u,l,h,c),"Bpmn"===u.shape.type&&"Default"===u.shape.sequence&&"Sequence"===u.shape.flow&&this.updatePathElementOffset(u)),"Bezier"===u.type)if(p={sourcePoint:u.sourcePoint},d)this.translateBezierPoints(t,""===o?"ConnectorSourceEnd":o,e,i,d,s,!a);else for(var g=0;g2){var d=z.direction((c=t.segments[2]).points[0],c.points[1]);o.direction===ls(d)?("Right"===o.direction?c.points[0].x=o.points[o.points.length-1].x=l.wrapper.corners.middleRight.x+20:"Left"===o.direction?c.points[0].x=o.points[o.points.length-1].x=l.wrapper.corners.middleLeft.x-20:c.points[0].y=o.points[o.points.length-1].y="Top"===o.direction?l.wrapper.corners.topCenter.y-20:l.wrapper.corners.bottomCenter.y+20,c.direction&&c.length&&(c.length=z.distancePoints(c.points[0],c.points[c.points.length-1])),o.length=z.distancePoints(o.points[0],o.points[o.points.length-1])):o.direction===d&&c.direction&&c.length?("Top"===o.direction||"Bottom"===o.direction?(c.points[0]=o.points[0],c.points[c.points.length-1].x=c.points[0].x):(c.points[0]=o.points[0],c.points[c.points.length-1].y=c.points[0].y),c.length=z.distancePoints(c.points[0],c.points[c.points.length-1]),t.segments.splice(0,2)):o.length=20}else o.length=20;else if(o.length<1)if(""!==t.sourceID){var c;"Right"===a.direction?a.points[a.points.length-1].y=(h=l.wrapper.corners.middleRight).y:"Left"===a.direction?a.points[a.points.length-1].y=(h=l.wrapper.corners.middleLeft).y:a.points[a.points.length-1].x="Top"===a.direction?(h=l.wrapper.corners.topCenter).x:(h=l.wrapper.corners.bottomCenter).x,a.length=z.distancePoints(h,a.points[a.points.length-1]),t.segments.length>2&&(c=t.segments[2]).direction&&c.length&&(c.length=z.distancePoints(a.points[a.points.length-1],c.points[c.points.length-1])),t.segments.splice(0,1)}else t.segments.splice(0,1)}else e&&!i&&t.sourceID!==e.id&&t.segments&&null!==t.segments[0].direction&&e&&e instanceof te&&s&&this.changeSourceEndToNode(t,e),e&&i&&t.sourcePortID!==i&&t.segments&&null!==t.segments[0].direction&&e&&e instanceof te&&s&&this.changeSourceEndToPort(t,e,i)},n.prototype.canConnect=function(t,e){return!(!da(e)||!Nh(e))},n.prototype.changeSourceEndToPort=function(t,e,i){var r=this.diagram.getWrapper(e.wrapper,i),s={x:r.offsetX,y:r.offsetY},o=zo(s,En(e.wrapper),e.wrapper.bounds),a=t.segments[0],l=t.segments[1];if(a.direction!==o){var h=[],c={};if(a.direction===ls(o)){c={};var d=void 0;"Top"===o||"Bottom"===o?(d="Top"===o?{type:"Orthogonal",isTerminal:!0,direction:o,length:Math.abs(a.points[0].y-s.y)}:{type:"Orthogonal",isTerminal:!0,direction:o,length:Math.abs(s.y-a.points[0].y)},c=a.points[0].x>s.x?{type:"Orthogonal",isTerminal:!0,direction:"Right",length:a.points[0].x-s.x}:{type:"Orthogonal",isTerminal:!0,direction:"Left",length:s.x-a.points[0].x}):(d="Right"===o?{type:"Orthogonal",isTerminal:!0,direction:o,length:Math.abs(a.points[0].x-s.x)}:{type:"Orthogonal",isTerminal:!0,direction:o,length:Math.abs(s.x-a.points[0].x)},c=a.points[0].y>s.y?{type:"Orthogonal",direction:"Top",isTerminal:!0,length:a.points[0].y-s.y}:{type:"Orthogonal",direction:"Bottom",isTerminal:!0,length:s.y-a.points[0].y}),h.push(new bi(t,"segments",d,!0)),h.push(new bi(t,"segments",c,!0))}else h.push(new bi(t,"segments",c={type:"Orthogonal",direction:o,length:20,isTerminal:!0},!0));a.direction!==ls(o)&&("Top"===o||"Bottom"===o?(a.points[0].x=s.x,a.points[0].y=a.points[a.points.length-1].y="Top"===o?s.y-20:s.y+20):(a.points[0].y=s.y,a.points[0].x=a.points[a.points.length-1].x="Right"===o?s.x+20:s.x-20),a.length=z.distancePoints(a.points[0],a.points[a.points.length-1]),l.length=z.distancePoints(a.points[a.points.length-1],l.points[l.points.length-1])),t.segments=h.concat(t.segments)}else a.points[0]=s,"Top"===o||"Bottom"===o?a.points[a.points.length-1].x=s.x:a.points[a.points.length-1].y=s.y,a.length=z.distancePoints(a.points[0],a.points[a.points.length-1]),l.length=z.distancePoints(a.points[a.points.length-1],l.points[l.points.length-1])},n.prototype.removeTerminalSegment=function(t,e){for(var i=0;ii.width||"Left"===o.direction&&r.x>=o.points[0].x||"Right"===o.direction&&r.x<=o.points[0].x)o.points[0].y=o.points[o.points.length-1].y=r.y,o.points[0].x=r.x,o.length=z.distancePoints(o.points[0],o.points[o.points.length-1]),a.length=z.distancePoints(o.points[o.points.length-1],a.points[a.points.length-1]);else{var h=void 0;s="Bottom"===(h=a.direction?a.direction:z.direction(a.points[0],a.points[a.points.length-1]))?i.bottomCenter:i.topCenter,a.length&&a.direction&&(a.length="Top"===h?o.points[o.points.length-1].y-(s.y+20):s.y+20-o.points[o.points.length-1].y),o.length=o.points[o.points.length-1].x-s.x,o.direction=o.length>0?"Right":"Left",l.push(new bi(t,"segments",{type:"Orthogonal",direction:h,length:20},!0)),t.segments=l.concat(t.segments)}else r="Bottom"===o.direction?i.bottomCenter:i.topCenter,o.length>i.height||"Top"===o.direction&&r.y>=o.points[0].y||"Bottom"===o.direction&&r.y<=o.points[0].y?(o.points[0].x=o.points[o.points.length-1].x=r.x,o.points[0].y=r.y,o.length=z.distancePoints(o.points[0],o.points[o.points.length-1]),a.length=z.distancePoints(o.points[o.points.length-1],a.points[a.points.length-1])):(s="Left"===a.direction?i.middleLeft:i.middleRight,h=void 0,h=a.direction?a.direction:z.direction(a.points[0],a.points[a.points.length-1]),a.length&&a.direction&&(a.length="Left"===h?o.points[o.points.length-1].x-(s.x+20):s.x+20-o.points[o.points.length-1].x),o.length=o.points[o.points.length-1].y-s.y,o.direction=o.length>0?"Bottom":"Top",l.push(new bi(t,"segments",{type:"Orthogonal",direction:h,length:20},!0)),t.segments=l.concat(t.segments))},n.prototype.translateBezierPoints=function(t,e,i,r,s,o,a){var l=t.segments.indexOf(s),h=t.segments[parseInt(l.toString(),10)],c=l>0?t.segments[l-1]:null,d=null!==c?c.point:t.sourcePoint,u=l===t.segments.length-1?t.targetPoint:h.point;if(h)if("BezierSourceThumb"===e&&(h.vector1.angle||h.vector1.distance)){var p=h.vector1.distance,f=h.vector1.angle;h.vector1={distance:t.distance(d,o),angle:z.findAngle(d,o)},this.translateSubsequentSegment(t,s,!0,h.vector1.distance-p,h.vector1.angle-f)}else"BezierTargetThumb"===e&&(h.vector2.angle||h.vector2.distance)?(p=h.vector2.distance,f=h.vector2.angle,h.vector2={distance:t.distance(u,o),angle:z.findAngle(u,o)},this.translateSubsequentSegment(t,s,!1,h.vector2.distance-p,h.vector2.angle-f)):("ConnectorSourceEnd"===e&&!t.sourceID||"ConnectorTargetEnd"===e&&!t.targetID)&&a&&WI(h.vector1)&&WI(h.vector2)?(z.isEmptyPoint(h.point1)&&(h.bezierPoint1=YI(t.sourcePoint,t.targetPoint)),z.isEmptyPoint(h.point2)&&(h.bezierPoint2=YI(t.targetPoint,t.sourcePoint))):"BezierSourceThumb"===e||"ConnectorSourceEnd"===e&&!a&&WI(h.vector1)?(h.bezierPoint1.x+=i,h.bezierPoint1.y+=r,(!z.isEmptyPoint(h.point1)||a)&&(h.point1={x:h.bezierPoint1.x,y:h.bezierPoint1.y})):("BezierTargetThumb"===e||"ConnectorTargetEnd"===e&&!a&&WI(h.vector2))&&(h.bezierPoint2.x+=i,h.bezierPoint2.y+=r,(!z.isEmptyPoint(h.point2)||a)&&(h.point2={x:h.bezierPoint2.x,y:h.bezierPoint2.y}))},n.prototype.translateSubsequentSegment=function(t,e,i,r,s){var o=t.segments.indexOf(e);parseInt(o.toString(),10),t.bezierSettings.smoothness&gI.SymmetricAngle||(s=null),t.bezierSettings.smoothness&gI.SymmetricDistance||(r=null),(null!=r||null!=s)&&(i?0!==o&&this.updatePreviousBezierSegment(t,o,r,s):o!==t.segments.length-1&&this.updateNextBezierSegment(t,o,r,s))},n.prototype.updatePreviousBezierSegment=function(t,e,i,r){var s=t.segments[e-1],a=(s.vector2.angle+r)%360;a<0&&(a+=360),s.vector2={distance:s.vector2.distance+i,angle:a}},n.prototype.updateNextBezierSegment=function(t,e,i,r){var s=t.segments[e+1],a=(s.vector1.angle+r)%360;a<0&&(a+=360),s.vector1={distance:s.vector1.distance+i,angle:a}},n.prototype.dragTargetEnd=function(t,e,i,r,s,o,a,l){var c,h=this.diagram.nameTable[t.id],d=this.checkBoundaryConstraints(e,i,h.wrapper.bounds);if(DI(h)&&"BezierTargetThumb"!==o&&d&&Uv(this.diagram)){if(c=$(c={targetPoint:h.targetPoint}),h.targetPoint.x+=e,h.targetPoint.y+=i,"ConnectorTargetEnd"===o&&"Orthogonal"===h.type&&h.segments&&h.segments.length>0){var u=h.segments[h.segments.length-2];u&&2===h.segments[h.segments.length-1].points.length&&("Left"===u.direction||"Right"===u.direction?u.points[u.points.length-1].x=h.targetPoint.x:u.points[u.points.length-1].y=h.targetPoint.y,u.length=z.distancePoints(u.points[0],u.points[u.points.length-1]),u.direction=z.direction(u.points[0],u.points[u.points.length-1]))}"Bpmn"===h.shape.type&&"Default"===h.shape.sequence&&"Sequence"===h.shape.flow&&this.updatePathElementOffset(h)}if("Bezier"===h.type)if(c={targetPoint:h.targetPoint},l)this.translateBezierPoints(t,""===o?"ConnectorTargetEnd":o,e,i,l,s,!a);else for(var p=0;p0){if(void 0!==s&&o.segments[parseInt(s.toString(),10)])if("Bezier"===o.type){var a=o.segments[parseInt(s.toString(),10)],l=a.isInternalSegment;l&&null!==o.bezierSettings&&"FreeForm"!==o.bezierSettings.segmentEditOrientation?("Horizontal"===a.orientation?a.point.x+=e:a.point.y+=i,this.updateDirectionalBezierCurve(o)):(a.point.x+=e,a.point.y+=i),l&&(o.isBezierEditing=!0)}else o.segments[parseInt(s.toString(),10)].point.x+=e,o.segments[parseInt(s.toString(),10)].point.y+=i;else for(var h=0;h1){var a=e[1],l=e[2],h={x:.5*(a.x+l.x),y:.5*(a.y+l.y)},c=t.segments[0];c.vector1.angle=Gt(s,a),c.vector1.distance=.5*z.findLength(s,a),c.vector2.angle=Gt(h,a),c.vector2.distance=.5*z.findLength(h,a),c.point=h;var d=t.segments[1];if(d.vector1.angle=Gt(h,l),d.vector1.distance=.5*z.findLength(h,l),t.segments.length>2){var u=e[3],p={x:.5*(l.x+u.x),y:.5*(l.y+u.y)};d.vector2.angle=Gt(p,l),d.vector2.distance=.5*z.findLength(p,l),d.point=p;var f=t.segments[2];if(f.vector1.angle=Gt(p,u),f.vector1.distance=.5*z.findLength(p,u),t.segments.length>3){var g=e[4],v={x:.5*(u.x+g.x),y:.5*(u.y+g.y)};f.vector2.angle=Gt(v,u),f.vector2.distance=.5*z.findLength(v,u),f.point=v;var y=t.segments[3];y.vector1.angle=Gt(v,g),y.vector1.distance=.5*z.findLength(v,g),y.vector2.angle=Gt(o,g),y.vector2.distance=.5*z.findLength(o,g)}else f.vector2.angle=Gt(o,u),f.vector2.distance=.5*z.findLength(o,u)}else d.vector2.angle=Gt(o,l),d.vector2.distance=.5*z.findLength(o,l)}},n.prototype.rotateObjects=function(t,e,i,r,s){r=r||{};var o=Hi();qi(o,i,r.x,r.y);for(var l=0,h=e;l0){this.diagram.protectPropertyChange(!0);var o=t;o.segments=[],this.diagram.connectorPropertyChange(o,{},{segments:o.segments}),this.diagram.protectPropertyChange(!1)}}},n.prototype.updateInnerParentProperties=function(t){var r=this.diagram.isProtectedOnChange;this.diagram.protectPropertyChange(!0);for(var s=this.getAllDescendants(t,[],!1,!0),o=0;o0&&(p=this.diagram.bpmnModule.getChildrenBound(d,d.id,this.diagram),u=d.wrapper.bounds.containsRect(p)),h=d.wrapper.actualSize.width*t,c=d.wrapper.actualSize.height*e,void 0!==d.maxWidth&&0!==d.maxWidth&&(h=Math.min(d.maxWidth,h)),void 0!==d.minWidth&&0!==d.minWidth&&(h=Math.max(d.minWidth,h)),void 0!==d.maxHeight&&0!==d.maxHeight&&(c=Math.min(d.maxHeight,c)),void 0!==d.minHeight&&0!==d.minHeight&&(c=Math.max(d.minHeight,c)),u&&(h=Math.max(h,p.right-d.wrapper.bounds.x),c=Math.max(c,p.bottom-d.wrapper.bounds.y)),t=h/d.actualSize.width,e=c/d.actualSize.height}var f=Hi();o||(o=r);var g=o.wrapper;if(qi(f,-g.rotateAngle,i.x,i.y),Wp(f,t,e,i.x,i.y),qi(f,g.rotateAngle,i.x,i.y),r instanceof te){var d,v=Je(f,{x:(d=r).wrapper.offsetX,y:d.wrapper.offsetY}),y=d.wrapper.offsetX-d.wrapper.actualSize.width*d.pivot.x,S=d.wrapper.offsetY-d.wrapper.actualSize.height*d.pivot.y;if(h>0)if(d.processId){var b=this.diagram.nameTable[d.processId];(!b.maxWidth||d.margin.left+h0)if(d.processId){var M=this.diagram.nameTable[d.processId];(!M.maxHeight||d.margin.top+c0){if(e.dragLimit=e.dragLimit?e.dragLimit:{},e.dragLimit.top||e.dragLimit.bottom||e.dragLimit.left||e.dragLimit.right){var b={minDistance:null};S=this.getRelativeOffset(v,d,b);var M={minDistance:null};g=this.getRelativeOffset(v,y,M),S=null!=b&&M.minDistance0){if(S=y[y.length-1]){var b=void 0;for(b=0;b=e.x-t.dragLimit.left-r.width/2&&i.x<=e.x+t.dragLimit.right+r.width/2&&(s=!0),i.y>=e.y-t.dragLimit.top-r.height/2&&i.y<=e.y+t.dragLimit.bottom+r.height/2&&(o=!0),{x:s,y:o}},n.prototype.updateLabelMargin=function(t,e,i,r,s,o,a){if(i=i||{x:e.offset,y:0},e&&i&&i.x>0&&i.x<1){var l=z.getLengthFromListOfPoints(t.intermediatePoints),h=this.getPointAtLength(l*i.x,t.intermediatePoints,0),c=this.diagram.scrollSettings.currentZoom,d=e.dragLimit?e.dragLimit:{left:0,right:0,top:0,bottom:0};if(d.top||d.bottom||d.left||d.right){this.diagram.getWrapper(t.wrapper,e.id);var p=new Ne(0,0,0,0),f=this.diagram.getWrapper(t.wrapper,e.id);p.x=f.offsetX/c+o,p.y=f.offsetY/c+a,p.width=f.bounds.width/c,p.height=f.bounds.height/c;var g=new Ne(h.x-(d.left||0)-p.width/2,h.y-(d.top||0)-p.height/2,(d.left||0)+(d.right||0)+p.width,(d.top||0)+(d.bottom||0)+p.height);if(g.containsPoint(r));else for(var S=0,b=this.boundsInterSects([h,r],g,!1);S=t){c=t-r,d=z.findAngle(s,a),u=c*Math.cos(d*Math.PI/180),p=c*Math.sin(d*Math.PI/180),o={x:s.x+u,y:s.y+p};break}r+=h,s=a}else s=a;return o},n.prototype.getInterceptWithSegment=function(t,e){for(var o,a,i=[],r=[],s=[],l=z.findLength({x:0,y:0},{x:this.diagram.scroller.viewPortWidth,y:this.diagram.scroller.viewPortHeight}),h=1;h0&&a<=90||a>180&&a<=270?90:-90;r.push(z.transform(t,a+c,l)),r.push(z.transform(t,o+c,l));var p=Jv({x1:s[0].x,y1:s[0].y,x2:s[1].x,y2:s[1].y},{x1:r[0].x,y1:r[0].y,x2:r[1].x,y2:r[1].y});p.enabled&&i.push(p.intersectPt)}return i},n.prototype.getAnnotationChanges=function(t,e){var r={};return r[KI(t,e.id,!0)]={width:e.width,height:e.height,offset:t instanceof te?{x:e.offset.x,y:e.offset.y}:e.offset,rotateAngle:e.rotateAngle,margin:{left:e.margin.left,right:e.margin.right,top:e.margin.top,bottom:e.margin.bottom},horizontalAlignment:e.horizontalAlignment,verticalAlignment:e.verticalAlignment,alignment:t instanceof de?e.alignment:void 0},{annotations:r}},n.prototype.getConnectorPortChanges=function(t,e){var i=function Nse(n,t,e){for(var i=n.ports,r=0;r1&&(v.width=g,v.offset.x=1/S),f>1&&(v.height=f,v.offset.y=1/b)}}e instanceof Nr&&(e.alignment="Center"),l=this.getAnnotationChanges(t,e),t instanceof te?this.diagram.nodePropertyChange(t,a,l):this.diagram.connectorPropertyChange(t,a,l),this.diagram.updateDiagramObject(t)},n.prototype.getSubProcess=function(t){var i,e={nodes:[],connectors:[]};return t instanceof te?i=t.processId:t&&t.nodes&&t.nodes.length&&t.nodes[0].processId&&(i=t.nodes[0].processId),i&&e.nodes.push($(this.diagram.nameTable[i])),e},n.prototype.checkBoundaryConstraints=function(t,e,i,r){var s=this.diagram.pageSettings,o=this.diagram.pageSettings.boundaryConstraints,a=this.diagram.scroller;if("Page"===o||"Diagram"===o){var l=i?void 0:this.diagram.selectedItems.wrapper.bounds;return!!((i?i.right:l.right)+(t||0)<=("Page"===o?s.width:a.viewPortWidth)&&(i?i.left:l.left)+(t||0)>=0&&(i?i.bottom:l.bottom)+(e||0)<=("Page"===o?s.height:a.viewPortHeight)&&(i?i.top:l.top)+(e||0)>=0||"None"!==this.diagram.layout.type&&r)}return!0},n.prototype.dragSelectedObjects=function(t,e){var i=this,r=this.diagram.selectedItems;this.state&&!this.state.backup&&(this.state.backup={},this.state.backup.offsetX=r.offsetX,this.state.backup.offsetY=r.offsetY),r=FI(this.diagram,r)||r;var s=this.diagram.selectedItems.nodes.filter(function(c){return"SwimLane"===c.shape.type});if(s.length>0&&!this.diagram.currentSymbol&&this.diagram.selectedItems.nodes.length>1){var o=this.diagram.selectedItems.nodes.filter(function(c){return""===c.parentId||"SwimLane"!==i.diagram.nameTable[c.parentId].shape.type});if(o.length>0){for(var a=0;a0||l.length>1)&&(o=o.concat(l),this.diagram.selectedItems.nodes.splice(0,this.diagram.selectedItems.nodes.length),o.forEach(function(c){i.diagram.selectedItems.nodes.push(c)}),r=this.diagram.selectedItems,this.diagram.selectedObject.helperObject=void 0)}}if(this.checkBoundaryConstraints(t,e)){this.diagram.diagramActions=this.diagram.diagramActions|ee.PreventZIndexOnDragging|ee.DragUsingMouse;var h=this.diagram.selectedObject.actualObject;return(h&&h instanceof te&&h.isLane&&jx(h,this.diagram)||!h||!h.isLane)&&this.diagram.drag(r,t,e),this.diagram.diagramActions=this.diagram.diagramActions&~(ee.PreventZIndexOnDragging|ee.DragUsingMouse),this.diagram.refreshCanvasLayers(),this.checkHtmlObjectDrag(r),!0}return!1},n.prototype.checkHtmlObjectDrag=function(t){var e=!1;this.diagram.views&&this.diagram.views.length>1&&(t instanceof si?e=t.nodes.some(function(i){return i.shape&&"HTML"===i.shape.type}):t.shape&&"HTML"===t.shape.type&&(e=!0),e&&this.resetOverviewCanvas())},n.prototype.resetOverviewCanvas=function(){for(var t=0,e=this.diagram.views;t0&&(this.layoutAnimateModule.stopCurrentAnimation(this.objectStore[0],e,t),this.objectStore=[]),a=this.diagram.doLayout(),this.objectStore.push(a)),this.canUpdateTemplate=!1,this.diagram.blazorActions&=~on.expandNode,this.diagram.preventNodesUpdate=r,this.diagram.layoutAnimateModule&&this.diagram.organizationalChartModule&&!i)this.diagram.allowServerDataBinding=!1,this.layoutAnimateModule.expand(this.diagram.layout.enableAnimation,a,t,this.diagram);else{var l={element:$(t),state:!!t.isExpanded};this.triggerEvent(Ce.expandStateChange,l),this.diagram.lineRoutingModule&&this.diagram.constraints&rt.LineRouting&&"ComplexHierarchicalTree"!==this.diagram.layout.type&&this.diagram.resetSegments()}return this.diagram.layout.fixedNode=""===o?"":this.diagram.layout.fixedNode,a},n.prototype.getparentexpand=function(t,e,i,r){for(var s,o=0;o0&&(this.diagram.selectedItems.wrapper.rotateAngle=this.diagram.selectedItems.rotateAngle=s.rotateAngle),r instanceof te&&"SwimLane"!==r.shape.type&&!r.isLane&&!r.isPhase&&!r.isHeader)(r.offsetX!==r.wrapper.offsetX||r.offsetY!==r.wrapper.offsetY||r.width!==r.wrapper.width||r.height!==r.wrapper.height||r.rotateAngle!==r.wrapper.rotateAngle)&&(r.offsetX+=o,r.offsetY+=a,r.width+=l,r.height+=h,r.rotateAngle+=c,this.diagram.nodePropertyChange(r,{},{offsetX:r.offsetX,offsetY:r.offsetY,width:r.width,height:r.height,rotateAngle:r.rotateAngle})),e=this.diagram.spatialSearch.findObjects(r.wrapper.outerBounds);else if(r instanceof si)for(var d=0;d30||g.wrapper.outerBounds.topCenter.y-f.wrapper.outerBounds.bottomCenter.y>30)&&this.diagram.lineRoutingModule.refreshConnectorSegments(this.diagram,p,!0)}}this.updateSelector(),this.diagram.protectPropertyChange(!1)}},n.prototype.drawSelectionRectangle=function(t,e,i,r){this.diagram.drawSelectionRectangle(t,e,i,r)},n.prototype.startGroupAction=function(){this.diagram.startGroupAction()},n.prototype.endGroupAction=function(){this.diagram.endGroupAction()},n.prototype.removeChildFromBPmn=function(t,e,i){var r=this.diagram.nameTable[t.id]||t.nodes[0];if(i&&r&&r.processId&&r.processId===i.wrapper.id){var s=$(r);s.processId=r.processId,this.diagram.startGroupAction();var o=this.diagram.nameTable[r.processId].shape.activity.subProcess.processes||[];o.splice(o.indexOf(r.id),1),this.diagram.bpmnModule.removeChildFromBPMN(this.diagram.nameTable[r.processId].wrapper,r.id,this.diagram),this.diagram.nameTable[r.id].processId="",r.offsetX=r.wrapper.offsetX,r.offsetY=r.wrapper.offsetY;var a=$(r);this.addHistoryEntry({type:"PositionChanged",redoObject:{nodes:[a]},undoObject:{nodes:[s]},category:"Internal"}),this.diagram.endGroupAction()}},n.prototype.isDroppable=function(t,e){var i=this.diagram.nameTable[t.id]||t.nodes[0];return i instanceof te&&(!ce()&&"TextAnnotation"===i.shape.shape||("Group"===e.shape.shape&&(e.shape.activity.subProcess.collapsed=!1),!(i&&"Bpmn"===i.shape.type&&(i.processId===e.id||i.id===e.processId||"Bpmn"===e.shape.type&&!(e instanceof de)&&e.shape.activity&&e.shape.activity.subProcess&&e.shape.activity.subProcess.collapsed))))},n.prototype.renderHighlighter=function(t,e,i){if(new Ne,t.target instanceof te||t.target instanceof de||e&&(t.source instanceof te||t.source instanceof de)){var a=this.findTarget(e?t.sourceWrapper:t.targetWrapper,e?t.source:t.target,i,!0),l=void 0;if(a instanceof zd)for(var h=a.id,c=t.target,u=0,p=c.wrapper.children[0].children[0].children[2].children;u0){var r=0;t[0]=this.diagram.nameTable[t[0].id]||t[0];var s="Object"===i?yr(t[0].wrapper):this.diagram.selectedItems.wrapper.bounds,o={nodes:[],connectors:[]},a={nodes:[],connectors:[]};for(r="Object"===i?r+1:r;r0){var i=0,r=0,s=0,o=0,a=0,l=0,h=0,c=0,d={nodes:[],connectors:[]},u={nodes:[],connectors:[]};for(i=0;io.center.y&&(r=n[parseInt(e.toString(),10)],n[parseInt(e.toString(),10)]=n[parseInt(i.toString(),10)],n[parseInt(i.toString(),10)]=r):s.center.x>o.center.x&&(r=n[parseInt(e.toString(),10)],n[parseInt(e.toString(),10)]=n[parseInt(i.toString(),10)],n[parseInt(i.toString(),10)]=r)}}return n}(t,e),i=1;i0){var i=0,r={x:.5,y:.5};t[0]=this.diagram.nameTable[t[0].id]||t[0];var s=yr(t[0].wrapper),o={nodes:[],connectors:[]},a={nodes:[],connectors:[]};for(i=1;ii.zIndex){for(var s=this.diagram.layers.indexOf(this.diagram.getActiveLayer()),o=this.diagram.layers[parseInt(s.toString(),10)].zIndexTable,a=JSON.parse(JSON.stringify(o)),l=i.zIndex,h=r.zIndex,c=h;c>=l;c--)l!==c?o[c-1]?(o[parseInt(c.toString(),10)]=o[c-1],this.diagram.nameTable[o[parseInt(c.toString(),10)]].zIndex=c):(o[c-1]=o[parseInt(c.toString(),10)],this.diagram.nameTable[o[c-1]].zIndex=c,delete o[parseInt(c.toString(),10)]):this.swapZIndexObjects(h,o,r.id,a);"SVG"===this.diagram.mode?(this.moveSvgNode(e.parentId,i.id),this.updateNativeNodeIndex(e.parentId,i.id)):this.diagram.refreshCanvasLayers()}},n.prototype.findLeastIndexConnector=function(t,e,i){for(var r=0;rs.zIndex&&(i=s)}return i},n.prototype.findLeastIndexObject=function(t,e){var i=t;return t instanceof te&&(i=this.findLeastIndexConnector(t.inEdges,e,i),i=this.findLeastIndexConnector(t.outEdges,e,i)),i},n.prototype.checkSelection=function(t,e){var i;if(1===t.nodes.length&&0===t.connectors.length)if(cs(this.diagram,t.nodes[0],!0)){var r=t.nodes[0];if("SwimLane"===(i="SwimLane"===t.nodes[0].shape?t.nodes[0]:this.diagram.nameTable[t.nodes[0].parentId]).shape.type){var s="Horizontal"===i.shape.orientation;(r.isPhase&&(s&&"ResizeSouth"===e||!s&&"ResizeEast"===e)||r.isLane&&(s&&"ResizeEast"===e||!s&&"ResizeSouth"===e))&&R3(this.diagram,i,e)}else if("Grid"===i.container.type)if("Horizontal"===i.container.orientation&&1===r.rowIndex||"Vertical"===i.container.orientation&&r.rowIndex>0&&r.columnIndex>0){if("ResizeSouth"===e)for(var o=0;o1&&(this.diagram.realActions=this.diagram.realActions|$i.hScrollbarMoved,this.scrolled=!0),this.diagram.scrollSettings.horizontalOffset=t},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"verticalOffset",{get:function(){return this.vOffset},set:function(t){this.vOffset=t,Math.abs(this.vOffset-this.diagram.scrollSettings.verticalOffset)>1&&(this.diagram.realActions=this.diagram.realActions|$i.vScrollbarMoved,this.scrolled=!0),this.diagram.scrollSettings.verticalOffset=t},enumerable:!0,configurable:!0}),n.prototype.getBounds=function(){var e=this.diagram.spatialSearch.getPageBounds(0,0);return(e.x<0||e.y<0)&&!this.diagram.pageSettings.multiplePage?this.getPageBounds(void 0,void 0,!0,!0):this.getPageBounds(void 0,void 0,!0)},n.prototype.updateScrollOffsets=function(t,e){var i,r,s=this.getBounds();s.x*=this.currentZoom,s.y*=this.currentZoom,s.width*=this.currentZoom,s.height*=this.currentZoom,i=Math.max(0,t-s.left),r=Math.max(0,e-s.top),void 0!==t&&void 0!==e?(this.horizontalOffset=i,this.verticalOffset=r,this.diagram.setOffset(i,r)):this.diagram.setOffset(-this.horizontalOffset-s.x,-this.verticalOffset-s.y),this.transform={tx:Math.max(this.horizontalOffset,-s.left)/this.currentZoom,ty:Math.max(this.verticalOffset,-s.top)/this.currentZoom,scale:this.currentZoom}},n.prototype.setScrollOffset=function(t,e){this.scrolled=!1;var i=this.getBounds();i.x*=this.currentZoom,i.y*=this.currentZoom,i.width*=this.currentZoom,i.height*=this.currentZoom;var r=-i.left,s=-i.top,o=!1,a=this.viewPortWidth*this.currentZoom,l=this.viewPortHeight*this.currentZoom,h=r-t;if(h!==this.horizontalOffset){rh?this.horizontalOffset-=t:this.horizontalOffset=h,o=!0);var c=Math.max(i.right+this.vScrollSize,a);if(!o&&c<-h+this.viewPortWidth){var d=-h+a-this.vScrollSize,u=-this.horizontalOffset+a-this.vScrollSize;this.horizontalOffset=dd-u?h:-(i.right+this.vScrollSize-a),o=!0}o||(this.horizontalOffset=r-t)}o=!1;var p=s-e;if(p!==this.verticalOffset){sp?this.verticalOffset-=e:this.verticalOffset=p,o=!0);var f=Math.max(i.bottom+this.hScrollSize,l);if(!o&&f<-p+l){var g=-p+l-this.hScrollSize,v=-this.verticalOffset+l-this.hScrollSize;this.verticalOffset=gg-v?p:-(i.bottom+this.hScrollSize-l),o=!0}o||(this.verticalOffset=s-e)}this.transform={tx:Math.max(this.horizontalOffset,-i.left)/this.currentZoom,ty:Math.max(this.verticalOffset,-i.top)/this.currentZoom,scale:this.currentZoom},this.setSize()},n.prototype.getObjects=function(t,e){for(var i=[],r=0;r0){for(var l=0;l0){h.push(i[parseInt(o.toString(),10)].id);for(var d=0;d=e.bottom&&(l=0),-this.horizontalOffset<=e.x&&-this.horizontalOffset+this.viewPortWidth>=e.right&&(a=0),this.hScrollSize=a,this.vScrollSize=l;var h=this.diagramWidth,c=this.diagramHeight;this.diagramWidth=Math.max(e.right,-this.horizontalOffset+this.viewPortWidth-l)-i,this.diagramHeight=Math.max(e.bottom,-this.verticalOffset+this.viewPortHeight-a)-r,(h!==this.diagramWidth||c!==this.diagramHeight)&&"Diagram"!==this.diagram.scrollSettings.scrollLimit&&this.diagram.setSize(this.diagramWidth,this.diagramHeight),"Diagram"===this.diagram.scrollSettings.scrollLimit&&(h===this.diagramWidth&&c===this.diagramHeight&&1===this.currentZoom||this.diagram.diagramActions&&t&&(!this.diagram.diagramActions||!t||0===this.verticalOffset&&this.verticalOffset!==t.y||0===this.horizontalOffset&&this.horizontalOffset!==t.x)?t&&h===this.diagramWidth&&c===this.diagramHeight&&(this.diagram.diagramCanvas.scrollHeight>this.viewPortHeight&&t.y<0&&this.horizontalOffset===t.x&&0===this.verticalOffset||this.diagram.diagramCanvas.scrollWidth>this.viewPortWidth&&t.x<0&&this.verticalOffset===t.y&&0===this.horizontalOffset)&&(this.verticalOffset=t.y,this.horizontalOffset=t.x,this.transform={tx:Math.max(t.x,-e.left)/this.currentZoom,ty:Math.max(t.y,-e.top)/this.currentZoom,scale:this.currentZoom}):(this.diagram.scrollActions&ca.Interaction&&t&&(this.transform={tx:Math.max(t.x,-e.left/this.currentZoom)/this.currentZoom,ty:Math.max(t.y,-e.top/this.currentZoom)/this.currentZoom,scale:this.currentZoom},this.horizontalOffset=t.x,this.verticalOffset=t.y),this.diagram.setSize(this.diagramWidth,this.diagramHeight),!(this.diagram.scrollActions&ca.PropertyChange)&&t&&(this.horizontalOffset=t.x,this.verticalOffset=t.y,this.transform={tx:Math.max(t.x,-e.left)/this.currentZoom,ty:Math.max(t.y,-e.top)/this.currentZoom,scale:this.currentZoom}))),this.diagram.transformLayers(),this.diagram.element.style.overflow="hidden"},n.prototype.setViewPortSize=function(t,e){this.viewPortWidth=t,this.viewPortHeight=e},n.prototype.getPageBounds=function(t,e,i,r){var o,s=new Ne;if("Content"===e||r||null===this.diagram.pageSettings.width||null===this.diagram.pageSettings.height){var u=t?void 0:0;o=this.diagram.spatialSearch.getPageBounds(u,u)}else{var a=this.diagram.pageSettings.width,l=this.diagram.pageSettings.height,h=0,c=0;if(this.diagram.pageSettings.multiplePage){if((s=this.diagram.spatialSearch.getPageBounds(0,0)).right>a&&(a*=d=Math.ceil(s.right/a)),s.bottom>l&&(l*=d=Math.ceil(s.bottom/l)),s.left<0&&Math.abs(s.left)>h){var d=Math.ceil(Math.abs(s.left)/this.diagram.pageSettings.width);h=this.diagram.pageSettings.width*d}s.top<0&&Math.abs(s.top)>c&&(d=Math.ceil(Math.abs(s.top)/this.diagram.pageSettings.height),c=this.diagram.pageSettings.height*d)}o=new Ne(-h,-c,a+h,l+c)}if(i){var p=this.diagram.scrollSettings.padding;o.x-=p.left,o.y-=p.top,o.width+=p.left+p.right,o.height+=p.top+p.bottom}return o},n.prototype.getPageBreak=function(t){for(var e=0,i=0,r=-1,s=[],c=this.diagram.pageSettings.margin.left,d=this.diagram.pageSettings.margin.right,u=this.diagram.pageSettings.margin.top,p=this.diagram.pageSettings.margin.bottom,f=1,g=1;t.width>e;)(e+=this.diagram.pageSettings.width?this.diagram.pageSettings.width:t.width)===this.diagram.pageSettings.width&&(s[++r]={x1:t.left+c,y1:t.top+u,x2:t.left+c,y2:t.bottom-p}),ei;)(i+=this.diagram.pageSettings.height?this.diagram.pageSettings.height:t.height)===this.diagram.pageSettings.height&&(s[++r]={x1:t.left+c,y1:t.top+u,x2:t.right-d,y2:t.top+u}),i=this.diagram.scrollSettings.minZoom||l||t>=1)){this.currentZoom*=t;var c=this.getPageBounds(void 0,void 0,!0);c.x*=this.currentZoom,c.y*=this.currentZoom;var d=Hi();Wp(d,t,t,r.x,r.y),qB(d,e||0,i||0),mx(h,d);var u=Je(h,{x:0,y:0});if(1===t&&(u=this.applyScrollLimit(u.x,u.y,s,o,a)),a=-c.y>=u.y&&-c.x>=u.x&&a,(this.diagram.scrollActions&ca.PropertyChange||!(this.diagram.scrollActions&ca.Interaction)||"Diagram"!==this.diagram.scrollSettings.scrollLimit||a)&&(this.transform={tx:Math.max(u.x,-c.left)/this.currentZoom,ty:Math.max(u.y,-c.top)/this.currentZoom,scale:this.currentZoom},this.horizontalOffset=u.x,this.verticalOffset=u.y),this.setSize(u),"SVG"!==this.diagram.mode&&Ds(this.diagram)&&this.diagram.scroller.virtualizeElements(),"SVG"!==this.diagram.mode&&!Ds(this.diagram)&&this.diagram.refreshDiagramLayer(),this.diagram.setOffset(-this.horizontalOffset-c.x,-this.verticalOffset-c.y),QI(this.diagram),this.diagram.views&&this.diagram.views.overview){var p=this.diagram.views.overview,f=p.scrollOverviewRect(p.parent.scroller.horizontalOffset,p.parent.scroller.verticalOffset,p.parent.scroller.currentZoom,!0);p.updateOverviewrect(-f.x,-f.y,f.width,f.height),p.updateView(p)}}}},n.prototype.fitToPage=function(t){var e=(t=t||{}).mode,i=t.region,r=t.margin||{},s=t.canZoomIn,o=t.customBounds,a=t.canZoomOut;r.bottom=r.bottom||25,r.top=r.top||25,r.left=r.left||25,r.right=r.right||25;var h,l=o,c=-this.horizontalOffset,d=-this.verticalOffset;if("PageSettings"===(i=i||"PageSettings")&&this.diagram.pageSettings.width&&this.diagram.pageSettings.height||this.diagram.nodes.length>0||this.diagram.connectors.length>0){e=e||"Page","CustomBounds"!==i&&(l=this.getPageBounds(!0,i,!0));var u={x:0,y:0};r.left+r.right>this.viewPortWidth&&(this.viewPortWidth<=100?(r.left=5,r.right=5):(r.left=25,r.right=25)),r.top+r.bottom>this.viewPortHeight&&(this.viewPortHeight<=100?(r.top=5,r.bottom=5):(r.top=25,r.bottom=25)),u.x=(this.viewPortWidth-(r.left+r.right))/l.width,u.y=(this.viewPortHeight-(r.top+r.bottom))/l.height,!s&&l.width-this.horizontalOffset-a+this.viewPortWidth&&(i=o.right-this.viewPortWidth,i+=20),o.x<-a&&(i=o.x),o.bottom>-l+this.viewPortHeight&&(r=o.bottom-this.viewPortHeight,r+=20),o.y<-l&&(r=o.y),this.zoom(1,-this.horizontalOffset-i,-this.verticalOffset-r,null,void 0,e))},n.prototype.bringToCenter=function(t){var e=this.currentZoom,i=new Ne(t.x*e,t.y*e,t.width*e,t.height*e),r=i.x+i.width/2-this.viewPortWidth/2,s=i.y+i.height/2-this.viewPortHeight/2;this.zoom(1,-this.horizontalOffset-(r*=-1),-this.verticalOffset-(s*=-1),null)},n.prototype.applyScrollLimit=function(t,e,i,r,s){if("Infinity"===this.diagram.scrollSettings.scrollLimit&&void 0===i&&!r&&(t=-t,e=-e),"Infinity"!==this.diagram.scrollSettings.scrollLimit){var o=void 0;if("Limited"===this.diagram.scrollSettings.scrollLimit){var a=this.diagram.scrollSettings.scrollableArea;o=new Ne(a.x,a.y,a.width,a.height)}(o=o||(s?this.getPageBounds():this.getPageBounds(!0))).x*=this.currentZoom,o.y*=this.currentZoom,o.width*=this.currentZoom,o.height*=this.currentZoom,void 0!==i&&(t*=-1,e*=-1),r&&(t*=-1,e*=-1);var l=Math.max(o.right,this.viewPortWidth);if(!r&&!(t<=o.x&&(t+this.viewPortWidth>=o.right||t>=o.right-this.viewPortWidth)||t>=o.x&&t+this.viewPortWidth<=l))if(t>=o.x)t=Math.max(o.x,Math.min(t,t-(t+this.viewPortWidth-this.vScrollSize-l)));else{var h=o.right-this.viewPortWidth;t=Math.min(h,o.x)}var c=Math.max(o.bottom,this.viewPortHeight);r||e<=o.y&&e+this.viewPortHeight>=o.bottom||e>=o.y&&e+this.viewPortHeight<=c||(e>=o.y?e=Math.max(o.y,Math.min(e,e-(e+this.viewPortHeight-this.hScrollSize-c))):(h=o.bottom-this.viewPortHeight,e=Math.min(o.y,h))),t*=-1,e*=-1}return{x:t,y:e}},n}(),joe=function(){function n(t,e,i,r,s){this.objects=[],this.left=t,this.top=e,this.width=i,this.height=r,this.spatialSearch=s}return n.prototype.findQuads=function(t,e){null!=this.first&&this.first.isIntersect(t)&&this.first.findQuads(t,e),null!=this.second&&this.second.isIntersect(t)&&this.second.findQuads(t,e),null!=this.third&&this.third.isIntersect(t)&&this.third.findQuads(t,e),null!=this.fourth&&this.fourth.isIntersect(t)&&this.fourth.findQuads(t,e),this.objects.length>0&&e.push(this)},n.prototype.isIntersect=function(t){return!(this.left+this.widtht.right||this.top>t.bottom)},n.prototype.selectQuad=function(){for(var i,t=null,e=this;null!=e;)i=e.getQuad(t),e=i.source,t=i.target||t;return t},n.prototype.getQuad=function(t){var e=this.width/2,i=this.height/2;if(e>=1e3&&i>=1e3){var r=this.left+e,s=this.top+i;if(this.spatialSearch.childRight<=r){if(this.spatialSearch.childBottom<=s)return this.first||((o=new n(this.left,this.top,e,i,this.spatialSearch)).parent=this,this.first=o),{source:this.first};if(this.spatialSearch.childTop>=s)return this.third||((o=new n(this.left,s,e,i,this.spatialSearch)).parent=this,this.third=o),{source:this.third}}else if(this.spatialSearch.childLeft>=r){if(this.spatialSearch.childBottom<=s)return this.second||((o=new n(r,this.top,e,i,this.spatialSearch)).parent=this,this.second=o),{source:this.second};var o;if(this.spatialSearch.childTop>=s)return this.fourth||((o=new n(r,s,e,i,this.spatialSearch)).parent=this,this.fourth=o),{source:this.fourth}}}return this.objects.push(this.spatialSearch.childNode),{target:this}},n.prototype.isContained=function(){return this.spatialSearch.childLeft>=this.left&&this.spatialSearch.childRight<=this.left+this.width&&this.spatialSearch.childTop>=this.top&&this.spatialSearch.childBottom<=this.top+this.height},n.prototype.addIntoAQuad=function(t){var e={};this.spatialSearch.setCurrentNode(t);for(var i=null;!e.isAdded;)i=(e=this.spatialSearch.parentQuad.add(i)).quad;return i},n.prototype.add=function(t){if(t=null,this.isContained())return{isAdded:!0,quad:t=this.selectQuad()};var e=void 0,i=!(0!==this.objects.length||this.first||this.second||this.third||this.fourth),r=2*this.width,s=2*this.height;return this.spatialSearch.childLeft=this.childLeft?(this.pageLeft=this.childLeft,this.leftElement=t,r=!0):t===this.leftElement&&(this.pageLeft=Number.MAX_VALUE,this.findLeft(this.parentQuad),r=!0)),(this.pageTop!==this.childTop||t!==this.topElement)&&(this.pageTop>=this.childTop?(this.pageTop=this.childTop,this.topElement=t,r=!0):t===this.topElement&&(this.pageTop=Number.MAX_VALUE,this.findTop(this.parentQuad),r=!0)),(this.pageBottom!==this.childBottom||t!==this.bottomElement)&&(this.pageBottom<=this.childBottom?(r=!0,this.pageBottom=this.childBottom,this.bottomElement=t):t===this.bottomElement&&(this.pageBottom=-Number.MAX_VALUE,this.findBottom(this.parentQuad),r=!0)),(this.pageRight!==this.childRight||t!==this.rightElement)&&(this.pageRight<=this.childRight?(this.pageRight=this.childRight,this.rightElement=t,r=!0):t===this.rightElement&&(this.pageRight=-Number.MAX_VALUE,this.findRight(this.parentQuad),r=!0)),r}return this.setCurrentNode(null),!1},n.prototype.isWithinPageBounds=function(t){return t.left>=this.pageLeft&&t.right<=this.pageRight&&t.top>=this.pageTop&&t.bottom<=this.pageBottom},n.prototype.findQuads=function(t){var e=[];return this.parentQuad.findQuads(t,e),e},n.prototype.findObjects=function(t){for(var i=[],r=0,s=this.findQuads(t);r=r.outerBounds.left&&(this.pageLeft=r.outerBounds.left,this.leftElement=r)}},n.prototype.findTop=function(t){t.first||t.second?(t.first&&this.findTop(t.first),t.second&&this.findTop(t.second)):(t.third&&this.findTop(t.third),t.fourth&&this.findTop(t.fourth));for(var e=0,i=t.objects;e=r.outerBounds.top&&(this.pageTop=r.outerBounds.top,this.topElement=r)}},n.prototype.setCurrentNode=function(t){if(this.childNode=t,t){var e=t.outerBounds;this.childLeft=Number(e.left),this.childTop=Number(e.top),this.childRight=Number(e.right),this.childBottom=Number(e.bottom)}else this.childLeft=Number.MAX_VALUE,this.childTop=Number.MAX_VALUE,this.childRight=-Number.MAX_VALUE,this.childBottom=-Number.MAX_VALUE},n.prototype.getPageBounds=function(t,e){if(this.pageLeft===Number.MAX_VALUE)return new Ne(0,0,0,0);var i=void 0!==t?Math.min(this.pageLeft,0):this.pageLeft,r=void 0!==e?Math.min(this.pageTop,0):this.pageTop;return new Ne(Math.round(i),Math.round(r),Math.round(this.pageRight-i),Math.round(this.pageBottom-r))},n.prototype.getQuad=function(t){return this.quadTable[t.id]},n}(),Voe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Yoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Voe(t,n),function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);r>3&&s&&Object.defineProperty(t,e,s)}([I(!1)],t.prototype,"preventDefaults",void 0),t}(Ee),Qoe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),JF=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Goe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qoe(t,n),JF([I("")],t.prototype,"action",void 0),JF([I("")],t.prototype,"cursor",void 0),t}(Ee),KF=function(){function n(){this.size=20,this.intermediatePoints=[],this.gridCollection=[],this.startArray=[],this.targetGridCollection=[],this.sourceGridCollection=[],this.considerWalkable=[]}return n.prototype.lineRouting=function(t){var e=t.connectors.length;if(this.renderVirtualRegion(t),e>0)for(var i=0;i=t.right||e.right<=t.left||e.top>=t.bottom||e.bottom<=t.top)},n.prototype.findEndPoint=function(t,e,i){var r,s;if(e&&""!==t.sourcePortID&&t.sourcePortWrapper||!e&&""!==t.targetPortID&&t.targetPortWrapper){s=zo(r=e?{x:t.sourcePortWrapper.offsetX,y:t.sourcePortWrapper.offsetY}:{x:t.targetPortWrapper.offsetX,y:t.targetPortWrapper.offsetY},void 0,e?t.sourceWrapper.bounds:t.targetWrapper.bounds);var o=e?t.sourcePortWrapper.bounds:t.targetPortWrapper.bounds;r=i?"Top"===s?{x:o.topCenter.x,y:o.topCenter.y}:"Left"===s?{x:o.middleLeft.x,y:o.middleLeft.y}:"Right"===s?{x:o.middleRight.x,y:o.middleRight.y}:{x:o.bottomCenter.x,y:o.bottomCenter.y}:{x:o.center.x,y:o.center.y}}else r=e&&this.startNode||!e&&this.targetNode?e?{x:this.startNode.wrapper.offsetX,y:this.startNode.wrapper.offsetY}:{x:this.targetNode.wrapper.offsetX,y:this.targetNode.wrapper.offsetY}:e?{x:t.sourcePoint.x,y:t.sourcePoint.y}:{x:t.targetPoint.x,y:t.targetPoint.y};return r},n.prototype.refreshConnectorSegments=function(t,e,i,r){var h,c,p,f,g,y,S,b,M,w,C,s=e.sourceID,o=e.targetID,a=e.sourcePortID,l=e.targetPortID;if(function Fre(n,t){var e=0;return n.constraints&qe.LineRouting?e=n.constraints&qe.LineRouting:n.constraints&qe.InheritLineRouting&&(e=t.constraints&rt.LineRouting),e}(e,t)||r){this.startNode=t.nameTable[""+s],this.targetNode=t.nameTable[""+o],this.intermediatePoints=[],this.startArray=[],this.targetGridCollection=[],this.sourceGridCollection=[],this.startGrid=void 0,this.targetGrid=void 0;for(var D=0;D0;){var L=this.startArray.pop();if(L){for(D=0;D1&&(e.segments=[]),this.updateConnectorSegments(t,this.intermediatePoints,this.gridCollection,e,i)){this.considerWalkable=[];break e}this.targetGridCollection.splice(this.targetGridCollection.indexOf(O),1),L=this.startArray.pop()}}L&&this.findPath(L)}}}},n.prototype.checkChildNodes=function(t,e){var i=!1,r=!1;if(t.nodeId.length>=1&&!e)for(var s=0;s1&&this.targetGridCollection[0].nodeId.length>1)for(var c=0;c<=1;c++){for(var d=this.targetGridCollection[parseInt(c.toString(),10)].gridX,u=this.targetGridCollection[parseInt(c.toString(),10)].gridY,p=this.targetGridCollection[parseInt(c.toString(),10)].nodeId,f=void 0,g=0;g=e.right&&t.top<=e.top&&t.bottom>=e.bottom},n.prototype.getEndvalue=function(t,e){return this.gridCollection[t.gridX][t.gridY].walkable?t:"left"===e?this.getEndvalue(this.gridCollection[t.gridX-1][t.gridY],e):"right"===e?this.getEndvalue(this.gridCollection[t.gridX+1][t.gridY],e):"top"===e?this.getEndvalue(this.gridCollection[t.gridX][t.gridY-1],e):"bottom"===e?this.getEndvalue(this.gridCollection[t.gridX][t.gridY+1],e):t},n.prototype.changeValue=function(t,e,i){t.walkable||this.considerWalkable.push(t);for(var r,s=0;s<=e;s++)"left"===i?r=this.gridCollection[t.gridX-s][t.gridY]:"right"===i?r=this.gridCollection[t.gridX+s][t.gridY]:"top"===i?r=this.gridCollection[t.gridX][t.gridY-s]:"bottom"===i&&(r=this.gridCollection[t.gridX][t.gridY+s]),r.walkable||this.considerWalkable.push(r)},n.prototype.getIntermediatePoints=function(t){var e;for(this.intermediatePoints=[];t;)this.intermediatePoints.push({x:t.gridX,y:t.gridY}),t=t.parent;this.intermediatePoints.reverse(),this.intermediatePoints.length>=1&&void 0!==this.intermediatePoints[0]&&void 0!==this.intermediatePoints[1]&&(this.intermediatePoints[0].x===this.intermediatePoints[1].x?this.intermediatePoints[0].y=1&&u.length>1&&(g=u[u.length-2].x!==u[u.length-1].x?u[u.length-2].x>u[u.length-1].x?"Left":"Right":u[u.length-2].y>u[u.length-1].y?"Top":"Bottom"),M>=2&&v===g&&u.length>1&&u.splice(u.length-2,1),v=g);if(u&&u.length>1){for(var w=0;wD.x?S.bounds.middleLeft:S.bounds.middleRight),w===u.length-2&&""===r.targetPortID&&y&&(l=C.x>D.x?y.bounds.middleRight:y.bounds.middleLeft),0===w&&b&&(C.x=b.x,C.y=D.y=b.y),w===u.length-2&&l&&(w>0&&r.targetDecorator&&l.x-D.x<0&&Math.abs(l.x-C.x)0&&r.targetDecorator&&l.x-D.x>0&&Math.abs(l.x-C.x)D.y?S.bounds.topCenter:S.bounds.bottomCenter),w===u.length-2&&""===r.targetPortID&&y&&(l=C.y>D.y?y.bounds.bottomCenter:y.bounds.topCenter),0===w&&b&&(C.y=b.y,C.x=D.x=b.x),w===u.length-2&&l&&(w>0&&r.targetDecorator&&l.y-D.y<0&&Math.abs(l.y-C.y)0&&r.targetDecorator&&l.y-D.y>0&&Math.abs(l.y-C.y)D.x?(p="Left",f=C.x-D.x):(p="Right",f=D.x-C.x):C.y>D.y?(p="Top",f=C.y-D.y):(p="Bottom",f=D.y-C.y),o.push({type:"Orthogonal",length:f,direction:p})}}if(o&&o.length>0){var A=o[o.length-1];if(1===o.length&&(A.length-=20),A.length<10&&2===o.length&&(o.pop(),o.length>0&&(o[0].length-=20,A=o[0])),r.targetDecorator&&("Top"===A.direction||"Bottom"===A.direction)&&A.length>r.targetDecorator.height+1||("Right"===A.direction||"Left"===A.direction)&&A.length>r.targetDecorator.width+1)return r.segments=o,s&&t.connectorPropertyChange(r,{},{type:"Orthogonal",segments:o}),!0}return!1},n.prototype.findPath=function(t){for(var e,i=[],r=this.findNearestNeigbours(t,this.gridCollection,!0),s=0;sl)&&(e.x!==t.gridX||e.y!==t.gridY)&&(i.push(e),o.previousDistance=l,o.afterDistance=o.afterDistance||this.manhattan(Math.abs(e.x-this.targetGrid.gridX),Math.abs(e.y-this.targetGrid.gridY)),o.totalDistance=o.previousDistance+o.afterDistance,o.parent=t)}if(i.length>0)for(s=0;st?i*t+e:i*e+t},n.prototype.manhattan=function(t,e){return t+e},n.prototype.findNearestNeigbours=function(t,e,i){var r=[],s=t.parent;if(s){var o=(t.gridX-s.gridX)/Math.max(Math.abs(t.gridX-s.gridX),1),a=(t.gridY-s.gridY)/Math.max(Math.abs(t.gridY-s.gridY),1);0!==o?(this.isWalkable(t.gridX,t.gridY-1,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX][t.gridY-1])&&r.push(e[t.gridX][t.gridY-1]),this.isWalkable(t.gridX,t.gridY+1,!0)&&this.sourceGridCollection.indexOf(e[t.gridX][t.gridY+1])&&r.push(e[t.gridX][t.gridY+1]),this.isWalkable(t.gridX+o,t.gridY,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX+o][t.gridY])&&r.push(e[t.gridX+o][t.gridY])):0!==a&&(this.isWalkable(t.gridX-1,t.gridY,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX-1][t.gridY])&&r.push(e[t.gridX-1][t.gridY]),this.isWalkable(t.gridX+1,t.gridY,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX+1][t.gridY])&&r.push(e[t.gridX+1][t.gridY]),this.isWalkable(t.gridX,t.gridY+a,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX][t.gridY+a])&&r.push(e[t.gridX][t.gridY+a]))}else this.neigbour(t,"top",r,i),this.neigbour(t,"right",r,i),this.neigbour(t,"bottom",r,i),this.neigbour(t,"left",r,i);return r},n.prototype.neigbour=function(t,e,i,r){for(var o,s=1;s>0;){var a="top"===e||"bottom"===e?t.gridX:"left"===e?t.gridX-s:t.gridX+s,l="right"===e||"left"===e?t.gridY:"top"===e?t.gridY-s:t.gridY+s;if((o=this.gridCollection[parseInt(a.toString(),10)][parseInt(l.toString(),10)])&&(r&&-1===this.sourceGridCollection.indexOf(o)||!r&&-1===this.targetGridCollection.indexOf(o)))return i&&this.isWalkable(a,l)&&i.push(o),s;if(!(a>0&&l>0))break;s++}return null},n.prototype.resetGridColl=function(t,e,i){for(var s,r=1;r>0;){var o="top"===e||"bottom"===e?t.gridX:"left"===e?t.gridX-r:t.gridX+r,a="right"===e||"left"===e?t.gridY:"top"===e?t.gridY-r:t.gridY+r;if((s=this.gridCollection[parseInt(o.toString(),10)][parseInt(a.toString(),10)])&&(i&&-1===this.sourceGridCollection.indexOf(s)||!i&&-1===this.targetGridCollection.indexOf(s))){if(this.isWalkable(o,a))break;var l=this.gridCollection[parseInt(o.toString(),10)][parseInt(a.toString(),10)];this.considerWalkable.push(l)}if(!(o>0&&a>0))break;"top"===e||"left"===e?r--:r++}return null},n.prototype.isWalkable=function(t,e,i){if(t>=0&&t=0&&e0?1:-1,this.isWalkable(h,c-1)&&!this.isWalkable(h-a,c-1)||this.isWalkable(h,c+1)&&!this.isWalkable(h-a,c+1)))return{x:t,y:e};if(0!==l){if(l=l>0?1:-1,this.isWalkable(h-1,c)&&!this.isWalkable(h-1,c-l)||this.isWalkable(h+1,c)&&!this.isWalkable(h+1,c-l))return{x:t,y:e};if(this.findIntermediatePoints(h+1,c,h,c,s,o)||this.findIntermediatePoints(h-1,c,h,c,s,o))return{x:t,y:e}}return this.findIntermediatePoints(h+a,c+l,h,c,s,o)},n.prototype.destroy=function(){},n.prototype.getModuleName=function(){return"LineRouting"},n}(),Xoe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),$oe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Xoe(t,n),function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);r>3&&s&&Object.defineProperty(t,e,s)}([I(!0)],t.prototype,"inversedAlignment",void 0),t}(Ee),Zoe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Oe=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},wT=function(n,t,e,i){return new(e||(e=Promise))(function(r,s){function o(h){try{l(i.next(h))}catch(c){s(c)}}function a(h){try{l(i.throw(h))}catch(c){s(c)}}function l(h){h.done?r(h.value):new e(function(c){c(h.value)}).then(o,a)}l((i=i.apply(n,t||[])).next())})},CT=function(n,t){var i,r,s,o,e={label:0,sent:function(){if(1&s[0])throw s[1];return s[1]},trys:[],ops:[]};return o={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function a(h){return function(c){return function l(h){if(i)throw new TypeError("Generator is already executing.");for(;e;)try{if(i=1,r&&(s=2&h[0]?r.return:h[0]?r.throw||((s=r.return)&&s.call(r),0):r.next)&&!(s=s.call(r,h[1])).done)return s;switch(r=0,s&&(h=[2&h[0],s.value]),h[0]){case 0:case 1:s=h;break;case 4:return e.label++,{value:h[1],done:!1};case 5:e.label++,r=h[1],h=[0];continue;case 7:h=e.ops.pop(),e.trys.pop();continue;default:if(!(s=(s=e.trys).length>0&&s[s.length-1])&&(6===h[0]||2===h[0])){e=0;continue}if(3===h[0]&&(!s||h[1]>s[0]&&h[1]0&&((!s.style||!s.style.fill)&&(o.style.fill="transparent"),(!s.style||!s.style.strokeColor)&&(o.style.strokeColor="transparent")),s.shape&&"UmlActivity"===s.shape.type&&qI(s,o),s.shape&&"SwimLane"===s.shape.type&&sF(s,o),r.nodeDefaults&&Ro(o,s,r.nodeDefaults),r.updateAnnotationText(o.annotations);if(e&&e.connectors)for(a=0;e&&e.connectors&&a0&&0===i.nodes.length)this.clearCollection(),a=!0;else{for(var g=0,v=Object.keys(e.nodes);g0&&0===i.connectors.length)this.clearCollection(!0),a=!0;else{for(var C=0,D=Object.keys(e.connectors);C0){this.renderSelector(!0);break}if(e.selectedItems.constraints){this.renderSelector(!0);break}break;case"snapSettings":this.updateSnapSettings(e);break;case"commandManager":this.initCommands();break;case"layout":o=!0;break;case"segmentThumbShape":this.updateSelector();break;case"dataSourceSettings":this.clear(),"None"===this.layout.type?a=!0:(this.initObjects(),o=!0);break;case"tooltip":e3(this);break;case"rulerSettings":this.updateRulerSettings(e);break;case"layers":this.updateLayer(e);break;case"scrollSettings":this.scrollActions|=ca.PropertyChange,this.updateScrollSettings(e),this.scrollActions&=~ca.PropertyChange,this.scrollSettings.horizontalOffset=-this.scroller.horizontalOffset||0,this.scrollSettings.verticalOffset=-this.scroller.verticalOffset||0;break;case"locale":e.locale!==i.locale&&(this.realActions|=$i.PreventDataInit,n.prototype.refresh.call(this),this.realActions&=~$i.PreventDataInit);break;case"contextMenuSettings":if(void 0!==e.contextMenuSettings.showCustomMenuOnly&&(this.contextMenuSettings.showCustomMenuOnly=e.contextMenuSettings.showCustomMenuOnly),void 0!==e.contextMenuSettings.show&&(this.contextMenuSettings.show=e.contextMenuSettings.show),e.contextMenuSettings.items){for(var A=e.contextMenuSettings.items,x=0,R=Object.keys(A);x0){for(var N=[],T=O.ports.length-1;T>=0;T--)"LineDistribution"===O.ports[parseInt(T.toString(),10)].id.split("_")[1]&&N.push(O.ports[parseInt(T.toString(),10)]);this.removePorts(O,N)}}for(T=0;T0)for(var ue=0,pe=Object.keys(e.nodes);ue0)for(var De=0,xe=Object.keys(e.connectors);De=0;o--)this.commandHandler.expandNode(r[parseInt(o.toString(),10)],this,0!==o);this.canLayout&&this.doLayout(),this.lineRoutingModule?this.connectors.sourceID!==this.connectors.targetID&&this.lineRoutingModule.lineRouting(this):this.constraints&rt.LineRouting&&console.warn('[WARNING] :: Module "LineRouting" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),this.validatePageSize(),this.renderPageBreaks(),this.diagramRenderer.renderSvgGridlines(this.snapSettings,Bd(this.element.id),this.scroller.transform,this.rulerSettings,this.hRuler,this.vRuler),this.commandHandler.initSelectorWrapper(),this.notify("initial-load",{}),this.trigger("load"),this.scroller.setSize(),this.scroller.updateScrollOffsets(),this.isRefreshed||this.refreshDiagramLayer(),(this.scrollSettings.verticalOffset>0||this.scrollSettings.horizontalOffset>0)&&this.updateScrollOffset(),X.isDevice&&(this.tool=Ci.ZoomPan|Ci.SingleSelect),this.notify("initial-end",{}),this.isProtectedOnChange=!1,this.tooltipObject=e3(this),this.diagramActions=ee.Render,this.initCommands();var a=document.getElementsByClassName(this.element.id+"_hiddenUserHandleTemplate");(function yoe(n,t,e,i){var r,s,o,a,l,d=document.getElementById(i).ej2_instances[0];if(n&&t){r=FF(n);for(var u=0,p=e.userHandles;u0;)e[0].parentNode.removeChild(e[0]);var i=document.getElementById(this.element.id+"content");i&&this.element.removeChild(i);var r="measureElement";if(window[""+r]){window[""+r].usageCount-=1;var s="measureElementCount";window[""+s]--,0===window[""+s]&&(window[""+r].parentNode.removeChild(window[""+r]),window[""+r]=null)}}window.domTable={};for(var a=0;a1&&(this.callBlazorModel=!1,this.insertBlazorDiagramObjects(this.selectedItems),this.commandHandler.group(),this.callBlazorModel=!0,this.commandHandler.getBlazorOldValues())},t.prototype.unGroup=function(){this.callBlazorModel=!1,this.insertBlazorDiagramObjects(this.selectedItems),this.commandHandler.unGroup(),this.callBlazorModel=!0,this.commandHandler.getBlazorOldValues()},t.prototype.sendToBack=function(){this.commandHandler.sendToBack()},t.prototype.setActiveLayer=function(e){var i=this.commandHandler.getLayer(e);this.activeLayer=i},t.prototype.addLayer=function(e,i){this.commandHandler.addLayer(e,i)},t.prototype.removeLayer=function(e){this.commandHandler.removeLayer(e,ce())},t.prototype.moveObjects=function(e,i){$(this.layers),this.enableServerDataBinding(!1),this.commandHandler.moveObjects(e,i)},t.prototype.layerObjectUpdate=function(){},t.prototype.sendLayerBackward=function(e){this.layerObjectUpdate(),this.commandHandler.sendLayerBackward(e)},t.prototype.bringLayerForward=function(e){this.layerObjectUpdate(),this.commandHandler.bringLayerForward(e)},t.prototype.cloneLayer=function(e){this.commandHandler.cloneLayer(e)},t.prototype.bringToFront=function(){this.commandHandler.bringToFront()},t.prototype.moveForward=function(){this.commandHandler.sendForward()},t.prototype.sendBackward=function(){this.commandHandler.sendBackward()},t.prototype.getObject=function(e){return this.nameTable[""+e]},t.prototype.getNodeObject=function(e){return $(this.nameTable[""+e])},t.prototype.getConnectorObject=function(e){return $(this.nameTable[""+e])},t.prototype.getActiveLayer=function(){return this.activeLayer},t.prototype.nudgeCommand=function(e,i,r){if("object"!=typeof e&&(this.selectedItems.nodes.length||this.selectedItems.connectors.length)>0){var s=void 0;i.type&&"KEYDOWN"===i.type&&(s=i.type),this.nudge(e,void 0,void 0,s)}},t.prototype.nudge=function(e,i,r,s){var o=0,a=0;"Left"===e||"Right"===e?o=("Left"===e?-1:1)*(i||1):a=("Up"===e?-1:1)*(r||1),"KEYDOWN"===s&&(o*=5,a*=5);var h=this.selectedItems,c=this.selectedItems.wrapper.children[0];if(c instanceof ni)this.commandHandler.labelDrag(h.nodes[0],c,o,a);else{var d=$(this.selectedItems);this.protectPropertyChange(!0),this.drag(h,o,a),this.protectPropertyChange(!1);var u={type:"PositionChanged",redoObject:$(this.selectedItems),undoObject:d,category:"Internal"};this.addHistoryEntry(u)}this.refreshCanvasLayers()},t.prototype.insertBlazorDiagramObjects=function(e){},t.prototype.drag=function(e,i,r){if(this.insertBlazorDiagramObjects(e),!(this.bpmnModule&&e instanceof te&&this.bpmnModule.updateAnnotationDrag(e,this,i,r))){if(e instanceof si){if(this.preventConnectorsUpdate=!0,e.nodes&&e.nodes.length){for(var o=0,a=e.nodes;o0&&o.nodes[0].children){this.fromUndo||(this.rotateUsingButton=!0);for(var h=this.commandHandler.getAllDescendants(o.nodes[0],[]),c=0;c0&&o.nodes[0].children){var g={type:"RotationChanged",redoObject:$(e),undoObject:$(o),category:"Internal",childTable:a};this.commandHandler.addHistoryEntry(g),this.commandHandler.updateSelector()}return u},t.prototype.dragSourceEnd=function(e,i,r){this.insertBlazorDiagramObjects(e),this.commandHandler.dragSourceEnd(e,i,r),this.callBlazorModel&&this.commandHandler.getBlazorOldValues()},t.prototype.dragTargetEnd=function(e,i,r){this.insertBlazorDiagramObjects(e),this.commandHandler.dragTargetEnd(e,i,r),this.callBlazorModel&&this.commandHandler.getBlazorOldValues()},t.prototype.findObjectsUnderMouse=function(e,i){return this.eventHandler.findObjectsUnderMouse(e,i)},t.prototype.findObjectUnderMouse=function(e,i,r){return this.eventHandler.findObjectUnderMouse(e,i,r)},t.prototype.findTargetObjectUnderMouse=function(e,i,r,s,o){return this.eventHandler.findTargetUnderMouse(e,i,r,s,o)},t.prototype.findElementUnderMouse=function(e,i,r,s){return this.eventHandler.findElementUnderMouse(e,i,r,s)},t.prototype.findActionToBeDone=function(e,i,r,s){return this.eventHandler.findActionToBeDone(e,i,r,s)},t.prototype.updateConnectorPort=function(e){if(e.ports.length)for(var i=void 0,r=0,s=e.ports;r=0;s--)if(i.push(r[parseInt(s.toString(),10)]),i.length>this.historyManager.stackLimit)return i}else i=r;return i},t.prototype.getEdges=function(e){return e.outEdge?this.nameTable[e.id].outEdges:this.nameTable[e.id].inEdges},t.prototype.getParentId=function(e){return this.nameTable[""+e].parentId},t.prototype.addConnector=function(e){return this.add(e)},t.prototype.UpdateBlazorDiagramModelCollection=function(e,i,r,s){},t.prototype.UpdateBlazorDiagramModel=function(e,i,r,s){},t.prototype.UpdateBlazorLabelOrPortObjects=function(e,i,r,s){},t.prototype.addBlazorDiagramObjects=function(){},t.prototype.removeNodeEdges=function(e,i,r){var s=this.nameTable[""+e],o=r?s.outEdges:s.inEdges;if(o.length>0)for(var a=0;a0)){for(var c=0;c0))}this.removePortEdges(l,a.element.sourcePortID,a.element.id,h)}a.element.targetID&&this.removeNodeEdges(a.element.targetID,a.element.id,!1)}}this.diagramActions=this.diagramActions|ee.PublicMethod,e.id=e.id||Qe();var u=this.activeLayer;if(!a.cancel&&u&&!u.lock){if(u.objects.indexOf(e.id)<0&&!u.lock&&(u.visible||(u.visible=!0,this.dataBind()),u.objects.push(e.id)),fs(e)===de)(r=new de(this,"connectors",e,!0)).status="New",this.nameTable[r.targetID]&&"TextAnnotation"===this.nameTable[r.targetID].shape.shape&&(r.isBpmnAnnotationConnector=!0,r.constraints=r.constraints&~qe.Delete),Ro(r,e,this.connectorDefaults),this.connectors.push(r),this.initObject(r),!1===e.visible&&this.updateElementVisibility(r.wrapper,r,e.visible),this.updateEdges(r),this.insertBlazorConnector(r);else{if(Ro(r=new te(this,"nodes",e,!0),e,this.nodeDefaults),r.parentId=e.parentId?e.parentId:r.parentId,r.umlIndex=e.umlIndex,r.status="New",(o="TextAnnotation"===r.shape.shape)&&!e.isTextAnnotationCopied&&(r.inEdges=e.inEdges?e.inEdges:r.inEdges),this.nodes.push(r),this.initObject(r,u,void 0,i),o&&this.bpmnModule)for(c=0;c-1&&e.parentId&&this.nameTable[e.parentId]&&"UmlClassifier"===this.nameTable[e.parentId].shape.type){var g=this.nameTable[e.parentId];g.children.splice(r.umlIndex,0,r.id),g.wrapper.children.splice(r.umlIndex,0,r.wrapper),g.wrapper.measure(new me),g.wrapper.arrange(g.wrapper.desiredSize),this.updateDiagramObject(g)}}if(a={element:r,cause:this.diagramActions,diagramAction:this.getDiagramAction(this.diagramActions),state:"Changed",type:"Addition",cancel:!1},this.parentObject&&(a.parentId=this.parentObject.id),"helper"!==e.id&&!(this.diagramActions&ee.PreventCollectionChangeOnDragOver)&&this.triggerEvent(Ce.collectionChange,a),!(this.diagramActions&ee.UndoRedo||this.diagramActions&ee.Group||this.diagramActions&ee.PreventHistory)){var v={type:"CollectionChanged",changeType:"Insert",undoObject:$(e),redoObject:$(e),category:"Internal"};this.addHistoryEntry(v)}this.parentObject=void 0,"SVG"===this.mode&&(this.updateSvgNodes(r),this.updateTextElementValue(r),this.updateDiagramObject(r),o&&this.updateDiagramObject(this.nameTable[r.inEdges[0]]),r.shape.activity&&r.shape.activity.subProcess.processes&&r.shape.activity.subProcess.processes.length&&this.updateProcesses(r),this.updateBridging())}}if(this.protectPropertyChange(s),this.resetDiagramActions(ee.PublicMethod),r&&this.layers.length>1&&this.moveNode(r),this.views)for(var S=0,b=this.views;S=0;l--)this.moveSvgNode(a[parseInt(l.toString(),10)])}for(var h=0,c=i;h=0;o--)r[parseInt(o.toString(),10)]===e.id&&r.splice(o,1);for(var a=0;s.ports&&a=0;s--)if(i=this.nameTable[r[parseInt(s.toString(),10)]])if(this.connectorTable[i.id]=$(i),i.isBpmnAnnotationConnector){var o=this.nameTable[i.targetID];this.removeObjectsFromLayer(i);var a=this.connectors.indexOf(i);-1!==a&&this.connectors.splice(a,1),this.removeElements(i),this.removeFromAQuad(i),delete this.nameTable[i.id];var l=this.nameTable[i.sourceID];if(l){var h=l.outEdges.indexOf(i.id);-1!==h&&l.outEdges.splice(h,1)}e.id!==i.targetID&&this.remove(o)}else this.remove(i)},t.prototype.removeObjectsFromLayer=function(e){if(e.children)for(var i=0;i-1&&(_r(this,e)&&this.unSelect(e),this.layers[parseInt(s.toString(),10)].objects.splice(a,1),delete this.layers[parseInt(s.toString(),10)].zIndexTable[this.nameTable[e.id].zIndex])},t.prototype.removeElements=function(e){if("SVG"===this.mode||"Canvas"===this.mode&&"Native"===e.shape.type){var i=xt(e.id+"_groupElement",this.element.id),r=e;if(r.ports&&r.ports.length>0)for(var s=0;s0){l[parseInt(s.toString(),10)].id.indexOf("icon_content")>0&&"SVG"===this.mode&&((h=xt(l[parseInt(s.toString(),10)].id+"_shape_groupElement",this.element.id))&&h.parentNode.removeChild(h),(h=xt(l[parseInt(s.toString(),10)].id+"_rect_groupElement",this.element.id))&&h.parentNode.removeChild(h));for(var c=0,d=this.views;c=0;o--)a.children[parseInt(o.toString(),10)].children&&(l=n.nameTable[a.children[parseInt(o.toString(),10)].id])&&(l.isLane?Gv(n,l):(n.removeDependentConnector(l),n.diagramActions|=ee.PreventHistory,l.constraints&ie.Delete?n.remove(l):U3(n,l,{},!1),n.diagramActions&=~ee.PreventHistory));a&&(i=n.nameTable[a.id])&&Gv(n,i)}}(this,e),!(this.diagramActions&ee.UndoRedo||this.diagramActions&ee.PreventHistory)&&(e instanceof te||e instanceof de)){var o={type:"CollectionChanged",changeType:"Remove",undoObject:$(e),redoObject:$(e),category:"Internal"};this.diagramActions&ee.Clear||e.children&&!e.isLane&&!e.isPhase&&e.children.length>0&&this.undoRedoModule&&"None"===this.layout.type&&(this.historyManager.startGroupAction(),s=!0),(e instanceof te||e instanceof de)&&this.deleteDependentConnector&&this.removeDependentConnector(e),!e.isLane&&!e.isPhase&&!(this.diagramActions&ee.Clear)&&!this.isStackChild(e)&&this.addHistoryEntry(o)}"TextAnnotation"===e.shape.shape&&this.removeDependentConnector(e),e.children&&!e.isLane&&!e.isPhase&&(!(this.diagramActions&ee.UndoRedo)||!ce())&&this.deleteGroup(e),e.parentId&&(this.deleteChild(e,void 0,!0),this.nameTable[e.parentId]&&"UmlClassifier"===this.nameTable[e.parentId].shape.type&&(this.updateDiagramObject(this.nameTable[e.parentId]),this.updateConnectorEdges(this.nameTable[e.parentId])));var a=void 0;this.diagramActions=this.diagramActions|ee.PublicMethod;var l=this.nameTable[e.id];if(l instanceof te?("Bpmn"===l.shape.type&&this.bpmnModule&&this.bpmnModule.removeBpmnProcesses(l,this),(l.isLane||l.isPhase||"SwimLane"===l.shape.type)&&(h=l.isLane||l.isPhase?this.nameTable[l.parentId]:this.nameTable[l.id],l.isLane?B3(this,l,h):l.isPhase&&F3(this,l,h)),-1!==(a=this.nodes.indexOf(l))&&(this.crudDeleteNodes.push(this.nameTable[l.id]),this.nodes.splice(a,1),this.updateNodeEdges(l))):(-1!==(a=this.connectors.indexOf(l))&&(this.crudDeleteNodes.push(this.nameTable[l.id]),this.connectors.splice(a,1)),this.updateEdges(l),this.spliceConnectorEdges(e,!0),this.spliceConnectorEdges(e,!1)),!this.isServerUpdate&&!(this.blazorActions&on.GroupClipboardInProcess)&&this.commandHandler.getBlazorOldValues(),s&&this.historyManager.endGroupAction(),_r(this,l)&&this.unSelect(l),!l.isPhase){if(this.removeObjectsFromLayer(e),this.currentDrawingObject&&(this.currentDrawingObject.wrapper=void 0),delete this.nameTable[e.id],i.length>0&&i[0].id===l.id&&l.parentId){var h,d=this.nameTable[l.parentId];d&&d.isLane&&"SwimLane"===this.nameTable[d.parentId].shape.type&&H3(this,h=this.nameTable[d.parentId],d,l)}this.removeElements(l),this.updateBridging(),"SVG"!==this.mode&&this.refreshDiagramLayer(),this.diagramActions&ee.Clear||(this.removeFromAQuad(l),r={element:e,cause:this.diagramActions,diagramAction:this.getDiagramAction(this.diagramActions),state:"Changed",type:"Removal",cancel:!1},"helper"!==e.id&&this.triggerEvent(Ce.collectionChange,r),this.resetTool())}}}else if(i.length>0){this.undoRedoModule&&(this.historyManager.startGroupAction(),this.blazorActions|=on.GroupingInProgress,s=!0);for(var u=0;u=f.wrapper.bounds.width&&"Horizontal"===f.shape.orientation||this.selectedItems.wrapper.bounds.y<=f.wrapper.bounds.y+g&&this.selectedItems.wrapper.bounds.height>=f.wrapper.bounds.height-g&&"Vertical"===f.shape.orientation)&&(CI(f)||f.shape.lanes.length>1)&&this.remove(i[parseInt(u.toString(),10)])}}else this.remove(i[parseInt(u.toString(),10)])}s&&(this.blazorActions&=~on.GroupingInProgress,this.isServerUpdate=!0,this.commandHandler.getBlazorOldValues(),this.UpdateBlazorDiagramModelCollection(void 0,void 0,void 0,!0),this.historyManager.endGroupAction(),this.isServerUpdate=!1),this.clearSelection()}e&&(CI(e)||this.diagramActions&ee.Clear)||this.diagramActions&ee.UndoRedo||this.diagramActions&ee.PreventHistory||!(e instanceof te||e instanceof de)||(o={type:"ConnectionChanged",undoObject:$(e),redoObject:$(e),category:"Internal"},!e.isLane&&!e.isPhase&&!(this.diagramActions&ee.Clear)&&!this.isStackChild(e)&&this.addHistoryEntry(o)),this.tooltipObject.close()},t.prototype.isStackChild=function(e){var i,r=this.nameTable[e.parentId];if(e&&e.parentId&&r.container&&"Stack"===r.container.type&&"UmlClassifier"!==this.nameTable[e.parentId].shape.type){i=!0;var s={sourceIndex:r.wrapper.children.indexOf(e.wrapper),source:e,target:void 0,targetIndex:void 0};this.diagramActions&ee.UndoRedo||this.addHistoryEntry({type:"StackChildPositionChanged",redoObject:{sourceIndex:void 0,source:e,target:void 0,targetIndex:void 0},undoObject:s,category:"Internal"})}return i},t.prototype.deleteChild=function(e,i,r){var s;if(s="string"==typeof e?e:e.id,(i=i?this.nameTable[i.id]:this.nameTable[e.parentId])&&i.children){for(var o=0;o=0;i--)this.removeLayer(this.layers[parseInt(i.toString(),10)].id);this.commandHandler.addLayer({id:"default_layer",visible:!0,lock:!1,objects:[],zIndex:0,objectZIndex:-1,zIndexTable:{}},null,!0),this.setActiveLayer(this.layers[this.layers.length-1].id)},t.prototype.clearObjects=function(e){var i=[];i=e||(i=i.concat(this.nodes)).concat(this.connectors),this.diagramActions=this.diagramActions|ee.Clear;for(var r=0,s=i;r0||"Text"===e.shape.type))if("Text"===e.shape.type)i=e.wrapper.children[0].id.split("_")[1];else for(var f=e.annotations.length-1;f>=0;f--)e.annotations[parseInt(f.toString(),10)].visibility&&(i=e.annotations[parseInt(f.toString(),10)].id);i&&(u=this.getWrapper(e.wrapper,i))}if(e&&u&&!(u instanceof Jn)&&(!function Qre(n,t){return"Text"===t.shape.type?t.constraints&ie.ReadOnly:t.constraints&(t instanceof de?qe.ReadOnly:ie.ReadOnly)?n.constraints&Lr.InheritReadOnly?1:0:n.constraints&Lr.ReadOnly?1:0}(u,e)||p)){var g=u.style,v=void 0;v=90>(v=u.bounds.width50?50:e.width,u.style.fontSize)),e.parentId&&"UmlClassifier"===this.nameTable[e.parentId].shape.type?(l.width=e.wrapper.bounds.width-20,c=(e.wrapper.bounds.center.x+r.tx)*r.scale-l.width/2*s-2.5,d=(e.wrapper.bounds.center.y+r.ty)*r.scale-l.height/2*s-3,u.style.textAlign="Left"):(l.width=Math.max(l.width,50),c=(u.bounds.center.x+r.tx)*r.scale-l.width/2*s-2.5,d=(u.bounds.center.y+r.ty)*r.scale-l.height/2*s-3),Ho(y,{id:this.element.id+"_editTextBoxDiv",style:"position: absolute;left:"+c+"px;top:"+d+"px;width:"+(l.width+1)*s+"px;height:"+l.height*s+"px; containerName:"+e.id+";"}),Ho(S,{"aria-label":a,id:this.element.id+"_editBox",style:"width:"+(l.width+1)*s+"px;height:"+l.height*s+"px;resize: none;outline: none;overflow: hidden;;font-family:"+g.fontFamily+";font-size:"+g.fontSize*s+"px;text-align:"+u.style.textAlign.toLocaleLowerCase()+";",class:"e-diagram-text-edit"}),S.style.fontWeight=g.bold?"bold":"",S.style.fontStyle=g.italic?"italic":"",S.style.lineHeight=(1.2*g.fontSize+"px;").toString(),S.style.textDecoration=g.textDecoration?g.textDecoration:"",this.activeLabel.parentId=e.id,this.activeLabel.id=i,u.visible=!1,this.updateDiagramObject(e),this.diagramActions=this.diagramActions|ee.TextEdit,this.isTriggerEvent||(E.add(S,"input",this.eventHandler.inputChange,this.eventHandler),E.add(S,"focusout",this.focusOutEdit,this),S.select())}}}},t.prototype.updateConnectorfixedUserHandles=function(e){if(e.fixedUserHandles.length)for(var i=void 0,r=0,s=e.fixedUserHandles;r0&&this.mindMapChartModule.updateLayout(o,this.nameTable,this.layout,l,this.dataSourceSettings.id,this.dataSourceSettings.root),e=!0;else if(this.radialTreeModule)this.radialTreeModule.updateLayout(o,this.nameTable,this.layout,l),e=!0;else if(this.symmetricalLayoutModule)this.symmetricalLayoutModule.maxIteration=this.layout.maxIteration,this.symmetricalLayoutModule.springLength=this.layout.springLength,this.symmetricalLayoutModule.springFactor=this.layout.springFactor,this.symmetricalLayoutModule.updateLayout(o,this.connectors,this.symmetricalLayoutModule,this.nameTable,this.layout,l),e=!0;else if(this.complexHierarchicalTreeModule){this.canDistribute(a,r)&&(this.lineDistributionModule.diagram=this,this.connectors.forEach(function(R){R.obstaclePointCollection=[]}));var c=this.complexHierarchicalTreeModule.getLayoutNodesCollection(this.nodes);c.length>0&&this.complexHierarchicalTreeModule.doLayout(c,this.nameTable,this.layout,l,this),e=!0,this.canDistribute(a,r)&&this.lineDistributionModule.initLineDistribution(this.layout,this)}else this.flowchartLayoutModule?(this.flowchartLayoutModule.updateLayout(this.nodes,this),e=!0):console.warn("[WARNING] :: Module "+("OrganizationalChart"===this.layout.type?"HierarchicalTree":this.layout.type)+" is not available in Diagram component! You either misspelled the module name or forgot to load it.");if(e){this.preventDiagramUpdate=!0;for(var u={},f=0,g=o;f0)for(var S=0;S0)for(var M=0;M0)for(var s=0,o=r.ports;s0&&function wse(n){var t,e,i,r=[];for(t=0;t0&&y.connectors[w].bezierSettings&&y.connectors[w].bezierSettings.allowSegmentsReset&&(y.connectors[w].segments=[]);if(t.connectors=y.connectors||[],t.dataSourceSettings=y.dataSourceSettings||{},t.dataSourceSettings.doBinding=i,t.height=y.height||"100%",t.setNodeTemplate=r,t.getConnectorDefaults=v,t.getNodeDefaults=g,t.getCustomProperty=o,t.mode=y.mode||"SVG",y.nodes)for(w=0;w0)){var r=this.nodes.filter(function(a){return 0===a.inEdges.length})[0],s=this.convertMindmapToMermaid(r,0);i.push(s),this.updateTextDataSource(i,r.outEdges,1),e=(i=i.filter(function(a){return""!==a.trim()})).join("\n")}return e},t.prototype.updateTextDataSource=function(e,i,r){for(var s=0;s0&&this.updateTextDataSource(e,h,r+1),s++}},t.prototype.convertMindmapToMermaid=function(e,i){var r=e.id,o=" ".repeat(2*(i+1)),a=e.annotations.length>0?e.annotations[0].content.replace(/\n/g," "):"",l=o+a,h=o+r;if(e.shape&&"Basic"===e.shape.type){var c=e.shape;"Rectangle"===c.shape?l=h+"["+a+"]":"Ellipse"===c.shape?l=h+"(("+a+"))":"Hexagon"===c.shape&&(l=h+"{{"+a+"}}")}else if(e.shape&&"Flow"===e.shape.type)"Terminator"===e.shape.shape&&(l=h+"("+a+")");else if(e.shape&&"Path"===e.shape.type){var u=e.shape;u.data===this.bangShape?l=h+"))"+a+"((":u.data===this.cloudShape&&(l=h+")"+a+"(")}return l},t.prototype.saveFlowDiagramInMermaidFormat=function(){var e=this,i=[],r="graph TD\n",s={nodes:this.nodes,edges:this.connectors};return s.nodes.reduce(function(a,l){return a[l.id]=l.annotations.length?l.annotations[0].content:"",a},{}),s.edges.forEach(function(a){var l=a.sourceID,h=a.targetID,p=e.nameTable[""+h],f=e.getNodeShape(e.nameTable[""+l]),g=e.getNodeShape(p),v=a.annotations[0]&&""!==a.annotations[0].content?"|"+a.annotations[0].content+"|":"";-1===i.indexOf(l)?i.push(l):f="",-1===i.indexOf(h)?i.push(h):g="";var y=e.arrowType(a);r+=" "+l+f+" "+y+v+" "+h+g+"\n"}),s.nodes.forEach(function(a){r+=" style "+a.id+" fill:"+a.style.fill+",stroke:"+a.style.strokeColor+",stroke-width:"+a.style.strokeWidth+"px;\n"}),r},t.prototype.arrowType=function(e){var i=e.targetDecorator.shape;return e.style.opacity<1?"~~~":""!==e.style.strokeDashArray?"-.->":"Arrow"===i?e.style.strokeWidth>1?"==>":"--\x3e":"None"===i?"---":"--\x3e"},t.prototype.getNodeShape=function(e){var i=e.annotations.length>0?e.annotations[0].content:"",r=e.shape.shape;if(!r){var s=e.shape.data;return"M 0 0 A 1 1 0 0 0 7 0 A 1 1 0 0 0 0 0 M -1 0 A 1 1 0 0 0 8 0 A 1 1 0 0 0 -1 0"===s?"((("+i+")))":"M 0 0 L 1 -1 L 5 -1 L 6 0 L 0 0"===s?"[/"+i+"\\]":"M 0 1 L 0 6 C 2 7 4 7 6 6 L 6 1 C 5 0 1 0 0 1 C 1 2 5 2 6 1"===s?"[("+i+")]":"M 0 0 L 12 0 L 14 2 L 2 2 L 0 0"===s?"[\\"+i+"\\]":"M 0 0 L 5 0 L 4 1 L 1 1 L 0 0"===s?"[\\"+i+"/]":"M 0 0 L 2 -2 L 11 -2 L 13 0 L 11 2 L 2 2 L 0 0"===s?"{{"+i+"}}":">"+i+"]"}switch(r){case"Terminator":return"(["+i+"])";case"Process":default:return"["+i+"]";case"Decision":return"{"+i+"}";case"Parallelogram":return"[/"+i+"/]";case"Ellipse":return"(("+i+"))";case"PreDefinedProcess":return"[["+i+"]]"}},t.prototype.loadDiagramFromMermaid=function(e){this.layout&&"Flowchart"===this.layout.type&&this.flowchartLayoutModule?this.convertMermaidToFlowChart(e):this.layout&&"MindMap"===this.layout.type&&this.mindMapChartModule?this.convertMermaidToMindmap(e):console.warn('[WARNING] :: Module "FlowchartLayout" or "MindMap" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.countLeadingSpaces=function(e){for(var i=0,r=e.length;i0});this.clear(),this.mermaidNodeBaseCollection=[];var r=[],s={text:"",children:[],currentLevel:0,branch:"Left"},o=[],l=!1,h=!1,c=!1;if(i.length>0){for(var d=function(M){var w=i[parseInt(M.toString(),10)],C=0,D="",A=u.countLeadingSpaces(w),x=w.includes('"`');if(h=w.includes('`"'),c=(l=!!x||l)||c?c:0===A&&M>0,l&&h&&!x)return s.text+="\n"+w,l=!1,"continue";if(!x&&l)return s.text+="\n"+w,"continue";if(l=!h&&l,w.length>0&&(/\s/.test(w[0])&&M>0||0===A)){if(-1!==o.findIndex(function(B){return B.space===A.toString()}))for(var L=o.length-1;L>=0;L--){var O=o[parseInt(L.toString(),10)];if((N=parseFloat(O.space))>A)o.splice(L,1);else{if(N=0;L--){var N,T=o[parseInt(L.toString(),10)];if(!((N=parseFloat(T.space))>A)){var P=o[o.length-1];o.push({space:A.toString(),level:P.level+1});break}o.splice(L,1)}C=o[o.length-1].level}D=w.trim().replace(/^[+-]/,"")}var _={text:D,branch:void 0,children:[],currentLevel:0===M?0:C-1};if(r.length>0){for(;r.length>=C&&0!==r.length;)r.pop();r.length>0&&r[r.length-1].children.push(_)}r.push(_),s=_},u=this,p=0;p0){var c=h[h.length-1];c.arrowType=a[2],""!==a[3]&&(c.label&&c.label.some(function(d){return d.trim().length>0})?c.label.push(a[3]):(c.label=[],c.label[c.parentId.length-1]=a[3]))}h.filter(function(d){return d.parentId&&0===d.parentId.length}).forEach(function(d){d.parentId=null}),i=i.concat(h)}}this.createFlowChart(i),this.doLayout(),this.clearHistory()},t.prototype.createFlowChart=function(e){for(var i=[],r=0;r1)for(var h=0;h|---|--\s*.*?\s*-->|~~~|==>|===|==\s*.*?\s*==>|\s*-\.\s*->|\s*-\.\s*-|\s*-\.\s*.*?\s*\.\s*->|\s*-\..*?\.\s*->)(.*)$/);if(l){i=l[1].trim();var h=l[2].trim();r=l[3].trim();var d=h.match(/(-\.|\\-\\-|==|--|~~)(.*?)(\1>|\.->|==>|\\->|~~>)/),u=void 0,p="";o=null!==(u=d?{text:d[2].trim()||null,arrowType:d[1]+d[3]}:{text:null,arrowType:h}).text?u.text:"",s=(p=u.arrowType).includes("--\x3e")?"single-line-arrow":p.includes("---")?"single-line":p.includes("==>")?"double-line-arrow":p.includes("==")?"double-line":p.includes("~~~")?"wiggly-arrow":p.includes("-.->")||p.includes(".->")?"dotted-arrow":p.includes("-.-")||p.includes(".-")?"dotted":"single-line-arrow"}return[i,r,s,o]},t.prototype.parseStyle=function(e,i){if(e.startsWith("style")){var s=e.match(/^style\s+(\w+)\s+fill:([^,]+),stroke:([^,]+),stroke-width:(\d+)px;/);if(s){var c={id:s[1],fill:s[2],stroke:s[3],strokeWidth:parseInt(s[4],10)},d=i.filter(function(u){return u.id===c.id});d[0].color=c.fill,d[0].stroke=c.stroke,d[0].strokeWidth=c.strokeWidth}}},t.prototype.getNodeData=function(e,i,r){for(var s=[],o=null,a=null,l=0,h="",c=function(v){var y=e[parseInt(v.toString(),10)],S=d.splitNested(y);if(S[0].includes("|")){var b=S[0].match(/\|([^|]*)\|/);b&&(h=b[1]);var M=S[0].split("|");M.length>=3&&(S[0]=M[2].trim())}var w=S[0].trim();if(0===v?o=w:a=w,i.find(function(L){return L.id===w}))l++;else{var D=S.length>1?S[1]:S[0],A=d.getShape(D),x=D.replace(/[\\[\]\\(\\)\\{\\}\\{\\}\\/>]/g,"");s.push({id:w,name:x,shape:A,color:"white",parentId:[]})}},d=this,u=0;u"===h?0===s?(r.trim().length>0&&i.push(r.trim()),r=h,o=h,s++):(r+=h,s++):"]"===h||"}"===h||")"===h?1===s&&h===o?(i.push((r+=h).trim()),r="",s--):s>1?(r+=h,s--):r+=h:r+=h}return r.trim().length>0&&i.push(r.trim()),i},t.prototype.getShape=function(e){var i={};return e.startsWith("(((")?i={type:"Path",data:"M 0 0 A 1 1 0 0 0 7 0 A 1 1 0 0 0 0 0 M -1 0 A 1 1 0 0 0 8 0 A 1 1 0 0 0 -1 0"}:e.startsWith("((")?i={shape:"Ellipse",type:"Basic"}:e.startsWith("([")?i={type:"Flow",shape:"Terminator"}:e.startsWith("(")?i={type:"Flow",shape:"Process"}:e.startsWith("[[")?i={type:"Flow",shape:"PreDefinedProcess"}:e.startsWith("[/")?i=e.endsWith("/]")?{type:"Basic",shape:"Parallelogram"}:{type:"Path",data:"M 0 0 L 1 -1 L 5 -1 L 6 0 L 0 0"}:e.startsWith("[(")?i={type:"Path",data:"M 0 1 L 0 6 C 2 7 4 7 6 6 L 6 1 C 5 0 1 0 0 1 C 1 2 5 2 6 1"}:e.startsWith("[\\")?i=e.endsWith("\\]")?{type:"Path",data:"M 0 0 L 12 0 L 14 2 L 2 2 L 0 0"}:{type:"Path",data:"M 0 0 L 5 0 L 4 1 L 1 1 L 0 0"}:e.startsWith("[")?i={type:"Basic",shape:"Rectangle"}:e.startsWith("{{")?i={type:"Path",data:"M 0 0 L 2 -2 L 11 -2 L 13 0 L 11 2 L 2 2 L 0 0"}:e.startsWith("{")?i={type:"Flow",shape:"Decision"}:e.startsWith(">")&&(i={type:"Path",data:"M 0 0 L 8 0 L 8 2 L 0 2 L 2 1 L 0 0"}),i},t.prototype.getDiagramContent=function(e){return this.printandExportModule?this.printandExportModule.getDiagramContent(e):(console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),"")},t.prototype.exportImage=function(e,i){this.printandExportModule?this.printandExportModule.exportImages(e,i):console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.printImage=function(e,i){this.printandExportModule?(i.printOptions=!0,this.printandExportModule.exportImages(e,i)):console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.setStackLimit=function(e){this.undoRedoModule&&e&&(this.historyManager.stackLimit=e,this.undoRedoModule.applyLimit(this.historyManager.currentEntry,e,this,!0))},t.prototype.clearHistory=function(){this.undoRedoModule&&this.undoRedoModule.clearHistory(this)},t.prototype.getDiagramBounds=function(){if(this.printandExportModule){var e=this.printandExportModule.getDiagramBounds("",{});return e.width=e.width>this.scrollSettings.viewPortWidth?e.width+(e.x>0?e.x:0):this.scrollSettings.viewPortWidth,e.height=e.height>this.scrollSettings.viewPortHeight?e.height+(e.y>0?e.y:0):this.scrollSettings.viewPortHeight,e.x=e.x>0?0:e.x,e.y=e.y>0?0:e.y,e}return console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),new Ne},t.prototype.exportDiagram=function(e){return this.printandExportModule?this.printandExportModule.exportDiagram(e):(console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),"")},t.prototype.print=function(e){this.printandExportModule?this.printandExportModule.print(e):console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.addPorts=function(e,i){var s;this.protectPropertyChange(!0),e=this.nameTable[e.id]||e,i.length>1&&this.startGroupAction();for(var o=function(h){if(e.ports.some(function(y){return y.id===i[parseInt(h.toString(),10)].id}))return"continue";if(e instanceof te?(s=new Es(e,"ports",i[parseInt(h.toString(),10)],!0),e.ports.push(s)):e instanceof de&&(s=new xc(e,"ports",i[parseInt(h.toString(),10)],!0),e.ports.push(s)),e.children)for(var c=e.wrapper,d=0;d1&&this.endGroupAction(),e.wrapper.measure(new me(e.width,e.height)),e.wrapper.arrange(e.wrapper.desiredSize),this.updateDiagramObject(e),this.protectPropertyChange(!1)},t.prototype.addConstraints=function(e,i){return e|i},t.prototype.removeConstraints=function(e,i){return e&~i},t.prototype.addNodeLabels=function(e,i){this.addLabels(e,i)},t.prototype.addConnectorLabels=function(e,i){this.addLabels(e,i)},t.prototype.addLabels=function(e,i){this.protectPropertyChange(!0);var s,r=(e=this.nameTable[e.id]||e).wrapper;i.length>1&&this.startGroupAction();for(var o=0;o1&&this.endGroupAction(),e.wrapper.measure(new me(r.width,r.height)),e.wrapper.arrange(r.desiredSize),this.updateDiagramObject(e),this.protectPropertyChange(!1),this.refreshCanvasLayers()},t.prototype.addChildToUmlNode=function(e,i,r){var s,o,a,l,h="NoWrap";"Class"===e.shape.classifier||"Interface"===e.shape.classifier?"Method"===r?(o=new am(e,"",i),"Class"===e.shape.classifier?(e.shape.classShape.methods.push(o),s=e.shape.classShape):"Interface"===e.shape.classifier&&(e.shape.interfaceShape.methods.push(o),s=e.shape.interfaceShape),function Qse(n,t,e,i){if(e.methods&&e.methods.length){var r=e.methods,s="",o="",a=void 0,l=1,h=void 0,c=0,d=0,u=n.shape,g="Class"===u.classifier?u.classShape:u.interfaceShape;1===r.length?g.attributes.length>0?(c=g.attributes.filter(function(w){return w.isSeparator}).length,h=(l=2+g.attributes.length+c)+1,rT(n,t,l)):h=l+1:(c=g.attributes.filter(function(w){return w.isSeparator}).length,d=g.methods.filter(function(w){return w.isSeparator}).length,h=(l=2+g.attributes.length+c+g.methods.length+d)+1);for(var v=0;v1&&this.startGroupAction();for(var r=i.length-1;r>=0;r--)if(e.children&&e.children.length>0){var s=e.wrapper.children.filter(function(o){return o.id===e.id+"group_container"});s&&s.length>0&&this.removelabelExtension(e,i,r,s[0])}else this.removelabelExtension(e,i,r,e.wrapper);i.length>1&&this.endGroupAction(),this.refreshCanvasLayers()},t.prototype.removePortsExtenion=function(e,i,r,s){for(var o=0;o1&&this.startGroupAction();for(var r=i.length-1;r>=0;r--)if(e.children&&e.children.length>0)for(var s=0;s1&&this.endGroupAction()},t.prototype.getSizeValue=function(e,i){var r;return r=e.toString().indexOf("px")>0?e.toString():e.toString().indexOf("%")>0?void 0!==i?"100%":e.toString():e.toString()+"px",i&&(qa(this),r="calc("+r+" - "+i+"px)"),r},t.prototype.renderRulers=function(){this.rulerSettings.showRulers?(function Vne(n){var t=qa(n),i=Tt("div",{id:n.element.id+"_overlapRuler",style:"height:"+t.height+"px;width:"+t.width+"px;position:absolute;left:0;top:0",class:"e-ruler-overlap"});n.element.insertBefore(i,n.element.firstChild)}(this),J3(this,!0),J3(this,!1)):Yx(this)},t.prototype.intOffPageBackground=function(){var e=new me;e=qa(this);var i=document.getElementById(this.element.id+"content"),r=this.getSizeValue(this.width,e.width),s=this.getSizeValue(this.height,e.height),o=this.rulerSettings.showRulers?"width:"+r+"; height:"+s+";top:"+e.height+"px;left:"+e.width+"px;overflow: scroll;position:absolute;overflow:auto;":"width:"+r+"; height:"+s+";position:absolute; left:0px; top:0px;overflow: auto;",a={id:this.element.id+"content",tabindex:"0",style:o};i?(this.diagramCanvas=i,Za(this.diagramCanvas,o)):(this.diagramCanvas=Tt("div",a),this.element.appendChild(this.diagramCanvas)),this.diagramCanvas.style.background=this.backgroundColor},t.prototype.initDiagram=function(){this.intOffPageBackground(),Ho(this.element,{style:"width:"+this.getSizeValue(this.width)+"; height:"+this.getSizeValue(this.height)+";position:relative;overflow:hidden;"})},t.prototype.renderHiddenUserHandleTemplateLayer=function(e){var r=Tt("div",{class:this.element.id+"_hiddenUserHandleTemplate",style:"width:"+e.width+"px; height:"+e.height+"px;visibility:hidden ; overflow: hidden;"});this.element.appendChild(r)},t.prototype.renderBackgroundLayer=function(e,i){var r=this.createSvg(this.element.id+"_backgroundLayer_svg",e.width,e.height);Za(r,i);var s=Bi("g",{id:this.element.id+"_backgroundImageLayer",class:"e-background-image-layer"});r.appendChild(s);var a=Bi("g",{id:this.element.id+"_backgroundLayer",class:"e-background-layer"});r.appendChild(a),this.diagramCanvas.appendChild(r)},t.prototype.renderGridLayer=function(e,i){var r=this.createSvg(this.element.id+"_gridline_svg",e.width,e.height);r.setAttribute("class","e-grid-layer");var s=Bi("g",{id:this.element.id+"_gridline"}),o=Bi("rect",{id:this.element.id+"_grid_rect",x:"0",y:"0",width:"100%",height:"100%"});if(im()){var a=new URL(window.location.href);o.setAttribute("fill",""!==a.search?"url(#"+this.element.id+"_pattern)":"url("+location.protocol+"//"+location.host+location.pathname+"#"+this.element.id+"_pattern)")}else o.setAttribute("fill","url(#"+this.element.id+"_pattern)");s.appendChild(o),r.appendChild(s),this.diagramCanvas.appendChild(r),oi(r,{style:i})},t.prototype.renderDiagramLayer=function(e,i){if(this.diagramLayerDiv=Tt("div",{id:this.element.id+"_diagramLayer_div",style:"width:"+e.width+"px; height:"+e.height+"px;"+i}),"SVG"===this.mode){var s=this.createSvg(this.element.id+"_diagramLayer_svg",e.width,e.height);s.style["pointer-events"]="none",s.setAttribute("class","e-diagram-layer");var o=Bi("g",{id:this.element.id+"_diagramLayer"}),a=Bi("g",{});this.diagramLayer=o,s.style["pointer-events"]="all",a.appendChild(o),s.appendChild(a),this.diagramLayerDiv.appendChild(s)}else this.diagramLayer=bo.createCanvas(this.element.id+"_diagram",e.width,e.height),Za(this.diagramLayer,"position:absolute;left:0px;top:0px;"),this.diagramLayerDiv.appendChild(this.diagramLayer);this.diagramCanvas.appendChild(this.diagramLayerDiv)},t.prototype.initLayers=function(){var e="position:absolute;top:0px;left:0px;overflow:hidden;pointer-events:none;",r=document.getElementById(this.element.id).getBoundingClientRect(),s=function moe(){var n=Tt("div",{style:"visibility:hidden; width: 100px"});document.body.appendChild(n);var t=n.getBoundingClientRect().width;n.style.overflow="scroll";var e=Tt("div",{style:"width:100%"});n.appendChild(e);var i=e.getBoundingClientRect().width;return n.parentNode.removeChild(n),t-i}();this.scroller.scrollerWidth=s,this.scroller.setViewPortSize(r.width,r.height),this.renderRulers();var o="measureElement";window[""+o]&&(window[""+o]=null,document.getElementById("measureElement").remove()),function RF(){var n="measureElement";if(window[""+n])window[""+n].usageCount+=1;else{var t=Tt("div",{id:"measureElement",style:"visibility:hidden ; height: 0px ; width: 0px; overflow: hidden;"}),e=Tt("span",{style:"display:inline-block ; line-height: normal"});t.appendChild(e);var i=Tt("img",{alt:"measureElementImage",src:"data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7"});t.appendChild(i);var r=document.createElementNS("http://www.w3.org/2000/svg","svg");r.setAttribute("xmlns:xlink","http://www.w3.org/1999/xlink"),t.appendChild(r);var s=document.createElementNS("http://www.w3.org/2000/svg","path");s.setAttribute("d",""),r.appendChild(s),document.createTextNode("");var a=document.createElementNS("http://www.w3.org/2000/svg","text");a.setAttributeNS("http://www.w3.org/XML/1998/namespace","xml:space","preserve"),r.appendChild(a),window[""+n]=t,window[""+n].usageCount=1,document.body.appendChild(t);var l="measureElementCount";window[""+l]?window[""+l]++:window[""+l]=1}}(),this.renderBackgroundLayer(r,e),this.renderGridLayer(r,e),this.renderDiagramLayer(r,e),this.renderHTMLLayer(r,e),this.renderPortsExpandLayer(r,e),this.renderNativeLayer(r,e),this.renderAdornerLayer(r,e),this.renderHiddenUserHandleTemplateLayer(r)},t.prototype.renderAdornerLayer=function(e,i){var r=Tt("div",{id:this.element.id+"_diagramAdornerLayer",style:"width:"+e.width+"px;height:"+e.height+"px;"+i}),s=Tt("div",{id:this.element.id+"_diagramUserHandleLayer",style:"width:"+e.width+"px;height:"+e.height+"px;"+i});s.setAttribute("class","e-userHandle-layer"),r.appendChild(s);var o=this.createSvg(this.element.id+"_diagramAdorner_svg",e.width,e.height);o.setAttribute("class","e-adorner-layer"),o.style["pointer-events"]="none",this.adornerLayer=Bi("g",{id:this.element.id+"_diagramAdorner"}),this.adornerLayer.style[" pointer-events"]="all",o.appendChild(this.adornerLayer),r.appendChild(o),this.diagramCanvas.appendChild(r);var a=Bi("g",{id:this.element.id+"_SelectorElement"});this.adornerLayer.appendChild(a),oi(o,{style:"pointer-events:none;"})},t.prototype.renderPortsExpandLayer=function(e,i){var r=this.createSvg(this.element.id+"_diagramPorts_svg",e.width,e.height);r.setAttribute("class","e-ports-expand-layer");var s=Bi("g",{id:this.element.id+"_diagramPorts",class:"e-ports-layer",style:"pointer-events: all;"});r.appendChild(s);var o=Bi("g",{id:this.element.id+"_diagramExpander",class:"e-expand-layer",style:"pointer-events: all;"});r.appendChild(o),this.diagramCanvas.appendChild(r),oi(r,{style:i})},t.prototype.renderHTMLLayer=function(e,i){this.htmlLayer=Tt("div",{id:this.element.id+"_htmlLayer",style:"width:"+e.width+"px; height:"+e.height+"px;position:absolute;top:0px;left:0px;overflow:hidden;pointer-events:none;",class:"e-html-layer"});var r=Tt("div",{id:this.element.id+"_htmlLayer_div",style:"position:absolute;top:0px;left:0px;pointer-events:all;"});this.htmlLayer.appendChild(r),this.diagramCanvas.appendChild(this.htmlLayer)},t.prototype.renderNativeLayer=function(e,i){var r=this.createSvg(this.element.id+"_nativeLayer_svg",e.width,e.height),s=Bi("g",{id:this.element.id+"_nativeLayer",style:"pointer-events:all;"});r.appendChild(s),this.diagramLayerDiv.appendChild(r),oi(r,{class:"e-native-layer",style:i})},t.prototype.createSvg=function(e,i,r){var s=document.createElementNS("http://www.w3.org/2000/svg","svg");return oi(s,{id:e,width:i,height:r}),s},t.prototype.updateBazorShape=function(){for(var e=0;e1,i=[],r={},s={},o=[],a=0,l=this.nodes;a0||b&&b.children&&b.children.length>0)&&(M=!1),S&&S.wrapper&&b&&b.wrapper&&M?this.initConnectors(r[""+h],f):i.push(r[""+h])}else b=r[y.targetID],(S=r[y.sourceID])&&S.children&&S.children.length>0||b&&b.children&&b.children.length>0?i.push(r[""+h]):this.initConnectors(r[""+h],f);else r[""+h].children?o.push(h):r[""+h].shape instanceof lT&&r[""+h].shape.activity.subProcess.processes&&r[""+h].shape.activity.subProcess.processes.length>0?s[r[""+h].id]=h:this.initNodes(r[""+h],f);if(this.bpmnModule)for(var w=0,C=this.bpmnModule.bpmnTextAnnotationConnector;w-1&&-1===r.indexOf(c)&&-1===s.indexOf(c)&&r.splice(0,0,c);-1===r.indexOf(o)&&s.push(o)}return r.concat(s)},t.prototype.addToLayer=function(e,i){var r;if(i&&(r=this.commandHandler.getObjectLayer(e.id)),(!i||!r)&&-1===this.activeLayer.objects.indexOf(e.id)&&this.activeLayer.objects.push(e.id),(e instanceof te||e instanceof de)&&("SwimLane"!==e.shape.type||e.children&&e.children.length>0)){if(e.parentId){var s=this.swimlaneZIndexTable[e.parentId],o=this.swimlaneChildTable[e.id];(s&&-1!==s||o&&-1!==o)&&(e.zIndex=this.swimlaneChildTable[e.id])}e instanceof de&&e.sourceID&&e.targetID?-1!==this.activeLayer.objects.indexOf(e.sourceID)&&-1!==this.activeLayer.objects.indexOf(e.targetID)&&this.setZIndex(r||this.activeLayer,e):this.setZIndex(r||this.activeLayer,e)}},t.prototype.updateLayer=function(e){for(var i=0,r=Object.keys(e.layers);i0)for(r=0;rs;l--)r.zIndexTable[parseInt(l.toString(),10)]=r.zIndexTable[l-1],this.nameTable[r.zIndexTable[parseInt(l.toString(),10)]]&&(this.nameTable[r.zIndexTable[parseInt(l.toString(),10)]].zIndex=l);r.zIndexTable[parseInt(a.toString(),10)]=i.id}}},t.prototype.initializeDiagramLayers=function(){for(var e=0;ethis.layers[parseInt(a.toString(),10)].zIndex&&(i=this.layers[parseInt(e.toString(),10)],this.layers[parseInt(e.toString(),10)]=this.layers[parseInt(a.toString(),10)],this.layers[parseInt(a.toString(),10)]=i);0===this.layers.length&&this.commandHandler.addLayer({id:"default_layer",visible:!0,lock:!1,objects:[],zIndex:0,objectZIndex:-1,zIndexTable:{}},null,!0),this.setActiveLayer(this.layers[this.layers.length-1].id)},t.prototype.resetTool=function(){this.eventHandler.resetTool()},t.prototype.initObjectExtend=function(e,i,r){if(r){var s=this.commandHandler.checkBoundaryConstraints(void 0,void 0,e.wrapper.bounds,!0);if("SwimLane"===e.shape.type)for(var o=0,a=Object.keys(i.zIndexTable);o0)&&this.setZIndex(i,e)),e instanceof te){if(r){if("helper"!==e.id&&(o=Zi(this.getNodeDefaults))){if((a=o(e,this))&&a.ports)for(var l=0;l0)for(l=0;l0&&!e.container||e.processId){var r=this.nameTable[e.id];if(!(this.realActions&$i.PreventScale||this.realActions&$i.PreventDrag)){if(r.offsetX&&(this.realActions&$i.EnableGroupAction||!(this.diagramActions&ee.UndoRedo||this.diagramActions&ee.ToolAction||this.diagramActions&ee.PublicMethod))){this.realActions|=$i.PreventScale;var s=r.offsetX-e.wrapper.offsetX;r.offsetX=e.wrapper.offsetX;var o=r.offsetY-e.wrapper.offsetY;r.offsetY=e.wrapper.offsetY,s+o!==0&&this.drag(r,s,o),this.realActions&=~$i.PreventScale}else r.offsetX=e.wrapper.offsetX;r.offsetY&&(this.realActions&$i.EnableGroupAction||!(this.diagramActions&ee.UndoRedo||this.diagramActions&ee.ToolAction||this.diagramActions&ee.PublicMethod))?(this.realActions|=$i.PreventScale,o=r.offsetY-e.wrapper.offsetY,r.offsetY=e.wrapper.offsetY,this.drag(r,0,o),this.realActions&=~$i.PreventScale):r.offsetY=e.wrapper.offsetY,this.diagramActions&&(r.width=e.wrapper.actualSize.width,r.height=e.wrapper.actualSize.height)}}i&&e.children&&e.children.length>0&&(void 0!==this.nameTable[e.id].width?this.scaleObject(e,this.nameTable[e.id].width,!0):this.nameTable[e.id].width=e.wrapper.actualSize.width,void 0!==this.nameTable[e.id].height?this.scaleObject(e,this.nameTable[e.id].height,!1):this.nameTable[e.id].height=e.wrapper.actualSize.height)},t.prototype.initNode=function(e,i,r){var a,p,s=e.initContainer(),o=new Ii;if(this.diagramSettings.inversedAlignment||(s.inversedAlignment=!1),s.children||(s.children=[]),e.children){s.measureChildren=!1,o.id=e.id+"group_container",o.style.fill=e.shape&&"SwimLane"===e.shape.type?e.style.fill:"none",o.style.strokeColor="none",o.horizontalAlignment="Stretch",o.verticalAlignment="Stretch",o.pivot=e.pivot,s.style=e.style,s.padding.left=e.padding.left,s.padding.right=e.padding.right,s.padding.top=e.padding.top,s.padding.bottom=e.padding.bottom,o.children=[],o.preventContainer=!0,e.container&&(o.relativeMode="Object");var l=!!(e.ports&&e.ports.length>0);if(m(e.container)&&!l&&s.children.push(o),e.container&&"Grid"===e.container.type)for(var h=0;h0&&e.wrapper.children[0]instanceof jv){if(this.setZIndex(this.activeLayer,e),this.connectors.length>0)for(h=0;h0?i.phases.length:0,v="Horizontal"===i.orientation,y=v?i.phases.length||1:s.length+1,S=v?(i.header&&i.hasHeader?1:0)+(i.phases.length>0?1:0)+i.lanes.length:(i.header&&i.hasHeader?1:0)+i.phases.length;if(0===h&&!v&&i.lanes.length&&(S+=1),v?(a=(i.header&&i.hasHeader?1:0)+(h>0?1:0),l=0):(a=i.header&&i.hasHeader?1:0,l=h>0?1:0),s.length>0)for(o+=i.header&&i.hasHeader?i.header.height:0,p=0;pl?d.margin.left=d.margin.left-(u.bounds.left-e.bounds.left):u.children[0].children[1].actualSize.width+r>=d.margin.left&&(d.margin.left=u.children[0].children[1].actualSize.width+r),d.margin.lefta?d.margin.top=d.margin.top-(u.bounds.top-o):u.children[0].children[1].actualSize.height+r>=d.margin.top&&(d.margin.top=u.children[0].children[1].actualSize.height+r),d.margin.left0)for(o=0;o0&&this.updateChildPosition(e)},t.prototype.addBpmnAnnotationConnector=function(e,i){if(e.parentObj instanceof t||e.parentObj instanceof Rd){var r=e.shape,o=""!==r.textAnnotation.textAnnotationTarget&&this.nameTable[r.textAnnotation.textAnnotationTarget],a=o?this.nameTable[r.textAnnotation.textAnnotationTarget]:null,l=null!=a?a.wrapper:null,h=e.ports[0],c={x:0,y:0};switch(r.textAnnotation.textAnnotationDirection){case"Left":h.offset={x:0,y:.5},c.x=i.bounds.left-40,c.y=i.bounds.bottom+30;break;case"Right":h.offset={x:1,y:.5},c.x=i.bounds.right+40,c.y=i.bounds.bottom+30;break;case"Top":h.offset={x:.5,y:0},c.x=i.bounds.right+30,c.y=i.bounds.top-40;break;case"Bottom":h.offset={x:.5,y:1},c.x=i.bounds.right+30,c.y=i.bounds.bottom+40;break;default:h.offset={x:0,y:.5},c.x=i.bounds.left-40,c.y=i.bounds.bottom+30,o&&null!=i&&null!=l&&(i.bounds.left>l.bounds.right?h.offset={x:0,y:.5}:i.bounds.rightl.bounds.top?h.offset={x:.5,y:0}:i.bounds.top0&&this.updateChildPosition(r)}},t.prototype.canExecute=function(){return!0},t.prototype.updateStackProperty=function(e,i,r){e.container&&"Stack"===e.container.type&&(i.width||(i.wrapper.horizontalAlignment="Stretch",i.horizontalAlignment="Stretch"),i.height||(i.verticalAlignment="Stretch",i.wrapper.verticalAlignment="Stretch"),r&&"UmlClassifier"===e.shape.type&&(i.umlIndex=r))},t.prototype.initViews=function(){this.isLoading||(this.views.push(this.element.id),this.views[this.element.id]=this)},t.prototype.initCommands=function(){var e=this.commandManager.commands,i={copy:{execute:this.copyCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.C,keyModifiers:pt.Control}},paste:{execute:this.pasteCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.V,keyModifiers:pt.Control}},cut:{execute:this.cutCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.X,keyModifiers:pt.Control}},delete:{execute:this.removeCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Delete}},selectAll:{execute:this.selectAll.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.A,keyModifiers:pt.Control}},undo:{execute:this.undo.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Z,keyModifiers:pt.Control}},redo:{execute:this.redo.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Y,keyModifiers:pt.Control}},nudgeUp:{execute:this.nudgeCommand.bind(this,"Up"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Up},parameter:"up"},nudgeRight:{execute:this.nudgeCommand.bind(this,"Right"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Right},parameter:"right"},nudgeDown:{execute:this.nudgeCommand.bind(this,"Down"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Down},parameter:"down"},nudgeLeft:{execute:this.nudgeCommand.bind(this,"Left"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Left},parameter:"left"},startEdit:{execute:this.startEditCommad.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.F2}},endEdit:{execute:this.endEditCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Escape}},focusToNextItem:{execute:this.navigateItems.bind(this,!0),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Tab}},focusToPreviousItem:{execute:this.navigateItems.bind(this,!1),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Tab,keyModifiers:pt.Shift}},selectFocusedItem:{execute:this.startEditCommad.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Enter}},bold:{execute:this.fontStyleCommand.bind(this,"bold"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.B,keyModifiers:pt.Control}},italic:{execute:this.fontStyleCommand.bind(this,"italic"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.I,keyModifiers:pt.Control}},underline:{execute:this.fontStyleCommand.bind(this,"underline"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.U,keyModifiers:pt.Control}},duplicate:{execute:this.duplicateCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.D,keyModifiers:pt.Control}},group:{execute:this.groupCommand.bind(this,"group"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.G,keyModifiers:pt.Control}},ungroup:{execute:this.groupCommand.bind(this,"ungroup"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.U,keyModifiers:pt.Control|pt.Shift}},rotateClockwise:{execute:this.rotateCommand.bind(this,"clockwise"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.R,keyModifiers:pt.Control}},rotateAntiClockwise:{execute:this.rotateCommand.bind(this,"antiClockwise"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.L,keyModifiers:pt.Control}},flipHorizontal:{execute:this.flipCommand.bind(this,"horizontal"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.H,keyModifiers:pt.Control}},flipVertical:{execute:this.flipCommand.bind(this,"vertical"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.J,keyModifiers:pt.Control}},pointerTool:{execute:this.toolCommand.bind(this,"pointer"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number1,keyModifiers:pt.Control}},textTool:{execute:this.toolCommand.bind(this,"text"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number2,keyModifiers:pt.Control}},connectTool:{execute:this.toolCommand.bind(this,"connect"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number3,keyModifiers:pt.Control}},freeForm:{execute:this.toolCommand.bind(this,"freeForm"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number5,keyModifiers:pt.Control}},lineTool:{execute:this.toolCommand.bind(this,"line"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number6,keyModifiers:pt.Control}},rectangleTool:{execute:this.toolCommand.bind(this,"rectangle"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number8,keyModifiers:pt.Control}},ellipseTool:{execute:this.toolCommand.bind(this,"ellipse"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number9,keyModifiers:pt.Control}},zoomIn:{execute:this.zoomCommand.bind(this,"zoomIn"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Plus,keyModifiers:pt.Control}},zoomOut:{execute:this.zoomCommand.bind(this,"zoomOut"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Minus,keyModifiers:pt.Control}},shiftUp:{execute:this.shiftCommand.bind(this,"Up"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Up,keyModifiers:pt.Shift}},shiftDown:{execute:this.shiftCommand.bind(this,"Down"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Down,keyModifiers:pt.Shift}},shiftLeft:{execute:this.shiftCommand.bind(this,"Left"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Left,keyModifiers:pt.Shift}},shiftRight:{execute:this.shiftCommand.bind(this,"Right"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Right,keyModifiers:pt.Shift}},alignTextCenter:{execute:this.alignCommand.bind(this,"center"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.C,keyModifiers:pt.Control|pt.Shift}},alignTextLeft:{execute:this.alignCommand.bind(this,"right"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.L,keyModifiers:pt.Control|pt.Shift}},alignTextRight:{execute:this.alignCommand.bind(this,"left"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.R,keyModifiers:pt.Control|pt.Shift}},alignTextTop:{execute:this.alignCommand.bind(this,"top"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.E,keyModifiers:pt.Control|pt.Shift}},alignTextCenterVertical:{execute:this.alignCommand.bind(this,"centerVertical"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.M,keyModifiers:pt.Control|pt.Shift}},alignTextBottom:{execute:this.alignCommand.bind(this,"bottom"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.V,keyModifiers:pt.Control|pt.Shift}},alignJustify:{execute:this.alignCommand.bind(this,"justify"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.J,keyModifiers:pt.Control|pt.Shift}},sendToBack:{execute:this.orderCommand.bind(this,"sendToBack"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.B,keyModifiers:pt.Control|pt.Shift}},bringToFront:{execute:this.orderCommand.bind(this,"bringToFront"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.F,keyModifiers:pt.Control|pt.Shift}},sendBackward:{execute:this.orderCommand.bind(this,"sendBackward"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.BracketLeft,keyModifiers:pt.Control}},bringForward:{execute:this.orderCommand.bind(this,"bringForward"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.BracketRight,keyModifiers:pt.Control}}};this.initCommandManager(e,i)},t.prototype.overrideCommands=function(e,i){for(var r,s=0,o=Object.keys(i);se.zIndex){("HTML"===e.shape.type||"Native"===e.shape.type)&&(o="HTML"===e.shape.type?"html":"native"),s=uoe(i,r[parseInt(a.toString(),10)].id,o);break}return s},t.prototype.updateDiagramObject=function(e,i,r){for(var s,o="domTable",a=0,l=this.views;a1&&(d=this.commandHandler.getObjectLayer(e.id)),void 0===d||d&&d.visible||r){var u=Io(this.element.id);window[""+o][s.element.id+"_diagramLayer"]||(window[""+o][s.element.id+"_diagramLayer"]=document.getElementById(s.element.id+"_diagramLayer"));var p=window[""+o][s.element.id+"_diagramLayer"];this.diagramActions&ee.Interactions&&this.updateCanupdateStyle(e.wrapper.children,!0);var f=this.getMidPoint(e);this.diagramRenderer.updateNode(e.wrapper,p,u,void 0,i?void 0:this.getZindexPosition(e,s.element.id),f,this.portCenterPoint),this.updateCanupdateStyle(e.wrapper.children,!0)}}},t.prototype.applyMarginBezier=function(e,i){i.cx=i.cx+e.margin.left,i.cx=i.cx-e.margin.right,i.cy=i.cy+e.margin.top,i.cy=i.cy-e.margin.bottom},t.prototype.getMidPoint=function(e){var i;if(e instanceof de&&"Bezier"===e.type){i=[];for(var r=this.getBezierPoints(e),s=z.getLengthFromListOfPoints(r),o=0;o0&&e.updateView(e));var s=Io(e.element.id);this.renderDiagramElements(e.diagramLayer,e.diagramRenderer,s,void 0,void 0,i);for(var o=0;o0&&this.renderBasicElement(e),!this.diagramActions||!(this.diagramActions&ee.Render)||ee.ToolAction&this.diagramActions||Ds(this)||1!==this.scroller.currentZoom?this.refreshElements(e):this.renderTimer||(this.renderTimer=setTimeout(function(){i.refreshElements(e)},40)))},t.prototype.updatePortVisibility=function(e,i,r){var s;if((e instanceof te||e instanceof de)&&(!this.drawingObject||!this.drawingObject.shape)&&to(e)){for(var a=e.ports,l=!1,h=0;h=0&&this.scroller.removeCollection.splice(l,1);var h=this.nameTable[e[parseInt(a.toString(),10)]];this.updateTextElementValue(h),this.diagramRenderer.renderElement(h.wrapper,s,o,void 0,void 0,void 0,void 0,h.zIndex)}for(var c=0;c0?this.scroller.oldCollectionObjects:void 0,b=Object.keys(S||g.zIndexTable);b.sort(function(N,T){return parseInt(""+N,10)-parseInt(""+T,10)});for(var M=0,w=b;M0?h:0)+"px",y=(this.realActions&$i.vScrollbarMoved?0:-(this.scroller.verticalOffset<0?this.scroller.verticalOffset:0))+"px"):(v="0px",y="0px"),this.realActions&$i.hScrollbarMoved&&(this.realActions=this.realActions&~$i.hScrollbarMoved),this.realActions&$i.vScrollbarMoved&&(this.realActions=this.realActions&~$i.vScrollbarMoved)):(v=(l.x<0?h:-this.scroller.horizontalOffset)+"px",y=(l.y<0?c:-this.scroller.verticalOffset)+"px"),this.diagramLayer.style.left=v,this.diagramLayer.style.top=y,A.tx=-l.x/A.scale,A.ty=-l.y/A.scale);var R=!0;if(o&&(R=!1),this.updateTextElementValue(D),this.refreshing&&D.shape.activity&&D.shape.activity.subProcess&&D.shape.activity.subProcess.processes){for(var L=0;L0){var o=s.children[0],a=o.data;(r.isBezierEditing&&this.selectedItems.connectors[0].id===r.id||"Bezier"!==r.type)&&r.getSegmentElement(r,o,"ComplexHierarchicalTree"===this.layout.type||"HierarchicalTree"===this.layout.type?this.layout.orientation:void 0,void 0,!1),o.data!==a&&(s.measure(new me),s.arrange(s.desiredSize),"SVG"===this.mode&&!e&&this.updateDiagramObject(r))}}else this.constraints&rt.Bridging&&console.warn('[WARNING] :: Module "ConnectorBridging" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.setCursor=function(e){this.diagramRenderer.setCursor(this.diagramCanvas,e)},t.prototype.clearCanvas=function(e){var i=e.contentWidth||e.diagramLayer.width/this.scroller.currentZoom,r=e.contentHeight||e.diagramLayer.height/this.scroller.currentZoom;"SVG"!==e.mode&&bo.getContext(e.diagramLayer).clearRect(0,0,i,r)},t.prototype.updateScrollOffset=function(){this.scroller.setScrollOffset(this.diagramCanvas.scrollLeft,this.diagramCanvas.scrollTop),QI(this),Ds(this)&&this.scroller.virtualizeElements()},t.prototype.setOffset=function(e,i){var r="domTable";window[""+r][this.element.id+"content"]||(window[""+r][this.element.id+"content"]=document.getElementById(this.element.id+"content"));var s=window[""+r][this.element.id+"content"];s&&(s.scrollLeft=e,s.scrollTop=i)},t.prototype.setSize=function(e,i){if(this.diagramLayer&&!this.preventDiagramUpdate){var r=qa(this);e-=r.width,i-=r.height;var s=this.spatialSearch.getPageBounds();s.x*=this.scroller.currentZoom,s.y*=this.scroller.currentZoom,s.width*=this.scroller.currentZoom,s.height*=this.scroller.currentZoom;var o="SVG"===this.mode?1:1.5,a="SVG"===this.mode?pT(this.element.id):this.diagramLayer,h="Canvas"===this.mode&&this.constraints&rt.Virtualization?this.scroller.viewPortHeight:i;a.setAttribute("width",(o*("Canvas"===this.mode&&this.constraints&rt.Virtualization?this.scroller.viewPortWidth:e)).toString()),a.setAttribute("height",(o*h).toString());var c=document.getElementById(this.element.id+"_diagramUserHandleLayer");c&&(c.style.width=e+"px",c.style.height=i+"px");var d={width:e.toString(),height:i.toString()};this.diagramLayerDiv.style.width=e+"px",this.diagramLayerDiv.style.height=i+"px",oi(NF(this.element.id),d),oi(function foe(n){return xt(n).getElementsByClassName("e-ports-expand-layer")[0]}(this.element.id),d);var u=Pl(this.element.id);oi(u,d),u.parentNode.style.width=e+"px",u.parentNode.style.height=i+"px";var p=Bd(this.element.id);oi(p,d),this.diagramRenderer.updateGrid(this.snapSettings,p,this.scroller.transform,this.rulerSettings,this.hRuler,this.vRuler),oi(vT(this.element.id),d),this.htmlLayer.style.width=e+"px",this.htmlLayer.style.height=i+"px","SVG"!==this.mode&&!Ds(this)&&this.refreshDiagramLayer(),"SVG"===this.mode&&Ds(this)&&this.scroller.virtualizeElements()}},t.prototype.transformLayers=function(){var e=this.spatialSearch.getPageBounds();e.x*=this.scroller.currentZoom,e.y*=this.scroller.currentZoom,e.width*=this.scroller.currentZoom,e.height*=this.scroller.currentZoom,this.diagramRenderer.updateGrid(this.snapSettings,Bd(this.element.id),this.scroller.transform,this.rulerSettings,this.hRuler,this.vRuler),this.diagramRenderer.transformLayers(this.scroller.transform,"SVG"===this.mode),this.diagramActions&ee.DragUsingMouse||this.updateSelector(),this.renderPageBreaks(e)},t.prototype.removePageBreaks=function(){if(this.diagramLayer){var e=OF(this.element.id);if(e&&e.childNodes)for(var i=e.childNodes.length,r=0;rthis.pageSettings.height&&(e=this.pageSettings.height,this.pageSettings.height=this.pageSettings.width,this.pageSettings.width=e):this.pageSettings.height>this.pageSettings.width&&(e=this.pageSettings.width,this.pageSettings.width=this.pageSettings.height,this.pageSettings.height=e)},t.prototype.setOverview=function(e,i){if(e)e&&(this.views.push(e.id),this.views[e.id]=e,e.renderDocument(e),e.diagramRenderer.setLayers(),e.updateView(e),this.renderNodes(e));else{for(var r=0;r1&&this.updateSelectionRectangle(),this.isProtectedOnChange=s},t.prototype.updateSelectionRectangle=function(){for(var e=lm(this.element.id),i=!1,r=0;r1&&this.updateSelectionRectangle(),this.enableServerDataBinding(e)},t.prototype.renderSelectorForAnnotation=function(e,i){this.diagramRenderer.renderResizeHandle(e.wrapper.children[0],i,e.thumbsConstraints,this.scroller.currentZoom,e.constraints,this.scroller.transform,void 0,to(e.annotation),void 0,void 0,e.handleSize)},t.prototype.drawSelectionRectangle=function(e,i,r,s){this.clearSelectorLayer(),this.diagramRenderer.drawSelectionRectangle(e,i,r,s,this.adornerLayer,this.scroller.transform)},t.prototype.renderHighlighter=function(e){var i=Pl(this.element.id);this.diagramRenderer.renderHighlighter(e,i,this.scroller.transform)},t.prototype.clearHighlighter=function(){var e=Pl(this.element.id),i=e.getElementById(e.id+"_highlighter");i&&i.parentNode.removeChild(i)},t.prototype.getNodesConnectors=function(e){for(var i=0;i0;l--)(a=o[l-1]).parentNode.removeChild(a);if(!ce()){var h=gT(this.element.id).childNodes;for(r=h.length;r>0;r--)h[r-1].parentNode.removeChild(h[r-1])}}},t.prototype.getWrapper=function(e,i){var r;i=e.id+"_"+i;for(var s=e instanceof Ii?e:this.getPortContainer(this.nameTable[e.id]),o=0;o0&&this.applyStyle(e,a=r.annotations)}for(i=0;i0){var a=this.selectedItems.connectors[parseInt(i.toString(),10)].annotations;this.applyStyle(e,a)}},t.prototype.applyStyle=function(e,i){for(var r=0;r0)for(var i=0;i0?r[0].zIndex+(e?1:-1):e?0:this.nodes.length+this.connectors.length-1)<0?i=this.nodes.length+this.connectors.length-1:i===this.nodes.length+this.connectors.length&&(i=0);for(var s=0;s0)for(var s=void 0,o=r.children.length-1;o>=0;o--){var a=r.children[parseInt(o.toString(),10)];i.length>0&&-1!==i.indexOf(a.id.split("_groupElement")[0])&&(r.parentNode.insertBefore(a,s||r),s=a)}r&&r.parentNode.removeChild(r)},t.prototype.deleteGroup=function(e){var r=[];e.children&&(r=this.commandHandler.getChildren(e,[])),this.UpdateBlazorDiagramModelCollection(e);for(var s=0,o=r;s0)for(var xe=0;xe0)if("Path"===t.shape.type&&void 0!==n.shape.data)t.wrapper.children[0].data=n.shape.data;else if("Text"===t.shape.type&&void 0!==n.shape.content)t.wrapper.children[0].content=n.shape.content;else if("Image"===t.shape.type&&void 0!==n.shape.source)t.wrapper.children[0].source=n.shape.source;else if("Native"===t.shape.type){for(var r=void 0,s=0;s-1)&&(this.diagramActions&ee.PreventZIndexOnDragging?this.updateDiagramObject(e,!0):this.updateDiagramObject(e)),!s&&d&&(this.lineRoutingModule&&this.diagramActions&&this.constraints&rt.LineRouting&&"helper"!==e.id?this.diagramActions&ee.ToolAction||this.lineRoutingModule.renderVirtualRegion(this,!0):this.diagramActions&&this.constraints&rt.LineRouting&&"helper"!==e.id&&console.warn('[WARNING] :: Module "LineRouting" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),this.updateConnectorEdges(e),"helper"!==e.id&&!(this.diagramActions&ee.ToolAction))))for(var ya=this.spatialSearch.findObjects(e.wrapper.outerBounds),Mo=0;Moe?Math.abs(r-e):Math.abs(e-r),d=s>i?Math.abs(s-i):Math.abs(i-s);(0===c&&0===d||Number.isNaN(c)&&Number.isNaN(d))&&o.laneMargin&&(u=o.margin.left-o.laneMargin.left,p=o.margin.top-o.laneMargin.top);var f=o.width,g=o.height,v=new Ne(0,0,0,0);if(0!==f&&0!==g&&(v=new Ne((0!==r?r:o.offsetX)-f/2,(0!==s?s:o.offsetY)-g/2,f,g)),h){var y=l,b=this.selectedItems.nodes?this.selectedItems.nodes[0]:void 0;if(""!==y.textAnnotation.textAnnotationTarget&&this.nameTable[y.textAnnotation.textAnnotationTarget])if(""===o.parentId||b&&b.shape&&"TextAnnotation"===b.shape.shape){if("Auto"===y.textAnnotation.textAnnotationDirection&&a.children[0]instanceof Ii&&a.children[0].children[0]instanceof Ke){var w=a.children[0],C=document.getElementById(w.id+"_groupElement"),D=document.getElementById(w.children[0].id+"_groupElement");C.removeChild(D),w.children.splice(0,1),this.isProtectedOnChange=!0,this.bpmnModule.setAnnotationPath(v,w,o,y,y.textAnnotation.textAnnotationDirection,this),this.isProtectedOnChange=!1}}else this.isPositionUndo=!0,this.updateTextAnnotationInSwimlane(o,o),this.isPositionUndo=!1;else o.inEdges.length>0&&(x=this.nameTable[""+o.inEdges[0]])&&x.isBpmnAnnotationConnector&&(x.sourcePoint={x:r>e?x.sourcePoint.x+c:x.sourcePoint.x-c,y:s>i?x.sourcePoint.y+d:x.sourcePoint.y-d});this.nodePropertyChange(o,{},R={ports:[{offset:o.ports[0].offset}]})}else for(var L=0,O=o.outEdges;Le?T.offsetX+c:T.offsetX-c,T.offsetY=s>i?T.offsetY+d:T.offsetY-d,R={offsetX:T.offsetX,offsetY:T.offsetY}),this.nodePropertyChange(T,P,R)}}}},t.prototype.updatePorts=function(e,i){if(e&&e.ports.length>0)for(var r=0,s=Object.keys(e.ports);r0)for(var i=0;i0)for(var r=0;r0&&void 0===r.segments&&(e.segments=[]),void 0!==r.shape&&void 0!==e.shape&&e.shape&&"Bpmn"===e.shape.type&&this.bpmnModule&&this.bpmnModule.updateBPMNConnector(e,i,r,this),void 0!==e.constraints?(this.updateThumbConstraints(this.selectedItems.connectors,this.selectedItems),s=!0):s},t.prototype.connectorPropertyChange=function(e,i,r,s,o){if(this.canEnableBlazorObject){var a=$(e);this.insertValue(a,!1)}var d,u,p,f,l=e.wrapper.bounds,h=!1,c=[];if(h=this.connectorProprtyChangeExtend(e,i,r,h),void 0!==r.visible&&this.updateElementVisibility(e.wrapper,e,e.visible),void 0!==r.sourcePoint||void 0!==r.targetPoint||void 0!==r.sourceID||void 0!==r.targetID||void 0!==r.targetPadding||void 0!==r.sourcePortID||void 0!==r.targetPortID||void 0!==r.sourcePadding||void 0!==r.type||void 0!==r.segments||void 0!==r.flip){if(void 0!==r.sourceID&&r.sourceID!==i.sourceID||r.sourcePortID){if(u=this.findInOutConnectPorts(g=this.nameTable[e.sourceID],!1),(!g||Nh(g)||""!==e.sourcePortID&&xd(u))&&(e.sourceWrapper=g?this.getEndNodeWrapper(g,e,!0):void 0,e.sourcePortID&&void 0===r.sourcePortID&&(e.sourcePortWrapper=g?this.getWrapper(g.wrapper,e.sourcePortID):void 0),this.removePortEdges(this.nameTable[i.sourceID]||g,i.sourcePortID||e.sourcePortID,e.id,!1)),void 0!==r.sourceID&&void 0!==i.sourceID&&""!==i.sourceID){var v=this.nameTable[i.sourceID];void 0!==v&&v.outEdges&&-1!==v.outEdges.indexOf(e.id)&&Kv(v.outEdges,e.id)}this.updateEdges(e)}if(void 0!==r.targetID&&r.targetID!==i.targetID){if(d=this.findInOutConnectPorts(y=this.nameTable[r.targetID],!0),(!y||da(y)||""!==e.targetPortID&&Lh(d))&&(e.targetWrapper=y?this.getEndNodeWrapper(y,e,!1):void 0,e.targetPortID&&void 0===r.targetPortID&&(e.targetPortWrapper=y?this.getWrapper(y.wrapper,e.targetPortID):void 0),this.removePortEdges(this.nameTable[i.targetID]||y,i.targetPortID||e.targetPortID,e.id,!0)),void 0!==i&&void 0!==i.targetID&&""!==i.targetID){var S=this.nameTable[i.targetID];void 0!==S&&S.inEdges&&-1!==S.inEdges.indexOf(e.id)&&Kv(S.inEdges,e.id)}this.updateEdges(e)}var g,y;void 0!==r.sourcePortID&&r.sourcePortID!==i.sourcePortID&&(e.sourceID&&this.nameTable[e.sourceID]&&(p=this.nameTable[e.sourceID].wrapper),!(g=this.nameTable[e.sourceID])||Nh(g)||""!==e.sourcePortID&&xd(u)?e.sourcePortWrapper=p?this.getWrapper(p,r.sourcePortID):void 0:""===e.sourcePortID&&!Nh(g)&&(e.sourcePortWrapper=void 0)),void 0!==r.targetPortID&&r.targetPortID!==i.targetPortID&&(e.targetID&&this.nameTable[e.targetID]&&(f=this.nameTable[e.targetID].wrapper),!(y=this.nameTable[e.targetID])||da(y)||""!==e.targetPortID&&Lh(d)?e.targetPortWrapper=f?this.getWrapper(f,r.targetPortID):void 0:""===e.targetPortID&&!da(y)&&(e.targetPortWrapper=void 0)),void 0!==r.flip&&(e.flip=r.flip,mF(e)),"Orthogonal"===e.type&&this.lineRoutingModule&&this.diagramActions&&this.constraints&rt.LineRouting&&!(this.diagramActions&ee.ToolAction)&&"ComplexHierarchicalTree"!==this.layout.type&&(this.lineRoutingModule.renderVirtualRegion(this,!0),e.sourceID!==e.targetID&&e.segments.length>1&&this.lineRoutingModule.refreshConnectorSegments(this,e,!1)),c=this.getPoints(e)}void 0!==r.style&&Ph(r.style,e.wrapper.children[0]),(c.length>0||void 0!==r.sourceDecorator||void 0!==r.targetDecorator&&function Rse(n){return-1!==n.indexOf("shape")||-1!==n.indexOf("pathData")||-1!==n.indexOf("width")||-1!==n.indexOf("height")}(Object.keys(r.targetDecorator))||void 0!==r.cornerRadius)&&(Zp(e,c.length>0?c:e.intermediatePoints,this.diagramActions),void 0!==r.type&&(h=!0),c.length>0&&(e.wrapper.measure(new me(e.wrapper.width,e.wrapper.height)),e.wrapper.arrange(e.wrapper.desiredSize),this.updateConnectorAnnotation(e),this.updateConnectorPort(e),this.updateConnectorfixedUserHandles(e),this.updateObject(e,i,r))),(r.sourcePoint||r.targetPoint||r.segments)&&this.diagramActions===ee.Render&&(h=!0),"Bpmn"===e.shape.type&&"Default"===e.shape.sequence&&"Sequence"===e.shape.flow&&this.commandHandler.updatePathElementOffset(e),s||this.updateBridging(),this.updateAnnotations(r,e),this.updateConnectorPorts(r,e),this.updatefixedUserHandle(r,e),e.wrapper.measure(new me(e.wrapper.width,e.wrapper.height)),e.wrapper.arrange(e.wrapper.desiredSize),!1===l.equals(l,e.wrapper.bounds)&&(this.updateQuad(e),"Drag"!==this.eventHandler.currentAction&&this.updateGroupSize(e)),!0===h&&this.checkSelectedItem(e)&&(!(this.diagramActions&ee.ToolAction)||this.diagramActions&ee.UndoRedo)&&this.updateSelector(),this.preventConnectorsUpdate||(!Ds(this)||Ds(this)&&this.scroller.oldCollectionObjects.indexOf(e.id)>-1)&&(this.diagramActions&ee.PreventZIndexOnDragging?this.updateDiagramObject(e,!0):this.updateDiagramObject(e)),this.updateConnectorEdges(e),this.diagramActions&&"New"!==e.status&&(e.status="Update"),this.triggerPropertyChange(o,e,i,r)},t.prototype.removePortEdges=function(e,i,r,s){if(e)for(var o=0;o0&&e.id===s[s.length-1].id&&(r=!0),r},t.prototype.updateDiagramContainerVisibility=function(e,i){if(e instanceof Cs)for(var r=0;r>"),r instanceof Jn&&this.updateAnnotationWrapper(r,s,o,a)),void 0!==e.template&&(r.content=e.template,this.updateAnnotationWrapper(r,s,o,a))},t.prototype.updateAnnotationWrapper=function(e,i,r,s){for(var o=0,a=this.views;o=0&&this.nodes.splice(s,1),delete this.nameTable[""+r]}var o=this.nodes.indexOf(this.nameTable[this.currentSymbol.id]);o>=0&&this.nodes.splice(o,1)}},t.prototype.selectDragedNode=function(e,i,r){this.currentSymbol=e,"SVG"!==this.mode&&this.refreshDiagramLayer(),this.commandHandler.oldSelectedObjects=tm(this),this.commandHandler.select(e),this.eventHandler.mouseDown(i.event),this.eventHandler.mouseMove(i.event,i),this.preventDiagramUpdate=!1,this.updatePage(),r.style.opacity="0"},t.prototype.initDroppables=function(){var s,o,e=this,i={},r={},a="selectedSymbols";this.droppable=new oR(this.element);var l=5;this.droppable.over=function(h){if(e.rulerSettings.showRulers){var c=document.getElementById(e.element.id+"_vRuler"),d=parseFloat(c.style.width);l=d+1}if(0===e.previousSelectedObjects.length&&!e.currentSymbol&&(e.previousSelectedObjects=e.commandHandler.getSelectedObject()),e.commandHandler.PreventConnectorSplit=!0,e.currentSymbol)h.event.touches&&h.event.touches.length&&e.eventHandler.mouseMove(h.event,h.event.touches);else{var u=null;if(!h.dragData&&"drag"===h.name){var p=document.getElementsByClassName("e-dragclone")[0];p&&(u=p)}if(h.dragData||u){var f=void 0,g=void 0;document.getElementById(e.element.id+"content").focus();var v=e.eventHandler.getMousePosition(h.event),y=void 0,S=u||h.dragData.helper,b=S.getAttribute("paletteId"),M=void 0,w=void 0,C=void 0,D=void 0;if(!b&&h.dragData){e.triggerEvent(Ce.dragEnter,A={source:null,element:f,cancel:!1,diagram:e,dragData:h.dragData.draggedElement.ej2_instances[0].dragData,dragItem:f});var x=void 0,R=void 0;if(A.dragItem){if(A.dragItem.sourcePoint&&A.dragItem.targetPoint?R=new de(e,"connectors",A.dragItem,!0):x=new te(e,"nodes",A.dragItem,!0),e.initObject(f=x||R,void 0,void 0,!0),e.enterObject=f,e.enterTable=r,f instanceof te)x.offsetX=v.x+5+x.width*x.pivot.x,x.offsetY=v.y+x.height*x.pivot.y;else if(f instanceof de){var L=Ne.toBounds([f.sourcePoint,f.targetPoint]),O=v.x-L.left,N=v.y-L.top;f.sourcePoint.x+=O,f.sourcePoint.y+=N,f.targetPoint.x+=O,f.targetPoint.y+=N}e.preventDiagramUpdate=!0,e.currentSymbol=f,"SVG"!==e.mode&&e.refreshDiagramLayer(),e.selectDragedNode(f,h,S),delete e.enterObject,delete e.enterTable,e.droppable[""+a]=S,e.allowServerDataBinding=!0}}if(b){var T=document.getElementById(b).ej2_instances[0];if(e.droppable.sourceElement=T,T){var B=T[""+a];e.allowServerDataBinding=!1,y=$(T[""+a]),i=T.childTable;var j=B.wrapper.children[0].children[0];if(D=function Hse(n,t,e){var i=bF(n,t,e,"width"),r=bF(n,t,e,"height");return new me(i,r)}(T,y,j),T[""+a]instanceof te){"TextAnnotation"===B.shape.shape?(y.offsetX=v.x+11+D.width*y.pivot.x,y.offsetY=v.y+11+D.height*y.pivot.y):(y.offsetX=v.x+5+D.width*y.pivot.x,y.offsetY=v.y+D.height*y.pivot.y),"Bpmn"===(x=new te(e,"nodes",y,!0)).shape.type&&x.shape.activity.subProcess.processes&&x.shape.activity.subProcess.processes.length&&(x.shape.activity.subProcess.processes=[]),w=x.previewSize,C=T.symbolDragSize;var Q=T.symbolPreview;if(x.width=(M=x.dragSize).width||C.width||w.width||Q.width||x.width,x.height=M.height||C.height||w.height||Q.height||x.height,"SwimLane"===x.shape.type){if(e.diagramActions|=ee.PreventHistory,x.shape.isLane){x.children=[],s={id:"header"+Qe()},"Horizontal"===x.shape.orientation?(s.width=x.shape.lanes[0].header.width,s.height=x.shape.lanes[0].height):(s.width=x.shape.lanes[0].width,s.height=x.shape.lanes[0].header.height),s.style=x.shape.lanes[0].header.style,s.offsetX=v.x+l+s.width/2,s.offsetY=v.y+s.height/2,e.diagramActions|=ee.PreventCollectionChangeOnDragOver,s=e.add(s),o={id:"body"+Qe()},"Horizontal"===x.shape.orientation?(o.width=x.shape.lanes[0].width-s.width,o.height=x.shape.lanes[0].height,o.offsetX=v.x+l+(x.shape.lanes[0].header.width+o.width/2),o.offsetY=v.y+o.height/2):(o.width=x.shape.lanes[0].width,o.height=x.shape.lanes[0].height-s.height,o.offsetX=v.x+l+o.width/2,o.offsetY=v.y+(x.shape.lanes[0].header.height+o.height/2)),o.style=x.shape.lanes[0].style,o=e.add(o);var oe={id:"group"+Qe(),children:[s.id,o.id]};oe.shape=x.shape,oe.width=x.shape.lanes[0].width,oe.height=x.shape.lanes[0].height,oe.previewSize=x.previewSize,oe.dragSize=x.dragSize,oe.addInfo=x.addInfo,x=e.add(oe),e.diagramActions&=~ee.PreventCollectionChangeOnDragOver}e.diagramActions&=~ee.PreventHistory}if(x.shape.isPhase&&((g="Horizontal"===x.shape.orientation)?(x.offsetX=v.x+l+(x.width||j.actualSize.width)/2,x.offsetY=v.y,x.shape.data="M20,"+x.height/2+" L"+(x.width-20)+","+x.height/2+"z",x.height=1):(x.offsetX=v.x+5,x.offsetY=v.y+(x.height||j.actualSize.height)/2,x.shape.data="M"+x.width/2+",20 L"+x.width/2+","+(x.height-20)+"z",x.width=1)),"UmlClassifier"===x.shape.type&&(x.children=x.width=x.height=void 0,y.children=void 0,"Class"===x.shape.classifier&&x.shape.classShape.methods.length<=0&&x.shape.classShape.attributes.length<=0&&(x.shape.classShape.attributes=[{name:"Name",type:"Type",style:{}}]),"Enumeration"===x.shape.classifier&&x.shape.enumerationShape.members.length<=0&&(x.shape.enumerationShape.members=[{name:"Name"}]),"Interface"===x.shape.classifier&&x.shape.interfaceShape.methods.length<=0&&x.shape.interfaceShape.attributes.length<=0&&(x.shape.interfaceShape.attributes=[{name:"Name",type:"Type",style:{}}])),f=x,y.children){var ue=y;r=e.getChildren(ue,{},i),Kx(ue,-ue.offsetX,-ue.offsetY,r,!0,e)}}else if(T[""+a]instanceof de){f=new de(e,"connectors",y,!0);var Me=Ne.toBounds([f.sourcePoint,f.targetPoint]),De=v.x-Me.left,xe=v.y-Me.top;f.sourcePoint.x+=De,f.sourcePoint.y+=xe,f.targetPoint.x+=De,f.targetPoint.y+=xe}f.shape.isLane||(f.id+=Qe());var A={source:T,element:f,cancel:!1,diagram:e,dragData:null,dragItem:f};if(e.enterObject=f,e.enterTable=r,e.triggerEvent(Ce.dragEnter,A),f instanceof te&&"SwimLane"===f.shape.type&&f.shape.isLane){var Ie=A.element,Ve=Ie.shape.lanes[0];g="Horizontal"===Ie.shape.orientation;var ot=e.nameTable[f.children[0]],$e=e.nameTable[f.children[1]];w=f.previewSize,C=T.symbolDragSize,Ve.width=(M=f.dragSize).width||C.width||w.width||Ve.width,Ve.height=M.height||C.height||w.height||Ve.height,g?(s.width=Ve.header.width,s.height=Ve.height,o.width=Ve.width-s.width,o.height=Ve.height,o.offsetX=v.x+l+(Ve.header.width+$e.width/2),o.offsetY=v.y+$e.height/2):(s.width=Ve.width,s.height=Ve.header.height,o.width=Ve.width,o.height=Ve.height-s.height,o.offsetX=v.x+l+$e.width/2,o.offsetY=v.y+(Ve.header.height+$e.height/2)),s.offsetX=v.x+l+ot.width/2,s.offsetY=v.y+ot.height/2,f.width=Ve.width,f.height=Ve.height}if(f instanceof te&&f.shape.isPhase&&(g?f.height=1:f.width=1),!e.activeLayer.lock&&!A.cancel){if(e.preventDiagramUpdate=!0,f.children&&e.findChild(f,r),e.preventDiagramUpdate=!0,f.zIndex!==Number.MIN_VALUE&&(f.zIndex=Number.MIN_VALUE),e.initObject(f,void 0,void 0,!0),e.bpmnModule)for(var Mi=0;Mi0&&(S.segments=[]),d=this.add(S,!0)),(S||d)&&(Bv(this)||Fv(this))&&this.select([this.nameTable[S[""+b]]],!1,this.previousSelectedObjects),y.target&&y.target instanceof de&&!0===this.enableConnectorSplit&&this.nameTable[S[""+b]]instanceof te&&(this.commandHandler.connectorSplit(this.nameTable[S[""+b]],y.target),this.commandHandler.PreventConnectorSplit=!1))),this.protectPropertyChange(!1),v=this.nameTable[S[""+b]],S.hasTarget&&(S.nodeId=S.hasTarget,this.remove(S)),this.bpmnModule&&v instanceof te&&S.processId&&(v.processId=S.processId,this.bpmnModule.dropBPMNchild(this.nameTable[v.processId],v,this)),y.cancel||this.endGroupAction(),"SVG"!==this.mode&&this.refreshDiagramLayer(),delete this.droppable[""+c]):(this.triggerEvent(Ce.drop,y={source:h.droppedElement,element:void 0,target:this.eventHandler.hoverNode||this.eventHandler.lastObjectUnderMouse||this,cancel:!1,position:void 0}),S=void 0,b="id"),this.droppable[M="selectedSymbols"]&&this.droppable[""+M].parentNode)gt(this.droppable[""+M]);else for(w=document.getElementsByClassName("e-dragclone"),C=0;C0)for(var p=0;p1),e.previousSelectedObject=null}}},t.prototype.getDropEventArgs=function(e){if(this.eventHandler.lastObjectUnderMouse||this.eventHandler.hoverNode){var i=this.eventHandler.lastObjectUnderMouse||this.eventHandler.hoverNode;e.target=fs(i)===de?{connector:i}:{node:i}}else e.target.diagramId=this.element.id},t.prototype.removeChildInNodes=function(e){if(e){if(e.children)for(var i=0;i1){var l=2;if(e.children&&e.children.length>0)for(;e.children.indexOf(i.objects[s-l])>-1;)l++;this.commandHandler.moveSvgNode(e.id,i.objects[s-l]),this.commandHandler.moveSvgNode(i.objects[s-l],e.id)}else if(o){var h=this.commandHandler.getLayer(this.layerZIndexTable[o.zIndex]).objects[0];h?(this.commandHandler.moveSvgNode(e.id,h),this.commandHandler.updateNativeNodeIndex(e.id,h)):this.moveObjectsUp(e,i)}else this.moveObjectsUp(e,i)},t.prototype.moveObjectsUp=function(e,i){for(var r,s=this.layers.length-1;s>=0;s--)if(r=this.layers[parseInt(s.toString(),10)],i.id!==r.id){var o=this.commandHandler.getLayer(this.layerZIndexTable[r.zIndex]).objects[r.objects.length-1];if(o){this.commandHandler.moveSvgNode(e.id,o),this.commandHandler.moveSvgNode(o,e.id);break}}},t.prototype.insertData=function(e){return this.crudOperation(e,"create",this.getNewUpdateNodes("New"))},t.prototype.updateData=function(e){return this.crudOperation(e,"update",this.getNewUpdateNodes("Update"))},t.prototype.removeData=function(e){return this.crudOperation(e,"destroy",this.getDeletedNodes())},t.prototype.crudOperation=function(e,i,r){if(e){var s=this.parameterMap(e,!(e instanceof de));if(s){var o=e instanceof de?this.dataSourceSettings.connectionDataSource.crudAction[""+i]:this.dataSourceSettings.crudAction[""+i];this.raiseAjaxPost(JSON.stringify(s),o)}return s}var a=r;return this.processCrudCollection(a,this.dataSourceSettings.crudAction[""+i],this.dataSourceSettings.connectionDataSource.crudAction[""+i]),a},t.prototype.processCrudCollection=function(e,i,r){if(e.nodes){var s=[],o=void 0;for(o=0;o0&&this.raiseAjaxPost(JSON.stringify(s),i)}if(e.connectors){for(s=[],o=void 0,o=0;o0&&this.raiseAjaxPost(JSON.stringify(s),r)}},t.prototype.parameterMap=function(e,i){var s,r={},o=i?this.dataSourceSettings:this.dataSourceSettings.connectionDataSource;if(o.id&&(r[o.id]=e.id),o.sourcePointX&&o.sourcePointY&&(r[o.sourcePointX]=e.sourcePoint.x,r[o.sourcePointY]=e.sourcePoint.y),o.targetPointX&&o.targetPointY&&(r[o.targetPointX]=e.targetPoint.x,r[o.targetPointY]=e.targetPoint.y),o.sourceID&&(r[o.sourceID]=e.sourceID),o.targetID&&(r[o.targetID]=e.targetID),o.crudAction&&o.crudAction.customFields&&o.crudAction.customFields.length>0)for(s=0;s0&&(l=a.length),r.annotations=[{content:o.data.label[parseInt(l.toString(),10)]}]}s=this.getConnectorArrowType(o.data)}var h=new de(i,"connectors",r,!0);return s&&(h.style.strokeWidth=s.strokeWidth,h.targetDecorator.shape=s.targetDecorator),Ro(h,r,i.connectorDefaults),h},n.prototype.getConnectorArrowType=function(t){if(""===t.arrowType)return{targetDecorator:"Arrow",strokeWidth:1};switch(t.arrowType){case"None":return{targetDecorator:"None",strokeWidth:1};case"Arrow":default:return{targetDecorator:"Arrow",strokeWidth:1};case"Diamond":return{targetDecorator:"Diamond",strokeWidth:1};case"Circle":return{targetDecorator:"Circle",strokeWidth:1};case"OpenArrow":return{targetDecorator:"OpenArrow",strokeWidth:1};case"Square":return{targetDecorator:"Square",strokeWidth:1};case"Fletch":return{targetDecorator:"Fletch",strokeWidth:1};case"OpenFetch":return{targetDecorator:"OpenFetch",strokeWidth:1};case"IndentedArrow":return{targetDecorator:"IndentedArrow",strokeWidth:1};case"OutdentedArrow":return{targetDecorator:"OutdentedArrow",strokeWidth:1};case"DoubleArrow":return{targetDecorator:"DoubleArrow",strokeWidth:1}}},n}(),uae=function(){function n(){this.protectChange=!1,this.setIntervalObject=[]}return n.prototype.expand=function(t,e,i,r){var s=this,a=0;if(r.realActions=r.realActions|$i.AnimationClick,this.setIntervalObject[parseInt((0).toString(),10)]=setInterval(function(){return a++,s.layoutAnimation(e,s.setIntervalObject,6===a,r,i)},20),i.isExpanded){var l=.2;r.protectPropertyChange(!1);var h={};t&&(this.updateOpacity(i,l,r),h[parseInt((0).toString(),10)]=setInterval(function(){r.allowServerDataBinding=!1,l<=1?s.updateOpacity(i,l,r):clearInterval(h[0]),l+=.2,r.allowServerDataBinding=!0},20))}},n.prototype.stopCurrentAnimation=function(t,e,i){clearInterval(this.setIntervalObject[0]),this.setIntervalObject=[];for(var r=0;r0){t.rootNode=t.firstLevelNodes[0];var u=0,p=0,f=void 0,g=void 0,v=void 0,y=void 0,S=void 0;for(a=0;ad.y||(l.y=d.y),l.mid&&(e=l.mid),l.tree.assistants.length&&(y=this.setBreadthSpaceForAssistants(t,r,d,void 0!==e?e:d.x,b,s),u||(e=((g=p=y).x+g.right)/2-d.width/2,p=g),v=y?y.canMoveBy:void 0),l.x=e,l.translate||(l.treeWidth=p.right-p.x),this.translateSubTree({layout:t,shape:r,shapeBounds:{x:e,y:d.y,right:e+d.width,bottom:d.y+d.height},treeBounds:p,dim:d,level:s},v,void 0!==o,a),l.firstChild&&"string"!=typeof l.firstChild&&(l.firstChild.x+=l.subTreeTranslation),r.treeBounds=p,p},n.prototype.updateLeafNode=function(t,e,i,r,s,o){var a=t.graphNodes[e.id];a.x=r.x,a.y&&a.y>r.y||(a.y=r.y,a.maxLevel=Math.max(s,a.maxLevel||0));var l={x:r.x,y:r.y,right:r.x+r.width,bottom:r.y+r.height};return a.maxLevel=Math.max(a.maxLevel||0,s),this.translateSubTree({layout:t,shape:e,shapeBounds:l,treeBounds:l,dim:r,level:s},void 0,void 0!==i,o),{x:a.x,y:a.y,right:a.x+r.width,bottom:a.y+r.height}},n.prototype.setUpLayoutInfo=function(t,e){var i={subTreeTranslation:0};return i.tree="OrganizationalChart"===t.type?{orientation:"Vertical",type:"Alternate",offset:20,enableRouting:!0}:{orientation:"Horizontal",type:"Center",enableRouting:!0},i.tree.children=[],i.tree.assistants=[],i.tree.level=0,i.translate=!0,i},n.prototype.translateSubTree=function(t,e,i,r){var s=t.layout,o=t.shape,a=t.shapeBounds,l=t.treeBounds,h=t.level,c=t.dim,d=s.graphNodes[o.id],u=s.nameTable[d.firstChild?d.firstChild.child:d.tree.children[0]],p=u?s.graphNodes[u.id]:null,f=this.hasChild(s,o),g=this.findIntersectingLevels(s,a,h,d.actualLevel),v=this.findIntersectingLevels(s,l,h,d.actualLevel),y=[];g.length&&d.translate?(d.intersect=g,this.spaceLeftFromPrevSubTree(s,o,a),d.canMoveBy=d.diff,void 0!==e&&(d.canMoveBy=Math.min(e,d.canMoveBy)),u&&void 0!==p.canMoveBy&&(p.canMoveBy>=d.canMoveBy&&(d.translated=!0),d.canMoveBy=Math.min(d.canMoveBy,p.canMoveBy)),i&&(d.x-=d.canMoveBy,d.subTreeTranslation-=d.canMoveBy,f&&(this.shiftSubordinates(s,v,d.canMoveBy),l.x=Math.min(l.x,d.x),l.right=Math.max(l.right,d.x+c.width),l.bottom=Math.max(l.bottom,d.y+c.height),l.x-=d.canMoveBy,l.right-=d.canMoveBy),u&&p.canMoveBy>d.canMoveBy?d.canMoveBy=p.canMoveBy-d.canMoveBy:u&&void 0!==d.canMoveBy&&(d.canMoveBy=0))):(f&&(l.x=Math.min(l.x,a.x),l.right=Math.max(l.right,a.x+c.width),l.bottom=Math.max(l.bottom,d.y+c.height)),d.translate||(d.canMoveBy=0,d.subTreeTranslation=0)),r||(y.push({rBounds:a={x:d.x,y:c.y,right:d.x+c.width,bottom:c.y+c.height}}),this.updateRearBounds(s,o,y,h))},n.prototype.updateRearBounds=function(t,e,i,r,s){var o,a,h,d,l=!0,c={};e&&(s=(c=t.graphNodes[e.id]).intersect,l=!c.tree.children.length&&!c.tree.assistants.length);var u=i[0].rBounds,p=i[i.length-1].rBounds;if(s&&s.length){for(d=(o=t.levels[s[0]].rBounds).bottom,o.yp.bottom?i.push({rBounds:{x:o.x,right:o.right,y:u.bottom,bottom:d}}):(o=t.levels[s[s.length-1]].rBounds,l&&o.bottom>p.bottom&&(o.y=p.bottom,i.push({rBounds:o}))),a=s[0],h=i.length-1;h>=0;h--)t.levels.splice(a,0,i[parseInt(h.toString(),10)]);t.levels.splice(a+=i.length,s.length)}else for(a=this.findLevel(t,i[i.length-1].rBounds,r),h=i.length-1;h>=0;h--)t.levels.splice(a,0,i[parseInt(h.toString(),10)])},n.prototype.shiftSubordinates=function(t,e,i){var r;if(0!==i)for(r=0;rA.right&&(A.right=M.right),A.bottom=M.bottom):A=M,0===x&&(l.firstChild={x:R.x,canMoveBy:R.canMoveBy,child:g.id}),this.hasChild(t,g)&&(!l.firstChild||l.firstChild.x>=R.firstChild.x?(R.firstChild&&l.firstChild.canMoveByR.canMoveBy&&(l.firstChild.canMoveBy=t.graphNodes[l.firstChild.child].canMoveBy=R.canMoveBy)),w=w?Math.max(R.maxLevel,w):R.maxLevel,this.uniteRects(b,v),d=0!==x&&!this.hasChild(t,g)&&R.subTreeTranslation<0?v.right-R.subTreeTranslation+t.horizontalSpacing:v.right+t.horizontalSpacing;isNaN(C)||(L.canMoveBy=C),l.mid=(L.x+A.right)/2-a.width/2,"Left"===h?l.mid=M.right-a.width:"Right"===h&&(l.mid=r)}return b},n.prototype.updateHorizontalTreeWithMultipleRows=function(t,e,i,r,s,o){var a,l,h,c,d,f,g,v,y,S=this.getDimensions(t,e,r,s,o),b=t.graphNodes[e.id],w=o,C=r,D=s,x=(t.levels.slice(0,t.levels.length),0);if(this.hasChild(t,e)){var R=-1!==t.orientation.indexOf("Left"),L=void 0,O=this.splitChildrenInRows(t,e),N=5===b.tree.children.length&&3===O[0].length,T=[],P=[];N?P=O:this.splitRows(O,T,P);var _={leftTree:T,rows:O,rightTree:P,dimensions:S},B=this.updateLeftTree(t,_,e,r,D,w);d=_.bounds;var j=void 0;void 0!==B&&(b.mid=(B||0)+(void 0!==B?t.horizontalSpacing/2:0)-S.width/2,j=B+t.horizontalSpacing),D=s;var oe=void 0;for(oe=[],g=0;gl.canMoveBy)&&(x=Math.min(x,l.canMoveBy||0),b.firstChild={x:l.x,child:a.id,canMoveBy:l.canMoveBy}),_.leftCenter=v,_.rightCenter=y,_.align=L,_.level=w,_.rightBounds=oe,this.alignRowsToCenter(t,g,e,_,j)}return d},n.prototype.updateLeftTree=function(t,e,i,r,s,o){for(var h,d,u,p,f,a=e.leftTree,l=t.graphNodes[i.id],c=[],v=(t.orientation.indexOf("Left"),0);vw.canMoveBy&&(d=Math.min(d,w.canMoveBy||0),l.firstChild={x:w.x,child:S.id,canMoveBy:w.canMoveBy}),h=p.right+t.horizontalSpacing}u=0===v?c[parseInt(v.toString(),10)].right:Math.max(u,c[parseInt(v.toString(),10)].right)}for(v=0;v=g[1].right-g[1].x?0:1),e===c.length-1&&(c[parseInt(e.toString(),10)].length%2==1||S&&1===e)){a=d[parseInt(e.toString(),10)][Math.floor(d[parseInt(e.toString(),10)].length/2)];var M=t.graphNodes[""+a].x,C=this.getDimensions(t,t.nameTable[""+a],M,t.graphNodes[""+a].y,y+1);l=void 0,!f&&S?(1===o&&(e=0),l=(g[parseInt(o.toString(),10)].x+g[parseInt(o.toString(),10)].right)/2-(g[parseInt(e.toString(),10)].x+g[parseInt(e.toString(),10)].right)/2,0===e&&(h.mid+=l)):!S&&void 0!==s&&(l=s-t.horizontalSpacing/2-(M+C.width/2)),void 0!==l&&this.updateRearBoundsOfTree(t,d[parseInt(e.toString(),10)],l,v),S&&(h.mid=(p+u)/2+(0===e?l:0)-v.width/2),void 0===h.mid&&t.graphNodes[""+a]&&(h.mid=M),f=!1,e++}},n.prototype.updateRearBoundsOfTree=function(t,e,i,r){for(var s=0;s2?"Left":"Right",M=A%2==0&&y.tree.children.length>2?-1:0),w=i+this.findOffset(t,e,y,R),a=t.nameTable[y.tree.children[parseInt(A.toString(),10)]],d=b?a.actualSize.width:a.actualSize.height,h=this.updateTree(t,w+M*(c=b?a.actualSize.height:a.actualSize.width),C,a,s+1,void 0,!0),f={x:(l=t.graphNodes[a.id]).x,y:l.y,right:l.x+c,bottom:l.y+d},0===A?(this.uniteRects(h,f),p=h):this.uniteRects(p,h),l.prevBounds&&!("Alternate"===y.tree.type&&A%2==1&&y.tree.children.length>2)&&(N=void 0!==N?Math.min(l.canMoveBy,N):l.canMoveBy),y.maxLevel=Math.max(y.maxLevel||0,l.maxLevel||0),"Alternate"===y.tree.type&&y.tree.children.length>2&&A%2==0?(0!==A&&(C=u.bottom+t.verticalSpacing/2),O.push({rBounds:f}),l.levelBounds&&(O=O.concat(l.levelBounds))):(C="Alternate"===y.tree.type&&y.tree.children.length>2?Math.max(h.bottom,u.bottom)+t.verticalSpacing/2:h.bottom+t.verticalSpacing/2,s=y.maxLevel,L.push({rBounds:f}),v?this.uniteRects(v,f):v={x:l.x,y:l.y,right:l.x+c,bottom:l.y+d},l.levelBounds&&(L=L.concat(l.levelBounds))),0===A&&(y.firstChild={x:l.x,canMoveBy:l.canMoveBy,child:a.id}),this.hasChild(t,a))if(!y.firstChild||y.firstChild.x>=l.firstChild.x){if(l.firstChild&&y.firstChild.canMoveByl.canMoveBy&&(y.firstChild.canMoveBy=t.graphNodes[y.firstChild.child].canMoveBy=l.canMoveBy);u=f}return o?y.levelBounds=L:("Alternate"===y.tree.type&&y.tree.children.length>2&&(x=this.findIntersectingLevels(t,{x:O[0].rBounds.x,y:O[0].rBounds.y,right:O[O.length-1].rBounds.right,bottom:O[O.length-1].rBounds.bottom},D+1),this.updateRearBounds(t,null,O,D+1,x)),x=this.findIntersectingLevels(t,v||p,D+1),this.updateRearBounds(t,null,v?L:[{rBounds:p}],D+1,x)),isNaN(N)||(t.graphNodes[S.id].canMoveBy=N),y.childBounds=p,y.mid=i,p},n.prototype.splitChildrenInRows=function(t,e){var r,i=t.graphNodes[e.id];r=4;var o,s=[];o=i.tree.children.length;var a=this.extend(i.tree.children);if(i.tree.rows){var h=i.tree.rows;r=h%2==0?h:h-1}else 3===i.tree.children.length||4===i.tree.children.length?r=2:5===i.tree.children.length&&(r=3);for(;o>0;)s[s.length]=a.splice(0,r),(o-=r)=t.horizontalSpacing&&(s=t.horizontalSpacing/2),r||i.tree.type){case"Left":s=o/2-s;break;case"Right":s+=o/2}return s},n.prototype.uniteRects=function(t,e){t.x=Math.min(t.x,e.x),t.right=Math.max(t.right,e.right),t.bottom=Math.max(t.bottom,e.bottom)},n.prototype.spaceLeftFromPrevSubTree=function(t,e,i){for(var s,o,r=t.graphNodes[e.id],a=t.horizontalSpacing,l=0;la.y||s.y=a.y&&s.bottom<=a.bottom||s.ya.bottom))o.splice(0,0,l);else if(a&&a.bottom=0);l=(void 0!==r?r:i)+1,a=t.levels[parseInt(l.toString(),10)]?t.levels[parseInt(l.toString(),10)].rBounds:null;do{if(a&&(s.ya.y||s.y=a.y&&s.bottom<=a.bottom||s.ya.bottom))o.push(l);else if(a&&a.y>s.bottom)break;l++,a=t.levels[parseInt(l.toString(),10)]?t.levels[parseInt(l.toString(),10)].rBounds:null}while(l<=t.levels.length);return o},n.prototype.findLevel=function(t,e,i){var s,o,r=e;for(s=0,o=t.levels[parseInt(s.toString(),10)]?t.levels[parseInt(s.toString(),10)].rBounds:null;s=t.level&&(o.tree.hasSubTree=!1)},n.prototype.updateAnchor=function(t,e,i){var r,s,o=0,a=0,l=0,h=0,c=new Ne(0,0,i.x,i.y),d=t.bounds?t.bounds:c,u=t.orientation;if(t.fixedNode){o=(s=t.nameTable[t.fixedNode]).actualSize.width,a=s.actualSize.height,t.anchorX=s.offsetX,t.anchorY=s.offsetY;var p=s.pivot;for(t.anchorX+="RightToLeft"===t.orientation?o*p.x:-o*p.x,t.anchorY+="BottomToTop"===t.orientation?a*p.y:-a*p.y,r=s,l=0;r.inEdges.length;)r=this.getParentNode(t,r),l+=t.graphNodes[r.id].subTreeTranslation||0;-1!==t.orientation.indexOf("Left")?(h=t.graphNodes[s.id].y,"LeftToRight"===u?t.anchorX-=h:t.anchorX+=h,t.anchorY-=t.graphNodes[s.id].x+l):(h=t.graphNodes[s.id].y,t.anchorX-=t.graphNodes[s.id].x+l,"TopToBottom"===u?t.anchorY-=h:t.anchorY+=h)}else if("TopToBottom"===u||"BottomToTop"===u){switch(t.horizontalAlignment){case"Left":t.anchorX=d.x-e.x+t.margin.left;break;case"Right":t.anchorX=d.x+d.width-t.margin.right-e.right;break;case"Auto":case"Center":t.anchorX=d.x+d.width/2-(e.x+e.right)/2}switch(t.verticalAlignment){case"Auto":case"Top":var f;f=d.y+t.margin.top,t.anchorY="TopToBottom"===u?f:e.bottom+f;break;case"Bottom":var g;g=d.y+d.height-t.margin.bottom,t.anchorY="TopToBottom"===u?g-e.bottom:g;break;case"Center":var v=void 0;v=d.y+d.height/2,t.anchorY="TopToBottom"===t.orientation?v-(e.y+e.bottom)/2:v+(e.y+e.bottom)/2}}else{switch(t.horizontalAlignment){case"Auto":case"Left":var y;y=d.x+t.margin.left,t.anchorX="LeftToRight"===u?y:e.bottom+y;break;case"Right":var S;S=d.x+d.width-t.margin.right,t.anchorX="LeftToRight"===u?S-e.bottom:S;break;case"Center":v=void 0,v=d.width/2+d.x,t.anchorX="LeftToRight"===t.orientation?v-(e.y+e.bottom)/2:v+(e.y+e.bottom)/2}switch(t.verticalAlignment){case"Top":t.anchorY=d.y+t.margin.top-e.x;break;case"Auto":case"Center":t.anchorY=d.y+d.height/2-(e.right+e.x)/2;break;case"Bottom":t.anchorY=d.y+d.height-t.margin.bottom-e.right}}},n.prototype.updateConnectors=function(t,e,i){var r,s,o,a=t.graphNodes[e.id];if(e.outEdges.length)for(r=0;r2){l=o.tree.children[1],isNaN(t.graphNodes[""+l].treeWidth)&&(t.graphNodes[""+l].treeWidth=t.nameTable[""+l].actualSize.width);t.orientation.indexOf("Left"),this.getSegmentsForMultipleRows(t,i,r,e)}else o.tree.children.length>5?s<4||si.offsetX?a.middleRight:a.middleLeft).y},h)}else{var h;l=0===t.orientation.indexOf("Left")?o.middleRight:o.middleLeft,s.push(l,{x:a.bottomCenter.x,y:o.middleRight.y},h=e.offsetY>i.offsetY?a.bottomCenter:a.topCenter)}this.getSegmentsFromPoints(s,r)},n.prototype.get5Points=function(t,e,i,r){var l,h,c,d,s=[],o=this.getBounds(e),a=this.getBounds(i);-1!==t.orientation.indexOf("Top")?s.push(l=e.offsetYi.offsetX?a.middleRight:a.middleLeft).x+(c=t.horizontalSpacing/2*(e.offsetX>i.offsetX?1:-1)),y:l.y+d},{x:h.x+c,y:h.y},h):s.push(l=e.offsetX>i.offsetX?o.middleLeft:o.middleRight,{x:l.x+(c=t.horizontalSpacing/4*(e.offsetXi.offsetY?1:-1))},{x:(h=e.offsetY>i.offsetY?a.bottomCenter:a.topCenter).x,y:l.y+d},h),this.getSegmentsFromPoints(s,r)},n.prototype.getSegmentsFromPoints=function(t,e){for(var r,i=[],s=0;s"u"||(y.innerHTML=v.innerHTML?v.innerHTML:"",void 0!==v.className&&(y.className=v.className),void 0!==v.id&&(y.id=v.id),void 0!==v.styles&&y.setAttribute("style",v.styles),void 0!==e.ngAttr&&y.setAttribute(e.ngAttr,""),void 0!==v.attrs&&Fe(y,v.attrs)),y};for(var i=0,r=e.tags;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s}!function CZ(n){wC.compile=n.compile}({compile:function Hae(n,t){if("string"==typeof n||"function"==typeof n&&n.prototype&&n.prototype.CSPTemplate)return Rae(n,t);var e=n.elementRef.nativeElement._viewContainerRef,i=n.elementRef.nativeElement.propName;return function(r,s,o){var l=e||s.viewContainerRef,h=l.createEmbeddedView(n,{$implicit:r});/EJS-MENTION|EJS-DROPDOWNLIST/.test(Y("currentInstance.element.nodeName",l))||/E-TABITEM/.test(Y("element.nativeElement.nodeName",l))?h.detectChanges():h.markForCheck();var c=s&&s.registeredTemplate?s.registeredTemplate:Y("currentInstance.registeredTemplate",l);return typeof c["".concat(o=o&&s.registeredTemplate?o:i)]>"u"&&(c["".concat(o)]=[]),c["".concat(o)].push(h),h.rootNodes}}});const jae=["annotationTemplate"],Vae=["nodeTemplate"],Wae=["userHandleTemplate"];let Yae=["addInfo","id","lock","objects","visible","zIndex"],Qae=[],Gae=(()=>{class n extends Hh{constructor(e){super(),this.viewContainerRef=e,Rl("currentInstance",this,this.viewContainerRef),this.registerEvents(Qae),this.directivePropList=Yae}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-layer"]],inputs:{addInfo:"addInfo",id:"id",lock:"lock",objects:"objects",visible:"visible",zIndex:"zIndex"},features:[yn]}),n})(),Xae=(()=>{class n extends Bh{constructor(){super("layers")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-layers"]],contentQueries:function(e,i,r){if(1&e&&dn(r,Gae,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),qae=["action","cursor"],$ae=[],Zae=(()=>{class n extends Hh{constructor(e){super(),this.viewContainerRef=e,Rl("currentInstance",this,this.viewContainerRef),this.registerEvents($ae),this.directivePropList=qae}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-cursormap"]],inputs:{action:"action",cursor:"cursor"},features:[yn]}),n})(),Jae=(()=>{class n extends Bh{constructor(){super("customcursor")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-cursormaps"]],contentQueries:function(e,i,r){if(1&e&&dn(r,Zae,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),Kae=["alignment","cornerRadius","displacement","fill","handleStrokeColor","handleStrokeWidth","height","iconStrokeColor","iconStrokeWidth","id","offset","padding","pathData","tooltip","visibility","width"],ele=[],tle=(()=>{class n extends Hh{constructor(e){super(),this.viewContainerRef=e,Rl("currentInstance",this,this.viewContainerRef),this.registerEvents(ele),this.directivePropList=Kae}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-connector-fixeduserhandle"]],inputs:{alignment:"alignment",cornerRadius:"cornerRadius",displacement:"displacement",fill:"fill",handleStrokeColor:"handleStrokeColor",handleStrokeWidth:"handleStrokeWidth",height:"height",iconStrokeColor:"iconStrokeColor",iconStrokeWidth:"iconStrokeWidth",id:"id",offset:"offset",padding:"padding",pathData:"pathData",tooltip:"tooltip",visibility:"visibility",width:"width"},features:[yn]}),n})(),ile=(()=>{class n extends Bh{constructor(){super("fixeduserhandles")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-connector-fixeduserhandles"]],contentQueries:function(e,i,r){if(1&e&&dn(r,tle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),rle=["addInfo","alignment","annotationType","constraints","content","displacement","dragLimit","height","horizontalAlignment","hyperlink","id","margin","offset","rotateAngle","rotationReference","segmentAngle","style","template","tooltip","type","verticalAlignment","visibility","width"],nle=[],sle=(()=>{class n extends Hh{constructor(e){super(),this.viewContainerRef=e,Rl("currentInstance",this,this.viewContainerRef),this.registerEvents(nle),this.directivePropList=rle}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-connector-annotation"]],inputs:{addInfo:"addInfo",alignment:"alignment",annotationType:"annotationType",constraints:"constraints",content:"content",displacement:"displacement",dragLimit:"dragLimit",height:"height",horizontalAlignment:"horizontalAlignment",hyperlink:"hyperlink",id:"id",margin:"margin",offset:"offset",rotateAngle:"rotateAngle",rotationReference:"rotationReference",segmentAngle:"segmentAngle",style:"style",template:"template",tooltip:"tooltip",type:"type",verticalAlignment:"verticalAlignment",visibility:"visibility",width:"width"},features:[yn]}),n})(),ole=(()=>{class n extends Bh{constructor(){super("annotations")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-connector-annotations"]],contentQueries:function(e,i,r){if(1&e&&dn(r,sle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),ale=["addInfo","allowNodeOverlap","annotations","bezierSettings","bridgeSpace","connectionPadding","connectorSpacing","constraints","cornerRadius","dragSize","excludeFromLayout","fixedUserHandles","flip","flipMode","hitPadding","id","margin","maxSegmentThumb","ports","previewSize","segmentThumbShape","segmentThumbSize","segments","shape","sourceDecorator","sourceID","sourcePadding","sourcePoint","sourcePortID","style","symbolInfo","targetDecorator","targetID","targetPadding","targetPoint","targetPortID","tooltip","type","visible","wrapper","zIndex"],lle=[],hle=(()=>{class n extends Hh{constructor(e){super(),this.viewContainerRef=e,this.tags=["fixedUserHandles","annotations"],Rl("currentInstance",this,this.viewContainerRef),this.registerEvents(lle),this.directivePropList=ale}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-connector"]],contentQueries:function(e,i,r){if(1&e&&(dn(r,ile,5),dn(r,ole,5)),2&e){let s;Kr(s=en())&&(i.childFixedUserHandles=s.first),Kr(s=en())&&(i.childAnnotations=s.first)}},inputs:{addInfo:"addInfo",allowNodeOverlap:"allowNodeOverlap",annotations:"annotations",bezierSettings:"bezierSettings",bridgeSpace:"bridgeSpace",connectionPadding:"connectionPadding",connectorSpacing:"connectorSpacing",constraints:"constraints",cornerRadius:"cornerRadius",dragSize:"dragSize",excludeFromLayout:"excludeFromLayout",fixedUserHandles:"fixedUserHandles",flip:"flip",flipMode:"flipMode",hitPadding:"hitPadding",id:"id",margin:"margin",maxSegmentThumb:"maxSegmentThumb",ports:"ports",previewSize:"previewSize",segmentThumbShape:"segmentThumbShape",segmentThumbSize:"segmentThumbSize",segments:"segments",shape:"shape",sourceDecorator:"sourceDecorator",sourceID:"sourceID",sourcePadding:"sourcePadding",sourcePoint:"sourcePoint",sourcePortID:"sourcePortID",style:"style",symbolInfo:"symbolInfo",targetDecorator:"targetDecorator",targetID:"targetID",targetPadding:"targetPadding",targetPoint:"targetPoint",targetPortID:"targetPortID",tooltip:"tooltip",type:"type",visible:"visible",wrapper:"wrapper",zIndex:"zIndex"},features:[yn]}),n})(),cle=(()=>{class n extends Bh{constructor(){super("connectors")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-connectors"]],contentQueries:function(e,i,r){if(1&e&&dn(r,hle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),dle=["cornerRadius","fill","handleStrokeColor","handleStrokeWidth","height","iconStrokeColor","iconStrokeWidth","id","margin","offset","padding","pathData","tooltip","visibility","width"],ule=[],ple=(()=>{class n extends Hh{constructor(e){super(),this.viewContainerRef=e,Rl("currentInstance",this,this.viewContainerRef),this.registerEvents(ule),this.directivePropList=dle}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-node-fixeduserhandle"]],inputs:{cornerRadius:"cornerRadius",fill:"fill",handleStrokeColor:"handleStrokeColor",handleStrokeWidth:"handleStrokeWidth",height:"height",iconStrokeColor:"iconStrokeColor",iconStrokeWidth:"iconStrokeWidth",id:"id",margin:"margin",offset:"offset",padding:"padding",pathData:"pathData",tooltip:"tooltip",visibility:"visibility",width:"width"},features:[yn]}),n})(),fle=(()=>{class n extends Bh{constructor(){super("fixeduserhandles")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-node-fixeduserhandles"]],contentQueries:function(e,i,r){if(1&e&&dn(r,ple,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),gle=["addInfo","annotationType","constraints","content","dragLimit","height","horizontalAlignment","hyperlink","id","margin","offset","rotateAngle","rotationReference","style","template","tooltip","type","verticalAlignment","visibility","width"],vle=[],mle=(()=>{class n extends Hh{constructor(e){super(),this.viewContainerRef=e,Rl("currentInstance",this,this.viewContainerRef),this.registerEvents(vle),this.directivePropList=gle}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-node-annotation"]],inputs:{addInfo:"addInfo",annotationType:"annotationType",constraints:"constraints",content:"content",dragLimit:"dragLimit",height:"height",horizontalAlignment:"horizontalAlignment",hyperlink:"hyperlink",id:"id",margin:"margin",offset:"offset",rotateAngle:"rotateAngle",rotationReference:"rotationReference",style:"style",template:"template",tooltip:"tooltip",type:"type",verticalAlignment:"verticalAlignment",visibility:"visibility",width:"width"},features:[yn]}),n})(),yle=(()=>{class n extends Bh{constructor(){super("annotations")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-node-annotations"]],contentQueries:function(e,i,r){if(1&e&&dn(r,mle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),Sle=["addInfo","connectionDirection","constraints","height","horizontalAlignment","id","inEdges","margin","offset","outEdges","pathData","shape","style","tooltip","verticalAlignment","visibility","width"],Ile=[],ble=(()=>{class n extends Hh{constructor(e){super(),this.viewContainerRef=e,Rl("currentInstance",this,this.viewContainerRef),this.registerEvents(Ile),this.directivePropList=Sle}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-node-port"]],inputs:{addInfo:"addInfo",connectionDirection:"connectionDirection",constraints:"constraints",height:"height",horizontalAlignment:"horizontalAlignment",id:"id",inEdges:"inEdges",margin:"margin",offset:"offset",outEdges:"outEdges",pathData:"pathData",shape:"shape",style:"style",tooltip:"tooltip",verticalAlignment:"verticalAlignment",visibility:"visibility",width:"width"},features:[yn]}),n})(),Mle=(()=>{class n extends Bh{constructor(){super("ports")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-node-ports"]],contentQueries:function(e,i,r){if(1&e&&dn(r,ble,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),wle=["addInfo","annotations","backgroundColor","borderColor","borderWidth","branch","children","collapseIcon","columnIndex","columnSpan","columns","constraints","container","data","dragSize","excludeFromLayout","expandIcon","fixedUserHandles","flip","flipMode","height","horizontalAlignment","id","isExpanded","layoutInfo","margin","maxHeight","maxWidth","minHeight","minWidth","offsetX","offsetY","padding","pivot","ports","previewSize","rotateAngle","rowIndex","rowSpan","rows","shadow","shape","style","symbolInfo","tooltip","verticalAlignment","visible","width","wrapper","zIndex"],Cle=[],Ele=(()=>{class n extends Hh{constructor(e){super(),this.viewContainerRef=e,this.tags=["fixedUserHandles","annotations","ports"],Rl("currentInstance",this,this.viewContainerRef),this.registerEvents(Cle),this.directivePropList=wle}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-node"]],contentQueries:function(e,i,r){if(1&e&&(dn(r,fle,5),dn(r,yle,5),dn(r,Mle,5)),2&e){let s;Kr(s=en())&&(i.childFixedUserHandles=s.first),Kr(s=en())&&(i.childAnnotations=s.first),Kr(s=en())&&(i.childPorts=s.first)}},inputs:{addInfo:"addInfo",annotations:"annotations",backgroundColor:"backgroundColor",borderColor:"borderColor",borderWidth:"borderWidth",branch:"branch",children:"children",collapseIcon:"collapseIcon",columnIndex:"columnIndex",columnSpan:"columnSpan",columns:"columns",constraints:"constraints",container:"container",data:"data",dragSize:"dragSize",excludeFromLayout:"excludeFromLayout",expandIcon:"expandIcon",fixedUserHandles:"fixedUserHandles",flip:"flip",flipMode:"flipMode",height:"height",horizontalAlignment:"horizontalAlignment",id:"id",isExpanded:"isExpanded",layoutInfo:"layoutInfo",margin:"margin",maxHeight:"maxHeight",maxWidth:"maxWidth",minHeight:"minHeight",minWidth:"minWidth",offsetX:"offsetX",offsetY:"offsetY",padding:"padding",pivot:"pivot",ports:"ports",previewSize:"previewSize",rotateAngle:"rotateAngle",rowIndex:"rowIndex",rowSpan:"rowSpan",rows:"rows",shadow:"shadow",shape:"shape",style:"style",symbolInfo:"symbolInfo",tooltip:"tooltip",verticalAlignment:"verticalAlignment",visible:"visible",width:"width",wrapper:"wrapper",zIndex:"zIndex"},features:[yn]}),n})(),Dle=(()=>{class n extends Bh{constructor(){super("nodes")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-nodes"]],contentQueries:function(e,i,r){if(1&e&&dn(r,Ele,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})();const xle=["animationComplete","click","collectionChange","commandExecute","connectionChange","contextMenuBeforeItemRender","contextMenuClick","contextMenuOpen","created","dataLoaded","doubleClick","dragEnter","dragLeave","dragOver","drop","elementDraw","expandStateChange","fixedUserHandleClick","historyChange","historyStateChange","keyDown","keyUp","load","loaded","mouseEnter","mouseLeave","mouseOver","mouseWheel","onFixedUserHandleMouseDown","onFixedUserHandleMouseEnter","onFixedUserHandleMouseLeave","onFixedUserHandleMouseUp","onImageLoad","onUserHandleMouseDown","onUserHandleMouseEnter","onUserHandleMouseLeave","onUserHandleMouseUp","positionChange","propertyChange","rotateChange","scrollChange","segmentChange","segmentCollectionChange","selectionChange","sizeChange","sourcePointChange","targetPointChange","textEdit"],Tle=[""];let Ale=(()=>{let n=class extends zl{constructor(e,i,r,s){super(),this.ngEle=e,this.srenderer=i,this.viewContainerRef=r,this.injector=s,this.tags=["layers","customCursor","connectors","nodes"],this.element=this.ngEle.nativeElement,this.injectedModules=this.injectedModules||[];try{let o=this.injector.get("DiagramsHierarchicalTree");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsMindMap");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsRadialTree");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsComplexHierarchicalTree");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsDataBinding");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsSnapping");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsPrintAndExport");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsBpmnDiagrams");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsSymmetricLayout");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsConnectorBridging");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsUndoRedo");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsLayoutAnimation");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsDiagramContextMenu");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsLineRouting");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsConnectorEditing");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsLineDistribution");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsEj1Serialization");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsFlowchartLayout");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}this.registerEvents(xle),this.addTwoWay.call(this,Tle),Rl("currentInstance",this,this.viewContainerRef),this.context=new c_}ngOnInit(){this.context.ngOnInit(this)}ngAfterViewInit(){this.context.ngAfterViewInit(this)}ngOnDestroy(){this.context.ngOnDestroy(this)}ngAfterContentChecked(){this.tagObjects[0].instance=this.childLayers,this.childCustomCursor&&(this.tagObjects[1].instance=this.childCustomCursor),this.childConnectors&&(this.tagObjects[2].instance=this.childConnectors),this.childNodes&&(this.tagObjects[3].instance=this.childNodes),this.context.ngAfterContentChecked(this)}};return n.\u0275fac=function(e){return new(e||n)(Ot($c),Ot(nM),Ot(xn),Ot(Wo))},n.\u0275cmp=Pb({type:n,selectors:[["ejs-diagram"]],contentQueries:function(e,i,r){if(1&e&&(dn(r,jae,5),dn(r,Vae,5),dn(r,Wae,5),dn(r,Xae,5),dn(r,Jae,5),dn(r,cle,5),dn(r,Dle,5)),2&e){let s;Kr(s=en())&&(i.annotationTemplate=s.first),Kr(s=en())&&(i.nodeTemplate=s.first),Kr(s=en())&&(i.userHandleTemplate=s.first),Kr(s=en())&&(i.childLayers=s.first),Kr(s=en())&&(i.childCustomCursor=s.first),Kr(s=en())&&(i.childConnectors=s.first),Kr(s=en())&&(i.childNodes=s.first)}},inputs:{addInfo:"addInfo",annotationTemplate:"annotationTemplate",backgroundColor:"backgroundColor",bridgeDirection:"bridgeDirection",commandManager:"commandManager",connectorDefaults:"connectorDefaults",connectors:"connectors",constraints:"constraints",contextMenuSettings:"contextMenuSettings",customCursor:"customCursor",dataSourceSettings:"dataSourceSettings",diagramSettings:"diagramSettings",drawingObject:"drawingObject",enableConnectorSplit:"enableConnectorSplit",enablePersistence:"enablePersistence",enableRtl:"enableRtl",fixedUserHandleTemplate:"fixedUserHandleTemplate",getConnectorDefaults:"getConnectorDefaults",getCustomCursor:"getCustomCursor",getCustomProperty:"getCustomProperty",getCustomTool:"getCustomTool",getDescription:"getDescription",getNodeDefaults:"getNodeDefaults",height:"height",historyManager:"historyManager",layers:"layers",layout:"layout",locale:"locale",mode:"mode",nodeDefaults:"nodeDefaults",nodeTemplate:"nodeTemplate",nodes:"nodes",pageSettings:"pageSettings",rulerSettings:"rulerSettings",scrollSettings:"scrollSettings",segmentThumbShape:"segmentThumbShape",segmentThumbSize:"segmentThumbSize",selectedItems:"selectedItems",serializationSettings:"serializationSettings",setNodeTemplate:"setNodeTemplate",snapSettings:"snapSettings",tool:"tool",tooltip:"tooltip",updateSelection:"updateSelection",userHandleTemplate:"userHandleTemplate",width:"width"},outputs:{animationComplete:"animationComplete",click:"click",collectionChange:"collectionChange",commandExecute:"commandExecute",connectionChange:"connectionChange",contextMenuBeforeItemRender:"contextMenuBeforeItemRender",contextMenuClick:"contextMenuClick",contextMenuOpen:"contextMenuOpen",created:"created",dataLoaded:"dataLoaded",doubleClick:"doubleClick",dragEnter:"dragEnter",dragLeave:"dragLeave",dragOver:"dragOver",drop:"drop",elementDraw:"elementDraw",expandStateChange:"expandStateChange",fixedUserHandleClick:"fixedUserHandleClick",historyChange:"historyChange",historyStateChange:"historyStateChange",keyDown:"keyDown",keyUp:"keyUp",load:"load",loaded:"loaded",mouseEnter:"mouseEnter",mouseLeave:"mouseLeave",mouseOver:"mouseOver",mouseWheel:"mouseWheel",onFixedUserHandleMouseDown:"onFixedUserHandleMouseDown",onFixedUserHandleMouseEnter:"onFixedUserHandleMouseEnter",onFixedUserHandleMouseLeave:"onFixedUserHandleMouseLeave",onFixedUserHandleMouseUp:"onFixedUserHandleMouseUp",onImageLoad:"onImageLoad",onUserHandleMouseDown:"onUserHandleMouseDown",onUserHandleMouseEnter:"onUserHandleMouseEnter",onUserHandleMouseLeave:"onUserHandleMouseLeave",onUserHandleMouseUp:"onUserHandleMouseUp",positionChange:"positionChange",propertyChange:"propertyChange",rotateChange:"rotateChange",scrollChange:"scrollChange",segmentChange:"segmentChange",segmentCollectionChange:"segmentCollectionChange",selectionChange:"selectionChange",sizeChange:"sizeChange",sourcePointChange:"sourcePointChange",targetPointChange:"targetPointChange",textEdit:"textEdit"},features:[yn],decls:0,vars:0,template:function(e,i){},encapsulation:2,changeDetection:0}),cb([xT()],n.prototype,"annotationTemplate",void 0),cb([xT()],n.prototype,"nodeTemplate",void 0),cb([xT()],n.prototype,"userHandleTemplate",void 0),n=cb([Pae([c_])],n),n})(),Lle=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=xm({type:n}),n.\u0275inj=gf({imports:[[tq]]}),n})();const Nle={provide:"DiagramsHierarchicalTree",useValue:n_},Ole={provide:"DiagramsDataBinding",useValue:Koe},kle={provide:"DiagramsLayoutAnimation",useValue:uae},Ple=["diagram"];let zle=(()=>{class n{constructor(){this.data=[{Id:"parent1",Name:"Maria ",Designation:"Managing Director",RatingColor:"#C34444"},{Id:"parent",Name:" sam",Designation:"Managing Director",ReportingPerson:"parent1",RatingColor:"#C34444"}]}getNodeDefaults(e,i){return e.height=40,e.width=100,e.expandIcon={height:15,width:15,shape:"Plus",fill:"lightgray",offset:{x:.5,y:.85}},e.collapseIcon.offset={x:.5,y:.85},e.collapseIcon.height=15,e.collapseIcon.width=15,e.collapseIcon.shape="Minus",e.borderColor="white",e.backgroundColor="#6BA5D7",e.borderWidth=1,e.style={fill:"transparent",strokeWidth:2},e}getConnectorDefaults(e,i){return e.style={strokeColor:"#6BA5D7",strokeWidth:2},e.targetDecorator.style.fill="#6BA5D7",e.targetDecorator.style.strokeColor="#6BA5D7",e.targetDecorator.shape="None",e.type="Orthogonal",e}ngOnInit(){this.selectedItems={constraints:~lr.ResizeAll},this.snapSettings={constraints:0},this.items=new nt(this.data,(new _t).take(7)),this.layout={enableAnimation:!0,type:"HierarchicalTree",margin:{top:20},getLayoutInfo:(e,i)=>{i.hasSubTree||(i.orientation="vertical",i.type="alternate")}},this.dataSourceSettings={id:"Id",parentId:"ReportingPerson",dataSource:this.items}}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275cmp=Pb({type:n,selectors:[["app-container"]],viewQuery:function(i,r){if(1&i&&function dP(n,t,e){const i=xi();i.firstCreatePass&&(hP(i,new oP(n,t,e),-1),2==(2&t)&&(i.staticViewQueries=!0)),lP(i,Se(),t)}(Ple,5),2&i){let s;Kr(s=en())&&(r.diagram=s.first)}},standalone:!0,features:[OP([Nle,Ole,kle]),PP],decls:2,vars:6,consts:[["id","diagram","width","100%","height","580px",3,"getNodeDefaults","getConnectorDefaults","snapSettings","selectedItems","layout","dataSourceSettings"],["diagram",""]],template:function(i,r){1&i&&ew(0,"ejs-diagram",0,1),2&i&&YM("getNodeDefaults",r.getNodeDefaults)("getConnectorDefaults",r.getConnectorDefaults)("snapSettings",r.snapSettings)("selectedItems",r.selectedItems)("layout",r.layout)("dataSourceSettings",r.dataSourceSettings)},dependencies:[Lle,Ale],encapsulation:2})}}return n})();Ud(332),function Qq(n,t){return MG({rootComponent:n,...wz(t)})}(zle).catch(n=>console.error(n))},332:()=>{!function(Z){const se=Z.performance;function ye(Pi){se&&se.mark&&se.mark(Pi)}function fe(Pi,ht){se&&se.measure&&se.measure(Pi,ht)}ye("Zone");const be=Z.__Zone_symbol_prefix||"__zone_symbol__";function ke(Pi){return be+Pi}const at=!0===Z[ke("forceDuplicateZoneCheck")];if(Z.Zone){if(at||"function"!=typeof Z.Zone.__symbol__)throw new Error("Zone already loaded.");return Z.Zone}let tt=(()=>{class Pi{static{this.__symbol__=ke}static assertZonePatched(){if(Z.Promise!==_o.ZoneAwarePromise)throw new Error("Zone.js has detected that ZoneAwarePromise `(window|global).Promise` has been overwritten.\nMost likely cause is that a Promise polyfill has been loaded after Zone.js (Polyfilling Promise api is not necessary when zone.js is loaded. If you must load one, do so before loading zone.js.)")}static get root(){let F=Pi.current;for(;F.parent;)F=F.parent;return F}static get current(){return Ur.zone}static get currentTask(){return Do}static __load_patch(F,ae,Et=!1){if(_o.hasOwnProperty(F)){if(!Et&&at)throw Error("Already loaded patch: "+F)}else if(!Z["__Zone_disable_"+F]){const Xt="Zone:"+F;ye(Xt),_o[F]=ae(Z,Pi,cn),fe(Xt,Xt)}}get parent(){return this._parent}get name(){return this._name}constructor(F,ae){this._parent=F,this._name=ae?ae.name||"unnamed":"",this._properties=ae&&ae.properties||{},this._zoneDelegate=new Lt(this,this._parent&&this._parent._zoneDelegate,ae)}get(F){const ae=this.getZoneWith(F);if(ae)return ae._properties[F]}getZoneWith(F){let ae=this;for(;ae;){if(ae._properties.hasOwnProperty(F))return ae;ae=ae._parent}return null}fork(F){if(!F)throw new Error("ZoneSpec required!");return this._zoneDelegate.fork(this,F)}wrap(F,ae){if("function"!=typeof F)throw new Error("Expecting function got: "+F);const Et=this._zoneDelegate.intercept(this,F,ae),Xt=this;return function(){return Xt.runGuarded(Et,this,arguments,ae)}}run(F,ae,Et,Xt){Ur={parent:Ur,zone:this};try{return this._zoneDelegate.invoke(this,F,ae,Et,Xt)}finally{Ur=Ur.parent}}runGuarded(F,ae=null,Et,Xt){Ur={parent:Ur,zone:this};try{try{return this._zoneDelegate.invoke(this,F,ae,Et,Xt)}catch(Un){if(this._zoneDelegate.handleError(this,Un))throw Un}}finally{Ur=Ur.parent}}runTask(F,ae,Et){if(F.zone!=this)throw new Error("A task can only be run in the zone of creation! (Creation: "+(F.zone||_n).name+"; Execution: "+this.name+")");if(F.state===sr&&(F.type===ts||F.type===Pt))return;const Xt=F.state!=lt;Xt&&F._transitionTo(lt,ki),F.runCount++;const Un=Do;Do=F,Ur={parent:Ur,zone:this};try{F.type==Pt&&F.data&&!F.data.isPeriodic&&(F.cancelFn=void 0);try{return this._zoneDelegate.invokeTask(this,F,ae,Et)}catch(Ue){if(this._zoneDelegate.handleError(this,Ue))throw Ue}}finally{F.state!==sr&&F.state!==et&&(F.type==ts||F.data&&F.data.isPeriodic?Xt&&F._transitionTo(ki,lt):(F.runCount=0,this._updateTaskCount(F,-1),Xt&&F._transitionTo(sr,lt,sr))),Ur=Ur.parent,Do=Un}}scheduleTask(F){if(F.zone&&F.zone!==this){let Et=this;for(;Et;){if(Et===F.zone)throw Error(`can not reschedule task to ${this.name} which is descendants of the original zone ${F.zone.name}`);Et=Et.parent}}F._transitionTo(Zr,sr);const ae=[];F._zoneDelegates=ae,F._zone=this;try{F=this._zoneDelegate.scheduleTask(this,F)}catch(Et){throw F._transitionTo(et,Zr,sr),this._zoneDelegate.handleError(this,Et),Et}return F._zoneDelegates===ae&&this._updateTaskCount(F,1),F.state==Zr&&F._transitionTo(ki,Zr),F}scheduleMicroTask(F,ae,Et,Xt){return this.scheduleTask(new ft(vi,F,ae,Et,Xt,void 0))}scheduleMacroTask(F,ae,Et,Xt,Un){return this.scheduleTask(new ft(Pt,F,ae,Et,Xt,Un))}scheduleEventTask(F,ae,Et,Xt,Un){return this.scheduleTask(new ft(ts,F,ae,Et,Xt,Un))}cancelTask(F){if(F.zone!=this)throw new Error("A task can only be cancelled in the zone of creation! (Creation: "+(F.zone||_n).name+"; Execution: "+this.name+")");if(F.state===ki||F.state===lt){F._transitionTo(ur,ki,lt);try{this._zoneDelegate.cancelTask(this,F)}catch(ae){throw F._transitionTo(et,ur),this._zoneDelegate.handleError(this,ae),ae}return this._updateTaskCount(F,-1),F._transitionTo(sr,ur),F.runCount=0,F}}_updateTaskCount(F,ae){const Et=F._zoneDelegates;-1==ae&&(F._zoneDelegates=null);for(let Xt=0;XtPi.hasTask(F,ae),onScheduleTask:(Pi,ht,F,ae)=>Pi.scheduleTask(F,ae),onInvokeTask:(Pi,ht,F,ae,Et,Xt)=>Pi.invokeTask(F,ae,Et,Xt),onCancelTask:(Pi,ht,F,ae)=>Pi.cancelTask(F,ae)};class Lt{constructor(ht,F,ae){this._taskCounts={microTask:0,macroTask:0,eventTask:0},this.zone=ht,this._parentDelegate=F,this._forkZS=ae&&(ae&&ae.onFork?ae:F._forkZS),this._forkDlgt=ae&&(ae.onFork?F:F._forkDlgt),this._forkCurrZone=ae&&(ae.onFork?this.zone:F._forkCurrZone),this._interceptZS=ae&&(ae.onIntercept?ae:F._interceptZS),this._interceptDlgt=ae&&(ae.onIntercept?F:F._interceptDlgt),this._interceptCurrZone=ae&&(ae.onIntercept?this.zone:F._interceptCurrZone),this._invokeZS=ae&&(ae.onInvoke?ae:F._invokeZS),this._invokeDlgt=ae&&(ae.onInvoke?F:F._invokeDlgt),this._invokeCurrZone=ae&&(ae.onInvoke?this.zone:F._invokeCurrZone),this._handleErrorZS=ae&&(ae.onHandleError?ae:F._handleErrorZS),this._handleErrorDlgt=ae&&(ae.onHandleError?F:F._handleErrorDlgt),this._handleErrorCurrZone=ae&&(ae.onHandleError?this.zone:F._handleErrorCurrZone),this._scheduleTaskZS=ae&&(ae.onScheduleTask?ae:F._scheduleTaskZS),this._scheduleTaskDlgt=ae&&(ae.onScheduleTask?F:F._scheduleTaskDlgt),this._scheduleTaskCurrZone=ae&&(ae.onScheduleTask?this.zone:F._scheduleTaskCurrZone),this._invokeTaskZS=ae&&(ae.onInvokeTask?ae:F._invokeTaskZS),this._invokeTaskDlgt=ae&&(ae.onInvokeTask?F:F._invokeTaskDlgt),this._invokeTaskCurrZone=ae&&(ae.onInvokeTask?this.zone:F._invokeTaskCurrZone),this._cancelTaskZS=ae&&(ae.onCancelTask?ae:F._cancelTaskZS),this._cancelTaskDlgt=ae&&(ae.onCancelTask?F:F._cancelTaskDlgt),this._cancelTaskCurrZone=ae&&(ae.onCancelTask?this.zone:F._cancelTaskCurrZone),this._hasTaskZS=null,this._hasTaskDlgt=null,this._hasTaskDlgtOwner=null,this._hasTaskCurrZone=null;const Et=ae&&ae.onHasTask;(Et||F&&F._hasTaskZS)&&(this._hasTaskZS=Et?ae:At,this._hasTaskDlgt=F,this._hasTaskDlgtOwner=this,this._hasTaskCurrZone=ht,ae.onScheduleTask||(this._scheduleTaskZS=At,this._scheduleTaskDlgt=F,this._scheduleTaskCurrZone=this.zone),ae.onInvokeTask||(this._invokeTaskZS=At,this._invokeTaskDlgt=F,this._invokeTaskCurrZone=this.zone),ae.onCancelTask||(this._cancelTaskZS=At,this._cancelTaskDlgt=F,this._cancelTaskCurrZone=this.zone))}fork(ht,F){return this._forkZS?this._forkZS.onFork(this._forkDlgt,this.zone,ht,F):new tt(ht,F)}intercept(ht,F,ae){return this._interceptZS?this._interceptZS.onIntercept(this._interceptDlgt,this._interceptCurrZone,ht,F,ae):F}invoke(ht,F,ae,Et,Xt){return this._invokeZS?this._invokeZS.onInvoke(this._invokeDlgt,this._invokeCurrZone,ht,F,ae,Et,Xt):F.apply(ae,Et)}handleError(ht,F){return!this._handleErrorZS||this._handleErrorZS.onHandleError(this._handleErrorDlgt,this._handleErrorCurrZone,ht,F)}scheduleTask(ht,F){let ae=F;if(this._scheduleTaskZS)this._hasTaskZS&&ae._zoneDelegates.push(this._hasTaskDlgtOwner),ae=this._scheduleTaskZS.onScheduleTask(this._scheduleTaskDlgt,this._scheduleTaskCurrZone,ht,F),ae||(ae=F);else if(F.scheduleFn)F.scheduleFn(F);else{if(F.type!=vi)throw new Error("Task is missing scheduleFn.");Wt(F)}return ae}invokeTask(ht,F,ae,Et){return this._invokeTaskZS?this._invokeTaskZS.onInvokeTask(this._invokeTaskDlgt,this._invokeTaskCurrZone,ht,F,ae,Et):F.callback.apply(ae,Et)}cancelTask(ht,F){let ae;if(this._cancelTaskZS)ae=this._cancelTaskZS.onCancelTask(this._cancelTaskDlgt,this._cancelTaskCurrZone,ht,F);else{if(!F.cancelFn)throw Error("Task is not cancelable");ae=F.cancelFn(F)}return ae}hasTask(ht,F){try{this._hasTaskZS&&this._hasTaskZS.onHasTask(this._hasTaskDlgt,this._hasTaskCurrZone,ht,F)}catch(ae){this.handleError(ht,ae)}}_updateTaskCount(ht,F){const ae=this._taskCounts,Et=ae[ht],Xt=ae[ht]=Et+F;if(Xt<0)throw new Error("More tasks executed then were scheduled.");0!=Et&&0!=Xt||this.hasTask(this.zone,{microTask:ae.microTask>0,macroTask:ae.macroTask>0,eventTask:ae.eventTask>0,change:ht})}}class ft{constructor(ht,F,ae,Et,Xt,Un){if(this._zone=null,this.runCount=0,this._zoneDelegates=null,this._state="notScheduled",this.type=ht,this.source=F,this.data=Et,this.scheduleFn=Xt,this.cancelFn=Un,!ae)throw new Error("callback is not defined");this.callback=ae;const Ue=this;this.invoke=ht===ts&&Et&&Et.useG?ft.invokeTask:function(){return ft.invokeTask.call(Z,Ue,this,arguments)}}static invokeTask(ht,F,ae){ht||(ht=this),Ls++;try{return ht.runCount++,ht.zone.runTask(ht,F,ae)}finally{1==Ls&&ct(),Ls--}}get zone(){return this._zone}get state(){return this._state}cancelScheduleRequest(){this._transitionTo(sr,Zr)}_transitionTo(ht,F,ae){if(this._state!==F&&this._state!==ae)throw new Error(`${this.type} '${this.source}': can not transition to '${ht}', expecting state '${F}'${ae?" or '"+ae+"'":""}, was '${this._state}'.`);this._state=ht,ht==sr&&(this._zoneDelegates=null)}toString(){return this.data&&typeof this.data.handleId<"u"?this.data.handleId.toString():Object.prototype.toString.call(this)}toJSON(){return{type:this.type,state:this.state,source:this.source,zone:this.zone.name,runCount:this.runCount}}}const Ei=ke("setTimeout"),ti=ke("Promise"),gi=ke("then");let es,dr=[],Oi=!1;function kr(Pi){if(es||Z[ti]&&(es=Z[ti].resolve(0)),es){let ht=es[gi];ht||(ht=es.then),ht.call(es,Pi)}else Z[Ei](Pi,0)}function Wt(Pi){0===Ls&&0===dr.length&&kr(ct),Pi&&dr.push(Pi)}function ct(){if(!Oi){for(Oi=!0;dr.length;){const Pi=dr;dr=[];for(let ht=0;htUr,onUnhandledError:jr,microtaskDrainDone:jr,scheduleMicroTask:Wt,showUncaughtError:()=>!tt[ke("ignoreConsoleErrorUncaughtError")],patchEventTarget:()=>[],patchOnProperties:jr,patchMethod:()=>jr,bindArguments:()=>[],patchThen:()=>jr,patchMacroTask:()=>jr,patchEventPrototype:()=>jr,isIEOrEdge:()=>!1,getGlobalObjects:()=>{},ObjectDefineProperty:()=>jr,ObjectGetOwnPropertyDescriptor:()=>{},ObjectCreate:()=>{},ArraySlice:()=>[],patchClass:()=>jr,wrapWithCurrentZone:()=>jr,filterProperties:()=>[],attachOriginToPatched:()=>jr,_redefineProperty:()=>jr,patchCallbacks:()=>jr,nativeScheduleMicroTask:kr};let Ur={parent:null,zone:new tt(null,null)},Do=null,Ls=0;function jr(){}fe("Zone","Zone"),Z.Zone=tt}(globalThis);const _l=Object.getOwnPropertyDescriptor,_d=Object.defineProperty,Ud=Object.getPrototypeOf,jd=Object.create,pb=Array.prototype.slice,dm="addEventListener",$r="removeEventListener",Ul=Zone.__symbol__(dm),Fh=Zone.__symbol__($r),Ts="true",Wi="false",Vd=Zone.__symbol__("");function of(Z,se){return Zone.current.wrap(Z,se)}function um(Z,se,ye,fe,be){return Zone.current.scheduleMacroTask(Z,se,ye,fe,be)}const Ji=Zone.__symbol__,_h=typeof window<"u",Uh=_h?window:void 0,gn=_h&&Uh||globalThis,pm="removeAttribute";function Wd(Z,se){for(let ye=Z.length-1;ye>=0;ye--)"function"==typeof Z[ye]&&(Z[ye]=of(Z[ye],se+"_"+ye));return Z}function af(Z){return!Z||!1!==Z.writable&&!("function"==typeof Z.get&&typeof Z.set>"u")}const lf=typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope,jh=!("nw"in gn)&&typeof gn.process<"u"&&"[object process]"==={}.toString.call(gn.process),Yd=!jh&&!lf&&!(!_h||!Uh.HTMLElement),hf=typeof gn.process<"u"&&"[object process]"==={}.toString.call(gn.process)&&!lf&&!(!_h||!Uh.HTMLElement),jl={},Vh=function(Z){if(!(Z=Z||gn.event))return;let se=jl[Z.type];se||(se=jl[Z.type]=Ji("ON_PROPERTY"+Z.type));const ye=this||Z.target||gn,fe=ye[se];let be;return Yd&&ye===Uh&&"error"===Z.type?(be=fe&&fe.call(this,Z.message,Z.filename,Z.lineno,Z.colno,Z.error),!0===be&&Z.preventDefault()):(be=fe&&fe.apply(this,arguments),null!=be&&!be&&Z.preventDefault()),be};function Vl(Z,se,ye){let fe=_l(Z,se);if(!fe&&ye&&_l(ye,se)&&(fe={enumerable:!0,configurable:!0}),!fe||!fe.configurable)return;const be=Ji("on"+se+"patched");if(Z.hasOwnProperty(be)&&Z[be])return;delete fe.writable,delete fe.value;const ke=fe.get,at=fe.set,tt=se.slice(2);let At=jl[tt];At||(At=jl[tt]=Ji("ON_PROPERTY"+tt)),fe.set=function(Lt){let ft=this;!ft&&Z===gn&&(ft=gn),ft&&("function"==typeof ft[At]&&ft.removeEventListener(tt,Vh),at&&at.call(ft,null),ft[At]=Lt,"function"==typeof Lt&&ft.addEventListener(tt,Vh,!1))},fe.get=function(){let Lt=this;if(!Lt&&Z===gn&&(Lt=gn),!Lt)return null;const ft=Lt[At];if(ft)return ft;if(ke){let Ei=ke.call(this);if(Ei)return fe.set.call(this,Ei),"function"==typeof Lt[pm]&&Lt.removeAttribute(se),Ei}return null},_d(Z,se,fe),Z[be]=!0}function cf(Z,se,ye){if(se)for(let fe=0;fefunction(at,tt){const At=ye(at,tt);return At.cbIdx>=0&&"function"==typeof tt[At.cbIdx]?um(At.name,tt[At.cbIdx],At,be):ke.apply(at,tt)})}function Sa(Z,se){Z[Ji("OriginalDelegate")]=se}let gb=!1,Gd=!1;function vb(){if(gb)return Gd;gb=!0;try{const Z=Uh.navigator.userAgent;(-1!==Z.indexOf("MSIE ")||-1!==Z.indexOf("Trident/")||-1!==Z.indexOf("Edge/"))&&(Gd=!0)}catch{}return Gd}Zone.__load_patch("ZoneAwarePromise",(Z,se,ye)=>{const fe=Object.getOwnPropertyDescriptor,be=Object.defineProperty,at=ye.symbol,tt=[],At=!1!==Z[at("DISABLE_WRAPPING_UNCAUGHT_PROMISE_REJECTION")],Lt=at("Promise"),ft=at("then"),Ei="__creationTrace__";ye.onUnhandledError=Ue=>{if(ye.showUncaughtError()){const He=Ue&&Ue.rejection;He?console.error("Unhandled Promise rejection:",He instanceof Error?He.message:He,"; Zone:",Ue.zone.name,"; Task:",Ue.task&&Ue.task.source,"; Value:",He,He instanceof Error?He.stack:void 0):console.error(Ue)}},ye.microtaskDrainDone=()=>{for(;tt.length;){const Ue=tt.shift();try{Ue.zone.runGuarded(()=>{throw Ue.throwOriginal?Ue.rejection:Ue})}catch(He){gi(He)}}};const ti=at("unhandledPromiseRejectionHandler");function gi(Ue){ye.onUnhandledError(Ue);try{const He=se[ti];"function"==typeof He&&He.call(this,Ue)}catch{}}function dr(Ue){return Ue&&Ue.then}function Oi(Ue){return Ue}function es(Ue){return F.reject(Ue)}const kr=at("state"),Wt=at("value"),ct=at("finally"),_n=at("parentPromiseValue"),sr=at("parentPromiseState"),Zr="Promise.then",ki=null,lt=!0,ur=!1,et=0;function vi(Ue,He){return ge=>{try{cn(Ue,He,ge)}catch(We){cn(Ue,!1,We)}}}const Pt=function(){let Ue=!1;return function(ge){return function(){Ue||(Ue=!0,ge.apply(null,arguments))}}},ts="Promise resolved with itself",_o=at("currentTaskTrace");function cn(Ue,He,ge){const We=Pt();if(Ue===ge)throw new TypeError(ts);if(Ue[kr]===ki){let wt=null;try{("object"==typeof ge||"function"==typeof ge)&&(wt=ge&&ge.then)}catch(Xe){return We(()=>{cn(Ue,!1,Xe)})(),Ue}if(He!==ur&&ge instanceof F&&ge.hasOwnProperty(kr)&&ge.hasOwnProperty(Wt)&&ge[kr]!==ki)Do(ge),cn(Ue,ge[kr],ge[Wt]);else if(He!==ur&&"function"==typeof wt)try{wt.call(ge,We(vi(Ue,He)),We(vi(Ue,!1)))}catch(Xe){We(()=>{cn(Ue,!1,Xe)})()}else{Ue[kr]=He;const Xe=Ue[Wt];if(Ue[Wt]=ge,Ue[ct]===ct&&He===lt&&(Ue[kr]=Ue[sr],Ue[Wt]=Ue[_n]),He===ur&&ge instanceof Error){const mt=se.currentTask&&se.currentTask.data&&se.currentTask.data[Ei];mt&&be(ge,_o,{configurable:!0,enumerable:!1,writable:!0,value:mt})}for(let mt=0;mt{try{const dt=Ue[Wt],qt=!!ge&&ct===ge[ct];qt&&(ge[_n]=dt,ge[sr]=Xe);const ai=He.run(mt,void 0,qt&&mt!==es&&mt!==Oi?[]:[dt]);cn(ge,!0,ai)}catch(dt){cn(ge,!1,dt)}},ge)}const Pi=function(){},ht=Z.AggregateError;class F{static toString(){return"function ZoneAwarePromise() { [native code] }"}static resolve(He){return He instanceof F?He:cn(new this(null),lt,He)}static reject(He){return cn(new this(null),ur,He)}static withResolvers(){const He={};return He.promise=new F((ge,We)=>{He.resolve=ge,He.reject=We}),He}static any(He){if(!He||"function"!=typeof He[Symbol.iterator])return Promise.reject(new ht([],"All promises were rejected"));const ge=[];let We=0;try{for(let mt of He)We++,ge.push(F.resolve(mt))}catch{return Promise.reject(new ht([],"All promises were rejected"))}if(0===We)return Promise.reject(new ht([],"All promises were rejected"));let wt=!1;const Xe=[];return new F((mt,dt)=>{for(let qt=0;qt{wt||(wt=!0,mt(ai))},ai=>{Xe.push(ai),We--,0===We&&(wt=!0,dt(new ht(Xe,"All promises were rejected")))})})}static race(He){let ge,We,wt=new this((dt,qt)=>{ge=dt,We=qt});function Xe(dt){ge(dt)}function mt(dt){We(dt)}for(let dt of He)dr(dt)||(dt=this.resolve(dt)),dt.then(Xe,mt);return wt}static all(He){return F.allWithCallback(He)}static allSettled(He){return(this&&this.prototype instanceof F?this:F).allWithCallback(He,{thenCallback:We=>({status:"fulfilled",value:We}),errorCallback:We=>({status:"rejected",reason:We})})}static allWithCallback(He,ge){let We,wt,Xe=new this((ai,pr)=>{We=ai,wt=pr}),mt=2,dt=0;const qt=[];for(let ai of He){dr(ai)||(ai=this.resolve(ai));const pr=dt;try{ai.then(ir=>{qt[pr]=ge?ge.thenCallback(ir):ir,mt--,0===mt&&We(qt)},ir=>{ge?(qt[pr]=ge.errorCallback(ir),mt--,0===mt&&We(qt)):wt(ir)})}catch(ir){wt(ir)}mt++,dt++}return mt-=2,0===mt&&We(qt),Xe}constructor(He){const ge=this;if(!(ge instanceof F))throw new Error("Must be an instanceof Promise.");ge[kr]=ki,ge[Wt]=[];try{const We=Pt();He&&He(We(vi(ge,lt)),We(vi(ge,ur)))}catch(We){cn(ge,!1,We)}}get[Symbol.toStringTag](){return"Promise"}get[Symbol.species](){return F}then(He,ge){let We=this.constructor?.[Symbol.species];(!We||"function"!=typeof We)&&(We=this.constructor||F);const wt=new We(Pi),Xe=se.current;return this[kr]==ki?this[Wt].push(Xe,wt,He,ge):Ls(this,Xe,wt,He,ge),wt}catch(He){return this.then(null,He)}finally(He){let ge=this.constructor?.[Symbol.species];(!ge||"function"!=typeof ge)&&(ge=F);const We=new ge(Pi);We[ct]=ct;const wt=se.current;return this[kr]==ki?this[Wt].push(wt,We,He,He):Ls(this,wt,We,He,He),We}}F.resolve=F.resolve,F.reject=F.reject,F.race=F.race,F.all=F.all;const ae=Z[Lt]=Z.Promise;Z.Promise=F;const Et=at("thenPatched");function Xt(Ue){const He=Ue.prototype,ge=fe(He,"then");if(ge&&(!1===ge.writable||!ge.configurable))return;const We=He.then;He[ft]=We,Ue.prototype.then=function(wt,Xe){return new F((dt,qt)=>{We.call(this,dt,qt)}).then(wt,Xe)},Ue[Et]=!0}return ye.patchThen=Xt,ae&&(Xt(ae),Ka(Z,"fetch",Ue=>function Un(Ue){return function(He,ge){let We=Ue.apply(He,ge);if(We instanceof F)return We;let wt=We.constructor;return wt[Et]||Xt(wt),We}}(Ue))),Promise[se.__symbol__("uncaughtPromiseErrors")]=tt,F}),Zone.__load_patch("toString",Z=>{const se=Function.prototype.toString,ye=Ji("OriginalDelegate"),fe=Ji("Promise"),be=Ji("Error"),ke=function(){if("function"==typeof this){const Lt=this[ye];if(Lt)return"function"==typeof Lt?se.call(Lt):Object.prototype.toString.call(Lt);if(this===Promise){const ft=Z[fe];if(ft)return se.call(ft)}if(this===Error){const ft=Z[be];if(ft)return se.call(ft)}}return se.call(this)};ke[ye]=se,Function.prototype.toString=ke;const at=Object.prototype.toString;Object.prototype.toString=function(){return"function"==typeof Promise&&this instanceof Promise?"[object Promise]":at.call(this)}});let el=!1;if(typeof window<"u")try{const Z=Object.defineProperty({},"passive",{get:function(){el=!0}});window.addEventListener("test",Z,Z),window.removeEventListener("test",Z,Z)}catch{el=!1}const OT={useG:!0},Co={},mb={},vm=new RegExp("^"+Vd+"(\\w+)(true|false)$"),yb=Ji("propagationStopped");function mm(Z,se){const ye=(se?se(Z):Z)+Wi,fe=(se?se(Z):Z)+Ts,be=Vd+ye,ke=Vd+fe;Co[Z]={},Co[Z][Wi]=be,Co[Z][Ts]=ke}function Sb(Z,se,ye,fe){const be=fe&&fe.add||dm,ke=fe&&fe.rm||$r,at=fe&&fe.listeners||"eventListeners",tt=fe&&fe.rmAll||"removeAllListeners",At=Ji(be),Lt="."+be+":",ft="prependListener",Ei="."+ft+":",ti=function(Wt,ct,_n){if(Wt.isRemoved)return;const sr=Wt.callback;let Zr;"object"==typeof sr&&sr.handleEvent&&(Wt.callback=lt=>sr.handleEvent(lt),Wt.originalDelegate=sr);try{Wt.invoke(Wt,ct,[_n])}catch(lt){Zr=lt}const ki=Wt.options;return ki&&"object"==typeof ki&&ki.once&&ct[ke].call(ct,_n.type,Wt.originalDelegate?Wt.originalDelegate:Wt.callback,ki),Zr};function gi(Wt,ct,_n){if(!(ct=ct||Z.event))return;const sr=Wt||ct.target||Z,Zr=sr[Co[ct.type][_n?Ts:Wi]];if(Zr){const ki=[];if(1===Zr.length){const lt=ti(Zr[0],sr,ct);lt&&ki.push(lt)}else{const lt=Zr.slice();for(let ur=0;ur{throw ur})}}}const dr=function(Wt){return gi(this,Wt,!1)},Oi=function(Wt){return gi(this,Wt,!0)};function es(Wt,ct){if(!Wt)return!1;let _n=!0;ct&&void 0!==ct.useG&&(_n=ct.useG);const sr=ct&&ct.vh;let Zr=!0;ct&&void 0!==ct.chkDup&&(Zr=ct.chkDup);let ki=!1;ct&&void 0!==ct.rt&&(ki=ct.rt);let lt=Wt;for(;lt&&!lt.hasOwnProperty(be);)lt=Ud(lt);if(!lt&&Wt[be]&&(lt=Wt),!lt||lt[At])return!1;const ur=ct&&ct.eventNameToString,et={},vi=lt[At]=lt[be],Pt=lt[Ji(ke)]=lt[ke],ts=lt[Ji(at)]=lt[at],_o=lt[Ji(tt)]=lt[tt];let cn;ct&&ct.prepend&&(cn=lt[Ji(ct.prepend)]=lt[ct.prepend]);const F=_n?function(ge){if(!et.isExisting)return vi.call(et.target,et.eventName,et.capture?Oi:dr,et.options)}:function(ge){return vi.call(et.target,et.eventName,ge.invoke,et.options)},ae=_n?function(ge){if(!ge.isRemoved){const We=Co[ge.eventName];let wt;We&&(wt=We[ge.capture?Ts:Wi]);const Xe=wt&&ge.target[wt];if(Xe)for(let mt=0;mt{Vo.zone.cancelTask(Vo)},{once:!0})),et.target=null,Fc&&(Fc.taskData=null),qd&&(Dn.once=!0),!el&&"boolean"==typeof Vo.options||(Vo.options=Dn),Vo.target=qt,Vo.capture=Gl,Vo.eventName=ai,ir&&(Vo.originalDelegate=pr),dt?jo.unshift(Vo):jo.push(Vo),mt?qt:void 0}};return lt[be]=He(vi,Lt,F,ae,ki),cn&&(lt[ft]=He(cn,Ei,function(ge){return cn.call(et.target,et.eventName,ge.invoke,et.options)},ae,ki,!0)),lt[ke]=function(){const ge=this||Z;let We=arguments[0];ct&&ct.transferEventName&&(We=ct.transferEventName(We));const wt=arguments[2],Xe=!!wt&&("boolean"==typeof wt||wt.capture),mt=arguments[1];if(!mt)return Pt.apply(this,arguments);if(sr&&!sr(Pt,mt,ge,arguments))return;const dt=Co[We];let qt;dt&&(qt=dt[Xe?Ts:Wi]);const ai=qt&&ge[qt];if(ai)for(let pr=0;prfunction(be,ke){be[yb]=!0,fe&&fe.apply(be,ke)})}function bb(Z,se,ye,fe,be){const ke=Zone.__symbol__(fe);if(se[ke])return;const at=se[ke]=se[fe];se[fe]=function(tt,At,Lt){return At&&At.prototype&&be.forEach(function(ft){const Ei=`${ye}.${fe}::`+ft,ti=At.prototype;try{if(ti.hasOwnProperty(ft)){const gi=Z.ObjectGetOwnPropertyDescriptor(ti,ft);gi&&gi.value?(gi.value=Z.wrapWithCurrentZone(gi.value,Ei),Z._redefineProperty(At.prototype,ft,gi)):ti[ft]&&(ti[ft]=Z.wrapWithCurrentZone(ti[ft],Ei))}else ti[ft]&&(ti[ft]=Z.wrapWithCurrentZone(ti[ft],Ei))}catch{}}),at.call(se,tt,At,Lt)},Z.attachOriginToPatched(se[fe],at)}function Mb(Z,se,ye){if(!ye||0===ye.length)return se;const fe=ye.filter(ke=>ke.target===Z);if(!fe||0===fe.length)return se;const be=fe[0].ignoreProperties;return se.filter(ke=>-1===be.indexOf(ke))}function Eo(Z,se,ye,fe){Z&&cf(Z,Mb(Z,se,ye),fe)}function Xd(Z){return Object.getOwnPropertyNames(Z).filter(se=>se.startsWith("on")&&se.length>2).map(se=>se.substring(2))}Zone.__load_patch("util",(Z,se,ye)=>{const fe=Xd(Z);ye.patchOnProperties=cf,ye.patchMethod=Ka,ye.bindArguments=Wd,ye.patchMacroTask=fb;const be=se.__symbol__("BLACK_LISTED_EVENTS"),ke=se.__symbol__("UNPATCHED_EVENTS");Z[ke]&&(Z[be]=Z[ke]),Z[be]&&(se[be]=se[ke]=Z[be]),ye.patchEventPrototype=ym,ye.patchEventTarget=Sb,ye.isIEOrEdge=vb,ye.ObjectDefineProperty=_d,ye.ObjectGetOwnPropertyDescriptor=_l,ye.ObjectCreate=jd,ye.ArraySlice=pb,ye.patchClass=Qd,ye.wrapWithCurrentZone=of,ye.filterProperties=Mb,ye.attachOriginToPatched=Sa,ye._redefineProperty=Object.defineProperty,ye.patchCallbacks=bb,ye.getGlobalObjects=()=>({globalSources:mb,zoneSymbolEventNames:Co,eventNames:fe,isBrowser:Yd,isMix:hf,isNode:jh,TRUE_STR:Ts,FALSE_STR:Wi,ZONE_SYMBOL_PREFIX:Vd,ADD_EVENT_LISTENER_STR:dm,REMOVE_EVENT_LISTENER_STR:$r})});const As=Ji("zoneTask");function Wl(Z,se,ye,fe){let be=null,ke=null;ye+=fe;const at={};function tt(Lt){const ft=Lt.data;return ft.args[0]=function(){return Lt.invoke.apply(this,arguments)},ft.handleId=be.apply(Z,ft.args),Lt}function At(Lt){return ke.call(Z,Lt.data.handleId)}be=Ka(Z,se+=fe,Lt=>function(ft,Ei){if("function"==typeof Ei[0]){const ti={isPeriodic:"Interval"===fe,delay:"Timeout"===fe||"Interval"===fe?Ei[1]||0:void 0,args:Ei},gi=Ei[0];Ei[0]=function(){try{return gi.apply(this,arguments)}finally{ti.isPeriodic||("number"==typeof ti.handleId?delete at[ti.handleId]:ti.handleId&&(ti.handleId[As]=null))}};const dr=um(se,Ei[0],ti,tt,At);if(!dr)return dr;const Oi=dr.data.handleId;return"number"==typeof Oi?at[Oi]=dr:Oi&&(Oi[As]=dr),Oi&&Oi.ref&&Oi.unref&&"function"==typeof Oi.ref&&"function"==typeof Oi.unref&&(dr.ref=Oi.ref.bind(Oi),dr.unref=Oi.unref.bind(Oi)),"number"==typeof Oi||Oi?Oi:dr}return Lt.apply(Z,Ei)}),ke=Ka(Z,ye,Lt=>function(ft,Ei){const ti=Ei[0];let gi;"number"==typeof ti?gi=at[ti]:(gi=ti&&ti[As],gi||(gi=ti)),gi&&"string"==typeof gi.type?"notScheduled"!==gi.state&&(gi.cancelFn&&gi.data.isPeriodic||0===gi.runCount)&&("number"==typeof ti?delete at[ti]:ti&&(ti[As]=null),gi.zone.cancelTask(gi)):Lt.apply(Z,Ei)})}Zone.__load_patch("legacy",Z=>{const se=Z[Zone.__symbol__("legacyPatch")];se&&se()}),Zone.__load_patch("timers",Z=>{const ye="clear";Wl(Z,"set",ye,"Timeout"),Wl(Z,"set",ye,"Interval"),Wl(Z,"set",ye,"Immediate")}),Zone.__load_patch("requestAnimationFrame",Z=>{Wl(Z,"request","cancel","AnimationFrame"),Wl(Z,"mozRequest","mozCancel","AnimationFrame"),Wl(Z,"webkitRequest","webkitCancel","AnimationFrame")}),Zone.__load_patch("blocking",(Z,se)=>{const ye=["alert","prompt","confirm"];for(let fe=0;fefunction(At,Lt){return se.current.run(ke,Z,Lt,tt)})}),Zone.__load_patch("EventTarget",(Z,se,ye)=>{(function Yl(Z,se){se.patchEventPrototype(Z,se)})(Z,ye),function Im(Z,se){if(Zone[se.symbol("patchEventTarget")])return;const{eventNames:ye,zoneSymbolEventNames:fe,TRUE_STR:be,FALSE_STR:ke,ZONE_SYMBOL_PREFIX:at}=se.getGlobalObjects();for(let At=0;At{Qd("MutationObserver"),Qd("WebKitMutationObserver")}),Zone.__load_patch("IntersectionObserver",(Z,se,ye)=>{Qd("IntersectionObserver")}),Zone.__load_patch("FileReader",(Z,se,ye)=>{Qd("FileReader")}),Zone.__load_patch("on_property",(Z,se,ye)=>{!function df(Z,se){if(jh&&!hf||Zone[Z.symbol("patchEvents")])return;const ye=se.__Zone_ignore_on_properties;let fe=[];if(Yd){const be=window;fe=fe.concat(["Document","SVGElement","Element","HTMLElement","HTMLBodyElement","HTMLMediaElement","HTMLFrameSetElement","HTMLFrameElement","HTMLIFrameElement","HTMLMarqueeElement","Worker"]);const ke=function gm(){try{const Z=Uh.navigator.userAgent;if(-1!==Z.indexOf("MSIE ")||-1!==Z.indexOf("Trident/"))return!0}catch{}return!1}()?[{target:be,ignoreProperties:["error"]}]:[];Eo(be,Xd(be),ye&&ye.concat(ke),Ud(be))}fe=fe.concat(["XMLHttpRequest","XMLHttpRequestEventTarget","IDBIndex","IDBRequest","IDBOpenDBRequest","IDBDatabase","IDBTransaction","IDBCursor","WebSocket"]);for(let be=0;be{!function Sm(Z,se){const{isBrowser:ye,isMix:fe}=se.getGlobalObjects();(ye||fe)&&Z.customElements&&"customElements"in Z&&se.patchCallbacks(se,Z.customElements,"customElements","define",["connectedCallback","disconnectedCallback","adoptedCallback","attributeChangedCallback"])}(Z,ye)}),Zone.__load_patch("XHR",(Z,se)=>{!function At(Lt){const ft=Lt.XMLHttpRequest;if(!ft)return;const Ei=ft.prototype;let gi=Ei[Ul],dr=Ei[Fh];if(!gi){const et=Lt.XMLHttpRequestEventTarget;if(et){const vi=et.prototype;gi=vi[Ul],dr=vi[Fh]}}const Oi="readystatechange",es="scheduled";function kr(et){const vi=et.data,Pt=vi.target;Pt[ke]=!1,Pt[tt]=!1;const ts=Pt[be];gi||(gi=Pt[Ul],dr=Pt[Fh]),ts&&dr.call(Pt,Oi,ts);const _o=Pt[be]=()=>{if(Pt.readyState===Pt.DONE)if(!vi.aborted&&Pt[ke]&&et.state===es){const Ur=Pt[se.__symbol__("loadfalse")];if(0!==Pt.status&&Ur&&Ur.length>0){const Do=et.invoke;et.invoke=function(){const Ls=Pt[se.__symbol__("loadfalse")];for(let jr=0;jrfunction(et,vi){return et[fe]=0==vi[2],et[at]=vi[1],_n.apply(et,vi)}),Zr=Ji("fetchTaskAborting"),ki=Ji("fetchTaskScheduling"),lt=Ka(Ei,"send",()=>function(et,vi){if(!0===se.current[ki]||et[fe])return lt.apply(et,vi);{const Pt={target:et,url:et[at],isPeriodic:!1,args:vi,aborted:!1},ts=um("XMLHttpRequest.send",Wt,Pt,kr,ct);et&&!0===et[tt]&&!Pt.aborted&&ts.state===es&&ts.invoke()}}),ur=Ka(Ei,"abort",()=>function(et,vi){const Pt=function ti(et){return et[ye]}(et);if(Pt&&"string"==typeof Pt.type){if(null==Pt.cancelFn||Pt.data&&Pt.data.aborted)return;Pt.zone.cancelTask(Pt)}else if(!0===se.current[Zr])return ur.apply(et,vi)})}(Z);const ye=Ji("xhrTask"),fe=Ji("xhrSync"),be=Ji("xhrListener"),ke=Ji("xhrScheduled"),at=Ji("xhrURL"),tt=Ji("xhrErrorBeforeScheduled")}),Zone.__load_patch("geolocation",Z=>{Z.navigator&&Z.navigator.geolocation&&function fm(Z,se){const ye=Z.constructor.name;for(let fe=0;fe{const At=function(){return tt.apply(this,Wd(arguments,ye+"."+be))};return Sa(At,tt),At})(ke)}}}(Z.navigator.geolocation,["getCurrentPosition","watchPosition"])}),Zone.__load_patch("PromiseRejectionEvent",(Z,se)=>{function ye(fe){return function(be){Ib(Z,fe).forEach(at=>{const tt=Z.PromiseRejectionEvent;if(tt){const At=new tt(fe,{promise:be.promise,reason:be.rejection});at.invoke(At)}})}}Z.PromiseRejectionEvent&&(se[Ji("unhandledPromiseRejectionHandler")]=ye("unhandledrejection"),se[Ji("rejectionHandledHandler")]=ye("rejectionhandled"))}),Zone.__load_patch("queueMicrotask",(Z,se,ye)=>{!function uf(Z,se){se.patchMethod(Z,"queueMicrotask",ye=>function(fe,be){Zone.current.scheduleMicroTask("queueMicrotask",be[0])})}(Z,ye)})}},_l=>{_l(_l.s=51)}]); \ No newline at end of file diff --git a/ej2-angular/samples/diagram/nodes/node-expandAndCollapse-cs2/index.html b/ej2-angular/samples/diagram/nodes/node-expandAndCollapse-cs2/index.html index ec66427a83..d5580658b5 100644 --- a/ej2-angular/samples/diagram/nodes/node-expandAndCollapse-cs2/index.html +++ b/ej2-angular/samples/diagram/nodes/node-expandAndCollapse-cs2/index.html @@ -19,5 +19,5 @@
Loading....
- + \ No newline at end of file diff --git a/ej2-angular/samples/diagram/nodes/node-expandAndCollapse-cs2/main.348fc4eaf45b08b7.js b/ej2-angular/samples/diagram/nodes/node-expandAndCollapse-cs2/main.348fc4eaf45b08b7.js new file mode 100644 index 0000000000..396c16f76d --- /dev/null +++ b/ej2-angular/samples/diagram/nodes/node-expandAndCollapse-cs2/main.348fc4eaf45b08b7.js @@ -0,0 +1 @@ +"use strict";(self.webpackChunksyncfusion_component=self.webpackChunksyncfusion_component||[]).push([[179],{51:(Wl,Ud,jd)=>{let $r=null,_h=1;const Ts=Symbol("SIGNAL");function Wi(n){const t=$r;return $r=n,t}function gn(n){if((!Wh(n)||n.dirty)&&(n.dirty||n.lastCleanEpoch!==_h)){if(!n.producerMustRecompute(n)&&!Vh(n))return n.dirty=!1,void(n.lastCleanEpoch=_h);n.producerRecomputeValue(n),n.dirty=!1,n.lastCleanEpoch=_h}}function Vh(n){Gl(n);for(let t=0;t0}function Gl(n){n.producerNode??=[],n.producerIndexOfThis??=[],n.producerLastReadVersion??=[]}let Xd=null;function Eo(n){return"function"==typeof n}function qd(n){const e=n(i=>{Error.call(i),i.stack=(new Error).stack});return e.prototype=Object.create(Error.prototype),e.prototype.constructor=e,e}const dp=qd(n=>function(e){n(this),this.message=e?`${e.length} errors occurred during unsubscription:\n${e.map((i,r)=>`${r+1}) ${i.toString()}`).join("\n ")}`:"",this.name="UnsubscriptionError",this.errors=e});function up(n,t){if(n){const e=n.indexOf(t);0<=e&&n.splice(e,1)}}class As{constructor(t){this.initialTeardown=t,this.closed=!1,this._parentage=null,this._finalizers=null}unsubscribe(){let t;if(!this.closed){this.closed=!0;const{_parentage:e}=this;if(e)if(this._parentage=null,Array.isArray(e))for(const s of e)s.remove(this);else e.remove(this);const{initialTeardown:i}=this;if(Eo(i))try{i()}catch(s){t=s instanceof dp?s.errors:[s]}const{_finalizers:r}=this;if(r){this._finalizers=null;for(const s of r)try{bm(s)}catch(o){t=t??[],o instanceof dp?t=[...t,...o.errors]:t.push(o)}}if(t)throw new dp(t)}}add(t){var e;if(t&&t!==this)if(this.closed)bm(t);else{if(t instanceof As){if(t.closed||t._hasParent(this))return;t._addParent(this)}(this._finalizers=null!==(e=this._finalizers)&&void 0!==e?e:[]).push(t)}}_hasParent(t){const{_parentage:e}=this;return e===t||Array.isArray(e)&&e.includes(t)}_addParent(t){const{_parentage:e}=this;this._parentage=Array.isArray(e)?(e.push(t),e):e?[e,t]:t}_removeParent(t){const{_parentage:e}=this;e===t?this._parentage=null:Array.isArray(e)&&up(e,t)}remove(t){const{_finalizers:e}=this;e&&up(e,t),t instanceof As&&t._removeParent(this)}}As.EMPTY=(()=>{const n=new As;return n.closed=!0,n})();const Xl=As.EMPTY;function Im(n){return n instanceof As||n&&"closed"in n&&Eo(n.remove)&&Eo(n.add)&&Eo(n.unsubscribe)}function bm(n){Eo(n)?n():n.unsubscribe()}const ql={onUnhandledError:null,onStoppedNotification:null,Promise:void 0,useDeprecatedSynchronousErrorHandling:!1,useDeprecatedNextContext:!1},Z={setTimeout(n,t,...e){const{delegate:i}=Z;return i?.setTimeout?i.setTimeout(n,t,...e):setTimeout(n,t,...e)},clearTimeout(n){const{delegate:t}=Z;return(t?.clearTimeout||clearTimeout)(n)},delegate:void 0};function ye(){}const pe=at("C",void 0,void 0);function at(n,t,e){return{kind:n,value:t,error:e}}let it=null;function At(n){if(ql.useDeprecatedSynchronousErrorHandling){const t=!it;if(t&&(it={errorThrown:!1,error:null}),n(),t){const{errorThrown:e,error:i}=it;if(it=null,e)throw i}}else n()}class pt extends As{constructor(t){super(),this.isStopped=!1,t?(this.destination=t,Im(t)&&t.add(this)):this.destination=Wt}static create(t,e,i){return new dr(t,e,i)}next(t){this.isStopped?Pr(function ke(n){return at("N",n,void 0)}(t),this):this._next(t)}error(t){this.isStopped?Pr(function be(n){return at("E",void 0,n)}(t),this):(this.isStopped=!0,this._error(t))}complete(){this.isStopped?Pr(pe,this):(this.isStopped=!0,this._complete())}unsubscribe(){this.closed||(this.isStopped=!0,super.unsubscribe(),this.destination=null)}_next(t){this.destination.next(t)}_error(t){try{this.destination.error(t)}finally{this.unsubscribe()}}_complete(){try{this.destination.complete()}finally{this.unsubscribe()}}}const Di=Function.prototype.bind;function ni(n,t){return Di.call(n,t)}class mi{constructor(t){this.partialObserver=t}next(t){const{partialObserver:e}=this;if(e.next)try{e.next(t)}catch(i){ki(i)}}error(t){const{partialObserver:e}=this;if(e.error)try{e.error(t)}catch(i){ki(i)}else ki(t)}complete(){const{partialObserver:t}=this;if(t.complete)try{t.complete()}catch(e){ki(e)}}}class dr extends pt{constructor(t,e,i){let r;if(super(),Eo(t)||!t)r={next:t??void 0,error:e??void 0,complete:i??void 0};else{let s;this&&ql.useDeprecatedNextContext?(s=Object.create(t),s.unsubscribe=()=>this.unsubscribe(),r={next:t.next&&ni(t.next,s),error:t.error&&ni(t.error,s),complete:t.complete&&ni(t.complete,s)}):r=t}this.destination=new mi(r)}}function ki(n){ql.useDeprecatedSynchronousErrorHandling?function Lt(n){ql.useDeprecatedSynchronousErrorHandling&&it&&(it.errorThrown=!0,it.error=n)}(n):function se(n){Z.setTimeout(()=>{const{onUnhandledError:t}=ql;if(!t)throw n;t(n)})}(n)}function Pr(n,t){const{onStoppedNotification:e}=ql;e&&Z.setTimeout(()=>e(n,t))}const Wt={closed:!0,next:ye,error:function is(n){throw n},complete:ye},ct="function"==typeof Symbol&&Symbol.observable||"@@observable";function jn(n){return n}let Pi=(()=>{class n{constructor(e){e&&(this._subscribe=e)}lift(e){const i=new n;return i.source=this,i.operator=e,i}subscribe(e,i,r){const s=function et(n){return n&&n instanceof pt||function ur(n){return n&&Eo(n.next)&&Eo(n.error)&&Eo(n.complete)}(n)&&Im(n)}(e)?e:new dr(e,i,r);return At(()=>{const{operator:o,source:a}=this;s.add(o?o.call(s,a):a?this._subscribe(s):this._trySubscribe(s))}),s}_trySubscribe(e){try{return this._subscribe(e)}catch(i){e.error(i)}}forEach(e,i){return new(i=lt(i))((r,s)=>{const o=new dr({next:a=>{try{e(a)}catch(l){s(l),o.unsubscribe()}},error:s,complete:r});this.subscribe(o)})}_subscribe(e){var i;return null===(i=this.source)||void 0===i?void 0:i.subscribe(e)}[ct](){return this}pipe(...e){return function Zr(n){return 0===n.length?jn:1===n.length?n[0]:function(e){return n.reduce((i,r)=>r(i),e)}}(e)(this)}toPromise(e){return new(e=lt(e))((i,r)=>{let s;this.subscribe(o=>s=o,o=>r(o),()=>i(s))})}}return n.create=t=>new n(t),n})();function lt(n){var t;return null!==(t=n??ql.Promise)&&void 0!==t?t:Promise}const yi=qd(n=>function(){n(this),this.name="ObjectUnsubscribedError",this.message="object unsubscribed"});let Pt=(()=>{class n extends Pi{constructor(){super(),this.closed=!1,this.currentObservers=null,this.observers=[],this.isStopped=!1,this.hasError=!1,this.thrownError=null}lift(e){const i=new rs(this,this);return i.operator=e,i}_throwIfClosed(){if(this.closed)throw new yi}next(e){At(()=>{if(this._throwIfClosed(),!this.isStopped){this.currentObservers||(this.currentObservers=Array.from(this.observers));for(const i of this.currentObservers)i.next(e)}})}error(e){At(()=>{if(this._throwIfClosed(),!this.isStopped){this.hasError=this.isStopped=!0,this.thrownError=e;const{observers:i}=this;for(;i.length;)i.shift().error(e)}})}complete(){At(()=>{if(this._throwIfClosed(),!this.isStopped){this.isStopped=!0;const{observers:e}=this;for(;e.length;)e.shift().complete()}})}unsubscribe(){this.isStopped=this.closed=!0,this.observers=this.currentObservers=null}get observed(){var e;return(null===(e=this.observers)||void 0===e?void 0:e.length)>0}_trySubscribe(e){return this._throwIfClosed(),super._trySubscribe(e)}_subscribe(e){return this._throwIfClosed(),this._checkFinalizedStatuses(e),this._innerSubscribe(e)}_innerSubscribe(e){const{hasError:i,isStopped:r,observers:s}=this;return i||r?Xl:(this.currentObservers=null,s.push(e),new As(()=>{this.currentObservers=null,up(s,e)}))}_checkFinalizedStatuses(e){const{hasError:i,thrownError:r,isStopped:s}=this;i?e.error(r):s&&e.complete()}asObservable(){const e=new Pi;return e.source=this,e}}return n.create=(t,e)=>new rs(t,e),n})();class rs extends Pt{constructor(t,e){super(),this.destination=t,this.source=e}next(t){var e,i;null===(i=null===(e=this.destination)||void 0===e?void 0:e.next)||void 0===i||i.call(e,t)}error(t){var e,i;null===(i=null===(e=this.destination)||void 0===e?void 0:e.error)||void 0===i||i.call(e,t)}complete(){var t,e;null===(e=null===(t=this.destination)||void 0===t?void 0:t.complete)||void 0===e||e.call(t)}_subscribe(t){var e,i;return null!==(i=null===(e=this.source)||void 0===e?void 0:e.subscribe(t))&&void 0!==i?i:Xl}}class _o extends Pt{constructor(t){super(),this._value=t}get value(){return this.getValue()}_subscribe(t){const e=super._subscribe(t);return!e.closed&&t.next(this._value),e}getValue(){const{hasError:t,thrownError:e,_value:i}=this;if(t)throw e;return this._throwIfClosed(),i}next(t){super.next(this._value=t)}}class Ls extends pt{constructor(t,e,i,r,s,o){super(t),this.onFinalize=s,this.shouldUnsubscribe=o,this._next=e?function(a){try{e(a)}catch(l){t.error(l)}}:super._next,this._error=r?function(a){try{r(a)}catch(l){t.error(l)}finally{this.unsubscribe()}}:super._error,this._complete=i?function(){try{i()}catch(a){t.error(a)}finally{this.unsubscribe()}}:super._complete}unsubscribe(){var t;if(!this.shouldUnsubscribe||this.shouldUnsubscribe()){const{closed:e}=this;super.unsubscribe(),!e&&(null===(t=this.onFinalize)||void 0===t||t.call(this))}}}function jr(n,t){return function Ur(n){return t=>{if(function cn(n){return Eo(n?.lift)}(t))return t.lift(function(e){try{return n(e,this)}catch(i){this.error(i)}});throw new TypeError("Unable to lift unknown Observable type")}}((e,i)=>{let r=0;e.subscribe(function Do(n,t,e,i,r){return new Ls(n,t,e,i,r)}(i,s=>{i.next(n.call(t,s,r++))}))})}class F extends Error{constructor(t,e){super(function ae(n,t){return`NG0${Math.abs(n)}${t?": "+t:""}`}(t,e)),this.code=t}}function Xe(n){for(let t in n)if(n[t]===Xe)return t;throw Error("Could not find renamed property on target object.")}function mt(n,t){for(const e in t)t.hasOwnProperty(e)&&!n.hasOwnProperty(e)&&(n[e]=t[e])}function dt(n){if("string"==typeof n)return n;if(Array.isArray(n))return"["+n.map(dt).join(", ")+"]";if(null==n)return""+n;if(n.overriddenName)return`${n.overriddenName}`;if(n.name)return`${n.name}`;const t=n.toString();if(null==t)return""+t;const e=t.indexOf("\n");return-1===e?t:t.substring(0,e)}function qt(n,t){return null==n||""===n?null===t?"":t:null==t||""===t?n:n+" "+t}const fr=Xe({__forward_ref__:Xe});function ir(n){return n.__forward_ref__=ir,n.toString=function(){return dt(this())},n}function vt(n){return function Tn(n){return"function"==typeof n&&n.hasOwnProperty(fr)&&n.__forward_ref__===ir}(n)?n():n}function $l(n){return n&&!!n.\u0275providers}const Zl=Xe({\u0275cmp:Xe}),$d=Xe({\u0275dir:Xe}),fp=Xe({\u0275pipe:Xe}),Uo=Xe({\u0275fac:Xe}),jo=Xe({__NG_ELEMENT_ID__:Xe}),pp=Xe({__NG_ENV_ID__:Xe});function Ri(n){return"function"==typeof n?n.name||n.toString():"object"==typeof n&&null!=n&&"function"==typeof n.type?n.type.name||n.type.toString():function Nt(n){return"string"==typeof n?n:null==n?"":String(n)}(n)}function Eb(n,t){throw new F(-201,!1)}function so(n,t){null==n&&function zt(n,t,e,i){throw new Error(`ASSERTION ERROR: ${n}`+(null==i?"":` [Expected=> ${e} ${i} ${t} <=Actual]`))}(t,n,null,"!=")}function Yi(n){return{token:n.token,providedIn:n.providedIn||null,factory:n.factory,value:void 0}}function gp(n){return{providers:n.providers||[],imports:n.imports||[]}}function Mm(n){return kT(n,Cm)||kT(n,PT)}function kT(n,t){return n.hasOwnProperty(t)?n[t]:null}function wm(n){return n&&(n.hasOwnProperty(Db)||n.hasOwnProperty(b_))?n[Db]:null}const Cm=Xe({\u0275prov:Xe}),Db=Xe({\u0275inj:Xe}),PT=Xe({ngInjectableDef:Xe}),b_=Xe({ngInjectorDef:Xe});var xi=function(n){return n[n.Default=0]="Default",n[n.Host=1]="Host",n[n.Self=2]="Self",n[n.SkipSelf=4]="SkipSelf",n[n.Optional=8]="Optional",n}(xi||{});let xb;function oo(n){const t=xb;return xb=n,t}function RT(n,t,e){const i=Mm(n);return i&&"root"==i.providedIn?void 0===i.value?i.value=i.factory():i.value:e&xi.Optional?null:void 0!==t?t:void Eb()}const rr=globalThis;class Bt{constructor(t,e){this._desc=t,this.ngMetadataName="InjectionToken",this.\u0275prov=void 0,"number"==typeof e?this.__NG_ELEMENT_ID__=e:void 0!==e&&(this.\u0275prov=Yi({token:this,providedIn:e.providedIn||"root",factory:e.factory}))}get multi(){return this}toString(){return`InjectionToken ${this._desc}`}}const vp={},Ob="__NG_DI_FLAG__",Em="ngTempTokenPath",C_=/\n/gm,BT="__source";let Jd;function Gh(n){const t=Jd;return Jd=n,t}function x_(n,t=xi.Default){if(void 0===Jd)throw new F(-203,!1);return null===Jd?RT(n,void 0,t):Jd.get(n,t&xi.Optional?null:void 0,t)}function _i(n,t=xi.Default){return(function zT(){return xb}()||x_)(vt(n),t)}function Hi(n,t=xi.Default){return _i(n,Dm(t))}function Dm(n){return typeof n>"u"||"number"==typeof n?n:0|(n.optional&&8)|(n.host&&1)|(n.self&&2)|(n.skipSelf&&4)}function kb(n){const t=[];for(let e=0;et){o=s-1;break}}}for(;ss?"":r[d+1].toLowerCase();const f=8&i?u:null;if(f&&-1!==_T(f,h,0)||2&i&&h!==u){if(Ma(i))return!1;o=!0}}}}else{if(!o&&!Ma(i)&&!Ma(l))return!1;if(o&&Ma(l))continue;o=!1,i=l|1&i}}return Ma(i)||o}function Ma(n){return 0==(1&n)}function P_(n,t,e,i){if(null===t)return-1;let r=0;if(i||!e){let s=!1;for(;r-1)for(e++;e0?'="'+a+'"':"")+"]"}else 8&i?r+="."+o:4&i&&(r+=" "+o);else""!==r&&!Ma(o)&&(t+=GT(s,r),r=""),i=o,s=s||!Ma(i);e++}return""!==r&&(t+=GT(s,r)),t}function zb(n){return Jl(()=>{const t=qT(n),e={...t,decls:n.decls,vars:n.vars,template:n.template,consts:n.consts||null,ngContentSelectors:n.ngContentSelectors,onPush:n.changeDetection===xm.OnPush,directiveDefs:null,pipeDefs:null,dependencies:t.standalone&&n.dependencies||null,getStandaloneInjector:null,signals:n.signals??!1,data:n.data||{},encapsulation:n.encapsulation||ba.Emulated,styles:n.styles||Qi,_:null,schemas:n.schemas||null,tView:null,id:""};$T(e);const i=n.dependencies;return e.directiveDefs=Am(i,!1),e.pipeDefs=Am(i,!0),e.id=function Y_(n){let t=0;const e=[n.selectors,n.ngContentSelectors,n.hostVars,n.hostAttrs,n.consts,n.vars,n.decls,n.encapsulation,n.standalone,n.signals,n.exportAs,JSON.stringify(n.inputs),JSON.stringify(n.outputs),Object.getOwnPropertyNames(n.type.prototype),!!n.contentQueries,!!n.viewQuery].join("|");for(const r of e)t=Math.imul(31,t)+r.charCodeAt(0)<<0;return t+=2147483648,"c"+t}(e),e})}function j_(n){return di(n)||Wn(n)}function V_(n){return null!==n}function Tm(n){return Jl(()=>({type:n.type,bootstrap:n.bootstrap||Qi,declarations:n.declarations||Qi,imports:n.imports||Qi,exports:n.exports||Qi,transitiveCompileScopes:null,schemas:n.schemas||null,id:n.id||null}))}function XT(n,t){if(null==n)return rl;const e={};for(const i in n)if(n.hasOwnProperty(i)){const r=n[i];let s,o,a=Xh.None;Array.isArray(r)?(a=r[0],s=r[1],o=r[2]??s):(s=r,o=r),t?(e[s]=a!==Xh.None?[i,a]:i,t[s]=o):e[s]=i}return e}function nr(n){return Jl(()=>{const t=qT(n);return $T(t),t})}function di(n){return n[Zl]||null}function Wn(n){return n[$d]||null}function gs(n){return n[fp]||null}function qT(n){const t={};return{type:n.type,providersResolver:null,factory:null,hostBindings:n.hostBindings||null,hostVars:n.hostVars||0,hostAttrs:n.hostAttrs||null,contentQueries:n.contentQueries||null,declaredInputs:t,inputTransforms:null,inputConfig:n.inputs||rl,exportAs:n.exportAs||null,standalone:!0===n.standalone,signals:!0===n.signals,selectors:n.selectors||Qi,viewQuery:n.viewQuery||null,features:n.features||null,setInput:null,findHostDirectiveDefs:null,hostDirectives:null,inputs:XT(n.inputs,t),outputs:XT(n.outputs),debugInfo:null}}function $T(n){n.features?.forEach(t=>t(n))}function Am(n,t){if(!n)return null;const e=t?gs:j_;return()=>("function"==typeof n?n():n).map(i=>e(i)).filter(V_)}const Vr=0,Be=1,Ct=2,vn=3,wa=4,Os=5,Ca=6,Kd=7,Er=8,Xs=9,Kl=10,Yt=11,Sp=12,ZT=13,eu=14,Jr=15,Ip=16,tu=17,nl=18,bp=19,JT=20,qh=21,Lm=22,Uc=23,jt=25,Rb=1,sl=7,iu=9,mn=10;var Hb=function(n){return n[n.None=0]="None",n[n.HasTransplantedViews=2]="HasTransplantedViews",n}(Hb||{});function ks(n){return Array.isArray(n)&&"object"==typeof n[Rb]}function Ps(n){return Array.isArray(n)&&!0===n[Rb]}function Bb(n){return 0!=(4&n.flags)}function jc(n){return n.componentOffset>-1}function Ea(n){return!!n.template}function Fb(n){return 0!=(512&n[Ct])}function Vc(n,t){return n.hasOwnProperty(Uo)?n[Uo]:null}class q_{constructor(t,e,i){this.previousValue=t,this.currentValue=e,this.firstChange=i}isFirstChange(){return this.firstChange}}function iA(n,t,e,i){null!==t?t.applyValueToInputSignal(t,i):n[e]=i}function rA(n){return n.type.prototype.ngOnChanges&&(n.setInput=Z_),$_}function $_(){const n=sA(this),t=n?.current;if(t){const e=n.previous;if(e===rl)n.previous=t;else for(let i in t)e[i]=t[i];n.current=null,this.ngOnChanges(t)}}function Z_(n,t,e,i,r){const s=this.declaredInputs[i],o=sA(n)||function J_(n,t){return n[nA]=t}(n,{previous:rl,current:null}),a=o.current||(o.current={}),l=o.previous,h=l[s];a[s]=new q_(h&&h.currentValue,e,l===rl),iA(n,t,r,e)}const nA="__ngSimpleChanges__";function sA(n){return n[nA]||null}const ol=function(n,t,e){};let lA=!1;function pr(n){for(;Array.isArray(n);)n=n[Vr];return n}function qs(n,t){return pr(t[n.index])}function Cp(n,t){return n.data[t]}function To(n,t){const e=t[n];return ks(e)?e:e[Vr]}function Wb(n){return 128==(128&n[Ct])}function al(n,t){return null==t?null:n[t]}function hA(n){n[tu]=0}function nU(n){1024&n[Ct]||(n[Ct]|=1024,Wb(n)&&Ep(n))}function dA(n){return 9216&n[Ct]||n[Uc]?.dirty}function Yb(n){dA(n)?Ep(n):64&n[Ct]&&(function eU(){return lA}()?(n[Ct]|=1024,Ep(n)):n[Kl].changeDetectionScheduler?.notify())}function Ep(n){n[Kl].changeDetectionScheduler?.notify();let t=Wc(n);for(;null!==t&&!(8192&t[Ct])&&(t[Ct]|=8192,Wb(t));)t=Wc(t)}function Wc(n){const t=n[vn];return Ps(t)?t[vn]:t}const Rt={lFrame:bA(null),bindingsEnabled:!0,skipHydrationRootTNode:null};function fA(){return Rt.bindingsEnabled}function Se(){return Rt.lFrame.lView}function Ti(){return Rt.lFrame.tView}function gr(){let n=pA();for(;null!==n&&64===n.type;)n=n.parent;return n}function pA(){return Rt.lFrame.currentTNode}function ll(n,t){const e=Rt.lFrame;e.currentTNode=n,e.isParent=t}function Gb(){return Rt.lFrame.isParent}function mU(n,t){const e=Rt.lFrame;e.bindingIndex=e.bindingRootIndex=n,qb(t)}function qb(n){Rt.lFrame.currentDirectiveIndex=n}function yA(){return Rt.lFrame.currentQueryIndex}function Zb(n){Rt.lFrame.currentQueryIndex=n}function SU(n){const t=n[Be];return 2===t.type?t.declTNode:1===t.type?n[Os]:null}function SA(n,t,e){if(e&xi.SkipSelf){let r=t,s=n;for(;!(r=r.parent,null!==r||e&xi.Host||(r=SU(s),null===r||(s=s[eu],10&r.type))););if(null===r)return!1;t=r,n=s}const i=Rt.lFrame=IA();return i.currentTNode=t,i.lView=n,!0}function Jb(n){const t=IA(),e=n[Be];Rt.lFrame=t,t.currentTNode=e.firstChild,t.lView=n,t.tView=e,t.contextLView=n,t.bindingIndex=e.bindingStartIndex,t.inI18n=!1}function IA(){const n=Rt.lFrame,t=null===n?null:n.child;return null===t?bA(n):t}function bA(n){const t={currentTNode:null,isParent:!0,lView:null,tView:null,selectedIndex:-1,contextLView:null,elementDepthCount:0,currentNamespace:null,currentDirectiveIndex:-1,bindingRootIndex:-1,bindingIndex:-1,currentQueryIndex:0,parent:n,child:null,inI18n:!1};return null!==n&&(n.child=t),t}function MA(){const n=Rt.lFrame;return Rt.lFrame=n.parent,n.currentTNode=null,n.lView=null,n}const wA=MA;function Kb(){const n=MA();n.isParent=!0,n.tView=null,n.selectedIndex=-1,n.contextLView=null,n.elementDepthCount=0,n.currentDirectiveIndex=-1,n.currentNamespace=null,n.bindingRootIndex=-1,n.bindingIndex=-1,n.currentQueryIndex=0}function Yc(n){Rt.lFrame.selectedIndex=n}let EA=!0;function Rm(n,t){for(let e=t.directiveStart,i=t.directiveEnd;e=i)break}else t[l]<0&&(n[tu]+=65536),(a>14>16&&(3&n[Ct])===t&&(n[Ct]+=16384,xA(a,s)):xA(a,s)}const su=-1;class xp{constructor(t,e,i){this.factory=t,this.resolving=!1,this.canSeeViewProviders=e,this.injectImpl=i}}function i1(n){return n!==su}function Tp(n){return 32767&n}function Ap(n,t){let e=function NU(n){return n>>16}(n),i=t;for(;e>0;)i=i[eu],e--;return i}let r1=!0;function Fm(n){const t=r1;return r1=n,t}const TA=255,AA=5;let OU=0;const cl={};function _m(n,t){const e=LA(n,t);if(-1!==e)return e;const i=t[Be];i.firstCreatePass&&(n.injectorIndex=t.length,n1(i.data,n),n1(t,null),n1(i.blueprint,null));const r=Um(n,t),s=n.injectorIndex;if(i1(r)){const o=Tp(r),a=Ap(r,t),l=a[Be].data;for(let h=0;h<8;h++)t[s+h]=a[o+h]|l[o+h]}return t[s+8]=r,s}function n1(n,t){n.push(0,0,0,0,0,0,0,0,t)}function LA(n,t){return-1===n.injectorIndex||n.parent&&n.parent.injectorIndex===n.injectorIndex||null===t[n.injectorIndex+8]?-1:n.injectorIndex}function Um(n,t){if(n.parent&&-1!==n.parent.injectorIndex)return n.parent.injectorIndex;let e=0,i=null,r=t;for(;null!==r;){if(i=HA(r),null===i)return su;if(e++,r=r[eu],-1!==i.injectorIndex)return i.injectorIndex|e<<16}return su}function s1(n,t,e){!function kU(n,t,e){let i;"string"==typeof e?i=e.charCodeAt(0)||0:e.hasOwnProperty(jo)&&(i=e[jo]),null==i&&(i=e[jo]=OU++);const r=i&TA;t.data[n+(r>>AA)]|=1<=0?t&TA:HU:t}(e);if("function"==typeof s){if(!SA(t,n,i))return i&xi.Host?NA(r,0,i):OA(t,e,i,r);try{let o;if(o=s(i),null!=o||i&xi.Optional)return o;Eb()}finally{wA()}}else if("number"==typeof s){let o=null,a=LA(n,t),l=su,h=i&xi.Host?t[Jr][Os]:null;for((-1===a||i&xi.SkipSelf)&&(l=-1===a?Um(n,t):t[a+8],l!==su&&RA(i,!1)?(o=t[Be],a=Tp(l),t=Ap(l,t)):a=-1);-1!==a;){const c=t[Be];if(zA(s,a,c.data)){const d=zU(a,t,e,o,i,h);if(d!==cl)return d}l=t[a+8],l!==su&&RA(i,t[Be].data[a+8]===h)&&zA(s,a,t)?(o=c,a=Tp(l),t=Ap(l,t)):a=-1}}return r}function zU(n,t,e,i,r,s){const o=t[Be],a=o.data[n+8],c=jm(a,o,e,null==i?jc(a)&&r1:i!=o&&0!=(3&a.type),r&xi.Host&&s===a);return null!==c?Qc(t,o,c,a):cl}function jm(n,t,e,i,r){const s=n.providerIndexes,o=t.data,a=1048575&s,l=n.directiveStart,c=s>>20,u=r?a+c:n.directiveEnd;for(let f=i?a:a+c;f=l&&p.type===e)return f}if(r){const f=o[l];if(f&&Ea(f)&&f.type===e)return l}return null}function Qc(n,t,e,i){let r=n[e];const s=t.data;if(function xU(n){return n instanceof xp}(r)){const o=r;o.resolving&&function Vo(n,t){const e=t?`. Dependency path: ${t.join(" > ")} > ${n}`:"";throw new F(-200,`Circular dependency in DI detected for ${n}${e}`)}(Ri(s[e]));const a=Fm(o.canSeeViewProviders);o.resolving=!0;const h=o.injectImpl?oo(o.injectImpl):null;SA(n,i,xi.Default);try{r=n[e]=o.factory(void 0,s,n,i),t.firstCreatePass&&e>=i.directiveStart&&function EU(n,t,e){const{ngOnChanges:i,ngOnInit:r,ngDoCheck:s}=t.type.prototype;if(i){const o=rA(t);(e.preOrderHooks??=[]).push(n,o),(e.preOrderCheckHooks??=[]).push(n,o)}r&&(e.preOrderHooks??=[]).push(0-n,r),s&&((e.preOrderHooks??=[]).push(n,s),(e.preOrderCheckHooks??=[]).push(n,s))}(e,s[e],t)}finally{null!==h&&oo(h),Fm(a),o.resolving=!1,wA()}}return r}function zA(n,t,e){return!!(e[t+(n>>AA)]&1<Array.isArray(e)?fu(e,t):t(e))}function FA(n,t,e){t>=n.length?n.push(e):n.splice(t,0,e)}function Vm(n,t){return t>=n.length-1?n.pop():n.splice(t,1)[0]}const vu=new Bt(""),YA=new Bt("",-1),g1=new Bt("");class Gm{get(t,e=vp){if(e===vp){const i=new Error(`NullInjectorError: No provider for ${dt(t)}!`);throw i.name="NullInjectorError",i}return e}}function aj(...n){return{\u0275providers:QA(0,n),\u0275fromNgModule:!0}}function QA(n,...t){const e=[],i=new Set;let r;const s=o=>{e.push(o)};return fu(t,o=>{const a=o;Xm(a,s,[],i)&&(r||=[],r.push(a))}),void 0!==r&&GA(r,s),e}function GA(n,t){for(let e=0;e{t(s,i)})}}function Xm(n,t,e,i){if(!(n=vt(n)))return!1;let r=null,s=wm(n);const o=!s&&di(n);if(s||o){if(o&&!o.standalone)return!1;r=n}else{const l=n.ngModule;if(s=wm(l),!s)return!1;r=l}const a=i.has(r);if(o){if(a)return!1;if(i.add(r),o.dependencies){const l="function"==typeof o.dependencies?o.dependencies():o.dependencies;for(const h of l)Xm(h,t,e,i)}}else{if(!s)return!1;{if(null!=s.imports&&!a){let h;i.add(r);try{fu(s.imports,c=>{Xm(c,t,e,i)&&(h||=[],h.push(c))})}finally{}void 0!==h&&GA(h,t)}if(!a){const h=Vc(r)||(()=>new r);t({provide:r,useFactory:h,deps:Qi},r),t({provide:g1,useValue:r,multi:!0},r),t({provide:vu,useValue:()=>_i(r),multi:!0},r)}const l=s.providers;if(null!=l&&!a){const h=n;m1(l,c=>{t(c,h)})}}}return r!==n&&void 0!==n.providers}function m1(n,t){for(let e of n)$l(e)&&(e=e.\u0275providers),Array.isArray(e)?m1(e,t):t(e)}const lj=Xe({provide:String,useValue:Xe});function y1(n){return null!==n&&"object"==typeof n&&lj in n}function Gc(n){return"function"==typeof n}const S1=new Bt(""),qm={},cj={};let I1;function $m(){return void 0===I1&&(I1=new Gm),I1}class ih{}class mu extends ih{get destroyed(){return this._destroyed}constructor(t,e,i,r){super(),this.parent=e,this.source=i,this.scopes=r,this.records=new Map,this._ngOnDestroyHooks=new Set,this._onDestroyHooks=[],this._destroyed=!1,M1(t,o=>this.processProvider(o)),this.records.set(YA,yu(void 0,this)),r.has("environment")&&this.records.set(ih,yu(void 0,this));const s=this.records.get(S1);null!=s&&"string"==typeof s.value&&this.scopes.add(s.value),this.injectorDefTypes=new Set(this.get(g1,Qi,xi.Self))}destroy(){this.assertNotDestroyed(),this._destroyed=!0;try{for(const e of this._ngOnDestroyHooks)e.ngOnDestroy();const t=this._onDestroyHooks;this._onDestroyHooks=[];for(const e of t)e()}finally{this.records.clear(),this._ngOnDestroyHooks.clear(),this.injectorDefTypes.clear()}}onDestroy(t){return this.assertNotDestroyed(),this._onDestroyHooks.push(t),()=>this.removeOnDestroy(t)}runInContext(t){this.assertNotDestroyed();const e=Gh(this),i=oo(void 0);try{return t()}finally{Gh(e),oo(i)}}get(t,e=vp,i=xi.Default){if(this.assertNotDestroyed(),t.hasOwnProperty(pp))return t[pp](this);i=Dm(i);const s=Gh(this),o=oo(void 0);try{if(!(i&xi.SkipSelf)){let l=this.records.get(t);if(void 0===l){const h=function gj(n){return"function"==typeof n||"object"==typeof n&&n instanceof Bt}(t)&&Mm(t);l=h&&this.injectableDefInScope(h)?yu(b1(t),qm):null,this.records.set(t,l)}if(null!=l)return this.hydrate(t,l)}return(i&xi.Self?$m():this.parent).get(t,e=i&xi.Optional&&e===vp?null:e)}catch(a){if("NullInjectorError"===a.name){if((a[Em]=a[Em]||[]).unshift(dt(t)),s)throw a;return function A_(n,t,e,i){const r=n[Em];throw t[BT]&&r.unshift(t[BT]),n.message=function L_(n,t,e,i=null){n=n&&"\n"===n.charAt(0)&&"\u0275"==n.charAt(1)?n.slice(2):n;let r=dt(t);if(Array.isArray(t))r=t.map(dt).join(" -> ");else if("object"==typeof t){let s=[];for(let o in t)if(t.hasOwnProperty(o)){let a=t[o];s.push(o+":"+("string"==typeof a?JSON.stringify(a):dt(a)))}r=`{${s.join(", ")}}`}return`${e}${i?"("+i+")":""}[${r}]: ${n.replace(C_,"\n ")}`}("\n"+n.message,r,e,i),n.ngTokenPath=r,n[Em]=null,n}(a,t,"R3InjectorError",this.source)}throw a}finally{oo(o),Gh(s)}}resolveInjectorInitializers(){const t=Gh(this),e=oo(void 0);try{const r=this.get(vu,Qi,xi.Self);for(const s of r)s()}finally{Gh(t),oo(e)}}toString(){const t=[],e=this.records;for(const i of e.keys())t.push(dt(i));return`R3Injector[${t.join(", ")}]`}assertNotDestroyed(){if(this._destroyed)throw new F(205,!1)}processProvider(t){let e=Gc(t=vt(t))?t:vt(t&&t.provide);const i=function uj(n){return y1(n)?yu(void 0,n.useValue):yu($A(n),qm)}(t);if(!Gc(t)&&!0===t.multi){let r=this.records.get(e);r||(r=yu(void 0,qm,!0),r.factory=()=>kb(r.multi),this.records.set(e,r)),e=t,r.multi.push(t)}this.records.set(e,i)}hydrate(t,e){return e.value===qm&&(e.value=cj,e.value=e.factory()),"object"==typeof e.value&&e.value&&function pj(n){return null!==n&&"object"==typeof n&&"function"==typeof n.ngOnDestroy}(e.value)&&this._ngOnDestroyHooks.add(e.value),e.value}injectableDefInScope(t){if(!t.providedIn)return!1;const e=vt(t.providedIn);return"string"==typeof e?"any"===e||this.scopes.has(e):this.injectorDefTypes.has(e)}removeOnDestroy(t){const e=this._onDestroyHooks.indexOf(t);-1!==e&&this._onDestroyHooks.splice(e,1)}}function b1(n){const t=Mm(n),e=null!==t?t.factory:Vc(n);if(null!==e)return e;if(n instanceof Bt)throw new F(204,!1);if(n instanceof Function)return function dj(n){if(n.length>0)throw new F(204,!1);const e=function I_(n){return n&&(n[Cm]||n[PT])||null}(n);return null!==e?()=>e.factory(n):()=>new n}(n);throw new F(204,!1)}function $A(n,t,e){let i;if(Gc(n)){const r=vt(n);return Vc(r)||b1(r)}if(y1(n))i=()=>vt(n.useValue);else if(function qA(n){return!(!n||!n.useFactory)}(n))i=()=>n.useFactory(...kb(n.deps||[]));else if(function XA(n){return!(!n||!n.useExisting)}(n))i=()=>_i(vt(n.useExisting));else{const r=vt(n&&(n.useClass||n.provide));if(!function fj(n){return!!n.deps}(n))return Vc(r)||b1(r);i=()=>new r(...kb(n.deps))}return i}function yu(n,t,e=!1){return{factory:n,value:t,multi:e?[]:void 0}}function M1(n,t){for(const e of n)Array.isArray(e)?M1(e,t):e&&$l(e)?M1(e.\u0275providers,t):t(e)}function eL(n,t=null,e=null,i){const r=function tL(n,t=null,e=null,i,r=new Set){const s=[e||Qi,aj(n)];return i=i||("object"==typeof n?void 0:dt(n)),new mu(s,t||$m(),i||null,r)}(n,t,e,i);return r.resolveInjectorInitializers(),r}let E1,Wo=(()=>{class n{static{this.THROW_IF_NOT_FOUND=vp}static{this.NULL=new Gm}static create(e,i){if(Array.isArray(e))return eL({name:""},i,e,"");{const r=e.name??"";return eL({name:r},e.parent,e.providers,r)}}static{this.\u0275prov=Yi({token:n,providedIn:"any",factory:()=>_i(YA)})}static{this.__NG_ELEMENT_ID__=-1}}return n})();const D1=new Bt("",{providedIn:"root",factory:()=>Cj}),Cj="ng",rL=new Bt(""),Su=new Bt("",{providedIn:"platform",factory:()=>"unknown"}),nL=new Bt("",{providedIn:"root",factory:()=>function Zh(){if(void 0!==E1)return E1;if(typeof document<"u")return document;throw new F(210,!1)}().body?.querySelector("[ngCspNonce]")?.getAttribute("ngCspNonce")||null});function ty(n){return 128==(128&n.flags)}var ec=function(n){return n[n.Important=1]="Important",n[n.DashCase=2]="DashCase",n}(ec||{});const N1=new Map;let Hj=0;const k1="__ngContext__";function Rs(n,t){ks(t)?(n[k1]=t[bp],function Fj(n){N1.set(n[bp],n)}(t)):n[k1]=t}let P1;function z1(n,t){return P1(n,t)}function bu(n,t,e,i,r){if(null!=i){let s,o=!1;Ps(i)?s=i:ks(i)&&(o=!0,i=i[Vr]);const a=pr(i);0===n&&null!==e?null==r?DL(t,e,a):qc(t,e,a,r||null,!0):1===n&&null!==e?qc(t,e,a,r||null,!0):2===n?function ly(n,t,e){const i=oy(n,t);i&&function t6(n,t,e,i){n.removeChild(t,e,i)}(n,i,t,e)}(t,a,o):3===n&&t.destroyNode(a),null!=s&&function n6(n,t,e,i,r){const s=e[sl];s!==pr(e)&&bu(t,n,i,s,r);for(let a=mn;a0&&(n[e-1][wa]=i[wa]);const s=Vm(n,mn+t);!function Xj(n,t){wL(n,t),t[Vr]=null,t[Os]=null}(i[Be],i);const o=s[nl];null!==o&&o.detachView(s[Be]),i[vn]=null,i[wa]=null,i[Ct]&=-129}return i}function sy(n,t){if(!(256&t[Ct])){const e=t[Yt];e.destroyNode&&hy(n,t,e,3,null,null),function $j(n){let t=n[Sp];if(!t)return H1(n[Be],n);for(;t;){let e=null;if(ks(t))e=t[Sp];else{const i=t[mn];i&&(e=i)}if(!e){for(;t&&!t[wa]&&t!==n;)ks(t)&&H1(t[Be],t),t=t[vn];null===t&&(t=n),ks(t)&&H1(t[Be],t),e=t&&t[wa]}t=e}}(t)}}function H1(n,t){if(!(256&t[Ct])){t[Ct]&=-129,t[Ct]|=256,t[Uc]&&function Qd(n){if(Gl(n),Wh(n))for(let t=0;t=0?i[o]():i[-o].unsubscribe(),s+=2}else e[s].call(i[e[s+1]]);null!==i&&(t[Kd]=null);const r=t[qh];if(null!==r){t[qh]=null;for(let s=0;s-1){const{encapsulation:s}=n.data[i.directiveStart+r];if(s===ba.None||s===ba.Emulated)return null}return qs(i,e)}}(n,t.parent,e)}function qc(n,t,e,i,r){n.insertBefore(t,e,i,r)}function DL(n,t,e){n.appendChild(t,e)}function xL(n,t,e,i,r){null!==i?qc(n,t,e,i,r):DL(n,t,e)}function oy(n,t){return n.parentNode(t)}let F1,LL=function AL(n,t,e){return 40&n.type?qs(n,e):null};function ay(n,t,e,i){const r=B1(n,i,t),s=t[Yt],a=function TL(n,t,e){return LL(n,t,e)}(i.parent||t[Os],i,t);if(null!=r)if(Array.isArray(e))for(let l=0;lnull;function tM(n,t,e=!1){return $L(n,t,e)}class U6{}class tN{}class V6{resolveComponentFactory(t){throw function j6(n){const t=Error(`No component factory found for ${dt(n)}.`);return t.ngComponent=n,t}(t)}}let yy=(()=>{class n{static{this.NULL=new V6}}return n})();function W6(){return xu(gr(),Se())}function xu(n,t){return new $c(qs(n,t))}let $c=(()=>{class n{constructor(e){this.nativeElement=e}static{this.__NG_ELEMENT_ID__=W6}}return n})();function Y6(n){return n instanceof $c?n.nativeElement:n}class rN{}let sM=(()=>{class n{constructor(){this.destroyNode=null}static{this.__NG_ELEMENT_ID__=()=>function Q6(){const n=Se(),e=To(gr().index,n);return(ks(e)?e:n)[Yt]}()}}return n})(),G6=(()=>{class n{static{this.\u0275prov=Yi({token:n,providedIn:"root",factory:()=>null})}}return n})();const oM={};function Wp(n,t,e,i,r=!1){for(;null!==e;){const s=t[e.index];null!==s&&i.push(pr(s)),Ps(s)&&dN(s,i);const o=e.type;if(8&o)Wp(n,t,e.child,i);else if(32&o){const a=z1(e,t);let l;for(;l=a();)i.push(l)}else if(16&o){const a=OL(t,e);if(Array.isArray(a))i.push(...a);else{const l=Wc(t[Jr]);Wp(l[Be],l,a,i,!0)}}e=r?e.projectionNext:e.next}return i}function dN(n,t){for(let e=mn;e!1,producerRecomputeValue:()=>{},consumerMarkedDirty:()=>{},consumerOnSignalRead:()=>{},consumerIsAlwaysLive:!0,consumerMarkedDirty:n=>{Ep(n.lView)},consumerOnSignalRead(){this.lView[Uc]=this}};function fN(n){return gN(n[Sp])}function pN(n){return gN(n[wa])}function gN(n){for(;null!==n&&!Ps(n);)n=n[wa];return n}function hM(n){return n.ngOriginalError}class nh{constructor(){this._console=console}handleError(t){const e=this._findOriginalError(t);this._console.error("ERROR",t),e&&this._console.error("ORIGINAL ERROR",e)}_findOriginalError(t){let e=t&&hM(t);for(;e&&hM(e);)e=hM(e);return e||null}}const mN=new Bt("",{providedIn:"root",factory:()=>Hi(nh).handleError.bind(void 0)}),SN=new Bt("",{providedIn:"root",factory:()=>!1}),Qt={};function Ot(n,t=xi.Default){const e=Se();return null===e?_i(n,t):kA(gr(),e,vt(n),t)}function CN(n,t,e,i,r,s){const o=Wi(null);try{let a=null;r&Xh.SignalBased&&(a=t[i][Ts]),null!==a&&void 0!==a.transformFn&&(s=a.transformFn(s)),r&Xh.HasDecoratorInputTransform&&(s=n.inputTransforms[i].call(t,s)),null!==n.setInput?n.setInput(t,a,s,e,i):iA(t,a,i,s)}finally{Wi(o)}}function My(n,t,e,i,r,s,o,a,l,h,c){const d=t.blueprint.slice();return d[Vr]=r,d[Ct]=204|i,(null!==h||n&&2048&n[Ct])&&(d[Ct]|=2048),hA(d),d[vn]=d[eu]=n,d[Er]=e,d[Kl]=o||n&&n[Kl],d[Yt]=a||n&&n[Yt],d[Xs]=l||n&&n[Xs]||null,d[Os]=s,d[bp]=function Bj(){return Hj++}(),d[Ca]=c,d[JT]=h,d[Jr]=2==t.type?n[Jr]:d,d}function Tu(n,t,e,i,r){let s=n.data[t];if(null===s)s=function cM(n,t,e,i,r){const s=pA(),o=Gb(),l=n.data[t]=function EV(n,t,e,i,r,s){let o=t?t.injectorIndex:-1,a=0;return function nu(){return null!==Rt.skipHydrationRootTNode}()&&(a|=128),{type:e,index:i,insertBeforeIndex:null,injectorIndex:o,directiveStart:-1,directiveEnd:-1,directiveStylingLast:-1,componentOffset:-1,propertyBindings:null,flags:a,providerIndexes:0,value:r,attrs:s,mergedAttrs:null,localNames:null,initialInputs:void 0,inputs:null,outputs:null,tView:null,next:null,prev:null,projectionNext:null,child:null,parent:t,projection:null,styles:null,stylesWithoutHost:null,residualStyles:void 0,classes:null,classesWithoutHost:null,residualClasses:void 0,classBindings:0,styleBindings:0}}(0,o?s:s&&s.parent,e,t,i,r);return null===n.firstChild&&(n.firstChild=l),null!==s&&(o?null==s.child&&null!==l.parent&&(s.child=l):null===s.next&&(s.next=l,l.prev=s)),l}(n,t,e,i,r),function vU(){return Rt.lFrame.inI18n}()&&(s.flags|=32);else if(64&s.type){s.type=e,s.value=i,s.attrs=r;const o=function Dp(){const n=Rt.lFrame,t=n.currentTNode;return n.isParent?t:t.parent}();s.injectorIndex=null===o?-1:o.injectorIndex}return ll(s,!0),s}function Yp(n,t,e,i){if(0===e)return-1;const r=t.length;for(let s=0;sjt&&function wN(n,t,e,i){if(!i)if(3==(3&t[Ct])){const s=n.preOrderCheckHooks;null!==s&&Hm(t,s,e)}else{const s=n.preOrderHooks;null!==s&&Bm(t,s,0,e)}Yc(e)}(n,t,jt,!1),ol(o?2:0,r),e(i,r)}finally{Yc(s),ol(o?3:1,r)}}function dM(n,t,e){if(Bb(t)){const i=Wi(null);try{const s=t.directiveEnd;for(let o=t.directiveStart;onull;function TN(n,t,e,i,r){for(let s in t){if(!t.hasOwnProperty(s))continue;const o=t[s];if(void 0===o)continue;i??={};let a,l=Xh.None;Array.isArray(o)?(a=o[0],l=o[1]):a=o;let h=s;if(null!==r){if(!r.hasOwnProperty(s))continue;h=r[s]}0===n?AN(i,e,h,a,l):AN(i,e,h,a)}return i}function AN(n,t,e,i,r){let s;n.hasOwnProperty(e)?(s=n[e]).push(t,i):s=n[e]=[t,i],void 0!==r&&s.push(r)}function LN(n,t,e,i,r,s){for(let h=0;h0;){const e=n[--t];if("number"==typeof e&&e<0)return e}return 0})(o)!=a&&o.push(a),o.push(e,i,s)}}(n,t,i,Yp(n,e,r.hostVars,Qt),r)}function _V(n,t,e,i,r,s){const o=s[t];if(null!==o)for(let a=0;an.nextProducerIndex;)n.producerNode.pop(),n.producerLastReadVersion.pop(),n.producerIndexOfThis.pop()}}(a,o),function aV(n){n.lView[Uc]!==n&&(n.lView=null,uN.push(n))}(a)),Kb()}}function HN(n,t){for(let e=fN(n);null!==e;e=pN(e))for(let i=mn;i-1&&(Rp(t,i),Vm(e,i))}this._attachedToViewContainer=!1}sy(this._lView[Be],this._lView)}onDestroy(t){!function Pm(n,t){if(256==(256&n[Ct]))throw new F(911,!1);null===n[qh]&&(n[qh]=[]),n[qh].push(t)}(this._lView,t)}markForCheck(){Qp(this._cdRefInjectingView||this._lView)}detach(){this._lView[Ct]&=-129}reattach(){Yb(this._lView),this._lView[Ct]|=128}detectChanges(){this._lView[Ct]|=1024,IM(this._lView,this.notifyErrorHandler)}checkNoChanges(){}attachToViewContainerRef(){if(this._appRef)throw new F(902,!1);this._attachedToViewContainer=!0}detachFromAppRef(){this._appRef=null,wL(this._lView[Be],this._lView)}attachToAppRef(t){if(this._attachedToViewContainer)throw new F(902,!1);this._appRef=t,Yb(this._lView)}}const UN=new Set;function wM(n){return t=>{setTimeout(n,void 0,t)}}const Yo=class n7 extends Pt{constructor(t=!1){super(),this.__isAsync=t}emit(t){super.next(t)}subscribe(t,e,i){let r=t,s=e||(()=>null),o=i;if(t&&"object"==typeof t){const l=t;r=l.next?.bind(l),s=l.error?.bind(l),o=l.complete?.bind(l)}this.__isAsync&&(s=wM(s),r&&(r=wM(r)),o&&(o=wM(o)));const a=super.subscribe({next:r,error:s,complete:o});return t instanceof As&&t.add(a),a}};function jN(...n){}class Rr{constructor({enableLongStackTrace:t=!1,shouldCoalesceEventChangeDetection:e=!1,shouldCoalesceRunChangeDetection:i=!1}){if(this.hasPendingMacrotasks=!1,this.hasPendingMicrotasks=!1,this.isStable=!0,this.onUnstable=new Yo(!1),this.onMicrotaskEmpty=new Yo(!1),this.onStable=new Yo(!1),this.onError=new Yo(!1),typeof Zone>"u")throw new F(908,!1);Zone.assertZonePatched();const r=this;r._nesting=0,r._outer=r._inner=Zone.current,Zone.TaskTrackingZoneSpec&&(r._inner=r._inner.fork(new Zone.TaskTrackingZoneSpec)),t&&Zone.longStackTraceZoneSpec&&(r._inner=r._inner.fork(Zone.longStackTraceZoneSpec)),r.shouldCoalesceEventChangeDetection=!i&&e,r.shouldCoalesceRunChangeDetection=i,r.lastRequestAnimationFrameId=-1,r.nativeRequestAnimationFrame=function s7(){const n="function"==typeof rr.requestAnimationFrame;let t=rr[n?"requestAnimationFrame":"setTimeout"],e=rr[n?"cancelAnimationFrame":"clearTimeout"];if(typeof Zone<"u"&&t&&e){const i=t[Zone.__symbol__("OriginalDelegate")];i&&(t=i);const r=e[Zone.__symbol__("OriginalDelegate")];r&&(e=r)}return{nativeRequestAnimationFrame:t,nativeCancelAnimationFrame:e}}().nativeRequestAnimationFrame,function l7(n){const t=()=>{!function a7(n){n.isCheckStableRunning||-1!==n.lastRequestAnimationFrameId||(n.lastRequestAnimationFrameId=n.nativeRequestAnimationFrame.call(rr,()=>{n.fakeTopEventTask||(n.fakeTopEventTask=Zone.root.scheduleEventTask("fakeTopEventTask",()=>{n.lastRequestAnimationFrameId=-1,EM(n),n.isCheckStableRunning=!0,CM(n),n.isCheckStableRunning=!1},void 0,()=>{},()=>{})),n.fakeTopEventTask.invoke()}),EM(n))}(n)};n._inner=n._inner.fork({name:"angular",properties:{isAngularZone:!0},onInvokeTask:(e,i,r,s,o,a)=>{if(function h7(n){return!(!Array.isArray(n)||1!==n.length)&&!0===n[0].data?.__ignore_ng_zone__}(a))return e.invokeTask(r,s,o,a);try{return VN(n),e.invokeTask(r,s,o,a)}finally{(n.shouldCoalesceEventChangeDetection&&"eventTask"===s.type||n.shouldCoalesceRunChangeDetection)&&t(),WN(n)}},onInvoke:(e,i,r,s,o,a,l)=>{try{return VN(n),e.invoke(r,s,o,a,l)}finally{n.shouldCoalesceRunChangeDetection&&t(),WN(n)}},onHasTask:(e,i,r,s)=>{e.hasTask(r,s),i===r&&("microTask"==s.change?(n._hasPendingMicrotasks=s.microTask,EM(n),CM(n)):"macroTask"==s.change&&(n.hasPendingMacrotasks=s.macroTask))},onHandleError:(e,i,r,s)=>(e.handleError(r,s),n.runOutsideAngular(()=>n.onError.emit(s)),!1)})}(r)}static isInAngularZone(){return typeof Zone<"u"&&!0===Zone.current.get("isAngularZone")}static assertInAngularZone(){if(!Rr.isInAngularZone())throw new F(909,!1)}static assertNotInAngularZone(){if(Rr.isInAngularZone())throw new F(909,!1)}run(t,e,i){return this._inner.run(t,e,i)}runTask(t,e,i,r){const s=this._inner,o=s.scheduleEventTask("NgZoneEvent: "+r,t,o7,jN,jN);try{return s.runTask(o,e,i)}finally{s.cancelTask(o)}}runGuarded(t,e,i){return this._inner.runGuarded(t,e,i)}runOutsideAngular(t){return this._outer.run(t)}}const o7={};function CM(n){if(0==n._nesting&&!n.hasPendingMicrotasks&&!n.isStable)try{n._nesting++,n.onMicrotaskEmpty.emit(null)}finally{if(n._nesting--,!n.hasPendingMicrotasks)try{n.runOutsideAngular(()=>n.onStable.emit(null))}finally{n.isStable=!0}}}function EM(n){n.hasPendingMicrotasks=!!(n._hasPendingMicrotasks||(n.shouldCoalesceEventChangeDetection||n.shouldCoalesceRunChangeDetection)&&-1!==n.lastRequestAnimationFrameId)}function VN(n){n._nesting++,n.isStable&&(n.isStable=!1,n.onUnstable.emit(null))}function WN(n){n._nesting--,CM(n)}let Xp=(()=>{class n{constructor(){this.handler=null,this.internalCallbacks=[]}execute(){const e=[...this.internalCallbacks];this.internalCallbacks.length=0;for(const r of e)r();return!!this.handler?.execute()||e.length>0}ngOnDestroy(){this.handler?.destroy(),this.handler=null,this.internalCallbacks.length=0}static{this.\u0275prov=Yi({token:n,providedIn:"root",factory:()=>new n})}}return n})();function f7(n,t){const e=To(t,n),i=e[Be];!function p7(n,t){for(let e=t.length;e0&&zL(n,e,s.join(" "))}}(u,w,p,i),void 0!==e&&function C7(n,t,e){const i=n.projection=[];for(let r=0;r=0;i--){const r=n[i];r.hostVars=t+=r.hostVars,r.hostAttrs=yp(r.hostAttrs,e=yp(e,r.hostAttrs))}}(i)}function D7(n,t){for(const e in t.inputs){if(!t.inputs.hasOwnProperty(e)||n.inputs.hasOwnProperty(e))continue;const i=t.inputs[e];if(void 0!==i&&(n.inputs[e]=i,n.declaredInputs[e]=t.declaredInputs[e],null!==t.inputTransforms)){const r=Array.isArray(i)?i[0]:i;if(!t.inputTransforms.hasOwnProperty(r))continue;n.inputTransforms??={},n.inputTransforms[r]=t.inputTransforms[r]}}}function Dy(n){return n===rl?{}:n===Qi?[]:n}function T7(n,t){const e=n.viewQuery;n.viewQuery=e?(i,r)=>{t(i,r),e(i,r)}:t}function A7(n,t){const e=n.contentQueries;n.contentQueries=e?(i,r,s)=>{t(i,r,s),e(i,r,s)}:t}function L7(n,t){const e=n.hostBindings;n.hostBindings=e?(i,r)=>{t(i,r),e(i,r)}:t}function Lu(n,t){return!t||null===t.firstChild||ty(n)}function tg(n,t,e,i=!0){const r=t[Be];if(function Zj(n,t,e,i){const r=mn+i,s=e.length;i>0&&(e[r-1][wa]=t),i{class n{static{this.__NG_ELEMENT_ID__=n9}}return n})();function n9(){return dO(gr(),Se())}const s9=An,hO=class extends s9{constructor(t,e,i){super(),this._lContainer=t,this._hostTNode=e,this._hostLView=i}get element(){return xu(this._hostTNode,this._hostLView)}get injector(){return new Yn(this._hostTNode,this._hostLView)}get parentInjector(){const t=Um(this._hostTNode,this._hostLView);if(i1(t)){const e=Ap(t,this._hostLView),i=Tp(t);return new Yn(e[Be].data[i+8],e)}return new Yn(null,this._hostLView)}clear(){for(;this.length>0;)this.remove(this.length-1)}get(t){const e=cO(this._lContainer);return null!==e&&e[t]||null}get length(){return this._lContainer.length-mn}createEmbeddedView(t,e,i){let r,s;"number"==typeof i?r=i:null!=i&&(r=i.index,s=i.injector);const a=t.createEmbeddedViewImpl(e||{},s,null);return this.insertImpl(a,r,Lu(this._hostTNode,null)),a}createComponent(t,e,i,r,s){const o=t&&!function Lp(n){return"function"==typeof n}(t);let a;if(o)a=e;else{const p=e||{};a=p.index,i=p.injector,r=p.projectableNodes,s=p.environmentInjector||p.ngModuleRef}const l=o?t:new qp(di(t)),h=i||this.parentInjector;if(!s&&null==l.ngModule){const g=(o?h:this.parentInjector).get(ih,null);g&&(s=g)}di(l.componentType??{});const f=l.create(h,r,null,s);return this.insertImpl(f.hostView,a,Lu(this._hostTNode,null)),f}insert(t,e){return this.insertImpl(t,e,!0)}insertImpl(t,e,i){const r=t._lView;if(function rU(n){return Ps(n[vn])}(r)){const a=this.indexOf(t);if(-1!==a)this.detach(a);else{const l=r[vn],h=new hO(l,l[Os],l[vn]);h.detach(h.indexOf(t))}}const s=this._adjustIndex(e),o=this._lContainer;return tg(o,r,s,i),t.attachToViewContainerRef(),FA(kM(o),s,t),t}move(t,e){return this.insert(t,e)}indexOf(t){const e=cO(this._lContainer);return null!==e?e.indexOf(t):-1}remove(t){const e=this._adjustIndex(t,-1),i=Rp(this._lContainer,e);i&&(Vm(kM(this._lContainer),e),sy(i[Be],i))}detach(t){const e=this._adjustIndex(t,-1),i=Rp(this._lContainer,e);return i&&null!=Vm(kM(this._lContainer),e)?new Gp(i):null}_adjustIndex(t,e=0){return t??this.length+e}};function cO(n){return n[8]}function kM(n){return n[8]||(n[8]=[])}function dO(n,t){let e;const i=t[n.index];return Ps(i)?e=i:(e=function ON(n,t,e,i){return[n,!0,0,t,null,i,null,e,null,null]}(i,t,null,n),t[n.index]=e,wy(t,e)),uO(e,t,n,i),new hO(e,n,t)}let uO=function pO(n,t,e,i){if(n[sl])return;let r;r=8&e.type?pr(i):function o9(n,t){const e=n[Yt],i=e.createComment(""),r=qs(t,n);return qc(e,oy(e,r),i,function i6(n,t){return n.nextSibling(t)}(e,r),!1),i}(t,e),n[sl]=r};function QM(n,t,e){const i=Se();return function Ln(n,t,e){return!Object.is(n[t],e)&&(n[t]=e,!0)}(i,function hl(){return Rt.lFrame.bindingIndex++}(),t)&&function No(n,t,e,i,r,s,o,a){const l=qs(t,e);let c,h=t.inputs;!a&&null!=h&&(c=h[i])?(SM(n,e,c,i,r),jc(t)&&function TV(n,t){const e=To(t,n);16&e[Ct]||(e[Ct]|=64)}(e,t.index)):3&t.type&&(i=function xV(n){return"class"===n?"className":"for"===n?"htmlFor":"formaction"===n?"formAction":"innerHtml"===n?"innerHTML":"readonly"===n?"readOnly":"tabindex"===n?"tabIndex":n}(i),r=null!=o?o(r,t.value||"",i):r,s.setProperty(l,i,r))}(Ti(),function zr(){const n=Rt.lFrame;return Cp(n.tView,n.selectedIndex)}(),i,n,t,i[Yt],e,!1),QM}function GM(n,t,e,i,r){const o=r?"class":"style";SM(n,e,t.inputs[o],o,i)}function KM(n,t,e,i){const r=Se(),s=Ti(),o=jt+n,a=r[Yt],l=s.firstCreatePass?function k8(n,t,e,i,r,s){const o=t.consts,l=Tu(t,n,2,i,al(o,r));return function gM(n,t,e,i){if(fA()){const r=null===i?null:{"":-1},s=function PV(n,t){const e=n.directiveRegistry;let i=null,r=null;if(e)for(let s=0;s(function $h(n){EA=n}(!0),ny(i,r,function CA(){return Rt.lFrame.currentNamespace}()));const Xu="en-US";let Ik=Xu;function ow(n){return!!n&&"function"==typeof n.then}function Yk(n){return!!n&&"function"==typeof n.subscribe}function UW(){return this._results[Symbol.iterator]()}class lw{get changes(){return this._changes??=new Yo}constructor(t=!1){this._emitDistinctChangesOnly=t,this.dirty=!0,this._results=[],this._changesDetected=!1,this._changes=void 0,this.length=0,this.first=void 0,this.last=void 0;const e=lw.prototype;e[Symbol.iterator]||(e[Symbol.iterator]=UW)}get(t){return this._results[t]}map(t){return this._results.map(t)}filter(t){return this._results.filter(t)}find(t){return this._results.find(t)}reduce(t,e){return this._results.reduce(t,e)}forEach(t){this._results.forEach(t)}some(t){return this._results.some(t)}toArray(){return this._results.slice()}toString(){return this._results.toString()}reset(t,e){this.dirty=!1;const i=function lo(n){return n.flat(Number.POSITIVE_INFINITY)}(t);(this._changesDetected=!function WU(n,t,e){if(n.length!==t.length)return!1;for(let i=0;i{class n{static{this.__NG_ELEMENT_ID__=WW}}return n})();const jW=oh,VW=class extends jW{constructor(t,e,i){super(),this._declarationLView=t,this._declarationTContainer=e,this.elementRef=i}get ssrId(){return this._declarationTContainer.tView?.ssrId||null}createEmbeddedView(t,e){return this.createEmbeddedViewImpl(t,e)}createEmbeddedViewImpl(t,e,i){const r=function eg(n,t,e,i){const r=t.tView,a=My(n,r,e,4096&n[Ct]?4096:16,null,t,null,null,null,i?.injector??null,i?.dehydratedView??null);a[Ip]=n[t.index];const h=n[nl];return null!==h&&(a[nl]=h.createEmbeddedView(r)),DM(r,a,e),a}(this._declarationLView,this._declarationTContainer,t,{injector:e,dehydratedView:i});return new Gp(r)}};function WW(){return Vy(gr(),Se())}function Vy(n,t){return 4&n.type?new VW(t,n,xu(n,t)):null}class hw{constructor(t){this.queryList=t,this.matches=null}clone(){return new hw(this.queryList)}setDirty(){this.queryList.setDirty()}}class cw{constructor(t=[]){this.queries=t}createEmbeddedView(t){const e=t.queries;if(null!==e){const i=null!==t.contentQueries?t.contentQueries[0]:e.length,r=[];for(let s=0;s0)i.push(o[a/2]);else{const h=s[a+1],c=t[-l];for(let d=mn;d>20;if(Gc(n)||!n.multi){const f=new xp(h,r,Ot),p=mw(l,t,r?c:c+u,d);-1===p?(s1(_m(a,o),s,l),vw(s,n,t.length),t.push(l),a.directiveStart++,a.directiveEnd++,r&&(a.providerIndexes+=1048576),e.push(f),o.push(f)):(e[p]=f,o[p]=f)}else{const f=mw(l,t,c+u,d),p=mw(l,t,c,c+u),v=p>=0&&e[p];if(r&&!v||!r&&!(f>=0&&e[f])){s1(_m(a,o),s,l);const y=function pY(n,t,e,i,r){const s=new xp(n,e,Ot);return s.multi=[],s.index=t,s.componentProviders=0,NP(s,r,i&&!e),s}(r?fY:uY,e.length,r,i,h);!r&&v&&(e[p].providerFactory=y),vw(s,n,t.length,0),t.push(l),a.directiveStart++,a.directiveEnd++,r&&(a.providerIndexes+=1048576),e.push(y),o.push(y)}else vw(s,n,f>-1?f:p,NP(e[r?p:f],h,!r&&i));!r&&i&&v&&e[p].componentProviders++}}}function vw(n,t,e,i){const r=Gc(t),s=function hj(n){return!!n.useClass}(t);if(r||s){const l=(s?vt(t.useClass):t).prototype.ngOnDestroy;if(l){const h=n.destroyHooks||(n.destroyHooks=[]);if(!r&&t.multi){const c=h.indexOf(e);-1===c?h.push(e,[i,l]):h[c+1].push(i,l)}else h.push(e,l)}}}function NP(n,t,e){return e&&n.componentProviders++,n.multi.push(t)-1}function mw(n,t,e,i){for(let r=e;r{e.providersResolver=(i,r)=>function dY(n,t,e){const i=Ti();if(i.firstCreatePass){const r=Ea(n);gw(e,i.data,i.blueprint,r,!0),gw(t,i.data,i.blueprint,r,!1)}}(i,r?r(n):n,t)}}class rd{}class kP extends rd{constructor(t){super(),this.componentFactoryResolver=new $N(this),this.instance=null;const e=new mu([...t.providers,{provide:rd,useValue:this},{provide:yy,useValue:this.componentFactoryResolver}],t.parent||$m(),t.debugName,new Set(["environment"]));this.injector=e,t.runEnvironmentInitializers&&e.resolveInjectorInitializers()}destroy(){this.injector.destroy()}onDestroy(t){this.injector.onDestroy(t)}}let SY=(()=>{class n{constructor(e){this._injector=e,this.cachedInjectors=new Map}getOrCreateStandaloneInjector(e){if(!e.standalone)return null;if(!this.cachedInjectors.has(e)){const i=QA(0,e.type),r=i.length>0?function yY(n,t,e=null){return new kP({providers:n,parent:t,debugName:e,runEnvironmentInitializers:!0}).injector}([i],this._injector,`Standalone[${e.type.name}]`):null;this.cachedInjectors.set(e,r)}return this.cachedInjectors.get(e)}ngOnDestroy(){try{for(const e of this.cachedInjectors.values())null!==e&&e.destroy()}finally{this.cachedInjectors.clear()}}static{this.\u0275prov=Yi({token:n,providedIn:"environment",factory:()=>new n(_i(ih))})}}return n})();function PP(n){(function Zc(n){UN.has(n)||(UN.add(n),performance?.mark?.("mark_feature_usage",{detail:{feature:n}}))})("NgStandalone"),n.getStandaloneInjector=t=>t.get(SY).getOrCreateStandaloneInjector(n)}let xw=(()=>{class n{constructor(){this.taskId=0,this.pendingTasks=new Set,this.hasPendingTasks=new _o(!1)}get _hasPendingTasks(){return this.hasPendingTasks.value}add(){this._hasPendingTasks||this.hasPendingTasks.next(!0);const e=this.taskId++;return this.pendingTasks.add(e),e}remove(e){this.pendingTasks.delete(e),0===this.pendingTasks.size&&this._hasPendingTasks&&this.hasPendingTasks.next(!1)}ngOnDestroy(){this.pendingTasks.clear(),this._hasPendingTasks&&this.hasPendingTasks.next(!1)}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();const f2=new Bt(""),WQ=new Bt("");let Ow=(()=>{class n{constructor(){this.initialized=!1,this.done=!1,this.donePromise=new Promise((e,i)=>{this.resolve=e,this.reject=i}),this.appInits=Hi(WQ,{optional:!0})??[]}runInitializers(){if(this.initialized)return;const e=[];for(const r of this.appInits){const s=r();if(ow(s))e.push(s);else if(Yk(s)){const o=new Promise((a,l)=>{s.subscribe({complete:a,error:l})});e.push(o)}}const i=()=>{this.done=!0,this.resolve()};Promise.all(e).then(()=>{i()}).catch(r=>{this.reject(r)}),0===e.length&&i(),this.initialized=!0}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();const p2=new Bt("");let Zu=(()=>{class n{constructor(){this._bootstrapListeners=[],this._runningTick=!1,this._destroyed=!1,this._destroyListeners=[],this._views=[],this.internalErrorHandler=Hi(mN),this.afterRenderEffectManager=Hi(Xp),this.componentTypes=[],this.components=[],this.isStable=Hi(xw).hasPendingTasks.pipe(jr(e=>!e)),this._injector=Hi(ih)}get destroyed(){return this._destroyed}get injector(){return this._injector}bootstrap(e,i){const r=e instanceof tN;if(!this._injector.get(Ow).done)throw!r&&function _c(n){const t=di(n)||Wn(n)||gs(n);return null!==t&&t.standalone}(e),new F(405,!1);let o;o=r?e:this._injector.get(yy).resolveComponentFactory(e),this.componentTypes.push(o.componentType);const a=function QQ(n){return n.isBoundToModule}(o)?void 0:this._injector.get(rd),h=o.create(Wo.NULL,[],i||o.selector,a),c=h.location.nativeElement,d=h.injector.get(f2,null);return d?.registerApplication(c),h.onDestroy(()=>{this.detachView(h.hostView),qy(this.components,h),d?.unregisterApplication(c)}),this._loadComponent(h),h}tick(){if(this._runningTick)throw new F(101,!1);try{this._runningTick=!0;for(let e of this._views)e.detectChanges()}catch(e){this.internalErrorHandler(e)}finally{try{this.afterRenderEffectManager.execute()}catch(e){this.internalErrorHandler(e)}this._runningTick=!1}}attachView(e){const i=e;this._views.push(i),i.attachToAppRef(this)}detachView(e){const i=e;qy(this._views,i),i.detachFromAppRef()}_loadComponent(e){this.attachView(e.hostView),this.tick(),this.components.push(e);const i=this._injector.get(p2,[]);[...this._bootstrapListeners,...i].forEach(r=>r(e))}ngOnDestroy(){if(!this._destroyed)try{this._destroyListeners.forEach(e=>e()),this._views.slice().forEach(e=>e.destroy())}finally{this._destroyed=!0,this._views=[],this._bootstrapListeners=[],this._destroyListeners=[]}}onDestroy(e){return this._destroyListeners.push(e),()=>qy(this._destroyListeners,e)}destroy(){if(this._destroyed)throw new F(406,!1);const e=this._injector;e.destroy&&!e.destroyed&&e.destroy()}get viewCount(){return this._views.length}warnIfDestroyed(){}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();function qy(n,t){const e=n.indexOf(t);e>-1&&n.splice(e,1)}let XQ=(()=>{class n{constructor(){this.zone=Hi(Rr),this.applicationRef=Hi(Zu)}initialize(){this._onMicrotaskEmptySubscription||(this._onMicrotaskEmptySubscription=this.zone.onMicrotaskEmpty.subscribe({next:()=>{this.zone.run(()=>{this.applicationRef.tick()})}}))}ngOnDestroy(){this._onMicrotaskEmptySubscription?.unsubscribe()}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();function S2(n){return[{provide:Rr,useFactory:n},{provide:vu,multi:!0,useFactory:()=>{const t=Hi(XQ,{optional:!0});return()=>t.initialize()}},{provide:vu,multi:!0,useFactory:()=>{const t=Hi(ZQ);return()=>{t.initialize()}}},{provide:mN,useFactory:qQ}]}function qQ(){const n=Hi(Rr),t=Hi(nh);return e=>n.runOutsideAngular(()=>t.handleError(e))}function $Q(n){return function v1(n){return{\u0275providers:n}}([[],S2(()=>new Rr(function I2(n){return{enableLongStackTrace:!1,shouldCoalesceEventChangeDetection:n?.eventCoalescing??!1,shouldCoalesceRunChangeDetection:n?.runCoalescing??!1}}(n)))])}let ZQ=(()=>{class n{constructor(){this.subscription=new As,this.initialized=!1,this.zone=Hi(Rr),this.pendingTasks=Hi(xw)}initialize(){if(this.initialized)return;this.initialized=!0;let e=null;!this.zone.isStable&&!this.zone.hasPendingMacrotasks&&!this.zone.hasPendingMicrotasks&&(e=this.pendingTasks.add()),this.zone.runOutsideAngular(()=>{this.subscription.add(this.zone.onStable.subscribe(()=>{Rr.assertNotInAngularZone(),queueMicrotask(()=>{null!==e&&!this.zone.hasPendingMacrotasks&&!this.zone.hasPendingMicrotasks&&(this.pendingTasks.remove(e),e=null)})}))}),this.subscription.add(this.zone.onUnstable.subscribe(()=>{Rr.assertInAngularZone(),e??=this.pendingTasks.add()}))}ngOnDestroy(){this.subscription.unsubscribe()}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();const ah=new Bt("",{providedIn:"root",factory:()=>Hi(ah,xi.Optional|xi.SkipSelf)||function JQ(){return typeof $localize<"u"&&$localize.locale||Xu}()}),kw=new Bt("");let nc=null;function MG(n){try{const{rootComponent:t,appProviders:e,platformProviders:i}=n,r=function rG(n=[]){if(nc)return nc;const t=function w2(n=[],t){return Wo.create({name:t,providers:[{provide:S1,useValue:"platform"},{provide:kw,useValue:new Set([()=>nc=null])},...n]})}(n);return nc=t,function g2(){!function mb(n){Xd=n}(()=>{throw new F(600,!1)})}(),function C2(n){n.get(rL,null)?.forEach(e=>e())}(t),t}(i),s=[$Q(),...e||[]],a=new kP({providers:s,parent:r,debugName:"",runEnvironmentInitializers:!1}).injector,l=a.get(Rr);return l.run(()=>{a.resolveInjectorInitializers();const h=a.get(nh,null);let c;l.runOutsideAngular(()=>{c=l.onError.subscribe({next:f=>{h.handleError(f)}})});const d=()=>a.destroy(),u=r.get(kw);return u.add(d),a.onDestroy(()=>{c.unsubscribe(),u.delete(d)}),function v2(n,t,e){try{const i=e();return ow(i)?i.catch(r=>{throw t.runOutsideAngular(()=>n.handleError(r)),r}):i}catch(i){throw t.runOutsideAngular(()=>n.handleError(i)),i}}(h,l,()=>{const f=a.get(Ow);return f.runInitializers(),f.donePromise.then(()=>{!function bk(n){so(n,"Expected localeId to be defined"),"string"==typeof n&&(Ik=n.toLowerCase().replace(/_/g,"-"))}(a.get(ah,Xu)||Xu);const g=a.get(Zu);return void 0!==t&&g.bootstrap(t),g})})})}catch(t){return Promise.reject(t)}}let X2=null;function Uw(){return X2}class HG{}const sd=new Bt("");let tq=(()=>{class n{static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275mod=Tm({type:n})}static{this.\u0275inj=gp({})}}return n})();function cz(n){return"server"===n}class Aq extends HG{constructor(){super(...arguments),this.supportsDOMEvents=!0}}class nC extends Aq{static makeCurrent(){!function RG(n){X2??=n}(new nC)}onAndCancel(t,e,i){return t.addEventListener(e,i),()=>{t.removeEventListener(e,i)}}dispatchEvent(t,e){t.dispatchEvent(e)}remove(t){t.parentNode&&t.parentNode.removeChild(t)}createElement(t,e){return(e=e||this.getDefaultDocument()).createElement(t)}createHtmlDocument(){return document.implementation.createHTMLDocument("fakeTitle")}getDefaultDocument(){return document}isElementNode(t){return t.nodeType===Node.ELEMENT_NODE}isShadowRoot(t){return t instanceof DocumentFragment}getGlobalEventTarget(t,e){return"window"===e?window:"document"===e?t:"body"===e?t.body:null}getBaseHref(t){const e=function Lq(){return bg=bg||document.querySelector("base"),bg?bg.getAttribute("href"):null}();return null==e?null:function Nq(n){return new URL(n,document.baseURI).pathname}(e)}resetBaseElement(){bg=null}getUserAgent(){return window.navigator.userAgent}getCookie(t){return function wX(n,t){t=encodeURIComponent(t);for(const e of n.split(";")){const i=e.indexOf("="),[r,s]=-1==i?[e,""]:[e.slice(0,i),e.slice(i+1)];if(r.trim()===t)return decodeURIComponent(s)}return null}(document.cookie,t)}}let bg=null,kq=(()=>{class n{build(){return new XMLHttpRequest}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();const sC=new Bt("");let pz=(()=>{class n{constructor(e,i){this._zone=i,this._eventNameToPlugin=new Map,e.forEach(r=>{r.manager=this}),this._plugins=e.slice().reverse()}addEventListener(e,i,r){return this._findPluginFor(i).addEventListener(e,i,r)}getZone(){return this._zone}_findPluginFor(e){let i=this._eventNameToPlugin.get(e);if(i)return i;if(i=this._plugins.find(s=>s.supports(e)),!i)throw new F(5101,!1);return this._eventNameToPlugin.set(e,i),i}static{this.\u0275fac=function(i){return new(i||n)(_i(sC),_i(Rr))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();class gz{constructor(t){this._doc=t}}const oC="ng-app-id";let vz=(()=>{class n{constructor(e,i,r,s={}){this.doc=e,this.appId=i,this.nonce=r,this.platformId=s,this.styleRef=new Map,this.hostNodes=new Set,this.styleNodesInDOM=this.collectServerRenderedStyles(),this.platformIsServer=cz(s),this.resetHostNodes()}addStyles(e){for(const i of e)1===this.changeUsageCount(i,1)&&this.onStyleAdded(i)}removeStyles(e){for(const i of e)this.changeUsageCount(i,-1)<=0&&this.onStyleRemoved(i)}ngOnDestroy(){const e=this.styleNodesInDOM;e&&(e.forEach(i=>i.remove()),e.clear());for(const i of this.getAllStyles())this.onStyleRemoved(i);this.resetHostNodes()}addHost(e){this.hostNodes.add(e);for(const i of this.getAllStyles())this.addStyleToHost(e,i)}removeHost(e){this.hostNodes.delete(e)}getAllStyles(){return this.styleRef.keys()}onStyleAdded(e){for(const i of this.hostNodes)this.addStyleToHost(i,e)}onStyleRemoved(e){const i=this.styleRef;i.get(e)?.elements?.forEach(r=>r.remove()),i.delete(e)}collectServerRenderedStyles(){const e=this.doc.head?.querySelectorAll(`style[${oC}="${this.appId}"]`);if(e?.length){const i=new Map;return e.forEach(r=>{null!=r.textContent&&i.set(r.textContent,r)}),i}return null}changeUsageCount(e,i){const r=this.styleRef;if(r.has(e)){const s=r.get(e);return s.usage+=i,s.usage}return r.set(e,{usage:i,elements:[]}),i}getStyleElement(e,i){const r=this.styleNodesInDOM,s=r?.get(i);if(s?.parentNode===e)return r.delete(i),s.removeAttribute(oC),s;{const o=this.doc.createElement("style");return this.nonce&&o.setAttribute("nonce",this.nonce),o.textContent=i,this.platformIsServer&&o.setAttribute(oC,this.appId),e.appendChild(o),o}}addStyleToHost(e,i){const r=this.getStyleElement(e,i),s=this.styleRef,o=s.get(i)?.elements;o?o.push(r):s.set(i,{elements:[r],usage:1})}resetHostNodes(){const e=this.hostNodes;e.clear(),e.add(this.doc.head)}static{this.\u0275fac=function(i){return new(i||n)(_i(sd),_i(D1),_i(nL,8),_i(Su))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();const aC={svg:"http://www.w3.org/2000/svg",xhtml:"http://www.w3.org/1999/xhtml",xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/",math:"http://www.w3.org/1998/MathML/"},lC=/%COMP%/g,Hq=new Bt("",{providedIn:"root",factory:()=>!0});function yz(n,t){return t.map(e=>e.replace(lC,n))}let Sz=(()=>{class n{constructor(e,i,r,s,o,a,l,h=null){this.eventManager=e,this.sharedStylesHost=i,this.appId=r,this.removeStylesOnCompDestroy=s,this.doc=o,this.platformId=a,this.ngZone=l,this.nonce=h,this.rendererByCompId=new Map,this.platformIsServer=cz(a),this.defaultRenderer=new hC(e,o,l,this.platformIsServer)}createRenderer(e,i){if(!e||!i)return this.defaultRenderer;this.platformIsServer&&i.encapsulation===ba.ShadowDom&&(i={...i,encapsulation:ba.Emulated});const r=this.getOrCreateRenderer(e,i);return r instanceof bz?r.applyToHost(e):r instanceof cC&&r.applyStyles(),r}getOrCreateRenderer(e,i){const r=this.rendererByCompId;let s=r.get(i.id);if(!s){const o=this.doc,a=this.ngZone,l=this.eventManager,h=this.sharedStylesHost,c=this.removeStylesOnCompDestroy,d=this.platformIsServer;switch(i.encapsulation){case ba.Emulated:s=new bz(l,h,i,this.appId,c,o,a,d);break;case ba.ShadowDom:return new Uq(l,h,e,i,o,a,this.nonce,d);default:s=new cC(l,h,i,c,o,a,d)}r.set(i.id,s)}return s}ngOnDestroy(){this.rendererByCompId.clear()}static{this.\u0275fac=function(i){return new(i||n)(_i(pz),_i(vz),_i(D1),_i(Hq),_i(sd),_i(Su),_i(Rr),_i(nL))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();class hC{constructor(t,e,i,r){this.eventManager=t,this.doc=e,this.ngZone=i,this.platformIsServer=r,this.data=Object.create(null),this.throwOnSyntheticProps=!0,this.destroyNode=null}destroy(){}createElement(t,e){return e?this.doc.createElementNS(aC[e]||e,t):this.doc.createElement(t)}createComment(t){return this.doc.createComment(t)}createText(t){return this.doc.createTextNode(t)}appendChild(t,e){(Iz(t)?t.content:t).appendChild(e)}insertBefore(t,e,i){t&&(Iz(t)?t.content:t).insertBefore(e,i)}removeChild(t,e){t&&t.removeChild(e)}selectRootElement(t,e){let i="string"==typeof t?this.doc.querySelector(t):t;if(!i)throw new F(-5104,!1);return e||(i.textContent=""),i}parentNode(t){return t.parentNode}nextSibling(t){return t.nextSibling}setAttribute(t,e,i,r){if(r){e=r+":"+e;const s=aC[r];s?t.setAttributeNS(s,e,i):t.setAttribute(e,i)}else t.setAttribute(e,i)}removeAttribute(t,e,i){if(i){const r=aC[i];r?t.removeAttributeNS(r,e):t.removeAttribute(`${i}:${e}`)}else t.removeAttribute(e)}addClass(t,e){t.classList.add(e)}removeClass(t,e){t.classList.remove(e)}setStyle(t,e,i,r){r&(ec.DashCase|ec.Important)?t.style.setProperty(e,i,r&ec.Important?"important":""):t.style[e]=i}removeStyle(t,e,i){i&ec.DashCase?t.style.removeProperty(e):t.style[e]=""}setProperty(t,e,i){null!=t&&(t[e]=i)}setValue(t,e){t.nodeValue=e}listen(t,e,i){if("string"==typeof t&&!(t=Uw().getGlobalEventTarget(this.doc,t)))throw new Error(`Unsupported event target ${t} for event ${e}`);return this.eventManager.addEventListener(t,e,this.decoratePreventDefault(i))}decoratePreventDefault(t){return e=>{if("__ngUnwrap__"===e)return t;!1===(this.platformIsServer?this.ngZone.runGuarded(()=>t(e)):t(e))&&e.preventDefault()}}}function Iz(n){return"TEMPLATE"===n.tagName&&void 0!==n.content}class Uq extends hC{constructor(t,e,i,r,s,o,a,l){super(t,s,o,l),this.sharedStylesHost=e,this.hostEl=i,this.shadowRoot=i.attachShadow({mode:"open"}),this.sharedStylesHost.addHost(this.shadowRoot);const h=yz(r.id,r.styles);for(const c of h){const d=document.createElement("style");a&&d.setAttribute("nonce",a),d.textContent=c,this.shadowRoot.appendChild(d)}}nodeOrShadowRoot(t){return t===this.hostEl?this.shadowRoot:t}appendChild(t,e){return super.appendChild(this.nodeOrShadowRoot(t),e)}insertBefore(t,e,i){return super.insertBefore(this.nodeOrShadowRoot(t),e,i)}removeChild(t,e){return super.removeChild(this.nodeOrShadowRoot(t),e)}parentNode(t){return this.nodeOrShadowRoot(super.parentNode(this.nodeOrShadowRoot(t)))}destroy(){this.sharedStylesHost.removeHost(this.shadowRoot)}}class cC extends hC{constructor(t,e,i,r,s,o,a,l){super(t,s,o,a),this.sharedStylesHost=e,this.removeStylesOnCompDestroy=r,this.styles=l?yz(l,i.styles):i.styles}applyStyles(){this.sharedStylesHost.addStyles(this.styles)}destroy(){this.removeStylesOnCompDestroy&&this.sharedStylesHost.removeStyles(this.styles)}}class bz extends cC{constructor(t,e,i,r,s,o,a,l){const h=r+"-"+i.id;super(t,e,i,s,o,a,l,h),this.contentAttr=function Bq(n){return"_ngcontent-%COMP%".replace(lC,n)}(h),this.hostAttr=function Fq(n){return"_nghost-%COMP%".replace(lC,n)}(h)}applyToHost(t){this.applyStyles(),this.setAttribute(t,this.hostAttr,"")}createElement(t,e){const i=super.createElement(t,e);return super.setAttribute(i,this.contentAttr,""),i}}let jq=(()=>{class n extends gz{constructor(e){super(e)}supports(e){return!0}addEventListener(e,i,r){return e.addEventListener(i,r,!1),()=>this.removeEventListener(e,i,r)}removeEventListener(e,i,r){return e.removeEventListener(i,r)}static{this.\u0275fac=function(i){return new(i||n)(_i(sd))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();const Mz=["alt","control","meta","shift"],Vq={"\b":"Backspace","\t":"Tab","\x7f":"Delete","\x1b":"Escape",Del:"Delete",Esc:"Escape",Left:"ArrowLeft",Right:"ArrowRight",Up:"ArrowUp",Down:"ArrowDown",Menu:"ContextMenu",Scroll:"ScrollLock",Win:"OS"},Wq={alt:n=>n.altKey,control:n=>n.ctrlKey,meta:n=>n.metaKey,shift:n=>n.shiftKey};let Yq=(()=>{class n extends gz{constructor(e){super(e)}supports(e){return null!=n.parseEventName(e)}addEventListener(e,i,r){const s=n.parseEventName(i),o=n.eventCallback(s.fullKey,r,this.manager.getZone());return this.manager.getZone().runOutsideAngular(()=>Uw().onAndCancel(e,s.domEventName,o))}static parseEventName(e){const i=e.toLowerCase().split("."),r=i.shift();if(0===i.length||"keydown"!==r&&"keyup"!==r)return null;const s=n._normalizeKey(i.pop());let o="",a=i.indexOf("code");if(a>-1&&(i.splice(a,1),o="code."),Mz.forEach(h=>{const c=i.indexOf(h);c>-1&&(i.splice(c,1),o+=h+".")}),o+=s,0!=i.length||0===s.length)return null;const l={};return l.domEventName=r,l.fullKey=o,l}static matchEventFullKeyCode(e,i){let r=Vq[e.key]||e.key,s="";return i.indexOf("code.")>-1&&(r=e.code,s="code."),!(null==r||!r)&&(r=r.toLowerCase()," "===r?r="space":"."===r&&(r="dot"),Mz.forEach(o=>{o!==r&&(0,Wq[o])(e)&&(s+=o+".")}),s+=r,s===i)}static eventCallback(e,i,r){return s=>{n.matchEventFullKeyCode(s,e)&&r.runGuarded(()=>i(s))}}static _normalizeKey(e){return"esc"===e?"escape":e}static{this.\u0275fac=function(i){return new(i||n)(_i(sd))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();function wz(n){return{appProviders:[...Jq,...n?.providers??[]],platformProviders:$q}}const $q=[{provide:Su,useValue:"browser"},{provide:rL,useValue:function Gq(){nC.makeCurrent()},multi:!0},{provide:sd,useFactory:function qq(){return function wj(n){E1=n}(document),document},deps:[]}],Jq=[{provide:S1,useValue:"root"},{provide:nh,useFactory:function Xq(){return new nh},deps:[]},{provide:sC,useClass:jq,multi:!0,deps:[sd,Rr,Su]},{provide:sC,useClass:Yq,multi:!0,deps:[sd]},Sz,vz,pz,{provide:rN,useExisting:Sz},{provide:class oq{},useClass:kq,deps:[]},[]];var i$=0,dC=!1;function y0(n,t){var e=t;return e.unshift(void 0),new(Function.prototype.bind.apply(n,e))}function Y(n,t){for(var e=t,i=n.replace(/\[/g,".").replace(/\]/g,"").split("."),r=0;r"u"}function Ei(n){return n+"_"+i$++}function I0(n,t){return n===t||!(n===document||!n)&&I0(n.parentNode,t)}function Cg(n){try{throw new Error(n)}catch(t){throw new Error(t.message+"\n"+t.stack)}}function Re(n){var t=n+"";return t.match(/auto|cm|mm|in|px|pt|pc|%|em|ex|ch|rem|vw|vh|vmin|vmax/)?t:t+"px"}function ce(){return dC}var Eg,n,t,a$={latn:{_digits:"0123456789",_type:"numeric"}},Tz={decimal:".",group:",",percentSign:"%",plusSign:"+",minusSign:"-",infinity:"\u221e",nan:"NaN",exponential:"E"},Az=[0,1,2,3,4,5,6,7,8,9],Hr=function(){function n(){}return n.getMainObject=function(t,e){return Y(ce()?e:"main."+e,t)},n.getNumberingSystem=function(t){return Y("supplemental.numberingSystems",t)||this.numberingSystems},n.reverseObject=function(t,e){for(var r={},s=0,o=e||Object.keys(t);s13&&(p+=1,o-=12),o-=1,a=p-4716;var y=u-24e5,S=10631/30,b=u-1948084,M=Math.floor(b/10631);b-=10631*M;var w=Math.floor((b-.1335)/S),C=30*M+w;b-=Math.floor(w*S+.1335);var D=Math.floor((b+28.5001)/29.5);13===D&&(D=12);for(var A=b-Math.floor(29.5001*D-29),x=0;xy);x++);var P=x+16260,L=Math.floor((P-1)/12),O=L+1,N=P-12*L,T=y-t[x-1]+1;return(T+"").length>2&&(T=A,N=D,O=C),{year:O,month:N,date:T}},n.toGregorian=function i(r,s,o){var g=Math.floor(o+t[12*(r-1)+1+(s-1)-16260-1]-1+24e5+.5),v=Math.floor((g-1867216.25)/36524.25),y=1524+(v=g+1+v-Math.floor(v/4)),S=Math.floor((y-122.1)/365.25),b=Math.floor(365.25*S),M=Math.floor((y-b)/30.6001),w=y-b-Math.floor(30.6001*M),C=M-(M>13.5?13:1),D=S-(C>2.5?4716:4715);return D<=0&&C--,new Date(D+"/"+C+"/"+w)};var ut,c$=/\/MMMMM|MMMM|MMM|a|LLLL|LLL|EEEEE|EEEE|E|K|cccc|ccc|WW|W|G+|z+/gi,Lz="stand-alone",d$=["sun","mon","tue","wed","thu","fri","sat"],Nz={m:"getMinutes",h:"getHours",H:"getHours",s:"getSeconds",d:"getDate",f:"getMilliseconds"},Oz=function(){function n(){}return n.dateFormat=function(t,e,i){var r=this,s=ut.getDependables(i,t,e.calendar),o=Y("parserObject.numbers",s),a=s.dateObject,l={isIslamic:ut.islamicRegex.test(e.calendar)};ce()&&e.isServerRendered&&(e=ut.compareBlazorDateFormats(e,t));var h=e.format||ut.getResultantPattern(e.skeleton,s.dateObject,e.type,!1,ce()?t:"");if(l.dateSeperator=ce()?Y("dateSeperator",a):ut.getDateSeparator(s.dateObject),st(h))Cg("Format options or type given must be invalid");else{h=ut.ConvertDateToWeekFormat(h),ce()&&(h=h.replace(/tt/,"a")),l.pattern=h,l.numMapper=ce()?ze({},o):Hr.getNumberMapper(s.parserObject,Hr.getNumberingSystem(i));for(var d=0,u=h.match(c$)||[];d2?r+=e.month[""+u]:p=!0;break;case"E":case"c":r+=e.weekday[""+d$[t.getDay()]];break;case"H":case"h":case"m":case"s":case"d":case"f":if(p=!0,"d"===d)u=o.date;else if("f"===d){p=!1,g=!0;var y=(f=(f=t[""+Nz[""+d]]().toString()).substring(0,c)).length;if(c!==y){if(c>3)continue;for(var S=0;S0?1:0],o=Math.abs(t);return s.replace(/HH?|mm/g,function(a){var l=a.length,h=-1!==a.indexOf("H");return i.checkTwodigitNumber(Math.floor(h?o/60:o%60),l)})},n}(),kz={ms:"minimumSignificantDigits",ls:"maximumSignificantDigits",mf:"minimumFractionDigits",lf:"maximumFractionDigits"},tf=["infinity","nan","group","decimal","exponential"],Pz=function(){function n(){}return n.numberFormatter=function(t,e,i){var l,r=this,s=ze({},e),o={},a={},h=ut.getDependables(i,t,"",!0),c=h.numericObject;a.numberMapper=ce()?ze({},c):Hr.getNumberMapper(h.parserObject,Hr.getNumberingSystem(i),!0),a.currencySymbol=ce()?Y("currencySymbol",c):ut.getCurrencySymbol(h.numericObject,s.currency||Tg,e.altSymbol,e.ignoreCurrency),a.percentSymbol=ce()?Y("numberSymbols.percentSign",c):a.numberMapper.numberSymbols.percentSign,a.minusSymbol=ce()?Y("numberSymbols.minusSign",c):a.numberMapper.numberSymbols.minusSign;var d=a.numberMapper.numberSymbols;if(e.format&&!ut.formatRegex.test(e.format))o=ut.customFormat(e.format,a,h.numericObject),!st(s.useGrouping)&&s.useGrouping&&(s.useGrouping=o.pData.useGrouping);else{if(ze(s,ut.getProperNumericSkeleton(e.format||"N")),s.isCurrency="currency"===s.type,s.isPercent="percent"===s.type,ce()||(l=ut.getSymbolPattern(s.type,a.numberMapper.numberSystem,h.numericObject,s.isAccount)),s.groupOne=this.checkValueRange(s.maximumSignificantDigits,s.minimumSignificantDigits,!0),this.checkValueRange(s.maximumFractionDigits,s.minimumFractionDigits,!1,!0),st(s.fractionDigits)||(s.minimumFractionDigits=s.maximumFractionDigits=s.fractionDigits),st(s.useGrouping)&&(s.useGrouping=!0),s.isCurrency&&!ce()&&(l=l.replace(/\u00A4/g,ut.defaultCurrency)),ce())o.nData=ze({},{},Y(s.type+"nData",c)),o.pData=ze({},{},Y(s.type+"pData",c)),"currency"===s.type&&e.currency&&ut.replaceBlazorCurrency([o.pData,o.nData],a.currencySymbol,e.currency);else{var u=l.split(";");o.nData=ut.getFormatData(u[1]||"-"+u[0],!0,a.currencySymbol),o.pData=ut.getFormatData(u[0],!1,a.currencySymbol),s.useGrouping&&(s.groupSeparator=d[tf[2]],s.groupData=this.getGroupingDetails(u[0]))}if(st(s.minimumFractionDigits)&&(s.minimumFractionDigits=o.nData.minimumFraction),st(s.maximumFractionDigits)){var p=o.nData.maximumFraction;s.maximumFractionDigits=st(p)&&s.isPercent?0:p}var g=s.minimumFractionDigits,v=s.maximumFractionDigits;!st(g)&&!st(v)&&g>v&&(s.maximumFractionDigits=g)}return ze(o.nData,s),ze(o.pData,s),function(y){return isNaN(y)?d[tf[1]]:isFinite(y)?r.intNumberFormatter(y,o,a,e):d[tf[0]]}},n.getGroupingDetails=function(t){var e={},i=t.match(ut.negativeDataRegex);if(i&&i[4]){var r=i[4],s=r.lastIndexOf(",");if(-1!==s){var o=r.split(".")[0];e.primary=o.length-s-1;var a=r.lastIndexOf(",",s-1);-1!==a&&(e.secondary=s-1-a)}}return e},n.checkValueRange=function(t,e,i,r){var s=r?"f":"s",o=0,a=kz["l"+s],l=kz["m"+s];if(st(t)||(this.checkRange(t,a,r),o++),st(e)||(this.checkRange(e,l,r),o++),2===o){if(!(tr[1])&&Cg(e+"value must be within the range"+r[0]+"to"+r[1])},n.intNumberFormatter=function(t,e,i,r){var s;if(!st(e.nData.type)){t<0?(t*=-1,s=e.nData):s=0===t&&e.zeroData||e.pData;var o="";if(s.isPercent&&(t*=100),s.groupOne)o=this.processSignificantDigits(t,s.minimumSignificantDigits,s.maximumSignificantDigits);else if(o=this.processFraction(t,s.minimumFractionDigits,s.maximumFractionDigits,r),s.minimumIntegerDigits&&(o=this.processMinimumIntegers(o,s.minimumIntegerDigits)),i.isCustomFormat&&s.minimumFractionDigits=0&&"0"===l[parseInt(c.toString(),10)]&&c>=s.minimumFractionDigits;c--)l=l.slice(0,c);o=a[0]+"."+l}return"scientific"===s.type&&(o=(o=t.toExponential(s.maximumFractionDigits)).replace("e",i.numberMapper.numberSymbols[tf[4]])),o=o.replace(".",i.numberMapper.numberSymbols[tf[3]]),o="#,###,,;(#,###,,)"===s.format?this.customPivotFormat(parseInt(o,10)):o,s.useGrouping&&(o=this.groupNumbers(o,s.groupData.primary,s.groupSeparator||",",i.numberMapper.numberSymbols[tf[3]]||".",s.groupData.secondary)),o=Hr.convertValueParts(o,ut.latnParseRegex,i.numberMapper.mapper),"N/A"===s.nlead?s.nlead:"0"===o&&r&&"0"===r.format?o+s.nend:s.nlead+o+s.nend}},n.processSignificantDigits=function(t,e,i){var r=t+"";return r.lengthe;)c=l.slice(h-e,h)+(c.length?i+c:""),h-=e,o&&(e=s,o=!1);return a[0]=l.slice(0,h)+(c.length?i:"")+c,a.join(r)},n.processFraction=function(t,e,i,r){var s=(t+"").split(".")[1],o=s?s.length:0;if(e&&oi||0===i))return t.toFixed(i);var h=t+"";return"0"===h[0]&&r&&"###.00"===r.format&&(h=h.slice(1)),h},n.processMinimumIntegers=function(t,e){var i=t.split("."),r=i[0],s=r.length;if(s=5e5){var r=(t/=1e6).toString().split(".")[1];return r&&+r.substring(0,1)>=5?Math.ceil(t).toString():Math.floor(t).toString()}return""},n}(),Dg=(new RegExp("^([^0-9]*)(([0-9,]*[0-9]+)(.[0-9]+)?)([Ee][+-]?[0-9]+)?([^0-9]*)$"),function(){function n(t){this.ranArray=[],this.boundedEvents={},!m(t)&&(this.context=t)}return n.prototype.on=function(t,e,i,r){if(!m(e)){var s=i||this.context;if(this.notExist(t))return void(this.boundedEvents[""+t]=[{handler:e,context:s,id:r}]);m(r)?this.isHandlerPresent(this.boundedEvents[""+t],e)||this.boundedEvents[""+t].push({handler:e,context:s}):-1===this.ranArray.indexOf(r)&&(this.ranArray.push(r),this.boundedEvents[""+t].push({handler:e,context:s,id:r}))}},n.prototype.off=function(t,e,i){if(!this.notExist(t)){var r=Y(t,this.boundedEvents);if(e){for(var s=0;s1&&(U.fractionDigits=parseInt(z[2],10)),U}function p(T,z,U,B){var j=B?{}:{nlead:"",nend:""},Q=T.match(n.customRegex);if(Q){B||(j.nlead=g(Q[1],U),j.nend=g(Q[10],U),j.groupPattern=Q[4]);var oe=Q[7];if(oe&&z){var ue=oe.match(t);j.minimumFraction=m(ue)?0:ue.length,j.maximumFraction=oe.length-1}}return j}function g(T,z){return T?(T=T.replace(n.defaultCurrency,z),""===z?T.trim():T):""}function v(T,z,U,B){return B?"$":Y("currencies."+z+(U?"."+U:".symbol"),T)||Y("currencies."+z+".symbol-alt-narrow",T)||"$"}function S(T,z,U){var B={type:"decimal",minimumFractionDigits:0,maximumFractionDigits:0},j=T.match(n.customRegex);if(m(j)||""===j[5]&&"N/A"!==T)return B.type=void 0,B;B.nlead=j[1],B.nend=j[10];var Q=j[6],oe=!!Q.match(/ $/g),ue=-1!==Q.replace(/ $/g,"").indexOf(" ");B.useGrouping=-1!==Q.indexOf(",")||ue,Q=Q.replace(/,/g,"");var fe=j[7];if(-1!==Q.indexOf("0")&&(B.minimumIntegerDigits=Q.length-Q.indexOf("0")),m(fe)||(B.minimumFractionDigits=fe.lastIndexOf("0"),B.maximumFractionDigits=fe.lastIndexOf("#"),-1===B.minimumFractionDigits&&(B.minimumFractionDigits=0),(-1===B.maximumFractionDigits||B.maximumFractionDigitsQ.lastIndexOf("'"))){B[""+a[parseInt(j.toString(),10)]]=Q.substr(0,oe)+U+Q.substr(oe+1),B[""+a[""+z]]=!0,B.type=B.isCurrency?"currency":"percent";break}}return B}function C(T,z){if(-1!==T.indexOf(",")){var U=T.split(",");T=U[0]+Y("numberMapper.numberSymbols.group",z)+U[1].replace(".",Y("numberMapper.numberSymbols.decimal",z))}else T=T.replace(".",Y("numberMapper.numberSymbols.decimal",z));return T}function A(T,z,U){T+=".";for(var B=0;B0;Q-=3)T=","+U[Q-2]+U[Q-1]+U[parseInt(Q.toString(),10)]+T;return T=T.slice(1),z[1]?T+"."+z[1]:T}n.dateParseRegex=/([a-z])\1*|'([^']|'')+'|''|./gi,n.basicPatterns=["short","medium","long","full"],n.defaultObject={dates:{calendars:{gregorian:{months:{"stand-alone":{abbreviated:{1:"Jan",2:"Feb",3:"Mar",4:"Apr",5:"May",6:"Jun",7:"Jul",8:"Aug",9:"Sep",10:"Oct",11:"Nov",12:"Dec"},narrow:{1:"J",2:"F",3:"M",4:"A",5:"M",6:"J",7:"J",8:"A",9:"S",10:"O",11:"N",12:"D"},wide:{1:"January",2:"February",3:"March",4:"April",5:"May",6:"June",7:"July",8:"August",9:"September",10:"October",11:"November",12:"December"}}},days:{"stand-alone":{abbreviated:{sun:"Sun",mon:"Mon",tue:"Tue",wed:"Wed",thu:"Thu",fri:"Fri",sat:"Sat"},narrow:{sun:"S",mon:"M",tue:"T",wed:"W",thu:"T",fri:"F",sat:"S"},short:{sun:"Su",mon:"Mo",tue:"Tu",wed:"We",thu:"Th",fri:"Fr",sat:"Sa"},wide:{sun:"Sunday",mon:"Monday",tue:"Tuesday",wed:"Wednesday",thu:"Thursday",fri:"Friday",sat:"Saturday"}}},dayPeriods:{format:{wide:{am:"AM",pm:"PM"}}},eras:{eraNames:{0:"Before Christ","0-alt-variant":"Before Common Era",1:"Anno Domini","1-alt-variant":"Common Era"},eraAbbr:{0:"BC","0-alt-variant":"BCE",1:"AD","1-alt-variant":"CE"},eraNarrow:{0:"B","0-alt-variant":"BCE",1:"A","1-alt-variant":"CE"}},dateFormats:{full:"EEEE, MMMM d, y",long:"MMMM d, y",medium:"MMM d, y",short:"M/d/yy"},timeFormats:{full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},dateTimeFormats:{full:"{1} 'at' {0}",long:"{1} 'at' {0}",medium:"{1}, {0}",short:"{1}, {0}",availableFormats:{d:"d",E:"ccc",Ed:"d E",Ehm:"E h:mm a",EHm:"E HH:mm",Ehms:"E h:mm:ss a",EHms:"E HH:mm:ss",Gy:"y G",GyMMM:"MMM y G",GyMMMd:"MMM d, y G",GyMMMEd:"E, MMM d, y G",h:"h a",H:"HH",hm:"h:mm a",Hm:"HH:mm",hms:"h:mm:ss a",Hms:"HH:mm:ss",hmsv:"h:mm:ss a v",Hmsv:"HH:mm:ss v",hmv:"h:mm a v",Hmv:"HH:mm v",M:"L",Md:"M/d",MEd:"E, M/d",MMM:"LLL",MMMd:"MMM d",MMMEd:"E, MMM d",MMMMd:"MMMM d",ms:"mm:ss",y:"y",yM:"M/y",yMd:"M/d/y",yMEd:"E, M/d/y",yMMM:"MMM y",yMMMd:"MMM d, y",yMMMEd:"E, MMM d, y",yMMMM:"MMMM y"}}},islamic:{months:{"stand-alone":{abbreviated:{1:"Muh.",2:"Saf.",3:"Rab. I",4:"Rab. II",5:"Jum. I",6:"Jum. II",7:"Raj.",8:"Sha.",9:"Ram.",10:"Shaw.",11:"Dhu\u02bbl-Q.",12:"Dhu\u02bbl-H."},narrow:{1:"1",2:"2",3:"3",4:"4",5:"5",6:"6",7:"7",8:"8",9:"9",10:"10",11:"11",12:"12"},wide:{1:"Muharram",2:"Safar",3:"Rabi\u02bb I",4:"Rabi\u02bb II",5:"Jumada I",6:"Jumada II",7:"Rajab",8:"Sha\u02bbban",9:"Ramadan",10:"Shawwal",11:"Dhu\u02bbl-Qi\u02bbdah",12:"Dhu\u02bbl-Hijjah"}}},days:{"stand-alone":{abbreviated:{sun:"Sun",mon:"Mon",tue:"Tue",wed:"Wed",thu:"Thu",fri:"Fri",sat:"Sat"},narrow:{sun:"S",mon:"M",tue:"T",wed:"W",thu:"T",fri:"F",sat:"S"},short:{sun:"Su",mon:"Mo",tue:"Tu",wed:"We",thu:"Th",fri:"Fr",sat:"Sa"},wide:{sun:"Sunday",mon:"Monday",tue:"Tuesday",wed:"Wednesday",thu:"Thursday",fri:"Friday",sat:"Saturday"}}},dayPeriods:{format:{wide:{am:"AM",pm:"PM"}}},eras:{eraNames:{0:"AH"},eraAbbr:{0:"AH"},eraNarrow:{0:"AH"}},dateFormats:{full:"EEEE, MMMM d, y G",long:"MMMM d, y G",medium:"MMM d, y G",short:"M/d/y GGGGG"},timeFormats:{full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},dateTimeFormats:{full:"{1} 'at' {0}",long:"{1} 'at' {0}",medium:"{1}, {0}",short:"{1}, {0}",availableFormats:{d:"d",E:"ccc",Ed:"d E",Ehm:"E h:mm a",EHm:"E HH:mm",Ehms:"E h:mm:ss a",EHms:"E HH:mm:ss",Gy:"y G",GyMMM:"MMM y G",GyMMMd:"MMM d, y G",GyMMMEd:"E, MMM d, y G",h:"h a",H:"HH",hm:"h:mm a",Hm:"HH:mm",hms:"h:mm:ss a",Hms:"HH:mm:ss",M:"L",Md:"M/d",MEd:"E, M/d",MMM:"LLL",MMMd:"MMM d",MMMEd:"E, MMM d",MMMMd:"MMMM d",ms:"mm:ss",y:"y G",yyyy:"y G",yyyyM:"M/y GGGGG",yyyyMd:"M/d/y GGGGG",yyyyMEd:"E, M/d/y GGGGG",yyyyMMM:"MMM y G",yyyyMMMd:"MMM d, y G",yyyyMMMEd:"E, MMM d, y G",yyyyMMMM:"MMMM y G",yyyyQQQ:"QQQ y G",yyyyQQQQ:"QQQQ y G"}}}},timeZoneNames:{hourFormat:"+HH:mm;-HH:mm",gmtFormat:"GMT{0}",gmtZeroFormat:"GMT"}},numbers:{currencies:{USD:{displayName:"US Dollar",symbol:"$","symbol-alt-narrow":"$"},EUR:{displayName:"Euro",symbol:"\u20ac","symbol-alt-narrow":"\u20ac"},GBP:{displayName:"British Pound","symbol-alt-narrow":"\xa3"}},defaultNumberingSystem:"latn",minimumGroupingDigits:"1","symbols-numberSystem-latn":{decimal:".",group:",",list:";",percentSign:"%",plusSign:"+",minusSign:"-",exponential:"E",superscriptingExponent:"\xd7",perMille:"\u2030",infinity:"\u221e",nan:"NaN",timeSeparator:":"},"decimalFormats-numberSystem-latn":{standard:"#,##0.###"},"percentFormats-numberSystem-latn":{standard:"#,##0%"},"currencyFormats-numberSystem-latn":{standard:"\xa4#,##0.00",accounting:"\xa4#,##0.00;(\xa4#,##0.00)"},"scientificFormats-numberSystem-latn":{standard:"#E0"}}},n.blazorDefaultObject={numbers:{mapper:{0:"0",1:"1",2:"2",3:"3",4:"4",5:"5",6:"6",7:"7",8:"8",9:"9"},mapperDigits:"0123456789",numberSymbols:{decimal:".",group:",",plusSign:"+",minusSign:"-",percentSign:"%",nan:"NaN",timeSeparator:":",infinity:"\u221e"},timeSeparator:":",currencySymbol:"$",currencypData:{nlead:"$",nend:"",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},percentpData:{nlead:"",nend:"%",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},percentnData:{nlead:"-",nend:"%",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},currencynData:{nlead:"($",nend:")",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},decimalnData:{nlead:"-",nend:"",groupData:{primary:3},maximumFraction:2,minimumFraction:2},decimalpData:{nlead:"",nend:"",groupData:{primary:3},maximumFraction:2,minimumFraction:2}},dates:{dayPeriods:{am:"AM",pm:"PM"},dateSeperator:"/",days:{abbreviated:{sun:"Sun",mon:"Mon",tue:"Tue",wed:"Wed",thu:"Thu",fri:"Fri",sat:"Sat"},short:{sun:"Su",mon:"Mo",tue:"Tu",wed:"We",thu:"Th",fri:"Fr",sat:"Sa"},wide:{sun:"Sunday",mon:"Monday",tue:"Tuesday",wed:"Wednesday",thu:"Thursday",fri:"Friday",sat:"Saturday"}},months:{abbreviated:{1:"Jan",2:"Feb",3:"Mar",4:"Apr",5:"May",6:"Jun",7:"Jul",8:"Aug",9:"Sep",10:"Oct",11:"Nov",12:"Dec"},wide:{1:"January",2:"February",3:"March",4:"April",5:"May",6:"June",7:"July",8:"August",9:"September",10:"October",11:"November",12:"December"}},eras:{1:"AD"}}},n.monthIndex={3:"abbreviated",4:"wide",5:"narrow",1:"abbreviated"},n.month="months",n.days="days",n.patternMatcher={C:"currency",P:"percent",N:"decimal",A:"currency",E:"scientific"},n.getResultantPattern=l,n.getDependables=h,n.getSymbolPattern=c,n.ConvertDateToWeekFormat=d,n.compareBlazorDateFormats=u,n.getProperNumericSkeleton=f,n.getFormatData=p,n.changeCurrencySymbol=g,n.getCurrencySymbol=v,n.customFormat=function y(T,z,U){for(var B={},j=T.split(";"),Q=["pData","nData","zeroData"],oe=0;oe1,fe.nData=ce()?Y(De.type+"nData",oe):p(ot[1]||"-"+ot[0],!0,Ie),fe.pData=ce()?Y(De.type+"pData",oe):p(ot[0],!1,Ie),!Me[2]&&!z.minimumFractionDigits&&!z.maximumFractionDigits&&(ue=p(Ve.split(";")[0],!0,"",!0).minimumFraction)}if(n.formatRegex.test(z.format)||!z.format){if(ze(Q,f(z.format||"N")),Q.custom=!1,$e="###0",(Q.fractionDigits||z.minimumFractionDigits||z.maximumFractionDigits||ue)&&(Q.fractionDigits&&(z.minimumFractionDigits=z.maximumFractionDigits=Q.fractionDigits),$e=A($e,ue||Q.fractionDigits||z.minimumFractionDigits||0,z.maximumFractionDigits||0)),z.minimumIntegerDigits&&($e=x($e,z.minimumIntegerDigits)),z.useGrouping&&($e=P($e)),"currency"===Q.type||Q.type&&ce()){ce()&&"currency"!==Q.type&&(fe.pData=Y(Q.type+"pData",oe),fe.nData=Y(Q.type+"nData",oe));var cr=$e;$e=fe.pData.nlead+cr+fe.pData.nend,(fe.hasNegativePattern||ce())&&($e+=";"+fe.nData.nlead+cr+fe.nData.nend)}"percent"===Q.type&&!ce()&&($e+=" %")}else $e=z.format.replace(/'/g,'"');return Object.keys(xe).length>0&&($e=B?$e:C($e,xe)),$e},n.fractionDigitsPattern=A,n.minimumIntegerPattern=x,n.groupingPattern=P,n.getWeekData=function L(T,z){var U="sun",B=Y("supplemental.weekData.firstDay",z),j=T;return/en-/.test(j)&&(j=j.slice(3)),j=j.slice(0,2).toUpperCase()+j.substr(2),B&&(U=B[""+j]||B[j.slice(0,2)]||"sun"),o[""+U]},n.replaceBlazorCurrency=function O(T,z,U){var B=function h$(n){return Y(n||"",l$)}(U);if(z!==B)for(var j=0,Q=T;j=0?U:U+7;var j=Math.floor((T.getTime()-z.getTime()-6e4*(T.getTimezoneOffset()-z.getTimezoneOffset()))/864e5)+1;if(U<4){if((B=Math.floor((j+U-1)/7)+1)>52){var oe=new Date(T.getFullYear()+1,0,1).getDay();B=(oe=oe>=0?oe:oe+7)<4?1:53}}else B=Math.floor((j+U-1)/7);return B}}(ut||(ut={}));var rf=function(){function n(t,e,i){this.type="GET",this.emitError=!0,"string"==typeof t?(this.url=t,this.type=m(e)?this.type:e.toUpperCase(),this.contentType=i):La(t)&&Object.keys(t).length>0&&kn(this,t),this.contentType=m(this.contentType)?"application/json; charset=utf-8":this.contentType}return n.prototype.send=function(t){var e=this,i={"application/json":"json","multipart/form-data":"formData","application/octet-stream":"blob","application/x-www-form-urlencoded":"formData"};try{m(this.fetchRequest)&&"GET"===this.type?this.fetchRequest=new Request(this.url,{method:this.type}):m(this.fetchRequest)&&(this.data=m(t)?this.data:t,this.fetchRequest=new Request(this.url,{method:this.type,headers:{"Content-Type":this.contentType},body:this.data}));var r={cancel:!1,fetchRequest:this.fetchRequest};return this.triggerEvent(this.beforeSend,r),r.cancel?null:(this.fetchResponse=fetch(this.fetchRequest),this.fetchResponse.then(function(s){if(e.triggerEvent(e.onLoad,s),!s.ok)throw s;for(var o="text",a=0,l=Object.keys(i);a-1},n.getValue=function(t,e){var i=typeof window<"u"?window.browserDetails:{};return typeof navigator<"u"&&"MacIntel"===navigator.platform&&navigator.maxTouchPoints>1&&!0===n.isTouch&&!pC.CHROME.test(navigator.userAgent)&&(i.isIos=!0,i.isDevice=!0,i.isTouch=!0,i.isPointer=!0,i.isPointer="pointerEnabled"in window.navigator),typeof window<"u"&&window.Capacitor&&"ios"===window.Capacitor.getPlatform()&&(i.isPointer=!1),typeof i[""+t]>"u"?i[""+t]=e.test(n.userAgent):i[""+t]},Object.defineProperty(n,"userAgent",{get:function(){return n.uA},set:function(t){n.uA=t,window.browserDetails={}},enumerable:!0,configurable:!0}),Object.defineProperty(n,"info",{get:function(){return st(window.browserDetails.info)?window.browserDetails.info=n.extractBrowserDetail():window.browserDetails.info},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isIE",{get:function(){return n.getValue("isIE",E$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isTouch",{get:function(){return st(window.browserDetails.isTouch)?window.browserDetails.isTouch="ontouchstart"in window.navigator||window&&window.navigator&&window.navigator.maxTouchPoints>0||"ontouchstart"in window:window.browserDetails.isTouch},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isPointer",{get:function(){return st(window.browserDetails.isPointer)?window.browserDetails.isPointer="pointerEnabled"in window.navigator:window.browserDetails.isPointer},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isMSPointer",{get:function(){return st(window.browserDetails.isMSPointer)?window.browserDetails.isMSPointer="msPointerEnabled"in window.navigator:window.browserDetails.isMSPointer},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isDevice",{get:function(){return n.getValue("isDevice",C$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isIos",{get:function(){return n.getValue("isIos",x$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isIos7",{get:function(){return n.getValue("isIos7",T$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isAndroid",{get:function(){return n.getValue("isAndroid",A$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isWebView",{get:function(){return st(window.browserDetails.isWebView)&&(window.browserDetails.isWebView=!(st(window.cordova)&&st(window.PhoneGap)&&st(window.phonegap)&&"object"!==window.forge)),window.browserDetails.isWebView},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isWindows",{get:function(){return n.getValue("isWindows",L$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"touchStartEvent",{get:function(){return st(window.browserDetails.touchStartEvent)?window.browserDetails.touchStartEvent=n.getTouchStartEvent():window.browserDetails.touchStartEvent},enumerable:!0,configurable:!0}),Object.defineProperty(n,"touchMoveEvent",{get:function(){return st(window.browserDetails.touchMoveEvent)?window.browserDetails.touchMoveEvent=n.getTouchMoveEvent():window.browserDetails.touchMoveEvent},enumerable:!0,configurable:!0}),Object.defineProperty(n,"touchEndEvent",{get:function(){return st(window.browserDetails.touchEndEvent)?window.browserDetails.touchEndEvent=n.getTouchEndEvent():window.browserDetails.touchEndEvent},enumerable:!0,configurable:!0}),Object.defineProperty(n,"touchCancelEvent",{get:function(){return st(window.browserDetails.touchCancelEvent)?window.browserDetails.touchCancelEvent=n.getTouchCancelEvent():window.browserDetails.touchCancelEvent},enumerable:!0,configurable:!0}),n.uA=typeof navigator<"u"?navigator.userAgent:"",n}(),E=function(){function n(){}return n.addOrGetEventData=function(t){return"__eventList"in t?t.__eventList.events:(t.__eventList={},t.__eventList.events=[])},n.add=function(t,e,i,r,s){var a,o=n.addOrGetEventData(t);a=s?function n$(n,t){var e;return function(){for(var i=this,r=[],s=0;s"u"||(e.innerHTML=t.innerHTML?t.innerHTML:"",void 0!==t.className&&(e.className=t.className),void 0!==t.id&&(e.id=t.id),void 0!==t.styles&&e.setAttribute("style",t.styles),void 0!==t.attrs&&Fe(e,t.attrs)),e}function V(n,t){for(var e=Uz(t),i=RegExp,r=0,s=n;r0}function gl(n,t,e){for(var i=document.createDocumentFragment(),r=0,s=n;r0;)i.appendChild(n[0]);else for(var r=0,s=n;r-1&&!r[parseInt(s.toString(),10)].match(/\[.*\]/)){var o=r[parseInt(s.toString(),10)].split("#");if(o[1].match(/^\d/)||o[1].match(t)){var a=r[parseInt(s.toString(),10)].split(".");a[0]=a[0].replace(/#/,"[id='")+"']",r[parseInt(s.toString(),10)]=a.join(".")}}e[parseInt(i.toString(),10)]=r.join(" ")}return e.join(",")}return n}function J(n,t){var e=n;if("function"==typeof e.closest)return e.closest(t);for(;e&&1===e.nodeType;){if(gC(e,t))return e;e=e.parentNode}return null}function je(n,t){void 0!==t&&Object.keys(t).forEach(function(e){n.style[""+e]=t[""+e]})}function gC(n,t){var e=n.matches||n.msMatchesSelector||n.webkitMatchesSelector;return e?e.call(n,t):-1!==[].indexOf.call(document.querySelectorAll(t),n)}var k$=new RegExp("]"),dh=function(){function n(t,e){this.isRendered=!1,this.isComplexArraySetter=!1,this.isServerRendered=!1,this.allowServerDataBinding=!0,this.isProtectedOnChange=!0,this.properties={},this.changedProperties={},this.oldProperties={},this.bulkChanges={},this.refreshing=!1,this.ignoreCollectionWatch=!1,this.finalUpdate=function(){},this.childChangedProperties={},this.modelObserver=new Dg(this),st(e)||(this.element="string"==typeof e?document.querySelector(e):e,m(this.element)||(this.isProtectedOnChange=!1,this.addInstance())),st(t)||this.setProperties(t,!0),this.isDestroyed=!1}return n.prototype.setProperties=function(t,e){var i=this.isProtectedOnChange;this.isProtectedOnChange=!!e,kn(this,t),!0!==e?(kn(this.changedProperties,t),this.dataBind()):ce()&&this.isRendered&&this.serverDataBind(t),this.finalUpdate(),this.changedProperties={},this.oldProperties={},this.isProtectedOnChange=i},n.callChildDataBind=function(t,e){for(var r=0,s=Object.keys(t);r=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Hs=function(n){function t(i){var r=n.call(this,i,void 0)||this;return r.easing={ease:"cubic-bezier(0.250, 0.100, 0.250, 1.000)",linear:"cubic-bezier(0.250, 0.250, 0.750, 0.750)",easeIn:"cubic-bezier(0.420, 0.000, 1.000, 1.000)",easeOut:"cubic-bezier(0.000, 0.000, 0.580, 1.000)",easeInOut:"cubic-bezier(0.420, 0.000, 0.580, 1.000)",elasticInOut:"cubic-bezier(0.5,-0.58,0.38,1.81)",elasticIn:"cubic-bezier(0.17,0.67,0.59,1.81)",elasticOut:"cubic-bezier(0.7,-0.75,0.99,1.01)"},r}var e;return W$(t,n),e=t,t.prototype.animate=function(i,r){var s=this.getModel(r=r||{});if("string"==typeof i)for(var a=0,l=Array.prototype.slice.call(we(i,document));a0?r-1:0,i+=e=-1!==e?"-"+e:"-"+r}return this.controlParent!==this.parentObj&&(i=this.parentObj.getParentKey()+"."+this.propName+e),i},n}(),X$=["grid","pivotview","treegrid","spreadsheet","rangeNavigator","DocumentEditor","listbox","inplaceeditor","PdfViewer","richtexteditor","DashboardLayout","chart","stockChart","circulargauge","diagram","heatmap","lineargauge","maps","slider","smithchart","barcode","sparkline","treemap","bulletChart","kanban","daterangepicker","schedule","gantt","signature","query-builder","drop-down-tree","carousel","filemanager","uploader","accordion","tab","treeview"],Kz=[115,121,110,99,102,117,115,105,111,110,46,105,115,76,105,99,86,97,108,105,100,97,116,101,100],eR=function(){function n(t){this.isValidated=!1,this.isLicensed=!0,this.version="27",this.platform=/JavaScript|ASPNET|ASPNETCORE|ASPNETMVC|FileFormats|essentialstudio/i,this.errors={noLicense:"This application was built using a trial version of Syncfusion Essential Studio. To remove the license validation message permanently, a valid license key must be included.",trailExpired:"This application was built using a trial version of Syncfusion Essential Studio. To remove the license validation message permanently, a valid license key must be included.",versionMismatched:"The included Syncfusion license key is invalid.",platformMismatched:"The included Syncfusion license key is invalid.",invalidKey:"The included Syncfusion license key is invalid."},this.manager=function(){var e=null;return{setKey:function i(s){e=s},getKey:function r(){return e}}}(),this.npxManager=function(){return{getKey:function i(){return"npxKeyReplace"}}}(),this.manager.setKey(t)}return n.prototype.validate=function(){if(!this.isValidated&&ef&&!Y(C0(Kz),ef)&&!Y("Blazor",ef)){var i=void 0,r=void 0;if(this.manager&&this.manager.getKey()||this.npxManager&&"npxKeyReplace"!==this.npxManager.getKey()){var s=this.getInfoFromKey();if(s&&s.length)for(var o=0,a=s;o"+i+' Claim your FREE account\n
have a Syncfusion account? Sign In
\n
\n ';if(typeof document<"u"&&!m(document)){var t=Si("div",{innerHTML:n});document.body.appendChild(t)}}(),nR=!0),this.render(),this.mount?this.accessMount():this.trigger("created")}},t.prototype.renderComplete=function(e){ce()&&window.sfBlazor.renderComplete(this.element,e),this.isRendered=!0},t.prototype.dataBind=function(){this.injectModules(),n.prototype.dataBind.call(this)},t.prototype.on=function(e,i,r){if("string"==typeof e)this.localObserver.on(e,i,r);else for(var s=0,o=e;s=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},K$={left:0,top:0,bottom:0,right:0},IC={isDragged:!1},eZ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return sR(t,n),vr([I(0)],t.prototype,"left",void 0),vr([I(0)],t.prototype,"top",void 0),t}(Ee),of=function(n){function t(i,r){var s=n.call(this,r,i)||this;return s.dragLimit=e.getDefaultPosition(),s.borderWidth=e.getDefaultPosition(),s.padding=e.getDefaultPosition(),s.diffX=0,s.prevLeft=0,s.prevTop=0,s.dragProcessStarted=!1,s.eleTop=0,s.tapHoldTimer=0,s.externalInitialize=!1,s.diffY=0,s.parentScrollX=0,s.parentScrollY=0,s.droppables={},s.bind(),s}var e;return sR(t,n),e=t,t.prototype.bind=function(){this.toggleEvents(),X.isIE&&V([this.element],"e-block-touch"),this.droppables[this.scope]={}},t.getDefaultPosition=function(){return ze({},K$)},t.prototype.toggleEvents=function(i){var r;st(this.handle)||(r=_(this.handle,this.element));var s=this.enableTapHold&&X.isDevice&&X.isTouch?this.mobileInitialize:this.initialize;i?E.remove(r||this.element,X.isSafari()?"touchstart":X.touchStartEvent,s):E.add(r||this.element,X.isSafari()?"touchstart":X.touchStartEvent,s,this)},t.prototype.mobileInitialize=function(i){var r=this,s=i.currentTarget;this.tapHoldTimer=setTimeout(function(){r.externalInitialize=!0,r.removeTapholdTimer(),r.initialize(i,s)},this.tapHoldThreshold),E.add(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.removeTapholdTimer,this),E.add(document,X.isSafari()?"touchend":X.touchEndEvent,this.removeTapholdTimer,this)},t.prototype.removeTapholdTimer=function(){clearTimeout(this.tapHoldTimer),E.remove(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.removeTapholdTimer),E.remove(document,X.isSafari()?"touchend":X.touchEndEvent,this.removeTapholdTimer)},t.prototype.getScrollableParent=function(i,r){return m(i)?null:i[{vertical:"scrollHeight",horizontal:"scrollWidth"}[""+r]]>i[{vertical:"clientHeight",horizontal:"clientWidth"}[""+r]]&&("vertical"===r?i.scrollTop>0:i.scrollLeft>0)?("vertical"===r?(this.parentScrollY=this.parentScrollY+(0===this.parentScrollY?i.scrollTop:i.scrollTop-this.parentScrollY),this.tempScrollHeight=i.scrollHeight):(this.parentScrollX=this.parentScrollX+(0===this.parentScrollX?i.scrollLeft:i.scrollLeft-this.parentScrollX),this.tempScrollWidth=i.scrollWidth),m(i)?i:this.getScrollableParent(i.parentNode,r)):this.getScrollableParent(i.parentNode,r)},t.prototype.getScrollableValues=function(){this.parentScrollX=0,this.parentScrollY=0,this.element.classList.contains("e-dialog")&&this.element.classList.contains("e-dlg-modal"),this.getScrollableParent(this.element.parentNode,"vertical"),this.getScrollableParent(this.element.parentNode,"horizontal")},t.prototype.initialize=function(i,r){if(this.currentStateTarget=i.target,!this.isDragStarted()){if(this.isDragStarted(!0),this.externalInitialize=!1,this.target=i.currentTarget||r,this.dragProcessStarted=!1,this.abort){var s=this.abort;"string"==typeof s&&(s=[s]);for(var o=0;o=this.distance||this.externalInitialize){var f=this.getHelperElement(i);if(!f||m(f))return;r&&i.preventDefault();var p=this.helperElement=f;if(this.parentClientRect=this.calculateParentPosition(p.offsetParent),this.dragStart){var v={event:i,element:l,target:this.getProperTargetElement(i),bindEvents:ce()?this.bindDragEvents.bind(this):null,dragElement:p};this.trigger("dragStart",v)}this.dragArea?this.setDragArea():(this.dragLimit={left:0,right:0,bottom:0,top:0},this.borderWidth={top:0,left:0}),o={left:this.position.left-this.parentClientRect.left,top:this.position.top-this.parentClientRect.top},this.clone&&!this.enableTailMode&&(this.diffX=this.position.left-this.offset.left,this.diffY=this.position.top-this.offset.top),this.getScrollableValues();var y=getComputedStyle(l),S=parseFloat(y.marginTop);this.clone&&0!==S&&(o.top+=S),this.eleTop=isNaN(parseFloat(y.top))?0:parseFloat(y.top)-this.offset.top,this.enableScrollHandler&&!this.clone&&(o.top-=this.parentScrollY,o.left-=this.parentScrollX);var b=this.getProcessedPositionValue({top:o.top-this.diffY+"px",left:o.left-this.diffX+"px"});this.dragArea&&"string"!=typeof this.dragArea&&this.dragArea.classList.contains("e-kanban-content")&&"relative"===this.dragArea.style.position&&(o.top+=this.dragArea.scrollTop),this.dragElePosition={top:o.top,left:o.left},je(p,this.getDragPosition({position:"absolute",left:b.left,top:b.top})),E.remove(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.intDragStart),E.remove(document,X.isSafari()?"touchend":X.touchEndEvent,this.intDestroy),ce()||this.bindDragEvents(p)}}},t.prototype.bindDragEvents=function(i){Tr(i)?(E.add(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.intDrag,this),E.add(document,X.isSafari()?"touchend":X.touchEndEvent,this.intDragStop,this),this.setGlobalDroppables(!1,this.element,i)):(this.toggleEvents(),document.body.classList.remove("e-prevent-select"))},t.prototype.elementInViewport=function(i){for(this.top=i.offsetTop,this.left=i.offsetLeft,this.width=i.offsetWidth,this.height=i.offsetHeight;i.offsetParent;)this.top+=(i=i.offsetParent).offsetTop,this.left+=i.offsetLeft;return this.top>=window.pageYOffset&&this.left>=window.pageXOffset&&this.top+this.height<=window.pageYOffset+window.innerHeight&&this.left+this.width<=window.pageXOffset+window.innerWidth},t.prototype.getProcessedPositionValue=function(i){return this.queryPositionInfo?this.queryPositionInfo(i):i},t.prototype.calculateParentPosition=function(i){if(m(i))return{left:0,top:0};var r=i.getBoundingClientRect(),s=getComputedStyle(i);return{left:r.left+window.pageXOffset-parseInt(s.marginLeft,10),top:r.top+window.pageYOffset-parseInt(s.marginTop,10)}},t.prototype.intDrag=function(i){if(st(i.changedTouches)||1===i.changedTouches.length){var r,s;this.clone&&i.changedTouches&&X.isDevice&&X.isTouch&&i.preventDefault(),this.position=this.getMousePosition(i,this.isDragScroll);var o=this.getDocumentWidthHeight("Height");oy&&y>0?this.dragLimit.left:this.dragLimit.right+window.pageXOffset0?y-(y-this.dragLimit.right)+window.pageXOffset-M:y<0?this.dragLimit.left:y}if(this.pageY!==v||this.skipDistanceCheck){var w=d.offsetHeight+(parseFloat(b.marginTop)+parseFloat(b.marginBottom));s=this.dragLimit.top>S&&S>0?this.dragLimit.top:this.dragLimit.bottom+window.pageYOffset0?S-(S-this.dragLimit.bottom)+window.pageYOffset-w:S<0?this.dragLimit.top:S}}else r=y,s=S;var A,x,C=f+this.borderWidth.top,D=u+this.borderWidth.left;if(this.dragProcessStarted&&(m(s)&&(s=this.prevTop),m(r)&&(r=this.prevLeft)),this.helperElement.classList.contains("e-treeview"))this.dragArea?(this.dragLimit.top=this.clone?this.dragLimit.top:0,A=s-C<0?this.dragLimit.top:s-this.borderWidth.top,x=r-D<0?this.dragLimit.left:r-this.borderWidth.left):(A=s-this.borderWidth.top,x=r-this.borderWidth.left);else if(this.dragArea){var P=this.helperElement.classList.contains("e-dialog");this.dragLimit.top=this.clone?this.dragLimit.top:0,A=s-C<0?this.dragLimit.top:s-C,x=r-D<0?P?r-(D-this.borderWidth.left):this.dragElePosition.left:r-D}else A=s-C,x=r-D;var L=parseFloat(getComputedStyle(this.element).marginTop);if(L>0&&(this.clone&&(A+=L,S<0&&(L+S>=0?A=L+S:A-=L),this.dragArea&&(A=this.dragLimit.bottom=0){var O=this.dragLimit.top+S-C;O+L+C<0?A-=L+C:A=O}else A-=L+C;this.dragArea&&this.helperElement.classList.contains("e-treeview")&&(A=A+(w=d.offsetHeight+(parseFloat(b.marginTop)+parseFloat(b.marginBottom)))>this.dragLimit.bottom?this.dragLimit.bottom-w:A),this.enableScrollHandler&&!this.clone&&(A-=this.parentScrollY,x-=this.parentScrollX),this.dragArea&&"string"!=typeof this.dragArea&&this.dragArea.classList.contains("e-kanban-content")&&"relative"===this.dragArea.style.position&&(A+=this.dragArea.scrollTop);var N=this.getProcessedPositionValue({top:A+"px",left:x+"px"});this.isPreventScroll&&(N=this.getProcessedPositionValue({top:this.position.top-this.parentClientRect.top-2+"px",left:this.position.left-this.parentClientRect.left-2+"px"})),je(d,this.getDragPosition(N)),!this.elementInViewport(d)&&this.enableAutoScroll&&!this.helperElement.classList.contains("e-treeview")&&this.helperElement.scrollIntoView();var T=document.querySelectorAll(":hover");if(this.enableAutoScroll&&this.helperElement.classList.contains("e-treeview")){0===T.length&&(T=this.getPathElements(i));var z=this.getScrollParent(T,!1);this.elementInViewport(this.helperElement)?this.getScrollPosition(z,A):this.elementInViewport(this.helperElement)||(0===(T=[].slice.call(document.querySelectorAll(":hover"))).length&&(T=this.getPathElements(i)),z=this.getScrollParent(T,!0),this.getScrollPosition(z,A))}this.dragProcessStarted=!0,this.prevLeft=r,this.prevTop=s,this.position.left=r,this.position.top=s,this.pageX=g,this.pageY=v}},t.prototype.getScrollParent=function(i,r){for(var o,s=r?i.reverse():i,a=s.length-1;a>=0;a--)if(("auto"===(o=window.getComputedStyle(s[parseInt(a.toString(),10)])["overflow-y"])||"scroll"===o)&&s[parseInt(a.toString(),10)].scrollHeight>s[parseInt(a.toString(),10)].clientHeight)return s[parseInt(a.toString(),10)];if("visible"===(o=window.getComputedStyle(document.scrollingElement)["overflow-y"]))return document.scrollingElement.style.overflow="auto",document.scrollingElement},t.prototype.getScrollPosition=function(i,r){if(i&&i===document.scrollingElement)i.clientHeight+document.scrollingElement.scrollTop-this.helperElement.clientHeightr?i.scrollTop+=this.helperElement.clientHeight:i.scrollTop>r-this.helperElement.clientHeight&&(i.scrollTop-=this.helperElement.clientHeight);else if(i&&i!==document.scrollingElement){var s=document.scrollingElement.scrollTop,o=this.helperElement.clientHeight;i.clientHeight+i.getBoundingClientRect().top-o+sr-o-s&&(i.scrollTop-=this.helperElement.clientHeight)}},t.prototype.getPathElements=function(i){return document.elementsFromPoint(i.clientX>0?i.clientX:0,i.clientY>0?i.clientY:0)},t.prototype.triggerOutFunction=function(i,r){this.hoverObject.instance.intOut(i,r.target),this.hoverObject.instance.dragData[this.scope]=null,this.hoverObject=null},t.prototype.getDragPosition=function(i){var r=ze({},i);return this.axis&&("x"===this.axis?delete r.top:"y"===this.axis&&delete r.left),r},t.prototype.getDocumentWidthHeight=function(i){var r=document.body,s=document.documentElement;return Math.max(r["scroll"+i],s["scroll"+i],r["offset"+i],s["offset"+i],s["client"+i])},t.prototype.intDragStop=function(i){if(this.dragProcessStarted=!1,st(i.changedTouches)||1===i.changedTouches.length){if(-1!==["touchend","pointerup","mouseup"].indexOf(i.type)){if(this.dragStop){var s=this.getProperTargetElement(i);this.trigger("dragStop",{event:i,element:this.element,target:s,helper:this.helperElement})}this.intDestroy(i)}else this.element.setAttribute("aria-grabbed","false");var o=this.checkTargetElement(i);o.target&&o.instance&&(o.instance.dragStopCalled=!0,o.instance.dragData[this.scope]=this.droppables[this.scope],o.instance.intDrop(i,o.target)),this.setGlobalDroppables(!0),document.body.classList.remove("e-prevent-select")}},t.prototype.intDestroy=function(i){this.dragProcessStarted=!1,this.toggleEvents(),document.body.classList.remove("e-prevent-select"),this.element.setAttribute("aria-grabbed","false"),E.remove(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.intDragStart),E.remove(document,X.isSafari()?"touchend":X.touchEndEvent,this.intDragStop),E.remove(document,X.isSafari()?"touchend":X.touchEndEvent,this.intDestroy),E.remove(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.intDrag),this.isDragStarted()&&this.isDragStarted(!0)},t.prototype.onPropertyChanged=function(i,r){},t.prototype.getModuleName=function(){return"draggable"},t.prototype.isDragStarted=function(i){return i&&(IC.isDragged=!IC.isDragged),IC.isDragged},t.prototype.setDragArea=function(){var i,r,a,s=0,o=0;if(a="string"==typeof this.dragArea?_(this.dragArea):this.dragArea){var h=a.getBoundingClientRect();i=a.scrollWidth?a.scrollWidth:h.right-h.left,r=a.scrollHeight?this.dragArea&&!m(this.helperElement)&&this.helperElement.classList.contains("e-treeview")?a.clientHeight:a.scrollHeight:h.bottom-h.top;for(var c=["Top","Left","Bottom","Right"],d=getComputedStyle(a),u=0;u12;return I0(i.target,this.helperElement)||-1!==i.type.indexOf("touch")||a?(this.helperElement.style.pointerEvents="none",s=document.elementFromPoint(r.clientX,r.clientY),this.helperElement.style.pointerEvents=o):s=i.target,s},t.prototype.currentStateCheck=function(i,r){return m(this.currentStateTarget)||this.currentStateTarget===i?m(r)?i:r:this.currentStateTarget},t.prototype.getMousePosition=function(i,r){var a,l,s=void 0!==i.srcElement?i.srcElement:i.target,o=this.getCoordinates(i),h=m(s.offsetParent);if(r?(a=this.clone?o.pageX:o.pageX+(h?0:s.offsetParent.scrollLeft)-this.relativeXPosition,l=this.clone?o.pageY:o.pageY+(h?0:s.offsetParent.scrollTop)-this.relativeYPosition):(a=this.clone?o.pageX:o.pageX+window.pageXOffset-this.relativeXPosition,l=this.clone?o.pageY:o.pageY+window.pageYOffset-this.relativeYPosition),document.scrollingElement&&!r&&!this.clone){var c=document.scrollingElement;a=c.scrollWidth>0&&c.scrollWidth>c.clientWidth&&c.scrollLeft>0?a-c.scrollLeft:a,l=c.scrollHeight>0&&c.scrollHeight>c.clientHeight&&c.scrollTop>0?l-c.scrollTop:l}return{left:a-(this.margin.left+this.cursorAt.left),top:l-(this.margin.top+this.cursorAt.top)}},t.prototype.getCoordinates=function(i){return i.type.indexOf("touch")>-1?i.changedTouches[0]:i},t.prototype.getHelperElement=function(i){var r;return this.clone?this.helper?r=this.helper({sender:i,element:this.target}):(r=Si("div",{className:"e-drag-helper e-block-touch",innerHTML:"Draggable"}),document.body.appendChild(r)):r=this.element,r},t.prototype.setGlobalDroppables=function(i,r,s){this.droppables[this.scope]=i?null:{draggable:r,helper:s,draggedElement:this.element}},t.prototype.checkTargetElement=function(i){var r=this.getProperTargetElement(i),s=this.getDropInstance(r);if(!s&&r&&!m(r.parentNode)){var o=J(r.parentNode,".e-droppable")||r.parentElement;o&&(s=this.getDropInstance(o))}return{target:r,instance:s}},t.prototype.getDropInstance=function(i){var s,o=i&&i.ej2_instances;if(o)for(var a=0,l=o;a=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},oR=function(n){function t(e,i){var r=n.call(this,i,e)||this;return r.mouseOver=!1,r.dragData={},r.dragStopCalled=!1,r.bind(),r}return tZ(t,n),t.prototype.bind=function(){this.wireEvents()},t.prototype.wireEvents=function(){E.add(this.element,X.isSafari()?"touchend":X.touchEndEvent,this.intDrop,this)},t.prototype.onPropertyChanged=function(e,i){},t.prototype.getModuleName=function(){return"droppable"},t.prototype.intOver=function(e,i){this.mouseOver||(this.trigger("over",{event:e,target:i,dragData:this.dragData[this.scope]}),this.mouseOver=!0)},t.prototype.intOut=function(e,i){this.mouseOver&&(this.trigger("out",{evt:e,target:i}),this.mouseOver=!1)},t.prototype.intDrop=function(e,i){if(this.dragStopCalled){this.dragStopCalled=!1;var a,r=!0,s=this.dragData[this.scope],o=!!s&&s.helper&&Tr(s.helper);o&&(a=this.isDropArea(e,s.helper,i),this.accept&&(r=gC(s.helper,this.accept))),o&&this.drop&&a.canDrop&&r&&this.trigger("drop",{event:e,target:a.target,droppedElement:s.helper,dragData:s}),this.mouseOver=!1}},t.prototype.isDropArea=function(e,i,r){var s={canDrop:!0,target:r||e.target},o="touchend"===e.type;if(o||s.target===i){i.style.display="none";var a=o?e.changedTouches[0]:e,l=document.elementFromPoint(a.clientX,a.clientY);s.canDrop=!1,s.canDrop=I0(l,this.element),s.canDrop&&(s.target=l),i.style.display=""}return s},t.prototype.destroy=function(){E.remove(this.element,X.isSafari()?"touchend":X.touchEndEvent,this.intDrop),n.prototype.destroy.call(this)},af([I()],t.prototype,"accept",void 0),af([I("default")],t.prototype,"scope",void 0),af([H()],t.prototype,"drop",void 0),af([H()],t.prototype,"over",void 0),af([H()],t.prototype,"out",void 0),af([_t],t)}(dh),uo=function(){function n(t,e,i){this.controlName=t,this.localeStrings=e,this.setLocale(i||"en-US")}return n.prototype.setLocale=function(t){var e=this.intGetControlConstant(n.locale,t);this.currentLocale=e||this.localeStrings},n.load=function(t){this.locale=ze(this.locale,t,{},!0)},n.prototype.getConstant=function(t){return m(this.currentLocale[""+t])?this.localeStrings[""+t]||"":this.currentLocale[""+t]},n.prototype.intGetControlConstant=function(t,e){return t[""+e]?t[""+e][this.controlName]:null},n.locale={},n}(),aR=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),fh=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},nZ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return aR(t,n),fh([I(50)],t.prototype,"swipeThresholdDistance",void 0),t}(Ee),sZ=/(Up|Down)/,Fs=function(n){function t(e,i){var r=n.call(this,i,e)||this;return r.touchAction=!0,r.tapCount=0,r.startEvent=function(s){if(!0===r.touchAction){var o=r.updateChangeTouches(s);void 0!==s.changedTouches&&(r.touchAction=!1),r.isTouchMoved=!1,r.movedDirection="",r.startPoint=r.lastMovedPoint={clientX:o.clientX,clientY:o.clientY},r.startEventData=o,r.hScrollLocked=r.vScrollLocked=!1,r.tStampStart=Date.now(),r.timeOutTapHold=setTimeout(function(){r.tapHoldEvent(s)},r.tapHoldThreshold),E.add(r.element,X.touchMoveEvent,r.moveEvent,r),E.add(r.element,X.touchEndEvent,r.endEvent,r),E.add(r.element,X.touchCancelEvent,r.cancelEvent,r)}},r.moveEvent=function(s){var o=r.updateChangeTouches(s);r.movedPoint=o,r.isTouchMoved=!(o.clientX===r.startPoint.clientX&&o.clientY===r.startPoint.clientY);var a={};r.isTouchMoved&&(clearTimeout(r.timeOutTapHold),r.calcScrollPoints(s),a=ze(a,{},{startEvents:r.startEventData,originalEvent:s,startX:r.startPoint.clientX,startY:r.startPoint.clientY,distanceX:r.distanceX,distanceY:r.distanceY,scrollDirection:r.scrollDirection,velocity:r.getVelocity(o)}),r.trigger("scroll",a),r.lastMovedPoint={clientX:o.clientX,clientY:o.clientY})},r.cancelEvent=function(s){clearTimeout(r.timeOutTapHold),clearTimeout(r.timeOutTap),r.tapCount=0,r.swipeFn(s),E.remove(r.element,X.touchCancelEvent,r.cancelEvent)},r.endEvent=function(s){r.swipeFn(s),r.isTouchMoved||"function"==typeof r.tap&&(r.trigger("tap",{originalEvent:s,tapCount:++r.tapCount}),r.timeOutTap=setTimeout(function(){r.tapCount=0},r.tapThreshold)),r.modeclear()},r.swipeFn=function(s){clearTimeout(r.timeOutTapHold),clearTimeout(r.timeOutTap);var o=r.updateChangeTouches(s),a=o.clientX-r.startPoint.clientX,l=o.clientY-r.startPoint.clientY;a=Math.floor(a<0?-1*a:a),l=Math.floor(l<0?-1*l:a),r.isTouchMoved=a>1||l>1,/Firefox/.test(X.userAgent)&&0===o.clientX&&0===o.clientY&&"mouseup"===s.type&&(r.isTouchMoved=!1),r.endPoint=o,r.calcPoints(s);var c={originalEvent:s,startEvents:r.startEventData,startX:r.startPoint.clientX,startY:r.startPoint.clientY,distanceX:r.distanceX,distanceY:r.distanceY,swipeDirection:r.movedDirection,velocity:r.getVelocity(o)};if(r.isTouchMoved){var d=r.swipeSettings.swipeThresholdDistance,u=ze(void 0,r.defaultArgs,c),f=!1,p=r.element,g=r.isScrollable(p),v=sZ.test(r.movedDirection);(dthis.distanceY?i.clientX>this.startPoint.clientX?"Right":"Left":i.clientYthis.distanceY||!0===this.hScrollLocked)&&!1===this.vScrollLocked?(this.scrollDirection=i.clientX>this.lastMovedPoint.clientX?"Right":"Left",this.hScrollLocked=!0):(this.scrollDirection=i.clientY=e[r[0]+s[0]]},t.prototype.updateChangeTouches=function(e){return e.changedTouches&&0!==e.changedTouches.length?e.changedTouches[0]:e},fh([H()],t.prototype,"tap",void 0),fh([H()],t.prototype,"tapHold",void 0),fh([H()],t.prototype,"swipe",void 0),fh([H()],t.prototype,"scroll",void 0),fh([I(350)],t.prototype,"tapThreshold",void 0),fh([I(750)],t.prototype,"tapHoldThreshold",void 0),fh([re({},nZ)],t.prototype,"swipeSettings",void 0),fh([_t],t)}(dh),oZ=new RegExp("\\n|\\r|\\s\\s+","g"),aZ=new RegExp(/'|"/g),lZ=new RegExp("if ?\\("),hZ=new RegExp("else if ?\\("),lR=new RegExp("else"),cZ=new RegExp("for ?\\("),hR=new RegExp("(/if|/for)"),dZ=new RegExp("\\((.*)\\)",""),bC=new RegExp("^[0-9]+$","g"),uZ=new RegExp("[\\w\"'.\\s+]+","g"),fZ=new RegExp('"(.*?)"',"g"),pZ=new RegExp("[\\w\"'@#$.\\s-+]+","g"),cR=new RegExp("\\${([^}]*)}","g"),gZ=/^\..*/gm,MC=/\\/gi,vZ=/\\\\/gi,mZ=new RegExp("[\\w\"'@#$.\\s+]+","g"),yZ=/\window\./gm;function lf(n,t,e,i,r){return!t||bC.test(n)||-1!==i.indexOf(n.split(".")[0])||r||"true"===n||"false"===n?n:e+"."+n}function wC(n,t,e,i){return t&&!bC.test(n)&&-1===i.indexOf(n.split(".")[0])?e+'["'+n:n}function dR(n){return n.match(vZ)?n:n.replace(MC,"\\\\")}function uR(n,t,e,i){if(n=n.trim(),/\window\./gm.test(n))return n;var s=/'|"/gm;return/@|\$|#/gm.test(n)&&(n=wC(n,-1===e.indexOf(n),t,e)+'"]'),gZ.test(n)?function bZ(n,t,e,i){return!t||bC.test(n)||-1!==i.indexOf(n.split(".")[0])||/^\..*/gm.test(n)?n:e+"."+n}(n,!s.test(n)&&-1===e.indexOf(n),t,e):lf(n,!s.test(n)&&-1===e.indexOf(n),t,e,i)}var MZ=/^[\n\r.]+0&&t.forEach(function(e){he(e)})},n.removeJsEvents=function(){var t=this.wrapElement.querySelectorAll("["+pR.join("],[")+"]");t.length>0&&t.forEach(function(e){pR.forEach(function(i){e.hasAttribute(i)&&e.removeAttribute(i)})})},n.removeXssAttrs=function(){var t=this;this.removeAttrs.forEach(function(e,i){var r=t.wrapElement.querySelectorAll(e.selector);r.length>0&&r.forEach("a[href]"===e.selector?function(s){-1!==s.getAttribute(e.attribute).replace(/\t|\s|&/,"").indexOf("javascript:alert")&&s.removeAttribute(e.attribute)}:function(s){s.removeAttribute(e.attribute)})})},n}();function AZ(n){for(var t,e=n.childNodes,i=0;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Jo_RTL=(new Dg,"e-rtl"),ys=function(n){function t(e,i){return n.call(this,e,i)||this}return OZ(t,n),t.prototype.preRender=function(){},t.prototype.render=function(){this.initialize(),this.removeRippleEffect=function ms(n,t,e){var i=function Y$(n){return{selector:n&&n.selector?n.selector:null,ignore:n&&n.ignore?n.ignore:null,rippleFlag:n&&n.rippleFlag,isCenterRipple:n&&n.isCenterRipple,duration:n&&n.duration?n.duration:350}}(t);return!1===i.rippleFlag||void 0===i.rippleFlag&&!Zo?function(){}:(n.setAttribute("data-ripple","true"),E.add(n,"mousedown",qz,{parent:n,rippleOptions:i}),E.add(n,"mouseup",$z,{parent:n,rippleOptions:i,done:e}),E.add(n,"mouseleave",sf,{parent:n,rippleOptions:i}),X.isPointer&&E.add(n,"transitionend",sf,{parent:n,rippleOptions:i}),function(){n.removeAttribute("data-ripple"),E.remove(n,"mousedown",qz),E.remove(n,"mouseup",$z),E.remove(n,"mouseleave",sf),E.remove(n,"transitionend",sf)})}(this.element,{selector:".e-btn"}),this.renderComplete()},t.prototype.initialize=function(){if(this.cssClass&&V([this.element],this.cssClass.replace(/\s+/g," ").trim().split(" ")),this.isPrimary&&this.element.classList.add("e-primary"),!ce()||ce()&&"progress-btn"!==this.getModuleName()){if(this.content){var e=this.enableHtmlSanitizer?Ai.sanitize(this.content):this.content;this.element.innerHTML=e}this.setIconCss()}this.enableRtl&&this.element.classList.add(Jo_RTL),this.disabled?this.controlStatus(this.disabled):this.wireEvents()},t.prototype.controlStatus=function(e){this.element.disabled=e},t.prototype.setIconCss=function(){if(this.iconCss){var e=this.createElement("span",{className:"e-btn-icon "+this.iconCss});this.element.textContent.trim()?(e.classList.add("e-icon-"+this.iconPosition.toLowerCase()),("Top"===this.iconPosition||"Bottom"===this.iconPosition)&&this.element.classList.add("e-"+this.iconPosition.toLowerCase()+"-icon-btn")):this.element.classList.add("e-icon-btn");var i=this.element.childNodes[0];!i||"Left"!==this.iconPosition&&"Top"!==this.iconPosition?this.element.appendChild(e):this.element.insertBefore(e,i)}},t.prototype.wireEvents=function(){this.isToggle&&E.add(this.element,"click",this.btnClickHandler,this)},t.prototype.unWireEvents=function(){this.isToggle&&E.remove(this.element,"click",this.btnClickHandler)},t.prototype.btnClickHandler=function(){this.element.classList.contains("e-active")?this.element.classList.remove("e-active"):this.element.classList.add("e-active")},t.prototype.destroy=function(){var e=["e-primary",Jo_RTL,"e-icon-btn","e-success","e-info","e-danger","e-warning","e-flat","e-outline","e-small","e-bigger","e-active","e-round","e-top-icon-btn","e-bottom-icon-btn"];this.cssClass&&(e=e.concat(this.cssClass.split(" "))),n.prototype.destroy.call(this),K([this.element],e),this.element.getAttribute("class")||this.element.removeAttribute("class"),this.disabled&&this.element.removeAttribute("disabled"),this.content&&(this.element.innerHTML=this.element.innerHTML.replace(this.content,""));var i=this.element.querySelector("span.e-btn-icon");i&&he(i),this.unWireEvents(),Zo&&this.removeRippleEffect()},t.prototype.getModuleName=function(){return"btn"},t.prototype.getPersistData=function(){return this.addOnPersist([])},t.Inject=function(){},t.prototype.onPropertyChanged=function(e,i){for(var r=this.element.querySelector("span.e-btn-icon"),s=0,o=Object.keys(e);s=ad.width?ad.width:0;return yl.right+WR()-n}function lE(){return z0()+yl.width/2}function hE(n,t,e,i){if(void 0===t&&(t=null),void 0===e&&(e={X:!1,Y:!1}),!e.Y&&!e.X)return{left:0,top:0};var r=n.getBoundingClientRect();if(po=t,oc=n.ownerDocument,i||(i=ns(n,"left","top")),e.X){var s=po?qR():e4(),o=pE(),a=gE(),l=o-i.left,h=i.left+r.width-a;r.width>s?i.left=l>0&&h<=0?a-r.width:h>0&&l<=0?o:l>h?a-r.width:o:l>0?i.left+=l:h>0&&(i.left-=h)}if(e.Y){var c=po?$R():KR(),d=fE(),u=vE(),f=d-i.top,p=i.top+r.height-u;r.height>c?i.top=f>0&&p<=0?u-r.height:p>0&&f<=0?d:f>p?u-r.height:d:f>0?i.top+=f:p>0&&(i.top-=p)}return i}function ac(n,t,e,i){void 0===t&&(t=null);var r=ns(n,"left","top");e&&(r.left=e),i&&(r.top=i);var s=[];po=t,oc=n.ownerDocument;var o=n.getBoundingClientRect(),l=r.left,h=r.left+o.width,d=uE(r.top,r.top+o.height),u=QR(l,h);return d.topSide&&s.push("top"),u.rightSide&&s.push("right"),u.leftSide&&s.push("left"),d.bottomSide&&s.push("bottom"),s}function lJ(n,t,e,i,r,s,o,a,l){if(void 0===o&&(o=null),void 0===a&&(a={X:!0,Y:!0}),t&&n&&r&&s&&(a.X||a.Y)){var d,h={TL:null,TR:null,BL:null,BR:null},c={TL:null,TR:null,BL:null,BR:null};if("none"===window.getComputedStyle(n).display){var u=n.style.visibility;n.style.visibility="hidden",n.style.display="block",d=n.getBoundingClientRect(),n.style.removeProperty("display"),n.style.visibility=u}else d=n.getBoundingClientRect();var f={posX:r,posY:s,offsetX:e,offsetY:i,position:{left:0,top:0}};po=o,oc=t.ownerDocument,function cJ(n,t,e,i,r){e.position=ns(n,e.posX,e.posY,i,r),t.TL=ns(n,"left","top",i,r),t.TR=ns(n,"right","top",i,r),t.BR=ns(n,"left","bottom",i,r),t.BL=ns(n,"right","bottom",i,r)}(t,h,f,l,d),dE(c,f,d),a.X&&GR(t,c,h,f,d,!0),a.Y&&h.TL.top>-1&&XR(t,c,h,f,d,!0),function hJ(n,t,e){var i=0,r=0;if(null!=n.offsetParent&&("absolute"===getComputedStyle(n.offsetParent).position||"relative"===getComputedStyle(n.offsetParent).position)){var s=ns(n.offsetParent,"left","top",!1,e);i=s.left,r=s.top}var o=1,a=1,l=YR(n);if(l){var h=getComputedStyle(l).transform;if("none"!==h){var c=new DOMMatrix(h);o=c.a,a=c.d}if("none"!==getComputedStyle(l).zoom){var u=cE(document.body);o*=u,a*=u}}n.style.top=t.position.top/a+t.offsetY-r/a+"px",n.style.left=t.position.left/o+t.offsetX-i/o+"px"}(n,f,d)}}function cE(n){var t=getComputedStyle(n).zoom;return parseFloat(t)||1}function YR(n){for(;n;){var t=window.getComputedStyle(n).transform,e=cE(document.body);if(t&&"none"!==t||e&&1!==e)return n;if(n===document.body)return null;n=n.offsetParent||n.parentElement}return null}function dE(n,t,e){n.TL={top:t.position.top+t.offsetY,left:t.position.left+t.offsetX},n.TR={top:n.TL.top,left:n.TL.left+e.width},n.BL={top:n.TL.top+e.height,left:n.TL.left},n.BR={top:n.TL.top+e.height,left:n.TL.left+e.width}}function QR(n,t){var e=!1,i=!1;return n-H0()gE()&&(i=!0),{leftSide:e,rightSide:i}}function GR(n,t,e,i,r,s){var o=QR(t.TL.left,t.TR.left),a=uE(t.TL.top,t.BL.top);e.TL.left-H0()<=pE()&&(o.leftSide=!1),e.TR.left>gE()&&(o.rightSide=!1),(o.leftSide&&!o.rightSide||!o.leftSide&&o.rightSide)&&(i.posX="right"===i.posX?"left":"right",i.offsetX=i.offsetX+r.width,i.offsetX=-1*i.offsetX,i.position=ns(n,i.posX,i.posY,!1),dE(t,i,r),s&&GR(n,t,e,i,r,!1),!o.leftSide&&o.rightSide&&a.bottomSide&&(i.offsetX=0))}function XR(n,t,e,i,r,s){var o=uE(t.TL.top,t.BL.top);e.TL.top-R0()<=fE()&&(o.topSide=!1),e.BL.top>=vE()&&n.getBoundingClientRect().bottomvE()&&(i=!0),{topSide:e,bottomSide:i}}function qR(){return po.getBoundingClientRect().width}function $R(){return po.getBoundingClientRect().height}function ZR(){return po.getBoundingClientRect().left}function JR(){return po.getBoundingClientRect().top}function fE(){return po?JR():0}function pE(){return po?ZR():0}function gE(){return po?H0()+ZR()+qR():H0()+e4()}function vE(){return po?R0()+JR()+$R():R0()+KR()}function R0(){return oc.documentElement.scrollTop||oc.body.scrollTop}function H0(){return oc.documentElement.scrollLeft||oc.body.scrollLeft}function KR(){return window.innerHeight}function e4(){var n=window.innerWidth,t=document.documentElement.getBoundingClientRect();return n-(n-(m(document.documentElement)?0:t.width))}function t4(){po=null,oc=null}var i4=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),bn=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},r4=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return i4(t,n),bn([I("left")],t.prototype,"X",void 0),bn([I("top")],t.prototype,"Y",void 0),t}(Ee),qn_OPEN="e-popup-open",qn_CLOSE="e-popup-close",lc=function(n){function t(e,i){return n.call(this,i,e)||this}return i4(t,n),t.prototype.onPropertyChanged=function(e,i){for(var r=0,s=Object.keys(e);r0&&c.left>0&&c.right>0&&c.bottom>0}var s=i.getBoundingClientRect();return!(r.bottoms.bottom||r.right>s.right||r.leftr.top?this.element.style.top="0px":s.bottomr.left&&(this.element.style.left=parseInt(this.element.style.left,10)+(s.left-r.left)+"px"))}},t.prototype.checkCollision=function(){var e=this.collision.X,i=this.collision.Y;"none"===e&&"none"===i||("flip"===e&&"flip"===i?this.callFlip({X:!0,Y:!0}):"fit"===e&&"fit"===i?this.callFit({X:!0,Y:!0}):("flip"===e?this.callFlip({X:!0,Y:!1}):"flip"===i&&this.callFlip({Y:!0,X:!1}),"fit"===e?this.callFit({X:!0,Y:!1}):"fit"===i&&this.callFit({X:!1,Y:!0})))},t.prototype.show=function(e,i){var r=this;if(this.getRelateToElement().classList.contains("e-filemanager")&&(this.fmDialogContainer=this.element.getElementsByClassName("e-file-select-wrap")[0]),this.wireEvents(),!m(this.fmDialogContainer)&&X.isIos&&(this.fmDialogContainer.style.display="block"),1e3===this.zIndex||!m(i)){var o=m(i)?this.element:i;this.zIndex=hc(o),je(this.element,{zIndex:this.zIndex})}e=m(e)||"object"!=typeof e?this.showAnimation:e,("none"!==this.collision.X||"none"!==this.collision.Y)&&(K([this.element],qn_CLOSE),V([this.element],qn_OPEN),this.checkCollision(),K([this.element],qn_OPEN),V([this.element],qn_CLOSE)),m(e)?(K([this.element],qn_CLOSE),V([this.element],qn_OPEN),this.trigger("open")):(e.begin=function(){r.isDestroyed||(K([r.element],qn_CLOSE),V([r.element],qn_OPEN))},e.end=function(){r.isDestroyed||r.trigger("open")},new Hs(e).animate(this.element))},t.prototype.hide=function(e){var i=this;e=m(e)||"object"!=typeof e?this.hideAnimation:e,m(e)?(K([this.element],qn_OPEN),V([this.element],qn_CLOSE),this.trigger("close")):(e.end=function(){i.isDestroyed||(K([i.element],qn_OPEN),V([i.element],qn_CLOSE),i.trigger("close"))},new Hs(e).animate(this.element)),this.unwireEvents()},t.prototype.getScrollableParent=function(e){return this.checkFixedParent(e),function mE(n,t){for(var e=getComputedStyle(n),i=[],r=/(auto|scroll)/,s=n.parentElement;s&&"HTML"!==s.tagName;){var o=getComputedStyle(s);!("absolute"===e.position&&"static"===o.position)&&r.test(o.overflow+o.overflowY+o.overflowX)&&i.push(s),s=s.parentElement}return t||i.push(document),i}(e,this.fixedParent)},t.prototype.checkFixedParent=function(e){for(var i=e.parentElement;i&&"HTML"!==i.tagName;){var r=getComputedStyle(i);("fixed"===r.position||"sticky"===r.position)&&!m(this.element)&&this.element.offsetParent&&"BODY"===this.element.offsetParent.tagName&&"hidden"!==getComputedStyle(this.element.offsetParent).overflow&&(this.element.style.top=window.scrollY>parseInt(this.element.style.top,10)?Re(window.scrollY-parseInt(this.element.style.top,10)):Re(parseInt(this.element.style.top,10)-window.scrollY),this.element.style.position="fixed",this.fixedParent=!0),i=i.parentElement,!m(this.element)&&m(this.element.offsetParent)&&"fixed"===r.position&&"fixed"===this.element.style.position&&(this.fixedParent=!0)}},bn([I("auto")],t.prototype,"height",void 0),bn([I("auto")],t.prototype,"width",void 0),bn([I(null)],t.prototype,"content",void 0),bn([I("container")],t.prototype,"targetType",void 0),bn([I(null)],t.prototype,"viewPortElement",void 0),bn([I({X:"none",Y:"none"})],t.prototype,"collision",void 0),bn([I("")],t.prototype,"relateTo",void 0),bn([re({},r4)],t.prototype,"position",void 0),bn([I(0)],t.prototype,"offsetX",void 0),bn([I(0)],t.prototype,"offsetY",void 0),bn([I(1e3)],t.prototype,"zIndex",void 0),bn([I(!1)],t.prototype,"enableRtl",void 0),bn([I("reposition")],t.prototype,"actionOnScroll",void 0),bn([I(null)],t.prototype,"showAnimation",void 0),bn([I(null)],t.prototype,"hideAnimation",void 0),bn([H()],t.prototype,"open",void 0),bn([H()],t.prototype,"close",void 0),bn([H()],t.prototype,"targetExitViewport",void 0),bn([_t],t)}(Ii);function hc(n){for(var t=n.parentElement,e=[];t&&"BODY"!==t.tagName;){var i=document.defaultView.getComputedStyle(t,null).getPropertyValue("z-index"),r=document.defaultView.getComputedStyle(t,null).getPropertyValue("position");"auto"!==i&&"static"!==r&&e.push(i),t=t.parentElement}for(var s=[],o=0;o2147483647?2147483647:c}var Ui,ka,hf,yh,bE,Sh,$t,Ih,yE=["north-west","north","north-east","west","east","south-west","south","south-east"],_g="e-resize-handle",cc="e-focused-handle",dJ="e-dlg-resizable",n4=["e-restrict-left"],s4="e-resize-viewport",uJ=["north","west","east","south"],SE=0,IE=0,o4=0,a4=0,Ug=0,jg=0,Vg=null,ME=null,wE=null,B0=!0,l4=0,CE=!0;function pJ(n){EE();var t=Si("span",{attrs:{unselectable:"on",contenteditable:"false"}});t.setAttribute("class","e-dialog-border-resize e-"+n),"south"===n&&(t.style.height="2px",t.style.width="100%",t.style.bottom="0px",t.style.left="0px"),"north"===n&&(t.style.height="2px",t.style.width="100%",t.style.top="0px",t.style.left="0px"),"east"===n&&(t.style.height="100%",t.style.width="2px",t.style.right="0px",t.style.top="0px"),"west"===n&&(t.style.height="100%",t.style.width="2px",t.style.left="0px",t.style.top="0px"),Ui.appendChild(t)}function h4(n){var t;return m(n)||(t="string"==typeof n?document.querySelector(n):n),t}function c4(n){for(var t=n||this,e=Ui.querySelectorAll("."+_g),i=0;i-1?"mouse":"touch"}function u4(n){if(n.preventDefault(),Ui=n.target.parentElement,EE(),Ug=n.pageX,jg=n.pageY,n.target.classList.add(cc),m(Vg)||!0!==Vg(n,this)){this.targetEle&&Ui&&Ui.querySelector("."+dJ)&&($t="body"===this.target?null:this.targetEle,Sh=this.targetEle.clientWidth,yh=this.targetEle.clientHeight);var e=m($t)?document:$t;E.add(e,"mousemove",Wg,this),E.add(document,"mouseup",F0,this);for(var i=0;i=0||s.top<0)&&(e=!0):e=!0;var a=IE+(r-jg);a=a>hf?a:hf;var l=0;m($t)||(l=o.top);var h=m($t)?0:$t.offsetHeight-$t.clientHeight,c=s.top-l-h/2;if(c=c<0?0:c,s.top>0&&c+a>yh){if(e=!1,Ui.classList.contains(s4))return;Ui.style.height=yh-parseInt(c.toString(),10)+"px"}else{var d=0;if(e){s.top<0&&t+(s.height+s.top)>0&&a+(d=s.top)<=30&&(a=s.height-(s.height+s.top)+30),a+s.top>=yh&&(Ui.style.height=s.height+(t-(s.height+s.top))+"px");var u=m($t)?d:c;a>=hf&&a+u<=yh&&(Ui.style.height=a+"px")}}}function xE(n){var e,t=!1,i="mouse"===d4(n.type)?n.pageY:n.touches[0].pageY,r=dc(Ui),s=m($t)?0:$t.offsetHeight-$t.clientHeight;m($t)||(e=dc($t)),(!m($t)&&r.top-e.top>0||m($t)&&i>0||!m($t)&&Math.floor(r.top-e.top+r.height+(e.bottom-r.bottom))-s<=yh)&&(t=!0);var o=IE-(i-jg);if(t&&o>=hf&&o<=yh){var a=0;m($t)||(a=e.top);var l=a4-a+(i-jg);l=l>0?l:1,Ui.style.height=o+"px",Ui.style.top=l+"px"}}function TE(n){var i,t=document.documentElement.clientWidth,e=!1;m($t)||(i=dc($t));var r="mouse"===d4(n.type)?n.pageX:n.touches[0].pageX,s=dc(Ui),o=m($t)?0:$t.offsetWidth-$t.clientWidth,a=m($t)?0:i.left,l=m($t)?0:i.width;m(Ih)&&(m($t)?Ih=t:(Ih=s.left-a-o/2+s.width,Ih+=l-o-Ih)),(!m($t)&&Math.floor(s.left-i.left+s.width+(i.right-s.right))-o<=Sh||m($t)&&r>=0)&&(e=!0);var h=SE-(r-Ug);if(B0&&(h=h>Ih?Ih:h),e&&h>=bE&&h<=Sh){var c=0;m($t)||(c=i.left);var d=o4-c+(r-Ug);d=d>0?d:1,h!==l4&&CE&&(Ui.style.width=h+"px"),B0&&(Ui.style.left=d+"px",CE=1!==d)}l4=h}function AE(n){var i,t=document.documentElement.clientWidth,e=!1;m($t)||(i=dc($t));var s=(n.touches?n.changedTouches[0]:n).pageX,o=dc(Ui);(!m($t)&&(o.left-i.left+o.width<=Sh||o.right-i.left>=o.width)||m($t)&&t-s>0)&&(e=!0);var a=SE+(s-Ug),l=0;if(m($t)||(l=i.left),o.left-l+a>Sh){if(e=!1,Ui.classList.contains(s4))return;Ui.style.width=Sh-(o.left-l)+"px"}e&&a>=bE&&a<=Sh&&(Ui.style.width=a+"px")}function p4(){for(var n=Ui.querySelectorAll("."+_g),t=0;t=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},SJ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return LE(t,n),Zt([I(!0)],t.prototype,"isFlat",void 0),Zt([I()],t.prototype,"buttonModel",void 0),Zt([I("Button")],t.prototype,"type",void 0),Zt([H()],t.prototype,"click",void 0),t}(Ee),IJ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return LE(t,n),Zt([I("Fade")],t.prototype,"effect",void 0),Zt([I(400)],t.prototype,"duration",void 0),Zt([I(0)],t.prototype,"delay",void 0),t}(Ee),_0="e-dialog",NE="e-rtl",OE="e-dlg-header-content",g4="e-dlg-header",U0="e-footer-content",j0="e-dlg-modal",v4="e-icon-dlg-close",Pa="e-dlg-target",ea="e-scroll-disabled",m4="e-device",V0="e-dlg-fullscreen",y4="e-dlg-closeicon-btn",S4="e-popup-open",I4="Information",b4="e-scroll-disabled",M4="e-alert-dialog",w4="e-confirm-dialog",kE="e-dlg-resizable",cf="e-restrict-left",C4="e-resize-viewport",PE="user action",kJ=function(n){function t(e,i){var r=n.call(this,e,i)||this;return r.needsID=!0,r}return LE(t,n),t.prototype.render=function(){this.initialize(),this.initRender(),this.wireEvents(),"100%"===this.width&&(this.element.style.width=""),""!==this.minHeight&&(this.element.style.minHeight=Re(this.minHeight)),this.enableResize&&(this.setResize(),this.isModal&&(this.isModelResize=!0),"None"===this.animationSettings.effect&&this.getMinHeight()),this.renderComplete()},t.prototype.initializeValue=function(){this.dlgClosedBy=PE},t.prototype.preRender=function(){var e=this;if(this.initializeValue(),this.headerContent=null,this.allowMaxHeight=!0,this.preventVisibility=!0,this.clonedEle=this.element.cloneNode(!0),this.closeIconClickEventHandler=function(s){e.dlgClosedBy="close icon",e.hide(s)},this.dlgOverlayClickEventHandler=function(s){e.dlgClosedBy="overlayClick",s.preventFocus=!1,e.trigger("overlayClick",s,function(o){o.preventFocus||e.focusContent(),e.dlgClosedBy=PE})},this.l10n=new uo("dialog",{close:"Close"},this.locale),this.checkPositionData(),m(this.target)){var r=this.isProtectedOnChange;this.isProtectedOnChange=!0,this.target=document.body,this.isProtectedOnChange=r}},t.prototype.updatePersistData=function(){this.enablePersistence&&this.setProperties({width:parseFloat(this.element.style.width),height:parseFloat(this.element.style.height),position:{X:parseFloat(this.dragObj.element.style.left),Y:parseFloat(this.dragObj.element.style.top)}},!0)},t.prototype.isNumberValue=function(e){return/^[-+]?\d*\.?\d+$/.test(e)},t.prototype.checkPositionData=function(){if(!m(this.position)){if(!m(this.position.X)&&"number"!=typeof this.position.X&&this.isNumberValue(this.position.X)){var i=this.isProtectedOnChange;this.isProtectedOnChange=!0,this.position.X=parseFloat(this.position.X),this.isProtectedOnChange=i}m(this.position.Y)||"number"==typeof this.position.Y||this.isNumberValue(this.position.Y)&&(i=this.isProtectedOnChange,this.isProtectedOnChange=!0,this.position.Y=parseFloat(this.position.Y),this.isProtectedOnChange=i)}},t.prototype.getEle=function(e,i){for(var r=void 0,s=0;s=0&&t[e])pJ(t[e]);else if(""!==t[e].trim()){var i=Si("div",{className:"e-icons "+_g+" e-"+t[e]});Ui.appendChild(i)}hf=n.minHeight,bE=n.minWidth,Sh=n.maxWidth,yh=n.maxHeight,n.proxy&&n.proxy.element&&n.proxy.element.classList.contains("e-dialog")?c4(n.proxy):c4()}({element:this.element,direction:r,minHeight:parseInt(e.slice(0,i.indexOf("p")),10),maxHeight:this.targetEle.clientHeight,minWidth:parseInt(i.slice(0,i.indexOf("p")),10),maxWidth:this.targetEle.clientWidth,boundary:this.target===document.body?null:this.targetEle,resizeBegin:this.onResizeStart.bind(this),resizeComplete:this.onResizeComplete.bind(this),resizing:this.onResizing.bind(this),proxy:this}),this.wireWindowResizeEvent()}else p4(),this.unWireWindowResizeEvent(),this.element.classList.remove(this.isModal?cf:C4),this.element.classList.remove(kE)},t.prototype.getFocusElement=function(e){var r=e.querySelectorAll('input,select,textarea,button:enabled,a,[contenteditable="true"],[tabindex]');return{element:r[r.length-1]}},t.prototype.keyDown=function(e){var i=this;if(9===e.keyCode&&this.isModal){var r=void 0;m(this.btnObj)||(r=this.btnObj[this.btnObj.length-1]),m(this.btnObj)&&!m(this.ftrTemplateContent)&&(r=this.getFocusElement(this.ftrTemplateContent)),m(this.btnObj)&&m(this.ftrTemplateContent)&&!m(this.contentEle)&&(r=this.getFocusElement(this.contentEle)),!m(r)&&document.activeElement===r.element&&!e.shiftKey&&(e.preventDefault(),this.focusableElements(this.element).focus()),document.activeElement===this.focusableElements(this.element)&&e.shiftKey&&(e.preventDefault(),m(r)||r.element.focus())}var h,s=document.activeElement,o=["input","textarea"].indexOf(s.tagName.toLowerCase())>-1,a=!1;if(o||(a=s.hasAttribute("contenteditable")&&"true"===s.getAttribute("contenteditable")),27===e.keyCode&&this.closeOnEscape){this.dlgClosedBy="escape";var l=document.querySelector(".e-popup-open:not(.e-dialog)");!m(l)&&!l.classList.contains("e-toolbar-pop")&&!l.classList.contains("e-slider-tooltip")||this.hide(e)}(13===e.keyCode&&!e.ctrlKey&&"textarea"!==s.tagName.toLowerCase()&&o&&!m(this.primaryButtonEle)||13===e.keyCode&&e.ctrlKey&&("textarea"===s.tagName.toLowerCase()||a)&&!m(this.primaryButtonEle))&&this.buttons.some(function(d,u){h=u;var f=d.buttonModel;return!m(f)&&!0===f.isPrimary})&&"function"==typeof this.buttons[h].click&&setTimeout(function(){i.buttons[h].click.call(i,e)})},t.prototype.initialize=function(){m(this.target)||(this.targetEle="string"==typeof this.target?document.querySelector(this.target):this.target),this.isBlazorServerRender()||V([this.element],_0),X.isDevice&&V([this.element],m4),this.isBlazorServerRender()||this.setCSSClass(),this.setMaxHeight()},t.prototype.initRender=function(){var e=this;if(this.initialRender=!0,this.isBlazorServerRender()||Fe(this.element,{role:"dialog"}),1e3===this.zIndex?(this.setzIndex(this.element,!1),this.calculatezIndex=!0):this.calculatezIndex=!1,this.setTargetContent(),""!==this.header&&!m(this.header)&&this.setHeader(),this.renderCloseIcon(),this.setContent(),""===this.footerTemplate||m(this.footerTemplate)?!m(this.buttons[0])&&!m(this.buttons[0].buttonModel)&&this.setButton():this.setFooterTemplate(),this.allowDragging&&!m(this.headerContent)&&this.setAllowDragging(),Fe(this.element,{"aria-modal":this.isModal?"true":"false"}),this.isModal&&this.setIsModal(),!0!==this.element.classList.contains(M4)&&!0!==this.element.classList.contains(w4)&&!m(this.element.parentElement)){var i=this.isModal?this.dlgContainer.parentElement:this.element.parentElement;this.refElement=this.createElement("div",{className:"e-dlg-ref-element"}),i.insertBefore(this.refElement,this.isModal?this.dlgContainer:this.element)}if(m(this.targetEle)||this.targetEle.appendChild(this.isModal?this.dlgContainer:this.element),this.popupObj=new lc(this.element,{height:this.height,width:this.width,zIndex:this.zIndex,relateTo:this.target,actionOnScroll:"none",enableRtl:this.enableRtl,open:function(o){var a={container:e.isModal?e.dlgContainer:e.element,element:e.element,target:e.target,preventFocus:!1};e.enableResize&&e.resetResizeIcon(),e.trigger("open",a,function(l){l.preventFocus||e.focusContent()})},close:function(o){e.isModal&&V([e.dlgOverlay],"e-fade"),e.unBindEvent(e.element),e.isModal&&(e.dlgContainer.style.display="none"),e.trigger("close",e.closeArgs);var a=document.activeElement;!m(a)&&!m(a.blur)&&a.blur(),!m(e.storeActiveElement)&&!m(e.storeActiveElement.focus)&&e.storeActiveElement.focus()}}),this.positionChange(),this.setEnableRTL(),this.isBlazorServerRender()||(V([this.element],"e-popup-close"),this.isModal&&this.setOverlayZindex()),this.visible){if(this.show(),this.isModal){var r=this.getTargetContainer(this.target);r instanceof Element&&"rtl"===window.getComputedStyle(r).getPropertyValue("direction")&&this.setPopupPosition()}}else this.isModal&&(this.dlgOverlay.style.display="none");this.initialRender=!1},t.prototype.getTargetContainer=function(e){var i=null;if("string"==typeof e)if(e.startsWith("#"))i=document.getElementById(e.substring(1));else if(e.startsWith(".")){var r=document.getElementsByClassName(e.substring(1));i=r.length>0?r[0]:null}else!(e instanceof HTMLElement)&&e!==document.body&&(i=document.querySelector(e));else e instanceof HTMLElement&&(i=e);return i},t.prototype.resetResizeIcon=function(){var e=this.getMinHeight();if(this.targetEle.offsetHeight0&&("function"==typeof this.buttons[e].click&&E.add(s[e],"click",this.buttons[e].click,this),"object"==typeof this.buttons[e].click&&E.add(s[e],"click",this.buttonClickHandler.bind(this,e),this)),!this.isBlazorServerRender()&&!m(this.ftrTemplateContent)&&(this.btnObj[e].appendTo(this.ftrTemplateContent.children[e]),this.buttons[e].isFlat&&this.btnObj[e].element.classList.add("e-flat"),this.primaryButtonEle=this.element.getElementsByClassName("e-primary")[0]))},t.prototype.buttonClickHandler=function(e){this.trigger("buttons["+e+"].click",{})},t.prototype.setContent=function(){this.contentEle=this.createElement("div",{className:"e-dlg-content",id:this.element.id+"_dialog-content"}),Fe(this.element,this.headerEle?{"aria-describedby":this.element.id+"_title "+this.element.id+"_dialog-content"}:{"aria-describedby":this.element.id+"_dialog-content"}),this.innerContentElement?this.contentEle.appendChild(this.innerContentElement):(!m(this.content)&&""!==this.content||!this.initialRender)&&(("string"!=typeof this.content||ce())&&this.content instanceof HTMLElement?this.contentEle.appendChild(this.content):this.setTemplate(this.content,this.contentEle,"content")),m(this.headerContent)?this.element.insertBefore(this.contentEle,this.element.children[0]):this.element.insertBefore(this.contentEle,this.element.children[1]),"auto"===this.height&&(!this.isBlazorServerRender()&&X.isIE&&""===this.element.style.width&&!m(this.width)&&(this.element.style.width=Re(this.width)),this.setMaxHeight())},t.prototype.setTemplate=function(e,i,r){var s,o,a;o=i.classList.contains(g4)?this.element.id+"header":i.classList.contains(U0)?this.element.id+"footerTemplate":this.element.id+"content",m(e.outerHTML)?("string"==typeof e||"string"!=typeof e||ce()&&!this.isStringTemplate)&&("string"==typeof e&&(e=this.sanitizeHelper(e)),this.isVue||"string"!=typeof e?(s=si(e),a=e):i.innerHTML=e):i.appendChild(e);var l=[];if(!m(s)){for(var c=0,d=s({},this,r,o,!(ce()&&!this.isStringTemplate&&0===a.indexOf("
Blazor"))||this.isStringTemplate);c/g,"");(this.element.children.length>0||i)&&(this.innerContentElement=document.createDocumentFragment(),[].slice.call(this.element.childNodes).forEach(function(r){8!==r.nodeType&&e.innerContentElement.appendChild(r)}))}},t.prototype.setHeader=function(){this.headerEle?this.headerEle.innerHTML="":this.headerEle=this.createElement("div",{id:this.element.id+"_title",className:g4}),this.createHeaderContent(),this.headerContent.appendChild(this.headerEle),this.setTemplate(this.header,this.headerEle,"header"),Fe(this.element,{"aria-describedby":this.element.id+"_title"}),Fe(this.element,{"aria-labelledby":this.element.id+"_dialog-header"}),this.element.insertBefore(this.headerContent,this.element.children[0]),this.allowDragging&&!m(this.headerContent)&&this.setAllowDragging()},t.prototype.setFooterTemplate=function(){this.ftrTemplateContent?this.ftrTemplateContent.innerHTML="":this.ftrTemplateContent=this.createElement("div",{className:U0}),""===this.footerTemplate||m(this.footerTemplate)?this.ftrTemplateContent.innerHTML=this.buttonContent.join(""):this.setTemplate(this.footerTemplate,this.ftrTemplateContent,"footerTemplate"),this.element.appendChild(this.ftrTemplateContent)},t.prototype.createHeaderContent=function(){m(this.headerContent)&&(this.headerContent=this.createElement("div",{id:this.element.id+"_dialog-header",className:OE}))},t.prototype.renderCloseIcon=function(){this.showCloseIcon&&(this.closeIcon=this.createElement("button",{className:y4,attrs:{type:"button"}}),this.closeIconBtnObj=new ys({cssClass:"e-flat",iconCss:v4+" e-icons"}),this.closeIconTitle(),m(this.headerContent)?(this.createHeaderContent(),gl([this.closeIcon],this.headerContent),this.element.insertBefore(this.headerContent,this.element.children[0])):gl([this.closeIcon],this.headerContent),this.closeIconBtnObj.appendTo(this.closeIcon))},t.prototype.closeIconTitle=function(){this.l10n.setLocale(this.locale);var e=this.l10n.getConstant("close");this.closeIcon.setAttribute("title",e),this.closeIcon.setAttribute("aria-label",e)},t.prototype.setCSSClass=function(e){e&&(K([this.element],e.split(" ")),this.isModal&&!m(this.dlgContainer)&&K([this.dlgContainer],e.split(" "))),this.cssClass&&(V([this.element],this.cssClass.split(" ")),this.isModal&&!m(this.dlgContainer)&&V([this.dlgContainer],this.cssClass.split(" ")))},t.prototype.setIsModal=function(){this.dlgContainer=this.createElement("div",{className:"e-dlg-container"}),this.setCSSClass(),this.element.classList.remove(S4),this.element.parentNode.insertBefore(this.dlgContainer,this.element),this.dlgContainer.appendChild(this.element),V([this.element],j0),this.dlgOverlay=this.createElement("div",{className:"e-dlg-overlay"}),this.dlgOverlay.style.zIndex=(this.zIndex-1).toString(),this.dlgContainer.appendChild(this.dlgOverlay)},t.prototype.getValidFocusNode=function(e){for(var i,r=0;r0||"a"===i.tagName.toLowerCase()&&i.hasAttribute("href"))&&i.tabIndex>-1&&!i.disabled&&!this.disableElement(i,'[disabled],[aria-disabled="true"],[type="hidden"]'))return i;i=null}return i},t.prototype.focusableElements=function(e){if(!m(e)){var r=e.querySelectorAll('input,select,textarea,button,a,[contenteditable="true"],[tabindex]');return this.getValidFocusNode(r)}return null},t.prototype.getAutoFocusNode=function(e){var i=e.querySelector("."+y4),s=e.querySelectorAll("[autofocus]"),o=this.getValidFocusNode(s);if(ce()&&(this.primaryButtonEle=this.element.getElementsByClassName("e-primary")[0]),m(o)){if(!m(o=this.focusableElements(this.contentEle)))return o;if(!m(this.primaryButtonEle))return this.element.querySelector(".e-primary")}else i=o;return i},t.prototype.disableElement=function(e,i){var r=e?e.matches||e.webkitMatchesSelector||e.msGetRegionContent:null;if(r)for(;e;e=e.parentNode)if(e instanceof Element&&r.call(e,i))return e;return null},t.prototype.focusContent=function(){var e=this.getAutoFocusNode(this.element),i=m(e)?this.element:e,r=X.userAgent;(r.indexOf("MSIE ")>0||r.indexOf("Trident/")>0)&&this.element.focus(),i.focus(),this.unBindEvent(this.element),this.bindEvent(this.element)},t.prototype.bindEvent=function(e){E.add(e,"keydown",this.keyDown,this)},t.prototype.unBindEvent=function(e){E.remove(e,"keydown",this.keyDown)},t.prototype.updateSanitizeContent=function(){this.isBlazorServerRender()||(this.contentEle.innerHTML=this.sanitizeHelper(this.content))},t.prototype.isBlazorServerRender=function(){return ce()&&this.isServerRendered},t.prototype.getModuleName=function(){return"dialog"},t.prototype.onPropertyChanged=function(e,i){if(this.element.classList.contains(_0))for(var r=0,s=Object.keys(e);r0?this.showCloseIcon||""!==this.header&&!m(this.header)?this.showCloseIcon||he(this.closeIcon):(he(this.headerContent),this.headerContent=null):(this.renderCloseIcon(),this.wireEvents());break;case"locale":this.showCloseIcon&&this.closeIconTitle();break;case"visible":this.visible?this.show():this.hide();break;case"isModal":this.updateIsModal();break;case"height":je(this.element,{height:Re(e.height)}),this.updatePersistData();break;case"width":je(this.element,{width:Re(e.width)}),this.updatePersistData();break;case"zIndex":this.popupObj.zIndex=this.zIndex,this.isModal&&this.setOverlayZindex(this.zIndex),this.element.style.zIndex!==this.zIndex.toString()&&(this.calculatezIndex=!1);break;case"cssClass":this.setCSSClass(i.cssClass);break;case"buttons":this.unWireButtonEvents(),this.destroyButtons(),m(this.ftrTemplateContent)||(he(this.ftrTemplateContent),this.ftrTemplateContent=null),this.footerTemplate="",this.setButton();break;case"allowDragging":this.allowDragging&&!m(this.headerContent)?this.setAllowDragging():this.dragObj.destroy();break;case"target":this.setTarget(e.target);break;case"position":if(this.checkPositionData(),this.isModal){var a=this.position.X,l=this.position.Y;m(i.position)||(m(i.position.X)||(a=i.position.X),m(i.position.Y)||(l=i.position.Y)),this.dlgContainer.classList.contains("e-dlg-"+a+"-"+l)&&this.dlgContainer.classList.remove("e-dlg-"+a+"-"+l)}this.positionChange(),this.updatePersistData();break;case"enableRtl":this.setEnableRTL();break;case"enableResize":this.setResize(),this.isModelResize=this.enableResize&&this.isModal,this.enableResize&&this.dialogOpen&&this.resetResizeIcon();break;case"minHeight":""!==this.minHeight&&(this.element.style.minHeight=Re(this.minHeight))}},t.prototype.setTarget=function(e){this.popupObj.relateTo=e,this.target=e,this.targetEle="string"==typeof this.target?document.querySelector(this.target):this.target,this.dragObj&&(this.dragObj.dragArea=this.targetEle),this.setMaxHeight(),this.isModal&&this.updateIsModal(),this.enableResize&&this.setResize(),m(this.targetEle)||(this.isModal&&!m(this.dlgContainer)?this.targetEle.appendChild(this.dlgContainer):m(this.element)||this.targetEle.appendChild(this.element))},t.prototype.updateIsModal=function(){if(this.element.setAttribute("aria-modal",this.isModal?"true":"false"),this.isModal)m(this.dlgOverlay)&&(this.setIsModal(),this.element.style.top="0px",this.element.style.left="0px",m(this.targetEle)||this.targetEle.appendChild(this.dlgContainer));else{for(K([this.element],j0),K([document.body],[Pa,ea]),he(this.dlgOverlay);this.dlgContainer.firstChild;)this.dlgContainer.parentElement.insertBefore(this.dlgContainer.firstChild,this.dlgContainer);this.dlgContainer.parentElement.removeChild(this.dlgContainer)}this.visible&&this.show(),this.positionChange(),this.isModal&&this.dlgOverlay&&E.add(this.dlgOverlay,"click",this.dlgOverlayClickEventHandler,this)},t.prototype.setzIndex=function(e,i){var r=this.isProtectedOnChange;this.isProtectedOnChange=!0;var s=hc(e);this.zIndex=s>this.zIndex?s:this.zIndex,this.isProtectedOnChange=r,i&&(this.popupObj.zIndex=this.zIndex)},t.prototype.windowResizeHandler=function(){(function vJ(n){Sh=n})(this.targetEle.clientWidth),function mJ(n){yh=n}(this.targetEle.clientHeight),this.setMaxHeight()},t.prototype.getPersistData=function(){return this.addOnPersist(["width","height","position"])},t.prototype.removeAllChildren=function(e){for(;e.children[0];)this.removeAllChildren(e.children[0]),e.removeChild(e.children[0])},t.prototype.destroy=function(){if(!this.isDestroyed){var e=[NE,j0,kE,cf,V0,m4],i=["role","aria-modal","aria-labelledby","aria-describedby","aria-grabbed","tabindex","style"];K([this.targetEle],[Pa,ea]),!m(this.element)&&this.element.classList.contains(V0)&&K([document.body],[Pa,ea]),this.isModal&&K([m(this.targetEle)?document.body:this.targetEle],ea),this.unWireEvents(),this.unWireButtonEvents(),this.destroyButtons(),m(this.closeIconBtnObj)||this.closeIconBtnObj.destroy(),m(this.dragObj)||this.dragObj.destroy(),!m(this.popupObj.element)&&this.popupObj.element.classList.contains("e-popup")&&this.popupObj.destroy(),K([this.element],e),!m(this.cssClass)&&""!==this.cssClass&&K([this.element],this.cssClass.split(" ")),!m(this.refElement)&&!m(this.refElement.parentElement)&&(this.refElement.parentElement.insertBefore(this.isModal?this.dlgContainer:this.element,this.refElement),he(this.refElement),this.refElement=void 0),this.isModal&&(he(this.dlgOverlay),this.dlgContainer.parentNode.insertBefore(this.element,this.dlgContainer),he(this.dlgContainer)),this.element.innerHTML=this.clonedEle.innerHTML;for(var r=0;r0&&""===this.footerTemplate&&this.ftrTemplateContent)for(var e=0;e=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},zE="e-tooltip",L4="e-icons",N4="e-tooltip-close",RE="e-tooltip-wrap",O4="e-tip-content",df="e-arrow-tip",k4="e-arrow-tip-outer",W0="e-arrow-tip-inner",Yg="e-tip-bottom",HE="e-tip-top",P4="e-tip-left",BE="e-tip-right",FE="e-popup",Qg="e-popup-open",_E="e-popup-close",Y0="e-lib",z4="e-tooltip-popup-container",FJ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return D4(t,n),Gi([I({effect:"FadeIn",duration:150,delay:0})],t.prototype,"open",void 0),Gi([I({effect:"FadeOut",duration:150,delay:0})],t.prototype,"close",void 0),t}(Ee),bh=function(n){function t(e,i){var r=n.call(this,e,i)||this;return r.mouseMoveEvent=null,r.mouseMoveTarget=null,r.containerElement=null,r.isBodyContainer=!0,r}return D4(t,n),t.prototype.initialize=function(){this.formatPosition(),V([this.element],zE)},t.prototype.formatPosition=function(){var e,i;this.position&&(0===this.position.indexOf("Top")||0===this.position.indexOf("Bottom")?(e=this.position.split(/(?=[A-Z])/),this.tooltipPositionY=e[0],this.tooltipPositionX=e[1]):(i=this.position.split(/(?=[A-Z])/),this.tooltipPositionX=i[0],this.tooltipPositionY=i[1]))},t.prototype.renderArrow=function(){this.setTipClass(this.position);var e=this.createElement("div",{className:df+" "+this.tipClass});e.appendChild(this.createElement("div",{className:k4+" "+this.tipClass})),e.appendChild(this.createElement("div",{className:W0+" "+this.tipClass})),this.tooltipEle.appendChild(e)},t.prototype.setTipClass=function(e){this.tipClass=0===e.indexOf("Right")?P4:0===e.indexOf("Bottom")?HE:0===e.indexOf("Left")?BE:Yg},t.prototype.renderPopup=function(e){var i=this.mouseTrail?{top:0,left:0}:this.getTooltipPosition(e);this.tooltipEle.classList.remove(Y0),this.popupObj=new lc(this.tooltipEle,{height:this.height,width:this.width,position:{X:i.left,Y:i.top},enableRtl:this.enableRtl,open:this.openPopupHandler.bind(this),close:this.closePopupHandler.bind(this)})},t.prototype.getScalingFactor=function(e){if(!e)return{x:1,y:1};var i={x:1,y:1},r=e.closest('[style*="transform: scale"]');if(r&&r!==this.tooltipEle&&r.contains(this.tooltipEle)){var a=window.getComputedStyle(r).getPropertyValue("transform").match(/matrix\(([^)]+)\)/)[1].split(",").map(parseFloat);i.x=a[0],i.y=a[3]}return i},t.prototype.getTooltipPosition=function(e){this.tooltipEle.style.display="block";var i=this.element.closest('[style*="zoom"]');i&&(i.contains(this.tooltipEle)||(this.tooltipEle.style.zoom=getComputedStyle(i).zoom));var r=ns(e,this.tooltipPositionX,this.tooltipPositionY,!this.isBodyContainer,this.isBodyContainer?null:this.containerElement.getBoundingClientRect()),s=this.getScalingFactor(e),o=this.calculateTooltipOffset(this.position,s.x,s.y),a=this.calculateElementPosition(r,o),c=this.collisionFlipFit(e,a[0],a[1]);return c.left=c.left/s.x,c.top=c.top/s.y,this.tooltipEle.style.display="",c},t.prototype.windowResize=function(){this.reposition(this.findTarget())},t.prototype.reposition=function(e){if(this.popupObj&&e){var i=this.getTooltipPosition(e);this.popupObj.position={X:i.left,Y:i.top},this.popupObj.dataBind()}},t.prototype.openPopupHandler=function(){!this.mouseTrail&&this.needTemplateReposition()&&this.reposition(this.findTarget()),this.trigger("afterOpen",this.tooltipEventArgs),this.tooltipEventArgs=null},t.prototype.closePopupHandler=function(){this.isReact&&!("Click"===this.opensOn||"function"==typeof this.content)&&this.clearTemplate(["content"]),this.clear();var e={type:this.tooltipEventArgs.event?this.tooltipEventArgs.event.type:null,cancel:!1,target:this.tooltipEventArgs.target,event:this.tooltipEventArgs.event?this.tooltipEventArgs.event:null,element:this.tooltipEle,isInteracted:!m(this.tooltipEventArgs.event)};this.trigger("afterClose",e),e=null},t.prototype.calculateTooltipOffset=function(e,i,r){void 0===i&&(i=1),void 0===r&&(r=1);var o,a,l,h,c,d,u,f,s={top:0,left:0};if(1!==i||1!==r){var p=this.tooltipEle.getBoundingClientRect(),g=void 0;l=Math.round(p.width),h=Math.round(p.height),(c=_("."+df,this.tooltipEle))&&(g=c.getBoundingClientRect()),o=c?Math.round(g.width):0,a=c?Math.round(g.height):0,d=this.showTipPointer?0:8,u=a/2+2+(h-this.tooltipEle.clientHeight*r),f=o/2+2+(l-this.tooltipEle.clientWidth*i)}else l=this.tooltipEle.offsetWidth,h=this.tooltipEle.offsetHeight,c=_("."+df,this.tooltipEle),d=this.showTipPointer?0:8,u=(a=c?c.offsetHeight:0)/2+2+(this.tooltipEle.offsetHeight-this.tooltipEle.clientHeight),f=(o=c?c.offsetWidth:0)/2+2+(this.tooltipEle.offsetWidth-this.tooltipEle.clientWidth);switch(this.mouseTrail&&(d+=2),e){case"RightTop":s.left+=o+d,s.top-=h-u;break;case"RightCenter":s.left+=o+d,s.top-=h/2;break;case"RightBottom":s.left+=o+d,s.top-=u;break;case"BottomRight":s.top+=a+d,s.left-=f;break;case"BottomCenter":s.top+=a+d,s.left-=l/2;break;case"BottomLeft":s.top+=a+d,s.left-=l-f;break;case"LeftBottom":s.left-=o+l+d,s.top-=u;break;case"LeftCenter":s.left-=o+l+d,s.top-=h/2;break;case"LeftTop":s.left-=o+l+d,s.top-=h-u;break;case"TopLeft":s.top-=h+a+d,s.left-=l-f;break;case"TopRight":s.top-=h+a+d,s.left-=f;break;default:s.top-=h+a+d,s.left-=l/2}return s.left+=this.offsetX,s.top+=this.offsetY,s},t.prototype.updateTipPosition=function(e){var i=we("."+df+",."+k4+",."+W0,this.tooltipEle);K(i,[Yg,HE,P4,BE]),this.setTipClass(e),V(i,this.tipClass)},t.prototype.adjustArrow=function(e,i,r,s){var o=_("."+df,this.tooltipEle);if(!1!==this.showTipPointer&&null!==o){var a,l;this.updateTipPosition(i),this.tooltipEle.style.display="block";var p,h=this.tooltipEle.clientWidth,c=this.tooltipEle.clientHeight,d=_("."+W0,this.tooltipEle),u=o.offsetWidth,f=o.offsetHeight;this.tooltipEle.style.display="",this.tipClass===Yg||this.tipClass===HE?(this.tipClass===Yg?(l="99.9%",d.style.top="-"+(f-2)+"px"):(l=-(f-1)+"px",d.style.top="-"+(f-6)+"px"),e&&(a=(p="Center"!==r||h>e.offsetWidth||this.mouseTrail)&&"Left"===r||!p&&"End"===this.tipPointerPosition?h-u-2+"px":p&&"Right"===r||!p&&"Start"===this.tipPointerPosition?"2px":!p||"End"!==this.tipPointerPosition&&"Start"!==this.tipPointerPosition?h/2-u/2+"px":"End"===this.tipPointerPosition?e.offsetWidth+(this.tooltipEle.offsetWidth-e.offsetWidth)/2-u/2-2+"px":(this.tooltipEle.offsetWidth-e.offsetWidth)/2-u/2+2+"px")):(this.tipClass===BE?(a="99.9%",d.style.left="-"+(u-2)+"px"):(a=-(u-1)+"px",d.style.left=u-2-u+"px"),l=(p="Center"!==s||c>e.offsetHeight||this.mouseTrail)&&"Top"===s||!p&&"End"===this.tipPointerPosition?c-f-2+"px":p&&"Bottom"===s||!p&&"Start"===this.tipPointerPosition?"2px":c/2-f/2+"px"),o.style.top=l,o.style.left=a}},t.prototype.renderContent=function(e){var i=this,r=_("."+O4,this.tooltipEle);if(this.cssClass&&V([this.tooltipEle],this.cssClass.split(" ")),e&&!m(e.getAttribute("title"))&&(e.setAttribute("data-content",e.getAttribute("title")),e.removeAttribute("title")),m(this.content))e&&!m(e.getAttribute("data-content"))&&(r.innerHTML=e.getAttribute("data-content"));else if(r.innerHTML="",this.content instanceof HTMLElement)r.appendChild(this.content);else if("string"==typeof this.content)this.isAngular?this.setProperties({content:Ai.sanitize(this.content)},!0):this.content=this.enableHtmlSanitizer?Ai.sanitize(this.content):this.content,this.enableHtmlParse?(o=si(this.content)({},this,"content",this.element.id+"content",void 0,void 0,r,this.root))&&Dt(o,r):r.textContent=this.content;else{var o;(o=si(this.content)({},this,"content",this.element.id+"content",void 0,void 0,r))&&(this.isAngular&&setTimeout(function(){i.reposition(e)},1),Dt(o,r)),this.renderReactTemplates()}},t.prototype.renderCloseIcon=function(){if(this.isSticky){var i=this.createElement("div",{className:L4+" "+N4});this.tooltipEle.appendChild(i),E.add(i,X.touchStartEvent,this.onStickyClose,this)}else{var e=this.tooltipEle.querySelector("."+L4+"."+N4);e&>(e)}},t.prototype.addDescribedBy=function(e,i){var r=(e.getAttribute("aria-describedby")||"").split(/\s+/);r.indexOf(i)<0&&r.push(i),Fe(e,{"aria-describedby":r.join(" ").trim(),"data-tooltip-id":i})},t.prototype.removeDescribedBy=function(e){var i=e.getAttribute("data-tooltip-id"),r=(e.getAttribute("aria-describedby")||"").split(/\s+/),s=r.indexOf(i);-1!==s&&r.splice(s,1),e.removeAttribute("data-tooltip-id");var o=r.join(" ").trim();o?e.setAttribute("aria-describedby",o):e.removeAttribute("aria-describedby")},t.prototype.tapHoldHandler=function(e){clearTimeout(this.autoCloseTimer),this.targetHover(e.originalEvent)},t.prototype.touchEndHandler=function(){var e=this;this.isSticky||(this.autoCloseTimer=setTimeout(function(){e.close()},1500))},t.prototype.targetClick=function(e){var i;!m(i=this.target?J(e.target,this.target):this.element)&&(null===i.getAttribute("data-tooltip-id")?this.targetHover(e):this.isSticky||this.hideTooltip(this.animation.close,e,i))},t.prototype.targetHover=function(e){var i;if(!(m(i=this.target?J(e.target,this.target):this.element)||null!==i.getAttribute("data-tooltip-id")&&0===this.closeDelay)){for(var s=0,o=[].slice.call(we('[data-tooltip-id= "'+this.ctrlId+'_content"]',document));s0?this.showTimer=setTimeout(function(){o.mouseTrail&&E.add(i,"mousemove touchstart mouseenter",o.onMouseMove,o),o.popupObj&&(o.popupObj.show(a,i),o.mouseMoveEvent&&o.mouseTrail&&o.onMouseMove(o.mouseMoveEvent))},this.openDelay):this.popupObj&&this.popupObj.show(a,i)}s&&this.wireMouseEvents(s,i)},t.prototype.needTemplateReposition=function(){return!m(this.viewContainerRef)&&"string"!=typeof this.viewContainerRef||this.isReact},t.prototype.checkCollision=function(e,i,r){var s={left:i,top:r,position:this.position,horizontal:this.tooltipPositionX,vertical:this.tooltipPositionY},o=ac(this.tooltipEle,this.checkCollideTarget(),i,r);return o.length>0&&(s.horizontal=o.indexOf("left")>=0?"Right":o.indexOf("right")>=0?"Left":this.tooltipPositionX,s.vertical=o.indexOf("top")>=0?"Bottom":o.indexOf("bottom")>=0?"Top":this.tooltipPositionY),s},t.prototype.calculateElementPosition=function(e,i){return[this.isBodyContainer?e.left+i.left:e.left-this.containerElement.getBoundingClientRect().left+i.left+window.pageXOffset+this.containerElement.scrollLeft,this.isBodyContainer?e.top+i.top:e.top-this.containerElement.getBoundingClientRect().top+i.top+window.pageYOffset+this.containerElement.scrollTop]},t.prototype.collisionFlipFit=function(e,i,r){var s=this.checkCollision(e,i,r),o=s.position;if(this.tooltipPositionY!==s.vertical&&(o=0===this.position.indexOf("Bottom")||0===this.position.indexOf("Top")?s.vertical+this.tooltipPositionX:this.tooltipPositionX+s.vertical),this.tooltipPositionX!==s.horizontal&&(0===o.indexOf("Left")&&(s.vertical="LeftTop"===o||"LeftCenter"===o?"Top":"Bottom",o=s.vertical+"Left"),0===o.indexOf("Right")&&(s.vertical="RightTop"===o||"RightCenter"===o?"Top":"Bottom",o=s.vertical+"Right"),s.horizontal=this.tooltipPositionX),this.tooltipEventArgs={type:null,cancel:!1,target:e,event:null,element:this.tooltipEle,collidedPosition:o},this.trigger("beforeCollision",this.tooltipEventArgs),this.tooltipEventArgs.cancel)o=this.position;else{var a=s.vertical,l=s.horizontal;if(s.position!==o){var h=ns(e,l,a,!this.isBodyContainer,this.isBodyContainer?null:this.containerElement.getBoundingClientRect());this.adjustArrow(e,o,l,a);var c=this.getScalingFactor(e),d=this.calculateTooltipOffset(o,c.x,c.y);d.top-=this.getOffSetPosition("TopBottom",o,this.offsetY),d.left-=this.getOffSetPosition("RightLeft",o,this.offsetX),s.position=o;var u=this.calculateElementPosition(h,d);s.left=u[0],s.top=u[1]}else this.adjustArrow(e,o,l,a)}var f={left:s.left,top:s.top},p=this.isBodyContainer?hE(this.tooltipEle,this.checkCollideTarget(),{X:!0,Y:this.windowCollision},f):f;this.tooltipEle.style.display="block";var g=_("."+df,this.tooltipEle);if(this.showTipPointer&&null!=g&&(0===o.indexOf("Bottom")||0===o.indexOf("Top"))){var v=parseInt(g.style.left,10)-(p.left-s.left);v<0?v=0:v+g.offsetWidth>this.tooltipEle.clientWidth&&(v=this.tooltipEle.clientWidth-g.offsetWidth),g.style.left=v.toString()+"px"}return this.tooltipEle.style.display="",f.left=p.left,f.top=p.top,f},t.prototype.getOffSetPosition=function(e,i,r){return-1!==e.indexOf(this.position.split(/(?=[A-Z])/)[0])&&-1!==e.indexOf(i.split(/(?=[A-Z])/)[0])?2*r:0},t.prototype.checkCollideTarget=function(){return!this.windowCollision&&this.target?this.element:null},t.prototype.hideTooltip=function(e,i,r){var s=this;this.closeDelay>0?(clearTimeout(this.hideTimer),clearTimeout(this.showTimer),this.hideTimer=setTimeout(function(){s.closeDelay&&s.tooltipEle&&s.isTooltipOpen||s.tooltipHide(e,i,r)},this.closeDelay)):this.tooltipHide(e,i,r)},t.prototype.tooltipHide=function(e,i,r){var o,s=this;o=i?this.target?r||i.target:this.element:_('[data-tooltip-id= "'+this.ctrlId+'_content"]',document),this.tooltipEventArgs={type:i?i.type:null,cancel:!1,target:o,event:i||null,element:this.tooltipEle,isInteracted:!m(i)},this.trigger("beforeClose",this.tooltipEventArgs,function(a){a.cancel?s.isHidden=!1:(s.mouseMoveBeforeRemove(),s.popupHide(e,o,i))})},t.prototype.popupHide=function(e,i,r){i&&r&&this.restoreElement(i),this.isHidden=!0;var s={name:this.animation.close.effect,duration:e.duration,delay:e.delay,timingFunction:"easeIn"};"None"===e.effect&&(s=void 0),this.popupObj&&this.popupObj.hide(s)},t.prototype.restoreElement=function(e){this.unwireMouseEvents(e),m(e.getAttribute("data-content"))||(e.setAttribute("title",e.getAttribute("data-content")),e.removeAttribute("data-content")),this.removeDescribedBy(e)},t.prototype.clear=function(){var e=this.findTarget();e&&this.restoreElement(e),this.tooltipEle&&(K([this.tooltipEle],_E),V([this.tooltipEle],Qg)),this.isHidden&&(this.popupObj&&this.popupObj.destroy(),this.tooltipEle&>(this.tooltipEle),this.tooltipEle=null,this.popupObj=null)},t.prototype.tooltipHover=function(){this.tooltipEle&&(this.isTooltipOpen=!0)},t.prototype.tooltipMouseOut=function(e){this.isTooltipOpen=!1,this.hideTooltip(this.animation.close,e,this.findTarget())},t.prototype.onMouseOut=function(e){var i=e.relatedTarget;if(i&&!this.mouseTrail){var r=J(i,"."+RE+"."+Y0+"."+FE);r?E.add(r,"mouseleave",this.tooltipElementMouseOut,this):(this.hideTooltip(this.animation.close,e,this.findTarget()),0===this.closeDelay&&("None"===this.animation.close.effect||this.isReact&&"string"!=typeof this.content)&&this.clear())}else this.hideTooltip(this.animation.close,e,this.findTarget()),this.clear();this.popupObj&&!this.popupObj.element.classList.contains(Qg)&&this.clear()},t.prototype.tooltipElementMouseOut=function(e){this.hideTooltip(this.animation.close,e,this.findTarget()),E.remove(this.element,"mouseleave",this.tooltipElementMouseOut),this.clear()},t.prototype.onStickyClose=function(){this.close()},t.prototype.onMouseMove=function(e){var i=0,r=0;e.type.indexOf("touch")>-1?(e.preventDefault(),i=e.touches[0].pageX,r=e.touches[0].pageY):(i=e.pageX,r=e.pageY),Hs.stop(this.tooltipEle),K([this.tooltipEle],_E),V([this.tooltipEle],Qg),this.adjustArrow(e.target,this.position,this.tooltipPositionX,this.tooltipPositionY);var s=this.getScalingFactor(e.target),o=this.calculateTooltipOffset(this.position,s.x,s.y),h=this.checkCollision(e.target,i+o.left+this.offsetX,r+o.top+this.offsetY);if(this.tooltipPositionX!==h.horizontal||this.tooltipPositionY!==h.vertical){var c=0===this.position.indexOf("Bottom")||0===this.position.indexOf("Top")?h.vertical+h.horizontal:h.horizontal+h.vertical;h.position=c,this.adjustArrow(e.target,h.position,h.horizontal,h.vertical);var d=this.calculateTooltipOffset(h.position,s.x,s.y);h.left=i+d.left-this.offsetX,h.top=r+d.top-this.offsetY}this.tooltipEle.style.left=h.left+"px",this.tooltipEle.style.top=h.top+"px"},t.prototype.keyDown=function(e){this.tooltipEle&&27===e.keyCode&&this.close()},t.prototype.touchEnd=function(e){this.tooltipEle&&null===J(e.target,"."+zE)&&!this.isSticky&&this.close()},t.prototype.scrollHandler=function(e){this.tooltipEle&&!this.isSticky&&!J(e.target,"."+RE+"."+Y0+"."+FE)&&!this.isSticky&&this.close()},t.prototype.render=function(){this.initialize(),this.wireEvents(this.opensOn),this.renderComplete()},t.prototype.preRender=function(){this.tipClass=Yg,this.tooltipPositionX="Center",this.tooltipPositionY="Top",this.isHidden=!0},t.prototype.wireEvents=function(e){for(var r=0,s=this.getTriggerList(e);r0)for(var i=0,r=e;i0)for(var i=0,r=e;i0&&this.condition&&-1!==this.condition.indexOf("not")&&(e[s].condition=e[s].condition?e[s].condition+"not":"not"),i=e[s].validate(t),r){if(!i)return!1}else if(i)return!0;return r},n.prototype.toJson=function(){var t,e;if(this.isComplex){t=[],e=this.predicates;for(var i=0;ie.length-3?(e=e.substring(0,e.length-1),n.endsWith(n.toLowerCase(t),n.toLowerCase(e))):(e.lastIndexOf("%")!==e.indexOf("%")&&e.lastIndexOf("%")>e.indexOf("%")+1&&(e=e.substring(e.indexOf("%")+1,e.lastIndexOf("%"))),-1!==t.indexOf(e)))},n.fnSort=function(t){return"ascending"===(t=t?n.toLowerCase(t):"ascending")?this.fnAscending:this.fnDescending},n.fnAscending=function(t,e){return m(t)&&m(e)||null==e?-1:"string"==typeof t?t.localeCompare(e):null==t?1:t-e},n.fnDescending=function(t,e){return m(t)&&m(e)?-1:null==e?1:"string"==typeof t?-1*t.localeCompare(e):null==t?-1:e-t},n.extractFields=function(t,e){for(var i={},r=0;r0||e.length>0;)o=t.length>0&&e.length>0?r?r(this.getVal(t,0,i),this.getVal(e,0,i),t[0],e[0])<=0?t:e:t[0][i]0?t:e,s.push(o.shift());return s},n.getVal=function(t,e,i){return i?this.getObject(i,t[e]):t[e]},n.toLowerCase=function(t){return t?"string"==typeof t?t.toLowerCase():t.toString():0===t||!1===t?t.toString():""},n.callAdaptorFunction=function(t,e,i,r){if(e in t){var s=t[e](i,r);m(s)||(i=s)}return i},n.getAddParams=function(t,e,i){var r={};return n.callAdaptorFunction(t,"addParams",{dm:e,query:i,params:i?i.params:[],reqParams:r}),r},n.isPlainObject=function(t){return!!t&&t.constructor===Object},n.isCors=function(){var t=null;try{t=new window.XMLHttpRequest}catch{}return!!t&&"withCredentials"in t},n.getGuid=function(t){var i;return(t||"")+"00000000-0000-4000-0000-000000000000".replace(/0/g,function(r,s){if("crypto"in window&&"getRandomValues"in crypto){var o=new Uint8Array(1);window.crypto.getRandomValues(o),i=o[0]%16|0}else i=16*Math.random()|0;return"0123456789abcdef"[19===s?3&i|8:i]})},n.isNull=function(t){return null==t},n.getItemFromComparer=function(t,e,i){var r,s,o,a=0,l="string"==typeof n.getVal(t,0,e);if(t.length)for(;m(r)&&a0&&(r=s,o=t[a]));return o},n.distinct=function(t,e,i){i=!m(i)&&i;var s,r=[],o={};return t.forEach(function(a,l){(s="object"==typeof t[l]?n.getVal(t,l,e):t[l])in o||(r.push(i?t[l]:s),o[s]=1)}),r},n.processData=function(t,e){var i=this.prepareQuery(t),r=new tt(e);t.requiresCounts&&i.requiresCount();var s=r.executeLocal(i),o={result:t.requiresCounts?s.result:s,count:s.count,aggregates:JSON.stringify(s.aggregates)};return t.requiresCounts?o:s},n.prepareQuery=function(t){var e=this,i=new Ht;return t.select&&i.select(t.select),t.where&&n.parse.parseJson(t.where).filter(function(o){if(m(o.condition))i.where(o.field,o.operator,o.value,o.ignoreCase,o.ignoreAccent);else{var a=[];o.field?a.push(new Ss(o.field,o.operator,o.value,o.ignoreCase,o.ignoreAccent)):a=a.concat(e.getPredicate(o.predicates)),"or"===o.condition?i.where(Ss.or(a)):"and"===o.condition&&i.where(Ss.and(a))}}),t.search&&n.parse.parseJson(t.search).filter(function(o){return i.search(o.key,o.fields,o.operator,o.ignoreCase,o.ignoreAccent)}),t.aggregates&&t.aggregates.filter(function(o){return i.aggregate(o.type,o.field)}),t.sorted&&t.sorted.filter(function(o){return i.sortBy(o.name,o.direction)}),t.skip&&i.skip(t.skip),t.take&&i.take(t.take),t.group&&t.group.filter(function(o){return i.group(o)}),i},n.getPredicate=function(t){for(var e=[],i=0;i":"greaterthan","<=":"lessthanorequal",">=":"greaterthanorequal","==":"equal","!=":"notequal","*=":"contains","$=":"endswith","^=":"startswith"},n.odBiOperator={"<":" lt ",">":" gt ","<=":" le ",">=":" ge ","==":" eq ","!=":" ne ",lessthan:" lt ",lessthanorequal:" le ",greaterthan:" gt ",greaterthanorequal:" ge ",equal:" eq ",notequal:" ne "},n.odUniOperator={"$=":"endswith","^=":"startswith","*=":"substringof",endswith:"endswith",startswith:"startswith",contains:"substringof",doesnotendwith:"not endswith",doesnotstartwith:"not startswith",doesnotcontain:"not substringof",wildcard:"wildcard",like:"like"},n.odv4UniOperator={"$=":"endswith","^=":"startswith","*=":"contains",endswith:"endswith",startswith:"startswith",contains:"contains",doesnotendwith:"not endswith",doesnotstartwith:"not startswith",doesnotcontain:"not contains",wildcard:"wildcard",like:"like"},n.diacritics={"\u24b6":"A",\uff21:"A",\u00c0:"A",\u00c1:"A",\u00c2:"A",\u1ea6:"A",\u1ea4:"A",\u1eaa:"A",\u1ea8:"A",\u00c3:"A",\u0100:"A",\u0102:"A",\u1eb0:"A",\u1eae:"A",\u1eb4:"A",\u1eb2:"A",\u0226:"A",\u01e0:"A",\u00c4:"A",\u01de:"A",\u1ea2:"A",\u00c5:"A",\u01fa:"A",\u01cd:"A",\u0200:"A",\u0202:"A",\u1ea0:"A",\u1eac:"A",\u1eb6:"A",\u1e00:"A",\u0104:"A",\u023a:"A",\u2c6f:"A",\ua732:"AA",\u00c6:"AE",\u01fc:"AE",\u01e2:"AE",\ua734:"AO",\ua736:"AU",\ua738:"AV",\ua73a:"AV",\ua73c:"AY","\u24b7":"B",\uff22:"B",\u1e02:"B",\u1e04:"B",\u1e06:"B",\u0243:"B",\u0182:"B",\u0181:"B","\u24b8":"C",\uff23:"C",\u0106:"C",\u0108:"C",\u010a:"C",\u010c:"C",\u00c7:"C",\u1e08:"C",\u0187:"C",\u023b:"C",\ua73e:"C","\u24b9":"D",\uff24:"D",\u1e0a:"D",\u010e:"D",\u1e0c:"D",\u1e10:"D",\u1e12:"D",\u1e0e:"D",\u0110:"D",\u018b:"D",\u018a:"D",\u0189:"D",\ua779:"D",\u01f1:"DZ",\u01c4:"DZ",\u01f2:"Dz",\u01c5:"Dz","\u24ba":"E",\uff25:"E",\u00c8:"E",\u00c9:"E",\u00ca:"E",\u1ec0:"E",\u1ebe:"E",\u1ec4:"E",\u1ec2:"E",\u1ebc:"E",\u0112:"E",\u1e14:"E",\u1e16:"E",\u0114:"E",\u0116:"E",\u00cb:"E",\u1eba:"E",\u011a:"E",\u0204:"E",\u0206:"E",\u1eb8:"E",\u1ec6:"E",\u0228:"E",\u1e1c:"E",\u0118:"E",\u1e18:"E",\u1e1a:"E",\u0190:"E",\u018e:"E","\u24bb":"F",\uff26:"F",\u1e1e:"F",\u0191:"F",\ua77b:"F","\u24bc":"G",\uff27:"G",\u01f4:"G",\u011c:"G",\u1e20:"G",\u011e:"G",\u0120:"G",\u01e6:"G",\u0122:"G",\u01e4:"G",\u0193:"G",\ua7a0:"G",\ua77d:"G",\ua77e:"G","\u24bd":"H",\uff28:"H",\u0124:"H",\u1e22:"H",\u1e26:"H",\u021e:"H",\u1e24:"H",\u1e28:"H",\u1e2a:"H",\u0126:"H",\u2c67:"H",\u2c75:"H",\ua78d:"H","\u24be":"I",\uff29:"I",\u00cc:"I",\u00cd:"I",\u00ce:"I",\u0128:"I",\u012a:"I",\u012c:"I",\u0130:"I",\u00cf:"I",\u1e2e:"I",\u1ec8:"I",\u01cf:"I",\u0208:"I",\u020a:"I",\u1eca:"I",\u012e:"I",\u1e2c:"I",\u0197:"I","\u24bf":"J",\uff2a:"J",\u0134:"J",\u0248:"J","\u24c0":"K",\uff2b:"K",\u1e30:"K",\u01e8:"K",\u1e32:"K",\u0136:"K",\u1e34:"K",\u0198:"K",\u2c69:"K",\ua740:"K",\ua742:"K",\ua744:"K",\ua7a2:"K","\u24c1":"L",\uff2c:"L",\u013f:"L",\u0139:"L",\u013d:"L",\u1e36:"L",\u1e38:"L",\u013b:"L",\u1e3c:"L",\u1e3a:"L",\u0141:"L",\u023d:"L",\u2c62:"L",\u2c60:"L",\ua748:"L",\ua746:"L",\ua780:"L",\u01c7:"LJ",\u01c8:"Lj","\u24c2":"M",\uff2d:"M",\u1e3e:"M",\u1e40:"M",\u1e42:"M",\u2c6e:"M",\u019c:"M","\u24c3":"N",\uff2e:"N",\u01f8:"N",\u0143:"N",\u00d1:"N",\u1e44:"N",\u0147:"N",\u1e46:"N",\u0145:"N",\u1e4a:"N",\u1e48:"N",\u0220:"N",\u019d:"N",\ua790:"N",\ua7a4:"N",\u01ca:"NJ",\u01cb:"Nj","\u24c4":"O",\uff2f:"O",\u00d2:"O",\u00d3:"O",\u00d4:"O",\u1ed2:"O",\u1ed0:"O",\u1ed6:"O",\u1ed4:"O",\u00d5:"O",\u1e4c:"O",\u022c:"O",\u1e4e:"O",\u014c:"O",\u1e50:"O",\u1e52:"O",\u014e:"O",\u022e:"O",\u0230:"O",\u00d6:"O",\u022a:"O",\u1ece:"O",\u0150:"O",\u01d1:"O",\u020c:"O",\u020e:"O",\u01a0:"O",\u1edc:"O",\u1eda:"O",\u1ee0:"O",\u1ede:"O",\u1ee2:"O",\u1ecc:"O",\u1ed8:"O",\u01ea:"O",\u01ec:"O",\u00d8:"O",\u01fe:"O",\u0186:"O",\u019f:"O",\ua74a:"O",\ua74c:"O",\u01a2:"OI",\ua74e:"OO",\u0222:"OU","\u24c5":"P",\uff30:"P",\u1e54:"P",\u1e56:"P",\u01a4:"P",\u2c63:"P",\ua750:"P",\ua752:"P",\ua754:"P","\u24c6":"Q",\uff31:"Q",\ua756:"Q",\ua758:"Q",\u024a:"Q","\u24c7":"R",\uff32:"R",\u0154:"R",\u1e58:"R",\u0158:"R",\u0210:"R",\u0212:"R",\u1e5a:"R",\u1e5c:"R",\u0156:"R",\u1e5e:"R",\u024c:"R",\u2c64:"R",\ua75a:"R",\ua7a6:"R",\ua782:"R","\u24c8":"S",\uff33:"S",\u1e9e:"S",\u015a:"S",\u1e64:"S",\u015c:"S",\u1e60:"S",\u0160:"S",\u1e66:"S",\u1e62:"S",\u1e68:"S",\u0218:"S",\u015e:"S",\u2c7e:"S",\ua7a8:"S",\ua784:"S","\u24c9":"T",\uff34:"T",\u1e6a:"T",\u0164:"T",\u1e6c:"T",\u021a:"T",\u0162:"T",\u1e70:"T",\u1e6e:"T",\u0166:"T",\u01ac:"T",\u01ae:"T",\u023e:"T",\ua786:"T",\ua728:"TZ","\u24ca":"U",\uff35:"U",\u00d9:"U",\u00da:"U",\u00db:"U",\u0168:"U",\u1e78:"U",\u016a:"U",\u1e7a:"U",\u016c:"U",\u00dc:"U",\u01db:"U",\u01d7:"U",\u01d5:"U",\u01d9:"U",\u1ee6:"U",\u016e:"U",\u0170:"U",\u01d3:"U",\u0214:"U",\u0216:"U",\u01af:"U",\u1eea:"U",\u1ee8:"U",\u1eee:"U",\u1eec:"U",\u1ef0:"U",\u1ee4:"U",\u1e72:"U",\u0172:"U",\u1e76:"U",\u1e74:"U",\u0244:"U","\u24cb":"V",\uff36:"V",\u1e7c:"V",\u1e7e:"V",\u01b2:"V",\ua75e:"V",\u0245:"V",\ua760:"VY","\u24cc":"W",\uff37:"W",\u1e80:"W",\u1e82:"W",\u0174:"W",\u1e86:"W",\u1e84:"W",\u1e88:"W",\u2c72:"W","\u24cd":"X",\uff38:"X",\u1e8a:"X",\u1e8c:"X","\u24ce":"Y",\uff39:"Y",\u1ef2:"Y",\u00dd:"Y",\u0176:"Y",\u1ef8:"Y",\u0232:"Y",\u1e8e:"Y",\u0178:"Y",\u1ef6:"Y",\u1ef4:"Y",\u01b3:"Y",\u024e:"Y",\u1efe:"Y","\u24cf":"Z",\uff3a:"Z",\u0179:"Z",\u1e90:"Z",\u017b:"Z",\u017d:"Z",\u1e92:"Z",\u1e94:"Z",\u01b5:"Z",\u0224:"Z",\u2c7f:"Z",\u2c6b:"Z",\ua762:"Z","\u24d0":"a",\uff41:"a",\u1e9a:"a",\u00e0:"a",\u00e1:"a",\u00e2:"a",\u1ea7:"a",\u1ea5:"a",\u1eab:"a",\u1ea9:"a",\u00e3:"a",\u0101:"a",\u0103:"a",\u1eb1:"a",\u1eaf:"a",\u1eb5:"a",\u1eb3:"a",\u0227:"a",\u01e1:"a",\u00e4:"a",\u01df:"a",\u1ea3:"a",\u00e5:"a",\u01fb:"a",\u01ce:"a",\u0201:"a",\u0203:"a",\u1ea1:"a",\u1ead:"a",\u1eb7:"a",\u1e01:"a",\u0105:"a",\u2c65:"a",\u0250:"a",\ua733:"aa",\u00e6:"ae",\u01fd:"ae",\u01e3:"ae",\ua735:"ao",\ua737:"au",\ua739:"av",\ua73b:"av",\ua73d:"ay","\u24d1":"b",\uff42:"b",\u1e03:"b",\u1e05:"b",\u1e07:"b",\u0180:"b",\u0183:"b",\u0253:"b","\u24d2":"c",\uff43:"c",\u0107:"c",\u0109:"c",\u010b:"c",\u010d:"c",\u00e7:"c",\u1e09:"c",\u0188:"c",\u023c:"c",\ua73f:"c",\u2184:"c","\u24d3":"d",\uff44:"d",\u1e0b:"d",\u010f:"d",\u1e0d:"d",\u1e11:"d",\u1e13:"d",\u1e0f:"d",\u0111:"d",\u018c:"d",\u0256:"d",\u0257:"d",\ua77a:"d",\u01f3:"dz",\u01c6:"dz","\u24d4":"e",\uff45:"e",\u00e8:"e",\u00e9:"e",\u00ea:"e",\u1ec1:"e",\u1ebf:"e",\u1ec5:"e",\u1ec3:"e",\u1ebd:"e",\u0113:"e",\u1e15:"e",\u1e17:"e",\u0115:"e",\u0117:"e",\u00eb:"e",\u1ebb:"e",\u011b:"e",\u0205:"e",\u0207:"e",\u1eb9:"e",\u1ec7:"e",\u0229:"e",\u1e1d:"e",\u0119:"e",\u1e19:"e",\u1e1b:"e",\u0247:"e",\u025b:"e",\u01dd:"e","\u24d5":"f",\uff46:"f",\u1e1f:"f",\u0192:"f",\ua77c:"f","\u24d6":"g",\uff47:"g",\u01f5:"g",\u011d:"g",\u1e21:"g",\u011f:"g",\u0121:"g",\u01e7:"g",\u0123:"g",\u01e5:"g",\u0260:"g",\ua7a1:"g",\u1d79:"g",\ua77f:"g","\u24d7":"h",\uff48:"h",\u0125:"h",\u1e23:"h",\u1e27:"h",\u021f:"h",\u1e25:"h",\u1e29:"h",\u1e2b:"h",\u1e96:"h",\u0127:"h",\u2c68:"h",\u2c76:"h",\u0265:"h",\u0195:"hv","\u24d8":"i",\uff49:"i",\u00ec:"i",\u00ed:"i",\u00ee:"i",\u0129:"i",\u012b:"i",\u012d:"i",\u00ef:"i",\u1e2f:"i",\u1ec9:"i",\u01d0:"i",\u0209:"i",\u020b:"i",\u1ecb:"i",\u012f:"i",\u1e2d:"i",\u0268:"i",\u0131:"i","\u24d9":"j",\uff4a:"j",\u0135:"j",\u01f0:"j",\u0249:"j","\u24da":"k",\uff4b:"k",\u1e31:"k",\u01e9:"k",\u1e33:"k",\u0137:"k",\u1e35:"k",\u0199:"k",\u2c6a:"k",\ua741:"k",\ua743:"k",\ua745:"k",\ua7a3:"k","\u24db":"l",\uff4c:"l",\u0140:"l",\u013a:"l",\u013e:"l",\u1e37:"l",\u1e39:"l",\u013c:"l",\u1e3d:"l",\u1e3b:"l",\u017f:"l",\u0142:"l",\u019a:"l",\u026b:"l",\u2c61:"l",\ua749:"l",\ua781:"l",\ua747:"l",\u01c9:"lj","\u24dc":"m",\uff4d:"m",\u1e3f:"m",\u1e41:"m",\u1e43:"m",\u0271:"m",\u026f:"m","\u24dd":"n",\uff4e:"n",\u01f9:"n",\u0144:"n",\u00f1:"n",\u1e45:"n",\u0148:"n",\u1e47:"n",\u0146:"n",\u1e4b:"n",\u1e49:"n",\u019e:"n",\u0272:"n",\u0149:"n",\ua791:"n",\ua7a5:"n",\u01cc:"nj","\u24de":"o",\uff4f:"o",\u00f2:"o",\u00f3:"o",\u00f4:"o",\u1ed3:"o",\u1ed1:"o",\u1ed7:"o",\u1ed5:"o",\u00f5:"o",\u1e4d:"o",\u022d:"o",\u1e4f:"o",\u014d:"o",\u1e51:"o",\u1e53:"o",\u014f:"o",\u022f:"o",\u0231:"o",\u00f6:"o",\u022b:"o",\u1ecf:"o",\u0151:"o",\u01d2:"o",\u020d:"o",\u020f:"o",\u01a1:"o",\u1edd:"o",\u1edb:"o",\u1ee1:"o",\u1edf:"o",\u1ee3:"o",\u1ecd:"o",\u1ed9:"o",\u01eb:"o",\u01ed:"o",\u00f8:"o",\u01ff:"o",\u0254:"o",\ua74b:"o",\ua74d:"o",\u0275:"o",\u01a3:"oi",\u0223:"ou",\ua74f:"oo","\u24df":"p",\uff50:"p",\u1e55:"p",\u1e57:"p",\u01a5:"p",\u1d7d:"p",\ua751:"p",\ua753:"p",\ua755:"p","\u24e0":"q",\uff51:"q",\u024b:"q",\ua757:"q",\ua759:"q","\u24e1":"r",\uff52:"r",\u0155:"r",\u1e59:"r",\u0159:"r",\u0211:"r",\u0213:"r",\u1e5b:"r",\u1e5d:"r",\u0157:"r",\u1e5f:"r",\u024d:"r",\u027d:"r",\ua75b:"r",\ua7a7:"r",\ua783:"r","\u24e2":"s",\uff53:"s",\u00df:"s",\u015b:"s",\u1e65:"s",\u015d:"s",\u1e61:"s",\u0161:"s",\u1e67:"s",\u1e63:"s",\u1e69:"s",\u0219:"s",\u015f:"s",\u023f:"s",\ua7a9:"s",\ua785:"s",\u1e9b:"s","\u24e3":"t",\uff54:"t",\u1e6b:"t",\u1e97:"t",\u0165:"t",\u1e6d:"t",\u021b:"t",\u0163:"t",\u1e71:"t",\u1e6f:"t",\u0167:"t",\u01ad:"t",\u0288:"t",\u2c66:"t",\ua787:"t",\ua729:"tz","\u24e4":"u",\uff55:"u",\u00f9:"u",\u00fa:"u",\u00fb:"u",\u0169:"u",\u1e79:"u",\u016b:"u",\u1e7b:"u",\u016d:"u",\u00fc:"u",\u01dc:"u",\u01d8:"u",\u01d6:"u",\u01da:"u",\u1ee7:"u",\u016f:"u",\u0171:"u",\u01d4:"u",\u0215:"u",\u0217:"u",\u01b0:"u",\u1eeb:"u",\u1ee9:"u",\u1eef:"u",\u1eed:"u",\u1ef1:"u",\u1ee5:"u",\u1e73:"u",\u0173:"u",\u1e77:"u",\u1e75:"u",\u0289:"u","\u24e5":"v",\uff56:"v",\u1e7d:"v",\u1e7f:"v",\u028b:"v",\ua75f:"v",\u028c:"v",\ua761:"vy","\u24e6":"w",\uff57:"w",\u1e81:"w",\u1e83:"w",\u0175:"w",\u1e87:"w",\u1e85:"w",\u1e98:"w",\u1e89:"w",\u2c73:"w","\u24e7":"x",\uff58:"x",\u1e8b:"x",\u1e8d:"x","\u24e8":"y",\uff59:"y",\u1ef3:"y",\u00fd:"y",\u0177:"y",\u1ef9:"y",\u0233:"y",\u1e8f:"y",\u00ff:"y",\u1ef7:"y",\u1e99:"y",\u1ef5:"y",\u01b4:"y",\u024f:"y",\u1eff:"y","\u24e9":"z",\uff5a:"z",\u017a:"z",\u1e91:"z",\u017c:"z",\u017e:"z",\u1e93:"z",\u1e95:"z",\u01b6:"z",\u0225:"z",\u0240:"z",\u2c6c:"z",\ua763:"z",\u0386:"\u0391",\u0388:"\u0395",\u0389:"\u0397",\u038a:"\u0399",\u03aa:"\u0399",\u038c:"\u039f",\u038e:"\u03a5",\u03ab:"\u03a5",\u038f:"\u03a9",\u03ac:"\u03b1",\u03ad:"\u03b5",\u03ae:"\u03b7",\u03af:"\u03b9",\u03ca:"\u03b9",\u0390:"\u03b9",\u03cc:"\u03bf",\u03cd:"\u03c5",\u03cb:"\u03c5",\u03b0:"\u03c5",\u03c9:"\u03c9",\u03c2:"\u03c3"},n.fnOperators={equal:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?n.toLowerCase(t)===n.toLowerCase(e):t===e},notequal:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),!n.fnOperators.equal(t,e,i)},lessthan:function(t,e,i){return i?n.toLowerCase(t)n.toLowerCase(e):t>e},lessthanorequal:function(t,e,i){return i?n.toLowerCase(t)<=n.toLowerCase(e):(m(t)&&(t=void 0),t<=e)},greaterthanorequal:function(t,e,i){return i?n.toLowerCase(t)>=n.toLowerCase(e):t>=e},contains:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?!m(t)&&!m(e)&&-1!==n.toLowerCase(t).indexOf(n.toLowerCase(e)):!m(t)&&!m(e)&&-1!==t.toString().indexOf(e)},doesnotcontain:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?!m(t)&&!m(e)&&-1===n.toLowerCase(t).indexOf(n.toLowerCase(e)):!m(t)&&!m(e)&&-1===t.toString().indexOf(e)},isnotnull:function(t){return null!=t},isnull:function(t){return null==t},startswith:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.startsWith(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.startsWith(t,e)},doesnotstartwith:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.notStartsWith(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.notStartsWith(t,e)},like:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.like(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.like(t,e)},isempty:function(t){return void 0===t||""===t},isnotempty:function(t){return void 0!==t&&""!==t},wildcard:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?(t||"boolean"==typeof t)&&e&&"object"!=typeof t&&n.wildCard(n.toLowerCase(t),n.toLowerCase(e)):(t||"boolean"==typeof t)&&e&&n.wildCard(t,e)},endswith:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.endsWith(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.endsWith(t,e)},doesnotendwith:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.notEndsWith(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.notEndsWith(t,e)},processSymbols:function(t){var e=n.operatorSymbols[t];return e?n.fnOperators[e]:n.throwError("Query - Process Operator : Invalid operator")},processOperator:function(t){return n.fnOperators[t]||n.fnOperators.processSymbols(t)}},n.parse={parseJson:function(t){return"string"!=typeof t||!/^[\s]*\[|^[\s]*\{(.)+:/g.test(t)&&-1!==t.indexOf('"')?t instanceof Array?n.parse.iterateAndReviveArray(t):"object"==typeof t&&null!==t&&n.parse.iterateAndReviveJson(t):t=JSON.parse(t,n.parse.jsonReviver),t},iterateAndReviveArray:function(t){for(var e=0;e-1||e.indexOf("z")>-1,o=e.split(/[^0-9.]/);if(s){if(o[5].indexOf(".")>-1){var a=o[5].split(".");o[5]=a[0],o[6]=new Date(e).getUTCMilliseconds().toString()}else o[6]="00";e=n.dateParse.toTimeZone(new Date(parseInt(o[0],10),parseInt(o[1],10)-1,parseInt(o[2],10),parseInt(o[3],10),parseInt(o[4],10),parseInt(o[5]?o[5]:"00",10),parseInt(o[6],10)),n.serverTimezoneOffset,!1)}else{var l=new Date(parseInt(o[0],10),parseInt(o[1],10)-1,parseInt(o[2],10),parseInt(o[3],10),parseInt(o[4],10),parseInt(o[5]?o[5]:"00",10)),h=parseInt(o[6],10),c=parseInt(o[7],10);if(isNaN(h)&&isNaN(c))return l;e.indexOf("+")>-1?l.setHours(l.getHours()-h,l.getMinutes()-c):l.setHours(l.getHours()+h,l.getMinutes()+c),e=n.dateParse.toTimeZone(l,n.serverTimezoneOffset,!1)}null==n.serverTimezoneOffset&&(e=n.dateParse.addSelfOffset(e))}}return e},isJson:function(t){return"string"==typeof t[0]?t:n.parse.parseJson(t)},isGuid:function(t){return null!=/[A-Fa-f0-9]{8}(?:-[A-Fa-f0-9]{4}){3}-[A-Fa-f0-9]{12}/i.exec(t)},replacer:function(t,e){return n.isPlainObject(t)?n.parse.jsonReplacer(t,e):t instanceof Array?n.parse.arrayReplacer(t):t instanceof Date?n.parse.jsonReplacer({val:t},e).val:t},jsonReplacer:function(t,e){for(var i,s=0,o=Object.keys(t);s=0?"+":"-",s=function(a){var l=Math.floor(Math.abs(a));return(l<10?"0":"")+l};return e.getFullYear()+"-"+s(e.getMonth()+1)+"-"+s(e.getDate())+"T"+s(e.getHours())+":"+s(e.getMinutes())+":"+s(e.getSeconds())+r+s(i/60)+":"+s(i%60)}},n}(),Ml=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),EK={GroupGuid:"{271bbba0-1ee7}"},K4=function(){function n(t){this.options={from:"table",requestType:"json",sortBy:"sorted",select:"select",skip:"skip",group:"group",take:"take",search:"search",count:"requiresCounts",where:"where",aggregates:"aggregates",expand:"expand"},this.type=n,this.dataSource=t,this.pvt={}}return n.prototype.processResponse=function(t,e,i,r){return t},n}(),VE=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ml(t,n),t.prototype.processQuery=function(e,i){for(var a,l,f,r=e.dataSource.json.slice(0),s=r.length,o=!0,h={},c=0,d=[],u=[],p=0;p1?e.sort.filter(function(f){return f.fieldName===c})[0]:e.sort[0];s=this.onSortBy(s,d,e.query,!0)}e.page&&(s=this.onPage(s,e.page,e.query)),this.formGroupResult(s,h)}else{for(var o=e.lazyLoad.onDemandGroupInfo,a=o.where.length-1;a>=0;a--)s=this.onWhere(s,o.where[a]);if(e.group.length!==o.level)s=le.group(s,e.group[o.level].fieldName,r,null,null,e.group[o.level].comparer,!0),e.sort.length&&(s=this.onSortBy(s,e.sort[parseInt(o.level.toString(),10)],e.query,!0));else for(a=e.sort.length-1;a>=o.level;a--)s=this.onSortBy(s,e.sort[parseInt(a.toString(),10)],e.query,!1);i=s.length,h=s,s=(s=s.slice(o.skip)).slice(0,o.take),e.group.length!==o.level&&this.formGroupResult(s,h)}return{result:s,count:i}},t.prototype.formGroupResult=function(e,i){if(e.length&&i.length){var r="GroupGuid",s="childLevels",o="level",a="records";e[r]=i[r],e[s]=i[s],e[o]=i[o],e[a]=i[a]}return e},t.prototype.getAggregate=function(e){var i=Ht.filterQueries(e.queries,"onAggregates"),r=[];if(i.length)for(var s=void 0,o=0;o=0;l--)a[l]&&(o=i.comparer,le.endsWith(a[l]," desc")&&(o=le.fnSort("descending"),a[l]=a[l].replace(" desc","")),e=le.sort(e,a[l],o));return e}return le.sort(e,s?"key":a,i.comparer)},t.prototype.onGroup=function(e,i,r){if(!e||!e.length)return e;var s=this.getAggregate(r);return le.group(e,le.getValue(i.fieldName,r),s,null,null,i.comparer)},t.prototype.onPage=function(e,i,r){var s=le.getValue(i.pageSize,r),o=(le.getValue(i.pageIndex,r)-1)*s;return e&&e.length?e.slice(o,o+s):e},t.prototype.onRange=function(e,i){return e&&e.length?e.slice(le.getValue(i.start),le.getValue(i.end)):e},t.prototype.onTake=function(e,i){return e&&e.length?e.slice(0,le.getValue(i.nos)):e},t.prototype.onSkip=function(e,i){return e&&e.length?e.slice(le.getValue(i.nos)):e},t.prototype.onSelect=function(e,i){return e&&e.length?le.select(e,le.getValue(i.fieldNames)):e},t.prototype.insert=function(e,i,r,s,o){return m(o)?e.dataSource.json.push(i):e.dataSource.json.splice(o,0,i)},t.prototype.remove=function(e,i,r,s){var a,o=e.dataSource.json;for("object"==typeof r&&!(r instanceof Date)&&(r=le.getObject(i,r)),a=0;a1&&(g="("+g+")"),f.filters.push(g);for(var y=0,S="object"==typeof f.filters[p]?Object.keys(f.filters[p]):[];y-1&&this.formRemoteGroupedData(e[s].items,i+1,r-1);var o="GroupGuid",h="records";return e[o]=EK[o],e.level=i,e.childLevels=r,e[h]=e[0].items.length?this.getGroupedRecords(e,!m(e[0].items[h])):[],e},t.prototype.getGroupedRecords=function(e,i){for(var r=[],o=0;ol.length-3?(l=l.substring(0,l.length-1),o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.endswith:le.odv4UniOperator.endswith):l.lastIndexOf("%")!==l.indexOf("%")&&l.lastIndexOf("%")>l.indexOf("%")+1?(l=l.substring(l.indexOf("%")+1,l.lastIndexOf("%")),o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains):o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains),l="'"+(l=encodeURIComponent(l))+"'";else if("wildcard"===o)if(-1!==l.indexOf("*")){var d=l.split("*"),u=void 0,f=0;if(0!==l.indexOf("*")&&-1===d[0].indexOf("%3f")&&-1===d[0].indexOf("?")&&(u="'"+(u=d[0])+"'",s+=(o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.startswith:le.odv4UniOperator.startswith)+"(",s+=c+",",a&&(s+=a),s+=u+")",f++),l.lastIndexOf("*")!==l.length-1&&-1===d[d.length-1].indexOf("%3f")&&-1===d[d.length-1].indexOf("?")&&(u="'"+(u=d[d.length-1])+"'",f>0&&(s+=" and "),s+=(o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.endswith:le.odv4UniOperator.endswith)+"(",s+=c+",",a&&(s+=a),s+=u+")",f++),d.length>2)for(var p=1;p0&&(s+=" and "),"substringof"===(o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains)||"not substringof"===o){var g=u;u=c,c=g}s+=o+"(",s+=c+",",a&&(s+=a),s+=u+")",f++}0===f?(o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains,(-1!==l.indexOf("?")||-1!==l.indexOf("%3f"))&&(l=-1!==l.indexOf("?")?l.split("?").join(""):l.split("%3f").join("")),l="'"+l+"'"):o="wildcard"}else o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains,(-1!==l.indexOf("?")||-1!==l.indexOf("%3f"))&&(l=-1!==l.indexOf("?")?l.split("?").join(""):l.split("%3f").join("")),l="'"+l+"'";return"substringof"!==o&&"not substringof"!==o||(g=l,l=c,c=g),"wildcard"!==o&&(s+=o+"(",s+=c+",",a&&(s+=a),s+=l+")"),s},t.prototype.addParams=function(e){n.prototype.addParams.call(this,e),delete e.reqParams.params},t.prototype.onComplexPredicate=function(e,i,r){for(var s=[],o=0;o-1;f--)!/\bContent-ID:/i.test(c[f])||!/\bHTTP.+201/.test(c[f])||(l=parseInt(/\bContent-ID: (\d+)/i.exec(c[f])[1],10),o.addedRecords[l]&&(h=le.parse.parseJson(/^\{.+\}/m.exec(c[f])[0]),ze({},o.addedRecords[l],this.processResponse(h))));return o}return null},t.prototype.compareAndRemove=function(e,i,r){var s=this;return m(i)||Object.keys(e).forEach(function(o){o!==r&&"@odata.etag"!==o&&(le.isPlainObject(e[o])?(s.compareAndRemove(e[o],i[o]),0===Object.keys(e[o]).filter(function(l){return"@odata.etag"!==l}).length&&delete e[o]):(e[o]===i[o]||e[o]&&i[o]&&e[o].valueOf()===i[o].valueOf())&&delete e[o])}),e},t}(fc),DK=function(n){function t(){var e=n.call(this)||this;return yt("beforeSend",fc.prototype.beforeSend,e),e}return Ml(t,n),t.prototype.insert=function(e,i,r,s,o){return this.pvt.position=o,this.updateType="add",{url:e.dataSource.insertUrl||e.dataSource.crudUrl||e.dataSource.url,data:JSON.stringify(ze({},{value:i,table:r,action:"insert"},le.getAddParams(this,e,s)))}},t.prototype.remove=function(e,i,r,s,o){return n.prototype.remove.call(this,e,i,r),{type:"POST",url:e.dataSource.removeUrl||e.dataSource.crudUrl||e.dataSource.url,data:JSON.stringify(ze({},{key:r,keyColumn:i,table:s,action:"remove"},le.getAddParams(this,e,o)))}},t.prototype.update=function(e,i,r,s,o){return this.updateType="update",this.updateKey=i,{type:"POST",url:e.dataSource.updateUrl||e.dataSource.crudUrl||e.dataSource.url,data:JSON.stringify(ze({},{value:r,action:"update",keyColumn:i,key:r[i],table:s},le.getAddParams(this,e,o)))}},t.prototype.processResponse=function(e,i,r,s,o,a,l){var h;if(e="batch"===(o?JSON.parse(o.data):e).action?le.parse.parseJson(e):e,"add"===this.updateType&&n.prototype.insert.call(this,i,e,null,null,this.pvt.position),"update"===this.updateType&&n.prototype.update.call(this,i,this.updateKey,e),this.updateType=void 0,e.added)for(h=0;hi&&h.push(c)}for(c=0;cthis.pageSize;)h.results.splice(0,1),h.keys.splice(0,1);return window.localStorage.setItem(this.guidId,JSON.stringify(h)),e},t.prototype.beforeSend=function(e,i,r){!m(this.cacheAdaptor.options.batch)&&le.endsWith(r.url,this.cacheAdaptor.options.batch)&&"post"===r.type.toLowerCase()&&i.headers.set("Accept",this.cacheAdaptor.options.multipartAccept),e.dataSource.crossDomain||i.headers.set("Accept",this.cacheAdaptor.options.accept)},t.prototype.update=function(e,i,r,s){return this.isCrudAction=!0,this.cacheAdaptor.update(e,i,r,s)},t.prototype.insert=function(e,i,r){return this.isInsertAction=!0,this.cacheAdaptor.insert(e,i,r)},t.prototype.remove=function(e,i,r,s){return this.isCrudAction=!0,this.cacheAdaptor.remove(e,i,r,s)},t.prototype.batchRequest=function(e,i,r){return this.cacheAdaptor.batchRequest(e,i,r)},t}(fc),tt=function(){function n(t,e,i){var s,r=this;return this.dateParse=!0,this.timeZoneHandling=!0,this.persistQuery={},this.isInitialLoad=!1,this.requests=[],this.isInitialLoad=!0,!t&&!this.dataSource&&(t=[]),i=i||t.adaptor,t&&!1===t.timeZoneHandling&&(this.timeZoneHandling=t.timeZoneHandling),t instanceof Array?s={json:t,offline:!0}:"object"==typeof t?(t.json||(t.json=[]),t.enablePersistence||(t.enablePersistence=!1),t.id||(t.id=""),t.ignoreOnPersist||(t.ignoreOnPersist=[]),s={url:t.url,insertUrl:t.insertUrl,removeUrl:t.removeUrl,updateUrl:t.updateUrl,crudUrl:t.crudUrl,batchUrl:t.batchUrl,json:t.json,headers:t.headers,accept:t.accept,data:t.data,timeTillExpiration:t.timeTillExpiration,cachingPageSize:t.cachingPageSize,enableCaching:t.enableCaching,requestType:t.requestType,key:t.key,crossDomain:t.crossDomain,jsonp:t.jsonp,dataType:t.dataType,offline:void 0!==t.offline?t.offline:!(t.adaptor instanceof DK||t.adaptor instanceof xK||t.url),requiresFormat:t.requiresFormat,enablePersistence:t.enablePersistence,id:t.id,ignoreOnPersist:t.ignoreOnPersist}):le.throwError("DataManager: Invalid arguments"),void 0===s.requiresFormat&&!le.isCors()&&(s.requiresFormat=!!m(s.crossDomain)||s.crossDomain),void 0===s.dataType&&(s.dataType="json"),this.dataSource=s,this.defaultQuery=e,this.dataSource.enablePersistence&&this.dataSource.id&&window.addEventListener("unload",this.setPersistData.bind(this)),s.url&&s.offline&&!s.json.length?(this.isDataAvailable=!1,this.adaptor=i||new pf,this.dataSource.offline=!1,this.ready=this.executeQuery(e||new Ht),this.ready.then(function(o){r.dataSource.offline=!0,r.isDataAvailable=!0,s.json=o.result,r.adaptor=new VE})):this.adaptor=s.offline?new VE:new pf,!s.jsonp&&this.adaptor instanceof pf&&(s.jsonp="callback"),this.adaptor=i||this.adaptor,s.enableCaching&&(this.adaptor=new TK(this.adaptor,s.timeTillExpiration,s.cachingPageSize)),this}return Object.defineProperty(n.prototype,"moduleName",{get:function(){return"datamanager"},enumerable:!0,configurable:!0}),n.prototype.getPersistedData=function(t){var e=localStorage.getItem(t||this.dataSource.id);return JSON.parse(e)},n.prototype.setPersistData=function(t,e,i){localStorage.setItem(e||this.dataSource.id,JSON.stringify(i||this.persistQuery))},n.prototype.setPersistQuery=function(t){var e=this,i=this.getPersistedData();if(this.isInitialLoad&&i&&Object.keys(i).length){this.persistQuery=i,this.persistQuery.queries=this.persistQuery.queries.filter(function(s){if(e.dataSource.ignoreOnPersist&&e.dataSource.ignoreOnPersist.length&&s.fn&&e.dataSource.ignoreOnPersist.some(function(l){return s.fn===l}))return!1;if("onWhere"===s.fn){var o=s.e;if(o&&o.isComplex&&o.predicates instanceof Array){var a=o.predicates.map(function(l){if(l.predicates&&l.predicates instanceof Array){var h=l.predicates.map(function(v){return new Ss(v.field,v.operator,v.value,v.ignoreCase,v.ignoreAccent,v.matchCase)});return"and"===l.condition?Ss.and(h):Ss.or(h)}return new Ss(l.field,l.operator,l.value,l.ignoreCase,l.ignoreAccent,l.matchCase)});s.e=new Ss(a[0],o.condition,a.slice(1))}}return!0});var r=ze(new Ht,this.persistQuery);return this.isInitialLoad=!1,r}return this.persistQuery=t,this.isInitialLoad=!1,t},n.prototype.setDefaultQuery=function(t){return this.defaultQuery=t,this},n.prototype.executeLocal=function(t){!this.defaultQuery&&!(t instanceof Ht)&&le.throwError("DataManager - executeLocal() : A query is required to execute"),this.dataSource.json||le.throwError("DataManager - executeLocal() : Json data is required to execute"),this.dataSource.enablePersistence&&this.dataSource.id&&(t=this.setPersistQuery(t));var e=this.adaptor.processQuery(this,t=t||this.defaultQuery);if(t.subQuery){var i=t.subQuery.fromTable,r=t.subQuery.lookups,s=t.isCountRequired?e.result:e;r&&r instanceof Array&&le.buildHierarchy(t.subQuery.fKey,i,s,r,t.subQuery.key);for(var o=0;oli");z.classList.remove("json-parent");for(var j=0;j',W=ve.children[0].placeholder}return W}function Q(k,W,ve){!m(ve)&&""!==ve&&K(W,ve.split(" ")),!m(k)&&""!==k&&V(W,k.split(" "))}function oe(k,W,ve){if("multiselect"===ve||function Mo(k){if(!k)return!1;for(var W=k;W&&W!==document.body;){if("none"===window.getComputedStyle(W).display)return!1;W=W.parentElement}return!0}(k)){var Te="multiselect"===ve?k:k.clientWidth-parseInt(getComputedStyle(k,null).getPropertyValue("padding-left"),10);!m(W)&&!m(W.getElementsByClassName("e-float-text-content")[0])&&(W.getElementsByClassName("e-float-text-content")[0].classList.contains("e-float-text-overflow")&&W.getElementsByClassName("e-float-text-content")[0].classList.remove("e-float-text-overflow"),(Te0)for(var Ye=0;Ye<_e.length;Ye++)_e[parseInt(Ye.toString(),10)].addEventListener("mousedown",wo,!1),_e[parseInt(Ye.toString(),10)].addEventListener("mouseup",Ul,!1);else if(_e.length>0)for(Ye=0;Ye<_e.length;Ye++)_e[parseInt(Ye.toString(),10)].removeEventListener("mousedown",wo,this),_e[parseInt(Ye.toString(),10)].removeEventListener("mouseup",Ul,this)}function wo(){for(var W=this.parentElement;!W.classList.contains("e-input-group");)W=W.parentElement;!function Sa(k,W){!k.classList.contains("e-disabled")&&!k.querySelector("input").readOnly&&W.classList.add("e-input-btn-ripple")}(W,this)}function Ul(){var k=this;setTimeout(function(){k.classList.remove("e-input-btn-ripple")},500)}function fb(k,W){var ve=W("span",{className:k});return ve.classList.add("e-input-group-icon"),ve}function p_(k,W,ve,Te){var _e=m(Te)?Si:Te,Ye=fb(k,_e);W.classList.add("e-float-icon-left");var vi=W.querySelector(".e-input-in-wrap");if(m(vi)){vi=_e("span",{className:"e-input-in-wrap"}),ve.parentNode.insertBefore(vi,ve);var Gs=W.querySelectorAll(ve.tagName+" ~ *");vi.appendChild(ve);for(var ts=0;ts-1)if("class"===_e){var Ye=this.getInputValidClassList(k[""+_e]);""!==Ye&&V([W],Ye.split(" "))}else if("style"===_e){var vi=W.getAttribute(_e);vi=m(vi)?k[""+_e]:vi+k[""+_e],W.setAttribute(_e,vi)}else W.setAttribute(_e,k[""+_e])}},n.isBlank=function _le(k){return!k||/^\s*$/.test(k)}}(Le||(Le={})),new RegExp("^(-)?(\\d*)$"),new RegExp("^[A-Za-z0-9._%+-]{1,}@[A-Za-z0-9._%+-]{1,}([.]{1}[a-zA-Z0-9]{2,}|[.]{1}[a-zA-Z0-9]{2,4}[.]{1}[a-zA-Z0-9]{2,4})$"),new RegExp("^([0-9]{4})-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])$"),new RegExp("^[0-9]*$"),new RegExp("^[+]?[0-9]{9,13}$"),new RegExp("^\\d{13,16}$");var me=function(){function n(t,e){this.width=t,this.height=e}return n.prototype.isEmpty=function(){return 0===this.height&&0===this.width},n.prototype.clone=function(){return new n(this.width,this.height)},n}(),wie=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),YB=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},R=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return wie(t,n),t.equals=function(e,i){return e===i||!(!e||!i)&&(!e||!i||e.x===i.x&&e.y===i.y)},t.isEmptyPoint=function(e){return!(e.x&&e.y)},t.transform=function(e,i,r){var s={x:0,y:0};return s.x=Math.round(100*(e.x+r*Math.cos(i*Math.PI/180)))/100,s.y=Math.round(100*(e.y+r*Math.sin(i*Math.PI/180)))/100,s},t.findLength=function(e,i){return Math.sqrt(Math.pow(e.x-i.x,2)+Math.pow(e.y-i.y,2))},t.findAngle=function(e,i){var r=Math.atan2(i.y-e.y,i.x-e.x);return r=180*r/Math.PI,(r%=360)<0&&(r+=360),r},t.distancePoints=function(e,i){return Math.sqrt(Math.pow(i.x-e.x,2)+Math.pow(i.y-e.y,2))},t.getLengthFromListOfPoints=function(e){for(var i=0,r=0;ri.y&&!r?o.y+=s:o.y-=s:e.y===i.y?e.xi.x&&!r?o.x+=s:o.x-=s:r?(a=this.findAngle(e,i),o=this.transform(e,a,s)):(a=this.findAngle(i,e),o=this.transform(i,a,s)),o},t.direction=function(e,i){return Math.abs(i.x-e.x)>Math.abs(i.y-e.y)?e.x0)for(var r=0;rt.right||this.top>t.bottom||this.bottom=t.right&&this.top<=t.top&&this.bottom>=t.bottom},n.prototype.containsPoint=function(t,e){return void 0===e&&(e=0),this.left-e<=t.x&&this.right+e>=t.x&&this.top-e<=t.y&&this.bottom+e>=t.y},n.toBounds=function(t){for(var e=new n,i=0,r=t;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},ZB=function(n){if(n)switch(n.type){case"Linear":default:return vI;case"Radial":return Pie}return vI},Oie=function(){return function n(t,e,i,r){this.left=t,this.right=e,this.top=i,this.bottom=r}}(),Jn=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),rt([I(0)],t.prototype,"left",void 0),rt([I(0)],t.prototype,"right",void 0),rt([I(0)],t.prototype,"top",void 0),rt([I(0)],t.prototype,"bottom",void 0),t}(Ee),kie=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),rt([I(45)],t.prototype,"angle",void 0),rt([I(5)],t.prototype,"distance",void 0),rt([I(.7)],t.prototype,"opacity",void 0),rt([I("lightgrey")],t.prototype,"color",void 0),t}(Ee),JB=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),t.prototype.getClassName=function(){return"Stop"},rt([I("")],t.prototype,"color",void 0),rt([I(0)],t.prototype,"offset",void 0),rt([I(1)],t.prototype,"opacity",void 0),t}(Ee),Sx=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),rt([Ft([],JB)],t.prototype,"stops",void 0),rt([I("None")],t.prototype,"type",void 0),rt([I("")],t.prototype,"id",void 0),t}(Ee),vI=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),rt([I(0)],t.prototype,"x1",void 0),rt([I(0)],t.prototype,"x2",void 0),rt([I(0)],t.prototype,"y1",void 0),rt([I(0)],t.prototype,"y2",void 0),t}(Sx),Pie=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),rt([I(0)],t.prototype,"cx",void 0),rt([I(0)],t.prototype,"cy",void 0),rt([I(0)],t.prototype,"fx",void 0),rt([I(0)],t.prototype,"fy",void 0),rt([I(50)],t.prototype,"r",void 0),t}(Sx),Ll=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),rt([I("white")],t.prototype,"fill",void 0),rt([I("black")],t.prototype,"strokeColor",void 0),rt([I("")],t.prototype,"strokeDashArray",void 0),rt([I(1)],t.prototype,"strokeWidth",void 0),rt([I(1)],t.prototype,"opacity",void 0),rt([w0(ZB)],t.prototype,"gradient",void 0),t}(Ee),KB=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),rt([I("transparent")],t.prototype,"fill",void 0),t}(Ll),Qf=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),rt([I("black")],t.prototype,"color",void 0),rt([I("Arial")],t.prototype,"fontFamily",void 0),rt([I(12)],t.prototype,"fontSize",void 0),rt([I(!1)],t.prototype,"italic",void 0),rt([I(!1)],t.prototype,"bold",void 0),rt([I("CollapseSpace")],t.prototype,"whiteSpace",void 0),rt([I("WrapWithOverflow")],t.prototype,"textWrapping",void 0),rt([I("Center")],t.prototype,"textAlign",void 0),rt([I("None")],t.prototype,"textDecoration",void 0),rt([I("Wrap")],t.prototype,"textOverflow",void 0),rt([I("transparent")],t.prototype,"fill",void 0),t}(Ll),on=function(n){return n[n.Default=0]="Default",n[n.expandNode=2]="expandNode",n[n.interaction=4]="interaction",n[n.GroupingInProgress=8]="GroupingInProgress",n[n.GroupClipboardInProcess=16]="GroupClipboardInProcess",n[n.ClearObject=32]="ClearObject",n}(on||{}),ci=function(n){return n[n.Visible=1]="Visible",n[n.Hidden=2]="Hidden",n[n.Hover=4]="Hover",n[n.Connect=8]="Connect",n}(ci||{}),Kt=function(n){return n[n.None=0]="None",n[n.ShowHorizontalLines=1]="ShowHorizontalLines",n[n.ShowVerticalLines=2]="ShowVerticalLines",n[n.ShowLines=3]="ShowLines",n[n.SnapToHorizontalLines=4]="SnapToHorizontalLines",n[n.SnapToVerticalLines=8]="SnapToVerticalLines",n[n.SnapToLines=12]="SnapToLines",n[n.SnapToObject=16]="SnapToObject",n[n.All=31]="All",n}(Kt||{}),lr=function(n){return n[n.None=1]="None",n[n.ConnectorSourceThumb=2]="ConnectorSourceThumb",n[n.ConnectorTargetThumb=4]="ConnectorTargetThumb",n[n.ResizeSouthEast=8]="ResizeSouthEast",n[n.ResizeSouthWest=16]="ResizeSouthWest",n[n.ResizeNorthEast=32]="ResizeNorthEast",n[n.ResizeNorthWest=64]="ResizeNorthWest",n[n.ResizeEast=128]="ResizeEast",n[n.ResizeWest=256]="ResizeWest",n[n.ResizeSouth=512]="ResizeSouth",n[n.ResizeNorth=1024]="ResizeNorth",n[n.Rotate=2048]="Rotate",n[n.UserHandle=4096]="UserHandle",n[n.ToolTip=8192]="ToolTip",n[n.ResizeAll=2046]="ResizeAll",n[n.All=16382]="All",n}(lr||{}),qe=function(n){return n[n.None=1]="None",n[n.Select=2]="Select",n[n.Delete=4]="Delete",n[n.Drag=8]="Drag",n[n.DragSourceEnd=16]="DragSourceEnd",n[n.DragTargetEnd=32]="DragTargetEnd",n[n.DragSegmentThumb=64]="DragSegmentThumb",n[n.AllowDrop=128]="AllowDrop",n[n.Bridging=256]="Bridging",n[n.BridgeObstacle=512]="BridgeObstacle",n[n.InheritBridging=1024]="InheritBridging",n[n.PointerEvents=2048]="PointerEvents",n[n.Tooltip=4096]="Tooltip",n[n.InheritTooltip=8192]="InheritTooltip",n[n.Interaction=4218]="Interaction",n[n.ReadOnly=16384]="ReadOnly",n[n.LineRouting=32768]="LineRouting",n[n.InheritLineRouting=65536]="InheritLineRouting",n[n.ConnectToNearByNode=131072]="ConnectToNearByNode",n[n.ConnectToNearByPort=262144]="ConnectToNearByPort",n[n.ConnectToNearByElement=393216]="ConnectToNearByElement",n[n.InheritSegmentThumbShape=524288]="InheritSegmentThumbShape",n[n.InheritSegmentThumbSize=1048576]="InheritSegmentThumbSize",n[n.Default=2043454]="Default",n}(qe||{}),Nr=function(n){return n[n.ReadOnly=2]="ReadOnly",n[n.InheritReadOnly=4]="InheritReadOnly",n[n.Select=8]="Select",n[n.Drag=16]="Drag",n[n.Resize=32]="Resize",n[n.Rotate=64]="Rotate",n[n.Tooltip=128]="Tooltip",n[n.Interaction=120]="Interaction",n[n.None=0]="None",n}(Nr||{}),ie=function(n){return n[n.None=0]="None",n[n.Select=2]="Select",n[n.Drag=4]="Drag",n[n.Rotate=8]="Rotate",n[n.Shadow=16]="Shadow",n[n.PointerEvents=32]="PointerEvents",n[n.Delete=64]="Delete",n[n.InConnect=128]="InConnect",n[n.OutConnect=256]="OutConnect",n[n.Individual=512]="Individual",n[n.Expandable=1024]="Expandable",n[n.AllowDrop=2048]="AllowDrop",n[n.Inherit=78]="Inherit",n[n.ResizeNorthEast=4096]="ResizeNorthEast",n[n.ResizeEast=8192]="ResizeEast",n[n.ResizeSouthEast=16384]="ResizeSouthEast",n[n.ResizeSouth=32768]="ResizeSouth",n[n.ResizeSouthWest=65536]="ResizeSouthWest",n[n.ResizeWest=131072]="ResizeWest",n[n.ResizeNorthWest=262144]="ResizeNorthWest",n[n.ResizeNorth=524288]="ResizeNorth",n[n.Resize=1044480]="Resize",n[n.AspectRatio=1048576]="AspectRatio",n[n.Tooltip=2097152]="Tooltip",n[n.InheritTooltip=4194304]="InheritTooltip",n[n.ReadOnly=8388608]="ReadOnly",n[n.HideThumbs=16777216]="HideThumbs",n[n.AllowMovingOutsideLane=33554432]="AllowMovingOutsideLane",n[n.Default=5240814]="Default",n}(ie||{}),Xr=function(n){return n[n.None=0]="None",n[n.ElementIsPort=2]="ElementIsPort",n[n.ElementIsGroup=4]="ElementIsGroup",n[n.HorizontalLaneHeader=8]="HorizontalLaneHeader",n}(Xr||{}),bt=function(n){return n[n.Rotate=2]="Rotate",n[n.ConnectorSource=4]="ConnectorSource",n[n.ConnectorTarget=8]="ConnectorTarget",n[n.ResizeNorthEast=16]="ResizeNorthEast",n[n.ResizeEast=32]="ResizeEast",n[n.ResizeSouthEast=64]="ResizeSouthEast",n[n.ResizeSouth=128]="ResizeSouth",n[n.ResizeSouthWest=256]="ResizeSouthWest",n[n.ResizeWest=512]="ResizeWest",n[n.ResizeNorthWest=1024]="ResizeNorthWest",n[n.ResizeNorth=2048]="ResizeNorth",n[n.Default=4094]="Default",n}(bt||{}),nt=function(n){return n[n.None=1]="None",n[n.Bridging=2]="Bridging",n[n.UndoRedo=4]="UndoRedo",n[n.Tooltip=8]="Tooltip",n[n.UserInteraction=16]="UserInteraction",n[n.ApiUpdate=32]="ApiUpdate",n[n.PageEditable=48]="PageEditable",n[n.Zoom=64]="Zoom",n[n.PanX=128]="PanX",n[n.PanY=256]="PanY",n[n.Pan=384]="Pan",n[n.ZoomTextEdit=512]="ZoomTextEdit",n[n.Virtualization=1024]="Virtualization",n[n.LineRouting=2048]="LineRouting",n[n.Default=500]="Default",n}(nt||{}),ri=function(n){return n[n.None=0]="None",n[n.SingleSelect=1]="SingleSelect",n[n.MultipleSelect=2]="MultipleSelect",n[n.ZoomPan=4]="ZoomPan",n[n.DrawOnce=8]="DrawOnce",n[n.ContinuousDraw=16]="ContinuousDraw",n[n.Default=3]="Default",n}(ri||{}),Qa=function(n){return n[n.Self=1]="Self",n[n.Parent=2]="Parent",n}(Qa||{}),ft=function(n){return n[n.None=0]="None",n[n.Control=1]="Control",n[n.Meta=1]="Meta",n[n.Alt=2]="Alt",n[n.Shift=4]="Shift",n}(ft||{}),Mt=function(n){return n[n.None=null]="None",n[n.Number0=0]="Number0",n[n.Number1=1]="Number1",n[n.Number2=2]="Number2",n[n.Number3=3]="Number3",n[n.Number4=4]="Number4",n[n.Number5=5]="Number5",n[n.Number6=6]="Number6",n[n.Number7=7]="Number7",n[n.Number8=8]="Number8",n[n.Number9=9]="Number9",n[n.A=65]="A",n[n.B=66]="B",n[n.C=67]="C",n[n.D=68]="D",n[n.E=69]="E",n[n.F=70]="F",n[n.G=71]="G",n[n.H=72]="H",n[n.I=73]="I",n[n.J=74]="J",n[n.K=75]="K",n[n.L=76]="L",n[n.M=77]="M",n[n.N=78]="N",n[n.O=79]="O",n[n.P=80]="P",n[n.Q=81]="Q",n[n.R=82]="R",n[n.S=83]="S",n[n.T=84]="T",n[n.U=85]="U",n[n.V=86]="V",n[n.W=87]="W",n[n.X=88]="X",n[n.Y=89]="Y",n[n.Z=90]="Z",n[n.Left=37]="Left",n[n.Up=38]="Up",n[n.Right=39]="Right",n[n.Down=40]="Down",n[n.Escape=27]="Escape",n[n.Space=32]="Space",n[n.PageUp=33]="PageUp",n[n.PageDown=34]="PageDown",n[n.End=35]="End",n[n.Home=36]="Home",n[n.Delete=46]="Delete",n[n.Tab=9]="Tab",n[n.Enter=13]="Enter",n[n.BackSpace=8]="BackSpace",n[n.F1=112]="F1",n[n.F2=113]="F2",n[n.F3=114]="F3",n[n.F4=115]="F4",n[n.F5=116]="F5",n[n.F6=117]="F6",n[n.F7=118]="F7",n[n.F8=119]="F8",n[n.F9=120]="F9",n[n.F10=121]="F10",n[n.F11=122]="F11",n[n.F12=123]="F12",n[n.Star=56]="Star",n[n.Plus=187]="Plus",n[n.Minus=189]="Minus",n[n.BracketLeft=219]="BracketLeft",n[n.BracketRight=221]="BracketRight",n}(Mt||{}),ee=function(n){return n[n.Render=2]="Render",n[n.PublicMethod=4]="PublicMethod",n[n.ToolAction=8]="ToolAction",n[n.UndoRedo=16]="UndoRedo",n[n.TextEdit=32]="TextEdit",n[n.Group=64]="Group",n[n.Clear=128]="Clear",n[n.PreventClearSelection=256]="PreventClearSelection",n[n.Interactions=512]="Interactions",n[n.PreventHistory=1024]="PreventHistory",n[n.PreventIconsUpdate=2048]="PreventIconsUpdate",n[n.PreventCollectionChangeOnDragOver=4096]="PreventCollectionChangeOnDragOver",n[n.PreventZIndexOnDragging=8192]="PreventZIndexOnDragging",n[n.isGroupDragging=16384]="isGroupDragging",n[n.DragUsingMouse=32768]="DragUsingMouse",n[n.DecoratorPropertyChange=65536]="DecoratorPropertyChange",n[n.PreventLaneContainerUpdate=131072]="PreventLaneContainerUpdate",n}(ee||{}),Ga=function(n){return n[n.None=2]="None",n[n.DrawSelectorBorder=4]="DrawSelectorBorder",n[n.PreventRenderSelector=8]="PreventRenderSelector",n}(Ga||{}),$i=function(n){return n[n.None=0]="None",n[n.PreventDrag=2]="PreventDrag",n[n.PreventScale=4]="PreventScale",n[n.PreventDataInit=8]="PreventDataInit",n[n.hScrollbarMoved=16]="hScrollbarMoved",n[n.vScrollbarMoved=32]="vScrollbarMoved",n[n.AnimationClick=64]="AnimationClick",n[n.EnableGroupAction=128]="EnableGroupAction",n[n.PanInProgress=256]="PanInProgress",n[n.OverViewAction=512]="OverViewAction",n}($i||{}),da=function(n){return n[n.None=0]="None",n[n.PropertyChange=1024]="PropertyChange",n[n.Interaction=2048]="Interaction",n}(da||{}),Ae=function(n){return n[n.Zero=0]="Zero",n[n.One=1]="One",n[n.Two=2]="Two",n[n.Three=3]="Three",n[n.Four=4]="Four",n[n.Five=5]="Five",n}(Ae||{}),Ce=function(n){return n[n.collectionChange=0]="collectionChange",n[n.rotateChange=1]="rotateChange",n[n.positionChange=2]="positionChange",n[n.propertyChange=3]="propertyChange",n[n.selectionChange=4]="selectionChange",n[n.sizeChange=5]="sizeChange",n[n.drop=6]="drop",n[n.sourcePointChange=7]="sourcePointChange",n[n.targetPointChange=8]="targetPointChange",n[n.connectionChange=9]="connectionChange",n[n.animationComplete=10]="animationComplete",n[n.click=11]="click",n[n.doubleClick=12]="doubleClick",n[n.scrollChange=13]="scrollChange",n[n.dragEnter=14]="dragEnter",n[n.dragLeave=15]="dragLeave",n[n.dragOver=16]="dragOver",n[n.textEdit=17]="textEdit",n[n.paletteSelectionChange=18]="paletteSelectionChange",n[n.historyChange=19]="historyChange",n[n.mouseEnter=20]="mouseEnter",n[n.mouseLeave=21]="mouseLeave",n[n.mouseOver=22]="mouseOver",n[n.expandStateChange=23]="expandStateChange",n[n.segmentCollectionChange=24]="segmentCollectionChange",n[n.commandExecute=25]="commandExecute",n[n.historyStateChange=26]="historyStateChange",n[n.onUserHandleMouseDown=27]="onUserHandleMouseDown",n[n.onUserHandleMouseUp=28]="onUserHandleMouseUp",n[n.onUserHandleMouseEnter=29]="onUserHandleMouseEnter",n[n.onUserHandleMouseLeave=30]="onUserHandleMouseLeave",n[n.onImageLoad=31]="onImageLoad",n[n.onDoBindingInit=32]="onDoBindingInit",n[n.keyUp=33]="keyUp",n[n.keyDown=34]="keyDown",n[n.fixedUserHandleClick=35]="fixedUserHandleClick",n[n.elementDraw=36]="elementDraw",n[n.mouseWheel=37]="mouseWheel",n[n.segmentChange=38]="segmentChange",n[n.onFixedUserHandleMouseDown=39]="onFixedUserHandleMouseDown",n[n.onFixedUserHandleMouseUp=40]="onFixedUserHandleMouseUp",n[n.onFixedUserHandleMouseEnter=41]="onFixedUserHandleMouseEnter",n[n.onFixedUserHandleMouseLeave=42]="onFixedUserHandleMouseLeave",n[n.loaded=43]="loaded",n}(Ce||{}),oi=function(n){return n[n.None=1]="None",n[n.Drag=2]="Drag",n[n.Draw=4]="Draw",n[n.InConnect=8]="InConnect",n[n.OutConnect=16]="OutConnect",n[n.ToolTip=32]="ToolTip",n[n.InheritTooltip=64]="InheritTooltip",n[n.Default=24]="Default",n}(oi||{}),Ix=function(n){return n[n.None=1]="None",n[n.Source=2]="Source",n[n.Target=4]="Target",n[n.Intermediate=8]="Intermediate",n[n.All=14]="All",n}(Ix||{}),mI=function(n){return n[n.None=0]="None",n[n.SymmetricAngle=2]="SymmetricAngle",n[n.SymmetricDistance=4]="SymmetricDistance",n[n.Default=6]="Default",n}(mI||{}),hs=function(){function n(){this.pivot={x:.5,y:.5},this.isDirt=!0,this.isExport=!1,this.exportScaleValue={x:0,y:0},this.exportScaleOffset={x:0,y:0},this.canApplyStyle=!0,this.visible=!0,this.offsetX=0,this.offsetY=0,this.cornerRadius=0,this.minHeight=void 0,this.minWidth=void 0,this.maxWidth=void 0,this.maxHeight=void 0,this.width=void 0,this.height=void 0,this.rotateAngle=0,this.margin={left:0,right:0,top:0,bottom:0},this.connectionDirection="Auto",this.horizontalAlignment="Auto",this.verticalAlignment="Auto",this.flip="None",this.flipMode="All",this.relativeMode="Point",this.transform=Qa.Self|Qa.Parent,this.style={fill:"white",strokeColor:"black",opacity:1,strokeWidth:1},this.desiredSize=new me,this.actualSize=new me,this.parentTransform=0,this.preventContainer=!1,this.isSvgRender=!1,this.bounds=new Ne(0,0,0,0),this.shadow=null,this.description="",this.staticSize=!1,this.shapeType="",this.isRectElement=!1,this.isCalculateDesiredSize=!0,this.flipOffset={x:0,y:0},this.elementActions=Xr.None,this.inversedAlignment=!0,this.position=void 0,this.unitMode=void 0,this.float=!1,this.floatingBounds=void 0}return n.prototype.setOffsetWithRespectToBounds=function(t,e,i){this.unitMode=i,this.position={x:t,y:e}},n.prototype.getAbsolutePosition=function(t){if(void 0!==this.position)return"Absolute"===this.unitMode?this.position:{x:this.position.x*t.width,y:this.position.y*t.height}},Object.defineProperty(n.prototype,"outerBounds",{get:function(){return this.floatingBounds||this.bounds},set:function(t){this.floatingBounds=t},enumerable:!0,configurable:!0}),n.prototype.measure=function(t,e,i){var s=void 0!==this.height?this.height:(t.height||0)-this.margin.top-this.margin.bottom;return this.id&&0===s&&this.elementActions&Xr.HorizontalLaneHeader&&(s=this.actualSize.height),this.desiredSize=new me(void 0!==this.width?this.width:(t.width||0)-this.margin.left-this.margin.right,s),this.isCalculateDesiredSize&&(this.desiredSize=this.validateDesiredSize(this.desiredSize,t)),this.desiredSize},n.prototype.arrange=function(t){return this.actualSize=t,this.updateBounds(),this.actualSize},n.prototype.updateBounds=function(){this.bounds=yr(this)},n.prototype.validateDesiredSize=function(t,e){return this.isRectElement&&!this.width&&!this.minWidth&&!this.maxWidth&&(t.width=50),this.isRectElement&&!this.height&&!this.minHeight&&!this.maxHeight&&(t.height=50),(void 0===t||void 0!==this.width&&void 0!==this.height)&&((t=t||new me).width=void 0===this.width?(e.width||0)-this.margin.left-this.margin.right:this.width,t.height=void 0===this.height?(e.height||0)-this.margin.top-this.margin.bottom:this.height),void 0!==this.minWidth&&(t.width=Math.max(t.width,this.minWidth)),void 0!==this.minHeight&&(t.height=Math.max(t.height,this.minHeight)),void 0!==this.maxWidth&&0!==this.maxWidth&&(t.width=Math.min(t.width,this.maxWidth)),void 0!==this.maxHeight&&0!==this.maxHeight&&(t.height=Math.min(t.height,this.maxHeight)),t},n}(),Uie=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Cs=function(n){function t(){var e=null!==n&&n.apply(this,arguments)||this;return e.padding=new Oie(0,0,0,0),e.desiredBounds=void 0,e.measureChildren=!0,e.prevRotateAngle=0,e}return Uie(t,n),t.prototype.hasChildren=function(){return void 0!==this.children&&this.children.length>0},t.prototype.measure=function(e,i,r){this.desiredBounds=void 0;var o,a,s=void 0;if(this.hasChildren()){for(var l=0;l=n.width&&s.length>0)i[i.length]={text:s,x:0,dy:0,width:o},s="";else{(s+=a[r+1]||"").indexOf("\n")>-1&&(i[i.length]={text:s,x:0,dy:0,width:Bc(s,n)},s="");var l=Bc(s,n);Math.ceil(l)+2>=n.width&&s.length>0&&(i[i.length]={text:s,x:0,dy:0,width:l},s=""),r===a.length-1&&s.length>0&&(i[i.length]={text:s,x:0,dy:0,width:l},s="")}else i=function ooe(n,t,e){var c,d,u,f,i=[],r="",s=0,o=0,a="nowrap"!==n.whiteSpace,h=(t||n.content).split("\n");for(s=0;s0?" ":"")+c[parseInt(o.toString(),10)];var p=Bc(d=c[o+1]?r+" "+c[o+1]:r,n);Math.floor(p)>(e||n.width)-2&&r.length>0?(i[i.length]={text:r,x:0,dy:0,width:d===r?p:r===f?u:Bc(r,n)},r=""):o===c.length-1&&(i[i.length]={text:r,x:0,dy:0,width:p},r=""),f=d,u=p}return i}(n,t,e);else i[i.length]={text:a,x:0,dy:0,width:Bc(a,n)};return i}(l,r,n.isLaneOrientation?i:void 0),n.wrapBounds=a=function aoe(n,t){var r,s,e={x:0,width:0},i=0;for(i=0;in.width&&("Ellipsis"===n.textOverflow||"Clip"===n.textOverflow)?0:-r/2:"right"===n.textAlign?-r:t.length>1?0:-r/2,t[parseInt(i.toString(),10)].dy=1.2*n.fontSize,t[parseInt(i.toString(),10)].x=r,e.x=Math.min(e.x,r),e.width=Math.max(e.width,s);return e}(l,o),s.width=a.width,n.wrapBounds.width>=i&&"Wrap"!==l.textOverflow&&(s.width=i),s.height=o.length*n.style.fontSize*1.2,s}(this,0,0,this.isLaneOrientation?e.height:this.width||e.width):this.desiredSize,this.desiredSize=void 0===this.width||void 0===this.height?new me(i.width,i.height):new me(this.width,this.height),this.desiredSize=this.validateDesiredSize(this.desiredSize,e),this.desiredSize},t.prototype.arrange=function(e){return(e.width!==this.actualSize.width||e.height!==this.actualSize.height||this.isDirt)&&(this.doWrap=!0),this.actualSize=e,this.updateBounds(),this.isDirt=!1,this.actualSize},t}(hs),Vie=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Mi=function(n){function t(){var e=null!==n&&n.apply(this,arguments)||this;return e.measureChildren=void 0,e}return Vie(t,n),t.prototype.measure=function(e,i,r){var s=void 0,o=void 0;if(this.hasChildren()){for(var a=0,l=this.children;a=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Dd=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Xie(t,n),Oh([I("")],t.prototype,"content",void 0),Oh([I("TopLeft")],t.prototype,"position",void 0),Oh([I("Mouse")],t.prototype,"relativeMode",void 0),Oh([I(!0)],t.prototype,"showTipPointer",void 0),Oh([I("auto")],t.prototype,"width",void 0),Oh([I("auto")],t.prototype,"height",void 0),Oh([I("Auto")],t.prototype,"openOn",void 0),Oh([I()],t.prototype,"animation",void 0),Oh([I(!1)],t.prototype,"isSticky",void 0),t}(Ee);function e3(n){var t=new bh;t=t3(n.tooltip,t);var e=new bh(t);return e.beforeCollision=$ie,e.beforeOpen=qie,e.cssClass="e-diagram-tooltip",e.opensOn="custom",e.appendTo("#"+n.element.id),e.close(),e}function qie(n){(""===this.content||void 0===this.content)&&(n.element.style.display="none")}function $ie(n){n.collidedPosition&&n.collidedPosition!==this.position&&(n.element.style.display="none")}function bx(n,t){var e=n.tooltipObject;return t3(t?t.tooltip:n.tooltip,e),e}function t3(n,t){return n.content?(t.content=n.content,"string"==typeof n.content&&(t.content=ko(function(){return n.content})),t.position=n.position,t.showTipPointer=n.showTipPointer,t.width=n.width,t.height=n.height,t.animation=n.animation?n.animation:{close:{effect:"None"}}):t.close(),t}var Mx=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Bn=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},wx=function(n){function t(e,i,r,s){var o=n.call(this,e,i,r,s)||this;return o.inEdges=[],o.outEdges=[],o}return Mx(t,n),Bn([I("")],t.prototype,"id",void 0),Bn([I("Center")],t.prototype,"horizontalAlignment",void 0),Bn([I("Center")],t.prototype,"verticalAlignment",void 0),Bn([re({},Jn)],t.prototype,"margin",void 0),Bn([I(12)],t.prototype,"width",void 0),Bn([I(12)],t.prototype,"height",void 0),Bn([re({},Ll)],t.prototype,"style",void 0),Bn([I("Square")],t.prototype,"shape",void 0),Bn([I("Auto")],t.prototype,"connectionDirection",void 0),Bn([I(ci.Connect)],t.prototype,"visibility",void 0),Bn([I("")],t.prototype,"pathData",void 0),Bn([I(oi.Default)],t.prototype,"constraints",void 0),Bn([I()],t.prototype,"addInfo",void 0),Bn([I()],t.prototype,"outEdges",void 0),Bn([I()],t.prototype,"inEdges",void 0),Bn([re({},Dd)],t.prototype,"tooltip",void 0),t}(Ee),Es=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return Mx(t,n),t.prototype.getClassName=function(){return"PointPort"},Bn([re({x:.5,y:.5},R)],t.prototype,"offset",void 0),t}(wx),Tc=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return Mx(t,n),t.prototype.getClassName=function(){return"PathPort"},Bn([I(.5)],t.prototype,"offset",void 0),Bn([re({x:0,y:0},R)],t.prototype,"displacement",void 0),Bn([I("Center")],t.prototype,"alignment",void 0),t}(wx),II=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),hr=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Zie=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return II(t,n),hr([I("blue")],t.prototype,"color",void 0),hr([I("")],t.prototype,"content",void 0),hr([I("")],t.prototype,"link",void 0),hr([I("None")],t.prototype,"textDecoration",void 0),hr([I("NewTab")],t.prototype,"hyperlinkOpenState",void 0),t}(Ee),Cx=function(n){function t(e,i,r,s){var o=n.call(this,e,i,r,s)||this;return r.id||(o.id=e.parentObj&&e.parentObj.propName&&"phases"===e.parentObj.propName?e.parentObj.id:Qe()),o}return II(t,n),hr([I("")],t.prototype,"content",void 0),hr([I(void 0)],t.prototype,"template",void 0),hr([I("String")],t.prototype,"annotationType",void 0),hr([I(!0)],t.prototype,"visibility",void 0),hr([I(Nr.InheritReadOnly)],t.prototype,"constraints",void 0),hr([re(void 0,Zie)],t.prototype,"hyperlink",void 0),hr([I("")],t.prototype,"id",void 0),hr([I()],t.prototype,"width",void 0),hr([I()],t.prototype,"height",void 0),hr([I(0)],t.prototype,"rotateAngle",void 0),hr([I("Parent")],t.prototype,"rotationReference",void 0),hr([re({strokeWidth:0,strokeColor:"transparent",fill:"transparent"},Qf)],t.prototype,"style",void 0),hr([I("Center")],t.prototype,"horizontalAlignment",void 0),hr([I("Center")],t.prototype,"verticalAlignment",void 0),hr([re({},Jn)],t.prototype,"margin",void 0),hr([re({top:void 0,bottom:void 0,left:void 0,right:void 0},Jn)],t.prototype,"dragLimit",void 0),hr([I("Shape")],t.prototype,"type",void 0),hr([re({},Dd)],t.prototype,"tooltip",void 0),hr([I()],t.prototype,"addInfo",void 0),t}(Ee),Kn=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return II(t,n),t.prototype.getClassName=function(){return"ShapeAnnotation"},hr([re({x:.5,y:.5},R)],t.prototype,"offset",void 0),t}(Cx),Or=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return II(t,n),t.prototype.getClassName=function(){return"PathAnnotation"},hr([I(.5)],t.prototype,"offset",void 0),hr([re({x:0,y:0},R)],t.prototype,"displacement",void 0),hr([I("Center")],t.prototype,"alignment",void 0),hr([I(!1)],t.prototype,"segmentAngle",void 0),t}(Cx);function Ex(n){return tre[n.toString()]}function i3(n){return nre[""+n]}var tre={X:"M14,14 L106,106 M106,14 L14,106",Circle:"M0,50 A50,50,0 1 1 100,50 A50,50,0 1 1 0,50 Z",Square:"M0,0 L10,0 L10,10 L0,10 z"},ire={OpenArrow:"M15.9,23 L5,16 L15.9,9 L17,10.7 L8.7,16 L17,21.3Z",Square:"M0,0 L10,0 L10,10 L0,10 z",Fletch:"M14.8,10c0,0-3.5,6,0.2,12c0,0-2.5-6-10.9-6C4.1,16,11.3,16,14.8,10z",OpenFetch:"M6,17c-0.6,0-1-0.4-1-1s0.4-1,1-1c10.9,0,11-5,11-5c0-0.6,0.4-1,1-1s1,0.4,1,1C19,10.3,18.9,17,6,17C6,17,6,17,6,17z M18,23c-0.5,0-1-0.4-1-1c0-0.2-0.3-5-11-5c-0.6,0-1-0.5-1-1s0.4-1,1-1c0,0,0,0,0,0c12.9,0,13,6.7,13,7 C19,22.6,18.6,23,18,23z",IndentedArrow:"M17,10c0,0-4.5,5.5,0,12L5,16L17,10z",OutdentedArrow:"M14.6,10c0,0,5.4,6,0,12L5,16L14.6,10z",DoubleArrow:"M19,10 L19,22 L13,16Z M12,10 L12,22 L6,16Z",Arrow:"M15,10 L15,22 L5,16Z",Diamond:"M12,23l-7-7l7-7l6.9,7L12,23z",Circle:"M0,50 A50,50,0 1 1 100,50 A50,50,0 1 1 0,50 Z"},rre={Square:"M0,0 L10,0 L10,10 L0,10 z",Rhombus:"M10,5 L5,10 L0,5 L5,0 L10,5 Z ",Rectangle:"M0,0 L15,0 L15,10 L0,10 z ",OpenArrow:"M15.9,23 L5,16 L15.9,9 L17,10.7 L8.7,16 L17,21.3Z",Fletch:"M9.82,0 C9.82,0,6.61,5,10,10 C10,10,7.71,5,0,5 C0,5,6.61,5,9.82,0 Z ",OpenFetch:"M0.71,5.71 C0.29,5.71,0,5.43,0,5 C0,4.57,0.29,4.29,0.71,4.29 C8.5,4.29,8.57,0.71,8.57,0.71 C8.57,0.29,8.86,0,9.29,0 C9.719999999999999,0,10,0.29,10,0.71 C10,0.93,9.93,5.71,0.71,5.71 C0.71,5.71,0.71,5.71,0.71,5.71 Z M9.29,10 C8.93,10,8.57,9.71,8.57,9.29 C8.57,9.14,8.36,5.71,0.71,5.71 C0.29,5.71,0,5.36,0,5 C0,4.64,0.29,4.29,0.71,4.29 C0.71,4.29,0.71,4.29,0.71,4.29 C9.93,4.29,10,9.07,10,9.29 C10,9.71,9.71,10,9.29,10 Z ",IndentedArrow:"M10,0 C10,0,6.25,4.58,10,10 L0,5 L10,0 Z ",OutdentedArrow:"M8,0 C8,0,12.5,5,8,10 L0,5 L8,0 Z ",DoubleArrow:"M19,10 L19,22 L13,16Z M12,10 L12,22 L6,16Z",Arrow:"M15,10 L15,22 L5,16Z",Diamond:"M10,5 L5,10 L0,5 L5,0 L10,5 Z ",Circle:"M10,5 C10,7.76,7.76,10,5,10 C2.24,10,0,7.76,0,5 C0,2.24,2.24,0,5,0 C7.76,0,10,2.24,10,5 Z ",Ellipse:"M15,5 C15,7.76,11.64,10,7.5,10 C3.36,10,0,7.76,0,5 C0,2.24,3.36,0,7.5,0 C11.64,0,15,2.24,15,5 Z "},nre={Square:"M0,0 L10,0 L10,10 L0,10 z",Rhombus:"M10,5 L5,10 L0,5 L5,0 L10,5 Z ",Rectangle:"M0,0 L15,0 L15,10 L0,10 z",OpenArrow:"M23,15.9 L16,5 L9,15.9 L10.7,17 L16,8.7 L21,17.3Z",Fletch:"M9.82,0 C9.82,0,6.61,5,10,10 C10,10,7.71,5,0,5 C0,5,6.61,5,9.82,0 Z ",OpenFetch:"M0.71,5.71 C0.29,5.71,0,5.43,0,5 C0,4.57,0.29,4.29,0.71,4.29 C8.5,4.29,8.57,0.71,8.57,0.71 C8.57,0.29,8.86,0,9.29,0 C9.719999999999999,0,10,0.29,10,0.71 C10,0.93,9.93,5.71,0.71,5.71 C0.71,5.71,0.71,5.71,0.71,5.71 Z M9.29,10 C8.93,10,8.57,9.71,8.57,9.29 C8.57,9.14,8.36,5.71,0.71,5.71 C0.29,5.71,0,5.36,0,5 C0,4.64,0.29,4.29,0.71,4.29 C0.71,4.29,0.71,4.29,0.71,4.29 C9.93,4.29,10,9.07,10,9.29 C10,9.71,9.71,10,9.29,10 Z ",IndentedArrow:"M10,0 C10,0,6.25,4.58,10,10 L0,5 L10,0 Z ",OutdentedArrow:"M8,0 C8,0,12.5,5,8,10 L0,5 L8,0 Z ",DoubleArrow:"M10,19 L22,19 L16,13Z M10,12 L22,12 L16,6Z",Arrow:"M10,15 L22,15 L16,5Z",Diamond:"M10,5 L5,10 L0,5 L5,0 L10,5 Z ",Circle:"M10,5 C10,7.76,7.76,10,5,10 C2.24,10,0,7.76,0,5 C0,2.24,2.24,0,5,0 C7.76,0,10,2.24,10,5 Z ",Ellipse:"M15,5 C15,7.76,11.64,10,7.5,10 C3.36,10,0,7.76,0,5 C0,2.24,3.36,0,7.5,0 C11.64,0,15,2.24,15,5 Z "};function Dx(n){return sre[n.toString()]}var sre={Process:"M419.511,76.687L359.511,76.687L359.511,43.086L419.511,43.086z",Decision:"M 253.005,115.687L 200.567,146.071L 148.097,115.687L 200.534,85.304L 253.005,115.687 Z",Document:"M 60 31.9 c 0 0 -11 -7.7 -30 0 s -30 0 -30 0 V 0 h 60 V 31.9 Z",PreDefinedProcess:"M 0,0 L 50,0 L 50,50 L 0,50 Z M 8.334,0 L 8.334,50 M 41.667,0 L 41.667,50",Terminator:"M 269.711,29.33C 269.71,44.061 257.77,56 243.04,56L 158.058,56C 143.33,56 131.39,44.061 131.39,29.33L 131.39,29.33C 131.391,14.6057 143.33,2.669 158.058,2.669L 243.044,2.669C 257.772,2.669 269.711,14.6057 269.711,29.333 Z",PaperTap:"M0.0009,17.2042 L0.0009,47.165 C0.001,47.165 14.403,53.5455 25.00,47.165 C35.599,40.7852 44.403,43.5087 50.00,47.165L50.001,17.2042 M50.001,32.7987 L50.001,2.8405 C50.001,2.8405 35.599,-3.5427 25.001,2.8405C14.403,9.2237 5.599,6.494 0.0009,2.8405 L0.0009,32.7987",DirectData:"M 132.62 0 L 17.38 0 C 7.78 0 0 13.43 0 30 C 0 46.57 7.78 60 17.38 60 L 132.62 60 M 132.62 0C 123.02 0 115.24 13.43 115.24 30 C 115.24 46.57 123.02 60 132.62 60 C 142.22 60 150 46.57 150 30 C 150 13.43 142.22 0 132.62 0 z ",SequentialData:"M0.0029,24.999 C0.0029,11.1922 10.433,0.0021 23.295,0.0021 C36.159,0.00216 46.585,11.1922 46.585,24.999C46.585,38.8057 36.159,49.9979 23.295,49.9979 C10.433,49.9979 0.0029,38.8057 0.0029,24.999 z M23.294,49.999 L50.002,49.999",Sort:"M50.001,24.9971 L25.001,49.9971 L0.00097,24.9971 L25.001,-0.00286865 L50.001,24.9971 z M0.000976562,24.9971 L50.001,24.9971",MultiDocument:"M43.6826,40 C44.8746,40.6183 45.8586,41.3502 46.8366,42.1122 L46.8366,4.74487 L3.09857,4.74487 L3.09857,10.9544 M46.837,35.143 C48.027,35.765 49.025,36.604 50.003,37.369 L50.003,0.002 L6.264,0.002 L6.264,4.744 M43.682,47.113 L43.682,10.765 L0.0025,10.7652 L0.0025,47.1132 C0.0025,47.1132 12.5846,53.6101 21.8426,47.1132 C31.1006,40.6163 38.792,43.393 43.6826,47.1132 z",Collate:"M50.001,0.0028 L25.001,25.0029 L0.00097,0.0028 L50.001,0.002 z M0.0009,50.002 L25.001,25.002L50.001,50.002 L0.0009,50.0029 z",SummingJunction:"M7.3252,42.6768 L42.6772,7.3247 M42.6768,42.6768 L7.3248,7.3247 M0.0009,25.001 C0.0009,11.193 11.197,0.0009 25.001,0.0009 C38.809,0.0009 50.001,11.193 50.001,25.001 C50.001,38.809 38.809,50.001 25.001,50.001 C11.197,50.00 0.0009,38.809 0.0009,25.00 z",Or:"M 0 50 L 100 50 M 50 100 L 50 0.0 M 0 50 C 0 22.384 22.392 0 50 0 C 77.616 0 100 22.384 100 50 C 100 77.616 77.616 100 50 100 C 22.392 100 0 77.616 0 50 Z",InternalStorage:"M 0 3.81946A 2.5,3.81946 0 0,1 2.5,0L 47.5 0A 2.5,3.81946 0 0,1 50,3.81946L 50 45.836A 2.5,3.819446 0 0,1 47.5,49.652778L 2.5 49.652778A 2.5,3.819446 0 0,1 0,45.8336L 0 3.819446ZM 0 11.45834L 50 11.4583334M 12.5 0L 12.5 49.652778",Extract:"M0,35 L30,0 L60,35 Z",ManualOperation:"M46.4,28.8 L14.8,28.8 L0,0 L60,0 Z",Merge:"M60,0 L30,35 L0,0 Z",OffPageReference:"M60,33.3 L30.1,39 L0,33.3 L0,0 L60,0 Z",SequentialAccessStorage:"M 60 30 C 60 13.4 46.6 0 30 0 S 0 13.4 0 30 s 13.4 30 30 30 h 28.6 v -6.5 h -9.9C 55.5 48 60 39.5 60 30 Z",Annotation:"M49.9984,50.0029 L-0.00271199,50.0029 L-0.00271199,0.00286865 L49.9984,0.00286865",Annotation2:"M49.9977,50.0029 L25.416,50.0029 L25.416,0.00286865 L49.9977,0.00286865 M25.4166,25.0029 L-0.00227869,25.0029",Data:"M 10 0 L 40 0 L 30 40 L 0 40 Z",Card:"M275,60 L400,60 L400,110 L260,110 L260,75 Z",Delay:"M0,0 L12.029,0 C14.212999,0 16,1.7869979 16,3.9709952 C16,6.1549926 14.212999,7.9409904 12.029,7.9409904 L0,7.9409904 z",Preparation:"M 1048.17 572 C 1051.06 568.86 1055.17 567.05 1059.5 567 L 1094.51 567 C 1098.84 567.05 1102.95 568.86 1105.84 572 L 1126.43 595 C 1127.01 596.28 1127.01 597.72 1126.43 599 L 1105.84 622 C 1102.95 625.14 1098.84 626.95 1094.51 627 L 1059.5 627 C 1055.17 626.95 1051.06 625.14 1048.17 622 L 1027.58 599 C 1027 597.72 1027 596.28 1027.58 595 L 1048.17 572 Z",Display:"M47.8809,19.2914 L32.7968,-0.00594145 L11.3902,-0.00594145 C7.93166,-0.00594145 0.00124586,11.187 0.00124586,24.9968C0.00124586,38.8032 7.93166,49.9962 11.3902,49.9962 L32.7968,49.99 L47.615,31.038 C47.615,31.0388 52.798,24.9968 47.880,19.2914 z",ManualInput:"M 912 732 L 1006.85 707 C 1008.2 707 1009.5 707.53 1010.46 708.46 C 1011.41 709.4 1011.95 710.67 1011.95 712 L 1011.95 762C 1012 764.41 1010.28 766.52 1007.87 767 L 917.1 767 C 915.75 767 914.45 766.47 913.49 765.54 C 912.54 764.6 912 763.33 912 762 L 912 732 Z",LoopLimit:"M 8 9 L 27 9 L 33 15 L 33 26 C 33 27 33 27 32 27 L 4 27 C 3 27 2 27 2 26 L 2 15 L 8 9 Z",StoredData:"M 5.55 0L 50 0A 1.5,30 0 0,1 50,0A 5.555,25 0 0,0 50,50A 1.5,30 0 0,1 50,50L 5.555 50A 5.55,25 0 0,1 5.555,0Z"};function r3(n,t,e){var i;i="Straight"!==n.type&&n.sourceWrapper?n.sourceWrapper.corners.center:function ore(n){var t;if(n.sourcePortWrapper){var e=n.sourcePortWrapper;t={x:e.offsetX,y:e.offsetY}}else t=n.sourceID&&n.sourceWrapper&&n.targetWrapper?qa(n,0,n.sourceWrapper.corners.center,n.targetWrapper.corners.center,!1):n.sourcePoint;return t}(n);var r=function lre(n,t,e,i,r){var b,M,s=n.sourceWrapper,o=n.targetWrapper,a=n.sourcePortWrapper,l=n.targetPortWrapper,d=[],p=Xa(n),y={corners:undefined,point:t,direction:undefined,margin:{left:5,right:5,bottom:5,top:5}},S={corners:undefined,point:e,direction:undefined,margin:{left:5,right:5,bottom:5,top:5}};if(void 0!==s&&void 0!==o&&(b=xn(s),M=xn(o),y.corners=s.corners,S.corners=o.corners),void 0!==a&&(y.direction="Left"===a.connectionDirection||"Top"===a.connectionDirection||"Bottom"===a.connectionDirection||"Right"===a.connectionDirection?a.connectionDirection:zo({x:a.offsetX,y:a.offsetY},b,s.bounds)),void 0!==l&&(S.direction="Left"===l.connectionDirection||"Right"===l.connectionDirection||"Bottom"===l.connectionDirection||"Top"===l.connectionDirection?l.connectionDirection:zo({x:l.offsetX,y:l.offsetY},M,o.bounds)),"Bezier"===n.type&&!n.isBezierEditing&&n.segments.length>0)for(var D=n.segments.length-1;D>=0;)n.segments[parseInt(D.toString(),10)].isInternalSegment&&n.segments.pop(),D--;if(void 0!==s&&void 0!==o)return(void 0===y.direction||void 0===S.direction)&&(i?function are(n,t,e){"LeftToRight"===e?(n.direction=n.direction?n.direction:"Right",t.direction=t.direction?t.direction:"Left"):"RightToLeft"===e?(n.direction=n.direction?n.direction:"Left",t.direction=t.direction?t.direction:"Right"):"TopToBottom"===e?(n.direction=n.direction?n.direction:"Bottom",t.direction=t.direction?t.direction:"Top"):"BottomToTop"===e&&(n.direction=n.direction?n.direction:"Top",t.direction=t.direction?t.direction:"Bottom")}(y,S,i):y.corners.top>S.corners.bottom&&Math.abs(y.corners.top-S.corners.bottom)>p?(y.direction=y.direction?y.direction:"Top",S.direction=S.direction?S.direction:"Bottom"):y.corners.bottomp?(y.direction=y.direction?y.direction:"Bottom",S.direction=S.direction?S.direction:"Top"):y.corners.rightp||y.corners.right+p=y.corners.left-p&&y.corners.left>S.corners.left?(y.direction=y.direction?y.direction:"Right",S.direction=S.direction?S.direction:"Left"):y.corners.left>S.corners.right&&Math.abs(y.corners.left-S.corners.right)>y.margin.left+y.margin.right||S.corners.right+p=S.corners.left-p&&y.corners.left0&&n.segments[0].direction&&(y.direction=n.segments[0].direction),y.point=Nl(b,y.direction),d=Nl(b,_n(y.direction)),y.point=qa(n,0,y.point,d,!1)):y.point=o.corners.center;if(void 0!==h){switch(S.point={x:h.offsetX,y:h.offsetY},S.direction){case"Bottom":case"Top":S.point.y=S.point.y;break;case"Left":case"Right":S.point.x=S.point.x}n.targetPadding&&!w&&(S.point=bI(n,y,S,!0))}else"Orthogonal"===n.type||"Bezier"===n.type?(S.point=Nl(M,S.direction),d=Nl(M,_n(S.direction)),S.point=qa(n,0,S.point,d,!0)):S.point=a.corners.center;if("Orthogonal"!==n.type){var C=void 0,D=void 0;if("Bezier"===n.type){if(n.bezierSettings.allowSegmentsReset||0===n.segments.length||!R.isEmptyPoint(n.segments[n.segments.length-1].point))return c=f3(n,y,S,void 0,s),xx(n,y,S);Rv(n)}else Rv(n);if(void 0===n.sourcePortWrapper){y.point=y.corners.center,n.segments&&n.segments.length>0&&(C=R.isEmptyPoint((D=n.segments[0]).point)?void 0:D);var A=void 0!==C?C.point:S.point;if("Bezier"===n.type&&n.segments.length>0&&n.segments[0].vector1.angle&&n.segments[0].vector1.distance){var x=Math.max(y.corners.width,y.corners.height);A=R.transform(y.point,n.segments[0].vector1.angle,x/2)}y.point=w?n.sourceWrapper.bounds.center:qa(n,0,y.point,A,!1)}if(void 0===n.targetPortWrapper){S.point=S.corners.center,n.segments&&n.segments.length>1&&(C=R.isEmptyPoint((D=n.segments[n.segments.length-2]).point)?void 0:D);var P=C?C.point:y.point;"Bezier"===n.type&&n.segments.length>0&&n.segments[n.segments.length-1].vector2.angle&&n.segments[n.segments.length-1].vector2.distance&&(x=Math.max(y.corners.width,y.corners.height),P=R.transform(S.point,n.segments[0].vector2.angle,x/2)),S.point=w?n.targetWrapper.bounds.center:qa(n,0,P,S.point,!0)}c=xx(n,y,S)}else"Orthogonal"===n.type&&n.segments&&n.segments.length>0&&null!==n.segments[0].direction?c=function yre(n,t,e,i,r,s,o){var a,h,c,d;Rv(n);for(var u=0;u0&&n.segments[u-1].direction===h.direction?u=c3(n,u,t):h.direction?t.point=n3(t,n.segments[parseInt(u.toString(),10)]):(f=n.segments[u-1])&&f.points&&f.points.length>0&&(t.point=f.points[f.points.length-1]),u===n.segments.length-1)if(d3(n,t),l3(a=void 0===r?mre(n,t,e):o3(n,t,e),n),h.points=[],a.length>=2)for(c=0;c2&&n.segments.length>2){var p={x:a[parseInt(c.toString(),10)].x,y:t.point.y};h.points=[],h.points.push(p),h.points.push(a[parseInt(c.toString(),10)]);var f=n.segments[u-1];n.segments.length<4&&f.points.pop(),f.points=f.points.concat(h.points)}else h.points.push(a[parseInt(c.toString(),10)]);else h.points.push(a[parseInt(c.toString(),10)]);else d=u;if(void 0!==d&&!n.selectedSegmentIndex&&(d===n.segments.length-1&&(n.segments[d-1].direction=null,n.segments[d-1].length=null),n.segments.splice(d,1)),i&&0===u){var g=a3(n,i,s);g&&(t.point=g)}}return u3(n,[])}(n,y,S,l,h,o):(n.segments[0]||(C=new wi(n,"segments",{type:"Orthogonal"},!0),n.segments.push(C)),n.segments[0].points=c=f3(n,y,S,void 0,s));return c}(n,y.direction,S.direction,y.point,S.point,r);if(Rv(n),(n.sourceWrapper||n.targetWrapper)&&function fre(n,t,e){var i=n.sourcePortWrapper,r=n.targetPortWrapper,s=n.sourceWrapper,o=t.point,a={left:0,right:0,top:0,bottom:0},l={x:0,y:0},c="Top";if(s?(o=e.point,a=t.margin):(s=n.targetWrapper,a=e.margin),"Orthogonal"===n.type)if(n.segments&&n.segments.length>0&&n.sourceWrapper&&n.segments[0].direction)t.direction=n.segments[0].direction,l=qa(n,0,l=Nl(s.corners,t.direction),Nl(s.corners,_n(t.direction)),!1);else{var u={corners:null,direction:null,point:null,margin:null};Hv(s,{corners:null,direction:null,point:o,margin:a},u,n),l=u.point,c=u.direction}else{var f=void 0;n.segments&&n.segments.length>1&&(f=s===n.sourceWrapper?n.segments[0].point:n.segments[n.segments.length-2].point),l=qa(n,0,s.bounds.center,n.segments&&n.segments.length>1?f:o,s===n.targetWrapper)}s===n.sourceWrapper?(t.direction=t.direction||c,t.point=l,n.sourcePortWrapper&&(t.point={x:i.offsetX,y:i.offsetY},n.sourcePadding&&(t.point=bI(n,t,e,!1)))):(e.direction=e.direction||c,e.point=l,n.targetPortWrapper&&(e.point={x:r.offsetX,y:r.offsetY},n.targetPadding&&(e.point=bI(n,t,e,!0))))}(n,y,S),"Straight"===n.type||"Bezier"===n.type)d=xx(n,y,S);else if("Orthogonal"===n.type&&n.segments&&n.segments.length>0&&null!==n.segments[0].length&&null!==n.segments[0].direction)d=function ure(n,t,e,i,r,s,o){var a,l,c,u,h=[];if(Rv(n),n.segments.length>0){for(var f=0;f0&&n.segments[f-1].direction===p.direction)f=c3(n,f,t);else{var g=n.segments[f-1];t.point=p.direction?n3(t,p):g.points[g.points.length-1]}if(f===n.segments.length-1&&(o||r?n.targetWrapper&&void 0===n.targetPortWrapper?(d3(n,t),l=cre(n,t,e)):l=o3(n,t,e):l=hre(n,t,e),l))if(l3(l,n),p.points=[],l.length>=2)for(a=0;at.corners.top&&e.point.ye.point.x?"Left":"Right"):e.point.x>t.corners.left&&e.point.xe.point.y?"Top":"Bottom")),n.sourcePortWrapper&&s===_n(r)?(("Left"===s||"Right"===s)&&t.point.y>=t.corners.top&&t.point.y<=t.corners.center.y&&e.point.y>=t.corners.top&&e.point.y<=t.corners.center.y?(t.direction="Top",a=t.point.y-t.corners.top+20):("Left"===s||"Right"===s)&&t.point.y>t.corners.center.y&&t.point.y<=t.corners.bottom&&e.point.y>t.corners.center.y&&e.point.y<=t.corners.bottom?(t.direction="Bottom",a=t.corners.bottom-t.point.y+20):("Top"===s||"Bottom"===s)&&t.point.x>=t.corners.left&&t.point.x<=t.corners.center.x&&e.point.x>=t.corners.left&&e.point.x<=t.corners.center.x?(t.direction="Left",a=t.point.x-t.corners.left+20):("Top"===s||"Bottom"===s)&&t.point.x<=t.corners.right&&t.point.x>t.corners.center.x&&e.point.x<=t.corners.right&&e.point.xt.point.y&&t.point.y>=e.corners.top?(i="Top",r=t.point.y-e.corners.top+20):e.corners.center.y===t.point.y&&"Top"===n.segments[n.segments.length-2].direction||e.corners.center.ye.point.y?t.point.y-t.corners.top+20:t.corners.bottom-t.point.y+20):(i="Top",r=e.corners.height/2+20):e.corners.center.x!==t.point.x||e.corners.topt.point.x&&t.point.x>=e.corners.left?(i="Left",r=t.point.x-e.corners.left+20):e.corners.center.x===t.point.x&&"Left"===n.segments[n.segments.length-2].direction||e.corners.center.x<=t.point.x&&t.point.x<=e.corners.right?(i="Right",r=e.corners.right-t.point.x+20):void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&t.corners.left<=t.point.x&&t.point.x<=t.corners.right&&(i=t.direction,r=t.point.x>e.point.x?t.point.x-t.corners.left+20:t.corners.right-t.point.x+20):(i="Left",r=e.corners.width/2+20);var a=t.point;t.point=Fn(t.point,"Left"===i||"Top"===i?-r:r,"Left"===i||"Right"===i?0:90),t.direction=R.direction(t.point,e.point),void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&(t.corners.center.x===e.corners.center.x||t.corners.center.y===e.corners.center.y)&&(t.direction=e.direction);var l=Ys(n,t,e);return l.splice(0,0,a),l}function o3(n,t,e){var i,r;e.corners=n.targetWrapper.corners,void 0!==n.sourcePortWrapper&&(r=zo({x:n.sourcePortWrapper.offsetX,y:n.sourcePortWrapper.offsetY},xn(n.sourceWrapper),n.sourceWrapper.bounds));var a=function dre(n,t,e,i){var r=!1;switch(e.direction){case"Left":void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&"Right"===i&&t.point.x>e.point.x&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom||("Bottom"===i&&t.point.y>e.point.y||"Top"===i&&t.point.y=t.corners.left&&t.point.x<=t.corners.right?(t.direction="Right"===i?t.point.y>e.point.y?"Top":"Bottom":t.point.xe.point.x&&(t.point.y>e.point.y||t.point.yt.point.y&&e.corners.bottome.point.y||t.point.x>e.point.x&&t.point.y<=e.point.y&&e.corners.top=t.point.y?t.direction="Top":t.point.xe.point.x&&t.point.y>e.point.y&&e.corners.bottomt.point.y?t.direction="Bottom":t.point.y===e.point.y&&t.point.xe.point.y||"Top"===i&&t.point.ye.point.x&&t.point.x>=t.corners.left&&t.point.x<=t.corners.right?(t.direction=t.point.x>e.point.x?"Left":"Right",r=!0):void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&"Left"===i&&t.point.x=t.corners.top&&t.point.y<=t.corners.bottom?(t.direction=t.point.y>e.point.y?"Top":"Bottom",r=!0):t.point.x=t.point.y&&t.point.y===e.point.y||t.point.y>e.point.y&&t.point.x>e.point.x?t.direction="Top":t.point.ye.point.x?t.direction="Bottom":t.point.xe.point.y||t.point.ye.point.x&&(t.direction="Left");break;case"Top":void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&"Bottom"===i&&t.point.y>e.point.y&&t.point.x>=t.corners.left&&t.point.x<=t.corners.right||("Right"===i&&t.point.x>e.point.x||"Left"===i&&e.point.y>t.point.y&&e.point.x>t.point.x)&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom?(t.direction="Bottom"===i?t.point.x>e.point.x?"Left":"Right":t.point.ye.point.y&&t.point.x>e.corners.left&&t.point.x=e.point.y?t.direction="Top":t.point.ye.point.x?t.direction="Left":t.point.yt.point.x)&&t.point.y>e.point.y&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom||"Top"===i&&t.point.y=t.corners.left&&t.point.x<=t.corners.right)?(t.direction="Right"===i||"Left"===i?t.point.y>e.point.y?"Top":"Bottom":t.point.x>e.point.x?"Left":"Right",r=!0):t.point.ye.corners.left&&e.corners.right>t.point.x?t.point.ye.corners.left&&e.corners.center.x>=t.point.x?t.direction="Left":t.point.ye.point.y&&t.point.x>e.point.x?t.direction="Left":t.point.y>e.point.y&&t.point.xe.point.x||e.point.x>t.point.x)&&(t.direction="Bottom")}return r}(n,t,e,r);return!n.selectedSegmentIndex&&void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&e.direction===_n(r)&&(("Left"===e.direction&&t.point.x>e.point.x||"Right"===e.direction&&t.point.x=t.corners.top&&t.point.y<=t.corners.bottom||"Bottom"===e.direction&&t.point.y=t.corners.left&&t.point.x<=t.corners.right)?i=s3(n,t,e):n.selectedSegmentIndex||t.direction!==e.direction?!n.selectedSegmentIndex&&("Left"===e.direction&&t.point.x>e.point.x||"Right"===e.direction&&t.point.x=t.point.y||"Top"===e.direction&&t.point.y>e.point.y||"Bottom"===e.direction&&t.point.y=t.point.x?i=n.selectedSegmentIndex?Ol(t,e):s3(n,t,e):!n.selectedSegmentIndex&&void 0!==n.sourceWrapper&&void 0!==n.targetWrapper&&void 0!==n.targetPortWrapper&&("Left"===t.direction||"Right"===t.direction)&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom&&("Top"===e.direction||"Bottom"===e.direction)&&e.corners.center.x===t.corners.center.x?(t.direction="Top"===e.direction?"Bottom":"Top",i=Ys(n,t,e,"Top"===e.direction?t.corners.bottom-t.point.y+20:t.point.y-t.corners.top+20)):!n.selectedSegmentIndex&&void 0!==n.sourceWrapper&&void 0!==n.targetWrapper&&void 0!==n.targetPortWrapper&&("Top"===t.direction||"Bottom"===t.direction)&&t.point.x>=t.corners.left&&t.point.x<=t.corners.right&&("Left"===e.direction||"Right"===e.direction)&&e.corners.center.y===t.corners.center.y?(t.direction="Left"===e.direction?"Right":"Left",i=Ys(n,t,e,"Left"===e.direction?t.corners.right-t.point.x+20:t.point.x-t.corners.left+20)):i=a?Ys(n,t,e,"Left"===t.direction||"Right"===t.direction?"Left"===t.direction?t.point.x-t.corners.left+20:t.corners.right-t.point.x+20:"Top"===t.direction?t.point.y-t.corners.top+20:t.corners.bottom-t.point.y+20):Ol(t,e):i=Ys(n,t,e),i}function a3(n,t,e){var r,i={x:t.offsetX,y:t.offsetY},s=xn(e),o=zo(i,s,e.bounds),a=n.segments[0];return a.direction!==o&&(function Sre(n,t,e,i,r,s){var a,h,o=13,l=[];l.push(i),i.y===r.y&&("Left"===t&&r.xi.x)||i.x===r.x&&("Top"===t&&r.yi.y)||("Top"===t||"Bottom"===t?"Top"===t&&r.yi.y-o||"Bottom"===t&&r.y>i.y&&r.yo&&("Top"===t&&r.yi.y)?l.push({x:i.x,y:r.y}):(a=r.xi.x-o||"right"===t&&r.x>i.x&&r.xo&&("Left"===t&&r.xi.x)?l.push({x:r.x,y:i.y}):(l.push({x:a="Left"===t?e.left-o:e.right+o,y:i.y}),l.push({x:a,y:r.y})),s&&(l.push(n.points[0]),l.reverse()),n.points=l)}(a,o,s,a.points[0],a.points[a.points.length-1],!1),r=a.points[a.points.length-1],a.direction=R.direction(a.points[a.points.length-2],a.points[a.points.length-1])),r}function l3(n,t,e){var s,i=t.segments[t.segments.length-2],r=i.points[i.points.length-1];(("Top"===i.direction||"Bottom"===i.direction)&&r.x===n[1].x||("Left"===i.direction||"Right"===i.direction)&&r.y===n[1].y)&&(i.points[i.points.length-1]=n[1],s=R.direction(i.points[0],i.points[i.points.length-1]),void 0!==t.sourceWrapper&&void 0===t.sourcePortWrapper&&s===_n(i.direction)&&("Left"===i.direction||"Right"===i.direction?i.points[0].x="Right"===i.direction?i.points[0].x-t.sourceWrapper.corners.width:i.points[0].x+t.sourceWrapper.corners.width:i.points[0].y="Bottom"===i.direction?i.points[0].y-t.sourceWrapper.corners.height:i.points[0].y+t.sourceWrapper.corners.height),i.direction=s,i.length=R.distancePoints(i.points[0],i.points[i.points.length-1]),n.splice(0,1))}function bI(n,t,e,i){var o=i?n.targetPadding:n.sourcePadding,a=i?n.targetPortWrapper:n.sourcePortWrapper,l=new Ne(a.bounds.x-o,a.bounds.y-o,a.actualSize.width+2*o,a.actualSize.height+2*o),h=[l.topLeft,l.topRight,l.bottomRight,l.bottomLeft];h[h.length]=h[0];var d=i?e.point:t.point;return Ax({x1:t.point.x,y1:t.point.y,x2:e.point.x,y2:e.point.y},h,0,d)||d}function h3(n,t){var e=[],i=hF(0,n.corners,t);i.push(i[0]);for(var r=0;r0){var r=void 0,s=[],o=t.point;for(r=0;r1&&R.equals(a.points[0],a.points[1])&&n.segments.splice(r,1),a)for(var l=0;l0||0===r)&&i.push(a.points[parseInt(l.toString(),10)])}}return i}function Tx(n,t,e){return"Top"===n||"Bottom"===n?e.x>t.x?"Right":"Left":e.y>t.y?"Bottom":"Top"}function Rv(n){if("Straight"===n.type||"Bezier"===n.type){if(0===n.segments.length||n.segments.length>0&&!R.isEmptyPoint(n.segments[n.segments.length-1].point))if("Bezier"===n.type){var t=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0},!0);n.segments.push(t)}else t=new Hl(n,"segments",{type:"Straight"},!0),n.segments.push(t)}else{if(n.segments.length>0)for(var e=!1,i=0;i=t.corners.left&&e.point.x<=t.corners.right&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom)t.direction=e.point.y>t.point.y?"Bottom":"Top",i=Ys(n,t,e,"Top"===t.direction?t.point.y-t.corners.top+20:t.corners.bottom-t.point.y+20);else if(n.sourcePortWrapper&&r===_n(o)){var h;("Left"===r||"Right"===r)&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom?(t.direction=e.point.y>t.point.y?"Bottom":"Top",h=t.corners.height/2+20):("Top"===r||"Bottom"===r)&&t.point.x>=t.corners.left&&t.point.x<=t.corners.right&&(t.direction=e.point.x>t.point.x?"Right":"Left",h=t.corners.width/2+20),t.direction&&h?i=Ys(n,t,e,h,!0):(t.direction=o,i=Ol(t,e))}else if(!n.sourcePortWrapper||r!==e.direction||"Top"!==r&&"Bottom"!==r||t.corners.center.x!==e.corners.center.x)if(t.direction===e.direction)if(("Left"===t.direction||"Right"===t.direction)&&e.point.y>t.corners.top-20&&e.point.yt.corners.left-20&&e.point.xt.point.y?"Bottom":"Top",i=Ys(n,t,e,"Bottom"===t.direction?t.corners.bottom-t.point.y+20:t.point.y-t.corners.top+20);else t.direction=o,i=Ys(n,t,e,"Top"===o||"Bottom"===o?n.sourceWrapper.height/2+20:n.sourceWrapper.width/2+20),t.point=i[1],"Left"===o||"Right"===o?(e.direction=o,e.point="Left"===o?e.corners.middleLeft:e.corners.middleRight):Hv(n.targetWrapper,t,e,n),i=Ys(n,t,e);return i}function d3(n,t){if(void 0!==n.targetWrapper&&void 0===n.targetPortWrapper&&xn(n.targetWrapper).containsPoint(t.point,1)){var i=n.targetWrapper,r=n.segments[n.segments.length-2],s=r.points[r.points.length-1],o=_n(r.direction);"Bottom"===o?s.yi.corners.top-1&&(r.points[r.points.length-1].y=i.corners.top-20,r.length=R.distancePoints(r.points[0],r.points[r.points.length-1])):"Left"===o?s.x>i.corners.left-1&&(r.points[r.points.length-1].x=i.corners.left-20,r.length=R.distancePoints(r.points[0],r.points[r.points.length-1])):"Right"===o&&s.x0||0===e)&&t.push(i.points[parseInt(r.toString(),10)]);return t}function Hv(n,t,e,i){var r,s={x:0,y:0},o=MI(n,n.corners,n.bounds),a=t.margin,l=t.point;if(o.bottomCenter.y+a.bottoml.y)r="Top",s=o.topCenter;else if(o.middleLeft.x-a.left>l.x)r="Left",s=o.middleLeft;else if(o.middleRight.x+a.rightc&&(f=c,r="Right",s=o.middleRight),f>d&&(f=d,r="Bottom",s=o.bottomCenter),f>u&&(r="Left",s=o.middleLeft)}e.point=s,e.direction=r;var p=Nl(o,_n(e.direction));e.point=qa(i,0,e.point,p,n===i.targetWrapper)}function f3(n,t,e,i,r){var s,o,a;if(s=function kre(n,t){var e=!1;switch(n){case"Left":switch(t){case"Right":case"Bottom":e=!0}break;case"Top":switch(t){case"Left":case"Right":case"Bottom":e=!0}break;case"Bottom":"Right"===t&&(e=!0)}return e}(t.direction,e.direction),s&&S3(t,e),"Right"===t.direction&&"Left"===e.direction)a=function Ire(n,t,e,i){var o=Math.round(Math.abs(t.point.y-e.point.y)),a={x:Math.max(t.point.x,t.corners.right),y:t.point.y},l={x:Math.min(e.point.x,e.corners.left),y:e.point.y},h=Xa(n);if(i){var c=l;l=a,a=c}return t.corners.bottom+he.corners.bottom+h||("Bezier"!==n.type||e.corners.left-t.corners.right<=2*h&&e.corners.left-t.corners.right>=5)&&(h=0),t.margin={left:h,right:h,top:h,bottom:h},e.margin={left:h,right:h,top:h,bottom:h},0===o&&(t.corners.right=e.corners.right?void 0!==i&&(i.offsetYe.corners.bottom+e.margin.bottom)||void 0===i&&t.corners.middleRight.ye.corners.bottom+e.margin.bottom&&t.corners.top>e.corners.bottom||void 0===i&&t.corners.middleRight.y>e.corners.bottom||void 0!==i&&i.offsetYe.corners.top||void 0===i&&t.corners.middleRight.y>e.corners.bottom?Ae.Three:t.corners.rightr.offsetY+e.margin.right||void 0===r&&t.corners.top>e.corners.middleRight.y||void 0!==r&&(void 0!==i&&i.offsetXr.offsetX||void 0===r&&t.corners.left>e.corners.topCenter.x?Ae.Four:Ae.Two:void 0!==s&&Math.abs(t.corners.right-e.corners.left)<=5&&Math.abs(s.offsetY-e.corners.top)<=5||void 0!==r&&t.corners.right=25&&t.corners.middleRight.y+t.margin.righte.corners.bottom+e.margin.bottom||void 0===o&&t.corners.middleRight.y>e.corners.bottom+e.margin.bottom?t.corners.top>e.corners.bottom?void 0!==a&&t.corners.right+t.margin.righta.offsetX||void 0===a&&t.corners.left>e.corners.bottomCenter.x?Ae.Four:Ae.Two:void 0!==o&&Math.abs(t.corners.right-e.corners.left)<=25&&Math.abs(o.offsetY-e.corners.bottom)<=25?Ae.Two:Ae.Four}(n,t,e,s);else if("Bottom"===t.direction&&"Top"===e.direction)a=function Cre(n,t,e){var r=t.point.x-e.point.x,s=Xa(n);return t.corners.right+se.corners.right+s||("Bezier"!==n.type||e.corners.top-t.corners.bottom<=2*s&&e.corners.top-t.corners.bottom>=5)&&(s=0),t.margin={left:s,right:s,top:s,bottom:s},e.margin={left:s,right:s,top:s,bottom:s},0===r&&t.corners.bottome.corners.right+e.margin.right||void 0===i&&t.corners.bottomCenter.x>e.corners.right+e.margin.right?Ae.Three:t.corners.bottomr.offsetX||void 0===r&&t.corners.left>e.corners.left||void 0!==r&&t.corners.right+t.margin.righte.corners.bottom?Ae.Five:0===s||0===o?Ae.One:Ae.Three}(n,t,e)}else"Bottom"===t.direction&&"Left"===e.direction?a=function Ere(n,t,e,i){var r=n.sourcePortWrapper,s=n.targetPortWrapper,o=Xa(n);if(e.margin={left:o,right:o,top:o,bottom:o},t.margin={top:o,bottom:o,left:o,right:o},i){var l=r;r=s,s=l}return void 0!==r&&r.offsetXs.offsetY||void 0===s&&t.corners.top>e.corners.middleLeft.y?Ae.Four:Ae.Two:void 0!==s&&Math.abs(t.corners.right-e.corners.left)<=25&&Math.abs(s.offsetY-t.corners.bottom)<=25?Ae.Two:Ae.Four}(n,t,e,s):"Left"===t.direction&&"Left"===e.direction?a=function Tre(n,t,e){var i=n.sourcePortWrapper,r=n.targetPortWrapper,s=Xa(n);t.margin={left:s,right:s,top:s,bottom:s},e.margin={left:s,right:s,top:s,bottom:s};var o=Math.round(Math.abs(t.point.x-e.point.x)),a=Math.round(Math.abs(t.point.y-e.point.y));return t.corners.leftr.offsetY||void 0===r&&t.corners.top-t.margin.top>e.corners.middleLeft.y?Ae.Three:t.corners.righte.corners.bottom+e.margin.bottom||void 0===i&&t.corners.middleLeft.y>e.corners.bottom+e.margin.bottom?Ae.Three:t.corners.left>e.corners.right?Ae.Five:0===o||0===a?Ae.One:Ae.Three}(n,t,e):"Left"===t.direction&&"Top"===e.direction?a=function xre(n,t,e,i){var s=n.sourcePortWrapper,o=Xa(n);e.margin={left:o,right:o,top:o,bottom:o},t.margin={top:o,bottom:o,left:o,right:o};var a=n.targetPortWrapper,l={x:Math.min(t.point.x,t.corners.left),y:t.point.y},h={x:e.point.x,y:Math.min(e.point.y,e.corners.top)};if(i){var c=s;s=a,a=c;var d=l;l=h,h=d}return void 0!==s&&s.offsetYa.offsetX||void 0===a&&t.corners.left-t.margin.left>e.corners.topCenter.x?Ae.Two:Ae.Four:void 0!==a&&t.corners.rightr.offsetX||void 0===r&&t.corners.left>e.corners.left||void 0!==r&&t.corners.right+t.margin.righte.corners.right+e.margin.right||void 0===i&&t.corners.left>e.corners.right||void 0!==i&&i.offsetXe.corners.bottom?Ae.Five:0===s||0===o?Ae.One:Ae.Three}(n,t,e));return s&&S3(t,e),o=function Lre(n,t,e,i,r,s){var l,d,h=n.sourceWrapper.corners,c=n.targetWrapper.corners,u=20,f={corners:e.corners,point:e.point,direction:e.direction,margin:e.margin},p={corners:i.corners,point:i.point,direction:i.direction,margin:i.margin};if(!(f.direction===p.direction&&t!==Ae.Five||f.direction!==_n(p.direction)&&t!==Ae.Three))switch(f.direction){case"Left":h.middleLeft.x>c.middleRight.x&&(d=(h.middleLeft.x-c.middleRight.x)/2,u=s?d:Math.min(u,d));break;case"Right":h.middleRight.xc.bottomCenter.y&&(d=(h.topCenter.y-c.bottomCenter.y)/2,u=s?d:Math.min(u,d));break;case"Bottom":h.bottomCenter.yf&&hf)&&o>c&&o<=d&&e>=20&&(s=n.point.x-t.corners.left+s),i&&n.direction===t.direction&&n.corners.left>t.corners.left&&n.corners.left-t.corners.right>=20&&(s=(n.corners.left-t.corners.right)/2),p=Fn(n.point,s,180);break;case"Top":(o>c&&oc)&&h>f&&h<=u&&e>=20&&(s=n.point.y-t.corners.top+s),i&&n.direction===t.direction&&n.corners.top>t.corners.top&&n.corners.top-t.corners.bottom>=20&&(s=(n.corners.top-t.corners.bottom)/2),p=Fn(n.point,s,270);break;case"Right":(h>f&&hf)&&a=c&&e>=20&&(s=t.corners.right-n.point.x+s),i&&n.direction===t.direction&&n.corners.right=20&&(s=(t.corners.left-n.corners.right)/2),p=Fn(n.point,s,0);break;case"Bottom":(o>c&&oc)&&l=f&&e>=20&&(s=t.corners.bottom-n.point.y+s),i&&n.direction===t.direction&&n.corners.bottom=20&&(s=(t.corners.top-n.corners.bottom)/2),p=Fn(n.point,s,90)}r=[n.point,p];var g=void 0;if("Top"===n.direction||"Bottom"===n.direction){var v=n.direction;n.direction=p.x>t.point.x?"Left":"Right",n.point=p,r=wI(n,t,v,r,g=i?.5*Math.abs(p.x-t.point.x):g,i)}else v=n.direction,n.direction=p.y>t.point.y?"Top":"Bottom",n.point=p,r=wI(n,t,v,r,g=i?.5*Math.abs(p.y-t.point.y):g,i);return r}(f,p,u,g)),l}(n,a,t,e,i,r),"Bezier"===n.type&&function Ore(n,t,e){if("Bezier"===n.type)if(0===n.segments.length){var i=e[0],r=e[e.length-1];if(t===Ae.One){var s=Math.min(20,.5*R.findLength(i,r)),o={angle:Gt(i,r),distance:s},a={angle:Gt(r,i),distance:s},l=R.direction(i,r),c=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,orientation:"Left"===l||"Right"===l?"Horizontal":"Vertical"},!0);n.segments.push(c)}else if(t===Ae.Two)o={angle:Gt(i,d=e[1]),distance:.5*R.findLength(i,d)},a={angle:Gt(r,d),distance:.5*R.findLength(r,d)},l=R.direction(i,d),c=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,orientation:"Left"===l||"Right"===l?"Horizontal":"Vertical"},!0),n.segments.push(c);else if(t===Ae.Three){var d={x:.5*((u=e[1]).x+(f=e[e.length-2]).x),y:.5*(u.y+f.y)},p=(o={angle:Gt(i,u),distance:.5*R.findLength(i,u)},a={angle:Gt(d,u),distance:.5*R.findLength(d,u)},R.direction(i,u)),v=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,point:d,orientation:"Left"===p||"Right"===p?"Horizontal":"Vertical"},!0);n.segments.push(v);var y={angle:Gt(d,f),distance:.5*R.findLength(d,f)},S={angle:Gt(r,f),distance:.5*R.findLength(r,f)},b=R.direction(d,f),w=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:y,vector2:S,orientation:"Left"===b||"Right"===b?"Horizontal":"Vertical"},!0);n.segments.push(w)}else if(t===Ae.Four){var D={x:.5*((u=e[1]).x+(f=e[2]).x),y:.5*(u.y+f.y)},A={x:.5*(f.x+(C=e[3]).x),y:.5*(f.y+C.y)};o={angle:Gt(i,u),distance:.5*R.findLength(i,u)},a={angle:Gt(D,u),distance:.5*R.findLength(D,u)},p=R.direction(i,u),v=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,point:D,orientation:"Left"===p||"Right"===p?"Horizontal":"Vertical"},!0),n.segments.push(v),y={angle:Gt(D,f),distance:.5*R.findLength(D,f)},S={angle:Gt(A,f),distance:.5*R.findLength(A,f)},b=R.direction(D,f),w=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:y,vector2:S,point:A,orientation:"Left"===b||"Right"===b?"Horizontal":"Vertical"},!0),n.segments.push(w);var x={angle:Gt(A,C),distance:.5*R.findLength(A,C)},P={angle:Gt(r,C),distance:.5*R.findLength(r,C)},L=R.direction(A,C),N=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:x,vector2:P,orientation:"Left"===L||"Right"===L?"Horizontal":"Vertical"},!0);n.segments.push(N)}else if(t===Ae.Five){var u,f,C,T=e[4],z=(D={x:.5*((u=e[1]).x+(f=e[2]).x),y:.5*(u.y+f.y)},A={x:.5*(f.x+(C=e[3]).x),y:.5*(f.y+C.y)},{x:.5*(C.x+T.x),y:.5*(C.y+T.y)});o={angle:Gt(i,u),distance:.5*R.findLength(i,u)},a={angle:Gt(D,u),distance:.5*R.findLength(D,u)},p=R.direction(i,u),v=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,point:D,orientation:"Left"===p||"Right"===p?"Horizontal":"Vertical"},!0),n.segments.push(v),y={angle:Gt(D,f),distance:.5*R.findLength(D,f)},S={angle:Gt(A,f),distance:.5*R.findLength(A,f)},b=R.direction(D,f),w=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:y,vector2:S,point:A,orientation:"Left"===b||"Right"===b?"Horizontal":"Vertical"},!0),n.segments.push(w),x={angle:Gt(A,C),distance:.5*R.findLength(A,C)},P={angle:Gt(z,C),distance:.5*R.findLength(z,C)},L=R.direction(A,C),N=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:x,vector2:P,point:z,orientation:"Left"===L||"Right"===L?"Horizontal":"Vertical"},!0),n.segments.push(N);var U={angle:Gt(z,T),distance:.5*R.findLength(z,T)},B={angle:Gt(r,T),distance:.5*R.findLength(r,T)},j=R.direction(z,T),oe=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:U,vector2:B,orientation:"Left"===j||"Right"===j?"Horizontal":"Vertical"},!0);n.segments.push(oe)}else c=new fs(n,"segments",{type:"Bezier"},!0),n.segments.push(c)}else for(var ue=0;ue=13?13:n.connectorSpacing<=1?1:n.connectorSpacing}function Gt(n,t){var i=R.findLength({x:t.x,y:n.y},t),r=R.findLength(t,n),s=Math.asin(i/r);return s=180*s/Math.PI,n.xt.y&&(s=360-s):s=n.y0)for(var l=1;lc)&&(s=c,a=h),s>=0&&s<=1)break}}return a}function g3(n,t){var c,d,u,f,p,g,S,b,M,w,D,e=n.x1,i=n.y1,r=n.x2,s=n.y2,o=t.x1,a=t.y1,l=t.x2,h=t.y2;if(w=(c=s-i)*l+(u=e-r)*h+(p=r*i-e*s),0!==(M=c*o+u*a+p)&&0!==w&&v3(M,w)||(b=(d=h-a)*r+(f=o-l)*s+(g=l*a-o*h),0!==(S=d*e+f*i+g)&&0!==b&&v3(S,b)))return null;var A=c*f-d*u;return 0===A?null:(A<0?-A/2:A/2,0,{x:(D=u*g-f*p)<0?(D-0)/A:(D+0)/A,y:(D=d*p-c*g)<0?(D-0)/A:(D+0)/A})}function v3(n,t){return n*t>=0}function m3(n,t,e){switch(t.direction){case"Left":t.point.x>n.left&&(e=t.point.x-n.left>e?t.point.x-n.left+e:e);break;case"Right":t.point.xe?n.right-t.point.x+e:e);break;case"Top":t.point.y>n.top&&(e=t.point.y-n.top>e?t.point.y-n.top+e:e);break;case"Bottom":t.point.ye?n.bottom-t.point.y+e:e)}return e}function Ol(n,t){var e;switch(n.direction){case"Left":case"Right":var i={x:t.point.x,y:n.point.y};e=R.equals(n.point,i)||R.equals(t.point,i)?[n.point,t.point]:[n.point,i,t.point];break;case"Top":case"Bottom":var r={x:n.point.x,y:t.point.y};e=R.equals(n.point,r)||R.equals(t.point,r)?[n.point,t.point]:[n.point,r,t.point]}return e}function Ys(n,t,e,i,r,s){void 0===s&&(s=!1),i||(i=20),s&&t.direction!==e.direction&&(i="Left"===t.direction||"Right"===t.direction?Math.floor(.5*Math.abs(t.point.x-e.point.x)):Math.floor(.5*Math.abs(t.point.y-e.point.y)));var l,h,u,o=n.sourcePortWrapper,c=e.point.x-t.point.x,d=e.point.y-t.point.y;if(!r&&(Math.abs(c)<.001||Math.abs(d)<.001)&&void 0===e.direction)return[t.point,e.point];if(void 0===n.targetWrapper&&Math.abs(c)<=31&&Math.abs(d)<=31){if("Left"===t.direction||"Right"===t.direction?Math.abs(d)<12&&(t.direction=t.point.y>e.point.y?"Top":"Bottom"):Math.abs(c)<12&&(t.direction=t.point.x>e.point.x?"Left":"Right"),Math.abs(c)>12||Math.abs(d)>12)return Ol(t,e);i+=5}return"Left"===t.direction||"Right"===t.direction?("Right"===t.direction?(void 0!==e.direction&&"Right"===e.direction&&(i=Math.max(t.point.x,e.point.x)-t.point.x+i),t.point.x>e.point.x&&void 0===o&&(i=-i)):(void 0!==e.direction&&"Left"===e.direction&&(i=t.point.x-Math.min(t.point.x,e.point.x)+i),(t.point.x>e.point.x||void 0!==o||"Left"===t.direction)&&(i=-i)),u=e.point.y-t.point.y,l=Fn(t.point,i,0),0!=(u=e.point.y-l.y)&&(h=Fn(l,e.point.y-l.y,90))):("Top"===t.direction||"Bottom"===t.direction)&&("Bottom"===t.direction?void 0!==e.direction&&"Bottom"===e.direction&&(i=Math.max(t.point.y,e.point.y)-t.point.y+i):(void 0!==e.direction&&"Top"===e.direction&&(i=t.point.y-Math.min(t.point.y,e.point.y)+i),(t.point.y>e.point.y||void 0!==o||"Top"===t.direction)&&(i=-i)),u=e.point.x-t.point.x,l=Fn(t.point,i,90),0!=(u=e.point.x-l.x)&&(h=Fn(l,e.point.x-l.x,0))),0===u?[t.point,e.point]:[t.point,l,h,e.point]}function wI(n,t,e,i,r,s){var o;switch(void 0===r&&(r=20),void 0===s&&(s=!1),void 0===e?(n.margin={left:2,right:2,top:2,bottom:2},t.margin={left:0,right:5,top:0,bottom:5},s&&(n.margin={left:10,right:10,top:10,bottom:10},t.margin={left:10,right:10,top:10,bottom:10},"Left"===n.direction?(r=Nx(n,t,e,r),n.corners.left-t.corners.right>=5&&(r=Math.abs(n.point.x-n.corners.left)+.5*Math.floor(n.corners.left-t.corners.right))):"Right"===n.direction?(r=Ox(n,t,r,e),t.corners.left-n.corners.right>=5&&(r=Math.abs(n.point.x-n.corners.right)+.5*Math.floor(t.corners.left-n.corners.right))):"Top"===n.direction?(r=Lx(n,t,e,r),n.corners.top-t.corners.bottom>=5&&(r=Math.abs(n.point.y-n.corners.top)+.5*Math.floor(n.corners.top-t.corners.bottom))):"Bottom"===n.direction&&(r=kx(n,t,r,e),t.corners.top-n.corners.bottom>=5&&(r=Math.abs(n.point.y-n.corners.bottom)+.5*Math.floor(t.corners.top-n.corners.bottom))))):("Bottom"===n.direction?s?t.corners.top-n.corners.bottom<20&&(r=t.corners.bottom-n.point.y+25):t.corners.top>n.corners.bottom&&t.corners.top-n.corners.bottom<20&&(r=(t.corners.top-n.corners.bottom)/2):"Top"===n.direction?s?n.corners.top-t.corners.bottom<20&&(r=n.point.y-t.corners.top+25):t.corners.bottomn.corners.right&&t.corners.left-n.corners.right<20&&(r=(t.corners.left-n.corners.right)/2):"Left"===n.direction&&(s?n.corners.left-t.corners.right<20&&(r=n.point.x-t.corners.left+25):t.corners.rightt.point.y||"Top"===t.direction&&n.point.yt.point.x||"Left"===t.direction&&n.point.xh||e.corners.top-e.margin.top<=i.point.y&&e.corners.bottom+e.margin.bottom>=i.point.y))if(!s||"Top"!==e.direction&&"Bottom"!==e.direction)c=Math.min(Math.abs(i.corners.left-e.corners.right)/2,20),h=e.corners.right-n.x+c;else{var c=Math.abs(i.corners.left-e.corners.right)/2;h=e.corners.right-n.x+c}else h="Top"===e.direction&&n.y>i.point.y||"Bottom"===e.direction&&n.y=e.corners.left-e.margin.left&&n.x<=e.corners.right+e.margin.right?Math.min(i.corners.left,e.corners.left)-n.x-20:i.corners.left-n.x-20;break;case"Right":if(e.corners.left-e.margin.left>i.corners.right+i.margin.right&&(e.corners.left-e.margin.right-i.corners.right>h||e.corners.top-e.margin.top<=i.point.y&&e.corners.bottom+e.margin.bottom>=i.point.y))if(!s||"Top"!==e.direction&&"Bottom"!==e.direction)c=Math.min(Math.abs(e.corners.left-i.corners.right)/2,20),h=e.corners.left-n.x-c;else{c=Math.abs(e.corners.left-i.corners.right)/2;h=e.corners.left-n.x-c}else h="Top"===e.direction&&n.y>i.point.y||"Bottom"===e.direction&&n.y=e.corners.left-e.margin.left&&n.x<=e.corners.right+e.margin.right?Math.max(i.corners.right,e.corners.right)-n.x+20:i.corners.right-n.x+20}o=Fn(n,h,0),a=Fn(o,i.point.y-n.y,90),l=i.point}else if("vertical"===t){switch(i.direction){case"Top":e.corners.bottom+e.margin.bottomh||e.corners.left-e.margin.left<=i.point.x&&e.corners.right+e.margin.right>=i.point.x)?!s||"Right"!==e.direction&&"Left"!==e.direction?(c=Math.min(Math.abs(i.corners.top-e.corners.bottom)/2,20),h=e.corners.bottom-n.y+c):(c=Math.abs(i.corners.top-e.corners.bottom)/2,h=e.corners.bottom-n.y+c):h="Left"===e.direction&&n.x>i.point.x||"Right"===e.direction&&n.x=e.corners.top-e.margin.top&&n.y<=e.corners.bottom+e.margin.bottom?Math.min(i.corners.top,e.corners.top)-n.y-20:i.corners.top-n.y-20;break;case"Bottom":e.corners.top-e.margin.top>i.corners.bottom+i.margin.bottom&&(e.corners.top-e.margin.top-i.corners.bottom>h||e.corners.left-e.margin.left<=i.point.x&&e.corners.right+e.margin.right>=i.point.x)?!s||"Right"!==e.direction&&"Left"!==e.direction?(c=Math.min(Math.abs(e.corners.top-i.corners.bottom)/2,20),h=e.corners.top-n.y-c):(c=Math.abs(e.corners.top-i.corners.bottom)/2,h=e.corners.top-n.y-c):h="Left"===e.direction&&n.x>i.point.x||"Right"===e.direction&&n.x=e.corners.top-e.margin.top&&n.y<=e.corners.bottom+e.margin.bottom?Math.max(i.corners.bottom,e.corners.bottom)-n.y+20:i.corners.bottom-n.y+20}o=Fn(n,h,90),a=Fn(o,i.point.x-n.x,0),l=i.point}r.push(o),r.push(a),r.push(l)}function Lx(n,t,e,i){return n.corners.top-n.margin.top>t.corners.top+t.margin.top&&n.corners.top-n.margin.top<=t.corners.bottom+t.margin.bottom?(("Right"===t.direction&&n.point.xt.point.x)&&(i+=n.corners.top-t.corners.top),i+=n.point.y-n.corners.top):i+=void 0!==e&&"Left"!==e&&"Right"===t.direction&&n.point.xt.corners.left-t.margin.left&&n.corners.left-n.margin.left<=t.corners.right+t.margin.right?(("Bottom"===t.direction&&n.point.yt.point.y)&&(i+=n.corners.left-t.corners.left),i+=n.point.x-n.corners.left):i+=void 0!==e&&"Top"!==e&&"Bottom"===t.direction&&n.point.y=t.corners.left-t.margin.left?(("Bottom"===t.direction&&n.point.yt.point.y)&&(e+=t.corners.right-n.corners.right),e+=n.corners.right-n.point.x):e+=void 0!==i&&"Top"!==i&&"Bottom"===t.direction&&n.point.y=t.corners.top-t.margin.top?(("Right"===t.direction&&n.point.xt.point.x)&&(e+=t.corners.bottom-n.corners.bottom),e+=n.corners.bottom-n.point.y):e+=void 0!==i&&"Left"!==i&&"Right"===t.direction&&n.point.xp&&d=u&&d=f&&d<=p?"Left":"Right"}function _n(n){switch(n){case"Top":return"Bottom";case"Bottom":return"Top";case"Left":return"Right";case"Right":return"Left"}return"auto"}var b3=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Ac=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},CI=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return b3(t,n),Ac([I()],t.prototype,"width",void 0),Ac([I()],t.prototype,"height",void 0),t}(Ee),Pre=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return b3(t,n),Ac([I()],t.prototype,"width",void 0),Ac([I()],t.prototype,"height",void 0),Ac([I()],t.prototype,"fit",void 0),Ac([I()],t.prototype,"description",void 0),Ac([I()],t.prototype,"template",void 0),Ac([I()],t.prototype,"tooltip",void 0),t}(Ee),zre=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),kl=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},M3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return zre(t,n),kl([I("")],t.prototype,"id",void 0),kl([I(Number.MIN_VALUE)],t.prototype,"zIndex",void 0),kl([re({},Jn)],t.prototype,"margin",void 0),kl([I(!0)],t.prototype,"visible",void 0),kl([re({},Dd)],t.prototype,"tooltip",void 0),kl([I(!1)],t.prototype,"excludeFromLayout",void 0),kl([I()],t.prototype,"addInfo",void 0),kl([I("None")],t.prototype,"flip",void 0),kl([I("All")],t.prototype,"flipMode",void 0),kl([re({},Pre)],t.prototype,"symbolInfo",void 0),t}(Ee),Rre=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),es=function(n){function t(e,i,r,s){var o=n.call(this)||this;return o.data="",o.nodeId="",o.annotationId="",o.diagramId="",o.diagramId=i,o.nodeId=e,o.annotationId=r,o.templateFn=FF(s),o}return Rre(t,n),t.prototype.getNodeTemplate=function(){return this.templateFn},Object.defineProperty(t.prototype,"content",{get:function(){return this.data},set:function(e){this.data=e,this.canReset||(this.canReset=!0,this.isTemplate||(this.template=Hh(this,!0)),this.canReset=!1,this.isDirt=!0)},enumerable:!0,configurable:!0}),t}(hs),Px=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),cs=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},w3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Px(t,n),cs([I("")],t.prototype,"id",void 0),cs([I("transparent")],t.prototype,"fill",void 0),cs([I("black")],t.prototype,"iconStrokeColor",void 0),cs([I(0)],t.prototype,"iconStrokeWidth",void 0),cs([I(!0)],t.prototype,"visibility",void 0),cs([I(10)],t.prototype,"width",void 0),cs([I(10)],t.prototype,"height",void 0),cs([I("transparent")],t.prototype,"handleStrokeColor",void 0),cs([I(1)],t.prototype,"handleStrokeWidth",void 0),cs([I("")],t.prototype,"pathData",void 0),cs([I(0)],t.prototype,"cornerRadius",void 0),cs([re({left:0,right:0,top:0,bottom:0},Jn)],t.prototype,"padding",void 0),cs([re({},Dd)],t.prototype,"tooltip",void 0),t}(Ee),C3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Px(t,n),cs([re({x:0,y:0},R)],t.prototype,"offset",void 0),cs([re({},Jn)],t.prototype,"margin",void 0),t}(w3),EI=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Px(t,n),cs([I(.5)],t.prototype,"offset",void 0),cs([I("Center")],t.prototype,"alignment",void 0),cs([re({x:0,y:0},R)],t.prototype,"displacement",void 0),t}(w3);function xd(n){return n?n instanceof Kn||n instanceof Or?n.constraints&Nr.Select:n instanceof de?n.constraints&qe.Select:n.constraints&ie.Select:1}function ro(n){return n?n instanceof Kn||n instanceof Or?n.constraints&Nr.Drag:n instanceof de?n.constraints&qe.Drag:n instanceof ei?1:n.constraints&ie.Drag:1}function Hre(n,t){return n instanceof de?n.constraints&qe.PointerEvents:n.constraints&ie.PointerEvents}function DI(n){return n instanceof de?n.constraints&qe.Delete:n.constraints&ie.Delete}function xI(n){return n.constraints&qe.DragSourceEnd}function TI(n){return n.constraints&qe.DragTargetEnd}function AI(n){return n.constraints&qe.DragSegmentThumb}function LI(n){return n instanceof Kn||n instanceof Or?n.constraints&Nr.Rotate:n.constraints&ie.Rotate}function NI(n){return n.constraints&ie.Shadow}function ua(n){return n instanceof te&&n.constraints&ie.InConnect?n.constraints&ie.InConnect:0}function kh(n){return n&&n.constraints&&!(n.constraints&oi.None)&&n.constraints&oi.InConnect?n.constraints&oi.InConnect:0}function Ph(n){return n instanceof te&&n.constraints&ie.OutConnect?n.constraints&ie.OutConnect:0}function Td(n){return n&&n.constraints&&!(n.constraints&oi.None)&&n.constraints&oi.OutConnect?n.constraints&oi.OutConnect:0}function Pl(n,t){var e=0;return n instanceof Kn||n instanceof Or?e=n.constraints&Nr.Resize:n&&("SouthEast"===t?e=n.constraints&ie.ResizeSouthEast:"East"===t?e=n.constraints&ie.ResizeEast:"NorthEast"===t?e=n.constraints&ie.ResizeNorthEast:"South"===t?e=n.constraints&ie.ResizeSouth:"North"===t?e=n.constraints&ie.ResizeNorth:"SouthWest"===t?e=n.constraints&ie.ResizeSouthWest:"West"===t?e=n.constraints&ie.ResizeWest:"NorthWest"===t&&(e=n.constraints&ie.ResizeNorthWest)),e}function OI(n){return n instanceof de?n.constraints&qe.AllowDrop:n.constraints&ie.AllowDrop}function Ds(n){return n.constraints&nt.Virtualization}function Bv(n){return n.tool&ri.SingleSelect}function Fv(n){return n.tool&ri.MultipleSelect}function Lc(n){return n.tool&ri.ZoomPan}function kI(n){return n.tool&ri.ContinuousDraw}function E3(n){return n.tool&ri.DrawOnce}function PI(n){return n.tool&ri.SingleSelect||n.tool&ri.MultipleSelect}function _v(n){return n.constraints&nt.UserInteraction}function D3(n){return n.constraints&nt.ZoomTextEdit}function Uv(n){return function Vre(n){return n.constraints&nt.ApiUpdate}(n)||n.diagramActions&ee.ToolAction}function zx(n,t){return n.constraints&oi.Draw}function Rx(n,t){return n.constraints&oi.Drag}function zI(n){return!(n&Ga.DrawSelectorBorder)}function x3(n){return!!(n&Ga.PreventRenderSelector)}var Hx=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),jv=function(n){function t(){var e=null!==n&&n.apply(this,arguments)||this;return e.childTable=[],e.cellStyle={},e.desiredRowHeight=[],e.desiredCellWidth=[],e}return Hx(t,n),t.prototype.rowDefinitions=function(){return this.rowDefns},t.prototype.columnDefinitions=function(){return this.colDefns},t.prototype.addObject=function(e,i,r,s,o){if(this.rows.length>=i){var a=this.rows[parseInt(i.toString(),10)];if(a.cells.length>r){o=o||1,s=s||1;var l=a.cells[parseInt(r.toString(),10)];l.columnSpan=Math.max(o,l.columnSpan),l.rowSpan=Math.max(s,l.rowSpan);var h=new Xre;(h=e).rowId=i,h.columnId=r,h.columnSpan=o,this.childTable[h.id]=h,this.addObjectToCell(h,l)}}},t.prototype.addObjectToCell=function(e,i){i.children||(i.children=[]),e.style.strokeColor="black",e.style.strokeWidth=1,i.children.push(e)},t.prototype.updateProperties=function(e,i,r,s){this.offsetX=e,this.offsetY=i,this.width=r,this.height=s},t.prototype.setDefinitions=function(e,i){this.rowDefns=e,this.colDefns=i,this.children=[],this.rows=this.rows||[];for(var r=0;r0){for(var h=0;hi&&this.updateRowHeight(e,l,!1)}},t.prototype.setTextRefresh=function(e){if(e.children&&e.children.length)for(var i=e.children,r=0;ri&&this.updateColumnWidth(e,a,!1)}},t.prototype.calculateCellWidth=function(e){for(var i,r,s,o=0;os.bounds.width&&(0===s.children.length||void 0===s.children[0].maxWidth)?s.outerBounds.width:s.bounds.width,i=i?is.bounds.height?s.outerBounds.height:s.bounds.height,i=i?i0?e.children[0]:void 0;if(a&&1===e.columnSpan){o="Width"===i?a.bounds.right:a.bounds.bottom,s||(s="Width"===i?a.bounds.width:a.bounds.height);for(var l=0;lo){var d=c-o+("Width"===i?a.bounds.width:a.bounds.height);s&&(s=s0?this.rowDefns.splice(e,0,i):this.rowDefns.push(i);var s=new T3;s.cells=[],(new Ad).width=this.width,this.addCellInRow(this.colDefns,i,s),e>this.rows.length-1?this.rows.push(s):this.rows.splice(e,0,s),r&&(this.measure(new me(this.width,this.height)),this.arrange(this.desiredSize))},t.prototype.addColumn=function(e,i,r){var s,o,a,l,h=this.rows;this.colDefns.length>0?this.colDefns.splice(e,0,i):this.colDefns.push(i),void 0!==this.width&&(this.width+=i.width);for(var c=0;cs.cells.length-1?s.cells.push(l):s.cells.splice(e,0,l),this.children.push(l);r&&(this.measure(new me(this.width,this.height)),this.arrange(this.desiredSize))},t.prototype.removeRow=function(e){var i,r,o=this.rows[parseInt(e.toString(),10)];this.height-=this.rowDefns[parseInt(e.toString(),10)].height;for(var a=0;a0){var r=0,s=0;i=new me(0,0),this.calculateSize();for(var o=0,a=this.rows;o0){for(var o=this.offsetX-e.width*this.pivot.x,a=this.offsetY-e.height*this.pivot.y,l=o,h=0,c=this.rows;h1&&this.children.splice(this.children.indexOf(p)+1,p.columnSpan-1),p.rowSpan>1)for(y=s,S=0;y+p.rowSpan-10){for(var c=0;c0?1:0,v=0;v0||a.outEdges.length>0))for(f=a.inEdges.concat(a.outEdges),s=0;s0)for(o=0;o1)for(a=1;a0))if(h=n.wrapper.children[0],"Horizontal"===e.orientation)for(o=e.header&&e.hasHeader?h.rows[1]:h.rows[0],r=0;r0){var e=void 0;t.lineRoutingModule&&t.constraints&nt.LineRouting&&t.lineRoutingModule.renderVirtualRegion(t,!0);for(var i=0;i0?o+1:o)].height=t.wrapper.height;else if(t.isPhase)for(l[t.rowIndex-o].offset=t.wrapper.height,p=0;p0?1:0)].width=t.wrapper.width}function HI(n,t){var i=n.shape,r=i.header&&i.hasHeader?1:0;return"Horizontal"===i.orientation?t.rowIndex-(r+=i.phases.length>0?1:0):t.columnIndex-(i.phaseSize&&i.phases.length>0?1:0)}function BI(n){var t=0,e=n.shape;return"Horizontal"===e.orientation&&(t=e.header&&e.hasHeader?1:0),e.phases.length>0&&e.phaseSize&&(t+=1),t}function FI(n,t,e,i){var r=n.shape;if(r.phases.length>0){var s=t.nameTable[r.phases[parseInt(i.toString(),10)].header.id];s&&s.maxWidth0?u+1:u);var w=Nc(n,o),C=void 0!==i?i:l.lanes.length;if(u+=C,r={element:M,cause:n.diagramActions,diagramAction:n.getDiagramAction(n.diagramActions),state:"Changing",type:"Addition",cancel:!1,laneIndex:C},n.triggerEvent(Ce.collectionChange,r),!r.cancel){if(c){var D=new Vv;D.height=e.height,o.addRow(u,D,!1),s.height=void 0!==s.height?s.height+e.height:s.height,s.wrapper.height=o.height=s.height}else{var A=new Ad;A.width=e.width,o.addColumn(C+1,A,!1),s.width&&(s.width+=e.width,s.wrapper.width=o.width=s.width),n.diagramActions&ee.UndoRedo||(o.rows[0].cells[0].columnSpan+=1)}n.diagramActions&ee.UndoRedo||(M.id=""===M.id?Qe():M.id),void 0!==i?l.lanes.splice(i,0,M):l.lanes.push(M),r={element:M,cause:n.diagramActions,diagramAction:n.getDiagramAction(n.diagramActions),state:"Changed",type:"Addition",cancel:!1,laneIndex:C},n.triggerEvent(Ce.collectionChange,r),L3(o,n,s,u,C,c),h="Horizontal"===l.orientation?n.nameTable[o.rows[parseInt(u.toString(),10)].cells[0].children[0].id]:l.header&&l.hasHeader?n.nameTable[o.rows[1].cells[parseInt(u.toString(),10)].children[0].id]:n.nameTable[o.rows[0].cells[parseInt(u.toString(),10)].children[0].id],n.diagramActions&ee.UndoRedo||(d={type:"LaneCollectionChanged",changeType:"Insert",undoObject:$(M),redoObject:$(h),category:"Internal"},n.addHistoryEntry(d)),Xf(n,s,"Horizontal"===l.orientation?u:l.header&&l.hasHeader?1:0),Gf(s),Oc(n,s);var P=!1;if((f=e.children)&&f.length>0)for(p=0;p0){var o=t.children[0],a=n.nameTable[o.id];(function rne(n,t,e){return n.left-(e.left||0)<=t.x&&n.right+(e.right||0)>=t.x&&n.top-(e.top||0)<=t.y&&n.bottom+(e.bottom||0)>=t.y})(o.bounds,e,r)&&(n.addChild(a,i),s=!0)}return s}function nne(n,t,e){if("SwimLane"===t.shape.type){var i=void 0,r=void 0,s=void 0,a=void 0,l=void 0,h=void 0,c=t.wrapper.bounds.x,d=t.wrapper.bounds.y,u=t.shape,f=u.padding,p=u.phases,g=void 0,v=t.wrapper.children[0],y="Horizontal"===u.orientation;if(i=u.header&&u.hasHeader?0:-1,u.phases.length>0&&(i+=1),e.offset>(y?u.lanes[0].header.width:u.lanes[0].header.height)){for(h=0;he.offset){if(g=h>0?e.offset-(h>0?p[h-1]:s).offset:e.offset,y){var b=v.columnDefinitions()[parseInt(h.toString(),10)];b.width-=g,(a=n.nameTable[u.phases[parseInt(h.toString(),10)].header.id]).maxWidth=a.wrapper.maxWidth=b.width,v.updateColumnWidth(h,b.width,!1);var M=new Ad;M.width=g,l=h,v.addColumn(h,M,!1);break}var w=v.rowDefinitions()[h+i];w.height-=g,a=n.nameTable[u.phases[parseInt(h.toString(),10)].header.id],v.updateRowHeight(h+i,w.height,!1);var C=new Vv;C.height=g,l=h,v.addRow(h+i,C,!1);break}if(n.diagramActions&ee.UndoRedo&&void 0===l&&(D=n.historyManager.currentEntry.next).isLastPhase&&function sne(n,t,e,i,r,s){var a=t.shape.phases[n-2],l=e.previousPhase.offset;if(r){var h=i.columnDefinitions()[n-1],c=new Ad;n>1?(c.width=h.width-(l-a.offset),h.width=l-a.offset):(c.width=h.width-l,h.width=l),i.updateColumnWidth(n-1,h.width,!1),i.addColumn(n,c,!1)}else{h=i.rowDefinitions()[parseInt(n.toString(),10)];var d=new Vv;n>1?(d.height=e.undoObject.offset-l,h.height=l-a.offset):(d.height=h.height-l,h.height=l),i.updateRowHeight(n,h.height,!1),i.addRow(1+n,d,!1)}}(l=p.length,t,D,v,y),l>=0){var A=new ob(t.shape,"phases",e,!0);if(n.diagramActions&ee.UndoRedo||(A.id+=Qe()),u.phases.splice(l,0,A),Bx(v,n,t,i,y,l),y){if(r=n.nameTable[v.rows[parseInt(i.toString(),10)].cells[parseInt(l.toString(),10)].children[0].id],0===l&&u.header&&u.hasHeader){v.rows[0].cells[0].children=v.rows[0].cells[1].children,v.rows[0].cells[1].children=[];for(var x=v.rows[0],P=0;Pl+1){var O=n.nameTable[v.rows[parseInt(i.toString(),10)].cells[l+1].children[0].id];v.updateColumnWidth(l+1,L[l+1].width,!0,f),O.maxWidth=O.wrapper.maxWidth=L[l+1].width}t.width=t.wrapper.width=t.wrapper.children[0].width=v.width}else{r=n.nameTable[v.rows[i+l].cells[0].children[0].id];var N=v.rowDefinitions(),T=N[i+l].height;(function ane(n,t,e,i,r){for(var o,a,l=e.rows[parseInt(i.toString(),10)],h=e.rows[i+1],c=e.rows[i-1],d=1;di+l+1&&v.updateRowHeight(i+l+1,T=N[i+l+1].height,!0,f),t.height=t.wrapper.height=t.wrapper.children[0].height=v.actualSize.height}if(Gf(t),t.width=t.wrapper.actualSize.width,Oc(n,t),n.drag(t,c-t.wrapper.bounds.x,d-t.wrapper.bounds.y),RI(t,n),n.commandHandler.select(r),!(n.diagramActions&ee.UndoRedo)){var D={type:"PhaseCollectionChanged",changeType:"Insert",undoObject:$(A),redoObject:$(r),category:"Internal"};n.addHistoryEntry(D)}n.updateDiagramObject(t)}}}}function z3(n,t,e,i,r,s,o){var a,l,p,h=t.shape,c="Horizontal"===h.orientation,d=t.wrapper.children[0],g=c?s:o;e?(a=c?e.bounds.x+e.bounds.width:e.bounds.x,l=c?e.bounds.y:e.bounds.y+e.bounds.height):(a=d.bounds.x,l=r.bounds.y);var v=new Ne(a,l,i.desiredCellWidth,i.desiredCellHeight),S=Wv(n,0,t,{id:t.id+(c?h.lanes[g-2]:h.lanes[g-1]).id+Qe()[0],rowIndex:s,columnIndex:o,width:i.minWidth,height:i.minHeight,style:(c?h.lanes[g-2]:h.lanes[g-1]).style,constraints:ie.Default|ie.AllowDrop,container:{type:"Canvas",orientation:c?"Horizontal":"Vertical"}},!1,!1,!0);if(S.children[0].isCalculateDesiredSize=!1,d.addObject(S,s,o),r&&r.children&&r.children.length)for(p=0;p1)for(var p=1;ph.margin.left&&(h.margin.left=f)):(h.margin.top-=e.desiredCellHeight,f>h.margin.top&&(h.margin.top=f)))}(n,r,i,v,S,c,e)}function R3(n,t,e){if("SwimLane"===t.shape.type&&("ResizeSouth"===e||"ResizeEast"===e)){var i=t.shape,r=t.wrapper.children[0],s=void 0,o=void 0;"ResizeSouth"===e?"Vertical"===i.orientation?s=r.rows[r.rows.length-1].cells[0]:(o=r.rows.length-1,s=r.rows[parseInt(o.toString(),10)].cells[r.rows[parseInt(o.toString(),10)].cells.length-1]):(o=i.header&&i.hasHeader?1:0,s=r.rows[parseInt(o.toString(),10)].cells[r.rows[parseInt(o.toString(),10)].cells.length-1]),n.commandHandler.select(n.nameTable[s.children[0].id])}}function _I(n,t,e,i,r,s){var o,a,l,c,u,f,p,d=Qe(),g=n.shape,v=g.phases,y=n.offsetX-n.wrapper.actualSize.width/2,S=n.offsetY-n.wrapper.actualSize.height/2;if("Vertical"===g.orientation&&(S+=g.header&&g.hasHeader?g.header.height:0),!s)for(r||(n.id+=d,g&&g.header&&g.hasHeader?g.header.id+=d:g.header=void 0),o=0;v&&o0&&s.columnIndex>0||s.isLane)?(a=function mne(n,t,e){for(var i=new Ne,r="SwimLane"===n.shape.type?n.wrapper.children[0].rows:n.wrapper.rows,s=e?1:0;s=0;a--)i?i.id===o.children[parseInt(a.toString(),10)].id&&o.children.splice(a,1):(n.removeDependentConnector(o.children[parseInt(a.toString(),10)]),n.diagramActions&ee.UndoRedo||(n.diagramActions=n.diagramActions|ee.UndoRedo,s=!0),n.remove(o.children[parseInt(a.toString(),10)]),o.children.splice(a,1),s&&(n.diagramActions=n.diagramActions&~ee.UndoRedo))}function hne(n){return n.children[0]}function Gv(n,t){t&&(n.nodes.splice(n.nodes.indexOf(t),1),n.removeFromAQuad(t),n.removeObjectsFromLayer(t),delete n.nameTable[t.id],n.removeElements(t))}function B3(n,t,e,i){var r;if("SwimLane"===e.shape.type){var s=e.shape,o=void 0;if(1===s.lanes.length)n.remove(e);else{var a=e.wrapper.bounds.x,l=e.wrapper.bounds.y,h=void 0,c=void 0,d=void 0,u=void 0,p=e.wrapper.children[0];if(o=i?s.lanes.indexOf(i):HI(e,t),r={element:t,cause:n.diagramActions,diagramAction:n.getDiagramAction(n.diagramActions),state:"Changing",type:"Removal",cancel:!1,laneIndex:o},n.triggerEvent(Ce.collectionChange,r),!r.cancel){var g=s.lanes[parseInt(o.toString(),10)],v=g.children;g.children=[];for(var y=0;y0)for(u=0;u0)for(u=0;u0)for(e=0;e1){c===l.phases.length-1&&(o=!0,a=$(l.phases[c-1]));var u=$(l.phases[parseInt(c.toString(),10)]);if(l.phases.splice(c,1),!(n.diagramActions&ee.UndoRedo)){var f={type:"PhaseCollectionChanged",changeType:"Remove",undoObject:u,previousPhase:a,redoObject:$(t),category:"Internal",isLastPhase:o};n.addHistoryEntry(f)}"Horizontal"===l.orientation?function dne(n,t,e,i){var r,s,o,a,l,h,c,d,u,f,p,g;for(i=void 0!==i?i:e.columnIndex,c=0;c1&&(s=r.cells[parseInt(i.toString(),10)],l=(o=r.cells.length-1===i?r.cells[i-1]:r.cells[i+1]).children[0],s.children.length>0))if(p=n.nameTable[(a=s.children[0]).id],0===o.children.length&&s.children.length>0)o.children=s.children,o.columnSpan=s.columnSpan-1;else{for(d=0;d0){var M=s.children[0],w=n.nameTable[M.id];if(i=e.x&&a.bounds.y<=e.y&&a.bounds.bottom>=e.y){var l=void 0,h=a.bounds.y,c=a.bounds.x,d=n.nameTable[r.parentId]||r;if("SwimLane"===d.shape.type)o=qv(r,d,t,n,!0);else{var f=n.nameTable[r.parentId]||r,p=f.shape;l=f.wrapper,a.actualSize.widtha.outerBounds.x)&&(void 0!==r.rowIndex?(l.updateColumnWidth(r.columnIndex,a.outerBounds.width,!0),"Horizontal"===p.orientation&&p.phaseSize&&FI(f,n,a,r.columnIndex),Oc(n,f),n.drag(f,c-a.bounds.x,h-a.bounds.y)):n.scale(r,1+(a.outerBounds.width-a.actualSize.width)/a.actualSize.width,1,a.outerBounds.xa.outerBounds.y)&&(void 0!==r.rowIndex?(l.updateRowHeight(r.rowIndex,a.outerBounds.height,!0),n.drag(f,c-a.bounds.x,h-a.bounds.y)):n.scale(r,1,1+(a.outerBounds.height-a.actualSize.height)/a.actualSize.height,a.outerBounds.y=e.x&&a.bounds.y<=e.y&&a.bounds.bottom>=e.y)&&!(t.constraints&ie.AllowMovingOutsideLane)){var l=$(t);n.clearSelection(),j3(n,t),t.parentId="",t.parentObj=n,t.propName="nodes";var h={type:"ChildCollectionChanged",category:"Internal",undoObject:l,redoObject:$(t)};n.addHistoryEntry(h),n.commandHandler.isContainer&&(n.commandHandler.isContainer=!1,n.endGroupAction()),V3(t,n)}n.protectPropertyChange(o)}}function UI(n,t){var e,i,r;return n.enableServerDataBinding(!1),ce()||(n.selectedObject.helperObject?r=n.selectedObject.helperObject:(n.selectedItems.nodes.length>0||n.selectedItems.connectors.length>0)&&(t instanceof ei&&t.nodes.length+t.connectors.length===1?(e=t.nodes.length>0?t.nodes[0]:t.connectors[0],i=n.selectedItems.wrapper.children[0]):(e=t,i=n.selectedItems.wrapper),n.selectedObject.actualObject=e,!n.currentSymbol&&(e.isLane&&jx(e,n)&&Dn(n,e)||!e.isLane&&Dn(n,e)||n.constraints&nt.LineRouting&&n.selectedItems.nodes.length>0))&&(r=function yne(n,t){for(var e,i={},r=0,s=Object.keys(t);r=t.x-e&&n.x<=t.x+e&&n.y>=t.y-e&&n.y<=t.y+e}function $a(n){return n.selectedItems.nodes.length>0||n.selectedItems.connectors.length>0}function Y3(n){return 1===n.selectedItems.connectors.length&&!n.selectedItems.nodes.length}function _r(n,t,e,i){if(void 0===e&&(e=!0),t instanceof ei)return!0;if(t instanceof te)for(;t;){if(-1!==n.selectedItems.nodes.indexOf(t)&&void 0===n.selectedItems.annotation)return!0;if(e)break;t=n.nameTable[t.parentId]}else if(t instanceof de){if(-1!==n.selectedItems.connectors.indexOf(t)&&void 0===n.selectedItems.annotation)return!0}else if((t instanceof Kn||t instanceof Or)&&n.selectedItems.annotation&&n.selectedItems.wrapper.children[0].id===i.id)return!0;return!1}var Vx={None:"default",Rotate:"crosshair",Select:"default",Drag:"move",ResizeWest:"w-resize",ResizeEast:"e-resize",ResizeSouth:"s-resize",ResizeNorth:"n-resize",Draw:"crosshair",PortDraw:"crosshair",ResizeNorthEast:"ne-resize",ResizeNorthWest:"nw-resize",ResizeSouthEast:"se-resize",ResizeSouthWest:"sw-resize",ConnectorSourceEnd:"move",ConnectorTargetEnd:"move",BezierSourceThumb:"move",BezierTargetThumb:"move",OrthoThumb:"move",SegmentEnd:"move",Pan:"grab",Hyperlink:"pointer",PortDrag:"pointer",LabelSelect:"pointer",LabelDrag:"move",LabelRotate:"crosshair",LabelResizeWest:"w-resize",LabelResizeEast:"e-resize",LabelResizeSouth:"s-resize",LabelResizeNorth:"n-resize",LabelResizeNorthEast:"ne-resize",LabelResizeNorthWest:"nw-resize",LabelResizeSouthEast:"se-resize",LabelResizeSouthWest:"sw-resize"},ds=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Nd=function(n,t,e,i){return new(e||(e=Promise))(function(r,s){function o(h){try{l(i.next(h))}catch(c){s(c)}}function a(h){try{l(i.throw(h))}catch(c){s(c)}}function l(h){h.done?r(h.value):new e(function(c){c(h.value)}).then(o,a)}l((i=i.apply(n,t||[])).next())})},Od=function(n,t){var i,r,s,o,e={label:0,sent:function(){if(1&s[0])throw s[1];return s[1]},trys:[],ops:[]};return o={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function a(h){return function(c){return function l(h){if(i)throw new TypeError("Generator is already executing.");for(;e;)try{if(i=1,r&&(s=2&h[0]?r.return:h[0]?r.throw||((s=r.return)&&s.call(r),0):r.next)&&!(s=s.call(r,h[1])).done)return s;switch(r=0,s&&(h=[2&h[0],s.value]),h[0]){case 0:case 1:s=h;break;case 4:return e.label++,{value:h[1],done:!1};case 5:e.label++,r=h[1],h=[0];continue;case 7:h=e.ops.pop(),e.trys.pop();continue;default:if(!(s=(s=e.trys).length>0&&s[s.length-1])&&(6===h[0]||2===h[0])){e=0;continue}if(3===h[0]&&(!s||h[1]>s[0]&&h[1]-1&&(r=i.fixedUserHandles[parseInt(o.toString(),10)]);this.commandHandler.triggerEvent(Ce.fixedUserHandleClick,{fixedUserHandle:r,element:e.source}),n.prototype.mouseUp.call(this,e)},t}(us),kd=function(n){function t(e,i){var r=n.call(this,e,!0)||this;return r.isConnected=!1,r.endPoint=i,r}return ds(t,n),t.prototype.mouseDown=function(e){return Nd(this,void 0,void 0,function(){var r,s,o,a,l;return Od(this,function(h){if(this.inAction=!0,this.undoElement=void 0,this instanceof pa||(this.undoElement=$(e.source)),n.prototype.mouseDown.call(this,e),e.source&&e.source.connectors&&(this.oldConnector=$(r=e.source.connectors[0])),"BezierSourceThumb"===this.endPoint||"BezierTargetThumb"===this.endPoint)for(s=0;s0))},t.prototype.endAction=function(){n.prototype.endAction.call(this),this.prevPosition=null,this.endPoint=null},t}(us),fa=function(n){function t(e,i){var r=n.call(this,e,!0)||this;return r.currentTarget=null,r.isStartAction=!1,r.canCancel=!1,r.canTrigger=!1,r.objectType=i,r}return ds(t,n),t.prototype.mouseDown=function(e){if(e.source instanceof te||e.source instanceof de){var i=this.commandHandler.getSelectedObject();this.commandHandler.selectObjects([e.source],e.info&&e.info.ctrlKey,i);var r={nodes:[],connectors:[]};e.source instanceof te?r.nodes.push($(e.source)):r.connectors.push($(e.source)),this.undoElement=$(r)}else this.undoElement=$(e.source);this.undoParentElement=this.commandHandler.getSubProcess(e.source),"Port"===this.objectType&&(this.portId=e.sourceWrapper.id),this.commandHandler.insertBlazorConnector(e.source),n.prototype.mouseDown.call(this,e),this.initialOffset={x:0,y:0}},t.prototype.mouseUp=function(e,i){return Nd(this,void 0,void 0,function(){var s,o,a,l,h,c,d,u,p,g,v,y,S,b,M;return Od(this,function(w){if(this.checkPropertyValue(),a=!1,h={nodes:[],connectors:[]},"Port"!==this.objectType){if(e.source instanceof te||e.source instanceof de?(e.source instanceof te?h.nodes.push($(e.source)):h.connectors.push($(e.source)),(o=$(h)).offsetX=(c=e.source.wrapper).offsetX,o.offsetY=c.offsetY):o=$(e.source),("helper"===(l=this.commandHandler.renderContainerHelper(e.source)||e.source||this.commandHandler.renderContainerHelper(e.source)).id||"helper"!==l.id)&&((l instanceof ei&&(Math.round(l.width)===Math.round(this.undoElement.width)&&Math.round(l.height)===Math.round(this.undoElement.height)||l.selectedObjects&&1===l.selectedObjects.length)||!(l instanceof ei))&&(l.offsetX!==this.undoElement.offsetX||l.offsetY!==this.undoElement.offsetY||l.sourcePoint!==this.undoElement.sourcePoint||l.targetPoint!==this.undoElement.targetPoint)||this.isSelectionHasConnector(l))&&(e.source&&(s={offsetX:e.source.wrapper.offsetX,offsetY:e.source.wrapper.offsetY}),g={source:e.source,state:"Completed",oldValue:this.intialValue,newValue:s,target:this.currentTarget,targetPosition:this.currentPosition,allowDrop:(g={source:e.source,state:"Completed",oldValue:this.intialValue,newValue:s,target:this.currentTarget,targetPosition:this.currentPosition,allowDrop:!0,cancel:!1}).allowDrop,cancel:g.cancel},d=!0,"helper"===l.id?this.canTrigger?(this.commandHandler.triggerEvent(Ce.positionChange,g),this.connectorEndPointChangeEvent(g),d=!0):d=!1:(this.commandHandler.triggerEvent(Ce.positionChange,g),this.connectorEndPointChangeEvent(g)),!i&&d&&(this.commandHandler.startGroupAction(),a=!0,M={type:"PositionChanged",redoObject:$(o),undoObject:$(this.undoElement),category:"Internal"},o.nodes[0]&&o.nodes[0].processId&&(u={type:"SizeChanged",category:"Internal",undoObject:this.undoParentElement,redoObject:this.commandHandler.getSubProcess(e.source)},this.commandHandler.addHistoryEntry(u)),this.commandHandler.addHistoryEntry(M))),this.commandHandler.snapPoint(this.prevPosition,this.currentPosition,0,0),this.commandHandler.removeSnap(),this.commandHandler.removeHighlighter(),e.source&&this.currentTarget&&OI(this.currentTarget)&&this.commandHandler.isDroppable(e.source,this.currentTarget)){if(p=!0,this.commandHandler.drop(this.currentElement,this.currentTarget,this.currentPosition),this.currentTarget&&this.currentTarget instanceof de&&!0===this.commandHandler.diagram.enableConnectorSplit)if(this.currentElement&&this.currentElement instanceof te){if(void 0!==this.currentElement.children)for(b=0;b0)for(var s=0;s0)for(var a=0;a0)for(a=0;a0&&e.connectors.length>0)||e.width===this.undoElement.width&&e.height===this.undoElement.height)},t.prototype.mouseMove=function(e){n.prototype.mouseMove.call(this,e);var r,s,i=!1;(r=this.commandHandler.renderContainerHelper(e.source)||e.source)instanceof te||r instanceof de?r instanceof te?r.offsetX===this.undoElement.nodes[0].offsetX&&r.offsetY===this.undoElement.nodes[0].offsetY&&(i=!0):R.equals(r.sourcePoint,this.undoElement.connectors[0].sourcePoint)&&R.equals(r.targetPoint,this.undoElement.connectors[0].targetPoint)&&(i=!0):r.wrapper.offsetX===this.undoElement.wrapper.offsetX&&r.wrapper.offsetY===this.undoElement.wrapper.offsetY&&(i=!0),r&&(s={offsetX:r.wrapper.offsetX,offsetY:r.wrapper.offsetY});var o={source:r,state:"Start",oldValue:s,newValue:s,target:e.target,targetPosition:e.position,allowDrop:!0,cancel:!1};if(o={source:r,state:"Start",oldValue:s,newValue:s,target:e.target,targetPosition:e.position,allowDrop:o.allowDrop,cancel:o.cancel},this.isStartAction||(this.intialValue={offsetX:r.wrapper.offsetX,offsetY:r.wrapper.offsetY}),i&&!ce()&&(this.commandHandler.triggerEvent(Ce.positionChange,o),this.connectorEndPointChangeEvent(o),this.isStartAction=!0),this.currentPosition=e.position,"Port"!==this.objectType){var h=this.initialOffset.x+(this.currentPosition.x-this.prevPosition.x),c=this.initialOffset.y+(this.currentPosition.y-this.prevPosition.y);this.commandHandler.dragOverElement(e,this.currentPosition),this.commandHandler.disConnect(e.source),this.commandHandler.removeSnap();var d,u=void 0,f=this.commandHandler.snapPoint(this.prevPosition,this.currentPosition,h,c);this.initialOffset.x=h-f.x,this.initialOffset.y=c-f.y,r&&(d={offsetX:r.wrapper.offsetX,offsetY:r.wrapper.offsetY},u={offsetX:r.wrapper.offsetX+f.x,offsetY:r.wrapper.offsetY+f.y}),this.currentTarget&&e.target!==this.currentTarget&&this.commandHandler.removeChildFromBPmn(e.source,e.target,this.currentTarget),this.currentTarget=e.target;var p={source:r,state:"Progress",oldValue:d,newValue:u,target:e.target,targetPosition:e.position,allowDrop:!0,cancel:!1};if(this.commandHandler.triggerEvent(Ce.positionChange,p),this.canTrigger=!0,this.connectorEndPointChangeEvent(p,f),!p.cancel&&!this.canCancel){this.blocked=!this.commandHandler.dragSelectedObjects(f.x,f.y);var g=!this.commandHandler.mouseOver(this.currentElement,this.currentTarget,this.currentPosition);this.blocked=this.blocked||g}if(this.commandHandler.removeStackHighlighter(),this.commandHandler.renderStackHighlighter(e),this.currentTarget&&e.source!==this.currentTarget&&this.commandHandler.isDroppable(e.source,this.currentTarget)&&"helper"!==e.source.id){var v=e.source instanceof ei?e.source.nodes[0]:e.source;!this.commandHandler.isParentAsContainer(v,!0)&&"SwimLane"!==v.shape.type&&!v.shape.isPhase&&(this.currentTarget.isLane?this.commandHandler.renderStackHighlighter(e,this.currentTarget):this.commandHandler.drawHighlighter(this.currentTarget))}else this.commandHandler.removeHighlighter();if(this.commandHandler.canEnableDefaultTooltip()){var y=this.getTooltipContent(e.source);this.commandHandler.showTooltip(e.source,e.position,ko(function(){return y}),"MoveTool",this.isTooltipVisible),this.isTooltipVisible=!1}}else{var b=Bi(),M=e.source;qi(b,-M.rotateAngle||-M.wrapper.rotateAngle,M.offsetX||M.wrapper.offsetX,M.offsetY||M.wrapper.offsetY);var w=Ke(b,{x:this.prevPosition.x,y:this.prevPosition.y}),C=Ke(b,{x:e.position.x,y:e.position.y});this.commandHandler.portDrag(e.source,e.sourceWrapper,C.x-w.x,C.y-w.y)}return this.prevPosition=this.currentPosition,!this.blocked},t.prototype.getTooltipContent=function(e){return"X:"+Math.round(e.wrapper.bounds.x)+" Y:"+Math.round(e.wrapper.bounds.y)},t.prototype.mouseLeave=function(e){this.mouseUp(e)},t.prototype.endAction=function(){n.prototype.endAction.call(this),this.currentTarget=null,this.prevPosition=null},t}(us),Wx=function(n){function t(e){var i=n.call(this,e,!0)||this;return i.rotateStart=!1,i}return ds(t,n),t.prototype.mouseDown=function(e){if(this.undoElement=$(e.source),this.undoElement.nodes[0]&&this.undoElement.nodes[0].children)for(var r=this.commandHandler.getAllDescendants(this.undoElement.nodes[0],[]),s=0;s=2){var s=e.startTouches[0],o=e.startTouches[1],a=e.moveTouches[0],l=e.moveTouches[1],h=this.getDistance(a,l)/this.getDistance(s,o);this.commandHandler.zoom(h,0,0,e.position),this.updateTouch(s,a),this.updateTouch(o,l)}}else this.commandHandler.scroll(this.currentPosition.x-this.prevPosition.x,this.currentPosition.y-this.prevPosition.y,this.currentPosition);return this.commandHandler.dataBinding(),!this.blocked},t.prototype.mouseUp=function(e){this.commandHandler.setBlazorDiagramProps(!1),this.checkPropertyValue(),this.commandHandler.updatePanState(!1),n.prototype.mouseUp.call(this,e),this.inAction=!1},t.prototype.endAction=function(){n.prototype.endAction.call(this)},t.prototype.getDistance=function(e,i){var r=i.pageX-e.pageX,s=i.pageY-e.pageY;return Math.sqrt(r*r+s*s)},t.prototype.updateTouch=function(e,i){e.pageX=i.pageX,e.pageY=i.pageY},t}(us),Tne=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseUp=function(e){this.checkPropertyValue(),this.commandHandler.initExpand(e),n.prototype.mouseUp.call(this,e)},t}(us),Q3=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseUp=function(e){this.checkPropertyValue();var i="_blank",r="",s=window.innerHeight,o=window.innerWidth,a=window.screenTop,l=window.screenLeft;"CurrentTab"===e.sourceWrapper.hyperlink.hyperlinkOpenState?i="_self":"NewWindow"===e.sourceWrapper.hyperlink.hyperlinkOpenState&&(r="height="+s+",width="+o+",top="+a+",left="+l),window.open(e.sourceWrapper.hyperlink.link,i,r).focus(),n.prototype.mouseUp.call(this,e)},t}(us),zl=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseDown=function(e){if(n.prototype.mouseDown.call(this,e),this.inAction=!0,this.drawingObject){var r=void 0,s=this.drawingObject.shape;this.drawingObject.shape.points.push(r={x:(r=s.points[s.points.length-1]).x,y:r.y})}else{this.startPoint={x:this.startPosition.x,y:this.startPosition.y};var i={offsetX:this.currentPosition.x,offsetY:this.currentPosition.y,width:5,height:5,shape:{type:"Basic",shape:"Polygon",points:[{x:this.startPoint.x,y:this.startPoint.y},{x:this.currentPosition.x,y:this.currentPosition.y}]}};this.triggerElementDrawEvent(e.source,"Start","Node",this.getShapeType(),!0),this.drawingObject=this.commandHandler.drawObject(i)}},t.prototype.mouseMove=function(e){if(n.prototype.mouseMove.call(this,e),this.inAction){var i=this.drawingObject.shape;if(i.points[i.points.length-1].x=this.currentPosition.x,i.points[i.points.length-1].y=this.currentPosition.y,this.drawingObject.wrapper.children[0].data=gx(this.drawingObject.shape.points),this.triggerElementDrawEvent(this.drawingObject,"Progress","Node",this.getShapeType(),!1),this.inAction&&!1===R.equals(this.currentPosition,this.prevPosition)){var r=Ne.toBounds(this.drawingObject.shape.points);this.commandHandler.updateNodeDimension(this.drawingObject,r)}}return!0},t.prototype.mouseUp=function(e,i){this.checkPropertyValue(),n.prototype.mouseMove.call(this,e),this.inAction&&(this.inAction=!1,this.commandHandler.addObjectToDiagram(this.drawingObject),this.triggerElementDrawEvent(this.drawingObject,"Completed","Node",this.getShapeType(),!1)),this.endAction()},t.prototype.mouseWheel=function(e){n.prototype.mouseWheel.call(this,e),this.mouseMove(e)},t.prototype.endAction=function(){this.inAction=!1,this.drawingObject=null},t}(us),Rl=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseMove=function(e){if(n.prototype.mouseMove.call(this,e),this.inAction){var i=this.drawingObject;i.targetPoint=this.currentPosition,this.triggerElementDrawEvent(this.drawingObject,"Progress","Connector",this.drawingObject.type,!1),this.commandHandler.updateConnectorPoints(i)}return!0},t.prototype.mouseDown=function(e){if(n.prototype.mouseDown.call(this,e),this.inAction=!0,this.drawingObject){var r=this.drawingObject,s=void 0;(s=new Hl(r,"segments",{type:"Straight"},!0)).point=this.currentPosition,r.segments[r.segments.length-1]=s}else{var i={id:"Connector",type:"Straight",sourcePoint:this.currentPosition,targetPoint:this.currentPosition};this.triggerElementDrawEvent(e.source,"Start","Connector",this.commandHandler.diagram.drawingObject.type,!0),this.inAction&&(this.drawingObject=this.commandHandler.drawObject(i))}},t.prototype.mouseWheel=function(e){n.prototype.mouseWheel.call(this,e),this.mouseMove(e)},t.prototype.mouseUp=function(e){if(this.checkPropertyValue(),n.prototype.mouseMove.call(this,e),this.inAction&&this.drawingObject){var i=this.drawingObject;i.segments[i.segments.length-1].point={x:0,y:0},this.commandHandler.addObjectToDiagram(this.drawingObject),this.triggerElementDrawEvent(this.drawingObject,"Completed","Connector",this.drawingObject.type,!1)}this.endAction()},t.prototype.endAction=function(){this.drawingObject=null,this.inAction=!1},t}(us),Ane=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseDown=function(e){this.inAction=!0,this.undoElement=$(e.source),this.annotationId=e.sourceWrapper.id,n.prototype.mouseDown.call(this,e)},t.prototype.mouseMove=function(e){n.prototype.mouseMove.call(this,e);var i=this.currentPosition.x-this.prevPosition.x,r=this.currentPosition.y-this.prevPosition.y,s=e.source;if(s instanceof te){var o=Bi();qi(o,-s.rotateAngle,0,0);var a=Ke(o,{x:i,y:r});i=a.x,r=a.y}return this.inAction&&(this.commandHandler.labelDrag(e.source,e.sourceWrapper,i,r),this.commandHandler.updateSelector()),this.prevPosition=this.currentPosition,!this.blocked},t.prototype.mouseUp=function(e){this.checkPropertyValue();var i=e.source;this.inAction=!1;var r={type:"AnnotationPropertyChanged",objectId:this.annotationId,undoObject:$(this.undoElement),category:"Internal",redoObject:$(i)};this.commandHandler.addHistoryEntry(r),n.prototype.mouseUp.call(this,e)},t.prototype.mouseLeave=function(e){this.mouseUp(e)},t}(us),Lne=function(n){function t(e,i){var r=n.call(this,e,!0)||this;return r.corner=i,r}return ds(t,n),t.prototype.mouseDown=function(e){this.inAction=!0;var i=e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0];this.annotationId=e.source.wrapper.children[0].id,this.undoElement=$(i);var r=e.source.wrapper.children[0];this.initialBounds={x:r.offsetX,y:r.offsetY,width:r.actualSize.width,height:r.actualSize.height},n.prototype.mouseDown.call(this,e)},t.prototype.mouseMove=function(e){return n.prototype.mouseMove.call(this,e),this.inAction&&this.resizeObject(e),!this.blocked},t.prototype.mouseUp=function(e){this.checkPropertyValue();var i=e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0];this.inAction=!1;var r={type:"AnnotationPropertyChanged",objectId:this.annotationId,redoObject:$(i),undoObject:$(this.undoElement),category:"Internal"};this.commandHandler.addHistoryEntry(r),n.prototype.mouseUp.call(this,e)},t.prototype.mouseLeave=function(e){this.mouseUp(e)},t.prototype.resizeObject=function(e){var i,s,o,r=e.source.wrapper.children[0],a={x:r.offsetX,y:r.offsetY},l=r.rotateAngle;l=((l+=(i=e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0])instanceof te?i.rotateAngle:0)+360)%360;var h=Bi();qi(h,l,a.x,a.y);var c=this.corner.slice(5),d=this.updateSize(r,this.startPosition,this.currentPosition,c,this.initialBounds,l),u=r.offsetX-r.actualSize.width*r.pivot.x,f=r.offsetY-r.actualSize.height*r.pivot.y,p=this.getPivot(c),g=Ke(h,p={x:u+r.actualSize.width*p.x,y:f+r.actualSize.height*p.y});d.x=g.x,d.y=g.y,this.commandHandler.labelResize(i,e.source.annotation,s=(s=d.width)<0?1:s,o=(o=d.height)<0?1:o,d,e.source),this.commandHandler.updateSelector()},t}(us),Nne=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseDown=function(e){this.inAction=!0,this.annotationId=e.source.wrapper.children[0].id,this.undoElement=$(e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0]),n.prototype.mouseDown.call(this,e)},t.prototype.mouseMove=function(e){return n.prototype.mouseMove.call(this,e),e.source&&this.inAction&&(this.commandHandler.labelRotate(e.source.nodes[0]?e.source.nodes[0]:e.source.connectors[0],e.source.annotation,this.currentPosition,e.source),this.commandHandler.updateSelector()),this.prevPosition=this.currentPosition,!this.blocked},t.prototype.mouseUp=function(e){this.checkPropertyValue(),this.inAction=!1;var r={type:"AnnotationPropertyChanged",objectId:this.annotationId,redoObject:$(e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0]),undoObject:$(this.undoElement),category:"Internal"};this.commandHandler.addHistoryEntry(r),n.prototype.mouseUp.call(this,e)},t.prototype.mouseLeave=function(e){this.mouseUp(e)},t}(us),One=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseMove=function(e){if(n.prototype.mouseMove.call(this,e),this.inAction){var i=this.drawingObject.shape;if(i.points.push(this.currentPosition),this.drawingObject.wrapper.children[0].data=vx(this.drawingObject.shape.points),i.data=vx(i.points),this.triggerElementDrawEvent(e.source,"Progress","Connector",this.drawingObject.type,!1),this.inAction&&!1===R.equals(this.currentPosition,this.prevPosition)){var s=Ne.toBounds(this.drawingObject.shape.points);this.commandHandler.updateNodeDimension(this.drawingObject,s)}}return!0},t.prototype.mouseDown=function(e){n.prototype.mouseDown.call(this,e),this.inAction=!0,this.startPoint={x:this.startPosition.x,y:this.startPosition.y};var i={offsetX:this.currentPosition.x,offsetY:this.currentPosition.y,width:5,height:5,style:{strokeColor:"black",strokeWidth:1,fill:"transparent"},shape:{type:"Path",points:[{x:this.startPoint.x,y:this.startPoint.y},{x:this.currentPosition.x,y:this.currentPosition.y}]}};this.triggerElementDrawEvent(e.source,"Start","Connector",this.commandHandler.diagram.drawingObject.type,!0),this.drawingObject=this.commandHandler.drawObject(i)},t.prototype.mouseUp=function(e){if(this.checkPropertyValue(),this.inAction){this.inAction=!1;var s=this.drawingObject.shape,o=s.points;this.commandHandler.addObjectToDiagram(this.drawingObject),this.commandHandler.diagram.remove(this.commandHandler.diagram.nameTable[""+this.drawingObject.id]),o=this.pointReduction(o,10);var h={id:"newConnector"+Qe(),type:"Bezier",sourcePoint:{x:o[0].x,y:o[0].y},targetPoint:{x:o[o.length-1].x,y:o[o.length-1].y},segments:[],bezierSettings:{allowSegmentsReset:!1}};this.drawingObject=this.commandHandler.drawObject(h),this.drawingObject=this.bezierCurveSmoothness(o,.5,this.drawingObject,s),this.commandHandler.updateConnectorPoints(this.drawingObject),this.commandHandler.addObjectToDiagram(this.drawingObject),this.triggerElementDrawEvent(this.drawingObject,"Completed","Connector",this.drawingObject.type,!1),n.prototype.mouseUp.call(this,e)}},t.prototype.pointReduction=function(e,i){if(null===e||e.length<3)return e;var s=e.length-1,o=[];for(o.push(0),o.push(s);e[parseInt((0).toString(),10)]===e[parseInt(s.toString(),10)];)s--;this.reduction(e,0,s,i,o);var a=[];return o.sort(function(l,h){return l-h}),o.forEach(function(l){a.push(e[parseInt(l.toString(),10)])}),a},t.prototype.reduction=function(e,i,r,s,o){for(var a=0,l=0,h=i;ha&&(a=c,l=h)}a>s&&0!==l&&(o.push(l),this.reduction(e,i,l,s,o),this.reduction(e,l,r,s,o))},t.prototype.perpendicularDistance=function(e,i,r){return Math.abs(.5*(e.x*i.y-i.x*e.y+(i.x*r.y-r.x*i.y)+(r.x*e.y-e.x*r.y)))/Math.sqrt(Math.pow(e.x-i.x,2)+Math.pow(e.y-i.y,2))*2},t.prototype.bezierCurveSmoothness=function(e,i,r,s){if(e.length<3)return r;for(var o=0;o=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},kne=function(n){if(n)switch(n.type){case"Bpmn":return Hne;case"UmlActivity":return Rne;case"UmlClassifier":return _ne;default:return Jv}return Jv},Pne=function(n){if(n)switch(n.type){case"Straight":default:return Hl;case"Bezier":return fs;case"Orthogonal":return wi}},G3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I(10)],t.prototype,"width",void 0),Pe([I(10)],t.prototype,"height",void 0),Pe([I("Arrow")],t.prototype,"shape",void 0),Pe([re({fill:"black",strokeColor:"black",strokeWidth:1},Ll)],t.prototype,"style",void 0),Pe([re({x:0,y:.5},R)],t.prototype,"pivot",void 0),Pe([I("")],t.prototype,"pathData",void 0),t}(Ee),WI=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I(0)],t.prototype,"angle",void 0),Pe([I(0)],t.prototype,"distance",void 0),t}(Ee),zne=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I(Ix.All)],t.prototype,"controlPointsVisibility",void 0),Pe([I("FreeForm")],t.prototype,"segmentEditOrientation",void 0),Pe([I(mI.Default)],t.prototype,"smoothness",void 0),Pe([I(!0)],t.prototype,"allowSegmentsReset",void 0),t}(Ee),Jv=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I("None")],t.prototype,"type",void 0),t}(Ee),Rne=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I("Object")],t.prototype,"flow",void 0),Pe([I(30)],t.prototype,"exceptionFlowHeight",void 0),t}(Jv),Hne=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I("Sequence")],t.prototype,"flow",void 0),Pe([I("Normal")],t.prototype,"sequence",void 0),Pe([I("Default")],t.prototype,"message",void 0),Pe([I("Default")],t.prototype,"association",void 0),t}(Jv),X3=function(n){function t(e,i,r,s){var o=n.call(this,e,i,r,s)||this;return o.points=[],o}return Qs(t,n),Pe([I("Straight")],t.prototype,"type",void 0),Pe([I(!0)],t.prototype,"allowDrag",void 0),t}(Ee),Hl=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),t.prototype.getClassName=function(){return"StraightSegment"},Pe([re({x:0,y:0},R)],t.prototype,"point",void 0),t}(X3),fs=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),t.prototype.getClassName=function(){return"BezierSegment"},t.prototype.getPoints=function(e,i){var r=[];if(r.length>0||null!=i){var o=this.bezireToPoly(r.length>0?r[r.length-1]:i,e);r.push.apply(r,o)}return r},t.prototype.bezireToPoly=function(e,i){var r=[];return i&&this.flattenCubicBezier(r,e,i.bezierPoint1,i.bezierPoint2,{x:i.points[1].x,y:i.points[1].y},10),r},t.prototype.flattenCubicBezier=function(e,i,r,s,o,a){var h,l=(R.findLength(i,r)+R.findLength(r,s)+R.findLength(s,o))/a;for(h=0;h<=l;h++){var c=h/l;e.push({x:(1-c)*(1-c)*(1-c)*i.x+3*c*(1-c)*(1-c)*r.x+3*c*c*(1-c)*s.x+c*c*c*o.x,y:(1-c)*(1-c)*(1-c)*i.y+3*c*(1-c)*(1-c)*r.y+3*c*c*(1-c)*s.y+c*c*c*o.y})}},Pe([I("Horizontal")],t.prototype,"orientation",void 0),Pe([re({x:0,y:0},R)],t.prototype,"point1",void 0),Pe([re({x:0,y:0},R)],t.prototype,"point2",void 0),Pe([re({angle:0,distance:0},WI)],t.prototype,"vector1",void 0),Pe([re({angle:0,distance:0},WI)],t.prototype,"vector2",void 0),t}(Hl),wi=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),t.prototype.getClassName=function(){return"OrthogonalSegment"},Pe([I(null)],t.prototype,"length",void 0),Pe([I(null)],t.prototype,"direction",void 0),t}(X3);function q3(n,t,e){var s=e?45:180/(2+2/(n.height/n.width)),o=s,a=180-s,l=a+2*s,h=360-s,c=Gt(t,n.center);return c>o&&ca&&cl&&cMath.abs(t.y-n.y)?n.x=c)return s=R.findAngle(n[parseInt(d.toString(),10)],n[d+1]),{point:r=R.transform(n[parseInt(d.toString(),10)],s,c-(a||0)),index:l=d};a=o[parseInt(d.toString(),10)]}return{point:r,index:l}}(n,t),r=R.findAngle(n[i.index],n[i.index+1]),s=function pse(n){var e=0;switch(n.alignment){case"Center":case"After":e=0;break;case"Before":e=-0}return e}(t),o=R.transform(i.point,r+45,s);return i.point=o,i.angle=r,i}(i,e),h=l.point;s.id=this.id+"_"+e.id;var c=e.style;s.style={fill:c.fill,strokeColor:c.strokeColor,gradient:null,opacity:c.opacity,strokeDashArray:c.strokeDashArray,strokeWidth:c.strokeWidth},0===r.width&&(r.width=this.style.strokeWidth),0===r.height&&(r.height=this.style.strokeWidth);var d_y=(h.y-r.y)/r.height;a.x=r.width*((h.x-r.x)/r.width),a.y=r.height*d_y;var g,v,u=dF(e,l.angle,i),f=u.hAlign,p=u.vAlign;return"left"===f?(g="Left",a.x+=e.displacement.x):"right"===f?(g="Right",a.x-=e.displacement.x):"center"===f&&(g="Center"),"top"===p?(v="Top",a.y+=e.displacement.y):"bottom"===p?(v="Bottom",a.y-=e.displacement.y):"center"===p&&(v="Center"),s.horizontalAlignment=g,s.verticalAlignment=v,(s=tm(s,o&&"Label"!==o.flipMode&&"None"!==o.flipMode?this.flip:"None",e)).float=!0,s.connectionDirection=e.connectionDirection,s.setOffsetWithRespectToBounds(a.x,a.y,"Absolute"),s.relativeMode="Point",s.visible=!(!va(e,ci.Visible)||va(e,ci.Hover)||va(e,ci.Connect)),s.elementActions=s.elementActions|Xr.ElementIsPort,s},t.prototype.getConnectorRelation=function(){var e=this.shape;"Association"===e.relationship?(this.segments[0].type="Straight",this.sourceDecorator.shape="None",this.targetDecorator.shape="Arrow"):"Inheritance"===e.relationship?(this.segments[0].type="Orthogonal",this.sourceDecorator.shape="None",this.targetDecorator.shape="Arrow"):"Composition"===e.relationship||"Aggregation"===e.relationship?(this.segments[0].type="Orthogonal",this.sourceDecorator.shape="Diamond",this.targetDecorator.shape="None"):"Dependency"===e.relationship?(this.segments[0].type="Orthogonal",this.sourceDecorator.shape="None",this.targetDecorator.shape="OpenArrow"):"Realization"===e.relationship&&(this.segments[0].type="Orthogonal",this.sourceDecorator.shape="None",this.targetDecorator.shape="Arrow"),"BiDirectional"===e.associationType&&(this.sourceDecorator.shape="None",this.targetDecorator.shape="None");var i,o,r="",s="";e.multiplicity.source&&(e.multiplicity.source.lowerBounds=e.multiplicity.source.lowerBounds,e.multiplicity.source.upperBounds=e.multiplicity.source.upperBounds),e.multiplicity.target&&(e.multiplicity.target.lowerBounds=e.multiplicity.target.lowerBounds,e.multiplicity.target.upperBounds=e.multiplicity.target.upperBounds);var a=e.multiplicity.source,l=e.multiplicity.target;o=a.upperBounds?a.lowerBounds+"..."+a.upperBounds:a.lowerBounds,i=l.upperBounds?l.lowerBounds+"..."+l.upperBounds:l.lowerBounds,"ManyToOne"===e.multiplicity.type&&(e.multiplicity.target.optional=!1,r=o||"*",s="1"),"OneToMany"===e.multiplicity.type&&(e.multiplicity.source.optional=!1,s=i||"*",r="1"),"ManyToMany"===e.multiplicity.type&&(r=o||"*",s=i||"*"),"OneToOne"===e.multiplicity.type&&(e.multiplicity.target.optional=!1,e.multiplicity.source.optional=!1,r="1",s="1"),this.annotations=[{id:this.id+"sourcelabel",content:r,offset:0,alignment:"Before",margin:{right:5,bottom:5}},{id:this.id+"targetlabel",content:s,offset:1,alignment:"Before",margin:{right:5,bottom:5}}]},t.prototype.getBpmnSequenceFlow=function(){var e=new Ze,i=new Ze;return"Normal"===this.shape.sequence&&"Bezier"!==this.type&&(this.targetDecorator.shape="Arrow"),"Default"===this.shape.sequence&&(e=this.getSegmentElement(this,e),i=yF(this.intermediatePoints,this),this.targetDecorator.shape="Arrow"),"Conditional"===this.shape.sequence&&(this.targetDecorator.shape="Arrow",this.sourceDecorator.shape="Diamond",i.id=this.id+this.shape.type),i},t.prototype.getUMLObjectFlow=function(){if(this.annotations)for(var e=0;e0&&(this.sourcePoint=o[0],this.targetPoint=o[o.length-1]),o},t.prototype.clipDecorator=function(e,i,r,s){var a,l,o={x:0,y:0},h=i.length,c=R.distancePoints(a=r?i[0]:i[h-1],l=r?i[1]:i[h-2]);c=0===c?1:c;var d=1,u=r?e.sourceWrapper:e.targetWrapper;u&&(d=u.style.strokeWidth,s&&s&ee.DecoratorPropertyChange&&(d=1));var f=d-1;return o.x=Math.round(a.x+f*(l.x-a.x)/c),o.y=Math.round(a.y+f*(l.y-a.y)/c),(r&&"None"!==e.sourceDecorator.shape||!r&&"None"!==e.targetDecorator.shape)&&(o=R.adjustPoint(o,l,!0,s&ee.DecoratorPropertyChange?0:d/2)),o},t.prototype.clipDecorators=function(e,i,r){return"None"!==e.sourceDecorator.shape&&(i[0]=this.clipDecorator(e,i,!0,r)),"None"!==e.targetDecorator.shape&&(i[i.length-1]=this.clipDecorator(e,i,!1,r)),i},t.prototype.updateSegmentElement=function(e,i,r,s){var o=new Ne,a=this.getSegmentPath(e,i,s);if("Bezier"===e.type){if(this.segments.length>0)for(var l=0;l0)if("Straight"===e.type&&e.segments.length<2)for(var o=0;o1)for(o=0;o0&&"Bezier"!==this.type)for(var f=0;f0&&(a=f0&&(p<2*this.cornerRadius?(l=R.adjustPoint(h[parseInt(f.toString(),10)],h[f+1],!0,p/2),f0&&(s=this.bridgePath(e,s,f),"Orthogonal"===e.type&&(s=this.bridgePath(e,s,f+1))),s+=" L"+a.x+" "+a.y))}else if("Bezier"===this.type){var g=void 0,v=void 0;if(this.parentObj.element){var y=this.parentObj.element.ej2_instances[0].eventHandler.action;g=this.parentObj.element.ej2_instances[0].eventHandler.tool instanceof Pd,v=y.includes("PortDraw")||y.includes("Drag")}for(var S=void 0,b=this.segments,M=0;M2&&(b[parseInt(M.toString(),10)].bezierPoint1={x:0,y:0},b[parseInt(M.toString(),10)].bezierPoint2={x:0,y:0}),!R.isEmptyPoint(b[parseInt(M.toString(),10)].point1)||b[parseInt(M.toString(),10)].vector1.angle||b[parseInt(M.toString(),10)].vector1.distance?b[parseInt(M.toString(),10)].vector1.angle||b[parseInt(M.toString(),10)].vector1.distance?b[parseInt(M.toString(),10)].bezierPoint1=R.transform(h[parseInt(M.toString(),10)],b[parseInt(M.toString(),10)].vector1.angle,b[parseInt(M.toString(),10)].vector1.distance):b[parseInt(M.toString(),10)].bezierPoint1={x:b[parseInt(M.toString(),10)].point1.x||b[parseInt(M.toString(),10)].bezierPoint1.x,y:b[parseInt(M.toString(),10)].point1.y||b[parseInt(M.toString(),10)].bezierPoint1.y}:((e.sourceID||this.sourcePortID)&&this.sourceWrapper&&!v&&!g&&(S=q3(this.sourceWrapper.bounds,h[parseInt(M.toString(),10)],!0)),b[parseInt(M.toString(),10)].bezierPoint1=QI(h[parseInt(M.toString(),10)],h[M+1],S)),!R.isEmptyPoint(b[parseInt(M.toString(),10)].point2)||b[parseInt(M.toString(),10)].vector2.angle||b[parseInt(M.toString(),10)].vector2.distance?b[parseInt(M.toString(),10)].vector2.angle||b[parseInt(M.toString(),10)].vector2.distance?b[parseInt(M.toString(),10)].bezierPoint2=R.transform(h[M+1],b[parseInt(M.toString(),10)].vector2.angle,b[parseInt(M.toString(),10)].vector2.distance):b[parseInt(M.toString(),10)].bezierPoint2={x:b[parseInt(M.toString(),10)].point2.x||b[parseInt(M.toString(),10)].bezierPoint2.x,y:b[parseInt(M.toString(),10)].point2.y||b[parseInt(M.toString(),10)].bezierPoint2.y}:((e.targetID||this.targetPortID)&&this.targetWrapper&&!v&&!g&&(S=q3(this.targetWrapper.bounds,h[M+1],!0)),b[parseInt(M.toString(),10)].bezierPoint2=QI(h[M+1],h[parseInt(M.toString(),10)],S));h.splice(1,0,{x:b[0].bezierPoint1.x,y:b[0].bezierPoint1.y}),h.splice(h.length-1,0,{x:b[b.length-1].bezierPoint2.x,y:b[b.length-1].bezierPoint2.y}),h=this.clipDecorators(e,h,r);for(var w=0;w0&&(s=this.bridgePath(e,s,D),s+=" L"+o.x+" "+o.y);return s},t.prototype.updateShapeElement=function(e){var i;switch(e.shape.type){case"Bpmn":e.wrapper.children[3]instanceof Ze&&(i=e.wrapper.children[3]),"Message"===e.shape.flow&&this.updateShapePosition(e,i);break;case"UmlActivity":"Exception"===e.shape.flow&&this.getUMLExceptionFlow(e.wrapper.children[0])}},t.prototype.updateShapePosition=function(e,i){var o=SF(this.intermediatePoints,i,.5);i.offsetX=o.x,i.offsetY=o.y},t.prototype.scale=function(e,i,r,s,o){var a=0,l=0;if(this.wrapper&&this.wrapper.outerBounds){var h=function I3(n){var t=n.wrapper.children[0].bounds;return"None"!==n.sourceDecorator.shape&&t.uniteRect(n.wrapper.children[1].bounds),"None"!==n.targetDecorator.shape&&t.uniteRect(n.wrapper.children[2].bounds),t}(this),c=Math.abs((this.wrapper.bounds.width||this.style.strokeWidth||1)-2),d=Math.abs((this.wrapper.bounds.height||this.style.strokeWidth||1)-2);a=h.width-c,l=h.height-d,e=Math.abs((r-Math.max(a,l))/c),i=Math.abs((s-Math.max(a,l))/d),a=l=Math.min(a,l)}e=i=Math.min(e,i);var u=Bi();qi(u,-(o=o||this.wrapper).rotateAngle,o.offsetX,o.offsetY),Yf(u,e,i,o.offsetX,o.offsetY),qi(u,o.rotateAngle,o.offsetX,o.offsetY);var f=function Tie(n,t){for(var e=[],i=0,r=t;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},jne=function(n){function t(e,i){var r=n.call(this,e,i)||this;return r.offset=0,r.scale=1,r}return Une(t,n),t.prototype.preRender=function(){this.unWireEvents(),this.wireEvents()},t.prototype.render=function(){this.updateRulerGeometry(),this.renderComplete()},t.prototype.getModuleName=function(){return"Ruler"},t.prototype.destroy=function(){this.unWireEvents(),this.notify("destroy",{}),n.prototype.destroy.call(this),this.element.classList.remove("e-ruler")},t.prototype.getPersistData=function(){return this.addOnPersist(["loaded"])},t.prototype.onPropertyChanged=function(e,i){for(var r=0,s=Object.keys(e);r100;)r/=10,s/=10;for(;s<25;)r*=10,s*=10;return s>=25&&s%25!=0&&(s=25*Math.round(s/25)),s*e/r},t.prototype.createMarkerLine=function(e,i,r){var s;return i&&((s=e.getElementById(i.id+"_marker"))&&s.parentNode.removeChild(s),s=Fi("line",r)),s},t.prototype.drawRulerMarker=function(e,i,r){var s,o,h,d,u="Horizontal"===this.orientation,f=e.getElementsByTagName("svg");for(h=0;h0)for(var a=i.childNodes.length-1;a>=0;a--)i.childNodes[parseInt(a.toString(),10)].parentNode.removeChild(i.childNodes[parseInt(a.toString(),10)]);i.appendChild(s)}return s},t.prototype.wireEvents=function(){},t.prototype.unWireEvents=function(){},kc([I(5)],t.prototype,"interval",void 0),kc([I(100)],t.prototype,"segmentWidth",void 0),kc([I("Horizontal")],t.prototype,"orientation",void 0),kc([I("RightOrBottom")],t.prototype,"tickAlignment",void 0),kc([I("red")],t.prototype,"markerColor",void 0),kc([I(25)],t.prototype,"thickness",void 0),kc([I(null)],t.prototype,"arrangeTick",void 0),kc([I(400)],t.prototype,"length",void 0),t}(Ii);function J3(n,t){var e=document.getElementById(n.element.id+(t?"_hRuler":"_vRuler")),i=Za(n),r=K3(n);e||(e=Tt("div",{id:n.element.id+(t?"_hRuler":"_vRuler"),style:"height:"+(t?i.height:r.height+100)+"px;overflow:hidden;width:"+(t?r.width+100:i.width)+"px;position:absolute;font-size:11px;"+(t?"margin-left:"+i.width+"px;":"margin-top:"+i.height+"px;")})),n.element.insertBefore(e,n.element.firstChild);var l=t?n.rulerSettings.horizontalRuler:n.rulerSettings.verticalRuler,h=new jne(l);h.orientation=t?"Horizontal":"Vertical",h.length=(t?r.width:r.height)+l.segmentWidth,h.appendTo("#"+n.element.id+(t?"_hRuler":"_vRuler")),t?n.hRuler=h:n.vRuler=h;var c=document.getElementById(n.element.id+(t?"_hRuler":"_vRuler"));t?n.hRuler.element=c:n.vRuler.element=c}function GI(n){var t=-n.scroller.horizontalOffset,e=-n.scroller.verticalOffset;n&&n.rulerSettings.showRulers?(n.hRuler.length=0,n.vRuler.length=0,void 0!==t&&n.hRuler.element&&eF(n,n.hRuler,t,!0),void 0!==e&&n.vRuler.element&&eF(n,n.vRuler,e,!1)):Yx(n)}function Yx(n){an(n.element.id+"_hRuler"),an(n.element.id+"_vRuler"),an(n.element.id+"_overlapRuler")}function Za(n){var t=0,e=0;return n.rulerSettings.showRulers&&(t=n.rulerSettings.horizontalRuler.thickness,e=n.rulerSettings.verticalRuler.thickness),new me(e,t)}function K3(n){var t=Za(n),e=n.scroller.viewPortHeight,i=n.scroller.viewPortWidth;return i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},tF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Xne(t,n),t.prototype.getClassName=function(){return"UserHandle"},Un([I("")],t.prototype,"name",void 0),Un([I("")],t.prototype,"pathData",void 0),Un([I("")],t.prototype,"content",void 0),Un([I("")],t.prototype,"source",void 0),Un([I("#000000")],t.prototype,"backgroundColor",void 0),Un([I("Top")],t.prototype,"side",void 0),Un([I("")],t.prototype,"borderColor",void 0),Un([I(.5)],t.prototype,"borderWidth",void 0),Un([I(25)],t.prototype,"size",void 0),Un([I("white")],t.prototype,"pathColor",void 0),Un([I(10)],t.prototype,"displacement",void 0),Un([I(!0)],t.prototype,"visible",void 0),Un([I(0)],t.prototype,"offset",void 0),Un([re({},Jn)],t.prototype,"margin",void 0),Un([I("Center")],t.prototype,"horizontalAlignment",void 0),Un([I("Center")],t.prototype,"verticalAlignment",void 0),Un([I(!1)],t.prototype,"disableNodes",void 0),Un([I(!1)],t.prototype,"disableConnectors",void 0),Un([re({},Dd)],t.prototype,"tooltip",void 0),Un([I("")],t.prototype,"template",void 0),t}(Ee);function iF(n){return qne[n.toString()]}var qne={Action:"M 90 82.895 C 90 86.819 86.776 90 82.8 90 H 7.2 C 3.224 90 0 86.819 0 82.895 V 7.105 C 0 3.181 3.224 0 7.2 0 h 75.6 C 86.776 0 90 3.181 90 7.105 V 82.895 Z",Decision:"M10,19.707L0.293,10L10,0.293L19.707,10L10,19.707z",MergeNode:"M10,19.707L0.293,10L10,0.293L19.707,10L10,19.707z",InitialNode:"M10,19.5c-5.238,0-9.5-4.262-9.5-9.5S4.762,0.5,10,0.5s9.5,4.262,9.5,9.5S15.238,19.5,10,19.5z",ForkNode:"m0.75,0.75l636.00002,0l0,290l-636.00002,0l0,-290z",JoinNode:"m0.75,0.75l636.00002,0l0,290l-636.00002,0l0,-290z",TimeEvent:"M50.001,0.00286865 L25.001,25.0029 L0.000976562,0.00286865 L50.001,0.00286865 z M0.000976562,50.0029 L25.001,25.0029 L50.001,50.0029 L0.000976562,50.0029 z",AcceptingEvent:"M17.8336 32.164 L29.64 24 L17.32 16 L48.1664 16 L48.5 32 Z",SendSignal:"M48.164 31.8336 L56 23.832 L47.836 16 L16.168 16 L16.1668 31.8336 Z",ReceiveSignal:"M48.1664 31.8336 L39.836 24 L47.836 16 L16.168 16 L16.168 31.836 Z",StructuredNode:"M0,0 L50,0 L50,50 L0,50 z",Note:"M20 12 L4 12 L4 22 L22 22 L22 14 L20 14 L20 12 L22 14 Z"},XI=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Ja=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},$ne=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return XI(t,n),Ja([I()],t.prototype,"key",void 0),Ja([I()],t.prototype,"keyModifiers",void 0),t}(Ee),rF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return XI(t,n),t.prototype.getClassName=function(){return"Command"},Ja([I("")],t.prototype,"name",void 0),Ja([I()],t.prototype,"canExecute",void 0),Ja([I()],t.prototype,"execute",void 0),Ja([re({},$ne)],t.prototype,"gesture",void 0),Ja([I("")],t.prototype,"parameter",void 0),t}(Ee),Zne=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return XI(t,n),Ja([Ft([],rF)],t.prototype,"commands",void 0),t}(Ee),Jne=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return XI(t,n),Ja([I()],t.prototype,"show",void 0),Ja([I()],t.prototype,"showCustomMenuOnly",void 0),Ja([I()],t.prototype,"items",void 0),t}(Ee),$f=function(){function n(){}return n.prototype.renderShadow=function(t,e,i,r){void 0===i&&(i=null);var l,o=R.transform({x:0,y:0},t.shadow.angle,t.shadow.distance);r&&(l=r.getElementById(e.id+"_shadow")),l||(l=document.createElementNS("http://www.w3.org/2000/svg",i?"path":"rect"),e.appendChild(l));var h={id:e.id+"_shadow",fill:t.shadow.color,stroke:t.shadow.color,opacity:t.shadow.opacity.toString(),transform:"rotate("+t.angle+","+(t.x+t.width*t.pivotX)+","+(t.y+t.height*t.pivotY)+")translate("+(t.x+o.x)+","+(t.y+o.y)+")"};if(r){var c=r.getElementById(e.id);c&&c.insertBefore(l,c.firstChild)}ti(l,h),i?i&&this.renderPath(l,t,i):ti(l,{width:t.width,height:t.height})},n.prototype.parseDashArray=function(t){return[]},n.prototype.drawRectangle=function(t,e,i,r,s,o,a,l,h){var c,d,u,f;e.shadow&&!r&&this.renderShadow(e,t,void 0,o),c=e.id===t.id?e.id+"_container":e.id,o&&(d=o.getElementById(c)),(!d||s)&&(d=document.createElementNS("http://www.w3.org/2000/svg","rect"),t.appendChild(d)),o&&!e.shadow&&(u=o.getElementById(e.id+"_groupElement_shadow"))&&u.parentNode.removeChild(u),f=l?{id:c,x:e.x.toString(),y:e.y.toString(),width:e.width.toString(),height:e.height.toString(),visibility:e.visible?"visible":"hidden",transform:"rotate("+e.angle+","+(e.x+e.width/2)+","+(e.y+e.height/2)+")",rx:e.cornerRadius||0,ry:e.cornerRadius||0,opacity:e.opacity}:{id:c,x:e.x.toString(),y:e.y.toString(),width:e.width.toString(),height:e.height.toString(),visibility:e.visible?"visible":"hidden",transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")",rx:e.cornerRadius||0,ry:e.cornerRadius||0,opacity:e.opacity},a&&(f.role="img",f["aria-label"]=a);var p=e.class||"";h||(p.includes("e-diagram-resize-handle")||p.includes("e-diagram-endpoint-handle")||p.includes("e-diagram-bezier-control-handle"))&&(p+=" e-disabled"),e.class&&(f.class=p),a||(f["pointer-events"]="none"),ti(d,f),this.setSvgStyle(d,e,i)},n.prototype.updateSelectionRegion=function(t,e){var i;i=t.parentNode.getElementById(e.id);var r={id:e.id,x:e.x.toString(),y:e.y.toString(),width:e.width.toString(),height:e.height.toString(),transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")",class:"e-diagram-selected-region"};i||(i=document.createElementNS("http://www.w3.org/2000/svg","rect"),t.appendChild(i)),this.setSvgStyle(i,e),ti(i,r)},n.prototype.createGElement=function(t,e){return Fi(t,e)},n.prototype.drawLine=function(t,e){var i=document.createElementNS("http://www.w3.org/2000/svg","line");this.setSvgStyle(i,e);var r=e.x+e.width*e.pivotX,s=e.y+e.height*e.pivotY,o={id:e.id,x1:e.startPoint.x+e.x,y1:e.startPoint.y+e.y,x2:e.endPoint.x+e.x,y2:e.endPoint.y+e.y,stroke:e.stroke,"stroke-width":e.strokeWidth.toString(),opacity:e.opacity.toString(),transform:"rotate("+e.angle+" "+r+" "+s+")",visibility:e.visible?"visible":"hidden"};e.class&&(o.class=e.class),ti(i,o),t.appendChild(i)},n.prototype.drawCircle=function(t,e,i,r){var s=document.createElementNS("http://www.w3.org/2000/svg","circle");this.setSvgStyle(s,e);var o=e.class||"";i||(o+=" e-disabled");var a={id:e.id,cx:e.centerX,cy:e.centerY,r:e.radius,visibility:e.visible?"visible":"hidden",class:o};r&&(a.role="img",a["aria-label"]=r),s.style.display=e.visible?"block":"none",ti(s,a),t.appendChild(s)},n.prototype.drawPath=function(t,e,i,r,s,o,a){var h,c,l=[];l=QB(l=Ed(e.data)),e.shadow&&this.renderShadow(e,t,l,s),s&&!e.shadow&&(h=s.getElementById(e.id+"_groupElement_shadow"))&&h.parentNode.removeChild(h),s&&(c=s.getElementById(e.id)),(!c||r)&&(c=document.createElementNS("http://www.w3.org/2000/svg","path"),t.appendChild(c)),this.renderPath(c,e,l);var d={};d=a?{id:e.id,transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")translate("+e.x+","+e.y+"),scale("+a+")",visibility:e.visible?"visible":"hidden",opacity:e.opacity}:{id:e.id,transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")translate("+e.x+","+e.y+")",visibility:e.visible?"visible":"hidden",opacity:e.opacity},o&&(d.role="img",d["aria-label"]=o),e.class&&(d.class=e.class),ti(c,d),this.setSvgStyle(c,e,i)},n.prototype.renderPath=function(t,e,i){var r,s,o,a,l,h,c,d,u=i,f="";for(l=0,h=0,d=0,c=u.length;de.width&&"Wrap"!==e.textOverflow&&"NoWrap"===e.textWrapping&&(h[0].text=UF(e.content,e)),v=0;vD&&(u.text=u.text.slice(0,u.text.length-3),u.text=u.text.concat("..."),l.data=u.text),this.alignText(y,f,u,l,p,g,v,e,h),C+=u.dy}}C&&e.isHorizontalLane&&(M=e.parentOffsetX+e.pivotX,w=e.parentOffsetY+e.pivotY,e.y=e.parentOffsetY-C*e.pivotY+.5),e.textDecoration&&"LineThrough"===e.textDecoration&&(e.textDecoration=lb(e.textDecoration));var P={id:e.id+"_text",fill:e.color,visibility:e.visible?"visible":"hidden","text-decoration":e.textDecoration,transform:"rotate("+e.angle+","+M+","+w+")translate("+e.x+","+e.y+")",opacity:e.opacity};r&&(P.role="img",P["aria-label"]=r),ti(y,P)}},n.prototype.alignText=function(t,e,i,r,s,o,a,l,h){"justify"!==l.textAlign?this.setText(t,e,i,r,s,o,l):a!==h.length-1?this.setText(t,e,i,r,s,o,l,l.width,"spacing"):this.setText(t,e,i,r,s,o,l)},n.prototype.setText=function(t,e,i,r,s,o,a,l,h){ti(e,"justify"!==a.textAlign?{x:s.toString(),y:o.toString()}:{x:s.toString(),y:o.toString(),textLength:l||0,lengthAdjust:h||"spacing"}),t.setAttribute("fill",i.text),e.appendChild(r),t.appendChild(e)},n.prototype.drawImage=function(t,e,i,r){var s;i&&(s=i.getElementById(e.id+"image")),s||(s=document.createElementNS("http://www.w3.org/2000/svg","image"),t.appendChild(s));var o=new Image;o.src=e.source;var a="None"!==e.scale?e.scale:"",l=e.alignment,h=l.charAt(0).toLowerCase()+l.slice(1);"Stretch"!==a&&(h+=" "+a.charAt(0).toLowerCase()+a.slice(1)),ti(s,{id:e.id+"image",x:e.x.toString(),y:e.y.toString(),transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")",width:e.width.toString(),visibility:e.visible?"visible":"hidden",height:e.height.toString(),preserveAspectRatio:h,opacity:e.opacity.toString()}),s.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",o.src.toString())},n.prototype.drawHTMLContent=function(t,e,i,r,s){var o,a;if(e&&(o=e.querySelector("#"+t.id+"_html_element")),!o){(a=e.querySelector("#"+t.id+"_html_element")||e.querySelector("#"+t.nodeId+"_html_element"))||(a=Tt("div",{id:t.nodeId+"_html_element",class:"foreign-object"})),o=Tt("div",{id:t.id+"_html_element",class:"foreign-object"});var c=document.getElementById(t.diagramId).ej2_instances[0],d=!1;if(e.parentNode&&e.parentNode.parentNode&&e.parentNode.parentNode.parentNode&&e.parentNode.parentNode.parentNode.classList.contains("e-overview")&&(d=!0),d)c.isReact?c.renderReactTemplates(function(){o.appendChild(t.template.cloneNode(!0))}):o.appendChild(t.template.cloneNode(!0));else{if("string"==typeof t.template){var u=document.createElement("div");u.innerHTML=t.template,t.template=u,c.selectedItems.userHandles.filter(function(g){return g.name===t.id.split("_shape")[0]&&""!==g.template})[0].template=t.template}t.isTemplate&&t.template?o.appendChild(t.template):t.template&&o.appendChild(t.template.cloneNode(!0))}void 0!==s&&e.childNodes.length>s&&e.insertBefore(o,e.childNodes[parseInt(s.toString(),10)]),a.appendChild(o),e.appendChild(a)}var p=xn(t).topLeft;o.setAttribute("style","height:"+t.actualSize.height+"px; width:"+t.actualSize.width+"px;left:"+p.x+"px; top:"+p.y+"px;position:absolute;transform:rotate("+(t.rotateAngle+t.parentTransform)+"deg);pointer-events:"+(r?"all":"none")+";visibility:"+(t.visible?"visible":"hidden")+";opacity:"+t.style.opacity+";")},n.prototype.drawNativeContent=function(t,e,i,r,s){var o,a;if(s&&(o=s.getElementById(t.id+"_native_element"),a=s.getElementById(t.id+"_clip")),!o){(o=document.createElementNS("http://www.w3.org/2000/svg","g")).setAttribute("id",t.id+"_native_element"),o.appendChild(t.template.cloneNode(!0));var l=this.createGElement("g",{id:t.id+"_inner_native_element"});l.appendChild(o),e.appendChild(l)}a&&o.removeChild(a),o.setAttribute("style","visibility:"+(t.visible?"visible":"hidden")+";opacity:"+t.style.opacity+";"),this.setNativTransform(t,o,i,r),"Slice"===t.scale&&this.drawClipPath(t,o,i,r,s),ti(o,t.description?{role:"img","aria-label":t.description}:{})},n.prototype.setNativTransform=function(t,e,i,r){var s=0!==t.contentSize.width?t.contentSize.width:1,o=0!==t.contentSize.height?t.contentSize.height:1;e.setAttribute("transform","rotate("+t.parentTransform+","+t.offsetX+","+t.offsetY+") translate("+(t.offsetX-t.templatePosition.x*r/s-r*t.pivot.x)+","+(t.offsetY-t.templatePosition.y*i/o-i*t.pivot.y)+") scale("+r/s+","+i/o+")")},n.prototype.drawClipPath=function(t,e,i,r,s){var o=t.contentSize.width,a=t.contentSize.height,l=t.width/(r/o),h=t.height/(i/a),c=t.templatePosition.x+(t.width>=t.height?0:(o-l)/2),d=t.templatePosition.y+(t.height>=t.width?0:(a-h)/2),u=s.getElementById(t.id+"_clip");(u=document.createElementNS("http://www.w3.org/2000/svg","clipPath")).setAttribute("id",t.id+"_clip"),e.appendChild(u);var f=s.getElementById(t.id+"_clip_rect");return f=document.createElementNS("http://www.w3.org/2000/svg","rect"),u.appendChild(f),ti(f,{id:t.id+"_clip_rect",width:l.toString(),height:h.toString(),x:c.toString(),y:d.toString()}),rm()?e.setAttribute("clip-path","url("+location.protocol+"//"+location.host+location.pathname+"#"+t.id+"_clip)"):e.setAttribute("clip-path","url(#"+t.id+"_clip)"),e},n.prototype.renderGradient=function(t,e,i){var r,s,o,h,c,a=vT(i),l=a.getElementById(i+"gradient_pattern");if(l||(l=Fi("defs",{id:i+"gradient_pattern"}),a.insertBefore(l,a.firstChild)),fF(e.id),"None"!==t.gradient.type){for(var d=0;dt.width&&("Ellipsis"===t.textOverflow||"Clip"===t.textOverflow)&&"NoWrap"===t.textWrapping?0:.5*t.width:"right"===t.textAlign&&(c=1*t.width),s.x=0+c+(e?e.x:0),s.y=1.2+d-r.height/2,s},n}(),Pc=function(){function n(t,e,i){this.renderer=null,this.isSvgMode=!0,this.touchMove=void 0,this.transform={x:0,y:0},this.diagramId=t,this.element=xt(this.diagramId),this.svgRenderer=e,this.isSvgMode=i,this.renderer=i?new $f:new bo}return n.prototype.setCursor=function(t,e){t.style.cursor=e},n.prototype.setLayers=function(){this.iconSvgLayer=this.element.getElementsByClassName("e-ports-expand-layer")[0],this.adornerSvgLayer=this.element.getElementsByClassName("e-adorner-layer")[0],this.nativeSvgLayer=this.element.getElementsByClassName("e-native-layer")[0],this.diagramSvgLayer=this.element.getElementsByClassName("e-diagram-layer")[0]},n.prototype.getAdornerLayer=function(){return pT(this.diagramId)},n.prototype.getParentSvg=function(t,e,i){return this.diagramId&&t&&t.id?t.id.split("_icon_content").length>1||t.id.split("_nodeport").length>1||t.elementActions&Xr.ElementIsPort?this.iconSvgLayer:e&&"selector"===e?this.adornerSvgLayer:t instanceof En?this.nativeSvgLayer:this.diagramSvgLayer:i},n.prototype.getParentElement=function(t,e,i,r){var s=e;if(i&&this.diagramId&&t&&t.id){t.id.split("_icon_content").length>1?(s=i.getElementById(this.diagramId+"_diagramExpander"),e=null):t.id.split("_nodeport").length>1?s=i.getElementById(this.diagramId+"_diagramPorts"):t instanceof En?(s=i.getElementById(this.diagramId+"_nativeLayer"),e=null):t.elementActions&Xr.ElementIsPort?(s=i.getElementById(this.diagramId+"_diagramPorts"),e=null):s=i.getElementById(this.diagramId+"_diagramLayer");var o=this.getGroupElement(t,e||s,r);s=o.g,o.svg&&(i=o.svg)}return{g:s,svg:i}},n.prototype.getGroupElement=function(t,e,i){var r,o,s=this.getParentSvg(t);if(e&&s){if(s&&!(r=s.getElementById(t.id+"_groupElement"))&&s!==this.nativeSvgLayer){var a=this.nativeSvgLayer;r=a.getElementById(t.id+"_groupElement"),o=a}r||(r=this.svgRenderer.createGElement("g",{id:t.id+"_groupElement"}),void 0!==i&&e.childNodes.length>i?e.insertBefore(r,e.childNodes[parseInt(i.toString(),10)]):e.appendChild(r))}return{g:r,svg:o}},n.prototype.renderElement=function(t,e,i,r,s,o,a,l,h,c,d){t instanceof Cs?(t.id=t.id?t.id:Qe(),this.renderContainer(t,e,i,r,s,o,a,l,h,c,d)):t instanceof SI?this.renderImageElement(t,e,r,s,a):t instanceof Ze?this.renderPathElement(t,e,r,s,a,h,d):t instanceof ai?this.renderTextElement(t,e,r,s,a,c):t instanceof En?this.renderNativeElement(t,e,r,s,a):t instanceof es?this.renderHTMLElement(t,e,i,r,s,a,l):this.renderRect(t,e,r,s,h)},n.prototype.drawSelectionRectangle=function(t,e,i,r,s,o){var a={width:i*o.scale,height:r*o.scale,x:.5+(t=(t+o.tx)*o.scale),y:.5+(e=(e+o.ty)*o.scale),fill:"transparent",stroke:"gray",angle:0,pivotX:.5,pivotY:.5,strokeWidth:1,dashArray:"6 3",opacity:1,visible:!0,id:s.id+"_selected_region"},l=this.getAdornerLayer();this.svgRenderer.updateSelectionRegion(l,a)},n.prototype.renderHighlighter=function(t,e,i){var r=t.actualSize.width||2,s=t.actualSize.height||2,o=t.offsetX-r*t.pivot.x,a=t.offsetY-s*t.pivot.y;this.svgRenderer.drawRectangle(e,{width:r*i.scale,height:s*i.scale,x:o=(o+i.tx)*i.scale,y:a=(a+i.ty)*i.scale,fill:"transparent",stroke:"#8CC63F",angle:t.rotateAngle,pivotX:t.pivot.x,pivotY:t.pivot.y,strokeWidth:4,dashArray:"",opacity:1,cornerRadius:0,visible:!0,id:e.id+"_highlighter",class:"e-diagram-highlighter"},this.diagramId,void 0,void 0,e)},n.prototype.renderSelectionRectangle=function(t,e,i,r){var s=t.actualSize.width||2,o=t.actualSize.height||2,a=t.offsetX-s*t.pivot.x,l=t.offsetY-o*t.pivot.y,h={width:s*i.scale,height:o*i.scale,x:a=(a+i.tx)*i.scale,y:l=(l+i.ty)*i.scale,fill:"transparent",stroke:"#00cc00",angle:t.rotateAngle,pivotX:t.pivot.x,pivotY:t.pivot.y,strokeWidth:r?2:1,dashArray:"",opacity:1,cornerRadius:0,visible:!0,id:t.id+"_highlighter",class:r?"e-diagram-first-selection-indicator e-diagram-selection-indicator":"e-diagram-selection-indicator"},c=this.getParentSvg(t,"selector");this.svgRenderer.drawRectangle(e,h,this.diagramId,void 0,void 0,c)},n.prototype.renderSelectionLine=function(t,e,i,r){var s=this.getBaseAttributes(t,i);s.data=t.absolutePath,s.id=s.id+"_highlighter";var o=t.description?t.description:t.id;this.isSvgMode||(s.x=t.flipOffset.x?t.flipOffset.x:s.x,s.y=t.flipOffset.y?t.flipOffset.y:s.y),i&&(s.x=s.x*i.scale,s.y=s.y*i.scale),s.stroke="#00cc00",s.strokeWidth=r?2:1,s.class=r?"e-diagram-first-selection-indicator e-diagram-selection-indicator":"e-diagram-selection-indicator";var a=this.getParentSvg(t,"selector");this.svgRenderer.drawPath(e,s,this.diagramId,void 0,a,o,i.scale)},n.prototype.renderStackHighlighter=function(t,e,i,r,s,o,a){var l=t.actualSize.width||2,h=t.offsetX-l*t.pivot.x,c=t.actualSize.height||2,d=t.offsetY-c*t.pivot.y;h=(h+i.tx)*i.scale;var u,f=t.bounds,p="";if(d=(d+i.ty)*i.scale,r)if(o){var v,y;u="M 0 0 L "+(2+(g=l*i.scale))+" 0 Z",v=t.actualSize.width/Number(f.width?f.width:1)*i.scale,y=t.actualSize.height/Number(f.height?f.height:1)*i.scale,p=pI(gI(Ed("M7,4 L8,4 8,7 11,7 11,8 8,8 8,11 7,11 7,8 4,8 4,7 7,7 z M7.5,0.99999994C3.9160004,1 1,3.9160004 0.99999994,7.5 1,11.084 3.9160004,14 7.5,14 11.084,14 14,11.084 14,7.5 14,3.9160004 11.084,1 7.5,0.99999994 z M7.5,0 C11.636002,0 15,3.3639984 15,7.5 15,11.636002 11.636002,15 7.5,15 3.3640003,15 0,11.636002 0,7.5 0,3.3639984 3.3640003,0 7.5,0 z")),v+g+2,y-8,!1,f.x,f.y,0,0),s.y>=t.offsetY&&(d+=c)}else{var g;a&&s.y>=t.offsetY&&(d+=c*i.scale),u="M -10 -10 L 0 0 Z M -10 10 L 0 0 Z M 0 0 L "+(g=l*i.scale)+" 0 Z M "+g+" 0 L "+(g+10)+" 10 Z L "+(g+10)+" -10 Z"}else u="M 10 -10 L 0 0 Z M -10 -10 L 0 0 Z M 0 0 L 0 "+(g=c*i.scale)+" Z M 0 "+g+" L -10 "+(g+10)+" Z L 10 "+(g+10)+" Z",s.x>=t.offsetX&&(h+=l*i.scale);this.svgRenderer.drawPath(e,{data:u+p,width:l*i.scale,height:c*i.scale,x:h,y:d,fill:"transparent",stroke:"#8CC63F",angle:t.rotateAngle,pivotX:t.pivot.x,pivotY:t.pivot.y,strokeWidth:1,dashArray:"",opacity:1,visible:!0,id:e.id+"_stack_highlighter",class:"e-diagram-highlighter"},this.diagramId)},n.prototype.drawLine=function(t,e){this.svgRenderer.drawLine(t,e)},n.prototype.drawPath=function(t,e){this.svgRenderer.drawPath(t,e,this.diagramId)},n.prototype.renderResizeHandle=function(t,e,i,r,s,o,a,l,h,c,d){var u=t.offsetX-t.actualSize.width*t.pivot.x,f=t.offsetY-t.actualSize.height*t.pivot.y,p=t.actualSize.height,g=t.actualSize.width;if(!c&&i&bt.Rotate&&zI(this.rendererActions)&&!x3(this.rendererActions))this.renderPivotLine(t,e,o,s,a),this.renderRotateThumb(t,e,o,s,a);else if(this.touchMove){var v=document.getElementById("rotateThumb");v&&v.setAttribute("visibility","hidden")}this.renderBorder(t,e,o,l,h,c);var y=t.actualSize.width*r,S=t.actualSize.height*r;!h&&zI(this.rendererActions)&&!x3(this.rendererActions)&&(t.isTextAnnotation||(y>=40&&S>=40&&(s&lr.ResizeNorthWest&&this.renderCircularHandle("resizeNorthWest",t,u,f,e,qr(s,"ResizeNorthWest"),i&bt.ResizeNorthWest,o,void 0,a,{"aria-label":"Thumb to resize the selected object on top left side direction"},void 0,"e-diagram-resize-handle e-northwest",d),s&lr.ResizeNorthEast&&this.renderCircularHandle("resizeNorthEast",t,u+g,f,e,qr(s,"ResizeNorthEast"),i&bt.ResizeNorthEast,o,void 0,a,{"aria-label":"Thumb to resize the selected object on top right side direction"},void 0,"e-diagram-resize-handle e-northeast",d),s&lr.ResizeSouthWest&&this.renderCircularHandle("resizeSouthWest",t,u,f+p,e,qr(s,"ResizeSouthWest"),i&bt.ResizeSouthWest,o,void 0,a,{"aria-label":"Thumb to resize the selected object on bottom left side direction"},void 0,"e-diagram-resize-handle e-southwest",d),s&lr.ResizeSouthEast&&this.renderCircularHandle("resizeSouthEast",t,u+g,f+p,e,qr(s,"ResizeSouthEast"),i&bt.ResizeSouthEast,o,void 0,a,{"aria-label":"Thumb to resize the selected object on bottom right side direction"},void 0,"e-diagram-resize-handle e-southeast",d)),s&lr.ResizeNorth&&this.renderCircularHandle("resizeNorth",t,u+g/2,f,e,qr(s,"ResizeNorth"),i&bt.ResizeNorth,o,void 0,a,{"aria-label":"Thumb to resize the selected object on top side direction"},void 0,"e-diagram-resize-handle e-north",d),s&lr.ResizeSouth&&this.renderCircularHandle("resizeSouth",t,u+g/2,f+p,e,qr(s,"ResizeSouth"),i&bt.ResizeSouth,o,void 0,a,{"aria-label":"Thumb to resize the selected object on bottom side direction"},void 0,"e-diagram-resize-handle e-south",d),s&lr.ResizeWest&&this.renderCircularHandle("resizeWest",t,u,f+p/2,e,qr(s,"ResizeWest"),i&bt.ResizeWest,o,void 0,a,{"aria-label":"Thumb to resize the selected object on left side direction"},void 0,"e-diagram-resize-handle e-west",d),s&lr.ResizeEast&&this.renderCircularHandle("resizeEast",t,u+g,f+p/2,e,qr(s,"ResizeEast"),i&bt.ResizeEast,o,void 0,a,{"aria-label":"Thumb to resize the selected object on right side direction"},void 0,"e-diagram-resize-handle e-east",d)))},n.prototype.renderEndPointHandle=function(t,e,i,r,s,o,a,l,h,c){var p,g,d=t.sourcePoint,u=t.targetPoint,f=t.wrapper;if(this.renderCircularHandle("connectorSourceThumb",f,d.x,d.y,e,qr(r,"ConnectorSourceThumb"),i&bt.ConnectorSource,s,o,void 0,{"aria-label":"Thumb to move the source point of the connector"},void 0,"e-diagram-endpoint-handle e-sourceend",c),this.renderCircularHandle("connectorTargetThumb",f,u.x,u.y,e,qr(r,"ConnectorTargetThumb"),i&bt.ConnectorTarget,s,a,void 0,{"aria-label":"Thumb to move the target point of the connector"},void 0,"e-diagram-endpoint-handle e-targetend",c),l)if("Straight"===t.type&&t.segments.length>0)for(p=0;p0)for(p=0;p=3&&3===t.segments.length&&(S=1,b=t.segments.length-1),S=t.segments.length>t.maxSegmentThumb+2?2:S,b=t.segments.length>t.maxSegmentThumb+2?t.segments.length-2:b,1===t.segments.length&&t.segments[0].points.length<=2&&(S=1,b=t.segments.length),p=S;p=50&&i.allowDrag),this.renderOrthogonalThumb(t+"_"+(d+1),e,(i.points[parseInt(d.toString(),10)].x+i.points[d+1].x)/2,(i.points[parseInt(d.toString(),10)].y+i.points[d+1].y)/2,r,h,l,o,a,u)}else for(d=0;d=50&&i.allowDrag),this.renderOrthogonalThumb(t+"_"+(d+1),e,(i.points[parseInt(d.toString(),10)].x+i.points[d+1].x)/2,(i.points[parseInt(d.toString(),10)].y+i.points[d+1].y)/2,r,h,l,o,a,u)},n.prototype.renderOrthogonalThumb=function(t,e,i,r,s,o,a,l,h,c){var d,g,u=0,f=document.getElementById(this.diagramId);f&&(g=f.ej2_instances[0]);var y=h.constraints&qe.InheritSegmentThumbShape?g.segmentThumbShape:h.segmentThumbShape,b=h.constraints&qe.InheritSegmentThumbSize?g.segmentThumbSize:h.segmentThumbSize;if(d="horizontal"===a?function Kie(n){return rre[""+n]}(y):i3(y),"Arrow"===y||"DoubleArrow"===y||"OpenArrow"===y)switch(c){case"Bottom":case"Right":u=180;break;default:u=0}else if("Fletch"===y||"OpenFetch"===y||"IndentedArrow"===y||"OutdentedArrow"===y)switch(c){case"Bottom":u=-90;break;case"Top":u=90;break;case"Right":u=180;break;default:u=0}var M={x:(i+l.tx)*l.scale-b/2,y:(r+l.ty)*l.scale-b/2,angle:u,fill:"#e2e2e2",stroke:"black",strokeWidth:1,dashArray:"",data:d,width:b,height:b,pivotX:.5,pivotY:.5,opacity:1,visible:o,id:t,class:"e-diagram-ortho-segment-handle"},w=np(M.data),C=new me(M.width,M.height),D=new Ze;if(M.data=D.updatePath(M.data,w,C),this.touchMove){var A=document.getElementById(t);A?this.updateSegmentPosition(A,M):this.svgRenderer.drawPath(s,M,this.diagramId)}else this.svgRenderer.drawPath(s,M,this.diagramId)},n.prototype.renderPivotLine=function(t,e,i,r,s){var o=t,l=!!(r&lr.Rotate);s&&(l=!1);var h=this.getBaseAttributes(o,i);h.fill="None",h.stroke="black",h.strokeWidth=1,h.dashArray="2,3",h.visible=l;var c=i.scale;h.x*=c,h.y*=c,h.width*=c,h.height*=c,h.id="pivotLine",h.class="e-diagram-pivot-line";var u={x:o.actualSize.width*o.pivot.x*c,y:0};h.startPoint={x:o.actualSize.width*o.pivot.x*c,y:-20},h.endPoint=u,this.svgRenderer.drawLine(e,h)},n.prototype.renderBezierLine=function(t,e,i,r,s,o){var l=this.getBaseAttributes(e,o);l.id=t,l.stroke="black",l.strokeWidth=1,l.dashArray="3,3",l.fill="None",l.class="e-diagram-bezier-control-line",l.x=0,l.y=0;var h=o.scale,g={x:(s.x+o.tx)*h,y:(s.y+o.ty)*h};l.startPoint={x:(r.x+o.tx)*h,y:(r.y+o.ty)*h},l.endPoint=g,this.svgRenderer.drawLine(i,l)},n.prototype.renderCircularHandle=function(t,e,i,r,s,o,a,l,h,c,d,u,f,p){var g=e,v={x:i,y:r};if(0!==g.rotateAngle||0!==g.parentTransform){var y=Bi();qi(y,g.rotateAngle+g.parentTransform,g.offsetX,g.offsetY),v=Ke(y,v)}var S=this.getBaseAttributes(g);if(S.stroke="black",S.strokeWidth=1,void 0!==u?(S.id="segmentEnd_"+u,S.fill="#e2e2e2"):S.fill=h?"#8CC63F":"white",S.cornerRadius=p/2,S.angle=e.rotateAngle,S.id=t,S.visible=o,S.class=f,S.width=p,S.height=p,S.x=(v.x+l.tx)*l.scale,S.y=(v.y+l.ty)*l.scale,S.x=S.x-S.width/2,S.y=S.y-S.height/2,h&&(S.class+=" e-connected"),c&&(S.visible=!1),this.touchMove){var b=document.getElementById(t);if(b)this.updateResizeHandle(b,S);else{var M=this.getParentSvg(e,"selector");this.svgRenderer.drawRectangle(s,S,this.diagramId,!0,!0,M,d,!0,a)}}else M=this.getParentSvg(e,"selector"),this.svgRenderer.drawRectangle(s,S,this.diagramId,!0,!0,M,d,!0,a)},n.prototype.updateResizeHandle=function(t,e){ti(t,{id:e.id,x:e.x.toString(),y:e.y.toString(),width:e.width.toString(),height:e.height.toString(),visibility:e.visible?"visible":"hidden",transform:"rotate("+e.angle+","+(e.x+e.width/2)+","+(e.y+e.height/2)+")",rx:e.cornerRadius||0,ry:e.cornerRadius||0,opacity:e.opacity})},n.prototype.renderBezierHandle=function(t,e,i,r,s,o,a,l,h,c,d,u,f){var v,p=document.getElementById(this.diagramId);p&&(v=p.ej2_instances[0]);var y=e,S={x:i,y:r};if(0!==y.rotateAngle||0!==y.parentTransform){var b=Bi();qi(b,y.rotateAngle+y.parentTransform,y.offsetX,y.offsetY),S=Ke(b,S)}var D=a.constraints&qe.InheritSegmentThumbSize?v.segmentThumbSize:a.segmentThumbSize,A=i3(a.constraints&qe.InheritSegmentThumbShape?v.segmentThumbShape:a.segmentThumbShape),x=this.getBaseAttributes(y);x.stroke="black",x.strokeWidth=1,void 0!==d?(x.id="segmentEnd_"+d,x.fill="#e2e2e2"):x.fill=h?"#8CC63F":"white",x.angle=e.rotateAngle,x.id=t,x.visible=o,x.class=u,x.width=D,x.height=D,x.data=A,x.x=(S.x+l.tx)*l.scale,x.y=(S.y+l.ty)*l.scale,x.x=x.x-x.width/2,x.y=x.y-x.height/2,h&&(x.class+=" e-connected"),c&&(x.visible=!1);var P=np(x.data),L=new me(x.width,x.height),O=new Ze;if(x.data=O.updatePath(x.data,P,L),this.touchMove){var N=document.getElementById(t);if(N)this.updateSegmentPosition(N,x);else{var T=this.getParentSvg(e,"selector");this.svgRenderer.drawPath(s,x,this.diagramId,!0,T)}}else T=this.getParentSvg(e,"selector"),this.svgRenderer.drawPath(s,x,this.diagramId,!0,T)},n.prototype.updateSegmentPosition=function(t,e){ti(t,{id:e.id,transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")translate("+e.x+","+e.y+")",visibility:e.visible?"visible":"hidden",opacity:e.opacity})},n.prototype.renderBorder=function(t,e,i,r,s,o){var l=this.getBaseAttributes(t,i);l.x*=i.scale,l.y*=i.scale,l.width*=i.scale,l.height*=i.scale,l.fill="transparent",l.stroke="#097F7F",l.strokeWidth=1.2,l.gradient=null,l.dashArray="6,3",l.class="e-diagram-selector",o&&(l.class+=" e-diagram-lane"),l.id="borderRect",l.id=this.rendererActions&Ga.DrawSelectorBorder?"borderRect_symbol":"borderRect",r||(l.class+=" e-disabled"),s&&(l.class+=" e-thick-border"),l.cornerRadius=0;var h=this.getParentSvg(t,"selector");this.svgRenderer.drawRectangle(e,l,this.diagramId,void 0,!0,h)},n.prototype.renderUserHandler=function(t,e,i,r,s,o){for(var l,a=t.wrapper,h=0,c=t.userHandles;h0||d.disableNodes&&t.nodes.length>0||"Drag"===s&&o)&&(l=!1);var u=document.getElementById(d.name+"_template_hiddenUserHandle");u&&(d.template=u.childNodes[0].cloneNode(!0));var f=Jx(t,d,i);if(f.x=(f.x+i.tx)*i.scale,f.y=(f.y+i.ty)*i.scale,d.visible&&(d.visible=!!(t.constraints&lr.UserHandle)),l)if(d.pathData){var p=d.pathData?d.pathData:d.content,g=this.getBaseAttributes(a);g.id=d.name+"_userhandle",g.fill=d.backgroundColor,g.stroke=d.borderColor,g.strokeWidth=d.borderWidth,g.centerX=f.x,g.centerY=f.y,g.radius=.5*d.size,g.class="e-diagram-userhandle-circle",g.angle=0,g.visible=d.visible,g.opacity=1,this.svgRenderer.drawCircle(e,g,1,{"aria-label":d.name+"user handle"});var y=[];y=gI(y=Ed(p));var S=np(p),w=pI(y,(d.size-.45*d.size)/S.width,(d.size-.45*d.size)/S.height,!0,S.x,S.y,0,0);S=np(w),this.svgRenderer.drawPath(e,C={x:f.x-S.width/2,y:f.y-S.height/2,angle:0,id:"",class:"e-diagram-userhandle-path",fill:d.pathColor,stroke:d.backgroundColor,strokeWidth:.5,dashArray:"",data:w,width:d.size-5,height:d.size-5,pivotX:0,pivotY:0,opacity:1,visible:d.visible},this.diagramId,void 0,void 0,{"aria-label":d.name+"user handle"})}else if(d.content){var D=new En(d.name,this.diagramId);D.content=d.content,D.offsetX=f.x,D.offsetY=f.y,D.id=d.name+"_shape",D.horizontalAlignment="Center",D.verticalAlignment="Center",D.visible=d.visible,D.setOffsetWithRespectToBounds(f.x,f.y,"Fraction"),D.relativeMode="Object",D.description=d.name||"User handle",D.measure(new me(d.size,d.size)),D.arrange(D.desiredSize),this.svgRenderer.drawNativeContent(D,e,d.size,d.size,this.adornerSvgLayer)}else if(d.source){var C,A=new SI;(C=this.getBaseAttributes(A,i)).width=d.size,C.height=d.size,C.x=f.x-d.size/2,C.y=f.y-d.size/2,C.sourceWidth=d.size,C.sourceHeight=d.size,C.alignment=A.imageAlign,C.source=d.source,C.scale=A.imageScale,C.visible=d.visible,C.description=d.name||"User handle",C.id=d.name+"_",this.renderer.drawImage(e,C,this.adornerSvgLayer,!1)}else{var x=new es(d.name,this.diagramId);x.offsetX=f.x,x.offsetY=f.y,x.id=d.name+"_shape",x.visible=d.visible,x.relativeMode="Object",x.template=d.template,x.measure(new me(d.size,d.size)),x.arrange(x.desiredSize),this.svgRenderer.drawHTMLContent(x,r,void 0,!0,void 0)}}},n.prototype.renderRotateThumb=function(t,e,i,r,s){new Ze;var a,l=new me;l.width=18,l.height=16;var d=!!(r&lr.Rotate);s&&(d=!1);var f=t.offsetX-t.actualSize.width*t.pivot.x+t.pivot.x*t.actualSize.width,p=t.offsetY-t.actualSize.height*t.pivot.y;if(a={x:(f=(f+i.tx)*i.scale)-.5*l.width,y:(p=(p+i.ty)*i.scale)-30-.5*l.height},0!==t.rotateAngle||0!==t.parentTransform){var g=Bi();qi(g,t.rotateAngle+t.parentTransform,(i.tx+t.offsetX)*i.scale,(i.ty+t.offsetY)*i.scale),a=Ke(g,a)}var v={x:a.x,y:a.y,angle:t.rotateAngle+t.parentTransform,fill:"#231f20",stroke:"black",strokeWidth:.5,dashArray:"",data:"M 16.856144362449648 10.238890446662904 L 18.000144362449646 3.437890446662903L 15.811144362449646 4.254890446662903 C 14.837144362449646 2.5608904466629028 13.329144362449647 1.2598904466629026 11.485144362449645 0.5588904466629026 C 9.375144362449646 - 0.24510955333709716 7.071144362449646 - 0.18010955333709716 5.010144362449646 0.7438904466629028 C 2.942144362449646 1.6678904466629028 1.365144362449646 3.341890446662903 0.558144362449646 5.452890446662903 C - 0.244855637550354 7.567890446662903 - 0.17985563755035394 9.866890446662904 0.7431443624496461 11.930890446662904 C 1.6681443624496461 13.994890446662904 3.343144362449646 15.575890446662903 5.457144362449647 16.380890446662903 C 6.426144362449647 16.7518904466629 7.450144362449647 16.9348904466629 8.470144362449647 16.9348904466629 C 9.815144362449647 16.9348904466629 11.155144362449647 16.6178904466629 12.367144362449647 15.986890446662901 L 11.351144362449647 14.024890446662901 C 9.767144362449647 14.8468904466629 7.906144362449647 14.953890446662902 6.237144362449647 14.3178904466629 C 4.677144362449647 13.7218904466629 3.444144362449647 12.5558904466629 2.758144362449647 11.028890446662901 C 2.078144362449646 9.501890446662903 2.031144362449646 7.802890446662903 2.622144362449646 6.243890446662903 C 3.216144362449646 4.6798904466629025 4.387144362449646 3.442890446662903 5.914144362449646 2.760890446662903 C 7.437144362449646 2.078890446662903 9.137144362449646 2.0298904466629026 10.700144362449645 2.6258904466629027 C 11.946144362449646 3.100890446662903 12.971144362449646 3.9538904466629026 13.686144362449646 5.049890446662903 L 11.540144362449645 5.850890446662903 L 16.856144362449648 10.238890446662904 Z",width:20,height:20,pivotX:0,pivotY:0,opacity:1,visible:d,id:"rotateThumb",class:"e-diagram-rotate-handle"};if(this.touchMove){var y=document.getElementById("rotateThumb");y?this.updateSegmentPosition(y,v):this.svgRenderer.drawPath(e,v,this.diagramId,!0,void 0,{"aria-label":"Thumb to rotate the selected object"})}else this.svgRenderer.drawPath(e,v,this.diagramId,!0,void 0,{"aria-label":"Thumb to rotate the selected object"})},n.prototype.renderPathElement=function(t,e,i,r,s,o,a){var l=this.getBaseAttributes(t,i,o);if(l.data=t.absolutePath,l.data=t.absolutePath,t.isPathPort&&a){l.x=a[t.id]?a[t.id].cx:l.x,l.y=a[t.id]?a[t.id].cy:l.y,t.bounds.x=l.x,t.bounds.y=l.y;var h=document.getElementById(this.diagramId);h&&"PortDrag"!==h.ej2_instances[0].eventHandler.currentAction&&(t.offsetX=l.x+t.width/2,t.offsetY=l.y+t.height/2)}var u=t.description?t.description:t.id;if(this.isSvgMode||(l.x=t.flipOffset.x?t.flipOffset.x:l.x,l.y=t.flipOffset.y?t.flipOffset.y:l.y),t.isExport){var f=t.absoluteBounds,p=Ed(l.data),g=this.findAndStoreArcValues(p);l.arc=g,l.data=LF(t,f,0,l)}this.renderer.drawPath(e,l,this.diagramId,void 0,r,u)},n.prototype.findAndStoreArcValues=function(t){var e=[];return t.forEach(function(i){"A"===i.command&&e.push({r1:i.r1/2,r2:i.r2/2})}),e},n.prototype.renderSvgGridlines=function(t,e,i,r,s,o){var a=document.createElementNS("http://www.w3.org/2000/svg","pattern"),l=document.createElementNS("http://www.w3.org/2000/svg","defs");l.setAttribute("id",this.diagramId+"_grid_pattern_defn"),(t.constraints&Kt.ShowHorizontalLines||t.constraints&Kt.ShowVerticalLines)&&a.setAttribute("id",this.diagramId+"_pattern");var h=0,c=0,d=0,u=0,f=1,p=!1,g="Lines"===t.gridType,v=g?t.verticalGridlines.lineIntervals:t.verticalGridlines.dotIntervals,y=g?t.horizontalGridlines.lineIntervals:t.horizontalGridlines.dotIntervals;if(r.showRulers&&r.dynamicGrid&&s&&o)d=o.updateSegmentWidth(i.scale),u=s.updateSegmentWidth(i.scale),t.horizontalGridlines.scaledIntervals=[d/s.interval],t.verticalGridlines.scaledIntervals=[u/o.interval],p=!0;else{for(var S=0;S=2)for(;e>=2;)e/=2;else if(e<=.5)for(;e<=.5;)e*=2;var i;if(t.horizontalGridlines.scaledIntervals=t.horizontalGridlines.snapIntervals,t.verticalGridlines.scaledIntervals=t.verticalGridlines.snapIntervals,1!==e){var r=t.horizontalGridlines;for(r.scaledIntervals=[],i=0;ithis.groupElement.actualSize.height&&("Clip"===t.style.textOverflow||"Ellipsis"===t.style.textOverflow)&&(a.y=a.y+(a.height-this.groupElement.actualSize.height)/2),this.renderer.drawRectangle(e,a,this.diagramId,void 0,void 0,r),this.renderer.drawText(e,a,r,l,this.diagramId,t.isExport&&Math.min(t.exportScaleValue.x||t.exportScaleValue.y),this.groupElement),this.isSvgMode&&(t.doWrap=!1)},n.prototype.renderNativeElement=function(t,e,i,r,s){var o,a,l=this.getParentSvg(t,void 0,e)||r,h=this.getParentElement(t,e,l).g||e,c=this.getBaseAttributes(t,i);switch(c.fill="transparent",c.cornerRadius=t.cornerRadius,c.stroke="transparent",this.renderer.drawRectangle(e,c,this.diagramId,void 0,void 0,r),t.scale){case"None":o=t.contentSize.width,a=t.contentSize.height;break;case"Stretch":o=t.actualSize.width,a=t.actualSize.height;break;case"Meet":o=a=t.actualSize.width<=t.actualSize.height?t.actualSize.width:t.actualSize.height;break;case"Slice":o=a=t.actualSize.width>=t.actualSize.height?t.actualSize.width:t.actualSize.height}this.svgRenderer&&this.svgRenderer.drawNativeContent(t,h,a,o,l)},n.prototype.renderHTMLElement=function(t,e,i,r,s,o,a){var l=this.getBaseAttributes(t,r);l.fill="transparent",l.cornerRadius=t.cornerRadius,l.stroke="transparent",this.renderer.drawRectangle(e,l,this.diagramId,void 0,void 0,s),this.svgRenderer&&this.svgRenderer.drawHTMLContent(t,i.children[0],r,function ose(n){var t=n.parentElement;do{if(cm(t,"e-diagram"))return!0;t=t.parentElement}while(t);return!1}(i),a)},n.prototype.renderImageElement=function(t,e,i,r,s){var o=this.getBaseAttributes(t,i);o.cornerRadius=0,this.renderer.drawRectangle(e,o,this.diagramId,void 0,void 0,r);var a,l,h,c,g,d=t.contentSize.width,u=t.contentSize.height,f=o.width/d,p=o.height/u;if("Stretch"===t.stretch)a=d*(g=Math.min(f,p)),l=u*g;else switch(t.stretch){case"Meet":a=d*(g=Math.min(f,p)),l=u*g,o.x+=Math.abs(o.width-a)/2,o.y+=Math.abs(o.height-l)/2;break;case"Slice":g=Math.max(f,p),h=o.width/(a=d*g)*d,c=o.height/(l=u*g)*u;break;case"None":a=d,l=u}o.width=a,o.height=l,o.sourceWidth=h,o.sourceHeight=c,o.source=t.source,o.alignment=t.imageAlign,o.scale=t.imageScale,o.description=t.description?t.description:t.id,this.renderer.drawImage(e,o,r,s)},n.prototype.renderContainer=function(t,e,i,r,s,o,a,l,h,c,d){var g,u={svg:s,g:e},f=document.getElementById(this.diagramId);if(f&&(g=f.ej2_instances[0]),this.diagramId&&(s=this.getParentSvg(t)||s,this.isSvgMode)){var v=this.getParentElement(t,e,s,l).g||e;s=this.getParentSvg(this.hasNativeParent(t.children))||s;var y=this.getParentElement(this.hasNativeParent(t.children),v,s,l);u.svg=y.svg||s,u.g=y.g||v,o&&s&&(s.getElementById(u.g.id)||e.appendChild(u.g)),e=u.g}if(this.renderRect(t,e,r,s),this.groupElement=t,t.hasChildren()){for(var b,S=void 0,M=0,w=t.children;M0&&(D=g.selectedItems.nodes[0]);var L,A=void 0,x=void 0,P=!1;if(g&&g.selectedItems&&(L=g.getObject(t.id)),"None"!==t.flip&&(D=L),"None"===t.flip&&(D=L),D&&D.flipMode&&(P=!0),!(t.elementActions&Xr.ElementIsGroup)&&g instanceof Fl&&g.nameTable[t.id]&&"connectors"!==g.nameTable[t.id].propName&&P&&D){if(A=t.children&&t.children[0]instanceof En?document.getElementById(D.id+"_content_inner_native_element"):document.getElementById(D.id+"_content_groupElement"),!(t.children[0]instanceof En)&&"Text"!==D.shape.type&&"None"!==D.flipMode&&"Label"!==D.flipMode&&"All"!==D.flipMode&&"PortAndLabel"!==D.flipMode&&"LabelText"!==D.flipMode&&"PortAndLabelText"!==D.flipMode&&"LabelAndLabelText"!==D.flipMode||t.children[0]instanceof En&&"Port"===D.flipMode)return void this.renderFlipElement(t,A,D.flip);if((t.children[0]instanceof En&&("All"===D.flipMode||"Label"===D.flipMode)||"Label"===D.flipMode||"PortAndLabel"===D.flipMode||"LabelText"===D.flipMode||"PortAndLabelText"===D.flipMode||"LabelAndLabelText"===D.flipMode||"Image"===D.shape.type&&"Label"===D.flipMode)&&this.renderFlipElement(t,A,t.flip),"None"!==t.flip&&"None"===D.flipMode)this.renderFlipElement(t,A,t.flip);else if("None"!==t.flip&&("Label"===D.flipMode||"PortAndLabel"===D.flipMode||"LabelText"===D.flipMode||"PortAndLabelText"===D.flipMode||"LabelAndLabelText"===D.flipMode)||t.children[0]instanceof En&&"None"!==t.flip&&D&&("None"===D.flipMode||"All"===D.flipMode)){for(var O=0;O0){var i=t[0];if(i instanceof En)return i;i.children&&i.children.length&&this.hasNativeParent(i.children,e++||0)}},n.prototype.renderRect=function(t,e,i,r,s){var o=this.getBaseAttributes(t,i,s);o.cornerRadius=t.cornerRadius||0,t.isExport&&(o.cornerRadius*=t.exportScaleValue.x),this.renderer.drawRectangle(e,o,this.diagramId,t.isExport,void 0,r,t.description?t.description:t.id)},n.prototype.drawRect=function(t,e){e.cornerRadius=0,this.svgRenderer.drawRectangle(t,e,this.diagramId)},n.prototype.getBaseAttributes=function(t,e,i){var r={width:t.actualSize.width,height:t.actualSize.height,x:t.offsetX-t.actualSize.width*t.pivot.x,y:t.offsetY-t.actualSize.height*t.pivot.y,fill:t.style.fill,stroke:t.style.strokeColor,angle:t.rotateAngle+t.parentTransform,pivotX:t.pivot.x,pivotY:t.pivot.y,strokeWidth:t.style.strokeWidth,dashArray:t.style.strokeDashArray||"",opacity:t.style.opacity,shadow:t.shadow,gradient:t.style.gradient,visible:t.visible,id:t.id,description:t.description,canApplyStyle:t.canApplyStyle,shapeType:t.shapeType};return"Page"===t.rotationReference&&(r.angle=t.rotateAngle),i&&(r.x=r.x-.5,r.y=r.y-.5),t.isExport&&(r.width*=t.exportScaleValue.x,r.height*=t.exportScaleValue.y,r.x*=t.exportScaleValue.x,r.y*=t.exportScaleValue.y,r.strokeWidth*=t.exportScaleValue.x),t.flip&&(r.flip=t.flip),e&&(r.x+=e.tx,r.y+=e.ty),r},n.renderSvgBackGroundImage=function(t,e,i,r,s,o){if(t.source){var l=vT(e.id).getElementById(e.id+"_image");if(!l){var h=function goe(n){return xt(n).getElementsByClassName("e-background-image-layer")[0]}(e.id);(l=document.createElementNS("http://www.w3.org/2000/svg","image")).setAttribute("id",e.id+"_image"),h.appendChild(l)}var c=new Image;c.src=t.source,l.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",c.src.toString());var d="None"!==t.scale?t.scale:"",u=t.align,f=u.charAt(0).toLowerCase()+u.slice(1);d&&(f+=" "+d.charAt(0).toLowerCase()+d.slice(1)),ti(l,{id:e.id+"_image",x:i,y:r,width:s,height:o,preserveAspectRatio:f})}},n.prototype.transformLayers=function(t,e){var i=t.tx*t.scale,r=t.ty*t.scale,s="domTable";if(i!==this.transform.x||r!==this.transform.y||0===i||0===r){e&&(window[""+s][this.diagramId+"_diagramLayer"]||(window[""+s][this.diagramId+"_diagramLayer"]=this.diagramSvgLayer.getElementById(this.diagramId+"_diagramLayer")),window[""+s][this.diagramId+"_diagramLayer"].setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+"),scale("+t.scale+")"));var a=function voe(n){var t="domTable",e=null;return window[t][n+"_gridline"]?e=window[t][n+"_gridline"]:(e=Fd(n).getElementById(n+"_gridline"),window[t][n+"_gridline"]=e),e}(this.diagramId);return a.setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+")"),window[""+s][this.diagramId+"_diagramPorts"]||(window[""+s][this.diagramId+"_diagramPorts"]=this.iconSvgLayer.getElementById(this.diagramId+"_diagramPorts")),window[""+s][this.diagramId+"_diagramPorts"].setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+"),scale("+t.scale+")"),window[""+s][this.diagramId+"_diagramExpander"]||(window[""+s][this.diagramId+"_diagramExpander"]=this.iconSvgLayer.getElementById(this.diagramId+"_diagramExpander")),window[""+s][this.diagramId+"_diagramExpander"].setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+"),scale("+t.scale+")"),window[""+s][this.diagramId+"_nativeLayer"]||(window[""+s][this.diagramId+"_nativeLayer"]=this.nativeSvgLayer.getElementById(this.diagramId+"_nativeLayer")),window[""+s][this.diagramId+"_nativeLayer"].setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+"),scale("+t.scale+")"),Io(this.diagramId).children[0].style.transform="translate("+t.tx*t.scale+"px,"+t.ty*t.scale+"px)scale("+t.scale+")",this.transform={x:t.tx*t.scale,y:t.ty*t.scale},!0}return!1},n.prototype.updateNode=function(t,e,i,r,s,o,a){this.renderElement(t,e,i,r,this.getParentSvg(t),void 0,void 0,s,null,o,a)},n}(),Kne=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),qI=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},nF=function(n){function t(e,i){var r=n.call(this,e,i)||this;return r.mode="Canvas",r.id="overview",r.actionName="",r.startPoint=null,r.currentPoint=null,r.prevPoint=null,r.scale=null,r.inAction=!1,r.viewPortRatio=1,r.horizontalOffset=0,r.verticalOffset=0,r.model={},r.event=!0,r.overviewid=88123,r.model={width:r.width,height:r.height},r}return Kne(t,n),t.prototype.onPropertyChanged=function(e,i){for(var r=0,s=Object.keys(e);r0||e.toString().indexOf("%")>0?e.toString():e.toString()+"px"},t.prototype.renderCanvas=function(e){var i=document.getElementById(this.element.id+"_canvas");i||(i=Tt("div",{}),this.element.appendChild(i)),Ho(i,{id:this.element.id+"_canvas",class:"drawing",style:"position:relative; height:"+this.getSizeValue(this.model.height)+"; width:"+this.getSizeValue(this.model.width)+";style:-ms-touch-action: none;touch-action: none;"}),this.element.setAttribute("tabindex",String(-1)),this.element.style.overflow="hidden",this.element.style.height=String(this.model.height),this.element.style.width=String(this.model.width),this.canvas=i},t.prototype.setParent=function(e){var i=document.getElementById(e);if(this.parent){var s=this.parent;this.parent=null,s.setOverview(null,this.element.id),this.removeDocument(this)}this.parent=this.getDiagram(i,"ej2_instances"),this.parent&&this.parent.setOverview(this)},t.prototype.getDiagram=function(e,i){for(var r,s=e[""+i].length,o=0;o0?f:Math.floor(window.innerWidth)}if(0===h){var p=Math.floor(window.innerHeight-u-Math.floor(c.top));h=p>0?p:Math.floor(window.innerHeight)}l>0&&(s.setAttribute("width",String(l)),this.model.height=h),h>0&&(s.setAttribute("height",String(h)),this.model.width=l),e.diagramLayerDiv||(e.diagramLayerDiv=Tt("div",{}),e.diagramLayer=bo.createCanvas(this.element.id+"_diagramLayer",this.model.width,this.model.height),e.diagramLayer.setAttribute("style","position:absolute; left:0px; top:0px "),e.diagramLayerDiv.appendChild(e.diagramLayer),e.canvas.appendChild(e.diagramLayerDiv)),Ho(e.diagramLayerDiv,{id:this.element.id+"_diagramLayer_div",style:"width:"+this.model.width+"px; height:"+this.model.height+"px;position:absolute;top:0px;left:0px"}),this.renderHtmlLayer(e.canvas),this.renderNativeLayer(e.canvas,e),this.addOverviewRectPanel(e)},t.prototype.removeDocument=function(e){var i=document.getElementById(this.canvas.id+"_svg");this.canvas.removeChild(i);var r=document.getElementById(this.element.id+"_htmlLayer");this.canvas.removeChild(r);var s=document.getElementById(this.element.id+"_diagramLayer_div");this.canvas.removeChild(s),e.diagramLayerDiv=null,e.diagramLayer=null,window.domTable[this.id+"html_layer"]=null},t.prototype.renderHtmlLayer=function(e){var i=Tt("div",{id:this.element.id+"_htmlLayer",class:"e-html-layer",style:"pointer-events:none;position:absolute;top:0px;left:0px;"}),s=Tt("div",{id:this.element.id+"_htmlLayer_div",style:"position:absolute;top:0px;left:0px;"});return i.appendChild(s),e.appendChild(i),i},t.prototype.renderNativeLayer=function(e,i){if(!document.getElementById(this.element.id+"_nativeLayer_svg")){var r=this.parent.createSvg(this.element.id+"_nativeLayer_svg",this.model.width,this.model.height),s=Fi("g",{id:this.element.id+"_nativeLayer"});r.appendChild(s),i.diagramLayerDiv.appendChild(r),ti(r,{class:"e-native-layer"})}},t.prototype.addOverviewRectPanel=function(e){var i=document.getElementById(this.canvas.id+"_overviewsvg");i&&i.parentNode.removeChild(i),i=Fi("svg",{id:this.canvas.id+"_overviewsvg",class:"overviewsvg",version:"1.1",style:"position:absolute;left:0px;top:0px; aria-label:Specifies overview",width:this.model.width,height:this.model.height}),e.canvas.appendChild(i);var s=Fi("g",{id:this.element.id+"_overviewlayer",style:"pointer-events:none"});i.appendChild(s);var o=Fi("rect",{fill:"transparent",width:"100%",height:"100%",class:"overviewbackrect",id:this.canvas.id+"overviewbackrect"});o.setAttribute("style"," pointer-events: none; "),s.appendChild(o);var a=Fi("g",{id:this.canvas.id+"overviewhandle",style:"pointer-events:all"});s.appendChild(a);var l=Fi("rect",{id:this.canvas.id+"overviewrect",fill:"transparent"});a.appendChild(l),this.renderOverviewCorner("left",a),this.renderOverviewCorner("right",a),this.renderOverviewCorner("top",a),this.renderOverviewCorner("bottom",a),this.renderOverviewCorner("topleft",a),this.renderOverviewCorner("topright",a),this.renderOverviewCorner("bottomleft",a),this.renderOverviewCorner("bottomright",a)},t.prototype.renderOverviewCorner=function(e,i){var s,o=Fi(s="top"===e||"bottom"===e||"right"===e||"left"===e?"rect":"circle",{id:this.canvas.id+"visible"+e,class:"overview-resizer"});i.appendChild(o);var a=Fi(s,{id:this.canvas.id+e,class:"overviewresizer",fill:"transparent"});i.appendChild(a)},t.prototype.updateOverviewRectangle=function(){var e=this.currentPoint.x-this.prevPoint.x,i=this.currentPoint.y-this.prevPoint.y,r=new me;r.width=0,r.height=0;var s=0,o=0;switch(this.resizeDirection){case"left":r.width-=e,r.height-=e/this.viewPortRatio,s=e,o=e/this.viewPortRatio,o/=2;break;case"right":r.width+=e,r.height+=e/this.viewPortRatio,o=e/this.viewPortRatio,o/=-2;break;case"top":r.height-=i,r.width-=i*this.viewPortRatio,o=i,s=i*this.viewPortRatio,s/=2;break;case"bottom":r.height+=i,r.width+=i*this.viewPortRatio,s=i*this.viewPortRatio,s/=-2;break;case"topleft":Math.abs(i)>Math.abs(e)?e=i*this.viewPortRatio:i=e/this.viewPortRatio,r.width-=e,r.height-=i,s=e,o=i;break;case"topright":Math.abs(i)>Math.abs(e)?e=-i*this.viewPortRatio:i=-e/this.viewPortRatio,o=i,r.width+=e,r.height-=i;break;case"bottomleft":Math.abs(i)>Math.abs(e)?e=-i*this.viewPortRatio:i=-e/this.viewPortRatio,s=e,r.width-=e,r.height+=i;break;case"bottomright":Math.abs(i)>Math.abs(e)?e=i*this.viewPortRatio:i=e/this.viewPortRatio,r.width+=e,r.height+=i}this.updateHelper(s,o,r,void 0,void 0)},t.prototype.updateHelper=function(e,i,r,s,o){var a,l,h,u,f,d=this.element.getElementsByTagName("svg")[2].getElementById("helper");r?(a=(h=d.getBBox()).x+e,l=h.y+i,s=h.width+r.width,o=h.height+r.height):(u=this.currentPoint.x>this.startPoint.x?this.currentPoint.x-this.prevPoint.x:this.prevPoint.x-this.currentPoint.x,f=this.currentPoint.y>this.startPoint.y?this.currentPoint.y-this.prevPoint.y:this.prevPoint.y-this.currentPoint.y,Math.abs(f)>Math.abs(u)?u=this.viewPortRatio*f:f=u/this.viewPortRatio,h=d.getBBox(),a=this.startPoint.x>this.currentPoint.x?h.x-u:h.x,l=this.startPoint.y>this.currentPoint.y?h.y-f:h.y,s=h.width+u,o=h.height+f),ti(this.helper,{id:this.helper.id,x:a,y:l,width:Math.max(0,s),height:Math.max(0,o)})},t.prototype.updateOverviewrect=function(e,i,r,s){Ho(document.getElementById(this.canvas.id+"overviewrect"),{x:e,y:i,width:Math.max(1,r),height:Math.max(1,s)}),this.updateOverviewCorner("top",e+8,i+1,Math.max(0,r-16),2),this.updateOverviewCorner("bottom",e+8,i+s+3,Math.max(0,r-16),2),this.updateOverviewCorner("left",e-2,i+11,2,Math.max(0,s-16)),this.updateOverviewCorner("right",e+r,i+11,2,Math.max(0,s-16)),this.updateOverviewCorner("topleft",e,i+3,5,5),this.updateOverviewCorner("topright",e+r,i+3,5,5),this.updateOverviewCorner("bottomleft",e,i+s+3,5,5),this.updateOverviewCorner("bottomright",e+r,i+s+3,5,5)},t.prototype.updateOverviewCorner=function(e,i,r,s,o){var a,l;"top"===e||"bottom"===e||"right"===e||"left"===e?(a={x:i,y:r,width:s,height:o,fill:"#ED1C24"},l={x:i-2,y:r-2,width:2===s?4:s,height:2===o?4:o}):(a={cx:i,cy:r,r:4,fill:"#ED1C24"},l={cx:i,cy:r,r:6,fill:"transparent"}),Ho(document.getElementById(this.canvas.id+"visible"+e),a),Ho(document.getElementById(this.canvas.id+e),l)},t.prototype.translateOverviewRectangle=function(){Number(this.model.width),Number(this.model.height);var r=this.currentPoint.x-this.prevPoint.x,s=this.currentPoint.y-this.prevPoint.y,l=this.element.getElementsByClassName("overviewsvg")[0].getElementById(this.canvas.id+"overviewrect").getBBox(),h=l.x+r,c=l.y+s,d=l.width,u=l.height;this.updateOverviewrect(h,c,d,u),this.updateParentView(this.parent.scroller.currentZoom,h,c,d,u,null)},t.prototype.renderOverviewRect=function(e,i,r,s){var o=Number(this.model.width),a=Number(this.model.height),c=Math.max(this.parent.scroller.viewPortWidth/(r/o*this.contentWidth),this.parent.scroller.viewPortHeight/(s/a*this.contentHeight));if(c>=.25&&c<=30){this.updateParentView(c,e,i,r,s,{x:0,y:0});var u=this.scrollOverviewRect(this.parent.scroller.horizontalOffset,this.parent.scroller.verticalOffset,this.parent.scroller.currentZoom,!0);if(this.helper){var p=this.element.getElementsByTagName("rect")[10].getBBox();u.x=p.x,u.y=p.y}"pan"===this.actionName?this.updateOverviewrect(-u.x,-u.y,u.width,u.height):this.updateOverviewrect(u.x,u.y,u.width,u.height)}},t.prototype.scrollOverviewRect=function(e,i,r,s){if(!this.actionName||s){var o=Number(this.model.width),a=Number(this.model.height),l=Math.min(this.contentWidth/o,this.contentHeight/a),h=new Ne,c=h.x=e/r/l,d=h.y=i/r/l,u=0;this.parent.rulerSettings.showRulers&&(u=25);var f=document.getElementById(this.parent.element.id+"content"),p=0,g=0;f&&(p=f.offsetWidth-f.clientWidth,g=f.offsetHeight-f.clientHeight);var v=h.width=(this.parent.scroller.viewPortWidth-u-p)/r/l,y=h.height=(this.parent.scroller.viewPortHeight-u-g)/r/l;if(s){var S=new Ne;return S.x=c,S.y=d,S.width=v,S.height=y,S}this.updateOverviewrect(-c,-d,v,y)}return null},t.prototype.updateParentView=function(e,i,r,s,o,a){var p,g,l=Number(this.model.width),h=Number(this.model.height),u=i*(this.contentWidth/l)*e,f=r*(this.contentHeight/h)*e;this.parent.scroller.getPageBounds(),(1!==e||"pan"===this.actionName)&&(p=-u-this.parent.scroller.horizontalOffset,g=-f-this.parent.scroller.verticalOffset),this.parent.setBlazorDiagramProps(!0),this.parent.realActions|=$i.OverViewAction,"scale"===this.actionName||"draw"===this.actionName?this.parent.scroller.zoom(e/this.parent.scroller.currentZoom,p,g,a):ce()?this.parent.scroller.zoom(1,p,g,a):this.parent.pan(p,g,a,!0)},t.prototype.updateHtmlLayer=function(e){var i=Io(e.element.id),r=this.parent.scroller.getPageBounds(!0),o=r.height,a=Math.max(r.width,this.parent.scroller.viewPortWidth),l=Math.max(o,this.parent.scroller.viewPortHeight/this.parent.scroller.currentZoom),h=Math.min(Number(this.model.width)/a,Number(this.model.height)/l);i.style.transform="scale("+h+") translate("+this.parent.scroller.transform.tx+"px,"+this.parent.scroller.transform.ty+"px)"},t.prototype.updateView=function(e){var i=this.parent.scroller.getPageBounds(),r=i.width,s=i.height,o=Number(this.model.width),a=Number(this.model.height),l=Math.max(r,this.parent.scroller.viewPortWidth),h=Math.max(s,this.parent.scroller.viewPortHeight);this.contentWidth=l=Math.max(l,o/a*h),this.contentHeight=h=Math.max(h,a/o*l);var c=Math.min(o/l,a/h),d=document.getElementById(this.element.id+"_htmlLayer");d.style.webkitTransform="scale("+c+") translate("+-i.x+"px,"+-i.y+"px)",d.style.transform="scale("+c+") translate("+-i.x+"px,"+-i.y+"px)",document.getElementById(this.element.id+"_overviewlayer").setAttribute("transform","translate("+-i.x*c+","+-i.y*c+")"),this.horizontalOffset=i.x*c,this.verticalOffset=i.y*c;var f=document.getElementById(this.element.id+"_diagramLayer"),p=kF(this.element.id),g=f.getContext("2d"),v=Number(this.model.width)/this.contentWidth,y=Number(this.model.height)/this.contentHeight;v=Math.min(v,y);var S=this.parent.scroller.transform;p.setAttribute("transform","translate("+S.tx*v+","+S.ty*y+"),scale("+v+")"),g.setTransform(v,0,0,v,0,0),g.fillStyle="red",this.scrollOverviewRect(this.parent.scroller.horizontalOffset,this.parent.scroller.verticalOffset,this.parent.scroller.currentZoom)},t.prototype.scrolled=function(e){if(this.event){var i=this.scrollOverviewRect(this.parent.scroller.horizontalOffset,this.parent.scroller.verticalOffset,this.parent.scroller.currentZoom,!0);this.updateOverviewrect(-i.x,-i.y,i.width,i.height),this.updateView(this)}},t.prototype.updateCursor=function(e){if(cm(e.target,"overviewresizer"))switch(e.target.id){case this.canvas.id+"left":this.canvas.style.cursor="w-resize";break;case this.canvas.id+"right":this.canvas.style.cursor="e-resize";break;case this.canvas.id+"top":this.canvas.style.cursor="n-resize";break;case this.canvas.id+"bottom":this.canvas.style.cursor="s-resize";break;case this.canvas.id+"topleft":this.canvas.style.cursor="nw-resize";break;case this.canvas.id+"topright":this.canvas.style.cursor="ne-resize";break;case this.canvas.id+"bottomleft":this.canvas.style.cursor="sw-resize";break;case this.canvas.id+"bottomright":this.canvas.style.cursor="se-resize"}else this.canvas.style.cursor="default"},t.prototype.mouseMove=function(e){if(this.event=!1,this.updateCursor(e),this.currentPoint=this.mousePosition(e),this.actionName)switch(this.actionName){case"draw":!this.inAction&&(this.startPoint.x!==this.currentPoint.x||this.startPoint.y!==this.currentPoint.y)&&(this.initHelper(),this.inAction=!0),this.inAction&&this.updateHelper();break;case"scale":this.inAction||(this.initHelper(),this.inAction=!0),this.updateOverviewRectangle();break;case"pan":(this.startPoint.x!==this.currentPoint.x||this.startPoint.y===this.currentPoint.y||this.inAction)&&(this.inAction=!0,this.translateOverviewRectangle())}this.prevPoint=this.currentPoint},t.prototype.documentMouseUp=function(e){this.inAction=!1,this.actionName="",this.helper&&(this.helper.parentNode.removeChild(this.helper),this.helper=null),this.event=!0,document.getElementById(this.canvas.id+"overviewhandle").style.pointerEvents="all"},t.prototype.windowResize=function(e){var i=this;return this.resizeTo&&clearTimeout(this.resizeTo),this.resizeTo=setTimeout(function(){var s=document.getElementById(i.element.id).getBoundingClientRect();i.model.width=s.width>0?s.width:i.model.width,i.model.height=s.height>0?s.height:i.model.height,i.renderCanvas(),i.setParent(i.sourceID)},10),!1},t.prototype.mouseDown=function(e){if(e.target.id===this.canvas.id+"_overviewsvg"&&(this.actionName="draw"),e.target.id===this.canvas.id+"overviewrect"&&(this.actionName="pan"),cm(e.target,"overviewresizer"))switch(this.actionName="scale",e.target.id){case this.canvas.id+"left":this.resizeDirection="left";break;case this.canvas.id+"right":this.resizeDirection="right";break;case this.canvas.id+"top":this.resizeDirection="top";break;case this.canvas.id+"bottom":this.resizeDirection="bottom";break;case this.canvas.id+"topleft":this.resizeDirection="topleft";break;case this.canvas.id+"topright":this.resizeDirection="topright";break;case this.canvas.id+"bottomleft":this.resizeDirection="bottomleft";break;case this.canvas.id+"bottomright":this.resizeDirection="bottomright"}this.startPoint=this.prevPoint=this.mousePosition(e),this.viewPortRatio=this.parent.scroller.viewPortWidth/this.parent.scroller.viewPortHeight,document.getElementById(this.canvas.id+"overviewhandle").style.pointerEvents="none"},t.prototype.mouseUp=function(e){if(this.currentPoint=this.mousePosition(e),this.actionName)if(this.startPoint.x!==this.currentPoint.x||this.startPoint.y!==this.currentPoint.y){if("pan"!==this.actionName&&this.helper){var i=this.element.getElementsByTagName("rect")[10].getBBox();this.resizeDirection=this.resizeDirection||"",this.renderOverviewRect(i.x,i.y,o=i.width,a=i.height)}}else if(e.target.id===this.canvas.id+"_overviewsvg"||"helper"===e.target.id){var o=(i=this.element.getElementsByTagName("svg")[2].getElementById(this.canvas.id+"overviewrect").getBBox()).width,a=i.height;this.inAction=!0,this.actionName="pan",this.renderOverviewRect(this.currentPoint.x-o/2,this.currentPoint.y-a/2,o,a),this.inAction=!1}this.helper&&(this.helper.parentNode.removeChild(this.helper),this.helper=null),this.actionName="",this.startPoint=null,this.currentPoint=null,this.prevPoint=null,this.helper=null,this.viewPortRatio=1,this.resizeDirection="",this.inAction=!1,this.event=!0,document.getElementById(this.canvas.id+"overviewhandle").style.pointerEvents="all"},t.prototype.initHelper=function(){var e=this.element.getElementsByTagName("svg")[2],i=this.startPoint.x,r=this.startPoint.y,s=1,o=1;if("scale"===this.actionName){var l=e.getElementById(this.canvas.id+"overviewrect").getBBox();i=l.x,r=l.y,s=l.width,o=l.height}var h=Fi("rect",{id:"helper",x:i,y:r,width:s,height:o,fill:"transparent",stroke:"gray","stroke-dasharray":"2 2","shape-rendering":"crispEdges"});e.getElementById(this.element.id+"_overviewlayer").appendChild(h),this.helper=h},t.prototype.mousePosition=function(e){var i,r,s;-1!==e.type.indexOf("touch")?(r=(i=e).changedTouches[0].clientX-this.element.offsetLeft,s=i.changedTouches[0].clientY-this.element.offsetTop):(r=e.clientX,s=e.clientY);var l=this.element.getBoundingClientRect();return{x:(r-=l.left)+this.horizontalOffset,y:(s-=l.top)+this.verticalOffset}},t.prototype.destroy=function(){if(this.unWireEvents(),this.notify("destroy",{}),n.prototype.destroy.call(this),document.getElementById(this.element.id)){this.element.classList.remove("e-overview");var e=document.getElementById(this.element.id+"_canvas");e&&this.element.removeChild(e)}this.parent.views.splice(this.parent.views.indexOf(this.element.id),1),this.diagramLayerDiv=null,this.canvas=null,this.parent=null},t.prototype.getModuleName=function(){return"Overview"},qI([I("100%")],t.prototype,"width",void 0),qI([I("100%")],t.prototype,"height",void 0),qI([I("")],t.prototype,"sourceID",void 0),qI([H()],t.prototype,"created",void 0),t}(Ii);function tse(n,t){for(var e=0;eR.findLength(e,n)?e:t;var o=R.findAngle(t,e),a=R.findAngle(i,n),l=R.findLength(i,n),h=a+2*(o-a);return{x:i.x+l*Math.cos(h*Math.PI/180),y:i.y+l*Math.sin(h*Math.PI/180)}}function Zf(n,t,e){if(n&&n.children&&n.children.length>0)for(var r=void 0,s=0;s0&&"annotations"!==r&&"ports"!==r)if(n[""+l].length>0)for(var h=0;h<=n[""+l].length;h++)Ro(n[""+l],t?t[""+l]:void 0,e[""+l],"annotations"===l||"ports"===l?n:void 0,l);else Ro(n[""+l],t?t[""+l]:void 0,e[""+l],"annotations"===l||"ports"===l?n:void 0,l);else if(s instanceof Object&&t&&"annotations"!==r&&"ports"!==r)Ro(n[""+l],t[""+l],e[""+l]);else if("annotations"!==r&&"ports"!==r&&t&&!t[""+l]||!t&&n&&(n[""+l]||void 0!==n[""+l]))n[""+l]=e[""+l];else{var c=void 0;("annotations"===r||"ports"===r)&&("annotations"===r?(n[""+l]&&Ro(n[""+l],t[""+l],e[""+l]),n[""+l]||(ps(i)===de?(c=new Or(i,"annotations",e[""+l]),i.annotations.push(c)):(c=new Kn(i,"annotations",e[""+l]),i.annotations.push(c)))):n[""+l]?Ro(n[""+l],t[""+l],e[""+l]):(c=new Es(i,"ports",e[""+l]),i.ports.push(c)))}}}function lse(n,t){for(var e="Bezier"===n.type?function sse(n){var t=[];if("Bezier"===n.type)for(var e=0,i=0;i0||n.ports.length>0){var f=n.wrapper.children;for(i=3;i0)return{enabled:!1,intersectPt:e};var l=o/s,h=a/s;return l>=0&&l<=1&&h>=0&&h<=1?(e.x=i.x1+l*(i.x2-i.x1),e.y=i.y1+l*(i.y2-i.y1),{enabled:!0,intersectPt:e}):{enabled:!1,intersectPt:e}}function ZI(n,t,e,i){var a=Kv(lF(n.x,n.y,t.x,t.y),lF(e.x,e.y,i.x,i.y));return a.enabled?a.intersectPt:{x:0,y:0}}function lF(n,t,e,i){return{x1:Number(n)||0,y1:Number(t)||0,x2:Number(e)||0,y2:Number(i)||0}}function hF(n,t,e){var i=[],s={x:t.topRight.x+(e=e||0),y:t.topRight.y},o={x:t.bottomRight.x,y:t.bottomRight.y-e},a={x:t.bottomLeft.x,y:t.bottomLeft.y+e};return i.push({x:t.topLeft.x-e,y:t.topLeft.y}),i.push(s),i.push(o),i.push(a),i}function zc(n,t,e,i,r,s){var o={},a=e.scroller.transform.scale,h=e.scroller.verticalOffset;return o.x=(i?n.x:t.x)*a+e.scroller.horizontalOffset-r,o.y=(i?n.y:t.y)*a+h-s,o}function cF(n,t){var e=new Ze;return e.data=n.pathData,e.height=n.height>10?n.height-(n.padding.bottom+n.padding.top):n.height,e.width=n.width>10?n.width-(n.padding.left+n.padding.right):n.width,e.visible=n.visibility,e.id=t.id+"_shape",e.inversedAlignment=!1,e.horizontalAlignment="Center",e.verticalAlignment="Center",e.style={fill:n.iconStrokeColor,strokeColor:n.iconStrokeColor,strokeWidth:n.iconStrokeWidth},e.setOffsetWithRespectToBounds(.5,.5,"Fraction"),e.relativeMode="Object",e.description=t.description||"",e}function Gx(n,t,e){var i=Xx(n,t),r=R.findAngle(n[i.index],n[i.index+1]),s=function gse(n){var t;t=n instanceof EI?0:void 0===n.content?10:0;var e=0;switch(n.alignment){case"Center":e=0;break;case"Before":e=-(0+t);break;case"After":e=0+t}return e}(t),o=R.transform(i.point,r+45,s);return i.point=o,i.angle=r,i}function Xx(n,t){for(var r,s,a,l,e=0,i=t.offset,o=[],h=0;h=c)return s=R.findAngle(n[parseInt(d.toString(),10)],n[d+1]),{point:r=R.transform(n[parseInt(d.toString(),10)],s,c-(a||0)),index:l=d};a=o[parseInt(d.toString(),10)]}return{point:r,index:l}}function dF(n,t,e){t%=360;var a,l,s=225;switch(n.alignment){case"Before":t>=45&&t<=135?(l="right",a=.5===n.offset?"center":"top"):t>=s&&t<=315?(l="left",a=.5===n.offset?"center":"bottom"):t>45&&t=45&&t<=135?(l="left",a=.5===n.offset?"center":"top"):t>=s&&t<=315?(l="right",a=.5===n.offset?"center":"bottom"):t>45&&tMath.abs(t.y-n.y)?n.x0)for(var e=0;e=0;r--)("nodes"===i||"connectors"===i)&&(n[""+i][parseInt(r.toString(),10)].wrapper=null),"dataManager"!==i&&(n[""+i][parseInt(r.toString(),10)]=Zx(n[""+i][parseInt(r.toString(),10)],e[""+i][parseInt(r.toString(),10)],void 0!==t[""+i]?t[""+i][parseInt(r.toString(),10)]:[]),("[]"===JSON.stringify(n[""+i][parseInt(r.toString(),10)])||"{}"===JSON.stringify(n[""+i][parseInt(r.toString(),10)])||void 0===n[""+i][parseInt(r.toString(),10)])&&n[""+i].splice(r,1));n=void 0}function zh(n,t){var e=t.style,i=t;t.canApplyStyle=!0;for(var r=0,s=Object.keys(n);r=0&&n.splice(e,1)}function Jf(n,t,e){var i;n.intermediatePoints=t,n.updateSegmentElement(n,t,n.wrapper.children[0],e);var r=n.sourceDecorator;if("Bezier"===n.type){var s=n.segments[0],o=n.segments[n.segments.length-1];i=[R.isEmptyPoint(o.point2)?o.bezierPoint2:o.point2,R.isEmptyPoint(s.point1)?s.bezierPoint1:s.point1]}else i=n.intermediatePoints;t=n.clipDecorators(n,t,e);var a=n.wrapper.children[0];a.canMeasurePath=!0,n.updateDecoratorElement(a=n.wrapper.children[1],t[0],i[1],r),n.updateDecoratorElement(a=n.wrapper.children[2],t[t.length-1],i[i.length-2],n.targetDecorator),n.updateShapeElement(n)}function Jx(n,t,e){var l,i=n.wrapper,s=t.offset,o=t.size/e.scale,a=t.margin,h=i.offsetX-i.actualSize.width*i.pivot.x,c=i.offsetY-i.actualSize.height*i.pivot.y;if(l={x:0,y:0},n.nodes.length>0){switch(t.side){case"Top":l.x+=h+s*i.actualSize.width,l.y+=c-o;break;case"Bottom":l.x+=h+s*i.actualSize.width,l.y+=c+i.actualSize.height+o;break;case"Left":l.x+=h-o,l.y+=c+s*i.actualSize.height;break;case"Right":l.x+=h+i.actualSize.width+o,l.y+=c+s*i.actualSize.height}l.x+=(a.left-a.right)/e.scale+o/2*("Center"===t.horizontalAlignment?0:"Right"===t.horizontalAlignment?-1:1),l.y+=(a.top-a.bottom)/e.scale+o/2*("Center"===t.verticalAlignment?0:"Top"===t.verticalAlignment?-1:1)}else if(n.connectors.length>0){var d=n.connectors[0],u={offset:s},f=Xx(d.intermediatePoints,u),p=f.index;l=f.point;var y,v=Gx(d.intermediatePoints,u).angle;qi(y=Bi(),-v,d.intermediatePoints[parseInt(p.toString(),10)].x,d.intermediatePoints[parseInt(p.toString(),10)].y),(l=Ke(y,l)).x+=a.left-a.right+o/2*("Center"===t.horizontalAlignment?0:"Right"===t.horizontalAlignment?-1:1),l.y+=a.top-a.bottom+o/2*("Center"===t.verticalAlignment?0:"Top"===t.verticalAlignment?-1:1),qi(y=Bi(),v,d.intermediatePoints[parseInt(p.toString(),10)].x,d.intermediatePoints[parseInt(p.toString(),10)].y),l=Ke(y,l)}return 0===i.rotateAngle&&0===i.parentTransform||(qi(y=Bi(),i.rotateAngle+i.parentTransform,i.offsetX,i.offsetY),l=Ke(y,l)),l}function ga(n,t,e,i){if(i.annotation){if(Pl(i.annotation))return!0}else if(lr[""+t]&n&&bt[""+t]&e)return!0;return!1}function qr(n,t){return!!(lr[""+t]&n)}function Hc(n,t){return!!(Ix[""+t]&n)}function va(n,t){return n.visibility&t}function JI(n,t){var e;if("Text"===n.shape.type)e=n.shape;else{var i=t.split("_");t=i[i.length-1];for(var r=0;rn[""+t]?e.splice(0,0,n):e.push(n);else if(e.length>1){for(var i=0,r=e.length-1,s=Math.floor((i+r)/2);s!==i;)if(e[parseInt(s.toString(),10)][""+t]n[""+t]))break;r=s,s=Math.floor((i+r)/2)}e[parseInt(r.toString(),10)][""+t]n[""+t]?e.splice(i,0,n):e[parseInt(i.toString(),10)][""+t]n[""+t]&&e.splice(r,0,n)}}function kse(n){var t=document.getElementById(n.diagramId),e="ej2_instances",i=t[""+e][0].nodes;void 0===i&&(i=function Pse(n){for(var t=[],e=0;e30?10:o/2;for(var h=0,c=0;c=l){var u=l-h;r=Gt(n[c],n[c+1]),s=R.transform(n[c],r,u);break}h+=d}return s},tb=function(n,t){if(n instanceof te||n instanceof de)for(var e=0;e=0||navigator.platform.indexOf("iPad")>=0||navigator.platform.indexOf("iPhone")>=0||navigator.platform.indexOf("MacIntel")>=0)&&("safari"===X.info.name||"webkit"===X.info.name)}function bF(n,t,e,i){return void 0!==t.previewSize[""+i]?t.previewSize[""+i]:void 0!==n.symbolPreview[""+i]?n.symbolPreview[""+i]:t[""+i]||e.actualSize[""+i]}function nm(n,t,e){return n&&n.parentId&&(e=(n=t.nameTable[n.parentId]).parentId?nm(n,t,e):n.id),e}function sm(n,t){return n.selectedItems.connectors.length>1&&0===n.selectedItems.nodes.length&&0!==t.rotateAngle}function Bse(n){if(n.arrowType&&""!==n.arrowType.trim())switch(n.arrowType){case"single-line-arrow":default:return{targetDecorator:"Arrow",strokeWidth:1};case"double-line-arrow":return{targetDecorator:"Arrow",strokeWidth:2};case"dotted-arrow":return{targetDecorator:"Arrow",strokeDashArray:"2,2"};case"single-line":return{targetDecorator:"None",strokeWidth:1};case"double-line":return{targetDecorator:"None",strokeWidth:2};case"dotted":return{targetDecorator:"None",strokeDashArray:"2,2"};case"wiggly-arrow":return{targetDecorator:"None",strokeWidth:1,opacity:0}}return{targetDecorator:"Arrow",strokeWidth:1}}var Fse=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),no=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},MF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Fse(t,n),no([I("None")],t.prototype,"shape",void 0),no([I("white")],t.prototype,"fill",void 0),no([I("Auto")],t.prototype,"horizontalAlignment",void 0),no([I("Auto")],t.prototype,"verticalAlignment",void 0),no([I(10)],t.prototype,"width",void 0),no([I(10)],t.prototype,"height",void 0),no([re({x:.5,y:1},R)],t.prototype,"offset",void 0),no([I("#1a1a1a")],t.prototype,"borderColor",void 0),no([I(1)],t.prototype,"borderWidth",void 0),no([re({},Jn)],t.prototype,"margin",void 0),no([I("")],t.prototype,"pathData",void 0),no([I("")],t.prototype,"content",void 0),no([I(0)],t.prototype,"cornerRadius",void 0),no([re({left:2,right:2,top:2,bottom:2},Jn)],t.prototype,"padding",void 0),no([I("#1a1a1a")],t.prototype,"iconColor",void 0),t}(Ee),_se=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),iT=function(n){function t(){var e=null!==n&&n.apply(this,arguments)||this;return e.orientation="Vertical",e.measureChildren=void 0,e.considerPadding=!0,e}return _se(t,n),t.prototype.measure=function(e){return this.desiredSize=this.measureStackPanel(e,"Horizontal"===this.orientation?this.updateHorizontalStack:this.updateVerticalStack),this.desiredSize},t.prototype.arrange=function(e){return this.actualSize=this.arrangeStackPanel(e,"Horizontal"===this.orientation?this.arrangeHorizontalStack:this.arrangeVerticalStack),this.updateBounds(),this.actualSize},t.prototype.measureStackPanel=function(e,i){var r=void 0;if(void 0!==this.children&&this.children.length>0)for(var s=0,o=this.children;s0){var r=void 0,s=void 0;r=this.offsetX-e.width*this.pivot.x+this.padding.left,s=this.offsetY-e.height*this.pivot.y+this.padding.top;for(var o=0,a=this.children;o0)for(var i=0,r=this.children;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Xse=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Gse(t,n),Rh([I("Horizontal")],t.prototype,"orientation",void 0),Rh([I("Center")],t.prototype,"type",void 0),Rh([I(void 0)],t.prototype,"offset",void 0),Rh([I(!1)],t.prototype,"enableRouting",void 0),Rh([I([])],t.prototype,"children",void 0),Rh([I("")],t.prototype,"assistants",void 0),Rh([I("")],t.prototype,"level",void 0),Rh([I("")],t.prototype,"hasSubTree",void 0),Rh([I("")],t.prototype,"rows",void 0),t}(Ee),Ni=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),q=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},qse=function(n){if(n)switch(n.type){case"Basic":default:return ib;case"Flow":return DF;case"Path":return wF;case"Image":return EF;case"Text":return zd;case"Bpmn":return lT;case"Native":return om;case"HTML":return CF;case"UmlActivity":return xF;case"UmlClassifier":return TF;case"SwimLane":return Bd}return ib},ma=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),q([I("Basic")],t.prototype,"type",void 0),t}(Ee),wF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"Path"},q([I("Path")],t.prototype,"type",void 0),q([I("")],t.prototype,"data",void 0),t}(ma),om=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"Native"},q([I("Native")],t.prototype,"type",void 0),q([I("")],t.prototype,"content",void 0),q([I("Stretch")],t.prototype,"scale",void 0),t}(ma),CF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"Html"},q([I("HTML")],t.prototype,"type",void 0),q([I("")],t.prototype,"content",void 0),t}(ma),EF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"Image"},q([I("Image")],t.prototype,"type",void 0),q([I("")],t.prototype,"source",void 0),q([I("None")],t.prototype,"scale",void 0),q([I("None")],t.prototype,"align",void 0),t}(ma),zd=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"Text"},q([I("Text")],t.prototype,"type",void 0),q([I("")],t.prototype,"content",void 0),q([re({},Jn)],t.prototype,"margin",void 0),t}(ma),ib=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"BasicShape"},q([I("Basic")],t.prototype,"type",void 0),q([I("Rectangle")],t.prototype,"shape",void 0),q([I(0)],t.prototype,"cornerRadius",void 0),q([Ft([],R)],t.prototype,"points",void 0),t}(ma),DF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"FlowShape"},q([I("Flow")],t.prototype,"type",void 0),q([I("Terminator")],t.prototype,"shape",void 0),t}(ma),nT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"BpmnGateway"},q([I("None")],t.prototype,"type",void 0),t}(Ee),sT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"BpmnDataObject"},q([I("None")],t.prototype,"type",void 0),q([I(!1)],t.prototype,"collection",void 0),t}(Ee),$se=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),q([I("None")],t.prototype,"type",void 0),q([I("None")],t.prototype,"loop",void 0),q([I(!1)],t.prototype,"call",void 0),q([I(!1)],t.prototype,"compensation",void 0),t}(Ee),oT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"BpmnEvent"},q([I("Start")],t.prototype,"event",void 0),q([I("None")],t.prototype,"trigger",void 0),t}(Ee),Rd=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"BpmnSubEvent"},q([I("None")],t.prototype,"trigger",void 0),q([I("Start")],t.prototype,"event",void 0),q([I("")],t.prototype,"id",void 0),q([re({},R)],t.prototype,"offset",void 0),q([Ft([],Kn)],t.prototype,"annotations",void 0),q([Ft([],Es)],t.prototype,"ports",void 0),q([I()],t.prototype,"width",void 0),q([I()],t.prototype,"height",void 0),q([re({},Jn)],t.prototype,"margin",void 0),q([I("Center")],t.prototype,"horizontalAlignment",void 0),q([I("Center")],t.prototype,"verticalAlignment",void 0),q([I(!0)],t.prototype,"visible",void 0),t}(Ee),Zse=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),q([re({id:"success",event:"End",offset:{x:1,y:.5}},Rd)],t.prototype,"success",void 0),q([re({id:"failure",event:"Intermediate",trigger:"Error",offset:{x:.25,y:1}},Rd)],t.prototype,"failure",void 0),q([re({id:"cancel",event:"Intermediate",trigger:"Cancel",offset:{x:.75,y:1}},Rd)],t.prototype,"cancel",void 0),t}(Ee),Jse=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),q([I("None")],t.prototype,"type",void 0),q([I(!1)],t.prototype,"adhoc",void 0),q([I("Default")],t.prototype,"boundary",void 0),q([I(!1)],t.prototype,"compensation",void 0),q([I("None")],t.prototype,"loop",void 0),q([I(!0)],t.prototype,"collapsed",void 0),q([Ft([],Rd)],t.prototype,"events",void 0),q([re({},Zse)],t.prototype,"transaction",void 0),q([I(void 0)],t.prototype,"processes",void 0),t}(Ee),aT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"BpmnActivity"},q([I("Task")],t.prototype,"activity",void 0),q([re({},$se)],t.prototype,"task",void 0),q([re({},Jse)],t.prototype,"subProcess",void 0),t}(Ee),am=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return Ni(t,n),t.prototype.getClassName=function(){return"BpmnAnnotation"},q([I("")],t.prototype,"text",void 0),q([I("")],t.prototype,"id",void 0),q([I(0)],t.prototype,"angle",void 0),q([I()],t.prototype,"height",void 0),q([I()],t.prototype,"width",void 0),q([I(0)],t.prototype,"length",void 0),t}(Ee),Kse=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),q([I("")],t.prototype,"textAnnotationTarget",void 0),q([I("Auto")],t.prototype,"textAnnotationDirection",void 0),t}(Ee),lT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"BpmnShape"},q([I("Bpmn")],t.prototype,"type",void 0),q([I("Event")],t.prototype,"shape",void 0),q([re({},oT)],t.prototype,"event",void 0),q([re({},nT)],t.prototype,"gateway",void 0),q([re({},sT)],t.prototype,"dataObject",void 0),q([re({},aT)],t.prototype,"activity",void 0),q([re({},am)],t.prototype,"annotation",void 0),q([Ft([],am)],t.prototype,"annotations",void 0),q([re({},Kse)],t.prototype,"textAnnotation",void 0),t}(ma),xF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"UmlActivityShape"},q([I("UmlActivity")],t.prototype,"type",void 0),q([I("Action")],t.prototype,"shape",void 0),t}(ma),hT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"MethodArguments"},q([I("")],t.prototype,"name",void 0),q([I("")],t.prototype,"type",void 0),q([re({},Qf)],t.prototype,"style",void 0),t}(Ee),rp=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"UmlClassAttribute"},q([I("Public")],t.prototype,"scope",void 0),q([I(!1)],t.prototype,"isSeparator",void 0),q([re({fill:"#F9F9F9",strokeColor:"#CCCCCC"},Ll)],t.prototype,"separatorStyle",void 0),t}(hT),lm=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"UmlClassMethod"},q([Ft([],hT)],t.prototype,"parameters",void 0),t}(rp),rb=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"UmlClass"},q([I("")],t.prototype,"name",void 0),q([Ft([],rp)],t.prototype,"attributes",void 0),q([Ft([],lm)],t.prototype,"methods",void 0),q([re({},Qf)],t.prototype,"style",void 0),t}(Ee),cT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"UmlInterface"},q([I(!1)],t.prototype,"isSeparator",void 0),q([re({fill:"#F9F9F9",strokeColor:"#CCCCCC"},Ll)],t.prototype,"separatorStyle",void 0),t}(rb),nb=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"UmlEnumerationMember"},q([I("")],t.prototype,"name",void 0),q([I("")],t.prototype,"value",void 0),q([I(!1)],t.prototype,"isSeparator",void 0),q([re({fill:"#F9F9F9",strokeColor:"#CCCCCC"},Ll)],t.prototype,"separatorStyle",void 0),q([re({},Qf)],t.prototype,"style",void 0),t}(Ee),dT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"UmlEnumeration"},q([I("")],t.prototype,"name",void 0),q([Ft([],nb)],t.prototype,"members",void 0),q([re({},Qf)],t.prototype,"style",void 0),t}(Ee),TF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"UmlClassifierShape"},q([I("UmlClassifier")],t.prototype,"type",void 0),q([re({},rb)],t.prototype,"classShape",void 0),q([re({},cT)],t.prototype,"interfaceShape",void 0),q([re({},dT)],t.prototype,"enumerationShape",void 0),q([I("Class")],t.prototype,"classifier",void 0),t}(ma),te=function(n){function t(e,i,r,s){var a,o=n.call(this,e,i,r,s)||this;return o.isCanvasUpdate=!1,o.status="None",o.parentId="",o.processId="",o.umlIndex=-1,o.outEdges=[],o.inEdges=[],o.isHeader=!1,o.isLane=!1,o.isPhase=!1,o.children&&o.children.length>0&&((!(a=r).style||!a.style.fill)&&(o.style.fill="transparent"),(!a.style||!a.style.strokeColor)&&(o.style.strokeColor="transparent")),o.shape&&"UmlActivity"===o.shape.type&&$I(r,o),o.shape&&"SwimLane"===o.shape.type&&sF(r,o),o.ports&&o.ports.length&&function rse(n){for(var t=0;t>";t=n;break;case"FinalNode":t=uF(e)}return t}(new Ze,i,this);break;case"Bpmn":if(e.bpmnModule){i=e.bpmnModule.initBPMNContent(i,this,e),this.wrapper.elementActions=this.wrapper.elementActions|Xr.ElementIsGroup;var v=this.shape.activity.subProcess;if(v.processes&&v.processes.length)for(var S=0,b=this.shape.activity.subProcess.processes;S>",margin:{left:10,right:10},id:"class",style:{fontSize:i.style.fontSize,color:i.style.color,fill:i.style.fill,textWrapping:r},offset:{x:.5,y:.3},constraints:Nr.ReadOnly}],constraints:(ie.Default|ie.HideThumbs)&~(ie.Rotate|ie.Drag|ie.Resize),verticalAlignment:"Stretch",horizontalAlignment:"Stretch",style:{fill:t.style.fill,strokeColor:"black"===t.style.strokeColor?"#ffffff00":t.style.strokeColor}},!0);return e.initObject(s),e.nodes.push(s),e.UpdateBlazorDiagramModel(s,"Node"),t.children.push(s.id),function jse(n,t,e,i){if("Enumeration"===n.shape.classifier){var r=e.members;if(r&&r.length){tp(n,t);for(var s="",o=0;o0)for(var o=0;o0&&s.phaseSize&&(i+=s.phaseSize,Yv(n,s.phaseSize)),s.lanes.length>0)for(o=0;o0){var a=0;for(o=0;o0&&"Horizontal"===r.orientation)for(l=0;l0&&(i+=r.phaseSize,o=Qv(r.phaseSize),n.push(o)),a=0;a0&&o.phaseSize){for(var l=0;l0)for(l=0;l0?e.nameTable[this.nodes[0].id].wrapper:e.nameTable[this.connectors[0].id].wrapper,this.annotation.id);i.children.push(s)}else if(this.nodes||this.connectors){for(var o=0;o-1}function zF(n,t,e){n=[];for(var i=0,r=e.length;i0?c.getElementsByTagName("svg")[0].outerHTML:c.getElementsByTagName("g").length>0?c.getElementsByTagName("g")[0].outerHTML:"",s.shape.content=h,n.content=h,c.parentElement.removeChild(c)}l="nodeTemplate"}else a=s,l="annotationTemplate";var p=document.getElementById(n.diagramId).ej2_instances[0];if("string"!=typeof n.content&&"function"!=typeof n.content||n.isTemplate)if(n.isTemplate){if(v=void 0,v=p.isReact?n.getNodeTemplate()($(e),p,l+"_"+("nodeTemplate"===l?e.id:n.nodeId+e.id),void 0,void 0,!1,i):p.isVue||p.isVue3?n.getNodeTemplate()?n.getNodeTemplate()($(e),p,l+"_"+("nodeTemplate"===l?e.id:n.nodeId+e.id),void 0,void 0,!1,i):(v=si("nodeTemplate"===l?p.nodeTemplate:p.annotationTemplate))($(e),p,l+"_"+("nodeTemplate"===l?e.id:n.nodeId+e.id),void 0,void 0,!1,i):n.getNodeTemplate()($(e),p,l+"_"+("nodeTemplate"===l?e.id:n.nodeId+e.id),void 0,void 0,!1))for(var M=0;M=1&&0===n.x&&("Clip"===i.textOverflow||"Ellipsis"===i.textOverflow)&&("Wrap"===i.textWrapping||"WrapWithOverflow"===i.textWrapping)&&(n.x=t[e-1]?t[e-1].x:-n.width/2),n.x}function BF(n,t,e,i){return e&&!t.template||t.template&&"function"==typeof t.template&&i.isReact?(n.isTemplate=!0,n.template=n.content=Hh(n,!0,t)):n.content=t.template,n}function Qe(){for(var e,t="",i=0;i<5;i++){if(typeof window<"u"&&"crypto"in window&&"getRandomValues"in crypto){var r=new Uint16Array(1);e=(window.msCrypto||window.crypto).getRandomValues(r)[0]%60}else e=Math.floor(61*Math.random());0===i&&e<10?i--:t+="0123456789ABCDEFGHIJKLMNOPQRSTUVWXTZabcdefghiklmnopqrstuvwxyz".substring(e,e+1)}return t}function FF(n){if(n)try{return"function"!=typeof n&&document.querySelectorAll(n).length?si(document.querySelector(n).innerHTML.trim()):si(n)}catch{return si(n)}}function xn(n){new Ne;var e=n.offsetY-n.actualSize.height*n.pivot.y,i=n.offsetY+n.actualSize.height*(1-n.pivot.y),r=n.offsetX-n.actualSize.width*n.pivot.x,s=n.offsetX+n.actualSize.width*(1-n.pivot.x);return Ne.toBounds([{x:r,y:e},{x:s,y:e},{x:r,y:i},{x:s,y:i}])}function yr(n){var t=new Ne,e=xn(n),i=e.middleLeft,r=e.topCenter,s=e.bottomCenter,o=e.middleRight,a=e.topLeft,l=e.topRight,h=e.bottomLeft,c=e.bottomRight;if(n.corners={topLeft:a,topCenter:r,topRight:l,middleLeft:i,middleRight:o,bottomLeft:h,bottomCenter:s,bottomRight:c},0!==n.rotateAngle||0!==n.parentTransform){var d=Bi();qi(d,n.rotateAngle+n.parentTransform,n.offsetX,n.offsetY),n.corners.topLeft=a=Ke(d,a),n.corners.topCenter=r=Ke(d,r),n.corners.topRight=l=Ke(d,l),n.corners.middleLeft=i=Ke(d,i),n.corners.middleRight=o=Ke(d,o),n.corners.bottomLeft=h=Ke(d,h),n.corners.bottomCenter=s=Ke(d,s),n.corners.bottomRight=c=Ke(d,c)}return t=Ne.toBounds([a,l,h,c]),n.corners.left=t.left,n.corners.right=t.right,n.corners.top=t.top,n.corners.bottom=t.bottom,n.corners.center=t.center,n.corners.width=t.width,n.corners.height=t.height,t}function $(n,t,e,i){var r={},s="properties";if(n){e=n.propName;var l=[],h=[];if((l=l.concat(Object.keys(n[""+s]||n))).push("version"),e){var c=Zi(t);h=c?c(e):[],l=l.concat(h)}for(var d=function Soe(n){switch(n){case"nodes":case"children":return["inEdges","outEdges","parentId","processId","nodeId","umlIndex","isPhase","isLane"];case"connectors":return["parentId"];case"annotation":case"annotations":return["nodeId"];case"shape":return["hasHeader"];case"layers":return["objectZIndex"]}return[]}(e),u=0,f=l=l.concat(d);u0&&(e=r),r=Math.floor(boe(e,i)),s=Bc(o+=n.substr(e,r),t)}while(s<=t.width);for(o=o.substr(0,e),a=e;a=t.width){n=n.substr(0,o.length-1);break}return"Ellipsis"===t.textOverflow?(n=n.substr(0,n.length-3),n+="..."):n=n.substr(0,n.length),n}function yT(n,t){if("NoWrap"===t&&"PreserveAll"===n)return"pre";var e="";switch(n){case"CollapseAll":e="nowrap";break;case"CollapseSpace":e="pre-line";break;case"PreserveAll":e="pre-wrap"}return e}function ST(n,t){var e=Bi();qi(e,t,0,0);var i=Ke(e,{x:0,y:0}),r=Ke(e,{x:n.width,y:0}),s=Ke(e,{x:0,y:n.height}),o=Ke(e,{x:n.width,y:n.height}),a=Math.min(i.x,r.x,s.x,o.x),l=Math.min(i.y,r.y,s.y,o.y),h=Math.max(i.x,r.x,s.x,o.x),c=Math.max(i.y,r.y,s.y,o.y);return new me(h-a,c-l)}function xs(n,t,e,i){if(0!==n){var r=Bi();return qi(r,n,t,e),Ke(r,i)}return i}function Zi(n){return void 0!==n&&"string"==typeof n&&(n=Y(n,window)),n}var bo=function(){function n(){}return n.getContext=function(t){return t.getContext("2d")},n.setCanvasSize=function(t,e,i){t&&(t.setAttribute("width",e.toString()),t.setAttribute("height",i.toString()))},n.prototype.renderGradient=function(t,e,i,r){var s,o,a;if("None"!==t.gradient.type){for(var l=0;l0?(w=0===S.r1?e.arc[parseInt(r.toString(),10)].r1:S.r1,C=0===S.r2?e.arc[parseInt(r.toString(),10)].r2:S.r2,r++):(w=S.r1,C=S.r2);var D=S.angle*(Math.PI/180),A=S.largeArc,x=S.sweep,P={x:u,y:f},L={x:Math.cos(D)*(M.x-P.x)/2+Math.sin(D)*(M.y-P.y)/2,y:-Math.sin(D)*(M.x-P.x)/2+Math.cos(D)*(M.y-P.y)/2},O=Math.pow(L.x,2)/Math.pow(w,2)+Math.pow(L.y,2)/Math.pow(C,2);O>1&&(w*=Math.sqrt(O),C*=Math.sqrt(O));var N=Math.pow(C,2)*Math.pow(L.x,2),T=(A===x?-1:1)*Math.sqrt((Math.pow(w,2)*Math.pow(C,2)-Math.pow(w,2)*Math.pow(L.y,2)-N)/(Math.pow(w,2)*Math.pow(L.y,2)+Math.pow(C,2)*Math.pow(L.x,2)));isNaN(T)&&(T=0);var z={x:T*w*L.y/C,y:T*-C*L.x/w},U={x:(M.x+P.x)/2+Math.cos(D)*z.x-Math.sin(D)*z.y,y:(M.y+P.y)/2+Math.sin(D)*z.x+Math.cos(D)*z.y},B=this.a([1,0],[(L.x-z.x)/w,(L.y-z.y)/C]),j=[(L.x-z.x)/w,(L.y-z.y)/C],Q=[(-L.x-z.x)/w,(-L.y-z.y)/C],oe=this.a(j,Q);this.r(j,Q)<=-1&&(oe=Math.PI),this.r(j,Q)>=1&&(oe=0);var fe=B+oe/2*(x?1:-1);if(Math.cos(fe),Math.sin(fe),S.centp=U,S.xAxisRotation=D,S.rx=w,S.ry=C,S.a1=B,S.ad=oe,S.sweep=x,null!=s){var De=w>C?w:C,xe=w>C?1:w/C,Ie=w>C?C/w:1;s.save(),s.translate(U.x,U.y),s.rotate(D),s.scale(xe,Ie),s.arc(0,0,De,B,B+oe,!x),s.scale(1/xe,1/Ie),s.rotate(-D),s.translate(-U.x,-U.y),s.restore()}break;case"Z":case"z":s.closePath(),u=o,f=a}o=u,a=f}}},n.prototype.drawText=function(t,e,i,r,s,o,a){if(e.content&&!0===e.visible){var l=n.getContext(t);l.save(),this.setStyle(t,e),o&&(e.fontSize*=o),this.applyFlipAndRotate(l,e,t,e.x+e.width*e.pivotX,e.y+e.height*e.pivotY),this.setFontStyle(t,e);var u,d=0;u=e.childNodes;var f=e.wrapBounds;if(l.fillStyle=e.color,f){var p=this.labelAlign(e,f,u);for(d=0;de.width&&"Wrap"!==e.textOverflow&&"NoWrap"===e.textWrapping&&(g.text=UF(g.text,e)),"Clip"!==e.textOverflow&&"Ellipsis"!==e.textOverflow||"Wrap"!==e.textWrapping?l.fillText(g.text,v,y):ya.actualSize.height+a.bounds.y&&(g.text=g.text.slice(0,g.text.length-3),g.text=g.text.concat("...")),l.fillText(g.text,v,y)),"Underline"===e.textDecoration||"Overline"===e.textDecoration||"LineThrough"===e.textDecoration){var M=v,w=void 0,D=v+l.measureText(g.text).width,A=void 0;switch(e.textDecoration){case"Underline":w=y+2,A=y+2;break;case"Overline":w=p.y+g.dy*d,A=p.y+g.dy*d;break;case"LineThrough":w=(y+p.y+g.dy*d)/2+2,A=(y+p.y+g.dy*d)/2+2}l.beginPath(),l.moveTo(M,w),l.lineTo(D,A),l.strokeStyle=e.color,l.lineWidth=.08*e.fontSize,l.globalAlpha=e.opacity,l.stroke()}}}l.restore()}},n.prototype.applyFlipAndRotate=function(t,e,i,r,s){"Horizontal"===e.flip||"Vertical"===e.flip?(t.translate(e.x+e.width/2,e.y+e.height/2),t.rotate(-e.angle*Math.PI/180),t.translate(-e.x-e.width/2,-e.y-e.height/2)):this.rotateContext(i,e.angle,r,s),t.translate(e.x,e.y),"Horizontal"===e.flip?(t.scale(-1,1),t.translate(-1*e.width,0)):"Vertical"===e.flip?(t.scale(1,-1),t.translate(0,-1*e.height)):"Both"===e.flip&&(t.scale(-1,-1),t.translate(-1*e.width,-1*e.height)),t.translate(-e.x,-e.y)},n.prototype.loadImage=function(t,e,i,r,s){var o=new Image;o.src=e.source,this.image(t,o,e.x,e.y,e.width,e.height,e)},n.prototype.drawImage=function(t,e,i,r){var s=this;if(e.visible){var o=n.getContext(t);o.save();var a=e.x+e.width*e.pivotX,l=e.y+e.height*e.pivotY,h=new Image;h.src=e.source,this.setStyle(t,e),o.canvas.id.split("_"),this.applyFlipAndRotate(o,e,t,a,l),r?h.onload=function(){s.loadImage(o,e,t,a,l)}:this.loadImage(o,e,t,a,l),o.restore()}},n.prototype.image=function(t,e,i,r,s,o,a){t.beginPath();var l=e.width,h=e.height,c=s,d=o,u=0,f=0;if(a&&"None"!==a.alignment){var p=a.alignment.toLowerCase().substr(1,3),g=a.alignment.toLowerCase().substr(5,3);if("Slice"===a.scale){var v=function(){u=c,f=h*c/l},y=function(){u=l*d/h,f=d};c>d?(v(),d>f&&y()):c===d?l>h?y():v():(y(),c>u&&v());var S=this.getSliceOffset(p,u,c,l),b=this.getSliceOffset(g,f,d,h),M=l-S,w=h-b,C=u-S*(u/l),D=f-b*(f/h),A=Tt("canvas",{width:s.toString(),height:o.toString()});A.getContext("2d").drawImage(e,S,b,M,w,0,0,C,D),t.drawImage(A,i,r,s,o)}else if("Meet"===a.scale){var P=h/l,L=d/c;f=L>P?c*P:d,i+=this.getMeetOffset(p,u=L>P?c:d/P,c),r+=this.getMeetOffset(g,f,d),t.drawImage(e,0,0,l,h,i,r,u,f)}else t.drawImage(e,i,r,s,o)}else if("None"!==a.flip){var O=1,N=1;("Horizontal"===a.flip||"Both"===a.flip)&&(i=-i,s=-s,O=-1),("Vertical"===a.flip||"Both"===a.flip)&&(r=-r,o=-o,N=-1),t.scale(O,N),t.drawImage(e,i,r,s,o)}else t.drawImage(e,i,r,s,o);t.closePath()},n.prototype.getSliceOffset=function(t,e,i,r){switch(t){case"min":default:return 0;case"mid":return(e-i)/2*r/e;case"max":return(e-i)*r/e}},n.prototype.getMeetOffset=function(t,e,i){var r=Math.max(e,i),s=Math.min(e,i);switch(t){case"min":default:return 0;case"mid":return(r-s)/2;case"max":return r-s}},n.prototype.m=function(t){return Math.sqrt(Math.pow(t[0],2)+Math.pow(t[1],2))},n.prototype.r=function(t,e){return(t[0]*e[0]+t[1]*e[1])/(this.m(t)*this.m(e))},n.prototype.a=function(t,e){return(t[0]*e[1]t.width&&("Ellipsis"===t.textOverflow||"Clip"===t.textOverflow)&&"NoWrap"===t.textWrapping?0:.5*t.width:"right"===t.textAlign&&(c=1*t.width),s.x=t.x+c+(e?e.x:0),s.y=a+d-r.height/2,s},n}(),hb=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Vi=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},woe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return hb(t,n),Vi([I("")],t.prototype,"source",void 0),Vi([I("transparent")],t.prototype,"color",void 0),Vi([I("None")],t.prototype,"scale",void 0),Vi([I("None")],t.prototype,"align",void 0),t}(Ee),Coe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return hb(t,n),Vi([I("Page")],t.prototype,"mode",void 0),Vi([I("PageSettings")],t.prototype,"region",void 0),Vi([re({top:25,bottom:25,left:25,right:25},Jn)],t.prototype,"margin",void 0),Vi([I(!1)],t.prototype,"canZoomIn",void 0),Vi([I(void 0)],t.prototype,"customBounds",void 0),Vi([I(!1)],t.prototype,"canFit",void 0),t}(Ee),Eoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return hb(t,n),Vi([I(null)],t.prototype,"width",void 0),Vi([I(null)],t.prototype,"height",void 0),Vi([re({},Jn)],t.prototype,"margin",void 0),Vi([I("Landscape")],t.prototype,"orientation",void 0),Vi([I("Infinity")],t.prototype,"boundaryConstraints",void 0),Vi([re({},woe)],t.prototype,"background",void 0),Vi([I(!1)],t.prototype,"multiplePage",void 0),Vi([I(!1)],t.prototype,"showPageBreaks",void 0),Vi([re({},Coe)],t.prototype,"fitOptions",void 0),t}(Ee),Doe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return hb(t,n),Vi([I(0)],t.prototype,"horizontalOffset",void 0),Vi([I(0)],t.prototype,"verticalOffset",void 0),Vi([I(1)],t.prototype,"currentZoom",void 0),Vi([I(0)],t.prototype,"viewPortWidth",void 0),Vi([I(0)],t.prototype,"viewPortHeight",void 0),Vi([I(.2)],t.prototype,"minZoom",void 0),Vi([I(30)],t.prototype,"maxZoom",void 0),Vi([I("Diagram")],t.prototype,"scrollLimit",void 0),Vi([I()],t.prototype,"scrollableArea",void 0),Vi([I(!1)],t.prototype,"canAutoScroll",void 0),Vi([I(100)],t.prototype,"autoScrollFrequency",void 0),Vi([re({left:15,right:15,top:15,bottom:15},Jn)],t.prototype,"autoScrollBorder",void 0),Vi([re({left:0,right:0,top:0,bottom:0},Jn)],t.prototype,"padding",void 0),Vi([I(.2)],t.prototype,"zoomFactor",void 0),t}(Ee),xoe=function(){function n(){this.services={}}return n.prototype.register=function(t,e){this.services[""+t]=e},n.prototype.getService=function(t){return this.services[""+t]},n}(),jF=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),ya=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},VF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return jF(t,n),ya([I("lightgray")],t.prototype,"lineColor",void 0),ya([I("")],t.prototype,"lineDashArray",void 0),ya([I([1.25,18.75,.25,19.75,.25,19.75,.25,19.75,.25,19.75])],t.prototype,"lineIntervals",void 0),ya([I([1,19,.5,19.5,.5,19.5,.5,19.5,.5,19.5])],t.prototype,"dotIntervals",void 0),ya([I([20])],t.prototype,"snapIntervals",void 0),t}(Ee),Toe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return jF(t,n),ya([re({},VF)],t.prototype,"horizontalGridlines",void 0),ya([re({},VF)],t.prototype,"verticalGridlines",void 0),ya([I(Kt.All)],t.prototype,"constraints",void 0),ya([I(5)],t.prototype,"snapAngle",void 0),ya([I("Lines")],t.prototype,"gridType",void 0),ya([I(5)],t.prototype,"snapObjectDistance",void 0),ya([I("#07EDE1")],t.prototype,"snapLineColor",void 0),t}(Ee),WF=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),el=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},YF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return WF(t,n),el([I(5)],t.prototype,"interval",void 0),el([I(100)],t.prototype,"segmentWidth",void 0),el([I("Horizontal")],t.prototype,"orientation",void 0),el([I("RightOrBottom")],t.prototype,"tickAlignment",void 0),el([I("red")],t.prototype,"markerColor",void 0),el([I(25)],t.prototype,"thickness",void 0),el([I(null)],t.prototype,"arrangeTick",void 0),t}(Ee),Aoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return WF(t,n),el([I(!1)],t.prototype,"showRulers",void 0),el([I(!0)],t.prototype,"dynamicGrid",void 0),el([re({orientation:"Horizontal"},YF)],t.prototype,"horizontalRuler",void 0),el([re({orientation:"Vertical"},YF)],t.prototype,"verticalRuler",void 0),t}(Ee),Loe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),QF=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Noe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Loe(t,n),QF([I("")],t.prototype,"property",void 0),QF([I("")],t.prototype,"field",void 0),t}(Ee),IT=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),ln=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},GF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return IT(t,n),ln([I("")],t.prototype,"read",void 0),ln([I("")],t.prototype,"create",void 0),ln([I("")],t.prototype,"update",void 0),ln([I("")],t.prototype,"destroy",void 0),ln([I()],t.prototype,"customFields",void 0),t}(Ee),Ooe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return IT(t,n),ln([I("")],t.prototype,"id",void 0),ln([I("")],t.prototype,"sourceID",void 0),ln([I("")],t.prototype,"targetID",void 0),ln([I(null)],t.prototype,"sourcePointX",void 0),ln([I(null)],t.prototype,"sourcePointY",void 0),ln([I(null)],t.prototype,"targetPointX",void 0),ln([I(null)],t.prototype,"targetPointY",void 0),ln([I(null)],t.prototype,"dataManager",void 0),ln([re({},GF)],t.prototype,"crudAction",void 0),t}(Ee),koe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return IT(t,n),ln([I("")],t.prototype,"id",void 0),ln([I(null)],t.prototype,"dataManager",void 0),ln([I(null)],t.prototype,"dataSource",void 0),ln([I("")],t.prototype,"root",void 0),ln([I("")],t.prototype,"parentId",void 0),ln([I()],t.prototype,"doBinding",void 0),ln([Ft([],Noe)],t.prototype,"dataMapSettings",void 0),ln([re({},GF)],t.prototype,"crudAction",void 0),ln([re({},Ooe)],t.prototype,"connectionDataSource",void 0),t}(Ee),XF=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Cr=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Poe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return XF(t,n),Cr([I("LeftInFlow")],t.prototype,"yesBranchDirection",void 0),Cr([I("RightInFlow")],t.prototype,"noBranchDirection",void 0),Cr([I(["Yes","True"])],t.prototype,"yesBranchValues",void 0),Cr([I(["No","False"])],t.prototype,"noBranchValues",void 0),t}(Ee),zoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return XF(t,n),Cr([I("")],t.prototype,"fixedNode",void 0),Cr([I(30)],t.prototype,"horizontalSpacing",void 0),Cr([I("SamePoint")],t.prototype,"connectionPointOrigin",void 0),Cr([I("Nonlinear")],t.prototype,"arrangement",void 0),Cr([I(30)],t.prototype,"verticalSpacing",void 0),Cr([I(30)],t.prototype,"maxIteration",void 0),Cr([I(40)],t.prototype,"springFactor",void 0),Cr([I(50)],t.prototype,"springLength",void 0),Cr([re({left:50,top:50,right:0,bottom:0},Jn)],t.prototype,"margin",void 0),Cr([I("Auto")],t.prototype,"horizontalAlignment",void 0),Cr([I("Auto")],t.prototype,"verticalAlignment",void 0),Cr([I("TopToBottom")],t.prototype,"orientation",void 0),Cr([I("Auto")],t.prototype,"connectionDirection",void 0),Cr([I("Default")],t.prototype,"connectorSegments",void 0),Cr([I("None")],t.prototype,"type",void 0),Cr([I()],t.prototype,"getLayoutInfo",void 0),Cr([I()],t.prototype,"layoutInfo",void 0),Cr([I()],t.prototype,"getBranch",void 0),Cr([I()],t.prototype,"bounds",void 0),Cr([I(!0)],t.prototype,"enableAnimation",void 0),Cr([I(!1)],t.prototype,"enableRouting",void 0),Cr([I("")],t.prototype,"root",void 0),Cr([re({},Poe)],t.prototype,"flowchartLayoutSettings",void 0),t}(Ee),Roe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),qF=function(n){function t(e,i){var r=n.call(this,e,!0)||this;return r.oldValue=null,r.endPoint=i,r}return Roe(t,n),t.prototype.mouseDown=function(e){var i,r=!0;if(e.source&&e.source.connectors&&(i=e.source.connectors[0]),e.info&&e.actualObject&&(r=e.info.ctrlKey&&"Orthogonal"!==e.actualObject.type),i&&r){this.inAction=!0,this.undoElement=$(e.source),n.prototype.mouseDown.call(this,e);for(var s=0;s0)1!==s&&this.removePrevSegment(i,s);else if(a){var l=R.distancePoints(a.points[0],a.points[1]);Math.abs(a.length||0===a.length?a.length:l)<=5&&this.removeNextSegment(i,s)}this.commandHandler.updateEndPoint(i,r),i.selectedSegmentIndex=0}if(this.undoElement){var c=$(e.source);this.commandHandler.addHistoryEntry({type:"SegmentChanged",redoObject:c,undoObject:this.undoElement,category:"Internal"})}if(i.isBezierEditing&&(i.isBezierEditing=!1),this.prevPosition!==this.startPosition){var u={source:i,state:"Completed",oldValue:this.oldValue,newValue:$(this.selectedSegment),cancel:!1,segment:this.selectedSegment};this.commandHandler.triggerEvent(Ce.segmentChange,u)}n.prototype.mouseUp.call(this,e)},t.prototype.removePrevSegment=function(e,i){var r=e.segments[i-2],s=e.segments[i+1];if(s&&!((s.length||0===s.length?s.length:R.distancePoints(s.points[0],s.points[1]))<=5)){var a=e.segments.slice(i-1,i+1),l={element:e,removeSegments:a,type:"Removal",cancel:!1};if(this.commandHandler.triggerEvent(Ce.segmentCollectionChange,l),!l.cancel){var h=e.segments[i+1];e.segments.splice(i-1,2);var c=this.selectedSegment;"Left"===c.direction||"Right"===c.direction?(r.points[r.points.length-1].x=h.points[0].x,h.points[0].y=r.points[r.points.length-1].y):(r.points[r.points.length-1].y=h.points[0].y,h.points[0].x=r.points[r.points.length-1].x),(c.length||0===c.length)&&this.findSegmentDirection(r),this.findSegmentDirection(h)}}},t.prototype.findSegmentDirection=function(e){e.direction&&(e.length||0===e.length)&&(e.length=R.distancePoints(e.points[0],e.points[e.points.length-1]),e.direction=R.direction(e.points[0],e.points[e.points.length-1]))},t.prototype.removeNextSegment=function(e,i){var l,h,r=this.selectedSegment,s=e.segments[i-1],o=e.segments[i+2],a=e.segments[i+1];if(a.length||0===a.length?(l=e.segments.slice(i,2),h={element:e,removeSegments:l,type:"Removal",cancel:!1},this.commandHandler.triggerEvent(Ce.segmentCollectionChange,h={element:e,removeSegments:l,type:"Removal",cancel:!1}),h.cancel||(e.segments.splice(i,2),"Top"===r.direction||"Bottom"===r.direction?(o.points[0].y=r.points[0].y,s.points[s.points.length-1].x=o.points[0].x):(o.points[0].x=r.points[0].x,s.points[s.points.length-1].y=o.points[0].y))):(l=e.segments.slice(i+1,1),this.commandHandler.triggerEvent(Ce.segmentCollectionChange,h={element:e,removeSegments:l,type:"Removal",cancel:!1}),h.cancel||(e.segments.splice(i+1,1),"Top"===r.direction||"Bottom"===r.direction?s.points[s.points.length-1].x=a.points[a.points.length-1].x:s.points[s.points.length-1].y=a.points[a.points.length-1].y,this.findSegmentDirection(s),r.length=r.direction=null)),s&&o&&!h.cancel&&(s.length=R.distancePoints(s.points[0],o.points[0]),s.direction=R.direction(s.points[0],o.points[0]),o.length||0===o.length)){o.length=R.distancePoints(s.points[s.points.length-1],o.points[o.points.length-1]);var c=s.points,d=o.points;o.direction=R.direction(c[c.length-1],d[d.length-1])}},t.prototype.addOrRemoveSegment=function(e,i,r){for(var s,o,a=[],l={segments:e.segments},h=0;h0?"Bottom":"Top":r>0?"Right":"Left",length:i.points[0].x===i.points[1].x?s:r},!0)),l.push(new wi(e,"segments",{type:"Orthogonal",direction:c,length:h/2},!0));var f={element:e,addSegments:l,type:"Addition",cancel:!1};return this.commandHandler.triggerEvent(Ce.segmentCollectionChange,f),f.cancel||(e.segments=l.concat(e.segments),a=o+2),a},t.prototype.insertFirstSegment=function(e,i,r,s,o){var a,l,d,u,h=[];if(e.sourcePortID&&i.length&&e.segments[0].points.length>2)for(var f=void 0,p=0;p0?"Bottom":"Top":r>0?"Right":"Left"),f=u,h.push(u)}else h.push(new wi(e,"segments",{type:"Orthogonal",direction:i.direction,length:i.length/3},!0)),"Bottom"===i.direction||"Top"===i.direction?(l=Math.abs(r),a=r>0?"Right":"Left"):(l=Math.abs(s),a=s>0?"Bottom":"Top"),u=new wi(e,"segments",{type:"Orthogonal",direction:a,length:l},!0),h.push(u);var y={element:e,addSegments:h,type:"Addition",cancel:!1};if(this.commandHandler.triggerEvent(Ce.segmentCollectionChange,y),!y.cancel){if(e.sourcePortID&&i.length&&e.segments[0].points.length>2)e.segments.splice(0,1),d=1;else{var S=e.segments[1];S&&S.length&&(S.length=a!==S.direction?S.length+l:S.length-l),d=2,i.length=2*i.length/3}e.segments=h.concat(e.segments)}return d},t.prototype.updateAdjacentSegments=function(e,i,r,s){var o=e.segments[parseInt(i.toString(),10)],a=o.points[o.points.length-1],h=!0;"Orthogonal"===o.type&&(o.points[0]=o.points[0],o.points[o.points.length-1]=a,e.segments[i-1]&&(h=this.updatePreviousSegment(r,s,e,i)),e.segments.length-1>i&&h&&this.updateNextSegment(e,o,e.segments[i+1],r,s))},t.prototype.addTerminalSegment=function(e,i,r,s,o){var l,h,c,d,a=e.segments.indexOf(i),u=[],f=e.segments.pop(),p=e.segments[e.segments.length-1];l=p&&"Orthogonal"===p.type?p:null;for(var g=0;g0&&"Left"===o.direction?c.middleLeft:c.middleRight,o.length>c.width/2?Math.abs(a.length)0&&"Top"===o.direction?c.topCenter:c.bottomCenter,o.length>c.height/2?Math.abs(a.length)1)for(var a=0,l=this.diagram.views;a0)for(var e=t===Ce.onUserHandleMouseLeave?this.previousAction:this.action,i={element:void 0},r=0;r0)for(var r={element:void 0},s=void 0,o=void 0,a=0;a-1&&(o=s,this.previousTarget=i,this.targetItem=e),o===e.fixedUserHandles[parseInt(a.toString(),10)].id&&(r.element=e.fixedUserHandles[parseInt(a.toString(),10)],this.userHandle(t,a,r,e))},n.prototype.mouseDown=function(t){var e=this;if("touchstart"===t.type&&(this.timeOutTapHold=setTimeout(function(){("Select"===e.action||"Drag"===e.action)&&e.mouseMove(t,void 0)},500)),!0!==this.inAction||!(this.tool instanceof jI||this.tool instanceof pa)){this.focus=!0;var i=t.touches,r=!!document.getElementsByClassName("e-dragclone")[0];if(this.isMouseOnScrollBar(t)&&!r)return this.isScrolling=!0,void t.preventDefault();if(this.checkFixedUserHandleEvent(Ce.onFixedUserHandleMouseDown,this.targetItem,this.previousTarget),this.checkUserHandleEvent(Ce.onUserHandleMouseDown),!this.checkEditBoxAsTarget(t)&&_v(this.diagram)||Lc(this.diagram)&&!PI(this.diagram))if(("Select"===this.action||"Drag"===this.action)&&this.diagram.updatePortVisibility(this.hoverElement,ci.Hover,!0),!(this.tool instanceof zl||this.tool instanceof Rl)||2!==t.button&&2!==t.buttons)if(!0===this.inAction&&!0===this.isMouseDown&&(this.tool instanceof zl||this.tool instanceof Rl))this.isMouseDown=!0,this.eventArgs={},this.getMouseEventArgs(this.currentPosition,this.eventArgs),this.eventArgs.position=this.currentPosition,this.tool.mouseDown(this.eventArgs);else{this.isMouseDown=!0,this.currentPosition=this.prevPosition=this.getMousePosition(t),this.eventArgs={},this.diagram.textEditing&&!this.isMouseOnScrollBar(t)&&(this.diagram.endEdit(),this.diagram.textEditing=!1,"Canvas"===this.diagram.mode&&1!==this.diagram.scroller.currentZoom&&this.diagram.refreshDiagramLayer());var o=this.getTargetElement();this.action=this.diagram.findActionToBeDone(o.obj,o.sourceElement,this.currentPosition,o.target);var a=this.isMetaKey(t);a&&t.shiftKey&&this.diagram.connectorEditingToolModule?this.action="SegmentEnd":(a||t.shiftKey)&&(Bv(this.diagram)||Fv(this.diagram))&&(this.action="Select"),this.tool=this.diagram.getTool(this.action),this.tool||(this.action="Select",this.tool=this.diagram.getTool(this.action)),this.getMouseEventArgs(this.currentPosition,this.eventArgs),(a||t.shiftKey)&&(this.eventArgs.info=a&&t.shiftKey?{ctrlKey:a,shiftKey:t.shiftKey}:{ctrlKey:!0}),this.eventArgs.position=this.currentPosition;var h=this.diagram.selectedItems.nodes;if(this.tool.mouseDown(this.eventArgs),this.diagram.selectedItems.canToggleSelection&&h&&this.diagram.selectedItems.nodes&&this.tool instanceof fa)for(var c=0;c=2&&(this.touchStartList=zF(this.touchStartList,0,i)),i||t.preventDefault())}else this.inAction=!1,this.tool.mouseUp(this.eventArgs);!this.isForeignObject(t.target)&&!this.isForeignObject(t.target,!0)&&!i&&t.preventDefault()}},n.prototype.mouseMoveExtend=function(t,e){(this.tool instanceof zl||this.tool instanceof Rl)&&this.tool.mouseMove(this.eventArgs),this.diagram.scrollSettings.canAutoScroll?this.checkAutoScroll(t):this.blocked||this.tool.mouseMove(this.eventArgs),this.eventArgs.target&&(this.hoverElement=this.eventArgs.target);var i=!((this.eventArgs.target instanceof te||this.eventArgs.target instanceof de)&&(e instanceof te||e instanceof de));this.tool instanceof kd&&this.diagram.updatePortVisibility(this.hoverElement instanceof te||this.hoverElement instanceof de?this.hoverElement:this.hoverNode,ci.Connect|ci.Hover,i),this.hoverElement instanceof te&&this.hoverNode instanceof te&&this.hoverNode&&this.hoverNode.id!==this.hoverElement.id&&this.diagram.updatePortVisibility(this.hoverNode,ci.Connect|ci.Hover,!0),this.hoverElement instanceof de&&this.hoverElement.ports.length>0&&this.diagram.updatePortVisibility(this.hoverElement,ci.Connect|ci.Hover,!0),this.previousElement instanceof te&&this.hoverElement&&this.previousElement.id!==this.hoverElement.id&&this.diagram.updatePortVisibility(this.previousElement,ci.Connect|ci.Hover,!0),this.previousElement=this.hoverElement,""!==this.diagram.tooltip.content&&(this.hoverElement=null),this.hoverNode=i?null:e},n.prototype.checkAction=function(t){if("LabelSelect"===this.action&&this.eventArgs.sourceWrapper&&(this.eventArgs.sourceWrapper instanceof ai||this.eventArgs.sourceWrapper instanceof es)){var e=this.commandHandler.findTarget(this.eventArgs.sourceWrapper,this.eventArgs.source);!_r(this.diagram,e,!1,this.eventArgs.sourceWrapper)&&ro(e)&&(this.action="LabelDrag",this.tool=this.getTool(this.action),this.tool.mouseDown(this.initialEventArgs))}else ro(t)&&xd(t)&&this.initialEventArgs&&this.initialEventArgs.source&&"Select"===this.action&&(!_r(this.diagram,this.eventArgs.source,!1)&&this.eventArgs.source instanceof ei&&this.getMouseEventArgs(this.currentPosition,this.eventArgs),(!(t instanceof de)||t instanceof de&&!(wr(this.currentPosition,t.sourcePoint,t.hitPadding)||wr(this.currentPosition,t.targetPoint,t.hitPadding)))&&(this.action="Drag"),this.tool=this.getTool(this.action),this.tool.mouseDown(this.initialEventArgs))},n.prototype.isSwimlaneElements=function(t){return!(t&&(t.isLane||t.isPhase||t.isHeader))},n.prototype.canShowTouchTooltip=function(t){return!!("touchstart"===t.type&&this.diagram.tool&ri.SingleSelect&&this.diagram.tool&ri.ZoomPan)&&(this.isMouseDown=!1,!0)},n.prototype.mouseMove=function(t,e){if(this.focus=!0,"touchmove"===t.type&&(this.touchArgs={target:t.target,type:"touchmove"}),this.isScrolling)t.preventDefault();else if(_v(this.diagram)||Lc(this.diagram)&&!PI(this.diagram)){this.currentPosition=this.getMousePosition(t);var i=this.diagram.findObjectsUnderMouse(this.currentPosition),r=this.diagram.findObjectUnderMouse(i,this.action,this.inAction);!function Yne(n,t){n.rulerSettings.showRulers&&(n.hRuler.drawRulerMarker(n.hRuler.element,t,n.scroller.horizontalOffset),n.vRuler.drawRulerMarker(n.vRuler.element,t,n.scroller.verticalOffset))}(this.diagram,this.currentPosition);var s=!1,o=void 0;if("touchmove"===t.type&&(e=t.touches)&&e.length>1&&(this.touchMoveList=zF(this.touchMoveList,0,e),"PinchZoom"!==this.action&&(s=!0)),!1===R.equals(this.currentPosition,this.prevPosition)||this.inAction||this.canShowTouchTooltip(t)){if(!1===this.isMouseDown||s){this.eventArgs={};var a=null,l=void 0;if(null!==r){if((a=this.diagram.findElementUnderMouse(r,this.currentPosition,this.diagram))&&(l=this.commandHandler.findTarget(a,r)),(l instanceof Kn||l instanceof Or)&&(l.tooltip&&""!==l.tooltip.content||(l=r)),l!==this.hoverElement){var h=this.getContent();this.hoverElement&&"Auto"===this.hoverElement.tooltip.openOn&&""!==h&&this.elementLeave(),this.diagram.updatePortVisibility(this.hoverElement,ci.Hover,!0),r instanceof te&&(this.hoverNode=r);var c=!0;!this.isSwimlaneElements(r)&&this.hoverElement&&this.isSwimlaneElements(this.hoverElement)&&(c=!1),this.hoverElement=c?r:this.hoverElement;var d,u=void 0;(d=this.diagram.findElementUnderMouse(r,this.currentPosition,this.diagram))instanceof Ze&&((u=this.commandHandler.findTarget(d,r))instanceof Es||u instanceof Tc)&&this.hoverElement.constraints&oi.ToolTip&&(this.hoverElement=u);var f=void 0;d instanceof ai&&((f=this.commandHandler.findTarget(d,r))instanceof Kn||f instanceof Or)&&f.constraints&Nr.Tooltip&&(this.hoverElement=f),c?this.elementEnter(this.currentPosition,!1):this.hoverElement=r}else this.hoverElement&&this.hoverElement===l&&this.hoverElement.tooltip.content&&void 0!==this.diagram.tooltipObject&&"Mouse"===this.hoverElement.tooltip.relativeMode&&this.setTooltipOffset(this.currentPosition);a&&(o=this.commandHandler.findTarget(a,r))}this.action=this.diagram.findActionToBeDone(r,a,this.currentPosition,o),this.checkFixedUserHandleEvent(Ce.onFixedUserHandleMouseEnter,r,a),this.checkUserHandleEvent(Ce.onUserHandleMouseEnter),this.checkPreviousAction(),this.getMouseEventArgs(this.currentPosition,this.eventArgs),this.tool=this.getTool(this.action),this.mouseEvents(),this.tool instanceof pa||this.tool instanceof Rl||this.tool instanceof zl?this.tool.mouseMove(this.eventArgs):e&&this.tool instanceof Zv&&this.tool.mouseDown(this.eventArgs),this.updateCursor(),this.renderUmlHighLighter(this.eventArgs);var p=!1;this.hoverElement&&!(this.tool instanceof Zv)&&r instanceof te&&this.isSwimlaneElements(r)&&(0===this.diagram.selectedItems.nodes.length||!_r(this.diagram,this.hoverElement))||this.hoverElement instanceof de||(p=!0),this.hoverElement&&!(this.tool instanceof Zv)&&r instanceof de&&(0===this.diagram.selectedItems.connectors.length||!_r(this.diagram,this.hoverElement))||this.hoverElement instanceof te||(p=!0),this.diagram.updatePortVisibility(this.hoverElement,ci.Hover,p);var g=this.getContent();null===r&&this.hoverElement&&"Auto"===this.hoverElement.tooltip.openOn&&g&&(this.hoverElement=null,this.elementLeave()),s=!1}else{this.eventArgs.position=this.currentPosition,"Drag"===this.action&&!_r(this.diagram,this.eventArgs.source,!1)&&this.eventArgs.source instanceof ei&&this.getMouseEventArgs(this.currentPosition,this.eventArgs),this.mouseEvents(),(t.ctrlKey||t.shiftKey)&&(this.eventArgs.info=t.ctrlKey&&t.shiftKey?{ctrlKey:t.ctrlKey,shiftKey:t.shiftKey}:{ctrlKey:!0}),this.checkAction(r);var y=this.getConnectorPadding(this.eventArgs);this.getMouseEventArgs(this.currentPosition,this.eventArgs,this.eventArgs.source,y),this.updateCursor(),this.inAction=!0,this.initialEventArgs=null,("Drag"===this.action||"Rotate"===this.action)&&(this.diagram.diagramActions=this.diagram.diagramActions|ee.Interactions);var S=this.diagram.scroller.getPageBounds();this.mouseMoveExtend(t,r);var b=this.diagram.scroller.getPageBounds();if(r&&(S.width!==b.width||S.height!==b.height||S.x!==b.x||S.y!==b.y)&&this.diagram.views&&this.diagram.views.overview){var M=this.diagram.views.overview;M.updateView(M)}}this.prevPosition=this.currentPosition,this.isForeignObject(t.target,!0)||t.preventDefault()}}},n.prototype.getContent=function(){var i,t=this.hoverElement instanceof te&&this.hoverElement.constraints&ie.Tooltip||this.hoverElement instanceof de&&this.hoverElement.constraints&qe.Tooltip||(this.hoverElement instanceof Es||this.hoverElement instanceof Tc)&&this.hoverElement.constraints&oi.ToolTip||(this.hoverElement instanceof Kn||this.hoverElement instanceof Or)&&this.hoverElement.constraints&Nr.Tooltip,e=this.hoverElement;e instanceof te&&e.children&&e.children.length>0&&(i=this.findIntersectChild(e));var r=t?this.hoverElement.tooltip.content:this.diagram.tooltip.content;return i?i.tooltip.content:r},n.prototype.findIntersectChild=function(t){for(var e,i=new Ne(this.currentPosition.x,this.currentPosition.y,8,8),r=0;r1&&1===t.which&&!function Gre(n){return!!(n&ee.PreventClearSelection)}(this.diagram.diagramActions)&&(c=!1,this.commandHandler.clearSelection()),(!_r(this.diagram,h)||!c)&&(this.commandHandler.selectObjects([h],void 0,a),this.diagram.selectedItems.canToggleSelection)){var d=this.diagram.selectedItems.nodes;d?d[0].parentObj instanceof Hd&&(s=!0):this.diagram.selectedItems.connectors.length>0&&(s=!0)}}var u=!1,f=this.updateContainerProperties(),p=void 0;if(this.addUmlNode(),this.inAction=!1,this.isMouseDown=!1,this.diagram.selectedObject.helperObject&&(p=this.updateContainerBounds()),this.tool&&(this.tool.prevPosition||this.tool instanceof Q3)){this.eventArgs.position=this.currentPosition;var g=this.getConnectorPadding(this.eventArgs);this.getMouseEventArgs(this.currentPosition,this.eventArgs,this.eventArgs.source,g);var v=this.isMetaKey(t);if((v||t.shiftKey)&&(this.eventArgs.info=v&&t.shiftKey?{ctrlKey:v,shiftKey:t.shiftKey}:{ctrlKey:!0}),this.diagram.diagramActions&ee.Interactions&&(this.diagram.diagramActions=this.diagram.diagramActions&~ee.Interactions),this.eventArgs.clickCount=t.detail,this.diagram.selectedObject.helperObject&&(this.tool instanceof fa||this.tool instanceof Pd)){if(this.diagram.selectedObject.actualObject&&""!==this.diagram.selectedObject.actualObject.parentId){var S=this.diagram.getObject(this.diagram.selectedObject.actualObject.parentId);S&&S.isLane&&(this.commandHandler.isContainer=!0)}(u=this.diagram.lineRoutingModule&&this.diagram.nameTable.helper&&this.eventArgs.target&&this.eventArgs.target.isLane&&(this.eventArgs.source instanceof ei&&this.eventArgs.source.nodes.length>0&&""===this.eventArgs.source.nodes[0].parentId||""===this.eventArgs.source.parentId))&&(this.diagram.diagramActions=this.diagram.diagramActions|ee.PreventLaneContainerUpdate),this.tool.mouseUp(this.eventArgs,f.isPreventHistory)}else{if(this.diagram.selectedItems.canToggleSelection){var b=void 0,M=void 0;if(this.diagram.selectedItems.nodes.length>0)for(var w=0;w1&&D[0].id===i[parseInt(w.toString(),10)].id||r.length>0)&&(M=!0);!this.isSwimlaneSelected&&!s&&!M&&this.tool instanceof fa&&"Select"===this.currentAction&&(!b||this.diagram.selectedItems.connectors.length>0)&&this.commandHandler.clearSelection(!0)}this.isSwimlaneSelected=!1,this.tool.mouseUp(this.eventArgs),this.diagram.checkMenu&&(-1!==window.navigator.userAgent.indexOf("Linux")||-1!==window.navigator.userAgent.indexOf("X11"))&&(!t.pageY&&t instanceof TouchEvent&&t.changedTouches?(window.getSelection().removeAllRanges(),this.diagram.contextMenuModule.contextMenu.open(t.changedTouches[0].pageY,t.changedTouches[0].pageX,this.diagram.element),t.preventDefault()):this.diagram.contextMenuModule.contextMenu.open(t.pageY,t.pageX,this.diagram.element),this.diagram.checkMenu=!1)}f.hasStack&&this.diagram.endGroupAction()}if(p&&this.diagram.endGroupAction(),this.updateContainerBounds(!0),2!==this.eventArgs.clickCount&&(this.commandHandler.updateSelectedNodeProperties(this.eventArgs.source),u)){this.diagram.diagramActions=this.diagram.diagramActions&~ee.PreventLaneContainerUpdate;var A=this.eventArgs.source instanceof ei?this.eventArgs.source.nodes:[this.eventArgs.source];if(A)for(w=0;w0&&!N&&this.diagram.renderSelector(!0),!this.inAction&&!this.diagram.currentSymbol&&this.eventArgs){var T=this.getTargetElement();this.diagram.tool!==ri.ZoomPan&&this.diagram.triggerEvent(Ce.click,{element:T.target instanceof Es?T.target:this.eventArgs.source||this.diagram,position:this.eventArgs.position,count:t.detail,actualObject:this.eventArgs.actualObject,button:0===t.button?"Left":1===t.button?"Middle":"Right"})}this.eventArgs={}}this.diagram.diagramActions=this.diagram.diagramActions&~ee.PreventLaneContainerUpdate,e&&this.updateAnnotation(this.diagram.selectedItems),this.previousElement=null,this.eventArgs={},this.diagram.commandHandler.removeStackHighlighter()},n.prototype.isSwimlaneChild=function(t){if(t.shape&&"SwimLane"!==t.shape.type){var e=this.diagram.nameTable[t.parentId];if(!e)return!1;var i=e.parentId?this.diagram.nameTable[e.parentId]:e;return i&&i.shape&&"SwimLane"===i.shape.type}return!1},n.prototype.updateAnnotation=function(t){var e=t.nodes;if(e.length>0)for(var i=0;i0&&(a+=1),h.isPhase){l="Horizontal"===r.orientation?this.currentPosition.x-e.wrapper.bounds.x:this.currentPosition.y-(e.wrapper.bounds.y+r.header.height);var g={id:Qe(),offset:l,header:{annotation:{content:void 0===h.phases[0].header?"Phase":h.phases[0].header.annotation.content,style:void 0===h.phases[0].header?{}:h.phases[0].header.annotation.style}},style:void 0===h.phases[0]?{}:h.phases[0].style};this.diagram.addPhases(e,[g])}else{var v={id:Qe(),style:h.lanes[0].style,header:{annotation:{content:h.lanes[0].header.annotation.content,style:h.lanes[0].header.annotation.style},style:h.lanes[0].header.style}};if("Horizontal"===h.orientation?v.height=h.lanes[0].height:v.width=h.lanes[0].width,"Horizontal"===r.orientation?(s=i.rowIndex?i.rowIndex:this.diagram.nameTable[i.parentId].rowIndex,i.wrapper.offsetYs)v.header.width=r.lanes[parseInt(s.toString(),10)].header.width,v.header.height=r.lanes[parseInt(s.toString(),10)].header.height;else{var S=void 0;S="Horizontal"===r.orientation?i.rowIndex<3?0:s-a-1:s-1,v.header.width=r.lanes[parseInt(S.toString(),10)].header.width,v.header.height=r.lanes[parseInt(S.toString(),10)].header.height}p&&("height"===p?(v.width=v.height,delete v.height):(v.height=v.width,delete v.width)),this.diagram.addLanes(e,[v],"Horizontal"===r.orientation?s-a:s)}this.commandHandler.select(e)}else if(h.isLane){var b={id:Qe(),width:t.width,height:t.height,addInfo:t.addInfo,shape:{type:"SwimLane",header:{annotation:{content:void 0===h.header?"Header":h.header.annotation.content,style:void 0===h.header?{}:h.header.annotation.style},height:50,style:h.header?h.header.style:h.lanes[0].header.style},phases:[{id:Qe(),header:{annotation:{content:void 0===h.phases||void 0===h.phases[0].header?"Phase":h.phases[0].header.annotation.content,style:void 0===h.phases||void 0===h.phases[0].header?{}:h.phases[0].header.annotation.style},style:void 0===h.phases||void 0===h.phases[0].header?{}:h.phases[0].header.style},style:void 0===h.phases?{}:h.phases[0].style}],lanes:[{id:Qe(),height:t.height,width:t.width,style:h.lanes[0].style,header:{annotation:{content:h.lanes[0].header.annotation.content,style:h.lanes[0].header.annotation.style},style:h.lanes[0].header.style}}],orientation:h.orientation}};"Vertical"===h.orientation&&(b.width+=20),b.offsetX=this.currentPosition.x+b.width/2,b.offsetY=this.currentPosition.y+b.height/2,b.style=t.style,this.diagram.add(b)}},n.prototype.mouseLeave=function(t){this.tool&&this.inAction&&this.tool.mouseLeave(this.eventArgs),this.diagram.selectedObject.helperObject&&(this.updateContainerProperties(),this.updateContainerBounds()&&this.diagram.endGroupAction()),this.eventArgs&&this.eventArgs.source&&(this.diagram.updatePortVisibility(this.eventArgs.source,ci.Hover,!0),this.hoverElement=null),this.eventArgs&&!this.eventArgs.source&&this.hoverElement&&(this.hoverElement=null),this.tool instanceof kd&&this.eventArgs&&this.eventArgs.target&&this.eventArgs.target instanceof te&&(this.diagram.updatePortVisibility(this.eventArgs.target,ci.Hover|ci.Connect,!0),this.hoverElement=null);var i=this.diagram.selectedItems;i&&i.wrapper&&(sm(this.diagram,i)||this.diagram.renderSelector(!0)),(this.diagram.diagramActions&ee.Interactions||this.diagram.diagramActions&ee.ToolAction)&&(this.diagram.diagramActions=this.diagram.diagramActions&~ee.ToolAction),this.isMouseDown=!1,this.focus=!1,this.touchStartList=null,this.touchMoveList=null,this.elementLeave(),this.commandHandler.removeSnap(),this.inAction=!1,this.eventArgs={},this.diagram.selectedObject&&this.diagram.selectedObject.helperObject&&(this.diagram.remove(this.diagram.selectedObject.helperObject),this.diagram.selectedObject={helperObject:void 0,actualObject:void 0}),this.tool=null,function Wne(){var t,e,n=document.getElementsByClassName("e-d-ruler-marker");if(n&&n.length>0)for(e=n.length-1;e>=0;e--)(t=n[parseInt(e.toString(),10)])&&t.parentNode.removeChild(t)}(),"Rotate"===this.action&&this.diagram.diagramCanvas.classList.remove("e-diagram-rotate"),t.preventDefault()},n.prototype.mouseWheel=function(t){this.diagram.blazorActions|=on.interaction;var e={event:t,cancel:!1};if(this.diagram.triggerEvent(Ce.mouseWheel,e),!e.cancel){var i=t.wheelDelta>0||-40*t.detail>0,r=this.getMousePosition(t);if(this.diagram.tooltipObject.close(),this.isMetaKey(t)){var o=this.diagram.scrollSettings.zoomFactor;this.diagram.zoomTo(i?{type:"ZoomIn",zoomFactor:o,focusPoint:r}:{type:"ZoomOut",zoomFactor:o,focusPoint:r}),t.preventDefault()}else{var a=this.diagram.scroller.horizontalOffset,l=this.diagram.scroller.verticalOffset,h=i?10:-10;this.tool&&(this.tool instanceof zl||this.tool instanceof Rl)&&(this.eventArgs={},this.getMouseEventArgs(r,this.eventArgs),this.eventArgs.position=r,this.tool.mouseWheel(this.eventArgs)),this.diagram.scrollActions|=da.Interaction;var c=!0;if(t.isTrusted){var d=!1;(Math.abs(t.deltaY)<100&&-0===Math.abs(t.deltaX)||Math.abs(t.deltaX)<100&&-0===Math.abs(t.deltaY))&&(d=!0);var u=!1;(0!==t.deltaX||0!==t.deltaY)&&(u=navigator.userAgent.includes("Macintosh")),u?Math.abs(t.deltaX)>Math.abs(t.deltaY)?(t.shiftKey||t.deltaX&&-0!==t.deltaX&&(d||!u))&&this.diagram.scroller.zoom(1,h,0,r,c,void 0,d):t.deltaY&&-0!==t.deltaY&&(d||!u)&&this.diagram.scroller.zoom(1,0,h,r,c,void 0,d):t.shiftKey||t.deltaX&&-0!==t.deltaX&&(d||!u)?this.diagram.scroller.zoom(1,h,0,r,c,void 0,d):t.deltaY&&-0!==t.deltaY&&(d||!u)&&this.diagram.scroller.zoom(1,0,h,r,c,void 0,d)}else t.shiftKey||t.deltaX&&-0!==t.deltaX?this.diagram.scroller.zoom(1,h,0,r,c):this.diagram.scroller.zoom(1,0,h,r,c);this.diagram.scrollActions&=~da.Interaction,(a!==this.diagram.scroller.horizontalOffset||l!==this.diagram.scroller.verticalOffset)&&t.preventDefault()}if(this.diagram.textEditing){if(this.diagram.isTriggerEvent=!0,this.diagram.activeLabel.parentId){var p=this.diagram.getObject(this.diagram.activeLabel.parentId);this.diagram.startTextEdit(p,this.diagram.activeLabel.id)}this.diagram.isTriggerEvent=!1}this.diagram.blazorActions=this.diagram.blazorActions&~on.interaction}},n.prototype.keyDown=function(t){if(t.fromMouseEvents&&(t.ctrlKey&&(this.keyArgs.keyModifiers=1),t.shiftKey&&(this.keyArgs.keyModifiers=4),t.shiftKey&&t.ctrlKey&&(this.keyArgs.keyModifiers=5)),!(this.diagram.diagramActions&ee.TextEdit)&&!this.checkEditBoxAsTarget(t)||"Escape"===t.key||27===t.keyCode){var i=void 0,r=t.keyCode?t.keyCode:t.which,s=t.key;("ArrowDown"===s||"ArrowUp"===s||"ArrowLeft"===s||"ArrowRight"===s)&&(this.isNudgeKey=!0);var o=this.isMetaKey(t);if(this.diagram.commandManager&&this.diagram.commands)for(var l=0,h=Object.keys(this.diagram.commands);l4&&(S({keyDownEventArgs:KeyboardEvent,parameter:i.parameter,type:"KEYDOWN"}),this.keyCount=0,this.keyArgs.newValue={offsetX:this.diagram.selectedItems.offsetX,offsetY:this.diagram.selectedItems.offsetY},this.diagram.triggerEvent(Ce.positionChange,this.keyArgs))),this.isKeyUp=!1):S({keyDownEventArgs:KeyboardEvent,parameter:i.parameter})}break}}}}this.keyArgs={element:this.diagram.selectedItems,key:t.key,keyCode:t.keyCode?t.keyCode:t.which},this.getKeyModifier(this.keyArgs,t),this.diagram.diagramActions&ee.TextEdit&&this.getlabel(this.keyArgs,t),this.diagram.triggerEvent(Ce.keyDown,this.keyArgs)},n.prototype.getlabel=function(t,e){var i=this.diagram.activeLabel;t.target=this.diagram.element.id+"_editBox";var r=this.diagram.nameTable[i.parentId];if(document.getElementById(this.diagram.element.id+"_editBox")){t.text=document.getElementById(this.diagram.element.id+"_editBox").value;for(var s=0;s=this.diagram.scroller.viewPortWidth-18?r="right":e.x+this.diagram.scroller.horizontalOffsetthis.diagram.scroller.viewPortHeight-18?r="bottom":e.y+this.diagram.scroller.verticalOffset0&&(s=this.findIntersectChild(this.hoverElement)),"Auto"===this.hoverElement.tooltip.openOn&&""!==r&&bx(this.diagram,s||(i?this.hoverElement:void 0)),this.hoverElement.tooltip.content&&("Mouse"===this.hoverElement.tooltip.relativeMode?this.setTooltipOffset(t):(this.diagram.tooltipObject.offsetX=0,this.diagram.tooltipObject.offsetY=0));var o=this.diagram.findObjectsUnderMouse(this.currentPosition),a=this.diagram.findObjectUnderMouse(o,this.action,this.inAction);if(null!==a){var l=void 0;this.hoverElement.tooltip.isSticky&&(this.diagram.tooltipObject.isSticky=!0),a instanceof te&&a.children&&a.children.length>0&&(a=s||a),l=a.ports&&(this.hoverElement instanceof Es||this.hoverElement instanceof Tc)||a.annotations&&(this.hoverElement instanceof Kn||this.hoverElement instanceof Or)?document.getElementById(a.id+"_"+this.hoverElement.id):document.getElementById(a.id+(a.shape&&a.shape instanceof om?"_content_native_element":"_groupElement")),"Auto"===this.hoverElement.tooltip.openOn&&""!==r&&(this.diagram.tooltipObject.close(),this.diagram.tooltipObject.openOn=this.hoverElement.tooltip.openOn,this.diagram.tooltipObject.dataBind()),function _re(n,t){var e=0;return n instanceof de?n.constraints&qe.Tooltip?e=n.constraints&qe.Tooltip:n.constraints&qe.InheritTooltip&&(e=t.constraints&nt.Tooltip):n instanceof Es||n instanceof Tc?n.constraints&oi.ToolTip?e=n.constraints&oi.ToolTip:n.constraints&oi.InheritTooltip&&(e=t.constraints&nt.Tooltip):n instanceof Kn||n instanceof Or?n.constraints&Nr.Tooltip&&(e=n.constraints&Nr.Tooltip):n.constraints&ie.Tooltip?e=n.constraints&ie.Tooltip:n.constraints&ie.InheritTooltip&&(e=t.constraints&nt.Tooltip),e}(this.hoverElement,this.diagram)&&"Auto"===this.hoverElement.tooltip.openOn&&(this.diagram.tooltipObject.target=this.hoverElement.id,this.diagram.tooltipObject.open("Mouse"===this.hoverElement.tooltip.relativeMode?this.diagram.element:l))}}},n.prototype.elementLeave=function(){this.diagram.tooltipObject&&!this.diagram.tooltipObject.isSticky&&"Custom"!==this.diagram.tooltipObject.openOn&&this.diagram.tooltipObject.close()},n.prototype.setTooltipOffset=function(t){var e=function hse(n,t,e,i){var o="Mouse"===(!(e instanceof te?e.constraints&ie.InheritTooltip:e instanceof de?e.constraints&qe.InheritTooltip:e.constraints&oi.InheritTooltip)&&(e instanceof te?e.constraints&ie.Tooltip:e instanceof de?e.constraints&qe.Tooltip:e.constraints&oi.ToolTip)?e.tooltip.relativeMode:n.tooltip.relativeMode);"Mouse"===i?o=!0:"Object"===i&&(o=!1);var a=function cse(n,t,e,i){var o,r={},s=document.getElementById(e.element.id);if(n instanceof te||n instanceof de)o=n.wrapper.bounds;else{var a=e.findObjectsUnderMouse(t),l=e.findObjectUnderMouse(a,"Select",!1);o=e.findElementUnderMouse(l,t,e).bounds}var c=s.getBoundingClientRect();switch(e.tooltipObject.position){case"BottomCenter":r=zc(t,o.bottomCenter,e,i,c.width/2,c.height);break;case"BottomLeft":case"LeftBottom":r=zc(t,o.bottomLeft,e,i,0,c.height);break;case"BottomRight":case"RightBottom":r=zc(t,o.bottomRight,e,i,c.width,c.height);break;case"LeftCenter":r=zc(t,o.middleLeft,e,i,0,c.height/2);break;case"LeftTop":case"TopLeft":r=zc(t,o.topLeft,e,i,0,0);break;case"RightCenter":r=zc(t,o.middleRight,e,i,c.width,c.height/2);break;case"RightTop":case"TopRight":r=zc(t,o.topRight,e,i,c.width,0);break;case"TopCenter":r=zc(t,o.topCenter,e,i,c.width/2,0)}return r}(e,t,n,o),l=Za(n);return{x:a.x+l.width,y:a.y+l.height}}(this.diagram,t,this.hoverElement);this.diagram.tooltipObject.offsetX=e.x,this.diagram.tooltipObject.offsetY=e.y},n.prototype.altKeyPressed=function(t){return!!(t&ft.Alt)},n.prototype.ctrlKeyPressed=function(t){return!!(t&ft.Control)},n.prototype.shiftKeyPressed=function(t){return!!(t&ft.Shift)},n.prototype.scrolled=function(t){this.diagram.updateScrollOffset()},n.prototype.isMobileOrIPadDevice=function(){var t=navigator.userAgent||navigator.vendor||window.opera;return/iPhone|iPad|iPod/.test(t)&&!window.MSStream?"iOS":/android/i.test(t)?"Android":/Mobile|Tablet/.test(t)?"Mobile":"Desktop"},n.prototype.doubleClick=function(t){if(_v(this.diagram)){var e=this.isMobileOrIPadDevice(),i=this.diagram.tool;"Desktop"!==e&&this.tool&&(this.tool instanceof zl||this.tool instanceof Rl)&&(this.diagram.tool=0);var r=void 0,s=this.diagram.findObjectsUnderMouse(this.currentPosition),o=this.diagram.findObjectUnderMouse(s,this.action,this.inAction);if(null!==o&&_v(this.diagram))if(r=this.diagram.findElementUnderMouse(o,this.currentPosition,this.diagram),this.tool&&(this.tool instanceof zl||this.tool instanceof Rl))this.diagram.tool=i,this.tool.mouseUp(this.eventArgs),this.isMouseDown=!1,this.eventArgs={},this.tool=null,t.preventDefault();else{var l=this.diagram.commandHandler.getObjectLayer(o.id);!l||l.lock||!l.visible||this.diagram.diagramActions&ee.TextEdit||this.diagram.startTextEdit(o,r instanceof ai?r.id.split(o.id+"_")[1]:void 0)}this.diagram.triggerEvent(Ce.doubleClick,{source:o||this.diagram,position:this.currentPosition,count:t.detail})}},n.prototype.itemClick=function(t,e){var i=t;return Dn(this.diagram,i,!0)?i:null},n.prototype.inputChange=function(t){var i,s,o,a,l,h,c,d,u,f=document.getElementById(this.diagram.element.id+"_editBox"),p=document.getElementById(this.diagram.element.id+"_editTextBoxDiv"),g=f.value,v=g.split("\n");(!(a=this.diagram.selectedItems.nodes[0]?this.diagram.selectedItems.nodes[0]:this.diagram.selectedItems.connectors[0])&&this.tool instanceof VI||a&&"SwimLane"===a.shape.type)&&(a=this.diagram.nameTable[this.diagram.activeLabel.parentId]),a&&("Text"!==a.shape.type&&a.annotations.length>0||"Text"===a.shape.type)&&(c=AF((o=this.diagram.getWrapper(a.wrapper,this.diagram.activeLabel.id)).style,g,void 0,void 0,i=(i=a.wrapper.bounds.width90?i:90),s=Number(f.style.fontSize.split("px")[0]),v.length>1&&""===v[v.length-1]&&(c.height=c.height+s),d=this.diagram.scroller.transform,u=D3(this.diagram)?d.scale:1,l=(12>c.height?12:c.height)*u,p.style.left=(o.bounds.center.x+d.tx)*d.scale-(h=(90>(h=c.width)?90:h)*u)/2-2.5+"px",p.style.top=(o.bounds.center.y+d.ty)*d.scale-l/2-3+"px",p.style.width=h+"px",p.style.height=l+"px",f.style.minHeight="12px",f.style.minWidth="90px",f.style.width=h+"px",f.style.height=l+"px")},n.prototype.isAddTextNode=function(t,e){return!(!(this.tool instanceof VI||e)||(this.tool=null,t&&!kI(this.diagram)&&(this.diagram.drawingObject=void 0,this.diagram.currentDrawingObject=void 0),pF(this.diagram.nodes,t.id)||pF(this.diagram.connectors,t.id)))},n.prototype.checkEditBoxAsTarget=function(t){return!(!t.target||t.target.id!==this.diagram.element.id+"_editBox")},n.prototype.getMouseEventArgs=function(t,e,i,r){var s,o,a;if(e.position=t,i?(o=this.diagram.findObjectsUnderMouse(this.currentPosition,i),s=this.diagram.findTargetObjectUnderMouse(o,this.action,this.inAction,e.position,i)):"Drag"===this.action||"ConnectorSourceEnd"===this.action||"SegmentEnd"===this.action||"OrthoThumb"===this.action||"BezierSourceThumb"===this.action||"BezierTargetThumb"===this.action||"ConnectorTargetEnd"===this.action||-1!==this.action.indexOf("Rotate")||-1!==this.action.indexOf("Resize")?(s=this.diagram.selectedItems,!this.diagram.currentSymbol&&"Drag"===this.action&&s&&this.diagram.selectedItems.nodes.length>0&&"SwimLane"===this.diagram.selectedItems.nodes[0].shape.type&&(o=this.diagram.findObjectsUnderMouse(this.currentPosition),s=this.diagram.findObjectUnderMouse(o,this.action,this.inAction))):(o=this.diagram.findObjectsUnderMouse(this.currentPosition),s=this.diagram.findObjectUnderMouse(o,this.action,this.inAction)),s&&s.isHeader&&(this.eventArgs.actualObject=s=this.diagram.nameTable[s.parentId]),s){var l=void 0,h=void 0,c=void 0;if(((a=this.diagram.findElementUnderMouse(s,this.currentPosition,this.diagram,r))&&s.ports&&s.ports.length&&!tb(s,a)||!a||!s)&&o&&o.length&&i instanceof ei)for(l=i.connectors[0],c=o.length-1;c>=0;c--)if(((h=o[parseInt(c.toString(),10)])instanceof te||h instanceof de)&&l&&l.connectionPadding){if(a=this.diagram.findElementUnderMouse(s=h,this.currentPosition,this.diagram,r),l.constraints&qe.ConnectToNearByPort&&s&&s.ports&&s.ports.length&&tb(s,a))break;if((h instanceof te||h instanceof de)&&l&&l.connectionPadding&&h.wrapper.outerBounds.containsPoint(this.currentPosition)&&l.constraints&qe.ConnectToNearByNode&&!(l.constraints&qe.ConnectToNearByPort)){a=this.diagram.findElementUnderMouse(s=h,this.currentPosition,this.diagram,0);break}}}return i?(e.target=s,e.targetWrapper=a):(e.source=s,e.sourceWrapper=a),e.actualObject=this.eventArgs.actualObject,e.source instanceof ei&&void 0===e.actualObject&&(e.source.nodes.length>0||e.source.connectors.length>0)&&(e.actualObject=e.source.nodes.length>0?this.diagram.nameTable[e.source.nodes[0].id]:this.diagram.nameTable[e.source.connectors[0].id]),e.startTouches=this.touchStartList,e.moveTouches=this.touchMoveList,e},n.prototype.resetTool=function(){this.action="Select",this.hoverElement=null,this.hoverNode=null,this.tool=this.diagram.getTool(this.action),this.updateCursor()},n.prototype.updateTool=function(){this.action=this.currentPosition&&"Pan"!==this.action?"Pan":"Select"},n.prototype.getTool=function(t){switch(t){case"Select":return new $v(this.commandHandler,!0);case"Drag":return new fa(this.commandHandler);case"Rotate":return new Wx(this.commandHandler);case"LayoutAnimation":return new Tne(this.commandHandler);case"FixedUserHandle":return new xne(this.commandHandler,!0);case"Hyperlink":return new Q3(this.commandHandler);case"ResizeSouthEast":case"ResizeSouthWest":case"ResizeNorthEast":case"ResizeNorthWest":case"ResizeSouth":case"ResizeNorth":case"ResizeWest":case"ResizeEast":return new Pd(this.commandHandler,t);case"ConnectorSourceEnd":case"ConnectorTargetEnd":case"BezierSourceThumb":case"BezierTargetThumb":return new kd(this.commandHandler,t);case"SegmentEnd":case"OrthoThumb":return new qF(this.commandHandler,t);case"Draw":var e="shape",i=function ise(n){var t;return n&&(n.type?t="Connector":n.shape&&!n.type&&(t="Node")),t}(this.diagram.drawingObject);if("Node"===i&&"Text"===this.diagram.drawingObject.shape.type)return new VI(this.commandHandler);if("Connector"===i&&"Freehand"===this.diagram.drawingObject.type)return new One(this.commandHandler);if("Node"===i&&"Polygon"===this.diagram.drawingObject.shape[""+e]&&!this.diagram.drawingObject.shape.points)return new zl(this.commandHandler);if("Node"===i||"Node"===i&&"Polygon"===this.diagram.drawingObject.shape[""+e]&&this.diagram.drawingObject.shape.points)return new jI(this.commandHandler,this.diagram.drawingObject);if("Connector"===i&&"Polyline"===this.diagram.drawingObject.type)return new Rl(this.commandHandler);if("Connector"===i)return new pa(this.commandHandler,"ConnectorSourceEnd",this.diagram.drawingObject);break;case"Pan":return new Zv(this.commandHandler,!1);case"PinchZoom":return new Zv(this.commandHandler,!0);case"PortDrag":return new fa(this.commandHandler,"Port");case"PortDraw":return new pa(this.commandHandler,"ConnectorSourceEnd",this.diagram.drawingObject);case"LabelSelect":return new $v(this.commandHandler,!0,"LabelSelect");case"LabelDrag":return new Ane(this.commandHandler);case"LabelResizeSouthEast":case"LabelResizeSouthWest":case"LabelResizeNorthEast":case"LabelResizeNorthWest":case"LabelResizeSouth":case"LabelResizeNorth":case"LabelResizeWest":case"LabelResizeEast":return new Lne(this.commandHandler,t);case"LabelRotate":return new Nne(this.commandHandler)}return null},n.prototype.getCursor=function(t){var e=this.diagram.selectedItems.annotation?this.diagram.selectedItems.wrapper.children[0]:this.diagram.selectedItems;return function Dne(n,t){if(t+=360,t%=360,-1===n.indexOf("Resize"))return Vx[""+n];var e=Vx[""+n];return t>=0&&t<25||t>=160&&t<=205||t>=340&&t<=360?e:t>=25&&t<=70||t>=205&&t<=250?"n-resize"===e||"s-resize"===e?"ne-resize":"nw-resize"===e||"se-resize"===e?"n-resize":"e-resize"===e||"w-resize"===e?"nw-resize":"e-resize":t>=70&&t<=115||t>=250&&t<=295?"n-resize"===e||"s-resize"===e?"e-resize":"nw-resize"===e||"se-resize"===e?"ne-resize":"e-resize"===e||"w-resize"===e?"n-resize":"nw-resize":t>=115&&t<=155||t>=295&&t<=340?"n-resize"===e||"s-resize"===e?"nw-resize":"nw-resize"===e||"se-resize"===e?"e-resize":"e-resize"===e||"w-resize"===e?"ne-resize":Vx[""+n]:"n-resize"}(t,this.diagram.selectedItems.annotation?e.rotateAngle+e.parentTransform:e.rotateAngle)},n.prototype.findElementUnderMouse=function(t,e,i,r){return this.objectFinder.findElementUnderSelectedItem(t,e,i,r)},n.prototype.findObjectsUnderMouse=function(t,e){return this.objectFinder.findObjectsUnderMouse(t,this.diagram,this.eventArgs,e)},n.prototype.findObjectUnderMouse=function(t,e,i){return this.objectFinder.findObjectUnderMouse(this.diagram,t,e,i,this.eventArgs,this.currentPosition)},n.prototype.findTargetUnderMouse=function(t,e,i,r,s){return this.objectFinder.findObjectUnderMouse(this.diagram,t,e,i,this.eventArgs,r,s)},n.prototype.findActionToBeDone=function(t,e,i,r){return function Ine(n,t,e,i,r,s,o){if(s&&s.length>1&&r&&r.length>1)return"PinchZoom";if(i.currentSymbol)return"Drag";if("PortDraw"===i.eventHandler.action&&(i.tool&=~ri.DrawOnce),(E3(i)||kI(i))&&i.drawingObject)return"Draw";if($a(i)&&(l=i.selectedItems).wrapper&&qr(l.constraints,"UserHandle"))for(var h=0,c=l.userHandles;h=50&&(l.x=(a.points[parseInt(h.toString(),10)].x+a.points[h+1].x)/2,l.y=(a.points[parseInt(h.toString(),10)].y+a.points[h+1].y)/2,wr(e,l,n.hitPadding?n.hitPadding:10)))return"OrthoThumb"}else AI(n)&&console.warn('[WARNING] :: Module "ConnectorEditing" is not available in Diagram component! You either misspelled the module name or forgot to load it.');return null}(g,l,e,i);if("OrthoThumb"===S)return S;if(qr(l.constraints,"ConnectorSourceThumb")&&xI(g)&&S||qr(l.constraints,"ConnectorTargetThumb")&&TI(g)&&S)return S}}else{var b=i.selectedItems.handleSize/2/i.scroller.currentZoom,M=10/i.scroller.currentZoom,w=Bi();qi(w,f.rotateAngle+f.parentTransform,f.offsetX,f.offsetY);var C=f.offsetX-f.pivot.x*f.actualSize.width,D=f.offsetY-f.pivot.y*f.actualSize.height,A={x:C+(.5===f.pivot.x?2*f.pivot.x:f.pivot.x)*f.actualSize.width/2,y:D-30/i.scroller.currentZoom};A=Ke(w,A);var x=!!i.selectedItems.annotation,P=!(!x||!LI(i.selectedItems.annotation));if(qr(l.constraints,"Rotate")&&wr(e,A,M)&&i.selectedItems.thumbsConstraints&bt.Rotate){if(x&&P)return"LabelRotate";if(!x)return"Rotate"}if(u.Inflate(b),u.containsPoint(e)&&(S=function bne(n,t,e,i,r,s){var o;return 1===n.selectedItems.nodes.length&&0===n.selectedItems.connectors.length&&n.selectedItems.nodes[0].container&&(o=function Cne(n,t,e,i,r){var s=10/n.scroller.currentZoom,o=n.selectedItems,a=t.actualSize.width,l=t.actualSize.height,h=new Ne(i,r,t.style.strokeWidth,l),c=new Ne(i+a,r,t.style.strokeWidth,l),d=new Ne(i,r,a,t.style.strokeWidth),u=new Ne(i,r+l,a,t.style.strokeWidth),f=Dn(n,n.selectedItems.nodes[0],!0)?n.nameTable[n.selectedItems.nodes[0].parentId]:n.selectedItems.nodes[0];if(ga(o.constraints,"ResizeEast",o.thumbsConstraints,o)&&c.containsPoint(e,s))return"ResizeEast";if(ga(o.constraints,"ResizeSouth",o.thumbsConstraints,o)&&u.containsPoint(e,s))return"ResizeSouth";if("Grid"!==f.container.type){if(ga(o.constraints,"ResizeWest",o.thumbsConstraints,o)&&h.containsPoint(e,s))return"ResizeWest";if(ga(o.constraints,"ResizeNorth",o.thumbsConstraints,o)&&d.containsPoint(e,s))return"ResizeNorth"}return null}(n,t,e,r,s)),!o&&(!n.selectedItems.nodes[0]||!n.selectedItems.nodes[0].isPhase&&!n.selectedItems.nodes[0].isLane&&"SwimLane"!==n.selectedItems.nodes[0].shape.type)&&(o=function Ene(n,t,e,i,r,s){var o=40/n.scroller.currentZoom,a=n.selectedItems.handleSize/2/n.scroller.currentZoom,l=n.selectedItems,h=!!l.annotation;if(t.actualSize.width>=o&&t.actualSize.height>=o){if(ga(l.constraints,"ResizeSouthEast",l.thumbsConstraints,l)&&wr(e,Ke(i,{x:r+t.actualSize.width,y:s+t.actualSize.height}),a))return h?"LabelResizeSouthEast":"ResizeSouthEast";if(ga(l.constraints,"ResizeSouthWest",l.thumbsConstraints,l)&&wr(e,Ke(i,{x:r,y:s+t.actualSize.height}),a))return h?"LabelResizeSouthWest":"ResizeSouthWest";if(ga(l.constraints,"ResizeNorthEast",l.thumbsConstraints,l)&&wr(e,Ke(i,{x:r+t.actualSize.width,y:s}),a))return h?"LabelResizeNorthEast":"ResizeNorthEast";if(ga(l.constraints,"ResizeNorthWest",l.thumbsConstraints,l)&&wr(e,Ke(i,{x:r,y:s}),a))return h?"LabelResizeNorthWest":"ResizeNorthWest"}return ga(l.constraints,"ResizeEast",l.thumbsConstraints,l)&&wr(e,Ke(i,{x:r+t.actualSize.width,y:s+t.actualSize.height/2}),a)?h?"LabelResizeEast":"ResizeEast":ga(l.constraints,"ResizeWest",l.thumbsConstraints,l)&&wr(e,Ke(i,{x:r,y:s+t.actualSize.height/2}),a)?h?"LabelResizeWest":"ResizeWest":ga(l.constraints,"ResizeSouth",l.thumbsConstraints,l)&&wr(e,Ke(i,{x:r+t.actualSize.width/2,y:s+t.actualSize.height}),a)?h?"LabelResizeSouth":"ResizeSouth":ga(l.constraints,"ResizeNorth",l.thumbsConstraints,l)&&wr(e,Ke(i,{x:r+t.actualSize.width/2,y:s}),a)?h?"LabelResizeNorth":"ResizeNorth":null}(n,t,e,i,r,s)),o||null}(i,f,e,w,C,D),S))return S}}if(Lc(i)&&!n)return"Pan";if((o instanceof Es||o instanceof Tc)&&(!Lc(i)||Bv(i)||Fv(i))&&(S=function wne(n,t,e,i){if(Rx(t)&&(va(t,ci.Hover)||va(t,ci.Visible))){if(t.constraints&oi.Drag)return"PortDrag"}else if(zx(t)&&(va(t,ci.Hover)||va(t,ci.Visible))&&t.constraints&oi.Draw){n.drawingObject={};var r={type:"Orthogonal",sourcePortID:t.id};return n.drawingObject=r,n.tool|=ri.DrawOnce,n.currentDrawingObject=r,"PortDraw"}return"None"}(i,o),"None"!==S))return S;if((o instanceof Kn||o instanceof Or)&&!Lc(i)&&xd(o))return _r(i,o,void 0,t)&&ro(o)?"LabelDrag":"LabelSelect";if(null!==n){if(!(n instanceof te||n instanceof de))return"Select";if(t&&t.id){var L=t.id.split(n.id)[1];if(L&&L.match("^_icon"))return"LayoutAnimation"}if(t&&t.id)for(var O=void 0,N=0;N-1)return"FixedUserHandle";if(t instanceof ai&&t.hyperlink.link)return"Hyperlink";if(!ro(n)||!_r(i,n,!1)||void 0!==i.selectedItems.annotation)return n&&Lc(i)&&!PI(i)?"Pan":i.selectedItems.nodes.length&&i.selectedItems.nodes[0].isLane&&i.selectedItems.wrapper&&i.selectedItems.wrapper.bounds.containsPoint(e)?"Drag":"Select";if(n instanceof de&&!wr(e,n.sourcePoint,n.hitPadding)&&!wr(e,n.targetPoint,n.hitPadding)||!(n instanceof de))return"Drag"}return"Select"}(t,e,this.currentPosition,this.diagram,this.touchStartList,this.touchMoveList,r)},n.prototype.updateContainerBounds=function(t){var e=!1;if(this.diagram.selectedObject.helperObject&&this.diagram.selectedObject.actualObject)for(var i=this.diagram.selectedObject.actualObject,r=this.diagram.selectedObject.actualObject instanceof ei?i.nodes:[i],s=0;si.y&&(h+=u>0?-1:1,u+=u>0?-1:1):i&&e.wrapper.offsetYi.x&&(h+=u>0?-1:1,u+=u>0?-1:1):i&&e.wrapper.offsetX1)for(var S=t.offsetX-this.diagram.selectedItems.offsetX,b=t.offsetY-this.diagram.selectedItems.offsetY,M=t.rotateAngle-this.diagram.selectedItems.rotateAngle,w=0;w-1){var A=c.children;A.splice(A.indexOf(o.id),1),this.diagram.nameTable[o.id].parentId="",i=!0,c.wrapper.children.splice(D,1)}}if(function Sne(n,t,e,i){var r=n,s=e.nameTable[r.parentId],o=e.nameTable[r.parentId];if(t&&o&&o.container&&"Stack"===o.container.type&&t.container&&"Stack"===t.container.type&&o.id!==t.parentId){var a=o.wrapper.children.indexOf(r.wrapper);a>-1&&(e.nameTable[r.id].parentId=t.id,o.wrapper.children.splice(a,1))}if(t&&t.parentId&&r.parentId&&"Drag"===i&&o.container&&"Stack"===o.container.type){var l=s.wrapper.children.indexOf(t.wrapper),h=s.wrapper.children.indexOf(r.wrapper),c={targetIndex:l,target:t,sourceIndex:h,source:n};s.wrapper.children.splice(h,1),s.wrapper.children.splice(l,0,r.wrapper),e.commandHandler.addHistoryEntry({type:"StackChildPositionChanged",redoObject:{targetIndex:h,target:t,sourceIndex:l,source:n},undoObject:c,category:"Internal"})}}(o,h,this.diagram,this.action),(c=Dn(this.diagram,o)?this.diagram.nameTable[o.parentId]:this.diagram.nameTable[o.parentId]||o)&&c.container&&"Canvas"===c.container.type&&(c.wrapper.maxWidth=c.maxWidth=c.wrapper.actualSize.width,c.wrapper.maxHeight=c.maxHeight=c.wrapper.actualSize.height,e=!0),Dn(this.diagram,o,!0)&&c&&"Canvas"===c.container.type)if(this.diagram.selectedItems.nodes.length>1)for(w=0;w0)for(var i=0;i0&&e.columnIndex>0||l&&e.isLane)){if("Horizontal"===t.container.orientation&&e.isPhase&&e.wrapper.width>e.maxWidth&&(e.maxWidth=e.wrapper.width,e.wrapper.maxWidth=e.wrapper.width),h.updateColumnWidth(e.columnIndex,r.width,!0,c),Fx(this.diagram,e,t),e.isPhase){var p=this.diagram.nameTable[""+t.shape.phases[e.columnIndex].header.id];p.maxWidth0?(r=new rp(t,"",u),t.shape.classShape.attributes.push(r)):i.id.includes("_umlMethods")&&t.shape.classShape.methods.length>0&&(s=new lm(t,"",u),t.shape.classShape.methods.push(s))),"Interface"===t.shape.classifier&&(i.id.includes("_umlProperty")&&t.shape.interfaceShape.attributes.length>0?(r=new rp(t,"",u),t.shape.classShape.attributes.push(r)):i.id.includes("_umlMethods")&&t.shape.interfaceShape.methods.length>0&&(s=new lm(t,"",u),t.shape.interfaceShape.methods.push(s))),"Enumeration"===t.shape.classifier&&i.id.includes("_umlMember")&&t.shape.enumerationShape.members.length>0){var f=new nb(t,"",u);t.shape.enumerationShape.members.push(f)}t.wrapper.children.indexOf(c.wrapper),this.diagram.enableServerDataBinding(!0),this.diagram.add(c),this.diagram.updateConnectorEdges(t),this.diagram.clearSelection(),this.diagram.select([this.diagram.nameTable[c.id]]),this.diagram.endGroupAction(),this.diagram.startTextEdit()}}},n}(),Boe=function(){function n(){}return n.prototype.findObjectsUnderMouse=function(t,e,i,r,s){var o=[];r&&r instanceof ei&&r.nodes.length+r.connectors.length===1&&(r=r.nodes[0]||r.connectors[0]).children&&0===r.children.length&&(i.actualObject=r);for(var a,l,h,c,p,d=r&&r instanceof de&&(r.constraints&qe.ConnectToNearByNode||r.constraints&qe.ConnectToNearByPort)&&r.connectionPadding||0,f={},g=0,v=e.spatialSearch.findObjects(new Ne(t.x-50-d,t.y-50-d,100+d,100+d));g-1&&o.splice(T,1),"UmlClassifier"===y.shape.type&&y.container&&"Stack"===y.container.type&&(T=o.indexOf(e.nameTable[e.nameTable[y.id].wrapper.children[0].id]))>-1&&o.splice(T,1)}for(var z=0;zs.zIndex&&(t[parseInt(r.toString(),10)]=l),r>0&&i&&a&&(a.isLane||a.isPhase||a.isHeader)&&t[parseInt(r.toString(),10)].zIndex=2)for(var d=t.length-1;d>=0;d--)if(t[parseInt(d.toString(),10)].parentId){var u=nm(t[parseInt(d.toString(),10)],e,""),f=nm(t[d-1],e,""),g=e.nameTable[""+f];g&&u!==f&&e.nameTable[""+u].zIndex=0;p--){d=Kf(e[parseInt(p.toString(),10)],!1),c=Kf(e[parseInt(p.toString(),10)],!0);var g=t[""+l].tool,v=this.findTargetElement(e[parseInt(p.toString(),10)].wrapper,o,t,void 0);if("Draw"===i&&v&&(e[parseInt(p.toString(),10)]instanceof te||e[parseInt(p.toString(),10)]instanceof de)&&!tb(e[parseInt(p.toString(),10)],v)&&(g&&"ConnectorSourceEnd"===g[""+h]&&!Ph(e[parseInt(p.toString(),10)])||g&&"ConnectorTargetEnd"===g[""+h]&&!ua(e[parseInt(p.toString(),10)])))return u;if(e[parseInt(p.toString(),10)]instanceof te||e[parseInt(p.toString(),10)]instanceof de&&(Ph(e[parseInt(p.toString(),10)])||Td(d)||ua(e[parseInt(p.toString(),10)])||kh(c)||"PortDraw"===i&&g instanceof kd&&"ConnectorTargetEnd"===g[""+h]&&(ua(e[parseInt(p.toString(),10)])||kh(c))))return u=e[parseInt(p.toString(),10)],f&&(u=this.isTarget(u,t,i)),s.actualObject=u,u}else if("ConnectorTargetEnd"===i&&a){for(p=e.length-1;p>=0;p--)if(c=Kf(e[parseInt(p.toString(),10)],!0),(e[parseInt(p.toString(),10)]instanceof te||e[parseInt(p.toString(),10)]instanceof de)&&(ua(e[parseInt(p.toString(),10)])||kh(c)))return u=e[parseInt(p.toString(),10)],u=this.isTarget(u,t,i),s.actualObject=u,u}else{if(a&&("Drag"===i||t[""+l].tool instanceof fa)){var y=0;for(p=0;p=S.zIndex?u:S,y=Math.max(y,S.zIndex)):y=(u=S).zIndex)}return u&&"Bpmn"===u.shape.type&&(t.selectedItems.nodes.length>0&&"Bpmn"===t.selectedItems.nodes[0].shape.type||(u=null)),u&&(s.actualObject=u),u}if("Select"!==i&&"Pan"!==i||!t[""+l].tool)if("Pan"===i||"LayoutAnimation"===i){for(p=e.length-1;p>=0;p--)if((e[parseInt(p.toString(),10)]instanceof te||e[parseInt(p.toString(),10)]instanceof de)&&(v=this.findTargetElement(e[parseInt(p.toString(),10)].wrapper,o,t,void 0),"Pan"===i||v&&(v.id.match("_icon_content_shape$")||v.id.match("_icon_content_rect$"))))return e[parseInt(p.toString(),10)]}else u=e[e.length-1],s&&u&&(s.actualObject=u);else{for(p=e.length-1;p>=0;p--)if(e[parseInt(p.toString(),10)]instanceof de){var b=e[p-1];if(e[p-1]instanceof te&&b.ports){if((v=this.findTargetElement(b.wrapper,o,t,void 0))&&(v.id.match("_icon_content_shape$")||v.id.match("_icon_content_rect$")))return b;for(var M=0;M=0;s--){var o=t.children[parseInt(s.toString(),10)];if(o&&o.outerBounds.containsPoint(e,r||0))if(o.visible){if(o instanceof Cs){var a=this.findTargetElement(o,e,i);if(a)return a}var l="Clip"===o.style.textOverflow||"Ellipsis"===o.style.textOverflow;if(o.bounds.containsPoint(e,r||0)&&!l)return o;if(t.bounds.containsPoint(e,r||0)&&l)return o}else if(o instanceof Ze&&t&&t.id){var h=void 0;if(t.id.includes("group_container")){var c=t.id.slice(0,-15);h=i.getObject(c)}else h=i.getObject(t.id);if(KI(h,o.id))return o}}return t.bounds.containsPoint(e,r)&&"none"!==t.style.fill?t:null},n}(),Foe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),sp=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},$F=function(n){function t(e,i,r,s){var o=n.call(this,e,i,r,s)||this;return o.objectZIndex=-1,o.zIndexTable={},o.objects=[],o}return Foe(t,n),sp([I("")],t.prototype,"id",void 0),sp([I(!0)],t.prototype,"visible",void 0),sp([I(!1)],t.prototype,"lock",void 0),sp([I()],t.prototype,"objects",void 0),sp([I()],t.prototype,"addInfo",void 0),sp([I(-1)],t.prototype,"zIndex",void 0),t}(Ee),bT=function(n,t,e,i){return new(e||(e=Promise))(function(r,s){function o(h){try{l(i.next(h))}catch(c){s(c)}}function a(h){try{l(i.throw(h))}catch(c){s(c)}}function l(h){h.done?r(h.value):new e(function(c){c(h.value)}).then(o,a)}l((i=i.apply(n,t||[])).next())})},MT=function(n,t){var i,r,s,o,e={label:0,sent:function(){if(1&s[0])throw s[1];return s[1]},trys:[],ops:[]};return o={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function a(h){return function(c){return function l(h){if(i)throw new TypeError("Generator is already executing.");for(;e;)try{if(i=1,r&&(s=2&h[0]?r.return:h[0]?r.throw||((s=r.return)&&s.call(r),0):r.next)&&!(s=s.call(r,h[1])).done)return s;switch(r=0,s&&(h=[2&h[0],s.value]),h[0]){case 0:case 1:s=h;break;case 4:return e.label++,{value:h[1],done:!1};case 5:e.label++,r=h[1],h=[0];continue;case 7:h=e.ops.pop(),e.trys.pop();continue;default:if(!(s=(s=e.trys).length>0&&s[s.length-1])&&(6===h[0]||2===h[0])){e=0;continue}if(3===h[0]&&(!s||h[1]>s[0]&&h[1]1)for(var i=0;i-1)return e[parseInt(i.toString(),10)];return this.diagram.activeLayer},n.prototype.getLayer=function(t){for(var e=this.diagram.layers,i=0;i=0;o--)this.diagram.unSelect(this.diagram.nameTable[s[parseInt(o.toString(),10)]]),this.diagram.remove(this.diagram.nameTable[s[parseInt(o.toString(),10)]]),"default_layer"!==i.id&&this.diagram.activeLayer.id===t&&(this.diagram.activeLayer=this.diagram.layers[this.diagram.layers.length-1]);delete this.diagram.layerZIndexTable[i.zIndex],this.diagram.layers.splice(r,1),"SVG"!==this.diagram.mode&&this.diagram.refreshDiagramLayer()}},n.prototype.moveObjects=function(t,e){this.diagram.startGroupAction();for(var i={},r=[],s=0;s-1){if(r=[],(h=this.diagram.nameTable[""+s]).children)for(var p=0,g=h.children;p0){for(var y=void 0,S=0,b=r;S0)for(var r=0;r0)for(r=0;r0){t=t.concat(this.diagram.selectedItems.connectors);for(var i=0;i0)for(t=t.concat(this.diagram.selectedItems.nodes),i=0;i0){for(var i=0,r=t.shape.activity.subProcess.processes;i0&&this.copyProcesses(this.processTable[""+s])}this.clipboardData.processTable=this.processTable}},n.prototype.group=function(){this.oldSelectedObjects=im(this.diagram);var e=this.diagram.isProtectedOnChange;this.diagram.protectPropertyChange(!0),this.diagram.diagramActions=this.diagram.diagramActions|ee.Group;var r={};r.id="group"+Qe(),(r=new te(this.diagram,"nodes",r,!0)).children=[];for(var s=this.diagram.selectedItems.nodes.concat(this.diagram.selectedItems.connectors).sort(function(h,c){return h.zIndex-c.zIndex}),o=0;o0){var a=this.diagram.add(r);a&&this.select(a),this.addHistoryEntry({type:"Group",undoObject:r,redoObject:r,category:"Internal"}),this.diagram.diagramActions=this.diagram.diagramActions&~ee.Group,this.diagram.protectPropertyChange(e)}},n.prototype.unGroup=function(t){var i=this.diagram.isProtectedOnChange;this.diagram.protectPropertyChange(!0),this.diagram.diagramActions=this.diagram.diagramActions|ee.Group;var r=[];t?r.push(t):r=this.diagram.selectedItems.nodes,this.diagram.startGroupAction();for(var s=0;s0&&this.diagram.removePorts(o,o.ports),o.annotations&&o.annotations.length>0&&!ce()&&this.diagram.removeLabels(o,o.annotations);for(var c=this.diagram.nameTable[o.parentId],d=o.children.length-1;d>=0;d--)this.diagram.nameTable[o.children[parseInt(d.toString(),10)]].parentId="",this.diagram.deleteChild(this.diagram.nameTable[o.children[parseInt(d.toString(),10)]],o),o.parentId&&o.children[parseInt(d.toString(),10)]&&this.diagram.addChild(c,o.children[parseInt(d.toString(),10)]);this.resetDependentConnectors(o.inEdges,!0),this.resetDependentConnectors(o.outEdges,!1),this.diagram.diagramActions&ee.UndoRedo||this.addHistoryEntry({type:"UnGroup",undoObject:a,redoObject:a,category:"Internal"}),o.parentId&&this.diagram.deleteChild(o,c)}this.diagram.removeNode(o,l),this.clearSelection()}this.diagram.endGroupAction(),this.diagram.diagramActions=this.diagram.diagramActions&~ee.Group,this.diagram.protectPropertyChange(i)},n.prototype.resetDependentConnectors=function(t,e){for(var i=0;i0&&(g=!1)}if(g){var y=this.cloneConnector(f,i);c.push(y),o[h.id]=y.id}}else{var S=this.cloneNode(h,i);if(c.push(S),S){o[h.id]=S.id;var b=h.inEdges;if(b)for(var M=0,w=b;M0)for(var u=0;u0)for(r=t.segments,s=0;s0&&this.diagram.drawingObject&&"Bezier"===this.diagram.drawingObject.type&&(t.segments=[]);var e=this.diagram.add(t);"SVG"!==this.diagram.mode&&this.diagram.refreshDiagramLayer(),this.selectObjects([e]),t&&!kI(this.diagram)&&(this.diagram.tool&=~ri.DrawOnce,this.diagram.currentDrawingObject=void 0)},n.prototype.enableServerDataBinding=function(t){this.diagram.enableServerDataBinding(t)},n.prototype.addText=function(t,e){var i=this.diagram.findElementUnderMouse(t,e,this.diagram);this.diagram.startTextEdit(t,i instanceof ai?i.id.split("_")[1]:void 0)},n.prototype.isUserHandle=function(t){var e=this.diagram.selectedItems;if(e.wrapper&&qr(e.constraints,"UserHandle"))for(var i=0,r=e.userHandles;i0&&t[0]&&t[0].isLane)for(s=this.diagram.getObject(t[0].parentId),t[0].shape.header=[],a=0;a1||e&&1===t.length)){if(1!==t.length)return[2];this.clearSelection()}if(!(u||d||1!==t.length||e&&$a(this.diagram)))return this.clearSelection(),[2]}if(!r.cancel){for(f=0;f0||e)&&p.children&&!p.parentId)for(g=0;g0||e,!0)}else this.select(p,f>0||e,!0);void 0===i&&(i=c),r={oldValue:i||[],newValue:this.getSelectedObject(),cause:this.diagram.diagramActions,state:"Changed",type:"Addition",cancel:!1},this.diagram.renderSelector(e||t&&t.length>1),ce()||this.diagram.triggerEvent(Ce.selectionChange,r),this.diagram.enableServerDataBinding(!0)}return[2]})})},n.prototype.findParent=function(t){return t.parentId&&this.findParent(t=this.diagram.nameTable[t.parentId]),t},n.prototype.selectProcesses=function(t){if(this.hasProcesses(t))for(var e=t.shape.activity.subProcess.processes,i=0;i0)},n.prototype.select=function(t,e,i){var r=this.getObjectLayer(t.id);if(xd(t)&&!(t instanceof ei)&&!_r(this.diagram,t)&&r&&!r.lock&&r.visible&&t.wrapper.visible){(e=!!$a(this.diagram)&&e)||this.clearSelection(),this.diagram.enableServerDataBinding(!1);var s=this.diagram.selectedItems;if(t instanceof te?s.nodes.push(t.isHeader?this.diagram.nameTable[t.parentId]:t):s.connectors.push(t),s.selectedObjects.push(t),e)s.wrapper.rotateAngle=s.rotateAngle=0,s.wrapper.children.push(t.wrapper);else if(s.init(this.diagram),1===s.nodes.length&&0===s.connectors.length){var l=_x(this.diagram,s);l&&(s.wrapper.children[0]=l),s.rotateAngle=s.nodes[0].rotateAngle,s.wrapper.rotateAngle=s.nodes[0].rotateAngle,s.wrapper.pivot=s.nodes[0].pivot}i||this.diagram.renderSelector(e),this.diagram.enableServerDataBinding(!0)}},n.prototype.labelSelect=function(t,e){this.oldSelectedObjects=im(this.diagram);var i=this.diagram.selectedItems,r=this.diagram.allowServerDataBinding;this.diagram.allowServerDataBinding=!1,i.nodes=i.connectors=[],this.diagram.allowServerDataBinding=r,t instanceof te?i.nodes[0]=t:i.connectors[0]=t,i.annotation=this.findTarget(e,t),i.init(this.diagram),this.diagram.renderSelector(!1)},n.prototype.unSelect=function(t){var e=this.diagram.selectedItems.nodes.concat(this.diagram.selectedItems.connectors),i=e.filter(function(a){return a.id!==t.id}),r={oldValue:e,newValue:i,cause:this.diagram.diagramActions,state:"Changing",type:"Removal",cancel:!1};if(this.diagram.currentSymbol||ce()||this.diagram.triggerEvent(Ce.selectionChange,r),_r(this.diagram,t)){var s=this.diagram.selectedItems,o=void 0;t instanceof te?(o=s.nodes.indexOf(t,0),s.nodes.splice(o,1)):(o=s.connectors.indexOf(t,0),s.connectors.splice(o,1)),o=s.selectedObjects.indexOf(t,0),s.selectedObjects.splice(o,1),(r={oldValue:e,newValue:i,cause:this.diagram.diagramActions,state:"Changed",type:"Removal",cancel:(r={oldValue:e,newValue:i,cause:this.diagram.diagramActions,state:"Changed",type:"Removal",cancel:!1}).cancel}).cancel||(o=s.wrapper.children.indexOf(t.wrapper,0),s.wrapper.children.splice(o,1),this.diagram.updateSelector(),this.diagram.currentSymbol||this.diagram.triggerEvent(Ce.selectionChange,r))}},n.prototype.moveSvgNode=function(t,e){var i=this.diagram.nameTable[""+e];if("Native"===i.shape.type||"HTML"===i.shape.type)this.updateNativeNodeIndex(t,e);else{var r=xt(e+"_groupElement",this.diagram.element.id),s=xt(t+"_groupElement",this.diagram.element.id);r.parentNode.insertBefore(s,r)}},n.prototype.moveAfterSvgNode=function(t,e){var i=this.diagram.nameTable[""+e];if(!i||"HTML"!==i.shape.type&&"Native"!==i.shape.type)a=xt(e+"_groupElement",this.diagram.element.id),o=xt(t+"_groupElement",this.diagram.element.id),a.insertAdjacentElement("afterend",o);else for(var r=0;rd&&"SwimLane"!==p.shape.type){var S=$(p);p.zIndex=d-((-1!==i.indexOf(p)?i.indexOf(p):0)+1),p.children&&(d=this.findLowestZIndex(p,c)||d),this.triggerOrderCommand(S,p,p),p.children&&this.updateGroupZindex(p,"SendToBack",d)}else"SwimLane"===p.shape.type&&(y=this.swapZIndexObjects(a,h,r,g));if("SVG"===this.diagram.mode){for(var M="SwimLane"!==this.diagram.nameTable[""+r].shape.type?d:y,w=h[parseInt(M.toString(),10)];!w&&Md)&&(d=f.zIndex)}for(var p=JSON.parse(JSON.stringify(l)),v=Number(Object.keys(l).sort(function(wo,Ul){return Number(wo)-Number(Ul)}).reverse()[0]),y=this.diagram.nameTable[""+e].zIndex,S=[],M=0;M<=v;M++)S.push(l[parseInt(M.toString(),10)]);if("SwimLane"===this.diagram.nameTable[""+e].shape.type)for(var C=v;C>=y;C--)if(l[parseInt(C.toString(),10)]&&this.diagram.nameTable[l[parseInt(C.toString(),10)]].parentId!==e){v=C;break}var D=this.diagram.nameTable[""+e];if(D.zIndexx&&(x=L.zIndex)}}else x=d;D.zIndex=x+((-1!==r.indexOf(D)?r.indexOf(D):0)+1),this.triggerOrderCommand(A,D,D)}else if("SwimLane"===D.shape.type){for(var O=0,N=-1,T=0,z=0,U=JSON.parse(JSON.stringify(l)),B=0;B<=y;B++)if(l[parseInt(B.toString(),10)]&&this.diagram.nameTable[l[parseInt(B.toString(),10)]].parentId===e&&-1===N){N=B,T=B;break}for(var j=0;j<=v;j++)p[parseInt(j.toString(),10)]&&p[parseInt(j.toString(),10)]!==e&&this.diagram.nameTable[p[parseInt(j.toString(),10)]].parentId!==e&&this.diagram.nameTable[p[parseInt(j.toString(),10)]].zIndex>=this.diagram.nameTable[""+e].zIndex&&O++;for(var ue=N,fe=0;fe<=O;fe++){for(;!l[parseInt(ue.toString(),10)];)ue++;z=this.diagram.nameTable[l[parseInt(ue.toString(),10)]].zIndex,ue++}for(var Me=z;Me<=v;Me++){for(;!U[parseInt(N.toString(),10)];)N++;for(;!l[parseInt(Me.toString(),10)];)Me++;l[parseInt(Me.toString(),10)]=U[parseInt(N.toString(),10)],this.diagram.nameTable[l[parseInt(Me.toString(),10)]].zIndex=Me,N++}l[parseInt(v.toString(),10)]=this.diagram.nameTable[""+e].id,this.diagram.nameTable[""+e].zIndex=v,ue=y+1;for(var De=T,xe=0;xe0&&("Native"===cr[0].shape.type||"HTML"===cr[0].shape.type)){for(Ci.parentNode.removeChild(Ci),De=0;De0?r[0]:null},n.prototype.findLowestZIndex=function(t,e){var r=this.diagram.nodes.filter(function(s){return-1!==e.indexOf(s.id)}).filter(function(s){return""===s.parentId&&s.id!==t.id}).map(function(s){return s.zIndex});return r.sort(function(s,o){return s-o}),r.length>0?r[0]:null},n.prototype.triggerOrderCommand=function(t,e,i){var s={zIndex:$(t).zIndex},o={zIndex:e.zIndex},a={element:i,cause:this.diagram.diagramActions,diagramAction:this.diagram.getDiagramAction(this.diagram.diagramActions),oldValue:s,newValue:o};this.diagram.triggerEvent(Ce.propertyChange,a)},n.prototype.checkGroupNode=function(t,e,i){return i[""+e].parentId===i[""+t].parentId},n.prototype.sortByZIndex=function(t,e,i){if("BringForward"===i){var r=e||"zIndex";t=t.sort(function(o,a){return a[""+r]-o[""+r]})}else{var s=e||"zIndex";t=t.sort(function(o,a){return o[""+s]-a[""+s]})}return t},n.prototype.orderCommands=function(t,e,i){var r=this,s=e.nodes;if(s=s.concat(e.connectors),t)if("SendBackward"===i)for(var o=0;oa}),S=v.filter(function(D){return D0?Math.max.apply(Math,S):a,M=y.length>0?Math.min.apply(Math,y):a;if(a!==M){var w=c.zIndexTable[parseInt(M.toString(),10)],C=c.zIndexTable[parseInt(a.toString(),10)];this.moveSvgNode(C,w)}else"SendToBack"===i&&(w=c.zIndexTable[parseInt(a.toString(),10)],C=c.zIndexTable[parseInt(b.toString(),10)],this.moveAfterSvgNode(w,C))}}else this.diagram.refreshCanvasLayers()}},n.prototype.swapDomOrder=function(t,e){if(t){var i=this.diagram.getObject(e);if("Native"===i.shape.type||"HTML"===i.shape.type)this.updateNativeNodeIndex(e,t),this.updateNativeNodeIndex(t,e);else{var r=xt(e+"_groupElement",this.diagram.element.id),s=xt(t+"_groupElement",this.diagram.element.id);r.parentNode.insertBefore(r,s),r.parentNode.insertBefore(s,r)}}},n.prototype.sendForward=function(t){var e=this;if(this.diagram.protectPropertyChange(!0),$a(this.diagram)||t){$(t||(this.diagram.selectedItems.nodes.length?this.diagram.selectedItems.nodes[0]:this.diagram.selectedItems.connectors[0]));var s=t&&t.id,o=this.diagram.layers.indexOf(this.getObjectLayer(s=s||(this.diagram.selectedItems.nodes.length?this.diagram.selectedItems.nodes[0].id:this.diagram.selectedItems.connectors[0].id))),a=$(this.diagram.nameTable),h=(parseInt(o.toString(),10),this.diagram.nameTable[""+s]),c=[],d=this.diagram.spatialSearch.findObjects(h.wrapper.bounds);d.length>2&&(d=this.sortByZIndex(d,void 0,"BringForward"));for(var u=0,f=d;u=0;p--)this.diagram.nameTable[c[parseInt(p.toString(),10)].id].parentId===s&&c.splice(p,1);if(c.length>0){var y=this.diagram.nameTable[c[c.length-1].id];if(y.parentId){var b=nm(y,this.diagram,""),M=this.diagram.nameTable[""+b];M.id!==s&&(c[0]=M)}var w={};for(p=0;p0&&(Object.values(O).forEach(function(ue){ue>=T&&N.push(ue)}),0!==N.length&&this.updateZIndexBySendForward(h,N,o))}var z=[];if(Object.keys(this.changedNodeZIndexes).forEach(function(ue){if((a[""+ue]?a[""+ue].zIndex:null)!==e.changedNodeZIndexes[""+ue]){var De=$(a[""+ue]);z.push(De)}}),this.updateLayerZindexTable(o),L.nodes.splice(0,L.nodes.length),z.forEach(function(ue){var fe=$(ue);L.nodes.push(fe)}),"SVG"===this.diagram.mode){var U=c[c.length-1].id,B=c[c.length-1];B&&!("HTML"===B.shape.type||"Native"===B.shape.type)&&this.moveAfterSvgNode(s,U),this.updateNativeNodeIndex(U,s)}else this.diagram.refreshCanvasLayers();var j=[];Object.keys(this.changedNodeZIndexes).forEach(function(ue){if((a[""+ue]?a[""+ue].zIndex:null)!==e.changedNodeZIndexes[""+ue]){var De=$(e.diagram.nameTable[""+ue]);j.push(De)}});var Q=$(this.diagram.selectedItems);Q.nodes.splice(0,Q.nodes.length),j.forEach(function(ue){var fe=$(ue);Q.nodes.push(fe)}),this.diagram.diagramActions&ee.UndoRedo||this.addHistoryEntry({type:"SendForward",category:"Internal",undoObject:L,redoObject:Q}),this.diagram.endGroupAction()}}this.diagram.protectPropertyChange(!1)},n.prototype.updateZIndexBySendForward=function(t,e,i){var r=$(t);t.zIndex=Math.min.apply(Math,e);var a,s=Math.min.apply(Math,e),o=Math.min.apply(Math,e),l=this.diagram.layers[parseInt(i.toString(),10)].objects,h=this.diagram.nodes.filter(function(S){return-1!==l.indexOf(S.id)});t.children&&this.updateGroupZindex(t,"BringForward",t.zIndex);var c=h.filter(function(S){return S.zIndex===Math.min.apply(Math,e)&&S.id!==t.id});if(c&&c.length>0&&c[0].children){for(var d=Math.min.apply(Math,e),u=0;uo&&g!==t&&g.parentId!==t.id&&c&&c.length>0&&g.parentId!==c[0].id){var v=$(g);g.zIndex=a+1,a++,this.triggerOrderCommand(v,g,g)}var y=g.zIndex;this.changedNodeZIndexes[g.id]=(this.changedNodeZIndexes.hasOwnProperty(g.id),y)}},n.prototype.arrangeZIndexForLowerNodes=function(t,e,i){var r=i.filter(function(o){return o.zIndex<=t&&o.parentId!==e.id});r.sort(function(o,a){return a.zIndex-o.zIndex});for(var s=0;se&&(e=r.zIndex)}return e},n.prototype.sendBackward=function(t){var e=this;if(this.diagram.protectPropertyChange(!0),$a(this.diagram)||t){$(t||(this.diagram.selectedItems.nodes.length?this.diagram.selectedItems.nodes[0]:this.diagram.selectedItems.connectors[0]));var s=t&&t.id,o=this.diagram.layers.indexOf(this.getObjectLayer(s=s||(this.diagram.selectedItems.nodes.length?this.diagram.selectedItems.nodes[0].id:this.diagram.selectedItems.connectors[0].id))),a=$(this.diagram.nameTable),h=(parseInt(o.toString(),10),this.diagram.nameTable[""+s]),c=[],d=this.diagram.spatialSearch.findObjects(h.wrapper.bounds);d.length>2&&(d=this.sortByZIndex(d));for(var u=0,f=d;uNumber(p.zIndex)&&""===p.parentId&&h.wrapper.bounds.intersects(p.wrapper.bounds)&&c.push(p);for(var p=c.length-1;p>=0;p--)(v=this.diagram.nameTable[c[parseInt(p.toString(),10)].id]).parentId===s&&c.splice(p,1);if(c.length>0){var v;if((v=this.diagram.nameTable[c[c.length-1].id]).parentId){var S=nm(v,this.diagram,""),b=this.diagram.nameTable[""+S];s!==b.id&&(c[c.length-1]=b)}var M={};for(p=0;p0&&(Object.values(L).forEach(function(fe){fe<=N&&O.push(fe)}),0!==O.length&&this.updateZIndexBySendBackward(h,O,o))}var T=[];if(Object.keys(this.changedNodeZIndexes).forEach(function(fe){if((a[""+fe]?a[""+fe].zIndex:null)!==e.changedNodeZIndexes[""+fe]){var xe=$(a[""+fe]);T.push(xe)}}),this.updateLayerZindexTable(o),P.nodes.splice(0,P.nodes.length),T.forEach(function(fe){var Me=$(fe);P.nodes.push(Me)}),"SVG"===this.diagram.mode){var z=c[c.length-1].id,U=c[c.length-1];U&&"HTML"!==U.shape.type&&"Native"!==U.shape.type&&this.moveSvgNode(s,z);var B=this.diagram.nameTable[""+z];B.children&&B.children.length>0?this.updateNativeNodeIndex(s):this.updateNativeNodeIndex(s,z)}else this.diagram.refreshCanvasLayers();var j=[];Object.keys(this.changedNodeZIndexes).forEach(function(fe){if((a[""+fe]?a[""+fe].zIndex:null)!==e.changedNodeZIndexes[""+fe]){var xe=$(e.diagram.nameTable[""+fe]);j.push(xe)}});var Q=$(this.diagram.selectedItems);Q.nodes.splice(0,Q.nodes.length),j.forEach(function(fe){var Me=$(fe);Q.nodes.push(Me)}),this.diagram.diagramActions&ee.UndoRedo||this.addHistoryEntry({type:"SendBackward",category:"Internal",undoObject:P,redoObject:Q}),this.diagram.endGroupAction()}}this.diagram.protectPropertyChange(!1)},n.prototype.updateZIndexBySendBackward=function(t,e,i){var r=$(t);t.zIndex=Math.max.apply(Math,e);var f,s=t.zIndex,o=Math.max.apply(Math,e),a=this.diagram.layers[parseInt(i.toString(),10)].objects,l=this.diagram.nodes.filter(function(S){return-1!==a.indexOf(S.id)}),h=l.filter(function(S){return S.zIndex===Math.max.apply(Math,e)&&S.id!==t.id});if(h&&h.length>0&&h[0].children)for(var c=Math.max.apply(Math,e),d=0;d0&&g.parentId!==h[0].id){var v=$(g);g.zIndex=f-1,f--,this.triggerOrderCommand(v,g,g)}var y=g.zIndex;this.changedNodeZIndexes[""+g.id]=(this.changedNodeZIndexes.hasOwnProperty(g.id),y)}},n.prototype.findLowestChildZIndex=function(t){for(var e=t.zIndex,i=0;i0),this.selectObjects([t],!0))},n.prototype.clearSelection=function(t,e){return bT(this,void 0,void 0,function(){var i,r,s,o;return MT(this,function(a){return i=this.diagram.allowServerDataBinding,this.diagram.enableServerDataBinding(!1),$a(this.diagram)&&(r=this.diagram.selectedItems,s=this.getSelectedObject(),this.diagram.currentSymbol&&(this.diagram.previousSelectedObject=s),o={oldValue:s,newValue:[],cause:this.diagram.diagramActions,state:"Changing",type:"Removal",cancel:!1},t&&(ce()||this.diagram.triggerEvent(Ce.selectionChange,o)),o.cancel||(r.offsetX=0,r.offsetY=0,r.width=0,r.height=0,r.rotateAngle=0,r.nodes=[],r.connectors=[],r.wrapper=null,r.annotation=void 0,r.selectedObjects=[],this.diagram.clearSelectorLayer(),t&&(o={oldValue:s,newValue:[],cause:this.diagram.diagramActions,state:"Changed",type:"Removal",cancel:!1},ce()||this.diagram.triggerEvent(Ce.selectionChange,o))),this.diagram.enableServerDataBinding(i)),[2]})})},n.prototype.clearSelectedItems=function(){this.clearSelection((this.diagram.selectedItems.nodes?this.diagram.selectedItems.nodes.length:0)+(this.diagram.selectedItems.connectors?this.diagram.selectedItems.connectors.length:0)>0)},n.prototype.removeStackHighlighter=function(){var t=Bl(this.diagram.element.id),e=t.getElementById(t.id+"_stack_highlighter");e&&e.parentNode.removeChild(e)},n.prototype.renderStackHighlighter=function(t,e){var r,s,o,i=this.diagram.selectedItems.nodes[0];if(!e){var a=this.diagram.findObjectsUnderMouse(t.position);if((e=this.diagram.findObjectUnderMouse(a,"Drag",!0))&&!(e.isLane||e.isPhase||e.isHeader))for(var l=0;l0)for(var a=0;a1)if(i){var h=l.segments[0],c=l.segments[1],u=Nl(MI(t.wrapper,t.wrapper.corners,t.wrapper.bounds),h.direction),g=Ol({corners:void 0,point:u=qa(l,0,u,{x:l.sourceWrapper.offsetX,y:l.sourceWrapper.offsetY},!1),margin:void 0,direction:h.direction},{corners:void 0,point:c.points[1],margin:void 0,direction:void 0});h.length=R.distancePoints(g[0],g[1]),c.direction&&c.length&&(c.length=R.distancePoints(g[1],g[2]))}else if(o){switch(l.segments[0].direction){case"Bottom":r=t.wrapper.bounds.bottomCenter.x-e.bottomCenter.x,s=t.wrapper.bounds.bottomCenter.y-e.bottomCenter.y;break;case"Top":r=t.wrapper.bounds.topCenter.x-e.topCenter.x,s=t.wrapper.bounds.topCenter.y-e.topCenter.y;break;case"Left":r=t.wrapper.bounds.middleLeft.x-e.middleLeft.x,s=t.wrapper.bounds.middleLeft.y-e.middleLeft.y;break;case"Right":r=t.wrapper.bounds.middleRight.x-e.middleRight.x,s=t.wrapper.bounds.middleRight.y-e.middleRight.y}this.dragSourceEnd(l,r,s,!0,null,"ConnectorSourceEnd",void 0,void 0,void 0,!(t.parentId&&this.diagram.diagramActions&ee.isGroupDragging))}}},n.prototype.updateEndPoint=function(t,e){var r={sourcePoint:t.sourcePoint,targetPoint:t.targetPoint};t.sourceID&&(r.sourceID=t.sourceID),t.targetID&&(r.targetID=t.targetID),t.sourcePortID&&(r.sourcePortID=t.sourcePortID),t.targetPortID&&(r.targetPortID=t.targetPortID),t.segments&&(r.segments=t.segments),this.diagram.connectorPropertyChange(t,e||{},r),this.diagram.updateSelector()},n.prototype.dragSourceEnd=function(t,e,i,r,s,o,a,l,h,c,d){var u=this.diagram.nameTable[t.id],f={},p=this.checkBoundaryConstraints(e,i,u.wrapper.bounds);if(xI(u)&&p&&"BezierSourceThumb"!==o&&Uv(this.diagram)&&(f=$(f={sourcePoint:u.sourcePoint}),u.sourcePoint.x+=e,u.sourcePoint.y+=i,"ConnectorSourceEnd"===o&&"Orthogonal"===u.type&&this.changeSegmentLength(u,l,h,c),"Bpmn"===u.shape.type&&"Default"===u.shape.sequence&&"Sequence"===u.shape.flow&&this.updatePathElementOffset(u)),"Bezier"===u.type)if(f={sourcePoint:u.sourcePoint},d)this.translateBezierPoints(t,""===o?"ConnectorSourceEnd":o,e,i,d,s,!a);else for(var g=0;g2){var d=R.direction((c=t.segments[2]).points[0],c.points[1]);o.direction===_n(d)?("Right"===o.direction?c.points[0].x=o.points[o.points.length-1].x=l.wrapper.corners.middleRight.x+20:"Left"===o.direction?c.points[0].x=o.points[o.points.length-1].x=l.wrapper.corners.middleLeft.x-20:c.points[0].y=o.points[o.points.length-1].y="Top"===o.direction?l.wrapper.corners.topCenter.y-20:l.wrapper.corners.bottomCenter.y+20,c.direction&&c.length&&(c.length=R.distancePoints(c.points[0],c.points[c.points.length-1])),o.length=R.distancePoints(o.points[0],o.points[o.points.length-1])):o.direction===d&&c.direction&&c.length?("Top"===o.direction||"Bottom"===o.direction?(c.points[0]=o.points[0],c.points[c.points.length-1].x=c.points[0].x):(c.points[0]=o.points[0],c.points[c.points.length-1].y=c.points[0].y),c.length=R.distancePoints(c.points[0],c.points[c.points.length-1]),t.segments.splice(0,2)):o.length=20}else o.length=20;else if(o.length<1)if(""!==t.sourceID){var c;"Right"===a.direction?a.points[a.points.length-1].y=(h=l.wrapper.corners.middleRight).y:"Left"===a.direction?a.points[a.points.length-1].y=(h=l.wrapper.corners.middleLeft).y:a.points[a.points.length-1].x="Top"===a.direction?(h=l.wrapper.corners.topCenter).x:(h=l.wrapper.corners.bottomCenter).x,a.length=R.distancePoints(h,a.points[a.points.length-1]),t.segments.length>2&&(c=t.segments[2]).direction&&c.length&&(c.length=R.distancePoints(a.points[a.points.length-1],c.points[c.points.length-1])),t.segments.splice(0,1)}else t.segments.splice(0,1)}else e&&!i&&t.sourceID!==e.id&&t.segments&&null!==t.segments[0].direction&&e&&e instanceof te&&s&&this.changeSourceEndToNode(t,e),e&&i&&t.sourcePortID!==i&&t.segments&&null!==t.segments[0].direction&&e&&e instanceof te&&s&&this.changeSourceEndToPort(t,e,i)},n.prototype.canConnect=function(t,e){return!(!ua(e)||!Ph(e))},n.prototype.changeSourceEndToPort=function(t,e,i){var r=this.diagram.getWrapper(e.wrapper,i),s={x:r.offsetX,y:r.offsetY},o=zo(s,xn(e.wrapper),e.wrapper.bounds),a=t.segments[0],l=t.segments[1];if(a.direction!==o){var h=[],c={};if(a.direction===_n(o)){c={};var d=void 0;"Top"===o||"Bottom"===o?(d="Top"===o?{type:"Orthogonal",isTerminal:!0,direction:o,length:Math.abs(a.points[0].y-s.y)}:{type:"Orthogonal",isTerminal:!0,direction:o,length:Math.abs(s.y-a.points[0].y)},c=a.points[0].x>s.x?{type:"Orthogonal",isTerminal:!0,direction:"Right",length:a.points[0].x-s.x}:{type:"Orthogonal",isTerminal:!0,direction:"Left",length:s.x-a.points[0].x}):(d="Right"===o?{type:"Orthogonal",isTerminal:!0,direction:o,length:Math.abs(a.points[0].x-s.x)}:{type:"Orthogonal",isTerminal:!0,direction:o,length:Math.abs(s.x-a.points[0].x)},c=a.points[0].y>s.y?{type:"Orthogonal",direction:"Top",isTerminal:!0,length:a.points[0].y-s.y}:{type:"Orthogonal",direction:"Bottom",isTerminal:!0,length:s.y-a.points[0].y}),h.push(new wi(t,"segments",d,!0)),h.push(new wi(t,"segments",c,!0))}else h.push(new wi(t,"segments",c={type:"Orthogonal",direction:o,length:20,isTerminal:!0},!0));a.direction!==_n(o)&&("Top"===o||"Bottom"===o?(a.points[0].x=s.x,a.points[0].y=a.points[a.points.length-1].y="Top"===o?s.y-20:s.y+20):(a.points[0].y=s.y,a.points[0].x=a.points[a.points.length-1].x="Right"===o?s.x+20:s.x-20),a.length=R.distancePoints(a.points[0],a.points[a.points.length-1]),l.length=R.distancePoints(a.points[a.points.length-1],l.points[l.points.length-1])),t.segments=h.concat(t.segments)}else a.points[0]=s,"Top"===o||"Bottom"===o?a.points[a.points.length-1].x=s.x:a.points[a.points.length-1].y=s.y,a.length=R.distancePoints(a.points[0],a.points[a.points.length-1]),l.length=R.distancePoints(a.points[a.points.length-1],l.points[l.points.length-1])},n.prototype.removeTerminalSegment=function(t,e){for(var i=0;ii.width||"Left"===o.direction&&r.x>=o.points[0].x||"Right"===o.direction&&r.x<=o.points[0].x)o.points[0].y=o.points[o.points.length-1].y=r.y,o.points[0].x=r.x,o.length=R.distancePoints(o.points[0],o.points[o.points.length-1]),a.length=R.distancePoints(o.points[o.points.length-1],a.points[a.points.length-1]);else{var h=void 0;s="Bottom"===(h=a.direction?a.direction:R.direction(a.points[0],a.points[a.points.length-1]))?i.bottomCenter:i.topCenter,a.length&&a.direction&&(a.length="Top"===h?o.points[o.points.length-1].y-(s.y+20):s.y+20-o.points[o.points.length-1].y),o.length=o.points[o.points.length-1].x-s.x,o.direction=o.length>0?"Right":"Left",l.push(new wi(t,"segments",{type:"Orthogonal",direction:h,length:20},!0)),t.segments=l.concat(t.segments)}else r="Bottom"===o.direction?i.bottomCenter:i.topCenter,o.length>i.height||"Top"===o.direction&&r.y>=o.points[0].y||"Bottom"===o.direction&&r.y<=o.points[0].y?(o.points[0].x=o.points[o.points.length-1].x=r.x,o.points[0].y=r.y,o.length=R.distancePoints(o.points[0],o.points[o.points.length-1]),a.length=R.distancePoints(o.points[o.points.length-1],a.points[a.points.length-1])):(s="Left"===a.direction?i.middleLeft:i.middleRight,h=void 0,h=a.direction?a.direction:R.direction(a.points[0],a.points[a.points.length-1]),a.length&&a.direction&&(a.length="Left"===h?o.points[o.points.length-1].x-(s.x+20):s.x+20-o.points[o.points.length-1].x),o.length=o.points[o.points.length-1].y-s.y,o.direction=o.length>0?"Bottom":"Top",l.push(new wi(t,"segments",{type:"Orthogonal",direction:h,length:20},!0)),t.segments=l.concat(t.segments))},n.prototype.translateBezierPoints=function(t,e,i,r,s,o,a){var l=t.segments.indexOf(s),h=t.segments[parseInt(l.toString(),10)],c=l>0?t.segments[l-1]:null,d=null!==c?c.point:t.sourcePoint,u=l===t.segments.length-1?t.targetPoint:h.point;if(h)if("BezierSourceThumb"===e&&(h.vector1.angle||h.vector1.distance)){var f=h.vector1.distance,p=h.vector1.angle;h.vector1={distance:t.distance(d,o),angle:R.findAngle(d,o)},this.translateSubsequentSegment(t,s,!0,h.vector1.distance-f,h.vector1.angle-p)}else"BezierTargetThumb"===e&&(h.vector2.angle||h.vector2.distance)?(f=h.vector2.distance,p=h.vector2.angle,h.vector2={distance:t.distance(u,o),angle:R.findAngle(u,o)},this.translateSubsequentSegment(t,s,!1,h.vector2.distance-f,h.vector2.angle-p)):("ConnectorSourceEnd"===e&&!t.sourceID||"ConnectorTargetEnd"===e&&!t.targetID)&&a&&YI(h.vector1)&&YI(h.vector2)?(R.isEmptyPoint(h.point1)&&(h.bezierPoint1=QI(t.sourcePoint,t.targetPoint)),R.isEmptyPoint(h.point2)&&(h.bezierPoint2=QI(t.targetPoint,t.sourcePoint))):"BezierSourceThumb"===e||"ConnectorSourceEnd"===e&&!a&&YI(h.vector1)?(h.bezierPoint1.x+=i,h.bezierPoint1.y+=r,(!R.isEmptyPoint(h.point1)||a)&&(h.point1={x:h.bezierPoint1.x,y:h.bezierPoint1.y})):("BezierTargetThumb"===e||"ConnectorTargetEnd"===e&&!a&&YI(h.vector2))&&(h.bezierPoint2.x+=i,h.bezierPoint2.y+=r,(!R.isEmptyPoint(h.point2)||a)&&(h.point2={x:h.bezierPoint2.x,y:h.bezierPoint2.y}))},n.prototype.translateSubsequentSegment=function(t,e,i,r,s){var o=t.segments.indexOf(e);parseInt(o.toString(),10),t.bezierSettings.smoothness&mI.SymmetricAngle||(s=null),t.bezierSettings.smoothness&mI.SymmetricDistance||(r=null),(null!=r||null!=s)&&(i?0!==o&&this.updatePreviousBezierSegment(t,o,r,s):o!==t.segments.length-1&&this.updateNextBezierSegment(t,o,r,s))},n.prototype.updatePreviousBezierSegment=function(t,e,i,r){var s=t.segments[e-1],a=(s.vector2.angle+r)%360;a<0&&(a+=360),s.vector2={distance:s.vector2.distance+i,angle:a}},n.prototype.updateNextBezierSegment=function(t,e,i,r){var s=t.segments[e+1],a=(s.vector1.angle+r)%360;a<0&&(a+=360),s.vector1={distance:s.vector1.distance+i,angle:a}},n.prototype.dragTargetEnd=function(t,e,i,r,s,o,a,l){var c,h=this.diagram.nameTable[t.id],d=this.checkBoundaryConstraints(e,i,h.wrapper.bounds);if(TI(h)&&"BezierTargetThumb"!==o&&d&&Uv(this.diagram)){if(c=$(c={targetPoint:h.targetPoint}),h.targetPoint.x+=e,h.targetPoint.y+=i,"ConnectorTargetEnd"===o&&"Orthogonal"===h.type&&h.segments&&h.segments.length>0){var u=h.segments[h.segments.length-2];u&&2===h.segments[h.segments.length-1].points.length&&("Left"===u.direction||"Right"===u.direction?u.points[u.points.length-1].x=h.targetPoint.x:u.points[u.points.length-1].y=h.targetPoint.y,u.length=R.distancePoints(u.points[0],u.points[u.points.length-1]),u.direction=R.direction(u.points[0],u.points[u.points.length-1]))}"Bpmn"===h.shape.type&&"Default"===h.shape.sequence&&"Sequence"===h.shape.flow&&this.updatePathElementOffset(h)}if("Bezier"===h.type)if(c={targetPoint:h.targetPoint},l)this.translateBezierPoints(t,""===o?"ConnectorTargetEnd":o,e,i,l,s,!a);else for(var f=0;f0){if(void 0!==s&&o.segments[parseInt(s.toString(),10)])if("Bezier"===o.type){var a=o.segments[parseInt(s.toString(),10)],l=a.isInternalSegment;l&&null!==o.bezierSettings&&"FreeForm"!==o.bezierSettings.segmentEditOrientation?("Horizontal"===a.orientation?a.point.x+=e:a.point.y+=i,this.updateDirectionalBezierCurve(o)):(a.point.x+=e,a.point.y+=i),l&&(o.isBezierEditing=!0)}else o.segments[parseInt(s.toString(),10)].point.x+=e,o.segments[parseInt(s.toString(),10)].point.y+=i;else for(var h=0;h1){var a=e[1],l=e[2],h={x:.5*(a.x+l.x),y:.5*(a.y+l.y)},c=t.segments[0];c.vector1.angle=Gt(s,a),c.vector1.distance=.5*R.findLength(s,a),c.vector2.angle=Gt(h,a),c.vector2.distance=.5*R.findLength(h,a),c.point=h;var d=t.segments[1];if(d.vector1.angle=Gt(h,l),d.vector1.distance=.5*R.findLength(h,l),t.segments.length>2){var u=e[3],f={x:.5*(l.x+u.x),y:.5*(l.y+u.y)};d.vector2.angle=Gt(f,l),d.vector2.distance=.5*R.findLength(f,l),d.point=f;var p=t.segments[2];if(p.vector1.angle=Gt(f,u),p.vector1.distance=.5*R.findLength(f,u),t.segments.length>3){var g=e[4],v={x:.5*(u.x+g.x),y:.5*(u.y+g.y)};p.vector2.angle=Gt(v,u),p.vector2.distance=.5*R.findLength(v,u),p.point=v;var y=t.segments[3];y.vector1.angle=Gt(v,g),y.vector1.distance=.5*R.findLength(v,g),y.vector2.angle=Gt(o,g),y.vector2.distance=.5*R.findLength(o,g)}else p.vector2.angle=Gt(o,u),p.vector2.distance=.5*R.findLength(o,u)}else d.vector2.angle=Gt(o,l),d.vector2.distance=.5*R.findLength(o,l)}},n.prototype.rotateObjects=function(t,e,i,r,s){r=r||{};var o=Bi();qi(o,i,r.x,r.y);for(var l=0,h=e;l0){this.diagram.protectPropertyChange(!0);var o=t;o.segments=[],this.diagram.connectorPropertyChange(o,{},{segments:o.segments}),this.diagram.protectPropertyChange(!1)}}},n.prototype.updateInnerParentProperties=function(t){var r=this.diagram.isProtectedOnChange;this.diagram.protectPropertyChange(!0);for(var s=this.getAllDescendants(t,[],!1,!0),o=0;o0&&(f=this.diagram.bpmnModule.getChildrenBound(d,d.id,this.diagram),u=d.wrapper.bounds.containsRect(f)),h=d.wrapper.actualSize.width*t,c=d.wrapper.actualSize.height*e,void 0!==d.maxWidth&&0!==d.maxWidth&&(h=Math.min(d.maxWidth,h)),void 0!==d.minWidth&&0!==d.minWidth&&(h=Math.max(d.minWidth,h)),void 0!==d.maxHeight&&0!==d.maxHeight&&(c=Math.min(d.maxHeight,c)),void 0!==d.minHeight&&0!==d.minHeight&&(c=Math.max(d.minHeight,c)),u&&(h=Math.max(h,f.right-d.wrapper.bounds.x),c=Math.max(c,f.bottom-d.wrapper.bounds.y)),t=h/d.actualSize.width,e=c/d.actualSize.height}var p=Bi();o||(o=r);var g=o.wrapper;if(qi(p,-g.rotateAngle,i.x,i.y),Yf(p,t,e,i.x,i.y),qi(p,g.rotateAngle,i.x,i.y),r instanceof te){var d,v=Ke(p,{x:(d=r).wrapper.offsetX,y:d.wrapper.offsetY}),y=d.wrapper.offsetX-d.wrapper.actualSize.width*d.pivot.x,S=d.wrapper.offsetY-d.wrapper.actualSize.height*d.pivot.y;if(h>0)if(d.processId){var b=this.diagram.nameTable[d.processId];(!b.maxWidth||d.margin.left+h0)if(d.processId){var M=this.diagram.nameTable[d.processId];(!M.maxHeight||d.margin.top+c0){if(e.dragLimit=e.dragLimit?e.dragLimit:{},e.dragLimit.top||e.dragLimit.bottom||e.dragLimit.left||e.dragLimit.right){var b={minDistance:null};S=this.getRelativeOffset(v,d,b);var M={minDistance:null};g=this.getRelativeOffset(v,y,M),S=null!=b&&M.minDistance0){if(S=y[y.length-1]){var b=void 0;for(b=0;b=e.x-t.dragLimit.left-r.width/2&&i.x<=e.x+t.dragLimit.right+r.width/2&&(s=!0),i.y>=e.y-t.dragLimit.top-r.height/2&&i.y<=e.y+t.dragLimit.bottom+r.height/2&&(o=!0),{x:s,y:o}},n.prototype.updateLabelMargin=function(t,e,i,r,s,o,a){if(i=i||{x:e.offset,y:0},e&&i&&i.x>0&&i.x<1){var l=R.getLengthFromListOfPoints(t.intermediatePoints),h=this.getPointAtLength(l*i.x,t.intermediatePoints,0),c=this.diagram.scrollSettings.currentZoom,d=e.dragLimit?e.dragLimit:{left:0,right:0,top:0,bottom:0};if(d.top||d.bottom||d.left||d.right){this.diagram.getWrapper(t.wrapper,e.id);var f=new Ne(0,0,0,0),p=this.diagram.getWrapper(t.wrapper,e.id);f.x=p.offsetX/c+o,f.y=p.offsetY/c+a,f.width=p.bounds.width/c,f.height=p.bounds.height/c;var g=new Ne(h.x-(d.left||0)-f.width/2,h.y-(d.top||0)-f.height/2,(d.left||0)+(d.right||0)+f.width,(d.top||0)+(d.bottom||0)+f.height);if(g.containsPoint(r));else for(var S=0,b=this.boundsInterSects([h,r],g,!1);S=t){c=t-r,d=R.findAngle(s,a),u=c*Math.cos(d*Math.PI/180),f=c*Math.sin(d*Math.PI/180),o={x:s.x+u,y:s.y+f};break}r+=h,s=a}else s=a;return o},n.prototype.getInterceptWithSegment=function(t,e){for(var o,a,i=[],r=[],s=[],l=R.findLength({x:0,y:0},{x:this.diagram.scroller.viewPortWidth,y:this.diagram.scroller.viewPortHeight}),h=1;h0&&a<=90||a>180&&a<=270?90:-90;r.push(R.transform(t,a+c,l)),r.push(R.transform(t,o+c,l));var f=Kv({x1:s[0].x,y1:s[0].y,x2:s[1].x,y2:s[1].y},{x1:r[0].x,y1:r[0].y,x2:r[1].x,y2:r[1].y});f.enabled&&i.push(f.intersectPt)}return i},n.prototype.getAnnotationChanges=function(t,e){var r={};return r[eb(t,e.id,!0)]={width:e.width,height:e.height,offset:t instanceof te?{x:e.offset.x,y:e.offset.y}:e.offset,rotateAngle:e.rotateAngle,margin:{left:e.margin.left,right:e.margin.right,top:e.margin.top,bottom:e.margin.bottom},horizontalAlignment:e.horizontalAlignment,verticalAlignment:e.verticalAlignment,alignment:t instanceof de?e.alignment:void 0},{annotations:r}},n.prototype.getConnectorPortChanges=function(t,e){var i=function Nse(n,t,e){for(var i=n.ports,r=0;r1&&(v.width=g,v.offset.x=1/S),p>1&&(v.height=p,v.offset.y=1/b)}}e instanceof Or&&(e.alignment="Center"),l=this.getAnnotationChanges(t,e),t instanceof te?this.diagram.nodePropertyChange(t,a,l):this.diagram.connectorPropertyChange(t,a,l),this.diagram.updateDiagramObject(t)},n.prototype.getSubProcess=function(t){var i,e={nodes:[],connectors:[]};return t instanceof te?i=t.processId:t&&t.nodes&&t.nodes.length&&t.nodes[0].processId&&(i=t.nodes[0].processId),i&&e.nodes.push($(this.diagram.nameTable[i])),e},n.prototype.checkBoundaryConstraints=function(t,e,i,r){var s=this.diagram.pageSettings,o=this.diagram.pageSettings.boundaryConstraints,a=this.diagram.scroller;if("Page"===o||"Diagram"===o){var l=i?void 0:this.diagram.selectedItems.wrapper.bounds;return!!((i?i.right:l.right)+(t||0)<=("Page"===o?s.width:a.viewPortWidth)&&(i?i.left:l.left)+(t||0)>=0&&(i?i.bottom:l.bottom)+(e||0)<=("Page"===o?s.height:a.viewPortHeight)&&(i?i.top:l.top)+(e||0)>=0||"None"!==this.diagram.layout.type&&r)}return!0},n.prototype.dragSelectedObjects=function(t,e){var i=this,r=this.diagram.selectedItems;this.state&&!this.state.backup&&(this.state.backup={},this.state.backup.offsetX=r.offsetX,this.state.backup.offsetY=r.offsetY),r=UI(this.diagram,r)||r;var s=this.diagram.selectedItems.nodes.filter(function(c){return"SwimLane"===c.shape.type});if(s.length>0&&!this.diagram.currentSymbol&&this.diagram.selectedItems.nodes.length>1){var o=this.diagram.selectedItems.nodes.filter(function(c){return""===c.parentId||"SwimLane"!==i.diagram.nameTable[c.parentId].shape.type});if(o.length>0){for(var a=0;a0||l.length>1)&&(o=o.concat(l),this.diagram.selectedItems.nodes.splice(0,this.diagram.selectedItems.nodes.length),o.forEach(function(c){i.diagram.selectedItems.nodes.push(c)}),r=this.diagram.selectedItems,this.diagram.selectedObject.helperObject=void 0)}}if(this.checkBoundaryConstraints(t,e)){this.diagram.diagramActions=this.diagram.diagramActions|ee.PreventZIndexOnDragging|ee.DragUsingMouse;var h=this.diagram.selectedObject.actualObject;return(h&&h instanceof te&&h.isLane&&jx(h,this.diagram)||!h||!h.isLane)&&this.diagram.drag(r,t,e),this.diagram.diagramActions=this.diagram.diagramActions&~(ee.PreventZIndexOnDragging|ee.DragUsingMouse),this.diagram.refreshCanvasLayers(),this.checkHtmlObjectDrag(r),!0}return!1},n.prototype.checkHtmlObjectDrag=function(t){var e=!1;this.diagram.views&&this.diagram.views.length>1&&(t instanceof ei?e=t.nodes.some(function(i){return i.shape&&"HTML"===i.shape.type}):t.shape&&"HTML"===t.shape.type&&(e=!0),e&&this.resetOverviewCanvas())},n.prototype.resetOverviewCanvas=function(){for(var t=0,e=this.diagram.views;t0&&(this.layoutAnimateModule.stopCurrentAnimation(this.objectStore[0],e,t),this.objectStore=[]),a=this.diagram.doLayout(),this.objectStore.push(a)),this.canUpdateTemplate=!1,this.diagram.blazorActions&=~on.expandNode,this.diagram.preventNodesUpdate=r,this.diagram.layoutAnimateModule&&this.diagram.organizationalChartModule&&!i)this.diagram.allowServerDataBinding=!1,this.layoutAnimateModule.expand(this.diagram.layout.enableAnimation,a,t,this.diagram);else{var l={element:$(t),state:!!t.isExpanded};this.triggerEvent(Ce.expandStateChange,l),this.diagram.lineRoutingModule&&this.diagram.constraints&nt.LineRouting&&"ComplexHierarchicalTree"!==this.diagram.layout.type&&this.diagram.resetSegments()}return this.diagram.layout.fixedNode=""===o?"":this.diagram.layout.fixedNode,a},n.prototype.getparentexpand=function(t,e,i,r){for(var s,o=0;o0&&(this.diagram.selectedItems.wrapper.rotateAngle=this.diagram.selectedItems.rotateAngle=s.rotateAngle),!(r instanceof te&&"SwimLane"!==r.shape.type)||r.isLane||r.isPhase||r.isHeader||Dn(this.diagram,r)){if(r instanceof ei)for(var d=0;d30||g.wrapper.outerBounds.topCenter.y-p.wrapper.outerBounds.bottomCenter.y>30)&&this.diagram.lineRoutingModule.refreshConnectorSegments(this.diagram,f,!0)}}this.updateSelector(),this.diagram.protectPropertyChange(!1)}},n.prototype.drawSelectionRectangle=function(t,e,i,r){this.diagram.drawSelectionRectangle(t,e,i,r)},n.prototype.startGroupAction=function(){this.diagram.startGroupAction()},n.prototype.endGroupAction=function(){this.diagram.endGroupAction()},n.prototype.removeChildFromBPmn=function(t,e,i){var r=this.diagram.nameTable[t.id]||t.nodes[0];if(i&&r&&r.processId&&r.processId===i.wrapper.id){var s=$(r);s.processId=r.processId,this.diagram.startGroupAction();var o=this.diagram.nameTable[r.processId].shape.activity.subProcess.processes||[];o.splice(o.indexOf(r.id),1),this.diagram.bpmnModule.removeChildFromBPMN(this.diagram.nameTable[r.processId].wrapper,r.id,this.diagram),this.diagram.nameTable[r.id].processId="",r.offsetX=r.wrapper.offsetX,r.offsetY=r.wrapper.offsetY;var a=$(r);this.addHistoryEntry({type:"PositionChanged",redoObject:{nodes:[a]},undoObject:{nodes:[s]},category:"Internal"}),this.diagram.endGroupAction()}},n.prototype.isDroppable=function(t,e){var i=this.diagram.nameTable[t.id]||t.nodes[0];return i instanceof te&&(!ce()&&"TextAnnotation"===i.shape.shape||("Group"===e.shape.shape&&(e.shape.activity.subProcess.collapsed=!1),!(i&&"Bpmn"===i.shape.type&&(i.processId===e.id||i.id===e.processId||"Bpmn"===e.shape.type&&!(e instanceof de)&&e.shape.activity&&e.shape.activity.subProcess&&e.shape.activity.subProcess.collapsed))))},n.prototype.renderHighlighter=function(t,e,i){if(new Ne,t.target instanceof te||t.target instanceof de||e&&(t.source instanceof te||t.source instanceof de)){var a=this.findTarget(e?t.sourceWrapper:t.targetWrapper,e?t.source:t.target,i,!0),l=void 0;if(a instanceof Rd)for(var h=a.id,c=t.target,u=0,f=c.wrapper.children[0].children[0].children[2].children;u0){var r=0;t[0]=this.diagram.nameTable[t[0].id]||t[0];var s="Object"===i?yr(t[0].wrapper):this.diagram.selectedItems.wrapper.bounds,o={nodes:[],connectors:[]},a={nodes:[],connectors:[]};for(r="Object"===i?r+1:r;r0){var i=0,r=0,s=0,o=0,a=0,l=0,h=0,c=0,d={nodes:[],connectors:[]},u={nodes:[],connectors:[]};for(i=0;io.center.y&&(r=n[parseInt(e.toString(),10)],n[parseInt(e.toString(),10)]=n[parseInt(i.toString(),10)],n[parseInt(i.toString(),10)]=r):s.center.x>o.center.x&&(r=n[parseInt(e.toString(),10)],n[parseInt(e.toString(),10)]=n[parseInt(i.toString(),10)],n[parseInt(i.toString(),10)]=r)}}return n}(t,e),i=1;i0){var i=0,r={x:.5,y:.5};t[0]=this.diagram.nameTable[t[0].id]||t[0];var s=yr(t[0].wrapper),o={nodes:[],connectors:[]},a={nodes:[],connectors:[]};for(i=1;ii.zIndex){for(var s=this.diagram.layers.indexOf(this.diagram.getActiveLayer()),o=this.diagram.layers[parseInt(s.toString(),10)].zIndexTable,a=JSON.parse(JSON.stringify(o)),l=i.zIndex,h=r.zIndex,c=h;c>=l;c--)l!==c?o[c-1]?(o[parseInt(c.toString(),10)]=o[c-1],this.diagram.nameTable[o[parseInt(c.toString(),10)]].zIndex=c):(o[c-1]=o[parseInt(c.toString(),10)],this.diagram.nameTable[o[c-1]].zIndex=c,delete o[parseInt(c.toString(),10)]):this.swapZIndexObjects(h,o,r.id,a);"SVG"===this.diagram.mode?(this.moveSvgNode(e.parentId,i.id),this.updateNativeNodeIndex(e.parentId,i.id)):this.diagram.refreshCanvasLayers()}},n.prototype.findLeastIndexConnector=function(t,e,i){for(var r=0;rs.zIndex&&(i=s)}return i},n.prototype.findLeastIndexObject=function(t,e){var i=t;return t instanceof te&&(i=this.findLeastIndexConnector(t.inEdges,e,i),i=this.findLeastIndexConnector(t.outEdges,e,i)),i},n.prototype.checkSelection=function(t,e){var i;if(1===t.nodes.length&&0===t.connectors.length)if(Dn(this.diagram,t.nodes[0],!0)){var r=t.nodes[0];if("SwimLane"===(i="SwimLane"===t.nodes[0].shape?t.nodes[0]:this.diagram.nameTable[t.nodes[0].parentId]).shape.type){var s="Horizontal"===i.shape.orientation;(r.isPhase&&(s&&"ResizeSouth"===e||!s&&"ResizeEast"===e)||r.isLane&&(s&&"ResizeEast"===e||!s&&"ResizeSouth"===e))&&R3(this.diagram,i,e)}else if("Grid"===i.container.type)if("Horizontal"===i.container.orientation&&1===r.rowIndex||"Vertical"===i.container.orientation&&r.rowIndex>0&&r.columnIndex>0){if("ResizeSouth"===e)for(var o=0;o1&&(this.diagram.realActions=this.diagram.realActions|$i.hScrollbarMoved,this.scrolled=!0),this.diagram.scrollSettings.horizontalOffset=t},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"verticalOffset",{get:function(){return this.vOffset},set:function(t){this.vOffset=t,Math.abs(this.vOffset-this.diagram.scrollSettings.verticalOffset)>1&&(this.diagram.realActions=this.diagram.realActions|$i.vScrollbarMoved,this.scrolled=!0),this.diagram.scrollSettings.verticalOffset=t},enumerable:!0,configurable:!0}),n.prototype.getBounds=function(){var e=this.diagram.spatialSearch.getPageBounds(0,0);return(e.x<0||e.y<0)&&!this.diagram.pageSettings.multiplePage?this.getPageBounds(void 0,void 0,!0,!0):this.getPageBounds(void 0,void 0,!0)},n.prototype.updateScrollOffsets=function(t,e){var i,r,s=this.getBounds();s.x*=this.currentZoom,s.y*=this.currentZoom,s.width*=this.currentZoom,s.height*=this.currentZoom,i=Math.max(0,t-s.left),r=Math.max(0,e-s.top),void 0!==t&&void 0!==e?(this.horizontalOffset=i,this.verticalOffset=r,this.diagram.setOffset(i,r)):this.diagram.setOffset(-this.horizontalOffset-s.x,-this.verticalOffset-s.y),this.transform={tx:Math.max(this.horizontalOffset,-s.left)/this.currentZoom,ty:Math.max(this.verticalOffset,-s.top)/this.currentZoom,scale:this.currentZoom}},n.prototype.setScrollOffset=function(t,e){this.scrolled=!1;var i=this.getBounds();i.x*=this.currentZoom,i.y*=this.currentZoom,i.width*=this.currentZoom,i.height*=this.currentZoom;var r=-i.left,s=-i.top,o=!1,a=this.viewPortWidth*this.currentZoom,l=this.viewPortHeight*this.currentZoom,h=r-t;if(h!==this.horizontalOffset){rh?this.horizontalOffset-=t:this.horizontalOffset=h,o=!0);var c=Math.max(i.right+this.vScrollSize,a);if(!o&&c<-h+this.viewPortWidth){var d=-h+a-this.vScrollSize,u=-this.horizontalOffset+a-this.vScrollSize;this.horizontalOffset=dd-u?h:-(i.right+this.vScrollSize-a),o=!0}o||(this.horizontalOffset=r-t)}o=!1;var f=s-e;if(f!==this.verticalOffset){sf?this.verticalOffset-=e:this.verticalOffset=f,o=!0);var p=Math.max(i.bottom+this.hScrollSize,l);if(!o&&p<-f+l){var g=-f+l-this.hScrollSize,v=-this.verticalOffset+l-this.hScrollSize;this.verticalOffset=gg-v?f:-(i.bottom+this.hScrollSize-l),o=!0}o||(this.verticalOffset=s-e)}this.transform={tx:Math.max(this.horizontalOffset,-i.left)/this.currentZoom,ty:Math.max(this.verticalOffset,-i.top)/this.currentZoom,scale:this.currentZoom},this.setSize()},n.prototype.getObjects=function(t,e){for(var i=[],r=0;r0){for(var l=0;l0){h.push(i[parseInt(o.toString(),10)].id);for(var d=0;d=e.bottom&&(l=0),-this.horizontalOffset<=e.x&&-this.horizontalOffset+this.viewPortWidth>=e.right&&(a=0),this.hScrollSize=a,this.vScrollSize=l;var h=this.diagramWidth,c=this.diagramHeight;this.diagramWidth=Math.max(e.right,-this.horizontalOffset+this.viewPortWidth-l)-i,this.diagramHeight=Math.max(e.bottom,-this.verticalOffset+this.viewPortHeight-a)-r,(h!==this.diagramWidth||c!==this.diagramHeight)&&"Diagram"!==this.diagram.scrollSettings.scrollLimit&&this.diagram.setSize(this.diagramWidth,this.diagramHeight),"Diagram"===this.diagram.scrollSettings.scrollLimit&&(h===this.diagramWidth&&c===this.diagramHeight&&1===this.currentZoom||this.diagram.diagramActions&&t&&(!this.diagram.diagramActions||!t||0===this.verticalOffset&&this.verticalOffset!==t.y||0===this.horizontalOffset&&this.horizontalOffset!==t.x)?t&&h===this.diagramWidth&&c===this.diagramHeight&&(this.diagram.diagramCanvas.scrollHeight>this.viewPortHeight&&t.y<0&&this.horizontalOffset===t.x&&0===this.verticalOffset||this.diagram.diagramCanvas.scrollWidth>this.viewPortWidth&&t.x<0&&this.verticalOffset===t.y&&0===this.horizontalOffset)&&(this.verticalOffset=t.y,this.horizontalOffset=t.x,this.transform={tx:Math.max(t.x,-e.left)/this.currentZoom,ty:Math.max(t.y,-e.top)/this.currentZoom,scale:this.currentZoom}):(this.diagram.scrollActions&da.Interaction&&t&&(this.transform={tx:Math.max(t.x,-e.left/this.currentZoom)/this.currentZoom,ty:Math.max(t.y,-e.top/this.currentZoom)/this.currentZoom,scale:this.currentZoom},this.horizontalOffset=t.x,this.verticalOffset=t.y),this.diagram.setSize(this.diagramWidth,this.diagramHeight),!(this.diagram.scrollActions&da.PropertyChange)&&t&&(this.horizontalOffset=t.x,this.verticalOffset=t.y,this.transform={tx:Math.max(t.x,-e.left)/this.currentZoom,ty:Math.max(t.y,-e.top)/this.currentZoom,scale:this.currentZoom}))),this.diagram.transformLayers(),this.diagram.element.style.overflow="hidden"},n.prototype.setViewPortSize=function(t,e){this.viewPortWidth=t,this.viewPortHeight=e},n.prototype.getPageBounds=function(t,e,i,r){var o,s=new Ne;if("Content"===e||r||null===this.diagram.pageSettings.width||null===this.diagram.pageSettings.height){var u=t?void 0:0;o=this.diagram.spatialSearch.getPageBounds(u,u)}else{var a=this.diagram.pageSettings.width,l=this.diagram.pageSettings.height,h=0,c=0;if(this.diagram.pageSettings.multiplePage){if((s=this.diagram.spatialSearch.getPageBounds(0,0)).right>a&&(a*=d=Math.ceil(s.right/a)),s.bottom>l&&(l*=d=Math.ceil(s.bottom/l)),s.left<0&&Math.abs(s.left)>h){var d=Math.ceil(Math.abs(s.left)/this.diagram.pageSettings.width);h=this.diagram.pageSettings.width*d}s.top<0&&Math.abs(s.top)>c&&(d=Math.ceil(Math.abs(s.top)/this.diagram.pageSettings.height),c=this.diagram.pageSettings.height*d)}o=new Ne(-h,-c,a+h,l+c)}if(i){var f=this.diagram.scrollSettings.padding;o.x-=f.left,o.y-=f.top,o.width+=f.left+f.right,o.height+=f.top+f.bottom}return o},n.prototype.getPageBreak=function(t){for(var e=0,i=0,r=-1,s=[],c=this.diagram.pageSettings.margin.left,d=this.diagram.pageSettings.margin.right,u=this.diagram.pageSettings.margin.top,f=this.diagram.pageSettings.margin.bottom,p=1,g=1;t.width>e;)(e+=this.diagram.pageSettings.width?this.diagram.pageSettings.width:t.width)===this.diagram.pageSettings.width&&(s[++r]={x1:t.left+c,y1:t.top+u,x2:t.left+c,y2:t.bottom-f}),ei;)(i+=this.diagram.pageSettings.height?this.diagram.pageSettings.height:t.height)===this.diagram.pageSettings.height&&(s[++r]={x1:t.left+c,y1:t.top+u,x2:t.right-d,y2:t.top+u}),i=this.diagram.scrollSettings.minZoom||l||t>=1)){this.currentZoom*=t;var c=this.getPageBounds(void 0,void 0,!0);c.x*=this.currentZoom,c.y*=this.currentZoom;var d=Bi();Yf(d,t,t,r.x,r.y),qB(d,e||0,i||0),mx(h,d);var u=Ke(h,{x:0,y:0});if(1===t&&(u=this.applyScrollLimit(u.x,u.y,s,o,a)),a=-c.y>=u.y&&-c.x>=u.x&&a,(this.diagram.scrollActions&da.PropertyChange||!(this.diagram.scrollActions&da.Interaction)||"Diagram"!==this.diagram.scrollSettings.scrollLimit||a)&&(this.transform={tx:Math.max(u.x,-c.left)/this.currentZoom,ty:Math.max(u.y,-c.top)/this.currentZoom,scale:this.currentZoom},this.horizontalOffset=u.x,this.verticalOffset=u.y),this.setSize(u),"SVG"!==this.diagram.mode&&Ds(this.diagram)&&this.diagram.scroller.virtualizeElements(),"SVG"!==this.diagram.mode&&!Ds(this.diagram)&&this.diagram.refreshDiagramLayer(),this.diagram.setOffset(-this.horizontalOffset-c.x,-this.verticalOffset-c.y),GI(this.diagram),this.diagram.views&&this.diagram.views.overview){var f=this.diagram.views.overview,p=f.scrollOverviewRect(f.parent.scroller.horizontalOffset,f.parent.scroller.verticalOffset,f.parent.scroller.currentZoom,!0);f.updateOverviewrect(-p.x,-p.y,p.width,p.height),f.updateView(f)}}}},n.prototype.fitToPage=function(t){var e=(t=t||{}).mode,i=t.region,r=t.margin||{},s=t.canZoomIn,o=t.customBounds,a=t.canZoomOut;r.bottom=r.bottom||25,r.top=r.top||25,r.left=r.left||25,r.right=r.right||25;var h,l=o,c=-this.horizontalOffset,d=-this.verticalOffset;if("PageSettings"===(i=i||"PageSettings")&&this.diagram.pageSettings.width&&this.diagram.pageSettings.height||this.diagram.nodes.length>0||this.diagram.connectors.length>0){e=e||"Page","CustomBounds"!==i&&(l=this.getPageBounds(!0,i,!0));var u={x:0,y:0};r.left+r.right>this.viewPortWidth&&(this.viewPortWidth<=100?(r.left=5,r.right=5):(r.left=25,r.right=25)),r.top+r.bottom>this.viewPortHeight&&(this.viewPortHeight<=100?(r.top=5,r.bottom=5):(r.top=25,r.bottom=25)),u.x=(this.viewPortWidth-(r.left+r.right))/l.width,u.y=(this.viewPortHeight-(r.top+r.bottom))/l.height,!s&&l.width-this.horizontalOffset-a+this.viewPortWidth&&(i=o.right-this.viewPortWidth,i+=20),o.x<-a&&(i=o.x),o.bottom>-l+this.viewPortHeight&&(r=o.bottom-this.viewPortHeight,r+=20),o.y<-l&&(r=o.y),this.zoom(1,-this.horizontalOffset-i,-this.verticalOffset-r,null,void 0,e))},n.prototype.bringToCenter=function(t){var e=this.currentZoom,i=new Ne(t.x*e,t.y*e,t.width*e,t.height*e),r=i.x+i.width/2-this.viewPortWidth/2,s=i.y+i.height/2-this.viewPortHeight/2;this.zoom(1,-this.horizontalOffset-(r*=-1),-this.verticalOffset-(s*=-1),null)},n.prototype.applyScrollLimit=function(t,e,i,r,s){if("Infinity"===this.diagram.scrollSettings.scrollLimit&&void 0===i&&!r&&(t=-t,e=-e),"Infinity"!==this.diagram.scrollSettings.scrollLimit){var o=void 0;if("Limited"===this.diagram.scrollSettings.scrollLimit){var a=this.diagram.scrollSettings.scrollableArea;o=new Ne(a.x,a.y,a.width,a.height)}(o=o||(s?this.getPageBounds():this.getPageBounds(!0))).x*=this.currentZoom,o.y*=this.currentZoom,o.width*=this.currentZoom,o.height*=this.currentZoom,void 0!==i&&(t*=-1,e*=-1),r&&(t*=-1,e*=-1);var l=Math.max(o.right,this.viewPortWidth);if(!r&&!(t<=o.x&&(t+this.viewPortWidth>=o.right||t>=o.right-this.viewPortWidth)||t>=o.x&&t+this.viewPortWidth<=l))if(t>=o.x)t=Math.max(o.x,Math.min(t,t-(t+this.viewPortWidth-this.vScrollSize-l)));else{var h=o.right-this.viewPortWidth;t=Math.min(h,o.x)}var c=Math.max(o.bottom,this.viewPortHeight);r||e<=o.y&&e+this.viewPortHeight>=o.bottom||e>=o.y&&e+this.viewPortHeight<=c||(e>=o.y?e=Math.max(o.y,Math.min(e,e-(e+this.viewPortHeight-this.hScrollSize-c))):(h=o.bottom-this.viewPortHeight,e=Math.min(o.y,h))),t*=-1,e*=-1}return{x:t,y:e}},n}(),joe=function(){function n(t,e,i,r,s){this.objects=[],this.left=t,this.top=e,this.width=i,this.height=r,this.spatialSearch=s}return n.prototype.findQuads=function(t,e){null!=this.first&&this.first.isIntersect(t)&&this.first.findQuads(t,e),null!=this.second&&this.second.isIntersect(t)&&this.second.findQuads(t,e),null!=this.third&&this.third.isIntersect(t)&&this.third.findQuads(t,e),null!=this.fourth&&this.fourth.isIntersect(t)&&this.fourth.findQuads(t,e),this.objects.length>0&&e.push(this)},n.prototype.isIntersect=function(t){return!(this.left+this.widtht.right||this.top>t.bottom)},n.prototype.selectQuad=function(){for(var i,t=null,e=this;null!=e;)i=e.getQuad(t),e=i.source,t=i.target||t;return t},n.prototype.getQuad=function(t){var e=this.width/2,i=this.height/2;if(e>=1e3&&i>=1e3){var r=this.left+e,s=this.top+i;if(this.spatialSearch.childRight<=r){if(this.spatialSearch.childBottom<=s)return this.first||((o=new n(this.left,this.top,e,i,this.spatialSearch)).parent=this,this.first=o),{source:this.first};if(this.spatialSearch.childTop>=s)return this.third||((o=new n(this.left,s,e,i,this.spatialSearch)).parent=this,this.third=o),{source:this.third}}else if(this.spatialSearch.childLeft>=r){if(this.spatialSearch.childBottom<=s)return this.second||((o=new n(r,this.top,e,i,this.spatialSearch)).parent=this,this.second=o),{source:this.second};var o;if(this.spatialSearch.childTop>=s)return this.fourth||((o=new n(r,s,e,i,this.spatialSearch)).parent=this,this.fourth=o),{source:this.fourth}}}return this.objects.push(this.spatialSearch.childNode),{target:this}},n.prototype.isContained=function(){return this.spatialSearch.childLeft>=this.left&&this.spatialSearch.childRight<=this.left+this.width&&this.spatialSearch.childTop>=this.top&&this.spatialSearch.childBottom<=this.top+this.height},n.prototype.addIntoAQuad=function(t){var e={};this.spatialSearch.setCurrentNode(t);for(var i=null;!e.isAdded;)i=(e=this.spatialSearch.parentQuad.add(i)).quad;return i},n.prototype.add=function(t){if(t=null,this.isContained())return{isAdded:!0,quad:t=this.selectQuad()};var e=void 0,i=!(0!==this.objects.length||this.first||this.second||this.third||this.fourth),r=2*this.width,s=2*this.height;return this.spatialSearch.childLeft=this.childLeft?(this.pageLeft=this.childLeft,this.leftElement=t,r=!0):t===this.leftElement&&(this.pageLeft=Number.MAX_VALUE,this.findLeft(this.parentQuad),r=!0)),(this.pageTop!==this.childTop||t!==this.topElement)&&(this.pageTop>=this.childTop?(this.pageTop=this.childTop,this.topElement=t,r=!0):t===this.topElement&&(this.pageTop=Number.MAX_VALUE,this.findTop(this.parentQuad),r=!0)),(this.pageBottom!==this.childBottom||t!==this.bottomElement)&&(this.pageBottom<=this.childBottom?(r=!0,this.pageBottom=this.childBottom,this.bottomElement=t):t===this.bottomElement&&(this.pageBottom=-Number.MAX_VALUE,this.findBottom(this.parentQuad),r=!0)),(this.pageRight!==this.childRight||t!==this.rightElement)&&(this.pageRight<=this.childRight?(this.pageRight=this.childRight,this.rightElement=t,r=!0):t===this.rightElement&&(this.pageRight=-Number.MAX_VALUE,this.findRight(this.parentQuad),r=!0)),r}return this.setCurrentNode(null),!1},n.prototype.isWithinPageBounds=function(t){return t.left>=this.pageLeft&&t.right<=this.pageRight&&t.top>=this.pageTop&&t.bottom<=this.pageBottom},n.prototype.findQuads=function(t){var e=[];return this.parentQuad.findQuads(t,e),e},n.prototype.findObjects=function(t){for(var i=[],r=0,s=this.findQuads(t);r=r.outerBounds.left&&(this.pageLeft=r.outerBounds.left,this.leftElement=r)}},n.prototype.findTop=function(t){t.first||t.second?(t.first&&this.findTop(t.first),t.second&&this.findTop(t.second)):(t.third&&this.findTop(t.third),t.fourth&&this.findTop(t.fourth));for(var e=0,i=t.objects;e=r.outerBounds.top&&(this.pageTop=r.outerBounds.top,this.topElement=r)}},n.prototype.setCurrentNode=function(t){if(this.childNode=t,t){var e=t.outerBounds;this.childLeft=Number(e.left),this.childTop=Number(e.top),this.childRight=Number(e.right),this.childBottom=Number(e.bottom)}else this.childLeft=Number.MAX_VALUE,this.childTop=Number.MAX_VALUE,this.childRight=-Number.MAX_VALUE,this.childBottom=-Number.MAX_VALUE},n.prototype.getPageBounds=function(t,e){if(this.pageLeft===Number.MAX_VALUE)return new Ne(0,0,0,0);var i=void 0!==t?Math.min(this.pageLeft,0):this.pageLeft,r=void 0!==e?Math.min(this.pageTop,0):this.pageTop;return new Ne(Math.round(i),Math.round(r),Math.round(this.pageRight-i),Math.round(this.pageBottom-r))},n.prototype.getQuad=function(t){return this.quadTable[t.id]},n}(),Voe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Yoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Voe(t,n),function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);r>3&&s&&Object.defineProperty(t,e,s)}([I(!1)],t.prototype,"preventDefaults",void 0),t}(Ee),Qoe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),JF=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Goe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qoe(t,n),JF([I("")],t.prototype,"action",void 0),JF([I("")],t.prototype,"cursor",void 0),t}(Ee),KF=function(){function n(){this.size=20,this.intermediatePoints=[],this.gridCollection=[],this.startArray=[],this.targetGridCollection=[],this.sourceGridCollection=[],this.considerWalkable=[]}return n.prototype.lineRouting=function(t){var e=t.connectors.length;if(this.renderVirtualRegion(t),e>0)for(var i=0;i=t.right||e.right<=t.left||e.top>=t.bottom||e.bottom<=t.top)},n.prototype.findEndPoint=function(t,e,i){var r,s;if(e&&""!==t.sourcePortID&&t.sourcePortWrapper||!e&&""!==t.targetPortID&&t.targetPortWrapper){s=zo(r=e?{x:t.sourcePortWrapper.offsetX,y:t.sourcePortWrapper.offsetY}:{x:t.targetPortWrapper.offsetX,y:t.targetPortWrapper.offsetY},void 0,e?t.sourceWrapper.bounds:t.targetWrapper.bounds);var o=e?t.sourcePortWrapper.bounds:t.targetPortWrapper.bounds;r=i?"Top"===s?{x:o.topCenter.x,y:o.topCenter.y}:"Left"===s?{x:o.middleLeft.x,y:o.middleLeft.y}:"Right"===s?{x:o.middleRight.x,y:o.middleRight.y}:{x:o.bottomCenter.x,y:o.bottomCenter.y}:{x:o.center.x,y:o.center.y}}else r=e&&this.startNode||!e&&this.targetNode?e?{x:this.startNode.wrapper.offsetX,y:this.startNode.wrapper.offsetY}:{x:this.targetNode.wrapper.offsetX,y:this.targetNode.wrapper.offsetY}:e?{x:t.sourcePoint.x,y:t.sourcePoint.y}:{x:t.targetPoint.x,y:t.targetPoint.y};return r},n.prototype.refreshConnectorSegments=function(t,e,i,r){var h,c,f,p,g,y,S,b,M,w,C,s=e.sourceID,o=e.targetID,a=e.sourcePortID,l=e.targetPortID;if(function Fre(n,t){var e=0;return n.constraints&qe.LineRouting?e=n.constraints&qe.LineRouting:n.constraints&qe.InheritLineRouting&&(e=t.constraints&nt.LineRouting),e}(e,t)||r){this.startNode=t.nameTable[""+s],this.targetNode=t.nameTable[""+o],this.intermediatePoints=[],this.startArray=[],this.targetGridCollection=[],this.sourceGridCollection=[],this.startGrid=void 0,this.targetGrid=void 0;for(var D=0;D0;){var L=this.startArray.pop();if(L){for(D=0;D1&&(e.segments=[]),this.updateConnectorSegments(t,this.intermediatePoints,this.gridCollection,e,i)){this.considerWalkable=[];break e}this.targetGridCollection.splice(this.targetGridCollection.indexOf(O),1),L=this.startArray.pop()}}L&&this.findPath(L)}}}},n.prototype.checkChildNodes=function(t,e){var i=!1,r=!1;if(t.nodeId.length>=1&&!e)for(var s=0;s1&&this.targetGridCollection[0].nodeId.length>1)for(var c=0;c<=1;c++){for(var d=this.targetGridCollection[parseInt(c.toString(),10)].gridX,u=this.targetGridCollection[parseInt(c.toString(),10)].gridY,f=this.targetGridCollection[parseInt(c.toString(),10)].nodeId,p=void 0,g=0;g=e.right&&t.top<=e.top&&t.bottom>=e.bottom},n.prototype.getEndvalue=function(t,e){return this.gridCollection[t.gridX][t.gridY].walkable?t:"left"===e?this.getEndvalue(this.gridCollection[t.gridX-1][t.gridY],e):"right"===e?this.getEndvalue(this.gridCollection[t.gridX+1][t.gridY],e):"top"===e?this.getEndvalue(this.gridCollection[t.gridX][t.gridY-1],e):"bottom"===e?this.getEndvalue(this.gridCollection[t.gridX][t.gridY+1],e):t},n.prototype.changeValue=function(t,e,i){t.walkable||this.considerWalkable.push(t);for(var r,s=0;s<=e;s++)"left"===i?r=this.gridCollection[t.gridX-s][t.gridY]:"right"===i?r=this.gridCollection[t.gridX+s][t.gridY]:"top"===i?r=this.gridCollection[t.gridX][t.gridY-s]:"bottom"===i&&(r=this.gridCollection[t.gridX][t.gridY+s]),r.walkable||this.considerWalkable.push(r)},n.prototype.getIntermediatePoints=function(t){var e;for(this.intermediatePoints=[];t;)this.intermediatePoints.push({x:t.gridX,y:t.gridY}),t=t.parent;this.intermediatePoints.reverse(),this.intermediatePoints.length>=1&&void 0!==this.intermediatePoints[0]&&void 0!==this.intermediatePoints[1]&&(this.intermediatePoints[0].x===this.intermediatePoints[1].x?this.intermediatePoints[0].yi.y&&o.y>s.y){for(var a=i.xi.x&&o.x>s.x)){for(var u=i.y=1&&u.length>1&&(g=u[u.length-2].x!==u[u.length-1].x?u[u.length-2].x>u[u.length-1].x?"Left":"Right":u[u.length-2].y>u[u.length-1].y?"Top":"Bottom"),M>=2&&v===g&&u.length>1&&u.splice(u.length-2,1),v=g);if(u&&u.length>1){for(var w=0;wD.x?S.bounds.middleLeft:S.bounds.middleRight),w===u.length-2&&""===r.targetPortID&&y&&(l=C.x>D.x?y.bounds.middleRight:y.bounds.middleLeft),0===w&&b&&(C.x=b.x,C.y=D.y=b.y,b=qa(r,0,b,Nl(S.bounds,_n(C.x>D.x?"Left":"Right")),!1),C.x=b.x),w===u.length-2&&l&&(w>0&&r.targetDecorator&&l.x-D.x<0&&Math.abs(l.x-C.x)0&&r.targetDecorator&&l.x-D.x>0&&Math.abs(l.x-C.x)D.y?S.bounds.topCenter:S.bounds.bottomCenter),w===u.length-2&&""===r.targetPortID&&y&&(l=C.y>D.y?y.bounds.bottomCenter:y.bounds.topCenter),0===w&&b&&(C.y=b.y,C.x=D.x=b.x,b=qa(r,0,b,Nl(S.bounds,_n(C.y>D.y?"Top":"Bottom")),!1),C.y=b.y),w===u.length-2&&l&&(w>0&&r.targetDecorator&&l.y-D.y<0&&Math.abs(l.y-C.y)0&&r.targetDecorator&&l.y-D.y>0&&Math.abs(l.y-C.y)D.x?(f="Left",p=C.x-D.x):(f="Right",p=D.x-C.x):C.y>D.y?(f="Top",p=C.y-D.y):(f="Bottom",p=D.y-C.y),o.push({type:"Orthogonal",length:p,direction:f})}}if(o&&o.length>0){var L=o[o.length-1];if(1===o.length&&(L.length-=20),L.length<10&&2===o.length&&(o.pop(),o.length>0&&(o[0].length-=20,L=o[0])),r.targetDecorator&&("Top"===L.direction||"Bottom"===L.direction)&&L.length>r.targetDecorator.height+1||("Right"===L.direction||"Left"===L.direction)&&L.length>r.targetDecorator.width+1)return r.segments=o,s&&t.connectorPropertyChange(r,{},{type:"Orthogonal",segments:o}),!0}return!1},n.prototype.findPath=function(t){for(var e,i=[],r=this.findNearestNeigbours(t,this.gridCollection,!0),s=0;sl)&&(e.x!==t.gridX||e.y!==t.gridY)&&(i.push(e),o.previousDistance=l,o.afterDistance=o.afterDistance||this.manhattan(Math.abs(e.x-this.targetGrid.gridX),Math.abs(e.y-this.targetGrid.gridY)),o.totalDistance=o.previousDistance+o.afterDistance,o.parent=t)}if(i.length>0)for(s=0;st?i*t+e:i*e+t},n.prototype.manhattan=function(t,e){return t+e},n.prototype.findNearestNeigbours=function(t,e,i){var r=[],s=t.parent;if(s){var o=(t.gridX-s.gridX)/Math.max(Math.abs(t.gridX-s.gridX),1),a=(t.gridY-s.gridY)/Math.max(Math.abs(t.gridY-s.gridY),1);0!==o?(this.isWalkable(t.gridX,t.gridY-1,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX][t.gridY-1])&&r.push(e[t.gridX][t.gridY-1]),this.isWalkable(t.gridX,t.gridY+1,!0)&&this.sourceGridCollection.indexOf(e[t.gridX][t.gridY+1])&&r.push(e[t.gridX][t.gridY+1]),this.isWalkable(t.gridX+o,t.gridY,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX+o][t.gridY])&&r.push(e[t.gridX+o][t.gridY])):0!==a&&(this.isWalkable(t.gridX-1,t.gridY,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX-1][t.gridY])&&r.push(e[t.gridX-1][t.gridY]),this.isWalkable(t.gridX+1,t.gridY,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX+1][t.gridY])&&r.push(e[t.gridX+1][t.gridY]),this.isWalkable(t.gridX,t.gridY+a,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX][t.gridY+a])&&r.push(e[t.gridX][t.gridY+a]))}else this.neigbour(t,"top",r,i),this.neigbour(t,"right",r,i),this.neigbour(t,"bottom",r,i),this.neigbour(t,"left",r,i);return r},n.prototype.neigbour=function(t,e,i,r){for(var o,s=1;s>0;){var a="top"===e||"bottom"===e?t.gridX:"left"===e?t.gridX-s:t.gridX+s,l="right"===e||"left"===e?t.gridY:"top"===e?t.gridY-s:t.gridY+s;if((o=this.gridCollection[parseInt(a.toString(),10)][parseInt(l.toString(),10)])&&(r&&-1===this.sourceGridCollection.indexOf(o)||!r&&-1===this.targetGridCollection.indexOf(o)))return i&&this.isWalkable(a,l)&&i.push(o),s;if(!(a>0&&l>0))break;s++}return null},n.prototype.resetGridColl=function(t,e,i){for(var s,r=1;r>0;){var o="top"===e||"bottom"===e?t.gridX:"left"===e?t.gridX-r:t.gridX+r,a="right"===e||"left"===e?t.gridY:"top"===e?t.gridY-r:t.gridY+r;if((s=this.gridCollection[parseInt(o.toString(),10)][parseInt(a.toString(),10)])&&(i&&-1===this.sourceGridCollection.indexOf(s)||!i&&-1===this.targetGridCollection.indexOf(s))){if(this.isWalkable(o,a))break;var l=this.gridCollection[parseInt(o.toString(),10)][parseInt(a.toString(),10)];this.considerWalkable.push(l)}if(!(o>0&&a>0))break;"top"===e||"left"===e?r--:r++}return null},n.prototype.isWalkable=function(t,e,i){if(t>=0&&t=0&&e0?1:-1,this.isWalkable(h,c-1)&&!this.isWalkable(h-a,c-1)||this.isWalkable(h,c+1)&&!this.isWalkable(h-a,c+1)))return{x:t,y:e};if(0!==l){if(l=l>0?1:-1,this.isWalkable(h-1,c)&&!this.isWalkable(h-1,c-l)||this.isWalkable(h+1,c)&&!this.isWalkable(h+1,c-l))return{x:t,y:e};if(this.findIntermediatePoints(h+1,c,h,c,s,o)||this.findIntermediatePoints(h-1,c,h,c,s,o))return{x:t,y:e}}return this.findIntermediatePoints(h+a,c+l,h,c,s,o)},n.prototype.destroy=function(){},n.prototype.getModuleName=function(){return"LineRouting"},n}(),Xoe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),$oe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Xoe(t,n),function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);r>3&&s&&Object.defineProperty(t,e,s)}([I(!0)],t.prototype,"inversedAlignment",void 0),t}(Ee),Zoe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Oe=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},wT=function(n,t,e,i){return new(e||(e=Promise))(function(r,s){function o(h){try{l(i.next(h))}catch(c){s(c)}}function a(h){try{l(i.throw(h))}catch(c){s(c)}}function l(h){h.done?r(h.value):new e(function(c){c(h.value)}).then(o,a)}l((i=i.apply(n,t||[])).next())})},CT=function(n,t){var i,r,s,o,e={label:0,sent:function(){if(1&s[0])throw s[1];return s[1]},trys:[],ops:[]};return o={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function a(h){return function(c){return function l(h){if(i)throw new TypeError("Generator is already executing.");for(;e;)try{if(i=1,r&&(s=2&h[0]?r.return:h[0]?r.throw||((s=r.return)&&s.call(r),0):r.next)&&!(s=s.call(r,h[1])).done)return s;switch(r=0,s&&(h=[2&h[0],s.value]),h[0]){case 0:case 1:s=h;break;case 4:return e.label++,{value:h[1],done:!1};case 5:e.label++,r=h[1],h=[0];continue;case 7:h=e.ops.pop(),e.trys.pop();continue;default:if(!(s=(s=e.trys).length>0&&s[s.length-1])&&(6===h[0]||2===h[0])){e=0;continue}if(3===h[0]&&(!s||h[1]>s[0]&&h[1]0&&((!s.style||!s.style.fill)&&(o.style.fill="transparent"),(!s.style||!s.style.strokeColor)&&(o.style.strokeColor="transparent")),s.shape&&"UmlActivity"===s.shape.type&&$I(s,o),s.shape&&"SwimLane"===s.shape.type&&sF(s,o),r.nodeDefaults&&Ro(o,s,r.nodeDefaults),r.updateAnnotationText(o.annotations);if(e&&e.connectors)for(a=0;e&&e.connectors&&a0&&0===i.nodes.length)this.clearCollection(),a=!0;else{for(var g=0,v=Object.keys(e.nodes);g0&&0===i.connectors.length)this.clearCollection(!0),a=!0;else{for(var C=0,D=Object.keys(e.connectors);C0){this.renderSelector(!0);break}if(e.selectedItems.constraints){this.renderSelector(!0);break}break;case"snapSettings":this.updateSnapSettings(e);break;case"commandManager":this.initCommands();break;case"layout":o=!0;break;case"segmentThumbShape":this.updateSelector();break;case"dataSourceSettings":this.clear(),"None"===this.layout.type?a=!0:(this.initObjects(),o=!0);break;case"tooltip":e3(this);break;case"rulerSettings":this.updateRulerSettings(e);break;case"layers":this.updateLayer(e);break;case"scrollSettings":this.scrollActions|=da.PropertyChange,this.updateScrollSettings(e),this.scrollActions&=~da.PropertyChange,this.scrollSettings.horizontalOffset=-this.scroller.horizontalOffset||0,this.scrollSettings.verticalOffset=-this.scroller.verticalOffset||0;break;case"locale":e.locale!==i.locale&&(this.realActions|=$i.PreventDataInit,n.prototype.refresh.call(this),this.realActions&=~$i.PreventDataInit);break;case"contextMenuSettings":if(void 0!==e.contextMenuSettings.showCustomMenuOnly&&(this.contextMenuSettings.showCustomMenuOnly=e.contextMenuSettings.showCustomMenuOnly),void 0!==e.contextMenuSettings.show&&(this.contextMenuSettings.show=e.contextMenuSettings.show),e.contextMenuSettings.items){for(var A=e.contextMenuSettings.items,x=0,P=Object.keys(A);x0){for(var N=[],T=O.ports.length-1;T>=0;T--)"LineDistribution"===O.ports[parseInt(T.toString(),10)].id.split("_")[1]&&N.push(O.ports[parseInt(T.toString(),10)]);this.removePorts(O,N)}}for(T=0;T0)for(var ue=0,fe=Object.keys(e.nodes);ue0)for(var De=0,xe=Object.keys(e.connectors);De=0;o--)this.commandHandler.expandNode(r[parseInt(o.toString(),10)],this,0!==o);this.canLayout&&this.doLayout(),this.lineRoutingModule?this.connectors.sourceID!==this.connectors.targetID&&this.lineRoutingModule.lineRouting(this):this.constraints&nt.LineRouting&&console.warn('[WARNING] :: Module "LineRouting" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),this.validatePageSize(),this.renderPageBreaks(),this.diagramRenderer.renderSvgGridlines(this.snapSettings,Fd(this.element.id),this.scroller.transform,this.rulerSettings,this.hRuler,this.vRuler),this.commandHandler.initSelectorWrapper(),this.notify("initial-load",{}),this.trigger("load"),this.scroller.setSize(),this.scroller.updateScrollOffsets(),this.isRefreshed||this.refreshDiagramLayer(),(this.scrollSettings.verticalOffset>0||this.scrollSettings.horizontalOffset>0)&&this.updateScrollOffset(),X.isDevice&&(this.tool=ri.ZoomPan|ri.SingleSelect),this.notify("initial-end",{}),this.isProtectedOnChange=!1,this.tooltipObject=e3(this),this.diagramActions=ee.Render,this.initCommands();var a=document.getElementsByClassName(this.element.id+"_hiddenUserHandleTemplate");(function yoe(n,t,e,i){var r,s,o,a,l,d=document.getElementById(i).ej2_instances[0];if(n&&t){r=FF(n);for(var u=0,f=e.userHandles;u0;)e[0].parentNode.removeChild(e[0]);var i=document.getElementById(this.element.id+"content");i&&this.element.removeChild(i);var r="measureElement";if(window[""+r]){window[""+r].usageCount-=1;var s="measureElementCount";window[""+s]--,0===window[""+s]&&(window[""+r].parentNode.removeChild(window[""+r]),window[""+r]=null)}}window.domTable={};for(var a=0;a1&&(this.callBlazorModel=!1,this.insertBlazorDiagramObjects(this.selectedItems),this.commandHandler.group(),this.callBlazorModel=!0,this.commandHandler.getBlazorOldValues())},t.prototype.unGroup=function(){this.callBlazorModel=!1,this.insertBlazorDiagramObjects(this.selectedItems),this.commandHandler.unGroup(),this.callBlazorModel=!0,this.commandHandler.getBlazorOldValues()},t.prototype.sendToBack=function(){this.commandHandler.sendToBack()},t.prototype.setActiveLayer=function(e){var i=this.commandHandler.getLayer(e);this.activeLayer=i},t.prototype.addLayer=function(e,i){this.commandHandler.addLayer(e,i)},t.prototype.removeLayer=function(e){this.commandHandler.removeLayer(e,ce())},t.prototype.moveObjects=function(e,i){$(this.layers),this.enableServerDataBinding(!1),this.commandHandler.moveObjects(e,i)},t.prototype.layerObjectUpdate=function(){},t.prototype.sendLayerBackward=function(e){this.layerObjectUpdate(),this.commandHandler.sendLayerBackward(e)},t.prototype.bringLayerForward=function(e){this.layerObjectUpdate(),this.commandHandler.bringLayerForward(e)},t.prototype.cloneLayer=function(e){this.commandHandler.cloneLayer(e)},t.prototype.bringToFront=function(){this.commandHandler.bringToFront()},t.prototype.moveForward=function(){this.commandHandler.sendForward()},t.prototype.sendBackward=function(){this.commandHandler.sendBackward()},t.prototype.getObject=function(e){return this.nameTable[""+e]},t.prototype.getNodeObject=function(e){return $(this.nameTable[""+e])},t.prototype.getConnectorObject=function(e){return $(this.nameTable[""+e])},t.prototype.getActiveLayer=function(){return this.activeLayer},t.prototype.nudgeCommand=function(e,i,r){if("object"!=typeof e&&(this.selectedItems.nodes.length||this.selectedItems.connectors.length)>0){var s=void 0;i.type&&"KEYDOWN"===i.type&&(s=i.type),this.nudge(e,void 0,void 0,s)}},t.prototype.nudge=function(e,i,r,s){var o=0,a=0;"Left"===e||"Right"===e?o=("Left"===e?-1:1)*(i||1):a=("Up"===e?-1:1)*(r||1),"KEYDOWN"===s&&(o*=5,a*=5);var h=this.selectedItems,c=this.selectedItems.wrapper.children[0];if(c instanceof ai)this.commandHandler.labelDrag(h.nodes[0],c,o,a);else{var d=$(this.selectedItems);this.protectPropertyChange(!0),this.drag(h,o,a),this.protectPropertyChange(!1);var u={type:"PositionChanged",redoObject:$(this.selectedItems),undoObject:d,category:"Internal"};this.addHistoryEntry(u)}this.refreshCanvasLayers()},t.prototype.insertBlazorDiagramObjects=function(e){},t.prototype.drag=function(e,i,r){if(this.insertBlazorDiagramObjects(e),!(this.bpmnModule&&e instanceof te&&this.bpmnModule.updateAnnotationDrag(e,this,i,r))){if(e instanceof ei){if(this.preventConnectorsUpdate=!0,e.nodes&&e.nodes.length){for(var o=0,a=e.nodes;o0&&o.nodes[0].children){this.fromUndo||(this.rotateUsingButton=!0);for(var h=this.commandHandler.getAllDescendants(o.nodes[0],[]),c=0;c0&&o.nodes[0].children){var g={type:"RotationChanged",redoObject:$(e),undoObject:$(o),category:"Internal",childTable:a};this.commandHandler.addHistoryEntry(g),this.commandHandler.updateSelector()}return u},t.prototype.dragSourceEnd=function(e,i,r){this.insertBlazorDiagramObjects(e),this.commandHandler.dragSourceEnd(e,i,r),this.callBlazorModel&&this.commandHandler.getBlazorOldValues()},t.prototype.dragTargetEnd=function(e,i,r){this.insertBlazorDiagramObjects(e),this.commandHandler.dragTargetEnd(e,i,r),this.callBlazorModel&&this.commandHandler.getBlazorOldValues()},t.prototype.findObjectsUnderMouse=function(e,i){return this.eventHandler.findObjectsUnderMouse(e,i)},t.prototype.findObjectUnderMouse=function(e,i,r){return this.eventHandler.findObjectUnderMouse(e,i,r)},t.prototype.findTargetObjectUnderMouse=function(e,i,r,s,o){return this.eventHandler.findTargetUnderMouse(e,i,r,s,o)},t.prototype.findElementUnderMouse=function(e,i,r,s){return this.eventHandler.findElementUnderMouse(e,i,r,s)},t.prototype.findActionToBeDone=function(e,i,r,s){return this.eventHandler.findActionToBeDone(e,i,r,s)},t.prototype.updateConnectorPort=function(e){if(e.ports.length)for(var i=void 0,r=0,s=e.ports;r=0;s--)if(i.push(r[parseInt(s.toString(),10)]),i.length>this.historyManager.stackLimit)return i}else i=r;return i},t.prototype.getEdges=function(e){return e.outEdge?this.nameTable[e.id].outEdges:this.nameTable[e.id].inEdges},t.prototype.getParentId=function(e){return this.nameTable[""+e].parentId},t.prototype.addConnector=function(e){return this.add(e)},t.prototype.UpdateBlazorDiagramModelCollection=function(e,i,r,s){},t.prototype.UpdateBlazorDiagramModel=function(e,i,r,s){},t.prototype.UpdateBlazorLabelOrPortObjects=function(e,i,r,s){},t.prototype.addBlazorDiagramObjects=function(){},t.prototype.removeNodeEdges=function(e,i,r){var s=this.nameTable[""+e],o=r?s.outEdges:s.inEdges;if(o.length>0)for(var a=0;a0)){for(var c=0;c0))}this.removePortEdges(l,a.element.sourcePortID,a.element.id,h)}a.element.targetID&&this.removeNodeEdges(a.element.targetID,a.element.id,!1)}}this.diagramActions=this.diagramActions|ee.PublicMethod,e.id=e.id||Qe();var u=this.activeLayer;if(!a.cancel&&u&&!u.lock){if(u.objects.indexOf(e.id)<0&&!u.lock&&(u.visible||(u.visible=!0,this.dataBind()),u.objects.push(e.id)),ps(e)===de)(r=new de(this,"connectors",e,!0)).status="New",this.nameTable[r.targetID]&&"TextAnnotation"===this.nameTable[r.targetID].shape.shape&&(r.isBpmnAnnotationConnector=!0,r.constraints=r.constraints&~qe.Delete),Ro(r,e,this.connectorDefaults),this.connectors.push(r),this.initObject(r),!1===e.visible&&this.updateElementVisibility(r.wrapper,r,e.visible),this.updateEdges(r),this.insertBlazorConnector(r);else{if(Ro(r=new te(this,"nodes",e,!0),e,this.nodeDefaults),r.parentId=e.parentId?e.parentId:r.parentId,r.umlIndex=e.umlIndex,r.status="New",(o="TextAnnotation"===r.shape.shape)&&!e.isTextAnnotationCopied&&(r.inEdges=e.inEdges?e.inEdges:r.inEdges),this.nodes.push(r),this.initObject(r,u,void 0,i),o&&this.bpmnModule)for(c=0;c-1&&e.parentId&&this.nameTable[e.parentId]&&"UmlClassifier"===this.nameTable[e.parentId].shape.type){var g=this.nameTable[e.parentId];g.children.splice(r.umlIndex,0,r.id),g.wrapper.children.splice(r.umlIndex,0,r.wrapper),g.wrapper.measure(new me),g.wrapper.arrange(g.wrapper.desiredSize),this.updateDiagramObject(g)}}if(a={element:r,cause:this.diagramActions,diagramAction:this.getDiagramAction(this.diagramActions),state:"Changed",type:"Addition",cancel:!1},this.parentObject&&(a.parentId=this.parentObject.id),"helper"!==e.id&&!(this.diagramActions&ee.PreventCollectionChangeOnDragOver)&&this.triggerEvent(Ce.collectionChange,a),!(this.diagramActions&ee.UndoRedo||this.diagramActions&ee.Group||this.diagramActions&ee.PreventHistory)){var v={type:"CollectionChanged",changeType:"Insert",undoObject:$(e),redoObject:$(e),category:"Internal"};this.addHistoryEntry(v)}this.parentObject=void 0,"SVG"===this.mode&&(this.updateSvgNodes(r),this.updateTextElementValue(r),this.updateDiagramObject(r),o&&this.updateDiagramObject(this.nameTable[r.inEdges[0]]),r.shape.activity&&r.shape.activity.subProcess.processes&&r.shape.activity.subProcess.processes.length&&this.updateProcesses(r),this.updateBridging())}}if(this.protectPropertyChange(s),this.resetDiagramActions(ee.PublicMethod),r&&this.layers.length>1&&this.moveNode(r),this.views)for(var S=0,b=this.views;S=0;l--)this.moveSvgNode(a[parseInt(l.toString(),10)])}for(var h=0,c=i;h=0;o--)r[parseInt(o.toString(),10)]===e.id&&r.splice(o,1);for(var a=0;s.ports&&a=0;s--)if(i=this.nameTable[r[parseInt(s.toString(),10)]])if(this.connectorTable[i.id]=$(i),i.isBpmnAnnotationConnector){var o=this.nameTable[i.targetID];this.removeObjectsFromLayer(i);var a=this.connectors.indexOf(i);-1!==a&&this.connectors.splice(a,1),this.removeElements(i),this.removeFromAQuad(i),delete this.nameTable[i.id];var l=this.nameTable[i.sourceID];if(l){var h=l.outEdges.indexOf(i.id);-1!==h&&l.outEdges.splice(h,1)}e.id!==i.targetID&&this.remove(o)}else this.remove(i)},t.prototype.removeObjectsFromLayer=function(e){if(e.children)for(var i=0;i-1&&(_r(this,e)&&this.unSelect(e),this.layers[parseInt(s.toString(),10)].objects.splice(a,1),delete this.layers[parseInt(s.toString(),10)].zIndexTable[this.nameTable[e.id].zIndex])},t.prototype.removeElements=function(e){if("SVG"===this.mode||"Canvas"===this.mode&&"Native"===e.shape.type){var i=xt(e.id+"_groupElement",this.element.id),r=e;if(r.ports&&r.ports.length>0)for(var s=0;s0){l[parseInt(s.toString(),10)].id.indexOf("icon_content")>0&&"SVG"===this.mode&&((h=xt(l[parseInt(s.toString(),10)].id+"_shape_groupElement",this.element.id))&&h.parentNode.removeChild(h),(h=xt(l[parseInt(s.toString(),10)].id+"_rect_groupElement",this.element.id))&&h.parentNode.removeChild(h));for(var c=0,d=this.views;c=0;o--)a.children[parseInt(o.toString(),10)].children&&(l=n.nameTable[a.children[parseInt(o.toString(),10)].id])&&(l.isLane?Gv(n,l):(n.removeDependentConnector(l),n.diagramActions|=ee.PreventHistory,l.constraints&ie.Delete?n.remove(l):U3(n,l,{},!1),n.diagramActions&=~ee.PreventHistory));a&&(i=n.nameTable[a.id])&&Gv(n,i)}}(this,e),!(this.diagramActions&ee.UndoRedo||this.diagramActions&ee.PreventHistory)&&(e instanceof te||e instanceof de)){var o={type:"CollectionChanged",changeType:"Remove",undoObject:$(e),redoObject:$(e),category:"Internal"};this.diagramActions&ee.Clear||e.children&&!e.isLane&&!e.isPhase&&e.children.length>0&&this.undoRedoModule&&"None"===this.layout.type&&(this.historyManager.startGroupAction(),s=!0),(e instanceof te||e instanceof de)&&this.deleteDependentConnector&&this.removeDependentConnector(e),!e.isLane&&!e.isPhase&&!(this.diagramActions&ee.Clear)&&!this.isStackChild(e)&&this.addHistoryEntry(o)}"TextAnnotation"===e.shape.shape&&this.removeDependentConnector(e),e.children&&!e.isLane&&!e.isPhase&&(!(this.diagramActions&ee.UndoRedo)||!ce())&&this.deleteGroup(e),e.parentId&&(this.deleteChild(e,void 0,!0),this.nameTable[e.parentId]&&"UmlClassifier"===this.nameTable[e.parentId].shape.type&&(this.updateDiagramObject(this.nameTable[e.parentId]),this.updateConnectorEdges(this.nameTable[e.parentId])));var a=void 0;this.diagramActions=this.diagramActions|ee.PublicMethod;var l=this.nameTable[e.id];if(l instanceof te?("Bpmn"===l.shape.type&&this.bpmnModule&&this.bpmnModule.removeBpmnProcesses(l,this),(l.isLane||l.isPhase||"SwimLane"===l.shape.type)&&(h=l.isLane||l.isPhase?this.nameTable[l.parentId]:this.nameTable[l.id],l.isLane?B3(this,l,h):l.isPhase&&F3(this,l,h)),-1!==(a=this.nodes.indexOf(l))&&(this.crudDeleteNodes.push(this.nameTable[l.id]),this.nodes.splice(a,1),this.updateNodeEdges(l))):(-1!==(a=this.connectors.indexOf(l))&&(this.crudDeleteNodes.push(this.nameTable[l.id]),this.connectors.splice(a,1)),this.updateEdges(l),this.spliceConnectorEdges(e,!0),this.spliceConnectorEdges(e,!1)),!this.isServerUpdate&&!(this.blazorActions&on.GroupClipboardInProcess)&&this.commandHandler.getBlazorOldValues(),s&&this.historyManager.endGroupAction(),_r(this,l)&&this.unSelect(l),!l.isPhase){if(this.removeObjectsFromLayer(e),this.currentDrawingObject&&(this.currentDrawingObject.wrapper=void 0),delete this.nameTable[e.id],i.length>0&&i[0].id===l.id&&l.parentId){var h,d=this.nameTable[l.parentId];d&&d.isLane&&"SwimLane"===this.nameTable[d.parentId].shape.type&&H3(this,h=this.nameTable[d.parentId],d,l)}this.removeElements(l),this.updateBridging(),"SVG"!==this.mode&&this.refreshDiagramLayer(),this.diagramActions&ee.Clear||(this.removeFromAQuad(l),r={element:e,cause:this.diagramActions,diagramAction:this.getDiagramAction(this.diagramActions),state:"Changed",type:"Removal",cancel:!1},"helper"!==e.id&&this.triggerEvent(Ce.collectionChange,r),this.resetTool())}}}else if(i.length>0){this.undoRedoModule&&(this.historyManager.startGroupAction(),this.blazorActions|=on.GroupingInProgress,s=!0);for(var u=0;u=p.wrapper.bounds.width&&"Horizontal"===p.shape.orientation||this.selectedItems.wrapper.bounds.y<=p.wrapper.bounds.y+g&&this.selectedItems.wrapper.bounds.height>=p.wrapper.bounds.height-g&&"Vertical"===p.shape.orientation)&&(DI(p)||p.shape.lanes.length>1)&&this.remove(i[parseInt(u.toString(),10)])}}else this.remove(i[parseInt(u.toString(),10)])}s&&(this.blazorActions&=~on.GroupingInProgress,this.isServerUpdate=!0,this.commandHandler.getBlazorOldValues(),this.UpdateBlazorDiagramModelCollection(void 0,void 0,void 0,!0),this.historyManager.endGroupAction(),this.isServerUpdate=!1),this.clearSelection()}e&&(DI(e)||this.diagramActions&ee.Clear)||this.diagramActions&ee.UndoRedo||this.diagramActions&ee.PreventHistory||!(e instanceof te||e instanceof de)||(o={type:"ConnectionChanged",undoObject:$(e),redoObject:$(e),category:"Internal"},!e.isLane&&!e.isPhase&&!(this.diagramActions&ee.Clear)&&!this.isStackChild(e)&&this.addHistoryEntry(o)),this.tooltipObject.close()},t.prototype.isStackChild=function(e){var i,r=this.nameTable[e.parentId];if(e&&e.parentId&&r.container&&"Stack"===r.container.type&&"UmlClassifier"!==this.nameTable[e.parentId].shape.type){i=!0;var s={sourceIndex:r.wrapper.children.indexOf(e.wrapper),source:e,target:void 0,targetIndex:void 0};this.diagramActions&ee.UndoRedo||this.addHistoryEntry({type:"StackChildPositionChanged",redoObject:{sourceIndex:void 0,source:e,target:void 0,targetIndex:void 0},undoObject:s,category:"Internal"})}return i},t.prototype.deleteChild=function(e,i,r){var s;if(s="string"==typeof e?e:e.id,(i=i?this.nameTable[i.id]:this.nameTable[e.parentId])&&i.children){for(var o=0;o=0;i--)this.removeLayer(this.layers[parseInt(i.toString(),10)].id);this.commandHandler.addLayer({id:"default_layer",visible:!0,lock:!1,objects:[],zIndex:0,objectZIndex:-1,zIndexTable:{}},null,!0),this.setActiveLayer(this.layers[this.layers.length-1].id)},t.prototype.clearObjects=function(e){var i=[];i=e||(i=i.concat(this.nodes)).concat(this.connectors),this.diagramActions=this.diagramActions|ee.Clear;for(var r=0,s=i;r0||"Text"===e.shape.type))if("Text"===e.shape.type)i=e.wrapper.children[0].id.split("_")[1];else for(var p=e.annotations.length-1;p>=0;p--)e.annotations[parseInt(p.toString(),10)].visibility&&(i=e.annotations[parseInt(p.toString(),10)].id);i&&(u=this.getWrapper(e.wrapper,i))}if(e&&u&&!(u instanceof es)&&(!function Qre(n,t){return"Text"===t.shape.type?t.constraints&ie.ReadOnly:t.constraints&(t instanceof de?qe.ReadOnly:ie.ReadOnly)?n.constraints&Nr.InheritReadOnly?1:0:n.constraints&Nr.ReadOnly?1:0}(u,e)||f)){var g=u.style,v=void 0;v=90>(v=u.bounds.width50?50:e.width,u.style.fontSize)),e.parentId&&"UmlClassifier"===this.nameTable[e.parentId].shape.type?(l.width=e.wrapper.bounds.width-20,c=(e.wrapper.bounds.center.x+r.tx)*r.scale-l.width/2*s-2.5,d=(e.wrapper.bounds.center.y+r.ty)*r.scale-l.height/2*s-3,u.style.textAlign="Left"):(l.width=Math.max(l.width,50),c=(u.bounds.center.x+r.tx)*r.scale-l.width/2*s-2.5,d=(u.bounds.center.y+r.ty)*r.scale-l.height/2*s-3),Ho(y,{id:this.element.id+"_editTextBoxDiv",style:"position: absolute;left:"+c+"px;top:"+d+"px;width:"+(l.width+1)*s+"px;height:"+l.height*s+"px; containerName:"+e.id+";"}),Ho(S,{"aria-label":a,id:this.element.id+"_editBox",style:"width:"+(l.width+1)*s+"px;height:"+l.height*s+"px;resize: none;outline: none;overflow: hidden;;font-family:"+g.fontFamily+";font-size:"+g.fontSize*s+"px;text-align:"+u.style.textAlign.toLocaleLowerCase()+";",class:"e-diagram-text-edit"}),S.style.fontWeight=g.bold?"bold":"",S.style.fontStyle=g.italic?"italic":"",S.style.lineHeight=(1.2*g.fontSize+"px;").toString(),S.style.textDecoration=g.textDecoration?g.textDecoration:"",this.activeLabel.parentId=e.id,this.activeLabel.id=i,u.visible=!1,this.updateDiagramObject(e),this.diagramActions=this.diagramActions|ee.TextEdit,this.isTriggerEvent||(E.add(S,"input",this.eventHandler.inputChange,this.eventHandler),E.add(S,"focusout",this.focusOutEdit,this),S.select())}}}},t.prototype.updateConnectorfixedUserHandles=function(e){if(e.fixedUserHandles.length)for(var i=void 0,r=0,s=e.fixedUserHandles;r0&&this.mindMapChartModule.updateLayout(o,this.nameTable,this.layout,l,this.dataSourceSettings.id,this.dataSourceSettings.root),e=!0;else if(this.radialTreeModule)this.radialTreeModule.updateLayout(o,this.nameTable,this.layout,l),e=!0;else if(this.symmetricalLayoutModule)this.symmetricalLayoutModule.maxIteration=this.layout.maxIteration,this.symmetricalLayoutModule.springLength=this.layout.springLength,this.symmetricalLayoutModule.springFactor=this.layout.springFactor,this.symmetricalLayoutModule.updateLayout(o,this.connectors,this.symmetricalLayoutModule,this.nameTable,this.layout,l),e=!0;else if(this.complexHierarchicalTreeModule){this.canDistribute(a,r)&&(this.lineDistributionModule.diagram=this,this.connectors.forEach(function(P){P.obstaclePointCollection=[]}));var c=this.complexHierarchicalTreeModule.getLayoutNodesCollection(this.nodes);c.length>0&&this.complexHierarchicalTreeModule.doLayout(c,this.nameTable,this.layout,l,this),e=!0,this.canDistribute(a,r)&&this.lineDistributionModule.initLineDistribution(this.layout,this)}else this.flowchartLayoutModule?(this.flowchartLayoutModule.updateLayout(this.nodes,this),e=!0):console.warn("[WARNING] :: Module "+("OrganizationalChart"===this.layout.type?"HierarchicalTree":this.layout.type)+" is not available in Diagram component! You either misspelled the module name or forgot to load it.");if(e){this.preventDiagramUpdate=!0;for(var u={},p=0,g=o;p0)for(var S=0;S0)for(var M=0;M0)for(var s=0,o=r.ports;s0&&function wse(n){var t,e,i,r=[];for(t=0;t0&&y.connectors[w].bezierSettings&&y.connectors[w].bezierSettings.allowSegmentsReset&&(y.connectors[w].segments=[]);if(t.connectors=y.connectors||[],t.dataSourceSettings=y.dataSourceSettings||{},t.dataSourceSettings.doBinding=i,t.height=y.height||"100%",t.setNodeTemplate=r,t.getConnectorDefaults=v,t.getNodeDefaults=g,t.getCustomProperty=o,t.mode=y.mode||"SVG",y.nodes)for(w=0;w0)){var r=this.nodes.filter(function(a){return 0===a.inEdges.length})[0],s=this.convertMindmapToMermaid(r,0);i.push(s),this.updateTextDataSource(i,r.outEdges,1),e=(i=i.filter(function(a){return""!==a.trim()})).join("\n")}return e},t.prototype.updateTextDataSource=function(e,i,r){for(var s=0;s0&&this.updateTextDataSource(e,h,r+1),s++}},t.prototype.convertMindmapToMermaid=function(e,i){var r=e.id,o=" ".repeat(2*(i+1)),a=e.annotations.length>0?e.annotations[0].content.replace(/\n/g," "):"",l=o+a,h=o+r;if(e.shape&&"Basic"===e.shape.type){var c=e.shape;"Rectangle"===c.shape?l=h+"["+a+"]":"Ellipse"===c.shape?l=h+"(("+a+"))":"Hexagon"===c.shape&&(l=h+"{{"+a+"}}")}else if(e.shape&&"Flow"===e.shape.type)"Terminator"===e.shape.shape&&(l=h+"("+a+")");else if(e.shape&&"Path"===e.shape.type){var u=e.shape;u.data===this.bangShape?l=h+"))"+a+"((":u.data===this.cloudShape&&(l=h+")"+a+"(")}return l},t.prototype.saveFlowDiagramInMermaidFormat=function(){var e=this,i=[],r="graph TD\n",s={nodes:this.nodes,edges:this.connectors};return s.nodes.reduce(function(a,l){return a[l.id]=l.annotations.length?l.annotations[0].content:"",a},{}),s.edges.forEach(function(a){var l=a.sourceID,h=a.targetID,f=e.nameTable[""+h],p=e.getNodeShape(e.nameTable[""+l]),g=e.getNodeShape(f),v=a.annotations[0]&&""!==a.annotations[0].content?"|"+a.annotations[0].content+"|":"";-1===i.indexOf(l)?i.push(l):p="",-1===i.indexOf(h)?i.push(h):g="";var y=e.arrowType(a);r+=" "+l+p+" "+y+v+" "+h+g+"\n"}),s.nodes.forEach(function(a){r+=" style "+a.id+" fill:"+a.style.fill+",stroke:"+a.style.strokeColor+",stroke-width:"+a.style.strokeWidth+"px;\n"}),r},t.prototype.arrowType=function(e){var i=e.targetDecorator.shape;return e.style.opacity<1?"~~~":""!==e.style.strokeDashArray?"-.->":"Arrow"===i?e.style.strokeWidth>1?"==>":"--\x3e":"None"===i?"---":"--\x3e"},t.prototype.getNodeShape=function(e){var i=e.annotations.length>0?e.annotations[0].content:"",r=e.shape.shape;if(!r){var s=e.shape.data;return"M 0 0 A 1 1 0 0 0 7 0 A 1 1 0 0 0 0 0 M -1 0 A 1 1 0 0 0 8 0 A 1 1 0 0 0 -1 0"===s?"((("+i+")))":"M 0 0 L 1 -1 L 5 -1 L 6 0 L 0 0"===s?"[/"+i+"\\]":"M 0 1 L 0 6 C 2 7 4 7 6 6 L 6 1 C 5 0 1 0 0 1 C 1 2 5 2 6 1"===s?"[("+i+")]":"M 0 0 L 12 0 L 14 2 L 2 2 L 0 0"===s?"[\\"+i+"\\]":"M 0 0 L 5 0 L 4 1 L 1 1 L 0 0"===s?"[\\"+i+"/]":"M 0 0 L 2 -2 L 11 -2 L 13 0 L 11 2 L 2 2 L 0 0"===s?"{{"+i+"}}":">"+i+"]"}switch(r){case"Terminator":return"(["+i+"])";case"Process":default:return"["+i+"]";case"Decision":return"{"+i+"}";case"Parallelogram":return"[/"+i+"/]";case"Ellipse":return"(("+i+"))";case"PreDefinedProcess":return"[["+i+"]]"}},t.prototype.loadDiagramFromMermaid=function(e){this.layout&&"Flowchart"===this.layout.type&&this.flowchartLayoutModule?this.convertMermaidToFlowChart(e):this.layout&&"MindMap"===this.layout.type&&this.mindMapChartModule?this.convertMermaidToMindmap(e):console.warn('[WARNING] :: Module "FlowchartLayout" or "MindMap" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.countLeadingSpaces=function(e){for(var i=0,r=e.length;i0});this.clear(),this.mermaidNodeBaseCollection=[];var r=[],s={text:"",children:[],currentLevel:0,branch:"Left"},o=[],l=!1,h=!1,c=!1;if(i.length>0){for(var d=function(M){var w=i[parseInt(M.toString(),10)],C=0,D="",A=u.countLeadingSpaces(w),x=w.includes('"`');if(h=w.includes('`"'),c=(l=!!x||l)||c?c:0===A&&M>0,l&&h&&!x)return s.text+="\n"+w,l=!1,"continue";if(!x&&l)return s.text+="\n"+w,"continue";if(l=!h&&l,w.length>0&&(/\s/.test(w[0])&&M>0||0===A)){if(-1!==o.findIndex(function(B){return B.space===A.toString()}))for(var L=o.length-1;L>=0;L--){var O=o[parseInt(L.toString(),10)];if((N=parseFloat(O.space))>A)o.splice(L,1);else{if(N=0;L--){var N,T=o[parseInt(L.toString(),10)];if(!((N=parseFloat(T.space))>A)){var z=o[o.length-1];o.push({space:A.toString(),level:z.level+1});break}o.splice(L,1)}C=o[o.length-1].level}D=w.trim().replace(/^[+-]/,"")}var U={text:D,branch:void 0,children:[],currentLevel:0===M?0:C-1};if(r.length>0){for(;r.length>=C&&0!==r.length;)r.pop();r.length>0&&r[r.length-1].children.push(U)}r.push(U),s=U},u=this,f=0;f0){var c=h[h.length-1];c.arrowType=a[2],""!==a[3]&&(c.label&&c.label.some(function(d){return d.trim().length>0})?c.label.push(a[3]):(c.label=[],c.label[c.parentId.length-1]=a[3]))}h.filter(function(d){return d.parentId&&0===d.parentId.length}).forEach(function(d){d.parentId=null}),i=i.concat(h)}}this.createFlowChart(i),this.doLayout(),this.clearHistory()},t.prototype.createFlowChart=function(e){for(var i=[],r=0;r1)for(var h=0;h|---|--\s*.*?\s*-->|~~~|==>|===|==\s*.*?\s*==>|\s*-\.\s*->|\s*-\.\s*-|\s*-\.\s*.*?\s*\.\s*->|\s*-\..*?\.\s*->)(.*)$/);if(l){i=l[1].trim();var h=l[2].trim();r=l[3].trim();var d=h.match(/(-\.|\\-\\-|==|--|~~)(.*?)(\1>|\.->|==>|\\->|~~>)/),u=void 0,f="";o=null!==(u=d?{text:d[2].trim()||null,arrowType:d[1]+d[3]}:{text:null,arrowType:h}).text?u.text:"",s=(f=u.arrowType).includes("--\x3e")?"single-line-arrow":f.includes("---")?"single-line":f.includes("==>")?"double-line-arrow":f.includes("==")?"double-line":f.includes("~~~")?"wiggly-arrow":f.includes("-.->")||f.includes(".->")?"dotted-arrow":f.includes("-.-")||f.includes(".-")?"dotted":"single-line-arrow"}return[i,r,s,o]},t.prototype.parseStyle=function(e,i){if(e.startsWith("style")){var s=e.match(/^style\s+(\w+)\s+fill:([^,]+),stroke:([^,]+),stroke-width:(\d+)px;/);if(s){var c={id:s[1],fill:s[2],stroke:s[3],strokeWidth:parseInt(s[4],10)},d=i.filter(function(u){return u.id===c.id});d[0].color=c.fill,d[0].stroke=c.stroke,d[0].strokeWidth=c.strokeWidth}}},t.prototype.getNodeData=function(e,i,r){for(var s=[],o=null,a=null,l=0,h="",c=function(v){var y=e[parseInt(v.toString(),10)],S=d.splitNested(y);if(S[0].includes("|")){var b=S[0].match(/\|([^|]*)\|/);b&&(h=b[1]);var M=S[0].split("|");M.length>=3&&(S[0]=M[2].trim())}var w=S[0].trim();if(0===v?o=w:a=w,i.find(function(L){return L.id===w}))l++;else{var D=S.length>1?S[1]:S[0],A=d.getShape(D),x=D.replace(/[\\[\]\\(\\)\\{\\}\\{\\}\\/>]/g,"");s.push({id:w,name:x,shape:A,color:"white",parentId:[]})}},d=this,u=0;u"===h?0===s?(r.trim().length>0&&i.push(r.trim()),r=h,o=h,s++):(r+=h,s++):"]"===h||"}"===h||")"===h?1===s&&h===o?(i.push((r+=h).trim()),r="",s--):s>1?(r+=h,s--):r+=h:r+=h}return r.trim().length>0&&i.push(r.trim()),i},t.prototype.getShape=function(e){var i={};return e.startsWith("(((")?i={type:"Path",data:"M 0 0 A 1 1 0 0 0 7 0 A 1 1 0 0 0 0 0 M -1 0 A 1 1 0 0 0 8 0 A 1 1 0 0 0 -1 0"}:e.startsWith("((")?i={shape:"Ellipse",type:"Basic"}:e.startsWith("([")?i={type:"Flow",shape:"Terminator"}:e.startsWith("(")?i={type:"Flow",shape:"Process"}:e.startsWith("[[")?i={type:"Flow",shape:"PreDefinedProcess"}:e.startsWith("[/")?i=e.endsWith("/]")?{type:"Basic",shape:"Parallelogram"}:{type:"Path",data:"M 0 0 L 1 -1 L 5 -1 L 6 0 L 0 0"}:e.startsWith("[(")?i={type:"Path",data:"M 0 1 L 0 6 C 2 7 4 7 6 6 L 6 1 C 5 0 1 0 0 1 C 1 2 5 2 6 1"}:e.startsWith("[\\")?i=e.endsWith("\\]")?{type:"Path",data:"M 0 0 L 12 0 L 14 2 L 2 2 L 0 0"}:{type:"Path",data:"M 0 0 L 5 0 L 4 1 L 1 1 L 0 0"}:e.startsWith("[")?i={type:"Basic",shape:"Rectangle"}:e.startsWith("{{")?i={type:"Path",data:"M 0 0 L 2 -2 L 11 -2 L 13 0 L 11 2 L 2 2 L 0 0"}:e.startsWith("{")?i={type:"Flow",shape:"Decision"}:e.startsWith(">")&&(i={type:"Path",data:"M 0 0 L 8 0 L 8 2 L 0 2 L 2 1 L 0 0"}),i},t.prototype.getDiagramContent=function(e){return this.printandExportModule?this.printandExportModule.getDiagramContent(e):(console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),"")},t.prototype.exportImage=function(e,i){this.printandExportModule?this.printandExportModule.exportImages(e,i):console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.printImage=function(e,i){this.printandExportModule?(i.printOptions=!0,this.printandExportModule.exportImages(e,i)):console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.setStackLimit=function(e){this.undoRedoModule&&e&&(this.historyManager.stackLimit=e,this.undoRedoModule.applyLimit(this.historyManager.currentEntry,e,this,!0))},t.prototype.clearHistory=function(){this.undoRedoModule&&this.undoRedoModule.clearHistory(this)},t.prototype.getDiagramBounds=function(){if(this.printandExportModule){var e=this.printandExportModule.getDiagramBounds("",{});return e.width=e.width>this.scrollSettings.viewPortWidth?e.width+(e.x>0?e.x:0):this.scrollSettings.viewPortWidth,e.height=e.height>this.scrollSettings.viewPortHeight?e.height+(e.y>0?e.y:0):this.scrollSettings.viewPortHeight,e.x=e.x>0?0:e.x,e.y=e.y>0?0:e.y,e}return console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),new Ne},t.prototype.exportDiagram=function(e){return this.printandExportModule?this.printandExportModule.exportDiagram(e):(console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),"")},t.prototype.print=function(e){this.printandExportModule?this.printandExportModule.print(e):console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.addPorts=function(e,i){var s;this.protectPropertyChange(!0),e=this.nameTable[e.id]||e,i.length>1&&this.startGroupAction();for(var o=function(h){if(e.ports.some(function(y){return y.id===i[parseInt(h.toString(),10)].id}))return"continue";if(e instanceof te?(s=new Es(e,"ports",i[parseInt(h.toString(),10)],!0),e.ports.push(s)):e instanceof de&&(s=new Tc(e,"ports",i[parseInt(h.toString(),10)],!0),e.ports.push(s)),e.children)for(var c=e.wrapper,d=0;d1&&this.endGroupAction(),e.wrapper.measure(new me(e.width,e.height)),e.wrapper.arrange(e.wrapper.desiredSize),this.updateDiagramObject(e),this.protectPropertyChange(!1)},t.prototype.addConstraints=function(e,i){return e|i},t.prototype.removeConstraints=function(e,i){return e&~i},t.prototype.addNodeLabels=function(e,i){this.addLabels(e,i)},t.prototype.addConnectorLabels=function(e,i){this.addLabels(e,i)},t.prototype.addLabels=function(e,i){this.protectPropertyChange(!0);var s,r=(e=this.nameTable[e.id]||e).wrapper;i.length>1&&this.startGroupAction();for(var o=0;o1&&this.endGroupAction(),e.wrapper.measure(new me(r.width,r.height)),e.wrapper.arrange(r.desiredSize),this.updateDiagramObject(e),this.protectPropertyChange(!1),this.refreshCanvasLayers()},t.prototype.addChildToUmlNode=function(e,i,r){var s,o,a,l,h="NoWrap";"Class"===e.shape.classifier||"Interface"===e.shape.classifier?"Method"===r?(o=new lm(e,"",i),"Class"===e.shape.classifier?(e.shape.classShape.methods.push(o),s=e.shape.classShape):"Interface"===e.shape.classifier&&(e.shape.interfaceShape.methods.push(o),s=e.shape.interfaceShape),function Qse(n,t,e,i){if(e.methods&&e.methods.length){var r=e.methods,s="",o="",a=void 0,l=1,h=void 0,c=0,d=0,u=n.shape,g="Class"===u.classifier?u.classShape:u.interfaceShape;1===r.length?g.attributes.length>0?(c=g.attributes.filter(function(w){return w.isSeparator}).length,h=(l=2+g.attributes.length+c)+1,rT(n,t,l)):h=l+1:(c=g.attributes.filter(function(w){return w.isSeparator}).length,d=g.methods.filter(function(w){return w.isSeparator}).length,h=(l=2+g.attributes.length+c+g.methods.length+d)+1);for(var v=0;v1&&this.startGroupAction();for(var r=i.length-1;r>=0;r--)if(e.children&&e.children.length>0){var s=e.wrapper.children.filter(function(o){return o.id===e.id+"group_container"});s&&s.length>0&&this.removelabelExtension(e,i,r,s[0])}else this.removelabelExtension(e,i,r,e.wrapper);i.length>1&&this.endGroupAction(),this.refreshCanvasLayers()},t.prototype.removePortsExtenion=function(e,i,r,s){for(var o=0;o1&&this.startGroupAction();for(var r=i.length-1;r>=0;r--)if(e.children&&e.children.length>0)for(var s=0;s1&&this.endGroupAction()},t.prototype.getSizeValue=function(e,i){var r;return r=e.toString().indexOf("px")>0?e.toString():e.toString().indexOf("%")>0?void 0!==i?"100%":e.toString():e.toString()+"px",i&&(Za(this),r="calc("+r+" - "+i+"px)"),r},t.prototype.renderRulers=function(){this.rulerSettings.showRulers?(function Vne(n){var t=Za(n),i=Tt("div",{id:n.element.id+"_overlapRuler",style:"height:"+t.height+"px;width:"+t.width+"px;position:absolute;left:0;top:0",class:"e-ruler-overlap"});n.element.insertBefore(i,n.element.firstChild)}(this),J3(this,!0),J3(this,!1)):Yx(this)},t.prototype.intOffPageBackground=function(){var e=new me;e=Za(this);var i=document.getElementById(this.element.id+"content"),r=this.getSizeValue(this.width,e.width),s=this.getSizeValue(this.height,e.height),o=this.rulerSettings.showRulers?"width:"+r+"; height:"+s+";top:"+e.height+"px;left:"+e.width+"px;overflow: scroll;position:absolute;overflow:auto;":"width:"+r+"; height:"+s+";position:absolute; left:0px; top:0px;overflow: auto;",a={id:this.element.id+"content",tabindex:"0",style:o};i?(this.diagramCanvas=i,Ka(this.diagramCanvas,o)):(this.diagramCanvas=Tt("div",a),this.element.appendChild(this.diagramCanvas)),this.diagramCanvas.style.background=this.backgroundColor},t.prototype.initDiagram=function(){this.intOffPageBackground(),Ho(this.element,{style:"width:"+this.getSizeValue(this.width)+"; height:"+this.getSizeValue(this.height)+";position:relative;overflow:hidden;"})},t.prototype.renderHiddenUserHandleTemplateLayer=function(e){var r=Tt("div",{class:this.element.id+"_hiddenUserHandleTemplate",style:"width:"+e.width+"px; height:"+e.height+"px;visibility:hidden ; overflow: hidden;"});this.element.appendChild(r)},t.prototype.renderBackgroundLayer=function(e,i){var r=this.createSvg(this.element.id+"_backgroundLayer_svg",e.width,e.height);Ka(r,i);var s=Fi("g",{id:this.element.id+"_backgroundImageLayer",class:"e-background-image-layer"});r.appendChild(s);var a=Fi("g",{id:this.element.id+"_backgroundLayer",class:"e-background-layer"});r.appendChild(a),this.diagramCanvas.appendChild(r)},t.prototype.renderGridLayer=function(e,i){var r=this.createSvg(this.element.id+"_gridline_svg",e.width,e.height);r.setAttribute("class","e-grid-layer");var s=Fi("g",{id:this.element.id+"_gridline"}),o=Fi("rect",{id:this.element.id+"_grid_rect",x:"0",y:"0",width:"100%",height:"100%"});if(rm()){var a=new URL(window.location.href);o.setAttribute("fill",""!==a.search?"url(#"+this.element.id+"_pattern)":"url("+location.protocol+"//"+location.host+location.pathname+"#"+this.element.id+"_pattern)")}else o.setAttribute("fill","url(#"+this.element.id+"_pattern)");s.appendChild(o),r.appendChild(s),this.diagramCanvas.appendChild(r),ti(r,{style:i})},t.prototype.renderDiagramLayer=function(e,i){if(this.diagramLayerDiv=Tt("div",{id:this.element.id+"_diagramLayer_div",style:"width:"+e.width+"px; height:"+e.height+"px;"+i}),"SVG"===this.mode){var s=this.createSvg(this.element.id+"_diagramLayer_svg",e.width,e.height);s.style["pointer-events"]="none",s.setAttribute("class","e-diagram-layer");var o=Fi("g",{id:this.element.id+"_diagramLayer"}),a=Fi("g",{});this.diagramLayer=o,s.style["pointer-events"]="all",a.appendChild(o),s.appendChild(a),this.diagramLayerDiv.appendChild(s)}else this.diagramLayer=bo.createCanvas(this.element.id+"_diagram",e.width,e.height),Ka(this.diagramLayer,"position:absolute;left:0px;top:0px;"),this.diagramLayerDiv.appendChild(this.diagramLayer);this.diagramCanvas.appendChild(this.diagramLayerDiv)},t.prototype.initLayers=function(){var e="position:absolute;top:0px;left:0px;overflow:hidden;pointer-events:none;",r=document.getElementById(this.element.id).getBoundingClientRect(),s=function moe(){var n=Tt("div",{style:"visibility:hidden; width: 100px"});document.body.appendChild(n);var t=n.getBoundingClientRect().width;n.style.overflow="scroll";var e=Tt("div",{style:"width:100%"});n.appendChild(e);var i=e.getBoundingClientRect().width;return n.parentNode.removeChild(n),t-i}();this.scroller.scrollerWidth=s,this.scroller.setViewPortSize(r.width,r.height),this.renderRulers();var o="measureElement";window[""+o]&&(window[""+o]=null,document.getElementById("measureElement").remove()),function RF(){var n="measureElement";if(window[""+n])window[""+n].usageCount+=1;else{var t=Tt("div",{id:"measureElement",style:"visibility:hidden ; height: 0px ; width: 0px; overflow: hidden;"}),e=Tt("span",{style:"display:inline-block ; line-height: normal"});t.appendChild(e);var i=Tt("img",{alt:"measureElementImage",src:"data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7"});t.appendChild(i);var r=document.createElementNS("http://www.w3.org/2000/svg","svg");r.setAttribute("xmlns:xlink","http://www.w3.org/1999/xlink"),t.appendChild(r);var s=document.createElementNS("http://www.w3.org/2000/svg","path");s.setAttribute("d",""),r.appendChild(s),document.createTextNode("");var a=document.createElementNS("http://www.w3.org/2000/svg","text");a.setAttributeNS("http://www.w3.org/XML/1998/namespace","xml:space","preserve"),r.appendChild(a),window[""+n]=t,window[""+n].usageCount=1,document.body.appendChild(t);var l="measureElementCount";window[""+l]?window[""+l]++:window[""+l]=1}}(),this.renderBackgroundLayer(r,e),this.renderGridLayer(r,e),this.renderDiagramLayer(r,e),this.renderHTMLLayer(r,e),this.renderPortsExpandLayer(r,e),this.renderNativeLayer(r,e),this.renderAdornerLayer(r,e),this.renderHiddenUserHandleTemplateLayer(r)},t.prototype.renderAdornerLayer=function(e,i){var r=Tt("div",{id:this.element.id+"_diagramAdornerLayer",style:"width:"+e.width+"px;height:"+e.height+"px;"+i}),s=Tt("div",{id:this.element.id+"_diagramUserHandleLayer",style:"width:"+e.width+"px;height:"+e.height+"px;"+i});s.setAttribute("class","e-userHandle-layer"),r.appendChild(s);var o=this.createSvg(this.element.id+"_diagramAdorner_svg",e.width,e.height);o.setAttribute("class","e-adorner-layer"),o.style["pointer-events"]="none",this.adornerLayer=Fi("g",{id:this.element.id+"_diagramAdorner"}),this.adornerLayer.style[" pointer-events"]="all",o.appendChild(this.adornerLayer),r.appendChild(o),this.diagramCanvas.appendChild(r);var a=Fi("g",{id:this.element.id+"_SelectorElement"});this.adornerLayer.appendChild(a),ti(o,{style:"pointer-events:none;"})},t.prototype.renderPortsExpandLayer=function(e,i){var r=this.createSvg(this.element.id+"_diagramPorts_svg",e.width,e.height);r.setAttribute("class","e-ports-expand-layer");var s=Fi("g",{id:this.element.id+"_diagramPorts",class:"e-ports-layer",style:"pointer-events: all;"});r.appendChild(s);var o=Fi("g",{id:this.element.id+"_diagramExpander",class:"e-expand-layer",style:"pointer-events: all;"});r.appendChild(o),this.diagramCanvas.appendChild(r),ti(r,{style:i})},t.prototype.renderHTMLLayer=function(e,i){this.htmlLayer=Tt("div",{id:this.element.id+"_htmlLayer",style:"width:"+e.width+"px; height:"+e.height+"px;position:absolute;top:0px;left:0px;overflow:hidden;pointer-events:none;",class:"e-html-layer"});var r=Tt("div",{id:this.element.id+"_htmlLayer_div",style:"position:absolute;top:0px;left:0px;pointer-events:all;"});this.htmlLayer.appendChild(r),this.diagramCanvas.appendChild(this.htmlLayer)},t.prototype.renderNativeLayer=function(e,i){var r=this.createSvg(this.element.id+"_nativeLayer_svg",e.width,e.height),s=Fi("g",{id:this.element.id+"_nativeLayer",style:"pointer-events:all;"});r.appendChild(s),this.diagramLayerDiv.appendChild(r),ti(r,{class:"e-native-layer",style:i})},t.prototype.createSvg=function(e,i,r){var s=document.createElementNS("http://www.w3.org/2000/svg","svg");return ti(s,{id:e,width:i,height:r}),s},t.prototype.updateBazorShape=function(){for(var e=0;e1,i=[],r={},s={},o=[],a=0,l=this.nodes;a0||b&&b.children&&b.children.length>0)&&(M=!1),S&&S.wrapper&&b&&b.wrapper&&M?this.initConnectors(r[""+h],p):i.push(r[""+h])}else b=r[y.targetID],(S=r[y.sourceID])&&S.children&&S.children.length>0||b&&b.children&&b.children.length>0?i.push(r[""+h]):this.initConnectors(r[""+h],p);else r[""+h].children?o.push(h):r[""+h].shape instanceof lT&&r[""+h].shape.activity.subProcess.processes&&r[""+h].shape.activity.subProcess.processes.length>0?s[r[""+h].id]=h:this.initNodes(r[""+h],p);if(this.bpmnModule)for(var w=0,C=this.bpmnModule.bpmnTextAnnotationConnector;w-1&&-1===r.indexOf(c)&&-1===s.indexOf(c)&&r.splice(0,0,c);-1===r.indexOf(o)&&s.push(o)}return r.concat(s)},t.prototype.addToLayer=function(e,i){var r;if(i&&(r=this.commandHandler.getObjectLayer(e.id)),(!i||!r)&&-1===this.activeLayer.objects.indexOf(e.id)&&this.activeLayer.objects.push(e.id),(e instanceof te||e instanceof de)&&("SwimLane"!==e.shape.type||e.children&&e.children.length>0)){if(e.parentId){var s=this.swimlaneZIndexTable[e.parentId],o=this.swimlaneChildTable[e.id];(s&&-1!==s||o&&-1!==o)&&(e.zIndex=this.swimlaneChildTable[e.id])}e instanceof de&&e.sourceID&&e.targetID?-1!==this.activeLayer.objects.indexOf(e.sourceID)&&-1!==this.activeLayer.objects.indexOf(e.targetID)&&this.setZIndex(r||this.activeLayer,e):this.setZIndex(r||this.activeLayer,e)}},t.prototype.updateLayer=function(e){for(var i=0,r=Object.keys(e.layers);i0)for(r=0;rs;l--)r.zIndexTable[parseInt(l.toString(),10)]=r.zIndexTable[l-1],this.nameTable[r.zIndexTable[parseInt(l.toString(),10)]]&&(this.nameTable[r.zIndexTable[parseInt(l.toString(),10)]].zIndex=l);r.zIndexTable[parseInt(a.toString(),10)]=i.id}}},t.prototype.initializeDiagramLayers=function(){for(var e=0;ethis.layers[parseInt(a.toString(),10)].zIndex&&(i=this.layers[parseInt(e.toString(),10)],this.layers[parseInt(e.toString(),10)]=this.layers[parseInt(a.toString(),10)],this.layers[parseInt(a.toString(),10)]=i);0===this.layers.length&&this.commandHandler.addLayer({id:"default_layer",visible:!0,lock:!1,objects:[],zIndex:0,objectZIndex:-1,zIndexTable:{}},null,!0),this.setActiveLayer(this.layers[this.layers.length-1].id)},t.prototype.resetTool=function(){this.eventHandler.resetTool()},t.prototype.initObjectExtend=function(e,i,r){if(r){var s=this.commandHandler.checkBoundaryConstraints(void 0,void 0,e.wrapper.bounds,!0);if("SwimLane"===e.shape.type)for(var o=0,a=Object.keys(i.zIndexTable);o0)&&this.setZIndex(i,e)),e instanceof te){if(r){if("helper"!==e.id&&(o=Zi(this.getNodeDefaults))){if((a=o(e,this))&&a.ports)for(var l=0;l0)for(l=0;l0&&!e.container||e.processId){var r=this.nameTable[e.id];if(!(this.realActions&$i.PreventScale||this.realActions&$i.PreventDrag)){if(r.offsetX&&(this.realActions&$i.EnableGroupAction||!(this.diagramActions&ee.UndoRedo||this.diagramActions&ee.ToolAction||this.diagramActions&ee.PublicMethod))){this.realActions|=$i.PreventScale;var s=r.offsetX-e.wrapper.offsetX;r.offsetX=e.wrapper.offsetX;var o=r.offsetY-e.wrapper.offsetY;r.offsetY=e.wrapper.offsetY,s+o!==0&&this.drag(r,s,o),this.realActions&=~$i.PreventScale}else r.offsetX=e.wrapper.offsetX;r.offsetY&&(this.realActions&$i.EnableGroupAction||!(this.diagramActions&ee.UndoRedo||this.diagramActions&ee.ToolAction||this.diagramActions&ee.PublicMethod))?(this.realActions|=$i.PreventScale,o=r.offsetY-e.wrapper.offsetY,r.offsetY=e.wrapper.offsetY,this.drag(r,0,o),this.realActions&=~$i.PreventScale):r.offsetY=e.wrapper.offsetY,this.diagramActions&&(r.width=e.wrapper.actualSize.width,r.height=e.wrapper.actualSize.height)}}i&&e.children&&e.children.length>0&&(void 0!==this.nameTable[e.id].width?this.scaleObject(e,this.nameTable[e.id].width,!0):this.nameTable[e.id].width=e.wrapper.actualSize.width,void 0!==this.nameTable[e.id].height?this.scaleObject(e,this.nameTable[e.id].height,!1):this.nameTable[e.id].height=e.wrapper.actualSize.height)},t.prototype.initNode=function(e,i,r){var a,f,s=e.initContainer(),o=new Mi;if(this.diagramSettings.inversedAlignment||(s.inversedAlignment=!1),s.children||(s.children=[]),e.children){s.measureChildren=!1,o.id=e.id+"group_container",o.style.fill=e.shape&&"SwimLane"===e.shape.type?e.style.fill:"none",o.style.strokeColor="none",o.horizontalAlignment="Stretch",o.verticalAlignment="Stretch",o.pivot=e.pivot,s.style=e.style,s.padding.left=e.padding.left,s.padding.right=e.padding.right,s.padding.top=e.padding.top,s.padding.bottom=e.padding.bottom,o.children=[],o.preventContainer=!0,e.container&&(o.relativeMode="Object");var l=!!(e.ports&&e.ports.length>0);if(m(e.container)&&!l&&s.children.push(o),e.container&&"Grid"===e.container.type)for(var h=0;h0&&e.wrapper.children[0]instanceof jv){if(this.setZIndex(this.activeLayer,e),this.connectors.length>0)for(h=0;h0?i.phases.length:0,v="Horizontal"===i.orientation,y=v?i.phases.length||1:s.length+1,S=v?(i.header&&i.hasHeader?1:0)+(i.phases.length>0?1:0)+i.lanes.length:(i.header&&i.hasHeader?1:0)+i.phases.length;if(0===h&&!v&&i.lanes.length&&(S+=1),v?(a=(i.header&&i.hasHeader?1:0)+(h>0?1:0),l=0):(a=i.header&&i.hasHeader?1:0,l=h>0?1:0),s.length>0)for(o+=i.header&&i.hasHeader?i.header.height:0,f=0;fl?d.margin.left=d.margin.left-(u.bounds.left-e.bounds.left):u.children[0].children[1].actualSize.width+r>=d.margin.left&&(d.margin.left=u.children[0].children[1].actualSize.width+r),d.margin.lefta?d.margin.top=d.margin.top-(u.bounds.top-o):u.children[0].children[1].actualSize.height+r>=d.margin.top&&(d.margin.top=u.children[0].children[1].actualSize.height+r),d.margin.left0)for(o=0;o0&&this.updateChildPosition(e)},t.prototype.addBpmnAnnotationConnector=function(e,i){if(e.parentObj instanceof t||e.parentObj instanceof Hd){var r=e.shape,o=""!==r.textAnnotation.textAnnotationTarget&&this.nameTable[r.textAnnotation.textAnnotationTarget],a=o?this.nameTable[r.textAnnotation.textAnnotationTarget]:null,l=null!=a?a.wrapper:null,h=e.ports[0],c={x:0,y:0};switch(r.textAnnotation.textAnnotationDirection){case"Left":h.offset={x:0,y:.5},c.x=i.bounds.left-40,c.y=i.bounds.bottom+30;break;case"Right":h.offset={x:1,y:.5},c.x=i.bounds.right+40,c.y=i.bounds.bottom+30;break;case"Top":h.offset={x:.5,y:0},c.x=i.bounds.right+30,c.y=i.bounds.top-40;break;case"Bottom":h.offset={x:.5,y:1},c.x=i.bounds.right+30,c.y=i.bounds.bottom+40;break;default:h.offset={x:0,y:.5},c.x=i.bounds.left-40,c.y=i.bounds.bottom+30,o&&null!=i&&null!=l&&(i.bounds.left>l.bounds.right?h.offset={x:0,y:.5}:i.bounds.rightl.bounds.top?h.offset={x:.5,y:0}:i.bounds.top0&&this.updateChildPosition(r)}},t.prototype.canExecute=function(){return!0},t.prototype.updateStackProperty=function(e,i,r){e.container&&"Stack"===e.container.type&&(i.width||(i.wrapper.horizontalAlignment="Stretch",i.horizontalAlignment="Stretch"),i.height||(i.verticalAlignment="Stretch",i.wrapper.verticalAlignment="Stretch"),r&&"UmlClassifier"===e.shape.type&&(i.umlIndex=r))},t.prototype.initViews=function(){this.isLoading||(this.views.push(this.element.id),this.views[this.element.id]=this)},t.prototype.initCommands=function(){var e=this.commandManager.commands,i={copy:{execute:this.copyCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.C,keyModifiers:ft.Control}},paste:{execute:this.pasteCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.V,keyModifiers:ft.Control}},cut:{execute:this.cutCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.X,keyModifiers:ft.Control}},delete:{execute:this.removeCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Delete}},selectAll:{execute:this.selectAll.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.A,keyModifiers:ft.Control}},undo:{execute:this.undo.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Z,keyModifiers:ft.Control}},redo:{execute:this.redo.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Y,keyModifiers:ft.Control}},nudgeUp:{execute:this.nudgeCommand.bind(this,"Up"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Up},parameter:"up"},nudgeRight:{execute:this.nudgeCommand.bind(this,"Right"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Right},parameter:"right"},nudgeDown:{execute:this.nudgeCommand.bind(this,"Down"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Down},parameter:"down"},nudgeLeft:{execute:this.nudgeCommand.bind(this,"Left"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Left},parameter:"left"},startEdit:{execute:this.startEditCommad.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.F2}},endEdit:{execute:this.endEditCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Escape}},focusToNextItem:{execute:this.navigateItems.bind(this,!0),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Tab}},focusToPreviousItem:{execute:this.navigateItems.bind(this,!1),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Tab,keyModifiers:ft.Shift}},selectFocusedItem:{execute:this.startEditCommad.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Enter}},bold:{execute:this.fontStyleCommand.bind(this,"bold"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.B,keyModifiers:ft.Control}},italic:{execute:this.fontStyleCommand.bind(this,"italic"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.I,keyModifiers:ft.Control}},underline:{execute:this.fontStyleCommand.bind(this,"underline"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.U,keyModifiers:ft.Control}},duplicate:{execute:this.duplicateCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.D,keyModifiers:ft.Control}},group:{execute:this.groupCommand.bind(this,"group"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.G,keyModifiers:ft.Control}},ungroup:{execute:this.groupCommand.bind(this,"ungroup"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.U,keyModifiers:ft.Control|ft.Shift}},rotateClockwise:{execute:this.rotateCommand.bind(this,"clockwise"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.R,keyModifiers:ft.Control}},rotateAntiClockwise:{execute:this.rotateCommand.bind(this,"antiClockwise"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.L,keyModifiers:ft.Control}},flipHorizontal:{execute:this.flipCommand.bind(this,"horizontal"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.H,keyModifiers:ft.Control}},flipVertical:{execute:this.flipCommand.bind(this,"vertical"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.J,keyModifiers:ft.Control}},pointerTool:{execute:this.toolCommand.bind(this,"pointer"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number1,keyModifiers:ft.Control}},textTool:{execute:this.toolCommand.bind(this,"text"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number2,keyModifiers:ft.Control}},connectTool:{execute:this.toolCommand.bind(this,"connect"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number3,keyModifiers:ft.Control}},freeForm:{execute:this.toolCommand.bind(this,"freeForm"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number5,keyModifiers:ft.Control}},lineTool:{execute:this.toolCommand.bind(this,"line"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number6,keyModifiers:ft.Control}},rectangleTool:{execute:this.toolCommand.bind(this,"rectangle"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number8,keyModifiers:ft.Control}},ellipseTool:{execute:this.toolCommand.bind(this,"ellipse"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number9,keyModifiers:ft.Control}},zoomIn:{execute:this.zoomCommand.bind(this,"zoomIn"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Plus,keyModifiers:ft.Control}},zoomOut:{execute:this.zoomCommand.bind(this,"zoomOut"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Minus,keyModifiers:ft.Control}},shiftUp:{execute:this.shiftCommand.bind(this,"Up"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Up,keyModifiers:ft.Shift}},shiftDown:{execute:this.shiftCommand.bind(this,"Down"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Down,keyModifiers:ft.Shift}},shiftLeft:{execute:this.shiftCommand.bind(this,"Left"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Left,keyModifiers:ft.Shift}},shiftRight:{execute:this.shiftCommand.bind(this,"Right"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Right,keyModifiers:ft.Shift}},alignTextCenter:{execute:this.alignCommand.bind(this,"center"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.C,keyModifiers:ft.Control|ft.Shift}},alignTextLeft:{execute:this.alignCommand.bind(this,"right"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.L,keyModifiers:ft.Control|ft.Shift}},alignTextRight:{execute:this.alignCommand.bind(this,"left"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.R,keyModifiers:ft.Control|ft.Shift}},alignTextTop:{execute:this.alignCommand.bind(this,"top"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.E,keyModifiers:ft.Control|ft.Shift}},alignTextCenterVertical:{execute:this.alignCommand.bind(this,"centerVertical"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.M,keyModifiers:ft.Control|ft.Shift}},alignTextBottom:{execute:this.alignCommand.bind(this,"bottom"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.V,keyModifiers:ft.Control|ft.Shift}},alignJustify:{execute:this.alignCommand.bind(this,"justify"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.J,keyModifiers:ft.Control|ft.Shift}},sendToBack:{execute:this.orderCommand.bind(this,"sendToBack"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.B,keyModifiers:ft.Control|ft.Shift}},bringToFront:{execute:this.orderCommand.bind(this,"bringToFront"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.F,keyModifiers:ft.Control|ft.Shift}},sendBackward:{execute:this.orderCommand.bind(this,"sendBackward"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.BracketLeft,keyModifiers:ft.Control}},bringForward:{execute:this.orderCommand.bind(this,"bringForward"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.BracketRight,keyModifiers:ft.Control}}};this.initCommandManager(e,i)},t.prototype.overrideCommands=function(e,i){for(var r,s=0,o=Object.keys(i);se.zIndex){("HTML"===e.shape.type||"Native"===e.shape.type)&&(o="HTML"===e.shape.type?"html":"native"),s=uoe(i,r[parseInt(a.toString(),10)].id,o);break}return s},t.prototype.updateDiagramObject=function(e,i,r){for(var s,o="domTable",a=0,l=this.views;a1&&(d=this.commandHandler.getObjectLayer(e.id)),void 0===d||d&&d.visible||r){var u=Io(this.element.id);window[""+o][s.element.id+"_diagramLayer"]||(window[""+o][s.element.id+"_diagramLayer"]=document.getElementById(s.element.id+"_diagramLayer"));var f=window[""+o][s.element.id+"_diagramLayer"];this.diagramActions&ee.Interactions&&this.updateCanupdateStyle(e.wrapper.children,!0);var p=this.getMidPoint(e);this.diagramRenderer.updateNode(e.wrapper,f,u,void 0,i?void 0:this.getZindexPosition(e,s.element.id),p,this.portCenterPoint),this.updateCanupdateStyle(e.wrapper.children,!0)}}},t.prototype.applyMarginBezier=function(e,i){i.cx=i.cx+e.margin.left,i.cx=i.cx-e.margin.right,i.cy=i.cy+e.margin.top,i.cy=i.cy-e.margin.bottom},t.prototype.getMidPoint=function(e){var i;if(e instanceof de&&"Bezier"===e.type){i=[];for(var r=this.getBezierPoints(e),s=R.getLengthFromListOfPoints(r),o=0;o0&&e.updateView(e));var s=Io(e.element.id);this.renderDiagramElements(e.diagramLayer,e.diagramRenderer,s,void 0,void 0,i);for(var o=0;o0&&this.renderBasicElement(e),!this.diagramActions||!(this.diagramActions&ee.Render)||ee.ToolAction&this.diagramActions||Ds(this)||1!==this.scroller.currentZoom?this.refreshElements(e):this.renderTimer||(this.renderTimer=setTimeout(function(){i.refreshElements(e)},40)))},t.prototype.updatePortVisibility=function(e,i,r){var s;if((e instanceof te||e instanceof de)&&(!this.drawingObject||!this.drawingObject.shape)&&ro(e)){for(var a=e.ports,l=!1,h=0;h=0&&this.scroller.removeCollection.splice(l,1);var h=this.nameTable[e[parseInt(a.toString(),10)]];this.updateTextElementValue(h),this.diagramRenderer.renderElement(h.wrapper,s,o,void 0,void 0,void 0,void 0,h.zIndex)}for(var c=0;c0?this.scroller.oldCollectionObjects:void 0,b=Object.keys(S||g.zIndexTable);b.sort(function(N,T){return parseInt(""+N,10)-parseInt(""+T,10)});for(var M=0,w=b;M0?h:0)+"px",y=(this.realActions&$i.vScrollbarMoved?0:-(this.scroller.verticalOffset<0?this.scroller.verticalOffset:0))+"px"):(v="0px",y="0px"),this.realActions&$i.hScrollbarMoved&&(this.realActions=this.realActions&~$i.hScrollbarMoved),this.realActions&$i.vScrollbarMoved&&(this.realActions=this.realActions&~$i.vScrollbarMoved)):(v=(l.x<0?h:-this.scroller.horizontalOffset)+"px",y=(l.y<0?c:-this.scroller.verticalOffset)+"px"),this.diagramLayer.style.left=v,this.diagramLayer.style.top=y,A.tx=-l.x/A.scale,A.ty=-l.y/A.scale);var P=!0;if(o&&(P=!1),this.updateTextElementValue(D),this.refreshing&&D.shape.activity&&D.shape.activity.subProcess&&D.shape.activity.subProcess.processes){for(var L=0;L0){var o=s.children[0],a=o.data;(r.isBezierEditing&&this.selectedItems.connectors[0].id===r.id||"Bezier"!==r.type)&&r.getSegmentElement(r,o,"ComplexHierarchicalTree"===this.layout.type||"HierarchicalTree"===this.layout.type?this.layout.orientation:void 0,void 0,!1),o.data!==a&&(s.measure(new me),s.arrange(s.desiredSize),"SVG"===this.mode&&!e&&this.updateDiagramObject(r))}}else this.constraints&nt.Bridging&&console.warn('[WARNING] :: Module "ConnectorBridging" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.setCursor=function(e){this.diagramRenderer.setCursor(this.diagramCanvas,e)},t.prototype.clearCanvas=function(e){var i=e.contentWidth||e.diagramLayer.width/this.scroller.currentZoom,r=e.contentHeight||e.diagramLayer.height/this.scroller.currentZoom;"SVG"!==e.mode&&bo.getContext(e.diagramLayer).clearRect(0,0,i,r)},t.prototype.updateScrollOffset=function(){this.scroller.setScrollOffset(this.diagramCanvas.scrollLeft,this.diagramCanvas.scrollTop),GI(this),Ds(this)&&this.scroller.virtualizeElements()},t.prototype.setOffset=function(e,i){var r="domTable";window[""+r][this.element.id+"content"]||(window[""+r][this.element.id+"content"]=document.getElementById(this.element.id+"content"));var s=window[""+r][this.element.id+"content"];s&&(s.scrollLeft=e,s.scrollTop=i)},t.prototype.setSize=function(e,i){if(this.diagramLayer&&!this.preventDiagramUpdate){var r=Za(this);e-=r.width,i-=r.height;var s=this.spatialSearch.getPageBounds();s.x*=this.scroller.currentZoom,s.y*=this.scroller.currentZoom,s.width*=this.scroller.currentZoom,s.height*=this.scroller.currentZoom;var o="SVG"===this.mode?1:1.5,a="SVG"===this.mode?fT(this.element.id):this.diagramLayer,h="Canvas"===this.mode&&this.constraints&nt.Virtualization?this.scroller.viewPortHeight:i;a.setAttribute("width",(o*("Canvas"===this.mode&&this.constraints&nt.Virtualization?this.scroller.viewPortWidth:e)).toString()),a.setAttribute("height",(o*h).toString());var c=document.getElementById(this.element.id+"_diagramUserHandleLayer");c&&(c.style.width=e+"px",c.style.height=i+"px");var d={width:e.toString(),height:i.toString()};this.diagramLayerDiv.style.width=e+"px",this.diagramLayerDiv.style.height=i+"px",ti(NF(this.element.id),d),ti(function poe(n){return xt(n).getElementsByClassName("e-ports-expand-layer")[0]}(this.element.id),d);var u=Bl(this.element.id);ti(u,d),u.parentNode.style.width=e+"px",u.parentNode.style.height=i+"px";var f=Fd(this.element.id);ti(f,d),this.diagramRenderer.updateGrid(this.snapSettings,f,this.scroller.transform,this.rulerSettings,this.hRuler,this.vRuler),ti(vT(this.element.id),d),this.htmlLayer.style.width=e+"px",this.htmlLayer.style.height=i+"px","SVG"!==this.mode&&!Ds(this)&&this.refreshDiagramLayer(),"SVG"===this.mode&&Ds(this)&&this.scroller.virtualizeElements()}},t.prototype.transformLayers=function(){var e=this.spatialSearch.getPageBounds();e.x*=this.scroller.currentZoom,e.y*=this.scroller.currentZoom,e.width*=this.scroller.currentZoom,e.height*=this.scroller.currentZoom,this.diagramRenderer.updateGrid(this.snapSettings,Fd(this.element.id),this.scroller.transform,this.rulerSettings,this.hRuler,this.vRuler),this.diagramRenderer.transformLayers(this.scroller.transform,"SVG"===this.mode),this.diagramActions&ee.DragUsingMouse||this.updateSelector(),this.renderPageBreaks(e)},t.prototype.removePageBreaks=function(){if(this.diagramLayer){var e=OF(this.element.id);if(e&&e.childNodes)for(var i=e.childNodes.length,r=0;rthis.pageSettings.height&&(e=this.pageSettings.height,this.pageSettings.height=this.pageSettings.width,this.pageSettings.width=e):this.pageSettings.height>this.pageSettings.width&&(e=this.pageSettings.width,this.pageSettings.width=this.pageSettings.height,this.pageSettings.height=e)},t.prototype.setOverview=function(e,i){if(e)e&&(this.views.push(e.id),this.views[e.id]=e,e.renderDocument(e),e.diagramRenderer.setLayers(),e.updateView(e),this.renderNodes(e));else{for(var r=0;r1&&this.updateSelectionRectangle(),this.isProtectedOnChange=s},t.prototype.updateSelectionRectangle=function(){for(var e=hm(this.element.id),i=!1,r=0;r1&&this.updateSelectionRectangle(),this.enableServerDataBinding(e)},t.prototype.renderSelectorForAnnotation=function(e,i){this.diagramRenderer.renderResizeHandle(e.wrapper.children[0],i,e.thumbsConstraints,this.scroller.currentZoom,e.constraints,this.scroller.transform,void 0,ro(e.annotation),void 0,void 0,e.handleSize)},t.prototype.drawSelectionRectangle=function(e,i,r,s){this.clearSelectorLayer(),this.diagramRenderer.drawSelectionRectangle(e,i,r,s,this.adornerLayer,this.scroller.transform)},t.prototype.renderHighlighter=function(e){var i=Bl(this.element.id);this.diagramRenderer.renderHighlighter(e,i,this.scroller.transform)},t.prototype.clearHighlighter=function(){var e=Bl(this.element.id),i=e.getElementById(e.id+"_highlighter");i&&i.parentNode.removeChild(i)},t.prototype.getNodesConnectors=function(e){for(var i=0;i0;h--)this.eventHandler&&this.eventHandler.touchArgs&&"touchmove"===this.eventHandler.touchArgs.type?(this.diagramRenderer.touchMove=!0,l&&l===o[h-1].id||(a=o[h-1]).parentNode.removeChild(a)):(a=o[h-1]).parentNode.removeChild(a);if(!ce()){var c=gT(this.element.id).childNodes;for(r=c.length;r>0;r--)c[r-1].parentNode.removeChild(c[r-1])}}},t.prototype.getWrapper=function(e,i){var r;i=e.id+"_"+i;for(var s=e instanceof Mi?e:this.getPortContainer(this.nameTable[e.id]),o=0;o0&&this.applyStyle(e,a=r.annotations)}for(i=0;i0){var a=this.selectedItems.connectors[parseInt(i.toString(),10)].annotations;this.applyStyle(e,a)}},t.prototype.applyStyle=function(e,i){for(var r=0;r0)for(var i=0;i0?r[0].zIndex+(e?1:-1):e?0:this.nodes.length+this.connectors.length-1)<0?i=this.nodes.length+this.connectors.length-1:i===this.nodes.length+this.connectors.length&&(i=0);for(var s=0;s0)for(var s=void 0,o=r.children.length-1;o>=0;o--){var a=r.children[parseInt(o.toString(),10)];i.length>0&&-1!==i.indexOf(a.id.split("_groupElement")[0])&&(r.parentNode.insertBefore(a,s||r),s=a)}r&&r.parentNode.removeChild(r)},t.prototype.deleteGroup=function(e){var r=[];e.children&&(r=this.commandHandler.getChildren(e,[])),this.UpdateBlazorDiagramModelCollection(e);for(var s=0,o=r;s0)for(var xe=0;xe0)if("Path"===t.shape.type&&void 0!==n.shape.data)t.wrapper.children[0].data=n.shape.data;else if("Text"===t.shape.type&&void 0!==n.shape.content)t.wrapper.children[0].content=n.shape.content;else if("Image"===t.shape.type&&void 0!==n.shape.source)t.wrapper.children[0].source=n.shape.source;else if("Native"===t.shape.type){for(var r=void 0,s=0;s-1)&&(this.diagramActions&ee.PreventZIndexOnDragging?this.updateDiagramObject(e,!0):this.updateDiagramObject(e)),!s&&d&&(this.lineRoutingModule&&this.diagramActions&&this.constraints&nt.LineRouting&&"helper"!==e.id?this.diagramActions&ee.ToolAction||this.lineRoutingModule.renderVirtualRegion(this,!0):this.diagramActions&&this.constraints&nt.LineRouting&&"helper"!==e.id&&console.warn('[WARNING] :: Module "LineRouting" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),this.updateConnectorEdges(e),"helper"!==e.id&&!(this.diagramActions&ee.ToolAction))))for(var Sa=this.spatialSearch.findObjects(e.wrapper.outerBounds),Mo=0;Moe?Math.abs(r-e):Math.abs(e-r),d=s>i?Math.abs(s-i):Math.abs(i-s);(0===c&&0===d||Number.isNaN(c)&&Number.isNaN(d))&&o.laneMargin&&(u=o.margin.left-o.laneMargin.left,f=o.margin.top-o.laneMargin.top);var p=o.width,g=o.height,v=new Ne(0,0,0,0);if(0!==p&&0!==g&&(v=new Ne((0!==r?r:o.offsetX)-p/2,(0!==s?s:o.offsetY)-g/2,p,g)),h){var y=l,b=this.selectedItems.nodes?this.selectedItems.nodes[0]:void 0;if(""!==y.textAnnotation.textAnnotationTarget&&this.nameTable[y.textAnnotation.textAnnotationTarget])if(""===o.parentId||b&&b.shape&&"TextAnnotation"===b.shape.shape){if("Auto"===y.textAnnotation.textAnnotationDirection&&a.children[0]instanceof Mi&&a.children[0].children[0]instanceof Ze){var w=a.children[0],C=document.getElementById(w.id+"_groupElement"),D=document.getElementById(w.children[0].id+"_groupElement");C.removeChild(D),w.children.splice(0,1),this.isProtectedOnChange=!0,this.bpmnModule.setAnnotationPath(v,w,o,y,y.textAnnotation.textAnnotationDirection,this),this.isProtectedOnChange=!1}}else this.isPositionUndo=!0,this.updateTextAnnotationInSwimlane(o,o),this.isPositionUndo=!1;else o.inEdges.length>0&&(x=this.nameTable[""+o.inEdges[0]])&&x.isBpmnAnnotationConnector&&(x.sourcePoint={x:r>e?x.sourcePoint.x+c:x.sourcePoint.x-c,y:s>i?x.sourcePoint.y+d:x.sourcePoint.y-d});this.nodePropertyChange(o,{},P={ports:[{offset:o.ports[0].offset}]})}else for(var L=0,O=o.outEdges;Le?T.offsetX+c:T.offsetX-c,T.offsetY=s>i?T.offsetY+d:T.offsetY-d,P={offsetX:T.offsetX,offsetY:T.offsetY}),this.nodePropertyChange(T,z,P)}}}},t.prototype.updatePorts=function(e,i){if(e&&e.ports.length>0)for(var r=0,s=Object.keys(e.ports);r0)for(var i=0;i0)for(var r=0;r0&&void 0===r.segments&&(e.segments=[]),void 0!==r.shape&&void 0!==e.shape&&e.shape&&"Bpmn"===e.shape.type&&this.bpmnModule&&this.bpmnModule.updateBPMNConnector(e,i,r,this),void 0!==e.constraints?(this.updateThumbConstraints(this.selectedItems.connectors,this.selectedItems),s=!0):s},t.prototype.connectorPropertyChange=function(e,i,r,s,o){if(this.canEnableBlazorObject){var a=$(e);this.insertValue(a,!1)}var d,u,f,p,l=e.wrapper.bounds,h=!1,c=[];if(h=this.connectorProprtyChangeExtend(e,i,r,h),void 0!==r.visible&&this.updateElementVisibility(e.wrapper,e,e.visible),void 0!==r.sourcePoint||void 0!==r.targetPoint||void 0!==r.sourceID||void 0!==r.targetID||void 0!==r.targetPadding||void 0!==r.sourcePortID||void 0!==r.targetPortID||void 0!==r.sourcePadding||void 0!==r.type||void 0!==r.segments||void 0!==r.flip){if(void 0!==r.sourceID&&r.sourceID!==i.sourceID||r.sourcePortID){if(u=this.findInOutConnectPorts(g=this.nameTable[e.sourceID],!1),(!g||Ph(g)||""!==e.sourcePortID&&Td(u))&&(e.sourceWrapper=g?this.getEndNodeWrapper(g,e,!0):void 0,e.sourcePortID&&void 0===r.sourcePortID&&(e.sourcePortWrapper=g?this.getWrapper(g.wrapper,e.sourcePortID):void 0),this.removePortEdges(this.nameTable[i.sourceID]||g,i.sourcePortID||e.sourcePortID,e.id,!1)),void 0!==r.sourceID&&void 0!==i.sourceID&&""!==i.sourceID){var v=this.nameTable[i.sourceID];void 0!==v&&v.outEdges&&-1!==v.outEdges.indexOf(e.id)&&em(v.outEdges,e.id)}this.updateEdges(e)}if(void 0!==r.targetID&&r.targetID!==i.targetID){if(d=this.findInOutConnectPorts(y=this.nameTable[r.targetID],!0),(!y||ua(y)||""!==e.targetPortID&&kh(d))&&(e.targetWrapper=y?this.getEndNodeWrapper(y,e,!1):void 0,e.targetPortID&&void 0===r.targetPortID&&(e.targetPortWrapper=y?this.getWrapper(y.wrapper,e.targetPortID):void 0),this.removePortEdges(this.nameTable[i.targetID]||y,i.targetPortID||e.targetPortID,e.id,!0)),void 0!==i&&void 0!==i.targetID&&""!==i.targetID){var S=this.nameTable[i.targetID];void 0!==S&&S.inEdges&&-1!==S.inEdges.indexOf(e.id)&&em(S.inEdges,e.id)}this.updateEdges(e)}var g,y;void 0!==r.sourcePortID&&r.sourcePortID!==i.sourcePortID&&(e.sourceID&&this.nameTable[e.sourceID]&&(f=this.nameTable[e.sourceID].wrapper),!(g=this.nameTable[e.sourceID])||Ph(g)||""!==e.sourcePortID&&Td(u)?e.sourcePortWrapper=f?this.getWrapper(f,r.sourcePortID):void 0:""===e.sourcePortID&&!Ph(g)&&(e.sourcePortWrapper=void 0)),void 0!==r.targetPortID&&r.targetPortID!==i.targetPortID&&(e.targetID&&this.nameTable[e.targetID]&&(p=this.nameTable[e.targetID].wrapper),!(y=this.nameTable[e.targetID])||ua(y)||""!==e.targetPortID&&kh(d)?e.targetPortWrapper=p?this.getWrapper(p,r.targetPortID):void 0:""===e.targetPortID&&!ua(y)&&(e.targetPortWrapper=void 0)),void 0!==r.flip&&(e.flip=r.flip,mF(e)),"Orthogonal"===e.type&&this.lineRoutingModule&&this.diagramActions&&this.constraints&nt.LineRouting&&!(this.diagramActions&ee.ToolAction)&&"ComplexHierarchicalTree"!==this.layout.type&&(this.lineRoutingModule.renderVirtualRegion(this,!0),e.sourceID!==e.targetID&&e.segments.length>1&&this.lineRoutingModule.refreshConnectorSegments(this,e,!1)),c=this.getPoints(e)}void 0!==r.style&&zh(r.style,e.wrapper.children[0]),(c.length>0||void 0!==r.sourceDecorator||void 0!==r.targetDecorator&&function Rse(n){return-1!==n.indexOf("shape")||-1!==n.indexOf("pathData")||-1!==n.indexOf("width")||-1!==n.indexOf("height")}(Object.keys(r.targetDecorator))||void 0!==r.cornerRadius)&&(Jf(e,c.length>0?c:e.intermediatePoints,this.diagramActions),void 0!==r.type&&(h=!0),c.length>0&&(e.wrapper.measure(new me(e.wrapper.width,e.wrapper.height)),e.wrapper.arrange(e.wrapper.desiredSize),this.updateConnectorAnnotation(e),this.updateConnectorPort(e),this.updateConnectorfixedUserHandles(e),this.updateObject(e,i,r))),(r.sourcePoint||r.targetPoint||r.segments)&&this.diagramActions===ee.Render&&(h=!0),"Bpmn"===e.shape.type&&"Default"===e.shape.sequence&&"Sequence"===e.shape.flow&&this.commandHandler.updatePathElementOffset(e),s||this.updateBridging(),this.updateAnnotations(r,e),this.updateConnectorPorts(r,e),this.updatefixedUserHandle(r,e),e.wrapper.measure(new me(e.wrapper.width,e.wrapper.height)),e.wrapper.arrange(e.wrapper.desiredSize),!1===l.equals(l,e.wrapper.bounds)&&(this.updateQuad(e),"Drag"!==this.eventHandler.currentAction&&this.updateGroupSize(e)),!0===h&&this.checkSelectedItem(e)&&(!(this.diagramActions&ee.ToolAction)||this.diagramActions&ee.UndoRedo)&&this.updateSelector(),this.preventConnectorsUpdate||(!Ds(this)||Ds(this)&&this.scroller.oldCollectionObjects.indexOf(e.id)>-1)&&(this.diagramActions&ee.PreventZIndexOnDragging?this.updateDiagramObject(e,!0):this.updateDiagramObject(e)),this.updateConnectorEdges(e),this.diagramActions&&"New"!==e.status&&(e.status="Update"),this.triggerPropertyChange(o,e,i,r)},t.prototype.removePortEdges=function(e,i,r,s){if(e)for(var o=0;o0&&e.id===s[s.length-1].id&&(r=!0),r},t.prototype.updateDiagramContainerVisibility=function(e,i){if(e instanceof Cs)for(var r=0;r>"),r instanceof es&&this.updateAnnotationWrapper(r,s,o,a)),void 0!==e.template&&(r.content=e.template,this.updateAnnotationWrapper(r,s,o,a))},t.prototype.updateAnnotationWrapper=function(e,i,r,s){for(var o=0,a=this.views;o=0&&this.nodes.splice(s,1),delete this.nameTable[""+r]}var o=this.nodes.indexOf(this.nameTable[this.currentSymbol.id]);o>=0&&this.nodes.splice(o,1)}},t.prototype.selectDragedNode=function(e,i,r){this.currentSymbol=e,"SVG"!==this.mode&&this.refreshDiagramLayer(),this.commandHandler.oldSelectedObjects=im(this),this.commandHandler.select(e),this.eventHandler.mouseDown(i.event),this.eventHandler.mouseMove(i.event,i),this.preventDiagramUpdate=!1,this.updatePage(),r.style.opacity="0"},t.prototype.initDroppables=function(){var s,o,e=this,i={},r={},a="selectedSymbols";this.droppable=new oR(this.element);var l=5;this.droppable.over=function(h){if(e.rulerSettings.showRulers){var c=document.getElementById(e.element.id+"_vRuler"),d=parseFloat(c.style.width);l=d+1}if(0===e.previousSelectedObjects.length&&!e.currentSymbol&&(e.previousSelectedObjects=e.commandHandler.getSelectedObject()),e.commandHandler.PreventConnectorSplit=!0,e.currentSymbol)h.event.touches&&h.event.touches.length&&e.eventHandler.mouseMove(h.event,h.event.touches);else{var u=null;if(!h.dragData&&"drag"===h.name){var f=document.getElementsByClassName("e-dragclone")[0];f&&(u=f)}if(h.dragData||u){var p=void 0,g=void 0;document.getElementById(e.element.id+"content").focus();var v=e.eventHandler.getMousePosition(h.event),y=void 0,S=u||h.dragData.helper,b=S.getAttribute("paletteId"),M=void 0,w=void 0,C=void 0,D=void 0;if(!b&&h.dragData){e.triggerEvent(Ce.dragEnter,A={source:null,element:p,cancel:!1,diagram:e,dragData:h.dragData.draggedElement.ej2_instances[0].dragData,dragItem:p});var x=void 0,P=void 0;if(A.dragItem){if(A.dragItem.sourcePoint&&A.dragItem.targetPoint?P=new de(e,"connectors",A.dragItem,!0):x=new te(e,"nodes",A.dragItem,!0),e.initObject(p=x||P,void 0,void 0,!0),e.enterObject=p,e.enterTable=r,p instanceof te)x.offsetX=v.x+5+x.width*x.pivot.x,x.offsetY=v.y+x.height*x.pivot.y;else if(p instanceof de){var L=Ne.toBounds([p.sourcePoint,p.targetPoint]),O=v.x-L.left,N=v.y-L.top;p.sourcePoint.x+=O,p.sourcePoint.y+=N,p.targetPoint.x+=O,p.targetPoint.y+=N}e.preventDiagramUpdate=!0,e.currentSymbol=p,"SVG"!==e.mode&&e.refreshDiagramLayer(),e.selectDragedNode(p,h,S),delete e.enterObject,delete e.enterTable,e.droppable[""+a]=S,e.allowServerDataBinding=!0}}if(b){var T=document.getElementById(b).ej2_instances[0];if(e.droppable.sourceElement=T,T){var B=T[""+a];e.allowServerDataBinding=!1,y=$(T[""+a]),i=T.childTable;var j=B.wrapper.children[0].children[0];if(D=function Hse(n,t,e){var i=bF(n,t,e,"width"),r=bF(n,t,e,"height");return new me(i,r)}(T,y,j),T[""+a]instanceof te){"TextAnnotation"===B.shape.shape?(y.offsetX=v.x+11+D.width*y.pivot.x,y.offsetY=v.y+11+D.height*y.pivot.y):(y.offsetX=v.x+5+D.width*y.pivot.x,y.offsetY=v.y+D.height*y.pivot.y),"Bpmn"===(x=new te(e,"nodes",y,!0)).shape.type&&x.shape.activity.subProcess.processes&&x.shape.activity.subProcess.processes.length&&(x.shape.activity.subProcess.processes=[]),w=x.previewSize,C=T.symbolDragSize;var Q=T.symbolPreview;if(x.width=(M=x.dragSize).width||C.width||w.width||Q.width||x.width,x.height=M.height||C.height||w.height||Q.height||x.height,"SwimLane"===x.shape.type){if(e.diagramActions|=ee.PreventHistory,x.shape.isLane){x.children=[],s={id:"header"+Qe()},"Horizontal"===x.shape.orientation?(s.width=x.shape.lanes[0].header.width,s.height=x.shape.lanes[0].height):(s.width=x.shape.lanes[0].width,s.height=x.shape.lanes[0].header.height),s.style=x.shape.lanes[0].header.style,s.offsetX=v.x+l+s.width/2,s.offsetY=v.y+s.height/2,e.diagramActions|=ee.PreventCollectionChangeOnDragOver,s=e.add(s),o={id:"body"+Qe()},"Horizontal"===x.shape.orientation?(o.width=x.shape.lanes[0].width-s.width,o.height=x.shape.lanes[0].height,o.offsetX=v.x+l+(x.shape.lanes[0].header.width+o.width/2),o.offsetY=v.y+o.height/2):(o.width=x.shape.lanes[0].width,o.height=x.shape.lanes[0].height-s.height,o.offsetX=v.x+l+o.width/2,o.offsetY=v.y+(x.shape.lanes[0].header.height+o.height/2)),o.style=x.shape.lanes[0].style,o=e.add(o);var oe={id:"group"+Qe(),children:[s.id,o.id]};oe.shape=x.shape,oe.width=x.shape.lanes[0].width,oe.height=x.shape.lanes[0].height,oe.previewSize=x.previewSize,oe.dragSize=x.dragSize,oe.addInfo=x.addInfo,x=e.add(oe),e.diagramActions&=~ee.PreventCollectionChangeOnDragOver}e.diagramActions&=~ee.PreventHistory}if(x.shape.isPhase&&((g="Horizontal"===x.shape.orientation)?(x.offsetX=v.x+l+(x.width||j.actualSize.width)/2,x.offsetY=v.y,x.shape.data="M20,"+x.height/2+" L"+(x.width-20)+","+x.height/2+"z",x.height=1):(x.offsetX=v.x+5,x.offsetY=v.y+(x.height||j.actualSize.height)/2,x.shape.data="M"+x.width/2+",20 L"+x.width/2+","+(x.height-20)+"z",x.width=1)),"UmlClassifier"===x.shape.type&&(x.children=x.width=x.height=void 0,y.children=void 0,"Class"===x.shape.classifier&&x.shape.classShape.methods.length<=0&&x.shape.classShape.attributes.length<=0&&(x.shape.classShape.attributes=[{name:"Name",type:"Type",style:{}}]),"Enumeration"===x.shape.classifier&&x.shape.enumerationShape.members.length<=0&&(x.shape.enumerationShape.members=[{name:"Name"}]),"Interface"===x.shape.classifier&&x.shape.interfaceShape.methods.length<=0&&x.shape.interfaceShape.attributes.length<=0&&(x.shape.interfaceShape.attributes=[{name:"Name",type:"Type",style:{}}])),p=x,y.children){var ue=y;r=e.getChildren(ue,{},i),Kx(ue,-ue.offsetX,-ue.offsetY,r,!0,e)}}else if(T[""+a]instanceof de){p=new de(e,"connectors",y,!0);var Me=Ne.toBounds([p.sourcePoint,p.targetPoint]),De=v.x-Me.left,xe=v.y-Me.top;p.sourcePoint.x+=De,p.sourcePoint.y+=xe,p.targetPoint.x+=De,p.targetPoint.y+=xe}p.shape.isLane||(p.id+=Qe());var A={source:T,element:p,cancel:!1,diagram:e,dragData:null,dragItem:p};if(e.enterObject=p,e.enterTable=r,e.triggerEvent(Ce.dragEnter,A),p instanceof te&&"SwimLane"===p.shape.type&&p.shape.isLane){var Ie=A.element,Ve=Ie.shape.lanes[0];g="Horizontal"===Ie.shape.orientation;var ot=e.nameTable[p.children[0]],$e=e.nameTable[p.children[1]];w=p.previewSize,C=T.symbolDragSize,Ve.width=(M=p.dragSize).width||C.width||w.width||Ve.width,Ve.height=M.height||C.height||w.height||Ve.height,g?(s.width=Ve.header.width,s.height=Ve.height,o.width=Ve.width-s.width,o.height=Ve.height,o.offsetX=v.x+l+(Ve.header.width+$e.width/2),o.offsetY=v.y+$e.height/2):(s.width=Ve.width,s.height=Ve.header.height,o.width=Ve.width,o.height=Ve.height-s.height,o.offsetX=v.x+l+$e.width/2,o.offsetY=v.y+(Ve.header.height+$e.height/2)),s.offsetX=v.x+l+ot.width/2,s.offsetY=v.y+ot.height/2,p.width=Ve.width,p.height=Ve.height}if(p instanceof te&&p.shape.isPhase&&(g?p.height=1:p.width=1),!e.activeLayer.lock&&!A.cancel){if(e.preventDiagramUpdate=!0,p.children&&e.findChild(p,r),e.preventDiagramUpdate=!0,p.zIndex!==Number.MIN_VALUE&&(p.zIndex=Number.MIN_VALUE),e.initObject(p,void 0,void 0,!0),e.bpmnModule)for(var Ci=0;Ci0&&(S.segments=[]),d=this.add(S,!0)),(S||d)&&(Bv(this)||Fv(this))&&this.select([this.nameTable[S[""+b]]],!1,this.previousSelectedObjects),y.target&&y.target instanceof de&&!0===this.enableConnectorSplit&&this.nameTable[S[""+b]]instanceof te&&(this.commandHandler.connectorSplit(this.nameTable[S[""+b]],y.target),this.commandHandler.PreventConnectorSplit=!1))),this.protectPropertyChange(!1),v=this.nameTable[S[""+b]],S.hasTarget&&(S.nodeId=S.hasTarget,this.remove(S)),this.bpmnModule&&v instanceof te&&S.processId&&(v.processId=S.processId,this.bpmnModule.dropBPMNchild(this.nameTable[v.processId],v,this)),y.cancel||this.endGroupAction(),"SVG"!==this.mode&&this.refreshDiagramLayer(),delete this.droppable[""+c]):(this.triggerEvent(Ce.drop,y={source:h.droppedElement,element:void 0,target:this.eventHandler.hoverNode||this.eventHandler.lastObjectUnderMouse||this,cancel:!1,position:void 0}),S=void 0,b="id"),this.droppable[M="selectedSymbols"]&&this.droppable[""+M].parentNode)gt(this.droppable[""+M]);else for(w=document.getElementsByClassName("e-dragclone"),C=0;C0)for(var f=0;f1),e.previousSelectedObject=null}}},t.prototype.getDropEventArgs=function(e){if(this.eventHandler.lastObjectUnderMouse||this.eventHandler.hoverNode){var i=this.eventHandler.lastObjectUnderMouse||this.eventHandler.hoverNode;e.target=ps(i)===de?{connector:i}:{node:i}}else e.target.diagramId=this.element.id},t.prototype.removeChildInNodes=function(e){if(e){if(e.children)for(var i=0;i1){var l=2;if(e.children&&e.children.length>0)for(;e.children.indexOf(i.objects[s-l])>-1;)l++;this.commandHandler.moveSvgNode(e.id,i.objects[s-l]),this.commandHandler.moveSvgNode(i.objects[s-l],e.id)}else if(o){var h=this.commandHandler.getLayer(this.layerZIndexTable[o.zIndex]).objects[0];h?(this.commandHandler.moveSvgNode(e.id,h),this.commandHandler.updateNativeNodeIndex(e.id,h)):this.moveObjectsUp(e,i)}else this.moveObjectsUp(e,i)},t.prototype.moveObjectsUp=function(e,i){for(var r,s=this.layers.length-1;s>=0;s--)if(r=this.layers[parseInt(s.toString(),10)],i.id!==r.id){var o=this.commandHandler.getLayer(this.layerZIndexTable[r.zIndex]).objects[r.objects.length-1];if(o){this.commandHandler.moveSvgNode(e.id,o),this.commandHandler.moveSvgNode(o,e.id);break}}},t.prototype.insertData=function(e){return this.crudOperation(e,"create",this.getNewUpdateNodes("New"))},t.prototype.updateData=function(e){return this.crudOperation(e,"update",this.getNewUpdateNodes("Update"))},t.prototype.removeData=function(e){return this.crudOperation(e,"destroy",this.getDeletedNodes())},t.prototype.crudOperation=function(e,i,r){if(e){var s=this.parameterMap(e,!(e instanceof de));if(s){var o=e instanceof de?this.dataSourceSettings.connectionDataSource.crudAction[""+i]:this.dataSourceSettings.crudAction[""+i];this.raiseAjaxPost(JSON.stringify(s),o)}return s}var a=r;return this.processCrudCollection(a,this.dataSourceSettings.crudAction[""+i],this.dataSourceSettings.connectionDataSource.crudAction[""+i]),a},t.prototype.processCrudCollection=function(e,i,r){if(e.nodes){var s=[],o=void 0;for(o=0;o0&&this.raiseAjaxPost(JSON.stringify(s),i)}if(e.connectors){for(s=[],o=void 0,o=0;o0&&this.raiseAjaxPost(JSON.stringify(s),r)}},t.prototype.parameterMap=function(e,i){var s,r={},o=i?this.dataSourceSettings:this.dataSourceSettings.connectionDataSource;if(o.id&&(r[o.id]=e.id),o.sourcePointX&&o.sourcePointY&&(r[o.sourcePointX]=e.sourcePoint.x,r[o.sourcePointY]=e.sourcePoint.y),o.targetPointX&&o.targetPointY&&(r[o.targetPointX]=e.targetPoint.x,r[o.targetPointY]=e.targetPoint.y),o.sourceID&&(r[o.sourceID]=e.sourceID),o.targetID&&(r[o.targetID]=e.targetID),o.crudAction&&o.crudAction.customFields&&o.crudAction.customFields.length>0)for(s=0;s0&&(l=a.length),r.annotations=[{content:o.data.label[parseInt(l.toString(),10)]}]}s=this.getConnectorArrowType(o.data)}var h=new de(i,"connectors",r,!0);return s&&(h.style.strokeWidth=s.strokeWidth,h.targetDecorator.shape=s.targetDecorator),Ro(h,r,i.connectorDefaults),h},n.prototype.getConnectorArrowType=function(t){if(""===t.arrowType)return{targetDecorator:"Arrow",strokeWidth:1};switch(t.arrowType){case"None":return{targetDecorator:"None",strokeWidth:1};case"Arrow":default:return{targetDecorator:"Arrow",strokeWidth:1};case"Diamond":return{targetDecorator:"Diamond",strokeWidth:1};case"Circle":return{targetDecorator:"Circle",strokeWidth:1};case"OpenArrow":return{targetDecorator:"OpenArrow",strokeWidth:1};case"Square":return{targetDecorator:"Square",strokeWidth:1};case"Fletch":return{targetDecorator:"Fletch",strokeWidth:1};case"OpenFetch":return{targetDecorator:"OpenFetch",strokeWidth:1};case"IndentedArrow":return{targetDecorator:"IndentedArrow",strokeWidth:1};case"OutdentedArrow":return{targetDecorator:"OutdentedArrow",strokeWidth:1};case"DoubleArrow":return{targetDecorator:"DoubleArrow",strokeWidth:1}}},n}(),uae=function(){function n(){this.protectChange=!1,this.setIntervalObject=[]}return n.prototype.expand=function(t,e,i,r){var s=this,a=0;if(r.realActions=r.realActions|$i.AnimationClick,this.setIntervalObject[parseInt((0).toString(),10)]=setInterval(function(){return a++,s.layoutAnimation(e,s.setIntervalObject,6===a,r,i)},20),i.isExpanded){var l=.2;r.protectPropertyChange(!1);var h={};t&&(this.updateOpacity(i,l,r),h[parseInt((0).toString(),10)]=setInterval(function(){r.allowServerDataBinding=!1,l<=1?s.updateOpacity(i,l,r):clearInterval(h[0]),l+=.2,r.allowServerDataBinding=!0},20))}},n.prototype.stopCurrentAnimation=function(t,e,i){clearInterval(this.setIntervalObject[0]),this.setIntervalObject=[];for(var r=0;r0){t.rootNode=t.firstLevelNodes[0];var u=0,f=0,p=void 0,g=void 0,v=void 0,y=void 0,S=void 0;for(a=0;ad.y||(l.y=d.y),void 0!==l.mid&&(e=l.mid),l.tree.assistants.length&&(y=this.setBreadthSpaceForAssistants(t,r,d,void 0!==e?e:d.x,b,s),u||(e=((g=f=y).x+g.right)/2-d.width/2,f=g),v=y?y.canMoveBy:void 0),l.x=e,l.translate||(l.treeWidth=f.right-f.x),this.translateSubTree({layout:t,shape:r,shapeBounds:{x:e,y:d.y,right:e+d.width,bottom:d.y+d.height},treeBounds:f,dim:d,level:s},v,void 0!==o,a),l.firstChild&&"string"!=typeof l.firstChild&&(l.firstChild.x+=l.subTreeTranslation),r.treeBounds=f,f},n.prototype.updateLeafNode=function(t,e,i,r,s,o){var a=t.graphNodes[e.id];a.x=r.x,a.y&&a.y>r.y||(a.y=r.y,a.maxLevel=Math.max(s,a.maxLevel||0));var l={x:r.x,y:r.y,right:r.x+r.width,bottom:r.y+r.height};return a.maxLevel=Math.max(a.maxLevel||0,s),this.translateSubTree({layout:t,shape:e,shapeBounds:l,treeBounds:l,dim:r,level:s},void 0,void 0!==i,o),{x:a.x,y:a.y,right:a.x+r.width,bottom:a.y+r.height}},n.prototype.setUpLayoutInfo=function(t,e){var i={subTreeTranslation:0};return i.tree="OrganizationalChart"===t.type?{orientation:"Vertical",type:"Alternate",offset:20,enableRouting:!0}:{orientation:"Horizontal",type:"Center",enableRouting:!0},i.tree.children=[],i.tree.assistants=[],i.tree.level=0,i.translate=!0,i},n.prototype.translateSubTree=function(t,e,i,r){var s=t.layout,o=t.shape,a=t.shapeBounds,l=t.treeBounds,h=t.level,c=t.dim,d=s.graphNodes[o.id],u=s.nameTable[d.firstChild?d.firstChild.child:d.tree.children[0]],f=u?s.graphNodes[u.id]:null,p=this.hasChild(s,o),g=this.findIntersectingLevels(s,a,h,d.actualLevel),v=this.findIntersectingLevels(s,l,h,d.actualLevel),y=[];g.length&&d.translate?(d.intersect=g,this.spaceLeftFromPrevSubTree(s,o,a),d.canMoveBy=d.diff,void 0!==e&&(d.canMoveBy=Math.min(e,d.canMoveBy)),u&&void 0!==f.canMoveBy&&(f.canMoveBy>=d.canMoveBy&&(d.translated=!0),d.canMoveBy=Math.min(d.canMoveBy,f.canMoveBy)),i&&(d.x-=d.canMoveBy,d.subTreeTranslation-=d.canMoveBy,p&&(this.shiftSubordinates(s,v,d.canMoveBy),l.x=Math.min(l.x,d.x),l.right=Math.max(l.right,d.x+c.width),l.bottom=Math.max(l.bottom,d.y+c.height),l.x-=d.canMoveBy,l.right-=d.canMoveBy),u&&f.canMoveBy>d.canMoveBy?d.canMoveBy=f.canMoveBy-d.canMoveBy:u&&void 0!==d.canMoveBy&&(d.canMoveBy=0))):(p&&(l.x=Math.min(l.x,a.x),l.right=Math.max(l.right,a.x+c.width),l.bottom=Math.max(l.bottom,d.y+c.height)),d.translate||(d.canMoveBy=0,d.subTreeTranslation=0)),r||(y.push({rBounds:a={x:d.x,y:c.y,right:d.x+c.width,bottom:c.y+c.height}}),this.updateRearBounds(s,o,y,h))},n.prototype.updateRearBounds=function(t,e,i,r,s){var o,a,h,d,l=!0,c={};e&&(s=(c=t.graphNodes[e.id]).intersect,l=!c.tree.children.length&&!c.tree.assistants.length);var u=i[0].rBounds,f=i[i.length-1].rBounds;if(s&&s.length){for(d=(o=t.levels[s[0]].rBounds).bottom,o.yf.bottom?i.push({rBounds:{x:o.x,right:o.right,y:u.bottom,bottom:d}}):(o=t.levels[s[s.length-1]].rBounds,l&&o.bottom>f.bottom&&(o.y=f.bottom,i.push({rBounds:o}))),a=s[0],h=i.length-1;h>=0;h--)t.levels.splice(a,0,i[parseInt(h.toString(),10)]);t.levels.splice(a+=i.length,s.length)}else for(a=this.findLevel(t,i[i.length-1].rBounds,r),h=i.length-1;h>=0;h--)t.levels.splice(a,0,i[parseInt(h.toString(),10)])},n.prototype.shiftSubordinates=function(t,e,i){var r;if(0!==i)for(r=0;rA.right&&(A.right=M.right),A.bottom=M.bottom):A=M,0===x&&(l.firstChild={x:P.x,canMoveBy:P.canMoveBy,child:g.id}),this.hasChild(t,g)&&(!l.firstChild||l.firstChild.x>=P.firstChild.x?(P.firstChild&&l.firstChild.canMoveByP.canMoveBy&&(l.firstChild.canMoveBy=t.graphNodes[l.firstChild.child].canMoveBy=P.canMoveBy)),w=w?Math.max(P.maxLevel,w):P.maxLevel,this.uniteRects(b,v),d=0!==x&&!this.hasChild(t,g)&&P.subTreeTranslation<0?v.right-P.subTreeTranslation+t.horizontalSpacing:v.right+t.horizontalSpacing;isNaN(C)||(L.canMoveBy=C),l.mid=(L.x+A.right)/2-a.width/2,"Left"===h?l.mid=M.right-a.width:"Right"===h&&(l.mid=r)}return b},n.prototype.updateHorizontalTreeWithMultipleRows=function(t,e,i,r,s,o){var a,l,h,c,d,p,g,v,y,S=this.getDimensions(t,e,r,s,o),b=t.graphNodes[e.id],w=o,C=r,D=s,x=(t.levels.slice(0,t.levels.length),0);if(this.hasChild(t,e)){var P=-1!==t.orientation.indexOf("Left"),L=void 0,O=this.splitChildrenInRows(t,e),N=5===b.tree.children.length&&3===O[0].length,T=[],z=[];N?z=O:this.splitRows(O,T,z);var U={leftTree:T,rows:O,rightTree:z,dimensions:S},B=this.updateLeftTree(t,U,e,r,D,w);d=U.bounds;var j=void 0;void 0!==B&&(b.mid=(B||0)+(void 0!==B?t.horizontalSpacing/2:0)-S.width/2,j=B+t.horizontalSpacing),D=s;var oe=void 0;for(oe=[],g=0;gl.canMoveBy)&&(x=Math.min(x,l.canMoveBy||0),b.firstChild={x:l.x,child:a.id,canMoveBy:l.canMoveBy}),U.leftCenter=v,U.rightCenter=y,U.align=L,U.level=w,U.rightBounds=oe,this.alignRowsToCenter(t,g,e,U,j)}return d},n.prototype.updateLeftTree=function(t,e,i,r,s,o){for(var h,d,u,f,p,a=e.leftTree,l=t.graphNodes[i.id],c=[],v=(t.orientation.indexOf("Left"),0);vw.canMoveBy&&(d=Math.min(d,w.canMoveBy||0),l.firstChild={x:w.x,child:S.id,canMoveBy:w.canMoveBy}),h=f.right+t.horizontalSpacing}u=0===v?c[parseInt(v.toString(),10)].right:Math.max(u,c[parseInt(v.toString(),10)].right)}for(v=0;v=g[1].right-g[1].x?0:1),e===c.length-1&&(c[parseInt(e.toString(),10)].length%2==1||S&&1===e)){a=d[parseInt(e.toString(),10)][Math.floor(d[parseInt(e.toString(),10)].length/2)];var M=t.graphNodes[""+a].x,C=this.getDimensions(t,t.nameTable[""+a],M,t.graphNodes[""+a].y,y+1);l=void 0,!p&&S?(1===o&&(e=0),l=(g[parseInt(o.toString(),10)].x+g[parseInt(o.toString(),10)].right)/2-(g[parseInt(e.toString(),10)].x+g[parseInt(e.toString(),10)].right)/2,0===e&&(h.mid+=l)):!S&&void 0!==s&&(l=s-t.horizontalSpacing/2-(M+C.width/2)),void 0!==l&&this.updateRearBoundsOfTree(t,d[parseInt(e.toString(),10)],l,v),S&&(h.mid=(f+u)/2+(0===e?l:0)-v.width/2),void 0===h.mid&&t.graphNodes[""+a]&&(h.mid=M),p=!1,e++}},n.prototype.updateRearBoundsOfTree=function(t,e,i,r){for(var s=0;s2?"Left":"Right",M=A%2==0&&y.tree.children.length>2?-1:0),w=i+this.findOffset(t,e,y,P),a=t.nameTable[y.tree.children[parseInt(A.toString(),10)]],d=b?a.actualSize.width:a.actualSize.height,h=this.updateTree(t,w+M*(c=b?a.actualSize.height:a.actualSize.width),C,a,s+1,void 0,!0),p={x:(l=t.graphNodes[a.id]).x,y:l.y,right:l.x+c,bottom:l.y+d},0===A?(this.uniteRects(h,p),f=h):this.uniteRects(f,h),l.prevBounds&&!("Alternate"===y.tree.type&&A%2==1&&y.tree.children.length>2)&&(N=void 0!==N?Math.min(l.canMoveBy,N):l.canMoveBy),y.maxLevel=Math.max(y.maxLevel||0,l.maxLevel||0),"Alternate"===y.tree.type&&y.tree.children.length>2&&A%2==0?(0!==A&&(C=u.bottom+t.verticalSpacing/2),O.push({rBounds:p}),l.levelBounds&&(O=O.concat(l.levelBounds))):(C="Alternate"===y.tree.type&&y.tree.children.length>2?Math.max(h.bottom,u.bottom)+t.verticalSpacing/2:h.bottom+t.verticalSpacing/2,s=y.maxLevel,L.push({rBounds:p}),v?this.uniteRects(v,p):v={x:l.x,y:l.y,right:l.x+c,bottom:l.y+d},l.levelBounds&&(L=L.concat(l.levelBounds))),0===A&&(y.firstChild={x:l.x,canMoveBy:l.canMoveBy,child:a.id}),this.hasChild(t,a))if(!y.firstChild||y.firstChild.x>=l.firstChild.x){if(l.firstChild&&y.firstChild.canMoveByl.canMoveBy&&(y.firstChild.canMoveBy=t.graphNodes[y.firstChild.child].canMoveBy=l.canMoveBy);u=p}return o?y.levelBounds=L:("Alternate"===y.tree.type&&y.tree.children.length>2&&(x=this.findIntersectingLevels(t,{x:O[0].rBounds.x,y:O[0].rBounds.y,right:O[O.length-1].rBounds.right,bottom:O[O.length-1].rBounds.bottom},D+1),this.updateRearBounds(t,null,O,D+1,x)),x=this.findIntersectingLevels(t,v||f,D+1),this.updateRearBounds(t,null,v?L:[{rBounds:f}],D+1,x)),isNaN(N)||(t.graphNodes[S.id].canMoveBy=N),y.childBounds=f,y.mid=i,f},n.prototype.splitChildrenInRows=function(t,e){var r,i=t.graphNodes[e.id];r=4;var o,s=[];o=i.tree.children.length;var a=this.extend(i.tree.children);if(i.tree.rows){var h=i.tree.rows;r=h%2==0?h:h-1}else 3===i.tree.children.length||4===i.tree.children.length?r=2:5===i.tree.children.length&&(r=3);for(;o>0;)s[s.length]=a.splice(0,r),(o-=r)=t.horizontalSpacing&&(s=t.horizontalSpacing/2),r||i.tree.type){case"Left":s=o/2-s;break;case"Right":s+=o/2}return s},n.prototype.uniteRects=function(t,e){t.x=Math.min(t.x,e.x),t.right=Math.max(t.right,e.right),t.bottom=Math.max(t.bottom,e.bottom)},n.prototype.spaceLeftFromPrevSubTree=function(t,e,i){for(var s,o,r=t.graphNodes[e.id],a=t.horizontalSpacing,l=0;la.y||s.y=a.y&&s.bottom<=a.bottom||s.ya.bottom))o.splice(0,0,l);else if(a&&a.bottom=0);l=(void 0!==r?r:i)+1,a=t.levels[parseInt(l.toString(),10)]?t.levels[parseInt(l.toString(),10)].rBounds:null;do{if(a&&(s.ya.y||s.y=a.y&&s.bottom<=a.bottom||s.ya.bottom))o.push(l);else if(a&&a.y>s.bottom)break;l++,a=t.levels[parseInt(l.toString(),10)]?t.levels[parseInt(l.toString(),10)].rBounds:null}while(l<=t.levels.length);return o},n.prototype.findLevel=function(t,e,i){var s,o,r=e;for(s=0,o=t.levels[parseInt(s.toString(),10)]?t.levels[parseInt(s.toString(),10)].rBounds:null;s=t.level&&(o.tree.hasSubTree=!1)},n.prototype.updateAnchor=function(t,e,i){var r,s,o=0,a=0,l=0,h=0,c=new Ne(0,0,i.x,i.y),d=t.bounds?t.bounds:c,u=t.orientation;if(t.fixedNode){o=(s=t.nameTable[t.fixedNode]).actualSize.width,a=s.actualSize.height,t.anchorX=s.offsetX,t.anchorY=s.offsetY;var f=s.pivot;for(t.anchorX+="RightToLeft"===t.orientation?o*f.x:-o*f.x,t.anchorY+="BottomToTop"===t.orientation?a*f.y:-a*f.y,r=s,l=0;r.inEdges.length;)r=this.getParentNode(t,r),l+=t.graphNodes[r.id].subTreeTranslation||0;-1!==t.orientation.indexOf("Left")?(h=t.graphNodes[s.id].y,"LeftToRight"===u?t.anchorX-=h:t.anchorX+=h,t.anchorY-=t.graphNodes[s.id].x+l):(h=t.graphNodes[s.id].y,t.anchorX-=t.graphNodes[s.id].x+l,"TopToBottom"===u?t.anchorY-=h:t.anchorY+=h)}else if("TopToBottom"===u||"BottomToTop"===u){switch(t.horizontalAlignment){case"Left":t.anchorX=d.x-e.x+t.margin.left;break;case"Right":t.anchorX=d.x+d.width-t.margin.right-e.right;break;case"Auto":case"Center":t.anchorX=d.x+d.width/2-(e.x+e.right)/2}switch(t.verticalAlignment){case"Auto":case"Top":var p;p=d.y+t.margin.top,t.anchorY="TopToBottom"===u?p:e.bottom+p;break;case"Bottom":var g;g=d.y+d.height-t.margin.bottom,t.anchorY="TopToBottom"===u?g-e.bottom:g;break;case"Center":var v=void 0;v=d.y+d.height/2,t.anchorY="TopToBottom"===t.orientation?v-(e.y+e.bottom)/2:v+(e.y+e.bottom)/2}}else{switch(t.horizontalAlignment){case"Auto":case"Left":var y;y=d.x+t.margin.left,t.anchorX="LeftToRight"===u?y:e.bottom+y;break;case"Right":var S;S=d.x+d.width-t.margin.right,t.anchorX="LeftToRight"===u?S-e.bottom:S;break;case"Center":v=void 0,v=d.width/2+d.x,t.anchorX="LeftToRight"===t.orientation?v-(e.y+e.bottom)/2:v+(e.y+e.bottom)/2}switch(t.verticalAlignment){case"Top":t.anchorY=d.y+t.margin.top-e.x;break;case"Auto":case"Center":t.anchorY=d.y+d.height/2-(e.right+e.x)/2;break;case"Bottom":t.anchorY=d.y+d.height-t.margin.bottom-e.right}}},n.prototype.updateConnectors=function(t,e,i){var r,s,o,a=t.graphNodes[e.id];if(e.outEdges.length)for(r=0;r2){l=o.tree.children[1],isNaN(t.graphNodes[""+l].treeWidth)&&(t.graphNodes[""+l].treeWidth=t.nameTable[""+l].actualSize.width);t.orientation.indexOf("Left"),this.getSegmentsForMultipleRows(t,i,r,e)}else o.tree.children.length>5?s<4||si.offsetX?a.middleRight:a.middleLeft).y},h)}else{var h;l=0===t.orientation.indexOf("Left")?o.middleRight:o.middleLeft,s.push(l,{x:a.bottomCenter.x,y:o.middleRight.y},h=e.offsetY>i.offsetY?a.bottomCenter:a.topCenter)}this.getSegmentsFromPoints(s,r)},n.prototype.get5Points=function(t,e,i,r){var l,h,c,d,s=[],o=this.getBounds(e),a=this.getBounds(i);-1!==t.orientation.indexOf("Top")?s.push(l=e.offsetYi.offsetX?a.middleRight:a.middleLeft).x+(c=t.horizontalSpacing/2*(e.offsetX>i.offsetX?1:-1)),y:l.y+d},{x:h.x+c,y:h.y},h):s.push(l=e.offsetX>i.offsetX?o.middleLeft:o.middleRight,{x:l.x+(c=t.horizontalSpacing/4*(e.offsetXi.offsetY?1:-1))},{x:(h=e.offsetY>i.offsetY?a.bottomCenter:a.topCenter).x,y:l.y+d},h),this.getSegmentsFromPoints(s,r)},n.prototype.getSegmentsFromPoints=function(t,e){for(var r,i=[],s=0;s"u"||(y.innerHTML=v.innerHTML?v.innerHTML:"",void 0!==v.className&&(y.className=v.className),void 0!==v.id&&(y.id=v.id),void 0!==v.styles&&y.setAttribute("style",v.styles),void 0!==e.ngAttr&&y.setAttribute(e.ngAttr,""),void 0!==v.attrs&&Fe(y,v.attrs)),y};for(var i=0,r=e.tags;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s}!function CZ(n){CC.compile=n.compile}({compile:function Hae(n,t){if("string"==typeof n||"function"==typeof n&&n.prototype&&n.prototype.CSPTemplate)return Rae(n,t);var e=n.elementRef.nativeElement._viewContainerRef,i=n.elementRef.nativeElement.propName;return function(r,s,o){var l=e||s.viewContainerRef,h=l.createEmbeddedView(n,{$implicit:r});/EJS-MENTION|EJS-DROPDOWNLIST/.test(Y("currentInstance.element.nodeName",l))||/E-TABITEM/.test(Y("element.nativeElement.nodeName",l))?h.detectChanges():h.markForCheck();var c=s&&s.registeredTemplate?s.registeredTemplate:Y("currentInstance.registeredTemplate",l);return typeof c["".concat(o=o&&s.registeredTemplate?o:i)]>"u"&&(c["".concat(o)]=[]),c["".concat(o)].push(h),h.rootNodes}}});const jae=["annotationTemplate"],Vae=["nodeTemplate"],Wae=["userHandleTemplate"];let Yae=["addInfo","id","lock","objects","visible","zIndex"],Qae=[],Gae=(()=>{class n extends Bh{constructor(e){super(),this.viewContainerRef=e,_l("currentInstance",this,this.viewContainerRef),this.registerEvents(Qae),this.directivePropList=Yae}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-layer"]],inputs:{addInfo:"addInfo",id:"id",lock:"lock",objects:"objects",visible:"visible",zIndex:"zIndex"},features:[yn]}),n})(),Xae=(()=>{class n extends Fh{constructor(){super("layers")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-layers"]],contentQueries:function(e,i,r){if(1&e&&dn(r,Gae,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),qae=["action","cursor"],$ae=[],Zae=(()=>{class n extends Bh{constructor(e){super(),this.viewContainerRef=e,_l("currentInstance",this,this.viewContainerRef),this.registerEvents($ae),this.directivePropList=qae}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-cursormap"]],inputs:{action:"action",cursor:"cursor"},features:[yn]}),n})(),Jae=(()=>{class n extends Fh{constructor(){super("customcursor")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-cursormaps"]],contentQueries:function(e,i,r){if(1&e&&dn(r,Zae,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),Kae=["alignment","cornerRadius","displacement","fill","handleStrokeColor","handleStrokeWidth","height","iconStrokeColor","iconStrokeWidth","id","offset","padding","pathData","tooltip","visibility","width"],ele=[],tle=(()=>{class n extends Bh{constructor(e){super(),this.viewContainerRef=e,_l("currentInstance",this,this.viewContainerRef),this.registerEvents(ele),this.directivePropList=Kae}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-connector-fixeduserhandle"]],inputs:{alignment:"alignment",cornerRadius:"cornerRadius",displacement:"displacement",fill:"fill",handleStrokeColor:"handleStrokeColor",handleStrokeWidth:"handleStrokeWidth",height:"height",iconStrokeColor:"iconStrokeColor",iconStrokeWidth:"iconStrokeWidth",id:"id",offset:"offset",padding:"padding",pathData:"pathData",tooltip:"tooltip",visibility:"visibility",width:"width"},features:[yn]}),n})(),ile=(()=>{class n extends Fh{constructor(){super("fixeduserhandles")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-connector-fixeduserhandles"]],contentQueries:function(e,i,r){if(1&e&&dn(r,tle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),rle=["addInfo","alignment","annotationType","constraints","content","displacement","dragLimit","height","horizontalAlignment","hyperlink","id","margin","offset","rotateAngle","rotationReference","segmentAngle","style","template","tooltip","type","verticalAlignment","visibility","width"],nle=[],sle=(()=>{class n extends Bh{constructor(e){super(),this.viewContainerRef=e,_l("currentInstance",this,this.viewContainerRef),this.registerEvents(nle),this.directivePropList=rle}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-connector-annotation"]],inputs:{addInfo:"addInfo",alignment:"alignment",annotationType:"annotationType",constraints:"constraints",content:"content",displacement:"displacement",dragLimit:"dragLimit",height:"height",horizontalAlignment:"horizontalAlignment",hyperlink:"hyperlink",id:"id",margin:"margin",offset:"offset",rotateAngle:"rotateAngle",rotationReference:"rotationReference",segmentAngle:"segmentAngle",style:"style",template:"template",tooltip:"tooltip",type:"type",verticalAlignment:"verticalAlignment",visibility:"visibility",width:"width"},features:[yn]}),n})(),ole=(()=>{class n extends Fh{constructor(){super("annotations")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-connector-annotations"]],contentQueries:function(e,i,r){if(1&e&&dn(r,sle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),ale=["addInfo","allowNodeOverlap","annotations","bezierSettings","bridgeSpace","connectionPadding","connectorSpacing","constraints","cornerRadius","dragSize","excludeFromLayout","fixedUserHandles","flip","flipMode","hitPadding","id","margin","maxSegmentThumb","ports","previewSize","segmentThumbShape","segmentThumbSize","segments","shape","sourceDecorator","sourceID","sourcePadding","sourcePoint","sourcePortID","style","symbolInfo","targetDecorator","targetID","targetPadding","targetPoint","targetPortID","tooltip","type","visible","wrapper","zIndex"],lle=[],hle=(()=>{class n extends Bh{constructor(e){super(),this.viewContainerRef=e,this.tags=["fixedUserHandles","annotations"],_l("currentInstance",this,this.viewContainerRef),this.registerEvents(lle),this.directivePropList=ale}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-connector"]],contentQueries:function(e,i,r){if(1&e&&(dn(r,ile,5),dn(r,ole,5)),2&e){let s;Kr(s=en())&&(i.childFixedUserHandles=s.first),Kr(s=en())&&(i.childAnnotations=s.first)}},inputs:{addInfo:"addInfo",allowNodeOverlap:"allowNodeOverlap",annotations:"annotations",bezierSettings:"bezierSettings",bridgeSpace:"bridgeSpace",connectionPadding:"connectionPadding",connectorSpacing:"connectorSpacing",constraints:"constraints",cornerRadius:"cornerRadius",dragSize:"dragSize",excludeFromLayout:"excludeFromLayout",fixedUserHandles:"fixedUserHandles",flip:"flip",flipMode:"flipMode",hitPadding:"hitPadding",id:"id",margin:"margin",maxSegmentThumb:"maxSegmentThumb",ports:"ports",previewSize:"previewSize",segmentThumbShape:"segmentThumbShape",segmentThumbSize:"segmentThumbSize",segments:"segments",shape:"shape",sourceDecorator:"sourceDecorator",sourceID:"sourceID",sourcePadding:"sourcePadding",sourcePoint:"sourcePoint",sourcePortID:"sourcePortID",style:"style",symbolInfo:"symbolInfo",targetDecorator:"targetDecorator",targetID:"targetID",targetPadding:"targetPadding",targetPoint:"targetPoint",targetPortID:"targetPortID",tooltip:"tooltip",type:"type",visible:"visible",wrapper:"wrapper",zIndex:"zIndex"},features:[yn]}),n})(),cle=(()=>{class n extends Fh{constructor(){super("connectors")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-connectors"]],contentQueries:function(e,i,r){if(1&e&&dn(r,hle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),dle=["cornerRadius","fill","handleStrokeColor","handleStrokeWidth","height","iconStrokeColor","iconStrokeWidth","id","margin","offset","padding","pathData","tooltip","visibility","width"],ule=[],fle=(()=>{class n extends Bh{constructor(e){super(),this.viewContainerRef=e,_l("currentInstance",this,this.viewContainerRef),this.registerEvents(ule),this.directivePropList=dle}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-node-fixeduserhandle"]],inputs:{cornerRadius:"cornerRadius",fill:"fill",handleStrokeColor:"handleStrokeColor",handleStrokeWidth:"handleStrokeWidth",height:"height",iconStrokeColor:"iconStrokeColor",iconStrokeWidth:"iconStrokeWidth",id:"id",margin:"margin",offset:"offset",padding:"padding",pathData:"pathData",tooltip:"tooltip",visibility:"visibility",width:"width"},features:[yn]}),n})(),ple=(()=>{class n extends Fh{constructor(){super("fixeduserhandles")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-node-fixeduserhandles"]],contentQueries:function(e,i,r){if(1&e&&dn(r,fle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),gle=["addInfo","annotationType","constraints","content","dragLimit","height","horizontalAlignment","hyperlink","id","margin","offset","rotateAngle","rotationReference","style","template","tooltip","type","verticalAlignment","visibility","width"],vle=[],mle=(()=>{class n extends Bh{constructor(e){super(),this.viewContainerRef=e,_l("currentInstance",this,this.viewContainerRef),this.registerEvents(vle),this.directivePropList=gle}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-node-annotation"]],inputs:{addInfo:"addInfo",annotationType:"annotationType",constraints:"constraints",content:"content",dragLimit:"dragLimit",height:"height",horizontalAlignment:"horizontalAlignment",hyperlink:"hyperlink",id:"id",margin:"margin",offset:"offset",rotateAngle:"rotateAngle",rotationReference:"rotationReference",style:"style",template:"template",tooltip:"tooltip",type:"type",verticalAlignment:"verticalAlignment",visibility:"visibility",width:"width"},features:[yn]}),n})(),yle=(()=>{class n extends Fh{constructor(){super("annotations")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-node-annotations"]],contentQueries:function(e,i,r){if(1&e&&dn(r,mle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),Sle=["addInfo","connectionDirection","constraints","height","horizontalAlignment","id","inEdges","margin","offset","outEdges","pathData","shape","style","tooltip","verticalAlignment","visibility","width"],Ile=[],ble=(()=>{class n extends Bh{constructor(e){super(),this.viewContainerRef=e,_l("currentInstance",this,this.viewContainerRef),this.registerEvents(Ile),this.directivePropList=Sle}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-node-port"]],inputs:{addInfo:"addInfo",connectionDirection:"connectionDirection",constraints:"constraints",height:"height",horizontalAlignment:"horizontalAlignment",id:"id",inEdges:"inEdges",margin:"margin",offset:"offset",outEdges:"outEdges",pathData:"pathData",shape:"shape",style:"style",tooltip:"tooltip",verticalAlignment:"verticalAlignment",visibility:"visibility",width:"width"},features:[yn]}),n})(),Mle=(()=>{class n extends Fh{constructor(){super("ports")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-node-ports"]],contentQueries:function(e,i,r){if(1&e&&dn(r,ble,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),wle=["addInfo","annotations","backgroundColor","borderColor","borderWidth","branch","children","collapseIcon","columnIndex","columnSpan","columns","constraints","container","data","dragSize","excludeFromLayout","expandIcon","fixedUserHandles","flip","flipMode","height","horizontalAlignment","id","isExpanded","layoutInfo","margin","maxHeight","maxWidth","minHeight","minWidth","offsetX","offsetY","padding","pivot","ports","previewSize","rotateAngle","rowIndex","rowSpan","rows","shadow","shape","style","symbolInfo","tooltip","verticalAlignment","visible","width","wrapper","zIndex"],Cle=[],Ele=(()=>{class n extends Bh{constructor(e){super(),this.viewContainerRef=e,this.tags=["fixedUserHandles","annotations","ports"],_l("currentInstance",this,this.viewContainerRef),this.registerEvents(Cle),this.directivePropList=wle}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-node"]],contentQueries:function(e,i,r){if(1&e&&(dn(r,ple,5),dn(r,yle,5),dn(r,Mle,5)),2&e){let s;Kr(s=en())&&(i.childFixedUserHandles=s.first),Kr(s=en())&&(i.childAnnotations=s.first),Kr(s=en())&&(i.childPorts=s.first)}},inputs:{addInfo:"addInfo",annotations:"annotations",backgroundColor:"backgroundColor",borderColor:"borderColor",borderWidth:"borderWidth",branch:"branch",children:"children",collapseIcon:"collapseIcon",columnIndex:"columnIndex",columnSpan:"columnSpan",columns:"columns",constraints:"constraints",container:"container",data:"data",dragSize:"dragSize",excludeFromLayout:"excludeFromLayout",expandIcon:"expandIcon",fixedUserHandles:"fixedUserHandles",flip:"flip",flipMode:"flipMode",height:"height",horizontalAlignment:"horizontalAlignment",id:"id",isExpanded:"isExpanded",layoutInfo:"layoutInfo",margin:"margin",maxHeight:"maxHeight",maxWidth:"maxWidth",minHeight:"minHeight",minWidth:"minWidth",offsetX:"offsetX",offsetY:"offsetY",padding:"padding",pivot:"pivot",ports:"ports",previewSize:"previewSize",rotateAngle:"rotateAngle",rowIndex:"rowIndex",rowSpan:"rowSpan",rows:"rows",shadow:"shadow",shape:"shape",style:"style",symbolInfo:"symbolInfo",tooltip:"tooltip",verticalAlignment:"verticalAlignment",visible:"visible",width:"width",wrapper:"wrapper",zIndex:"zIndex"},features:[yn]}),n})(),Dle=(()=>{class n extends Fh{constructor(){super("nodes")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-nodes"]],contentQueries:function(e,i,r){if(1&e&&dn(r,Ele,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})();const xle=["animationComplete","click","collectionChange","commandExecute","connectionChange","contextMenuBeforeItemRender","contextMenuClick","contextMenuOpen","created","dataLoaded","doubleClick","dragEnter","dragLeave","dragOver","drop","elementDraw","expandStateChange","fixedUserHandleClick","historyChange","historyStateChange","keyDown","keyUp","load","loaded","mouseEnter","mouseLeave","mouseOver","mouseWheel","onFixedUserHandleMouseDown","onFixedUserHandleMouseEnter","onFixedUserHandleMouseLeave","onFixedUserHandleMouseUp","onImageLoad","onUserHandleMouseDown","onUserHandleMouseEnter","onUserHandleMouseLeave","onUserHandleMouseUp","positionChange","propertyChange","rotateChange","scrollChange","segmentChange","segmentCollectionChange","selectionChange","sizeChange","sourcePointChange","targetPointChange","textEdit"],Tle=[""];let Ale=(()=>{let n=class extends Fl{constructor(e,i,r,s){super(),this.ngEle=e,this.srenderer=i,this.viewContainerRef=r,this.injector=s,this.tags=["layers","customCursor","connectors","nodes"],this.element=this.ngEle.nativeElement,this.injectedModules=this.injectedModules||[];try{let o=this.injector.get("DiagramsHierarchicalTree");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsMindMap");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsRadialTree");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsComplexHierarchicalTree");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsDataBinding");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsSnapping");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsPrintAndExport");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsBpmnDiagrams");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsSymmetricLayout");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsConnectorBridging");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsUndoRedo");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsLayoutAnimation");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsDiagramContextMenu");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsLineRouting");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsConnectorEditing");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsLineDistribution");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsEj1Serialization");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsFlowchartLayout");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}this.registerEvents(xle),this.addTwoWay.call(this,Tle),_l("currentInstance",this,this.viewContainerRef),this.context=new c_}ngOnInit(){this.context.ngOnInit(this)}ngAfterViewInit(){this.context.ngAfterViewInit(this)}ngOnDestroy(){this.context.ngOnDestroy(this)}ngAfterContentChecked(){this.tagObjects[0].instance=this.childLayers,this.childCustomCursor&&(this.tagObjects[1].instance=this.childCustomCursor),this.childConnectors&&(this.tagObjects[2].instance=this.childConnectors),this.childNodes&&(this.tagObjects[3].instance=this.childNodes),this.context.ngAfterContentChecked(this)}};return n.\u0275fac=function(e){return new(e||n)(Ot($c),Ot(sM),Ot(An),Ot(Wo))},n.\u0275cmp=zb({type:n,selectors:[["ejs-diagram"]],contentQueries:function(e,i,r){if(1&e&&(dn(r,jae,5),dn(r,Vae,5),dn(r,Wae,5),dn(r,Xae,5),dn(r,Jae,5),dn(r,cle,5),dn(r,Dle,5)),2&e){let s;Kr(s=en())&&(i.annotationTemplate=s.first),Kr(s=en())&&(i.nodeTemplate=s.first),Kr(s=en())&&(i.userHandleTemplate=s.first),Kr(s=en())&&(i.childLayers=s.first),Kr(s=en())&&(i.childCustomCursor=s.first),Kr(s=en())&&(i.childConnectors=s.first),Kr(s=en())&&(i.childNodes=s.first)}},inputs:{addInfo:"addInfo",annotationTemplate:"annotationTemplate",backgroundColor:"backgroundColor",bridgeDirection:"bridgeDirection",commandManager:"commandManager",connectorDefaults:"connectorDefaults",connectors:"connectors",constraints:"constraints",contextMenuSettings:"contextMenuSettings",customCursor:"customCursor",dataSourceSettings:"dataSourceSettings",diagramSettings:"diagramSettings",drawingObject:"drawingObject",enableConnectorSplit:"enableConnectorSplit",enablePersistence:"enablePersistence",enableRtl:"enableRtl",fixedUserHandleTemplate:"fixedUserHandleTemplate",getConnectorDefaults:"getConnectorDefaults",getCustomCursor:"getCustomCursor",getCustomProperty:"getCustomProperty",getCustomTool:"getCustomTool",getDescription:"getDescription",getNodeDefaults:"getNodeDefaults",height:"height",historyManager:"historyManager",layers:"layers",layout:"layout",locale:"locale",mode:"mode",nodeDefaults:"nodeDefaults",nodeTemplate:"nodeTemplate",nodes:"nodes",pageSettings:"pageSettings",rulerSettings:"rulerSettings",scrollSettings:"scrollSettings",segmentThumbShape:"segmentThumbShape",segmentThumbSize:"segmentThumbSize",selectedItems:"selectedItems",serializationSettings:"serializationSettings",setNodeTemplate:"setNodeTemplate",snapSettings:"snapSettings",tool:"tool",tooltip:"tooltip",updateSelection:"updateSelection",userHandleTemplate:"userHandleTemplate",width:"width"},outputs:{animationComplete:"animationComplete",click:"click",collectionChange:"collectionChange",commandExecute:"commandExecute",connectionChange:"connectionChange",contextMenuBeforeItemRender:"contextMenuBeforeItemRender",contextMenuClick:"contextMenuClick",contextMenuOpen:"contextMenuOpen",created:"created",dataLoaded:"dataLoaded",doubleClick:"doubleClick",dragEnter:"dragEnter",dragLeave:"dragLeave",dragOver:"dragOver",drop:"drop",elementDraw:"elementDraw",expandStateChange:"expandStateChange",fixedUserHandleClick:"fixedUserHandleClick",historyChange:"historyChange",historyStateChange:"historyStateChange",keyDown:"keyDown",keyUp:"keyUp",load:"load",loaded:"loaded",mouseEnter:"mouseEnter",mouseLeave:"mouseLeave",mouseOver:"mouseOver",mouseWheel:"mouseWheel",onFixedUserHandleMouseDown:"onFixedUserHandleMouseDown",onFixedUserHandleMouseEnter:"onFixedUserHandleMouseEnter",onFixedUserHandleMouseLeave:"onFixedUserHandleMouseLeave",onFixedUserHandleMouseUp:"onFixedUserHandleMouseUp",onImageLoad:"onImageLoad",onUserHandleMouseDown:"onUserHandleMouseDown",onUserHandleMouseEnter:"onUserHandleMouseEnter",onUserHandleMouseLeave:"onUserHandleMouseLeave",onUserHandleMouseUp:"onUserHandleMouseUp",positionChange:"positionChange",propertyChange:"propertyChange",rotateChange:"rotateChange",scrollChange:"scrollChange",segmentChange:"segmentChange",segmentCollectionChange:"segmentCollectionChange",selectionChange:"selectionChange",sizeChange:"sizeChange",sourcePointChange:"sourcePointChange",targetPointChange:"targetPointChange",textEdit:"textEdit"},features:[yn],decls:0,vars:0,template:function(e,i){},encapsulation:2,changeDetection:0}),db([xT()],n.prototype,"annotationTemplate",void 0),db([xT()],n.prototype,"nodeTemplate",void 0),db([xT()],n.prototype,"userHandleTemplate",void 0),n=db([Pae([c_])],n),n})(),Lle=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Tm({type:n}),n.\u0275inj=gp({imports:[[tq]]}),n})();const Nle={provide:"DiagramsHierarchicalTree",useValue:n_},Ole={provide:"DiagramsDataBinding",useValue:Koe},kle={provide:"DiagramsLayoutAnimation",useValue:uae},Ple=["diagram"];let zle=(()=>{class n{constructor(){this.data=[{Id:"parent1",Name:"Maria ",Designation:"Managing Director",RatingColor:"#C34444"},{Id:"parent",Name:" sam",Designation:"Managing Director",ReportingPerson:"parent1",RatingColor:"#C34444"}]}getNodeDefaults(e,i){return e.height=40,e.width=100,e.expandIcon={shape:"ArrowUp",width:20,height:20,fill:"red",borderColor:"blue",iconColor:"white",cornerRadius:7,borderWidth:2.5,offset:{x:.5,y:.85}},e.collapseIcon={offset:{x:.5,y:.85},shape:"ArrowDown",width:20,height:20,fill:"green",borderColor:"blue",iconColor:"white",cornerRadius:7,borderWidth:2.5},e.collapseIcon.height=15,e.collapseIcon.width=15,e.borderColor="white",e.backgroundColor="#6BA5D7",e.borderWidth=1,e.style={fill:"transparent",strokeWidth:2},e}getConnectorDefaults(e,i){return e.style={strokeColor:"#6BA5D7",strokeWidth:2},e.targetDecorator.style.fill="#6BA5D7",e.targetDecorator.style.strokeColor="#6BA5D7",e.targetDecorator.shape="None",e.type="Orthogonal",e}ngOnInit(){this.selectedItems={constraints:~lr.ResizeAll},this.snapSettings={constraints:0},this.items=new tt(this.data,(new Ht).take(7)),this.layout={enableAnimation:!0,type:"HierarchicalTree",margin:{top:20},getLayoutInfo:(e,i)=>{i.hasSubTree||(i.orientation="vertical",i.type="alternate")}},this.dataSourceSettings={id:"Id",parentId:"ReportingPerson",dataSource:this.items}}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275cmp=zb({type:n,selectors:[["app-container"]],viewQuery:function(i,r){if(1&i&&function dP(n,t,e){const i=Ti();i.firstCreatePass&&(hP(i,new oP(n,t,e),-1),2==(2&t)&&(i.staticViewQueries=!0)),lP(i,Se(),t)}(Ple,5),2&i){let s;Kr(s=en())&&(r.diagram=s.first)}},standalone:!0,features:[OP([Nle,Ole,kle]),PP],decls:2,vars:6,consts:[["id","diagram","width","100%","height","580px",3,"getNodeDefaults","getConnectorDefaults","snapSettings","selectedItems","layout","dataSourceSettings"],["diagram",""]],template:function(i,r){1&i&&tw(0,"ejs-diagram",0,1),2&i&&QM("getNodeDefaults",r.getNodeDefaults)("getConnectorDefaults",r.getConnectorDefaults)("snapSettings",r.snapSettings)("selectedItems",r.selectedItems)("layout",r.layout)("dataSourceSettings",r.dataSourceSettings)},dependencies:[Lle,Ale],encapsulation:2})}}return n})();jd(332),function Qq(n,t){return MG({rootComponent:n,...wz(t)})}(zle).catch(n=>console.error(n))},332:()=>{!function(Z){const se=Z.performance;function ye(zi){se&&se.mark&&se.mark(zi)}function pe(zi,ht){se&&se.measure&&se.measure(zi,ht)}ye("Zone");const be=Z.__Zone_symbol_prefix||"__zone_symbol__";function ke(zi){return be+zi}const at=!0===Z[ke("forceDuplicateZoneCheck")];if(Z.Zone){if(at||"function"!=typeof Z.Zone.__symbol__)throw new Error("Zone already loaded.");return Z.Zone}let it=(()=>{class zi{static{this.__symbol__=ke}static assertZonePatched(){if(Z.Promise!==_o.ZoneAwarePromise)throw new Error("Zone.js has detected that ZoneAwarePromise `(window|global).Promise` has been overwritten.\nMost likely cause is that a Promise polyfill has been loaded after Zone.js (Polyfilling Promise api is not necessary when zone.js is loaded. If you must load one, do so before loading zone.js.)")}static get root(){let F=zi.current;for(;F.parent;)F=F.parent;return F}static get current(){return Ur.zone}static get currentTask(){return Do}static __load_patch(F,ae,Et=!1){if(_o.hasOwnProperty(F)){if(!Et&&at)throw Error("Already loaded patch: "+F)}else if(!Z["__Zone_disable_"+F]){const Xt="Zone:"+F;ye(Xt),_o[F]=ae(Z,zi,cn),pe(Xt,Xt)}}get parent(){return this._parent}get name(){return this._name}constructor(F,ae){this._parent=F,this._name=ae?ae.name||"unnamed":"",this._properties=ae&&ae.properties||{},this._zoneDelegate=new Lt(this,this._parent&&this._parent._zoneDelegate,ae)}get(F){const ae=this.getZoneWith(F);if(ae)return ae._properties[F]}getZoneWith(F){let ae=this;for(;ae;){if(ae._properties.hasOwnProperty(F))return ae;ae=ae._parent}return null}fork(F){if(!F)throw new Error("ZoneSpec required!");return this._zoneDelegate.fork(this,F)}wrap(F,ae){if("function"!=typeof F)throw new Error("Expecting function got: "+F);const Et=this._zoneDelegate.intercept(this,F,ae),Xt=this;return function(){return Xt.runGuarded(Et,this,arguments,ae)}}run(F,ae,Et,Xt){Ur={parent:Ur,zone:this};try{return this._zoneDelegate.invoke(this,F,ae,Et,Xt)}finally{Ur=Ur.parent}}runGuarded(F,ae=null,Et,Xt){Ur={parent:Ur,zone:this};try{try{return this._zoneDelegate.invoke(this,F,ae,Et,Xt)}catch(Vn){if(this._zoneDelegate.handleError(this,Vn))throw Vn}}finally{Ur=Ur.parent}}runTask(F,ae,Et){if(F.zone!=this)throw new Error("A task can only be run in the zone of creation! (Creation: "+(F.zone||jn).name+"; Execution: "+this.name+")");if(F.state===sr&&(F.type===rs||F.type===Pt))return;const Xt=F.state!=lt;Xt&&F._transitionTo(lt,Pi),F.runCount++;const Vn=Do;Do=F,Ur={parent:Ur,zone:this};try{F.type==Pt&&F.data&&!F.data.isPeriodic&&(F.cancelFn=void 0);try{return this._zoneDelegate.invokeTask(this,F,ae,Et)}catch(Ue){if(this._zoneDelegate.handleError(this,Ue))throw Ue}}finally{F.state!==sr&&F.state!==et&&(F.type==rs||F.data&&F.data.isPeriodic?Xt&&F._transitionTo(Pi,lt):(F.runCount=0,this._updateTaskCount(F,-1),Xt&&F._transitionTo(sr,lt,sr))),Ur=Ur.parent,Do=Vn}}scheduleTask(F){if(F.zone&&F.zone!==this){let Et=this;for(;Et;){if(Et===F.zone)throw Error(`can not reschedule task to ${this.name} which is descendants of the original zone ${F.zone.name}`);Et=Et.parent}}F._transitionTo(Zr,sr);const ae=[];F._zoneDelegates=ae,F._zone=this;try{F=this._zoneDelegate.scheduleTask(this,F)}catch(Et){throw F._transitionTo(et,Zr,sr),this._zoneDelegate.handleError(this,Et),Et}return F._zoneDelegates===ae&&this._updateTaskCount(F,1),F.state==Zr&&F._transitionTo(Pi,Zr),F}scheduleMicroTask(F,ae,Et,Xt){return this.scheduleTask(new pt(yi,F,ae,Et,Xt,void 0))}scheduleMacroTask(F,ae,Et,Xt,Vn){return this.scheduleTask(new pt(Pt,F,ae,Et,Xt,Vn))}scheduleEventTask(F,ae,Et,Xt,Vn){return this.scheduleTask(new pt(rs,F,ae,Et,Xt,Vn))}cancelTask(F){if(F.zone!=this)throw new Error("A task can only be cancelled in the zone of creation! (Creation: "+(F.zone||jn).name+"; Execution: "+this.name+")");if(F.state===Pi||F.state===lt){F._transitionTo(ur,Pi,lt);try{this._zoneDelegate.cancelTask(this,F)}catch(ae){throw F._transitionTo(et,ur),this._zoneDelegate.handleError(this,ae),ae}return this._updateTaskCount(F,-1),F._transitionTo(sr,ur),F.runCount=0,F}}_updateTaskCount(F,ae){const Et=F._zoneDelegates;-1==ae&&(F._zoneDelegates=null);for(let Xt=0;Xtzi.hasTask(F,ae),onScheduleTask:(zi,ht,F,ae)=>zi.scheduleTask(F,ae),onInvokeTask:(zi,ht,F,ae,Et,Xt)=>zi.invokeTask(F,ae,Et,Xt),onCancelTask:(zi,ht,F,ae)=>zi.cancelTask(F,ae)};class Lt{constructor(ht,F,ae){this._taskCounts={microTask:0,macroTask:0,eventTask:0},this.zone=ht,this._parentDelegate=F,this._forkZS=ae&&(ae&&ae.onFork?ae:F._forkZS),this._forkDlgt=ae&&(ae.onFork?F:F._forkDlgt),this._forkCurrZone=ae&&(ae.onFork?this.zone:F._forkCurrZone),this._interceptZS=ae&&(ae.onIntercept?ae:F._interceptZS),this._interceptDlgt=ae&&(ae.onIntercept?F:F._interceptDlgt),this._interceptCurrZone=ae&&(ae.onIntercept?this.zone:F._interceptCurrZone),this._invokeZS=ae&&(ae.onInvoke?ae:F._invokeZS),this._invokeDlgt=ae&&(ae.onInvoke?F:F._invokeDlgt),this._invokeCurrZone=ae&&(ae.onInvoke?this.zone:F._invokeCurrZone),this._handleErrorZS=ae&&(ae.onHandleError?ae:F._handleErrorZS),this._handleErrorDlgt=ae&&(ae.onHandleError?F:F._handleErrorDlgt),this._handleErrorCurrZone=ae&&(ae.onHandleError?this.zone:F._handleErrorCurrZone),this._scheduleTaskZS=ae&&(ae.onScheduleTask?ae:F._scheduleTaskZS),this._scheduleTaskDlgt=ae&&(ae.onScheduleTask?F:F._scheduleTaskDlgt),this._scheduleTaskCurrZone=ae&&(ae.onScheduleTask?this.zone:F._scheduleTaskCurrZone),this._invokeTaskZS=ae&&(ae.onInvokeTask?ae:F._invokeTaskZS),this._invokeTaskDlgt=ae&&(ae.onInvokeTask?F:F._invokeTaskDlgt),this._invokeTaskCurrZone=ae&&(ae.onInvokeTask?this.zone:F._invokeTaskCurrZone),this._cancelTaskZS=ae&&(ae.onCancelTask?ae:F._cancelTaskZS),this._cancelTaskDlgt=ae&&(ae.onCancelTask?F:F._cancelTaskDlgt),this._cancelTaskCurrZone=ae&&(ae.onCancelTask?this.zone:F._cancelTaskCurrZone),this._hasTaskZS=null,this._hasTaskDlgt=null,this._hasTaskDlgtOwner=null,this._hasTaskCurrZone=null;const Et=ae&&ae.onHasTask;(Et||F&&F._hasTaskZS)&&(this._hasTaskZS=Et?ae:At,this._hasTaskDlgt=F,this._hasTaskDlgtOwner=this,this._hasTaskCurrZone=ht,ae.onScheduleTask||(this._scheduleTaskZS=At,this._scheduleTaskDlgt=F,this._scheduleTaskCurrZone=this.zone),ae.onInvokeTask||(this._invokeTaskZS=At,this._invokeTaskDlgt=F,this._invokeTaskCurrZone=this.zone),ae.onCancelTask||(this._cancelTaskZS=At,this._cancelTaskDlgt=F,this._cancelTaskCurrZone=this.zone))}fork(ht,F){return this._forkZS?this._forkZS.onFork(this._forkDlgt,this.zone,ht,F):new it(ht,F)}intercept(ht,F,ae){return this._interceptZS?this._interceptZS.onIntercept(this._interceptDlgt,this._interceptCurrZone,ht,F,ae):F}invoke(ht,F,ae,Et,Xt){return this._invokeZS?this._invokeZS.onInvoke(this._invokeDlgt,this._invokeCurrZone,ht,F,ae,Et,Xt):F.apply(ae,Et)}handleError(ht,F){return!this._handleErrorZS||this._handleErrorZS.onHandleError(this._handleErrorDlgt,this._handleErrorCurrZone,ht,F)}scheduleTask(ht,F){let ae=F;if(this._scheduleTaskZS)this._hasTaskZS&&ae._zoneDelegates.push(this._hasTaskDlgtOwner),ae=this._scheduleTaskZS.onScheduleTask(this._scheduleTaskDlgt,this._scheduleTaskCurrZone,ht,F),ae||(ae=F);else if(F.scheduleFn)F.scheduleFn(F);else{if(F.type!=yi)throw new Error("Task is missing scheduleFn.");Wt(F)}return ae}invokeTask(ht,F,ae,Et){return this._invokeTaskZS?this._invokeTaskZS.onInvokeTask(this._invokeTaskDlgt,this._invokeTaskCurrZone,ht,F,ae,Et):F.callback.apply(ae,Et)}cancelTask(ht,F){let ae;if(this._cancelTaskZS)ae=this._cancelTaskZS.onCancelTask(this._cancelTaskDlgt,this._cancelTaskCurrZone,ht,F);else{if(!F.cancelFn)throw Error("Task is not cancelable");ae=F.cancelFn(F)}return ae}hasTask(ht,F){try{this._hasTaskZS&&this._hasTaskZS.onHasTask(this._hasTaskDlgt,this._hasTaskCurrZone,ht,F)}catch(ae){this.handleError(ht,ae)}}_updateTaskCount(ht,F){const ae=this._taskCounts,Et=ae[ht],Xt=ae[ht]=Et+F;if(Xt<0)throw new Error("More tasks executed then were scheduled.");0!=Et&&0!=Xt||this.hasTask(this.zone,{microTask:ae.microTask>0,macroTask:ae.macroTask>0,eventTask:ae.eventTask>0,change:ht})}}class pt{constructor(ht,F,ae,Et,Xt,Vn){if(this._zone=null,this.runCount=0,this._zoneDelegates=null,this._state="notScheduled",this.type=ht,this.source=F,this.data=Et,this.scheduleFn=Xt,this.cancelFn=Vn,!ae)throw new Error("callback is not defined");this.callback=ae;const Ue=this;this.invoke=ht===rs&&Et&&Et.useG?pt.invokeTask:function(){return pt.invokeTask.call(Z,Ue,this,arguments)}}static invokeTask(ht,F,ae){ht||(ht=this),Ls++;try{return ht.runCount++,ht.zone.runTask(ht,F,ae)}finally{1==Ls&&ct(),Ls--}}get zone(){return this._zone}get state(){return this._state}cancelScheduleRequest(){this._transitionTo(sr,Zr)}_transitionTo(ht,F,ae){if(this._state!==F&&this._state!==ae)throw new Error(`${this.type} '${this.source}': can not transition to '${ht}', expecting state '${F}'${ae?" or '"+ae+"'":""}, was '${this._state}'.`);this._state=ht,ht==sr&&(this._zoneDelegates=null)}toString(){return this.data&&typeof this.data.handleId<"u"?this.data.handleId.toString():Object.prototype.toString.call(this)}toJSON(){return{type:this.type,state:this.state,source:this.source,zone:this.zone.name,runCount:this.runCount}}}const Di=ke("setTimeout"),ni=ke("Promise"),mi=ke("then");let is,dr=[],ki=!1;function Pr(zi){if(is||Z[ni]&&(is=Z[ni].resolve(0)),is){let ht=is[mi];ht||(ht=is.then),ht.call(is,zi)}else Z[Di](zi,0)}function Wt(zi){0===Ls&&0===dr.length&&Pr(ct),zi&&dr.push(zi)}function ct(){if(!ki){for(ki=!0;dr.length;){const zi=dr;dr=[];for(let ht=0;htUr,onUnhandledError:jr,microtaskDrainDone:jr,scheduleMicroTask:Wt,showUncaughtError:()=>!it[ke("ignoreConsoleErrorUncaughtError")],patchEventTarget:()=>[],patchOnProperties:jr,patchMethod:()=>jr,bindArguments:()=>[],patchThen:()=>jr,patchMacroTask:()=>jr,patchEventPrototype:()=>jr,isIEOrEdge:()=>!1,getGlobalObjects:()=>{},ObjectDefineProperty:()=>jr,ObjectGetOwnPropertyDescriptor:()=>{},ObjectCreate:()=>{},ArraySlice:()=>[],patchClass:()=>jr,wrapWithCurrentZone:()=>jr,filterProperties:()=>[],attachOriginToPatched:()=>jr,_redefineProperty:()=>jr,patchCallbacks:()=>jr,nativeScheduleMicroTask:Pr};let Ur={parent:null,zone:new it(null,null)},Do=null,Ls=0;function jr(){}pe("Zone","Zone"),Z.Zone=it}(globalThis);const Wl=Object.getOwnPropertyDescriptor,Ud=Object.defineProperty,jd=Object.getPrototypeOf,Vd=Object.create,pb=Array.prototype.slice,um="addEventListener",$r="removeEventListener",Yl=Zone.__symbol__(um),_h=Zone.__symbol__($r),Ts="true",Wi="false",Wd=Zone.__symbol__("");function op(Z,se){return Zone.current.wrap(Z,se)}function fm(Z,se,ye,pe,be){return Zone.current.scheduleMacroTask(Z,se,ye,pe,be)}const Ji=Zone.__symbol__,Uh=typeof window<"u",jh=Uh?window:void 0,gn=Uh&&jh||globalThis,pm="removeAttribute";function Yd(Z,se){for(let ye=Z.length-1;ye>=0;ye--)"function"==typeof Z[ye]&&(Z[ye]=op(Z[ye],se+"_"+ye));return Z}function ap(Z){return!Z||!1!==Z.writable&&!("function"==typeof Z.get&&typeof Z.set>"u")}const lp=typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope,Vh=!("nw"in gn)&&typeof gn.process<"u"&&"[object process]"==={}.toString.call(gn.process),Qd=!Vh&&!lp&&!(!Uh||!jh.HTMLElement),hp=typeof gn.process<"u"&&"[object process]"==={}.toString.call(gn.process)&&!lp&&!(!Uh||!jh.HTMLElement),Ql={},Wh=function(Z){if(!(Z=Z||gn.event))return;let se=Ql[Z.type];se||(se=Ql[Z.type]=Ji("ON_PROPERTY"+Z.type));const ye=this||Z.target||gn,pe=ye[se];let be;return Qd&&ye===jh&&"error"===Z.type?(be=pe&&pe.call(this,Z.message,Z.filename,Z.lineno,Z.colno,Z.error),!0===be&&Z.preventDefault()):(be=pe&&pe.apply(this,arguments),null!=be&&!be&&Z.preventDefault()),be};function Gl(Z,se,ye){let pe=Wl(Z,se);if(!pe&&ye&&Wl(ye,se)&&(pe={enumerable:!0,configurable:!0}),!pe||!pe.configurable)return;const be=Ji("on"+se+"patched");if(Z.hasOwnProperty(be)&&Z[be])return;delete pe.writable,delete pe.value;const ke=pe.get,at=pe.set,it=se.slice(2);let At=Ql[it];At||(At=Ql[it]=Ji("ON_PROPERTY"+it)),pe.set=function(Lt){let pt=this;!pt&&Z===gn&&(pt=gn),pt&&("function"==typeof pt[At]&&pt.removeEventListener(it,Wh),at&&at.call(pt,null),pt[At]=Lt,"function"==typeof Lt&&pt.addEventListener(it,Wh,!1))},pe.get=function(){let Lt=this;if(!Lt&&Z===gn&&(Lt=gn),!Lt)return null;const pt=Lt[At];if(pt)return pt;if(ke){let Di=ke.call(this);if(Di)return pe.set.call(this,Di),"function"==typeof Lt[pm]&&Lt.removeAttribute(se),Di}return null},Ud(Z,se,pe),Z[be]=!0}function cp(Z,se,ye){if(se)for(let pe=0;pefunction(at,it){const At=ye(at,it);return At.cbIdx>=0&&"function"==typeof it[At.cbIdx]?fm(At.name,it[At.cbIdx],At,be):ke.apply(at,it)})}function Ia(Z,se){Z[Ji("OriginalDelegate")]=se}let vb=!1,Xd=!1;function mb(){if(vb)return Xd;vb=!0;try{const Z=jh.navigator.userAgent;(-1!==Z.indexOf("MSIE ")||-1!==Z.indexOf("Trident/")||-1!==Z.indexOf("Edge/"))&&(Xd=!0)}catch{}return Xd}Zone.__load_patch("ZoneAwarePromise",(Z,se,ye)=>{const pe=Object.getOwnPropertyDescriptor,be=Object.defineProperty,at=ye.symbol,it=[],At=!1!==Z[at("DISABLE_WRAPPING_UNCAUGHT_PROMISE_REJECTION")],Lt=at("Promise"),pt=at("then"),Di="__creationTrace__";ye.onUnhandledError=Ue=>{if(ye.showUncaughtError()){const He=Ue&&Ue.rejection;He?console.error("Unhandled Promise rejection:",He instanceof Error?He.message:He,"; Zone:",Ue.zone.name,"; Task:",Ue.task&&Ue.task.source,"; Value:",He,He instanceof Error?He.stack:void 0):console.error(Ue)}},ye.microtaskDrainDone=()=>{for(;it.length;){const Ue=it.shift();try{Ue.zone.runGuarded(()=>{throw Ue.throwOriginal?Ue.rejection:Ue})}catch(He){mi(He)}}};const ni=at("unhandledPromiseRejectionHandler");function mi(Ue){ye.onUnhandledError(Ue);try{const He=se[ni];"function"==typeof He&&He.call(this,Ue)}catch{}}function dr(Ue){return Ue&&Ue.then}function ki(Ue){return Ue}function is(Ue){return F.reject(Ue)}const Pr=at("state"),Wt=at("value"),ct=at("finally"),jn=at("parentPromiseValue"),sr=at("parentPromiseState"),Zr="Promise.then",Pi=null,lt=!0,ur=!1,et=0;function yi(Ue,He){return ge=>{try{cn(Ue,He,ge)}catch(We){cn(Ue,!1,We)}}}const Pt=function(){let Ue=!1;return function(ge){return function(){Ue||(Ue=!0,ge.apply(null,arguments))}}},rs="Promise resolved with itself",_o=at("currentTaskTrace");function cn(Ue,He,ge){const We=Pt();if(Ue===ge)throw new TypeError(rs);if(Ue[Pr]===Pi){let wt=null;try{("object"==typeof ge||"function"==typeof ge)&&(wt=ge&&ge.then)}catch(Xe){return We(()=>{cn(Ue,!1,Xe)})(),Ue}if(He!==ur&&ge instanceof F&&ge.hasOwnProperty(Pr)&&ge.hasOwnProperty(Wt)&&ge[Pr]!==Pi)Do(ge),cn(Ue,ge[Pr],ge[Wt]);else if(He!==ur&&"function"==typeof wt)try{wt.call(ge,We(yi(Ue,He)),We(yi(Ue,!1)))}catch(Xe){We(()=>{cn(Ue,!1,Xe)})()}else{Ue[Pr]=He;const Xe=Ue[Wt];if(Ue[Wt]=ge,Ue[ct]===ct&&He===lt&&(Ue[Pr]=Ue[sr],Ue[Wt]=Ue[jn]),He===ur&&ge instanceof Error){const mt=se.currentTask&&se.currentTask.data&&se.currentTask.data[Di];mt&&be(ge,_o,{configurable:!0,enumerable:!1,writable:!0,value:mt})}for(let mt=0;mt{try{const dt=Ue[Wt],qt=!!ge&&ct===ge[ct];qt&&(ge[jn]=dt,ge[sr]=Xe);const li=He.run(mt,void 0,qt&&mt!==is&&mt!==ki?[]:[dt]);cn(ge,!0,li)}catch(dt){cn(ge,!1,dt)}},ge)}const zi=function(){},ht=Z.AggregateError;class F{static toString(){return"function ZoneAwarePromise() { [native code] }"}static resolve(He){return He instanceof F?He:cn(new this(null),lt,He)}static reject(He){return cn(new this(null),ur,He)}static withResolvers(){const He={};return He.promise=new F((ge,We)=>{He.resolve=ge,He.reject=We}),He}static any(He){if(!He||"function"!=typeof He[Symbol.iterator])return Promise.reject(new ht([],"All promises were rejected"));const ge=[];let We=0;try{for(let mt of He)We++,ge.push(F.resolve(mt))}catch{return Promise.reject(new ht([],"All promises were rejected"))}if(0===We)return Promise.reject(new ht([],"All promises were rejected"));let wt=!1;const Xe=[];return new F((mt,dt)=>{for(let qt=0;qt{wt||(wt=!0,mt(li))},li=>{Xe.push(li),We--,0===We&&(wt=!0,dt(new ht(Xe,"All promises were rejected")))})})}static race(He){let ge,We,wt=new this((dt,qt)=>{ge=dt,We=qt});function Xe(dt){ge(dt)}function mt(dt){We(dt)}for(let dt of He)dr(dt)||(dt=this.resolve(dt)),dt.then(Xe,mt);return wt}static all(He){return F.allWithCallback(He)}static allSettled(He){return(this&&this.prototype instanceof F?this:F).allWithCallback(He,{thenCallback:We=>({status:"fulfilled",value:We}),errorCallback:We=>({status:"rejected",reason:We})})}static allWithCallback(He,ge){let We,wt,Xe=new this((li,fr)=>{We=li,wt=fr}),mt=2,dt=0;const qt=[];for(let li of He){dr(li)||(li=this.resolve(li));const fr=dt;try{li.then(ir=>{qt[fr]=ge?ge.thenCallback(ir):ir,mt--,0===mt&&We(qt)},ir=>{ge?(qt[fr]=ge.errorCallback(ir),mt--,0===mt&&We(qt)):wt(ir)})}catch(ir){wt(ir)}mt++,dt++}return mt-=2,0===mt&&We(qt),Xe}constructor(He){const ge=this;if(!(ge instanceof F))throw new Error("Must be an instanceof Promise.");ge[Pr]=Pi,ge[Wt]=[];try{const We=Pt();He&&He(We(yi(ge,lt)),We(yi(ge,ur)))}catch(We){cn(ge,!1,We)}}get[Symbol.toStringTag](){return"Promise"}get[Symbol.species](){return F}then(He,ge){let We=this.constructor?.[Symbol.species];(!We||"function"!=typeof We)&&(We=this.constructor||F);const wt=new We(zi),Xe=se.current;return this[Pr]==Pi?this[Wt].push(Xe,wt,He,ge):Ls(this,Xe,wt,He,ge),wt}catch(He){return this.then(null,He)}finally(He){let ge=this.constructor?.[Symbol.species];(!ge||"function"!=typeof ge)&&(ge=F);const We=new ge(zi);We[ct]=ct;const wt=se.current;return this[Pr]==Pi?this[Wt].push(wt,We,He,He):Ls(this,wt,We,He,He),We}}F.resolve=F.resolve,F.reject=F.reject,F.race=F.race,F.all=F.all;const ae=Z[Lt]=Z.Promise;Z.Promise=F;const Et=at("thenPatched");function Xt(Ue){const He=Ue.prototype,ge=pe(He,"then");if(ge&&(!1===ge.writable||!ge.configurable))return;const We=He.then;He[pt]=We,Ue.prototype.then=function(wt,Xe){return new F((dt,qt)=>{We.call(this,dt,qt)}).then(wt,Xe)},Ue[Et]=!0}return ye.patchThen=Xt,ae&&(Xt(ae),tl(Z,"fetch",Ue=>function Vn(Ue){return function(He,ge){let We=Ue.apply(He,ge);if(We instanceof F)return We;let wt=We.constructor;return wt[Et]||Xt(wt),We}}(Ue))),Promise[se.__symbol__("uncaughtPromiseErrors")]=it,F}),Zone.__load_patch("toString",Z=>{const se=Function.prototype.toString,ye=Ji("OriginalDelegate"),pe=Ji("Promise"),be=Ji("Error"),ke=function(){if("function"==typeof this){const Lt=this[ye];if(Lt)return"function"==typeof Lt?se.call(Lt):Object.prototype.toString.call(Lt);if(this===Promise){const pt=Z[pe];if(pt)return se.call(pt)}if(this===Error){const pt=Z[be];if(pt)return se.call(pt)}}return se.call(this)};ke[ye]=se,Function.prototype.toString=ke;const at=Object.prototype.toString;Object.prototype.toString=function(){return"function"==typeof Promise&&this instanceof Promise?"[object Promise]":at.call(this)}});let il=!1;if(typeof window<"u")try{const Z=Object.defineProperty({},"passive",{get:function(){il=!0}});window.addEventListener("test",Z,Z),window.removeEventListener("test",Z,Z)}catch{il=!1}const OT={useG:!0},Co={},yb={},mm=new RegExp("^"+Wd+"(\\w+)(true|false)$"),Sb=Ji("propagationStopped");function ym(Z,se){const ye=(se?se(Z):Z)+Wi,pe=(se?se(Z):Z)+Ts,be=Wd+ye,ke=Wd+pe;Co[Z]={},Co[Z][Wi]=be,Co[Z][Ts]=ke}function Ib(Z,se,ye,pe){const be=pe&&pe.add||um,ke=pe&&pe.rm||$r,at=pe&&pe.listeners||"eventListeners",it=pe&&pe.rmAll||"removeAllListeners",At=Ji(be),Lt="."+be+":",pt="prependListener",Di="."+pt+":",ni=function(Wt,ct,jn){if(Wt.isRemoved)return;const sr=Wt.callback;let Zr;"object"==typeof sr&&sr.handleEvent&&(Wt.callback=lt=>sr.handleEvent(lt),Wt.originalDelegate=sr);try{Wt.invoke(Wt,ct,[jn])}catch(lt){Zr=lt}const Pi=Wt.options;return Pi&&"object"==typeof Pi&&Pi.once&&ct[ke].call(ct,jn.type,Wt.originalDelegate?Wt.originalDelegate:Wt.callback,Pi),Zr};function mi(Wt,ct,jn){if(!(ct=ct||Z.event))return;const sr=Wt||ct.target||Z,Zr=sr[Co[ct.type][jn?Ts:Wi]];if(Zr){const Pi=[];if(1===Zr.length){const lt=ni(Zr[0],sr,ct);lt&&Pi.push(lt)}else{const lt=Zr.slice();for(let ur=0;ur{throw ur})}}}const dr=function(Wt){return mi(this,Wt,!1)},ki=function(Wt){return mi(this,Wt,!0)};function is(Wt,ct){if(!Wt)return!1;let jn=!0;ct&&void 0!==ct.useG&&(jn=ct.useG);const sr=ct&&ct.vh;let Zr=!0;ct&&void 0!==ct.chkDup&&(Zr=ct.chkDup);let Pi=!1;ct&&void 0!==ct.rt&&(Pi=ct.rt);let lt=Wt;for(;lt&&!lt.hasOwnProperty(be);)lt=jd(lt);if(!lt&&Wt[be]&&(lt=Wt),!lt||lt[At])return!1;const ur=ct&&ct.eventNameToString,et={},yi=lt[At]=lt[be],Pt=lt[Ji(ke)]=lt[ke],rs=lt[Ji(at)]=lt[at],_o=lt[Ji(it)]=lt[it];let cn;ct&&ct.prepend&&(cn=lt[Ji(ct.prepend)]=lt[ct.prepend]);const F=jn?function(ge){if(!et.isExisting)return yi.call(et.target,et.eventName,et.capture?ki:dr,et.options)}:function(ge){return yi.call(et.target,et.eventName,ge.invoke,et.options)},ae=jn?function(ge){if(!ge.isRemoved){const We=Co[ge.eventName];let wt;We&&(wt=We[ge.capture?Ts:Wi]);const Xe=wt&&ge.target[wt];if(Xe)for(let mt=0;mt{Vo.zone.cancelTask(Vo)},{once:!0})),et.target=null,Fc&&(Fc.taskData=null),$d&&(Tn.once=!0),!il&&"boolean"==typeof Vo.options||(Vo.options=Tn),Vo.target=qt,Vo.capture=Zl,Vo.eventName=li,ir&&(Vo.originalDelegate=fr),dt?jo.unshift(Vo):jo.push(Vo),mt?qt:void 0}};return lt[be]=He(yi,Lt,F,ae,Pi),cn&&(lt[pt]=He(cn,Di,function(ge){return cn.call(et.target,et.eventName,ge.invoke,et.options)},ae,Pi,!0)),lt[ke]=function(){const ge=this||Z;let We=arguments[0];ct&&ct.transferEventName&&(We=ct.transferEventName(We));const wt=arguments[2],Xe=!!wt&&("boolean"==typeof wt||wt.capture),mt=arguments[1];if(!mt)return Pt.apply(this,arguments);if(sr&&!sr(Pt,mt,ge,arguments))return;const dt=Co[We];let qt;dt&&(qt=dt[Xe?Ts:Wi]);const li=qt&&ge[qt];if(li)for(let fr=0;frfunction(be,ke){be[Sb]=!0,pe&&pe.apply(be,ke)})}function Mb(Z,se,ye,pe,be){const ke=Zone.__symbol__(pe);if(se[ke])return;const at=se[ke]=se[pe];se[pe]=function(it,At,Lt){return At&&At.prototype&&be.forEach(function(pt){const Di=`${ye}.${pe}::`+pt,ni=At.prototype;try{if(ni.hasOwnProperty(pt)){const mi=Z.ObjectGetOwnPropertyDescriptor(ni,pt);mi&&mi.value?(mi.value=Z.wrapWithCurrentZone(mi.value,Di),Z._redefineProperty(At.prototype,pt,mi)):ni[pt]&&(ni[pt]=Z.wrapWithCurrentZone(ni[pt],Di))}else ni[pt]&&(ni[pt]=Z.wrapWithCurrentZone(ni[pt],Di))}catch{}}),at.call(se,it,At,Lt)},Z.attachOriginToPatched(se[pe],at)}function wb(Z,se,ye){if(!ye||0===ye.length)return se;const pe=ye.filter(ke=>ke.target===Z);if(!pe||0===pe.length)return se;const be=pe[0].ignoreProperties;return se.filter(ke=>-1===be.indexOf(ke))}function Eo(Z,se,ye,pe){Z&&cp(Z,wb(Z,se,ye),pe)}function qd(Z){return Object.getOwnPropertyNames(Z).filter(se=>se.startsWith("on")&&se.length>2).map(se=>se.substring(2))}Zone.__load_patch("util",(Z,se,ye)=>{const pe=qd(Z);ye.patchOnProperties=cp,ye.patchMethod=tl,ye.bindArguments=Yd,ye.patchMacroTask=gb;const be=se.__symbol__("BLACK_LISTED_EVENTS"),ke=se.__symbol__("UNPATCHED_EVENTS");Z[ke]&&(Z[be]=Z[ke]),Z[be]&&(se[be]=se[ke]=Z[be]),ye.patchEventPrototype=Sm,ye.patchEventTarget=Ib,ye.isIEOrEdge=mb,ye.ObjectDefineProperty=Ud,ye.ObjectGetOwnPropertyDescriptor=Wl,ye.ObjectCreate=Vd,ye.ArraySlice=pb,ye.patchClass=Gd,ye.wrapWithCurrentZone=op,ye.filterProperties=wb,ye.attachOriginToPatched=Ia,ye._redefineProperty=Object.defineProperty,ye.patchCallbacks=Mb,ye.getGlobalObjects=()=>({globalSources:yb,zoneSymbolEventNames:Co,eventNames:pe,isBrowser:Qd,isMix:hp,isNode:Vh,TRUE_STR:Ts,FALSE_STR:Wi,ZONE_SYMBOL_PREFIX:Wd,ADD_EVENT_LISTENER_STR:um,REMOVE_EVENT_LISTENER_STR:$r})});const As=Ji("zoneTask");function Xl(Z,se,ye,pe){let be=null,ke=null;ye+=pe;const at={};function it(Lt){const pt=Lt.data;return pt.args[0]=function(){return Lt.invoke.apply(this,arguments)},pt.handleId=be.apply(Z,pt.args),Lt}function At(Lt){return ke.call(Z,Lt.data.handleId)}be=tl(Z,se+=pe,Lt=>function(pt,Di){if("function"==typeof Di[0]){const ni={isPeriodic:"Interval"===pe,delay:"Timeout"===pe||"Interval"===pe?Di[1]||0:void 0,args:Di},mi=Di[0];Di[0]=function(){try{return mi.apply(this,arguments)}finally{ni.isPeriodic||("number"==typeof ni.handleId?delete at[ni.handleId]:ni.handleId&&(ni.handleId[As]=null))}};const dr=fm(se,Di[0],ni,it,At);if(!dr)return dr;const ki=dr.data.handleId;return"number"==typeof ki?at[ki]=dr:ki&&(ki[As]=dr),ki&&ki.ref&&ki.unref&&"function"==typeof ki.ref&&"function"==typeof ki.unref&&(dr.ref=ki.ref.bind(ki),dr.unref=ki.unref.bind(ki)),"number"==typeof ki||ki?ki:dr}return Lt.apply(Z,Di)}),ke=tl(Z,ye,Lt=>function(pt,Di){const ni=Di[0];let mi;"number"==typeof ni?mi=at[ni]:(mi=ni&&ni[As],mi||(mi=ni)),mi&&"string"==typeof mi.type?"notScheduled"!==mi.state&&(mi.cancelFn&&mi.data.isPeriodic||0===mi.runCount)&&("number"==typeof ni?delete at[ni]:ni&&(ni[As]=null),mi.zone.cancelTask(mi)):Lt.apply(Z,Di)})}Zone.__load_patch("legacy",Z=>{const se=Z[Zone.__symbol__("legacyPatch")];se&&se()}),Zone.__load_patch("timers",Z=>{const ye="clear";Xl(Z,"set",ye,"Timeout"),Xl(Z,"set",ye,"Interval"),Xl(Z,"set",ye,"Immediate")}),Zone.__load_patch("requestAnimationFrame",Z=>{Xl(Z,"request","cancel","AnimationFrame"),Xl(Z,"mozRequest","mozCancel","AnimationFrame"),Xl(Z,"webkitRequest","webkitCancel","AnimationFrame")}),Zone.__load_patch("blocking",(Z,se)=>{const ye=["alert","prompt","confirm"];for(let pe=0;pefunction(At,Lt){return se.current.run(ke,Z,Lt,it)})}),Zone.__load_patch("EventTarget",(Z,se,ye)=>{(function ql(Z,se){se.patchEventPrototype(Z,se)})(Z,ye),function bm(Z,se){if(Zone[se.symbol("patchEventTarget")])return;const{eventNames:ye,zoneSymbolEventNames:pe,TRUE_STR:be,FALSE_STR:ke,ZONE_SYMBOL_PREFIX:at}=se.getGlobalObjects();for(let At=0;At{Gd("MutationObserver"),Gd("WebKitMutationObserver")}),Zone.__load_patch("IntersectionObserver",(Z,se,ye)=>{Gd("IntersectionObserver")}),Zone.__load_patch("FileReader",(Z,se,ye)=>{Gd("FileReader")}),Zone.__load_patch("on_property",(Z,se,ye)=>{!function dp(Z,se){if(Vh&&!hp||Zone[Z.symbol("patchEvents")])return;const ye=se.__Zone_ignore_on_properties;let pe=[];if(Qd){const be=window;pe=pe.concat(["Document","SVGElement","Element","HTMLElement","HTMLBodyElement","HTMLMediaElement","HTMLFrameSetElement","HTMLFrameElement","HTMLIFrameElement","HTMLMarqueeElement","Worker"]);const ke=function vm(){try{const Z=jh.navigator.userAgent;if(-1!==Z.indexOf("MSIE ")||-1!==Z.indexOf("Trident/"))return!0}catch{}return!1}()?[{target:be,ignoreProperties:["error"]}]:[];Eo(be,qd(be),ye&&ye.concat(ke),jd(be))}pe=pe.concat(["XMLHttpRequest","XMLHttpRequestEventTarget","IDBIndex","IDBRequest","IDBOpenDBRequest","IDBDatabase","IDBTransaction","IDBCursor","WebSocket"]);for(let be=0;be{!function Im(Z,se){const{isBrowser:ye,isMix:pe}=se.getGlobalObjects();(ye||pe)&&Z.customElements&&"customElements"in Z&&se.patchCallbacks(se,Z.customElements,"customElements","define",["connectedCallback","disconnectedCallback","adoptedCallback","attributeChangedCallback"])}(Z,ye)}),Zone.__load_patch("XHR",(Z,se)=>{!function At(Lt){const pt=Lt.XMLHttpRequest;if(!pt)return;const Di=pt.prototype;let mi=Di[Yl],dr=Di[_h];if(!mi){const et=Lt.XMLHttpRequestEventTarget;if(et){const yi=et.prototype;mi=yi[Yl],dr=yi[_h]}}const ki="readystatechange",is="scheduled";function Pr(et){const yi=et.data,Pt=yi.target;Pt[ke]=!1,Pt[it]=!1;const rs=Pt[be];mi||(mi=Pt[Yl],dr=Pt[_h]),rs&&dr.call(Pt,ki,rs);const _o=Pt[be]=()=>{if(Pt.readyState===Pt.DONE)if(!yi.aborted&&Pt[ke]&&et.state===is){const Ur=Pt[se.__symbol__("loadfalse")];if(0!==Pt.status&&Ur&&Ur.length>0){const Do=et.invoke;et.invoke=function(){const Ls=Pt[se.__symbol__("loadfalse")];for(let jr=0;jrfunction(et,yi){return et[pe]=0==yi[2],et[at]=yi[1],jn.apply(et,yi)}),Zr=Ji("fetchTaskAborting"),Pi=Ji("fetchTaskScheduling"),lt=tl(Di,"send",()=>function(et,yi){if(!0===se.current[Pi]||et[pe])return lt.apply(et,yi);{const Pt={target:et,url:et[at],isPeriodic:!1,args:yi,aborted:!1},rs=fm("XMLHttpRequest.send",Wt,Pt,Pr,ct);et&&!0===et[it]&&!Pt.aborted&&rs.state===is&&rs.invoke()}}),ur=tl(Di,"abort",()=>function(et,yi){const Pt=function ni(et){return et[ye]}(et);if(Pt&&"string"==typeof Pt.type){if(null==Pt.cancelFn||Pt.data&&Pt.data.aborted)return;Pt.zone.cancelTask(Pt)}else if(!0===se.current[Zr])return ur.apply(et,yi)})}(Z);const ye=Ji("xhrTask"),pe=Ji("xhrSync"),be=Ji("xhrListener"),ke=Ji("xhrScheduled"),at=Ji("xhrURL"),it=Ji("xhrErrorBeforeScheduled")}),Zone.__load_patch("geolocation",Z=>{Z.navigator&&Z.navigator.geolocation&&function gm(Z,se){const ye=Z.constructor.name;for(let pe=0;pe{const At=function(){return it.apply(this,Yd(arguments,ye+"."+be))};return Ia(At,it),At})(ke)}}}(Z.navigator.geolocation,["getCurrentPosition","watchPosition"])}),Zone.__load_patch("PromiseRejectionEvent",(Z,se)=>{function ye(pe){return function(be){bb(Z,pe).forEach(at=>{const it=Z.PromiseRejectionEvent;if(it){const At=new it(pe,{promise:be.promise,reason:be.rejection});at.invoke(At)}})}}Z.PromiseRejectionEvent&&(se[Ji("unhandledPromiseRejectionHandler")]=ye("unhandledrejection"),se[Ji("rejectionHandledHandler")]=ye("rejectionhandled"))}),Zone.__load_patch("queueMicrotask",(Z,se,ye)=>{!function up(Z,se){se.patchMethod(Z,"queueMicrotask",ye=>function(pe,be){Zone.current.scheduleMicroTask("queueMicrotask",be[0])})}(Z,ye)})}},Wl=>{Wl(Wl.s=51)}]); \ No newline at end of file diff --git a/ej2-angular/samples/diagram/nodes/node-expandAndCollapse-cs2/main.a5263187c36c3a78.js b/ej2-angular/samples/diagram/nodes/node-expandAndCollapse-cs2/main.a5263187c36c3a78.js deleted file mode 100644 index b07dea11b9..0000000000 --- a/ej2-angular/samples/diagram/nodes/node-expandAndCollapse-cs2/main.a5263187c36c3a78.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";(self.webpackChunksyncfusion_component=self.webpackChunksyncfusion_component||[]).push([[179],{51:(_l,_d,Ud)=>{let $r=null,Fh=1;const Ts=Symbol("SIGNAL");function Wi(n){const t=$r;return $r=n,t}function gn(n){if((!Vh(n)||n.dirty)&&(n.dirty||n.lastCleanEpoch!==Fh)){if(!n.producerMustRecompute(n)&&!jh(n))return n.dirty=!1,void(n.lastCleanEpoch=Fh);n.producerRecomputeValue(n),n.dirty=!1,n.lastCleanEpoch=Fh}}function jh(n){Vl(n);for(let t=0;t0}function Vl(n){n.producerNode??=[],n.producerIndexOfThis??=[],n.producerLastReadVersion??=[]}let Gd=null;function Eo(n){return"function"==typeof n}function Xd(n){const e=n(i=>{Error.call(i),i.stack=(new Error).stack});return e.prototype=Object.create(Error.prototype),e.prototype.constructor=e,e}const df=Xd(n=>function(e){n(this),this.message=e?`${e.length} errors occurred during unsubscription:\n${e.map((i,r)=>`${r+1}) ${i.toString()}`).join("\n ")}`:"",this.name="UnsubscriptionError",this.errors=e});function uf(n,t){if(n){const e=n.indexOf(t);0<=e&&n.splice(e,1)}}class As{constructor(t){this.initialTeardown=t,this.closed=!1,this._parentage=null,this._finalizers=null}unsubscribe(){let t;if(!this.closed){this.closed=!0;const{_parentage:e}=this;if(e)if(this._parentage=null,Array.isArray(e))for(const s of e)s.remove(this);else e.remove(this);const{initialTeardown:i}=this;if(Eo(i))try{i()}catch(s){t=s instanceof df?s.errors:[s]}const{_finalizers:r}=this;if(r){this._finalizers=null;for(const s of r)try{Im(s)}catch(o){t=t??[],o instanceof df?t=[...t,...o.errors]:t.push(o)}}if(t)throw new df(t)}}add(t){var e;if(t&&t!==this)if(this.closed)Im(t);else{if(t instanceof As){if(t.closed||t._hasParent(this))return;t._addParent(this)}(this._finalizers=null!==(e=this._finalizers)&&void 0!==e?e:[]).push(t)}}_hasParent(t){const{_parentage:e}=this;return e===t||Array.isArray(e)&&e.includes(t)}_addParent(t){const{_parentage:e}=this;this._parentage=Array.isArray(e)?(e.push(t),e):e?[e,t]:t}_removeParent(t){const{_parentage:e}=this;e===t?this._parentage=null:Array.isArray(e)&&uf(e,t)}remove(t){const{_finalizers:e}=this;e&&uf(e,t),t instanceof As&&t._removeParent(this)}}As.EMPTY=(()=>{const n=new As;return n.closed=!0,n})();const Wl=As.EMPTY;function Sm(n){return n instanceof As||n&&"closed"in n&&Eo(n.remove)&&Eo(n.add)&&Eo(n.unsubscribe)}function Im(n){Eo(n)?n():n.unsubscribe()}const Yl={onUnhandledError:null,onStoppedNotification:null,Promise:void 0,useDeprecatedSynchronousErrorHandling:!1,useDeprecatedNextContext:!1},Z={setTimeout(n,t,...e){const{delegate:i}=Z;return i?.setTimeout?i.setTimeout(n,t,...e):setTimeout(n,t,...e)},clearTimeout(n){const{delegate:t}=Z;return(t?.clearTimeout||clearTimeout)(n)},delegate:void 0};function ye(){}const fe=at("C",void 0,void 0);function at(n,t,e){return{kind:n,value:t,error:e}}let tt=null;function At(n){if(Yl.useDeprecatedSynchronousErrorHandling){const t=!tt;if(t&&(tt={errorThrown:!1,error:null}),n(),t){const{errorThrown:e,error:i}=tt;if(tt=null,e)throw i}}else n()}class ft extends As{constructor(t){super(),this.isStopped=!1,t?(this.destination=t,Sm(t)&&t.add(this)):this.destination=Wt}static create(t,e,i){return new dr(t,e,i)}next(t){this.isStopped?kr(function ke(n){return at("N",n,void 0)}(t),this):this._next(t)}error(t){this.isStopped?kr(function be(n){return at("E",void 0,n)}(t),this):(this.isStopped=!0,this._error(t))}complete(){this.isStopped?kr(fe,this):(this.isStopped=!0,this._complete())}unsubscribe(){this.closed||(this.isStopped=!0,super.unsubscribe(),this.destination=null)}_next(t){this.destination.next(t)}_error(t){try{this.destination.error(t)}finally{this.unsubscribe()}}_complete(){try{this.destination.complete()}finally{this.unsubscribe()}}}const Ei=Function.prototype.bind;function ti(n,t){return Ei.call(n,t)}class gi{constructor(t){this.partialObserver=t}next(t){const{partialObserver:e}=this;if(e.next)try{e.next(t)}catch(i){Oi(i)}}error(t){const{partialObserver:e}=this;if(e.error)try{e.error(t)}catch(i){Oi(i)}else Oi(t)}complete(){const{partialObserver:t}=this;if(t.complete)try{t.complete()}catch(e){Oi(e)}}}class dr extends ft{constructor(t,e,i){let r;if(super(),Eo(t)||!t)r={next:t??void 0,error:e??void 0,complete:i??void 0};else{let s;this&&Yl.useDeprecatedNextContext?(s=Object.create(t),s.unsubscribe=()=>this.unsubscribe(),r={next:t.next&&ti(t.next,s),error:t.error&&ti(t.error,s),complete:t.complete&&ti(t.complete,s)}):r=t}this.destination=new gi(r)}}function Oi(n){Yl.useDeprecatedSynchronousErrorHandling?function Lt(n){Yl.useDeprecatedSynchronousErrorHandling&&tt&&(tt.errorThrown=!0,tt.error=n)}(n):function se(n){Z.setTimeout(()=>{const{onUnhandledError:t}=Yl;if(!t)throw n;t(n)})}(n)}function kr(n,t){const{onStoppedNotification:e}=Yl;e&&Z.setTimeout(()=>e(n,t))}const Wt={closed:!0,next:ye,error:function es(n){throw n},complete:ye},ct="function"==typeof Symbol&&Symbol.observable||"@@observable";function _n(n){return n}let ki=(()=>{class n{constructor(e){e&&(this._subscribe=e)}lift(e){const i=new n;return i.source=this,i.operator=e,i}subscribe(e,i,r){const s=function et(n){return n&&n instanceof ft||function ur(n){return n&&Eo(n.next)&&Eo(n.error)&&Eo(n.complete)}(n)&&Sm(n)}(e)?e:new dr(e,i,r);return At(()=>{const{operator:o,source:a}=this;s.add(o?o.call(s,a):a?this._subscribe(s):this._trySubscribe(s))}),s}_trySubscribe(e){try{return this._subscribe(e)}catch(i){e.error(i)}}forEach(e,i){return new(i=lt(i))((r,s)=>{const o=new dr({next:a=>{try{e(a)}catch(l){s(l),o.unsubscribe()}},error:s,complete:r});this.subscribe(o)})}_subscribe(e){var i;return null===(i=this.source)||void 0===i?void 0:i.subscribe(e)}[ct](){return this}pipe(...e){return function Zr(n){return 0===n.length?_n:1===n.length?n[0]:function(e){return n.reduce((i,r)=>r(i),e)}}(e)(this)}toPromise(e){return new(e=lt(e))((i,r)=>{let s;this.subscribe(o=>s=o,o=>r(o),()=>i(s))})}}return n.create=t=>new n(t),n})();function lt(n){var t;return null!==(t=n??Yl.Promise)&&void 0!==t?t:Promise}const vi=Xd(n=>function(){n(this),this.name="ObjectUnsubscribedError",this.message="object unsubscribed"});let Pt=(()=>{class n extends ki{constructor(){super(),this.closed=!1,this.currentObservers=null,this.observers=[],this.isStopped=!1,this.hasError=!1,this.thrownError=null}lift(e){const i=new ts(this,this);return i.operator=e,i}_throwIfClosed(){if(this.closed)throw new vi}next(e){At(()=>{if(this._throwIfClosed(),!this.isStopped){this.currentObservers||(this.currentObservers=Array.from(this.observers));for(const i of this.currentObservers)i.next(e)}})}error(e){At(()=>{if(this._throwIfClosed(),!this.isStopped){this.hasError=this.isStopped=!0,this.thrownError=e;const{observers:i}=this;for(;i.length;)i.shift().error(e)}})}complete(){At(()=>{if(this._throwIfClosed(),!this.isStopped){this.isStopped=!0;const{observers:e}=this;for(;e.length;)e.shift().complete()}})}unsubscribe(){this.isStopped=this.closed=!0,this.observers=this.currentObservers=null}get observed(){var e;return(null===(e=this.observers)||void 0===e?void 0:e.length)>0}_trySubscribe(e){return this._throwIfClosed(),super._trySubscribe(e)}_subscribe(e){return this._throwIfClosed(),this._checkFinalizedStatuses(e),this._innerSubscribe(e)}_innerSubscribe(e){const{hasError:i,isStopped:r,observers:s}=this;return i||r?Wl:(this.currentObservers=null,s.push(e),new As(()=>{this.currentObservers=null,uf(s,e)}))}_checkFinalizedStatuses(e){const{hasError:i,thrownError:r,isStopped:s}=this;i?e.error(r):s&&e.complete()}asObservable(){const e=new ki;return e.source=this,e}}return n.create=(t,e)=>new ts(t,e),n})();class ts extends Pt{constructor(t,e){super(),this.destination=t,this.source=e}next(t){var e,i;null===(i=null===(e=this.destination)||void 0===e?void 0:e.next)||void 0===i||i.call(e,t)}error(t){var e,i;null===(i=null===(e=this.destination)||void 0===e?void 0:e.error)||void 0===i||i.call(e,t)}complete(){var t,e;null===(e=null===(t=this.destination)||void 0===t?void 0:t.complete)||void 0===e||e.call(t)}_subscribe(t){var e,i;return null!==(i=null===(e=this.source)||void 0===e?void 0:e.subscribe(t))&&void 0!==i?i:Wl}}class _o extends Pt{constructor(t){super(),this._value=t}get value(){return this.getValue()}_subscribe(t){const e=super._subscribe(t);return!e.closed&&t.next(this._value),e}getValue(){const{hasError:t,thrownError:e,_value:i}=this;if(t)throw e;return this._throwIfClosed(),i}next(t){super.next(this._value=t)}}class Ls extends ft{constructor(t,e,i,r,s,o){super(t),this.onFinalize=s,this.shouldUnsubscribe=o,this._next=e?function(a){try{e(a)}catch(l){t.error(l)}}:super._next,this._error=r?function(a){try{r(a)}catch(l){t.error(l)}finally{this.unsubscribe()}}:super._error,this._complete=i?function(){try{i()}catch(a){t.error(a)}finally{this.unsubscribe()}}:super._complete}unsubscribe(){var t;if(!this.shouldUnsubscribe||this.shouldUnsubscribe()){const{closed:e}=this;super.unsubscribe(),!e&&(null===(t=this.onFinalize)||void 0===t||t.call(this))}}}function jr(n,t){return function Ur(n){return t=>{if(function cn(n){return Eo(n?.lift)}(t))return t.lift(function(e){try{return n(e,this)}catch(i){this.error(i)}});throw new TypeError("Unable to lift unknown Observable type")}}((e,i)=>{let r=0;e.subscribe(function Do(n,t,e,i,r){return new Ls(n,t,e,i,r)}(i,s=>{i.next(n.call(t,s,r++))}))})}class F extends Error{constructor(t,e){super(function ae(n,t){return`NG0${Math.abs(n)}${t?": "+t:""}`}(t,e)),this.code=t}}function Xe(n){for(let t in n)if(n[t]===Xe)return t;throw Error("Could not find renamed property on target object.")}function mt(n,t){for(const e in t)t.hasOwnProperty(e)&&!n.hasOwnProperty(e)&&(n[e]=t[e])}function dt(n){if("string"==typeof n)return n;if(Array.isArray(n))return"["+n.map(dt).join(", ")+"]";if(null==n)return""+n;if(n.overriddenName)return`${n.overriddenName}`;if(n.name)return`${n.name}`;const t=n.toString();if(null==t)return""+t;const e=t.indexOf("\n");return-1===e?t:t.substring(0,e)}function qt(n,t){return null==n||""===n?null===t?"":t:null==t||""===t?n:n+" "+t}const pr=Xe({__forward_ref__:Xe});function ir(n){return n.__forward_ref__=ir,n.toString=function(){return dt(this())},n}function vt(n){return function Dn(n){return"function"==typeof n&&n.hasOwnProperty(pr)&&n.__forward_ref__===ir}(n)?n():n}function Ql(n){return n&&!!n.\u0275providers}const Gl=Xe({\u0275cmp:Xe}),qd=Xe({\u0275dir:Xe}),pf=Xe({\u0275pipe:Xe}),Uo=Xe({\u0275fac:Xe}),jo=Xe({__NG_ELEMENT_ID__:Xe}),ff=Xe({__NG_ENV_ID__:Xe});function zi(n){return"function"==typeof n?n.name||n.toString():"object"==typeof n&&null!=n&&"function"==typeof n.type?n.type.name||n.type.toString():function Nt(n){return"string"==typeof n?n:null==n?"":String(n)}(n)}function Cb(n,t){throw new F(-201,!1)}function ro(n,t){null==n&&function zt(n,t,e,i){throw new Error(`ASSERTION ERROR: ${n}`+(null==i?"":` [Expected=> ${e} ${i} ${t} <=Actual]`))}(t,n,null,"!=")}function Yi(n){return{token:n.token,providedIn:n.providedIn||null,factory:n.factory,value:void 0}}function gf(n){return{providers:n.providers||[],imports:n.imports||[]}}function bm(n){return kT(n,wm)||kT(n,PT)}function kT(n,t){return n.hasOwnProperty(t)?n[t]:null}function Mm(n){return n&&(n.hasOwnProperty(Eb)||n.hasOwnProperty(b_))?n[Eb]:null}const wm=Xe({\u0275prov:Xe}),Eb=Xe({\u0275inj:Xe}),PT=Xe({ngInjectableDef:Xe}),b_=Xe({ngInjectorDef:Xe});var Di=function(n){return n[n.Default=0]="Default",n[n.Host=1]="Host",n[n.Self=2]="Self",n[n.SkipSelf=4]="SkipSelf",n[n.Optional=8]="Optional",n}(Di||{});let Db;function no(n){const t=Db;return Db=n,t}function RT(n,t,e){const i=bm(n);return i&&"root"==i.providedIn?void 0===i.value?i.value=i.factory():i.value:e&Di.Optional?null:void 0!==t?t:void Cb()}const rr=globalThis;class Ht{constructor(t,e){this._desc=t,this.ngMetadataName="InjectionToken",this.\u0275prov=void 0,"number"==typeof e?this.__NG_ELEMENT_ID__=e:void 0!==e&&(this.\u0275prov=Yi({token:this,providedIn:e.providedIn||"root",factory:e.factory}))}get multi(){return this}toString(){return`InjectionToken ${this._desc}`}}const vf={},Nb="__NG_DI_FLAG__",Cm="ngTempTokenPath",C_=/\n/gm,BT="__source";let Zd;function Qh(n){const t=Zd;return Zd=n,t}function x_(n,t=Di.Default){if(void 0===Zd)throw new F(-203,!1);return null===Zd?RT(n,void 0,t):Zd.get(n,t&Di.Optional?null:void 0,t)}function Fi(n,t=Di.Default){return(function zT(){return Db}()||x_)(vt(n),t)}function Ri(n,t=Di.Default){return Fi(n,Em(t))}function Em(n){return typeof n>"u"||"number"==typeof n?n:0|(n.optional&&8)|(n.host&&1)|(n.self&&2)|(n.skipSelf&&4)}function Ob(n){const t=[];for(let e=0;et){o=s-1;break}}}for(;ss?"":r[d+1].toLowerCase();const p=8&i?u:null;if(p&&-1!==_T(p,h,0)||2&i&&h!==u){if(ba(i))return!1;o=!0}}}}else{if(!o&&!ba(i)&&!ba(l))return!1;if(o&&ba(l))continue;o=!1,i=l|1&i}}return ba(i)||o}function ba(n){return 0==(1&n)}function P_(n,t,e,i){if(null===t)return-1;let r=0;if(i||!e){let s=!1;for(;r-1)for(e++;e0?'="'+a+'"':"")+"]"}else 8&i?r+="."+o:4&i&&(r+=" "+o);else""!==r&&!ba(o)&&(t+=GT(s,r),r=""),i=o,s=s||!ba(i);e++}return""!==r&&(t+=GT(s,r)),t}function Pb(n){return Xl(()=>{const t=qT(n),e={...t,decls:n.decls,vars:n.vars,template:n.template,consts:n.consts||null,ngContentSelectors:n.ngContentSelectors,onPush:n.changeDetection===Dm.OnPush,directiveDefs:null,pipeDefs:null,dependencies:t.standalone&&n.dependencies||null,getStandaloneInjector:null,signals:n.signals??!1,data:n.data||{},encapsulation:n.encapsulation||Ia.Emulated,styles:n.styles||Qi,_:null,schemas:n.schemas||null,tView:null,id:""};$T(e);const i=n.dependencies;return e.directiveDefs=Tm(i,!1),e.pipeDefs=Tm(i,!0),e.id=function Y_(n){let t=0;const e=[n.selectors,n.ngContentSelectors,n.hostVars,n.hostAttrs,n.consts,n.vars,n.decls,n.encapsulation,n.standalone,n.signals,n.exportAs,JSON.stringify(n.inputs),JSON.stringify(n.outputs),Object.getOwnPropertyNames(n.type.prototype),!!n.contentQueries,!!n.viewQuery].join("|");for(const r of e)t=Math.imul(31,t)+r.charCodeAt(0)<<0;return t+=2147483648,"c"+t}(e),e})}function j_(n){return ci(n)||jn(n)}function V_(n){return null!==n}function xm(n){return Xl(()=>({type:n.type,bootstrap:n.bootstrap||Qi,declarations:n.declarations||Qi,imports:n.imports||Qi,exports:n.exports||Qi,transitiveCompileScopes:null,schemas:n.schemas||null,id:n.id||null}))}function XT(n,t){if(null==n)return tl;const e={};for(const i in n)if(n.hasOwnProperty(i)){const r=n[i];let s,o,a=Gh.None;Array.isArray(r)?(a=r[0],s=r[1],o=r[2]??s):(s=r,o=r),t?(e[s]=a!==Gh.None?[i,a]:i,t[s]=o):e[s]=i}return e}function nr(n){return Xl(()=>{const t=qT(n);return $T(t),t})}function ci(n){return n[Gl]||null}function jn(n){return n[qd]||null}function gs(n){return n[pf]||null}function qT(n){const t={};return{type:n.type,providersResolver:null,factory:null,hostBindings:n.hostBindings||null,hostVars:n.hostVars||0,hostAttrs:n.hostAttrs||null,contentQueries:n.contentQueries||null,declaredInputs:t,inputTransforms:null,inputConfig:n.inputs||tl,exportAs:n.exportAs||null,standalone:!0===n.standalone,signals:!0===n.signals,selectors:n.selectors||Qi,viewQuery:n.viewQuery||null,features:n.features||null,setInput:null,findHostDirectiveDefs:null,hostDirectives:null,inputs:XT(n.inputs,t),outputs:XT(n.outputs),debugInfo:null}}function $T(n){n.features?.forEach(t=>t(n))}function Tm(n,t){if(!n)return null;const e=t?gs:j_;return()=>("function"==typeof n?n():n).map(i=>e(i)).filter(V_)}const Vr=0,Be=1,Ct=2,vn=3,Ma=4,Os=5,wa=6,Jd=7,Er=8,Xs=9,ql=10,Yt=11,Sf=12,ZT=13,Kd=14,Jr=15,If=16,eu=17,il=18,bf=19,JT=20,Xh=21,Am=22,Uc=23,jt=25,zb=1,rl=7,tu=9,mn=10;var Rb=function(n){return n[n.None=0]="None",n[n.HasTransplantedViews=2]="HasTransplantedViews",n}(Rb||{});function ks(n){return Array.isArray(n)&&"object"==typeof n[zb]}function Ps(n){return Array.isArray(n)&&!0===n[zb]}function Hb(n){return 0!=(4&n.flags)}function jc(n){return n.componentOffset>-1}function Ca(n){return!!n.template}function Bb(n){return 0!=(512&n[Ct])}function Vc(n,t){return n.hasOwnProperty(Uo)?n[Uo]:null}class q_{constructor(t,e,i){this.previousValue=t,this.currentValue=e,this.firstChange=i}isFirstChange(){return this.firstChange}}function iA(n,t,e,i){null!==t?t.applyValueToInputSignal(t,i):n[e]=i}function rA(n){return n.type.prototype.ngOnChanges&&(n.setInput=Z_),$_}function $_(){const n=sA(this),t=n?.current;if(t){const e=n.previous;if(e===tl)n.previous=t;else for(let i in t)e[i]=t[i];n.current=null,this.ngOnChanges(t)}}function Z_(n,t,e,i,r){const s=this.declaredInputs[i],o=sA(n)||function J_(n,t){return n[nA]=t}(n,{previous:tl,current:null}),a=o.current||(o.current={}),l=o.previous,h=l[s];a[s]=new q_(h&&h.currentValue,e,l===tl),iA(n,t,r,e)}const nA="__ngSimpleChanges__";function sA(n){return n[nA]||null}const nl=function(n,t,e){};let lA=!1;function fr(n){for(;Array.isArray(n);)n=n[Vr];return n}function qs(n,t){return fr(t[n.index])}function Cf(n,t){return n.data[t]}function To(n,t){const e=t[n];return ks(e)?e:e[Vr]}function Vb(n){return 128==(128&n[Ct])}function sl(n,t){return null==t?null:n[t]}function hA(n){n[eu]=0}function nU(n){1024&n[Ct]||(n[Ct]|=1024,Vb(n)&&Ef(n))}function dA(n){return 9216&n[Ct]||n[Uc]?.dirty}function Wb(n){dA(n)?Ef(n):64&n[Ct]&&(function eU(){return lA}()?(n[Ct]|=1024,Ef(n)):n[ql].changeDetectionScheduler?.notify())}function Ef(n){n[ql].changeDetectionScheduler?.notify();let t=Wc(n);for(;null!==t&&!(8192&t[Ct])&&(t[Ct]|=8192,Vb(t));)t=Wc(t)}function Wc(n){const t=n[vn];return Ps(t)?t[vn]:t}const Rt={lFrame:bA(null),bindingsEnabled:!0,skipHydrationRootTNode:null};function pA(){return Rt.bindingsEnabled}function Se(){return Rt.lFrame.lView}function xi(){return Rt.lFrame.tView}function gr(){let n=fA();for(;null!==n&&64===n.type;)n=n.parent;return n}function fA(){return Rt.lFrame.currentTNode}function ol(n,t){const e=Rt.lFrame;e.currentTNode=n,e.isParent=t}function Qb(){return Rt.lFrame.isParent}function mU(n,t){const e=Rt.lFrame;e.bindingIndex=e.bindingRootIndex=n,Xb(t)}function Xb(n){Rt.lFrame.currentDirectiveIndex=n}function yA(){return Rt.lFrame.currentQueryIndex}function $b(n){Rt.lFrame.currentQueryIndex=n}function SU(n){const t=n[Be];return 2===t.type?t.declTNode:1===t.type?n[Os]:null}function SA(n,t,e){if(e&Di.SkipSelf){let r=t,s=n;for(;!(r=r.parent,null!==r||e&Di.Host||(r=SU(s),null===r||(s=s[Kd],10&r.type))););if(null===r)return!1;t=r,n=s}const i=Rt.lFrame=IA();return i.currentTNode=t,i.lView=n,!0}function Zb(n){const t=IA(),e=n[Be];Rt.lFrame=t,t.currentTNode=e.firstChild,t.lView=n,t.tView=e,t.contextLView=n,t.bindingIndex=e.bindingStartIndex,t.inI18n=!1}function IA(){const n=Rt.lFrame,t=null===n?null:n.child;return null===t?bA(n):t}function bA(n){const t={currentTNode:null,isParent:!0,lView:null,tView:null,selectedIndex:-1,contextLView:null,elementDepthCount:0,currentNamespace:null,currentDirectiveIndex:-1,bindingRootIndex:-1,bindingIndex:-1,currentQueryIndex:0,parent:n,child:null,inI18n:!1};return null!==n&&(n.child=t),t}function MA(){const n=Rt.lFrame;return Rt.lFrame=n.parent,n.currentTNode=null,n.lView=null,n}const wA=MA;function Jb(){const n=MA();n.isParent=!0,n.tView=null,n.selectedIndex=-1,n.contextLView=null,n.elementDepthCount=0,n.currentDirectiveIndex=-1,n.currentNamespace=null,n.bindingRootIndex=-1,n.bindingIndex=-1,n.currentQueryIndex=0}function Yc(n){Rt.lFrame.selectedIndex=n}let EA=!0;function zm(n,t){for(let e=t.directiveStart,i=t.directiveEnd;e=i)break}else t[l]<0&&(n[eu]+=65536),(a>14>16&&(3&n[Ct])===t&&(n[Ct]+=16384,xA(a,s)):xA(a,s)}const nu=-1;class xf{constructor(t,e,i){this.factory=t,this.resolving=!1,this.canSeeViewProviders=e,this.injectImpl=i}}function t1(n){return n!==nu}function Tf(n){return 32767&n}function Af(n,t){let e=function NU(n){return n>>16}(n),i=t;for(;e>0;)i=i[Kd],e--;return i}let i1=!0;function Bm(n){const t=i1;return i1=n,t}const TA=255,AA=5;let OU=0;const ll={};function Fm(n,t){const e=LA(n,t);if(-1!==e)return e;const i=t[Be];i.firstCreatePass&&(n.injectorIndex=t.length,r1(i.data,n),r1(t,null),r1(i.blueprint,null));const r=_m(n,t),s=n.injectorIndex;if(t1(r)){const o=Tf(r),a=Af(r,t),l=a[Be].data;for(let h=0;h<8;h++)t[s+h]=a[o+h]|l[o+h]}return t[s+8]=r,s}function r1(n,t){n.push(0,0,0,0,0,0,0,0,t)}function LA(n,t){return-1===n.injectorIndex||n.parent&&n.parent.injectorIndex===n.injectorIndex||null===t[n.injectorIndex+8]?-1:n.injectorIndex}function _m(n,t){if(n.parent&&-1!==n.parent.injectorIndex)return n.parent.injectorIndex;let e=0,i=null,r=t;for(;null!==r;){if(i=HA(r),null===i)return nu;if(e++,r=r[Kd],-1!==i.injectorIndex)return i.injectorIndex|e<<16}return nu}function n1(n,t,e){!function kU(n,t,e){let i;"string"==typeof e?i=e.charCodeAt(0)||0:e.hasOwnProperty(jo)&&(i=e[jo]),null==i&&(i=e[jo]=OU++);const r=i&TA;t.data[n+(r>>AA)]|=1<=0?t&TA:HU:t}(e);if("function"==typeof s){if(!SA(t,n,i))return i&Di.Host?NA(r,0,i):OA(t,e,i,r);try{let o;if(o=s(i),null!=o||i&Di.Optional)return o;Cb()}finally{wA()}}else if("number"==typeof s){let o=null,a=LA(n,t),l=nu,h=i&Di.Host?t[Jr][Os]:null;for((-1===a||i&Di.SkipSelf)&&(l=-1===a?_m(n,t):t[a+8],l!==nu&&RA(i,!1)?(o=t[Be],a=Tf(l),t=Af(l,t)):a=-1);-1!==a;){const c=t[Be];if(zA(s,a,c.data)){const d=zU(a,t,e,o,i,h);if(d!==ll)return d}l=t[a+8],l!==nu&&RA(i,t[Be].data[a+8]===h)&&zA(s,a,t)?(o=c,a=Tf(l),t=Af(l,t)):a=-1}}return r}function zU(n,t,e,i,r,s){const o=t[Be],a=o.data[n+8],c=Um(a,o,e,null==i?jc(a)&&i1:i!=o&&0!=(3&a.type),r&Di.Host&&s===a);return null!==c?Qc(t,o,c,a):ll}function Um(n,t,e,i,r){const s=n.providerIndexes,o=t.data,a=1048575&s,l=n.directiveStart,c=s>>20,u=r?a+c:n.directiveEnd;for(let p=i?a:a+c;p=l&&f.type===e)return p}if(r){const p=o[l];if(p&&Ca(p)&&p.type===e)return l}return null}function Qc(n,t,e,i){let r=n[e];const s=t.data;if(function xU(n){return n instanceof xf}(r)){const o=r;o.resolving&&function Vo(n,t){const e=t?`. Dependency path: ${t.join(" > ")} > ${n}`:"";throw new F(-200,`Circular dependency in DI detected for ${n}${e}`)}(zi(s[e]));const a=Bm(o.canSeeViewProviders);o.resolving=!0;const h=o.injectImpl?no(o.injectImpl):null;SA(n,i,Di.Default);try{r=n[e]=o.factory(void 0,s,n,i),t.firstCreatePass&&e>=i.directiveStart&&function EU(n,t,e){const{ngOnChanges:i,ngOnInit:r,ngDoCheck:s}=t.type.prototype;if(i){const o=rA(t);(e.preOrderHooks??=[]).push(n,o),(e.preOrderCheckHooks??=[]).push(n,o)}r&&(e.preOrderHooks??=[]).push(0-n,r),s&&((e.preOrderHooks??=[]).push(n,s),(e.preOrderCheckHooks??=[]).push(n,s))}(e,s[e],t)}finally{null!==h&&no(h),Bm(a),o.resolving=!1,wA()}}return r}function zA(n,t,e){return!!(e[t+(n>>AA)]&1<Array.isArray(e)?uu(e,t):t(e))}function FA(n,t,e){t>=n.length?n.push(e):n.splice(t,0,e)}function jm(n,t){return t>=n.length-1?n.pop():n.splice(t,1)[0]}const gu=new Ht(""),YA=new Ht("",-1),f1=new Ht("");class Qm{get(t,e=vf){if(e===vf){const i=new Error(`NullInjectorError: No provider for ${dt(t)}!`);throw i.name="NullInjectorError",i}return e}}function aj(...n){return{\u0275providers:QA(0,n),\u0275fromNgModule:!0}}function QA(n,...t){const e=[],i=new Set;let r;const s=o=>{e.push(o)};return uu(t,o=>{const a=o;Gm(a,s,[],i)&&(r||=[],r.push(a))}),void 0!==r&&GA(r,s),e}function GA(n,t){for(let e=0;e{t(s,i)})}}function Gm(n,t,e,i){if(!(n=vt(n)))return!1;let r=null,s=Mm(n);const o=!s&&ci(n);if(s||o){if(o&&!o.standalone)return!1;r=n}else{const l=n.ngModule;if(s=Mm(l),!s)return!1;r=l}const a=i.has(r);if(o){if(a)return!1;if(i.add(r),o.dependencies){const l="function"==typeof o.dependencies?o.dependencies():o.dependencies;for(const h of l)Gm(h,t,e,i)}}else{if(!s)return!1;{if(null!=s.imports&&!a){let h;i.add(r);try{uu(s.imports,c=>{Gm(c,t,e,i)&&(h||=[],h.push(c))})}finally{}void 0!==h&&GA(h,t)}if(!a){const h=Vc(r)||(()=>new r);t({provide:r,useFactory:h,deps:Qi},r),t({provide:f1,useValue:r,multi:!0},r),t({provide:gu,useValue:()=>Fi(r),multi:!0},r)}const l=s.providers;if(null!=l&&!a){const h=n;v1(l,c=>{t(c,h)})}}}return r!==n&&void 0!==n.providers}function v1(n,t){for(let e of n)Ql(e)&&(e=e.\u0275providers),Array.isArray(e)?v1(e,t):t(e)}const lj=Xe({provide:String,useValue:Xe});function m1(n){return null!==n&&"object"==typeof n&&lj in n}function Gc(n){return"function"==typeof n}const y1=new Ht(""),Xm={},cj={};let S1;function qm(){return void 0===S1&&(S1=new Qm),S1}class Jl{}class vu extends Jl{get destroyed(){return this._destroyed}constructor(t,e,i,r){super(),this.parent=e,this.source=i,this.scopes=r,this.records=new Map,this._ngOnDestroyHooks=new Set,this._onDestroyHooks=[],this._destroyed=!1,b1(t,o=>this.processProvider(o)),this.records.set(YA,mu(void 0,this)),r.has("environment")&&this.records.set(Jl,mu(void 0,this));const s=this.records.get(y1);null!=s&&"string"==typeof s.value&&this.scopes.add(s.value),this.injectorDefTypes=new Set(this.get(f1,Qi,Di.Self))}destroy(){this.assertNotDestroyed(),this._destroyed=!0;try{for(const e of this._ngOnDestroyHooks)e.ngOnDestroy();const t=this._onDestroyHooks;this._onDestroyHooks=[];for(const e of t)e()}finally{this.records.clear(),this._ngOnDestroyHooks.clear(),this.injectorDefTypes.clear()}}onDestroy(t){return this.assertNotDestroyed(),this._onDestroyHooks.push(t),()=>this.removeOnDestroy(t)}runInContext(t){this.assertNotDestroyed();const e=Qh(this),i=no(void 0);try{return t()}finally{Qh(e),no(i)}}get(t,e=vf,i=Di.Default){if(this.assertNotDestroyed(),t.hasOwnProperty(ff))return t[ff](this);i=Em(i);const s=Qh(this),o=no(void 0);try{if(!(i&Di.SkipSelf)){let l=this.records.get(t);if(void 0===l){const h=function gj(n){return"function"==typeof n||"object"==typeof n&&n instanceof Ht}(t)&&bm(t);l=h&&this.injectableDefInScope(h)?mu(I1(t),Xm):null,this.records.set(t,l)}if(null!=l)return this.hydrate(t,l)}return(i&Di.Self?qm():this.parent).get(t,e=i&Di.Optional&&e===vf?null:e)}catch(a){if("NullInjectorError"===a.name){if((a[Cm]=a[Cm]||[]).unshift(dt(t)),s)throw a;return function A_(n,t,e,i){const r=n[Cm];throw t[BT]&&r.unshift(t[BT]),n.message=function L_(n,t,e,i=null){n=n&&"\n"===n.charAt(0)&&"\u0275"==n.charAt(1)?n.slice(2):n;let r=dt(t);if(Array.isArray(t))r=t.map(dt).join(" -> ");else if("object"==typeof t){let s=[];for(let o in t)if(t.hasOwnProperty(o)){let a=t[o];s.push(o+":"+("string"==typeof a?JSON.stringify(a):dt(a)))}r=`{${s.join(", ")}}`}return`${e}${i?"("+i+")":""}[${r}]: ${n.replace(C_,"\n ")}`}("\n"+n.message,r,e,i),n.ngTokenPath=r,n[Cm]=null,n}(a,t,"R3InjectorError",this.source)}throw a}finally{no(o),Qh(s)}}resolveInjectorInitializers(){const t=Qh(this),e=no(void 0);try{const r=this.get(gu,Qi,Di.Self);for(const s of r)s()}finally{Qh(t),no(e)}}toString(){const t=[],e=this.records;for(const i of e.keys())t.push(dt(i));return`R3Injector[${t.join(", ")}]`}assertNotDestroyed(){if(this._destroyed)throw new F(205,!1)}processProvider(t){let e=Gc(t=vt(t))?t:vt(t&&t.provide);const i=function uj(n){return m1(n)?mu(void 0,n.useValue):mu($A(n),Xm)}(t);if(!Gc(t)&&!0===t.multi){let r=this.records.get(e);r||(r=mu(void 0,Xm,!0),r.factory=()=>Ob(r.multi),this.records.set(e,r)),e=t,r.multi.push(t)}this.records.set(e,i)}hydrate(t,e){return e.value===Xm&&(e.value=cj,e.value=e.factory()),"object"==typeof e.value&&e.value&&function fj(n){return null!==n&&"object"==typeof n&&"function"==typeof n.ngOnDestroy}(e.value)&&this._ngOnDestroyHooks.add(e.value),e.value}injectableDefInScope(t){if(!t.providedIn)return!1;const e=vt(t.providedIn);return"string"==typeof e?"any"===e||this.scopes.has(e):this.injectorDefTypes.has(e)}removeOnDestroy(t){const e=this._onDestroyHooks.indexOf(t);-1!==e&&this._onDestroyHooks.splice(e,1)}}function I1(n){const t=bm(n),e=null!==t?t.factory:Vc(n);if(null!==e)return e;if(n instanceof Ht)throw new F(204,!1);if(n instanceof Function)return function dj(n){if(n.length>0)throw new F(204,!1);const e=function I_(n){return n&&(n[wm]||n[PT])||null}(n);return null!==e?()=>e.factory(n):()=>new n}(n);throw new F(204,!1)}function $A(n,t,e){let i;if(Gc(n)){const r=vt(n);return Vc(r)||I1(r)}if(m1(n))i=()=>vt(n.useValue);else if(function qA(n){return!(!n||!n.useFactory)}(n))i=()=>n.useFactory(...Ob(n.deps||[]));else if(function XA(n){return!(!n||!n.useExisting)}(n))i=()=>Fi(vt(n.useExisting));else{const r=vt(n&&(n.useClass||n.provide));if(!function pj(n){return!!n.deps}(n))return Vc(r)||I1(r);i=()=>new r(...Ob(n.deps))}return i}function mu(n,t,e=!1){return{factory:n,value:t,multi:e?[]:void 0}}function b1(n,t){for(const e of n)Array.isArray(e)?b1(e,t):e&&Ql(e)?b1(e.\u0275providers,t):t(e)}function eL(n,t=null,e=null,i){const r=function tL(n,t=null,e=null,i,r=new Set){const s=[e||Qi,aj(n)];return i=i||("object"==typeof n?void 0:dt(n)),new vu(s,t||qm(),i||null,r)}(n,t,e,i);return r.resolveInjectorInitializers(),r}let C1,Wo=(()=>{class n{static{this.THROW_IF_NOT_FOUND=vf}static{this.NULL=new Qm}static create(e,i){if(Array.isArray(e))return eL({name:""},i,e,"");{const r=e.name??"";return eL({name:r},e.parent,e.providers,r)}}static{this.\u0275prov=Yi({token:n,providedIn:"any",factory:()=>Fi(YA)})}static{this.__NG_ELEMENT_ID__=-1}}return n})();const E1=new Ht("",{providedIn:"root",factory:()=>Cj}),Cj="ng",rL=new Ht(""),yu=new Ht("",{providedIn:"platform",factory:()=>"unknown"}),nL=new Ht("",{providedIn:"root",factory:()=>function $h(){if(void 0!==C1)return C1;if(typeof document<"u")return document;throw new F(210,!1)}().body?.querySelector("[ngCspNonce]")?.getAttribute("ngCspNonce")||null});function ey(n){return 128==(128&n.flags)}var Kh=function(n){return n[n.Important=1]="Important",n[n.DashCase=2]="DashCase",n}(Kh||{});const L1=new Map;let Hj=0;const O1="__ngContext__";function Rs(n,t){ks(t)?(n[O1]=t[bf],function Fj(n){L1.set(n[bf],n)}(t)):n[O1]=t}let k1;function P1(n,t){return k1(n,t)}function Iu(n,t,e,i,r){if(null!=i){let s,o=!1;Ps(i)?s=i:ks(i)&&(o=!0,i=i[Vr]);const a=fr(i);0===n&&null!==e?null==r?DL(t,e,a):qc(t,e,a,r||null,!0):1===n&&null!==e?qc(t,e,a,r||null,!0):2===n?function ay(n,t,e){const i=sy(n,t);i&&function t6(n,t,e,i){n.removeChild(t,e,i)}(n,i,t,e)}(t,a,o):3===n&&t.destroyNode(a),null!=s&&function n6(n,t,e,i,r){const s=e[rl];s!==fr(e)&&Iu(t,n,i,s,r);for(let a=mn;a0&&(n[e-1][Ma]=i[Ma]);const s=jm(n,mn+t);!function Xj(n,t){wL(n,t),t[Vr]=null,t[Os]=null}(i[Be],i);const o=s[il];null!==o&&o.detachView(s[Be]),i[vn]=null,i[Ma]=null,i[Ct]&=-129}return i}function ny(n,t){if(!(256&t[Ct])){const e=t[Yt];e.destroyNode&&ly(n,t,e,3,null,null),function $j(n){let t=n[Sf];if(!t)return R1(n[Be],n);for(;t;){let e=null;if(ks(t))e=t[Sf];else{const i=t[mn];i&&(e=i)}if(!e){for(;t&&!t[Ma]&&t!==n;)ks(t)&&R1(t[Be],t),t=t[vn];null===t&&(t=n),ks(t)&&R1(t[Be],t),e=t&&t[Ma]}t=e}}(t)}}function R1(n,t){if(!(256&t[Ct])){t[Ct]&=-129,t[Ct]|=256,t[Uc]&&function Yd(n){if(Vl(n),Vh(n))for(let t=0;t=0?i[o]():i[-o].unsubscribe(),s+=2}else e[s].call(i[e[s+1]]);null!==i&&(t[Jd]=null);const r=t[Xh];if(null!==r){t[Xh]=null;for(let s=0;s-1){const{encapsulation:s}=n.data[i.directiveStart+r];if(s===Ia.None||s===Ia.Emulated)return null}return qs(i,e)}}(n,t.parent,e)}function qc(n,t,e,i,r){n.insertBefore(t,e,i,r)}function DL(n,t,e){n.appendChild(t,e)}function xL(n,t,e,i,r){null!==i?qc(n,t,e,i,r):DL(n,t,e)}function sy(n,t){return n.parentNode(t)}let B1,LL=function AL(n,t,e){return 40&n.type?qs(n,e):null};function oy(n,t,e,i){const r=H1(n,i,t),s=t[Yt],a=function TL(n,t,e){return LL(n,t,e)}(i.parent||t[Os],i,t);if(null!=r)if(Array.isArray(e))for(let l=0;lnull;function eM(n,t,e=!1){return $L(n,t,e)}class U6{}class tN{}class V6{resolveComponentFactory(t){throw function j6(n){const t=Error(`No component factory found for ${dt(n)}.`);return t.ngComponent=n,t}(t)}}let my=(()=>{class n{static{this.NULL=new V6}}return n})();function W6(){return Du(gr(),Se())}function Du(n,t){return new $c(qs(n,t))}let $c=(()=>{class n{constructor(e){this.nativeElement=e}static{this.__NG_ELEMENT_ID__=W6}}return n})();function Y6(n){return n instanceof $c?n.nativeElement:n}class rN{}let nM=(()=>{class n{constructor(){this.destroyNode=null}static{this.__NG_ELEMENT_ID__=()=>function Q6(){const n=Se(),e=To(gr().index,n);return(ks(e)?e:n)[Yt]}()}}return n})(),G6=(()=>{class n{static{this.\u0275prov=Yi({token:n,providedIn:"root",factory:()=>null})}}return n})();const sM={};function Wf(n,t,e,i,r=!1){for(;null!==e;){const s=t[e.index];null!==s&&i.push(fr(s)),Ps(s)&&dN(s,i);const o=e.type;if(8&o)Wf(n,t,e.child,i);else if(32&o){const a=P1(e,t);let l;for(;l=a();)i.push(l)}else if(16&o){const a=OL(t,e);if(Array.isArray(a))i.push(...a);else{const l=Wc(t[Jr]);Wf(l[Be],l,a,i,!0)}}e=r?e.projectionNext:e.next}return i}function dN(n,t){for(let e=mn;e!1,producerRecomputeValue:()=>{},consumerMarkedDirty:()=>{},consumerOnSignalRead:()=>{},consumerIsAlwaysLive:!0,consumerMarkedDirty:n=>{Ef(n.lView)},consumerOnSignalRead(){this.lView[Uc]=this}};function pN(n){return gN(n[Sf])}function fN(n){return gN(n[Ma])}function gN(n){for(;null!==n&&!Ps(n);)n=n[Ma];return n}function lM(n){return n.ngOriginalError}class eh{constructor(){this._console=console}handleError(t){const e=this._findOriginalError(t);this._console.error("ERROR",t),e&&this._console.error("ORIGINAL ERROR",e)}_findOriginalError(t){let e=t&&lM(t);for(;e&&lM(e);)e=lM(e);return e||null}}const mN=new Ht("",{providedIn:"root",factory:()=>Ri(eh).handleError.bind(void 0)}),SN=new Ht("",{providedIn:"root",factory:()=>!1}),Qt={};function Ot(n,t=Di.Default){const e=Se();return null===e?Fi(n,t):kA(gr(),e,vt(n),t)}function CN(n,t,e,i,r,s){const o=Wi(null);try{let a=null;r&Gh.SignalBased&&(a=t[i][Ts]),null!==a&&void 0!==a.transformFn&&(s=a.transformFn(s)),r&Gh.HasDecoratorInputTransform&&(s=n.inputTransforms[i].call(t,s)),null!==n.setInput?n.setInput(t,a,s,e,i):iA(t,a,i,s)}finally{Wi(o)}}function by(n,t,e,i,r,s,o,a,l,h,c){const d=t.blueprint.slice();return d[Vr]=r,d[Ct]=204|i,(null!==h||n&&2048&n[Ct])&&(d[Ct]|=2048),hA(d),d[vn]=d[Kd]=n,d[Er]=e,d[ql]=o||n&&n[ql],d[Yt]=a||n&&n[Yt],d[Xs]=l||n&&n[Xs]||null,d[Os]=s,d[bf]=function Bj(){return Hj++}(),d[wa]=c,d[JT]=h,d[Jr]=2==t.type?n[Jr]:d,d}function xu(n,t,e,i,r){let s=n.data[t];if(null===s)s=function hM(n,t,e,i,r){const s=fA(),o=Qb(),l=n.data[t]=function EV(n,t,e,i,r,s){let o=t?t.injectorIndex:-1,a=0;return function ru(){return null!==Rt.skipHydrationRootTNode}()&&(a|=128),{type:e,index:i,insertBeforeIndex:null,injectorIndex:o,directiveStart:-1,directiveEnd:-1,directiveStylingLast:-1,componentOffset:-1,propertyBindings:null,flags:a,providerIndexes:0,value:r,attrs:s,mergedAttrs:null,localNames:null,initialInputs:void 0,inputs:null,outputs:null,tView:null,next:null,prev:null,projectionNext:null,child:null,parent:t,projection:null,styles:null,stylesWithoutHost:null,residualStyles:void 0,classes:null,classesWithoutHost:null,residualClasses:void 0,classBindings:0,styleBindings:0}}(0,o?s:s&&s.parent,e,t,i,r);return null===n.firstChild&&(n.firstChild=l),null!==s&&(o?null==s.child&&null!==l.parent&&(s.child=l):null===s.next&&(s.next=l,l.prev=s)),l}(n,t,e,i,r),function vU(){return Rt.lFrame.inI18n}()&&(s.flags|=32);else if(64&s.type){s.type=e,s.value=i,s.attrs=r;const o=function Df(){const n=Rt.lFrame,t=n.currentTNode;return n.isParent?t:t.parent}();s.injectorIndex=null===o?-1:o.injectorIndex}return ol(s,!0),s}function Yf(n,t,e,i){if(0===e)return-1;const r=t.length;for(let s=0;sjt&&function wN(n,t,e,i){if(!i)if(3==(3&t[Ct])){const s=n.preOrderCheckHooks;null!==s&&Rm(t,s,e)}else{const s=n.preOrderHooks;null!==s&&Hm(t,s,0,e)}Yc(e)}(n,t,jt,!1),nl(o?2:0,r),e(i,r)}finally{Yc(s),nl(o?3:1,r)}}function cM(n,t,e){if(Hb(t)){const i=Wi(null);try{const s=t.directiveEnd;for(let o=t.directiveStart;onull;function TN(n,t,e,i,r){for(let s in t){if(!t.hasOwnProperty(s))continue;const o=t[s];if(void 0===o)continue;i??={};let a,l=Gh.None;Array.isArray(o)?(a=o[0],l=o[1]):a=o;let h=s;if(null!==r){if(!r.hasOwnProperty(s))continue;h=r[s]}0===n?AN(i,e,h,a,l):AN(i,e,h,a)}return i}function AN(n,t,e,i,r){let s;n.hasOwnProperty(e)?(s=n[e]).push(t,i):s=n[e]=[t,i],void 0!==r&&s.push(r)}function LN(n,t,e,i,r,s){for(let h=0;h0;){const e=n[--t];if("number"==typeof e&&e<0)return e}return 0})(o)!=a&&o.push(a),o.push(e,i,s)}}(n,t,i,Yf(n,e,r.hostVars,Qt),r)}function _V(n,t,e,i,r,s){const o=s[t];if(null!==o)for(let a=0;an.nextProducerIndex;)n.producerNode.pop(),n.producerLastReadVersion.pop(),n.producerIndexOfThis.pop()}}(a,o),function aV(n){n.lView[Uc]!==n&&(n.lView=null,uN.push(n))}(a)),Jb()}}function HN(n,t){for(let e=pN(n);null!==e;e=fN(e))for(let i=mn;i-1&&(Rf(t,i),jm(e,i))}this._attachedToViewContainer=!1}ny(this._lView[Be],this._lView)}onDestroy(t){!function km(n,t){if(256==(256&n[Ct]))throw new F(911,!1);null===n[Xh]&&(n[Xh]=[]),n[Xh].push(t)}(this._lView,t)}markForCheck(){Qf(this._cdRefInjectingView||this._lView)}detach(){this._lView[Ct]&=-129}reattach(){Wb(this._lView),this._lView[Ct]|=128}detectChanges(){this._lView[Ct]|=1024,SM(this._lView,this.notifyErrorHandler)}checkNoChanges(){}attachToViewContainerRef(){if(this._appRef)throw new F(902,!1);this._attachedToViewContainer=!0}detachFromAppRef(){this._appRef=null,wL(this._lView[Be],this._lView)}attachToAppRef(t){if(this._attachedToViewContainer)throw new F(902,!1);this._appRef=t,Wb(this._lView)}}const UN=new Set;function MM(n){return t=>{setTimeout(n,void 0,t)}}const Yo=class n7 extends Pt{constructor(t=!1){super(),this.__isAsync=t}emit(t){super.next(t)}subscribe(t,e,i){let r=t,s=e||(()=>null),o=i;if(t&&"object"==typeof t){const l=t;r=l.next?.bind(l),s=l.error?.bind(l),o=l.complete?.bind(l)}this.__isAsync&&(s=MM(s),r&&(r=MM(r)),o&&(o=MM(o)));const a=super.subscribe({next:r,error:s,complete:o});return t instanceof As&&t.add(a),a}};function jN(...n){}class zr{constructor({enableLongStackTrace:t=!1,shouldCoalesceEventChangeDetection:e=!1,shouldCoalesceRunChangeDetection:i=!1}){if(this.hasPendingMacrotasks=!1,this.hasPendingMicrotasks=!1,this.isStable=!0,this.onUnstable=new Yo(!1),this.onMicrotaskEmpty=new Yo(!1),this.onStable=new Yo(!1),this.onError=new Yo(!1),typeof Zone>"u")throw new F(908,!1);Zone.assertZonePatched();const r=this;r._nesting=0,r._outer=r._inner=Zone.current,Zone.TaskTrackingZoneSpec&&(r._inner=r._inner.fork(new Zone.TaskTrackingZoneSpec)),t&&Zone.longStackTraceZoneSpec&&(r._inner=r._inner.fork(Zone.longStackTraceZoneSpec)),r.shouldCoalesceEventChangeDetection=!i&&e,r.shouldCoalesceRunChangeDetection=i,r.lastRequestAnimationFrameId=-1,r.nativeRequestAnimationFrame=function s7(){const n="function"==typeof rr.requestAnimationFrame;let t=rr[n?"requestAnimationFrame":"setTimeout"],e=rr[n?"cancelAnimationFrame":"clearTimeout"];if(typeof Zone<"u"&&t&&e){const i=t[Zone.__symbol__("OriginalDelegate")];i&&(t=i);const r=e[Zone.__symbol__("OriginalDelegate")];r&&(e=r)}return{nativeRequestAnimationFrame:t,nativeCancelAnimationFrame:e}}().nativeRequestAnimationFrame,function l7(n){const t=()=>{!function a7(n){n.isCheckStableRunning||-1!==n.lastRequestAnimationFrameId||(n.lastRequestAnimationFrameId=n.nativeRequestAnimationFrame.call(rr,()=>{n.fakeTopEventTask||(n.fakeTopEventTask=Zone.root.scheduleEventTask("fakeTopEventTask",()=>{n.lastRequestAnimationFrameId=-1,CM(n),n.isCheckStableRunning=!0,wM(n),n.isCheckStableRunning=!1},void 0,()=>{},()=>{})),n.fakeTopEventTask.invoke()}),CM(n))}(n)};n._inner=n._inner.fork({name:"angular",properties:{isAngularZone:!0},onInvokeTask:(e,i,r,s,o,a)=>{if(function h7(n){return!(!Array.isArray(n)||1!==n.length)&&!0===n[0].data?.__ignore_ng_zone__}(a))return e.invokeTask(r,s,o,a);try{return VN(n),e.invokeTask(r,s,o,a)}finally{(n.shouldCoalesceEventChangeDetection&&"eventTask"===s.type||n.shouldCoalesceRunChangeDetection)&&t(),WN(n)}},onInvoke:(e,i,r,s,o,a,l)=>{try{return VN(n),e.invoke(r,s,o,a,l)}finally{n.shouldCoalesceRunChangeDetection&&t(),WN(n)}},onHasTask:(e,i,r,s)=>{e.hasTask(r,s),i===r&&("microTask"==s.change?(n._hasPendingMicrotasks=s.microTask,CM(n),wM(n)):"macroTask"==s.change&&(n.hasPendingMacrotasks=s.macroTask))},onHandleError:(e,i,r,s)=>(e.handleError(r,s),n.runOutsideAngular(()=>n.onError.emit(s)),!1)})}(r)}static isInAngularZone(){return typeof Zone<"u"&&!0===Zone.current.get("isAngularZone")}static assertInAngularZone(){if(!zr.isInAngularZone())throw new F(909,!1)}static assertNotInAngularZone(){if(zr.isInAngularZone())throw new F(909,!1)}run(t,e,i){return this._inner.run(t,e,i)}runTask(t,e,i,r){const s=this._inner,o=s.scheduleEventTask("NgZoneEvent: "+r,t,o7,jN,jN);try{return s.runTask(o,e,i)}finally{s.cancelTask(o)}}runGuarded(t,e,i){return this._inner.runGuarded(t,e,i)}runOutsideAngular(t){return this._outer.run(t)}}const o7={};function wM(n){if(0==n._nesting&&!n.hasPendingMicrotasks&&!n.isStable)try{n._nesting++,n.onMicrotaskEmpty.emit(null)}finally{if(n._nesting--,!n.hasPendingMicrotasks)try{n.runOutsideAngular(()=>n.onStable.emit(null))}finally{n.isStable=!0}}}function CM(n){n.hasPendingMicrotasks=!!(n._hasPendingMicrotasks||(n.shouldCoalesceEventChangeDetection||n.shouldCoalesceRunChangeDetection)&&-1!==n.lastRequestAnimationFrameId)}function VN(n){n._nesting++,n.isStable&&(n.isStable=!1,n.onUnstable.emit(null))}function WN(n){n._nesting--,wM(n)}let Xf=(()=>{class n{constructor(){this.handler=null,this.internalCallbacks=[]}execute(){const e=[...this.internalCallbacks];this.internalCallbacks.length=0;for(const r of e)r();return!!this.handler?.execute()||e.length>0}ngOnDestroy(){this.handler?.destroy(),this.handler=null,this.internalCallbacks.length=0}static{this.\u0275prov=Yi({token:n,providedIn:"root",factory:()=>new n})}}return n})();function p7(n,t){const e=To(t,n),i=e[Be];!function f7(n,t){for(let e=t.length;e0&&zL(n,e,s.join(" "))}}(u,w,f,i),void 0!==e&&function C7(n,t,e){const i=n.projection=[];for(let r=0;r=0;i--){const r=n[i];r.hostVars=t+=r.hostVars,r.hostAttrs=yf(r.hostAttrs,e=yf(e,r.hostAttrs))}}(i)}function D7(n,t){for(const e in t.inputs){if(!t.inputs.hasOwnProperty(e)||n.inputs.hasOwnProperty(e))continue;const i=t.inputs[e];if(void 0!==i&&(n.inputs[e]=i,n.declaredInputs[e]=t.declaredInputs[e],null!==t.inputTransforms)){const r=Array.isArray(i)?i[0]:i;if(!t.inputTransforms.hasOwnProperty(r))continue;n.inputTransforms??={},n.inputTransforms[r]=t.inputTransforms[r]}}}function Ey(n){return n===tl?{}:n===Qi?[]:n}function T7(n,t){const e=n.viewQuery;n.viewQuery=e?(i,r)=>{t(i,r),e(i,r)}:t}function A7(n,t){const e=n.contentQueries;n.contentQueries=e?(i,r,s)=>{t(i,r,s),e(i,r,s)}:t}function L7(n,t){const e=n.hostBindings;n.hostBindings=e?(i,r)=>{t(i,r),e(i,r)}:t}function Au(n,t){return!t||null===t.firstChild||ey(n)}function tg(n,t,e,i=!0){const r=t[Be];if(function Zj(n,t,e,i){const r=mn+i,s=e.length;i>0&&(e[r-1][Ma]=t),i{class n{static{this.__NG_ELEMENT_ID__=n9}}return n})();function n9(){return dO(gr(),Se())}const s9=xn,hO=class extends s9{constructor(t,e,i){super(),this._lContainer=t,this._hostTNode=e,this._hostLView=i}get element(){return Du(this._hostTNode,this._hostLView)}get injector(){return new Vn(this._hostTNode,this._hostLView)}get parentInjector(){const t=_m(this._hostTNode,this._hostLView);if(t1(t)){const e=Af(t,this._hostLView),i=Tf(t);return new Vn(e[Be].data[i+8],e)}return new Vn(null,this._hostLView)}clear(){for(;this.length>0;)this.remove(this.length-1)}get(t){const e=cO(this._lContainer);return null!==e&&e[t]||null}get length(){return this._lContainer.length-mn}createEmbeddedView(t,e,i){let r,s;"number"==typeof i?r=i:null!=i&&(r=i.index,s=i.injector);const a=t.createEmbeddedViewImpl(e||{},s,null);return this.insertImpl(a,r,Au(this._hostTNode,null)),a}createComponent(t,e,i,r,s){const o=t&&!function Lf(n){return"function"==typeof n}(t);let a;if(o)a=e;else{const f=e||{};a=f.index,i=f.injector,r=f.projectableNodes,s=f.environmentInjector||f.ngModuleRef}const l=o?t:new qf(ci(t)),h=i||this.parentInjector;if(!s&&null==l.ngModule){const g=(o?h:this.parentInjector).get(Jl,null);g&&(s=g)}ci(l.componentType??{});const p=l.create(h,r,null,s);return this.insertImpl(p.hostView,a,Au(this._hostTNode,null)),p}insert(t,e){return this.insertImpl(t,e,!0)}insertImpl(t,e,i){const r=t._lView;if(function rU(n){return Ps(n[vn])}(r)){const a=this.indexOf(t);if(-1!==a)this.detach(a);else{const l=r[vn],h=new hO(l,l[Os],l[vn]);h.detach(h.indexOf(t))}}const s=this._adjustIndex(e),o=this._lContainer;return tg(o,r,s,i),t.attachToViewContainerRef(),FA(OM(o),s,t),t}move(t,e){return this.insert(t,e)}indexOf(t){const e=cO(this._lContainer);return null!==e?e.indexOf(t):-1}remove(t){const e=this._adjustIndex(t,-1),i=Rf(this._lContainer,e);i&&(jm(OM(this._lContainer),e),ny(i[Be],i))}detach(t){const e=this._adjustIndex(t,-1),i=Rf(this._lContainer,e);return i&&null!=jm(OM(this._lContainer),e)?new Gf(i):null}_adjustIndex(t,e=0){return t??this.length+e}};function cO(n){return n[8]}function OM(n){return n[8]||(n[8]=[])}function dO(n,t){let e;const i=t[n.index];return Ps(i)?e=i:(e=function ON(n,t,e,i){return[n,!0,0,t,null,i,null,e,null,null]}(i,t,null,n),t[n.index]=e,My(t,e)),uO(e,t,n,i),new hO(e,n,t)}let uO=function fO(n,t,e,i){if(n[rl])return;let r;r=8&e.type?fr(i):function o9(n,t){const e=n[Yt],i=e.createComment(""),r=qs(t,n);return qc(e,sy(e,r),i,function i6(n,t){return n.nextSibling(t)}(e,r),!1),i}(t,e),n[rl]=r};function YM(n,t,e){const i=Se();return function Tn(n,t,e){return!Object.is(n[t],e)&&(n[t]=e,!0)}(i,function al(){return Rt.lFrame.bindingIndex++}(),t)&&function No(n,t,e,i,r,s,o,a){const l=qs(t,e);let c,h=t.inputs;!a&&null!=h&&(c=h[i])?(yM(n,e,c,i,r),jc(t)&&function TV(n,t){const e=To(t,n);16&e[Ct]||(e[Ct]|=64)}(e,t.index)):3&t.type&&(i=function xV(n){return"class"===n?"className":"for"===n?"htmlFor":"formaction"===n?"formAction":"innerHtml"===n?"innerHTML":"readonly"===n?"readOnly":"tabindex"===n?"tabIndex":n}(i),r=null!=o?o(r,t.value||"",i):r,s.setProperty(l,i,r))}(xi(),function Pr(){const n=Rt.lFrame;return Cf(n.tView,n.selectedIndex)}(),i,n,t,i[Yt],e,!1),YM}function QM(n,t,e,i,r){const o=r?"class":"style";yM(n,e,t.inputs[o],o,i)}function JM(n,t,e,i){const r=Se(),s=xi(),o=jt+n,a=r[Yt],l=s.firstCreatePass?function k8(n,t,e,i,r,s){const o=t.consts,l=xu(t,n,2,i,sl(o,r));return function fM(n,t,e,i){if(pA()){const r=null===i?null:{"":-1},s=function PV(n,t){const e=n.directiveRegistry;let i=null,r=null;if(e)for(let s=0;s(function qh(n){EA=n}(!0),ry(i,r,function CA(){return Rt.lFrame.currentNamespace}()));const Gu="en-US";let Ik=Gu;function sw(n){return!!n&&"function"==typeof n.then}function Yk(n){return!!n&&"function"==typeof n.subscribe}function UW(){return this._results[Symbol.iterator]()}class aw{get changes(){return this._changes??=new Yo}constructor(t=!1){this._emitDistinctChangesOnly=t,this.dirty=!0,this._results=[],this._changesDetected=!1,this._changes=void 0,this.length=0,this.first=void 0,this.last=void 0;const e=aw.prototype;e[Symbol.iterator]||(e[Symbol.iterator]=UW)}get(t){return this._results[t]}map(t){return this._results.map(t)}filter(t){return this._results.filter(t)}find(t){return this._results.find(t)}reduce(t,e){return this._results.reduce(t,e)}forEach(t){this._results.forEach(t)}some(t){return this._results.some(t)}toArray(){return this._results.slice()}toString(){return this._results.toString()}reset(t,e){this.dirty=!1;const i=function oo(n){return n.flat(Number.POSITIVE_INFINITY)}(t);(this._changesDetected=!function WU(n,t,e){if(n.length!==t.length)return!1;for(let i=0;i{class n{static{this.__NG_ELEMENT_ID__=WW}}return n})();const jW=ih,VW=class extends jW{constructor(t,e,i){super(),this._declarationLView=t,this._declarationTContainer=e,this.elementRef=i}get ssrId(){return this._declarationTContainer.tView?.ssrId||null}createEmbeddedView(t,e){return this.createEmbeddedViewImpl(t,e)}createEmbeddedViewImpl(t,e,i){const r=function eg(n,t,e,i){const r=t.tView,a=by(n,r,e,4096&n[Ct]?4096:16,null,t,null,null,null,i?.injector??null,i?.dehydratedView??null);a[If]=n[t.index];const h=n[il];return null!==h&&(a[il]=h.createEmbeddedView(r)),EM(r,a,e),a}(this._declarationLView,this._declarationTContainer,t,{injector:e,dehydratedView:i});return new Gf(r)}};function WW(){return jy(gr(),Se())}function jy(n,t){return 4&n.type?new VW(t,n,Du(n,t)):null}class lw{constructor(t){this.queryList=t,this.matches=null}clone(){return new lw(this.queryList)}setDirty(){this.queryList.setDirty()}}class hw{constructor(t=[]){this.queries=t}createEmbeddedView(t){const e=t.queries;if(null!==e){const i=null!==t.contentQueries?t.contentQueries[0]:e.length,r=[];for(let s=0;s0)i.push(o[a/2]);else{const h=s[a+1],c=t[-l];for(let d=mn;d>20;if(Gc(n)||!n.multi){const p=new xf(h,r,Ot),f=vw(l,t,r?c:c+u,d);-1===f?(n1(Fm(a,o),s,l),gw(s,n,t.length),t.push(l),a.directiveStart++,a.directiveEnd++,r&&(a.providerIndexes+=1048576),e.push(p),o.push(p)):(e[f]=p,o[f]=p)}else{const p=vw(l,t,c+u,d),f=vw(l,t,c,c+u),v=f>=0&&e[f];if(r&&!v||!r&&!(p>=0&&e[p])){n1(Fm(a,o),s,l);const y=function fY(n,t,e,i,r){const s=new xf(n,e,Ot);return s.multi=[],s.index=t,s.componentProviders=0,NP(s,r,i&&!e),s}(r?pY:uY,e.length,r,i,h);!r&&v&&(e[f].providerFactory=y),gw(s,n,t.length,0),t.push(l),a.directiveStart++,a.directiveEnd++,r&&(a.providerIndexes+=1048576),e.push(y),o.push(y)}else gw(s,n,p>-1?p:f,NP(e[r?f:p],h,!r&&i));!r&&i&&v&&e[f].componentProviders++}}}function gw(n,t,e,i){const r=Gc(t),s=function hj(n){return!!n.useClass}(t);if(r||s){const l=(s?vt(t.useClass):t).prototype.ngOnDestroy;if(l){const h=n.destroyHooks||(n.destroyHooks=[]);if(!r&&t.multi){const c=h.indexOf(e);-1===c?h.push(e,[i,l]):h[c+1].push(i,l)}else h.push(e,l)}}}function NP(n,t,e){return e&&n.componentProviders++,n.multi.push(t)-1}function vw(n,t,e,i){for(let r=e;r{e.providersResolver=(i,r)=>function dY(n,t,e){const i=xi();if(i.firstCreatePass){const r=Ca(n);fw(e,i.data,i.blueprint,r,!0),fw(t,i.data,i.blueprint,r,!1)}}(i,r?r(n):n,t)}}class rd{}class kP extends rd{constructor(t){super(),this.componentFactoryResolver=new $N(this),this.instance=null;const e=new vu([...t.providers,{provide:rd,useValue:this},{provide:my,useValue:this.componentFactoryResolver}],t.parent||qm(),t.debugName,new Set(["environment"]));this.injector=e,t.runEnvironmentInitializers&&e.resolveInjectorInitializers()}destroy(){this.injector.destroy()}onDestroy(t){this.injector.onDestroy(t)}}let SY=(()=>{class n{constructor(e){this._injector=e,this.cachedInjectors=new Map}getOrCreateStandaloneInjector(e){if(!e.standalone)return null;if(!this.cachedInjectors.has(e)){const i=QA(0,e.type),r=i.length>0?function yY(n,t,e=null){return new kP({providers:n,parent:t,debugName:e,runEnvironmentInitializers:!0}).injector}([i],this._injector,`Standalone[${e.type.name}]`):null;this.cachedInjectors.set(e,r)}return this.cachedInjectors.get(e)}ngOnDestroy(){try{for(const e of this.cachedInjectors.values())null!==e&&e.destroy()}finally{this.cachedInjectors.clear()}}static{this.\u0275prov=Yi({token:n,providedIn:"environment",factory:()=>new n(Fi(Jl))})}}return n})();function PP(n){(function Zc(n){UN.has(n)||(UN.add(n),performance?.mark?.("mark_feature_usage",{detail:{feature:n}}))})("NgStandalone"),n.getStandaloneInjector=t=>t.get(SY).getOrCreateStandaloneInjector(n)}let Dw=(()=>{class n{constructor(){this.taskId=0,this.pendingTasks=new Set,this.hasPendingTasks=new _o(!1)}get _hasPendingTasks(){return this.hasPendingTasks.value}add(){this._hasPendingTasks||this.hasPendingTasks.next(!0);const e=this.taskId++;return this.pendingTasks.add(e),e}remove(e){this.pendingTasks.delete(e),0===this.pendingTasks.size&&this._hasPendingTasks&&this.hasPendingTasks.next(!1)}ngOnDestroy(){this.pendingTasks.clear(),this._hasPendingTasks&&this.hasPendingTasks.next(!1)}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();const p2=new Ht(""),WQ=new Ht("");let Nw=(()=>{class n{constructor(){this.initialized=!1,this.done=!1,this.donePromise=new Promise((e,i)=>{this.resolve=e,this.reject=i}),this.appInits=Ri(WQ,{optional:!0})??[]}runInitializers(){if(this.initialized)return;const e=[];for(const r of this.appInits){const s=r();if(sw(s))e.push(s);else if(Yk(s)){const o=new Promise((a,l)=>{s.subscribe({complete:a,error:l})});e.push(o)}}const i=()=>{this.done=!0,this.resolve()};Promise.all(e).then(()=>{i()}).catch(r=>{this.reject(r)}),0===e.length&&i(),this.initialized=!0}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();const f2=new Ht("");let $u=(()=>{class n{constructor(){this._bootstrapListeners=[],this._runningTick=!1,this._destroyed=!1,this._destroyListeners=[],this._views=[],this.internalErrorHandler=Ri(mN),this.afterRenderEffectManager=Ri(Xf),this.componentTypes=[],this.components=[],this.isStable=Ri(Dw).hasPendingTasks.pipe(jr(e=>!e)),this._injector=Ri(Jl)}get destroyed(){return this._destroyed}get injector(){return this._injector}bootstrap(e,i){const r=e instanceof tN;if(!this._injector.get(Nw).done)throw!r&&function _c(n){const t=ci(n)||jn(n)||gs(n);return null!==t&&t.standalone}(e),new F(405,!1);let o;o=r?e:this._injector.get(my).resolveComponentFactory(e),this.componentTypes.push(o.componentType);const a=function QQ(n){return n.isBoundToModule}(o)?void 0:this._injector.get(rd),h=o.create(Wo.NULL,[],i||o.selector,a),c=h.location.nativeElement,d=h.injector.get(p2,null);return d?.registerApplication(c),h.onDestroy(()=>{this.detachView(h.hostView),Xy(this.components,h),d?.unregisterApplication(c)}),this._loadComponent(h),h}tick(){if(this._runningTick)throw new F(101,!1);try{this._runningTick=!0;for(let e of this._views)e.detectChanges()}catch(e){this.internalErrorHandler(e)}finally{try{this.afterRenderEffectManager.execute()}catch(e){this.internalErrorHandler(e)}this._runningTick=!1}}attachView(e){const i=e;this._views.push(i),i.attachToAppRef(this)}detachView(e){const i=e;Xy(this._views,i),i.detachFromAppRef()}_loadComponent(e){this.attachView(e.hostView),this.tick(),this.components.push(e);const i=this._injector.get(f2,[]);[...this._bootstrapListeners,...i].forEach(r=>r(e))}ngOnDestroy(){if(!this._destroyed)try{this._destroyListeners.forEach(e=>e()),this._views.slice().forEach(e=>e.destroy())}finally{this._destroyed=!0,this._views=[],this._bootstrapListeners=[],this._destroyListeners=[]}}onDestroy(e){return this._destroyListeners.push(e),()=>Xy(this._destroyListeners,e)}destroy(){if(this._destroyed)throw new F(406,!1);const e=this._injector;e.destroy&&!e.destroyed&&e.destroy()}get viewCount(){return this._views.length}warnIfDestroyed(){}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();function Xy(n,t){const e=n.indexOf(t);e>-1&&n.splice(e,1)}let XQ=(()=>{class n{constructor(){this.zone=Ri(zr),this.applicationRef=Ri($u)}initialize(){this._onMicrotaskEmptySubscription||(this._onMicrotaskEmptySubscription=this.zone.onMicrotaskEmpty.subscribe({next:()=>{this.zone.run(()=>{this.applicationRef.tick()})}}))}ngOnDestroy(){this._onMicrotaskEmptySubscription?.unsubscribe()}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();function S2(n){return[{provide:zr,useFactory:n},{provide:gu,multi:!0,useFactory:()=>{const t=Ri(XQ,{optional:!0});return()=>t.initialize()}},{provide:gu,multi:!0,useFactory:()=>{const t=Ri(ZQ);return()=>{t.initialize()}}},{provide:mN,useFactory:qQ}]}function qQ(){const n=Ri(zr),t=Ri(eh);return e=>n.runOutsideAngular(()=>t.handleError(e))}function $Q(n){return function g1(n){return{\u0275providers:n}}([[],S2(()=>new zr(function I2(n){return{enableLongStackTrace:!1,shouldCoalesceEventChangeDetection:n?.eventCoalescing??!1,shouldCoalesceRunChangeDetection:n?.runCoalescing??!1}}(n)))])}let ZQ=(()=>{class n{constructor(){this.subscription=new As,this.initialized=!1,this.zone=Ri(zr),this.pendingTasks=Ri(Dw)}initialize(){if(this.initialized)return;this.initialized=!0;let e=null;!this.zone.isStable&&!this.zone.hasPendingMacrotasks&&!this.zone.hasPendingMicrotasks&&(e=this.pendingTasks.add()),this.zone.runOutsideAngular(()=>{this.subscription.add(this.zone.onStable.subscribe(()=>{zr.assertNotInAngularZone(),queueMicrotask(()=>{null!==e&&!this.zone.hasPendingMacrotasks&&!this.zone.hasPendingMicrotasks&&(this.pendingTasks.remove(e),e=null)})}))}),this.subscription.add(this.zone.onUnstable.subscribe(()=>{zr.assertInAngularZone(),e??=this.pendingTasks.add()}))}ngOnDestroy(){this.subscription.unsubscribe()}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();const rh=new Ht("",{providedIn:"root",factory:()=>Ri(rh,Di.Optional|Di.SkipSelf)||function JQ(){return typeof $localize<"u"&&$localize.locale||Gu}()}),Ow=new Ht("");let rc=null;function MG(n){try{const{rootComponent:t,appProviders:e,platformProviders:i}=n,r=function rG(n=[]){if(rc)return rc;const t=function w2(n=[],t){return Wo.create({name:t,providers:[{provide:y1,useValue:"platform"},{provide:Ow,useValue:new Set([()=>rc=null])},...n]})}(n);return rc=t,function g2(){!function vb(n){Gd=n}(()=>{throw new F(600,!1)})}(),function C2(n){n.get(rL,null)?.forEach(e=>e())}(t),t}(i),s=[$Q(),...e||[]],a=new kP({providers:s,parent:r,debugName:"",runEnvironmentInitializers:!1}).injector,l=a.get(zr);return l.run(()=>{a.resolveInjectorInitializers();const h=a.get(eh,null);let c;l.runOutsideAngular(()=>{c=l.onError.subscribe({next:p=>{h.handleError(p)}})});const d=()=>a.destroy(),u=r.get(Ow);return u.add(d),a.onDestroy(()=>{c.unsubscribe(),u.delete(d)}),function v2(n,t,e){try{const i=e();return sw(i)?i.catch(r=>{throw t.runOutsideAngular(()=>n.handleError(r)),r}):i}catch(i){throw t.runOutsideAngular(()=>n.handleError(i)),i}}(h,l,()=>{const p=a.get(Nw);return p.runInitializers(),p.donePromise.then(()=>{!function bk(n){ro(n,"Expected localeId to be defined"),"string"==typeof n&&(Ik=n.toLowerCase().replace(/_/g,"-"))}(a.get(rh,Gu)||Gu);const g=a.get($u);return void 0!==t&&g.bootstrap(t),g})})})}catch(t){return Promise.reject(t)}}let X2=null;function _w(){return X2}class HG{}const sd=new Ht("");let tq=(()=>{class n{static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275mod=xm({type:n})}static{this.\u0275inj=gf({})}}return n})();function cz(n){return"server"===n}class Aq extends HG{constructor(){super(...arguments),this.supportsDOMEvents=!0}}class rC extends Aq{static makeCurrent(){!function RG(n){X2??=n}(new rC)}onAndCancel(t,e,i){return t.addEventListener(e,i),()=>{t.removeEventListener(e,i)}}dispatchEvent(t,e){t.dispatchEvent(e)}remove(t){t.parentNode&&t.parentNode.removeChild(t)}createElement(t,e){return(e=e||this.getDefaultDocument()).createElement(t)}createHtmlDocument(){return document.implementation.createHTMLDocument("fakeTitle")}getDefaultDocument(){return document}isElementNode(t){return t.nodeType===Node.ELEMENT_NODE}isShadowRoot(t){return t instanceof DocumentFragment}getGlobalEventTarget(t,e){return"window"===e?window:"document"===e?t:"body"===e?t.body:null}getBaseHref(t){const e=function Lq(){return bg=bg||document.querySelector("base"),bg?bg.getAttribute("href"):null}();return null==e?null:function Nq(n){return new URL(n,document.baseURI).pathname}(e)}resetBaseElement(){bg=null}getUserAgent(){return window.navigator.userAgent}getCookie(t){return function wX(n,t){t=encodeURIComponent(t);for(const e of n.split(";")){const i=e.indexOf("="),[r,s]=-1==i?[e,""]:[e.slice(0,i),e.slice(i+1)];if(r.trim()===t)return decodeURIComponent(s)}return null}(document.cookie,t)}}let bg=null,kq=(()=>{class n{build(){return new XMLHttpRequest}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();const nC=new Ht("");let fz=(()=>{class n{constructor(e,i){this._zone=i,this._eventNameToPlugin=new Map,e.forEach(r=>{r.manager=this}),this._plugins=e.slice().reverse()}addEventListener(e,i,r){return this._findPluginFor(i).addEventListener(e,i,r)}getZone(){return this._zone}_findPluginFor(e){let i=this._eventNameToPlugin.get(e);if(i)return i;if(i=this._plugins.find(s=>s.supports(e)),!i)throw new F(5101,!1);return this._eventNameToPlugin.set(e,i),i}static{this.\u0275fac=function(i){return new(i||n)(Fi(nC),Fi(zr))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();class gz{constructor(t){this._doc=t}}const sC="ng-app-id";let vz=(()=>{class n{constructor(e,i,r,s={}){this.doc=e,this.appId=i,this.nonce=r,this.platformId=s,this.styleRef=new Map,this.hostNodes=new Set,this.styleNodesInDOM=this.collectServerRenderedStyles(),this.platformIsServer=cz(s),this.resetHostNodes()}addStyles(e){for(const i of e)1===this.changeUsageCount(i,1)&&this.onStyleAdded(i)}removeStyles(e){for(const i of e)this.changeUsageCount(i,-1)<=0&&this.onStyleRemoved(i)}ngOnDestroy(){const e=this.styleNodesInDOM;e&&(e.forEach(i=>i.remove()),e.clear());for(const i of this.getAllStyles())this.onStyleRemoved(i);this.resetHostNodes()}addHost(e){this.hostNodes.add(e);for(const i of this.getAllStyles())this.addStyleToHost(e,i)}removeHost(e){this.hostNodes.delete(e)}getAllStyles(){return this.styleRef.keys()}onStyleAdded(e){for(const i of this.hostNodes)this.addStyleToHost(i,e)}onStyleRemoved(e){const i=this.styleRef;i.get(e)?.elements?.forEach(r=>r.remove()),i.delete(e)}collectServerRenderedStyles(){const e=this.doc.head?.querySelectorAll(`style[${sC}="${this.appId}"]`);if(e?.length){const i=new Map;return e.forEach(r=>{null!=r.textContent&&i.set(r.textContent,r)}),i}return null}changeUsageCount(e,i){const r=this.styleRef;if(r.has(e)){const s=r.get(e);return s.usage+=i,s.usage}return r.set(e,{usage:i,elements:[]}),i}getStyleElement(e,i){const r=this.styleNodesInDOM,s=r?.get(i);if(s?.parentNode===e)return r.delete(i),s.removeAttribute(sC),s;{const o=this.doc.createElement("style");return this.nonce&&o.setAttribute("nonce",this.nonce),o.textContent=i,this.platformIsServer&&o.setAttribute(sC,this.appId),e.appendChild(o),o}}addStyleToHost(e,i){const r=this.getStyleElement(e,i),s=this.styleRef,o=s.get(i)?.elements;o?o.push(r):s.set(i,{elements:[r],usage:1})}resetHostNodes(){const e=this.hostNodes;e.clear(),e.add(this.doc.head)}static{this.\u0275fac=function(i){return new(i||n)(Fi(sd),Fi(E1),Fi(nL,8),Fi(yu))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();const oC={svg:"http://www.w3.org/2000/svg",xhtml:"http://www.w3.org/1999/xhtml",xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/",math:"http://www.w3.org/1998/MathML/"},aC=/%COMP%/g,Hq=new Ht("",{providedIn:"root",factory:()=>!0});function yz(n,t){return t.map(e=>e.replace(aC,n))}let Sz=(()=>{class n{constructor(e,i,r,s,o,a,l,h=null){this.eventManager=e,this.sharedStylesHost=i,this.appId=r,this.removeStylesOnCompDestroy=s,this.doc=o,this.platformId=a,this.ngZone=l,this.nonce=h,this.rendererByCompId=new Map,this.platformIsServer=cz(a),this.defaultRenderer=new lC(e,o,l,this.platformIsServer)}createRenderer(e,i){if(!e||!i)return this.defaultRenderer;this.platformIsServer&&i.encapsulation===Ia.ShadowDom&&(i={...i,encapsulation:Ia.Emulated});const r=this.getOrCreateRenderer(e,i);return r instanceof bz?r.applyToHost(e):r instanceof hC&&r.applyStyles(),r}getOrCreateRenderer(e,i){const r=this.rendererByCompId;let s=r.get(i.id);if(!s){const o=this.doc,a=this.ngZone,l=this.eventManager,h=this.sharedStylesHost,c=this.removeStylesOnCompDestroy,d=this.platformIsServer;switch(i.encapsulation){case Ia.Emulated:s=new bz(l,h,i,this.appId,c,o,a,d);break;case Ia.ShadowDom:return new Uq(l,h,e,i,o,a,this.nonce,d);default:s=new hC(l,h,i,c,o,a,d)}r.set(i.id,s)}return s}ngOnDestroy(){this.rendererByCompId.clear()}static{this.\u0275fac=function(i){return new(i||n)(Fi(fz),Fi(vz),Fi(E1),Fi(Hq),Fi(sd),Fi(yu),Fi(zr),Fi(nL))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();class lC{constructor(t,e,i,r){this.eventManager=t,this.doc=e,this.ngZone=i,this.platformIsServer=r,this.data=Object.create(null),this.throwOnSyntheticProps=!0,this.destroyNode=null}destroy(){}createElement(t,e){return e?this.doc.createElementNS(oC[e]||e,t):this.doc.createElement(t)}createComment(t){return this.doc.createComment(t)}createText(t){return this.doc.createTextNode(t)}appendChild(t,e){(Iz(t)?t.content:t).appendChild(e)}insertBefore(t,e,i){t&&(Iz(t)?t.content:t).insertBefore(e,i)}removeChild(t,e){t&&t.removeChild(e)}selectRootElement(t,e){let i="string"==typeof t?this.doc.querySelector(t):t;if(!i)throw new F(-5104,!1);return e||(i.textContent=""),i}parentNode(t){return t.parentNode}nextSibling(t){return t.nextSibling}setAttribute(t,e,i,r){if(r){e=r+":"+e;const s=oC[r];s?t.setAttributeNS(s,e,i):t.setAttribute(e,i)}else t.setAttribute(e,i)}removeAttribute(t,e,i){if(i){const r=oC[i];r?t.removeAttributeNS(r,e):t.removeAttribute(`${i}:${e}`)}else t.removeAttribute(e)}addClass(t,e){t.classList.add(e)}removeClass(t,e){t.classList.remove(e)}setStyle(t,e,i,r){r&(Kh.DashCase|Kh.Important)?t.style.setProperty(e,i,r&Kh.Important?"important":""):t.style[e]=i}removeStyle(t,e,i){i&Kh.DashCase?t.style.removeProperty(e):t.style[e]=""}setProperty(t,e,i){null!=t&&(t[e]=i)}setValue(t,e){t.nodeValue=e}listen(t,e,i){if("string"==typeof t&&!(t=_w().getGlobalEventTarget(this.doc,t)))throw new Error(`Unsupported event target ${t} for event ${e}`);return this.eventManager.addEventListener(t,e,this.decoratePreventDefault(i))}decoratePreventDefault(t){return e=>{if("__ngUnwrap__"===e)return t;!1===(this.platformIsServer?this.ngZone.runGuarded(()=>t(e)):t(e))&&e.preventDefault()}}}function Iz(n){return"TEMPLATE"===n.tagName&&void 0!==n.content}class Uq extends lC{constructor(t,e,i,r,s,o,a,l){super(t,s,o,l),this.sharedStylesHost=e,this.hostEl=i,this.shadowRoot=i.attachShadow({mode:"open"}),this.sharedStylesHost.addHost(this.shadowRoot);const h=yz(r.id,r.styles);for(const c of h){const d=document.createElement("style");a&&d.setAttribute("nonce",a),d.textContent=c,this.shadowRoot.appendChild(d)}}nodeOrShadowRoot(t){return t===this.hostEl?this.shadowRoot:t}appendChild(t,e){return super.appendChild(this.nodeOrShadowRoot(t),e)}insertBefore(t,e,i){return super.insertBefore(this.nodeOrShadowRoot(t),e,i)}removeChild(t,e){return super.removeChild(this.nodeOrShadowRoot(t),e)}parentNode(t){return this.nodeOrShadowRoot(super.parentNode(this.nodeOrShadowRoot(t)))}destroy(){this.sharedStylesHost.removeHost(this.shadowRoot)}}class hC extends lC{constructor(t,e,i,r,s,o,a,l){super(t,s,o,a),this.sharedStylesHost=e,this.removeStylesOnCompDestroy=r,this.styles=l?yz(l,i.styles):i.styles}applyStyles(){this.sharedStylesHost.addStyles(this.styles)}destroy(){this.removeStylesOnCompDestroy&&this.sharedStylesHost.removeStyles(this.styles)}}class bz extends hC{constructor(t,e,i,r,s,o,a,l){const h=r+"-"+i.id;super(t,e,i,s,o,a,l,h),this.contentAttr=function Bq(n){return"_ngcontent-%COMP%".replace(aC,n)}(h),this.hostAttr=function Fq(n){return"_nghost-%COMP%".replace(aC,n)}(h)}applyToHost(t){this.applyStyles(),this.setAttribute(t,this.hostAttr,"")}createElement(t,e){const i=super.createElement(t,e);return super.setAttribute(i,this.contentAttr,""),i}}let jq=(()=>{class n extends gz{constructor(e){super(e)}supports(e){return!0}addEventListener(e,i,r){return e.addEventListener(i,r,!1),()=>this.removeEventListener(e,i,r)}removeEventListener(e,i,r){return e.removeEventListener(i,r)}static{this.\u0275fac=function(i){return new(i||n)(Fi(sd))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();const Mz=["alt","control","meta","shift"],Vq={"\b":"Backspace","\t":"Tab","\x7f":"Delete","\x1b":"Escape",Del:"Delete",Esc:"Escape",Left:"ArrowLeft",Right:"ArrowRight",Up:"ArrowUp",Down:"ArrowDown",Menu:"ContextMenu",Scroll:"ScrollLock",Win:"OS"},Wq={alt:n=>n.altKey,control:n=>n.ctrlKey,meta:n=>n.metaKey,shift:n=>n.shiftKey};let Yq=(()=>{class n extends gz{constructor(e){super(e)}supports(e){return null!=n.parseEventName(e)}addEventListener(e,i,r){const s=n.parseEventName(i),o=n.eventCallback(s.fullKey,r,this.manager.getZone());return this.manager.getZone().runOutsideAngular(()=>_w().onAndCancel(e,s.domEventName,o))}static parseEventName(e){const i=e.toLowerCase().split("."),r=i.shift();if(0===i.length||"keydown"!==r&&"keyup"!==r)return null;const s=n._normalizeKey(i.pop());let o="",a=i.indexOf("code");if(a>-1&&(i.splice(a,1),o="code."),Mz.forEach(h=>{const c=i.indexOf(h);c>-1&&(i.splice(c,1),o+=h+".")}),o+=s,0!=i.length||0===s.length)return null;const l={};return l.domEventName=r,l.fullKey=o,l}static matchEventFullKeyCode(e,i){let r=Vq[e.key]||e.key,s="";return i.indexOf("code.")>-1&&(r=e.code,s="code."),!(null==r||!r)&&(r=r.toLowerCase()," "===r?r="space":"."===r&&(r="dot"),Mz.forEach(o=>{o!==r&&(0,Wq[o])(e)&&(s+=o+".")}),s+=r,s===i)}static eventCallback(e,i,r){return s=>{n.matchEventFullKeyCode(s,e)&&r.runGuarded(()=>i(s))}}static _normalizeKey(e){return"esc"===e?"escape":e}static{this.\u0275fac=function(i){return new(i||n)(Fi(sd))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();function wz(n){return{appProviders:[...Jq,...n?.providers??[]],platformProviders:$q}}const $q=[{provide:yu,useValue:"browser"},{provide:rL,useValue:function Gq(){rC.makeCurrent()},multi:!0},{provide:sd,useFactory:function qq(){return function wj(n){C1=n}(document),document},deps:[]}],Jq=[{provide:y1,useValue:"root"},{provide:eh,useFactory:function Xq(){return new eh},deps:[]},{provide:nC,useClass:jq,multi:!0,deps:[sd,zr,yu]},{provide:nC,useClass:Yq,multi:!0,deps:[sd]},Sz,vz,fz,{provide:rN,useExisting:Sz},{provide:class oq{},useClass:kq,deps:[]},[]];var i$=0,cC=!1;function m0(n,t){var e=t;return e.unshift(void 0),new(Function.prototype.bind.apply(n,e))}function Y(n,t){for(var e=t,i=n.replace(/\[/g,".").replace(/\]/g,"").split("."),r=0;r"u"}function wi(n){return n+"_"+i$++}function S0(n,t){return n===t||!(n===document||!n)&&S0(n.parentNode,t)}function Cg(n){try{throw new Error(n)}catch(t){throw new Error(t.message+"\n"+t.stack)}}function Re(n){var t=n+"";return t.match(/auto|cm|mm|in|px|pt|pc|%|em|ex|ch|rem|vw|vh|vmin|vmax/)?t:t+"px"}function ce(){return cC}var Eg,n,t,a$={latn:{_digits:"0123456789",_type:"numeric"}},Tz={decimal:".",group:",",percentSign:"%",plusSign:"+",minusSign:"-",infinity:"\u221e",nan:"NaN",exponential:"E"},Az=[0,1,2,3,4,5,6,7,8,9],Rr=function(){function n(){}return n.getMainObject=function(t,e){return Y(ce()?e:"main."+e,t)},n.getNumberingSystem=function(t){return Y("supplemental.numberingSystems",t)||this.numberingSystems},n.reverseObject=function(t,e){for(var r={},s=0,o=e||Object.keys(t);s13&&(f+=1,o-=12),o-=1,a=f-4716;var y=u-24e5,S=10631/30,b=u-1948084,M=Math.floor(b/10631);b-=10631*M;var w=Math.floor((b-.1335)/S),C=30*M+w;b-=Math.floor(w*S+.1335);var D=Math.floor((b+28.5001)/29.5);13===D&&(D=12);for(var A=b-Math.floor(29.5001*D-29),x=0;xy);x++);var R=x+16260,L=Math.floor((R-1)/12),O=L+1,N=R-12*L,T=y-t[x-1]+1;return(T+"").length>2&&(T=A,N=D,O=C),{year:O,month:N,date:T}},n.toGregorian=function i(r,s,o){var g=Math.floor(o+t[12*(r-1)+1+(s-1)-16260-1]-1+24e5+.5),v=Math.floor((g-1867216.25)/36524.25),y=1524+(v=g+1+v-Math.floor(v/4)),S=Math.floor((y-122.1)/365.25),b=Math.floor(365.25*S),M=Math.floor((y-b)/30.6001),w=y-b-Math.floor(30.6001*M),C=M-(M>13.5?13:1),D=S-(C>2.5?4716:4715);return D<=0&&C--,new Date(D+"/"+C+"/"+w)};var ut,c$=/\/MMMMM|MMMM|MMM|a|LLLL|LLL|EEEEE|EEEE|E|K|cccc|ccc|WW|W|G+|z+/gi,Lz="stand-alone",d$=["sun","mon","tue","wed","thu","fri","sat"],Nz={m:"getMinutes",h:"getHours",H:"getHours",s:"getSeconds",d:"getDate",f:"getMilliseconds"},Oz=function(){function n(){}return n.dateFormat=function(t,e,i){var r=this,s=ut.getDependables(i,t,e.calendar),o=Y("parserObject.numbers",s),a=s.dateObject,l={isIslamic:ut.islamicRegex.test(e.calendar)};ce()&&e.isServerRendered&&(e=ut.compareBlazorDateFormats(e,t));var h=e.format||ut.getResultantPattern(e.skeleton,s.dateObject,e.type,!1,ce()?t:"");if(l.dateSeperator=ce()?Y("dateSeperator",a):ut.getDateSeparator(s.dateObject),st(h))Cg("Format options or type given must be invalid");else{h=ut.ConvertDateToWeekFormat(h),ce()&&(h=h.replace(/tt/,"a")),l.pattern=h,l.numMapper=ce()?ze({},o):Rr.getNumberMapper(s.parserObject,Rr.getNumberingSystem(i));for(var d=0,u=h.match(c$)||[];d2?r+=e.month[""+u]:f=!0;break;case"E":case"c":r+=e.weekday[""+d$[t.getDay()]];break;case"H":case"h":case"m":case"s":case"d":case"f":if(f=!0,"d"===d)u=o.date;else if("f"===d){f=!1,g=!0;var y=(p=(p=t[""+Nz[""+d]]().toString()).substring(0,c)).length;if(c!==y){if(c>3)continue;for(var S=0;S0?1:0],o=Math.abs(t);return s.replace(/HH?|mm/g,function(a){var l=a.length,h=-1!==a.indexOf("H");return i.checkTwodigitNumber(Math.floor(h?o/60:o%60),l)})},n}(),kz={ms:"minimumSignificantDigits",ls:"maximumSignificantDigits",mf:"minimumFractionDigits",lf:"maximumFractionDigits"},ep=["infinity","nan","group","decimal","exponential"],Pz=function(){function n(){}return n.numberFormatter=function(t,e,i){var l,r=this,s=ze({},e),o={},a={},h=ut.getDependables(i,t,"",!0),c=h.numericObject;a.numberMapper=ce()?ze({},c):Rr.getNumberMapper(h.parserObject,Rr.getNumberingSystem(i),!0),a.currencySymbol=ce()?Y("currencySymbol",c):ut.getCurrencySymbol(h.numericObject,s.currency||Tg,e.altSymbol,e.ignoreCurrency),a.percentSymbol=ce()?Y("numberSymbols.percentSign",c):a.numberMapper.numberSymbols.percentSign,a.minusSymbol=ce()?Y("numberSymbols.minusSign",c):a.numberMapper.numberSymbols.minusSign;var d=a.numberMapper.numberSymbols;if(e.format&&!ut.formatRegex.test(e.format))o=ut.customFormat(e.format,a,h.numericObject),!st(s.useGrouping)&&s.useGrouping&&(s.useGrouping=o.pData.useGrouping);else{if(ze(s,ut.getProperNumericSkeleton(e.format||"N")),s.isCurrency="currency"===s.type,s.isPercent="percent"===s.type,ce()||(l=ut.getSymbolPattern(s.type,a.numberMapper.numberSystem,h.numericObject,s.isAccount)),s.groupOne=this.checkValueRange(s.maximumSignificantDigits,s.minimumSignificantDigits,!0),this.checkValueRange(s.maximumFractionDigits,s.minimumFractionDigits,!1,!0),st(s.fractionDigits)||(s.minimumFractionDigits=s.maximumFractionDigits=s.fractionDigits),st(s.useGrouping)&&(s.useGrouping=!0),s.isCurrency&&!ce()&&(l=l.replace(/\u00A4/g,ut.defaultCurrency)),ce())o.nData=ze({},{},Y(s.type+"nData",c)),o.pData=ze({},{},Y(s.type+"pData",c)),"currency"===s.type&&e.currency&&ut.replaceBlazorCurrency([o.pData,o.nData],a.currencySymbol,e.currency);else{var u=l.split(";");o.nData=ut.getFormatData(u[1]||"-"+u[0],!0,a.currencySymbol),o.pData=ut.getFormatData(u[0],!1,a.currencySymbol),s.useGrouping&&(s.groupSeparator=d[ep[2]],s.groupData=this.getGroupingDetails(u[0]))}if(st(s.minimumFractionDigits)&&(s.minimumFractionDigits=o.nData.minimumFraction),st(s.maximumFractionDigits)){var f=o.nData.maximumFraction;s.maximumFractionDigits=st(f)&&s.isPercent?0:f}var g=s.minimumFractionDigits,v=s.maximumFractionDigits;!st(g)&&!st(v)&&g>v&&(s.maximumFractionDigits=g)}return ze(o.nData,s),ze(o.pData,s),function(y){return isNaN(y)?d[ep[1]]:isFinite(y)?r.intNumberFormatter(y,o,a,e):d[ep[0]]}},n.getGroupingDetails=function(t){var e={},i=t.match(ut.negativeDataRegex);if(i&&i[4]){var r=i[4],s=r.lastIndexOf(",");if(-1!==s){var o=r.split(".")[0];e.primary=o.length-s-1;var a=r.lastIndexOf(",",s-1);-1!==a&&(e.secondary=s-1-a)}}return e},n.checkValueRange=function(t,e,i,r){var s=r?"f":"s",o=0,a=kz["l"+s],l=kz["m"+s];if(st(t)||(this.checkRange(t,a,r),o++),st(e)||(this.checkRange(e,l,r),o++),2===o){if(!(tr[1])&&Cg(e+"value must be within the range"+r[0]+"to"+r[1])},n.intNumberFormatter=function(t,e,i,r){var s;if(!st(e.nData.type)){t<0?(t*=-1,s=e.nData):s=0===t&&e.zeroData||e.pData;var o="";if(s.isPercent&&(t*=100),s.groupOne)o=this.processSignificantDigits(t,s.minimumSignificantDigits,s.maximumSignificantDigits);else if(o=this.processFraction(t,s.minimumFractionDigits,s.maximumFractionDigits,r),s.minimumIntegerDigits&&(o=this.processMinimumIntegers(o,s.minimumIntegerDigits)),i.isCustomFormat&&s.minimumFractionDigits=0&&"0"===l[parseInt(c.toString(),10)]&&c>=s.minimumFractionDigits;c--)l=l.slice(0,c);o=a[0]+"."+l}return"scientific"===s.type&&(o=(o=t.toExponential(s.maximumFractionDigits)).replace("e",i.numberMapper.numberSymbols[ep[4]])),o=o.replace(".",i.numberMapper.numberSymbols[ep[3]]),o="#,###,,;(#,###,,)"===s.format?this.customPivotFormat(parseInt(o,10)):o,s.useGrouping&&(o=this.groupNumbers(o,s.groupData.primary,s.groupSeparator||",",i.numberMapper.numberSymbols[ep[3]]||".",s.groupData.secondary)),o=Rr.convertValueParts(o,ut.latnParseRegex,i.numberMapper.mapper),"N/A"===s.nlead?s.nlead:"0"===o&&r&&"0"===r.format?o+s.nend:s.nlead+o+s.nend}},n.processSignificantDigits=function(t,e,i){var r=t+"";return r.lengthe;)c=l.slice(h-e,h)+(c.length?i+c:""),h-=e,o&&(e=s,o=!1);return a[0]=l.slice(0,h)+(c.length?i:"")+c,a.join(r)},n.processFraction=function(t,e,i,r){var s=(t+"").split(".")[1],o=s?s.length:0;if(e&&oi||0===i))return t.toFixed(i);var h=t+"";return"0"===h[0]&&r&&"###.00"===r.format&&(h=h.slice(1)),h},n.processMinimumIntegers=function(t,e){var i=t.split("."),r=i[0],s=r.length;if(s=5e5){var r=(t/=1e6).toString().split(".")[1];return r&&+r.substring(0,1)>=5?Math.ceil(t).toString():Math.floor(t).toString()}return""},n}(),Dg=(new RegExp("^([^0-9]*)(([0-9,]*[0-9]+)(.[0-9]+)?)([Ee][+-]?[0-9]+)?([^0-9]*)$"),function(){function n(t){this.ranArray=[],this.boundedEvents={},!m(t)&&(this.context=t)}return n.prototype.on=function(t,e,i,r){if(!m(e)){var s=i||this.context;if(this.notExist(t))return void(this.boundedEvents[""+t]=[{handler:e,context:s,id:r}]);m(r)?this.isHandlerPresent(this.boundedEvents[""+t],e)||this.boundedEvents[""+t].push({handler:e,context:s}):-1===this.ranArray.indexOf(r)&&(this.ranArray.push(r),this.boundedEvents[""+t].push({handler:e,context:s,id:r}))}},n.prototype.off=function(t,e,i){if(!this.notExist(t)){var r=Y(t,this.boundedEvents);if(e){for(var s=0;s1&&(_.fractionDigits=parseInt(P[2],10)),_}function f(T,P,_,B){var j=B?{}:{nlead:"",nend:""},Q=T.match(n.customRegex);if(Q){B||(j.nlead=g(Q[1],_),j.nend=g(Q[10],_),j.groupPattern=Q[4]);var oe=Q[7];if(oe&&P){var ue=oe.match(t);j.minimumFraction=m(ue)?0:ue.length,j.maximumFraction=oe.length-1}}return j}function g(T,P){return T?(T=T.replace(n.defaultCurrency,P),""===P?T.trim():T):""}function v(T,P,_,B){return B?"$":Y("currencies."+P+(_?"."+_:".symbol"),T)||Y("currencies."+P+".symbol-alt-narrow",T)||"$"}function S(T,P,_){var B={type:"decimal",minimumFractionDigits:0,maximumFractionDigits:0},j=T.match(n.customRegex);if(m(j)||""===j[5]&&"N/A"!==T)return B.type=void 0,B;B.nlead=j[1],B.nend=j[10];var Q=j[6],oe=!!Q.match(/ $/g),ue=-1!==Q.replace(/ $/g,"").indexOf(" ");B.useGrouping=-1!==Q.indexOf(",")||ue,Q=Q.replace(/,/g,"");var pe=j[7];if(-1!==Q.indexOf("0")&&(B.minimumIntegerDigits=Q.length-Q.indexOf("0")),m(pe)||(B.minimumFractionDigits=pe.lastIndexOf("0"),B.maximumFractionDigits=pe.lastIndexOf("#"),-1===B.minimumFractionDigits&&(B.minimumFractionDigits=0),(-1===B.maximumFractionDigits||B.maximumFractionDigitsQ.lastIndexOf("'"))){B[""+a[parseInt(j.toString(),10)]]=Q.substr(0,oe)+_+Q.substr(oe+1),B[""+a[""+P]]=!0,B.type=B.isCurrency?"currency":"percent";break}}return B}function C(T,P){if(-1!==T.indexOf(",")){var _=T.split(",");T=_[0]+Y("numberMapper.numberSymbols.group",P)+_[1].replace(".",Y("numberMapper.numberSymbols.decimal",P))}else T=T.replace(".",Y("numberMapper.numberSymbols.decimal",P));return T}function A(T,P,_){T+=".";for(var B=0;B0;Q-=3)T=","+_[Q-2]+_[Q-1]+_[parseInt(Q.toString(),10)]+T;return T=T.slice(1),P[1]?T+"."+P[1]:T}n.dateParseRegex=/([a-z])\1*|'([^']|'')+'|''|./gi,n.basicPatterns=["short","medium","long","full"],n.defaultObject={dates:{calendars:{gregorian:{months:{"stand-alone":{abbreviated:{1:"Jan",2:"Feb",3:"Mar",4:"Apr",5:"May",6:"Jun",7:"Jul",8:"Aug",9:"Sep",10:"Oct",11:"Nov",12:"Dec"},narrow:{1:"J",2:"F",3:"M",4:"A",5:"M",6:"J",7:"J",8:"A",9:"S",10:"O",11:"N",12:"D"},wide:{1:"January",2:"February",3:"March",4:"April",5:"May",6:"June",7:"July",8:"August",9:"September",10:"October",11:"November",12:"December"}}},days:{"stand-alone":{abbreviated:{sun:"Sun",mon:"Mon",tue:"Tue",wed:"Wed",thu:"Thu",fri:"Fri",sat:"Sat"},narrow:{sun:"S",mon:"M",tue:"T",wed:"W",thu:"T",fri:"F",sat:"S"},short:{sun:"Su",mon:"Mo",tue:"Tu",wed:"We",thu:"Th",fri:"Fr",sat:"Sa"},wide:{sun:"Sunday",mon:"Monday",tue:"Tuesday",wed:"Wednesday",thu:"Thursday",fri:"Friday",sat:"Saturday"}}},dayPeriods:{format:{wide:{am:"AM",pm:"PM"}}},eras:{eraNames:{0:"Before Christ","0-alt-variant":"Before Common Era",1:"Anno Domini","1-alt-variant":"Common Era"},eraAbbr:{0:"BC","0-alt-variant":"BCE",1:"AD","1-alt-variant":"CE"},eraNarrow:{0:"B","0-alt-variant":"BCE",1:"A","1-alt-variant":"CE"}},dateFormats:{full:"EEEE, MMMM d, y",long:"MMMM d, y",medium:"MMM d, y",short:"M/d/yy"},timeFormats:{full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},dateTimeFormats:{full:"{1} 'at' {0}",long:"{1} 'at' {0}",medium:"{1}, {0}",short:"{1}, {0}",availableFormats:{d:"d",E:"ccc",Ed:"d E",Ehm:"E h:mm a",EHm:"E HH:mm",Ehms:"E h:mm:ss a",EHms:"E HH:mm:ss",Gy:"y G",GyMMM:"MMM y G",GyMMMd:"MMM d, y G",GyMMMEd:"E, MMM d, y G",h:"h a",H:"HH",hm:"h:mm a",Hm:"HH:mm",hms:"h:mm:ss a",Hms:"HH:mm:ss",hmsv:"h:mm:ss a v",Hmsv:"HH:mm:ss v",hmv:"h:mm a v",Hmv:"HH:mm v",M:"L",Md:"M/d",MEd:"E, M/d",MMM:"LLL",MMMd:"MMM d",MMMEd:"E, MMM d",MMMMd:"MMMM d",ms:"mm:ss",y:"y",yM:"M/y",yMd:"M/d/y",yMEd:"E, M/d/y",yMMM:"MMM y",yMMMd:"MMM d, y",yMMMEd:"E, MMM d, y",yMMMM:"MMMM y"}}},islamic:{months:{"stand-alone":{abbreviated:{1:"Muh.",2:"Saf.",3:"Rab. I",4:"Rab. II",5:"Jum. I",6:"Jum. II",7:"Raj.",8:"Sha.",9:"Ram.",10:"Shaw.",11:"Dhu\u02bbl-Q.",12:"Dhu\u02bbl-H."},narrow:{1:"1",2:"2",3:"3",4:"4",5:"5",6:"6",7:"7",8:"8",9:"9",10:"10",11:"11",12:"12"},wide:{1:"Muharram",2:"Safar",3:"Rabi\u02bb I",4:"Rabi\u02bb II",5:"Jumada I",6:"Jumada II",7:"Rajab",8:"Sha\u02bbban",9:"Ramadan",10:"Shawwal",11:"Dhu\u02bbl-Qi\u02bbdah",12:"Dhu\u02bbl-Hijjah"}}},days:{"stand-alone":{abbreviated:{sun:"Sun",mon:"Mon",tue:"Tue",wed:"Wed",thu:"Thu",fri:"Fri",sat:"Sat"},narrow:{sun:"S",mon:"M",tue:"T",wed:"W",thu:"T",fri:"F",sat:"S"},short:{sun:"Su",mon:"Mo",tue:"Tu",wed:"We",thu:"Th",fri:"Fr",sat:"Sa"},wide:{sun:"Sunday",mon:"Monday",tue:"Tuesday",wed:"Wednesday",thu:"Thursday",fri:"Friday",sat:"Saturday"}}},dayPeriods:{format:{wide:{am:"AM",pm:"PM"}}},eras:{eraNames:{0:"AH"},eraAbbr:{0:"AH"},eraNarrow:{0:"AH"}},dateFormats:{full:"EEEE, MMMM d, y G",long:"MMMM d, y G",medium:"MMM d, y G",short:"M/d/y GGGGG"},timeFormats:{full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},dateTimeFormats:{full:"{1} 'at' {0}",long:"{1} 'at' {0}",medium:"{1}, {0}",short:"{1}, {0}",availableFormats:{d:"d",E:"ccc",Ed:"d E",Ehm:"E h:mm a",EHm:"E HH:mm",Ehms:"E h:mm:ss a",EHms:"E HH:mm:ss",Gy:"y G",GyMMM:"MMM y G",GyMMMd:"MMM d, y G",GyMMMEd:"E, MMM d, y G",h:"h a",H:"HH",hm:"h:mm a",Hm:"HH:mm",hms:"h:mm:ss a",Hms:"HH:mm:ss",M:"L",Md:"M/d",MEd:"E, M/d",MMM:"LLL",MMMd:"MMM d",MMMEd:"E, MMM d",MMMMd:"MMMM d",ms:"mm:ss",y:"y G",yyyy:"y G",yyyyM:"M/y GGGGG",yyyyMd:"M/d/y GGGGG",yyyyMEd:"E, M/d/y GGGGG",yyyyMMM:"MMM y G",yyyyMMMd:"MMM d, y G",yyyyMMMEd:"E, MMM d, y G",yyyyMMMM:"MMMM y G",yyyyQQQ:"QQQ y G",yyyyQQQQ:"QQQQ y G"}}}},timeZoneNames:{hourFormat:"+HH:mm;-HH:mm",gmtFormat:"GMT{0}",gmtZeroFormat:"GMT"}},numbers:{currencies:{USD:{displayName:"US Dollar",symbol:"$","symbol-alt-narrow":"$"},EUR:{displayName:"Euro",symbol:"\u20ac","symbol-alt-narrow":"\u20ac"},GBP:{displayName:"British Pound","symbol-alt-narrow":"\xa3"}},defaultNumberingSystem:"latn",minimumGroupingDigits:"1","symbols-numberSystem-latn":{decimal:".",group:",",list:";",percentSign:"%",plusSign:"+",minusSign:"-",exponential:"E",superscriptingExponent:"\xd7",perMille:"\u2030",infinity:"\u221e",nan:"NaN",timeSeparator:":"},"decimalFormats-numberSystem-latn":{standard:"#,##0.###"},"percentFormats-numberSystem-latn":{standard:"#,##0%"},"currencyFormats-numberSystem-latn":{standard:"\xa4#,##0.00",accounting:"\xa4#,##0.00;(\xa4#,##0.00)"},"scientificFormats-numberSystem-latn":{standard:"#E0"}}},n.blazorDefaultObject={numbers:{mapper:{0:"0",1:"1",2:"2",3:"3",4:"4",5:"5",6:"6",7:"7",8:"8",9:"9"},mapperDigits:"0123456789",numberSymbols:{decimal:".",group:",",plusSign:"+",minusSign:"-",percentSign:"%",nan:"NaN",timeSeparator:":",infinity:"\u221e"},timeSeparator:":",currencySymbol:"$",currencypData:{nlead:"$",nend:"",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},percentpData:{nlead:"",nend:"%",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},percentnData:{nlead:"-",nend:"%",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},currencynData:{nlead:"($",nend:")",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},decimalnData:{nlead:"-",nend:"",groupData:{primary:3},maximumFraction:2,minimumFraction:2},decimalpData:{nlead:"",nend:"",groupData:{primary:3},maximumFraction:2,minimumFraction:2}},dates:{dayPeriods:{am:"AM",pm:"PM"},dateSeperator:"/",days:{abbreviated:{sun:"Sun",mon:"Mon",tue:"Tue",wed:"Wed",thu:"Thu",fri:"Fri",sat:"Sat"},short:{sun:"Su",mon:"Mo",tue:"Tu",wed:"We",thu:"Th",fri:"Fr",sat:"Sa"},wide:{sun:"Sunday",mon:"Monday",tue:"Tuesday",wed:"Wednesday",thu:"Thursday",fri:"Friday",sat:"Saturday"}},months:{abbreviated:{1:"Jan",2:"Feb",3:"Mar",4:"Apr",5:"May",6:"Jun",7:"Jul",8:"Aug",9:"Sep",10:"Oct",11:"Nov",12:"Dec"},wide:{1:"January",2:"February",3:"March",4:"April",5:"May",6:"June",7:"July",8:"August",9:"September",10:"October",11:"November",12:"December"}},eras:{1:"AD"}}},n.monthIndex={3:"abbreviated",4:"wide",5:"narrow",1:"abbreviated"},n.month="months",n.days="days",n.patternMatcher={C:"currency",P:"percent",N:"decimal",A:"currency",E:"scientific"},n.getResultantPattern=l,n.getDependables=h,n.getSymbolPattern=c,n.ConvertDateToWeekFormat=d,n.compareBlazorDateFormats=u,n.getProperNumericSkeleton=p,n.getFormatData=f,n.changeCurrencySymbol=g,n.getCurrencySymbol=v,n.customFormat=function y(T,P,_){for(var B={},j=T.split(";"),Q=["pData","nData","zeroData"],oe=0;oe1,pe.nData=ce()?Y(De.type+"nData",oe):f(ot[1]||"-"+ot[0],!0,Ie),pe.pData=ce()?Y(De.type+"pData",oe):f(ot[0],!1,Ie),!Me[2]&&!P.minimumFractionDigits&&!P.maximumFractionDigits&&(ue=f(Ve.split(";")[0],!0,"",!0).minimumFraction)}if(n.formatRegex.test(P.format)||!P.format){if(ze(Q,p(P.format||"N")),Q.custom=!1,$e="###0",(Q.fractionDigits||P.minimumFractionDigits||P.maximumFractionDigits||ue)&&(Q.fractionDigits&&(P.minimumFractionDigits=P.maximumFractionDigits=Q.fractionDigits),$e=A($e,ue||Q.fractionDigits||P.minimumFractionDigits||0,P.maximumFractionDigits||0)),P.minimumIntegerDigits&&($e=x($e,P.minimumIntegerDigits)),P.useGrouping&&($e=R($e)),"currency"===Q.type||Q.type&&ce()){ce()&&"currency"!==Q.type&&(pe.pData=Y(Q.type+"pData",oe),pe.nData=Y(Q.type+"nData",oe));var cr=$e;$e=pe.pData.nlead+cr+pe.pData.nend,(pe.hasNegativePattern||ce())&&($e+=";"+pe.nData.nlead+cr+pe.nData.nend)}"percent"===Q.type&&!ce()&&($e+=" %")}else $e=P.format.replace(/'/g,'"');return Object.keys(xe).length>0&&($e=B?$e:C($e,xe)),$e},n.fractionDigitsPattern=A,n.minimumIntegerPattern=x,n.groupingPattern=R,n.getWeekData=function L(T,P){var _="sun",B=Y("supplemental.weekData.firstDay",P),j=T;return/en-/.test(j)&&(j=j.slice(3)),j=j.slice(0,2).toUpperCase()+j.substr(2),B&&(_=B[""+j]||B[j.slice(0,2)]||"sun"),o[""+_]},n.replaceBlazorCurrency=function O(T,P,_){var B=function h$(n){return Y(n||"",l$)}(_);if(P!==B)for(var j=0,Q=T;j=0?_:_+7;var j=Math.floor((T.getTime()-P.getTime()-6e4*(T.getTimezoneOffset()-P.getTimezoneOffset()))/864e5)+1;if(_<4){if((B=Math.floor((j+_-1)/7)+1)>52){var oe=new Date(T.getFullYear()+1,0,1).getDay();B=(oe=oe>=0?oe:oe+7)<4?1:53}}else B=Math.floor((j+_-1)/7);return B}}(ut||(ut={}));var tp=function(){function n(t,e,i){this.type="GET",this.emitError=!0,"string"==typeof t?(this.url=t,this.type=m(e)?this.type:e.toUpperCase(),this.contentType=i):Aa(t)&&Object.keys(t).length>0&&Nn(this,t),this.contentType=m(this.contentType)?"application/json; charset=utf-8":this.contentType}return n.prototype.send=function(t){var e=this,i={"application/json":"json","multipart/form-data":"formData","application/octet-stream":"blob","application/x-www-form-urlencoded":"formData"};try{m(this.fetchRequest)&&"GET"===this.type?this.fetchRequest=new Request(this.url,{method:this.type}):m(this.fetchRequest)&&(this.data=m(t)?this.data:t,this.fetchRequest=new Request(this.url,{method:this.type,headers:{"Content-Type":this.contentType},body:this.data}));var r={cancel:!1,fetchRequest:this.fetchRequest};return this.triggerEvent(this.beforeSend,r),r.cancel?null:(this.fetchResponse=fetch(this.fetchRequest),this.fetchResponse.then(function(s){if(e.triggerEvent(e.onLoad,s),!s.ok)throw s;for(var o="text",a=0,l=Object.keys(i);a-1},n.getValue=function(t,e){var i=typeof window<"u"?window.browserDetails:{};return typeof navigator<"u"&&"MacIntel"===navigator.platform&&navigator.maxTouchPoints>1&&!0===n.isTouch&&!pC.CHROME.test(navigator.userAgent)&&(i.isIos=!0,i.isDevice=!0,i.isTouch=!0,i.isPointer=!0),typeof window<"u"&&window.Capacitor&&"ios"===window.Capacitor.getPlatform()&&(i.isPointer=!1),typeof i[""+t]>"u"?i[""+t]=e.test(n.userAgent):i[""+t]},Object.defineProperty(n,"userAgent",{get:function(){return n.uA},set:function(t){n.uA=t,window.browserDetails={}},enumerable:!0,configurable:!0}),Object.defineProperty(n,"info",{get:function(){return st(window.browserDetails.info)?window.browserDetails.info=n.extractBrowserDetail():window.browserDetails.info},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isIE",{get:function(){return n.getValue("isIE",E$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isTouch",{get:function(){return st(window.browserDetails.isTouch)?window.browserDetails.isTouch="ontouchstart"in window.navigator||window&&window.navigator&&window.navigator.maxTouchPoints>0||"ontouchstart"in window:window.browserDetails.isTouch},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isPointer",{get:function(){return st(window.browserDetails.isPointer)?window.browserDetails.isPointer="pointerEnabled"in window.navigator:window.browserDetails.isPointer},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isMSPointer",{get:function(){return st(window.browserDetails.isMSPointer)?window.browserDetails.isMSPointer="msPointerEnabled"in window.navigator:window.browserDetails.isMSPointer},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isDevice",{get:function(){return n.getValue("isDevice",C$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isIos",{get:function(){return n.getValue("isIos",x$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isIos7",{get:function(){return n.getValue("isIos7",T$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isAndroid",{get:function(){return n.getValue("isAndroid",A$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isWebView",{get:function(){return st(window.browserDetails.isWebView)&&(window.browserDetails.isWebView=!(st(window.cordova)&&st(window.PhoneGap)&&st(window.phonegap)&&"object"!==window.forge)),window.browserDetails.isWebView},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isWindows",{get:function(){return n.getValue("isWindows",L$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"touchStartEvent",{get:function(){return st(window.browserDetails.touchStartEvent)?window.browserDetails.touchStartEvent=n.getTouchStartEvent():window.browserDetails.touchStartEvent},enumerable:!0,configurable:!0}),Object.defineProperty(n,"touchMoveEvent",{get:function(){return st(window.browserDetails.touchMoveEvent)?window.browserDetails.touchMoveEvent=n.getTouchMoveEvent():window.browserDetails.touchMoveEvent},enumerable:!0,configurable:!0}),Object.defineProperty(n,"touchEndEvent",{get:function(){return st(window.browserDetails.touchEndEvent)?window.browserDetails.touchEndEvent=n.getTouchEndEvent():window.browserDetails.touchEndEvent},enumerable:!0,configurable:!0}),Object.defineProperty(n,"touchCancelEvent",{get:function(){return st(window.browserDetails.touchCancelEvent)?window.browserDetails.touchCancelEvent=n.getTouchCancelEvent():window.browserDetails.touchCancelEvent},enumerable:!0,configurable:!0}),n.uA=typeof navigator<"u"?navigator.userAgent:"",n}(),E=function(){function n(){}return n.addOrGetEventData=function(t){return"__eventList"in t?t.__eventList.events:(t.__eventList={},t.__eventList.events=[])},n.add=function(t,e,i,r,s){var a,o=n.addOrGetEventData(t);a=s?function n$(n,t){var e;return function(){for(var i=this,r=[],s=0;s"u"||(e.innerHTML=t.innerHTML?t.innerHTML:"",void 0!==t.className&&(e.className=t.className),void 0!==t.id&&(e.id=t.id),void 0!==t.styles&&e.setAttribute("style",t.styles),void 0!==t.attrs&&Fe(e,t.attrs)),e}function V(n,t){for(var e=Uz(t),i=RegExp,r=0,s=n;r0}function pl(n,t,e){for(var i=document.createDocumentFragment(),r=0,s=n;r0;)i.appendChild(n[0]);else for(var r=0,s=n;r-1&&!r[parseInt(s.toString(),10)].match(/\[.*\]/)){var o=r[parseInt(s.toString(),10)].split("#");if(o[1].match(/^\d/)||o[1].match(t)){var a=r[parseInt(s.toString(),10)].split(".");a[0]=a[0].replace(/#/,"[id='")+"']",r[parseInt(s.toString(),10)]=a.join(".")}}e[parseInt(i.toString(),10)]=r.join(" ")}return e.join(",")}return n}function J(n,t){var e=n;if("function"==typeof e.closest)return e.closest(t);for(;e&&1===e.nodeType;){if(fC(e,t))return e;e=e.parentNode}return null}function je(n,t){void 0!==t&&Object.keys(t).forEach(function(e){n.style[""+e]=t[""+e]})}function fC(n,t){var e=n.matches||n.msMatchesSelector||n.webkitMatchesSelector;return e?e.call(n,t):-1!==[].indexOf.call(document.querySelectorAll(t),n)}var k$=new RegExp("]"),ah=function(){function n(t,e){this.isRendered=!1,this.isComplexArraySetter=!1,this.isServerRendered=!1,this.allowServerDataBinding=!0,this.isProtectedOnChange=!0,this.properties={},this.changedProperties={},this.oldProperties={},this.bulkChanges={},this.refreshing=!1,this.ignoreCollectionWatch=!1,this.finalUpdate=function(){},this.childChangedProperties={},this.modelObserver=new Dg(this),st(e)||(this.element="string"==typeof e?document.querySelector(e):e,m(this.element)||(this.isProtectedOnChange=!1,this.addInstance())),st(t)||this.setProperties(t,!0),this.isDestroyed=!1}return n.prototype.setProperties=function(t,e){var i=this.isProtectedOnChange;this.isProtectedOnChange=!!e,Nn(this,t),!0!==e?(Nn(this.changedProperties,t),this.dataBind()):ce()&&this.isRendered&&this.serverDataBind(t),this.finalUpdate(),this.changedProperties={},this.oldProperties={},this.isProtectedOnChange=i},n.callChildDataBind=function(t,e){for(var r=0,s=Object.keys(t);r=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Hs=function(n){function t(i){var r=n.call(this,i,void 0)||this;return r.easing={ease:"cubic-bezier(0.250, 0.100, 0.250, 1.000)",linear:"cubic-bezier(0.250, 0.250, 0.750, 0.750)",easeIn:"cubic-bezier(0.420, 0.000, 1.000, 1.000)",easeOut:"cubic-bezier(0.000, 0.000, 0.580, 1.000)",easeInOut:"cubic-bezier(0.420, 0.000, 0.580, 1.000)",elasticInOut:"cubic-bezier(0.5,-0.58,0.38,1.81)",elasticIn:"cubic-bezier(0.17,0.67,0.59,1.81)",elasticOut:"cubic-bezier(0.7,-0.75,0.99,1.01)"},r}var e;return W$(t,n),e=t,t.prototype.animate=function(i,r){var s=this.getModel(r=r||{});if("string"==typeof i)for(var a=0,l=Array.prototype.slice.call(we(i,document));a0?r-1:0,i+=e=-1!==e?"-"+e:"-"+r}return this.controlParent!==this.parentObj&&(i=this.parentObj.getParentKey()+"."+this.propName+e),i},n}(),X$=["grid","pivotview","treegrid","spreadsheet","rangeNavigator","DocumentEditor","listbox","inplaceeditor","PdfViewer","richtexteditor","DashboardLayout","chart","stockChart","circulargauge","diagram","heatmap","lineargauge","maps","slider","smithchart","barcode","sparkline","treemap","bulletChart","kanban","daterangepicker","schedule","gantt","signature","query-builder","drop-down-tree","carousel","filemanager","uploader","accordion","tab","treeview"],Kz=[115,121,110,99,102,117,115,105,111,110,46,105,115,76,105,99,86,97,108,105,100,97,116,101,100],eR=function(){function n(t){this.isValidated=!1,this.isLicensed=!0,this.version="27",this.platform=/JavaScript|ASPNET|ASPNETCORE|ASPNETMVC|FileFormats|essentialstudio/i,this.errors={noLicense:"This application was built using a trial version of Syncfusion Essential Studio. To remove the license validation message permanently, a valid license key must be included.",trailExpired:"This application was built using a trial version of Syncfusion Essential Studio. To remove the license validation message permanently, a valid license key must be included.",versionMismatched:"The included Syncfusion license key is invalid.",platformMismatched:"The included Syncfusion license key is invalid.",invalidKey:"The included Syncfusion license key is invalid."},this.manager=function(){var e=null;return{setKey:function i(s){e=s},getKey:function r(){return e}}}(),this.npxManager=function(){return{getKey:function i(){return"npxKeyReplace"}}}(),this.manager.setKey(t)}return n.prototype.validate=function(){if(!this.isValidated&&Ku&&!Y(w0(Kz),Ku)&&!Y("Blazor",Ku)){var i=void 0,r=void 0;if(this.manager&&this.manager.getKey()||this.npxManager&&"npxKeyReplace"!==this.npxManager.getKey()){var s=this.getInfoFromKey();if(s&&s.length)for(var o=0,a=s;o"+i+' Claim your FREE account\n
have a Syncfusion account? Sign In
\n
\n ';if(typeof document<"u"&&!m(document)){var t=mi("div",{innerHTML:n});document.body.appendChild(t)}}(),nR=!0),this.render(),this.mount?this.accessMount():this.trigger("created")}},t.prototype.renderComplete=function(e){ce()&&window.sfBlazor.renderComplete(this.element,e),this.isRendered=!0},t.prototype.dataBind=function(){this.injectModules(),n.prototype.dataBind.call(this)},t.prototype.on=function(e,i,r){if("string"==typeof e)this.localObserver.on(e,i,r);else for(var s=0,o=e;s=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},K$={left:0,top:0,bottom:0,right:0},SC={isDragged:!1},eZ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return sR(t,n),vr([I(0)],t.prototype,"left",void 0),vr([I(0)],t.prototype,"top",void 0),t}(Ee),np=function(n){function t(i,r){var s=n.call(this,r,i)||this;return s.dragLimit=e.getDefaultPosition(),s.borderWidth=e.getDefaultPosition(),s.padding=e.getDefaultPosition(),s.diffX=0,s.prevLeft=0,s.prevTop=0,s.dragProcessStarted=!1,s.eleTop=0,s.tapHoldTimer=0,s.externalInitialize=!1,s.diffY=0,s.parentScrollX=0,s.parentScrollY=0,s.droppables={},s.bind(),s}var e;return sR(t,n),e=t,t.prototype.bind=function(){this.toggleEvents(),X.isIE&&V([this.element],"e-block-touch"),this.droppables[this.scope]={}},t.getDefaultPosition=function(){return ze({},K$)},t.prototype.toggleEvents=function(i){var r;st(this.handle)||(r=U(this.handle,this.element));var s=this.enableTapHold&&X.isDevice&&X.isTouch?this.mobileInitialize:this.initialize;i?E.remove(r||this.element,X.isSafari()?"touchstart":X.touchStartEvent,s):E.add(r||this.element,X.isSafari()?"touchstart":X.touchStartEvent,s,this)},t.prototype.mobileInitialize=function(i){var r=this,s=i.currentTarget;this.tapHoldTimer=setTimeout(function(){r.externalInitialize=!0,r.removeTapholdTimer(),r.initialize(i,s)},this.tapHoldThreshold),E.add(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.removeTapholdTimer,this),E.add(document,X.isSafari()?"touchend":X.touchEndEvent,this.removeTapholdTimer,this)},t.prototype.removeTapholdTimer=function(){clearTimeout(this.tapHoldTimer),E.remove(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.removeTapholdTimer),E.remove(document,X.isSafari()?"touchend":X.touchEndEvent,this.removeTapholdTimer)},t.prototype.getScrollableParent=function(i,r){return m(i)?null:i[{vertical:"scrollHeight",horizontal:"scrollWidth"}[""+r]]>i[{vertical:"clientHeight",horizontal:"clientWidth"}[""+r]]&&("vertical"===r?i.scrollTop>0:i.scrollLeft>0)?("vertical"===r?(this.parentScrollY=this.parentScrollY+(0===this.parentScrollY?i.scrollTop:i.scrollTop-this.parentScrollY),this.tempScrollHeight=i.scrollHeight):(this.parentScrollX=this.parentScrollX+(0===this.parentScrollX?i.scrollLeft:i.scrollLeft-this.parentScrollX),this.tempScrollWidth=i.scrollWidth),m(i)?i:this.getScrollableParent(i.parentNode,r)):this.getScrollableParent(i.parentNode,r)},t.prototype.getScrollableValues=function(){this.parentScrollX=0,this.parentScrollY=0,this.element.classList.contains("e-dialog")&&this.element.classList.contains("e-dlg-modal"),this.getScrollableParent(this.element.parentNode,"vertical"),this.getScrollableParent(this.element.parentNode,"horizontal")},t.prototype.initialize=function(i,r){if(this.currentStateTarget=i.target,!this.isDragStarted()){if(this.isDragStarted(!0),this.externalInitialize=!1,this.target=i.currentTarget||r,this.dragProcessStarted=!1,this.abort){var s=this.abort;"string"==typeof s&&(s=[s]);for(var o=0;o=this.distance||this.externalInitialize){var p=this.getHelperElement(i);if(!p||m(p))return;r&&i.preventDefault();var f=this.helperElement=p;if(this.parentClientRect=this.calculateParentPosition(f.offsetParent),this.dragStart){var v={event:i,element:l,target:this.getProperTargetElement(i),bindEvents:ce()?this.bindDragEvents.bind(this):null,dragElement:f};this.trigger("dragStart",v)}this.dragArea?this.setDragArea():(this.dragLimit={left:0,right:0,bottom:0,top:0},this.borderWidth={top:0,left:0}),o={left:this.position.left-this.parentClientRect.left,top:this.position.top-this.parentClientRect.top},this.clone&&!this.enableTailMode&&(this.diffX=this.position.left-this.offset.left,this.diffY=this.position.top-this.offset.top),this.getScrollableValues();var y=getComputedStyle(l),S=parseFloat(y.marginTop);this.clone&&0!==S&&(o.top+=S),this.eleTop=isNaN(parseFloat(y.top))?0:parseFloat(y.top)-this.offset.top,this.enableScrollHandler&&!this.clone&&(o.top-=this.parentScrollY,o.left-=this.parentScrollX);var b=this.getProcessedPositionValue({top:o.top-this.diffY+"px",left:o.left-this.diffX+"px"});this.dragArea&&"string"!=typeof this.dragArea&&this.dragArea.classList.contains("e-kanban-content")&&"relative"===this.dragArea.style.position&&(o.top+=this.dragArea.scrollTop),this.dragElePosition={top:o.top,left:o.left},je(f,this.getDragPosition({position:"absolute",left:b.left,top:b.top})),E.remove(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.intDragStart),E.remove(document,X.isSafari()?"touchend":X.touchEndEvent,this.intDestroy),ce()||this.bindDragEvents(f)}}},t.prototype.bindDragEvents=function(i){Tr(i)?(E.add(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.intDrag,this),E.add(document,X.isSafari()?"touchend":X.touchEndEvent,this.intDragStop,this),this.setGlobalDroppables(!1,this.element,i)):(this.toggleEvents(),document.body.classList.remove("e-prevent-select"))},t.prototype.elementInViewport=function(i){for(this.top=i.offsetTop,this.left=i.offsetLeft,this.width=i.offsetWidth,this.height=i.offsetHeight;i.offsetParent;)this.top+=(i=i.offsetParent).offsetTop,this.left+=i.offsetLeft;return this.top>=window.pageYOffset&&this.left>=window.pageXOffset&&this.top+this.height<=window.pageYOffset+window.innerHeight&&this.left+this.width<=window.pageXOffset+window.innerWidth},t.prototype.getProcessedPositionValue=function(i){return this.queryPositionInfo?this.queryPositionInfo(i):i},t.prototype.calculateParentPosition=function(i){if(m(i))return{left:0,top:0};var r=i.getBoundingClientRect(),s=getComputedStyle(i);return{left:r.left+window.pageXOffset-parseInt(s.marginLeft,10),top:r.top+window.pageYOffset-parseInt(s.marginTop,10)}},t.prototype.intDrag=function(i){if(st(i.changedTouches)||1===i.changedTouches.length){var r,s;this.clone&&i.changedTouches&&X.isDevice&&X.isTouch&&i.preventDefault(),this.position=this.getMousePosition(i,this.isDragScroll);var o=this.getDocumentWidthHeight("Height");oy&&y>0?this.dragLimit.left:this.dragLimit.right+window.pageXOffset0?y-(y-this.dragLimit.right)+window.pageXOffset-M:y<0?this.dragLimit.left:y}if(this.pageY!==v||this.skipDistanceCheck){var w=d.offsetHeight+(parseFloat(b.marginTop)+parseFloat(b.marginBottom));s=this.dragLimit.top>S&&S>0?this.dragLimit.top:this.dragLimit.bottom+window.pageYOffset0?S-(S-this.dragLimit.bottom)+window.pageYOffset-w:S<0?this.dragLimit.top:S}}else r=y,s=S;var A,x,C=p+this.borderWidth.top,D=u+this.borderWidth.left;if(this.dragProcessStarted&&(m(s)&&(s=this.prevTop),m(r)&&(r=this.prevLeft)),this.helperElement.classList.contains("e-treeview"))this.dragArea?(this.dragLimit.top=this.clone?this.dragLimit.top:0,A=s-C<0?this.dragLimit.top:s-this.borderWidth.top,x=r-D<0?this.dragLimit.left:r-this.borderWidth.left):(A=s-this.borderWidth.top,x=r-this.borderWidth.left);else if(this.dragArea){var R=this.helperElement.classList.contains("e-dialog");this.dragLimit.top=this.clone?this.dragLimit.top:0,A=s-C<0?this.dragLimit.top:s-C,x=r-D<0?R?r-(D-this.borderWidth.left):this.dragElePosition.left:r-D}else A=s-C,x=r-D;var L=parseFloat(getComputedStyle(this.element).marginTop);if(L>0&&(this.clone&&(A+=L,S<0&&(L+S>=0?A=L+S:A-=L),this.dragArea&&(A=this.dragLimit.bottom=0){var O=this.dragLimit.top+S-C;O+L+C<0?A-=L+C:A=O}else A-=L+C;this.dragArea&&this.helperElement.classList.contains("e-treeview")&&(A=A+(w=d.offsetHeight+(parseFloat(b.marginTop)+parseFloat(b.marginBottom)))>this.dragLimit.bottom?this.dragLimit.bottom-w:A),this.enableScrollHandler&&!this.clone&&(A-=this.parentScrollY,x-=this.parentScrollX),this.dragArea&&"string"!=typeof this.dragArea&&this.dragArea.classList.contains("e-kanban-content")&&"relative"===this.dragArea.style.position&&(A+=this.dragArea.scrollTop);var N=this.getProcessedPositionValue({top:A+"px",left:x+"px"});this.isPreventScroll&&(N=this.getProcessedPositionValue({top:this.position.top-this.parentClientRect.top-2+"px",left:this.position.left-this.parentClientRect.left-2+"px"})),je(d,this.getDragPosition(N)),!this.elementInViewport(d)&&this.enableAutoScroll&&!this.helperElement.classList.contains("e-treeview")&&this.helperElement.scrollIntoView();var T=document.querySelectorAll(":hover");if(this.enableAutoScroll&&this.helperElement.classList.contains("e-treeview")){0===T.length&&(T=this.getPathElements(i));var P=this.getScrollParent(T,!1);this.elementInViewport(this.helperElement)?this.getScrollPosition(P,A):this.elementInViewport(this.helperElement)||(0===(T=[].slice.call(document.querySelectorAll(":hover"))).length&&(T=this.getPathElements(i)),P=this.getScrollParent(T,!0),this.getScrollPosition(P,A))}this.dragProcessStarted=!0,this.prevLeft=r,this.prevTop=s,this.position.left=r,this.position.top=s,this.pageX=g,this.pageY=v}},t.prototype.getScrollParent=function(i,r){for(var o,s=r?i.reverse():i,a=s.length-1;a>=0;a--)if(("auto"===(o=window.getComputedStyle(s[parseInt(a.toString(),10)])["overflow-y"])||"scroll"===o)&&s[parseInt(a.toString(),10)].scrollHeight>s[parseInt(a.toString(),10)].clientHeight)return s[parseInt(a.toString(),10)];if("visible"===(o=window.getComputedStyle(document.scrollingElement)["overflow-y"]))return document.scrollingElement.style.overflow="auto",document.scrollingElement},t.prototype.getScrollPosition=function(i,r){if(i&&i===document.scrollingElement)i.clientHeight+document.scrollingElement.scrollTop-this.helperElement.clientHeightr?i.scrollTop+=this.helperElement.clientHeight:i.scrollTop>r-this.helperElement.clientHeight&&(i.scrollTop-=this.helperElement.clientHeight);else if(i&&i!==document.scrollingElement){var s=document.scrollingElement.scrollTop,o=this.helperElement.clientHeight;i.clientHeight+i.getBoundingClientRect().top-o+sr-o-s&&(i.scrollTop-=this.helperElement.clientHeight)}},t.prototype.getPathElements=function(i){return document.elementsFromPoint(i.clientX>0?i.clientX:0,i.clientY>0?i.clientY:0)},t.prototype.triggerOutFunction=function(i,r){this.hoverObject.instance.intOut(i,r.target),this.hoverObject.instance.dragData[this.scope]=null,this.hoverObject=null},t.prototype.getDragPosition=function(i){var r=ze({},i);return this.axis&&("x"===this.axis?delete r.top:"y"===this.axis&&delete r.left),r},t.prototype.getDocumentWidthHeight=function(i){var r=document.body,s=document.documentElement;return Math.max(r["scroll"+i],s["scroll"+i],r["offset"+i],s["offset"+i],s["client"+i])},t.prototype.intDragStop=function(i){if(this.dragProcessStarted=!1,st(i.changedTouches)||1===i.changedTouches.length){if(-1!==["touchend","pointerup","mouseup"].indexOf(i.type)){if(this.dragStop){var s=this.getProperTargetElement(i);this.trigger("dragStop",{event:i,element:this.element,target:s,helper:this.helperElement})}this.intDestroy(i)}else this.element.setAttribute("aria-grabbed","false");var o=this.checkTargetElement(i);o.target&&o.instance&&(o.instance.dragStopCalled=!0,o.instance.dragData[this.scope]=this.droppables[this.scope],o.instance.intDrop(i,o.target)),this.setGlobalDroppables(!0),document.body.classList.remove("e-prevent-select")}},t.prototype.intDestroy=function(i){this.dragProcessStarted=!1,this.toggleEvents(),document.body.classList.remove("e-prevent-select"),this.element.setAttribute("aria-grabbed","false"),E.remove(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.intDragStart),E.remove(document,X.isSafari()?"touchend":X.touchEndEvent,this.intDragStop),E.remove(document,X.isSafari()?"touchend":X.touchEndEvent,this.intDestroy),E.remove(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.intDrag),this.isDragStarted()&&this.isDragStarted(!0)},t.prototype.onPropertyChanged=function(i,r){},t.prototype.getModuleName=function(){return"draggable"},t.prototype.isDragStarted=function(i){return i&&(SC.isDragged=!SC.isDragged),SC.isDragged},t.prototype.setDragArea=function(){var i,r,a,s=0,o=0;if(a="string"==typeof this.dragArea?U(this.dragArea):this.dragArea){var h=a.getBoundingClientRect();i=a.scrollWidth?a.scrollWidth:h.right-h.left,r=a.scrollHeight?this.dragArea&&!m(this.helperElement)&&this.helperElement.classList.contains("e-treeview")?a.clientHeight:a.scrollHeight:h.bottom-h.top;for(var c=["Top","Left","Bottom","Right"],d=getComputedStyle(a),u=0;u12;return S0(i.target,this.helperElement)||-1!==i.type.indexOf("touch")||a?(this.helperElement.style.pointerEvents="none",s=document.elementFromPoint(r.clientX,r.clientY),this.helperElement.style.pointerEvents=o):s=i.target,s},t.prototype.currentStateCheck=function(i,r){return m(this.currentStateTarget)||this.currentStateTarget===i?m(r)?i:r:this.currentStateTarget},t.prototype.getMousePosition=function(i,r){var a,l,s=void 0!==i.srcElement?i.srcElement:i.target,o=this.getCoordinates(i),h=m(s.offsetParent);if(r?(a=this.clone?o.pageX:o.pageX+(h?0:s.offsetParent.scrollLeft)-this.relativeXPosition,l=this.clone?o.pageY:o.pageY+(h?0:s.offsetParent.scrollTop)-this.relativeYPosition):(a=this.clone?o.pageX:o.pageX+window.pageXOffset-this.relativeXPosition,l=this.clone?o.pageY:o.pageY+window.pageYOffset-this.relativeYPosition),document.scrollingElement&&!r&&!this.clone){var c=document.scrollingElement;a=c.scrollWidth>0&&c.scrollWidth>c.clientWidth&&c.scrollLeft>0?a-c.scrollLeft:a,l=c.scrollHeight>0&&c.scrollHeight>c.clientHeight&&c.scrollTop>0?l-c.scrollTop:l}return{left:a-(this.margin.left+this.cursorAt.left),top:l-(this.margin.top+this.cursorAt.top)}},t.prototype.getCoordinates=function(i){return i.type.indexOf("touch")>-1?i.changedTouches[0]:i},t.prototype.getHelperElement=function(i){var r;return this.clone?this.helper?r=this.helper({sender:i,element:this.target}):(r=mi("div",{className:"e-drag-helper e-block-touch",innerHTML:"Draggable"}),document.body.appendChild(r)):r=this.element,r},t.prototype.setGlobalDroppables=function(i,r,s){this.droppables[this.scope]=i?null:{draggable:r,helper:s,draggedElement:this.element}},t.prototype.checkTargetElement=function(i){var r=this.getProperTargetElement(i),s=this.getDropInstance(r);if(!s&&r&&!m(r.parentNode)){var o=J(r.parentNode,".e-droppable")||r.parentElement;o&&(s=this.getDropInstance(o))}return{target:r,instance:s}},t.prototype.getDropInstance=function(i){var s,o=i&&i.ej2_instances;if(o)for(var a=0,l=o;a=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},oR=function(n){function t(e,i){var r=n.call(this,i,e)||this;return r.mouseOver=!1,r.dragData={},r.dragStopCalled=!1,r.bind(),r}return tZ(t,n),t.prototype.bind=function(){this.wireEvents()},t.prototype.wireEvents=function(){E.add(this.element,X.isSafari()?"touchend":X.touchEndEvent,this.intDrop,this)},t.prototype.onPropertyChanged=function(e,i){},t.prototype.getModuleName=function(){return"droppable"},t.prototype.intOver=function(e,i){this.mouseOver||(this.trigger("over",{event:e,target:i,dragData:this.dragData[this.scope]}),this.mouseOver=!0)},t.prototype.intOut=function(e,i){this.mouseOver&&(this.trigger("out",{evt:e,target:i}),this.mouseOver=!1)},t.prototype.intDrop=function(e,i){if(this.dragStopCalled){this.dragStopCalled=!1;var a,r=!0,s=this.dragData[this.scope],o=!!s&&s.helper&&Tr(s.helper);o&&(a=this.isDropArea(e,s.helper,i),this.accept&&(r=fC(s.helper,this.accept))),o&&this.drop&&a.canDrop&&r&&this.trigger("drop",{event:e,target:a.target,droppedElement:s.helper,dragData:s}),this.mouseOver=!1}},t.prototype.isDropArea=function(e,i,r){var s={canDrop:!0,target:r||e.target},o="touchend"===e.type;if(o||s.target===i){i.style.display="none";var a=o?e.changedTouches[0]:e,l=document.elementFromPoint(a.clientX,a.clientY);s.canDrop=!1,s.canDrop=S0(l,this.element),s.canDrop&&(s.target=l),i.style.display=""}return s},t.prototype.destroy=function(){E.remove(this.element,X.isSafari()?"touchend":X.touchEndEvent,this.intDrop),n.prototype.destroy.call(this)},sp([I()],t.prototype,"accept",void 0),sp([I("default")],t.prototype,"scope",void 0),sp([H()],t.prototype,"drop",void 0),sp([H()],t.prototype,"over",void 0),sp([H()],t.prototype,"out",void 0),sp([Ft],t)}(ah),ho=function(){function n(t,e,i){this.controlName=t,this.localeStrings=e,this.setLocale(i||"en-US")}return n.prototype.setLocale=function(t){var e=this.intGetControlConstant(n.locale,t);this.currentLocale=e||this.localeStrings},n.load=function(t){this.locale=ze(this.locale,t,{},!0)},n.prototype.getConstant=function(t){return m(this.currentLocale[""+t])?this.localeStrings[""+t]||"":this.currentLocale[""+t]},n.prototype.intGetControlConstant=function(t,e){return t[""+e]?t[""+e][this.controlName]:null},n.locale={},n}(),aR=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),hh=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},nZ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return aR(t,n),hh([I(50)],t.prototype,"swipeThresholdDistance",void 0),t}(Ee),sZ=/(Up|Down)/,Fs=function(n){function t(e,i){var r=n.call(this,i,e)||this;return r.touchAction=!0,r.tapCount=0,r.startEvent=function(s){if(!0===r.touchAction){var o=r.updateChangeTouches(s);void 0!==s.changedTouches&&(r.touchAction=!1),r.isTouchMoved=!1,r.movedDirection="",r.startPoint=r.lastMovedPoint={clientX:o.clientX,clientY:o.clientY},r.startEventData=o,r.hScrollLocked=r.vScrollLocked=!1,r.tStampStart=Date.now(),r.timeOutTapHold=setTimeout(function(){r.tapHoldEvent(s)},r.tapHoldThreshold),E.add(r.element,X.touchMoveEvent,r.moveEvent,r),E.add(r.element,X.touchEndEvent,r.endEvent,r),E.add(r.element,X.touchCancelEvent,r.cancelEvent,r)}},r.moveEvent=function(s){var o=r.updateChangeTouches(s);r.movedPoint=o,r.isTouchMoved=!(o.clientX===r.startPoint.clientX&&o.clientY===r.startPoint.clientY);var a={};r.isTouchMoved&&(clearTimeout(r.timeOutTapHold),r.calcScrollPoints(s),a=ze(a,{},{startEvents:r.startEventData,originalEvent:s,startX:r.startPoint.clientX,startY:r.startPoint.clientY,distanceX:r.distanceX,distanceY:r.distanceY,scrollDirection:r.scrollDirection,velocity:r.getVelocity(o)}),r.trigger("scroll",a),r.lastMovedPoint={clientX:o.clientX,clientY:o.clientY})},r.cancelEvent=function(s){clearTimeout(r.timeOutTapHold),clearTimeout(r.timeOutTap),r.tapCount=0,r.swipeFn(s),E.remove(r.element,X.touchCancelEvent,r.cancelEvent)},r.endEvent=function(s){r.swipeFn(s),r.isTouchMoved||"function"==typeof r.tap&&(r.trigger("tap",{originalEvent:s,tapCount:++r.tapCount}),r.timeOutTap=setTimeout(function(){r.tapCount=0},r.tapThreshold)),r.modeclear()},r.swipeFn=function(s){clearTimeout(r.timeOutTapHold),clearTimeout(r.timeOutTap);var o=r.updateChangeTouches(s),a=o.clientX-r.startPoint.clientX,l=o.clientY-r.startPoint.clientY;a=Math.floor(a<0?-1*a:a),l=Math.floor(l<0?-1*l:a),r.isTouchMoved=a>1||l>1,/Firefox/.test(X.userAgent)&&0===o.clientX&&0===o.clientY&&"mouseup"===s.type&&(r.isTouchMoved=!1),r.endPoint=o,r.calcPoints(s);var c={originalEvent:s,startEvents:r.startEventData,startX:r.startPoint.clientX,startY:r.startPoint.clientY,distanceX:r.distanceX,distanceY:r.distanceY,swipeDirection:r.movedDirection,velocity:r.getVelocity(o)};if(r.isTouchMoved){var d=r.swipeSettings.swipeThresholdDistance,u=ze(void 0,r.defaultArgs,c),p=!1,f=r.element,g=r.isScrollable(f),v=sZ.test(r.movedDirection);(dthis.distanceY?i.clientX>this.startPoint.clientX?"Right":"Left":i.clientYthis.distanceY||!0===this.hScrollLocked)&&!1===this.vScrollLocked?(this.scrollDirection=i.clientX>this.lastMovedPoint.clientX?"Right":"Left",this.hScrollLocked=!0):(this.scrollDirection=i.clientY=e[r[0]+s[0]]},t.prototype.updateChangeTouches=function(e){return e.changedTouches&&0!==e.changedTouches.length?e.changedTouches[0]:e},hh([H()],t.prototype,"tap",void 0),hh([H()],t.prototype,"tapHold",void 0),hh([H()],t.prototype,"swipe",void 0),hh([H()],t.prototype,"scroll",void 0),hh([I(350)],t.prototype,"tapThreshold",void 0),hh([I(750)],t.prototype,"tapHoldThreshold",void 0),hh([re({},nZ)],t.prototype,"swipeSettings",void 0),hh([Ft],t)}(ah),oZ=new RegExp("\\n|\\r|\\s\\s+","g"),aZ=new RegExp(/'|"/g),lZ=new RegExp("if ?\\("),hZ=new RegExp("else if ?\\("),lR=new RegExp("else"),cZ=new RegExp("for ?\\("),hR=new RegExp("(/if|/for)"),dZ=new RegExp("\\((.*)\\)",""),IC=new RegExp("^[0-9]+$","g"),uZ=new RegExp("[\\w\"'.\\s+]+","g"),pZ=new RegExp('"(.*?)"',"g"),fZ=new RegExp("[\\w\"'@#$.\\s-+]+","g"),cR=new RegExp("\\${([^}]*)}","g"),gZ=/^\..*/gm,bC=/\\/gi,vZ=/\\\\/gi,mZ=new RegExp("[\\w\"'@#$.\\s+]+","g"),yZ=/\window\./gm;function op(n,t,e,i,r){return!t||IC.test(n)||-1!==i.indexOf(n.split(".")[0])||r||"true"===n||"false"===n?n:e+"."+n}function MC(n,t,e,i){return t&&!IC.test(n)&&-1===i.indexOf(n.split(".")[0])?e+'["'+n:n}function dR(n){return n.match(vZ)?n:n.replace(bC,"\\\\")}function uR(n,t,e,i){if(n=n.trim(),/\window\./gm.test(n))return n;var s=/'|"/gm;return/@|\$|#/gm.test(n)&&(n=MC(n,-1===e.indexOf(n),t,e)+'"]'),gZ.test(n)?function bZ(n,t,e,i){return!t||IC.test(n)||-1!==i.indexOf(n.split(".")[0])||/^\..*/gm.test(n)?n:e+"."+n}(n,!s.test(n)&&-1===e.indexOf(n),t,e):op(n,!s.test(n)&&-1===e.indexOf(n),t,e,i)}var MZ=/^[\n\r.]+0&&t.forEach(function(e){he(e)})},n.removeJsEvents=function(){var t=this.wrapElement.querySelectorAll("["+fR.join("],[")+"]");t.length>0&&t.forEach(function(e){fR.forEach(function(i){e.hasAttribute(i)&&e.removeAttribute(i)})})},n.removeXssAttrs=function(){var t=this;this.removeAttrs.forEach(function(e,i){var r=t.wrapElement.querySelectorAll(e.selector);r.length>0&&r.forEach("a[href]"===e.selector?function(s){-1!==s.getAttribute(e.attribute).replace(/\t|\s|&/,"").indexOf("javascript:alert")&&s.removeAttribute(e.attribute)}:function(s){s.removeAttribute(e.attribute)})})},n}();function AZ(n){for(var t,e=n.childNodes,i=0;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Jo_RTL=(new Dg,"e-rtl"),ys=function(n){function t(e,i){return n.call(this,e,i)||this}return OZ(t,n),t.prototype.preRender=function(){},t.prototype.render=function(){this.initialize(),this.removeRippleEffect=function ms(n,t,e){var i=function Y$(n){return{selector:n&&n.selector?n.selector:null,ignore:n&&n.ignore?n.ignore:null,rippleFlag:n&&n.rippleFlag,isCenterRipple:n&&n.isCenterRipple,duration:n&&n.duration?n.duration:350}}(t);return!1===i.rippleFlag||void 0===i.rippleFlag&&!Zo?function(){}:(n.setAttribute("data-ripple","true"),E.add(n,"mousedown",qz,{parent:n,rippleOptions:i}),E.add(n,"mouseup",$z,{parent:n,rippleOptions:i,done:e}),E.add(n,"mouseleave",rp,{parent:n,rippleOptions:i}),X.isPointer&&E.add(n,"transitionend",rp,{parent:n,rippleOptions:i}),function(){n.removeAttribute("data-ripple"),E.remove(n,"mousedown",qz),E.remove(n,"mouseup",$z),E.remove(n,"mouseleave",rp),E.remove(n,"transitionend",rp)})}(this.element,{selector:".e-btn"}),this.renderComplete()},t.prototype.initialize=function(){if(this.cssClass&&V([this.element],this.cssClass.replace(/\s+/g," ").trim().split(" ")),this.isPrimary&&this.element.classList.add("e-primary"),!ce()||ce()&&"progress-btn"!==this.getModuleName()){if(this.content){var e=this.enableHtmlSanitizer?Ti.sanitize(this.content):this.content;this.element.innerHTML=e}this.setIconCss()}this.enableRtl&&this.element.classList.add(Jo_RTL),this.disabled?this.controlStatus(this.disabled):this.wireEvents()},t.prototype.controlStatus=function(e){this.element.disabled=e},t.prototype.setIconCss=function(){if(this.iconCss){var e=this.createElement("span",{className:"e-btn-icon "+this.iconCss});this.element.textContent.trim()?(e.classList.add("e-icon-"+this.iconPosition.toLowerCase()),("Top"===this.iconPosition||"Bottom"===this.iconPosition)&&this.element.classList.add("e-"+this.iconPosition.toLowerCase()+"-icon-btn")):this.element.classList.add("e-icon-btn");var i=this.element.childNodes[0];!i||"Left"!==this.iconPosition&&"Top"!==this.iconPosition?this.element.appendChild(e):this.element.insertBefore(e,i)}},t.prototype.wireEvents=function(){this.isToggle&&E.add(this.element,"click",this.btnClickHandler,this)},t.prototype.unWireEvents=function(){this.isToggle&&E.remove(this.element,"click",this.btnClickHandler)},t.prototype.btnClickHandler=function(){this.element.classList.contains("e-active")?this.element.classList.remove("e-active"):this.element.classList.add("e-active")},t.prototype.destroy=function(){var e=["e-primary",Jo_RTL,"e-icon-btn","e-success","e-info","e-danger","e-warning","e-flat","e-outline","e-small","e-bigger","e-active","e-round","e-top-icon-btn","e-bottom-icon-btn"];this.cssClass&&(e=e.concat(this.cssClass.split(" "))),n.prototype.destroy.call(this),K([this.element],e),this.element.getAttribute("class")||this.element.removeAttribute("class"),this.disabled&&this.element.removeAttribute("disabled"),this.content&&(this.element.innerHTML=this.element.innerHTML.replace(this.content,""));var i=this.element.querySelector("span.e-btn-icon");i&&he(i),this.unWireEvents(),Zo&&this.removeRippleEffect()},t.prototype.getModuleName=function(){return"btn"},t.prototype.getPersistData=function(){return this.addOnPersist([])},t.Inject=function(){},t.prototype.onPropertyChanged=function(e,i){for(var r=this.element.querySelector("span.e-btn-icon"),s=0,o=Object.keys(e);s=ad.width?ad.width:0;return vl.right+WR()-n}function aE(){return P0()+vl.width/2}function lE(n,t,e,i){if(void 0===t&&(t=null),void 0===e&&(e={X:!1,Y:!1}),!e.Y&&!e.X)return{left:0,top:0};var r=n.getBoundingClientRect();if(uo=t,sc=n.ownerDocument,i||(i=is(n,"left","top")),e.X){var s=uo?qR():e4(),o=pE(),a=fE(),l=o-i.left,h=i.left+r.width-a;r.width>s?i.left=l>0&&h<=0?a-r.width:h>0&&l<=0?o:l>h?a-r.width:o:l>0?i.left+=l:h>0&&(i.left-=h)}if(e.Y){var c=uo?$R():KR(),d=uE(),u=gE(),p=d-i.top,f=i.top+r.height-u;r.height>c?i.top=p>0&&f<=0?u-r.height:f>0&&p<=0?d:p>f?u-r.height:d:p>0?i.top+=p:f>0&&(i.top-=f)}return i}function oc(n,t,e,i){void 0===t&&(t=null);var r=is(n,"left","top");e&&(r.left=e),i&&(r.top=i);var s=[];uo=t,sc=n.ownerDocument;var o=n.getBoundingClientRect(),l=r.left,h=r.left+o.width,d=dE(r.top,r.top+o.height),u=QR(l,h);return d.topSide&&s.push("top"),u.rightSide&&s.push("right"),u.leftSide&&s.push("left"),d.bottomSide&&s.push("bottom"),s}function lJ(n,t,e,i,r,s,o,a,l){if(void 0===o&&(o=null),void 0===a&&(a={X:!0,Y:!0}),t&&n&&r&&s&&(a.X||a.Y)){var d,h={TL:null,TR:null,BL:null,BR:null},c={TL:null,TR:null,BL:null,BR:null};if("none"===window.getComputedStyle(n).display){var u=n.style.visibility;n.style.visibility="hidden",n.style.display="block",d=n.getBoundingClientRect(),n.style.removeProperty("display"),n.style.visibility=u}else d=n.getBoundingClientRect();var p={posX:r,posY:s,offsetX:e,offsetY:i,position:{left:0,top:0}};uo=o,sc=t.ownerDocument,function cJ(n,t,e,i,r){e.position=is(n,e.posX,e.posY,i,r),t.TL=is(n,"left","top",i,r),t.TR=is(n,"right","top",i,r),t.BR=is(n,"left","bottom",i,r),t.BL=is(n,"right","bottom",i,r)}(t,h,p,l,d),cE(c,p,d),a.X&&GR(t,c,h,p,d,!0),a.Y&&h.TL.top>-1&&XR(t,c,h,p,d,!0),function hJ(n,t,e){var i=0,r=0;if(null!=n.offsetParent&&("absolute"===getComputedStyle(n.offsetParent).position||"relative"===getComputedStyle(n.offsetParent).position)){var s=is(n.offsetParent,"left","top",!1,e);i=s.left,r=s.top}var o=1,a=1,l=YR(n);if(l){var h=getComputedStyle(l).transform;if("none"!==h){var c=new DOMMatrix(h);o=c.a,a=c.d}if("none"!==getComputedStyle(l).zoom){var u=hE(document.body);o*=u,a*=u}}n.style.top=t.position.top/a+t.offsetY-r/a+"px",n.style.left=t.position.left/o+t.offsetX-i/o+"px"}(n,p,d)}}function hE(n){var t=getComputedStyle(n).zoom;return parseFloat(t)||1}function YR(n){for(;n;){var t=window.getComputedStyle(n).transform,e=hE(document.body);if(t&&"none"!==t||e&&1!==e)return n;if(n===document.body)return null;n=n.offsetParent||n.parentElement}return null}function cE(n,t,e){n.TL={top:t.position.top+t.offsetY,left:t.position.left+t.offsetX},n.TR={top:n.TL.top,left:n.TL.left+e.width},n.BL={top:n.TL.top+e.height,left:n.TL.left},n.BR={top:n.TL.top+e.height,left:n.TL.left+e.width}}function QR(n,t){var e=!1,i=!1;return n-R0()fE()&&(i=!0),{leftSide:e,rightSide:i}}function GR(n,t,e,i,r,s){var o=QR(t.TL.left,t.TR.left),a=dE(t.TL.top,t.BL.top);e.TL.left-R0()<=pE()&&(o.leftSide=!1),e.TR.left>fE()&&(o.rightSide=!1),(o.leftSide&&!o.rightSide||!o.leftSide&&o.rightSide)&&(i.posX="right"===i.posX?"left":"right",i.offsetX=i.offsetX+r.width,i.offsetX=-1*i.offsetX,i.position=is(n,i.posX,i.posY,!1),cE(t,i,r),s&&GR(n,t,e,i,r,!1),!o.leftSide&&o.rightSide&&a.bottomSide&&(i.offsetX=0))}function XR(n,t,e,i,r,s){var o=dE(t.TL.top,t.BL.top);e.TL.top-z0()<=uE()&&(o.topSide=!1),e.BL.top>=gE()&&n.getBoundingClientRect().bottomgE()&&(i=!0),{topSide:e,bottomSide:i}}function qR(){return uo.getBoundingClientRect().width}function $R(){return uo.getBoundingClientRect().height}function ZR(){return uo.getBoundingClientRect().left}function JR(){return uo.getBoundingClientRect().top}function uE(){return uo?JR():0}function pE(){return uo?ZR():0}function fE(){return uo?R0()+ZR()+qR():R0()+e4()}function gE(){return uo?z0()+JR()+$R():z0()+KR()}function z0(){return sc.documentElement.scrollTop||sc.body.scrollTop}function R0(){return sc.documentElement.scrollLeft||sc.body.scrollLeft}function KR(){return window.innerHeight}function e4(){var n=window.innerWidth,t=document.documentElement.getBoundingClientRect();return n-(n-(m(document.documentElement)?0:t.width))}function t4(){uo=null,sc=null}var i4=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),bn=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},r4=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return i4(t,n),bn([I("left")],t.prototype,"X",void 0),bn([I("top")],t.prototype,"Y",void 0),t}(Ee),Gn_OPEN="e-popup-open",Gn_CLOSE="e-popup-close",ac=function(n){function t(e,i){return n.call(this,i,e)||this}return i4(t,n),t.prototype.onPropertyChanged=function(e,i){for(var r=0,s=Object.keys(e);r0&&c.left>0&&c.right>0&&c.bottom>0}var s=i.getBoundingClientRect();return!(r.bottoms.bottom||r.right>s.right||r.leftr.top?this.element.style.top="0px":s.bottomr.left&&(this.element.style.left=parseInt(this.element.style.left,10)+(s.left-r.left)+"px"))}},t.prototype.checkCollision=function(){var e=this.collision.X,i=this.collision.Y;"none"===e&&"none"===i||("flip"===e&&"flip"===i?this.callFlip({X:!0,Y:!0}):"fit"===e&&"fit"===i?this.callFit({X:!0,Y:!0}):("flip"===e?this.callFlip({X:!0,Y:!1}):"flip"===i&&this.callFlip({Y:!0,X:!1}),"fit"===e?this.callFit({X:!0,Y:!1}):"fit"===i&&this.callFit({X:!1,Y:!0})))},t.prototype.show=function(e,i){var r=this;if(this.getRelateToElement().classList.contains("e-filemanager")&&(this.fmDialogContainer=this.element.getElementsByClassName("e-file-select-wrap")[0]),this.wireEvents(),!m(this.fmDialogContainer)&&X.isIos&&(this.fmDialogContainer.style.display="block"),1e3===this.zIndex||!m(i)){var o=m(i)?this.element:i;this.zIndex=lc(o),je(this.element,{zIndex:this.zIndex})}e=m(e)||"object"!=typeof e?this.showAnimation:e,("none"!==this.collision.X||"none"!==this.collision.Y)&&(K([this.element],Gn_CLOSE),V([this.element],Gn_OPEN),this.checkCollision(),K([this.element],Gn_OPEN),V([this.element],Gn_CLOSE)),m(e)?(K([this.element],Gn_CLOSE),V([this.element],Gn_OPEN),this.trigger("open")):(e.begin=function(){r.isDestroyed||(K([r.element],Gn_CLOSE),V([r.element],Gn_OPEN))},e.end=function(){r.isDestroyed||r.trigger("open")},new Hs(e).animate(this.element))},t.prototype.hide=function(e){var i=this;e=m(e)||"object"!=typeof e?this.hideAnimation:e,m(e)?(K([this.element],Gn_OPEN),V([this.element],Gn_CLOSE),this.trigger("close")):(e.end=function(){i.isDestroyed||(K([i.element],Gn_OPEN),V([i.element],Gn_CLOSE),i.trigger("close"))},new Hs(e).animate(this.element)),this.unwireEvents()},t.prototype.getScrollableParent=function(e){return this.checkFixedParent(e),function vE(n,t){for(var e=getComputedStyle(n),i=[],r=/(auto|scroll)/,s=n.parentElement;s&&"HTML"!==s.tagName;){var o=getComputedStyle(s);!("absolute"===e.position&&"static"===o.position)&&r.test(o.overflow+o.overflowY+o.overflowX)&&i.push(s),s=s.parentElement}return t||i.push(document),i}(e,this.fixedParent)},t.prototype.checkFixedParent=function(e){for(var i=e.parentElement;i&&"HTML"!==i.tagName;){var r=getComputedStyle(i);("fixed"===r.position||"sticky"===r.position)&&!m(this.element)&&this.element.offsetParent&&"BODY"===this.element.offsetParent.tagName&&"hidden"!==getComputedStyle(this.element.offsetParent).overflow&&(this.element.style.top=window.scrollY>parseInt(this.element.style.top,10)?Re(window.scrollY-parseInt(this.element.style.top,10)):Re(parseInt(this.element.style.top,10)-window.scrollY),this.element.style.position="fixed",this.fixedParent=!0),i=i.parentElement,!m(this.element)&&m(this.element.offsetParent)&&"fixed"===r.position&&"fixed"===this.element.style.position&&(this.fixedParent=!0)}},bn([I("auto")],t.prototype,"height",void 0),bn([I("auto")],t.prototype,"width",void 0),bn([I(null)],t.prototype,"content",void 0),bn([I("container")],t.prototype,"targetType",void 0),bn([I(null)],t.prototype,"viewPortElement",void 0),bn([I({X:"none",Y:"none"})],t.prototype,"collision",void 0),bn([I("")],t.prototype,"relateTo",void 0),bn([re({},r4)],t.prototype,"position",void 0),bn([I(0)],t.prototype,"offsetX",void 0),bn([I(0)],t.prototype,"offsetY",void 0),bn([I(1e3)],t.prototype,"zIndex",void 0),bn([I(!1)],t.prototype,"enableRtl",void 0),bn([I("reposition")],t.prototype,"actionOnScroll",void 0),bn([I(null)],t.prototype,"showAnimation",void 0),bn([I(null)],t.prototype,"hideAnimation",void 0),bn([H()],t.prototype,"open",void 0),bn([H()],t.prototype,"close",void 0),bn([H()],t.prototype,"targetExitViewport",void 0),bn([Ft],t)}(yi);function lc(n){for(var t=n.parentElement,e=[];t&&"BODY"!==t.tagName;){var i=document.defaultView.getComputedStyle(t,null).getPropertyValue("z-index"),r=document.defaultView.getComputedStyle(t,null).getPropertyValue("position");"auto"!==i&&"static"!==r&&e.push(i),t=t.parentElement}for(var s=[],o=0;o2147483647?2147483647:c}var _i,Oa,ap,fh,IE,gh,$t,vh,mE=["north-west","north","north-east","west","east","south-west","south","south-east"],_g="e-resize-handle",hc="e-focused-handle",dJ="e-dlg-resizable",n4=["e-restrict-left"],s4="e-resize-viewport",uJ=["north","west","east","south"],yE=0,SE=0,o4=0,a4=0,Ug=0,jg=0,Vg=null,bE=null,ME=null,H0=!0,l4=0,wE=!0;function fJ(n){CE();var t=mi("span",{attrs:{unselectable:"on",contenteditable:"false"}});t.setAttribute("class","e-dialog-border-resize e-"+n),"south"===n&&(t.style.height="2px",t.style.width="100%",t.style.bottom="0px",t.style.left="0px"),"north"===n&&(t.style.height="2px",t.style.width="100%",t.style.top="0px",t.style.left="0px"),"east"===n&&(t.style.height="100%",t.style.width="2px",t.style.right="0px",t.style.top="0px"),"west"===n&&(t.style.height="100%",t.style.width="2px",t.style.left="0px",t.style.top="0px"),_i.appendChild(t)}function h4(n){var t;return m(n)||(t="string"==typeof n?document.querySelector(n):n),t}function c4(n){for(var t=n||this,e=_i.querySelectorAll("."+_g),i=0;i-1?"mouse":"touch"}function u4(n){if(n.preventDefault(),_i=n.target.parentElement,CE(),Ug=n.pageX,jg=n.pageY,n.target.classList.add(hc),m(Vg)||!0!==Vg(n,this)){this.targetEle&&_i&&_i.querySelector("."+dJ)&&($t="body"===this.target?null:this.targetEle,gh=this.targetEle.clientWidth,fh=this.targetEle.clientHeight);var e=m($t)?document:$t;E.add(e,"mousemove",Wg,this),E.add(document,"mouseup",B0,this);for(var i=0;i=0||s.top<0)&&(e=!0):e=!0;var a=SE+(r-jg);a=a>ap?a:ap;var l=0;m($t)||(l=o.top);var h=m($t)?0:$t.offsetHeight-$t.clientHeight,c=s.top-l-h/2;if(c=c<0?0:c,s.top>0&&c+a>fh){if(e=!1,_i.classList.contains(s4))return;_i.style.height=fh-parseInt(c.toString(),10)+"px"}else{var d=0;if(e){s.top<0&&t+(s.height+s.top)>0&&a+(d=s.top)<=30&&(a=s.height-(s.height+s.top)+30),a+s.top>=fh&&(_i.style.height=s.height+(t-(s.height+s.top))+"px");var u=m($t)?d:c;a>=ap&&a+u<=fh&&(_i.style.height=a+"px")}}}function DE(n){var e,t=!1,i="mouse"===d4(n.type)?n.pageY:n.touches[0].pageY,r=cc(_i),s=m($t)?0:$t.offsetHeight-$t.clientHeight;m($t)||(e=cc($t)),(!m($t)&&r.top-e.top>0||m($t)&&i>0||!m($t)&&Math.floor(r.top-e.top+r.height+(e.bottom-r.bottom))-s<=fh)&&(t=!0);var o=SE-(i-jg);if(t&&o>=ap&&o<=fh){var a=0;m($t)||(a=e.top);var l=a4-a+(i-jg);l=l>0?l:1,_i.style.height=o+"px",_i.style.top=l+"px"}}function xE(n){var i,t=document.documentElement.clientWidth,e=!1;m($t)||(i=cc($t));var r="mouse"===d4(n.type)?n.pageX:n.touches[0].pageX,s=cc(_i),o=m($t)?0:$t.offsetWidth-$t.clientWidth,a=m($t)?0:i.left,l=m($t)?0:i.width;m(vh)&&(m($t)?vh=t:(vh=s.left-a-o/2+s.width,vh+=l-o-vh)),(!m($t)&&Math.floor(s.left-i.left+s.width+(i.right-s.right))-o<=gh||m($t)&&r>=0)&&(e=!0);var h=yE-(r-Ug);if(H0&&(h=h>vh?vh:h),e&&h>=IE&&h<=gh){var c=0;m($t)||(c=i.left);var d=o4-c+(r-Ug);d=d>0?d:1,h!==l4&&wE&&(_i.style.width=h+"px"),H0&&(_i.style.left=d+"px",wE=1!==d)}l4=h}function TE(n){var i,t=document.documentElement.clientWidth,e=!1;m($t)||(i=cc($t));var s=(n.touches?n.changedTouches[0]:n).pageX,o=cc(_i);(!m($t)&&(o.left-i.left+o.width<=gh||o.right-i.left>=o.width)||m($t)&&t-s>0)&&(e=!0);var a=yE+(s-Ug),l=0;if(m($t)||(l=i.left),o.left-l+a>gh){if(e=!1,_i.classList.contains(s4))return;_i.style.width=gh-(o.left-l)+"px"}e&&a>=IE&&a<=gh&&(_i.style.width=a+"px")}function f4(){for(var n=_i.querySelectorAll("."+_g),t=0;t=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},SJ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return AE(t,n),Zt([I(!0)],t.prototype,"isFlat",void 0),Zt([I()],t.prototype,"buttonModel",void 0),Zt([I("Button")],t.prototype,"type",void 0),Zt([H()],t.prototype,"click",void 0),t}(Ee),IJ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return AE(t,n),Zt([I("Fade")],t.prototype,"effect",void 0),Zt([I(400)],t.prototype,"duration",void 0),Zt([I(0)],t.prototype,"delay",void 0),t}(Ee),F0="e-dialog",LE="e-rtl",NE="e-dlg-header-content",g4="e-dlg-header",_0="e-footer-content",U0="e-dlg-modal",v4="e-icon-dlg-close",ml="e-dlg-target",ka="e-scroll-disabled",m4="e-device",j0="e-dlg-fullscreen",y4="e-dlg-closeicon-btn",S4="e-popup-open",I4="Information",b4="e-scroll-disabled",M4="e-alert-dialog",w4="e-confirm-dialog",OE="e-dlg-resizable",lp="e-restrict-left",C4="e-resize-viewport",kE="user action",kJ=function(n){function t(e,i){var r=n.call(this,e,i)||this;return r.needsID=!0,r}return AE(t,n),t.prototype.render=function(){this.initialize(),this.initRender(),this.wireEvents(),"100%"===this.width&&(this.element.style.width=""),""!==this.minHeight&&(this.element.style.minHeight=Re(this.minHeight)),this.enableResize&&(this.setResize(),this.isModal&&(this.isModelResize=!0),"None"===this.animationSettings.effect&&this.getMinHeight()),this.renderComplete()},t.prototype.initializeValue=function(){this.dlgClosedBy=kE},t.prototype.preRender=function(){var e=this;if(this.initializeValue(),this.headerContent=null,this.allowMaxHeight=!0,this.preventVisibility=!0,this.clonedEle=this.element.cloneNode(!0),this.closeIconClickEventHandler=function(s){e.dlgClosedBy="close icon",e.hide(s)},this.dlgOverlayClickEventHandler=function(s){e.dlgClosedBy="overlayClick",s.preventFocus=!1,e.trigger("overlayClick",s,function(o){o.preventFocus||e.focusContent(),e.dlgClosedBy=kE})},this.l10n=new ho("dialog",{close:"Close"},this.locale),this.checkPositionData(),m(this.target)){var r=this.isProtectedOnChange;this.isProtectedOnChange=!0,this.target=document.body,this.isProtectedOnChange=r}},t.prototype.updatePersistData=function(){this.enablePersistence&&this.setProperties({width:parseFloat(this.element.style.width),height:parseFloat(this.element.style.height),position:{X:parseFloat(this.dragObj.element.style.left),Y:parseFloat(this.dragObj.element.style.top)}},!0)},t.prototype.isNumberValue=function(e){return/^[-+]?\d*\.?\d+$/.test(e)},t.prototype.checkPositionData=function(){if(!m(this.position)){if(!m(this.position.X)&&"number"!=typeof this.position.X&&this.isNumberValue(this.position.X)){var i=this.isProtectedOnChange;this.isProtectedOnChange=!0,this.position.X=parseFloat(this.position.X),this.isProtectedOnChange=i}m(this.position.Y)||"number"==typeof this.position.Y||this.isNumberValue(this.position.Y)&&(i=this.isProtectedOnChange,this.isProtectedOnChange=!0,this.position.Y=parseFloat(this.position.Y),this.isProtectedOnChange=i)}},t.prototype.getEle=function(e,i){for(var r=void 0,s=0;s=0&&t[e])fJ(t[e]);else if(""!==t[e].trim()){var i=mi("div",{className:"e-icons "+_g+" e-"+t[e]});_i.appendChild(i)}ap=n.minHeight,IE=n.minWidth,gh=n.maxWidth,fh=n.maxHeight,n.proxy&&n.proxy.element&&n.proxy.element.classList.contains("e-dialog")?c4(n.proxy):c4()}({element:this.element,direction:r,minHeight:parseInt(e.slice(0,i.indexOf("p")),10),maxHeight:this.targetEle.clientHeight,minWidth:parseInt(i.slice(0,i.indexOf("p")),10),maxWidth:this.targetEle.clientWidth,boundary:this.target===document.body?null:this.targetEle,resizeBegin:this.onResizeStart.bind(this),resizeComplete:this.onResizeComplete.bind(this),resizing:this.onResizing.bind(this),proxy:this}),this.wireWindowResizeEvent()}else f4(),this.unWireWindowResizeEvent(),this.element.classList.remove(this.isModal?lp:C4),this.element.classList.remove(OE)},t.prototype.getFocusElement=function(e){var r=e.querySelectorAll('input,select,textarea,button:enabled,a,[contenteditable="true"],[tabindex]');return{element:r[r.length-1]}},t.prototype.keyDown=function(e){var i=this;if(9===e.keyCode&&this.isModal){var r=void 0;m(this.btnObj)||(r=this.btnObj[this.btnObj.length-1]),m(this.btnObj)&&!m(this.ftrTemplateContent)&&(r=this.getFocusElement(this.ftrTemplateContent)),m(this.btnObj)&&m(this.ftrTemplateContent)&&!m(this.contentEle)&&(r=this.getFocusElement(this.contentEle)),!m(r)&&document.activeElement===r.element&&!e.shiftKey&&(e.preventDefault(),this.focusableElements(this.element).focus()),document.activeElement===this.focusableElements(this.element)&&e.shiftKey&&(e.preventDefault(),m(r)||r.element.focus())}var h,s=document.activeElement,o=["input","textarea"].indexOf(s.tagName.toLowerCase())>-1,a=!1;if(o||(a=s.hasAttribute("contenteditable")&&"true"===s.getAttribute("contenteditable")),27===e.keyCode&&this.closeOnEscape){this.dlgClosedBy="escape";var l=document.querySelector(".e-popup-open:not(.e-dialog)");!m(l)&&!l.classList.contains("e-toolbar-pop")||this.hide(e)}(13===e.keyCode&&!e.ctrlKey&&"textarea"!==s.tagName.toLowerCase()&&o&&!m(this.primaryButtonEle)||13===e.keyCode&&e.ctrlKey&&("textarea"===s.tagName.toLowerCase()||a)&&!m(this.primaryButtonEle))&&this.buttons.some(function(d,u){h=u;var p=d.buttonModel;return!m(p)&&!0===p.isPrimary})&&"function"==typeof this.buttons[h].click&&setTimeout(function(){i.buttons[h].click.call(i,e)})},t.prototype.initialize=function(){m(this.target)||(this.targetEle="string"==typeof this.target?document.querySelector(this.target):this.target),this.isBlazorServerRender()||V([this.element],F0),X.isDevice&&V([this.element],m4),this.isBlazorServerRender()||this.setCSSClass(),this.setMaxHeight()},t.prototype.initRender=function(){var e=this;if(this.initialRender=!0,this.isBlazorServerRender()||Fe(this.element,{role:"dialog"}),1e3===this.zIndex?(this.setzIndex(this.element,!1),this.calculatezIndex=!0):this.calculatezIndex=!1,this.setTargetContent(),""!==this.header&&!m(this.header)&&this.setHeader(),this.renderCloseIcon(),this.setContent(),""===this.footerTemplate||m(this.footerTemplate)?!m(this.buttons[0])&&!m(this.buttons[0].buttonModel)&&this.setButton():this.setFooterTemplate(),this.allowDragging&&!m(this.headerContent)&&this.setAllowDragging(),Fe(this.element,{"aria-modal":this.isModal?"true":"false"}),this.isModal&&this.setIsModal(),!0!==this.element.classList.contains(M4)&&!0!==this.element.classList.contains(w4)&&!m(this.element.parentElement)){var i=this.isModal?this.dlgContainer.parentElement:this.element.parentElement;this.refElement=this.createElement("div",{className:"e-dlg-ref-element"}),i.insertBefore(this.refElement,this.isModal?this.dlgContainer:this.element)}if(m(this.targetEle)||this.targetEle.appendChild(this.isModal?this.dlgContainer:this.element),this.popupObj=new ac(this.element,{height:this.height,width:this.width,zIndex:this.zIndex,relateTo:this.target,actionOnScroll:"none",enableRtl:this.enableRtl,open:function(o){var a={container:e.isModal?e.dlgContainer:e.element,element:e.element,target:e.target,preventFocus:!1};e.enableResize&&e.resetResizeIcon(),e.trigger("open",a,function(l){l.preventFocus||e.focusContent()})},close:function(o){e.isModal&&V([e.dlgOverlay],"e-fade"),e.unBindEvent(e.element),e.isModal&&(e.dlgContainer.style.display="none"),e.trigger("close",e.closeArgs);var a=document.activeElement;!m(a)&&!m(a.blur)&&a.blur(),!m(e.storeActiveElement)&&!m(e.storeActiveElement.focus)&&e.storeActiveElement.focus()}}),this.positionChange(),this.setEnableRTL(),this.isBlazorServerRender()||(V([this.element],"e-popup-close"),this.isModal&&this.setOverlayZindex()),this.visible){if(this.show(),this.isModal){var r=this.getTargetContainer(this.target);r instanceof Element&&"rtl"===window.getComputedStyle(r).getPropertyValue("direction")&&this.setPopupPosition()}}else this.isModal&&(this.dlgOverlay.style.display="none");this.initialRender=!1},t.prototype.getTargetContainer=function(e){var i=null;if("string"==typeof e)if(e.startsWith("#"))i=document.getElementById(e.substring(1));else if(e.startsWith(".")){var r=document.getElementsByClassName(e.substring(1));i=r.length>0?r[0]:null}else!(e instanceof HTMLElement)&&e!==document.body&&(i=document.querySelector(e));else e instanceof HTMLElement&&(i=e);return i},t.prototype.resetResizeIcon=function(){var e=this.getMinHeight();if(this.targetEle.offsetHeight0&&("function"==typeof this.buttons[e].click&&E.add(s[e],"click",this.buttons[e].click,this),"object"==typeof this.buttons[e].click&&E.add(s[e],"click",this.buttonClickHandler.bind(this,e),this)),!this.isBlazorServerRender()&&!m(this.ftrTemplateContent)&&(this.btnObj[e].appendTo(this.ftrTemplateContent.children[e]),this.buttons[e].isFlat&&this.btnObj[e].element.classList.add("e-flat"),this.primaryButtonEle=this.element.getElementsByClassName("e-primary")[0]))},t.prototype.buttonClickHandler=function(e){this.trigger("buttons["+e+"].click",{})},t.prototype.setContent=function(){this.contentEle=this.createElement("div",{className:"e-dlg-content",id:this.element.id+"_dialog-content"}),Fe(this.element,this.headerEle?{"aria-describedby":this.element.id+"_title "+this.element.id+"_dialog-content"}:{"aria-describedby":this.element.id+"_dialog-content"}),this.innerContentElement?this.contentEle.appendChild(this.innerContentElement):(!m(this.content)&&""!==this.content||!this.initialRender)&&(("string"!=typeof this.content||ce())&&this.content instanceof HTMLElement?this.contentEle.appendChild(this.content):this.setTemplate(this.content,this.contentEle,"content")),m(this.headerContent)?this.element.insertBefore(this.contentEle,this.element.children[0]):this.element.insertBefore(this.contentEle,this.element.children[1]),"auto"===this.height&&(!this.isBlazorServerRender()&&X.isIE&&""===this.element.style.width&&!m(this.width)&&(this.element.style.width=Re(this.width)),this.setMaxHeight())},t.prototype.setTemplate=function(e,i,r){var s,o,a;o=i.classList.contains(g4)?this.element.id+"header":i.classList.contains(_0)?this.element.id+"footerTemplate":this.element.id+"content",m(e.outerHTML)?("string"==typeof e||"string"!=typeof e||ce()&&!this.isStringTemplate)&&("string"==typeof e&&(e=this.sanitizeHelper(e)),this.isVue||"string"!=typeof e?(s=ii(e),a=e):i.innerHTML=e):i.appendChild(e);var l=[];if(!m(s)){for(var c=0,d=s({},this,r,o,!(ce()&&!this.isStringTemplate&&0===a.indexOf("
Blazor"))||this.isStringTemplate);c/g,"");(this.element.children.length>0||i)&&(this.innerContentElement=document.createDocumentFragment(),[].slice.call(this.element.childNodes).forEach(function(r){8!==r.nodeType&&e.innerContentElement.appendChild(r)}))}},t.prototype.setHeader=function(){this.headerEle?this.headerEle.innerHTML="":this.headerEle=this.createElement("div",{id:this.element.id+"_title",className:g4}),this.createHeaderContent(),this.headerContent.appendChild(this.headerEle),this.setTemplate(this.header,this.headerEle,"header"),Fe(this.element,{"aria-describedby":this.element.id+"_title"}),Fe(this.element,{"aria-labelledby":this.element.id+"_dialog-header"}),this.element.insertBefore(this.headerContent,this.element.children[0]),this.allowDragging&&!m(this.headerContent)&&this.setAllowDragging()},t.prototype.setFooterTemplate=function(){this.ftrTemplateContent?this.ftrTemplateContent.innerHTML="":this.ftrTemplateContent=this.createElement("div",{className:_0}),""===this.footerTemplate||m(this.footerTemplate)?this.ftrTemplateContent.innerHTML=this.buttonContent.join(""):this.setTemplate(this.footerTemplate,this.ftrTemplateContent,"footerTemplate"),this.element.appendChild(this.ftrTemplateContent)},t.prototype.createHeaderContent=function(){m(this.headerContent)&&(this.headerContent=this.createElement("div",{id:this.element.id+"_dialog-header",className:NE}))},t.prototype.renderCloseIcon=function(){this.showCloseIcon&&(this.closeIcon=this.createElement("button",{className:y4,attrs:{type:"button"}}),this.closeIconBtnObj=new ys({cssClass:"e-flat",iconCss:v4+" e-icons"}),this.closeIconTitle(),m(this.headerContent)?(this.createHeaderContent(),pl([this.closeIcon],this.headerContent),this.element.insertBefore(this.headerContent,this.element.children[0])):pl([this.closeIcon],this.headerContent),this.closeIconBtnObj.appendTo(this.closeIcon))},t.prototype.closeIconTitle=function(){this.l10n.setLocale(this.locale);var e=this.l10n.getConstant("close");this.closeIcon.setAttribute("title",e),this.closeIcon.setAttribute("aria-label",e)},t.prototype.setCSSClass=function(e){e&&(K([this.element],e.split(" ")),this.isModal&&!m(this.dlgContainer)&&K([this.dlgContainer],e.split(" "))),this.cssClass&&(V([this.element],this.cssClass.split(" ")),this.isModal&&!m(this.dlgContainer)&&V([this.dlgContainer],this.cssClass.split(" ")))},t.prototype.setIsModal=function(){this.dlgContainer=this.createElement("div",{className:"e-dlg-container"}),this.setCSSClass(),this.element.classList.remove(S4),this.element.parentNode.insertBefore(this.dlgContainer,this.element),this.dlgContainer.appendChild(this.element),V([this.element],U0),this.dlgOverlay=this.createElement("div",{className:"e-dlg-overlay"}),this.dlgOverlay.style.zIndex=(this.zIndex-1).toString(),this.dlgContainer.appendChild(this.dlgOverlay)},t.prototype.getValidFocusNode=function(e){for(var i,r=0;r0||"a"===i.tagName.toLowerCase()&&i.hasAttribute("href"))&&i.tabIndex>-1&&!i.disabled&&!this.disableElement(i,'[disabled],[aria-disabled="true"],[type="hidden"]'))return i;i=null}return i},t.prototype.focusableElements=function(e){if(!m(e)){var r=e.querySelectorAll('input,select,textarea,button,a,[contenteditable="true"],[tabindex]');return this.getValidFocusNode(r)}return null},t.prototype.getAutoFocusNode=function(e){var i=e.querySelector("."+y4),s=e.querySelectorAll("[autofocus]"),o=this.getValidFocusNode(s);if(ce()&&(this.primaryButtonEle=this.element.getElementsByClassName("e-primary")[0]),m(o)){if(!m(o=this.focusableElements(this.contentEle)))return o;if(!m(this.primaryButtonEle))return this.element.querySelector(".e-primary")}else i=o;return i},t.prototype.disableElement=function(e,i){var r=e?e.matches||e.webkitMatchesSelector||e.msGetRegionContent:null;if(r)for(;e;e=e.parentNode)if(e instanceof Element&&r.call(e,i))return e;return null},t.prototype.focusContent=function(){var e=this.getAutoFocusNode(this.element),i=m(e)?this.element:e,r=X.userAgent;(r.indexOf("MSIE ")>0||r.indexOf("Trident/")>0)&&this.element.focus(),i.focus(),this.unBindEvent(this.element),this.bindEvent(this.element)},t.prototype.bindEvent=function(e){E.add(e,"keydown",this.keyDown,this)},t.prototype.unBindEvent=function(e){E.remove(e,"keydown",this.keyDown)},t.prototype.updateSanitizeContent=function(){this.isBlazorServerRender()||(this.contentEle.innerHTML=this.sanitizeHelper(this.content))},t.prototype.isBlazorServerRender=function(){return ce()&&this.isServerRendered},t.prototype.getModuleName=function(){return"dialog"},t.prototype.onPropertyChanged=function(e,i){if(this.element.classList.contains(F0))for(var r=0,s=Object.keys(e);r0?this.showCloseIcon||""!==this.header&&!m(this.header)?this.showCloseIcon||he(this.closeIcon):(he(this.headerContent),this.headerContent=null):(this.renderCloseIcon(),this.wireEvents());break;case"locale":this.showCloseIcon&&this.closeIconTitle();break;case"visible":this.visible?this.show():this.hide();break;case"isModal":this.updateIsModal();break;case"height":je(this.element,{height:Re(e.height)}),this.updatePersistData();break;case"width":je(this.element,{width:Re(e.width)}),this.updatePersistData();break;case"zIndex":this.popupObj.zIndex=this.zIndex,this.isModal&&this.setOverlayZindex(this.zIndex),this.element.style.zIndex!==this.zIndex.toString()&&(this.calculatezIndex=!1);break;case"cssClass":this.setCSSClass(i.cssClass);break;case"buttons":this.unWireButtonEvents(),this.destroyButtons(),m(this.ftrTemplateContent)||(he(this.ftrTemplateContent),this.ftrTemplateContent=null),this.footerTemplate="",this.setButton();break;case"allowDragging":this.allowDragging&&!m(this.headerContent)?this.setAllowDragging():this.dragObj.destroy();break;case"target":this.setTarget(e.target);break;case"position":if(this.checkPositionData(),this.isModal){var a=this.position.X,l=this.position.Y;m(i.position)||(m(i.position.X)||(a=i.position.X),m(i.position.Y)||(l=i.position.Y)),this.dlgContainer.classList.contains("e-dlg-"+a+"-"+l)&&this.dlgContainer.classList.remove("e-dlg-"+a+"-"+l)}this.positionChange(),this.updatePersistData();break;case"enableRtl":this.setEnableRTL();break;case"enableResize":this.setResize();break;case"minHeight":""!==this.minHeight&&(this.element.style.minHeight=Re(this.minHeight))}},t.prototype.setTarget=function(e){this.popupObj.relateTo=e,this.target=e,this.targetEle="string"==typeof this.target?document.querySelector(this.target):this.target,this.dragObj&&(this.dragObj.dragArea=this.targetEle),this.setMaxHeight(),this.isModal&&this.updateIsModal(),this.enableResize&&this.setResize()},t.prototype.updateIsModal=function(){if(this.element.setAttribute("aria-modal",this.isModal?"true":"false"),this.isModal)m(this.dlgOverlay)&&(this.setIsModal(),this.element.style.top="0px",this.element.style.left="0px",m(this.targetEle)||this.targetEle.appendChild(this.dlgContainer));else{for(K([this.element],U0),K([document.body],[ml,ka]),he(this.dlgOverlay);this.dlgContainer.firstChild;)this.dlgContainer.parentElement.insertBefore(this.dlgContainer.firstChild,this.dlgContainer);this.dlgContainer.parentElement.removeChild(this.dlgContainer)}this.visible&&this.show(),this.positionChange(),this.isModal&&this.dlgOverlay&&E.add(this.dlgOverlay,"click",this.dlgOverlayClickEventHandler,this)},t.prototype.setzIndex=function(e,i){var r=this.isProtectedOnChange;this.isProtectedOnChange=!0;var s=lc(e);this.zIndex=s>this.zIndex?s:this.zIndex,this.isProtectedOnChange=r,i&&(this.popupObj.zIndex=this.zIndex)},t.prototype.windowResizeHandler=function(){(function vJ(n){gh=n})(this.targetEle.clientWidth),function mJ(n){fh=n}(this.targetEle.clientHeight),this.setMaxHeight()},t.prototype.getPersistData=function(){return this.addOnPersist(["width","height","position"])},t.prototype.removeAllChildren=function(e){for(;e.children[0];)this.removeAllChildren(e.children[0]),e.removeChild(e.children[0])},t.prototype.destroy=function(){if(!this.isDestroyed){var e=[LE,U0,OE,lp,j0,m4],i=["role","aria-modal","aria-labelledby","aria-describedby","aria-grabbed","tabindex","style"];K([this.targetEle],[ml,ka]),!m(this.element)&&this.element.classList.contains(j0)&&K([document.body],[ml,ka]),this.isModal&&K([m(this.targetEle)?document.body:this.targetEle],ka),this.unWireEvents(),this.unWireButtonEvents(),this.destroyButtons(),m(this.closeIconBtnObj)||this.closeIconBtnObj.destroy(),m(this.dragObj)||this.dragObj.destroy(),!m(this.popupObj.element)&&this.popupObj.element.classList.contains("e-popup")&&this.popupObj.destroy(),K([this.element],e),!m(this.cssClass)&&""!==this.cssClass&&K([this.element],this.cssClass.split(" ")),!m(this.refElement)&&!m(this.refElement.parentElement)&&(this.refElement.parentElement.insertBefore(this.isModal?this.dlgContainer:this.element,this.refElement),he(this.refElement),this.refElement=void 0),this.isModal&&(he(this.dlgOverlay),this.dlgContainer.parentNode.insertBefore(this.element,this.dlgContainer),he(this.dlgContainer)),this.element.innerHTML=this.clonedEle.innerHTML;for(var r=0;r0&&""===this.footerTemplate&&this.ftrTemplateContent)for(var e=0;e=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},PE="e-tooltip",L4="e-icons",N4="e-tooltip-close",zE="e-tooltip-wrap",O4="e-tip-content",hp="e-arrow-tip",k4="e-arrow-tip-outer",V0="e-arrow-tip-inner",Yg="e-tip-bottom",RE="e-tip-top",P4="e-tip-left",HE="e-tip-right",BE="e-popup",Qg="e-popup-open",FE="e-popup-close",W0="e-lib",z4="e-tooltip-popup-container",FJ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return D4(t,n),Gi([I({effect:"FadeIn",duration:150,delay:0})],t.prototype,"open",void 0),Gi([I({effect:"FadeOut",duration:150,delay:0})],t.prototype,"close",void 0),t}(Ee),mh=function(n){function t(e,i){var r=n.call(this,e,i)||this;return r.mouseMoveEvent=null,r.mouseMoveTarget=null,r.containerElement=null,r.isBodyContainer=!0,r}return D4(t,n),t.prototype.initialize=function(){this.formatPosition(),V([this.element],PE)},t.prototype.formatPosition=function(){var e,i;this.position&&(0===this.position.indexOf("Top")||0===this.position.indexOf("Bottom")?(e=this.position.split(/(?=[A-Z])/),this.tooltipPositionY=e[0],this.tooltipPositionX=e[1]):(i=this.position.split(/(?=[A-Z])/),this.tooltipPositionX=i[0],this.tooltipPositionY=i[1]))},t.prototype.renderArrow=function(){this.setTipClass(this.position);var e=this.createElement("div",{className:hp+" "+this.tipClass});e.appendChild(this.createElement("div",{className:k4+" "+this.tipClass})),e.appendChild(this.createElement("div",{className:V0+" "+this.tipClass})),this.tooltipEle.appendChild(e)},t.prototype.setTipClass=function(e){this.tipClass=0===e.indexOf("Right")?P4:0===e.indexOf("Bottom")?RE:0===e.indexOf("Left")?HE:Yg},t.prototype.renderPopup=function(e){var i=this.mouseTrail?{top:0,left:0}:this.getTooltipPosition(e);this.tooltipEle.classList.remove(W0),this.popupObj=new ac(this.tooltipEle,{height:this.height,width:this.width,position:{X:i.left,Y:i.top},enableRtl:this.enableRtl,open:this.openPopupHandler.bind(this),close:this.closePopupHandler.bind(this)})},t.prototype.getScalingFactor=function(e){if(!e)return{x:1,y:1};var i={x:1,y:1},r=e.closest('[style*="transform: scale"]');if(r&&r!==this.tooltipEle&&r.contains(this.tooltipEle)){var a=window.getComputedStyle(r).getPropertyValue("transform").match(/matrix\(([^)]+)\)/)[1].split(",").map(parseFloat);i.x=a[0],i.y=a[3]}return i},t.prototype.getTooltipPosition=function(e){this.tooltipEle.style.display="block";var i=this.element.closest('[style*="zoom"]');i&&(i.contains(this.tooltipEle)||(this.tooltipEle.style.zoom=getComputedStyle(i).zoom));var r=is(e,this.tooltipPositionX,this.tooltipPositionY,!this.isBodyContainer,this.isBodyContainer?null:this.containerElement.getBoundingClientRect()),s=this.getScalingFactor(e),o=this.calculateTooltipOffset(this.position,s.x,s.y),a=this.calculateElementPosition(r,o),c=this.collisionFlipFit(e,a[0],a[1]);return c.left=c.left/s.x,c.top=c.top/s.y,this.tooltipEle.style.display="",c},t.prototype.windowResize=function(){this.reposition(this.findTarget())},t.prototype.reposition=function(e){if(this.popupObj&&e){var i=this.getTooltipPosition(e);this.popupObj.position={X:i.left,Y:i.top},this.popupObj.dataBind()}},t.prototype.openPopupHandler=function(){!this.mouseTrail&&this.needTemplateReposition()&&this.reposition(this.findTarget()),this.trigger("afterOpen",this.tooltipEventArgs),this.tooltipEventArgs=null},t.prototype.closePopupHandler=function(){this.isReact&&!("Click"===this.opensOn||"function"==typeof this.content)&&this.clearTemplate(["content"]),this.clear();var e={type:this.tooltipEventArgs.event?this.tooltipEventArgs.event.type:null,cancel:!1,target:this.tooltipEventArgs.target,event:this.tooltipEventArgs.event?this.tooltipEventArgs.event:null,element:this.tooltipEle,isInteracted:!m(this.tooltipEventArgs.event)};this.trigger("afterClose",e),e=null},t.prototype.calculateTooltipOffset=function(e,i,r){void 0===i&&(i=1),void 0===r&&(r=1);var o,a,l,h,c,d,u,p,s={top:0,left:0};if(1!==i||1!==r){var f=this.tooltipEle.getBoundingClientRect(),g=void 0;l=Math.round(f.width),h=Math.round(f.height),(c=U("."+hp,this.tooltipEle))&&(g=c.getBoundingClientRect()),o=c?Math.round(g.width):0,a=c?Math.round(g.height):0,d=this.showTipPointer?0:8,u=a/2+2+(h-this.tooltipEle.clientHeight*r),p=o/2+2+(l-this.tooltipEle.clientWidth*i)}else l=this.tooltipEle.offsetWidth,h=this.tooltipEle.offsetHeight,c=U("."+hp,this.tooltipEle),d=this.showTipPointer?0:8,u=(a=c?c.offsetHeight:0)/2+2+(this.tooltipEle.offsetHeight-this.tooltipEle.clientHeight),p=(o=c?c.offsetWidth:0)/2+2+(this.tooltipEle.offsetWidth-this.tooltipEle.clientWidth);switch(this.mouseTrail&&(d+=2),e){case"RightTop":s.left+=o+d,s.top-=h-u;break;case"RightCenter":s.left+=o+d,s.top-=h/2;break;case"RightBottom":s.left+=o+d,s.top-=u;break;case"BottomRight":s.top+=a+d,s.left-=p;break;case"BottomCenter":s.top+=a+d,s.left-=l/2;break;case"BottomLeft":s.top+=a+d,s.left-=l-p;break;case"LeftBottom":s.left-=o+l+d,s.top-=u;break;case"LeftCenter":s.left-=o+l+d,s.top-=h/2;break;case"LeftTop":s.left-=o+l+d,s.top-=h-u;break;case"TopLeft":s.top-=h+a+d,s.left-=l-p;break;case"TopRight":s.top-=h+a+d,s.left-=p;break;default:s.top-=h+a+d,s.left-=l/2}return s.left+=this.offsetX,s.top+=this.offsetY,s},t.prototype.updateTipPosition=function(e){var i=we("."+hp+",."+k4+",."+V0,this.tooltipEle);K(i,[Yg,RE,P4,HE]),this.setTipClass(e),V(i,this.tipClass)},t.prototype.adjustArrow=function(e,i,r,s){var o=U("."+hp,this.tooltipEle);if(!1!==this.showTipPointer&&null!==o){var a,l;this.updateTipPosition(i),this.tooltipEle.style.display="block";var f,h=this.tooltipEle.clientWidth,c=this.tooltipEle.clientHeight,d=U("."+V0,this.tooltipEle),u=o.offsetWidth,p=o.offsetHeight;this.tooltipEle.style.display="",this.tipClass===Yg||this.tipClass===RE?(this.tipClass===Yg?(l="99.9%",d.style.top="-"+(p-2)+"px"):(l=-(p-1)+"px",d.style.top="-"+(p-6)+"px"),e&&(a=(f="Center"!==r||h>e.offsetWidth||this.mouseTrail)&&"Left"===r||!f&&"End"===this.tipPointerPosition?h-u-2+"px":f&&"Right"===r||!f&&"Start"===this.tipPointerPosition?"2px":!f||"End"!==this.tipPointerPosition&&"Start"!==this.tipPointerPosition?h/2-u/2+"px":"End"===this.tipPointerPosition?e.offsetWidth+(this.tooltipEle.offsetWidth-e.offsetWidth)/2-u/2-2+"px":(this.tooltipEle.offsetWidth-e.offsetWidth)/2-u/2+2+"px")):(this.tipClass===HE?(a="99.9%",d.style.left="-"+(u-2)+"px"):(a=-(u-1)+"px",d.style.left=u-2-u+"px"),l=(f="Center"!==s||c>e.offsetHeight||this.mouseTrail)&&"Top"===s||!f&&"End"===this.tipPointerPosition?c-p-2+"px":f&&"Bottom"===s||!f&&"Start"===this.tipPointerPosition?"2px":c/2-p/2+"px"),o.style.top=l,o.style.left=a}},t.prototype.renderContent=function(e){var i=this,r=U("."+O4,this.tooltipEle);if(this.cssClass&&V([this.tooltipEle],this.cssClass.split(" ")),e&&!m(e.getAttribute("title"))&&(e.setAttribute("data-content",e.getAttribute("title")),e.removeAttribute("title")),m(this.content))e&&!m(e.getAttribute("data-content"))&&(r.innerHTML=e.getAttribute("data-content"));else if(r.innerHTML="",this.content instanceof HTMLElement)r.appendChild(this.content);else if("string"==typeof this.content)this.isAngular?this.setProperties({content:Ti.sanitize(this.content)},!0):this.content=this.enableHtmlSanitizer?Ti.sanitize(this.content):this.content,this.enableHtmlParse?(o=ii(this.content)({},this,"content",this.element.id+"content",void 0,void 0,r,this.root))&&Dt(o,r):r.textContent=this.content;else{var o;(o=ii(this.content)({},this,"content",this.element.id+"content",void 0,void 0,r))&&(this.isAngular&&setTimeout(function(){i.reposition(e)},1),Dt(o,r)),this.renderReactTemplates()}},t.prototype.renderCloseIcon=function(){if(this.isSticky){var i=this.createElement("div",{className:L4+" "+N4});this.tooltipEle.appendChild(i),E.add(i,X.touchStartEvent,this.onStickyClose,this)}else{var e=this.tooltipEle.querySelector("."+L4+"."+N4);e&>(e)}},t.prototype.addDescribedBy=function(e,i){var r=(e.getAttribute("aria-describedby")||"").split(/\s+/);r.indexOf(i)<0&&r.push(i),Fe(e,{"aria-describedby":r.join(" ").trim(),"data-tooltip-id":i})},t.prototype.removeDescribedBy=function(e){var i=e.getAttribute("data-tooltip-id"),r=(e.getAttribute("aria-describedby")||"").split(/\s+/),s=r.indexOf(i);-1!==s&&r.splice(s,1),e.removeAttribute("data-tooltip-id");var o=r.join(" ").trim();o?e.setAttribute("aria-describedby",o):e.removeAttribute("aria-describedby")},t.prototype.tapHoldHandler=function(e){clearTimeout(this.autoCloseTimer),this.targetHover(e.originalEvent)},t.prototype.touchEndHandler=function(){var e=this;this.isSticky||(this.autoCloseTimer=setTimeout(function(){e.close()},1500))},t.prototype.targetClick=function(e){var i;!m(i=this.target?J(e.target,this.target):this.element)&&(null===i.getAttribute("data-tooltip-id")?this.targetHover(e):this.isSticky||this.hideTooltip(this.animation.close,e,i))},t.prototype.targetHover=function(e){var i;if(!(m(i=this.target?J(e.target,this.target):this.element)||null!==i.getAttribute("data-tooltip-id")&&0===this.closeDelay)){for(var s=0,o=[].slice.call(we('[data-tooltip-id= "'+this.ctrlId+'_content"]',document));s0?this.showTimer=setTimeout(function(){o.mouseTrail&&E.add(i,"mousemove touchstart mouseenter",o.onMouseMove,o),o.popupObj&&(o.popupObj.show(a,i),o.mouseMoveEvent&&o.mouseTrail&&o.onMouseMove(o.mouseMoveEvent))},this.openDelay):this.popupObj&&this.popupObj.show(a,i)}s&&this.wireMouseEvents(s,i)},t.prototype.needTemplateReposition=function(){return!m(this.viewContainerRef)&&"string"!=typeof this.viewContainerRef||this.isReact},t.prototype.checkCollision=function(e,i,r){var s={left:i,top:r,position:this.position,horizontal:this.tooltipPositionX,vertical:this.tooltipPositionY},o=oc(this.tooltipEle,this.checkCollideTarget(),i,r);return o.length>0&&(s.horizontal=o.indexOf("left")>=0?"Right":o.indexOf("right")>=0?"Left":this.tooltipPositionX,s.vertical=o.indexOf("top")>=0?"Bottom":o.indexOf("bottom")>=0?"Top":this.tooltipPositionY),s},t.prototype.calculateElementPosition=function(e,i){return[this.isBodyContainer?e.left+i.left:e.left-this.containerElement.getBoundingClientRect().left+i.left+window.pageXOffset+this.containerElement.scrollLeft,this.isBodyContainer?e.top+i.top:e.top-this.containerElement.getBoundingClientRect().top+i.top+window.pageYOffset+this.containerElement.scrollTop]},t.prototype.collisionFlipFit=function(e,i,r){var s=this.checkCollision(e,i,r),o=s.position;if(this.tooltipPositionY!==s.vertical&&(o=0===this.position.indexOf("Bottom")||0===this.position.indexOf("Top")?s.vertical+this.tooltipPositionX:this.tooltipPositionX+s.vertical),this.tooltipPositionX!==s.horizontal&&(0===o.indexOf("Left")&&(s.vertical="LeftTop"===o||"LeftCenter"===o?"Top":"Bottom",o=s.vertical+"Left"),0===o.indexOf("Right")&&(s.vertical="RightTop"===o||"RightCenter"===o?"Top":"Bottom",o=s.vertical+"Right"),s.horizontal=this.tooltipPositionX),this.tooltipEventArgs={type:null,cancel:!1,target:e,event:null,element:this.tooltipEle,collidedPosition:o},this.trigger("beforeCollision",this.tooltipEventArgs),this.tooltipEventArgs.cancel)o=this.position;else{var a=s.vertical,l=s.horizontal;if(s.position!==o){var h=is(e,l,a,!this.isBodyContainer,this.isBodyContainer?null:this.containerElement.getBoundingClientRect());this.adjustArrow(e,o,l,a);var c=this.getScalingFactor(e),d=this.calculateTooltipOffset(o,c.x,c.y);d.top-=this.getOffSetPosition("TopBottom",o,this.offsetY),d.left-=this.getOffSetPosition("RightLeft",o,this.offsetX),s.position=o;var u=this.calculateElementPosition(h,d);s.left=u[0],s.top=u[1]}else this.adjustArrow(e,o,l,a)}var p={left:s.left,top:s.top},f=this.isBodyContainer?lE(this.tooltipEle,this.checkCollideTarget(),{X:!0,Y:this.windowCollision},p):p;this.tooltipEle.style.display="block";var g=U("."+hp,this.tooltipEle);if(this.showTipPointer&&null!=g&&(0===o.indexOf("Bottom")||0===o.indexOf("Top"))){var v=parseInt(g.style.left,10)-(f.left-s.left);v<0?v=0:v+g.offsetWidth>this.tooltipEle.clientWidth&&(v=this.tooltipEle.clientWidth-g.offsetWidth),g.style.left=v.toString()+"px"}return this.tooltipEle.style.display="",p.left=f.left,p.top=f.top,p},t.prototype.getOffSetPosition=function(e,i,r){return-1!==e.indexOf(this.position.split(/(?=[A-Z])/)[0])&&-1!==e.indexOf(i.split(/(?=[A-Z])/)[0])?2*r:0},t.prototype.checkCollideTarget=function(){return!this.windowCollision&&this.target?this.element:null},t.prototype.hideTooltip=function(e,i,r){var s=this;this.closeDelay>0?(clearTimeout(this.hideTimer),clearTimeout(this.showTimer),this.hideTimer=setTimeout(function(){s.closeDelay&&s.tooltipEle&&s.isTooltipOpen||s.tooltipHide(e,i,r)},this.closeDelay)):this.tooltipHide(e,i,r)},t.prototype.tooltipHide=function(e,i,r){var o,s=this;o=i?this.target?r||i.target:this.element:U('[data-tooltip-id= "'+this.ctrlId+'_content"]',document),this.tooltipEventArgs={type:i?i.type:null,cancel:!1,target:o,event:i||null,element:this.tooltipEle,isInteracted:!m(i)},this.trigger("beforeClose",this.tooltipEventArgs,function(a){a.cancel?s.isHidden=!1:(s.mouseMoveBeforeRemove(),s.popupHide(e,o,i))})},t.prototype.popupHide=function(e,i,r){i&&r&&this.restoreElement(i),this.isHidden=!0;var s={name:this.animation.close.effect,duration:e.duration,delay:e.delay,timingFunction:"easeIn"};"None"===e.effect&&(s=void 0),this.popupObj&&this.popupObj.hide(s)},t.prototype.restoreElement=function(e){this.unwireMouseEvents(e),m(e.getAttribute("data-content"))||(e.setAttribute("title",e.getAttribute("data-content")),e.removeAttribute("data-content")),this.removeDescribedBy(e)},t.prototype.clear=function(){var e=this.findTarget();e&&this.restoreElement(e),this.tooltipEle&&(K([this.tooltipEle],FE),V([this.tooltipEle],Qg)),this.isHidden&&(this.popupObj&&this.popupObj.destroy(),this.tooltipEle&>(this.tooltipEle),this.tooltipEle=null,this.popupObj=null)},t.prototype.tooltipHover=function(){this.tooltipEle&&(this.isTooltipOpen=!0)},t.prototype.tooltipMouseOut=function(e){this.isTooltipOpen=!1,this.hideTooltip(this.animation.close,e,this.findTarget())},t.prototype.onMouseOut=function(e){var i=e.relatedTarget;if(i&&!this.mouseTrail){var r=J(i,"."+zE+"."+W0+"."+BE);r?E.add(r,"mouseleave",this.tooltipElementMouseOut,this):(this.hideTooltip(this.animation.close,e,this.findTarget()),0===this.closeDelay&&("None"===this.animation.close.effect||this.isReact&&"string"!=typeof this.content)&&this.clear())}else this.hideTooltip(this.animation.close,e,this.findTarget()),this.clear();this.popupObj&&!this.popupObj.element.classList.contains(Qg)&&this.clear()},t.prototype.tooltipElementMouseOut=function(e){this.hideTooltip(this.animation.close,e,this.findTarget()),E.remove(this.element,"mouseleave",this.tooltipElementMouseOut),this.clear()},t.prototype.onStickyClose=function(){this.close()},t.prototype.onMouseMove=function(e){var i=0,r=0;e.type.indexOf("touch")>-1?(e.preventDefault(),i=e.touches[0].pageX,r=e.touches[0].pageY):(i=e.pageX,r=e.pageY),Hs.stop(this.tooltipEle),K([this.tooltipEle],FE),V([this.tooltipEle],Qg),this.adjustArrow(e.target,this.position,this.tooltipPositionX,this.tooltipPositionY);var s=this.getScalingFactor(e.target),o=this.calculateTooltipOffset(this.position,s.x,s.y),h=this.checkCollision(e.target,i+o.left+this.offsetX,r+o.top+this.offsetY);if(this.tooltipPositionX!==h.horizontal||this.tooltipPositionY!==h.vertical){var c=0===this.position.indexOf("Bottom")||0===this.position.indexOf("Top")?h.vertical+h.horizontal:h.horizontal+h.vertical;h.position=c,this.adjustArrow(e.target,h.position,h.horizontal,h.vertical);var d=this.calculateTooltipOffset(h.position,s.x,s.y);h.left=i+d.left-this.offsetX,h.top=r+d.top-this.offsetY}this.tooltipEle.style.left=h.left+"px",this.tooltipEle.style.top=h.top+"px"},t.prototype.keyDown=function(e){this.tooltipEle&&27===e.keyCode&&this.close()},t.prototype.touchEnd=function(e){this.tooltipEle&&null===J(e.target,"."+PE)&&!this.isSticky&&this.close()},t.prototype.scrollHandler=function(e){this.tooltipEle&&!this.isSticky&&!J(e.target,"."+zE+"."+W0+"."+BE)&&!this.isSticky&&this.close()},t.prototype.render=function(){this.initialize(),this.wireEvents(this.opensOn),this.renderComplete()},t.prototype.preRender=function(){this.tipClass=Yg,this.tooltipPositionX="Center",this.tooltipPositionY="Top",this.isHidden=!0},t.prototype.wireEvents=function(e){for(var r=0,s=this.getTriggerList(e);r0)for(var i=0,r=e;i0)for(var i=0,r=e;i0&&this.condition&&-1!==this.condition.indexOf("not")&&(e[s].condition=e[s].condition?e[s].condition+"not":"not"),i=e[s].validate(t),r){if(!i)return!1}else if(i)return!0;return r},n.prototype.toJson=function(){var t,e;if(this.isComplex){t=[],e=this.predicates;for(var i=0;ie.length-3?(e=e.substring(0,e.length-1),n.endsWith(n.toLowerCase(t),n.toLowerCase(e))):(e.lastIndexOf("%")!==e.indexOf("%")&&e.lastIndexOf("%")>e.indexOf("%")+1&&(e=e.substring(e.indexOf("%")+1,e.lastIndexOf("%"))),-1!==t.indexOf(e)))},n.fnSort=function(t){return"ascending"===(t=t?n.toLowerCase(t):"ascending")?this.fnAscending:this.fnDescending},n.fnAscending=function(t,e){return m(t)&&m(e)||null==e?-1:"string"==typeof t?t.localeCompare(e):null==t?1:t-e},n.fnDescending=function(t,e){return m(t)&&m(e)?-1:null==e?1:"string"==typeof t?-1*t.localeCompare(e):null==t?-1:e-t},n.extractFields=function(t,e){for(var i={},r=0;r0||e.length>0;)o=t.length>0&&e.length>0?r?r(this.getVal(t,0,i),this.getVal(e,0,i),t[0],e[0])<=0?t:e:t[0][i]0?t:e,s.push(o.shift());return s},n.getVal=function(t,e,i){return i?this.getObject(i,t[e]):t[e]},n.toLowerCase=function(t){return t?"string"==typeof t?t.toLowerCase():t.toString():0===t||!1===t?t.toString():""},n.callAdaptorFunction=function(t,e,i,r){if(e in t){var s=t[e](i,r);m(s)||(i=s)}return i},n.getAddParams=function(t,e,i){var r={};return n.callAdaptorFunction(t,"addParams",{dm:e,query:i,params:i?i.params:[],reqParams:r}),r},n.isPlainObject=function(t){return!!t&&t.constructor===Object},n.isCors=function(){var t=null;try{t=new window.XMLHttpRequest}catch{}return!!t&&"withCredentials"in t},n.getGuid=function(t){var i;return(t||"")+"00000000-0000-4000-0000-000000000000".replace(/0/g,function(r,s){if("crypto"in window&&"getRandomValues"in crypto){var o=new Uint8Array(1);window.crypto.getRandomValues(o),i=o[0]%16|0}else i=16*Math.random()|0;return"0123456789abcdef"[19===s?3&i|8:i]})},n.isNull=function(t){return null==t},n.getItemFromComparer=function(t,e,i){var r,s,o,a=0,l="string"==typeof n.getVal(t,0,e);if(t.length)for(;m(r)&&a0&&(r=s,o=t[a]));return o},n.distinct=function(t,e,i){i=!m(i)&&i;var s,r=[],o={};return t.forEach(function(a,l){(s="object"==typeof t[l]?n.getVal(t,l,e):t[l])in o||(r.push(i?t[l]:s),o[s]=1)}),r},n.processData=function(t,e){var i=this.prepareQuery(t),r=new nt(e);t.requiresCounts&&i.requiresCount();var s=r.executeLocal(i),o={result:t.requiresCounts?s.result:s,count:s.count,aggregates:JSON.stringify(s.aggregates)};return t.requiresCounts?o:s},n.prepareQuery=function(t){var e=this,i=new _t;return t.select&&i.select(t.select),t.where&&n.parse.parseJson(t.where).filter(function(o){if(m(o.condition))i.where(o.field,o.operator,o.value,o.ignoreCase,o.ignoreAccent);else{var a=[];o.field?a.push(new Ss(o.field,o.operator,o.value,o.ignoreCase,o.ignoreAccent)):a=a.concat(e.getPredicate(o.predicates)),"or"===o.condition?i.where(Ss.or(a)):"and"===o.condition&&i.where(Ss.and(a))}}),t.search&&n.parse.parseJson(t.search).filter(function(o){return i.search(o.key,o.fields,o.operator,o.ignoreCase,o.ignoreAccent)}),t.aggregates&&t.aggregates.filter(function(o){return i.aggregate(o.type,o.field)}),t.sorted&&t.sorted.filter(function(o){return i.sortBy(o.name,o.direction)}),t.skip&&i.skip(t.skip),t.take&&i.take(t.take),t.group&&t.group.filter(function(o){return i.group(o)}),i},n.getPredicate=function(t){for(var e=[],i=0;i":"greaterthan","<=":"lessthanorequal",">=":"greaterthanorequal","==":"equal","!=":"notequal","*=":"contains","$=":"endswith","^=":"startswith"},n.odBiOperator={"<":" lt ",">":" gt ","<=":" le ",">=":" ge ","==":" eq ","!=":" ne ",lessthan:" lt ",lessthanorequal:" le ",greaterthan:" gt ",greaterthanorequal:" ge ",equal:" eq ",notequal:" ne "},n.odUniOperator={"$=":"endswith","^=":"startswith","*=":"substringof",endswith:"endswith",startswith:"startswith",contains:"substringof",doesnotendwith:"not endswith",doesnotstartwith:"not startswith",doesnotcontain:"not substringof",wildcard:"wildcard",like:"like"},n.odv4UniOperator={"$=":"endswith","^=":"startswith","*=":"contains",endswith:"endswith",startswith:"startswith",contains:"contains",doesnotendwith:"not endswith",doesnotstartwith:"not startswith",doesnotcontain:"not contains",wildcard:"wildcard",like:"like"},n.diacritics={"\u24b6":"A",\uff21:"A",\u00c0:"A",\u00c1:"A",\u00c2:"A",\u1ea6:"A",\u1ea4:"A",\u1eaa:"A",\u1ea8:"A",\u00c3:"A",\u0100:"A",\u0102:"A",\u1eb0:"A",\u1eae:"A",\u1eb4:"A",\u1eb2:"A",\u0226:"A",\u01e0:"A",\u00c4:"A",\u01de:"A",\u1ea2:"A",\u00c5:"A",\u01fa:"A",\u01cd:"A",\u0200:"A",\u0202:"A",\u1ea0:"A",\u1eac:"A",\u1eb6:"A",\u1e00:"A",\u0104:"A",\u023a:"A",\u2c6f:"A",\ua732:"AA",\u00c6:"AE",\u01fc:"AE",\u01e2:"AE",\ua734:"AO",\ua736:"AU",\ua738:"AV",\ua73a:"AV",\ua73c:"AY","\u24b7":"B",\uff22:"B",\u1e02:"B",\u1e04:"B",\u1e06:"B",\u0243:"B",\u0182:"B",\u0181:"B","\u24b8":"C",\uff23:"C",\u0106:"C",\u0108:"C",\u010a:"C",\u010c:"C",\u00c7:"C",\u1e08:"C",\u0187:"C",\u023b:"C",\ua73e:"C","\u24b9":"D",\uff24:"D",\u1e0a:"D",\u010e:"D",\u1e0c:"D",\u1e10:"D",\u1e12:"D",\u1e0e:"D",\u0110:"D",\u018b:"D",\u018a:"D",\u0189:"D",\ua779:"D",\u01f1:"DZ",\u01c4:"DZ",\u01f2:"Dz",\u01c5:"Dz","\u24ba":"E",\uff25:"E",\u00c8:"E",\u00c9:"E",\u00ca:"E",\u1ec0:"E",\u1ebe:"E",\u1ec4:"E",\u1ec2:"E",\u1ebc:"E",\u0112:"E",\u1e14:"E",\u1e16:"E",\u0114:"E",\u0116:"E",\u00cb:"E",\u1eba:"E",\u011a:"E",\u0204:"E",\u0206:"E",\u1eb8:"E",\u1ec6:"E",\u0228:"E",\u1e1c:"E",\u0118:"E",\u1e18:"E",\u1e1a:"E",\u0190:"E",\u018e:"E","\u24bb":"F",\uff26:"F",\u1e1e:"F",\u0191:"F",\ua77b:"F","\u24bc":"G",\uff27:"G",\u01f4:"G",\u011c:"G",\u1e20:"G",\u011e:"G",\u0120:"G",\u01e6:"G",\u0122:"G",\u01e4:"G",\u0193:"G",\ua7a0:"G",\ua77d:"G",\ua77e:"G","\u24bd":"H",\uff28:"H",\u0124:"H",\u1e22:"H",\u1e26:"H",\u021e:"H",\u1e24:"H",\u1e28:"H",\u1e2a:"H",\u0126:"H",\u2c67:"H",\u2c75:"H",\ua78d:"H","\u24be":"I",\uff29:"I",\u00cc:"I",\u00cd:"I",\u00ce:"I",\u0128:"I",\u012a:"I",\u012c:"I",\u0130:"I",\u00cf:"I",\u1e2e:"I",\u1ec8:"I",\u01cf:"I",\u0208:"I",\u020a:"I",\u1eca:"I",\u012e:"I",\u1e2c:"I",\u0197:"I","\u24bf":"J",\uff2a:"J",\u0134:"J",\u0248:"J","\u24c0":"K",\uff2b:"K",\u1e30:"K",\u01e8:"K",\u1e32:"K",\u0136:"K",\u1e34:"K",\u0198:"K",\u2c69:"K",\ua740:"K",\ua742:"K",\ua744:"K",\ua7a2:"K","\u24c1":"L",\uff2c:"L",\u013f:"L",\u0139:"L",\u013d:"L",\u1e36:"L",\u1e38:"L",\u013b:"L",\u1e3c:"L",\u1e3a:"L",\u0141:"L",\u023d:"L",\u2c62:"L",\u2c60:"L",\ua748:"L",\ua746:"L",\ua780:"L",\u01c7:"LJ",\u01c8:"Lj","\u24c2":"M",\uff2d:"M",\u1e3e:"M",\u1e40:"M",\u1e42:"M",\u2c6e:"M",\u019c:"M","\u24c3":"N",\uff2e:"N",\u01f8:"N",\u0143:"N",\u00d1:"N",\u1e44:"N",\u0147:"N",\u1e46:"N",\u0145:"N",\u1e4a:"N",\u1e48:"N",\u0220:"N",\u019d:"N",\ua790:"N",\ua7a4:"N",\u01ca:"NJ",\u01cb:"Nj","\u24c4":"O",\uff2f:"O",\u00d2:"O",\u00d3:"O",\u00d4:"O",\u1ed2:"O",\u1ed0:"O",\u1ed6:"O",\u1ed4:"O",\u00d5:"O",\u1e4c:"O",\u022c:"O",\u1e4e:"O",\u014c:"O",\u1e50:"O",\u1e52:"O",\u014e:"O",\u022e:"O",\u0230:"O",\u00d6:"O",\u022a:"O",\u1ece:"O",\u0150:"O",\u01d1:"O",\u020c:"O",\u020e:"O",\u01a0:"O",\u1edc:"O",\u1eda:"O",\u1ee0:"O",\u1ede:"O",\u1ee2:"O",\u1ecc:"O",\u1ed8:"O",\u01ea:"O",\u01ec:"O",\u00d8:"O",\u01fe:"O",\u0186:"O",\u019f:"O",\ua74a:"O",\ua74c:"O",\u01a2:"OI",\ua74e:"OO",\u0222:"OU","\u24c5":"P",\uff30:"P",\u1e54:"P",\u1e56:"P",\u01a4:"P",\u2c63:"P",\ua750:"P",\ua752:"P",\ua754:"P","\u24c6":"Q",\uff31:"Q",\ua756:"Q",\ua758:"Q",\u024a:"Q","\u24c7":"R",\uff32:"R",\u0154:"R",\u1e58:"R",\u0158:"R",\u0210:"R",\u0212:"R",\u1e5a:"R",\u1e5c:"R",\u0156:"R",\u1e5e:"R",\u024c:"R",\u2c64:"R",\ua75a:"R",\ua7a6:"R",\ua782:"R","\u24c8":"S",\uff33:"S",\u1e9e:"S",\u015a:"S",\u1e64:"S",\u015c:"S",\u1e60:"S",\u0160:"S",\u1e66:"S",\u1e62:"S",\u1e68:"S",\u0218:"S",\u015e:"S",\u2c7e:"S",\ua7a8:"S",\ua784:"S","\u24c9":"T",\uff34:"T",\u1e6a:"T",\u0164:"T",\u1e6c:"T",\u021a:"T",\u0162:"T",\u1e70:"T",\u1e6e:"T",\u0166:"T",\u01ac:"T",\u01ae:"T",\u023e:"T",\ua786:"T",\ua728:"TZ","\u24ca":"U",\uff35:"U",\u00d9:"U",\u00da:"U",\u00db:"U",\u0168:"U",\u1e78:"U",\u016a:"U",\u1e7a:"U",\u016c:"U",\u00dc:"U",\u01db:"U",\u01d7:"U",\u01d5:"U",\u01d9:"U",\u1ee6:"U",\u016e:"U",\u0170:"U",\u01d3:"U",\u0214:"U",\u0216:"U",\u01af:"U",\u1eea:"U",\u1ee8:"U",\u1eee:"U",\u1eec:"U",\u1ef0:"U",\u1ee4:"U",\u1e72:"U",\u0172:"U",\u1e76:"U",\u1e74:"U",\u0244:"U","\u24cb":"V",\uff36:"V",\u1e7c:"V",\u1e7e:"V",\u01b2:"V",\ua75e:"V",\u0245:"V",\ua760:"VY","\u24cc":"W",\uff37:"W",\u1e80:"W",\u1e82:"W",\u0174:"W",\u1e86:"W",\u1e84:"W",\u1e88:"W",\u2c72:"W","\u24cd":"X",\uff38:"X",\u1e8a:"X",\u1e8c:"X","\u24ce":"Y",\uff39:"Y",\u1ef2:"Y",\u00dd:"Y",\u0176:"Y",\u1ef8:"Y",\u0232:"Y",\u1e8e:"Y",\u0178:"Y",\u1ef6:"Y",\u1ef4:"Y",\u01b3:"Y",\u024e:"Y",\u1efe:"Y","\u24cf":"Z",\uff3a:"Z",\u0179:"Z",\u1e90:"Z",\u017b:"Z",\u017d:"Z",\u1e92:"Z",\u1e94:"Z",\u01b5:"Z",\u0224:"Z",\u2c7f:"Z",\u2c6b:"Z",\ua762:"Z","\u24d0":"a",\uff41:"a",\u1e9a:"a",\u00e0:"a",\u00e1:"a",\u00e2:"a",\u1ea7:"a",\u1ea5:"a",\u1eab:"a",\u1ea9:"a",\u00e3:"a",\u0101:"a",\u0103:"a",\u1eb1:"a",\u1eaf:"a",\u1eb5:"a",\u1eb3:"a",\u0227:"a",\u01e1:"a",\u00e4:"a",\u01df:"a",\u1ea3:"a",\u00e5:"a",\u01fb:"a",\u01ce:"a",\u0201:"a",\u0203:"a",\u1ea1:"a",\u1ead:"a",\u1eb7:"a",\u1e01:"a",\u0105:"a",\u2c65:"a",\u0250:"a",\ua733:"aa",\u00e6:"ae",\u01fd:"ae",\u01e3:"ae",\ua735:"ao",\ua737:"au",\ua739:"av",\ua73b:"av",\ua73d:"ay","\u24d1":"b",\uff42:"b",\u1e03:"b",\u1e05:"b",\u1e07:"b",\u0180:"b",\u0183:"b",\u0253:"b","\u24d2":"c",\uff43:"c",\u0107:"c",\u0109:"c",\u010b:"c",\u010d:"c",\u00e7:"c",\u1e09:"c",\u0188:"c",\u023c:"c",\ua73f:"c",\u2184:"c","\u24d3":"d",\uff44:"d",\u1e0b:"d",\u010f:"d",\u1e0d:"d",\u1e11:"d",\u1e13:"d",\u1e0f:"d",\u0111:"d",\u018c:"d",\u0256:"d",\u0257:"d",\ua77a:"d",\u01f3:"dz",\u01c6:"dz","\u24d4":"e",\uff45:"e",\u00e8:"e",\u00e9:"e",\u00ea:"e",\u1ec1:"e",\u1ebf:"e",\u1ec5:"e",\u1ec3:"e",\u1ebd:"e",\u0113:"e",\u1e15:"e",\u1e17:"e",\u0115:"e",\u0117:"e",\u00eb:"e",\u1ebb:"e",\u011b:"e",\u0205:"e",\u0207:"e",\u1eb9:"e",\u1ec7:"e",\u0229:"e",\u1e1d:"e",\u0119:"e",\u1e19:"e",\u1e1b:"e",\u0247:"e",\u025b:"e",\u01dd:"e","\u24d5":"f",\uff46:"f",\u1e1f:"f",\u0192:"f",\ua77c:"f","\u24d6":"g",\uff47:"g",\u01f5:"g",\u011d:"g",\u1e21:"g",\u011f:"g",\u0121:"g",\u01e7:"g",\u0123:"g",\u01e5:"g",\u0260:"g",\ua7a1:"g",\u1d79:"g",\ua77f:"g","\u24d7":"h",\uff48:"h",\u0125:"h",\u1e23:"h",\u1e27:"h",\u021f:"h",\u1e25:"h",\u1e29:"h",\u1e2b:"h",\u1e96:"h",\u0127:"h",\u2c68:"h",\u2c76:"h",\u0265:"h",\u0195:"hv","\u24d8":"i",\uff49:"i",\u00ec:"i",\u00ed:"i",\u00ee:"i",\u0129:"i",\u012b:"i",\u012d:"i",\u00ef:"i",\u1e2f:"i",\u1ec9:"i",\u01d0:"i",\u0209:"i",\u020b:"i",\u1ecb:"i",\u012f:"i",\u1e2d:"i",\u0268:"i",\u0131:"i","\u24d9":"j",\uff4a:"j",\u0135:"j",\u01f0:"j",\u0249:"j","\u24da":"k",\uff4b:"k",\u1e31:"k",\u01e9:"k",\u1e33:"k",\u0137:"k",\u1e35:"k",\u0199:"k",\u2c6a:"k",\ua741:"k",\ua743:"k",\ua745:"k",\ua7a3:"k","\u24db":"l",\uff4c:"l",\u0140:"l",\u013a:"l",\u013e:"l",\u1e37:"l",\u1e39:"l",\u013c:"l",\u1e3d:"l",\u1e3b:"l",\u017f:"l",\u0142:"l",\u019a:"l",\u026b:"l",\u2c61:"l",\ua749:"l",\ua781:"l",\ua747:"l",\u01c9:"lj","\u24dc":"m",\uff4d:"m",\u1e3f:"m",\u1e41:"m",\u1e43:"m",\u0271:"m",\u026f:"m","\u24dd":"n",\uff4e:"n",\u01f9:"n",\u0144:"n",\u00f1:"n",\u1e45:"n",\u0148:"n",\u1e47:"n",\u0146:"n",\u1e4b:"n",\u1e49:"n",\u019e:"n",\u0272:"n",\u0149:"n",\ua791:"n",\ua7a5:"n",\u01cc:"nj","\u24de":"o",\uff4f:"o",\u00f2:"o",\u00f3:"o",\u00f4:"o",\u1ed3:"o",\u1ed1:"o",\u1ed7:"o",\u1ed5:"o",\u00f5:"o",\u1e4d:"o",\u022d:"o",\u1e4f:"o",\u014d:"o",\u1e51:"o",\u1e53:"o",\u014f:"o",\u022f:"o",\u0231:"o",\u00f6:"o",\u022b:"o",\u1ecf:"o",\u0151:"o",\u01d2:"o",\u020d:"o",\u020f:"o",\u01a1:"o",\u1edd:"o",\u1edb:"o",\u1ee1:"o",\u1edf:"o",\u1ee3:"o",\u1ecd:"o",\u1ed9:"o",\u01eb:"o",\u01ed:"o",\u00f8:"o",\u01ff:"o",\u0254:"o",\ua74b:"o",\ua74d:"o",\u0275:"o",\u01a3:"oi",\u0223:"ou",\ua74f:"oo","\u24df":"p",\uff50:"p",\u1e55:"p",\u1e57:"p",\u01a5:"p",\u1d7d:"p",\ua751:"p",\ua753:"p",\ua755:"p","\u24e0":"q",\uff51:"q",\u024b:"q",\ua757:"q",\ua759:"q","\u24e1":"r",\uff52:"r",\u0155:"r",\u1e59:"r",\u0159:"r",\u0211:"r",\u0213:"r",\u1e5b:"r",\u1e5d:"r",\u0157:"r",\u1e5f:"r",\u024d:"r",\u027d:"r",\ua75b:"r",\ua7a7:"r",\ua783:"r","\u24e2":"s",\uff53:"s",\u00df:"s",\u015b:"s",\u1e65:"s",\u015d:"s",\u1e61:"s",\u0161:"s",\u1e67:"s",\u1e63:"s",\u1e69:"s",\u0219:"s",\u015f:"s",\u023f:"s",\ua7a9:"s",\ua785:"s",\u1e9b:"s","\u24e3":"t",\uff54:"t",\u1e6b:"t",\u1e97:"t",\u0165:"t",\u1e6d:"t",\u021b:"t",\u0163:"t",\u1e71:"t",\u1e6f:"t",\u0167:"t",\u01ad:"t",\u0288:"t",\u2c66:"t",\ua787:"t",\ua729:"tz","\u24e4":"u",\uff55:"u",\u00f9:"u",\u00fa:"u",\u00fb:"u",\u0169:"u",\u1e79:"u",\u016b:"u",\u1e7b:"u",\u016d:"u",\u00fc:"u",\u01dc:"u",\u01d8:"u",\u01d6:"u",\u01da:"u",\u1ee7:"u",\u016f:"u",\u0171:"u",\u01d4:"u",\u0215:"u",\u0217:"u",\u01b0:"u",\u1eeb:"u",\u1ee9:"u",\u1eef:"u",\u1eed:"u",\u1ef1:"u",\u1ee5:"u",\u1e73:"u",\u0173:"u",\u1e77:"u",\u1e75:"u",\u0289:"u","\u24e5":"v",\uff56:"v",\u1e7d:"v",\u1e7f:"v",\u028b:"v",\ua75f:"v",\u028c:"v",\ua761:"vy","\u24e6":"w",\uff57:"w",\u1e81:"w",\u1e83:"w",\u0175:"w",\u1e87:"w",\u1e85:"w",\u1e98:"w",\u1e89:"w",\u2c73:"w","\u24e7":"x",\uff58:"x",\u1e8b:"x",\u1e8d:"x","\u24e8":"y",\uff59:"y",\u1ef3:"y",\u00fd:"y",\u0177:"y",\u1ef9:"y",\u0233:"y",\u1e8f:"y",\u00ff:"y",\u1ef7:"y",\u1e99:"y",\u1ef5:"y",\u01b4:"y",\u024f:"y",\u1eff:"y","\u24e9":"z",\uff5a:"z",\u017a:"z",\u1e91:"z",\u017c:"z",\u017e:"z",\u1e93:"z",\u1e95:"z",\u01b6:"z",\u0225:"z",\u0240:"z",\u2c6c:"z",\ua763:"z",\u0386:"\u0391",\u0388:"\u0395",\u0389:"\u0397",\u038a:"\u0399",\u03aa:"\u0399",\u038c:"\u039f",\u038e:"\u03a5",\u03ab:"\u03a5",\u038f:"\u03a9",\u03ac:"\u03b1",\u03ad:"\u03b5",\u03ae:"\u03b7",\u03af:"\u03b9",\u03ca:"\u03b9",\u0390:"\u03b9",\u03cc:"\u03bf",\u03cd:"\u03c5",\u03cb:"\u03c5",\u03b0:"\u03c5",\u03c9:"\u03c9",\u03c2:"\u03c3"},n.fnOperators={equal:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?n.toLowerCase(t)===n.toLowerCase(e):t===e},notequal:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),!n.fnOperators.equal(t,e,i)},lessthan:function(t,e,i){return i?n.toLowerCase(t)n.toLowerCase(e):t>e},lessthanorequal:function(t,e,i){return i?n.toLowerCase(t)<=n.toLowerCase(e):(m(t)&&(t=void 0),t<=e)},greaterthanorequal:function(t,e,i){return i?n.toLowerCase(t)>=n.toLowerCase(e):t>=e},contains:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?!m(t)&&!m(e)&&-1!==n.toLowerCase(t).indexOf(n.toLowerCase(e)):!m(t)&&!m(e)&&-1!==t.toString().indexOf(e)},doesnotcontain:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?!m(t)&&!m(e)&&-1===n.toLowerCase(t).indexOf(n.toLowerCase(e)):!m(t)&&!m(e)&&-1===t.toString().indexOf(e)},isnotnull:function(t){return null!=t},isnull:function(t){return null==t},startswith:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.startsWith(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.startsWith(t,e)},doesnotstartwith:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.notStartsWith(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.notStartsWith(t,e)},like:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.like(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.like(t,e)},isempty:function(t){return void 0===t||""===t},isnotempty:function(t){return void 0!==t&&""!==t},wildcard:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?(t||"boolean"==typeof t)&&e&&"object"!=typeof t&&n.wildCard(n.toLowerCase(t),n.toLowerCase(e)):(t||"boolean"==typeof t)&&e&&n.wildCard(t,e)},endswith:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.endsWith(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.endsWith(t,e)},doesnotendwith:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.notEndsWith(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.notEndsWith(t,e)},processSymbols:function(t){var e=n.operatorSymbols[t];return e?n.fnOperators[e]:n.throwError("Query - Process Operator : Invalid operator")},processOperator:function(t){return n.fnOperators[t]||n.fnOperators.processSymbols(t)}},n.parse={parseJson:function(t){return"string"!=typeof t||!/^[\s]*\[|^[\s]*\{(.)+:/g.test(t)&&-1!==t.indexOf('"')?t instanceof Array?n.parse.iterateAndReviveArray(t):"object"==typeof t&&null!==t&&n.parse.iterateAndReviveJson(t):t=JSON.parse(t,n.parse.jsonReviver),t},iterateAndReviveArray:function(t){for(var e=0;e-1||e.indexOf("z")>-1,o=e.split(/[^0-9.]/);if(s){if(o[5].indexOf(".")>-1){var a=o[5].split(".");o[5]=a[0],o[6]=new Date(e).getUTCMilliseconds().toString()}else o[6]="00";e=n.dateParse.toTimeZone(new Date(parseInt(o[0],10),parseInt(o[1],10)-1,parseInt(o[2],10),parseInt(o[3],10),parseInt(o[4],10),parseInt(o[5]?o[5]:"00",10),parseInt(o[6],10)),n.serverTimezoneOffset,!1)}else{var l=new Date(parseInt(o[0],10),parseInt(o[1],10)-1,parseInt(o[2],10),parseInt(o[3],10),parseInt(o[4],10),parseInt(o[5]?o[5]:"00",10)),h=parseInt(o[6],10),c=parseInt(o[7],10);if(isNaN(h)&&isNaN(c))return l;e.indexOf("+")>-1?l.setHours(l.getHours()-h,l.getMinutes()-c):l.setHours(l.getHours()+h,l.getMinutes()+c),e=n.dateParse.toTimeZone(l,n.serverTimezoneOffset,!1)}null==n.serverTimezoneOffset&&(e=n.dateParse.addSelfOffset(e))}}return e},isJson:function(t){return"string"==typeof t[0]?t:n.parse.parseJson(t)},isGuid:function(t){return null!=/[A-Fa-f0-9]{8}(?:-[A-Fa-f0-9]{4}){3}-[A-Fa-f0-9]{12}/i.exec(t)},replacer:function(t,e){return n.isPlainObject(t)?n.parse.jsonReplacer(t,e):t instanceof Array?n.parse.arrayReplacer(t):t instanceof Date?n.parse.jsonReplacer({val:t},e).val:t},jsonReplacer:function(t,e){for(var i,s=0,o=Object.keys(t);s=0?"+":"-",s=function(a){var l=Math.floor(Math.abs(a));return(l<10?"0":"")+l};return e.getFullYear()+"-"+s(e.getMonth()+1)+"-"+s(e.getDate())+"T"+s(e.getHours())+":"+s(e.getMinutes())+":"+s(e.getSeconds())+r+s(i/60)+":"+s(i%60)}},n}(),bl=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),EK={GroupGuid:"{271bbba0-1ee7}"},K4=function(){function n(t){this.options={from:"table",requestType:"json",sortBy:"sorted",select:"select",skip:"skip",group:"group",take:"take",search:"search",count:"requiresCounts",where:"where",aggregates:"aggregates",expand:"expand"},this.type=n,this.dataSource=t,this.pvt={}}return n.prototype.processResponse=function(t,e,i,r){return t},n}(),jE=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return bl(t,n),t.prototype.processQuery=function(e,i){for(var a,l,p,r=e.dataSource.json.slice(0),s=r.length,o=!0,h={},c=0,d=[],u=[],f=0;f1?e.sort.filter(function(p){return p.fieldName===c})[0]:e.sort[0];s=this.onSortBy(s,d,e.query,!0)}e.page&&(s=this.onPage(s,e.page,e.query)),this.formGroupResult(s,h)}else{for(var o=e.lazyLoad.onDemandGroupInfo,a=o.where.length-1;a>=0;a--)s=this.onWhere(s,o.where[a]);if(e.group.length!==o.level)s=le.group(s,e.group[o.level].fieldName,r,null,null,e.group[o.level].comparer,!0),e.sort.length&&(s=this.onSortBy(s,e.sort[parseInt(o.level.toString(),10)],e.query,!0));else for(a=e.sort.length-1;a>=o.level;a--)s=this.onSortBy(s,e.sort[parseInt(a.toString(),10)],e.query,!1);i=s.length,h=s,s=(s=s.slice(o.skip)).slice(0,o.take),e.group.length!==o.level&&this.formGroupResult(s,h)}return{result:s,count:i}},t.prototype.formGroupResult=function(e,i){if(e.length&&i.length){var r="GroupGuid",s="childLevels",o="level",a="records";e[r]=i[r],e[s]=i[s],e[o]=i[o],e[a]=i[a]}return e},t.prototype.getAggregate=function(e){var i=_t.filterQueries(e.queries,"onAggregates"),r=[];if(i.length)for(var s=void 0,o=0;o=0;l--)a[l]&&(o=i.comparer,le.endsWith(a[l]," desc")&&(o=le.fnSort("descending"),a[l]=a[l].replace(" desc","")),e=le.sort(e,a[l],o));return e}return le.sort(e,s?"key":a,i.comparer)},t.prototype.onGroup=function(e,i,r){if(!e||!e.length)return e;var s=this.getAggregate(r);return le.group(e,le.getValue(i.fieldName,r),s,null,null,i.comparer)},t.prototype.onPage=function(e,i,r){var s=le.getValue(i.pageSize,r),o=(le.getValue(i.pageIndex,r)-1)*s;return e&&e.length?e.slice(o,o+s):e},t.prototype.onRange=function(e,i){return e&&e.length?e.slice(le.getValue(i.start),le.getValue(i.end)):e},t.prototype.onTake=function(e,i){return e&&e.length?e.slice(0,le.getValue(i.nos)):e},t.prototype.onSkip=function(e,i){return e&&e.length?e.slice(le.getValue(i.nos)):e},t.prototype.onSelect=function(e,i){return e&&e.length?le.select(e,le.getValue(i.fieldNames)):e},t.prototype.insert=function(e,i,r,s,o){return m(o)?e.dataSource.json.push(i):e.dataSource.json.splice(o,0,i)},t.prototype.remove=function(e,i,r,s){var a,o=e.dataSource.json;for("object"==typeof r&&!(r instanceof Date)&&(r=le.getObject(i,r)),a=0;a1&&(g="("+g+")"),p.filters.push(g);for(var y=0,S="object"==typeof p.filters[f]?Object.keys(p.filters[f]):[];y-1&&this.formRemoteGroupedData(e[s].items,i+1,r-1);var o="GroupGuid",h="records";return e[o]=EK[o],e.level=i,e.childLevels=r,e[h]=e[0].items.length?this.getGroupedRecords(e,!m(e[0].items[h])):[],e},t.prototype.getGroupedRecords=function(e,i){for(var r=[],o=0;ol.length-3?(l=l.substring(0,l.length-1),o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.endswith:le.odv4UniOperator.endswith):l.lastIndexOf("%")!==l.indexOf("%")&&l.lastIndexOf("%")>l.indexOf("%")+1?(l=l.substring(l.indexOf("%")+1,l.lastIndexOf("%")),o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains):o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains),l="'"+(l=encodeURIComponent(l))+"'";else if("wildcard"===o)if(-1!==l.indexOf("*")){var d=l.split("*"),u=void 0,p=0;if(0!==l.indexOf("*")&&-1===d[0].indexOf("%3f")&&-1===d[0].indexOf("?")&&(u="'"+(u=d[0])+"'",s+=(o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.startswith:le.odv4UniOperator.startswith)+"(",s+=c+",",a&&(s+=a),s+=u+")",p++),l.lastIndexOf("*")!==l.length-1&&-1===d[d.length-1].indexOf("%3f")&&-1===d[d.length-1].indexOf("?")&&(u="'"+(u=d[d.length-1])+"'",p>0&&(s+=" and "),s+=(o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.endswith:le.odv4UniOperator.endswith)+"(",s+=c+",",a&&(s+=a),s+=u+")",p++),d.length>2)for(var f=1;f0&&(s+=" and "),"substringof"===(o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains)||"not substringof"===o){var g=u;u=c,c=g}s+=o+"(",s+=c+",",a&&(s+=a),s+=u+")",p++}0===p?(o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains,(-1!==l.indexOf("?")||-1!==l.indexOf("%3f"))&&(l=-1!==l.indexOf("?")?l.split("?").join(""):l.split("%3f").join("")),l="'"+l+"'"):o="wildcard"}else o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains,(-1!==l.indexOf("?")||-1!==l.indexOf("%3f"))&&(l=-1!==l.indexOf("?")?l.split("?").join(""):l.split("%3f").join("")),l="'"+l+"'";return"substringof"!==o&&"not substringof"!==o||(g=l,l=c,c=g),"wildcard"!==o&&(s+=o+"(",s+=c+",",a&&(s+=a),s+=l+")"),s},t.prototype.addParams=function(e){n.prototype.addParams.call(this,e),delete e.reqParams.params},t.prototype.onComplexPredicate=function(e,i,r){for(var s=[],o=0;o-1;p--)!/\bContent-ID:/i.test(c[p])||!/\bHTTP.+201/.test(c[p])||(l=parseInt(/\bContent-ID: (\d+)/i.exec(c[p])[1],10),o.addedRecords[l]&&(h=le.parse.parseJson(/^\{.+\}/m.exec(c[p])[0]),ze({},o.addedRecords[l],this.processResponse(h))));return o}return null},t.prototype.compareAndRemove=function(e,i,r){var s=this;return m(i)||Object.keys(e).forEach(function(o){o!==r&&"@odata.etag"!==o&&(le.isPlainObject(e[o])?(s.compareAndRemove(e[o],i[o]),0===Object.keys(e[o]).filter(function(l){return"@odata.etag"!==l}).length&&delete e[o]):(e[o]===i[o]||e[o]&&i[o]&&e[o].valueOf()===i[o].valueOf())&&delete e[o])}),e},t}(uc),DK=function(n){function t(){var e=n.call(this)||this;return yt("beforeSend",uc.prototype.beforeSend,e),e}return bl(t,n),t.prototype.insert=function(e,i,r,s,o){return this.pvt.position=o,this.updateType="add",{url:e.dataSource.insertUrl||e.dataSource.crudUrl||e.dataSource.url,data:JSON.stringify(ze({},{value:i,table:r,action:"insert"},le.getAddParams(this,e,s)))}},t.prototype.remove=function(e,i,r,s,o){return n.prototype.remove.call(this,e,i,r),{type:"POST",url:e.dataSource.removeUrl||e.dataSource.crudUrl||e.dataSource.url,data:JSON.stringify(ze({},{key:r,keyColumn:i,table:s,action:"remove"},le.getAddParams(this,e,o)))}},t.prototype.update=function(e,i,r,s,o){return this.updateType="update",this.updateKey=i,{type:"POST",url:e.dataSource.updateUrl||e.dataSource.crudUrl||e.dataSource.url,data:JSON.stringify(ze({},{value:r,action:"update",keyColumn:i,key:r[i],table:s},le.getAddParams(this,e,o)))}},t.prototype.processResponse=function(e,i,r,s,o,a,l){var h;if(e="batch"===(o?JSON.parse(o.data):e).action?le.parse.parseJson(e):e,"add"===this.updateType&&n.prototype.insert.call(this,i,e,null,null,this.pvt.position),"update"===this.updateType&&n.prototype.update.call(this,i,this.updateKey,e),this.updateType=void 0,e.added)for(h=0;hi&&h.push(c)}for(c=0;cthis.pageSize;)h.results.splice(0,1),h.keys.splice(0,1);return window.localStorage.setItem(this.guidId,JSON.stringify(h)),e},t.prototype.beforeSend=function(e,i,r){!m(this.cacheAdaptor.options.batch)&&le.endsWith(r.url,this.cacheAdaptor.options.batch)&&"post"===r.type.toLowerCase()&&i.headers.set("Accept",this.cacheAdaptor.options.multipartAccept),e.dataSource.crossDomain||i.headers.set("Accept",this.cacheAdaptor.options.accept)},t.prototype.update=function(e,i,r,s){return this.isCrudAction=!0,this.cacheAdaptor.update(e,i,r,s)},t.prototype.insert=function(e,i,r){return this.isInsertAction=!0,this.cacheAdaptor.insert(e,i,r)},t.prototype.remove=function(e,i,r,s){return this.isCrudAction=!0,this.cacheAdaptor.remove(e,i,r,s)},t.prototype.batchRequest=function(e,i,r){return this.cacheAdaptor.batchRequest(e,i,r)},t}(uc),nt=function(){function n(t,e,i){var s,r=this;return this.dateParse=!0,this.timeZoneHandling=!0,this.persistQuery={},this.isInitialLoad=!1,this.requests=[],this.isInitialLoad=!0,!t&&!this.dataSource&&(t=[]),i=i||t.adaptor,t&&!1===t.timeZoneHandling&&(this.timeZoneHandling=t.timeZoneHandling),t instanceof Array?s={json:t,offline:!0}:"object"==typeof t?(t.json||(t.json=[]),t.enablePersistence||(t.enablePersistence=!1),t.id||(t.id=""),t.ignoreOnPersist||(t.ignoreOnPersist=[]),s={url:t.url,insertUrl:t.insertUrl,removeUrl:t.removeUrl,updateUrl:t.updateUrl,crudUrl:t.crudUrl,batchUrl:t.batchUrl,json:t.json,headers:t.headers,accept:t.accept,data:t.data,timeTillExpiration:t.timeTillExpiration,cachingPageSize:t.cachingPageSize,enableCaching:t.enableCaching,requestType:t.requestType,key:t.key,crossDomain:t.crossDomain,jsonp:t.jsonp,dataType:t.dataType,offline:void 0!==t.offline?t.offline:!(t.adaptor instanceof DK||t.adaptor instanceof xK||t.url),requiresFormat:t.requiresFormat,enablePersistence:t.enablePersistence,id:t.id,ignoreOnPersist:t.ignoreOnPersist}):le.throwError("DataManager: Invalid arguments"),void 0===s.requiresFormat&&!le.isCors()&&(s.requiresFormat=!!m(s.crossDomain)||s.crossDomain),void 0===s.dataType&&(s.dataType="json"),this.dataSource=s,this.defaultQuery=e,this.dataSource.enablePersistence&&this.dataSource.id&&window.addEventListener("unload",this.setPersistData.bind(this)),s.url&&s.offline&&!s.json.length?(this.isDataAvailable=!1,this.adaptor=i||new up,this.dataSource.offline=!1,this.ready=this.executeQuery(e||new _t),this.ready.then(function(o){r.dataSource.offline=!0,r.isDataAvailable=!0,s.json=o.result,r.adaptor=new jE})):this.adaptor=s.offline?new jE:new up,!s.jsonp&&this.adaptor instanceof up&&(s.jsonp="callback"),this.adaptor=i||this.adaptor,s.enableCaching&&(this.adaptor=new TK(this.adaptor,s.timeTillExpiration,s.cachingPageSize)),this}return Object.defineProperty(n.prototype,"moduleName",{get:function(){return"datamanager"},enumerable:!0,configurable:!0}),n.prototype.getPersistedData=function(t){var e=localStorage.getItem(t||this.dataSource.id);return JSON.parse(e)},n.prototype.setPersistData=function(t,e,i){localStorage.setItem(e||this.dataSource.id,JSON.stringify(i||this.persistQuery))},n.prototype.setPersistQuery=function(t){var e=this,i=this.getPersistedData();if(this.isInitialLoad&&i&&Object.keys(i).length){this.persistQuery=i,this.persistQuery.queries=this.persistQuery.queries.filter(function(s){if(e.dataSource.ignoreOnPersist&&e.dataSource.ignoreOnPersist.length&&s.fn&&e.dataSource.ignoreOnPersist.some(function(l){return s.fn===l}))return!1;if("onWhere"===s.fn){var o=s.e;if(o&&o.isComplex&&o.predicates instanceof Array){var a=o.predicates.map(function(l){if(l.predicates&&l.predicates instanceof Array){var h=l.predicates.map(function(v){return new Ss(v.field,v.operator,v.value,v.ignoreCase,v.ignoreAccent,v.matchCase)});return"and"===l.condition?Ss.and(h):Ss.or(h)}return new Ss(l.field,l.operator,l.value,l.ignoreCase,l.ignoreAccent,l.matchCase)});s.e=new Ss(a[0],o.condition,a.slice(1))}}return!0});var r=ze(new _t,this.persistQuery);return this.isInitialLoad=!1,r}return this.persistQuery=t,this.isInitialLoad=!1,t},n.prototype.setDefaultQuery=function(t){return this.defaultQuery=t,this},n.prototype.executeLocal=function(t){!this.defaultQuery&&!(t instanceof _t)&&le.throwError("DataManager - executeLocal() : A query is required to execute"),this.dataSource.json||le.throwError("DataManager - executeLocal() : Json data is required to execute"),this.dataSource.enablePersistence&&this.dataSource.id&&(t=this.setPersistQuery(t));var e=this.adaptor.processQuery(this,t=t||this.defaultQuery);if(t.subQuery){var i=t.subQuery.fromTable,r=t.subQuery.lookups,s=t.isCountRequired?e.result:e;r&&r instanceof Array&&le.buildHierarchy(t.subQuery.fKey,i,s,r,t.subQuery.key);for(var o=0;oli");P.classList.remove("json-parent");for(var j=0;j',W=ve.children[0].placeholder}return W}function Q(k,W,ve){!m(ve)&&""!==ve&&K(W,ve.split(" ")),!m(k)&&""!==k&&V(W,k.split(" "))}function oe(k,W,ve){if("multiselect"===ve||function Mo(k){if(!k)return!1;for(var W=k;W&&W!==document.body;){if("none"===window.getComputedStyle(W).display)return!1;W=W.parentElement}return!0}(k)){var Te="multiselect"===ve?k:k.clientWidth-parseInt(getComputedStyle(k,null).getPropertyValue("padding-left"),10);!m(W)&&!m(W.getElementsByClassName("e-float-text-content")[0])&&(W.getElementsByClassName("e-float-text-content")[0].classList.contains("e-float-text-overflow")&&W.getElementsByClassName("e-float-text-content")[0].classList.remove("e-float-text-overflow"),(Te0)for(var Ye=0;Ye<_e.length;Ye++)_e[parseInt(Ye.toString(),10)].addEventListener("mousedown",wo,!1),_e[parseInt(Ye.toString(),10)].addEventListener("mouseup",Hl,!1);else if(_e.length>0)for(Ye=0;Ye<_e.length;Ye++)_e[parseInt(Ye.toString(),10)].removeEventListener("mousedown",wo,this),_e[parseInt(Ye.toString(),10)].removeEventListener("mouseup",Hl,this)}function wo(){for(var W=this.parentElement;!W.classList.contains("e-input-group");)W=W.parentElement;!function ya(k,W){!k.classList.contains("e-disabled")&&!k.querySelector("input").readOnly&&W.classList.add("e-input-btn-ripple")}(W,this)}function Hl(){var k=this;setTimeout(function(){k.classList.remove("e-input-btn-ripple")},500)}function ub(k,W){var ve=W("span",{className:k});return ve.classList.add("e-input-group-icon"),ve}function f_(k,W,ve,Te){var _e=m(Te)?mi:Te,Ye=ub(k,_e);W.classList.add("e-float-icon-left");var fi=W.querySelector(".e-input-in-wrap");if(m(fi)){fi=_e("span",{className:"e-input-in-wrap"}),ve.parentNode.insertBefore(fi,ve);var Gs=W.querySelectorAll(ve.tagName+" ~ *");fi.appendChild(ve);for(var Kn=0;Kn-1)if("class"===_e){var Ye=this.getInputValidClassList(k[""+_e]);""!==Ye&&V([W],Ye.split(" "))}else if("style"===_e){var fi=W.getAttribute(_e);fi=m(fi)?k[""+_e]:fi+k[""+_e],W.setAttribute(_e,fi)}else W.setAttribute(_e,k[""+_e])}},n.isBlank=function _le(k){return!k||/^\s*$/.test(k)}}(Le||(Le={})),new RegExp("^(-)?(\\d*)$"),new RegExp("^[A-Za-z0-9._%+-]{1,}@[A-Za-z0-9._%+-]{1,}([.]{1}[a-zA-Z0-9]{2,}|[.]{1}[a-zA-Z0-9]{2,4}[.]{1}[a-zA-Z0-9]{2,4})$"),new RegExp("^([0-9]{4})-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])$"),new RegExp("^[0-9]*$"),new RegExp("^[+]?[0-9]{9,13}$"),new RegExp("^\\d{13,16}$");var me=function(){function n(t,e){this.width=t,this.height=e}return n.prototype.isEmpty=function(){return 0===this.height&&0===this.width},n.prototype.clone=function(){return new n(this.width,this.height)},n}(),wie=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),YB=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},z=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return wie(t,n),t.equals=function(e,i){return e===i||!(!e||!i)&&(!e||!i||e.x===i.x&&e.y===i.y)},t.isEmptyPoint=function(e){return!(e.x&&e.y)},t.transform=function(e,i,r){var s={x:0,y:0};return s.x=Math.round(100*(e.x+r*Math.cos(i*Math.PI/180)))/100,s.y=Math.round(100*(e.y+r*Math.sin(i*Math.PI/180)))/100,s},t.findLength=function(e,i){return Math.sqrt(Math.pow(e.x-i.x,2)+Math.pow(e.y-i.y,2))},t.findAngle=function(e,i){var r=Math.atan2(i.y-e.y,i.x-e.x);return r=180*r/Math.PI,(r%=360)<0&&(r+=360),r},t.distancePoints=function(e,i){return Math.sqrt(Math.pow(i.x-e.x,2)+Math.pow(i.y-e.y,2))},t.getLengthFromListOfPoints=function(e){for(var i=0,r=0;ri.y&&!r?o.y+=s:o.y-=s:e.y===i.y?e.xi.x&&!r?o.x+=s:o.x-=s:r?(a=this.findAngle(e,i),o=this.transform(e,a,s)):(a=this.findAngle(i,e),o=this.transform(i,a,s)),o},t.direction=function(e,i){return Math.abs(i.x-e.x)>Math.abs(i.y-e.y)?e.x0)for(var r=0;rt.right||this.top>t.bottom||this.bottom=t.right&&this.top<=t.top&&this.bottom>=t.bottom},n.prototype.containsPoint=function(t,e){return void 0===e&&(e=0),this.left-e<=t.x&&this.right+e>=t.x&&this.top-e<=t.y&&this.bottom+e>=t.y},n.toBounds=function(t){for(var e=new n,i=0,r=t;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},ZB=function(n){if(n)switch(n.type){case"Linear":default:return fI;case"Radial":return Pie}return fI},Oie=function(){return function n(t,e,i,r){this.left=t,this.right=e,this.top=i,this.bottom=r}}(),$n=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),it([I(0)],t.prototype,"left",void 0),it([I(0)],t.prototype,"right",void 0),it([I(0)],t.prototype,"top",void 0),it([I(0)],t.prototype,"bottom",void 0),t}(Ee),kie=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),it([I(45)],t.prototype,"angle",void 0),it([I(5)],t.prototype,"distance",void 0),it([I(.7)],t.prototype,"opacity",void 0),it([I("lightgrey")],t.prototype,"color",void 0),t}(Ee),JB=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),t.prototype.getClassName=function(){return"Stop"},it([I("")],t.prototype,"color",void 0),it([I(0)],t.prototype,"offset",void 0),it([I(1)],t.prototype,"opacity",void 0),t}(Ee),Sx=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),it([Bt([],JB)],t.prototype,"stops",void 0),it([I("None")],t.prototype,"type",void 0),it([I("")],t.prototype,"id",void 0),t}(Ee),fI=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),it([I(0)],t.prototype,"x1",void 0),it([I(0)],t.prototype,"x2",void 0),it([I(0)],t.prototype,"y1",void 0),it([I(0)],t.prototype,"y2",void 0),t}(Sx),Pie=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),it([I(0)],t.prototype,"cx",void 0),it([I(0)],t.prototype,"cy",void 0),it([I(0)],t.prototype,"fx",void 0),it([I(0)],t.prototype,"fy",void 0),it([I(50)],t.prototype,"r",void 0),t}(Sx),Al=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),it([I("white")],t.prototype,"fill",void 0),it([I("black")],t.prototype,"strokeColor",void 0),it([I("")],t.prototype,"strokeDashArray",void 0),it([I(1)],t.prototype,"strokeWidth",void 0),it([I(1)],t.prototype,"opacity",void 0),it([M0(ZB)],t.prototype,"gradient",void 0),t}(Ee),KB=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),it([I("transparent")],t.prototype,"fill",void 0),t}(Al),Yp=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),it([I("black")],t.prototype,"color",void 0),it([I("Arial")],t.prototype,"fontFamily",void 0),it([I(12)],t.prototype,"fontSize",void 0),it([I(!1)],t.prototype,"italic",void 0),it([I(!1)],t.prototype,"bold",void 0),it([I("CollapseSpace")],t.prototype,"whiteSpace",void 0),it([I("WrapWithOverflow")],t.prototype,"textWrapping",void 0),it([I("Center")],t.prototype,"textAlign",void 0),it([I("None")],t.prototype,"textDecoration",void 0),it([I("Wrap")],t.prototype,"textOverflow",void 0),it([I("transparent")],t.prototype,"fill",void 0),t}(Al),on=function(n){return n[n.Default=0]="Default",n[n.expandNode=2]="expandNode",n[n.interaction=4]="interaction",n[n.GroupingInProgress=8]="GroupingInProgress",n[n.GroupClipboardInProcess=16]="GroupClipboardInProcess",n[n.ClearObject=32]="ClearObject",n}(on||{}),hi=function(n){return n[n.Visible=1]="Visible",n[n.Hidden=2]="Hidden",n[n.Hover=4]="Hover",n[n.Connect=8]="Connect",n}(hi||{}),Kt=function(n){return n[n.None=0]="None",n[n.ShowHorizontalLines=1]="ShowHorizontalLines",n[n.ShowVerticalLines=2]="ShowVerticalLines",n[n.ShowLines=3]="ShowLines",n[n.SnapToHorizontalLines=4]="SnapToHorizontalLines",n[n.SnapToVerticalLines=8]="SnapToVerticalLines",n[n.SnapToLines=12]="SnapToLines",n[n.SnapToObject=16]="SnapToObject",n[n.All=31]="All",n}(Kt||{}),lr=function(n){return n[n.None=1]="None",n[n.ConnectorSourceThumb=2]="ConnectorSourceThumb",n[n.ConnectorTargetThumb=4]="ConnectorTargetThumb",n[n.ResizeSouthEast=8]="ResizeSouthEast",n[n.ResizeSouthWest=16]="ResizeSouthWest",n[n.ResizeNorthEast=32]="ResizeNorthEast",n[n.ResizeNorthWest=64]="ResizeNorthWest",n[n.ResizeEast=128]="ResizeEast",n[n.ResizeWest=256]="ResizeWest",n[n.ResizeSouth=512]="ResizeSouth",n[n.ResizeNorth=1024]="ResizeNorth",n[n.Rotate=2048]="Rotate",n[n.UserHandle=4096]="UserHandle",n[n.ToolTip=8192]="ToolTip",n[n.ResizeAll=2046]="ResizeAll",n[n.All=16382]="All",n}(lr||{}),qe=function(n){return n[n.None=1]="None",n[n.Select=2]="Select",n[n.Delete=4]="Delete",n[n.Drag=8]="Drag",n[n.DragSourceEnd=16]="DragSourceEnd",n[n.DragTargetEnd=32]="DragTargetEnd",n[n.DragSegmentThumb=64]="DragSegmentThumb",n[n.AllowDrop=128]="AllowDrop",n[n.Bridging=256]="Bridging",n[n.BridgeObstacle=512]="BridgeObstacle",n[n.InheritBridging=1024]="InheritBridging",n[n.PointerEvents=2048]="PointerEvents",n[n.Tooltip=4096]="Tooltip",n[n.InheritTooltip=8192]="InheritTooltip",n[n.Interaction=4218]="Interaction",n[n.ReadOnly=16384]="ReadOnly",n[n.LineRouting=32768]="LineRouting",n[n.InheritLineRouting=65536]="InheritLineRouting",n[n.ConnectToNearByNode=131072]="ConnectToNearByNode",n[n.ConnectToNearByPort=262144]="ConnectToNearByPort",n[n.ConnectToNearByElement=393216]="ConnectToNearByElement",n[n.InheritSegmentThumbShape=524288]="InheritSegmentThumbShape",n[n.InheritSegmentThumbSize=1048576]="InheritSegmentThumbSize",n[n.Default=2043454]="Default",n}(qe||{}),Lr=function(n){return n[n.ReadOnly=2]="ReadOnly",n[n.InheritReadOnly=4]="InheritReadOnly",n[n.Select=8]="Select",n[n.Drag=16]="Drag",n[n.Resize=32]="Resize",n[n.Rotate=64]="Rotate",n[n.Tooltip=128]="Tooltip",n[n.Interaction=120]="Interaction",n[n.None=0]="None",n}(Lr||{}),ie=function(n){return n[n.None=0]="None",n[n.Select=2]="Select",n[n.Drag=4]="Drag",n[n.Rotate=8]="Rotate",n[n.Shadow=16]="Shadow",n[n.PointerEvents=32]="PointerEvents",n[n.Delete=64]="Delete",n[n.InConnect=128]="InConnect",n[n.OutConnect=256]="OutConnect",n[n.Individual=512]="Individual",n[n.Expandable=1024]="Expandable",n[n.AllowDrop=2048]="AllowDrop",n[n.Inherit=78]="Inherit",n[n.ResizeNorthEast=4096]="ResizeNorthEast",n[n.ResizeEast=8192]="ResizeEast",n[n.ResizeSouthEast=16384]="ResizeSouthEast",n[n.ResizeSouth=32768]="ResizeSouth",n[n.ResizeSouthWest=65536]="ResizeSouthWest",n[n.ResizeWest=131072]="ResizeWest",n[n.ResizeNorthWest=262144]="ResizeNorthWest",n[n.ResizeNorth=524288]="ResizeNorth",n[n.Resize=1044480]="Resize",n[n.AspectRatio=1048576]="AspectRatio",n[n.Tooltip=2097152]="Tooltip",n[n.InheritTooltip=4194304]="InheritTooltip",n[n.ReadOnly=8388608]="ReadOnly",n[n.HideThumbs=16777216]="HideThumbs",n[n.AllowMovingOutsideLane=33554432]="AllowMovingOutsideLane",n[n.Default=5240814]="Default",n}(ie||{}),Xr=function(n){return n[n.None=0]="None",n[n.ElementIsPort=2]="ElementIsPort",n[n.ElementIsGroup=4]="ElementIsGroup",n[n.HorizontalLaneHeader=8]="HorizontalLaneHeader",n}(Xr||{}),bt=function(n){return n[n.Rotate=2]="Rotate",n[n.ConnectorSource=4]="ConnectorSource",n[n.ConnectorTarget=8]="ConnectorTarget",n[n.ResizeNorthEast=16]="ResizeNorthEast",n[n.ResizeEast=32]="ResizeEast",n[n.ResizeSouthEast=64]="ResizeSouthEast",n[n.ResizeSouth=128]="ResizeSouth",n[n.ResizeSouthWest=256]="ResizeSouthWest",n[n.ResizeWest=512]="ResizeWest",n[n.ResizeNorthWest=1024]="ResizeNorthWest",n[n.ResizeNorth=2048]="ResizeNorth",n[n.Default=4094]="Default",n}(bt||{}),rt=function(n){return n[n.None=1]="None",n[n.Bridging=2]="Bridging",n[n.UndoRedo=4]="UndoRedo",n[n.Tooltip=8]="Tooltip",n[n.UserInteraction=16]="UserInteraction",n[n.ApiUpdate=32]="ApiUpdate",n[n.PageEditable=48]="PageEditable",n[n.Zoom=64]="Zoom",n[n.PanX=128]="PanX",n[n.PanY=256]="PanY",n[n.Pan=384]="Pan",n[n.ZoomTextEdit=512]="ZoomTextEdit",n[n.Virtualization=1024]="Virtualization",n[n.LineRouting=2048]="LineRouting",n[n.Default=500]="Default",n}(rt||{}),Ci=function(n){return n[n.None=0]="None",n[n.SingleSelect=1]="SingleSelect",n[n.MultipleSelect=2]="MultipleSelect",n[n.ZoomPan=4]="ZoomPan",n[n.DrawOnce=8]="DrawOnce",n[n.ContinuousDraw=16]="ContinuousDraw",n[n.Default=3]="Default",n}(Ci||{}),Ya=function(n){return n[n.Self=1]="Self",n[n.Parent=2]="Parent",n}(Ya||{}),pt=function(n){return n[n.None=0]="None",n[n.Control=1]="Control",n[n.Meta=1]="Meta",n[n.Alt=2]="Alt",n[n.Shift=4]="Shift",n}(pt||{}),Mt=function(n){return n[n.None=null]="None",n[n.Number0=0]="Number0",n[n.Number1=1]="Number1",n[n.Number2=2]="Number2",n[n.Number3=3]="Number3",n[n.Number4=4]="Number4",n[n.Number5=5]="Number5",n[n.Number6=6]="Number6",n[n.Number7=7]="Number7",n[n.Number8=8]="Number8",n[n.Number9=9]="Number9",n[n.A=65]="A",n[n.B=66]="B",n[n.C=67]="C",n[n.D=68]="D",n[n.E=69]="E",n[n.F=70]="F",n[n.G=71]="G",n[n.H=72]="H",n[n.I=73]="I",n[n.J=74]="J",n[n.K=75]="K",n[n.L=76]="L",n[n.M=77]="M",n[n.N=78]="N",n[n.O=79]="O",n[n.P=80]="P",n[n.Q=81]="Q",n[n.R=82]="R",n[n.S=83]="S",n[n.T=84]="T",n[n.U=85]="U",n[n.V=86]="V",n[n.W=87]="W",n[n.X=88]="X",n[n.Y=89]="Y",n[n.Z=90]="Z",n[n.Left=37]="Left",n[n.Up=38]="Up",n[n.Right=39]="Right",n[n.Down=40]="Down",n[n.Escape=27]="Escape",n[n.Space=32]="Space",n[n.PageUp=33]="PageUp",n[n.PageDown=34]="PageDown",n[n.End=35]="End",n[n.Home=36]="Home",n[n.Delete=46]="Delete",n[n.Tab=9]="Tab",n[n.Enter=13]="Enter",n[n.BackSpace=8]="BackSpace",n[n.F1=112]="F1",n[n.F2=113]="F2",n[n.F3=114]="F3",n[n.F4=115]="F4",n[n.F5=116]="F5",n[n.F6=117]="F6",n[n.F7=118]="F7",n[n.F8=119]="F8",n[n.F9=120]="F9",n[n.F10=121]="F10",n[n.F11=122]="F11",n[n.F12=123]="F12",n[n.Star=56]="Star",n[n.Plus=187]="Plus",n[n.Minus=189]="Minus",n[n.BracketLeft=219]="BracketLeft",n[n.BracketRight=221]="BracketRight",n}(Mt||{}),ee=function(n){return n[n.Render=2]="Render",n[n.PublicMethod=4]="PublicMethod",n[n.ToolAction=8]="ToolAction",n[n.UndoRedo=16]="UndoRedo",n[n.TextEdit=32]="TextEdit",n[n.Group=64]="Group",n[n.Clear=128]="Clear",n[n.PreventClearSelection=256]="PreventClearSelection",n[n.Interactions=512]="Interactions",n[n.PreventHistory=1024]="PreventHistory",n[n.PreventIconsUpdate=2048]="PreventIconsUpdate",n[n.PreventCollectionChangeOnDragOver=4096]="PreventCollectionChangeOnDragOver",n[n.PreventZIndexOnDragging=8192]="PreventZIndexOnDragging",n[n.isGroupDragging=16384]="isGroupDragging",n[n.DragUsingMouse=32768]="DragUsingMouse",n[n.DecoratorPropertyChange=65536]="DecoratorPropertyChange",n[n.PreventLaneContainerUpdate=131072]="PreventLaneContainerUpdate",n}(ee||{}),Qa=function(n){return n[n.None=2]="None",n[n.DrawSelectorBorder=4]="DrawSelectorBorder",n[n.PreventRenderSelector=8]="PreventRenderSelector",n}(Qa||{}),$i=function(n){return n[n.None=0]="None",n[n.PreventDrag=2]="PreventDrag",n[n.PreventScale=4]="PreventScale",n[n.PreventDataInit=8]="PreventDataInit",n[n.hScrollbarMoved=16]="hScrollbarMoved",n[n.vScrollbarMoved=32]="vScrollbarMoved",n[n.AnimationClick=64]="AnimationClick",n[n.EnableGroupAction=128]="EnableGroupAction",n[n.PanInProgress=256]="PanInProgress",n[n.OverViewAction=512]="OverViewAction",n}($i||{}),ca=function(n){return n[n.None=0]="None",n[n.PropertyChange=1024]="PropertyChange",n[n.Interaction=2048]="Interaction",n}(ca||{}),Ae=function(n){return n[n.Zero=0]="Zero",n[n.One=1]="One",n[n.Two=2]="Two",n[n.Three=3]="Three",n[n.Four=4]="Four",n[n.Five=5]="Five",n}(Ae||{}),Ce=function(n){return n[n.collectionChange=0]="collectionChange",n[n.rotateChange=1]="rotateChange",n[n.positionChange=2]="positionChange",n[n.propertyChange=3]="propertyChange",n[n.selectionChange=4]="selectionChange",n[n.sizeChange=5]="sizeChange",n[n.drop=6]="drop",n[n.sourcePointChange=7]="sourcePointChange",n[n.targetPointChange=8]="targetPointChange",n[n.connectionChange=9]="connectionChange",n[n.animationComplete=10]="animationComplete",n[n.click=11]="click",n[n.doubleClick=12]="doubleClick",n[n.scrollChange=13]="scrollChange",n[n.dragEnter=14]="dragEnter",n[n.dragLeave=15]="dragLeave",n[n.dragOver=16]="dragOver",n[n.textEdit=17]="textEdit",n[n.paletteSelectionChange=18]="paletteSelectionChange",n[n.historyChange=19]="historyChange",n[n.mouseEnter=20]="mouseEnter",n[n.mouseLeave=21]="mouseLeave",n[n.mouseOver=22]="mouseOver",n[n.expandStateChange=23]="expandStateChange",n[n.segmentCollectionChange=24]="segmentCollectionChange",n[n.commandExecute=25]="commandExecute",n[n.historyStateChange=26]="historyStateChange",n[n.onUserHandleMouseDown=27]="onUserHandleMouseDown",n[n.onUserHandleMouseUp=28]="onUserHandleMouseUp",n[n.onUserHandleMouseEnter=29]="onUserHandleMouseEnter",n[n.onUserHandleMouseLeave=30]="onUserHandleMouseLeave",n[n.onImageLoad=31]="onImageLoad",n[n.onDoBindingInit=32]="onDoBindingInit",n[n.keyUp=33]="keyUp",n[n.keyDown=34]="keyDown",n[n.fixedUserHandleClick=35]="fixedUserHandleClick",n[n.elementDraw=36]="elementDraw",n[n.mouseWheel=37]="mouseWheel",n[n.segmentChange=38]="segmentChange",n[n.onFixedUserHandleMouseDown=39]="onFixedUserHandleMouseDown",n[n.onFixedUserHandleMouseUp=40]="onFixedUserHandleMouseUp",n[n.onFixedUserHandleMouseEnter=41]="onFixedUserHandleMouseEnter",n[n.onFixedUserHandleMouseLeave=42]="onFixedUserHandleMouseLeave",n[n.loaded=43]="loaded",n}(Ce||{}),ri=function(n){return n[n.None=1]="None",n[n.Drag=2]="Drag",n[n.Draw=4]="Draw",n[n.InConnect=8]="InConnect",n[n.OutConnect=16]="OutConnect",n[n.ToolTip=32]="ToolTip",n[n.InheritTooltip=64]="InheritTooltip",n[n.Default=24]="Default",n}(ri||{}),Ix=function(n){return n[n.None=1]="None",n[n.Source=2]="Source",n[n.Target=4]="Target",n[n.Intermediate=8]="Intermediate",n[n.All=14]="All",n}(Ix||{}),gI=function(n){return n[n.None=0]="None",n[n.SymmetricAngle=2]="SymmetricAngle",n[n.SymmetricDistance=4]="SymmetricDistance",n[n.Default=6]="Default",n}(gI||{}),as=function(){function n(){this.pivot={x:.5,y:.5},this.isDirt=!0,this.isExport=!1,this.exportScaleValue={x:0,y:0},this.exportScaleOffset={x:0,y:0},this.canApplyStyle=!0,this.visible=!0,this.offsetX=0,this.offsetY=0,this.cornerRadius=0,this.minHeight=void 0,this.minWidth=void 0,this.maxWidth=void 0,this.maxHeight=void 0,this.width=void 0,this.height=void 0,this.rotateAngle=0,this.margin={left:0,right:0,top:0,bottom:0},this.connectionDirection="Auto",this.horizontalAlignment="Auto",this.verticalAlignment="Auto",this.flip="None",this.flipMode="All",this.relativeMode="Point",this.transform=Ya.Self|Ya.Parent,this.style={fill:"white",strokeColor:"black",opacity:1,strokeWidth:1},this.desiredSize=new me,this.actualSize=new me,this.parentTransform=0,this.preventContainer=!1,this.isSvgRender=!1,this.bounds=new Ne(0,0,0,0),this.shadow=null,this.description="",this.staticSize=!1,this.shapeType="",this.isRectElement=!1,this.isCalculateDesiredSize=!0,this.flipOffset={x:0,y:0},this.elementActions=Xr.None,this.inversedAlignment=!0,this.position=void 0,this.unitMode=void 0,this.float=!1,this.floatingBounds=void 0}return n.prototype.setOffsetWithRespectToBounds=function(t,e,i){this.unitMode=i,this.position={x:t,y:e}},n.prototype.getAbsolutePosition=function(t){if(void 0!==this.position)return"Absolute"===this.unitMode?this.position:{x:this.position.x*t.width,y:this.position.y*t.height}},Object.defineProperty(n.prototype,"outerBounds",{get:function(){return this.floatingBounds||this.bounds},set:function(t){this.floatingBounds=t},enumerable:!0,configurable:!0}),n.prototype.measure=function(t,e,i){var s=void 0!==this.height?this.height:(t.height||0)-this.margin.top-this.margin.bottom;return this.id&&0===s&&this.elementActions&Xr.HorizontalLaneHeader&&(s=this.actualSize.height),this.desiredSize=new me(void 0!==this.width?this.width:(t.width||0)-this.margin.left-this.margin.right,s),this.isCalculateDesiredSize&&(this.desiredSize=this.validateDesiredSize(this.desiredSize,t)),this.desiredSize},n.prototype.arrange=function(t){return this.actualSize=t,this.updateBounds(),this.actualSize},n.prototype.updateBounds=function(){this.bounds=yr(this)},n.prototype.validateDesiredSize=function(t,e){return this.isRectElement&&!this.width&&!this.minWidth&&!this.maxWidth&&(t.width=50),this.isRectElement&&!this.height&&!this.minHeight&&!this.maxHeight&&(t.height=50),(void 0===t||void 0!==this.width&&void 0!==this.height)&&((t=t||new me).width=void 0===this.width?(e.width||0)-this.margin.left-this.margin.right:this.width,t.height=void 0===this.height?(e.height||0)-this.margin.top-this.margin.bottom:this.height),void 0!==this.minWidth&&(t.width=Math.max(t.width,this.minWidth)),void 0!==this.minHeight&&(t.height=Math.max(t.height,this.minHeight)),void 0!==this.maxWidth&&0!==this.maxWidth&&(t.width=Math.min(t.width,this.maxWidth)),void 0!==this.maxHeight&&0!==this.maxHeight&&(t.height=Math.min(t.height,this.maxHeight)),t},n}(),Uie=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Cs=function(n){function t(){var e=null!==n&&n.apply(this,arguments)||this;return e.padding=new Oie(0,0,0,0),e.desiredBounds=void 0,e.measureChildren=!0,e.prevRotateAngle=0,e}return Uie(t,n),t.prototype.hasChildren=function(){return void 0!==this.children&&this.children.length>0},t.prototype.measure=function(e,i,r){this.desiredBounds=void 0;var o,a,s=void 0;if(this.hasChildren()){for(var l=0;l=n.width&&s.length>0)i[i.length]={text:s,x:0,dy:0,width:o},s="";else{(s+=a[r+1]||"").indexOf("\n")>-1&&(i[i.length]={text:s,x:0,dy:0,width:Bc(s,n)},s="");var l=Bc(s,n);Math.ceil(l)+2>=n.width&&s.length>0&&(i[i.length]={text:s,x:0,dy:0,width:l},s=""),r===a.length-1&&s.length>0&&(i[i.length]={text:s,x:0,dy:0,width:l},s="")}else i=function ooe(n,t,e){var c,d,u,p,i=[],r="",s=0,o=0,a="nowrap"!==n.whiteSpace,h=(t||n.content).split("\n");for(s=0;s0?" ":"")+c[parseInt(o.toString(),10)];var f=Bc(d=c[o+1]?r+" "+c[o+1]:r,n);Math.floor(f)>(e||n.width)-2&&r.length>0?(i[i.length]={text:r,x:0,dy:0,width:d===r?f:r===p?u:Bc(r,n)},r=""):o===c.length-1&&(i[i.length]={text:r,x:0,dy:0,width:f},r=""),p=d,u=f}return i}(n,t,e);else i[i.length]={text:a,x:0,dy:0,width:Bc(a,n)};return i}(l,r,n.isLaneOrientation?i:void 0),n.wrapBounds=a=function aoe(n,t){var r,s,e={x:0,width:0},i=0;for(i=0;in.width&&("Ellipsis"===n.textOverflow||"Clip"===n.textOverflow)?0:-r/2:"right"===n.textAlign?-r:t.length>1?0:-r/2,t[parseInt(i.toString(),10)].dy=1.2*n.fontSize,t[parseInt(i.toString(),10)].x=r,e.x=Math.min(e.x,r),e.width=Math.max(e.width,s);return e}(l,o),s.width=a.width,n.wrapBounds.width>=i&&"Wrap"!==l.textOverflow&&(s.width=i),s.height=o.length*n.style.fontSize*1.2,s}(this,0,0,this.isLaneOrientation?e.height:this.width||e.width):this.desiredSize,this.desiredSize=void 0===this.width||void 0===this.height?new me(i.width,i.height):new me(this.width,this.height),this.desiredSize=this.validateDesiredSize(this.desiredSize,e),this.desiredSize},t.prototype.arrange=function(e){return(e.width!==this.actualSize.width||e.height!==this.actualSize.height||this.isDirt)&&(this.doWrap=!0),this.actualSize=e,this.updateBounds(),this.isDirt=!1,this.actualSize},t}(as),Vie=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Ii=function(n){function t(){var e=null!==n&&n.apply(this,arguments)||this;return e.measureChildren=void 0,e}return Vie(t,n),t.prototype.measure=function(e,i,r){var s=void 0,o=void 0;if(this.hasChildren()){for(var a=0,l=this.children;a=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Ed=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Xie(t,n),Th([I("")],t.prototype,"content",void 0),Th([I("TopLeft")],t.prototype,"position",void 0),Th([I("Mouse")],t.prototype,"relativeMode",void 0),Th([I(!0)],t.prototype,"showTipPointer",void 0),Th([I("auto")],t.prototype,"width",void 0),Th([I("auto")],t.prototype,"height",void 0),Th([I("Auto")],t.prototype,"openOn",void 0),Th([I()],t.prototype,"animation",void 0),Th([I(!1)],t.prototype,"isSticky",void 0),t}(Ee);function e3(n){var t=new mh;t=t3(n.tooltip,t);var e=new mh(t);return e.beforeCollision=$ie,e.beforeOpen=qie,e.cssClass="e-diagram-tooltip",e.opensOn="custom",e.appendTo("#"+n.element.id),e.close(),e}function qie(n){(""===this.content||void 0===this.content)&&(n.element.style.display="none")}function $ie(n){n.collidedPosition&&n.collidedPosition!==this.position&&(n.element.style.display="none")}function bx(n,t){var e=n.tooltipObject;return t3(t?t.tooltip:n.tooltip,e),e}function t3(n,t){return n.content?(t.content=n.content,"string"==typeof n.content&&(t.content=ko(function(){return n.content})),t.position=n.position,t.showTipPointer=n.showTipPointer,t.width=n.width,t.height=n.height,t.animation=n.animation?n.animation:{close:{effect:"None"}}):t.close(),t}var Mx=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Hn=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},wx=function(n){function t(e,i,r,s){var o=n.call(this,e,i,r,s)||this;return o.inEdges=[],o.outEdges=[],o}return Mx(t,n),Hn([I("")],t.prototype,"id",void 0),Hn([I("Center")],t.prototype,"horizontalAlignment",void 0),Hn([I("Center")],t.prototype,"verticalAlignment",void 0),Hn([re({},$n)],t.prototype,"margin",void 0),Hn([I(12)],t.prototype,"width",void 0),Hn([I(12)],t.prototype,"height",void 0),Hn([re({},Al)],t.prototype,"style",void 0),Hn([I("Square")],t.prototype,"shape",void 0),Hn([I("Auto")],t.prototype,"connectionDirection",void 0),Hn([I(hi.Connect)],t.prototype,"visibility",void 0),Hn([I("")],t.prototype,"pathData",void 0),Hn([I(ri.Default)],t.prototype,"constraints",void 0),Hn([I()],t.prototype,"addInfo",void 0),Hn([I()],t.prototype,"outEdges",void 0),Hn([I()],t.prototype,"inEdges",void 0),Hn([re({},Ed)],t.prototype,"tooltip",void 0),t}(Ee),Es=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return Mx(t,n),t.prototype.getClassName=function(){return"PointPort"},Hn([re({x:.5,y:.5},z)],t.prototype,"offset",void 0),t}(wx),xc=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return Mx(t,n),t.prototype.getClassName=function(){return"PathPort"},Hn([I(.5)],t.prototype,"offset",void 0),Hn([re({x:0,y:0},z)],t.prototype,"displacement",void 0),Hn([I("Center")],t.prototype,"alignment",void 0),t}(wx),yI=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),hr=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Zie=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return yI(t,n),hr([I("blue")],t.prototype,"color",void 0),hr([I("")],t.prototype,"content",void 0),hr([I("")],t.prototype,"link",void 0),hr([I("None")],t.prototype,"textDecoration",void 0),hr([I("NewTab")],t.prototype,"hyperlinkOpenState",void 0),t}(Ee),Cx=function(n){function t(e,i,r,s){var o=n.call(this,e,i,r,s)||this;return r.id||(o.id=e.parentObj&&e.parentObj.propName&&"phases"===e.parentObj.propName?e.parentObj.id:Qe()),o}return yI(t,n),hr([I("")],t.prototype,"content",void 0),hr([I(void 0)],t.prototype,"template",void 0),hr([I("String")],t.prototype,"annotationType",void 0),hr([I(!0)],t.prototype,"visibility",void 0),hr([I(Lr.InheritReadOnly)],t.prototype,"constraints",void 0),hr([re(void 0,Zie)],t.prototype,"hyperlink",void 0),hr([I("")],t.prototype,"id",void 0),hr([I()],t.prototype,"width",void 0),hr([I()],t.prototype,"height",void 0),hr([I(0)],t.prototype,"rotateAngle",void 0),hr([I("Parent")],t.prototype,"rotationReference",void 0),hr([re({strokeWidth:0,strokeColor:"transparent",fill:"transparent"},Yp)],t.prototype,"style",void 0),hr([I("Center")],t.prototype,"horizontalAlignment",void 0),hr([I("Center")],t.prototype,"verticalAlignment",void 0),hr([re({},$n)],t.prototype,"margin",void 0),hr([re({top:void 0,bottom:void 0,left:void 0,right:void 0},$n)],t.prototype,"dragLimit",void 0),hr([I("Shape")],t.prototype,"type",void 0),hr([re({},Ed)],t.prototype,"tooltip",void 0),hr([I()],t.prototype,"addInfo",void 0),t}(Ee),Zn=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return yI(t,n),t.prototype.getClassName=function(){return"ShapeAnnotation"},hr([re({x:.5,y:.5},z)],t.prototype,"offset",void 0),t}(Cx),Nr=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return yI(t,n),t.prototype.getClassName=function(){return"PathAnnotation"},hr([I(.5)],t.prototype,"offset",void 0),hr([re({x:0,y:0},z)],t.prototype,"displacement",void 0),hr([I("Center")],t.prototype,"alignment",void 0),hr([I(!1)],t.prototype,"segmentAngle",void 0),t}(Cx);function Ex(n){return tre[n.toString()]}function i3(n){return nre[""+n]}var tre={X:"M14,14 L106,106 M106,14 L14,106",Circle:"M0,50 A50,50,0 1 1 100,50 A50,50,0 1 1 0,50 Z",Square:"M0,0 L10,0 L10,10 L0,10 z"},ire={OpenArrow:"M15.9,23 L5,16 L15.9,9 L17,10.7 L8.7,16 L17,21.3Z",Square:"M0,0 L10,0 L10,10 L0,10 z",Fletch:"M14.8,10c0,0-3.5,6,0.2,12c0,0-2.5-6-10.9-6C4.1,16,11.3,16,14.8,10z",OpenFetch:"M6,17c-0.6,0-1-0.4-1-1s0.4-1,1-1c10.9,0,11-5,11-5c0-0.6,0.4-1,1-1s1,0.4,1,1C19,10.3,18.9,17,6,17C6,17,6,17,6,17z M18,23c-0.5,0-1-0.4-1-1c0-0.2-0.3-5-11-5c-0.6,0-1-0.5-1-1s0.4-1,1-1c0,0,0,0,0,0c12.9,0,13,6.7,13,7 C19,22.6,18.6,23,18,23z",IndentedArrow:"M17,10c0,0-4.5,5.5,0,12L5,16L17,10z",OutdentedArrow:"M14.6,10c0,0,5.4,6,0,12L5,16L14.6,10z",DoubleArrow:"M19,10 L19,22 L13,16Z M12,10 L12,22 L6,16Z",Arrow:"M15,10 L15,22 L5,16Z",Diamond:"M12,23l-7-7l7-7l6.9,7L12,23z",Circle:"M0,50 A50,50,0 1 1 100,50 A50,50,0 1 1 0,50 Z"},rre={Square:"M0,0 L10,0 L10,10 L0,10 z",Rhombus:"M10,5 L5,10 L0,5 L5,0 L10,5 Z ",Rectangle:"M0,0 L15,0 L15,10 L0,10 z ",OpenArrow:"M15.9,23 L5,16 L15.9,9 L17,10.7 L8.7,16 L17,21.3Z",Fletch:"M9.82,0 C9.82,0,6.61,5,10,10 C10,10,7.71,5,0,5 C0,5,6.61,5,9.82,0 Z ",OpenFetch:"M0.71,5.71 C0.29,5.71,0,5.43,0,5 C0,4.57,0.29,4.29,0.71,4.29 C8.5,4.29,8.57,0.71,8.57,0.71 C8.57,0.29,8.86,0,9.29,0 C9.719999999999999,0,10,0.29,10,0.71 C10,0.93,9.93,5.71,0.71,5.71 C0.71,5.71,0.71,5.71,0.71,5.71 Z M9.29,10 C8.93,10,8.57,9.71,8.57,9.29 C8.57,9.14,8.36,5.71,0.71,5.71 C0.29,5.71,0,5.36,0,5 C0,4.64,0.29,4.29,0.71,4.29 C0.71,4.29,0.71,4.29,0.71,4.29 C9.93,4.29,10,9.07,10,9.29 C10,9.71,9.71,10,9.29,10 Z ",IndentedArrow:"M10,0 C10,0,6.25,4.58,10,10 L0,5 L10,0 Z ",OutdentedArrow:"M8,0 C8,0,12.5,5,8,10 L0,5 L8,0 Z ",DoubleArrow:"M19,10 L19,22 L13,16Z M12,10 L12,22 L6,16Z",Arrow:"M15,10 L15,22 L5,16Z",Diamond:"M10,5 L5,10 L0,5 L5,0 L10,5 Z ",Circle:"M10,5 C10,7.76,7.76,10,5,10 C2.24,10,0,7.76,0,5 C0,2.24,2.24,0,5,0 C7.76,0,10,2.24,10,5 Z ",Ellipse:"M15,5 C15,7.76,11.64,10,7.5,10 C3.36,10,0,7.76,0,5 C0,2.24,3.36,0,7.5,0 C11.64,0,15,2.24,15,5 Z "},nre={Square:"M0,0 L10,0 L10,10 L0,10 z",Rhombus:"M10,5 L5,10 L0,5 L5,0 L10,5 Z ",Rectangle:"M0,0 L15,0 L15,10 L0,10 z",OpenArrow:"M23,15.9 L16,5 L9,15.9 L10.7,17 L16,8.7 L21,17.3Z",Fletch:"M9.82,0 C9.82,0,6.61,5,10,10 C10,10,7.71,5,0,5 C0,5,6.61,5,9.82,0 Z ",OpenFetch:"M0.71,5.71 C0.29,5.71,0,5.43,0,5 C0,4.57,0.29,4.29,0.71,4.29 C8.5,4.29,8.57,0.71,8.57,0.71 C8.57,0.29,8.86,0,9.29,0 C9.719999999999999,0,10,0.29,10,0.71 C10,0.93,9.93,5.71,0.71,5.71 C0.71,5.71,0.71,5.71,0.71,5.71 Z M9.29,10 C8.93,10,8.57,9.71,8.57,9.29 C8.57,9.14,8.36,5.71,0.71,5.71 C0.29,5.71,0,5.36,0,5 C0,4.64,0.29,4.29,0.71,4.29 C0.71,4.29,0.71,4.29,0.71,4.29 C9.93,4.29,10,9.07,10,9.29 C10,9.71,9.71,10,9.29,10 Z ",IndentedArrow:"M10,0 C10,0,6.25,4.58,10,10 L0,5 L10,0 Z ",OutdentedArrow:"M8,0 C8,0,12.5,5,8,10 L0,5 L8,0 Z ",DoubleArrow:"M10,19 L22,19 L16,13Z M10,12 L22,12 L16,6Z",Arrow:"M10,15 L22,15 L16,5Z",Diamond:"M10,5 L5,10 L0,5 L5,0 L10,5 Z ",Circle:"M10,5 C10,7.76,7.76,10,5,10 C2.24,10,0,7.76,0,5 C0,2.24,2.24,0,5,0 C7.76,0,10,2.24,10,5 Z ",Ellipse:"M15,5 C15,7.76,11.64,10,7.5,10 C3.36,10,0,7.76,0,5 C0,2.24,3.36,0,7.5,0 C11.64,0,15,2.24,15,5 Z "};function Dx(n){return sre[n.toString()]}var sre={Process:"M419.511,76.687L359.511,76.687L359.511,43.086L419.511,43.086z",Decision:"M 253.005,115.687L 200.567,146.071L 148.097,115.687L 200.534,85.304L 253.005,115.687 Z",Document:"M 60 31.9 c 0 0 -11 -7.7 -30 0 s -30 0 -30 0 V 0 h 60 V 31.9 Z",PreDefinedProcess:"M 0,0 L 50,0 L 50,50 L 0,50 Z M 8.334,0 L 8.334,50 M 41.667,0 L 41.667,50",Terminator:"M 269.711,29.33C 269.71,44.061 257.77,56 243.04,56L 158.058,56C 143.33,56 131.39,44.061 131.39,29.33L 131.39,29.33C 131.391,14.6057 143.33,2.669 158.058,2.669L 243.044,2.669C 257.772,2.669 269.711,14.6057 269.711,29.333 Z",PaperTap:"M0.0009,17.2042 L0.0009,47.165 C0.001,47.165 14.403,53.5455 25.00,47.165 C35.599,40.7852 44.403,43.5087 50.00,47.165L50.001,17.2042 M50.001,32.7987 L50.001,2.8405 C50.001,2.8405 35.599,-3.5427 25.001,2.8405C14.403,9.2237 5.599,6.494 0.0009,2.8405 L0.0009,32.7987",DirectData:"M 132.62 0 L 17.38 0 C 7.78 0 0 13.43 0 30 C 0 46.57 7.78 60 17.38 60 L 132.62 60 M 132.62 0C 123.02 0 115.24 13.43 115.24 30 C 115.24 46.57 123.02 60 132.62 60 C 142.22 60 150 46.57 150 30 C 150 13.43 142.22 0 132.62 0 z ",SequentialData:"M0.0029,24.999 C0.0029,11.1922 10.433,0.0021 23.295,0.0021 C36.159,0.00216 46.585,11.1922 46.585,24.999C46.585,38.8057 36.159,49.9979 23.295,49.9979 C10.433,49.9979 0.0029,38.8057 0.0029,24.999 z M23.294,49.999 L50.002,49.999",Sort:"M50.001,24.9971 L25.001,49.9971 L0.00097,24.9971 L25.001,-0.00286865 L50.001,24.9971 z M0.000976562,24.9971 L50.001,24.9971",MultiDocument:"M43.6826,40 C44.8746,40.6183 45.8586,41.3502 46.8366,42.1122 L46.8366,4.74487 L3.09857,4.74487 L3.09857,10.9544 M46.837,35.143 C48.027,35.765 49.025,36.604 50.003,37.369 L50.003,0.002 L6.264,0.002 L6.264,4.744 M43.682,47.113 L43.682,10.765 L0.0025,10.7652 L0.0025,47.1132 C0.0025,47.1132 12.5846,53.6101 21.8426,47.1132 C31.1006,40.6163 38.792,43.393 43.6826,47.1132 z",Collate:"M50.001,0.0028 L25.001,25.0029 L0.00097,0.0028 L50.001,0.002 z M0.0009,50.002 L25.001,25.002L50.001,50.002 L0.0009,50.0029 z",SummingJunction:"M7.3252,42.6768 L42.6772,7.3247 M42.6768,42.6768 L7.3248,7.3247 M0.0009,25.001 C0.0009,11.193 11.197,0.0009 25.001,0.0009 C38.809,0.0009 50.001,11.193 50.001,25.001 C50.001,38.809 38.809,50.001 25.001,50.001 C11.197,50.00 0.0009,38.809 0.0009,25.00 z",Or:"M 0 50 L 100 50 M 50 100 L 50 0.0 M 0 50 C 0 22.384 22.392 0 50 0 C 77.616 0 100 22.384 100 50 C 100 77.616 77.616 100 50 100 C 22.392 100 0 77.616 0 50 Z",InternalStorage:"M 0 3.81946A 2.5,3.81946 0 0,1 2.5,0L 47.5 0A 2.5,3.81946 0 0,1 50,3.81946L 50 45.836A 2.5,3.819446 0 0,1 47.5,49.652778L 2.5 49.652778A 2.5,3.819446 0 0,1 0,45.8336L 0 3.819446ZM 0 11.45834L 50 11.4583334M 12.5 0L 12.5 49.652778",Extract:"M0,35 L30,0 L60,35 Z",ManualOperation:"M46.4,28.8 L14.8,28.8 L0,0 L60,0 Z",Merge:"M60,0 L30,35 L0,0 Z",OffPageReference:"M60,33.3 L30.1,39 L0,33.3 L0,0 L60,0 Z",SequentialAccessStorage:"M 60 30 C 60 13.4 46.6 0 30 0 S 0 13.4 0 30 s 13.4 30 30 30 h 28.6 v -6.5 h -9.9C 55.5 48 60 39.5 60 30 Z",Annotation:"M49.9984,50.0029 L-0.00271199,50.0029 L-0.00271199,0.00286865 L49.9984,0.00286865",Annotation2:"M49.9977,50.0029 L25.416,50.0029 L25.416,0.00286865 L49.9977,0.00286865 M25.4166,25.0029 L-0.00227869,25.0029",Data:"M 10 0 L 40 0 L 30 40 L 0 40 Z",Card:"M275,60 L400,60 L400,110 L260,110 L260,75 Z",Delay:"M0,0 L12.029,0 C14.212999,0 16,1.7869979 16,3.9709952 C16,6.1549926 14.212999,7.9409904 12.029,7.9409904 L0,7.9409904 z",Preparation:"M 1048.17 572 C 1051.06 568.86 1055.17 567.05 1059.5 567 L 1094.51 567 C 1098.84 567.05 1102.95 568.86 1105.84 572 L 1126.43 595 C 1127.01 596.28 1127.01 597.72 1126.43 599 L 1105.84 622 C 1102.95 625.14 1098.84 626.95 1094.51 627 L 1059.5 627 C 1055.17 626.95 1051.06 625.14 1048.17 622 L 1027.58 599 C 1027 597.72 1027 596.28 1027.58 595 L 1048.17 572 Z",Display:"M47.8809,19.2914 L32.7968,-0.00594145 L11.3902,-0.00594145 C7.93166,-0.00594145 0.00124586,11.187 0.00124586,24.9968C0.00124586,38.8032 7.93166,49.9962 11.3902,49.9962 L32.7968,49.99 L47.615,31.038 C47.615,31.0388 52.798,24.9968 47.880,19.2914 z",ManualInput:"M 912 732 L 1006.85 707 C 1008.2 707 1009.5 707.53 1010.46 708.46 C 1011.41 709.4 1011.95 710.67 1011.95 712 L 1011.95 762C 1012 764.41 1010.28 766.52 1007.87 767 L 917.1 767 C 915.75 767 914.45 766.47 913.49 765.54 C 912.54 764.6 912 763.33 912 762 L 912 732 Z",LoopLimit:"M 8 9 L 27 9 L 33 15 L 33 26 C 33 27 33 27 32 27 L 4 27 C 3 27 2 27 2 26 L 2 15 L 8 9 Z",StoredData:"M 5.55 0L 50 0A 1.5,30 0 0,1 50,0A 5.555,25 0 0,0 50,50A 1.5,30 0 0,1 50,50L 5.555 50A 5.55,25 0 0,1 5.555,0Z"};function r3(n,t,e){var i;i="Straight"!==n.type&&n.sourceWrapper?n.sourceWrapper.corners.center:function ore(n){var t;if(n.sourcePortWrapper){var e=n.sourcePortWrapper;t={x:e.offsetX,y:e.offsetY}}else t=n.sourceID&&n.sourceWrapper&&n.targetWrapper?Ah(n,0,n.sourceWrapper.corners.center,n.targetWrapper.corners.center,!1):n.sourcePoint;return t}(n);var r=function lre(n,t,e,i,r){var b,M,s=n.sourceWrapper,o=n.targetWrapper,a=n.sourcePortWrapper,l=n.targetPortWrapper,d=[],f=Ga(n),y={corners:undefined,point:t,direction:undefined,margin:{left:5,right:5,bottom:5,top:5}},S={corners:undefined,point:e,direction:undefined,margin:{left:5,right:5,bottom:5,top:5}};if(void 0!==s&&void 0!==o&&(b=En(s),M=En(o),y.corners=s.corners,S.corners=o.corners),void 0!==a&&(y.direction="Left"===a.connectionDirection||"Top"===a.connectionDirection||"Bottom"===a.connectionDirection||"Right"===a.connectionDirection?a.connectionDirection:zo({x:a.offsetX,y:a.offsetY},b,s.bounds)),void 0!==l&&(S.direction="Left"===l.connectionDirection||"Right"===l.connectionDirection||"Bottom"===l.connectionDirection||"Top"===l.connectionDirection?l.connectionDirection:zo({x:l.offsetX,y:l.offsetY},M,o.bounds)),"Bezier"===n.type&&!n.isBezierEditing&&n.segments.length>0)for(var D=n.segments.length-1;D>=0;)n.segments[parseInt(D.toString(),10)].isInternalSegment&&n.segments.pop(),D--;if(void 0!==s&&void 0!==o)return(void 0===y.direction||void 0===S.direction)&&(i?function are(n,t,e){"LeftToRight"===e?(n.direction=n.direction?n.direction:"Right",t.direction=t.direction?t.direction:"Left"):"RightToLeft"===e?(n.direction=n.direction?n.direction:"Left",t.direction=t.direction?t.direction:"Right"):"TopToBottom"===e?(n.direction=n.direction?n.direction:"Bottom",t.direction=t.direction?t.direction:"Top"):"BottomToTop"===e&&(n.direction=n.direction?n.direction:"Top",t.direction=t.direction?t.direction:"Bottom")}(y,S,i):y.corners.top>S.corners.bottom&&Math.abs(y.corners.top-S.corners.bottom)>f?(y.direction=y.direction?y.direction:"Top",S.direction=S.direction?S.direction:"Bottom"):y.corners.bottomf?(y.direction=y.direction?y.direction:"Bottom",S.direction=S.direction?S.direction:"Top"):y.corners.rightf||y.corners.right+f=y.corners.left-f&&y.corners.left>S.corners.left?(y.direction=y.direction?y.direction:"Right",S.direction=S.direction?S.direction:"Left"):y.corners.left>S.corners.right&&Math.abs(y.corners.left-S.corners.right)>y.margin.left+y.margin.right||S.corners.right+f=S.corners.left-f&&y.corners.left0&&n.segments[0].direction&&(y.direction=n.segments[0].direction),y.point=Tc(b,y.direction),d=Tc(b,ls(y.direction)),y.point=Ah(n,0,y.point,d,!1)):y.point=o.corners.center;if(void 0!==h){switch(S.point={x:h.offsetX,y:h.offsetY},S.direction){case"Bottom":case"Top":S.point.y=S.point.y;break;case"Left":case"Right":S.point.x=S.point.x}n.targetPadding&&!w&&(S.point=SI(n,y,S,!0))}else"Orthogonal"===n.type||"Bezier"===n.type?(S.point=Tc(M,S.direction),d=Tc(M,ls(S.direction)),S.point=Ah(n,0,S.point,d,!0)):S.point=a.corners.center;if("Orthogonal"!==n.type){var C=void 0,D=void 0;if("Bezier"===n.type){if(n.bezierSettings.allowSegmentsReset||0===n.segments.length||!z.isEmptyPoint(n.segments[n.segments.length-1].point))return c=p3(n,y,S,void 0,s),xx(n,y,S);Rv(n)}else Rv(n);if(void 0===n.sourcePortWrapper){y.point=y.corners.center,n.segments&&n.segments.length>0&&(C=z.isEmptyPoint((D=n.segments[0]).point)?void 0:D);var A=void 0!==C?C.point:S.point;if("Bezier"===n.type&&n.segments.length>0&&n.segments[0].vector1.angle&&n.segments[0].vector1.distance){var x=Math.max(y.corners.width,y.corners.height);A=z.transform(y.point,n.segments[0].vector1.angle,x/2)}y.point=w?n.sourceWrapper.bounds.center:Ah(n,0,y.point,A,!1)}if(void 0===n.targetPortWrapper){S.point=S.corners.center,n.segments&&n.segments.length>1&&(C=z.isEmptyPoint((D=n.segments[n.segments.length-2]).point)?void 0:D);var R=C?C.point:y.point;"Bezier"===n.type&&n.segments.length>0&&n.segments[n.segments.length-1].vector2.angle&&n.segments[n.segments.length-1].vector2.distance&&(x=Math.max(y.corners.width,y.corners.height),R=z.transform(S.point,n.segments[0].vector2.angle,x/2)),S.point=w?n.targetWrapper.bounds.center:Ah(n,0,R,S.point,!0)}c=xx(n,y,S)}else"Orthogonal"===n.type&&n.segments&&n.segments.length>0&&null!==n.segments[0].direction?c=function yre(n,t,e,i,r,s,o){var a,h,c,d;Rv(n);for(var u=0;u0&&n.segments[u-1].direction===h.direction?u=c3(n,u,t):h.direction?t.point=n3(t,n.segments[parseInt(u.toString(),10)]):(p=n.segments[u-1])&&p.points&&(t.point=p.points[p.points.length-1]),u===n.segments.length-1)if(d3(n,t),l3(a=void 0===r?mre(n,t,e):o3(n,t,e),n),h.points=[],a.length>=2)for(c=0;c2&&n.segments.length>2){var f={x:a[parseInt(c.toString(),10)].x,y:t.point.y};h.points=[],h.points.push(f),h.points.push(a[parseInt(c.toString(),10)]);var p=n.segments[u-1];n.segments.length<4&&p.points.pop(),p.points=p.points.concat(h.points)}else h.points.push(a[parseInt(c.toString(),10)]);else h.points.push(a[parseInt(c.toString(),10)]);else d=u;if(void 0!==d&&!n.selectedSegmentIndex&&(d===n.segments.length-1&&(n.segments[d-1].direction=null,n.segments[d-1].length=null),n.segments.splice(d,1)),i&&0===u){var g=a3(n,i,s);g&&(t.point=g)}}return u3(n,[])}(n,y,S,l,h,o):(n.segments[0]||(C=new bi(n,"segments",{type:"Orthogonal"},!0),n.segments.push(C)),n.segments[0].points=c=p3(n,y,S,void 0,s));return c}(n,y.direction,S.direction,y.point,S.point,r);if(Rv(n),(n.sourceWrapper||n.targetWrapper)&&function pre(n,t,e){var i=n.sourcePortWrapper,r=n.targetPortWrapper,s=n.sourceWrapper,o=t.point,a={left:0,right:0,top:0,bottom:0},l={x:0,y:0},c="Top";if(s?(o=e.point,a=t.margin):(s=n.targetWrapper,a=e.margin),"Orthogonal"===n.type)if(n.segments&&n.segments.length>0&&n.sourceWrapper&&n.segments[0].direction)t.direction=n.segments[0].direction,l=Ah(n,0,l=Tc(s.corners,t.direction),Tc(s.corners,ls(t.direction)),!1);else{var u={corners:null,direction:null,point:null,margin:null};Hv(s,{corners:null,direction:null,point:o,margin:a},u,n),l=u.point,c=u.direction}else{var p=void 0;n.segments&&n.segments.length>1&&(p=s===n.sourceWrapper?n.segments[0].point:n.segments[n.segments.length-2].point),l=Ah(n,0,s.bounds.center,n.segments&&n.segments.length>1?p:o,s===n.targetWrapper)}s===n.sourceWrapper?(t.direction=t.direction||c,t.point=l,n.sourcePortWrapper&&(t.point={x:i.offsetX,y:i.offsetY},n.sourcePadding&&(t.point=SI(n,t,e,!1)))):(e.direction=e.direction||c,e.point=l,n.targetPortWrapper&&(e.point={x:r.offsetX,y:r.offsetY},n.targetPadding&&(e.point=SI(n,t,e,!0))))}(n,y,S),"Straight"===n.type||"Bezier"===n.type)d=xx(n,y,S);else if("Orthogonal"===n.type&&n.segments&&n.segments.length>0&&null!==n.segments[0].length&&null!==n.segments[0].direction)d=function ure(n,t,e,i,r,s,o){var a,l,c,u,h=[];if(Rv(n),n.segments.length>0){for(var p=0;p0&&n.segments[p-1].direction===f.direction)p=c3(n,p,t);else{var g=n.segments[p-1];t.point=f.direction?n3(t,f):g.points[g.points.length-1]}if(p===n.segments.length-1&&(o||r?n.targetWrapper&&void 0===n.targetPortWrapper?(d3(n,t),l=cre(n,t,e)):l=o3(n,t,e):l=hre(n,t,e),l))if(l3(l,n),f.points=[],l.length>=2)for(a=0;at.corners.top&&e.point.ye.point.x?"Left":"Right"):e.point.x>t.corners.left&&e.point.xe.point.y?"Top":"Bottom")),n.sourcePortWrapper&&s===ls(r)?(("Left"===s||"Right"===s)&&t.point.y>=t.corners.top&&t.point.y<=t.corners.center.y&&e.point.y>=t.corners.top&&e.point.y<=t.corners.center.y?(t.direction="Top",a=t.point.y-t.corners.top+20):("Left"===s||"Right"===s)&&t.point.y>t.corners.center.y&&t.point.y<=t.corners.bottom&&e.point.y>t.corners.center.y&&e.point.y<=t.corners.bottom?(t.direction="Bottom",a=t.corners.bottom-t.point.y+20):("Top"===s||"Bottom"===s)&&t.point.x>=t.corners.left&&t.point.x<=t.corners.center.x&&e.point.x>=t.corners.left&&e.point.x<=t.corners.center.x?(t.direction="Left",a=t.point.x-t.corners.left+20):("Top"===s||"Bottom"===s)&&t.point.x<=t.corners.right&&t.point.x>t.corners.center.x&&e.point.x<=t.corners.right&&e.point.xt.point.y&&t.point.y>=e.corners.top?(i="Top",r=t.point.y-e.corners.top+20):e.corners.center.y===t.point.y&&"Top"===n.segments[n.segments.length-2].direction||e.corners.center.ye.point.y?t.point.y-t.corners.top+20:t.corners.bottom-t.point.y+20):(i="Top",r=e.corners.height/2+20):e.corners.center.x!==t.point.x||e.corners.topt.point.x&&t.point.x>=e.corners.left?(i="Left",r=t.point.x-e.corners.left+20):e.corners.center.x===t.point.x&&"Left"===n.segments[n.segments.length-2].direction||e.corners.center.x<=t.point.x&&t.point.x<=e.corners.right?(i="Right",r=e.corners.right-t.point.x+20):void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&t.corners.left<=t.point.x&&t.point.x<=t.corners.right&&(i=t.direction,r=t.point.x>e.point.x?t.point.x-t.corners.left+20:t.corners.right-t.point.x+20):(i="Left",r=e.corners.width/2+20);var a=t.point;t.point=Bn(t.point,"Left"===i||"Top"===i?-r:r,"Left"===i||"Right"===i?0:90),t.direction=z.direction(t.point,e.point),void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&(t.corners.center.x===e.corners.center.x||t.corners.center.y===e.corners.center.y)&&(t.direction=e.direction);var l=Ys(n,t,e);return l.splice(0,0,a),l}function o3(n,t,e){var i,r;e.corners=n.targetWrapper.corners,void 0!==n.sourcePortWrapper&&(r=zo({x:n.sourcePortWrapper.offsetX,y:n.sourcePortWrapper.offsetY},En(n.sourceWrapper),n.sourceWrapper.bounds));var a=function dre(n,t,e,i){var r=!1;switch(e.direction){case"Left":void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&"Right"===i&&t.point.x>e.point.x&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom||("Bottom"===i&&t.point.y>e.point.y||"Top"===i&&t.point.y=t.corners.left&&t.point.x<=t.corners.right?(t.direction="Right"===i?t.point.y>e.point.y?"Top":"Bottom":t.point.xe.point.x&&(t.point.y>e.point.y||t.point.yt.point.y&&e.corners.bottome.point.y||t.point.x>e.point.x&&t.point.y<=e.point.y&&e.corners.top=t.point.y?t.direction="Top":t.point.xe.point.x&&t.point.y>e.point.y&&e.corners.bottomt.point.y?t.direction="Bottom":t.point.y===e.point.y&&t.point.xe.point.y||"Top"===i&&t.point.ye.point.x&&t.point.x>=t.corners.left&&t.point.x<=t.corners.right?(t.direction=t.point.x>e.point.x?"Left":"Right",r=!0):void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&"Left"===i&&t.point.x=t.corners.top&&t.point.y<=t.corners.bottom?(t.direction=t.point.y>e.point.y?"Top":"Bottom",r=!0):t.point.x=t.point.y&&t.point.y===e.point.y||t.point.y>e.point.y&&t.point.x>e.point.x?t.direction="Top":t.point.ye.point.x?t.direction="Bottom":t.point.xe.point.y||t.point.ye.point.x&&(t.direction="Left");break;case"Top":void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&"Bottom"===i&&t.point.y>e.point.y&&t.point.x>=t.corners.left&&t.point.x<=t.corners.right||("Right"===i&&t.point.x>e.point.x||"Left"===i&&e.point.y>t.point.y&&e.point.x>t.point.x)&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom?(t.direction="Bottom"===i?t.point.x>e.point.x?"Left":"Right":t.point.ye.point.y&&t.point.x>e.corners.left&&t.point.x=e.point.y?t.direction="Top":t.point.ye.point.x?t.direction="Left":t.point.yt.point.x)&&t.point.y>e.point.y&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom||"Top"===i&&t.point.y=t.corners.left&&t.point.x<=t.corners.right)?(t.direction="Right"===i||"Left"===i?t.point.y>e.point.y?"Top":"Bottom":t.point.x>e.point.x?"Left":"Right",r=!0):t.point.ye.corners.left&&e.corners.right>t.point.x?t.point.ye.corners.left&&e.corners.center.x>=t.point.x?t.direction="Left":t.point.ye.point.y&&t.point.x>e.point.x?t.direction="Left":t.point.y>e.point.y&&t.point.xe.point.x||e.point.x>t.point.x)&&(t.direction="Bottom")}return r}(n,t,e,r);return!n.selectedSegmentIndex&&void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&e.direction===ls(r)&&(("Left"===e.direction&&t.point.x>e.point.x||"Right"===e.direction&&t.point.x=t.corners.top&&t.point.y<=t.corners.bottom||"Bottom"===e.direction&&t.point.y=t.corners.left&&t.point.x<=t.corners.right)?i=s3(n,t,e):n.selectedSegmentIndex||t.direction!==e.direction?!n.selectedSegmentIndex&&("Left"===e.direction&&t.point.x>e.point.x||"Right"===e.direction&&t.point.x=t.point.y||"Top"===e.direction&&t.point.y>e.point.y||"Bottom"===e.direction&&t.point.y=t.point.x?i=n.selectedSegmentIndex?Ll(t,e):s3(n,t,e):!n.selectedSegmentIndex&&void 0!==n.sourceWrapper&&void 0!==n.targetWrapper&&void 0!==n.targetPortWrapper&&("Left"===t.direction||"Right"===t.direction)&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom&&("Top"===e.direction||"Bottom"===e.direction)&&e.corners.center.x===t.corners.center.x?(t.direction="Top"===e.direction?"Bottom":"Top",i=Ys(n,t,e,"Top"===e.direction?t.corners.bottom-t.point.y+20:t.point.y-t.corners.top+20)):!n.selectedSegmentIndex&&void 0!==n.sourceWrapper&&void 0!==n.targetWrapper&&void 0!==n.targetPortWrapper&&("Top"===t.direction||"Bottom"===t.direction)&&t.point.x>=t.corners.left&&t.point.x<=t.corners.right&&("Left"===e.direction||"Right"===e.direction)&&e.corners.center.y===t.corners.center.y?(t.direction="Left"===e.direction?"Right":"Left",i=Ys(n,t,e,"Left"===e.direction?t.corners.right-t.point.x+20:t.point.x-t.corners.left+20)):i=a?Ys(n,t,e,"Left"===t.direction||"Right"===t.direction?"Left"===t.direction?t.point.x-t.corners.left+20:t.corners.right-t.point.x+20:"Top"===t.direction?t.point.y-t.corners.top+20:t.corners.bottom-t.point.y+20):Ll(t,e):i=Ys(n,t,e),i}function a3(n,t,e){var r,i={x:t.offsetX,y:t.offsetY},s=En(e),o=zo(i,s,e.bounds),a=n.segments[0];return a.direction!==o&&(function Sre(n,t,e,i,r,s){var a,h,o=13,l=[];l.push(i),i.y===r.y&&("Left"===t&&r.xi.x)||i.x===r.x&&("Top"===t&&r.yi.y)||("Top"===t||"Bottom"===t?"Top"===t&&r.yi.y-o||"Bottom"===t&&r.y>i.y&&r.yo&&("Top"===t&&r.yi.y)?l.push({x:i.x,y:r.y}):(a=r.xi.x-o||"right"===t&&r.x>i.x&&r.xo&&("Left"===t&&r.xi.x)?l.push({x:r.x,y:i.y}):(l.push({x:a="Left"===t?e.left-o:e.right+o,y:i.y}),l.push({x:a,y:r.y})),s&&(l.push(n.points[0]),l.reverse()),n.points=l)}(a,o,s,a.points[0],a.points[a.points.length-1],!1),r=a.points[a.points.length-1],a.direction=z.direction(a.points[a.points.length-2],a.points[a.points.length-1])),r}function l3(n,t,e){var s,i=t.segments[t.segments.length-2],r=i.points[i.points.length-1];(("Top"===i.direction||"Bottom"===i.direction)&&r.x===n[1].x||("Left"===i.direction||"Right"===i.direction)&&r.y===n[1].y)&&(i.points[i.points.length-1]=n[1],s=z.direction(i.points[0],i.points[i.points.length-1]),void 0!==t.sourceWrapper&&void 0===t.sourcePortWrapper&&s===ls(i.direction)&&("Left"===i.direction||"Right"===i.direction?i.points[0].x="Right"===i.direction?i.points[0].x-t.sourceWrapper.corners.width:i.points[0].x+t.sourceWrapper.corners.width:i.points[0].y="Bottom"===i.direction?i.points[0].y-t.sourceWrapper.corners.height:i.points[0].y+t.sourceWrapper.corners.height),i.direction=s,i.length=z.distancePoints(i.points[0],i.points[i.points.length-1]),n.splice(0,1))}function SI(n,t,e,i){var o=i?n.targetPadding:n.sourcePadding,a=i?n.targetPortWrapper:n.sourcePortWrapper,l=new Ne(a.bounds.x-o,a.bounds.y-o,a.actualSize.width+2*o,a.actualSize.height+2*o),h=[l.topLeft,l.topRight,l.bottomRight,l.bottomLeft];h[h.length]=h[0];var d=i?e.point:t.point;return Ax({x1:t.point.x,y1:t.point.y,x2:e.point.x,y2:e.point.y},h,0,d)||d}function h3(n,t){var e=[],i=hF(0,n.corners,t);i.push(i[0]);for(var r=0;r0){var r=void 0,s=[],o=t.point;for(r=0;r1&&z.equals(a.points[0],a.points[1])&&n.segments.splice(r,1),a)for(var l=0;l0||0===r)&&i.push(a.points[parseInt(l.toString(),10)])}}return i}function Tx(n,t,e){return"Top"===n||"Bottom"===n?e.x>t.x?"Right":"Left":e.y>t.y?"Bottom":"Top"}function Rv(n){if("Straight"===n.type||"Bezier"===n.type){if(0===n.segments.length||n.segments.length>0&&!z.isEmptyPoint(n.segments[n.segments.length-1].point))if("Bezier"===n.type){var t=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0},!0);n.segments.push(t)}else t=new kl(n,"segments",{type:"Straight"},!0),n.segments.push(t)}else{if(n.segments.length>0)for(var e=!1,i=0;i=t.corners.left&&e.point.x<=t.corners.right&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom)t.direction=e.point.y>t.point.y?"Bottom":"Top",i=Ys(n,t,e,"Top"===t.direction?t.point.y-t.corners.top+20:t.corners.bottom-t.point.y+20);else if(n.sourcePortWrapper&&r===ls(o)){var h;("Left"===r||"Right"===r)&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom?(t.direction=e.point.y>t.point.y?"Bottom":"Top",h=t.corners.height/2+20):("Top"===r||"Bottom"===r)&&t.point.x>=t.corners.left&&t.point.x<=t.corners.right&&(t.direction=e.point.x>t.point.x?"Right":"Left",h=t.corners.width/2+20),t.direction&&h?i=Ys(n,t,e,h,!0):(t.direction=o,i=Ll(t,e))}else if(!n.sourcePortWrapper||r!==e.direction||"Top"!==r&&"Bottom"!==r||t.corners.center.x!==e.corners.center.x)if(t.direction===e.direction)if(("Left"===t.direction||"Right"===t.direction)&&e.point.y>t.corners.top-20&&e.point.yt.corners.left-20&&e.point.xt.point.y?"Bottom":"Top",i=Ys(n,t,e,"Bottom"===t.direction?t.corners.bottom-t.point.y+20:t.point.y-t.corners.top+20);else t.direction=o,i=Ys(n,t,e,"Top"===o||"Bottom"===o?n.sourceWrapper.height/2+20:n.sourceWrapper.width/2+20),t.point=i[1],"Left"===o||"Right"===o?(e.direction=o,e.point="Left"===o?e.corners.middleLeft:e.corners.middleRight):Hv(n.targetWrapper,t,e,n),i=Ys(n,t,e);return i}function d3(n,t){if(void 0!==n.targetWrapper&&void 0===n.targetPortWrapper&&En(n.targetWrapper).containsPoint(t.point,1)){var i=n.targetWrapper,r=n.segments[n.segments.length-2],s=r.points[r.points.length-1],o=ls(r.direction);"Bottom"===o?s.yi.corners.top-1&&(r.points[r.points.length-1].y=i.corners.top-20,r.length=z.distancePoints(r.points[0],r.points[r.points.length-1])):"Left"===o?s.x>i.corners.left-1&&(r.points[r.points.length-1].x=i.corners.left-20,r.length=z.distancePoints(r.points[0],r.points[r.points.length-1])):"Right"===o&&s.x0||0===e)&&t.push(i.points[parseInt(r.toString(),10)]);return t}function Hv(n,t,e,i){var r,s={x:0,y:0},o=II(n,n.corners,n.bounds),a=t.margin,l=t.point;if(o.bottomCenter.y+a.bottoml.y)r="Top",s=o.topCenter;else if(o.middleLeft.x-a.left>l.x)r="Left",s=o.middleLeft;else if(o.middleRight.x+a.rightc&&(p=c,r="Right",s=o.middleRight),p>d&&(p=d,r="Bottom",s=o.bottomCenter),p>u&&(r="Left",s=o.middleLeft)}e.point=s,e.direction=r;var f=Tc(o,ls(e.direction));e.point=Ah(i,0,e.point,f,n===i.targetWrapper)}function p3(n,t,e,i,r){var s,o,a;if(s=function kre(n,t){var e=!1;switch(n){case"Left":switch(t){case"Right":case"Bottom":e=!0}break;case"Top":switch(t){case"Left":case"Right":case"Bottom":e=!0}break;case"Bottom":"Right"===t&&(e=!0)}return e}(t.direction,e.direction),s&&S3(t,e),"Right"===t.direction&&"Left"===e.direction)a=function Ire(n,t,e,i){var o=Math.round(Math.abs(t.point.y-e.point.y)),a={x:Math.max(t.point.x,t.corners.right),y:t.point.y},l={x:Math.min(e.point.x,e.corners.left),y:e.point.y},h=Ga(n);if(i){var c=l;l=a,a=c}return t.corners.bottom+he.corners.bottom+h||("Bezier"!==n.type||e.corners.left-t.corners.right<=2*h&&e.corners.left-t.corners.right>=5)&&(h=0),t.margin={left:h,right:h,top:h,bottom:h},e.margin={left:h,right:h,top:h,bottom:h},0===o&&(t.corners.right=e.corners.right?void 0!==i&&(i.offsetYe.corners.bottom+e.margin.bottom)||void 0===i&&t.corners.middleRight.ye.corners.bottom+e.margin.bottom&&t.corners.top>e.corners.bottom||void 0===i&&t.corners.middleRight.y>e.corners.bottom||void 0!==i&&i.offsetYe.corners.top||void 0===i&&t.corners.middleRight.y>e.corners.bottom?Ae.Three:t.corners.rightr.offsetY+e.margin.right||void 0===r&&t.corners.top>e.corners.middleRight.y||void 0!==r&&(void 0!==i&&i.offsetXr.offsetX||void 0===r&&t.corners.left>e.corners.topCenter.x?Ae.Four:Ae.Two:void 0!==s&&Math.abs(t.corners.right-e.corners.left)<=5&&Math.abs(s.offsetY-e.corners.top)<=5||void 0!==r&&t.corners.right=25&&t.corners.middleRight.y+t.margin.righte.corners.bottom+e.margin.bottom||void 0===o&&t.corners.middleRight.y>e.corners.bottom+e.margin.bottom?t.corners.top>e.corners.bottom?void 0!==a&&t.corners.right+t.margin.righta.offsetX||void 0===a&&t.corners.left>e.corners.bottomCenter.x?Ae.Four:Ae.Two:void 0!==o&&Math.abs(t.corners.right-e.corners.left)<=25&&Math.abs(o.offsetY-e.corners.bottom)<=25?Ae.Two:Ae.Four}(n,t,e,s);else if("Bottom"===t.direction&&"Top"===e.direction)a=function Cre(n,t,e){var r=t.point.x-e.point.x,s=Ga(n);return t.corners.right+se.corners.right+s||("Bezier"!==n.type||e.corners.top-t.corners.bottom<=2*s&&e.corners.top-t.corners.bottom>=5)&&(s=0),t.margin={left:s,right:s,top:s,bottom:s},e.margin={left:s,right:s,top:s,bottom:s},0===r&&t.corners.bottome.corners.right+e.margin.right||void 0===i&&t.corners.bottomCenter.x>e.corners.right+e.margin.right?Ae.Three:t.corners.bottomr.offsetX||void 0===r&&t.corners.left>e.corners.left||void 0!==r&&t.corners.right+t.margin.righte.corners.bottom?Ae.Five:0===s||0===o?Ae.One:Ae.Three}(n,t,e)}else"Bottom"===t.direction&&"Left"===e.direction?a=function Ere(n,t,e,i){var r=n.sourcePortWrapper,s=n.targetPortWrapper,o=Ga(n);if(e.margin={left:o,right:o,top:o,bottom:o},t.margin={top:o,bottom:o,left:o,right:o},i){var l=r;r=s,s=l}return void 0!==r&&r.offsetXs.offsetY||void 0===s&&t.corners.top>e.corners.middleLeft.y?Ae.Four:Ae.Two:void 0!==s&&Math.abs(t.corners.right-e.corners.left)<=25&&Math.abs(s.offsetY-t.corners.bottom)<=25?Ae.Two:Ae.Four}(n,t,e,s):"Left"===t.direction&&"Left"===e.direction?a=function Tre(n,t,e){var i=n.sourcePortWrapper,r=n.targetPortWrapper,s=Ga(n);t.margin={left:s,right:s,top:s,bottom:s},e.margin={left:s,right:s,top:s,bottom:s};var o=Math.round(Math.abs(t.point.x-e.point.x)),a=Math.round(Math.abs(t.point.y-e.point.y));return t.corners.leftr.offsetY||void 0===r&&t.corners.top-t.margin.top>e.corners.middleLeft.y?Ae.Three:t.corners.righte.corners.bottom+e.margin.bottom||void 0===i&&t.corners.middleLeft.y>e.corners.bottom+e.margin.bottom?Ae.Three:t.corners.left>e.corners.right?Ae.Five:0===o||0===a?Ae.One:Ae.Three}(n,t,e):"Left"===t.direction&&"Top"===e.direction?a=function xre(n,t,e,i){var s=n.sourcePortWrapper,o=Ga(n);e.margin={left:o,right:o,top:o,bottom:o},t.margin={top:o,bottom:o,left:o,right:o};var a=n.targetPortWrapper,l={x:Math.min(t.point.x,t.corners.left),y:t.point.y},h={x:e.point.x,y:Math.min(e.point.y,e.corners.top)};if(i){var c=s;s=a,a=c;var d=l;l=h,h=d}return void 0!==s&&s.offsetYa.offsetX||void 0===a&&t.corners.left-t.margin.left>e.corners.topCenter.x?Ae.Two:Ae.Four:void 0!==a&&t.corners.rightr.offsetX||void 0===r&&t.corners.left>e.corners.left||void 0!==r&&t.corners.right+t.margin.righte.corners.right+e.margin.right||void 0===i&&t.corners.left>e.corners.right||void 0!==i&&i.offsetXe.corners.bottom?Ae.Five:0===s||0===o?Ae.One:Ae.Three}(n,t,e));return s&&S3(t,e),o=function Lre(n,t,e,i,r,s){var l,d,h=n.sourceWrapper.corners,c=n.targetWrapper.corners,u=20,p={corners:e.corners,point:e.point,direction:e.direction,margin:e.margin},f={corners:i.corners,point:i.point,direction:i.direction,margin:i.margin};if(!(p.direction===f.direction&&t!==Ae.Five||p.direction!==ls(f.direction)&&t!==Ae.Three))switch(p.direction){case"Left":h.middleLeft.x>c.middleRight.x&&(d=(h.middleLeft.x-c.middleRight.x)/2,u=s?d:Math.min(u,d));break;case"Right":h.middleRight.xc.bottomCenter.y&&(d=(h.topCenter.y-c.bottomCenter.y)/2,u=s?d:Math.min(u,d));break;case"Bottom":h.bottomCenter.yp&&hp)&&o>c&&o<=d&&e>=20&&(s=n.point.x-t.corners.left+s),i&&n.direction===t.direction&&n.corners.left>t.corners.left&&n.corners.left-t.corners.right>=20&&(s=(n.corners.left-t.corners.right)/2),f=Bn(n.point,s,180);break;case"Top":(o>c&&oc)&&h>p&&h<=u&&e>=20&&(s=n.point.y-t.corners.top+s),i&&n.direction===t.direction&&n.corners.top>t.corners.top&&n.corners.top-t.corners.bottom>=20&&(s=(n.corners.top-t.corners.bottom)/2),f=Bn(n.point,s,270);break;case"Right":(h>p&&hp)&&a=c&&e>=20&&(s=t.corners.right-n.point.x+s),i&&n.direction===t.direction&&n.corners.right=20&&(s=(t.corners.left-n.corners.right)/2),f=Bn(n.point,s,0);break;case"Bottom":(o>c&&oc)&&l=p&&e>=20&&(s=t.corners.bottom-n.point.y+s),i&&n.direction===t.direction&&n.corners.bottom=20&&(s=(t.corners.top-n.corners.bottom)/2),f=Bn(n.point,s,90)}r=[n.point,f];var g=void 0;if("Top"===n.direction||"Bottom"===n.direction){var v=n.direction;n.direction=f.x>t.point.x?"Left":"Right",n.point=f,r=bI(n,t,v,r,g=i?.5*Math.abs(f.x-t.point.x):g,i)}else v=n.direction,n.direction=f.y>t.point.y?"Top":"Bottom",n.point=f,r=bI(n,t,v,r,g=i?.5*Math.abs(f.y-t.point.y):g,i);return r}(p,f,u,g)),l}(n,a,t,e,i,r),"Bezier"===n.type&&function Ore(n,t,e){if("Bezier"===n.type)if(0===n.segments.length){var i=e[0],r=e[e.length-1];if(t===Ae.One){var s=Math.min(20,.5*z.findLength(i,r)),o={angle:Gt(i,r),distance:s},a={angle:Gt(r,i),distance:s},l=z.direction(i,r),c=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,orientation:"Left"===l||"Right"===l?"Horizontal":"Vertical"},!0);n.segments.push(c)}else if(t===Ae.Two)o={angle:Gt(i,d=e[1]),distance:.5*z.findLength(i,d)},a={angle:Gt(r,d),distance:.5*z.findLength(r,d)},l=z.direction(i,d),c=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,orientation:"Left"===l||"Right"===l?"Horizontal":"Vertical"},!0),n.segments.push(c);else if(t===Ae.Three){var d={x:.5*((u=e[1]).x+(p=e[e.length-2]).x),y:.5*(u.y+p.y)},f=(o={angle:Gt(i,u),distance:.5*z.findLength(i,u)},a={angle:Gt(d,u),distance:.5*z.findLength(d,u)},z.direction(i,u)),v=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,point:d,orientation:"Left"===f||"Right"===f?"Horizontal":"Vertical"},!0);n.segments.push(v);var y={angle:Gt(d,p),distance:.5*z.findLength(d,p)},S={angle:Gt(r,p),distance:.5*z.findLength(r,p)},b=z.direction(d,p),w=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:y,vector2:S,orientation:"Left"===b||"Right"===b?"Horizontal":"Vertical"},!0);n.segments.push(w)}else if(t===Ae.Four){var D={x:.5*((u=e[1]).x+(p=e[2]).x),y:.5*(u.y+p.y)},A={x:.5*(p.x+(C=e[3]).x),y:.5*(p.y+C.y)};o={angle:Gt(i,u),distance:.5*z.findLength(i,u)},a={angle:Gt(D,u),distance:.5*z.findLength(D,u)},f=z.direction(i,u),v=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,point:D,orientation:"Left"===f||"Right"===f?"Horizontal":"Vertical"},!0),n.segments.push(v),y={angle:Gt(D,p),distance:.5*z.findLength(D,p)},S={angle:Gt(A,p),distance:.5*z.findLength(A,p)},b=z.direction(D,p),w=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:y,vector2:S,point:A,orientation:"Left"===b||"Right"===b?"Horizontal":"Vertical"},!0),n.segments.push(w);var x={angle:Gt(A,C),distance:.5*z.findLength(A,C)},R={angle:Gt(r,C),distance:.5*z.findLength(r,C)},L=z.direction(A,C),N=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:x,vector2:R,orientation:"Left"===L||"Right"===L?"Horizontal":"Vertical"},!0);n.segments.push(N)}else if(t===Ae.Five){var u,p,C,T=e[4],P=(D={x:.5*((u=e[1]).x+(p=e[2]).x),y:.5*(u.y+p.y)},A={x:.5*(p.x+(C=e[3]).x),y:.5*(p.y+C.y)},{x:.5*(C.x+T.x),y:.5*(C.y+T.y)});o={angle:Gt(i,u),distance:.5*z.findLength(i,u)},a={angle:Gt(D,u),distance:.5*z.findLength(D,u)},f=z.direction(i,u),v=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,point:D,orientation:"Left"===f||"Right"===f?"Horizontal":"Vertical"},!0),n.segments.push(v),y={angle:Gt(D,p),distance:.5*z.findLength(D,p)},S={angle:Gt(A,p),distance:.5*z.findLength(A,p)},b=z.direction(D,p),w=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:y,vector2:S,point:A,orientation:"Left"===b||"Right"===b?"Horizontal":"Vertical"},!0),n.segments.push(w),x={angle:Gt(A,C),distance:.5*z.findLength(A,C)},R={angle:Gt(P,C),distance:.5*z.findLength(P,C)},L=z.direction(A,C),N=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:x,vector2:R,point:P,orientation:"Left"===L||"Right"===L?"Horizontal":"Vertical"},!0),n.segments.push(N);var _={angle:Gt(P,T),distance:.5*z.findLength(P,T)},B={angle:Gt(r,T),distance:.5*z.findLength(r,T)},j=z.direction(P,T),oe=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:_,vector2:B,orientation:"Left"===j||"Right"===j?"Horizontal":"Vertical"},!0);n.segments.push(oe)}else c=new ps(n,"segments",{type:"Bezier"},!0),n.segments.push(c)}else for(var ue=0;ue=13?13:n.connectorSpacing<=1?1:n.connectorSpacing}function Gt(n,t){var i=z.findLength({x:t.x,y:n.y},t),r=z.findLength(t,n),s=Math.asin(i/r);return s=180*s/Math.PI,n.xt.y&&(s=360-s):s=n.y0)for(var l=1;lc)&&(s=c,a=h),s>=0&&s<=1)break}}return a}function g3(n,t){var c,d,u,p,f,g,S,b,M,w,D,e=n.x1,i=n.y1,r=n.x2,s=n.y2,o=t.x1,a=t.y1,l=t.x2,h=t.y2;if(w=(c=s-i)*l+(u=e-r)*h+(f=r*i-e*s),0!==(M=c*o+u*a+f)&&0!==w&&v3(M,w)||(b=(d=h-a)*r+(p=o-l)*s+(g=l*a-o*h),0!==(S=d*e+p*i+g)&&0!==b&&v3(S,b)))return null;var A=c*p-d*u;return 0===A?null:(A<0?-A/2:A/2,0,{x:(D=u*g-p*f)<0?(D-0)/A:(D+0)/A,y:(D=d*f-c*g)<0?(D-0)/A:(D+0)/A})}function v3(n,t){return n*t>=0}function m3(n,t,e){switch(t.direction){case"Left":t.point.x>n.left&&(e=t.point.x-n.left>e?t.point.x-n.left+e:e);break;case"Right":t.point.xe?n.right-t.point.x+e:e);break;case"Top":t.point.y>n.top&&(e=t.point.y-n.top>e?t.point.y-n.top+e:e);break;case"Bottom":t.point.ye?n.bottom-t.point.y+e:e)}return e}function Ll(n,t){var e;switch(n.direction){case"Left":case"Right":var i={x:t.point.x,y:n.point.y};e=z.equals(n.point,i)||z.equals(t.point,i)?[n.point,t.point]:[n.point,i,t.point];break;case"Top":case"Bottom":var r={x:n.point.x,y:t.point.y};e=z.equals(n.point,r)||z.equals(t.point,r)?[n.point,t.point]:[n.point,r,t.point]}return e}function Ys(n,t,e,i,r,s){void 0===s&&(s=!1),i||(i=20),s&&t.direction!==e.direction&&(i="Left"===t.direction||"Right"===t.direction?Math.floor(.5*Math.abs(t.point.x-e.point.x)):Math.floor(.5*Math.abs(t.point.y-e.point.y)));var l,h,u,o=n.sourcePortWrapper,c=e.point.x-t.point.x,d=e.point.y-t.point.y;if(!r&&(Math.abs(c)<.001||Math.abs(d)<.001)&&void 0===e.direction)return[t.point,e.point];if(void 0===n.targetWrapper&&Math.abs(c)<=31&&Math.abs(d)<=31){if("Left"===t.direction||"Right"===t.direction?Math.abs(d)<12&&(t.direction=t.point.y>e.point.y?"Top":"Bottom"):Math.abs(c)<12&&(t.direction=t.point.x>e.point.x?"Left":"Right"),Math.abs(c)>12||Math.abs(d)>12)return Ll(t,e);i+=5}return"Left"===t.direction||"Right"===t.direction?("Right"===t.direction?(void 0!==e.direction&&"Right"===e.direction&&(i=Math.max(t.point.x,e.point.x)-t.point.x+i),t.point.x>e.point.x&&void 0===o&&(i=-i)):(void 0!==e.direction&&"Left"===e.direction&&(i=t.point.x-Math.min(t.point.x,e.point.x)+i),(t.point.x>e.point.x||void 0!==o||"Left"===t.direction)&&(i=-i)),u=e.point.y-t.point.y,l=Bn(t.point,i,0),0!=(u=e.point.y-l.y)&&(h=Bn(l,e.point.y-l.y,90))):("Top"===t.direction||"Bottom"===t.direction)&&("Bottom"===t.direction?void 0!==e.direction&&"Bottom"===e.direction&&(i=Math.max(t.point.y,e.point.y)-t.point.y+i):(void 0!==e.direction&&"Top"===e.direction&&(i=t.point.y-Math.min(t.point.y,e.point.y)+i),(t.point.y>e.point.y||void 0!==o||"Top"===t.direction)&&(i=-i)),u=e.point.x-t.point.x,l=Bn(t.point,i,90),0!=(u=e.point.x-l.x)&&(h=Bn(l,e.point.x-l.x,0))),0===u?[t.point,e.point]:[t.point,l,h,e.point]}function bI(n,t,e,i,r,s){var o;switch(void 0===r&&(r=20),void 0===s&&(s=!1),void 0===e?(n.margin={left:2,right:2,top:2,bottom:2},t.margin={left:0,right:5,top:0,bottom:5},s&&(n.margin={left:10,right:10,top:10,bottom:10},t.margin={left:10,right:10,top:10,bottom:10},"Left"===n.direction?(r=Nx(n,t,e,r),n.corners.left-t.corners.right>=5&&(r=Math.abs(n.point.x-n.corners.left)+.5*Math.floor(n.corners.left-t.corners.right))):"Right"===n.direction?(r=Ox(n,t,r,e),t.corners.left-n.corners.right>=5&&(r=Math.abs(n.point.x-n.corners.right)+.5*Math.floor(t.corners.left-n.corners.right))):"Top"===n.direction?(r=Lx(n,t,e,r),n.corners.top-t.corners.bottom>=5&&(r=Math.abs(n.point.y-n.corners.top)+.5*Math.floor(n.corners.top-t.corners.bottom))):"Bottom"===n.direction&&(r=kx(n,t,r,e),t.corners.top-n.corners.bottom>=5&&(r=Math.abs(n.point.y-n.corners.bottom)+.5*Math.floor(t.corners.top-n.corners.bottom))))):("Bottom"===n.direction?s?t.corners.top-n.corners.bottom<20&&(r=t.corners.bottom-n.point.y+25):t.corners.top>n.corners.bottom&&t.corners.top-n.corners.bottom<20&&(r=(t.corners.top-n.corners.bottom)/2):"Top"===n.direction?s?n.corners.top-t.corners.bottom<20&&(r=n.point.y-t.corners.top+25):t.corners.bottomn.corners.right&&t.corners.left-n.corners.right<20&&(r=(t.corners.left-n.corners.right)/2):"Left"===n.direction&&(s?n.corners.left-t.corners.right<20&&(r=n.point.x-t.corners.left+25):t.corners.rightt.point.y||"Top"===t.direction&&n.point.yt.point.x||"Left"===t.direction&&n.point.xh||e.corners.top-e.margin.top<=i.point.y&&e.corners.bottom+e.margin.bottom>=i.point.y))if(!s||"Top"!==e.direction&&"Bottom"!==e.direction)c=Math.min(Math.abs(i.corners.left-e.corners.right)/2,20),h=e.corners.right-n.x+c;else{var c=Math.abs(i.corners.left-e.corners.right)/2;h=e.corners.right-n.x+c}else h="Top"===e.direction&&n.y>i.point.y||"Bottom"===e.direction&&n.y=e.corners.left-e.margin.left&&n.x<=e.corners.right+e.margin.right?Math.min(i.corners.left,e.corners.left)-n.x-20:i.corners.left-n.x-20;break;case"Right":if(e.corners.left-e.margin.left>i.corners.right+i.margin.right&&(e.corners.left-e.margin.right-i.corners.right>h||e.corners.top-e.margin.top<=i.point.y&&e.corners.bottom+e.margin.bottom>=i.point.y))if(!s||"Top"!==e.direction&&"Bottom"!==e.direction)c=Math.min(Math.abs(e.corners.left-i.corners.right)/2,20),h=e.corners.left-n.x-c;else{c=Math.abs(e.corners.left-i.corners.right)/2;h=e.corners.left-n.x-c}else h="Top"===e.direction&&n.y>i.point.y||"Bottom"===e.direction&&n.y=e.corners.left-e.margin.left&&n.x<=e.corners.right+e.margin.right?Math.max(i.corners.right,e.corners.right)-n.x+20:i.corners.right-n.x+20}o=Bn(n,h,0),a=Bn(o,i.point.y-n.y,90),l=i.point}else if("vertical"===t){switch(i.direction){case"Top":e.corners.bottom+e.margin.bottomh||e.corners.left-e.margin.left<=i.point.x&&e.corners.right+e.margin.right>=i.point.x)?!s||"Right"!==e.direction&&"Left"!==e.direction?(c=Math.min(Math.abs(i.corners.top-e.corners.bottom)/2,20),h=e.corners.bottom-n.y+c):(c=Math.abs(i.corners.top-e.corners.bottom)/2,h=e.corners.bottom-n.y+c):h="Left"===e.direction&&n.x>i.point.x||"Right"===e.direction&&n.x=e.corners.top-e.margin.top&&n.y<=e.corners.bottom+e.margin.bottom?Math.min(i.corners.top,e.corners.top)-n.y-20:i.corners.top-n.y-20;break;case"Bottom":e.corners.top-e.margin.top>i.corners.bottom+i.margin.bottom&&(e.corners.top-e.margin.top-i.corners.bottom>h||e.corners.left-e.margin.left<=i.point.x&&e.corners.right+e.margin.right>=i.point.x)?!s||"Right"!==e.direction&&"Left"!==e.direction?(c=Math.min(Math.abs(e.corners.top-i.corners.bottom)/2,20),h=e.corners.top-n.y-c):(c=Math.abs(e.corners.top-i.corners.bottom)/2,h=e.corners.top-n.y-c):h="Left"===e.direction&&n.x>i.point.x||"Right"===e.direction&&n.x=e.corners.top-e.margin.top&&n.y<=e.corners.bottom+e.margin.bottom?Math.max(i.corners.bottom,e.corners.bottom)-n.y+20:i.corners.bottom-n.y+20}o=Bn(n,h,90),a=Bn(o,i.point.x-n.x,0),l=i.point}r.push(o),r.push(a),r.push(l)}function Lx(n,t,e,i){return n.corners.top-n.margin.top>t.corners.top+t.margin.top&&n.corners.top-n.margin.top<=t.corners.bottom+t.margin.bottom?(("Right"===t.direction&&n.point.xt.point.x)&&(i+=n.corners.top-t.corners.top),i+=n.point.y-n.corners.top):i+=void 0!==e&&"Left"!==e&&"Right"===t.direction&&n.point.xt.corners.left-t.margin.left&&n.corners.left-n.margin.left<=t.corners.right+t.margin.right?(("Bottom"===t.direction&&n.point.yt.point.y)&&(i+=n.corners.left-t.corners.left),i+=n.point.x-n.corners.left):i+=void 0!==e&&"Top"!==e&&"Bottom"===t.direction&&n.point.y=t.corners.left-t.margin.left?(("Bottom"===t.direction&&n.point.yt.point.y)&&(e+=t.corners.right-n.corners.right),e+=n.corners.right-n.point.x):e+=void 0!==i&&"Top"!==i&&"Bottom"===t.direction&&n.point.y=t.corners.top-t.margin.top?(("Right"===t.direction&&n.point.xt.point.x)&&(e+=t.corners.bottom-n.corners.bottom),e+=n.corners.bottom-n.point.y):e+=void 0!==i&&"Left"!==i&&"Right"===t.direction&&n.point.xf&&d=u&&d=p&&d<=f?"Left":"Right"}function ls(n){switch(n){case"Top":return"Bottom";case"Bottom":return"Top";case"Left":return"Right";case"Right":return"Left"}return"auto"}var b3=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Ac=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},MI=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return b3(t,n),Ac([I()],t.prototype,"width",void 0),Ac([I()],t.prototype,"height",void 0),t}(Ee),Pre=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return b3(t,n),Ac([I()],t.prototype,"width",void 0),Ac([I()],t.prototype,"height",void 0),Ac([I()],t.prototype,"fit",void 0),Ac([I()],t.prototype,"description",void 0),Ac([I()],t.prototype,"template",void 0),Ac([I()],t.prototype,"tooltip",void 0),t}(Ee),zre=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Nl=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},M3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return zre(t,n),Nl([I("")],t.prototype,"id",void 0),Nl([I(Number.MIN_VALUE)],t.prototype,"zIndex",void 0),Nl([re({},$n)],t.prototype,"margin",void 0),Nl([I(!0)],t.prototype,"visible",void 0),Nl([re({},Ed)],t.prototype,"tooltip",void 0),Nl([I(!1)],t.prototype,"excludeFromLayout",void 0),Nl([I()],t.prototype,"addInfo",void 0),Nl([I("None")],t.prototype,"flip",void 0),Nl([I("All")],t.prototype,"flipMode",void 0),Nl([re({},Pre)],t.prototype,"symbolInfo",void 0),t}(Ee),Rre=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Jn=function(n){function t(e,i,r,s){var o=n.call(this)||this;return o.data="",o.nodeId="",o.annotationId="",o.diagramId="",o.diagramId=i,o.nodeId=e,o.annotationId=r,o.templateFn=FF(s),o}return Rre(t,n),t.prototype.getNodeTemplate=function(){return this.templateFn},Object.defineProperty(t.prototype,"content",{get:function(){return this.data},set:function(e){this.data=e,this.canReset||(this.canReset=!0,this.isTemplate||(this.template=Rh(this,!0)),this.canReset=!1,this.isDirt=!0)},enumerable:!0,configurable:!0}),t}(as),Px=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),hs=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},w3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Px(t,n),hs([I("")],t.prototype,"id",void 0),hs([I("transparent")],t.prototype,"fill",void 0),hs([I("black")],t.prototype,"iconStrokeColor",void 0),hs([I(0)],t.prototype,"iconStrokeWidth",void 0),hs([I(!0)],t.prototype,"visibility",void 0),hs([I(10)],t.prototype,"width",void 0),hs([I(10)],t.prototype,"height",void 0),hs([I("transparent")],t.prototype,"handleStrokeColor",void 0),hs([I(1)],t.prototype,"handleStrokeWidth",void 0),hs([I("")],t.prototype,"pathData",void 0),hs([I(0)],t.prototype,"cornerRadius",void 0),hs([re({left:0,right:0,top:0,bottom:0},$n)],t.prototype,"padding",void 0),hs([re({},Ed)],t.prototype,"tooltip",void 0),t}(Ee),C3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Px(t,n),hs([re({x:0,y:0},z)],t.prototype,"offset",void 0),hs([re({},$n)],t.prototype,"margin",void 0),t}(w3),wI=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Px(t,n),hs([I(.5)],t.prototype,"offset",void 0),hs([I("Center")],t.prototype,"alignment",void 0),hs([re({x:0,y:0},z)],t.prototype,"displacement",void 0),t}(w3);function Dd(n){return n?n instanceof Zn||n instanceof Nr?n.constraints&Lr.Select:n instanceof de?n.constraints&qe.Select:n.constraints&ie.Select:1}function to(n){return n?n instanceof Zn||n instanceof Nr?n.constraints&Lr.Drag:n instanceof de?n.constraints&qe.Drag:n instanceof si?1:n.constraints&ie.Drag:1}function Hre(n,t){return n instanceof de?n.constraints&qe.PointerEvents:n.constraints&ie.PointerEvents}function CI(n){return n instanceof de?n.constraints&qe.Delete:n.constraints&ie.Delete}function EI(n){return n.constraints&qe.DragSourceEnd}function DI(n){return n.constraints&qe.DragTargetEnd}function xI(n){return n.constraints&qe.DragSegmentThumb}function TI(n){return n instanceof Zn||n instanceof Nr?n.constraints&Lr.Rotate:n.constraints&ie.Rotate}function AI(n){return n.constraints&ie.Shadow}function da(n){return n instanceof te&&n.constraints&ie.InConnect?n.constraints&ie.InConnect:0}function Lh(n){return n&&n.constraints&&!(n.constraints&ri.None)&&n.constraints&ri.InConnect?n.constraints&ri.InConnect:0}function Nh(n){return n instanceof te&&n.constraints&ie.OutConnect?n.constraints&ie.OutConnect:0}function xd(n){return n&&n.constraints&&!(n.constraints&ri.None)&&n.constraints&ri.OutConnect?n.constraints&ri.OutConnect:0}function Ol(n,t){var e=0;return n instanceof Zn||n instanceof Nr?e=n.constraints&Lr.Resize:n&&("SouthEast"===t?e=n.constraints&ie.ResizeSouthEast:"East"===t?e=n.constraints&ie.ResizeEast:"NorthEast"===t?e=n.constraints&ie.ResizeNorthEast:"South"===t?e=n.constraints&ie.ResizeSouth:"North"===t?e=n.constraints&ie.ResizeNorth:"SouthWest"===t?e=n.constraints&ie.ResizeSouthWest:"West"===t?e=n.constraints&ie.ResizeWest:"NorthWest"===t&&(e=n.constraints&ie.ResizeNorthWest)),e}function LI(n){return n instanceof de?n.constraints&qe.AllowDrop:n.constraints&ie.AllowDrop}function Ds(n){return n.constraints&rt.Virtualization}function Bv(n){return n.tool&Ci.SingleSelect}function Fv(n){return n.tool&Ci.MultipleSelect}function Lc(n){return n.tool&Ci.ZoomPan}function NI(n){return n.tool&Ci.ContinuousDraw}function E3(n){return n.tool&Ci.DrawOnce}function OI(n){return n.tool&Ci.SingleSelect||n.tool&Ci.MultipleSelect}function _v(n){return n.constraints&rt.UserInteraction}function D3(n){return n.constraints&rt.ZoomTextEdit}function Uv(n){return function Vre(n){return n.constraints&rt.ApiUpdate}(n)||n.diagramActions&ee.ToolAction}function zx(n,t){return n.constraints&ri.Draw}function Rx(n,t){return n.constraints&ri.Drag}function kI(n){return!(n&Qa.DrawSelectorBorder)}function x3(n){return!!(n&Qa.PreventRenderSelector)}var Hx=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),jv=function(n){function t(){var e=null!==n&&n.apply(this,arguments)||this;return e.childTable=[],e.cellStyle={},e.desiredRowHeight=[],e.desiredCellWidth=[],e}return Hx(t,n),t.prototype.rowDefinitions=function(){return this.rowDefns},t.prototype.columnDefinitions=function(){return this.colDefns},t.prototype.addObject=function(e,i,r,s,o){if(this.rows.length>=i){var a=this.rows[parseInt(i.toString(),10)];if(a.cells.length>r){o=o||1,s=s||1;var l=a.cells[parseInt(r.toString(),10)];l.columnSpan=Math.max(o,l.columnSpan),l.rowSpan=Math.max(s,l.rowSpan);var h=new Xre;(h=e).rowId=i,h.columnId=r,h.columnSpan=o,this.childTable[h.id]=h,this.addObjectToCell(h,l)}}},t.prototype.addObjectToCell=function(e,i){i.children||(i.children=[]),e.style.strokeColor="black",e.style.strokeWidth=1,i.children.push(e)},t.prototype.updateProperties=function(e,i,r,s){this.offsetX=e,this.offsetY=i,this.width=r,this.height=s},t.prototype.setDefinitions=function(e,i){this.rowDefns=e,this.colDefns=i,this.children=[],this.rows=this.rows||[];for(var r=0;r0){for(var h=0;hi&&this.updateRowHeight(e,l,!1)}},t.prototype.setTextRefresh=function(e){if(e.children&&e.children.length)for(var i=e.children,r=0;ri&&this.updateColumnWidth(e,a,!1)}},t.prototype.calculateCellWidth=function(e){for(var i,r,s,o=0;os.bounds.width&&(0===s.children.length||void 0===s.children[0].maxWidth)?s.outerBounds.width:s.bounds.width,i=i?is.bounds.height?s.outerBounds.height:s.bounds.height,i=i?i0?e.children[0]:void 0;if(a&&1===e.columnSpan){o="Width"===i?a.bounds.right:a.bounds.bottom,s||(s="Width"===i?a.bounds.width:a.bounds.height);for(var l=0;lo){var d=c-o+("Width"===i?a.bounds.width:a.bounds.height);s&&(s=s0?this.rowDefns.splice(e,0,i):this.rowDefns.push(i);var s=new T3;s.cells=[],(new Td).width=this.width,this.addCellInRow(this.colDefns,i,s),e>this.rows.length-1?this.rows.push(s):this.rows.splice(e,0,s),r&&(this.measure(new me(this.width,this.height)),this.arrange(this.desiredSize))},t.prototype.addColumn=function(e,i,r){var s,o,a,l,h=this.rows;this.colDefns.length>0?this.colDefns.splice(e,0,i):this.colDefns.push(i),void 0!==this.width&&(this.width+=i.width);for(var c=0;cs.cells.length-1?s.cells.push(l):s.cells.splice(e,0,l),this.children.push(l);r&&(this.measure(new me(this.width,this.height)),this.arrange(this.desiredSize))},t.prototype.removeRow=function(e){var i,r,o=this.rows[parseInt(e.toString(),10)];this.height-=this.rowDefns[parseInt(e.toString(),10)].height;for(var a=0;a0){var r=0,s=0;i=new me(0,0),this.calculateSize();for(var o=0,a=this.rows;o0){for(var o=this.offsetX-e.width*this.pivot.x,a=this.offsetY-e.height*this.pivot.y,l=o,h=0,c=this.rows;h1&&this.children.splice(this.children.indexOf(f)+1,f.columnSpan-1),f.rowSpan>1)for(y=s,S=0;y+f.rowSpan-10){for(var c=0;c0?1:0,v=0;v0||a.outEdges.length>0))for(p=a.inEdges.concat(a.outEdges),s=0;s0)for(o=0;o1)for(a=1;a0))if(h=n.wrapper.children[0],"Horizontal"===e.orientation)for(o=e.header&&e.hasHeader?h.rows[1]:h.rows[0],r=0;r0){var e=void 0;t.lineRoutingModule&&t.constraints&rt.LineRouting&&t.lineRoutingModule.renderVirtualRegion(t,!0);for(var i=0;i0?o+1:o)].height=t.wrapper.height;else if(t.isPhase)for(l[t.rowIndex-o].offset=t.wrapper.height,f=0;f0?1:0)].width=t.wrapper.width}function zI(n,t){var i=n.shape,r=i.header&&i.hasHeader?1:0;return"Horizontal"===i.orientation?t.rowIndex-(r+=i.phases.length>0?1:0):t.columnIndex-(i.phaseSize&&i.phases.length>0?1:0)}function RI(n){var t=0,e=n.shape;return"Horizontal"===e.orientation&&(t=e.header&&e.hasHeader?1:0),e.phases.length>0&&e.phaseSize&&(t+=1),t}function HI(n,t,e,i){var r=n.shape;if(r.phases.length>0){var s=t.nameTable[r.phases[parseInt(i.toString(),10)].header.id];s&&s.maxWidth0?u+1:u);var w=Nc(n,o),C=void 0!==i?i:l.lanes.length;if(u+=C,r={element:M,cause:n.diagramActions,diagramAction:n.getDiagramAction(n.diagramActions),state:"Changing",type:"Addition",cancel:!1,laneIndex:C},n.triggerEvent(Ce.collectionChange,r),!r.cancel){if(c){var D=new Vv;D.height=e.height,o.addRow(u,D,!1),s.height=void 0!==s.height?s.height+e.height:s.height,s.wrapper.height=o.height=s.height}else{var A=new Td;A.width=e.width,o.addColumn(C+1,A,!1),s.width&&(s.width+=e.width,s.wrapper.width=o.width=s.width),n.diagramActions&ee.UndoRedo||(o.rows[0].cells[0].columnSpan+=1)}n.diagramActions&ee.UndoRedo||(M.id=""===M.id?Qe():M.id),void 0!==i?l.lanes.splice(i,0,M):l.lanes.push(M),r={element:M,cause:n.diagramActions,diagramAction:n.getDiagramAction(n.diagramActions),state:"Changed",type:"Addition",cancel:!1,laneIndex:C},n.triggerEvent(Ce.collectionChange,r),L3(o,n,s,u,C,c),h="Horizontal"===l.orientation?n.nameTable[o.rows[parseInt(u.toString(),10)].cells[0].children[0].id]:l.header&&l.hasHeader?n.nameTable[o.rows[1].cells[parseInt(u.toString(),10)].children[0].id]:n.nameTable[o.rows[0].cells[parseInt(u.toString(),10)].children[0].id],n.diagramActions&ee.UndoRedo||(d={type:"LaneCollectionChanged",changeType:"Insert",undoObject:$(M),redoObject:$(h),category:"Internal"},n.addHistoryEntry(d)),Gp(n,s,"Horizontal"===l.orientation?u:l.header&&l.hasHeader?1:0),Qp(s),Oc(n,s);var R=!1;if((p=e.children)&&p.length>0)for(f=0;f0){var o=t.children[0],a=n.nameTable[o.id];(function rne(n,t,e){return n.left-(e.left||0)<=t.x&&n.right+(e.right||0)>=t.x&&n.top-(e.top||0)<=t.y&&n.bottom+(e.bottom||0)>=t.y})(o.bounds,e,r)&&(n.addChild(a,i),s=!0)}return s}function nne(n,t,e){if("SwimLane"===t.shape.type){var i=void 0,r=void 0,s=void 0,a=void 0,l=void 0,h=void 0,c=t.wrapper.bounds.x,d=t.wrapper.bounds.y,u=t.shape,p=u.padding,f=u.phases,g=void 0,v=t.wrapper.children[0],y="Horizontal"===u.orientation;if(i=u.header&&u.hasHeader?0:-1,u.phases.length>0&&(i+=1),e.offset>(y?u.lanes[0].header.width:u.lanes[0].header.height)){for(h=0;he.offset){if(g=h>0?e.offset-(h>0?f[h-1]:s).offset:e.offset,y){var b=v.columnDefinitions()[parseInt(h.toString(),10)];b.width-=g,(a=n.nameTable[u.phases[parseInt(h.toString(),10)].header.id]).maxWidth=a.wrapper.maxWidth=b.width,v.updateColumnWidth(h,b.width,!1);var M=new Td;M.width=g,l=h,v.addColumn(h,M,!1);break}var w=v.rowDefinitions()[h+i];w.height-=g,a=n.nameTable[u.phases[parseInt(h.toString(),10)].header.id],v.updateRowHeight(h+i,w.height,!1);var C=new Vv;C.height=g,l=h,v.addRow(h+i,C,!1);break}if(n.diagramActions&ee.UndoRedo&&void 0===l&&(D=n.historyManager.currentEntry.next).isLastPhase&&function sne(n,t,e,i,r,s){var a=t.shape.phases[n-2],l=e.previousPhase.offset;if(r){var h=i.columnDefinitions()[n-1],c=new Td;n>1?(c.width=h.width-(l-a.offset),h.width=l-a.offset):(c.width=h.width-l,h.width=l),i.updateColumnWidth(n-1,h.width,!1),i.addColumn(n,c,!1)}else{h=i.rowDefinitions()[parseInt(n.toString(),10)];var d=new Vv;n>1?(d.height=e.undoObject.offset-l,h.height=l-a.offset):(d.height=h.height-l,h.height=l),i.updateRowHeight(n,h.height,!1),i.addRow(1+n,d,!1)}}(l=f.length,t,D,v,y),l>=0){var A=new sb(t.shape,"phases",e,!0);if(n.diagramActions&ee.UndoRedo||(A.id+=Qe()),u.phases.splice(l,0,A),Bx(v,n,t,i,y,l),y){if(r=n.nameTable[v.rows[parseInt(i.toString(),10)].cells[parseInt(l.toString(),10)].children[0].id],0===l&&u.header&&u.hasHeader){v.rows[0].cells[0].children=v.rows[0].cells[1].children,v.rows[0].cells[1].children=[];for(var x=v.rows[0],R=0;Rl+1){var O=n.nameTable[v.rows[parseInt(i.toString(),10)].cells[l+1].children[0].id];v.updateColumnWidth(l+1,L[l+1].width,!0,p),O.maxWidth=O.wrapper.maxWidth=L[l+1].width}t.width=t.wrapper.width=t.wrapper.children[0].width=v.width}else{r=n.nameTable[v.rows[i+l].cells[0].children[0].id];var N=v.rowDefinitions(),T=N[i+l].height;(function ane(n,t,e,i,r){for(var o,a,l=e.rows[parseInt(i.toString(),10)],h=e.rows[i+1],c=e.rows[i-1],d=1;di+l+1&&v.updateRowHeight(i+l+1,T=N[i+l+1].height,!0,p),t.height=t.wrapper.height=t.wrapper.children[0].height=v.actualSize.height}if(Qp(t),t.width=t.wrapper.actualSize.width,Oc(n,t),n.drag(t,c-t.wrapper.bounds.x,d-t.wrapper.bounds.y),PI(t,n),n.commandHandler.select(r),!(n.diagramActions&ee.UndoRedo)){var D={type:"PhaseCollectionChanged",changeType:"Insert",undoObject:$(A),redoObject:$(r),category:"Internal"};n.addHistoryEntry(D)}n.updateDiagramObject(t)}}}}function z3(n,t,e,i,r,s,o){var a,l,f,h=t.shape,c="Horizontal"===h.orientation,d=t.wrapper.children[0],g=c?s:o;e?(a=c?e.bounds.x+e.bounds.width:e.bounds.x,l=c?e.bounds.y:e.bounds.y+e.bounds.height):(a=d.bounds.x,l=r.bounds.y);var v=new Ne(a,l,i.desiredCellWidth,i.desiredCellHeight),S=Wv(n,0,t,{id:t.id+(c?h.lanes[g-2]:h.lanes[g-1]).id+Qe()[0],rowIndex:s,columnIndex:o,width:i.minWidth,height:i.minHeight,style:(c?h.lanes[g-2]:h.lanes[g-1]).style,constraints:ie.Default|ie.AllowDrop,container:{type:"Canvas",orientation:c?"Horizontal":"Vertical"}},!1,!1,!0);if(S.children[0].isCalculateDesiredSize=!1,d.addObject(S,s,o),r&&r.children&&r.children.length)for(f=0;f1)for(var f=1;fh.margin.left&&(h.margin.left=p)):(h.margin.top-=e.desiredCellHeight,p>h.margin.top&&(h.margin.top=p)))}(n,r,i,v,S,c,e)}function R3(n,t,e){if("SwimLane"===t.shape.type&&("ResizeSouth"===e||"ResizeEast"===e)){var i=t.shape,r=t.wrapper.children[0],s=void 0,o=void 0;"ResizeSouth"===e?"Vertical"===i.orientation?s=r.rows[r.rows.length-1].cells[0]:(o=r.rows.length-1,s=r.rows[parseInt(o.toString(),10)].cells[r.rows[parseInt(o.toString(),10)].cells.length-1]):(o=i.header&&i.hasHeader?1:0,s=r.rows[parseInt(o.toString(),10)].cells[r.rows[parseInt(o.toString(),10)].cells.length-1]),n.commandHandler.select(n.nameTable[s.children[0].id])}}function BI(n,t,e,i,r,s){var o,a,l,c,u,p,f,d=Qe(),g=n.shape,v=g.phases,y=n.offsetX-n.wrapper.actualSize.width/2,S=n.offsetY-n.wrapper.actualSize.height/2;if("Vertical"===g.orientation&&(S+=g.header&&g.hasHeader?g.header.height:0),!s)for(r||(n.id+=d,g&&g.header&&g.hasHeader?g.header.id+=d:g.header=void 0),o=0;v&&o0&&s.columnIndex>0||s.isLane)?(a=function mne(n,t,e){for(var i=new Ne,r="SwimLane"===n.shape.type?n.wrapper.children[0].rows:n.wrapper.rows,s=e?1:0;s=0;a--)i?i.id===o.children[parseInt(a.toString(),10)].id&&o.children.splice(a,1):(n.removeDependentConnector(o.children[parseInt(a.toString(),10)]),n.diagramActions&ee.UndoRedo||(n.diagramActions=n.diagramActions|ee.UndoRedo,s=!0),n.remove(o.children[parseInt(a.toString(),10)]),o.children.splice(a,1),s&&(n.diagramActions=n.diagramActions&~ee.UndoRedo))}function hne(n){return n.children[0]}function Gv(n,t){t&&(n.nodes.splice(n.nodes.indexOf(t),1),n.removeFromAQuad(t),n.removeObjectsFromLayer(t),delete n.nameTable[t.id],n.removeElements(t))}function B3(n,t,e,i){var r;if("SwimLane"===e.shape.type){var s=e.shape,o=void 0;if(1===s.lanes.length)n.remove(e);else{var a=e.wrapper.bounds.x,l=e.wrapper.bounds.y,h=void 0,c=void 0,d=void 0,u=void 0,f=e.wrapper.children[0];if(o=i?s.lanes.indexOf(i):zI(e,t),r={element:t,cause:n.diagramActions,diagramAction:n.getDiagramAction(n.diagramActions),state:"Changing",type:"Removal",cancel:!1,laneIndex:o},n.triggerEvent(Ce.collectionChange,r),!r.cancel){var g=s.lanes[parseInt(o.toString(),10)],v=g.children;g.children=[];for(var y=0;y0)for(u=0;u0)for(u=0;u0)for(e=0;e1){c===l.phases.length-1&&(o=!0,a=$(l.phases[c-1]));var u=$(l.phases[parseInt(c.toString(),10)]);if(l.phases.splice(c,1),!(n.diagramActions&ee.UndoRedo)){var p={type:"PhaseCollectionChanged",changeType:"Remove",undoObject:u,previousPhase:a,redoObject:$(t),category:"Internal",isLastPhase:o};n.addHistoryEntry(p)}"Horizontal"===l.orientation?function dne(n,t,e,i){var r,s,o,a,l,h,c,d,u,p,f,g;for(i=void 0!==i?i:e.columnIndex,c=0;c1&&(s=r.cells[parseInt(i.toString(),10)],l=(o=r.cells.length-1===i?r.cells[i-1]:r.cells[i+1]).children[0],s.children.length>0))if(f=n.nameTable[(a=s.children[0]).id],0===o.children.length&&s.children.length>0)o.children=s.children,o.columnSpan=s.columnSpan-1;else{for(d=0;d0){var M=s.children[0],w=n.nameTable[M.id];if(i=e.x&&a.bounds.y<=e.y&&a.bounds.bottom>=e.y)&&!(t.constraints&ie.AllowMovingOutsideLane)){var l=$(t);n.clearSelection(),j3(n,t),t.parentId="",t.parentObj=n,t.propName="nodes";var h={type:"ChildCollectionChanged",category:"Internal",undoObject:l,redoObject:$(t)};n.addHistoryEntry(h),n.commandHandler.isContainer&&(n.commandHandler.isContainer=!1,n.endGroupAction()),V3(t,n)}n.protectPropertyChange(o)}}function FI(n,t){var e,i,r;return n.enableServerDataBinding(!1),ce()||(n.selectedObject.helperObject?r=n.selectedObject.helperObject:(n.selectedItems.nodes.length>0||n.selectedItems.connectors.length>0)&&(t instanceof si&&t.nodes.length+t.connectors.length===1?(e=t.nodes.length>0?t.nodes[0]:t.connectors[0],i=n.selectedItems.wrapper.children[0]):(e=t,i=n.selectedItems.wrapper),n.selectedObject.actualObject=e,!n.currentSymbol&&(e.isLane&&jx(e,n)&&cs(n,e)||!e.isLane&&cs(n,e)||n.constraints&rt.LineRouting&&n.selectedItems.nodes.length>0))&&(r=function yne(n,t){for(var e,i={},r=0,s=Object.keys(t);r=t.x-e&&n.x<=t.x+e&&n.y>=t.y-e&&n.y<=t.y+e}function Xa(n){return n.selectedItems.nodes.length>0||n.selectedItems.connectors.length>0}function Y3(n){return 1===n.selectedItems.connectors.length&&!n.selectedItems.nodes.length}function _r(n,t,e,i){if(void 0===e&&(e=!0),t instanceof si)return!0;if(t instanceof te)for(;t;){if(-1!==n.selectedItems.nodes.indexOf(t)&&void 0===n.selectedItems.annotation)return!0;if(e)break;t=n.nameTable[t.parentId]}else if(t instanceof de){if(-1!==n.selectedItems.connectors.indexOf(t)&&void 0===n.selectedItems.annotation)return!0}else if((t instanceof Zn||t instanceof Nr)&&n.selectedItems.annotation&&n.selectedItems.wrapper.children[0].id===i.id)return!0;return!1}var Vx={None:"default",Rotate:"crosshair",Select:"default",Drag:"move",ResizeWest:"w-resize",ResizeEast:"e-resize",ResizeSouth:"s-resize",ResizeNorth:"n-resize",Draw:"crosshair",PortDraw:"crosshair",ResizeNorthEast:"ne-resize",ResizeNorthWest:"nw-resize",ResizeSouthEast:"se-resize",ResizeSouthWest:"sw-resize",ConnectorSourceEnd:"move",ConnectorTargetEnd:"move",BezierSourceThumb:"move",BezierTargetThumb:"move",OrthoThumb:"move",SegmentEnd:"move",Pan:"grab",Hyperlink:"pointer",PortDrag:"pointer",LabelSelect:"pointer",LabelDrag:"move",LabelRotate:"crosshair",LabelResizeWest:"w-resize",LabelResizeEast:"e-resize",LabelResizeSouth:"s-resize",LabelResizeNorth:"n-resize",LabelResizeNorthEast:"ne-resize",LabelResizeNorthWest:"nw-resize",LabelResizeSouthEast:"se-resize",LabelResizeSouthWest:"sw-resize"},ds=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Ld=function(n,t,e,i){return new(e||(e=Promise))(function(r,s){function o(h){try{l(i.next(h))}catch(c){s(c)}}function a(h){try{l(i.throw(h))}catch(c){s(c)}}function l(h){h.done?r(h.value):new e(function(c){c(h.value)}).then(o,a)}l((i=i.apply(n,t||[])).next())})},Nd=function(n,t){var i,r,s,o,e={label:0,sent:function(){if(1&s[0])throw s[1];return s[1]},trys:[],ops:[]};return o={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function a(h){return function(c){return function l(h){if(i)throw new TypeError("Generator is already executing.");for(;e;)try{if(i=1,r&&(s=2&h[0]?r.return:h[0]?r.throw||((s=r.return)&&s.call(r),0):r.next)&&!(s=s.call(r,h[1])).done)return s;switch(r=0,s&&(h=[2&h[0],s.value]),h[0]){case 0:case 1:s=h;break;case 4:return e.label++,{value:h[1],done:!1};case 5:e.label++,r=h[1],h=[0];continue;case 7:h=e.ops.pop(),e.trys.pop();continue;default:if(!(s=(s=e.trys).length>0&&s[s.length-1])&&(6===h[0]||2===h[0])){e=0;continue}if(3===h[0]&&(!s||h[1]>s[0]&&h[1]-1&&(r=i.fixedUserHandles[parseInt(o.toString(),10)]);this.commandHandler.triggerEvent(Ce.fixedUserHandleClick,{fixedUserHandle:r,element:e.source}),n.prototype.mouseUp.call(this,e)},t}(us),Od=function(n){function t(e,i){var r=n.call(this,e,!0)||this;return r.isConnected=!1,r.endPoint=i,r}return ds(t,n),t.prototype.mouseDown=function(e){return Ld(this,void 0,void 0,function(){var r,s,o,a,l;return Nd(this,function(h){if(this.inAction=!0,this.undoElement=void 0,this instanceof pa||(this.undoElement=$(e.source)),n.prototype.mouseDown.call(this,e),e.source&&e.source.connectors&&(this.oldConnector=$(r=e.source.connectors[0])),"BezierSourceThumb"===this.endPoint||"BezierTargetThumb"===this.endPoint)for(s=0;s0))},t.prototype.endAction=function(){n.prototype.endAction.call(this),this.prevPosition=null,this.endPoint=null},t}(us),ua=function(n){function t(e,i){var r=n.call(this,e,!0)||this;return r.currentTarget=null,r.isStartAction=!1,r.canCancel=!1,r.canTrigger=!1,r.objectType=i,r}return ds(t,n),t.prototype.mouseDown=function(e){if(e.source instanceof te||e.source instanceof de){var i=this.commandHandler.getSelectedObject();this.commandHandler.selectObjects([e.source],e.info&&e.info.ctrlKey,i);var r={nodes:[],connectors:[]};e.source instanceof te?r.nodes.push($(e.source)):r.connectors.push($(e.source)),this.undoElement=$(r)}else this.undoElement=$(e.source);this.undoParentElement=this.commandHandler.getSubProcess(e.source),"Port"===this.objectType&&(this.portId=e.sourceWrapper.id),this.commandHandler.insertBlazorConnector(e.source),n.prototype.mouseDown.call(this,e),this.initialOffset={x:0,y:0}},t.prototype.mouseUp=function(e,i){return Ld(this,void 0,void 0,function(){var s,o,a,l,h,c,d,u,f,g,v,y,S,b,M;return Nd(this,function(w){if(this.checkPropertyValue(),a=!1,h={nodes:[],connectors:[]},"Port"!==this.objectType){if(e.source instanceof te||e.source instanceof de?(e.source instanceof te?h.nodes.push($(e.source)):h.connectors.push($(e.source)),(o=$(h)).offsetX=(c=e.source.wrapper).offsetX,o.offsetY=c.offsetY):o=$(e.source),("helper"===(l=this.commandHandler.renderContainerHelper(e.source)||e.source||this.commandHandler.renderContainerHelper(e.source)).id||"helper"!==l.id)&&((l instanceof si&&(Math.round(l.width)===Math.round(this.undoElement.width)&&Math.round(l.height)===Math.round(this.undoElement.height)||l.selectedObjects&&1===l.selectedObjects.length)||!(l instanceof si))&&(l.offsetX!==this.undoElement.offsetX||l.offsetY!==this.undoElement.offsetY||l.sourcePoint!==this.undoElement.sourcePoint||l.targetPoint!==this.undoElement.targetPoint)||this.isSelectionHasConnector(l))&&(e.source&&(s={offsetX:e.source.wrapper.offsetX,offsetY:e.source.wrapper.offsetY}),g={source:e.source,state:"Completed",oldValue:this.intialValue,newValue:s,target:this.currentTarget,targetPosition:this.currentPosition,allowDrop:(g={source:e.source,state:"Completed",oldValue:this.intialValue,newValue:s,target:this.currentTarget,targetPosition:this.currentPosition,allowDrop:!0,cancel:!1}).allowDrop,cancel:g.cancel},d=!0,"helper"===l.id?this.canTrigger?(this.commandHandler.triggerEvent(Ce.positionChange,g),this.connectorEndPointChangeEvent(g),d=!0):d=!1:(this.commandHandler.triggerEvent(Ce.positionChange,g),this.connectorEndPointChangeEvent(g)),!i&&d&&(this.commandHandler.startGroupAction(),a=!0,M={type:"PositionChanged",redoObject:$(o),undoObject:$(this.undoElement),category:"Internal"},o.nodes[0]&&o.nodes[0].processId&&(u={type:"SizeChanged",category:"Internal",undoObject:this.undoParentElement,redoObject:this.commandHandler.getSubProcess(e.source)},this.commandHandler.addHistoryEntry(u)),this.commandHandler.addHistoryEntry(M))),this.commandHandler.snapPoint(this.prevPosition,this.currentPosition,0,0),this.commandHandler.removeSnap(),this.commandHandler.removeHighlighter(),e.source&&this.currentTarget&&LI(this.currentTarget)&&this.commandHandler.isDroppable(e.source,this.currentTarget)){if(f=!0,this.commandHandler.drop(this.currentElement,this.currentTarget,this.currentPosition),this.currentTarget&&this.currentTarget instanceof de&&!0===this.commandHandler.diagram.enableConnectorSplit)if(this.currentElement&&this.currentElement instanceof te){if(void 0!==this.currentElement.children)for(b=0;b0)for(var s=0;s0)for(var a=0;a0)for(a=0;a0&&e.connectors.length>0)||e.width===this.undoElement.width&&e.height===this.undoElement.height)},t.prototype.mouseMove=function(e){n.prototype.mouseMove.call(this,e);var r,s,i=!1;(r=this.commandHandler.renderContainerHelper(e.source)||e.source)instanceof te||r instanceof de?r instanceof te?r.offsetX===this.undoElement.nodes[0].offsetX&&r.offsetY===this.undoElement.nodes[0].offsetY&&(i=!0):z.equals(r.sourcePoint,this.undoElement.connectors[0].sourcePoint)&&z.equals(r.targetPoint,this.undoElement.connectors[0].targetPoint)&&(i=!0):r.wrapper.offsetX===this.undoElement.wrapper.offsetX&&r.wrapper.offsetY===this.undoElement.wrapper.offsetY&&(i=!0),r&&(s={offsetX:r.wrapper.offsetX,offsetY:r.wrapper.offsetY});var o={source:r,state:"Start",oldValue:s,newValue:s,target:e.target,targetPosition:e.position,allowDrop:!0,cancel:!1};if(o={source:r,state:"Start",oldValue:s,newValue:s,target:e.target,targetPosition:e.position,allowDrop:o.allowDrop,cancel:o.cancel},this.isStartAction||(this.intialValue={offsetX:r.wrapper.offsetX,offsetY:r.wrapper.offsetY}),i&&!ce()&&(this.commandHandler.triggerEvent(Ce.positionChange,o),this.connectorEndPointChangeEvent(o),this.isStartAction=!0),this.currentPosition=e.position,"Port"!==this.objectType){var h=this.initialOffset.x+(this.currentPosition.x-this.prevPosition.x),c=this.initialOffset.y+(this.currentPosition.y-this.prevPosition.y);this.commandHandler.dragOverElement(e,this.currentPosition),this.commandHandler.disConnect(e.source),this.commandHandler.removeSnap();var d,u=void 0,p=this.commandHandler.snapPoint(this.prevPosition,this.currentPosition,h,c);this.initialOffset.x=h-p.x,this.initialOffset.y=c-p.y,r&&(d={offsetX:r.wrapper.offsetX,offsetY:r.wrapper.offsetY},u={offsetX:r.wrapper.offsetX+p.x,offsetY:r.wrapper.offsetY+p.y}),this.currentTarget&&e.target!==this.currentTarget&&this.commandHandler.removeChildFromBPmn(e.source,e.target,this.currentTarget),this.currentTarget=e.target;var f={source:r,state:"Progress",oldValue:d,newValue:u,target:e.target,targetPosition:e.position,allowDrop:!0,cancel:!1};if(this.commandHandler.triggerEvent(Ce.positionChange,f),this.canTrigger=!0,this.connectorEndPointChangeEvent(f,p),!f.cancel&&!this.canCancel){this.blocked=!this.commandHandler.dragSelectedObjects(p.x,p.y);var g=!this.commandHandler.mouseOver(this.currentElement,this.currentTarget,this.currentPosition);this.blocked=this.blocked||g}if(this.commandHandler.removeStackHighlighter(),this.commandHandler.renderStackHighlighter(e),this.currentTarget&&e.source!==this.currentTarget&&this.commandHandler.isDroppable(e.source,this.currentTarget)&&"helper"!==e.source.id){var v=e.source instanceof si?e.source.nodes[0]:e.source;!this.commandHandler.isParentAsContainer(v,!0)&&"SwimLane"!==v.shape.type&&!v.shape.isPhase&&(this.currentTarget.isLane?this.commandHandler.renderStackHighlighter(e,this.currentTarget):this.commandHandler.drawHighlighter(this.currentTarget))}else this.commandHandler.removeHighlighter();if(this.commandHandler.canEnableDefaultTooltip()){var y=this.getTooltipContent(e.source);this.commandHandler.showTooltip(e.source,e.position,ko(function(){return y}),"MoveTool",this.isTooltipVisible),this.isTooltipVisible=!1}}else{var b=Hi(),M=e.source;qi(b,-M.rotateAngle||-M.wrapper.rotateAngle,M.offsetX||M.wrapper.offsetX,M.offsetY||M.wrapper.offsetY);var w=Je(b,{x:this.prevPosition.x,y:this.prevPosition.y}),C=Je(b,{x:e.position.x,y:e.position.y});this.commandHandler.portDrag(e.source,e.sourceWrapper,C.x-w.x,C.y-w.y)}return this.prevPosition=this.currentPosition,!this.blocked},t.prototype.getTooltipContent=function(e){return"X:"+Math.round(e.wrapper.bounds.x)+" Y:"+Math.round(e.wrapper.bounds.y)},t.prototype.mouseLeave=function(e){this.mouseUp(e)},t.prototype.endAction=function(){n.prototype.endAction.call(this),this.currentTarget=null,this.prevPosition=null},t}(us),Wx=function(n){function t(e){var i=n.call(this,e,!0)||this;return i.rotateStart=!1,i}return ds(t,n),t.prototype.mouseDown=function(e){if(this.undoElement=$(e.source),this.undoElement.nodes[0]&&this.undoElement.nodes[0].children)for(var r=this.commandHandler.getAllDescendants(this.undoElement.nodes[0],[]),s=0;s=2){var s=e.startTouches[0],o=e.startTouches[1],a=e.moveTouches[0],l=e.moveTouches[1],h=this.getDistance(a,l)/this.getDistance(s,o);this.commandHandler.zoom(h,0,0,e.position),this.updateTouch(s,a),this.updateTouch(o,l)}}else this.commandHandler.scroll(this.currentPosition.x-this.prevPosition.x,this.currentPosition.y-this.prevPosition.y,this.currentPosition);return this.commandHandler.dataBinding(),!this.blocked},t.prototype.mouseUp=function(e){this.commandHandler.setBlazorDiagramProps(!1),this.checkPropertyValue(),this.commandHandler.updatePanState(!1),n.prototype.mouseUp.call(this,e),this.inAction=!1},t.prototype.endAction=function(){n.prototype.endAction.call(this)},t.prototype.getDistance=function(e,i){var r=i.pageX-e.pageX,s=i.pageY-e.pageY;return Math.sqrt(r*r+s*s)},t.prototype.updateTouch=function(e,i){e.pageX=i.pageX,e.pageY=i.pageY},t}(us),Tne=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseUp=function(e){this.checkPropertyValue(),this.commandHandler.initExpand(e),n.prototype.mouseUp.call(this,e)},t}(us),Q3=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseUp=function(e){this.checkPropertyValue();var i="_blank",r="",s=window.innerHeight,o=window.innerWidth,a=window.screenTop,l=window.screenLeft;"CurrentTab"===e.sourceWrapper.hyperlink.hyperlinkOpenState?i="_self":"NewWindow"===e.sourceWrapper.hyperlink.hyperlinkOpenState&&(r="height="+s+",width="+o+",top="+a+",left="+l),window.open(e.sourceWrapper.hyperlink.link,i,r).focus(),n.prototype.mouseUp.call(this,e)},t}(us),Oh=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseDown=function(e){if(n.prototype.mouseDown.call(this,e),this.inAction=!0,this.drawingObject){var r=void 0,s=this.drawingObject.shape;this.drawingObject.shape.points.push(r={x:(r=s.points[s.points.length-1]).x,y:r.y})}else this.startPoint={x:this.startPosition.x,y:this.startPosition.y},this.drawingObject=this.commandHandler.drawObject({offsetX:this.currentPosition.x,offsetY:this.currentPosition.y,width:5,height:5,style:{strokeColor:"black",strokeWidth:1},shape:{type:"Basic",shape:"Polygon",points:[{x:this.startPoint.x,y:this.startPoint.y},{x:this.currentPosition.x,y:this.currentPosition.y}]}})},t.prototype.mouseMove=function(e){if(n.prototype.mouseMove.call(this,e),this.inAction){var i=this.drawingObject.shape;if(i.points[i.points.length-1].x=this.currentPosition.x,i.points[i.points.length-1].y=this.currentPosition.y,this.drawingObject.wrapper.children[0].data=gx(this.drawingObject.shape.points),this.inAction&&!1===z.equals(this.currentPosition,this.prevPosition)){var r=Ne.toBounds(this.drawingObject.shape.points);this.commandHandler.updateNodeDimension(this.drawingObject,r)}}return!0},t.prototype.mouseUp=function(e,i){this.checkPropertyValue(),n.prototype.mouseMove.call(this,e),this.inAction&&(this.inAction=!1,this.commandHandler.addObjectToDiagram(this.drawingObject)),this.endAction()},t.prototype.mouseWheel=function(e){n.prototype.mouseWheel.call(this,e),this.mouseMove(e)},t.prototype.endAction=function(){this.inAction=!1,this.drawingObject=null},t}(us),kh=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseMove=function(e){if(n.prototype.mouseMove.call(this,e),this.inAction){var i=this.drawingObject;i.targetPoint=this.currentPosition,this.commandHandler.updateConnectorPoints(i)}return!0},t.prototype.mouseDown=function(e){if(n.prototype.mouseDown.call(this,e),this.inAction=!0,this.drawingObject){var r=this.drawingObject,s=void 0;(s=new kl(r,"segments",{type:"Straight"},!0)).point=this.currentPosition,r.segments[r.segments.length-1]=s}else this.drawingObject=this.commandHandler.drawObject({id:"Connector",type:"Straight",sourcePoint:this.currentPosition,targetPoint:this.currentPosition})},t.prototype.mouseWheel=function(e){n.prototype.mouseWheel.call(this,e),this.mouseMove(e)},t.prototype.mouseUp=function(e){if(this.checkPropertyValue(),n.prototype.mouseMove.call(this,e),this.inAction&&this.drawingObject){var i=this.drawingObject;i.segments[i.segments.length-1].point={x:0,y:0},this.commandHandler.addObjectToDiagram(this.drawingObject)}this.endAction()},t.prototype.endAction=function(){this.drawingObject=null,this.inAction=!1},t}(us),Ane=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseDown=function(e){this.inAction=!0,this.undoElement=$(e.source),this.annotationId=e.sourceWrapper.id,n.prototype.mouseDown.call(this,e)},t.prototype.mouseMove=function(e){n.prototype.mouseMove.call(this,e);var i=this.currentPosition.x-this.prevPosition.x,r=this.currentPosition.y-this.prevPosition.y,s=e.source;if(s instanceof te){var o=Hi();qi(o,-s.rotateAngle,0,0);var a=Je(o,{x:i,y:r});i=a.x,r=a.y}return this.inAction&&(this.commandHandler.labelDrag(e.source,e.sourceWrapper,i,r),this.commandHandler.updateSelector()),this.prevPosition=this.currentPosition,!this.blocked},t.prototype.mouseUp=function(e){this.checkPropertyValue();var i=e.source;this.inAction=!1;var r={type:"AnnotationPropertyChanged",objectId:this.annotationId,undoObject:$(this.undoElement),category:"Internal",redoObject:$(i)};this.commandHandler.addHistoryEntry(r),n.prototype.mouseUp.call(this,e)},t.prototype.mouseLeave=function(e){this.mouseUp(e)},t}(us),Lne=function(n){function t(e,i){var r=n.call(this,e,!0)||this;return r.corner=i,r}return ds(t,n),t.prototype.mouseDown=function(e){this.inAction=!0;var i=e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0];this.annotationId=e.source.wrapper.children[0].id,this.undoElement=$(i);var r=e.source.wrapper.children[0];this.initialBounds={x:r.offsetX,y:r.offsetY,width:r.actualSize.width,height:r.actualSize.height},n.prototype.mouseDown.call(this,e)},t.prototype.mouseMove=function(e){return n.prototype.mouseMove.call(this,e),this.inAction&&this.resizeObject(e),!this.blocked},t.prototype.mouseUp=function(e){this.checkPropertyValue();var i=e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0];this.inAction=!1;var r={type:"AnnotationPropertyChanged",objectId:this.annotationId,redoObject:$(i),undoObject:$(this.undoElement),category:"Internal"};this.commandHandler.addHistoryEntry(r),n.prototype.mouseUp.call(this,e)},t.prototype.mouseLeave=function(e){this.mouseUp(e)},t.prototype.resizeObject=function(e){var i,s,o,r=e.source.wrapper.children[0],a={x:r.offsetX,y:r.offsetY},l=r.rotateAngle;l=((l+=(i=e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0])instanceof te?i.rotateAngle:0)+360)%360;var h=Hi();qi(h,l,a.x,a.y);var c=this.corner.slice(5),d=this.updateSize(r,this.startPosition,this.currentPosition,c,this.initialBounds,l),u=r.offsetX-r.actualSize.width*r.pivot.x,p=r.offsetY-r.actualSize.height*r.pivot.y,f=this.getPivot(c),g=Je(h,f={x:u+r.actualSize.width*f.x,y:p+r.actualSize.height*f.y});d.x=g.x,d.y=g.y,this.commandHandler.labelResize(i,e.source.annotation,s=(s=d.width)<0?1:s,o=(o=d.height)<0?1:o,d,e.source),this.commandHandler.updateSelector()},t}(us),Nne=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseDown=function(e){this.inAction=!0,this.annotationId=e.source.wrapper.children[0].id,this.undoElement=$(e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0]),n.prototype.mouseDown.call(this,e)},t.prototype.mouseMove=function(e){return n.prototype.mouseMove.call(this,e),e.source&&this.inAction&&(this.commandHandler.labelRotate(e.source.nodes[0]?e.source.nodes[0]:e.source.connectors[0],e.source.annotation,this.currentPosition,e.source),this.commandHandler.updateSelector()),this.prevPosition=this.currentPosition,!this.blocked},t.prototype.mouseUp=function(e){this.checkPropertyValue(),this.inAction=!1;var r={type:"AnnotationPropertyChanged",objectId:this.annotationId,redoObject:$(e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0]),undoObject:$(this.undoElement),category:"Internal"};this.commandHandler.addHistoryEntry(r),n.prototype.mouseUp.call(this,e)},t.prototype.mouseLeave=function(e){this.mouseUp(e)},t}(us),One=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseMove=function(e){if(n.prototype.mouseMove.call(this,e),this.inAction){var i=this.drawingObject.shape;if(i.points.push(this.currentPosition),this.drawingObject.wrapper.children[0].data=vx(this.drawingObject.shape.points),i.data=vx(i.points),this.inAction&&!1===z.equals(this.currentPosition,this.prevPosition)){var s=Ne.toBounds(this.drawingObject.shape.points);this.commandHandler.updateNodeDimension(this.drawingObject,s)}}return!0},t.prototype.mouseDown=function(e){n.prototype.mouseDown.call(this,e),this.inAction=!0,this.startPoint={x:this.startPosition.x,y:this.startPosition.y},this.drawingObject=this.commandHandler.drawObject({offsetX:this.currentPosition.x,offsetY:this.currentPosition.y,width:5,height:5,style:{strokeColor:"black",strokeWidth:1,fill:"transparent"},shape:{type:"Path",points:[{x:this.startPoint.x,y:this.startPoint.y},{x:this.currentPosition.x,y:this.currentPosition.y}]}})},t.prototype.mouseUp=function(e){if(this.checkPropertyValue(),this.inAction){this.inAction=!1;var s=this.drawingObject.shape,o=s.points;this.commandHandler.addObjectToDiagram(this.drawingObject),this.commandHandler.diagram.remove(this.commandHandler.diagram.nameTable[""+this.drawingObject.id]),o=this.pointReduction(o,10);var h={id:"newConnector"+Qe(),type:"Bezier",sourcePoint:{x:o[0].x,y:o[0].y},targetPoint:{x:o[o.length-1].x,y:o[o.length-1].y},segments:[],bezierSettings:{allowSegmentsReset:!1}};this.drawingObject=this.commandHandler.drawObject(h),this.drawingObject=this.bezierCurveSmoothness(o,.5,this.drawingObject,s),this.commandHandler.updateConnectorPoints(this.drawingObject),this.commandHandler.addObjectToDiagram(this.drawingObject),n.prototype.mouseUp.call(this,e)}},t.prototype.pointReduction=function(e,i){if(null===e||e.length<3)return e;var s=e.length-1,o=[];for(o.push(0),o.push(s);e[parseInt((0).toString(),10)]===e[parseInt(s.toString(),10)];)s--;this.reduction(e,0,s,i,o);var a=[];return o.sort(function(l,h){return l-h}),o.forEach(function(l){a.push(e[parseInt(l.toString(),10)])}),a},t.prototype.reduction=function(e,i,r,s,o){for(var a=0,l=0,h=i;ha&&(a=c,l=h)}a>s&&0!==l&&(o.push(l),this.reduction(e,i,l,s,o),this.reduction(e,l,r,s,o))},t.prototype.perpendicularDistance=function(e,i,r){return Math.abs(.5*(e.x*i.y-i.x*e.y+(i.x*r.y-r.x*i.y)+(r.x*e.y-e.x*r.y)))/Math.sqrt(Math.pow(e.x-i.x,2)+Math.pow(e.y-i.y,2))*2},t.prototype.bezierCurveSmoothness=function(e,i,r,s){if(e.length<3)return r;for(var o=0;o=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},kne=function(n){if(n)switch(n.type){case"Bpmn":return Hne;case"UmlActivity":return Rne;case"UmlClassifier":return _ne;default:return Zv}return Zv},Pne=function(n){if(n)switch(n.type){case"Straight":default:return kl;case"Bezier":return ps;case"Orthogonal":return bi}},G3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I(10)],t.prototype,"width",void 0),Pe([I(10)],t.prototype,"height",void 0),Pe([I("Arrow")],t.prototype,"shape",void 0),Pe([re({fill:"black",strokeColor:"black",strokeWidth:1},Al)],t.prototype,"style",void 0),Pe([re({x:0,y:.5},z)],t.prototype,"pivot",void 0),Pe([I("")],t.prototype,"pathData",void 0),t}(Ee),VI=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I(0)],t.prototype,"angle",void 0),Pe([I(0)],t.prototype,"distance",void 0),t}(Ee),zne=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I(Ix.All)],t.prototype,"controlPointsVisibility",void 0),Pe([I("FreeForm")],t.prototype,"segmentEditOrientation",void 0),Pe([I(gI.Default)],t.prototype,"smoothness",void 0),Pe([I(!0)],t.prototype,"allowSegmentsReset",void 0),t}(Ee),Zv=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I("None")],t.prototype,"type",void 0),t}(Ee),Rne=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I("Object")],t.prototype,"flow",void 0),Pe([I(30)],t.prototype,"exceptionFlowHeight",void 0),t}(Zv),Hne=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I("Sequence")],t.prototype,"flow",void 0),Pe([I("Normal")],t.prototype,"sequence",void 0),Pe([I("Default")],t.prototype,"message",void 0),Pe([I("Default")],t.prototype,"association",void 0),t}(Zv),X3=function(n){function t(e,i,r,s){var o=n.call(this,e,i,r,s)||this;return o.points=[],o}return Qs(t,n),Pe([I("Straight")],t.prototype,"type",void 0),Pe([I(!0)],t.prototype,"allowDrag",void 0),t}(Ee),kl=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),t.prototype.getClassName=function(){return"StraightSegment"},Pe([re({x:0,y:0},z)],t.prototype,"point",void 0),t}(X3),ps=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),t.prototype.getClassName=function(){return"BezierSegment"},t.prototype.getPoints=function(e,i){var r=[];if(r.length>0||null!=i){var o=this.bezireToPoly(r.length>0?r[r.length-1]:i,e);r.push.apply(r,o)}return r},t.prototype.bezireToPoly=function(e,i){var r=[];return i&&this.flattenCubicBezier(r,e,i.bezierPoint1,i.bezierPoint2,{x:i.points[1].x,y:i.points[1].y},10),r},t.prototype.flattenCubicBezier=function(e,i,r,s,o,a){var h,l=(z.findLength(i,r)+z.findLength(r,s)+z.findLength(s,o))/a;for(h=0;h<=l;h++){var c=h/l;e.push({x:(1-c)*(1-c)*(1-c)*i.x+3*c*(1-c)*(1-c)*r.x+3*c*c*(1-c)*s.x+c*c*c*o.x,y:(1-c)*(1-c)*(1-c)*i.y+3*c*(1-c)*(1-c)*r.y+3*c*c*(1-c)*s.y+c*c*c*o.y})}},Pe([I("Horizontal")],t.prototype,"orientation",void 0),Pe([re({x:0,y:0},z)],t.prototype,"point1",void 0),Pe([re({x:0,y:0},z)],t.prototype,"point2",void 0),Pe([re({angle:0,distance:0},VI)],t.prototype,"vector1",void 0),Pe([re({angle:0,distance:0},VI)],t.prototype,"vector2",void 0),t}(kl),bi=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),t.prototype.getClassName=function(){return"OrthogonalSegment"},Pe([I(null)],t.prototype,"length",void 0),Pe([I(null)],t.prototype,"direction",void 0),t}(X3);function q3(n,t,e){var s=e?45:180/(2+2/(n.height/n.width)),o=s,a=180-s,l=a+2*s,h=360-s,c=Gt(t,n.center);return c>o&&ca&&cl&&cMath.abs(t.y-n.y)?n.x=c)return s=z.findAngle(n[parseInt(d.toString(),10)],n[d+1]),{point:r=z.transform(n[parseInt(d.toString(),10)],s,c-(a||0)),index:l=d};a=o[parseInt(d.toString(),10)]}return{point:r,index:l}}(n,t),r=z.findAngle(n[i.index],n[i.index+1]),s=function fse(n){var e=0;switch(n.alignment){case"Center":case"After":e=0;break;case"Before":e=-0}return e}(t),o=z.transform(i.point,r+45,s);return i.point=o,i.angle=r,i}(i,e),h=l.point;s.id=this.id+"_"+e.id;var c=e.style;s.style={fill:c.fill,strokeColor:c.strokeColor,gradient:null,opacity:c.opacity,strokeDashArray:c.strokeDashArray,strokeWidth:c.strokeWidth},0===r.width&&(r.width=this.style.strokeWidth),0===r.height&&(r.height=this.style.strokeWidth);var d_y=(h.y-r.y)/r.height;a.x=r.width*((h.x-r.x)/r.width),a.y=r.height*d_y;var g,v,u=dF(e,l.angle,i),p=u.hAlign,f=u.vAlign;return"left"===p?(g="Left",a.x+=e.displacement.x):"right"===p?(g="Right",a.x-=e.displacement.x):"center"===p&&(g="Center"),"top"===f?(v="Top",a.y+=e.displacement.y):"bottom"===f?(v="Bottom",a.y-=e.displacement.y):"center"===f&&(v="Center"),s.horizontalAlignment=g,s.verticalAlignment=v,(s=em(s,o&&"Label"!==o.flipMode&&"None"!==o.flipMode?this.flip:"None",e)).float=!0,s.connectionDirection=e.connectionDirection,s.setOffsetWithRespectToBounds(a.x,a.y,"Absolute"),s.relativeMode="Point",s.visible=!(!ga(e,hi.Visible)||ga(e,hi.Hover)||ga(e,hi.Connect)),s.elementActions=s.elementActions|Xr.ElementIsPort,s},t.prototype.getConnectorRelation=function(){var e=this.shape;"Association"===e.relationship?(this.segments[0].type="Straight",this.sourceDecorator.shape="None",this.targetDecorator.shape="Arrow"):"Inheritance"===e.relationship?(this.segments[0].type="Orthogonal",this.sourceDecorator.shape="None",this.targetDecorator.shape="Arrow"):"Composition"===e.relationship||"Aggregation"===e.relationship?(this.segments[0].type="Orthogonal",this.sourceDecorator.shape="Diamond",this.targetDecorator.shape="None"):"Dependency"===e.relationship?(this.segments[0].type="Orthogonal",this.sourceDecorator.shape="None",this.targetDecorator.shape="OpenArrow"):"Realization"===e.relationship&&(this.segments[0].type="Orthogonal",this.sourceDecorator.shape="None",this.targetDecorator.shape="Arrow"),"BiDirectional"===e.associationType&&(this.sourceDecorator.shape="None",this.targetDecorator.shape="None");var i,o,r="",s="";e.multiplicity.source&&(e.multiplicity.source.lowerBounds=e.multiplicity.source.lowerBounds,e.multiplicity.source.upperBounds=e.multiplicity.source.upperBounds),e.multiplicity.target&&(e.multiplicity.target.lowerBounds=e.multiplicity.target.lowerBounds,e.multiplicity.target.upperBounds=e.multiplicity.target.upperBounds);var a=e.multiplicity.source,l=e.multiplicity.target;o=a.upperBounds?a.lowerBounds+"..."+a.upperBounds:a.lowerBounds,i=l.upperBounds?l.lowerBounds+"..."+l.upperBounds:l.lowerBounds,"ManyToOne"===e.multiplicity.type&&(e.multiplicity.target.optional=!1,r=o||"*",s="1"),"OneToMany"===e.multiplicity.type&&(e.multiplicity.source.optional=!1,s=i||"*",r="1"),"ManyToMany"===e.multiplicity.type&&(r=o||"*",s=i||"*"),"OneToOne"===e.multiplicity.type&&(e.multiplicity.target.optional=!1,e.multiplicity.source.optional=!1,r="1",s="1"),this.annotations=[{id:this.id+"sourcelabel",content:r,offset:0,alignment:"Before",margin:{right:5,bottom:5}},{id:this.id+"targetlabel",content:s,offset:1,alignment:"Before",margin:{right:5,bottom:5}}]},t.prototype.getBpmnSequenceFlow=function(){var e=new Ke,i=new Ke;return"Normal"===this.shape.sequence&&"Bezier"!==this.type&&(this.targetDecorator.shape="Arrow"),"Default"===this.shape.sequence&&(e=this.getSegmentElement(this,e),i=yF(this.intermediatePoints,this),this.targetDecorator.shape="Arrow"),"Conditional"===this.shape.sequence&&(this.targetDecorator.shape="Arrow",this.sourceDecorator.shape="Diamond",i.id=this.id+this.shape.type),i},t.prototype.getUMLObjectFlow=function(){if(this.annotations)for(var e=0;e0&&(this.sourcePoint=o[0],this.targetPoint=o[o.length-1]),o},t.prototype.clipDecorator=function(e,i,r,s){var a,l,o={x:0,y:0},h=i.length,c=z.distancePoints(a=r?i[0]:i[h-1],l=r?i[1]:i[h-2]);c=0===c?1:c;var d=1,u=r?e.sourceWrapper:e.targetWrapper;u&&(d=u.style.strokeWidth,s&&s&ee.DecoratorPropertyChange&&(d=1));var p=d-1;return o.x=Math.round(a.x+p*(l.x-a.x)/c),o.y=Math.round(a.y+p*(l.y-a.y)/c),(r&&"None"!==e.sourceDecorator.shape||!r&&"None"!==e.targetDecorator.shape)&&(o=z.adjustPoint(o,l,!0,s&ee.DecoratorPropertyChange?0:d/2)),o},t.prototype.clipDecorators=function(e,i,r){return"None"!==e.sourceDecorator.shape&&(i[0]=this.clipDecorator(e,i,!0,r)),"None"!==e.targetDecorator.shape&&(i[i.length-1]=this.clipDecorator(e,i,!1,r)),i},t.prototype.updateSegmentElement=function(e,i,r,s){var o=new Ne,a=this.getSegmentPath(e,i,s);if("Bezier"===e.type){if(this.segments.length>0)for(var l=0;l0)if("Straight"===e.type&&e.segments.length<2)for(var o=0;o1)for(o=0;o0&&"Bezier"!==this.type)for(var p=0;p0&&(a=p0&&(f<2*this.cornerRadius?(l=z.adjustPoint(h[parseInt(p.toString(),10)],h[p+1],!0,f/2),p0&&(s=this.bridgePath(e,s,p),"Orthogonal"===e.type&&(s=this.bridgePath(e,s,p+1))),s+=" L"+a.x+" "+a.y))}else if("Bezier"===this.type){var g=void 0,v=void 0;if(this.parentObj.element){var y=this.parentObj.element.ej2_instances[0].eventHandler.action;g=this.parentObj.element.ej2_instances[0].eventHandler.tool instanceof kd,v=y.includes("PortDraw")||y.includes("Drag")}for(var S=void 0,b=this.segments,M=0;M2&&(b[parseInt(M.toString(),10)].bezierPoint1={x:0,y:0},b[parseInt(M.toString(),10)].bezierPoint2={x:0,y:0}),!z.isEmptyPoint(b[parseInt(M.toString(),10)].point1)||b[parseInt(M.toString(),10)].vector1.angle||b[parseInt(M.toString(),10)].vector1.distance?b[parseInt(M.toString(),10)].vector1.angle||b[parseInt(M.toString(),10)].vector1.distance?b[parseInt(M.toString(),10)].bezierPoint1=z.transform(h[parseInt(M.toString(),10)],b[parseInt(M.toString(),10)].vector1.angle,b[parseInt(M.toString(),10)].vector1.distance):b[parseInt(M.toString(),10)].bezierPoint1={x:b[parseInt(M.toString(),10)].point1.x||b[parseInt(M.toString(),10)].bezierPoint1.x,y:b[parseInt(M.toString(),10)].point1.y||b[parseInt(M.toString(),10)].bezierPoint1.y}:((e.sourceID||this.sourcePortID)&&this.sourceWrapper&&!v&&!g&&(S=q3(this.sourceWrapper.bounds,h[parseInt(M.toString(),10)],!0)),b[parseInt(M.toString(),10)].bezierPoint1=YI(h[parseInt(M.toString(),10)],h[M+1],S)),!z.isEmptyPoint(b[parseInt(M.toString(),10)].point2)||b[parseInt(M.toString(),10)].vector2.angle||b[parseInt(M.toString(),10)].vector2.distance?b[parseInt(M.toString(),10)].vector2.angle||b[parseInt(M.toString(),10)].vector2.distance?b[parseInt(M.toString(),10)].bezierPoint2=z.transform(h[M+1],b[parseInt(M.toString(),10)].vector2.angle,b[parseInt(M.toString(),10)].vector2.distance):b[parseInt(M.toString(),10)].bezierPoint2={x:b[parseInt(M.toString(),10)].point2.x||b[parseInt(M.toString(),10)].bezierPoint2.x,y:b[parseInt(M.toString(),10)].point2.y||b[parseInt(M.toString(),10)].bezierPoint2.y}:((e.targetID||this.targetPortID)&&this.targetWrapper&&!v&&!g&&(S=q3(this.targetWrapper.bounds,h[M+1],!0)),b[parseInt(M.toString(),10)].bezierPoint2=YI(h[M+1],h[parseInt(M.toString(),10)],S));h.splice(1,0,{x:b[0].bezierPoint1.x,y:b[0].bezierPoint1.y}),h.splice(h.length-1,0,{x:b[b.length-1].bezierPoint2.x,y:b[b.length-1].bezierPoint2.y}),h=this.clipDecorators(e,h,r);for(var w=0;w0&&(s=this.bridgePath(e,s,D),s+=" L"+o.x+" "+o.y);return s},t.prototype.updateShapeElement=function(e){var i;switch(e.shape.type){case"Bpmn":e.wrapper.children[3]instanceof Ke&&(i=e.wrapper.children[3]),"Message"===e.shape.flow&&this.updateShapePosition(e,i);break;case"UmlActivity":"Exception"===e.shape.flow&&this.getUMLExceptionFlow(e.wrapper.children[0])}},t.prototype.updateShapePosition=function(e,i){var o=SF(this.intermediatePoints,i,.5);i.offsetX=o.x,i.offsetY=o.y},t.prototype.scale=function(e,i,r,s,o){var a=0,l=0;if(this.wrapper&&this.wrapper.outerBounds){var h=function I3(n){var t=n.wrapper.children[0].bounds;return"None"!==n.sourceDecorator.shape&&t.uniteRect(n.wrapper.children[1].bounds),"None"!==n.targetDecorator.shape&&t.uniteRect(n.wrapper.children[2].bounds),t}(this),c=Math.abs((this.wrapper.bounds.width||this.style.strokeWidth||1)-2),d=Math.abs((this.wrapper.bounds.height||this.style.strokeWidth||1)-2);a=h.width-c,l=h.height-d,e=Math.abs((r-Math.max(a,l))/c),i=Math.abs((s-Math.max(a,l))/d),a=l=Math.min(a,l)}e=i=Math.min(e,i);var u=Hi();qi(u,-(o=o||this.wrapper).rotateAngle,o.offsetX,o.offsetY),Wp(u,e,i,o.offsetX,o.offsetY),qi(u,o.rotateAngle,o.offsetX,o.offsetY);var p=function Tie(n,t){for(var e=[],i=0,r=t;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},jne=function(n){function t(e,i){var r=n.call(this,e,i)||this;return r.offset=0,r.scale=1,r}return Une(t,n),t.prototype.preRender=function(){this.unWireEvents(),this.wireEvents()},t.prototype.render=function(){this.updateRulerGeometry(),this.renderComplete()},t.prototype.getModuleName=function(){return"Ruler"},t.prototype.destroy=function(){this.unWireEvents(),this.notify("destroy",{}),n.prototype.destroy.call(this),this.element.classList.remove("e-ruler")},t.prototype.getPersistData=function(){return this.addOnPersist(["loaded"])},t.prototype.onPropertyChanged=function(e,i){for(var r=0,s=Object.keys(e);r100;)r/=10,s/=10;for(;s<25;)r*=10,s*=10;return s>=25&&s%25!=0&&(s=25*Math.round(s/25)),s*e/r},t.prototype.createMarkerLine=function(e,i,r){var s;return i&&((s=e.getElementById(i.id+"_marker"))&&s.parentNode.removeChild(s),s=Bi("line",r)),s},t.prototype.drawRulerMarker=function(e,i,r){var s,o,h,d,u="Horizontal"===this.orientation,p=e.getElementsByTagName("svg");for(h=0;h0)for(var a=i.childNodes.length-1;a>=0;a--)i.childNodes[parseInt(a.toString(),10)].parentNode.removeChild(i.childNodes[parseInt(a.toString(),10)]);i.appendChild(s)}return s},t.prototype.wireEvents=function(){},t.prototype.unWireEvents=function(){},kc([I(5)],t.prototype,"interval",void 0),kc([I(100)],t.prototype,"segmentWidth",void 0),kc([I("Horizontal")],t.prototype,"orientation",void 0),kc([I("RightOrBottom")],t.prototype,"tickAlignment",void 0),kc([I("red")],t.prototype,"markerColor",void 0),kc([I(25)],t.prototype,"thickness",void 0),kc([I(null)],t.prototype,"arrangeTick",void 0),kc([I(400)],t.prototype,"length",void 0),t}(yi);function J3(n,t){var e=document.getElementById(n.element.id+(t?"_hRuler":"_vRuler")),i=qa(n),r=K3(n);e||(e=Tt("div",{id:n.element.id+(t?"_hRuler":"_vRuler"),style:"height:"+(t?i.height:r.height+100)+"px;overflow:hidden;width:"+(t?r.width+100:i.width)+"px;position:absolute;font-size:11px;"+(t?"margin-left:"+i.width+"px;":"margin-top:"+i.height+"px;")})),n.element.insertBefore(e,n.element.firstChild);var l=t?n.rulerSettings.horizontalRuler:n.rulerSettings.verticalRuler,h=new jne(l);h.orientation=t?"Horizontal":"Vertical",h.length=(t?r.width:r.height)+l.segmentWidth,h.appendTo("#"+n.element.id+(t?"_hRuler":"_vRuler")),t?n.hRuler=h:n.vRuler=h;var c=document.getElementById(n.element.id+(t?"_hRuler":"_vRuler"));t?n.hRuler.element=c:n.vRuler.element=c}function QI(n){var t=-n.scroller.horizontalOffset,e=-n.scroller.verticalOffset;n&&n.rulerSettings.showRulers?(n.hRuler.length=0,n.vRuler.length=0,void 0!==t&&n.hRuler.element&&eF(n,n.hRuler,t,!0),void 0!==e&&n.vRuler.element&&eF(n,n.vRuler,e,!1)):Yx(n)}function Yx(n){an(n.element.id+"_hRuler"),an(n.element.id+"_vRuler"),an(n.element.id+"_overlapRuler")}function qa(n){var t=0,e=0;return n.rulerSettings.showRulers&&(t=n.rulerSettings.horizontalRuler.thickness,e=n.rulerSettings.verticalRuler.thickness),new me(e,t)}function K3(n){var t=qa(n),e=n.scroller.viewPortHeight,i=n.scroller.viewPortWidth;return i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},tF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Xne(t,n),t.prototype.getClassName=function(){return"UserHandle"},Fn([I("")],t.prototype,"name",void 0),Fn([I("")],t.prototype,"pathData",void 0),Fn([I("")],t.prototype,"content",void 0),Fn([I("")],t.prototype,"source",void 0),Fn([I("#000000")],t.prototype,"backgroundColor",void 0),Fn([I("Top")],t.prototype,"side",void 0),Fn([I("")],t.prototype,"borderColor",void 0),Fn([I(.5)],t.prototype,"borderWidth",void 0),Fn([I(25)],t.prototype,"size",void 0),Fn([I("white")],t.prototype,"pathColor",void 0),Fn([I(10)],t.prototype,"displacement",void 0),Fn([I(!0)],t.prototype,"visible",void 0),Fn([I(0)],t.prototype,"offset",void 0),Fn([re({},$n)],t.prototype,"margin",void 0),Fn([I("Center")],t.prototype,"horizontalAlignment",void 0),Fn([I("Center")],t.prototype,"verticalAlignment",void 0),Fn([I(!1)],t.prototype,"disableNodes",void 0),Fn([I(!1)],t.prototype,"disableConnectors",void 0),Fn([re({},Ed)],t.prototype,"tooltip",void 0),Fn([I("")],t.prototype,"template",void 0),t}(Ee);function iF(n){return qne[n.toString()]}var qne={Action:"M 90 82.895 C 90 86.819 86.776 90 82.8 90 H 7.2 C 3.224 90 0 86.819 0 82.895 V 7.105 C 0 3.181 3.224 0 7.2 0 h 75.6 C 86.776 0 90 3.181 90 7.105 V 82.895 Z",Decision:"M10,19.707L0.293,10L10,0.293L19.707,10L10,19.707z",MergeNode:"M10,19.707L0.293,10L10,0.293L19.707,10L10,19.707z",InitialNode:"M10,19.5c-5.238,0-9.5-4.262-9.5-9.5S4.762,0.5,10,0.5s9.5,4.262,9.5,9.5S15.238,19.5,10,19.5z",ForkNode:"m0.75,0.75l636.00002,0l0,290l-636.00002,0l0,-290z",JoinNode:"m0.75,0.75l636.00002,0l0,290l-636.00002,0l0,-290z",TimeEvent:"M50.001,0.00286865 L25.001,25.0029 L0.000976562,0.00286865 L50.001,0.00286865 z M0.000976562,50.0029 L25.001,25.0029 L50.001,50.0029 L0.000976562,50.0029 z",AcceptingEvent:"M17.8336 32.164 L29.64 24 L17.32 16 L48.1664 16 L48.5 32 Z",SendSignal:"M48.164 31.8336 L56 23.832 L47.836 16 L16.168 16 L16.1668 31.8336 Z",ReceiveSignal:"M48.1664 31.8336 L39.836 24 L47.836 16 L16.168 16 L16.168 31.836 Z",StructuredNode:"M0,0 L50,0 L50,50 L0,50 z",Note:"M20 12 L4 12 L4 22 L22 22 L22 14 L20 14 L20 12 L22 14 Z"},GI=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),$a=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},$ne=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return GI(t,n),$a([I()],t.prototype,"key",void 0),$a([I()],t.prototype,"keyModifiers",void 0),t}(Ee),rF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return GI(t,n),t.prototype.getClassName=function(){return"Command"},$a([I("")],t.prototype,"name",void 0),$a([I()],t.prototype,"canExecute",void 0),$a([I()],t.prototype,"execute",void 0),$a([re({},$ne)],t.prototype,"gesture",void 0),$a([I("")],t.prototype,"parameter",void 0),t}(Ee),Zne=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return GI(t,n),$a([Bt([],rF)],t.prototype,"commands",void 0),t}(Ee),Jne=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return GI(t,n),$a([I()],t.prototype,"show",void 0),$a([I()],t.prototype,"showCustomMenuOnly",void 0),$a([I()],t.prototype,"items",void 0),t}(Ee),qp=function(){function n(){}return n.prototype.renderShadow=function(t,e,i,r){void 0===i&&(i=null);var l,o=z.transform({x:0,y:0},t.shadow.angle,t.shadow.distance);r&&(l=r.getElementById(e.id+"_shadow")),l||(l=document.createElementNS("http://www.w3.org/2000/svg",i?"path":"rect"),e.appendChild(l));var h={id:e.id+"_shadow",fill:t.shadow.color,stroke:t.shadow.color,opacity:t.shadow.opacity.toString(),transform:"rotate("+t.angle+","+(t.x+t.width*t.pivotX)+","+(t.y+t.height*t.pivotY)+")translate("+(t.x+o.x)+","+(t.y+o.y)+")"};if(r){var c=r.getElementById(e.id);c&&c.insertBefore(l,c.firstChild)}oi(l,h),i?i&&this.renderPath(l,t,i):oi(l,{width:t.width,height:t.height})},n.prototype.parseDashArray=function(t){return[]},n.prototype.drawRectangle=function(t,e,i,r,s,o,a,l,h){var c,d,u,p;e.shadow&&!r&&this.renderShadow(e,t,void 0,o),c=e.id===t.id?e.id+"_container":e.id,o&&(d=o.getElementById(c)),(!d||s)&&(d=document.createElementNS("http://www.w3.org/2000/svg","rect"),t.appendChild(d)),o&&!e.shadow&&(u=o.getElementById(e.id+"_groupElement_shadow"))&&u.parentNode.removeChild(u),p=l?{id:c,x:e.x.toString(),y:e.y.toString(),width:e.width.toString(),height:e.height.toString(),visibility:e.visible?"visible":"hidden",transform:"rotate("+e.angle+","+(e.x+e.width/2)+","+(e.y+e.height/2)+")",rx:e.cornerRadius||0,ry:e.cornerRadius||0,opacity:e.opacity}:{id:c,x:e.x.toString(),y:e.y.toString(),width:e.width.toString(),height:e.height.toString(),visibility:e.visible?"visible":"hidden",transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")",rx:e.cornerRadius||0,ry:e.cornerRadius||0,opacity:e.opacity},a&&(p.role="img",p["aria-label"]=a);var f=e.class||"";h||(f.includes("e-diagram-resize-handle")||f.includes("e-diagram-endpoint-handle")||f.includes("e-diagram-bezier-control-handle"))&&(f+=" e-disabled"),e.class&&(p.class=f),a||(p["pointer-events"]="none"),oi(d,p),this.setSvgStyle(d,e,i)},n.prototype.updateSelectionRegion=function(t,e){var i;i=t.parentNode.getElementById(e.id);var r={id:e.id,x:e.x.toString(),y:e.y.toString(),width:e.width.toString(),height:e.height.toString(),transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")",class:"e-diagram-selected-region"};i||(i=document.createElementNS("http://www.w3.org/2000/svg","rect"),t.appendChild(i)),this.setSvgStyle(i,e),oi(i,r)},n.prototype.createGElement=function(t,e){return Bi(t,e)},n.prototype.drawLine=function(t,e){var i=document.createElementNS("http://www.w3.org/2000/svg","line");this.setSvgStyle(i,e);var r=e.x+e.width*e.pivotX,s=e.y+e.height*e.pivotY,o={id:e.id,x1:e.startPoint.x+e.x,y1:e.startPoint.y+e.y,x2:e.endPoint.x+e.x,y2:e.endPoint.y+e.y,stroke:e.stroke,"stroke-width":e.strokeWidth.toString(),opacity:e.opacity.toString(),transform:"rotate("+e.angle+" "+r+" "+s+")",visibility:e.visible?"visible":"hidden"};e.class&&(o.class=e.class),oi(i,o),t.appendChild(i)},n.prototype.drawCircle=function(t,e,i,r){var s=document.createElementNS("http://www.w3.org/2000/svg","circle");this.setSvgStyle(s,e);var o=e.class||"";i||(o+=" e-disabled");var a={id:e.id,cx:e.centerX,cy:e.centerY,r:e.radius,visibility:e.visible?"visible":"hidden",class:o};r&&(a.role="img",a["aria-label"]=r),s.style.display=e.visible?"block":"none",oi(s,a),t.appendChild(s)},n.prototype.drawPath=function(t,e,i,r,s,o,a){var h,c,l=[];l=QB(l=Cd(e.data)),e.shadow&&this.renderShadow(e,t,l,s),s&&!e.shadow&&(h=s.getElementById(e.id+"_groupElement_shadow"))&&h.parentNode.removeChild(h),s&&(c=s.getElementById(e.id)),(!c||r)&&(c=document.createElementNS("http://www.w3.org/2000/svg","path"),t.appendChild(c)),this.renderPath(c,e,l);var d={};d=a?{id:e.id,transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")translate("+e.x+","+e.y+"),scale("+a+")",visibility:e.visible?"visible":"hidden",opacity:e.opacity}:{id:e.id,transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")translate("+e.x+","+e.y+")",visibility:e.visible?"visible":"hidden",opacity:e.opacity},o&&(d.role="img",d["aria-label"]=o),e.class&&(d.class=e.class),oi(c,d),this.setSvgStyle(c,e,i)},n.prototype.renderPath=function(t,e,i){var r,s,o,a,l,h,c,d,u=i,p="";for(l=0,h=0,d=0,c=u.length;de.width&&"Wrap"!==e.textOverflow&&"NoWrap"===e.textWrapping&&(h[0].text=UF(e.content,e)),v=0;vD&&(u.text=u.text.slice(0,u.text.length-3),u.text=u.text.concat("..."),l.data=u.text),this.alignText(y,p,u,l,f,g,v,e,h),C+=u.dy}}C&&e.isHorizontalLane&&(M=e.parentOffsetX+e.pivotX,w=e.parentOffsetY+e.pivotY,e.y=e.parentOffsetY-C*e.pivotY+.5),e.textDecoration&&"LineThrough"===e.textDecoration&&(e.textDecoration=ab(e.textDecoration));var R={id:e.id+"_text",fill:e.color,visibility:e.visible?"visible":"hidden","text-decoration":e.textDecoration,transform:"rotate("+e.angle+","+M+","+w+")translate("+e.x+","+e.y+")",opacity:e.opacity};r&&(R.role="img",R["aria-label"]=r),oi(y,R)}},n.prototype.alignText=function(t,e,i,r,s,o,a,l,h){"justify"!==l.textAlign?this.setText(t,e,i,r,s,o,l):a!==h.length-1?this.setText(t,e,i,r,s,o,l,l.width,"spacing"):this.setText(t,e,i,r,s,o,l)},n.prototype.setText=function(t,e,i,r,s,o,a,l,h){oi(e,"justify"!==a.textAlign?{x:s.toString(),y:o.toString()}:{x:s.toString(),y:o.toString(),textLength:l||0,lengthAdjust:h||"spacing"}),t.setAttribute("fill",i.text),e.appendChild(r),t.appendChild(e)},n.prototype.drawImage=function(t,e,i,r){var s;i&&(s=i.getElementById(e.id+"image")),s||(s=document.createElementNS("http://www.w3.org/2000/svg","image"),t.appendChild(s));var o=new Image;o.src=e.source;var a="None"!==e.scale?e.scale:"",l=e.alignment,h=l.charAt(0).toLowerCase()+l.slice(1);"Stretch"!==a&&(h+=" "+a.charAt(0).toLowerCase()+a.slice(1)),oi(s,{id:e.id+"image",x:e.x.toString(),y:e.y.toString(),transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")",width:e.width.toString(),visibility:e.visible?"visible":"hidden",height:e.height.toString(),preserveAspectRatio:h,opacity:e.opacity.toString()}),s.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",o.src.toString())},n.prototype.drawHTMLContent=function(t,e,i,r,s){var o,a;if(e&&(o=e.querySelector("#"+t.id+"_html_element")),!o){(a=e.querySelector("#"+t.id+"_html_element")||e.querySelector("#"+t.nodeId+"_html_element"))||(a=Tt("div",{id:t.nodeId+"_html_element",class:"foreign-object"})),o=Tt("div",{id:t.id+"_html_element",class:"foreign-object"});var c=document.getElementById(t.diagramId).ej2_instances[0],d=!1;if(e.parentNode&&e.parentNode.parentNode&&e.parentNode.parentNode.parentNode&&e.parentNode.parentNode.parentNode.classList.contains("e-overview")&&(d=!0),d)c.isReact?c.renderReactTemplates(function(){o.appendChild(t.template.cloneNode(!0))}):o.appendChild(t.template.cloneNode(!0));else{if("string"==typeof t.template){var u=document.createElement("div");u.innerHTML=t.template,t.template=u,c.selectedItems.userHandles.filter(function(g){return g.name===t.id.split("_shape")[0]&&""!==g.template})[0].template=t.template}t.isTemplate&&t.template?o.appendChild(t.template):t.template&&o.appendChild(t.template.cloneNode(!0))}void 0!==s&&e.childNodes.length>s&&e.insertBefore(o,e.childNodes[parseInt(s.toString(),10)]),a.appendChild(o),e.appendChild(a)}var f=En(t).topLeft;o.setAttribute("style","height:"+t.actualSize.height+"px; width:"+t.actualSize.width+"px;left:"+f.x+"px; top:"+f.y+"px;position:absolute;transform:rotate("+(t.rotateAngle+t.parentTransform)+"deg);pointer-events:"+(r?"all":"none")+";visibility:"+(t.visible?"visible":"hidden")+";opacity:"+t.style.opacity+";")},n.prototype.drawNativeContent=function(t,e,i,r,s){var o,a;if(s&&(o=s.getElementById(t.id+"_native_element"),a=s.getElementById(t.id+"_clip")),!o){(o=document.createElementNS("http://www.w3.org/2000/svg","g")).setAttribute("id",t.id+"_native_element"),o.appendChild(t.template.cloneNode(!0));var l=this.createGElement("g",{id:t.id+"_inner_native_element"});l.appendChild(o),e.appendChild(l)}a&&o.removeChild(a),o.setAttribute("style","visibility:"+(t.visible?"visible":"hidden")+";opacity:"+t.style.opacity+";"),this.setNativTransform(t,o,i,r),"Slice"===t.scale&&this.drawClipPath(t,o,i,r,s),oi(o,t.description?{role:"img","aria-label":t.description}:{})},n.prototype.setNativTransform=function(t,e,i,r){var s=0!==t.contentSize.width?t.contentSize.width:1,o=0!==t.contentSize.height?t.contentSize.height:1;e.setAttribute("transform","rotate("+t.parentTransform+","+t.offsetX+","+t.offsetY+") translate("+(t.offsetX-t.templatePosition.x*r/s-r*t.pivot.x)+","+(t.offsetY-t.templatePosition.y*i/o-i*t.pivot.y)+") scale("+r/s+","+i/o+")")},n.prototype.drawClipPath=function(t,e,i,r,s){var o=t.contentSize.width,a=t.contentSize.height,l=t.width/(r/o),h=t.height/(i/a),c=t.templatePosition.x+(t.width>=t.height?0:(o-l)/2),d=t.templatePosition.y+(t.height>=t.width?0:(a-h)/2),u=s.getElementById(t.id+"_clip");(u=document.createElementNS("http://www.w3.org/2000/svg","clipPath")).setAttribute("id",t.id+"_clip"),e.appendChild(u);var p=s.getElementById(t.id+"_clip_rect");return p=document.createElementNS("http://www.w3.org/2000/svg","rect"),u.appendChild(p),oi(p,{id:t.id+"_clip_rect",width:l.toString(),height:h.toString(),x:c.toString(),y:d.toString()}),im()?e.setAttribute("clip-path","url("+location.protocol+"//"+location.host+location.pathname+"#"+t.id+"_clip)"):e.setAttribute("clip-path","url(#"+t.id+"_clip)"),e},n.prototype.renderGradient=function(t,e,i){var r,s,o,h,c,a=vT(i),l=a.getElementById(i+"gradient_pattern");if(l||(l=Bi("defs",{id:i+"gradient_pattern"}),a.insertBefore(l,a.firstChild)),pF(e.id),"None"!==t.gradient.type){for(var d=0;dt.width&&("Ellipsis"===t.textOverflow||"Clip"===t.textOverflow)&&"NoWrap"===t.textWrapping?0:.5*t.width:"right"===t.textAlign&&(c=1*t.width),s.x=0+c+(e?e.x:0),s.y=1.2+d-r.height/2,s},n}(),Pc=function(){function n(t,e,i){this.renderer=null,this.isSvgMode=!0,this.transform={x:0,y:0},this.diagramId=t,this.element=xt(this.diagramId),this.svgRenderer=e,this.isSvgMode=i,this.renderer=i?new qp:new bo}return n.prototype.setCursor=function(t,e){t.style.cursor=e},n.prototype.setLayers=function(){this.iconSvgLayer=this.element.getElementsByClassName("e-ports-expand-layer")[0],this.adornerSvgLayer=this.element.getElementsByClassName("e-adorner-layer")[0],this.nativeSvgLayer=this.element.getElementsByClassName("e-native-layer")[0],this.diagramSvgLayer=this.element.getElementsByClassName("e-diagram-layer")[0]},n.prototype.getAdornerLayer=function(){return fT(this.diagramId)},n.prototype.getParentSvg=function(t,e,i){return this.diagramId&&t&&t.id?t.id.split("_icon_content").length>1||t.id.split("_nodeport").length>1||t.elementActions&Xr.ElementIsPort?this.iconSvgLayer:e&&"selector"===e?this.adornerSvgLayer:t instanceof Cn?this.nativeSvgLayer:this.diagramSvgLayer:i},n.prototype.getParentElement=function(t,e,i,r){var s=e;if(i&&this.diagramId&&t&&t.id){t.id.split("_icon_content").length>1?(s=i.getElementById(this.diagramId+"_diagramExpander"),e=null):t.id.split("_nodeport").length>1?s=i.getElementById(this.diagramId+"_diagramPorts"):t instanceof Cn?(s=i.getElementById(this.diagramId+"_nativeLayer"),e=null):t.elementActions&Xr.ElementIsPort?(s=i.getElementById(this.diagramId+"_diagramPorts"),e=null):s=i.getElementById(this.diagramId+"_diagramLayer");var o=this.getGroupElement(t,e||s,r);s=o.g,o.svg&&(i=o.svg)}return{g:s,svg:i}},n.prototype.getGroupElement=function(t,e,i){var r,o,s=this.getParentSvg(t);if(e&&s){if(s&&!(r=s.getElementById(t.id+"_groupElement"))&&s!==this.nativeSvgLayer){var a=this.nativeSvgLayer;r=a.getElementById(t.id+"_groupElement"),o=a}r||(r=this.svgRenderer.createGElement("g",{id:t.id+"_groupElement"}),void 0!==i&&e.childNodes.length>i?e.insertBefore(r,e.childNodes[parseInt(i.toString(),10)]):e.appendChild(r))}return{g:r,svg:o}},n.prototype.renderElement=function(t,e,i,r,s,o,a,l,h,c,d){t instanceof Cs?(t.id=t.id?t.id:Qe(),this.renderContainer(t,e,i,r,s,o,a,l,h,c,d)):t instanceof mI?this.renderImageElement(t,e,r,s,a):t instanceof Ke?this.renderPathElement(t,e,r,s,a,h,d):t instanceof ni?this.renderTextElement(t,e,r,s,a,c):t instanceof Cn?this.renderNativeElement(t,e,r,s,a):t instanceof Jn?this.renderHTMLElement(t,e,i,r,s,a,l):this.renderRect(t,e,r,s,h)},n.prototype.drawSelectionRectangle=function(t,e,i,r,s,o){var a={width:i*o.scale,height:r*o.scale,x:.5+(t=(t+o.tx)*o.scale),y:.5+(e=(e+o.ty)*o.scale),fill:"transparent",stroke:"gray",angle:0,pivotX:.5,pivotY:.5,strokeWidth:1,dashArray:"6 3",opacity:1,visible:!0,id:s.id+"_selected_region"},l=this.getAdornerLayer();this.svgRenderer.updateSelectionRegion(l,a)},n.prototype.renderHighlighter=function(t,e,i){var r=t.actualSize.width||2,s=t.actualSize.height||2,o=t.offsetX-r*t.pivot.x,a=t.offsetY-s*t.pivot.y;this.svgRenderer.drawRectangle(e,{width:r*i.scale,height:s*i.scale,x:o=(o+i.tx)*i.scale,y:a=(a+i.ty)*i.scale,fill:"transparent",stroke:"#8CC63F",angle:t.rotateAngle,pivotX:t.pivot.x,pivotY:t.pivot.y,strokeWidth:4,dashArray:"",opacity:1,cornerRadius:0,visible:!0,id:e.id+"_highlighter",class:"e-diagram-highlighter"},this.diagramId,void 0,void 0,e)},n.prototype.renderSelectionRectangle=function(t,e,i,r){var s=t.actualSize.width||2,o=t.actualSize.height||2,a=t.offsetX-s*t.pivot.x,l=t.offsetY-o*t.pivot.y,h={width:s*i.scale,height:o*i.scale,x:a=(a+i.tx)*i.scale,y:l=(l+i.ty)*i.scale,fill:"transparent",stroke:"#00cc00",angle:t.rotateAngle,pivotX:t.pivot.x,pivotY:t.pivot.y,strokeWidth:r?2:1,dashArray:"",opacity:1,cornerRadius:0,visible:!0,id:t.id+"_highlighter",class:r?"e-diagram-first-selection-indicator e-diagram-selection-indicator":"e-diagram-selection-indicator"},c=this.getParentSvg(t,"selector");this.svgRenderer.drawRectangle(e,h,this.diagramId,void 0,void 0,c)},n.prototype.renderSelectionLine=function(t,e,i,r){var s=this.getBaseAttributes(t,i);s.data=t.absolutePath,s.id=s.id+"_highlighter";var o=t.description?t.description:t.id;this.isSvgMode||(s.x=t.flipOffset.x?t.flipOffset.x:s.x,s.y=t.flipOffset.y?t.flipOffset.y:s.y),i&&(s.x=s.x*i.scale,s.y=s.y*i.scale),s.stroke="#00cc00",s.strokeWidth=r?2:1,s.class=r?"e-diagram-first-selection-indicator e-diagram-selection-indicator":"e-diagram-selection-indicator";var a=this.getParentSvg(t,"selector");this.svgRenderer.drawPath(e,s,this.diagramId,void 0,a,o,i.scale)},n.prototype.renderStackHighlighter=function(t,e,i,r,s,o,a){var l=t.actualSize.width||2,h=t.offsetX-l*t.pivot.x,c=t.actualSize.height||2,d=t.offsetY-c*t.pivot.y;h=(h+i.tx)*i.scale;var u,p=t.bounds,f="";if(d=(d+i.ty)*i.scale,r)if(o){var v,y;u="M 0 0 L "+(2+(g=l*i.scale))+" 0 Z",v=t.actualSize.width/Number(p.width?p.width:1)*i.scale,y=t.actualSize.height/Number(p.height?p.height:1)*i.scale,f=uI(pI(Cd("M7,4 L8,4 8,7 11,7 11,8 8,8 8,11 7,11 7,8 4,8 4,7 7,7 z M7.5,0.99999994C3.9160004,1 1,3.9160004 0.99999994,7.5 1,11.084 3.9160004,14 7.5,14 11.084,14 14,11.084 14,7.5 14,3.9160004 11.084,1 7.5,0.99999994 z M7.5,0 C11.636002,0 15,3.3639984 15,7.5 15,11.636002 11.636002,15 7.5,15 3.3640003,15 0,11.636002 0,7.5 0,3.3639984 3.3640003,0 7.5,0 z")),v+g+2,y-8,!1,p.x,p.y,0,0),s.y>=t.offsetY&&(d+=c)}else{var g;a&&s.y>=t.offsetY&&(d+=c*i.scale),u="M -10 -10 L 0 0 Z M -10 10 L 0 0 Z M 0 0 L "+(g=l*i.scale)+" 0 Z M "+g+" 0 L "+(g+10)+" 10 Z L "+(g+10)+" -10 Z"}else u="M 10 -10 L 0 0 Z M -10 -10 L 0 0 Z M 0 0 L 0 "+(g=c*i.scale)+" Z M 0 "+g+" L -10 "+(g+10)+" Z L 10 "+(g+10)+" Z",s.x>=t.offsetX&&(h+=l*i.scale);this.svgRenderer.drawPath(e,{data:u+f,width:l*i.scale,height:c*i.scale,x:h,y:d,fill:"transparent",stroke:"#8CC63F",angle:t.rotateAngle,pivotX:t.pivot.x,pivotY:t.pivot.y,strokeWidth:1,dashArray:"",opacity:1,visible:!0,id:e.id+"_stack_highlighter",class:"e-diagram-highlighter"},this.diagramId)},n.prototype.drawLine=function(t,e){this.svgRenderer.drawLine(t,e)},n.prototype.drawPath=function(t,e){this.svgRenderer.drawPath(t,e,this.diagramId)},n.prototype.renderResizeHandle=function(t,e,i,r,s,o,a,l,h,c,d){var u=t.offsetX-t.actualSize.width*t.pivot.x,p=t.offsetY-t.actualSize.height*t.pivot.y,f=t.actualSize.height,g=t.actualSize.width;!c&&i&bt.Rotate&&kI(this.rendererActions)&&!x3(this.rendererActions)&&(this.renderPivotLine(t,e,o,s,a),this.renderRotateThumb(t,e,o,s,a)),this.renderBorder(t,e,o,l,h,c);var v=t.actualSize.width*r,y=t.actualSize.height*r;!h&&kI(this.rendererActions)&&!x3(this.rendererActions)&&(t.isTextAnnotation||(v>=40&&y>=40&&(s&lr.ResizeNorthWest&&this.renderCircularHandle("resizeNorthWest",t,u,p,e,qr(s,"ResizeNorthWest"),i&bt.ResizeNorthWest,o,void 0,a,{"aria-label":"Thumb to resize the selected object on top left side direction"},void 0,"e-diagram-resize-handle e-northwest",d),s&lr.ResizeNorthEast&&this.renderCircularHandle("resizeNorthEast",t,u+g,p,e,qr(s,"ResizeNorthEast"),i&bt.ResizeNorthEast,o,void 0,a,{"aria-label":"Thumb to resize the selected object on top right side direction"},void 0,"e-diagram-resize-handle e-northeast",d),s&lr.ResizeSouthWest&&this.renderCircularHandle("resizeSouthWest",t,u,p+f,e,qr(s,"ResizeSouthWest"),i&bt.ResizeSouthWest,o,void 0,a,{"aria-label":"Thumb to resize the selected object on bottom left side direction"},void 0,"e-diagram-resize-handle e-southwest",d),s&lr.ResizeSouthEast&&this.renderCircularHandle("resizeSouthEast",t,u+g,p+f,e,qr(s,"ResizeSouthEast"),i&bt.ResizeSouthEast,o,void 0,a,{"aria-label":"Thumb to resize the selected object on bottom right side direction"},void 0,"e-diagram-resize-handle e-southeast",d)),s&lr.ResizeNorth&&this.renderCircularHandle("resizeNorth",t,u+g/2,p,e,qr(s,"ResizeNorth"),i&bt.ResizeNorth,o,void 0,a,{"aria-label":"Thumb to resize the selected object on top side direction"},void 0,"e-diagram-resize-handle e-north",d),s&lr.ResizeSouth&&this.renderCircularHandle("resizeSouth",t,u+g/2,p+f,e,qr(s,"ResizeSouth"),i&bt.ResizeSouth,o,void 0,a,{"aria-label":"Thumb to resize the selected object on bottom side direction"},void 0,"e-diagram-resize-handle e-south",d),s&lr.ResizeWest&&this.renderCircularHandle("resizeWest",t,u,p+f/2,e,qr(s,"ResizeWest"),i&bt.ResizeWest,o,void 0,a,{"aria-label":"Thumb to resize the selected object on left side direction"},void 0,"e-diagram-resize-handle e-west",d),s&lr.ResizeEast&&this.renderCircularHandle("resizeEast",t,u+g,p+f/2,e,qr(s,"ResizeEast"),i&bt.ResizeEast,o,void 0,a,{"aria-label":"Thumb to resize the selected object on right side direction"},void 0,"e-diagram-resize-handle e-east",d)))},n.prototype.renderEndPointHandle=function(t,e,i,r,s,o,a,l,h,c){var f,g,d=t.sourcePoint,u=t.targetPoint,p=t.wrapper;if(this.renderCircularHandle("connectorSourceThumb",p,d.x,d.y,e,qr(r,"ConnectorSourceThumb"),i&bt.ConnectorSource,s,o,void 0,{"aria-label":"Thumb to move the source point of the connector"},void 0,"e-diagram-endpoint-handle e-sourceend",c),this.renderCircularHandle("connectorTargetThumb",p,u.x,u.y,e,qr(r,"ConnectorTargetThumb"),i&bt.ConnectorTarget,s,a,void 0,{"aria-label":"Thumb to move the target point of the connector"},void 0,"e-diagram-endpoint-handle e-targetend",c),l)if("Straight"===t.type&&t.segments.length>0)for(f=0;f0)for(f=0;f=3&&3===t.segments.length&&(S=1,b=t.segments.length-1),S=t.segments.length>t.maxSegmentThumb+2?2:S,b=t.segments.length>t.maxSegmentThumb+2?t.segments.length-2:b,1===t.segments.length&&t.segments[0].points.length<=2&&(S=1,b=t.segments.length),f=S;f=50&&i.allowDrag),this.renderOrthogonalThumb(t+"_"+(d+1),e,(i.points[parseInt(d.toString(),10)].x+i.points[d+1].x)/2,(i.points[parseInt(d.toString(),10)].y+i.points[d+1].y)/2,r,h,l,o,a,u)}else for(d=0;d=50&&i.allowDrag),this.renderOrthogonalThumb(t+"_"+(d+1),e,(i.points[parseInt(d.toString(),10)].x+i.points[d+1].x)/2,(i.points[parseInt(d.toString(),10)].y+i.points[d+1].y)/2,r,h,l,o,a,u)},n.prototype.renderOrthogonalThumb=function(t,e,i,r,s,o,a,l,h,c){var d,g,u=0,p=document.getElementById(this.diagramId);p&&(g=p.ej2_instances[0]);var y=h.constraints&qe.InheritSegmentThumbShape?g.segmentThumbShape:h.segmentThumbShape,b=h.constraints&qe.InheritSegmentThumbSize?g.segmentThumbSize:h.segmentThumbSize;if(d="horizontal"===a?function Kie(n){return rre[""+n]}(y):i3(y),"Arrow"===y||"DoubleArrow"===y||"OpenArrow"===y)switch(c){case"Bottom":case"Right":u=180;break;default:u=0}else if("Fletch"===y||"OpenFetch"===y||"IndentedArrow"===y||"OutdentedArrow"===y)switch(c){case"Bottom":u=-90;break;case"Top":u=90;break;case"Right":u=180;break;default:u=0}var M={x:(i+l.tx)*l.scale-b/2,y:(r+l.ty)*l.scale-b/2,angle:u,fill:"#e2e2e2",stroke:"black",strokeWidth:1,dashArray:"",data:d,width:b,height:b,pivotX:.5,pivotY:.5,opacity:1,visible:o,id:t,class:"e-diagram-ortho-segment-handle"},w=nf(M.data),C=new me(M.width,M.height),D=new Ke;M.data=D.updatePath(M.data,w,C),this.svgRenderer.drawPath(s,M,this.diagramId)},n.prototype.renderPivotLine=function(t,e,i,r,s){var o=t,l=!!(r&lr.Rotate);s&&(l=!1);var h=this.getBaseAttributes(o,i);h.fill="None",h.stroke="black",h.strokeWidth=1,h.dashArray="2,3",h.visible=l;var c=i.scale;h.x*=c,h.y*=c,h.width*=c,h.height*=c,h.id="pivotLine",h.class="e-diagram-pivot-line";var u={x:o.actualSize.width*o.pivot.x*c,y:0};h.startPoint={x:o.actualSize.width*o.pivot.x*c,y:-20},h.endPoint=u,this.svgRenderer.drawLine(e,h)},n.prototype.renderBezierLine=function(t,e,i,r,s,o){var l=this.getBaseAttributes(e,o);l.id=t,l.stroke="black",l.strokeWidth=1,l.dashArray="3,3",l.fill="None",l.class="e-diagram-bezier-control-line",l.x=0,l.y=0;var h=o.scale,g={x:(s.x+o.tx)*h,y:(s.y+o.ty)*h};l.startPoint={x:(r.x+o.tx)*h,y:(r.y+o.ty)*h},l.endPoint=g,this.svgRenderer.drawLine(i,l)},n.prototype.renderCircularHandle=function(t,e,i,r,s,o,a,l,h,c,d,u,p,f){var g=e,v={x:i,y:r};if(0!==g.rotateAngle||0!==g.parentTransform){var y=Hi();qi(y,g.rotateAngle+g.parentTransform,g.offsetX,g.offsetY),v=Je(y,v)}var S=this.getBaseAttributes(g);S.stroke="black",S.strokeWidth=1,void 0!==u?(S.id="segmentEnd_"+u,S.fill="#e2e2e2"):S.fill=h?"#8CC63F":"white",S.cornerRadius=f/2,S.angle=e.rotateAngle,S.id=t,S.visible=o,S.class=p,S.width=f,S.height=f,S.x=(v.x+l.tx)*l.scale,S.y=(v.y+l.ty)*l.scale,S.x=S.x-S.width/2,S.y=S.y-S.height/2,h&&(S.class+=" e-connected"),c&&(S.visible=!1);var b=this.getParentSvg(e,"selector");this.svgRenderer.drawRectangle(s,S,this.diagramId,!0,!0,b,d,!0,a)},n.prototype.renderBezierHandle=function(t,e,i,r,s,o,a,l,h,c,d,u,p){var v,f=document.getElementById(this.diagramId);f&&(v=f.ej2_instances[0]);var y=e,S={x:i,y:r};if(0!==y.rotateAngle||0!==y.parentTransform){var b=Hi();qi(b,y.rotateAngle+y.parentTransform,y.offsetX,y.offsetY),S=Je(b,S)}var D=a.constraints&qe.InheritSegmentThumbSize?v.segmentThumbSize:a.segmentThumbSize,A=i3(a.constraints&qe.InheritSegmentThumbShape?v.segmentThumbShape:a.segmentThumbShape),x=this.getBaseAttributes(y);x.stroke="black",x.strokeWidth=1,void 0!==d?(x.id="segmentEnd_"+d,x.fill="#e2e2e2"):x.fill=h?"#8CC63F":"white",x.angle=e.rotateAngle,x.id=t,x.visible=o,x.class=u,x.width=D,x.height=D,x.data=A,x.x=(S.x+l.tx)*l.scale,x.y=(S.y+l.ty)*l.scale,x.x=x.x-x.width/2,x.y=x.y-x.height/2,h&&(x.class+=" e-connected"),c&&(x.visible=!1);var R=nf(x.data),L=new me(x.width,x.height),O=new Ke;x.data=O.updatePath(x.data,R,L);var N=this.getParentSvg(e,"selector");this.svgRenderer.drawPath(s,x,this.diagramId,!0,N)},n.prototype.renderBorder=function(t,e,i,r,s,o){var l=this.getBaseAttributes(t,i);l.x*=i.scale,l.y*=i.scale,l.width*=i.scale,l.height*=i.scale,l.fill="transparent",l.stroke="#097F7F",l.strokeWidth=1.2,l.gradient=null,l.dashArray="6,3",l.class="e-diagram-selector",o&&(l.class+=" e-diagram-lane"),l.id="borderRect",l.id=this.rendererActions&Qa.DrawSelectorBorder?"borderRect_symbol":"borderRect",r||(l.class+=" e-disabled"),s&&(l.class+=" e-thick-border"),l.cornerRadius=0;var h=this.getParentSvg(t,"selector");this.svgRenderer.drawRectangle(e,l,this.diagramId,void 0,!0,h)},n.prototype.renderUserHandler=function(t,e,i,r,s,o){for(var l,a=t.wrapper,h=0,c=t.userHandles;h0||d.disableNodes&&t.nodes.length>0||"Drag"===s&&o)&&(l=!1);var u=document.getElementById(d.name+"_template_hiddenUserHandle");u&&(d.template=u.childNodes[0].cloneNode(!0));var p=Jx(t,d,i);if(p.x=(p.x+i.tx)*i.scale,p.y=(p.y+i.ty)*i.scale,d.visible&&(d.visible=!!(t.constraints&lr.UserHandle)),l)if(d.pathData){var f=d.pathData?d.pathData:d.content,g=this.getBaseAttributes(a);g.id=d.name+"_userhandle",g.fill=d.backgroundColor,g.stroke=d.borderColor,g.strokeWidth=d.borderWidth,g.centerX=p.x,g.centerY=p.y,g.radius=.5*d.size,g.class="e-diagram-userhandle-circle",g.angle=0,g.visible=d.visible,g.opacity=1,this.svgRenderer.drawCircle(e,g,1,{"aria-label":d.name+"user handle"});var y=[];y=pI(y=Cd(f));var S=nf(f),w=uI(y,(d.size-.45*d.size)/S.width,(d.size-.45*d.size)/S.height,!0,S.x,S.y,0,0);S=nf(w),this.svgRenderer.drawPath(e,C={x:p.x-S.width/2,y:p.y-S.height/2,angle:0,id:"",class:"e-diagram-userhandle-path",fill:d.pathColor,stroke:d.backgroundColor,strokeWidth:.5,dashArray:"",data:w,width:d.size-5,height:d.size-5,pivotX:0,pivotY:0,opacity:1,visible:d.visible},this.diagramId,void 0,void 0,{"aria-label":d.name+"user handle"})}else if(d.content){var D=new Cn(d.name,this.diagramId);D.content=d.content,D.offsetX=p.x,D.offsetY=p.y,D.id=d.name+"_shape",D.horizontalAlignment="Center",D.verticalAlignment="Center",D.visible=d.visible,D.setOffsetWithRespectToBounds(p.x,p.y,"Fraction"),D.relativeMode="Object",D.description=d.name||"User handle",D.measure(new me(d.size,d.size)),D.arrange(D.desiredSize),this.svgRenderer.drawNativeContent(D,e,d.size,d.size,this.adornerSvgLayer)}else if(d.source){var C,A=new mI;(C=this.getBaseAttributes(A,i)).width=d.size,C.height=d.size,C.x=p.x-d.size/2,C.y=p.y-d.size/2,C.sourceWidth=d.size,C.sourceHeight=d.size,C.alignment=A.imageAlign,C.source=d.source,C.scale=A.imageScale,C.visible=d.visible,C.description=d.name||"User handle",C.id=d.name+"_",this.renderer.drawImage(e,C,this.adornerSvgLayer,!1)}else{var x=new Jn(d.name,this.diagramId);x.offsetX=p.x,x.offsetY=p.y,x.id=d.name+"_shape",x.visible=d.visible,x.relativeMode="Object",x.template=d.template,x.measure(new me(d.size,d.size)),x.arrange(x.desiredSize),this.svgRenderer.drawHTMLContent(x,r,void 0,!0,void 0)}}},n.prototype.renderRotateThumb=function(t,e,i,r,s){new Ke;var a,l=new me;l.width=18,l.height=16;var d=!!(r&lr.Rotate);s&&(d=!1);var p=t.offsetX-t.actualSize.width*t.pivot.x+t.pivot.x*t.actualSize.width,f=t.offsetY-t.actualSize.height*t.pivot.y;if(a={x:(p=(p+i.tx)*i.scale)-.5*l.width,y:(f=(f+i.ty)*i.scale)-30-.5*l.height},0!==t.rotateAngle||0!==t.parentTransform){var g=Hi();qi(g,t.rotateAngle+t.parentTransform,(i.tx+t.offsetX)*i.scale,(i.ty+t.offsetY)*i.scale),a=Je(g,a)}this.svgRenderer.drawPath(e,{x:a.x,y:a.y,angle:t.rotateAngle+t.parentTransform,fill:"#231f20",stroke:"black",strokeWidth:.5,dashArray:"",data:"M 16.856144362449648 10.238890446662904 L 18.000144362449646 3.437890446662903L 15.811144362449646 4.254890446662903 C 14.837144362449646 2.5608904466629028 13.329144362449647 1.2598904466629026 11.485144362449645 0.5588904466629026 C 9.375144362449646 - 0.24510955333709716 7.071144362449646 - 0.18010955333709716 5.010144362449646 0.7438904466629028 C 2.942144362449646 1.6678904466629028 1.365144362449646 3.341890446662903 0.558144362449646 5.452890446662903 C - 0.244855637550354 7.567890446662903 - 0.17985563755035394 9.866890446662904 0.7431443624496461 11.930890446662904 C 1.6681443624496461 13.994890446662904 3.343144362449646 15.575890446662903 5.457144362449647 16.380890446662903 C 6.426144362449647 16.7518904466629 7.450144362449647 16.9348904466629 8.470144362449647 16.9348904466629 C 9.815144362449647 16.9348904466629 11.155144362449647 16.6178904466629 12.367144362449647 15.986890446662901 L 11.351144362449647 14.024890446662901 C 9.767144362449647 14.8468904466629 7.906144362449647 14.953890446662902 6.237144362449647 14.3178904466629 C 4.677144362449647 13.7218904466629 3.444144362449647 12.5558904466629 2.758144362449647 11.028890446662901 C 2.078144362449646 9.501890446662903 2.031144362449646 7.802890446662903 2.622144362449646 6.243890446662903 C 3.216144362449646 4.6798904466629025 4.387144362449646 3.442890446662903 5.914144362449646 2.760890446662903 C 7.437144362449646 2.078890446662903 9.137144362449646 2.0298904466629026 10.700144362449645 2.6258904466629027 C 11.946144362449646 3.100890446662903 12.971144362449646 3.9538904466629026 13.686144362449646 5.049890446662903 L 11.540144362449645 5.850890446662903 L 16.856144362449648 10.238890446662904 Z",width:20,height:20,pivotX:0,pivotY:0,opacity:1,visible:d,id:"rotateThumb",class:"e-diagram-rotate-handle"},this.diagramId,!0,void 0,{"aria-label":"Thumb to rotate the selected object"})},n.prototype.renderPathElement=function(t,e,i,r,s,o,a){var l=this.getBaseAttributes(t,i,o);if(l.data=t.absolutePath,l.data=t.absolutePath,t.isPathPort&&a){l.x=a[t.id]?a[t.id].cx:l.x,l.y=a[t.id]?a[t.id].cy:l.y,t.bounds.x=l.x,t.bounds.y=l.y;var h=document.getElementById(this.diagramId);h&&"PortDrag"!==h.ej2_instances[0].eventHandler.currentAction&&(t.offsetX=l.x+t.width/2,t.offsetY=l.y+t.height/2)}var u=t.description?t.description:t.id;if(this.isSvgMode||(l.x=t.flipOffset.x?t.flipOffset.x:l.x,l.y=t.flipOffset.y?t.flipOffset.y:l.y),t.isExport){var p=t.absoluteBounds,f=Cd(l.data),g=this.findAndStoreArcValues(f);l.arc=g,l.data=LF(t,p,0,l)}this.renderer.drawPath(e,l,this.diagramId,void 0,r,u)},n.prototype.findAndStoreArcValues=function(t){var e=[];return t.forEach(function(i){"A"===i.command&&e.push({r1:i.r1/2,r2:i.r2/2})}),e},n.prototype.renderSvgGridlines=function(t,e,i,r,s,o){var a=document.createElementNS("http://www.w3.org/2000/svg","pattern"),l=document.createElementNS("http://www.w3.org/2000/svg","defs");l.setAttribute("id",this.diagramId+"_grid_pattern_defn"),(t.constraints&Kt.ShowHorizontalLines||t.constraints&Kt.ShowVerticalLines)&&a.setAttribute("id",this.diagramId+"_pattern");var h=0,c=0,d=0,u=0,p=1,f=!1,g="Lines"===t.gridType,v=g?t.verticalGridlines.lineIntervals:t.verticalGridlines.dotIntervals,y=g?t.horizontalGridlines.lineIntervals:t.horizontalGridlines.dotIntervals;if(r.showRulers&&r.dynamicGrid&&s&&o)d=o.updateSegmentWidth(i.scale),u=s.updateSegmentWidth(i.scale),t.horizontalGridlines.scaledIntervals=[d/s.interval],t.verticalGridlines.scaledIntervals=[u/o.interval],f=!0;else{for(var S=0;S=2)for(;e>=2;)e/=2;else if(e<=.5)for(;e<=.5;)e*=2;var i;if(t.horizontalGridlines.scaledIntervals=t.horizontalGridlines.snapIntervals,t.verticalGridlines.scaledIntervals=t.verticalGridlines.snapIntervals,1!==e){var r=t.horizontalGridlines;for(r.scaledIntervals=[],i=0;ithis.groupElement.actualSize.height&&("Clip"===t.style.textOverflow||"Ellipsis"===t.style.textOverflow)&&(a.y=a.y+(a.height-this.groupElement.actualSize.height)/2),this.renderer.drawRectangle(e,a,this.diagramId,void 0,void 0,r),this.renderer.drawText(e,a,r,l,this.diagramId,t.isExport&&Math.min(t.exportScaleValue.x||t.exportScaleValue.y),this.groupElement),this.isSvgMode&&(t.doWrap=!1)},n.prototype.renderNativeElement=function(t,e,i,r,s){var o,a,l=this.getParentSvg(t,void 0,e)||r,h=this.getParentElement(t,e,l).g||e,c=this.getBaseAttributes(t,i);switch(c.fill="transparent",c.cornerRadius=t.cornerRadius,c.stroke="transparent",this.renderer.drawRectangle(e,c,this.diagramId,void 0,void 0,r),t.scale){case"None":o=t.contentSize.width,a=t.contentSize.height;break;case"Stretch":o=t.actualSize.width,a=t.actualSize.height;break;case"Meet":o=a=t.actualSize.width<=t.actualSize.height?t.actualSize.width:t.actualSize.height;break;case"Slice":o=a=t.actualSize.width>=t.actualSize.height?t.actualSize.width:t.actualSize.height}this.svgRenderer&&this.svgRenderer.drawNativeContent(t,h,a,o,l)},n.prototype.renderHTMLElement=function(t,e,i,r,s,o,a){var l=this.getBaseAttributes(t,r);l.fill="transparent",l.cornerRadius=t.cornerRadius,l.stroke="transparent",this.renderer.drawRectangle(e,l,this.diagramId,void 0,void 0,s),this.svgRenderer&&this.svgRenderer.drawHTMLContent(t,i.children[0],r,function ose(n){var t=n.parentElement;do{if(hm(t,"e-diagram"))return!0;t=t.parentElement}while(t);return!1}(i),a)},n.prototype.renderImageElement=function(t,e,i,r,s){var o=this.getBaseAttributes(t,i);o.cornerRadius=0,this.renderer.drawRectangle(e,o,this.diagramId,void 0,void 0,r);var a,l,h,c,g,d=t.contentSize.width,u=t.contentSize.height,p=o.width/d,f=o.height/u;if("Stretch"===t.stretch)a=d*(g=Math.min(p,f)),l=u*g;else switch(t.stretch){case"Meet":a=d*(g=Math.min(p,f)),l=u*g,o.x+=Math.abs(o.width-a)/2,o.y+=Math.abs(o.height-l)/2;break;case"Slice":g=Math.max(p,f),h=o.width/(a=d*g)*d,c=o.height/(l=u*g)*u;break;case"None":a=d,l=u}o.width=a,o.height=l,o.sourceWidth=h,o.sourceHeight=c,o.source=t.source,o.alignment=t.imageAlign,o.scale=t.imageScale,o.description=t.description?t.description:t.id,this.renderer.drawImage(e,o,r,s)},n.prototype.renderContainer=function(t,e,i,r,s,o,a,l,h,c,d){var g,u={svg:s,g:e},p=document.getElementById(this.diagramId);if(p&&(g=p.ej2_instances[0]),this.diagramId&&(s=this.getParentSvg(t)||s,this.isSvgMode)){var v=this.getParentElement(t,e,s,l).g||e;s=this.getParentSvg(this.hasNativeParent(t.children))||s;var y=this.getParentElement(this.hasNativeParent(t.children),v,s,l);u.svg=y.svg||s,u.g=y.g||v,o&&s&&(s.getElementById(u.g.id)||e.appendChild(u.g)),e=u.g}if(this.renderRect(t,e,r,s),this.groupElement=t,t.hasChildren()){for(var b,S=void 0,M=0,w=t.children;M0&&(D=g.selectedItems.nodes[0]);var L,A=void 0,x=void 0,R=!1;if(g&&g.selectedItems&&(L=g.getObject(t.id)),"None"!==t.flip&&(D=L),"None"===t.flip&&(D=L),D&&D.flipMode&&(R=!0),!(t.elementActions&Xr.ElementIsGroup)&&g instanceof zl&&g.nameTable[t.id]&&"connectors"!==g.nameTable[t.id].propName&&R&&D){if(A=t.children&&t.children[0]instanceof Cn?document.getElementById(D.id+"_content_inner_native_element"):document.getElementById(D.id+"_content_groupElement"),!(t.children[0]instanceof Cn)&&"Text"!==D.shape.type&&"None"!==D.flipMode&&"Label"!==D.flipMode&&"All"!==D.flipMode&&"PortAndLabel"!==D.flipMode&&"LabelText"!==D.flipMode&&"PortAndLabelText"!==D.flipMode&&"LabelAndLabelText"!==D.flipMode||t.children[0]instanceof Cn&&"Port"===D.flipMode)return void this.renderFlipElement(t,A,D.flip);if((t.children[0]instanceof Cn&&("All"===D.flipMode||"Label"===D.flipMode)||"Label"===D.flipMode||"PortAndLabel"===D.flipMode||"LabelText"===D.flipMode||"PortAndLabelText"===D.flipMode||"LabelAndLabelText"===D.flipMode||"Image"===D.shape.type&&"Label"===D.flipMode)&&this.renderFlipElement(t,A,t.flip),"None"!==t.flip&&"None"===D.flipMode)this.renderFlipElement(t,A,t.flip);else if("None"!==t.flip&&("Label"===D.flipMode||"PortAndLabel"===D.flipMode||"LabelText"===D.flipMode||"PortAndLabelText"===D.flipMode||"LabelAndLabelText"===D.flipMode)||t.children[0]instanceof Cn&&"None"!==t.flip&&D&&("None"===D.flipMode||"All"===D.flipMode)){for(var O=0;O0){var i=t[0];if(i instanceof Cn)return i;i.children&&i.children.length&&this.hasNativeParent(i.children,e++||0)}},n.prototype.renderRect=function(t,e,i,r,s){var o=this.getBaseAttributes(t,i,s);o.cornerRadius=t.cornerRadius||0,t.isExport&&(o.cornerRadius*=t.exportScaleValue.x),this.renderer.drawRectangle(e,o,this.diagramId,t.isExport,void 0,r,t.description?t.description:t.id)},n.prototype.drawRect=function(t,e){e.cornerRadius=0,this.svgRenderer.drawRectangle(t,e,this.diagramId)},n.prototype.getBaseAttributes=function(t,e,i){var r={width:t.actualSize.width,height:t.actualSize.height,x:t.offsetX-t.actualSize.width*t.pivot.x,y:t.offsetY-t.actualSize.height*t.pivot.y,fill:t.style.fill,stroke:t.style.strokeColor,angle:t.rotateAngle+t.parentTransform,pivotX:t.pivot.x,pivotY:t.pivot.y,strokeWidth:t.style.strokeWidth,dashArray:t.style.strokeDashArray||"",opacity:t.style.opacity,shadow:t.shadow,gradient:t.style.gradient,visible:t.visible,id:t.id,description:t.description,canApplyStyle:t.canApplyStyle,shapeType:t.shapeType};return"Page"===t.rotationReference&&(r.angle=t.rotateAngle),i&&(r.x=r.x-.5,r.y=r.y-.5),t.isExport&&(r.width*=t.exportScaleValue.x,r.height*=t.exportScaleValue.y,r.x*=t.exportScaleValue.x,r.y*=t.exportScaleValue.y,r.strokeWidth*=t.exportScaleValue.x),t.flip&&(r.flip=t.flip),e&&(r.x+=e.tx,r.y+=e.ty),r},n.renderSvgBackGroundImage=function(t,e,i,r,s,o){if(t.source){var l=vT(e.id).getElementById(e.id+"_image");if(!l){var h=function goe(n){return xt(n).getElementsByClassName("e-background-image-layer")[0]}(e.id);(l=document.createElementNS("http://www.w3.org/2000/svg","image")).setAttribute("id",e.id+"_image"),h.appendChild(l)}var c=new Image;c.src=t.source,l.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",c.src.toString());var d="None"!==t.scale?t.scale:"",u=t.align,p=u.charAt(0).toLowerCase()+u.slice(1);d&&(p+=" "+d.charAt(0).toLowerCase()+d.slice(1)),oi(l,{id:e.id+"_image",x:i,y:r,width:s,height:o,preserveAspectRatio:p})}},n.prototype.transformLayers=function(t,e){var i=t.tx*t.scale,r=t.ty*t.scale,s="domTable";if(i!==this.transform.x||r!==this.transform.y||0===i||0===r){e&&(window[""+s][this.diagramId+"_diagramLayer"]||(window[""+s][this.diagramId+"_diagramLayer"]=this.diagramSvgLayer.getElementById(this.diagramId+"_diagramLayer")),window[""+s][this.diagramId+"_diagramLayer"].setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+"),scale("+t.scale+")"));var a=function voe(n){var t="domTable",e=null;return window[t][n+"_gridline"]?e=window[t][n+"_gridline"]:(e=Bd(n).getElementById(n+"_gridline"),window[t][n+"_gridline"]=e),e}(this.diagramId);return a.setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+")"),window[""+s][this.diagramId+"_diagramPorts"]||(window[""+s][this.diagramId+"_diagramPorts"]=this.iconSvgLayer.getElementById(this.diagramId+"_diagramPorts")),window[""+s][this.diagramId+"_diagramPorts"].setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+"),scale("+t.scale+")"),window[""+s][this.diagramId+"_diagramExpander"]||(window[""+s][this.diagramId+"_diagramExpander"]=this.iconSvgLayer.getElementById(this.diagramId+"_diagramExpander")),window[""+s][this.diagramId+"_diagramExpander"].setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+"),scale("+t.scale+")"),window[""+s][this.diagramId+"_nativeLayer"]||(window[""+s][this.diagramId+"_nativeLayer"]=this.nativeSvgLayer.getElementById(this.diagramId+"_nativeLayer")),window[""+s][this.diagramId+"_nativeLayer"].setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+"),scale("+t.scale+")"),Io(this.diagramId).children[0].style.transform="translate("+t.tx*t.scale+"px,"+t.ty*t.scale+"px)scale("+t.scale+")",this.transform={x:t.tx*t.scale,y:t.ty*t.scale},!0}return!1},n.prototype.updateNode=function(t,e,i,r,s,o,a){this.renderElement(t,e,i,r,this.getParentSvg(t),void 0,void 0,s,null,o,a)},n}(),Kne=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),XI=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},nF=function(n){function t(e,i){var r=n.call(this,e,i)||this;return r.mode="Canvas",r.id="overview",r.actionName="",r.startPoint=null,r.currentPoint=null,r.prevPoint=null,r.scale=null,r.inAction=!1,r.viewPortRatio=1,r.horizontalOffset=0,r.verticalOffset=0,r.model={},r.event=!0,r.overviewid=88123,r.model={width:r.width,height:r.height},r}return Kne(t,n),t.prototype.onPropertyChanged=function(e,i){for(var r=0,s=Object.keys(e);r0||e.toString().indexOf("%")>0?e.toString():e.toString()+"px"},t.prototype.renderCanvas=function(e){var i=document.getElementById(this.element.id+"_canvas");i||(i=Tt("div",{}),this.element.appendChild(i)),Ho(i,{id:this.element.id+"_canvas",class:"drawing",style:"position:relative; height:"+this.getSizeValue(this.model.height)+"; width:"+this.getSizeValue(this.model.width)+";style:-ms-touch-action: none;touch-action: none;"}),this.element.setAttribute("tabindex",String(-1)),this.element.style.overflow="hidden",this.element.style.height=String(this.model.height),this.element.style.width=String(this.model.width),this.canvas=i},t.prototype.setParent=function(e){var i=document.getElementById(e);if(this.parent){var s=this.parent;this.parent=null,s.setOverview(null,this.element.id),this.removeDocument(this)}this.parent=this.getDiagram(i,"ej2_instances"),this.parent&&this.parent.setOverview(this)},t.prototype.getDiagram=function(e,i){for(var r,s=e[""+i].length,o=0;o0?p:Math.floor(window.innerWidth)}if(0===h){var f=Math.floor(window.innerHeight-u-Math.floor(c.top));h=f>0?f:Math.floor(window.innerHeight)}l>0&&(s.setAttribute("width",String(l)),this.model.height=h),h>0&&(s.setAttribute("height",String(h)),this.model.width=l),e.diagramLayerDiv||(e.diagramLayerDiv=Tt("div",{}),e.diagramLayer=bo.createCanvas(this.element.id+"_diagramLayer",this.model.width,this.model.height),e.diagramLayer.setAttribute("style","position:absolute; left:0px; top:0px "),e.diagramLayerDiv.appendChild(e.diagramLayer),e.canvas.appendChild(e.diagramLayerDiv)),Ho(e.diagramLayerDiv,{id:this.element.id+"_diagramLayer_div",style:"width:"+this.model.width+"px; height:"+this.model.height+"px;position:absolute;top:0px;left:0px"}),this.renderHtmlLayer(e.canvas),this.renderNativeLayer(e.canvas,e),this.addOverviewRectPanel(e)},t.prototype.removeDocument=function(e){var i=document.getElementById(this.canvas.id+"_svg");this.canvas.removeChild(i);var r=document.getElementById(this.element.id+"_htmlLayer");this.canvas.removeChild(r);var s=document.getElementById(this.element.id+"_diagramLayer_div");this.canvas.removeChild(s),e.diagramLayerDiv=null,e.diagramLayer=null,window.domTable[this.id+"html_layer"]=null},t.prototype.renderHtmlLayer=function(e){var i=Tt("div",{id:this.element.id+"_htmlLayer",class:"e-html-layer",style:"pointer-events:none;position:absolute;top:0px;left:0px;"}),s=Tt("div",{id:this.element.id+"_htmlLayer_div",style:"position:absolute;top:0px;left:0px;"});return i.appendChild(s),e.appendChild(i),i},t.prototype.renderNativeLayer=function(e,i){if(!document.getElementById(this.element.id+"_nativeLayer_svg")){var r=this.parent.createSvg(this.element.id+"_nativeLayer_svg",this.model.width,this.model.height),s=Bi("g",{id:this.element.id+"_nativeLayer"});r.appendChild(s),i.diagramLayerDiv.appendChild(r),oi(r,{class:"e-native-layer"})}},t.prototype.addOverviewRectPanel=function(e){var i=document.getElementById(this.canvas.id+"_overviewsvg");i&&i.parentNode.removeChild(i),i=Bi("svg",{id:this.canvas.id+"_overviewsvg",class:"overviewsvg",version:"1.1",style:"position:absolute;left:0px;top:0px; aria-label:Specifies overview",width:this.model.width,height:this.model.height}),e.canvas.appendChild(i);var s=Bi("g",{id:this.element.id+"_overviewlayer",style:"pointer-events:none"});i.appendChild(s);var o=Bi("rect",{fill:"transparent",width:"100%",height:"100%",class:"overviewbackrect",id:this.canvas.id+"overviewbackrect"});o.setAttribute("style"," pointer-events: none; "),s.appendChild(o);var a=Bi("g",{id:this.canvas.id+"overviewhandle",style:"pointer-events:all"});s.appendChild(a);var l=Bi("rect",{id:this.canvas.id+"overviewrect",fill:"transparent"});a.appendChild(l),this.renderOverviewCorner("left",a),this.renderOverviewCorner("right",a),this.renderOverviewCorner("top",a),this.renderOverviewCorner("bottom",a),this.renderOverviewCorner("topleft",a),this.renderOverviewCorner("topright",a),this.renderOverviewCorner("bottomleft",a),this.renderOverviewCorner("bottomright",a)},t.prototype.renderOverviewCorner=function(e,i){var s,o=Bi(s="top"===e||"bottom"===e||"right"===e||"left"===e?"rect":"circle",{id:this.canvas.id+"visible"+e,class:"overview-resizer"});i.appendChild(o);var a=Bi(s,{id:this.canvas.id+e,class:"overviewresizer",fill:"transparent"});i.appendChild(a)},t.prototype.updateOverviewRectangle=function(){var e=this.currentPoint.x-this.prevPoint.x,i=this.currentPoint.y-this.prevPoint.y,r=new me;r.width=0,r.height=0;var s=0,o=0;switch(this.resizeDirection){case"left":r.width-=e,r.height-=e/this.viewPortRatio,s=e,o=e/this.viewPortRatio,o/=2;break;case"right":r.width+=e,r.height+=e/this.viewPortRatio,o=e/this.viewPortRatio,o/=-2;break;case"top":r.height-=i,r.width-=i*this.viewPortRatio,o=i,s=i*this.viewPortRatio,s/=2;break;case"bottom":r.height+=i,r.width+=i*this.viewPortRatio,s=i*this.viewPortRatio,s/=-2;break;case"topleft":Math.abs(i)>Math.abs(e)?e=i*this.viewPortRatio:i=e/this.viewPortRatio,r.width-=e,r.height-=i,s=e,o=i;break;case"topright":Math.abs(i)>Math.abs(e)?e=-i*this.viewPortRatio:i=-e/this.viewPortRatio,o=i,r.width+=e,r.height-=i;break;case"bottomleft":Math.abs(i)>Math.abs(e)?e=-i*this.viewPortRatio:i=-e/this.viewPortRatio,s=e,r.width-=e,r.height+=i;break;case"bottomright":Math.abs(i)>Math.abs(e)?e=i*this.viewPortRatio:i=e/this.viewPortRatio,r.width+=e,r.height+=i}this.updateHelper(s,o,r,void 0,void 0)},t.prototype.updateHelper=function(e,i,r,s,o){var a,l,h,u,p,d=this.element.getElementsByTagName("svg")[2].getElementById("helper");r?(a=(h=d.getBBox()).x+e,l=h.y+i,s=h.width+r.width,o=h.height+r.height):(u=this.currentPoint.x>this.startPoint.x?this.currentPoint.x-this.prevPoint.x:this.prevPoint.x-this.currentPoint.x,p=this.currentPoint.y>this.startPoint.y?this.currentPoint.y-this.prevPoint.y:this.prevPoint.y-this.currentPoint.y,Math.abs(p)>Math.abs(u)?u=this.viewPortRatio*p:p=u/this.viewPortRatio,h=d.getBBox(),a=this.startPoint.x>this.currentPoint.x?h.x-u:h.x,l=this.startPoint.y>this.currentPoint.y?h.y-p:h.y,s=h.width+u,o=h.height+p),oi(this.helper,{id:this.helper.id,x:a,y:l,width:Math.max(0,s),height:Math.max(0,o)})},t.prototype.updateOverviewrect=function(e,i,r,s){Ho(document.getElementById(this.canvas.id+"overviewrect"),{x:e,y:i,width:Math.max(1,r),height:Math.max(1,s)}),this.updateOverviewCorner("top",e+8,i+1,Math.max(0,r-16),2),this.updateOverviewCorner("bottom",e+8,i+s+3,Math.max(0,r-16),2),this.updateOverviewCorner("left",e-2,i+11,2,Math.max(0,s-16)),this.updateOverviewCorner("right",e+r,i+11,2,Math.max(0,s-16)),this.updateOverviewCorner("topleft",e,i+3,5,5),this.updateOverviewCorner("topright",e+r,i+3,5,5),this.updateOverviewCorner("bottomleft",e,i+s+3,5,5),this.updateOverviewCorner("bottomright",e+r,i+s+3,5,5)},t.prototype.updateOverviewCorner=function(e,i,r,s,o){var a,l;"top"===e||"bottom"===e||"right"===e||"left"===e?(a={x:i,y:r,width:s,height:o,fill:"#ED1C24"},l={x:i-2,y:r-2,width:2===s?4:s,height:2===o?4:o}):(a={cx:i,cy:r,r:4,fill:"#ED1C24"},l={cx:i,cy:r,r:6,fill:"transparent"}),Ho(document.getElementById(this.canvas.id+"visible"+e),a),Ho(document.getElementById(this.canvas.id+e),l)},t.prototype.translateOverviewRectangle=function(){Number(this.model.width),Number(this.model.height);var r=this.currentPoint.x-this.prevPoint.x,s=this.currentPoint.y-this.prevPoint.y,l=this.element.getElementsByClassName("overviewsvg")[0].getElementById(this.canvas.id+"overviewrect").getBBox(),h=l.x+r,c=l.y+s,d=l.width,u=l.height;this.updateOverviewrect(h,c,d,u),this.updateParentView(this.parent.scroller.currentZoom,h,c,d,u,null)},t.prototype.renderOverviewRect=function(e,i,r,s){var o=Number(this.model.width),a=Number(this.model.height),c=Math.max(this.parent.scroller.viewPortWidth/(r/o*this.contentWidth),this.parent.scroller.viewPortHeight/(s/a*this.contentHeight));if(c>=.25&&c<=30){this.updateParentView(c,e,i,r,s,{x:0,y:0});var u=this.scrollOverviewRect(this.parent.scroller.horizontalOffset,this.parent.scroller.verticalOffset,this.parent.scroller.currentZoom,!0);if(this.helper){var f=this.element.getElementsByTagName("rect")[10].getBBox();u.x=f.x,u.y=f.y}"pan"===this.actionName?this.updateOverviewrect(-u.x,-u.y,u.width,u.height):this.updateOverviewrect(u.x,u.y,u.width,u.height)}},t.prototype.scrollOverviewRect=function(e,i,r,s){if(!this.actionName||s){var o=Number(this.model.width),a=Number(this.model.height),l=Math.min(this.contentWidth/o,this.contentHeight/a),h=new Ne,c=h.x=e/r/l,d=h.y=i/r/l,u=0;this.parent.rulerSettings.showRulers&&(u=25);var p=document.getElementById(this.parent.element.id+"content"),f=0,g=0;p&&(f=p.offsetWidth-p.clientWidth,g=p.offsetHeight-p.clientHeight);var v=h.width=(this.parent.scroller.viewPortWidth-u-f)/r/l,y=h.height=(this.parent.scroller.viewPortHeight-u-g)/r/l;if(s){var S=new Ne;return S.x=c,S.y=d,S.width=v,S.height=y,S}this.updateOverviewrect(-c,-d,v,y)}return null},t.prototype.updateParentView=function(e,i,r,s,o,a){var f,g,l=Number(this.model.width),h=Number(this.model.height),u=i*(this.contentWidth/l)*e,p=r*(this.contentHeight/h)*e;this.parent.scroller.getPageBounds(),(1!==e||"pan"===this.actionName)&&(f=-u-this.parent.scroller.horizontalOffset,g=-p-this.parent.scroller.verticalOffset),this.parent.setBlazorDiagramProps(!0),this.parent.realActions|=$i.OverViewAction,"scale"===this.actionName||"draw"===this.actionName?this.parent.scroller.zoom(e/this.parent.scroller.currentZoom,f,g,a):ce()?this.parent.scroller.zoom(1,f,g,a):this.parent.pan(f,g,a,!0)},t.prototype.updateHtmlLayer=function(e){var i=Io(e.element.id),r=this.parent.scroller.getPageBounds(!0),o=r.height,a=Math.max(r.width,this.parent.scroller.viewPortWidth),l=Math.max(o,this.parent.scroller.viewPortHeight/this.parent.scroller.currentZoom),h=Math.min(Number(this.model.width)/a,Number(this.model.height)/l);i.style.transform="scale("+h+") translate("+this.parent.scroller.transform.tx+"px,"+this.parent.scroller.transform.ty+"px)"},t.prototype.updateView=function(e){var i=this.parent.scroller.getPageBounds(),r=i.width,s=i.height,o=Number(this.model.width),a=Number(this.model.height),l=Math.max(r,this.parent.scroller.viewPortWidth),h=Math.max(s,this.parent.scroller.viewPortHeight);this.contentWidth=l=Math.max(l,o/a*h),this.contentHeight=h=Math.max(h,a/o*l);var c=Math.min(o/l,a/h),d=document.getElementById(this.element.id+"_htmlLayer");d.style.webkitTransform="scale("+c+") translate("+-i.x+"px,"+-i.y+"px)",d.style.transform="scale("+c+") translate("+-i.x+"px,"+-i.y+"px)",document.getElementById(this.element.id+"_overviewlayer").setAttribute("transform","translate("+-i.x*c+","+-i.y*c+")"),this.horizontalOffset=i.x*c,this.verticalOffset=i.y*c;var p=document.getElementById(this.element.id+"_diagramLayer"),f=kF(this.element.id),g=p.getContext("2d"),v=Number(this.model.width)/this.contentWidth,y=Number(this.model.height)/this.contentHeight;v=Math.min(v,y);var S=this.parent.scroller.transform;f.setAttribute("transform","translate("+S.tx*v+","+S.ty*y+"),scale("+v+")"),g.setTransform(v,0,0,v,0,0),g.fillStyle="red",this.scrollOverviewRect(this.parent.scroller.horizontalOffset,this.parent.scroller.verticalOffset,this.parent.scroller.currentZoom)},t.prototype.scrolled=function(e){if(this.event){var i=this.scrollOverviewRect(this.parent.scroller.horizontalOffset,this.parent.scroller.verticalOffset,this.parent.scroller.currentZoom,!0);this.updateOverviewrect(-i.x,-i.y,i.width,i.height),this.updateView(this)}},t.prototype.updateCursor=function(e){if(hm(e.target,"overviewresizer"))switch(e.target.id){case this.canvas.id+"left":this.canvas.style.cursor="w-resize";break;case this.canvas.id+"right":this.canvas.style.cursor="e-resize";break;case this.canvas.id+"top":this.canvas.style.cursor="n-resize";break;case this.canvas.id+"bottom":this.canvas.style.cursor="s-resize";break;case this.canvas.id+"topleft":this.canvas.style.cursor="nw-resize";break;case this.canvas.id+"topright":this.canvas.style.cursor="ne-resize";break;case this.canvas.id+"bottomleft":this.canvas.style.cursor="sw-resize";break;case this.canvas.id+"bottomright":this.canvas.style.cursor="se-resize"}else this.canvas.style.cursor="default"},t.prototype.mouseMove=function(e){if(this.event=!1,this.updateCursor(e),this.currentPoint=this.mousePosition(e),this.actionName)switch(this.actionName){case"draw":!this.inAction&&(this.startPoint.x!==this.currentPoint.x||this.startPoint.y!==this.currentPoint.y)&&(this.initHelper(),this.inAction=!0),this.inAction&&this.updateHelper();break;case"scale":this.inAction||(this.initHelper(),this.inAction=!0),this.updateOverviewRectangle();break;case"pan":(this.startPoint.x!==this.currentPoint.x||this.startPoint.y===this.currentPoint.y||this.inAction)&&(this.inAction=!0,this.translateOverviewRectangle())}this.prevPoint=this.currentPoint},t.prototype.documentMouseUp=function(e){this.inAction=!1,this.actionName="",this.helper&&(this.helper.parentNode.removeChild(this.helper),this.helper=null),this.event=!0,document.getElementById(this.canvas.id+"overviewhandle").style.pointerEvents="all"},t.prototype.windowResize=function(e){var i=this;return this.resizeTo&&clearTimeout(this.resizeTo),this.resizeTo=setTimeout(function(){var s=document.getElementById(i.element.id).getBoundingClientRect();i.model.width=s.width>0?s.width:i.model.width,i.model.height=s.height>0?s.height:i.model.height,i.renderCanvas(),i.setParent(i.sourceID)},10),!1},t.prototype.mouseDown=function(e){if(e.target.id===this.canvas.id+"_overviewsvg"&&(this.actionName="draw"),e.target.id===this.canvas.id+"overviewrect"&&(this.actionName="pan"),hm(e.target,"overviewresizer"))switch(this.actionName="scale",e.target.id){case this.canvas.id+"left":this.resizeDirection="left";break;case this.canvas.id+"right":this.resizeDirection="right";break;case this.canvas.id+"top":this.resizeDirection="top";break;case this.canvas.id+"bottom":this.resizeDirection="bottom";break;case this.canvas.id+"topleft":this.resizeDirection="topleft";break;case this.canvas.id+"topright":this.resizeDirection="topright";break;case this.canvas.id+"bottomleft":this.resizeDirection="bottomleft";break;case this.canvas.id+"bottomright":this.resizeDirection="bottomright"}this.startPoint=this.prevPoint=this.mousePosition(e),this.viewPortRatio=this.parent.scroller.viewPortWidth/this.parent.scroller.viewPortHeight,document.getElementById(this.canvas.id+"overviewhandle").style.pointerEvents="none"},t.prototype.mouseUp=function(e){if(this.currentPoint=this.mousePosition(e),this.actionName)if(this.startPoint.x!==this.currentPoint.x||this.startPoint.y!==this.currentPoint.y){if("pan"!==this.actionName&&this.helper){var i=this.element.getElementsByTagName("rect")[10].getBBox();this.resizeDirection=this.resizeDirection||"",this.renderOverviewRect(i.x,i.y,o=i.width,a=i.height)}}else if(e.target.id===this.canvas.id+"_overviewsvg"||"helper"===e.target.id){var o=(i=this.element.getElementsByTagName("svg")[2].getElementById(this.canvas.id+"overviewrect").getBBox()).width,a=i.height;this.inAction=!0,this.actionName="pan",this.renderOverviewRect(this.currentPoint.x-o/2,this.currentPoint.y-a/2,o,a),this.inAction=!1}this.helper&&(this.helper.parentNode.removeChild(this.helper),this.helper=null),this.actionName="",this.startPoint=null,this.currentPoint=null,this.prevPoint=null,this.helper=null,this.viewPortRatio=1,this.resizeDirection="",this.inAction=!1,this.event=!0,document.getElementById(this.canvas.id+"overviewhandle").style.pointerEvents="all"},t.prototype.initHelper=function(){var e=this.element.getElementsByTagName("svg")[2],i=this.startPoint.x,r=this.startPoint.y,s=1,o=1;if("scale"===this.actionName){var l=e.getElementById(this.canvas.id+"overviewrect").getBBox();i=l.x,r=l.y,s=l.width,o=l.height}var h=Bi("rect",{id:"helper",x:i,y:r,width:s,height:o,fill:"transparent",stroke:"gray","stroke-dasharray":"2 2","shape-rendering":"crispEdges"});e.getElementById(this.element.id+"_overviewlayer").appendChild(h),this.helper=h},t.prototype.mousePosition=function(e){var i,r,s;-1!==e.type.indexOf("touch")?(r=(i=e).changedTouches[0].clientX-this.element.offsetLeft,s=i.changedTouches[0].clientY-this.element.offsetTop):(r=e.clientX,s=e.clientY);var l=this.element.getBoundingClientRect();return{x:(r-=l.left)+this.horizontalOffset,y:(s-=l.top)+this.verticalOffset}},t.prototype.destroy=function(){if(this.unWireEvents(),this.notify("destroy",{}),n.prototype.destroy.call(this),document.getElementById(this.element.id)){this.element.classList.remove("e-overview");var e=document.getElementById(this.element.id+"_canvas");e&&this.element.removeChild(e)}this.parent.views.splice(this.parent.views.indexOf(this.element.id),1),this.diagramLayerDiv=null,this.canvas=null,this.parent=null},t.prototype.getModuleName=function(){return"Overview"},XI([I("100%")],t.prototype,"width",void 0),XI([I("100%")],t.prototype,"height",void 0),XI([I("")],t.prototype,"sourceID",void 0),XI([H()],t.prototype,"created",void 0),t}(yi);function tse(n,t){for(var e=0;ez.findLength(e,n)?e:t;var o=z.findAngle(t,e),a=z.findAngle(i,n),l=z.findLength(i,n),h=a+2*(o-a);return{x:i.x+l*Math.cos(h*Math.PI/180),y:i.y+l*Math.sin(h*Math.PI/180)}}function $p(n,t,e){if(n&&n.children&&n.children.length>0)for(var r=void 0,s=0;s0&&"annotations"!==r&&"ports"!==r)if(n[""+l].length>0)for(var h=0;h<=n[""+l].length;h++)Ro(n[""+l],t?t[""+l]:void 0,e[""+l],"annotations"===l||"ports"===l?n:void 0,l);else Ro(n[""+l],t?t[""+l]:void 0,e[""+l],"annotations"===l||"ports"===l?n:void 0,l);else if(s instanceof Object&&t&&"annotations"!==r&&"ports"!==r)Ro(n[""+l],t[""+l],e[""+l]);else if("annotations"!==r&&"ports"!==r&&t&&!t[""+l]||!t&&n&&(n[""+l]||void 0!==n[""+l]))n[""+l]=e[""+l];else{var c=void 0;("annotations"===r||"ports"===r)&&("annotations"===r?(n[""+l]&&Ro(n[""+l],t[""+l],e[""+l]),n[""+l]||(fs(i)===de?(c=new Nr(i,"annotations",e[""+l]),i.annotations.push(c)):(c=new Zn(i,"annotations",e[""+l]),i.annotations.push(c)))):n[""+l]?Ro(n[""+l],t[""+l],e[""+l]):(c=new Es(i,"ports",e[""+l]),i.ports.push(c)))}}}function lse(n,t){for(var e="Bezier"===n.type?function sse(n){var t=[];if("Bezier"===n.type)for(var e=0,i=0;i0||n.ports.length>0){var p=n.wrapper.children;for(i=3;i0)return{enabled:!1,intersectPt:e};var l=o/s,h=a/s;return l>=0&&l<=1&&h>=0&&h<=1?(e.x=i.x1+l*(i.x2-i.x1),e.y=i.y1+l*(i.y2-i.y1),{enabled:!0,intersectPt:e}):{enabled:!1,intersectPt:e}}function $I(n,t,e,i){var a=Jv(lF(n.x,n.y,t.x,t.y),lF(e.x,e.y,i.x,i.y));return a.enabled?a.intersectPt:{x:0,y:0}}function lF(n,t,e,i){return{x1:Number(n)||0,y1:Number(t)||0,x2:Number(e)||0,y2:Number(i)||0}}function hF(n,t,e){var i=[],s={x:t.topRight.x+(e=e||0),y:t.topRight.y},o={x:t.bottomRight.x,y:t.bottomRight.y-e},a={x:t.bottomLeft.x,y:t.bottomLeft.y+e};return i.push({x:t.topLeft.x-e,y:t.topLeft.y}),i.push(s),i.push(o),i.push(a),i}function zc(n,t,e,i,r,s){var o={},a=e.scroller.transform.scale,h=e.scroller.verticalOffset;return o.x=(i?n.x:t.x)*a+e.scroller.horizontalOffset-r,o.y=(i?n.y:t.y)*a+h-s,o}function cF(n,t){var e=new Ke;return e.data=n.pathData,e.height=n.height>10?n.height-(n.padding.bottom+n.padding.top):n.height,e.width=n.width>10?n.width-(n.padding.left+n.padding.right):n.width,e.visible=n.visibility,e.id=t.id+"_shape",e.inversedAlignment=!1,e.horizontalAlignment="Center",e.verticalAlignment="Center",e.style={fill:n.iconStrokeColor,strokeColor:n.iconStrokeColor,strokeWidth:n.iconStrokeWidth},e.setOffsetWithRespectToBounds(.5,.5,"Fraction"),e.relativeMode="Object",e.description=t.description||"",e}function Gx(n,t,e){var i=Xx(n,t),r=z.findAngle(n[i.index],n[i.index+1]),s=function gse(n){var t;t=n instanceof wI?0:void 0===n.content?10:0;var e=0;switch(n.alignment){case"Center":e=0;break;case"Before":e=-(0+t);break;case"After":e=0+t}return e}(t),o=z.transform(i.point,r+45,s);return i.point=o,i.angle=r,i}function Xx(n,t){for(var r,s,a,l,e=0,i=t.offset,o=[],h=0;h=c)return s=z.findAngle(n[parseInt(d.toString(),10)],n[d+1]),{point:r=z.transform(n[parseInt(d.toString(),10)],s,c-(a||0)),index:l=d};a=o[parseInt(d.toString(),10)]}return{point:r,index:l}}function dF(n,t,e){t%=360;var a,l,s=225;switch(n.alignment){case"Before":t>=45&&t<=135?(l="right",a=.5===n.offset?"center":"top"):t>=s&&t<=315?(l="left",a=.5===n.offset?"center":"bottom"):t>45&&t=45&&t<=135?(l="left",a=.5===n.offset?"center":"top"):t>=s&&t<=315?(l="right",a=.5===n.offset?"center":"bottom"):t>45&&tMath.abs(t.y-n.y)?n.x0)for(var e=0;e=0;r--)("nodes"===i||"connectors"===i)&&(n[""+i][parseInt(r.toString(),10)].wrapper=null),"dataManager"!==i&&(n[""+i][parseInt(r.toString(),10)]=Zx(n[""+i][parseInt(r.toString(),10)],e[""+i][parseInt(r.toString(),10)],void 0!==t[""+i]?t[""+i][parseInt(r.toString(),10)]:[]),("[]"===JSON.stringify(n[""+i][parseInt(r.toString(),10)])||"{}"===JSON.stringify(n[""+i][parseInt(r.toString(),10)])||void 0===n[""+i][parseInt(r.toString(),10)])&&n[""+i].splice(r,1));n=void 0}function Ph(n,t){var e=t.style,i=t;t.canApplyStyle=!0;for(var r=0,s=Object.keys(n);r=0&&n.splice(e,1)}function Zp(n,t,e){var i;n.intermediatePoints=t,n.updateSegmentElement(n,t,n.wrapper.children[0],e);var r=n.sourceDecorator;if("Bezier"===n.type){var s=n.segments[0],o=n.segments[n.segments.length-1];i=[z.isEmptyPoint(o.point2)?o.bezierPoint2:o.point2,z.isEmptyPoint(s.point1)?s.bezierPoint1:s.point1]}else i=n.intermediatePoints;t=n.clipDecorators(n,t,e);var a=n.wrapper.children[0];a.canMeasurePath=!0,n.updateDecoratorElement(a=n.wrapper.children[1],t[0],i[1],r),n.updateDecoratorElement(a=n.wrapper.children[2],t[t.length-1],i[i.length-2],n.targetDecorator),n.updateShapeElement(n)}function Jx(n,t,e){var l,i=n.wrapper,s=t.offset,o=t.size/e.scale,a=t.margin,h=i.offsetX-i.actualSize.width*i.pivot.x,c=i.offsetY-i.actualSize.height*i.pivot.y;if(l={x:0,y:0},n.nodes.length>0){switch(t.side){case"Top":l.x+=h+s*i.actualSize.width,l.y+=c-o;break;case"Bottom":l.x+=h+s*i.actualSize.width,l.y+=c+i.actualSize.height+o;break;case"Left":l.x+=h-o,l.y+=c+s*i.actualSize.height;break;case"Right":l.x+=h+i.actualSize.width+o,l.y+=c+s*i.actualSize.height}l.x+=(a.left-a.right)/e.scale+o/2*("Center"===t.horizontalAlignment?0:"Right"===t.horizontalAlignment?-1:1),l.y+=(a.top-a.bottom)/e.scale+o/2*("Center"===t.verticalAlignment?0:"Top"===t.verticalAlignment?-1:1)}else if(n.connectors.length>0){var d=n.connectors[0],u={offset:s},p=Xx(d.intermediatePoints,u),f=p.index;l=p.point;var y,v=Gx(d.intermediatePoints,u).angle;qi(y=Hi(),-v,d.intermediatePoints[parseInt(f.toString(),10)].x,d.intermediatePoints[parseInt(f.toString(),10)].y),(l=Je(y,l)).x+=a.left-a.right+o/2*("Center"===t.horizontalAlignment?0:"Right"===t.horizontalAlignment?-1:1),l.y+=a.top-a.bottom+o/2*("Center"===t.verticalAlignment?0:"Top"===t.verticalAlignment?-1:1),qi(y=Hi(),v,d.intermediatePoints[parseInt(f.toString(),10)].x,d.intermediatePoints[parseInt(f.toString(),10)].y),l=Je(y,l)}return 0===i.rotateAngle&&0===i.parentTransform||(qi(y=Hi(),i.rotateAngle+i.parentTransform,i.offsetX,i.offsetY),l=Je(y,l)),l}function fa(n,t,e,i){if(i.annotation){if(Ol(i.annotation))return!0}else if(lr[""+t]&n&&bt[""+t]&e)return!0;return!1}function qr(n,t){return!!(lr[""+t]&n)}function Hc(n,t){return!!(Ix[""+t]&n)}function ga(n,t){return n.visibility&t}function ZI(n,t){var e;if("Text"===n.shape.type)e=n.shape;else{var i=t.split("_");t=i[i.length-1];for(var r=0;rn[""+t]?e.splice(0,0,n):e.push(n);else if(e.length>1){for(var i=0,r=e.length-1,s=Math.floor((i+r)/2);s!==i;)if(e[parseInt(s.toString(),10)][""+t]n[""+t]))break;r=s,s=Math.floor((i+r)/2)}e[parseInt(r.toString(),10)][""+t]n[""+t]?e.splice(i,0,n):e[parseInt(i.toString(),10)][""+t]n[""+t]&&e.splice(r,0,n)}}function kse(n){var t=document.getElementById(n.diagramId),e="ej2_instances",i=t[""+e][0].nodes;void 0===i&&(i=function Pse(n){for(var t=[],e=0;e30?10:o/2;for(var h=0,c=0;c=l){var u=l-h;r=Gt(n[c],n[c+1]),s=z.transform(n[c],r,u);break}h+=d}return s},eb=function(n,t){if(n instanceof te||n instanceof de)for(var e=0;e=0||navigator.platform.indexOf("iPad")>=0||navigator.platform.indexOf("iPhone")>=0||navigator.platform.indexOf("MacIntel")>=0)&&("safari"===X.info.name||"webkit"===X.info.name)}function bF(n,t,e,i){return void 0!==t.previewSize[""+i]?t.previewSize[""+i]:void 0!==n.symbolPreview[""+i]?n.symbolPreview[""+i]:t[""+i]||e.actualSize[""+i]}function rm(n,t,e){return n&&n.parentId&&(e=(n=t.nameTable[n.parentId]).parentId?rm(n,t,e):n.id),e}function nm(n,t){return n.selectedItems.connectors.length>1&&0===n.selectedItems.nodes.length&&0!==t.rotateAngle}function Bse(n){if(n.arrowType&&""!==n.arrowType.trim())switch(n.arrowType){case"single-line-arrow":default:return{targetDecorator:"Arrow",strokeWidth:1};case"double-line-arrow":return{targetDecorator:"Arrow",strokeWidth:2};case"dotted-arrow":return{targetDecorator:"Arrow",strokeDashArray:"2,2"};case"single-line":return{targetDecorator:"None",strokeWidth:1};case"double-line":return{targetDecorator:"None",strokeWidth:2};case"dotted":return{targetDecorator:"None",strokeDashArray:"2,2"};case"wiggly-arrow":return{targetDecorator:"None",strokeWidth:1,opacity:0}}return{targetDecorator:"Arrow",strokeWidth:1}}var Fse=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),io=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},MF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Fse(t,n),io([I("None")],t.prototype,"shape",void 0),io([I("white")],t.prototype,"fill",void 0),io([I("Auto")],t.prototype,"horizontalAlignment",void 0),io([I("Auto")],t.prototype,"verticalAlignment",void 0),io([I(10)],t.prototype,"width",void 0),io([I(10)],t.prototype,"height",void 0),io([re({x:.5,y:1},z)],t.prototype,"offset",void 0),io([I("#1a1a1a")],t.prototype,"borderColor",void 0),io([I(1)],t.prototype,"borderWidth",void 0),io([re({},$n)],t.prototype,"margin",void 0),io([I("")],t.prototype,"pathData",void 0),io([I("")],t.prototype,"content",void 0),io([I(0)],t.prototype,"cornerRadius",void 0),io([re({left:2,right:2,top:2,bottom:2},$n)],t.prototype,"padding",void 0),io([I("#1a1a1a")],t.prototype,"iconColor",void 0),t}(Ee),_se=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),iT=function(n){function t(){var e=null!==n&&n.apply(this,arguments)||this;return e.orientation="Vertical",e.measureChildren=void 0,e.considerPadding=!0,e}return _se(t,n),t.prototype.measure=function(e){return this.desiredSize=this.measureStackPanel(e,"Horizontal"===this.orientation?this.updateHorizontalStack:this.updateVerticalStack),this.desiredSize},t.prototype.arrange=function(e){return this.actualSize=this.arrangeStackPanel(e,"Horizontal"===this.orientation?this.arrangeHorizontalStack:this.arrangeVerticalStack),this.updateBounds(),this.actualSize},t.prototype.measureStackPanel=function(e,i){var r=void 0;if(void 0!==this.children&&this.children.length>0)for(var s=0,o=this.children;s0){var r=void 0,s=void 0;r=this.offsetX-e.width*this.pivot.x+this.padding.left,s=this.offsetY-e.height*this.pivot.y+this.padding.top;for(var o=0,a=this.children;o0)for(var i=0,r=this.children;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Xse=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Gse(t,n),zh([I("Horizontal")],t.prototype,"orientation",void 0),zh([I("Center")],t.prototype,"type",void 0),zh([I(void 0)],t.prototype,"offset",void 0),zh([I(!1)],t.prototype,"enableRouting",void 0),zh([I([])],t.prototype,"children",void 0),zh([I("")],t.prototype,"assistants",void 0),zh([I("")],t.prototype,"level",void 0),zh([I("")],t.prototype,"hasSubTree",void 0),zh([I("")],t.prototype,"rows",void 0),t}(Ee),Li=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),q=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},qse=function(n){if(n)switch(n.type){case"Basic":default:return tb;case"Flow":return DF;case"Path":return wF;case"Image":return EF;case"Text":return Pd;case"Bpmn":return lT;case"Native":return sm;case"HTML":return CF;case"UmlActivity":return xF;case"UmlClassifier":return TF;case"SwimLane":return Hd}return tb},va=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),q([I("Basic")],t.prototype,"type",void 0),t}(Ee),wF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"Path"},q([I("Path")],t.prototype,"type",void 0),q([I("")],t.prototype,"data",void 0),t}(va),sm=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"Native"},q([I("Native")],t.prototype,"type",void 0),q([I("")],t.prototype,"content",void 0),q([I("Stretch")],t.prototype,"scale",void 0),t}(va),CF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"Html"},q([I("HTML")],t.prototype,"type",void 0),q([I("")],t.prototype,"content",void 0),t}(va),EF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"Image"},q([I("Image")],t.prototype,"type",void 0),q([I("")],t.prototype,"source",void 0),q([I("None")],t.prototype,"scale",void 0),q([I("None")],t.prototype,"align",void 0),t}(va),Pd=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"Text"},q([I("Text")],t.prototype,"type",void 0),q([I("")],t.prototype,"content",void 0),q([re({},$n)],t.prototype,"margin",void 0),t}(va),tb=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"BasicShape"},q([I("Basic")],t.prototype,"type",void 0),q([I("Rectangle")],t.prototype,"shape",void 0),q([I(0)],t.prototype,"cornerRadius",void 0),q([Bt([],z)],t.prototype,"points",void 0),t}(va),DF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"FlowShape"},q([I("Flow")],t.prototype,"type",void 0),q([I("Terminator")],t.prototype,"shape",void 0),t}(va),nT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"BpmnGateway"},q([I("None")],t.prototype,"type",void 0),t}(Ee),sT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"BpmnDataObject"},q([I("None")],t.prototype,"type",void 0),q([I(!1)],t.prototype,"collection",void 0),t}(Ee),$se=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),q([I("None")],t.prototype,"type",void 0),q([I("None")],t.prototype,"loop",void 0),q([I(!1)],t.prototype,"call",void 0),q([I(!1)],t.prototype,"compensation",void 0),t}(Ee),oT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"BpmnEvent"},q([I("Start")],t.prototype,"event",void 0),q([I("None")],t.prototype,"trigger",void 0),t}(Ee),zd=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"BpmnSubEvent"},q([I("None")],t.prototype,"trigger",void 0),q([I("Start")],t.prototype,"event",void 0),q([I("")],t.prototype,"id",void 0),q([re({},z)],t.prototype,"offset",void 0),q([Bt([],Zn)],t.prototype,"annotations",void 0),q([Bt([],Es)],t.prototype,"ports",void 0),q([I()],t.prototype,"width",void 0),q([I()],t.prototype,"height",void 0),q([re({},$n)],t.prototype,"margin",void 0),q([I("Center")],t.prototype,"horizontalAlignment",void 0),q([I("Center")],t.prototype,"verticalAlignment",void 0),q([I(!0)],t.prototype,"visible",void 0),t}(Ee),Zse=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),q([re({id:"success",event:"End",offset:{x:1,y:.5}},zd)],t.prototype,"success",void 0),q([re({id:"failure",event:"Intermediate",trigger:"Error",offset:{x:.25,y:1}},zd)],t.prototype,"failure",void 0),q([re({id:"cancel",event:"Intermediate",trigger:"Cancel",offset:{x:.75,y:1}},zd)],t.prototype,"cancel",void 0),t}(Ee),Jse=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),q([I("None")],t.prototype,"type",void 0),q([I(!1)],t.prototype,"adhoc",void 0),q([I("Default")],t.prototype,"boundary",void 0),q([I(!1)],t.prototype,"compensation",void 0),q([I("None")],t.prototype,"loop",void 0),q([I(!0)],t.prototype,"collapsed",void 0),q([Bt([],zd)],t.prototype,"events",void 0),q([re({},Zse)],t.prototype,"transaction",void 0),q([I(void 0)],t.prototype,"processes",void 0),t}(Ee),aT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"BpmnActivity"},q([I("Task")],t.prototype,"activity",void 0),q([re({},$se)],t.prototype,"task",void 0),q([re({},Jse)],t.prototype,"subProcess",void 0),t}(Ee),om=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return Li(t,n),t.prototype.getClassName=function(){return"BpmnAnnotation"},q([I("")],t.prototype,"text",void 0),q([I("")],t.prototype,"id",void 0),q([I(0)],t.prototype,"angle",void 0),q([I()],t.prototype,"height",void 0),q([I()],t.prototype,"width",void 0),q([I(0)],t.prototype,"length",void 0),t}(Ee),Kse=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),q([I("")],t.prototype,"textAnnotationTarget",void 0),q([I("Auto")],t.prototype,"textAnnotationDirection",void 0),t}(Ee),lT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"BpmnShape"},q([I("Bpmn")],t.prototype,"type",void 0),q([I("Event")],t.prototype,"shape",void 0),q([re({},oT)],t.prototype,"event",void 0),q([re({},nT)],t.prototype,"gateway",void 0),q([re({},sT)],t.prototype,"dataObject",void 0),q([re({},aT)],t.prototype,"activity",void 0),q([re({},om)],t.prototype,"annotation",void 0),q([Bt([],om)],t.prototype,"annotations",void 0),q([re({},Kse)],t.prototype,"textAnnotation",void 0),t}(va),xF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"UmlActivityShape"},q([I("UmlActivity")],t.prototype,"type",void 0),q([I("Action")],t.prototype,"shape",void 0),t}(va),hT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"MethodArguments"},q([I("")],t.prototype,"name",void 0),q([I("")],t.prototype,"type",void 0),q([re({},Yp)],t.prototype,"style",void 0),t}(Ee),rf=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"UmlClassAttribute"},q([I("Public")],t.prototype,"scope",void 0),q([I(!1)],t.prototype,"isSeparator",void 0),q([re({fill:"#F9F9F9",strokeColor:"#CCCCCC"},Al)],t.prototype,"separatorStyle",void 0),t}(hT),am=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"UmlClassMethod"},q([Bt([],hT)],t.prototype,"parameters",void 0),t}(rf),ib=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"UmlClass"},q([I("")],t.prototype,"name",void 0),q([Bt([],rf)],t.prototype,"attributes",void 0),q([Bt([],am)],t.prototype,"methods",void 0),q([re({},Yp)],t.prototype,"style",void 0),t}(Ee),cT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"UmlInterface"},q([I(!1)],t.prototype,"isSeparator",void 0),q([re({fill:"#F9F9F9",strokeColor:"#CCCCCC"},Al)],t.prototype,"separatorStyle",void 0),t}(ib),rb=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"UmlEnumerationMember"},q([I("")],t.prototype,"name",void 0),q([I("")],t.prototype,"value",void 0),q([I(!1)],t.prototype,"isSeparator",void 0),q([re({fill:"#F9F9F9",strokeColor:"#CCCCCC"},Al)],t.prototype,"separatorStyle",void 0),q([re({},Yp)],t.prototype,"style",void 0),t}(Ee),dT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"UmlEnumeration"},q([I("")],t.prototype,"name",void 0),q([Bt([],rb)],t.prototype,"members",void 0),q([re({},Yp)],t.prototype,"style",void 0),t}(Ee),TF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"UmlClassifierShape"},q([I("UmlClassifier")],t.prototype,"type",void 0),q([re({},ib)],t.prototype,"classShape",void 0),q([re({},cT)],t.prototype,"interfaceShape",void 0),q([re({},dT)],t.prototype,"enumerationShape",void 0),q([I("Class")],t.prototype,"classifier",void 0),t}(va),te=function(n){function t(e,i,r,s){var a,o=n.call(this,e,i,r,s)||this;return o.isCanvasUpdate=!1,o.status="None",o.parentId="",o.processId="",o.umlIndex=-1,o.outEdges=[],o.inEdges=[],o.isHeader=!1,o.isLane=!1,o.isPhase=!1,o.children&&o.children.length>0&&((!(a=r).style||!a.style.fill)&&(o.style.fill="transparent"),(!a.style||!a.style.strokeColor)&&(o.style.strokeColor="transparent")),o.shape&&"UmlActivity"===o.shape.type&&qI(r,o),o.shape&&"SwimLane"===o.shape.type&&sF(r,o),o.ports&&o.ports.length&&function rse(n){for(var t=0;t>";t=n;break;case"FinalNode":t=uF(e)}return t}(new Ke,i,this);break;case"Bpmn":if(e.bpmnModule){i=e.bpmnModule.initBPMNContent(i,this,e),this.wrapper.elementActions=this.wrapper.elementActions|Xr.ElementIsGroup;var v=this.shape.activity.subProcess;if(v.processes&&v.processes.length)for(var S=0,b=this.shape.activity.subProcess.processes;S>",margin:{left:10,right:10},id:"class",style:{fontSize:i.style.fontSize,color:i.style.color,fill:i.style.fill,textWrapping:r},offset:{x:.5,y:.3},constraints:Lr.ReadOnly}],constraints:(ie.Default|ie.HideThumbs)&~(ie.Rotate|ie.Drag|ie.Resize),verticalAlignment:"Stretch",horizontalAlignment:"Stretch",style:{fill:t.style.fill,strokeColor:"black"===t.style.strokeColor?"#ffffff00":t.style.strokeColor}},!0);return e.initObject(s),e.nodes.push(s),e.UpdateBlazorDiagramModel(s,"Node"),t.children.push(s.id),function jse(n,t,e,i){if("Enumeration"===n.shape.classifier){var r=e.members;if(r&&r.length){ef(n,t);for(var s="",o=0;o0)for(var o=0;o0&&s.phaseSize&&(i+=s.phaseSize,Yv(n,s.phaseSize)),s.lanes.length>0)for(o=0;o0){var a=0;for(o=0;o0&&"Horizontal"===r.orientation)for(l=0;l0&&(i+=r.phaseSize,o=Qv(r.phaseSize),n.push(o)),a=0;a0&&o.phaseSize){for(var l=0;l0)for(l=0;l0?e.nameTable[this.nodes[0].id].wrapper:e.nameTable[this.connectors[0].id].wrapper,this.annotation.id);i.children.push(s)}else if(this.nodes||this.connectors){for(var o=0;o-1}function zF(n,t,e){n=[];for(var i=0,r=e.length;i0?c.getElementsByTagName("svg")[0].outerHTML:c.getElementsByTagName("g").length>0?c.getElementsByTagName("g")[0].outerHTML:"",s.shape.content=h,n.content=h,c.parentElement.removeChild(c)}l="nodeTemplate"}else a=s,l="annotationTemplate";var f=document.getElementById(n.diagramId).ej2_instances[0];if("string"!=typeof n.content&&"function"!=typeof n.content||n.isTemplate)if(n.isTemplate){if(v=void 0,v=f.isReact?n.getNodeTemplate()($(e),f,l+"_"+("nodeTemplate"===l?e.id:n.nodeId+e.id),void 0,void 0,!1,i):f.isVue||f.isVue3?n.getNodeTemplate()?n.getNodeTemplate()($(e),f,l+"_"+("nodeTemplate"===l?e.id:n.nodeId+e.id),void 0,void 0,!1,i):(v=ii("nodeTemplate"===l?f.nodeTemplate:f.annotationTemplate))($(e),f,l+"_"+("nodeTemplate"===l?e.id:n.nodeId+e.id),void 0,void 0,!1,i):n.getNodeTemplate()($(e),f,l+"_"+("nodeTemplate"===l?e.id:n.nodeId+e.id),void 0,void 0,!1))for(var M=0;M=1&&0===n.x&&("Clip"===i.textOverflow||"Ellipsis"===i.textOverflow)&&("Wrap"===i.textWrapping||"WrapWithOverflow"===i.textWrapping)&&(n.x=t[e-1]?t[e-1].x:-n.width/2),n.x}function BF(n,t,e,i){return e&&!t.template||t.template&&"function"==typeof t.template&&i.isReact?(n.isTemplate=!0,n.template=n.content=Rh(n,!0,t)):n.content=t.template,n}function Qe(){for(var e,t="",i=0;i<5;i++){if(typeof window<"u"&&"crypto"in window&&"getRandomValues"in crypto){var r=new Uint16Array(1);e=(window.msCrypto||window.crypto).getRandomValues(r)[0]%60}else e=Math.floor(61*Math.random());0===i&&e<10?i--:t+="0123456789ABCDEFGHIJKLMNOPQRSTUVWXTZabcdefghiklmnopqrstuvwxyz".substring(e,e+1)}return t}function FF(n){if(n)try{return"function"!=typeof n&&document.querySelectorAll(n).length?ii(document.querySelector(n).innerHTML.trim()):ii(n)}catch{return ii(n)}}function En(n){new Ne;var e=n.offsetY-n.actualSize.height*n.pivot.y,i=n.offsetY+n.actualSize.height*(1-n.pivot.y),r=n.offsetX-n.actualSize.width*n.pivot.x,s=n.offsetX+n.actualSize.width*(1-n.pivot.x);return Ne.toBounds([{x:r,y:e},{x:s,y:e},{x:r,y:i},{x:s,y:i}])}function yr(n){var t=new Ne,e=En(n),i=e.middleLeft,r=e.topCenter,s=e.bottomCenter,o=e.middleRight,a=e.topLeft,l=e.topRight,h=e.bottomLeft,c=e.bottomRight;if(n.corners={topLeft:a,topCenter:r,topRight:l,middleLeft:i,middleRight:o,bottomLeft:h,bottomCenter:s,bottomRight:c},0!==n.rotateAngle||0!==n.parentTransform){var d=Hi();qi(d,n.rotateAngle+n.parentTransform,n.offsetX,n.offsetY),n.corners.topLeft=a=Je(d,a),n.corners.topCenter=r=Je(d,r),n.corners.topRight=l=Je(d,l),n.corners.middleLeft=i=Je(d,i),n.corners.middleRight=o=Je(d,o),n.corners.bottomLeft=h=Je(d,h),n.corners.bottomCenter=s=Je(d,s),n.corners.bottomRight=c=Je(d,c)}return t=Ne.toBounds([a,l,h,c]),n.corners.left=t.left,n.corners.right=t.right,n.corners.top=t.top,n.corners.bottom=t.bottom,n.corners.center=t.center,n.corners.width=t.width,n.corners.height=t.height,t}function $(n,t,e,i){var r={},s="properties";if(n){e=n.propName;var l=[],h=[];if((l=l.concat(Object.keys(n[""+s]||n))).push("version"),e){var c=Zi(t);h=c?c(e):[],l=l.concat(h)}for(var d=function Soe(n){switch(n){case"nodes":case"children":return["inEdges","outEdges","parentId","processId","nodeId","umlIndex","isPhase","isLane"];case"connectors":return["parentId"];case"annotation":case"annotations":return["nodeId"];case"shape":return["hasHeader"];case"layers":return["objectZIndex"]}return[]}(e),u=0,p=l=l.concat(d);u0&&(e=r),r=Math.floor(boe(e,i)),s=Bc(o+=n.substr(e,r),t)}while(s<=t.width);for(o=o.substr(0,e),a=e;a=t.width){n=n.substr(0,o.length-1);break}return"Ellipsis"===t.textOverflow?(n=n.substr(0,n.length-3),n+="..."):n=n.substr(0,n.length),n}function yT(n,t){if("NoWrap"===t&&"PreserveAll"===n)return"pre";var e="";switch(n){case"CollapseAll":e="nowrap";break;case"CollapseSpace":e="pre-line";break;case"PreserveAll":e="pre-wrap"}return e}function ST(n,t){var e=Hi();qi(e,t,0,0);var i=Je(e,{x:0,y:0}),r=Je(e,{x:n.width,y:0}),s=Je(e,{x:0,y:n.height}),o=Je(e,{x:n.width,y:n.height}),a=Math.min(i.x,r.x,s.x,o.x),l=Math.min(i.y,r.y,s.y,o.y),h=Math.max(i.x,r.x,s.x,o.x),c=Math.max(i.y,r.y,s.y,o.y);return new me(h-a,c-l)}function xs(n,t,e,i){if(0!==n){var r=Hi();return qi(r,n,t,e),Je(r,i)}return i}function Zi(n){return void 0!==n&&"string"==typeof n&&(n=Y(n,window)),n}var bo=function(){function n(){}return n.getContext=function(t){return t.getContext("2d")},n.setCanvasSize=function(t,e,i){t&&(t.setAttribute("width",e.toString()),t.setAttribute("height",i.toString()))},n.prototype.renderGradient=function(t,e,i,r){var s,o,a;if("None"!==t.gradient.type){for(var l=0;l0?(w=0===S.r1?e.arc[parseInt(r.toString(),10)].r1:S.r1,C=0===S.r2?e.arc[parseInt(r.toString(),10)].r2:S.r2,r++):(w=S.r1,C=S.r2);var D=S.angle*(Math.PI/180),A=S.largeArc,x=S.sweep,R={x:u,y:p},L={x:Math.cos(D)*(M.x-R.x)/2+Math.sin(D)*(M.y-R.y)/2,y:-Math.sin(D)*(M.x-R.x)/2+Math.cos(D)*(M.y-R.y)/2},O=Math.pow(L.x,2)/Math.pow(w,2)+Math.pow(L.y,2)/Math.pow(C,2);O>1&&(w*=Math.sqrt(O),C*=Math.sqrt(O));var N=Math.pow(C,2)*Math.pow(L.x,2),T=(A===x?-1:1)*Math.sqrt((Math.pow(w,2)*Math.pow(C,2)-Math.pow(w,2)*Math.pow(L.y,2)-N)/(Math.pow(w,2)*Math.pow(L.y,2)+Math.pow(C,2)*Math.pow(L.x,2)));isNaN(T)&&(T=0);var P={x:T*w*L.y/C,y:T*-C*L.x/w},_={x:(M.x+R.x)/2+Math.cos(D)*P.x-Math.sin(D)*P.y,y:(M.y+R.y)/2+Math.sin(D)*P.x+Math.cos(D)*P.y},B=this.a([1,0],[(L.x-P.x)/w,(L.y-P.y)/C]),j=[(L.x-P.x)/w,(L.y-P.y)/C],Q=[(-L.x-P.x)/w,(-L.y-P.y)/C],oe=this.a(j,Q);this.r(j,Q)<=-1&&(oe=Math.PI),this.r(j,Q)>=1&&(oe=0);var pe=B+oe/2*(x?1:-1);if(Math.cos(pe),Math.sin(pe),S.centp=_,S.xAxisRotation=D,S.rx=w,S.ry=C,S.a1=B,S.ad=oe,S.sweep=x,null!=s){var De=w>C?w:C,xe=w>C?1:w/C,Ie=w>C?C/w:1;s.save(),s.translate(_.x,_.y),s.rotate(D),s.scale(xe,Ie),s.arc(0,0,De,B,B+oe,!x),s.scale(1/xe,1/Ie),s.rotate(-D),s.translate(-_.x,-_.y),s.restore()}break;case"Z":case"z":s.closePath(),u=o,p=a}o=u,a=p}}},n.prototype.drawText=function(t,e,i,r,s,o,a){if(e.content&&!0===e.visible){var l=n.getContext(t);l.save(),this.setStyle(t,e),o&&(e.fontSize*=o),this.rotateContext(t,e.angle,e.x+e.width*e.pivotX,e.y+e.height*e.pivotY),this.setFontStyle(t,e);var u,d=0;u=e.childNodes;var p=e.wrapBounds;if(l.fillStyle=e.color,p){var f=this.labelAlign(e,p,u);for(d=0;de.width&&"Wrap"!==e.textOverflow&&"NoWrap"===e.textWrapping&&(g.text=UF(g.text,e)),"Clip"!==e.textOverflow&&"Ellipsis"!==e.textOverflow||"Wrap"!==e.textWrapping?l.fillText(g.text,v,y):ya.actualSize.height+a.bounds.y&&(g.text=g.text.slice(0,g.text.length-3),g.text=g.text.concat("...")),l.fillText(g.text,v,y)),"Underline"===e.textDecoration||"Overline"===e.textDecoration||"LineThrough"===e.textDecoration){var M=v,w=void 0,D=v+l.measureText(g.text).width,A=void 0;switch(e.textDecoration){case"Underline":w=y+2,A=y+2;break;case"Overline":w=f.y+g.dy*d,A=f.y+g.dy*d;break;case"LineThrough":w=(y+f.y+g.dy*d)/2+2,A=(y+f.y+g.dy*d)/2+2}l.beginPath(),l.moveTo(M,w),l.lineTo(D,A),l.strokeStyle=e.color,l.lineWidth=.08*e.fontSize,l.globalAlpha=e.opacity,l.stroke()}}}l.restore()}},n.prototype.loadImage=function(t,e,i,r,s){this.rotateContext(i,e.angle,r,s);var o=new Image;o.src=e.source,this.image(t,o,e.x,e.y,e.width,e.height,e)},n.prototype.drawImage=function(t,e,i,r){var s=this;if(e.visible){var o=n.getContext(t);o.save();var a=e.x+e.width*e.pivotX,l=e.y+e.height*e.pivotY,h=new Image;h.src=e.source,o.canvas.id.split("_"),r?h.onload=function(){s.loadImage(o,e,t,a,l)}:this.loadImage(o,e,t,a,l),o.restore()}},n.prototype.image=function(t,e,i,r,s,o,a){t.beginPath();var l=e.width,h=e.height,c=s,d=o,u=0,p=0;if(a&&"None"!==a.alignment){var f=a.alignment.toLowerCase().substr(1,3),g=a.alignment.toLowerCase().substr(5,3);if("Slice"===a.scale){var v=function(){u=c,p=h*c/l},y=function(){u=l*d/h,p=d};c>d?(v(),d>p&&y()):c===d?l>h?y():v():(y(),c>u&&v());var S=this.getSliceOffset(f,u,c,l),b=this.getSliceOffset(g,p,d,h),M=l-S,w=h-b,C=u-S*(u/l),D=p-b*(p/h),A=Tt("canvas",{width:s.toString(),height:o.toString()});A.getContext("2d").drawImage(e,S,b,M,w,0,0,C,D),t.drawImage(A,i,r,s,o)}else if("Meet"===a.scale){var R=h/l,L=d/c;p=L>R?c*R:d,i+=this.getMeetOffset(f,u=L>R?c:d/R,c),r+=this.getMeetOffset(g,p,d),t.drawImage(e,0,0,l,h,i,r,u,p)}else t.drawImage(e,i,r,s,o)}else if("None"!==a.flip){var O=1,N=1;("Horizontal"===a.flip||"Both"===a.flip)&&(i=-i,s=-s,O=-1),("Vertical"===a.flip||"Both"===a.flip)&&(r=-r,o=-o,N=-1),t.scale(O,N),t.drawImage(e,i,r,s,o)}else t.drawImage(e,i,r,s,o);t.closePath()},n.prototype.getSliceOffset=function(t,e,i,r){switch(t){case"min":default:return 0;case"mid":return(e-i)/2*r/e;case"max":return(e-i)*r/e}},n.prototype.getMeetOffset=function(t,e,i){var r=Math.max(e,i),s=Math.min(e,i);switch(t){case"min":default:return 0;case"mid":return(r-s)/2;case"max":return r-s}},n.prototype.m=function(t){return Math.sqrt(Math.pow(t[0],2)+Math.pow(t[1],2))},n.prototype.r=function(t,e){return(t[0]*e[0]+t[1]*e[1])/(this.m(t)*this.m(e))},n.prototype.a=function(t,e){return(t[0]*e[1]t.width&&("Ellipsis"===t.textOverflow||"Clip"===t.textOverflow)&&"NoWrap"===t.textWrapping?0:.5*t.width:"right"===t.textAlign&&(c=1*t.width),s.x=t.x+c+(e?e.x:0),s.y=a+d-r.height/2,s},n}(),lb=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Vi=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},woe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return lb(t,n),Vi([I("")],t.prototype,"source",void 0),Vi([I("transparent")],t.prototype,"color",void 0),Vi([I("None")],t.prototype,"scale",void 0),Vi([I("None")],t.prototype,"align",void 0),t}(Ee),Coe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return lb(t,n),Vi([I("Page")],t.prototype,"mode",void 0),Vi([I("PageSettings")],t.prototype,"region",void 0),Vi([re({top:25,bottom:25,left:25,right:25},$n)],t.prototype,"margin",void 0),Vi([I(!1)],t.prototype,"canZoomIn",void 0),Vi([I(void 0)],t.prototype,"customBounds",void 0),Vi([I(!1)],t.prototype,"canFit",void 0),t}(Ee),Eoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return lb(t,n),Vi([I(null)],t.prototype,"width",void 0),Vi([I(null)],t.prototype,"height",void 0),Vi([re({},$n)],t.prototype,"margin",void 0),Vi([I("Landscape")],t.prototype,"orientation",void 0),Vi([I("Infinity")],t.prototype,"boundaryConstraints",void 0),Vi([re({},woe)],t.prototype,"background",void 0),Vi([I(!1)],t.prototype,"multiplePage",void 0),Vi([I(!1)],t.prototype,"showPageBreaks",void 0),Vi([re({},Coe)],t.prototype,"fitOptions",void 0),t}(Ee),Doe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return lb(t,n),Vi([I(0)],t.prototype,"horizontalOffset",void 0),Vi([I(0)],t.prototype,"verticalOffset",void 0),Vi([I(1)],t.prototype,"currentZoom",void 0),Vi([I(0)],t.prototype,"viewPortWidth",void 0),Vi([I(0)],t.prototype,"viewPortHeight",void 0),Vi([I(.2)],t.prototype,"minZoom",void 0),Vi([I(30)],t.prototype,"maxZoom",void 0),Vi([I("Diagram")],t.prototype,"scrollLimit",void 0),Vi([I()],t.prototype,"scrollableArea",void 0),Vi([I(!1)],t.prototype,"canAutoScroll",void 0),Vi([I(100)],t.prototype,"autoScrollFrequency",void 0),Vi([re({left:15,right:15,top:15,bottom:15},$n)],t.prototype,"autoScrollBorder",void 0),Vi([re({left:0,right:0,top:0,bottom:0},$n)],t.prototype,"padding",void 0),Vi([I(.2)],t.prototype,"zoomFactor",void 0),t}(Ee),xoe=function(){function n(){this.services={}}return n.prototype.register=function(t,e){this.services[""+t]=e},n.prototype.getService=function(t){return this.services[""+t]},n}(),jF=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),ma=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},VF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return jF(t,n),ma([I("lightgray")],t.prototype,"lineColor",void 0),ma([I("")],t.prototype,"lineDashArray",void 0),ma([I([1.25,18.75,.25,19.75,.25,19.75,.25,19.75,.25,19.75])],t.prototype,"lineIntervals",void 0),ma([I([1,19,.5,19.5,.5,19.5,.5,19.5,.5,19.5])],t.prototype,"dotIntervals",void 0),ma([I([20])],t.prototype,"snapIntervals",void 0),t}(Ee),Toe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return jF(t,n),ma([re({},VF)],t.prototype,"horizontalGridlines",void 0),ma([re({},VF)],t.prototype,"verticalGridlines",void 0),ma([I(Kt.All)],t.prototype,"constraints",void 0),ma([I(5)],t.prototype,"snapAngle",void 0),ma([I("Lines")],t.prototype,"gridType",void 0),ma([I(5)],t.prototype,"snapObjectDistance",void 0),ma([I("#07EDE1")],t.prototype,"snapLineColor",void 0),t}(Ee),WF=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Ja=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},YF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return WF(t,n),Ja([I(5)],t.prototype,"interval",void 0),Ja([I(100)],t.prototype,"segmentWidth",void 0),Ja([I("Horizontal")],t.prototype,"orientation",void 0),Ja([I("RightOrBottom")],t.prototype,"tickAlignment",void 0),Ja([I("red")],t.prototype,"markerColor",void 0),Ja([I(25)],t.prototype,"thickness",void 0),Ja([I(null)],t.prototype,"arrangeTick",void 0),t}(Ee),Aoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return WF(t,n),Ja([I(!1)],t.prototype,"showRulers",void 0),Ja([I(!0)],t.prototype,"dynamicGrid",void 0),Ja([re({orientation:"Horizontal"},YF)],t.prototype,"horizontalRuler",void 0),Ja([re({orientation:"Vertical"},YF)],t.prototype,"verticalRuler",void 0),t}(Ee),Loe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),QF=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Noe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Loe(t,n),QF([I("")],t.prototype,"property",void 0),QF([I("")],t.prototype,"field",void 0),t}(Ee),IT=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),ln=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},GF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return IT(t,n),ln([I("")],t.prototype,"read",void 0),ln([I("")],t.prototype,"create",void 0),ln([I("")],t.prototype,"update",void 0),ln([I("")],t.prototype,"destroy",void 0),ln([I()],t.prototype,"customFields",void 0),t}(Ee),Ooe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return IT(t,n),ln([I("")],t.prototype,"id",void 0),ln([I("")],t.prototype,"sourceID",void 0),ln([I("")],t.prototype,"targetID",void 0),ln([I(null)],t.prototype,"sourcePointX",void 0),ln([I(null)],t.prototype,"sourcePointY",void 0),ln([I(null)],t.prototype,"targetPointX",void 0),ln([I(null)],t.prototype,"targetPointY",void 0),ln([I(null)],t.prototype,"dataManager",void 0),ln([re({},GF)],t.prototype,"crudAction",void 0),t}(Ee),koe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return IT(t,n),ln([I("")],t.prototype,"id",void 0),ln([I(null)],t.prototype,"dataManager",void 0),ln([I(null)],t.prototype,"dataSource",void 0),ln([I("")],t.prototype,"root",void 0),ln([I("")],t.prototype,"parentId",void 0),ln([I()],t.prototype,"doBinding",void 0),ln([Bt([],Noe)],t.prototype,"dataMapSettings",void 0),ln([re({},GF)],t.prototype,"crudAction",void 0),ln([re({},Ooe)],t.prototype,"connectionDataSource",void 0),t}(Ee),XF=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Cr=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Poe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return XF(t,n),Cr([I("LeftInFlow")],t.prototype,"yesBranchDirection",void 0),Cr([I("RightInFlow")],t.prototype,"noBranchDirection",void 0),Cr([I(["Yes","True"])],t.prototype,"yesBranchValues",void 0),Cr([I(["No","False"])],t.prototype,"noBranchValues",void 0),t}(Ee),zoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return XF(t,n),Cr([I("")],t.prototype,"fixedNode",void 0),Cr([I(30)],t.prototype,"horizontalSpacing",void 0),Cr([I("SamePoint")],t.prototype,"connectionPointOrigin",void 0),Cr([I("Nonlinear")],t.prototype,"arrangement",void 0),Cr([I(30)],t.prototype,"verticalSpacing",void 0),Cr([I(30)],t.prototype,"maxIteration",void 0),Cr([I(40)],t.prototype,"springFactor",void 0),Cr([I(50)],t.prototype,"springLength",void 0),Cr([re({left:50,top:50,right:0,bottom:0},$n)],t.prototype,"margin",void 0),Cr([I("Auto")],t.prototype,"horizontalAlignment",void 0),Cr([I("Auto")],t.prototype,"verticalAlignment",void 0),Cr([I("TopToBottom")],t.prototype,"orientation",void 0),Cr([I("Auto")],t.prototype,"connectionDirection",void 0),Cr([I("Default")],t.prototype,"connectorSegments",void 0),Cr([I("None")],t.prototype,"type",void 0),Cr([I()],t.prototype,"getLayoutInfo",void 0),Cr([I()],t.prototype,"layoutInfo",void 0),Cr([I()],t.prototype,"getBranch",void 0),Cr([I()],t.prototype,"bounds",void 0),Cr([I(!0)],t.prototype,"enableAnimation",void 0),Cr([I(!1)],t.prototype,"enableRouting",void 0),Cr([I("")],t.prototype,"root",void 0),Cr([re({},Poe)],t.prototype,"flowchartLayoutSettings",void 0),t}(Ee),Roe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),qF=function(n){function t(e,i){var r=n.call(this,e,!0)||this;return r.oldValue=null,r.endPoint=i,r}return Roe(t,n),t.prototype.mouseDown=function(e){var i,r=!0;if(e.source&&e.source.connectors&&(i=e.source.connectors[0]),e.info&&e.actualObject&&(r=e.info.ctrlKey&&"Orthogonal"!==e.actualObject.type),i&&r){this.inAction=!0,this.undoElement=$(e.source),n.prototype.mouseDown.call(this,e);for(var s=0;s0)1!==s&&this.removePrevSegment(i,s);else if(a){var l=z.distancePoints(a.points[0],a.points[1]);Math.abs(a.length||0===a.length?a.length:l)<=5&&this.removeNextSegment(i,s)}this.commandHandler.updateEndPoint(i,r),i.selectedSegmentIndex=0}if(this.undoElement){var c=$(e.source);this.commandHandler.addHistoryEntry({type:"SegmentChanged",redoObject:c,undoObject:this.undoElement,category:"Internal"})}if(i.isBezierEditing&&(i.isBezierEditing=!1),this.prevPosition!==this.startPosition){var u={source:i,state:"Completed",oldValue:this.oldValue,newValue:$(this.selectedSegment),cancel:!1,segment:this.selectedSegment};this.commandHandler.triggerEvent(Ce.segmentChange,u)}n.prototype.mouseUp.call(this,e)},t.prototype.removePrevSegment=function(e,i){var r=e.segments[i-2],s=e.segments[i+1];if(s&&!((s.length||0===s.length?s.length:z.distancePoints(s.points[0],s.points[1]))<=5)){var a=e.segments.slice(i-1,i+1),l={element:e,removeSegments:a,type:"Removal",cancel:!1};if(this.commandHandler.triggerEvent(Ce.segmentCollectionChange,l),!l.cancel){var h=e.segments[i+1];e.segments.splice(i-1,2);var c=this.selectedSegment;"Left"===c.direction||"Right"===c.direction?(r.points[r.points.length-1].x=h.points[0].x,h.points[0].y=r.points[r.points.length-1].y):(r.points[r.points.length-1].y=h.points[0].y,h.points[0].x=r.points[r.points.length-1].x),(c.length||0===c.length)&&this.findSegmentDirection(r),this.findSegmentDirection(h)}}},t.prototype.findSegmentDirection=function(e){e.direction&&(e.length||0===e.length)&&(e.length=z.distancePoints(e.points[0],e.points[e.points.length-1]),e.direction=z.direction(e.points[0],e.points[e.points.length-1]))},t.prototype.removeNextSegment=function(e,i){var l,h,r=this.selectedSegment,s=e.segments[i-1],o=e.segments[i+2],a=e.segments[i+1];if(a.length||0===a.length?(l=e.segments.slice(i,2),h={element:e,removeSegments:l,type:"Removal",cancel:!1},this.commandHandler.triggerEvent(Ce.segmentCollectionChange,h={element:e,removeSegments:l,type:"Removal",cancel:!1}),h.cancel||(e.segments.splice(i,2),"Top"===r.direction||"Bottom"===r.direction?(o.points[0].y=r.points[0].y,s.points[s.points.length-1].x=o.points[0].x):(o.points[0].x=r.points[0].x,s.points[s.points.length-1].y=o.points[0].y))):(l=e.segments.slice(i+1,1),this.commandHandler.triggerEvent(Ce.segmentCollectionChange,h={element:e,removeSegments:l,type:"Removal",cancel:!1}),h.cancel||(e.segments.splice(i+1,1),"Top"===r.direction||"Bottom"===r.direction?s.points[s.points.length-1].x=a.points[a.points.length-1].x:s.points[s.points.length-1].y=a.points[a.points.length-1].y,this.findSegmentDirection(s),r.length=r.direction=null)),s&&o&&!h.cancel&&(s.length=z.distancePoints(s.points[0],o.points[0]),s.direction=z.direction(s.points[0],o.points[0]),o.length||0===o.length)){o.length=z.distancePoints(s.points[s.points.length-1],o.points[o.points.length-1]);var c=s.points,d=o.points;o.direction=z.direction(c[c.length-1],d[d.length-1])}},t.prototype.addOrRemoveSegment=function(e,i,r){for(var s,o,a=[],l={segments:e.segments},h=0;h0?"Bottom":"Top":r>0?"Right":"Left",length:i.points[0].x===i.points[1].x?s:r},!0)),l.push(new bi(e,"segments",{type:"Orthogonal",direction:c,length:h/2},!0));var p={element:e,addSegments:l,type:"Addition",cancel:!1};return this.commandHandler.triggerEvent(Ce.segmentCollectionChange,p),p.cancel||(e.segments=l.concat(e.segments),a=o+2),a},t.prototype.insertFirstSegment=function(e,i,r,s,o){var a,l,d,u,h=[];if(e.sourcePortID&&i.length&&e.segments[0].points.length>2)for(var p=void 0,f=0;f0?"Bottom":"Top":r>0?"Right":"Left"),p=u,h.push(u)}else h.push(new bi(e,"segments",{type:"Orthogonal",direction:i.direction,length:i.length/3},!0)),"Bottom"===i.direction||"Top"===i.direction?(l=Math.abs(r),a=r>0?"Right":"Left"):(l=Math.abs(s),a=s>0?"Bottom":"Top"),u=new bi(e,"segments",{type:"Orthogonal",direction:a,length:l},!0),h.push(u);var y={element:e,addSegments:h,type:"Addition",cancel:!1};if(this.commandHandler.triggerEvent(Ce.segmentCollectionChange,y),!y.cancel){if(e.sourcePortID&&i.length&&e.segments[0].points.length>2)e.segments.splice(0,1),d=1;else{var S=e.segments[1];S&&S.length&&(S.length=a!==S.direction?S.length+l:S.length-l),d=2,i.length=2*i.length/3}e.segments=h.concat(e.segments)}return d},t.prototype.updateAdjacentSegments=function(e,i,r,s){var o=e.segments[parseInt(i.toString(),10)],a=o.points[o.points.length-1],h=!0;"Orthogonal"===o.type&&(o.points[0]=o.points[0],o.points[o.points.length-1]=a,e.segments[i-1]&&(h=this.updatePreviousSegment(r,s,e,i)),e.segments.length-1>i&&h&&this.updateNextSegment(e,o,e.segments[i+1],r,s))},t.prototype.addTerminalSegment=function(e,i,r,s,o){var l,h,c,d,a=e.segments.indexOf(i),u=[],p=e.segments.pop(),f=e.segments[e.segments.length-1];l=f&&"Orthogonal"===f.type?f:null;for(var g=0;g0&&"Left"===o.direction?c.middleLeft:c.middleRight,o.length>c.width/2?Math.abs(a.length)0&&"Top"===o.direction?c.topCenter:c.bottomCenter,o.length>c.height/2?Math.abs(a.length)1)for(var a=0,l=this.diagram.views;a0)for(var e=t===Ce.onUserHandleMouseLeave?this.previousAction:this.action,i={element:void 0},r=0;r0)for(var r={element:void 0},s=void 0,o=void 0,a=0;a-1&&(o=s,this.previousTarget=i,this.targetItem=e),o===e.fixedUserHandles[parseInt(a.toString(),10)].id&&(r.element=e.fixedUserHandles[parseInt(a.toString(),10)],this.userHandle(t,a,r,e))},n.prototype.mouseDown=function(t){if(!0!==this.inAction||!(this.tool instanceof UI||this.tool instanceof pa)){this.focus=!0;var e=t.touches,i=!!document.getElementsByClassName("e-dragclone")[0];if(this.isMouseOnScrollBar(t)&&!i)return this.isScrolling=!0,void t.preventDefault();if(this.checkFixedUserHandleEvent(Ce.onFixedUserHandleMouseDown,this.targetItem,this.previousTarget),this.checkUserHandleEvent(Ce.onUserHandleMouseDown),!this.checkEditBoxAsTarget(t)&&_v(this.diagram)||Lc(this.diagram)&&!OI(this.diagram))if(("Select"===this.action||"Drag"===this.action)&&this.diagram.updatePortVisibility(this.hoverElement,hi.Hover,!0),!(this.tool instanceof Oh||this.tool instanceof kh)||2!==t.button&&2!==t.buttons)if(!0===this.inAction&&!0===this.isMouseDown&&(this.tool instanceof Oh||this.tool instanceof kh))this.isMouseDown=!0,this.eventArgs={},this.getMouseEventArgs(this.currentPosition,this.eventArgs),this.eventArgs.position=this.currentPosition,this.tool.mouseDown(this.eventArgs);else{this.isMouseDown=!0,this.currentPosition=this.prevPosition=this.getMousePosition(t),this.eventArgs={},this.diagram.textEditing&&!this.isMouseOnScrollBar(t)&&(this.diagram.endEdit(),this.diagram.textEditing=!1,"Canvas"===this.diagram.mode&&1!==this.diagram.scroller.currentZoom&&this.diagram.refreshDiagramLayer());var s=this.getTargetElement();this.action=this.diagram.findActionToBeDone(s.obj,s.sourceElement,this.currentPosition,s.target);var o=this.isMetaKey(t);o&&t.shiftKey&&this.diagram.connectorEditingToolModule?this.action="SegmentEnd":(o||t.shiftKey)&&(Bv(this.diagram)||Fv(this.diagram))&&(this.action="Select"),this.tool=this.diagram.getTool(this.action),this.tool||(this.action="Select",this.tool=this.diagram.getTool(this.action)),this.getMouseEventArgs(this.currentPosition,this.eventArgs),(o||t.shiftKey)&&(this.eventArgs.info=o&&t.shiftKey?{ctrlKey:o,shiftKey:t.shiftKey}:{ctrlKey:!0}),this.eventArgs.position=this.currentPosition;var l=this.diagram.selectedItems.nodes;if(this.tool.mouseDown(this.eventArgs),this.diagram.selectedItems.canToggleSelection&&l&&this.diagram.selectedItems.nodes&&this.tool instanceof ua)for(var h=0;h=2&&(this.touchStartList=zF(this.touchStartList,0,e)),e||t.preventDefault())}else this.inAction=!1,this.tool.mouseUp(this.eventArgs);!this.isForeignObject(t.target)&&!this.isForeignObject(t.target,!0)&&!e&&t.preventDefault()}},n.prototype.mouseMoveExtend=function(t,e){(this.tool instanceof Oh||this.tool instanceof kh)&&this.tool.mouseMove(this.eventArgs),this.diagram.scrollSettings.canAutoScroll?this.checkAutoScroll(t):this.blocked||this.tool.mouseMove(this.eventArgs),this.eventArgs.target&&(this.hoverElement=this.eventArgs.target);var i=!((this.eventArgs.target instanceof te||this.eventArgs.target instanceof de)&&(e instanceof te||e instanceof de));this.tool instanceof Od&&this.diagram.updatePortVisibility(this.hoverElement instanceof te||this.hoverElement instanceof de?this.hoverElement:this.hoverNode,hi.Connect|hi.Hover,i),this.hoverElement instanceof te&&this.hoverNode instanceof te&&this.hoverNode&&this.hoverNode.id!==this.hoverElement.id&&this.diagram.updatePortVisibility(this.hoverNode,hi.Connect|hi.Hover,!0),this.hoverElement instanceof de&&this.hoverElement.ports.length>0&&this.diagram.updatePortVisibility(this.hoverElement,hi.Connect|hi.Hover,!0),this.previousElement instanceof te&&this.hoverElement&&this.previousElement.id!==this.hoverElement.id&&this.diagram.updatePortVisibility(this.previousElement,hi.Connect|hi.Hover,!0),this.previousElement=this.hoverElement,""!==this.diagram.tooltip.content&&(this.hoverElement=null),this.hoverNode=i?null:e},n.prototype.checkAction=function(t){if("LabelSelect"===this.action&&this.eventArgs.sourceWrapper&&(this.eventArgs.sourceWrapper instanceof ni||this.eventArgs.sourceWrapper instanceof Jn)){var e=this.commandHandler.findTarget(this.eventArgs.sourceWrapper,this.eventArgs.source);!_r(this.diagram,e,!1,this.eventArgs.sourceWrapper)&&to(e)&&(this.action="LabelDrag",this.tool=this.getTool(this.action),this.tool.mouseDown(this.initialEventArgs))}else to(t)&&Dd(t)&&this.initialEventArgs&&this.initialEventArgs.source&&"Select"===this.action&&(!_r(this.diagram,this.eventArgs.source,!1)&&this.eventArgs.source instanceof si&&this.getMouseEventArgs(this.currentPosition,this.eventArgs),(!(t instanceof de)||t instanceof de&&!(wr(this.currentPosition,t.sourcePoint,t.hitPadding)||wr(this.currentPosition,t.targetPoint,t.hitPadding)))&&(this.action="Drag"),this.tool=this.getTool(this.action),this.tool.mouseDown(this.initialEventArgs))},n.prototype.isSwimlaneElements=function(t){return!(t&&(t.isLane||t.isPhase||t.isHeader))},n.prototype.mouseMove=function(t,e){if(this.focus=!0,this.isScrolling)t.preventDefault();else if(_v(this.diagram)||Lc(this.diagram)&&!OI(this.diagram)){this.currentPosition=this.getMousePosition(t);var i=this.diagram.findObjectsUnderMouse(this.currentPosition),r=this.diagram.findObjectUnderMouse(i,this.action,this.inAction);!function Yne(n,t){n.rulerSettings.showRulers&&(n.hRuler.drawRulerMarker(n.hRuler.element,t,n.scroller.horizontalOffset),n.vRuler.drawRulerMarker(n.vRuler.element,t,n.scroller.verticalOffset))}(this.diagram,this.currentPosition);var s=!1,o=void 0;if("touchmove"===t.type&&(e=t.touches)&&e.length>1&&(this.touchMoveList=zF(this.touchMoveList,0,e),"PinchZoom"!==this.action&&(s=!0)),!1===z.equals(this.currentPosition,this.prevPosition)||this.inAction){if(!1===this.isMouseDown||s){this.eventArgs={};var a=null,l=void 0;if(null!==r){if((a=this.diagram.findElementUnderMouse(r,this.currentPosition,this.diagram))&&(l=this.commandHandler.findTarget(a,r)),(l instanceof Zn||l instanceof Nr)&&(l.tooltip&&""!==l.tooltip.content||(l=r)),l!==this.hoverElement){var h=this.getContent();this.hoverElement&&"Auto"===this.hoverElement.tooltip.openOn&&""!==h&&this.elementLeave(),this.diagram.updatePortVisibility(this.hoverElement,hi.Hover,!0),r instanceof te&&(this.hoverNode=r);var c=!0;!this.isSwimlaneElements(r)&&this.hoverElement&&this.isSwimlaneElements(this.hoverElement)&&(c=!1),this.hoverElement=c?r:this.hoverElement;var d,u=void 0;(d=this.diagram.findElementUnderMouse(r,this.currentPosition,this.diagram))instanceof Ke&&((u=this.commandHandler.findTarget(d,r))instanceof Es||u instanceof xc)&&this.hoverElement.constraints&ri.ToolTip&&(this.hoverElement=u);var p=void 0;d instanceof ni&&((p=this.commandHandler.findTarget(d,r))instanceof Zn||p instanceof Nr)&&p.constraints&Lr.Tooltip&&(this.hoverElement=p),c?this.elementEnter(this.currentPosition,!1):this.hoverElement=r}else this.hoverElement&&this.hoverElement===l&&this.hoverElement.tooltip.content&&void 0!==this.diagram.tooltipObject&&"Mouse"===this.hoverElement.tooltip.relativeMode&&this.setTooltipOffset(this.currentPosition);a&&(o=this.commandHandler.findTarget(a,r))}this.action=this.diagram.findActionToBeDone(r,a,this.currentPosition,o),this.checkFixedUserHandleEvent(Ce.onFixedUserHandleMouseEnter,r,a),this.checkUserHandleEvent(Ce.onUserHandleMouseEnter),this.checkPreviousAction(),this.getMouseEventArgs(this.currentPosition,this.eventArgs),this.tool=this.getTool(this.action),this.mouseEvents(),this.tool instanceof pa||this.tool instanceof kh||this.tool instanceof Oh?this.tool.mouseMove(this.eventArgs):e&&this.tool instanceof $v&&this.tool.mouseDown(this.eventArgs),this.updateCursor(),this.renderUmlHighLighter(this.eventArgs);var f=!1;this.hoverElement&&!(this.tool instanceof $v)&&r instanceof te&&this.isSwimlaneElements(r)&&(0===this.diagram.selectedItems.nodes.length||!_r(this.diagram,this.hoverElement))||this.hoverElement instanceof de||(f=!0),this.hoverElement&&!(this.tool instanceof $v)&&r instanceof de&&(0===this.diagram.selectedItems.connectors.length||!_r(this.diagram,this.hoverElement))||this.hoverElement instanceof te||(f=!0),this.diagram.updatePortVisibility(this.hoverElement,hi.Hover,f);var g=this.getContent();null===r&&this.hoverElement&&"Auto"===this.hoverElement.tooltip.openOn&&g&&(this.hoverElement=null,this.elementLeave()),s=!1}else{this.eventArgs.position=this.currentPosition,"Drag"===this.action&&!_r(this.diagram,this.eventArgs.source,!1)&&this.eventArgs.source instanceof si&&this.getMouseEventArgs(this.currentPosition,this.eventArgs),this.mouseEvents(),(t.ctrlKey||t.shiftKey)&&(this.eventArgs.info=t.ctrlKey&&t.shiftKey?{ctrlKey:t.ctrlKey,shiftKey:t.shiftKey}:{ctrlKey:!0}),this.checkAction(r);var y=this.getConnectorPadding(this.eventArgs);this.getMouseEventArgs(this.currentPosition,this.eventArgs,this.eventArgs.source,y),this.updateCursor(),this.inAction=!0,this.initialEventArgs=null,("Drag"===this.action||"Rotate"===this.action)&&(this.diagram.diagramActions=this.diagram.diagramActions|ee.Interactions);var S=this.diagram.scroller.getPageBounds();this.mouseMoveExtend(t,r);var b=this.diagram.scroller.getPageBounds();if(r&&(S.width!==b.width||S.height!==b.height||S.x!==b.x||S.y!==b.y)&&this.diagram.views&&this.diagram.views.overview){var M=this.diagram.views.overview;M.updateView(M)}}this.prevPosition=this.currentPosition,this.isForeignObject(t.target,!0)||t.preventDefault()}}},n.prototype.getContent=function(){var i,t=this.hoverElement instanceof te&&this.hoverElement.constraints&ie.Tooltip||this.hoverElement instanceof de&&this.hoverElement.constraints&qe.Tooltip||(this.hoverElement instanceof Es||this.hoverElement instanceof xc)&&this.hoverElement.constraints&ri.ToolTip||(this.hoverElement instanceof Zn||this.hoverElement instanceof Nr)&&this.hoverElement.constraints&Lr.Tooltip,e=this.hoverElement;e instanceof te&&e.children&&e.children.length>0&&(i=this.findIntersectChild(e));var r=t?this.hoverElement.tooltip.content:this.diagram.tooltip.content;return i?i.tooltip.content:r},n.prototype.findIntersectChild=function(t){for(var e,i=new Ne(this.currentPosition.x,this.currentPosition.y,8,8),r=0;r1&&1===t.which&&!function Gre(n){return!!(n&ee.PreventClearSelection)}(this.diagram.diagramActions)&&(c=!1,this.commandHandler.clearSelection()),(!_r(this.diagram,h)||!c)&&(this.commandHandler.selectObjects([h],void 0,a),this.diagram.selectedItems.canToggleSelection)){var d=this.diagram.selectedItems.nodes;d?d[0].parentObj instanceof Rd&&(s=!0):this.diagram.selectedItems.connectors.length>0&&(s=!0)}}var u=!1,p=this.updateContainerProperties(),f=void 0;if(this.addUmlNode(),this.inAction=!1,this.isMouseDown=!1,this.diagram.selectedObject.helperObject&&(f=this.updateContainerBounds()),this.tool&&(this.tool.prevPosition||this.tool instanceof Q3)){this.eventArgs.position=this.currentPosition;var g=this.getConnectorPadding(this.eventArgs);this.getMouseEventArgs(this.currentPosition,this.eventArgs,this.eventArgs.source,g);var v=this.isMetaKey(t);if((v||t.shiftKey)&&(this.eventArgs.info=v&&t.shiftKey?{ctrlKey:v,shiftKey:t.shiftKey}:{ctrlKey:!0}),this.diagram.diagramActions&ee.Interactions&&(this.diagram.diagramActions=this.diagram.diagramActions&~ee.Interactions),this.eventArgs.clickCount=t.detail,this.diagram.selectedObject.helperObject&&(this.tool instanceof ua||this.tool instanceof kd)){if(this.diagram.selectedObject.actualObject&&""!==this.diagram.selectedObject.actualObject.parentId){var S=this.diagram.getObject(this.diagram.selectedObject.actualObject.parentId);S&&S.isLane&&(this.commandHandler.isContainer=!0)}(u=this.diagram.lineRoutingModule&&this.diagram.nameTable.helper&&this.eventArgs.target&&this.eventArgs.target.isLane&&(this.eventArgs.source instanceof si&&this.eventArgs.source.nodes.length>0&&""===this.eventArgs.source.nodes[0].parentId||""===this.eventArgs.source.parentId))&&(this.diagram.diagramActions=this.diagram.diagramActions|ee.PreventLaneContainerUpdate),this.tool.mouseUp(this.eventArgs,p.isPreventHistory)}else{if(this.diagram.selectedItems.canToggleSelection){var b=void 0,M=void 0;if(this.diagram.selectedItems.nodes.length>0)for(var w=0;w1&&D[0].id===i[parseInt(w.toString(),10)].id||r.length>0)&&(M=!0);!this.isSwimlaneSelected&&!s&&!M&&this.tool instanceof ua&&"Select"===this.currentAction&&(!b||this.diagram.selectedItems.connectors.length>0)&&this.commandHandler.clearSelection(!0)}this.isSwimlaneSelected=!1,this.tool.mouseUp(this.eventArgs),this.diagram.checkMenu&&(-1!==window.navigator.userAgent.indexOf("Linux")||-1!==window.navigator.userAgent.indexOf("X11"))&&(!t.pageY&&t instanceof TouchEvent&&t.changedTouches?(window.getSelection().removeAllRanges(),this.diagram.contextMenuModule.contextMenu.open(t.changedTouches[0].pageY,t.changedTouches[0].pageX,this.diagram.element),t.preventDefault()):this.diagram.contextMenuModule.contextMenu.open(t.pageY,t.pageX,this.diagram.element),this.diagram.checkMenu=!1)}p.hasStack&&this.diagram.endGroupAction()}if(f&&this.diagram.endGroupAction(),this.updateContainerBounds(!0),2!==this.eventArgs.clickCount&&(this.commandHandler.updateSelectedNodeProperties(this.eventArgs.source),u)){this.diagram.diagramActions=this.diagram.diagramActions&~ee.PreventLaneContainerUpdate;var A=this.eventArgs.source instanceof si?this.eventArgs.source.nodes:[this.eventArgs.source];if(A)for(w=0;w0&&!N&&this.diagram.renderSelector(!0),!this.inAction&&!this.diagram.currentSymbol&&this.eventArgs){var T=this.getTargetElement();this.diagram.tool!==Ci.ZoomPan&&this.diagram.triggerEvent(Ce.click,{element:T.target instanceof Es?T.target:this.eventArgs.source||this.diagram,position:this.eventArgs.position,count:t.detail,actualObject:this.eventArgs.actualObject,button:0===t.button?"Left":1===t.button?"Middle":"Right"})}this.eventArgs={}}this.diagram.diagramActions=this.diagram.diagramActions&~ee.PreventLaneContainerUpdate,e&&this.updateAnnotation(this.diagram.selectedItems),this.eventArgs={},this.diagram.commandHandler.removeStackHighlighter()},n.prototype.isSwimlaneChild=function(t){if(t.shape&&"SwimLane"!==t.shape.type){var e=this.diagram.nameTable[t.parentId];if(!e)return!1;var i=e.parentId?this.diagram.nameTable[e.parentId]:e;return i&&i.shape&&"SwimLane"===i.shape.type}return!1},n.prototype.updateAnnotation=function(t){var e=t.nodes;if(e.length>0)for(var i=0;i0&&(a+=1),h.isPhase){l="Horizontal"===r.orientation?this.currentPosition.x-e.wrapper.bounds.x:this.currentPosition.y-(e.wrapper.bounds.y+r.header.height);var g={id:Qe(),offset:l,header:{annotation:{content:void 0===h.phases[0].header?"Phase":h.phases[0].header.annotation.content,style:void 0===h.phases[0].header?{}:h.phases[0].header.annotation.style}},style:void 0===h.phases[0]?{}:h.phases[0].style};this.diagram.addPhases(e,[g])}else{var v={id:Qe(),style:h.lanes[0].style,header:{annotation:{content:h.lanes[0].header.annotation.content,style:h.lanes[0].header.annotation.style},style:h.lanes[0].header.style}};if("Horizontal"===h.orientation?v.height=h.lanes[0].height:v.width=h.lanes[0].width,"Horizontal"===r.orientation?(s=i.rowIndex?i.rowIndex:this.diagram.nameTable[i.parentId].rowIndex,i.wrapper.offsetYs)v.header.width=r.lanes[parseInt(s.toString(),10)].header.width,v.header.height=r.lanes[parseInt(s.toString(),10)].header.height;else{var S=void 0;S="Horizontal"===r.orientation?i.rowIndex<3?0:s-a-1:s-1,v.header.width=r.lanes[parseInt(S.toString(),10)].header.width,v.header.height=r.lanes[parseInt(S.toString(),10)].header.height}f&&("height"===f?(v.width=v.height,delete v.height):(v.height=v.width,delete v.width)),this.diagram.addLanes(e,[v],"Horizontal"===r.orientation?s-a:s)}this.commandHandler.select(e)}else if(h.isLane){var b={id:Qe(),width:t.width,height:t.height,addInfo:t.addInfo,shape:{type:"SwimLane",header:{annotation:{content:void 0===h.header?"Header":h.header.annotation.content,style:void 0===h.header?{}:h.header.annotation.style},height:50,style:h.header?h.header.style:h.lanes[0].header.style},phases:[{id:Qe(),header:{annotation:{content:void 0===h.phases||void 0===h.phases[0].header?"Phase":h.phases[0].header.annotation.content,style:void 0===h.phases||void 0===h.phases[0].header?{}:h.phases[0].header.annotation.style},style:void 0===h.phases||void 0===h.phases[0].header?{}:h.phases[0].header.style},style:void 0===h.phases?{}:h.phases[0].style}],lanes:[{id:Qe(),height:t.height,width:t.width,style:h.lanes[0].style,header:{annotation:{content:h.lanes[0].header.annotation.content,style:h.lanes[0].header.annotation.style},style:h.lanes[0].header.style}}],orientation:h.orientation}};"Vertical"===h.orientation&&(b.width+=20),b.offsetX=this.currentPosition.x+b.width/2,b.offsetY=this.currentPosition.y+b.height/2,b.style=t.style,this.diagram.add(b)}},n.prototype.mouseLeave=function(t){this.tool&&this.inAction&&this.tool.mouseLeave(this.eventArgs),this.diagram.selectedObject.helperObject&&(this.updateContainerProperties(),this.updateContainerBounds()&&this.diagram.endGroupAction()),this.eventArgs&&this.eventArgs.source&&(this.diagram.updatePortVisibility(this.eventArgs.source,hi.Hover,!0),this.hoverElement=null),this.eventArgs&&!this.eventArgs.source&&this.hoverElement&&(this.hoverElement=null),this.tool instanceof Od&&this.eventArgs&&this.eventArgs.target&&this.eventArgs.target instanceof te&&(this.diagram.updatePortVisibility(this.eventArgs.target,hi.Hover|hi.Connect,!0),this.hoverElement=null);var i=this.diagram.selectedItems;i&&i.wrapper&&(nm(this.diagram,i)||this.diagram.renderSelector(!0)),(this.diagram.diagramActions&ee.Interactions||this.diagram.diagramActions&ee.ToolAction)&&(this.diagram.diagramActions=this.diagram.diagramActions&~ee.ToolAction),this.isMouseDown=!1,this.focus=!1,this.touchStartList=null,this.touchMoveList=null,this.elementLeave(),this.commandHandler.removeSnap(),this.inAction=!1,this.eventArgs={},this.diagram.selectedObject&&this.diagram.selectedObject.helperObject&&(this.diagram.remove(this.diagram.selectedObject.helperObject),this.diagram.selectedObject={helperObject:void 0,actualObject:void 0}),this.tool=null,function Wne(){var t,e,n=document.getElementsByClassName("e-d-ruler-marker");if(n&&n.length>0)for(e=n.length-1;e>=0;e--)(t=n[parseInt(e.toString(),10)])&&t.parentNode.removeChild(t)}(),"Rotate"===this.action&&this.diagram.diagramCanvas.classList.remove("e-diagram-rotate"),t.preventDefault()},n.prototype.mouseWheel=function(t){this.diagram.blazorActions|=on.interaction;var e={event:t,cancel:!1};if(this.diagram.triggerEvent(Ce.mouseWheel,e),!e.cancel){var i=t.wheelDelta>0||-40*t.detail>0,r=this.getMousePosition(t);if(this.diagram.tooltipObject.close(),this.isMetaKey(t)){var o=this.diagram.scrollSettings.zoomFactor;this.diagram.zoomTo(i?{type:"ZoomIn",zoomFactor:o,focusPoint:r}:{type:"ZoomOut",zoomFactor:o,focusPoint:r}),t.preventDefault()}else{var a=this.diagram.scroller.horizontalOffset,l=this.diagram.scroller.verticalOffset,h=i?10:-10;this.tool&&(this.tool instanceof Oh||this.tool instanceof kh)&&(this.eventArgs={},this.getMouseEventArgs(r,this.eventArgs),this.eventArgs.position=r,this.tool.mouseWheel(this.eventArgs)),this.diagram.scrollActions|=ca.Interaction;var c=!0;if(t.isTrusted){var d=!1;(Math.abs(t.deltaY)<100&&-0===Math.abs(t.deltaX)||Math.abs(t.deltaX)<100&&-0===Math.abs(t.deltaY))&&(d=!0);var u=!1;(0!==t.deltaX||0!==t.deltaY)&&(u=navigator.userAgent.includes("Macintosh")),u?Math.abs(t.deltaX)>Math.abs(t.deltaY)?(t.shiftKey||t.deltaX&&-0!==t.deltaX&&(d||!u))&&this.diagram.scroller.zoom(1,h,0,r,c,void 0,d):t.deltaY&&-0!==t.deltaY&&(d||!u)&&this.diagram.scroller.zoom(1,0,h,r,c,void 0,d):t.shiftKey||t.deltaX&&-0!==t.deltaX&&(d||!u)?this.diagram.scroller.zoom(1,h,0,r,c,void 0,d):t.deltaY&&-0!==t.deltaY&&(d||!u)&&this.diagram.scroller.zoom(1,0,h,r,c,void 0,d)}else t.shiftKey||t.deltaX&&-0!==t.deltaX?this.diagram.scroller.zoom(1,h,0,r,c):this.diagram.scroller.zoom(1,0,h,r,c);this.diagram.scrollActions&=~ca.Interaction,(a!==this.diagram.scroller.horizontalOffset||l!==this.diagram.scroller.verticalOffset)&&t.preventDefault()}if(this.diagram.textEditing){if(this.diagram.isTriggerEvent=!0,this.diagram.activeLabel.parentId){var f=this.diagram.getObject(this.diagram.activeLabel.parentId);this.diagram.startTextEdit(f,this.diagram.activeLabel.id)}this.diagram.isTriggerEvent=!1}this.diagram.blazorActions=this.diagram.blazorActions&~on.interaction}},n.prototype.keyDown=function(t){if(t.fromMouseEvents&&(t.ctrlKey&&(this.keyArgs.keyModifiers=1),t.shiftKey&&(this.keyArgs.keyModifiers=4),t.shiftKey&&t.ctrlKey&&(this.keyArgs.keyModifiers=5)),!(this.diagram.diagramActions&ee.TextEdit)&&!this.checkEditBoxAsTarget(t)||"Escape"===t.key||27===t.keyCode){var i=void 0,r=t.keyCode?t.keyCode:t.which,s=t.key;("ArrowDown"===s||"ArrowUp"===s||"ArrowLeft"===s||"ArrowRight"===s)&&(this.isNudgeKey=!0);var o=this.isMetaKey(t);if(this.diagram.commandManager&&this.diagram.commands)for(var l=0,h=Object.keys(this.diagram.commands);l4&&(S({keyDownEventArgs:KeyboardEvent,parameter:i.parameter,type:"KEYDOWN"}),this.keyCount=0)),this.isKeyUp=!1):S({keyDownEventArgs:KeyboardEvent,parameter:i.parameter})}break}}}}this.keyArgs={element:this.diagram.selectedItems,key:t.key,keyCode:t.keyCode?t.keyCode:t.which},this.getKeyModifier(this.keyArgs,t),this.diagram.diagramActions&ee.TextEdit&&this.getlabel(this.keyArgs,t),this.diagram.triggerEvent(Ce.keyDown,this.keyArgs)},n.prototype.getlabel=function(t,e){var i=this.diagram.activeLabel;t.target=this.diagram.element.id+"_editBox";var r=this.diagram.nameTable[i.parentId];if(document.getElementById(this.diagram.element.id+"_editBox")){t.text=document.getElementById(this.diagram.element.id+"_editBox").value;for(var s=0;s=this.diagram.scroller.viewPortWidth-18?r="right":e.x+this.diagram.scroller.horizontalOffsetthis.diagram.scroller.viewPortHeight-18?r="bottom":e.y+this.diagram.scroller.verticalOffset0&&(s=this.findIntersectChild(this.hoverElement)),"Auto"===this.hoverElement.tooltip.openOn&&""!==r&&bx(this.diagram,s||(i?this.hoverElement:void 0)),this.hoverElement.tooltip.content&&("Mouse"===this.hoverElement.tooltip.relativeMode?this.setTooltipOffset(t):(this.diagram.tooltipObject.offsetX=0,this.diagram.tooltipObject.offsetY=0));var o=this.diagram.findObjectsUnderMouse(this.currentPosition),a=this.diagram.findObjectUnderMouse(o,this.action,this.inAction);if(null!==a){var l=void 0;this.hoverElement.tooltip.isSticky&&(this.diagram.tooltipObject.isSticky=!0),a instanceof te&&a.children&&a.children.length>0&&(a=s||a),l=a.ports&&(this.hoverElement instanceof Es||this.hoverElement instanceof xc)||a.annotations&&(this.hoverElement instanceof Zn||this.hoverElement instanceof Nr)?document.getElementById(a.id+"_"+this.hoverElement.id):document.getElementById(a.id+(a.shape&&a.shape instanceof sm?"_content_native_element":"_groupElement")),"Auto"===this.hoverElement.tooltip.openOn&&""!==r&&(this.diagram.tooltipObject.close(),this.diagram.tooltipObject.openOn=this.hoverElement.tooltip.openOn,this.diagram.tooltipObject.dataBind()),function _re(n,t){var e=0;return n instanceof de?n.constraints&qe.Tooltip?e=n.constraints&qe.Tooltip:n.constraints&qe.InheritTooltip&&(e=t.constraints&rt.Tooltip):n instanceof Es||n instanceof xc?n.constraints&ri.ToolTip?e=n.constraints&ri.ToolTip:n.constraints&ri.InheritTooltip&&(e=t.constraints&rt.Tooltip):n instanceof Zn||n instanceof Nr?n.constraints&Lr.Tooltip&&(e=n.constraints&Lr.Tooltip):n.constraints&ie.Tooltip?e=n.constraints&ie.Tooltip:n.constraints&ie.InheritTooltip&&(e=t.constraints&rt.Tooltip),e}(this.hoverElement,this.diagram)&&"Auto"===this.hoverElement.tooltip.openOn&&(this.diagram.tooltipObject.target=this.hoverElement.id,this.diagram.tooltipObject.open("Mouse"===this.hoverElement.tooltip.relativeMode?this.diagram.element:l))}}},n.prototype.elementLeave=function(){this.diagram.tooltipObject&&!this.diagram.tooltipObject.isSticky&&"Custom"!==this.diagram.tooltipObject.openOn&&this.diagram.tooltipObject.close()},n.prototype.setTooltipOffset=function(t){var e=function hse(n,t,e,i){var o="Mouse"===(!(e instanceof te?e.constraints&ie.InheritTooltip:e instanceof de?e.constraints&qe.InheritTooltip:e.constraints&ri.InheritTooltip)&&(e instanceof te?e.constraints&ie.Tooltip:e instanceof de?e.constraints&qe.Tooltip:e.constraints&ri.ToolTip)?e.tooltip.relativeMode:n.tooltip.relativeMode);"Mouse"===i?o=!0:"Object"===i&&(o=!1);var a=function cse(n,t,e,i){var o,r={},s=document.getElementById(e.element.id);if(n instanceof te||n instanceof de)o=n.wrapper.bounds;else{var a=e.findObjectsUnderMouse(t),l=e.findObjectUnderMouse(a,"Select",!1);o=e.findElementUnderMouse(l,t,e).bounds}var c=s.getBoundingClientRect();switch(e.tooltipObject.position){case"BottomCenter":r=zc(t,o.bottomCenter,e,i,c.width/2,c.height);break;case"BottomLeft":case"LeftBottom":r=zc(t,o.bottomLeft,e,i,0,c.height);break;case"BottomRight":case"RightBottom":r=zc(t,o.bottomRight,e,i,c.width,c.height);break;case"LeftCenter":r=zc(t,o.middleLeft,e,i,0,c.height/2);break;case"LeftTop":case"TopLeft":r=zc(t,o.topLeft,e,i,0,0);break;case"RightCenter":r=zc(t,o.middleRight,e,i,c.width,c.height/2);break;case"RightTop":case"TopRight":r=zc(t,o.topRight,e,i,c.width,0);break;case"TopCenter":r=zc(t,o.topCenter,e,i,c.width/2,0)}return r}(e,t,n,o),l=qa(n);return{x:a.x+l.width,y:a.y+l.height}}(this.diagram,t,this.hoverElement);this.diagram.tooltipObject.offsetX=e.x,this.diagram.tooltipObject.offsetY=e.y},n.prototype.altKeyPressed=function(t){return!!(t&pt.Alt)},n.prototype.ctrlKeyPressed=function(t){return!!(t&pt.Control)},n.prototype.shiftKeyPressed=function(t){return!!(t&pt.Shift)},n.prototype.scrolled=function(t){this.diagram.updateScrollOffset()},n.prototype.doubleClick=function(t){if(_v(this.diagram)){var e=void 0,i=this.diagram.findObjectsUnderMouse(this.currentPosition),r=this.diagram.findObjectUnderMouse(i,this.action,this.inAction);if(null!==r&&_v(this.diagram))if(e=this.diagram.findElementUnderMouse(r,this.currentPosition,this.diagram),this.tool&&(this.tool instanceof Oh||this.tool instanceof kh))this.tool.mouseUp(this.eventArgs),this.isMouseDown=!1,this.eventArgs={},this.tool=null,t.preventDefault();else{var o=this.diagram.commandHandler.getObjectLayer(r.id);!o||o.lock||!o.visible||this.diagram.diagramActions&ee.TextEdit||this.diagram.startTextEdit(r,e instanceof ni?e.id.split(r.id+"_")[1]:void 0)}this.diagram.triggerEvent(Ce.doubleClick,{source:r||this.diagram,position:this.currentPosition,count:t.detail})}},n.prototype.itemClick=function(t,e){var i=t;return cs(this.diagram,i,!0)?i:null},n.prototype.inputChange=function(t){var i,s,o,a,l,h,c,d,u,p=document.getElementById(this.diagram.element.id+"_editBox"),f=document.getElementById(this.diagram.element.id+"_editTextBoxDiv"),g=p.value,v=g.split("\n");(!(a=this.diagram.selectedItems.nodes[0]?this.diagram.selectedItems.nodes[0]:this.diagram.selectedItems.connectors[0])&&this.tool instanceof jI||a&&"SwimLane"===a.shape.type)&&(a=this.diagram.nameTable[this.diagram.activeLabel.parentId]),a&&("Text"!==a.shape.type&&a.annotations.length>0||"Text"===a.shape.type)&&(c=AF((o=this.diagram.getWrapper(a.wrapper,this.diagram.activeLabel.id)).style,g,void 0,void 0,i=(i=a.wrapper.bounds.width90?i:90),s=Number(p.style.fontSize.split("px")[0]),v.length>1&&""===v[v.length-1]&&(c.height=c.height+s),d=this.diagram.scroller.transform,u=D3(this.diagram)?d.scale:1,l=(12>c.height?12:c.height)*u,f.style.left=(o.bounds.center.x+d.tx)*d.scale-(h=(90>(h=c.width)?90:h)*u)/2-2.5+"px",f.style.top=(o.bounds.center.y+d.ty)*d.scale-l/2-3+"px",f.style.width=h+"px",f.style.height=l+"px",p.style.minHeight="12px",p.style.minWidth="90px",p.style.width=h+"px",p.style.height=l+"px")},n.prototype.isAddTextNode=function(t,e){return!(!(this.tool instanceof jI||e)||(this.tool=null,t&&!NI(this.diagram)&&(this.diagram.drawingObject=void 0,this.diagram.currentDrawingObject=void 0),fF(this.diagram.nodes,t.id)||fF(this.diagram.connectors,t.id)))},n.prototype.checkEditBoxAsTarget=function(t){return!(!t.target||t.target.id!==this.diagram.element.id+"_editBox")},n.prototype.getMouseEventArgs=function(t,e,i,r){var s,o,a;if(e.position=t,i?(o=this.diagram.findObjectsUnderMouse(this.currentPosition,i),s=this.diagram.findTargetObjectUnderMouse(o,this.action,this.inAction,e.position,i)):"Drag"===this.action||"ConnectorSourceEnd"===this.action||"SegmentEnd"===this.action||"OrthoThumb"===this.action||"BezierSourceThumb"===this.action||"BezierTargetThumb"===this.action||"ConnectorTargetEnd"===this.action||-1!==this.action.indexOf("Rotate")||-1!==this.action.indexOf("Resize")?(s=this.diagram.selectedItems,!this.diagram.currentSymbol&&"Drag"===this.action&&s&&this.diagram.selectedItems.nodes.length>0&&"SwimLane"===this.diagram.selectedItems.nodes[0].shape.type&&(o=this.diagram.findObjectsUnderMouse(this.currentPosition),s=this.diagram.findObjectUnderMouse(o,this.action,this.inAction))):(o=this.diagram.findObjectsUnderMouse(this.currentPosition),s=this.diagram.findObjectUnderMouse(o,this.action,this.inAction)),s&&s.isHeader&&(this.eventArgs.actualObject=s=this.diagram.nameTable[s.parentId]),s){var l=void 0,h=void 0,c=void 0;if(((a=this.diagram.findElementUnderMouse(s,this.currentPosition,this.diagram,r))&&s.ports&&s.ports.length&&!eb(s,a)||!a||!s)&&o&&o.length&&i instanceof si)for(l=i.connectors[0],c=o.length-1;c>=0;c--)if(((h=o[parseInt(c.toString(),10)])instanceof te||h instanceof de)&&l&&l.connectionPadding){if(a=this.diagram.findElementUnderMouse(s=h,this.currentPosition,this.diagram,r),l.constraints&qe.ConnectToNearByPort&&s&&s.ports&&s.ports.length&&eb(s,a))break;if((h instanceof te||h instanceof de)&&l&&l.connectionPadding&&h.wrapper.outerBounds.containsPoint(this.currentPosition)&&l.constraints&qe.ConnectToNearByNode&&!(l.constraints&qe.ConnectToNearByPort)){a=this.diagram.findElementUnderMouse(s=h,this.currentPosition,this.diagram,0);break}}}return i?(e.target=s,e.targetWrapper=a):(e.source=s,e.sourceWrapper=a),e.actualObject=this.eventArgs.actualObject,e.source instanceof si&&void 0===e.actualObject&&(e.source.nodes.length>0||e.source.connectors.length>0)&&(e.actualObject=e.source.nodes.length>0?this.diagram.nameTable[e.source.nodes[0].id]:this.diagram.nameTable[e.source.connectors[0].id]),e.startTouches=this.touchStartList,e.moveTouches=this.touchMoveList,e},n.prototype.resetTool=function(){this.action="Select",this.hoverElement=null,this.hoverNode=null,this.tool=this.diagram.getTool(this.action),this.updateCursor()},n.prototype.updateTool=function(){this.eventArgs&&!this.eventArgs.position&&(this.action="Select")},n.prototype.getTool=function(t){switch(t){case"Select":return new qv(this.commandHandler,!0);case"Drag":return new ua(this.commandHandler);case"Rotate":return new Wx(this.commandHandler);case"LayoutAnimation":return new Tne(this.commandHandler);case"FixedUserHandle":return new xne(this.commandHandler,!0);case"Hyperlink":return new Q3(this.commandHandler);case"ResizeSouthEast":case"ResizeSouthWest":case"ResizeNorthEast":case"ResizeNorthWest":case"ResizeSouth":case"ResizeNorth":case"ResizeWest":case"ResizeEast":return new kd(this.commandHandler,t);case"ConnectorSourceEnd":case"ConnectorTargetEnd":case"BezierSourceThumb":case"BezierTargetThumb":return new Od(this.commandHandler,t);case"SegmentEnd":case"OrthoThumb":return new qF(this.commandHandler,t);case"Draw":var e="shape",i=function ise(n){var t;return n&&(n.type?t="Connector":n.shape&&!n.type&&(t="Node")),t}(this.diagram.drawingObject);if("Node"===i&&"Text"===this.diagram.drawingObject.shape.type)return new jI(this.commandHandler);if("Connector"===i&&"Freehand"===this.diagram.drawingObject.type)return new One(this.commandHandler);if("Node"===i&&"Polygon"===this.diagram.drawingObject.shape[""+e]&&!this.diagram.drawingObject.shape.points)return new Oh(this.commandHandler);if("Node"===i||"Node"===i&&"Polygon"===this.diagram.drawingObject.shape[""+e]&&this.diagram.drawingObject.shape.points)return new UI(this.commandHandler,this.diagram.drawingObject);if("Connector"===i&&"Polyline"===this.diagram.drawingObject.type)return new kh(this.commandHandler);if("Connector"===i)return new pa(this.commandHandler,"ConnectorSourceEnd",this.diagram.drawingObject);break;case"Pan":return new $v(this.commandHandler,!1);case"PinchZoom":return new $v(this.commandHandler,!0);case"PortDrag":return new ua(this.commandHandler,"Port");case"PortDraw":return new pa(this.commandHandler,"ConnectorSourceEnd",this.diagram.drawingObject);case"LabelSelect":return new qv(this.commandHandler,!0,"LabelSelect");case"LabelDrag":return new Ane(this.commandHandler);case"LabelResizeSouthEast":case"LabelResizeSouthWest":case"LabelResizeNorthEast":case"LabelResizeNorthWest":case"LabelResizeSouth":case"LabelResizeNorth":case"LabelResizeWest":case"LabelResizeEast":return new Lne(this.commandHandler,t);case"LabelRotate":return new Nne(this.commandHandler)}return null},n.prototype.getCursor=function(t){var e=this.diagram.selectedItems.annotation?this.diagram.selectedItems.wrapper.children[0]:this.diagram.selectedItems;return function Dne(n,t){if(t+=360,t%=360,-1===n.indexOf("Resize"))return Vx[""+n];var e=Vx[""+n];return t>=0&&t<25||t>=160&&t<=205||t>=340&&t<=360?e:t>=25&&t<=70||t>=205&&t<=250?"n-resize"===e||"s-resize"===e?"ne-resize":"nw-resize"===e||"se-resize"===e?"n-resize":"e-resize"===e||"w-resize"===e?"nw-resize":"e-resize":t>=70&&t<=115||t>=250&&t<=295?"n-resize"===e||"s-resize"===e?"e-resize":"nw-resize"===e||"se-resize"===e?"ne-resize":"e-resize"===e||"w-resize"===e?"n-resize":"nw-resize":t>=115&&t<=155||t>=295&&t<=340?"n-resize"===e||"s-resize"===e?"nw-resize":"nw-resize"===e||"se-resize"===e?"e-resize":"e-resize"===e||"w-resize"===e?"ne-resize":Vx[""+n]:"n-resize"}(t,this.diagram.selectedItems.annotation?e.rotateAngle+e.parentTransform:e.rotateAngle)},n.prototype.findElementUnderMouse=function(t,e,i,r){return this.objectFinder.findElementUnderSelectedItem(t,e,i,r)},n.prototype.findObjectsUnderMouse=function(t,e){return this.objectFinder.findObjectsUnderMouse(t,this.diagram,this.eventArgs,e)},n.prototype.findObjectUnderMouse=function(t,e,i){return this.objectFinder.findObjectUnderMouse(this.diagram,t,e,i,this.eventArgs,this.currentPosition)},n.prototype.findTargetUnderMouse=function(t,e,i,r,s){return this.objectFinder.findObjectUnderMouse(this.diagram,t,e,i,this.eventArgs,r,s)},n.prototype.findActionToBeDone=function(t,e,i,r){return function Ine(n,t,e,i,r,s,o){if(s&&s.length>1&&r&&r.length>1)return"PinchZoom";if(i.currentSymbol)return"Drag";if("PortDraw"===i.eventHandler.action&&(i.tool&=~Ci.DrawOnce),(E3(i)||NI(i))&&i.drawingObject)return"Draw";if(Xa(i)&&(l=i.selectedItems).wrapper&&qr(l.constraints,"UserHandle"))for(var h=0,c=l.userHandles;h=50&&(l.x=(a.points[parseInt(h.toString(),10)].x+a.points[h+1].x)/2,l.y=(a.points[parseInt(h.toString(),10)].y+a.points[h+1].y)/2,wr(e,l,n.hitPadding?n.hitPadding:10)))return"OrthoThumb"}else xI(n)&&console.warn('[WARNING] :: Module "ConnectorEditing" is not available in Diagram component! You either misspelled the module name or forgot to load it.');return null}(g,l,e,i);if("OrthoThumb"===S)return S;if(qr(l.constraints,"ConnectorSourceThumb")&&EI(g)&&S||qr(l.constraints,"ConnectorTargetThumb")&&DI(g)&&S)return S}}else{var b=i.selectedItems.handleSize/2/i.scroller.currentZoom,M=10/i.scroller.currentZoom,w=Hi();qi(w,p.rotateAngle+p.parentTransform,p.offsetX,p.offsetY);var C=p.offsetX-p.pivot.x*p.actualSize.width,D=p.offsetY-p.pivot.y*p.actualSize.height,A={x:C+(.5===p.pivot.x?2*p.pivot.x:p.pivot.x)*p.actualSize.width/2,y:D-30/i.scroller.currentZoom};A=Je(w,A);var x=!!i.selectedItems.annotation,R=!(!x||!TI(i.selectedItems.annotation));if(qr(l.constraints,"Rotate")&&wr(e,A,M)&&i.selectedItems.thumbsConstraints&bt.Rotate){if(x&&R)return"LabelRotate";if(!x)return"Rotate"}if(u.Inflate(b),u.containsPoint(e)&&(S=function bne(n,t,e,i,r,s){var o;return 1===n.selectedItems.nodes.length&&0===n.selectedItems.connectors.length&&n.selectedItems.nodes[0].container&&(o=function Cne(n,t,e,i,r){var s=10/n.scroller.currentZoom,o=40/n.scroller.currentZoom,a=n.selectedItems,l=t.actualSize.width,h=t.actualSize.height,c=new Ne(i,r,t.style.strokeWidth,h),d=new Ne(i+l,r,t.style.strokeWidth,h),u=new Ne(i,r,l,t.style.strokeWidth),p=new Ne(i,r+h,l,t.style.strokeWidth),f=cs(n,n.selectedItems.nodes[0],!0)?n.nameTable[n.selectedItems.nodes[0].parentId]:n.selectedItems.nodes[0];if(l>=o&&h>=o){if(fa(a.constraints,"ResizeEast",a.thumbsConstraints,a)&&d.containsPoint(e,s))return"ResizeEast";if(fa(a.constraints,"ResizeSouth",a.thumbsConstraints,a)&&p.containsPoint(e,s))return"ResizeSouth";if("Grid"!==f.container.type){if(fa(a.constraints,"ResizeWest",a.thumbsConstraints,a)&&c.containsPoint(e,s))return"ResizeWest";if(fa(a.constraints,"ResizeNorth",a.thumbsConstraints,a)&&u.containsPoint(e,s))return"ResizeNorth"}}return null}(n,t,e,r,s)),!o&&(!n.selectedItems.nodes[0]||!n.selectedItems.nodes[0].isPhase&&!n.selectedItems.nodes[0].isLane&&"SwimLane"!==n.selectedItems.nodes[0].shape.type)&&(o=function Ene(n,t,e,i,r,s){var o=40/n.scroller.currentZoom,a=n.selectedItems.handleSize/2/n.scroller.currentZoom,l=n.selectedItems,h=!!l.annotation;if(t.actualSize.width>=o&&t.actualSize.height>=o){if(fa(l.constraints,"ResizeSouthEast",l.thumbsConstraints,l)&&wr(e,Je(i,{x:r+t.actualSize.width,y:s+t.actualSize.height}),a))return h?"LabelResizeSouthEast":"ResizeSouthEast";if(fa(l.constraints,"ResizeSouthWest",l.thumbsConstraints,l)&&wr(e,Je(i,{x:r,y:s+t.actualSize.height}),a))return h?"LabelResizeSouthWest":"ResizeSouthWest";if(fa(l.constraints,"ResizeNorthEast",l.thumbsConstraints,l)&&wr(e,Je(i,{x:r+t.actualSize.width,y:s}),a))return h?"LabelResizeNorthEast":"ResizeNorthEast";if(fa(l.constraints,"ResizeNorthWest",l.thumbsConstraints,l)&&wr(e,Je(i,{x:r,y:s}),a))return h?"LabelResizeNorthWest":"ResizeNorthWest"}return fa(l.constraints,"ResizeEast",l.thumbsConstraints,l)&&wr(e,Je(i,{x:r+t.actualSize.width,y:s+t.actualSize.height/2}),a)?h?"LabelResizeEast":"ResizeEast":fa(l.constraints,"ResizeWest",l.thumbsConstraints,l)&&wr(e,Je(i,{x:r,y:s+t.actualSize.height/2}),a)?h?"LabelResizeWest":"ResizeWest":fa(l.constraints,"ResizeSouth",l.thumbsConstraints,l)&&wr(e,Je(i,{x:r+t.actualSize.width/2,y:s+t.actualSize.height}),a)?h?"LabelResizeSouth":"ResizeSouth":fa(l.constraints,"ResizeNorth",l.thumbsConstraints,l)&&wr(e,Je(i,{x:r+t.actualSize.width/2,y:s}),a)?h?"LabelResizeNorth":"ResizeNorth":null}(n,t,e,i,r,s)),o||null}(i,p,e,w,C,D),S))return S}}if(Lc(i)&&!n)return"Pan";if((o instanceof Es||o instanceof xc)&&(!Lc(i)||Bv(i)||Fv(i))&&(S=function wne(n,t,e,i){if(Rx(t)&&(ga(t,hi.Hover)||ga(t,hi.Visible))){if(t.constraints&ri.Drag)return"PortDrag"}else if(zx(t)&&(ga(t,hi.Hover)||ga(t,hi.Visible))&&t.constraints&ri.Draw){n.drawingObject={};var r={type:"Orthogonal",sourcePortID:t.id};return n.drawingObject=r,n.tool|=Ci.DrawOnce,n.currentDrawingObject=r,"PortDraw"}return"None"}(i,o),"None"!==S))return S;if((o instanceof Zn||o instanceof Nr)&&!Lc(i)&&Dd(o))return _r(i,o,void 0,t)&&to(o)?"LabelDrag":"LabelSelect";if(null!==n){if(!(n instanceof te||n instanceof de))return"Select";if(t&&t.id){var L=t.id.split(n.id)[1];if(L&&L.match("^_icon"))return"LayoutAnimation"}if(t&&t.id)for(var O=void 0,N=0;N-1)return"FixedUserHandle";if(t instanceof ni&&t.hyperlink.link)return"Hyperlink";if(!to(n)||!_r(i,n,!1)||void 0!==i.selectedItems.annotation)return n&&Lc(i)&&!OI(i)?"Pan":i.selectedItems.nodes.length&&i.selectedItems.nodes[0].isLane&&i.selectedItems.wrapper&&i.selectedItems.wrapper.bounds.containsPoint(e)?"Drag":"Select";if(n instanceof de&&!wr(e,n.sourcePoint,n.hitPadding)&&!wr(e,n.targetPoint,n.hitPadding)||!(n instanceof de))return"Drag"}return"Select"}(t,e,this.currentPosition,this.diagram,this.touchStartList,this.touchMoveList,r)},n.prototype.updateContainerBounds=function(t){var e=!1;if(this.diagram.selectedObject.helperObject&&this.diagram.selectedObject.actualObject instanceof te){var i=this.tool instanceof kd,r=this.diagram.selectedObject.actualObject,s=this.diagram.nameTable[r.parentId];t?U3(this.diagram,r,this.currentPosition,i):((!s||s&&"SwimLane"!==s.shape.type)&&this.diagram.updateDiagramObject(r),e=function vne(n,t,e,i){var r,o=!1;if(cs(n,t,!0)){n.protectPropertyChange(!0);var a=(r=n.nameTable[t.parentId]).wrapper;if(r&&"Canvas"===r.container.type){if(i||a.bounds.x<=e.x&&a.bounds.right>=e.x&&a.bounds.y<=e.y&&a.bounds.bottom>=e.y){var l=void 0,h=a.bounds.y,c=a.bounds.x,d=n.nameTable[r.parentId]||r;if("SwimLane"===d.shape.type)o=Xv(r,d,t,n,!0);else{var p=n.nameTable[r.parentId]||r,f=p.shape;l=p.wrapper,a.actualSize.widtha.outerBounds.x)&&(void 0!==r.rowIndex?(l.updateColumnWidth(r.columnIndex,a.outerBounds.width,!0),"Horizontal"===f.orientation&&f.phaseSize&&HI(p,n,a,r.columnIndex),Oc(n,p),n.drag(p,c-a.bounds.x,h-a.bounds.y)):n.scale(r,1+(a.outerBounds.width-a.actualSize.width)/a.actualSize.width,1,a.outerBounds.xa.outerBounds.y)&&(void 0!==r.rowIndex?(l.updateRowHeight(r.rowIndex,a.outerBounds.height,!0),n.drag(p,c-a.bounds.x,h-a.bounds.y)):n.scale(r,1,1+(a.outerBounds.height-a.actualSize.height)/a.actualSize.height,a.outerBounds.yi.y&&(h+=u>0?-1:1,u+=u>0?-1:1):i&&e.wrapper.offsetYi.x&&(h+=u>0?-1:1,u+=u>0?-1:1):i&&e.wrapper.offsetX1&&!(this.diagram.lineRoutingModule&&this.diagram.constraints&rt.LineRouting))for(var b=t.offsetX-this.diagram.selectedItems.offsetX,M=t.offsetY-this.diagram.selectedItems.offsetY,w=t.rotateAngle-this.diagram.selectedItems.rotateAngle,C=0;C-1){var x=c.children;x.splice(x.indexOf(o.id),1),this.diagram.nameTable[o.id].parentId="",i=!0,c.wrapper.children.splice(A,1)}}if(function Sne(n,t,e,i){var r=n,s=e.nameTable[r.parentId],o=e.nameTable[r.parentId];if(t&&o&&o.container&&"Stack"===o.container.type&&t.container&&"Stack"===t.container.type&&o.id!==t.parentId){var a=o.wrapper.children.indexOf(r.wrapper);a>-1&&(e.nameTable[r.id].parentId=t.id,o.wrapper.children.splice(a,1))}if(t&&t.parentId&&r.parentId&&"Drag"===i&&o.container&&"Stack"===o.container.type){var l=s.wrapper.children.indexOf(t.wrapper),h=s.wrapper.children.indexOf(r.wrapper),c={targetIndex:l,target:t,sourceIndex:h,source:n};s.wrapper.children.splice(h,1),s.wrapper.children.splice(l,0,r.wrapper),e.commandHandler.addHistoryEntry({type:"StackChildPositionChanged",redoObject:{targetIndex:h,target:t,sourceIndex:l,source:n},undoObject:c,category:"Internal"})}}(o,h,this.diagram,this.action),(c=cs(this.diagram,o)?this.diagram.nameTable[o.parentId]:this.diagram.nameTable[o.parentId]||o)&&c.container&&"Canvas"===c.container.type&&(c.wrapper.maxWidth=c.maxWidth=c.wrapper.actualSize.width,c.wrapper.maxHeight=c.maxHeight=c.wrapper.actualSize.height,e=!0),cs(this.diagram,o,!0)&&c&&"Canvas"===c.container.type)if(this.diagram.selectedItems.nodes.length>1)for(C=0;C0)for(var i=0;i0&&e.columnIndex>0||l&&e.isLane)){if("Horizontal"===t.container.orientation&&e.isPhase&&e.wrapper.width>e.maxWidth&&(e.maxWidth=e.wrapper.width,e.wrapper.maxWidth=e.wrapper.width),h.updateColumnWidth(e.columnIndex,r.width,!0,c),Fx(this.diagram,e,t),e.isPhase){var f=this.diagram.nameTable[""+t.shape.phases[e.columnIndex].header.id];f.maxWidth0?(r=new rf(t,"",u),t.shape.classShape.attributes.push(r)):i.id.includes("_umlMethods")&&t.shape.classShape.methods.length>0&&(s=new am(t,"",u),t.shape.classShape.methods.push(s))),"Interface"===t.shape.classifier&&(i.id.includes("_umlProperty")&&t.shape.interfaceShape.attributes.length>0?(r=new rf(t,"",u),t.shape.classShape.attributes.push(r)):i.id.includes("_umlMethods")&&t.shape.interfaceShape.methods.length>0&&(s=new am(t,"",u),t.shape.interfaceShape.methods.push(s))),"Enumeration"===t.shape.classifier&&i.id.includes("_umlMember")&&t.shape.enumerationShape.members.length>0){var p=new rb(t,"",u);t.shape.enumerationShape.members.push(p)}t.wrapper.children.indexOf(c.wrapper),this.diagram.enableServerDataBinding(!0),this.diagram.add(c),this.diagram.updateConnectorEdges(t),this.diagram.clearSelection(),this.diagram.select([this.diagram.nameTable[c.id]]),this.diagram.endGroupAction(),this.diagram.startTextEdit()}}},n}(),Boe=function(){function n(){}return n.prototype.findObjectsUnderMouse=function(t,e,i,r,s){var o=[];r&&r instanceof si&&r.nodes.length+r.connectors.length===1&&(r=r.nodes[0]||r.connectors[0]).children&&0===r.children.length&&(i.actualObject=r);for(var a,l,h,c,f,d=r&&r instanceof de&&(r.constraints&qe.ConnectToNearByNode||r.constraints&qe.ConnectToNearByPort)&&r.connectionPadding||0,p={},g=0,v=e.spatialSearch.findObjects(new Ne(t.x-50-d,t.y-50-d,100+d,100+d));g-1&&o.splice(T,1),"UmlClassifier"===y.shape.type&&y.container&&"Stack"===y.container.type&&(T=o.indexOf(e.nameTable[e.nameTable[y.id].wrapper.children[0].id]))>-1&&o.splice(T,1)}for(var P=0;Ps.zIndex&&(t[parseInt(r.toString(),10)]=l),r>0&&i&&a&&(a.isLane||a.isPhase||a.isHeader)&&t[parseInt(r.toString(),10)].zIndex=2)for(var d=t.length-1;d>=0;d--)if(t[parseInt(d.toString(),10)].parentId){var u=rm(t[parseInt(d.toString(),10)],e,""),p=rm(t[d-1],e,""),g=e.nameTable[""+p];g&&u!==p&&e.nameTable[""+u].zIndex=0;f--){d=Jp(e[parseInt(f.toString(),10)],!1),c=Jp(e[parseInt(f.toString(),10)],!0);var g=t[""+l].tool,v=this.findTargetElement(e[parseInt(f.toString(),10)].wrapper,o,t,void 0);if("Draw"===i&&v&&(e[parseInt(f.toString(),10)]instanceof te||e[parseInt(f.toString(),10)]instanceof de)&&!eb(e[parseInt(f.toString(),10)],v)&&(g&&"ConnectorSourceEnd"===g[""+h]&&!Nh(e[parseInt(f.toString(),10)])||g&&"ConnectorTargetEnd"===g[""+h]&&!da(e[parseInt(f.toString(),10)])))return u;if(e[parseInt(f.toString(),10)]instanceof te||e[parseInt(f.toString(),10)]instanceof de&&(Nh(e[parseInt(f.toString(),10)])||xd(d)||da(e[parseInt(f.toString(),10)])||Lh(c)||"PortDraw"===i&&g instanceof Od&&"ConnectorTargetEnd"===g[""+h]&&(da(e[parseInt(f.toString(),10)])||Lh(c))))return u=e[parseInt(f.toString(),10)],p&&(u=this.isTarget(u,t,i)),s.actualObject=u,u}else if("ConnectorTargetEnd"===i&&a){for(f=e.length-1;f>=0;f--)if(c=Jp(e[parseInt(f.toString(),10)],!0),(e[parseInt(f.toString(),10)]instanceof te||e[parseInt(f.toString(),10)]instanceof de)&&(da(e[parseInt(f.toString(),10)])||Lh(c)))return u=e[parseInt(f.toString(),10)],u=this.isTarget(u,t,i),s.actualObject=u,u}else{if(a&&("Drag"===i||t[""+l].tool instanceof ua)){var y=0;for(f=0;f=S.zIndex?u:S,y=Math.max(y,S.zIndex)):y=(u=S).zIndex)}return u&&"Bpmn"===u.shape.type&&(t.selectedItems.nodes.length>0&&"Bpmn"===t.selectedItems.nodes[0].shape.type||(u=null)),u&&(s.actualObject=u),u}if("Select"!==i&&"Pan"!==i||!t[""+l].tool)if("Pan"===i||"LayoutAnimation"===i){for(f=e.length-1;f>=0;f--)if((e[parseInt(f.toString(),10)]instanceof te||e[parseInt(f.toString(),10)]instanceof de)&&(v=this.findTargetElement(e[parseInt(f.toString(),10)].wrapper,o,t,void 0),"Pan"===i||v&&(v.id.match("_icon_content_shape$")||v.id.match("_icon_content_rect$"))))return e[parseInt(f.toString(),10)]}else u=e[e.length-1],s&&u&&(s.actualObject=u);else{for(f=e.length-1;f>=0;f--)if(e[parseInt(f.toString(),10)]instanceof de){var b=e[f-1];if(e[f-1]instanceof te&&b.ports){if((v=this.findTargetElement(b.wrapper,o,t,void 0))&&(v.id.match("_icon_content_shape$")||v.id.match("_icon_content_rect$")))return b;for(var M=0;M=0;s--){var o=t.children[parseInt(s.toString(),10)];if(o&&o.outerBounds.containsPoint(e,r||0))if(o.visible){if(o instanceof Cs){var a=this.findTargetElement(o,e,i);if(a)return a}var l="Clip"===o.style.textOverflow||"Ellipsis"===o.style.textOverflow;if(o.bounds.containsPoint(e,r||0)&&!l)return o;if(t.bounds.containsPoint(e,r||0)&&l)return o}else if(o instanceof Ke&&t&&t.id){var h=void 0;if(t.id.includes("group_container")){var c=t.id.slice(0,-15);h=i.getObject(c)}else h=i.getObject(t.id);if(JI(h,o.id))return o}}return t.bounds.containsPoint(e,r)&&"none"!==t.style.fill?t:null},n}(),Foe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),sf=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},$F=function(n){function t(e,i,r,s){var o=n.call(this,e,i,r,s)||this;return o.objectZIndex=-1,o.zIndexTable={},o.objects=[],o}return Foe(t,n),sf([I("")],t.prototype,"id",void 0),sf([I(!0)],t.prototype,"visible",void 0),sf([I(!1)],t.prototype,"lock",void 0),sf([I()],t.prototype,"objects",void 0),sf([I()],t.prototype,"addInfo",void 0),sf([I(-1)],t.prototype,"zIndex",void 0),t}(Ee),bT=function(n,t,e,i){return new(e||(e=Promise))(function(r,s){function o(h){try{l(i.next(h))}catch(c){s(c)}}function a(h){try{l(i.throw(h))}catch(c){s(c)}}function l(h){h.done?r(h.value):new e(function(c){c(h.value)}).then(o,a)}l((i=i.apply(n,t||[])).next())})},MT=function(n,t){var i,r,s,o,e={label:0,sent:function(){if(1&s[0])throw s[1];return s[1]},trys:[],ops:[]};return o={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function a(h){return function(c){return function l(h){if(i)throw new TypeError("Generator is already executing.");for(;e;)try{if(i=1,r&&(s=2&h[0]?r.return:h[0]?r.throw||((s=r.return)&&s.call(r),0):r.next)&&!(s=s.call(r,h[1])).done)return s;switch(r=0,s&&(h=[2&h[0],s.value]),h[0]){case 0:case 1:s=h;break;case 4:return e.label++,{value:h[1],done:!1};case 5:e.label++,r=h[1],h=[0];continue;case 7:h=e.ops.pop(),e.trys.pop();continue;default:if(!(s=(s=e.trys).length>0&&s[s.length-1])&&(6===h[0]||2===h[0])){e=0;continue}if(3===h[0]&&(!s||h[1]>s[0]&&h[1]1)for(var i=0;i-1)return e[parseInt(i.toString(),10)];return this.diagram.activeLayer},n.prototype.getLayer=function(t){for(var e=this.diagram.layers,i=0;i=0;o--)this.diagram.unSelect(this.diagram.nameTable[s[parseInt(o.toString(),10)]]),this.diagram.remove(this.diagram.nameTable[s[parseInt(o.toString(),10)]]),"default_layer"!==i.id&&this.diagram.activeLayer.id===t&&(this.diagram.activeLayer=this.diagram.layers[this.diagram.layers.length-1]);delete this.diagram.layerZIndexTable[i.zIndex],this.diagram.layers.splice(r,1),"SVG"!==this.diagram.mode&&this.diagram.refreshDiagramLayer()}},n.prototype.moveObjects=function(t,e){this.diagram.startGroupAction();for(var i={},r=[],s=0;s-1){if(r=[],(h=this.diagram.nameTable[""+s]).children)for(var f=0,g=h.children;f0){for(var y=void 0,S=0,b=r;S0)for(var r=0;r0)for(r=0;r0){t=t.concat(this.diagram.selectedItems.connectors);for(var i=0;i0)for(t=t.concat(this.diagram.selectedItems.nodes),i=0;i0){for(var i=0,r=t.shape.activity.subProcess.processes;i0&&this.copyProcesses(this.processTable[""+s])}this.clipboardData.processTable=this.processTable}},n.prototype.group=function(){this.oldSelectedObjects=tm(this.diagram);var e=this.diagram.isProtectedOnChange;this.diagram.protectPropertyChange(!0),this.diagram.diagramActions=this.diagram.diagramActions|ee.Group;var r={};r.id="group"+Qe(),(r=new te(this.diagram,"nodes",r,!0)).children=[];for(var s=this.diagram.selectedItems.nodes.concat(this.diagram.selectedItems.connectors).sort(function(h,c){return h.zIndex-c.zIndex}),o=0;o0){var a=this.diagram.add(r);a&&this.select(a),this.addHistoryEntry({type:"Group",undoObject:r,redoObject:r,category:"Internal"}),this.diagram.diagramActions=this.diagram.diagramActions&~ee.Group,this.diagram.protectPropertyChange(e)}},n.prototype.unGroup=function(t){var i=this.diagram.isProtectedOnChange;this.diagram.protectPropertyChange(!0),this.diagram.diagramActions=this.diagram.diagramActions|ee.Group;var r=[];t?r.push(t):r=this.diagram.selectedItems.nodes,this.diagram.startGroupAction();for(var s=0;s0&&this.diagram.removePorts(o,o.ports),o.annotations&&o.annotations.length>0&&!ce()&&this.diagram.removeLabels(o,o.annotations);for(var c=this.diagram.nameTable[o.parentId],d=o.children.length-1;d>=0;d--)this.diagram.nameTable[o.children[parseInt(d.toString(),10)]].parentId="",this.diagram.deleteChild(this.diagram.nameTable[o.children[parseInt(d.toString(),10)]],o),o.parentId&&o.children[parseInt(d.toString(),10)]&&this.diagram.addChild(c,o.children[parseInt(d.toString(),10)]);this.resetDependentConnectors(o.inEdges,!0),this.resetDependentConnectors(o.outEdges,!1),this.diagram.diagramActions&ee.UndoRedo||this.addHistoryEntry({type:"UnGroup",undoObject:a,redoObject:a,category:"Internal"}),o.parentId&&this.diagram.deleteChild(o,c)}this.diagram.removeNode(o,l),this.clearSelection()}this.diagram.endGroupAction(),this.diagram.diagramActions=this.diagram.diagramActions&~ee.Group,this.diagram.protectPropertyChange(i)},n.prototype.resetDependentConnectors=function(t,e){for(var i=0;i0&&(g=!1)}if(g){var y=this.cloneConnector(p,i);c.push(y),o[h.id]=y.id}}else{var S=this.cloneNode(h,i);if(c.push(S),S){o[h.id]=S.id;var b=h.inEdges;if(b)for(var M=0,w=b;M0)for(var u=0;u0)for(r=t.segments,s=0;s0&&this.diagram.drawingObject&&"Bezier"===this.diagram.drawingObject.type&&(t.segments=[]);var e=this.diagram.add(t);"SVG"!==this.diagram.mode&&this.diagram.refreshDiagramLayer(),this.selectObjects([e]),t&&!NI(this.diagram)&&(this.diagram.tool&=~Ci.DrawOnce,this.diagram.currentDrawingObject=void 0)},n.prototype.enableServerDataBinding=function(t){this.diagram.enableServerDataBinding(t)},n.prototype.addText=function(t,e){var i=this.diagram.findElementUnderMouse(t,e,this.diagram);this.diagram.startTextEdit(t,i instanceof ni?i.id.split("_")[1]:void 0)},n.prototype.isUserHandle=function(t){var e=this.diagram.selectedItems;if(e.wrapper&&qr(e.constraints,"UserHandle"))for(var i=0,r=e.userHandles;i0&&t[0]&&t[0].isLane)for(s=this.diagram.getObject(t[0].parentId),t[0].shape.header=[],a=0;a1||e&&1===t.length)){if(1!==t.length)return[2];this.clearSelection()}if(!(u||d||1!==t.length||e&&Xa(this.diagram)))return this.clearSelection(),[2]}if(!r.cancel){for(p=0;p0||e)&&f.children&&!f.parentId)for(g=0;g0||e,!0)}else this.select(f,p>0||e,!0);void 0===i&&(i=c),r={oldValue:i||[],newValue:this.getSelectedObject(),cause:this.diagram.diagramActions,state:"Changed",type:"Addition",cancel:!1},this.diagram.renderSelector(e||t&&t.length>1),ce()||this.diagram.triggerEvent(Ce.selectionChange,r),this.diagram.enableServerDataBinding(!0)}return[2]})})},n.prototype.findParent=function(t){return t.parentId&&this.findParent(t=this.diagram.nameTable[t.parentId]),t},n.prototype.selectProcesses=function(t){if(this.hasProcesses(t))for(var e=t.shape.activity.subProcess.processes,i=0;i0)},n.prototype.select=function(t,e,i){var r=this.getObjectLayer(t.id);if(Dd(t)&&!(t instanceof si)&&!_r(this.diagram,t)&&r&&!r.lock&&r.visible&&t.wrapper.visible){(e=!!Xa(this.diagram)&&e)||this.clearSelection(),this.diagram.enableServerDataBinding(!1);var s=this.diagram.selectedItems;if(t instanceof te?s.nodes.push(t.isHeader?this.diagram.nameTable[t.parentId]:t):s.connectors.push(t),s.selectedObjects.push(t),e)s.wrapper.rotateAngle=s.rotateAngle=0,s.wrapper.children.push(t.wrapper);else if(s.init(this.diagram),1===s.nodes.length&&0===s.connectors.length){var l=_x(this.diagram,s);l&&(s.wrapper.children[0]=l),s.rotateAngle=s.nodes[0].rotateAngle,s.wrapper.rotateAngle=s.nodes[0].rotateAngle,s.wrapper.pivot=s.nodes[0].pivot}i||this.diagram.renderSelector(e),this.diagram.enableServerDataBinding(!0)}},n.prototype.labelSelect=function(t,e){this.oldSelectedObjects=tm(this.diagram);var i=this.diagram.selectedItems,r=this.diagram.allowServerDataBinding;this.diagram.allowServerDataBinding=!1,i.nodes=i.connectors=[],this.diagram.allowServerDataBinding=r,t instanceof te?i.nodes[0]=t:i.connectors[0]=t,i.annotation=this.findTarget(e,t),i.init(this.diagram),this.diagram.renderSelector(!1)},n.prototype.unSelect=function(t){var e=this.diagram.selectedItems.nodes.concat(this.diagram.selectedItems.connectors),i=e.filter(function(a){return a.id!==t.id}),r={oldValue:e,newValue:i,cause:this.diagram.diagramActions,state:"Changing",type:"Removal",cancel:!1};if(this.diagram.currentSymbol||ce()||this.diagram.triggerEvent(Ce.selectionChange,r),_r(this.diagram,t)){var s=this.diagram.selectedItems,o=void 0;t instanceof te?(o=s.nodes.indexOf(t,0),s.nodes.splice(o,1)):(o=s.connectors.indexOf(t,0),s.connectors.splice(o,1)),o=s.selectedObjects.indexOf(t,0),s.selectedObjects.splice(o,1),(r={oldValue:e,newValue:i,cause:this.diagram.diagramActions,state:"Changed",type:"Removal",cancel:(r={oldValue:e,newValue:i,cause:this.diagram.diagramActions,state:"Changed",type:"Removal",cancel:!1}).cancel}).cancel||(o=s.wrapper.children.indexOf(t.wrapper,0),s.wrapper.children.splice(o,1),this.diagram.updateSelector(),this.diagram.currentSymbol||this.diagram.triggerEvent(Ce.selectionChange,r))}},n.prototype.moveSvgNode=function(t,e){var i=xt(e+"_groupElement",this.diagram.element.id),r=xt(t+"_groupElement",this.diagram.element.id);i.parentNode.insertBefore(r,i)},n.prototype.moveAfterSvgNode=function(t,e){var i=xt(e+"_groupElement",this.diagram.element.id),r=xt(t+"_groupElement",this.diagram.element.id);i.insertAdjacentElement("afterend",r)},n.prototype.sendLayerBackward=function(t){var e=this.getLayer(t);if(e&&0!==e.zIndex){var i=e.zIndex;if("SVG"===this.diagram.mode){var r=e.objects,s=this.getLayer(this.diagram.layerZIndexTable[i-1]).objects[0];if(s)for(var o=0,a=r;od&&"SwimLane"!==f.shape.type){var S=$(f);f.zIndex=d-((-1!==i.indexOf(f)?i.indexOf(f):0)+1),f.children&&(d=this.findLowestZIndex(f,c)||d),this.triggerOrderCommand(S,f,f),f.children&&this.updateGroupZindex(f,"SendToBack",d)}else"SwimLane"===f.shape.type&&(y=this.swapZIndexObjects(a,h,r,g));if("SVG"===this.diagram.mode){for(var M="SwimLane"!==this.diagram.nameTable[""+r].shape.type?d:y,w=h[parseInt(M.toString(),10)];!w&&Md)&&(d=p.zIndex)}for(var f=JSON.parse(JSON.stringify(l)),v=Number(Object.keys(l).sort(function(wo,Hl){return Number(wo)-Number(Hl)}).reverse()[0]),y=this.diagram.nameTable[""+e].zIndex,S=[],M=0;M<=v;M++)S.push(l[parseInt(M.toString(),10)]);if("SwimLane"===this.diagram.nameTable[""+e].shape.type)for(var C=v;C>=y;C--)if(l[parseInt(C.toString(),10)]&&this.diagram.nameTable[l[parseInt(C.toString(),10)]].parentId!==e){v=C;break}var D=this.diagram.nameTable[""+e];if(D.zIndexx&&(x=L.zIndex)}}else x=d;D.zIndex=x+((-1!==r.indexOf(D)?r.indexOf(D):0)+1),this.triggerOrderCommand(A,D,D)}else if("SwimLane"===D.shape.type){for(var O=0,N=-1,T=0,P=0,_=JSON.parse(JSON.stringify(l)),B=0;B<=y;B++)if(l[parseInt(B.toString(),10)]&&this.diagram.nameTable[l[parseInt(B.toString(),10)]].parentId===e&&-1===N){N=B,T=B;break}for(var j=0;j<=v;j++)f[parseInt(j.toString(),10)]&&f[parseInt(j.toString(),10)]!==e&&this.diagram.nameTable[f[parseInt(j.toString(),10)]].parentId!==e&&this.diagram.nameTable[f[parseInt(j.toString(),10)]].zIndex>=this.diagram.nameTable[""+e].zIndex&&O++;for(var ue=N,pe=0;pe<=O;pe++){for(;!l[parseInt(ue.toString(),10)];)ue++;P=this.diagram.nameTable[l[parseInt(ue.toString(),10)]].zIndex,ue++}for(var Me=P;Me<=v;Me++){for(;!_[parseInt(N.toString(),10)];)N++;for(;!l[parseInt(Me.toString(),10)];)Me++;l[parseInt(Me.toString(),10)]=_[parseInt(N.toString(),10)],this.diagram.nameTable[l[parseInt(Me.toString(),10)]].zIndex=Me,N++}l[parseInt(v.toString(),10)]=this.diagram.nameTable[""+e].id,this.diagram.nameTable[""+e].zIndex=v,ue=y+1;for(var De=T,xe=0;xe0&&("Native"===cr[0].shape.type||"HTML"===cr[0].shape.type)){for(Mi.parentNode.removeChild(Mi),De=0;De0?r[0]:null},n.prototype.findLowestZIndex=function(t,e){var r=this.diagram.nodes.filter(function(s){return-1!==e.indexOf(s.id)}).filter(function(s){return""===s.parentId&&s.id!==t.id}).map(function(s){return s.zIndex});return r.sort(function(s,o){return s-o}),r.length>0?r[0]:null},n.prototype.triggerOrderCommand=function(t,e,i){var s={zIndex:$(t).zIndex},o={zIndex:e.zIndex},a={element:i,cause:this.diagram.diagramActions,diagramAction:this.diagram.getDiagramAction(this.diagram.diagramActions),oldValue:s,newValue:o};this.diagram.triggerEvent(Ce.propertyChange,a)},n.prototype.checkGroupNode=function(t,e,i){return i[""+e].parentId===i[""+t].parentId},n.prototype.sortByZIndex=function(t,e,i){if("BringForward"===i){var r=e||"zIndex";t=t.sort(function(o,a){return a[""+r]-o[""+r]})}else{var s=e||"zIndex";t=t.sort(function(o,a){return o[""+s]-a[""+s]})}return t},n.prototype.orderCommands=function(t,e,i){var r=this,s=e.nodes;if(s=s.concat(e.connectors),t)if("SendBackward"===i)for(var o=0;oa}),S=v.filter(function(D){return D0?Math.max.apply(Math,S):a,M=y.length>0?Math.min.apply(Math,y):a;if(a!==M){var w=c.zIndexTable[parseInt(M.toString(),10)],C=c.zIndexTable[parseInt(a.toString(),10)];this.moveSvgNode(C,w)}else"SendToBack"===i&&(w=c.zIndexTable[parseInt(a.toString(),10)],C=c.zIndexTable[parseInt(b.toString(),10)],this.moveAfterSvgNode(w,C))}}else this.diagram.refreshCanvasLayers()}},n.prototype.sendForward=function(t){var e=this;if(this.diagram.protectPropertyChange(!0),Xa(this.diagram)||t){$(t||(this.diagram.selectedItems.nodes.length?this.diagram.selectedItems.nodes[0]:this.diagram.selectedItems.connectors[0]));var s=t&&t.id,o=this.diagram.layers.indexOf(this.getObjectLayer(s=s||(this.diagram.selectedItems.nodes.length?this.diagram.selectedItems.nodes[0].id:this.diagram.selectedItems.connectors[0].id))),a=$(this.diagram.nameTable),h=(parseInt(o.toString(),10),this.diagram.nameTable[""+s]),c=[],d=this.diagram.spatialSearch.findObjects(h.wrapper.bounds);d.length>2&&(d=this.sortByZIndex(d,void 0,"BringForward"));for(var u=0,p=d;u=0;f--)this.diagram.nameTable[c[parseInt(f.toString(),10)].id].parentId===s&&c.splice(f,1);if(c.length>0){var y=this.diagram.nameTable[c[c.length-1].id];if(y.parentId){var b=rm(y,this.diagram,""),M=this.diagram.nameTable[""+b];M.id!==s&&(c[0]=M)}var w={};for(f=0;f0&&(Object.values(O).forEach(function(ue){ue>=T&&N.push(ue)}),0!==N.length&&this.updateZIndexBySendForward(h,N,o))}var P=[];if(Object.keys(this.changedNodeZIndexes).forEach(function(ue){if((a[""+ue]?a[""+ue].zIndex:null)!==e.changedNodeZIndexes[""+ue]){var De=$(a[""+ue]);P.push(De)}}),this.updateLayerZindexTable(o),L.nodes.splice(0,L.nodes.length),P.forEach(function(ue){var pe=$(ue);L.nodes.push(pe)}),"SVG"===this.diagram.mode){var _=c[c.length-1].id,B=c[c.length-1];B&&!("HTML"===B.shape.type||"Native"===B.shape.type)&&this.moveAfterSvgNode(s,_),this.updateNativeNodeIndex(_,s)}else this.diagram.refreshCanvasLayers();var j=[];Object.keys(this.changedNodeZIndexes).forEach(function(ue){if((a[""+ue]?a[""+ue].zIndex:null)!==e.changedNodeZIndexes[""+ue]){var De=$(e.diagram.nameTable[""+ue]);j.push(De)}});var Q=$(this.diagram.selectedItems);Q.nodes.splice(0,Q.nodes.length),j.forEach(function(ue){var pe=$(ue);Q.nodes.push(pe)}),this.diagram.diagramActions&ee.UndoRedo||this.addHistoryEntry({type:"SendForward",category:"Internal",undoObject:L,redoObject:Q}),this.diagram.endGroupAction()}}this.diagram.protectPropertyChange(!1)},n.prototype.updateZIndexBySendForward=function(t,e,i){var r=$(t);t.zIndex=Math.min.apply(Math,e);var a,s=Math.min.apply(Math,e),o=Math.min.apply(Math,e),l=this.diagram.layers[parseInt(i.toString(),10)].objects,h=this.diagram.nodes.filter(function(S){return-1!==l.indexOf(S.id)});t.children&&this.updateGroupZindex(t,"BringForward",t.zIndex);var c=h.filter(function(S){return S.zIndex===Math.min.apply(Math,e)&&S.id!==t.id});if(c&&c.length>0&&c[0].children){for(var d=Math.min.apply(Math,e),u=0;uo&&g!==t&&g.parentId!==t.id&&c&&c.length>0&&g.parentId!==c[0].id){var v=$(g);g.zIndex=a+1,a++,this.triggerOrderCommand(v,g,g)}var y=g.zIndex;this.changedNodeZIndexes[g.id]=(this.changedNodeZIndexes.hasOwnProperty(g.id),y)}},n.prototype.arrangeZIndexForLowerNodes=function(t,e,i){var r=i.filter(function(o){return o.zIndex<=t&&o.parentId!==e.id});r.sort(function(o,a){return a.zIndex-o.zIndex});for(var s=0;se&&(e=r.zIndex)}return e},n.prototype.sendBackward=function(t){var e=this;if(this.diagram.protectPropertyChange(!0),Xa(this.diagram)||t){$(t||(this.diagram.selectedItems.nodes.length?this.diagram.selectedItems.nodes[0]:this.diagram.selectedItems.connectors[0]));var s=t&&t.id,o=this.diagram.layers.indexOf(this.getObjectLayer(s=s||(this.diagram.selectedItems.nodes.length?this.diagram.selectedItems.nodes[0].id:this.diagram.selectedItems.connectors[0].id))),a=$(this.diagram.nameTable),h=(parseInt(o.toString(),10),this.diagram.nameTable[""+s]),c=[],d=this.diagram.spatialSearch.findObjects(h.wrapper.bounds);d.length>2&&(d=this.sortByZIndex(d));for(var u=0,p=d;uNumber(f.zIndex)&&""===f.parentId&&h.wrapper.bounds.intersects(f.wrapper.bounds)&&c.push(f);for(var f=c.length-1;f>=0;f--)(v=this.diagram.nameTable[c[parseInt(f.toString(),10)].id]).parentId===s&&c.splice(f,1);if(c.length>0){var v;if((v=this.diagram.nameTable[c[c.length-1].id]).parentId){var S=rm(v,this.diagram,""),b=this.diagram.nameTable[""+S];s!==b.id&&(c[c.length-1]=b)}var M={};for(f=0;f0&&(Object.values(L).forEach(function(pe){pe<=N&&O.push(pe)}),0!==O.length&&this.updateZIndexBySendBackward(h,O,o))}var T=[];if(Object.keys(this.changedNodeZIndexes).forEach(function(pe){if((a[""+pe]?a[""+pe].zIndex:null)!==e.changedNodeZIndexes[""+pe]){var xe=$(a[""+pe]);T.push(xe)}}),this.updateLayerZindexTable(o),R.nodes.splice(0,R.nodes.length),T.forEach(function(pe){var Me=$(pe);R.nodes.push(Me)}),"SVG"===this.diagram.mode){var P=c[c.length-1].id,_=c[c.length-1];_&&"HTML"!==_.shape.type&&"Native"!==_.shape.type&&this.moveSvgNode(s,P);var B=this.diagram.nameTable[""+P];B.children&&B.children.length>0?this.updateNativeNodeIndex(s):this.updateNativeNodeIndex(s,P)}else this.diagram.refreshCanvasLayers();var j=[];Object.keys(this.changedNodeZIndexes).forEach(function(pe){if((a[""+pe]?a[""+pe].zIndex:null)!==e.changedNodeZIndexes[""+pe]){var xe=$(e.diagram.nameTable[""+pe]);j.push(xe)}});var Q=$(this.diagram.selectedItems);Q.nodes.splice(0,Q.nodes.length),j.forEach(function(pe){var Me=$(pe);Q.nodes.push(Me)}),this.diagram.diagramActions&ee.UndoRedo||this.addHistoryEntry({type:"SendBackward",category:"Internal",undoObject:R,redoObject:Q}),this.diagram.endGroupAction()}}this.diagram.protectPropertyChange(!1)},n.prototype.updateZIndexBySendBackward=function(t,e,i){var r=$(t);t.zIndex=Math.max.apply(Math,e);var p,s=t.zIndex,o=Math.max.apply(Math,e),a=this.diagram.layers[parseInt(i.toString(),10)].objects,l=this.diagram.nodes.filter(function(S){return-1!==a.indexOf(S.id)}),h=l.filter(function(S){return S.zIndex===Math.max.apply(Math,e)&&S.id!==t.id});if(h&&h.length>0&&h[0].children)for(var c=Math.max.apply(Math,e),d=0;d0&&g.parentId!==h[0].id){var v=$(g);g.zIndex=p-1,p--,this.triggerOrderCommand(v,g,g)}var y=g.zIndex;this.changedNodeZIndexes[""+g.id]=(this.changedNodeZIndexes.hasOwnProperty(g.id),y)}},n.prototype.findLowestChildZIndex=function(t){for(var e=t.zIndex,i=0;i0),this.selectObjects([t],!0))},n.prototype.clearSelection=function(t,e){return bT(this,void 0,void 0,function(){var i,r,s,o;return MT(this,function(a){return i=this.diagram.allowServerDataBinding,this.diagram.enableServerDataBinding(!1),Xa(this.diagram)&&(r=this.diagram.selectedItems,s=this.getSelectedObject(),this.diagram.currentSymbol&&(this.diagram.previousSelectedObject=s),o={oldValue:s,newValue:[],cause:this.diagram.diagramActions,state:"Changing",type:"Removal",cancel:!1},t&&(ce()||this.diagram.triggerEvent(Ce.selectionChange,o)),o.cancel||(r.offsetX=0,r.offsetY=0,r.width=0,r.height=0,r.rotateAngle=0,r.nodes=[],r.connectors=[],r.wrapper=null,r.annotation=void 0,r.selectedObjects=[],this.diagram.clearSelectorLayer(),t&&(o={oldValue:s,newValue:[],cause:this.diagram.diagramActions,state:"Changed",type:"Removal",cancel:!1},ce()||this.diagram.triggerEvent(Ce.selectionChange,o))),this.diagram.enableServerDataBinding(i)),[2]})})},n.prototype.clearSelectedItems=function(){this.clearSelection((this.diagram.selectedItems.nodes?this.diagram.selectedItems.nodes.length:0)+(this.diagram.selectedItems.connectors?this.diagram.selectedItems.connectors.length:0)>0)},n.prototype.removeStackHighlighter=function(){var t=Pl(this.diagram.element.id),e=t.getElementById(t.id+"_stack_highlighter");e&&e.parentNode.removeChild(e)},n.prototype.renderStackHighlighter=function(t,e){var r,s,o,i=this.diagram.selectedItems.nodes[0];if(!e){var a=this.diagram.findObjectsUnderMouse(t.position);if((e=this.diagram.findObjectUnderMouse(a,"Drag",!0))&&!(e.isLane||e.isPhase||e.isHeader))for(var l=0;l0)for(var a=0;a1)if(i){var h=l.segments[0],c=l.segments[1],u=Tc(II(t.wrapper,t.wrapper.corners,t.wrapper.bounds),h.direction),g=Ll({corners:void 0,point:u=Ah(l,0,u,{x:l.sourceWrapper.offsetX,y:l.sourceWrapper.offsetY},!1),margin:void 0,direction:h.direction},{corners:void 0,point:c.points[1],margin:void 0,direction:void 0});h.length=z.distancePoints(g[0],g[1]),c.direction&&c.length&&(c.length=z.distancePoints(g[1],g[2]))}else if(o){switch(l.segments[0].direction){case"Bottom":r=t.wrapper.bounds.bottomCenter.x-e.bottomCenter.x,s=t.wrapper.bounds.bottomCenter.y-e.bottomCenter.y;break;case"Top":r=t.wrapper.bounds.topCenter.x-e.topCenter.x,s=t.wrapper.bounds.topCenter.y-e.topCenter.y;break;case"Left":r=t.wrapper.bounds.middleLeft.x-e.middleLeft.x,s=t.wrapper.bounds.middleLeft.y-e.middleLeft.y;break;case"Right":r=t.wrapper.bounds.middleRight.x-e.middleRight.x,s=t.wrapper.bounds.middleRight.y-e.middleRight.y}this.dragSourceEnd(l,r,s,!0,null,"ConnectorSourceEnd",void 0,void 0,void 0,!(t.parentId&&this.diagram.diagramActions&ee.isGroupDragging))}}},n.prototype.updateEndPoint=function(t,e){var r={sourcePoint:t.sourcePoint,targetPoint:t.targetPoint};t.sourceID&&(r.sourceID=t.sourceID),t.targetID&&(r.targetID=t.targetID),t.sourcePortID&&(r.sourcePortID=t.sourcePortID),t.targetPortID&&(r.targetPortID=t.targetPortID),t.segments&&(r.segments=t.segments),this.diagram.connectorPropertyChange(t,e||{},r),this.diagram.updateSelector()},n.prototype.dragSourceEnd=function(t,e,i,r,s,o,a,l,h,c,d){var u=this.diagram.nameTable[t.id],p={},f=this.checkBoundaryConstraints(e,i,u.wrapper.bounds);if(EI(u)&&f&&"BezierSourceThumb"!==o&&Uv(this.diagram)&&(p=$(p={sourcePoint:u.sourcePoint}),u.sourcePoint.x+=e,u.sourcePoint.y+=i,"ConnectorSourceEnd"===o&&"Orthogonal"===u.type&&this.changeSegmentLength(u,l,h,c),"Bpmn"===u.shape.type&&"Default"===u.shape.sequence&&"Sequence"===u.shape.flow&&this.updatePathElementOffset(u)),"Bezier"===u.type)if(p={sourcePoint:u.sourcePoint},d)this.translateBezierPoints(t,""===o?"ConnectorSourceEnd":o,e,i,d,s,!a);else for(var g=0;g2){var d=z.direction((c=t.segments[2]).points[0],c.points[1]);o.direction===ls(d)?("Right"===o.direction?c.points[0].x=o.points[o.points.length-1].x=l.wrapper.corners.middleRight.x+20:"Left"===o.direction?c.points[0].x=o.points[o.points.length-1].x=l.wrapper.corners.middleLeft.x-20:c.points[0].y=o.points[o.points.length-1].y="Top"===o.direction?l.wrapper.corners.topCenter.y-20:l.wrapper.corners.bottomCenter.y+20,c.direction&&c.length&&(c.length=z.distancePoints(c.points[0],c.points[c.points.length-1])),o.length=z.distancePoints(o.points[0],o.points[o.points.length-1])):o.direction===d&&c.direction&&c.length?("Top"===o.direction||"Bottom"===o.direction?(c.points[0]=o.points[0],c.points[c.points.length-1].x=c.points[0].x):(c.points[0]=o.points[0],c.points[c.points.length-1].y=c.points[0].y),c.length=z.distancePoints(c.points[0],c.points[c.points.length-1]),t.segments.splice(0,2)):o.length=20}else o.length=20;else if(o.length<1)if(""!==t.sourceID){var c;"Right"===a.direction?a.points[a.points.length-1].y=(h=l.wrapper.corners.middleRight).y:"Left"===a.direction?a.points[a.points.length-1].y=(h=l.wrapper.corners.middleLeft).y:a.points[a.points.length-1].x="Top"===a.direction?(h=l.wrapper.corners.topCenter).x:(h=l.wrapper.corners.bottomCenter).x,a.length=z.distancePoints(h,a.points[a.points.length-1]),t.segments.length>2&&(c=t.segments[2]).direction&&c.length&&(c.length=z.distancePoints(a.points[a.points.length-1],c.points[c.points.length-1])),t.segments.splice(0,1)}else t.segments.splice(0,1)}else e&&!i&&t.sourceID!==e.id&&t.segments&&null!==t.segments[0].direction&&e&&e instanceof te&&s&&this.changeSourceEndToNode(t,e),e&&i&&t.sourcePortID!==i&&t.segments&&null!==t.segments[0].direction&&e&&e instanceof te&&s&&this.changeSourceEndToPort(t,e,i)},n.prototype.canConnect=function(t,e){return!(!da(e)||!Nh(e))},n.prototype.changeSourceEndToPort=function(t,e,i){var r=this.diagram.getWrapper(e.wrapper,i),s={x:r.offsetX,y:r.offsetY},o=zo(s,En(e.wrapper),e.wrapper.bounds),a=t.segments[0],l=t.segments[1];if(a.direction!==o){var h=[],c={};if(a.direction===ls(o)){c={};var d=void 0;"Top"===o||"Bottom"===o?(d="Top"===o?{type:"Orthogonal",isTerminal:!0,direction:o,length:Math.abs(a.points[0].y-s.y)}:{type:"Orthogonal",isTerminal:!0,direction:o,length:Math.abs(s.y-a.points[0].y)},c=a.points[0].x>s.x?{type:"Orthogonal",isTerminal:!0,direction:"Right",length:a.points[0].x-s.x}:{type:"Orthogonal",isTerminal:!0,direction:"Left",length:s.x-a.points[0].x}):(d="Right"===o?{type:"Orthogonal",isTerminal:!0,direction:o,length:Math.abs(a.points[0].x-s.x)}:{type:"Orthogonal",isTerminal:!0,direction:o,length:Math.abs(s.x-a.points[0].x)},c=a.points[0].y>s.y?{type:"Orthogonal",direction:"Top",isTerminal:!0,length:a.points[0].y-s.y}:{type:"Orthogonal",direction:"Bottom",isTerminal:!0,length:s.y-a.points[0].y}),h.push(new bi(t,"segments",d,!0)),h.push(new bi(t,"segments",c,!0))}else h.push(new bi(t,"segments",c={type:"Orthogonal",direction:o,length:20,isTerminal:!0},!0));a.direction!==ls(o)&&("Top"===o||"Bottom"===o?(a.points[0].x=s.x,a.points[0].y=a.points[a.points.length-1].y="Top"===o?s.y-20:s.y+20):(a.points[0].y=s.y,a.points[0].x=a.points[a.points.length-1].x="Right"===o?s.x+20:s.x-20),a.length=z.distancePoints(a.points[0],a.points[a.points.length-1]),l.length=z.distancePoints(a.points[a.points.length-1],l.points[l.points.length-1])),t.segments=h.concat(t.segments)}else a.points[0]=s,"Top"===o||"Bottom"===o?a.points[a.points.length-1].x=s.x:a.points[a.points.length-1].y=s.y,a.length=z.distancePoints(a.points[0],a.points[a.points.length-1]),l.length=z.distancePoints(a.points[a.points.length-1],l.points[l.points.length-1])},n.prototype.removeTerminalSegment=function(t,e){for(var i=0;ii.width||"Left"===o.direction&&r.x>=o.points[0].x||"Right"===o.direction&&r.x<=o.points[0].x)o.points[0].y=o.points[o.points.length-1].y=r.y,o.points[0].x=r.x,o.length=z.distancePoints(o.points[0],o.points[o.points.length-1]),a.length=z.distancePoints(o.points[o.points.length-1],a.points[a.points.length-1]);else{var h=void 0;s="Bottom"===(h=a.direction?a.direction:z.direction(a.points[0],a.points[a.points.length-1]))?i.bottomCenter:i.topCenter,a.length&&a.direction&&(a.length="Top"===h?o.points[o.points.length-1].y-(s.y+20):s.y+20-o.points[o.points.length-1].y),o.length=o.points[o.points.length-1].x-s.x,o.direction=o.length>0?"Right":"Left",l.push(new bi(t,"segments",{type:"Orthogonal",direction:h,length:20},!0)),t.segments=l.concat(t.segments)}else r="Bottom"===o.direction?i.bottomCenter:i.topCenter,o.length>i.height||"Top"===o.direction&&r.y>=o.points[0].y||"Bottom"===o.direction&&r.y<=o.points[0].y?(o.points[0].x=o.points[o.points.length-1].x=r.x,o.points[0].y=r.y,o.length=z.distancePoints(o.points[0],o.points[o.points.length-1]),a.length=z.distancePoints(o.points[o.points.length-1],a.points[a.points.length-1])):(s="Left"===a.direction?i.middleLeft:i.middleRight,h=void 0,h=a.direction?a.direction:z.direction(a.points[0],a.points[a.points.length-1]),a.length&&a.direction&&(a.length="Left"===h?o.points[o.points.length-1].x-(s.x+20):s.x+20-o.points[o.points.length-1].x),o.length=o.points[o.points.length-1].y-s.y,o.direction=o.length>0?"Bottom":"Top",l.push(new bi(t,"segments",{type:"Orthogonal",direction:h,length:20},!0)),t.segments=l.concat(t.segments))},n.prototype.translateBezierPoints=function(t,e,i,r,s,o,a){var l=t.segments.indexOf(s),h=t.segments[parseInt(l.toString(),10)],c=l>0?t.segments[l-1]:null,d=null!==c?c.point:t.sourcePoint,u=l===t.segments.length-1?t.targetPoint:h.point;if(h)if("BezierSourceThumb"===e&&(h.vector1.angle||h.vector1.distance)){var p=h.vector1.distance,f=h.vector1.angle;h.vector1={distance:t.distance(d,o),angle:z.findAngle(d,o)},this.translateSubsequentSegment(t,s,!0,h.vector1.distance-p,h.vector1.angle-f)}else"BezierTargetThumb"===e&&(h.vector2.angle||h.vector2.distance)?(p=h.vector2.distance,f=h.vector2.angle,h.vector2={distance:t.distance(u,o),angle:z.findAngle(u,o)},this.translateSubsequentSegment(t,s,!1,h.vector2.distance-p,h.vector2.angle-f)):("ConnectorSourceEnd"===e&&!t.sourceID||"ConnectorTargetEnd"===e&&!t.targetID)&&a&&WI(h.vector1)&&WI(h.vector2)?(z.isEmptyPoint(h.point1)&&(h.bezierPoint1=YI(t.sourcePoint,t.targetPoint)),z.isEmptyPoint(h.point2)&&(h.bezierPoint2=YI(t.targetPoint,t.sourcePoint))):"BezierSourceThumb"===e||"ConnectorSourceEnd"===e&&!a&&WI(h.vector1)?(h.bezierPoint1.x+=i,h.bezierPoint1.y+=r,(!z.isEmptyPoint(h.point1)||a)&&(h.point1={x:h.bezierPoint1.x,y:h.bezierPoint1.y})):("BezierTargetThumb"===e||"ConnectorTargetEnd"===e&&!a&&WI(h.vector2))&&(h.bezierPoint2.x+=i,h.bezierPoint2.y+=r,(!z.isEmptyPoint(h.point2)||a)&&(h.point2={x:h.bezierPoint2.x,y:h.bezierPoint2.y}))},n.prototype.translateSubsequentSegment=function(t,e,i,r,s){var o=t.segments.indexOf(e);parseInt(o.toString(),10),t.bezierSettings.smoothness&gI.SymmetricAngle||(s=null),t.bezierSettings.smoothness&gI.SymmetricDistance||(r=null),(null!=r||null!=s)&&(i?0!==o&&this.updatePreviousBezierSegment(t,o,r,s):o!==t.segments.length-1&&this.updateNextBezierSegment(t,o,r,s))},n.prototype.updatePreviousBezierSegment=function(t,e,i,r){var s=t.segments[e-1],a=(s.vector2.angle+r)%360;a<0&&(a+=360),s.vector2={distance:s.vector2.distance+i,angle:a}},n.prototype.updateNextBezierSegment=function(t,e,i,r){var s=t.segments[e+1],a=(s.vector1.angle+r)%360;a<0&&(a+=360),s.vector1={distance:s.vector1.distance+i,angle:a}},n.prototype.dragTargetEnd=function(t,e,i,r,s,o,a,l){var c,h=this.diagram.nameTable[t.id],d=this.checkBoundaryConstraints(e,i,h.wrapper.bounds);if(DI(h)&&"BezierTargetThumb"!==o&&d&&Uv(this.diagram)){if(c=$(c={targetPoint:h.targetPoint}),h.targetPoint.x+=e,h.targetPoint.y+=i,"ConnectorTargetEnd"===o&&"Orthogonal"===h.type&&h.segments&&h.segments.length>0){var u=h.segments[h.segments.length-2];u&&2===h.segments[h.segments.length-1].points.length&&("Left"===u.direction||"Right"===u.direction?u.points[u.points.length-1].x=h.targetPoint.x:u.points[u.points.length-1].y=h.targetPoint.y,u.length=z.distancePoints(u.points[0],u.points[u.points.length-1]),u.direction=z.direction(u.points[0],u.points[u.points.length-1]))}"Bpmn"===h.shape.type&&"Default"===h.shape.sequence&&"Sequence"===h.shape.flow&&this.updatePathElementOffset(h)}if("Bezier"===h.type)if(c={targetPoint:h.targetPoint},l)this.translateBezierPoints(t,""===o?"ConnectorTargetEnd":o,e,i,l,s,!a);else for(var p=0;p0){if(void 0!==s&&o.segments[parseInt(s.toString(),10)])if("Bezier"===o.type){var a=o.segments[parseInt(s.toString(),10)],l=a.isInternalSegment;l&&null!==o.bezierSettings&&"FreeForm"!==o.bezierSettings.segmentEditOrientation?("Horizontal"===a.orientation?a.point.x+=e:a.point.y+=i,this.updateDirectionalBezierCurve(o)):(a.point.x+=e,a.point.y+=i),l&&(o.isBezierEditing=!0)}else o.segments[parseInt(s.toString(),10)].point.x+=e,o.segments[parseInt(s.toString(),10)].point.y+=i;else for(var h=0;h1){var a=e[1],l=e[2],h={x:.5*(a.x+l.x),y:.5*(a.y+l.y)},c=t.segments[0];c.vector1.angle=Gt(s,a),c.vector1.distance=.5*z.findLength(s,a),c.vector2.angle=Gt(h,a),c.vector2.distance=.5*z.findLength(h,a),c.point=h;var d=t.segments[1];if(d.vector1.angle=Gt(h,l),d.vector1.distance=.5*z.findLength(h,l),t.segments.length>2){var u=e[3],p={x:.5*(l.x+u.x),y:.5*(l.y+u.y)};d.vector2.angle=Gt(p,l),d.vector2.distance=.5*z.findLength(p,l),d.point=p;var f=t.segments[2];if(f.vector1.angle=Gt(p,u),f.vector1.distance=.5*z.findLength(p,u),t.segments.length>3){var g=e[4],v={x:.5*(u.x+g.x),y:.5*(u.y+g.y)};f.vector2.angle=Gt(v,u),f.vector2.distance=.5*z.findLength(v,u),f.point=v;var y=t.segments[3];y.vector1.angle=Gt(v,g),y.vector1.distance=.5*z.findLength(v,g),y.vector2.angle=Gt(o,g),y.vector2.distance=.5*z.findLength(o,g)}else f.vector2.angle=Gt(o,u),f.vector2.distance=.5*z.findLength(o,u)}else d.vector2.angle=Gt(o,l),d.vector2.distance=.5*z.findLength(o,l)}},n.prototype.rotateObjects=function(t,e,i,r,s){r=r||{};var o=Hi();qi(o,i,r.x,r.y);for(var l=0,h=e;l0){this.diagram.protectPropertyChange(!0);var o=t;o.segments=[],this.diagram.connectorPropertyChange(o,{},{segments:o.segments}),this.diagram.protectPropertyChange(!1)}}},n.prototype.updateInnerParentProperties=function(t){var r=this.diagram.isProtectedOnChange;this.diagram.protectPropertyChange(!0);for(var s=this.getAllDescendants(t,[],!1,!0),o=0;o0&&(p=this.diagram.bpmnModule.getChildrenBound(d,d.id,this.diagram),u=d.wrapper.bounds.containsRect(p)),h=d.wrapper.actualSize.width*t,c=d.wrapper.actualSize.height*e,void 0!==d.maxWidth&&0!==d.maxWidth&&(h=Math.min(d.maxWidth,h)),void 0!==d.minWidth&&0!==d.minWidth&&(h=Math.max(d.minWidth,h)),void 0!==d.maxHeight&&0!==d.maxHeight&&(c=Math.min(d.maxHeight,c)),void 0!==d.minHeight&&0!==d.minHeight&&(c=Math.max(d.minHeight,c)),u&&(h=Math.max(h,p.right-d.wrapper.bounds.x),c=Math.max(c,p.bottom-d.wrapper.bounds.y)),t=h/d.actualSize.width,e=c/d.actualSize.height}var f=Hi();o||(o=r);var g=o.wrapper;if(qi(f,-g.rotateAngle,i.x,i.y),Wp(f,t,e,i.x,i.y),qi(f,g.rotateAngle,i.x,i.y),r instanceof te){var d,v=Je(f,{x:(d=r).wrapper.offsetX,y:d.wrapper.offsetY}),y=d.wrapper.offsetX-d.wrapper.actualSize.width*d.pivot.x,S=d.wrapper.offsetY-d.wrapper.actualSize.height*d.pivot.y;if(h>0)if(d.processId){var b=this.diagram.nameTable[d.processId];(!b.maxWidth||d.margin.left+h0)if(d.processId){var M=this.diagram.nameTable[d.processId];(!M.maxHeight||d.margin.top+c0){if(e.dragLimit=e.dragLimit?e.dragLimit:{},e.dragLimit.top||e.dragLimit.bottom||e.dragLimit.left||e.dragLimit.right){var b={minDistance:null};S=this.getRelativeOffset(v,d,b);var M={minDistance:null};g=this.getRelativeOffset(v,y,M),S=null!=b&&M.minDistance0){if(S=y[y.length-1]){var b=void 0;for(b=0;b=e.x-t.dragLimit.left-r.width/2&&i.x<=e.x+t.dragLimit.right+r.width/2&&(s=!0),i.y>=e.y-t.dragLimit.top-r.height/2&&i.y<=e.y+t.dragLimit.bottom+r.height/2&&(o=!0),{x:s,y:o}},n.prototype.updateLabelMargin=function(t,e,i,r,s,o,a){if(i=i||{x:e.offset,y:0},e&&i&&i.x>0&&i.x<1){var l=z.getLengthFromListOfPoints(t.intermediatePoints),h=this.getPointAtLength(l*i.x,t.intermediatePoints,0),c=this.diagram.scrollSettings.currentZoom,d=e.dragLimit?e.dragLimit:{left:0,right:0,top:0,bottom:0};if(d.top||d.bottom||d.left||d.right){this.diagram.getWrapper(t.wrapper,e.id);var p=new Ne(0,0,0,0),f=this.diagram.getWrapper(t.wrapper,e.id);p.x=f.offsetX/c+o,p.y=f.offsetY/c+a,p.width=f.bounds.width/c,p.height=f.bounds.height/c;var g=new Ne(h.x-(d.left||0)-p.width/2,h.y-(d.top||0)-p.height/2,(d.left||0)+(d.right||0)+p.width,(d.top||0)+(d.bottom||0)+p.height);if(g.containsPoint(r));else for(var S=0,b=this.boundsInterSects([h,r],g,!1);S=t){c=t-r,d=z.findAngle(s,a),u=c*Math.cos(d*Math.PI/180),p=c*Math.sin(d*Math.PI/180),o={x:s.x+u,y:s.y+p};break}r+=h,s=a}else s=a;return o},n.prototype.getInterceptWithSegment=function(t,e){for(var o,a,i=[],r=[],s=[],l=z.findLength({x:0,y:0},{x:this.diagram.scroller.viewPortWidth,y:this.diagram.scroller.viewPortHeight}),h=1;h0&&a<=90||a>180&&a<=270?90:-90;r.push(z.transform(t,a+c,l)),r.push(z.transform(t,o+c,l));var p=Jv({x1:s[0].x,y1:s[0].y,x2:s[1].x,y2:s[1].y},{x1:r[0].x,y1:r[0].y,x2:r[1].x,y2:r[1].y});p.enabled&&i.push(p.intersectPt)}return i},n.prototype.getAnnotationChanges=function(t,e){var r={};return r[KI(t,e.id,!0)]={width:e.width,height:e.height,offset:t instanceof te?{x:e.offset.x,y:e.offset.y}:e.offset,rotateAngle:e.rotateAngle,margin:{left:e.margin.left,right:e.margin.right,top:e.margin.top,bottom:e.margin.bottom},horizontalAlignment:e.horizontalAlignment,verticalAlignment:e.verticalAlignment,alignment:t instanceof de?e.alignment:void 0},{annotations:r}},n.prototype.getConnectorPortChanges=function(t,e){var i=function Nse(n,t,e){for(var i=n.ports,r=0;r1&&(v.width=g,v.offset.x=1/S),f>1&&(v.height=f,v.offset.y=1/b)}}e instanceof Nr&&(e.alignment="Center"),l=this.getAnnotationChanges(t,e),t instanceof te?this.diagram.nodePropertyChange(t,a,l):this.diagram.connectorPropertyChange(t,a,l),this.diagram.updateDiagramObject(t)},n.prototype.getSubProcess=function(t){var i,e={nodes:[],connectors:[]};return t instanceof te?i=t.processId:t&&t.nodes&&t.nodes.length&&t.nodes[0].processId&&(i=t.nodes[0].processId),i&&e.nodes.push($(this.diagram.nameTable[i])),e},n.prototype.checkBoundaryConstraints=function(t,e,i,r){var s=this.diagram.pageSettings,o=this.diagram.pageSettings.boundaryConstraints,a=this.diagram.scroller;if("Page"===o||"Diagram"===o){var l=i?void 0:this.diagram.selectedItems.wrapper.bounds;return!!((i?i.right:l.right)+(t||0)<=("Page"===o?s.width:a.viewPortWidth)&&(i?i.left:l.left)+(t||0)>=0&&(i?i.bottom:l.bottom)+(e||0)<=("Page"===o?s.height:a.viewPortHeight)&&(i?i.top:l.top)+(e||0)>=0||"None"!==this.diagram.layout.type&&r)}return!0},n.prototype.dragSelectedObjects=function(t,e){var i=this,r=this.diagram.selectedItems;this.state&&!this.state.backup&&(this.state.backup={},this.state.backup.offsetX=r.offsetX,this.state.backup.offsetY=r.offsetY),r=FI(this.diagram,r)||r;var s=this.diagram.selectedItems.nodes.filter(function(c){return"SwimLane"===c.shape.type});if(s.length>0&&!this.diagram.currentSymbol&&this.diagram.selectedItems.nodes.length>1){var o=this.diagram.selectedItems.nodes.filter(function(c){return""===c.parentId||"SwimLane"!==i.diagram.nameTable[c.parentId].shape.type});if(o.length>0){for(var a=0;a0||l.length>1)&&(o=o.concat(l),this.diagram.selectedItems.nodes.splice(0,this.diagram.selectedItems.nodes.length),o.forEach(function(c){i.diagram.selectedItems.nodes.push(c)}),r=this.diagram.selectedItems,this.diagram.selectedObject.helperObject=void 0)}}if(this.checkBoundaryConstraints(t,e)){this.diagram.diagramActions=this.diagram.diagramActions|ee.PreventZIndexOnDragging|ee.DragUsingMouse;var h=this.diagram.selectedObject.actualObject;return(h&&h instanceof te&&h.isLane&&jx(h,this.diagram)||!h||!h.isLane)&&this.diagram.drag(r,t,e),this.diagram.diagramActions=this.diagram.diagramActions&~(ee.PreventZIndexOnDragging|ee.DragUsingMouse),this.diagram.refreshCanvasLayers(),this.checkHtmlObjectDrag(r),!0}return!1},n.prototype.checkHtmlObjectDrag=function(t){var e=!1;this.diagram.views&&this.diagram.views.length>1&&(t instanceof si?e=t.nodes.some(function(i){return i.shape&&"HTML"===i.shape.type}):t.shape&&"HTML"===t.shape.type&&(e=!0),e&&this.resetOverviewCanvas())},n.prototype.resetOverviewCanvas=function(){for(var t=0,e=this.diagram.views;t0&&(this.layoutAnimateModule.stopCurrentAnimation(this.objectStore[0],e,t),this.objectStore=[]),a=this.diagram.doLayout(),this.objectStore.push(a)),this.canUpdateTemplate=!1,this.diagram.blazorActions&=~on.expandNode,this.diagram.preventNodesUpdate=r,this.diagram.layoutAnimateModule&&this.diagram.organizationalChartModule&&!i)this.diagram.allowServerDataBinding=!1,this.layoutAnimateModule.expand(this.diagram.layout.enableAnimation,a,t,this.diagram);else{var l={element:$(t),state:!!t.isExpanded};this.triggerEvent(Ce.expandStateChange,l),this.diagram.lineRoutingModule&&this.diagram.constraints&rt.LineRouting&&"ComplexHierarchicalTree"!==this.diagram.layout.type&&this.diagram.resetSegments()}return this.diagram.layout.fixedNode=""===o?"":this.diagram.layout.fixedNode,a},n.prototype.getparentexpand=function(t,e,i,r){for(var s,o=0;o0&&(this.diagram.selectedItems.wrapper.rotateAngle=this.diagram.selectedItems.rotateAngle=s.rotateAngle),r instanceof te&&"SwimLane"!==r.shape.type&&!r.isLane&&!r.isPhase&&!r.isHeader)(r.offsetX!==r.wrapper.offsetX||r.offsetY!==r.wrapper.offsetY||r.width!==r.wrapper.width||r.height!==r.wrapper.height||r.rotateAngle!==r.wrapper.rotateAngle)&&(r.offsetX+=o,r.offsetY+=a,r.width+=l,r.height+=h,r.rotateAngle+=c,this.diagram.nodePropertyChange(r,{},{offsetX:r.offsetX,offsetY:r.offsetY,width:r.width,height:r.height,rotateAngle:r.rotateAngle})),e=this.diagram.spatialSearch.findObjects(r.wrapper.outerBounds);else if(r instanceof si)for(var d=0;d30||g.wrapper.outerBounds.topCenter.y-f.wrapper.outerBounds.bottomCenter.y>30)&&this.diagram.lineRoutingModule.refreshConnectorSegments(this.diagram,p,!0)}}this.updateSelector(),this.diagram.protectPropertyChange(!1)}},n.prototype.drawSelectionRectangle=function(t,e,i,r){this.diagram.drawSelectionRectangle(t,e,i,r)},n.prototype.startGroupAction=function(){this.diagram.startGroupAction()},n.prototype.endGroupAction=function(){this.diagram.endGroupAction()},n.prototype.removeChildFromBPmn=function(t,e,i){var r=this.diagram.nameTable[t.id]||t.nodes[0];if(i&&r&&r.processId&&r.processId===i.wrapper.id){var s=$(r);s.processId=r.processId,this.diagram.startGroupAction();var o=this.diagram.nameTable[r.processId].shape.activity.subProcess.processes||[];o.splice(o.indexOf(r.id),1),this.diagram.bpmnModule.removeChildFromBPMN(this.diagram.nameTable[r.processId].wrapper,r.id,this.diagram),this.diagram.nameTable[r.id].processId="",r.offsetX=r.wrapper.offsetX,r.offsetY=r.wrapper.offsetY;var a=$(r);this.addHistoryEntry({type:"PositionChanged",redoObject:{nodes:[a]},undoObject:{nodes:[s]},category:"Internal"}),this.diagram.endGroupAction()}},n.prototype.isDroppable=function(t,e){var i=this.diagram.nameTable[t.id]||t.nodes[0];return i instanceof te&&(!ce()&&"TextAnnotation"===i.shape.shape||("Group"===e.shape.shape&&(e.shape.activity.subProcess.collapsed=!1),!(i&&"Bpmn"===i.shape.type&&(i.processId===e.id||i.id===e.processId||"Bpmn"===e.shape.type&&!(e instanceof de)&&e.shape.activity&&e.shape.activity.subProcess&&e.shape.activity.subProcess.collapsed))))},n.prototype.renderHighlighter=function(t,e,i){if(new Ne,t.target instanceof te||t.target instanceof de||e&&(t.source instanceof te||t.source instanceof de)){var a=this.findTarget(e?t.sourceWrapper:t.targetWrapper,e?t.source:t.target,i,!0),l=void 0;if(a instanceof zd)for(var h=a.id,c=t.target,u=0,p=c.wrapper.children[0].children[0].children[2].children;u0){var r=0;t[0]=this.diagram.nameTable[t[0].id]||t[0];var s="Object"===i?yr(t[0].wrapper):this.diagram.selectedItems.wrapper.bounds,o={nodes:[],connectors:[]},a={nodes:[],connectors:[]};for(r="Object"===i?r+1:r;r0){var i=0,r=0,s=0,o=0,a=0,l=0,h=0,c=0,d={nodes:[],connectors:[]},u={nodes:[],connectors:[]};for(i=0;io.center.y&&(r=n[parseInt(e.toString(),10)],n[parseInt(e.toString(),10)]=n[parseInt(i.toString(),10)],n[parseInt(i.toString(),10)]=r):s.center.x>o.center.x&&(r=n[parseInt(e.toString(),10)],n[parseInt(e.toString(),10)]=n[parseInt(i.toString(),10)],n[parseInt(i.toString(),10)]=r)}}return n}(t,e),i=1;i0){var i=0,r={x:.5,y:.5};t[0]=this.diagram.nameTable[t[0].id]||t[0];var s=yr(t[0].wrapper),o={nodes:[],connectors:[]},a={nodes:[],connectors:[]};for(i=1;ii.zIndex){for(var s=this.diagram.layers.indexOf(this.diagram.getActiveLayer()),o=this.diagram.layers[parseInt(s.toString(),10)].zIndexTable,a=JSON.parse(JSON.stringify(o)),l=i.zIndex,h=r.zIndex,c=h;c>=l;c--)l!==c?o[c-1]?(o[parseInt(c.toString(),10)]=o[c-1],this.diagram.nameTable[o[parseInt(c.toString(),10)]].zIndex=c):(o[c-1]=o[parseInt(c.toString(),10)],this.diagram.nameTable[o[c-1]].zIndex=c,delete o[parseInt(c.toString(),10)]):this.swapZIndexObjects(h,o,r.id,a);"SVG"===this.diagram.mode?(this.moveSvgNode(e.parentId,i.id),this.updateNativeNodeIndex(e.parentId,i.id)):this.diagram.refreshCanvasLayers()}},n.prototype.findLeastIndexConnector=function(t,e,i){for(var r=0;rs.zIndex&&(i=s)}return i},n.prototype.findLeastIndexObject=function(t,e){var i=t;return t instanceof te&&(i=this.findLeastIndexConnector(t.inEdges,e,i),i=this.findLeastIndexConnector(t.outEdges,e,i)),i},n.prototype.checkSelection=function(t,e){var i;if(1===t.nodes.length&&0===t.connectors.length)if(cs(this.diagram,t.nodes[0],!0)){var r=t.nodes[0];if("SwimLane"===(i="SwimLane"===t.nodes[0].shape?t.nodes[0]:this.diagram.nameTable[t.nodes[0].parentId]).shape.type){var s="Horizontal"===i.shape.orientation;(r.isPhase&&(s&&"ResizeSouth"===e||!s&&"ResizeEast"===e)||r.isLane&&(s&&"ResizeEast"===e||!s&&"ResizeSouth"===e))&&R3(this.diagram,i,e)}else if("Grid"===i.container.type)if("Horizontal"===i.container.orientation&&1===r.rowIndex||"Vertical"===i.container.orientation&&r.rowIndex>0&&r.columnIndex>0){if("ResizeSouth"===e)for(var o=0;o1&&(this.diagram.realActions=this.diagram.realActions|$i.hScrollbarMoved,this.scrolled=!0),this.diagram.scrollSettings.horizontalOffset=t},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"verticalOffset",{get:function(){return this.vOffset},set:function(t){this.vOffset=t,Math.abs(this.vOffset-this.diagram.scrollSettings.verticalOffset)>1&&(this.diagram.realActions=this.diagram.realActions|$i.vScrollbarMoved,this.scrolled=!0),this.diagram.scrollSettings.verticalOffset=t},enumerable:!0,configurable:!0}),n.prototype.getBounds=function(){var e=this.diagram.spatialSearch.getPageBounds(0,0);return(e.x<0||e.y<0)&&!this.diagram.pageSettings.multiplePage?this.getPageBounds(void 0,void 0,!0,!0):this.getPageBounds(void 0,void 0,!0)},n.prototype.updateScrollOffsets=function(t,e){var i,r,s=this.getBounds();s.x*=this.currentZoom,s.y*=this.currentZoom,s.width*=this.currentZoom,s.height*=this.currentZoom,i=Math.max(0,t-s.left),r=Math.max(0,e-s.top),void 0!==t&&void 0!==e?(this.horizontalOffset=i,this.verticalOffset=r,this.diagram.setOffset(i,r)):this.diagram.setOffset(-this.horizontalOffset-s.x,-this.verticalOffset-s.y),this.transform={tx:Math.max(this.horizontalOffset,-s.left)/this.currentZoom,ty:Math.max(this.verticalOffset,-s.top)/this.currentZoom,scale:this.currentZoom}},n.prototype.setScrollOffset=function(t,e){this.scrolled=!1;var i=this.getBounds();i.x*=this.currentZoom,i.y*=this.currentZoom,i.width*=this.currentZoom,i.height*=this.currentZoom;var r=-i.left,s=-i.top,o=!1,a=this.viewPortWidth*this.currentZoom,l=this.viewPortHeight*this.currentZoom,h=r-t;if(h!==this.horizontalOffset){rh?this.horizontalOffset-=t:this.horizontalOffset=h,o=!0);var c=Math.max(i.right+this.vScrollSize,a);if(!o&&c<-h+this.viewPortWidth){var d=-h+a-this.vScrollSize,u=-this.horizontalOffset+a-this.vScrollSize;this.horizontalOffset=dd-u?h:-(i.right+this.vScrollSize-a),o=!0}o||(this.horizontalOffset=r-t)}o=!1;var p=s-e;if(p!==this.verticalOffset){sp?this.verticalOffset-=e:this.verticalOffset=p,o=!0);var f=Math.max(i.bottom+this.hScrollSize,l);if(!o&&f<-p+l){var g=-p+l-this.hScrollSize,v=-this.verticalOffset+l-this.hScrollSize;this.verticalOffset=gg-v?p:-(i.bottom+this.hScrollSize-l),o=!0}o||(this.verticalOffset=s-e)}this.transform={tx:Math.max(this.horizontalOffset,-i.left)/this.currentZoom,ty:Math.max(this.verticalOffset,-i.top)/this.currentZoom,scale:this.currentZoom},this.setSize()},n.prototype.getObjects=function(t,e){for(var i=[],r=0;r0){for(var l=0;l0){h.push(i[parseInt(o.toString(),10)].id);for(var d=0;d=e.bottom&&(l=0),-this.horizontalOffset<=e.x&&-this.horizontalOffset+this.viewPortWidth>=e.right&&(a=0),this.hScrollSize=a,this.vScrollSize=l;var h=this.diagramWidth,c=this.diagramHeight;this.diagramWidth=Math.max(e.right,-this.horizontalOffset+this.viewPortWidth-l)-i,this.diagramHeight=Math.max(e.bottom,-this.verticalOffset+this.viewPortHeight-a)-r,(h!==this.diagramWidth||c!==this.diagramHeight)&&"Diagram"!==this.diagram.scrollSettings.scrollLimit&&this.diagram.setSize(this.diagramWidth,this.diagramHeight),"Diagram"===this.diagram.scrollSettings.scrollLimit&&(h===this.diagramWidth&&c===this.diagramHeight&&1===this.currentZoom||this.diagram.diagramActions&&t&&(!this.diagram.diagramActions||!t||0===this.verticalOffset&&this.verticalOffset!==t.y||0===this.horizontalOffset&&this.horizontalOffset!==t.x)?t&&h===this.diagramWidth&&c===this.diagramHeight&&(this.diagram.diagramCanvas.scrollHeight>this.viewPortHeight&&t.y<0&&this.horizontalOffset===t.x&&0===this.verticalOffset||this.diagram.diagramCanvas.scrollWidth>this.viewPortWidth&&t.x<0&&this.verticalOffset===t.y&&0===this.horizontalOffset)&&(this.verticalOffset=t.y,this.horizontalOffset=t.x,this.transform={tx:Math.max(t.x,-e.left)/this.currentZoom,ty:Math.max(t.y,-e.top)/this.currentZoom,scale:this.currentZoom}):(this.diagram.scrollActions&ca.Interaction&&t&&(this.transform={tx:Math.max(t.x,-e.left/this.currentZoom)/this.currentZoom,ty:Math.max(t.y,-e.top/this.currentZoom)/this.currentZoom,scale:this.currentZoom},this.horizontalOffset=t.x,this.verticalOffset=t.y),this.diagram.setSize(this.diagramWidth,this.diagramHeight),!(this.diagram.scrollActions&ca.PropertyChange)&&t&&(this.horizontalOffset=t.x,this.verticalOffset=t.y,this.transform={tx:Math.max(t.x,-e.left)/this.currentZoom,ty:Math.max(t.y,-e.top)/this.currentZoom,scale:this.currentZoom}))),this.diagram.transformLayers(),this.diagram.element.style.overflow="hidden"},n.prototype.setViewPortSize=function(t,e){this.viewPortWidth=t,this.viewPortHeight=e},n.prototype.getPageBounds=function(t,e,i,r){var o,s=new Ne;if("Content"===e||r||null===this.diagram.pageSettings.width||null===this.diagram.pageSettings.height){var u=t?void 0:0;o=this.diagram.spatialSearch.getPageBounds(u,u)}else{var a=this.diagram.pageSettings.width,l=this.diagram.pageSettings.height,h=0,c=0;if(this.diagram.pageSettings.multiplePage){if((s=this.diagram.spatialSearch.getPageBounds(0,0)).right>a&&(a*=d=Math.ceil(s.right/a)),s.bottom>l&&(l*=d=Math.ceil(s.bottom/l)),s.left<0&&Math.abs(s.left)>h){var d=Math.ceil(Math.abs(s.left)/this.diagram.pageSettings.width);h=this.diagram.pageSettings.width*d}s.top<0&&Math.abs(s.top)>c&&(d=Math.ceil(Math.abs(s.top)/this.diagram.pageSettings.height),c=this.diagram.pageSettings.height*d)}o=new Ne(-h,-c,a+h,l+c)}if(i){var p=this.diagram.scrollSettings.padding;o.x-=p.left,o.y-=p.top,o.width+=p.left+p.right,o.height+=p.top+p.bottom}return o},n.prototype.getPageBreak=function(t){for(var e=0,i=0,r=-1,s=[],c=this.diagram.pageSettings.margin.left,d=this.diagram.pageSettings.margin.right,u=this.diagram.pageSettings.margin.top,p=this.diagram.pageSettings.margin.bottom,f=1,g=1;t.width>e;)(e+=this.diagram.pageSettings.width?this.diagram.pageSettings.width:t.width)===this.diagram.pageSettings.width&&(s[++r]={x1:t.left+c,y1:t.top+u,x2:t.left+c,y2:t.bottom-p}),ei;)(i+=this.diagram.pageSettings.height?this.diagram.pageSettings.height:t.height)===this.diagram.pageSettings.height&&(s[++r]={x1:t.left+c,y1:t.top+u,x2:t.right-d,y2:t.top+u}),i=this.diagram.scrollSettings.minZoom||l||t>=1)){this.currentZoom*=t;var c=this.getPageBounds(void 0,void 0,!0);c.x*=this.currentZoom,c.y*=this.currentZoom;var d=Hi();Wp(d,t,t,r.x,r.y),qB(d,e||0,i||0),mx(h,d);var u=Je(h,{x:0,y:0});if(1===t&&(u=this.applyScrollLimit(u.x,u.y,s,o,a)),a=-c.y>=u.y&&-c.x>=u.x&&a,(this.diagram.scrollActions&ca.PropertyChange||!(this.diagram.scrollActions&ca.Interaction)||"Diagram"!==this.diagram.scrollSettings.scrollLimit||a)&&(this.transform={tx:Math.max(u.x,-c.left)/this.currentZoom,ty:Math.max(u.y,-c.top)/this.currentZoom,scale:this.currentZoom},this.horizontalOffset=u.x,this.verticalOffset=u.y),this.setSize(u),"SVG"!==this.diagram.mode&&Ds(this.diagram)&&this.diagram.scroller.virtualizeElements(),"SVG"!==this.diagram.mode&&!Ds(this.diagram)&&this.diagram.refreshDiagramLayer(),this.diagram.setOffset(-this.horizontalOffset-c.x,-this.verticalOffset-c.y),QI(this.diagram),this.diagram.views&&this.diagram.views.overview){var p=this.diagram.views.overview,f=p.scrollOverviewRect(p.parent.scroller.horizontalOffset,p.parent.scroller.verticalOffset,p.parent.scroller.currentZoom,!0);p.updateOverviewrect(-f.x,-f.y,f.width,f.height),p.updateView(p)}}}},n.prototype.fitToPage=function(t){var e=(t=t||{}).mode,i=t.region,r=t.margin||{},s=t.canZoomIn,o=t.customBounds,a=t.canZoomOut;r.bottom=r.bottom||25,r.top=r.top||25,r.left=r.left||25,r.right=r.right||25;var h,l=o,c=-this.horizontalOffset,d=-this.verticalOffset;if("PageSettings"===(i=i||"PageSettings")&&this.diagram.pageSettings.width&&this.diagram.pageSettings.height||this.diagram.nodes.length>0||this.diagram.connectors.length>0){e=e||"Page","CustomBounds"!==i&&(l=this.getPageBounds(!0,i,!0));var u={x:0,y:0};r.left+r.right>this.viewPortWidth&&(this.viewPortWidth<=100?(r.left=5,r.right=5):(r.left=25,r.right=25)),r.top+r.bottom>this.viewPortHeight&&(this.viewPortHeight<=100?(r.top=5,r.bottom=5):(r.top=25,r.bottom=25)),u.x=(this.viewPortWidth-(r.left+r.right))/l.width,u.y=(this.viewPortHeight-(r.top+r.bottom))/l.height,!s&&l.width-this.horizontalOffset-a+this.viewPortWidth&&(i=o.right-this.viewPortWidth,i+=20),o.x<-a&&(i=o.x),o.bottom>-l+this.viewPortHeight&&(r=o.bottom-this.viewPortHeight,r+=20),o.y<-l&&(r=o.y),this.zoom(1,-this.horizontalOffset-i,-this.verticalOffset-r,null,void 0,e))},n.prototype.bringToCenter=function(t){var e=this.currentZoom,i=new Ne(t.x*e,t.y*e,t.width*e,t.height*e),r=i.x+i.width/2-this.viewPortWidth/2,s=i.y+i.height/2-this.viewPortHeight/2;this.zoom(1,-this.horizontalOffset-(r*=-1),-this.verticalOffset-(s*=-1),null)},n.prototype.applyScrollLimit=function(t,e,i,r,s){if("Infinity"===this.diagram.scrollSettings.scrollLimit&&void 0===i&&!r&&(t=-t,e=-e),"Infinity"!==this.diagram.scrollSettings.scrollLimit){var o=void 0;if("Limited"===this.diagram.scrollSettings.scrollLimit){var a=this.diagram.scrollSettings.scrollableArea;o=new Ne(a.x,a.y,a.width,a.height)}(o=o||(s?this.getPageBounds():this.getPageBounds(!0))).x*=this.currentZoom,o.y*=this.currentZoom,o.width*=this.currentZoom,o.height*=this.currentZoom,void 0!==i&&(t*=-1,e*=-1),r&&(t*=-1,e*=-1);var l=Math.max(o.right,this.viewPortWidth);if(!r&&!(t<=o.x&&(t+this.viewPortWidth>=o.right||t>=o.right-this.viewPortWidth)||t>=o.x&&t+this.viewPortWidth<=l))if(t>=o.x)t=Math.max(o.x,Math.min(t,t-(t+this.viewPortWidth-this.vScrollSize-l)));else{var h=o.right-this.viewPortWidth;t=Math.min(h,o.x)}var c=Math.max(o.bottom,this.viewPortHeight);r||e<=o.y&&e+this.viewPortHeight>=o.bottom||e>=o.y&&e+this.viewPortHeight<=c||(e>=o.y?e=Math.max(o.y,Math.min(e,e-(e+this.viewPortHeight-this.hScrollSize-c))):(h=o.bottom-this.viewPortHeight,e=Math.min(o.y,h))),t*=-1,e*=-1}return{x:t,y:e}},n}(),joe=function(){function n(t,e,i,r,s){this.objects=[],this.left=t,this.top=e,this.width=i,this.height=r,this.spatialSearch=s}return n.prototype.findQuads=function(t,e){null!=this.first&&this.first.isIntersect(t)&&this.first.findQuads(t,e),null!=this.second&&this.second.isIntersect(t)&&this.second.findQuads(t,e),null!=this.third&&this.third.isIntersect(t)&&this.third.findQuads(t,e),null!=this.fourth&&this.fourth.isIntersect(t)&&this.fourth.findQuads(t,e),this.objects.length>0&&e.push(this)},n.prototype.isIntersect=function(t){return!(this.left+this.widtht.right||this.top>t.bottom)},n.prototype.selectQuad=function(){for(var i,t=null,e=this;null!=e;)i=e.getQuad(t),e=i.source,t=i.target||t;return t},n.prototype.getQuad=function(t){var e=this.width/2,i=this.height/2;if(e>=1e3&&i>=1e3){var r=this.left+e,s=this.top+i;if(this.spatialSearch.childRight<=r){if(this.spatialSearch.childBottom<=s)return this.first||((o=new n(this.left,this.top,e,i,this.spatialSearch)).parent=this,this.first=o),{source:this.first};if(this.spatialSearch.childTop>=s)return this.third||((o=new n(this.left,s,e,i,this.spatialSearch)).parent=this,this.third=o),{source:this.third}}else if(this.spatialSearch.childLeft>=r){if(this.spatialSearch.childBottom<=s)return this.second||((o=new n(r,this.top,e,i,this.spatialSearch)).parent=this,this.second=o),{source:this.second};var o;if(this.spatialSearch.childTop>=s)return this.fourth||((o=new n(r,s,e,i,this.spatialSearch)).parent=this,this.fourth=o),{source:this.fourth}}}return this.objects.push(this.spatialSearch.childNode),{target:this}},n.prototype.isContained=function(){return this.spatialSearch.childLeft>=this.left&&this.spatialSearch.childRight<=this.left+this.width&&this.spatialSearch.childTop>=this.top&&this.spatialSearch.childBottom<=this.top+this.height},n.prototype.addIntoAQuad=function(t){var e={};this.spatialSearch.setCurrentNode(t);for(var i=null;!e.isAdded;)i=(e=this.spatialSearch.parentQuad.add(i)).quad;return i},n.prototype.add=function(t){if(t=null,this.isContained())return{isAdded:!0,quad:t=this.selectQuad()};var e=void 0,i=!(0!==this.objects.length||this.first||this.second||this.third||this.fourth),r=2*this.width,s=2*this.height;return this.spatialSearch.childLeft=this.childLeft?(this.pageLeft=this.childLeft,this.leftElement=t,r=!0):t===this.leftElement&&(this.pageLeft=Number.MAX_VALUE,this.findLeft(this.parentQuad),r=!0)),(this.pageTop!==this.childTop||t!==this.topElement)&&(this.pageTop>=this.childTop?(this.pageTop=this.childTop,this.topElement=t,r=!0):t===this.topElement&&(this.pageTop=Number.MAX_VALUE,this.findTop(this.parentQuad),r=!0)),(this.pageBottom!==this.childBottom||t!==this.bottomElement)&&(this.pageBottom<=this.childBottom?(r=!0,this.pageBottom=this.childBottom,this.bottomElement=t):t===this.bottomElement&&(this.pageBottom=-Number.MAX_VALUE,this.findBottom(this.parentQuad),r=!0)),(this.pageRight!==this.childRight||t!==this.rightElement)&&(this.pageRight<=this.childRight?(this.pageRight=this.childRight,this.rightElement=t,r=!0):t===this.rightElement&&(this.pageRight=-Number.MAX_VALUE,this.findRight(this.parentQuad),r=!0)),r}return this.setCurrentNode(null),!1},n.prototype.isWithinPageBounds=function(t){return t.left>=this.pageLeft&&t.right<=this.pageRight&&t.top>=this.pageTop&&t.bottom<=this.pageBottom},n.prototype.findQuads=function(t){var e=[];return this.parentQuad.findQuads(t,e),e},n.prototype.findObjects=function(t){for(var i=[],r=0,s=this.findQuads(t);r=r.outerBounds.left&&(this.pageLeft=r.outerBounds.left,this.leftElement=r)}},n.prototype.findTop=function(t){t.first||t.second?(t.first&&this.findTop(t.first),t.second&&this.findTop(t.second)):(t.third&&this.findTop(t.third),t.fourth&&this.findTop(t.fourth));for(var e=0,i=t.objects;e=r.outerBounds.top&&(this.pageTop=r.outerBounds.top,this.topElement=r)}},n.prototype.setCurrentNode=function(t){if(this.childNode=t,t){var e=t.outerBounds;this.childLeft=Number(e.left),this.childTop=Number(e.top),this.childRight=Number(e.right),this.childBottom=Number(e.bottom)}else this.childLeft=Number.MAX_VALUE,this.childTop=Number.MAX_VALUE,this.childRight=-Number.MAX_VALUE,this.childBottom=-Number.MAX_VALUE},n.prototype.getPageBounds=function(t,e){if(this.pageLeft===Number.MAX_VALUE)return new Ne(0,0,0,0);var i=void 0!==t?Math.min(this.pageLeft,0):this.pageLeft,r=void 0!==e?Math.min(this.pageTop,0):this.pageTop;return new Ne(Math.round(i),Math.round(r),Math.round(this.pageRight-i),Math.round(this.pageBottom-r))},n.prototype.getQuad=function(t){return this.quadTable[t.id]},n}(),Voe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Yoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Voe(t,n),function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);r>3&&s&&Object.defineProperty(t,e,s)}([I(!1)],t.prototype,"preventDefaults",void 0),t}(Ee),Qoe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),JF=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Goe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qoe(t,n),JF([I("")],t.prototype,"action",void 0),JF([I("")],t.prototype,"cursor",void 0),t}(Ee),KF=function(){function n(){this.size=20,this.intermediatePoints=[],this.gridCollection=[],this.startArray=[],this.targetGridCollection=[],this.sourceGridCollection=[],this.considerWalkable=[]}return n.prototype.lineRouting=function(t){var e=t.connectors.length;if(this.renderVirtualRegion(t),e>0)for(var i=0;i=t.right||e.right<=t.left||e.top>=t.bottom||e.bottom<=t.top)},n.prototype.findEndPoint=function(t,e,i){var r,s;if(e&&""!==t.sourcePortID&&t.sourcePortWrapper||!e&&""!==t.targetPortID&&t.targetPortWrapper){s=zo(r=e?{x:t.sourcePortWrapper.offsetX,y:t.sourcePortWrapper.offsetY}:{x:t.targetPortWrapper.offsetX,y:t.targetPortWrapper.offsetY},void 0,e?t.sourceWrapper.bounds:t.targetWrapper.bounds);var o=e?t.sourcePortWrapper.bounds:t.targetPortWrapper.bounds;r=i?"Top"===s?{x:o.topCenter.x,y:o.topCenter.y}:"Left"===s?{x:o.middleLeft.x,y:o.middleLeft.y}:"Right"===s?{x:o.middleRight.x,y:o.middleRight.y}:{x:o.bottomCenter.x,y:o.bottomCenter.y}:{x:o.center.x,y:o.center.y}}else r=e&&this.startNode||!e&&this.targetNode?e?{x:this.startNode.wrapper.offsetX,y:this.startNode.wrapper.offsetY}:{x:this.targetNode.wrapper.offsetX,y:this.targetNode.wrapper.offsetY}:e?{x:t.sourcePoint.x,y:t.sourcePoint.y}:{x:t.targetPoint.x,y:t.targetPoint.y};return r},n.prototype.refreshConnectorSegments=function(t,e,i,r){var h,c,p,f,g,y,S,b,M,w,C,s=e.sourceID,o=e.targetID,a=e.sourcePortID,l=e.targetPortID;if(function Fre(n,t){var e=0;return n.constraints&qe.LineRouting?e=n.constraints&qe.LineRouting:n.constraints&qe.InheritLineRouting&&(e=t.constraints&rt.LineRouting),e}(e,t)||r){this.startNode=t.nameTable[""+s],this.targetNode=t.nameTable[""+o],this.intermediatePoints=[],this.startArray=[],this.targetGridCollection=[],this.sourceGridCollection=[],this.startGrid=void 0,this.targetGrid=void 0;for(var D=0;D0;){var L=this.startArray.pop();if(L){for(D=0;D1&&(e.segments=[]),this.updateConnectorSegments(t,this.intermediatePoints,this.gridCollection,e,i)){this.considerWalkable=[];break e}this.targetGridCollection.splice(this.targetGridCollection.indexOf(O),1),L=this.startArray.pop()}}L&&this.findPath(L)}}}},n.prototype.checkChildNodes=function(t,e){var i=!1,r=!1;if(t.nodeId.length>=1&&!e)for(var s=0;s1&&this.targetGridCollection[0].nodeId.length>1)for(var c=0;c<=1;c++){for(var d=this.targetGridCollection[parseInt(c.toString(),10)].gridX,u=this.targetGridCollection[parseInt(c.toString(),10)].gridY,p=this.targetGridCollection[parseInt(c.toString(),10)].nodeId,f=void 0,g=0;g=e.right&&t.top<=e.top&&t.bottom>=e.bottom},n.prototype.getEndvalue=function(t,e){return this.gridCollection[t.gridX][t.gridY].walkable?t:"left"===e?this.getEndvalue(this.gridCollection[t.gridX-1][t.gridY],e):"right"===e?this.getEndvalue(this.gridCollection[t.gridX+1][t.gridY],e):"top"===e?this.getEndvalue(this.gridCollection[t.gridX][t.gridY-1],e):"bottom"===e?this.getEndvalue(this.gridCollection[t.gridX][t.gridY+1],e):t},n.prototype.changeValue=function(t,e,i){t.walkable||this.considerWalkable.push(t);for(var r,s=0;s<=e;s++)"left"===i?r=this.gridCollection[t.gridX-s][t.gridY]:"right"===i?r=this.gridCollection[t.gridX+s][t.gridY]:"top"===i?r=this.gridCollection[t.gridX][t.gridY-s]:"bottom"===i&&(r=this.gridCollection[t.gridX][t.gridY+s]),r.walkable||this.considerWalkable.push(r)},n.prototype.getIntermediatePoints=function(t){var e;for(this.intermediatePoints=[];t;)this.intermediatePoints.push({x:t.gridX,y:t.gridY}),t=t.parent;this.intermediatePoints.reverse(),this.intermediatePoints.length>=1&&void 0!==this.intermediatePoints[0]&&void 0!==this.intermediatePoints[1]&&(this.intermediatePoints[0].x===this.intermediatePoints[1].x?this.intermediatePoints[0].y=1&&u.length>1&&(g=u[u.length-2].x!==u[u.length-1].x?u[u.length-2].x>u[u.length-1].x?"Left":"Right":u[u.length-2].y>u[u.length-1].y?"Top":"Bottom"),M>=2&&v===g&&u.length>1&&u.splice(u.length-2,1),v=g);if(u&&u.length>1){for(var w=0;wD.x?S.bounds.middleLeft:S.bounds.middleRight),w===u.length-2&&""===r.targetPortID&&y&&(l=C.x>D.x?y.bounds.middleRight:y.bounds.middleLeft),0===w&&b&&(C.x=b.x,C.y=D.y=b.y),w===u.length-2&&l&&(w>0&&r.targetDecorator&&l.x-D.x<0&&Math.abs(l.x-C.x)0&&r.targetDecorator&&l.x-D.x>0&&Math.abs(l.x-C.x)D.y?S.bounds.topCenter:S.bounds.bottomCenter),w===u.length-2&&""===r.targetPortID&&y&&(l=C.y>D.y?y.bounds.bottomCenter:y.bounds.topCenter),0===w&&b&&(C.y=b.y,C.x=D.x=b.x),w===u.length-2&&l&&(w>0&&r.targetDecorator&&l.y-D.y<0&&Math.abs(l.y-C.y)0&&r.targetDecorator&&l.y-D.y>0&&Math.abs(l.y-C.y)D.x?(p="Left",f=C.x-D.x):(p="Right",f=D.x-C.x):C.y>D.y?(p="Top",f=C.y-D.y):(p="Bottom",f=D.y-C.y),o.push({type:"Orthogonal",length:f,direction:p})}}if(o&&o.length>0){var A=o[o.length-1];if(1===o.length&&(A.length-=20),A.length<10&&2===o.length&&(o.pop(),o.length>0&&(o[0].length-=20,A=o[0])),r.targetDecorator&&("Top"===A.direction||"Bottom"===A.direction)&&A.length>r.targetDecorator.height+1||("Right"===A.direction||"Left"===A.direction)&&A.length>r.targetDecorator.width+1)return r.segments=o,s&&t.connectorPropertyChange(r,{},{type:"Orthogonal",segments:o}),!0}return!1},n.prototype.findPath=function(t){for(var e,i=[],r=this.findNearestNeigbours(t,this.gridCollection,!0),s=0;sl)&&(e.x!==t.gridX||e.y!==t.gridY)&&(i.push(e),o.previousDistance=l,o.afterDistance=o.afterDistance||this.manhattan(Math.abs(e.x-this.targetGrid.gridX),Math.abs(e.y-this.targetGrid.gridY)),o.totalDistance=o.previousDistance+o.afterDistance,o.parent=t)}if(i.length>0)for(s=0;st?i*t+e:i*e+t},n.prototype.manhattan=function(t,e){return t+e},n.prototype.findNearestNeigbours=function(t,e,i){var r=[],s=t.parent;if(s){var o=(t.gridX-s.gridX)/Math.max(Math.abs(t.gridX-s.gridX),1),a=(t.gridY-s.gridY)/Math.max(Math.abs(t.gridY-s.gridY),1);0!==o?(this.isWalkable(t.gridX,t.gridY-1,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX][t.gridY-1])&&r.push(e[t.gridX][t.gridY-1]),this.isWalkable(t.gridX,t.gridY+1,!0)&&this.sourceGridCollection.indexOf(e[t.gridX][t.gridY+1])&&r.push(e[t.gridX][t.gridY+1]),this.isWalkable(t.gridX+o,t.gridY,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX+o][t.gridY])&&r.push(e[t.gridX+o][t.gridY])):0!==a&&(this.isWalkable(t.gridX-1,t.gridY,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX-1][t.gridY])&&r.push(e[t.gridX-1][t.gridY]),this.isWalkable(t.gridX+1,t.gridY,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX+1][t.gridY])&&r.push(e[t.gridX+1][t.gridY]),this.isWalkable(t.gridX,t.gridY+a,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX][t.gridY+a])&&r.push(e[t.gridX][t.gridY+a]))}else this.neigbour(t,"top",r,i),this.neigbour(t,"right",r,i),this.neigbour(t,"bottom",r,i),this.neigbour(t,"left",r,i);return r},n.prototype.neigbour=function(t,e,i,r){for(var o,s=1;s>0;){var a="top"===e||"bottom"===e?t.gridX:"left"===e?t.gridX-s:t.gridX+s,l="right"===e||"left"===e?t.gridY:"top"===e?t.gridY-s:t.gridY+s;if((o=this.gridCollection[parseInt(a.toString(),10)][parseInt(l.toString(),10)])&&(r&&-1===this.sourceGridCollection.indexOf(o)||!r&&-1===this.targetGridCollection.indexOf(o)))return i&&this.isWalkable(a,l)&&i.push(o),s;if(!(a>0&&l>0))break;s++}return null},n.prototype.resetGridColl=function(t,e,i){for(var s,r=1;r>0;){var o="top"===e||"bottom"===e?t.gridX:"left"===e?t.gridX-r:t.gridX+r,a="right"===e||"left"===e?t.gridY:"top"===e?t.gridY-r:t.gridY+r;if((s=this.gridCollection[parseInt(o.toString(),10)][parseInt(a.toString(),10)])&&(i&&-1===this.sourceGridCollection.indexOf(s)||!i&&-1===this.targetGridCollection.indexOf(s))){if(this.isWalkable(o,a))break;var l=this.gridCollection[parseInt(o.toString(),10)][parseInt(a.toString(),10)];this.considerWalkable.push(l)}if(!(o>0&&a>0))break;"top"===e||"left"===e?r--:r++}return null},n.prototype.isWalkable=function(t,e,i){if(t>=0&&t=0&&e0?1:-1,this.isWalkable(h,c-1)&&!this.isWalkable(h-a,c-1)||this.isWalkable(h,c+1)&&!this.isWalkable(h-a,c+1)))return{x:t,y:e};if(0!==l){if(l=l>0?1:-1,this.isWalkable(h-1,c)&&!this.isWalkable(h-1,c-l)||this.isWalkable(h+1,c)&&!this.isWalkable(h+1,c-l))return{x:t,y:e};if(this.findIntermediatePoints(h+1,c,h,c,s,o)||this.findIntermediatePoints(h-1,c,h,c,s,o))return{x:t,y:e}}return this.findIntermediatePoints(h+a,c+l,h,c,s,o)},n.prototype.destroy=function(){},n.prototype.getModuleName=function(){return"LineRouting"},n}(),Xoe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),$oe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Xoe(t,n),function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);r>3&&s&&Object.defineProperty(t,e,s)}([I(!0)],t.prototype,"inversedAlignment",void 0),t}(Ee),Zoe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Oe=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},wT=function(n,t,e,i){return new(e||(e=Promise))(function(r,s){function o(h){try{l(i.next(h))}catch(c){s(c)}}function a(h){try{l(i.throw(h))}catch(c){s(c)}}function l(h){h.done?r(h.value):new e(function(c){c(h.value)}).then(o,a)}l((i=i.apply(n,t||[])).next())})},CT=function(n,t){var i,r,s,o,e={label:0,sent:function(){if(1&s[0])throw s[1];return s[1]},trys:[],ops:[]};return o={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function a(h){return function(c){return function l(h){if(i)throw new TypeError("Generator is already executing.");for(;e;)try{if(i=1,r&&(s=2&h[0]?r.return:h[0]?r.throw||((s=r.return)&&s.call(r),0):r.next)&&!(s=s.call(r,h[1])).done)return s;switch(r=0,s&&(h=[2&h[0],s.value]),h[0]){case 0:case 1:s=h;break;case 4:return e.label++,{value:h[1],done:!1};case 5:e.label++,r=h[1],h=[0];continue;case 7:h=e.ops.pop(),e.trys.pop();continue;default:if(!(s=(s=e.trys).length>0&&s[s.length-1])&&(6===h[0]||2===h[0])){e=0;continue}if(3===h[0]&&(!s||h[1]>s[0]&&h[1]0&&((!s.style||!s.style.fill)&&(o.style.fill="transparent"),(!s.style||!s.style.strokeColor)&&(o.style.strokeColor="transparent")),s.shape&&"UmlActivity"===s.shape.type&&qI(s,o),s.shape&&"SwimLane"===s.shape.type&&sF(s,o),r.nodeDefaults&&Ro(o,s,r.nodeDefaults),r.updateAnnotationText(o.annotations);if(e&&e.connectors)for(a=0;e&&e.connectors&&a0&&0===i.nodes.length)this.clearCollection(),a=!0;else{for(var g=0,v=Object.keys(e.nodes);g0&&0===i.connectors.length)this.clearCollection(!0),a=!0;else{for(var C=0,D=Object.keys(e.connectors);C0){this.renderSelector(!0);break}if(e.selectedItems.constraints){this.renderSelector(!0);break}break;case"snapSettings":this.updateSnapSettings(e);break;case"commandManager":this.initCommands();break;case"layout":o=!0;break;case"segmentThumbShape":this.updateSelector();break;case"dataSourceSettings":this.clear(),"None"===this.layout.type?a=!0:(this.initObjects(),o=!0);break;case"tooltip":e3(this);break;case"rulerSettings":this.updateRulerSettings(e);break;case"layers":this.updateLayer(e);break;case"scrollSettings":this.scrollActions|=ca.PropertyChange,this.updateScrollSettings(e),this.scrollActions&=~ca.PropertyChange,this.scrollSettings.horizontalOffset=-this.scroller.horizontalOffset||0,this.scrollSettings.verticalOffset=-this.scroller.verticalOffset||0;break;case"locale":e.locale!==i.locale&&(this.realActions|=$i.PreventDataInit,n.prototype.refresh.call(this),this.realActions&=~$i.PreventDataInit);break;case"contextMenuSettings":if(void 0!==e.contextMenuSettings.showCustomMenuOnly&&(this.contextMenuSettings.showCustomMenuOnly=e.contextMenuSettings.showCustomMenuOnly),void 0!==e.contextMenuSettings.show&&(this.contextMenuSettings.show=e.contextMenuSettings.show),e.contextMenuSettings.items){for(var A=e.contextMenuSettings.items,x=0,R=Object.keys(A);x0){for(var N=[],T=O.ports.length-1;T>=0;T--)"LineDistribution"===O.ports[parseInt(T.toString(),10)].id.split("_")[1]&&N.push(O.ports[parseInt(T.toString(),10)]);this.removePorts(O,N)}}for(T=0;T0)for(var ue=0,pe=Object.keys(e.nodes);ue0)for(var De=0,xe=Object.keys(e.connectors);De=0;o--)this.commandHandler.expandNode(r[parseInt(o.toString(),10)],this,0!==o);this.canLayout&&this.doLayout(),this.lineRoutingModule?this.connectors.sourceID!==this.connectors.targetID&&this.lineRoutingModule.lineRouting(this):this.constraints&rt.LineRouting&&console.warn('[WARNING] :: Module "LineRouting" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),this.validatePageSize(),this.renderPageBreaks(),this.diagramRenderer.renderSvgGridlines(this.snapSettings,Bd(this.element.id),this.scroller.transform,this.rulerSettings,this.hRuler,this.vRuler),this.commandHandler.initSelectorWrapper(),this.notify("initial-load",{}),this.trigger("load"),this.scroller.setSize(),this.scroller.updateScrollOffsets(),this.isRefreshed||this.refreshDiagramLayer(),(this.scrollSettings.verticalOffset>0||this.scrollSettings.horizontalOffset>0)&&this.updateScrollOffset(),X.isDevice&&(this.tool=Ci.ZoomPan|Ci.SingleSelect),this.notify("initial-end",{}),this.isProtectedOnChange=!1,this.tooltipObject=e3(this),this.diagramActions=ee.Render,this.initCommands();var a=document.getElementsByClassName(this.element.id+"_hiddenUserHandleTemplate");(function yoe(n,t,e,i){var r,s,o,a,l,d=document.getElementById(i).ej2_instances[0];if(n&&t){r=FF(n);for(var u=0,p=e.userHandles;u0;)e[0].parentNode.removeChild(e[0]);var i=document.getElementById(this.element.id+"content");i&&this.element.removeChild(i);var r="measureElement";if(window[""+r]){window[""+r].usageCount-=1;var s="measureElementCount";window[""+s]--,0===window[""+s]&&(window[""+r].parentNode.removeChild(window[""+r]),window[""+r]=null)}}window.domTable={};for(var a=0;a1&&(this.callBlazorModel=!1,this.insertBlazorDiagramObjects(this.selectedItems),this.commandHandler.group(),this.callBlazorModel=!0,this.commandHandler.getBlazorOldValues())},t.prototype.unGroup=function(){this.callBlazorModel=!1,this.insertBlazorDiagramObjects(this.selectedItems),this.commandHandler.unGroup(),this.callBlazorModel=!0,this.commandHandler.getBlazorOldValues()},t.prototype.sendToBack=function(){this.commandHandler.sendToBack()},t.prototype.setActiveLayer=function(e){var i=this.commandHandler.getLayer(e);this.activeLayer=i},t.prototype.addLayer=function(e,i){this.commandHandler.addLayer(e,i)},t.prototype.removeLayer=function(e){this.commandHandler.removeLayer(e,ce())},t.prototype.moveObjects=function(e,i){$(this.layers),this.enableServerDataBinding(!1),this.commandHandler.moveObjects(e,i)},t.prototype.layerObjectUpdate=function(){},t.prototype.sendLayerBackward=function(e){this.layerObjectUpdate(),this.commandHandler.sendLayerBackward(e)},t.prototype.bringLayerForward=function(e){this.layerObjectUpdate(),this.commandHandler.bringLayerForward(e)},t.prototype.cloneLayer=function(e){this.commandHandler.cloneLayer(e)},t.prototype.bringToFront=function(){this.commandHandler.bringToFront()},t.prototype.moveForward=function(){this.commandHandler.sendForward()},t.prototype.sendBackward=function(){this.commandHandler.sendBackward()},t.prototype.getObject=function(e){return this.nameTable[""+e]},t.prototype.getNodeObject=function(e){return $(this.nameTable[""+e])},t.prototype.getConnectorObject=function(e){return $(this.nameTable[""+e])},t.prototype.getActiveLayer=function(){return this.activeLayer},t.prototype.nudgeCommand=function(e,i,r){if("object"!=typeof e&&(this.selectedItems.nodes.length||this.selectedItems.connectors.length)>0){var s=void 0;i.type&&"KEYDOWN"===i.type&&(s=i.type),this.nudge(e,void 0,void 0,s)}},t.prototype.nudge=function(e,i,r,s){var o=0,a=0;"Left"===e||"Right"===e?o=("Left"===e?-1:1)*(i||1):a=("Up"===e?-1:1)*(r||1),"KEYDOWN"===s&&(o*=5,a*=5);var h=this.selectedItems,c=this.selectedItems.wrapper.children[0];if(c instanceof ni)this.commandHandler.labelDrag(h.nodes[0],c,o,a);else{var d=$(this.selectedItems);this.protectPropertyChange(!0),this.drag(h,o,a),this.protectPropertyChange(!1);var u={type:"PositionChanged",redoObject:$(this.selectedItems),undoObject:d,category:"Internal"};this.addHistoryEntry(u)}this.refreshCanvasLayers()},t.prototype.insertBlazorDiagramObjects=function(e){},t.prototype.drag=function(e,i,r){if(this.insertBlazorDiagramObjects(e),!(this.bpmnModule&&e instanceof te&&this.bpmnModule.updateAnnotationDrag(e,this,i,r))){if(e instanceof si){if(this.preventConnectorsUpdate=!0,e.nodes&&e.nodes.length){for(var o=0,a=e.nodes;o0&&o.nodes[0].children){this.fromUndo||(this.rotateUsingButton=!0);for(var h=this.commandHandler.getAllDescendants(o.nodes[0],[]),c=0;c0&&o.nodes[0].children){var g={type:"RotationChanged",redoObject:$(e),undoObject:$(o),category:"Internal",childTable:a};this.commandHandler.addHistoryEntry(g),this.commandHandler.updateSelector()}return u},t.prototype.dragSourceEnd=function(e,i,r){this.insertBlazorDiagramObjects(e),this.commandHandler.dragSourceEnd(e,i,r),this.callBlazorModel&&this.commandHandler.getBlazorOldValues()},t.prototype.dragTargetEnd=function(e,i,r){this.insertBlazorDiagramObjects(e),this.commandHandler.dragTargetEnd(e,i,r),this.callBlazorModel&&this.commandHandler.getBlazorOldValues()},t.prototype.findObjectsUnderMouse=function(e,i){return this.eventHandler.findObjectsUnderMouse(e,i)},t.prototype.findObjectUnderMouse=function(e,i,r){return this.eventHandler.findObjectUnderMouse(e,i,r)},t.prototype.findTargetObjectUnderMouse=function(e,i,r,s,o){return this.eventHandler.findTargetUnderMouse(e,i,r,s,o)},t.prototype.findElementUnderMouse=function(e,i,r,s){return this.eventHandler.findElementUnderMouse(e,i,r,s)},t.prototype.findActionToBeDone=function(e,i,r,s){return this.eventHandler.findActionToBeDone(e,i,r,s)},t.prototype.updateConnectorPort=function(e){if(e.ports.length)for(var i=void 0,r=0,s=e.ports;r=0;s--)if(i.push(r[parseInt(s.toString(),10)]),i.length>this.historyManager.stackLimit)return i}else i=r;return i},t.prototype.getEdges=function(e){return e.outEdge?this.nameTable[e.id].outEdges:this.nameTable[e.id].inEdges},t.prototype.getParentId=function(e){return this.nameTable[""+e].parentId},t.prototype.addConnector=function(e){return this.add(e)},t.prototype.UpdateBlazorDiagramModelCollection=function(e,i,r,s){},t.prototype.UpdateBlazorDiagramModel=function(e,i,r,s){},t.prototype.UpdateBlazorLabelOrPortObjects=function(e,i,r,s){},t.prototype.addBlazorDiagramObjects=function(){},t.prototype.removeNodeEdges=function(e,i,r){var s=this.nameTable[""+e],o=r?s.outEdges:s.inEdges;if(o.length>0)for(var a=0;a0)){for(var c=0;c0))}this.removePortEdges(l,a.element.sourcePortID,a.element.id,h)}a.element.targetID&&this.removeNodeEdges(a.element.targetID,a.element.id,!1)}}this.diagramActions=this.diagramActions|ee.PublicMethod,e.id=e.id||Qe();var u=this.activeLayer;if(!a.cancel&&u&&!u.lock){if(u.objects.indexOf(e.id)<0&&!u.lock&&(u.visible||(u.visible=!0,this.dataBind()),u.objects.push(e.id)),fs(e)===de)(r=new de(this,"connectors",e,!0)).status="New",this.nameTable[r.targetID]&&"TextAnnotation"===this.nameTable[r.targetID].shape.shape&&(r.isBpmnAnnotationConnector=!0,r.constraints=r.constraints&~qe.Delete),Ro(r,e,this.connectorDefaults),this.connectors.push(r),this.initObject(r),!1===e.visible&&this.updateElementVisibility(r.wrapper,r,e.visible),this.updateEdges(r),this.insertBlazorConnector(r);else{if(Ro(r=new te(this,"nodes",e,!0),e,this.nodeDefaults),r.parentId=e.parentId?e.parentId:r.parentId,r.umlIndex=e.umlIndex,r.status="New",(o="TextAnnotation"===r.shape.shape)&&!e.isTextAnnotationCopied&&(r.inEdges=e.inEdges?e.inEdges:r.inEdges),this.nodes.push(r),this.initObject(r,u,void 0,i),o&&this.bpmnModule)for(c=0;c-1&&e.parentId&&this.nameTable[e.parentId]&&"UmlClassifier"===this.nameTable[e.parentId].shape.type){var g=this.nameTable[e.parentId];g.children.splice(r.umlIndex,0,r.id),g.wrapper.children.splice(r.umlIndex,0,r.wrapper),g.wrapper.measure(new me),g.wrapper.arrange(g.wrapper.desiredSize),this.updateDiagramObject(g)}}if(a={element:r,cause:this.diagramActions,diagramAction:this.getDiagramAction(this.diagramActions),state:"Changed",type:"Addition",cancel:!1},this.parentObject&&(a.parentId=this.parentObject.id),"helper"!==e.id&&!(this.diagramActions&ee.PreventCollectionChangeOnDragOver)&&this.triggerEvent(Ce.collectionChange,a),!(this.diagramActions&ee.UndoRedo||this.diagramActions&ee.Group||this.diagramActions&ee.PreventHistory)){var v={type:"CollectionChanged",changeType:"Insert",undoObject:$(e),redoObject:$(e),category:"Internal"};this.addHistoryEntry(v)}this.parentObject=void 0,"SVG"===this.mode&&(this.updateSvgNodes(r),this.updateTextElementValue(r),this.updateDiagramObject(r),o&&this.updateDiagramObject(this.nameTable[r.inEdges[0]]),r.shape.activity&&r.shape.activity.subProcess.processes&&r.shape.activity.subProcess.processes.length&&this.updateProcesses(r),this.updateBridging())}}if(this.protectPropertyChange(s),this.resetDiagramActions(ee.PublicMethod),r&&this.layers.length>1&&this.moveNode(r),this.views)for(var S=0,b=this.views;S=0;l--)this.moveSvgNode(a[parseInt(l.toString(),10)])}for(var h=0,c=i;h=0;o--)r[parseInt(o.toString(),10)]===e.id&&r.splice(o,1);for(var a=0;s.ports&&a=0;s--)if(i=this.nameTable[r[parseInt(s.toString(),10)]])if(this.connectorTable[i.id]=$(i),i.isBpmnAnnotationConnector){var o=this.nameTable[i.targetID];this.removeObjectsFromLayer(i);var a=this.connectors.indexOf(i);-1!==a&&this.connectors.splice(a,1),this.removeElements(i),this.removeFromAQuad(i),delete this.nameTable[i.id];var l=this.nameTable[i.sourceID];if(l){var h=l.outEdges.indexOf(i.id);-1!==h&&l.outEdges.splice(h,1)}e.id!==i.targetID&&this.remove(o)}else this.remove(i)},t.prototype.removeObjectsFromLayer=function(e){if(e.children)for(var i=0;i-1&&(_r(this,e)&&this.unSelect(e),this.layers[parseInt(s.toString(),10)].objects.splice(a,1),delete this.layers[parseInt(s.toString(),10)].zIndexTable[this.nameTable[e.id].zIndex])},t.prototype.removeElements=function(e){if("SVG"===this.mode||"Canvas"===this.mode&&"Native"===e.shape.type){var i=xt(e.id+"_groupElement",this.element.id),r=e;if(r.ports&&r.ports.length>0)for(var s=0;s0){l[parseInt(s.toString(),10)].id.indexOf("icon_content")>0&&"SVG"===this.mode&&((h=xt(l[parseInt(s.toString(),10)].id+"_shape_groupElement",this.element.id))&&h.parentNode.removeChild(h),(h=xt(l[parseInt(s.toString(),10)].id+"_rect_groupElement",this.element.id))&&h.parentNode.removeChild(h));for(var c=0,d=this.views;c=0;o--)a.children[parseInt(o.toString(),10)].children&&(l=n.nameTable[a.children[parseInt(o.toString(),10)].id])&&(l.isLane?Gv(n,l):(n.removeDependentConnector(l),n.diagramActions|=ee.PreventHistory,l.constraints&ie.Delete?n.remove(l):U3(n,l,{},!1),n.diagramActions&=~ee.PreventHistory));a&&(i=n.nameTable[a.id])&&Gv(n,i)}}(this,e),!(this.diagramActions&ee.UndoRedo||this.diagramActions&ee.PreventHistory)&&(e instanceof te||e instanceof de)){var o={type:"CollectionChanged",changeType:"Remove",undoObject:$(e),redoObject:$(e),category:"Internal"};this.diagramActions&ee.Clear||e.children&&!e.isLane&&!e.isPhase&&e.children.length>0&&this.undoRedoModule&&"None"===this.layout.type&&(this.historyManager.startGroupAction(),s=!0),(e instanceof te||e instanceof de)&&this.deleteDependentConnector&&this.removeDependentConnector(e),!e.isLane&&!e.isPhase&&!(this.diagramActions&ee.Clear)&&!this.isStackChild(e)&&this.addHistoryEntry(o)}"TextAnnotation"===e.shape.shape&&this.removeDependentConnector(e),e.children&&!e.isLane&&!e.isPhase&&(!(this.diagramActions&ee.UndoRedo)||!ce())&&this.deleteGroup(e),e.parentId&&(this.deleteChild(e,void 0,!0),this.nameTable[e.parentId]&&"UmlClassifier"===this.nameTable[e.parentId].shape.type&&(this.updateDiagramObject(this.nameTable[e.parentId]),this.updateConnectorEdges(this.nameTable[e.parentId])));var a=void 0;this.diagramActions=this.diagramActions|ee.PublicMethod;var l=this.nameTable[e.id];if(l instanceof te?("Bpmn"===l.shape.type&&this.bpmnModule&&this.bpmnModule.removeBpmnProcesses(l,this),(l.isLane||l.isPhase||"SwimLane"===l.shape.type)&&(h=l.isLane||l.isPhase?this.nameTable[l.parentId]:this.nameTable[l.id],l.isLane?B3(this,l,h):l.isPhase&&F3(this,l,h)),-1!==(a=this.nodes.indexOf(l))&&(this.crudDeleteNodes.push(this.nameTable[l.id]),this.nodes.splice(a,1),this.updateNodeEdges(l))):(-1!==(a=this.connectors.indexOf(l))&&(this.crudDeleteNodes.push(this.nameTable[l.id]),this.connectors.splice(a,1)),this.updateEdges(l),this.spliceConnectorEdges(e,!0),this.spliceConnectorEdges(e,!1)),!this.isServerUpdate&&!(this.blazorActions&on.GroupClipboardInProcess)&&this.commandHandler.getBlazorOldValues(),s&&this.historyManager.endGroupAction(),_r(this,l)&&this.unSelect(l),!l.isPhase){if(this.removeObjectsFromLayer(e),this.currentDrawingObject&&(this.currentDrawingObject.wrapper=void 0),delete this.nameTable[e.id],i.length>0&&i[0].id===l.id&&l.parentId){var h,d=this.nameTable[l.parentId];d&&d.isLane&&"SwimLane"===this.nameTable[d.parentId].shape.type&&H3(this,h=this.nameTable[d.parentId],d,l)}this.removeElements(l),this.updateBridging(),"SVG"!==this.mode&&this.refreshDiagramLayer(),this.diagramActions&ee.Clear||(this.removeFromAQuad(l),r={element:e,cause:this.diagramActions,diagramAction:this.getDiagramAction(this.diagramActions),state:"Changed",type:"Removal",cancel:!1},"helper"!==e.id&&this.triggerEvent(Ce.collectionChange,r),this.resetTool())}}}else if(i.length>0){this.undoRedoModule&&(this.historyManager.startGroupAction(),this.blazorActions|=on.GroupingInProgress,s=!0);for(var u=0;u=f.wrapper.bounds.width&&"Horizontal"===f.shape.orientation||this.selectedItems.wrapper.bounds.y<=f.wrapper.bounds.y+g&&this.selectedItems.wrapper.bounds.height>=f.wrapper.bounds.height-g&&"Vertical"===f.shape.orientation)&&(CI(f)||f.shape.lanes.length>1)&&this.remove(i[parseInt(u.toString(),10)])}}else this.remove(i[parseInt(u.toString(),10)])}s&&(this.blazorActions&=~on.GroupingInProgress,this.isServerUpdate=!0,this.commandHandler.getBlazorOldValues(),this.UpdateBlazorDiagramModelCollection(void 0,void 0,void 0,!0),this.historyManager.endGroupAction(),this.isServerUpdate=!1),this.clearSelection()}e&&(CI(e)||this.diagramActions&ee.Clear)||this.diagramActions&ee.UndoRedo||this.diagramActions&ee.PreventHistory||!(e instanceof te||e instanceof de)||(o={type:"ConnectionChanged",undoObject:$(e),redoObject:$(e),category:"Internal"},!e.isLane&&!e.isPhase&&!(this.diagramActions&ee.Clear)&&!this.isStackChild(e)&&this.addHistoryEntry(o)),this.tooltipObject.close()},t.prototype.isStackChild=function(e){var i,r=this.nameTable[e.parentId];if(e&&e.parentId&&r.container&&"Stack"===r.container.type&&"UmlClassifier"!==this.nameTable[e.parentId].shape.type){i=!0;var s={sourceIndex:r.wrapper.children.indexOf(e.wrapper),source:e,target:void 0,targetIndex:void 0};this.diagramActions&ee.UndoRedo||this.addHistoryEntry({type:"StackChildPositionChanged",redoObject:{sourceIndex:void 0,source:e,target:void 0,targetIndex:void 0},undoObject:s,category:"Internal"})}return i},t.prototype.deleteChild=function(e,i,r){var s;if(s="string"==typeof e?e:e.id,(i=i?this.nameTable[i.id]:this.nameTable[e.parentId])&&i.children){for(var o=0;o=0;i--)this.removeLayer(this.layers[parseInt(i.toString(),10)].id);this.commandHandler.addLayer({id:"default_layer",visible:!0,lock:!1,objects:[],zIndex:0,objectZIndex:-1,zIndexTable:{}},null,!0),this.setActiveLayer(this.layers[this.layers.length-1].id)},t.prototype.clearObjects=function(e){var i=[];i=e||(i=i.concat(this.nodes)).concat(this.connectors),this.diagramActions=this.diagramActions|ee.Clear;for(var r=0,s=i;r0||"Text"===e.shape.type))if("Text"===e.shape.type)i=e.wrapper.children[0].id.split("_")[1];else for(var f=e.annotations.length-1;f>=0;f--)e.annotations[parseInt(f.toString(),10)].visibility&&(i=e.annotations[parseInt(f.toString(),10)].id);i&&(u=this.getWrapper(e.wrapper,i))}if(e&&u&&!(u instanceof Jn)&&(!function Qre(n,t){return"Text"===t.shape.type?t.constraints&ie.ReadOnly:t.constraints&(t instanceof de?qe.ReadOnly:ie.ReadOnly)?n.constraints&Lr.InheritReadOnly?1:0:n.constraints&Lr.ReadOnly?1:0}(u,e)||p)){var g=u.style,v=void 0;v=90>(v=u.bounds.width50?50:e.width,u.style.fontSize)),e.parentId&&"UmlClassifier"===this.nameTable[e.parentId].shape.type?(l.width=e.wrapper.bounds.width-20,c=(e.wrapper.bounds.center.x+r.tx)*r.scale-l.width/2*s-2.5,d=(e.wrapper.bounds.center.y+r.ty)*r.scale-l.height/2*s-3,u.style.textAlign="Left"):(l.width=Math.max(l.width,50),c=(u.bounds.center.x+r.tx)*r.scale-l.width/2*s-2.5,d=(u.bounds.center.y+r.ty)*r.scale-l.height/2*s-3),Ho(y,{id:this.element.id+"_editTextBoxDiv",style:"position: absolute;left:"+c+"px;top:"+d+"px;width:"+(l.width+1)*s+"px;height:"+l.height*s+"px; containerName:"+e.id+";"}),Ho(S,{"aria-label":a,id:this.element.id+"_editBox",style:"width:"+(l.width+1)*s+"px;height:"+l.height*s+"px;resize: none;outline: none;overflow: hidden;;font-family:"+g.fontFamily+";font-size:"+g.fontSize*s+"px;text-align:"+u.style.textAlign.toLocaleLowerCase()+";",class:"e-diagram-text-edit"}),S.style.fontWeight=g.bold?"bold":"",S.style.fontStyle=g.italic?"italic":"",S.style.lineHeight=(1.2*g.fontSize+"px;").toString(),S.style.textDecoration=g.textDecoration?g.textDecoration:"",this.activeLabel.parentId=e.id,this.activeLabel.id=i,u.visible=!1,this.updateDiagramObject(e),this.diagramActions=this.diagramActions|ee.TextEdit,this.isTriggerEvent||(E.add(S,"input",this.eventHandler.inputChange,this.eventHandler),E.add(S,"focusout",this.focusOutEdit,this),S.select())}}}},t.prototype.updateConnectorfixedUserHandles=function(e){if(e.fixedUserHandles.length)for(var i=void 0,r=0,s=e.fixedUserHandles;r0&&this.mindMapChartModule.updateLayout(o,this.nameTable,this.layout,l,this.dataSourceSettings.id,this.dataSourceSettings.root),e=!0;else if(this.radialTreeModule)this.radialTreeModule.updateLayout(o,this.nameTable,this.layout,l),e=!0;else if(this.symmetricalLayoutModule)this.symmetricalLayoutModule.maxIteration=this.layout.maxIteration,this.symmetricalLayoutModule.springLength=this.layout.springLength,this.symmetricalLayoutModule.springFactor=this.layout.springFactor,this.symmetricalLayoutModule.updateLayout(o,this.connectors,this.symmetricalLayoutModule,this.nameTable,this.layout,l),e=!0;else if(this.complexHierarchicalTreeModule){this.canDistribute(a,r)&&(this.lineDistributionModule.diagram=this,this.connectors.forEach(function(R){R.obstaclePointCollection=[]}));var c=this.complexHierarchicalTreeModule.getLayoutNodesCollection(this.nodes);c.length>0&&this.complexHierarchicalTreeModule.doLayout(c,this.nameTable,this.layout,l,this),e=!0,this.canDistribute(a,r)&&this.lineDistributionModule.initLineDistribution(this.layout,this)}else this.flowchartLayoutModule?(this.flowchartLayoutModule.updateLayout(this.nodes,this),e=!0):console.warn("[WARNING] :: Module "+("OrganizationalChart"===this.layout.type?"HierarchicalTree":this.layout.type)+" is not available in Diagram component! You either misspelled the module name or forgot to load it.");if(e){this.preventDiagramUpdate=!0;for(var u={},f=0,g=o;f0)for(var S=0;S0)for(var M=0;M0)for(var s=0,o=r.ports;s0&&function wse(n){var t,e,i,r=[];for(t=0;t0&&y.connectors[w].bezierSettings&&y.connectors[w].bezierSettings.allowSegmentsReset&&(y.connectors[w].segments=[]);if(t.connectors=y.connectors||[],t.dataSourceSettings=y.dataSourceSettings||{},t.dataSourceSettings.doBinding=i,t.height=y.height||"100%",t.setNodeTemplate=r,t.getConnectorDefaults=v,t.getNodeDefaults=g,t.getCustomProperty=o,t.mode=y.mode||"SVG",y.nodes)for(w=0;w0)){var r=this.nodes.filter(function(a){return 0===a.inEdges.length})[0],s=this.convertMindmapToMermaid(r,0);i.push(s),this.updateTextDataSource(i,r.outEdges,1),e=(i=i.filter(function(a){return""!==a.trim()})).join("\n")}return e},t.prototype.updateTextDataSource=function(e,i,r){for(var s=0;s0&&this.updateTextDataSource(e,h,r+1),s++}},t.prototype.convertMindmapToMermaid=function(e,i){var r=e.id,o=" ".repeat(2*(i+1)),a=e.annotations.length>0?e.annotations[0].content.replace(/\n/g," "):"",l=o+a,h=o+r;if(e.shape&&"Basic"===e.shape.type){var c=e.shape;"Rectangle"===c.shape?l=h+"["+a+"]":"Ellipse"===c.shape?l=h+"(("+a+"))":"Hexagon"===c.shape&&(l=h+"{{"+a+"}}")}else if(e.shape&&"Flow"===e.shape.type)"Terminator"===e.shape.shape&&(l=h+"("+a+")");else if(e.shape&&"Path"===e.shape.type){var u=e.shape;u.data===this.bangShape?l=h+"))"+a+"((":u.data===this.cloudShape&&(l=h+")"+a+"(")}return l},t.prototype.saveFlowDiagramInMermaidFormat=function(){var e=this,i=[],r="graph TD\n",s={nodes:this.nodes,edges:this.connectors};return s.nodes.reduce(function(a,l){return a[l.id]=l.annotations.length?l.annotations[0].content:"",a},{}),s.edges.forEach(function(a){var l=a.sourceID,h=a.targetID,p=e.nameTable[""+h],f=e.getNodeShape(e.nameTable[""+l]),g=e.getNodeShape(p),v=a.annotations[0]&&""!==a.annotations[0].content?"|"+a.annotations[0].content+"|":"";-1===i.indexOf(l)?i.push(l):f="",-1===i.indexOf(h)?i.push(h):g="";var y=e.arrowType(a);r+=" "+l+f+" "+y+v+" "+h+g+"\n"}),s.nodes.forEach(function(a){r+=" style "+a.id+" fill:"+a.style.fill+",stroke:"+a.style.strokeColor+",stroke-width:"+a.style.strokeWidth+"px;\n"}),r},t.prototype.arrowType=function(e){var i=e.targetDecorator.shape;return e.style.opacity<1?"~~~":""!==e.style.strokeDashArray?"-.->":"Arrow"===i?e.style.strokeWidth>1?"==>":"--\x3e":"None"===i?"---":"--\x3e"},t.prototype.getNodeShape=function(e){var i=e.annotations.length>0?e.annotations[0].content:"",r=e.shape.shape;if(!r){var s=e.shape.data;return"M 0 0 A 1 1 0 0 0 7 0 A 1 1 0 0 0 0 0 M -1 0 A 1 1 0 0 0 8 0 A 1 1 0 0 0 -1 0"===s?"((("+i+")))":"M 0 0 L 1 -1 L 5 -1 L 6 0 L 0 0"===s?"[/"+i+"\\]":"M 0 1 L 0 6 C 2 7 4 7 6 6 L 6 1 C 5 0 1 0 0 1 C 1 2 5 2 6 1"===s?"[("+i+")]":"M 0 0 L 12 0 L 14 2 L 2 2 L 0 0"===s?"[\\"+i+"\\]":"M 0 0 L 5 0 L 4 1 L 1 1 L 0 0"===s?"[\\"+i+"/]":"M 0 0 L 2 -2 L 11 -2 L 13 0 L 11 2 L 2 2 L 0 0"===s?"{{"+i+"}}":">"+i+"]"}switch(r){case"Terminator":return"(["+i+"])";case"Process":default:return"["+i+"]";case"Decision":return"{"+i+"}";case"Parallelogram":return"[/"+i+"/]";case"Ellipse":return"(("+i+"))";case"PreDefinedProcess":return"[["+i+"]]"}},t.prototype.loadDiagramFromMermaid=function(e){this.layout&&"Flowchart"===this.layout.type&&this.flowchartLayoutModule?this.convertMermaidToFlowChart(e):this.layout&&"MindMap"===this.layout.type&&this.mindMapChartModule?this.convertMermaidToMindmap(e):console.warn('[WARNING] :: Module "FlowchartLayout" or "MindMap" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.countLeadingSpaces=function(e){for(var i=0,r=e.length;i0});this.clear(),this.mermaidNodeBaseCollection=[];var r=[],s={text:"",children:[],currentLevel:0,branch:"Left"},o=[],l=!1,h=!1,c=!1;if(i.length>0){for(var d=function(M){var w=i[parseInt(M.toString(),10)],C=0,D="",A=u.countLeadingSpaces(w),x=w.includes('"`');if(h=w.includes('`"'),c=(l=!!x||l)||c?c:0===A&&M>0,l&&h&&!x)return s.text+="\n"+w,l=!1,"continue";if(!x&&l)return s.text+="\n"+w,"continue";if(l=!h&&l,w.length>0&&(/\s/.test(w[0])&&M>0||0===A)){if(-1!==o.findIndex(function(B){return B.space===A.toString()}))for(var L=o.length-1;L>=0;L--){var O=o[parseInt(L.toString(),10)];if((N=parseFloat(O.space))>A)o.splice(L,1);else{if(N=0;L--){var N,T=o[parseInt(L.toString(),10)];if(!((N=parseFloat(T.space))>A)){var P=o[o.length-1];o.push({space:A.toString(),level:P.level+1});break}o.splice(L,1)}C=o[o.length-1].level}D=w.trim().replace(/^[+-]/,"")}var _={text:D,branch:void 0,children:[],currentLevel:0===M?0:C-1};if(r.length>0){for(;r.length>=C&&0!==r.length;)r.pop();r.length>0&&r[r.length-1].children.push(_)}r.push(_),s=_},u=this,p=0;p0){var c=h[h.length-1];c.arrowType=a[2],""!==a[3]&&(c.label&&c.label.some(function(d){return d.trim().length>0})?c.label.push(a[3]):(c.label=[],c.label[c.parentId.length-1]=a[3]))}h.filter(function(d){return d.parentId&&0===d.parentId.length}).forEach(function(d){d.parentId=null}),i=i.concat(h)}}this.createFlowChart(i),this.doLayout(),this.clearHistory()},t.prototype.createFlowChart=function(e){for(var i=[],r=0;r1)for(var h=0;h|---|--\s*.*?\s*-->|~~~|==>|===|==\s*.*?\s*==>|\s*-\.\s*->|\s*-\.\s*-|\s*-\.\s*.*?\s*\.\s*->|\s*-\..*?\.\s*->)(.*)$/);if(l){i=l[1].trim();var h=l[2].trim();r=l[3].trim();var d=h.match(/(-\.|\\-\\-|==|--|~~)(.*?)(\1>|\.->|==>|\\->|~~>)/),u=void 0,p="";o=null!==(u=d?{text:d[2].trim()||null,arrowType:d[1]+d[3]}:{text:null,arrowType:h}).text?u.text:"",s=(p=u.arrowType).includes("--\x3e")?"single-line-arrow":p.includes("---")?"single-line":p.includes("==>")?"double-line-arrow":p.includes("==")?"double-line":p.includes("~~~")?"wiggly-arrow":p.includes("-.->")||p.includes(".->")?"dotted-arrow":p.includes("-.-")||p.includes(".-")?"dotted":"single-line-arrow"}return[i,r,s,o]},t.prototype.parseStyle=function(e,i){if(e.startsWith("style")){var s=e.match(/^style\s+(\w+)\s+fill:([^,]+),stroke:([^,]+),stroke-width:(\d+)px;/);if(s){var c={id:s[1],fill:s[2],stroke:s[3],strokeWidth:parseInt(s[4],10)},d=i.filter(function(u){return u.id===c.id});d[0].color=c.fill,d[0].stroke=c.stroke,d[0].strokeWidth=c.strokeWidth}}},t.prototype.getNodeData=function(e,i,r){for(var s=[],o=null,a=null,l=0,h="",c=function(v){var y=e[parseInt(v.toString(),10)],S=d.splitNested(y);if(S[0].includes("|")){var b=S[0].match(/\|([^|]*)\|/);b&&(h=b[1]);var M=S[0].split("|");M.length>=3&&(S[0]=M[2].trim())}var w=S[0].trim();if(0===v?o=w:a=w,i.find(function(L){return L.id===w}))l++;else{var D=S.length>1?S[1]:S[0],A=d.getShape(D),x=D.replace(/[\\[\]\\(\\)\\{\\}\\{\\}\\/>]/g,"");s.push({id:w,name:x,shape:A,color:"white",parentId:[]})}},d=this,u=0;u"===h?0===s?(r.trim().length>0&&i.push(r.trim()),r=h,o=h,s++):(r+=h,s++):"]"===h||"}"===h||")"===h?1===s&&h===o?(i.push((r+=h).trim()),r="",s--):s>1?(r+=h,s--):r+=h:r+=h}return r.trim().length>0&&i.push(r.trim()),i},t.prototype.getShape=function(e){var i={};return e.startsWith("(((")?i={type:"Path",data:"M 0 0 A 1 1 0 0 0 7 0 A 1 1 0 0 0 0 0 M -1 0 A 1 1 0 0 0 8 0 A 1 1 0 0 0 -1 0"}:e.startsWith("((")?i={shape:"Ellipse",type:"Basic"}:e.startsWith("([")?i={type:"Flow",shape:"Terminator"}:e.startsWith("(")?i={type:"Flow",shape:"Process"}:e.startsWith("[[")?i={type:"Flow",shape:"PreDefinedProcess"}:e.startsWith("[/")?i=e.endsWith("/]")?{type:"Basic",shape:"Parallelogram"}:{type:"Path",data:"M 0 0 L 1 -1 L 5 -1 L 6 0 L 0 0"}:e.startsWith("[(")?i={type:"Path",data:"M 0 1 L 0 6 C 2 7 4 7 6 6 L 6 1 C 5 0 1 0 0 1 C 1 2 5 2 6 1"}:e.startsWith("[\\")?i=e.endsWith("\\]")?{type:"Path",data:"M 0 0 L 12 0 L 14 2 L 2 2 L 0 0"}:{type:"Path",data:"M 0 0 L 5 0 L 4 1 L 1 1 L 0 0"}:e.startsWith("[")?i={type:"Basic",shape:"Rectangle"}:e.startsWith("{{")?i={type:"Path",data:"M 0 0 L 2 -2 L 11 -2 L 13 0 L 11 2 L 2 2 L 0 0"}:e.startsWith("{")?i={type:"Flow",shape:"Decision"}:e.startsWith(">")&&(i={type:"Path",data:"M 0 0 L 8 0 L 8 2 L 0 2 L 2 1 L 0 0"}),i},t.prototype.getDiagramContent=function(e){return this.printandExportModule?this.printandExportModule.getDiagramContent(e):(console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),"")},t.prototype.exportImage=function(e,i){this.printandExportModule?this.printandExportModule.exportImages(e,i):console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.printImage=function(e,i){this.printandExportModule?(i.printOptions=!0,this.printandExportModule.exportImages(e,i)):console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.setStackLimit=function(e){this.undoRedoModule&&e&&(this.historyManager.stackLimit=e,this.undoRedoModule.applyLimit(this.historyManager.currentEntry,e,this,!0))},t.prototype.clearHistory=function(){this.undoRedoModule&&this.undoRedoModule.clearHistory(this)},t.prototype.getDiagramBounds=function(){if(this.printandExportModule){var e=this.printandExportModule.getDiagramBounds("",{});return e.width=e.width>this.scrollSettings.viewPortWidth?e.width+(e.x>0?e.x:0):this.scrollSettings.viewPortWidth,e.height=e.height>this.scrollSettings.viewPortHeight?e.height+(e.y>0?e.y:0):this.scrollSettings.viewPortHeight,e.x=e.x>0?0:e.x,e.y=e.y>0?0:e.y,e}return console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),new Ne},t.prototype.exportDiagram=function(e){return this.printandExportModule?this.printandExportModule.exportDiagram(e):(console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),"")},t.prototype.print=function(e){this.printandExportModule?this.printandExportModule.print(e):console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.addPorts=function(e,i){var s;this.protectPropertyChange(!0),e=this.nameTable[e.id]||e,i.length>1&&this.startGroupAction();for(var o=function(h){if(e.ports.some(function(y){return y.id===i[parseInt(h.toString(),10)].id}))return"continue";if(e instanceof te?(s=new Es(e,"ports",i[parseInt(h.toString(),10)],!0),e.ports.push(s)):e instanceof de&&(s=new xc(e,"ports",i[parseInt(h.toString(),10)],!0),e.ports.push(s)),e.children)for(var c=e.wrapper,d=0;d1&&this.endGroupAction(),e.wrapper.measure(new me(e.width,e.height)),e.wrapper.arrange(e.wrapper.desiredSize),this.updateDiagramObject(e),this.protectPropertyChange(!1)},t.prototype.addConstraints=function(e,i){return e|i},t.prototype.removeConstraints=function(e,i){return e&~i},t.prototype.addNodeLabels=function(e,i){this.addLabels(e,i)},t.prototype.addConnectorLabels=function(e,i){this.addLabels(e,i)},t.prototype.addLabels=function(e,i){this.protectPropertyChange(!0);var s,r=(e=this.nameTable[e.id]||e).wrapper;i.length>1&&this.startGroupAction();for(var o=0;o1&&this.endGroupAction(),e.wrapper.measure(new me(r.width,r.height)),e.wrapper.arrange(r.desiredSize),this.updateDiagramObject(e),this.protectPropertyChange(!1),this.refreshCanvasLayers()},t.prototype.addChildToUmlNode=function(e,i,r){var s,o,a,l,h="NoWrap";"Class"===e.shape.classifier||"Interface"===e.shape.classifier?"Method"===r?(o=new am(e,"",i),"Class"===e.shape.classifier?(e.shape.classShape.methods.push(o),s=e.shape.classShape):"Interface"===e.shape.classifier&&(e.shape.interfaceShape.methods.push(o),s=e.shape.interfaceShape),function Qse(n,t,e,i){if(e.methods&&e.methods.length){var r=e.methods,s="",o="",a=void 0,l=1,h=void 0,c=0,d=0,u=n.shape,g="Class"===u.classifier?u.classShape:u.interfaceShape;1===r.length?g.attributes.length>0?(c=g.attributes.filter(function(w){return w.isSeparator}).length,h=(l=2+g.attributes.length+c)+1,rT(n,t,l)):h=l+1:(c=g.attributes.filter(function(w){return w.isSeparator}).length,d=g.methods.filter(function(w){return w.isSeparator}).length,h=(l=2+g.attributes.length+c+g.methods.length+d)+1);for(var v=0;v1&&this.startGroupAction();for(var r=i.length-1;r>=0;r--)if(e.children&&e.children.length>0){var s=e.wrapper.children.filter(function(o){return o.id===e.id+"group_container"});s&&s.length>0&&this.removelabelExtension(e,i,r,s[0])}else this.removelabelExtension(e,i,r,e.wrapper);i.length>1&&this.endGroupAction(),this.refreshCanvasLayers()},t.prototype.removePortsExtenion=function(e,i,r,s){for(var o=0;o1&&this.startGroupAction();for(var r=i.length-1;r>=0;r--)if(e.children&&e.children.length>0)for(var s=0;s1&&this.endGroupAction()},t.prototype.getSizeValue=function(e,i){var r;return r=e.toString().indexOf("px")>0?e.toString():e.toString().indexOf("%")>0?void 0!==i?"100%":e.toString():e.toString()+"px",i&&(qa(this),r="calc("+r+" - "+i+"px)"),r},t.prototype.renderRulers=function(){this.rulerSettings.showRulers?(function Vne(n){var t=qa(n),i=Tt("div",{id:n.element.id+"_overlapRuler",style:"height:"+t.height+"px;width:"+t.width+"px;position:absolute;left:0;top:0",class:"e-ruler-overlap"});n.element.insertBefore(i,n.element.firstChild)}(this),J3(this,!0),J3(this,!1)):Yx(this)},t.prototype.intOffPageBackground=function(){var e=new me;e=qa(this);var i=document.getElementById(this.element.id+"content"),r=this.getSizeValue(this.width,e.width),s=this.getSizeValue(this.height,e.height),o=this.rulerSettings.showRulers?"width:"+r+"; height:"+s+";top:"+e.height+"px;left:"+e.width+"px;overflow: scroll;position:absolute;overflow:auto;":"width:"+r+"; height:"+s+";position:absolute; left:0px; top:0px;overflow: auto;",a={id:this.element.id+"content",tabindex:"0",style:o};i?(this.diagramCanvas=i,Za(this.diagramCanvas,o)):(this.diagramCanvas=Tt("div",a),this.element.appendChild(this.diagramCanvas)),this.diagramCanvas.style.background=this.backgroundColor},t.prototype.initDiagram=function(){this.intOffPageBackground(),Ho(this.element,{style:"width:"+this.getSizeValue(this.width)+"; height:"+this.getSizeValue(this.height)+";position:relative;overflow:hidden;"})},t.prototype.renderHiddenUserHandleTemplateLayer=function(e){var r=Tt("div",{class:this.element.id+"_hiddenUserHandleTemplate",style:"width:"+e.width+"px; height:"+e.height+"px;visibility:hidden ; overflow: hidden;"});this.element.appendChild(r)},t.prototype.renderBackgroundLayer=function(e,i){var r=this.createSvg(this.element.id+"_backgroundLayer_svg",e.width,e.height);Za(r,i);var s=Bi("g",{id:this.element.id+"_backgroundImageLayer",class:"e-background-image-layer"});r.appendChild(s);var a=Bi("g",{id:this.element.id+"_backgroundLayer",class:"e-background-layer"});r.appendChild(a),this.diagramCanvas.appendChild(r)},t.prototype.renderGridLayer=function(e,i){var r=this.createSvg(this.element.id+"_gridline_svg",e.width,e.height);r.setAttribute("class","e-grid-layer");var s=Bi("g",{id:this.element.id+"_gridline"}),o=Bi("rect",{id:this.element.id+"_grid_rect",x:"0",y:"0",width:"100%",height:"100%"});if(im()){var a=new URL(window.location.href);o.setAttribute("fill",""!==a.search?"url(#"+this.element.id+"_pattern)":"url("+location.protocol+"//"+location.host+location.pathname+"#"+this.element.id+"_pattern)")}else o.setAttribute("fill","url(#"+this.element.id+"_pattern)");s.appendChild(o),r.appendChild(s),this.diagramCanvas.appendChild(r),oi(r,{style:i})},t.prototype.renderDiagramLayer=function(e,i){if(this.diagramLayerDiv=Tt("div",{id:this.element.id+"_diagramLayer_div",style:"width:"+e.width+"px; height:"+e.height+"px;"+i}),"SVG"===this.mode){var s=this.createSvg(this.element.id+"_diagramLayer_svg",e.width,e.height);s.style["pointer-events"]="none",s.setAttribute("class","e-diagram-layer");var o=Bi("g",{id:this.element.id+"_diagramLayer"}),a=Bi("g",{});this.diagramLayer=o,s.style["pointer-events"]="all",a.appendChild(o),s.appendChild(a),this.diagramLayerDiv.appendChild(s)}else this.diagramLayer=bo.createCanvas(this.element.id+"_diagram",e.width,e.height),Za(this.diagramLayer,"position:absolute;left:0px;top:0px;"),this.diagramLayerDiv.appendChild(this.diagramLayer);this.diagramCanvas.appendChild(this.diagramLayerDiv)},t.prototype.initLayers=function(){var e="position:absolute;top:0px;left:0px;overflow:hidden;pointer-events:none;",r=document.getElementById(this.element.id).getBoundingClientRect(),s=function moe(){var n=Tt("div",{style:"visibility:hidden; width: 100px"});document.body.appendChild(n);var t=n.getBoundingClientRect().width;n.style.overflow="scroll";var e=Tt("div",{style:"width:100%"});n.appendChild(e);var i=e.getBoundingClientRect().width;return n.parentNode.removeChild(n),t-i}();this.scroller.scrollerWidth=s,this.scroller.setViewPortSize(r.width,r.height),this.renderRulers();var o="measureElement";window[""+o]&&(window[""+o]=null,document.getElementById("measureElement").remove()),function RF(){var n="measureElement";if(window[""+n])window[""+n].usageCount+=1;else{var t=Tt("div",{id:"measureElement",style:"visibility:hidden ; height: 0px ; width: 0px; overflow: hidden;"}),e=Tt("span",{style:"display:inline-block ; line-height: normal"});t.appendChild(e);var i=Tt("img",{alt:"measureElementImage",src:"data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7"});t.appendChild(i);var r=document.createElementNS("http://www.w3.org/2000/svg","svg");r.setAttribute("xmlns:xlink","http://www.w3.org/1999/xlink"),t.appendChild(r);var s=document.createElementNS("http://www.w3.org/2000/svg","path");s.setAttribute("d",""),r.appendChild(s),document.createTextNode("");var a=document.createElementNS("http://www.w3.org/2000/svg","text");a.setAttributeNS("http://www.w3.org/XML/1998/namespace","xml:space","preserve"),r.appendChild(a),window[""+n]=t,window[""+n].usageCount=1,document.body.appendChild(t);var l="measureElementCount";window[""+l]?window[""+l]++:window[""+l]=1}}(),this.renderBackgroundLayer(r,e),this.renderGridLayer(r,e),this.renderDiagramLayer(r,e),this.renderHTMLLayer(r,e),this.renderPortsExpandLayer(r,e),this.renderNativeLayer(r,e),this.renderAdornerLayer(r,e),this.renderHiddenUserHandleTemplateLayer(r)},t.prototype.renderAdornerLayer=function(e,i){var r=Tt("div",{id:this.element.id+"_diagramAdornerLayer",style:"width:"+e.width+"px;height:"+e.height+"px;"+i}),s=Tt("div",{id:this.element.id+"_diagramUserHandleLayer",style:"width:"+e.width+"px;height:"+e.height+"px;"+i});s.setAttribute("class","e-userHandle-layer"),r.appendChild(s);var o=this.createSvg(this.element.id+"_diagramAdorner_svg",e.width,e.height);o.setAttribute("class","e-adorner-layer"),o.style["pointer-events"]="none",this.adornerLayer=Bi("g",{id:this.element.id+"_diagramAdorner"}),this.adornerLayer.style[" pointer-events"]="all",o.appendChild(this.adornerLayer),r.appendChild(o),this.diagramCanvas.appendChild(r);var a=Bi("g",{id:this.element.id+"_SelectorElement"});this.adornerLayer.appendChild(a),oi(o,{style:"pointer-events:none;"})},t.prototype.renderPortsExpandLayer=function(e,i){var r=this.createSvg(this.element.id+"_diagramPorts_svg",e.width,e.height);r.setAttribute("class","e-ports-expand-layer");var s=Bi("g",{id:this.element.id+"_diagramPorts",class:"e-ports-layer",style:"pointer-events: all;"});r.appendChild(s);var o=Bi("g",{id:this.element.id+"_diagramExpander",class:"e-expand-layer",style:"pointer-events: all;"});r.appendChild(o),this.diagramCanvas.appendChild(r),oi(r,{style:i})},t.prototype.renderHTMLLayer=function(e,i){this.htmlLayer=Tt("div",{id:this.element.id+"_htmlLayer",style:"width:"+e.width+"px; height:"+e.height+"px;position:absolute;top:0px;left:0px;overflow:hidden;pointer-events:none;",class:"e-html-layer"});var r=Tt("div",{id:this.element.id+"_htmlLayer_div",style:"position:absolute;top:0px;left:0px;pointer-events:all;"});this.htmlLayer.appendChild(r),this.diagramCanvas.appendChild(this.htmlLayer)},t.prototype.renderNativeLayer=function(e,i){var r=this.createSvg(this.element.id+"_nativeLayer_svg",e.width,e.height),s=Bi("g",{id:this.element.id+"_nativeLayer",style:"pointer-events:all;"});r.appendChild(s),this.diagramLayerDiv.appendChild(r),oi(r,{class:"e-native-layer",style:i})},t.prototype.createSvg=function(e,i,r){var s=document.createElementNS("http://www.w3.org/2000/svg","svg");return oi(s,{id:e,width:i,height:r}),s},t.prototype.updateBazorShape=function(){for(var e=0;e1,i=[],r={},s={},o=[],a=0,l=this.nodes;a0||b&&b.children&&b.children.length>0)&&(M=!1),S&&S.wrapper&&b&&b.wrapper&&M?this.initConnectors(r[""+h],f):i.push(r[""+h])}else b=r[y.targetID],(S=r[y.sourceID])&&S.children&&S.children.length>0||b&&b.children&&b.children.length>0?i.push(r[""+h]):this.initConnectors(r[""+h],f);else r[""+h].children?o.push(h):r[""+h].shape instanceof lT&&r[""+h].shape.activity.subProcess.processes&&r[""+h].shape.activity.subProcess.processes.length>0?s[r[""+h].id]=h:this.initNodes(r[""+h],f);if(this.bpmnModule)for(var w=0,C=this.bpmnModule.bpmnTextAnnotationConnector;w-1&&-1===r.indexOf(c)&&-1===s.indexOf(c)&&r.splice(0,0,c);-1===r.indexOf(o)&&s.push(o)}return r.concat(s)},t.prototype.addToLayer=function(e,i){var r;if(i&&(r=this.commandHandler.getObjectLayer(e.id)),(!i||!r)&&-1===this.activeLayer.objects.indexOf(e.id)&&this.activeLayer.objects.push(e.id),(e instanceof te||e instanceof de)&&("SwimLane"!==e.shape.type||e.children&&e.children.length>0)){if(e.parentId){var s=this.swimlaneZIndexTable[e.parentId],o=this.swimlaneChildTable[e.id];(s&&-1!==s||o&&-1!==o)&&(e.zIndex=this.swimlaneChildTable[e.id])}e instanceof de&&e.sourceID&&e.targetID?-1!==this.activeLayer.objects.indexOf(e.sourceID)&&-1!==this.activeLayer.objects.indexOf(e.targetID)&&this.setZIndex(r||this.activeLayer,e):this.setZIndex(r||this.activeLayer,e)}},t.prototype.updateLayer=function(e){for(var i=0,r=Object.keys(e.layers);i0)for(r=0;rs;l--)r.zIndexTable[parseInt(l.toString(),10)]=r.zIndexTable[l-1],this.nameTable[r.zIndexTable[parseInt(l.toString(),10)]]&&(this.nameTable[r.zIndexTable[parseInt(l.toString(),10)]].zIndex=l);r.zIndexTable[parseInt(a.toString(),10)]=i.id}}},t.prototype.initializeDiagramLayers=function(){for(var e=0;ethis.layers[parseInt(a.toString(),10)].zIndex&&(i=this.layers[parseInt(e.toString(),10)],this.layers[parseInt(e.toString(),10)]=this.layers[parseInt(a.toString(),10)],this.layers[parseInt(a.toString(),10)]=i);0===this.layers.length&&this.commandHandler.addLayer({id:"default_layer",visible:!0,lock:!1,objects:[],zIndex:0,objectZIndex:-1,zIndexTable:{}},null,!0),this.setActiveLayer(this.layers[this.layers.length-1].id)},t.prototype.resetTool=function(){this.eventHandler.resetTool()},t.prototype.initObjectExtend=function(e,i,r){if(r){var s=this.commandHandler.checkBoundaryConstraints(void 0,void 0,e.wrapper.bounds,!0);if("SwimLane"===e.shape.type)for(var o=0,a=Object.keys(i.zIndexTable);o0)&&this.setZIndex(i,e)),e instanceof te){if(r){if("helper"!==e.id&&(o=Zi(this.getNodeDefaults))){if((a=o(e,this))&&a.ports)for(var l=0;l0)for(l=0;l0&&!e.container||e.processId){var r=this.nameTable[e.id];if(!(this.realActions&$i.PreventScale||this.realActions&$i.PreventDrag)){if(r.offsetX&&(this.realActions&$i.EnableGroupAction||!(this.diagramActions&ee.UndoRedo||this.diagramActions&ee.ToolAction||this.diagramActions&ee.PublicMethod))){this.realActions|=$i.PreventScale;var s=r.offsetX-e.wrapper.offsetX;r.offsetX=e.wrapper.offsetX;var o=r.offsetY-e.wrapper.offsetY;r.offsetY=e.wrapper.offsetY,s+o!==0&&this.drag(r,s,o),this.realActions&=~$i.PreventScale}else r.offsetX=e.wrapper.offsetX;r.offsetY&&(this.realActions&$i.EnableGroupAction||!(this.diagramActions&ee.UndoRedo||this.diagramActions&ee.ToolAction||this.diagramActions&ee.PublicMethod))?(this.realActions|=$i.PreventScale,o=r.offsetY-e.wrapper.offsetY,r.offsetY=e.wrapper.offsetY,this.drag(r,0,o),this.realActions&=~$i.PreventScale):r.offsetY=e.wrapper.offsetY,this.diagramActions&&(r.width=e.wrapper.actualSize.width,r.height=e.wrapper.actualSize.height)}}i&&e.children&&e.children.length>0&&(void 0!==this.nameTable[e.id].width?this.scaleObject(e,this.nameTable[e.id].width,!0):this.nameTable[e.id].width=e.wrapper.actualSize.width,void 0!==this.nameTable[e.id].height?this.scaleObject(e,this.nameTable[e.id].height,!1):this.nameTable[e.id].height=e.wrapper.actualSize.height)},t.prototype.initNode=function(e,i,r){var a,p,s=e.initContainer(),o=new Ii;if(this.diagramSettings.inversedAlignment||(s.inversedAlignment=!1),s.children||(s.children=[]),e.children){s.measureChildren=!1,o.id=e.id+"group_container",o.style.fill=e.shape&&"SwimLane"===e.shape.type?e.style.fill:"none",o.style.strokeColor="none",o.horizontalAlignment="Stretch",o.verticalAlignment="Stretch",o.pivot=e.pivot,s.style=e.style,s.padding.left=e.padding.left,s.padding.right=e.padding.right,s.padding.top=e.padding.top,s.padding.bottom=e.padding.bottom,o.children=[],o.preventContainer=!0,e.container&&(o.relativeMode="Object");var l=!!(e.ports&&e.ports.length>0);if(m(e.container)&&!l&&s.children.push(o),e.container&&"Grid"===e.container.type)for(var h=0;h0&&e.wrapper.children[0]instanceof jv){if(this.setZIndex(this.activeLayer,e),this.connectors.length>0)for(h=0;h0?i.phases.length:0,v="Horizontal"===i.orientation,y=v?i.phases.length||1:s.length+1,S=v?(i.header&&i.hasHeader?1:0)+(i.phases.length>0?1:0)+i.lanes.length:(i.header&&i.hasHeader?1:0)+i.phases.length;if(0===h&&!v&&i.lanes.length&&(S+=1),v?(a=(i.header&&i.hasHeader?1:0)+(h>0?1:0),l=0):(a=i.header&&i.hasHeader?1:0,l=h>0?1:0),s.length>0)for(o+=i.header&&i.hasHeader?i.header.height:0,p=0;pl?d.margin.left=d.margin.left-(u.bounds.left-e.bounds.left):u.children[0].children[1].actualSize.width+r>=d.margin.left&&(d.margin.left=u.children[0].children[1].actualSize.width+r),d.margin.lefta?d.margin.top=d.margin.top-(u.bounds.top-o):u.children[0].children[1].actualSize.height+r>=d.margin.top&&(d.margin.top=u.children[0].children[1].actualSize.height+r),d.margin.left0)for(o=0;o0&&this.updateChildPosition(e)},t.prototype.addBpmnAnnotationConnector=function(e,i){if(e.parentObj instanceof t||e.parentObj instanceof Rd){var r=e.shape,o=""!==r.textAnnotation.textAnnotationTarget&&this.nameTable[r.textAnnotation.textAnnotationTarget],a=o?this.nameTable[r.textAnnotation.textAnnotationTarget]:null,l=null!=a?a.wrapper:null,h=e.ports[0],c={x:0,y:0};switch(r.textAnnotation.textAnnotationDirection){case"Left":h.offset={x:0,y:.5},c.x=i.bounds.left-40,c.y=i.bounds.bottom+30;break;case"Right":h.offset={x:1,y:.5},c.x=i.bounds.right+40,c.y=i.bounds.bottom+30;break;case"Top":h.offset={x:.5,y:0},c.x=i.bounds.right+30,c.y=i.bounds.top-40;break;case"Bottom":h.offset={x:.5,y:1},c.x=i.bounds.right+30,c.y=i.bounds.bottom+40;break;default:h.offset={x:0,y:.5},c.x=i.bounds.left-40,c.y=i.bounds.bottom+30,o&&null!=i&&null!=l&&(i.bounds.left>l.bounds.right?h.offset={x:0,y:.5}:i.bounds.rightl.bounds.top?h.offset={x:.5,y:0}:i.bounds.top0&&this.updateChildPosition(r)}},t.prototype.canExecute=function(){return!0},t.prototype.updateStackProperty=function(e,i,r){e.container&&"Stack"===e.container.type&&(i.width||(i.wrapper.horizontalAlignment="Stretch",i.horizontalAlignment="Stretch"),i.height||(i.verticalAlignment="Stretch",i.wrapper.verticalAlignment="Stretch"),r&&"UmlClassifier"===e.shape.type&&(i.umlIndex=r))},t.prototype.initViews=function(){this.isLoading||(this.views.push(this.element.id),this.views[this.element.id]=this)},t.prototype.initCommands=function(){var e=this.commandManager.commands,i={copy:{execute:this.copyCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.C,keyModifiers:pt.Control}},paste:{execute:this.pasteCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.V,keyModifiers:pt.Control}},cut:{execute:this.cutCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.X,keyModifiers:pt.Control}},delete:{execute:this.removeCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Delete}},selectAll:{execute:this.selectAll.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.A,keyModifiers:pt.Control}},undo:{execute:this.undo.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Z,keyModifiers:pt.Control}},redo:{execute:this.redo.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Y,keyModifiers:pt.Control}},nudgeUp:{execute:this.nudgeCommand.bind(this,"Up"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Up},parameter:"up"},nudgeRight:{execute:this.nudgeCommand.bind(this,"Right"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Right},parameter:"right"},nudgeDown:{execute:this.nudgeCommand.bind(this,"Down"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Down},parameter:"down"},nudgeLeft:{execute:this.nudgeCommand.bind(this,"Left"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Left},parameter:"left"},startEdit:{execute:this.startEditCommad.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.F2}},endEdit:{execute:this.endEditCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Escape}},focusToNextItem:{execute:this.navigateItems.bind(this,!0),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Tab}},focusToPreviousItem:{execute:this.navigateItems.bind(this,!1),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Tab,keyModifiers:pt.Shift}},selectFocusedItem:{execute:this.startEditCommad.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Enter}},bold:{execute:this.fontStyleCommand.bind(this,"bold"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.B,keyModifiers:pt.Control}},italic:{execute:this.fontStyleCommand.bind(this,"italic"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.I,keyModifiers:pt.Control}},underline:{execute:this.fontStyleCommand.bind(this,"underline"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.U,keyModifiers:pt.Control}},duplicate:{execute:this.duplicateCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.D,keyModifiers:pt.Control}},group:{execute:this.groupCommand.bind(this,"group"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.G,keyModifiers:pt.Control}},ungroup:{execute:this.groupCommand.bind(this,"ungroup"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.U,keyModifiers:pt.Control|pt.Shift}},rotateClockwise:{execute:this.rotateCommand.bind(this,"clockwise"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.R,keyModifiers:pt.Control}},rotateAntiClockwise:{execute:this.rotateCommand.bind(this,"antiClockwise"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.L,keyModifiers:pt.Control}},flipHorizontal:{execute:this.flipCommand.bind(this,"horizontal"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.H,keyModifiers:pt.Control}},flipVertical:{execute:this.flipCommand.bind(this,"vertical"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.J,keyModifiers:pt.Control}},pointerTool:{execute:this.toolCommand.bind(this,"pointer"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number1,keyModifiers:pt.Control}},textTool:{execute:this.toolCommand.bind(this,"text"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number2,keyModifiers:pt.Control}},connectTool:{execute:this.toolCommand.bind(this,"connect"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number3,keyModifiers:pt.Control}},freeForm:{execute:this.toolCommand.bind(this,"freeForm"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number5,keyModifiers:pt.Control}},lineTool:{execute:this.toolCommand.bind(this,"line"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number6,keyModifiers:pt.Control}},rectangleTool:{execute:this.toolCommand.bind(this,"rectangle"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number8,keyModifiers:pt.Control}},ellipseTool:{execute:this.toolCommand.bind(this,"ellipse"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number9,keyModifiers:pt.Control}},zoomIn:{execute:this.zoomCommand.bind(this,"zoomIn"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Plus,keyModifiers:pt.Control}},zoomOut:{execute:this.zoomCommand.bind(this,"zoomOut"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Minus,keyModifiers:pt.Control}},shiftUp:{execute:this.shiftCommand.bind(this,"Up"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Up,keyModifiers:pt.Shift}},shiftDown:{execute:this.shiftCommand.bind(this,"Down"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Down,keyModifiers:pt.Shift}},shiftLeft:{execute:this.shiftCommand.bind(this,"Left"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Left,keyModifiers:pt.Shift}},shiftRight:{execute:this.shiftCommand.bind(this,"Right"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Right,keyModifiers:pt.Shift}},alignTextCenter:{execute:this.alignCommand.bind(this,"center"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.C,keyModifiers:pt.Control|pt.Shift}},alignTextLeft:{execute:this.alignCommand.bind(this,"right"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.L,keyModifiers:pt.Control|pt.Shift}},alignTextRight:{execute:this.alignCommand.bind(this,"left"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.R,keyModifiers:pt.Control|pt.Shift}},alignTextTop:{execute:this.alignCommand.bind(this,"top"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.E,keyModifiers:pt.Control|pt.Shift}},alignTextCenterVertical:{execute:this.alignCommand.bind(this,"centerVertical"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.M,keyModifiers:pt.Control|pt.Shift}},alignTextBottom:{execute:this.alignCommand.bind(this,"bottom"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.V,keyModifiers:pt.Control|pt.Shift}},alignJustify:{execute:this.alignCommand.bind(this,"justify"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.J,keyModifiers:pt.Control|pt.Shift}},sendToBack:{execute:this.orderCommand.bind(this,"sendToBack"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.B,keyModifiers:pt.Control|pt.Shift}},bringToFront:{execute:this.orderCommand.bind(this,"bringToFront"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.F,keyModifiers:pt.Control|pt.Shift}},sendBackward:{execute:this.orderCommand.bind(this,"sendBackward"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.BracketLeft,keyModifiers:pt.Control}},bringForward:{execute:this.orderCommand.bind(this,"bringForward"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.BracketRight,keyModifiers:pt.Control}}};this.initCommandManager(e,i)},t.prototype.overrideCommands=function(e,i){for(var r,s=0,o=Object.keys(i);se.zIndex){("HTML"===e.shape.type||"Native"===e.shape.type)&&(o="HTML"===e.shape.type?"html":"native"),s=uoe(i,r[parseInt(a.toString(),10)].id,o);break}return s},t.prototype.updateDiagramObject=function(e,i,r){for(var s,o="domTable",a=0,l=this.views;a1&&(d=this.commandHandler.getObjectLayer(e.id)),void 0===d||d&&d.visible||r){var u=Io(this.element.id);window[""+o][s.element.id+"_diagramLayer"]||(window[""+o][s.element.id+"_diagramLayer"]=document.getElementById(s.element.id+"_diagramLayer"));var p=window[""+o][s.element.id+"_diagramLayer"];this.diagramActions&ee.Interactions&&this.updateCanupdateStyle(e.wrapper.children,!0);var f=this.getMidPoint(e);this.diagramRenderer.updateNode(e.wrapper,p,u,void 0,i?void 0:this.getZindexPosition(e,s.element.id),f,this.portCenterPoint),this.updateCanupdateStyle(e.wrapper.children,!0)}}},t.prototype.applyMarginBezier=function(e,i){i.cx=i.cx+e.margin.left,i.cx=i.cx-e.margin.right,i.cy=i.cy+e.margin.top,i.cy=i.cy-e.margin.bottom},t.prototype.getMidPoint=function(e){var i;if(e instanceof de&&"Bezier"===e.type){i=[];for(var r=this.getBezierPoints(e),s=z.getLengthFromListOfPoints(r),o=0;o0&&e.updateView(e));var s=Io(e.element.id);this.renderDiagramElements(e.diagramLayer,e.diagramRenderer,s,void 0,void 0,i);for(var o=0;o0&&this.renderBasicElement(e),!this.diagramActions||!(this.diagramActions&ee.Render)||ee.ToolAction&this.diagramActions||Ds(this)||1!==this.scroller.currentZoom?this.refreshElements(e):this.renderTimer||(this.renderTimer=setTimeout(function(){i.refreshElements(e)},40)))},t.prototype.updatePortVisibility=function(e,i,r){var s;if((e instanceof te||e instanceof de)&&(!this.drawingObject||!this.drawingObject.shape)&&to(e)){for(var a=e.ports,l=!1,h=0;h=0&&this.scroller.removeCollection.splice(l,1);var h=this.nameTable[e[parseInt(a.toString(),10)]];this.updateTextElementValue(h),this.diagramRenderer.renderElement(h.wrapper,s,o,void 0,void 0,void 0,void 0,h.zIndex)}for(var c=0;c0?this.scroller.oldCollectionObjects:void 0,b=Object.keys(S||g.zIndexTable);b.sort(function(N,T){return parseInt(""+N,10)-parseInt(""+T,10)});for(var M=0,w=b;M0?h:0)+"px",y=(this.realActions&$i.vScrollbarMoved?0:-(this.scroller.verticalOffset<0?this.scroller.verticalOffset:0))+"px"):(v="0px",y="0px"),this.realActions&$i.hScrollbarMoved&&(this.realActions=this.realActions&~$i.hScrollbarMoved),this.realActions&$i.vScrollbarMoved&&(this.realActions=this.realActions&~$i.vScrollbarMoved)):(v=(l.x<0?h:-this.scroller.horizontalOffset)+"px",y=(l.y<0?c:-this.scroller.verticalOffset)+"px"),this.diagramLayer.style.left=v,this.diagramLayer.style.top=y,A.tx=-l.x/A.scale,A.ty=-l.y/A.scale);var R=!0;if(o&&(R=!1),this.updateTextElementValue(D),this.refreshing&&D.shape.activity&&D.shape.activity.subProcess&&D.shape.activity.subProcess.processes){for(var L=0;L0){var o=s.children[0],a=o.data;(r.isBezierEditing&&this.selectedItems.connectors[0].id===r.id||"Bezier"!==r.type)&&r.getSegmentElement(r,o,"ComplexHierarchicalTree"===this.layout.type||"HierarchicalTree"===this.layout.type?this.layout.orientation:void 0,void 0,!1),o.data!==a&&(s.measure(new me),s.arrange(s.desiredSize),"SVG"===this.mode&&!e&&this.updateDiagramObject(r))}}else this.constraints&rt.Bridging&&console.warn('[WARNING] :: Module "ConnectorBridging" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.setCursor=function(e){this.diagramRenderer.setCursor(this.diagramCanvas,e)},t.prototype.clearCanvas=function(e){var i=e.contentWidth||e.diagramLayer.width/this.scroller.currentZoom,r=e.contentHeight||e.diagramLayer.height/this.scroller.currentZoom;"SVG"!==e.mode&&bo.getContext(e.diagramLayer).clearRect(0,0,i,r)},t.prototype.updateScrollOffset=function(){this.scroller.setScrollOffset(this.diagramCanvas.scrollLeft,this.diagramCanvas.scrollTop),QI(this),Ds(this)&&this.scroller.virtualizeElements()},t.prototype.setOffset=function(e,i){var r="domTable";window[""+r][this.element.id+"content"]||(window[""+r][this.element.id+"content"]=document.getElementById(this.element.id+"content"));var s=window[""+r][this.element.id+"content"];s&&(s.scrollLeft=e,s.scrollTop=i)},t.prototype.setSize=function(e,i){if(this.diagramLayer&&!this.preventDiagramUpdate){var r=qa(this);e-=r.width,i-=r.height;var s=this.spatialSearch.getPageBounds();s.x*=this.scroller.currentZoom,s.y*=this.scroller.currentZoom,s.width*=this.scroller.currentZoom,s.height*=this.scroller.currentZoom;var o="SVG"===this.mode?1:1.5,a="SVG"===this.mode?pT(this.element.id):this.diagramLayer,h="Canvas"===this.mode&&this.constraints&rt.Virtualization?this.scroller.viewPortHeight:i;a.setAttribute("width",(o*("Canvas"===this.mode&&this.constraints&rt.Virtualization?this.scroller.viewPortWidth:e)).toString()),a.setAttribute("height",(o*h).toString());var c=document.getElementById(this.element.id+"_diagramUserHandleLayer");c&&(c.style.width=e+"px",c.style.height=i+"px");var d={width:e.toString(),height:i.toString()};this.diagramLayerDiv.style.width=e+"px",this.diagramLayerDiv.style.height=i+"px",oi(NF(this.element.id),d),oi(function foe(n){return xt(n).getElementsByClassName("e-ports-expand-layer")[0]}(this.element.id),d);var u=Pl(this.element.id);oi(u,d),u.parentNode.style.width=e+"px",u.parentNode.style.height=i+"px";var p=Bd(this.element.id);oi(p,d),this.diagramRenderer.updateGrid(this.snapSettings,p,this.scroller.transform,this.rulerSettings,this.hRuler,this.vRuler),oi(vT(this.element.id),d),this.htmlLayer.style.width=e+"px",this.htmlLayer.style.height=i+"px","SVG"!==this.mode&&!Ds(this)&&this.refreshDiagramLayer(),"SVG"===this.mode&&Ds(this)&&this.scroller.virtualizeElements()}},t.prototype.transformLayers=function(){var e=this.spatialSearch.getPageBounds();e.x*=this.scroller.currentZoom,e.y*=this.scroller.currentZoom,e.width*=this.scroller.currentZoom,e.height*=this.scroller.currentZoom,this.diagramRenderer.updateGrid(this.snapSettings,Bd(this.element.id),this.scroller.transform,this.rulerSettings,this.hRuler,this.vRuler),this.diagramRenderer.transformLayers(this.scroller.transform,"SVG"===this.mode),this.diagramActions&ee.DragUsingMouse||this.updateSelector(),this.renderPageBreaks(e)},t.prototype.removePageBreaks=function(){if(this.diagramLayer){var e=OF(this.element.id);if(e&&e.childNodes)for(var i=e.childNodes.length,r=0;rthis.pageSettings.height&&(e=this.pageSettings.height,this.pageSettings.height=this.pageSettings.width,this.pageSettings.width=e):this.pageSettings.height>this.pageSettings.width&&(e=this.pageSettings.width,this.pageSettings.width=this.pageSettings.height,this.pageSettings.height=e)},t.prototype.setOverview=function(e,i){if(e)e&&(this.views.push(e.id),this.views[e.id]=e,e.renderDocument(e),e.diagramRenderer.setLayers(),e.updateView(e),this.renderNodes(e));else{for(var r=0;r1&&this.updateSelectionRectangle(),this.isProtectedOnChange=s},t.prototype.updateSelectionRectangle=function(){for(var e=lm(this.element.id),i=!1,r=0;r1&&this.updateSelectionRectangle(),this.enableServerDataBinding(e)},t.prototype.renderSelectorForAnnotation=function(e,i){this.diagramRenderer.renderResizeHandle(e.wrapper.children[0],i,e.thumbsConstraints,this.scroller.currentZoom,e.constraints,this.scroller.transform,void 0,to(e.annotation),void 0,void 0,e.handleSize)},t.prototype.drawSelectionRectangle=function(e,i,r,s){this.clearSelectorLayer(),this.diagramRenderer.drawSelectionRectangle(e,i,r,s,this.adornerLayer,this.scroller.transform)},t.prototype.renderHighlighter=function(e){var i=Pl(this.element.id);this.diagramRenderer.renderHighlighter(e,i,this.scroller.transform)},t.prototype.clearHighlighter=function(){var e=Pl(this.element.id),i=e.getElementById(e.id+"_highlighter");i&&i.parentNode.removeChild(i)},t.prototype.getNodesConnectors=function(e){for(var i=0;i0;l--)(a=o[l-1]).parentNode.removeChild(a);if(!ce()){var h=gT(this.element.id).childNodes;for(r=h.length;r>0;r--)h[r-1].parentNode.removeChild(h[r-1])}}},t.prototype.getWrapper=function(e,i){var r;i=e.id+"_"+i;for(var s=e instanceof Ii?e:this.getPortContainer(this.nameTable[e.id]),o=0;o0&&this.applyStyle(e,a=r.annotations)}for(i=0;i0){var a=this.selectedItems.connectors[parseInt(i.toString(),10)].annotations;this.applyStyle(e,a)}},t.prototype.applyStyle=function(e,i){for(var r=0;r0)for(var i=0;i0?r[0].zIndex+(e?1:-1):e?0:this.nodes.length+this.connectors.length-1)<0?i=this.nodes.length+this.connectors.length-1:i===this.nodes.length+this.connectors.length&&(i=0);for(var s=0;s0)for(var s=void 0,o=r.children.length-1;o>=0;o--){var a=r.children[parseInt(o.toString(),10)];i.length>0&&-1!==i.indexOf(a.id.split("_groupElement")[0])&&(r.parentNode.insertBefore(a,s||r),s=a)}r&&r.parentNode.removeChild(r)},t.prototype.deleteGroup=function(e){var r=[];e.children&&(r=this.commandHandler.getChildren(e,[])),this.UpdateBlazorDiagramModelCollection(e);for(var s=0,o=r;s0)for(var xe=0;xe0)if("Path"===t.shape.type&&void 0!==n.shape.data)t.wrapper.children[0].data=n.shape.data;else if("Text"===t.shape.type&&void 0!==n.shape.content)t.wrapper.children[0].content=n.shape.content;else if("Image"===t.shape.type&&void 0!==n.shape.source)t.wrapper.children[0].source=n.shape.source;else if("Native"===t.shape.type){for(var r=void 0,s=0;s-1)&&(this.diagramActions&ee.PreventZIndexOnDragging?this.updateDiagramObject(e,!0):this.updateDiagramObject(e)),!s&&d&&(this.lineRoutingModule&&this.diagramActions&&this.constraints&rt.LineRouting&&"helper"!==e.id?this.diagramActions&ee.ToolAction||this.lineRoutingModule.renderVirtualRegion(this,!0):this.diagramActions&&this.constraints&rt.LineRouting&&"helper"!==e.id&&console.warn('[WARNING] :: Module "LineRouting" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),this.updateConnectorEdges(e),"helper"!==e.id&&!(this.diagramActions&ee.ToolAction))))for(var ya=this.spatialSearch.findObjects(e.wrapper.outerBounds),Mo=0;Moe?Math.abs(r-e):Math.abs(e-r),d=s>i?Math.abs(s-i):Math.abs(i-s);(0===c&&0===d||Number.isNaN(c)&&Number.isNaN(d))&&o.laneMargin&&(u=o.margin.left-o.laneMargin.left,p=o.margin.top-o.laneMargin.top);var f=o.width,g=o.height,v=new Ne(0,0,0,0);if(0!==f&&0!==g&&(v=new Ne((0!==r?r:o.offsetX)-f/2,(0!==s?s:o.offsetY)-g/2,f,g)),h){var y=l,b=this.selectedItems.nodes?this.selectedItems.nodes[0]:void 0;if(""!==y.textAnnotation.textAnnotationTarget&&this.nameTable[y.textAnnotation.textAnnotationTarget])if(""===o.parentId||b&&b.shape&&"TextAnnotation"===b.shape.shape){if("Auto"===y.textAnnotation.textAnnotationDirection&&a.children[0]instanceof Ii&&a.children[0].children[0]instanceof Ke){var w=a.children[0],C=document.getElementById(w.id+"_groupElement"),D=document.getElementById(w.children[0].id+"_groupElement");C.removeChild(D),w.children.splice(0,1),this.isProtectedOnChange=!0,this.bpmnModule.setAnnotationPath(v,w,o,y,y.textAnnotation.textAnnotationDirection,this),this.isProtectedOnChange=!1}}else this.isPositionUndo=!0,this.updateTextAnnotationInSwimlane(o,o),this.isPositionUndo=!1;else o.inEdges.length>0&&(x=this.nameTable[""+o.inEdges[0]])&&x.isBpmnAnnotationConnector&&(x.sourcePoint={x:r>e?x.sourcePoint.x+c:x.sourcePoint.x-c,y:s>i?x.sourcePoint.y+d:x.sourcePoint.y-d});this.nodePropertyChange(o,{},R={ports:[{offset:o.ports[0].offset}]})}else for(var L=0,O=o.outEdges;Le?T.offsetX+c:T.offsetX-c,T.offsetY=s>i?T.offsetY+d:T.offsetY-d,R={offsetX:T.offsetX,offsetY:T.offsetY}),this.nodePropertyChange(T,P,R)}}}},t.prototype.updatePorts=function(e,i){if(e&&e.ports.length>0)for(var r=0,s=Object.keys(e.ports);r0)for(var i=0;i0)for(var r=0;r0&&void 0===r.segments&&(e.segments=[]),void 0!==r.shape&&void 0!==e.shape&&e.shape&&"Bpmn"===e.shape.type&&this.bpmnModule&&this.bpmnModule.updateBPMNConnector(e,i,r,this),void 0!==e.constraints?(this.updateThumbConstraints(this.selectedItems.connectors,this.selectedItems),s=!0):s},t.prototype.connectorPropertyChange=function(e,i,r,s,o){if(this.canEnableBlazorObject){var a=$(e);this.insertValue(a,!1)}var d,u,p,f,l=e.wrapper.bounds,h=!1,c=[];if(h=this.connectorProprtyChangeExtend(e,i,r,h),void 0!==r.visible&&this.updateElementVisibility(e.wrapper,e,e.visible),void 0!==r.sourcePoint||void 0!==r.targetPoint||void 0!==r.sourceID||void 0!==r.targetID||void 0!==r.targetPadding||void 0!==r.sourcePortID||void 0!==r.targetPortID||void 0!==r.sourcePadding||void 0!==r.type||void 0!==r.segments||void 0!==r.flip){if(void 0!==r.sourceID&&r.sourceID!==i.sourceID||r.sourcePortID){if(u=this.findInOutConnectPorts(g=this.nameTable[e.sourceID],!1),(!g||Nh(g)||""!==e.sourcePortID&&xd(u))&&(e.sourceWrapper=g?this.getEndNodeWrapper(g,e,!0):void 0,e.sourcePortID&&void 0===r.sourcePortID&&(e.sourcePortWrapper=g?this.getWrapper(g.wrapper,e.sourcePortID):void 0),this.removePortEdges(this.nameTable[i.sourceID]||g,i.sourcePortID||e.sourcePortID,e.id,!1)),void 0!==r.sourceID&&void 0!==i.sourceID&&""!==i.sourceID){var v=this.nameTable[i.sourceID];void 0!==v&&v.outEdges&&-1!==v.outEdges.indexOf(e.id)&&Kv(v.outEdges,e.id)}this.updateEdges(e)}if(void 0!==r.targetID&&r.targetID!==i.targetID){if(d=this.findInOutConnectPorts(y=this.nameTable[r.targetID],!0),(!y||da(y)||""!==e.targetPortID&&Lh(d))&&(e.targetWrapper=y?this.getEndNodeWrapper(y,e,!1):void 0,e.targetPortID&&void 0===r.targetPortID&&(e.targetPortWrapper=y?this.getWrapper(y.wrapper,e.targetPortID):void 0),this.removePortEdges(this.nameTable[i.targetID]||y,i.targetPortID||e.targetPortID,e.id,!0)),void 0!==i&&void 0!==i.targetID&&""!==i.targetID){var S=this.nameTable[i.targetID];void 0!==S&&S.inEdges&&-1!==S.inEdges.indexOf(e.id)&&Kv(S.inEdges,e.id)}this.updateEdges(e)}var g,y;void 0!==r.sourcePortID&&r.sourcePortID!==i.sourcePortID&&(e.sourceID&&this.nameTable[e.sourceID]&&(p=this.nameTable[e.sourceID].wrapper),!(g=this.nameTable[e.sourceID])||Nh(g)||""!==e.sourcePortID&&xd(u)?e.sourcePortWrapper=p?this.getWrapper(p,r.sourcePortID):void 0:""===e.sourcePortID&&!Nh(g)&&(e.sourcePortWrapper=void 0)),void 0!==r.targetPortID&&r.targetPortID!==i.targetPortID&&(e.targetID&&this.nameTable[e.targetID]&&(f=this.nameTable[e.targetID].wrapper),!(y=this.nameTable[e.targetID])||da(y)||""!==e.targetPortID&&Lh(d)?e.targetPortWrapper=f?this.getWrapper(f,r.targetPortID):void 0:""===e.targetPortID&&!da(y)&&(e.targetPortWrapper=void 0)),void 0!==r.flip&&(e.flip=r.flip,mF(e)),"Orthogonal"===e.type&&this.lineRoutingModule&&this.diagramActions&&this.constraints&rt.LineRouting&&!(this.diagramActions&ee.ToolAction)&&"ComplexHierarchicalTree"!==this.layout.type&&(this.lineRoutingModule.renderVirtualRegion(this,!0),e.sourceID!==e.targetID&&e.segments.length>1&&this.lineRoutingModule.refreshConnectorSegments(this,e,!1)),c=this.getPoints(e)}void 0!==r.style&&Ph(r.style,e.wrapper.children[0]),(c.length>0||void 0!==r.sourceDecorator||void 0!==r.targetDecorator&&function Rse(n){return-1!==n.indexOf("shape")||-1!==n.indexOf("pathData")||-1!==n.indexOf("width")||-1!==n.indexOf("height")}(Object.keys(r.targetDecorator))||void 0!==r.cornerRadius)&&(Zp(e,c.length>0?c:e.intermediatePoints,this.diagramActions),void 0!==r.type&&(h=!0),c.length>0&&(e.wrapper.measure(new me(e.wrapper.width,e.wrapper.height)),e.wrapper.arrange(e.wrapper.desiredSize),this.updateConnectorAnnotation(e),this.updateConnectorPort(e),this.updateConnectorfixedUserHandles(e),this.updateObject(e,i,r))),(r.sourcePoint||r.targetPoint||r.segments)&&this.diagramActions===ee.Render&&(h=!0),"Bpmn"===e.shape.type&&"Default"===e.shape.sequence&&"Sequence"===e.shape.flow&&this.commandHandler.updatePathElementOffset(e),s||this.updateBridging(),this.updateAnnotations(r,e),this.updateConnectorPorts(r,e),this.updatefixedUserHandle(r,e),e.wrapper.measure(new me(e.wrapper.width,e.wrapper.height)),e.wrapper.arrange(e.wrapper.desiredSize),!1===l.equals(l,e.wrapper.bounds)&&(this.updateQuad(e),"Drag"!==this.eventHandler.currentAction&&this.updateGroupSize(e)),!0===h&&this.checkSelectedItem(e)&&(!(this.diagramActions&ee.ToolAction)||this.diagramActions&ee.UndoRedo)&&this.updateSelector(),this.preventConnectorsUpdate||(!Ds(this)||Ds(this)&&this.scroller.oldCollectionObjects.indexOf(e.id)>-1)&&(this.diagramActions&ee.PreventZIndexOnDragging?this.updateDiagramObject(e,!0):this.updateDiagramObject(e)),this.updateConnectorEdges(e),this.diagramActions&&"New"!==e.status&&(e.status="Update"),this.triggerPropertyChange(o,e,i,r)},t.prototype.removePortEdges=function(e,i,r,s){if(e)for(var o=0;o0&&e.id===s[s.length-1].id&&(r=!0),r},t.prototype.updateDiagramContainerVisibility=function(e,i){if(e instanceof Cs)for(var r=0;r>"),r instanceof Jn&&this.updateAnnotationWrapper(r,s,o,a)),void 0!==e.template&&(r.content=e.template,this.updateAnnotationWrapper(r,s,o,a))},t.prototype.updateAnnotationWrapper=function(e,i,r,s){for(var o=0,a=this.views;o=0&&this.nodes.splice(s,1),delete this.nameTable[""+r]}var o=this.nodes.indexOf(this.nameTable[this.currentSymbol.id]);o>=0&&this.nodes.splice(o,1)}},t.prototype.selectDragedNode=function(e,i,r){this.currentSymbol=e,"SVG"!==this.mode&&this.refreshDiagramLayer(),this.commandHandler.oldSelectedObjects=tm(this),this.commandHandler.select(e),this.eventHandler.mouseDown(i.event),this.eventHandler.mouseMove(i.event,i),this.preventDiagramUpdate=!1,this.updatePage(),r.style.opacity="0"},t.prototype.initDroppables=function(){var s,o,e=this,i={},r={},a="selectedSymbols";this.droppable=new oR(this.element);var l=5;this.droppable.over=function(h){if(e.rulerSettings.showRulers){var c=document.getElementById(e.element.id+"_vRuler"),d=parseFloat(c.style.width);l=d+1}if(0===e.previousSelectedObjects.length&&!e.currentSymbol&&(e.previousSelectedObjects=e.commandHandler.getSelectedObject()),e.commandHandler.PreventConnectorSplit=!0,e.currentSymbol)h.event.touches&&h.event.touches.length&&e.eventHandler.mouseMove(h.event,h.event.touches);else{var u=null;if(!h.dragData&&"drag"===h.name){var p=document.getElementsByClassName("e-dragclone")[0];p&&(u=p)}if(h.dragData||u){var f=void 0,g=void 0;document.getElementById(e.element.id+"content").focus();var v=e.eventHandler.getMousePosition(h.event),y=void 0,S=u||h.dragData.helper,b=S.getAttribute("paletteId"),M=void 0,w=void 0,C=void 0,D=void 0;if(!b&&h.dragData){e.triggerEvent(Ce.dragEnter,A={source:null,element:f,cancel:!1,diagram:e,dragData:h.dragData.draggedElement.ej2_instances[0].dragData,dragItem:f});var x=void 0,R=void 0;if(A.dragItem){if(A.dragItem.sourcePoint&&A.dragItem.targetPoint?R=new de(e,"connectors",A.dragItem,!0):x=new te(e,"nodes",A.dragItem,!0),e.initObject(f=x||R,void 0,void 0,!0),e.enterObject=f,e.enterTable=r,f instanceof te)x.offsetX=v.x+5+x.width*x.pivot.x,x.offsetY=v.y+x.height*x.pivot.y;else if(f instanceof de){var L=Ne.toBounds([f.sourcePoint,f.targetPoint]),O=v.x-L.left,N=v.y-L.top;f.sourcePoint.x+=O,f.sourcePoint.y+=N,f.targetPoint.x+=O,f.targetPoint.y+=N}e.preventDiagramUpdate=!0,e.currentSymbol=f,"SVG"!==e.mode&&e.refreshDiagramLayer(),e.selectDragedNode(f,h,S),delete e.enterObject,delete e.enterTable,e.droppable[""+a]=S,e.allowServerDataBinding=!0}}if(b){var T=document.getElementById(b).ej2_instances[0];if(e.droppable.sourceElement=T,T){var B=T[""+a];e.allowServerDataBinding=!1,y=$(T[""+a]),i=T.childTable;var j=B.wrapper.children[0].children[0];if(D=function Hse(n,t,e){var i=bF(n,t,e,"width"),r=bF(n,t,e,"height");return new me(i,r)}(T,y,j),T[""+a]instanceof te){"TextAnnotation"===B.shape.shape?(y.offsetX=v.x+11+D.width*y.pivot.x,y.offsetY=v.y+11+D.height*y.pivot.y):(y.offsetX=v.x+5+D.width*y.pivot.x,y.offsetY=v.y+D.height*y.pivot.y),"Bpmn"===(x=new te(e,"nodes",y,!0)).shape.type&&x.shape.activity.subProcess.processes&&x.shape.activity.subProcess.processes.length&&(x.shape.activity.subProcess.processes=[]),w=x.previewSize,C=T.symbolDragSize;var Q=T.symbolPreview;if(x.width=(M=x.dragSize).width||C.width||w.width||Q.width||x.width,x.height=M.height||C.height||w.height||Q.height||x.height,"SwimLane"===x.shape.type){if(e.diagramActions|=ee.PreventHistory,x.shape.isLane){x.children=[],s={id:"header"+Qe()},"Horizontal"===x.shape.orientation?(s.width=x.shape.lanes[0].header.width,s.height=x.shape.lanes[0].height):(s.width=x.shape.lanes[0].width,s.height=x.shape.lanes[0].header.height),s.style=x.shape.lanes[0].header.style,s.offsetX=v.x+l+s.width/2,s.offsetY=v.y+s.height/2,e.diagramActions|=ee.PreventCollectionChangeOnDragOver,s=e.add(s),o={id:"body"+Qe()},"Horizontal"===x.shape.orientation?(o.width=x.shape.lanes[0].width-s.width,o.height=x.shape.lanes[0].height,o.offsetX=v.x+l+(x.shape.lanes[0].header.width+o.width/2),o.offsetY=v.y+o.height/2):(o.width=x.shape.lanes[0].width,o.height=x.shape.lanes[0].height-s.height,o.offsetX=v.x+l+o.width/2,o.offsetY=v.y+(x.shape.lanes[0].header.height+o.height/2)),o.style=x.shape.lanes[0].style,o=e.add(o);var oe={id:"group"+Qe(),children:[s.id,o.id]};oe.shape=x.shape,oe.width=x.shape.lanes[0].width,oe.height=x.shape.lanes[0].height,oe.previewSize=x.previewSize,oe.dragSize=x.dragSize,oe.addInfo=x.addInfo,x=e.add(oe),e.diagramActions&=~ee.PreventCollectionChangeOnDragOver}e.diagramActions&=~ee.PreventHistory}if(x.shape.isPhase&&((g="Horizontal"===x.shape.orientation)?(x.offsetX=v.x+l+(x.width||j.actualSize.width)/2,x.offsetY=v.y,x.shape.data="M20,"+x.height/2+" L"+(x.width-20)+","+x.height/2+"z",x.height=1):(x.offsetX=v.x+5,x.offsetY=v.y+(x.height||j.actualSize.height)/2,x.shape.data="M"+x.width/2+",20 L"+x.width/2+","+(x.height-20)+"z",x.width=1)),"UmlClassifier"===x.shape.type&&(x.children=x.width=x.height=void 0,y.children=void 0,"Class"===x.shape.classifier&&x.shape.classShape.methods.length<=0&&x.shape.classShape.attributes.length<=0&&(x.shape.classShape.attributes=[{name:"Name",type:"Type",style:{}}]),"Enumeration"===x.shape.classifier&&x.shape.enumerationShape.members.length<=0&&(x.shape.enumerationShape.members=[{name:"Name"}]),"Interface"===x.shape.classifier&&x.shape.interfaceShape.methods.length<=0&&x.shape.interfaceShape.attributes.length<=0&&(x.shape.interfaceShape.attributes=[{name:"Name",type:"Type",style:{}}])),f=x,y.children){var ue=y;r=e.getChildren(ue,{},i),Kx(ue,-ue.offsetX,-ue.offsetY,r,!0,e)}}else if(T[""+a]instanceof de){f=new de(e,"connectors",y,!0);var Me=Ne.toBounds([f.sourcePoint,f.targetPoint]),De=v.x-Me.left,xe=v.y-Me.top;f.sourcePoint.x+=De,f.sourcePoint.y+=xe,f.targetPoint.x+=De,f.targetPoint.y+=xe}f.shape.isLane||(f.id+=Qe());var A={source:T,element:f,cancel:!1,diagram:e,dragData:null,dragItem:f};if(e.enterObject=f,e.enterTable=r,e.triggerEvent(Ce.dragEnter,A),f instanceof te&&"SwimLane"===f.shape.type&&f.shape.isLane){var Ie=A.element,Ve=Ie.shape.lanes[0];g="Horizontal"===Ie.shape.orientation;var ot=e.nameTable[f.children[0]],$e=e.nameTable[f.children[1]];w=f.previewSize,C=T.symbolDragSize,Ve.width=(M=f.dragSize).width||C.width||w.width||Ve.width,Ve.height=M.height||C.height||w.height||Ve.height,g?(s.width=Ve.header.width,s.height=Ve.height,o.width=Ve.width-s.width,o.height=Ve.height,o.offsetX=v.x+l+(Ve.header.width+$e.width/2),o.offsetY=v.y+$e.height/2):(s.width=Ve.width,s.height=Ve.header.height,o.width=Ve.width,o.height=Ve.height-s.height,o.offsetX=v.x+l+$e.width/2,o.offsetY=v.y+(Ve.header.height+$e.height/2)),s.offsetX=v.x+l+ot.width/2,s.offsetY=v.y+ot.height/2,f.width=Ve.width,f.height=Ve.height}if(f instanceof te&&f.shape.isPhase&&(g?f.height=1:f.width=1),!e.activeLayer.lock&&!A.cancel){if(e.preventDiagramUpdate=!0,f.children&&e.findChild(f,r),e.preventDiagramUpdate=!0,f.zIndex!==Number.MIN_VALUE&&(f.zIndex=Number.MIN_VALUE),e.initObject(f,void 0,void 0,!0),e.bpmnModule)for(var Mi=0;Mi0&&(S.segments=[]),d=this.add(S,!0)),(S||d)&&(Bv(this)||Fv(this))&&this.select([this.nameTable[S[""+b]]],!1,this.previousSelectedObjects),y.target&&y.target instanceof de&&!0===this.enableConnectorSplit&&this.nameTable[S[""+b]]instanceof te&&(this.commandHandler.connectorSplit(this.nameTable[S[""+b]],y.target),this.commandHandler.PreventConnectorSplit=!1))),this.protectPropertyChange(!1),v=this.nameTable[S[""+b]],S.hasTarget&&(S.nodeId=S.hasTarget,this.remove(S)),this.bpmnModule&&v instanceof te&&S.processId&&(v.processId=S.processId,this.bpmnModule.dropBPMNchild(this.nameTable[v.processId],v,this)),y.cancel||this.endGroupAction(),"SVG"!==this.mode&&this.refreshDiagramLayer(),delete this.droppable[""+c]):(this.triggerEvent(Ce.drop,y={source:h.droppedElement,element:void 0,target:this.eventHandler.hoverNode||this.eventHandler.lastObjectUnderMouse||this,cancel:!1,position:void 0}),S=void 0,b="id"),this.droppable[M="selectedSymbols"]&&this.droppable[""+M].parentNode)gt(this.droppable[""+M]);else for(w=document.getElementsByClassName("e-dragclone"),C=0;C0)for(var p=0;p1),e.previousSelectedObject=null}}},t.prototype.getDropEventArgs=function(e){if(this.eventHandler.lastObjectUnderMouse||this.eventHandler.hoverNode){var i=this.eventHandler.lastObjectUnderMouse||this.eventHandler.hoverNode;e.target=fs(i)===de?{connector:i}:{node:i}}else e.target.diagramId=this.element.id},t.prototype.removeChildInNodes=function(e){if(e){if(e.children)for(var i=0;i1){var l=2;if(e.children&&e.children.length>0)for(;e.children.indexOf(i.objects[s-l])>-1;)l++;this.commandHandler.moveSvgNode(e.id,i.objects[s-l]),this.commandHandler.moveSvgNode(i.objects[s-l],e.id)}else if(o){var h=this.commandHandler.getLayer(this.layerZIndexTable[o.zIndex]).objects[0];h?(this.commandHandler.moveSvgNode(e.id,h),this.commandHandler.updateNativeNodeIndex(e.id,h)):this.moveObjectsUp(e,i)}else this.moveObjectsUp(e,i)},t.prototype.moveObjectsUp=function(e,i){for(var r,s=this.layers.length-1;s>=0;s--)if(r=this.layers[parseInt(s.toString(),10)],i.id!==r.id){var o=this.commandHandler.getLayer(this.layerZIndexTable[r.zIndex]).objects[r.objects.length-1];if(o){this.commandHandler.moveSvgNode(e.id,o),this.commandHandler.moveSvgNode(o,e.id);break}}},t.prototype.insertData=function(e){return this.crudOperation(e,"create",this.getNewUpdateNodes("New"))},t.prototype.updateData=function(e){return this.crudOperation(e,"update",this.getNewUpdateNodes("Update"))},t.prototype.removeData=function(e){return this.crudOperation(e,"destroy",this.getDeletedNodes())},t.prototype.crudOperation=function(e,i,r){if(e){var s=this.parameterMap(e,!(e instanceof de));if(s){var o=e instanceof de?this.dataSourceSettings.connectionDataSource.crudAction[""+i]:this.dataSourceSettings.crudAction[""+i];this.raiseAjaxPost(JSON.stringify(s),o)}return s}var a=r;return this.processCrudCollection(a,this.dataSourceSettings.crudAction[""+i],this.dataSourceSettings.connectionDataSource.crudAction[""+i]),a},t.prototype.processCrudCollection=function(e,i,r){if(e.nodes){var s=[],o=void 0;for(o=0;o0&&this.raiseAjaxPost(JSON.stringify(s),i)}if(e.connectors){for(s=[],o=void 0,o=0;o0&&this.raiseAjaxPost(JSON.stringify(s),r)}},t.prototype.parameterMap=function(e,i){var s,r={},o=i?this.dataSourceSettings:this.dataSourceSettings.connectionDataSource;if(o.id&&(r[o.id]=e.id),o.sourcePointX&&o.sourcePointY&&(r[o.sourcePointX]=e.sourcePoint.x,r[o.sourcePointY]=e.sourcePoint.y),o.targetPointX&&o.targetPointY&&(r[o.targetPointX]=e.targetPoint.x,r[o.targetPointY]=e.targetPoint.y),o.sourceID&&(r[o.sourceID]=e.sourceID),o.targetID&&(r[o.targetID]=e.targetID),o.crudAction&&o.crudAction.customFields&&o.crudAction.customFields.length>0)for(s=0;s0&&(l=a.length),r.annotations=[{content:o.data.label[parseInt(l.toString(),10)]}]}s=this.getConnectorArrowType(o.data)}var h=new de(i,"connectors",r,!0);return s&&(h.style.strokeWidth=s.strokeWidth,h.targetDecorator.shape=s.targetDecorator),Ro(h,r,i.connectorDefaults),h},n.prototype.getConnectorArrowType=function(t){if(""===t.arrowType)return{targetDecorator:"Arrow",strokeWidth:1};switch(t.arrowType){case"None":return{targetDecorator:"None",strokeWidth:1};case"Arrow":default:return{targetDecorator:"Arrow",strokeWidth:1};case"Diamond":return{targetDecorator:"Diamond",strokeWidth:1};case"Circle":return{targetDecorator:"Circle",strokeWidth:1};case"OpenArrow":return{targetDecorator:"OpenArrow",strokeWidth:1};case"Square":return{targetDecorator:"Square",strokeWidth:1};case"Fletch":return{targetDecorator:"Fletch",strokeWidth:1};case"OpenFetch":return{targetDecorator:"OpenFetch",strokeWidth:1};case"IndentedArrow":return{targetDecorator:"IndentedArrow",strokeWidth:1};case"OutdentedArrow":return{targetDecorator:"OutdentedArrow",strokeWidth:1};case"DoubleArrow":return{targetDecorator:"DoubleArrow",strokeWidth:1}}},n}(),uae=function(){function n(){this.protectChange=!1,this.setIntervalObject=[]}return n.prototype.expand=function(t,e,i,r){var s=this,a=0;if(r.realActions=r.realActions|$i.AnimationClick,this.setIntervalObject[parseInt((0).toString(),10)]=setInterval(function(){return a++,s.layoutAnimation(e,s.setIntervalObject,6===a,r,i)},20),i.isExpanded){var l=.2;r.protectPropertyChange(!1);var h={};t&&(this.updateOpacity(i,l,r),h[parseInt((0).toString(),10)]=setInterval(function(){r.allowServerDataBinding=!1,l<=1?s.updateOpacity(i,l,r):clearInterval(h[0]),l+=.2,r.allowServerDataBinding=!0},20))}},n.prototype.stopCurrentAnimation=function(t,e,i){clearInterval(this.setIntervalObject[0]),this.setIntervalObject=[];for(var r=0;r0){t.rootNode=t.firstLevelNodes[0];var u=0,p=0,f=void 0,g=void 0,v=void 0,y=void 0,S=void 0;for(a=0;ad.y||(l.y=d.y),l.mid&&(e=l.mid),l.tree.assistants.length&&(y=this.setBreadthSpaceForAssistants(t,r,d,void 0!==e?e:d.x,b,s),u||(e=((g=p=y).x+g.right)/2-d.width/2,p=g),v=y?y.canMoveBy:void 0),l.x=e,l.translate||(l.treeWidth=p.right-p.x),this.translateSubTree({layout:t,shape:r,shapeBounds:{x:e,y:d.y,right:e+d.width,bottom:d.y+d.height},treeBounds:p,dim:d,level:s},v,void 0!==o,a),l.firstChild&&"string"!=typeof l.firstChild&&(l.firstChild.x+=l.subTreeTranslation),r.treeBounds=p,p},n.prototype.updateLeafNode=function(t,e,i,r,s,o){var a=t.graphNodes[e.id];a.x=r.x,a.y&&a.y>r.y||(a.y=r.y,a.maxLevel=Math.max(s,a.maxLevel||0));var l={x:r.x,y:r.y,right:r.x+r.width,bottom:r.y+r.height};return a.maxLevel=Math.max(a.maxLevel||0,s),this.translateSubTree({layout:t,shape:e,shapeBounds:l,treeBounds:l,dim:r,level:s},void 0,void 0!==i,o),{x:a.x,y:a.y,right:a.x+r.width,bottom:a.y+r.height}},n.prototype.setUpLayoutInfo=function(t,e){var i={subTreeTranslation:0};return i.tree="OrganizationalChart"===t.type?{orientation:"Vertical",type:"Alternate",offset:20,enableRouting:!0}:{orientation:"Horizontal",type:"Center",enableRouting:!0},i.tree.children=[],i.tree.assistants=[],i.tree.level=0,i.translate=!0,i},n.prototype.translateSubTree=function(t,e,i,r){var s=t.layout,o=t.shape,a=t.shapeBounds,l=t.treeBounds,h=t.level,c=t.dim,d=s.graphNodes[o.id],u=s.nameTable[d.firstChild?d.firstChild.child:d.tree.children[0]],p=u?s.graphNodes[u.id]:null,f=this.hasChild(s,o),g=this.findIntersectingLevels(s,a,h,d.actualLevel),v=this.findIntersectingLevels(s,l,h,d.actualLevel),y=[];g.length&&d.translate?(d.intersect=g,this.spaceLeftFromPrevSubTree(s,o,a),d.canMoveBy=d.diff,void 0!==e&&(d.canMoveBy=Math.min(e,d.canMoveBy)),u&&void 0!==p.canMoveBy&&(p.canMoveBy>=d.canMoveBy&&(d.translated=!0),d.canMoveBy=Math.min(d.canMoveBy,p.canMoveBy)),i&&(d.x-=d.canMoveBy,d.subTreeTranslation-=d.canMoveBy,f&&(this.shiftSubordinates(s,v,d.canMoveBy),l.x=Math.min(l.x,d.x),l.right=Math.max(l.right,d.x+c.width),l.bottom=Math.max(l.bottom,d.y+c.height),l.x-=d.canMoveBy,l.right-=d.canMoveBy),u&&p.canMoveBy>d.canMoveBy?d.canMoveBy=p.canMoveBy-d.canMoveBy:u&&void 0!==d.canMoveBy&&(d.canMoveBy=0))):(f&&(l.x=Math.min(l.x,a.x),l.right=Math.max(l.right,a.x+c.width),l.bottom=Math.max(l.bottom,d.y+c.height)),d.translate||(d.canMoveBy=0,d.subTreeTranslation=0)),r||(y.push({rBounds:a={x:d.x,y:c.y,right:d.x+c.width,bottom:c.y+c.height}}),this.updateRearBounds(s,o,y,h))},n.prototype.updateRearBounds=function(t,e,i,r,s){var o,a,h,d,l=!0,c={};e&&(s=(c=t.graphNodes[e.id]).intersect,l=!c.tree.children.length&&!c.tree.assistants.length);var u=i[0].rBounds,p=i[i.length-1].rBounds;if(s&&s.length){for(d=(o=t.levels[s[0]].rBounds).bottom,o.yp.bottom?i.push({rBounds:{x:o.x,right:o.right,y:u.bottom,bottom:d}}):(o=t.levels[s[s.length-1]].rBounds,l&&o.bottom>p.bottom&&(o.y=p.bottom,i.push({rBounds:o}))),a=s[0],h=i.length-1;h>=0;h--)t.levels.splice(a,0,i[parseInt(h.toString(),10)]);t.levels.splice(a+=i.length,s.length)}else for(a=this.findLevel(t,i[i.length-1].rBounds,r),h=i.length-1;h>=0;h--)t.levels.splice(a,0,i[parseInt(h.toString(),10)])},n.prototype.shiftSubordinates=function(t,e,i){var r;if(0!==i)for(r=0;rA.right&&(A.right=M.right),A.bottom=M.bottom):A=M,0===x&&(l.firstChild={x:R.x,canMoveBy:R.canMoveBy,child:g.id}),this.hasChild(t,g)&&(!l.firstChild||l.firstChild.x>=R.firstChild.x?(R.firstChild&&l.firstChild.canMoveByR.canMoveBy&&(l.firstChild.canMoveBy=t.graphNodes[l.firstChild.child].canMoveBy=R.canMoveBy)),w=w?Math.max(R.maxLevel,w):R.maxLevel,this.uniteRects(b,v),d=0!==x&&!this.hasChild(t,g)&&R.subTreeTranslation<0?v.right-R.subTreeTranslation+t.horizontalSpacing:v.right+t.horizontalSpacing;isNaN(C)||(L.canMoveBy=C),l.mid=(L.x+A.right)/2-a.width/2,"Left"===h?l.mid=M.right-a.width:"Right"===h&&(l.mid=r)}return b},n.prototype.updateHorizontalTreeWithMultipleRows=function(t,e,i,r,s,o){var a,l,h,c,d,f,g,v,y,S=this.getDimensions(t,e,r,s,o),b=t.graphNodes[e.id],w=o,C=r,D=s,x=(t.levels.slice(0,t.levels.length),0);if(this.hasChild(t,e)){var R=-1!==t.orientation.indexOf("Left"),L=void 0,O=this.splitChildrenInRows(t,e),N=5===b.tree.children.length&&3===O[0].length,T=[],P=[];N?P=O:this.splitRows(O,T,P);var _={leftTree:T,rows:O,rightTree:P,dimensions:S},B=this.updateLeftTree(t,_,e,r,D,w);d=_.bounds;var j=void 0;void 0!==B&&(b.mid=(B||0)+(void 0!==B?t.horizontalSpacing/2:0)-S.width/2,j=B+t.horizontalSpacing),D=s;var oe=void 0;for(oe=[],g=0;gl.canMoveBy)&&(x=Math.min(x,l.canMoveBy||0),b.firstChild={x:l.x,child:a.id,canMoveBy:l.canMoveBy}),_.leftCenter=v,_.rightCenter=y,_.align=L,_.level=w,_.rightBounds=oe,this.alignRowsToCenter(t,g,e,_,j)}return d},n.prototype.updateLeftTree=function(t,e,i,r,s,o){for(var h,d,u,p,f,a=e.leftTree,l=t.graphNodes[i.id],c=[],v=(t.orientation.indexOf("Left"),0);vw.canMoveBy&&(d=Math.min(d,w.canMoveBy||0),l.firstChild={x:w.x,child:S.id,canMoveBy:w.canMoveBy}),h=p.right+t.horizontalSpacing}u=0===v?c[parseInt(v.toString(),10)].right:Math.max(u,c[parseInt(v.toString(),10)].right)}for(v=0;v=g[1].right-g[1].x?0:1),e===c.length-1&&(c[parseInt(e.toString(),10)].length%2==1||S&&1===e)){a=d[parseInt(e.toString(),10)][Math.floor(d[parseInt(e.toString(),10)].length/2)];var M=t.graphNodes[""+a].x,C=this.getDimensions(t,t.nameTable[""+a],M,t.graphNodes[""+a].y,y+1);l=void 0,!f&&S?(1===o&&(e=0),l=(g[parseInt(o.toString(),10)].x+g[parseInt(o.toString(),10)].right)/2-(g[parseInt(e.toString(),10)].x+g[parseInt(e.toString(),10)].right)/2,0===e&&(h.mid+=l)):!S&&void 0!==s&&(l=s-t.horizontalSpacing/2-(M+C.width/2)),void 0!==l&&this.updateRearBoundsOfTree(t,d[parseInt(e.toString(),10)],l,v),S&&(h.mid=(p+u)/2+(0===e?l:0)-v.width/2),void 0===h.mid&&t.graphNodes[""+a]&&(h.mid=M),f=!1,e++}},n.prototype.updateRearBoundsOfTree=function(t,e,i,r){for(var s=0;s2?"Left":"Right",M=A%2==0&&y.tree.children.length>2?-1:0),w=i+this.findOffset(t,e,y,R),a=t.nameTable[y.tree.children[parseInt(A.toString(),10)]],d=b?a.actualSize.width:a.actualSize.height,h=this.updateTree(t,w+M*(c=b?a.actualSize.height:a.actualSize.width),C,a,s+1,void 0,!0),f={x:(l=t.graphNodes[a.id]).x,y:l.y,right:l.x+c,bottom:l.y+d},0===A?(this.uniteRects(h,f),p=h):this.uniteRects(p,h),l.prevBounds&&!("Alternate"===y.tree.type&&A%2==1&&y.tree.children.length>2)&&(N=void 0!==N?Math.min(l.canMoveBy,N):l.canMoveBy),y.maxLevel=Math.max(y.maxLevel||0,l.maxLevel||0),"Alternate"===y.tree.type&&y.tree.children.length>2&&A%2==0?(0!==A&&(C=u.bottom+t.verticalSpacing/2),O.push({rBounds:f}),l.levelBounds&&(O=O.concat(l.levelBounds))):(C="Alternate"===y.tree.type&&y.tree.children.length>2?Math.max(h.bottom,u.bottom)+t.verticalSpacing/2:h.bottom+t.verticalSpacing/2,s=y.maxLevel,L.push({rBounds:f}),v?this.uniteRects(v,f):v={x:l.x,y:l.y,right:l.x+c,bottom:l.y+d},l.levelBounds&&(L=L.concat(l.levelBounds))),0===A&&(y.firstChild={x:l.x,canMoveBy:l.canMoveBy,child:a.id}),this.hasChild(t,a))if(!y.firstChild||y.firstChild.x>=l.firstChild.x){if(l.firstChild&&y.firstChild.canMoveByl.canMoveBy&&(y.firstChild.canMoveBy=t.graphNodes[y.firstChild.child].canMoveBy=l.canMoveBy);u=f}return o?y.levelBounds=L:("Alternate"===y.tree.type&&y.tree.children.length>2&&(x=this.findIntersectingLevels(t,{x:O[0].rBounds.x,y:O[0].rBounds.y,right:O[O.length-1].rBounds.right,bottom:O[O.length-1].rBounds.bottom},D+1),this.updateRearBounds(t,null,O,D+1,x)),x=this.findIntersectingLevels(t,v||p,D+1),this.updateRearBounds(t,null,v?L:[{rBounds:p}],D+1,x)),isNaN(N)||(t.graphNodes[S.id].canMoveBy=N),y.childBounds=p,y.mid=i,p},n.prototype.splitChildrenInRows=function(t,e){var r,i=t.graphNodes[e.id];r=4;var o,s=[];o=i.tree.children.length;var a=this.extend(i.tree.children);if(i.tree.rows){var h=i.tree.rows;r=h%2==0?h:h-1}else 3===i.tree.children.length||4===i.tree.children.length?r=2:5===i.tree.children.length&&(r=3);for(;o>0;)s[s.length]=a.splice(0,r),(o-=r)=t.horizontalSpacing&&(s=t.horizontalSpacing/2),r||i.tree.type){case"Left":s=o/2-s;break;case"Right":s+=o/2}return s},n.prototype.uniteRects=function(t,e){t.x=Math.min(t.x,e.x),t.right=Math.max(t.right,e.right),t.bottom=Math.max(t.bottom,e.bottom)},n.prototype.spaceLeftFromPrevSubTree=function(t,e,i){for(var s,o,r=t.graphNodes[e.id],a=t.horizontalSpacing,l=0;la.y||s.y=a.y&&s.bottom<=a.bottom||s.ya.bottom))o.splice(0,0,l);else if(a&&a.bottom=0);l=(void 0!==r?r:i)+1,a=t.levels[parseInt(l.toString(),10)]?t.levels[parseInt(l.toString(),10)].rBounds:null;do{if(a&&(s.ya.y||s.y=a.y&&s.bottom<=a.bottom||s.ya.bottom))o.push(l);else if(a&&a.y>s.bottom)break;l++,a=t.levels[parseInt(l.toString(),10)]?t.levels[parseInt(l.toString(),10)].rBounds:null}while(l<=t.levels.length);return o},n.prototype.findLevel=function(t,e,i){var s,o,r=e;for(s=0,o=t.levels[parseInt(s.toString(),10)]?t.levels[parseInt(s.toString(),10)].rBounds:null;s=t.level&&(o.tree.hasSubTree=!1)},n.prototype.updateAnchor=function(t,e,i){var r,s,o=0,a=0,l=0,h=0,c=new Ne(0,0,i.x,i.y),d=t.bounds?t.bounds:c,u=t.orientation;if(t.fixedNode){o=(s=t.nameTable[t.fixedNode]).actualSize.width,a=s.actualSize.height,t.anchorX=s.offsetX,t.anchorY=s.offsetY;var p=s.pivot;for(t.anchorX+="RightToLeft"===t.orientation?o*p.x:-o*p.x,t.anchorY+="BottomToTop"===t.orientation?a*p.y:-a*p.y,r=s,l=0;r.inEdges.length;)r=this.getParentNode(t,r),l+=t.graphNodes[r.id].subTreeTranslation||0;-1!==t.orientation.indexOf("Left")?(h=t.graphNodes[s.id].y,"LeftToRight"===u?t.anchorX-=h:t.anchorX+=h,t.anchorY-=t.graphNodes[s.id].x+l):(h=t.graphNodes[s.id].y,t.anchorX-=t.graphNodes[s.id].x+l,"TopToBottom"===u?t.anchorY-=h:t.anchorY+=h)}else if("TopToBottom"===u||"BottomToTop"===u){switch(t.horizontalAlignment){case"Left":t.anchorX=d.x-e.x+t.margin.left;break;case"Right":t.anchorX=d.x+d.width-t.margin.right-e.right;break;case"Auto":case"Center":t.anchorX=d.x+d.width/2-(e.x+e.right)/2}switch(t.verticalAlignment){case"Auto":case"Top":var f;f=d.y+t.margin.top,t.anchorY="TopToBottom"===u?f:e.bottom+f;break;case"Bottom":var g;g=d.y+d.height-t.margin.bottom,t.anchorY="TopToBottom"===u?g-e.bottom:g;break;case"Center":var v=void 0;v=d.y+d.height/2,t.anchorY="TopToBottom"===t.orientation?v-(e.y+e.bottom)/2:v+(e.y+e.bottom)/2}}else{switch(t.horizontalAlignment){case"Auto":case"Left":var y;y=d.x+t.margin.left,t.anchorX="LeftToRight"===u?y:e.bottom+y;break;case"Right":var S;S=d.x+d.width-t.margin.right,t.anchorX="LeftToRight"===u?S-e.bottom:S;break;case"Center":v=void 0,v=d.width/2+d.x,t.anchorX="LeftToRight"===t.orientation?v-(e.y+e.bottom)/2:v+(e.y+e.bottom)/2}switch(t.verticalAlignment){case"Top":t.anchorY=d.y+t.margin.top-e.x;break;case"Auto":case"Center":t.anchorY=d.y+d.height/2-(e.right+e.x)/2;break;case"Bottom":t.anchorY=d.y+d.height-t.margin.bottom-e.right}}},n.prototype.updateConnectors=function(t,e,i){var r,s,o,a=t.graphNodes[e.id];if(e.outEdges.length)for(r=0;r2){l=o.tree.children[1],isNaN(t.graphNodes[""+l].treeWidth)&&(t.graphNodes[""+l].treeWidth=t.nameTable[""+l].actualSize.width);t.orientation.indexOf("Left"),this.getSegmentsForMultipleRows(t,i,r,e)}else o.tree.children.length>5?s<4||si.offsetX?a.middleRight:a.middleLeft).y},h)}else{var h;l=0===t.orientation.indexOf("Left")?o.middleRight:o.middleLeft,s.push(l,{x:a.bottomCenter.x,y:o.middleRight.y},h=e.offsetY>i.offsetY?a.bottomCenter:a.topCenter)}this.getSegmentsFromPoints(s,r)},n.prototype.get5Points=function(t,e,i,r){var l,h,c,d,s=[],o=this.getBounds(e),a=this.getBounds(i);-1!==t.orientation.indexOf("Top")?s.push(l=e.offsetYi.offsetX?a.middleRight:a.middleLeft).x+(c=t.horizontalSpacing/2*(e.offsetX>i.offsetX?1:-1)),y:l.y+d},{x:h.x+c,y:h.y},h):s.push(l=e.offsetX>i.offsetX?o.middleLeft:o.middleRight,{x:l.x+(c=t.horizontalSpacing/4*(e.offsetXi.offsetY?1:-1))},{x:(h=e.offsetY>i.offsetY?a.bottomCenter:a.topCenter).x,y:l.y+d},h),this.getSegmentsFromPoints(s,r)},n.prototype.getSegmentsFromPoints=function(t,e){for(var r,i=[],s=0;s"u"||(y.innerHTML=v.innerHTML?v.innerHTML:"",void 0!==v.className&&(y.className=v.className),void 0!==v.id&&(y.id=v.id),void 0!==v.styles&&y.setAttribute("style",v.styles),void 0!==e.ngAttr&&y.setAttribute(e.ngAttr,""),void 0!==v.attrs&&Fe(y,v.attrs)),y};for(var i=0,r=e.tags;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s}!function CZ(n){wC.compile=n.compile}({compile:function Hae(n,t){if("string"==typeof n||"function"==typeof n&&n.prototype&&n.prototype.CSPTemplate)return Rae(n,t);var e=n.elementRef.nativeElement._viewContainerRef,i=n.elementRef.nativeElement.propName;return function(r,s,o){var l=e||s.viewContainerRef,h=l.createEmbeddedView(n,{$implicit:r});/EJS-MENTION|EJS-DROPDOWNLIST/.test(Y("currentInstance.element.nodeName",l))||/E-TABITEM/.test(Y("element.nativeElement.nodeName",l))?h.detectChanges():h.markForCheck();var c=s&&s.registeredTemplate?s.registeredTemplate:Y("currentInstance.registeredTemplate",l);return typeof c["".concat(o=o&&s.registeredTemplate?o:i)]>"u"&&(c["".concat(o)]=[]),c["".concat(o)].push(h),h.rootNodes}}});const jae=["annotationTemplate"],Vae=["nodeTemplate"],Wae=["userHandleTemplate"];let Yae=["addInfo","id","lock","objects","visible","zIndex"],Qae=[],Gae=(()=>{class n extends Hh{constructor(e){super(),this.viewContainerRef=e,Rl("currentInstance",this,this.viewContainerRef),this.registerEvents(Qae),this.directivePropList=Yae}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-layer"]],inputs:{addInfo:"addInfo",id:"id",lock:"lock",objects:"objects",visible:"visible",zIndex:"zIndex"},features:[yn]}),n})(),Xae=(()=>{class n extends Bh{constructor(){super("layers")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-layers"]],contentQueries:function(e,i,r){if(1&e&&dn(r,Gae,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),qae=["action","cursor"],$ae=[],Zae=(()=>{class n extends Hh{constructor(e){super(),this.viewContainerRef=e,Rl("currentInstance",this,this.viewContainerRef),this.registerEvents($ae),this.directivePropList=qae}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-cursormap"]],inputs:{action:"action",cursor:"cursor"},features:[yn]}),n})(),Jae=(()=>{class n extends Bh{constructor(){super("customcursor")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-cursormaps"]],contentQueries:function(e,i,r){if(1&e&&dn(r,Zae,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),Kae=["alignment","cornerRadius","displacement","fill","handleStrokeColor","handleStrokeWidth","height","iconStrokeColor","iconStrokeWidth","id","offset","padding","pathData","tooltip","visibility","width"],ele=[],tle=(()=>{class n extends Hh{constructor(e){super(),this.viewContainerRef=e,Rl("currentInstance",this,this.viewContainerRef),this.registerEvents(ele),this.directivePropList=Kae}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-connector-fixeduserhandle"]],inputs:{alignment:"alignment",cornerRadius:"cornerRadius",displacement:"displacement",fill:"fill",handleStrokeColor:"handleStrokeColor",handleStrokeWidth:"handleStrokeWidth",height:"height",iconStrokeColor:"iconStrokeColor",iconStrokeWidth:"iconStrokeWidth",id:"id",offset:"offset",padding:"padding",pathData:"pathData",tooltip:"tooltip",visibility:"visibility",width:"width"},features:[yn]}),n})(),ile=(()=>{class n extends Bh{constructor(){super("fixeduserhandles")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-connector-fixeduserhandles"]],contentQueries:function(e,i,r){if(1&e&&dn(r,tle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),rle=["addInfo","alignment","annotationType","constraints","content","displacement","dragLimit","height","horizontalAlignment","hyperlink","id","margin","offset","rotateAngle","rotationReference","segmentAngle","style","template","tooltip","type","verticalAlignment","visibility","width"],nle=[],sle=(()=>{class n extends Hh{constructor(e){super(),this.viewContainerRef=e,Rl("currentInstance",this,this.viewContainerRef),this.registerEvents(nle),this.directivePropList=rle}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-connector-annotation"]],inputs:{addInfo:"addInfo",alignment:"alignment",annotationType:"annotationType",constraints:"constraints",content:"content",displacement:"displacement",dragLimit:"dragLimit",height:"height",horizontalAlignment:"horizontalAlignment",hyperlink:"hyperlink",id:"id",margin:"margin",offset:"offset",rotateAngle:"rotateAngle",rotationReference:"rotationReference",segmentAngle:"segmentAngle",style:"style",template:"template",tooltip:"tooltip",type:"type",verticalAlignment:"verticalAlignment",visibility:"visibility",width:"width"},features:[yn]}),n})(),ole=(()=>{class n extends Bh{constructor(){super("annotations")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-connector-annotations"]],contentQueries:function(e,i,r){if(1&e&&dn(r,sle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),ale=["addInfo","allowNodeOverlap","annotations","bezierSettings","bridgeSpace","connectionPadding","connectorSpacing","constraints","cornerRadius","dragSize","excludeFromLayout","fixedUserHandles","flip","flipMode","hitPadding","id","margin","maxSegmentThumb","ports","previewSize","segmentThumbShape","segmentThumbSize","segments","shape","sourceDecorator","sourceID","sourcePadding","sourcePoint","sourcePortID","style","symbolInfo","targetDecorator","targetID","targetPadding","targetPoint","targetPortID","tooltip","type","visible","wrapper","zIndex"],lle=[],hle=(()=>{class n extends Hh{constructor(e){super(),this.viewContainerRef=e,this.tags=["fixedUserHandles","annotations"],Rl("currentInstance",this,this.viewContainerRef),this.registerEvents(lle),this.directivePropList=ale}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-connector"]],contentQueries:function(e,i,r){if(1&e&&(dn(r,ile,5),dn(r,ole,5)),2&e){let s;Kr(s=en())&&(i.childFixedUserHandles=s.first),Kr(s=en())&&(i.childAnnotations=s.first)}},inputs:{addInfo:"addInfo",allowNodeOverlap:"allowNodeOverlap",annotations:"annotations",bezierSettings:"bezierSettings",bridgeSpace:"bridgeSpace",connectionPadding:"connectionPadding",connectorSpacing:"connectorSpacing",constraints:"constraints",cornerRadius:"cornerRadius",dragSize:"dragSize",excludeFromLayout:"excludeFromLayout",fixedUserHandles:"fixedUserHandles",flip:"flip",flipMode:"flipMode",hitPadding:"hitPadding",id:"id",margin:"margin",maxSegmentThumb:"maxSegmentThumb",ports:"ports",previewSize:"previewSize",segmentThumbShape:"segmentThumbShape",segmentThumbSize:"segmentThumbSize",segments:"segments",shape:"shape",sourceDecorator:"sourceDecorator",sourceID:"sourceID",sourcePadding:"sourcePadding",sourcePoint:"sourcePoint",sourcePortID:"sourcePortID",style:"style",symbolInfo:"symbolInfo",targetDecorator:"targetDecorator",targetID:"targetID",targetPadding:"targetPadding",targetPoint:"targetPoint",targetPortID:"targetPortID",tooltip:"tooltip",type:"type",visible:"visible",wrapper:"wrapper",zIndex:"zIndex"},features:[yn]}),n})(),cle=(()=>{class n extends Bh{constructor(){super("connectors")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-connectors"]],contentQueries:function(e,i,r){if(1&e&&dn(r,hle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),dle=["cornerRadius","fill","handleStrokeColor","handleStrokeWidth","height","iconStrokeColor","iconStrokeWidth","id","margin","offset","padding","pathData","tooltip","visibility","width"],ule=[],ple=(()=>{class n extends Hh{constructor(e){super(),this.viewContainerRef=e,Rl("currentInstance",this,this.viewContainerRef),this.registerEvents(ule),this.directivePropList=dle}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-node-fixeduserhandle"]],inputs:{cornerRadius:"cornerRadius",fill:"fill",handleStrokeColor:"handleStrokeColor",handleStrokeWidth:"handleStrokeWidth",height:"height",iconStrokeColor:"iconStrokeColor",iconStrokeWidth:"iconStrokeWidth",id:"id",margin:"margin",offset:"offset",padding:"padding",pathData:"pathData",tooltip:"tooltip",visibility:"visibility",width:"width"},features:[yn]}),n})(),fle=(()=>{class n extends Bh{constructor(){super("fixeduserhandles")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-node-fixeduserhandles"]],contentQueries:function(e,i,r){if(1&e&&dn(r,ple,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),gle=["addInfo","annotationType","constraints","content","dragLimit","height","horizontalAlignment","hyperlink","id","margin","offset","rotateAngle","rotationReference","style","template","tooltip","type","verticalAlignment","visibility","width"],vle=[],mle=(()=>{class n extends Hh{constructor(e){super(),this.viewContainerRef=e,Rl("currentInstance",this,this.viewContainerRef),this.registerEvents(vle),this.directivePropList=gle}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-node-annotation"]],inputs:{addInfo:"addInfo",annotationType:"annotationType",constraints:"constraints",content:"content",dragLimit:"dragLimit",height:"height",horizontalAlignment:"horizontalAlignment",hyperlink:"hyperlink",id:"id",margin:"margin",offset:"offset",rotateAngle:"rotateAngle",rotationReference:"rotationReference",style:"style",template:"template",tooltip:"tooltip",type:"type",verticalAlignment:"verticalAlignment",visibility:"visibility",width:"width"},features:[yn]}),n})(),yle=(()=>{class n extends Bh{constructor(){super("annotations")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-node-annotations"]],contentQueries:function(e,i,r){if(1&e&&dn(r,mle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),Sle=["addInfo","connectionDirection","constraints","height","horizontalAlignment","id","inEdges","margin","offset","outEdges","pathData","shape","style","tooltip","verticalAlignment","visibility","width"],Ile=[],ble=(()=>{class n extends Hh{constructor(e){super(),this.viewContainerRef=e,Rl("currentInstance",this,this.viewContainerRef),this.registerEvents(Ile),this.directivePropList=Sle}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-node-port"]],inputs:{addInfo:"addInfo",connectionDirection:"connectionDirection",constraints:"constraints",height:"height",horizontalAlignment:"horizontalAlignment",id:"id",inEdges:"inEdges",margin:"margin",offset:"offset",outEdges:"outEdges",pathData:"pathData",shape:"shape",style:"style",tooltip:"tooltip",verticalAlignment:"verticalAlignment",visibility:"visibility",width:"width"},features:[yn]}),n})(),Mle=(()=>{class n extends Bh{constructor(){super("ports")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-node-ports"]],contentQueries:function(e,i,r){if(1&e&&dn(r,ble,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),wle=["addInfo","annotations","backgroundColor","borderColor","borderWidth","branch","children","collapseIcon","columnIndex","columnSpan","columns","constraints","container","data","dragSize","excludeFromLayout","expandIcon","fixedUserHandles","flip","flipMode","height","horizontalAlignment","id","isExpanded","layoutInfo","margin","maxHeight","maxWidth","minHeight","minWidth","offsetX","offsetY","padding","pivot","ports","previewSize","rotateAngle","rowIndex","rowSpan","rows","shadow","shape","style","symbolInfo","tooltip","verticalAlignment","visible","width","wrapper","zIndex"],Cle=[],Ele=(()=>{class n extends Hh{constructor(e){super(),this.viewContainerRef=e,this.tags=["fixedUserHandles","annotations","ports"],Rl("currentInstance",this,this.viewContainerRef),this.registerEvents(Cle),this.directivePropList=wle}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-node"]],contentQueries:function(e,i,r){if(1&e&&(dn(r,fle,5),dn(r,yle,5),dn(r,Mle,5)),2&e){let s;Kr(s=en())&&(i.childFixedUserHandles=s.first),Kr(s=en())&&(i.childAnnotations=s.first),Kr(s=en())&&(i.childPorts=s.first)}},inputs:{addInfo:"addInfo",annotations:"annotations",backgroundColor:"backgroundColor",borderColor:"borderColor",borderWidth:"borderWidth",branch:"branch",children:"children",collapseIcon:"collapseIcon",columnIndex:"columnIndex",columnSpan:"columnSpan",columns:"columns",constraints:"constraints",container:"container",data:"data",dragSize:"dragSize",excludeFromLayout:"excludeFromLayout",expandIcon:"expandIcon",fixedUserHandles:"fixedUserHandles",flip:"flip",flipMode:"flipMode",height:"height",horizontalAlignment:"horizontalAlignment",id:"id",isExpanded:"isExpanded",layoutInfo:"layoutInfo",margin:"margin",maxHeight:"maxHeight",maxWidth:"maxWidth",minHeight:"minHeight",minWidth:"minWidth",offsetX:"offsetX",offsetY:"offsetY",padding:"padding",pivot:"pivot",ports:"ports",previewSize:"previewSize",rotateAngle:"rotateAngle",rowIndex:"rowIndex",rowSpan:"rowSpan",rows:"rows",shadow:"shadow",shape:"shape",style:"style",symbolInfo:"symbolInfo",tooltip:"tooltip",verticalAlignment:"verticalAlignment",visible:"visible",width:"width",wrapper:"wrapper",zIndex:"zIndex"},features:[yn]}),n})(),Dle=(()=>{class n extends Bh{constructor(){super("nodes")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-nodes"]],contentQueries:function(e,i,r){if(1&e&&dn(r,Ele,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})();const xle=["animationComplete","click","collectionChange","commandExecute","connectionChange","contextMenuBeforeItemRender","contextMenuClick","contextMenuOpen","created","dataLoaded","doubleClick","dragEnter","dragLeave","dragOver","drop","elementDraw","expandStateChange","fixedUserHandleClick","historyChange","historyStateChange","keyDown","keyUp","load","loaded","mouseEnter","mouseLeave","mouseOver","mouseWheel","onFixedUserHandleMouseDown","onFixedUserHandleMouseEnter","onFixedUserHandleMouseLeave","onFixedUserHandleMouseUp","onImageLoad","onUserHandleMouseDown","onUserHandleMouseEnter","onUserHandleMouseLeave","onUserHandleMouseUp","positionChange","propertyChange","rotateChange","scrollChange","segmentChange","segmentCollectionChange","selectionChange","sizeChange","sourcePointChange","targetPointChange","textEdit"],Tle=[""];let Ale=(()=>{let n=class extends zl{constructor(e,i,r,s){super(),this.ngEle=e,this.srenderer=i,this.viewContainerRef=r,this.injector=s,this.tags=["layers","customCursor","connectors","nodes"],this.element=this.ngEle.nativeElement,this.injectedModules=this.injectedModules||[];try{let o=this.injector.get("DiagramsHierarchicalTree");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsMindMap");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsRadialTree");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsComplexHierarchicalTree");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsDataBinding");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsSnapping");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsPrintAndExport");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsBpmnDiagrams");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsSymmetricLayout");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsConnectorBridging");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsUndoRedo");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsLayoutAnimation");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsDiagramContextMenu");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsLineRouting");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsConnectorEditing");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsLineDistribution");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsEj1Serialization");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsFlowchartLayout");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}this.registerEvents(xle),this.addTwoWay.call(this,Tle),Rl("currentInstance",this,this.viewContainerRef),this.context=new c_}ngOnInit(){this.context.ngOnInit(this)}ngAfterViewInit(){this.context.ngAfterViewInit(this)}ngOnDestroy(){this.context.ngOnDestroy(this)}ngAfterContentChecked(){this.tagObjects[0].instance=this.childLayers,this.childCustomCursor&&(this.tagObjects[1].instance=this.childCustomCursor),this.childConnectors&&(this.tagObjects[2].instance=this.childConnectors),this.childNodes&&(this.tagObjects[3].instance=this.childNodes),this.context.ngAfterContentChecked(this)}};return n.\u0275fac=function(e){return new(e||n)(Ot($c),Ot(nM),Ot(xn),Ot(Wo))},n.\u0275cmp=Pb({type:n,selectors:[["ejs-diagram"]],contentQueries:function(e,i,r){if(1&e&&(dn(r,jae,5),dn(r,Vae,5),dn(r,Wae,5),dn(r,Xae,5),dn(r,Jae,5),dn(r,cle,5),dn(r,Dle,5)),2&e){let s;Kr(s=en())&&(i.annotationTemplate=s.first),Kr(s=en())&&(i.nodeTemplate=s.first),Kr(s=en())&&(i.userHandleTemplate=s.first),Kr(s=en())&&(i.childLayers=s.first),Kr(s=en())&&(i.childCustomCursor=s.first),Kr(s=en())&&(i.childConnectors=s.first),Kr(s=en())&&(i.childNodes=s.first)}},inputs:{addInfo:"addInfo",annotationTemplate:"annotationTemplate",backgroundColor:"backgroundColor",bridgeDirection:"bridgeDirection",commandManager:"commandManager",connectorDefaults:"connectorDefaults",connectors:"connectors",constraints:"constraints",contextMenuSettings:"contextMenuSettings",customCursor:"customCursor",dataSourceSettings:"dataSourceSettings",diagramSettings:"diagramSettings",drawingObject:"drawingObject",enableConnectorSplit:"enableConnectorSplit",enablePersistence:"enablePersistence",enableRtl:"enableRtl",fixedUserHandleTemplate:"fixedUserHandleTemplate",getConnectorDefaults:"getConnectorDefaults",getCustomCursor:"getCustomCursor",getCustomProperty:"getCustomProperty",getCustomTool:"getCustomTool",getDescription:"getDescription",getNodeDefaults:"getNodeDefaults",height:"height",historyManager:"historyManager",layers:"layers",layout:"layout",locale:"locale",mode:"mode",nodeDefaults:"nodeDefaults",nodeTemplate:"nodeTemplate",nodes:"nodes",pageSettings:"pageSettings",rulerSettings:"rulerSettings",scrollSettings:"scrollSettings",segmentThumbShape:"segmentThumbShape",segmentThumbSize:"segmentThumbSize",selectedItems:"selectedItems",serializationSettings:"serializationSettings",setNodeTemplate:"setNodeTemplate",snapSettings:"snapSettings",tool:"tool",tooltip:"tooltip",updateSelection:"updateSelection",userHandleTemplate:"userHandleTemplate",width:"width"},outputs:{animationComplete:"animationComplete",click:"click",collectionChange:"collectionChange",commandExecute:"commandExecute",connectionChange:"connectionChange",contextMenuBeforeItemRender:"contextMenuBeforeItemRender",contextMenuClick:"contextMenuClick",contextMenuOpen:"contextMenuOpen",created:"created",dataLoaded:"dataLoaded",doubleClick:"doubleClick",dragEnter:"dragEnter",dragLeave:"dragLeave",dragOver:"dragOver",drop:"drop",elementDraw:"elementDraw",expandStateChange:"expandStateChange",fixedUserHandleClick:"fixedUserHandleClick",historyChange:"historyChange",historyStateChange:"historyStateChange",keyDown:"keyDown",keyUp:"keyUp",load:"load",loaded:"loaded",mouseEnter:"mouseEnter",mouseLeave:"mouseLeave",mouseOver:"mouseOver",mouseWheel:"mouseWheel",onFixedUserHandleMouseDown:"onFixedUserHandleMouseDown",onFixedUserHandleMouseEnter:"onFixedUserHandleMouseEnter",onFixedUserHandleMouseLeave:"onFixedUserHandleMouseLeave",onFixedUserHandleMouseUp:"onFixedUserHandleMouseUp",onImageLoad:"onImageLoad",onUserHandleMouseDown:"onUserHandleMouseDown",onUserHandleMouseEnter:"onUserHandleMouseEnter",onUserHandleMouseLeave:"onUserHandleMouseLeave",onUserHandleMouseUp:"onUserHandleMouseUp",positionChange:"positionChange",propertyChange:"propertyChange",rotateChange:"rotateChange",scrollChange:"scrollChange",segmentChange:"segmentChange",segmentCollectionChange:"segmentCollectionChange",selectionChange:"selectionChange",sizeChange:"sizeChange",sourcePointChange:"sourcePointChange",targetPointChange:"targetPointChange",textEdit:"textEdit"},features:[yn],decls:0,vars:0,template:function(e,i){},encapsulation:2,changeDetection:0}),cb([xT()],n.prototype,"annotationTemplate",void 0),cb([xT()],n.prototype,"nodeTemplate",void 0),cb([xT()],n.prototype,"userHandleTemplate",void 0),n=cb([Pae([c_])],n),n})(),Lle=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=xm({type:n}),n.\u0275inj=gf({imports:[[tq]]}),n})();const Nle={provide:"DiagramsHierarchicalTree",useValue:n_},Ole={provide:"DiagramsDataBinding",useValue:Koe},kle={provide:"DiagramsLayoutAnimation",useValue:uae},Ple=["diagram"];let zle=(()=>{class n{constructor(){this.data=[{Id:"parent1",Name:"Maria ",Designation:"Managing Director",RatingColor:"#C34444"},{Id:"parent",Name:" sam",Designation:"Managing Director",ReportingPerson:"parent1",RatingColor:"#C34444"}]}getNodeDefaults(e,i){return e.height=40,e.width=100,e.expandIcon={shape:"ArrowDown",width:20,height:20,fill:"red",borderColor:"blue",iconColor:"white",cornerRadius:7,borderWidth:2.5,offset:{x:.5,y:.85}},e.collapseIcon={offset:{x:.5,y:.85},shape:"ArrowUp",width:20,height:20,fill:"green",borderColor:"blue",iconColor:"white",cornerRadius:7,borderWidth:2.5},e.collapseIcon.height=15,e.collapseIcon.width=15,e.collapseIcon.shape="Minus",e.borderColor="white",e.backgroundColor="#6BA5D7",e.borderWidth=1,e.style={fill:"transparent",strokeWidth:2},e}getConnectorDefaults(e,i){return e.style={strokeColor:"#6BA5D7",strokeWidth:2},e.targetDecorator.style.fill="#6BA5D7",e.targetDecorator.style.strokeColor="#6BA5D7",e.targetDecorator.shape="None",e.type="Orthogonal",e}ngOnInit(){this.selectedItems={constraints:~lr.ResizeAll},this.snapSettings={constraints:0},this.items=new nt(this.data,(new _t).take(7)),this.layout={enableAnimation:!0,type:"HierarchicalTree",margin:{top:20},getLayoutInfo:(e,i)=>{i.hasSubTree||(i.orientation="vertical",i.type="alternate")}},this.dataSourceSettings={id:"Id",parentId:"ReportingPerson",dataSource:this.items}}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275cmp=Pb({type:n,selectors:[["app-container"]],viewQuery:function(i,r){if(1&i&&function dP(n,t,e){const i=xi();i.firstCreatePass&&(hP(i,new oP(n,t,e),-1),2==(2&t)&&(i.staticViewQueries=!0)),lP(i,Se(),t)}(Ple,5),2&i){let s;Kr(s=en())&&(r.diagram=s.first)}},standalone:!0,features:[OP([Nle,Ole,kle]),PP],decls:2,vars:6,consts:[["id","diagram","width","100%","height","580px",3,"getNodeDefaults","getConnectorDefaults","snapSettings","selectedItems","layout","dataSourceSettings"],["diagram",""]],template:function(i,r){1&i&&ew(0,"ejs-diagram",0,1),2&i&&YM("getNodeDefaults",r.getNodeDefaults)("getConnectorDefaults",r.getConnectorDefaults)("snapSettings",r.snapSettings)("selectedItems",r.selectedItems)("layout",r.layout)("dataSourceSettings",r.dataSourceSettings)},dependencies:[Lle,Ale],encapsulation:2})}}return n})();Ud(332),function Qq(n,t){return MG({rootComponent:n,...wz(t)})}(zle).catch(n=>console.error(n))},332:()=>{!function(Z){const se=Z.performance;function ye(Pi){se&&se.mark&&se.mark(Pi)}function fe(Pi,ht){se&&se.measure&&se.measure(Pi,ht)}ye("Zone");const be=Z.__Zone_symbol_prefix||"__zone_symbol__";function ke(Pi){return be+Pi}const at=!0===Z[ke("forceDuplicateZoneCheck")];if(Z.Zone){if(at||"function"!=typeof Z.Zone.__symbol__)throw new Error("Zone already loaded.");return Z.Zone}let tt=(()=>{class Pi{static{this.__symbol__=ke}static assertZonePatched(){if(Z.Promise!==_o.ZoneAwarePromise)throw new Error("Zone.js has detected that ZoneAwarePromise `(window|global).Promise` has been overwritten.\nMost likely cause is that a Promise polyfill has been loaded after Zone.js (Polyfilling Promise api is not necessary when zone.js is loaded. If you must load one, do so before loading zone.js.)")}static get root(){let F=Pi.current;for(;F.parent;)F=F.parent;return F}static get current(){return Ur.zone}static get currentTask(){return Do}static __load_patch(F,ae,Et=!1){if(_o.hasOwnProperty(F)){if(!Et&&at)throw Error("Already loaded patch: "+F)}else if(!Z["__Zone_disable_"+F]){const Xt="Zone:"+F;ye(Xt),_o[F]=ae(Z,Pi,cn),fe(Xt,Xt)}}get parent(){return this._parent}get name(){return this._name}constructor(F,ae){this._parent=F,this._name=ae?ae.name||"unnamed":"",this._properties=ae&&ae.properties||{},this._zoneDelegate=new Lt(this,this._parent&&this._parent._zoneDelegate,ae)}get(F){const ae=this.getZoneWith(F);if(ae)return ae._properties[F]}getZoneWith(F){let ae=this;for(;ae;){if(ae._properties.hasOwnProperty(F))return ae;ae=ae._parent}return null}fork(F){if(!F)throw new Error("ZoneSpec required!");return this._zoneDelegate.fork(this,F)}wrap(F,ae){if("function"!=typeof F)throw new Error("Expecting function got: "+F);const Et=this._zoneDelegate.intercept(this,F,ae),Xt=this;return function(){return Xt.runGuarded(Et,this,arguments,ae)}}run(F,ae,Et,Xt){Ur={parent:Ur,zone:this};try{return this._zoneDelegate.invoke(this,F,ae,Et,Xt)}finally{Ur=Ur.parent}}runGuarded(F,ae=null,Et,Xt){Ur={parent:Ur,zone:this};try{try{return this._zoneDelegate.invoke(this,F,ae,Et,Xt)}catch(Un){if(this._zoneDelegate.handleError(this,Un))throw Un}}finally{Ur=Ur.parent}}runTask(F,ae,Et){if(F.zone!=this)throw new Error("A task can only be run in the zone of creation! (Creation: "+(F.zone||_n).name+"; Execution: "+this.name+")");if(F.state===sr&&(F.type===ts||F.type===Pt))return;const Xt=F.state!=lt;Xt&&F._transitionTo(lt,ki),F.runCount++;const Un=Do;Do=F,Ur={parent:Ur,zone:this};try{F.type==Pt&&F.data&&!F.data.isPeriodic&&(F.cancelFn=void 0);try{return this._zoneDelegate.invokeTask(this,F,ae,Et)}catch(Ue){if(this._zoneDelegate.handleError(this,Ue))throw Ue}}finally{F.state!==sr&&F.state!==et&&(F.type==ts||F.data&&F.data.isPeriodic?Xt&&F._transitionTo(ki,lt):(F.runCount=0,this._updateTaskCount(F,-1),Xt&&F._transitionTo(sr,lt,sr))),Ur=Ur.parent,Do=Un}}scheduleTask(F){if(F.zone&&F.zone!==this){let Et=this;for(;Et;){if(Et===F.zone)throw Error(`can not reschedule task to ${this.name} which is descendants of the original zone ${F.zone.name}`);Et=Et.parent}}F._transitionTo(Zr,sr);const ae=[];F._zoneDelegates=ae,F._zone=this;try{F=this._zoneDelegate.scheduleTask(this,F)}catch(Et){throw F._transitionTo(et,Zr,sr),this._zoneDelegate.handleError(this,Et),Et}return F._zoneDelegates===ae&&this._updateTaskCount(F,1),F.state==Zr&&F._transitionTo(ki,Zr),F}scheduleMicroTask(F,ae,Et,Xt){return this.scheduleTask(new ft(vi,F,ae,Et,Xt,void 0))}scheduleMacroTask(F,ae,Et,Xt,Un){return this.scheduleTask(new ft(Pt,F,ae,Et,Xt,Un))}scheduleEventTask(F,ae,Et,Xt,Un){return this.scheduleTask(new ft(ts,F,ae,Et,Xt,Un))}cancelTask(F){if(F.zone!=this)throw new Error("A task can only be cancelled in the zone of creation! (Creation: "+(F.zone||_n).name+"; Execution: "+this.name+")");if(F.state===ki||F.state===lt){F._transitionTo(ur,ki,lt);try{this._zoneDelegate.cancelTask(this,F)}catch(ae){throw F._transitionTo(et,ur),this._zoneDelegate.handleError(this,ae),ae}return this._updateTaskCount(F,-1),F._transitionTo(sr,ur),F.runCount=0,F}}_updateTaskCount(F,ae){const Et=F._zoneDelegates;-1==ae&&(F._zoneDelegates=null);for(let Xt=0;XtPi.hasTask(F,ae),onScheduleTask:(Pi,ht,F,ae)=>Pi.scheduleTask(F,ae),onInvokeTask:(Pi,ht,F,ae,Et,Xt)=>Pi.invokeTask(F,ae,Et,Xt),onCancelTask:(Pi,ht,F,ae)=>Pi.cancelTask(F,ae)};class Lt{constructor(ht,F,ae){this._taskCounts={microTask:0,macroTask:0,eventTask:0},this.zone=ht,this._parentDelegate=F,this._forkZS=ae&&(ae&&ae.onFork?ae:F._forkZS),this._forkDlgt=ae&&(ae.onFork?F:F._forkDlgt),this._forkCurrZone=ae&&(ae.onFork?this.zone:F._forkCurrZone),this._interceptZS=ae&&(ae.onIntercept?ae:F._interceptZS),this._interceptDlgt=ae&&(ae.onIntercept?F:F._interceptDlgt),this._interceptCurrZone=ae&&(ae.onIntercept?this.zone:F._interceptCurrZone),this._invokeZS=ae&&(ae.onInvoke?ae:F._invokeZS),this._invokeDlgt=ae&&(ae.onInvoke?F:F._invokeDlgt),this._invokeCurrZone=ae&&(ae.onInvoke?this.zone:F._invokeCurrZone),this._handleErrorZS=ae&&(ae.onHandleError?ae:F._handleErrorZS),this._handleErrorDlgt=ae&&(ae.onHandleError?F:F._handleErrorDlgt),this._handleErrorCurrZone=ae&&(ae.onHandleError?this.zone:F._handleErrorCurrZone),this._scheduleTaskZS=ae&&(ae.onScheduleTask?ae:F._scheduleTaskZS),this._scheduleTaskDlgt=ae&&(ae.onScheduleTask?F:F._scheduleTaskDlgt),this._scheduleTaskCurrZone=ae&&(ae.onScheduleTask?this.zone:F._scheduleTaskCurrZone),this._invokeTaskZS=ae&&(ae.onInvokeTask?ae:F._invokeTaskZS),this._invokeTaskDlgt=ae&&(ae.onInvokeTask?F:F._invokeTaskDlgt),this._invokeTaskCurrZone=ae&&(ae.onInvokeTask?this.zone:F._invokeTaskCurrZone),this._cancelTaskZS=ae&&(ae.onCancelTask?ae:F._cancelTaskZS),this._cancelTaskDlgt=ae&&(ae.onCancelTask?F:F._cancelTaskDlgt),this._cancelTaskCurrZone=ae&&(ae.onCancelTask?this.zone:F._cancelTaskCurrZone),this._hasTaskZS=null,this._hasTaskDlgt=null,this._hasTaskDlgtOwner=null,this._hasTaskCurrZone=null;const Et=ae&&ae.onHasTask;(Et||F&&F._hasTaskZS)&&(this._hasTaskZS=Et?ae:At,this._hasTaskDlgt=F,this._hasTaskDlgtOwner=this,this._hasTaskCurrZone=ht,ae.onScheduleTask||(this._scheduleTaskZS=At,this._scheduleTaskDlgt=F,this._scheduleTaskCurrZone=this.zone),ae.onInvokeTask||(this._invokeTaskZS=At,this._invokeTaskDlgt=F,this._invokeTaskCurrZone=this.zone),ae.onCancelTask||(this._cancelTaskZS=At,this._cancelTaskDlgt=F,this._cancelTaskCurrZone=this.zone))}fork(ht,F){return this._forkZS?this._forkZS.onFork(this._forkDlgt,this.zone,ht,F):new tt(ht,F)}intercept(ht,F,ae){return this._interceptZS?this._interceptZS.onIntercept(this._interceptDlgt,this._interceptCurrZone,ht,F,ae):F}invoke(ht,F,ae,Et,Xt){return this._invokeZS?this._invokeZS.onInvoke(this._invokeDlgt,this._invokeCurrZone,ht,F,ae,Et,Xt):F.apply(ae,Et)}handleError(ht,F){return!this._handleErrorZS||this._handleErrorZS.onHandleError(this._handleErrorDlgt,this._handleErrorCurrZone,ht,F)}scheduleTask(ht,F){let ae=F;if(this._scheduleTaskZS)this._hasTaskZS&&ae._zoneDelegates.push(this._hasTaskDlgtOwner),ae=this._scheduleTaskZS.onScheduleTask(this._scheduleTaskDlgt,this._scheduleTaskCurrZone,ht,F),ae||(ae=F);else if(F.scheduleFn)F.scheduleFn(F);else{if(F.type!=vi)throw new Error("Task is missing scheduleFn.");Wt(F)}return ae}invokeTask(ht,F,ae,Et){return this._invokeTaskZS?this._invokeTaskZS.onInvokeTask(this._invokeTaskDlgt,this._invokeTaskCurrZone,ht,F,ae,Et):F.callback.apply(ae,Et)}cancelTask(ht,F){let ae;if(this._cancelTaskZS)ae=this._cancelTaskZS.onCancelTask(this._cancelTaskDlgt,this._cancelTaskCurrZone,ht,F);else{if(!F.cancelFn)throw Error("Task is not cancelable");ae=F.cancelFn(F)}return ae}hasTask(ht,F){try{this._hasTaskZS&&this._hasTaskZS.onHasTask(this._hasTaskDlgt,this._hasTaskCurrZone,ht,F)}catch(ae){this.handleError(ht,ae)}}_updateTaskCount(ht,F){const ae=this._taskCounts,Et=ae[ht],Xt=ae[ht]=Et+F;if(Xt<0)throw new Error("More tasks executed then were scheduled.");0!=Et&&0!=Xt||this.hasTask(this.zone,{microTask:ae.microTask>0,macroTask:ae.macroTask>0,eventTask:ae.eventTask>0,change:ht})}}class ft{constructor(ht,F,ae,Et,Xt,Un){if(this._zone=null,this.runCount=0,this._zoneDelegates=null,this._state="notScheduled",this.type=ht,this.source=F,this.data=Et,this.scheduleFn=Xt,this.cancelFn=Un,!ae)throw new Error("callback is not defined");this.callback=ae;const Ue=this;this.invoke=ht===ts&&Et&&Et.useG?ft.invokeTask:function(){return ft.invokeTask.call(Z,Ue,this,arguments)}}static invokeTask(ht,F,ae){ht||(ht=this),Ls++;try{return ht.runCount++,ht.zone.runTask(ht,F,ae)}finally{1==Ls&&ct(),Ls--}}get zone(){return this._zone}get state(){return this._state}cancelScheduleRequest(){this._transitionTo(sr,Zr)}_transitionTo(ht,F,ae){if(this._state!==F&&this._state!==ae)throw new Error(`${this.type} '${this.source}': can not transition to '${ht}', expecting state '${F}'${ae?" or '"+ae+"'":""}, was '${this._state}'.`);this._state=ht,ht==sr&&(this._zoneDelegates=null)}toString(){return this.data&&typeof this.data.handleId<"u"?this.data.handleId.toString():Object.prototype.toString.call(this)}toJSON(){return{type:this.type,state:this.state,source:this.source,zone:this.zone.name,runCount:this.runCount}}}const Ei=ke("setTimeout"),ti=ke("Promise"),gi=ke("then");let es,dr=[],Oi=!1;function kr(Pi){if(es||Z[ti]&&(es=Z[ti].resolve(0)),es){let ht=es[gi];ht||(ht=es.then),ht.call(es,Pi)}else Z[Ei](Pi,0)}function Wt(Pi){0===Ls&&0===dr.length&&kr(ct),Pi&&dr.push(Pi)}function ct(){if(!Oi){for(Oi=!0;dr.length;){const Pi=dr;dr=[];for(let ht=0;htUr,onUnhandledError:jr,microtaskDrainDone:jr,scheduleMicroTask:Wt,showUncaughtError:()=>!tt[ke("ignoreConsoleErrorUncaughtError")],patchEventTarget:()=>[],patchOnProperties:jr,patchMethod:()=>jr,bindArguments:()=>[],patchThen:()=>jr,patchMacroTask:()=>jr,patchEventPrototype:()=>jr,isIEOrEdge:()=>!1,getGlobalObjects:()=>{},ObjectDefineProperty:()=>jr,ObjectGetOwnPropertyDescriptor:()=>{},ObjectCreate:()=>{},ArraySlice:()=>[],patchClass:()=>jr,wrapWithCurrentZone:()=>jr,filterProperties:()=>[],attachOriginToPatched:()=>jr,_redefineProperty:()=>jr,patchCallbacks:()=>jr,nativeScheduleMicroTask:kr};let Ur={parent:null,zone:new tt(null,null)},Do=null,Ls=0;function jr(){}fe("Zone","Zone"),Z.Zone=tt}(globalThis);const _l=Object.getOwnPropertyDescriptor,_d=Object.defineProperty,Ud=Object.getPrototypeOf,jd=Object.create,pb=Array.prototype.slice,dm="addEventListener",$r="removeEventListener",Ul=Zone.__symbol__(dm),Fh=Zone.__symbol__($r),Ts="true",Wi="false",Vd=Zone.__symbol__("");function of(Z,se){return Zone.current.wrap(Z,se)}function um(Z,se,ye,fe,be){return Zone.current.scheduleMacroTask(Z,se,ye,fe,be)}const Ji=Zone.__symbol__,_h=typeof window<"u",Uh=_h?window:void 0,gn=_h&&Uh||globalThis,pm="removeAttribute";function Wd(Z,se){for(let ye=Z.length-1;ye>=0;ye--)"function"==typeof Z[ye]&&(Z[ye]=of(Z[ye],se+"_"+ye));return Z}function af(Z){return!Z||!1!==Z.writable&&!("function"==typeof Z.get&&typeof Z.set>"u")}const lf=typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope,jh=!("nw"in gn)&&typeof gn.process<"u"&&"[object process]"==={}.toString.call(gn.process),Yd=!jh&&!lf&&!(!_h||!Uh.HTMLElement),hf=typeof gn.process<"u"&&"[object process]"==={}.toString.call(gn.process)&&!lf&&!(!_h||!Uh.HTMLElement),jl={},Vh=function(Z){if(!(Z=Z||gn.event))return;let se=jl[Z.type];se||(se=jl[Z.type]=Ji("ON_PROPERTY"+Z.type));const ye=this||Z.target||gn,fe=ye[se];let be;return Yd&&ye===Uh&&"error"===Z.type?(be=fe&&fe.call(this,Z.message,Z.filename,Z.lineno,Z.colno,Z.error),!0===be&&Z.preventDefault()):(be=fe&&fe.apply(this,arguments),null!=be&&!be&&Z.preventDefault()),be};function Vl(Z,se,ye){let fe=_l(Z,se);if(!fe&&ye&&_l(ye,se)&&(fe={enumerable:!0,configurable:!0}),!fe||!fe.configurable)return;const be=Ji("on"+se+"patched");if(Z.hasOwnProperty(be)&&Z[be])return;delete fe.writable,delete fe.value;const ke=fe.get,at=fe.set,tt=se.slice(2);let At=jl[tt];At||(At=jl[tt]=Ji("ON_PROPERTY"+tt)),fe.set=function(Lt){let ft=this;!ft&&Z===gn&&(ft=gn),ft&&("function"==typeof ft[At]&&ft.removeEventListener(tt,Vh),at&&at.call(ft,null),ft[At]=Lt,"function"==typeof Lt&&ft.addEventListener(tt,Vh,!1))},fe.get=function(){let Lt=this;if(!Lt&&Z===gn&&(Lt=gn),!Lt)return null;const ft=Lt[At];if(ft)return ft;if(ke){let Ei=ke.call(this);if(Ei)return fe.set.call(this,Ei),"function"==typeof Lt[pm]&&Lt.removeAttribute(se),Ei}return null},_d(Z,se,fe),Z[be]=!0}function cf(Z,se,ye){if(se)for(let fe=0;fefunction(at,tt){const At=ye(at,tt);return At.cbIdx>=0&&"function"==typeof tt[At.cbIdx]?um(At.name,tt[At.cbIdx],At,be):ke.apply(at,tt)})}function Sa(Z,se){Z[Ji("OriginalDelegate")]=se}let gb=!1,Gd=!1;function vb(){if(gb)return Gd;gb=!0;try{const Z=Uh.navigator.userAgent;(-1!==Z.indexOf("MSIE ")||-1!==Z.indexOf("Trident/")||-1!==Z.indexOf("Edge/"))&&(Gd=!0)}catch{}return Gd}Zone.__load_patch("ZoneAwarePromise",(Z,se,ye)=>{const fe=Object.getOwnPropertyDescriptor,be=Object.defineProperty,at=ye.symbol,tt=[],At=!1!==Z[at("DISABLE_WRAPPING_UNCAUGHT_PROMISE_REJECTION")],Lt=at("Promise"),ft=at("then"),Ei="__creationTrace__";ye.onUnhandledError=Ue=>{if(ye.showUncaughtError()){const He=Ue&&Ue.rejection;He?console.error("Unhandled Promise rejection:",He instanceof Error?He.message:He,"; Zone:",Ue.zone.name,"; Task:",Ue.task&&Ue.task.source,"; Value:",He,He instanceof Error?He.stack:void 0):console.error(Ue)}},ye.microtaskDrainDone=()=>{for(;tt.length;){const Ue=tt.shift();try{Ue.zone.runGuarded(()=>{throw Ue.throwOriginal?Ue.rejection:Ue})}catch(He){gi(He)}}};const ti=at("unhandledPromiseRejectionHandler");function gi(Ue){ye.onUnhandledError(Ue);try{const He=se[ti];"function"==typeof He&&He.call(this,Ue)}catch{}}function dr(Ue){return Ue&&Ue.then}function Oi(Ue){return Ue}function es(Ue){return F.reject(Ue)}const kr=at("state"),Wt=at("value"),ct=at("finally"),_n=at("parentPromiseValue"),sr=at("parentPromiseState"),Zr="Promise.then",ki=null,lt=!0,ur=!1,et=0;function vi(Ue,He){return ge=>{try{cn(Ue,He,ge)}catch(We){cn(Ue,!1,We)}}}const Pt=function(){let Ue=!1;return function(ge){return function(){Ue||(Ue=!0,ge.apply(null,arguments))}}},ts="Promise resolved with itself",_o=at("currentTaskTrace");function cn(Ue,He,ge){const We=Pt();if(Ue===ge)throw new TypeError(ts);if(Ue[kr]===ki){let wt=null;try{("object"==typeof ge||"function"==typeof ge)&&(wt=ge&&ge.then)}catch(Xe){return We(()=>{cn(Ue,!1,Xe)})(),Ue}if(He!==ur&&ge instanceof F&&ge.hasOwnProperty(kr)&&ge.hasOwnProperty(Wt)&&ge[kr]!==ki)Do(ge),cn(Ue,ge[kr],ge[Wt]);else if(He!==ur&&"function"==typeof wt)try{wt.call(ge,We(vi(Ue,He)),We(vi(Ue,!1)))}catch(Xe){We(()=>{cn(Ue,!1,Xe)})()}else{Ue[kr]=He;const Xe=Ue[Wt];if(Ue[Wt]=ge,Ue[ct]===ct&&He===lt&&(Ue[kr]=Ue[sr],Ue[Wt]=Ue[_n]),He===ur&&ge instanceof Error){const mt=se.currentTask&&se.currentTask.data&&se.currentTask.data[Ei];mt&&be(ge,_o,{configurable:!0,enumerable:!1,writable:!0,value:mt})}for(let mt=0;mt{try{const dt=Ue[Wt],qt=!!ge&&ct===ge[ct];qt&&(ge[_n]=dt,ge[sr]=Xe);const ai=He.run(mt,void 0,qt&&mt!==es&&mt!==Oi?[]:[dt]);cn(ge,!0,ai)}catch(dt){cn(ge,!1,dt)}},ge)}const Pi=function(){},ht=Z.AggregateError;class F{static toString(){return"function ZoneAwarePromise() { [native code] }"}static resolve(He){return He instanceof F?He:cn(new this(null),lt,He)}static reject(He){return cn(new this(null),ur,He)}static withResolvers(){const He={};return He.promise=new F((ge,We)=>{He.resolve=ge,He.reject=We}),He}static any(He){if(!He||"function"!=typeof He[Symbol.iterator])return Promise.reject(new ht([],"All promises were rejected"));const ge=[];let We=0;try{for(let mt of He)We++,ge.push(F.resolve(mt))}catch{return Promise.reject(new ht([],"All promises were rejected"))}if(0===We)return Promise.reject(new ht([],"All promises were rejected"));let wt=!1;const Xe=[];return new F((mt,dt)=>{for(let qt=0;qt{wt||(wt=!0,mt(ai))},ai=>{Xe.push(ai),We--,0===We&&(wt=!0,dt(new ht(Xe,"All promises were rejected")))})})}static race(He){let ge,We,wt=new this((dt,qt)=>{ge=dt,We=qt});function Xe(dt){ge(dt)}function mt(dt){We(dt)}for(let dt of He)dr(dt)||(dt=this.resolve(dt)),dt.then(Xe,mt);return wt}static all(He){return F.allWithCallback(He)}static allSettled(He){return(this&&this.prototype instanceof F?this:F).allWithCallback(He,{thenCallback:We=>({status:"fulfilled",value:We}),errorCallback:We=>({status:"rejected",reason:We})})}static allWithCallback(He,ge){let We,wt,Xe=new this((ai,pr)=>{We=ai,wt=pr}),mt=2,dt=0;const qt=[];for(let ai of He){dr(ai)||(ai=this.resolve(ai));const pr=dt;try{ai.then(ir=>{qt[pr]=ge?ge.thenCallback(ir):ir,mt--,0===mt&&We(qt)},ir=>{ge?(qt[pr]=ge.errorCallback(ir),mt--,0===mt&&We(qt)):wt(ir)})}catch(ir){wt(ir)}mt++,dt++}return mt-=2,0===mt&&We(qt),Xe}constructor(He){const ge=this;if(!(ge instanceof F))throw new Error("Must be an instanceof Promise.");ge[kr]=ki,ge[Wt]=[];try{const We=Pt();He&&He(We(vi(ge,lt)),We(vi(ge,ur)))}catch(We){cn(ge,!1,We)}}get[Symbol.toStringTag](){return"Promise"}get[Symbol.species](){return F}then(He,ge){let We=this.constructor?.[Symbol.species];(!We||"function"!=typeof We)&&(We=this.constructor||F);const wt=new We(Pi),Xe=se.current;return this[kr]==ki?this[Wt].push(Xe,wt,He,ge):Ls(this,Xe,wt,He,ge),wt}catch(He){return this.then(null,He)}finally(He){let ge=this.constructor?.[Symbol.species];(!ge||"function"!=typeof ge)&&(ge=F);const We=new ge(Pi);We[ct]=ct;const wt=se.current;return this[kr]==ki?this[Wt].push(wt,We,He,He):Ls(this,wt,We,He,He),We}}F.resolve=F.resolve,F.reject=F.reject,F.race=F.race,F.all=F.all;const ae=Z[Lt]=Z.Promise;Z.Promise=F;const Et=at("thenPatched");function Xt(Ue){const He=Ue.prototype,ge=fe(He,"then");if(ge&&(!1===ge.writable||!ge.configurable))return;const We=He.then;He[ft]=We,Ue.prototype.then=function(wt,Xe){return new F((dt,qt)=>{We.call(this,dt,qt)}).then(wt,Xe)},Ue[Et]=!0}return ye.patchThen=Xt,ae&&(Xt(ae),Ka(Z,"fetch",Ue=>function Un(Ue){return function(He,ge){let We=Ue.apply(He,ge);if(We instanceof F)return We;let wt=We.constructor;return wt[Et]||Xt(wt),We}}(Ue))),Promise[se.__symbol__("uncaughtPromiseErrors")]=tt,F}),Zone.__load_patch("toString",Z=>{const se=Function.prototype.toString,ye=Ji("OriginalDelegate"),fe=Ji("Promise"),be=Ji("Error"),ke=function(){if("function"==typeof this){const Lt=this[ye];if(Lt)return"function"==typeof Lt?se.call(Lt):Object.prototype.toString.call(Lt);if(this===Promise){const ft=Z[fe];if(ft)return se.call(ft)}if(this===Error){const ft=Z[be];if(ft)return se.call(ft)}}return se.call(this)};ke[ye]=se,Function.prototype.toString=ke;const at=Object.prototype.toString;Object.prototype.toString=function(){return"function"==typeof Promise&&this instanceof Promise?"[object Promise]":at.call(this)}});let el=!1;if(typeof window<"u")try{const Z=Object.defineProperty({},"passive",{get:function(){el=!0}});window.addEventListener("test",Z,Z),window.removeEventListener("test",Z,Z)}catch{el=!1}const OT={useG:!0},Co={},mb={},vm=new RegExp("^"+Vd+"(\\w+)(true|false)$"),yb=Ji("propagationStopped");function mm(Z,se){const ye=(se?se(Z):Z)+Wi,fe=(se?se(Z):Z)+Ts,be=Vd+ye,ke=Vd+fe;Co[Z]={},Co[Z][Wi]=be,Co[Z][Ts]=ke}function Sb(Z,se,ye,fe){const be=fe&&fe.add||dm,ke=fe&&fe.rm||$r,at=fe&&fe.listeners||"eventListeners",tt=fe&&fe.rmAll||"removeAllListeners",At=Ji(be),Lt="."+be+":",ft="prependListener",Ei="."+ft+":",ti=function(Wt,ct,_n){if(Wt.isRemoved)return;const sr=Wt.callback;let Zr;"object"==typeof sr&&sr.handleEvent&&(Wt.callback=lt=>sr.handleEvent(lt),Wt.originalDelegate=sr);try{Wt.invoke(Wt,ct,[_n])}catch(lt){Zr=lt}const ki=Wt.options;return ki&&"object"==typeof ki&&ki.once&&ct[ke].call(ct,_n.type,Wt.originalDelegate?Wt.originalDelegate:Wt.callback,ki),Zr};function gi(Wt,ct,_n){if(!(ct=ct||Z.event))return;const sr=Wt||ct.target||Z,Zr=sr[Co[ct.type][_n?Ts:Wi]];if(Zr){const ki=[];if(1===Zr.length){const lt=ti(Zr[0],sr,ct);lt&&ki.push(lt)}else{const lt=Zr.slice();for(let ur=0;ur{throw ur})}}}const dr=function(Wt){return gi(this,Wt,!1)},Oi=function(Wt){return gi(this,Wt,!0)};function es(Wt,ct){if(!Wt)return!1;let _n=!0;ct&&void 0!==ct.useG&&(_n=ct.useG);const sr=ct&&ct.vh;let Zr=!0;ct&&void 0!==ct.chkDup&&(Zr=ct.chkDup);let ki=!1;ct&&void 0!==ct.rt&&(ki=ct.rt);let lt=Wt;for(;lt&&!lt.hasOwnProperty(be);)lt=Ud(lt);if(!lt&&Wt[be]&&(lt=Wt),!lt||lt[At])return!1;const ur=ct&&ct.eventNameToString,et={},vi=lt[At]=lt[be],Pt=lt[Ji(ke)]=lt[ke],ts=lt[Ji(at)]=lt[at],_o=lt[Ji(tt)]=lt[tt];let cn;ct&&ct.prepend&&(cn=lt[Ji(ct.prepend)]=lt[ct.prepend]);const F=_n?function(ge){if(!et.isExisting)return vi.call(et.target,et.eventName,et.capture?Oi:dr,et.options)}:function(ge){return vi.call(et.target,et.eventName,ge.invoke,et.options)},ae=_n?function(ge){if(!ge.isRemoved){const We=Co[ge.eventName];let wt;We&&(wt=We[ge.capture?Ts:Wi]);const Xe=wt&&ge.target[wt];if(Xe)for(let mt=0;mt{Vo.zone.cancelTask(Vo)},{once:!0})),et.target=null,Fc&&(Fc.taskData=null),qd&&(Dn.once=!0),!el&&"boolean"==typeof Vo.options||(Vo.options=Dn),Vo.target=qt,Vo.capture=Gl,Vo.eventName=ai,ir&&(Vo.originalDelegate=pr),dt?jo.unshift(Vo):jo.push(Vo),mt?qt:void 0}};return lt[be]=He(vi,Lt,F,ae,ki),cn&&(lt[ft]=He(cn,Ei,function(ge){return cn.call(et.target,et.eventName,ge.invoke,et.options)},ae,ki,!0)),lt[ke]=function(){const ge=this||Z;let We=arguments[0];ct&&ct.transferEventName&&(We=ct.transferEventName(We));const wt=arguments[2],Xe=!!wt&&("boolean"==typeof wt||wt.capture),mt=arguments[1];if(!mt)return Pt.apply(this,arguments);if(sr&&!sr(Pt,mt,ge,arguments))return;const dt=Co[We];let qt;dt&&(qt=dt[Xe?Ts:Wi]);const ai=qt&&ge[qt];if(ai)for(let pr=0;prfunction(be,ke){be[yb]=!0,fe&&fe.apply(be,ke)})}function bb(Z,se,ye,fe,be){const ke=Zone.__symbol__(fe);if(se[ke])return;const at=se[ke]=se[fe];se[fe]=function(tt,At,Lt){return At&&At.prototype&&be.forEach(function(ft){const Ei=`${ye}.${fe}::`+ft,ti=At.prototype;try{if(ti.hasOwnProperty(ft)){const gi=Z.ObjectGetOwnPropertyDescriptor(ti,ft);gi&&gi.value?(gi.value=Z.wrapWithCurrentZone(gi.value,Ei),Z._redefineProperty(At.prototype,ft,gi)):ti[ft]&&(ti[ft]=Z.wrapWithCurrentZone(ti[ft],Ei))}else ti[ft]&&(ti[ft]=Z.wrapWithCurrentZone(ti[ft],Ei))}catch{}}),at.call(se,tt,At,Lt)},Z.attachOriginToPatched(se[fe],at)}function Mb(Z,se,ye){if(!ye||0===ye.length)return se;const fe=ye.filter(ke=>ke.target===Z);if(!fe||0===fe.length)return se;const be=fe[0].ignoreProperties;return se.filter(ke=>-1===be.indexOf(ke))}function Eo(Z,se,ye,fe){Z&&cf(Z,Mb(Z,se,ye),fe)}function Xd(Z){return Object.getOwnPropertyNames(Z).filter(se=>se.startsWith("on")&&se.length>2).map(se=>se.substring(2))}Zone.__load_patch("util",(Z,se,ye)=>{const fe=Xd(Z);ye.patchOnProperties=cf,ye.patchMethod=Ka,ye.bindArguments=Wd,ye.patchMacroTask=fb;const be=se.__symbol__("BLACK_LISTED_EVENTS"),ke=se.__symbol__("UNPATCHED_EVENTS");Z[ke]&&(Z[be]=Z[ke]),Z[be]&&(se[be]=se[ke]=Z[be]),ye.patchEventPrototype=ym,ye.patchEventTarget=Sb,ye.isIEOrEdge=vb,ye.ObjectDefineProperty=_d,ye.ObjectGetOwnPropertyDescriptor=_l,ye.ObjectCreate=jd,ye.ArraySlice=pb,ye.patchClass=Qd,ye.wrapWithCurrentZone=of,ye.filterProperties=Mb,ye.attachOriginToPatched=Sa,ye._redefineProperty=Object.defineProperty,ye.patchCallbacks=bb,ye.getGlobalObjects=()=>({globalSources:mb,zoneSymbolEventNames:Co,eventNames:fe,isBrowser:Yd,isMix:hf,isNode:jh,TRUE_STR:Ts,FALSE_STR:Wi,ZONE_SYMBOL_PREFIX:Vd,ADD_EVENT_LISTENER_STR:dm,REMOVE_EVENT_LISTENER_STR:$r})});const As=Ji("zoneTask");function Wl(Z,se,ye,fe){let be=null,ke=null;ye+=fe;const at={};function tt(Lt){const ft=Lt.data;return ft.args[0]=function(){return Lt.invoke.apply(this,arguments)},ft.handleId=be.apply(Z,ft.args),Lt}function At(Lt){return ke.call(Z,Lt.data.handleId)}be=Ka(Z,se+=fe,Lt=>function(ft,Ei){if("function"==typeof Ei[0]){const ti={isPeriodic:"Interval"===fe,delay:"Timeout"===fe||"Interval"===fe?Ei[1]||0:void 0,args:Ei},gi=Ei[0];Ei[0]=function(){try{return gi.apply(this,arguments)}finally{ti.isPeriodic||("number"==typeof ti.handleId?delete at[ti.handleId]:ti.handleId&&(ti.handleId[As]=null))}};const dr=um(se,Ei[0],ti,tt,At);if(!dr)return dr;const Oi=dr.data.handleId;return"number"==typeof Oi?at[Oi]=dr:Oi&&(Oi[As]=dr),Oi&&Oi.ref&&Oi.unref&&"function"==typeof Oi.ref&&"function"==typeof Oi.unref&&(dr.ref=Oi.ref.bind(Oi),dr.unref=Oi.unref.bind(Oi)),"number"==typeof Oi||Oi?Oi:dr}return Lt.apply(Z,Ei)}),ke=Ka(Z,ye,Lt=>function(ft,Ei){const ti=Ei[0];let gi;"number"==typeof ti?gi=at[ti]:(gi=ti&&ti[As],gi||(gi=ti)),gi&&"string"==typeof gi.type?"notScheduled"!==gi.state&&(gi.cancelFn&&gi.data.isPeriodic||0===gi.runCount)&&("number"==typeof ti?delete at[ti]:ti&&(ti[As]=null),gi.zone.cancelTask(gi)):Lt.apply(Z,Ei)})}Zone.__load_patch("legacy",Z=>{const se=Z[Zone.__symbol__("legacyPatch")];se&&se()}),Zone.__load_patch("timers",Z=>{const ye="clear";Wl(Z,"set",ye,"Timeout"),Wl(Z,"set",ye,"Interval"),Wl(Z,"set",ye,"Immediate")}),Zone.__load_patch("requestAnimationFrame",Z=>{Wl(Z,"request","cancel","AnimationFrame"),Wl(Z,"mozRequest","mozCancel","AnimationFrame"),Wl(Z,"webkitRequest","webkitCancel","AnimationFrame")}),Zone.__load_patch("blocking",(Z,se)=>{const ye=["alert","prompt","confirm"];for(let fe=0;fefunction(At,Lt){return se.current.run(ke,Z,Lt,tt)})}),Zone.__load_patch("EventTarget",(Z,se,ye)=>{(function Yl(Z,se){se.patchEventPrototype(Z,se)})(Z,ye),function Im(Z,se){if(Zone[se.symbol("patchEventTarget")])return;const{eventNames:ye,zoneSymbolEventNames:fe,TRUE_STR:be,FALSE_STR:ke,ZONE_SYMBOL_PREFIX:at}=se.getGlobalObjects();for(let At=0;At{Qd("MutationObserver"),Qd("WebKitMutationObserver")}),Zone.__load_patch("IntersectionObserver",(Z,se,ye)=>{Qd("IntersectionObserver")}),Zone.__load_patch("FileReader",(Z,se,ye)=>{Qd("FileReader")}),Zone.__load_patch("on_property",(Z,se,ye)=>{!function df(Z,se){if(jh&&!hf||Zone[Z.symbol("patchEvents")])return;const ye=se.__Zone_ignore_on_properties;let fe=[];if(Yd){const be=window;fe=fe.concat(["Document","SVGElement","Element","HTMLElement","HTMLBodyElement","HTMLMediaElement","HTMLFrameSetElement","HTMLFrameElement","HTMLIFrameElement","HTMLMarqueeElement","Worker"]);const ke=function gm(){try{const Z=Uh.navigator.userAgent;if(-1!==Z.indexOf("MSIE ")||-1!==Z.indexOf("Trident/"))return!0}catch{}return!1}()?[{target:be,ignoreProperties:["error"]}]:[];Eo(be,Xd(be),ye&&ye.concat(ke),Ud(be))}fe=fe.concat(["XMLHttpRequest","XMLHttpRequestEventTarget","IDBIndex","IDBRequest","IDBOpenDBRequest","IDBDatabase","IDBTransaction","IDBCursor","WebSocket"]);for(let be=0;be{!function Sm(Z,se){const{isBrowser:ye,isMix:fe}=se.getGlobalObjects();(ye||fe)&&Z.customElements&&"customElements"in Z&&se.patchCallbacks(se,Z.customElements,"customElements","define",["connectedCallback","disconnectedCallback","adoptedCallback","attributeChangedCallback"])}(Z,ye)}),Zone.__load_patch("XHR",(Z,se)=>{!function At(Lt){const ft=Lt.XMLHttpRequest;if(!ft)return;const Ei=ft.prototype;let gi=Ei[Ul],dr=Ei[Fh];if(!gi){const et=Lt.XMLHttpRequestEventTarget;if(et){const vi=et.prototype;gi=vi[Ul],dr=vi[Fh]}}const Oi="readystatechange",es="scheduled";function kr(et){const vi=et.data,Pt=vi.target;Pt[ke]=!1,Pt[tt]=!1;const ts=Pt[be];gi||(gi=Pt[Ul],dr=Pt[Fh]),ts&&dr.call(Pt,Oi,ts);const _o=Pt[be]=()=>{if(Pt.readyState===Pt.DONE)if(!vi.aborted&&Pt[ke]&&et.state===es){const Ur=Pt[se.__symbol__("loadfalse")];if(0!==Pt.status&&Ur&&Ur.length>0){const Do=et.invoke;et.invoke=function(){const Ls=Pt[se.__symbol__("loadfalse")];for(let jr=0;jrfunction(et,vi){return et[fe]=0==vi[2],et[at]=vi[1],_n.apply(et,vi)}),Zr=Ji("fetchTaskAborting"),ki=Ji("fetchTaskScheduling"),lt=Ka(Ei,"send",()=>function(et,vi){if(!0===se.current[ki]||et[fe])return lt.apply(et,vi);{const Pt={target:et,url:et[at],isPeriodic:!1,args:vi,aborted:!1},ts=um("XMLHttpRequest.send",Wt,Pt,kr,ct);et&&!0===et[tt]&&!Pt.aborted&&ts.state===es&&ts.invoke()}}),ur=Ka(Ei,"abort",()=>function(et,vi){const Pt=function ti(et){return et[ye]}(et);if(Pt&&"string"==typeof Pt.type){if(null==Pt.cancelFn||Pt.data&&Pt.data.aborted)return;Pt.zone.cancelTask(Pt)}else if(!0===se.current[Zr])return ur.apply(et,vi)})}(Z);const ye=Ji("xhrTask"),fe=Ji("xhrSync"),be=Ji("xhrListener"),ke=Ji("xhrScheduled"),at=Ji("xhrURL"),tt=Ji("xhrErrorBeforeScheduled")}),Zone.__load_patch("geolocation",Z=>{Z.navigator&&Z.navigator.geolocation&&function fm(Z,se){const ye=Z.constructor.name;for(let fe=0;fe{const At=function(){return tt.apply(this,Wd(arguments,ye+"."+be))};return Sa(At,tt),At})(ke)}}}(Z.navigator.geolocation,["getCurrentPosition","watchPosition"])}),Zone.__load_patch("PromiseRejectionEvent",(Z,se)=>{function ye(fe){return function(be){Ib(Z,fe).forEach(at=>{const tt=Z.PromiseRejectionEvent;if(tt){const At=new tt(fe,{promise:be.promise,reason:be.rejection});at.invoke(At)}})}}Z.PromiseRejectionEvent&&(se[Ji("unhandledPromiseRejectionHandler")]=ye("unhandledrejection"),se[Ji("rejectionHandledHandler")]=ye("rejectionhandled"))}),Zone.__load_patch("queueMicrotask",(Z,se,ye)=>{!function uf(Z,se){se.patchMethod(Z,"queueMicrotask",ye=>function(fe,be){Zone.current.scheduleMicroTask("queueMicrotask",be[0])})}(Z,ye)})}},_l=>{_l(_l.s=51)}]); \ No newline at end of file diff --git a/ej2-angular/samples/diagram/ports/add-cs1/index.html b/ej2-angular/samples/diagram/ports/add-cs1/index.html index 527d3fea53..67b1a2c081 100644 --- a/ej2-angular/samples/diagram/ports/add-cs1/index.html +++ b/ej2-angular/samples/diagram/ports/add-cs1/index.html @@ -19,5 +19,5 @@
Loading....
- + \ No newline at end of file diff --git a/ej2-angular/samples/diagram/ports/add-cs1/main.606f4ee7e9720645.js b/ej2-angular/samples/diagram/ports/add-cs1/main.606f4ee7e9720645.js deleted file mode 100644 index 49b3e7d5fb..0000000000 --- a/ej2-angular/samples/diagram/ports/add-cs1/main.606f4ee7e9720645.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";(self.webpackChunksyncfusion_component=self.webpackChunksyncfusion_component||[]).push([[179],{51:(_l,_d,Ud)=>{let $r=null,Fh=1;const Ts=Symbol("SIGNAL");function Wi(n){const t=$r;return $r=n,t}function gn(n){if((!Vh(n)||n.dirty)&&(n.dirty||n.lastCleanEpoch!==Fh)){if(!n.producerMustRecompute(n)&&!jh(n))return n.dirty=!1,void(n.lastCleanEpoch=Fh);n.producerRecomputeValue(n),n.dirty=!1,n.lastCleanEpoch=Fh}}function jh(n){Vl(n);for(let t=0;t0}function Vl(n){n.producerNode??=[],n.producerIndexOfThis??=[],n.producerLastReadVersion??=[]}let Gd=null;function Eo(n){return"function"==typeof n}function Xd(n){const e=n(i=>{Error.call(i),i.stack=(new Error).stack});return e.prototype=Object.create(Error.prototype),e.prototype.constructor=e,e}const df=Xd(n=>function(e){n(this),this.message=e?`${e.length} errors occurred during unsubscription:\n${e.map((i,r)=>`${r+1}) ${i.toString()}`).join("\n ")}`:"",this.name="UnsubscriptionError",this.errors=e});function uf(n,t){if(n){const e=n.indexOf(t);0<=e&&n.splice(e,1)}}class As{constructor(t){this.initialTeardown=t,this.closed=!1,this._parentage=null,this._finalizers=null}unsubscribe(){let t;if(!this.closed){this.closed=!0;const{_parentage:e}=this;if(e)if(this._parentage=null,Array.isArray(e))for(const s of e)s.remove(this);else e.remove(this);const{initialTeardown:i}=this;if(Eo(i))try{i()}catch(s){t=s instanceof df?s.errors:[s]}const{_finalizers:r}=this;if(r){this._finalizers=null;for(const s of r)try{Mm(s)}catch(o){t=t??[],o instanceof df?t=[...t,...o.errors]:t.push(o)}}if(t)throw new df(t)}}add(t){var e;if(t&&t!==this)if(this.closed)Mm(t);else{if(t instanceof As){if(t.closed||t._hasParent(this))return;t._addParent(this)}(this._finalizers=null!==(e=this._finalizers)&&void 0!==e?e:[]).push(t)}}_hasParent(t){const{_parentage:e}=this;return e===t||Array.isArray(e)&&e.includes(t)}_addParent(t){const{_parentage:e}=this;this._parentage=Array.isArray(e)?(e.push(t),e):e?[e,t]:t}_removeParent(t){const{_parentage:e}=this;e===t?this._parentage=null:Array.isArray(e)&&uf(e,t)}remove(t){const{_finalizers:e}=this;e&&uf(e,t),t instanceof As&&t._removeParent(this)}}As.EMPTY=(()=>{const n=new As;return n.closed=!0,n})();const Wl=As.EMPTY;function bm(n){return n instanceof As||n&&"closed"in n&&Eo(n.remove)&&Eo(n.add)&&Eo(n.unsubscribe)}function Mm(n){Eo(n)?n():n.unsubscribe()}const Yl={onUnhandledError:null,onStoppedNotification:null,Promise:void 0,useDeprecatedSynchronousErrorHandling:!1,useDeprecatedNextContext:!1},Z={setTimeout(n,t,...e){const{delegate:i}=Z;return i?.setTimeout?i.setTimeout(n,t,...e):setTimeout(n,t,...e)},clearTimeout(n){const{delegate:t}=Z;return(t?.clearTimeout||clearTimeout)(n)},delegate:void 0};function ye(){}const fe=at("C",void 0,void 0);function at(n,t,e){return{kind:n,value:t,error:e}}let tt=null;function At(n){if(Yl.useDeprecatedSynchronousErrorHandling){const t=!tt;if(t&&(tt={errorThrown:!1,error:null}),n(),t){const{errorThrown:e,error:i}=tt;if(tt=null,e)throw i}}else n()}class ft extends As{constructor(t){super(),this.isStopped=!1,t?(this.destination=t,bm(t)&&t.add(this)):this.destination=Wt}static create(t,e,i){return new cr(t,e,i)}next(t){this.isStopped?kr(function ke(n){return at("N",n,void 0)}(t),this):this._next(t)}error(t){this.isStopped?kr(function be(n){return at("E",void 0,n)}(t),this):(this.isStopped=!0,this._error(t))}complete(){this.isStopped?kr(fe,this):(this.isStopped=!0,this._complete())}unsubscribe(){this.closed||(this.isStopped=!0,super.unsubscribe(),this.destination=null)}_next(t){this.destination.next(t)}_error(t){try{this.destination.error(t)}finally{this.unsubscribe()}}_complete(){try{this.destination.complete()}finally{this.unsubscribe()}}}const Ei=Function.prototype.bind;function ii(n,t){return Ei.call(n,t)}class gi{constructor(t){this.partialObserver=t}next(t){const{partialObserver:e}=this;if(e.next)try{e.next(t)}catch(i){Oi(i)}}error(t){const{partialObserver:e}=this;if(e.error)try{e.error(t)}catch(i){Oi(i)}else Oi(t)}complete(){const{partialObserver:t}=this;if(t.complete)try{t.complete()}catch(e){Oi(e)}}}class cr extends ft{constructor(t,e,i){let r;if(super(),Eo(t)||!t)r={next:t??void 0,error:e??void 0,complete:i??void 0};else{let s;this&&Yl.useDeprecatedNextContext?(s=Object.create(t),s.unsubscribe=()=>this.unsubscribe(),r={next:t.next&&ii(t.next,s),error:t.error&&ii(t.error,s),complete:t.complete&&ii(t.complete,s)}):r=t}this.destination=new gi(r)}}function Oi(n){Yl.useDeprecatedSynchronousErrorHandling?function Lt(n){Yl.useDeprecatedSynchronousErrorHandling&&tt&&(tt.errorThrown=!0,tt.error=n)}(n):function se(n){Z.setTimeout(()=>{const{onUnhandledError:t}=Yl;if(!t)throw n;t(n)})}(n)}function kr(n,t){const{onStoppedNotification:e}=Yl;e&&Z.setTimeout(()=>e(n,t))}const Wt={closed:!0,next:ye,error:function es(n){throw n},complete:ye},ct="function"==typeof Symbol&&Symbol.observable||"@@observable";function _n(n){return n}let ki=(()=>{class n{constructor(e){e&&(this._subscribe=e)}lift(e){const i=new n;return i.source=this,i.operator=e,i}subscribe(e,i,r){const s=function et(n){return n&&n instanceof ft||function dr(n){return n&&Eo(n.next)&&Eo(n.error)&&Eo(n.complete)}(n)&&bm(n)}(e)?e:new cr(e,i,r);return At(()=>{const{operator:o,source:a}=this;s.add(o?o.call(s,a):a?this._subscribe(s):this._trySubscribe(s))}),s}_trySubscribe(e){try{return this._subscribe(e)}catch(i){e.error(i)}}forEach(e,i){return new(i=lt(i))((r,s)=>{const o=new cr({next:a=>{try{e(a)}catch(l){s(l),o.unsubscribe()}},error:s,complete:r});this.subscribe(o)})}_subscribe(e){var i;return null===(i=this.source)||void 0===i?void 0:i.subscribe(e)}[ct](){return this}pipe(...e){return function Zr(n){return 0===n.length?_n:1===n.length?n[0]:function(e){return n.reduce((i,r)=>r(i),e)}}(e)(this)}toPromise(e){return new(e=lt(e))((i,r)=>{let s;this.subscribe(o=>s=o,o=>r(o),()=>i(s))})}}return n.create=t=>new n(t),n})();function lt(n){var t;return null!==(t=n??Yl.Promise)&&void 0!==t?t:Promise}const vi=Xd(n=>function(){n(this),this.name="ObjectUnsubscribedError",this.message="object unsubscribed"});let Pt=(()=>{class n extends ki{constructor(){super(),this.closed=!1,this.currentObservers=null,this.observers=[],this.isStopped=!1,this.hasError=!1,this.thrownError=null}lift(e){const i=new ts(this,this);return i.operator=e,i}_throwIfClosed(){if(this.closed)throw new vi}next(e){At(()=>{if(this._throwIfClosed(),!this.isStopped){this.currentObservers||(this.currentObservers=Array.from(this.observers));for(const i of this.currentObservers)i.next(e)}})}error(e){At(()=>{if(this._throwIfClosed(),!this.isStopped){this.hasError=this.isStopped=!0,this.thrownError=e;const{observers:i}=this;for(;i.length;)i.shift().error(e)}})}complete(){At(()=>{if(this._throwIfClosed(),!this.isStopped){this.isStopped=!0;const{observers:e}=this;for(;e.length;)e.shift().complete()}})}unsubscribe(){this.isStopped=this.closed=!0,this.observers=this.currentObservers=null}get observed(){var e;return(null===(e=this.observers)||void 0===e?void 0:e.length)>0}_trySubscribe(e){return this._throwIfClosed(),super._trySubscribe(e)}_subscribe(e){return this._throwIfClosed(),this._checkFinalizedStatuses(e),this._innerSubscribe(e)}_innerSubscribe(e){const{hasError:i,isStopped:r,observers:s}=this;return i||r?Wl:(this.currentObservers=null,s.push(e),new As(()=>{this.currentObservers=null,uf(s,e)}))}_checkFinalizedStatuses(e){const{hasError:i,thrownError:r,isStopped:s}=this;i?e.error(r):s&&e.complete()}asObservable(){const e=new ki;return e.source=this,e}}return n.create=(t,e)=>new ts(t,e),n})();class ts extends Pt{constructor(t,e){super(),this.destination=t,this.source=e}next(t){var e,i;null===(i=null===(e=this.destination)||void 0===e?void 0:e.next)||void 0===i||i.call(e,t)}error(t){var e,i;null===(i=null===(e=this.destination)||void 0===e?void 0:e.error)||void 0===i||i.call(e,t)}complete(){var t,e;null===(e=null===(t=this.destination)||void 0===t?void 0:t.complete)||void 0===e||e.call(t)}_subscribe(t){var e,i;return null!==(i=null===(e=this.source)||void 0===e?void 0:e.subscribe(t))&&void 0!==i?i:Wl}}class _o extends Pt{constructor(t){super(),this._value=t}get value(){return this.getValue()}_subscribe(t){const e=super._subscribe(t);return!e.closed&&t.next(this._value),e}getValue(){const{hasError:t,thrownError:e,_value:i}=this;if(t)throw e;return this._throwIfClosed(),i}next(t){super.next(this._value=t)}}class Ls extends ft{constructor(t,e,i,r,s,o){super(t),this.onFinalize=s,this.shouldUnsubscribe=o,this._next=e?function(a){try{e(a)}catch(l){t.error(l)}}:super._next,this._error=r?function(a){try{r(a)}catch(l){t.error(l)}finally{this.unsubscribe()}}:super._error,this._complete=i?function(){try{i()}catch(a){t.error(a)}finally{this.unsubscribe()}}:super._complete}unsubscribe(){var t;if(!this.shouldUnsubscribe||this.shouldUnsubscribe()){const{closed:e}=this;super.unsubscribe(),!e&&(null===(t=this.onFinalize)||void 0===t||t.call(this))}}}function jr(n,t){return function Ur(n){return t=>{if(function cn(n){return Eo(n?.lift)}(t))return t.lift(function(e){try{return n(e,this)}catch(i){this.error(i)}});throw new TypeError("Unable to lift unknown Observable type")}}((e,i)=>{let r=0;e.subscribe(function Do(n,t,e,i,r){return new Ls(n,t,e,i,r)}(i,s=>{i.next(n.call(t,s,r++))}))})}class F extends Error{constructor(t,e){super(function ae(n,t){return`NG0${Math.abs(n)}${t?": "+t:""}`}(t,e)),this.code=t}}function Xe(n){for(let t in n)if(n[t]===Xe)return t;throw Error("Could not find renamed property on target object.")}function mt(n,t){for(const e in t)t.hasOwnProperty(e)&&!n.hasOwnProperty(e)&&(n[e]=t[e])}function dt(n){if("string"==typeof n)return n;if(Array.isArray(n))return"["+n.map(dt).join(", ")+"]";if(null==n)return""+n;if(n.overriddenName)return`${n.overriddenName}`;if(n.name)return`${n.name}`;const t=n.toString();if(null==t)return""+t;const e=t.indexOf("\n");return-1===e?t:t.substring(0,e)}function $t(n,t){return null==n||""===n?null===t?"":t:null==t||""===t?n:n+" "+t}const ur=Xe({__forward_ref__:Xe});function ir(n){return n.__forward_ref__=ir,n.toString=function(){return dt(this())},n}function vt(n){return function Dn(n){return"function"==typeof n&&n.hasOwnProperty(ur)&&n.__forward_ref__===ir}(n)?n():n}function Ql(n){return n&&!!n.\u0275providers}const Gl=Xe({\u0275cmp:Xe}),qd=Xe({\u0275dir:Xe}),pf=Xe({\u0275pipe:Xe}),Uo=Xe({\u0275fac:Xe}),jo=Xe({__NG_ELEMENT_ID__:Xe}),ff=Xe({__NG_ENV_ID__:Xe});function zi(n){return"function"==typeof n?n.name||n.toString():"object"==typeof n&&null!=n&&"function"==typeof n.type?n.type.name||n.type.toString():function Nt(n){return"string"==typeof n?n:null==n?"":String(n)}(n)}function Db(n,t){throw new F(-201,!1)}function ro(n,t){null==n&&function zt(n,t,e,i){throw new Error(`ASSERTION ERROR: ${n}`+(null==i?"":` [Expected=> ${e} ${i} ${t} <=Actual]`))}(t,n,null,"!=")}function Yi(n){return{token:n.token,providedIn:n.providedIn||null,factory:n.factory,value:void 0}}function gf(n){return{providers:n.providers||[],imports:n.imports||[]}}function wm(n){return PT(n,Em)||PT(n,zT)}function PT(n,t){return n.hasOwnProperty(t)?n[t]:null}function Cm(n){return n&&(n.hasOwnProperty(xb)||n.hasOwnProperty(E_))?n[xb]:null}const Em=Xe({\u0275prov:Xe}),xb=Xe({\u0275inj:Xe}),zT=Xe({ngInjectableDef:Xe}),E_=Xe({ngInjectorDef:Xe});var Di=function(n){return n[n.Default=0]="Default",n[n.Host=1]="Host",n[n.Self=2]="Self",n[n.SkipSelf=4]="SkipSelf",n[n.Optional=8]="Optional",n}(Di||{});let Tb;function no(n){const t=Tb;return Tb=n,t}function HT(n,t,e){const i=wm(n);return i&&"root"==i.providedIn?void 0===i.value?i.value=i.factory():i.value:e&Di.Optional?null:void 0!==t?t:void Db()}const rr=globalThis;class Ht{constructor(t,e){this._desc=t,this.ngMetadataName="InjectionToken",this.\u0275prov=void 0,"number"==typeof e?this.__NG_ELEMENT_ID__=e:void 0!==e&&(this.\u0275prov=Yi({token:this,providedIn:e.providedIn||"root",factory:e.factory}))}get multi(){return this}toString(){return`InjectionToken ${this._desc}`}}const vf={},kb="__NG_DI_FLAG__",Dm="ngTempTokenPath",T_=/\n/gm,FT="__source";let Zd;function Qh(n){const t=Zd;return Zd=n,t}function N_(n,t=Di.Default){if(void 0===Zd)throw new F(-203,!1);return null===Zd?HT(n,void 0,t):Zd.get(n,t&Di.Optional?null:void 0,t)}function Fi(n,t=Di.Default){return(function RT(){return Tb}()||N_)(vt(n),t)}function Ri(n,t=Di.Default){return Fi(n,xm(t))}function xm(n){return typeof n>"u"||"number"==typeof n?n:0|(n.optional&&8)|(n.host&&1)|(n.self&&2)|(n.skipSelf&&4)}function Pb(n){const t=[];for(let e=0;et){o=s-1;break}}}for(;ss?"":r[d+1].toLowerCase();const p=8&i?u:null;if(p&&-1!==UT(p,h,0)||2&i&&h!==u){if(ba(i))return!1;o=!0}}}}else{if(!o&&!ba(i)&&!ba(l))return!1;if(o&&ba(l))continue;o=!1,i=l|1&i}}return ba(i)||o}function ba(n){return 0==(1&n)}function B_(n,t,e,i){if(null===t)return-1;let r=0;if(i||!e){let s=!1;for(;r-1)for(e++;e0?'="'+a+'"':"")+"]"}else 8&i?r+="."+o:4&i&&(r+=" "+o);else""!==r&&!ba(o)&&(t+=XT(s,r),r=""),i=o,s=s||!ba(i);e++}return""!==r&&(t+=XT(s,r)),t}function Rb(n){return Xl(()=>{const t=$T(n),e={...t,decls:n.decls,vars:n.vars,template:n.template,consts:n.consts||null,ngContentSelectors:n.ngContentSelectors,onPush:n.changeDetection===Tm.OnPush,directiveDefs:null,pipeDefs:null,dependencies:t.standalone&&n.dependencies||null,getStandaloneInjector:null,signals:n.signals??!1,data:n.data||{},encapsulation:n.encapsulation||Ia.Emulated,styles:n.styles||Qi,_:null,schemas:n.schemas||null,tView:null,id:""};ZT(e);const i=n.dependencies;return e.directiveDefs=Lm(i,!1),e.pipeDefs=Lm(i,!0),e.id=function q_(n){let t=0;const e=[n.selectors,n.ngContentSelectors,n.hostVars,n.hostAttrs,n.consts,n.vars,n.decls,n.encapsulation,n.standalone,n.signals,n.exportAs,JSON.stringify(n.inputs),JSON.stringify(n.outputs),Object.getOwnPropertyNames(n.type.prototype),!!n.contentQueries,!!n.viewQuery].join("|");for(const r of e)t=Math.imul(31,t)+r.charCodeAt(0)<<0;return t+=2147483648,"c"+t}(e),e})}function Q_(n){return ci(n)||jn(n)}function G_(n){return null!==n}function Am(n){return Xl(()=>({type:n.type,bootstrap:n.bootstrap||Qi,declarations:n.declarations||Qi,imports:n.imports||Qi,exports:n.exports||Qi,transitiveCompileScopes:null,schemas:n.schemas||null,id:n.id||null}))}function qT(n,t){if(null==n)return tl;const e={};for(const i in n)if(n.hasOwnProperty(i)){const r=n[i];let s,o,a=Gh.None;Array.isArray(r)?(a=r[0],s=r[1],o=r[2]??s):(s=r,o=r),t?(e[s]=a!==Gh.None?[i,a]:i,t[s]=o):e[s]=i}return e}function nr(n){return Xl(()=>{const t=$T(n);return ZT(t),t})}function ci(n){return n[Gl]||null}function jn(n){return n[qd]||null}function gs(n){return n[pf]||null}function $T(n){const t={};return{type:n.type,providersResolver:null,factory:null,hostBindings:n.hostBindings||null,hostVars:n.hostVars||0,hostAttrs:n.hostAttrs||null,contentQueries:n.contentQueries||null,declaredInputs:t,inputTransforms:null,inputConfig:n.inputs||tl,exportAs:n.exportAs||null,standalone:!0===n.standalone,signals:!0===n.signals,selectors:n.selectors||Qi,viewQuery:n.viewQuery||null,features:n.features||null,setInput:null,findHostDirectiveDefs:null,hostDirectives:null,inputs:qT(n.inputs,t),outputs:qT(n.outputs),debugInfo:null}}function ZT(n){n.features?.forEach(t=>t(n))}function Lm(n,t){if(!n)return null;const e=t?gs:Q_;return()=>("function"==typeof n?n():n).map(i=>e(i)).filter(G_)}const Vr=0,Be=1,Ct=2,vn=3,Ma=4,Os=5,wa=6,Jd=7,Er=8,Xs=9,ql=10,Yt=11,Sf=12,JT=13,Kd=14,Jr=15,If=16,eu=17,il=18,bf=19,KT=20,Xh=21,Nm=22,Uc=23,Ut=25,Hb=1,rl=7,tu=9,mn=10;var Bb=function(n){return n[n.None=0]="None",n[n.HasTransplantedViews=2]="HasTransplantedViews",n}(Bb||{});function ks(n){return Array.isArray(n)&&"object"==typeof n[Hb]}function Ps(n){return Array.isArray(n)&&!0===n[Hb]}function Fb(n){return 0!=(4&n.flags)}function jc(n){return n.componentOffset>-1}function km(n){return 1==(1&n.flags)}function Ca(n){return!!n.template}function _b(n){return 0!=(512&n[Ct])}function Vc(n,t){return n.hasOwnProperty(Uo)?n[Uo]:null}class K_{constructor(t,e,i){this.previousValue=t,this.currentValue=e,this.firstChange=i}isFirstChange(){return this.firstChange}}function rA(n,t,e,i){null!==t?t.applyValueToInputSignal(t,i):n[e]=i}function nA(n){return n.type.prototype.ngOnChanges&&(n.setInput=tU),eU}function eU(){const n=oA(this),t=n?.current;if(t){const e=n.previous;if(e===tl)n.previous=t;else for(let i in t)e[i]=t[i];n.current=null,this.ngOnChanges(t)}}function tU(n,t,e,i,r){const s=this.declaredInputs[i],o=oA(n)||function iU(n,t){return n[sA]=t}(n,{previous:tl,current:null}),a=o.current||(o.current={}),l=o.previous,h=l[s];a[s]=new K_(h&&h.currentValue,e,l===tl),rA(n,t,r,e)}const sA="__ngSimpleChanges__";function oA(n){return n[sA]||null}const nl=function(n,t,e){};let hA=!1;function pr(n){for(;Array.isArray(n);)n=n[Vr];return n}function qs(n,t){return pr(t[n.index])}function Cf(n,t){return n.data[t]}function To(n,t){const e=t[n];return ks(e)?e:e[Vr]}function Yb(n){return 128==(128&n[Ct])}function sl(n,t){return null==t?null:n[t]}function cA(n){n[eu]=0}function lU(n){1024&n[Ct]||(n[Ct]|=1024,Yb(n)&&Ef(n))}function uA(n){return 9216&n[Ct]||n[Uc]?.dirty}function Qb(n){uA(n)?Ef(n):64&n[Ct]&&(function nU(){return hA}()?(n[Ct]|=1024,Ef(n)):n[ql].changeDetectionScheduler?.notify())}function Ef(n){n[ql].changeDetectionScheduler?.notify();let t=Wc(n);for(;null!==t&&!(8192&t[Ct])&&(t[Ct]|=8192,Yb(t));)t=Wc(t)}function Wc(n){const t=n[vn];return Ps(t)?t[vn]:t}const Rt={lFrame:MA(null),bindingsEnabled:!0,skipHydrationRootTNode:null};function fA(){return Rt.bindingsEnabled}function Se(){return Rt.lFrame.lView}function xi(){return Rt.lFrame.tView}function fr(){let n=gA();for(;null!==n&&64===n.type;)n=n.parent;return n}function gA(){return Rt.lFrame.currentTNode}function ol(n,t){const e=Rt.lFrame;e.currentTNode=n,e.isParent=t}function Xb(){return Rt.lFrame.isParent}function bU(n,t){const e=Rt.lFrame;e.bindingIndex=e.bindingRootIndex=n,$b(t)}function $b(n){Rt.lFrame.currentDirectiveIndex=n}function SA(){return Rt.lFrame.currentQueryIndex}function Jb(n){Rt.lFrame.currentQueryIndex=n}function wU(n){const t=n[Be];return 2===t.type?t.declTNode:1===t.type?n[Os]:null}function IA(n,t,e){if(e&Di.SkipSelf){let r=t,s=n;for(;!(r=r.parent,null!==r||e&Di.Host||(r=wU(s),null===r||(s=s[Kd],10&r.type))););if(null===r)return!1;t=r,n=s}const i=Rt.lFrame=bA();return i.currentTNode=t,i.lView=n,!0}function Kb(n){const t=bA(),e=n[Be];Rt.lFrame=t,t.currentTNode=e.firstChild,t.lView=n,t.tView=e,t.contextLView=n,t.bindingIndex=e.bindingStartIndex,t.inI18n=!1}function bA(){const n=Rt.lFrame,t=null===n?null:n.child;return null===t?MA(n):t}function MA(n){const t={currentTNode:null,isParent:!0,lView:null,tView:null,selectedIndex:-1,contextLView:null,elementDepthCount:0,currentNamespace:null,currentDirectiveIndex:-1,bindingRootIndex:-1,bindingIndex:-1,currentQueryIndex:0,parent:n,child:null,inI18n:!1};return null!==n&&(n.child=t),t}function wA(){const n=Rt.lFrame;return Rt.lFrame=n.parent,n.currentTNode=null,n.lView=null,n}const CA=wA;function e1(){const n=wA();n.isParent=!0,n.tView=null,n.selectedIndex=-1,n.contextLView=null,n.elementDepthCount=0,n.currentDirectiveIndex=-1,n.currentNamespace=null,n.bindingRootIndex=-1,n.bindingIndex=-1,n.currentQueryIndex=0}function zs(){return Rt.lFrame.selectedIndex}function Yc(n){Rt.lFrame.selectedIndex=n}let DA=!0;function Rm(){return DA}function qh(n){DA=n}function Hm(n,t){for(let e=t.directiveStart,i=t.directiveEnd;e=i)break}else t[l]<0&&(n[eu]+=65536),(a>14>16&&(3&n[Ct])===t&&(n[Ct]+=16384,TA(a,s)):TA(a,s)}const nu=-1;class xf{constructor(t,e,i){this.factory=t,this.resolving=!1,this.canSeeViewProviders=e,this.injectImpl=i}}function r1(n){return n!==nu}function Tf(n){return 32767&n}function Af(n,t){let e=function zU(n){return n>>16}(n),i=t;for(;e>0;)i=i[Kd],e--;return i}let n1=!0;function _m(n){const t=n1;return n1=n,t}const AA=255,LA=5;let RU=0;const ll={};function Um(n,t){const e=NA(n,t);if(-1!==e)return e;const i=t[Be];i.firstCreatePass&&(n.injectorIndex=t.length,s1(i.data,n),s1(t,null),s1(i.blueprint,null));const r=jm(n,t),s=n.injectorIndex;if(r1(r)){const o=Tf(r),a=Af(r,t),l=a[Be].data;for(let h=0;h<8;h++)t[s+h]=a[o+h]|l[o+h]}return t[s+8]=r,s}function s1(n,t){n.push(0,0,0,0,0,0,0,0,t)}function NA(n,t){return-1===n.injectorIndex||n.parent&&n.parent.injectorIndex===n.injectorIndex||null===t[n.injectorIndex+8]?-1:n.injectorIndex}function jm(n,t){if(n.parent&&-1!==n.parent.injectorIndex)return n.parent.injectorIndex;let e=0,i=null,r=t;for(;null!==r;){if(i=BA(r),null===i)return nu;if(e++,r=r[Kd],-1!==i.injectorIndex)return i.injectorIndex|e<<16}return nu}function o1(n,t,e){!function HU(n,t,e){let i;"string"==typeof e?i=e.charCodeAt(0)||0:e.hasOwnProperty(jo)&&(i=e[jo]),null==i&&(i=e[jo]=RU++);const r=i&AA;t.data[n+(r>>LA)]|=1<=0?t&AA:UU:t}(e);if("function"==typeof s){if(!IA(t,n,i))return i&Di.Host?OA(r,0,i):kA(t,e,i,r);try{let o;if(o=s(i),null!=o||i&Di.Optional)return o;Db()}finally{CA()}}else if("number"==typeof s){let o=null,a=NA(n,t),l=nu,h=i&Di.Host?t[Jr][Os]:null;for((-1===a||i&Di.SkipSelf)&&(l=-1===a?jm(n,t):t[a+8],l!==nu&&HA(i,!1)?(o=t[Be],a=Tf(l),t=Af(l,t)):a=-1);-1!==a;){const c=t[Be];if(RA(s,a,c.data)){const d=FU(a,t,e,o,i,h);if(d!==ll)return d}l=t[a+8],l!==nu&&HA(i,t[Be].data[a+8]===h)&&RA(s,a,t)?(o=c,a=Tf(l),t=Af(l,t)):a=-1}}return r}function FU(n,t,e,i,r,s){const o=t[Be],a=o.data[n+8],c=Vm(a,o,e,null==i?jc(a)&&n1:i!=o&&0!=(3&a.type),r&Di.Host&&s===a);return null!==c?Qc(t,o,c,a):ll}function Vm(n,t,e,i,r){const s=n.providerIndexes,o=t.data,a=1048575&s,l=n.directiveStart,c=s>>20,u=r?a+c:n.directiveEnd;for(let p=i?a:a+c;p=l&&f.type===e)return p}if(r){const p=o[l];if(p&&Ca(p)&&p.type===e)return l}return null}function Qc(n,t,e,i){let r=n[e];const s=t.data;if(function NU(n){return n instanceof xf}(r)){const o=r;o.resolving&&function Vo(n,t){const e=t?`. Dependency path: ${t.join(" > ")} > ${n}`:"";throw new F(-200,`Circular dependency in DI detected for ${n}${e}`)}(zi(s[e]));const a=_m(o.canSeeViewProviders);o.resolving=!0;const h=o.injectImpl?no(o.injectImpl):null;IA(n,i,Di.Default);try{r=n[e]=o.factory(void 0,s,n,i),t.firstCreatePass&&e>=i.directiveStart&&function AU(n,t,e){const{ngOnChanges:i,ngOnInit:r,ngDoCheck:s}=t.type.prototype;if(i){const o=nA(t);(e.preOrderHooks??=[]).push(n,o),(e.preOrderCheckHooks??=[]).push(n,o)}r&&(e.preOrderHooks??=[]).push(0-n,r),s&&((e.preOrderHooks??=[]).push(n,s),(e.preOrderCheckHooks??=[]).push(n,s))}(e,s[e],t)}finally{null!==h&&no(h),_m(a),o.resolving=!1,CA()}}return r}function RA(n,t,e){return!!(e[t+(n>>LA)]&1<Array.isArray(e)?uu(e,t):t(e))}function _A(n,t,e){t>=n.length?n.push(e):n.splice(t,0,e)}function Wm(n,t){return t>=n.length-1?n.pop():n.splice(t,1)[0]}const gu=new Ht(""),QA=new Ht("",-1),v1=new Ht("");class Xm{get(t,e=vf){if(e===vf){const i=new Error(`NullInjectorError: No provider for ${dt(t)}!`);throw i.name="NullInjectorError",i}return e}}function dj(...n){return{\u0275providers:GA(0,n),\u0275fromNgModule:!0}}function GA(n,...t){const e=[],i=new Set;let r;const s=o=>{e.push(o)};return uu(t,o=>{const a=o;qm(a,s,[],i)&&(r||=[],r.push(a))}),void 0!==r&&XA(r,s),e}function XA(n,t){for(let e=0;e{t(s,i)})}}function qm(n,t,e,i){if(!(n=vt(n)))return!1;let r=null,s=Cm(n);const o=!s&&ci(n);if(s||o){if(o&&!o.standalone)return!1;r=n}else{const l=n.ngModule;if(s=Cm(l),!s)return!1;r=l}const a=i.has(r);if(o){if(a)return!1;if(i.add(r),o.dependencies){const l="function"==typeof o.dependencies?o.dependencies():o.dependencies;for(const h of l)qm(h,t,e,i)}}else{if(!s)return!1;{if(null!=s.imports&&!a){let h;i.add(r);try{uu(s.imports,c=>{qm(c,t,e,i)&&(h||=[],h.push(c))})}finally{}void 0!==h&&XA(h,t)}if(!a){const h=Vc(r)||(()=>new r);t({provide:r,useFactory:h,deps:Qi},r),t({provide:v1,useValue:r,multi:!0},r),t({provide:gu,useValue:()=>Fi(r),multi:!0},r)}const l=s.providers;if(null!=l&&!a){const h=n;y1(l,c=>{t(c,h)})}}}return r!==n&&void 0!==n.providers}function y1(n,t){for(let e of n)Ql(e)&&(e=e.\u0275providers),Array.isArray(e)?y1(e,t):t(e)}const uj=Xe({provide:String,useValue:Xe});function S1(n){return null!==n&&"object"==typeof n&&uj in n}function Gc(n){return"function"==typeof n}const I1=new Ht(""),$m={},fj={};let b1;function Zm(){return void 0===b1&&(b1=new Xm),b1}class Jl{}class vu extends Jl{get destroyed(){return this._destroyed}constructor(t,e,i,r){super(),this.parent=e,this.source=i,this.scopes=r,this.records=new Map,this._ngOnDestroyHooks=new Set,this._onDestroyHooks=[],this._destroyed=!1,w1(t,o=>this.processProvider(o)),this.records.set(QA,mu(void 0,this)),r.has("environment")&&this.records.set(Jl,mu(void 0,this));const s=this.records.get(I1);null!=s&&"string"==typeof s.value&&this.scopes.add(s.value),this.injectorDefTypes=new Set(this.get(v1,Qi,Di.Self))}destroy(){this.assertNotDestroyed(),this._destroyed=!0;try{for(const e of this._ngOnDestroyHooks)e.ngOnDestroy();const t=this._onDestroyHooks;this._onDestroyHooks=[];for(const e of t)e()}finally{this.records.clear(),this._ngOnDestroyHooks.clear(),this.injectorDefTypes.clear()}}onDestroy(t){return this.assertNotDestroyed(),this._onDestroyHooks.push(t),()=>this.removeOnDestroy(t)}runInContext(t){this.assertNotDestroyed();const e=Qh(this),i=no(void 0);try{return t()}finally{Qh(e),no(i)}}get(t,e=vf,i=Di.Default){if(this.assertNotDestroyed(),t.hasOwnProperty(ff))return t[ff](this);i=xm(i);const s=Qh(this),o=no(void 0);try{if(!(i&Di.SkipSelf)){let l=this.records.get(t);if(void 0===l){const h=function Sj(n){return"function"==typeof n||"object"==typeof n&&n instanceof Ht}(t)&&wm(t);l=h&&this.injectableDefInScope(h)?mu(M1(t),$m):null,this.records.set(t,l)}if(null!=l)return this.hydrate(t,l)}return(i&Di.Self?Zm():this.parent).get(t,e=i&Di.Optional&&e===vf?null:e)}catch(a){if("NullInjectorError"===a.name){if((a[Dm]=a[Dm]||[]).unshift(dt(t)),s)throw a;return function k_(n,t,e,i){const r=n[Dm];throw t[FT]&&r.unshift(t[FT]),n.message=function P_(n,t,e,i=null){n=n&&"\n"===n.charAt(0)&&"\u0275"==n.charAt(1)?n.slice(2):n;let r=dt(t);if(Array.isArray(t))r=t.map(dt).join(" -> ");else if("object"==typeof t){let s=[];for(let o in t)if(t.hasOwnProperty(o)){let a=t[o];s.push(o+":"+("string"==typeof a?JSON.stringify(a):dt(a)))}r=`{${s.join(", ")}}`}return`${e}${i?"("+i+")":""}[${r}]: ${n.replace(T_,"\n ")}`}("\n"+n.message,r,e,i),n.ngTokenPath=r,n[Dm]=null,n}(a,t,"R3InjectorError",this.source)}throw a}finally{no(o),Qh(s)}}resolveInjectorInitializers(){const t=Qh(this),e=no(void 0);try{const r=this.get(gu,Qi,Di.Self);for(const s of r)s()}finally{Qh(t),no(e)}}toString(){const t=[],e=this.records;for(const i of e.keys())t.push(dt(i));return`R3Injector[${t.join(", ")}]`}assertNotDestroyed(){if(this._destroyed)throw new F(205,!1)}processProvider(t){let e=Gc(t=vt(t))?t:vt(t&&t.provide);const i=function vj(n){return S1(n)?mu(void 0,n.useValue):mu(ZA(n),$m)}(t);if(!Gc(t)&&!0===t.multi){let r=this.records.get(e);r||(r=mu(void 0,$m,!0),r.factory=()=>Pb(r.multi),this.records.set(e,r)),e=t,r.multi.push(t)}this.records.set(e,i)}hydrate(t,e){return e.value===$m&&(e.value=fj,e.value=e.factory()),"object"==typeof e.value&&e.value&&function yj(n){return null!==n&&"object"==typeof n&&"function"==typeof n.ngOnDestroy}(e.value)&&this._ngOnDestroyHooks.add(e.value),e.value}injectableDefInScope(t){if(!t.providedIn)return!1;const e=vt(t.providedIn);return"string"==typeof e?"any"===e||this.scopes.has(e):this.injectorDefTypes.has(e)}removeOnDestroy(t){const e=this._onDestroyHooks.indexOf(t);-1!==e&&this._onDestroyHooks.splice(e,1)}}function M1(n){const t=wm(n),e=null!==t?t.factory:Vc(n);if(null!==e)return e;if(n instanceof Ht)throw new F(204,!1);if(n instanceof Function)return function gj(n){if(n.length>0)throw new F(204,!1);const e=function C_(n){return n&&(n[Em]||n[zT])||null}(n);return null!==e?()=>e.factory(n):()=>new n}(n);throw new F(204,!1)}function ZA(n,t,e){let i;if(Gc(n)){const r=vt(n);return Vc(r)||M1(r)}if(S1(n))i=()=>vt(n.useValue);else if(function $A(n){return!(!n||!n.useFactory)}(n))i=()=>n.useFactory(...Pb(n.deps||[]));else if(function qA(n){return!(!n||!n.useExisting)}(n))i=()=>Fi(vt(n.useExisting));else{const r=vt(n&&(n.useClass||n.provide));if(!function mj(n){return!!n.deps}(n))return Vc(r)||M1(r);i=()=>new r(...Pb(n.deps))}return i}function mu(n,t,e=!1){return{factory:n,value:t,multi:e?[]:void 0}}function w1(n,t){for(const e of n)Array.isArray(e)?w1(e,t):e&&Ql(e)?w1(e.\u0275providers,t):t(e)}function tL(n,t=null,e=null,i){const r=function iL(n,t=null,e=null,i,r=new Set){const s=[e||Qi,dj(n)];return i=i||("object"==typeof n?void 0:dt(n)),new vu(s,t||Zm(),i||null,r)}(n,t,e,i);return r.resolveInjectorInitializers(),r}let D1,Wo=(()=>{class n{static{this.THROW_IF_NOT_FOUND=vf}static{this.NULL=new Xm}static create(e,i){if(Array.isArray(e))return tL({name:""},i,e,"");{const r=e.name??"";return tL({name:r},e.parent,e.providers,r)}}static{this.\u0275prov=Yi({token:n,providedIn:"any",factory:()=>Fi(QA)})}static{this.__NG_ELEMENT_ID__=-1}}return n})();const x1=new Ht("",{providedIn:"root",factory:()=>Tj}),Tj="ng",nL=new Ht(""),yu=new Ht("",{providedIn:"platform",factory:()=>"unknown"}),sL=new Ht("",{providedIn:"root",factory:()=>function $h(){if(void 0!==D1)return D1;if(typeof document<"u")return document;throw new F(210,!1)}().body?.querySelector("[ngCspNonce]")?.getAttribute("ngCspNonce")||null});function iy(n){return 128==(128&n.flags)}var Kh=function(n){return n[n.Important=1]="Important",n[n.DashCase=2]="DashCase",n}(Kh||{});const O1=new Map;let Uj=0;const P1="__ngContext__";function Rs(n,t){ks(t)?(n[P1]=t[bf],function Vj(n){O1.set(n[bf],n)}(t)):n[P1]=t}let z1;function R1(n,t){return z1(n,t)}function Iu(n,t,e,i,r){if(null!=i){let s,o=!1;Ps(i)?s=i:ks(i)&&(o=!0,i=i[Vr]);const a=pr(i);0===n&&null!==e?null==r?xL(t,e,a):qc(t,e,a,r||null,!0):1===n&&null!==e?qc(t,e,a,r||null,!0):2===n?function hy(n,t,e){const i=ay(n,t);i&&function s6(n,t,e,i){n.removeChild(t,e,i)}(n,i,t,e)}(t,a,o):3===n&&t.destroyNode(a),null!=s&&function l6(n,t,e,i,r){const s=e[rl];s!==pr(e)&&Iu(t,n,i,s,r);for(let a=mn;a0&&(n[e-1][Ma]=i[Ma]);const s=Wm(n,mn+t);!function Jj(n,t){CL(n,t),t[Vr]=null,t[Os]=null}(i[Be],i);const o=s[il];null!==o&&o.detachView(s[Be]),i[vn]=null,i[Ma]=null,i[Ct]&=-129}return i}function oy(n,t){if(!(256&t[Ct])){const e=t[Yt];e.destroyNode&&cy(n,t,e,3,null,null),function e6(n){let t=n[Sf];if(!t)return B1(n[Be],n);for(;t;){let e=null;if(ks(t))e=t[Sf];else{const i=t[mn];i&&(e=i)}if(!e){for(;t&&!t[Ma]&&t!==n;)ks(t)&&B1(t[Be],t),t=t[vn];null===t&&(t=n),ks(t)&&B1(t[Be],t),e=t&&t[Ma]}t=e}}(t)}}function B1(n,t){if(!(256&t[Ct])){t[Ct]&=-129,t[Ct]|=256,t[Uc]&&function Yd(n){if(Vl(n),Vh(n))for(let t=0;t=0?i[o]():i[-o].unsubscribe(),s+=2}else e[s].call(i[e[s+1]]);null!==i&&(t[Jd]=null);const r=t[Xh];if(null!==r){t[Xh]=null;for(let s=0;s-1){const{encapsulation:s}=n.data[i.directiveStart+r];if(s===Ia.None||s===Ia.Emulated)return null}return qs(i,e)}}(n,t.parent,e)}function qc(n,t,e,i,r){n.insertBefore(t,e,i,r)}function xL(n,t,e){n.appendChild(t,e)}function TL(n,t,e,i,r){null!==i?qc(n,t,e,i,r):xL(n,t,e)}function ay(n,t){return n.parentNode(t)}let _1,NL=function LL(n,t,e){return 40&n.type?qs(n,e):null};function ly(n,t,e,i){const r=F1(n,i,t),s=t[Yt],a=function AL(n,t,e){return NL(n,t,e)}(i.parent||t[Os],i,t);if(null!=r)if(Array.isArray(e))for(let l=0;lnull;function iM(n,t,e=!1){return ZL(n,t,e)}class Y6{}class iN{}class G6{resolveComponentFactory(t){throw function Q6(n){const t=Error(`No component factory found for ${dt(n)}.`);return t.ngComponent=n,t}(t)}}let Sy=(()=>{class n{static{this.NULL=new G6}}return n})();function X6(){return Du(fr(),Se())}function Du(n,t){return new $c(qs(n,t))}let $c=(()=>{class n{constructor(e){this.nativeElement=e}static{this.__NG_ELEMENT_ID__=X6}}return n})();function q6(n){return n instanceof $c?n.nativeElement:n}class nN{}let oM=(()=>{class n{constructor(){this.destroyNode=null}static{this.__NG_ELEMENT_ID__=()=>function $6(){const n=Se(),e=To(fr().index,n);return(ks(e)?e:n)[Yt]}()}}return n})(),Z6=(()=>{class n{static{this.\u0275prov=Yi({token:n,providedIn:"root",factory:()=>null})}}return n})();const aM={};function Wf(n,t,e,i,r=!1){for(;null!==e;){const s=t[e.index];null!==s&&i.push(pr(s)),Ps(s)&&uN(s,i);const o=e.type;if(8&o)Wf(n,t,e.child,i);else if(32&o){const a=R1(e,t);let l;for(;l=a();)i.push(l)}else if(16&o){const a=kL(t,e);if(Array.isArray(a))i.push(...a);else{const l=Wc(t[Jr]);Wf(l[Be],l,a,i,!0)}}e=r?e.projectionNext:e.next}return i}function uN(n,t){for(let e=mn;e!1,producerRecomputeValue:()=>{},consumerMarkedDirty:()=>{},consumerOnSignalRead:()=>{},consumerIsAlwaysLive:!0,consumerMarkedDirty:n=>{Ef(n.lView)},consumerOnSignalRead(){this.lView[Uc]=this}};function fN(n){return vN(n[Sf])}function gN(n){return vN(n[Ma])}function vN(n){for(;null!==n&&!Ps(n);)n=n[Ma];return n}function cM(n){return n.ngOriginalError}class eh{constructor(){this._console=console}handleError(t){const e=this._findOriginalError(t);this._console.error("ERROR",t),e&&this._console.error("ORIGINAL ERROR",e)}_findOriginalError(t){let e=t&&cM(t);for(;e&&cM(e);)e=cM(e);return e||null}}const yN=new Ht("",{providedIn:"root",factory:()=>Ri(eh).handleError.bind(void 0)}),IN=new Ht("",{providedIn:"root",factory:()=>!1}),Qt={};function EN(n,t,e,i){if(!i)if(3==(3&t[Ct])){const s=n.preOrderCheckHooks;null!==s&&Bm(t,s,e)}else{const s=n.preOrderHooks;null!==s&&Fm(t,s,0,e)}Yc(e)}function Ot(n,t=Di.Default){const e=Se();return null===e?Fi(n,t):PA(fr(),e,vt(n),t)}function DN(n,t,e,i,r,s){const o=Wi(null);try{let a=null;r&Gh.SignalBased&&(a=t[i][Ts]),null!==a&&void 0!==a.transformFn&&(s=a.transformFn(s)),r&Gh.HasDecoratorInputTransform&&(s=n.inputTransforms[i].call(t,s)),null!==n.setInput?n.setInput(t,a,s,e,i):rA(t,a,i,s)}finally{Wi(o)}}function wy(n,t,e,i,r,s,o,a,l,h,c){const d=t.blueprint.slice();return d[Vr]=r,d[Ct]=204|i,(null!==h||n&&2048&n[Ct])&&(d[Ct]|=2048),cA(d),d[vn]=d[Kd]=n,d[Er]=e,d[ql]=o||n&&n[ql],d[Yt]=a||n&&n[Yt],d[Xs]=l||n&&n[Xs]||null,d[Os]=s,d[bf]=function jj(){return Uj++}(),d[wa]=c,d[KT]=h,d[Jr]=2==t.type?n[Jr]:d,d}function xu(n,t,e,i,r){let s=n.data[t];if(null===s)s=function dM(n,t,e,i,r){const s=gA(),o=Xb(),l=n.data[t]=function TV(n,t,e,i,r,s){let o=t?t.injectorIndex:-1,a=0;return function ru(){return null!==Rt.skipHydrationRootTNode}()&&(a|=128),{type:e,index:i,insertBeforeIndex:null,injectorIndex:o,directiveStart:-1,directiveEnd:-1,directiveStylingLast:-1,componentOffset:-1,propertyBindings:null,flags:a,providerIndexes:0,value:r,attrs:s,mergedAttrs:null,localNames:null,initialInputs:void 0,inputs:null,outputs:null,tView:null,next:null,prev:null,projectionNext:null,child:null,parent:t,projection:null,styles:null,stylesWithoutHost:null,residualStyles:void 0,classes:null,classesWithoutHost:null,residualClasses:void 0,classBindings:0,styleBindings:0}}(0,o?s:s&&s.parent,e,t,i,r);return null===n.firstChild&&(n.firstChild=l),null!==s&&(o?null==s.child&&null!==l.parent&&(s.child=l):null===s.next&&(s.next=l,l.prev=s)),l}(n,t,e,i,r),function IU(){return Rt.lFrame.inI18n}()&&(s.flags|=32);else if(64&s.type){s.type=e,s.value=i,s.attrs=r;const o=function Df(){const n=Rt.lFrame,t=n.currentTNode;return n.isParent?t:t.parent}();s.injectorIndex=null===o?-1:o.injectorIndex}return ol(s,!0),s}function Yf(n,t,e,i){if(0===e)return-1;const r=t.length;for(let s=0;sUt&&EN(n,t,Ut,!1),nl(o?2:0,r),e(i,r)}finally{Yc(s),nl(o?3:1,r)}}function uM(n,t,e){if(Fb(t)){const i=Wi(null);try{const s=t.directiveEnd;for(let o=t.directiveStart;onull;function LN(n,t,e,i,r){for(let s in t){if(!t.hasOwnProperty(s))continue;const o=t[s];if(void 0===o)continue;i??={};let a,l=Gh.None;Array.isArray(o)?(a=o[0],l=o[1]):a=o;let h=s;if(null!==r){if(!r.hasOwnProperty(s))continue;h=r[s]}0===n?NN(i,e,h,a,l):NN(i,e,h,a)}return i}function NN(n,t,e,i,r){let s;n.hasOwnProperty(e)?(s=n[e]).push(t,i):s=n[e]=[t,i],void 0!==r&&s.push(r)}function ON(n,t,e,i,r,s){for(let h=0;h0;){const e=n[--t];if("number"==typeof e&&e<0)return e}return 0})(o)!=a&&o.push(a),o.push(e,i,s)}}(n,t,i,Yf(n,e,r.hostVars,Qt),r)}function VV(n,t,e,i,r,s){const o=s[t];if(null!==o)for(let a=0;an.nextProducerIndex;)n.producerNode.pop(),n.producerLastReadVersion.pop(),n.producerIndexOfThis.pop()}}(a,o),function dV(n){n.lView[Uc]!==n&&(n.lView=null,pN.push(n))}(a)),e1()}}function FN(n,t){for(let e=fN(n);null!==e;e=gN(e))for(let i=mn;i-1&&(Rf(t,i),Wm(e,i))}this._attachedToViewContainer=!1}oy(this._lView[Be],this._lView)}onDestroy(t){!function zm(n,t){if(256==(256&n[Ct]))throw new F(911,!1);null===n[Xh]&&(n[Xh]=[]),n[Xh].push(t)}(this._lView,t)}markForCheck(){Qf(this._cdRefInjectingView||this._lView)}detach(){this._lView[Ct]&=-129}reattach(){Qb(this._lView),this._lView[Ct]|=128}detectChanges(){this._lView[Ct]|=1024,function bM(n,t=!0){const e=n[ql],i=e.rendererFactory;i.begin?.();try{!function QV(n){MM(n,0);let t=0;for(;uA(n);){if(100===t)throw new F(103,!1);t++,MM(n,1)}}(n)}catch(s){throw t&&Ey(n,s),s}finally{i.end?.(),e.inlineEffectRunner?.flush()}}(this._lView,this.notifyErrorHandler)}checkNoChanges(){}attachToViewContainerRef(){if(this._appRef)throw new F(902,!1);this._attachedToViewContainer=!0}detachFromAppRef(){this._appRef=null,CL(this._lView[Be],this._lView)}attachToAppRef(t){if(this._attachedToViewContainer)throw new F(902,!1);this._appRef=t,Qb(this._lView)}}const VN=new Set;function CM(n){return t=>{setTimeout(n,void 0,t)}}const Yo=class a7 extends Pt{constructor(t=!1){super(),this.__isAsync=t}emit(t){super.next(t)}subscribe(t,e,i){let r=t,s=e||(()=>null),o=i;if(t&&"object"==typeof t){const l=t;r=l.next?.bind(l),s=l.error?.bind(l),o=l.complete?.bind(l)}this.__isAsync&&(s=CM(s),r&&(r=CM(r)),o&&(o=CM(o)));const a=super.subscribe({next:r,error:s,complete:o});return t instanceof As&&t.add(a),a}};function WN(...n){}class zr{constructor({enableLongStackTrace:t=!1,shouldCoalesceEventChangeDetection:e=!1,shouldCoalesceRunChangeDetection:i=!1}){if(this.hasPendingMacrotasks=!1,this.hasPendingMicrotasks=!1,this.isStable=!0,this.onUnstable=new Yo(!1),this.onMicrotaskEmpty=new Yo(!1),this.onStable=new Yo(!1),this.onError=new Yo(!1),typeof Zone>"u")throw new F(908,!1);Zone.assertZonePatched();const r=this;r._nesting=0,r._outer=r._inner=Zone.current,Zone.TaskTrackingZoneSpec&&(r._inner=r._inner.fork(new Zone.TaskTrackingZoneSpec)),t&&Zone.longStackTraceZoneSpec&&(r._inner=r._inner.fork(Zone.longStackTraceZoneSpec)),r.shouldCoalesceEventChangeDetection=!i&&e,r.shouldCoalesceRunChangeDetection=i,r.lastRequestAnimationFrameId=-1,r.nativeRequestAnimationFrame=function l7(){const n="function"==typeof rr.requestAnimationFrame;let t=rr[n?"requestAnimationFrame":"setTimeout"],e=rr[n?"cancelAnimationFrame":"clearTimeout"];if(typeof Zone<"u"&&t&&e){const i=t[Zone.__symbol__("OriginalDelegate")];i&&(t=i);const r=e[Zone.__symbol__("OriginalDelegate")];r&&(e=r)}return{nativeRequestAnimationFrame:t,nativeCancelAnimationFrame:e}}().nativeRequestAnimationFrame,function d7(n){const t=()=>{!function c7(n){n.isCheckStableRunning||-1!==n.lastRequestAnimationFrameId||(n.lastRequestAnimationFrameId=n.nativeRequestAnimationFrame.call(rr,()=>{n.fakeTopEventTask||(n.fakeTopEventTask=Zone.root.scheduleEventTask("fakeTopEventTask",()=>{n.lastRequestAnimationFrameId=-1,DM(n),n.isCheckStableRunning=!0,EM(n),n.isCheckStableRunning=!1},void 0,()=>{},()=>{})),n.fakeTopEventTask.invoke()}),DM(n))}(n)};n._inner=n._inner.fork({name:"angular",properties:{isAngularZone:!0},onInvokeTask:(e,i,r,s,o,a)=>{if(function u7(n){return!(!Array.isArray(n)||1!==n.length)&&!0===n[0].data?.__ignore_ng_zone__}(a))return e.invokeTask(r,s,o,a);try{return YN(n),e.invokeTask(r,s,o,a)}finally{(n.shouldCoalesceEventChangeDetection&&"eventTask"===s.type||n.shouldCoalesceRunChangeDetection)&&t(),QN(n)}},onInvoke:(e,i,r,s,o,a,l)=>{try{return YN(n),e.invoke(r,s,o,a,l)}finally{n.shouldCoalesceRunChangeDetection&&t(),QN(n)}},onHasTask:(e,i,r,s)=>{e.hasTask(r,s),i===r&&("microTask"==s.change?(n._hasPendingMicrotasks=s.microTask,DM(n),EM(n)):"macroTask"==s.change&&(n.hasPendingMacrotasks=s.macroTask))},onHandleError:(e,i,r,s)=>(e.handleError(r,s),n.runOutsideAngular(()=>n.onError.emit(s)),!1)})}(r)}static isInAngularZone(){return typeof Zone<"u"&&!0===Zone.current.get("isAngularZone")}static assertInAngularZone(){if(!zr.isInAngularZone())throw new F(909,!1)}static assertNotInAngularZone(){if(zr.isInAngularZone())throw new F(909,!1)}run(t,e,i){return this._inner.run(t,e,i)}runTask(t,e,i,r){const s=this._inner,o=s.scheduleEventTask("NgZoneEvent: "+r,t,h7,WN,WN);try{return s.runTask(o,e,i)}finally{s.cancelTask(o)}}runGuarded(t,e,i){return this._inner.runGuarded(t,e,i)}runOutsideAngular(t){return this._outer.run(t)}}const h7={};function EM(n){if(0==n._nesting&&!n.hasPendingMicrotasks&&!n.isStable)try{n._nesting++,n.onMicrotaskEmpty.emit(null)}finally{if(n._nesting--,!n.hasPendingMicrotasks)try{n.runOutsideAngular(()=>n.onStable.emit(null))}finally{n.isStable=!0}}}function DM(n){n.hasPendingMicrotasks=!!(n._hasPendingMicrotasks||(n.shouldCoalesceEventChangeDetection||n.shouldCoalesceRunChangeDetection)&&-1!==n.lastRequestAnimationFrameId)}function YN(n){n._nesting++,n.isStable&&(n.isStable=!1,n.onUnstable.emit(null))}function QN(n){n._nesting--,EM(n)}let Xf=(()=>{class n{constructor(){this.handler=null,this.internalCallbacks=[]}execute(){const e=[...this.internalCallbacks];this.internalCallbacks.length=0;for(const r of e)r();return!!this.handler?.execute()||e.length>0}ngOnDestroy(){this.handler?.destroy(),this.handler=null,this.internalCallbacks.length=0}static{this.\u0275prov=Yi({token:n,providedIn:"root",factory:()=>new n})}}return n})();function v7(n,t){const e=To(t,n),i=e[Be];!function m7(n,t){for(let e=t.length;e0&&RL(n,e,s.join(" "))}}(u,w,f,i),void 0!==e&&function x7(n,t,e){const i=n.projection=[];for(let r=0;r=0;i--){const r=n[i];r.hostVars=t+=r.hostVars,r.hostAttrs=yf(r.hostAttrs,e=yf(e,r.hostAttrs))}}(i)}function A7(n,t){for(const e in t.inputs){if(!t.inputs.hasOwnProperty(e)||n.inputs.hasOwnProperty(e))continue;const i=t.inputs[e];if(void 0!==i&&(n.inputs[e]=i,n.declaredInputs[e]=t.declaredInputs[e],null!==t.inputTransforms)){const r=Array.isArray(i)?i[0]:i;if(!t.inputTransforms.hasOwnProperty(r))continue;n.inputTransforms??={},n.inputTransforms[r]=t.inputTransforms[r]}}}function xy(n){return n===tl?{}:n===Qi?[]:n}function N7(n,t){const e=n.viewQuery;n.viewQuery=e?(i,r)=>{t(i,r),e(i,r)}:t}function O7(n,t){const e=n.contentQueries;n.contentQueries=e?(i,r,s)=>{t(i,r,s),e(i,r,s)}:t}function k7(n,t){const e=n.hostBindings;n.hostBindings=e?(i,r)=>{t(i,r),e(i,r)}:t}function Au(n,t){return!t||null===t.firstChild||iy(n)}function tg(n,t,e,i=!0){const r=t[Be];if(function t6(n,t,e,i){const r=mn+i,s=e.length;i>0&&(e[r-1][Ma]=t),i{class n{static{this.__NG_ELEMENT_ID__=a9}}return n})();function a9(){return pO(fr(),Se())}const l9=xn,dO=class extends l9{constructor(t,e,i){super(),this._lContainer=t,this._hostTNode=e,this._hostLView=i}get element(){return Du(this._hostTNode,this._hostLView)}get injector(){return new Vn(this._hostTNode,this._hostLView)}get parentInjector(){const t=jm(this._hostTNode,this._hostLView);if(r1(t)){const e=Af(t,this._hostLView),i=Tf(t);return new Vn(e[Be].data[i+8],e)}return new Vn(null,this._hostLView)}clear(){for(;this.length>0;)this.remove(this.length-1)}get(t){const e=uO(this._lContainer);return null!==e&&e[t]||null}get length(){return this._lContainer.length-mn}createEmbeddedView(t,e,i){let r,s;"number"==typeof i?r=i:null!=i&&(r=i.index,s=i.injector);const a=t.createEmbeddedViewImpl(e||{},s,null);return this.insertImpl(a,r,Au(this._hostTNode,null)),a}createComponent(t,e,i,r,s){const o=t&&!function Lf(n){return"function"==typeof n}(t);let a;if(o)a=e;else{const f=e||{};a=f.index,i=f.injector,r=f.projectableNodes,s=f.environmentInjector||f.ngModuleRef}const l=o?t:new qf(ci(t)),h=i||this.parentInjector;if(!s&&null==l.ngModule){const g=(o?h:this.parentInjector).get(Jl,null);g&&(s=g)}ci(l.componentType??{});const p=l.create(h,r,null,s);return this.insertImpl(p.hostView,a,Au(this._hostTNode,null)),p}insert(t,e){return this.insertImpl(t,e,!0)}insertImpl(t,e,i){const r=t._lView;if(function aU(n){return Ps(n[vn])}(r)){const a=this.indexOf(t);if(-1!==a)this.detach(a);else{const l=r[vn],h=new dO(l,l[Os],l[vn]);h.detach(h.indexOf(t))}}const s=this._adjustIndex(e),o=this._lContainer;return tg(o,r,s,i),t.attachToViewContainerRef(),_A(PM(o),s,t),t}move(t,e){return this.insert(t,e)}indexOf(t){const e=uO(this._lContainer);return null!==e?e.indexOf(t):-1}remove(t){const e=this._adjustIndex(t,-1),i=Rf(this._lContainer,e);i&&(Wm(PM(this._lContainer),e),oy(i[Be],i))}detach(t){const e=this._adjustIndex(t,-1),i=Rf(this._lContainer,e);return i&&null!=Wm(PM(this._lContainer),e)?new Gf(i):null}_adjustIndex(t,e=0){return t??this.length+e}};function uO(n){return n[8]}function PM(n){return n[8]||(n[8]=[])}function pO(n,t){let e;const i=t[n.index];return Ps(i)?e=i:(e=function PN(n,t,e,i){return[n,!0,0,t,null,i,null,e,null,null]}(i,t,null,n),t[n.index]=e,Cy(t,e)),fO(e,t,n,i),new dO(e,n,t)}let fO=function vO(n,t,e,i){if(n[rl])return;let r;r=8&e.type?pr(i):function h9(n,t){const e=n[Yt],i=e.createComment(""),r=qs(t,n);return qc(e,ay(e,r),i,function o6(n,t){return n.nextSibling(t)}(e,r),!1),i}(t,e),n[rl]=r};function GM(n,t,e){const i=Se();return function Tn(n,t,e){return!Object.is(n[t],e)&&(n[t]=e,!0)}(i,function al(){return Rt.lFrame.bindingIndex++}(),t)&&function No(n,t,e,i,r,s,o,a){const l=qs(t,e);let c,h=t.inputs;!a&&null!=h&&(c=h[i])?(IM(n,e,c,i,r),jc(t)&&function NV(n,t){const e=To(t,n);16&e[Ct]||(e[Ct]|=64)}(e,t.index)):3&t.type&&(i=function LV(n){return"class"===n?"className":"for"===n?"htmlFor":"formaction"===n?"formAction":"innerHtml"===n?"innerHTML":"readonly"===n?"readOnly":"tabindex"===n?"tabIndex":n}(i),r=null!=o?o(r,t.value||"",i):r,s.setProperty(l,i,r))}(xi(),function Pr(){const n=Rt.lFrame;return Cf(n.tView,n.selectedIndex)}(),i,n,t,i[Yt],e,!1),GM}function XM(n,t,e,i,r){const o=r?"class":"style";IM(n,e,t.inputs[o],o,i)}function lg(n,t,e,i){const r=Se(),s=xi(),o=Ut+n,a=r[Yt],l=s.firstCreatePass?function R8(n,t,e,i,r,s){const o=t.consts,l=xu(t,n,2,i,sl(o,r));return function vM(n,t,e,i){if(fA()){const r=null===i?null:{"":-1},s=function HV(n,t){const e=n.directiveRegistry;let i=null,r=null;if(e)for(let s=0;s(qh(!0),sy(i,r,function EA(){return Rt.lFrame.currentNamespace}()));const Gu="en-US";let Mk=Gu;function sw(n){return!!n&&"function"==typeof n.then}function Gk(n){return!!n&&"function"==typeof n.subscribe}function ow(n,t,e,i){const r=Se(),s=xi(),o=fr();return function qk(n,t,e,i,r,s,o){const a=km(i),h=n.firstCreatePass&&HN(n),c=t[Er],d=RN(t);let u=!0;if(3&i.type||o){const g=qs(i,t),v=o?o(g):g,y=d.length,S=o?M=>o(pr(M[i.index])):i.index;let b=null;if(!o&&a&&(b=function FW(n,t,e,i){const r=n.cleanup;if(null!=r)for(let s=0;sl?a[l]:null}"string"==typeof o&&(s+=2)}return null}(n,t,r,i.index)),null!==b)(b.__ngLastListenerFn__||b).__ngNextListenerFn__=s,b.__ngLastListenerFn__=s,u=!1;else{s=Zk(i,t,c,s,!1);const M=e.listen(v,r,s);d.push(s,M),h&&h.push(r,S,y,y+1)}}else s=Zk(i,t,c,s,!1);const p=i.outputs;let f;if(u&&null!==p&&(f=p[r])){const g=f.length;if(g)for(let v=0;v-1?To(n.index,t):t);let l=$k(t,e,i,o),h=s.__ngNextListenerFn__;for(;h;)l=$k(t,e,h,o)&&l,h=h.__ngNextListenerFn__;return r&&!1===l&&o.preventDefault(),l}}function WW(){return this._results[Symbol.iterator]()}class lw{get changes(){return this._changes??=new Yo}constructor(t=!1){this._emitDistinctChangesOnly=t,this.dirty=!0,this._results=[],this._changesDetected=!1,this._changes=void 0,this.length=0,this.first=void 0,this.last=void 0;const e=lw.prototype;e[Symbol.iterator]||(e[Symbol.iterator]=WW)}get(t){return this._results[t]}map(t){return this._results.map(t)}filter(t){return this._results.filter(t)}find(t){return this._results.find(t)}reduce(t,e){return this._results.reduce(t,e)}forEach(t){this._results.forEach(t)}some(t){return this._results.some(t)}toArray(){return this._results.slice()}toString(){return this._results.toString()}reset(t,e){this.dirty=!1;const i=function oo(n){return n.flat(Number.POSITIVE_INFINITY)}(t);(this._changesDetected=!function XU(n,t,e){if(n.length!==t.length)return!1;for(let i=0;i{class n{static{this.__NG_ELEMENT_ID__=GW}}return n})();const YW=ih,QW=class extends YW{constructor(t,e,i){super(),this._declarationLView=t,this._declarationTContainer=e,this.elementRef=i}get ssrId(){return this._declarationTContainer.tView?.ssrId||null}createEmbeddedView(t,e){return this.createEmbeddedViewImpl(t,e)}createEmbeddedViewImpl(t,e,i){const r=function eg(n,t,e,i){const r=t.tView,a=wy(n,r,e,4096&n[Ct]?4096:16,null,t,null,null,null,i?.injector??null,i?.dehydratedView??null);a[If]=n[t.index];const h=n[il];return null!==h&&(a[il]=h.createEmbeddedView(r)),xM(r,a,e),a}(this._declarationLView,this._declarationTContainer,t,{injector:e,dehydratedView:i});return new Gf(r)}};function GW(){return Wy(fr(),Se())}function Wy(n,t){return 4&n.type?new QW(t,n,Du(n,t)):null}class hw{constructor(t){this.queryList=t,this.matches=null}clone(){return new hw(this.queryList)}setDirty(){this.queryList.setDirty()}}class cw{constructor(t=[]){this.queries=t}createEmbeddedView(t){const e=t.queries;if(null!==e){const i=null!==t.contentQueries?t.contentQueries[0]:e.length,r=[];for(let s=0;s0)i.push(o[a/2]);else{const h=s[a+1],c=t[-l];for(let d=mn;d(qh(!0),function ny(n,t){return n.createText(t)}(t[Yt],i));function gw(n,t,e,i,r){if(n=vt(n),Array.isArray(n))for(let s=0;s>20;if(Gc(n)||!n.multi){const p=new xf(h,r,Ot),f=mw(l,t,r?c:c+u,d);-1===f?(o1(Um(a,o),s,l),vw(s,n,t.length),t.push(l),a.directiveStart++,a.directiveEnd++,r&&(a.providerIndexes+=1048576),e.push(p),o.push(p)):(e[f]=p,o[f]=p)}else{const p=mw(l,t,c+u,d),f=mw(l,t,c,c+u),v=f>=0&&e[f];if(r&&!v||!r&&!(p>=0&&e[p])){o1(Um(a,o),s,l);const y=function vY(n,t,e,i,r){const s=new xf(n,e,Ot);return s.multi=[],s.index=t,s.componentProviders=0,kP(s,r,i&&!e),s}(r?gY:fY,e.length,r,i,h);!r&&v&&(e[f].providerFactory=y),vw(s,n,t.length,0),t.push(l),a.directiveStart++,a.directiveEnd++,r&&(a.providerIndexes+=1048576),e.push(y),o.push(y)}else vw(s,n,p>-1?p:f,kP(e[r?f:p],h,!r&&i));!r&&i&&v&&e[f].componentProviders++}}}function vw(n,t,e,i){const r=Gc(t),s=function pj(n){return!!n.useClass}(t);if(r||s){const l=(s?vt(t.useClass):t).prototype.ngOnDestroy;if(l){const h=n.destroyHooks||(n.destroyHooks=[]);if(!r&&t.multi){const c=h.indexOf(e);-1===c?h.push(e,[i,l]):h[c+1].push(i,l)}else h.push(e,l)}}}function kP(n,t,e){return e&&n.componentProviders++,n.multi.push(t)-1}function mw(n,t,e,i){for(let r=e;r{e.providersResolver=(i,r)=>function pY(n,t,e){const i=xi();if(i.firstCreatePass){const r=Ca(n);gw(e,i.data,i.blueprint,r,!0),gw(t,i.data,i.blueprint,r,!1)}}(i,r?r(n):n,t)}}class rd{}class zP extends rd{constructor(t){super(),this.componentFactoryResolver=new JN(this),this.instance=null;const e=new vu([...t.providers,{provide:rd,useValue:this},{provide:Sy,useValue:this.componentFactoryResolver}],t.parent||Zm(),t.debugName,new Set(["environment"]));this.injector=e,t.runEnvironmentInitializers&&e.resolveInjectorInitializers()}destroy(){this.injector.destroy()}onDestroy(t){this.injector.onDestroy(t)}}let bY=(()=>{class n{constructor(e){this._injector=e,this.cachedInjectors=new Map}getOrCreateStandaloneInjector(e){if(!e.standalone)return null;if(!this.cachedInjectors.has(e)){const i=GA(0,e.type),r=i.length>0?function IY(n,t,e=null){return new zP({providers:n,parent:t,debugName:e,runEnvironmentInitializers:!0}).injector}([i],this._injector,`Standalone[${e.type.name}]`):null;this.cachedInjectors.set(e,r)}return this.cachedInjectors.get(e)}ngOnDestroy(){try{for(const e of this.cachedInjectors.values())null!==e&&e.destroy()}finally{this.cachedInjectors.clear()}}static{this.\u0275prov=Yi({token:n,providedIn:"environment",factory:()=>new n(Fi(Jl))})}}return n})();function RP(n){(function Zc(n){VN.has(n)||(VN.add(n),performance?.mark?.("mark_feature_usage",{detail:{feature:n}}))})("NgStandalone"),n.getStandaloneInjector=t=>t.get(bY).getOrCreateStandaloneInjector(n)}let xw=(()=>{class n{constructor(){this.taskId=0,this.pendingTasks=new Set,this.hasPendingTasks=new _o(!1)}get _hasPendingTasks(){return this.hasPendingTasks.value}add(){this._hasPendingTasks||this.hasPendingTasks.next(!0);const e=this.taskId++;return this.pendingTasks.add(e),e}remove(e){this.pendingTasks.delete(e),0===this.pendingTasks.size&&this._hasPendingTasks&&this.hasPendingTasks.next(!1)}ngOnDestroy(){this.pendingTasks.clear(),this._hasPendingTasks&&this.hasPendingTasks.next(!1)}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();const g2=new Ht(""),QQ=new Ht("");let Ow=(()=>{class n{constructor(){this.initialized=!1,this.done=!1,this.donePromise=new Promise((e,i)=>{this.resolve=e,this.reject=i}),this.appInits=Ri(QQ,{optional:!0})??[]}runInitializers(){if(this.initialized)return;const e=[];for(const r of this.appInits){const s=r();if(sw(s))e.push(s);else if(Gk(s)){const o=new Promise((a,l)=>{s.subscribe({complete:a,error:l})});e.push(o)}}const i=()=>{this.done=!0,this.resolve()};Promise.all(e).then(()=>{i()}).catch(r=>{this.reject(r)}),0===e.length&&i(),this.initialized=!0}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();const v2=new Ht("");let $u=(()=>{class n{constructor(){this._bootstrapListeners=[],this._runningTick=!1,this._destroyed=!1,this._destroyListeners=[],this._views=[],this.internalErrorHandler=Ri(yN),this.afterRenderEffectManager=Ri(Xf),this.componentTypes=[],this.components=[],this.isStable=Ri(xw).hasPendingTasks.pipe(jr(e=>!e)),this._injector=Ri(Jl)}get destroyed(){return this._destroyed}get injector(){return this._injector}bootstrap(e,i){const r=e instanceof iN;if(!this._injector.get(Ow).done)throw!r&&function _c(n){const t=ci(n)||jn(n)||gs(n);return null!==t&&t.standalone}(e),new F(405,!1);let o;o=r?e:this._injector.get(Sy).resolveComponentFactory(e),this.componentTypes.push(o.componentType);const a=function XQ(n){return n.isBoundToModule}(o)?void 0:this._injector.get(rd),h=o.create(Wo.NULL,[],i||o.selector,a),c=h.location.nativeElement,d=h.injector.get(g2,null);return d?.registerApplication(c),h.onDestroy(()=>{this.detachView(h.hostView),$y(this.components,h),d?.unregisterApplication(c)}),this._loadComponent(h),h}tick(){if(this._runningTick)throw new F(101,!1);try{this._runningTick=!0;for(let e of this._views)e.detectChanges()}catch(e){this.internalErrorHandler(e)}finally{try{this.afterRenderEffectManager.execute()}catch(e){this.internalErrorHandler(e)}this._runningTick=!1}}attachView(e){const i=e;this._views.push(i),i.attachToAppRef(this)}detachView(e){const i=e;$y(this._views,i),i.detachFromAppRef()}_loadComponent(e){this.attachView(e.hostView),this.tick(),this.components.push(e);const i=this._injector.get(v2,[]);[...this._bootstrapListeners,...i].forEach(r=>r(e))}ngOnDestroy(){if(!this._destroyed)try{this._destroyListeners.forEach(e=>e()),this._views.slice().forEach(e=>e.destroy())}finally{this._destroyed=!0,this._views=[],this._bootstrapListeners=[],this._destroyListeners=[]}}onDestroy(e){return this._destroyListeners.push(e),()=>$y(this._destroyListeners,e)}destroy(){if(this._destroyed)throw new F(406,!1);const e=this._injector;e.destroy&&!e.destroyed&&e.destroy()}get viewCount(){return this._views.length}warnIfDestroyed(){}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();function $y(n,t){const e=n.indexOf(t);e>-1&&n.splice(e,1)}let $Q=(()=>{class n{constructor(){this.zone=Ri(zr),this.applicationRef=Ri($u)}initialize(){this._onMicrotaskEmptySubscription||(this._onMicrotaskEmptySubscription=this.zone.onMicrotaskEmpty.subscribe({next:()=>{this.zone.run(()=>{this.applicationRef.tick()})}}))}ngOnDestroy(){this._onMicrotaskEmptySubscription?.unsubscribe()}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();function b2(n){return[{provide:zr,useFactory:n},{provide:gu,multi:!0,useFactory:()=>{const t=Ri($Q,{optional:!0});return()=>t.initialize()}},{provide:gu,multi:!0,useFactory:()=>{const t=Ri(KQ);return()=>{t.initialize()}}},{provide:yN,useFactory:ZQ}]}function ZQ(){const n=Ri(zr),t=Ri(eh);return e=>n.runOutsideAngular(()=>t.handleError(e))}function JQ(n){return function m1(n){return{\u0275providers:n}}([[],b2(()=>new zr(function M2(n){return{enableLongStackTrace:!1,shouldCoalesceEventChangeDetection:n?.eventCoalescing??!1,shouldCoalesceRunChangeDetection:n?.runCoalescing??!1}}(n)))])}let KQ=(()=>{class n{constructor(){this.subscription=new As,this.initialized=!1,this.zone=Ri(zr),this.pendingTasks=Ri(xw)}initialize(){if(this.initialized)return;this.initialized=!0;let e=null;!this.zone.isStable&&!this.zone.hasPendingMacrotasks&&!this.zone.hasPendingMicrotasks&&(e=this.pendingTasks.add()),this.zone.runOutsideAngular(()=>{this.subscription.add(this.zone.onStable.subscribe(()=>{zr.assertNotInAngularZone(),queueMicrotask(()=>{null!==e&&!this.zone.hasPendingMacrotasks&&!this.zone.hasPendingMicrotasks&&(this.pendingTasks.remove(e),e=null)})}))}),this.subscription.add(this.zone.onUnstable.subscribe(()=>{zr.assertInAngularZone(),e??=this.pendingTasks.add()}))}ngOnDestroy(){this.subscription.unsubscribe()}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();const rh=new Ht("",{providedIn:"root",factory:()=>Ri(rh,Di.Optional|Di.SkipSelf)||function eG(){return typeof $localize<"u"&&$localize.locale||Gu}()}),kw=new Ht("");let rc=null;function CG(n){try{const{rootComponent:t,appProviders:e,platformProviders:i}=n,r=function sG(n=[]){if(rc)return rc;const t=function E2(n=[],t){return Wo.create({name:t,providers:[{provide:I1,useValue:"platform"},{provide:kw,useValue:new Set([()=>rc=null])},...n]})}(n);return rc=t,function m2(){!function yb(n){Gd=n}(()=>{throw new F(600,!1)})}(),function D2(n){n.get(nL,null)?.forEach(e=>e())}(t),t}(i),s=[JQ(),...e||[]],a=new zP({providers:s,parent:r,debugName:"",runEnvironmentInitializers:!1}).injector,l=a.get(zr);return l.run(()=>{a.resolveInjectorInitializers();const h=a.get(eh,null);let c;l.runOutsideAngular(()=>{c=l.onError.subscribe({next:p=>{h.handleError(p)}})});const d=()=>a.destroy(),u=r.get(kw);return u.add(d),a.onDestroy(()=>{c.unsubscribe(),u.delete(d)}),function y2(n,t,e){try{const i=e();return sw(i)?i.catch(r=>{throw t.runOutsideAngular(()=>n.handleError(r)),r}):i}catch(i){throw t.runOutsideAngular(()=>n.handleError(i)),i}}(h,l,()=>{const p=a.get(Ow);return p.runInitializers(),p.donePromise.then(()=>{!function wk(n){ro(n,"Expected localeId to be defined"),"string"==typeof n&&(Mk=n.toLowerCase().replace(/_/g,"-"))}(a.get(rh,Gu)||Gu);const g=a.get($u);return void 0!==t&&g.bootstrap(t),g})})})}catch(t){return Promise.reject(t)}}let $2=null;function Uw(){return $2}class FG{}const sd=new Ht("");let rq=(()=>{class n{static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275mod=Am({type:n})}static{this.\u0275inj=gf({})}}return n})();function uz(n){return"server"===n}class Nq extends FG{constructor(){super(...arguments),this.supportsDOMEvents=!0}}class nC extends Nq{static makeCurrent(){!function BG(n){$2??=n}(new nC)}onAndCancel(t,e,i){return t.addEventListener(e,i),()=>{t.removeEventListener(e,i)}}dispatchEvent(t,e){t.dispatchEvent(e)}remove(t){t.parentNode&&t.parentNode.removeChild(t)}createElement(t,e){return(e=e||this.getDefaultDocument()).createElement(t)}createHtmlDocument(){return document.implementation.createHTMLDocument("fakeTitle")}getDefaultDocument(){return document}isElementNode(t){return t.nodeType===Node.ELEMENT_NODE}isShadowRoot(t){return t instanceof DocumentFragment}getGlobalEventTarget(t,e){return"window"===e?window:"document"===e?t:"body"===e?t.body:null}getBaseHref(t){const e=function Oq(){return wg=wg||document.querySelector("base"),wg?wg.getAttribute("href"):null}();return null==e?null:function kq(n){return new URL(n,document.baseURI).pathname}(e)}resetBaseElement(){wg=null}getUserAgent(){return window.navigator.userAgent}getCookie(t){return function EX(n,t){t=encodeURIComponent(t);for(const e of n.split(";")){const i=e.indexOf("="),[r,s]=-1==i?[e,""]:[e.slice(0,i),e.slice(i+1)];if(r.trim()===t)return decodeURIComponent(s)}return null}(document.cookie,t)}}let wg=null,zq=(()=>{class n{build(){return new XMLHttpRequest}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();const sC=new Ht("");let vz=(()=>{class n{constructor(e,i){this._zone=i,this._eventNameToPlugin=new Map,e.forEach(r=>{r.manager=this}),this._plugins=e.slice().reverse()}addEventListener(e,i,r){return this._findPluginFor(i).addEventListener(e,i,r)}getZone(){return this._zone}_findPluginFor(e){let i=this._eventNameToPlugin.get(e);if(i)return i;if(i=this._plugins.find(s=>s.supports(e)),!i)throw new F(5101,!1);return this._eventNameToPlugin.set(e,i),i}static{this.\u0275fac=function(i){return new(i||n)(Fi(sC),Fi(zr))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();class mz{constructor(t){this._doc=t}}const oC="ng-app-id";let yz=(()=>{class n{constructor(e,i,r,s={}){this.doc=e,this.appId=i,this.nonce=r,this.platformId=s,this.styleRef=new Map,this.hostNodes=new Set,this.styleNodesInDOM=this.collectServerRenderedStyles(),this.platformIsServer=uz(s),this.resetHostNodes()}addStyles(e){for(const i of e)1===this.changeUsageCount(i,1)&&this.onStyleAdded(i)}removeStyles(e){for(const i of e)this.changeUsageCount(i,-1)<=0&&this.onStyleRemoved(i)}ngOnDestroy(){const e=this.styleNodesInDOM;e&&(e.forEach(i=>i.remove()),e.clear());for(const i of this.getAllStyles())this.onStyleRemoved(i);this.resetHostNodes()}addHost(e){this.hostNodes.add(e);for(const i of this.getAllStyles())this.addStyleToHost(e,i)}removeHost(e){this.hostNodes.delete(e)}getAllStyles(){return this.styleRef.keys()}onStyleAdded(e){for(const i of this.hostNodes)this.addStyleToHost(i,e)}onStyleRemoved(e){const i=this.styleRef;i.get(e)?.elements?.forEach(r=>r.remove()),i.delete(e)}collectServerRenderedStyles(){const e=this.doc.head?.querySelectorAll(`style[${oC}="${this.appId}"]`);if(e?.length){const i=new Map;return e.forEach(r=>{null!=r.textContent&&i.set(r.textContent,r)}),i}return null}changeUsageCount(e,i){const r=this.styleRef;if(r.has(e)){const s=r.get(e);return s.usage+=i,s.usage}return r.set(e,{usage:i,elements:[]}),i}getStyleElement(e,i){const r=this.styleNodesInDOM,s=r?.get(i);if(s?.parentNode===e)return r.delete(i),s.removeAttribute(oC),s;{const o=this.doc.createElement("style");return this.nonce&&o.setAttribute("nonce",this.nonce),o.textContent=i,this.platformIsServer&&o.setAttribute(oC,this.appId),e.appendChild(o),o}}addStyleToHost(e,i){const r=this.getStyleElement(e,i),s=this.styleRef,o=s.get(i)?.elements;o?o.push(r):s.set(i,{elements:[r],usage:1})}resetHostNodes(){const e=this.hostNodes;e.clear(),e.add(this.doc.head)}static{this.\u0275fac=function(i){return new(i||n)(Fi(sd),Fi(x1),Fi(sL,8),Fi(yu))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();const aC={svg:"http://www.w3.org/2000/svg",xhtml:"http://www.w3.org/1999/xhtml",xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/",math:"http://www.w3.org/1998/MathML/"},lC=/%COMP%/g,Fq=new Ht("",{providedIn:"root",factory:()=>!0});function Iz(n,t){return t.map(e=>e.replace(lC,n))}let bz=(()=>{class n{constructor(e,i,r,s,o,a,l,h=null){this.eventManager=e,this.sharedStylesHost=i,this.appId=r,this.removeStylesOnCompDestroy=s,this.doc=o,this.platformId=a,this.ngZone=l,this.nonce=h,this.rendererByCompId=new Map,this.platformIsServer=uz(a),this.defaultRenderer=new hC(e,o,l,this.platformIsServer)}createRenderer(e,i){if(!e||!i)return this.defaultRenderer;this.platformIsServer&&i.encapsulation===Ia.ShadowDom&&(i={...i,encapsulation:Ia.Emulated});const r=this.getOrCreateRenderer(e,i);return r instanceof wz?r.applyToHost(e):r instanceof cC&&r.applyStyles(),r}getOrCreateRenderer(e,i){const r=this.rendererByCompId;let s=r.get(i.id);if(!s){const o=this.doc,a=this.ngZone,l=this.eventManager,h=this.sharedStylesHost,c=this.removeStylesOnCompDestroy,d=this.platformIsServer;switch(i.encapsulation){case Ia.Emulated:s=new wz(l,h,i,this.appId,c,o,a,d);break;case Ia.ShadowDom:return new Vq(l,h,e,i,o,a,this.nonce,d);default:s=new cC(l,h,i,c,o,a,d)}r.set(i.id,s)}return s}ngOnDestroy(){this.rendererByCompId.clear()}static{this.\u0275fac=function(i){return new(i||n)(Fi(vz),Fi(yz),Fi(x1),Fi(Fq),Fi(sd),Fi(yu),Fi(zr),Fi(sL))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();class hC{constructor(t,e,i,r){this.eventManager=t,this.doc=e,this.ngZone=i,this.platformIsServer=r,this.data=Object.create(null),this.throwOnSyntheticProps=!0,this.destroyNode=null}destroy(){}createElement(t,e){return e?this.doc.createElementNS(aC[e]||e,t):this.doc.createElement(t)}createComment(t){return this.doc.createComment(t)}createText(t){return this.doc.createTextNode(t)}appendChild(t,e){(Mz(t)?t.content:t).appendChild(e)}insertBefore(t,e,i){t&&(Mz(t)?t.content:t).insertBefore(e,i)}removeChild(t,e){t&&t.removeChild(e)}selectRootElement(t,e){let i="string"==typeof t?this.doc.querySelector(t):t;if(!i)throw new F(-5104,!1);return e||(i.textContent=""),i}parentNode(t){return t.parentNode}nextSibling(t){return t.nextSibling}setAttribute(t,e,i,r){if(r){e=r+":"+e;const s=aC[r];s?t.setAttributeNS(s,e,i):t.setAttribute(e,i)}else t.setAttribute(e,i)}removeAttribute(t,e,i){if(i){const r=aC[i];r?t.removeAttributeNS(r,e):t.removeAttribute(`${i}:${e}`)}else t.removeAttribute(e)}addClass(t,e){t.classList.add(e)}removeClass(t,e){t.classList.remove(e)}setStyle(t,e,i,r){r&(Kh.DashCase|Kh.Important)?t.style.setProperty(e,i,r&Kh.Important?"important":""):t.style[e]=i}removeStyle(t,e,i){i&Kh.DashCase?t.style.removeProperty(e):t.style[e]=""}setProperty(t,e,i){null!=t&&(t[e]=i)}setValue(t,e){t.nodeValue=e}listen(t,e,i){if("string"==typeof t&&!(t=Uw().getGlobalEventTarget(this.doc,t)))throw new Error(`Unsupported event target ${t} for event ${e}`);return this.eventManager.addEventListener(t,e,this.decoratePreventDefault(i))}decoratePreventDefault(t){return e=>{if("__ngUnwrap__"===e)return t;!1===(this.platformIsServer?this.ngZone.runGuarded(()=>t(e)):t(e))&&e.preventDefault()}}}function Mz(n){return"TEMPLATE"===n.tagName&&void 0!==n.content}class Vq extends hC{constructor(t,e,i,r,s,o,a,l){super(t,s,o,l),this.sharedStylesHost=e,this.hostEl=i,this.shadowRoot=i.attachShadow({mode:"open"}),this.sharedStylesHost.addHost(this.shadowRoot);const h=Iz(r.id,r.styles);for(const c of h){const d=document.createElement("style");a&&d.setAttribute("nonce",a),d.textContent=c,this.shadowRoot.appendChild(d)}}nodeOrShadowRoot(t){return t===this.hostEl?this.shadowRoot:t}appendChild(t,e){return super.appendChild(this.nodeOrShadowRoot(t),e)}insertBefore(t,e,i){return super.insertBefore(this.nodeOrShadowRoot(t),e,i)}removeChild(t,e){return super.removeChild(this.nodeOrShadowRoot(t),e)}parentNode(t){return this.nodeOrShadowRoot(super.parentNode(this.nodeOrShadowRoot(t)))}destroy(){this.sharedStylesHost.removeHost(this.shadowRoot)}}class cC extends hC{constructor(t,e,i,r,s,o,a,l){super(t,s,o,a),this.sharedStylesHost=e,this.removeStylesOnCompDestroy=r,this.styles=l?Iz(l,i.styles):i.styles}applyStyles(){this.sharedStylesHost.addStyles(this.styles)}destroy(){this.removeStylesOnCompDestroy&&this.sharedStylesHost.removeStyles(this.styles)}}class wz extends cC{constructor(t,e,i,r,s,o,a,l){const h=r+"-"+i.id;super(t,e,i,s,o,a,l,h),this.contentAttr=function _q(n){return"_ngcontent-%COMP%".replace(lC,n)}(h),this.hostAttr=function Uq(n){return"_nghost-%COMP%".replace(lC,n)}(h)}applyToHost(t){this.applyStyles(),this.setAttribute(t,this.hostAttr,"")}createElement(t,e){const i=super.createElement(t,e);return super.setAttribute(i,this.contentAttr,""),i}}let Wq=(()=>{class n extends mz{constructor(e){super(e)}supports(e){return!0}addEventListener(e,i,r){return e.addEventListener(i,r,!1),()=>this.removeEventListener(e,i,r)}removeEventListener(e,i,r){return e.removeEventListener(i,r)}static{this.\u0275fac=function(i){return new(i||n)(Fi(sd))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();const Cz=["alt","control","meta","shift"],Yq={"\b":"Backspace","\t":"Tab","\x7f":"Delete","\x1b":"Escape",Del:"Delete",Esc:"Escape",Left:"ArrowLeft",Right:"ArrowRight",Up:"ArrowUp",Down:"ArrowDown",Menu:"ContextMenu",Scroll:"ScrollLock",Win:"OS"},Qq={alt:n=>n.altKey,control:n=>n.ctrlKey,meta:n=>n.metaKey,shift:n=>n.shiftKey};let Gq=(()=>{class n extends mz{constructor(e){super(e)}supports(e){return null!=n.parseEventName(e)}addEventListener(e,i,r){const s=n.parseEventName(i),o=n.eventCallback(s.fullKey,r,this.manager.getZone());return this.manager.getZone().runOutsideAngular(()=>Uw().onAndCancel(e,s.domEventName,o))}static parseEventName(e){const i=e.toLowerCase().split("."),r=i.shift();if(0===i.length||"keydown"!==r&&"keyup"!==r)return null;const s=n._normalizeKey(i.pop());let o="",a=i.indexOf("code");if(a>-1&&(i.splice(a,1),o="code."),Cz.forEach(h=>{const c=i.indexOf(h);c>-1&&(i.splice(c,1),o+=h+".")}),o+=s,0!=i.length||0===s.length)return null;const l={};return l.domEventName=r,l.fullKey=o,l}static matchEventFullKeyCode(e,i){let r=Yq[e.key]||e.key,s="";return i.indexOf("code.")>-1&&(r=e.code,s="code."),!(null==r||!r)&&(r=r.toLowerCase()," "===r?r="space":"."===r&&(r="dot"),Cz.forEach(o=>{o!==r&&(0,Qq[o])(e)&&(s+=o+".")}),s+=r,s===i)}static eventCallback(e,i,r){return s=>{n.matchEventFullKeyCode(s,e)&&r.runGuarded(()=>i(s))}}static _normalizeKey(e){return"esc"===e?"escape":e}static{this.\u0275fac=function(i){return new(i||n)(Fi(sd))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();function Ez(n){return{appProviders:[...e$,...n?.providers??[]],platformProviders:Jq}}const Jq=[{provide:yu,useValue:"browser"},{provide:nL,useValue:function qq(){nC.makeCurrent()},multi:!0},{provide:sd,useFactory:function Zq(){return function xj(n){D1=n}(document),document},deps:[]}],e$=[{provide:I1,useValue:"root"},{provide:eh,useFactory:function $q(){return new eh},deps:[]},{provide:sC,useClass:Wq,multi:!0,deps:[sd,zr,yu]},{provide:sC,useClass:Gq,multi:!0,deps:[sd]},bz,yz,vz,{provide:nN,useExisting:bz},{provide:class lq{},useClass:zq,deps:[]},[]];var n$=0,dC=!1;function S0(n,t){var e=t;return e.unshift(void 0),new(Function.prototype.bind.apply(n,e))}function Y(n,t){for(var e=t,i=n.replace(/\[/g,".").replace(/\]/g,"").split("."),r=0;r"u"}function wi(n){return n+"_"+n$++}function b0(n,t){return n===t||!(n===document||!n)&&b0(n.parentNode,t)}function Dg(n){try{throw new Error(n)}catch(t){throw new Error(t.message+"\n"+t.stack)}}function Re(n){var t=n+"";return t.match(/auto|cm|mm|in|px|pt|pc|%|em|ex|ch|rem|vw|vh|vmin|vmax/)?t:t+"px"}function ce(){return dC}var xg,n,t,h$={latn:{_digits:"0123456789",_type:"numeric"}},Lz={decimal:".",group:",",percentSign:"%",plusSign:"+",minusSign:"-",infinity:"\u221e",nan:"NaN",exponential:"E"},Nz=[0,1,2,3,4,5,6,7,8,9],Rr=function(){function n(){}return n.getMainObject=function(t,e){return Y(ce()?e:"main."+e,t)},n.getNumberingSystem=function(t){return Y("supplemental.numberingSystems",t)||this.numberingSystems},n.reverseObject=function(t,e){for(var r={},s=0,o=e||Object.keys(t);s13&&(f+=1,o-=12),o-=1,a=f-4716;var y=u-24e5,S=10631/30,b=u-1948084,M=Math.floor(b/10631);b-=10631*M;var w=Math.floor((b-.1335)/S),C=30*M+w;b-=Math.floor(w*S+.1335);var D=Math.floor((b+28.5001)/29.5);13===D&&(D=12);for(var A=b-Math.floor(29.5001*D-29),x=0;xy);x++);var R=x+16260,L=Math.floor((R-1)/12),O=L+1,N=R-12*L,T=y-t[x-1]+1;return(T+"").length>2&&(T=A,N=D,O=C),{year:O,month:N,date:T}},n.toGregorian=function i(r,s,o){var g=Math.floor(o+t[12*(r-1)+1+(s-1)-16260-1]-1+24e5+.5),v=Math.floor((g-1867216.25)/36524.25),y=1524+(v=g+1+v-Math.floor(v/4)),S=Math.floor((y-122.1)/365.25),b=Math.floor(365.25*S),M=Math.floor((y-b)/30.6001),w=y-b-Math.floor(30.6001*M),C=M-(M>13.5?13:1),D=S-(C>2.5?4716:4715);return D<=0&&C--,new Date(D+"/"+C+"/"+w)};var ut,u$=/\/MMMMM|MMMM|MMM|a|LLLL|LLL|EEEEE|EEEE|E|K|cccc|ccc|WW|W|G+|z+/gi,Oz="stand-alone",p$=["sun","mon","tue","wed","thu","fri","sat"],kz={m:"getMinutes",h:"getHours",H:"getHours",s:"getSeconds",d:"getDate",f:"getMilliseconds"},Pz=function(){function n(){}return n.dateFormat=function(t,e,i){var r=this,s=ut.getDependables(i,t,e.calendar),o=Y("parserObject.numbers",s),a=s.dateObject,l={isIslamic:ut.islamicRegex.test(e.calendar)};ce()&&e.isServerRendered&&(e=ut.compareBlazorDateFormats(e,t));var h=e.format||ut.getResultantPattern(e.skeleton,s.dateObject,e.type,!1,ce()?t:"");if(l.dateSeperator=ce()?Y("dateSeperator",a):ut.getDateSeparator(s.dateObject),st(h))Dg("Format options or type given must be invalid");else{h=ut.ConvertDateToWeekFormat(h),ce()&&(h=h.replace(/tt/,"a")),l.pattern=h,l.numMapper=ce()?ze({},o):Rr.getNumberMapper(s.parserObject,Rr.getNumberingSystem(i));for(var d=0,u=h.match(u$)||[];d2?r+=e.month[""+u]:f=!0;break;case"E":case"c":r+=e.weekday[""+p$[t.getDay()]];break;case"H":case"h":case"m":case"s":case"d":case"f":if(f=!0,"d"===d)u=o.date;else if("f"===d){f=!1,g=!0;var y=(p=(p=t[""+kz[""+d]]().toString()).substring(0,c)).length;if(c!==y){if(c>3)continue;for(var S=0;S0?1:0],o=Math.abs(t);return s.replace(/HH?|mm/g,function(a){var l=a.length,h=-1!==a.indexOf("H");return i.checkTwodigitNumber(Math.floor(h?o/60:o%60),l)})},n}(),zz={ms:"minimumSignificantDigits",ls:"maximumSignificantDigits",mf:"minimumFractionDigits",lf:"maximumFractionDigits"},ep=["infinity","nan","group","decimal","exponential"],Rz=function(){function n(){}return n.numberFormatter=function(t,e,i){var l,r=this,s=ze({},e),o={},a={},h=ut.getDependables(i,t,"",!0),c=h.numericObject;a.numberMapper=ce()?ze({},c):Rr.getNumberMapper(h.parserObject,Rr.getNumberingSystem(i),!0),a.currencySymbol=ce()?Y("currencySymbol",c):ut.getCurrencySymbol(h.numericObject,s.currency||Lg,e.altSymbol,e.ignoreCurrency),a.percentSymbol=ce()?Y("numberSymbols.percentSign",c):a.numberMapper.numberSymbols.percentSign,a.minusSymbol=ce()?Y("numberSymbols.minusSign",c):a.numberMapper.numberSymbols.minusSign;var d=a.numberMapper.numberSymbols;if(e.format&&!ut.formatRegex.test(e.format))o=ut.customFormat(e.format,a,h.numericObject),!st(s.useGrouping)&&s.useGrouping&&(s.useGrouping=o.pData.useGrouping);else{if(ze(s,ut.getProperNumericSkeleton(e.format||"N")),s.isCurrency="currency"===s.type,s.isPercent="percent"===s.type,ce()||(l=ut.getSymbolPattern(s.type,a.numberMapper.numberSystem,h.numericObject,s.isAccount)),s.groupOne=this.checkValueRange(s.maximumSignificantDigits,s.minimumSignificantDigits,!0),this.checkValueRange(s.maximumFractionDigits,s.minimumFractionDigits,!1,!0),st(s.fractionDigits)||(s.minimumFractionDigits=s.maximumFractionDigits=s.fractionDigits),st(s.useGrouping)&&(s.useGrouping=!0),s.isCurrency&&!ce()&&(l=l.replace(/\u00A4/g,ut.defaultCurrency)),ce())o.nData=ze({},{},Y(s.type+"nData",c)),o.pData=ze({},{},Y(s.type+"pData",c)),"currency"===s.type&&e.currency&&ut.replaceBlazorCurrency([o.pData,o.nData],a.currencySymbol,e.currency);else{var u=l.split(";");o.nData=ut.getFormatData(u[1]||"-"+u[0],!0,a.currencySymbol),o.pData=ut.getFormatData(u[0],!1,a.currencySymbol),s.useGrouping&&(s.groupSeparator=d[ep[2]],s.groupData=this.getGroupingDetails(u[0]))}if(st(s.minimumFractionDigits)&&(s.minimumFractionDigits=o.nData.minimumFraction),st(s.maximumFractionDigits)){var f=o.nData.maximumFraction;s.maximumFractionDigits=st(f)&&s.isPercent?0:f}var g=s.minimumFractionDigits,v=s.maximumFractionDigits;!st(g)&&!st(v)&&g>v&&(s.maximumFractionDigits=g)}return ze(o.nData,s),ze(o.pData,s),function(y){return isNaN(y)?d[ep[1]]:isFinite(y)?r.intNumberFormatter(y,o,a,e):d[ep[0]]}},n.getGroupingDetails=function(t){var e={},i=t.match(ut.negativeDataRegex);if(i&&i[4]){var r=i[4],s=r.lastIndexOf(",");if(-1!==s){var o=r.split(".")[0];e.primary=o.length-s-1;var a=r.lastIndexOf(",",s-1);-1!==a&&(e.secondary=s-1-a)}}return e},n.checkValueRange=function(t,e,i,r){var s=r?"f":"s",o=0,a=zz["l"+s],l=zz["m"+s];if(st(t)||(this.checkRange(t,a,r),o++),st(e)||(this.checkRange(e,l,r),o++),2===o){if(!(tr[1])&&Dg(e+"value must be within the range"+r[0]+"to"+r[1])},n.intNumberFormatter=function(t,e,i,r){var s;if(!st(e.nData.type)){t<0?(t*=-1,s=e.nData):s=0===t&&e.zeroData||e.pData;var o="";if(s.isPercent&&(t*=100),s.groupOne)o=this.processSignificantDigits(t,s.minimumSignificantDigits,s.maximumSignificantDigits);else if(o=this.processFraction(t,s.minimumFractionDigits,s.maximumFractionDigits,r),s.minimumIntegerDigits&&(o=this.processMinimumIntegers(o,s.minimumIntegerDigits)),i.isCustomFormat&&s.minimumFractionDigits=0&&"0"===l[parseInt(c.toString(),10)]&&c>=s.minimumFractionDigits;c--)l=l.slice(0,c);o=a[0]+"."+l}return"scientific"===s.type&&(o=(o=t.toExponential(s.maximumFractionDigits)).replace("e",i.numberMapper.numberSymbols[ep[4]])),o=o.replace(".",i.numberMapper.numberSymbols[ep[3]]),o="#,###,,;(#,###,,)"===s.format?this.customPivotFormat(parseInt(o,10)):o,s.useGrouping&&(o=this.groupNumbers(o,s.groupData.primary,s.groupSeparator||",",i.numberMapper.numberSymbols[ep[3]]||".",s.groupData.secondary)),o=Rr.convertValueParts(o,ut.latnParseRegex,i.numberMapper.mapper),"N/A"===s.nlead?s.nlead:"0"===o&&r&&"0"===r.format?o+s.nend:s.nlead+o+s.nend}},n.processSignificantDigits=function(t,e,i){var r=t+"";return r.lengthe;)c=l.slice(h-e,h)+(c.length?i+c:""),h-=e,o&&(e=s,o=!1);return a[0]=l.slice(0,h)+(c.length?i:"")+c,a.join(r)},n.processFraction=function(t,e,i,r){var s=(t+"").split(".")[1],o=s?s.length:0;if(e&&oi||0===i))return t.toFixed(i);var h=t+"";return"0"===h[0]&&r&&"###.00"===r.format&&(h=h.slice(1)),h},n.processMinimumIntegers=function(t,e){var i=t.split("."),r=i[0],s=r.length;if(s=5e5){var r=(t/=1e6).toString().split(".")[1];return r&&+r.substring(0,1)>=5?Math.ceil(t).toString():Math.floor(t).toString()}return""},n}(),Tg=(new RegExp("^([^0-9]*)(([0-9,]*[0-9]+)(.[0-9]+)?)([Ee][+-]?[0-9]+)?([^0-9]*)$"),function(){function n(t){this.ranArray=[],this.boundedEvents={},!m(t)&&(this.context=t)}return n.prototype.on=function(t,e,i,r){if(!m(e)){var s=i||this.context;if(this.notExist(t))return void(this.boundedEvents[""+t]=[{handler:e,context:s,id:r}]);m(r)?this.isHandlerPresent(this.boundedEvents[""+t],e)||this.boundedEvents[""+t].push({handler:e,context:s}):-1===this.ranArray.indexOf(r)&&(this.ranArray.push(r),this.boundedEvents[""+t].push({handler:e,context:s,id:r}))}},n.prototype.off=function(t,e,i){if(!this.notExist(t)){var r=Y(t,this.boundedEvents);if(e){for(var s=0;s1&&(_.fractionDigits=parseInt(P[2],10)),_}function f(T,P,_,B){var j=B?{}:{nlead:"",nend:""},Q=T.match(n.customRegex);if(Q){B||(j.nlead=g(Q[1],_),j.nend=g(Q[10],_),j.groupPattern=Q[4]);var oe=Q[7];if(oe&&P){var ue=oe.match(t);j.minimumFraction=m(ue)?0:ue.length,j.maximumFraction=oe.length-1}}return j}function g(T,P){return T?(T=T.replace(n.defaultCurrency,P),""===P?T.trim():T):""}function v(T,P,_,B){return B?"$":Y("currencies."+P+(_?"."+_:".symbol"),T)||Y("currencies."+P+".symbol-alt-narrow",T)||"$"}function S(T,P,_){var B={type:"decimal",minimumFractionDigits:0,maximumFractionDigits:0},j=T.match(n.customRegex);if(m(j)||""===j[5]&&"N/A"!==T)return B.type=void 0,B;B.nlead=j[1],B.nend=j[10];var Q=j[6],oe=!!Q.match(/ $/g),ue=-1!==Q.replace(/ $/g,"").indexOf(" ");B.useGrouping=-1!==Q.indexOf(",")||ue,Q=Q.replace(/,/g,"");var pe=j[7];if(-1!==Q.indexOf("0")&&(B.minimumIntegerDigits=Q.length-Q.indexOf("0")),m(pe)||(B.minimumFractionDigits=pe.lastIndexOf("0"),B.maximumFractionDigits=pe.lastIndexOf("#"),-1===B.minimumFractionDigits&&(B.minimumFractionDigits=0),(-1===B.maximumFractionDigits||B.maximumFractionDigitsQ.lastIndexOf("'"))){B[""+a[parseInt(j.toString(),10)]]=Q.substr(0,oe)+_+Q.substr(oe+1),B[""+a[""+P]]=!0,B.type=B.isCurrency?"currency":"percent";break}}return B}function C(T,P){if(-1!==T.indexOf(",")){var _=T.split(",");T=_[0]+Y("numberMapper.numberSymbols.group",P)+_[1].replace(".",Y("numberMapper.numberSymbols.decimal",P))}else T=T.replace(".",Y("numberMapper.numberSymbols.decimal",P));return T}function A(T,P,_){T+=".";for(var B=0;B0;Q-=3)T=","+_[Q-2]+_[Q-1]+_[parseInt(Q.toString(),10)]+T;return T=T.slice(1),P[1]?T+"."+P[1]:T}n.dateParseRegex=/([a-z])\1*|'([^']|'')+'|''|./gi,n.basicPatterns=["short","medium","long","full"],n.defaultObject={dates:{calendars:{gregorian:{months:{"stand-alone":{abbreviated:{1:"Jan",2:"Feb",3:"Mar",4:"Apr",5:"May",6:"Jun",7:"Jul",8:"Aug",9:"Sep",10:"Oct",11:"Nov",12:"Dec"},narrow:{1:"J",2:"F",3:"M",4:"A",5:"M",6:"J",7:"J",8:"A",9:"S",10:"O",11:"N",12:"D"},wide:{1:"January",2:"February",3:"March",4:"April",5:"May",6:"June",7:"July",8:"August",9:"September",10:"October",11:"November",12:"December"}}},days:{"stand-alone":{abbreviated:{sun:"Sun",mon:"Mon",tue:"Tue",wed:"Wed",thu:"Thu",fri:"Fri",sat:"Sat"},narrow:{sun:"S",mon:"M",tue:"T",wed:"W",thu:"T",fri:"F",sat:"S"},short:{sun:"Su",mon:"Mo",tue:"Tu",wed:"We",thu:"Th",fri:"Fr",sat:"Sa"},wide:{sun:"Sunday",mon:"Monday",tue:"Tuesday",wed:"Wednesday",thu:"Thursday",fri:"Friday",sat:"Saturday"}}},dayPeriods:{format:{wide:{am:"AM",pm:"PM"}}},eras:{eraNames:{0:"Before Christ","0-alt-variant":"Before Common Era",1:"Anno Domini","1-alt-variant":"Common Era"},eraAbbr:{0:"BC","0-alt-variant":"BCE",1:"AD","1-alt-variant":"CE"},eraNarrow:{0:"B","0-alt-variant":"BCE",1:"A","1-alt-variant":"CE"}},dateFormats:{full:"EEEE, MMMM d, y",long:"MMMM d, y",medium:"MMM d, y",short:"M/d/yy"},timeFormats:{full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},dateTimeFormats:{full:"{1} 'at' {0}",long:"{1} 'at' {0}",medium:"{1}, {0}",short:"{1}, {0}",availableFormats:{d:"d",E:"ccc",Ed:"d E",Ehm:"E h:mm a",EHm:"E HH:mm",Ehms:"E h:mm:ss a",EHms:"E HH:mm:ss",Gy:"y G",GyMMM:"MMM y G",GyMMMd:"MMM d, y G",GyMMMEd:"E, MMM d, y G",h:"h a",H:"HH",hm:"h:mm a",Hm:"HH:mm",hms:"h:mm:ss a",Hms:"HH:mm:ss",hmsv:"h:mm:ss a v",Hmsv:"HH:mm:ss v",hmv:"h:mm a v",Hmv:"HH:mm v",M:"L",Md:"M/d",MEd:"E, M/d",MMM:"LLL",MMMd:"MMM d",MMMEd:"E, MMM d",MMMMd:"MMMM d",ms:"mm:ss",y:"y",yM:"M/y",yMd:"M/d/y",yMEd:"E, M/d/y",yMMM:"MMM y",yMMMd:"MMM d, y",yMMMEd:"E, MMM d, y",yMMMM:"MMMM y"}}},islamic:{months:{"stand-alone":{abbreviated:{1:"Muh.",2:"Saf.",3:"Rab. I",4:"Rab. II",5:"Jum. I",6:"Jum. II",7:"Raj.",8:"Sha.",9:"Ram.",10:"Shaw.",11:"Dhu\u02bbl-Q.",12:"Dhu\u02bbl-H."},narrow:{1:"1",2:"2",3:"3",4:"4",5:"5",6:"6",7:"7",8:"8",9:"9",10:"10",11:"11",12:"12"},wide:{1:"Muharram",2:"Safar",3:"Rabi\u02bb I",4:"Rabi\u02bb II",5:"Jumada I",6:"Jumada II",7:"Rajab",8:"Sha\u02bbban",9:"Ramadan",10:"Shawwal",11:"Dhu\u02bbl-Qi\u02bbdah",12:"Dhu\u02bbl-Hijjah"}}},days:{"stand-alone":{abbreviated:{sun:"Sun",mon:"Mon",tue:"Tue",wed:"Wed",thu:"Thu",fri:"Fri",sat:"Sat"},narrow:{sun:"S",mon:"M",tue:"T",wed:"W",thu:"T",fri:"F",sat:"S"},short:{sun:"Su",mon:"Mo",tue:"Tu",wed:"We",thu:"Th",fri:"Fr",sat:"Sa"},wide:{sun:"Sunday",mon:"Monday",tue:"Tuesday",wed:"Wednesday",thu:"Thursday",fri:"Friday",sat:"Saturday"}}},dayPeriods:{format:{wide:{am:"AM",pm:"PM"}}},eras:{eraNames:{0:"AH"},eraAbbr:{0:"AH"},eraNarrow:{0:"AH"}},dateFormats:{full:"EEEE, MMMM d, y G",long:"MMMM d, y G",medium:"MMM d, y G",short:"M/d/y GGGGG"},timeFormats:{full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},dateTimeFormats:{full:"{1} 'at' {0}",long:"{1} 'at' {0}",medium:"{1}, {0}",short:"{1}, {0}",availableFormats:{d:"d",E:"ccc",Ed:"d E",Ehm:"E h:mm a",EHm:"E HH:mm",Ehms:"E h:mm:ss a",EHms:"E HH:mm:ss",Gy:"y G",GyMMM:"MMM y G",GyMMMd:"MMM d, y G",GyMMMEd:"E, MMM d, y G",h:"h a",H:"HH",hm:"h:mm a",Hm:"HH:mm",hms:"h:mm:ss a",Hms:"HH:mm:ss",M:"L",Md:"M/d",MEd:"E, M/d",MMM:"LLL",MMMd:"MMM d",MMMEd:"E, MMM d",MMMMd:"MMMM d",ms:"mm:ss",y:"y G",yyyy:"y G",yyyyM:"M/y GGGGG",yyyyMd:"M/d/y GGGGG",yyyyMEd:"E, M/d/y GGGGG",yyyyMMM:"MMM y G",yyyyMMMd:"MMM d, y G",yyyyMMMEd:"E, MMM d, y G",yyyyMMMM:"MMMM y G",yyyyQQQ:"QQQ y G",yyyyQQQQ:"QQQQ y G"}}}},timeZoneNames:{hourFormat:"+HH:mm;-HH:mm",gmtFormat:"GMT{0}",gmtZeroFormat:"GMT"}},numbers:{currencies:{USD:{displayName:"US Dollar",symbol:"$","symbol-alt-narrow":"$"},EUR:{displayName:"Euro",symbol:"\u20ac","symbol-alt-narrow":"\u20ac"},GBP:{displayName:"British Pound","symbol-alt-narrow":"\xa3"}},defaultNumberingSystem:"latn",minimumGroupingDigits:"1","symbols-numberSystem-latn":{decimal:".",group:",",list:";",percentSign:"%",plusSign:"+",minusSign:"-",exponential:"E",superscriptingExponent:"\xd7",perMille:"\u2030",infinity:"\u221e",nan:"NaN",timeSeparator:":"},"decimalFormats-numberSystem-latn":{standard:"#,##0.###"},"percentFormats-numberSystem-latn":{standard:"#,##0%"},"currencyFormats-numberSystem-latn":{standard:"\xa4#,##0.00",accounting:"\xa4#,##0.00;(\xa4#,##0.00)"},"scientificFormats-numberSystem-latn":{standard:"#E0"}}},n.blazorDefaultObject={numbers:{mapper:{0:"0",1:"1",2:"2",3:"3",4:"4",5:"5",6:"6",7:"7",8:"8",9:"9"},mapperDigits:"0123456789",numberSymbols:{decimal:".",group:",",plusSign:"+",minusSign:"-",percentSign:"%",nan:"NaN",timeSeparator:":",infinity:"\u221e"},timeSeparator:":",currencySymbol:"$",currencypData:{nlead:"$",nend:"",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},percentpData:{nlead:"",nend:"%",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},percentnData:{nlead:"-",nend:"%",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},currencynData:{nlead:"($",nend:")",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},decimalnData:{nlead:"-",nend:"",groupData:{primary:3},maximumFraction:2,minimumFraction:2},decimalpData:{nlead:"",nend:"",groupData:{primary:3},maximumFraction:2,minimumFraction:2}},dates:{dayPeriods:{am:"AM",pm:"PM"},dateSeperator:"/",days:{abbreviated:{sun:"Sun",mon:"Mon",tue:"Tue",wed:"Wed",thu:"Thu",fri:"Fri",sat:"Sat"},short:{sun:"Su",mon:"Mo",tue:"Tu",wed:"We",thu:"Th",fri:"Fr",sat:"Sa"},wide:{sun:"Sunday",mon:"Monday",tue:"Tuesday",wed:"Wednesday",thu:"Thursday",fri:"Friday",sat:"Saturday"}},months:{abbreviated:{1:"Jan",2:"Feb",3:"Mar",4:"Apr",5:"May",6:"Jun",7:"Jul",8:"Aug",9:"Sep",10:"Oct",11:"Nov",12:"Dec"},wide:{1:"January",2:"February",3:"March",4:"April",5:"May",6:"June",7:"July",8:"August",9:"September",10:"October",11:"November",12:"December"}},eras:{1:"AD"}}},n.monthIndex={3:"abbreviated",4:"wide",5:"narrow",1:"abbreviated"},n.month="months",n.days="days",n.patternMatcher={C:"currency",P:"percent",N:"decimal",A:"currency",E:"scientific"},n.getResultantPattern=l,n.getDependables=h,n.getSymbolPattern=c,n.ConvertDateToWeekFormat=d,n.compareBlazorDateFormats=u,n.getProperNumericSkeleton=p,n.getFormatData=f,n.changeCurrencySymbol=g,n.getCurrencySymbol=v,n.customFormat=function y(T,P,_){for(var B={},j=T.split(";"),Q=["pData","nData","zeroData"],oe=0;oe1,pe.nData=ce()?Y(De.type+"nData",oe):f(ot[1]||"-"+ot[0],!0,Ie),pe.pData=ce()?Y(De.type+"pData",oe):f(ot[0],!1,Ie),!Me[2]&&!P.minimumFractionDigits&&!P.maximumFractionDigits&&(ue=f(Ve.split(";")[0],!0,"",!0).minimumFraction)}if(n.formatRegex.test(P.format)||!P.format){if(ze(Q,p(P.format||"N")),Q.custom=!1,$e="###0",(Q.fractionDigits||P.minimumFractionDigits||P.maximumFractionDigits||ue)&&(Q.fractionDigits&&(P.minimumFractionDigits=P.maximumFractionDigits=Q.fractionDigits),$e=A($e,ue||Q.fractionDigits||P.minimumFractionDigits||0,P.maximumFractionDigits||0)),P.minimumIntegerDigits&&($e=x($e,P.minimumIntegerDigits)),P.useGrouping&&($e=R($e)),"currency"===Q.type||Q.type&&ce()){ce()&&"currency"!==Q.type&&(pe.pData=Y(Q.type+"pData",oe),pe.nData=Y(Q.type+"nData",oe));var hr=$e;$e=pe.pData.nlead+hr+pe.pData.nend,(pe.hasNegativePattern||ce())&&($e+=";"+pe.nData.nlead+hr+pe.nData.nend)}"percent"===Q.type&&!ce()&&($e+=" %")}else $e=P.format.replace(/'/g,'"');return Object.keys(xe).length>0&&($e=B?$e:C($e,xe)),$e},n.fractionDigitsPattern=A,n.minimumIntegerPattern=x,n.groupingPattern=R,n.getWeekData=function L(T,P){var _="sun",B=Y("supplemental.weekData.firstDay",P),j=T;return/en-/.test(j)&&(j=j.slice(3)),j=j.slice(0,2).toUpperCase()+j.substr(2),B&&(_=B[""+j]||B[j.slice(0,2)]||"sun"),o[""+_]},n.replaceBlazorCurrency=function O(T,P,_){var B=function d$(n){return Y(n||"",c$)}(_);if(P!==B)for(var j=0,Q=T;j=0?_:_+7;var j=Math.floor((T.getTime()-P.getTime()-6e4*(T.getTimezoneOffset()-P.getTimezoneOffset()))/864e5)+1;if(_<4){if((B=Math.floor((j+_-1)/7)+1)>52){var oe=new Date(T.getFullYear()+1,0,1).getDay();B=(oe=oe>=0?oe:oe+7)<4?1:53}}else B=Math.floor((j+_-1)/7);return B}}(ut||(ut={}));var tp=function(){function n(t,e,i){this.type="GET",this.emitError=!0,"string"==typeof t?(this.url=t,this.type=m(e)?this.type:e.toUpperCase(),this.contentType=i):Aa(t)&&Object.keys(t).length>0&&Nn(this,t),this.contentType=m(this.contentType)?"application/json; charset=utf-8":this.contentType}return n.prototype.send=function(t){var e=this,i={"application/json":"json","multipart/form-data":"formData","application/octet-stream":"blob","application/x-www-form-urlencoded":"formData"};try{m(this.fetchRequest)&&"GET"===this.type?this.fetchRequest=new Request(this.url,{method:this.type}):m(this.fetchRequest)&&(this.data=m(t)?this.data:t,this.fetchRequest=new Request(this.url,{method:this.type,headers:{"Content-Type":this.contentType},body:this.data}));var r={cancel:!1,fetchRequest:this.fetchRequest};return this.triggerEvent(this.beforeSend,r),r.cancel?null:(this.fetchResponse=fetch(this.fetchRequest),this.fetchResponse.then(function(s){if(e.triggerEvent(e.onLoad,s),!s.ok)throw s;for(var o="text",a=0,l=Object.keys(i);a-1},n.getValue=function(t,e){var i=typeof window<"u"?window.browserDetails:{};return typeof navigator<"u"&&"MacIntel"===navigator.platform&&navigator.maxTouchPoints>1&&!0===n.isTouch&&!fC.CHROME.test(navigator.userAgent)&&(i.isIos=!0,i.isDevice=!0,i.isTouch=!0,i.isPointer=!0),typeof window<"u"&&window.Capacitor&&"ios"===window.Capacitor.getPlatform()&&(i.isPointer=!1),typeof i[""+t]>"u"?i[""+t]=e.test(n.userAgent):i[""+t]},Object.defineProperty(n,"userAgent",{get:function(){return n.uA},set:function(t){n.uA=t,window.browserDetails={}},enumerable:!0,configurable:!0}),Object.defineProperty(n,"info",{get:function(){return st(window.browserDetails.info)?window.browserDetails.info=n.extractBrowserDetail():window.browserDetails.info},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isIE",{get:function(){return n.getValue("isIE",x$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isTouch",{get:function(){return st(window.browserDetails.isTouch)?window.browserDetails.isTouch="ontouchstart"in window.navigator||window&&window.navigator&&window.navigator.maxTouchPoints>0||"ontouchstart"in window:window.browserDetails.isTouch},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isPointer",{get:function(){return st(window.browserDetails.isPointer)?window.browserDetails.isPointer="pointerEnabled"in window.navigator:window.browserDetails.isPointer},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isMSPointer",{get:function(){return st(window.browserDetails.isMSPointer)?window.browserDetails.isMSPointer="msPointerEnabled"in window.navigator:window.browserDetails.isMSPointer},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isDevice",{get:function(){return n.getValue("isDevice",D$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isIos",{get:function(){return n.getValue("isIos",A$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isIos7",{get:function(){return n.getValue("isIos7",L$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isAndroid",{get:function(){return n.getValue("isAndroid",N$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isWebView",{get:function(){return st(window.browserDetails.isWebView)&&(window.browserDetails.isWebView=!(st(window.cordova)&&st(window.PhoneGap)&&st(window.phonegap)&&"object"!==window.forge)),window.browserDetails.isWebView},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isWindows",{get:function(){return n.getValue("isWindows",O$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"touchStartEvent",{get:function(){return st(window.browserDetails.touchStartEvent)?window.browserDetails.touchStartEvent=n.getTouchStartEvent():window.browserDetails.touchStartEvent},enumerable:!0,configurable:!0}),Object.defineProperty(n,"touchMoveEvent",{get:function(){return st(window.browserDetails.touchMoveEvent)?window.browserDetails.touchMoveEvent=n.getTouchMoveEvent():window.browserDetails.touchMoveEvent},enumerable:!0,configurable:!0}),Object.defineProperty(n,"touchEndEvent",{get:function(){return st(window.browserDetails.touchEndEvent)?window.browserDetails.touchEndEvent=n.getTouchEndEvent():window.browserDetails.touchEndEvent},enumerable:!0,configurable:!0}),Object.defineProperty(n,"touchCancelEvent",{get:function(){return st(window.browserDetails.touchCancelEvent)?window.browserDetails.touchCancelEvent=n.getTouchCancelEvent():window.browserDetails.touchCancelEvent},enumerable:!0,configurable:!0}),n.uA=typeof navigator<"u"?navigator.userAgent:"",n}(),E=function(){function n(){}return n.addOrGetEventData=function(t){return"__eventList"in t?t.__eventList.events:(t.__eventList={},t.__eventList.events=[])},n.add=function(t,e,i,r,s){var a,o=n.addOrGetEventData(t);a=s?function o$(n,t){var e;return function(){for(var i=this,r=[],s=0;s"u"||(e.innerHTML=t.innerHTML?t.innerHTML:"",void 0!==t.className&&(e.className=t.className),void 0!==t.id&&(e.id=t.id),void 0!==t.styles&&e.setAttribute("style",t.styles),void 0!==t.attrs&&Fe(e,t.attrs)),e}function V(n,t){for(var e=Vz(t),i=RegExp,r=0,s=n;r0}function pl(n,t,e){for(var i=document.createDocumentFragment(),r=0,s=n;r0;)i.appendChild(n[0]);else for(var r=0,s=n;r-1&&!r[parseInt(s.toString(),10)].match(/\[.*\]/)){var o=r[parseInt(s.toString(),10)].split("#");if(o[1].match(/^\d/)||o[1].match(t)){var a=r[parseInt(s.toString(),10)].split(".");a[0]=a[0].replace(/#/,"[id='")+"']",r[parseInt(s.toString(),10)]=a.join(".")}}e[parseInt(i.toString(),10)]=r.join(" ")}return e.join(",")}return n}function J(n,t){var e=n;if("function"==typeof e.closest)return e.closest(t);for(;e&&1===e.nodeType;){if(gC(e,t))return e;e=e.parentNode}return null}function je(n,t){void 0!==t&&Object.keys(t).forEach(function(e){n.style[""+e]=t[""+e]})}function gC(n,t){var e=n.matches||n.msMatchesSelector||n.webkitMatchesSelector;return e?e.call(n,t):-1!==[].indexOf.call(document.querySelectorAll(t),n)}var z$=new RegExp("]"),ah=function(){function n(t,e){this.isRendered=!1,this.isComplexArraySetter=!1,this.isServerRendered=!1,this.allowServerDataBinding=!0,this.isProtectedOnChange=!0,this.properties={},this.changedProperties={},this.oldProperties={},this.bulkChanges={},this.refreshing=!1,this.ignoreCollectionWatch=!1,this.finalUpdate=function(){},this.childChangedProperties={},this.modelObserver=new Tg(this),st(e)||(this.element="string"==typeof e?document.querySelector(e):e,m(this.element)||(this.isProtectedOnChange=!1,this.addInstance())),st(t)||this.setProperties(t,!0),this.isDestroyed=!1}return n.prototype.setProperties=function(t,e){var i=this.isProtectedOnChange;this.isProtectedOnChange=!!e,Nn(this,t),!0!==e?(Nn(this.changedProperties,t),this.dataBind()):ce()&&this.isRendered&&this.serverDataBind(t),this.finalUpdate(),this.changedProperties={},this.oldProperties={},this.isProtectedOnChange=i},n.callChildDataBind=function(t,e){for(var r=0,s=Object.keys(t);r=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Hs=function(n){function t(i){var r=n.call(this,i,void 0)||this;return r.easing={ease:"cubic-bezier(0.250, 0.100, 0.250, 1.000)",linear:"cubic-bezier(0.250, 0.250, 0.750, 0.750)",easeIn:"cubic-bezier(0.420, 0.000, 1.000, 1.000)",easeOut:"cubic-bezier(0.000, 0.000, 0.580, 1.000)",easeInOut:"cubic-bezier(0.420, 0.000, 0.580, 1.000)",elasticInOut:"cubic-bezier(0.5,-0.58,0.38,1.81)",elasticIn:"cubic-bezier(0.17,0.67,0.59,1.81)",elasticOut:"cubic-bezier(0.7,-0.75,0.99,1.01)"},r}var e;return Q$(t,n),e=t,t.prototype.animate=function(i,r){var s=this.getModel(r=r||{});if("string"==typeof i)for(var a=0,l=Array.prototype.slice.call(we(i,document));a0?r-1:0,i+=e=-1!==e?"-"+e:"-"+r}return this.controlParent!==this.parentObj&&(i=this.parentObj.getParentKey()+"."+this.propName+e),i},n}(),$$=["grid","pivotview","treegrid","spreadsheet","rangeNavigator","DocumentEditor","listbox","inplaceeditor","PdfViewer","richtexteditor","DashboardLayout","chart","stockChart","circulargauge","diagram","heatmap","lineargauge","maps","slider","smithchart","barcode","sparkline","treemap","bulletChart","kanban","daterangepicker","schedule","gantt","signature","query-builder","drop-down-tree","carousel","filemanager","uploader","accordion","tab","treeview"],tR=[115,121,110,99,102,117,115,105,111,110,46,105,115,76,105,99,86,97,108,105,100,97,116,101,100],iR=function(){function n(t){this.isValidated=!1,this.isLicensed=!0,this.version="27",this.platform=/JavaScript|ASPNET|ASPNETCORE|ASPNETMVC|FileFormats|essentialstudio/i,this.errors={noLicense:"This application was built using a trial version of Syncfusion Essential Studio. To remove the license validation message permanently, a valid license key must be included.",trailExpired:"This application was built using a trial version of Syncfusion Essential Studio. To remove the license validation message permanently, a valid license key must be included.",versionMismatched:"The included Syncfusion license key is invalid.",platformMismatched:"The included Syncfusion license key is invalid.",invalidKey:"The included Syncfusion license key is invalid."},this.manager=function(){var e=null;return{setKey:function i(s){e=s},getKey:function r(){return e}}}(),this.npxManager=function(){return{getKey:function i(){return"npxKeyReplace"}}}(),this.manager.setKey(t)}return n.prototype.validate=function(){if(!this.isValidated&&Ku&&!Y(E0(tR),Ku)&&!Y("Blazor",Ku)){var i=void 0,r=void 0;if(this.manager&&this.manager.getKey()||this.npxManager&&"npxKeyReplace"!==this.npxManager.getKey()){var s=this.getInfoFromKey();if(s&&s.length)for(var o=0,a=s;o"+i+' Claim your FREE account\n
have a Syncfusion account? Sign In
\n
\n ';if(typeof document<"u"&&!m(document)){var t=mi("div",{innerHTML:n});document.body.appendChild(t)}}(),oR=!0),this.render(),this.mount?this.accessMount():this.trigger("created")}},t.prototype.renderComplete=function(e){ce()&&window.sfBlazor.renderComplete(this.element,e),this.isRendered=!0},t.prototype.dataBind=function(){this.injectModules(),n.prototype.dataBind.call(this)},t.prototype.on=function(e,i,r){if("string"==typeof e)this.localObserver.on(e,i,r);else for(var s=0,o=e;s=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},tZ={left:0,top:0,bottom:0,right:0},IC={isDragged:!1},iZ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return aR(t,n),gr([I(0)],t.prototype,"left",void 0),gr([I(0)],t.prototype,"top",void 0),t}(Ee),np=function(n){function t(i,r){var s=n.call(this,r,i)||this;return s.dragLimit=e.getDefaultPosition(),s.borderWidth=e.getDefaultPosition(),s.padding=e.getDefaultPosition(),s.diffX=0,s.prevLeft=0,s.prevTop=0,s.dragProcessStarted=!1,s.eleTop=0,s.tapHoldTimer=0,s.externalInitialize=!1,s.diffY=0,s.parentScrollX=0,s.parentScrollY=0,s.droppables={},s.bind(),s}var e;return aR(t,n),e=t,t.prototype.bind=function(){this.toggleEvents(),X.isIE&&V([this.element],"e-block-touch"),this.droppables[this.scope]={}},t.getDefaultPosition=function(){return ze({},tZ)},t.prototype.toggleEvents=function(i){var r;st(this.handle)||(r=U(this.handle,this.element));var s=this.enableTapHold&&X.isDevice&&X.isTouch?this.mobileInitialize:this.initialize;i?E.remove(r||this.element,X.isSafari()?"touchstart":X.touchStartEvent,s):E.add(r||this.element,X.isSafari()?"touchstart":X.touchStartEvent,s,this)},t.prototype.mobileInitialize=function(i){var r=this,s=i.currentTarget;this.tapHoldTimer=setTimeout(function(){r.externalInitialize=!0,r.removeTapholdTimer(),r.initialize(i,s)},this.tapHoldThreshold),E.add(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.removeTapholdTimer,this),E.add(document,X.isSafari()?"touchend":X.touchEndEvent,this.removeTapholdTimer,this)},t.prototype.removeTapholdTimer=function(){clearTimeout(this.tapHoldTimer),E.remove(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.removeTapholdTimer),E.remove(document,X.isSafari()?"touchend":X.touchEndEvent,this.removeTapholdTimer)},t.prototype.getScrollableParent=function(i,r){return m(i)?null:i[{vertical:"scrollHeight",horizontal:"scrollWidth"}[""+r]]>i[{vertical:"clientHeight",horizontal:"clientWidth"}[""+r]]&&("vertical"===r?i.scrollTop>0:i.scrollLeft>0)?("vertical"===r?(this.parentScrollY=this.parentScrollY+(0===this.parentScrollY?i.scrollTop:i.scrollTop-this.parentScrollY),this.tempScrollHeight=i.scrollHeight):(this.parentScrollX=this.parentScrollX+(0===this.parentScrollX?i.scrollLeft:i.scrollLeft-this.parentScrollX),this.tempScrollWidth=i.scrollWidth),m(i)?i:this.getScrollableParent(i.parentNode,r)):this.getScrollableParent(i.parentNode,r)},t.prototype.getScrollableValues=function(){this.parentScrollX=0,this.parentScrollY=0,this.element.classList.contains("e-dialog")&&this.element.classList.contains("e-dlg-modal"),this.getScrollableParent(this.element.parentNode,"vertical"),this.getScrollableParent(this.element.parentNode,"horizontal")},t.prototype.initialize=function(i,r){if(this.currentStateTarget=i.target,!this.isDragStarted()){if(this.isDragStarted(!0),this.externalInitialize=!1,this.target=i.currentTarget||r,this.dragProcessStarted=!1,this.abort){var s=this.abort;"string"==typeof s&&(s=[s]);for(var o=0;o=this.distance||this.externalInitialize){var p=this.getHelperElement(i);if(!p||m(p))return;r&&i.preventDefault();var f=this.helperElement=p;if(this.parentClientRect=this.calculateParentPosition(f.offsetParent),this.dragStart){var v={event:i,element:l,target:this.getProperTargetElement(i),bindEvents:ce()?this.bindDragEvents.bind(this):null,dragElement:f};this.trigger("dragStart",v)}this.dragArea?this.setDragArea():(this.dragLimit={left:0,right:0,bottom:0,top:0},this.borderWidth={top:0,left:0}),o={left:this.position.left-this.parentClientRect.left,top:this.position.top-this.parentClientRect.top},this.clone&&!this.enableTailMode&&(this.diffX=this.position.left-this.offset.left,this.diffY=this.position.top-this.offset.top),this.getScrollableValues();var y=getComputedStyle(l),S=parseFloat(y.marginTop);this.clone&&0!==S&&(o.top+=S),this.eleTop=isNaN(parseFloat(y.top))?0:parseFloat(y.top)-this.offset.top,this.enableScrollHandler&&!this.clone&&(o.top-=this.parentScrollY,o.left-=this.parentScrollX);var b=this.getProcessedPositionValue({top:o.top-this.diffY+"px",left:o.left-this.diffX+"px"});this.dragArea&&"string"!=typeof this.dragArea&&this.dragArea.classList.contains("e-kanban-content")&&"relative"===this.dragArea.style.position&&(o.top+=this.dragArea.scrollTop),this.dragElePosition={top:o.top,left:o.left},je(f,this.getDragPosition({position:"absolute",left:b.left,top:b.top})),E.remove(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.intDragStart),E.remove(document,X.isSafari()?"touchend":X.touchEndEvent,this.intDestroy),ce()||this.bindDragEvents(f)}}},t.prototype.bindDragEvents=function(i){Tr(i)?(E.add(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.intDrag,this),E.add(document,X.isSafari()?"touchend":X.touchEndEvent,this.intDragStop,this),this.setGlobalDroppables(!1,this.element,i)):(this.toggleEvents(),document.body.classList.remove("e-prevent-select"))},t.prototype.elementInViewport=function(i){for(this.top=i.offsetTop,this.left=i.offsetLeft,this.width=i.offsetWidth,this.height=i.offsetHeight;i.offsetParent;)this.top+=(i=i.offsetParent).offsetTop,this.left+=i.offsetLeft;return this.top>=window.pageYOffset&&this.left>=window.pageXOffset&&this.top+this.height<=window.pageYOffset+window.innerHeight&&this.left+this.width<=window.pageXOffset+window.innerWidth},t.prototype.getProcessedPositionValue=function(i){return this.queryPositionInfo?this.queryPositionInfo(i):i},t.prototype.calculateParentPosition=function(i){if(m(i))return{left:0,top:0};var r=i.getBoundingClientRect(),s=getComputedStyle(i);return{left:r.left+window.pageXOffset-parseInt(s.marginLeft,10),top:r.top+window.pageYOffset-parseInt(s.marginTop,10)}},t.prototype.intDrag=function(i){if(st(i.changedTouches)||1===i.changedTouches.length){var r,s;this.clone&&i.changedTouches&&X.isDevice&&X.isTouch&&i.preventDefault(),this.position=this.getMousePosition(i,this.isDragScroll);var o=this.getDocumentWidthHeight("Height");oy&&y>0?this.dragLimit.left:this.dragLimit.right+window.pageXOffset0?y-(y-this.dragLimit.right)+window.pageXOffset-M:y<0?this.dragLimit.left:y}if(this.pageY!==v||this.skipDistanceCheck){var w=d.offsetHeight+(parseFloat(b.marginTop)+parseFloat(b.marginBottom));s=this.dragLimit.top>S&&S>0?this.dragLimit.top:this.dragLimit.bottom+window.pageYOffset0?S-(S-this.dragLimit.bottom)+window.pageYOffset-w:S<0?this.dragLimit.top:S}}else r=y,s=S;var A,x,C=p+this.borderWidth.top,D=u+this.borderWidth.left;if(this.dragProcessStarted&&(m(s)&&(s=this.prevTop),m(r)&&(r=this.prevLeft)),this.helperElement.classList.contains("e-treeview"))this.dragArea?(this.dragLimit.top=this.clone?this.dragLimit.top:0,A=s-C<0?this.dragLimit.top:s-this.borderWidth.top,x=r-D<0?this.dragLimit.left:r-this.borderWidth.left):(A=s-this.borderWidth.top,x=r-this.borderWidth.left);else if(this.dragArea){var R=this.helperElement.classList.contains("e-dialog");this.dragLimit.top=this.clone?this.dragLimit.top:0,A=s-C<0?this.dragLimit.top:s-C,x=r-D<0?R?r-(D-this.borderWidth.left):this.dragElePosition.left:r-D}else A=s-C,x=r-D;var L=parseFloat(getComputedStyle(this.element).marginTop);if(L>0&&(this.clone&&(A+=L,S<0&&(L+S>=0?A=L+S:A-=L),this.dragArea&&(A=this.dragLimit.bottom=0){var O=this.dragLimit.top+S-C;O+L+C<0?A-=L+C:A=O}else A-=L+C;this.dragArea&&this.helperElement.classList.contains("e-treeview")&&(A=A+(w=d.offsetHeight+(parseFloat(b.marginTop)+parseFloat(b.marginBottom)))>this.dragLimit.bottom?this.dragLimit.bottom-w:A),this.enableScrollHandler&&!this.clone&&(A-=this.parentScrollY,x-=this.parentScrollX),this.dragArea&&"string"!=typeof this.dragArea&&this.dragArea.classList.contains("e-kanban-content")&&"relative"===this.dragArea.style.position&&(A+=this.dragArea.scrollTop);var N=this.getProcessedPositionValue({top:A+"px",left:x+"px"});this.isPreventScroll&&(N=this.getProcessedPositionValue({top:this.position.top-this.parentClientRect.top-2+"px",left:this.position.left-this.parentClientRect.left-2+"px"})),je(d,this.getDragPosition(N)),!this.elementInViewport(d)&&this.enableAutoScroll&&!this.helperElement.classList.contains("e-treeview")&&this.helperElement.scrollIntoView();var T=document.querySelectorAll(":hover");if(this.enableAutoScroll&&this.helperElement.classList.contains("e-treeview")){0===T.length&&(T=this.getPathElements(i));var P=this.getScrollParent(T,!1);this.elementInViewport(this.helperElement)?this.getScrollPosition(P,A):this.elementInViewport(this.helperElement)||(0===(T=[].slice.call(document.querySelectorAll(":hover"))).length&&(T=this.getPathElements(i)),P=this.getScrollParent(T,!0),this.getScrollPosition(P,A))}this.dragProcessStarted=!0,this.prevLeft=r,this.prevTop=s,this.position.left=r,this.position.top=s,this.pageX=g,this.pageY=v}},t.prototype.getScrollParent=function(i,r){for(var o,s=r?i.reverse():i,a=s.length-1;a>=0;a--)if(("auto"===(o=window.getComputedStyle(s[parseInt(a.toString(),10)])["overflow-y"])||"scroll"===o)&&s[parseInt(a.toString(),10)].scrollHeight>s[parseInt(a.toString(),10)].clientHeight)return s[parseInt(a.toString(),10)];if("visible"===(o=window.getComputedStyle(document.scrollingElement)["overflow-y"]))return document.scrollingElement.style.overflow="auto",document.scrollingElement},t.prototype.getScrollPosition=function(i,r){if(i&&i===document.scrollingElement)i.clientHeight+document.scrollingElement.scrollTop-this.helperElement.clientHeightr?i.scrollTop+=this.helperElement.clientHeight:i.scrollTop>r-this.helperElement.clientHeight&&(i.scrollTop-=this.helperElement.clientHeight);else if(i&&i!==document.scrollingElement){var s=document.scrollingElement.scrollTop,o=this.helperElement.clientHeight;i.clientHeight+i.getBoundingClientRect().top-o+sr-o-s&&(i.scrollTop-=this.helperElement.clientHeight)}},t.prototype.getPathElements=function(i){return document.elementsFromPoint(i.clientX>0?i.clientX:0,i.clientY>0?i.clientY:0)},t.prototype.triggerOutFunction=function(i,r){this.hoverObject.instance.intOut(i,r.target),this.hoverObject.instance.dragData[this.scope]=null,this.hoverObject=null},t.prototype.getDragPosition=function(i){var r=ze({},i);return this.axis&&("x"===this.axis?delete r.top:"y"===this.axis&&delete r.left),r},t.prototype.getDocumentWidthHeight=function(i){var r=document.body,s=document.documentElement;return Math.max(r["scroll"+i],s["scroll"+i],r["offset"+i],s["offset"+i],s["client"+i])},t.prototype.intDragStop=function(i){if(this.dragProcessStarted=!1,st(i.changedTouches)||1===i.changedTouches.length){if(-1!==["touchend","pointerup","mouseup"].indexOf(i.type)){if(this.dragStop){var s=this.getProperTargetElement(i);this.trigger("dragStop",{event:i,element:this.element,target:s,helper:this.helperElement})}this.intDestroy(i)}else this.element.setAttribute("aria-grabbed","false");var o=this.checkTargetElement(i);o.target&&o.instance&&(o.instance.dragStopCalled=!0,o.instance.dragData[this.scope]=this.droppables[this.scope],o.instance.intDrop(i,o.target)),this.setGlobalDroppables(!0),document.body.classList.remove("e-prevent-select")}},t.prototype.intDestroy=function(i){this.dragProcessStarted=!1,this.toggleEvents(),document.body.classList.remove("e-prevent-select"),this.element.setAttribute("aria-grabbed","false"),E.remove(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.intDragStart),E.remove(document,X.isSafari()?"touchend":X.touchEndEvent,this.intDragStop),E.remove(document,X.isSafari()?"touchend":X.touchEndEvent,this.intDestroy),E.remove(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.intDrag),this.isDragStarted()&&this.isDragStarted(!0)},t.prototype.onPropertyChanged=function(i,r){},t.prototype.getModuleName=function(){return"draggable"},t.prototype.isDragStarted=function(i){return i&&(IC.isDragged=!IC.isDragged),IC.isDragged},t.prototype.setDragArea=function(){var i,r,a,s=0,o=0;if(a="string"==typeof this.dragArea?U(this.dragArea):this.dragArea){var h=a.getBoundingClientRect();i=a.scrollWidth?a.scrollWidth:h.right-h.left,r=a.scrollHeight?this.dragArea&&!m(this.helperElement)&&this.helperElement.classList.contains("e-treeview")?a.clientHeight:a.scrollHeight:h.bottom-h.top;for(var c=["Top","Left","Bottom","Right"],d=getComputedStyle(a),u=0;u12;return b0(i.target,this.helperElement)||-1!==i.type.indexOf("touch")||a?(this.helperElement.style.pointerEvents="none",s=document.elementFromPoint(r.clientX,r.clientY),this.helperElement.style.pointerEvents=o):s=i.target,s},t.prototype.currentStateCheck=function(i,r){return m(this.currentStateTarget)||this.currentStateTarget===i?m(r)?i:r:this.currentStateTarget},t.prototype.getMousePosition=function(i,r){var a,l,s=void 0!==i.srcElement?i.srcElement:i.target,o=this.getCoordinates(i),h=m(s.offsetParent);if(r?(a=this.clone?o.pageX:o.pageX+(h?0:s.offsetParent.scrollLeft)-this.relativeXPosition,l=this.clone?o.pageY:o.pageY+(h?0:s.offsetParent.scrollTop)-this.relativeYPosition):(a=this.clone?o.pageX:o.pageX+window.pageXOffset-this.relativeXPosition,l=this.clone?o.pageY:o.pageY+window.pageYOffset-this.relativeYPosition),document.scrollingElement&&!r&&!this.clone){var c=document.scrollingElement;a=c.scrollWidth>0&&c.scrollWidth>c.clientWidth&&c.scrollLeft>0?a-c.scrollLeft:a,l=c.scrollHeight>0&&c.scrollHeight>c.clientHeight&&c.scrollTop>0?l-c.scrollTop:l}return{left:a-(this.margin.left+this.cursorAt.left),top:l-(this.margin.top+this.cursorAt.top)}},t.prototype.getCoordinates=function(i){return i.type.indexOf("touch")>-1?i.changedTouches[0]:i},t.prototype.getHelperElement=function(i){var r;return this.clone?this.helper?r=this.helper({sender:i,element:this.target}):(r=mi("div",{className:"e-drag-helper e-block-touch",innerHTML:"Draggable"}),document.body.appendChild(r)):r=this.element,r},t.prototype.setGlobalDroppables=function(i,r,s){this.droppables[this.scope]=i?null:{draggable:r,helper:s,draggedElement:this.element}},t.prototype.checkTargetElement=function(i){var r=this.getProperTargetElement(i),s=this.getDropInstance(r);if(!s&&r&&!m(r.parentNode)){var o=J(r.parentNode,".e-droppable")||r.parentElement;o&&(s=this.getDropInstance(o))}return{target:r,instance:s}},t.prototype.getDropInstance=function(i){var s,o=i&&i.ej2_instances;if(o)for(var a=0,l=o;a=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},lR=function(n){function t(e,i){var r=n.call(this,i,e)||this;return r.mouseOver=!1,r.dragData={},r.dragStopCalled=!1,r.bind(),r}return rZ(t,n),t.prototype.bind=function(){this.wireEvents()},t.prototype.wireEvents=function(){E.add(this.element,X.isSafari()?"touchend":X.touchEndEvent,this.intDrop,this)},t.prototype.onPropertyChanged=function(e,i){},t.prototype.getModuleName=function(){return"droppable"},t.prototype.intOver=function(e,i){this.mouseOver||(this.trigger("over",{event:e,target:i,dragData:this.dragData[this.scope]}),this.mouseOver=!0)},t.prototype.intOut=function(e,i){this.mouseOver&&(this.trigger("out",{evt:e,target:i}),this.mouseOver=!1)},t.prototype.intDrop=function(e,i){if(this.dragStopCalled){this.dragStopCalled=!1;var a,r=!0,s=this.dragData[this.scope],o=!!s&&s.helper&&Tr(s.helper);o&&(a=this.isDropArea(e,s.helper,i),this.accept&&(r=gC(s.helper,this.accept))),o&&this.drop&&a.canDrop&&r&&this.trigger("drop",{event:e,target:a.target,droppedElement:s.helper,dragData:s}),this.mouseOver=!1}},t.prototype.isDropArea=function(e,i,r){var s={canDrop:!0,target:r||e.target},o="touchend"===e.type;if(o||s.target===i){i.style.display="none";var a=o?e.changedTouches[0]:e,l=document.elementFromPoint(a.clientX,a.clientY);s.canDrop=!1,s.canDrop=b0(l,this.element),s.canDrop&&(s.target=l),i.style.display=""}return s},t.prototype.destroy=function(){E.remove(this.element,X.isSafari()?"touchend":X.touchEndEvent,this.intDrop),n.prototype.destroy.call(this)},sp([I()],t.prototype,"accept",void 0),sp([I("default")],t.prototype,"scope",void 0),sp([H()],t.prototype,"drop",void 0),sp([H()],t.prototype,"over",void 0),sp([H()],t.prototype,"out",void 0),sp([Ft],t)}(ah),ho=function(){function n(t,e,i){this.controlName=t,this.localeStrings=e,this.setLocale(i||"en-US")}return n.prototype.setLocale=function(t){var e=this.intGetControlConstant(n.locale,t);this.currentLocale=e||this.localeStrings},n.load=function(t){this.locale=ze(this.locale,t,{},!0)},n.prototype.getConstant=function(t){return m(this.currentLocale[""+t])?this.localeStrings[""+t]||"":this.currentLocale[""+t]},n.prototype.intGetControlConstant=function(t,e){return t[""+e]?t[""+e][this.controlName]:null},n.locale={},n}(),hR=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),hh=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},oZ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return hR(t,n),hh([I(50)],t.prototype,"swipeThresholdDistance",void 0),t}(Ee),aZ=/(Up|Down)/,Fs=function(n){function t(e,i){var r=n.call(this,i,e)||this;return r.touchAction=!0,r.tapCount=0,r.startEvent=function(s){if(!0===r.touchAction){var o=r.updateChangeTouches(s);void 0!==s.changedTouches&&(r.touchAction=!1),r.isTouchMoved=!1,r.movedDirection="",r.startPoint=r.lastMovedPoint={clientX:o.clientX,clientY:o.clientY},r.startEventData=o,r.hScrollLocked=r.vScrollLocked=!1,r.tStampStart=Date.now(),r.timeOutTapHold=setTimeout(function(){r.tapHoldEvent(s)},r.tapHoldThreshold),E.add(r.element,X.touchMoveEvent,r.moveEvent,r),E.add(r.element,X.touchEndEvent,r.endEvent,r),E.add(r.element,X.touchCancelEvent,r.cancelEvent,r)}},r.moveEvent=function(s){var o=r.updateChangeTouches(s);r.movedPoint=o,r.isTouchMoved=!(o.clientX===r.startPoint.clientX&&o.clientY===r.startPoint.clientY);var a={};r.isTouchMoved&&(clearTimeout(r.timeOutTapHold),r.calcScrollPoints(s),a=ze(a,{},{startEvents:r.startEventData,originalEvent:s,startX:r.startPoint.clientX,startY:r.startPoint.clientY,distanceX:r.distanceX,distanceY:r.distanceY,scrollDirection:r.scrollDirection,velocity:r.getVelocity(o)}),r.trigger("scroll",a),r.lastMovedPoint={clientX:o.clientX,clientY:o.clientY})},r.cancelEvent=function(s){clearTimeout(r.timeOutTapHold),clearTimeout(r.timeOutTap),r.tapCount=0,r.swipeFn(s),E.remove(r.element,X.touchCancelEvent,r.cancelEvent)},r.endEvent=function(s){r.swipeFn(s),r.isTouchMoved||"function"==typeof r.tap&&(r.trigger("tap",{originalEvent:s,tapCount:++r.tapCount}),r.timeOutTap=setTimeout(function(){r.tapCount=0},r.tapThreshold)),r.modeclear()},r.swipeFn=function(s){clearTimeout(r.timeOutTapHold),clearTimeout(r.timeOutTap);var o=r.updateChangeTouches(s),a=o.clientX-r.startPoint.clientX,l=o.clientY-r.startPoint.clientY;a=Math.floor(a<0?-1*a:a),l=Math.floor(l<0?-1*l:a),r.isTouchMoved=a>1||l>1,/Firefox/.test(X.userAgent)&&0===o.clientX&&0===o.clientY&&"mouseup"===s.type&&(r.isTouchMoved=!1),r.endPoint=o,r.calcPoints(s);var c={originalEvent:s,startEvents:r.startEventData,startX:r.startPoint.clientX,startY:r.startPoint.clientY,distanceX:r.distanceX,distanceY:r.distanceY,swipeDirection:r.movedDirection,velocity:r.getVelocity(o)};if(r.isTouchMoved){var d=r.swipeSettings.swipeThresholdDistance,u=ze(void 0,r.defaultArgs,c),p=!1,f=r.element,g=r.isScrollable(f),v=aZ.test(r.movedDirection);(dthis.distanceY?i.clientX>this.startPoint.clientX?"Right":"Left":i.clientYthis.distanceY||!0===this.hScrollLocked)&&!1===this.vScrollLocked?(this.scrollDirection=i.clientX>this.lastMovedPoint.clientX?"Right":"Left",this.hScrollLocked=!0):(this.scrollDirection=i.clientY=e[r[0]+s[0]]},t.prototype.updateChangeTouches=function(e){return e.changedTouches&&0!==e.changedTouches.length?e.changedTouches[0]:e},hh([H()],t.prototype,"tap",void 0),hh([H()],t.prototype,"tapHold",void 0),hh([H()],t.prototype,"swipe",void 0),hh([H()],t.prototype,"scroll",void 0),hh([I(350)],t.prototype,"tapThreshold",void 0),hh([I(750)],t.prototype,"tapHoldThreshold",void 0),hh([re({},oZ)],t.prototype,"swipeSettings",void 0),hh([Ft],t)}(ah),lZ=new RegExp("\\n|\\r|\\s\\s+","g"),hZ=new RegExp(/'|"/g),cZ=new RegExp("if ?\\("),dZ=new RegExp("else if ?\\("),cR=new RegExp("else"),uZ=new RegExp("for ?\\("),dR=new RegExp("(/if|/for)"),pZ=new RegExp("\\((.*)\\)",""),bC=new RegExp("^[0-9]+$","g"),fZ=new RegExp("[\\w\"'.\\s+]+","g"),gZ=new RegExp('"(.*?)"',"g"),vZ=new RegExp("[\\w\"'@#$.\\s-+]+","g"),uR=new RegExp("\\${([^}]*)}","g"),mZ=/^\..*/gm,MC=/\\/gi,yZ=/\\\\/gi,SZ=new RegExp("[\\w\"'@#$.\\s+]+","g"),IZ=/\window\./gm;function op(n,t,e,i,r){return!t||bC.test(n)||-1!==i.indexOf(n.split(".")[0])||r||"true"===n||"false"===n?n:e+"."+n}function wC(n,t,e,i){return t&&!bC.test(n)&&-1===i.indexOf(n.split(".")[0])?e+'["'+n:n}function pR(n){return n.match(yZ)?n:n.replace(MC,"\\\\")}function fR(n,t,e,i){if(n=n.trim(),/\window\./gm.test(n))return n;var s=/'|"/gm;return/@|\$|#/gm.test(n)&&(n=wC(n,-1===e.indexOf(n),t,e)+'"]'),mZ.test(n)?function wZ(n,t,e,i){return!t||bC.test(n)||-1!==i.indexOf(n.split(".")[0])||/^\..*/gm.test(n)?n:e+"."+n}(n,!s.test(n)&&-1===e.indexOf(n),t,e):op(n,!s.test(n)&&-1===e.indexOf(n),t,e,i)}var CZ=/^[\n\r.]+0&&t.forEach(function(e){he(e)})},n.removeJsEvents=function(){var t=this.wrapElement.querySelectorAll("["+vR.join("],[")+"]");t.length>0&&t.forEach(function(e){vR.forEach(function(i){e.hasAttribute(i)&&e.removeAttribute(i)})})},n.removeXssAttrs=function(){var t=this;this.removeAttrs.forEach(function(e,i){var r=t.wrapElement.querySelectorAll(e.selector);r.length>0&&r.forEach("a[href]"===e.selector?function(s){-1!==s.getAttribute(e.attribute).replace(/\t|\s|&/,"").indexOf("javascript:alert")&&s.removeAttribute(e.attribute)}:function(s){s.removeAttribute(e.attribute)})})},n}();function NZ(n){for(var t,e=n.childNodes,i=0;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Jo_RTL=(new Tg,"e-rtl"),ys=function(n){function t(e,i){return n.call(this,e,i)||this}return PZ(t,n),t.prototype.preRender=function(){},t.prototype.render=function(){this.initialize(),this.removeRippleEffect=function ms(n,t,e){var i=function G$(n){return{selector:n&&n.selector?n.selector:null,ignore:n&&n.ignore?n.ignore:null,rippleFlag:n&&n.rippleFlag,isCenterRipple:n&&n.isCenterRipple,duration:n&&n.duration?n.duration:350}}(t);return!1===i.rippleFlag||void 0===i.rippleFlag&&!Zo?function(){}:(n.setAttribute("data-ripple","true"),E.add(n,"mousedown",Zz,{parent:n,rippleOptions:i}),E.add(n,"mouseup",Jz,{parent:n,rippleOptions:i,done:e}),E.add(n,"mouseleave",rp,{parent:n,rippleOptions:i}),X.isPointer&&E.add(n,"transitionend",rp,{parent:n,rippleOptions:i}),function(){n.removeAttribute("data-ripple"),E.remove(n,"mousedown",Zz),E.remove(n,"mouseup",Jz),E.remove(n,"mouseleave",rp),E.remove(n,"transitionend",rp)})}(this.element,{selector:".e-btn"}),this.renderComplete()},t.prototype.initialize=function(){if(this.cssClass&&V([this.element],this.cssClass.replace(/\s+/g," ").trim().split(" ")),this.isPrimary&&this.element.classList.add("e-primary"),!ce()||ce()&&"progress-btn"!==this.getModuleName()){if(this.content){var e=this.enableHtmlSanitizer?Ti.sanitize(this.content):this.content;this.element.innerHTML=e}this.setIconCss()}this.enableRtl&&this.element.classList.add(Jo_RTL),this.disabled?this.controlStatus(this.disabled):this.wireEvents()},t.prototype.controlStatus=function(e){this.element.disabled=e},t.prototype.setIconCss=function(){if(this.iconCss){var e=this.createElement("span",{className:"e-btn-icon "+this.iconCss});this.element.textContent.trim()?(e.classList.add("e-icon-"+this.iconPosition.toLowerCase()),("Top"===this.iconPosition||"Bottom"===this.iconPosition)&&this.element.classList.add("e-"+this.iconPosition.toLowerCase()+"-icon-btn")):this.element.classList.add("e-icon-btn");var i=this.element.childNodes[0];!i||"Left"!==this.iconPosition&&"Top"!==this.iconPosition?this.element.appendChild(e):this.element.insertBefore(e,i)}},t.prototype.wireEvents=function(){this.isToggle&&E.add(this.element,"click",this.btnClickHandler,this)},t.prototype.unWireEvents=function(){this.isToggle&&E.remove(this.element,"click",this.btnClickHandler)},t.prototype.btnClickHandler=function(){this.element.classList.contains("e-active")?this.element.classList.remove("e-active"):this.element.classList.add("e-active")},t.prototype.destroy=function(){var e=["e-primary",Jo_RTL,"e-icon-btn","e-success","e-info","e-danger","e-warning","e-flat","e-outline","e-small","e-bigger","e-active","e-round","e-top-icon-btn","e-bottom-icon-btn"];this.cssClass&&(e=e.concat(this.cssClass.split(" "))),n.prototype.destroy.call(this),K([this.element],e),this.element.getAttribute("class")||this.element.removeAttribute("class"),this.disabled&&this.element.removeAttribute("disabled"),this.content&&(this.element.innerHTML=this.element.innerHTML.replace(this.content,""));var i=this.element.querySelector("span.e-btn-icon");i&&he(i),this.unWireEvents(),Zo&&this.removeRippleEffect()},t.prototype.getModuleName=function(){return"btn"},t.prototype.getPersistData=function(){return this.addOnPersist([])},t.Inject=function(){},t.prototype.onPropertyChanged=function(e,i){for(var r=this.element.querySelector("span.e-btn-icon"),s=0,o=Object.keys(e);s=ad.width?ad.width:0;return vl.right+QR()-n}function lE(){return R0()+vl.width/2}function hE(n,t,e,i){if(void 0===t&&(t=null),void 0===e&&(e={X:!1,Y:!1}),!e.Y&&!e.X)return{left:0,top:0};var r=n.getBoundingClientRect();if(uo=t,sc=n.ownerDocument,i||(i=is(n,"left","top")),e.X){var s=uo?ZR():i4(),o=fE(),a=gE(),l=o-i.left,h=i.left+r.width-a;r.width>s?i.left=l>0&&h<=0?a-r.width:h>0&&l<=0?o:l>h?a-r.width:o:l>0?i.left+=l:h>0&&(i.left-=h)}if(e.Y){var c=uo?JR():t4(),d=pE(),u=vE(),p=d-i.top,f=i.top+r.height-u;r.height>c?i.top=p>0&&f<=0?u-r.height:f>0&&p<=0?d:p>f?u-r.height:d:p>0?i.top+=p:f>0&&(i.top-=f)}return i}function oc(n,t,e,i){void 0===t&&(t=null);var r=is(n,"left","top");e&&(r.left=e),i&&(r.top=i);var s=[];uo=t,sc=n.ownerDocument;var o=n.getBoundingClientRect(),l=r.left,h=r.left+o.width,d=uE(r.top,r.top+o.height),u=XR(l,h);return d.topSide&&s.push("top"),u.rightSide&&s.push("right"),u.leftSide&&s.push("left"),d.bottomSide&&s.push("bottom"),s}function cJ(n,t,e,i,r,s,o,a,l){if(void 0===o&&(o=null),void 0===a&&(a={X:!0,Y:!0}),t&&n&&r&&s&&(a.X||a.Y)){var d,h={TL:null,TR:null,BL:null,BR:null},c={TL:null,TR:null,BL:null,BR:null};if("none"===window.getComputedStyle(n).display){var u=n.style.visibility;n.style.visibility="hidden",n.style.display="block",d=n.getBoundingClientRect(),n.style.removeProperty("display"),n.style.visibility=u}else d=n.getBoundingClientRect();var p={posX:r,posY:s,offsetX:e,offsetY:i,position:{left:0,top:0}};uo=o,sc=t.ownerDocument,function uJ(n,t,e,i,r){e.position=is(n,e.posX,e.posY,i,r),t.TL=is(n,"left","top",i,r),t.TR=is(n,"right","top",i,r),t.BR=is(n,"left","bottom",i,r),t.BL=is(n,"right","bottom",i,r)}(t,h,p,l,d),dE(c,p,d),a.X&&qR(t,c,h,p,d,!0),a.Y&&h.TL.top>-1&&$R(t,c,h,p,d,!0),function dJ(n,t,e){var i=0,r=0;if(null!=n.offsetParent&&("absolute"===getComputedStyle(n.offsetParent).position||"relative"===getComputedStyle(n.offsetParent).position)){var s=is(n.offsetParent,"left","top",!1,e);i=s.left,r=s.top}var o=1,a=1,l=GR(n);if(l){var h=getComputedStyle(l).transform;if("none"!==h){var c=new DOMMatrix(h);o=c.a,a=c.d}if("none"!==getComputedStyle(l).zoom){var u=cE(document.body);o*=u,a*=u}}n.style.top=t.position.top/a+t.offsetY-r/a+"px",n.style.left=t.position.left/o+t.offsetX-i/o+"px"}(n,p,d)}}function cE(n){var t=getComputedStyle(n).zoom;return parseFloat(t)||1}function GR(n){for(;n;){var t=window.getComputedStyle(n).transform,e=cE(document.body);if(t&&"none"!==t||e&&1!==e)return n;if(n===document.body)return null;n=n.offsetParent||n.parentElement}return null}function dE(n,t,e){n.TL={top:t.position.top+t.offsetY,left:t.position.left+t.offsetX},n.TR={top:n.TL.top,left:n.TL.left+e.width},n.BL={top:n.TL.top+e.height,left:n.TL.left},n.BR={top:n.TL.top+e.height,left:n.TL.left+e.width}}function XR(n,t){var e=!1,i=!1;return n-B0()gE()&&(i=!0),{leftSide:e,rightSide:i}}function qR(n,t,e,i,r,s){var o=XR(t.TL.left,t.TR.left),a=uE(t.TL.top,t.BL.top);e.TL.left-B0()<=fE()&&(o.leftSide=!1),e.TR.left>gE()&&(o.rightSide=!1),(o.leftSide&&!o.rightSide||!o.leftSide&&o.rightSide)&&(i.posX="right"===i.posX?"left":"right",i.offsetX=i.offsetX+r.width,i.offsetX=-1*i.offsetX,i.position=is(n,i.posX,i.posY,!1),dE(t,i,r),s&&qR(n,t,e,i,r,!1),!o.leftSide&&o.rightSide&&a.bottomSide&&(i.offsetX=0))}function $R(n,t,e,i,r,s){var o=uE(t.TL.top,t.BL.top);e.TL.top-H0()<=pE()&&(o.topSide=!1),e.BL.top>=vE()&&n.getBoundingClientRect().bottomvE()&&(i=!0),{topSide:e,bottomSide:i}}function ZR(){return uo.getBoundingClientRect().width}function JR(){return uo.getBoundingClientRect().height}function KR(){return uo.getBoundingClientRect().left}function e4(){return uo.getBoundingClientRect().top}function pE(){return uo?e4():0}function fE(){return uo?KR():0}function gE(){return uo?B0()+KR()+ZR():B0()+i4()}function vE(){return uo?H0()+e4()+JR():H0()+t4()}function H0(){return sc.documentElement.scrollTop||sc.body.scrollTop}function B0(){return sc.documentElement.scrollLeft||sc.body.scrollLeft}function t4(){return window.innerHeight}function i4(){var n=window.innerWidth,t=document.documentElement.getBoundingClientRect();return n-(n-(m(document.documentElement)?0:t.width))}function r4(){uo=null,sc=null}var n4=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),bn=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},s4=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return n4(t,n),bn([I("left")],t.prototype,"X",void 0),bn([I("top")],t.prototype,"Y",void 0),t}(Ee),Gn_OPEN="e-popup-open",Gn_CLOSE="e-popup-close",ac=function(n){function t(e,i){return n.call(this,i,e)||this}return n4(t,n),t.prototype.onPropertyChanged=function(e,i){for(var r=0,s=Object.keys(e);r0&&c.left>0&&c.right>0&&c.bottom>0}var s=i.getBoundingClientRect();return!(r.bottoms.bottom||r.right>s.right||r.leftr.top?this.element.style.top="0px":s.bottomr.left&&(this.element.style.left=parseInt(this.element.style.left,10)+(s.left-r.left)+"px"))}},t.prototype.checkCollision=function(){var e=this.collision.X,i=this.collision.Y;"none"===e&&"none"===i||("flip"===e&&"flip"===i?this.callFlip({X:!0,Y:!0}):"fit"===e&&"fit"===i?this.callFit({X:!0,Y:!0}):("flip"===e?this.callFlip({X:!0,Y:!1}):"flip"===i&&this.callFlip({Y:!0,X:!1}),"fit"===e?this.callFit({X:!0,Y:!1}):"fit"===i&&this.callFit({X:!1,Y:!0})))},t.prototype.show=function(e,i){var r=this;if(this.getRelateToElement().classList.contains("e-filemanager")&&(this.fmDialogContainer=this.element.getElementsByClassName("e-file-select-wrap")[0]),this.wireEvents(),!m(this.fmDialogContainer)&&X.isIos&&(this.fmDialogContainer.style.display="block"),1e3===this.zIndex||!m(i)){var o=m(i)?this.element:i;this.zIndex=lc(o),je(this.element,{zIndex:this.zIndex})}e=m(e)||"object"!=typeof e?this.showAnimation:e,("none"!==this.collision.X||"none"!==this.collision.Y)&&(K([this.element],Gn_CLOSE),V([this.element],Gn_OPEN),this.checkCollision(),K([this.element],Gn_OPEN),V([this.element],Gn_CLOSE)),m(e)?(K([this.element],Gn_CLOSE),V([this.element],Gn_OPEN),this.trigger("open")):(e.begin=function(){r.isDestroyed||(K([r.element],Gn_CLOSE),V([r.element],Gn_OPEN))},e.end=function(){r.isDestroyed||r.trigger("open")},new Hs(e).animate(this.element))},t.prototype.hide=function(e){var i=this;e=m(e)||"object"!=typeof e?this.hideAnimation:e,m(e)?(K([this.element],Gn_OPEN),V([this.element],Gn_CLOSE),this.trigger("close")):(e.end=function(){i.isDestroyed||(K([i.element],Gn_OPEN),V([i.element],Gn_CLOSE),i.trigger("close"))},new Hs(e).animate(this.element)),this.unwireEvents()},t.prototype.getScrollableParent=function(e){return this.checkFixedParent(e),function mE(n,t){for(var e=getComputedStyle(n),i=[],r=/(auto|scroll)/,s=n.parentElement;s&&"HTML"!==s.tagName;){var o=getComputedStyle(s);!("absolute"===e.position&&"static"===o.position)&&r.test(o.overflow+o.overflowY+o.overflowX)&&i.push(s),s=s.parentElement}return t||i.push(document),i}(e,this.fixedParent)},t.prototype.checkFixedParent=function(e){for(var i=e.parentElement;i&&"HTML"!==i.tagName;){var r=getComputedStyle(i);("fixed"===r.position||"sticky"===r.position)&&!m(this.element)&&this.element.offsetParent&&"BODY"===this.element.offsetParent.tagName&&"hidden"!==getComputedStyle(this.element.offsetParent).overflow&&(this.element.style.top=window.scrollY>parseInt(this.element.style.top,10)?Re(window.scrollY-parseInt(this.element.style.top,10)):Re(parseInt(this.element.style.top,10)-window.scrollY),this.element.style.position="fixed",this.fixedParent=!0),i=i.parentElement,!m(this.element)&&m(this.element.offsetParent)&&"fixed"===r.position&&"fixed"===this.element.style.position&&(this.fixedParent=!0)}},bn([I("auto")],t.prototype,"height",void 0),bn([I("auto")],t.prototype,"width",void 0),bn([I(null)],t.prototype,"content",void 0),bn([I("container")],t.prototype,"targetType",void 0),bn([I(null)],t.prototype,"viewPortElement",void 0),bn([I({X:"none",Y:"none"})],t.prototype,"collision",void 0),bn([I("")],t.prototype,"relateTo",void 0),bn([re({},s4)],t.prototype,"position",void 0),bn([I(0)],t.prototype,"offsetX",void 0),bn([I(0)],t.prototype,"offsetY",void 0),bn([I(1e3)],t.prototype,"zIndex",void 0),bn([I(!1)],t.prototype,"enableRtl",void 0),bn([I("reposition")],t.prototype,"actionOnScroll",void 0),bn([I(null)],t.prototype,"showAnimation",void 0),bn([I(null)],t.prototype,"hideAnimation",void 0),bn([H()],t.prototype,"open",void 0),bn([H()],t.prototype,"close",void 0),bn([H()],t.prototype,"targetExitViewport",void 0),bn([Ft],t)}(yi);function lc(n){for(var t=n.parentElement,e=[];t&&"BODY"!==t.tagName;){var i=document.defaultView.getComputedStyle(t,null).getPropertyValue("z-index"),r=document.defaultView.getComputedStyle(t,null).getPropertyValue("position");"auto"!==i&&"static"!==r&&e.push(i),t=t.parentElement}for(var s=[],o=0;o2147483647?2147483647:c}var _i,Oa,ap,fh,bE,gh,Zt,vh,yE=["north-west","north","north-east","west","east","south-west","south","south-east"],jg="e-resize-handle",hc="e-focused-handle",pJ="e-dlg-resizable",o4=["e-restrict-left"],a4="e-resize-viewport",fJ=["north","west","east","south"],SE=0,IE=0,l4=0,h4=0,Vg=0,Wg=0,Yg=null,ME=null,wE=null,F0=!0,c4=0,CE=!0;function vJ(n){EE();var t=mi("span",{attrs:{unselectable:"on",contenteditable:"false"}});t.setAttribute("class","e-dialog-border-resize e-"+n),"south"===n&&(t.style.height="2px",t.style.width="100%",t.style.bottom="0px",t.style.left="0px"),"north"===n&&(t.style.height="2px",t.style.width="100%",t.style.top="0px",t.style.left="0px"),"east"===n&&(t.style.height="100%",t.style.width="2px",t.style.right="0px",t.style.top="0px"),"west"===n&&(t.style.height="100%",t.style.width="2px",t.style.left="0px",t.style.top="0px"),_i.appendChild(t)}function d4(n){var t;return m(n)||(t="string"==typeof n?document.querySelector(n):n),t}function u4(n){for(var t=n||this,e=_i.querySelectorAll("."+jg),i=0;i-1?"mouse":"touch"}function f4(n){if(n.preventDefault(),_i=n.target.parentElement,EE(),Vg=n.pageX,Wg=n.pageY,n.target.classList.add(hc),m(Yg)||!0!==Yg(n,this)){this.targetEle&&_i&&_i.querySelector("."+pJ)&&(Zt="body"===this.target?null:this.targetEle,gh=this.targetEle.clientWidth,fh=this.targetEle.clientHeight);var e=m(Zt)?document:Zt;E.add(e,"mousemove",Qg,this),E.add(document,"mouseup",_0,this);for(var i=0;i=0||s.top<0)&&(e=!0):e=!0;var a=IE+(r-Wg);a=a>ap?a:ap;var l=0;m(Zt)||(l=o.top);var h=m(Zt)?0:Zt.offsetHeight-Zt.clientHeight,c=s.top-l-h/2;if(c=c<0?0:c,s.top>0&&c+a>fh){if(e=!1,_i.classList.contains(a4))return;_i.style.height=fh-parseInt(c.toString(),10)+"px"}else{var d=0;if(e){s.top<0&&t+(s.height+s.top)>0&&a+(d=s.top)<=30&&(a=s.height-(s.height+s.top)+30),a+s.top>=fh&&(_i.style.height=s.height+(t-(s.height+s.top))+"px");var u=m(Zt)?d:c;a>=ap&&a+u<=fh&&(_i.style.height=a+"px")}}}function xE(n){var e,t=!1,i="mouse"===p4(n.type)?n.pageY:n.touches[0].pageY,r=cc(_i),s=m(Zt)?0:Zt.offsetHeight-Zt.clientHeight;m(Zt)||(e=cc(Zt)),(!m(Zt)&&r.top-e.top>0||m(Zt)&&i>0||!m(Zt)&&Math.floor(r.top-e.top+r.height+(e.bottom-r.bottom))-s<=fh)&&(t=!0);var o=IE-(i-Wg);if(t&&o>=ap&&o<=fh){var a=0;m(Zt)||(a=e.top);var l=h4-a+(i-Wg);l=l>0?l:1,_i.style.height=o+"px",_i.style.top=l+"px"}}function TE(n){var i,t=document.documentElement.clientWidth,e=!1;m(Zt)||(i=cc(Zt));var r="mouse"===p4(n.type)?n.pageX:n.touches[0].pageX,s=cc(_i),o=m(Zt)?0:Zt.offsetWidth-Zt.clientWidth,a=m(Zt)?0:i.left,l=m(Zt)?0:i.width;m(vh)&&(m(Zt)?vh=t:(vh=s.left-a-o/2+s.width,vh+=l-o-vh)),(!m(Zt)&&Math.floor(s.left-i.left+s.width+(i.right-s.right))-o<=gh||m(Zt)&&r>=0)&&(e=!0);var h=SE-(r-Vg);if(F0&&(h=h>vh?vh:h),e&&h>=bE&&h<=gh){var c=0;m(Zt)||(c=i.left);var d=l4-c+(r-Vg);d=d>0?d:1,h!==c4&&CE&&(_i.style.width=h+"px"),F0&&(_i.style.left=d+"px",CE=1!==d)}c4=h}function AE(n){var i,t=document.documentElement.clientWidth,e=!1;m(Zt)||(i=cc(Zt));var s=(n.touches?n.changedTouches[0]:n).pageX,o=cc(_i);(!m(Zt)&&(o.left-i.left+o.width<=gh||o.right-i.left>=o.width)||m(Zt)&&t-s>0)&&(e=!0);var a=SE+(s-Vg),l=0;if(m(Zt)||(l=i.left),o.left-l+a>gh){if(e=!1,_i.classList.contains(a4))return;_i.style.width=gh-(o.left-l)+"px"}e&&a>=bE&&a<=gh&&(_i.style.width=a+"px")}function v4(){for(var n=_i.querySelectorAll("."+jg),t=0;t=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},bJ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return LE(t,n),Jt([I(!0)],t.prototype,"isFlat",void 0),Jt([I()],t.prototype,"buttonModel",void 0),Jt([I("Button")],t.prototype,"type",void 0),Jt([H()],t.prototype,"click",void 0),t}(Ee),MJ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return LE(t,n),Jt([I("Fade")],t.prototype,"effect",void 0),Jt([I(400)],t.prototype,"duration",void 0),Jt([I(0)],t.prototype,"delay",void 0),t}(Ee),U0="e-dialog",NE="e-rtl",OE="e-dlg-header-content",m4="e-dlg-header",j0="e-footer-content",V0="e-dlg-modal",y4="e-icon-dlg-close",ml="e-dlg-target",ka="e-scroll-disabled",S4="e-device",W0="e-dlg-fullscreen",I4="e-dlg-closeicon-btn",b4="e-popup-open",M4="Information",w4="e-scroll-disabled",C4="e-alert-dialog",E4="e-confirm-dialog",kE="e-dlg-resizable",lp="e-restrict-left",D4="e-resize-viewport",PE="user action",zJ=function(n){function t(e,i){var r=n.call(this,e,i)||this;return r.needsID=!0,r}return LE(t,n),t.prototype.render=function(){this.initialize(),this.initRender(),this.wireEvents(),"100%"===this.width&&(this.element.style.width=""),""!==this.minHeight&&(this.element.style.minHeight=Re(this.minHeight)),this.enableResize&&(this.setResize(),this.isModal&&(this.isModelResize=!0),"None"===this.animationSettings.effect&&this.getMinHeight()),this.renderComplete()},t.prototype.initializeValue=function(){this.dlgClosedBy=PE},t.prototype.preRender=function(){var e=this;if(this.initializeValue(),this.headerContent=null,this.allowMaxHeight=!0,this.preventVisibility=!0,this.clonedEle=this.element.cloneNode(!0),this.closeIconClickEventHandler=function(s){e.dlgClosedBy="close icon",e.hide(s)},this.dlgOverlayClickEventHandler=function(s){e.dlgClosedBy="overlayClick",s.preventFocus=!1,e.trigger("overlayClick",s,function(o){o.preventFocus||e.focusContent(),e.dlgClosedBy=PE})},this.l10n=new ho("dialog",{close:"Close"},this.locale),this.checkPositionData(),m(this.target)){var r=this.isProtectedOnChange;this.isProtectedOnChange=!0,this.target=document.body,this.isProtectedOnChange=r}},t.prototype.updatePersistData=function(){this.enablePersistence&&this.setProperties({width:parseFloat(this.element.style.width),height:parseFloat(this.element.style.height),position:{X:parseFloat(this.dragObj.element.style.left),Y:parseFloat(this.dragObj.element.style.top)}},!0)},t.prototype.isNumberValue=function(e){return/^[-+]?\d*\.?\d+$/.test(e)},t.prototype.checkPositionData=function(){if(!m(this.position)){if(!m(this.position.X)&&"number"!=typeof this.position.X&&this.isNumberValue(this.position.X)){var i=this.isProtectedOnChange;this.isProtectedOnChange=!0,this.position.X=parseFloat(this.position.X),this.isProtectedOnChange=i}m(this.position.Y)||"number"==typeof this.position.Y||this.isNumberValue(this.position.Y)&&(i=this.isProtectedOnChange,this.isProtectedOnChange=!0,this.position.Y=parseFloat(this.position.Y),this.isProtectedOnChange=i)}},t.prototype.getEle=function(e,i){for(var r=void 0,s=0;s=0&&t[e])vJ(t[e]);else if(""!==t[e].trim()){var i=mi("div",{className:"e-icons "+jg+" e-"+t[e]});_i.appendChild(i)}ap=n.minHeight,bE=n.minWidth,gh=n.maxWidth,fh=n.maxHeight,n.proxy&&n.proxy.element&&n.proxy.element.classList.contains("e-dialog")?u4(n.proxy):u4()}({element:this.element,direction:r,minHeight:parseInt(e.slice(0,i.indexOf("p")),10),maxHeight:this.targetEle.clientHeight,minWidth:parseInt(i.slice(0,i.indexOf("p")),10),maxWidth:this.targetEle.clientWidth,boundary:this.target===document.body?null:this.targetEle,resizeBegin:this.onResizeStart.bind(this),resizeComplete:this.onResizeComplete.bind(this),resizing:this.onResizing.bind(this),proxy:this}),this.wireWindowResizeEvent()}else v4(),this.unWireWindowResizeEvent(),this.element.classList.remove(this.isModal?lp:D4),this.element.classList.remove(kE)},t.prototype.getFocusElement=function(e){var r=e.querySelectorAll('input,select,textarea,button:enabled,a,[contenteditable="true"],[tabindex]');return{element:r[r.length-1]}},t.prototype.keyDown=function(e){var i=this;if(9===e.keyCode&&this.isModal){var r=void 0;m(this.btnObj)||(r=this.btnObj[this.btnObj.length-1]),m(this.btnObj)&&!m(this.ftrTemplateContent)&&(r=this.getFocusElement(this.ftrTemplateContent)),m(this.btnObj)&&m(this.ftrTemplateContent)&&!m(this.contentEle)&&(r=this.getFocusElement(this.contentEle)),!m(r)&&document.activeElement===r.element&&!e.shiftKey&&(e.preventDefault(),this.focusableElements(this.element).focus()),document.activeElement===this.focusableElements(this.element)&&e.shiftKey&&(e.preventDefault(),m(r)||r.element.focus())}var h,s=document.activeElement,o=["input","textarea"].indexOf(s.tagName.toLowerCase())>-1,a=!1;if(o||(a=s.hasAttribute("contenteditable")&&"true"===s.getAttribute("contenteditable")),27===e.keyCode&&this.closeOnEscape){this.dlgClosedBy="escape";var l=document.querySelector(".e-popup-open:not(.e-dialog)");!m(l)&&!l.classList.contains("e-toolbar-pop")||this.hide(e)}(13===e.keyCode&&!e.ctrlKey&&"textarea"!==s.tagName.toLowerCase()&&o&&!m(this.primaryButtonEle)||13===e.keyCode&&e.ctrlKey&&("textarea"===s.tagName.toLowerCase()||a)&&!m(this.primaryButtonEle))&&this.buttons.some(function(d,u){h=u;var p=d.buttonModel;return!m(p)&&!0===p.isPrimary})&&"function"==typeof this.buttons[h].click&&setTimeout(function(){i.buttons[h].click.call(i,e)})},t.prototype.initialize=function(){m(this.target)||(this.targetEle="string"==typeof this.target?document.querySelector(this.target):this.target),this.isBlazorServerRender()||V([this.element],U0),X.isDevice&&V([this.element],S4),this.isBlazorServerRender()||this.setCSSClass(),this.setMaxHeight()},t.prototype.initRender=function(){var e=this;if(this.initialRender=!0,this.isBlazorServerRender()||Fe(this.element,{role:"dialog"}),1e3===this.zIndex?(this.setzIndex(this.element,!1),this.calculatezIndex=!0):this.calculatezIndex=!1,this.setTargetContent(),""!==this.header&&!m(this.header)&&this.setHeader(),this.renderCloseIcon(),this.setContent(),""===this.footerTemplate||m(this.footerTemplate)?!m(this.buttons[0])&&!m(this.buttons[0].buttonModel)&&this.setButton():this.setFooterTemplate(),this.allowDragging&&!m(this.headerContent)&&this.setAllowDragging(),Fe(this.element,{"aria-modal":this.isModal?"true":"false"}),this.isModal&&this.setIsModal(),!0!==this.element.classList.contains(C4)&&!0!==this.element.classList.contains(E4)&&!m(this.element.parentElement)){var i=this.isModal?this.dlgContainer.parentElement:this.element.parentElement;this.refElement=this.createElement("div",{className:"e-dlg-ref-element"}),i.insertBefore(this.refElement,this.isModal?this.dlgContainer:this.element)}if(m(this.targetEle)||this.targetEle.appendChild(this.isModal?this.dlgContainer:this.element),this.popupObj=new ac(this.element,{height:this.height,width:this.width,zIndex:this.zIndex,relateTo:this.target,actionOnScroll:"none",enableRtl:this.enableRtl,open:function(o){var a={container:e.isModal?e.dlgContainer:e.element,element:e.element,target:e.target,preventFocus:!1};e.enableResize&&e.resetResizeIcon(),e.trigger("open",a,function(l){l.preventFocus||e.focusContent()})},close:function(o){e.isModal&&V([e.dlgOverlay],"e-fade"),e.unBindEvent(e.element),e.isModal&&(e.dlgContainer.style.display="none"),e.trigger("close",e.closeArgs);var a=document.activeElement;!m(a)&&!m(a.blur)&&a.blur(),!m(e.storeActiveElement)&&!m(e.storeActiveElement.focus)&&e.storeActiveElement.focus()}}),this.positionChange(),this.setEnableRTL(),this.isBlazorServerRender()||(V([this.element],"e-popup-close"),this.isModal&&this.setOverlayZindex()),this.visible){if(this.show(),this.isModal){var r=this.getTargetContainer(this.target);r instanceof Element&&"rtl"===window.getComputedStyle(r).getPropertyValue("direction")&&this.setPopupPosition()}}else this.isModal&&(this.dlgOverlay.style.display="none");this.initialRender=!1},t.prototype.getTargetContainer=function(e){var i=null;if("string"==typeof e)if(e.startsWith("#"))i=document.getElementById(e.substring(1));else if(e.startsWith(".")){var r=document.getElementsByClassName(e.substring(1));i=r.length>0?r[0]:null}else!(e instanceof HTMLElement)&&e!==document.body&&(i=document.querySelector(e));else e instanceof HTMLElement&&(i=e);return i},t.prototype.resetResizeIcon=function(){var e=this.getMinHeight();if(this.targetEle.offsetHeight0&&("function"==typeof this.buttons[e].click&&E.add(s[e],"click",this.buttons[e].click,this),"object"==typeof this.buttons[e].click&&E.add(s[e],"click",this.buttonClickHandler.bind(this,e),this)),!this.isBlazorServerRender()&&!m(this.ftrTemplateContent)&&(this.btnObj[e].appendTo(this.ftrTemplateContent.children[e]),this.buttons[e].isFlat&&this.btnObj[e].element.classList.add("e-flat"),this.primaryButtonEle=this.element.getElementsByClassName("e-primary")[0]))},t.prototype.buttonClickHandler=function(e){this.trigger("buttons["+e+"].click",{})},t.prototype.setContent=function(){this.contentEle=this.createElement("div",{className:"e-dlg-content",id:this.element.id+"_dialog-content"}),Fe(this.element,this.headerEle?{"aria-describedby":this.element.id+"_title "+this.element.id+"_dialog-content"}:{"aria-describedby":this.element.id+"_dialog-content"}),this.innerContentElement?this.contentEle.appendChild(this.innerContentElement):(!m(this.content)&&""!==this.content||!this.initialRender)&&(("string"!=typeof this.content||ce())&&this.content instanceof HTMLElement?this.contentEle.appendChild(this.content):this.setTemplate(this.content,this.contentEle,"content")),m(this.headerContent)?this.element.insertBefore(this.contentEle,this.element.children[0]):this.element.insertBefore(this.contentEle,this.element.children[1]),"auto"===this.height&&(!this.isBlazorServerRender()&&X.isIE&&""===this.element.style.width&&!m(this.width)&&(this.element.style.width=Re(this.width)),this.setMaxHeight())},t.prototype.setTemplate=function(e,i,r){var s,o,a;o=i.classList.contains(m4)?this.element.id+"header":i.classList.contains(j0)?this.element.id+"footerTemplate":this.element.id+"content",m(e.outerHTML)?("string"==typeof e||"string"!=typeof e||ce()&&!this.isStringTemplate)&&("string"==typeof e&&(e=this.sanitizeHelper(e)),this.isVue||"string"!=typeof e?(s=ri(e),a=e):i.innerHTML=e):i.appendChild(e);var l=[];if(!m(s)){for(var c=0,d=s({},this,r,o,!(ce()&&!this.isStringTemplate&&0===a.indexOf("
Blazor"))||this.isStringTemplate);c/g,"");(this.element.children.length>0||i)&&(this.innerContentElement=document.createDocumentFragment(),[].slice.call(this.element.childNodes).forEach(function(r){8!==r.nodeType&&e.innerContentElement.appendChild(r)}))}},t.prototype.setHeader=function(){this.headerEle?this.headerEle.innerHTML="":this.headerEle=this.createElement("div",{id:this.element.id+"_title",className:m4}),this.createHeaderContent(),this.headerContent.appendChild(this.headerEle),this.setTemplate(this.header,this.headerEle,"header"),Fe(this.element,{"aria-describedby":this.element.id+"_title"}),Fe(this.element,{"aria-labelledby":this.element.id+"_dialog-header"}),this.element.insertBefore(this.headerContent,this.element.children[0]),this.allowDragging&&!m(this.headerContent)&&this.setAllowDragging()},t.prototype.setFooterTemplate=function(){this.ftrTemplateContent?this.ftrTemplateContent.innerHTML="":this.ftrTemplateContent=this.createElement("div",{className:j0}),""===this.footerTemplate||m(this.footerTemplate)?this.ftrTemplateContent.innerHTML=this.buttonContent.join(""):this.setTemplate(this.footerTemplate,this.ftrTemplateContent,"footerTemplate"),this.element.appendChild(this.ftrTemplateContent)},t.prototype.createHeaderContent=function(){m(this.headerContent)&&(this.headerContent=this.createElement("div",{id:this.element.id+"_dialog-header",className:OE}))},t.prototype.renderCloseIcon=function(){this.showCloseIcon&&(this.closeIcon=this.createElement("button",{className:I4,attrs:{type:"button"}}),this.closeIconBtnObj=new ys({cssClass:"e-flat",iconCss:y4+" e-icons"}),this.closeIconTitle(),m(this.headerContent)?(this.createHeaderContent(),pl([this.closeIcon],this.headerContent),this.element.insertBefore(this.headerContent,this.element.children[0])):pl([this.closeIcon],this.headerContent),this.closeIconBtnObj.appendTo(this.closeIcon))},t.prototype.closeIconTitle=function(){this.l10n.setLocale(this.locale);var e=this.l10n.getConstant("close");this.closeIcon.setAttribute("title",e),this.closeIcon.setAttribute("aria-label",e)},t.prototype.setCSSClass=function(e){e&&(K([this.element],e.split(" ")),this.isModal&&!m(this.dlgContainer)&&K([this.dlgContainer],e.split(" "))),this.cssClass&&(V([this.element],this.cssClass.split(" ")),this.isModal&&!m(this.dlgContainer)&&V([this.dlgContainer],this.cssClass.split(" ")))},t.prototype.setIsModal=function(){this.dlgContainer=this.createElement("div",{className:"e-dlg-container"}),this.setCSSClass(),this.element.classList.remove(b4),this.element.parentNode.insertBefore(this.dlgContainer,this.element),this.dlgContainer.appendChild(this.element),V([this.element],V0),this.dlgOverlay=this.createElement("div",{className:"e-dlg-overlay"}),this.dlgOverlay.style.zIndex=(this.zIndex-1).toString(),this.dlgContainer.appendChild(this.dlgOverlay)},t.prototype.getValidFocusNode=function(e){for(var i,r=0;r0||"a"===i.tagName.toLowerCase()&&i.hasAttribute("href"))&&i.tabIndex>-1&&!i.disabled&&!this.disableElement(i,'[disabled],[aria-disabled="true"],[type="hidden"]'))return i;i=null}return i},t.prototype.focusableElements=function(e){if(!m(e)){var r=e.querySelectorAll('input,select,textarea,button,a,[contenteditable="true"],[tabindex]');return this.getValidFocusNode(r)}return null},t.prototype.getAutoFocusNode=function(e){var i=e.querySelector("."+I4),s=e.querySelectorAll("[autofocus]"),o=this.getValidFocusNode(s);if(ce()&&(this.primaryButtonEle=this.element.getElementsByClassName("e-primary")[0]),m(o)){if(!m(o=this.focusableElements(this.contentEle)))return o;if(!m(this.primaryButtonEle))return this.element.querySelector(".e-primary")}else i=o;return i},t.prototype.disableElement=function(e,i){var r=e?e.matches||e.webkitMatchesSelector||e.msGetRegionContent:null;if(r)for(;e;e=e.parentNode)if(e instanceof Element&&r.call(e,i))return e;return null},t.prototype.focusContent=function(){var e=this.getAutoFocusNode(this.element),i=m(e)?this.element:e,r=X.userAgent;(r.indexOf("MSIE ")>0||r.indexOf("Trident/")>0)&&this.element.focus(),i.focus(),this.unBindEvent(this.element),this.bindEvent(this.element)},t.prototype.bindEvent=function(e){E.add(e,"keydown",this.keyDown,this)},t.prototype.unBindEvent=function(e){E.remove(e,"keydown",this.keyDown)},t.prototype.updateSanitizeContent=function(){this.isBlazorServerRender()||(this.contentEle.innerHTML=this.sanitizeHelper(this.content))},t.prototype.isBlazorServerRender=function(){return ce()&&this.isServerRendered},t.prototype.getModuleName=function(){return"dialog"},t.prototype.onPropertyChanged=function(e,i){if(this.element.classList.contains(U0))for(var r=0,s=Object.keys(e);r0?this.showCloseIcon||""!==this.header&&!m(this.header)?this.showCloseIcon||he(this.closeIcon):(he(this.headerContent),this.headerContent=null):(this.renderCloseIcon(),this.wireEvents());break;case"locale":this.showCloseIcon&&this.closeIconTitle();break;case"visible":this.visible?this.show():this.hide();break;case"isModal":this.updateIsModal();break;case"height":je(this.element,{height:Re(e.height)}),this.updatePersistData();break;case"width":je(this.element,{width:Re(e.width)}),this.updatePersistData();break;case"zIndex":this.popupObj.zIndex=this.zIndex,this.isModal&&this.setOverlayZindex(this.zIndex),this.element.style.zIndex!==this.zIndex.toString()&&(this.calculatezIndex=!1);break;case"cssClass":this.setCSSClass(i.cssClass);break;case"buttons":this.unWireButtonEvents(),this.destroyButtons(),m(this.ftrTemplateContent)||(he(this.ftrTemplateContent),this.ftrTemplateContent=null),this.footerTemplate="",this.setButton();break;case"allowDragging":this.allowDragging&&!m(this.headerContent)?this.setAllowDragging():this.dragObj.destroy();break;case"target":this.setTarget(e.target);break;case"position":if(this.checkPositionData(),this.isModal){var a=this.position.X,l=this.position.Y;m(i.position)||(m(i.position.X)||(a=i.position.X),m(i.position.Y)||(l=i.position.Y)),this.dlgContainer.classList.contains("e-dlg-"+a+"-"+l)&&this.dlgContainer.classList.remove("e-dlg-"+a+"-"+l)}this.positionChange(),this.updatePersistData();break;case"enableRtl":this.setEnableRTL();break;case"enableResize":this.setResize();break;case"minHeight":""!==this.minHeight&&(this.element.style.minHeight=Re(this.minHeight))}},t.prototype.setTarget=function(e){this.popupObj.relateTo=e,this.target=e,this.targetEle="string"==typeof this.target?document.querySelector(this.target):this.target,this.dragObj&&(this.dragObj.dragArea=this.targetEle),this.setMaxHeight(),this.isModal&&this.updateIsModal(),this.enableResize&&this.setResize()},t.prototype.updateIsModal=function(){if(this.element.setAttribute("aria-modal",this.isModal?"true":"false"),this.isModal)m(this.dlgOverlay)&&(this.setIsModal(),this.element.style.top="0px",this.element.style.left="0px",m(this.targetEle)||this.targetEle.appendChild(this.dlgContainer));else{for(K([this.element],V0),K([document.body],[ml,ka]),he(this.dlgOverlay);this.dlgContainer.firstChild;)this.dlgContainer.parentElement.insertBefore(this.dlgContainer.firstChild,this.dlgContainer);this.dlgContainer.parentElement.removeChild(this.dlgContainer)}this.visible&&this.show(),this.positionChange(),this.isModal&&this.dlgOverlay&&E.add(this.dlgOverlay,"click",this.dlgOverlayClickEventHandler,this)},t.prototype.setzIndex=function(e,i){var r=this.isProtectedOnChange;this.isProtectedOnChange=!0;var s=lc(e);this.zIndex=s>this.zIndex?s:this.zIndex,this.isProtectedOnChange=r,i&&(this.popupObj.zIndex=this.zIndex)},t.prototype.windowResizeHandler=function(){(function yJ(n){gh=n})(this.targetEle.clientWidth),function SJ(n){fh=n}(this.targetEle.clientHeight),this.setMaxHeight()},t.prototype.getPersistData=function(){return this.addOnPersist(["width","height","position"])},t.prototype.removeAllChildren=function(e){for(;e.children[0];)this.removeAllChildren(e.children[0]),e.removeChild(e.children[0])},t.prototype.destroy=function(){if(!this.isDestroyed){var e=[NE,V0,kE,lp,W0,S4],i=["role","aria-modal","aria-labelledby","aria-describedby","aria-grabbed","tabindex","style"];K([this.targetEle],[ml,ka]),!m(this.element)&&this.element.classList.contains(W0)&&K([document.body],[ml,ka]),this.isModal&&K([m(this.targetEle)?document.body:this.targetEle],ka),this.unWireEvents(),this.unWireButtonEvents(),this.destroyButtons(),m(this.closeIconBtnObj)||this.closeIconBtnObj.destroy(),m(this.dragObj)||this.dragObj.destroy(),!m(this.popupObj.element)&&this.popupObj.element.classList.contains("e-popup")&&this.popupObj.destroy(),K([this.element],e),!m(this.cssClass)&&""!==this.cssClass&&K([this.element],this.cssClass.split(" ")),!m(this.refElement)&&!m(this.refElement.parentElement)&&(this.refElement.parentElement.insertBefore(this.isModal?this.dlgContainer:this.element,this.refElement),he(this.refElement),this.refElement=void 0),this.isModal&&(he(this.dlgOverlay),this.dlgContainer.parentNode.insertBefore(this.element,this.dlgContainer),he(this.dlgContainer)),this.element.innerHTML=this.clonedEle.innerHTML;for(var r=0;r0&&""===this.footerTemplate&&this.ftrTemplateContent)for(var e=0;e=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},zE="e-tooltip",O4="e-icons",k4="e-tooltip-close",RE="e-tooltip-wrap",P4="e-tip-content",hp="e-arrow-tip",z4="e-arrow-tip-outer",Y0="e-arrow-tip-inner",Gg="e-tip-bottom",HE="e-tip-top",R4="e-tip-left",BE="e-tip-right",FE="e-popup",Xg="e-popup-open",_E="e-popup-close",Q0="e-lib",H4="e-tooltip-popup-container",UJ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return T4(t,n),Gi([I({effect:"FadeIn",duration:150,delay:0})],t.prototype,"open",void 0),Gi([I({effect:"FadeOut",duration:150,delay:0})],t.prototype,"close",void 0),t}(Ee),mh=function(n){function t(e,i){var r=n.call(this,e,i)||this;return r.mouseMoveEvent=null,r.mouseMoveTarget=null,r.containerElement=null,r.isBodyContainer=!0,r}return T4(t,n),t.prototype.initialize=function(){this.formatPosition(),V([this.element],zE)},t.prototype.formatPosition=function(){var e,i;this.position&&(0===this.position.indexOf("Top")||0===this.position.indexOf("Bottom")?(e=this.position.split(/(?=[A-Z])/),this.tooltipPositionY=e[0],this.tooltipPositionX=e[1]):(i=this.position.split(/(?=[A-Z])/),this.tooltipPositionX=i[0],this.tooltipPositionY=i[1]))},t.prototype.renderArrow=function(){this.setTipClass(this.position);var e=this.createElement("div",{className:hp+" "+this.tipClass});e.appendChild(this.createElement("div",{className:z4+" "+this.tipClass})),e.appendChild(this.createElement("div",{className:Y0+" "+this.tipClass})),this.tooltipEle.appendChild(e)},t.prototype.setTipClass=function(e){this.tipClass=0===e.indexOf("Right")?R4:0===e.indexOf("Bottom")?HE:0===e.indexOf("Left")?BE:Gg},t.prototype.renderPopup=function(e){var i=this.mouseTrail?{top:0,left:0}:this.getTooltipPosition(e);this.tooltipEle.classList.remove(Q0),this.popupObj=new ac(this.tooltipEle,{height:this.height,width:this.width,position:{X:i.left,Y:i.top},enableRtl:this.enableRtl,open:this.openPopupHandler.bind(this),close:this.closePopupHandler.bind(this)})},t.prototype.getScalingFactor=function(e){if(!e)return{x:1,y:1};var i={x:1,y:1},r=e.closest('[style*="transform: scale"]');if(r&&r!==this.tooltipEle&&r.contains(this.tooltipEle)){var a=window.getComputedStyle(r).getPropertyValue("transform").match(/matrix\(([^)]+)\)/)[1].split(",").map(parseFloat);i.x=a[0],i.y=a[3]}return i},t.prototype.getTooltipPosition=function(e){this.tooltipEle.style.display="block";var i=this.element.closest('[style*="zoom"]');i&&(i.contains(this.tooltipEle)||(this.tooltipEle.style.zoom=getComputedStyle(i).zoom));var r=is(e,this.tooltipPositionX,this.tooltipPositionY,!this.isBodyContainer,this.isBodyContainer?null:this.containerElement.getBoundingClientRect()),s=this.getScalingFactor(e),o=this.calculateTooltipOffset(this.position,s.x,s.y),a=this.calculateElementPosition(r,o),c=this.collisionFlipFit(e,a[0],a[1]);return c.left=c.left/s.x,c.top=c.top/s.y,this.tooltipEle.style.display="",c},t.prototype.windowResize=function(){this.reposition(this.findTarget())},t.prototype.reposition=function(e){if(this.popupObj&&e){var i=this.getTooltipPosition(e);this.popupObj.position={X:i.left,Y:i.top},this.popupObj.dataBind()}},t.prototype.openPopupHandler=function(){!this.mouseTrail&&this.needTemplateReposition()&&this.reposition(this.findTarget()),this.trigger("afterOpen",this.tooltipEventArgs),this.tooltipEventArgs=null},t.prototype.closePopupHandler=function(){this.isReact&&!("Click"===this.opensOn||"function"==typeof this.content)&&this.clearTemplate(["content"]),this.clear();var e={type:this.tooltipEventArgs.event?this.tooltipEventArgs.event.type:null,cancel:!1,target:this.tooltipEventArgs.target,event:this.tooltipEventArgs.event?this.tooltipEventArgs.event:null,element:this.tooltipEle,isInteracted:!m(this.tooltipEventArgs.event)};this.trigger("afterClose",e),e=null},t.prototype.calculateTooltipOffset=function(e,i,r){void 0===i&&(i=1),void 0===r&&(r=1);var o,a,l,h,c,d,u,p,s={top:0,left:0};if(1!==i||1!==r){var f=this.tooltipEle.getBoundingClientRect(),g=void 0;l=Math.round(f.width),h=Math.round(f.height),(c=U("."+hp,this.tooltipEle))&&(g=c.getBoundingClientRect()),o=c?Math.round(g.width):0,a=c?Math.round(g.height):0,d=this.showTipPointer?0:8,u=a/2+2+(h-this.tooltipEle.clientHeight*r),p=o/2+2+(l-this.tooltipEle.clientWidth*i)}else l=this.tooltipEle.offsetWidth,h=this.tooltipEle.offsetHeight,c=U("."+hp,this.tooltipEle),d=this.showTipPointer?0:8,u=(a=c?c.offsetHeight:0)/2+2+(this.tooltipEle.offsetHeight-this.tooltipEle.clientHeight),p=(o=c?c.offsetWidth:0)/2+2+(this.tooltipEle.offsetWidth-this.tooltipEle.clientWidth);switch(this.mouseTrail&&(d+=2),e){case"RightTop":s.left+=o+d,s.top-=h-u;break;case"RightCenter":s.left+=o+d,s.top-=h/2;break;case"RightBottom":s.left+=o+d,s.top-=u;break;case"BottomRight":s.top+=a+d,s.left-=p;break;case"BottomCenter":s.top+=a+d,s.left-=l/2;break;case"BottomLeft":s.top+=a+d,s.left-=l-p;break;case"LeftBottom":s.left-=o+l+d,s.top-=u;break;case"LeftCenter":s.left-=o+l+d,s.top-=h/2;break;case"LeftTop":s.left-=o+l+d,s.top-=h-u;break;case"TopLeft":s.top-=h+a+d,s.left-=l-p;break;case"TopRight":s.top-=h+a+d,s.left-=p;break;default:s.top-=h+a+d,s.left-=l/2}return s.left+=this.offsetX,s.top+=this.offsetY,s},t.prototype.updateTipPosition=function(e){var i=we("."+hp+",."+z4+",."+Y0,this.tooltipEle);K(i,[Gg,HE,R4,BE]),this.setTipClass(e),V(i,this.tipClass)},t.prototype.adjustArrow=function(e,i,r,s){var o=U("."+hp,this.tooltipEle);if(!1!==this.showTipPointer&&null!==o){var a,l;this.updateTipPosition(i),this.tooltipEle.style.display="block";var f,h=this.tooltipEle.clientWidth,c=this.tooltipEle.clientHeight,d=U("."+Y0,this.tooltipEle),u=o.offsetWidth,p=o.offsetHeight;this.tooltipEle.style.display="",this.tipClass===Gg||this.tipClass===HE?(this.tipClass===Gg?(l="99.9%",d.style.top="-"+(p-2)+"px"):(l=-(p-1)+"px",d.style.top="-"+(p-6)+"px"),e&&(a=(f="Center"!==r||h>e.offsetWidth||this.mouseTrail)&&"Left"===r||!f&&"End"===this.tipPointerPosition?h-u-2+"px":f&&"Right"===r||!f&&"Start"===this.tipPointerPosition?"2px":!f||"End"!==this.tipPointerPosition&&"Start"!==this.tipPointerPosition?h/2-u/2+"px":"End"===this.tipPointerPosition?e.offsetWidth+(this.tooltipEle.offsetWidth-e.offsetWidth)/2-u/2-2+"px":(this.tooltipEle.offsetWidth-e.offsetWidth)/2-u/2+2+"px")):(this.tipClass===BE?(a="99.9%",d.style.left="-"+(u-2)+"px"):(a=-(u-1)+"px",d.style.left=u-2-u+"px"),l=(f="Center"!==s||c>e.offsetHeight||this.mouseTrail)&&"Top"===s||!f&&"End"===this.tipPointerPosition?c-p-2+"px":f&&"Bottom"===s||!f&&"Start"===this.tipPointerPosition?"2px":c/2-p/2+"px"),o.style.top=l,o.style.left=a}},t.prototype.renderContent=function(e){var i=this,r=U("."+P4,this.tooltipEle);if(this.cssClass&&V([this.tooltipEle],this.cssClass.split(" ")),e&&!m(e.getAttribute("title"))&&(e.setAttribute("data-content",e.getAttribute("title")),e.removeAttribute("title")),m(this.content))e&&!m(e.getAttribute("data-content"))&&(r.innerHTML=e.getAttribute("data-content"));else if(r.innerHTML="",this.content instanceof HTMLElement)r.appendChild(this.content);else if("string"==typeof this.content)this.isAngular?this.setProperties({content:Ti.sanitize(this.content)},!0):this.content=this.enableHtmlSanitizer?Ti.sanitize(this.content):this.content,this.enableHtmlParse?(o=ri(this.content)({},this,"content",this.element.id+"content",void 0,void 0,r,this.root))&&Dt(o,r):r.textContent=this.content;else{var o;(o=ri(this.content)({},this,"content",this.element.id+"content",void 0,void 0,r))&&(this.isAngular&&setTimeout(function(){i.reposition(e)},1),Dt(o,r)),this.renderReactTemplates()}},t.prototype.renderCloseIcon=function(){if(this.isSticky){var i=this.createElement("div",{className:O4+" "+k4});this.tooltipEle.appendChild(i),E.add(i,X.touchStartEvent,this.onStickyClose,this)}else{var e=this.tooltipEle.querySelector("."+O4+"."+k4);e&>(e)}},t.prototype.addDescribedBy=function(e,i){var r=(e.getAttribute("aria-describedby")||"").split(/\s+/);r.indexOf(i)<0&&r.push(i),Fe(e,{"aria-describedby":r.join(" ").trim(),"data-tooltip-id":i})},t.prototype.removeDescribedBy=function(e){var i=e.getAttribute("data-tooltip-id"),r=(e.getAttribute("aria-describedby")||"").split(/\s+/),s=r.indexOf(i);-1!==s&&r.splice(s,1),e.removeAttribute("data-tooltip-id");var o=r.join(" ").trim();o?e.setAttribute("aria-describedby",o):e.removeAttribute("aria-describedby")},t.prototype.tapHoldHandler=function(e){clearTimeout(this.autoCloseTimer),this.targetHover(e.originalEvent)},t.prototype.touchEndHandler=function(){var e=this;this.isSticky||(this.autoCloseTimer=setTimeout(function(){e.close()},1500))},t.prototype.targetClick=function(e){var i;!m(i=this.target?J(e.target,this.target):this.element)&&(null===i.getAttribute("data-tooltip-id")?this.targetHover(e):this.isSticky||this.hideTooltip(this.animation.close,e,i))},t.prototype.targetHover=function(e){var i;if(!(m(i=this.target?J(e.target,this.target):this.element)||null!==i.getAttribute("data-tooltip-id")&&0===this.closeDelay)){for(var s=0,o=[].slice.call(we('[data-tooltip-id= "'+this.ctrlId+'_content"]',document));s0?this.showTimer=setTimeout(function(){o.mouseTrail&&E.add(i,"mousemove touchstart mouseenter",o.onMouseMove,o),o.popupObj&&(o.popupObj.show(a,i),o.mouseMoveEvent&&o.mouseTrail&&o.onMouseMove(o.mouseMoveEvent))},this.openDelay):this.popupObj&&this.popupObj.show(a,i)}s&&this.wireMouseEvents(s,i)},t.prototype.needTemplateReposition=function(){return!m(this.viewContainerRef)&&"string"!=typeof this.viewContainerRef||this.isReact},t.prototype.checkCollision=function(e,i,r){var s={left:i,top:r,position:this.position,horizontal:this.tooltipPositionX,vertical:this.tooltipPositionY},o=oc(this.tooltipEle,this.checkCollideTarget(),i,r);return o.length>0&&(s.horizontal=o.indexOf("left")>=0?"Right":o.indexOf("right")>=0?"Left":this.tooltipPositionX,s.vertical=o.indexOf("top")>=0?"Bottom":o.indexOf("bottom")>=0?"Top":this.tooltipPositionY),s},t.prototype.calculateElementPosition=function(e,i){return[this.isBodyContainer?e.left+i.left:e.left-this.containerElement.getBoundingClientRect().left+i.left+window.pageXOffset+this.containerElement.scrollLeft,this.isBodyContainer?e.top+i.top:e.top-this.containerElement.getBoundingClientRect().top+i.top+window.pageYOffset+this.containerElement.scrollTop]},t.prototype.collisionFlipFit=function(e,i,r){var s=this.checkCollision(e,i,r),o=s.position;if(this.tooltipPositionY!==s.vertical&&(o=0===this.position.indexOf("Bottom")||0===this.position.indexOf("Top")?s.vertical+this.tooltipPositionX:this.tooltipPositionX+s.vertical),this.tooltipPositionX!==s.horizontal&&(0===o.indexOf("Left")&&(s.vertical="LeftTop"===o||"LeftCenter"===o?"Top":"Bottom",o=s.vertical+"Left"),0===o.indexOf("Right")&&(s.vertical="RightTop"===o||"RightCenter"===o?"Top":"Bottom",o=s.vertical+"Right"),s.horizontal=this.tooltipPositionX),this.tooltipEventArgs={type:null,cancel:!1,target:e,event:null,element:this.tooltipEle,collidedPosition:o},this.trigger("beforeCollision",this.tooltipEventArgs),this.tooltipEventArgs.cancel)o=this.position;else{var a=s.vertical,l=s.horizontal;if(s.position!==o){var h=is(e,l,a,!this.isBodyContainer,this.isBodyContainer?null:this.containerElement.getBoundingClientRect());this.adjustArrow(e,o,l,a);var c=this.getScalingFactor(e),d=this.calculateTooltipOffset(o,c.x,c.y);d.top-=this.getOffSetPosition("TopBottom",o,this.offsetY),d.left-=this.getOffSetPosition("RightLeft",o,this.offsetX),s.position=o;var u=this.calculateElementPosition(h,d);s.left=u[0],s.top=u[1]}else this.adjustArrow(e,o,l,a)}var p={left:s.left,top:s.top},f=this.isBodyContainer?hE(this.tooltipEle,this.checkCollideTarget(),{X:!0,Y:this.windowCollision},p):p;this.tooltipEle.style.display="block";var g=U("."+hp,this.tooltipEle);if(this.showTipPointer&&null!=g&&(0===o.indexOf("Bottom")||0===o.indexOf("Top"))){var v=parseInt(g.style.left,10)-(f.left-s.left);v<0?v=0:v+g.offsetWidth>this.tooltipEle.clientWidth&&(v=this.tooltipEle.clientWidth-g.offsetWidth),g.style.left=v.toString()+"px"}return this.tooltipEle.style.display="",p.left=f.left,p.top=f.top,p},t.prototype.getOffSetPosition=function(e,i,r){return-1!==e.indexOf(this.position.split(/(?=[A-Z])/)[0])&&-1!==e.indexOf(i.split(/(?=[A-Z])/)[0])?2*r:0},t.prototype.checkCollideTarget=function(){return!this.windowCollision&&this.target?this.element:null},t.prototype.hideTooltip=function(e,i,r){var s=this;this.closeDelay>0?(clearTimeout(this.hideTimer),clearTimeout(this.showTimer),this.hideTimer=setTimeout(function(){s.closeDelay&&s.tooltipEle&&s.isTooltipOpen||s.tooltipHide(e,i,r)},this.closeDelay)):this.tooltipHide(e,i,r)},t.prototype.tooltipHide=function(e,i,r){var o,s=this;o=i?this.target?r||i.target:this.element:U('[data-tooltip-id= "'+this.ctrlId+'_content"]',document),this.tooltipEventArgs={type:i?i.type:null,cancel:!1,target:o,event:i||null,element:this.tooltipEle,isInteracted:!m(i)},this.trigger("beforeClose",this.tooltipEventArgs,function(a){a.cancel?s.isHidden=!1:(s.mouseMoveBeforeRemove(),s.popupHide(e,o,i))})},t.prototype.popupHide=function(e,i,r){i&&r&&this.restoreElement(i),this.isHidden=!0;var s={name:this.animation.close.effect,duration:e.duration,delay:e.delay,timingFunction:"easeIn"};"None"===e.effect&&(s=void 0),this.popupObj&&this.popupObj.hide(s)},t.prototype.restoreElement=function(e){this.unwireMouseEvents(e),m(e.getAttribute("data-content"))||(e.setAttribute("title",e.getAttribute("data-content")),e.removeAttribute("data-content")),this.removeDescribedBy(e)},t.prototype.clear=function(){var e=this.findTarget();e&&this.restoreElement(e),this.tooltipEle&&(K([this.tooltipEle],_E),V([this.tooltipEle],Xg)),this.isHidden&&(this.popupObj&&this.popupObj.destroy(),this.tooltipEle&>(this.tooltipEle),this.tooltipEle=null,this.popupObj=null)},t.prototype.tooltipHover=function(){this.tooltipEle&&(this.isTooltipOpen=!0)},t.prototype.tooltipMouseOut=function(e){this.isTooltipOpen=!1,this.hideTooltip(this.animation.close,e,this.findTarget())},t.prototype.onMouseOut=function(e){var i=e.relatedTarget;if(i&&!this.mouseTrail){var r=J(i,"."+RE+"."+Q0+"."+FE);r?E.add(r,"mouseleave",this.tooltipElementMouseOut,this):(this.hideTooltip(this.animation.close,e,this.findTarget()),0===this.closeDelay&&("None"===this.animation.close.effect||this.isReact&&"string"!=typeof this.content)&&this.clear())}else this.hideTooltip(this.animation.close,e,this.findTarget()),this.clear();this.popupObj&&!this.popupObj.element.classList.contains(Xg)&&this.clear()},t.prototype.tooltipElementMouseOut=function(e){this.hideTooltip(this.animation.close,e,this.findTarget()),E.remove(this.element,"mouseleave",this.tooltipElementMouseOut),this.clear()},t.prototype.onStickyClose=function(){this.close()},t.prototype.onMouseMove=function(e){var i=0,r=0;e.type.indexOf("touch")>-1?(e.preventDefault(),i=e.touches[0].pageX,r=e.touches[0].pageY):(i=e.pageX,r=e.pageY),Hs.stop(this.tooltipEle),K([this.tooltipEle],_E),V([this.tooltipEle],Xg),this.adjustArrow(e.target,this.position,this.tooltipPositionX,this.tooltipPositionY);var s=this.getScalingFactor(e.target),o=this.calculateTooltipOffset(this.position,s.x,s.y),h=this.checkCollision(e.target,i+o.left+this.offsetX,r+o.top+this.offsetY);if(this.tooltipPositionX!==h.horizontal||this.tooltipPositionY!==h.vertical){var c=0===this.position.indexOf("Bottom")||0===this.position.indexOf("Top")?h.vertical+h.horizontal:h.horizontal+h.vertical;h.position=c,this.adjustArrow(e.target,h.position,h.horizontal,h.vertical);var d=this.calculateTooltipOffset(h.position,s.x,s.y);h.left=i+d.left-this.offsetX,h.top=r+d.top-this.offsetY}this.tooltipEle.style.left=h.left+"px",this.tooltipEle.style.top=h.top+"px"},t.prototype.keyDown=function(e){this.tooltipEle&&27===e.keyCode&&this.close()},t.prototype.touchEnd=function(e){this.tooltipEle&&null===J(e.target,"."+zE)&&!this.isSticky&&this.close()},t.prototype.scrollHandler=function(e){this.tooltipEle&&!this.isSticky&&!J(e.target,"."+RE+"."+Q0+"."+FE)&&!this.isSticky&&this.close()},t.prototype.render=function(){this.initialize(),this.wireEvents(this.opensOn),this.renderComplete()},t.prototype.preRender=function(){this.tipClass=Gg,this.tooltipPositionX="Center",this.tooltipPositionY="Top",this.isHidden=!0},t.prototype.wireEvents=function(e){for(var r=0,s=this.getTriggerList(e);r0)for(var i=0,r=e;i0)for(var i=0,r=e;i0&&this.condition&&-1!==this.condition.indexOf("not")&&(e[s].condition=e[s].condition?e[s].condition+"not":"not"),i=e[s].validate(t),r){if(!i)return!1}else if(i)return!0;return r},n.prototype.toJson=function(){var t,e;if(this.isComplex){t=[],e=this.predicates;for(var i=0;ie.length-3?(e=e.substring(0,e.length-1),n.endsWith(n.toLowerCase(t),n.toLowerCase(e))):(e.lastIndexOf("%")!==e.indexOf("%")&&e.lastIndexOf("%")>e.indexOf("%")+1&&(e=e.substring(e.indexOf("%")+1,e.lastIndexOf("%"))),-1!==t.indexOf(e)))},n.fnSort=function(t){return"ascending"===(t=t?n.toLowerCase(t):"ascending")?this.fnAscending:this.fnDescending},n.fnAscending=function(t,e){return m(t)&&m(e)||null==e?-1:"string"==typeof t?t.localeCompare(e):null==t?1:t-e},n.fnDescending=function(t,e){return m(t)&&m(e)?-1:null==e?1:"string"==typeof t?-1*t.localeCompare(e):null==t?-1:e-t},n.extractFields=function(t,e){for(var i={},r=0;r0||e.length>0;)o=t.length>0&&e.length>0?r?r(this.getVal(t,0,i),this.getVal(e,0,i),t[0],e[0])<=0?t:e:t[0][i]0?t:e,s.push(o.shift());return s},n.getVal=function(t,e,i){return i?this.getObject(i,t[e]):t[e]},n.toLowerCase=function(t){return t?"string"==typeof t?t.toLowerCase():t.toString():0===t||!1===t?t.toString():""},n.callAdaptorFunction=function(t,e,i,r){if(e in t){var s=t[e](i,r);m(s)||(i=s)}return i},n.getAddParams=function(t,e,i){var r={};return n.callAdaptorFunction(t,"addParams",{dm:e,query:i,params:i?i.params:[],reqParams:r}),r},n.isPlainObject=function(t){return!!t&&t.constructor===Object},n.isCors=function(){var t=null;try{t=new window.XMLHttpRequest}catch{}return!!t&&"withCredentials"in t},n.getGuid=function(t){var i;return(t||"")+"00000000-0000-4000-0000-000000000000".replace(/0/g,function(r,s){if("crypto"in window&&"getRandomValues"in crypto){var o=new Uint8Array(1);window.crypto.getRandomValues(o),i=o[0]%16|0}else i=16*Math.random()|0;return"0123456789abcdef"[19===s?3&i|8:i]})},n.isNull=function(t){return null==t},n.getItemFromComparer=function(t,e,i){var r,s,o,a=0,l="string"==typeof n.getVal(t,0,e);if(t.length)for(;m(r)&&a0&&(r=s,o=t[a]));return o},n.distinct=function(t,e,i){i=!m(i)&&i;var s,r=[],o={};return t.forEach(function(a,l){(s="object"==typeof t[l]?n.getVal(t,l,e):t[l])in o||(r.push(i?t[l]:s),o[s]=1)}),r},n.processData=function(t,e){var i=this.prepareQuery(t),r=new nt(e);t.requiresCounts&&i.requiresCount();var s=r.executeLocal(i),o={result:t.requiresCounts?s.result:s,count:s.count,aggregates:JSON.stringify(s.aggregates)};return t.requiresCounts?o:s},n.prepareQuery=function(t){var e=this,i=new jt;return t.select&&i.select(t.select),t.where&&n.parse.parseJson(t.where).filter(function(o){if(m(o.condition))i.where(o.field,o.operator,o.value,o.ignoreCase,o.ignoreAccent);else{var a=[];o.field?a.push(new Ss(o.field,o.operator,o.value,o.ignoreCase,o.ignoreAccent)):a=a.concat(e.getPredicate(o.predicates)),"or"===o.condition?i.where(Ss.or(a)):"and"===o.condition&&i.where(Ss.and(a))}}),t.search&&n.parse.parseJson(t.search).filter(function(o){return i.search(o.key,o.fields,o.operator,o.ignoreCase,o.ignoreAccent)}),t.aggregates&&t.aggregates.filter(function(o){return i.aggregate(o.type,o.field)}),t.sorted&&t.sorted.filter(function(o){return i.sortBy(o.name,o.direction)}),t.skip&&i.skip(t.skip),t.take&&i.take(t.take),t.group&&t.group.filter(function(o){return i.group(o)}),i},n.getPredicate=function(t){for(var e=[],i=0;i":"greaterthan","<=":"lessthanorequal",">=":"greaterthanorequal","==":"equal","!=":"notequal","*=":"contains","$=":"endswith","^=":"startswith"},n.odBiOperator={"<":" lt ",">":" gt ","<=":" le ",">=":" ge ","==":" eq ","!=":" ne ",lessthan:" lt ",lessthanorequal:" le ",greaterthan:" gt ",greaterthanorequal:" ge ",equal:" eq ",notequal:" ne "},n.odUniOperator={"$=":"endswith","^=":"startswith","*=":"substringof",endswith:"endswith",startswith:"startswith",contains:"substringof",doesnotendwith:"not endswith",doesnotstartwith:"not startswith",doesnotcontain:"not substringof",wildcard:"wildcard",like:"like"},n.odv4UniOperator={"$=":"endswith","^=":"startswith","*=":"contains",endswith:"endswith",startswith:"startswith",contains:"contains",doesnotendwith:"not endswith",doesnotstartwith:"not startswith",doesnotcontain:"not contains",wildcard:"wildcard",like:"like"},n.diacritics={"\u24b6":"A",\uff21:"A",\u00c0:"A",\u00c1:"A",\u00c2:"A",\u1ea6:"A",\u1ea4:"A",\u1eaa:"A",\u1ea8:"A",\u00c3:"A",\u0100:"A",\u0102:"A",\u1eb0:"A",\u1eae:"A",\u1eb4:"A",\u1eb2:"A",\u0226:"A",\u01e0:"A",\u00c4:"A",\u01de:"A",\u1ea2:"A",\u00c5:"A",\u01fa:"A",\u01cd:"A",\u0200:"A",\u0202:"A",\u1ea0:"A",\u1eac:"A",\u1eb6:"A",\u1e00:"A",\u0104:"A",\u023a:"A",\u2c6f:"A",\ua732:"AA",\u00c6:"AE",\u01fc:"AE",\u01e2:"AE",\ua734:"AO",\ua736:"AU",\ua738:"AV",\ua73a:"AV",\ua73c:"AY","\u24b7":"B",\uff22:"B",\u1e02:"B",\u1e04:"B",\u1e06:"B",\u0243:"B",\u0182:"B",\u0181:"B","\u24b8":"C",\uff23:"C",\u0106:"C",\u0108:"C",\u010a:"C",\u010c:"C",\u00c7:"C",\u1e08:"C",\u0187:"C",\u023b:"C",\ua73e:"C","\u24b9":"D",\uff24:"D",\u1e0a:"D",\u010e:"D",\u1e0c:"D",\u1e10:"D",\u1e12:"D",\u1e0e:"D",\u0110:"D",\u018b:"D",\u018a:"D",\u0189:"D",\ua779:"D",\u01f1:"DZ",\u01c4:"DZ",\u01f2:"Dz",\u01c5:"Dz","\u24ba":"E",\uff25:"E",\u00c8:"E",\u00c9:"E",\u00ca:"E",\u1ec0:"E",\u1ebe:"E",\u1ec4:"E",\u1ec2:"E",\u1ebc:"E",\u0112:"E",\u1e14:"E",\u1e16:"E",\u0114:"E",\u0116:"E",\u00cb:"E",\u1eba:"E",\u011a:"E",\u0204:"E",\u0206:"E",\u1eb8:"E",\u1ec6:"E",\u0228:"E",\u1e1c:"E",\u0118:"E",\u1e18:"E",\u1e1a:"E",\u0190:"E",\u018e:"E","\u24bb":"F",\uff26:"F",\u1e1e:"F",\u0191:"F",\ua77b:"F","\u24bc":"G",\uff27:"G",\u01f4:"G",\u011c:"G",\u1e20:"G",\u011e:"G",\u0120:"G",\u01e6:"G",\u0122:"G",\u01e4:"G",\u0193:"G",\ua7a0:"G",\ua77d:"G",\ua77e:"G","\u24bd":"H",\uff28:"H",\u0124:"H",\u1e22:"H",\u1e26:"H",\u021e:"H",\u1e24:"H",\u1e28:"H",\u1e2a:"H",\u0126:"H",\u2c67:"H",\u2c75:"H",\ua78d:"H","\u24be":"I",\uff29:"I",\u00cc:"I",\u00cd:"I",\u00ce:"I",\u0128:"I",\u012a:"I",\u012c:"I",\u0130:"I",\u00cf:"I",\u1e2e:"I",\u1ec8:"I",\u01cf:"I",\u0208:"I",\u020a:"I",\u1eca:"I",\u012e:"I",\u1e2c:"I",\u0197:"I","\u24bf":"J",\uff2a:"J",\u0134:"J",\u0248:"J","\u24c0":"K",\uff2b:"K",\u1e30:"K",\u01e8:"K",\u1e32:"K",\u0136:"K",\u1e34:"K",\u0198:"K",\u2c69:"K",\ua740:"K",\ua742:"K",\ua744:"K",\ua7a2:"K","\u24c1":"L",\uff2c:"L",\u013f:"L",\u0139:"L",\u013d:"L",\u1e36:"L",\u1e38:"L",\u013b:"L",\u1e3c:"L",\u1e3a:"L",\u0141:"L",\u023d:"L",\u2c62:"L",\u2c60:"L",\ua748:"L",\ua746:"L",\ua780:"L",\u01c7:"LJ",\u01c8:"Lj","\u24c2":"M",\uff2d:"M",\u1e3e:"M",\u1e40:"M",\u1e42:"M",\u2c6e:"M",\u019c:"M","\u24c3":"N",\uff2e:"N",\u01f8:"N",\u0143:"N",\u00d1:"N",\u1e44:"N",\u0147:"N",\u1e46:"N",\u0145:"N",\u1e4a:"N",\u1e48:"N",\u0220:"N",\u019d:"N",\ua790:"N",\ua7a4:"N",\u01ca:"NJ",\u01cb:"Nj","\u24c4":"O",\uff2f:"O",\u00d2:"O",\u00d3:"O",\u00d4:"O",\u1ed2:"O",\u1ed0:"O",\u1ed6:"O",\u1ed4:"O",\u00d5:"O",\u1e4c:"O",\u022c:"O",\u1e4e:"O",\u014c:"O",\u1e50:"O",\u1e52:"O",\u014e:"O",\u022e:"O",\u0230:"O",\u00d6:"O",\u022a:"O",\u1ece:"O",\u0150:"O",\u01d1:"O",\u020c:"O",\u020e:"O",\u01a0:"O",\u1edc:"O",\u1eda:"O",\u1ee0:"O",\u1ede:"O",\u1ee2:"O",\u1ecc:"O",\u1ed8:"O",\u01ea:"O",\u01ec:"O",\u00d8:"O",\u01fe:"O",\u0186:"O",\u019f:"O",\ua74a:"O",\ua74c:"O",\u01a2:"OI",\ua74e:"OO",\u0222:"OU","\u24c5":"P",\uff30:"P",\u1e54:"P",\u1e56:"P",\u01a4:"P",\u2c63:"P",\ua750:"P",\ua752:"P",\ua754:"P","\u24c6":"Q",\uff31:"Q",\ua756:"Q",\ua758:"Q",\u024a:"Q","\u24c7":"R",\uff32:"R",\u0154:"R",\u1e58:"R",\u0158:"R",\u0210:"R",\u0212:"R",\u1e5a:"R",\u1e5c:"R",\u0156:"R",\u1e5e:"R",\u024c:"R",\u2c64:"R",\ua75a:"R",\ua7a6:"R",\ua782:"R","\u24c8":"S",\uff33:"S",\u1e9e:"S",\u015a:"S",\u1e64:"S",\u015c:"S",\u1e60:"S",\u0160:"S",\u1e66:"S",\u1e62:"S",\u1e68:"S",\u0218:"S",\u015e:"S",\u2c7e:"S",\ua7a8:"S",\ua784:"S","\u24c9":"T",\uff34:"T",\u1e6a:"T",\u0164:"T",\u1e6c:"T",\u021a:"T",\u0162:"T",\u1e70:"T",\u1e6e:"T",\u0166:"T",\u01ac:"T",\u01ae:"T",\u023e:"T",\ua786:"T",\ua728:"TZ","\u24ca":"U",\uff35:"U",\u00d9:"U",\u00da:"U",\u00db:"U",\u0168:"U",\u1e78:"U",\u016a:"U",\u1e7a:"U",\u016c:"U",\u00dc:"U",\u01db:"U",\u01d7:"U",\u01d5:"U",\u01d9:"U",\u1ee6:"U",\u016e:"U",\u0170:"U",\u01d3:"U",\u0214:"U",\u0216:"U",\u01af:"U",\u1eea:"U",\u1ee8:"U",\u1eee:"U",\u1eec:"U",\u1ef0:"U",\u1ee4:"U",\u1e72:"U",\u0172:"U",\u1e76:"U",\u1e74:"U",\u0244:"U","\u24cb":"V",\uff36:"V",\u1e7c:"V",\u1e7e:"V",\u01b2:"V",\ua75e:"V",\u0245:"V",\ua760:"VY","\u24cc":"W",\uff37:"W",\u1e80:"W",\u1e82:"W",\u0174:"W",\u1e86:"W",\u1e84:"W",\u1e88:"W",\u2c72:"W","\u24cd":"X",\uff38:"X",\u1e8a:"X",\u1e8c:"X","\u24ce":"Y",\uff39:"Y",\u1ef2:"Y",\u00dd:"Y",\u0176:"Y",\u1ef8:"Y",\u0232:"Y",\u1e8e:"Y",\u0178:"Y",\u1ef6:"Y",\u1ef4:"Y",\u01b3:"Y",\u024e:"Y",\u1efe:"Y","\u24cf":"Z",\uff3a:"Z",\u0179:"Z",\u1e90:"Z",\u017b:"Z",\u017d:"Z",\u1e92:"Z",\u1e94:"Z",\u01b5:"Z",\u0224:"Z",\u2c7f:"Z",\u2c6b:"Z",\ua762:"Z","\u24d0":"a",\uff41:"a",\u1e9a:"a",\u00e0:"a",\u00e1:"a",\u00e2:"a",\u1ea7:"a",\u1ea5:"a",\u1eab:"a",\u1ea9:"a",\u00e3:"a",\u0101:"a",\u0103:"a",\u1eb1:"a",\u1eaf:"a",\u1eb5:"a",\u1eb3:"a",\u0227:"a",\u01e1:"a",\u00e4:"a",\u01df:"a",\u1ea3:"a",\u00e5:"a",\u01fb:"a",\u01ce:"a",\u0201:"a",\u0203:"a",\u1ea1:"a",\u1ead:"a",\u1eb7:"a",\u1e01:"a",\u0105:"a",\u2c65:"a",\u0250:"a",\ua733:"aa",\u00e6:"ae",\u01fd:"ae",\u01e3:"ae",\ua735:"ao",\ua737:"au",\ua739:"av",\ua73b:"av",\ua73d:"ay","\u24d1":"b",\uff42:"b",\u1e03:"b",\u1e05:"b",\u1e07:"b",\u0180:"b",\u0183:"b",\u0253:"b","\u24d2":"c",\uff43:"c",\u0107:"c",\u0109:"c",\u010b:"c",\u010d:"c",\u00e7:"c",\u1e09:"c",\u0188:"c",\u023c:"c",\ua73f:"c",\u2184:"c","\u24d3":"d",\uff44:"d",\u1e0b:"d",\u010f:"d",\u1e0d:"d",\u1e11:"d",\u1e13:"d",\u1e0f:"d",\u0111:"d",\u018c:"d",\u0256:"d",\u0257:"d",\ua77a:"d",\u01f3:"dz",\u01c6:"dz","\u24d4":"e",\uff45:"e",\u00e8:"e",\u00e9:"e",\u00ea:"e",\u1ec1:"e",\u1ebf:"e",\u1ec5:"e",\u1ec3:"e",\u1ebd:"e",\u0113:"e",\u1e15:"e",\u1e17:"e",\u0115:"e",\u0117:"e",\u00eb:"e",\u1ebb:"e",\u011b:"e",\u0205:"e",\u0207:"e",\u1eb9:"e",\u1ec7:"e",\u0229:"e",\u1e1d:"e",\u0119:"e",\u1e19:"e",\u1e1b:"e",\u0247:"e",\u025b:"e",\u01dd:"e","\u24d5":"f",\uff46:"f",\u1e1f:"f",\u0192:"f",\ua77c:"f","\u24d6":"g",\uff47:"g",\u01f5:"g",\u011d:"g",\u1e21:"g",\u011f:"g",\u0121:"g",\u01e7:"g",\u0123:"g",\u01e5:"g",\u0260:"g",\ua7a1:"g",\u1d79:"g",\ua77f:"g","\u24d7":"h",\uff48:"h",\u0125:"h",\u1e23:"h",\u1e27:"h",\u021f:"h",\u1e25:"h",\u1e29:"h",\u1e2b:"h",\u1e96:"h",\u0127:"h",\u2c68:"h",\u2c76:"h",\u0265:"h",\u0195:"hv","\u24d8":"i",\uff49:"i",\u00ec:"i",\u00ed:"i",\u00ee:"i",\u0129:"i",\u012b:"i",\u012d:"i",\u00ef:"i",\u1e2f:"i",\u1ec9:"i",\u01d0:"i",\u0209:"i",\u020b:"i",\u1ecb:"i",\u012f:"i",\u1e2d:"i",\u0268:"i",\u0131:"i","\u24d9":"j",\uff4a:"j",\u0135:"j",\u01f0:"j",\u0249:"j","\u24da":"k",\uff4b:"k",\u1e31:"k",\u01e9:"k",\u1e33:"k",\u0137:"k",\u1e35:"k",\u0199:"k",\u2c6a:"k",\ua741:"k",\ua743:"k",\ua745:"k",\ua7a3:"k","\u24db":"l",\uff4c:"l",\u0140:"l",\u013a:"l",\u013e:"l",\u1e37:"l",\u1e39:"l",\u013c:"l",\u1e3d:"l",\u1e3b:"l",\u017f:"l",\u0142:"l",\u019a:"l",\u026b:"l",\u2c61:"l",\ua749:"l",\ua781:"l",\ua747:"l",\u01c9:"lj","\u24dc":"m",\uff4d:"m",\u1e3f:"m",\u1e41:"m",\u1e43:"m",\u0271:"m",\u026f:"m","\u24dd":"n",\uff4e:"n",\u01f9:"n",\u0144:"n",\u00f1:"n",\u1e45:"n",\u0148:"n",\u1e47:"n",\u0146:"n",\u1e4b:"n",\u1e49:"n",\u019e:"n",\u0272:"n",\u0149:"n",\ua791:"n",\ua7a5:"n",\u01cc:"nj","\u24de":"o",\uff4f:"o",\u00f2:"o",\u00f3:"o",\u00f4:"o",\u1ed3:"o",\u1ed1:"o",\u1ed7:"o",\u1ed5:"o",\u00f5:"o",\u1e4d:"o",\u022d:"o",\u1e4f:"o",\u014d:"o",\u1e51:"o",\u1e53:"o",\u014f:"o",\u022f:"o",\u0231:"o",\u00f6:"o",\u022b:"o",\u1ecf:"o",\u0151:"o",\u01d2:"o",\u020d:"o",\u020f:"o",\u01a1:"o",\u1edd:"o",\u1edb:"o",\u1ee1:"o",\u1edf:"o",\u1ee3:"o",\u1ecd:"o",\u1ed9:"o",\u01eb:"o",\u01ed:"o",\u00f8:"o",\u01ff:"o",\u0254:"o",\ua74b:"o",\ua74d:"o",\u0275:"o",\u01a3:"oi",\u0223:"ou",\ua74f:"oo","\u24df":"p",\uff50:"p",\u1e55:"p",\u1e57:"p",\u01a5:"p",\u1d7d:"p",\ua751:"p",\ua753:"p",\ua755:"p","\u24e0":"q",\uff51:"q",\u024b:"q",\ua757:"q",\ua759:"q","\u24e1":"r",\uff52:"r",\u0155:"r",\u1e59:"r",\u0159:"r",\u0211:"r",\u0213:"r",\u1e5b:"r",\u1e5d:"r",\u0157:"r",\u1e5f:"r",\u024d:"r",\u027d:"r",\ua75b:"r",\ua7a7:"r",\ua783:"r","\u24e2":"s",\uff53:"s",\u00df:"s",\u015b:"s",\u1e65:"s",\u015d:"s",\u1e61:"s",\u0161:"s",\u1e67:"s",\u1e63:"s",\u1e69:"s",\u0219:"s",\u015f:"s",\u023f:"s",\ua7a9:"s",\ua785:"s",\u1e9b:"s","\u24e3":"t",\uff54:"t",\u1e6b:"t",\u1e97:"t",\u0165:"t",\u1e6d:"t",\u021b:"t",\u0163:"t",\u1e71:"t",\u1e6f:"t",\u0167:"t",\u01ad:"t",\u0288:"t",\u2c66:"t",\ua787:"t",\ua729:"tz","\u24e4":"u",\uff55:"u",\u00f9:"u",\u00fa:"u",\u00fb:"u",\u0169:"u",\u1e79:"u",\u016b:"u",\u1e7b:"u",\u016d:"u",\u00fc:"u",\u01dc:"u",\u01d8:"u",\u01d6:"u",\u01da:"u",\u1ee7:"u",\u016f:"u",\u0171:"u",\u01d4:"u",\u0215:"u",\u0217:"u",\u01b0:"u",\u1eeb:"u",\u1ee9:"u",\u1eef:"u",\u1eed:"u",\u1ef1:"u",\u1ee5:"u",\u1e73:"u",\u0173:"u",\u1e77:"u",\u1e75:"u",\u0289:"u","\u24e5":"v",\uff56:"v",\u1e7d:"v",\u1e7f:"v",\u028b:"v",\ua75f:"v",\u028c:"v",\ua761:"vy","\u24e6":"w",\uff57:"w",\u1e81:"w",\u1e83:"w",\u0175:"w",\u1e87:"w",\u1e85:"w",\u1e98:"w",\u1e89:"w",\u2c73:"w","\u24e7":"x",\uff58:"x",\u1e8b:"x",\u1e8d:"x","\u24e8":"y",\uff59:"y",\u1ef3:"y",\u00fd:"y",\u0177:"y",\u1ef9:"y",\u0233:"y",\u1e8f:"y",\u00ff:"y",\u1ef7:"y",\u1e99:"y",\u1ef5:"y",\u01b4:"y",\u024f:"y",\u1eff:"y","\u24e9":"z",\uff5a:"z",\u017a:"z",\u1e91:"z",\u017c:"z",\u017e:"z",\u1e93:"z",\u1e95:"z",\u01b6:"z",\u0225:"z",\u0240:"z",\u2c6c:"z",\ua763:"z",\u0386:"\u0391",\u0388:"\u0395",\u0389:"\u0397",\u038a:"\u0399",\u03aa:"\u0399",\u038c:"\u039f",\u038e:"\u03a5",\u03ab:"\u03a5",\u038f:"\u03a9",\u03ac:"\u03b1",\u03ad:"\u03b5",\u03ae:"\u03b7",\u03af:"\u03b9",\u03ca:"\u03b9",\u0390:"\u03b9",\u03cc:"\u03bf",\u03cd:"\u03c5",\u03cb:"\u03c5",\u03b0:"\u03c5",\u03c9:"\u03c9",\u03c2:"\u03c3"},n.fnOperators={equal:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?n.toLowerCase(t)===n.toLowerCase(e):t===e},notequal:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),!n.fnOperators.equal(t,e,i)},lessthan:function(t,e,i){return i?n.toLowerCase(t)n.toLowerCase(e):t>e},lessthanorequal:function(t,e,i){return i?n.toLowerCase(t)<=n.toLowerCase(e):(m(t)&&(t=void 0),t<=e)},greaterthanorequal:function(t,e,i){return i?n.toLowerCase(t)>=n.toLowerCase(e):t>=e},contains:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?!m(t)&&!m(e)&&-1!==n.toLowerCase(t).indexOf(n.toLowerCase(e)):!m(t)&&!m(e)&&-1!==t.toString().indexOf(e)},doesnotcontain:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?!m(t)&&!m(e)&&-1===n.toLowerCase(t).indexOf(n.toLowerCase(e)):!m(t)&&!m(e)&&-1===t.toString().indexOf(e)},isnotnull:function(t){return null!=t},isnull:function(t){return null==t},startswith:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.startsWith(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.startsWith(t,e)},doesnotstartwith:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.notStartsWith(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.notStartsWith(t,e)},like:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.like(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.like(t,e)},isempty:function(t){return void 0===t||""===t},isnotempty:function(t){return void 0!==t&&""!==t},wildcard:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?(t||"boolean"==typeof t)&&e&&"object"!=typeof t&&n.wildCard(n.toLowerCase(t),n.toLowerCase(e)):(t||"boolean"==typeof t)&&e&&n.wildCard(t,e)},endswith:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.endsWith(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.endsWith(t,e)},doesnotendwith:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.notEndsWith(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.notEndsWith(t,e)},processSymbols:function(t){var e=n.operatorSymbols[t];return e?n.fnOperators[e]:n.throwError("Query - Process Operator : Invalid operator")},processOperator:function(t){return n.fnOperators[t]||n.fnOperators.processSymbols(t)}},n.parse={parseJson:function(t){return"string"!=typeof t||!/^[\s]*\[|^[\s]*\{(.)+:/g.test(t)&&-1!==t.indexOf('"')?t instanceof Array?n.parse.iterateAndReviveArray(t):"object"==typeof t&&null!==t&&n.parse.iterateAndReviveJson(t):t=JSON.parse(t,n.parse.jsonReviver),t},iterateAndReviveArray:function(t){for(var e=0;e-1||e.indexOf("z")>-1,o=e.split(/[^0-9.]/);if(s){if(o[5].indexOf(".")>-1){var a=o[5].split(".");o[5]=a[0],o[6]=new Date(e).getUTCMilliseconds().toString()}else o[6]="00";e=n.dateParse.toTimeZone(new Date(parseInt(o[0],10),parseInt(o[1],10)-1,parseInt(o[2],10),parseInt(o[3],10),parseInt(o[4],10),parseInt(o[5]?o[5]:"00",10),parseInt(o[6],10)),n.serverTimezoneOffset,!1)}else{var l=new Date(parseInt(o[0],10),parseInt(o[1],10)-1,parseInt(o[2],10),parseInt(o[3],10),parseInt(o[4],10),parseInt(o[5]?o[5]:"00",10)),h=parseInt(o[6],10),c=parseInt(o[7],10);if(isNaN(h)&&isNaN(c))return l;e.indexOf("+")>-1?l.setHours(l.getHours()-h,l.getMinutes()-c):l.setHours(l.getHours()+h,l.getMinutes()+c),e=n.dateParse.toTimeZone(l,n.serverTimezoneOffset,!1)}null==n.serverTimezoneOffset&&(e=n.dateParse.addSelfOffset(e))}}return e},isJson:function(t){return"string"==typeof t[0]?t:n.parse.parseJson(t)},isGuid:function(t){return null!=/[A-Fa-f0-9]{8}(?:-[A-Fa-f0-9]{4}){3}-[A-Fa-f0-9]{12}/i.exec(t)},replacer:function(t,e){return n.isPlainObject(t)?n.parse.jsonReplacer(t,e):t instanceof Array?n.parse.arrayReplacer(t):t instanceof Date?n.parse.jsonReplacer({val:t},e).val:t},jsonReplacer:function(t,e){for(var i,s=0,o=Object.keys(t);s=0?"+":"-",s=function(a){var l=Math.floor(Math.abs(a));return(l<10?"0":"")+l};return e.getFullYear()+"-"+s(e.getMonth()+1)+"-"+s(e.getDate())+"T"+s(e.getHours())+":"+s(e.getMinutes())+":"+s(e.getSeconds())+r+s(i/60)+":"+s(i%60)}},n}(),bl=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),xK={GroupGuid:"{271bbba0-1ee7}"},t5=function(){function n(t){this.options={from:"table",requestType:"json",sortBy:"sorted",select:"select",skip:"skip",group:"group",take:"take",search:"search",count:"requiresCounts",where:"where",aggregates:"aggregates",expand:"expand"},this.type=n,this.dataSource=t,this.pvt={}}return n.prototype.processResponse=function(t,e,i,r){return t},n}(),VE=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return bl(t,n),t.prototype.processQuery=function(e,i){for(var a,l,p,r=e.dataSource.json.slice(0),s=r.length,o=!0,h={},c=0,d=[],u=[],f=0;f1?e.sort.filter(function(p){return p.fieldName===c})[0]:e.sort[0];s=this.onSortBy(s,d,e.query,!0)}e.page&&(s=this.onPage(s,e.page,e.query)),this.formGroupResult(s,h)}else{for(var o=e.lazyLoad.onDemandGroupInfo,a=o.where.length-1;a>=0;a--)s=this.onWhere(s,o.where[a]);if(e.group.length!==o.level)s=le.group(s,e.group[o.level].fieldName,r,null,null,e.group[o.level].comparer,!0),e.sort.length&&(s=this.onSortBy(s,e.sort[parseInt(o.level.toString(),10)],e.query,!0));else for(a=e.sort.length-1;a>=o.level;a--)s=this.onSortBy(s,e.sort[parseInt(a.toString(),10)],e.query,!1);i=s.length,h=s,s=(s=s.slice(o.skip)).slice(0,o.take),e.group.length!==o.level&&this.formGroupResult(s,h)}return{result:s,count:i}},t.prototype.formGroupResult=function(e,i){if(e.length&&i.length){var r="GroupGuid",s="childLevels",o="level",a="records";e[r]=i[r],e[s]=i[s],e[o]=i[o],e[a]=i[a]}return e},t.prototype.getAggregate=function(e){var i=jt.filterQueries(e.queries,"onAggregates"),r=[];if(i.length)for(var s=void 0,o=0;o=0;l--)a[l]&&(o=i.comparer,le.endsWith(a[l]," desc")&&(o=le.fnSort("descending"),a[l]=a[l].replace(" desc","")),e=le.sort(e,a[l],o));return e}return le.sort(e,s?"key":a,i.comparer)},t.prototype.onGroup=function(e,i,r){if(!e||!e.length)return e;var s=this.getAggregate(r);return le.group(e,le.getValue(i.fieldName,r),s,null,null,i.comparer)},t.prototype.onPage=function(e,i,r){var s=le.getValue(i.pageSize,r),o=(le.getValue(i.pageIndex,r)-1)*s;return e&&e.length?e.slice(o,o+s):e},t.prototype.onRange=function(e,i){return e&&e.length?e.slice(le.getValue(i.start),le.getValue(i.end)):e},t.prototype.onTake=function(e,i){return e&&e.length?e.slice(0,le.getValue(i.nos)):e},t.prototype.onSkip=function(e,i){return e&&e.length?e.slice(le.getValue(i.nos)):e},t.prototype.onSelect=function(e,i){return e&&e.length?le.select(e,le.getValue(i.fieldNames)):e},t.prototype.insert=function(e,i,r,s,o){return m(o)?e.dataSource.json.push(i):e.dataSource.json.splice(o,0,i)},t.prototype.remove=function(e,i,r,s){var a,o=e.dataSource.json;for("object"==typeof r&&!(r instanceof Date)&&(r=le.getObject(i,r)),a=0;a1&&(g="("+g+")"),p.filters.push(g);for(var y=0,S="object"==typeof p.filters[f]?Object.keys(p.filters[f]):[];y-1&&this.formRemoteGroupedData(e[s].items,i+1,r-1);var o="GroupGuid",h="records";return e[o]=xK[o],e.level=i,e.childLevels=r,e[h]=e[0].items.length?this.getGroupedRecords(e,!m(e[0].items[h])):[],e},t.prototype.getGroupedRecords=function(e,i){for(var r=[],o=0;ol.length-3?(l=l.substring(0,l.length-1),o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.endswith:le.odv4UniOperator.endswith):l.lastIndexOf("%")!==l.indexOf("%")&&l.lastIndexOf("%")>l.indexOf("%")+1?(l=l.substring(l.indexOf("%")+1,l.lastIndexOf("%")),o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains):o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains),l="'"+(l=encodeURIComponent(l))+"'";else if("wildcard"===o)if(-1!==l.indexOf("*")){var d=l.split("*"),u=void 0,p=0;if(0!==l.indexOf("*")&&-1===d[0].indexOf("%3f")&&-1===d[0].indexOf("?")&&(u="'"+(u=d[0])+"'",s+=(o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.startswith:le.odv4UniOperator.startswith)+"(",s+=c+",",a&&(s+=a),s+=u+")",p++),l.lastIndexOf("*")!==l.length-1&&-1===d[d.length-1].indexOf("%3f")&&-1===d[d.length-1].indexOf("?")&&(u="'"+(u=d[d.length-1])+"'",p>0&&(s+=" and "),s+=(o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.endswith:le.odv4UniOperator.endswith)+"(",s+=c+",",a&&(s+=a),s+=u+")",p++),d.length>2)for(var f=1;f0&&(s+=" and "),"substringof"===(o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains)||"not substringof"===o){var g=u;u=c,c=g}s+=o+"(",s+=c+",",a&&(s+=a),s+=u+")",p++}0===p?(o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains,(-1!==l.indexOf("?")||-1!==l.indexOf("%3f"))&&(l=-1!==l.indexOf("?")?l.split("?").join(""):l.split("%3f").join("")),l="'"+l+"'"):o="wildcard"}else o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains,(-1!==l.indexOf("?")||-1!==l.indexOf("%3f"))&&(l=-1!==l.indexOf("?")?l.split("?").join(""):l.split("%3f").join("")),l="'"+l+"'";return"substringof"!==o&&"not substringof"!==o||(g=l,l=c,c=g),"wildcard"!==o&&(s+=o+"(",s+=c+",",a&&(s+=a),s+=l+")"),s},t.prototype.addParams=function(e){n.prototype.addParams.call(this,e),delete e.reqParams.params},t.prototype.onComplexPredicate=function(e,i,r){for(var s=[],o=0;o-1;p--)!/\bContent-ID:/i.test(c[p])||!/\bHTTP.+201/.test(c[p])||(l=parseInt(/\bContent-ID: (\d+)/i.exec(c[p])[1],10),o.addedRecords[l]&&(h=le.parse.parseJson(/^\{.+\}/m.exec(c[p])[0]),ze({},o.addedRecords[l],this.processResponse(h))));return o}return null},t.prototype.compareAndRemove=function(e,i,r){var s=this;return m(i)||Object.keys(e).forEach(function(o){o!==r&&"@odata.etag"!==o&&(le.isPlainObject(e[o])?(s.compareAndRemove(e[o],i[o]),0===Object.keys(e[o]).filter(function(l){return"@odata.etag"!==l}).length&&delete e[o]):(e[o]===i[o]||e[o]&&i[o]&&e[o].valueOf()===i[o].valueOf())&&delete e[o])}),e},t}(uc),TK=function(n){function t(){var e=n.call(this)||this;return yt("beforeSend",uc.prototype.beforeSend,e),e}return bl(t,n),t.prototype.insert=function(e,i,r,s,o){return this.pvt.position=o,this.updateType="add",{url:e.dataSource.insertUrl||e.dataSource.crudUrl||e.dataSource.url,data:JSON.stringify(ze({},{value:i,table:r,action:"insert"},le.getAddParams(this,e,s)))}},t.prototype.remove=function(e,i,r,s,o){return n.prototype.remove.call(this,e,i,r),{type:"POST",url:e.dataSource.removeUrl||e.dataSource.crudUrl||e.dataSource.url,data:JSON.stringify(ze({},{key:r,keyColumn:i,table:s,action:"remove"},le.getAddParams(this,e,o)))}},t.prototype.update=function(e,i,r,s,o){return this.updateType="update",this.updateKey=i,{type:"POST",url:e.dataSource.updateUrl||e.dataSource.crudUrl||e.dataSource.url,data:JSON.stringify(ze({},{value:r,action:"update",keyColumn:i,key:r[i],table:s},le.getAddParams(this,e,o)))}},t.prototype.processResponse=function(e,i,r,s,o,a,l){var h;if(e="batch"===(o?JSON.parse(o.data):e).action?le.parse.parseJson(e):e,"add"===this.updateType&&n.prototype.insert.call(this,i,e,null,null,this.pvt.position),"update"===this.updateType&&n.prototype.update.call(this,i,this.updateKey,e),this.updateType=void 0,e.added)for(h=0;hi&&h.push(c)}for(c=0;cthis.pageSize;)h.results.splice(0,1),h.keys.splice(0,1);return window.localStorage.setItem(this.guidId,JSON.stringify(h)),e},t.prototype.beforeSend=function(e,i,r){!m(this.cacheAdaptor.options.batch)&&le.endsWith(r.url,this.cacheAdaptor.options.batch)&&"post"===r.type.toLowerCase()&&i.headers.set("Accept",this.cacheAdaptor.options.multipartAccept),e.dataSource.crossDomain||i.headers.set("Accept",this.cacheAdaptor.options.accept)},t.prototype.update=function(e,i,r,s){return this.isCrudAction=!0,this.cacheAdaptor.update(e,i,r,s)},t.prototype.insert=function(e,i,r){return this.isInsertAction=!0,this.cacheAdaptor.insert(e,i,r)},t.prototype.remove=function(e,i,r,s){return this.isCrudAction=!0,this.cacheAdaptor.remove(e,i,r,s)},t.prototype.batchRequest=function(e,i,r){return this.cacheAdaptor.batchRequest(e,i,r)},t}(uc),nt=function(){function n(t,e,i){var s,r=this;return this.dateParse=!0,this.timeZoneHandling=!0,this.persistQuery={},this.isInitialLoad=!1,this.requests=[],this.isInitialLoad=!0,!t&&!this.dataSource&&(t=[]),i=i||t.adaptor,t&&!1===t.timeZoneHandling&&(this.timeZoneHandling=t.timeZoneHandling),t instanceof Array?s={json:t,offline:!0}:"object"==typeof t?(t.json||(t.json=[]),t.enablePersistence||(t.enablePersistence=!1),t.id||(t.id=""),t.ignoreOnPersist||(t.ignoreOnPersist=[]),s={url:t.url,insertUrl:t.insertUrl,removeUrl:t.removeUrl,updateUrl:t.updateUrl,crudUrl:t.crudUrl,batchUrl:t.batchUrl,json:t.json,headers:t.headers,accept:t.accept,data:t.data,timeTillExpiration:t.timeTillExpiration,cachingPageSize:t.cachingPageSize,enableCaching:t.enableCaching,requestType:t.requestType,key:t.key,crossDomain:t.crossDomain,jsonp:t.jsonp,dataType:t.dataType,offline:void 0!==t.offline?t.offline:!(t.adaptor instanceof TK||t.adaptor instanceof AK||t.url),requiresFormat:t.requiresFormat,enablePersistence:t.enablePersistence,id:t.id,ignoreOnPersist:t.ignoreOnPersist}):le.throwError("DataManager: Invalid arguments"),void 0===s.requiresFormat&&!le.isCors()&&(s.requiresFormat=!!m(s.crossDomain)||s.crossDomain),void 0===s.dataType&&(s.dataType="json"),this.dataSource=s,this.defaultQuery=e,this.dataSource.enablePersistence&&this.dataSource.id&&window.addEventListener("unload",this.setPersistData.bind(this)),s.url&&s.offline&&!s.json.length?(this.isDataAvailable=!1,this.adaptor=i||new up,this.dataSource.offline=!1,this.ready=this.executeQuery(e||new jt),this.ready.then(function(o){r.dataSource.offline=!0,r.isDataAvailable=!0,s.json=o.result,r.adaptor=new VE})):this.adaptor=s.offline?new VE:new up,!s.jsonp&&this.adaptor instanceof up&&(s.jsonp="callback"),this.adaptor=i||this.adaptor,s.enableCaching&&(this.adaptor=new LK(this.adaptor,s.timeTillExpiration,s.cachingPageSize)),this}return Object.defineProperty(n.prototype,"moduleName",{get:function(){return"datamanager"},enumerable:!0,configurable:!0}),n.prototype.getPersistedData=function(t){var e=localStorage.getItem(t||this.dataSource.id);return JSON.parse(e)},n.prototype.setPersistData=function(t,e,i){localStorage.setItem(e||this.dataSource.id,JSON.stringify(i||this.persistQuery))},n.prototype.setPersistQuery=function(t){var e=this,i=this.getPersistedData();if(this.isInitialLoad&&i&&Object.keys(i).length){this.persistQuery=i,this.persistQuery.queries=this.persistQuery.queries.filter(function(s){if(e.dataSource.ignoreOnPersist&&e.dataSource.ignoreOnPersist.length&&s.fn&&e.dataSource.ignoreOnPersist.some(function(l){return s.fn===l}))return!1;if("onWhere"===s.fn){var o=s.e;if(o&&o.isComplex&&o.predicates instanceof Array){var a=o.predicates.map(function(l){if(l.predicates&&l.predicates instanceof Array){var h=l.predicates.map(function(v){return new Ss(v.field,v.operator,v.value,v.ignoreCase,v.ignoreAccent,v.matchCase)});return"and"===l.condition?Ss.and(h):Ss.or(h)}return new Ss(l.field,l.operator,l.value,l.ignoreCase,l.ignoreAccent,l.matchCase)});s.e=new Ss(a[0],o.condition,a.slice(1))}}return!0});var r=ze(new jt,this.persistQuery);return this.isInitialLoad=!1,r}return this.persistQuery=t,this.isInitialLoad=!1,t},n.prototype.setDefaultQuery=function(t){return this.defaultQuery=t,this},n.prototype.executeLocal=function(t){!this.defaultQuery&&!(t instanceof jt)&&le.throwError("DataManager - executeLocal() : A query is required to execute"),this.dataSource.json||le.throwError("DataManager - executeLocal() : Json data is required to execute"),this.dataSource.enablePersistence&&this.dataSource.id&&(t=this.setPersistQuery(t));var e=this.adaptor.processQuery(this,t=t||this.defaultQuery);if(t.subQuery){var i=t.subQuery.fromTable,r=t.subQuery.lookups,s=t.isCountRequired?e.result:e;r&&r instanceof Array&&le.buildHierarchy(t.subQuery.fKey,i,s,r,t.subQuery.key);for(var o=0;oli");P.classList.remove("json-parent");for(var j=0;j',W=ve.children[0].placeholder}return W}function Q(k,W,ve){!m(ve)&&""!==ve&&K(W,ve.split(" ")),!m(k)&&""!==k&&V(W,k.split(" "))}function oe(k,W,ve){if("multiselect"===ve||function Mo(k){if(!k)return!1;for(var W=k;W&&W!==document.body;){if("none"===window.getComputedStyle(W).display)return!1;W=W.parentElement}return!0}(k)){var Te="multiselect"===ve?k:k.clientWidth-parseInt(getComputedStyle(k,null).getPropertyValue("padding-left"),10);!m(W)&&!m(W.getElementsByClassName("e-float-text-content")[0])&&(W.getElementsByClassName("e-float-text-content")[0].classList.contains("e-float-text-overflow")&&W.getElementsByClassName("e-float-text-content")[0].classList.remove("e-float-text-overflow"),(Te0)for(var Ye=0;Ye<_e.length;Ye++)_e[parseInt(Ye.toString(),10)].addEventListener("mousedown",wo,!1),_e[parseInt(Ye.toString(),10)].addEventListener("mouseup",Hl,!1);else if(_e.length>0)for(Ye=0;Ye<_e.length;Ye++)_e[parseInt(Ye.toString(),10)].removeEventListener("mousedown",wo,this),_e[parseInt(Ye.toString(),10)].removeEventListener("mouseup",Hl,this)}function wo(){for(var W=this.parentElement;!W.classList.contains("e-input-group");)W=W.parentElement;!function ya(k,W){!k.classList.contains("e-disabled")&&!k.querySelector("input").readOnly&&W.classList.add("e-input-btn-ripple")}(W,this)}function Hl(){var k=this;setTimeout(function(){k.classList.remove("e-input-btn-ripple")},500)}function fb(k,W){var ve=W("span",{className:k});return ve.classList.add("e-input-group-icon"),ve}function y_(k,W,ve,Te){var _e=m(Te)?mi:Te,Ye=fb(k,_e);W.classList.add("e-float-icon-left");var fi=W.querySelector(".e-input-in-wrap");if(m(fi)){fi=_e("span",{className:"e-input-in-wrap"}),ve.parentNode.insertBefore(fi,ve);var Gs=W.querySelectorAll(ve.tagName+" ~ *");fi.appendChild(ve);for(var Kn=0;Kn-1)if("class"===_e){var Ye=this.getInputValidClassList(k[""+_e]);""!==Ye&&V([W],Ye.split(" "))}else if("style"===_e){var fi=W.getAttribute(_e);fi=m(fi)?k[""+_e]:fi+k[""+_e],W.setAttribute(_e,fi)}else W.setAttribute(_e,k[""+_e])}},n.isBlank=function Hle(k){return!k||/^\s*$/.test(k)}}(Le||(Le={})),new RegExp("^(-)?(\\d*)$"),new RegExp("^[A-Za-z0-9._%+-]{1,}@[A-Za-z0-9._%+-]{1,}([.]{1}[a-zA-Z0-9]{2,}|[.]{1}[a-zA-Z0-9]{2,4}[.]{1}[a-zA-Z0-9]{2,4})$"),new RegExp("^([0-9]{4})-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])$"),new RegExp("^[0-9]*$"),new RegExp("^[+]?[0-9]{9,13}$"),new RegExp("^\\d{13,16}$");var me=function(){function n(t,e){this.width=t,this.height=e}return n.prototype.isEmpty=function(){return 0===this.height&&0===this.width},n.prototype.clone=function(){return new n(this.width,this.height)},n}(),Eie=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),GB=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},z=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Eie(t,n),t.equals=function(e,i){return e===i||!(!e||!i)&&(!e||!i||e.x===i.x&&e.y===i.y)},t.isEmptyPoint=function(e){return!(e.x&&e.y)},t.transform=function(e,i,r){var s={x:0,y:0};return s.x=Math.round(100*(e.x+r*Math.cos(i*Math.PI/180)))/100,s.y=Math.round(100*(e.y+r*Math.sin(i*Math.PI/180)))/100,s},t.findLength=function(e,i){return Math.sqrt(Math.pow(e.x-i.x,2)+Math.pow(e.y-i.y,2))},t.findAngle=function(e,i){var r=Math.atan2(i.y-e.y,i.x-e.x);return r=180*r/Math.PI,(r%=360)<0&&(r+=360),r},t.distancePoints=function(e,i){return Math.sqrt(Math.pow(i.x-e.x,2)+Math.pow(i.y-e.y,2))},t.getLengthFromListOfPoints=function(e){for(var i=0,r=0;ri.y&&!r?o.y+=s:o.y-=s:e.y===i.y?e.xi.x&&!r?o.x+=s:o.x-=s:r?(a=this.findAngle(e,i),o=this.transform(e,a,s)):(a=this.findAngle(i,e),o=this.transform(i,a,s)),o},t.direction=function(e,i){return Math.abs(i.x-e.x)>Math.abs(i.y-e.y)?e.x0)for(var r=0;rt.right||this.top>t.bottom||this.bottom=t.right&&this.top<=t.top&&this.bottom>=t.bottom},n.prototype.containsPoint=function(t,e){return void 0===e&&(e=0),this.left-e<=t.x&&this.right+e>=t.x&&this.top-e<=t.y&&this.bottom+e>=t.y},n.toBounds=function(t){for(var e=new n,i=0,r=t;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},KB=function(n){if(n)switch(n.type){case"Linear":default:return vI;case"Radial":return Rie}return vI},Pie=function(){return function n(t,e,i,r){this.left=t,this.right=e,this.top=i,this.bottom=r}}(),$n=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),it([I(0)],t.prototype,"left",void 0),it([I(0)],t.prototype,"right",void 0),it([I(0)],t.prototype,"top",void 0),it([I(0)],t.prototype,"bottom",void 0),t}(Ee),zie=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),it([I(45)],t.prototype,"angle",void 0),it([I(5)],t.prototype,"distance",void 0),it([I(.7)],t.prototype,"opacity",void 0),it([I("lightgrey")],t.prototype,"color",void 0),t}(Ee),e3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),t.prototype.getClassName=function(){return"Stop"},it([I("")],t.prototype,"color",void 0),it([I(0)],t.prototype,"offset",void 0),it([I(1)],t.prototype,"opacity",void 0),t}(Ee),Ix=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),it([Bt([],e3)],t.prototype,"stops",void 0),it([I("None")],t.prototype,"type",void 0),it([I("")],t.prototype,"id",void 0),t}(Ee),vI=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),it([I(0)],t.prototype,"x1",void 0),it([I(0)],t.prototype,"x2",void 0),it([I(0)],t.prototype,"y1",void 0),it([I(0)],t.prototype,"y2",void 0),t}(Ix),Rie=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),it([I(0)],t.prototype,"cx",void 0),it([I(0)],t.prototype,"cy",void 0),it([I(0)],t.prototype,"fx",void 0),it([I(0)],t.prototype,"fy",void 0),it([I(50)],t.prototype,"r",void 0),t}(Ix),Al=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),it([I("white")],t.prototype,"fill",void 0),it([I("black")],t.prototype,"strokeColor",void 0),it([I("")],t.prototype,"strokeDashArray",void 0),it([I(1)],t.prototype,"strokeWidth",void 0),it([I(1)],t.prototype,"opacity",void 0),it([C0(KB)],t.prototype,"gradient",void 0),t}(Ee),t3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),it([I("transparent")],t.prototype,"fill",void 0),t}(Al),Yp=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),it([I("black")],t.prototype,"color",void 0),it([I("Arial")],t.prototype,"fontFamily",void 0),it([I(12)],t.prototype,"fontSize",void 0),it([I(!1)],t.prototype,"italic",void 0),it([I(!1)],t.prototype,"bold",void 0),it([I("CollapseSpace")],t.prototype,"whiteSpace",void 0),it([I("WrapWithOverflow")],t.prototype,"textWrapping",void 0),it([I("Center")],t.prototype,"textAlign",void 0),it([I("None")],t.prototype,"textDecoration",void 0),it([I("Wrap")],t.prototype,"textOverflow",void 0),it([I("transparent")],t.prototype,"fill",void 0),t}(Al),on=function(n){return n[n.Default=0]="Default",n[n.expandNode=2]="expandNode",n[n.interaction=4]="interaction",n[n.GroupingInProgress=8]="GroupingInProgress",n[n.GroupClipboardInProcess=16]="GroupClipboardInProcess",n[n.ClearObject=32]="ClearObject",n}(on||{}),Gt=function(n){return n[n.Visible=1]="Visible",n[n.Hidden=2]="Hidden",n[n.Hover=4]="Hover",n[n.Connect=8]="Connect",n}(Gt||{}),ei=function(n){return n[n.None=0]="None",n[n.ShowHorizontalLines=1]="ShowHorizontalLines",n[n.ShowVerticalLines=2]="ShowVerticalLines",n[n.ShowLines=3]="ShowLines",n[n.SnapToHorizontalLines=4]="SnapToHorizontalLines",n[n.SnapToVerticalLines=8]="SnapToVerticalLines",n[n.SnapToLines=12]="SnapToLines",n[n.SnapToObject=16]="SnapToObject",n[n.All=31]="All",n}(ei||{}),mr=function(n){return n[n.None=1]="None",n[n.ConnectorSourceThumb=2]="ConnectorSourceThumb",n[n.ConnectorTargetThumb=4]="ConnectorTargetThumb",n[n.ResizeSouthEast=8]="ResizeSouthEast",n[n.ResizeSouthWest=16]="ResizeSouthWest",n[n.ResizeNorthEast=32]="ResizeNorthEast",n[n.ResizeNorthWest=64]="ResizeNorthWest",n[n.ResizeEast=128]="ResizeEast",n[n.ResizeWest=256]="ResizeWest",n[n.ResizeSouth=512]="ResizeSouth",n[n.ResizeNorth=1024]="ResizeNorth",n[n.Rotate=2048]="Rotate",n[n.UserHandle=4096]="UserHandle",n[n.ToolTip=8192]="ToolTip",n[n.ResizeAll=2046]="ResizeAll",n[n.All=16382]="All",n}(mr||{}),qe=function(n){return n[n.None=1]="None",n[n.Select=2]="Select",n[n.Delete=4]="Delete",n[n.Drag=8]="Drag",n[n.DragSourceEnd=16]="DragSourceEnd",n[n.DragTargetEnd=32]="DragTargetEnd",n[n.DragSegmentThumb=64]="DragSegmentThumb",n[n.AllowDrop=128]="AllowDrop",n[n.Bridging=256]="Bridging",n[n.BridgeObstacle=512]="BridgeObstacle",n[n.InheritBridging=1024]="InheritBridging",n[n.PointerEvents=2048]="PointerEvents",n[n.Tooltip=4096]="Tooltip",n[n.InheritTooltip=8192]="InheritTooltip",n[n.Interaction=4218]="Interaction",n[n.ReadOnly=16384]="ReadOnly",n[n.LineRouting=32768]="LineRouting",n[n.InheritLineRouting=65536]="InheritLineRouting",n[n.ConnectToNearByNode=131072]="ConnectToNearByNode",n[n.ConnectToNearByPort=262144]="ConnectToNearByPort",n[n.ConnectToNearByElement=393216]="ConnectToNearByElement",n[n.InheritSegmentThumbShape=524288]="InheritSegmentThumbShape",n[n.InheritSegmentThumbSize=1048576]="InheritSegmentThumbSize",n[n.Default=2043454]="Default",n}(qe||{}),Lr=function(n){return n[n.ReadOnly=2]="ReadOnly",n[n.InheritReadOnly=4]="InheritReadOnly",n[n.Select=8]="Select",n[n.Drag=16]="Drag",n[n.Resize=32]="Resize",n[n.Rotate=64]="Rotate",n[n.Tooltip=128]="Tooltip",n[n.Interaction=120]="Interaction",n[n.None=0]="None",n}(Lr||{}),ie=function(n){return n[n.None=0]="None",n[n.Select=2]="Select",n[n.Drag=4]="Drag",n[n.Rotate=8]="Rotate",n[n.Shadow=16]="Shadow",n[n.PointerEvents=32]="PointerEvents",n[n.Delete=64]="Delete",n[n.InConnect=128]="InConnect",n[n.OutConnect=256]="OutConnect",n[n.Individual=512]="Individual",n[n.Expandable=1024]="Expandable",n[n.AllowDrop=2048]="AllowDrop",n[n.Inherit=78]="Inherit",n[n.ResizeNorthEast=4096]="ResizeNorthEast",n[n.ResizeEast=8192]="ResizeEast",n[n.ResizeSouthEast=16384]="ResizeSouthEast",n[n.ResizeSouth=32768]="ResizeSouth",n[n.ResizeSouthWest=65536]="ResizeSouthWest",n[n.ResizeWest=131072]="ResizeWest",n[n.ResizeNorthWest=262144]="ResizeNorthWest",n[n.ResizeNorth=524288]="ResizeNorth",n[n.Resize=1044480]="Resize",n[n.AspectRatio=1048576]="AspectRatio",n[n.Tooltip=2097152]="Tooltip",n[n.InheritTooltip=4194304]="InheritTooltip",n[n.ReadOnly=8388608]="ReadOnly",n[n.HideThumbs=16777216]="HideThumbs",n[n.AllowMovingOutsideLane=33554432]="AllowMovingOutsideLane",n[n.Default=5240814]="Default",n}(ie||{}),Xr=function(n){return n[n.None=0]="None",n[n.ElementIsPort=2]="ElementIsPort",n[n.ElementIsGroup=4]="ElementIsGroup",n[n.HorizontalLaneHeader=8]="HorizontalLaneHeader",n}(Xr||{}),bt=function(n){return n[n.Rotate=2]="Rotate",n[n.ConnectorSource=4]="ConnectorSource",n[n.ConnectorTarget=8]="ConnectorTarget",n[n.ResizeNorthEast=16]="ResizeNorthEast",n[n.ResizeEast=32]="ResizeEast",n[n.ResizeSouthEast=64]="ResizeSouthEast",n[n.ResizeSouth=128]="ResizeSouth",n[n.ResizeSouthWest=256]="ResizeSouthWest",n[n.ResizeWest=512]="ResizeWest",n[n.ResizeNorthWest=1024]="ResizeNorthWest",n[n.ResizeNorth=2048]="ResizeNorth",n[n.Default=4094]="Default",n}(bt||{}),rt=function(n){return n[n.None=1]="None",n[n.Bridging=2]="Bridging",n[n.UndoRedo=4]="UndoRedo",n[n.Tooltip=8]="Tooltip",n[n.UserInteraction=16]="UserInteraction",n[n.ApiUpdate=32]="ApiUpdate",n[n.PageEditable=48]="PageEditable",n[n.Zoom=64]="Zoom",n[n.PanX=128]="PanX",n[n.PanY=256]="PanY",n[n.Pan=384]="Pan",n[n.ZoomTextEdit=512]="ZoomTextEdit",n[n.Virtualization=1024]="Virtualization",n[n.LineRouting=2048]="LineRouting",n[n.Default=500]="Default",n}(rt||{}),Ci=function(n){return n[n.None=0]="None",n[n.SingleSelect=1]="SingleSelect",n[n.MultipleSelect=2]="MultipleSelect",n[n.ZoomPan=4]="ZoomPan",n[n.DrawOnce=8]="DrawOnce",n[n.ContinuousDraw=16]="ContinuousDraw",n[n.Default=3]="Default",n}(Ci||{}),Ya=function(n){return n[n.Self=1]="Self",n[n.Parent=2]="Parent",n}(Ya||{}),pt=function(n){return n[n.None=0]="None",n[n.Control=1]="Control",n[n.Meta=1]="Meta",n[n.Alt=2]="Alt",n[n.Shift=4]="Shift",n}(pt||{}),Mt=function(n){return n[n.None=null]="None",n[n.Number0=0]="Number0",n[n.Number1=1]="Number1",n[n.Number2=2]="Number2",n[n.Number3=3]="Number3",n[n.Number4=4]="Number4",n[n.Number5=5]="Number5",n[n.Number6=6]="Number6",n[n.Number7=7]="Number7",n[n.Number8=8]="Number8",n[n.Number9=9]="Number9",n[n.A=65]="A",n[n.B=66]="B",n[n.C=67]="C",n[n.D=68]="D",n[n.E=69]="E",n[n.F=70]="F",n[n.G=71]="G",n[n.H=72]="H",n[n.I=73]="I",n[n.J=74]="J",n[n.K=75]="K",n[n.L=76]="L",n[n.M=77]="M",n[n.N=78]="N",n[n.O=79]="O",n[n.P=80]="P",n[n.Q=81]="Q",n[n.R=82]="R",n[n.S=83]="S",n[n.T=84]="T",n[n.U=85]="U",n[n.V=86]="V",n[n.W=87]="W",n[n.X=88]="X",n[n.Y=89]="Y",n[n.Z=90]="Z",n[n.Left=37]="Left",n[n.Up=38]="Up",n[n.Right=39]="Right",n[n.Down=40]="Down",n[n.Escape=27]="Escape",n[n.Space=32]="Space",n[n.PageUp=33]="PageUp",n[n.PageDown=34]="PageDown",n[n.End=35]="End",n[n.Home=36]="Home",n[n.Delete=46]="Delete",n[n.Tab=9]="Tab",n[n.Enter=13]="Enter",n[n.BackSpace=8]="BackSpace",n[n.F1=112]="F1",n[n.F2=113]="F2",n[n.F3=114]="F3",n[n.F4=115]="F4",n[n.F5=116]="F5",n[n.F6=117]="F6",n[n.F7=118]="F7",n[n.F8=119]="F8",n[n.F9=120]="F9",n[n.F10=121]="F10",n[n.F11=122]="F11",n[n.F12=123]="F12",n[n.Star=56]="Star",n[n.Plus=187]="Plus",n[n.Minus=189]="Minus",n[n.BracketLeft=219]="BracketLeft",n[n.BracketRight=221]="BracketRight",n}(Mt||{}),ee=function(n){return n[n.Render=2]="Render",n[n.PublicMethod=4]="PublicMethod",n[n.ToolAction=8]="ToolAction",n[n.UndoRedo=16]="UndoRedo",n[n.TextEdit=32]="TextEdit",n[n.Group=64]="Group",n[n.Clear=128]="Clear",n[n.PreventClearSelection=256]="PreventClearSelection",n[n.Interactions=512]="Interactions",n[n.PreventHistory=1024]="PreventHistory",n[n.PreventIconsUpdate=2048]="PreventIconsUpdate",n[n.PreventCollectionChangeOnDragOver=4096]="PreventCollectionChangeOnDragOver",n[n.PreventZIndexOnDragging=8192]="PreventZIndexOnDragging",n[n.isGroupDragging=16384]="isGroupDragging",n[n.DragUsingMouse=32768]="DragUsingMouse",n[n.DecoratorPropertyChange=65536]="DecoratorPropertyChange",n[n.PreventLaneContainerUpdate=131072]="PreventLaneContainerUpdate",n}(ee||{}),Qa=function(n){return n[n.None=2]="None",n[n.DrawSelectorBorder=4]="DrawSelectorBorder",n[n.PreventRenderSelector=8]="PreventRenderSelector",n}(Qa||{}),$i=function(n){return n[n.None=0]="None",n[n.PreventDrag=2]="PreventDrag",n[n.PreventScale=4]="PreventScale",n[n.PreventDataInit=8]="PreventDataInit",n[n.hScrollbarMoved=16]="hScrollbarMoved",n[n.vScrollbarMoved=32]="vScrollbarMoved",n[n.AnimationClick=64]="AnimationClick",n[n.EnableGroupAction=128]="EnableGroupAction",n[n.PanInProgress=256]="PanInProgress",n[n.OverViewAction=512]="OverViewAction",n}($i||{}),ca=function(n){return n[n.None=0]="None",n[n.PropertyChange=1024]="PropertyChange",n[n.Interaction=2048]="Interaction",n}(ca||{}),Ae=function(n){return n[n.Zero=0]="Zero",n[n.One=1]="One",n[n.Two=2]="Two",n[n.Three=3]="Three",n[n.Four=4]="Four",n[n.Five=5]="Five",n}(Ae||{}),Ce=function(n){return n[n.collectionChange=0]="collectionChange",n[n.rotateChange=1]="rotateChange",n[n.positionChange=2]="positionChange",n[n.propertyChange=3]="propertyChange",n[n.selectionChange=4]="selectionChange",n[n.sizeChange=5]="sizeChange",n[n.drop=6]="drop",n[n.sourcePointChange=7]="sourcePointChange",n[n.targetPointChange=8]="targetPointChange",n[n.connectionChange=9]="connectionChange",n[n.animationComplete=10]="animationComplete",n[n.click=11]="click",n[n.doubleClick=12]="doubleClick",n[n.scrollChange=13]="scrollChange",n[n.dragEnter=14]="dragEnter",n[n.dragLeave=15]="dragLeave",n[n.dragOver=16]="dragOver",n[n.textEdit=17]="textEdit",n[n.paletteSelectionChange=18]="paletteSelectionChange",n[n.historyChange=19]="historyChange",n[n.mouseEnter=20]="mouseEnter",n[n.mouseLeave=21]="mouseLeave",n[n.mouseOver=22]="mouseOver",n[n.expandStateChange=23]="expandStateChange",n[n.segmentCollectionChange=24]="segmentCollectionChange",n[n.commandExecute=25]="commandExecute",n[n.historyStateChange=26]="historyStateChange",n[n.onUserHandleMouseDown=27]="onUserHandleMouseDown",n[n.onUserHandleMouseUp=28]="onUserHandleMouseUp",n[n.onUserHandleMouseEnter=29]="onUserHandleMouseEnter",n[n.onUserHandleMouseLeave=30]="onUserHandleMouseLeave",n[n.onImageLoad=31]="onImageLoad",n[n.onDoBindingInit=32]="onDoBindingInit",n[n.keyUp=33]="keyUp",n[n.keyDown=34]="keyDown",n[n.fixedUserHandleClick=35]="fixedUserHandleClick",n[n.elementDraw=36]="elementDraw",n[n.mouseWheel=37]="mouseWheel",n[n.segmentChange=38]="segmentChange",n[n.onFixedUserHandleMouseDown=39]="onFixedUserHandleMouseDown",n[n.onFixedUserHandleMouseUp=40]="onFixedUserHandleMouseUp",n[n.onFixedUserHandleMouseEnter=41]="onFixedUserHandleMouseEnter",n[n.onFixedUserHandleMouseLeave=42]="onFixedUserHandleMouseLeave",n[n.loaded=43]="loaded",n}(Ce||{}),ni=function(n){return n[n.None=1]="None",n[n.Drag=2]="Drag",n[n.Draw=4]="Draw",n[n.InConnect=8]="InConnect",n[n.OutConnect=16]="OutConnect",n[n.ToolTip=32]="ToolTip",n[n.InheritTooltip=64]="InheritTooltip",n[n.Default=24]="Default",n}(ni||{}),bx=function(n){return n[n.None=1]="None",n[n.Source=2]="Source",n[n.Target=4]="Target",n[n.Intermediate=8]="Intermediate",n[n.All=14]="All",n}(bx||{}),mI=function(n){return n[n.None=0]="None",n[n.SymmetricAngle=2]="SymmetricAngle",n[n.SymmetricDistance=4]="SymmetricDistance",n[n.Default=6]="Default",n}(mI||{}),as=function(){function n(){this.pivot={x:.5,y:.5},this.isDirt=!0,this.isExport=!1,this.exportScaleValue={x:0,y:0},this.exportScaleOffset={x:0,y:0},this.canApplyStyle=!0,this.visible=!0,this.offsetX=0,this.offsetY=0,this.cornerRadius=0,this.minHeight=void 0,this.minWidth=void 0,this.maxWidth=void 0,this.maxHeight=void 0,this.width=void 0,this.height=void 0,this.rotateAngle=0,this.margin={left:0,right:0,top:0,bottom:0},this.connectionDirection="Auto",this.horizontalAlignment="Auto",this.verticalAlignment="Auto",this.flip="None",this.flipMode="All",this.relativeMode="Point",this.transform=Ya.Self|Ya.Parent,this.style={fill:"white",strokeColor:"black",opacity:1,strokeWidth:1},this.desiredSize=new me,this.actualSize=new me,this.parentTransform=0,this.preventContainer=!1,this.isSvgRender=!1,this.bounds=new Ne(0,0,0,0),this.shadow=null,this.description="",this.staticSize=!1,this.shapeType="",this.isRectElement=!1,this.isCalculateDesiredSize=!0,this.flipOffset={x:0,y:0},this.elementActions=Xr.None,this.inversedAlignment=!0,this.position=void 0,this.unitMode=void 0,this.float=!1,this.floatingBounds=void 0}return n.prototype.setOffsetWithRespectToBounds=function(t,e,i){this.unitMode=i,this.position={x:t,y:e}},n.prototype.getAbsolutePosition=function(t){if(void 0!==this.position)return"Absolute"===this.unitMode?this.position:{x:this.position.x*t.width,y:this.position.y*t.height}},Object.defineProperty(n.prototype,"outerBounds",{get:function(){return this.floatingBounds||this.bounds},set:function(t){this.floatingBounds=t},enumerable:!0,configurable:!0}),n.prototype.measure=function(t,e,i){var s=void 0!==this.height?this.height:(t.height||0)-this.margin.top-this.margin.bottom;return this.id&&0===s&&this.elementActions&Xr.HorizontalLaneHeader&&(s=this.actualSize.height),this.desiredSize=new me(void 0!==this.width?this.width:(t.width||0)-this.margin.left-this.margin.right,s),this.isCalculateDesiredSize&&(this.desiredSize=this.validateDesiredSize(this.desiredSize,t)),this.desiredSize},n.prototype.arrange=function(t){return this.actualSize=t,this.updateBounds(),this.actualSize},n.prototype.updateBounds=function(){this.bounds=yr(this)},n.prototype.validateDesiredSize=function(t,e){return this.isRectElement&&!this.width&&!this.minWidth&&!this.maxWidth&&(t.width=50),this.isRectElement&&!this.height&&!this.minHeight&&!this.maxHeight&&(t.height=50),(void 0===t||void 0!==this.width&&void 0!==this.height)&&((t=t||new me).width=void 0===this.width?(e.width||0)-this.margin.left-this.margin.right:this.width,t.height=void 0===this.height?(e.height||0)-this.margin.top-this.margin.bottom:this.height),void 0!==this.minWidth&&(t.width=Math.max(t.width,this.minWidth)),void 0!==this.minHeight&&(t.height=Math.max(t.height,this.minHeight)),void 0!==this.maxWidth&&0!==this.maxWidth&&(t.width=Math.min(t.width,this.maxWidth)),void 0!==this.maxHeight&&0!==this.maxHeight&&(t.height=Math.min(t.height,this.maxHeight)),t},n}(),Vie=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Cs=function(n){function t(){var e=null!==n&&n.apply(this,arguments)||this;return e.padding=new Pie(0,0,0,0),e.desiredBounds=void 0,e.measureChildren=!0,e.prevRotateAngle=0,e}return Vie(t,n),t.prototype.hasChildren=function(){return void 0!==this.children&&this.children.length>0},t.prototype.measure=function(e,i,r){this.desiredBounds=void 0;var o,a,s=void 0;if(this.hasChildren()){for(var l=0;l=n.width&&s.length>0)i[i.length]={text:s,x:0,dy:0,width:o},s="";else{(s+=a[r+1]||"").indexOf("\n")>-1&&(i[i.length]={text:s,x:0,dy:0,width:Bc(s,n)},s="");var l=Bc(s,n);Math.ceil(l)+2>=n.width&&s.length>0&&(i[i.length]={text:s,x:0,dy:0,width:l},s=""),r===a.length-1&&s.length>0&&(i[i.length]={text:s,x:0,dy:0,width:l},s="")}else i=function loe(n,t,e){var c,d,u,p,i=[],r="",s=0,o=0,a="nowrap"!==n.whiteSpace,h=(t||n.content).split("\n");for(s=0;s0?" ":"")+c[parseInt(o.toString(),10)];var f=Bc(d=c[o+1]?r+" "+c[o+1]:r,n);Math.floor(f)>(e||n.width)-2&&r.length>0?(i[i.length]={text:r,x:0,dy:0,width:d===r?f:r===p?u:Bc(r,n)},r=""):o===c.length-1&&(i[i.length]={text:r,x:0,dy:0,width:f},r=""),p=d,u=f}return i}(n,t,e);else i[i.length]={text:a,x:0,dy:0,width:Bc(a,n)};return i}(l,r,n.isLaneOrientation?i:void 0),n.wrapBounds=a=function hoe(n,t){var r,s,e={x:0,width:0},i=0;for(i=0;in.width&&("Ellipsis"===n.textOverflow||"Clip"===n.textOverflow)?0:-r/2:"right"===n.textAlign?-r:t.length>1?0:-r/2,t[parseInt(i.toString(),10)].dy=1.2*n.fontSize,t[parseInt(i.toString(),10)].x=r,e.x=Math.min(e.x,r),e.width=Math.max(e.width,s);return e}(l,o),s.width=a.width,n.wrapBounds.width>=i&&"Wrap"!==l.textOverflow&&(s.width=i),s.height=o.length*n.style.fontSize*1.2,s}(this,0,0,this.isLaneOrientation?e.height:this.width||e.width):this.desiredSize,this.desiredSize=void 0===this.width||void 0===this.height?new me(i.width,i.height):new me(this.width,this.height),this.desiredSize=this.validateDesiredSize(this.desiredSize,e),this.desiredSize},t.prototype.arrange=function(e){return(e.width!==this.actualSize.width||e.height!==this.actualSize.height||this.isDirt)&&(this.doWrap=!0),this.actualSize=e,this.updateBounds(),this.isDirt=!1,this.actualSize},t}(as),Yie=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Ii=function(n){function t(){var e=null!==n&&n.apply(this,arguments)||this;return e.measureChildren=void 0,e}return Yie(t,n),t.prototype.measure=function(e,i,r){var s=void 0,o=void 0;if(this.hasChildren()){for(var a=0,l=this.children;a=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Ed=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return $ie(t,n),Th([I("")],t.prototype,"content",void 0),Th([I("TopLeft")],t.prototype,"position",void 0),Th([I("Mouse")],t.prototype,"relativeMode",void 0),Th([I(!0)],t.prototype,"showTipPointer",void 0),Th([I("auto")],t.prototype,"width",void 0),Th([I("auto")],t.prototype,"height",void 0),Th([I("Auto")],t.prototype,"openOn",void 0),Th([I()],t.prototype,"animation",void 0),Th([I(!1)],t.prototype,"isSticky",void 0),t}(Ee);function i3(n){var t=new mh;t=r3(n.tooltip,t);var e=new mh(t);return e.beforeCollision=Jie,e.beforeOpen=Zie,e.cssClass="e-diagram-tooltip",e.opensOn="custom",e.appendTo("#"+n.element.id),e.close(),e}function Zie(n){(""===this.content||void 0===this.content)&&(n.element.style.display="none")}function Jie(n){n.collidedPosition&&n.collidedPosition!==this.position&&(n.element.style.display="none")}function Mx(n,t){var e=n.tooltipObject;return r3(t?t.tooltip:n.tooltip,e),e}function r3(n,t){return n.content?(t.content=n.content,"string"==typeof n.content&&(t.content=ko(function(){return n.content})),t.position=n.position,t.showTipPointer=n.showTipPointer,t.width=n.width,t.height=n.height,t.animation=n.animation?n.animation:{close:{effect:"None"}}):t.close(),t}var wx=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Hn=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Cx=function(n){function t(e,i,r,s){var o=n.call(this,e,i,r,s)||this;return o.inEdges=[],o.outEdges=[],o}return wx(t,n),Hn([I("")],t.prototype,"id",void 0),Hn([I("Center")],t.prototype,"horizontalAlignment",void 0),Hn([I("Center")],t.prototype,"verticalAlignment",void 0),Hn([re({},$n)],t.prototype,"margin",void 0),Hn([I(12)],t.prototype,"width",void 0),Hn([I(12)],t.prototype,"height",void 0),Hn([re({},Al)],t.prototype,"style",void 0),Hn([I("Square")],t.prototype,"shape",void 0),Hn([I("Auto")],t.prototype,"connectionDirection",void 0),Hn([I(Gt.Connect)],t.prototype,"visibility",void 0),Hn([I("")],t.prototype,"pathData",void 0),Hn([I(ni.Default)],t.prototype,"constraints",void 0),Hn([I()],t.prototype,"addInfo",void 0),Hn([I()],t.prototype,"outEdges",void 0),Hn([I()],t.prototype,"inEdges",void 0),Hn([re({},Ed)],t.prototype,"tooltip",void 0),t}(Ee),Es=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return wx(t,n),t.prototype.getClassName=function(){return"PointPort"},Hn([re({x:.5,y:.5},z)],t.prototype,"offset",void 0),t}(Cx),xc=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return wx(t,n),t.prototype.getClassName=function(){return"PathPort"},Hn([I(.5)],t.prototype,"offset",void 0),Hn([re({x:0,y:0},z)],t.prototype,"displacement",void 0),Hn([I("Center")],t.prototype,"alignment",void 0),t}(Cx),II=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),lr=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Kie=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return II(t,n),lr([I("blue")],t.prototype,"color",void 0),lr([I("")],t.prototype,"content",void 0),lr([I("")],t.prototype,"link",void 0),lr([I("None")],t.prototype,"textDecoration",void 0),lr([I("NewTab")],t.prototype,"hyperlinkOpenState",void 0),t}(Ee),Ex=function(n){function t(e,i,r,s){var o=n.call(this,e,i,r,s)||this;return r.id||(o.id=e.parentObj&&e.parentObj.propName&&"phases"===e.parentObj.propName?e.parentObj.id:Qe()),o}return II(t,n),lr([I("")],t.prototype,"content",void 0),lr([I(void 0)],t.prototype,"template",void 0),lr([I("String")],t.prototype,"annotationType",void 0),lr([I(!0)],t.prototype,"visibility",void 0),lr([I(Lr.InheritReadOnly)],t.prototype,"constraints",void 0),lr([re(void 0,Kie)],t.prototype,"hyperlink",void 0),lr([I("")],t.prototype,"id",void 0),lr([I()],t.prototype,"width",void 0),lr([I()],t.prototype,"height",void 0),lr([I(0)],t.prototype,"rotateAngle",void 0),lr([I("Parent")],t.prototype,"rotationReference",void 0),lr([re({strokeWidth:0,strokeColor:"transparent",fill:"transparent"},Yp)],t.prototype,"style",void 0),lr([I("Center")],t.prototype,"horizontalAlignment",void 0),lr([I("Center")],t.prototype,"verticalAlignment",void 0),lr([re({},$n)],t.prototype,"margin",void 0),lr([re({top:void 0,bottom:void 0,left:void 0,right:void 0},$n)],t.prototype,"dragLimit",void 0),lr([I("Shape")],t.prototype,"type",void 0),lr([re({},Ed)],t.prototype,"tooltip",void 0),lr([I()],t.prototype,"addInfo",void 0),t}(Ee),Zn=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return II(t,n),t.prototype.getClassName=function(){return"ShapeAnnotation"},lr([re({x:.5,y:.5},z)],t.prototype,"offset",void 0),t}(Ex),Nr=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return II(t,n),t.prototype.getClassName=function(){return"PathAnnotation"},lr([I(.5)],t.prototype,"offset",void 0),lr([re({x:0,y:0},z)],t.prototype,"displacement",void 0),lr([I("Center")],t.prototype,"alignment",void 0),lr([I(!1)],t.prototype,"segmentAngle",void 0),t}(Ex);function Dx(n){return rre[n.toString()]}function n3(n){return ore[""+n]}var rre={X:"M14,14 L106,106 M106,14 L14,106",Circle:"M0,50 A50,50,0 1 1 100,50 A50,50,0 1 1 0,50 Z",Square:"M0,0 L10,0 L10,10 L0,10 z"},nre={OpenArrow:"M15.9,23 L5,16 L15.9,9 L17,10.7 L8.7,16 L17,21.3Z",Square:"M0,0 L10,0 L10,10 L0,10 z",Fletch:"M14.8,10c0,0-3.5,6,0.2,12c0,0-2.5-6-10.9-6C4.1,16,11.3,16,14.8,10z",OpenFetch:"M6,17c-0.6,0-1-0.4-1-1s0.4-1,1-1c10.9,0,11-5,11-5c0-0.6,0.4-1,1-1s1,0.4,1,1C19,10.3,18.9,17,6,17C6,17,6,17,6,17z M18,23c-0.5,0-1-0.4-1-1c0-0.2-0.3-5-11-5c-0.6,0-1-0.5-1-1s0.4-1,1-1c0,0,0,0,0,0c12.9,0,13,6.7,13,7 C19,22.6,18.6,23,18,23z",IndentedArrow:"M17,10c0,0-4.5,5.5,0,12L5,16L17,10z",OutdentedArrow:"M14.6,10c0,0,5.4,6,0,12L5,16L14.6,10z",DoubleArrow:"M19,10 L19,22 L13,16Z M12,10 L12,22 L6,16Z",Arrow:"M15,10 L15,22 L5,16Z",Diamond:"M12,23l-7-7l7-7l6.9,7L12,23z",Circle:"M0,50 A50,50,0 1 1 100,50 A50,50,0 1 1 0,50 Z"},sre={Square:"M0,0 L10,0 L10,10 L0,10 z",Rhombus:"M10,5 L5,10 L0,5 L5,0 L10,5 Z ",Rectangle:"M0,0 L15,0 L15,10 L0,10 z ",OpenArrow:"M15.9,23 L5,16 L15.9,9 L17,10.7 L8.7,16 L17,21.3Z",Fletch:"M9.82,0 C9.82,0,6.61,5,10,10 C10,10,7.71,5,0,5 C0,5,6.61,5,9.82,0 Z ",OpenFetch:"M0.71,5.71 C0.29,5.71,0,5.43,0,5 C0,4.57,0.29,4.29,0.71,4.29 C8.5,4.29,8.57,0.71,8.57,0.71 C8.57,0.29,8.86,0,9.29,0 C9.719999999999999,0,10,0.29,10,0.71 C10,0.93,9.93,5.71,0.71,5.71 C0.71,5.71,0.71,5.71,0.71,5.71 Z M9.29,10 C8.93,10,8.57,9.71,8.57,9.29 C8.57,9.14,8.36,5.71,0.71,5.71 C0.29,5.71,0,5.36,0,5 C0,4.64,0.29,4.29,0.71,4.29 C0.71,4.29,0.71,4.29,0.71,4.29 C9.93,4.29,10,9.07,10,9.29 C10,9.71,9.71,10,9.29,10 Z ",IndentedArrow:"M10,0 C10,0,6.25,4.58,10,10 L0,5 L10,0 Z ",OutdentedArrow:"M8,0 C8,0,12.5,5,8,10 L0,5 L8,0 Z ",DoubleArrow:"M19,10 L19,22 L13,16Z M12,10 L12,22 L6,16Z",Arrow:"M15,10 L15,22 L5,16Z",Diamond:"M10,5 L5,10 L0,5 L5,0 L10,5 Z ",Circle:"M10,5 C10,7.76,7.76,10,5,10 C2.24,10,0,7.76,0,5 C0,2.24,2.24,0,5,0 C7.76,0,10,2.24,10,5 Z ",Ellipse:"M15,5 C15,7.76,11.64,10,7.5,10 C3.36,10,0,7.76,0,5 C0,2.24,3.36,0,7.5,0 C11.64,0,15,2.24,15,5 Z "},ore={Square:"M0,0 L10,0 L10,10 L0,10 z",Rhombus:"M10,5 L5,10 L0,5 L5,0 L10,5 Z ",Rectangle:"M0,0 L15,0 L15,10 L0,10 z",OpenArrow:"M23,15.9 L16,5 L9,15.9 L10.7,17 L16,8.7 L21,17.3Z",Fletch:"M9.82,0 C9.82,0,6.61,5,10,10 C10,10,7.71,5,0,5 C0,5,6.61,5,9.82,0 Z ",OpenFetch:"M0.71,5.71 C0.29,5.71,0,5.43,0,5 C0,4.57,0.29,4.29,0.71,4.29 C8.5,4.29,8.57,0.71,8.57,0.71 C8.57,0.29,8.86,0,9.29,0 C9.719999999999999,0,10,0.29,10,0.71 C10,0.93,9.93,5.71,0.71,5.71 C0.71,5.71,0.71,5.71,0.71,5.71 Z M9.29,10 C8.93,10,8.57,9.71,8.57,9.29 C8.57,9.14,8.36,5.71,0.71,5.71 C0.29,5.71,0,5.36,0,5 C0,4.64,0.29,4.29,0.71,4.29 C0.71,4.29,0.71,4.29,0.71,4.29 C9.93,4.29,10,9.07,10,9.29 C10,9.71,9.71,10,9.29,10 Z ",IndentedArrow:"M10,0 C10,0,6.25,4.58,10,10 L0,5 L10,0 Z ",OutdentedArrow:"M8,0 C8,0,12.5,5,8,10 L0,5 L8,0 Z ",DoubleArrow:"M10,19 L22,19 L16,13Z M10,12 L22,12 L16,6Z",Arrow:"M10,15 L22,15 L16,5Z",Diamond:"M10,5 L5,10 L0,5 L5,0 L10,5 Z ",Circle:"M10,5 C10,7.76,7.76,10,5,10 C2.24,10,0,7.76,0,5 C0,2.24,2.24,0,5,0 C7.76,0,10,2.24,10,5 Z ",Ellipse:"M15,5 C15,7.76,11.64,10,7.5,10 C3.36,10,0,7.76,0,5 C0,2.24,3.36,0,7.5,0 C11.64,0,15,2.24,15,5 Z "};function xx(n){return are[n.toString()]}var are={Process:"M419.511,76.687L359.511,76.687L359.511,43.086L419.511,43.086z",Decision:"M 253.005,115.687L 200.567,146.071L 148.097,115.687L 200.534,85.304L 253.005,115.687 Z",Document:"M 60 31.9 c 0 0 -11 -7.7 -30 0 s -30 0 -30 0 V 0 h 60 V 31.9 Z",PreDefinedProcess:"M 0,0 L 50,0 L 50,50 L 0,50 Z M 8.334,0 L 8.334,50 M 41.667,0 L 41.667,50",Terminator:"M 269.711,29.33C 269.71,44.061 257.77,56 243.04,56L 158.058,56C 143.33,56 131.39,44.061 131.39,29.33L 131.39,29.33C 131.391,14.6057 143.33,2.669 158.058,2.669L 243.044,2.669C 257.772,2.669 269.711,14.6057 269.711,29.333 Z",PaperTap:"M0.0009,17.2042 L0.0009,47.165 C0.001,47.165 14.403,53.5455 25.00,47.165 C35.599,40.7852 44.403,43.5087 50.00,47.165L50.001,17.2042 M50.001,32.7987 L50.001,2.8405 C50.001,2.8405 35.599,-3.5427 25.001,2.8405C14.403,9.2237 5.599,6.494 0.0009,2.8405 L0.0009,32.7987",DirectData:"M 132.62 0 L 17.38 0 C 7.78 0 0 13.43 0 30 C 0 46.57 7.78 60 17.38 60 L 132.62 60 M 132.62 0C 123.02 0 115.24 13.43 115.24 30 C 115.24 46.57 123.02 60 132.62 60 C 142.22 60 150 46.57 150 30 C 150 13.43 142.22 0 132.62 0 z ",SequentialData:"M0.0029,24.999 C0.0029,11.1922 10.433,0.0021 23.295,0.0021 C36.159,0.00216 46.585,11.1922 46.585,24.999C46.585,38.8057 36.159,49.9979 23.295,49.9979 C10.433,49.9979 0.0029,38.8057 0.0029,24.999 z M23.294,49.999 L50.002,49.999",Sort:"M50.001,24.9971 L25.001,49.9971 L0.00097,24.9971 L25.001,-0.00286865 L50.001,24.9971 z M0.000976562,24.9971 L50.001,24.9971",MultiDocument:"M43.6826,40 C44.8746,40.6183 45.8586,41.3502 46.8366,42.1122 L46.8366,4.74487 L3.09857,4.74487 L3.09857,10.9544 M46.837,35.143 C48.027,35.765 49.025,36.604 50.003,37.369 L50.003,0.002 L6.264,0.002 L6.264,4.744 M43.682,47.113 L43.682,10.765 L0.0025,10.7652 L0.0025,47.1132 C0.0025,47.1132 12.5846,53.6101 21.8426,47.1132 C31.1006,40.6163 38.792,43.393 43.6826,47.1132 z",Collate:"M50.001,0.0028 L25.001,25.0029 L0.00097,0.0028 L50.001,0.002 z M0.0009,50.002 L25.001,25.002L50.001,50.002 L0.0009,50.0029 z",SummingJunction:"M7.3252,42.6768 L42.6772,7.3247 M42.6768,42.6768 L7.3248,7.3247 M0.0009,25.001 C0.0009,11.193 11.197,0.0009 25.001,0.0009 C38.809,0.0009 50.001,11.193 50.001,25.001 C50.001,38.809 38.809,50.001 25.001,50.001 C11.197,50.00 0.0009,38.809 0.0009,25.00 z",Or:"M 0 50 L 100 50 M 50 100 L 50 0.0 M 0 50 C 0 22.384 22.392 0 50 0 C 77.616 0 100 22.384 100 50 C 100 77.616 77.616 100 50 100 C 22.392 100 0 77.616 0 50 Z",InternalStorage:"M 0 3.81946A 2.5,3.81946 0 0,1 2.5,0L 47.5 0A 2.5,3.81946 0 0,1 50,3.81946L 50 45.836A 2.5,3.819446 0 0,1 47.5,49.652778L 2.5 49.652778A 2.5,3.819446 0 0,1 0,45.8336L 0 3.819446ZM 0 11.45834L 50 11.4583334M 12.5 0L 12.5 49.652778",Extract:"M0,35 L30,0 L60,35 Z",ManualOperation:"M46.4,28.8 L14.8,28.8 L0,0 L60,0 Z",Merge:"M60,0 L30,35 L0,0 Z",OffPageReference:"M60,33.3 L30.1,39 L0,33.3 L0,0 L60,0 Z",SequentialAccessStorage:"M 60 30 C 60 13.4 46.6 0 30 0 S 0 13.4 0 30 s 13.4 30 30 30 h 28.6 v -6.5 h -9.9C 55.5 48 60 39.5 60 30 Z",Annotation:"M49.9984,50.0029 L-0.00271199,50.0029 L-0.00271199,0.00286865 L49.9984,0.00286865",Annotation2:"M49.9977,50.0029 L25.416,50.0029 L25.416,0.00286865 L49.9977,0.00286865 M25.4166,25.0029 L-0.00227869,25.0029",Data:"M 10 0 L 40 0 L 30 40 L 0 40 Z",Card:"M275,60 L400,60 L400,110 L260,110 L260,75 Z",Delay:"M0,0 L12.029,0 C14.212999,0 16,1.7869979 16,3.9709952 C16,6.1549926 14.212999,7.9409904 12.029,7.9409904 L0,7.9409904 z",Preparation:"M 1048.17 572 C 1051.06 568.86 1055.17 567.05 1059.5 567 L 1094.51 567 C 1098.84 567.05 1102.95 568.86 1105.84 572 L 1126.43 595 C 1127.01 596.28 1127.01 597.72 1126.43 599 L 1105.84 622 C 1102.95 625.14 1098.84 626.95 1094.51 627 L 1059.5 627 C 1055.17 626.95 1051.06 625.14 1048.17 622 L 1027.58 599 C 1027 597.72 1027 596.28 1027.58 595 L 1048.17 572 Z",Display:"M47.8809,19.2914 L32.7968,-0.00594145 L11.3902,-0.00594145 C7.93166,-0.00594145 0.00124586,11.187 0.00124586,24.9968C0.00124586,38.8032 7.93166,49.9962 11.3902,49.9962 L32.7968,49.99 L47.615,31.038 C47.615,31.0388 52.798,24.9968 47.880,19.2914 z",ManualInput:"M 912 732 L 1006.85 707 C 1008.2 707 1009.5 707.53 1010.46 708.46 C 1011.41 709.4 1011.95 710.67 1011.95 712 L 1011.95 762C 1012 764.41 1010.28 766.52 1007.87 767 L 917.1 767 C 915.75 767 914.45 766.47 913.49 765.54 C 912.54 764.6 912 763.33 912 762 L 912 732 Z",LoopLimit:"M 8 9 L 27 9 L 33 15 L 33 26 C 33 27 33 27 32 27 L 4 27 C 3 27 2 27 2 26 L 2 15 L 8 9 Z",StoredData:"M 5.55 0L 50 0A 1.5,30 0 0,1 50,0A 5.555,25 0 0,0 50,50A 1.5,30 0 0,1 50,50L 5.555 50A 5.55,25 0 0,1 5.555,0Z"};function s3(n,t,e){var i;i="Straight"!==n.type&&n.sourceWrapper?n.sourceWrapper.corners.center:function lre(n){var t;if(n.sourcePortWrapper){var e=n.sourcePortWrapper;t={x:e.offsetX,y:e.offsetY}}else t=n.sourceID&&n.sourceWrapper&&n.targetWrapper?Ah(n,0,n.sourceWrapper.corners.center,n.targetWrapper.corners.center,!1):n.sourcePoint;return t}(n);var r=function cre(n,t,e,i,r){var b,M,s=n.sourceWrapper,o=n.targetWrapper,a=n.sourcePortWrapper,l=n.targetPortWrapper,d=[],f=Ga(n),y={corners:undefined,point:t,direction:undefined,margin:{left:5,right:5,bottom:5,top:5}},S={corners:undefined,point:e,direction:undefined,margin:{left:5,right:5,bottom:5,top:5}};if(void 0!==s&&void 0!==o&&(b=En(s),M=En(o),y.corners=s.corners,S.corners=o.corners),void 0!==a&&(y.direction="Left"===a.connectionDirection||"Top"===a.connectionDirection||"Bottom"===a.connectionDirection||"Right"===a.connectionDirection?a.connectionDirection:zo({x:a.offsetX,y:a.offsetY},b,s.bounds)),void 0!==l&&(S.direction="Left"===l.connectionDirection||"Right"===l.connectionDirection||"Bottom"===l.connectionDirection||"Top"===l.connectionDirection?l.connectionDirection:zo({x:l.offsetX,y:l.offsetY},M,o.bounds)),"Bezier"===n.type&&!n.isBezierEditing&&n.segments.length>0)for(var D=n.segments.length-1;D>=0;)n.segments[parseInt(D.toString(),10)].isInternalSegment&&n.segments.pop(),D--;if(void 0!==s&&void 0!==o)return(void 0===y.direction||void 0===S.direction)&&(i?function hre(n,t,e){"LeftToRight"===e?(n.direction=n.direction?n.direction:"Right",t.direction=t.direction?t.direction:"Left"):"RightToLeft"===e?(n.direction=n.direction?n.direction:"Left",t.direction=t.direction?t.direction:"Right"):"TopToBottom"===e?(n.direction=n.direction?n.direction:"Bottom",t.direction=t.direction?t.direction:"Top"):"BottomToTop"===e&&(n.direction=n.direction?n.direction:"Top",t.direction=t.direction?t.direction:"Bottom")}(y,S,i):y.corners.top>S.corners.bottom&&Math.abs(y.corners.top-S.corners.bottom)>f?(y.direction=y.direction?y.direction:"Top",S.direction=S.direction?S.direction:"Bottom"):y.corners.bottomf?(y.direction=y.direction?y.direction:"Bottom",S.direction=S.direction?S.direction:"Top"):y.corners.rightf||y.corners.right+f=y.corners.left-f&&y.corners.left>S.corners.left?(y.direction=y.direction?y.direction:"Right",S.direction=S.direction?S.direction:"Left"):y.corners.left>S.corners.right&&Math.abs(y.corners.left-S.corners.right)>y.margin.left+y.margin.right||S.corners.right+f=S.corners.left-f&&y.corners.left0&&n.segments[0].direction&&(y.direction=n.segments[0].direction),y.point=Tc(b,y.direction),d=Tc(b,ls(y.direction)),y.point=Ah(n,0,y.point,d,!1)):y.point=o.corners.center;if(void 0!==h){switch(S.point={x:h.offsetX,y:h.offsetY},S.direction){case"Bottom":case"Top":S.point.y=S.point.y;break;case"Left":case"Right":S.point.x=S.point.x}n.targetPadding&&!w&&(S.point=bI(n,y,S,!0))}else"Orthogonal"===n.type||"Bezier"===n.type?(S.point=Tc(M,S.direction),d=Tc(M,ls(S.direction)),S.point=Ah(n,0,S.point,d,!0)):S.point=a.corners.center;if("Orthogonal"!==n.type){var C=void 0,D=void 0;if("Bezier"===n.type){if(n.bezierSettings.allowSegmentsReset||0===n.segments.length||!z.isEmptyPoint(n.segments[n.segments.length-1].point))return c=g3(n,y,S,void 0,s),Tx(n,y,S);Bv(n)}else Bv(n);if(void 0===n.sourcePortWrapper){y.point=y.corners.center,n.segments&&n.segments.length>0&&(C=z.isEmptyPoint((D=n.segments[0]).point)?void 0:D);var A=void 0!==C?C.point:S.point;if("Bezier"===n.type&&n.segments.length>0&&n.segments[0].vector1.angle&&n.segments[0].vector1.distance){var x=Math.max(y.corners.width,y.corners.height);A=z.transform(y.point,n.segments[0].vector1.angle,x/2)}y.point=w?n.sourceWrapper.bounds.center:Ah(n,0,y.point,A,!1)}if(void 0===n.targetPortWrapper){S.point=S.corners.center,n.segments&&n.segments.length>1&&(C=z.isEmptyPoint((D=n.segments[n.segments.length-2]).point)?void 0:D);var R=C?C.point:y.point;"Bezier"===n.type&&n.segments.length>0&&n.segments[n.segments.length-1].vector2.angle&&n.segments[n.segments.length-1].vector2.distance&&(x=Math.max(y.corners.width,y.corners.height),R=z.transform(S.point,n.segments[0].vector2.angle,x/2)),S.point=w?n.targetWrapper.bounds.center:Ah(n,0,R,S.point,!0)}c=Tx(n,y,S)}else"Orthogonal"===n.type&&n.segments&&n.segments.length>0&&null!==n.segments[0].direction?c=function Ire(n,t,e,i,r,s,o){var a,h,c,d;Bv(n);for(var u=0;u0&&n.segments[u-1].direction===h.direction?u=u3(n,u,t):h.direction?t.point=o3(t,n.segments[parseInt(u.toString(),10)]):(p=n.segments[u-1])&&p.points&&(t.point=p.points[p.points.length-1]),u===n.segments.length-1)if(p3(n,t),c3(a=void 0===r?Sre(n,t,e):l3(n,t,e),n),h.points=[],a.length>=2)for(c=0;c2&&n.segments.length>2){var f={x:a[parseInt(c.toString(),10)].x,y:t.point.y};h.points=[],h.points.push(f),h.points.push(a[parseInt(c.toString(),10)]);var p=n.segments[u-1];n.segments.length<4&&p.points.pop(),p.points=p.points.concat(h.points)}else h.points.push(a[parseInt(c.toString(),10)]);else h.points.push(a[parseInt(c.toString(),10)]);else d=u;if(void 0!==d&&!n.selectedSegmentIndex&&(d===n.segments.length-1&&(n.segments[d-1].direction=null,n.segments[d-1].length=null),n.segments.splice(d,1)),i&&0===u){var g=h3(n,i,s);g&&(t.point=g)}}return f3(n,[])}(n,y,S,l,h,o):(n.segments[0]||(C=new bi(n,"segments",{type:"Orthogonal"},!0),n.segments.push(C)),n.segments[0].points=c=g3(n,y,S,void 0,s));return c}(n,y.direction,S.direction,y.point,S.point,r);if(Bv(n),(n.sourceWrapper||n.targetWrapper)&&function gre(n,t,e){var i=n.sourcePortWrapper,r=n.targetPortWrapper,s=n.sourceWrapper,o=t.point,a={left:0,right:0,top:0,bottom:0},l={x:0,y:0},c="Top";if(s?(o=e.point,a=t.margin):(s=n.targetWrapper,a=e.margin),"Orthogonal"===n.type)if(n.segments&&n.segments.length>0&&n.sourceWrapper&&n.segments[0].direction)t.direction=n.segments[0].direction,l=Ah(n,0,l=Tc(s.corners,t.direction),Tc(s.corners,ls(t.direction)),!1);else{var u={corners:null,direction:null,point:null,margin:null};Fv(s,{corners:null,direction:null,point:o,margin:a},u,n),l=u.point,c=u.direction}else{var p=void 0;n.segments&&n.segments.length>1&&(p=s===n.sourceWrapper?n.segments[0].point:n.segments[n.segments.length-2].point),l=Ah(n,0,s.bounds.center,n.segments&&n.segments.length>1?p:o,s===n.targetWrapper)}s===n.sourceWrapper?(t.direction=t.direction||c,t.point=l,n.sourcePortWrapper&&(t.point={x:i.offsetX,y:i.offsetY},n.sourcePadding&&(t.point=bI(n,t,e,!1)))):(e.direction=e.direction||c,e.point=l,n.targetPortWrapper&&(e.point={x:r.offsetX,y:r.offsetY},n.targetPadding&&(e.point=bI(n,t,e,!0))))}(n,y,S),"Straight"===n.type||"Bezier"===n.type)d=Tx(n,y,S);else if("Orthogonal"===n.type&&n.segments&&n.segments.length>0&&null!==n.segments[0].length&&null!==n.segments[0].direction)d=function fre(n,t,e,i,r,s,o){var a,l,c,u,h=[];if(Bv(n),n.segments.length>0){for(var p=0;p0&&n.segments[p-1].direction===f.direction)p=u3(n,p,t);else{var g=n.segments[p-1];t.point=f.direction?o3(t,f):g.points[g.points.length-1]}if(p===n.segments.length-1&&(o||r?n.targetWrapper&&void 0===n.targetPortWrapper?(p3(n,t),l=ure(n,t,e)):l=l3(n,t,e):l=dre(n,t,e),l))if(c3(l,n),f.points=[],l.length>=2)for(a=0;at.corners.top&&e.point.ye.point.x?"Left":"Right"):e.point.x>t.corners.left&&e.point.xe.point.y?"Top":"Bottom")),n.sourcePortWrapper&&s===ls(r)?(("Left"===s||"Right"===s)&&t.point.y>=t.corners.top&&t.point.y<=t.corners.center.y&&e.point.y>=t.corners.top&&e.point.y<=t.corners.center.y?(t.direction="Top",a=t.point.y-t.corners.top+20):("Left"===s||"Right"===s)&&t.point.y>t.corners.center.y&&t.point.y<=t.corners.bottom&&e.point.y>t.corners.center.y&&e.point.y<=t.corners.bottom?(t.direction="Bottom",a=t.corners.bottom-t.point.y+20):("Top"===s||"Bottom"===s)&&t.point.x>=t.corners.left&&t.point.x<=t.corners.center.x&&e.point.x>=t.corners.left&&e.point.x<=t.corners.center.x?(t.direction="Left",a=t.point.x-t.corners.left+20):("Top"===s||"Bottom"===s)&&t.point.x<=t.corners.right&&t.point.x>t.corners.center.x&&e.point.x<=t.corners.right&&e.point.xt.point.y&&t.point.y>=e.corners.top?(i="Top",r=t.point.y-e.corners.top+20):e.corners.center.y===t.point.y&&"Top"===n.segments[n.segments.length-2].direction||e.corners.center.ye.point.y?t.point.y-t.corners.top+20:t.corners.bottom-t.point.y+20):(i="Top",r=e.corners.height/2+20):e.corners.center.x!==t.point.x||e.corners.topt.point.x&&t.point.x>=e.corners.left?(i="Left",r=t.point.x-e.corners.left+20):e.corners.center.x===t.point.x&&"Left"===n.segments[n.segments.length-2].direction||e.corners.center.x<=t.point.x&&t.point.x<=e.corners.right?(i="Right",r=e.corners.right-t.point.x+20):void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&t.corners.left<=t.point.x&&t.point.x<=t.corners.right&&(i=t.direction,r=t.point.x>e.point.x?t.point.x-t.corners.left+20:t.corners.right-t.point.x+20):(i="Left",r=e.corners.width/2+20);var a=t.point;t.point=Bn(t.point,"Left"===i||"Top"===i?-r:r,"Left"===i||"Right"===i?0:90),t.direction=z.direction(t.point,e.point),void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&(t.corners.center.x===e.corners.center.x||t.corners.center.y===e.corners.center.y)&&(t.direction=e.direction);var l=Ys(n,t,e);return l.splice(0,0,a),l}function l3(n,t,e){var i,r;e.corners=n.targetWrapper.corners,void 0!==n.sourcePortWrapper&&(r=zo({x:n.sourcePortWrapper.offsetX,y:n.sourcePortWrapper.offsetY},En(n.sourceWrapper),n.sourceWrapper.bounds));var a=function pre(n,t,e,i){var r=!1;switch(e.direction){case"Left":void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&"Right"===i&&t.point.x>e.point.x&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom||("Bottom"===i&&t.point.y>e.point.y||"Top"===i&&t.point.y=t.corners.left&&t.point.x<=t.corners.right?(t.direction="Right"===i?t.point.y>e.point.y?"Top":"Bottom":t.point.xe.point.x&&(t.point.y>e.point.y||t.point.yt.point.y&&e.corners.bottome.point.y||t.point.x>e.point.x&&t.point.y<=e.point.y&&e.corners.top=t.point.y?t.direction="Top":t.point.xe.point.x&&t.point.y>e.point.y&&e.corners.bottomt.point.y?t.direction="Bottom":t.point.y===e.point.y&&t.point.xe.point.y||"Top"===i&&t.point.ye.point.x&&t.point.x>=t.corners.left&&t.point.x<=t.corners.right?(t.direction=t.point.x>e.point.x?"Left":"Right",r=!0):void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&"Left"===i&&t.point.x=t.corners.top&&t.point.y<=t.corners.bottom?(t.direction=t.point.y>e.point.y?"Top":"Bottom",r=!0):t.point.x=t.point.y&&t.point.y===e.point.y||t.point.y>e.point.y&&t.point.x>e.point.x?t.direction="Top":t.point.ye.point.x?t.direction="Bottom":t.point.xe.point.y||t.point.ye.point.x&&(t.direction="Left");break;case"Top":void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&"Bottom"===i&&t.point.y>e.point.y&&t.point.x>=t.corners.left&&t.point.x<=t.corners.right||("Right"===i&&t.point.x>e.point.x||"Left"===i&&e.point.y>t.point.y&&e.point.x>t.point.x)&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom?(t.direction="Bottom"===i?t.point.x>e.point.x?"Left":"Right":t.point.ye.point.y&&t.point.x>e.corners.left&&t.point.x=e.point.y?t.direction="Top":t.point.ye.point.x?t.direction="Left":t.point.yt.point.x)&&t.point.y>e.point.y&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom||"Top"===i&&t.point.y=t.corners.left&&t.point.x<=t.corners.right)?(t.direction="Right"===i||"Left"===i?t.point.y>e.point.y?"Top":"Bottom":t.point.x>e.point.x?"Left":"Right",r=!0):t.point.ye.corners.left&&e.corners.right>t.point.x?t.point.ye.corners.left&&e.corners.center.x>=t.point.x?t.direction="Left":t.point.ye.point.y&&t.point.x>e.point.x?t.direction="Left":t.point.y>e.point.y&&t.point.xe.point.x||e.point.x>t.point.x)&&(t.direction="Bottom")}return r}(n,t,e,r);return!n.selectedSegmentIndex&&void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&e.direction===ls(r)&&(("Left"===e.direction&&t.point.x>e.point.x||"Right"===e.direction&&t.point.x=t.corners.top&&t.point.y<=t.corners.bottom||"Bottom"===e.direction&&t.point.y=t.corners.left&&t.point.x<=t.corners.right)?i=a3(n,t,e):n.selectedSegmentIndex||t.direction!==e.direction?!n.selectedSegmentIndex&&("Left"===e.direction&&t.point.x>e.point.x||"Right"===e.direction&&t.point.x=t.point.y||"Top"===e.direction&&t.point.y>e.point.y||"Bottom"===e.direction&&t.point.y=t.point.x?i=n.selectedSegmentIndex?Ll(t,e):a3(n,t,e):!n.selectedSegmentIndex&&void 0!==n.sourceWrapper&&void 0!==n.targetWrapper&&void 0!==n.targetPortWrapper&&("Left"===t.direction||"Right"===t.direction)&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom&&("Top"===e.direction||"Bottom"===e.direction)&&e.corners.center.x===t.corners.center.x?(t.direction="Top"===e.direction?"Bottom":"Top",i=Ys(n,t,e,"Top"===e.direction?t.corners.bottom-t.point.y+20:t.point.y-t.corners.top+20)):!n.selectedSegmentIndex&&void 0!==n.sourceWrapper&&void 0!==n.targetWrapper&&void 0!==n.targetPortWrapper&&("Top"===t.direction||"Bottom"===t.direction)&&t.point.x>=t.corners.left&&t.point.x<=t.corners.right&&("Left"===e.direction||"Right"===e.direction)&&e.corners.center.y===t.corners.center.y?(t.direction="Left"===e.direction?"Right":"Left",i=Ys(n,t,e,"Left"===e.direction?t.corners.right-t.point.x+20:t.point.x-t.corners.left+20)):i=a?Ys(n,t,e,"Left"===t.direction||"Right"===t.direction?"Left"===t.direction?t.point.x-t.corners.left+20:t.corners.right-t.point.x+20:"Top"===t.direction?t.point.y-t.corners.top+20:t.corners.bottom-t.point.y+20):Ll(t,e):i=Ys(n,t,e),i}function h3(n,t,e){var r,i={x:t.offsetX,y:t.offsetY},s=En(e),o=zo(i,s,e.bounds),a=n.segments[0];return a.direction!==o&&(function bre(n,t,e,i,r,s){var a,h,o=13,l=[];l.push(i),i.y===r.y&&("Left"===t&&r.xi.x)||i.x===r.x&&("Top"===t&&r.yi.y)||("Top"===t||"Bottom"===t?"Top"===t&&r.yi.y-o||"Bottom"===t&&r.y>i.y&&r.yo&&("Top"===t&&r.yi.y)?l.push({x:i.x,y:r.y}):(a=r.xi.x-o||"right"===t&&r.x>i.x&&r.xo&&("Left"===t&&r.xi.x)?l.push({x:r.x,y:i.y}):(l.push({x:a="Left"===t?e.left-o:e.right+o,y:i.y}),l.push({x:a,y:r.y})),s&&(l.push(n.points[0]),l.reverse()),n.points=l)}(a,o,s,a.points[0],a.points[a.points.length-1],!1),r=a.points[a.points.length-1],a.direction=z.direction(a.points[a.points.length-2],a.points[a.points.length-1])),r}function c3(n,t,e){var s,i=t.segments[t.segments.length-2],r=i.points[i.points.length-1];(("Top"===i.direction||"Bottom"===i.direction)&&r.x===n[1].x||("Left"===i.direction||"Right"===i.direction)&&r.y===n[1].y)&&(i.points[i.points.length-1]=n[1],s=z.direction(i.points[0],i.points[i.points.length-1]),void 0!==t.sourceWrapper&&void 0===t.sourcePortWrapper&&s===ls(i.direction)&&("Left"===i.direction||"Right"===i.direction?i.points[0].x="Right"===i.direction?i.points[0].x-t.sourceWrapper.corners.width:i.points[0].x+t.sourceWrapper.corners.width:i.points[0].y="Bottom"===i.direction?i.points[0].y-t.sourceWrapper.corners.height:i.points[0].y+t.sourceWrapper.corners.height),i.direction=s,i.length=z.distancePoints(i.points[0],i.points[i.points.length-1]),n.splice(0,1))}function bI(n,t,e,i){var o=i?n.targetPadding:n.sourcePadding,a=i?n.targetPortWrapper:n.sourcePortWrapper,l=new Ne(a.bounds.x-o,a.bounds.y-o,a.actualSize.width+2*o,a.actualSize.height+2*o),h=[l.topLeft,l.topRight,l.bottomRight,l.bottomLeft];h[h.length]=h[0];var d=i?e.point:t.point;return Lx({x1:t.point.x,y1:t.point.y,x2:e.point.x,y2:e.point.y},h,0,d)||d}function d3(n,t){var e=[],i=dF(0,n.corners,t);i.push(i[0]);for(var r=0;r0){var r=void 0,s=[],o=t.point;for(r=0;r1&&z.equals(a.points[0],a.points[1])&&n.segments.splice(r,1),a)for(var l=0;l0||0===r)&&i.push(a.points[parseInt(l.toString(),10)])}}return i}function Ax(n,t,e){return"Top"===n||"Bottom"===n?e.x>t.x?"Right":"Left":e.y>t.y?"Bottom":"Top"}function Bv(n){if("Straight"===n.type||"Bezier"===n.type){if(0===n.segments.length||n.segments.length>0&&!z.isEmptyPoint(n.segments[n.segments.length-1].point))if("Bezier"===n.type){var t=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0},!0);n.segments.push(t)}else t=new kl(n,"segments",{type:"Straight"},!0),n.segments.push(t)}else{if(n.segments.length>0)for(var e=!1,i=0;i=t.corners.left&&e.point.x<=t.corners.right&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom)t.direction=e.point.y>t.point.y?"Bottom":"Top",i=Ys(n,t,e,"Top"===t.direction?t.point.y-t.corners.top+20:t.corners.bottom-t.point.y+20);else if(n.sourcePortWrapper&&r===ls(o)){var h;("Left"===r||"Right"===r)&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom?(t.direction=e.point.y>t.point.y?"Bottom":"Top",h=t.corners.height/2+20):("Top"===r||"Bottom"===r)&&t.point.x>=t.corners.left&&t.point.x<=t.corners.right&&(t.direction=e.point.x>t.point.x?"Right":"Left",h=t.corners.width/2+20),t.direction&&h?i=Ys(n,t,e,h,!0):(t.direction=o,i=Ll(t,e))}else if(!n.sourcePortWrapper||r!==e.direction||"Top"!==r&&"Bottom"!==r||t.corners.center.x!==e.corners.center.x)if(t.direction===e.direction)if(("Left"===t.direction||"Right"===t.direction)&&e.point.y>t.corners.top-20&&e.point.yt.corners.left-20&&e.point.xt.point.y?"Bottom":"Top",i=Ys(n,t,e,"Bottom"===t.direction?t.corners.bottom-t.point.y+20:t.point.y-t.corners.top+20);else t.direction=o,i=Ys(n,t,e,"Top"===o||"Bottom"===o?n.sourceWrapper.height/2+20:n.sourceWrapper.width/2+20),t.point=i[1],"Left"===o||"Right"===o?(e.direction=o,e.point="Left"===o?e.corners.middleLeft:e.corners.middleRight):Fv(n.targetWrapper,t,e,n),i=Ys(n,t,e);return i}function p3(n,t){if(void 0!==n.targetWrapper&&void 0===n.targetPortWrapper&&En(n.targetWrapper).containsPoint(t.point,1)){var i=n.targetWrapper,r=n.segments[n.segments.length-2],s=r.points[r.points.length-1],o=ls(r.direction);"Bottom"===o?s.yi.corners.top-1&&(r.points[r.points.length-1].y=i.corners.top-20,r.length=z.distancePoints(r.points[0],r.points[r.points.length-1])):"Left"===o?s.x>i.corners.left-1&&(r.points[r.points.length-1].x=i.corners.left-20,r.length=z.distancePoints(r.points[0],r.points[r.points.length-1])):"Right"===o&&s.x0||0===e)&&t.push(i.points[parseInt(r.toString(),10)]);return t}function Fv(n,t,e,i){var r,s={x:0,y:0},o=MI(n,n.corners,n.bounds),a=t.margin,l=t.point;if(o.bottomCenter.y+a.bottoml.y)r="Top",s=o.topCenter;else if(o.middleLeft.x-a.left>l.x)r="Left",s=o.middleLeft;else if(o.middleRight.x+a.rightc&&(p=c,r="Right",s=o.middleRight),p>d&&(p=d,r="Bottom",s=o.bottomCenter),p>u&&(r="Left",s=o.middleLeft)}e.point=s,e.direction=r;var f=Tc(o,ls(e.direction));e.point=Ah(i,0,e.point,f,n===i.targetWrapper)}function g3(n,t,e,i,r){var s,o,a;if(s=function zre(n,t){var e=!1;switch(n){case"Left":switch(t){case"Right":case"Bottom":e=!0}break;case"Top":switch(t){case"Left":case"Right":case"Bottom":e=!0}break;case"Bottom":"Right"===t&&(e=!0)}return e}(t.direction,e.direction),s&&b3(t,e),"Right"===t.direction&&"Left"===e.direction)a=function Mre(n,t,e,i){var o=Math.round(Math.abs(t.point.y-e.point.y)),a={x:Math.max(t.point.x,t.corners.right),y:t.point.y},l={x:Math.min(e.point.x,e.corners.left),y:e.point.y},h=Ga(n);if(i){var c=l;l=a,a=c}return t.corners.bottom+he.corners.bottom+h||("Bezier"!==n.type||e.corners.left-t.corners.right<=2*h&&e.corners.left-t.corners.right>=5)&&(h=0),t.margin={left:h,right:h,top:h,bottom:h},e.margin={left:h,right:h,top:h,bottom:h},0===o&&(t.corners.right=e.corners.right?void 0!==i&&(i.offsetYe.corners.bottom+e.margin.bottom)||void 0===i&&t.corners.middleRight.ye.corners.bottom+e.margin.bottom&&t.corners.top>e.corners.bottom||void 0===i&&t.corners.middleRight.y>e.corners.bottom||void 0!==i&&i.offsetYe.corners.top||void 0===i&&t.corners.middleRight.y>e.corners.bottom?Ae.Three:t.corners.rightr.offsetY+e.margin.right||void 0===r&&t.corners.top>e.corners.middleRight.y||void 0!==r&&(void 0!==i&&i.offsetXr.offsetX||void 0===r&&t.corners.left>e.corners.topCenter.x?Ae.Four:Ae.Two:void 0!==s&&Math.abs(t.corners.right-e.corners.left)<=5&&Math.abs(s.offsetY-e.corners.top)<=5||void 0!==r&&t.corners.right=25&&t.corners.middleRight.y+t.margin.righte.corners.bottom+e.margin.bottom||void 0===o&&t.corners.middleRight.y>e.corners.bottom+e.margin.bottom?t.corners.top>e.corners.bottom?void 0!==a&&t.corners.right+t.margin.righta.offsetX||void 0===a&&t.corners.left>e.corners.bottomCenter.x?Ae.Four:Ae.Two:void 0!==o&&Math.abs(t.corners.right-e.corners.left)<=25&&Math.abs(o.offsetY-e.corners.bottom)<=25?Ae.Two:Ae.Four}(n,t,e,s);else if("Bottom"===t.direction&&"Top"===e.direction)a=function Dre(n,t,e){var r=t.point.x-e.point.x,s=Ga(n);return t.corners.right+se.corners.right+s||("Bezier"!==n.type||e.corners.top-t.corners.bottom<=2*s&&e.corners.top-t.corners.bottom>=5)&&(s=0),t.margin={left:s,right:s,top:s,bottom:s},e.margin={left:s,right:s,top:s,bottom:s},0===r&&t.corners.bottome.corners.right+e.margin.right||void 0===i&&t.corners.bottomCenter.x>e.corners.right+e.margin.right?Ae.Three:t.corners.bottomr.offsetX||void 0===r&&t.corners.left>e.corners.left||void 0!==r&&t.corners.right+t.margin.righte.corners.bottom?Ae.Five:0===s||0===o?Ae.One:Ae.Three}(n,t,e)}else"Bottom"===t.direction&&"Left"===e.direction?a=function xre(n,t,e,i){var r=n.sourcePortWrapper,s=n.targetPortWrapper,o=Ga(n);if(e.margin={left:o,right:o,top:o,bottom:o},t.margin={top:o,bottom:o,left:o,right:o},i){var l=r;r=s,s=l}return void 0!==r&&r.offsetXs.offsetY||void 0===s&&t.corners.top>e.corners.middleLeft.y?Ae.Four:Ae.Two:void 0!==s&&Math.abs(t.corners.right-e.corners.left)<=25&&Math.abs(s.offsetY-t.corners.bottom)<=25?Ae.Two:Ae.Four}(n,t,e,s):"Left"===t.direction&&"Left"===e.direction?a=function Lre(n,t,e){var i=n.sourcePortWrapper,r=n.targetPortWrapper,s=Ga(n);t.margin={left:s,right:s,top:s,bottom:s},e.margin={left:s,right:s,top:s,bottom:s};var o=Math.round(Math.abs(t.point.x-e.point.x)),a=Math.round(Math.abs(t.point.y-e.point.y));return t.corners.leftr.offsetY||void 0===r&&t.corners.top-t.margin.top>e.corners.middleLeft.y?Ae.Three:t.corners.righte.corners.bottom+e.margin.bottom||void 0===i&&t.corners.middleLeft.y>e.corners.bottom+e.margin.bottom?Ae.Three:t.corners.left>e.corners.right?Ae.Five:0===o||0===a?Ae.One:Ae.Three}(n,t,e):"Left"===t.direction&&"Top"===e.direction?a=function Are(n,t,e,i){var s=n.sourcePortWrapper,o=Ga(n);e.margin={left:o,right:o,top:o,bottom:o},t.margin={top:o,bottom:o,left:o,right:o};var a=n.targetPortWrapper,l={x:Math.min(t.point.x,t.corners.left),y:t.point.y},h={x:e.point.x,y:Math.min(e.point.y,e.corners.top)};if(i){var c=s;s=a,a=c;var d=l;l=h,h=d}return void 0!==s&&s.offsetYa.offsetX||void 0===a&&t.corners.left-t.margin.left>e.corners.topCenter.x?Ae.Two:Ae.Four:void 0!==a&&t.corners.rightr.offsetX||void 0===r&&t.corners.left>e.corners.left||void 0!==r&&t.corners.right+t.margin.righte.corners.right+e.margin.right||void 0===i&&t.corners.left>e.corners.right||void 0!==i&&i.offsetXe.corners.bottom?Ae.Five:0===s||0===o?Ae.One:Ae.Three}(n,t,e));return s&&b3(t,e),o=function Ore(n,t,e,i,r,s){var l,d,h=n.sourceWrapper.corners,c=n.targetWrapper.corners,u=20,p={corners:e.corners,point:e.point,direction:e.direction,margin:e.margin},f={corners:i.corners,point:i.point,direction:i.direction,margin:i.margin};if(!(p.direction===f.direction&&t!==Ae.Five||p.direction!==ls(f.direction)&&t!==Ae.Three))switch(p.direction){case"Left":h.middleLeft.x>c.middleRight.x&&(d=(h.middleLeft.x-c.middleRight.x)/2,u=s?d:Math.min(u,d));break;case"Right":h.middleRight.xc.bottomCenter.y&&(d=(h.topCenter.y-c.bottomCenter.y)/2,u=s?d:Math.min(u,d));break;case"Bottom":h.bottomCenter.yp&&hp)&&o>c&&o<=d&&e>=20&&(s=n.point.x-t.corners.left+s),i&&n.direction===t.direction&&n.corners.left>t.corners.left&&n.corners.left-t.corners.right>=20&&(s=(n.corners.left-t.corners.right)/2),f=Bn(n.point,s,180);break;case"Top":(o>c&&oc)&&h>p&&h<=u&&e>=20&&(s=n.point.y-t.corners.top+s),i&&n.direction===t.direction&&n.corners.top>t.corners.top&&n.corners.top-t.corners.bottom>=20&&(s=(n.corners.top-t.corners.bottom)/2),f=Bn(n.point,s,270);break;case"Right":(h>p&&hp)&&a=c&&e>=20&&(s=t.corners.right-n.point.x+s),i&&n.direction===t.direction&&n.corners.right=20&&(s=(t.corners.left-n.corners.right)/2),f=Bn(n.point,s,0);break;case"Bottom":(o>c&&oc)&&l=p&&e>=20&&(s=t.corners.bottom-n.point.y+s),i&&n.direction===t.direction&&n.corners.bottom=20&&(s=(t.corners.top-n.corners.bottom)/2),f=Bn(n.point,s,90)}r=[n.point,f];var g=void 0;if("Top"===n.direction||"Bottom"===n.direction){var v=n.direction;n.direction=f.x>t.point.x?"Left":"Right",n.point=f,r=wI(n,t,v,r,g=i?.5*Math.abs(f.x-t.point.x):g,i)}else v=n.direction,n.direction=f.y>t.point.y?"Top":"Bottom",n.point=f,r=wI(n,t,v,r,g=i?.5*Math.abs(f.y-t.point.y):g,i);return r}(p,f,u,g)),l}(n,a,t,e,i,r),"Bezier"===n.type&&function Pre(n,t,e){if("Bezier"===n.type)if(0===n.segments.length){var i=e[0],r=e[e.length-1];if(t===Ae.One){var s=Math.min(20,.5*z.findLength(i,r)),o={angle:Xt(i,r),distance:s},a={angle:Xt(r,i),distance:s},l=z.direction(i,r),c=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,orientation:"Left"===l||"Right"===l?"Horizontal":"Vertical"},!0);n.segments.push(c)}else if(t===Ae.Two)o={angle:Xt(i,d=e[1]),distance:.5*z.findLength(i,d)},a={angle:Xt(r,d),distance:.5*z.findLength(r,d)},l=z.direction(i,d),c=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,orientation:"Left"===l||"Right"===l?"Horizontal":"Vertical"},!0),n.segments.push(c);else if(t===Ae.Three){var d={x:.5*((u=e[1]).x+(p=e[e.length-2]).x),y:.5*(u.y+p.y)},f=(o={angle:Xt(i,u),distance:.5*z.findLength(i,u)},a={angle:Xt(d,u),distance:.5*z.findLength(d,u)},z.direction(i,u)),v=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,point:d,orientation:"Left"===f||"Right"===f?"Horizontal":"Vertical"},!0);n.segments.push(v);var y={angle:Xt(d,p),distance:.5*z.findLength(d,p)},S={angle:Xt(r,p),distance:.5*z.findLength(r,p)},b=z.direction(d,p),w=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:y,vector2:S,orientation:"Left"===b||"Right"===b?"Horizontal":"Vertical"},!0);n.segments.push(w)}else if(t===Ae.Four){var D={x:.5*((u=e[1]).x+(p=e[2]).x),y:.5*(u.y+p.y)},A={x:.5*(p.x+(C=e[3]).x),y:.5*(p.y+C.y)};o={angle:Xt(i,u),distance:.5*z.findLength(i,u)},a={angle:Xt(D,u),distance:.5*z.findLength(D,u)},f=z.direction(i,u),v=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,point:D,orientation:"Left"===f||"Right"===f?"Horizontal":"Vertical"},!0),n.segments.push(v),y={angle:Xt(D,p),distance:.5*z.findLength(D,p)},S={angle:Xt(A,p),distance:.5*z.findLength(A,p)},b=z.direction(D,p),w=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:y,vector2:S,point:A,orientation:"Left"===b||"Right"===b?"Horizontal":"Vertical"},!0),n.segments.push(w);var x={angle:Xt(A,C),distance:.5*z.findLength(A,C)},R={angle:Xt(r,C),distance:.5*z.findLength(r,C)},L=z.direction(A,C),N=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:x,vector2:R,orientation:"Left"===L||"Right"===L?"Horizontal":"Vertical"},!0);n.segments.push(N)}else if(t===Ae.Five){var u,p,C,T=e[4],P=(D={x:.5*((u=e[1]).x+(p=e[2]).x),y:.5*(u.y+p.y)},A={x:.5*(p.x+(C=e[3]).x),y:.5*(p.y+C.y)},{x:.5*(C.x+T.x),y:.5*(C.y+T.y)});o={angle:Xt(i,u),distance:.5*z.findLength(i,u)},a={angle:Xt(D,u),distance:.5*z.findLength(D,u)},f=z.direction(i,u),v=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,point:D,orientation:"Left"===f||"Right"===f?"Horizontal":"Vertical"},!0),n.segments.push(v),y={angle:Xt(D,p),distance:.5*z.findLength(D,p)},S={angle:Xt(A,p),distance:.5*z.findLength(A,p)},b=z.direction(D,p),w=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:y,vector2:S,point:A,orientation:"Left"===b||"Right"===b?"Horizontal":"Vertical"},!0),n.segments.push(w),x={angle:Xt(A,C),distance:.5*z.findLength(A,C)},R={angle:Xt(P,C),distance:.5*z.findLength(P,C)},L=z.direction(A,C),N=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:x,vector2:R,point:P,orientation:"Left"===L||"Right"===L?"Horizontal":"Vertical"},!0),n.segments.push(N);var _={angle:Xt(P,T),distance:.5*z.findLength(P,T)},B={angle:Xt(r,T),distance:.5*z.findLength(r,T)},j=z.direction(P,T),oe=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:_,vector2:B,orientation:"Left"===j||"Right"===j?"Horizontal":"Vertical"},!0);n.segments.push(oe)}else c=new ps(n,"segments",{type:"Bezier"},!0),n.segments.push(c)}else for(var ue=0;ue=13?13:n.connectorSpacing<=1?1:n.connectorSpacing}function Xt(n,t){var i=z.findLength({x:t.x,y:n.y},t),r=z.findLength(t,n),s=Math.asin(i/r);return s=180*s/Math.PI,n.xt.y&&(s=360-s):s=n.y0)for(var l=1;lc)&&(s=c,a=h),s>=0&&s<=1)break}}return a}function m3(n,t){var c,d,u,p,f,g,S,b,M,w,D,e=n.x1,i=n.y1,r=n.x2,s=n.y2,o=t.x1,a=t.y1,l=t.x2,h=t.y2;if(w=(c=s-i)*l+(u=e-r)*h+(f=r*i-e*s),0!==(M=c*o+u*a+f)&&0!==w&&y3(M,w)||(b=(d=h-a)*r+(p=o-l)*s+(g=l*a-o*h),0!==(S=d*e+p*i+g)&&0!==b&&y3(S,b)))return null;var A=c*p-d*u;return 0===A?null:(A<0?-A/2:A/2,0,{x:(D=u*g-p*f)<0?(D-0)/A:(D+0)/A,y:(D=d*f-c*g)<0?(D-0)/A:(D+0)/A})}function y3(n,t){return n*t>=0}function S3(n,t,e){switch(t.direction){case"Left":t.point.x>n.left&&(e=t.point.x-n.left>e?t.point.x-n.left+e:e);break;case"Right":t.point.xe?n.right-t.point.x+e:e);break;case"Top":t.point.y>n.top&&(e=t.point.y-n.top>e?t.point.y-n.top+e:e);break;case"Bottom":t.point.ye?n.bottom-t.point.y+e:e)}return e}function Ll(n,t){var e;switch(n.direction){case"Left":case"Right":var i={x:t.point.x,y:n.point.y};e=z.equals(n.point,i)||z.equals(t.point,i)?[n.point,t.point]:[n.point,i,t.point];break;case"Top":case"Bottom":var r={x:n.point.x,y:t.point.y};e=z.equals(n.point,r)||z.equals(t.point,r)?[n.point,t.point]:[n.point,r,t.point]}return e}function Ys(n,t,e,i,r,s){void 0===s&&(s=!1),i||(i=20),s&&t.direction!==e.direction&&(i="Left"===t.direction||"Right"===t.direction?Math.floor(.5*Math.abs(t.point.x-e.point.x)):Math.floor(.5*Math.abs(t.point.y-e.point.y)));var l,h,u,o=n.sourcePortWrapper,c=e.point.x-t.point.x,d=e.point.y-t.point.y;if(!r&&(Math.abs(c)<.001||Math.abs(d)<.001)&&void 0===e.direction)return[t.point,e.point];if(void 0===n.targetWrapper&&Math.abs(c)<=31&&Math.abs(d)<=31){if("Left"===t.direction||"Right"===t.direction?Math.abs(d)<12&&(t.direction=t.point.y>e.point.y?"Top":"Bottom"):Math.abs(c)<12&&(t.direction=t.point.x>e.point.x?"Left":"Right"),Math.abs(c)>12||Math.abs(d)>12)return Ll(t,e);i+=5}return"Left"===t.direction||"Right"===t.direction?("Right"===t.direction?(void 0!==e.direction&&"Right"===e.direction&&(i=Math.max(t.point.x,e.point.x)-t.point.x+i),t.point.x>e.point.x&&void 0===o&&(i=-i)):(void 0!==e.direction&&"Left"===e.direction&&(i=t.point.x-Math.min(t.point.x,e.point.x)+i),(t.point.x>e.point.x||void 0!==o||"Left"===t.direction)&&(i=-i)),u=e.point.y-t.point.y,l=Bn(t.point,i,0),0!=(u=e.point.y-l.y)&&(h=Bn(l,e.point.y-l.y,90))):("Top"===t.direction||"Bottom"===t.direction)&&("Bottom"===t.direction?void 0!==e.direction&&"Bottom"===e.direction&&(i=Math.max(t.point.y,e.point.y)-t.point.y+i):(void 0!==e.direction&&"Top"===e.direction&&(i=t.point.y-Math.min(t.point.y,e.point.y)+i),(t.point.y>e.point.y||void 0!==o||"Top"===t.direction)&&(i=-i)),u=e.point.x-t.point.x,l=Bn(t.point,i,90),0!=(u=e.point.x-l.x)&&(h=Bn(l,e.point.x-l.x,0))),0===u?[t.point,e.point]:[t.point,l,h,e.point]}function wI(n,t,e,i,r,s){var o;switch(void 0===r&&(r=20),void 0===s&&(s=!1),void 0===e?(n.margin={left:2,right:2,top:2,bottom:2},t.margin={left:0,right:5,top:0,bottom:5},s&&(n.margin={left:10,right:10,top:10,bottom:10},t.margin={left:10,right:10,top:10,bottom:10},"Left"===n.direction?(r=Ox(n,t,e,r),n.corners.left-t.corners.right>=5&&(r=Math.abs(n.point.x-n.corners.left)+.5*Math.floor(n.corners.left-t.corners.right))):"Right"===n.direction?(r=kx(n,t,r,e),t.corners.left-n.corners.right>=5&&(r=Math.abs(n.point.x-n.corners.right)+.5*Math.floor(t.corners.left-n.corners.right))):"Top"===n.direction?(r=Nx(n,t,e,r),n.corners.top-t.corners.bottom>=5&&(r=Math.abs(n.point.y-n.corners.top)+.5*Math.floor(n.corners.top-t.corners.bottom))):"Bottom"===n.direction&&(r=Px(n,t,r,e),t.corners.top-n.corners.bottom>=5&&(r=Math.abs(n.point.y-n.corners.bottom)+.5*Math.floor(t.corners.top-n.corners.bottom))))):("Bottom"===n.direction?s?t.corners.top-n.corners.bottom<20&&(r=t.corners.bottom-n.point.y+25):t.corners.top>n.corners.bottom&&t.corners.top-n.corners.bottom<20&&(r=(t.corners.top-n.corners.bottom)/2):"Top"===n.direction?s?n.corners.top-t.corners.bottom<20&&(r=n.point.y-t.corners.top+25):t.corners.bottomn.corners.right&&t.corners.left-n.corners.right<20&&(r=(t.corners.left-n.corners.right)/2):"Left"===n.direction&&(s?n.corners.left-t.corners.right<20&&(r=n.point.x-t.corners.left+25):t.corners.rightt.point.y||"Top"===t.direction&&n.point.yt.point.x||"Left"===t.direction&&n.point.xh||e.corners.top-e.margin.top<=i.point.y&&e.corners.bottom+e.margin.bottom>=i.point.y))if(!s||"Top"!==e.direction&&"Bottom"!==e.direction)c=Math.min(Math.abs(i.corners.left-e.corners.right)/2,20),h=e.corners.right-n.x+c;else{var c=Math.abs(i.corners.left-e.corners.right)/2;h=e.corners.right-n.x+c}else h="Top"===e.direction&&n.y>i.point.y||"Bottom"===e.direction&&n.y=e.corners.left-e.margin.left&&n.x<=e.corners.right+e.margin.right?Math.min(i.corners.left,e.corners.left)-n.x-20:i.corners.left-n.x-20;break;case"Right":if(e.corners.left-e.margin.left>i.corners.right+i.margin.right&&(e.corners.left-e.margin.right-i.corners.right>h||e.corners.top-e.margin.top<=i.point.y&&e.corners.bottom+e.margin.bottom>=i.point.y))if(!s||"Top"!==e.direction&&"Bottom"!==e.direction)c=Math.min(Math.abs(e.corners.left-i.corners.right)/2,20),h=e.corners.left-n.x-c;else{c=Math.abs(e.corners.left-i.corners.right)/2;h=e.corners.left-n.x-c}else h="Top"===e.direction&&n.y>i.point.y||"Bottom"===e.direction&&n.y=e.corners.left-e.margin.left&&n.x<=e.corners.right+e.margin.right?Math.max(i.corners.right,e.corners.right)-n.x+20:i.corners.right-n.x+20}o=Bn(n,h,0),a=Bn(o,i.point.y-n.y,90),l=i.point}else if("vertical"===t){switch(i.direction){case"Top":e.corners.bottom+e.margin.bottomh||e.corners.left-e.margin.left<=i.point.x&&e.corners.right+e.margin.right>=i.point.x)?!s||"Right"!==e.direction&&"Left"!==e.direction?(c=Math.min(Math.abs(i.corners.top-e.corners.bottom)/2,20),h=e.corners.bottom-n.y+c):(c=Math.abs(i.corners.top-e.corners.bottom)/2,h=e.corners.bottom-n.y+c):h="Left"===e.direction&&n.x>i.point.x||"Right"===e.direction&&n.x=e.corners.top-e.margin.top&&n.y<=e.corners.bottom+e.margin.bottom?Math.min(i.corners.top,e.corners.top)-n.y-20:i.corners.top-n.y-20;break;case"Bottom":e.corners.top-e.margin.top>i.corners.bottom+i.margin.bottom&&(e.corners.top-e.margin.top-i.corners.bottom>h||e.corners.left-e.margin.left<=i.point.x&&e.corners.right+e.margin.right>=i.point.x)?!s||"Right"!==e.direction&&"Left"!==e.direction?(c=Math.min(Math.abs(e.corners.top-i.corners.bottom)/2,20),h=e.corners.top-n.y-c):(c=Math.abs(e.corners.top-i.corners.bottom)/2,h=e.corners.top-n.y-c):h="Left"===e.direction&&n.x>i.point.x||"Right"===e.direction&&n.x=e.corners.top-e.margin.top&&n.y<=e.corners.bottom+e.margin.bottom?Math.max(i.corners.bottom,e.corners.bottom)-n.y+20:i.corners.bottom-n.y+20}o=Bn(n,h,90),a=Bn(o,i.point.x-n.x,0),l=i.point}r.push(o),r.push(a),r.push(l)}function Nx(n,t,e,i){return n.corners.top-n.margin.top>t.corners.top+t.margin.top&&n.corners.top-n.margin.top<=t.corners.bottom+t.margin.bottom?(("Right"===t.direction&&n.point.xt.point.x)&&(i+=n.corners.top-t.corners.top),i+=n.point.y-n.corners.top):i+=void 0!==e&&"Left"!==e&&"Right"===t.direction&&n.point.xt.corners.left-t.margin.left&&n.corners.left-n.margin.left<=t.corners.right+t.margin.right?(("Bottom"===t.direction&&n.point.yt.point.y)&&(i+=n.corners.left-t.corners.left),i+=n.point.x-n.corners.left):i+=void 0!==e&&"Top"!==e&&"Bottom"===t.direction&&n.point.y=t.corners.left-t.margin.left?(("Bottom"===t.direction&&n.point.yt.point.y)&&(e+=t.corners.right-n.corners.right),e+=n.corners.right-n.point.x):e+=void 0!==i&&"Top"!==i&&"Bottom"===t.direction&&n.point.y=t.corners.top-t.margin.top?(("Right"===t.direction&&n.point.xt.point.x)&&(e+=t.corners.bottom-n.corners.bottom),e+=n.corners.bottom-n.point.y):e+=void 0!==i&&"Left"!==i&&"Right"===t.direction&&n.point.xf&&d=u&&d=p&&d<=f?"Left":"Right"}function ls(n){switch(n){case"Top":return"Bottom";case"Bottom":return"Top";case"Left":return"Right";case"Right":return"Left"}return"auto"}var w3=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Ac=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},CI=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return w3(t,n),Ac([I()],t.prototype,"width",void 0),Ac([I()],t.prototype,"height",void 0),t}(Ee),Rre=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return w3(t,n),Ac([I()],t.prototype,"width",void 0),Ac([I()],t.prototype,"height",void 0),Ac([I()],t.prototype,"fit",void 0),Ac([I()],t.prototype,"description",void 0),Ac([I()],t.prototype,"template",void 0),Ac([I()],t.prototype,"tooltip",void 0),t}(Ee),Hre=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Nl=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},C3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Hre(t,n),Nl([I("")],t.prototype,"id",void 0),Nl([I(Number.MIN_VALUE)],t.prototype,"zIndex",void 0),Nl([re({},$n)],t.prototype,"margin",void 0),Nl([I(!0)],t.prototype,"visible",void 0),Nl([re({},Ed)],t.prototype,"tooltip",void 0),Nl([I(!1)],t.prototype,"excludeFromLayout",void 0),Nl([I()],t.prototype,"addInfo",void 0),Nl([I("None")],t.prototype,"flip",void 0),Nl([I("All")],t.prototype,"flipMode",void 0),Nl([re({},Rre)],t.prototype,"symbolInfo",void 0),t}(Ee),Bre=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Jn=function(n){function t(e,i,r,s){var o=n.call(this)||this;return o.data="",o.nodeId="",o.annotationId="",o.diagramId="",o.diagramId=i,o.nodeId=e,o.annotationId=r,o.templateFn=UF(s),o}return Bre(t,n),t.prototype.getNodeTemplate=function(){return this.templateFn},Object.defineProperty(t.prototype,"content",{get:function(){return this.data},set:function(e){this.data=e,this.canReset||(this.canReset=!0,this.isTemplate||(this.template=Rh(this,!0)),this.canReset=!1,this.isDirt=!0)},enumerable:!0,configurable:!0}),t}(as),zx=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),hs=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},E3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return zx(t,n),hs([I("")],t.prototype,"id",void 0),hs([I("transparent")],t.prototype,"fill",void 0),hs([I("black")],t.prototype,"iconStrokeColor",void 0),hs([I(0)],t.prototype,"iconStrokeWidth",void 0),hs([I(!0)],t.prototype,"visibility",void 0),hs([I(10)],t.prototype,"width",void 0),hs([I(10)],t.prototype,"height",void 0),hs([I("transparent")],t.prototype,"handleStrokeColor",void 0),hs([I(1)],t.prototype,"handleStrokeWidth",void 0),hs([I("")],t.prototype,"pathData",void 0),hs([I(0)],t.prototype,"cornerRadius",void 0),hs([re({left:0,right:0,top:0,bottom:0},$n)],t.prototype,"padding",void 0),hs([re({},Ed)],t.prototype,"tooltip",void 0),t}(Ee),D3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return zx(t,n),hs([re({x:0,y:0},z)],t.prototype,"offset",void 0),hs([re({},$n)],t.prototype,"margin",void 0),t}(E3),EI=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return zx(t,n),hs([I(.5)],t.prototype,"offset",void 0),hs([I("Center")],t.prototype,"alignment",void 0),hs([re({x:0,y:0},z)],t.prototype,"displacement",void 0),t}(E3);function Dd(n){return n?n instanceof Zn||n instanceof Nr?n.constraints&Lr.Select:n instanceof de?n.constraints&qe.Select:n.constraints&ie.Select:1}function to(n){return n?n instanceof Zn||n instanceof Nr?n.constraints&Lr.Drag:n instanceof de?n.constraints&qe.Drag:n instanceof oi?1:n.constraints&ie.Drag:1}function Fre(n,t){return n instanceof de?n.constraints&qe.PointerEvents:n.constraints&ie.PointerEvents}function DI(n){return n instanceof de?n.constraints&qe.Delete:n.constraints&ie.Delete}function xI(n){return n.constraints&qe.DragSourceEnd}function TI(n){return n.constraints&qe.DragTargetEnd}function AI(n){return n.constraints&qe.DragSegmentThumb}function LI(n){return n instanceof Zn||n instanceof Nr?n.constraints&Lr.Rotate:n.constraints&ie.Rotate}function NI(n){return n.constraints&ie.Shadow}function da(n){return n instanceof te&&n.constraints&ie.InConnect?n.constraints&ie.InConnect:0}function Lh(n){return n&&n.constraints&&!(n.constraints&ni.None)&&n.constraints&ni.InConnect?n.constraints&ni.InConnect:0}function Nh(n){return n instanceof te&&n.constraints&ie.OutConnect?n.constraints&ie.OutConnect:0}function xd(n){return n&&n.constraints&&!(n.constraints&ni.None)&&n.constraints&ni.OutConnect?n.constraints&ni.OutConnect:0}function Ol(n,t){var e=0;return n instanceof Zn||n instanceof Nr?e=n.constraints&Lr.Resize:n&&("SouthEast"===t?e=n.constraints&ie.ResizeSouthEast:"East"===t?e=n.constraints&ie.ResizeEast:"NorthEast"===t?e=n.constraints&ie.ResizeNorthEast:"South"===t?e=n.constraints&ie.ResizeSouth:"North"===t?e=n.constraints&ie.ResizeNorth:"SouthWest"===t?e=n.constraints&ie.ResizeSouthWest:"West"===t?e=n.constraints&ie.ResizeWest:"NorthWest"===t&&(e=n.constraints&ie.ResizeNorthWest)),e}function OI(n){return n instanceof de?n.constraints&qe.AllowDrop:n.constraints&ie.AllowDrop}function Ds(n){return n.constraints&rt.Virtualization}function _v(n){return n.tool&Ci.SingleSelect}function Uv(n){return n.tool&Ci.MultipleSelect}function Lc(n){return n.tool&Ci.ZoomPan}function kI(n){return n.tool&Ci.ContinuousDraw}function x3(n){return n.tool&Ci.DrawOnce}function PI(n){return n.tool&Ci.SingleSelect||n.tool&Ci.MultipleSelect}function jv(n){return n.constraints&rt.UserInteraction}function T3(n){return n.constraints&rt.ZoomTextEdit}function Vv(n){return function Yre(n){return n.constraints&rt.ApiUpdate}(n)||n.diagramActions&ee.ToolAction}function Rx(n,t){return n.constraints&ni.Draw}function Hx(n,t){return n.constraints&ni.Drag}function zI(n){return!(n&Qa.DrawSelectorBorder)}function A3(n){return!!(n&Qa.PreventRenderSelector)}var Bx=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Wv=function(n){function t(){var e=null!==n&&n.apply(this,arguments)||this;return e.childTable=[],e.cellStyle={},e.desiredRowHeight=[],e.desiredCellWidth=[],e}return Bx(t,n),t.prototype.rowDefinitions=function(){return this.rowDefns},t.prototype.columnDefinitions=function(){return this.colDefns},t.prototype.addObject=function(e,i,r,s,o){if(this.rows.length>=i){var a=this.rows[parseInt(i.toString(),10)];if(a.cells.length>r){o=o||1,s=s||1;var l=a.cells[parseInt(r.toString(),10)];l.columnSpan=Math.max(o,l.columnSpan),l.rowSpan=Math.max(s,l.rowSpan);var h=new $re;(h=e).rowId=i,h.columnId=r,h.columnSpan=o,this.childTable[h.id]=h,this.addObjectToCell(h,l)}}},t.prototype.addObjectToCell=function(e,i){i.children||(i.children=[]),e.style.strokeColor="black",e.style.strokeWidth=1,i.children.push(e)},t.prototype.updateProperties=function(e,i,r,s){this.offsetX=e,this.offsetY=i,this.width=r,this.height=s},t.prototype.setDefinitions=function(e,i){this.rowDefns=e,this.colDefns=i,this.children=[],this.rows=this.rows||[];for(var r=0;r0){for(var h=0;hi&&this.updateRowHeight(e,l,!1)}},t.prototype.setTextRefresh=function(e){if(e.children&&e.children.length)for(var i=e.children,r=0;ri&&this.updateColumnWidth(e,a,!1)}},t.prototype.calculateCellWidth=function(e){for(var i,r,s,o=0;os.bounds.width&&(0===s.children.length||void 0===s.children[0].maxWidth)?s.outerBounds.width:s.bounds.width,i=i?is.bounds.height?s.outerBounds.height:s.bounds.height,i=i?i0?e.children[0]:void 0;if(a&&1===e.columnSpan){o="Width"===i?a.bounds.right:a.bounds.bottom,s||(s="Width"===i?a.bounds.width:a.bounds.height);for(var l=0;lo){var d=c-o+("Width"===i?a.bounds.width:a.bounds.height);s&&(s=s0?this.rowDefns.splice(e,0,i):this.rowDefns.push(i);var s=new L3;s.cells=[],(new Td).width=this.width,this.addCellInRow(this.colDefns,i,s),e>this.rows.length-1?this.rows.push(s):this.rows.splice(e,0,s),r&&(this.measure(new me(this.width,this.height)),this.arrange(this.desiredSize))},t.prototype.addColumn=function(e,i,r){var s,o,a,l,h=this.rows;this.colDefns.length>0?this.colDefns.splice(e,0,i):this.colDefns.push(i),void 0!==this.width&&(this.width+=i.width);for(var c=0;cs.cells.length-1?s.cells.push(l):s.cells.splice(e,0,l),this.children.push(l);r&&(this.measure(new me(this.width,this.height)),this.arrange(this.desiredSize))},t.prototype.removeRow=function(e){var i,r,o=this.rows[parseInt(e.toString(),10)];this.height-=this.rowDefns[parseInt(e.toString(),10)].height;for(var a=0;a0){var r=0,s=0;i=new me(0,0),this.calculateSize();for(var o=0,a=this.rows;o0){for(var o=this.offsetX-e.width*this.pivot.x,a=this.offsetY-e.height*this.pivot.y,l=o,h=0,c=this.rows;h1&&this.children.splice(this.children.indexOf(f)+1,f.columnSpan-1),f.rowSpan>1)for(y=s,S=0;y+f.rowSpan-10){for(var c=0;c0?1:0,v=0;v0||a.outEdges.length>0))for(p=a.inEdges.concat(a.outEdges),s=0;s0)for(o=0;o1)for(a=1;a0))if(h=n.wrapper.children[0],"Horizontal"===e.orientation)for(o=e.header&&e.hasHeader?h.rows[1]:h.rows[0],r=0;r0){var e=void 0;t.lineRoutingModule&&t.constraints&rt.LineRouting&&t.lineRoutingModule.renderVirtualRegion(t,!0);for(var i=0;i0?o+1:o)].height=t.wrapper.height;else if(t.isPhase)for(l[t.rowIndex-o].offset=t.wrapper.height,f=0;f0?1:0)].width=t.wrapper.width}function HI(n,t){var i=n.shape,r=i.header&&i.hasHeader?1:0;return"Horizontal"===i.orientation?t.rowIndex-(r+=i.phases.length>0?1:0):t.columnIndex-(i.phaseSize&&i.phases.length>0?1:0)}function BI(n){var t=0,e=n.shape;return"Horizontal"===e.orientation&&(t=e.header&&e.hasHeader?1:0),e.phases.length>0&&e.phaseSize&&(t+=1),t}function FI(n,t,e,i){var r=n.shape;if(r.phases.length>0){var s=t.nameTable[r.phases[parseInt(i.toString(),10)].header.id];s&&s.maxWidth0?u+1:u);var w=Nc(n,o),C=void 0!==i?i:l.lanes.length;if(u+=C,r={element:M,cause:n.diagramActions,diagramAction:n.getDiagramAction(n.diagramActions),state:"Changing",type:"Addition",cancel:!1,laneIndex:C},n.triggerEvent(Ce.collectionChange,r),!r.cancel){if(c){var D=new Yv;D.height=e.height,o.addRow(u,D,!1),s.height=void 0!==s.height?s.height+e.height:s.height,s.wrapper.height=o.height=s.height}else{var A=new Td;A.width=e.width,o.addColumn(C+1,A,!1),s.width&&(s.width+=e.width,s.wrapper.width=o.width=s.width),n.diagramActions&ee.UndoRedo||(o.rows[0].cells[0].columnSpan+=1)}n.diagramActions&ee.UndoRedo||(M.id=""===M.id?Qe():M.id),void 0!==i?l.lanes.splice(i,0,M):l.lanes.push(M),r={element:M,cause:n.diagramActions,diagramAction:n.getDiagramAction(n.diagramActions),state:"Changed",type:"Addition",cancel:!1,laneIndex:C},n.triggerEvent(Ce.collectionChange,r),O3(o,n,s,u,C,c),h="Horizontal"===l.orientation?n.nameTable[o.rows[parseInt(u.toString(),10)].cells[0].children[0].id]:l.header&&l.hasHeader?n.nameTable[o.rows[1].cells[parseInt(u.toString(),10)].children[0].id]:n.nameTable[o.rows[0].cells[parseInt(u.toString(),10)].children[0].id],n.diagramActions&ee.UndoRedo||(d={type:"LaneCollectionChanged",changeType:"Insert",undoObject:$(M),redoObject:$(h),category:"Internal"},n.addHistoryEntry(d)),Gp(n,s,"Horizontal"===l.orientation?u:l.header&&l.hasHeader?1:0),Qp(s),Oc(n,s);var R=!1;if((p=e.children)&&p.length>0)for(f=0;f0){var o=t.children[0],a=n.nameTable[o.id];(function sne(n,t,e){return n.left-(e.left||0)<=t.x&&n.right+(e.right||0)>=t.x&&n.top-(e.top||0)<=t.y&&n.bottom+(e.bottom||0)>=t.y})(o.bounds,e,r)&&(n.addChild(a,i),s=!0)}return s}function one(n,t,e){if("SwimLane"===t.shape.type){var i=void 0,r=void 0,s=void 0,a=void 0,l=void 0,h=void 0,c=t.wrapper.bounds.x,d=t.wrapper.bounds.y,u=t.shape,p=u.padding,f=u.phases,g=void 0,v=t.wrapper.children[0],y="Horizontal"===u.orientation;if(i=u.header&&u.hasHeader?0:-1,u.phases.length>0&&(i+=1),e.offset>(y?u.lanes[0].header.width:u.lanes[0].header.height)){for(h=0;he.offset){if(g=h>0?e.offset-(h>0?f[h-1]:s).offset:e.offset,y){var b=v.columnDefinitions()[parseInt(h.toString(),10)];b.width-=g,(a=n.nameTable[u.phases[parseInt(h.toString(),10)].header.id]).maxWidth=a.wrapper.maxWidth=b.width,v.updateColumnWidth(h,b.width,!1);var M=new Td;M.width=g,l=h,v.addColumn(h,M,!1);break}var w=v.rowDefinitions()[h+i];w.height-=g,a=n.nameTable[u.phases[parseInt(h.toString(),10)].header.id],v.updateRowHeight(h+i,w.height,!1);var C=new Yv;C.height=g,l=h,v.addRow(h+i,C,!1);break}if(n.diagramActions&ee.UndoRedo&&void 0===l&&(D=n.historyManager.currentEntry.next).isLastPhase&&function ane(n,t,e,i,r,s){var a=t.shape.phases[n-2],l=e.previousPhase.offset;if(r){var h=i.columnDefinitions()[n-1],c=new Td;n>1?(c.width=h.width-(l-a.offset),h.width=l-a.offset):(c.width=h.width-l,h.width=l),i.updateColumnWidth(n-1,h.width,!1),i.addColumn(n,c,!1)}else{h=i.rowDefinitions()[parseInt(n.toString(),10)];var d=new Yv;n>1?(d.height=e.undoObject.offset-l,h.height=l-a.offset):(d.height=h.height-l,h.height=l),i.updateRowHeight(n,h.height,!1),i.addRow(1+n,d,!1)}}(l=f.length,t,D,v,y),l>=0){var A=new ab(t.shape,"phases",e,!0);if(n.diagramActions&ee.UndoRedo||(A.id+=Qe()),u.phases.splice(l,0,A),Fx(v,n,t,i,y,l),y){if(r=n.nameTable[v.rows[parseInt(i.toString(),10)].cells[parseInt(l.toString(),10)].children[0].id],0===l&&u.header&&u.hasHeader){v.rows[0].cells[0].children=v.rows[0].cells[1].children,v.rows[0].cells[1].children=[];for(var x=v.rows[0],R=0;Rl+1){var O=n.nameTable[v.rows[parseInt(i.toString(),10)].cells[l+1].children[0].id];v.updateColumnWidth(l+1,L[l+1].width,!0,p),O.maxWidth=O.wrapper.maxWidth=L[l+1].width}t.width=t.wrapper.width=t.wrapper.children[0].width=v.width}else{r=n.nameTable[v.rows[i+l].cells[0].children[0].id];var N=v.rowDefinitions(),T=N[i+l].height;(function hne(n,t,e,i,r){for(var o,a,l=e.rows[parseInt(i.toString(),10)],h=e.rows[i+1],c=e.rows[i-1],d=1;di+l+1&&v.updateRowHeight(i+l+1,T=N[i+l+1].height,!0,p),t.height=t.wrapper.height=t.wrapper.children[0].height=v.actualSize.height}if(Qp(t),t.width=t.wrapper.actualSize.width,Oc(n,t),n.drag(t,c-t.wrapper.bounds.x,d-t.wrapper.bounds.y),RI(t,n),n.commandHandler.select(r),!(n.diagramActions&ee.UndoRedo)){var D={type:"PhaseCollectionChanged",changeType:"Insert",undoObject:$(A),redoObject:$(r),category:"Internal"};n.addHistoryEntry(D)}n.updateDiagramObject(t)}}}}function H3(n,t,e,i,r,s,o){var a,l,f,h=t.shape,c="Horizontal"===h.orientation,d=t.wrapper.children[0],g=c?s:o;e?(a=c?e.bounds.x+e.bounds.width:e.bounds.x,l=c?e.bounds.y:e.bounds.y+e.bounds.height):(a=d.bounds.x,l=r.bounds.y);var v=new Ne(a,l,i.desiredCellWidth,i.desiredCellHeight),S=Qv(n,0,t,{id:t.id+(c?h.lanes[g-2]:h.lanes[g-1]).id+Qe()[0],rowIndex:s,columnIndex:o,width:i.minWidth,height:i.minHeight,style:(c?h.lanes[g-2]:h.lanes[g-1]).style,constraints:ie.Default|ie.AllowDrop,container:{type:"Canvas",orientation:c?"Horizontal":"Vertical"}},!1,!1,!0);if(S.children[0].isCalculateDesiredSize=!1,d.addObject(S,s,o),r&&r.children&&r.children.length)for(f=0;f1)for(var f=1;fh.margin.left&&(h.margin.left=p)):(h.margin.top-=e.desiredCellHeight,p>h.margin.top&&(h.margin.top=p)))}(n,r,i,v,S,c,e)}function B3(n,t,e){if("SwimLane"===t.shape.type&&("ResizeSouth"===e||"ResizeEast"===e)){var i=t.shape,r=t.wrapper.children[0],s=void 0,o=void 0;"ResizeSouth"===e?"Vertical"===i.orientation?s=r.rows[r.rows.length-1].cells[0]:(o=r.rows.length-1,s=r.rows[parseInt(o.toString(),10)].cells[r.rows[parseInt(o.toString(),10)].cells.length-1]):(o=i.header&&i.hasHeader?1:0,s=r.rows[parseInt(o.toString(),10)].cells[r.rows[parseInt(o.toString(),10)].cells.length-1]),n.commandHandler.select(n.nameTable[s.children[0].id])}}function _I(n,t,e,i,r,s){var o,a,l,c,u,p,f,d=Qe(),g=n.shape,v=g.phases,y=n.offsetX-n.wrapper.actualSize.width/2,S=n.offsetY-n.wrapper.actualSize.height/2;if("Vertical"===g.orientation&&(S+=g.header&&g.hasHeader?g.header.height:0),!s)for(r||(n.id+=d,g&&g.header&&g.hasHeader?g.header.id+=d:g.header=void 0),o=0;v&&o0&&s.columnIndex>0||s.isLane)?(a=function Sne(n,t,e){for(var i=new Ne,r="SwimLane"===n.shape.type?n.wrapper.children[0].rows:n.wrapper.rows,s=e?1:0;s=0;a--)i?i.id===o.children[parseInt(a.toString(),10)].id&&o.children.splice(a,1):(n.removeDependentConnector(o.children[parseInt(a.toString(),10)]),n.diagramActions&ee.UndoRedo||(n.diagramActions=n.diagramActions|ee.UndoRedo,s=!0),n.remove(o.children[parseInt(a.toString(),10)]),o.children.splice(a,1),s&&(n.diagramActions=n.diagramActions&~ee.UndoRedo))}function dne(n){return n.children[0]}function qv(n,t){t&&(n.nodes.splice(n.nodes.indexOf(t),1),n.removeFromAQuad(t),n.removeObjectsFromLayer(t),delete n.nameTable[t.id],n.removeElements(t))}function _3(n,t,e,i){var r;if("SwimLane"===e.shape.type){var s=e.shape,o=void 0;if(1===s.lanes.length)n.remove(e);else{var a=e.wrapper.bounds.x,l=e.wrapper.bounds.y,h=void 0,c=void 0,d=void 0,u=void 0,f=e.wrapper.children[0];if(o=i?s.lanes.indexOf(i):HI(e,t),r={element:t,cause:n.diagramActions,diagramAction:n.getDiagramAction(n.diagramActions),state:"Changing",type:"Removal",cancel:!1,laneIndex:o},n.triggerEvent(Ce.collectionChange,r),!r.cancel){var g=s.lanes[parseInt(o.toString(),10)],v=g.children;g.children=[];for(var y=0;y0)for(u=0;u0)for(u=0;u0)for(e=0;e1){c===l.phases.length-1&&(o=!0,a=$(l.phases[c-1]));var u=$(l.phases[parseInt(c.toString(),10)]);if(l.phases.splice(c,1),!(n.diagramActions&ee.UndoRedo)){var p={type:"PhaseCollectionChanged",changeType:"Remove",undoObject:u,previousPhase:a,redoObject:$(t),category:"Internal",isLastPhase:o};n.addHistoryEntry(p)}"Horizontal"===l.orientation?function pne(n,t,e,i){var r,s,o,a,l,h,c,d,u,p,f,g;for(i=void 0!==i?i:e.columnIndex,c=0;c1&&(s=r.cells[parseInt(i.toString(),10)],l=(o=r.cells.length-1===i?r.cells[i-1]:r.cells[i+1]).children[0],s.children.length>0))if(f=n.nameTable[(a=s.children[0]).id],0===o.children.length&&s.children.length>0)o.children=s.children,o.columnSpan=s.columnSpan-1;else{for(d=0;d0){var M=s.children[0],w=n.nameTable[M.id];if(i=e.x&&a.bounds.y<=e.y&&a.bounds.bottom>=e.y)&&!(t.constraints&ie.AllowMovingOutsideLane)){var l=$(t);n.clearSelection(),W3(n,t),t.parentId="",t.parentObj=n,t.propName="nodes";var h={type:"ChildCollectionChanged",category:"Internal",undoObject:l,redoObject:$(t)};n.addHistoryEntry(h),n.commandHandler.isContainer&&(n.commandHandler.isContainer=!1,n.endGroupAction()),Y3(t,n)}n.protectPropertyChange(o)}}function UI(n,t){var e,i,r;return n.enableServerDataBinding(!1),ce()||(n.selectedObject.helperObject?r=n.selectedObject.helperObject:(n.selectedItems.nodes.length>0||n.selectedItems.connectors.length>0)&&(t instanceof oi&&t.nodes.length+t.connectors.length===1?(e=t.nodes.length>0?t.nodes[0]:t.connectors[0],i=n.selectedItems.wrapper.children[0]):(e=t,i=n.selectedItems.wrapper),n.selectedObject.actualObject=e,!n.currentSymbol&&(e.isLane&&Vx(e,n)&&cs(n,e)||!e.isLane&&cs(n,e)||n.constraints&rt.LineRouting&&n.selectedItems.nodes.length>0))&&(r=function Ine(n,t){for(var e,i={},r=0,s=Object.keys(t);r=t.x-e&&n.x<=t.x+e&&n.y>=t.y-e&&n.y<=t.y+e}function Xa(n){return n.selectedItems.nodes.length>0||n.selectedItems.connectors.length>0}function G3(n){return 1===n.selectedItems.connectors.length&&!n.selectedItems.nodes.length}function _r(n,t,e,i){if(void 0===e&&(e=!0),t instanceof oi)return!0;if(t instanceof te)for(;t;){if(-1!==n.selectedItems.nodes.indexOf(t)&&void 0===n.selectedItems.annotation)return!0;if(e)break;t=n.nameTable[t.parentId]}else if(t instanceof de){if(-1!==n.selectedItems.connectors.indexOf(t)&&void 0===n.selectedItems.annotation)return!0}else if((t instanceof Zn||t instanceof Nr)&&n.selectedItems.annotation&&n.selectedItems.wrapper.children[0].id===i.id)return!0;return!1}var Wx={None:"default",Rotate:"crosshair",Select:"default",Drag:"move",ResizeWest:"w-resize",ResizeEast:"e-resize",ResizeSouth:"s-resize",ResizeNorth:"n-resize",Draw:"crosshair",PortDraw:"crosshair",ResizeNorthEast:"ne-resize",ResizeNorthWest:"nw-resize",ResizeSouthEast:"se-resize",ResizeSouthWest:"sw-resize",ConnectorSourceEnd:"move",ConnectorTargetEnd:"move",BezierSourceThumb:"move",BezierTargetThumb:"move",OrthoThumb:"move",SegmentEnd:"move",Pan:"grab",Hyperlink:"pointer",PortDrag:"pointer",LabelSelect:"pointer",LabelDrag:"move",LabelRotate:"crosshair",LabelResizeWest:"w-resize",LabelResizeEast:"e-resize",LabelResizeSouth:"s-resize",LabelResizeNorth:"n-resize",LabelResizeNorthEast:"ne-resize",LabelResizeNorthWest:"nw-resize",LabelResizeSouthEast:"se-resize",LabelResizeSouthWest:"sw-resize"},ds=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Ld=function(n,t,e,i){return new(e||(e=Promise))(function(r,s){function o(h){try{l(i.next(h))}catch(c){s(c)}}function a(h){try{l(i.throw(h))}catch(c){s(c)}}function l(h){h.done?r(h.value):new e(function(c){c(h.value)}).then(o,a)}l((i=i.apply(n,t||[])).next())})},Nd=function(n,t){var i,r,s,o,e={label:0,sent:function(){if(1&s[0])throw s[1];return s[1]},trys:[],ops:[]};return o={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function a(h){return function(c){return function l(h){if(i)throw new TypeError("Generator is already executing.");for(;e;)try{if(i=1,r&&(s=2&h[0]?r.return:h[0]?r.throw||((s=r.return)&&s.call(r),0):r.next)&&!(s=s.call(r,h[1])).done)return s;switch(r=0,s&&(h=[2&h[0],s.value]),h[0]){case 0:case 1:s=h;break;case 4:return e.label++,{value:h[1],done:!1};case 5:e.label++,r=h[1],h=[0];continue;case 7:h=e.ops.pop(),e.trys.pop();continue;default:if(!(s=(s=e.trys).length>0&&s[s.length-1])&&(6===h[0]||2===h[0])){e=0;continue}if(3===h[0]&&(!s||h[1]>s[0]&&h[1]-1&&(r=i.fixedUserHandles[parseInt(o.toString(),10)]);this.commandHandler.triggerEvent(Ce.fixedUserHandleClick,{fixedUserHandle:r,element:e.source}),n.prototype.mouseUp.call(this,e)},t}(us),Od=function(n){function t(e,i){var r=n.call(this,e,!0)||this;return r.isConnected=!1,r.endPoint=i,r}return ds(t,n),t.prototype.mouseDown=function(e){return Ld(this,void 0,void 0,function(){var r,s,o,a,l;return Nd(this,function(h){if(this.inAction=!0,this.undoElement=void 0,this instanceof pa||(this.undoElement=$(e.source)),n.prototype.mouseDown.call(this,e),e.source&&e.source.connectors&&(this.oldConnector=$(r=e.source.connectors[0])),"BezierSourceThumb"===this.endPoint||"BezierTargetThumb"===this.endPoint)for(s=0;s0))},t.prototype.endAction=function(){n.prototype.endAction.call(this),this.prevPosition=null,this.endPoint=null},t}(us),ua=function(n){function t(e,i){var r=n.call(this,e,!0)||this;return r.currentTarget=null,r.isStartAction=!1,r.canCancel=!1,r.canTrigger=!1,r.objectType=i,r}return ds(t,n),t.prototype.mouseDown=function(e){if(e.source instanceof te||e.source instanceof de){var i=this.commandHandler.getSelectedObject();this.commandHandler.selectObjects([e.source],e.info&&e.info.ctrlKey,i);var r={nodes:[],connectors:[]};e.source instanceof te?r.nodes.push($(e.source)):r.connectors.push($(e.source)),this.undoElement=$(r)}else this.undoElement=$(e.source);this.undoParentElement=this.commandHandler.getSubProcess(e.source),"Port"===this.objectType&&(this.portId=e.sourceWrapper.id),this.commandHandler.insertBlazorConnector(e.source),n.prototype.mouseDown.call(this,e),this.initialOffset={x:0,y:0}},t.prototype.mouseUp=function(e,i){return Ld(this,void 0,void 0,function(){var s,o,a,l,h,c,d,u,f,g,v,y,S,b,M;return Nd(this,function(w){if(this.checkPropertyValue(),a=!1,h={nodes:[],connectors:[]},"Port"!==this.objectType){if(e.source instanceof te||e.source instanceof de?(e.source instanceof te?h.nodes.push($(e.source)):h.connectors.push($(e.source)),(o=$(h)).offsetX=(c=e.source.wrapper).offsetX,o.offsetY=c.offsetY):o=$(e.source),("helper"===(l=this.commandHandler.renderContainerHelper(e.source)||e.source||this.commandHandler.renderContainerHelper(e.source)).id||"helper"!==l.id)&&((l instanceof oi&&(Math.round(l.width)===Math.round(this.undoElement.width)&&Math.round(l.height)===Math.round(this.undoElement.height)||l.selectedObjects&&1===l.selectedObjects.length)||!(l instanceof oi))&&(l.offsetX!==this.undoElement.offsetX||l.offsetY!==this.undoElement.offsetY||l.sourcePoint!==this.undoElement.sourcePoint||l.targetPoint!==this.undoElement.targetPoint)||this.isSelectionHasConnector(l))&&(e.source&&(s={offsetX:e.source.wrapper.offsetX,offsetY:e.source.wrapper.offsetY}),g={source:e.source,state:"Completed",oldValue:this.intialValue,newValue:s,target:this.currentTarget,targetPosition:this.currentPosition,allowDrop:(g={source:e.source,state:"Completed",oldValue:this.intialValue,newValue:s,target:this.currentTarget,targetPosition:this.currentPosition,allowDrop:!0,cancel:!1}).allowDrop,cancel:g.cancel},d=!0,"helper"===l.id?this.canTrigger?(this.commandHandler.triggerEvent(Ce.positionChange,g),this.connectorEndPointChangeEvent(g),d=!0):d=!1:(this.commandHandler.triggerEvent(Ce.positionChange,g),this.connectorEndPointChangeEvent(g)),!i&&d&&(this.commandHandler.startGroupAction(),a=!0,M={type:"PositionChanged",redoObject:$(o),undoObject:$(this.undoElement),category:"Internal"},o.nodes[0]&&o.nodes[0].processId&&(u={type:"SizeChanged",category:"Internal",undoObject:this.undoParentElement,redoObject:this.commandHandler.getSubProcess(e.source)},this.commandHandler.addHistoryEntry(u)),this.commandHandler.addHistoryEntry(M))),this.commandHandler.snapPoint(this.prevPosition,this.currentPosition,0,0),this.commandHandler.removeSnap(),this.commandHandler.removeHighlighter(),e.source&&this.currentTarget&&OI(this.currentTarget)&&this.commandHandler.isDroppable(e.source,this.currentTarget)){if(f=!0,this.commandHandler.drop(this.currentElement,this.currentTarget,this.currentPosition),this.currentTarget&&this.currentTarget instanceof de&&!0===this.commandHandler.diagram.enableConnectorSplit)if(this.currentElement&&this.currentElement instanceof te){if(void 0!==this.currentElement.children)for(b=0;b0)for(var s=0;s0)for(var a=0;a0)for(a=0;a0&&e.connectors.length>0)||e.width===this.undoElement.width&&e.height===this.undoElement.height)},t.prototype.mouseMove=function(e){n.prototype.mouseMove.call(this,e);var r,s,i=!1;(r=this.commandHandler.renderContainerHelper(e.source)||e.source)instanceof te||r instanceof de?r instanceof te?r.offsetX===this.undoElement.nodes[0].offsetX&&r.offsetY===this.undoElement.nodes[0].offsetY&&(i=!0):z.equals(r.sourcePoint,this.undoElement.connectors[0].sourcePoint)&&z.equals(r.targetPoint,this.undoElement.connectors[0].targetPoint)&&(i=!0):r.wrapper.offsetX===this.undoElement.wrapper.offsetX&&r.wrapper.offsetY===this.undoElement.wrapper.offsetY&&(i=!0),r&&(s={offsetX:r.wrapper.offsetX,offsetY:r.wrapper.offsetY});var o={source:r,state:"Start",oldValue:s,newValue:s,target:e.target,targetPosition:e.position,allowDrop:!0,cancel:!1};if(o={source:r,state:"Start",oldValue:s,newValue:s,target:e.target,targetPosition:e.position,allowDrop:o.allowDrop,cancel:o.cancel},this.isStartAction||(this.intialValue={offsetX:r.wrapper.offsetX,offsetY:r.wrapper.offsetY}),i&&!ce()&&(this.commandHandler.triggerEvent(Ce.positionChange,o),this.connectorEndPointChangeEvent(o),this.isStartAction=!0),this.currentPosition=e.position,"Port"!==this.objectType){var h=this.initialOffset.x+(this.currentPosition.x-this.prevPosition.x),c=this.initialOffset.y+(this.currentPosition.y-this.prevPosition.y);this.commandHandler.dragOverElement(e,this.currentPosition),this.commandHandler.disConnect(e.source),this.commandHandler.removeSnap();var d,u=void 0,p=this.commandHandler.snapPoint(this.prevPosition,this.currentPosition,h,c);this.initialOffset.x=h-p.x,this.initialOffset.y=c-p.y,r&&(d={offsetX:r.wrapper.offsetX,offsetY:r.wrapper.offsetY},u={offsetX:r.wrapper.offsetX+p.x,offsetY:r.wrapper.offsetY+p.y}),this.currentTarget&&e.target!==this.currentTarget&&this.commandHandler.removeChildFromBPmn(e.source,e.target,this.currentTarget),this.currentTarget=e.target;var f={source:r,state:"Progress",oldValue:d,newValue:u,target:e.target,targetPosition:e.position,allowDrop:!0,cancel:!1};if(this.commandHandler.triggerEvent(Ce.positionChange,f),this.canTrigger=!0,this.connectorEndPointChangeEvent(f,p),!f.cancel&&!this.canCancel){this.blocked=!this.commandHandler.dragSelectedObjects(p.x,p.y);var g=!this.commandHandler.mouseOver(this.currentElement,this.currentTarget,this.currentPosition);this.blocked=this.blocked||g}if(this.commandHandler.removeStackHighlighter(),this.commandHandler.renderStackHighlighter(e),this.currentTarget&&e.source!==this.currentTarget&&this.commandHandler.isDroppable(e.source,this.currentTarget)&&"helper"!==e.source.id){var v=e.source instanceof oi?e.source.nodes[0]:e.source;!this.commandHandler.isParentAsContainer(v,!0)&&"SwimLane"!==v.shape.type&&!v.shape.isPhase&&(this.currentTarget.isLane?this.commandHandler.renderStackHighlighter(e,this.currentTarget):this.commandHandler.drawHighlighter(this.currentTarget))}else this.commandHandler.removeHighlighter();if(this.commandHandler.canEnableDefaultTooltip()){var y=this.getTooltipContent(e.source);this.commandHandler.showTooltip(e.source,e.position,ko(function(){return y}),"MoveTool",this.isTooltipVisible),this.isTooltipVisible=!1}}else{var b=Hi(),M=e.source;qi(b,-M.rotateAngle||-M.wrapper.rotateAngle,M.offsetX||M.wrapper.offsetX,M.offsetY||M.wrapper.offsetY);var w=Je(b,{x:this.prevPosition.x,y:this.prevPosition.y}),C=Je(b,{x:e.position.x,y:e.position.y});this.commandHandler.portDrag(e.source,e.sourceWrapper,C.x-w.x,C.y-w.y)}return this.prevPosition=this.currentPosition,!this.blocked},t.prototype.getTooltipContent=function(e){return"X:"+Math.round(e.wrapper.bounds.x)+" Y:"+Math.round(e.wrapper.bounds.y)},t.prototype.mouseLeave=function(e){this.mouseUp(e)},t.prototype.endAction=function(){n.prototype.endAction.call(this),this.currentTarget=null,this.prevPosition=null},t}(us),Yx=function(n){function t(e){var i=n.call(this,e,!0)||this;return i.rotateStart=!1,i}return ds(t,n),t.prototype.mouseDown=function(e){if(this.undoElement=$(e.source),this.undoElement.nodes[0]&&this.undoElement.nodes[0].children)for(var r=this.commandHandler.getAllDescendants(this.undoElement.nodes[0],[]),s=0;s=2){var s=e.startTouches[0],o=e.startTouches[1],a=e.moveTouches[0],l=e.moveTouches[1],h=this.getDistance(a,l)/this.getDistance(s,o);this.commandHandler.zoom(h,0,0,e.position),this.updateTouch(s,a),this.updateTouch(o,l)}}else this.commandHandler.scroll(this.currentPosition.x-this.prevPosition.x,this.currentPosition.y-this.prevPosition.y,this.currentPosition);return this.commandHandler.dataBinding(),!this.blocked},t.prototype.mouseUp=function(e){this.commandHandler.setBlazorDiagramProps(!1),this.checkPropertyValue(),this.commandHandler.updatePanState(!1),n.prototype.mouseUp.call(this,e),this.inAction=!1},t.prototype.endAction=function(){n.prototype.endAction.call(this)},t.prototype.getDistance=function(e,i){var r=i.pageX-e.pageX,s=i.pageY-e.pageY;return Math.sqrt(r*r+s*s)},t.prototype.updateTouch=function(e,i){e.pageX=i.pageX,e.pageY=i.pageY},t}(us),Lne=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseUp=function(e){this.checkPropertyValue(),this.commandHandler.initExpand(e),n.prototype.mouseUp.call(this,e)},t}(us),X3=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseUp=function(e){this.checkPropertyValue();var i="_blank",r="",s=window.innerHeight,o=window.innerWidth,a=window.screenTop,l=window.screenLeft;"CurrentTab"===e.sourceWrapper.hyperlink.hyperlinkOpenState?i="_self":"NewWindow"===e.sourceWrapper.hyperlink.hyperlinkOpenState&&(r="height="+s+",width="+o+",top="+a+",left="+l),window.open(e.sourceWrapper.hyperlink.link,i,r).focus(),n.prototype.mouseUp.call(this,e)},t}(us),Oh=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseDown=function(e){if(n.prototype.mouseDown.call(this,e),this.inAction=!0,this.drawingObject){var r=void 0,s=this.drawingObject.shape;this.drawingObject.shape.points.push(r={x:(r=s.points[s.points.length-1]).x,y:r.y})}else this.startPoint={x:this.startPosition.x,y:this.startPosition.y},this.drawingObject=this.commandHandler.drawObject({offsetX:this.currentPosition.x,offsetY:this.currentPosition.y,width:5,height:5,style:{strokeColor:"black",strokeWidth:1},shape:{type:"Basic",shape:"Polygon",points:[{x:this.startPoint.x,y:this.startPoint.y},{x:this.currentPosition.x,y:this.currentPosition.y}]}})},t.prototype.mouseMove=function(e){if(n.prototype.mouseMove.call(this,e),this.inAction){var i=this.drawingObject.shape;if(i.points[i.points.length-1].x=this.currentPosition.x,i.points[i.points.length-1].y=this.currentPosition.y,this.drawingObject.wrapper.children[0].data=vx(this.drawingObject.shape.points),this.inAction&&!1===z.equals(this.currentPosition,this.prevPosition)){var r=Ne.toBounds(this.drawingObject.shape.points);this.commandHandler.updateNodeDimension(this.drawingObject,r)}}return!0},t.prototype.mouseUp=function(e,i){this.checkPropertyValue(),n.prototype.mouseMove.call(this,e),this.inAction&&(this.inAction=!1,this.commandHandler.addObjectToDiagram(this.drawingObject)),this.endAction()},t.prototype.mouseWheel=function(e){n.prototype.mouseWheel.call(this,e),this.mouseMove(e)},t.prototype.endAction=function(){this.inAction=!1,this.drawingObject=null},t}(us),kh=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseMove=function(e){if(n.prototype.mouseMove.call(this,e),this.inAction){var i=this.drawingObject;i.targetPoint=this.currentPosition,this.commandHandler.updateConnectorPoints(i)}return!0},t.prototype.mouseDown=function(e){if(n.prototype.mouseDown.call(this,e),this.inAction=!0,this.drawingObject){var r=this.drawingObject,s=void 0;(s=new kl(r,"segments",{type:"Straight"},!0)).point=this.currentPosition,r.segments[r.segments.length-1]=s}else this.drawingObject=this.commandHandler.drawObject({id:"Connector",type:"Straight",sourcePoint:this.currentPosition,targetPoint:this.currentPosition})},t.prototype.mouseWheel=function(e){n.prototype.mouseWheel.call(this,e),this.mouseMove(e)},t.prototype.mouseUp=function(e){if(this.checkPropertyValue(),n.prototype.mouseMove.call(this,e),this.inAction&&this.drawingObject){var i=this.drawingObject;i.segments[i.segments.length-1].point={x:0,y:0},this.commandHandler.addObjectToDiagram(this.drawingObject)}this.endAction()},t.prototype.endAction=function(){this.drawingObject=null,this.inAction=!1},t}(us),Nne=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseDown=function(e){this.inAction=!0,this.undoElement=$(e.source),this.annotationId=e.sourceWrapper.id,n.prototype.mouseDown.call(this,e)},t.prototype.mouseMove=function(e){n.prototype.mouseMove.call(this,e);var i=this.currentPosition.x-this.prevPosition.x,r=this.currentPosition.y-this.prevPosition.y,s=e.source;if(s instanceof te){var o=Hi();qi(o,-s.rotateAngle,0,0);var a=Je(o,{x:i,y:r});i=a.x,r=a.y}return this.inAction&&(this.commandHandler.labelDrag(e.source,e.sourceWrapper,i,r),this.commandHandler.updateSelector()),this.prevPosition=this.currentPosition,!this.blocked},t.prototype.mouseUp=function(e){this.checkPropertyValue();var i=e.source;this.inAction=!1;var r={type:"AnnotationPropertyChanged",objectId:this.annotationId,undoObject:$(this.undoElement),category:"Internal",redoObject:$(i)};this.commandHandler.addHistoryEntry(r),n.prototype.mouseUp.call(this,e)},t.prototype.mouseLeave=function(e){this.mouseUp(e)},t}(us),One=function(n){function t(e,i){var r=n.call(this,e,!0)||this;return r.corner=i,r}return ds(t,n),t.prototype.mouseDown=function(e){this.inAction=!0;var i=e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0];this.annotationId=e.source.wrapper.children[0].id,this.undoElement=$(i);var r=e.source.wrapper.children[0];this.initialBounds={x:r.offsetX,y:r.offsetY,width:r.actualSize.width,height:r.actualSize.height},n.prototype.mouseDown.call(this,e)},t.prototype.mouseMove=function(e){return n.prototype.mouseMove.call(this,e),this.inAction&&this.resizeObject(e),!this.blocked},t.prototype.mouseUp=function(e){this.checkPropertyValue();var i=e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0];this.inAction=!1;var r={type:"AnnotationPropertyChanged",objectId:this.annotationId,redoObject:$(i),undoObject:$(this.undoElement),category:"Internal"};this.commandHandler.addHistoryEntry(r),n.prototype.mouseUp.call(this,e)},t.prototype.mouseLeave=function(e){this.mouseUp(e)},t.prototype.resizeObject=function(e){var i,s,o,r=e.source.wrapper.children[0],a={x:r.offsetX,y:r.offsetY},l=r.rotateAngle;l=((l+=(i=e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0])instanceof te?i.rotateAngle:0)+360)%360;var h=Hi();qi(h,l,a.x,a.y);var c=this.corner.slice(5),d=this.updateSize(r,this.startPosition,this.currentPosition,c,this.initialBounds,l),u=r.offsetX-r.actualSize.width*r.pivot.x,p=r.offsetY-r.actualSize.height*r.pivot.y,f=this.getPivot(c),g=Je(h,f={x:u+r.actualSize.width*f.x,y:p+r.actualSize.height*f.y});d.x=g.x,d.y=g.y,this.commandHandler.labelResize(i,e.source.annotation,s=(s=d.width)<0?1:s,o=(o=d.height)<0?1:o,d,e.source),this.commandHandler.updateSelector()},t}(us),kne=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseDown=function(e){this.inAction=!0,this.annotationId=e.source.wrapper.children[0].id,this.undoElement=$(e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0]),n.prototype.mouseDown.call(this,e)},t.prototype.mouseMove=function(e){return n.prototype.mouseMove.call(this,e),e.source&&this.inAction&&(this.commandHandler.labelRotate(e.source.nodes[0]?e.source.nodes[0]:e.source.connectors[0],e.source.annotation,this.currentPosition,e.source),this.commandHandler.updateSelector()),this.prevPosition=this.currentPosition,!this.blocked},t.prototype.mouseUp=function(e){this.checkPropertyValue(),this.inAction=!1;var r={type:"AnnotationPropertyChanged",objectId:this.annotationId,redoObject:$(e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0]),undoObject:$(this.undoElement),category:"Internal"};this.commandHandler.addHistoryEntry(r),n.prototype.mouseUp.call(this,e)},t.prototype.mouseLeave=function(e){this.mouseUp(e)},t}(us),Pne=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseMove=function(e){if(n.prototype.mouseMove.call(this,e),this.inAction){var i=this.drawingObject.shape;if(i.points.push(this.currentPosition),this.drawingObject.wrapper.children[0].data=mx(this.drawingObject.shape.points),i.data=mx(i.points),this.inAction&&!1===z.equals(this.currentPosition,this.prevPosition)){var s=Ne.toBounds(this.drawingObject.shape.points);this.commandHandler.updateNodeDimension(this.drawingObject,s)}}return!0},t.prototype.mouseDown=function(e){n.prototype.mouseDown.call(this,e),this.inAction=!0,this.startPoint={x:this.startPosition.x,y:this.startPosition.y},this.drawingObject=this.commandHandler.drawObject({offsetX:this.currentPosition.x,offsetY:this.currentPosition.y,width:5,height:5,style:{strokeColor:"black",strokeWidth:1,fill:"transparent"},shape:{type:"Path",points:[{x:this.startPoint.x,y:this.startPoint.y},{x:this.currentPosition.x,y:this.currentPosition.y}]}})},t.prototype.mouseUp=function(e){if(this.checkPropertyValue(),this.inAction){this.inAction=!1;var s=this.drawingObject.shape,o=s.points;this.commandHandler.addObjectToDiagram(this.drawingObject),this.commandHandler.diagram.remove(this.commandHandler.diagram.nameTable[""+this.drawingObject.id]),o=this.pointReduction(o,10);var h={id:"newConnector"+Qe(),type:"Bezier",sourcePoint:{x:o[0].x,y:o[0].y},targetPoint:{x:o[o.length-1].x,y:o[o.length-1].y},segments:[],bezierSettings:{allowSegmentsReset:!1}};this.drawingObject=this.commandHandler.drawObject(h),this.drawingObject=this.bezierCurveSmoothness(o,.5,this.drawingObject,s),this.commandHandler.updateConnectorPoints(this.drawingObject),this.commandHandler.addObjectToDiagram(this.drawingObject),n.prototype.mouseUp.call(this,e)}},t.prototype.pointReduction=function(e,i){if(null===e||e.length<3)return e;var s=e.length-1,o=[];for(o.push(0),o.push(s);e[parseInt((0).toString(),10)]===e[parseInt(s.toString(),10)];)s--;this.reduction(e,0,s,i,o);var a=[];return o.sort(function(l,h){return l-h}),o.forEach(function(l){a.push(e[parseInt(l.toString(),10)])}),a},t.prototype.reduction=function(e,i,r,s,o){for(var a=0,l=0,h=i;ha&&(a=c,l=h)}a>s&&0!==l&&(o.push(l),this.reduction(e,i,l,s,o),this.reduction(e,l,r,s,o))},t.prototype.perpendicularDistance=function(e,i,r){return Math.abs(.5*(e.x*i.y-i.x*e.y+(i.x*r.y-r.x*i.y)+(r.x*e.y-e.x*r.y)))/Math.sqrt(Math.pow(e.x-i.x,2)+Math.pow(e.y-i.y,2))*2},t.prototype.bezierCurveSmoothness=function(e,i,r,s){if(e.length<3)return r;for(var o=0;o=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},zne=function(n){if(n)switch(n.type){case"Bpmn":return Fne;case"UmlActivity":return Bne;case"UmlClassifier":return jne;default:return Kv}return Kv},Rne=function(n){if(n)switch(n.type){case"Straight":default:return kl;case"Bezier":return ps;case"Orthogonal":return bi}},q3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I(10)],t.prototype,"width",void 0),Pe([I(10)],t.prototype,"height",void 0),Pe([I("Arrow")],t.prototype,"shape",void 0),Pe([re({fill:"black",strokeColor:"black",strokeWidth:1},Al)],t.prototype,"style",void 0),Pe([re({x:0,y:.5},z)],t.prototype,"pivot",void 0),Pe([I("")],t.prototype,"pathData",void 0),t}(Ee),YI=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I(0)],t.prototype,"angle",void 0),Pe([I(0)],t.prototype,"distance",void 0),t}(Ee),Hne=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I(bx.All)],t.prototype,"controlPointsVisibility",void 0),Pe([I("FreeForm")],t.prototype,"segmentEditOrientation",void 0),Pe([I(mI.Default)],t.prototype,"smoothness",void 0),Pe([I(!0)],t.prototype,"allowSegmentsReset",void 0),t}(Ee),Kv=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I("None")],t.prototype,"type",void 0),t}(Ee),Bne=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I("Object")],t.prototype,"flow",void 0),Pe([I(30)],t.prototype,"exceptionFlowHeight",void 0),t}(Kv),Fne=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I("Sequence")],t.prototype,"flow",void 0),Pe([I("Normal")],t.prototype,"sequence",void 0),Pe([I("Default")],t.prototype,"message",void 0),Pe([I("Default")],t.prototype,"association",void 0),t}(Kv),$3=function(n){function t(e,i,r,s){var o=n.call(this,e,i,r,s)||this;return o.points=[],o}return Qs(t,n),Pe([I("Straight")],t.prototype,"type",void 0),Pe([I(!0)],t.prototype,"allowDrag",void 0),t}(Ee),kl=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),t.prototype.getClassName=function(){return"StraightSegment"},Pe([re({x:0,y:0},z)],t.prototype,"point",void 0),t}($3),ps=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),t.prototype.getClassName=function(){return"BezierSegment"},t.prototype.getPoints=function(e,i){var r=[];if(r.length>0||null!=i){var o=this.bezireToPoly(r.length>0?r[r.length-1]:i,e);r.push.apply(r,o)}return r},t.prototype.bezireToPoly=function(e,i){var r=[];return i&&this.flattenCubicBezier(r,e,i.bezierPoint1,i.bezierPoint2,{x:i.points[1].x,y:i.points[1].y},10),r},t.prototype.flattenCubicBezier=function(e,i,r,s,o,a){var h,l=(z.findLength(i,r)+z.findLength(r,s)+z.findLength(s,o))/a;for(h=0;h<=l;h++){var c=h/l;e.push({x:(1-c)*(1-c)*(1-c)*i.x+3*c*(1-c)*(1-c)*r.x+3*c*c*(1-c)*s.x+c*c*c*o.x,y:(1-c)*(1-c)*(1-c)*i.y+3*c*(1-c)*(1-c)*r.y+3*c*c*(1-c)*s.y+c*c*c*o.y})}},Pe([I("Horizontal")],t.prototype,"orientation",void 0),Pe([re({x:0,y:0},z)],t.prototype,"point1",void 0),Pe([re({x:0,y:0},z)],t.prototype,"point2",void 0),Pe([re({angle:0,distance:0},YI)],t.prototype,"vector1",void 0),Pe([re({angle:0,distance:0},YI)],t.prototype,"vector2",void 0),t}(kl),bi=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),t.prototype.getClassName=function(){return"OrthogonalSegment"},Pe([I(null)],t.prototype,"length",void 0),Pe([I(null)],t.prototype,"direction",void 0),t}($3);function Z3(n,t,e){var s=e?45:180/(2+2/(n.height/n.width)),o=s,a=180-s,l=a+2*s,h=360-s,c=Xt(t,n.center);return c>o&&ca&&cl&&cMath.abs(t.y-n.y)?n.x=c)return s=z.findAngle(n[parseInt(d.toString(),10)],n[d+1]),{point:r=z.transform(n[parseInt(d.toString(),10)],s,c-(a||0)),index:l=d};a=o[parseInt(d.toString(),10)]}return{point:r,index:l}}(n,t),r=z.findAngle(n[i.index],n[i.index+1]),s=function vse(n){var e=0;switch(n.alignment){case"Center":case"After":e=0;break;case"Before":e=-0}return e}(t),o=z.transform(i.point,r+45,s);return i.point=o,i.angle=r,i}(i,e),h=l.point;s.id=this.id+"_"+e.id;var c=e.style;s.style={fill:c.fill,strokeColor:c.strokeColor,gradient:null,opacity:c.opacity,strokeDashArray:c.strokeDashArray,strokeWidth:c.strokeWidth},0===r.width&&(r.width=this.style.strokeWidth),0===r.height&&(r.height=this.style.strokeWidth);var d_y=(h.y-r.y)/r.height;a.x=r.width*((h.x-r.x)/r.width),a.y=r.height*d_y;var g,v,u=pF(e,l.angle,i),p=u.hAlign,f=u.vAlign;return"left"===p?(g="Left",a.x+=e.displacement.x):"right"===p?(g="Right",a.x-=e.displacement.x):"center"===p&&(g="Center"),"top"===f?(v="Top",a.y+=e.displacement.y):"bottom"===f?(v="Bottom",a.y-=e.displacement.y):"center"===f&&(v="Center"),s.horizontalAlignment=g,s.verticalAlignment=v,(s=im(s,o&&"Label"!==o.flipMode&&"None"!==o.flipMode?this.flip:"None",e)).float=!0,s.connectionDirection=e.connectionDirection,s.setOffsetWithRespectToBounds(a.x,a.y,"Absolute"),s.relativeMode="Point",s.visible=!(!ga(e,Gt.Visible)||ga(e,Gt.Hover)||ga(e,Gt.Connect)),s.elementActions=s.elementActions|Xr.ElementIsPort,s},t.prototype.getConnectorRelation=function(){var e=this.shape;"Association"===e.relationship?(this.segments[0].type="Straight",this.sourceDecorator.shape="None",this.targetDecorator.shape="Arrow"):"Inheritance"===e.relationship?(this.segments[0].type="Orthogonal",this.sourceDecorator.shape="None",this.targetDecorator.shape="Arrow"):"Composition"===e.relationship||"Aggregation"===e.relationship?(this.segments[0].type="Orthogonal",this.sourceDecorator.shape="Diamond",this.targetDecorator.shape="None"):"Dependency"===e.relationship?(this.segments[0].type="Orthogonal",this.sourceDecorator.shape="None",this.targetDecorator.shape="OpenArrow"):"Realization"===e.relationship&&(this.segments[0].type="Orthogonal",this.sourceDecorator.shape="None",this.targetDecorator.shape="Arrow"),"BiDirectional"===e.associationType&&(this.sourceDecorator.shape="None",this.targetDecorator.shape="None");var i,o,r="",s="";e.multiplicity.source&&(e.multiplicity.source.lowerBounds=e.multiplicity.source.lowerBounds,e.multiplicity.source.upperBounds=e.multiplicity.source.upperBounds),e.multiplicity.target&&(e.multiplicity.target.lowerBounds=e.multiplicity.target.lowerBounds,e.multiplicity.target.upperBounds=e.multiplicity.target.upperBounds);var a=e.multiplicity.source,l=e.multiplicity.target;o=a.upperBounds?a.lowerBounds+"..."+a.upperBounds:a.lowerBounds,i=l.upperBounds?l.lowerBounds+"..."+l.upperBounds:l.lowerBounds,"ManyToOne"===e.multiplicity.type&&(e.multiplicity.target.optional=!1,r=o||"*",s="1"),"OneToMany"===e.multiplicity.type&&(e.multiplicity.source.optional=!1,s=i||"*",r="1"),"ManyToMany"===e.multiplicity.type&&(r=o||"*",s=i||"*"),"OneToOne"===e.multiplicity.type&&(e.multiplicity.target.optional=!1,e.multiplicity.source.optional=!1,r="1",s="1"),this.annotations=[{id:this.id+"sourcelabel",content:r,offset:0,alignment:"Before",margin:{right:5,bottom:5}},{id:this.id+"targetlabel",content:s,offset:1,alignment:"Before",margin:{right:5,bottom:5}}]},t.prototype.getBpmnSequenceFlow=function(){var e=new Ke,i=new Ke;return"Normal"===this.shape.sequence&&"Bezier"!==this.type&&(this.targetDecorator.shape="Arrow"),"Default"===this.shape.sequence&&(e=this.getSegmentElement(this,e),i=IF(this.intermediatePoints,this),this.targetDecorator.shape="Arrow"),"Conditional"===this.shape.sequence&&(this.targetDecorator.shape="Arrow",this.sourceDecorator.shape="Diamond",i.id=this.id+this.shape.type),i},t.prototype.getUMLObjectFlow=function(){if(this.annotations)for(var e=0;e0&&(this.sourcePoint=o[0],this.targetPoint=o[o.length-1]),o},t.prototype.clipDecorator=function(e,i,r,s){var a,l,o={x:0,y:0},h=i.length,c=z.distancePoints(a=r?i[0]:i[h-1],l=r?i[1]:i[h-2]);c=0===c?1:c;var d=1,u=r?e.sourceWrapper:e.targetWrapper;u&&(d=u.style.strokeWidth,s&&s&ee.DecoratorPropertyChange&&(d=1));var p=d-1;return o.x=Math.round(a.x+p*(l.x-a.x)/c),o.y=Math.round(a.y+p*(l.y-a.y)/c),(r&&"None"!==e.sourceDecorator.shape||!r&&"None"!==e.targetDecorator.shape)&&(o=z.adjustPoint(o,l,!0,s&ee.DecoratorPropertyChange?0:d/2)),o},t.prototype.clipDecorators=function(e,i,r){return"None"!==e.sourceDecorator.shape&&(i[0]=this.clipDecorator(e,i,!0,r)),"None"!==e.targetDecorator.shape&&(i[i.length-1]=this.clipDecorator(e,i,!1,r)),i},t.prototype.updateSegmentElement=function(e,i,r,s){var o=new Ne,a=this.getSegmentPath(e,i,s);if("Bezier"===e.type){if(this.segments.length>0)for(var l=0;l0)if("Straight"===e.type&&e.segments.length<2)for(var o=0;o1)for(o=0;o0&&"Bezier"!==this.type)for(var p=0;p0&&(a=p0&&(f<2*this.cornerRadius?(l=z.adjustPoint(h[parseInt(p.toString(),10)],h[p+1],!0,f/2),p0&&(s=this.bridgePath(e,s,p),"Orthogonal"===e.type&&(s=this.bridgePath(e,s,p+1))),s+=" L"+a.x+" "+a.y))}else if("Bezier"===this.type){var g=void 0,v=void 0;if(this.parentObj.element){var y=this.parentObj.element.ej2_instances[0].eventHandler.action;g=this.parentObj.element.ej2_instances[0].eventHandler.tool instanceof kd,v=y.includes("PortDraw")||y.includes("Drag")}for(var S=void 0,b=this.segments,M=0;M2&&(b[parseInt(M.toString(),10)].bezierPoint1={x:0,y:0},b[parseInt(M.toString(),10)].bezierPoint2={x:0,y:0}),!z.isEmptyPoint(b[parseInt(M.toString(),10)].point1)||b[parseInt(M.toString(),10)].vector1.angle||b[parseInt(M.toString(),10)].vector1.distance?b[parseInt(M.toString(),10)].vector1.angle||b[parseInt(M.toString(),10)].vector1.distance?b[parseInt(M.toString(),10)].bezierPoint1=z.transform(h[parseInt(M.toString(),10)],b[parseInt(M.toString(),10)].vector1.angle,b[parseInt(M.toString(),10)].vector1.distance):b[parseInt(M.toString(),10)].bezierPoint1={x:b[parseInt(M.toString(),10)].point1.x||b[parseInt(M.toString(),10)].bezierPoint1.x,y:b[parseInt(M.toString(),10)].point1.y||b[parseInt(M.toString(),10)].bezierPoint1.y}:((e.sourceID||this.sourcePortID)&&this.sourceWrapper&&!v&&!g&&(S=Z3(this.sourceWrapper.bounds,h[parseInt(M.toString(),10)],!0)),b[parseInt(M.toString(),10)].bezierPoint1=GI(h[parseInt(M.toString(),10)],h[M+1],S)),!z.isEmptyPoint(b[parseInt(M.toString(),10)].point2)||b[parseInt(M.toString(),10)].vector2.angle||b[parseInt(M.toString(),10)].vector2.distance?b[parseInt(M.toString(),10)].vector2.angle||b[parseInt(M.toString(),10)].vector2.distance?b[parseInt(M.toString(),10)].bezierPoint2=z.transform(h[M+1],b[parseInt(M.toString(),10)].vector2.angle,b[parseInt(M.toString(),10)].vector2.distance):b[parseInt(M.toString(),10)].bezierPoint2={x:b[parseInt(M.toString(),10)].point2.x||b[parseInt(M.toString(),10)].bezierPoint2.x,y:b[parseInt(M.toString(),10)].point2.y||b[parseInt(M.toString(),10)].bezierPoint2.y}:((e.targetID||this.targetPortID)&&this.targetWrapper&&!v&&!g&&(S=Z3(this.targetWrapper.bounds,h[M+1],!0)),b[parseInt(M.toString(),10)].bezierPoint2=GI(h[M+1],h[parseInt(M.toString(),10)],S));h.splice(1,0,{x:b[0].bezierPoint1.x,y:b[0].bezierPoint1.y}),h.splice(h.length-1,0,{x:b[b.length-1].bezierPoint2.x,y:b[b.length-1].bezierPoint2.y}),h=this.clipDecorators(e,h,r);for(var w=0;w0&&(s=this.bridgePath(e,s,D),s+=" L"+o.x+" "+o.y);return s},t.prototype.updateShapeElement=function(e){var i;switch(e.shape.type){case"Bpmn":e.wrapper.children[3]instanceof Ke&&(i=e.wrapper.children[3]),"Message"===e.shape.flow&&this.updateShapePosition(e,i);break;case"UmlActivity":"Exception"===e.shape.flow&&this.getUMLExceptionFlow(e.wrapper.children[0])}},t.prototype.updateShapePosition=function(e,i){var o=bF(this.intermediatePoints,i,.5);i.offsetX=o.x,i.offsetY=o.y},t.prototype.scale=function(e,i,r,s,o){var a=0,l=0;if(this.wrapper&&this.wrapper.outerBounds){var h=function M3(n){var t=n.wrapper.children[0].bounds;return"None"!==n.sourceDecorator.shape&&t.uniteRect(n.wrapper.children[1].bounds),"None"!==n.targetDecorator.shape&&t.uniteRect(n.wrapper.children[2].bounds),t}(this),c=Math.abs((this.wrapper.bounds.width||this.style.strokeWidth||1)-2),d=Math.abs((this.wrapper.bounds.height||this.style.strokeWidth||1)-2);a=h.width-c,l=h.height-d,e=Math.abs((r-Math.max(a,l))/c),i=Math.abs((s-Math.max(a,l))/d),a=l=Math.min(a,l)}e=i=Math.min(e,i);var u=Hi();qi(u,-(o=o||this.wrapper).rotateAngle,o.offsetX,o.offsetY),Wp(u,e,i,o.offsetX,o.offsetY),qi(u,o.rotateAngle,o.offsetX,o.offsetY);var p=function Lie(n,t){for(var e=[],i=0,r=t;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Wne=function(n){function t(e,i){var r=n.call(this,e,i)||this;return r.offset=0,r.scale=1,r}return Vne(t,n),t.prototype.preRender=function(){this.unWireEvents(),this.wireEvents()},t.prototype.render=function(){this.updateRulerGeometry(),this.renderComplete()},t.prototype.getModuleName=function(){return"Ruler"},t.prototype.destroy=function(){this.unWireEvents(),this.notify("destroy",{}),n.prototype.destroy.call(this),this.element.classList.remove("e-ruler")},t.prototype.getPersistData=function(){return this.addOnPersist(["loaded"])},t.prototype.onPropertyChanged=function(e,i){for(var r=0,s=Object.keys(e);r100;)r/=10,s/=10;for(;s<25;)r*=10,s*=10;return s>=25&&s%25!=0&&(s=25*Math.round(s/25)),s*e/r},t.prototype.createMarkerLine=function(e,i,r){var s;return i&&((s=e.getElementById(i.id+"_marker"))&&s.parentNode.removeChild(s),s=Bi("line",r)),s},t.prototype.drawRulerMarker=function(e,i,r){var s,o,h,d,u="Horizontal"===this.orientation,p=e.getElementsByTagName("svg");for(h=0;h0)for(var a=i.childNodes.length-1;a>=0;a--)i.childNodes[parseInt(a.toString(),10)].parentNode.removeChild(i.childNodes[parseInt(a.toString(),10)]);i.appendChild(s)}return s},t.prototype.wireEvents=function(){},t.prototype.unWireEvents=function(){},kc([I(5)],t.prototype,"interval",void 0),kc([I(100)],t.prototype,"segmentWidth",void 0),kc([I("Horizontal")],t.prototype,"orientation",void 0),kc([I("RightOrBottom")],t.prototype,"tickAlignment",void 0),kc([I("red")],t.prototype,"markerColor",void 0),kc([I(25)],t.prototype,"thickness",void 0),kc([I(null)],t.prototype,"arrangeTick",void 0),kc([I(400)],t.prototype,"length",void 0),t}(yi);function eF(n,t){var e=document.getElementById(n.element.id+(t?"_hRuler":"_vRuler")),i=qa(n),r=tF(n);e||(e=Tt("div",{id:n.element.id+(t?"_hRuler":"_vRuler"),style:"height:"+(t?i.height:r.height+100)+"px;overflow:hidden;width:"+(t?r.width+100:i.width)+"px;position:absolute;font-size:11px;"+(t?"margin-left:"+i.width+"px;":"margin-top:"+i.height+"px;")})),n.element.insertBefore(e,n.element.firstChild);var l=t?n.rulerSettings.horizontalRuler:n.rulerSettings.verticalRuler,h=new Wne(l);h.orientation=t?"Horizontal":"Vertical",h.length=(t?r.width:r.height)+l.segmentWidth,h.appendTo("#"+n.element.id+(t?"_hRuler":"_vRuler")),t?n.hRuler=h:n.vRuler=h;var c=document.getElementById(n.element.id+(t?"_hRuler":"_vRuler"));t?n.hRuler.element=c:n.vRuler.element=c}function XI(n){var t=-n.scroller.horizontalOffset,e=-n.scroller.verticalOffset;n&&n.rulerSettings.showRulers?(n.hRuler.length=0,n.vRuler.length=0,void 0!==t&&n.hRuler.element&&iF(n,n.hRuler,t,!0),void 0!==e&&n.vRuler.element&&iF(n,n.vRuler,e,!1)):Qx(n)}function Qx(n){an(n.element.id+"_hRuler"),an(n.element.id+"_vRuler"),an(n.element.id+"_overlapRuler")}function qa(n){var t=0,e=0;return n.rulerSettings.showRulers&&(t=n.rulerSettings.horizontalRuler.thickness,e=n.rulerSettings.verticalRuler.thickness),new me(e,t)}function tF(n){var t=qa(n),e=n.scroller.viewPortHeight,i=n.scroller.viewPortWidth;return i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},rF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return $ne(t,n),t.prototype.getClassName=function(){return"UserHandle"},Fn([I("")],t.prototype,"name",void 0),Fn([I("")],t.prototype,"pathData",void 0),Fn([I("")],t.prototype,"content",void 0),Fn([I("")],t.prototype,"source",void 0),Fn([I("#000000")],t.prototype,"backgroundColor",void 0),Fn([I("Top")],t.prototype,"side",void 0),Fn([I("")],t.prototype,"borderColor",void 0),Fn([I(.5)],t.prototype,"borderWidth",void 0),Fn([I(25)],t.prototype,"size",void 0),Fn([I("white")],t.prototype,"pathColor",void 0),Fn([I(10)],t.prototype,"displacement",void 0),Fn([I(!0)],t.prototype,"visible",void 0),Fn([I(0)],t.prototype,"offset",void 0),Fn([re({},$n)],t.prototype,"margin",void 0),Fn([I("Center")],t.prototype,"horizontalAlignment",void 0),Fn([I("Center")],t.prototype,"verticalAlignment",void 0),Fn([I(!1)],t.prototype,"disableNodes",void 0),Fn([I(!1)],t.prototype,"disableConnectors",void 0),Fn([re({},Ed)],t.prototype,"tooltip",void 0),Fn([I("")],t.prototype,"template",void 0),t}(Ee);function nF(n){return Zne[n.toString()]}var Zne={Action:"M 90 82.895 C 90 86.819 86.776 90 82.8 90 H 7.2 C 3.224 90 0 86.819 0 82.895 V 7.105 C 0 3.181 3.224 0 7.2 0 h 75.6 C 86.776 0 90 3.181 90 7.105 V 82.895 Z",Decision:"M10,19.707L0.293,10L10,0.293L19.707,10L10,19.707z",MergeNode:"M10,19.707L0.293,10L10,0.293L19.707,10L10,19.707z",InitialNode:"M10,19.5c-5.238,0-9.5-4.262-9.5-9.5S4.762,0.5,10,0.5s9.5,4.262,9.5,9.5S15.238,19.5,10,19.5z",ForkNode:"m0.75,0.75l636.00002,0l0,290l-636.00002,0l0,-290z",JoinNode:"m0.75,0.75l636.00002,0l0,290l-636.00002,0l0,-290z",TimeEvent:"M50.001,0.00286865 L25.001,25.0029 L0.000976562,0.00286865 L50.001,0.00286865 z M0.000976562,50.0029 L25.001,25.0029 L50.001,50.0029 L0.000976562,50.0029 z",AcceptingEvent:"M17.8336 32.164 L29.64 24 L17.32 16 L48.1664 16 L48.5 32 Z",SendSignal:"M48.164 31.8336 L56 23.832 L47.836 16 L16.168 16 L16.1668 31.8336 Z",ReceiveSignal:"M48.1664 31.8336 L39.836 24 L47.836 16 L16.168 16 L16.168 31.836 Z",StructuredNode:"M0,0 L50,0 L50,50 L0,50 z",Note:"M20 12 L4 12 L4 22 L22 22 L22 14 L20 14 L20 12 L22 14 Z"},qI=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),$a=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Jne=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return qI(t,n),$a([I()],t.prototype,"key",void 0),$a([I()],t.prototype,"keyModifiers",void 0),t}(Ee),sF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return qI(t,n),t.prototype.getClassName=function(){return"Command"},$a([I("")],t.prototype,"name",void 0),$a([I()],t.prototype,"canExecute",void 0),$a([I()],t.prototype,"execute",void 0),$a([re({},Jne)],t.prototype,"gesture",void 0),$a([I("")],t.prototype,"parameter",void 0),t}(Ee),Kne=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return qI(t,n),$a([Bt([],sF)],t.prototype,"commands",void 0),t}(Ee),ese=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return qI(t,n),$a([I()],t.prototype,"show",void 0),$a([I()],t.prototype,"showCustomMenuOnly",void 0),$a([I()],t.prototype,"items",void 0),t}(Ee),qp=function(){function n(){}return n.prototype.renderShadow=function(t,e,i,r){void 0===i&&(i=null);var l,o=z.transform({x:0,y:0},t.shadow.angle,t.shadow.distance);r&&(l=r.getElementById(e.id+"_shadow")),l||(l=document.createElementNS("http://www.w3.org/2000/svg",i?"path":"rect"),e.appendChild(l));var h={id:e.id+"_shadow",fill:t.shadow.color,stroke:t.shadow.color,opacity:t.shadow.opacity.toString(),transform:"rotate("+t.angle+","+(t.x+t.width*t.pivotX)+","+(t.y+t.height*t.pivotY)+")translate("+(t.x+o.x)+","+(t.y+o.y)+")"};if(r){var c=r.getElementById(e.id);c&&c.insertBefore(l,c.firstChild)}ai(l,h),i?i&&this.renderPath(l,t,i):ai(l,{width:t.width,height:t.height})},n.prototype.parseDashArray=function(t){return[]},n.prototype.drawRectangle=function(t,e,i,r,s,o,a,l,h){var c,d,u,p;e.shadow&&!r&&this.renderShadow(e,t,void 0,o),c=e.id===t.id?e.id+"_container":e.id,o&&(d=o.getElementById(c)),(!d||s)&&(d=document.createElementNS("http://www.w3.org/2000/svg","rect"),t.appendChild(d)),o&&!e.shadow&&(u=o.getElementById(e.id+"_groupElement_shadow"))&&u.parentNode.removeChild(u),p=l?{id:c,x:e.x.toString(),y:e.y.toString(),width:e.width.toString(),height:e.height.toString(),visibility:e.visible?"visible":"hidden",transform:"rotate("+e.angle+","+(e.x+e.width/2)+","+(e.y+e.height/2)+")",rx:e.cornerRadius||0,ry:e.cornerRadius||0,opacity:e.opacity}:{id:c,x:e.x.toString(),y:e.y.toString(),width:e.width.toString(),height:e.height.toString(),visibility:e.visible?"visible":"hidden",transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")",rx:e.cornerRadius||0,ry:e.cornerRadius||0,opacity:e.opacity},a&&(p.role="img",p["aria-label"]=a);var f=e.class||"";h||(f.includes("e-diagram-resize-handle")||f.includes("e-diagram-endpoint-handle")||f.includes("e-diagram-bezier-control-handle"))&&(f+=" e-disabled"),e.class&&(p.class=f),a||(p["pointer-events"]="none"),ai(d,p),this.setSvgStyle(d,e,i)},n.prototype.updateSelectionRegion=function(t,e){var i;i=t.parentNode.getElementById(e.id);var r={id:e.id,x:e.x.toString(),y:e.y.toString(),width:e.width.toString(),height:e.height.toString(),transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")",class:"e-diagram-selected-region"};i||(i=document.createElementNS("http://www.w3.org/2000/svg","rect"),t.appendChild(i)),this.setSvgStyle(i,e),ai(i,r)},n.prototype.createGElement=function(t,e){return Bi(t,e)},n.prototype.drawLine=function(t,e){var i=document.createElementNS("http://www.w3.org/2000/svg","line");this.setSvgStyle(i,e);var r=e.x+e.width*e.pivotX,s=e.y+e.height*e.pivotY,o={id:e.id,x1:e.startPoint.x+e.x,y1:e.startPoint.y+e.y,x2:e.endPoint.x+e.x,y2:e.endPoint.y+e.y,stroke:e.stroke,"stroke-width":e.strokeWidth.toString(),opacity:e.opacity.toString(),transform:"rotate("+e.angle+" "+r+" "+s+")",visibility:e.visible?"visible":"hidden"};e.class&&(o.class=e.class),ai(i,o),t.appendChild(i)},n.prototype.drawCircle=function(t,e,i,r){var s=document.createElementNS("http://www.w3.org/2000/svg","circle");this.setSvgStyle(s,e);var o=e.class||"";i||(o+=" e-disabled");var a={id:e.id,cx:e.centerX,cy:e.centerY,r:e.radius,visibility:e.visible?"visible":"hidden",class:o};r&&(a.role="img",a["aria-label"]=r),s.style.display=e.visible?"block":"none",ai(s,a),t.appendChild(s)},n.prototype.drawPath=function(t,e,i,r,s,o,a){var h,c,l=[];l=XB(l=Cd(e.data)),e.shadow&&this.renderShadow(e,t,l,s),s&&!e.shadow&&(h=s.getElementById(e.id+"_groupElement_shadow"))&&h.parentNode.removeChild(h),s&&(c=s.getElementById(e.id)),(!c||r)&&(c=document.createElementNS("http://www.w3.org/2000/svg","path"),t.appendChild(c)),this.renderPath(c,e,l);var d={};d=a?{id:e.id,transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")translate("+e.x+","+e.y+"),scale("+a+")",visibility:e.visible?"visible":"hidden",opacity:e.opacity}:{id:e.id,transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")translate("+e.x+","+e.y+")",visibility:e.visible?"visible":"hidden",opacity:e.opacity},o&&(d.role="img",d["aria-label"]=o),e.class&&(d.class=e.class),ai(c,d),this.setSvgStyle(c,e,i)},n.prototype.renderPath=function(t,e,i){var r,s,o,a,l,h,c,d,u=i,p="";for(l=0,h=0,d=0,c=u.length;de.width&&"Wrap"!==e.textOverflow&&"NoWrap"===e.textWrapping&&(h[0].text=VF(e.content,e)),v=0;vD&&(u.text=u.text.slice(0,u.text.length-3),u.text=u.text.concat("..."),l.data=u.text),this.alignText(y,p,u,l,f,g,v,e,h),C+=u.dy}}C&&e.isHorizontalLane&&(M=e.parentOffsetX+e.pivotX,w=e.parentOffsetY+e.pivotY,e.y=e.parentOffsetY-C*e.pivotY+.5),e.textDecoration&&"LineThrough"===e.textDecoration&&(e.textDecoration=hb(e.textDecoration));var R={id:e.id+"_text",fill:e.color,visibility:e.visible?"visible":"hidden","text-decoration":e.textDecoration,transform:"rotate("+e.angle+","+M+","+w+")translate("+e.x+","+e.y+")",opacity:e.opacity};r&&(R.role="img",R["aria-label"]=r),ai(y,R)}},n.prototype.alignText=function(t,e,i,r,s,o,a,l,h){"justify"!==l.textAlign?this.setText(t,e,i,r,s,o,l):a!==h.length-1?this.setText(t,e,i,r,s,o,l,l.width,"spacing"):this.setText(t,e,i,r,s,o,l)},n.prototype.setText=function(t,e,i,r,s,o,a,l,h){ai(e,"justify"!==a.textAlign?{x:s.toString(),y:o.toString()}:{x:s.toString(),y:o.toString(),textLength:l||0,lengthAdjust:h||"spacing"}),t.setAttribute("fill",i.text),e.appendChild(r),t.appendChild(e)},n.prototype.drawImage=function(t,e,i,r){var s;i&&(s=i.getElementById(e.id+"image")),s||(s=document.createElementNS("http://www.w3.org/2000/svg","image"),t.appendChild(s));var o=new Image;o.src=e.source;var a="None"!==e.scale?e.scale:"",l=e.alignment,h=l.charAt(0).toLowerCase()+l.slice(1);"Stretch"!==a&&(h+=" "+a.charAt(0).toLowerCase()+a.slice(1)),ai(s,{id:e.id+"image",x:e.x.toString(),y:e.y.toString(),transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")",width:e.width.toString(),visibility:e.visible?"visible":"hidden",height:e.height.toString(),preserveAspectRatio:h,opacity:e.opacity.toString()}),s.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",o.src.toString())},n.prototype.drawHTMLContent=function(t,e,i,r,s){var o,a;if(e&&(o=e.querySelector("#"+t.id+"_html_element")),!o){(a=e.querySelector("#"+t.id+"_html_element")||e.querySelector("#"+t.nodeId+"_html_element"))||(a=Tt("div",{id:t.nodeId+"_html_element",class:"foreign-object"})),o=Tt("div",{id:t.id+"_html_element",class:"foreign-object"});var c=document.getElementById(t.diagramId).ej2_instances[0],d=!1;if(e.parentNode&&e.parentNode.parentNode&&e.parentNode.parentNode.parentNode&&e.parentNode.parentNode.parentNode.classList.contains("e-overview")&&(d=!0),d)c.isReact?c.renderReactTemplates(function(){o.appendChild(t.template.cloneNode(!0))}):o.appendChild(t.template.cloneNode(!0));else{if("string"==typeof t.template){var u=document.createElement("div");u.innerHTML=t.template,t.template=u,c.selectedItems.userHandles.filter(function(g){return g.name===t.id.split("_shape")[0]&&""!==g.template})[0].template=t.template}t.isTemplate&&t.template?o.appendChild(t.template):t.template&&o.appendChild(t.template.cloneNode(!0))}void 0!==s&&e.childNodes.length>s&&e.insertBefore(o,e.childNodes[parseInt(s.toString(),10)]),a.appendChild(o),e.appendChild(a)}var f=En(t).topLeft;o.setAttribute("style","height:"+t.actualSize.height+"px; width:"+t.actualSize.width+"px;left:"+f.x+"px; top:"+f.y+"px;position:absolute;transform:rotate("+(t.rotateAngle+t.parentTransform)+"deg);pointer-events:"+(r?"all":"none")+";visibility:"+(t.visible?"visible":"hidden")+";opacity:"+t.style.opacity+";")},n.prototype.drawNativeContent=function(t,e,i,r,s){var o,a;if(s&&(o=s.getElementById(t.id+"_native_element"),a=s.getElementById(t.id+"_clip")),!o){(o=document.createElementNS("http://www.w3.org/2000/svg","g")).setAttribute("id",t.id+"_native_element"),o.appendChild(t.template.cloneNode(!0));var l=this.createGElement("g",{id:t.id+"_inner_native_element"});l.appendChild(o),e.appendChild(l)}a&&o.removeChild(a),o.setAttribute("style","visibility:"+(t.visible?"visible":"hidden")+";opacity:"+t.style.opacity+";"),this.setNativTransform(t,o,i,r),"Slice"===t.scale&&this.drawClipPath(t,o,i,r,s),ai(o,t.description?{role:"img","aria-label":t.description}:{})},n.prototype.setNativTransform=function(t,e,i,r){var s=0!==t.contentSize.width?t.contentSize.width:1,o=0!==t.contentSize.height?t.contentSize.height:1;e.setAttribute("transform","rotate("+t.parentTransform+","+t.offsetX+","+t.offsetY+") translate("+(t.offsetX-t.templatePosition.x*r/s-r*t.pivot.x)+","+(t.offsetY-t.templatePosition.y*i/o-i*t.pivot.y)+") scale("+r/s+","+i/o+")")},n.prototype.drawClipPath=function(t,e,i,r,s){var o=t.contentSize.width,a=t.contentSize.height,l=t.width/(r/o),h=t.height/(i/a),c=t.templatePosition.x+(t.width>=t.height?0:(o-l)/2),d=t.templatePosition.y+(t.height>=t.width?0:(a-h)/2),u=s.getElementById(t.id+"_clip");(u=document.createElementNS("http://www.w3.org/2000/svg","clipPath")).setAttribute("id",t.id+"_clip"),e.appendChild(u);var p=s.getElementById(t.id+"_clip_rect");return p=document.createElementNS("http://www.w3.org/2000/svg","rect"),u.appendChild(p),ai(p,{id:t.id+"_clip_rect",width:l.toString(),height:h.toString(),x:c.toString(),y:d.toString()}),nm()?e.setAttribute("clip-path","url("+location.protocol+"//"+location.host+location.pathname+"#"+t.id+"_clip)"):e.setAttribute("clip-path","url(#"+t.id+"_clip)"),e},n.prototype.renderGradient=function(t,e,i){var r,s,o,h,c,a=mT(i),l=a.getElementById(i+"gradient_pattern");if(l||(l=Bi("defs",{id:i+"gradient_pattern"}),a.insertBefore(l,a.firstChild)),gF(e.id),"None"!==t.gradient.type){for(var d=0;dt.width&&("Ellipsis"===t.textOverflow||"Clip"===t.textOverflow)&&"NoWrap"===t.textWrapping?0:.5*t.width:"right"===t.textAlign&&(c=1*t.width),s.x=0+c+(e?e.x:0),s.y=1.2+d-r.height/2,s},n}(),Pc=function(){function n(t,e,i){this.renderer=null,this.isSvgMode=!0,this.transform={x:0,y:0},this.diagramId=t,this.element=xt(this.diagramId),this.svgRenderer=e,this.isSvgMode=i,this.renderer=i?new qp:new bo}return n.prototype.setCursor=function(t,e){t.style.cursor=e},n.prototype.setLayers=function(){this.iconSvgLayer=this.element.getElementsByClassName("e-ports-expand-layer")[0],this.adornerSvgLayer=this.element.getElementsByClassName("e-adorner-layer")[0],this.nativeSvgLayer=this.element.getElementsByClassName("e-native-layer")[0],this.diagramSvgLayer=this.element.getElementsByClassName("e-diagram-layer")[0]},n.prototype.getAdornerLayer=function(){return gT(this.diagramId)},n.prototype.getParentSvg=function(t,e,i){return this.diagramId&&t&&t.id?t.id.split("_icon_content").length>1||t.id.split("_nodeport").length>1||t.elementActions&Xr.ElementIsPort?this.iconSvgLayer:e&&"selector"===e?this.adornerSvgLayer:t instanceof Cn?this.nativeSvgLayer:this.diagramSvgLayer:i},n.prototype.getParentElement=function(t,e,i,r){var s=e;if(i&&this.diagramId&&t&&t.id){t.id.split("_icon_content").length>1?(s=i.getElementById(this.diagramId+"_diagramExpander"),e=null):t.id.split("_nodeport").length>1?s=i.getElementById(this.diagramId+"_diagramPorts"):t instanceof Cn?(s=i.getElementById(this.diagramId+"_nativeLayer"),e=null):t.elementActions&Xr.ElementIsPort?(s=i.getElementById(this.diagramId+"_diagramPorts"),e=null):s=i.getElementById(this.diagramId+"_diagramLayer");var o=this.getGroupElement(t,e||s,r);s=o.g,o.svg&&(i=o.svg)}return{g:s,svg:i}},n.prototype.getGroupElement=function(t,e,i){var r,o,s=this.getParentSvg(t);if(e&&s){if(s&&!(r=s.getElementById(t.id+"_groupElement"))&&s!==this.nativeSvgLayer){var a=this.nativeSvgLayer;r=a.getElementById(t.id+"_groupElement"),o=a}r||(r=this.svgRenderer.createGElement("g",{id:t.id+"_groupElement"}),void 0!==i&&e.childNodes.length>i?e.insertBefore(r,e.childNodes[parseInt(i.toString(),10)]):e.appendChild(r))}return{g:r,svg:o}},n.prototype.renderElement=function(t,e,i,r,s,o,a,l,h,c,d){t instanceof Cs?(t.id=t.id?t.id:Qe(),this.renderContainer(t,e,i,r,s,o,a,l,h,c,d)):t instanceof SI?this.renderImageElement(t,e,r,s,a):t instanceof Ke?this.renderPathElement(t,e,r,s,a,h,d):t instanceof si?this.renderTextElement(t,e,r,s,a,c):t instanceof Cn?this.renderNativeElement(t,e,r,s,a):t instanceof Jn?this.renderHTMLElement(t,e,i,r,s,a,l):this.renderRect(t,e,r,s,h)},n.prototype.drawSelectionRectangle=function(t,e,i,r,s,o){var a={width:i*o.scale,height:r*o.scale,x:.5+(t=(t+o.tx)*o.scale),y:.5+(e=(e+o.ty)*o.scale),fill:"transparent",stroke:"gray",angle:0,pivotX:.5,pivotY:.5,strokeWidth:1,dashArray:"6 3",opacity:1,visible:!0,id:s.id+"_selected_region"},l=this.getAdornerLayer();this.svgRenderer.updateSelectionRegion(l,a)},n.prototype.renderHighlighter=function(t,e,i){var r=t.actualSize.width||2,s=t.actualSize.height||2,o=t.offsetX-r*t.pivot.x,a=t.offsetY-s*t.pivot.y;this.svgRenderer.drawRectangle(e,{width:r*i.scale,height:s*i.scale,x:o=(o+i.tx)*i.scale,y:a=(a+i.ty)*i.scale,fill:"transparent",stroke:"#8CC63F",angle:t.rotateAngle,pivotX:t.pivot.x,pivotY:t.pivot.y,strokeWidth:4,dashArray:"",opacity:1,cornerRadius:0,visible:!0,id:e.id+"_highlighter",class:"e-diagram-highlighter"},this.diagramId,void 0,void 0,e)},n.prototype.renderSelectionRectangle=function(t,e,i,r){var s=t.actualSize.width||2,o=t.actualSize.height||2,a=t.offsetX-s*t.pivot.x,l=t.offsetY-o*t.pivot.y,h={width:s*i.scale,height:o*i.scale,x:a=(a+i.tx)*i.scale,y:l=(l+i.ty)*i.scale,fill:"transparent",stroke:"#00cc00",angle:t.rotateAngle,pivotX:t.pivot.x,pivotY:t.pivot.y,strokeWidth:r?2:1,dashArray:"",opacity:1,cornerRadius:0,visible:!0,id:t.id+"_highlighter",class:r?"e-diagram-first-selection-indicator e-diagram-selection-indicator":"e-diagram-selection-indicator"},c=this.getParentSvg(t,"selector");this.svgRenderer.drawRectangle(e,h,this.diagramId,void 0,void 0,c)},n.prototype.renderSelectionLine=function(t,e,i,r){var s=this.getBaseAttributes(t,i);s.data=t.absolutePath,s.id=s.id+"_highlighter";var o=t.description?t.description:t.id;this.isSvgMode||(s.x=t.flipOffset.x?t.flipOffset.x:s.x,s.y=t.flipOffset.y?t.flipOffset.y:s.y),i&&(s.x=s.x*i.scale,s.y=s.y*i.scale),s.stroke="#00cc00",s.strokeWidth=r?2:1,s.class=r?"e-diagram-first-selection-indicator e-diagram-selection-indicator":"e-diagram-selection-indicator";var a=this.getParentSvg(t,"selector");this.svgRenderer.drawPath(e,s,this.diagramId,void 0,a,o,i.scale)},n.prototype.renderStackHighlighter=function(t,e,i,r,s,o,a){var l=t.actualSize.width||2,h=t.offsetX-l*t.pivot.x,c=t.actualSize.height||2,d=t.offsetY-c*t.pivot.y;h=(h+i.tx)*i.scale;var u,p=t.bounds,f="";if(d=(d+i.ty)*i.scale,r)if(o){var v,y;u="M 0 0 L "+(2+(g=l*i.scale))+" 0 Z",v=t.actualSize.width/Number(p.width?p.width:1)*i.scale,y=t.actualSize.height/Number(p.height?p.height:1)*i.scale,f=fI(gI(Cd("M7,4 L8,4 8,7 11,7 11,8 8,8 8,11 7,11 7,8 4,8 4,7 7,7 z M7.5,0.99999994C3.9160004,1 1,3.9160004 0.99999994,7.5 1,11.084 3.9160004,14 7.5,14 11.084,14 14,11.084 14,7.5 14,3.9160004 11.084,1 7.5,0.99999994 z M7.5,0 C11.636002,0 15,3.3639984 15,7.5 15,11.636002 11.636002,15 7.5,15 3.3640003,15 0,11.636002 0,7.5 0,3.3639984 3.3640003,0 7.5,0 z")),v+g+2,y-8,!1,p.x,p.y,0,0),s.y>=t.offsetY&&(d+=c)}else{var g;a&&s.y>=t.offsetY&&(d+=c*i.scale),u="M -10 -10 L 0 0 Z M -10 10 L 0 0 Z M 0 0 L "+(g=l*i.scale)+" 0 Z M "+g+" 0 L "+(g+10)+" 10 Z L "+(g+10)+" -10 Z"}else u="M 10 -10 L 0 0 Z M -10 -10 L 0 0 Z M 0 0 L 0 "+(g=c*i.scale)+" Z M 0 "+g+" L -10 "+(g+10)+" Z L 10 "+(g+10)+" Z",s.x>=t.offsetX&&(h+=l*i.scale);this.svgRenderer.drawPath(e,{data:u+f,width:l*i.scale,height:c*i.scale,x:h,y:d,fill:"transparent",stroke:"#8CC63F",angle:t.rotateAngle,pivotX:t.pivot.x,pivotY:t.pivot.y,strokeWidth:1,dashArray:"",opacity:1,visible:!0,id:e.id+"_stack_highlighter",class:"e-diagram-highlighter"},this.diagramId)},n.prototype.drawLine=function(t,e){this.svgRenderer.drawLine(t,e)},n.prototype.drawPath=function(t,e){this.svgRenderer.drawPath(t,e,this.diagramId)},n.prototype.renderResizeHandle=function(t,e,i,r,s,o,a,l,h,c,d){var u=t.offsetX-t.actualSize.width*t.pivot.x,p=t.offsetY-t.actualSize.height*t.pivot.y,f=t.actualSize.height,g=t.actualSize.width;!c&&i&bt.Rotate&&zI(this.rendererActions)&&!A3(this.rendererActions)&&(this.renderPivotLine(t,e,o,s,a),this.renderRotateThumb(t,e,o,s,a)),this.renderBorder(t,e,o,l,h,c);var v=t.actualSize.width*r,y=t.actualSize.height*r;!h&&zI(this.rendererActions)&&!A3(this.rendererActions)&&(t.isTextAnnotation||(v>=40&&y>=40&&(s&mr.ResizeNorthWest&&this.renderCircularHandle("resizeNorthWest",t,u,p,e,qr(s,"ResizeNorthWest"),i&bt.ResizeNorthWest,o,void 0,a,{"aria-label":"Thumb to resize the selected object on top left side direction"},void 0,"e-diagram-resize-handle e-northwest",d),s&mr.ResizeNorthEast&&this.renderCircularHandle("resizeNorthEast",t,u+g,p,e,qr(s,"ResizeNorthEast"),i&bt.ResizeNorthEast,o,void 0,a,{"aria-label":"Thumb to resize the selected object on top right side direction"},void 0,"e-diagram-resize-handle e-northeast",d),s&mr.ResizeSouthWest&&this.renderCircularHandle("resizeSouthWest",t,u,p+f,e,qr(s,"ResizeSouthWest"),i&bt.ResizeSouthWest,o,void 0,a,{"aria-label":"Thumb to resize the selected object on bottom left side direction"},void 0,"e-diagram-resize-handle e-southwest",d),s&mr.ResizeSouthEast&&this.renderCircularHandle("resizeSouthEast",t,u+g,p+f,e,qr(s,"ResizeSouthEast"),i&bt.ResizeSouthEast,o,void 0,a,{"aria-label":"Thumb to resize the selected object on bottom right side direction"},void 0,"e-diagram-resize-handle e-southeast",d)),s&mr.ResizeNorth&&this.renderCircularHandle("resizeNorth",t,u+g/2,p,e,qr(s,"ResizeNorth"),i&bt.ResizeNorth,o,void 0,a,{"aria-label":"Thumb to resize the selected object on top side direction"},void 0,"e-diagram-resize-handle e-north",d),s&mr.ResizeSouth&&this.renderCircularHandle("resizeSouth",t,u+g/2,p+f,e,qr(s,"ResizeSouth"),i&bt.ResizeSouth,o,void 0,a,{"aria-label":"Thumb to resize the selected object on bottom side direction"},void 0,"e-diagram-resize-handle e-south",d),s&mr.ResizeWest&&this.renderCircularHandle("resizeWest",t,u,p+f/2,e,qr(s,"ResizeWest"),i&bt.ResizeWest,o,void 0,a,{"aria-label":"Thumb to resize the selected object on left side direction"},void 0,"e-diagram-resize-handle e-west",d),s&mr.ResizeEast&&this.renderCircularHandle("resizeEast",t,u+g,p+f/2,e,qr(s,"ResizeEast"),i&bt.ResizeEast,o,void 0,a,{"aria-label":"Thumb to resize the selected object on right side direction"},void 0,"e-diagram-resize-handle e-east",d)))},n.prototype.renderEndPointHandle=function(t,e,i,r,s,o,a,l,h,c){var f,g,d=t.sourcePoint,u=t.targetPoint,p=t.wrapper;if(this.renderCircularHandle("connectorSourceThumb",p,d.x,d.y,e,qr(r,"ConnectorSourceThumb"),i&bt.ConnectorSource,s,o,void 0,{"aria-label":"Thumb to move the source point of the connector"},void 0,"e-diagram-endpoint-handle e-sourceend",c),this.renderCircularHandle("connectorTargetThumb",p,u.x,u.y,e,qr(r,"ConnectorTargetThumb"),i&bt.ConnectorTarget,s,a,void 0,{"aria-label":"Thumb to move the target point of the connector"},void 0,"e-diagram-endpoint-handle e-targetend",c),l)if("Straight"===t.type&&t.segments.length>0)for(f=0;f0)for(f=0;f=3&&3===t.segments.length&&(S=1,b=t.segments.length-1),S=t.segments.length>t.maxSegmentThumb+2?2:S,b=t.segments.length>t.maxSegmentThumb+2?t.segments.length-2:b,1===t.segments.length&&t.segments[0].points.length<=2&&(S=1,b=t.segments.length),f=S;f=50&&i.allowDrag),this.renderOrthogonalThumb(t+"_"+(d+1),e,(i.points[parseInt(d.toString(),10)].x+i.points[d+1].x)/2,(i.points[parseInt(d.toString(),10)].y+i.points[d+1].y)/2,r,h,l,o,a,u)}else for(d=0;d=50&&i.allowDrag),this.renderOrthogonalThumb(t+"_"+(d+1),e,(i.points[parseInt(d.toString(),10)].x+i.points[d+1].x)/2,(i.points[parseInt(d.toString(),10)].y+i.points[d+1].y)/2,r,h,l,o,a,u)},n.prototype.renderOrthogonalThumb=function(t,e,i,r,s,o,a,l,h,c){var d,g,u=0,p=document.getElementById(this.diagramId);p&&(g=p.ej2_instances[0]);var y=h.constraints&qe.InheritSegmentThumbShape?g.segmentThumbShape:h.segmentThumbShape,b=h.constraints&qe.InheritSegmentThumbSize?g.segmentThumbSize:h.segmentThumbSize;if(d="horizontal"===a?function tre(n){return sre[""+n]}(y):n3(y),"Arrow"===y||"DoubleArrow"===y||"OpenArrow"===y)switch(c){case"Bottom":case"Right":u=180;break;default:u=0}else if("Fletch"===y||"OpenFetch"===y||"IndentedArrow"===y||"OutdentedArrow"===y)switch(c){case"Bottom":u=-90;break;case"Top":u=90;break;case"Right":u=180;break;default:u=0}var M={x:(i+l.tx)*l.scale-b/2,y:(r+l.ty)*l.scale-b/2,angle:u,fill:"#e2e2e2",stroke:"black",strokeWidth:1,dashArray:"",data:d,width:b,height:b,pivotX:.5,pivotY:.5,opacity:1,visible:o,id:t,class:"e-diagram-ortho-segment-handle"},w=nf(M.data),C=new me(M.width,M.height),D=new Ke;M.data=D.updatePath(M.data,w,C),this.svgRenderer.drawPath(s,M,this.diagramId)},n.prototype.renderPivotLine=function(t,e,i,r,s){var o=t,l=!!(r&mr.Rotate);s&&(l=!1);var h=this.getBaseAttributes(o,i);h.fill="None",h.stroke="black",h.strokeWidth=1,h.dashArray="2,3",h.visible=l;var c=i.scale;h.x*=c,h.y*=c,h.width*=c,h.height*=c,h.id="pivotLine",h.class="e-diagram-pivot-line";var u={x:o.actualSize.width*o.pivot.x*c,y:0};h.startPoint={x:o.actualSize.width*o.pivot.x*c,y:-20},h.endPoint=u,this.svgRenderer.drawLine(e,h)},n.prototype.renderBezierLine=function(t,e,i,r,s,o){var l=this.getBaseAttributes(e,o);l.id=t,l.stroke="black",l.strokeWidth=1,l.dashArray="3,3",l.fill="None",l.class="e-diagram-bezier-control-line",l.x=0,l.y=0;var h=o.scale,g={x:(s.x+o.tx)*h,y:(s.y+o.ty)*h};l.startPoint={x:(r.x+o.tx)*h,y:(r.y+o.ty)*h},l.endPoint=g,this.svgRenderer.drawLine(i,l)},n.prototype.renderCircularHandle=function(t,e,i,r,s,o,a,l,h,c,d,u,p,f){var g=e,v={x:i,y:r};if(0!==g.rotateAngle||0!==g.parentTransform){var y=Hi();qi(y,g.rotateAngle+g.parentTransform,g.offsetX,g.offsetY),v=Je(y,v)}var S=this.getBaseAttributes(g);S.stroke="black",S.strokeWidth=1,void 0!==u?(S.id="segmentEnd_"+u,S.fill="#e2e2e2"):S.fill=h?"#8CC63F":"white",S.cornerRadius=f/2,S.angle=e.rotateAngle,S.id=t,S.visible=o,S.class=p,S.width=f,S.height=f,S.x=(v.x+l.tx)*l.scale,S.y=(v.y+l.ty)*l.scale,S.x=S.x-S.width/2,S.y=S.y-S.height/2,h&&(S.class+=" e-connected"),c&&(S.visible=!1);var b=this.getParentSvg(e,"selector");this.svgRenderer.drawRectangle(s,S,this.diagramId,!0,!0,b,d,!0,a)},n.prototype.renderBezierHandle=function(t,e,i,r,s,o,a,l,h,c,d,u,p){var v,f=document.getElementById(this.diagramId);f&&(v=f.ej2_instances[0]);var y=e,S={x:i,y:r};if(0!==y.rotateAngle||0!==y.parentTransform){var b=Hi();qi(b,y.rotateAngle+y.parentTransform,y.offsetX,y.offsetY),S=Je(b,S)}var D=a.constraints&qe.InheritSegmentThumbSize?v.segmentThumbSize:a.segmentThumbSize,A=n3(a.constraints&qe.InheritSegmentThumbShape?v.segmentThumbShape:a.segmentThumbShape),x=this.getBaseAttributes(y);x.stroke="black",x.strokeWidth=1,void 0!==d?(x.id="segmentEnd_"+d,x.fill="#e2e2e2"):x.fill=h?"#8CC63F":"white",x.angle=e.rotateAngle,x.id=t,x.visible=o,x.class=u,x.width=D,x.height=D,x.data=A,x.x=(S.x+l.tx)*l.scale,x.y=(S.y+l.ty)*l.scale,x.x=x.x-x.width/2,x.y=x.y-x.height/2,h&&(x.class+=" e-connected"),c&&(x.visible=!1);var R=nf(x.data),L=new me(x.width,x.height),O=new Ke;x.data=O.updatePath(x.data,R,L);var N=this.getParentSvg(e,"selector");this.svgRenderer.drawPath(s,x,this.diagramId,!0,N)},n.prototype.renderBorder=function(t,e,i,r,s,o){var l=this.getBaseAttributes(t,i);l.x*=i.scale,l.y*=i.scale,l.width*=i.scale,l.height*=i.scale,l.fill="transparent",l.stroke="#097F7F",l.strokeWidth=1.2,l.gradient=null,l.dashArray="6,3",l.class="e-diagram-selector",o&&(l.class+=" e-diagram-lane"),l.id="borderRect",l.id=this.rendererActions&Qa.DrawSelectorBorder?"borderRect_symbol":"borderRect",r||(l.class+=" e-disabled"),s&&(l.class+=" e-thick-border"),l.cornerRadius=0;var h=this.getParentSvg(t,"selector");this.svgRenderer.drawRectangle(e,l,this.diagramId,void 0,!0,h)},n.prototype.renderUserHandler=function(t,e,i,r,s,o){for(var l,a=t.wrapper,h=0,c=t.userHandles;h0||d.disableNodes&&t.nodes.length>0||"Drag"===s&&o)&&(l=!1);var u=document.getElementById(d.name+"_template_hiddenUserHandle");u&&(d.template=u.childNodes[0].cloneNode(!0));var p=Kx(t,d,i);if(p.x=(p.x+i.tx)*i.scale,p.y=(p.y+i.ty)*i.scale,d.visible&&(d.visible=!!(t.constraints&mr.UserHandle)),l)if(d.pathData){var f=d.pathData?d.pathData:d.content,g=this.getBaseAttributes(a);g.id=d.name+"_userhandle",g.fill=d.backgroundColor,g.stroke=d.borderColor,g.strokeWidth=d.borderWidth,g.centerX=p.x,g.centerY=p.y,g.radius=.5*d.size,g.class="e-diagram-userhandle-circle",g.angle=0,g.visible=d.visible,g.opacity=1,this.svgRenderer.drawCircle(e,g,1,{"aria-label":d.name+"user handle"});var y=[];y=gI(y=Cd(f));var S=nf(f),w=fI(y,(d.size-.45*d.size)/S.width,(d.size-.45*d.size)/S.height,!0,S.x,S.y,0,0);S=nf(w),this.svgRenderer.drawPath(e,C={x:p.x-S.width/2,y:p.y-S.height/2,angle:0,id:"",class:"e-diagram-userhandle-path",fill:d.pathColor,stroke:d.backgroundColor,strokeWidth:.5,dashArray:"",data:w,width:d.size-5,height:d.size-5,pivotX:0,pivotY:0,opacity:1,visible:d.visible},this.diagramId,void 0,void 0,{"aria-label":d.name+"user handle"})}else if(d.content){var D=new Cn(d.name,this.diagramId);D.content=d.content,D.offsetX=p.x,D.offsetY=p.y,D.id=d.name+"_shape",D.horizontalAlignment="Center",D.verticalAlignment="Center",D.visible=d.visible,D.setOffsetWithRespectToBounds(p.x,p.y,"Fraction"),D.relativeMode="Object",D.description=d.name||"User handle",D.measure(new me(d.size,d.size)),D.arrange(D.desiredSize),this.svgRenderer.drawNativeContent(D,e,d.size,d.size,this.adornerSvgLayer)}else if(d.source){var C,A=new SI;(C=this.getBaseAttributes(A,i)).width=d.size,C.height=d.size,C.x=p.x-d.size/2,C.y=p.y-d.size/2,C.sourceWidth=d.size,C.sourceHeight=d.size,C.alignment=A.imageAlign,C.source=d.source,C.scale=A.imageScale,C.visible=d.visible,C.description=d.name||"User handle",C.id=d.name+"_",this.renderer.drawImage(e,C,this.adornerSvgLayer,!1)}else{var x=new Jn(d.name,this.diagramId);x.offsetX=p.x,x.offsetY=p.y,x.id=d.name+"_shape",x.visible=d.visible,x.relativeMode="Object",x.template=d.template,x.measure(new me(d.size,d.size)),x.arrange(x.desiredSize),this.svgRenderer.drawHTMLContent(x,r,void 0,!0,void 0)}}},n.prototype.renderRotateThumb=function(t,e,i,r,s){new Ke;var a,l=new me;l.width=18,l.height=16;var d=!!(r&mr.Rotate);s&&(d=!1);var p=t.offsetX-t.actualSize.width*t.pivot.x+t.pivot.x*t.actualSize.width,f=t.offsetY-t.actualSize.height*t.pivot.y;if(a={x:(p=(p+i.tx)*i.scale)-.5*l.width,y:(f=(f+i.ty)*i.scale)-30-.5*l.height},0!==t.rotateAngle||0!==t.parentTransform){var g=Hi();qi(g,t.rotateAngle+t.parentTransform,(i.tx+t.offsetX)*i.scale,(i.ty+t.offsetY)*i.scale),a=Je(g,a)}this.svgRenderer.drawPath(e,{x:a.x,y:a.y,angle:t.rotateAngle+t.parentTransform,fill:"#231f20",stroke:"black",strokeWidth:.5,dashArray:"",data:"M 16.856144362449648 10.238890446662904 L 18.000144362449646 3.437890446662903L 15.811144362449646 4.254890446662903 C 14.837144362449646 2.5608904466629028 13.329144362449647 1.2598904466629026 11.485144362449645 0.5588904466629026 C 9.375144362449646 - 0.24510955333709716 7.071144362449646 - 0.18010955333709716 5.010144362449646 0.7438904466629028 C 2.942144362449646 1.6678904466629028 1.365144362449646 3.341890446662903 0.558144362449646 5.452890446662903 C - 0.244855637550354 7.567890446662903 - 0.17985563755035394 9.866890446662904 0.7431443624496461 11.930890446662904 C 1.6681443624496461 13.994890446662904 3.343144362449646 15.575890446662903 5.457144362449647 16.380890446662903 C 6.426144362449647 16.7518904466629 7.450144362449647 16.9348904466629 8.470144362449647 16.9348904466629 C 9.815144362449647 16.9348904466629 11.155144362449647 16.6178904466629 12.367144362449647 15.986890446662901 L 11.351144362449647 14.024890446662901 C 9.767144362449647 14.8468904466629 7.906144362449647 14.953890446662902 6.237144362449647 14.3178904466629 C 4.677144362449647 13.7218904466629 3.444144362449647 12.5558904466629 2.758144362449647 11.028890446662901 C 2.078144362449646 9.501890446662903 2.031144362449646 7.802890446662903 2.622144362449646 6.243890446662903 C 3.216144362449646 4.6798904466629025 4.387144362449646 3.442890446662903 5.914144362449646 2.760890446662903 C 7.437144362449646 2.078890446662903 9.137144362449646 2.0298904466629026 10.700144362449645 2.6258904466629027 C 11.946144362449646 3.100890446662903 12.971144362449646 3.9538904466629026 13.686144362449646 5.049890446662903 L 11.540144362449645 5.850890446662903 L 16.856144362449648 10.238890446662904 Z",width:20,height:20,pivotX:0,pivotY:0,opacity:1,visible:d,id:"rotateThumb",class:"e-diagram-rotate-handle"},this.diagramId,!0,void 0,{"aria-label":"Thumb to rotate the selected object"})},n.prototype.renderPathElement=function(t,e,i,r,s,o,a){var l=this.getBaseAttributes(t,i,o);if(l.data=t.absolutePath,l.data=t.absolutePath,t.isPathPort&&a){l.x=a[t.id]?a[t.id].cx:l.x,l.y=a[t.id]?a[t.id].cy:l.y,t.bounds.x=l.x,t.bounds.y=l.y;var h=document.getElementById(this.diagramId);h&&"PortDrag"!==h.ej2_instances[0].eventHandler.currentAction&&(t.offsetX=l.x+t.width/2,t.offsetY=l.y+t.height/2)}var u=t.description?t.description:t.id;if(this.isSvgMode||(l.x=t.flipOffset.x?t.flipOffset.x:l.x,l.y=t.flipOffset.y?t.flipOffset.y:l.y),t.isExport){var p=t.absoluteBounds,f=Cd(l.data),g=this.findAndStoreArcValues(f);l.arc=g,l.data=OF(t,p,0,l)}this.renderer.drawPath(e,l,this.diagramId,void 0,r,u)},n.prototype.findAndStoreArcValues=function(t){var e=[];return t.forEach(function(i){"A"===i.command&&e.push({r1:i.r1/2,r2:i.r2/2})}),e},n.prototype.renderSvgGridlines=function(t,e,i,r,s,o){var a=document.createElementNS("http://www.w3.org/2000/svg","pattern"),l=document.createElementNS("http://www.w3.org/2000/svg","defs");l.setAttribute("id",this.diagramId+"_grid_pattern_defn"),(t.constraints&ei.ShowHorizontalLines||t.constraints&ei.ShowVerticalLines)&&a.setAttribute("id",this.diagramId+"_pattern");var h=0,c=0,d=0,u=0,p=1,f=!1,g="Lines"===t.gridType,v=g?t.verticalGridlines.lineIntervals:t.verticalGridlines.dotIntervals,y=g?t.horizontalGridlines.lineIntervals:t.horizontalGridlines.dotIntervals;if(r.showRulers&&r.dynamicGrid&&s&&o)d=o.updateSegmentWidth(i.scale),u=s.updateSegmentWidth(i.scale),t.horizontalGridlines.scaledIntervals=[d/s.interval],t.verticalGridlines.scaledIntervals=[u/o.interval],f=!0;else{for(var S=0;S=2)for(;e>=2;)e/=2;else if(e<=.5)for(;e<=.5;)e*=2;var i;if(t.horizontalGridlines.scaledIntervals=t.horizontalGridlines.snapIntervals,t.verticalGridlines.scaledIntervals=t.verticalGridlines.snapIntervals,1!==e){var r=t.horizontalGridlines;for(r.scaledIntervals=[],i=0;ithis.groupElement.actualSize.height&&("Clip"===t.style.textOverflow||"Ellipsis"===t.style.textOverflow)&&(a.y=a.y+(a.height-this.groupElement.actualSize.height)/2),this.renderer.drawRectangle(e,a,this.diagramId,void 0,void 0,r),this.renderer.drawText(e,a,r,l,this.diagramId,t.isExport&&Math.min(t.exportScaleValue.x||t.exportScaleValue.y),this.groupElement),this.isSvgMode&&(t.doWrap=!1)},n.prototype.renderNativeElement=function(t,e,i,r,s){var o,a,l=this.getParentSvg(t,void 0,e)||r,h=this.getParentElement(t,e,l).g||e,c=this.getBaseAttributes(t,i);switch(c.fill="transparent",c.cornerRadius=t.cornerRadius,c.stroke="transparent",this.renderer.drawRectangle(e,c,this.diagramId,void 0,void 0,r),t.scale){case"None":o=t.contentSize.width,a=t.contentSize.height;break;case"Stretch":o=t.actualSize.width,a=t.actualSize.height;break;case"Meet":o=a=t.actualSize.width<=t.actualSize.height?t.actualSize.width:t.actualSize.height;break;case"Slice":o=a=t.actualSize.width>=t.actualSize.height?t.actualSize.width:t.actualSize.height}this.svgRenderer&&this.svgRenderer.drawNativeContent(t,h,a,o,l)},n.prototype.renderHTMLElement=function(t,e,i,r,s,o,a){var l=this.getBaseAttributes(t,r);l.fill="transparent",l.cornerRadius=t.cornerRadius,l.stroke="transparent",this.renderer.drawRectangle(e,l,this.diagramId,void 0,void 0,s),this.svgRenderer&&this.svgRenderer.drawHTMLContent(t,i.children[0],r,function lse(n){var t=n.parentElement;do{if(dm(t,"e-diagram"))return!0;t=t.parentElement}while(t);return!1}(i),a)},n.prototype.renderImageElement=function(t,e,i,r,s){var o=this.getBaseAttributes(t,i);o.cornerRadius=0,this.renderer.drawRectangle(e,o,this.diagramId,void 0,void 0,r);var a,l,h,c,g,d=t.contentSize.width,u=t.contentSize.height,p=o.width/d,f=o.height/u;if("Stretch"===t.stretch)a=d*(g=Math.min(p,f)),l=u*g;else switch(t.stretch){case"Meet":a=d*(g=Math.min(p,f)),l=u*g,o.x+=Math.abs(o.width-a)/2,o.y+=Math.abs(o.height-l)/2;break;case"Slice":g=Math.max(p,f),h=o.width/(a=d*g)*d,c=o.height/(l=u*g)*u;break;case"None":a=d,l=u}o.width=a,o.height=l,o.sourceWidth=h,o.sourceHeight=c,o.source=t.source,o.alignment=t.imageAlign,o.scale=t.imageScale,o.description=t.description?t.description:t.id,this.renderer.drawImage(e,o,r,s)},n.prototype.renderContainer=function(t,e,i,r,s,o,a,l,h,c,d){var g,u={svg:s,g:e},p=document.getElementById(this.diagramId);if(p&&(g=p.ej2_instances[0]),this.diagramId&&(s=this.getParentSvg(t)||s,this.isSvgMode)){var v=this.getParentElement(t,e,s,l).g||e;s=this.getParentSvg(this.hasNativeParent(t.children))||s;var y=this.getParentElement(this.hasNativeParent(t.children),v,s,l);u.svg=y.svg||s,u.g=y.g||v,o&&s&&(s.getElementById(u.g.id)||e.appendChild(u.g)),e=u.g}if(this.renderRect(t,e,r,s),this.groupElement=t,t.hasChildren()){for(var b,S=void 0,M=0,w=t.children;M0&&(D=g.selectedItems.nodes[0]);var L,A=void 0,x=void 0,R=!1;if(g&&g.selectedItems&&(L=g.getObject(t.id)),"None"!==t.flip&&(D=L),"None"===t.flip&&(D=L),D&&D.flipMode&&(R=!0),!(t.elementActions&Xr.ElementIsGroup)&&g instanceof zl&&g.nameTable[t.id]&&"connectors"!==g.nameTable[t.id].propName&&R&&D){if(A=t.children&&t.children[0]instanceof Cn?document.getElementById(D.id+"_content_inner_native_element"):document.getElementById(D.id+"_content_groupElement"),!(t.children[0]instanceof Cn)&&"Text"!==D.shape.type&&"None"!==D.flipMode&&"Label"!==D.flipMode&&"All"!==D.flipMode&&"PortAndLabel"!==D.flipMode&&"LabelText"!==D.flipMode&&"PortAndLabelText"!==D.flipMode&&"LabelAndLabelText"!==D.flipMode||t.children[0]instanceof Cn&&"Port"===D.flipMode)return void this.renderFlipElement(t,A,D.flip);if((t.children[0]instanceof Cn&&("All"===D.flipMode||"Label"===D.flipMode)||"Label"===D.flipMode||"PortAndLabel"===D.flipMode||"LabelText"===D.flipMode||"PortAndLabelText"===D.flipMode||"LabelAndLabelText"===D.flipMode||"Image"===D.shape.type&&"Label"===D.flipMode)&&this.renderFlipElement(t,A,t.flip),"None"!==t.flip&&"None"===D.flipMode)this.renderFlipElement(t,A,t.flip);else if("None"!==t.flip&&("Label"===D.flipMode||"PortAndLabel"===D.flipMode||"LabelText"===D.flipMode||"PortAndLabelText"===D.flipMode||"LabelAndLabelText"===D.flipMode)||t.children[0]instanceof Cn&&"None"!==t.flip&&D&&("None"===D.flipMode||"All"===D.flipMode)){for(var O=0;O0){var i=t[0];if(i instanceof Cn)return i;i.children&&i.children.length&&this.hasNativeParent(i.children,e++||0)}},n.prototype.renderRect=function(t,e,i,r,s){var o=this.getBaseAttributes(t,i,s);o.cornerRadius=t.cornerRadius||0,t.isExport&&(o.cornerRadius*=t.exportScaleValue.x),this.renderer.drawRectangle(e,o,this.diagramId,t.isExport,void 0,r,t.description?t.description:t.id)},n.prototype.drawRect=function(t,e){e.cornerRadius=0,this.svgRenderer.drawRectangle(t,e,this.diagramId)},n.prototype.getBaseAttributes=function(t,e,i){var r={width:t.actualSize.width,height:t.actualSize.height,x:t.offsetX-t.actualSize.width*t.pivot.x,y:t.offsetY-t.actualSize.height*t.pivot.y,fill:t.style.fill,stroke:t.style.strokeColor,angle:t.rotateAngle+t.parentTransform,pivotX:t.pivot.x,pivotY:t.pivot.y,strokeWidth:t.style.strokeWidth,dashArray:t.style.strokeDashArray||"",opacity:t.style.opacity,shadow:t.shadow,gradient:t.style.gradient,visible:t.visible,id:t.id,description:t.description,canApplyStyle:t.canApplyStyle,shapeType:t.shapeType};return"Page"===t.rotationReference&&(r.angle=t.rotateAngle),i&&(r.x=r.x-.5,r.y=r.y-.5),t.isExport&&(r.width*=t.exportScaleValue.x,r.height*=t.exportScaleValue.y,r.x*=t.exportScaleValue.x,r.y*=t.exportScaleValue.y,r.strokeWidth*=t.exportScaleValue.x),t.flip&&(r.flip=t.flip),e&&(r.x+=e.tx,r.y+=e.ty),r},n.renderSvgBackGroundImage=function(t,e,i,r,s,o){if(t.source){var l=mT(e.id).getElementById(e.id+"_image");if(!l){var h=function moe(n){return xt(n).getElementsByClassName("e-background-image-layer")[0]}(e.id);(l=document.createElementNS("http://www.w3.org/2000/svg","image")).setAttribute("id",e.id+"_image"),h.appendChild(l)}var c=new Image;c.src=t.source,l.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",c.src.toString());var d="None"!==t.scale?t.scale:"",u=t.align,p=u.charAt(0).toLowerCase()+u.slice(1);d&&(p+=" "+d.charAt(0).toLowerCase()+d.slice(1)),ai(l,{id:e.id+"_image",x:i,y:r,width:s,height:o,preserveAspectRatio:p})}},n.prototype.transformLayers=function(t,e){var i=t.tx*t.scale,r=t.ty*t.scale,s="domTable";if(i!==this.transform.x||r!==this.transform.y||0===i||0===r){e&&(window[""+s][this.diagramId+"_diagramLayer"]||(window[""+s][this.diagramId+"_diagramLayer"]=this.diagramSvgLayer.getElementById(this.diagramId+"_diagramLayer")),window[""+s][this.diagramId+"_diagramLayer"].setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+"),scale("+t.scale+")"));var a=function yoe(n){var t="domTable",e=null;return window[t][n+"_gridline"]?e=window[t][n+"_gridline"]:(e=Bd(n).getElementById(n+"_gridline"),window[t][n+"_gridline"]=e),e}(this.diagramId);return a.setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+")"),window[""+s][this.diagramId+"_diagramPorts"]||(window[""+s][this.diagramId+"_diagramPorts"]=this.iconSvgLayer.getElementById(this.diagramId+"_diagramPorts")),window[""+s][this.diagramId+"_diagramPorts"].setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+"),scale("+t.scale+")"),window[""+s][this.diagramId+"_diagramExpander"]||(window[""+s][this.diagramId+"_diagramExpander"]=this.iconSvgLayer.getElementById(this.diagramId+"_diagramExpander")),window[""+s][this.diagramId+"_diagramExpander"].setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+"),scale("+t.scale+")"),window[""+s][this.diagramId+"_nativeLayer"]||(window[""+s][this.diagramId+"_nativeLayer"]=this.nativeSvgLayer.getElementById(this.diagramId+"_nativeLayer")),window[""+s][this.diagramId+"_nativeLayer"].setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+"),scale("+t.scale+")"),Io(this.diagramId).children[0].style.transform="translate("+t.tx*t.scale+"px,"+t.ty*t.scale+"px)scale("+t.scale+")",this.transform={x:t.tx*t.scale,y:t.ty*t.scale},!0}return!1},n.prototype.updateNode=function(t,e,i,r,s,o,a){this.renderElement(t,e,i,r,this.getParentSvg(t),void 0,void 0,s,null,o,a)},n}(),tse=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),$I=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},oF=function(n){function t(e,i){var r=n.call(this,e,i)||this;return r.mode="Canvas",r.id="overview",r.actionName="",r.startPoint=null,r.currentPoint=null,r.prevPoint=null,r.scale=null,r.inAction=!1,r.viewPortRatio=1,r.horizontalOffset=0,r.verticalOffset=0,r.model={},r.event=!0,r.overviewid=88123,r.model={width:r.width,height:r.height},r}return tse(t,n),t.prototype.onPropertyChanged=function(e,i){for(var r=0,s=Object.keys(e);r0||e.toString().indexOf("%")>0?e.toString():e.toString()+"px"},t.prototype.renderCanvas=function(e){var i=document.getElementById(this.element.id+"_canvas");i||(i=Tt("div",{}),this.element.appendChild(i)),Ho(i,{id:this.element.id+"_canvas",class:"drawing",style:"position:relative; height:"+this.getSizeValue(this.model.height)+"; width:"+this.getSizeValue(this.model.width)+";style:-ms-touch-action: none;touch-action: none;"}),this.element.setAttribute("tabindex",String(-1)),this.element.style.overflow="hidden",this.element.style.height=String(this.model.height),this.element.style.width=String(this.model.width),this.canvas=i},t.prototype.setParent=function(e){var i=document.getElementById(e);if(this.parent){var s=this.parent;this.parent=null,s.setOverview(null,this.element.id),this.removeDocument(this)}this.parent=this.getDiagram(i,"ej2_instances"),this.parent&&this.parent.setOverview(this)},t.prototype.getDiagram=function(e,i){for(var r,s=e[""+i].length,o=0;o0?p:Math.floor(window.innerWidth)}if(0===h){var f=Math.floor(window.innerHeight-u-Math.floor(c.top));h=f>0?f:Math.floor(window.innerHeight)}l>0&&(s.setAttribute("width",String(l)),this.model.height=h),h>0&&(s.setAttribute("height",String(h)),this.model.width=l),e.diagramLayerDiv||(e.diagramLayerDiv=Tt("div",{}),e.diagramLayer=bo.createCanvas(this.element.id+"_diagramLayer",this.model.width,this.model.height),e.diagramLayer.setAttribute("style","position:absolute; left:0px; top:0px "),e.diagramLayerDiv.appendChild(e.diagramLayer),e.canvas.appendChild(e.diagramLayerDiv)),Ho(e.diagramLayerDiv,{id:this.element.id+"_diagramLayer_div",style:"width:"+this.model.width+"px; height:"+this.model.height+"px;position:absolute;top:0px;left:0px"}),this.renderHtmlLayer(e.canvas),this.renderNativeLayer(e.canvas,e),this.addOverviewRectPanel(e)},t.prototype.removeDocument=function(e){var i=document.getElementById(this.canvas.id+"_svg");this.canvas.removeChild(i);var r=document.getElementById(this.element.id+"_htmlLayer");this.canvas.removeChild(r);var s=document.getElementById(this.element.id+"_diagramLayer_div");this.canvas.removeChild(s),e.diagramLayerDiv=null,e.diagramLayer=null,window.domTable[this.id+"html_layer"]=null},t.prototype.renderHtmlLayer=function(e){var i=Tt("div",{id:this.element.id+"_htmlLayer",class:"e-html-layer",style:"pointer-events:none;position:absolute;top:0px;left:0px;"}),s=Tt("div",{id:this.element.id+"_htmlLayer_div",style:"position:absolute;top:0px;left:0px;"});return i.appendChild(s),e.appendChild(i),i},t.prototype.renderNativeLayer=function(e,i){if(!document.getElementById(this.element.id+"_nativeLayer_svg")){var r=this.parent.createSvg(this.element.id+"_nativeLayer_svg",this.model.width,this.model.height),s=Bi("g",{id:this.element.id+"_nativeLayer"});r.appendChild(s),i.diagramLayerDiv.appendChild(r),ai(r,{class:"e-native-layer"})}},t.prototype.addOverviewRectPanel=function(e){var i=document.getElementById(this.canvas.id+"_overviewsvg");i&&i.parentNode.removeChild(i),i=Bi("svg",{id:this.canvas.id+"_overviewsvg",class:"overviewsvg",version:"1.1",style:"position:absolute;left:0px;top:0px; aria-label:Specifies overview",width:this.model.width,height:this.model.height}),e.canvas.appendChild(i);var s=Bi("g",{id:this.element.id+"_overviewlayer",style:"pointer-events:none"});i.appendChild(s);var o=Bi("rect",{fill:"transparent",width:"100%",height:"100%",class:"overviewbackrect",id:this.canvas.id+"overviewbackrect"});o.setAttribute("style"," pointer-events: none; "),s.appendChild(o);var a=Bi("g",{id:this.canvas.id+"overviewhandle",style:"pointer-events:all"});s.appendChild(a);var l=Bi("rect",{id:this.canvas.id+"overviewrect",fill:"transparent"});a.appendChild(l),this.renderOverviewCorner("left",a),this.renderOverviewCorner("right",a),this.renderOverviewCorner("top",a),this.renderOverviewCorner("bottom",a),this.renderOverviewCorner("topleft",a),this.renderOverviewCorner("topright",a),this.renderOverviewCorner("bottomleft",a),this.renderOverviewCorner("bottomright",a)},t.prototype.renderOverviewCorner=function(e,i){var s,o=Bi(s="top"===e||"bottom"===e||"right"===e||"left"===e?"rect":"circle",{id:this.canvas.id+"visible"+e,class:"overview-resizer"});i.appendChild(o);var a=Bi(s,{id:this.canvas.id+e,class:"overviewresizer",fill:"transparent"});i.appendChild(a)},t.prototype.updateOverviewRectangle=function(){var e=this.currentPoint.x-this.prevPoint.x,i=this.currentPoint.y-this.prevPoint.y,r=new me;r.width=0,r.height=0;var s=0,o=0;switch(this.resizeDirection){case"left":r.width-=e,r.height-=e/this.viewPortRatio,s=e,o=e/this.viewPortRatio,o/=2;break;case"right":r.width+=e,r.height+=e/this.viewPortRatio,o=e/this.viewPortRatio,o/=-2;break;case"top":r.height-=i,r.width-=i*this.viewPortRatio,o=i,s=i*this.viewPortRatio,s/=2;break;case"bottom":r.height+=i,r.width+=i*this.viewPortRatio,s=i*this.viewPortRatio,s/=-2;break;case"topleft":Math.abs(i)>Math.abs(e)?e=i*this.viewPortRatio:i=e/this.viewPortRatio,r.width-=e,r.height-=i,s=e,o=i;break;case"topright":Math.abs(i)>Math.abs(e)?e=-i*this.viewPortRatio:i=-e/this.viewPortRatio,o=i,r.width+=e,r.height-=i;break;case"bottomleft":Math.abs(i)>Math.abs(e)?e=-i*this.viewPortRatio:i=-e/this.viewPortRatio,s=e,r.width-=e,r.height+=i;break;case"bottomright":Math.abs(i)>Math.abs(e)?e=i*this.viewPortRatio:i=e/this.viewPortRatio,r.width+=e,r.height+=i}this.updateHelper(s,o,r,void 0,void 0)},t.prototype.updateHelper=function(e,i,r,s,o){var a,l,h,u,p,d=this.element.getElementsByTagName("svg")[2].getElementById("helper");r?(a=(h=d.getBBox()).x+e,l=h.y+i,s=h.width+r.width,o=h.height+r.height):(u=this.currentPoint.x>this.startPoint.x?this.currentPoint.x-this.prevPoint.x:this.prevPoint.x-this.currentPoint.x,p=this.currentPoint.y>this.startPoint.y?this.currentPoint.y-this.prevPoint.y:this.prevPoint.y-this.currentPoint.y,Math.abs(p)>Math.abs(u)?u=this.viewPortRatio*p:p=u/this.viewPortRatio,h=d.getBBox(),a=this.startPoint.x>this.currentPoint.x?h.x-u:h.x,l=this.startPoint.y>this.currentPoint.y?h.y-p:h.y,s=h.width+u,o=h.height+p),ai(this.helper,{id:this.helper.id,x:a,y:l,width:Math.max(0,s),height:Math.max(0,o)})},t.prototype.updateOverviewrect=function(e,i,r,s){Ho(document.getElementById(this.canvas.id+"overviewrect"),{x:e,y:i,width:Math.max(1,r),height:Math.max(1,s)}),this.updateOverviewCorner("top",e+8,i+1,Math.max(0,r-16),2),this.updateOverviewCorner("bottom",e+8,i+s+3,Math.max(0,r-16),2),this.updateOverviewCorner("left",e-2,i+11,2,Math.max(0,s-16)),this.updateOverviewCorner("right",e+r,i+11,2,Math.max(0,s-16)),this.updateOverviewCorner("topleft",e,i+3,5,5),this.updateOverviewCorner("topright",e+r,i+3,5,5),this.updateOverviewCorner("bottomleft",e,i+s+3,5,5),this.updateOverviewCorner("bottomright",e+r,i+s+3,5,5)},t.prototype.updateOverviewCorner=function(e,i,r,s,o){var a,l;"top"===e||"bottom"===e||"right"===e||"left"===e?(a={x:i,y:r,width:s,height:o,fill:"#ED1C24"},l={x:i-2,y:r-2,width:2===s?4:s,height:2===o?4:o}):(a={cx:i,cy:r,r:4,fill:"#ED1C24"},l={cx:i,cy:r,r:6,fill:"transparent"}),Ho(document.getElementById(this.canvas.id+"visible"+e),a),Ho(document.getElementById(this.canvas.id+e),l)},t.prototype.translateOverviewRectangle=function(){Number(this.model.width),Number(this.model.height);var r=this.currentPoint.x-this.prevPoint.x,s=this.currentPoint.y-this.prevPoint.y,l=this.element.getElementsByClassName("overviewsvg")[0].getElementById(this.canvas.id+"overviewrect").getBBox(),h=l.x+r,c=l.y+s,d=l.width,u=l.height;this.updateOverviewrect(h,c,d,u),this.updateParentView(this.parent.scroller.currentZoom,h,c,d,u,null)},t.prototype.renderOverviewRect=function(e,i,r,s){var o=Number(this.model.width),a=Number(this.model.height),c=Math.max(this.parent.scroller.viewPortWidth/(r/o*this.contentWidth),this.parent.scroller.viewPortHeight/(s/a*this.contentHeight));if(c>=.25&&c<=30){this.updateParentView(c,e,i,r,s,{x:0,y:0});var u=this.scrollOverviewRect(this.parent.scroller.horizontalOffset,this.parent.scroller.verticalOffset,this.parent.scroller.currentZoom,!0);if(this.helper){var f=this.element.getElementsByTagName("rect")[10].getBBox();u.x=f.x,u.y=f.y}"pan"===this.actionName?this.updateOverviewrect(-u.x,-u.y,u.width,u.height):this.updateOverviewrect(u.x,u.y,u.width,u.height)}},t.prototype.scrollOverviewRect=function(e,i,r,s){if(!this.actionName||s){var o=Number(this.model.width),a=Number(this.model.height),l=Math.min(this.contentWidth/o,this.contentHeight/a),h=new Ne,c=h.x=e/r/l,d=h.y=i/r/l,u=0;this.parent.rulerSettings.showRulers&&(u=25);var p=document.getElementById(this.parent.element.id+"content"),f=0,g=0;p&&(f=p.offsetWidth-p.clientWidth,g=p.offsetHeight-p.clientHeight);var v=h.width=(this.parent.scroller.viewPortWidth-u-f)/r/l,y=h.height=(this.parent.scroller.viewPortHeight-u-g)/r/l;if(s){var S=new Ne;return S.x=c,S.y=d,S.width=v,S.height=y,S}this.updateOverviewrect(-c,-d,v,y)}return null},t.prototype.updateParentView=function(e,i,r,s,o,a){var f,g,l=Number(this.model.width),h=Number(this.model.height),u=i*(this.contentWidth/l)*e,p=r*(this.contentHeight/h)*e;this.parent.scroller.getPageBounds(),(1!==e||"pan"===this.actionName)&&(f=-u-this.parent.scroller.horizontalOffset,g=-p-this.parent.scroller.verticalOffset),this.parent.setBlazorDiagramProps(!0),this.parent.realActions|=$i.OverViewAction,"scale"===this.actionName||"draw"===this.actionName?this.parent.scroller.zoom(e/this.parent.scroller.currentZoom,f,g,a):ce()?this.parent.scroller.zoom(1,f,g,a):this.parent.pan(f,g,a,!0)},t.prototype.updateHtmlLayer=function(e){var i=Io(e.element.id),r=this.parent.scroller.getPageBounds(!0),o=r.height,a=Math.max(r.width,this.parent.scroller.viewPortWidth),l=Math.max(o,this.parent.scroller.viewPortHeight/this.parent.scroller.currentZoom),h=Math.min(Number(this.model.width)/a,Number(this.model.height)/l);i.style.transform="scale("+h+") translate("+this.parent.scroller.transform.tx+"px,"+this.parent.scroller.transform.ty+"px)"},t.prototype.updateView=function(e){var i=this.parent.scroller.getPageBounds(),r=i.width,s=i.height,o=Number(this.model.width),a=Number(this.model.height),l=Math.max(r,this.parent.scroller.viewPortWidth),h=Math.max(s,this.parent.scroller.viewPortHeight);this.contentWidth=l=Math.max(l,o/a*h),this.contentHeight=h=Math.max(h,a/o*l);var c=Math.min(o/l,a/h),d=document.getElementById(this.element.id+"_htmlLayer");d.style.webkitTransform="scale("+c+") translate("+-i.x+"px,"+-i.y+"px)",d.style.transform="scale("+c+") translate("+-i.x+"px,"+-i.y+"px)",document.getElementById(this.element.id+"_overviewlayer").setAttribute("transform","translate("+-i.x*c+","+-i.y*c+")"),this.horizontalOffset=i.x*c,this.verticalOffset=i.y*c;var p=document.getElementById(this.element.id+"_diagramLayer"),f=zF(this.element.id),g=p.getContext("2d"),v=Number(this.model.width)/this.contentWidth,y=Number(this.model.height)/this.contentHeight;v=Math.min(v,y);var S=this.parent.scroller.transform;f.setAttribute("transform","translate("+S.tx*v+","+S.ty*y+"),scale("+v+")"),g.setTransform(v,0,0,v,0,0),g.fillStyle="red",this.scrollOverviewRect(this.parent.scroller.horizontalOffset,this.parent.scroller.verticalOffset,this.parent.scroller.currentZoom)},t.prototype.scrolled=function(e){if(this.event){var i=this.scrollOverviewRect(this.parent.scroller.horizontalOffset,this.parent.scroller.verticalOffset,this.parent.scroller.currentZoom,!0);this.updateOverviewrect(-i.x,-i.y,i.width,i.height),this.updateView(this)}},t.prototype.updateCursor=function(e){if(dm(e.target,"overviewresizer"))switch(e.target.id){case this.canvas.id+"left":this.canvas.style.cursor="w-resize";break;case this.canvas.id+"right":this.canvas.style.cursor="e-resize";break;case this.canvas.id+"top":this.canvas.style.cursor="n-resize";break;case this.canvas.id+"bottom":this.canvas.style.cursor="s-resize";break;case this.canvas.id+"topleft":this.canvas.style.cursor="nw-resize";break;case this.canvas.id+"topright":this.canvas.style.cursor="ne-resize";break;case this.canvas.id+"bottomleft":this.canvas.style.cursor="sw-resize";break;case this.canvas.id+"bottomright":this.canvas.style.cursor="se-resize"}else this.canvas.style.cursor="default"},t.prototype.mouseMove=function(e){if(this.event=!1,this.updateCursor(e),this.currentPoint=this.mousePosition(e),this.actionName)switch(this.actionName){case"draw":!this.inAction&&(this.startPoint.x!==this.currentPoint.x||this.startPoint.y!==this.currentPoint.y)&&(this.initHelper(),this.inAction=!0),this.inAction&&this.updateHelper();break;case"scale":this.inAction||(this.initHelper(),this.inAction=!0),this.updateOverviewRectangle();break;case"pan":(this.startPoint.x!==this.currentPoint.x||this.startPoint.y===this.currentPoint.y||this.inAction)&&(this.inAction=!0,this.translateOverviewRectangle())}this.prevPoint=this.currentPoint},t.prototype.documentMouseUp=function(e){this.inAction=!1,this.actionName="",this.helper&&(this.helper.parentNode.removeChild(this.helper),this.helper=null),this.event=!0,document.getElementById(this.canvas.id+"overviewhandle").style.pointerEvents="all"},t.prototype.windowResize=function(e){var i=this;return this.resizeTo&&clearTimeout(this.resizeTo),this.resizeTo=setTimeout(function(){var s=document.getElementById(i.element.id).getBoundingClientRect();i.model.width=s.width>0?s.width:i.model.width,i.model.height=s.height>0?s.height:i.model.height,i.renderCanvas(),i.setParent(i.sourceID)},10),!1},t.prototype.mouseDown=function(e){if(e.target.id===this.canvas.id+"_overviewsvg"&&(this.actionName="draw"),e.target.id===this.canvas.id+"overviewrect"&&(this.actionName="pan"),dm(e.target,"overviewresizer"))switch(this.actionName="scale",e.target.id){case this.canvas.id+"left":this.resizeDirection="left";break;case this.canvas.id+"right":this.resizeDirection="right";break;case this.canvas.id+"top":this.resizeDirection="top";break;case this.canvas.id+"bottom":this.resizeDirection="bottom";break;case this.canvas.id+"topleft":this.resizeDirection="topleft";break;case this.canvas.id+"topright":this.resizeDirection="topright";break;case this.canvas.id+"bottomleft":this.resizeDirection="bottomleft";break;case this.canvas.id+"bottomright":this.resizeDirection="bottomright"}this.startPoint=this.prevPoint=this.mousePosition(e),this.viewPortRatio=this.parent.scroller.viewPortWidth/this.parent.scroller.viewPortHeight,document.getElementById(this.canvas.id+"overviewhandle").style.pointerEvents="none"},t.prototype.mouseUp=function(e){if(this.currentPoint=this.mousePosition(e),this.actionName)if(this.startPoint.x!==this.currentPoint.x||this.startPoint.y!==this.currentPoint.y){if("pan"!==this.actionName&&this.helper){var i=this.element.getElementsByTagName("rect")[10].getBBox();this.resizeDirection=this.resizeDirection||"",this.renderOverviewRect(i.x,i.y,o=i.width,a=i.height)}}else if(e.target.id===this.canvas.id+"_overviewsvg"||"helper"===e.target.id){var o=(i=this.element.getElementsByTagName("svg")[2].getElementById(this.canvas.id+"overviewrect").getBBox()).width,a=i.height;this.inAction=!0,this.actionName="pan",this.renderOverviewRect(this.currentPoint.x-o/2,this.currentPoint.y-a/2,o,a),this.inAction=!1}this.helper&&(this.helper.parentNode.removeChild(this.helper),this.helper=null),this.actionName="",this.startPoint=null,this.currentPoint=null,this.prevPoint=null,this.helper=null,this.viewPortRatio=1,this.resizeDirection="",this.inAction=!1,this.event=!0,document.getElementById(this.canvas.id+"overviewhandle").style.pointerEvents="all"},t.prototype.initHelper=function(){var e=this.element.getElementsByTagName("svg")[2],i=this.startPoint.x,r=this.startPoint.y,s=1,o=1;if("scale"===this.actionName){var l=e.getElementById(this.canvas.id+"overviewrect").getBBox();i=l.x,r=l.y,s=l.width,o=l.height}var h=Bi("rect",{id:"helper",x:i,y:r,width:s,height:o,fill:"transparent",stroke:"gray","stroke-dasharray":"2 2","shape-rendering":"crispEdges"});e.getElementById(this.element.id+"_overviewlayer").appendChild(h),this.helper=h},t.prototype.mousePosition=function(e){var i,r,s;-1!==e.type.indexOf("touch")?(r=(i=e).changedTouches[0].clientX-this.element.offsetLeft,s=i.changedTouches[0].clientY-this.element.offsetTop):(r=e.clientX,s=e.clientY);var l=this.element.getBoundingClientRect();return{x:(r-=l.left)+this.horizontalOffset,y:(s-=l.top)+this.verticalOffset}},t.prototype.destroy=function(){if(this.unWireEvents(),this.notify("destroy",{}),n.prototype.destroy.call(this),document.getElementById(this.element.id)){this.element.classList.remove("e-overview");var e=document.getElementById(this.element.id+"_canvas");e&&this.element.removeChild(e)}this.parent.views.splice(this.parent.views.indexOf(this.element.id),1),this.diagramLayerDiv=null,this.canvas=null,this.parent=null},t.prototype.getModuleName=function(){return"Overview"},$I([I("100%")],t.prototype,"width",void 0),$I([I("100%")],t.prototype,"height",void 0),$I([I("")],t.prototype,"sourceID",void 0),$I([H()],t.prototype,"created",void 0),t}(yi);function rse(n,t){for(var e=0;ez.findLength(e,n)?e:t;var o=z.findAngle(t,e),a=z.findAngle(i,n),l=z.findLength(i,n),h=a+2*(o-a);return{x:i.x+l*Math.cos(h*Math.PI/180),y:i.y+l*Math.sin(h*Math.PI/180)}}function $p(n,t,e){if(n&&n.children&&n.children.length>0)for(var r=void 0,s=0;s0&&"annotations"!==r&&"ports"!==r)if(n[""+l].length>0)for(var h=0;h<=n[""+l].length;h++)Ro(n[""+l],t?t[""+l]:void 0,e[""+l],"annotations"===l||"ports"===l?n:void 0,l);else Ro(n[""+l],t?t[""+l]:void 0,e[""+l],"annotations"===l||"ports"===l?n:void 0,l);else if(s instanceof Object&&t&&"annotations"!==r&&"ports"!==r)Ro(n[""+l],t[""+l],e[""+l]);else if("annotations"!==r&&"ports"!==r&&t&&!t[""+l]||!t&&n&&(n[""+l]||void 0!==n[""+l]))n[""+l]=e[""+l];else{var c=void 0;("annotations"===r||"ports"===r)&&("annotations"===r?(n[""+l]&&Ro(n[""+l],t[""+l],e[""+l]),n[""+l]||(fs(i)===de?(c=new Nr(i,"annotations",e[""+l]),i.annotations.push(c)):(c=new Zn(i,"annotations",e[""+l]),i.annotations.push(c)))):n[""+l]?Ro(n[""+l],t[""+l],e[""+l]):(c=new Es(i,"ports",e[""+l]),i.ports.push(c)))}}}function cse(n,t){for(var e="Bezier"===n.type?function ase(n){var t=[];if("Bezier"===n.type)for(var e=0,i=0;i0||n.ports.length>0){var p=n.wrapper.children;for(i=3;i0)return{enabled:!1,intersectPt:e};var l=o/s,h=a/s;return l>=0&&l<=1&&h>=0&&h<=1?(e.x=i.x1+l*(i.x2-i.x1),e.y=i.y1+l*(i.y2-i.y1),{enabled:!0,intersectPt:e}):{enabled:!1,intersectPt:e}}function JI(n,t,e,i){var a=em(cF(n.x,n.y,t.x,t.y),cF(e.x,e.y,i.x,i.y));return a.enabled?a.intersectPt:{x:0,y:0}}function cF(n,t,e,i){return{x1:Number(n)||0,y1:Number(t)||0,x2:Number(e)||0,y2:Number(i)||0}}function dF(n,t,e){var i=[],s={x:t.topRight.x+(e=e||0),y:t.topRight.y},o={x:t.bottomRight.x,y:t.bottomRight.y-e},a={x:t.bottomLeft.x,y:t.bottomLeft.y+e};return i.push({x:t.topLeft.x-e,y:t.topLeft.y}),i.push(s),i.push(o),i.push(a),i}function zc(n,t,e,i,r,s){var o={},a=e.scroller.transform.scale,h=e.scroller.verticalOffset;return o.x=(i?n.x:t.x)*a+e.scroller.horizontalOffset-r,o.y=(i?n.y:t.y)*a+h-s,o}function uF(n,t){var e=new Ke;return e.data=n.pathData,e.height=n.height>10?n.height-(n.padding.bottom+n.padding.top):n.height,e.width=n.width>10?n.width-(n.padding.left+n.padding.right):n.width,e.visible=n.visibility,e.id=t.id+"_shape",e.inversedAlignment=!1,e.horizontalAlignment="Center",e.verticalAlignment="Center",e.style={fill:n.iconStrokeColor,strokeColor:n.iconStrokeColor,strokeWidth:n.iconStrokeWidth},e.setOffsetWithRespectToBounds(.5,.5,"Fraction"),e.relativeMode="Object",e.description=t.description||"",e}function Xx(n,t,e){var i=qx(n,t),r=z.findAngle(n[i.index],n[i.index+1]),s=function mse(n){var t;t=n instanceof EI?0:void 0===n.content?10:0;var e=0;switch(n.alignment){case"Center":e=0;break;case"Before":e=-(0+t);break;case"After":e=0+t}return e}(t),o=z.transform(i.point,r+45,s);return i.point=o,i.angle=r,i}function qx(n,t){for(var r,s,a,l,e=0,i=t.offset,o=[],h=0;h=c)return s=z.findAngle(n[parseInt(d.toString(),10)],n[d+1]),{point:r=z.transform(n[parseInt(d.toString(),10)],s,c-(a||0)),index:l=d};a=o[parseInt(d.toString(),10)]}return{point:r,index:l}}function pF(n,t,e){t%=360;var a,l,s=225;switch(n.alignment){case"Before":t>=45&&t<=135?(l="right",a=.5===n.offset?"center":"top"):t>=s&&t<=315?(l="left",a=.5===n.offset?"center":"bottom"):t>45&&t=45&&t<=135?(l="left",a=.5===n.offset?"center":"top"):t>=s&&t<=315?(l="right",a=.5===n.offset?"center":"bottom"):t>45&&tMath.abs(t.y-n.y)?n.x0)for(var e=0;e=0;r--)("nodes"===i||"connectors"===i)&&(n[""+i][parseInt(r.toString(),10)].wrapper=null),"dataManager"!==i&&(n[""+i][parseInt(r.toString(),10)]=Jx(n[""+i][parseInt(r.toString(),10)],e[""+i][parseInt(r.toString(),10)],void 0!==t[""+i]?t[""+i][parseInt(r.toString(),10)]:[]),("[]"===JSON.stringify(n[""+i][parseInt(r.toString(),10)])||"{}"===JSON.stringify(n[""+i][parseInt(r.toString(),10)])||void 0===n[""+i][parseInt(r.toString(),10)])&&n[""+i].splice(r,1));n=void 0}function Ph(n,t){var e=t.style,i=t;t.canApplyStyle=!0;for(var r=0,s=Object.keys(n);r=0&&n.splice(e,1)}function Zp(n,t,e){var i;n.intermediatePoints=t,n.updateSegmentElement(n,t,n.wrapper.children[0],e);var r=n.sourceDecorator;if("Bezier"===n.type){var s=n.segments[0],o=n.segments[n.segments.length-1];i=[z.isEmptyPoint(o.point2)?o.bezierPoint2:o.point2,z.isEmptyPoint(s.point1)?s.bezierPoint1:s.point1]}else i=n.intermediatePoints;t=n.clipDecorators(n,t,e);var a=n.wrapper.children[0];a.canMeasurePath=!0,n.updateDecoratorElement(a=n.wrapper.children[1],t[0],i[1],r),n.updateDecoratorElement(a=n.wrapper.children[2],t[t.length-1],i[i.length-2],n.targetDecorator),n.updateShapeElement(n)}function Kx(n,t,e){var l,i=n.wrapper,s=t.offset,o=t.size/e.scale,a=t.margin,h=i.offsetX-i.actualSize.width*i.pivot.x,c=i.offsetY-i.actualSize.height*i.pivot.y;if(l={x:0,y:0},n.nodes.length>0){switch(t.side){case"Top":l.x+=h+s*i.actualSize.width,l.y+=c-o;break;case"Bottom":l.x+=h+s*i.actualSize.width,l.y+=c+i.actualSize.height+o;break;case"Left":l.x+=h-o,l.y+=c+s*i.actualSize.height;break;case"Right":l.x+=h+i.actualSize.width+o,l.y+=c+s*i.actualSize.height}l.x+=(a.left-a.right)/e.scale+o/2*("Center"===t.horizontalAlignment?0:"Right"===t.horizontalAlignment?-1:1),l.y+=(a.top-a.bottom)/e.scale+o/2*("Center"===t.verticalAlignment?0:"Top"===t.verticalAlignment?-1:1)}else if(n.connectors.length>0){var d=n.connectors[0],u={offset:s},p=qx(d.intermediatePoints,u),f=p.index;l=p.point;var y,v=Xx(d.intermediatePoints,u).angle;qi(y=Hi(),-v,d.intermediatePoints[parseInt(f.toString(),10)].x,d.intermediatePoints[parseInt(f.toString(),10)].y),(l=Je(y,l)).x+=a.left-a.right+o/2*("Center"===t.horizontalAlignment?0:"Right"===t.horizontalAlignment?-1:1),l.y+=a.top-a.bottom+o/2*("Center"===t.verticalAlignment?0:"Top"===t.verticalAlignment?-1:1),qi(y=Hi(),v,d.intermediatePoints[parseInt(f.toString(),10)].x,d.intermediatePoints[parseInt(f.toString(),10)].y),l=Je(y,l)}return 0===i.rotateAngle&&0===i.parentTransform||(qi(y=Hi(),i.rotateAngle+i.parentTransform,i.offsetX,i.offsetY),l=Je(y,l)),l}function fa(n,t,e,i){if(i.annotation){if(Ol(i.annotation))return!0}else if(mr[""+t]&n&&bt[""+t]&e)return!0;return!1}function qr(n,t){return!!(mr[""+t]&n)}function Hc(n,t){return!!(bx[""+t]&n)}function ga(n,t){return n.visibility&t}function KI(n,t){var e;if("Text"===n.shape.type)e=n.shape;else{var i=t.split("_");t=i[i.length-1];for(var r=0;rn[""+t]?e.splice(0,0,n):e.push(n);else if(e.length>1){for(var i=0,r=e.length-1,s=Math.floor((i+r)/2);s!==i;)if(e[parseInt(s.toString(),10)][""+t]n[""+t]))break;r=s,s=Math.floor((i+r)/2)}e[parseInt(r.toString(),10)][""+t]n[""+t]?e.splice(i,0,n):e[parseInt(i.toString(),10)][""+t]n[""+t]&&e.splice(r,0,n)}}function zse(n){var t=document.getElementById(n.diagramId),e="ej2_instances",i=t[""+e][0].nodes;void 0===i&&(i=function Rse(n){for(var t=[],e=0;e30?10:o/2;for(var h=0,c=0;c=l){var u=l-h;r=Xt(n[c],n[c+1]),s=z.transform(n[c],r,u);break}h+=d}return s},ib=function(n,t){if(n instanceof te||n instanceof de)for(var e=0;e=0||navigator.platform.indexOf("iPad")>=0||navigator.platform.indexOf("iPhone")>=0||navigator.platform.indexOf("MacIntel")>=0)&&("safari"===X.info.name||"webkit"===X.info.name)}function wF(n,t,e,i){return void 0!==t.previewSize[""+i]?t.previewSize[""+i]:void 0!==n.symbolPreview[""+i]?n.symbolPreview[""+i]:t[""+i]||e.actualSize[""+i]}function sm(n,t,e){return n&&n.parentId&&(e=(n=t.nameTable[n.parentId]).parentId?sm(n,t,e):n.id),e}function om(n,t){return n.selectedItems.connectors.length>1&&0===n.selectedItems.nodes.length&&0!==t.rotateAngle}function _se(n){if(n.arrowType&&""!==n.arrowType.trim())switch(n.arrowType){case"single-line-arrow":default:return{targetDecorator:"Arrow",strokeWidth:1};case"double-line-arrow":return{targetDecorator:"Arrow",strokeWidth:2};case"dotted-arrow":return{targetDecorator:"Arrow",strokeDashArray:"2,2"};case"single-line":return{targetDecorator:"None",strokeWidth:1};case"double-line":return{targetDecorator:"None",strokeWidth:2};case"dotted":return{targetDecorator:"None",strokeDashArray:"2,2"};case"wiggly-arrow":return{targetDecorator:"None",strokeWidth:1,opacity:0}}return{targetDecorator:"Arrow",strokeWidth:1}}var Use=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),io=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},CF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Use(t,n),io([I("None")],t.prototype,"shape",void 0),io([I("white")],t.prototype,"fill",void 0),io([I("Auto")],t.prototype,"horizontalAlignment",void 0),io([I("Auto")],t.prototype,"verticalAlignment",void 0),io([I(10)],t.prototype,"width",void 0),io([I(10)],t.prototype,"height",void 0),io([re({x:.5,y:1},z)],t.prototype,"offset",void 0),io([I("#1a1a1a")],t.prototype,"borderColor",void 0),io([I(1)],t.prototype,"borderWidth",void 0),io([re({},$n)],t.prototype,"margin",void 0),io([I("")],t.prototype,"pathData",void 0),io([I("")],t.prototype,"content",void 0),io([I(0)],t.prototype,"cornerRadius",void 0),io([re({left:2,right:2,top:2,bottom:2},$n)],t.prototype,"padding",void 0),io([I("#1a1a1a")],t.prototype,"iconColor",void 0),t}(Ee),jse=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),rT=function(n){function t(){var e=null!==n&&n.apply(this,arguments)||this;return e.orientation="Vertical",e.measureChildren=void 0,e.considerPadding=!0,e}return jse(t,n),t.prototype.measure=function(e){return this.desiredSize=this.measureStackPanel(e,"Horizontal"===this.orientation?this.updateHorizontalStack:this.updateVerticalStack),this.desiredSize},t.prototype.arrange=function(e){return this.actualSize=this.arrangeStackPanel(e,"Horizontal"===this.orientation?this.arrangeHorizontalStack:this.arrangeVerticalStack),this.updateBounds(),this.actualSize},t.prototype.measureStackPanel=function(e,i){var r=void 0;if(void 0!==this.children&&this.children.length>0)for(var s=0,o=this.children;s0){var r=void 0,s=void 0;r=this.offsetX-e.width*this.pivot.x+this.padding.left,s=this.offsetY-e.height*this.pivot.y+this.padding.top;for(var o=0,a=this.children;o0)for(var i=0,r=this.children;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},$se=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return qse(t,n),zh([I("Horizontal")],t.prototype,"orientation",void 0),zh([I("Center")],t.prototype,"type",void 0),zh([I(void 0)],t.prototype,"offset",void 0),zh([I(!1)],t.prototype,"enableRouting",void 0),zh([I([])],t.prototype,"children",void 0),zh([I("")],t.prototype,"assistants",void 0),zh([I("")],t.prototype,"level",void 0),zh([I("")],t.prototype,"hasSubTree",void 0),zh([I("")],t.prototype,"rows",void 0),t}(Ee),Li=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),q=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Zse=function(n){if(n)switch(n.type){case"Basic":default:return rb;case"Flow":return TF;case"Path":return EF;case"Image":return xF;case"Text":return Pd;case"Bpmn":return hT;case"Native":return am;case"HTML":return DF;case"UmlActivity":return AF;case"UmlClassifier":return LF;case"SwimLane":return Hd}return rb},va=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),q([I("Basic")],t.prototype,"type",void 0),t}(Ee),EF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"Path"},q([I("Path")],t.prototype,"type",void 0),q([I("")],t.prototype,"data",void 0),t}(va),am=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"Native"},q([I("Native")],t.prototype,"type",void 0),q([I("")],t.prototype,"content",void 0),q([I("Stretch")],t.prototype,"scale",void 0),t}(va),DF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"Html"},q([I("HTML")],t.prototype,"type",void 0),q([I("")],t.prototype,"content",void 0),t}(va),xF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"Image"},q([I("Image")],t.prototype,"type",void 0),q([I("")],t.prototype,"source",void 0),q([I("None")],t.prototype,"scale",void 0),q([I("None")],t.prototype,"align",void 0),t}(va),Pd=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"Text"},q([I("Text")],t.prototype,"type",void 0),q([I("")],t.prototype,"content",void 0),q([re({},$n)],t.prototype,"margin",void 0),t}(va),rb=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"BasicShape"},q([I("Basic")],t.prototype,"type",void 0),q([I("Rectangle")],t.prototype,"shape",void 0),q([I(0)],t.prototype,"cornerRadius",void 0),q([Bt([],z)],t.prototype,"points",void 0),t}(va),TF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"FlowShape"},q([I("Flow")],t.prototype,"type",void 0),q([I("Terminator")],t.prototype,"shape",void 0),t}(va),sT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"BpmnGateway"},q([I("None")],t.prototype,"type",void 0),t}(Ee),oT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"BpmnDataObject"},q([I("None")],t.prototype,"type",void 0),q([I(!1)],t.prototype,"collection",void 0),t}(Ee),Jse=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),q([I("None")],t.prototype,"type",void 0),q([I("None")],t.prototype,"loop",void 0),q([I(!1)],t.prototype,"call",void 0),q([I(!1)],t.prototype,"compensation",void 0),t}(Ee),aT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"BpmnEvent"},q([I("Start")],t.prototype,"event",void 0),q([I("None")],t.prototype,"trigger",void 0),t}(Ee),zd=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"BpmnSubEvent"},q([I("None")],t.prototype,"trigger",void 0),q([I("Start")],t.prototype,"event",void 0),q([I("")],t.prototype,"id",void 0),q([re({},z)],t.prototype,"offset",void 0),q([Bt([],Zn)],t.prototype,"annotations",void 0),q([Bt([],Es)],t.prototype,"ports",void 0),q([I()],t.prototype,"width",void 0),q([I()],t.prototype,"height",void 0),q([re({},$n)],t.prototype,"margin",void 0),q([I("Center")],t.prototype,"horizontalAlignment",void 0),q([I("Center")],t.prototype,"verticalAlignment",void 0),q([I(!0)],t.prototype,"visible",void 0),t}(Ee),Kse=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),q([re({id:"success",event:"End",offset:{x:1,y:.5}},zd)],t.prototype,"success",void 0),q([re({id:"failure",event:"Intermediate",trigger:"Error",offset:{x:.25,y:1}},zd)],t.prototype,"failure",void 0),q([re({id:"cancel",event:"Intermediate",trigger:"Cancel",offset:{x:.75,y:1}},zd)],t.prototype,"cancel",void 0),t}(Ee),eoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),q([I("None")],t.prototype,"type",void 0),q([I(!1)],t.prototype,"adhoc",void 0),q([I("Default")],t.prototype,"boundary",void 0),q([I(!1)],t.prototype,"compensation",void 0),q([I("None")],t.prototype,"loop",void 0),q([I(!0)],t.prototype,"collapsed",void 0),q([Bt([],zd)],t.prototype,"events",void 0),q([re({},Kse)],t.prototype,"transaction",void 0),q([I(void 0)],t.prototype,"processes",void 0),t}(Ee),lT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"BpmnActivity"},q([I("Task")],t.prototype,"activity",void 0),q([re({},Jse)],t.prototype,"task",void 0),q([re({},eoe)],t.prototype,"subProcess",void 0),t}(Ee),lm=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return Li(t,n),t.prototype.getClassName=function(){return"BpmnAnnotation"},q([I("")],t.prototype,"text",void 0),q([I("")],t.prototype,"id",void 0),q([I(0)],t.prototype,"angle",void 0),q([I()],t.prototype,"height",void 0),q([I()],t.prototype,"width",void 0),q([I(0)],t.prototype,"length",void 0),t}(Ee),toe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),q([I("")],t.prototype,"textAnnotationTarget",void 0),q([I("Auto")],t.prototype,"textAnnotationDirection",void 0),t}(Ee),hT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"BpmnShape"},q([I("Bpmn")],t.prototype,"type",void 0),q([I("Event")],t.prototype,"shape",void 0),q([re({},aT)],t.prototype,"event",void 0),q([re({},sT)],t.prototype,"gateway",void 0),q([re({},oT)],t.prototype,"dataObject",void 0),q([re({},lT)],t.prototype,"activity",void 0),q([re({},lm)],t.prototype,"annotation",void 0),q([Bt([],lm)],t.prototype,"annotations",void 0),q([re({},toe)],t.prototype,"textAnnotation",void 0),t}(va),AF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"UmlActivityShape"},q([I("UmlActivity")],t.prototype,"type",void 0),q([I("Action")],t.prototype,"shape",void 0),t}(va),cT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"MethodArguments"},q([I("")],t.prototype,"name",void 0),q([I("")],t.prototype,"type",void 0),q([re({},Yp)],t.prototype,"style",void 0),t}(Ee),rf=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"UmlClassAttribute"},q([I("Public")],t.prototype,"scope",void 0),q([I(!1)],t.prototype,"isSeparator",void 0),q([re({fill:"#F9F9F9",strokeColor:"#CCCCCC"},Al)],t.prototype,"separatorStyle",void 0),t}(cT),hm=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"UmlClassMethod"},q([Bt([],cT)],t.prototype,"parameters",void 0),t}(rf),nb=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"UmlClass"},q([I("")],t.prototype,"name",void 0),q([Bt([],rf)],t.prototype,"attributes",void 0),q([Bt([],hm)],t.prototype,"methods",void 0),q([re({},Yp)],t.prototype,"style",void 0),t}(Ee),dT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"UmlInterface"},q([I(!1)],t.prototype,"isSeparator",void 0),q([re({fill:"#F9F9F9",strokeColor:"#CCCCCC"},Al)],t.prototype,"separatorStyle",void 0),t}(nb),sb=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"UmlEnumerationMember"},q([I("")],t.prototype,"name",void 0),q([I("")],t.prototype,"value",void 0),q([I(!1)],t.prototype,"isSeparator",void 0),q([re({fill:"#F9F9F9",strokeColor:"#CCCCCC"},Al)],t.prototype,"separatorStyle",void 0),q([re({},Yp)],t.prototype,"style",void 0),t}(Ee),uT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"UmlEnumeration"},q([I("")],t.prototype,"name",void 0),q([Bt([],sb)],t.prototype,"members",void 0),q([re({},Yp)],t.prototype,"style",void 0),t}(Ee),LF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"UmlClassifierShape"},q([I("UmlClassifier")],t.prototype,"type",void 0),q([re({},nb)],t.prototype,"classShape",void 0),q([re({},dT)],t.prototype,"interfaceShape",void 0),q([re({},uT)],t.prototype,"enumerationShape",void 0),q([I("Class")],t.prototype,"classifier",void 0),t}(va),te=function(n){function t(e,i,r,s){var a,o=n.call(this,e,i,r,s)||this;return o.isCanvasUpdate=!1,o.status="None",o.parentId="",o.processId="",o.umlIndex=-1,o.outEdges=[],o.inEdges=[],o.isHeader=!1,o.isLane=!1,o.isPhase=!1,o.children&&o.children.length>0&&((!(a=r).style||!a.style.fill)&&(o.style.fill="transparent"),(!a.style||!a.style.strokeColor)&&(o.style.strokeColor="transparent")),o.shape&&"UmlActivity"===o.shape.type&&ZI(r,o),o.shape&&"SwimLane"===o.shape.type&&aF(r,o),o.ports&&o.ports.length&&function sse(n){for(var t=0;t>";t=n;break;case"FinalNode":t=fF(e)}return t}(new Ke,i,this);break;case"Bpmn":if(e.bpmnModule){i=e.bpmnModule.initBPMNContent(i,this,e),this.wrapper.elementActions=this.wrapper.elementActions|Xr.ElementIsGroup;var v=this.shape.activity.subProcess;if(v.processes&&v.processes.length)for(var S=0,b=this.shape.activity.subProcess.processes;S>",margin:{left:10,right:10},id:"class",style:{fontSize:i.style.fontSize,color:i.style.color,fill:i.style.fill,textWrapping:r},offset:{x:.5,y:.3},constraints:Lr.ReadOnly}],constraints:(ie.Default|ie.HideThumbs)&~(ie.Rotate|ie.Drag|ie.Resize),verticalAlignment:"Stretch",horizontalAlignment:"Stretch",style:{fill:t.style.fill,strokeColor:"black"===t.style.strokeColor?"#ffffff00":t.style.strokeColor}},!0);return e.initObject(s),e.nodes.push(s),e.UpdateBlazorDiagramModel(s,"Node"),t.children.push(s.id),function Wse(n,t,e,i){if("Enumeration"===n.shape.classifier){var r=e.members;if(r&&r.length){ef(n,t);for(var s="",o=0;o0)for(var o=0;o0&&s.phaseSize&&(i+=s.phaseSize,Gv(n,s.phaseSize)),s.lanes.length>0)for(o=0;o0){var a=0;for(o=0;o0&&"Horizontal"===r.orientation)for(l=0;l0&&(i+=r.phaseSize,o=Xv(r.phaseSize),n.push(o)),a=0;a0&&o.phaseSize){for(var l=0;l0)for(l=0;l0?e.nameTable[this.nodes[0].id].wrapper:e.nameTable[this.connectors[0].id].wrapper,this.annotation.id);i.children.push(s)}else if(this.nodes||this.connectors){for(var o=0;o-1}function HF(n,t,e){n=[];for(var i=0,r=e.length;i0?c.getElementsByTagName("svg")[0].outerHTML:c.getElementsByTagName("g").length>0?c.getElementsByTagName("g")[0].outerHTML:"",s.shape.content=h,n.content=h,c.parentElement.removeChild(c)}l="nodeTemplate"}else a=s,l="annotationTemplate";var f=document.getElementById(n.diagramId).ej2_instances[0];if("string"!=typeof n.content&&"function"!=typeof n.content||n.isTemplate)if(n.isTemplate){if(v=void 0,v=f.isReact?n.getNodeTemplate()($(e),f,l+"_"+("nodeTemplate"===l?e.id:n.nodeId+e.id),void 0,void 0,!1,i):f.isVue||f.isVue3?n.getNodeTemplate()?n.getNodeTemplate()($(e),f,l+"_"+("nodeTemplate"===l?e.id:n.nodeId+e.id),void 0,void 0,!1,i):(v=ri("nodeTemplate"===l?f.nodeTemplate:f.annotationTemplate))($(e),f,l+"_"+("nodeTemplate"===l?e.id:n.nodeId+e.id),void 0,void 0,!1,i):n.getNodeTemplate()($(e),f,l+"_"+("nodeTemplate"===l?e.id:n.nodeId+e.id),void 0,void 0,!1))for(var M=0;M=1&&0===n.x&&("Clip"===i.textOverflow||"Ellipsis"===i.textOverflow)&&("Wrap"===i.textWrapping||"WrapWithOverflow"===i.textWrapping)&&(n.x=t[e-1]?t[e-1].x:-n.width/2),n.x}function _F(n,t,e,i){return e&&!t.template||t.template&&"function"==typeof t.template&&i.isReact?(n.isTemplate=!0,n.template=n.content=Rh(n,!0,t)):n.content=t.template,n}function Qe(){for(var e,t="",i=0;i<5;i++){if(typeof window<"u"&&"crypto"in window&&"getRandomValues"in crypto){var r=new Uint16Array(1);e=(window.msCrypto||window.crypto).getRandomValues(r)[0]%60}else e=Math.floor(61*Math.random());0===i&&e<10?i--:t+="0123456789ABCDEFGHIJKLMNOPQRSTUVWXTZabcdefghiklmnopqrstuvwxyz".substring(e,e+1)}return t}function UF(n){if(n)try{return"function"!=typeof n&&document.querySelectorAll(n).length?ri(document.querySelector(n).innerHTML.trim()):ri(n)}catch{return ri(n)}}function En(n){new Ne;var e=n.offsetY-n.actualSize.height*n.pivot.y,i=n.offsetY+n.actualSize.height*(1-n.pivot.y),r=n.offsetX-n.actualSize.width*n.pivot.x,s=n.offsetX+n.actualSize.width*(1-n.pivot.x);return Ne.toBounds([{x:r,y:e},{x:s,y:e},{x:r,y:i},{x:s,y:i}])}function yr(n){var t=new Ne,e=En(n),i=e.middleLeft,r=e.topCenter,s=e.bottomCenter,o=e.middleRight,a=e.topLeft,l=e.topRight,h=e.bottomLeft,c=e.bottomRight;if(n.corners={topLeft:a,topCenter:r,topRight:l,middleLeft:i,middleRight:o,bottomLeft:h,bottomCenter:s,bottomRight:c},0!==n.rotateAngle||0!==n.parentTransform){var d=Hi();qi(d,n.rotateAngle+n.parentTransform,n.offsetX,n.offsetY),n.corners.topLeft=a=Je(d,a),n.corners.topCenter=r=Je(d,r),n.corners.topRight=l=Je(d,l),n.corners.middleLeft=i=Je(d,i),n.corners.middleRight=o=Je(d,o),n.corners.bottomLeft=h=Je(d,h),n.corners.bottomCenter=s=Je(d,s),n.corners.bottomRight=c=Je(d,c)}return t=Ne.toBounds([a,l,h,c]),n.corners.left=t.left,n.corners.right=t.right,n.corners.top=t.top,n.corners.bottom=t.bottom,n.corners.center=t.center,n.corners.width=t.width,n.corners.height=t.height,t}function $(n,t,e,i){var r={},s="properties";if(n){e=n.propName;var l=[],h=[];if((l=l.concat(Object.keys(n[""+s]||n))).push("version"),e){var c=Zi(t);h=c?c(e):[],l=l.concat(h)}for(var d=function boe(n){switch(n){case"nodes":case"children":return["inEdges","outEdges","parentId","processId","nodeId","umlIndex","isPhase","isLane"];case"connectors":return["parentId"];case"annotation":case"annotations":return["nodeId"];case"shape":return["hasHeader"];case"layers":return["objectZIndex"]}return[]}(e),u=0,p=l=l.concat(d);u0&&(e=r),r=Math.floor(woe(e,i)),s=Bc(o+=n.substr(e,r),t)}while(s<=t.width);for(o=o.substr(0,e),a=e;a=t.width){n=n.substr(0,o.length-1);break}return"Ellipsis"===t.textOverflow?(n=n.substr(0,n.length-3),n+="..."):n=n.substr(0,n.length),n}function ST(n,t){if("NoWrap"===t&&"PreserveAll"===n)return"pre";var e="";switch(n){case"CollapseAll":e="nowrap";break;case"CollapseSpace":e="pre-line";break;case"PreserveAll":e="pre-wrap"}return e}function IT(n,t){var e=Hi();qi(e,t,0,0);var i=Je(e,{x:0,y:0}),r=Je(e,{x:n.width,y:0}),s=Je(e,{x:0,y:n.height}),o=Je(e,{x:n.width,y:n.height}),a=Math.min(i.x,r.x,s.x,o.x),l=Math.min(i.y,r.y,s.y,o.y),h=Math.max(i.x,r.x,s.x,o.x),c=Math.max(i.y,r.y,s.y,o.y);return new me(h-a,c-l)}function xs(n,t,e,i){if(0!==n){var r=Hi();return qi(r,n,t,e),Je(r,i)}return i}function Zi(n){return void 0!==n&&"string"==typeof n&&(n=Y(n,window)),n}var bo=function(){function n(){}return n.getContext=function(t){return t.getContext("2d")},n.setCanvasSize=function(t,e,i){t&&(t.setAttribute("width",e.toString()),t.setAttribute("height",i.toString()))},n.prototype.renderGradient=function(t,e,i,r){var s,o,a;if("None"!==t.gradient.type){for(var l=0;l0?(w=0===S.r1?e.arc[parseInt(r.toString(),10)].r1:S.r1,C=0===S.r2?e.arc[parseInt(r.toString(),10)].r2:S.r2,r++):(w=S.r1,C=S.r2);var D=S.angle*(Math.PI/180),A=S.largeArc,x=S.sweep,R={x:u,y:p},L={x:Math.cos(D)*(M.x-R.x)/2+Math.sin(D)*(M.y-R.y)/2,y:-Math.sin(D)*(M.x-R.x)/2+Math.cos(D)*(M.y-R.y)/2},O=Math.pow(L.x,2)/Math.pow(w,2)+Math.pow(L.y,2)/Math.pow(C,2);O>1&&(w*=Math.sqrt(O),C*=Math.sqrt(O));var N=Math.pow(C,2)*Math.pow(L.x,2),T=(A===x?-1:1)*Math.sqrt((Math.pow(w,2)*Math.pow(C,2)-Math.pow(w,2)*Math.pow(L.y,2)-N)/(Math.pow(w,2)*Math.pow(L.y,2)+Math.pow(C,2)*Math.pow(L.x,2)));isNaN(T)&&(T=0);var P={x:T*w*L.y/C,y:T*-C*L.x/w},_={x:(M.x+R.x)/2+Math.cos(D)*P.x-Math.sin(D)*P.y,y:(M.y+R.y)/2+Math.sin(D)*P.x+Math.cos(D)*P.y},B=this.a([1,0],[(L.x-P.x)/w,(L.y-P.y)/C]),j=[(L.x-P.x)/w,(L.y-P.y)/C],Q=[(-L.x-P.x)/w,(-L.y-P.y)/C],oe=this.a(j,Q);this.r(j,Q)<=-1&&(oe=Math.PI),this.r(j,Q)>=1&&(oe=0);var pe=B+oe/2*(x?1:-1);if(Math.cos(pe),Math.sin(pe),S.centp=_,S.xAxisRotation=D,S.rx=w,S.ry=C,S.a1=B,S.ad=oe,S.sweep=x,null!=s){var De=w>C?w:C,xe=w>C?1:w/C,Ie=w>C?C/w:1;s.save(),s.translate(_.x,_.y),s.rotate(D),s.scale(xe,Ie),s.arc(0,0,De,B,B+oe,!x),s.scale(1/xe,1/Ie),s.rotate(-D),s.translate(-_.x,-_.y),s.restore()}break;case"Z":case"z":s.closePath(),u=o,p=a}o=u,a=p}}},n.prototype.drawText=function(t,e,i,r,s,o,a){if(e.content&&!0===e.visible){var l=n.getContext(t);l.save(),this.setStyle(t,e),o&&(e.fontSize*=o),this.rotateContext(t,e.angle,e.x+e.width*e.pivotX,e.y+e.height*e.pivotY),this.setFontStyle(t,e);var u,d=0;u=e.childNodes;var p=e.wrapBounds;if(l.fillStyle=e.color,p){var f=this.labelAlign(e,p,u);for(d=0;de.width&&"Wrap"!==e.textOverflow&&"NoWrap"===e.textWrapping&&(g.text=VF(g.text,e)),"Clip"!==e.textOverflow&&"Ellipsis"!==e.textOverflow||"Wrap"!==e.textWrapping?l.fillText(g.text,v,y):ya.actualSize.height+a.bounds.y&&(g.text=g.text.slice(0,g.text.length-3),g.text=g.text.concat("...")),l.fillText(g.text,v,y)),"Underline"===e.textDecoration||"Overline"===e.textDecoration||"LineThrough"===e.textDecoration){var M=v,w=void 0,D=v+l.measureText(g.text).width,A=void 0;switch(e.textDecoration){case"Underline":w=y+2,A=y+2;break;case"Overline":w=f.y+g.dy*d,A=f.y+g.dy*d;break;case"LineThrough":w=(y+f.y+g.dy*d)/2+2,A=(y+f.y+g.dy*d)/2+2}l.beginPath(),l.moveTo(M,w),l.lineTo(D,A),l.strokeStyle=e.color,l.lineWidth=.08*e.fontSize,l.globalAlpha=e.opacity,l.stroke()}}}l.restore()}},n.prototype.loadImage=function(t,e,i,r,s){this.rotateContext(i,e.angle,r,s);var o=new Image;o.src=e.source,this.image(t,o,e.x,e.y,e.width,e.height,e)},n.prototype.drawImage=function(t,e,i,r){var s=this;if(e.visible){var o=n.getContext(t);o.save();var a=e.x+e.width*e.pivotX,l=e.y+e.height*e.pivotY,h=new Image;h.src=e.source,o.canvas.id.split("_"),r?h.onload=function(){s.loadImage(o,e,t,a,l)}:this.loadImage(o,e,t,a,l),o.restore()}},n.prototype.image=function(t,e,i,r,s,o,a){t.beginPath();var l=e.width,h=e.height,c=s,d=o,u=0,p=0;if(a&&"None"!==a.alignment){var f=a.alignment.toLowerCase().substr(1,3),g=a.alignment.toLowerCase().substr(5,3);if("Slice"===a.scale){var v=function(){u=c,p=h*c/l},y=function(){u=l*d/h,p=d};c>d?(v(),d>p&&y()):c===d?l>h?y():v():(y(),c>u&&v());var S=this.getSliceOffset(f,u,c,l),b=this.getSliceOffset(g,p,d,h),M=l-S,w=h-b,C=u-S*(u/l),D=p-b*(p/h),A=Tt("canvas",{width:s.toString(),height:o.toString()});A.getContext("2d").drawImage(e,S,b,M,w,0,0,C,D),t.drawImage(A,i,r,s,o)}else if("Meet"===a.scale){var R=h/l,L=d/c;p=L>R?c*R:d,i+=this.getMeetOffset(f,u=L>R?c:d/R,c),r+=this.getMeetOffset(g,p,d),t.drawImage(e,0,0,l,h,i,r,u,p)}else t.drawImage(e,i,r,s,o)}else if("None"!==a.flip){var O=1,N=1;("Horizontal"===a.flip||"Both"===a.flip)&&(i=-i,s=-s,O=-1),("Vertical"===a.flip||"Both"===a.flip)&&(r=-r,o=-o,N=-1),t.scale(O,N),t.drawImage(e,i,r,s,o)}else t.drawImage(e,i,r,s,o);t.closePath()},n.prototype.getSliceOffset=function(t,e,i,r){switch(t){case"min":default:return 0;case"mid":return(e-i)/2*r/e;case"max":return(e-i)*r/e}},n.prototype.getMeetOffset=function(t,e,i){var r=Math.max(e,i),s=Math.min(e,i);switch(t){case"min":default:return 0;case"mid":return(r-s)/2;case"max":return r-s}},n.prototype.m=function(t){return Math.sqrt(Math.pow(t[0],2)+Math.pow(t[1],2))},n.prototype.r=function(t,e){return(t[0]*e[0]+t[1]*e[1])/(this.m(t)*this.m(e))},n.prototype.a=function(t,e){return(t[0]*e[1]t.width&&("Ellipsis"===t.textOverflow||"Clip"===t.textOverflow)&&"NoWrap"===t.textWrapping?0:.5*t.width:"right"===t.textAlign&&(c=1*t.width),s.x=t.x+c+(e?e.x:0),s.y=a+d-r.height/2,s},n}(),cb=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Vi=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Eoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return cb(t,n),Vi([I("")],t.prototype,"source",void 0),Vi([I("transparent")],t.prototype,"color",void 0),Vi([I("None")],t.prototype,"scale",void 0),Vi([I("None")],t.prototype,"align",void 0),t}(Ee),Doe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return cb(t,n),Vi([I("Page")],t.prototype,"mode",void 0),Vi([I("PageSettings")],t.prototype,"region",void 0),Vi([re({top:25,bottom:25,left:25,right:25},$n)],t.prototype,"margin",void 0),Vi([I(!1)],t.prototype,"canZoomIn",void 0),Vi([I(void 0)],t.prototype,"customBounds",void 0),Vi([I(!1)],t.prototype,"canFit",void 0),t}(Ee),xoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return cb(t,n),Vi([I(null)],t.prototype,"width",void 0),Vi([I(null)],t.prototype,"height",void 0),Vi([re({},$n)],t.prototype,"margin",void 0),Vi([I("Landscape")],t.prototype,"orientation",void 0),Vi([I("Infinity")],t.prototype,"boundaryConstraints",void 0),Vi([re({},Eoe)],t.prototype,"background",void 0),Vi([I(!1)],t.prototype,"multiplePage",void 0),Vi([I(!1)],t.prototype,"showPageBreaks",void 0),Vi([re({},Doe)],t.prototype,"fitOptions",void 0),t}(Ee),Toe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return cb(t,n),Vi([I(0)],t.prototype,"horizontalOffset",void 0),Vi([I(0)],t.prototype,"verticalOffset",void 0),Vi([I(1)],t.prototype,"currentZoom",void 0),Vi([I(0)],t.prototype,"viewPortWidth",void 0),Vi([I(0)],t.prototype,"viewPortHeight",void 0),Vi([I(.2)],t.prototype,"minZoom",void 0),Vi([I(30)],t.prototype,"maxZoom",void 0),Vi([I("Diagram")],t.prototype,"scrollLimit",void 0),Vi([I()],t.prototype,"scrollableArea",void 0),Vi([I(!1)],t.prototype,"canAutoScroll",void 0),Vi([I(100)],t.prototype,"autoScrollFrequency",void 0),Vi([re({left:15,right:15,top:15,bottom:15},$n)],t.prototype,"autoScrollBorder",void 0),Vi([re({left:0,right:0,top:0,bottom:0},$n)],t.prototype,"padding",void 0),Vi([I(.2)],t.prototype,"zoomFactor",void 0),t}(Ee),Aoe=function(){function n(){this.services={}}return n.prototype.register=function(t,e){this.services[""+t]=e},n.prototype.getService=function(t){return this.services[""+t]},n}(),WF=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),ma=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},YF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return WF(t,n),ma([I("lightgray")],t.prototype,"lineColor",void 0),ma([I("")],t.prototype,"lineDashArray",void 0),ma([I([1.25,18.75,.25,19.75,.25,19.75,.25,19.75,.25,19.75])],t.prototype,"lineIntervals",void 0),ma([I([1,19,.5,19.5,.5,19.5,.5,19.5,.5,19.5])],t.prototype,"dotIntervals",void 0),ma([I([20])],t.prototype,"snapIntervals",void 0),t}(Ee),Loe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return WF(t,n),ma([re({},YF)],t.prototype,"horizontalGridlines",void 0),ma([re({},YF)],t.prototype,"verticalGridlines",void 0),ma([I(ei.All)],t.prototype,"constraints",void 0),ma([I(5)],t.prototype,"snapAngle",void 0),ma([I("Lines")],t.prototype,"gridType",void 0),ma([I(5)],t.prototype,"snapObjectDistance",void 0),ma([I("#07EDE1")],t.prototype,"snapLineColor",void 0),t}(Ee),QF=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Ja=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},GF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return QF(t,n),Ja([I(5)],t.prototype,"interval",void 0),Ja([I(100)],t.prototype,"segmentWidth",void 0),Ja([I("Horizontal")],t.prototype,"orientation",void 0),Ja([I("RightOrBottom")],t.prototype,"tickAlignment",void 0),Ja([I("red")],t.prototype,"markerColor",void 0),Ja([I(25)],t.prototype,"thickness",void 0),Ja([I(null)],t.prototype,"arrangeTick",void 0),t}(Ee),Noe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return QF(t,n),Ja([I(!1)],t.prototype,"showRulers",void 0),Ja([I(!0)],t.prototype,"dynamicGrid",void 0),Ja([re({orientation:"Horizontal"},GF)],t.prototype,"horizontalRuler",void 0),Ja([re({orientation:"Vertical"},GF)],t.prototype,"verticalRuler",void 0),t}(Ee),Ooe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),XF=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},koe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ooe(t,n),XF([I("")],t.prototype,"property",void 0),XF([I("")],t.prototype,"field",void 0),t}(Ee),bT=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),ln=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},qF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return bT(t,n),ln([I("")],t.prototype,"read",void 0),ln([I("")],t.prototype,"create",void 0),ln([I("")],t.prototype,"update",void 0),ln([I("")],t.prototype,"destroy",void 0),ln([I()],t.prototype,"customFields",void 0),t}(Ee),Poe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return bT(t,n),ln([I("")],t.prototype,"id",void 0),ln([I("")],t.prototype,"sourceID",void 0),ln([I("")],t.prototype,"targetID",void 0),ln([I(null)],t.prototype,"sourcePointX",void 0),ln([I(null)],t.prototype,"sourcePointY",void 0),ln([I(null)],t.prototype,"targetPointX",void 0),ln([I(null)],t.prototype,"targetPointY",void 0),ln([I(null)],t.prototype,"dataManager",void 0),ln([re({},qF)],t.prototype,"crudAction",void 0),t}(Ee),zoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return bT(t,n),ln([I("")],t.prototype,"id",void 0),ln([I(null)],t.prototype,"dataManager",void 0),ln([I(null)],t.prototype,"dataSource",void 0),ln([I("")],t.prototype,"root",void 0),ln([I("")],t.prototype,"parentId",void 0),ln([I()],t.prototype,"doBinding",void 0),ln([Bt([],koe)],t.prototype,"dataMapSettings",void 0),ln([re({},qF)],t.prototype,"crudAction",void 0),ln([re({},Poe)],t.prototype,"connectionDataSource",void 0),t}(Ee),$F=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Cr=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Roe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return $F(t,n),Cr([I("LeftInFlow")],t.prototype,"yesBranchDirection",void 0),Cr([I("RightInFlow")],t.prototype,"noBranchDirection",void 0),Cr([I(["Yes","True"])],t.prototype,"yesBranchValues",void 0),Cr([I(["No","False"])],t.prototype,"noBranchValues",void 0),t}(Ee),Hoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return $F(t,n),Cr([I("")],t.prototype,"fixedNode",void 0),Cr([I(30)],t.prototype,"horizontalSpacing",void 0),Cr([I("SamePoint")],t.prototype,"connectionPointOrigin",void 0),Cr([I("Nonlinear")],t.prototype,"arrangement",void 0),Cr([I(30)],t.prototype,"verticalSpacing",void 0),Cr([I(30)],t.prototype,"maxIteration",void 0),Cr([I(40)],t.prototype,"springFactor",void 0),Cr([I(50)],t.prototype,"springLength",void 0),Cr([re({left:50,top:50,right:0,bottom:0},$n)],t.prototype,"margin",void 0),Cr([I("Auto")],t.prototype,"horizontalAlignment",void 0),Cr([I("Auto")],t.prototype,"verticalAlignment",void 0),Cr([I("TopToBottom")],t.prototype,"orientation",void 0),Cr([I("Auto")],t.prototype,"connectionDirection",void 0),Cr([I("Default")],t.prototype,"connectorSegments",void 0),Cr([I("None")],t.prototype,"type",void 0),Cr([I()],t.prototype,"getLayoutInfo",void 0),Cr([I()],t.prototype,"layoutInfo",void 0),Cr([I()],t.prototype,"getBranch",void 0),Cr([I()],t.prototype,"bounds",void 0),Cr([I(!0)],t.prototype,"enableAnimation",void 0),Cr([I(!1)],t.prototype,"enableRouting",void 0),Cr([I("")],t.prototype,"root",void 0),Cr([re({},Roe)],t.prototype,"flowchartLayoutSettings",void 0),t}(Ee),Boe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),ZF=function(n){function t(e,i){var r=n.call(this,e,!0)||this;return r.oldValue=null,r.endPoint=i,r}return Boe(t,n),t.prototype.mouseDown=function(e){var i,r=!0;if(e.source&&e.source.connectors&&(i=e.source.connectors[0]),e.info&&e.actualObject&&(r=e.info.ctrlKey&&"Orthogonal"!==e.actualObject.type),i&&r){this.inAction=!0,this.undoElement=$(e.source),n.prototype.mouseDown.call(this,e);for(var s=0;s0)1!==s&&this.removePrevSegment(i,s);else if(a){var l=z.distancePoints(a.points[0],a.points[1]);Math.abs(a.length||0===a.length?a.length:l)<=5&&this.removeNextSegment(i,s)}this.commandHandler.updateEndPoint(i,r),i.selectedSegmentIndex=0}if(this.undoElement){var c=$(e.source);this.commandHandler.addHistoryEntry({type:"SegmentChanged",redoObject:c,undoObject:this.undoElement,category:"Internal"})}if(i.isBezierEditing&&(i.isBezierEditing=!1),this.prevPosition!==this.startPosition){var u={source:i,state:"Completed",oldValue:this.oldValue,newValue:$(this.selectedSegment),cancel:!1,segment:this.selectedSegment};this.commandHandler.triggerEvent(Ce.segmentChange,u)}n.prototype.mouseUp.call(this,e)},t.prototype.removePrevSegment=function(e,i){var r=e.segments[i-2],s=e.segments[i+1];if(s&&!((s.length||0===s.length?s.length:z.distancePoints(s.points[0],s.points[1]))<=5)){var a=e.segments.slice(i-1,i+1),l={element:e,removeSegments:a,type:"Removal",cancel:!1};if(this.commandHandler.triggerEvent(Ce.segmentCollectionChange,l),!l.cancel){var h=e.segments[i+1];e.segments.splice(i-1,2);var c=this.selectedSegment;"Left"===c.direction||"Right"===c.direction?(r.points[r.points.length-1].x=h.points[0].x,h.points[0].y=r.points[r.points.length-1].y):(r.points[r.points.length-1].y=h.points[0].y,h.points[0].x=r.points[r.points.length-1].x),(c.length||0===c.length)&&this.findSegmentDirection(r),this.findSegmentDirection(h)}}},t.prototype.findSegmentDirection=function(e){e.direction&&(e.length||0===e.length)&&(e.length=z.distancePoints(e.points[0],e.points[e.points.length-1]),e.direction=z.direction(e.points[0],e.points[e.points.length-1]))},t.prototype.removeNextSegment=function(e,i){var l,h,r=this.selectedSegment,s=e.segments[i-1],o=e.segments[i+2],a=e.segments[i+1];if(a.length||0===a.length?(l=e.segments.slice(i,2),h={element:e,removeSegments:l,type:"Removal",cancel:!1},this.commandHandler.triggerEvent(Ce.segmentCollectionChange,h={element:e,removeSegments:l,type:"Removal",cancel:!1}),h.cancel||(e.segments.splice(i,2),"Top"===r.direction||"Bottom"===r.direction?(o.points[0].y=r.points[0].y,s.points[s.points.length-1].x=o.points[0].x):(o.points[0].x=r.points[0].x,s.points[s.points.length-1].y=o.points[0].y))):(l=e.segments.slice(i+1,1),this.commandHandler.triggerEvent(Ce.segmentCollectionChange,h={element:e,removeSegments:l,type:"Removal",cancel:!1}),h.cancel||(e.segments.splice(i+1,1),"Top"===r.direction||"Bottom"===r.direction?s.points[s.points.length-1].x=a.points[a.points.length-1].x:s.points[s.points.length-1].y=a.points[a.points.length-1].y,this.findSegmentDirection(s),r.length=r.direction=null)),s&&o&&!h.cancel&&(s.length=z.distancePoints(s.points[0],o.points[0]),s.direction=z.direction(s.points[0],o.points[0]),o.length||0===o.length)){o.length=z.distancePoints(s.points[s.points.length-1],o.points[o.points.length-1]);var c=s.points,d=o.points;o.direction=z.direction(c[c.length-1],d[d.length-1])}},t.prototype.addOrRemoveSegment=function(e,i,r){for(var s,o,a=[],l={segments:e.segments},h=0;h0?"Bottom":"Top":r>0?"Right":"Left",length:i.points[0].x===i.points[1].x?s:r},!0)),l.push(new bi(e,"segments",{type:"Orthogonal",direction:c,length:h/2},!0));var p={element:e,addSegments:l,type:"Addition",cancel:!1};return this.commandHandler.triggerEvent(Ce.segmentCollectionChange,p),p.cancel||(e.segments=l.concat(e.segments),a=o+2),a},t.prototype.insertFirstSegment=function(e,i,r,s,o){var a,l,d,u,h=[];if(e.sourcePortID&&i.length&&e.segments[0].points.length>2)for(var p=void 0,f=0;f0?"Bottom":"Top":r>0?"Right":"Left"),p=u,h.push(u)}else h.push(new bi(e,"segments",{type:"Orthogonal",direction:i.direction,length:i.length/3},!0)),"Bottom"===i.direction||"Top"===i.direction?(l=Math.abs(r),a=r>0?"Right":"Left"):(l=Math.abs(s),a=s>0?"Bottom":"Top"),u=new bi(e,"segments",{type:"Orthogonal",direction:a,length:l},!0),h.push(u);var y={element:e,addSegments:h,type:"Addition",cancel:!1};if(this.commandHandler.triggerEvent(Ce.segmentCollectionChange,y),!y.cancel){if(e.sourcePortID&&i.length&&e.segments[0].points.length>2)e.segments.splice(0,1),d=1;else{var S=e.segments[1];S&&S.length&&(S.length=a!==S.direction?S.length+l:S.length-l),d=2,i.length=2*i.length/3}e.segments=h.concat(e.segments)}return d},t.prototype.updateAdjacentSegments=function(e,i,r,s){var o=e.segments[parseInt(i.toString(),10)],a=o.points[o.points.length-1],h=!0;"Orthogonal"===o.type&&(o.points[0]=o.points[0],o.points[o.points.length-1]=a,e.segments[i-1]&&(h=this.updatePreviousSegment(r,s,e,i)),e.segments.length-1>i&&h&&this.updateNextSegment(e,o,e.segments[i+1],r,s))},t.prototype.addTerminalSegment=function(e,i,r,s,o){var l,h,c,d,a=e.segments.indexOf(i),u=[],p=e.segments.pop(),f=e.segments[e.segments.length-1];l=f&&"Orthogonal"===f.type?f:null;for(var g=0;g0&&"Left"===o.direction?c.middleLeft:c.middleRight,o.length>c.width/2?Math.abs(a.length)0&&"Top"===o.direction?c.topCenter:c.bottomCenter,o.length>c.height/2?Math.abs(a.length)1)for(var a=0,l=this.diagram.views;a0)for(var e=t===Ce.onUserHandleMouseLeave?this.previousAction:this.action,i={element:void 0},r=0;r0)for(var r={element:void 0},s=void 0,o=void 0,a=0;a-1&&(o=s,this.previousTarget=i,this.targetItem=e),o===e.fixedUserHandles[parseInt(a.toString(),10)].id&&(r.element=e.fixedUserHandles[parseInt(a.toString(),10)],this.userHandle(t,a,r,e))},n.prototype.mouseDown=function(t){if(!0!==this.inAction||!(this.tool instanceof VI||this.tool instanceof pa)){this.focus=!0;var e=t.touches,i=!!document.getElementsByClassName("e-dragclone")[0];if(this.isMouseOnScrollBar(t)&&!i)return this.isScrolling=!0,void t.preventDefault();if(this.checkFixedUserHandleEvent(Ce.onFixedUserHandleMouseDown,this.targetItem,this.previousTarget),this.checkUserHandleEvent(Ce.onUserHandleMouseDown),!this.checkEditBoxAsTarget(t)&&jv(this.diagram)||Lc(this.diagram)&&!PI(this.diagram))if(("Select"===this.action||"Drag"===this.action)&&this.diagram.updatePortVisibility(this.hoverElement,Gt.Hover,!0),!(this.tool instanceof Oh||this.tool instanceof kh)||2!==t.button&&2!==t.buttons)if(!0===this.inAction&&!0===this.isMouseDown&&(this.tool instanceof Oh||this.tool instanceof kh))this.isMouseDown=!0,this.eventArgs={},this.getMouseEventArgs(this.currentPosition,this.eventArgs),this.eventArgs.position=this.currentPosition,this.tool.mouseDown(this.eventArgs);else{this.isMouseDown=!0,this.currentPosition=this.prevPosition=this.getMousePosition(t),this.eventArgs={},this.diagram.textEditing&&!this.isMouseOnScrollBar(t)&&(this.diagram.endEdit(),this.diagram.textEditing=!1,"Canvas"===this.diagram.mode&&1!==this.diagram.scroller.currentZoom&&this.diagram.refreshDiagramLayer());var s=this.getTargetElement();this.action=this.diagram.findActionToBeDone(s.obj,s.sourceElement,this.currentPosition,s.target);var o=this.isMetaKey(t);o&&t.shiftKey&&this.diagram.connectorEditingToolModule?this.action="SegmentEnd":(o||t.shiftKey)&&(_v(this.diagram)||Uv(this.diagram))&&(this.action="Select"),this.tool=this.diagram.getTool(this.action),this.tool||(this.action="Select",this.tool=this.diagram.getTool(this.action)),this.getMouseEventArgs(this.currentPosition,this.eventArgs),(o||t.shiftKey)&&(this.eventArgs.info=o&&t.shiftKey?{ctrlKey:o,shiftKey:t.shiftKey}:{ctrlKey:!0}),this.eventArgs.position=this.currentPosition;var l=this.diagram.selectedItems.nodes;if(this.tool.mouseDown(this.eventArgs),this.diagram.selectedItems.canToggleSelection&&l&&this.diagram.selectedItems.nodes&&this.tool instanceof ua)for(var h=0;h=2&&(this.touchStartList=HF(this.touchStartList,0,e)),e||t.preventDefault())}else this.inAction=!1,this.tool.mouseUp(this.eventArgs);!this.isForeignObject(t.target)&&!this.isForeignObject(t.target,!0)&&!e&&t.preventDefault()}},n.prototype.mouseMoveExtend=function(t,e){(this.tool instanceof Oh||this.tool instanceof kh)&&this.tool.mouseMove(this.eventArgs),this.diagram.scrollSettings.canAutoScroll?this.checkAutoScroll(t):this.blocked||this.tool.mouseMove(this.eventArgs),this.eventArgs.target&&(this.hoverElement=this.eventArgs.target);var i=!((this.eventArgs.target instanceof te||this.eventArgs.target instanceof de)&&(e instanceof te||e instanceof de));this.tool instanceof Od&&this.diagram.updatePortVisibility(this.hoverElement instanceof te||this.hoverElement instanceof de?this.hoverElement:this.hoverNode,Gt.Connect|Gt.Hover,i),this.hoverElement instanceof te&&this.hoverNode instanceof te&&this.hoverNode&&this.hoverNode.id!==this.hoverElement.id&&this.diagram.updatePortVisibility(this.hoverNode,Gt.Connect|Gt.Hover,!0),this.hoverElement instanceof de&&this.hoverElement.ports.length>0&&this.diagram.updatePortVisibility(this.hoverElement,Gt.Connect|Gt.Hover,!0),this.previousElement instanceof te&&this.hoverElement&&this.previousElement.id!==this.hoverElement.id&&this.diagram.updatePortVisibility(this.previousElement,Gt.Connect|Gt.Hover,!0),this.previousElement=this.hoverElement,""!==this.diagram.tooltip.content&&(this.hoverElement=null),this.hoverNode=i?null:e},n.prototype.checkAction=function(t){if("LabelSelect"===this.action&&this.eventArgs.sourceWrapper&&(this.eventArgs.sourceWrapper instanceof si||this.eventArgs.sourceWrapper instanceof Jn)){var e=this.commandHandler.findTarget(this.eventArgs.sourceWrapper,this.eventArgs.source);!_r(this.diagram,e,!1,this.eventArgs.sourceWrapper)&&to(e)&&(this.action="LabelDrag",this.tool=this.getTool(this.action),this.tool.mouseDown(this.initialEventArgs))}else to(t)&&Dd(t)&&this.initialEventArgs&&this.initialEventArgs.source&&"Select"===this.action&&(!_r(this.diagram,this.eventArgs.source,!1)&&this.eventArgs.source instanceof oi&&this.getMouseEventArgs(this.currentPosition,this.eventArgs),(!(t instanceof de)||t instanceof de&&!(wr(this.currentPosition,t.sourcePoint,t.hitPadding)||wr(this.currentPosition,t.targetPoint,t.hitPadding)))&&(this.action="Drag"),this.tool=this.getTool(this.action),this.tool.mouseDown(this.initialEventArgs))},n.prototype.isSwimlaneElements=function(t){return!(t&&(t.isLane||t.isPhase||t.isHeader))},n.prototype.mouseMove=function(t,e){if(this.focus=!0,this.isScrolling)t.preventDefault();else if(jv(this.diagram)||Lc(this.diagram)&&!PI(this.diagram)){this.currentPosition=this.getMousePosition(t);var i=this.diagram.findObjectsUnderMouse(this.currentPosition),r=this.diagram.findObjectUnderMouse(i,this.action,this.inAction);!function Gne(n,t){n.rulerSettings.showRulers&&(n.hRuler.drawRulerMarker(n.hRuler.element,t,n.scroller.horizontalOffset),n.vRuler.drawRulerMarker(n.vRuler.element,t,n.scroller.verticalOffset))}(this.diagram,this.currentPosition);var s=!1,o=void 0;if("touchmove"===t.type&&(e=t.touches)&&e.length>1&&(this.touchMoveList=HF(this.touchMoveList,0,e),"PinchZoom"!==this.action&&(s=!0)),!1===z.equals(this.currentPosition,this.prevPosition)||this.inAction){if(!1===this.isMouseDown||s){this.eventArgs={};var a=null,l=void 0;if(null!==r){if((a=this.diagram.findElementUnderMouse(r,this.currentPosition,this.diagram))&&(l=this.commandHandler.findTarget(a,r)),(l instanceof Zn||l instanceof Nr)&&(l.tooltip&&""!==l.tooltip.content||(l=r)),l!==this.hoverElement){var h=this.getContent();this.hoverElement&&"Auto"===this.hoverElement.tooltip.openOn&&""!==h&&this.elementLeave(),this.diagram.updatePortVisibility(this.hoverElement,Gt.Hover,!0),r instanceof te&&(this.hoverNode=r);var c=!0;!this.isSwimlaneElements(r)&&this.hoverElement&&this.isSwimlaneElements(this.hoverElement)&&(c=!1),this.hoverElement=c?r:this.hoverElement;var d,u=void 0;(d=this.diagram.findElementUnderMouse(r,this.currentPosition,this.diagram))instanceof Ke&&((u=this.commandHandler.findTarget(d,r))instanceof Es||u instanceof xc)&&this.hoverElement.constraints&ni.ToolTip&&(this.hoverElement=u);var p=void 0;d instanceof si&&((p=this.commandHandler.findTarget(d,r))instanceof Zn||p instanceof Nr)&&p.constraints&Lr.Tooltip&&(this.hoverElement=p),c?this.elementEnter(this.currentPosition,!1):this.hoverElement=r}else this.hoverElement&&this.hoverElement===l&&this.hoverElement.tooltip.content&&void 0!==this.diagram.tooltipObject&&"Mouse"===this.hoverElement.tooltip.relativeMode&&this.setTooltipOffset(this.currentPosition);a&&(o=this.commandHandler.findTarget(a,r))}this.action=this.diagram.findActionToBeDone(r,a,this.currentPosition,o),this.checkFixedUserHandleEvent(Ce.onFixedUserHandleMouseEnter,r,a),this.checkUserHandleEvent(Ce.onUserHandleMouseEnter),this.checkPreviousAction(),this.getMouseEventArgs(this.currentPosition,this.eventArgs),this.tool=this.getTool(this.action),this.mouseEvents(),this.tool instanceof pa||this.tool instanceof kh||this.tool instanceof Oh?this.tool.mouseMove(this.eventArgs):e&&this.tool instanceof Jv&&this.tool.mouseDown(this.eventArgs),this.updateCursor(),this.renderUmlHighLighter(this.eventArgs);var f=!1;this.hoverElement&&!(this.tool instanceof Jv)&&r instanceof te&&this.isSwimlaneElements(r)&&(0===this.diagram.selectedItems.nodes.length||!_r(this.diagram,this.hoverElement))||this.hoverElement instanceof de||(f=!0),this.hoverElement&&!(this.tool instanceof Jv)&&r instanceof de&&(0===this.diagram.selectedItems.connectors.length||!_r(this.diagram,this.hoverElement))||this.hoverElement instanceof te||(f=!0),this.diagram.updatePortVisibility(this.hoverElement,Gt.Hover,f);var g=this.getContent();null===r&&this.hoverElement&&"Auto"===this.hoverElement.tooltip.openOn&&g&&(this.hoverElement=null,this.elementLeave()),s=!1}else{this.eventArgs.position=this.currentPosition,"Drag"===this.action&&!_r(this.diagram,this.eventArgs.source,!1)&&this.eventArgs.source instanceof oi&&this.getMouseEventArgs(this.currentPosition,this.eventArgs),this.mouseEvents(),(t.ctrlKey||t.shiftKey)&&(this.eventArgs.info=t.ctrlKey&&t.shiftKey?{ctrlKey:t.ctrlKey,shiftKey:t.shiftKey}:{ctrlKey:!0}),this.checkAction(r);var y=this.getConnectorPadding(this.eventArgs);this.getMouseEventArgs(this.currentPosition,this.eventArgs,this.eventArgs.source,y),this.updateCursor(),this.inAction=!0,this.initialEventArgs=null,("Drag"===this.action||"Rotate"===this.action)&&(this.diagram.diagramActions=this.diagram.diagramActions|ee.Interactions);var S=this.diagram.scroller.getPageBounds();this.mouseMoveExtend(t,r);var b=this.diagram.scroller.getPageBounds();if(r&&(S.width!==b.width||S.height!==b.height||S.x!==b.x||S.y!==b.y)&&this.diagram.views&&this.diagram.views.overview){var M=this.diagram.views.overview;M.updateView(M)}}this.prevPosition=this.currentPosition,this.isForeignObject(t.target,!0)||t.preventDefault()}}},n.prototype.getContent=function(){var i,t=this.hoverElement instanceof te&&this.hoverElement.constraints&ie.Tooltip||this.hoverElement instanceof de&&this.hoverElement.constraints&qe.Tooltip||(this.hoverElement instanceof Es||this.hoverElement instanceof xc)&&this.hoverElement.constraints&ni.ToolTip||(this.hoverElement instanceof Zn||this.hoverElement instanceof Nr)&&this.hoverElement.constraints&Lr.Tooltip,e=this.hoverElement;e instanceof te&&e.children&&e.children.length>0&&(i=this.findIntersectChild(e));var r=t?this.hoverElement.tooltip.content:this.diagram.tooltip.content;return i?i.tooltip.content:r},n.prototype.findIntersectChild=function(t){for(var e,i=new Ne(this.currentPosition.x,this.currentPosition.y,8,8),r=0;r1&&1===t.which&&!function qre(n){return!!(n&ee.PreventClearSelection)}(this.diagram.diagramActions)&&(c=!1,this.commandHandler.clearSelection()),(!_r(this.diagram,h)||!c)&&(this.commandHandler.selectObjects([h],void 0,a),this.diagram.selectedItems.canToggleSelection)){var d=this.diagram.selectedItems.nodes;d?d[0].parentObj instanceof Rd&&(s=!0):this.diagram.selectedItems.connectors.length>0&&(s=!0)}}var u=!1,p=this.updateContainerProperties(),f=void 0;if(this.addUmlNode(),this.inAction=!1,this.isMouseDown=!1,this.diagram.selectedObject.helperObject&&(f=this.updateContainerBounds()),this.tool&&(this.tool.prevPosition||this.tool instanceof X3)){this.eventArgs.position=this.currentPosition;var g=this.getConnectorPadding(this.eventArgs);this.getMouseEventArgs(this.currentPosition,this.eventArgs,this.eventArgs.source,g);var v=this.isMetaKey(t);if((v||t.shiftKey)&&(this.eventArgs.info=v&&t.shiftKey?{ctrlKey:v,shiftKey:t.shiftKey}:{ctrlKey:!0}),this.diagram.diagramActions&ee.Interactions&&(this.diagram.diagramActions=this.diagram.diagramActions&~ee.Interactions),this.eventArgs.clickCount=t.detail,this.diagram.selectedObject.helperObject&&(this.tool instanceof ua||this.tool instanceof kd)){if(this.diagram.selectedObject.actualObject&&""!==this.diagram.selectedObject.actualObject.parentId){var S=this.diagram.getObject(this.diagram.selectedObject.actualObject.parentId);S&&S.isLane&&(this.commandHandler.isContainer=!0)}(u=this.diagram.lineRoutingModule&&this.diagram.nameTable.helper&&this.eventArgs.target&&this.eventArgs.target.isLane&&(this.eventArgs.source instanceof oi&&this.eventArgs.source.nodes.length>0&&""===this.eventArgs.source.nodes[0].parentId||""===this.eventArgs.source.parentId))&&(this.diagram.diagramActions=this.diagram.diagramActions|ee.PreventLaneContainerUpdate),this.tool.mouseUp(this.eventArgs,p.isPreventHistory)}else{if(this.diagram.selectedItems.canToggleSelection){var b=void 0,M=void 0;if(this.diagram.selectedItems.nodes.length>0)for(var w=0;w1&&D[0].id===i[parseInt(w.toString(),10)].id||r.length>0)&&(M=!0);!this.isSwimlaneSelected&&!s&&!M&&this.tool instanceof ua&&"Select"===this.currentAction&&(!b||this.diagram.selectedItems.connectors.length>0)&&this.commandHandler.clearSelection(!0)}this.isSwimlaneSelected=!1,this.tool.mouseUp(this.eventArgs),this.diagram.checkMenu&&(-1!==window.navigator.userAgent.indexOf("Linux")||-1!==window.navigator.userAgent.indexOf("X11"))&&(!t.pageY&&t instanceof TouchEvent&&t.changedTouches?(window.getSelection().removeAllRanges(),this.diagram.contextMenuModule.contextMenu.open(t.changedTouches[0].pageY,t.changedTouches[0].pageX,this.diagram.element),t.preventDefault()):this.diagram.contextMenuModule.contextMenu.open(t.pageY,t.pageX,this.diagram.element),this.diagram.checkMenu=!1)}p.hasStack&&this.diagram.endGroupAction()}if(f&&this.diagram.endGroupAction(),this.updateContainerBounds(!0),2!==this.eventArgs.clickCount&&(this.commandHandler.updateSelectedNodeProperties(this.eventArgs.source),u)){this.diagram.diagramActions=this.diagram.diagramActions&~ee.PreventLaneContainerUpdate;var A=this.eventArgs.source instanceof oi?this.eventArgs.source.nodes:[this.eventArgs.source];if(A)for(w=0;w0&&!N&&this.diagram.renderSelector(!0),!this.inAction&&!this.diagram.currentSymbol&&this.eventArgs){var T=this.getTargetElement();this.diagram.tool!==Ci.ZoomPan&&this.diagram.triggerEvent(Ce.click,{element:T.target instanceof Es?T.target:this.eventArgs.source||this.diagram,position:this.eventArgs.position,count:t.detail,actualObject:this.eventArgs.actualObject,button:0===t.button?"Left":1===t.button?"Middle":"Right"})}this.eventArgs={}}this.diagram.diagramActions=this.diagram.diagramActions&~ee.PreventLaneContainerUpdate,e&&this.updateAnnotation(this.diagram.selectedItems),this.eventArgs={},this.diagram.commandHandler.removeStackHighlighter()},n.prototype.isSwimlaneChild=function(t){if(t.shape&&"SwimLane"!==t.shape.type){var e=this.diagram.nameTable[t.parentId];if(!e)return!1;var i=e.parentId?this.diagram.nameTable[e.parentId]:e;return i&&i.shape&&"SwimLane"===i.shape.type}return!1},n.prototype.updateAnnotation=function(t){var e=t.nodes;if(e.length>0)for(var i=0;i0&&(a+=1),h.isPhase){l="Horizontal"===r.orientation?this.currentPosition.x-e.wrapper.bounds.x:this.currentPosition.y-(e.wrapper.bounds.y+r.header.height);var g={id:Qe(),offset:l,header:{annotation:{content:void 0===h.phases[0].header?"Phase":h.phases[0].header.annotation.content,style:void 0===h.phases[0].header?{}:h.phases[0].header.annotation.style}},style:void 0===h.phases[0]?{}:h.phases[0].style};this.diagram.addPhases(e,[g])}else{var v={id:Qe(),style:h.lanes[0].style,header:{annotation:{content:h.lanes[0].header.annotation.content,style:h.lanes[0].header.annotation.style},style:h.lanes[0].header.style}};if("Horizontal"===h.orientation?v.height=h.lanes[0].height:v.width=h.lanes[0].width,"Horizontal"===r.orientation?(s=i.rowIndex?i.rowIndex:this.diagram.nameTable[i.parentId].rowIndex,i.wrapper.offsetYs)v.header.width=r.lanes[parseInt(s.toString(),10)].header.width,v.header.height=r.lanes[parseInt(s.toString(),10)].header.height;else{var S=void 0;S="Horizontal"===r.orientation?i.rowIndex<3?0:s-a-1:s-1,v.header.width=r.lanes[parseInt(S.toString(),10)].header.width,v.header.height=r.lanes[parseInt(S.toString(),10)].header.height}f&&("height"===f?(v.width=v.height,delete v.height):(v.height=v.width,delete v.width)),this.diagram.addLanes(e,[v],"Horizontal"===r.orientation?s-a:s)}this.commandHandler.select(e)}else if(h.isLane){var b={id:Qe(),width:t.width,height:t.height,addInfo:t.addInfo,shape:{type:"SwimLane",header:{annotation:{content:void 0===h.header?"Header":h.header.annotation.content,style:void 0===h.header?{}:h.header.annotation.style},height:50,style:h.header?h.header.style:h.lanes[0].header.style},phases:[{id:Qe(),header:{annotation:{content:void 0===h.phases||void 0===h.phases[0].header?"Phase":h.phases[0].header.annotation.content,style:void 0===h.phases||void 0===h.phases[0].header?{}:h.phases[0].header.annotation.style},style:void 0===h.phases||void 0===h.phases[0].header?{}:h.phases[0].header.style},style:void 0===h.phases?{}:h.phases[0].style}],lanes:[{id:Qe(),height:t.height,width:t.width,style:h.lanes[0].style,header:{annotation:{content:h.lanes[0].header.annotation.content,style:h.lanes[0].header.annotation.style},style:h.lanes[0].header.style}}],orientation:h.orientation}};"Vertical"===h.orientation&&(b.width+=20),b.offsetX=this.currentPosition.x+b.width/2,b.offsetY=this.currentPosition.y+b.height/2,b.style=t.style,this.diagram.add(b)}},n.prototype.mouseLeave=function(t){this.tool&&this.inAction&&this.tool.mouseLeave(this.eventArgs),this.diagram.selectedObject.helperObject&&(this.updateContainerProperties(),this.updateContainerBounds()&&this.diagram.endGroupAction()),this.eventArgs&&this.eventArgs.source&&(this.diagram.updatePortVisibility(this.eventArgs.source,Gt.Hover,!0),this.hoverElement=null),this.eventArgs&&!this.eventArgs.source&&this.hoverElement&&(this.hoverElement=null),this.tool instanceof Od&&this.eventArgs&&this.eventArgs.target&&this.eventArgs.target instanceof te&&(this.diagram.updatePortVisibility(this.eventArgs.target,Gt.Hover|Gt.Connect,!0),this.hoverElement=null);var i=this.diagram.selectedItems;i&&i.wrapper&&(om(this.diagram,i)||this.diagram.renderSelector(!0)),(this.diagram.diagramActions&ee.Interactions||this.diagram.diagramActions&ee.ToolAction)&&(this.diagram.diagramActions=this.diagram.diagramActions&~ee.ToolAction),this.isMouseDown=!1,this.focus=!1,this.touchStartList=null,this.touchMoveList=null,this.elementLeave(),this.commandHandler.removeSnap(),this.inAction=!1,this.eventArgs={},this.diagram.selectedObject&&this.diagram.selectedObject.helperObject&&(this.diagram.remove(this.diagram.selectedObject.helperObject),this.diagram.selectedObject={helperObject:void 0,actualObject:void 0}),this.tool=null,function Qne(){var t,e,n=document.getElementsByClassName("e-d-ruler-marker");if(n&&n.length>0)for(e=n.length-1;e>=0;e--)(t=n[parseInt(e.toString(),10)])&&t.parentNode.removeChild(t)}(),"Rotate"===this.action&&this.diagram.diagramCanvas.classList.remove("e-diagram-rotate"),t.preventDefault()},n.prototype.mouseWheel=function(t){this.diagram.blazorActions|=on.interaction;var e={event:t,cancel:!1};if(this.diagram.triggerEvent(Ce.mouseWheel,e),!e.cancel){var i=t.wheelDelta>0||-40*t.detail>0,r=this.getMousePosition(t);if(this.diagram.tooltipObject.close(),this.isMetaKey(t)){var o=this.diagram.scrollSettings.zoomFactor;this.diagram.zoomTo(i?{type:"ZoomIn",zoomFactor:o,focusPoint:r}:{type:"ZoomOut",zoomFactor:o,focusPoint:r}),t.preventDefault()}else{var a=this.diagram.scroller.horizontalOffset,l=this.diagram.scroller.verticalOffset,h=i?10:-10;this.tool&&(this.tool instanceof Oh||this.tool instanceof kh)&&(this.eventArgs={},this.getMouseEventArgs(r,this.eventArgs),this.eventArgs.position=r,this.tool.mouseWheel(this.eventArgs)),this.diagram.scrollActions|=ca.Interaction;var c=!0;if(t.isTrusted){var d=!1;(Math.abs(t.deltaY)<100&&-0===Math.abs(t.deltaX)||Math.abs(t.deltaX)<100&&-0===Math.abs(t.deltaY))&&(d=!0);var u=!1;(0!==t.deltaX||0!==t.deltaY)&&(u=navigator.userAgent.includes("Macintosh")),u?Math.abs(t.deltaX)>Math.abs(t.deltaY)?(t.shiftKey||t.deltaX&&-0!==t.deltaX&&(d||!u))&&this.diagram.scroller.zoom(1,h,0,r,c,void 0,d):t.deltaY&&-0!==t.deltaY&&(d||!u)&&this.diagram.scroller.zoom(1,0,h,r,c,void 0,d):t.shiftKey||t.deltaX&&-0!==t.deltaX&&(d||!u)?this.diagram.scroller.zoom(1,h,0,r,c,void 0,d):t.deltaY&&-0!==t.deltaY&&(d||!u)&&this.diagram.scroller.zoom(1,0,h,r,c,void 0,d)}else t.shiftKey||t.deltaX&&-0!==t.deltaX?this.diagram.scroller.zoom(1,h,0,r,c):this.diagram.scroller.zoom(1,0,h,r,c);this.diagram.scrollActions&=~ca.Interaction,(a!==this.diagram.scroller.horizontalOffset||l!==this.diagram.scroller.verticalOffset)&&t.preventDefault()}if(this.diagram.textEditing){if(this.diagram.isTriggerEvent=!0,this.diagram.activeLabel.parentId){var f=this.diagram.getObject(this.diagram.activeLabel.parentId);this.diagram.startTextEdit(f,this.diagram.activeLabel.id)}this.diagram.isTriggerEvent=!1}this.diagram.blazorActions=this.diagram.blazorActions&~on.interaction}},n.prototype.keyDown=function(t){if(t.fromMouseEvents&&(t.ctrlKey&&(this.keyArgs.keyModifiers=1),t.shiftKey&&(this.keyArgs.keyModifiers=4),t.shiftKey&&t.ctrlKey&&(this.keyArgs.keyModifiers=5)),!(this.diagram.diagramActions&ee.TextEdit)&&!this.checkEditBoxAsTarget(t)||"Escape"===t.key||27===t.keyCode){var i=void 0,r=t.keyCode?t.keyCode:t.which,s=t.key;("ArrowDown"===s||"ArrowUp"===s||"ArrowLeft"===s||"ArrowRight"===s)&&(this.isNudgeKey=!0);var o=this.isMetaKey(t);if(this.diagram.commandManager&&this.diagram.commands)for(var l=0,h=Object.keys(this.diagram.commands);l4&&(S({keyDownEventArgs:KeyboardEvent,parameter:i.parameter,type:"KEYDOWN"}),this.keyCount=0)),this.isKeyUp=!1):S({keyDownEventArgs:KeyboardEvent,parameter:i.parameter})}break}}}}this.keyArgs={element:this.diagram.selectedItems,key:t.key,keyCode:t.keyCode?t.keyCode:t.which},this.getKeyModifier(this.keyArgs,t),this.diagram.diagramActions&ee.TextEdit&&this.getlabel(this.keyArgs,t),this.diagram.triggerEvent(Ce.keyDown,this.keyArgs)},n.prototype.getlabel=function(t,e){var i=this.diagram.activeLabel;t.target=this.diagram.element.id+"_editBox";var r=this.diagram.nameTable[i.parentId];if(document.getElementById(this.diagram.element.id+"_editBox")){t.text=document.getElementById(this.diagram.element.id+"_editBox").value;for(var s=0;s=this.diagram.scroller.viewPortWidth-18?r="right":e.x+this.diagram.scroller.horizontalOffsetthis.diagram.scroller.viewPortHeight-18?r="bottom":e.y+this.diagram.scroller.verticalOffset0&&(s=this.findIntersectChild(this.hoverElement)),"Auto"===this.hoverElement.tooltip.openOn&&""!==r&&Mx(this.diagram,s||(i?this.hoverElement:void 0)),this.hoverElement.tooltip.content&&("Mouse"===this.hoverElement.tooltip.relativeMode?this.setTooltipOffset(t):(this.diagram.tooltipObject.offsetX=0,this.diagram.tooltipObject.offsetY=0));var o=this.diagram.findObjectsUnderMouse(this.currentPosition),a=this.diagram.findObjectUnderMouse(o,this.action,this.inAction);if(null!==a){var l=void 0;this.hoverElement.tooltip.isSticky&&(this.diagram.tooltipObject.isSticky=!0),a instanceof te&&a.children&&a.children.length>0&&(a=s||a),l=a.ports&&(this.hoverElement instanceof Es||this.hoverElement instanceof xc)||a.annotations&&(this.hoverElement instanceof Zn||this.hoverElement instanceof Nr)?document.getElementById(a.id+"_"+this.hoverElement.id):document.getElementById(a.id+(a.shape&&a.shape instanceof am?"_content_native_element":"_groupElement")),"Auto"===this.hoverElement.tooltip.openOn&&""!==r&&(this.diagram.tooltipObject.close(),this.diagram.tooltipObject.openOn=this.hoverElement.tooltip.openOn,this.diagram.tooltipObject.dataBind()),function jre(n,t){var e=0;return n instanceof de?n.constraints&qe.Tooltip?e=n.constraints&qe.Tooltip:n.constraints&qe.InheritTooltip&&(e=t.constraints&rt.Tooltip):n instanceof Es||n instanceof xc?n.constraints&ni.ToolTip?e=n.constraints&ni.ToolTip:n.constraints&ni.InheritTooltip&&(e=t.constraints&rt.Tooltip):n instanceof Zn||n instanceof Nr?n.constraints&Lr.Tooltip&&(e=n.constraints&Lr.Tooltip):n.constraints&ie.Tooltip?e=n.constraints&ie.Tooltip:n.constraints&ie.InheritTooltip&&(e=t.constraints&rt.Tooltip),e}(this.hoverElement,this.diagram)&&"Auto"===this.hoverElement.tooltip.openOn&&(this.diagram.tooltipObject.target=this.hoverElement.id,this.diagram.tooltipObject.open("Mouse"===this.hoverElement.tooltip.relativeMode?this.diagram.element:l))}}},n.prototype.elementLeave=function(){this.diagram.tooltipObject&&!this.diagram.tooltipObject.isSticky&&"Custom"!==this.diagram.tooltipObject.openOn&&this.diagram.tooltipObject.close()},n.prototype.setTooltipOffset=function(t){var e=function dse(n,t,e,i){var o="Mouse"===(!(e instanceof te?e.constraints&ie.InheritTooltip:e instanceof de?e.constraints&qe.InheritTooltip:e.constraints&ni.InheritTooltip)&&(e instanceof te?e.constraints&ie.Tooltip:e instanceof de?e.constraints&qe.Tooltip:e.constraints&ni.ToolTip)?e.tooltip.relativeMode:n.tooltip.relativeMode);"Mouse"===i?o=!0:"Object"===i&&(o=!1);var a=function use(n,t,e,i){var o,r={},s=document.getElementById(e.element.id);if(n instanceof te||n instanceof de)o=n.wrapper.bounds;else{var a=e.findObjectsUnderMouse(t),l=e.findObjectUnderMouse(a,"Select",!1);o=e.findElementUnderMouse(l,t,e).bounds}var c=s.getBoundingClientRect();switch(e.tooltipObject.position){case"BottomCenter":r=zc(t,o.bottomCenter,e,i,c.width/2,c.height);break;case"BottomLeft":case"LeftBottom":r=zc(t,o.bottomLeft,e,i,0,c.height);break;case"BottomRight":case"RightBottom":r=zc(t,o.bottomRight,e,i,c.width,c.height);break;case"LeftCenter":r=zc(t,o.middleLeft,e,i,0,c.height/2);break;case"LeftTop":case"TopLeft":r=zc(t,o.topLeft,e,i,0,0);break;case"RightCenter":r=zc(t,o.middleRight,e,i,c.width,c.height/2);break;case"RightTop":case"TopRight":r=zc(t,o.topRight,e,i,c.width,0);break;case"TopCenter":r=zc(t,o.topCenter,e,i,c.width/2,0)}return r}(e,t,n,o),l=qa(n);return{x:a.x+l.width,y:a.y+l.height}}(this.diagram,t,this.hoverElement);this.diagram.tooltipObject.offsetX=e.x,this.diagram.tooltipObject.offsetY=e.y},n.prototype.altKeyPressed=function(t){return!!(t&pt.Alt)},n.prototype.ctrlKeyPressed=function(t){return!!(t&pt.Control)},n.prototype.shiftKeyPressed=function(t){return!!(t&pt.Shift)},n.prototype.scrolled=function(t){this.diagram.updateScrollOffset()},n.prototype.doubleClick=function(t){if(jv(this.diagram)){var e=void 0,i=this.diagram.findObjectsUnderMouse(this.currentPosition),r=this.diagram.findObjectUnderMouse(i,this.action,this.inAction);if(null!==r&&jv(this.diagram))if(e=this.diagram.findElementUnderMouse(r,this.currentPosition,this.diagram),this.tool&&(this.tool instanceof Oh||this.tool instanceof kh))this.tool.mouseUp(this.eventArgs),this.isMouseDown=!1,this.eventArgs={},this.tool=null,t.preventDefault();else{var o=this.diagram.commandHandler.getObjectLayer(r.id);!o||o.lock||!o.visible||this.diagram.diagramActions&ee.TextEdit||this.diagram.startTextEdit(r,e instanceof si?e.id.split(r.id+"_")[1]:void 0)}this.diagram.triggerEvent(Ce.doubleClick,{source:r||this.diagram,position:this.currentPosition,count:t.detail})}},n.prototype.itemClick=function(t,e){var i=t;return cs(this.diagram,i,!0)?i:null},n.prototype.inputChange=function(t){var i,s,o,a,l,h,c,d,u,p=document.getElementById(this.diagram.element.id+"_editBox"),f=document.getElementById(this.diagram.element.id+"_editTextBoxDiv"),g=p.value,v=g.split("\n");(!(a=this.diagram.selectedItems.nodes[0]?this.diagram.selectedItems.nodes[0]:this.diagram.selectedItems.connectors[0])&&this.tool instanceof WI||a&&"SwimLane"===a.shape.type)&&(a=this.diagram.nameTable[this.diagram.activeLabel.parentId]),a&&("Text"!==a.shape.type&&a.annotations.length>0||"Text"===a.shape.type)&&(c=NF((o=this.diagram.getWrapper(a.wrapper,this.diagram.activeLabel.id)).style,g,void 0,void 0,i=(i=a.wrapper.bounds.width90?i:90),s=Number(p.style.fontSize.split("px")[0]),v.length>1&&""===v[v.length-1]&&(c.height=c.height+s),d=this.diagram.scroller.transform,u=T3(this.diagram)?d.scale:1,l=(12>c.height?12:c.height)*u,f.style.left=(o.bounds.center.x+d.tx)*d.scale-(h=(90>(h=c.width)?90:h)*u)/2-2.5+"px",f.style.top=(o.bounds.center.y+d.ty)*d.scale-l/2-3+"px",f.style.width=h+"px",f.style.height=l+"px",p.style.minHeight="12px",p.style.minWidth="90px",p.style.width=h+"px",p.style.height=l+"px")},n.prototype.isAddTextNode=function(t,e){return!(!(this.tool instanceof WI||e)||(this.tool=null,t&&!kI(this.diagram)&&(this.diagram.drawingObject=void 0,this.diagram.currentDrawingObject=void 0),vF(this.diagram.nodes,t.id)||vF(this.diagram.connectors,t.id)))},n.prototype.checkEditBoxAsTarget=function(t){return!(!t.target||t.target.id!==this.diagram.element.id+"_editBox")},n.prototype.getMouseEventArgs=function(t,e,i,r){var s,o,a;if(e.position=t,i?(o=this.diagram.findObjectsUnderMouse(this.currentPosition,i),s=this.diagram.findTargetObjectUnderMouse(o,this.action,this.inAction,e.position,i)):"Drag"===this.action||"ConnectorSourceEnd"===this.action||"SegmentEnd"===this.action||"OrthoThumb"===this.action||"BezierSourceThumb"===this.action||"BezierTargetThumb"===this.action||"ConnectorTargetEnd"===this.action||-1!==this.action.indexOf("Rotate")||-1!==this.action.indexOf("Resize")?(s=this.diagram.selectedItems,!this.diagram.currentSymbol&&"Drag"===this.action&&s&&this.diagram.selectedItems.nodes.length>0&&"SwimLane"===this.diagram.selectedItems.nodes[0].shape.type&&(o=this.diagram.findObjectsUnderMouse(this.currentPosition),s=this.diagram.findObjectUnderMouse(o,this.action,this.inAction))):(o=this.diagram.findObjectsUnderMouse(this.currentPosition),s=this.diagram.findObjectUnderMouse(o,this.action,this.inAction)),s&&s.isHeader&&(this.eventArgs.actualObject=s=this.diagram.nameTable[s.parentId]),s){var l=void 0,h=void 0,c=void 0;if(((a=this.diagram.findElementUnderMouse(s,this.currentPosition,this.diagram,r))&&s.ports&&s.ports.length&&!ib(s,a)||!a||!s)&&o&&o.length&&i instanceof oi)for(l=i.connectors[0],c=o.length-1;c>=0;c--)if(((h=o[parseInt(c.toString(),10)])instanceof te||h instanceof de)&&l&&l.connectionPadding){if(a=this.diagram.findElementUnderMouse(s=h,this.currentPosition,this.diagram,r),l.constraints&qe.ConnectToNearByPort&&s&&s.ports&&s.ports.length&&ib(s,a))break;if((h instanceof te||h instanceof de)&&l&&l.connectionPadding&&h.wrapper.outerBounds.containsPoint(this.currentPosition)&&l.constraints&qe.ConnectToNearByNode&&!(l.constraints&qe.ConnectToNearByPort)){a=this.diagram.findElementUnderMouse(s=h,this.currentPosition,this.diagram,0);break}}}return i?(e.target=s,e.targetWrapper=a):(e.source=s,e.sourceWrapper=a),e.actualObject=this.eventArgs.actualObject,e.source instanceof oi&&void 0===e.actualObject&&(e.source.nodes.length>0||e.source.connectors.length>0)&&(e.actualObject=e.source.nodes.length>0?this.diagram.nameTable[e.source.nodes[0].id]:this.diagram.nameTable[e.source.connectors[0].id]),e.startTouches=this.touchStartList,e.moveTouches=this.touchMoveList,e},n.prototype.resetTool=function(){this.action="Select",this.hoverElement=null,this.hoverNode=null,this.tool=this.diagram.getTool(this.action),this.updateCursor()},n.prototype.updateTool=function(){this.eventArgs&&!this.eventArgs.position&&(this.action="Select")},n.prototype.getTool=function(t){switch(t){case"Select":return new Zv(this.commandHandler,!0);case"Drag":return new ua(this.commandHandler);case"Rotate":return new Yx(this.commandHandler);case"LayoutAnimation":return new Lne(this.commandHandler);case"FixedUserHandle":return new Ane(this.commandHandler,!0);case"Hyperlink":return new X3(this.commandHandler);case"ResizeSouthEast":case"ResizeSouthWest":case"ResizeNorthEast":case"ResizeNorthWest":case"ResizeSouth":case"ResizeNorth":case"ResizeWest":case"ResizeEast":return new kd(this.commandHandler,t);case"ConnectorSourceEnd":case"ConnectorTargetEnd":case"BezierSourceThumb":case"BezierTargetThumb":return new Od(this.commandHandler,t);case"SegmentEnd":case"OrthoThumb":return new ZF(this.commandHandler,t);case"Draw":var e="shape",i=function nse(n){var t;return n&&(n.type?t="Connector":n.shape&&!n.type&&(t="Node")),t}(this.diagram.drawingObject);if("Node"===i&&"Text"===this.diagram.drawingObject.shape.type)return new WI(this.commandHandler);if("Connector"===i&&"Freehand"===this.diagram.drawingObject.type)return new Pne(this.commandHandler);if("Node"===i&&"Polygon"===this.diagram.drawingObject.shape[""+e]&&!this.diagram.drawingObject.shape.points)return new Oh(this.commandHandler);if("Node"===i||"Node"===i&&"Polygon"===this.diagram.drawingObject.shape[""+e]&&this.diagram.drawingObject.shape.points)return new VI(this.commandHandler,this.diagram.drawingObject);if("Connector"===i&&"Polyline"===this.diagram.drawingObject.type)return new kh(this.commandHandler);if("Connector"===i)return new pa(this.commandHandler,"ConnectorSourceEnd",this.diagram.drawingObject);break;case"Pan":return new Jv(this.commandHandler,!1);case"PinchZoom":return new Jv(this.commandHandler,!0);case"PortDrag":return new ua(this.commandHandler,"Port");case"PortDraw":return new pa(this.commandHandler,"ConnectorSourceEnd",this.diagram.drawingObject);case"LabelSelect":return new Zv(this.commandHandler,!0,"LabelSelect");case"LabelDrag":return new Nne(this.commandHandler);case"LabelResizeSouthEast":case"LabelResizeSouthWest":case"LabelResizeNorthEast":case"LabelResizeNorthWest":case"LabelResizeSouth":case"LabelResizeNorth":case"LabelResizeWest":case"LabelResizeEast":return new One(this.commandHandler,t);case"LabelRotate":return new kne(this.commandHandler)}return null},n.prototype.getCursor=function(t){var e=this.diagram.selectedItems.annotation?this.diagram.selectedItems.wrapper.children[0]:this.diagram.selectedItems;return function Tne(n,t){if(t+=360,t%=360,-1===n.indexOf("Resize"))return Wx[""+n];var e=Wx[""+n];return t>=0&&t<25||t>=160&&t<=205||t>=340&&t<=360?e:t>=25&&t<=70||t>=205&&t<=250?"n-resize"===e||"s-resize"===e?"ne-resize":"nw-resize"===e||"se-resize"===e?"n-resize":"e-resize"===e||"w-resize"===e?"nw-resize":"e-resize":t>=70&&t<=115||t>=250&&t<=295?"n-resize"===e||"s-resize"===e?"e-resize":"nw-resize"===e||"se-resize"===e?"ne-resize":"e-resize"===e||"w-resize"===e?"n-resize":"nw-resize":t>=115&&t<=155||t>=295&&t<=340?"n-resize"===e||"s-resize"===e?"nw-resize":"nw-resize"===e||"se-resize"===e?"e-resize":"e-resize"===e||"w-resize"===e?"ne-resize":Wx[""+n]:"n-resize"}(t,this.diagram.selectedItems.annotation?e.rotateAngle+e.parentTransform:e.rotateAngle)},n.prototype.findElementUnderMouse=function(t,e,i,r){return this.objectFinder.findElementUnderSelectedItem(t,e,i,r)},n.prototype.findObjectsUnderMouse=function(t,e){return this.objectFinder.findObjectsUnderMouse(t,this.diagram,this.eventArgs,e)},n.prototype.findObjectUnderMouse=function(t,e,i){return this.objectFinder.findObjectUnderMouse(this.diagram,t,e,i,this.eventArgs,this.currentPosition)},n.prototype.findTargetUnderMouse=function(t,e,i,r,s){return this.objectFinder.findObjectUnderMouse(this.diagram,t,e,i,this.eventArgs,r,s)},n.prototype.findActionToBeDone=function(t,e,i,r){return function Mne(n,t,e,i,r,s,o){if(s&&s.length>1&&r&&r.length>1)return"PinchZoom";if(i.currentSymbol)return"Drag";if("PortDraw"===i.eventHandler.action&&(i.tool&=~Ci.DrawOnce),(x3(i)||kI(i))&&i.drawingObject)return"Draw";if(Xa(i)&&(l=i.selectedItems).wrapper&&qr(l.constraints,"UserHandle"))for(var h=0,c=l.userHandles;h=50&&(l.x=(a.points[parseInt(h.toString(),10)].x+a.points[h+1].x)/2,l.y=(a.points[parseInt(h.toString(),10)].y+a.points[h+1].y)/2,wr(e,l,n.hitPadding?n.hitPadding:10)))return"OrthoThumb"}else AI(n)&&console.warn('[WARNING] :: Module "ConnectorEditing" is not available in Diagram component! You either misspelled the module name or forgot to load it.');return null}(g,l,e,i);if("OrthoThumb"===S)return S;if(qr(l.constraints,"ConnectorSourceThumb")&&xI(g)&&S||qr(l.constraints,"ConnectorTargetThumb")&&TI(g)&&S)return S}}else{var b=i.selectedItems.handleSize/2/i.scroller.currentZoom,M=10/i.scroller.currentZoom,w=Hi();qi(w,p.rotateAngle+p.parentTransform,p.offsetX,p.offsetY);var C=p.offsetX-p.pivot.x*p.actualSize.width,D=p.offsetY-p.pivot.y*p.actualSize.height,A={x:C+(.5===p.pivot.x?2*p.pivot.x:p.pivot.x)*p.actualSize.width/2,y:D-30/i.scroller.currentZoom};A=Je(w,A);var x=!!i.selectedItems.annotation,R=!(!x||!LI(i.selectedItems.annotation));if(qr(l.constraints,"Rotate")&&wr(e,A,M)&&i.selectedItems.thumbsConstraints&bt.Rotate){if(x&&R)return"LabelRotate";if(!x)return"Rotate"}if(u.Inflate(b),u.containsPoint(e)&&(S=function wne(n,t,e,i,r,s){var o;return 1===n.selectedItems.nodes.length&&0===n.selectedItems.connectors.length&&n.selectedItems.nodes[0].container&&(o=function Dne(n,t,e,i,r){var s=10/n.scroller.currentZoom,o=40/n.scroller.currentZoom,a=n.selectedItems,l=t.actualSize.width,h=t.actualSize.height,c=new Ne(i,r,t.style.strokeWidth,h),d=new Ne(i+l,r,t.style.strokeWidth,h),u=new Ne(i,r,l,t.style.strokeWidth),p=new Ne(i,r+h,l,t.style.strokeWidth),f=cs(n,n.selectedItems.nodes[0],!0)?n.nameTable[n.selectedItems.nodes[0].parentId]:n.selectedItems.nodes[0];if(l>=o&&h>=o){if(fa(a.constraints,"ResizeEast",a.thumbsConstraints,a)&&d.containsPoint(e,s))return"ResizeEast";if(fa(a.constraints,"ResizeSouth",a.thumbsConstraints,a)&&p.containsPoint(e,s))return"ResizeSouth";if("Grid"!==f.container.type){if(fa(a.constraints,"ResizeWest",a.thumbsConstraints,a)&&c.containsPoint(e,s))return"ResizeWest";if(fa(a.constraints,"ResizeNorth",a.thumbsConstraints,a)&&u.containsPoint(e,s))return"ResizeNorth"}}return null}(n,t,e,r,s)),!o&&(!n.selectedItems.nodes[0]||!n.selectedItems.nodes[0].isPhase&&!n.selectedItems.nodes[0].isLane&&"SwimLane"!==n.selectedItems.nodes[0].shape.type)&&(o=function xne(n,t,e,i,r,s){var o=40/n.scroller.currentZoom,a=n.selectedItems.handleSize/2/n.scroller.currentZoom,l=n.selectedItems,h=!!l.annotation;if(t.actualSize.width>=o&&t.actualSize.height>=o){if(fa(l.constraints,"ResizeSouthEast",l.thumbsConstraints,l)&&wr(e,Je(i,{x:r+t.actualSize.width,y:s+t.actualSize.height}),a))return h?"LabelResizeSouthEast":"ResizeSouthEast";if(fa(l.constraints,"ResizeSouthWest",l.thumbsConstraints,l)&&wr(e,Je(i,{x:r,y:s+t.actualSize.height}),a))return h?"LabelResizeSouthWest":"ResizeSouthWest";if(fa(l.constraints,"ResizeNorthEast",l.thumbsConstraints,l)&&wr(e,Je(i,{x:r+t.actualSize.width,y:s}),a))return h?"LabelResizeNorthEast":"ResizeNorthEast";if(fa(l.constraints,"ResizeNorthWest",l.thumbsConstraints,l)&&wr(e,Je(i,{x:r,y:s}),a))return h?"LabelResizeNorthWest":"ResizeNorthWest"}return fa(l.constraints,"ResizeEast",l.thumbsConstraints,l)&&wr(e,Je(i,{x:r+t.actualSize.width,y:s+t.actualSize.height/2}),a)?h?"LabelResizeEast":"ResizeEast":fa(l.constraints,"ResizeWest",l.thumbsConstraints,l)&&wr(e,Je(i,{x:r,y:s+t.actualSize.height/2}),a)?h?"LabelResizeWest":"ResizeWest":fa(l.constraints,"ResizeSouth",l.thumbsConstraints,l)&&wr(e,Je(i,{x:r+t.actualSize.width/2,y:s+t.actualSize.height}),a)?h?"LabelResizeSouth":"ResizeSouth":fa(l.constraints,"ResizeNorth",l.thumbsConstraints,l)&&wr(e,Je(i,{x:r+t.actualSize.width/2,y:s}),a)?h?"LabelResizeNorth":"ResizeNorth":null}(n,t,e,i,r,s)),o||null}(i,p,e,w,C,D),S))return S}}if(Lc(i)&&!n)return"Pan";if((o instanceof Es||o instanceof xc)&&(!Lc(i)||_v(i)||Uv(i))&&(S=function Ene(n,t,e,i){if(Hx(t)&&(ga(t,Gt.Hover)||ga(t,Gt.Visible))){if(t.constraints&ni.Drag)return"PortDrag"}else if(Rx(t)&&(ga(t,Gt.Hover)||ga(t,Gt.Visible))&&t.constraints&ni.Draw){n.drawingObject={};var r={type:"Orthogonal",sourcePortID:t.id};return n.drawingObject=r,n.tool|=Ci.DrawOnce,n.currentDrawingObject=r,"PortDraw"}return"None"}(i,o),"None"!==S))return S;if((o instanceof Zn||o instanceof Nr)&&!Lc(i)&&Dd(o))return _r(i,o,void 0,t)&&to(o)?"LabelDrag":"LabelSelect";if(null!==n){if(!(n instanceof te||n instanceof de))return"Select";if(t&&t.id){var L=t.id.split(n.id)[1];if(L&&L.match("^_icon"))return"LayoutAnimation"}if(t&&t.id)for(var O=void 0,N=0;N-1)return"FixedUserHandle";if(t instanceof si&&t.hyperlink.link)return"Hyperlink";if(!to(n)||!_r(i,n,!1)||void 0!==i.selectedItems.annotation)return n&&Lc(i)&&!PI(i)?"Pan":i.selectedItems.nodes.length&&i.selectedItems.nodes[0].isLane&&i.selectedItems.wrapper&&i.selectedItems.wrapper.bounds.containsPoint(e)?"Drag":"Select";if(n instanceof de&&!wr(e,n.sourcePoint,n.hitPadding)&&!wr(e,n.targetPoint,n.hitPadding)||!(n instanceof de))return"Drag"}return"Select"}(t,e,this.currentPosition,this.diagram,this.touchStartList,this.touchMoveList,r)},n.prototype.updateContainerBounds=function(t){var e=!1;if(this.diagram.selectedObject.helperObject&&this.diagram.selectedObject.actualObject instanceof te){var i=this.tool instanceof kd,r=this.diagram.selectedObject.actualObject,s=this.diagram.nameTable[r.parentId];t?V3(this.diagram,r,this.currentPosition,i):((!s||s&&"SwimLane"!==s.shape.type)&&this.diagram.updateDiagramObject(r),e=function yne(n,t,e,i){var r,o=!1;if(cs(n,t,!0)){n.protectPropertyChange(!0);var a=(r=n.nameTable[t.parentId]).wrapper;if(r&&"Canvas"===r.container.type){if(i||a.bounds.x<=e.x&&a.bounds.right>=e.x&&a.bounds.y<=e.y&&a.bounds.bottom>=e.y){var l=void 0,h=a.bounds.y,c=a.bounds.x,d=n.nameTable[r.parentId]||r;if("SwimLane"===d.shape.type)o=$v(r,d,t,n,!0);else{var p=n.nameTable[r.parentId]||r,f=p.shape;l=p.wrapper,a.actualSize.widtha.outerBounds.x)&&(void 0!==r.rowIndex?(l.updateColumnWidth(r.columnIndex,a.outerBounds.width,!0),"Horizontal"===f.orientation&&f.phaseSize&&FI(p,n,a,r.columnIndex),Oc(n,p),n.drag(p,c-a.bounds.x,h-a.bounds.y)):n.scale(r,1+(a.outerBounds.width-a.actualSize.width)/a.actualSize.width,1,a.outerBounds.xa.outerBounds.y)&&(void 0!==r.rowIndex?(l.updateRowHeight(r.rowIndex,a.outerBounds.height,!0),n.drag(p,c-a.bounds.x,h-a.bounds.y)):n.scale(r,1,1+(a.outerBounds.height-a.actualSize.height)/a.actualSize.height,a.outerBounds.yi.y&&(h+=u>0?-1:1,u+=u>0?-1:1):i&&e.wrapper.offsetYi.x&&(h+=u>0?-1:1,u+=u>0?-1:1):i&&e.wrapper.offsetX1&&!(this.diagram.lineRoutingModule&&this.diagram.constraints&rt.LineRouting))for(var b=t.offsetX-this.diagram.selectedItems.offsetX,M=t.offsetY-this.diagram.selectedItems.offsetY,w=t.rotateAngle-this.diagram.selectedItems.rotateAngle,C=0;C-1){var x=c.children;x.splice(x.indexOf(o.id),1),this.diagram.nameTable[o.id].parentId="",i=!0,c.wrapper.children.splice(A,1)}}if(function bne(n,t,e,i){var r=n,s=e.nameTable[r.parentId],o=e.nameTable[r.parentId];if(t&&o&&o.container&&"Stack"===o.container.type&&t.container&&"Stack"===t.container.type&&o.id!==t.parentId){var a=o.wrapper.children.indexOf(r.wrapper);a>-1&&(e.nameTable[r.id].parentId=t.id,o.wrapper.children.splice(a,1))}if(t&&t.parentId&&r.parentId&&"Drag"===i&&o.container&&"Stack"===o.container.type){var l=s.wrapper.children.indexOf(t.wrapper),h=s.wrapper.children.indexOf(r.wrapper),c={targetIndex:l,target:t,sourceIndex:h,source:n};s.wrapper.children.splice(h,1),s.wrapper.children.splice(l,0,r.wrapper),e.commandHandler.addHistoryEntry({type:"StackChildPositionChanged",redoObject:{targetIndex:h,target:t,sourceIndex:l,source:n},undoObject:c,category:"Internal"})}}(o,h,this.diagram,this.action),(c=cs(this.diagram,o)?this.diagram.nameTable[o.parentId]:this.diagram.nameTable[o.parentId]||o)&&c.container&&"Canvas"===c.container.type&&(c.wrapper.maxWidth=c.maxWidth=c.wrapper.actualSize.width,c.wrapper.maxHeight=c.maxHeight=c.wrapper.actualSize.height,e=!0),cs(this.diagram,o,!0)&&c&&"Canvas"===c.container.type)if(this.diagram.selectedItems.nodes.length>1)for(C=0;C0)for(var i=0;i0&&e.columnIndex>0||l&&e.isLane)){if("Horizontal"===t.container.orientation&&e.isPhase&&e.wrapper.width>e.maxWidth&&(e.maxWidth=e.wrapper.width,e.wrapper.maxWidth=e.wrapper.width),h.updateColumnWidth(e.columnIndex,r.width,!0,c),_x(this.diagram,e,t),e.isPhase){var f=this.diagram.nameTable[""+t.shape.phases[e.columnIndex].header.id];f.maxWidth0?(r=new rf(t,"",u),t.shape.classShape.attributes.push(r)):i.id.includes("_umlMethods")&&t.shape.classShape.methods.length>0&&(s=new hm(t,"",u),t.shape.classShape.methods.push(s))),"Interface"===t.shape.classifier&&(i.id.includes("_umlProperty")&&t.shape.interfaceShape.attributes.length>0?(r=new rf(t,"",u),t.shape.classShape.attributes.push(r)):i.id.includes("_umlMethods")&&t.shape.interfaceShape.methods.length>0&&(s=new hm(t,"",u),t.shape.interfaceShape.methods.push(s))),"Enumeration"===t.shape.classifier&&i.id.includes("_umlMember")&&t.shape.enumerationShape.members.length>0){var p=new sb(t,"",u);t.shape.enumerationShape.members.push(p)}t.wrapper.children.indexOf(c.wrapper),this.diagram.enableServerDataBinding(!0),this.diagram.add(c),this.diagram.updateConnectorEdges(t),this.diagram.clearSelection(),this.diagram.select([this.diagram.nameTable[c.id]]),this.diagram.endGroupAction(),this.diagram.startTextEdit()}}},n}(),_oe=function(){function n(){}return n.prototype.findObjectsUnderMouse=function(t,e,i,r,s){var o=[];r&&r instanceof oi&&r.nodes.length+r.connectors.length===1&&(r=r.nodes[0]||r.connectors[0]).children&&0===r.children.length&&(i.actualObject=r);for(var a,l,h,c,f,d=r&&r instanceof de&&(r.constraints&qe.ConnectToNearByNode||r.constraints&qe.ConnectToNearByPort)&&r.connectionPadding||0,p={},g=0,v=e.spatialSearch.findObjects(new Ne(t.x-50-d,t.y-50-d,100+d,100+d));g-1&&o.splice(T,1),"UmlClassifier"===y.shape.type&&y.container&&"Stack"===y.container.type&&(T=o.indexOf(e.nameTable[e.nameTable[y.id].wrapper.children[0].id]))>-1&&o.splice(T,1)}for(var P=0;Ps.zIndex&&(t[parseInt(r.toString(),10)]=l),r>0&&i&&a&&(a.isLane||a.isPhase||a.isHeader)&&t[parseInt(r.toString(),10)].zIndex=2)for(var d=t.length-1;d>=0;d--)if(t[parseInt(d.toString(),10)].parentId){var u=sm(t[parseInt(d.toString(),10)],e,""),p=sm(t[d-1],e,""),g=e.nameTable[""+p];g&&u!==p&&e.nameTable[""+u].zIndex=0;f--){d=Jp(e[parseInt(f.toString(),10)],!1),c=Jp(e[parseInt(f.toString(),10)],!0);var g=t[""+l].tool,v=this.findTargetElement(e[parseInt(f.toString(),10)].wrapper,o,t,void 0);if("Draw"===i&&v&&(e[parseInt(f.toString(),10)]instanceof te||e[parseInt(f.toString(),10)]instanceof de)&&!ib(e[parseInt(f.toString(),10)],v)&&(g&&"ConnectorSourceEnd"===g[""+h]&&!Nh(e[parseInt(f.toString(),10)])||g&&"ConnectorTargetEnd"===g[""+h]&&!da(e[parseInt(f.toString(),10)])))return u;if(e[parseInt(f.toString(),10)]instanceof te||e[parseInt(f.toString(),10)]instanceof de&&(Nh(e[parseInt(f.toString(),10)])||xd(d)||da(e[parseInt(f.toString(),10)])||Lh(c)||"PortDraw"===i&&g instanceof Od&&"ConnectorTargetEnd"===g[""+h]&&(da(e[parseInt(f.toString(),10)])||Lh(c))))return u=e[parseInt(f.toString(),10)],p&&(u=this.isTarget(u,t,i)),s.actualObject=u,u}else if("ConnectorTargetEnd"===i&&a){for(f=e.length-1;f>=0;f--)if(c=Jp(e[parseInt(f.toString(),10)],!0),(e[parseInt(f.toString(),10)]instanceof te||e[parseInt(f.toString(),10)]instanceof de)&&(da(e[parseInt(f.toString(),10)])||Lh(c)))return u=e[parseInt(f.toString(),10)],u=this.isTarget(u,t,i),s.actualObject=u,u}else{if(a&&("Drag"===i||t[""+l].tool instanceof ua)){var y=0;for(f=0;f=S.zIndex?u:S,y=Math.max(y,S.zIndex)):y=(u=S).zIndex)}return u&&"Bpmn"===u.shape.type&&(t.selectedItems.nodes.length>0&&"Bpmn"===t.selectedItems.nodes[0].shape.type||(u=null)),u&&(s.actualObject=u),u}if("Select"!==i&&"Pan"!==i||!t[""+l].tool)if("Pan"===i||"LayoutAnimation"===i){for(f=e.length-1;f>=0;f--)if((e[parseInt(f.toString(),10)]instanceof te||e[parseInt(f.toString(),10)]instanceof de)&&(v=this.findTargetElement(e[parseInt(f.toString(),10)].wrapper,o,t,void 0),"Pan"===i||v&&(v.id.match("_icon_content_shape$")||v.id.match("_icon_content_rect$"))))return e[parseInt(f.toString(),10)]}else u=e[e.length-1],s&&u&&(s.actualObject=u);else{for(f=e.length-1;f>=0;f--)if(e[parseInt(f.toString(),10)]instanceof de){var b=e[f-1];if(e[f-1]instanceof te&&b.ports){if((v=this.findTargetElement(b.wrapper,o,t,void 0))&&(v.id.match("_icon_content_shape$")||v.id.match("_icon_content_rect$")))return b;for(var M=0;M=0;s--){var o=t.children[parseInt(s.toString(),10)];if(o&&o.outerBounds.containsPoint(e,r||0))if(o.visible){if(o instanceof Cs){var a=this.findTargetElement(o,e,i);if(a)return a}var l="Clip"===o.style.textOverflow||"Ellipsis"===o.style.textOverflow;if(o.bounds.containsPoint(e,r||0)&&!l)return o;if(t.bounds.containsPoint(e,r||0)&&l)return o}else if(o instanceof Ke&&t&&t.id){var h=void 0;if(t.id.includes("group_container")){var c=t.id.slice(0,-15);h=i.getObject(c)}else h=i.getObject(t.id);if(eb(h,o.id))return o}}return t.bounds.containsPoint(e,r)&&"none"!==t.style.fill?t:null},n}(),Uoe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),sf=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},JF=function(n){function t(e,i,r,s){var o=n.call(this,e,i,r,s)||this;return o.objectZIndex=-1,o.zIndexTable={},o.objects=[],o}return Uoe(t,n),sf([I("")],t.prototype,"id",void 0),sf([I(!0)],t.prototype,"visible",void 0),sf([I(!1)],t.prototype,"lock",void 0),sf([I()],t.prototype,"objects",void 0),sf([I()],t.prototype,"addInfo",void 0),sf([I(-1)],t.prototype,"zIndex",void 0),t}(Ee),MT=function(n,t,e,i){return new(e||(e=Promise))(function(r,s){function o(h){try{l(i.next(h))}catch(c){s(c)}}function a(h){try{l(i.throw(h))}catch(c){s(c)}}function l(h){h.done?r(h.value):new e(function(c){c(h.value)}).then(o,a)}l((i=i.apply(n,t||[])).next())})},wT=function(n,t){var i,r,s,o,e={label:0,sent:function(){if(1&s[0])throw s[1];return s[1]},trys:[],ops:[]};return o={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function a(h){return function(c){return function l(h){if(i)throw new TypeError("Generator is already executing.");for(;e;)try{if(i=1,r&&(s=2&h[0]?r.return:h[0]?r.throw||((s=r.return)&&s.call(r),0):r.next)&&!(s=s.call(r,h[1])).done)return s;switch(r=0,s&&(h=[2&h[0],s.value]),h[0]){case 0:case 1:s=h;break;case 4:return e.label++,{value:h[1],done:!1};case 5:e.label++,r=h[1],h=[0];continue;case 7:h=e.ops.pop(),e.trys.pop();continue;default:if(!(s=(s=e.trys).length>0&&s[s.length-1])&&(6===h[0]||2===h[0])){e=0;continue}if(3===h[0]&&(!s||h[1]>s[0]&&h[1]1)for(var i=0;i-1)return e[parseInt(i.toString(),10)];return this.diagram.activeLayer},n.prototype.getLayer=function(t){for(var e=this.diagram.layers,i=0;i=0;o--)this.diagram.unSelect(this.diagram.nameTable[s[parseInt(o.toString(),10)]]),this.diagram.remove(this.diagram.nameTable[s[parseInt(o.toString(),10)]]),"default_layer"!==i.id&&this.diagram.activeLayer.id===t&&(this.diagram.activeLayer=this.diagram.layers[this.diagram.layers.length-1]);delete this.diagram.layerZIndexTable[i.zIndex],this.diagram.layers.splice(r,1),"SVG"!==this.diagram.mode&&this.diagram.refreshDiagramLayer()}},n.prototype.moveObjects=function(t,e){this.diagram.startGroupAction();for(var i={},r=[],s=0;s-1){if(r=[],(h=this.diagram.nameTable[""+s]).children)for(var f=0,g=h.children;f0){for(var y=void 0,S=0,b=r;S0)for(var r=0;r0)for(r=0;r0){t=t.concat(this.diagram.selectedItems.connectors);for(var i=0;i0)for(t=t.concat(this.diagram.selectedItems.nodes),i=0;i0){for(var i=0,r=t.shape.activity.subProcess.processes;i0&&this.copyProcesses(this.processTable[""+s])}this.clipboardData.processTable=this.processTable}},n.prototype.group=function(){this.oldSelectedObjects=rm(this.diagram);var e=this.diagram.isProtectedOnChange;this.diagram.protectPropertyChange(!0),this.diagram.diagramActions=this.diagram.diagramActions|ee.Group;var r={};r.id="group"+Qe(),(r=new te(this.diagram,"nodes",r,!0)).children=[];for(var s=this.diagram.selectedItems.nodes.concat(this.diagram.selectedItems.connectors).sort(function(h,c){return h.zIndex-c.zIndex}),o=0;o0){var a=this.diagram.add(r);a&&this.select(a),this.addHistoryEntry({type:"Group",undoObject:r,redoObject:r,category:"Internal"}),this.diagram.diagramActions=this.diagram.diagramActions&~ee.Group,this.diagram.protectPropertyChange(e)}},n.prototype.unGroup=function(t){var i=this.diagram.isProtectedOnChange;this.diagram.protectPropertyChange(!0),this.diagram.diagramActions=this.diagram.diagramActions|ee.Group;var r=[];t?r.push(t):r=this.diagram.selectedItems.nodes,this.diagram.startGroupAction();for(var s=0;s0&&this.diagram.removePorts(o,o.ports),o.annotations&&o.annotations.length>0&&!ce()&&this.diagram.removeLabels(o,o.annotations);for(var c=this.diagram.nameTable[o.parentId],d=o.children.length-1;d>=0;d--)this.diagram.nameTable[o.children[parseInt(d.toString(),10)]].parentId="",this.diagram.deleteChild(this.diagram.nameTable[o.children[parseInt(d.toString(),10)]],o),o.parentId&&o.children[parseInt(d.toString(),10)]&&this.diagram.addChild(c,o.children[parseInt(d.toString(),10)]);this.resetDependentConnectors(o.inEdges,!0),this.resetDependentConnectors(o.outEdges,!1),this.diagram.diagramActions&ee.UndoRedo||this.addHistoryEntry({type:"UnGroup",undoObject:a,redoObject:a,category:"Internal"}),o.parentId&&this.diagram.deleteChild(o,c)}this.diagram.removeNode(o,l),this.clearSelection()}this.diagram.endGroupAction(),this.diagram.diagramActions=this.diagram.diagramActions&~ee.Group,this.diagram.protectPropertyChange(i)},n.prototype.resetDependentConnectors=function(t,e){for(var i=0;i0&&(g=!1)}if(g){var y=this.cloneConnector(p,i);c.push(y),o[h.id]=y.id}}else{var S=this.cloneNode(h,i);if(c.push(S),S){o[h.id]=S.id;var b=h.inEdges;if(b)for(var M=0,w=b;M0)for(var u=0;u0)for(r=t.segments,s=0;s0&&this.diagram.drawingObject&&"Bezier"===this.diagram.drawingObject.type&&(t.segments=[]);var e=this.diagram.add(t);"SVG"!==this.diagram.mode&&this.diagram.refreshDiagramLayer(),this.selectObjects([e]),t&&!kI(this.diagram)&&(this.diagram.tool&=~Ci.DrawOnce,this.diagram.currentDrawingObject=void 0)},n.prototype.enableServerDataBinding=function(t){this.diagram.enableServerDataBinding(t)},n.prototype.addText=function(t,e){var i=this.diagram.findElementUnderMouse(t,e,this.diagram);this.diagram.startTextEdit(t,i instanceof si?i.id.split("_")[1]:void 0)},n.prototype.isUserHandle=function(t){var e=this.diagram.selectedItems;if(e.wrapper&&qr(e.constraints,"UserHandle"))for(var i=0,r=e.userHandles;i0&&t[0]&&t[0].isLane)for(s=this.diagram.getObject(t[0].parentId),t[0].shape.header=[],a=0;a1||e&&1===t.length)){if(1!==t.length)return[2];this.clearSelection()}if(!(u||d||1!==t.length||e&&Xa(this.diagram)))return this.clearSelection(),[2]}if(!r.cancel){for(p=0;p0||e)&&f.children&&!f.parentId)for(g=0;g0||e,!0)}else this.select(f,p>0||e,!0);void 0===i&&(i=c),r={oldValue:i||[],newValue:this.getSelectedObject(),cause:this.diagram.diagramActions,state:"Changed",type:"Addition",cancel:!1},this.diagram.renderSelector(e||t&&t.length>1),ce()||this.diagram.triggerEvent(Ce.selectionChange,r),this.diagram.enableServerDataBinding(!0)}return[2]})})},n.prototype.findParent=function(t){return t.parentId&&this.findParent(t=this.diagram.nameTable[t.parentId]),t},n.prototype.selectProcesses=function(t){if(this.hasProcesses(t))for(var e=t.shape.activity.subProcess.processes,i=0;i0)},n.prototype.select=function(t,e,i){var r=this.getObjectLayer(t.id);if(Dd(t)&&!(t instanceof oi)&&!_r(this.diagram,t)&&r&&!r.lock&&r.visible&&t.wrapper.visible){(e=!!Xa(this.diagram)&&e)||this.clearSelection(),this.diagram.enableServerDataBinding(!1);var s=this.diagram.selectedItems;if(t instanceof te?s.nodes.push(t.isHeader?this.diagram.nameTable[t.parentId]:t):s.connectors.push(t),s.selectedObjects.push(t),e)s.wrapper.rotateAngle=s.rotateAngle=0,s.wrapper.children.push(t.wrapper);else if(s.init(this.diagram),1===s.nodes.length&&0===s.connectors.length){var l=Ux(this.diagram,s);l&&(s.wrapper.children[0]=l),s.rotateAngle=s.nodes[0].rotateAngle,s.wrapper.rotateAngle=s.nodes[0].rotateAngle,s.wrapper.pivot=s.nodes[0].pivot}i||this.diagram.renderSelector(e),this.diagram.enableServerDataBinding(!0)}},n.prototype.labelSelect=function(t,e){this.oldSelectedObjects=rm(this.diagram);var i=this.diagram.selectedItems,r=this.diagram.allowServerDataBinding;this.diagram.allowServerDataBinding=!1,i.nodes=i.connectors=[],this.diagram.allowServerDataBinding=r,t instanceof te?i.nodes[0]=t:i.connectors[0]=t,i.annotation=this.findTarget(e,t),i.init(this.diagram),this.diagram.renderSelector(!1)},n.prototype.unSelect=function(t){var e=this.diagram.selectedItems.nodes.concat(this.diagram.selectedItems.connectors),i=e.filter(function(a){return a.id!==t.id}),r={oldValue:e,newValue:i,cause:this.diagram.diagramActions,state:"Changing",type:"Removal",cancel:!1};if(this.diagram.currentSymbol||ce()||this.diagram.triggerEvent(Ce.selectionChange,r),_r(this.diagram,t)){var s=this.diagram.selectedItems,o=void 0;t instanceof te?(o=s.nodes.indexOf(t,0),s.nodes.splice(o,1)):(o=s.connectors.indexOf(t,0),s.connectors.splice(o,1)),o=s.selectedObjects.indexOf(t,0),s.selectedObjects.splice(o,1),(r={oldValue:e,newValue:i,cause:this.diagram.diagramActions,state:"Changed",type:"Removal",cancel:(r={oldValue:e,newValue:i,cause:this.diagram.diagramActions,state:"Changed",type:"Removal",cancel:!1}).cancel}).cancel||(o=s.wrapper.children.indexOf(t.wrapper,0),s.wrapper.children.splice(o,1),this.diagram.updateSelector(),this.diagram.currentSymbol||this.diagram.triggerEvent(Ce.selectionChange,r))}},n.prototype.moveSvgNode=function(t,e){var i=xt(e+"_groupElement",this.diagram.element.id),r=xt(t+"_groupElement",this.diagram.element.id);i.parentNode.insertBefore(r,i)},n.prototype.moveAfterSvgNode=function(t,e){var i=xt(e+"_groupElement",this.diagram.element.id),r=xt(t+"_groupElement",this.diagram.element.id);i.insertAdjacentElement("afterend",r)},n.prototype.sendLayerBackward=function(t){var e=this.getLayer(t);if(e&&0!==e.zIndex){var i=e.zIndex;if("SVG"===this.diagram.mode){var r=e.objects,s=this.getLayer(this.diagram.layerZIndexTable[i-1]).objects[0];if(s)for(var o=0,a=r;od&&"SwimLane"!==f.shape.type){var S=$(f);f.zIndex=d-((-1!==i.indexOf(f)?i.indexOf(f):0)+1),f.children&&(d=this.findLowestZIndex(f,c)||d),this.triggerOrderCommand(S,f,f),f.children&&this.updateGroupZindex(f,"SendToBack",d)}else"SwimLane"===f.shape.type&&(y=this.swapZIndexObjects(a,h,r,g));if("SVG"===this.diagram.mode){for(var M="SwimLane"!==this.diagram.nameTable[""+r].shape.type?d:y,w=h[parseInt(M.toString(),10)];!w&&Md)&&(d=p.zIndex)}for(var f=JSON.parse(JSON.stringify(l)),v=Number(Object.keys(l).sort(function(wo,Hl){return Number(wo)-Number(Hl)}).reverse()[0]),y=this.diagram.nameTable[""+e].zIndex,S=[],M=0;M<=v;M++)S.push(l[parseInt(M.toString(),10)]);if("SwimLane"===this.diagram.nameTable[""+e].shape.type)for(var C=v;C>=y;C--)if(l[parseInt(C.toString(),10)]&&this.diagram.nameTable[l[parseInt(C.toString(),10)]].parentId!==e){v=C;break}var D=this.diagram.nameTable[""+e];if(D.zIndexx&&(x=L.zIndex)}}else x=d;D.zIndex=x+((-1!==r.indexOf(D)?r.indexOf(D):0)+1),this.triggerOrderCommand(A,D,D)}else if("SwimLane"===D.shape.type){for(var O=0,N=-1,T=0,P=0,_=JSON.parse(JSON.stringify(l)),B=0;B<=y;B++)if(l[parseInt(B.toString(),10)]&&this.diagram.nameTable[l[parseInt(B.toString(),10)]].parentId===e&&-1===N){N=B,T=B;break}for(var j=0;j<=v;j++)f[parseInt(j.toString(),10)]&&f[parseInt(j.toString(),10)]!==e&&this.diagram.nameTable[f[parseInt(j.toString(),10)]].parentId!==e&&this.diagram.nameTable[f[parseInt(j.toString(),10)]].zIndex>=this.diagram.nameTable[""+e].zIndex&&O++;for(var ue=N,pe=0;pe<=O;pe++){for(;!l[parseInt(ue.toString(),10)];)ue++;P=this.diagram.nameTable[l[parseInt(ue.toString(),10)]].zIndex,ue++}for(var Me=P;Me<=v;Me++){for(;!_[parseInt(N.toString(),10)];)N++;for(;!l[parseInt(Me.toString(),10)];)Me++;l[parseInt(Me.toString(),10)]=_[parseInt(N.toString(),10)],this.diagram.nameTable[l[parseInt(Me.toString(),10)]].zIndex=Me,N++}l[parseInt(v.toString(),10)]=this.diagram.nameTable[""+e].id,this.diagram.nameTable[""+e].zIndex=v,ue=y+1;for(var De=T,xe=0;xe0&&("Native"===hr[0].shape.type||"HTML"===hr[0].shape.type)){for(Mi.parentNode.removeChild(Mi),De=0;De0?r[0]:null},n.prototype.findLowestZIndex=function(t,e){var r=this.diagram.nodes.filter(function(s){return-1!==e.indexOf(s.id)}).filter(function(s){return""===s.parentId&&s.id!==t.id}).map(function(s){return s.zIndex});return r.sort(function(s,o){return s-o}),r.length>0?r[0]:null},n.prototype.triggerOrderCommand=function(t,e,i){var s={zIndex:$(t).zIndex},o={zIndex:e.zIndex},a={element:i,cause:this.diagram.diagramActions,diagramAction:this.diagram.getDiagramAction(this.diagram.diagramActions),oldValue:s,newValue:o};this.diagram.triggerEvent(Ce.propertyChange,a)},n.prototype.checkGroupNode=function(t,e,i){return i[""+e].parentId===i[""+t].parentId},n.prototype.sortByZIndex=function(t,e,i){if("BringForward"===i){var r=e||"zIndex";t=t.sort(function(o,a){return a[""+r]-o[""+r]})}else{var s=e||"zIndex";t=t.sort(function(o,a){return o[""+s]-a[""+s]})}return t},n.prototype.orderCommands=function(t,e,i){var r=this,s=e.nodes;if(s=s.concat(e.connectors),t)if("SendBackward"===i)for(var o=0;oa}),S=v.filter(function(D){return D0?Math.max.apply(Math,S):a,M=y.length>0?Math.min.apply(Math,y):a;if(a!==M){var w=c.zIndexTable[parseInt(M.toString(),10)],C=c.zIndexTable[parseInt(a.toString(),10)];this.moveSvgNode(C,w)}else"SendToBack"===i&&(w=c.zIndexTable[parseInt(a.toString(),10)],C=c.zIndexTable[parseInt(b.toString(),10)],this.moveAfterSvgNode(w,C))}}else this.diagram.refreshCanvasLayers()}},n.prototype.sendForward=function(t){var e=this;if(this.diagram.protectPropertyChange(!0),Xa(this.diagram)||t){$(t||(this.diagram.selectedItems.nodes.length?this.diagram.selectedItems.nodes[0]:this.diagram.selectedItems.connectors[0]));var s=t&&t.id,o=this.diagram.layers.indexOf(this.getObjectLayer(s=s||(this.diagram.selectedItems.nodes.length?this.diagram.selectedItems.nodes[0].id:this.diagram.selectedItems.connectors[0].id))),a=$(this.diagram.nameTable),h=(parseInt(o.toString(),10),this.diagram.nameTable[""+s]),c=[],d=this.diagram.spatialSearch.findObjects(h.wrapper.bounds);d.length>2&&(d=this.sortByZIndex(d,void 0,"BringForward"));for(var u=0,p=d;u=0;f--)this.diagram.nameTable[c[parseInt(f.toString(),10)].id].parentId===s&&c.splice(f,1);if(c.length>0){var y=this.diagram.nameTable[c[c.length-1].id];if(y.parentId){var b=sm(y,this.diagram,""),M=this.diagram.nameTable[""+b];M.id!==s&&(c[0]=M)}var w={};for(f=0;f0&&(Object.values(O).forEach(function(ue){ue>=T&&N.push(ue)}),0!==N.length&&this.updateZIndexBySendForward(h,N,o))}var P=[];if(Object.keys(this.changedNodeZIndexes).forEach(function(ue){if((a[""+ue]?a[""+ue].zIndex:null)!==e.changedNodeZIndexes[""+ue]){var De=$(a[""+ue]);P.push(De)}}),this.updateLayerZindexTable(o),L.nodes.splice(0,L.nodes.length),P.forEach(function(ue){var pe=$(ue);L.nodes.push(pe)}),"SVG"===this.diagram.mode){var _=c[c.length-1].id,B=c[c.length-1];B&&!("HTML"===B.shape.type||"Native"===B.shape.type)&&this.moveAfterSvgNode(s,_),this.updateNativeNodeIndex(_,s)}else this.diagram.refreshCanvasLayers();var j=[];Object.keys(this.changedNodeZIndexes).forEach(function(ue){if((a[""+ue]?a[""+ue].zIndex:null)!==e.changedNodeZIndexes[""+ue]){var De=$(e.diagram.nameTable[""+ue]);j.push(De)}});var Q=$(this.diagram.selectedItems);Q.nodes.splice(0,Q.nodes.length),j.forEach(function(ue){var pe=$(ue);Q.nodes.push(pe)}),this.diagram.diagramActions&ee.UndoRedo||this.addHistoryEntry({type:"SendForward",category:"Internal",undoObject:L,redoObject:Q}),this.diagram.endGroupAction()}}this.diagram.protectPropertyChange(!1)},n.prototype.updateZIndexBySendForward=function(t,e,i){var r=$(t);t.zIndex=Math.min.apply(Math,e);var a,s=Math.min.apply(Math,e),o=Math.min.apply(Math,e),l=this.diagram.layers[parseInt(i.toString(),10)].objects,h=this.diagram.nodes.filter(function(S){return-1!==l.indexOf(S.id)});t.children&&this.updateGroupZindex(t,"BringForward",t.zIndex);var c=h.filter(function(S){return S.zIndex===Math.min.apply(Math,e)&&S.id!==t.id});if(c&&c.length>0&&c[0].children){for(var d=Math.min.apply(Math,e),u=0;uo&&g!==t&&g.parentId!==t.id&&c&&c.length>0&&g.parentId!==c[0].id){var v=$(g);g.zIndex=a+1,a++,this.triggerOrderCommand(v,g,g)}var y=g.zIndex;this.changedNodeZIndexes[g.id]=(this.changedNodeZIndexes.hasOwnProperty(g.id),y)}},n.prototype.arrangeZIndexForLowerNodes=function(t,e,i){var r=i.filter(function(o){return o.zIndex<=t&&o.parentId!==e.id});r.sort(function(o,a){return a.zIndex-o.zIndex});for(var s=0;se&&(e=r.zIndex)}return e},n.prototype.sendBackward=function(t){var e=this;if(this.diagram.protectPropertyChange(!0),Xa(this.diagram)||t){$(t||(this.diagram.selectedItems.nodes.length?this.diagram.selectedItems.nodes[0]:this.diagram.selectedItems.connectors[0]));var s=t&&t.id,o=this.diagram.layers.indexOf(this.getObjectLayer(s=s||(this.diagram.selectedItems.nodes.length?this.diagram.selectedItems.nodes[0].id:this.diagram.selectedItems.connectors[0].id))),a=$(this.diagram.nameTable),h=(parseInt(o.toString(),10),this.diagram.nameTable[""+s]),c=[],d=this.diagram.spatialSearch.findObjects(h.wrapper.bounds);d.length>2&&(d=this.sortByZIndex(d));for(var u=0,p=d;uNumber(f.zIndex)&&""===f.parentId&&h.wrapper.bounds.intersects(f.wrapper.bounds)&&c.push(f);for(var f=c.length-1;f>=0;f--)(v=this.diagram.nameTable[c[parseInt(f.toString(),10)].id]).parentId===s&&c.splice(f,1);if(c.length>0){var v;if((v=this.diagram.nameTable[c[c.length-1].id]).parentId){var S=sm(v,this.diagram,""),b=this.diagram.nameTable[""+S];s!==b.id&&(c[c.length-1]=b)}var M={};for(f=0;f0&&(Object.values(L).forEach(function(pe){pe<=N&&O.push(pe)}),0!==O.length&&this.updateZIndexBySendBackward(h,O,o))}var T=[];if(Object.keys(this.changedNodeZIndexes).forEach(function(pe){if((a[""+pe]?a[""+pe].zIndex:null)!==e.changedNodeZIndexes[""+pe]){var xe=$(a[""+pe]);T.push(xe)}}),this.updateLayerZindexTable(o),R.nodes.splice(0,R.nodes.length),T.forEach(function(pe){var Me=$(pe);R.nodes.push(Me)}),"SVG"===this.diagram.mode){var P=c[c.length-1].id,_=c[c.length-1];_&&"HTML"!==_.shape.type&&"Native"!==_.shape.type&&this.moveSvgNode(s,P);var B=this.diagram.nameTable[""+P];B.children&&B.children.length>0?this.updateNativeNodeIndex(s):this.updateNativeNodeIndex(s,P)}else this.diagram.refreshCanvasLayers();var j=[];Object.keys(this.changedNodeZIndexes).forEach(function(pe){if((a[""+pe]?a[""+pe].zIndex:null)!==e.changedNodeZIndexes[""+pe]){var xe=$(e.diagram.nameTable[""+pe]);j.push(xe)}});var Q=$(this.diagram.selectedItems);Q.nodes.splice(0,Q.nodes.length),j.forEach(function(pe){var Me=$(pe);Q.nodes.push(Me)}),this.diagram.diagramActions&ee.UndoRedo||this.addHistoryEntry({type:"SendBackward",category:"Internal",undoObject:R,redoObject:Q}),this.diagram.endGroupAction()}}this.diagram.protectPropertyChange(!1)},n.prototype.updateZIndexBySendBackward=function(t,e,i){var r=$(t);t.zIndex=Math.max.apply(Math,e);var p,s=t.zIndex,o=Math.max.apply(Math,e),a=this.diagram.layers[parseInt(i.toString(),10)].objects,l=this.diagram.nodes.filter(function(S){return-1!==a.indexOf(S.id)}),h=l.filter(function(S){return S.zIndex===Math.max.apply(Math,e)&&S.id!==t.id});if(h&&h.length>0&&h[0].children)for(var c=Math.max.apply(Math,e),d=0;d0&&g.parentId!==h[0].id){var v=$(g);g.zIndex=p-1,p--,this.triggerOrderCommand(v,g,g)}var y=g.zIndex;this.changedNodeZIndexes[""+g.id]=(this.changedNodeZIndexes.hasOwnProperty(g.id),y)}},n.prototype.findLowestChildZIndex=function(t){for(var e=t.zIndex,i=0;i0),this.selectObjects([t],!0))},n.prototype.clearSelection=function(t,e){return MT(this,void 0,void 0,function(){var i,r,s,o;return wT(this,function(a){return i=this.diagram.allowServerDataBinding,this.diagram.enableServerDataBinding(!1),Xa(this.diagram)&&(r=this.diagram.selectedItems,s=this.getSelectedObject(),this.diagram.currentSymbol&&(this.diagram.previousSelectedObject=s),o={oldValue:s,newValue:[],cause:this.diagram.diagramActions,state:"Changing",type:"Removal",cancel:!1},t&&(ce()||this.diagram.triggerEvent(Ce.selectionChange,o)),o.cancel||(r.offsetX=0,r.offsetY=0,r.width=0,r.height=0,r.rotateAngle=0,r.nodes=[],r.connectors=[],r.wrapper=null,r.annotation=void 0,r.selectedObjects=[],this.diagram.clearSelectorLayer(),t&&(o={oldValue:s,newValue:[],cause:this.diagram.diagramActions,state:"Changed",type:"Removal",cancel:!1},ce()||this.diagram.triggerEvent(Ce.selectionChange,o))),this.diagram.enableServerDataBinding(i)),[2]})})},n.prototype.clearSelectedItems=function(){this.clearSelection((this.diagram.selectedItems.nodes?this.diagram.selectedItems.nodes.length:0)+(this.diagram.selectedItems.connectors?this.diagram.selectedItems.connectors.length:0)>0)},n.prototype.removeStackHighlighter=function(){var t=Pl(this.diagram.element.id),e=t.getElementById(t.id+"_stack_highlighter");e&&e.parentNode.removeChild(e)},n.prototype.renderStackHighlighter=function(t,e){var r,s,o,i=this.diagram.selectedItems.nodes[0];if(!e){var a=this.diagram.findObjectsUnderMouse(t.position);if((e=this.diagram.findObjectUnderMouse(a,"Drag",!0))&&!(e.isLane||e.isPhase||e.isHeader))for(var l=0;l0)for(var a=0;a1)if(i){var h=l.segments[0],c=l.segments[1],u=Tc(MI(t.wrapper,t.wrapper.corners,t.wrapper.bounds),h.direction),g=Ll({corners:void 0,point:u=Ah(l,0,u,{x:l.sourceWrapper.offsetX,y:l.sourceWrapper.offsetY},!1),margin:void 0,direction:h.direction},{corners:void 0,point:c.points[1],margin:void 0,direction:void 0});h.length=z.distancePoints(g[0],g[1]),c.direction&&c.length&&(c.length=z.distancePoints(g[1],g[2]))}else if(o){switch(l.segments[0].direction){case"Bottom":r=t.wrapper.bounds.bottomCenter.x-e.bottomCenter.x,s=t.wrapper.bounds.bottomCenter.y-e.bottomCenter.y;break;case"Top":r=t.wrapper.bounds.topCenter.x-e.topCenter.x,s=t.wrapper.bounds.topCenter.y-e.topCenter.y;break;case"Left":r=t.wrapper.bounds.middleLeft.x-e.middleLeft.x,s=t.wrapper.bounds.middleLeft.y-e.middleLeft.y;break;case"Right":r=t.wrapper.bounds.middleRight.x-e.middleRight.x,s=t.wrapper.bounds.middleRight.y-e.middleRight.y}this.dragSourceEnd(l,r,s,!0,null,"ConnectorSourceEnd",void 0,void 0,void 0,!(t.parentId&&this.diagram.diagramActions&ee.isGroupDragging))}}},n.prototype.updateEndPoint=function(t,e){var r={sourcePoint:t.sourcePoint,targetPoint:t.targetPoint};t.sourceID&&(r.sourceID=t.sourceID),t.targetID&&(r.targetID=t.targetID),t.sourcePortID&&(r.sourcePortID=t.sourcePortID),t.targetPortID&&(r.targetPortID=t.targetPortID),t.segments&&(r.segments=t.segments),this.diagram.connectorPropertyChange(t,e||{},r),this.diagram.updateSelector()},n.prototype.dragSourceEnd=function(t,e,i,r,s,o,a,l,h,c,d){var u=this.diagram.nameTable[t.id],p={},f=this.checkBoundaryConstraints(e,i,u.wrapper.bounds);if(xI(u)&&f&&"BezierSourceThumb"!==o&&Vv(this.diagram)&&(p=$(p={sourcePoint:u.sourcePoint}),u.sourcePoint.x+=e,u.sourcePoint.y+=i,"ConnectorSourceEnd"===o&&"Orthogonal"===u.type&&this.changeSegmentLength(u,l,h,c),"Bpmn"===u.shape.type&&"Default"===u.shape.sequence&&"Sequence"===u.shape.flow&&this.updatePathElementOffset(u)),"Bezier"===u.type)if(p={sourcePoint:u.sourcePoint},d)this.translateBezierPoints(t,""===o?"ConnectorSourceEnd":o,e,i,d,s,!a);else for(var g=0;g2){var d=z.direction((c=t.segments[2]).points[0],c.points[1]);o.direction===ls(d)?("Right"===o.direction?c.points[0].x=o.points[o.points.length-1].x=l.wrapper.corners.middleRight.x+20:"Left"===o.direction?c.points[0].x=o.points[o.points.length-1].x=l.wrapper.corners.middleLeft.x-20:c.points[0].y=o.points[o.points.length-1].y="Top"===o.direction?l.wrapper.corners.topCenter.y-20:l.wrapper.corners.bottomCenter.y+20,c.direction&&c.length&&(c.length=z.distancePoints(c.points[0],c.points[c.points.length-1])),o.length=z.distancePoints(o.points[0],o.points[o.points.length-1])):o.direction===d&&c.direction&&c.length?("Top"===o.direction||"Bottom"===o.direction?(c.points[0]=o.points[0],c.points[c.points.length-1].x=c.points[0].x):(c.points[0]=o.points[0],c.points[c.points.length-1].y=c.points[0].y),c.length=z.distancePoints(c.points[0],c.points[c.points.length-1]),t.segments.splice(0,2)):o.length=20}else o.length=20;else if(o.length<1)if(""!==t.sourceID){var c;"Right"===a.direction?a.points[a.points.length-1].y=(h=l.wrapper.corners.middleRight).y:"Left"===a.direction?a.points[a.points.length-1].y=(h=l.wrapper.corners.middleLeft).y:a.points[a.points.length-1].x="Top"===a.direction?(h=l.wrapper.corners.topCenter).x:(h=l.wrapper.corners.bottomCenter).x,a.length=z.distancePoints(h,a.points[a.points.length-1]),t.segments.length>2&&(c=t.segments[2]).direction&&c.length&&(c.length=z.distancePoints(a.points[a.points.length-1],c.points[c.points.length-1])),t.segments.splice(0,1)}else t.segments.splice(0,1)}else e&&!i&&t.sourceID!==e.id&&t.segments&&null!==t.segments[0].direction&&e&&e instanceof te&&s&&this.changeSourceEndToNode(t,e),e&&i&&t.sourcePortID!==i&&t.segments&&null!==t.segments[0].direction&&e&&e instanceof te&&s&&this.changeSourceEndToPort(t,e,i)},n.prototype.canConnect=function(t,e){return!(!da(e)||!Nh(e))},n.prototype.changeSourceEndToPort=function(t,e,i){var r=this.diagram.getWrapper(e.wrapper,i),s={x:r.offsetX,y:r.offsetY},o=zo(s,En(e.wrapper),e.wrapper.bounds),a=t.segments[0],l=t.segments[1];if(a.direction!==o){var h=[],c={};if(a.direction===ls(o)){c={};var d=void 0;"Top"===o||"Bottom"===o?(d="Top"===o?{type:"Orthogonal",isTerminal:!0,direction:o,length:Math.abs(a.points[0].y-s.y)}:{type:"Orthogonal",isTerminal:!0,direction:o,length:Math.abs(s.y-a.points[0].y)},c=a.points[0].x>s.x?{type:"Orthogonal",isTerminal:!0,direction:"Right",length:a.points[0].x-s.x}:{type:"Orthogonal",isTerminal:!0,direction:"Left",length:s.x-a.points[0].x}):(d="Right"===o?{type:"Orthogonal",isTerminal:!0,direction:o,length:Math.abs(a.points[0].x-s.x)}:{type:"Orthogonal",isTerminal:!0,direction:o,length:Math.abs(s.x-a.points[0].x)},c=a.points[0].y>s.y?{type:"Orthogonal",direction:"Top",isTerminal:!0,length:a.points[0].y-s.y}:{type:"Orthogonal",direction:"Bottom",isTerminal:!0,length:s.y-a.points[0].y}),h.push(new bi(t,"segments",d,!0)),h.push(new bi(t,"segments",c,!0))}else h.push(new bi(t,"segments",c={type:"Orthogonal",direction:o,length:20,isTerminal:!0},!0));a.direction!==ls(o)&&("Top"===o||"Bottom"===o?(a.points[0].x=s.x,a.points[0].y=a.points[a.points.length-1].y="Top"===o?s.y-20:s.y+20):(a.points[0].y=s.y,a.points[0].x=a.points[a.points.length-1].x="Right"===o?s.x+20:s.x-20),a.length=z.distancePoints(a.points[0],a.points[a.points.length-1]),l.length=z.distancePoints(a.points[a.points.length-1],l.points[l.points.length-1])),t.segments=h.concat(t.segments)}else a.points[0]=s,"Top"===o||"Bottom"===o?a.points[a.points.length-1].x=s.x:a.points[a.points.length-1].y=s.y,a.length=z.distancePoints(a.points[0],a.points[a.points.length-1]),l.length=z.distancePoints(a.points[a.points.length-1],l.points[l.points.length-1])},n.prototype.removeTerminalSegment=function(t,e){for(var i=0;ii.width||"Left"===o.direction&&r.x>=o.points[0].x||"Right"===o.direction&&r.x<=o.points[0].x)o.points[0].y=o.points[o.points.length-1].y=r.y,o.points[0].x=r.x,o.length=z.distancePoints(o.points[0],o.points[o.points.length-1]),a.length=z.distancePoints(o.points[o.points.length-1],a.points[a.points.length-1]);else{var h=void 0;s="Bottom"===(h=a.direction?a.direction:z.direction(a.points[0],a.points[a.points.length-1]))?i.bottomCenter:i.topCenter,a.length&&a.direction&&(a.length="Top"===h?o.points[o.points.length-1].y-(s.y+20):s.y+20-o.points[o.points.length-1].y),o.length=o.points[o.points.length-1].x-s.x,o.direction=o.length>0?"Right":"Left",l.push(new bi(t,"segments",{type:"Orthogonal",direction:h,length:20},!0)),t.segments=l.concat(t.segments)}else r="Bottom"===o.direction?i.bottomCenter:i.topCenter,o.length>i.height||"Top"===o.direction&&r.y>=o.points[0].y||"Bottom"===o.direction&&r.y<=o.points[0].y?(o.points[0].x=o.points[o.points.length-1].x=r.x,o.points[0].y=r.y,o.length=z.distancePoints(o.points[0],o.points[o.points.length-1]),a.length=z.distancePoints(o.points[o.points.length-1],a.points[a.points.length-1])):(s="Left"===a.direction?i.middleLeft:i.middleRight,h=void 0,h=a.direction?a.direction:z.direction(a.points[0],a.points[a.points.length-1]),a.length&&a.direction&&(a.length="Left"===h?o.points[o.points.length-1].x-(s.x+20):s.x+20-o.points[o.points.length-1].x),o.length=o.points[o.points.length-1].y-s.y,o.direction=o.length>0?"Bottom":"Top",l.push(new bi(t,"segments",{type:"Orthogonal",direction:h,length:20},!0)),t.segments=l.concat(t.segments))},n.prototype.translateBezierPoints=function(t,e,i,r,s,o,a){var l=t.segments.indexOf(s),h=t.segments[parseInt(l.toString(),10)],c=l>0?t.segments[l-1]:null,d=null!==c?c.point:t.sourcePoint,u=l===t.segments.length-1?t.targetPoint:h.point;if(h)if("BezierSourceThumb"===e&&(h.vector1.angle||h.vector1.distance)){var p=h.vector1.distance,f=h.vector1.angle;h.vector1={distance:t.distance(d,o),angle:z.findAngle(d,o)},this.translateSubsequentSegment(t,s,!0,h.vector1.distance-p,h.vector1.angle-f)}else"BezierTargetThumb"===e&&(h.vector2.angle||h.vector2.distance)?(p=h.vector2.distance,f=h.vector2.angle,h.vector2={distance:t.distance(u,o),angle:z.findAngle(u,o)},this.translateSubsequentSegment(t,s,!1,h.vector2.distance-p,h.vector2.angle-f)):("ConnectorSourceEnd"===e&&!t.sourceID||"ConnectorTargetEnd"===e&&!t.targetID)&&a&&QI(h.vector1)&&QI(h.vector2)?(z.isEmptyPoint(h.point1)&&(h.bezierPoint1=GI(t.sourcePoint,t.targetPoint)),z.isEmptyPoint(h.point2)&&(h.bezierPoint2=GI(t.targetPoint,t.sourcePoint))):"BezierSourceThumb"===e||"ConnectorSourceEnd"===e&&!a&&QI(h.vector1)?(h.bezierPoint1.x+=i,h.bezierPoint1.y+=r,(!z.isEmptyPoint(h.point1)||a)&&(h.point1={x:h.bezierPoint1.x,y:h.bezierPoint1.y})):("BezierTargetThumb"===e||"ConnectorTargetEnd"===e&&!a&&QI(h.vector2))&&(h.bezierPoint2.x+=i,h.bezierPoint2.y+=r,(!z.isEmptyPoint(h.point2)||a)&&(h.point2={x:h.bezierPoint2.x,y:h.bezierPoint2.y}))},n.prototype.translateSubsequentSegment=function(t,e,i,r,s){var o=t.segments.indexOf(e);parseInt(o.toString(),10),t.bezierSettings.smoothness&mI.SymmetricAngle||(s=null),t.bezierSettings.smoothness&mI.SymmetricDistance||(r=null),(null!=r||null!=s)&&(i?0!==o&&this.updatePreviousBezierSegment(t,o,r,s):o!==t.segments.length-1&&this.updateNextBezierSegment(t,o,r,s))},n.prototype.updatePreviousBezierSegment=function(t,e,i,r){var s=t.segments[e-1],a=(s.vector2.angle+r)%360;a<0&&(a+=360),s.vector2={distance:s.vector2.distance+i,angle:a}},n.prototype.updateNextBezierSegment=function(t,e,i,r){var s=t.segments[e+1],a=(s.vector1.angle+r)%360;a<0&&(a+=360),s.vector1={distance:s.vector1.distance+i,angle:a}},n.prototype.dragTargetEnd=function(t,e,i,r,s,o,a,l){var c,h=this.diagram.nameTable[t.id],d=this.checkBoundaryConstraints(e,i,h.wrapper.bounds);if(TI(h)&&"BezierTargetThumb"!==o&&d&&Vv(this.diagram)){if(c=$(c={targetPoint:h.targetPoint}),h.targetPoint.x+=e,h.targetPoint.y+=i,"ConnectorTargetEnd"===o&&"Orthogonal"===h.type&&h.segments&&h.segments.length>0){var u=h.segments[h.segments.length-2];u&&2===h.segments[h.segments.length-1].points.length&&("Left"===u.direction||"Right"===u.direction?u.points[u.points.length-1].x=h.targetPoint.x:u.points[u.points.length-1].y=h.targetPoint.y,u.length=z.distancePoints(u.points[0],u.points[u.points.length-1]),u.direction=z.direction(u.points[0],u.points[u.points.length-1]))}"Bpmn"===h.shape.type&&"Default"===h.shape.sequence&&"Sequence"===h.shape.flow&&this.updatePathElementOffset(h)}if("Bezier"===h.type)if(c={targetPoint:h.targetPoint},l)this.translateBezierPoints(t,""===o?"ConnectorTargetEnd":o,e,i,l,s,!a);else for(var p=0;p0){if(void 0!==s&&o.segments[parseInt(s.toString(),10)])if("Bezier"===o.type){var a=o.segments[parseInt(s.toString(),10)],l=a.isInternalSegment;l&&null!==o.bezierSettings&&"FreeForm"!==o.bezierSettings.segmentEditOrientation?("Horizontal"===a.orientation?a.point.x+=e:a.point.y+=i,this.updateDirectionalBezierCurve(o)):(a.point.x+=e,a.point.y+=i),l&&(o.isBezierEditing=!0)}else o.segments[parseInt(s.toString(),10)].point.x+=e,o.segments[parseInt(s.toString(),10)].point.y+=i;else for(var h=0;h1){var a=e[1],l=e[2],h={x:.5*(a.x+l.x),y:.5*(a.y+l.y)},c=t.segments[0];c.vector1.angle=Xt(s,a),c.vector1.distance=.5*z.findLength(s,a),c.vector2.angle=Xt(h,a),c.vector2.distance=.5*z.findLength(h,a),c.point=h;var d=t.segments[1];if(d.vector1.angle=Xt(h,l),d.vector1.distance=.5*z.findLength(h,l),t.segments.length>2){var u=e[3],p={x:.5*(l.x+u.x),y:.5*(l.y+u.y)};d.vector2.angle=Xt(p,l),d.vector2.distance=.5*z.findLength(p,l),d.point=p;var f=t.segments[2];if(f.vector1.angle=Xt(p,u),f.vector1.distance=.5*z.findLength(p,u),t.segments.length>3){var g=e[4],v={x:.5*(u.x+g.x),y:.5*(u.y+g.y)};f.vector2.angle=Xt(v,u),f.vector2.distance=.5*z.findLength(v,u),f.point=v;var y=t.segments[3];y.vector1.angle=Xt(v,g),y.vector1.distance=.5*z.findLength(v,g),y.vector2.angle=Xt(o,g),y.vector2.distance=.5*z.findLength(o,g)}else f.vector2.angle=Xt(o,u),f.vector2.distance=.5*z.findLength(o,u)}else d.vector2.angle=Xt(o,l),d.vector2.distance=.5*z.findLength(o,l)}},n.prototype.rotateObjects=function(t,e,i,r,s){r=r||{};var o=Hi();qi(o,i,r.x,r.y);for(var l=0,h=e;l0){this.diagram.protectPropertyChange(!0);var o=t;o.segments=[],this.diagram.connectorPropertyChange(o,{},{segments:o.segments}),this.diagram.protectPropertyChange(!1)}}},n.prototype.updateInnerParentProperties=function(t){var r=this.diagram.isProtectedOnChange;this.diagram.protectPropertyChange(!0);for(var s=this.getAllDescendants(t,[],!1,!0),o=0;o0&&(p=this.diagram.bpmnModule.getChildrenBound(d,d.id,this.diagram),u=d.wrapper.bounds.containsRect(p)),h=d.wrapper.actualSize.width*t,c=d.wrapper.actualSize.height*e,void 0!==d.maxWidth&&0!==d.maxWidth&&(h=Math.min(d.maxWidth,h)),void 0!==d.minWidth&&0!==d.minWidth&&(h=Math.max(d.minWidth,h)),void 0!==d.maxHeight&&0!==d.maxHeight&&(c=Math.min(d.maxHeight,c)),void 0!==d.minHeight&&0!==d.minHeight&&(c=Math.max(d.minHeight,c)),u&&(h=Math.max(h,p.right-d.wrapper.bounds.x),c=Math.max(c,p.bottom-d.wrapper.bounds.y)),t=h/d.actualSize.width,e=c/d.actualSize.height}var f=Hi();o||(o=r);var g=o.wrapper;if(qi(f,-g.rotateAngle,i.x,i.y),Wp(f,t,e,i.x,i.y),qi(f,g.rotateAngle,i.x,i.y),r instanceof te){var d,v=Je(f,{x:(d=r).wrapper.offsetX,y:d.wrapper.offsetY}),y=d.wrapper.offsetX-d.wrapper.actualSize.width*d.pivot.x,S=d.wrapper.offsetY-d.wrapper.actualSize.height*d.pivot.y;if(h>0)if(d.processId){var b=this.diagram.nameTable[d.processId];(!b.maxWidth||d.margin.left+h0)if(d.processId){var M=this.diagram.nameTable[d.processId];(!M.maxHeight||d.margin.top+c0){if(e.dragLimit=e.dragLimit?e.dragLimit:{},e.dragLimit.top||e.dragLimit.bottom||e.dragLimit.left||e.dragLimit.right){var b={minDistance:null};S=this.getRelativeOffset(v,d,b);var M={minDistance:null};g=this.getRelativeOffset(v,y,M),S=null!=b&&M.minDistance0){if(S=y[y.length-1]){var b=void 0;for(b=0;b=e.x-t.dragLimit.left-r.width/2&&i.x<=e.x+t.dragLimit.right+r.width/2&&(s=!0),i.y>=e.y-t.dragLimit.top-r.height/2&&i.y<=e.y+t.dragLimit.bottom+r.height/2&&(o=!0),{x:s,y:o}},n.prototype.updateLabelMargin=function(t,e,i,r,s,o,a){if(i=i||{x:e.offset,y:0},e&&i&&i.x>0&&i.x<1){var l=z.getLengthFromListOfPoints(t.intermediatePoints),h=this.getPointAtLength(l*i.x,t.intermediatePoints,0),c=this.diagram.scrollSettings.currentZoom,d=e.dragLimit?e.dragLimit:{left:0,right:0,top:0,bottom:0};if(d.top||d.bottom||d.left||d.right){this.diagram.getWrapper(t.wrapper,e.id);var p=new Ne(0,0,0,0),f=this.diagram.getWrapper(t.wrapper,e.id);p.x=f.offsetX/c+o,p.y=f.offsetY/c+a,p.width=f.bounds.width/c,p.height=f.bounds.height/c;var g=new Ne(h.x-(d.left||0)-p.width/2,h.y-(d.top||0)-p.height/2,(d.left||0)+(d.right||0)+p.width,(d.top||0)+(d.bottom||0)+p.height);if(g.containsPoint(r));else for(var S=0,b=this.boundsInterSects([h,r],g,!1);S=t){c=t-r,d=z.findAngle(s,a),u=c*Math.cos(d*Math.PI/180),p=c*Math.sin(d*Math.PI/180),o={x:s.x+u,y:s.y+p};break}r+=h,s=a}else s=a;return o},n.prototype.getInterceptWithSegment=function(t,e){for(var o,a,i=[],r=[],s=[],l=z.findLength({x:0,y:0},{x:this.diagram.scroller.viewPortWidth,y:this.diagram.scroller.viewPortHeight}),h=1;h0&&a<=90||a>180&&a<=270?90:-90;r.push(z.transform(t,a+c,l)),r.push(z.transform(t,o+c,l));var p=em({x1:s[0].x,y1:s[0].y,x2:s[1].x,y2:s[1].y},{x1:r[0].x,y1:r[0].y,x2:r[1].x,y2:r[1].y});p.enabled&&i.push(p.intersectPt)}return i},n.prototype.getAnnotationChanges=function(t,e){var r={};return r[tb(t,e.id,!0)]={width:e.width,height:e.height,offset:t instanceof te?{x:e.offset.x,y:e.offset.y}:e.offset,rotateAngle:e.rotateAngle,margin:{left:e.margin.left,right:e.margin.right,top:e.margin.top,bottom:e.margin.bottom},horizontalAlignment:e.horizontalAlignment,verticalAlignment:e.verticalAlignment,alignment:t instanceof de?e.alignment:void 0},{annotations:r}},n.prototype.getConnectorPortChanges=function(t,e){var i=function kse(n,t,e){for(var i=n.ports,r=0;r1&&(v.width=g,v.offset.x=1/S),f>1&&(v.height=f,v.offset.y=1/b)}}e instanceof Nr&&(e.alignment="Center"),l=this.getAnnotationChanges(t,e),t instanceof te?this.diagram.nodePropertyChange(t,a,l):this.diagram.connectorPropertyChange(t,a,l),this.diagram.updateDiagramObject(t)},n.prototype.getSubProcess=function(t){var i,e={nodes:[],connectors:[]};return t instanceof te?i=t.processId:t&&t.nodes&&t.nodes.length&&t.nodes[0].processId&&(i=t.nodes[0].processId),i&&e.nodes.push($(this.diagram.nameTable[i])),e},n.prototype.checkBoundaryConstraints=function(t,e,i,r){var s=this.diagram.pageSettings,o=this.diagram.pageSettings.boundaryConstraints,a=this.diagram.scroller;if("Page"===o||"Diagram"===o){var l=i?void 0:this.diagram.selectedItems.wrapper.bounds;return!!((i?i.right:l.right)+(t||0)<=("Page"===o?s.width:a.viewPortWidth)&&(i?i.left:l.left)+(t||0)>=0&&(i?i.bottom:l.bottom)+(e||0)<=("Page"===o?s.height:a.viewPortHeight)&&(i?i.top:l.top)+(e||0)>=0||"None"!==this.diagram.layout.type&&r)}return!0},n.prototype.dragSelectedObjects=function(t,e){var i=this,r=this.diagram.selectedItems;this.state&&!this.state.backup&&(this.state.backup={},this.state.backup.offsetX=r.offsetX,this.state.backup.offsetY=r.offsetY),r=UI(this.diagram,r)||r;var s=this.diagram.selectedItems.nodes.filter(function(c){return"SwimLane"===c.shape.type});if(s.length>0&&!this.diagram.currentSymbol&&this.diagram.selectedItems.nodes.length>1){var o=this.diagram.selectedItems.nodes.filter(function(c){return""===c.parentId||"SwimLane"!==i.diagram.nameTable[c.parentId].shape.type});if(o.length>0){for(var a=0;a0||l.length>1)&&(o=o.concat(l),this.diagram.selectedItems.nodes.splice(0,this.diagram.selectedItems.nodes.length),o.forEach(function(c){i.diagram.selectedItems.nodes.push(c)}),r=this.diagram.selectedItems,this.diagram.selectedObject.helperObject=void 0)}}if(this.checkBoundaryConstraints(t,e)){this.diagram.diagramActions=this.diagram.diagramActions|ee.PreventZIndexOnDragging|ee.DragUsingMouse;var h=this.diagram.selectedObject.actualObject;return(h&&h instanceof te&&h.isLane&&Vx(h,this.diagram)||!h||!h.isLane)&&this.diagram.drag(r,t,e),this.diagram.diagramActions=this.diagram.diagramActions&~(ee.PreventZIndexOnDragging|ee.DragUsingMouse),this.diagram.refreshCanvasLayers(),this.checkHtmlObjectDrag(r),!0}return!1},n.prototype.checkHtmlObjectDrag=function(t){var e=!1;this.diagram.views&&this.diagram.views.length>1&&(t instanceof oi?e=t.nodes.some(function(i){return i.shape&&"HTML"===i.shape.type}):t.shape&&"HTML"===t.shape.type&&(e=!0),e&&this.resetOverviewCanvas())},n.prototype.resetOverviewCanvas=function(){for(var t=0,e=this.diagram.views;t0&&(this.layoutAnimateModule.stopCurrentAnimation(this.objectStore[0],e,t),this.objectStore=[]),a=this.diagram.doLayout(),this.objectStore.push(a)),this.canUpdateTemplate=!1,this.diagram.blazorActions&=~on.expandNode,this.diagram.preventNodesUpdate=r,this.diagram.layoutAnimateModule&&this.diagram.organizationalChartModule&&!i)this.diagram.allowServerDataBinding=!1,this.layoutAnimateModule.expand(this.diagram.layout.enableAnimation,a,t,this.diagram);else{var l={element:$(t),state:!!t.isExpanded};this.triggerEvent(Ce.expandStateChange,l),this.diagram.lineRoutingModule&&this.diagram.constraints&rt.LineRouting&&"ComplexHierarchicalTree"!==this.diagram.layout.type&&this.diagram.resetSegments()}return this.diagram.layout.fixedNode=""===o?"":this.diagram.layout.fixedNode,a},n.prototype.getparentexpand=function(t,e,i,r){for(var s,o=0;o0&&(this.diagram.selectedItems.wrapper.rotateAngle=this.diagram.selectedItems.rotateAngle=s.rotateAngle),r instanceof te&&"SwimLane"!==r.shape.type&&!r.isLane&&!r.isPhase&&!r.isHeader)(r.offsetX!==r.wrapper.offsetX||r.offsetY!==r.wrapper.offsetY||r.width!==r.wrapper.width||r.height!==r.wrapper.height||r.rotateAngle!==r.wrapper.rotateAngle)&&(r.offsetX+=o,r.offsetY+=a,r.width+=l,r.height+=h,r.rotateAngle+=c,this.diagram.nodePropertyChange(r,{},{offsetX:r.offsetX,offsetY:r.offsetY,width:r.width,height:r.height,rotateAngle:r.rotateAngle})),e=this.diagram.spatialSearch.findObjects(r.wrapper.outerBounds);else if(r instanceof oi)for(var d=0;d30||g.wrapper.outerBounds.topCenter.y-f.wrapper.outerBounds.bottomCenter.y>30)&&this.diagram.lineRoutingModule.refreshConnectorSegments(this.diagram,p,!0)}}this.updateSelector(),this.diagram.protectPropertyChange(!1)}},n.prototype.drawSelectionRectangle=function(t,e,i,r){this.diagram.drawSelectionRectangle(t,e,i,r)},n.prototype.startGroupAction=function(){this.diagram.startGroupAction()},n.prototype.endGroupAction=function(){this.diagram.endGroupAction()},n.prototype.removeChildFromBPmn=function(t,e,i){var r=this.diagram.nameTable[t.id]||t.nodes[0];if(i&&r&&r.processId&&r.processId===i.wrapper.id){var s=$(r);s.processId=r.processId,this.diagram.startGroupAction();var o=this.diagram.nameTable[r.processId].shape.activity.subProcess.processes||[];o.splice(o.indexOf(r.id),1),this.diagram.bpmnModule.removeChildFromBPMN(this.diagram.nameTable[r.processId].wrapper,r.id,this.diagram),this.diagram.nameTable[r.id].processId="",r.offsetX=r.wrapper.offsetX,r.offsetY=r.wrapper.offsetY;var a=$(r);this.addHistoryEntry({type:"PositionChanged",redoObject:{nodes:[a]},undoObject:{nodes:[s]},category:"Internal"}),this.diagram.endGroupAction()}},n.prototype.isDroppable=function(t,e){var i=this.diagram.nameTable[t.id]||t.nodes[0];return i instanceof te&&(!ce()&&"TextAnnotation"===i.shape.shape||("Group"===e.shape.shape&&(e.shape.activity.subProcess.collapsed=!1),!(i&&"Bpmn"===i.shape.type&&(i.processId===e.id||i.id===e.processId||"Bpmn"===e.shape.type&&!(e instanceof de)&&e.shape.activity&&e.shape.activity.subProcess&&e.shape.activity.subProcess.collapsed))))},n.prototype.renderHighlighter=function(t,e,i){if(new Ne,t.target instanceof te||t.target instanceof de||e&&(t.source instanceof te||t.source instanceof de)){var a=this.findTarget(e?t.sourceWrapper:t.targetWrapper,e?t.source:t.target,i,!0),l=void 0;if(a instanceof zd)for(var h=a.id,c=t.target,u=0,p=c.wrapper.children[0].children[0].children[2].children;u0){var r=0;t[0]=this.diagram.nameTable[t[0].id]||t[0];var s="Object"===i?yr(t[0].wrapper):this.diagram.selectedItems.wrapper.bounds,o={nodes:[],connectors:[]},a={nodes:[],connectors:[]};for(r="Object"===i?r+1:r;r0){var i=0,r=0,s=0,o=0,a=0,l=0,h=0,c=0,d={nodes:[],connectors:[]},u={nodes:[],connectors:[]};for(i=0;io.center.y&&(r=n[parseInt(e.toString(),10)],n[parseInt(e.toString(),10)]=n[parseInt(i.toString(),10)],n[parseInt(i.toString(),10)]=r):s.center.x>o.center.x&&(r=n[parseInt(e.toString(),10)],n[parseInt(e.toString(),10)]=n[parseInt(i.toString(),10)],n[parseInt(i.toString(),10)]=r)}}return n}(t,e),i=1;i0){var i=0,r={x:.5,y:.5};t[0]=this.diagram.nameTable[t[0].id]||t[0];var s=yr(t[0].wrapper),o={nodes:[],connectors:[]},a={nodes:[],connectors:[]};for(i=1;ii.zIndex){for(var s=this.diagram.layers.indexOf(this.diagram.getActiveLayer()),o=this.diagram.layers[parseInt(s.toString(),10)].zIndexTable,a=JSON.parse(JSON.stringify(o)),l=i.zIndex,h=r.zIndex,c=h;c>=l;c--)l!==c?o[c-1]?(o[parseInt(c.toString(),10)]=o[c-1],this.diagram.nameTable[o[parseInt(c.toString(),10)]].zIndex=c):(o[c-1]=o[parseInt(c.toString(),10)],this.diagram.nameTable[o[c-1]].zIndex=c,delete o[parseInt(c.toString(),10)]):this.swapZIndexObjects(h,o,r.id,a);"SVG"===this.diagram.mode?(this.moveSvgNode(e.parentId,i.id),this.updateNativeNodeIndex(e.parentId,i.id)):this.diagram.refreshCanvasLayers()}},n.prototype.findLeastIndexConnector=function(t,e,i){for(var r=0;rs.zIndex&&(i=s)}return i},n.prototype.findLeastIndexObject=function(t,e){var i=t;return t instanceof te&&(i=this.findLeastIndexConnector(t.inEdges,e,i),i=this.findLeastIndexConnector(t.outEdges,e,i)),i},n.prototype.checkSelection=function(t,e){var i;if(1===t.nodes.length&&0===t.connectors.length)if(cs(this.diagram,t.nodes[0],!0)){var r=t.nodes[0];if("SwimLane"===(i="SwimLane"===t.nodes[0].shape?t.nodes[0]:this.diagram.nameTable[t.nodes[0].parentId]).shape.type){var s="Horizontal"===i.shape.orientation;(r.isPhase&&(s&&"ResizeSouth"===e||!s&&"ResizeEast"===e)||r.isLane&&(s&&"ResizeEast"===e||!s&&"ResizeSouth"===e))&&B3(this.diagram,i,e)}else if("Grid"===i.container.type)if("Horizontal"===i.container.orientation&&1===r.rowIndex||"Vertical"===i.container.orientation&&r.rowIndex>0&&r.columnIndex>0){if("ResizeSouth"===e)for(var o=0;o1&&(this.diagram.realActions=this.diagram.realActions|$i.hScrollbarMoved,this.scrolled=!0),this.diagram.scrollSettings.horizontalOffset=t},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"verticalOffset",{get:function(){return this.vOffset},set:function(t){this.vOffset=t,Math.abs(this.vOffset-this.diagram.scrollSettings.verticalOffset)>1&&(this.diagram.realActions=this.diagram.realActions|$i.vScrollbarMoved,this.scrolled=!0),this.diagram.scrollSettings.verticalOffset=t},enumerable:!0,configurable:!0}),n.prototype.getBounds=function(){var e=this.diagram.spatialSearch.getPageBounds(0,0);return(e.x<0||e.y<0)&&!this.diagram.pageSettings.multiplePage?this.getPageBounds(void 0,void 0,!0,!0):this.getPageBounds(void 0,void 0,!0)},n.prototype.updateScrollOffsets=function(t,e){var i,r,s=this.getBounds();s.x*=this.currentZoom,s.y*=this.currentZoom,s.width*=this.currentZoom,s.height*=this.currentZoom,i=Math.max(0,t-s.left),r=Math.max(0,e-s.top),void 0!==t&&void 0!==e?(this.horizontalOffset=i,this.verticalOffset=r,this.diagram.setOffset(i,r)):this.diagram.setOffset(-this.horizontalOffset-s.x,-this.verticalOffset-s.y),this.transform={tx:Math.max(this.horizontalOffset,-s.left)/this.currentZoom,ty:Math.max(this.verticalOffset,-s.top)/this.currentZoom,scale:this.currentZoom}},n.prototype.setScrollOffset=function(t,e){this.scrolled=!1;var i=this.getBounds();i.x*=this.currentZoom,i.y*=this.currentZoom,i.width*=this.currentZoom,i.height*=this.currentZoom;var r=-i.left,s=-i.top,o=!1,a=this.viewPortWidth*this.currentZoom,l=this.viewPortHeight*this.currentZoom,h=r-t;if(h!==this.horizontalOffset){rh?this.horizontalOffset-=t:this.horizontalOffset=h,o=!0);var c=Math.max(i.right+this.vScrollSize,a);if(!o&&c<-h+this.viewPortWidth){var d=-h+a-this.vScrollSize,u=-this.horizontalOffset+a-this.vScrollSize;this.horizontalOffset=dd-u?h:-(i.right+this.vScrollSize-a),o=!0}o||(this.horizontalOffset=r-t)}o=!1;var p=s-e;if(p!==this.verticalOffset){sp?this.verticalOffset-=e:this.verticalOffset=p,o=!0);var f=Math.max(i.bottom+this.hScrollSize,l);if(!o&&f<-p+l){var g=-p+l-this.hScrollSize,v=-this.verticalOffset+l-this.hScrollSize;this.verticalOffset=gg-v?p:-(i.bottom+this.hScrollSize-l),o=!0}o||(this.verticalOffset=s-e)}this.transform={tx:Math.max(this.horizontalOffset,-i.left)/this.currentZoom,ty:Math.max(this.verticalOffset,-i.top)/this.currentZoom,scale:this.currentZoom},this.setSize()},n.prototype.getObjects=function(t,e){for(var i=[],r=0;r0){for(var l=0;l0){h.push(i[parseInt(o.toString(),10)].id);for(var d=0;d=e.bottom&&(l=0),-this.horizontalOffset<=e.x&&-this.horizontalOffset+this.viewPortWidth>=e.right&&(a=0),this.hScrollSize=a,this.vScrollSize=l;var h=this.diagramWidth,c=this.diagramHeight;this.diagramWidth=Math.max(e.right,-this.horizontalOffset+this.viewPortWidth-l)-i,this.diagramHeight=Math.max(e.bottom,-this.verticalOffset+this.viewPortHeight-a)-r,(h!==this.diagramWidth||c!==this.diagramHeight)&&"Diagram"!==this.diagram.scrollSettings.scrollLimit&&this.diagram.setSize(this.diagramWidth,this.diagramHeight),"Diagram"===this.diagram.scrollSettings.scrollLimit&&(h===this.diagramWidth&&c===this.diagramHeight&&1===this.currentZoom||this.diagram.diagramActions&&t&&(!this.diagram.diagramActions||!t||0===this.verticalOffset&&this.verticalOffset!==t.y||0===this.horizontalOffset&&this.horizontalOffset!==t.x)?t&&h===this.diagramWidth&&c===this.diagramHeight&&(this.diagram.diagramCanvas.scrollHeight>this.viewPortHeight&&t.y<0&&this.horizontalOffset===t.x&&0===this.verticalOffset||this.diagram.diagramCanvas.scrollWidth>this.viewPortWidth&&t.x<0&&this.verticalOffset===t.y&&0===this.horizontalOffset)&&(this.verticalOffset=t.y,this.horizontalOffset=t.x,this.transform={tx:Math.max(t.x,-e.left)/this.currentZoom,ty:Math.max(t.y,-e.top)/this.currentZoom,scale:this.currentZoom}):(this.diagram.scrollActions&ca.Interaction&&t&&(this.transform={tx:Math.max(t.x,-e.left/this.currentZoom)/this.currentZoom,ty:Math.max(t.y,-e.top/this.currentZoom)/this.currentZoom,scale:this.currentZoom},this.horizontalOffset=t.x,this.verticalOffset=t.y),this.diagram.setSize(this.diagramWidth,this.diagramHeight),!(this.diagram.scrollActions&ca.PropertyChange)&&t&&(this.horizontalOffset=t.x,this.verticalOffset=t.y,this.transform={tx:Math.max(t.x,-e.left)/this.currentZoom,ty:Math.max(t.y,-e.top)/this.currentZoom,scale:this.currentZoom}))),this.diagram.transformLayers(),this.diagram.element.style.overflow="hidden"},n.prototype.setViewPortSize=function(t,e){this.viewPortWidth=t,this.viewPortHeight=e},n.prototype.getPageBounds=function(t,e,i,r){var o,s=new Ne;if("Content"===e||r||null===this.diagram.pageSettings.width||null===this.diagram.pageSettings.height){var u=t?void 0:0;o=this.diagram.spatialSearch.getPageBounds(u,u)}else{var a=this.diagram.pageSettings.width,l=this.diagram.pageSettings.height,h=0,c=0;if(this.diagram.pageSettings.multiplePage){if((s=this.diagram.spatialSearch.getPageBounds(0,0)).right>a&&(a*=d=Math.ceil(s.right/a)),s.bottom>l&&(l*=d=Math.ceil(s.bottom/l)),s.left<0&&Math.abs(s.left)>h){var d=Math.ceil(Math.abs(s.left)/this.diagram.pageSettings.width);h=this.diagram.pageSettings.width*d}s.top<0&&Math.abs(s.top)>c&&(d=Math.ceil(Math.abs(s.top)/this.diagram.pageSettings.height),c=this.diagram.pageSettings.height*d)}o=new Ne(-h,-c,a+h,l+c)}if(i){var p=this.diagram.scrollSettings.padding;o.x-=p.left,o.y-=p.top,o.width+=p.left+p.right,o.height+=p.top+p.bottom}return o},n.prototype.getPageBreak=function(t){for(var e=0,i=0,r=-1,s=[],c=this.diagram.pageSettings.margin.left,d=this.diagram.pageSettings.margin.right,u=this.diagram.pageSettings.margin.top,p=this.diagram.pageSettings.margin.bottom,f=1,g=1;t.width>e;)(e+=this.diagram.pageSettings.width?this.diagram.pageSettings.width:t.width)===this.diagram.pageSettings.width&&(s[++r]={x1:t.left+c,y1:t.top+u,x2:t.left+c,y2:t.bottom-p}),ei;)(i+=this.diagram.pageSettings.height?this.diagram.pageSettings.height:t.height)===this.diagram.pageSettings.height&&(s[++r]={x1:t.left+c,y1:t.top+u,x2:t.right-d,y2:t.top+u}),i=this.diagram.scrollSettings.minZoom||l||t>=1)){this.currentZoom*=t;var c=this.getPageBounds(void 0,void 0,!0);c.x*=this.currentZoom,c.y*=this.currentZoom;var d=Hi();Wp(d,t,t,r.x,r.y),ZB(d,e||0,i||0),yx(h,d);var u=Je(h,{x:0,y:0});if(1===t&&(u=this.applyScrollLimit(u.x,u.y,s,o,a)),a=-c.y>=u.y&&-c.x>=u.x&&a,(this.diagram.scrollActions&ca.PropertyChange||!(this.diagram.scrollActions&ca.Interaction)||"Diagram"!==this.diagram.scrollSettings.scrollLimit||a)&&(this.transform={tx:Math.max(u.x,-c.left)/this.currentZoom,ty:Math.max(u.y,-c.top)/this.currentZoom,scale:this.currentZoom},this.horizontalOffset=u.x,this.verticalOffset=u.y),this.setSize(u),"SVG"!==this.diagram.mode&&Ds(this.diagram)&&this.diagram.scroller.virtualizeElements(),"SVG"!==this.diagram.mode&&!Ds(this.diagram)&&this.diagram.refreshDiagramLayer(),this.diagram.setOffset(-this.horizontalOffset-c.x,-this.verticalOffset-c.y),XI(this.diagram),this.diagram.views&&this.diagram.views.overview){var p=this.diagram.views.overview,f=p.scrollOverviewRect(p.parent.scroller.horizontalOffset,p.parent.scroller.verticalOffset,p.parent.scroller.currentZoom,!0);p.updateOverviewrect(-f.x,-f.y,f.width,f.height),p.updateView(p)}}}},n.prototype.fitToPage=function(t){var e=(t=t||{}).mode,i=t.region,r=t.margin||{},s=t.canZoomIn,o=t.customBounds,a=t.canZoomOut;r.bottom=r.bottom||25,r.top=r.top||25,r.left=r.left||25,r.right=r.right||25;var h,l=o,c=-this.horizontalOffset,d=-this.verticalOffset;if("PageSettings"===(i=i||"PageSettings")&&this.diagram.pageSettings.width&&this.diagram.pageSettings.height||this.diagram.nodes.length>0||this.diagram.connectors.length>0){e=e||"Page","CustomBounds"!==i&&(l=this.getPageBounds(!0,i,!0));var u={x:0,y:0};r.left+r.right>this.viewPortWidth&&(this.viewPortWidth<=100?(r.left=5,r.right=5):(r.left=25,r.right=25)),r.top+r.bottom>this.viewPortHeight&&(this.viewPortHeight<=100?(r.top=5,r.bottom=5):(r.top=25,r.bottom=25)),u.x=(this.viewPortWidth-(r.left+r.right))/l.width,u.y=(this.viewPortHeight-(r.top+r.bottom))/l.height,!s&&l.width-this.horizontalOffset-a+this.viewPortWidth&&(i=o.right-this.viewPortWidth,i+=20),o.x<-a&&(i=o.x),o.bottom>-l+this.viewPortHeight&&(r=o.bottom-this.viewPortHeight,r+=20),o.y<-l&&(r=o.y),this.zoom(1,-this.horizontalOffset-i,-this.verticalOffset-r,null,void 0,e))},n.prototype.bringToCenter=function(t){var e=this.currentZoom,i=new Ne(t.x*e,t.y*e,t.width*e,t.height*e),r=i.x+i.width/2-this.viewPortWidth/2,s=i.y+i.height/2-this.viewPortHeight/2;this.zoom(1,-this.horizontalOffset-(r*=-1),-this.verticalOffset-(s*=-1),null)},n.prototype.applyScrollLimit=function(t,e,i,r,s){if("Infinity"===this.diagram.scrollSettings.scrollLimit&&void 0===i&&!r&&(t=-t,e=-e),"Infinity"!==this.diagram.scrollSettings.scrollLimit){var o=void 0;if("Limited"===this.diagram.scrollSettings.scrollLimit){var a=this.diagram.scrollSettings.scrollableArea;o=new Ne(a.x,a.y,a.width,a.height)}(o=o||(s?this.getPageBounds():this.getPageBounds(!0))).x*=this.currentZoom,o.y*=this.currentZoom,o.width*=this.currentZoom,o.height*=this.currentZoom,void 0!==i&&(t*=-1,e*=-1),r&&(t*=-1,e*=-1);var l=Math.max(o.right,this.viewPortWidth);if(!r&&!(t<=o.x&&(t+this.viewPortWidth>=o.right||t>=o.right-this.viewPortWidth)||t>=o.x&&t+this.viewPortWidth<=l))if(t>=o.x)t=Math.max(o.x,Math.min(t,t-(t+this.viewPortWidth-this.vScrollSize-l)));else{var h=o.right-this.viewPortWidth;t=Math.min(h,o.x)}var c=Math.max(o.bottom,this.viewPortHeight);r||e<=o.y&&e+this.viewPortHeight>=o.bottom||e>=o.y&&e+this.viewPortHeight<=c||(e>=o.y?e=Math.max(o.y,Math.min(e,e-(e+this.viewPortHeight-this.hScrollSize-c))):(h=o.bottom-this.viewPortHeight,e=Math.min(o.y,h))),t*=-1,e*=-1}return{x:t,y:e}},n}(),Woe=function(){function n(t,e,i,r,s){this.objects=[],this.left=t,this.top=e,this.width=i,this.height=r,this.spatialSearch=s}return n.prototype.findQuads=function(t,e){null!=this.first&&this.first.isIntersect(t)&&this.first.findQuads(t,e),null!=this.second&&this.second.isIntersect(t)&&this.second.findQuads(t,e),null!=this.third&&this.third.isIntersect(t)&&this.third.findQuads(t,e),null!=this.fourth&&this.fourth.isIntersect(t)&&this.fourth.findQuads(t,e),this.objects.length>0&&e.push(this)},n.prototype.isIntersect=function(t){return!(this.left+this.widtht.right||this.top>t.bottom)},n.prototype.selectQuad=function(){for(var i,t=null,e=this;null!=e;)i=e.getQuad(t),e=i.source,t=i.target||t;return t},n.prototype.getQuad=function(t){var e=this.width/2,i=this.height/2;if(e>=1e3&&i>=1e3){var r=this.left+e,s=this.top+i;if(this.spatialSearch.childRight<=r){if(this.spatialSearch.childBottom<=s)return this.first||((o=new n(this.left,this.top,e,i,this.spatialSearch)).parent=this,this.first=o),{source:this.first};if(this.spatialSearch.childTop>=s)return this.third||((o=new n(this.left,s,e,i,this.spatialSearch)).parent=this,this.third=o),{source:this.third}}else if(this.spatialSearch.childLeft>=r){if(this.spatialSearch.childBottom<=s)return this.second||((o=new n(r,this.top,e,i,this.spatialSearch)).parent=this,this.second=o),{source:this.second};var o;if(this.spatialSearch.childTop>=s)return this.fourth||((o=new n(r,s,e,i,this.spatialSearch)).parent=this,this.fourth=o),{source:this.fourth}}}return this.objects.push(this.spatialSearch.childNode),{target:this}},n.prototype.isContained=function(){return this.spatialSearch.childLeft>=this.left&&this.spatialSearch.childRight<=this.left+this.width&&this.spatialSearch.childTop>=this.top&&this.spatialSearch.childBottom<=this.top+this.height},n.prototype.addIntoAQuad=function(t){var e={};this.spatialSearch.setCurrentNode(t);for(var i=null;!e.isAdded;)i=(e=this.spatialSearch.parentQuad.add(i)).quad;return i},n.prototype.add=function(t){if(t=null,this.isContained())return{isAdded:!0,quad:t=this.selectQuad()};var e=void 0,i=!(0!==this.objects.length||this.first||this.second||this.third||this.fourth),r=2*this.width,s=2*this.height;return this.spatialSearch.childLeft=this.childLeft?(this.pageLeft=this.childLeft,this.leftElement=t,r=!0):t===this.leftElement&&(this.pageLeft=Number.MAX_VALUE,this.findLeft(this.parentQuad),r=!0)),(this.pageTop!==this.childTop||t!==this.topElement)&&(this.pageTop>=this.childTop?(this.pageTop=this.childTop,this.topElement=t,r=!0):t===this.topElement&&(this.pageTop=Number.MAX_VALUE,this.findTop(this.parentQuad),r=!0)),(this.pageBottom!==this.childBottom||t!==this.bottomElement)&&(this.pageBottom<=this.childBottom?(r=!0,this.pageBottom=this.childBottom,this.bottomElement=t):t===this.bottomElement&&(this.pageBottom=-Number.MAX_VALUE,this.findBottom(this.parentQuad),r=!0)),(this.pageRight!==this.childRight||t!==this.rightElement)&&(this.pageRight<=this.childRight?(this.pageRight=this.childRight,this.rightElement=t,r=!0):t===this.rightElement&&(this.pageRight=-Number.MAX_VALUE,this.findRight(this.parentQuad),r=!0)),r}return this.setCurrentNode(null),!1},n.prototype.isWithinPageBounds=function(t){return t.left>=this.pageLeft&&t.right<=this.pageRight&&t.top>=this.pageTop&&t.bottom<=this.pageBottom},n.prototype.findQuads=function(t){var e=[];return this.parentQuad.findQuads(t,e),e},n.prototype.findObjects=function(t){for(var i=[],r=0,s=this.findQuads(t);r=r.outerBounds.left&&(this.pageLeft=r.outerBounds.left,this.leftElement=r)}},n.prototype.findTop=function(t){t.first||t.second?(t.first&&this.findTop(t.first),t.second&&this.findTop(t.second)):(t.third&&this.findTop(t.third),t.fourth&&this.findTop(t.fourth));for(var e=0,i=t.objects;e=r.outerBounds.top&&(this.pageTop=r.outerBounds.top,this.topElement=r)}},n.prototype.setCurrentNode=function(t){if(this.childNode=t,t){var e=t.outerBounds;this.childLeft=Number(e.left),this.childTop=Number(e.top),this.childRight=Number(e.right),this.childBottom=Number(e.bottom)}else this.childLeft=Number.MAX_VALUE,this.childTop=Number.MAX_VALUE,this.childRight=-Number.MAX_VALUE,this.childBottom=-Number.MAX_VALUE},n.prototype.getPageBounds=function(t,e){if(this.pageLeft===Number.MAX_VALUE)return new Ne(0,0,0,0);var i=void 0!==t?Math.min(this.pageLeft,0):this.pageLeft,r=void 0!==e?Math.min(this.pageTop,0):this.pageTop;return new Ne(Math.round(i),Math.round(r),Math.round(this.pageRight-i),Math.round(this.pageBottom-r))},n.prototype.getQuad=function(t){return this.quadTable[t.id]},n}(),Yoe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Goe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Yoe(t,n),function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);r>3&&s&&Object.defineProperty(t,e,s)}([I(!1)],t.prototype,"preventDefaults",void 0),t}(Ee),Xoe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),e_=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},qoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Xoe(t,n),e_([I("")],t.prototype,"action",void 0),e_([I("")],t.prototype,"cursor",void 0),t}(Ee),t_=function(){function n(){this.size=20,this.intermediatePoints=[],this.gridCollection=[],this.startArray=[],this.targetGridCollection=[],this.sourceGridCollection=[],this.considerWalkable=[]}return n.prototype.lineRouting=function(t){var e=t.connectors.length;if(this.renderVirtualRegion(t),e>0)for(var i=0;i=t.right||e.right<=t.left||e.top>=t.bottom||e.bottom<=t.top)},n.prototype.findEndPoint=function(t,e,i){var r,s;if(e&&""!==t.sourcePortID&&t.sourcePortWrapper||!e&&""!==t.targetPortID&&t.targetPortWrapper){s=zo(r=e?{x:t.sourcePortWrapper.offsetX,y:t.sourcePortWrapper.offsetY}:{x:t.targetPortWrapper.offsetX,y:t.targetPortWrapper.offsetY},void 0,e?t.sourceWrapper.bounds:t.targetWrapper.bounds);var o=e?t.sourcePortWrapper.bounds:t.targetPortWrapper.bounds;r=i?"Top"===s?{x:o.topCenter.x,y:o.topCenter.y}:"Left"===s?{x:o.middleLeft.x,y:o.middleLeft.y}:"Right"===s?{x:o.middleRight.x,y:o.middleRight.y}:{x:o.bottomCenter.x,y:o.bottomCenter.y}:{x:o.center.x,y:o.center.y}}else r=e&&this.startNode||!e&&this.targetNode?e?{x:this.startNode.wrapper.offsetX,y:this.startNode.wrapper.offsetY}:{x:this.targetNode.wrapper.offsetX,y:this.targetNode.wrapper.offsetY}:e?{x:t.sourcePoint.x,y:t.sourcePoint.y}:{x:t.targetPoint.x,y:t.targetPoint.y};return r},n.prototype.refreshConnectorSegments=function(t,e,i,r){var h,c,p,f,g,y,S,b,M,w,C,s=e.sourceID,o=e.targetID,a=e.sourcePortID,l=e.targetPortID;if(function Ure(n,t){var e=0;return n.constraints&qe.LineRouting?e=n.constraints&qe.LineRouting:n.constraints&qe.InheritLineRouting&&(e=t.constraints&rt.LineRouting),e}(e,t)||r){this.startNode=t.nameTable[""+s],this.targetNode=t.nameTable[""+o],this.intermediatePoints=[],this.startArray=[],this.targetGridCollection=[],this.sourceGridCollection=[],this.startGrid=void 0,this.targetGrid=void 0;for(var D=0;D0;){var L=this.startArray.pop();if(L){for(D=0;D1&&(e.segments=[]),this.updateConnectorSegments(t,this.intermediatePoints,this.gridCollection,e,i)){this.considerWalkable=[];break e}this.targetGridCollection.splice(this.targetGridCollection.indexOf(O),1),L=this.startArray.pop()}}L&&this.findPath(L)}}}},n.prototype.checkChildNodes=function(t,e){var i=!1,r=!1;if(t.nodeId.length>=1&&!e)for(var s=0;s1&&this.targetGridCollection[0].nodeId.length>1)for(var c=0;c<=1;c++){for(var d=this.targetGridCollection[parseInt(c.toString(),10)].gridX,u=this.targetGridCollection[parseInt(c.toString(),10)].gridY,p=this.targetGridCollection[parseInt(c.toString(),10)].nodeId,f=void 0,g=0;g=e.right&&t.top<=e.top&&t.bottom>=e.bottom},n.prototype.getEndvalue=function(t,e){return this.gridCollection[t.gridX][t.gridY].walkable?t:"left"===e?this.getEndvalue(this.gridCollection[t.gridX-1][t.gridY],e):"right"===e?this.getEndvalue(this.gridCollection[t.gridX+1][t.gridY],e):"top"===e?this.getEndvalue(this.gridCollection[t.gridX][t.gridY-1],e):"bottom"===e?this.getEndvalue(this.gridCollection[t.gridX][t.gridY+1],e):t},n.prototype.changeValue=function(t,e,i){t.walkable||this.considerWalkable.push(t);for(var r,s=0;s<=e;s++)"left"===i?r=this.gridCollection[t.gridX-s][t.gridY]:"right"===i?r=this.gridCollection[t.gridX+s][t.gridY]:"top"===i?r=this.gridCollection[t.gridX][t.gridY-s]:"bottom"===i&&(r=this.gridCollection[t.gridX][t.gridY+s]),r.walkable||this.considerWalkable.push(r)},n.prototype.getIntermediatePoints=function(t){var e;for(this.intermediatePoints=[];t;)this.intermediatePoints.push({x:t.gridX,y:t.gridY}),t=t.parent;this.intermediatePoints.reverse(),this.intermediatePoints.length>=1&&void 0!==this.intermediatePoints[0]&&void 0!==this.intermediatePoints[1]&&(this.intermediatePoints[0].x===this.intermediatePoints[1].x?this.intermediatePoints[0].y=1&&u.length>1&&(g=u[u.length-2].x!==u[u.length-1].x?u[u.length-2].x>u[u.length-1].x?"Left":"Right":u[u.length-2].y>u[u.length-1].y?"Top":"Bottom"),M>=2&&v===g&&u.length>1&&u.splice(u.length-2,1),v=g);if(u&&u.length>1){for(var w=0;wD.x?S.bounds.middleLeft:S.bounds.middleRight),w===u.length-2&&""===r.targetPortID&&y&&(l=C.x>D.x?y.bounds.middleRight:y.bounds.middleLeft),0===w&&b&&(C.x=b.x,C.y=D.y=b.y),w===u.length-2&&l&&(w>0&&r.targetDecorator&&l.x-D.x<0&&Math.abs(l.x-C.x)0&&r.targetDecorator&&l.x-D.x>0&&Math.abs(l.x-C.x)D.y?S.bounds.topCenter:S.bounds.bottomCenter),w===u.length-2&&""===r.targetPortID&&y&&(l=C.y>D.y?y.bounds.bottomCenter:y.bounds.topCenter),0===w&&b&&(C.y=b.y,C.x=D.x=b.x),w===u.length-2&&l&&(w>0&&r.targetDecorator&&l.y-D.y<0&&Math.abs(l.y-C.y)0&&r.targetDecorator&&l.y-D.y>0&&Math.abs(l.y-C.y)D.x?(p="Left",f=C.x-D.x):(p="Right",f=D.x-C.x):C.y>D.y?(p="Top",f=C.y-D.y):(p="Bottom",f=D.y-C.y),o.push({type:"Orthogonal",length:f,direction:p})}}if(o&&o.length>0){var A=o[o.length-1];if(1===o.length&&(A.length-=20),A.length<10&&2===o.length&&(o.pop(),o.length>0&&(o[0].length-=20,A=o[0])),r.targetDecorator&&("Top"===A.direction||"Bottom"===A.direction)&&A.length>r.targetDecorator.height+1||("Right"===A.direction||"Left"===A.direction)&&A.length>r.targetDecorator.width+1)return r.segments=o,s&&t.connectorPropertyChange(r,{},{type:"Orthogonal",segments:o}),!0}return!1},n.prototype.findPath=function(t){for(var e,i=[],r=this.findNearestNeigbours(t,this.gridCollection,!0),s=0;sl)&&(e.x!==t.gridX||e.y!==t.gridY)&&(i.push(e),o.previousDistance=l,o.afterDistance=o.afterDistance||this.manhattan(Math.abs(e.x-this.targetGrid.gridX),Math.abs(e.y-this.targetGrid.gridY)),o.totalDistance=o.previousDistance+o.afterDistance,o.parent=t)}if(i.length>0)for(s=0;st?i*t+e:i*e+t},n.prototype.manhattan=function(t,e){return t+e},n.prototype.findNearestNeigbours=function(t,e,i){var r=[],s=t.parent;if(s){var o=(t.gridX-s.gridX)/Math.max(Math.abs(t.gridX-s.gridX),1),a=(t.gridY-s.gridY)/Math.max(Math.abs(t.gridY-s.gridY),1);0!==o?(this.isWalkable(t.gridX,t.gridY-1,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX][t.gridY-1])&&r.push(e[t.gridX][t.gridY-1]),this.isWalkable(t.gridX,t.gridY+1,!0)&&this.sourceGridCollection.indexOf(e[t.gridX][t.gridY+1])&&r.push(e[t.gridX][t.gridY+1]),this.isWalkable(t.gridX+o,t.gridY,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX+o][t.gridY])&&r.push(e[t.gridX+o][t.gridY])):0!==a&&(this.isWalkable(t.gridX-1,t.gridY,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX-1][t.gridY])&&r.push(e[t.gridX-1][t.gridY]),this.isWalkable(t.gridX+1,t.gridY,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX+1][t.gridY])&&r.push(e[t.gridX+1][t.gridY]),this.isWalkable(t.gridX,t.gridY+a,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX][t.gridY+a])&&r.push(e[t.gridX][t.gridY+a]))}else this.neigbour(t,"top",r,i),this.neigbour(t,"right",r,i),this.neigbour(t,"bottom",r,i),this.neigbour(t,"left",r,i);return r},n.prototype.neigbour=function(t,e,i,r){for(var o,s=1;s>0;){var a="top"===e||"bottom"===e?t.gridX:"left"===e?t.gridX-s:t.gridX+s,l="right"===e||"left"===e?t.gridY:"top"===e?t.gridY-s:t.gridY+s;if((o=this.gridCollection[parseInt(a.toString(),10)][parseInt(l.toString(),10)])&&(r&&-1===this.sourceGridCollection.indexOf(o)||!r&&-1===this.targetGridCollection.indexOf(o)))return i&&this.isWalkable(a,l)&&i.push(o),s;if(!(a>0&&l>0))break;s++}return null},n.prototype.resetGridColl=function(t,e,i){for(var s,r=1;r>0;){var o="top"===e||"bottom"===e?t.gridX:"left"===e?t.gridX-r:t.gridX+r,a="right"===e||"left"===e?t.gridY:"top"===e?t.gridY-r:t.gridY+r;if((s=this.gridCollection[parseInt(o.toString(),10)][parseInt(a.toString(),10)])&&(i&&-1===this.sourceGridCollection.indexOf(s)||!i&&-1===this.targetGridCollection.indexOf(s))){if(this.isWalkable(o,a))break;var l=this.gridCollection[parseInt(o.toString(),10)][parseInt(a.toString(),10)];this.considerWalkable.push(l)}if(!(o>0&&a>0))break;"top"===e||"left"===e?r--:r++}return null},n.prototype.isWalkable=function(t,e,i){if(t>=0&&t=0&&e0?1:-1,this.isWalkable(h,c-1)&&!this.isWalkable(h-a,c-1)||this.isWalkable(h,c+1)&&!this.isWalkable(h-a,c+1)))return{x:t,y:e};if(0!==l){if(l=l>0?1:-1,this.isWalkable(h-1,c)&&!this.isWalkable(h-1,c-l)||this.isWalkable(h+1,c)&&!this.isWalkable(h+1,c-l))return{x:t,y:e};if(this.findIntermediatePoints(h+1,c,h,c,s,o)||this.findIntermediatePoints(h-1,c,h,c,s,o))return{x:t,y:e}}return this.findIntermediatePoints(h+a,c+l,h,c,s,o)},n.prototype.destroy=function(){},n.prototype.getModuleName=function(){return"LineRouting"},n}(),$oe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Joe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return $oe(t,n),function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);r>3&&s&&Object.defineProperty(t,e,s)}([I(!0)],t.prototype,"inversedAlignment",void 0),t}(Ee),Koe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Oe=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},CT=function(n,t,e,i){return new(e||(e=Promise))(function(r,s){function o(h){try{l(i.next(h))}catch(c){s(c)}}function a(h){try{l(i.throw(h))}catch(c){s(c)}}function l(h){h.done?r(h.value):new e(function(c){c(h.value)}).then(o,a)}l((i=i.apply(n,t||[])).next())})},ET=function(n,t){var i,r,s,o,e={label:0,sent:function(){if(1&s[0])throw s[1];return s[1]},trys:[],ops:[]};return o={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function a(h){return function(c){return function l(h){if(i)throw new TypeError("Generator is already executing.");for(;e;)try{if(i=1,r&&(s=2&h[0]?r.return:h[0]?r.throw||((s=r.return)&&s.call(r),0):r.next)&&!(s=s.call(r,h[1])).done)return s;switch(r=0,s&&(h=[2&h[0],s.value]),h[0]){case 0:case 1:s=h;break;case 4:return e.label++,{value:h[1],done:!1};case 5:e.label++,r=h[1],h=[0];continue;case 7:h=e.ops.pop(),e.trys.pop();continue;default:if(!(s=(s=e.trys).length>0&&s[s.length-1])&&(6===h[0]||2===h[0])){e=0;continue}if(3===h[0]&&(!s||h[1]>s[0]&&h[1]0&&((!s.style||!s.style.fill)&&(o.style.fill="transparent"),(!s.style||!s.style.strokeColor)&&(o.style.strokeColor="transparent")),s.shape&&"UmlActivity"===s.shape.type&&ZI(s,o),s.shape&&"SwimLane"===s.shape.type&&aF(s,o),r.nodeDefaults&&Ro(o,s,r.nodeDefaults),r.updateAnnotationText(o.annotations);if(e&&e.connectors)for(a=0;e&&e.connectors&&a0&&0===i.nodes.length)this.clearCollection(),a=!0;else{for(var g=0,v=Object.keys(e.nodes);g0&&0===i.connectors.length)this.clearCollection(!0),a=!0;else{for(var C=0,D=Object.keys(e.connectors);C0){this.renderSelector(!0);break}if(e.selectedItems.constraints){this.renderSelector(!0);break}break;case"snapSettings":this.updateSnapSettings(e);break;case"commandManager":this.initCommands();break;case"layout":o=!0;break;case"segmentThumbShape":this.updateSelector();break;case"dataSourceSettings":this.clear(),"None"===this.layout.type?a=!0:(this.initObjects(),o=!0);break;case"tooltip":i3(this);break;case"rulerSettings":this.updateRulerSettings(e);break;case"layers":this.updateLayer(e);break;case"scrollSettings":this.scrollActions|=ca.PropertyChange,this.updateScrollSettings(e),this.scrollActions&=~ca.PropertyChange,this.scrollSettings.horizontalOffset=-this.scroller.horizontalOffset||0,this.scrollSettings.verticalOffset=-this.scroller.verticalOffset||0;break;case"locale":e.locale!==i.locale&&(this.realActions|=$i.PreventDataInit,n.prototype.refresh.call(this),this.realActions&=~$i.PreventDataInit);break;case"contextMenuSettings":if(void 0!==e.contextMenuSettings.showCustomMenuOnly&&(this.contextMenuSettings.showCustomMenuOnly=e.contextMenuSettings.showCustomMenuOnly),void 0!==e.contextMenuSettings.show&&(this.contextMenuSettings.show=e.contextMenuSettings.show),e.contextMenuSettings.items){for(var A=e.contextMenuSettings.items,x=0,R=Object.keys(A);x0){for(var N=[],T=O.ports.length-1;T>=0;T--)"LineDistribution"===O.ports[parseInt(T.toString(),10)].id.split("_")[1]&&N.push(O.ports[parseInt(T.toString(),10)]);this.removePorts(O,N)}}for(T=0;T0)for(var ue=0,pe=Object.keys(e.nodes);ue0)for(var De=0,xe=Object.keys(e.connectors);De=0;o--)this.commandHandler.expandNode(r[parseInt(o.toString(),10)],this,0!==o);this.canLayout&&this.doLayout(),this.lineRoutingModule?this.connectors.sourceID!==this.connectors.targetID&&this.lineRoutingModule.lineRouting(this):this.constraints&rt.LineRouting&&console.warn('[WARNING] :: Module "LineRouting" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),this.validatePageSize(),this.renderPageBreaks(),this.diagramRenderer.renderSvgGridlines(this.snapSettings,Bd(this.element.id),this.scroller.transform,this.rulerSettings,this.hRuler,this.vRuler),this.commandHandler.initSelectorWrapper(),this.notify("initial-load",{}),this.trigger("load"),this.scroller.setSize(),this.scroller.updateScrollOffsets(),this.isRefreshed||this.refreshDiagramLayer(),(this.scrollSettings.verticalOffset>0||this.scrollSettings.horizontalOffset>0)&&this.updateScrollOffset(),X.isDevice&&(this.tool=Ci.ZoomPan|Ci.SingleSelect),this.notify("initial-end",{}),this.isProtectedOnChange=!1,this.tooltipObject=i3(this),this.diagramActions=ee.Render,this.initCommands();var a=document.getElementsByClassName(this.element.id+"_hiddenUserHandleTemplate");(function Ioe(n,t,e,i){var r,s,o,a,l,d=document.getElementById(i).ej2_instances[0];if(n&&t){r=UF(n);for(var u=0,p=e.userHandles;u0;)e[0].parentNode.removeChild(e[0]);var i=document.getElementById(this.element.id+"content");i&&this.element.removeChild(i);var r="measureElement";if(window[""+r]){window[""+r].usageCount-=1;var s="measureElementCount";window[""+s]--,0===window[""+s]&&(window[""+r].parentNode.removeChild(window[""+r]),window[""+r]=null)}}window.domTable={};for(var a=0;a1&&(this.callBlazorModel=!1,this.insertBlazorDiagramObjects(this.selectedItems),this.commandHandler.group(),this.callBlazorModel=!0,this.commandHandler.getBlazorOldValues())},t.prototype.unGroup=function(){this.callBlazorModel=!1,this.insertBlazorDiagramObjects(this.selectedItems),this.commandHandler.unGroup(),this.callBlazorModel=!0,this.commandHandler.getBlazorOldValues()},t.prototype.sendToBack=function(){this.commandHandler.sendToBack()},t.prototype.setActiveLayer=function(e){var i=this.commandHandler.getLayer(e);this.activeLayer=i},t.prototype.addLayer=function(e,i){this.commandHandler.addLayer(e,i)},t.prototype.removeLayer=function(e){this.commandHandler.removeLayer(e,ce())},t.prototype.moveObjects=function(e,i){$(this.layers),this.enableServerDataBinding(!1),this.commandHandler.moveObjects(e,i)},t.prototype.layerObjectUpdate=function(){},t.prototype.sendLayerBackward=function(e){this.layerObjectUpdate(),this.commandHandler.sendLayerBackward(e)},t.prototype.bringLayerForward=function(e){this.layerObjectUpdate(),this.commandHandler.bringLayerForward(e)},t.prototype.cloneLayer=function(e){this.commandHandler.cloneLayer(e)},t.prototype.bringToFront=function(){this.commandHandler.bringToFront()},t.prototype.moveForward=function(){this.commandHandler.sendForward()},t.prototype.sendBackward=function(){this.commandHandler.sendBackward()},t.prototype.getObject=function(e){return this.nameTable[""+e]},t.prototype.getNodeObject=function(e){return $(this.nameTable[""+e])},t.prototype.getConnectorObject=function(e){return $(this.nameTable[""+e])},t.prototype.getActiveLayer=function(){return this.activeLayer},t.prototype.nudgeCommand=function(e,i,r){if("object"!=typeof e&&(this.selectedItems.nodes.length||this.selectedItems.connectors.length)>0){var s=void 0;i.type&&"KEYDOWN"===i.type&&(s=i.type),this.nudge(e,void 0,void 0,s)}},t.prototype.nudge=function(e,i,r,s){var o=0,a=0;"Left"===e||"Right"===e?o=("Left"===e?-1:1)*(i||1):a=("Up"===e?-1:1)*(r||1),"KEYDOWN"===s&&(o*=5,a*=5);var h=this.selectedItems,c=this.selectedItems.wrapper.children[0];if(c instanceof si)this.commandHandler.labelDrag(h.nodes[0],c,o,a);else{var d=$(this.selectedItems);this.protectPropertyChange(!0),this.drag(h,o,a),this.protectPropertyChange(!1);var u={type:"PositionChanged",redoObject:$(this.selectedItems),undoObject:d,category:"Internal"};this.addHistoryEntry(u)}this.refreshCanvasLayers()},t.prototype.insertBlazorDiagramObjects=function(e){},t.prototype.drag=function(e,i,r){if(this.insertBlazorDiagramObjects(e),!(this.bpmnModule&&e instanceof te&&this.bpmnModule.updateAnnotationDrag(e,this,i,r))){if(e instanceof oi){if(this.preventConnectorsUpdate=!0,e.nodes&&e.nodes.length){for(var o=0,a=e.nodes;o0&&o.nodes[0].children){this.fromUndo||(this.rotateUsingButton=!0);for(var h=this.commandHandler.getAllDescendants(o.nodes[0],[]),c=0;c0&&o.nodes[0].children){var g={type:"RotationChanged",redoObject:$(e),undoObject:$(o),category:"Internal",childTable:a};this.commandHandler.addHistoryEntry(g),this.commandHandler.updateSelector()}return u},t.prototype.dragSourceEnd=function(e,i,r){this.insertBlazorDiagramObjects(e),this.commandHandler.dragSourceEnd(e,i,r),this.callBlazorModel&&this.commandHandler.getBlazorOldValues()},t.prototype.dragTargetEnd=function(e,i,r){this.insertBlazorDiagramObjects(e),this.commandHandler.dragTargetEnd(e,i,r),this.callBlazorModel&&this.commandHandler.getBlazorOldValues()},t.prototype.findObjectsUnderMouse=function(e,i){return this.eventHandler.findObjectsUnderMouse(e,i)},t.prototype.findObjectUnderMouse=function(e,i,r){return this.eventHandler.findObjectUnderMouse(e,i,r)},t.prototype.findTargetObjectUnderMouse=function(e,i,r,s,o){return this.eventHandler.findTargetUnderMouse(e,i,r,s,o)},t.prototype.findElementUnderMouse=function(e,i,r,s){return this.eventHandler.findElementUnderMouse(e,i,r,s)},t.prototype.findActionToBeDone=function(e,i,r,s){return this.eventHandler.findActionToBeDone(e,i,r,s)},t.prototype.updateConnectorPort=function(e){if(e.ports.length)for(var i=void 0,r=0,s=e.ports;r=0;s--)if(i.push(r[parseInt(s.toString(),10)]),i.length>this.historyManager.stackLimit)return i}else i=r;return i},t.prototype.getEdges=function(e){return e.outEdge?this.nameTable[e.id].outEdges:this.nameTable[e.id].inEdges},t.prototype.getParentId=function(e){return this.nameTable[""+e].parentId},t.prototype.addConnector=function(e){return this.add(e)},t.prototype.UpdateBlazorDiagramModelCollection=function(e,i,r,s){},t.prototype.UpdateBlazorDiagramModel=function(e,i,r,s){},t.prototype.UpdateBlazorLabelOrPortObjects=function(e,i,r,s){},t.prototype.addBlazorDiagramObjects=function(){},t.prototype.removeNodeEdges=function(e,i,r){var s=this.nameTable[""+e],o=r?s.outEdges:s.inEdges;if(o.length>0)for(var a=0;a0)){for(var c=0;c0))}this.removePortEdges(l,a.element.sourcePortID,a.element.id,h)}a.element.targetID&&this.removeNodeEdges(a.element.targetID,a.element.id,!1)}}this.diagramActions=this.diagramActions|ee.PublicMethod,e.id=e.id||Qe();var u=this.activeLayer;if(!a.cancel&&u&&!u.lock){if(u.objects.indexOf(e.id)<0&&!u.lock&&(u.visible||(u.visible=!0,this.dataBind()),u.objects.push(e.id)),fs(e)===de)(r=new de(this,"connectors",e,!0)).status="New",this.nameTable[r.targetID]&&"TextAnnotation"===this.nameTable[r.targetID].shape.shape&&(r.isBpmnAnnotationConnector=!0,r.constraints=r.constraints&~qe.Delete),Ro(r,e,this.connectorDefaults),this.connectors.push(r),this.initObject(r),!1===e.visible&&this.updateElementVisibility(r.wrapper,r,e.visible),this.updateEdges(r),this.insertBlazorConnector(r);else{if(Ro(r=new te(this,"nodes",e,!0),e,this.nodeDefaults),r.parentId=e.parentId?e.parentId:r.parentId,r.umlIndex=e.umlIndex,r.status="New",(o="TextAnnotation"===r.shape.shape)&&!e.isTextAnnotationCopied&&(r.inEdges=e.inEdges?e.inEdges:r.inEdges),this.nodes.push(r),this.initObject(r,u,void 0,i),o&&this.bpmnModule)for(c=0;c-1&&e.parentId&&this.nameTable[e.parentId]&&"UmlClassifier"===this.nameTable[e.parentId].shape.type){var g=this.nameTable[e.parentId];g.children.splice(r.umlIndex,0,r.id),g.wrapper.children.splice(r.umlIndex,0,r.wrapper),g.wrapper.measure(new me),g.wrapper.arrange(g.wrapper.desiredSize),this.updateDiagramObject(g)}}if(a={element:r,cause:this.diagramActions,diagramAction:this.getDiagramAction(this.diagramActions),state:"Changed",type:"Addition",cancel:!1},this.parentObject&&(a.parentId=this.parentObject.id),"helper"!==e.id&&!(this.diagramActions&ee.PreventCollectionChangeOnDragOver)&&this.triggerEvent(Ce.collectionChange,a),!(this.diagramActions&ee.UndoRedo||this.diagramActions&ee.Group||this.diagramActions&ee.PreventHistory)){var v={type:"CollectionChanged",changeType:"Insert",undoObject:$(e),redoObject:$(e),category:"Internal"};this.addHistoryEntry(v)}this.parentObject=void 0,"SVG"===this.mode&&(this.updateSvgNodes(r),this.updateTextElementValue(r),this.updateDiagramObject(r),o&&this.updateDiagramObject(this.nameTable[r.inEdges[0]]),r.shape.activity&&r.shape.activity.subProcess.processes&&r.shape.activity.subProcess.processes.length&&this.updateProcesses(r),this.updateBridging())}}if(this.protectPropertyChange(s),this.resetDiagramActions(ee.PublicMethod),r&&this.layers.length>1&&this.moveNode(r),this.views)for(var S=0,b=this.views;S=0;l--)this.moveSvgNode(a[parseInt(l.toString(),10)])}for(var h=0,c=i;h=0;o--)r[parseInt(o.toString(),10)]===e.id&&r.splice(o,1);for(var a=0;s.ports&&a=0;s--)if(i=this.nameTable[r[parseInt(s.toString(),10)]])if(this.connectorTable[i.id]=$(i),i.isBpmnAnnotationConnector){var o=this.nameTable[i.targetID];this.removeObjectsFromLayer(i);var a=this.connectors.indexOf(i);-1!==a&&this.connectors.splice(a,1),this.removeElements(i),this.removeFromAQuad(i),delete this.nameTable[i.id];var l=this.nameTable[i.sourceID];if(l){var h=l.outEdges.indexOf(i.id);-1!==h&&l.outEdges.splice(h,1)}e.id!==i.targetID&&this.remove(o)}else this.remove(i)},t.prototype.removeObjectsFromLayer=function(e){if(e.children)for(var i=0;i-1&&(_r(this,e)&&this.unSelect(e),this.layers[parseInt(s.toString(),10)].objects.splice(a,1),delete this.layers[parseInt(s.toString(),10)].zIndexTable[this.nameTable[e.id].zIndex])},t.prototype.removeElements=function(e){if("SVG"===this.mode||"Canvas"===this.mode&&"Native"===e.shape.type){var i=xt(e.id+"_groupElement",this.element.id),r=e;if(r.ports&&r.ports.length>0)for(var s=0;s0){l[parseInt(s.toString(),10)].id.indexOf("icon_content")>0&&"SVG"===this.mode&&((h=xt(l[parseInt(s.toString(),10)].id+"_shape_groupElement",this.element.id))&&h.parentNode.removeChild(h),(h=xt(l[parseInt(s.toString(),10)].id+"_rect_groupElement",this.element.id))&&h.parentNode.removeChild(h));for(var c=0,d=this.views;c=0;o--)a.children[parseInt(o.toString(),10)].children&&(l=n.nameTable[a.children[parseInt(o.toString(),10)].id])&&(l.isLane?qv(n,l):(n.removeDependentConnector(l),n.diagramActions|=ee.PreventHistory,l.constraints&ie.Delete?n.remove(l):V3(n,l,{},!1),n.diagramActions&=~ee.PreventHistory));a&&(i=n.nameTable[a.id])&&qv(n,i)}}(this,e),!(this.diagramActions&ee.UndoRedo||this.diagramActions&ee.PreventHistory)&&(e instanceof te||e instanceof de)){var o={type:"CollectionChanged",changeType:"Remove",undoObject:$(e),redoObject:$(e),category:"Internal"};this.diagramActions&ee.Clear||e.children&&!e.isLane&&!e.isPhase&&e.children.length>0&&this.undoRedoModule&&"None"===this.layout.type&&(this.historyManager.startGroupAction(),s=!0),(e instanceof te||e instanceof de)&&this.deleteDependentConnector&&this.removeDependentConnector(e),!e.isLane&&!e.isPhase&&!(this.diagramActions&ee.Clear)&&!this.isStackChild(e)&&this.addHistoryEntry(o)}"TextAnnotation"===e.shape.shape&&this.removeDependentConnector(e),e.children&&!e.isLane&&!e.isPhase&&(!(this.diagramActions&ee.UndoRedo)||!ce())&&this.deleteGroup(e),e.parentId&&(this.deleteChild(e,void 0,!0),this.nameTable[e.parentId]&&"UmlClassifier"===this.nameTable[e.parentId].shape.type&&(this.updateDiagramObject(this.nameTable[e.parentId]),this.updateConnectorEdges(this.nameTable[e.parentId])));var a=void 0;this.diagramActions=this.diagramActions|ee.PublicMethod;var l=this.nameTable[e.id];if(l instanceof te?("Bpmn"===l.shape.type&&this.bpmnModule&&this.bpmnModule.removeBpmnProcesses(l,this),(l.isLane||l.isPhase||"SwimLane"===l.shape.type)&&(h=l.isLane||l.isPhase?this.nameTable[l.parentId]:this.nameTable[l.id],l.isLane?_3(this,l,h):l.isPhase&&U3(this,l,h)),-1!==(a=this.nodes.indexOf(l))&&(this.crudDeleteNodes.push(this.nameTable[l.id]),this.nodes.splice(a,1),this.updateNodeEdges(l))):(-1!==(a=this.connectors.indexOf(l))&&(this.crudDeleteNodes.push(this.nameTable[l.id]),this.connectors.splice(a,1)),this.updateEdges(l),this.spliceConnectorEdges(e,!0),this.spliceConnectorEdges(e,!1)),!this.isServerUpdate&&!(this.blazorActions&on.GroupClipboardInProcess)&&this.commandHandler.getBlazorOldValues(),s&&this.historyManager.endGroupAction(),_r(this,l)&&this.unSelect(l),!l.isPhase){if(this.removeObjectsFromLayer(e),this.currentDrawingObject&&(this.currentDrawingObject.wrapper=void 0),delete this.nameTable[e.id],i.length>0&&i[0].id===l.id&&l.parentId){var h,d=this.nameTable[l.parentId];d&&d.isLane&&"SwimLane"===this.nameTable[d.parentId].shape.type&&F3(this,h=this.nameTable[d.parentId],d,l)}this.removeElements(l),this.updateBridging(),"SVG"!==this.mode&&this.refreshDiagramLayer(),this.diagramActions&ee.Clear||(this.removeFromAQuad(l),r={element:e,cause:this.diagramActions,diagramAction:this.getDiagramAction(this.diagramActions),state:"Changed",type:"Removal",cancel:!1},"helper"!==e.id&&this.triggerEvent(Ce.collectionChange,r),this.resetTool())}}}else if(i.length>0){this.undoRedoModule&&(this.historyManager.startGroupAction(),this.blazorActions|=on.GroupingInProgress,s=!0);for(var u=0;u=f.wrapper.bounds.width&&"Horizontal"===f.shape.orientation||this.selectedItems.wrapper.bounds.y<=f.wrapper.bounds.y+g&&this.selectedItems.wrapper.bounds.height>=f.wrapper.bounds.height-g&&"Vertical"===f.shape.orientation)&&(DI(f)||f.shape.lanes.length>1)&&this.remove(i[parseInt(u.toString(),10)])}}else this.remove(i[parseInt(u.toString(),10)])}s&&(this.blazorActions&=~on.GroupingInProgress,this.isServerUpdate=!0,this.commandHandler.getBlazorOldValues(),this.UpdateBlazorDiagramModelCollection(void 0,void 0,void 0,!0),this.historyManager.endGroupAction(),this.isServerUpdate=!1),this.clearSelection()}e&&(DI(e)||this.diagramActions&ee.Clear)||this.diagramActions&ee.UndoRedo||this.diagramActions&ee.PreventHistory||!(e instanceof te||e instanceof de)||(o={type:"ConnectionChanged",undoObject:$(e),redoObject:$(e),category:"Internal"},!e.isLane&&!e.isPhase&&!(this.diagramActions&ee.Clear)&&!this.isStackChild(e)&&this.addHistoryEntry(o)),this.tooltipObject.close()},t.prototype.isStackChild=function(e){var i,r=this.nameTable[e.parentId];if(e&&e.parentId&&r.container&&"Stack"===r.container.type&&"UmlClassifier"!==this.nameTable[e.parentId].shape.type){i=!0;var s={sourceIndex:r.wrapper.children.indexOf(e.wrapper),source:e,target:void 0,targetIndex:void 0};this.diagramActions&ee.UndoRedo||this.addHistoryEntry({type:"StackChildPositionChanged",redoObject:{sourceIndex:void 0,source:e,target:void 0,targetIndex:void 0},undoObject:s,category:"Internal"})}return i},t.prototype.deleteChild=function(e,i,r){var s;if(s="string"==typeof e?e:e.id,(i=i?this.nameTable[i.id]:this.nameTable[e.parentId])&&i.children){for(var o=0;o=0;i--)this.removeLayer(this.layers[parseInt(i.toString(),10)].id);this.commandHandler.addLayer({id:"default_layer",visible:!0,lock:!1,objects:[],zIndex:0,objectZIndex:-1,zIndexTable:{}},null,!0),this.setActiveLayer(this.layers[this.layers.length-1].id)},t.prototype.clearObjects=function(e){var i=[];i=e||(i=i.concat(this.nodes)).concat(this.connectors),this.diagramActions=this.diagramActions|ee.Clear;for(var r=0,s=i;r0||"Text"===e.shape.type))if("Text"===e.shape.type)i=e.wrapper.children[0].id.split("_")[1];else for(var f=e.annotations.length-1;f>=0;f--)e.annotations[parseInt(f.toString(),10)].visibility&&(i=e.annotations[parseInt(f.toString(),10)].id);i&&(u=this.getWrapper(e.wrapper,i))}if(e&&u&&!(u instanceof Jn)&&(!function Xre(n,t){return"Text"===t.shape.type?t.constraints&ie.ReadOnly:t.constraints&(t instanceof de?qe.ReadOnly:ie.ReadOnly)?n.constraints&Lr.InheritReadOnly?1:0:n.constraints&Lr.ReadOnly?1:0}(u,e)||p)){var g=u.style,v=void 0;v=90>(v=u.bounds.width50?50:e.width,u.style.fontSize)),e.parentId&&"UmlClassifier"===this.nameTable[e.parentId].shape.type?(l.width=e.wrapper.bounds.width-20,c=(e.wrapper.bounds.center.x+r.tx)*r.scale-l.width/2*s-2.5,d=(e.wrapper.bounds.center.y+r.ty)*r.scale-l.height/2*s-3,u.style.textAlign="Left"):(l.width=Math.max(l.width,50),c=(u.bounds.center.x+r.tx)*r.scale-l.width/2*s-2.5,d=(u.bounds.center.y+r.ty)*r.scale-l.height/2*s-3),Ho(y,{id:this.element.id+"_editTextBoxDiv",style:"position: absolute;left:"+c+"px;top:"+d+"px;width:"+(l.width+1)*s+"px;height:"+l.height*s+"px; containerName:"+e.id+";"}),Ho(S,{"aria-label":a,id:this.element.id+"_editBox",style:"width:"+(l.width+1)*s+"px;height:"+l.height*s+"px;resize: none;outline: none;overflow: hidden;;font-family:"+g.fontFamily+";font-size:"+g.fontSize*s+"px;text-align:"+u.style.textAlign.toLocaleLowerCase()+";",class:"e-diagram-text-edit"}),S.style.fontWeight=g.bold?"bold":"",S.style.fontStyle=g.italic?"italic":"",S.style.lineHeight=(1.2*g.fontSize+"px;").toString(),S.style.textDecoration=g.textDecoration?g.textDecoration:"",this.activeLabel.parentId=e.id,this.activeLabel.id=i,u.visible=!1,this.updateDiagramObject(e),this.diagramActions=this.diagramActions|ee.TextEdit,this.isTriggerEvent||(E.add(S,"input",this.eventHandler.inputChange,this.eventHandler),E.add(S,"focusout",this.focusOutEdit,this),S.select())}}}},t.prototype.updateConnectorfixedUserHandles=function(e){if(e.fixedUserHandles.length)for(var i=void 0,r=0,s=e.fixedUserHandles;r0&&this.mindMapChartModule.updateLayout(o,this.nameTable,this.layout,l,this.dataSourceSettings.id,this.dataSourceSettings.root),e=!0;else if(this.radialTreeModule)this.radialTreeModule.updateLayout(o,this.nameTable,this.layout,l),e=!0;else if(this.symmetricalLayoutModule)this.symmetricalLayoutModule.maxIteration=this.layout.maxIteration,this.symmetricalLayoutModule.springLength=this.layout.springLength,this.symmetricalLayoutModule.springFactor=this.layout.springFactor,this.symmetricalLayoutModule.updateLayout(o,this.connectors,this.symmetricalLayoutModule,this.nameTable,this.layout,l),e=!0;else if(this.complexHierarchicalTreeModule){this.canDistribute(a,r)&&(this.lineDistributionModule.diagram=this,this.connectors.forEach(function(R){R.obstaclePointCollection=[]}));var c=this.complexHierarchicalTreeModule.getLayoutNodesCollection(this.nodes);c.length>0&&this.complexHierarchicalTreeModule.doLayout(c,this.nameTable,this.layout,l,this),e=!0,this.canDistribute(a,r)&&this.lineDistributionModule.initLineDistribution(this.layout,this)}else this.flowchartLayoutModule?(this.flowchartLayoutModule.updateLayout(this.nodes,this),e=!0):console.warn("[WARNING] :: Module "+("OrganizationalChart"===this.layout.type?"HierarchicalTree":this.layout.type)+" is not available in Diagram component! You either misspelled the module name or forgot to load it.");if(e){this.preventDiagramUpdate=!0;for(var u={},f=0,g=o;f0)for(var S=0;S0)for(var M=0;M0)for(var s=0,o=r.ports;s0&&function Ese(n){var t,e,i,r=[];for(t=0;t0&&y.connectors[w].bezierSettings&&y.connectors[w].bezierSettings.allowSegmentsReset&&(y.connectors[w].segments=[]);if(t.connectors=y.connectors||[],t.dataSourceSettings=y.dataSourceSettings||{},t.dataSourceSettings.doBinding=i,t.height=y.height||"100%",t.setNodeTemplate=r,t.getConnectorDefaults=v,t.getNodeDefaults=g,t.getCustomProperty=o,t.mode=y.mode||"SVG",y.nodes)for(w=0;w0)){var r=this.nodes.filter(function(a){return 0===a.inEdges.length})[0],s=this.convertMindmapToMermaid(r,0);i.push(s),this.updateTextDataSource(i,r.outEdges,1),e=(i=i.filter(function(a){return""!==a.trim()})).join("\n")}return e},t.prototype.updateTextDataSource=function(e,i,r){for(var s=0;s0&&this.updateTextDataSource(e,h,r+1),s++}},t.prototype.convertMindmapToMermaid=function(e,i){var r=e.id,o=" ".repeat(2*(i+1)),a=e.annotations.length>0?e.annotations[0].content.replace(/\n/g," "):"",l=o+a,h=o+r;if(e.shape&&"Basic"===e.shape.type){var c=e.shape;"Rectangle"===c.shape?l=h+"["+a+"]":"Ellipse"===c.shape?l=h+"(("+a+"))":"Hexagon"===c.shape&&(l=h+"{{"+a+"}}")}else if(e.shape&&"Flow"===e.shape.type)"Terminator"===e.shape.shape&&(l=h+"("+a+")");else if(e.shape&&"Path"===e.shape.type){var u=e.shape;u.data===this.bangShape?l=h+"))"+a+"((":u.data===this.cloudShape&&(l=h+")"+a+"(")}return l},t.prototype.saveFlowDiagramInMermaidFormat=function(){var e=this,i=[],r="graph TD\n",s={nodes:this.nodes,edges:this.connectors};return s.nodes.reduce(function(a,l){return a[l.id]=l.annotations.length?l.annotations[0].content:"",a},{}),s.edges.forEach(function(a){var l=a.sourceID,h=a.targetID,p=e.nameTable[""+h],f=e.getNodeShape(e.nameTable[""+l]),g=e.getNodeShape(p),v=a.annotations[0]&&""!==a.annotations[0].content?"|"+a.annotations[0].content+"|":"";-1===i.indexOf(l)?i.push(l):f="",-1===i.indexOf(h)?i.push(h):g="";var y=e.arrowType(a);r+=" "+l+f+" "+y+v+" "+h+g+"\n"}),s.nodes.forEach(function(a){r+=" style "+a.id+" fill:"+a.style.fill+",stroke:"+a.style.strokeColor+",stroke-width:"+a.style.strokeWidth+"px;\n"}),r},t.prototype.arrowType=function(e){var i=e.targetDecorator.shape;return e.style.opacity<1?"~~~":""!==e.style.strokeDashArray?"-.->":"Arrow"===i?e.style.strokeWidth>1?"==>":"--\x3e":"None"===i?"---":"--\x3e"},t.prototype.getNodeShape=function(e){var i=e.annotations.length>0?e.annotations[0].content:"",r=e.shape.shape;if(!r){var s=e.shape.data;return"M 0 0 A 1 1 0 0 0 7 0 A 1 1 0 0 0 0 0 M -1 0 A 1 1 0 0 0 8 0 A 1 1 0 0 0 -1 0"===s?"((("+i+")))":"M 0 0 L 1 -1 L 5 -1 L 6 0 L 0 0"===s?"[/"+i+"\\]":"M 0 1 L 0 6 C 2 7 4 7 6 6 L 6 1 C 5 0 1 0 0 1 C 1 2 5 2 6 1"===s?"[("+i+")]":"M 0 0 L 12 0 L 14 2 L 2 2 L 0 0"===s?"[\\"+i+"\\]":"M 0 0 L 5 0 L 4 1 L 1 1 L 0 0"===s?"[\\"+i+"/]":"M 0 0 L 2 -2 L 11 -2 L 13 0 L 11 2 L 2 2 L 0 0"===s?"{{"+i+"}}":">"+i+"]"}switch(r){case"Terminator":return"(["+i+"])";case"Process":default:return"["+i+"]";case"Decision":return"{"+i+"}";case"Parallelogram":return"[/"+i+"/]";case"Ellipse":return"(("+i+"))";case"PreDefinedProcess":return"[["+i+"]]"}},t.prototype.loadDiagramFromMermaid=function(e){this.layout&&"Flowchart"===this.layout.type&&this.flowchartLayoutModule?this.convertMermaidToFlowChart(e):this.layout&&"MindMap"===this.layout.type&&this.mindMapChartModule?this.convertMermaidToMindmap(e):console.warn('[WARNING] :: Module "FlowchartLayout" or "MindMap" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.countLeadingSpaces=function(e){for(var i=0,r=e.length;i0});this.clear(),this.mermaidNodeBaseCollection=[];var r=[],s={text:"",children:[],currentLevel:0,branch:"Left"},o=[],l=!1,h=!1,c=!1;if(i.length>0){for(var d=function(M){var w=i[parseInt(M.toString(),10)],C=0,D="",A=u.countLeadingSpaces(w),x=w.includes('"`');if(h=w.includes('`"'),c=(l=!!x||l)||c?c:0===A&&M>0,l&&h&&!x)return s.text+="\n"+w,l=!1,"continue";if(!x&&l)return s.text+="\n"+w,"continue";if(l=!h&&l,w.length>0&&(/\s/.test(w[0])&&M>0||0===A)){if(-1!==o.findIndex(function(B){return B.space===A.toString()}))for(var L=o.length-1;L>=0;L--){var O=o[parseInt(L.toString(),10)];if((N=parseFloat(O.space))>A)o.splice(L,1);else{if(N=0;L--){var N,T=o[parseInt(L.toString(),10)];if(!((N=parseFloat(T.space))>A)){var P=o[o.length-1];o.push({space:A.toString(),level:P.level+1});break}o.splice(L,1)}C=o[o.length-1].level}D=w.trim().replace(/^[+-]/,"")}var _={text:D,branch:void 0,children:[],currentLevel:0===M?0:C-1};if(r.length>0){for(;r.length>=C&&0!==r.length;)r.pop();r.length>0&&r[r.length-1].children.push(_)}r.push(_),s=_},u=this,p=0;p0){var c=h[h.length-1];c.arrowType=a[2],""!==a[3]&&(c.label&&c.label.some(function(d){return d.trim().length>0})?c.label.push(a[3]):(c.label=[],c.label[c.parentId.length-1]=a[3]))}h.filter(function(d){return d.parentId&&0===d.parentId.length}).forEach(function(d){d.parentId=null}),i=i.concat(h)}}this.createFlowChart(i),this.doLayout(),this.clearHistory()},t.prototype.createFlowChart=function(e){for(var i=[],r=0;r1)for(var h=0;h|---|--\s*.*?\s*-->|~~~|==>|===|==\s*.*?\s*==>|\s*-\.\s*->|\s*-\.\s*-|\s*-\.\s*.*?\s*\.\s*->|\s*-\..*?\.\s*->)(.*)$/);if(l){i=l[1].trim();var h=l[2].trim();r=l[3].trim();var d=h.match(/(-\.|\\-\\-|==|--|~~)(.*?)(\1>|\.->|==>|\\->|~~>)/),u=void 0,p="";o=null!==(u=d?{text:d[2].trim()||null,arrowType:d[1]+d[3]}:{text:null,arrowType:h}).text?u.text:"",s=(p=u.arrowType).includes("--\x3e")?"single-line-arrow":p.includes("---")?"single-line":p.includes("==>")?"double-line-arrow":p.includes("==")?"double-line":p.includes("~~~")?"wiggly-arrow":p.includes("-.->")||p.includes(".->")?"dotted-arrow":p.includes("-.-")||p.includes(".-")?"dotted":"single-line-arrow"}return[i,r,s,o]},t.prototype.parseStyle=function(e,i){if(e.startsWith("style")){var s=e.match(/^style\s+(\w+)\s+fill:([^,]+),stroke:([^,]+),stroke-width:(\d+)px;/);if(s){var c={id:s[1],fill:s[2],stroke:s[3],strokeWidth:parseInt(s[4],10)},d=i.filter(function(u){return u.id===c.id});d[0].color=c.fill,d[0].stroke=c.stroke,d[0].strokeWidth=c.strokeWidth}}},t.prototype.getNodeData=function(e,i,r){for(var s=[],o=null,a=null,l=0,h="",c=function(v){var y=e[parseInt(v.toString(),10)],S=d.splitNested(y);if(S[0].includes("|")){var b=S[0].match(/\|([^|]*)\|/);b&&(h=b[1]);var M=S[0].split("|");M.length>=3&&(S[0]=M[2].trim())}var w=S[0].trim();if(0===v?o=w:a=w,i.find(function(L){return L.id===w}))l++;else{var D=S.length>1?S[1]:S[0],A=d.getShape(D),x=D.replace(/[\\[\]\\(\\)\\{\\}\\{\\}\\/>]/g,"");s.push({id:w,name:x,shape:A,color:"white",parentId:[]})}},d=this,u=0;u"===h?0===s?(r.trim().length>0&&i.push(r.trim()),r=h,o=h,s++):(r+=h,s++):"]"===h||"}"===h||")"===h?1===s&&h===o?(i.push((r+=h).trim()),r="",s--):s>1?(r+=h,s--):r+=h:r+=h}return r.trim().length>0&&i.push(r.trim()),i},t.prototype.getShape=function(e){var i={};return e.startsWith("(((")?i={type:"Path",data:"M 0 0 A 1 1 0 0 0 7 0 A 1 1 0 0 0 0 0 M -1 0 A 1 1 0 0 0 8 0 A 1 1 0 0 0 -1 0"}:e.startsWith("((")?i={shape:"Ellipse",type:"Basic"}:e.startsWith("([")?i={type:"Flow",shape:"Terminator"}:e.startsWith("(")?i={type:"Flow",shape:"Process"}:e.startsWith("[[")?i={type:"Flow",shape:"PreDefinedProcess"}:e.startsWith("[/")?i=e.endsWith("/]")?{type:"Basic",shape:"Parallelogram"}:{type:"Path",data:"M 0 0 L 1 -1 L 5 -1 L 6 0 L 0 0"}:e.startsWith("[(")?i={type:"Path",data:"M 0 1 L 0 6 C 2 7 4 7 6 6 L 6 1 C 5 0 1 0 0 1 C 1 2 5 2 6 1"}:e.startsWith("[\\")?i=e.endsWith("\\]")?{type:"Path",data:"M 0 0 L 12 0 L 14 2 L 2 2 L 0 0"}:{type:"Path",data:"M 0 0 L 5 0 L 4 1 L 1 1 L 0 0"}:e.startsWith("[")?i={type:"Basic",shape:"Rectangle"}:e.startsWith("{{")?i={type:"Path",data:"M 0 0 L 2 -2 L 11 -2 L 13 0 L 11 2 L 2 2 L 0 0"}:e.startsWith("{")?i={type:"Flow",shape:"Decision"}:e.startsWith(">")&&(i={type:"Path",data:"M 0 0 L 8 0 L 8 2 L 0 2 L 2 1 L 0 0"}),i},t.prototype.getDiagramContent=function(e){return this.printandExportModule?this.printandExportModule.getDiagramContent(e):(console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),"")},t.prototype.exportImage=function(e,i){this.printandExportModule?this.printandExportModule.exportImages(e,i):console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.printImage=function(e,i){this.printandExportModule?(i.printOptions=!0,this.printandExportModule.exportImages(e,i)):console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.setStackLimit=function(e){this.undoRedoModule&&e&&(this.historyManager.stackLimit=e,this.undoRedoModule.applyLimit(this.historyManager.currentEntry,e,this,!0))},t.prototype.clearHistory=function(){this.undoRedoModule&&this.undoRedoModule.clearHistory(this)},t.prototype.getDiagramBounds=function(){if(this.printandExportModule){var e=this.printandExportModule.getDiagramBounds("",{});return e.width=e.width>this.scrollSettings.viewPortWidth?e.width+(e.x>0?e.x:0):this.scrollSettings.viewPortWidth,e.height=e.height>this.scrollSettings.viewPortHeight?e.height+(e.y>0?e.y:0):this.scrollSettings.viewPortHeight,e.x=e.x>0?0:e.x,e.y=e.y>0?0:e.y,e}return console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),new Ne},t.prototype.exportDiagram=function(e){return this.printandExportModule?this.printandExportModule.exportDiagram(e):(console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),"")},t.prototype.print=function(e){this.printandExportModule?this.printandExportModule.print(e):console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.addPorts=function(e,i){var s;this.protectPropertyChange(!0),e=this.nameTable[e.id]||e,i.length>1&&this.startGroupAction();for(var o=function(h){if(e.ports.some(function(y){return y.id===i[parseInt(h.toString(),10)].id}))return"continue";if(e instanceof te?(s=new Es(e,"ports",i[parseInt(h.toString(),10)],!0),e.ports.push(s)):e instanceof de&&(s=new xc(e,"ports",i[parseInt(h.toString(),10)],!0),e.ports.push(s)),e.children)for(var c=e.wrapper,d=0;d1&&this.endGroupAction(),e.wrapper.measure(new me(e.width,e.height)),e.wrapper.arrange(e.wrapper.desiredSize),this.updateDiagramObject(e),this.protectPropertyChange(!1)},t.prototype.addConstraints=function(e,i){return e|i},t.prototype.removeConstraints=function(e,i){return e&~i},t.prototype.addNodeLabels=function(e,i){this.addLabels(e,i)},t.prototype.addConnectorLabels=function(e,i){this.addLabels(e,i)},t.prototype.addLabels=function(e,i){this.protectPropertyChange(!0);var s,r=(e=this.nameTable[e.id]||e).wrapper;i.length>1&&this.startGroupAction();for(var o=0;o1&&this.endGroupAction(),e.wrapper.measure(new me(r.width,r.height)),e.wrapper.arrange(r.desiredSize),this.updateDiagramObject(e),this.protectPropertyChange(!1),this.refreshCanvasLayers()},t.prototype.addChildToUmlNode=function(e,i,r){var s,o,a,l,h="NoWrap";"Class"===e.shape.classifier||"Interface"===e.shape.classifier?"Method"===r?(o=new hm(e,"",i),"Class"===e.shape.classifier?(e.shape.classShape.methods.push(o),s=e.shape.classShape):"Interface"===e.shape.classifier&&(e.shape.interfaceShape.methods.push(o),s=e.shape.interfaceShape),function Xse(n,t,e,i){if(e.methods&&e.methods.length){var r=e.methods,s="",o="",a=void 0,l=1,h=void 0,c=0,d=0,u=n.shape,g="Class"===u.classifier?u.classShape:u.interfaceShape;1===r.length?g.attributes.length>0?(c=g.attributes.filter(function(w){return w.isSeparator}).length,h=(l=2+g.attributes.length+c)+1,nT(n,t,l)):h=l+1:(c=g.attributes.filter(function(w){return w.isSeparator}).length,d=g.methods.filter(function(w){return w.isSeparator}).length,h=(l=2+g.attributes.length+c+g.methods.length+d)+1);for(var v=0;v1&&this.startGroupAction();for(var r=i.length-1;r>=0;r--)if(e.children&&e.children.length>0){var s=e.wrapper.children.filter(function(o){return o.id===e.id+"group_container"});s&&s.length>0&&this.removelabelExtension(e,i,r,s[0])}else this.removelabelExtension(e,i,r,e.wrapper);i.length>1&&this.endGroupAction(),this.refreshCanvasLayers()},t.prototype.removePortsExtenion=function(e,i,r,s){for(var o=0;o1&&this.startGroupAction();for(var r=i.length-1;r>=0;r--)if(e.children&&e.children.length>0)for(var s=0;s1&&this.endGroupAction()},t.prototype.getSizeValue=function(e,i){var r;return r=e.toString().indexOf("px")>0?e.toString():e.toString().indexOf("%")>0?void 0!==i?"100%":e.toString():e.toString()+"px",i&&(qa(this),r="calc("+r+" - "+i+"px)"),r},t.prototype.renderRulers=function(){this.rulerSettings.showRulers?(function Yne(n){var t=qa(n),i=Tt("div",{id:n.element.id+"_overlapRuler",style:"height:"+t.height+"px;width:"+t.width+"px;position:absolute;left:0;top:0",class:"e-ruler-overlap"});n.element.insertBefore(i,n.element.firstChild)}(this),eF(this,!0),eF(this,!1)):Qx(this)},t.prototype.intOffPageBackground=function(){var e=new me;e=qa(this);var i=document.getElementById(this.element.id+"content"),r=this.getSizeValue(this.width,e.width),s=this.getSizeValue(this.height,e.height),o=this.rulerSettings.showRulers?"width:"+r+"; height:"+s+";top:"+e.height+"px;left:"+e.width+"px;overflow: scroll;position:absolute;overflow:auto;":"width:"+r+"; height:"+s+";position:absolute; left:0px; top:0px;overflow: auto;",a={id:this.element.id+"content",tabindex:"0",style:o};i?(this.diagramCanvas=i,Za(this.diagramCanvas,o)):(this.diagramCanvas=Tt("div",a),this.element.appendChild(this.diagramCanvas)),this.diagramCanvas.style.background=this.backgroundColor},t.prototype.initDiagram=function(){this.intOffPageBackground(),Ho(this.element,{style:"width:"+this.getSizeValue(this.width)+"; height:"+this.getSizeValue(this.height)+";position:relative;overflow:hidden;"})},t.prototype.renderHiddenUserHandleTemplateLayer=function(e){var r=Tt("div",{class:this.element.id+"_hiddenUserHandleTemplate",style:"width:"+e.width+"px; height:"+e.height+"px;visibility:hidden ; overflow: hidden;"});this.element.appendChild(r)},t.prototype.renderBackgroundLayer=function(e,i){var r=this.createSvg(this.element.id+"_backgroundLayer_svg",e.width,e.height);Za(r,i);var s=Bi("g",{id:this.element.id+"_backgroundImageLayer",class:"e-background-image-layer"});r.appendChild(s);var a=Bi("g",{id:this.element.id+"_backgroundLayer",class:"e-background-layer"});r.appendChild(a),this.diagramCanvas.appendChild(r)},t.prototype.renderGridLayer=function(e,i){var r=this.createSvg(this.element.id+"_gridline_svg",e.width,e.height);r.setAttribute("class","e-grid-layer");var s=Bi("g",{id:this.element.id+"_gridline"}),o=Bi("rect",{id:this.element.id+"_grid_rect",x:"0",y:"0",width:"100%",height:"100%"});if(nm()){var a=new URL(window.location.href);o.setAttribute("fill",""!==a.search?"url(#"+this.element.id+"_pattern)":"url("+location.protocol+"//"+location.host+location.pathname+"#"+this.element.id+"_pattern)")}else o.setAttribute("fill","url(#"+this.element.id+"_pattern)");s.appendChild(o),r.appendChild(s),this.diagramCanvas.appendChild(r),ai(r,{style:i})},t.prototype.renderDiagramLayer=function(e,i){if(this.diagramLayerDiv=Tt("div",{id:this.element.id+"_diagramLayer_div",style:"width:"+e.width+"px; height:"+e.height+"px;"+i}),"SVG"===this.mode){var s=this.createSvg(this.element.id+"_diagramLayer_svg",e.width,e.height);s.style["pointer-events"]="none",s.setAttribute("class","e-diagram-layer");var o=Bi("g",{id:this.element.id+"_diagramLayer"}),a=Bi("g",{});this.diagramLayer=o,s.style["pointer-events"]="all",a.appendChild(o),s.appendChild(a),this.diagramLayerDiv.appendChild(s)}else this.diagramLayer=bo.createCanvas(this.element.id+"_diagram",e.width,e.height),Za(this.diagramLayer,"position:absolute;left:0px;top:0px;"),this.diagramLayerDiv.appendChild(this.diagramLayer);this.diagramCanvas.appendChild(this.diagramLayerDiv)},t.prototype.initLayers=function(){var e="position:absolute;top:0px;left:0px;overflow:hidden;pointer-events:none;",r=document.getElementById(this.element.id).getBoundingClientRect(),s=function Soe(){var n=Tt("div",{style:"visibility:hidden; width: 100px"});document.body.appendChild(n);var t=n.getBoundingClientRect().width;n.style.overflow="scroll";var e=Tt("div",{style:"width:100%"});n.appendChild(e);var i=e.getBoundingClientRect().width;return n.parentNode.removeChild(n),t-i}();this.scroller.scrollerWidth=s,this.scroller.setViewPortSize(r.width,r.height),this.renderRulers();var o="measureElement";window[""+o]&&(window[""+o]=null,document.getElementById("measureElement").remove()),function BF(){var n="measureElement";if(window[""+n])window[""+n].usageCount+=1;else{var t=Tt("div",{id:"measureElement",style:"visibility:hidden ; height: 0px ; width: 0px; overflow: hidden;"}),e=Tt("span",{style:"display:inline-block ; line-height: normal"});t.appendChild(e);var i=Tt("img",{alt:"measureElementImage",src:"data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7"});t.appendChild(i);var r=document.createElementNS("http://www.w3.org/2000/svg","svg");r.setAttribute("xmlns:xlink","http://www.w3.org/1999/xlink"),t.appendChild(r);var s=document.createElementNS("http://www.w3.org/2000/svg","path");s.setAttribute("d",""),r.appendChild(s),document.createTextNode("");var a=document.createElementNS("http://www.w3.org/2000/svg","text");a.setAttributeNS("http://www.w3.org/XML/1998/namespace","xml:space","preserve"),r.appendChild(a),window[""+n]=t,window[""+n].usageCount=1,document.body.appendChild(t);var l="measureElementCount";window[""+l]?window[""+l]++:window[""+l]=1}}(),this.renderBackgroundLayer(r,e),this.renderGridLayer(r,e),this.renderDiagramLayer(r,e),this.renderHTMLLayer(r,e),this.renderPortsExpandLayer(r,e),this.renderNativeLayer(r,e),this.renderAdornerLayer(r,e),this.renderHiddenUserHandleTemplateLayer(r)},t.prototype.renderAdornerLayer=function(e,i){var r=Tt("div",{id:this.element.id+"_diagramAdornerLayer",style:"width:"+e.width+"px;height:"+e.height+"px;"+i}),s=Tt("div",{id:this.element.id+"_diagramUserHandleLayer",style:"width:"+e.width+"px;height:"+e.height+"px;"+i});s.setAttribute("class","e-userHandle-layer"),r.appendChild(s);var o=this.createSvg(this.element.id+"_diagramAdorner_svg",e.width,e.height);o.setAttribute("class","e-adorner-layer"),o.style["pointer-events"]="none",this.adornerLayer=Bi("g",{id:this.element.id+"_diagramAdorner"}),this.adornerLayer.style[" pointer-events"]="all",o.appendChild(this.adornerLayer),r.appendChild(o),this.diagramCanvas.appendChild(r);var a=Bi("g",{id:this.element.id+"_SelectorElement"});this.adornerLayer.appendChild(a),ai(o,{style:"pointer-events:none;"})},t.prototype.renderPortsExpandLayer=function(e,i){var r=this.createSvg(this.element.id+"_diagramPorts_svg",e.width,e.height);r.setAttribute("class","e-ports-expand-layer");var s=Bi("g",{id:this.element.id+"_diagramPorts",class:"e-ports-layer",style:"pointer-events: all;"});r.appendChild(s);var o=Bi("g",{id:this.element.id+"_diagramExpander",class:"e-expand-layer",style:"pointer-events: all;"});r.appendChild(o),this.diagramCanvas.appendChild(r),ai(r,{style:i})},t.prototype.renderHTMLLayer=function(e,i){this.htmlLayer=Tt("div",{id:this.element.id+"_htmlLayer",style:"width:"+e.width+"px; height:"+e.height+"px;position:absolute;top:0px;left:0px;overflow:hidden;pointer-events:none;",class:"e-html-layer"});var r=Tt("div",{id:this.element.id+"_htmlLayer_div",style:"position:absolute;top:0px;left:0px;pointer-events:all;"});this.htmlLayer.appendChild(r),this.diagramCanvas.appendChild(this.htmlLayer)},t.prototype.renderNativeLayer=function(e,i){var r=this.createSvg(this.element.id+"_nativeLayer_svg",e.width,e.height),s=Bi("g",{id:this.element.id+"_nativeLayer",style:"pointer-events:all;"});r.appendChild(s),this.diagramLayerDiv.appendChild(r),ai(r,{class:"e-native-layer",style:i})},t.prototype.createSvg=function(e,i,r){var s=document.createElementNS("http://www.w3.org/2000/svg","svg");return ai(s,{id:e,width:i,height:r}),s},t.prototype.updateBazorShape=function(){for(var e=0;e1,i=[],r={},s={},o=[],a=0,l=this.nodes;a0||b&&b.children&&b.children.length>0)&&(M=!1),S&&S.wrapper&&b&&b.wrapper&&M?this.initConnectors(r[""+h],f):i.push(r[""+h])}else b=r[y.targetID],(S=r[y.sourceID])&&S.children&&S.children.length>0||b&&b.children&&b.children.length>0?i.push(r[""+h]):this.initConnectors(r[""+h],f);else r[""+h].children?o.push(h):r[""+h].shape instanceof hT&&r[""+h].shape.activity.subProcess.processes&&r[""+h].shape.activity.subProcess.processes.length>0?s[r[""+h].id]=h:this.initNodes(r[""+h],f);if(this.bpmnModule)for(var w=0,C=this.bpmnModule.bpmnTextAnnotationConnector;w-1&&-1===r.indexOf(c)&&-1===s.indexOf(c)&&r.splice(0,0,c);-1===r.indexOf(o)&&s.push(o)}return r.concat(s)},t.prototype.addToLayer=function(e,i){var r;if(i&&(r=this.commandHandler.getObjectLayer(e.id)),(!i||!r)&&-1===this.activeLayer.objects.indexOf(e.id)&&this.activeLayer.objects.push(e.id),(e instanceof te||e instanceof de)&&("SwimLane"!==e.shape.type||e.children&&e.children.length>0)){if(e.parentId){var s=this.swimlaneZIndexTable[e.parentId],o=this.swimlaneChildTable[e.id];(s&&-1!==s||o&&-1!==o)&&(e.zIndex=this.swimlaneChildTable[e.id])}e instanceof de&&e.sourceID&&e.targetID?-1!==this.activeLayer.objects.indexOf(e.sourceID)&&-1!==this.activeLayer.objects.indexOf(e.targetID)&&this.setZIndex(r||this.activeLayer,e):this.setZIndex(r||this.activeLayer,e)}},t.prototype.updateLayer=function(e){for(var i=0,r=Object.keys(e.layers);i0)for(r=0;rs;l--)r.zIndexTable[parseInt(l.toString(),10)]=r.zIndexTable[l-1],this.nameTable[r.zIndexTable[parseInt(l.toString(),10)]]&&(this.nameTable[r.zIndexTable[parseInt(l.toString(),10)]].zIndex=l);r.zIndexTable[parseInt(a.toString(),10)]=i.id}}},t.prototype.initializeDiagramLayers=function(){for(var e=0;ethis.layers[parseInt(a.toString(),10)].zIndex&&(i=this.layers[parseInt(e.toString(),10)],this.layers[parseInt(e.toString(),10)]=this.layers[parseInt(a.toString(),10)],this.layers[parseInt(a.toString(),10)]=i);0===this.layers.length&&this.commandHandler.addLayer({id:"default_layer",visible:!0,lock:!1,objects:[],zIndex:0,objectZIndex:-1,zIndexTable:{}},null,!0),this.setActiveLayer(this.layers[this.layers.length-1].id)},t.prototype.resetTool=function(){this.eventHandler.resetTool()},t.prototype.initObjectExtend=function(e,i,r){if(r){var s=this.commandHandler.checkBoundaryConstraints(void 0,void 0,e.wrapper.bounds,!0);if("SwimLane"===e.shape.type)for(var o=0,a=Object.keys(i.zIndexTable);o0)&&this.setZIndex(i,e)),e instanceof te){if(r){if("helper"!==e.id&&(o=Zi(this.getNodeDefaults))){if((a=o(e,this))&&a.ports)for(var l=0;l0)for(l=0;l0&&!e.container||e.processId){var r=this.nameTable[e.id];if(!(this.realActions&$i.PreventScale||this.realActions&$i.PreventDrag)){if(r.offsetX&&(this.realActions&$i.EnableGroupAction||!(this.diagramActions&ee.UndoRedo||this.diagramActions&ee.ToolAction||this.diagramActions&ee.PublicMethod))){this.realActions|=$i.PreventScale;var s=r.offsetX-e.wrapper.offsetX;r.offsetX=e.wrapper.offsetX;var o=r.offsetY-e.wrapper.offsetY;r.offsetY=e.wrapper.offsetY,s+o!==0&&this.drag(r,s,o),this.realActions&=~$i.PreventScale}else r.offsetX=e.wrapper.offsetX;r.offsetY&&(this.realActions&$i.EnableGroupAction||!(this.diagramActions&ee.UndoRedo||this.diagramActions&ee.ToolAction||this.diagramActions&ee.PublicMethod))?(this.realActions|=$i.PreventScale,o=r.offsetY-e.wrapper.offsetY,r.offsetY=e.wrapper.offsetY,this.drag(r,0,o),this.realActions&=~$i.PreventScale):r.offsetY=e.wrapper.offsetY,this.diagramActions&&(r.width=e.wrapper.actualSize.width,r.height=e.wrapper.actualSize.height)}}i&&e.children&&e.children.length>0&&(void 0!==this.nameTable[e.id].width?this.scaleObject(e,this.nameTable[e.id].width,!0):this.nameTable[e.id].width=e.wrapper.actualSize.width,void 0!==this.nameTable[e.id].height?this.scaleObject(e,this.nameTable[e.id].height,!1):this.nameTable[e.id].height=e.wrapper.actualSize.height)},t.prototype.initNode=function(e,i,r){var a,p,s=e.initContainer(),o=new Ii;if(this.diagramSettings.inversedAlignment||(s.inversedAlignment=!1),s.children||(s.children=[]),e.children){s.measureChildren=!1,o.id=e.id+"group_container",o.style.fill=e.shape&&"SwimLane"===e.shape.type?e.style.fill:"none",o.style.strokeColor="none",o.horizontalAlignment="Stretch",o.verticalAlignment="Stretch",o.pivot=e.pivot,s.style=e.style,s.padding.left=e.padding.left,s.padding.right=e.padding.right,s.padding.top=e.padding.top,s.padding.bottom=e.padding.bottom,o.children=[],o.preventContainer=!0,e.container&&(o.relativeMode="Object");var l=!!(e.ports&&e.ports.length>0);if(m(e.container)&&!l&&s.children.push(o),e.container&&"Grid"===e.container.type)for(var h=0;h0&&e.wrapper.children[0]instanceof Wv){if(this.setZIndex(this.activeLayer,e),this.connectors.length>0)for(h=0;h0?i.phases.length:0,v="Horizontal"===i.orientation,y=v?i.phases.length||1:s.length+1,S=v?(i.header&&i.hasHeader?1:0)+(i.phases.length>0?1:0)+i.lanes.length:(i.header&&i.hasHeader?1:0)+i.phases.length;if(0===h&&!v&&i.lanes.length&&(S+=1),v?(a=(i.header&&i.hasHeader?1:0)+(h>0?1:0),l=0):(a=i.header&&i.hasHeader?1:0,l=h>0?1:0),s.length>0)for(o+=i.header&&i.hasHeader?i.header.height:0,p=0;pl?d.margin.left=d.margin.left-(u.bounds.left-e.bounds.left):u.children[0].children[1].actualSize.width+r>=d.margin.left&&(d.margin.left=u.children[0].children[1].actualSize.width+r),d.margin.lefta?d.margin.top=d.margin.top-(u.bounds.top-o):u.children[0].children[1].actualSize.height+r>=d.margin.top&&(d.margin.top=u.children[0].children[1].actualSize.height+r),d.margin.left0)for(o=0;o0&&this.updateChildPosition(e)},t.prototype.addBpmnAnnotationConnector=function(e,i){if(e.parentObj instanceof t||e.parentObj instanceof Rd){var r=e.shape,o=""!==r.textAnnotation.textAnnotationTarget&&this.nameTable[r.textAnnotation.textAnnotationTarget],a=o?this.nameTable[r.textAnnotation.textAnnotationTarget]:null,l=null!=a?a.wrapper:null,h=e.ports[0],c={x:0,y:0};switch(r.textAnnotation.textAnnotationDirection){case"Left":h.offset={x:0,y:.5},c.x=i.bounds.left-40,c.y=i.bounds.bottom+30;break;case"Right":h.offset={x:1,y:.5},c.x=i.bounds.right+40,c.y=i.bounds.bottom+30;break;case"Top":h.offset={x:.5,y:0},c.x=i.bounds.right+30,c.y=i.bounds.top-40;break;case"Bottom":h.offset={x:.5,y:1},c.x=i.bounds.right+30,c.y=i.bounds.bottom+40;break;default:h.offset={x:0,y:.5},c.x=i.bounds.left-40,c.y=i.bounds.bottom+30,o&&null!=i&&null!=l&&(i.bounds.left>l.bounds.right?h.offset={x:0,y:.5}:i.bounds.rightl.bounds.top?h.offset={x:.5,y:0}:i.bounds.top0&&this.updateChildPosition(r)}},t.prototype.canExecute=function(){return!0},t.prototype.updateStackProperty=function(e,i,r){e.container&&"Stack"===e.container.type&&(i.width||(i.wrapper.horizontalAlignment="Stretch",i.horizontalAlignment="Stretch"),i.height||(i.verticalAlignment="Stretch",i.wrapper.verticalAlignment="Stretch"),r&&"UmlClassifier"===e.shape.type&&(i.umlIndex=r))},t.prototype.initViews=function(){this.isLoading||(this.views.push(this.element.id),this.views[this.element.id]=this)},t.prototype.initCommands=function(){var e=this.commandManager.commands,i={copy:{execute:this.copyCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.C,keyModifiers:pt.Control}},paste:{execute:this.pasteCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.V,keyModifiers:pt.Control}},cut:{execute:this.cutCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.X,keyModifiers:pt.Control}},delete:{execute:this.removeCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Delete}},selectAll:{execute:this.selectAll.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.A,keyModifiers:pt.Control}},undo:{execute:this.undo.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Z,keyModifiers:pt.Control}},redo:{execute:this.redo.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Y,keyModifiers:pt.Control}},nudgeUp:{execute:this.nudgeCommand.bind(this,"Up"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Up},parameter:"up"},nudgeRight:{execute:this.nudgeCommand.bind(this,"Right"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Right},parameter:"right"},nudgeDown:{execute:this.nudgeCommand.bind(this,"Down"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Down},parameter:"down"},nudgeLeft:{execute:this.nudgeCommand.bind(this,"Left"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Left},parameter:"left"},startEdit:{execute:this.startEditCommad.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.F2}},endEdit:{execute:this.endEditCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Escape}},focusToNextItem:{execute:this.navigateItems.bind(this,!0),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Tab}},focusToPreviousItem:{execute:this.navigateItems.bind(this,!1),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Tab,keyModifiers:pt.Shift}},selectFocusedItem:{execute:this.startEditCommad.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Enter}},bold:{execute:this.fontStyleCommand.bind(this,"bold"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.B,keyModifiers:pt.Control}},italic:{execute:this.fontStyleCommand.bind(this,"italic"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.I,keyModifiers:pt.Control}},underline:{execute:this.fontStyleCommand.bind(this,"underline"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.U,keyModifiers:pt.Control}},duplicate:{execute:this.duplicateCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.D,keyModifiers:pt.Control}},group:{execute:this.groupCommand.bind(this,"group"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.G,keyModifiers:pt.Control}},ungroup:{execute:this.groupCommand.bind(this,"ungroup"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.U,keyModifiers:pt.Control|pt.Shift}},rotateClockwise:{execute:this.rotateCommand.bind(this,"clockwise"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.R,keyModifiers:pt.Control}},rotateAntiClockwise:{execute:this.rotateCommand.bind(this,"antiClockwise"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.L,keyModifiers:pt.Control}},flipHorizontal:{execute:this.flipCommand.bind(this,"horizontal"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.H,keyModifiers:pt.Control}},flipVertical:{execute:this.flipCommand.bind(this,"vertical"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.J,keyModifiers:pt.Control}},pointerTool:{execute:this.toolCommand.bind(this,"pointer"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number1,keyModifiers:pt.Control}},textTool:{execute:this.toolCommand.bind(this,"text"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number2,keyModifiers:pt.Control}},connectTool:{execute:this.toolCommand.bind(this,"connect"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number3,keyModifiers:pt.Control}},freeForm:{execute:this.toolCommand.bind(this,"freeForm"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number5,keyModifiers:pt.Control}},lineTool:{execute:this.toolCommand.bind(this,"line"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number6,keyModifiers:pt.Control}},rectangleTool:{execute:this.toolCommand.bind(this,"rectangle"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number8,keyModifiers:pt.Control}},ellipseTool:{execute:this.toolCommand.bind(this,"ellipse"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number9,keyModifiers:pt.Control}},zoomIn:{execute:this.zoomCommand.bind(this,"zoomIn"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Plus,keyModifiers:pt.Control}},zoomOut:{execute:this.zoomCommand.bind(this,"zoomOut"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Minus,keyModifiers:pt.Control}},shiftUp:{execute:this.shiftCommand.bind(this,"Up"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Up,keyModifiers:pt.Shift}},shiftDown:{execute:this.shiftCommand.bind(this,"Down"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Down,keyModifiers:pt.Shift}},shiftLeft:{execute:this.shiftCommand.bind(this,"Left"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Left,keyModifiers:pt.Shift}},shiftRight:{execute:this.shiftCommand.bind(this,"Right"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Right,keyModifiers:pt.Shift}},alignTextCenter:{execute:this.alignCommand.bind(this,"center"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.C,keyModifiers:pt.Control|pt.Shift}},alignTextLeft:{execute:this.alignCommand.bind(this,"right"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.L,keyModifiers:pt.Control|pt.Shift}},alignTextRight:{execute:this.alignCommand.bind(this,"left"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.R,keyModifiers:pt.Control|pt.Shift}},alignTextTop:{execute:this.alignCommand.bind(this,"top"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.E,keyModifiers:pt.Control|pt.Shift}},alignTextCenterVertical:{execute:this.alignCommand.bind(this,"centerVertical"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.M,keyModifiers:pt.Control|pt.Shift}},alignTextBottom:{execute:this.alignCommand.bind(this,"bottom"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.V,keyModifiers:pt.Control|pt.Shift}},alignJustify:{execute:this.alignCommand.bind(this,"justify"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.J,keyModifiers:pt.Control|pt.Shift}},sendToBack:{execute:this.orderCommand.bind(this,"sendToBack"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.B,keyModifiers:pt.Control|pt.Shift}},bringToFront:{execute:this.orderCommand.bind(this,"bringToFront"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.F,keyModifiers:pt.Control|pt.Shift}},sendBackward:{execute:this.orderCommand.bind(this,"sendBackward"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.BracketLeft,keyModifiers:pt.Control}},bringForward:{execute:this.orderCommand.bind(this,"bringForward"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.BracketRight,keyModifiers:pt.Control}}};this.initCommandManager(e,i)},t.prototype.overrideCommands=function(e,i){for(var r,s=0,o=Object.keys(i);se.zIndex){("HTML"===e.shape.type||"Native"===e.shape.type)&&(o="HTML"===e.shape.type?"html":"native"),s=foe(i,r[parseInt(a.toString(),10)].id,o);break}return s},t.prototype.updateDiagramObject=function(e,i,r){for(var s,o="domTable",a=0,l=this.views;a1&&(d=this.commandHandler.getObjectLayer(e.id)),void 0===d||d&&d.visible||r){var u=Io(this.element.id);window[""+o][s.element.id+"_diagramLayer"]||(window[""+o][s.element.id+"_diagramLayer"]=document.getElementById(s.element.id+"_diagramLayer"));var p=window[""+o][s.element.id+"_diagramLayer"];this.diagramActions&ee.Interactions&&this.updateCanupdateStyle(e.wrapper.children,!0);var f=this.getMidPoint(e);this.diagramRenderer.updateNode(e.wrapper,p,u,void 0,i?void 0:this.getZindexPosition(e,s.element.id),f,this.portCenterPoint),this.updateCanupdateStyle(e.wrapper.children,!0)}}},t.prototype.applyMarginBezier=function(e,i){i.cx=i.cx+e.margin.left,i.cx=i.cx-e.margin.right,i.cy=i.cy+e.margin.top,i.cy=i.cy-e.margin.bottom},t.prototype.getMidPoint=function(e){var i;if(e instanceof de&&"Bezier"===e.type){i=[];for(var r=this.getBezierPoints(e),s=z.getLengthFromListOfPoints(r),o=0;o0&&e.updateView(e));var s=Io(e.element.id);this.renderDiagramElements(e.diagramLayer,e.diagramRenderer,s,void 0,void 0,i);for(var o=0;o0&&this.renderBasicElement(e),!this.diagramActions||!(this.diagramActions&ee.Render)||ee.ToolAction&this.diagramActions||Ds(this)||1!==this.scroller.currentZoom?this.refreshElements(e):this.renderTimer||(this.renderTimer=setTimeout(function(){i.refreshElements(e)},40)))},t.prototype.updatePortVisibility=function(e,i,r){var s;if((e instanceof te||e instanceof de)&&(!this.drawingObject||!this.drawingObject.shape)&&to(e)){for(var a=e.ports,l=!1,h=0;h=0&&this.scroller.removeCollection.splice(l,1);var h=this.nameTable[e[parseInt(a.toString(),10)]];this.updateTextElementValue(h),this.diagramRenderer.renderElement(h.wrapper,s,o,void 0,void 0,void 0,void 0,h.zIndex)}for(var c=0;c0?this.scroller.oldCollectionObjects:void 0,b=Object.keys(S||g.zIndexTable);b.sort(function(N,T){return parseInt(""+N,10)-parseInt(""+T,10)});for(var M=0,w=b;M0?h:0)+"px",y=(this.realActions&$i.vScrollbarMoved?0:-(this.scroller.verticalOffset<0?this.scroller.verticalOffset:0))+"px"):(v="0px",y="0px"),this.realActions&$i.hScrollbarMoved&&(this.realActions=this.realActions&~$i.hScrollbarMoved),this.realActions&$i.vScrollbarMoved&&(this.realActions=this.realActions&~$i.vScrollbarMoved)):(v=(l.x<0?h:-this.scroller.horizontalOffset)+"px",y=(l.y<0?c:-this.scroller.verticalOffset)+"px"),this.diagramLayer.style.left=v,this.diagramLayer.style.top=y,A.tx=-l.x/A.scale,A.ty=-l.y/A.scale);var R=!0;if(o&&(R=!1),this.updateTextElementValue(D),this.refreshing&&D.shape.activity&&D.shape.activity.subProcess&&D.shape.activity.subProcess.processes){for(var L=0;L0){var o=s.children[0],a=o.data;(r.isBezierEditing&&this.selectedItems.connectors[0].id===r.id||"Bezier"!==r.type)&&r.getSegmentElement(r,o,"ComplexHierarchicalTree"===this.layout.type||"HierarchicalTree"===this.layout.type?this.layout.orientation:void 0,void 0,!1),o.data!==a&&(s.measure(new me),s.arrange(s.desiredSize),"SVG"===this.mode&&!e&&this.updateDiagramObject(r))}}else this.constraints&rt.Bridging&&console.warn('[WARNING] :: Module "ConnectorBridging" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.setCursor=function(e){this.diagramRenderer.setCursor(this.diagramCanvas,e)},t.prototype.clearCanvas=function(e){var i=e.contentWidth||e.diagramLayer.width/this.scroller.currentZoom,r=e.contentHeight||e.diagramLayer.height/this.scroller.currentZoom;"SVG"!==e.mode&&bo.getContext(e.diagramLayer).clearRect(0,0,i,r)},t.prototype.updateScrollOffset=function(){this.scroller.setScrollOffset(this.diagramCanvas.scrollLeft,this.diagramCanvas.scrollTop),XI(this),Ds(this)&&this.scroller.virtualizeElements()},t.prototype.setOffset=function(e,i){var r="domTable";window[""+r][this.element.id+"content"]||(window[""+r][this.element.id+"content"]=document.getElementById(this.element.id+"content"));var s=window[""+r][this.element.id+"content"];s&&(s.scrollLeft=e,s.scrollTop=i)},t.prototype.setSize=function(e,i){if(this.diagramLayer&&!this.preventDiagramUpdate){var r=qa(this);e-=r.width,i-=r.height;var s=this.spatialSearch.getPageBounds();s.x*=this.scroller.currentZoom,s.y*=this.scroller.currentZoom,s.width*=this.scroller.currentZoom,s.height*=this.scroller.currentZoom;var o="SVG"===this.mode?1:1.5,a="SVG"===this.mode?fT(this.element.id):this.diagramLayer,h="Canvas"===this.mode&&this.constraints&rt.Virtualization?this.scroller.viewPortHeight:i;a.setAttribute("width",(o*("Canvas"===this.mode&&this.constraints&rt.Virtualization?this.scroller.viewPortWidth:e)).toString()),a.setAttribute("height",(o*h).toString());var c=document.getElementById(this.element.id+"_diagramUserHandleLayer");c&&(c.style.width=e+"px",c.style.height=i+"px");var d={width:e.toString(),height:i.toString()};this.diagramLayerDiv.style.width=e+"px",this.diagramLayerDiv.style.height=i+"px",ai(kF(this.element.id),d),ai(function voe(n){return xt(n).getElementsByClassName("e-ports-expand-layer")[0]}(this.element.id),d);var u=Pl(this.element.id);ai(u,d),u.parentNode.style.width=e+"px",u.parentNode.style.height=i+"px";var p=Bd(this.element.id);ai(p,d),this.diagramRenderer.updateGrid(this.snapSettings,p,this.scroller.transform,this.rulerSettings,this.hRuler,this.vRuler),ai(mT(this.element.id),d),this.htmlLayer.style.width=e+"px",this.htmlLayer.style.height=i+"px","SVG"!==this.mode&&!Ds(this)&&this.refreshDiagramLayer(),"SVG"===this.mode&&Ds(this)&&this.scroller.virtualizeElements()}},t.prototype.transformLayers=function(){var e=this.spatialSearch.getPageBounds();e.x*=this.scroller.currentZoom,e.y*=this.scroller.currentZoom,e.width*=this.scroller.currentZoom,e.height*=this.scroller.currentZoom,this.diagramRenderer.updateGrid(this.snapSettings,Bd(this.element.id),this.scroller.transform,this.rulerSettings,this.hRuler,this.vRuler),this.diagramRenderer.transformLayers(this.scroller.transform,"SVG"===this.mode),this.diagramActions&ee.DragUsingMouse||this.updateSelector(),this.renderPageBreaks(e)},t.prototype.removePageBreaks=function(){if(this.diagramLayer){var e=PF(this.element.id);if(e&&e.childNodes)for(var i=e.childNodes.length,r=0;rthis.pageSettings.height&&(e=this.pageSettings.height,this.pageSettings.height=this.pageSettings.width,this.pageSettings.width=e):this.pageSettings.height>this.pageSettings.width&&(e=this.pageSettings.width,this.pageSettings.width=this.pageSettings.height,this.pageSettings.height=e)},t.prototype.setOverview=function(e,i){if(e)e&&(this.views.push(e.id),this.views[e.id]=e,e.renderDocument(e),e.diagramRenderer.setLayers(),e.updateView(e),this.renderNodes(e));else{for(var r=0;r1&&this.updateSelectionRectangle(),this.isProtectedOnChange=s},t.prototype.updateSelectionRectangle=function(){for(var e=cm(this.element.id),i=!1,r=0;r1&&this.updateSelectionRectangle(),this.enableServerDataBinding(e)},t.prototype.renderSelectorForAnnotation=function(e,i){this.diagramRenderer.renderResizeHandle(e.wrapper.children[0],i,e.thumbsConstraints,this.scroller.currentZoom,e.constraints,this.scroller.transform,void 0,to(e.annotation),void 0,void 0,e.handleSize)},t.prototype.drawSelectionRectangle=function(e,i,r,s){this.clearSelectorLayer(),this.diagramRenderer.drawSelectionRectangle(e,i,r,s,this.adornerLayer,this.scroller.transform)},t.prototype.renderHighlighter=function(e){var i=Pl(this.element.id);this.diagramRenderer.renderHighlighter(e,i,this.scroller.transform)},t.prototype.clearHighlighter=function(){var e=Pl(this.element.id),i=e.getElementById(e.id+"_highlighter");i&&i.parentNode.removeChild(i)},t.prototype.getNodesConnectors=function(e){for(var i=0;i0;l--)(a=o[l-1]).parentNode.removeChild(a);if(!ce()){var h=vT(this.element.id).childNodes;for(r=h.length;r>0;r--)h[r-1].parentNode.removeChild(h[r-1])}}},t.prototype.getWrapper=function(e,i){var r;i=e.id+"_"+i;for(var s=e instanceof Ii?e:this.getPortContainer(this.nameTable[e.id]),o=0;o0&&this.applyStyle(e,a=r.annotations)}for(i=0;i0){var a=this.selectedItems.connectors[parseInt(i.toString(),10)].annotations;this.applyStyle(e,a)}},t.prototype.applyStyle=function(e,i){for(var r=0;r0)for(var i=0;i0?r[0].zIndex+(e?1:-1):e?0:this.nodes.length+this.connectors.length-1)<0?i=this.nodes.length+this.connectors.length-1:i===this.nodes.length+this.connectors.length&&(i=0);for(var s=0;s0)for(var s=void 0,o=r.children.length-1;o>=0;o--){var a=r.children[parseInt(o.toString(),10)];i.length>0&&-1!==i.indexOf(a.id.split("_groupElement")[0])&&(r.parentNode.insertBefore(a,s||r),s=a)}r&&r.parentNode.removeChild(r)},t.prototype.deleteGroup=function(e){var r=[];e.children&&(r=this.commandHandler.getChildren(e,[])),this.UpdateBlazorDiagramModelCollection(e);for(var s=0,o=r;s0)for(var xe=0;xe0)if("Path"===t.shape.type&&void 0!==n.shape.data)t.wrapper.children[0].data=n.shape.data;else if("Text"===t.shape.type&&void 0!==n.shape.content)t.wrapper.children[0].content=n.shape.content;else if("Image"===t.shape.type&&void 0!==n.shape.source)t.wrapper.children[0].source=n.shape.source;else if("Native"===t.shape.type){for(var r=void 0,s=0;s-1)&&(this.diagramActions&ee.PreventZIndexOnDragging?this.updateDiagramObject(e,!0):this.updateDiagramObject(e)),!s&&d&&(this.lineRoutingModule&&this.diagramActions&&this.constraints&rt.LineRouting&&"helper"!==e.id?this.diagramActions&ee.ToolAction||this.lineRoutingModule.renderVirtualRegion(this,!0):this.diagramActions&&this.constraints&rt.LineRouting&&"helper"!==e.id&&console.warn('[WARNING] :: Module "LineRouting" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),this.updateConnectorEdges(e),"helper"!==e.id&&!(this.diagramActions&ee.ToolAction))))for(var ya=this.spatialSearch.findObjects(e.wrapper.outerBounds),Mo=0;Moe?Math.abs(r-e):Math.abs(e-r),d=s>i?Math.abs(s-i):Math.abs(i-s);(0===c&&0===d||Number.isNaN(c)&&Number.isNaN(d))&&o.laneMargin&&(u=o.margin.left-o.laneMargin.left,p=o.margin.top-o.laneMargin.top);var f=o.width,g=o.height,v=new Ne(0,0,0,0);if(0!==f&&0!==g&&(v=new Ne((0!==r?r:o.offsetX)-f/2,(0!==s?s:o.offsetY)-g/2,f,g)),h){var y=l,b=this.selectedItems.nodes?this.selectedItems.nodes[0]:void 0;if(""!==y.textAnnotation.textAnnotationTarget&&this.nameTable[y.textAnnotation.textAnnotationTarget])if(""===o.parentId||b&&b.shape&&"TextAnnotation"===b.shape.shape){if("Auto"===y.textAnnotation.textAnnotationDirection&&a.children[0]instanceof Ii&&a.children[0].children[0]instanceof Ke){var w=a.children[0],C=document.getElementById(w.id+"_groupElement"),D=document.getElementById(w.children[0].id+"_groupElement");C.removeChild(D),w.children.splice(0,1),this.isProtectedOnChange=!0,this.bpmnModule.setAnnotationPath(v,w,o,y,y.textAnnotation.textAnnotationDirection,this),this.isProtectedOnChange=!1}}else this.isPositionUndo=!0,this.updateTextAnnotationInSwimlane(o,o),this.isPositionUndo=!1;else o.inEdges.length>0&&(x=this.nameTable[""+o.inEdges[0]])&&x.isBpmnAnnotationConnector&&(x.sourcePoint={x:r>e?x.sourcePoint.x+c:x.sourcePoint.x-c,y:s>i?x.sourcePoint.y+d:x.sourcePoint.y-d});this.nodePropertyChange(o,{},R={ports:[{offset:o.ports[0].offset}]})}else for(var L=0,O=o.outEdges;Le?T.offsetX+c:T.offsetX-c,T.offsetY=s>i?T.offsetY+d:T.offsetY-d,R={offsetX:T.offsetX,offsetY:T.offsetY}),this.nodePropertyChange(T,P,R)}}}},t.prototype.updatePorts=function(e,i){if(e&&e.ports.length>0)for(var r=0,s=Object.keys(e.ports);r0)for(var i=0;i0)for(var r=0;r0&&void 0===r.segments&&(e.segments=[]),void 0!==r.shape&&void 0!==e.shape&&e.shape&&"Bpmn"===e.shape.type&&this.bpmnModule&&this.bpmnModule.updateBPMNConnector(e,i,r,this),void 0!==e.constraints?(this.updateThumbConstraints(this.selectedItems.connectors,this.selectedItems),s=!0):s},t.prototype.connectorPropertyChange=function(e,i,r,s,o){if(this.canEnableBlazorObject){var a=$(e);this.insertValue(a,!1)}var d,u,p,f,l=e.wrapper.bounds,h=!1,c=[];if(h=this.connectorProprtyChangeExtend(e,i,r,h),void 0!==r.visible&&this.updateElementVisibility(e.wrapper,e,e.visible),void 0!==r.sourcePoint||void 0!==r.targetPoint||void 0!==r.sourceID||void 0!==r.targetID||void 0!==r.targetPadding||void 0!==r.sourcePortID||void 0!==r.targetPortID||void 0!==r.sourcePadding||void 0!==r.type||void 0!==r.segments||void 0!==r.flip){if(void 0!==r.sourceID&&r.sourceID!==i.sourceID||r.sourcePortID){if(u=this.findInOutConnectPorts(g=this.nameTable[e.sourceID],!1),(!g||Nh(g)||""!==e.sourcePortID&&xd(u))&&(e.sourceWrapper=g?this.getEndNodeWrapper(g,e,!0):void 0,e.sourcePortID&&void 0===r.sourcePortID&&(e.sourcePortWrapper=g?this.getWrapper(g.wrapper,e.sourcePortID):void 0),this.removePortEdges(this.nameTable[i.sourceID]||g,i.sourcePortID||e.sourcePortID,e.id,!1)),void 0!==r.sourceID&&void 0!==i.sourceID&&""!==i.sourceID){var v=this.nameTable[i.sourceID];void 0!==v&&v.outEdges&&-1!==v.outEdges.indexOf(e.id)&&tm(v.outEdges,e.id)}this.updateEdges(e)}if(void 0!==r.targetID&&r.targetID!==i.targetID){if(d=this.findInOutConnectPorts(y=this.nameTable[r.targetID],!0),(!y||da(y)||""!==e.targetPortID&&Lh(d))&&(e.targetWrapper=y?this.getEndNodeWrapper(y,e,!1):void 0,e.targetPortID&&void 0===r.targetPortID&&(e.targetPortWrapper=y?this.getWrapper(y.wrapper,e.targetPortID):void 0),this.removePortEdges(this.nameTable[i.targetID]||y,i.targetPortID||e.targetPortID,e.id,!0)),void 0!==i&&void 0!==i.targetID&&""!==i.targetID){var S=this.nameTable[i.targetID];void 0!==S&&S.inEdges&&-1!==S.inEdges.indexOf(e.id)&&tm(S.inEdges,e.id)}this.updateEdges(e)}var g,y;void 0!==r.sourcePortID&&r.sourcePortID!==i.sourcePortID&&(e.sourceID&&this.nameTable[e.sourceID]&&(p=this.nameTable[e.sourceID].wrapper),!(g=this.nameTable[e.sourceID])||Nh(g)||""!==e.sourcePortID&&xd(u)?e.sourcePortWrapper=p?this.getWrapper(p,r.sourcePortID):void 0:""===e.sourcePortID&&!Nh(g)&&(e.sourcePortWrapper=void 0)),void 0!==r.targetPortID&&r.targetPortID!==i.targetPortID&&(e.targetID&&this.nameTable[e.targetID]&&(f=this.nameTable[e.targetID].wrapper),!(y=this.nameTable[e.targetID])||da(y)||""!==e.targetPortID&&Lh(d)?e.targetPortWrapper=f?this.getWrapper(f,r.targetPortID):void 0:""===e.targetPortID&&!da(y)&&(e.targetPortWrapper=void 0)),void 0!==r.flip&&(e.flip=r.flip,SF(e)),"Orthogonal"===e.type&&this.lineRoutingModule&&this.diagramActions&&this.constraints&rt.LineRouting&&!(this.diagramActions&ee.ToolAction)&&"ComplexHierarchicalTree"!==this.layout.type&&(this.lineRoutingModule.renderVirtualRegion(this,!0),e.sourceID!==e.targetID&&e.segments.length>1&&this.lineRoutingModule.refreshConnectorSegments(this,e,!1)),c=this.getPoints(e)}void 0!==r.style&&Ph(r.style,e.wrapper.children[0]),(c.length>0||void 0!==r.sourceDecorator||void 0!==r.targetDecorator&&function Bse(n){return-1!==n.indexOf("shape")||-1!==n.indexOf("pathData")||-1!==n.indexOf("width")||-1!==n.indexOf("height")}(Object.keys(r.targetDecorator))||void 0!==r.cornerRadius)&&(Zp(e,c.length>0?c:e.intermediatePoints,this.diagramActions),void 0!==r.type&&(h=!0),c.length>0&&(e.wrapper.measure(new me(e.wrapper.width,e.wrapper.height)),e.wrapper.arrange(e.wrapper.desiredSize),this.updateConnectorAnnotation(e),this.updateConnectorPort(e),this.updateConnectorfixedUserHandles(e),this.updateObject(e,i,r))),(r.sourcePoint||r.targetPoint||r.segments)&&this.diagramActions===ee.Render&&(h=!0),"Bpmn"===e.shape.type&&"Default"===e.shape.sequence&&"Sequence"===e.shape.flow&&this.commandHandler.updatePathElementOffset(e),s||this.updateBridging(),this.updateAnnotations(r,e),this.updateConnectorPorts(r,e),this.updatefixedUserHandle(r,e),e.wrapper.measure(new me(e.wrapper.width,e.wrapper.height)),e.wrapper.arrange(e.wrapper.desiredSize),!1===l.equals(l,e.wrapper.bounds)&&(this.updateQuad(e),"Drag"!==this.eventHandler.currentAction&&this.updateGroupSize(e)),!0===h&&this.checkSelectedItem(e)&&(!(this.diagramActions&ee.ToolAction)||this.diagramActions&ee.UndoRedo)&&this.updateSelector(),this.preventConnectorsUpdate||(!Ds(this)||Ds(this)&&this.scroller.oldCollectionObjects.indexOf(e.id)>-1)&&(this.diagramActions&ee.PreventZIndexOnDragging?this.updateDiagramObject(e,!0):this.updateDiagramObject(e)),this.updateConnectorEdges(e),this.diagramActions&&"New"!==e.status&&(e.status="Update"),this.triggerPropertyChange(o,e,i,r)},t.prototype.removePortEdges=function(e,i,r,s){if(e)for(var o=0;o0&&e.id===s[s.length-1].id&&(r=!0),r},t.prototype.updateDiagramContainerVisibility=function(e,i){if(e instanceof Cs)for(var r=0;r>"),r instanceof Jn&&this.updateAnnotationWrapper(r,s,o,a)),void 0!==e.template&&(r.content=e.template,this.updateAnnotationWrapper(r,s,o,a))},t.prototype.updateAnnotationWrapper=function(e,i,r,s){for(var o=0,a=this.views;o=0&&this.nodes.splice(s,1),delete this.nameTable[""+r]}var o=this.nodes.indexOf(this.nameTable[this.currentSymbol.id]);o>=0&&this.nodes.splice(o,1)}},t.prototype.selectDragedNode=function(e,i,r){this.currentSymbol=e,"SVG"!==this.mode&&this.refreshDiagramLayer(),this.commandHandler.oldSelectedObjects=rm(this),this.commandHandler.select(e),this.eventHandler.mouseDown(i.event),this.eventHandler.mouseMove(i.event,i),this.preventDiagramUpdate=!1,this.updatePage(),r.style.opacity="0"},t.prototype.initDroppables=function(){var s,o,e=this,i={},r={},a="selectedSymbols";this.droppable=new lR(this.element);var l=5;this.droppable.over=function(h){if(e.rulerSettings.showRulers){var c=document.getElementById(e.element.id+"_vRuler"),d=parseFloat(c.style.width);l=d+1}if(0===e.previousSelectedObjects.length&&!e.currentSymbol&&(e.previousSelectedObjects=e.commandHandler.getSelectedObject()),e.commandHandler.PreventConnectorSplit=!0,e.currentSymbol)h.event.touches&&h.event.touches.length&&e.eventHandler.mouseMove(h.event,h.event.touches);else{var u=null;if(!h.dragData&&"drag"===h.name){var p=document.getElementsByClassName("e-dragclone")[0];p&&(u=p)}if(h.dragData||u){var f=void 0,g=void 0;document.getElementById(e.element.id+"content").focus();var v=e.eventHandler.getMousePosition(h.event),y=void 0,S=u||h.dragData.helper,b=S.getAttribute("paletteId"),M=void 0,w=void 0,C=void 0,D=void 0;if(!b&&h.dragData){e.triggerEvent(Ce.dragEnter,A={source:null,element:f,cancel:!1,diagram:e,dragData:h.dragData.draggedElement.ej2_instances[0].dragData,dragItem:f});var x=void 0,R=void 0;if(A.dragItem){if(A.dragItem.sourcePoint&&A.dragItem.targetPoint?R=new de(e,"connectors",A.dragItem,!0):x=new te(e,"nodes",A.dragItem,!0),e.initObject(f=x||R,void 0,void 0,!0),e.enterObject=f,e.enterTable=r,f instanceof te)x.offsetX=v.x+5+x.width*x.pivot.x,x.offsetY=v.y+x.height*x.pivot.y;else if(f instanceof de){var L=Ne.toBounds([f.sourcePoint,f.targetPoint]),O=v.x-L.left,N=v.y-L.top;f.sourcePoint.x+=O,f.sourcePoint.y+=N,f.targetPoint.x+=O,f.targetPoint.y+=N}e.preventDiagramUpdate=!0,e.currentSymbol=f,"SVG"!==e.mode&&e.refreshDiagramLayer(),e.selectDragedNode(f,h,S),delete e.enterObject,delete e.enterTable,e.droppable[""+a]=S,e.allowServerDataBinding=!0}}if(b){var T=document.getElementById(b).ej2_instances[0];if(e.droppable.sourceElement=T,T){var B=T[""+a];e.allowServerDataBinding=!1,y=$(T[""+a]),i=T.childTable;var j=B.wrapper.children[0].children[0];if(D=function Fse(n,t,e){var i=wF(n,t,e,"width"),r=wF(n,t,e,"height");return new me(i,r)}(T,y,j),T[""+a]instanceof te){"TextAnnotation"===B.shape.shape?(y.offsetX=v.x+11+D.width*y.pivot.x,y.offsetY=v.y+11+D.height*y.pivot.y):(y.offsetX=v.x+5+D.width*y.pivot.x,y.offsetY=v.y+D.height*y.pivot.y),"Bpmn"===(x=new te(e,"nodes",y,!0)).shape.type&&x.shape.activity.subProcess.processes&&x.shape.activity.subProcess.processes.length&&(x.shape.activity.subProcess.processes=[]),w=x.previewSize,C=T.symbolDragSize;var Q=T.symbolPreview;if(x.width=(M=x.dragSize).width||C.width||w.width||Q.width||x.width,x.height=M.height||C.height||w.height||Q.height||x.height,"SwimLane"===x.shape.type){if(e.diagramActions|=ee.PreventHistory,x.shape.isLane){x.children=[],s={id:"header"+Qe()},"Horizontal"===x.shape.orientation?(s.width=x.shape.lanes[0].header.width,s.height=x.shape.lanes[0].height):(s.width=x.shape.lanes[0].width,s.height=x.shape.lanes[0].header.height),s.style=x.shape.lanes[0].header.style,s.offsetX=v.x+l+s.width/2,s.offsetY=v.y+s.height/2,e.diagramActions|=ee.PreventCollectionChangeOnDragOver,s=e.add(s),o={id:"body"+Qe()},"Horizontal"===x.shape.orientation?(o.width=x.shape.lanes[0].width-s.width,o.height=x.shape.lanes[0].height,o.offsetX=v.x+l+(x.shape.lanes[0].header.width+o.width/2),o.offsetY=v.y+o.height/2):(o.width=x.shape.lanes[0].width,o.height=x.shape.lanes[0].height-s.height,o.offsetX=v.x+l+o.width/2,o.offsetY=v.y+(x.shape.lanes[0].header.height+o.height/2)),o.style=x.shape.lanes[0].style,o=e.add(o);var oe={id:"group"+Qe(),children:[s.id,o.id]};oe.shape=x.shape,oe.width=x.shape.lanes[0].width,oe.height=x.shape.lanes[0].height,oe.previewSize=x.previewSize,oe.dragSize=x.dragSize,oe.addInfo=x.addInfo,x=e.add(oe),e.diagramActions&=~ee.PreventCollectionChangeOnDragOver}e.diagramActions&=~ee.PreventHistory}if(x.shape.isPhase&&((g="Horizontal"===x.shape.orientation)?(x.offsetX=v.x+l+(x.width||j.actualSize.width)/2,x.offsetY=v.y,x.shape.data="M20,"+x.height/2+" L"+(x.width-20)+","+x.height/2+"z",x.height=1):(x.offsetX=v.x+5,x.offsetY=v.y+(x.height||j.actualSize.height)/2,x.shape.data="M"+x.width/2+",20 L"+x.width/2+","+(x.height-20)+"z",x.width=1)),"UmlClassifier"===x.shape.type&&(x.children=x.width=x.height=void 0,y.children=void 0,"Class"===x.shape.classifier&&x.shape.classShape.methods.length<=0&&x.shape.classShape.attributes.length<=0&&(x.shape.classShape.attributes=[{name:"Name",type:"Type",style:{}}]),"Enumeration"===x.shape.classifier&&x.shape.enumerationShape.members.length<=0&&(x.shape.enumerationShape.members=[{name:"Name"}]),"Interface"===x.shape.classifier&&x.shape.interfaceShape.methods.length<=0&&x.shape.interfaceShape.attributes.length<=0&&(x.shape.interfaceShape.attributes=[{name:"Name",type:"Type",style:{}}])),f=x,y.children){var ue=y;r=e.getChildren(ue,{},i),eT(ue,-ue.offsetX,-ue.offsetY,r,!0,e)}}else if(T[""+a]instanceof de){f=new de(e,"connectors",y,!0);var Me=Ne.toBounds([f.sourcePoint,f.targetPoint]),De=v.x-Me.left,xe=v.y-Me.top;f.sourcePoint.x+=De,f.sourcePoint.y+=xe,f.targetPoint.x+=De,f.targetPoint.y+=xe}f.shape.isLane||(f.id+=Qe());var A={source:T,element:f,cancel:!1,diagram:e,dragData:null,dragItem:f};if(e.enterObject=f,e.enterTable=r,e.triggerEvent(Ce.dragEnter,A),f instanceof te&&"SwimLane"===f.shape.type&&f.shape.isLane){var Ie=A.element,Ve=Ie.shape.lanes[0];g="Horizontal"===Ie.shape.orientation;var ot=e.nameTable[f.children[0]],$e=e.nameTable[f.children[1]];w=f.previewSize,C=T.symbolDragSize,Ve.width=(M=f.dragSize).width||C.width||w.width||Ve.width,Ve.height=M.height||C.height||w.height||Ve.height,g?(s.width=Ve.header.width,s.height=Ve.height,o.width=Ve.width-s.width,o.height=Ve.height,o.offsetX=v.x+l+(Ve.header.width+$e.width/2),o.offsetY=v.y+$e.height/2):(s.width=Ve.width,s.height=Ve.header.height,o.width=Ve.width,o.height=Ve.height-s.height,o.offsetX=v.x+l+$e.width/2,o.offsetY=v.y+(Ve.header.height+$e.height/2)),s.offsetX=v.x+l+ot.width/2,s.offsetY=v.y+ot.height/2,f.width=Ve.width,f.height=Ve.height}if(f instanceof te&&f.shape.isPhase&&(g?f.height=1:f.width=1),!e.activeLayer.lock&&!A.cancel){if(e.preventDiagramUpdate=!0,f.children&&e.findChild(f,r),e.preventDiagramUpdate=!0,f.zIndex!==Number.MIN_VALUE&&(f.zIndex=Number.MIN_VALUE),e.initObject(f,void 0,void 0,!0),e.bpmnModule)for(var Mi=0;Mi0&&(S.segments=[]),d=this.add(S,!0)),(S||d)&&(_v(this)||Uv(this))&&this.select([this.nameTable[S[""+b]]],!1,this.previousSelectedObjects),y.target&&y.target instanceof de&&!0===this.enableConnectorSplit&&this.nameTable[S[""+b]]instanceof te&&(this.commandHandler.connectorSplit(this.nameTable[S[""+b]],y.target),this.commandHandler.PreventConnectorSplit=!1))),this.protectPropertyChange(!1),v=this.nameTable[S[""+b]],S.hasTarget&&(S.nodeId=S.hasTarget,this.remove(S)),this.bpmnModule&&v instanceof te&&S.processId&&(v.processId=S.processId,this.bpmnModule.dropBPMNchild(this.nameTable[v.processId],v,this)),y.cancel||this.endGroupAction(),"SVG"!==this.mode&&this.refreshDiagramLayer(),delete this.droppable[""+c]):(this.triggerEvent(Ce.drop,y={source:h.droppedElement,element:void 0,target:this.eventHandler.hoverNode||this.eventHandler.lastObjectUnderMouse||this,cancel:!1,position:void 0}),S=void 0,b="id"),this.droppable[M="selectedSymbols"]&&this.droppable[""+M].parentNode)gt(this.droppable[""+M]);else for(w=document.getElementsByClassName("e-dragclone"),C=0;C0)for(var p=0;p1),e.previousSelectedObject=null}}},t.prototype.getDropEventArgs=function(e){if(this.eventHandler.lastObjectUnderMouse||this.eventHandler.hoverNode){var i=this.eventHandler.lastObjectUnderMouse||this.eventHandler.hoverNode;e.target=fs(i)===de?{connector:i}:{node:i}}else e.target.diagramId=this.element.id},t.prototype.removeChildInNodes=function(e){if(e){if(e.children)for(var i=0;i1){var l=2;if(e.children&&e.children.length>0)for(;e.children.indexOf(i.objects[s-l])>-1;)l++;this.commandHandler.moveSvgNode(e.id,i.objects[s-l]),this.commandHandler.moveSvgNode(i.objects[s-l],e.id)}else if(o){var h=this.commandHandler.getLayer(this.layerZIndexTable[o.zIndex]).objects[0];h?(this.commandHandler.moveSvgNode(e.id,h),this.commandHandler.updateNativeNodeIndex(e.id,h)):this.moveObjectsUp(e,i)}else this.moveObjectsUp(e,i)},t.prototype.moveObjectsUp=function(e,i){for(var r,s=this.layers.length-1;s>=0;s--)if(r=this.layers[parseInt(s.toString(),10)],i.id!==r.id){var o=this.commandHandler.getLayer(this.layerZIndexTable[r.zIndex]).objects[r.objects.length-1];if(o){this.commandHandler.moveSvgNode(e.id,o),this.commandHandler.moveSvgNode(o,e.id);break}}},t.prototype.insertData=function(e){return this.crudOperation(e,"create",this.getNewUpdateNodes("New"))},t.prototype.updateData=function(e){return this.crudOperation(e,"update",this.getNewUpdateNodes("Update"))},t.prototype.removeData=function(e){return this.crudOperation(e,"destroy",this.getDeletedNodes())},t.prototype.crudOperation=function(e,i,r){if(e){var s=this.parameterMap(e,!(e instanceof de));if(s){var o=e instanceof de?this.dataSourceSettings.connectionDataSource.crudAction[""+i]:this.dataSourceSettings.crudAction[""+i];this.raiseAjaxPost(JSON.stringify(s),o)}return s}var a=r;return this.processCrudCollection(a,this.dataSourceSettings.crudAction[""+i],this.dataSourceSettings.connectionDataSource.crudAction[""+i]),a},t.prototype.processCrudCollection=function(e,i,r){if(e.nodes){var s=[],o=void 0;for(o=0;o0&&this.raiseAjaxPost(JSON.stringify(s),i)}if(e.connectors){for(s=[],o=void 0,o=0;o0&&this.raiseAjaxPost(JSON.stringify(s),r)}},t.prototype.parameterMap=function(e,i){var s,r={},o=i?this.dataSourceSettings:this.dataSourceSettings.connectionDataSource;if(o.id&&(r[o.id]=e.id),o.sourcePointX&&o.sourcePointY&&(r[o.sourcePointX]=e.sourcePoint.x,r[o.sourcePointY]=e.sourcePoint.y),o.targetPointX&&o.targetPointY&&(r[o.targetPointX]=e.targetPoint.x,r[o.targetPointY]=e.targetPoint.y),o.sourceID&&(r[o.sourceID]=e.sourceID),o.targetID&&(r[o.targetID]=e.targetID),o.crudAction&&o.crudAction.customFields&&o.crudAction.customFields.length>0)for(s=0;s"u"||(y.innerHTML=v.innerHTML?v.innerHTML:"",void 0!==v.className&&(y.className=v.className),void 0!==v.id&&(y.id=v.id),void 0!==v.styles&&y.setAttribute("style",v.styles),void 0!==e.ngAttr&&y.setAttribute(e.ngAttr,""),void 0!==v.attrs&&Fe(y,v.attrs)),y};for(var i=0,r=e.tags;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s}!function DZ(n){CC.compile=n.compile}({compile:function Fae(n,t){if("string"==typeof n||"function"==typeof n&&n.prototype&&n.prototype.CSPTemplate)return Bae(n,t);var e=n.elementRef.nativeElement._viewContainerRef,i=n.elementRef.nativeElement.propName;return function(r,s,o){var l=e||s.viewContainerRef,h=l.createEmbeddedView(n,{$implicit:r});/EJS-MENTION|EJS-DROPDOWNLIST/.test(Y("currentInstance.element.nodeName",l))||/E-TABITEM/.test(Y("element.nativeElement.nodeName",l))?h.detectChanges():h.markForCheck();var c=s&&s.registeredTemplate?s.registeredTemplate:Y("currentInstance.registeredTemplate",l);return typeof c["".concat(o=o&&s.registeredTemplate?o:i)]>"u"&&(c["".concat(o)]=[]),c["".concat(o)].push(h),h.rootNodes}}});const Wae=["annotationTemplate"],Yae=["nodeTemplate"],Qae=["userHandleTemplate"];let Gae=["addInfo","id","lock","objects","visible","zIndex"],Xae=[],qae=(()=>{class n extends Hh{constructor(e){super(),this.viewContainerRef=e,Rl("currentInstance",this,this.viewContainerRef),this.registerEvents(Xae),this.directivePropList=Gae}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-layer"]],inputs:{addInfo:"addInfo",id:"id",lock:"lock",objects:"objects",visible:"visible",zIndex:"zIndex"},features:[yn]}),n})(),$ae=(()=>{class n extends Bh{constructor(){super("layers")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-layers"]],contentQueries:function(e,i,r){if(1&e&&dn(r,qae,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),Zae=["action","cursor"],Jae=[],Kae=(()=>{class n extends Hh{constructor(e){super(),this.viewContainerRef=e,Rl("currentInstance",this,this.viewContainerRef),this.registerEvents(Jae),this.directivePropList=Zae}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-cursormap"]],inputs:{action:"action",cursor:"cursor"},features:[yn]}),n})(),ele=(()=>{class n extends Bh{constructor(){super("customcursor")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-cursormaps"]],contentQueries:function(e,i,r){if(1&e&&dn(r,Kae,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),tle=["alignment","cornerRadius","displacement","fill","handleStrokeColor","handleStrokeWidth","height","iconStrokeColor","iconStrokeWidth","id","offset","padding","pathData","tooltip","visibility","width"],ile=[],rle=(()=>{class n extends Hh{constructor(e){super(),this.viewContainerRef=e,Rl("currentInstance",this,this.viewContainerRef),this.registerEvents(ile),this.directivePropList=tle}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-connector-fixeduserhandle"]],inputs:{alignment:"alignment",cornerRadius:"cornerRadius",displacement:"displacement",fill:"fill",handleStrokeColor:"handleStrokeColor",handleStrokeWidth:"handleStrokeWidth",height:"height",iconStrokeColor:"iconStrokeColor",iconStrokeWidth:"iconStrokeWidth",id:"id",offset:"offset",padding:"padding",pathData:"pathData",tooltip:"tooltip",visibility:"visibility",width:"width"},features:[yn]}),n})(),nle=(()=>{class n extends Bh{constructor(){super("fixeduserhandles")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-connector-fixeduserhandles"]],contentQueries:function(e,i,r){if(1&e&&dn(r,rle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),sle=["addInfo","alignment","annotationType","constraints","content","displacement","dragLimit","height","horizontalAlignment","hyperlink","id","margin","offset","rotateAngle","rotationReference","segmentAngle","style","template","tooltip","type","verticalAlignment","visibility","width"],ole=[],ale=(()=>{class n extends Hh{constructor(e){super(),this.viewContainerRef=e,Rl("currentInstance",this,this.viewContainerRef),this.registerEvents(ole),this.directivePropList=sle}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-connector-annotation"]],inputs:{addInfo:"addInfo",alignment:"alignment",annotationType:"annotationType",constraints:"constraints",content:"content",displacement:"displacement",dragLimit:"dragLimit",height:"height",horizontalAlignment:"horizontalAlignment",hyperlink:"hyperlink",id:"id",margin:"margin",offset:"offset",rotateAngle:"rotateAngle",rotationReference:"rotationReference",segmentAngle:"segmentAngle",style:"style",template:"template",tooltip:"tooltip",type:"type",verticalAlignment:"verticalAlignment",visibility:"visibility",width:"width"},features:[yn]}),n})(),lle=(()=>{class n extends Bh{constructor(){super("annotations")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-connector-annotations"]],contentQueries:function(e,i,r){if(1&e&&dn(r,ale,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),hle=["addInfo","allowNodeOverlap","annotations","bezierSettings","bridgeSpace","connectionPadding","connectorSpacing","constraints","cornerRadius","dragSize","excludeFromLayout","fixedUserHandles","flip","flipMode","hitPadding","id","margin","maxSegmentThumb","ports","previewSize","segmentThumbShape","segmentThumbSize","segments","shape","sourceDecorator","sourceID","sourcePadding","sourcePoint","sourcePortID","style","symbolInfo","targetDecorator","targetID","targetPadding","targetPoint","targetPortID","tooltip","type","visible","wrapper","zIndex"],cle=[],dle=(()=>{class n extends Hh{constructor(e){super(),this.viewContainerRef=e,this.tags=["fixedUserHandles","annotations"],Rl("currentInstance",this,this.viewContainerRef),this.registerEvents(cle),this.directivePropList=hle}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-connector"]],contentQueries:function(e,i,r){if(1&e&&(dn(r,nle,5),dn(r,lle,5)),2&e){let s;Kr(s=en())&&(i.childFixedUserHandles=s.first),Kr(s=en())&&(i.childAnnotations=s.first)}},inputs:{addInfo:"addInfo",allowNodeOverlap:"allowNodeOverlap",annotations:"annotations",bezierSettings:"bezierSettings",bridgeSpace:"bridgeSpace",connectionPadding:"connectionPadding",connectorSpacing:"connectorSpacing",constraints:"constraints",cornerRadius:"cornerRadius",dragSize:"dragSize",excludeFromLayout:"excludeFromLayout",fixedUserHandles:"fixedUserHandles",flip:"flip",flipMode:"flipMode",hitPadding:"hitPadding",id:"id",margin:"margin",maxSegmentThumb:"maxSegmentThumb",ports:"ports",previewSize:"previewSize",segmentThumbShape:"segmentThumbShape",segmentThumbSize:"segmentThumbSize",segments:"segments",shape:"shape",sourceDecorator:"sourceDecorator",sourceID:"sourceID",sourcePadding:"sourcePadding",sourcePoint:"sourcePoint",sourcePortID:"sourcePortID",style:"style",symbolInfo:"symbolInfo",targetDecorator:"targetDecorator",targetID:"targetID",targetPadding:"targetPadding",targetPoint:"targetPoint",targetPortID:"targetPortID",tooltip:"tooltip",type:"type",visible:"visible",wrapper:"wrapper",zIndex:"zIndex"},features:[yn]}),n})(),ule=(()=>{class n extends Bh{constructor(){super("connectors")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-connectors"]],contentQueries:function(e,i,r){if(1&e&&dn(r,dle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),ple=["cornerRadius","fill","handleStrokeColor","handleStrokeWidth","height","iconStrokeColor","iconStrokeWidth","id","margin","offset","padding","pathData","tooltip","visibility","width"],fle=[],gle=(()=>{class n extends Hh{constructor(e){super(),this.viewContainerRef=e,Rl("currentInstance",this,this.viewContainerRef),this.registerEvents(fle),this.directivePropList=ple}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-node-fixeduserhandle"]],inputs:{cornerRadius:"cornerRadius",fill:"fill",handleStrokeColor:"handleStrokeColor",handleStrokeWidth:"handleStrokeWidth",height:"height",iconStrokeColor:"iconStrokeColor",iconStrokeWidth:"iconStrokeWidth",id:"id",margin:"margin",offset:"offset",padding:"padding",pathData:"pathData",tooltip:"tooltip",visibility:"visibility",width:"width"},features:[yn]}),n})(),vle=(()=>{class n extends Bh{constructor(){super("fixeduserhandles")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-node-fixeduserhandles"]],contentQueries:function(e,i,r){if(1&e&&dn(r,gle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),mle=["addInfo","annotationType","constraints","content","dragLimit","height","horizontalAlignment","hyperlink","id","margin","offset","rotateAngle","rotationReference","style","template","tooltip","type","verticalAlignment","visibility","width"],yle=[],Sle=(()=>{class n extends Hh{constructor(e){super(),this.viewContainerRef=e,Rl("currentInstance",this,this.viewContainerRef),this.registerEvents(yle),this.directivePropList=mle}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-node-annotation"]],inputs:{addInfo:"addInfo",annotationType:"annotationType",constraints:"constraints",content:"content",dragLimit:"dragLimit",height:"height",horizontalAlignment:"horizontalAlignment",hyperlink:"hyperlink",id:"id",margin:"margin",offset:"offset",rotateAngle:"rotateAngle",rotationReference:"rotationReference",style:"style",template:"template",tooltip:"tooltip",type:"type",verticalAlignment:"verticalAlignment",visibility:"visibility",width:"width"},features:[yn]}),n})(),Ile=(()=>{class n extends Bh{constructor(){super("annotations")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-node-annotations"]],contentQueries:function(e,i,r){if(1&e&&dn(r,Sle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),ble=["addInfo","connectionDirection","constraints","height","horizontalAlignment","id","inEdges","margin","offset","outEdges","pathData","shape","style","tooltip","verticalAlignment","visibility","width"],Mle=[],wle=(()=>{class n extends Hh{constructor(e){super(),this.viewContainerRef=e,Rl("currentInstance",this,this.viewContainerRef),this.registerEvents(Mle),this.directivePropList=ble}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-node-port"]],inputs:{addInfo:"addInfo",connectionDirection:"connectionDirection",constraints:"constraints",height:"height",horizontalAlignment:"horizontalAlignment",id:"id",inEdges:"inEdges",margin:"margin",offset:"offset",outEdges:"outEdges",pathData:"pathData",shape:"shape",style:"style",tooltip:"tooltip",verticalAlignment:"verticalAlignment",visibility:"visibility",width:"width"},features:[yn]}),n})(),Cle=(()=>{class n extends Bh{constructor(){super("ports")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-node-ports"]],contentQueries:function(e,i,r){if(1&e&&dn(r,wle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),Ele=["addInfo","annotations","backgroundColor","borderColor","borderWidth","branch","children","collapseIcon","columnIndex","columnSpan","columns","constraints","container","data","dragSize","excludeFromLayout","expandIcon","fixedUserHandles","flip","flipMode","height","horizontalAlignment","id","isExpanded","layoutInfo","margin","maxHeight","maxWidth","minHeight","minWidth","offsetX","offsetY","padding","pivot","ports","previewSize","rotateAngle","rowIndex","rowSpan","rows","shadow","shape","style","symbolInfo","tooltip","verticalAlignment","visible","width","wrapper","zIndex"],Dle=[],v_=(()=>{class n extends Hh{constructor(e){super(),this.viewContainerRef=e,this.tags=["fixedUserHandles","annotations","ports"],Rl("currentInstance",this,this.viewContainerRef),this.registerEvents(Dle),this.directivePropList=Ele}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-node"]],contentQueries:function(e,i,r){if(1&e&&(dn(r,vle,5),dn(r,Ile,5),dn(r,Cle,5)),2&e){let s;Kr(s=en())&&(i.childFixedUserHandles=s.first),Kr(s=en())&&(i.childAnnotations=s.first),Kr(s=en())&&(i.childPorts=s.first)}},inputs:{addInfo:"addInfo",annotations:"annotations",backgroundColor:"backgroundColor",borderColor:"borderColor",borderWidth:"borderWidth",branch:"branch",children:"children",collapseIcon:"collapseIcon",columnIndex:"columnIndex",columnSpan:"columnSpan",columns:"columns",constraints:"constraints",container:"container",data:"data",dragSize:"dragSize",excludeFromLayout:"excludeFromLayout",expandIcon:"expandIcon",fixedUserHandles:"fixedUserHandles",flip:"flip",flipMode:"flipMode",height:"height",horizontalAlignment:"horizontalAlignment",id:"id",isExpanded:"isExpanded",layoutInfo:"layoutInfo",margin:"margin",maxHeight:"maxHeight",maxWidth:"maxWidth",minHeight:"minHeight",minWidth:"minWidth",offsetX:"offsetX",offsetY:"offsetY",padding:"padding",pivot:"pivot",ports:"ports",previewSize:"previewSize",rotateAngle:"rotateAngle",rowIndex:"rowIndex",rowSpan:"rowSpan",rows:"rows",shadow:"shadow",shape:"shape",style:"style",symbolInfo:"symbolInfo",tooltip:"tooltip",verticalAlignment:"verticalAlignment",visible:"visible",width:"width",wrapper:"wrapper",zIndex:"zIndex"},features:[yn]}),n})(),m_=(()=>{class n extends Bh{constructor(){super("nodes")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-nodes"]],contentQueries:function(e,i,r){if(1&e&&dn(r,v_,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})();const xle=["animationComplete","click","collectionChange","commandExecute","connectionChange","contextMenuBeforeItemRender","contextMenuClick","contextMenuOpen","created","dataLoaded","doubleClick","dragEnter","dragLeave","dragOver","drop","elementDraw","expandStateChange","fixedUserHandleClick","historyChange","historyStateChange","keyDown","keyUp","load","loaded","mouseEnter","mouseLeave","mouseOver","mouseWheel","onFixedUserHandleMouseDown","onFixedUserHandleMouseEnter","onFixedUserHandleMouseLeave","onFixedUserHandleMouseUp","onImageLoad","onUserHandleMouseDown","onUserHandleMouseEnter","onUserHandleMouseLeave","onUserHandleMouseUp","positionChange","propertyChange","rotateChange","scrollChange","segmentChange","segmentCollectionChange","selectionChange","sizeChange","sourcePointChange","targetPointChange","textEdit"],Tle=[""];let Ale=(()=>{let n=class extends zl{constructor(e,i,r,s){super(),this.ngEle=e,this.srenderer=i,this.viewContainerRef=r,this.injector=s,this.tags=["layers","customCursor","connectors","nodes"],this.element=this.ngEle.nativeElement,this.injectedModules=this.injectedModules||[];try{let o=this.injector.get("DiagramsHierarchicalTree");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsMindMap");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsRadialTree");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsComplexHierarchicalTree");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsDataBinding");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsSnapping");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsPrintAndExport");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsBpmnDiagrams");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsSymmetricLayout");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsConnectorBridging");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsUndoRedo");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsLayoutAnimation");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsDiagramContextMenu");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsLineRouting");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsConnectorEditing");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsLineDistribution");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsEj1Serialization");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsFlowchartLayout");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}this.registerEvents(xle),this.addTwoWay.call(this,Tle),Rl("currentInstance",this,this.viewContainerRef),this.context=new u_}ngOnInit(){this.context.ngOnInit(this)}ngAfterViewInit(){this.context.ngAfterViewInit(this)}ngOnDestroy(){this.context.ngOnDestroy(this)}ngAfterContentChecked(){this.tagObjects[0].instance=this.childLayers,this.childCustomCursor&&(this.tagObjects[1].instance=this.childCustomCursor),this.childConnectors&&(this.tagObjects[2].instance=this.childConnectors),this.childNodes&&(this.tagObjects[3].instance=this.childNodes),this.context.ngAfterContentChecked(this)}};return n.\u0275fac=function(e){return new(e||n)(Ot($c),Ot(oM),Ot(xn),Ot(Wo))},n.\u0275cmp=Rb({type:n,selectors:[["ejs-diagram"]],contentQueries:function(e,i,r){if(1&e&&(dn(r,Wae,5),dn(r,Yae,5),dn(r,Qae,5),dn(r,$ae,5),dn(r,ele,5),dn(r,ule,5),dn(r,m_,5)),2&e){let s;Kr(s=en())&&(i.annotationTemplate=s.first),Kr(s=en())&&(i.nodeTemplate=s.first),Kr(s=en())&&(i.userHandleTemplate=s.first),Kr(s=en())&&(i.childLayers=s.first),Kr(s=en())&&(i.childCustomCursor=s.first),Kr(s=en())&&(i.childConnectors=s.first),Kr(s=en())&&(i.childNodes=s.first)}},inputs:{addInfo:"addInfo",annotationTemplate:"annotationTemplate",backgroundColor:"backgroundColor",bridgeDirection:"bridgeDirection",commandManager:"commandManager",connectorDefaults:"connectorDefaults",connectors:"connectors",constraints:"constraints",contextMenuSettings:"contextMenuSettings",customCursor:"customCursor",dataSourceSettings:"dataSourceSettings",diagramSettings:"diagramSettings",drawingObject:"drawingObject",enableConnectorSplit:"enableConnectorSplit",enablePersistence:"enablePersistence",enableRtl:"enableRtl",fixedUserHandleTemplate:"fixedUserHandleTemplate",getConnectorDefaults:"getConnectorDefaults",getCustomCursor:"getCustomCursor",getCustomProperty:"getCustomProperty",getCustomTool:"getCustomTool",getDescription:"getDescription",getNodeDefaults:"getNodeDefaults",height:"height",historyManager:"historyManager",layers:"layers",layout:"layout",locale:"locale",mode:"mode",nodeDefaults:"nodeDefaults",nodeTemplate:"nodeTemplate",nodes:"nodes",pageSettings:"pageSettings",rulerSettings:"rulerSettings",scrollSettings:"scrollSettings",segmentThumbShape:"segmentThumbShape",segmentThumbSize:"segmentThumbSize",selectedItems:"selectedItems",serializationSettings:"serializationSettings",setNodeTemplate:"setNodeTemplate",snapSettings:"snapSettings",tool:"tool",tooltip:"tooltip",updateSelection:"updateSelection",userHandleTemplate:"userHandleTemplate",width:"width"},outputs:{animationComplete:"animationComplete",click:"click",collectionChange:"collectionChange",commandExecute:"commandExecute",connectionChange:"connectionChange",contextMenuBeforeItemRender:"contextMenuBeforeItemRender",contextMenuClick:"contextMenuClick",contextMenuOpen:"contextMenuOpen",created:"created",dataLoaded:"dataLoaded",doubleClick:"doubleClick",dragEnter:"dragEnter",dragLeave:"dragLeave",dragOver:"dragOver",drop:"drop",elementDraw:"elementDraw",expandStateChange:"expandStateChange",fixedUserHandleClick:"fixedUserHandleClick",historyChange:"historyChange",historyStateChange:"historyStateChange",keyDown:"keyDown",keyUp:"keyUp",load:"load",loaded:"loaded",mouseEnter:"mouseEnter",mouseLeave:"mouseLeave",mouseOver:"mouseOver",mouseWheel:"mouseWheel",onFixedUserHandleMouseDown:"onFixedUserHandleMouseDown",onFixedUserHandleMouseEnter:"onFixedUserHandleMouseEnter",onFixedUserHandleMouseLeave:"onFixedUserHandleMouseLeave",onFixedUserHandleMouseUp:"onFixedUserHandleMouseUp",onImageLoad:"onImageLoad",onUserHandleMouseDown:"onUserHandleMouseDown",onUserHandleMouseEnter:"onUserHandleMouseEnter",onUserHandleMouseLeave:"onUserHandleMouseLeave",onUserHandleMouseUp:"onUserHandleMouseUp",positionChange:"positionChange",propertyChange:"propertyChange",rotateChange:"rotateChange",scrollChange:"scrollChange",segmentChange:"segmentChange",segmentCollectionChange:"segmentCollectionChange",selectionChange:"selectionChange",sizeChange:"sizeChange",sourcePointChange:"sourcePointChange",targetPointChange:"targetPointChange",textEdit:"textEdit"},features:[yn],decls:0,vars:0,template:function(e,i){},encapsulation:2,changeDetection:0}),ub([TT()],n.prototype,"annotationTemplate",void 0),ub([TT()],n.prototype,"nodeTemplate",void 0),ub([TT()],n.prototype,"userHandleTemplate",void 0),n=ub([Rae([u_])],n),n})(),Lle=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Am({type:n}),n.\u0275inj=gf({imports:[[rq]]}),n})();const Nle=["diagram"];let Ole=(()=>{class n{constructor(){this.ports=[{id:"port1",offset:{x:0,y:.5},visibility:Gt.Visible},{id:"port2",offset:{x:1,y:.5},visibility:Gt.Visible},{id:"port3",offset:{x:.5,y:0},visibility:Gt.Visible},{id:"port4",offset:{x:.5,y:1},visibility:Gt.Visible}]}addPort(){this.diagram.addPorts(this.diagram.nodes[0],this.ports)}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275cmp=Rb({type:n,selectors:[["app-container"]],viewQuery:function(i,r){if(1&i&&function uP(n,t,e){const i=xi();i.firstCreatePass&&(cP(i,new aP(n,t,e),-1),2==(2&t)&&(i.staticViewQueries=!0)),hP(i,Se(),t)}(Nle,5),2&i){let s;Kr(s=en())&&(r.diagram=s.first)}},standalone:!0,features:[PP([]),RP],decls:6,vars:4,consts:[["id","diagram","width","100%","height","580px"],["diagram",""],["id","node1",3,"offsetX","offsetY","width","height"],[3,"click"]],template:function(i,r){1&i&&(lg(0,"ejs-diagram",0,1)(2,"e-nodes"),ew(3,"e-node",2),hg()(),lg(4,"button",3),ow("click",function(){return r.addPort()}),function MP(n,t=""){const e=Se(),i=xi(),r=n+Ut,s=i.firstCreatePass?xu(i,r,1,t,null):i.data[r],o=wP(i,e,s,t,n);e[r]=o,Rm()&&ly(i,e,o,s),ol(s,!1)}(5,"AddPort"),hg()),2&i&&(function CN(n=1){EN(xi(),Se(),zs()+n,!1)}(3),GM("offsetX",250)("offsetY",250)("width",100)("height",100))},dependencies:[Lle,Ale,v_,m_],encapsulation:2})}}return n})();Ud(332),function Xq(n,t){return CG({rootComponent:n,...Ez(t)})}(Ole).catch(n=>console.error(n))},332:()=>{!function(Z){const se=Z.performance;function ye(Pi){se&&se.mark&&se.mark(Pi)}function fe(Pi,ht){se&&se.measure&&se.measure(Pi,ht)}ye("Zone");const be=Z.__Zone_symbol_prefix||"__zone_symbol__";function ke(Pi){return be+Pi}const at=!0===Z[ke("forceDuplicateZoneCheck")];if(Z.Zone){if(at||"function"!=typeof Z.Zone.__symbol__)throw new Error("Zone already loaded.");return Z.Zone}let tt=(()=>{class Pi{static{this.__symbol__=ke}static assertZonePatched(){if(Z.Promise!==_o.ZoneAwarePromise)throw new Error("Zone.js has detected that ZoneAwarePromise `(window|global).Promise` has been overwritten.\nMost likely cause is that a Promise polyfill has been loaded after Zone.js (Polyfilling Promise api is not necessary when zone.js is loaded. If you must load one, do so before loading zone.js.)")}static get root(){let F=Pi.current;for(;F.parent;)F=F.parent;return F}static get current(){return Ur.zone}static get currentTask(){return Do}static __load_patch(F,ae,Et=!1){if(_o.hasOwnProperty(F)){if(!Et&&at)throw Error("Already loaded patch: "+F)}else if(!Z["__Zone_disable_"+F]){const qt="Zone:"+F;ye(qt),_o[F]=ae(Z,Pi,cn),fe(qt,qt)}}get parent(){return this._parent}get name(){return this._name}constructor(F,ae){this._parent=F,this._name=ae?ae.name||"unnamed":"",this._properties=ae&&ae.properties||{},this._zoneDelegate=new Lt(this,this._parent&&this._parent._zoneDelegate,ae)}get(F){const ae=this.getZoneWith(F);if(ae)return ae._properties[F]}getZoneWith(F){let ae=this;for(;ae;){if(ae._properties.hasOwnProperty(F))return ae;ae=ae._parent}return null}fork(F){if(!F)throw new Error("ZoneSpec required!");return this._zoneDelegate.fork(this,F)}wrap(F,ae){if("function"!=typeof F)throw new Error("Expecting function got: "+F);const Et=this._zoneDelegate.intercept(this,F,ae),qt=this;return function(){return qt.runGuarded(Et,this,arguments,ae)}}run(F,ae,Et,qt){Ur={parent:Ur,zone:this};try{return this._zoneDelegate.invoke(this,F,ae,Et,qt)}finally{Ur=Ur.parent}}runGuarded(F,ae=null,Et,qt){Ur={parent:Ur,zone:this};try{try{return this._zoneDelegate.invoke(this,F,ae,Et,qt)}catch(Un){if(this._zoneDelegate.handleError(this,Un))throw Un}}finally{Ur=Ur.parent}}runTask(F,ae,Et){if(F.zone!=this)throw new Error("A task can only be run in the zone of creation! (Creation: "+(F.zone||_n).name+"; Execution: "+this.name+")");if(F.state===sr&&(F.type===ts||F.type===Pt))return;const qt=F.state!=lt;qt&&F._transitionTo(lt,ki),F.runCount++;const Un=Do;Do=F,Ur={parent:Ur,zone:this};try{F.type==Pt&&F.data&&!F.data.isPeriodic&&(F.cancelFn=void 0);try{return this._zoneDelegate.invokeTask(this,F,ae,Et)}catch(Ue){if(this._zoneDelegate.handleError(this,Ue))throw Ue}}finally{F.state!==sr&&F.state!==et&&(F.type==ts||F.data&&F.data.isPeriodic?qt&&F._transitionTo(ki,lt):(F.runCount=0,this._updateTaskCount(F,-1),qt&&F._transitionTo(sr,lt,sr))),Ur=Ur.parent,Do=Un}}scheduleTask(F){if(F.zone&&F.zone!==this){let Et=this;for(;Et;){if(Et===F.zone)throw Error(`can not reschedule task to ${this.name} which is descendants of the original zone ${F.zone.name}`);Et=Et.parent}}F._transitionTo(Zr,sr);const ae=[];F._zoneDelegates=ae,F._zone=this;try{F=this._zoneDelegate.scheduleTask(this,F)}catch(Et){throw F._transitionTo(et,Zr,sr),this._zoneDelegate.handleError(this,Et),Et}return F._zoneDelegates===ae&&this._updateTaskCount(F,1),F.state==Zr&&F._transitionTo(ki,Zr),F}scheduleMicroTask(F,ae,Et,qt){return this.scheduleTask(new ft(vi,F,ae,Et,qt,void 0))}scheduleMacroTask(F,ae,Et,qt,Un){return this.scheduleTask(new ft(Pt,F,ae,Et,qt,Un))}scheduleEventTask(F,ae,Et,qt,Un){return this.scheduleTask(new ft(ts,F,ae,Et,qt,Un))}cancelTask(F){if(F.zone!=this)throw new Error("A task can only be cancelled in the zone of creation! (Creation: "+(F.zone||_n).name+"; Execution: "+this.name+")");if(F.state===ki||F.state===lt){F._transitionTo(dr,ki,lt);try{this._zoneDelegate.cancelTask(this,F)}catch(ae){throw F._transitionTo(et,dr),this._zoneDelegate.handleError(this,ae),ae}return this._updateTaskCount(F,-1),F._transitionTo(sr,dr),F.runCount=0,F}}_updateTaskCount(F,ae){const Et=F._zoneDelegates;-1==ae&&(F._zoneDelegates=null);for(let qt=0;qtPi.hasTask(F,ae),onScheduleTask:(Pi,ht,F,ae)=>Pi.scheduleTask(F,ae),onInvokeTask:(Pi,ht,F,ae,Et,qt)=>Pi.invokeTask(F,ae,Et,qt),onCancelTask:(Pi,ht,F,ae)=>Pi.cancelTask(F,ae)};class Lt{constructor(ht,F,ae){this._taskCounts={microTask:0,macroTask:0,eventTask:0},this.zone=ht,this._parentDelegate=F,this._forkZS=ae&&(ae&&ae.onFork?ae:F._forkZS),this._forkDlgt=ae&&(ae.onFork?F:F._forkDlgt),this._forkCurrZone=ae&&(ae.onFork?this.zone:F._forkCurrZone),this._interceptZS=ae&&(ae.onIntercept?ae:F._interceptZS),this._interceptDlgt=ae&&(ae.onIntercept?F:F._interceptDlgt),this._interceptCurrZone=ae&&(ae.onIntercept?this.zone:F._interceptCurrZone),this._invokeZS=ae&&(ae.onInvoke?ae:F._invokeZS),this._invokeDlgt=ae&&(ae.onInvoke?F:F._invokeDlgt),this._invokeCurrZone=ae&&(ae.onInvoke?this.zone:F._invokeCurrZone),this._handleErrorZS=ae&&(ae.onHandleError?ae:F._handleErrorZS),this._handleErrorDlgt=ae&&(ae.onHandleError?F:F._handleErrorDlgt),this._handleErrorCurrZone=ae&&(ae.onHandleError?this.zone:F._handleErrorCurrZone),this._scheduleTaskZS=ae&&(ae.onScheduleTask?ae:F._scheduleTaskZS),this._scheduleTaskDlgt=ae&&(ae.onScheduleTask?F:F._scheduleTaskDlgt),this._scheduleTaskCurrZone=ae&&(ae.onScheduleTask?this.zone:F._scheduleTaskCurrZone),this._invokeTaskZS=ae&&(ae.onInvokeTask?ae:F._invokeTaskZS),this._invokeTaskDlgt=ae&&(ae.onInvokeTask?F:F._invokeTaskDlgt),this._invokeTaskCurrZone=ae&&(ae.onInvokeTask?this.zone:F._invokeTaskCurrZone),this._cancelTaskZS=ae&&(ae.onCancelTask?ae:F._cancelTaskZS),this._cancelTaskDlgt=ae&&(ae.onCancelTask?F:F._cancelTaskDlgt),this._cancelTaskCurrZone=ae&&(ae.onCancelTask?this.zone:F._cancelTaskCurrZone),this._hasTaskZS=null,this._hasTaskDlgt=null,this._hasTaskDlgtOwner=null,this._hasTaskCurrZone=null;const Et=ae&&ae.onHasTask;(Et||F&&F._hasTaskZS)&&(this._hasTaskZS=Et?ae:At,this._hasTaskDlgt=F,this._hasTaskDlgtOwner=this,this._hasTaskCurrZone=ht,ae.onScheduleTask||(this._scheduleTaskZS=At,this._scheduleTaskDlgt=F,this._scheduleTaskCurrZone=this.zone),ae.onInvokeTask||(this._invokeTaskZS=At,this._invokeTaskDlgt=F,this._invokeTaskCurrZone=this.zone),ae.onCancelTask||(this._cancelTaskZS=At,this._cancelTaskDlgt=F,this._cancelTaskCurrZone=this.zone))}fork(ht,F){return this._forkZS?this._forkZS.onFork(this._forkDlgt,this.zone,ht,F):new tt(ht,F)}intercept(ht,F,ae){return this._interceptZS?this._interceptZS.onIntercept(this._interceptDlgt,this._interceptCurrZone,ht,F,ae):F}invoke(ht,F,ae,Et,qt){return this._invokeZS?this._invokeZS.onInvoke(this._invokeDlgt,this._invokeCurrZone,ht,F,ae,Et,qt):F.apply(ae,Et)}handleError(ht,F){return!this._handleErrorZS||this._handleErrorZS.onHandleError(this._handleErrorDlgt,this._handleErrorCurrZone,ht,F)}scheduleTask(ht,F){let ae=F;if(this._scheduleTaskZS)this._hasTaskZS&&ae._zoneDelegates.push(this._hasTaskDlgtOwner),ae=this._scheduleTaskZS.onScheduleTask(this._scheduleTaskDlgt,this._scheduleTaskCurrZone,ht,F),ae||(ae=F);else if(F.scheduleFn)F.scheduleFn(F);else{if(F.type!=vi)throw new Error("Task is missing scheduleFn.");Wt(F)}return ae}invokeTask(ht,F,ae,Et){return this._invokeTaskZS?this._invokeTaskZS.onInvokeTask(this._invokeTaskDlgt,this._invokeTaskCurrZone,ht,F,ae,Et):F.callback.apply(ae,Et)}cancelTask(ht,F){let ae;if(this._cancelTaskZS)ae=this._cancelTaskZS.onCancelTask(this._cancelTaskDlgt,this._cancelTaskCurrZone,ht,F);else{if(!F.cancelFn)throw Error("Task is not cancelable");ae=F.cancelFn(F)}return ae}hasTask(ht,F){try{this._hasTaskZS&&this._hasTaskZS.onHasTask(this._hasTaskDlgt,this._hasTaskCurrZone,ht,F)}catch(ae){this.handleError(ht,ae)}}_updateTaskCount(ht,F){const ae=this._taskCounts,Et=ae[ht],qt=ae[ht]=Et+F;if(qt<0)throw new Error("More tasks executed then were scheduled.");0!=Et&&0!=qt||this.hasTask(this.zone,{microTask:ae.microTask>0,macroTask:ae.macroTask>0,eventTask:ae.eventTask>0,change:ht})}}class ft{constructor(ht,F,ae,Et,qt,Un){if(this._zone=null,this.runCount=0,this._zoneDelegates=null,this._state="notScheduled",this.type=ht,this.source=F,this.data=Et,this.scheduleFn=qt,this.cancelFn=Un,!ae)throw new Error("callback is not defined");this.callback=ae;const Ue=this;this.invoke=ht===ts&&Et&&Et.useG?ft.invokeTask:function(){return ft.invokeTask.call(Z,Ue,this,arguments)}}static invokeTask(ht,F,ae){ht||(ht=this),Ls++;try{return ht.runCount++,ht.zone.runTask(ht,F,ae)}finally{1==Ls&&ct(),Ls--}}get zone(){return this._zone}get state(){return this._state}cancelScheduleRequest(){this._transitionTo(sr,Zr)}_transitionTo(ht,F,ae){if(this._state!==F&&this._state!==ae)throw new Error(`${this.type} '${this.source}': can not transition to '${ht}', expecting state '${F}'${ae?" or '"+ae+"'":""}, was '${this._state}'.`);this._state=ht,ht==sr&&(this._zoneDelegates=null)}toString(){return this.data&&typeof this.data.handleId<"u"?this.data.handleId.toString():Object.prototype.toString.call(this)}toJSON(){return{type:this.type,state:this.state,source:this.source,zone:this.zone.name,runCount:this.runCount}}}const Ei=ke("setTimeout"),ii=ke("Promise"),gi=ke("then");let es,cr=[],Oi=!1;function kr(Pi){if(es||Z[ii]&&(es=Z[ii].resolve(0)),es){let ht=es[gi];ht||(ht=es.then),ht.call(es,Pi)}else Z[Ei](Pi,0)}function Wt(Pi){0===Ls&&0===cr.length&&kr(ct),Pi&&cr.push(Pi)}function ct(){if(!Oi){for(Oi=!0;cr.length;){const Pi=cr;cr=[];for(let ht=0;htUr,onUnhandledError:jr,microtaskDrainDone:jr,scheduleMicroTask:Wt,showUncaughtError:()=>!tt[ke("ignoreConsoleErrorUncaughtError")],patchEventTarget:()=>[],patchOnProperties:jr,patchMethod:()=>jr,bindArguments:()=>[],patchThen:()=>jr,patchMacroTask:()=>jr,patchEventPrototype:()=>jr,isIEOrEdge:()=>!1,getGlobalObjects:()=>{},ObjectDefineProperty:()=>jr,ObjectGetOwnPropertyDescriptor:()=>{},ObjectCreate:()=>{},ArraySlice:()=>[],patchClass:()=>jr,wrapWithCurrentZone:()=>jr,filterProperties:()=>[],attachOriginToPatched:()=>jr,_redefineProperty:()=>jr,patchCallbacks:()=>jr,nativeScheduleMicroTask:kr};let Ur={parent:null,zone:new tt(null,null)},Do=null,Ls=0;function jr(){}fe("Zone","Zone"),Z.Zone=tt}(globalThis);const _l=Object.getOwnPropertyDescriptor,_d=Object.defineProperty,Ud=Object.getPrototypeOf,jd=Object.create,gb=Array.prototype.slice,pm="addEventListener",$r="removeEventListener",Ul=Zone.__symbol__(pm),Fh=Zone.__symbol__($r),Ts="true",Wi="false",Vd=Zone.__symbol__("");function of(Z,se){return Zone.current.wrap(Z,se)}function fm(Z,se,ye,fe,be){return Zone.current.scheduleMacroTask(Z,se,ye,fe,be)}const Ji=Zone.__symbol__,_h=typeof window<"u",Uh=_h?window:void 0,gn=_h&&Uh||globalThis,gm="removeAttribute";function Wd(Z,se){for(let ye=Z.length-1;ye>=0;ye--)"function"==typeof Z[ye]&&(Z[ye]=of(Z[ye],se+"_"+ye));return Z}function af(Z){return!Z||!1!==Z.writable&&!("function"==typeof Z.get&&typeof Z.set>"u")}const lf=typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope,jh=!("nw"in gn)&&typeof gn.process<"u"&&"[object process]"==={}.toString.call(gn.process),Yd=!jh&&!lf&&!(!_h||!Uh.HTMLElement),hf=typeof gn.process<"u"&&"[object process]"==={}.toString.call(gn.process)&&!lf&&!(!_h||!Uh.HTMLElement),jl={},Vh=function(Z){if(!(Z=Z||gn.event))return;let se=jl[Z.type];se||(se=jl[Z.type]=Ji("ON_PROPERTY"+Z.type));const ye=this||Z.target||gn,fe=ye[se];let be;return Yd&&ye===Uh&&"error"===Z.type?(be=fe&&fe.call(this,Z.message,Z.filename,Z.lineno,Z.colno,Z.error),!0===be&&Z.preventDefault()):(be=fe&&fe.apply(this,arguments),null!=be&&!be&&Z.preventDefault()),be};function Vl(Z,se,ye){let fe=_l(Z,se);if(!fe&&ye&&_l(ye,se)&&(fe={enumerable:!0,configurable:!0}),!fe||!fe.configurable)return;const be=Ji("on"+se+"patched");if(Z.hasOwnProperty(be)&&Z[be])return;delete fe.writable,delete fe.value;const ke=fe.get,at=fe.set,tt=se.slice(2);let At=jl[tt];At||(At=jl[tt]=Ji("ON_PROPERTY"+tt)),fe.set=function(Lt){let ft=this;!ft&&Z===gn&&(ft=gn),ft&&("function"==typeof ft[At]&&ft.removeEventListener(tt,Vh),at&&at.call(ft,null),ft[At]=Lt,"function"==typeof Lt&&ft.addEventListener(tt,Vh,!1))},fe.get=function(){let Lt=this;if(!Lt&&Z===gn&&(Lt=gn),!Lt)return null;const ft=Lt[At];if(ft)return ft;if(ke){let Ei=ke.call(this);if(Ei)return fe.set.call(this,Ei),"function"==typeof Lt[gm]&&Lt.removeAttribute(se),Ei}return null},_d(Z,se,fe),Z[be]=!0}function cf(Z,se,ye){if(se)for(let fe=0;fefunction(at,tt){const At=ye(at,tt);return At.cbIdx>=0&&"function"==typeof tt[At.cbIdx]?fm(At.name,tt[At.cbIdx],At,be):ke.apply(at,tt)})}function Sa(Z,se){Z[Ji("OriginalDelegate")]=se}let mb=!1,Gd=!1;function yb(){if(mb)return Gd;mb=!0;try{const Z=Uh.navigator.userAgent;(-1!==Z.indexOf("MSIE ")||-1!==Z.indexOf("Trident/")||-1!==Z.indexOf("Edge/"))&&(Gd=!0)}catch{}return Gd}Zone.__load_patch("ZoneAwarePromise",(Z,se,ye)=>{const fe=Object.getOwnPropertyDescriptor,be=Object.defineProperty,at=ye.symbol,tt=[],At=!1!==Z[at("DISABLE_WRAPPING_UNCAUGHT_PROMISE_REJECTION")],Lt=at("Promise"),ft=at("then"),Ei="__creationTrace__";ye.onUnhandledError=Ue=>{if(ye.showUncaughtError()){const He=Ue&&Ue.rejection;He?console.error("Unhandled Promise rejection:",He instanceof Error?He.message:He,"; Zone:",Ue.zone.name,"; Task:",Ue.task&&Ue.task.source,"; Value:",He,He instanceof Error?He.stack:void 0):console.error(Ue)}},ye.microtaskDrainDone=()=>{for(;tt.length;){const Ue=tt.shift();try{Ue.zone.runGuarded(()=>{throw Ue.throwOriginal?Ue.rejection:Ue})}catch(He){gi(He)}}};const ii=at("unhandledPromiseRejectionHandler");function gi(Ue){ye.onUnhandledError(Ue);try{const He=se[ii];"function"==typeof He&&He.call(this,Ue)}catch{}}function cr(Ue){return Ue&&Ue.then}function Oi(Ue){return Ue}function es(Ue){return F.reject(Ue)}const kr=at("state"),Wt=at("value"),ct=at("finally"),_n=at("parentPromiseValue"),sr=at("parentPromiseState"),Zr="Promise.then",ki=null,lt=!0,dr=!1,et=0;function vi(Ue,He){return ge=>{try{cn(Ue,He,ge)}catch(We){cn(Ue,!1,We)}}}const Pt=function(){let Ue=!1;return function(ge){return function(){Ue||(Ue=!0,ge.apply(null,arguments))}}},ts="Promise resolved with itself",_o=at("currentTaskTrace");function cn(Ue,He,ge){const We=Pt();if(Ue===ge)throw new TypeError(ts);if(Ue[kr]===ki){let wt=null;try{("object"==typeof ge||"function"==typeof ge)&&(wt=ge&&ge.then)}catch(Xe){return We(()=>{cn(Ue,!1,Xe)})(),Ue}if(He!==dr&&ge instanceof F&&ge.hasOwnProperty(kr)&&ge.hasOwnProperty(Wt)&&ge[kr]!==ki)Do(ge),cn(Ue,ge[kr],ge[Wt]);else if(He!==dr&&"function"==typeof wt)try{wt.call(ge,We(vi(Ue,He)),We(vi(Ue,!1)))}catch(Xe){We(()=>{cn(Ue,!1,Xe)})()}else{Ue[kr]=He;const Xe=Ue[Wt];if(Ue[Wt]=ge,Ue[ct]===ct&&He===lt&&(Ue[kr]=Ue[sr],Ue[Wt]=Ue[_n]),He===dr&&ge instanceof Error){const mt=se.currentTask&&se.currentTask.data&&se.currentTask.data[Ei];mt&&be(ge,_o,{configurable:!0,enumerable:!1,writable:!0,value:mt})}for(let mt=0;mt{try{const dt=Ue[Wt],$t=!!ge&&ct===ge[ct];$t&&(ge[_n]=dt,ge[sr]=Xe);const li=He.run(mt,void 0,$t&&mt!==es&&mt!==Oi?[]:[dt]);cn(ge,!0,li)}catch(dt){cn(ge,!1,dt)}},ge)}const Pi=function(){},ht=Z.AggregateError;class F{static toString(){return"function ZoneAwarePromise() { [native code] }"}static resolve(He){return He instanceof F?He:cn(new this(null),lt,He)}static reject(He){return cn(new this(null),dr,He)}static withResolvers(){const He={};return He.promise=new F((ge,We)=>{He.resolve=ge,He.reject=We}),He}static any(He){if(!He||"function"!=typeof He[Symbol.iterator])return Promise.reject(new ht([],"All promises were rejected"));const ge=[];let We=0;try{for(let mt of He)We++,ge.push(F.resolve(mt))}catch{return Promise.reject(new ht([],"All promises were rejected"))}if(0===We)return Promise.reject(new ht([],"All promises were rejected"));let wt=!1;const Xe=[];return new F((mt,dt)=>{for(let $t=0;$t{wt||(wt=!0,mt(li))},li=>{Xe.push(li),We--,0===We&&(wt=!0,dt(new ht(Xe,"All promises were rejected")))})})}static race(He){let ge,We,wt=new this((dt,$t)=>{ge=dt,We=$t});function Xe(dt){ge(dt)}function mt(dt){We(dt)}for(let dt of He)cr(dt)||(dt=this.resolve(dt)),dt.then(Xe,mt);return wt}static all(He){return F.allWithCallback(He)}static allSettled(He){return(this&&this.prototype instanceof F?this:F).allWithCallback(He,{thenCallback:We=>({status:"fulfilled",value:We}),errorCallback:We=>({status:"rejected",reason:We})})}static allWithCallback(He,ge){let We,wt,Xe=new this((li,ur)=>{We=li,wt=ur}),mt=2,dt=0;const $t=[];for(let li of He){cr(li)||(li=this.resolve(li));const ur=dt;try{li.then(ir=>{$t[ur]=ge?ge.thenCallback(ir):ir,mt--,0===mt&&We($t)},ir=>{ge?($t[ur]=ge.errorCallback(ir),mt--,0===mt&&We($t)):wt(ir)})}catch(ir){wt(ir)}mt++,dt++}return mt-=2,0===mt&&We($t),Xe}constructor(He){const ge=this;if(!(ge instanceof F))throw new Error("Must be an instanceof Promise.");ge[kr]=ki,ge[Wt]=[];try{const We=Pt();He&&He(We(vi(ge,lt)),We(vi(ge,dr)))}catch(We){cn(ge,!1,We)}}get[Symbol.toStringTag](){return"Promise"}get[Symbol.species](){return F}then(He,ge){let We=this.constructor?.[Symbol.species];(!We||"function"!=typeof We)&&(We=this.constructor||F);const wt=new We(Pi),Xe=se.current;return this[kr]==ki?this[Wt].push(Xe,wt,He,ge):Ls(this,Xe,wt,He,ge),wt}catch(He){return this.then(null,He)}finally(He){let ge=this.constructor?.[Symbol.species];(!ge||"function"!=typeof ge)&&(ge=F);const We=new ge(Pi);We[ct]=ct;const wt=se.current;return this[kr]==ki?this[Wt].push(wt,We,He,He):Ls(this,wt,We,He,He),We}}F.resolve=F.resolve,F.reject=F.reject,F.race=F.race,F.all=F.all;const ae=Z[Lt]=Z.Promise;Z.Promise=F;const Et=at("thenPatched");function qt(Ue){const He=Ue.prototype,ge=fe(He,"then");if(ge&&(!1===ge.writable||!ge.configurable))return;const We=He.then;He[ft]=We,Ue.prototype.then=function(wt,Xe){return new F((dt,$t)=>{We.call(this,dt,$t)}).then(wt,Xe)},Ue[Et]=!0}return ye.patchThen=qt,ae&&(qt(ae),Ka(Z,"fetch",Ue=>function Un(Ue){return function(He,ge){let We=Ue.apply(He,ge);if(We instanceof F)return We;let wt=We.constructor;return wt[Et]||qt(wt),We}}(Ue))),Promise[se.__symbol__("uncaughtPromiseErrors")]=tt,F}),Zone.__load_patch("toString",Z=>{const se=Function.prototype.toString,ye=Ji("OriginalDelegate"),fe=Ji("Promise"),be=Ji("Error"),ke=function(){if("function"==typeof this){const Lt=this[ye];if(Lt)return"function"==typeof Lt?se.call(Lt):Object.prototype.toString.call(Lt);if(this===Promise){const ft=Z[fe];if(ft)return se.call(ft)}if(this===Error){const ft=Z[be];if(ft)return se.call(ft)}}return se.call(this)};ke[ye]=se,Function.prototype.toString=ke;const at=Object.prototype.toString;Object.prototype.toString=function(){return"function"==typeof Promise&&this instanceof Promise?"[object Promise]":at.call(this)}});let el=!1;if(typeof window<"u")try{const Z=Object.defineProperty({},"passive",{get:function(){el=!0}});window.addEventListener("test",Z,Z),window.removeEventListener("test",Z,Z)}catch{el=!1}const kT={useG:!0},Co={},Sb={},ym=new RegExp("^"+Vd+"(\\w+)(true|false)$"),Ib=Ji("propagationStopped");function Sm(Z,se){const ye=(se?se(Z):Z)+Wi,fe=(se?se(Z):Z)+Ts,be=Vd+ye,ke=Vd+fe;Co[Z]={},Co[Z][Wi]=be,Co[Z][Ts]=ke}function bb(Z,se,ye,fe){const be=fe&&fe.add||pm,ke=fe&&fe.rm||$r,at=fe&&fe.listeners||"eventListeners",tt=fe&&fe.rmAll||"removeAllListeners",At=Ji(be),Lt="."+be+":",ft="prependListener",Ei="."+ft+":",ii=function(Wt,ct,_n){if(Wt.isRemoved)return;const sr=Wt.callback;let Zr;"object"==typeof sr&&sr.handleEvent&&(Wt.callback=lt=>sr.handleEvent(lt),Wt.originalDelegate=sr);try{Wt.invoke(Wt,ct,[_n])}catch(lt){Zr=lt}const ki=Wt.options;return ki&&"object"==typeof ki&&ki.once&&ct[ke].call(ct,_n.type,Wt.originalDelegate?Wt.originalDelegate:Wt.callback,ki),Zr};function gi(Wt,ct,_n){if(!(ct=ct||Z.event))return;const sr=Wt||ct.target||Z,Zr=sr[Co[ct.type][_n?Ts:Wi]];if(Zr){const ki=[];if(1===Zr.length){const lt=ii(Zr[0],sr,ct);lt&&ki.push(lt)}else{const lt=Zr.slice();for(let dr=0;dr{throw dr})}}}const cr=function(Wt){return gi(this,Wt,!1)},Oi=function(Wt){return gi(this,Wt,!0)};function es(Wt,ct){if(!Wt)return!1;let _n=!0;ct&&void 0!==ct.useG&&(_n=ct.useG);const sr=ct&&ct.vh;let Zr=!0;ct&&void 0!==ct.chkDup&&(Zr=ct.chkDup);let ki=!1;ct&&void 0!==ct.rt&&(ki=ct.rt);let lt=Wt;for(;lt&&!lt.hasOwnProperty(be);)lt=Ud(lt);if(!lt&&Wt[be]&&(lt=Wt),!lt||lt[At])return!1;const dr=ct&&ct.eventNameToString,et={},vi=lt[At]=lt[be],Pt=lt[Ji(ke)]=lt[ke],ts=lt[Ji(at)]=lt[at],_o=lt[Ji(tt)]=lt[tt];let cn;ct&&ct.prepend&&(cn=lt[Ji(ct.prepend)]=lt[ct.prepend]);const F=_n?function(ge){if(!et.isExisting)return vi.call(et.target,et.eventName,et.capture?Oi:cr,et.options)}:function(ge){return vi.call(et.target,et.eventName,ge.invoke,et.options)},ae=_n?function(ge){if(!ge.isRemoved){const We=Co[ge.eventName];let wt;We&&(wt=We[ge.capture?Ts:Wi]);const Xe=wt&&ge.target[wt];if(Xe)for(let mt=0;mt{Vo.zone.cancelTask(Vo)},{once:!0})),et.target=null,Fc&&(Fc.taskData=null),qd&&(Dn.once=!0),!el&&"boolean"==typeof Vo.options||(Vo.options=Dn),Vo.target=$t,Vo.capture=Gl,Vo.eventName=li,ir&&(Vo.originalDelegate=ur),dt?jo.unshift(Vo):jo.push(Vo),mt?$t:void 0}};return lt[be]=He(vi,Lt,F,ae,ki),cn&&(lt[ft]=He(cn,Ei,function(ge){return cn.call(et.target,et.eventName,ge.invoke,et.options)},ae,ki,!0)),lt[ke]=function(){const ge=this||Z;let We=arguments[0];ct&&ct.transferEventName&&(We=ct.transferEventName(We));const wt=arguments[2],Xe=!!wt&&("boolean"==typeof wt||wt.capture),mt=arguments[1];if(!mt)return Pt.apply(this,arguments);if(sr&&!sr(Pt,mt,ge,arguments))return;const dt=Co[We];let $t;dt&&($t=dt[Xe?Ts:Wi]);const li=$t&&ge[$t];if(li)for(let ur=0;urfunction(be,ke){be[Ib]=!0,fe&&fe.apply(be,ke)})}function wb(Z,se,ye,fe,be){const ke=Zone.__symbol__(fe);if(se[ke])return;const at=se[ke]=se[fe];se[fe]=function(tt,At,Lt){return At&&At.prototype&&be.forEach(function(ft){const Ei=`${ye}.${fe}::`+ft,ii=At.prototype;try{if(ii.hasOwnProperty(ft)){const gi=Z.ObjectGetOwnPropertyDescriptor(ii,ft);gi&&gi.value?(gi.value=Z.wrapWithCurrentZone(gi.value,Ei),Z._redefineProperty(At.prototype,ft,gi)):ii[ft]&&(ii[ft]=Z.wrapWithCurrentZone(ii[ft],Ei))}else ii[ft]&&(ii[ft]=Z.wrapWithCurrentZone(ii[ft],Ei))}catch{}}),at.call(se,tt,At,Lt)},Z.attachOriginToPatched(se[fe],at)}function Cb(Z,se,ye){if(!ye||0===ye.length)return se;const fe=ye.filter(ke=>ke.target===Z);if(!fe||0===fe.length)return se;const be=fe[0].ignoreProperties;return se.filter(ke=>-1===be.indexOf(ke))}function Eo(Z,se,ye,fe){Z&&cf(Z,Cb(Z,se,ye),fe)}function Xd(Z){return Object.getOwnPropertyNames(Z).filter(se=>se.startsWith("on")&&se.length>2).map(se=>se.substring(2))}Zone.__load_patch("util",(Z,se,ye)=>{const fe=Xd(Z);ye.patchOnProperties=cf,ye.patchMethod=Ka,ye.bindArguments=Wd,ye.patchMacroTask=vb;const be=se.__symbol__("BLACK_LISTED_EVENTS"),ke=se.__symbol__("UNPATCHED_EVENTS");Z[ke]&&(Z[be]=Z[ke]),Z[be]&&(se[be]=se[ke]=Z[be]),ye.patchEventPrototype=Im,ye.patchEventTarget=bb,ye.isIEOrEdge=yb,ye.ObjectDefineProperty=_d,ye.ObjectGetOwnPropertyDescriptor=_l,ye.ObjectCreate=jd,ye.ArraySlice=gb,ye.patchClass=Qd,ye.wrapWithCurrentZone=of,ye.filterProperties=Cb,ye.attachOriginToPatched=Sa,ye._redefineProperty=Object.defineProperty,ye.patchCallbacks=wb,ye.getGlobalObjects=()=>({globalSources:Sb,zoneSymbolEventNames:Co,eventNames:fe,isBrowser:Yd,isMix:hf,isNode:jh,TRUE_STR:Ts,FALSE_STR:Wi,ZONE_SYMBOL_PREFIX:Vd,ADD_EVENT_LISTENER_STR:pm,REMOVE_EVENT_LISTENER_STR:$r})});const As=Ji("zoneTask");function Wl(Z,se,ye,fe){let be=null,ke=null;ye+=fe;const at={};function tt(Lt){const ft=Lt.data;return ft.args[0]=function(){return Lt.invoke.apply(this,arguments)},ft.handleId=be.apply(Z,ft.args),Lt}function At(Lt){return ke.call(Z,Lt.data.handleId)}be=Ka(Z,se+=fe,Lt=>function(ft,Ei){if("function"==typeof Ei[0]){const ii={isPeriodic:"Interval"===fe,delay:"Timeout"===fe||"Interval"===fe?Ei[1]||0:void 0,args:Ei},gi=Ei[0];Ei[0]=function(){try{return gi.apply(this,arguments)}finally{ii.isPeriodic||("number"==typeof ii.handleId?delete at[ii.handleId]:ii.handleId&&(ii.handleId[As]=null))}};const cr=fm(se,Ei[0],ii,tt,At);if(!cr)return cr;const Oi=cr.data.handleId;return"number"==typeof Oi?at[Oi]=cr:Oi&&(Oi[As]=cr),Oi&&Oi.ref&&Oi.unref&&"function"==typeof Oi.ref&&"function"==typeof Oi.unref&&(cr.ref=Oi.ref.bind(Oi),cr.unref=Oi.unref.bind(Oi)),"number"==typeof Oi||Oi?Oi:cr}return Lt.apply(Z,Ei)}),ke=Ka(Z,ye,Lt=>function(ft,Ei){const ii=Ei[0];let gi;"number"==typeof ii?gi=at[ii]:(gi=ii&&ii[As],gi||(gi=ii)),gi&&"string"==typeof gi.type?"notScheduled"!==gi.state&&(gi.cancelFn&&gi.data.isPeriodic||0===gi.runCount)&&("number"==typeof ii?delete at[ii]:ii&&(ii[As]=null),gi.zone.cancelTask(gi)):Lt.apply(Z,Ei)})}Zone.__load_patch("legacy",Z=>{const se=Z[Zone.__symbol__("legacyPatch")];se&&se()}),Zone.__load_patch("timers",Z=>{const ye="clear";Wl(Z,"set",ye,"Timeout"),Wl(Z,"set",ye,"Interval"),Wl(Z,"set",ye,"Immediate")}),Zone.__load_patch("requestAnimationFrame",Z=>{Wl(Z,"request","cancel","AnimationFrame"),Wl(Z,"mozRequest","mozCancel","AnimationFrame"),Wl(Z,"webkitRequest","webkitCancel","AnimationFrame")}),Zone.__load_patch("blocking",(Z,se)=>{const ye=["alert","prompt","confirm"];for(let fe=0;fefunction(At,Lt){return se.current.run(ke,Z,Lt,tt)})}),Zone.__load_patch("EventTarget",(Z,se,ye)=>{(function Yl(Z,se){se.patchEventPrototype(Z,se)})(Z,ye),function Mm(Z,se){if(Zone[se.symbol("patchEventTarget")])return;const{eventNames:ye,zoneSymbolEventNames:fe,TRUE_STR:be,FALSE_STR:ke,ZONE_SYMBOL_PREFIX:at}=se.getGlobalObjects();for(let At=0;At{Qd("MutationObserver"),Qd("WebKitMutationObserver")}),Zone.__load_patch("IntersectionObserver",(Z,se,ye)=>{Qd("IntersectionObserver")}),Zone.__load_patch("FileReader",(Z,se,ye)=>{Qd("FileReader")}),Zone.__load_patch("on_property",(Z,se,ye)=>{!function df(Z,se){if(jh&&!hf||Zone[Z.symbol("patchEvents")])return;const ye=se.__Zone_ignore_on_properties;let fe=[];if(Yd){const be=window;fe=fe.concat(["Document","SVGElement","Element","HTMLElement","HTMLBodyElement","HTMLMediaElement","HTMLFrameSetElement","HTMLFrameElement","HTMLIFrameElement","HTMLMarqueeElement","Worker"]);const ke=function mm(){try{const Z=Uh.navigator.userAgent;if(-1!==Z.indexOf("MSIE ")||-1!==Z.indexOf("Trident/"))return!0}catch{}return!1}()?[{target:be,ignoreProperties:["error"]}]:[];Eo(be,Xd(be),ye&&ye.concat(ke),Ud(be))}fe=fe.concat(["XMLHttpRequest","XMLHttpRequestEventTarget","IDBIndex","IDBRequest","IDBOpenDBRequest","IDBDatabase","IDBTransaction","IDBCursor","WebSocket"]);for(let be=0;be{!function bm(Z,se){const{isBrowser:ye,isMix:fe}=se.getGlobalObjects();(ye||fe)&&Z.customElements&&"customElements"in Z&&se.patchCallbacks(se,Z.customElements,"customElements","define",["connectedCallback","disconnectedCallback","adoptedCallback","attributeChangedCallback"])}(Z,ye)}),Zone.__load_patch("XHR",(Z,se)=>{!function At(Lt){const ft=Lt.XMLHttpRequest;if(!ft)return;const Ei=ft.prototype;let gi=Ei[Ul],cr=Ei[Fh];if(!gi){const et=Lt.XMLHttpRequestEventTarget;if(et){const vi=et.prototype;gi=vi[Ul],cr=vi[Fh]}}const Oi="readystatechange",es="scheduled";function kr(et){const vi=et.data,Pt=vi.target;Pt[ke]=!1,Pt[tt]=!1;const ts=Pt[be];gi||(gi=Pt[Ul],cr=Pt[Fh]),ts&&cr.call(Pt,Oi,ts);const _o=Pt[be]=()=>{if(Pt.readyState===Pt.DONE)if(!vi.aborted&&Pt[ke]&&et.state===es){const Ur=Pt[se.__symbol__("loadfalse")];if(0!==Pt.status&&Ur&&Ur.length>0){const Do=et.invoke;et.invoke=function(){const Ls=Pt[se.__symbol__("loadfalse")];for(let jr=0;jrfunction(et,vi){return et[fe]=0==vi[2],et[at]=vi[1],_n.apply(et,vi)}),Zr=Ji("fetchTaskAborting"),ki=Ji("fetchTaskScheduling"),lt=Ka(Ei,"send",()=>function(et,vi){if(!0===se.current[ki]||et[fe])return lt.apply(et,vi);{const Pt={target:et,url:et[at],isPeriodic:!1,args:vi,aborted:!1},ts=fm("XMLHttpRequest.send",Wt,Pt,kr,ct);et&&!0===et[tt]&&!Pt.aborted&&ts.state===es&&ts.invoke()}}),dr=Ka(Ei,"abort",()=>function(et,vi){const Pt=function ii(et){return et[ye]}(et);if(Pt&&"string"==typeof Pt.type){if(null==Pt.cancelFn||Pt.data&&Pt.data.aborted)return;Pt.zone.cancelTask(Pt)}else if(!0===se.current[Zr])return dr.apply(et,vi)})}(Z);const ye=Ji("xhrTask"),fe=Ji("xhrSync"),be=Ji("xhrListener"),ke=Ji("xhrScheduled"),at=Ji("xhrURL"),tt=Ji("xhrErrorBeforeScheduled")}),Zone.__load_patch("geolocation",Z=>{Z.navigator&&Z.navigator.geolocation&&function vm(Z,se){const ye=Z.constructor.name;for(let fe=0;fe{const At=function(){return tt.apply(this,Wd(arguments,ye+"."+be))};return Sa(At,tt),At})(ke)}}}(Z.navigator.geolocation,["getCurrentPosition","watchPosition"])}),Zone.__load_patch("PromiseRejectionEvent",(Z,se)=>{function ye(fe){return function(be){Mb(Z,fe).forEach(at=>{const tt=Z.PromiseRejectionEvent;if(tt){const At=new tt(fe,{promise:be.promise,reason:be.rejection});at.invoke(At)}})}}Z.PromiseRejectionEvent&&(se[Ji("unhandledPromiseRejectionHandler")]=ye("unhandledrejection"),se[Ji("rejectionHandledHandler")]=ye("rejectionhandled"))}),Zone.__load_patch("queueMicrotask",(Z,se,ye)=>{!function uf(Z,se){se.patchMethod(Z,"queueMicrotask",ye=>function(fe,be){Zone.current.scheduleMicroTask("queueMicrotask",be[0])})}(Z,ye)})}},_l=>{_l(_l.s=51)}]); \ No newline at end of file diff --git a/ej2-angular/samples/diagram/ports/add-cs1/main.a8714d93274f2509.js b/ej2-angular/samples/diagram/ports/add-cs1/main.a8714d93274f2509.js new file mode 100644 index 0000000000..6d63534137 --- /dev/null +++ b/ej2-angular/samples/diagram/ports/add-cs1/main.a8714d93274f2509.js @@ -0,0 +1 @@ +"use strict";(self.webpackChunksyncfusion_component=self.webpackChunksyncfusion_component||[]).push([[179],{51:(Wl,Ud,jd)=>{let $r=null,_h=1;const Ts=Symbol("SIGNAL");function Wi(n){const t=$r;return $r=n,t}function gn(n){if((!Wh(n)||n.dirty)&&(n.dirty||n.lastCleanEpoch!==_h)){if(!n.producerMustRecompute(n)&&!Vh(n))return n.dirty=!1,void(n.lastCleanEpoch=_h);n.producerRecomputeValue(n),n.dirty=!1,n.lastCleanEpoch=_h}}function Vh(n){Gl(n);for(let t=0;t0}function Gl(n){n.producerNode??=[],n.producerIndexOfThis??=[],n.producerLastReadVersion??=[]}let Xd=null;function Eo(n){return"function"==typeof n}function qd(n){const e=n(i=>{Error.call(i),i.stack=(new Error).stack});return e.prototype=Object.create(Error.prototype),e.prototype.constructor=e,e}const dp=qd(n=>function(e){n(this),this.message=e?`${e.length} errors occurred during unsubscription:\n${e.map((i,r)=>`${r+1}) ${i.toString()}`).join("\n ")}`:"",this.name="UnsubscriptionError",this.errors=e});function up(n,t){if(n){const e=n.indexOf(t);0<=e&&n.splice(e,1)}}class As{constructor(t){this.initialTeardown=t,this.closed=!1,this._parentage=null,this._finalizers=null}unsubscribe(){let t;if(!this.closed){this.closed=!0;const{_parentage:e}=this;if(e)if(this._parentage=null,Array.isArray(e))for(const s of e)s.remove(this);else e.remove(this);const{initialTeardown:i}=this;if(Eo(i))try{i()}catch(s){t=s instanceof dp?s.errors:[s]}const{_finalizers:r}=this;if(r){this._finalizers=null;for(const s of r)try{wm(s)}catch(o){t=t??[],o instanceof dp?t=[...t,...o.errors]:t.push(o)}}if(t)throw new dp(t)}}add(t){var e;if(t&&t!==this)if(this.closed)wm(t);else{if(t instanceof As){if(t.closed||t._hasParent(this))return;t._addParent(this)}(this._finalizers=null!==(e=this._finalizers)&&void 0!==e?e:[]).push(t)}}_hasParent(t){const{_parentage:e}=this;return e===t||Array.isArray(e)&&e.includes(t)}_addParent(t){const{_parentage:e}=this;this._parentage=Array.isArray(e)?(e.push(t),e):e?[e,t]:t}_removeParent(t){const{_parentage:e}=this;e===t?this._parentage=null:Array.isArray(e)&&up(e,t)}remove(t){const{_finalizers:e}=this;e&&up(e,t),t instanceof As&&t._removeParent(this)}}As.EMPTY=(()=>{const n=new As;return n.closed=!0,n})();const Xl=As.EMPTY;function Mm(n){return n instanceof As||n&&"closed"in n&&Eo(n.remove)&&Eo(n.add)&&Eo(n.unsubscribe)}function wm(n){Eo(n)?n():n.unsubscribe()}const ql={onUnhandledError:null,onStoppedNotification:null,Promise:void 0,useDeprecatedSynchronousErrorHandling:!1,useDeprecatedNextContext:!1},Z={setTimeout(n,t,...e){const{delegate:i}=Z;return i?.setTimeout?i.setTimeout(n,t,...e):setTimeout(n,t,...e)},clearTimeout(n){const{delegate:t}=Z;return(t?.clearTimeout||clearTimeout)(n)},delegate:void 0};function ye(){}const pe=at("C",void 0,void 0);function at(n,t,e){return{kind:n,value:t,error:e}}let tt=null;function At(n){if(ql.useDeprecatedSynchronousErrorHandling){const t=!tt;if(t&&(tt={errorThrown:!1,error:null}),n(),t){const{errorThrown:e,error:i}=tt;if(tt=null,e)throw i}}else n()}class pt extends As{constructor(t){super(),this.isStopped=!1,t?(this.destination=t,Mm(t)&&t.add(this)):this.destination=Wt}static create(t,e,i){return new cr(t,e,i)}next(t){this.isStopped?Pr(function ke(n){return at("N",n,void 0)}(t),this):this._next(t)}error(t){this.isStopped?Pr(function be(n){return at("E",void 0,n)}(t),this):(this.isStopped=!0,this._error(t))}complete(){this.isStopped?Pr(pe,this):(this.isStopped=!0,this._complete())}unsubscribe(){this.closed||(this.isStopped=!0,super.unsubscribe(),this.destination=null)}_next(t){this.destination.next(t)}_error(t){try{this.destination.error(t)}finally{this.unsubscribe()}}_complete(){try{this.destination.complete()}finally{this.unsubscribe()}}}const Di=Function.prototype.bind;function si(n,t){return Di.call(n,t)}class mi{constructor(t){this.partialObserver=t}next(t){const{partialObserver:e}=this;if(e.next)try{e.next(t)}catch(i){ki(i)}}error(t){const{partialObserver:e}=this;if(e.error)try{e.error(t)}catch(i){ki(i)}else ki(t)}complete(){const{partialObserver:t}=this;if(t.complete)try{t.complete()}catch(e){ki(e)}}}class cr extends pt{constructor(t,e,i){let r;if(super(),Eo(t)||!t)r={next:t??void 0,error:e??void 0,complete:i??void 0};else{let s;this&&ql.useDeprecatedNextContext?(s=Object.create(t),s.unsubscribe=()=>this.unsubscribe(),r={next:t.next&&si(t.next,s),error:t.error&&si(t.error,s),complete:t.complete&&si(t.complete,s)}):r=t}this.destination=new mi(r)}}function ki(n){ql.useDeprecatedSynchronousErrorHandling?function Lt(n){ql.useDeprecatedSynchronousErrorHandling&&tt&&(tt.errorThrown=!0,tt.error=n)}(n):function se(n){Z.setTimeout(()=>{const{onUnhandledError:t}=ql;if(!t)throw n;t(n)})}(n)}function Pr(n,t){const{onStoppedNotification:e}=ql;e&&Z.setTimeout(()=>e(n,t))}const Wt={closed:!0,next:ye,error:function is(n){throw n},complete:ye},ct="function"==typeof Symbol&&Symbol.observable||"@@observable";function jn(n){return n}let Pi=(()=>{class n{constructor(e){e&&(this._subscribe=e)}lift(e){const i=new n;return i.source=this,i.operator=e,i}subscribe(e,i,r){const s=function et(n){return n&&n instanceof pt||function dr(n){return n&&Eo(n.next)&&Eo(n.error)&&Eo(n.complete)}(n)&&Mm(n)}(e)?e:new cr(e,i,r);return At(()=>{const{operator:o,source:a}=this;s.add(o?o.call(s,a):a?this._subscribe(s):this._trySubscribe(s))}),s}_trySubscribe(e){try{return this._subscribe(e)}catch(i){e.error(i)}}forEach(e,i){return new(i=lt(i))((r,s)=>{const o=new cr({next:a=>{try{e(a)}catch(l){s(l),o.unsubscribe()}},error:s,complete:r});this.subscribe(o)})}_subscribe(e){var i;return null===(i=this.source)||void 0===i?void 0:i.subscribe(e)}[ct](){return this}pipe(...e){return function Zr(n){return 0===n.length?jn:1===n.length?n[0]:function(e){return n.reduce((i,r)=>r(i),e)}}(e)(this)}toPromise(e){return new(e=lt(e))((i,r)=>{let s;this.subscribe(o=>s=o,o=>r(o),()=>i(s))})}}return n.create=t=>new n(t),n})();function lt(n){var t;return null!==(t=n??ql.Promise)&&void 0!==t?t:Promise}const yi=qd(n=>function(){n(this),this.name="ObjectUnsubscribedError",this.message="object unsubscribed"});let Pt=(()=>{class n extends Pi{constructor(){super(),this.closed=!1,this.currentObservers=null,this.observers=[],this.isStopped=!1,this.hasError=!1,this.thrownError=null}lift(e){const i=new rs(this,this);return i.operator=e,i}_throwIfClosed(){if(this.closed)throw new yi}next(e){At(()=>{if(this._throwIfClosed(),!this.isStopped){this.currentObservers||(this.currentObservers=Array.from(this.observers));for(const i of this.currentObservers)i.next(e)}})}error(e){At(()=>{if(this._throwIfClosed(),!this.isStopped){this.hasError=this.isStopped=!0,this.thrownError=e;const{observers:i}=this;for(;i.length;)i.shift().error(e)}})}complete(){At(()=>{if(this._throwIfClosed(),!this.isStopped){this.isStopped=!0;const{observers:e}=this;for(;e.length;)e.shift().complete()}})}unsubscribe(){this.isStopped=this.closed=!0,this.observers=this.currentObservers=null}get observed(){var e;return(null===(e=this.observers)||void 0===e?void 0:e.length)>0}_trySubscribe(e){return this._throwIfClosed(),super._trySubscribe(e)}_subscribe(e){return this._throwIfClosed(),this._checkFinalizedStatuses(e),this._innerSubscribe(e)}_innerSubscribe(e){const{hasError:i,isStopped:r,observers:s}=this;return i||r?Xl:(this.currentObservers=null,s.push(e),new As(()=>{this.currentObservers=null,up(s,e)}))}_checkFinalizedStatuses(e){const{hasError:i,thrownError:r,isStopped:s}=this;i?e.error(r):s&&e.complete()}asObservable(){const e=new Pi;return e.source=this,e}}return n.create=(t,e)=>new rs(t,e),n})();class rs extends Pt{constructor(t,e){super(),this.destination=t,this.source=e}next(t){var e,i;null===(i=null===(e=this.destination)||void 0===e?void 0:e.next)||void 0===i||i.call(e,t)}error(t){var e,i;null===(i=null===(e=this.destination)||void 0===e?void 0:e.error)||void 0===i||i.call(e,t)}complete(){var t,e;null===(e=null===(t=this.destination)||void 0===t?void 0:t.complete)||void 0===e||e.call(t)}_subscribe(t){var e,i;return null!==(i=null===(e=this.source)||void 0===e?void 0:e.subscribe(t))&&void 0!==i?i:Xl}}class _o extends Pt{constructor(t){super(),this._value=t}get value(){return this.getValue()}_subscribe(t){const e=super._subscribe(t);return!e.closed&&t.next(this._value),e}getValue(){const{hasError:t,thrownError:e,_value:i}=this;if(t)throw e;return this._throwIfClosed(),i}next(t){super.next(this._value=t)}}class Ls extends pt{constructor(t,e,i,r,s,o){super(t),this.onFinalize=s,this.shouldUnsubscribe=o,this._next=e?function(a){try{e(a)}catch(l){t.error(l)}}:super._next,this._error=r?function(a){try{r(a)}catch(l){t.error(l)}finally{this.unsubscribe()}}:super._error,this._complete=i?function(){try{i()}catch(a){t.error(a)}finally{this.unsubscribe()}}:super._complete}unsubscribe(){var t;if(!this.shouldUnsubscribe||this.shouldUnsubscribe()){const{closed:e}=this;super.unsubscribe(),!e&&(null===(t=this.onFinalize)||void 0===t||t.call(this))}}}function jr(n,t){return function Ur(n){return t=>{if(function cn(n){return Eo(n?.lift)}(t))return t.lift(function(e){try{return n(e,this)}catch(i){this.error(i)}});throw new TypeError("Unable to lift unknown Observable type")}}((e,i)=>{let r=0;e.subscribe(function Do(n,t,e,i,r){return new Ls(n,t,e,i,r)}(i,s=>{i.next(n.call(t,s,r++))}))})}class F extends Error{constructor(t,e){super(function ae(n,t){return`NG0${Math.abs(n)}${t?": "+t:""}`}(t,e)),this.code=t}}function Xe(n){for(let t in n)if(n[t]===Xe)return t;throw Error("Could not find renamed property on target object.")}function mt(n,t){for(const e in t)t.hasOwnProperty(e)&&!n.hasOwnProperty(e)&&(n[e]=t[e])}function dt(n){if("string"==typeof n)return n;if(Array.isArray(n))return"["+n.map(dt).join(", ")+"]";if(null==n)return""+n;if(n.overriddenName)return`${n.overriddenName}`;if(n.name)return`${n.name}`;const t=n.toString();if(null==t)return""+t;const e=t.indexOf("\n");return-1===e?t:t.substring(0,e)}function $t(n,t){return null==n||""===n?null===t?"":t:null==t||""===t?n:n+" "+t}const ur=Xe({__forward_ref__:Xe});function ir(n){return n.__forward_ref__=ir,n.toString=function(){return dt(this())},n}function vt(n){return function Tn(n){return"function"==typeof n&&n.hasOwnProperty(ur)&&n.__forward_ref__===ir}(n)?n():n}function $l(n){return n&&!!n.\u0275providers}const Zl=Xe({\u0275cmp:Xe}),$d=Xe({\u0275dir:Xe}),fp=Xe({\u0275pipe:Xe}),Uo=Xe({\u0275fac:Xe}),jo=Xe({__NG_ELEMENT_ID__:Xe}),pp=Xe({__NG_ENV_ID__:Xe});function Ri(n){return"function"==typeof n?n.name||n.toString():"object"==typeof n&&null!=n&&"function"==typeof n.type?n.type.name||n.type.toString():function Nt(n){return"string"==typeof n?n:null==n?"":String(n)}(n)}function xb(n,t){throw new F(-201,!1)}function so(n,t){null==n&&function zt(n,t,e,i){throw new Error(`ASSERTION ERROR: ${n}`+(null==i?"":` [Expected=> ${e} ${i} ${t} <=Actual]`))}(t,n,null,"!=")}function Yi(n){return{token:n.token,providedIn:n.providedIn||null,factory:n.factory,value:void 0}}function gp(n){return{providers:n.providers||[],imports:n.imports||[]}}function Cm(n){return PT(n,Dm)||PT(n,zT)}function PT(n,t){return n.hasOwnProperty(t)?n[t]:null}function Em(n){return n&&(n.hasOwnProperty(Tb)||n.hasOwnProperty(E_))?n[Tb]:null}const Dm=Xe({\u0275prov:Xe}),Tb=Xe({\u0275inj:Xe}),zT=Xe({ngInjectableDef:Xe}),E_=Xe({ngInjectorDef:Xe});var xi=function(n){return n[n.Default=0]="Default",n[n.Host=1]="Host",n[n.Self=2]="Self",n[n.SkipSelf=4]="SkipSelf",n[n.Optional=8]="Optional",n}(xi||{});let Ab;function oo(n){const t=Ab;return Ab=n,t}function HT(n,t,e){const i=Cm(n);return i&&"root"==i.providedIn?void 0===i.value?i.value=i.factory():i.value:e&xi.Optional?null:void 0!==t?t:void xb()}const rr=globalThis;class Ht{constructor(t,e){this._desc=t,this.ngMetadataName="InjectionToken",this.\u0275prov=void 0,"number"==typeof e?this.__NG_ELEMENT_ID__=e:void 0!==e&&(this.\u0275prov=Yi({token:this,providedIn:e.providedIn||"root",factory:e.factory}))}get multi(){return this}toString(){return`InjectionToken ${this._desc}`}}const vp={},Pb="__NG_DI_FLAG__",xm="ngTempTokenPath",T_=/\n/gm,FT="__source";let Jd;function Gh(n){const t=Jd;return Jd=n,t}function N_(n,t=xi.Default){if(void 0===Jd)throw new F(-203,!1);return null===Jd?HT(n,void 0,t):Jd.get(n,t&xi.Optional?null:void 0,t)}function _i(n,t=xi.Default){return(function RT(){return Ab}()||N_)(vt(n),t)}function Hi(n,t=xi.Default){return _i(n,Tm(t))}function Tm(n){return typeof n>"u"||"number"==typeof n?n:0|(n.optional&&8)|(n.host&&1)|(n.self&&2)|(n.skipSelf&&4)}function zb(n){const t=[];for(let e=0;et){o=s-1;break}}}for(;ss?"":r[d+1].toLowerCase();const f=8&i?u:null;if(f&&-1!==UT(f,h,0)||2&i&&h!==u){if(Ma(i))return!1;o=!0}}}}else{if(!o&&!Ma(i)&&!Ma(l))return!1;if(o&&Ma(l))continue;o=!1,i=l|1&i}}return Ma(i)||o}function Ma(n){return 0==(1&n)}function B_(n,t,e,i){if(null===t)return-1;let r=0;if(i||!e){let s=!1;for(;r-1)for(e++;e0?'="'+a+'"':"")+"]"}else 8&i?r+="."+o:4&i&&(r+=" "+o);else""!==r&&!Ma(o)&&(t+=XT(s,r),r=""),i=o,s=s||!Ma(i);e++}return""!==r&&(t+=XT(s,r)),t}function Hb(n){return Jl(()=>{const t=$T(n),e={...t,decls:n.decls,vars:n.vars,template:n.template,consts:n.consts||null,ngContentSelectors:n.ngContentSelectors,onPush:n.changeDetection===Am.OnPush,directiveDefs:null,pipeDefs:null,dependencies:t.standalone&&n.dependencies||null,getStandaloneInjector:null,signals:n.signals??!1,data:n.data||{},encapsulation:n.encapsulation||ba.Emulated,styles:n.styles||Qi,_:null,schemas:n.schemas||null,tView:null,id:""};ZT(e);const i=n.dependencies;return e.directiveDefs=Nm(i,!1),e.pipeDefs=Nm(i,!0),e.id=function q_(n){let t=0;const e=[n.selectors,n.ngContentSelectors,n.hostVars,n.hostAttrs,n.consts,n.vars,n.decls,n.encapsulation,n.standalone,n.signals,n.exportAs,JSON.stringify(n.inputs),JSON.stringify(n.outputs),Object.getOwnPropertyNames(n.type.prototype),!!n.contentQueries,!!n.viewQuery].join("|");for(const r of e)t=Math.imul(31,t)+r.charCodeAt(0)<<0;return t+=2147483648,"c"+t}(e),e})}function Q_(n){return di(n)||Wn(n)}function G_(n){return null!==n}function Lm(n){return Jl(()=>({type:n.type,bootstrap:n.bootstrap||Qi,declarations:n.declarations||Qi,imports:n.imports||Qi,exports:n.exports||Qi,transitiveCompileScopes:null,schemas:n.schemas||null,id:n.id||null}))}function qT(n,t){if(null==n)return rl;const e={};for(const i in n)if(n.hasOwnProperty(i)){const r=n[i];let s,o,a=Xh.None;Array.isArray(r)?(a=r[0],s=r[1],o=r[2]??s):(s=r,o=r),t?(e[s]=a!==Xh.None?[i,a]:i,t[s]=o):e[s]=i}return e}function nr(n){return Jl(()=>{const t=$T(n);return ZT(t),t})}function di(n){return n[Zl]||null}function Wn(n){return n[$d]||null}function gs(n){return n[fp]||null}function $T(n){const t={};return{type:n.type,providersResolver:null,factory:null,hostBindings:n.hostBindings||null,hostVars:n.hostVars||0,hostAttrs:n.hostAttrs||null,contentQueries:n.contentQueries||null,declaredInputs:t,inputTransforms:null,inputConfig:n.inputs||rl,exportAs:n.exportAs||null,standalone:!0===n.standalone,signals:!0===n.signals,selectors:n.selectors||Qi,viewQuery:n.viewQuery||null,features:n.features||null,setInput:null,findHostDirectiveDefs:null,hostDirectives:null,inputs:qT(n.inputs,t),outputs:qT(n.outputs),debugInfo:null}}function ZT(n){n.features?.forEach(t=>t(n))}function Nm(n,t){if(!n)return null;const e=t?gs:Q_;return()=>("function"==typeof n?n():n).map(i=>e(i)).filter(G_)}const Vr=0,Be=1,Ct=2,vn=3,wa=4,Os=5,Ca=6,Kd=7,Er=8,Xs=9,Kl=10,Yt=11,Sp=12,JT=13,eu=14,Jr=15,Ip=16,tu=17,nl=18,bp=19,KT=20,qh=21,Om=22,Uc=23,jt=25,Bb=1,sl=7,iu=9,mn=10;var Fb=function(n){return n[n.None=0]="None",n[n.HasTransplantedViews=2]="HasTransplantedViews",n}(Fb||{});function ks(n){return Array.isArray(n)&&"object"==typeof n[Bb]}function Ps(n){return Array.isArray(n)&&!0===n[Bb]}function _b(n){return 0!=(4&n.flags)}function jc(n){return n.componentOffset>-1}function Pm(n){return 1==(1&n.flags)}function Ea(n){return!!n.template}function Ub(n){return 0!=(512&n[Ct])}function Vc(n,t){return n.hasOwnProperty(Uo)?n[Uo]:null}class K_{constructor(t,e,i){this.previousValue=t,this.currentValue=e,this.firstChange=i}isFirstChange(){return this.firstChange}}function rA(n,t,e,i){null!==t?t.applyValueToInputSignal(t,i):n[e]=i}function nA(n){return n.type.prototype.ngOnChanges&&(n.setInput=tU),eU}function eU(){const n=oA(this),t=n?.current;if(t){const e=n.previous;if(e===rl)n.previous=t;else for(let i in t)e[i]=t[i];n.current=null,this.ngOnChanges(t)}}function tU(n,t,e,i,r){const s=this.declaredInputs[i],o=oA(n)||function iU(n,t){return n[sA]=t}(n,{previous:rl,current:null}),a=o.current||(o.current={}),l=o.previous,h=l[s];a[s]=new K_(h&&h.currentValue,e,l===rl),rA(n,t,r,e)}const sA="__ngSimpleChanges__";function oA(n){return n[sA]||null}const ol=function(n,t,e){};let hA=!1;function fr(n){for(;Array.isArray(n);)n=n[Vr];return n}function qs(n,t){return fr(t[n.index])}function Cp(n,t){return n.data[t]}function To(n,t){const e=t[n];return ks(e)?e:e[Vr]}function Qb(n){return 128==(128&n[Ct])}function al(n,t){return null==t?null:n[t]}function cA(n){n[tu]=0}function lU(n){1024&n[Ct]||(n[Ct]|=1024,Qb(n)&&Ep(n))}function uA(n){return 9216&n[Ct]||n[Uc]?.dirty}function Gb(n){uA(n)?Ep(n):64&n[Ct]&&(function nU(){return hA}()?(n[Ct]|=1024,Ep(n)):n[Kl].changeDetectionScheduler?.notify())}function Ep(n){n[Kl].changeDetectionScheduler?.notify();let t=Wc(n);for(;null!==t&&!(8192&t[Ct])&&(t[Ct]|=8192,Qb(t));)t=Wc(t)}function Wc(n){const t=n[vn];return Ps(t)?t[vn]:t}const Rt={lFrame:MA(null),bindingsEnabled:!0,skipHydrationRootTNode:null};function pA(){return Rt.bindingsEnabled}function Se(){return Rt.lFrame.lView}function Ti(){return Rt.lFrame.tView}function pr(){let n=gA();for(;null!==n&&64===n.type;)n=n.parent;return n}function gA(){return Rt.lFrame.currentTNode}function ll(n,t){const e=Rt.lFrame;e.currentTNode=n,e.isParent=t}function qb(){return Rt.lFrame.isParent}function bU(n,t){const e=Rt.lFrame;e.bindingIndex=e.bindingRootIndex=n,Zb(t)}function Zb(n){Rt.lFrame.currentDirectiveIndex=n}function SA(){return Rt.lFrame.currentQueryIndex}function Kb(n){Rt.lFrame.currentQueryIndex=n}function wU(n){const t=n[Be];return 2===t.type?t.declTNode:1===t.type?n[Os]:null}function IA(n,t,e){if(e&xi.SkipSelf){let r=t,s=n;for(;!(r=r.parent,null!==r||e&xi.Host||(r=wU(s),null===r||(s=s[eu],10&r.type))););if(null===r)return!1;t=r,n=s}const i=Rt.lFrame=bA();return i.currentTNode=t,i.lView=n,!0}function e1(n){const t=bA(),e=n[Be];Rt.lFrame=t,t.currentTNode=e.firstChild,t.lView=n,t.tView=e,t.contextLView=n,t.bindingIndex=e.bindingStartIndex,t.inI18n=!1}function bA(){const n=Rt.lFrame,t=null===n?null:n.child;return null===t?MA(n):t}function MA(n){const t={currentTNode:null,isParent:!0,lView:null,tView:null,selectedIndex:-1,contextLView:null,elementDepthCount:0,currentNamespace:null,currentDirectiveIndex:-1,bindingRootIndex:-1,bindingIndex:-1,currentQueryIndex:0,parent:n,child:null,inI18n:!1};return null!==n&&(n.child=t),t}function wA(){const n=Rt.lFrame;return Rt.lFrame=n.parent,n.currentTNode=null,n.lView=null,n}const CA=wA;function t1(){const n=wA();n.isParent=!0,n.tView=null,n.selectedIndex=-1,n.contextLView=null,n.elementDepthCount=0,n.currentDirectiveIndex=-1,n.currentNamespace=null,n.bindingRootIndex=-1,n.bindingIndex=-1,n.currentQueryIndex=0}function zs(){return Rt.lFrame.selectedIndex}function Yc(n){Rt.lFrame.selectedIndex=n}let DA=!0;function Hm(){return DA}function $h(n){DA=n}function Bm(n,t){for(let e=t.directiveStart,i=t.directiveEnd;e=i)break}else t[l]<0&&(n[tu]+=65536),(a>14>16&&(3&n[Ct])===t&&(n[Ct]+=16384,TA(a,s)):TA(a,s)}const su=-1;class xp{constructor(t,e,i){this.factory=t,this.resolving=!1,this.canSeeViewProviders=e,this.injectImpl=i}}function n1(n){return n!==su}function Tp(n){return 32767&n}function Ap(n,t){let e=function zU(n){return n>>16}(n),i=t;for(;e>0;)i=i[eu],e--;return i}let s1=!0;function Um(n){const t=s1;return s1=n,t}const AA=255,LA=5;let RU=0;const cl={};function jm(n,t){const e=NA(n,t);if(-1!==e)return e;const i=t[Be];i.firstCreatePass&&(n.injectorIndex=t.length,o1(i.data,n),o1(t,null),o1(i.blueprint,null));const r=Vm(n,t),s=n.injectorIndex;if(n1(r)){const o=Tp(r),a=Ap(r,t),l=a[Be].data;for(let h=0;h<8;h++)t[s+h]=a[o+h]|l[o+h]}return t[s+8]=r,s}function o1(n,t){n.push(0,0,0,0,0,0,0,0,t)}function NA(n,t){return-1===n.injectorIndex||n.parent&&n.parent.injectorIndex===n.injectorIndex||null===t[n.injectorIndex+8]?-1:n.injectorIndex}function Vm(n,t){if(n.parent&&-1!==n.parent.injectorIndex)return n.parent.injectorIndex;let e=0,i=null,r=t;for(;null!==r;){if(i=BA(r),null===i)return su;if(e++,r=r[eu],-1!==i.injectorIndex)return i.injectorIndex|e<<16}return su}function a1(n,t,e){!function HU(n,t,e){let i;"string"==typeof e?i=e.charCodeAt(0)||0:e.hasOwnProperty(jo)&&(i=e[jo]),null==i&&(i=e[jo]=RU++);const r=i&AA;t.data[n+(r>>LA)]|=1<=0?t&AA:UU:t}(e);if("function"==typeof s){if(!IA(t,n,i))return i&xi.Host?OA(r,0,i):kA(t,e,i,r);try{let o;if(o=s(i),null!=o||i&xi.Optional)return o;xb()}finally{CA()}}else if("number"==typeof s){let o=null,a=NA(n,t),l=su,h=i&xi.Host?t[Jr][Os]:null;for((-1===a||i&xi.SkipSelf)&&(l=-1===a?Vm(n,t):t[a+8],l!==su&&HA(i,!1)?(o=t[Be],a=Tp(l),t=Ap(l,t)):a=-1);-1!==a;){const c=t[Be];if(RA(s,a,c.data)){const d=FU(a,t,e,o,i,h);if(d!==cl)return d}l=t[a+8],l!==su&&HA(i,t[Be].data[a+8]===h)&&RA(s,a,t)?(o=c,a=Tp(l),t=Ap(l,t)):a=-1}}return r}function FU(n,t,e,i,r,s){const o=t[Be],a=o.data[n+8],c=Wm(a,o,e,null==i?jc(a)&&s1:i!=o&&0!=(3&a.type),r&xi.Host&&s===a);return null!==c?Qc(t,o,c,a):cl}function Wm(n,t,e,i,r){const s=n.providerIndexes,o=t.data,a=1048575&s,l=n.directiveStart,c=s>>20,u=r?a+c:n.directiveEnd;for(let f=i?a:a+c;f=l&&p.type===e)return f}if(r){const f=o[l];if(f&&Ea(f)&&f.type===e)return l}return null}function Qc(n,t,e,i){let r=n[e];const s=t.data;if(function NU(n){return n instanceof xp}(r)){const o=r;o.resolving&&function Vo(n,t){const e=t?`. Dependency path: ${t.join(" > ")} > ${n}`:"";throw new F(-200,`Circular dependency in DI detected for ${n}${e}`)}(Ri(s[e]));const a=Um(o.canSeeViewProviders);o.resolving=!0;const h=o.injectImpl?oo(o.injectImpl):null;IA(n,i,xi.Default);try{r=n[e]=o.factory(void 0,s,n,i),t.firstCreatePass&&e>=i.directiveStart&&function AU(n,t,e){const{ngOnChanges:i,ngOnInit:r,ngDoCheck:s}=t.type.prototype;if(i){const o=nA(t);(e.preOrderHooks??=[]).push(n,o),(e.preOrderCheckHooks??=[]).push(n,o)}r&&(e.preOrderHooks??=[]).push(0-n,r),s&&((e.preOrderHooks??=[]).push(n,s),(e.preOrderCheckHooks??=[]).push(n,s))}(e,s[e],t)}finally{null!==h&&oo(h),Um(a),o.resolving=!1,CA()}}return r}function RA(n,t,e){return!!(e[t+(n>>LA)]&1<Array.isArray(e)?fu(e,t):t(e))}function _A(n,t,e){t>=n.length?n.push(e):n.splice(t,0,e)}function Ym(n,t){return t>=n.length-1?n.pop():n.splice(t,1)[0]}const vu=new Ht(""),QA=new Ht("",-1),m1=new Ht("");class qm{get(t,e=vp){if(e===vp){const i=new Error(`NullInjectorError: No provider for ${dt(t)}!`);throw i.name="NullInjectorError",i}return e}}function dj(...n){return{\u0275providers:GA(0,n),\u0275fromNgModule:!0}}function GA(n,...t){const e=[],i=new Set;let r;const s=o=>{e.push(o)};return fu(t,o=>{const a=o;$m(a,s,[],i)&&(r||=[],r.push(a))}),void 0!==r&&XA(r,s),e}function XA(n,t){for(let e=0;e{t(s,i)})}}function $m(n,t,e,i){if(!(n=vt(n)))return!1;let r=null,s=Em(n);const o=!s&&di(n);if(s||o){if(o&&!o.standalone)return!1;r=n}else{const l=n.ngModule;if(s=Em(l),!s)return!1;r=l}const a=i.has(r);if(o){if(a)return!1;if(i.add(r),o.dependencies){const l="function"==typeof o.dependencies?o.dependencies():o.dependencies;for(const h of l)$m(h,t,e,i)}}else{if(!s)return!1;{if(null!=s.imports&&!a){let h;i.add(r);try{fu(s.imports,c=>{$m(c,t,e,i)&&(h||=[],h.push(c))})}finally{}void 0!==h&&XA(h,t)}if(!a){const h=Vc(r)||(()=>new r);t({provide:r,useFactory:h,deps:Qi},r),t({provide:m1,useValue:r,multi:!0},r),t({provide:vu,useValue:()=>_i(r),multi:!0},r)}const l=s.providers;if(null!=l&&!a){const h=n;S1(l,c=>{t(c,h)})}}}return r!==n&&void 0!==n.providers}function S1(n,t){for(let e of n)$l(e)&&(e=e.\u0275providers),Array.isArray(e)?S1(e,t):t(e)}const uj=Xe({provide:String,useValue:Xe});function I1(n){return null!==n&&"object"==typeof n&&uj in n}function Gc(n){return"function"==typeof n}const b1=new Ht(""),Zm={},pj={};let M1;function Jm(){return void 0===M1&&(M1=new qm),M1}class ih{}class mu extends ih{get destroyed(){return this._destroyed}constructor(t,e,i,r){super(),this.parent=e,this.source=i,this.scopes=r,this.records=new Map,this._ngOnDestroyHooks=new Set,this._onDestroyHooks=[],this._destroyed=!1,C1(t,o=>this.processProvider(o)),this.records.set(QA,yu(void 0,this)),r.has("environment")&&this.records.set(ih,yu(void 0,this));const s=this.records.get(b1);null!=s&&"string"==typeof s.value&&this.scopes.add(s.value),this.injectorDefTypes=new Set(this.get(m1,Qi,xi.Self))}destroy(){this.assertNotDestroyed(),this._destroyed=!0;try{for(const e of this._ngOnDestroyHooks)e.ngOnDestroy();const t=this._onDestroyHooks;this._onDestroyHooks=[];for(const e of t)e()}finally{this.records.clear(),this._ngOnDestroyHooks.clear(),this.injectorDefTypes.clear()}}onDestroy(t){return this.assertNotDestroyed(),this._onDestroyHooks.push(t),()=>this.removeOnDestroy(t)}runInContext(t){this.assertNotDestroyed();const e=Gh(this),i=oo(void 0);try{return t()}finally{Gh(e),oo(i)}}get(t,e=vp,i=xi.Default){if(this.assertNotDestroyed(),t.hasOwnProperty(pp))return t[pp](this);i=Tm(i);const s=Gh(this),o=oo(void 0);try{if(!(i&xi.SkipSelf)){let l=this.records.get(t);if(void 0===l){const h=function Sj(n){return"function"==typeof n||"object"==typeof n&&n instanceof Ht}(t)&&Cm(t);l=h&&this.injectableDefInScope(h)?yu(w1(t),Zm):null,this.records.set(t,l)}if(null!=l)return this.hydrate(t,l)}return(i&xi.Self?Jm():this.parent).get(t,e=i&xi.Optional&&e===vp?null:e)}catch(a){if("NullInjectorError"===a.name){if((a[xm]=a[xm]||[]).unshift(dt(t)),s)throw a;return function k_(n,t,e,i){const r=n[xm];throw t[FT]&&r.unshift(t[FT]),n.message=function P_(n,t,e,i=null){n=n&&"\n"===n.charAt(0)&&"\u0275"==n.charAt(1)?n.slice(2):n;let r=dt(t);if(Array.isArray(t))r=t.map(dt).join(" -> ");else if("object"==typeof t){let s=[];for(let o in t)if(t.hasOwnProperty(o)){let a=t[o];s.push(o+":"+("string"==typeof a?JSON.stringify(a):dt(a)))}r=`{${s.join(", ")}}`}return`${e}${i?"("+i+")":""}[${r}]: ${n.replace(T_,"\n ")}`}("\n"+n.message,r,e,i),n.ngTokenPath=r,n[xm]=null,n}(a,t,"R3InjectorError",this.source)}throw a}finally{oo(o),Gh(s)}}resolveInjectorInitializers(){const t=Gh(this),e=oo(void 0);try{const r=this.get(vu,Qi,xi.Self);for(const s of r)s()}finally{Gh(t),oo(e)}}toString(){const t=[],e=this.records;for(const i of e.keys())t.push(dt(i));return`R3Injector[${t.join(", ")}]`}assertNotDestroyed(){if(this._destroyed)throw new F(205,!1)}processProvider(t){let e=Gc(t=vt(t))?t:vt(t&&t.provide);const i=function vj(n){return I1(n)?yu(void 0,n.useValue):yu(ZA(n),Zm)}(t);if(!Gc(t)&&!0===t.multi){let r=this.records.get(e);r||(r=yu(void 0,Zm,!0),r.factory=()=>zb(r.multi),this.records.set(e,r)),e=t,r.multi.push(t)}this.records.set(e,i)}hydrate(t,e){return e.value===Zm&&(e.value=pj,e.value=e.factory()),"object"==typeof e.value&&e.value&&function yj(n){return null!==n&&"object"==typeof n&&"function"==typeof n.ngOnDestroy}(e.value)&&this._ngOnDestroyHooks.add(e.value),e.value}injectableDefInScope(t){if(!t.providedIn)return!1;const e=vt(t.providedIn);return"string"==typeof e?"any"===e||this.scopes.has(e):this.injectorDefTypes.has(e)}removeOnDestroy(t){const e=this._onDestroyHooks.indexOf(t);-1!==e&&this._onDestroyHooks.splice(e,1)}}function w1(n){const t=Cm(n),e=null!==t?t.factory:Vc(n);if(null!==e)return e;if(n instanceof Ht)throw new F(204,!1);if(n instanceof Function)return function gj(n){if(n.length>0)throw new F(204,!1);const e=function C_(n){return n&&(n[Dm]||n[zT])||null}(n);return null!==e?()=>e.factory(n):()=>new n}(n);throw new F(204,!1)}function ZA(n,t,e){let i;if(Gc(n)){const r=vt(n);return Vc(r)||w1(r)}if(I1(n))i=()=>vt(n.useValue);else if(function $A(n){return!(!n||!n.useFactory)}(n))i=()=>n.useFactory(...zb(n.deps||[]));else if(function qA(n){return!(!n||!n.useExisting)}(n))i=()=>_i(vt(n.useExisting));else{const r=vt(n&&(n.useClass||n.provide));if(!function mj(n){return!!n.deps}(n))return Vc(r)||w1(r);i=()=>new r(...zb(n.deps))}return i}function yu(n,t,e=!1){return{factory:n,value:t,multi:e?[]:void 0}}function C1(n,t){for(const e of n)Array.isArray(e)?C1(e,t):e&&$l(e)?C1(e.\u0275providers,t):t(e)}function tL(n,t=null,e=null,i){const r=function iL(n,t=null,e=null,i,r=new Set){const s=[e||Qi,dj(n)];return i=i||("object"==typeof n?void 0:dt(n)),new mu(s,t||Jm(),i||null,r)}(n,t,e,i);return r.resolveInjectorInitializers(),r}let x1,Wo=(()=>{class n{static{this.THROW_IF_NOT_FOUND=vp}static{this.NULL=new qm}static create(e,i){if(Array.isArray(e))return tL({name:""},i,e,"");{const r=e.name??"";return tL({name:r},e.parent,e.providers,r)}}static{this.\u0275prov=Yi({token:n,providedIn:"any",factory:()=>_i(QA)})}static{this.__NG_ELEMENT_ID__=-1}}return n})();const T1=new Ht("",{providedIn:"root",factory:()=>Tj}),Tj="ng",nL=new Ht(""),Su=new Ht("",{providedIn:"platform",factory:()=>"unknown"}),sL=new Ht("",{providedIn:"root",factory:()=>function Zh(){if(void 0!==x1)return x1;if(typeof document<"u")return document;throw new F(210,!1)}().body?.querySelector("[ngCspNonce]")?.getAttribute("ngCspNonce")||null});function ry(n){return 128==(128&n.flags)}var ec=function(n){return n[n.Important=1]="Important",n[n.DashCase=2]="DashCase",n}(ec||{});const k1=new Map;let Uj=0;const z1="__ngContext__";function Rs(n,t){ks(t)?(n[z1]=t[bp],function Vj(n){k1.set(n[bp],n)}(t)):n[z1]=t}let R1;function H1(n,t){return R1(n,t)}function bu(n,t,e,i,r){if(null!=i){let s,o=!1;Ps(i)?s=i:ks(i)&&(o=!0,i=i[Vr]);const a=fr(i);0===n&&null!==e?null==r?xL(t,e,a):qc(t,e,a,r||null,!0):1===n&&null!==e?qc(t,e,a,r||null,!0):2===n?function cy(n,t,e){const i=ly(n,t);i&&function s6(n,t,e,i){n.removeChild(t,e,i)}(n,i,t,e)}(t,a,o):3===n&&t.destroyNode(a),null!=s&&function l6(n,t,e,i,r){const s=e[sl];s!==fr(e)&&bu(t,n,i,s,r);for(let a=mn;a0&&(n[e-1][wa]=i[wa]);const s=Ym(n,mn+t);!function Jj(n,t){CL(n,t),t[Vr]=null,t[Os]=null}(i[Be],i);const o=s[nl];null!==o&&o.detachView(s[Be]),i[vn]=null,i[wa]=null,i[Ct]&=-129}return i}function ay(n,t){if(!(256&t[Ct])){const e=t[Yt];e.destroyNode&&dy(n,t,e,3,null,null),function e6(n){let t=n[Sp];if(!t)return F1(n[Be],n);for(;t;){let e=null;if(ks(t))e=t[Sp];else{const i=t[mn];i&&(e=i)}if(!e){for(;t&&!t[wa]&&t!==n;)ks(t)&&F1(t[Be],t),t=t[vn];null===t&&(t=n),ks(t)&&F1(t[Be],t),e=t&&t[wa]}t=e}}(t)}}function F1(n,t){if(!(256&t[Ct])){t[Ct]&=-129,t[Ct]|=256,t[Uc]&&function Qd(n){if(Gl(n),Wh(n))for(let t=0;t=0?i[o]():i[-o].unsubscribe(),s+=2}else e[s].call(i[e[s+1]]);null!==i&&(t[Kd]=null);const r=t[qh];if(null!==r){t[qh]=null;for(let s=0;s-1){const{encapsulation:s}=n.data[i.directiveStart+r];if(s===ba.None||s===ba.Emulated)return null}return qs(i,e)}}(n,t.parent,e)}function qc(n,t,e,i,r){n.insertBefore(t,e,i,r)}function xL(n,t,e){n.appendChild(t,e)}function TL(n,t,e,i,r){null!==i?qc(n,t,e,i,r):xL(n,t,e)}function ly(n,t){return n.parentNode(t)}let U1,NL=function LL(n,t,e){return 40&n.type?qs(n,e):null};function hy(n,t,e,i){const r=_1(n,i,t),s=t[Yt],a=function AL(n,t,e){return NL(n,t,e)}(i.parent||t[Os],i,t);if(null!=r)if(Array.isArray(e))for(let l=0;lnull;function rM(n,t,e=!1){return ZL(n,t,e)}class Y6{}class iN{}class G6{resolveComponentFactory(t){throw function Q6(n){const t=Error(`No component factory found for ${dt(n)}.`);return t.ngComponent=n,t}(t)}}let Iy=(()=>{class n{static{this.NULL=new G6}}return n})();function X6(){return xu(pr(),Se())}function xu(n,t){return new $c(qs(n,t))}let $c=(()=>{class n{constructor(e){this.nativeElement=e}static{this.__NG_ELEMENT_ID__=X6}}return n})();function q6(n){return n instanceof $c?n.nativeElement:n}class nN{}let aM=(()=>{class n{constructor(){this.destroyNode=null}static{this.__NG_ELEMENT_ID__=()=>function $6(){const n=Se(),e=To(pr().index,n);return(ks(e)?e:n)[Yt]}()}}return n})(),Z6=(()=>{class n{static{this.\u0275prov=Yi({token:n,providedIn:"root",factory:()=>null})}}return n})();const lM={};function Wp(n,t,e,i,r=!1){for(;null!==e;){const s=t[e.index];null!==s&&i.push(fr(s)),Ps(s)&&uN(s,i);const o=e.type;if(8&o)Wp(n,t,e.child,i);else if(32&o){const a=H1(e,t);let l;for(;l=a();)i.push(l)}else if(16&o){const a=kL(t,e);if(Array.isArray(a))i.push(...a);else{const l=Wc(t[Jr]);Wp(l[Be],l,a,i,!0)}}e=r?e.projectionNext:e.next}return i}function uN(n,t){for(let e=mn;e!1,producerRecomputeValue:()=>{},consumerMarkedDirty:()=>{},consumerOnSignalRead:()=>{},consumerIsAlwaysLive:!0,consumerMarkedDirty:n=>{Ep(n.lView)},consumerOnSignalRead(){this.lView[Uc]=this}};function pN(n){return vN(n[Sp])}function gN(n){return vN(n[wa])}function vN(n){for(;null!==n&&!Ps(n);)n=n[wa];return n}function dM(n){return n.ngOriginalError}class nh{constructor(){this._console=console}handleError(t){const e=this._findOriginalError(t);this._console.error("ERROR",t),e&&this._console.error("ORIGINAL ERROR",e)}_findOriginalError(t){let e=t&&dM(t);for(;e&&dM(e);)e=dM(e);return e||null}}const yN=new Ht("",{providedIn:"root",factory:()=>Hi(nh).handleError.bind(void 0)}),IN=new Ht("",{providedIn:"root",factory:()=>!1}),Qt={};function EN(n,t,e,i){if(!i)if(3==(3&t[Ct])){const s=n.preOrderCheckHooks;null!==s&&Fm(t,s,e)}else{const s=n.preOrderHooks;null!==s&&_m(t,s,0,e)}Yc(e)}function Ot(n,t=xi.Default){const e=Se();return null===e?_i(n,t):PA(pr(),e,vt(n),t)}function DN(n,t,e,i,r,s){const o=Wi(null);try{let a=null;r&Xh.SignalBased&&(a=t[i][Ts]),null!==a&&void 0!==a.transformFn&&(s=a.transformFn(s)),r&Xh.HasDecoratorInputTransform&&(s=n.inputTransforms[i].call(t,s)),null!==n.setInput?n.setInput(t,a,s,e,i):rA(t,a,i,s)}finally{Wi(o)}}function Cy(n,t,e,i,r,s,o,a,l,h,c){const d=t.blueprint.slice();return d[Vr]=r,d[Ct]=204|i,(null!==h||n&&2048&n[Ct])&&(d[Ct]|=2048),cA(d),d[vn]=d[eu]=n,d[Er]=e,d[Kl]=o||n&&n[Kl],d[Yt]=a||n&&n[Yt],d[Xs]=l||n&&n[Xs]||null,d[Os]=s,d[bp]=function jj(){return Uj++}(),d[Ca]=c,d[KT]=h,d[Jr]=2==t.type?n[Jr]:d,d}function Tu(n,t,e,i,r){let s=n.data[t];if(null===s)s=function uM(n,t,e,i,r){const s=gA(),o=qb(),l=n.data[t]=function TV(n,t,e,i,r,s){let o=t?t.injectorIndex:-1,a=0;return function nu(){return null!==Rt.skipHydrationRootTNode}()&&(a|=128),{type:e,index:i,insertBeforeIndex:null,injectorIndex:o,directiveStart:-1,directiveEnd:-1,directiveStylingLast:-1,componentOffset:-1,propertyBindings:null,flags:a,providerIndexes:0,value:r,attrs:s,mergedAttrs:null,localNames:null,initialInputs:void 0,inputs:null,outputs:null,tView:null,next:null,prev:null,projectionNext:null,child:null,parent:t,projection:null,styles:null,stylesWithoutHost:null,residualStyles:void 0,classes:null,classesWithoutHost:null,residualClasses:void 0,classBindings:0,styleBindings:0}}(0,o?s:s&&s.parent,e,t,i,r);return null===n.firstChild&&(n.firstChild=l),null!==s&&(o?null==s.child&&null!==l.parent&&(s.child=l):null===s.next&&(s.next=l,l.prev=s)),l}(n,t,e,i,r),function IU(){return Rt.lFrame.inI18n}()&&(s.flags|=32);else if(64&s.type){s.type=e,s.value=i,s.attrs=r;const o=function Dp(){const n=Rt.lFrame,t=n.currentTNode;return n.isParent?t:t.parent}();s.injectorIndex=null===o?-1:o.injectorIndex}return ll(s,!0),s}function Yp(n,t,e,i){if(0===e)return-1;const r=t.length;for(let s=0;sjt&&EN(n,t,jt,!1),ol(o?2:0,r),e(i,r)}finally{Yc(s),ol(o?3:1,r)}}function fM(n,t,e){if(_b(t)){const i=Wi(null);try{const s=t.directiveEnd;for(let o=t.directiveStart;onull;function LN(n,t,e,i,r){for(let s in t){if(!t.hasOwnProperty(s))continue;const o=t[s];if(void 0===o)continue;i??={};let a,l=Xh.None;Array.isArray(o)?(a=o[0],l=o[1]):a=o;let h=s;if(null!==r){if(!r.hasOwnProperty(s))continue;h=r[s]}0===n?NN(i,e,h,a,l):NN(i,e,h,a)}return i}function NN(n,t,e,i,r){let s;n.hasOwnProperty(e)?(s=n[e]).push(t,i):s=n[e]=[t,i],void 0!==r&&s.push(r)}function ON(n,t,e,i,r,s){for(let h=0;h0;){const e=n[--t];if("number"==typeof e&&e<0)return e}return 0})(o)!=a&&o.push(a),o.push(e,i,s)}}(n,t,i,Yp(n,e,r.hostVars,Qt),r)}function VV(n,t,e,i,r,s){const o=s[t];if(null!==o)for(let a=0;an.nextProducerIndex;)n.producerNode.pop(),n.producerLastReadVersion.pop(),n.producerIndexOfThis.pop()}}(a,o),function dV(n){n.lView[Uc]!==n&&(n.lView=null,fN.push(n))}(a)),t1()}}function FN(n,t){for(let e=pN(n);null!==e;e=gN(e))for(let i=mn;i-1&&(Rp(t,i),Ym(e,i))}this._attachedToViewContainer=!1}ay(this._lView[Be],this._lView)}onDestroy(t){!function Rm(n,t){if(256==(256&n[Ct]))throw new F(911,!1);null===n[qh]&&(n[qh]=[]),n[qh].push(t)}(this._lView,t)}markForCheck(){Qp(this._cdRefInjectingView||this._lView)}detach(){this._lView[Ct]&=-129}reattach(){Gb(this._lView),this._lView[Ct]|=128}detectChanges(){this._lView[Ct]|=1024,function MM(n,t=!0){const e=n[Kl],i=e.rendererFactory;i.begin?.();try{!function QV(n){wM(n,0);let t=0;for(;uA(n);){if(100===t)throw new F(103,!1);t++,wM(n,1)}}(n)}catch(s){throw t&&Dy(n,s),s}finally{i.end?.(),e.inlineEffectRunner?.flush()}}(this._lView,this.notifyErrorHandler)}checkNoChanges(){}attachToViewContainerRef(){if(this._appRef)throw new F(902,!1);this._attachedToViewContainer=!0}detachFromAppRef(){this._appRef=null,CL(this._lView[Be],this._lView)}attachToAppRef(t){if(this._attachedToViewContainer)throw new F(902,!1);this._appRef=t,Gb(this._lView)}}const VN=new Set;function EM(n){return t=>{setTimeout(n,void 0,t)}}const Yo=class a7 extends Pt{constructor(t=!1){super(),this.__isAsync=t}emit(t){super.next(t)}subscribe(t,e,i){let r=t,s=e||(()=>null),o=i;if(t&&"object"==typeof t){const l=t;r=l.next?.bind(l),s=l.error?.bind(l),o=l.complete?.bind(l)}this.__isAsync&&(s=EM(s),r&&(r=EM(r)),o&&(o=EM(o)));const a=super.subscribe({next:r,error:s,complete:o});return t instanceof As&&t.add(a),a}};function WN(...n){}class Rr{constructor({enableLongStackTrace:t=!1,shouldCoalesceEventChangeDetection:e=!1,shouldCoalesceRunChangeDetection:i=!1}){if(this.hasPendingMacrotasks=!1,this.hasPendingMicrotasks=!1,this.isStable=!0,this.onUnstable=new Yo(!1),this.onMicrotaskEmpty=new Yo(!1),this.onStable=new Yo(!1),this.onError=new Yo(!1),typeof Zone>"u")throw new F(908,!1);Zone.assertZonePatched();const r=this;r._nesting=0,r._outer=r._inner=Zone.current,Zone.TaskTrackingZoneSpec&&(r._inner=r._inner.fork(new Zone.TaskTrackingZoneSpec)),t&&Zone.longStackTraceZoneSpec&&(r._inner=r._inner.fork(Zone.longStackTraceZoneSpec)),r.shouldCoalesceEventChangeDetection=!i&&e,r.shouldCoalesceRunChangeDetection=i,r.lastRequestAnimationFrameId=-1,r.nativeRequestAnimationFrame=function l7(){const n="function"==typeof rr.requestAnimationFrame;let t=rr[n?"requestAnimationFrame":"setTimeout"],e=rr[n?"cancelAnimationFrame":"clearTimeout"];if(typeof Zone<"u"&&t&&e){const i=t[Zone.__symbol__("OriginalDelegate")];i&&(t=i);const r=e[Zone.__symbol__("OriginalDelegate")];r&&(e=r)}return{nativeRequestAnimationFrame:t,nativeCancelAnimationFrame:e}}().nativeRequestAnimationFrame,function d7(n){const t=()=>{!function c7(n){n.isCheckStableRunning||-1!==n.lastRequestAnimationFrameId||(n.lastRequestAnimationFrameId=n.nativeRequestAnimationFrame.call(rr,()=>{n.fakeTopEventTask||(n.fakeTopEventTask=Zone.root.scheduleEventTask("fakeTopEventTask",()=>{n.lastRequestAnimationFrameId=-1,xM(n),n.isCheckStableRunning=!0,DM(n),n.isCheckStableRunning=!1},void 0,()=>{},()=>{})),n.fakeTopEventTask.invoke()}),xM(n))}(n)};n._inner=n._inner.fork({name:"angular",properties:{isAngularZone:!0},onInvokeTask:(e,i,r,s,o,a)=>{if(function u7(n){return!(!Array.isArray(n)||1!==n.length)&&!0===n[0].data?.__ignore_ng_zone__}(a))return e.invokeTask(r,s,o,a);try{return YN(n),e.invokeTask(r,s,o,a)}finally{(n.shouldCoalesceEventChangeDetection&&"eventTask"===s.type||n.shouldCoalesceRunChangeDetection)&&t(),QN(n)}},onInvoke:(e,i,r,s,o,a,l)=>{try{return YN(n),e.invoke(r,s,o,a,l)}finally{n.shouldCoalesceRunChangeDetection&&t(),QN(n)}},onHasTask:(e,i,r,s)=>{e.hasTask(r,s),i===r&&("microTask"==s.change?(n._hasPendingMicrotasks=s.microTask,xM(n),DM(n)):"macroTask"==s.change&&(n.hasPendingMacrotasks=s.macroTask))},onHandleError:(e,i,r,s)=>(e.handleError(r,s),n.runOutsideAngular(()=>n.onError.emit(s)),!1)})}(r)}static isInAngularZone(){return typeof Zone<"u"&&!0===Zone.current.get("isAngularZone")}static assertInAngularZone(){if(!Rr.isInAngularZone())throw new F(909,!1)}static assertNotInAngularZone(){if(Rr.isInAngularZone())throw new F(909,!1)}run(t,e,i){return this._inner.run(t,e,i)}runTask(t,e,i,r){const s=this._inner,o=s.scheduleEventTask("NgZoneEvent: "+r,t,h7,WN,WN);try{return s.runTask(o,e,i)}finally{s.cancelTask(o)}}runGuarded(t,e,i){return this._inner.runGuarded(t,e,i)}runOutsideAngular(t){return this._outer.run(t)}}const h7={};function DM(n){if(0==n._nesting&&!n.hasPendingMicrotasks&&!n.isStable)try{n._nesting++,n.onMicrotaskEmpty.emit(null)}finally{if(n._nesting--,!n.hasPendingMicrotasks)try{n.runOutsideAngular(()=>n.onStable.emit(null))}finally{n.isStable=!0}}}function xM(n){n.hasPendingMicrotasks=!!(n._hasPendingMicrotasks||(n.shouldCoalesceEventChangeDetection||n.shouldCoalesceRunChangeDetection)&&-1!==n.lastRequestAnimationFrameId)}function YN(n){n._nesting++,n.isStable&&(n.isStable=!1,n.onUnstable.emit(null))}function QN(n){n._nesting--,DM(n)}let Xp=(()=>{class n{constructor(){this.handler=null,this.internalCallbacks=[]}execute(){const e=[...this.internalCallbacks];this.internalCallbacks.length=0;for(const r of e)r();return!!this.handler?.execute()||e.length>0}ngOnDestroy(){this.handler?.destroy(),this.handler=null,this.internalCallbacks.length=0}static{this.\u0275prov=Yi({token:n,providedIn:"root",factory:()=>new n})}}return n})();function v7(n,t){const e=To(t,n),i=e[Be];!function m7(n,t){for(let e=t.length;e0&&RL(n,e,s.join(" "))}}(u,w,p,i),void 0!==e&&function x7(n,t,e){const i=n.projection=[];for(let r=0;r=0;i--){const r=n[i];r.hostVars=t+=r.hostVars,r.hostAttrs=yp(r.hostAttrs,e=yp(e,r.hostAttrs))}}(i)}function A7(n,t){for(const e in t.inputs){if(!t.inputs.hasOwnProperty(e)||n.inputs.hasOwnProperty(e))continue;const i=t.inputs[e];if(void 0!==i&&(n.inputs[e]=i,n.declaredInputs[e]=t.declaredInputs[e],null!==t.inputTransforms)){const r=Array.isArray(i)?i[0]:i;if(!t.inputTransforms.hasOwnProperty(r))continue;n.inputTransforms??={},n.inputTransforms[r]=t.inputTransforms[r]}}}function Ty(n){return n===rl?{}:n===Qi?[]:n}function N7(n,t){const e=n.viewQuery;n.viewQuery=e?(i,r)=>{t(i,r),e(i,r)}:t}function O7(n,t){const e=n.contentQueries;n.contentQueries=e?(i,r,s)=>{t(i,r,s),e(i,r,s)}:t}function k7(n,t){const e=n.hostBindings;n.hostBindings=e?(i,r)=>{t(i,r),e(i,r)}:t}function Lu(n,t){return!t||null===t.firstChild||ry(n)}function tg(n,t,e,i=!0){const r=t[Be];if(function t6(n,t,e,i){const r=mn+i,s=e.length;i>0&&(e[r-1][wa]=t),i{class n{static{this.__NG_ELEMENT_ID__=a9}}return n})();function a9(){return fO(pr(),Se())}const l9=An,dO=class extends l9{constructor(t,e,i){super(),this._lContainer=t,this._hostTNode=e,this._hostLView=i}get element(){return xu(this._hostTNode,this._hostLView)}get injector(){return new Yn(this._hostTNode,this._hostLView)}get parentInjector(){const t=Vm(this._hostTNode,this._hostLView);if(n1(t)){const e=Ap(t,this._hostLView),i=Tp(t);return new Yn(e[Be].data[i+8],e)}return new Yn(null,this._hostLView)}clear(){for(;this.length>0;)this.remove(this.length-1)}get(t){const e=uO(this._lContainer);return null!==e&&e[t]||null}get length(){return this._lContainer.length-mn}createEmbeddedView(t,e,i){let r,s;"number"==typeof i?r=i:null!=i&&(r=i.index,s=i.injector);const a=t.createEmbeddedViewImpl(e||{},s,null);return this.insertImpl(a,r,Lu(this._hostTNode,null)),a}createComponent(t,e,i,r,s){const o=t&&!function Lp(n){return"function"==typeof n}(t);let a;if(o)a=e;else{const p=e||{};a=p.index,i=p.injector,r=p.projectableNodes,s=p.environmentInjector||p.ngModuleRef}const l=o?t:new qp(di(t)),h=i||this.parentInjector;if(!s&&null==l.ngModule){const g=(o?h:this.parentInjector).get(ih,null);g&&(s=g)}di(l.componentType??{});const f=l.create(h,r,null,s);return this.insertImpl(f.hostView,a,Lu(this._hostTNode,null)),f}insert(t,e){return this.insertImpl(t,e,!0)}insertImpl(t,e,i){const r=t._lView;if(function aU(n){return Ps(n[vn])}(r)){const a=this.indexOf(t);if(-1!==a)this.detach(a);else{const l=r[vn],h=new dO(l,l[Os],l[vn]);h.detach(h.indexOf(t))}}const s=this._adjustIndex(e),o=this._lContainer;return tg(o,r,s,i),t.attachToViewContainerRef(),_A(zM(o),s,t),t}move(t,e){return this.insert(t,e)}indexOf(t){const e=uO(this._lContainer);return null!==e?e.indexOf(t):-1}remove(t){const e=this._adjustIndex(t,-1),i=Rp(this._lContainer,e);i&&(Ym(zM(this._lContainer),e),ay(i[Be],i))}detach(t){const e=this._adjustIndex(t,-1),i=Rp(this._lContainer,e);return i&&null!=Ym(zM(this._lContainer),e)?new Gp(i):null}_adjustIndex(t,e=0){return t??this.length+e}};function uO(n){return n[8]}function zM(n){return n[8]||(n[8]=[])}function fO(n,t){let e;const i=t[n.index];return Ps(i)?e=i:(e=function PN(n,t,e,i){return[n,!0,0,t,null,i,null,e,null,null]}(i,t,null,n),t[n.index]=e,Ey(t,e)),pO(e,t,n,i),new dO(e,n,t)}let pO=function vO(n,t,e,i){if(n[sl])return;let r;r=8&e.type?fr(i):function h9(n,t){const e=n[Yt],i=e.createComment(""),r=qs(t,n);return qc(e,ly(e,r),i,function o6(n,t){return n.nextSibling(t)}(e,r),!1),i}(t,e),n[sl]=r};function XM(n,t,e){const i=Se();return function Ln(n,t,e){return!Object.is(n[t],e)&&(n[t]=e,!0)}(i,function hl(){return Rt.lFrame.bindingIndex++}(),t)&&function No(n,t,e,i,r,s,o,a){const l=qs(t,e);let c,h=t.inputs;!a&&null!=h&&(c=h[i])?(bM(n,e,c,i,r),jc(t)&&function NV(n,t){const e=To(t,n);16&e[Ct]||(e[Ct]|=64)}(e,t.index)):3&t.type&&(i=function LV(n){return"class"===n?"className":"for"===n?"htmlFor":"formaction"===n?"formAction":"innerHtml"===n?"innerHTML":"readonly"===n?"readOnly":"tabindex"===n?"tabIndex":n}(i),r=null!=o?o(r,t.value||"",i):r,s.setProperty(l,i,r))}(Ti(),function zr(){const n=Rt.lFrame;return Cp(n.tView,n.selectedIndex)}(),i,n,t,i[Yt],e,!1),XM}function qM(n,t,e,i,r){const o=r?"class":"style";bM(n,e,t.inputs[o],o,i)}function lg(n,t,e,i){const r=Se(),s=Ti(),o=jt+n,a=r[Yt],l=s.firstCreatePass?function R8(n,t,e,i,r,s){const o=t.consts,l=Tu(t,n,2,i,al(o,r));return function mM(n,t,e,i){if(pA()){const r=null===i?null:{"":-1},s=function HV(n,t){const e=n.directiveRegistry;let i=null,r=null;if(e)for(let s=0;s($h(!0),oy(i,r,function EA(){return Rt.lFrame.currentNamespace}()));const Xu="en-US";let Mk=Xu;function ow(n){return!!n&&"function"==typeof n.then}function Gk(n){return!!n&&"function"==typeof n.subscribe}function aw(n,t,e,i){const r=Se(),s=Ti(),o=pr();return function qk(n,t,e,i,r,s,o){const a=Pm(i),h=n.firstCreatePass&&HN(n),c=t[Er],d=RN(t);let u=!0;if(3&i.type||o){const g=qs(i,t),v=o?o(g):g,y=d.length,S=o?M=>o(fr(M[i.index])):i.index;let b=null;if(!o&&a&&(b=function FW(n,t,e,i){const r=n.cleanup;if(null!=r)for(let s=0;sl?a[l]:null}"string"==typeof o&&(s+=2)}return null}(n,t,r,i.index)),null!==b)(b.__ngLastListenerFn__||b).__ngNextListenerFn__=s,b.__ngLastListenerFn__=s,u=!1;else{s=Zk(i,t,c,s,!1);const M=e.listen(v,r,s);d.push(s,M),h&&h.push(r,S,y,y+1)}}else s=Zk(i,t,c,s,!1);const f=i.outputs;let p;if(u&&null!==f&&(p=f[r])){const g=p.length;if(g)for(let v=0;v-1?To(n.index,t):t);let l=$k(t,e,i,o),h=s.__ngNextListenerFn__;for(;h;)l=$k(t,e,h,o)&&l,h=h.__ngNextListenerFn__;return r&&!1===l&&o.preventDefault(),l}}function WW(){return this._results[Symbol.iterator]()}class hw{get changes(){return this._changes??=new Yo}constructor(t=!1){this._emitDistinctChangesOnly=t,this.dirty=!0,this._results=[],this._changesDetected=!1,this._changes=void 0,this.length=0,this.first=void 0,this.last=void 0;const e=hw.prototype;e[Symbol.iterator]||(e[Symbol.iterator]=WW)}get(t){return this._results[t]}map(t){return this._results.map(t)}filter(t){return this._results.filter(t)}find(t){return this._results.find(t)}reduce(t,e){return this._results.reduce(t,e)}forEach(t){this._results.forEach(t)}some(t){return this._results.some(t)}toArray(){return this._results.slice()}toString(){return this._results.toString()}reset(t,e){this.dirty=!1;const i=function lo(n){return n.flat(Number.POSITIVE_INFINITY)}(t);(this._changesDetected=!function XU(n,t,e){if(n.length!==t.length)return!1;for(let i=0;i{class n{static{this.__NG_ELEMENT_ID__=GW}}return n})();const YW=oh,QW=class extends YW{constructor(t,e,i){super(),this._declarationLView=t,this._declarationTContainer=e,this.elementRef=i}get ssrId(){return this._declarationTContainer.tView?.ssrId||null}createEmbeddedView(t,e){return this.createEmbeddedViewImpl(t,e)}createEmbeddedViewImpl(t,e,i){const r=function eg(n,t,e,i){const r=t.tView,a=Cy(n,r,e,4096&n[Ct]?4096:16,null,t,null,null,null,i?.injector??null,i?.dehydratedView??null);a[Ip]=n[t.index];const h=n[nl];return null!==h&&(a[nl]=h.createEmbeddedView(r)),TM(r,a,e),a}(this._declarationLView,this._declarationTContainer,t,{injector:e,dehydratedView:i});return new Gp(r)}};function GW(){return Yy(pr(),Se())}function Yy(n,t){return 4&n.type?new QW(t,n,xu(n,t)):null}class cw{constructor(t){this.queryList=t,this.matches=null}clone(){return new cw(this.queryList)}setDirty(){this.queryList.setDirty()}}class dw{constructor(t=[]){this.queries=t}createEmbeddedView(t){const e=t.queries;if(null!==e){const i=null!==t.contentQueries?t.contentQueries[0]:e.length,r=[];for(let s=0;s0)i.push(o[a/2]);else{const h=s[a+1],c=t[-l];for(let d=mn;d($h(!0),function sy(n,t){return n.createText(t)}(t[Yt],i));function vw(n,t,e,i,r){if(n=vt(n),Array.isArray(n))for(let s=0;s>20;if(Gc(n)||!n.multi){const f=new xp(h,r,Ot),p=yw(l,t,r?c:c+u,d);-1===p?(a1(jm(a,o),s,l),mw(s,n,t.length),t.push(l),a.directiveStart++,a.directiveEnd++,r&&(a.providerIndexes+=1048576),e.push(f),o.push(f)):(e[p]=f,o[p]=f)}else{const f=yw(l,t,c+u,d),p=yw(l,t,c,c+u),v=p>=0&&e[p];if(r&&!v||!r&&!(f>=0&&e[f])){a1(jm(a,o),s,l);const y=function vY(n,t,e,i,r){const s=new xp(n,e,Ot);return s.multi=[],s.index=t,s.componentProviders=0,kP(s,r,i&&!e),s}(r?gY:pY,e.length,r,i,h);!r&&v&&(e[p].providerFactory=y),mw(s,n,t.length,0),t.push(l),a.directiveStart++,a.directiveEnd++,r&&(a.providerIndexes+=1048576),e.push(y),o.push(y)}else mw(s,n,f>-1?f:p,kP(e[r?p:f],h,!r&&i));!r&&i&&v&&e[p].componentProviders++}}}function mw(n,t,e,i){const r=Gc(t),s=function fj(n){return!!n.useClass}(t);if(r||s){const l=(s?vt(t.useClass):t).prototype.ngOnDestroy;if(l){const h=n.destroyHooks||(n.destroyHooks=[]);if(!r&&t.multi){const c=h.indexOf(e);-1===c?h.push(e,[i,l]):h[c+1].push(i,l)}else h.push(e,l)}}}function kP(n,t,e){return e&&n.componentProviders++,n.multi.push(t)-1}function yw(n,t,e,i){for(let r=e;r{e.providersResolver=(i,r)=>function fY(n,t,e){const i=Ti();if(i.firstCreatePass){const r=Ea(n);vw(e,i.data,i.blueprint,r,!0),vw(t,i.data,i.blueprint,r,!1)}}(i,r?r(n):n,t)}}class rd{}class zP extends rd{constructor(t){super(),this.componentFactoryResolver=new JN(this),this.instance=null;const e=new mu([...t.providers,{provide:rd,useValue:this},{provide:Iy,useValue:this.componentFactoryResolver}],t.parent||Jm(),t.debugName,new Set(["environment"]));this.injector=e,t.runEnvironmentInitializers&&e.resolveInjectorInitializers()}destroy(){this.injector.destroy()}onDestroy(t){this.injector.onDestroy(t)}}let bY=(()=>{class n{constructor(e){this._injector=e,this.cachedInjectors=new Map}getOrCreateStandaloneInjector(e){if(!e.standalone)return null;if(!this.cachedInjectors.has(e)){const i=GA(0,e.type),r=i.length>0?function IY(n,t,e=null){return new zP({providers:n,parent:t,debugName:e,runEnvironmentInitializers:!0}).injector}([i],this._injector,`Standalone[${e.type.name}]`):null;this.cachedInjectors.set(e,r)}return this.cachedInjectors.get(e)}ngOnDestroy(){try{for(const e of this.cachedInjectors.values())null!==e&&e.destroy()}finally{this.cachedInjectors.clear()}}static{this.\u0275prov=Yi({token:n,providedIn:"environment",factory:()=>new n(_i(ih))})}}return n})();function RP(n){(function Zc(n){VN.has(n)||(VN.add(n),performance?.mark?.("mark_feature_usage",{detail:{feature:n}}))})("NgStandalone"),n.getStandaloneInjector=t=>t.get(bY).getOrCreateStandaloneInjector(n)}let Tw=(()=>{class n{constructor(){this.taskId=0,this.pendingTasks=new Set,this.hasPendingTasks=new _o(!1)}get _hasPendingTasks(){return this.hasPendingTasks.value}add(){this._hasPendingTasks||this.hasPendingTasks.next(!0);const e=this.taskId++;return this.pendingTasks.add(e),e}remove(e){this.pendingTasks.delete(e),0===this.pendingTasks.size&&this._hasPendingTasks&&this.hasPendingTasks.next(!1)}ngOnDestroy(){this.pendingTasks.clear(),this._hasPendingTasks&&this.hasPendingTasks.next(!1)}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();const g2=new Ht(""),QQ=new Ht("");let kw=(()=>{class n{constructor(){this.initialized=!1,this.done=!1,this.donePromise=new Promise((e,i)=>{this.resolve=e,this.reject=i}),this.appInits=Hi(QQ,{optional:!0})??[]}runInitializers(){if(this.initialized)return;const e=[];for(const r of this.appInits){const s=r();if(ow(s))e.push(s);else if(Gk(s)){const o=new Promise((a,l)=>{s.subscribe({complete:a,error:l})});e.push(o)}}const i=()=>{this.done=!0,this.resolve()};Promise.all(e).then(()=>{i()}).catch(r=>{this.reject(r)}),0===e.length&&i(),this.initialized=!0}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();const v2=new Ht("");let Zu=(()=>{class n{constructor(){this._bootstrapListeners=[],this._runningTick=!1,this._destroyed=!1,this._destroyListeners=[],this._views=[],this.internalErrorHandler=Hi(yN),this.afterRenderEffectManager=Hi(Xp),this.componentTypes=[],this.components=[],this.isStable=Hi(Tw).hasPendingTasks.pipe(jr(e=>!e)),this._injector=Hi(ih)}get destroyed(){return this._destroyed}get injector(){return this._injector}bootstrap(e,i){const r=e instanceof iN;if(!this._injector.get(kw).done)throw!r&&function _c(n){const t=di(n)||Wn(n)||gs(n);return null!==t&&t.standalone}(e),new F(405,!1);let o;o=r?e:this._injector.get(Iy).resolveComponentFactory(e),this.componentTypes.push(o.componentType);const a=function XQ(n){return n.isBoundToModule}(o)?void 0:this._injector.get(rd),h=o.create(Wo.NULL,[],i||o.selector,a),c=h.location.nativeElement,d=h.injector.get(g2,null);return d?.registerApplication(c),h.onDestroy(()=>{this.detachView(h.hostView),Zy(this.components,h),d?.unregisterApplication(c)}),this._loadComponent(h),h}tick(){if(this._runningTick)throw new F(101,!1);try{this._runningTick=!0;for(let e of this._views)e.detectChanges()}catch(e){this.internalErrorHandler(e)}finally{try{this.afterRenderEffectManager.execute()}catch(e){this.internalErrorHandler(e)}this._runningTick=!1}}attachView(e){const i=e;this._views.push(i),i.attachToAppRef(this)}detachView(e){const i=e;Zy(this._views,i),i.detachFromAppRef()}_loadComponent(e){this.attachView(e.hostView),this.tick(),this.components.push(e);const i=this._injector.get(v2,[]);[...this._bootstrapListeners,...i].forEach(r=>r(e))}ngOnDestroy(){if(!this._destroyed)try{this._destroyListeners.forEach(e=>e()),this._views.slice().forEach(e=>e.destroy())}finally{this._destroyed=!0,this._views=[],this._bootstrapListeners=[],this._destroyListeners=[]}}onDestroy(e){return this._destroyListeners.push(e),()=>Zy(this._destroyListeners,e)}destroy(){if(this._destroyed)throw new F(406,!1);const e=this._injector;e.destroy&&!e.destroyed&&e.destroy()}get viewCount(){return this._views.length}warnIfDestroyed(){}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();function Zy(n,t){const e=n.indexOf(t);e>-1&&n.splice(e,1)}let $Q=(()=>{class n{constructor(){this.zone=Hi(Rr),this.applicationRef=Hi(Zu)}initialize(){this._onMicrotaskEmptySubscription||(this._onMicrotaskEmptySubscription=this.zone.onMicrotaskEmpty.subscribe({next:()=>{this.zone.run(()=>{this.applicationRef.tick()})}}))}ngOnDestroy(){this._onMicrotaskEmptySubscription?.unsubscribe()}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();function b2(n){return[{provide:Rr,useFactory:n},{provide:vu,multi:!0,useFactory:()=>{const t=Hi($Q,{optional:!0});return()=>t.initialize()}},{provide:vu,multi:!0,useFactory:()=>{const t=Hi(KQ);return()=>{t.initialize()}}},{provide:yN,useFactory:ZQ}]}function ZQ(){const n=Hi(Rr),t=Hi(nh);return e=>n.runOutsideAngular(()=>t.handleError(e))}function JQ(n){return function y1(n){return{\u0275providers:n}}([[],b2(()=>new Rr(function M2(n){return{enableLongStackTrace:!1,shouldCoalesceEventChangeDetection:n?.eventCoalescing??!1,shouldCoalesceRunChangeDetection:n?.runCoalescing??!1}}(n)))])}let KQ=(()=>{class n{constructor(){this.subscription=new As,this.initialized=!1,this.zone=Hi(Rr),this.pendingTasks=Hi(Tw)}initialize(){if(this.initialized)return;this.initialized=!0;let e=null;!this.zone.isStable&&!this.zone.hasPendingMacrotasks&&!this.zone.hasPendingMicrotasks&&(e=this.pendingTasks.add()),this.zone.runOutsideAngular(()=>{this.subscription.add(this.zone.onStable.subscribe(()=>{Rr.assertNotInAngularZone(),queueMicrotask(()=>{null!==e&&!this.zone.hasPendingMacrotasks&&!this.zone.hasPendingMicrotasks&&(this.pendingTasks.remove(e),e=null)})}))}),this.subscription.add(this.zone.onUnstable.subscribe(()=>{Rr.assertInAngularZone(),e??=this.pendingTasks.add()}))}ngOnDestroy(){this.subscription.unsubscribe()}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();const ah=new Ht("",{providedIn:"root",factory:()=>Hi(ah,xi.Optional|xi.SkipSelf)||function eG(){return typeof $localize<"u"&&$localize.locale||Xu}()}),Pw=new Ht("");let nc=null;function CG(n){try{const{rootComponent:t,appProviders:e,platformProviders:i}=n,r=function sG(n=[]){if(nc)return nc;const t=function E2(n=[],t){return Wo.create({name:t,providers:[{provide:b1,useValue:"platform"},{provide:Pw,useValue:new Set([()=>nc=null])},...n]})}(n);return nc=t,function m2(){!function Sb(n){Xd=n}(()=>{throw new F(600,!1)})}(),function D2(n){n.get(nL,null)?.forEach(e=>e())}(t),t}(i),s=[JQ(),...e||[]],a=new zP({providers:s,parent:r,debugName:"",runEnvironmentInitializers:!1}).injector,l=a.get(Rr);return l.run(()=>{a.resolveInjectorInitializers();const h=a.get(nh,null);let c;l.runOutsideAngular(()=>{c=l.onError.subscribe({next:f=>{h.handleError(f)}})});const d=()=>a.destroy(),u=r.get(Pw);return u.add(d),a.onDestroy(()=>{c.unsubscribe(),u.delete(d)}),function y2(n,t,e){try{const i=e();return ow(i)?i.catch(r=>{throw t.runOutsideAngular(()=>n.handleError(r)),r}):i}catch(i){throw t.runOutsideAngular(()=>n.handleError(i)),i}}(h,l,()=>{const f=a.get(kw);return f.runInitializers(),f.donePromise.then(()=>{!function wk(n){so(n,"Expected localeId to be defined"),"string"==typeof n&&(Mk=n.toLowerCase().replace(/_/g,"-"))}(a.get(ah,Xu)||Xu);const g=a.get(Zu);return void 0!==t&&g.bootstrap(t),g})})})}catch(t){return Promise.reject(t)}}let $2=null;function jw(){return $2}class FG{}const sd=new Ht("");let rq=(()=>{class n{static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275mod=Lm({type:n})}static{this.\u0275inj=gp({})}}return n})();function uz(n){return"server"===n}class Nq extends FG{constructor(){super(...arguments),this.supportsDOMEvents=!0}}class sC extends Nq{static makeCurrent(){!function BG(n){$2??=n}(new sC)}onAndCancel(t,e,i){return t.addEventListener(e,i),()=>{t.removeEventListener(e,i)}}dispatchEvent(t,e){t.dispatchEvent(e)}remove(t){t.parentNode&&t.parentNode.removeChild(t)}createElement(t,e){return(e=e||this.getDefaultDocument()).createElement(t)}createHtmlDocument(){return document.implementation.createHTMLDocument("fakeTitle")}getDefaultDocument(){return document}isElementNode(t){return t.nodeType===Node.ELEMENT_NODE}isShadowRoot(t){return t instanceof DocumentFragment}getGlobalEventTarget(t,e){return"window"===e?window:"document"===e?t:"body"===e?t.body:null}getBaseHref(t){const e=function Oq(){return wg=wg||document.querySelector("base"),wg?wg.getAttribute("href"):null}();return null==e?null:function kq(n){return new URL(n,document.baseURI).pathname}(e)}resetBaseElement(){wg=null}getUserAgent(){return window.navigator.userAgent}getCookie(t){return function EX(n,t){t=encodeURIComponent(t);for(const e of n.split(";")){const i=e.indexOf("="),[r,s]=-1==i?[e,""]:[e.slice(0,i),e.slice(i+1)];if(r.trim()===t)return decodeURIComponent(s)}return null}(document.cookie,t)}}let wg=null,zq=(()=>{class n{build(){return new XMLHttpRequest}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();const oC=new Ht("");let vz=(()=>{class n{constructor(e,i){this._zone=i,this._eventNameToPlugin=new Map,e.forEach(r=>{r.manager=this}),this._plugins=e.slice().reverse()}addEventListener(e,i,r){return this._findPluginFor(i).addEventListener(e,i,r)}getZone(){return this._zone}_findPluginFor(e){let i=this._eventNameToPlugin.get(e);if(i)return i;if(i=this._plugins.find(s=>s.supports(e)),!i)throw new F(5101,!1);return this._eventNameToPlugin.set(e,i),i}static{this.\u0275fac=function(i){return new(i||n)(_i(oC),_i(Rr))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();class mz{constructor(t){this._doc=t}}const aC="ng-app-id";let yz=(()=>{class n{constructor(e,i,r,s={}){this.doc=e,this.appId=i,this.nonce=r,this.platformId=s,this.styleRef=new Map,this.hostNodes=new Set,this.styleNodesInDOM=this.collectServerRenderedStyles(),this.platformIsServer=uz(s),this.resetHostNodes()}addStyles(e){for(const i of e)1===this.changeUsageCount(i,1)&&this.onStyleAdded(i)}removeStyles(e){for(const i of e)this.changeUsageCount(i,-1)<=0&&this.onStyleRemoved(i)}ngOnDestroy(){const e=this.styleNodesInDOM;e&&(e.forEach(i=>i.remove()),e.clear());for(const i of this.getAllStyles())this.onStyleRemoved(i);this.resetHostNodes()}addHost(e){this.hostNodes.add(e);for(const i of this.getAllStyles())this.addStyleToHost(e,i)}removeHost(e){this.hostNodes.delete(e)}getAllStyles(){return this.styleRef.keys()}onStyleAdded(e){for(const i of this.hostNodes)this.addStyleToHost(i,e)}onStyleRemoved(e){const i=this.styleRef;i.get(e)?.elements?.forEach(r=>r.remove()),i.delete(e)}collectServerRenderedStyles(){const e=this.doc.head?.querySelectorAll(`style[${aC}="${this.appId}"]`);if(e?.length){const i=new Map;return e.forEach(r=>{null!=r.textContent&&i.set(r.textContent,r)}),i}return null}changeUsageCount(e,i){const r=this.styleRef;if(r.has(e)){const s=r.get(e);return s.usage+=i,s.usage}return r.set(e,{usage:i,elements:[]}),i}getStyleElement(e,i){const r=this.styleNodesInDOM,s=r?.get(i);if(s?.parentNode===e)return r.delete(i),s.removeAttribute(aC),s;{const o=this.doc.createElement("style");return this.nonce&&o.setAttribute("nonce",this.nonce),o.textContent=i,this.platformIsServer&&o.setAttribute(aC,this.appId),e.appendChild(o),o}}addStyleToHost(e,i){const r=this.getStyleElement(e,i),s=this.styleRef,o=s.get(i)?.elements;o?o.push(r):s.set(i,{elements:[r],usage:1})}resetHostNodes(){const e=this.hostNodes;e.clear(),e.add(this.doc.head)}static{this.\u0275fac=function(i){return new(i||n)(_i(sd),_i(T1),_i(sL,8),_i(Su))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();const lC={svg:"http://www.w3.org/2000/svg",xhtml:"http://www.w3.org/1999/xhtml",xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/",math:"http://www.w3.org/1998/MathML/"},hC=/%COMP%/g,Fq=new Ht("",{providedIn:"root",factory:()=>!0});function Iz(n,t){return t.map(e=>e.replace(hC,n))}let bz=(()=>{class n{constructor(e,i,r,s,o,a,l,h=null){this.eventManager=e,this.sharedStylesHost=i,this.appId=r,this.removeStylesOnCompDestroy=s,this.doc=o,this.platformId=a,this.ngZone=l,this.nonce=h,this.rendererByCompId=new Map,this.platformIsServer=uz(a),this.defaultRenderer=new cC(e,o,l,this.platformIsServer)}createRenderer(e,i){if(!e||!i)return this.defaultRenderer;this.platformIsServer&&i.encapsulation===ba.ShadowDom&&(i={...i,encapsulation:ba.Emulated});const r=this.getOrCreateRenderer(e,i);return r instanceof wz?r.applyToHost(e):r instanceof dC&&r.applyStyles(),r}getOrCreateRenderer(e,i){const r=this.rendererByCompId;let s=r.get(i.id);if(!s){const o=this.doc,a=this.ngZone,l=this.eventManager,h=this.sharedStylesHost,c=this.removeStylesOnCompDestroy,d=this.platformIsServer;switch(i.encapsulation){case ba.Emulated:s=new wz(l,h,i,this.appId,c,o,a,d);break;case ba.ShadowDom:return new Vq(l,h,e,i,o,a,this.nonce,d);default:s=new dC(l,h,i,c,o,a,d)}r.set(i.id,s)}return s}ngOnDestroy(){this.rendererByCompId.clear()}static{this.\u0275fac=function(i){return new(i||n)(_i(vz),_i(yz),_i(T1),_i(Fq),_i(sd),_i(Su),_i(Rr),_i(sL))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();class cC{constructor(t,e,i,r){this.eventManager=t,this.doc=e,this.ngZone=i,this.platformIsServer=r,this.data=Object.create(null),this.throwOnSyntheticProps=!0,this.destroyNode=null}destroy(){}createElement(t,e){return e?this.doc.createElementNS(lC[e]||e,t):this.doc.createElement(t)}createComment(t){return this.doc.createComment(t)}createText(t){return this.doc.createTextNode(t)}appendChild(t,e){(Mz(t)?t.content:t).appendChild(e)}insertBefore(t,e,i){t&&(Mz(t)?t.content:t).insertBefore(e,i)}removeChild(t,e){t&&t.removeChild(e)}selectRootElement(t,e){let i="string"==typeof t?this.doc.querySelector(t):t;if(!i)throw new F(-5104,!1);return e||(i.textContent=""),i}parentNode(t){return t.parentNode}nextSibling(t){return t.nextSibling}setAttribute(t,e,i,r){if(r){e=r+":"+e;const s=lC[r];s?t.setAttributeNS(s,e,i):t.setAttribute(e,i)}else t.setAttribute(e,i)}removeAttribute(t,e,i){if(i){const r=lC[i];r?t.removeAttributeNS(r,e):t.removeAttribute(`${i}:${e}`)}else t.removeAttribute(e)}addClass(t,e){t.classList.add(e)}removeClass(t,e){t.classList.remove(e)}setStyle(t,e,i,r){r&(ec.DashCase|ec.Important)?t.style.setProperty(e,i,r&ec.Important?"important":""):t.style[e]=i}removeStyle(t,e,i){i&ec.DashCase?t.style.removeProperty(e):t.style[e]=""}setProperty(t,e,i){null!=t&&(t[e]=i)}setValue(t,e){t.nodeValue=e}listen(t,e,i){if("string"==typeof t&&!(t=jw().getGlobalEventTarget(this.doc,t)))throw new Error(`Unsupported event target ${t} for event ${e}`);return this.eventManager.addEventListener(t,e,this.decoratePreventDefault(i))}decoratePreventDefault(t){return e=>{if("__ngUnwrap__"===e)return t;!1===(this.platformIsServer?this.ngZone.runGuarded(()=>t(e)):t(e))&&e.preventDefault()}}}function Mz(n){return"TEMPLATE"===n.tagName&&void 0!==n.content}class Vq extends cC{constructor(t,e,i,r,s,o,a,l){super(t,s,o,l),this.sharedStylesHost=e,this.hostEl=i,this.shadowRoot=i.attachShadow({mode:"open"}),this.sharedStylesHost.addHost(this.shadowRoot);const h=Iz(r.id,r.styles);for(const c of h){const d=document.createElement("style");a&&d.setAttribute("nonce",a),d.textContent=c,this.shadowRoot.appendChild(d)}}nodeOrShadowRoot(t){return t===this.hostEl?this.shadowRoot:t}appendChild(t,e){return super.appendChild(this.nodeOrShadowRoot(t),e)}insertBefore(t,e,i){return super.insertBefore(this.nodeOrShadowRoot(t),e,i)}removeChild(t,e){return super.removeChild(this.nodeOrShadowRoot(t),e)}parentNode(t){return this.nodeOrShadowRoot(super.parentNode(this.nodeOrShadowRoot(t)))}destroy(){this.sharedStylesHost.removeHost(this.shadowRoot)}}class dC extends cC{constructor(t,e,i,r,s,o,a,l){super(t,s,o,a),this.sharedStylesHost=e,this.removeStylesOnCompDestroy=r,this.styles=l?Iz(l,i.styles):i.styles}applyStyles(){this.sharedStylesHost.addStyles(this.styles)}destroy(){this.removeStylesOnCompDestroy&&this.sharedStylesHost.removeStyles(this.styles)}}class wz extends dC{constructor(t,e,i,r,s,o,a,l){const h=r+"-"+i.id;super(t,e,i,s,o,a,l,h),this.contentAttr=function _q(n){return"_ngcontent-%COMP%".replace(hC,n)}(h),this.hostAttr=function Uq(n){return"_nghost-%COMP%".replace(hC,n)}(h)}applyToHost(t){this.applyStyles(),this.setAttribute(t,this.hostAttr,"")}createElement(t,e){const i=super.createElement(t,e);return super.setAttribute(i,this.contentAttr,""),i}}let Wq=(()=>{class n extends mz{constructor(e){super(e)}supports(e){return!0}addEventListener(e,i,r){return e.addEventListener(i,r,!1),()=>this.removeEventListener(e,i,r)}removeEventListener(e,i,r){return e.removeEventListener(i,r)}static{this.\u0275fac=function(i){return new(i||n)(_i(sd))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();const Cz=["alt","control","meta","shift"],Yq={"\b":"Backspace","\t":"Tab","\x7f":"Delete","\x1b":"Escape",Del:"Delete",Esc:"Escape",Left:"ArrowLeft",Right:"ArrowRight",Up:"ArrowUp",Down:"ArrowDown",Menu:"ContextMenu",Scroll:"ScrollLock",Win:"OS"},Qq={alt:n=>n.altKey,control:n=>n.ctrlKey,meta:n=>n.metaKey,shift:n=>n.shiftKey};let Gq=(()=>{class n extends mz{constructor(e){super(e)}supports(e){return null!=n.parseEventName(e)}addEventListener(e,i,r){const s=n.parseEventName(i),o=n.eventCallback(s.fullKey,r,this.manager.getZone());return this.manager.getZone().runOutsideAngular(()=>jw().onAndCancel(e,s.domEventName,o))}static parseEventName(e){const i=e.toLowerCase().split("."),r=i.shift();if(0===i.length||"keydown"!==r&&"keyup"!==r)return null;const s=n._normalizeKey(i.pop());let o="",a=i.indexOf("code");if(a>-1&&(i.splice(a,1),o="code."),Cz.forEach(h=>{const c=i.indexOf(h);c>-1&&(i.splice(c,1),o+=h+".")}),o+=s,0!=i.length||0===s.length)return null;const l={};return l.domEventName=r,l.fullKey=o,l}static matchEventFullKeyCode(e,i){let r=Yq[e.key]||e.key,s="";return i.indexOf("code.")>-1&&(r=e.code,s="code."),!(null==r||!r)&&(r=r.toLowerCase()," "===r?r="space":"."===r&&(r="dot"),Cz.forEach(o=>{o!==r&&(0,Qq[o])(e)&&(s+=o+".")}),s+=r,s===i)}static eventCallback(e,i,r){return s=>{n.matchEventFullKeyCode(s,e)&&r.runGuarded(()=>i(s))}}static _normalizeKey(e){return"esc"===e?"escape":e}static{this.\u0275fac=function(i){return new(i||n)(_i(sd))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();function Ez(n){return{appProviders:[...e$,...n?.providers??[]],platformProviders:Jq}}const Jq=[{provide:Su,useValue:"browser"},{provide:nL,useValue:function qq(){sC.makeCurrent()},multi:!0},{provide:sd,useFactory:function Zq(){return function xj(n){x1=n}(document),document},deps:[]}],e$=[{provide:b1,useValue:"root"},{provide:nh,useFactory:function $q(){return new nh},deps:[]},{provide:oC,useClass:Wq,multi:!0,deps:[sd,Rr,Su]},{provide:oC,useClass:Gq,multi:!0,deps:[sd]},bz,yz,vz,{provide:nN,useExisting:bz},{provide:class lq{},useClass:zq,deps:[]},[]];var n$=0,uC=!1;function I0(n,t){var e=t;return e.unshift(void 0),new(Function.prototype.bind.apply(n,e))}function Y(n,t){for(var e=t,i=n.replace(/\[/g,".").replace(/\]/g,"").split("."),r=0;r"u"}function Ei(n){return n+"_"+n$++}function M0(n,t){return n===t||!(n===document||!n)&&M0(n.parentNode,t)}function Dg(n){try{throw new Error(n)}catch(t){throw new Error(t.message+"\n"+t.stack)}}function Re(n){var t=n+"";return t.match(/auto|cm|mm|in|px|pt|pc|%|em|ex|ch|rem|vw|vh|vmin|vmax/)?t:t+"px"}function ce(){return uC}var xg,n,t,h$={latn:{_digits:"0123456789",_type:"numeric"}},Lz={decimal:".",group:",",percentSign:"%",plusSign:"+",minusSign:"-",infinity:"\u221e",nan:"NaN",exponential:"E"},Nz=[0,1,2,3,4,5,6,7,8,9],Hr=function(){function n(){}return n.getMainObject=function(t,e){return Y(ce()?e:"main."+e,t)},n.getNumberingSystem=function(t){return Y("supplemental.numberingSystems",t)||this.numberingSystems},n.reverseObject=function(t,e){for(var r={},s=0,o=e||Object.keys(t);s13&&(p+=1,o-=12),o-=1,a=p-4716;var y=u-24e5,S=10631/30,b=u-1948084,M=Math.floor(b/10631);b-=10631*M;var w=Math.floor((b-.1335)/S),C=30*M+w;b-=Math.floor(w*S+.1335);var D=Math.floor((b+28.5001)/29.5);13===D&&(D=12);for(var A=b-Math.floor(29.5001*D-29),x=0;xy);x++);var P=x+16260,L=Math.floor((P-1)/12),O=L+1,N=P-12*L,T=y-t[x-1]+1;return(T+"").length>2&&(T=A,N=D,O=C),{year:O,month:N,date:T}},n.toGregorian=function i(r,s,o){var g=Math.floor(o+t[12*(r-1)+1+(s-1)-16260-1]-1+24e5+.5),v=Math.floor((g-1867216.25)/36524.25),y=1524+(v=g+1+v-Math.floor(v/4)),S=Math.floor((y-122.1)/365.25),b=Math.floor(365.25*S),M=Math.floor((y-b)/30.6001),w=y-b-Math.floor(30.6001*M),C=M-(M>13.5?13:1),D=S-(C>2.5?4716:4715);return D<=0&&C--,new Date(D+"/"+C+"/"+w)};var ut,u$=/\/MMMMM|MMMM|MMM|a|LLLL|LLL|EEEEE|EEEE|E|K|cccc|ccc|WW|W|G+|z+/gi,Oz="stand-alone",f$=["sun","mon","tue","wed","thu","fri","sat"],kz={m:"getMinutes",h:"getHours",H:"getHours",s:"getSeconds",d:"getDate",f:"getMilliseconds"},Pz=function(){function n(){}return n.dateFormat=function(t,e,i){var r=this,s=ut.getDependables(i,t,e.calendar),o=Y("parserObject.numbers",s),a=s.dateObject,l={isIslamic:ut.islamicRegex.test(e.calendar)};ce()&&e.isServerRendered&&(e=ut.compareBlazorDateFormats(e,t));var h=e.format||ut.getResultantPattern(e.skeleton,s.dateObject,e.type,!1,ce()?t:"");if(l.dateSeperator=ce()?Y("dateSeperator",a):ut.getDateSeparator(s.dateObject),st(h))Dg("Format options or type given must be invalid");else{h=ut.ConvertDateToWeekFormat(h),ce()&&(h=h.replace(/tt/,"a")),l.pattern=h,l.numMapper=ce()?ze({},o):Hr.getNumberMapper(s.parserObject,Hr.getNumberingSystem(i));for(var d=0,u=h.match(u$)||[];d2?r+=e.month[""+u]:p=!0;break;case"E":case"c":r+=e.weekday[""+f$[t.getDay()]];break;case"H":case"h":case"m":case"s":case"d":case"f":if(p=!0,"d"===d)u=o.date;else if("f"===d){p=!1,g=!0;var y=(f=(f=t[""+kz[""+d]]().toString()).substring(0,c)).length;if(c!==y){if(c>3)continue;for(var S=0;S0?1:0],o=Math.abs(t);return s.replace(/HH?|mm/g,function(a){var l=a.length,h=-1!==a.indexOf("H");return i.checkTwodigitNumber(Math.floor(h?o/60:o%60),l)})},n}(),zz={ms:"minimumSignificantDigits",ls:"maximumSignificantDigits",mf:"minimumFractionDigits",lf:"maximumFractionDigits"},tf=["infinity","nan","group","decimal","exponential"],Rz=function(){function n(){}return n.numberFormatter=function(t,e,i){var l,r=this,s=ze({},e),o={},a={},h=ut.getDependables(i,t,"",!0),c=h.numericObject;a.numberMapper=ce()?ze({},c):Hr.getNumberMapper(h.parserObject,Hr.getNumberingSystem(i),!0),a.currencySymbol=ce()?Y("currencySymbol",c):ut.getCurrencySymbol(h.numericObject,s.currency||Lg,e.altSymbol,e.ignoreCurrency),a.percentSymbol=ce()?Y("numberSymbols.percentSign",c):a.numberMapper.numberSymbols.percentSign,a.minusSymbol=ce()?Y("numberSymbols.minusSign",c):a.numberMapper.numberSymbols.minusSign;var d=a.numberMapper.numberSymbols;if(e.format&&!ut.formatRegex.test(e.format))o=ut.customFormat(e.format,a,h.numericObject),!st(s.useGrouping)&&s.useGrouping&&(s.useGrouping=o.pData.useGrouping);else{if(ze(s,ut.getProperNumericSkeleton(e.format||"N")),s.isCurrency="currency"===s.type,s.isPercent="percent"===s.type,ce()||(l=ut.getSymbolPattern(s.type,a.numberMapper.numberSystem,h.numericObject,s.isAccount)),s.groupOne=this.checkValueRange(s.maximumSignificantDigits,s.minimumSignificantDigits,!0),this.checkValueRange(s.maximumFractionDigits,s.minimumFractionDigits,!1,!0),st(s.fractionDigits)||(s.minimumFractionDigits=s.maximumFractionDigits=s.fractionDigits),st(s.useGrouping)&&(s.useGrouping=!0),s.isCurrency&&!ce()&&(l=l.replace(/\u00A4/g,ut.defaultCurrency)),ce())o.nData=ze({},{},Y(s.type+"nData",c)),o.pData=ze({},{},Y(s.type+"pData",c)),"currency"===s.type&&e.currency&&ut.replaceBlazorCurrency([o.pData,o.nData],a.currencySymbol,e.currency);else{var u=l.split(";");o.nData=ut.getFormatData(u[1]||"-"+u[0],!0,a.currencySymbol),o.pData=ut.getFormatData(u[0],!1,a.currencySymbol),s.useGrouping&&(s.groupSeparator=d[tf[2]],s.groupData=this.getGroupingDetails(u[0]))}if(st(s.minimumFractionDigits)&&(s.minimumFractionDigits=o.nData.minimumFraction),st(s.maximumFractionDigits)){var p=o.nData.maximumFraction;s.maximumFractionDigits=st(p)&&s.isPercent?0:p}var g=s.minimumFractionDigits,v=s.maximumFractionDigits;!st(g)&&!st(v)&&g>v&&(s.maximumFractionDigits=g)}return ze(o.nData,s),ze(o.pData,s),function(y){return isNaN(y)?d[tf[1]]:isFinite(y)?r.intNumberFormatter(y,o,a,e):d[tf[0]]}},n.getGroupingDetails=function(t){var e={},i=t.match(ut.negativeDataRegex);if(i&&i[4]){var r=i[4],s=r.lastIndexOf(",");if(-1!==s){var o=r.split(".")[0];e.primary=o.length-s-1;var a=r.lastIndexOf(",",s-1);-1!==a&&(e.secondary=s-1-a)}}return e},n.checkValueRange=function(t,e,i,r){var s=r?"f":"s",o=0,a=zz["l"+s],l=zz["m"+s];if(st(t)||(this.checkRange(t,a,r),o++),st(e)||(this.checkRange(e,l,r),o++),2===o){if(!(tr[1])&&Dg(e+"value must be within the range"+r[0]+"to"+r[1])},n.intNumberFormatter=function(t,e,i,r){var s;if(!st(e.nData.type)){t<0?(t*=-1,s=e.nData):s=0===t&&e.zeroData||e.pData;var o="";if(s.isPercent&&(t*=100),s.groupOne)o=this.processSignificantDigits(t,s.minimumSignificantDigits,s.maximumSignificantDigits);else if(o=this.processFraction(t,s.minimumFractionDigits,s.maximumFractionDigits,r),s.minimumIntegerDigits&&(o=this.processMinimumIntegers(o,s.minimumIntegerDigits)),i.isCustomFormat&&s.minimumFractionDigits=0&&"0"===l[parseInt(c.toString(),10)]&&c>=s.minimumFractionDigits;c--)l=l.slice(0,c);o=a[0]+"."+l}return"scientific"===s.type&&(o=(o=t.toExponential(s.maximumFractionDigits)).replace("e",i.numberMapper.numberSymbols[tf[4]])),o=o.replace(".",i.numberMapper.numberSymbols[tf[3]]),o="#,###,,;(#,###,,)"===s.format?this.customPivotFormat(parseInt(o,10)):o,s.useGrouping&&(o=this.groupNumbers(o,s.groupData.primary,s.groupSeparator||",",i.numberMapper.numberSymbols[tf[3]]||".",s.groupData.secondary)),o=Hr.convertValueParts(o,ut.latnParseRegex,i.numberMapper.mapper),"N/A"===s.nlead?s.nlead:"0"===o&&r&&"0"===r.format?o+s.nend:s.nlead+o+s.nend}},n.processSignificantDigits=function(t,e,i){var r=t+"";return r.lengthe;)c=l.slice(h-e,h)+(c.length?i+c:""),h-=e,o&&(e=s,o=!1);return a[0]=l.slice(0,h)+(c.length?i:"")+c,a.join(r)},n.processFraction=function(t,e,i,r){var s=(t+"").split(".")[1],o=s?s.length:0;if(e&&oi||0===i))return t.toFixed(i);var h=t+"";return"0"===h[0]&&r&&"###.00"===r.format&&(h=h.slice(1)),h},n.processMinimumIntegers=function(t,e){var i=t.split("."),r=i[0],s=r.length;if(s=5e5){var r=(t/=1e6).toString().split(".")[1];return r&&+r.substring(0,1)>=5?Math.ceil(t).toString():Math.floor(t).toString()}return""},n}(),Tg=(new RegExp("^([^0-9]*)(([0-9,]*[0-9]+)(.[0-9]+)?)([Ee][+-]?[0-9]+)?([^0-9]*)$"),function(){function n(t){this.ranArray=[],this.boundedEvents={},!m(t)&&(this.context=t)}return n.prototype.on=function(t,e,i,r){if(!m(e)){var s=i||this.context;if(this.notExist(t))return void(this.boundedEvents[""+t]=[{handler:e,context:s,id:r}]);m(r)?this.isHandlerPresent(this.boundedEvents[""+t],e)||this.boundedEvents[""+t].push({handler:e,context:s}):-1===this.ranArray.indexOf(r)&&(this.ranArray.push(r),this.boundedEvents[""+t].push({handler:e,context:s,id:r}))}},n.prototype.off=function(t,e,i){if(!this.notExist(t)){var r=Y(t,this.boundedEvents);if(e){for(var s=0;s1&&(U.fractionDigits=parseInt(z[2],10)),U}function p(T,z,U,B){var j=B?{}:{nlead:"",nend:""},Q=T.match(n.customRegex);if(Q){B||(j.nlead=g(Q[1],U),j.nend=g(Q[10],U),j.groupPattern=Q[4]);var oe=Q[7];if(oe&&z){var ue=oe.match(t);j.minimumFraction=m(ue)?0:ue.length,j.maximumFraction=oe.length-1}}return j}function g(T,z){return T?(T=T.replace(n.defaultCurrency,z),""===z?T.trim():T):""}function v(T,z,U,B){return B?"$":Y("currencies."+z+(U?"."+U:".symbol"),T)||Y("currencies."+z+".symbol-alt-narrow",T)||"$"}function S(T,z,U){var B={type:"decimal",minimumFractionDigits:0,maximumFractionDigits:0},j=T.match(n.customRegex);if(m(j)||""===j[5]&&"N/A"!==T)return B.type=void 0,B;B.nlead=j[1],B.nend=j[10];var Q=j[6],oe=!!Q.match(/ $/g),ue=-1!==Q.replace(/ $/g,"").indexOf(" ");B.useGrouping=-1!==Q.indexOf(",")||ue,Q=Q.replace(/,/g,"");var fe=j[7];if(-1!==Q.indexOf("0")&&(B.minimumIntegerDigits=Q.length-Q.indexOf("0")),m(fe)||(B.minimumFractionDigits=fe.lastIndexOf("0"),B.maximumFractionDigits=fe.lastIndexOf("#"),-1===B.minimumFractionDigits&&(B.minimumFractionDigits=0),(-1===B.maximumFractionDigits||B.maximumFractionDigitsQ.lastIndexOf("'"))){B[""+a[parseInt(j.toString(),10)]]=Q.substr(0,oe)+U+Q.substr(oe+1),B[""+a[""+z]]=!0,B.type=B.isCurrency?"currency":"percent";break}}return B}function C(T,z){if(-1!==T.indexOf(",")){var U=T.split(",");T=U[0]+Y("numberMapper.numberSymbols.group",z)+U[1].replace(".",Y("numberMapper.numberSymbols.decimal",z))}else T=T.replace(".",Y("numberMapper.numberSymbols.decimal",z));return T}function A(T,z,U){T+=".";for(var B=0;B0;Q-=3)T=","+U[Q-2]+U[Q-1]+U[parseInt(Q.toString(),10)]+T;return T=T.slice(1),z[1]?T+"."+z[1]:T}n.dateParseRegex=/([a-z])\1*|'([^']|'')+'|''|./gi,n.basicPatterns=["short","medium","long","full"],n.defaultObject={dates:{calendars:{gregorian:{months:{"stand-alone":{abbreviated:{1:"Jan",2:"Feb",3:"Mar",4:"Apr",5:"May",6:"Jun",7:"Jul",8:"Aug",9:"Sep",10:"Oct",11:"Nov",12:"Dec"},narrow:{1:"J",2:"F",3:"M",4:"A",5:"M",6:"J",7:"J",8:"A",9:"S",10:"O",11:"N",12:"D"},wide:{1:"January",2:"February",3:"March",4:"April",5:"May",6:"June",7:"July",8:"August",9:"September",10:"October",11:"November",12:"December"}}},days:{"stand-alone":{abbreviated:{sun:"Sun",mon:"Mon",tue:"Tue",wed:"Wed",thu:"Thu",fri:"Fri",sat:"Sat"},narrow:{sun:"S",mon:"M",tue:"T",wed:"W",thu:"T",fri:"F",sat:"S"},short:{sun:"Su",mon:"Mo",tue:"Tu",wed:"We",thu:"Th",fri:"Fr",sat:"Sa"},wide:{sun:"Sunday",mon:"Monday",tue:"Tuesday",wed:"Wednesday",thu:"Thursday",fri:"Friday",sat:"Saturday"}}},dayPeriods:{format:{wide:{am:"AM",pm:"PM"}}},eras:{eraNames:{0:"Before Christ","0-alt-variant":"Before Common Era",1:"Anno Domini","1-alt-variant":"Common Era"},eraAbbr:{0:"BC","0-alt-variant":"BCE",1:"AD","1-alt-variant":"CE"},eraNarrow:{0:"B","0-alt-variant":"BCE",1:"A","1-alt-variant":"CE"}},dateFormats:{full:"EEEE, MMMM d, y",long:"MMMM d, y",medium:"MMM d, y",short:"M/d/yy"},timeFormats:{full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},dateTimeFormats:{full:"{1} 'at' {0}",long:"{1} 'at' {0}",medium:"{1}, {0}",short:"{1}, {0}",availableFormats:{d:"d",E:"ccc",Ed:"d E",Ehm:"E h:mm a",EHm:"E HH:mm",Ehms:"E h:mm:ss a",EHms:"E HH:mm:ss",Gy:"y G",GyMMM:"MMM y G",GyMMMd:"MMM d, y G",GyMMMEd:"E, MMM d, y G",h:"h a",H:"HH",hm:"h:mm a",Hm:"HH:mm",hms:"h:mm:ss a",Hms:"HH:mm:ss",hmsv:"h:mm:ss a v",Hmsv:"HH:mm:ss v",hmv:"h:mm a v",Hmv:"HH:mm v",M:"L",Md:"M/d",MEd:"E, M/d",MMM:"LLL",MMMd:"MMM d",MMMEd:"E, MMM d",MMMMd:"MMMM d",ms:"mm:ss",y:"y",yM:"M/y",yMd:"M/d/y",yMEd:"E, M/d/y",yMMM:"MMM y",yMMMd:"MMM d, y",yMMMEd:"E, MMM d, y",yMMMM:"MMMM y"}}},islamic:{months:{"stand-alone":{abbreviated:{1:"Muh.",2:"Saf.",3:"Rab. I",4:"Rab. II",5:"Jum. I",6:"Jum. II",7:"Raj.",8:"Sha.",9:"Ram.",10:"Shaw.",11:"Dhu\u02bbl-Q.",12:"Dhu\u02bbl-H."},narrow:{1:"1",2:"2",3:"3",4:"4",5:"5",6:"6",7:"7",8:"8",9:"9",10:"10",11:"11",12:"12"},wide:{1:"Muharram",2:"Safar",3:"Rabi\u02bb I",4:"Rabi\u02bb II",5:"Jumada I",6:"Jumada II",7:"Rajab",8:"Sha\u02bbban",9:"Ramadan",10:"Shawwal",11:"Dhu\u02bbl-Qi\u02bbdah",12:"Dhu\u02bbl-Hijjah"}}},days:{"stand-alone":{abbreviated:{sun:"Sun",mon:"Mon",tue:"Tue",wed:"Wed",thu:"Thu",fri:"Fri",sat:"Sat"},narrow:{sun:"S",mon:"M",tue:"T",wed:"W",thu:"T",fri:"F",sat:"S"},short:{sun:"Su",mon:"Mo",tue:"Tu",wed:"We",thu:"Th",fri:"Fr",sat:"Sa"},wide:{sun:"Sunday",mon:"Monday",tue:"Tuesday",wed:"Wednesday",thu:"Thursday",fri:"Friday",sat:"Saturday"}}},dayPeriods:{format:{wide:{am:"AM",pm:"PM"}}},eras:{eraNames:{0:"AH"},eraAbbr:{0:"AH"},eraNarrow:{0:"AH"}},dateFormats:{full:"EEEE, MMMM d, y G",long:"MMMM d, y G",medium:"MMM d, y G",short:"M/d/y GGGGG"},timeFormats:{full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},dateTimeFormats:{full:"{1} 'at' {0}",long:"{1} 'at' {0}",medium:"{1}, {0}",short:"{1}, {0}",availableFormats:{d:"d",E:"ccc",Ed:"d E",Ehm:"E h:mm a",EHm:"E HH:mm",Ehms:"E h:mm:ss a",EHms:"E HH:mm:ss",Gy:"y G",GyMMM:"MMM y G",GyMMMd:"MMM d, y G",GyMMMEd:"E, MMM d, y G",h:"h a",H:"HH",hm:"h:mm a",Hm:"HH:mm",hms:"h:mm:ss a",Hms:"HH:mm:ss",M:"L",Md:"M/d",MEd:"E, M/d",MMM:"LLL",MMMd:"MMM d",MMMEd:"E, MMM d",MMMMd:"MMMM d",ms:"mm:ss",y:"y G",yyyy:"y G",yyyyM:"M/y GGGGG",yyyyMd:"M/d/y GGGGG",yyyyMEd:"E, M/d/y GGGGG",yyyyMMM:"MMM y G",yyyyMMMd:"MMM d, y G",yyyyMMMEd:"E, MMM d, y G",yyyyMMMM:"MMMM y G",yyyyQQQ:"QQQ y G",yyyyQQQQ:"QQQQ y G"}}}},timeZoneNames:{hourFormat:"+HH:mm;-HH:mm",gmtFormat:"GMT{0}",gmtZeroFormat:"GMT"}},numbers:{currencies:{USD:{displayName:"US Dollar",symbol:"$","symbol-alt-narrow":"$"},EUR:{displayName:"Euro",symbol:"\u20ac","symbol-alt-narrow":"\u20ac"},GBP:{displayName:"British Pound","symbol-alt-narrow":"\xa3"}},defaultNumberingSystem:"latn",minimumGroupingDigits:"1","symbols-numberSystem-latn":{decimal:".",group:",",list:";",percentSign:"%",plusSign:"+",minusSign:"-",exponential:"E",superscriptingExponent:"\xd7",perMille:"\u2030",infinity:"\u221e",nan:"NaN",timeSeparator:":"},"decimalFormats-numberSystem-latn":{standard:"#,##0.###"},"percentFormats-numberSystem-latn":{standard:"#,##0%"},"currencyFormats-numberSystem-latn":{standard:"\xa4#,##0.00",accounting:"\xa4#,##0.00;(\xa4#,##0.00)"},"scientificFormats-numberSystem-latn":{standard:"#E0"}}},n.blazorDefaultObject={numbers:{mapper:{0:"0",1:"1",2:"2",3:"3",4:"4",5:"5",6:"6",7:"7",8:"8",9:"9"},mapperDigits:"0123456789",numberSymbols:{decimal:".",group:",",plusSign:"+",minusSign:"-",percentSign:"%",nan:"NaN",timeSeparator:":",infinity:"\u221e"},timeSeparator:":",currencySymbol:"$",currencypData:{nlead:"$",nend:"",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},percentpData:{nlead:"",nend:"%",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},percentnData:{nlead:"-",nend:"%",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},currencynData:{nlead:"($",nend:")",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},decimalnData:{nlead:"-",nend:"",groupData:{primary:3},maximumFraction:2,minimumFraction:2},decimalpData:{nlead:"",nend:"",groupData:{primary:3},maximumFraction:2,minimumFraction:2}},dates:{dayPeriods:{am:"AM",pm:"PM"},dateSeperator:"/",days:{abbreviated:{sun:"Sun",mon:"Mon",tue:"Tue",wed:"Wed",thu:"Thu",fri:"Fri",sat:"Sat"},short:{sun:"Su",mon:"Mo",tue:"Tu",wed:"We",thu:"Th",fri:"Fr",sat:"Sa"},wide:{sun:"Sunday",mon:"Monday",tue:"Tuesday",wed:"Wednesday",thu:"Thursday",fri:"Friday",sat:"Saturday"}},months:{abbreviated:{1:"Jan",2:"Feb",3:"Mar",4:"Apr",5:"May",6:"Jun",7:"Jul",8:"Aug",9:"Sep",10:"Oct",11:"Nov",12:"Dec"},wide:{1:"January",2:"February",3:"March",4:"April",5:"May",6:"June",7:"July",8:"August",9:"September",10:"October",11:"November",12:"December"}},eras:{1:"AD"}}},n.monthIndex={3:"abbreviated",4:"wide",5:"narrow",1:"abbreviated"},n.month="months",n.days="days",n.patternMatcher={C:"currency",P:"percent",N:"decimal",A:"currency",E:"scientific"},n.getResultantPattern=l,n.getDependables=h,n.getSymbolPattern=c,n.ConvertDateToWeekFormat=d,n.compareBlazorDateFormats=u,n.getProperNumericSkeleton=f,n.getFormatData=p,n.changeCurrencySymbol=g,n.getCurrencySymbol=v,n.customFormat=function y(T,z,U){for(var B={},j=T.split(";"),Q=["pData","nData","zeroData"],oe=0;oe1,fe.nData=ce()?Y(De.type+"nData",oe):p(ot[1]||"-"+ot[0],!0,Ie),fe.pData=ce()?Y(De.type+"pData",oe):p(ot[0],!1,Ie),!Me[2]&&!z.minimumFractionDigits&&!z.maximumFractionDigits&&(ue=p(Ve.split(";")[0],!0,"",!0).minimumFraction)}if(n.formatRegex.test(z.format)||!z.format){if(ze(Q,f(z.format||"N")),Q.custom=!1,$e="###0",(Q.fractionDigits||z.minimumFractionDigits||z.maximumFractionDigits||ue)&&(Q.fractionDigits&&(z.minimumFractionDigits=z.maximumFractionDigits=Q.fractionDigits),$e=A($e,ue||Q.fractionDigits||z.minimumFractionDigits||0,z.maximumFractionDigits||0)),z.minimumIntegerDigits&&($e=x($e,z.minimumIntegerDigits)),z.useGrouping&&($e=P($e)),"currency"===Q.type||Q.type&&ce()){ce()&&"currency"!==Q.type&&(fe.pData=Y(Q.type+"pData",oe),fe.nData=Y(Q.type+"nData",oe));var hr=$e;$e=fe.pData.nlead+hr+fe.pData.nend,(fe.hasNegativePattern||ce())&&($e+=";"+fe.nData.nlead+hr+fe.nData.nend)}"percent"===Q.type&&!ce()&&($e+=" %")}else $e=z.format.replace(/'/g,'"');return Object.keys(xe).length>0&&($e=B?$e:C($e,xe)),$e},n.fractionDigitsPattern=A,n.minimumIntegerPattern=x,n.groupingPattern=P,n.getWeekData=function L(T,z){var U="sun",B=Y("supplemental.weekData.firstDay",z),j=T;return/en-/.test(j)&&(j=j.slice(3)),j=j.slice(0,2).toUpperCase()+j.substr(2),B&&(U=B[""+j]||B[j.slice(0,2)]||"sun"),o[""+U]},n.replaceBlazorCurrency=function O(T,z,U){var B=function d$(n){return Y(n||"",c$)}(U);if(z!==B)for(var j=0,Q=T;j=0?U:U+7;var j=Math.floor((T.getTime()-z.getTime()-6e4*(T.getTimezoneOffset()-z.getTimezoneOffset()))/864e5)+1;if(U<4){if((B=Math.floor((j+U-1)/7)+1)>52){var oe=new Date(T.getFullYear()+1,0,1).getDay();B=(oe=oe>=0?oe:oe+7)<4?1:53}}else B=Math.floor((j+U-1)/7);return B}}(ut||(ut={}));var rf=function(){function n(t,e,i){this.type="GET",this.emitError=!0,"string"==typeof t?(this.url=t,this.type=m(e)?this.type:e.toUpperCase(),this.contentType=i):La(t)&&Object.keys(t).length>0&&kn(this,t),this.contentType=m(this.contentType)?"application/json; charset=utf-8":this.contentType}return n.prototype.send=function(t){var e=this,i={"application/json":"json","multipart/form-data":"formData","application/octet-stream":"blob","application/x-www-form-urlencoded":"formData"};try{m(this.fetchRequest)&&"GET"===this.type?this.fetchRequest=new Request(this.url,{method:this.type}):m(this.fetchRequest)&&(this.data=m(t)?this.data:t,this.fetchRequest=new Request(this.url,{method:this.type,headers:{"Content-Type":this.contentType},body:this.data}));var r={cancel:!1,fetchRequest:this.fetchRequest};return this.triggerEvent(this.beforeSend,r),r.cancel?null:(this.fetchResponse=fetch(this.fetchRequest),this.fetchResponse.then(function(s){if(e.triggerEvent(e.onLoad,s),!s.ok)throw s;for(var o="text",a=0,l=Object.keys(i);a-1},n.getValue=function(t,e){var i=typeof window<"u"?window.browserDetails:{};return typeof navigator<"u"&&"MacIntel"===navigator.platform&&navigator.maxTouchPoints>1&&!0===n.isTouch&&!gC.CHROME.test(navigator.userAgent)&&(i.isIos=!0,i.isDevice=!0,i.isTouch=!0,i.isPointer=!0,i.isPointer="pointerEnabled"in window.navigator),typeof window<"u"&&window.Capacitor&&"ios"===window.Capacitor.getPlatform()&&(i.isPointer=!1),typeof i[""+t]>"u"?i[""+t]=e.test(n.userAgent):i[""+t]},Object.defineProperty(n,"userAgent",{get:function(){return n.uA},set:function(t){n.uA=t,window.browserDetails={}},enumerable:!0,configurable:!0}),Object.defineProperty(n,"info",{get:function(){return st(window.browserDetails.info)?window.browserDetails.info=n.extractBrowserDetail():window.browserDetails.info},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isIE",{get:function(){return n.getValue("isIE",x$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isTouch",{get:function(){return st(window.browserDetails.isTouch)?window.browserDetails.isTouch="ontouchstart"in window.navigator||window&&window.navigator&&window.navigator.maxTouchPoints>0||"ontouchstart"in window:window.browserDetails.isTouch},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isPointer",{get:function(){return st(window.browserDetails.isPointer)?window.browserDetails.isPointer="pointerEnabled"in window.navigator:window.browserDetails.isPointer},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isMSPointer",{get:function(){return st(window.browserDetails.isMSPointer)?window.browserDetails.isMSPointer="msPointerEnabled"in window.navigator:window.browserDetails.isMSPointer},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isDevice",{get:function(){return n.getValue("isDevice",D$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isIos",{get:function(){return n.getValue("isIos",A$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isIos7",{get:function(){return n.getValue("isIos7",L$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isAndroid",{get:function(){return n.getValue("isAndroid",N$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isWebView",{get:function(){return st(window.browserDetails.isWebView)&&(window.browserDetails.isWebView=!(st(window.cordova)&&st(window.PhoneGap)&&st(window.phonegap)&&"object"!==window.forge)),window.browserDetails.isWebView},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isWindows",{get:function(){return n.getValue("isWindows",O$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"touchStartEvent",{get:function(){return st(window.browserDetails.touchStartEvent)?window.browserDetails.touchStartEvent=n.getTouchStartEvent():window.browserDetails.touchStartEvent},enumerable:!0,configurable:!0}),Object.defineProperty(n,"touchMoveEvent",{get:function(){return st(window.browserDetails.touchMoveEvent)?window.browserDetails.touchMoveEvent=n.getTouchMoveEvent():window.browserDetails.touchMoveEvent},enumerable:!0,configurable:!0}),Object.defineProperty(n,"touchEndEvent",{get:function(){return st(window.browserDetails.touchEndEvent)?window.browserDetails.touchEndEvent=n.getTouchEndEvent():window.browserDetails.touchEndEvent},enumerable:!0,configurable:!0}),Object.defineProperty(n,"touchCancelEvent",{get:function(){return st(window.browserDetails.touchCancelEvent)?window.browserDetails.touchCancelEvent=n.getTouchCancelEvent():window.browserDetails.touchCancelEvent},enumerable:!0,configurable:!0}),n.uA=typeof navigator<"u"?navigator.userAgent:"",n}(),E=function(){function n(){}return n.addOrGetEventData=function(t){return"__eventList"in t?t.__eventList.events:(t.__eventList={},t.__eventList.events=[])},n.add=function(t,e,i,r,s){var a,o=n.addOrGetEventData(t);a=s?function o$(n,t){var e;return function(){for(var i=this,r=[],s=0;s"u"||(e.innerHTML=t.innerHTML?t.innerHTML:"",void 0!==t.className&&(e.className=t.className),void 0!==t.id&&(e.id=t.id),void 0!==t.styles&&e.setAttribute("style",t.styles),void 0!==t.attrs&&Fe(e,t.attrs)),e}function V(n,t){for(var e=Vz(t),i=RegExp,r=0,s=n;r0}function gl(n,t,e){for(var i=document.createDocumentFragment(),r=0,s=n;r0;)i.appendChild(n[0]);else for(var r=0,s=n;r-1&&!r[parseInt(s.toString(),10)].match(/\[.*\]/)){var o=r[parseInt(s.toString(),10)].split("#");if(o[1].match(/^\d/)||o[1].match(t)){var a=r[parseInt(s.toString(),10)].split(".");a[0]=a[0].replace(/#/,"[id='")+"']",r[parseInt(s.toString(),10)]=a.join(".")}}e[parseInt(i.toString(),10)]=r.join(" ")}return e.join(",")}return n}function J(n,t){var e=n;if("function"==typeof e.closest)return e.closest(t);for(;e&&1===e.nodeType;){if(vC(e,t))return e;e=e.parentNode}return null}function je(n,t){void 0!==t&&Object.keys(t).forEach(function(e){n.style[""+e]=t[""+e]})}function vC(n,t){var e=n.matches||n.msMatchesSelector||n.webkitMatchesSelector;return e?e.call(n,t):-1!==[].indexOf.call(document.querySelectorAll(t),n)}var z$=new RegExp("]"),dh=function(){function n(t,e){this.isRendered=!1,this.isComplexArraySetter=!1,this.isServerRendered=!1,this.allowServerDataBinding=!0,this.isProtectedOnChange=!0,this.properties={},this.changedProperties={},this.oldProperties={},this.bulkChanges={},this.refreshing=!1,this.ignoreCollectionWatch=!1,this.finalUpdate=function(){},this.childChangedProperties={},this.modelObserver=new Tg(this),st(e)||(this.element="string"==typeof e?document.querySelector(e):e,m(this.element)||(this.isProtectedOnChange=!1,this.addInstance())),st(t)||this.setProperties(t,!0),this.isDestroyed=!1}return n.prototype.setProperties=function(t,e){var i=this.isProtectedOnChange;this.isProtectedOnChange=!!e,kn(this,t),!0!==e?(kn(this.changedProperties,t),this.dataBind()):ce()&&this.isRendered&&this.serverDataBind(t),this.finalUpdate(),this.changedProperties={},this.oldProperties={},this.isProtectedOnChange=i},n.callChildDataBind=function(t,e){for(var r=0,s=Object.keys(t);r=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Hs=function(n){function t(i){var r=n.call(this,i,void 0)||this;return r.easing={ease:"cubic-bezier(0.250, 0.100, 0.250, 1.000)",linear:"cubic-bezier(0.250, 0.250, 0.750, 0.750)",easeIn:"cubic-bezier(0.420, 0.000, 1.000, 1.000)",easeOut:"cubic-bezier(0.000, 0.000, 0.580, 1.000)",easeInOut:"cubic-bezier(0.420, 0.000, 0.580, 1.000)",elasticInOut:"cubic-bezier(0.5,-0.58,0.38,1.81)",elasticIn:"cubic-bezier(0.17,0.67,0.59,1.81)",elasticOut:"cubic-bezier(0.7,-0.75,0.99,1.01)"},r}var e;return Q$(t,n),e=t,t.prototype.animate=function(i,r){var s=this.getModel(r=r||{});if("string"==typeof i)for(var a=0,l=Array.prototype.slice.call(we(i,document));a0?r-1:0,i+=e=-1!==e?"-"+e:"-"+r}return this.controlParent!==this.parentObj&&(i=this.parentObj.getParentKey()+"."+this.propName+e),i},n}(),$$=["grid","pivotview","treegrid","spreadsheet","rangeNavigator","DocumentEditor","listbox","inplaceeditor","PdfViewer","richtexteditor","DashboardLayout","chart","stockChart","circulargauge","diagram","heatmap","lineargauge","maps","slider","smithchart","barcode","sparkline","treemap","bulletChart","kanban","daterangepicker","schedule","gantt","signature","query-builder","drop-down-tree","carousel","filemanager","uploader","accordion","tab","treeview"],tR=[115,121,110,99,102,117,115,105,111,110,46,105,115,76,105,99,86,97,108,105,100,97,116,101,100],iR=function(){function n(t){this.isValidated=!1,this.isLicensed=!0,this.version="27",this.platform=/JavaScript|ASPNET|ASPNETCORE|ASPNETMVC|FileFormats|essentialstudio/i,this.errors={noLicense:"This application was built using a trial version of Syncfusion Essential Studio. To remove the license validation message permanently, a valid license key must be included.",trailExpired:"This application was built using a trial version of Syncfusion Essential Studio. To remove the license validation message permanently, a valid license key must be included.",versionMismatched:"The included Syncfusion license key is invalid.",platformMismatched:"The included Syncfusion license key is invalid.",invalidKey:"The included Syncfusion license key is invalid."},this.manager=function(){var e=null;return{setKey:function i(s){e=s},getKey:function r(){return e}}}(),this.npxManager=function(){return{getKey:function i(){return"npxKeyReplace"}}}(),this.manager.setKey(t)}return n.prototype.validate=function(){if(!this.isValidated&&ef&&!Y(D0(tR),ef)&&!Y("Blazor",ef)){var i=void 0,r=void 0;if(this.manager&&this.manager.getKey()||this.npxManager&&"npxKeyReplace"!==this.npxManager.getKey()){var s=this.getInfoFromKey();if(s&&s.length)for(var o=0,a=s;o"+i+' Claim your FREE account\n
have a Syncfusion account? Sign In
\n
\n ';if(typeof document<"u"&&!m(document)){var t=Si("div",{innerHTML:n});document.body.appendChild(t)}}(),oR=!0),this.render(),this.mount?this.accessMount():this.trigger("created")}},t.prototype.renderComplete=function(e){ce()&&window.sfBlazor.renderComplete(this.element,e),this.isRendered=!0},t.prototype.dataBind=function(){this.injectModules(),n.prototype.dataBind.call(this)},t.prototype.on=function(e,i,r){if("string"==typeof e)this.localObserver.on(e,i,r);else for(var s=0,o=e;s=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},tZ={left:0,top:0,bottom:0,right:0},bC={isDragged:!1},iZ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return aR(t,n),gr([I(0)],t.prototype,"left",void 0),gr([I(0)],t.prototype,"top",void 0),t}(Ee),of=function(n){function t(i,r){var s=n.call(this,r,i)||this;return s.dragLimit=e.getDefaultPosition(),s.borderWidth=e.getDefaultPosition(),s.padding=e.getDefaultPosition(),s.diffX=0,s.prevLeft=0,s.prevTop=0,s.dragProcessStarted=!1,s.eleTop=0,s.tapHoldTimer=0,s.externalInitialize=!1,s.diffY=0,s.parentScrollX=0,s.parentScrollY=0,s.droppables={},s.bind(),s}var e;return aR(t,n),e=t,t.prototype.bind=function(){this.toggleEvents(),X.isIE&&V([this.element],"e-block-touch"),this.droppables[this.scope]={}},t.getDefaultPosition=function(){return ze({},tZ)},t.prototype.toggleEvents=function(i){var r;st(this.handle)||(r=_(this.handle,this.element));var s=this.enableTapHold&&X.isDevice&&X.isTouch?this.mobileInitialize:this.initialize;i?E.remove(r||this.element,X.isSafari()?"touchstart":X.touchStartEvent,s):E.add(r||this.element,X.isSafari()?"touchstart":X.touchStartEvent,s,this)},t.prototype.mobileInitialize=function(i){var r=this,s=i.currentTarget;this.tapHoldTimer=setTimeout(function(){r.externalInitialize=!0,r.removeTapholdTimer(),r.initialize(i,s)},this.tapHoldThreshold),E.add(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.removeTapholdTimer,this),E.add(document,X.isSafari()?"touchend":X.touchEndEvent,this.removeTapholdTimer,this)},t.prototype.removeTapholdTimer=function(){clearTimeout(this.tapHoldTimer),E.remove(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.removeTapholdTimer),E.remove(document,X.isSafari()?"touchend":X.touchEndEvent,this.removeTapholdTimer)},t.prototype.getScrollableParent=function(i,r){return m(i)?null:i[{vertical:"scrollHeight",horizontal:"scrollWidth"}[""+r]]>i[{vertical:"clientHeight",horizontal:"clientWidth"}[""+r]]&&("vertical"===r?i.scrollTop>0:i.scrollLeft>0)?("vertical"===r?(this.parentScrollY=this.parentScrollY+(0===this.parentScrollY?i.scrollTop:i.scrollTop-this.parentScrollY),this.tempScrollHeight=i.scrollHeight):(this.parentScrollX=this.parentScrollX+(0===this.parentScrollX?i.scrollLeft:i.scrollLeft-this.parentScrollX),this.tempScrollWidth=i.scrollWidth),m(i)?i:this.getScrollableParent(i.parentNode,r)):this.getScrollableParent(i.parentNode,r)},t.prototype.getScrollableValues=function(){this.parentScrollX=0,this.parentScrollY=0,this.element.classList.contains("e-dialog")&&this.element.classList.contains("e-dlg-modal"),this.getScrollableParent(this.element.parentNode,"vertical"),this.getScrollableParent(this.element.parentNode,"horizontal")},t.prototype.initialize=function(i,r){if(this.currentStateTarget=i.target,!this.isDragStarted()){if(this.isDragStarted(!0),this.externalInitialize=!1,this.target=i.currentTarget||r,this.dragProcessStarted=!1,this.abort){var s=this.abort;"string"==typeof s&&(s=[s]);for(var o=0;o=this.distance||this.externalInitialize){var f=this.getHelperElement(i);if(!f||m(f))return;r&&i.preventDefault();var p=this.helperElement=f;if(this.parentClientRect=this.calculateParentPosition(p.offsetParent),this.dragStart){var v={event:i,element:l,target:this.getProperTargetElement(i),bindEvents:ce()?this.bindDragEvents.bind(this):null,dragElement:p};this.trigger("dragStart",v)}this.dragArea?this.setDragArea():(this.dragLimit={left:0,right:0,bottom:0,top:0},this.borderWidth={top:0,left:0}),o={left:this.position.left-this.parentClientRect.left,top:this.position.top-this.parentClientRect.top},this.clone&&!this.enableTailMode&&(this.diffX=this.position.left-this.offset.left,this.diffY=this.position.top-this.offset.top),this.getScrollableValues();var y=getComputedStyle(l),S=parseFloat(y.marginTop);this.clone&&0!==S&&(o.top+=S),this.eleTop=isNaN(parseFloat(y.top))?0:parseFloat(y.top)-this.offset.top,this.enableScrollHandler&&!this.clone&&(o.top-=this.parentScrollY,o.left-=this.parentScrollX);var b=this.getProcessedPositionValue({top:o.top-this.diffY+"px",left:o.left-this.diffX+"px"});this.dragArea&&"string"!=typeof this.dragArea&&this.dragArea.classList.contains("e-kanban-content")&&"relative"===this.dragArea.style.position&&(o.top+=this.dragArea.scrollTop),this.dragElePosition={top:o.top,left:o.left},je(p,this.getDragPosition({position:"absolute",left:b.left,top:b.top})),E.remove(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.intDragStart),E.remove(document,X.isSafari()?"touchend":X.touchEndEvent,this.intDestroy),ce()||this.bindDragEvents(p)}}},t.prototype.bindDragEvents=function(i){Tr(i)?(E.add(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.intDrag,this),E.add(document,X.isSafari()?"touchend":X.touchEndEvent,this.intDragStop,this),this.setGlobalDroppables(!1,this.element,i)):(this.toggleEvents(),document.body.classList.remove("e-prevent-select"))},t.prototype.elementInViewport=function(i){for(this.top=i.offsetTop,this.left=i.offsetLeft,this.width=i.offsetWidth,this.height=i.offsetHeight;i.offsetParent;)this.top+=(i=i.offsetParent).offsetTop,this.left+=i.offsetLeft;return this.top>=window.pageYOffset&&this.left>=window.pageXOffset&&this.top+this.height<=window.pageYOffset+window.innerHeight&&this.left+this.width<=window.pageXOffset+window.innerWidth},t.prototype.getProcessedPositionValue=function(i){return this.queryPositionInfo?this.queryPositionInfo(i):i},t.prototype.calculateParentPosition=function(i){if(m(i))return{left:0,top:0};var r=i.getBoundingClientRect(),s=getComputedStyle(i);return{left:r.left+window.pageXOffset-parseInt(s.marginLeft,10),top:r.top+window.pageYOffset-parseInt(s.marginTop,10)}},t.prototype.intDrag=function(i){if(st(i.changedTouches)||1===i.changedTouches.length){var r,s;this.clone&&i.changedTouches&&X.isDevice&&X.isTouch&&i.preventDefault(),this.position=this.getMousePosition(i,this.isDragScroll);var o=this.getDocumentWidthHeight("Height");oy&&y>0?this.dragLimit.left:this.dragLimit.right+window.pageXOffset0?y-(y-this.dragLimit.right)+window.pageXOffset-M:y<0?this.dragLimit.left:y}if(this.pageY!==v||this.skipDistanceCheck){var w=d.offsetHeight+(parseFloat(b.marginTop)+parseFloat(b.marginBottom));s=this.dragLimit.top>S&&S>0?this.dragLimit.top:this.dragLimit.bottom+window.pageYOffset0?S-(S-this.dragLimit.bottom)+window.pageYOffset-w:S<0?this.dragLimit.top:S}}else r=y,s=S;var A,x,C=f+this.borderWidth.top,D=u+this.borderWidth.left;if(this.dragProcessStarted&&(m(s)&&(s=this.prevTop),m(r)&&(r=this.prevLeft)),this.helperElement.classList.contains("e-treeview"))this.dragArea?(this.dragLimit.top=this.clone?this.dragLimit.top:0,A=s-C<0?this.dragLimit.top:s-this.borderWidth.top,x=r-D<0?this.dragLimit.left:r-this.borderWidth.left):(A=s-this.borderWidth.top,x=r-this.borderWidth.left);else if(this.dragArea){var P=this.helperElement.classList.contains("e-dialog");this.dragLimit.top=this.clone?this.dragLimit.top:0,A=s-C<0?this.dragLimit.top:s-C,x=r-D<0?P?r-(D-this.borderWidth.left):this.dragElePosition.left:r-D}else A=s-C,x=r-D;var L=parseFloat(getComputedStyle(this.element).marginTop);if(L>0&&(this.clone&&(A+=L,S<0&&(L+S>=0?A=L+S:A-=L),this.dragArea&&(A=this.dragLimit.bottom=0){var O=this.dragLimit.top+S-C;O+L+C<0?A-=L+C:A=O}else A-=L+C;this.dragArea&&this.helperElement.classList.contains("e-treeview")&&(A=A+(w=d.offsetHeight+(parseFloat(b.marginTop)+parseFloat(b.marginBottom)))>this.dragLimit.bottom?this.dragLimit.bottom-w:A),this.enableScrollHandler&&!this.clone&&(A-=this.parentScrollY,x-=this.parentScrollX),this.dragArea&&"string"!=typeof this.dragArea&&this.dragArea.classList.contains("e-kanban-content")&&"relative"===this.dragArea.style.position&&(A+=this.dragArea.scrollTop);var N=this.getProcessedPositionValue({top:A+"px",left:x+"px"});this.isPreventScroll&&(N=this.getProcessedPositionValue({top:this.position.top-this.parentClientRect.top-2+"px",left:this.position.left-this.parentClientRect.left-2+"px"})),je(d,this.getDragPosition(N)),!this.elementInViewport(d)&&this.enableAutoScroll&&!this.helperElement.classList.contains("e-treeview")&&this.helperElement.scrollIntoView();var T=document.querySelectorAll(":hover");if(this.enableAutoScroll&&this.helperElement.classList.contains("e-treeview")){0===T.length&&(T=this.getPathElements(i));var z=this.getScrollParent(T,!1);this.elementInViewport(this.helperElement)?this.getScrollPosition(z,A):this.elementInViewport(this.helperElement)||(0===(T=[].slice.call(document.querySelectorAll(":hover"))).length&&(T=this.getPathElements(i)),z=this.getScrollParent(T,!0),this.getScrollPosition(z,A))}this.dragProcessStarted=!0,this.prevLeft=r,this.prevTop=s,this.position.left=r,this.position.top=s,this.pageX=g,this.pageY=v}},t.prototype.getScrollParent=function(i,r){for(var o,s=r?i.reverse():i,a=s.length-1;a>=0;a--)if(("auto"===(o=window.getComputedStyle(s[parseInt(a.toString(),10)])["overflow-y"])||"scroll"===o)&&s[parseInt(a.toString(),10)].scrollHeight>s[parseInt(a.toString(),10)].clientHeight)return s[parseInt(a.toString(),10)];if("visible"===(o=window.getComputedStyle(document.scrollingElement)["overflow-y"]))return document.scrollingElement.style.overflow="auto",document.scrollingElement},t.prototype.getScrollPosition=function(i,r){if(i&&i===document.scrollingElement)i.clientHeight+document.scrollingElement.scrollTop-this.helperElement.clientHeightr?i.scrollTop+=this.helperElement.clientHeight:i.scrollTop>r-this.helperElement.clientHeight&&(i.scrollTop-=this.helperElement.clientHeight);else if(i&&i!==document.scrollingElement){var s=document.scrollingElement.scrollTop,o=this.helperElement.clientHeight;i.clientHeight+i.getBoundingClientRect().top-o+sr-o-s&&(i.scrollTop-=this.helperElement.clientHeight)}},t.prototype.getPathElements=function(i){return document.elementsFromPoint(i.clientX>0?i.clientX:0,i.clientY>0?i.clientY:0)},t.prototype.triggerOutFunction=function(i,r){this.hoverObject.instance.intOut(i,r.target),this.hoverObject.instance.dragData[this.scope]=null,this.hoverObject=null},t.prototype.getDragPosition=function(i){var r=ze({},i);return this.axis&&("x"===this.axis?delete r.top:"y"===this.axis&&delete r.left),r},t.prototype.getDocumentWidthHeight=function(i){var r=document.body,s=document.documentElement;return Math.max(r["scroll"+i],s["scroll"+i],r["offset"+i],s["offset"+i],s["client"+i])},t.prototype.intDragStop=function(i){if(this.dragProcessStarted=!1,st(i.changedTouches)||1===i.changedTouches.length){if(-1!==["touchend","pointerup","mouseup"].indexOf(i.type)){if(this.dragStop){var s=this.getProperTargetElement(i);this.trigger("dragStop",{event:i,element:this.element,target:s,helper:this.helperElement})}this.intDestroy(i)}else this.element.setAttribute("aria-grabbed","false");var o=this.checkTargetElement(i);o.target&&o.instance&&(o.instance.dragStopCalled=!0,o.instance.dragData[this.scope]=this.droppables[this.scope],o.instance.intDrop(i,o.target)),this.setGlobalDroppables(!0),document.body.classList.remove("e-prevent-select")}},t.prototype.intDestroy=function(i){this.dragProcessStarted=!1,this.toggleEvents(),document.body.classList.remove("e-prevent-select"),this.element.setAttribute("aria-grabbed","false"),E.remove(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.intDragStart),E.remove(document,X.isSafari()?"touchend":X.touchEndEvent,this.intDragStop),E.remove(document,X.isSafari()?"touchend":X.touchEndEvent,this.intDestroy),E.remove(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.intDrag),this.isDragStarted()&&this.isDragStarted(!0)},t.prototype.onPropertyChanged=function(i,r){},t.prototype.getModuleName=function(){return"draggable"},t.prototype.isDragStarted=function(i){return i&&(bC.isDragged=!bC.isDragged),bC.isDragged},t.prototype.setDragArea=function(){var i,r,a,s=0,o=0;if(a="string"==typeof this.dragArea?_(this.dragArea):this.dragArea){var h=a.getBoundingClientRect();i=a.scrollWidth?a.scrollWidth:h.right-h.left,r=a.scrollHeight?this.dragArea&&!m(this.helperElement)&&this.helperElement.classList.contains("e-treeview")?a.clientHeight:a.scrollHeight:h.bottom-h.top;for(var c=["Top","Left","Bottom","Right"],d=getComputedStyle(a),u=0;u12;return M0(i.target,this.helperElement)||-1!==i.type.indexOf("touch")||a?(this.helperElement.style.pointerEvents="none",s=document.elementFromPoint(r.clientX,r.clientY),this.helperElement.style.pointerEvents=o):s=i.target,s},t.prototype.currentStateCheck=function(i,r){return m(this.currentStateTarget)||this.currentStateTarget===i?m(r)?i:r:this.currentStateTarget},t.prototype.getMousePosition=function(i,r){var a,l,s=void 0!==i.srcElement?i.srcElement:i.target,o=this.getCoordinates(i),h=m(s.offsetParent);if(r?(a=this.clone?o.pageX:o.pageX+(h?0:s.offsetParent.scrollLeft)-this.relativeXPosition,l=this.clone?o.pageY:o.pageY+(h?0:s.offsetParent.scrollTop)-this.relativeYPosition):(a=this.clone?o.pageX:o.pageX+window.pageXOffset-this.relativeXPosition,l=this.clone?o.pageY:o.pageY+window.pageYOffset-this.relativeYPosition),document.scrollingElement&&!r&&!this.clone){var c=document.scrollingElement;a=c.scrollWidth>0&&c.scrollWidth>c.clientWidth&&c.scrollLeft>0?a-c.scrollLeft:a,l=c.scrollHeight>0&&c.scrollHeight>c.clientHeight&&c.scrollTop>0?l-c.scrollTop:l}return{left:a-(this.margin.left+this.cursorAt.left),top:l-(this.margin.top+this.cursorAt.top)}},t.prototype.getCoordinates=function(i){return i.type.indexOf("touch")>-1?i.changedTouches[0]:i},t.prototype.getHelperElement=function(i){var r;return this.clone?this.helper?r=this.helper({sender:i,element:this.target}):(r=Si("div",{className:"e-drag-helper e-block-touch",innerHTML:"Draggable"}),document.body.appendChild(r)):r=this.element,r},t.prototype.setGlobalDroppables=function(i,r,s){this.droppables[this.scope]=i?null:{draggable:r,helper:s,draggedElement:this.element}},t.prototype.checkTargetElement=function(i){var r=this.getProperTargetElement(i),s=this.getDropInstance(r);if(!s&&r&&!m(r.parentNode)){var o=J(r.parentNode,".e-droppable")||r.parentElement;o&&(s=this.getDropInstance(o))}return{target:r,instance:s}},t.prototype.getDropInstance=function(i){var s,o=i&&i.ej2_instances;if(o)for(var a=0,l=o;a=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},lR=function(n){function t(e,i){var r=n.call(this,i,e)||this;return r.mouseOver=!1,r.dragData={},r.dragStopCalled=!1,r.bind(),r}return rZ(t,n),t.prototype.bind=function(){this.wireEvents()},t.prototype.wireEvents=function(){E.add(this.element,X.isSafari()?"touchend":X.touchEndEvent,this.intDrop,this)},t.prototype.onPropertyChanged=function(e,i){},t.prototype.getModuleName=function(){return"droppable"},t.prototype.intOver=function(e,i){this.mouseOver||(this.trigger("over",{event:e,target:i,dragData:this.dragData[this.scope]}),this.mouseOver=!0)},t.prototype.intOut=function(e,i){this.mouseOver&&(this.trigger("out",{evt:e,target:i}),this.mouseOver=!1)},t.prototype.intDrop=function(e,i){if(this.dragStopCalled){this.dragStopCalled=!1;var a,r=!0,s=this.dragData[this.scope],o=!!s&&s.helper&&Tr(s.helper);o&&(a=this.isDropArea(e,s.helper,i),this.accept&&(r=vC(s.helper,this.accept))),o&&this.drop&&a.canDrop&&r&&this.trigger("drop",{event:e,target:a.target,droppedElement:s.helper,dragData:s}),this.mouseOver=!1}},t.prototype.isDropArea=function(e,i,r){var s={canDrop:!0,target:r||e.target},o="touchend"===e.type;if(o||s.target===i){i.style.display="none";var a=o?e.changedTouches[0]:e,l=document.elementFromPoint(a.clientX,a.clientY);s.canDrop=!1,s.canDrop=M0(l,this.element),s.canDrop&&(s.target=l),i.style.display=""}return s},t.prototype.destroy=function(){E.remove(this.element,X.isSafari()?"touchend":X.touchEndEvent,this.intDrop),n.prototype.destroy.call(this)},af([I()],t.prototype,"accept",void 0),af([I("default")],t.prototype,"scope",void 0),af([H()],t.prototype,"drop",void 0),af([H()],t.prototype,"over",void 0),af([H()],t.prototype,"out",void 0),af([Ft],t)}(dh),uo=function(){function n(t,e,i){this.controlName=t,this.localeStrings=e,this.setLocale(i||"en-US")}return n.prototype.setLocale=function(t){var e=this.intGetControlConstant(n.locale,t);this.currentLocale=e||this.localeStrings},n.load=function(t){this.locale=ze(this.locale,t,{},!0)},n.prototype.getConstant=function(t){return m(this.currentLocale[""+t])?this.localeStrings[""+t]||"":this.currentLocale[""+t]},n.prototype.intGetControlConstant=function(t,e){return t[""+e]?t[""+e][this.controlName]:null},n.locale={},n}(),hR=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),fh=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},oZ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return hR(t,n),fh([I(50)],t.prototype,"swipeThresholdDistance",void 0),t}(Ee),aZ=/(Up|Down)/,Fs=function(n){function t(e,i){var r=n.call(this,i,e)||this;return r.touchAction=!0,r.tapCount=0,r.startEvent=function(s){if(!0===r.touchAction){var o=r.updateChangeTouches(s);void 0!==s.changedTouches&&(r.touchAction=!1),r.isTouchMoved=!1,r.movedDirection="",r.startPoint=r.lastMovedPoint={clientX:o.clientX,clientY:o.clientY},r.startEventData=o,r.hScrollLocked=r.vScrollLocked=!1,r.tStampStart=Date.now(),r.timeOutTapHold=setTimeout(function(){r.tapHoldEvent(s)},r.tapHoldThreshold),E.add(r.element,X.touchMoveEvent,r.moveEvent,r),E.add(r.element,X.touchEndEvent,r.endEvent,r),E.add(r.element,X.touchCancelEvent,r.cancelEvent,r)}},r.moveEvent=function(s){var o=r.updateChangeTouches(s);r.movedPoint=o,r.isTouchMoved=!(o.clientX===r.startPoint.clientX&&o.clientY===r.startPoint.clientY);var a={};r.isTouchMoved&&(clearTimeout(r.timeOutTapHold),r.calcScrollPoints(s),a=ze(a,{},{startEvents:r.startEventData,originalEvent:s,startX:r.startPoint.clientX,startY:r.startPoint.clientY,distanceX:r.distanceX,distanceY:r.distanceY,scrollDirection:r.scrollDirection,velocity:r.getVelocity(o)}),r.trigger("scroll",a),r.lastMovedPoint={clientX:o.clientX,clientY:o.clientY})},r.cancelEvent=function(s){clearTimeout(r.timeOutTapHold),clearTimeout(r.timeOutTap),r.tapCount=0,r.swipeFn(s),E.remove(r.element,X.touchCancelEvent,r.cancelEvent)},r.endEvent=function(s){r.swipeFn(s),r.isTouchMoved||"function"==typeof r.tap&&(r.trigger("tap",{originalEvent:s,tapCount:++r.tapCount}),r.timeOutTap=setTimeout(function(){r.tapCount=0},r.tapThreshold)),r.modeclear()},r.swipeFn=function(s){clearTimeout(r.timeOutTapHold),clearTimeout(r.timeOutTap);var o=r.updateChangeTouches(s),a=o.clientX-r.startPoint.clientX,l=o.clientY-r.startPoint.clientY;a=Math.floor(a<0?-1*a:a),l=Math.floor(l<0?-1*l:a),r.isTouchMoved=a>1||l>1,/Firefox/.test(X.userAgent)&&0===o.clientX&&0===o.clientY&&"mouseup"===s.type&&(r.isTouchMoved=!1),r.endPoint=o,r.calcPoints(s);var c={originalEvent:s,startEvents:r.startEventData,startX:r.startPoint.clientX,startY:r.startPoint.clientY,distanceX:r.distanceX,distanceY:r.distanceY,swipeDirection:r.movedDirection,velocity:r.getVelocity(o)};if(r.isTouchMoved){var d=r.swipeSettings.swipeThresholdDistance,u=ze(void 0,r.defaultArgs,c),f=!1,p=r.element,g=r.isScrollable(p),v=aZ.test(r.movedDirection);(dthis.distanceY?i.clientX>this.startPoint.clientX?"Right":"Left":i.clientYthis.distanceY||!0===this.hScrollLocked)&&!1===this.vScrollLocked?(this.scrollDirection=i.clientX>this.lastMovedPoint.clientX?"Right":"Left",this.hScrollLocked=!0):(this.scrollDirection=i.clientY=e[r[0]+s[0]]},t.prototype.updateChangeTouches=function(e){return e.changedTouches&&0!==e.changedTouches.length?e.changedTouches[0]:e},fh([H()],t.prototype,"tap",void 0),fh([H()],t.prototype,"tapHold",void 0),fh([H()],t.prototype,"swipe",void 0),fh([H()],t.prototype,"scroll",void 0),fh([I(350)],t.prototype,"tapThreshold",void 0),fh([I(750)],t.prototype,"tapHoldThreshold",void 0),fh([re({},oZ)],t.prototype,"swipeSettings",void 0),fh([Ft],t)}(dh),lZ=new RegExp("\\n|\\r|\\s\\s+","g"),hZ=new RegExp(/'|"/g),cZ=new RegExp("if ?\\("),dZ=new RegExp("else if ?\\("),cR=new RegExp("else"),uZ=new RegExp("for ?\\("),dR=new RegExp("(/if|/for)"),fZ=new RegExp("\\((.*)\\)",""),MC=new RegExp("^[0-9]+$","g"),pZ=new RegExp("[\\w\"'.\\s+]+","g"),gZ=new RegExp('"(.*?)"',"g"),vZ=new RegExp("[\\w\"'@#$.\\s-+]+","g"),uR=new RegExp("\\${([^}]*)}","g"),mZ=/^\..*/gm,wC=/\\/gi,yZ=/\\\\/gi,SZ=new RegExp("[\\w\"'@#$.\\s+]+","g"),IZ=/\window\./gm;function lf(n,t,e,i,r){return!t||MC.test(n)||-1!==i.indexOf(n.split(".")[0])||r||"true"===n||"false"===n?n:e+"."+n}function CC(n,t,e,i){return t&&!MC.test(n)&&-1===i.indexOf(n.split(".")[0])?e+'["'+n:n}function fR(n){return n.match(yZ)?n:n.replace(wC,"\\\\")}function pR(n,t,e,i){if(n=n.trim(),/\window\./gm.test(n))return n;var s=/'|"/gm;return/@|\$|#/gm.test(n)&&(n=CC(n,-1===e.indexOf(n),t,e)+'"]'),mZ.test(n)?function wZ(n,t,e,i){return!t||MC.test(n)||-1!==i.indexOf(n.split(".")[0])||/^\..*/gm.test(n)?n:e+"."+n}(n,!s.test(n)&&-1===e.indexOf(n),t,e):lf(n,!s.test(n)&&-1===e.indexOf(n),t,e,i)}var CZ=/^[\n\r.]+0&&t.forEach(function(e){he(e)})},n.removeJsEvents=function(){var t=this.wrapElement.querySelectorAll("["+vR.join("],[")+"]");t.length>0&&t.forEach(function(e){vR.forEach(function(i){e.hasAttribute(i)&&e.removeAttribute(i)})})},n.removeXssAttrs=function(){var t=this;this.removeAttrs.forEach(function(e,i){var r=t.wrapElement.querySelectorAll(e.selector);r.length>0&&r.forEach("a[href]"===e.selector?function(s){-1!==s.getAttribute(e.attribute).replace(/\t|\s|&/,"").indexOf("javascript:alert")&&s.removeAttribute(e.attribute)}:function(s){s.removeAttribute(e.attribute)})})},n}();function NZ(n){for(var t,e=n.childNodes,i=0;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Jo_RTL=(new Tg,"e-rtl"),ys=function(n){function t(e,i){return n.call(this,e,i)||this}return PZ(t,n),t.prototype.preRender=function(){},t.prototype.render=function(){this.initialize(),this.removeRippleEffect=function ms(n,t,e){var i=function G$(n){return{selector:n&&n.selector?n.selector:null,ignore:n&&n.ignore?n.ignore:null,rippleFlag:n&&n.rippleFlag,isCenterRipple:n&&n.isCenterRipple,duration:n&&n.duration?n.duration:350}}(t);return!1===i.rippleFlag||void 0===i.rippleFlag&&!Zo?function(){}:(n.setAttribute("data-ripple","true"),E.add(n,"mousedown",Zz,{parent:n,rippleOptions:i}),E.add(n,"mouseup",Jz,{parent:n,rippleOptions:i,done:e}),E.add(n,"mouseleave",sf,{parent:n,rippleOptions:i}),X.isPointer&&E.add(n,"transitionend",sf,{parent:n,rippleOptions:i}),function(){n.removeAttribute("data-ripple"),E.remove(n,"mousedown",Zz),E.remove(n,"mouseup",Jz),E.remove(n,"mouseleave",sf),E.remove(n,"transitionend",sf)})}(this.element,{selector:".e-btn"}),this.renderComplete()},t.prototype.initialize=function(){if(this.cssClass&&V([this.element],this.cssClass.replace(/\s+/g," ").trim().split(" ")),this.isPrimary&&this.element.classList.add("e-primary"),!ce()||ce()&&"progress-btn"!==this.getModuleName()){if(this.content){var e=this.enableHtmlSanitizer?Ai.sanitize(this.content):this.content;this.element.innerHTML=e}this.setIconCss()}this.enableRtl&&this.element.classList.add(Jo_RTL),this.disabled?this.controlStatus(this.disabled):this.wireEvents()},t.prototype.controlStatus=function(e){this.element.disabled=e},t.prototype.setIconCss=function(){if(this.iconCss){var e=this.createElement("span",{className:"e-btn-icon "+this.iconCss});this.element.textContent.trim()?(e.classList.add("e-icon-"+this.iconPosition.toLowerCase()),("Top"===this.iconPosition||"Bottom"===this.iconPosition)&&this.element.classList.add("e-"+this.iconPosition.toLowerCase()+"-icon-btn")):this.element.classList.add("e-icon-btn");var i=this.element.childNodes[0];!i||"Left"!==this.iconPosition&&"Top"!==this.iconPosition?this.element.appendChild(e):this.element.insertBefore(e,i)}},t.prototype.wireEvents=function(){this.isToggle&&E.add(this.element,"click",this.btnClickHandler,this)},t.prototype.unWireEvents=function(){this.isToggle&&E.remove(this.element,"click",this.btnClickHandler)},t.prototype.btnClickHandler=function(){this.element.classList.contains("e-active")?this.element.classList.remove("e-active"):this.element.classList.add("e-active")},t.prototype.destroy=function(){var e=["e-primary",Jo_RTL,"e-icon-btn","e-success","e-info","e-danger","e-warning","e-flat","e-outline","e-small","e-bigger","e-active","e-round","e-top-icon-btn","e-bottom-icon-btn"];this.cssClass&&(e=e.concat(this.cssClass.split(" "))),n.prototype.destroy.call(this),K([this.element],e),this.element.getAttribute("class")||this.element.removeAttribute("class"),this.disabled&&this.element.removeAttribute("disabled"),this.content&&(this.element.innerHTML=this.element.innerHTML.replace(this.content,""));var i=this.element.querySelector("span.e-btn-icon");i&&he(i),this.unWireEvents(),Zo&&this.removeRippleEffect()},t.prototype.getModuleName=function(){return"btn"},t.prototype.getPersistData=function(){return this.addOnPersist([])},t.Inject=function(){},t.prototype.onPropertyChanged=function(e,i){for(var r=this.element.querySelector("span.e-btn-icon"),s=0,o=Object.keys(e);s=ad.width?ad.width:0;return yl.right+QR()-n}function hE(){return H0()+yl.width/2}function cE(n,t,e,i){if(void 0===t&&(t=null),void 0===e&&(e={X:!1,Y:!1}),!e.Y&&!e.X)return{left:0,top:0};var r=n.getBoundingClientRect();if(po=t,oc=n.ownerDocument,i||(i=ns(n,"left","top")),e.X){var s=po?ZR():i4(),o=gE(),a=vE(),l=o-i.left,h=i.left+r.width-a;r.width>s?i.left=l>0&&h<=0?a-r.width:h>0&&l<=0?o:l>h?a-r.width:o:l>0?i.left+=l:h>0&&(i.left-=h)}if(e.Y){var c=po?JR():t4(),d=pE(),u=mE(),f=d-i.top,p=i.top+r.height-u;r.height>c?i.top=f>0&&p<=0?u-r.height:p>0&&f<=0?d:f>p?u-r.height:d:f>0?i.top+=f:p>0&&(i.top-=p)}return i}function ac(n,t,e,i){void 0===t&&(t=null);var r=ns(n,"left","top");e&&(r.left=e),i&&(r.top=i);var s=[];po=t,oc=n.ownerDocument;var o=n.getBoundingClientRect(),l=r.left,h=r.left+o.width,d=fE(r.top,r.top+o.height),u=XR(l,h);return d.topSide&&s.push("top"),u.rightSide&&s.push("right"),u.leftSide&&s.push("left"),d.bottomSide&&s.push("bottom"),s}function cJ(n,t,e,i,r,s,o,a,l){if(void 0===o&&(o=null),void 0===a&&(a={X:!0,Y:!0}),t&&n&&r&&s&&(a.X||a.Y)){var d,h={TL:null,TR:null,BL:null,BR:null},c={TL:null,TR:null,BL:null,BR:null};if("none"===window.getComputedStyle(n).display){var u=n.style.visibility;n.style.visibility="hidden",n.style.display="block",d=n.getBoundingClientRect(),n.style.removeProperty("display"),n.style.visibility=u}else d=n.getBoundingClientRect();var f={posX:r,posY:s,offsetX:e,offsetY:i,position:{left:0,top:0}};po=o,oc=t.ownerDocument,function uJ(n,t,e,i,r){e.position=ns(n,e.posX,e.posY,i,r),t.TL=ns(n,"left","top",i,r),t.TR=ns(n,"right","top",i,r),t.BR=ns(n,"left","bottom",i,r),t.BL=ns(n,"right","bottom",i,r)}(t,h,f,l,d),uE(c,f,d),a.X&&qR(t,c,h,f,d,!0),a.Y&&h.TL.top>-1&&$R(t,c,h,f,d,!0),function dJ(n,t,e){var i=0,r=0;if(null!=n.offsetParent&&("absolute"===getComputedStyle(n.offsetParent).position||"relative"===getComputedStyle(n.offsetParent).position)){var s=ns(n.offsetParent,"left","top",!1,e);i=s.left,r=s.top}var o=1,a=1,l=GR(n);if(l){var h=getComputedStyle(l).transform;if("none"!==h){var c=new DOMMatrix(h);o=c.a,a=c.d}if("none"!==getComputedStyle(l).zoom){var u=dE(document.body);o*=u,a*=u}}n.style.top=t.position.top/a+t.offsetY-r/a+"px",n.style.left=t.position.left/o+t.offsetX-i/o+"px"}(n,f,d)}}function dE(n){var t=getComputedStyle(n).zoom;return parseFloat(t)||1}function GR(n){for(;n;){var t=window.getComputedStyle(n).transform,e=dE(document.body);if(t&&"none"!==t||e&&1!==e)return n;if(n===document.body)return null;n=n.offsetParent||n.parentElement}return null}function uE(n,t,e){n.TL={top:t.position.top+t.offsetY,left:t.position.left+t.offsetX},n.TR={top:n.TL.top,left:n.TL.left+e.width},n.BL={top:n.TL.top+e.height,left:n.TL.left},n.BR={top:n.TL.top+e.height,left:n.TL.left+e.width}}function XR(n,t){var e=!1,i=!1;return n-F0()vE()&&(i=!0),{leftSide:e,rightSide:i}}function qR(n,t,e,i,r,s){var o=XR(t.TL.left,t.TR.left),a=fE(t.TL.top,t.BL.top);e.TL.left-F0()<=gE()&&(o.leftSide=!1),e.TR.left>vE()&&(o.rightSide=!1),(o.leftSide&&!o.rightSide||!o.leftSide&&o.rightSide)&&(i.posX="right"===i.posX?"left":"right",i.offsetX=i.offsetX+r.width,i.offsetX=-1*i.offsetX,i.position=ns(n,i.posX,i.posY,!1),uE(t,i,r),s&&qR(n,t,e,i,r,!1),!o.leftSide&&o.rightSide&&a.bottomSide&&(i.offsetX=0))}function $R(n,t,e,i,r,s){var o=fE(t.TL.top,t.BL.top);e.TL.top-B0()<=pE()&&(o.topSide=!1),e.BL.top>=mE()&&n.getBoundingClientRect().bottommE()&&(i=!0),{topSide:e,bottomSide:i}}function ZR(){return po.getBoundingClientRect().width}function JR(){return po.getBoundingClientRect().height}function KR(){return po.getBoundingClientRect().left}function e4(){return po.getBoundingClientRect().top}function pE(){return po?e4():0}function gE(){return po?KR():0}function vE(){return po?F0()+KR()+ZR():F0()+i4()}function mE(){return po?B0()+e4()+JR():B0()+t4()}function B0(){return oc.documentElement.scrollTop||oc.body.scrollTop}function F0(){return oc.documentElement.scrollLeft||oc.body.scrollLeft}function t4(){return window.innerHeight}function i4(){var n=window.innerWidth,t=document.documentElement.getBoundingClientRect();return n-(n-(m(document.documentElement)?0:t.width))}function r4(){po=null,oc=null}var n4=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),bn=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},s4=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return n4(t,n),bn([I("left")],t.prototype,"X",void 0),bn([I("top")],t.prototype,"Y",void 0),t}(Ee),qn_OPEN="e-popup-open",qn_CLOSE="e-popup-close",lc=function(n){function t(e,i){return n.call(this,i,e)||this}return n4(t,n),t.prototype.onPropertyChanged=function(e,i){for(var r=0,s=Object.keys(e);r0&&c.left>0&&c.right>0&&c.bottom>0}var s=i.getBoundingClientRect();return!(r.bottoms.bottom||r.right>s.right||r.leftr.top?this.element.style.top="0px":s.bottomr.left&&(this.element.style.left=parseInt(this.element.style.left,10)+(s.left-r.left)+"px"))}},t.prototype.checkCollision=function(){var e=this.collision.X,i=this.collision.Y;"none"===e&&"none"===i||("flip"===e&&"flip"===i?this.callFlip({X:!0,Y:!0}):"fit"===e&&"fit"===i?this.callFit({X:!0,Y:!0}):("flip"===e?this.callFlip({X:!0,Y:!1}):"flip"===i&&this.callFlip({Y:!0,X:!1}),"fit"===e?this.callFit({X:!0,Y:!1}):"fit"===i&&this.callFit({X:!1,Y:!0})))},t.prototype.show=function(e,i){var r=this;if(this.getRelateToElement().classList.contains("e-filemanager")&&(this.fmDialogContainer=this.element.getElementsByClassName("e-file-select-wrap")[0]),this.wireEvents(),!m(this.fmDialogContainer)&&X.isIos&&(this.fmDialogContainer.style.display="block"),1e3===this.zIndex||!m(i)){var o=m(i)?this.element:i;this.zIndex=hc(o),je(this.element,{zIndex:this.zIndex})}e=m(e)||"object"!=typeof e?this.showAnimation:e,("none"!==this.collision.X||"none"!==this.collision.Y)&&(K([this.element],qn_CLOSE),V([this.element],qn_OPEN),this.checkCollision(),K([this.element],qn_OPEN),V([this.element],qn_CLOSE)),m(e)?(K([this.element],qn_CLOSE),V([this.element],qn_OPEN),this.trigger("open")):(e.begin=function(){r.isDestroyed||(K([r.element],qn_CLOSE),V([r.element],qn_OPEN))},e.end=function(){r.isDestroyed||r.trigger("open")},new Hs(e).animate(this.element))},t.prototype.hide=function(e){var i=this;e=m(e)||"object"!=typeof e?this.hideAnimation:e,m(e)?(K([this.element],qn_OPEN),V([this.element],qn_CLOSE),this.trigger("close")):(e.end=function(){i.isDestroyed||(K([i.element],qn_OPEN),V([i.element],qn_CLOSE),i.trigger("close"))},new Hs(e).animate(this.element)),this.unwireEvents()},t.prototype.getScrollableParent=function(e){return this.checkFixedParent(e),function yE(n,t){for(var e=getComputedStyle(n),i=[],r=/(auto|scroll)/,s=n.parentElement;s&&"HTML"!==s.tagName;){var o=getComputedStyle(s);!("absolute"===e.position&&"static"===o.position)&&r.test(o.overflow+o.overflowY+o.overflowX)&&i.push(s),s=s.parentElement}return t||i.push(document),i}(e,this.fixedParent)},t.prototype.checkFixedParent=function(e){for(var i=e.parentElement;i&&"HTML"!==i.tagName;){var r=getComputedStyle(i);("fixed"===r.position||"sticky"===r.position)&&!m(this.element)&&this.element.offsetParent&&"BODY"===this.element.offsetParent.tagName&&"hidden"!==getComputedStyle(this.element.offsetParent).overflow&&(this.element.style.top=window.scrollY>parseInt(this.element.style.top,10)?Re(window.scrollY-parseInt(this.element.style.top,10)):Re(parseInt(this.element.style.top,10)-window.scrollY),this.element.style.position="fixed",this.fixedParent=!0),i=i.parentElement,!m(this.element)&&m(this.element.offsetParent)&&"fixed"===r.position&&"fixed"===this.element.style.position&&(this.fixedParent=!0)}},bn([I("auto")],t.prototype,"height",void 0),bn([I("auto")],t.prototype,"width",void 0),bn([I(null)],t.prototype,"content",void 0),bn([I("container")],t.prototype,"targetType",void 0),bn([I(null)],t.prototype,"viewPortElement",void 0),bn([I({X:"none",Y:"none"})],t.prototype,"collision",void 0),bn([I("")],t.prototype,"relateTo",void 0),bn([re({},s4)],t.prototype,"position",void 0),bn([I(0)],t.prototype,"offsetX",void 0),bn([I(0)],t.prototype,"offsetY",void 0),bn([I(1e3)],t.prototype,"zIndex",void 0),bn([I(!1)],t.prototype,"enableRtl",void 0),bn([I("reposition")],t.prototype,"actionOnScroll",void 0),bn([I(null)],t.prototype,"showAnimation",void 0),bn([I(null)],t.prototype,"hideAnimation",void 0),bn([H()],t.prototype,"open",void 0),bn([H()],t.prototype,"close",void 0),bn([H()],t.prototype,"targetExitViewport",void 0),bn([Ft],t)}(Ii);function hc(n){for(var t=n.parentElement,e=[];t&&"BODY"!==t.tagName;){var i=document.defaultView.getComputedStyle(t,null).getPropertyValue("z-index"),r=document.defaultView.getComputedStyle(t,null).getPropertyValue("position");"auto"!==i&&"static"!==r&&e.push(i),t=t.parentElement}for(var s=[],o=0;o2147483647?2147483647:c}var Ui,ka,hf,yh,ME,Sh,Zt,Ih,SE=["north-west","north","north-east","west","east","south-west","south","south-east"],jg="e-resize-handle",cc="e-focused-handle",fJ="e-dlg-resizable",o4=["e-restrict-left"],a4="e-resize-viewport",pJ=["north","west","east","south"],IE=0,bE=0,l4=0,h4=0,Vg=0,Wg=0,Yg=null,wE=null,CE=null,_0=!0,c4=0,EE=!0;function vJ(n){DE();var t=Si("span",{attrs:{unselectable:"on",contenteditable:"false"}});t.setAttribute("class","e-dialog-border-resize e-"+n),"south"===n&&(t.style.height="2px",t.style.width="100%",t.style.bottom="0px",t.style.left="0px"),"north"===n&&(t.style.height="2px",t.style.width="100%",t.style.top="0px",t.style.left="0px"),"east"===n&&(t.style.height="100%",t.style.width="2px",t.style.right="0px",t.style.top="0px"),"west"===n&&(t.style.height="100%",t.style.width="2px",t.style.left="0px",t.style.top="0px"),Ui.appendChild(t)}function d4(n){var t;return m(n)||(t="string"==typeof n?document.querySelector(n):n),t}function u4(n){for(var t=n||this,e=Ui.querySelectorAll("."+jg),i=0;i-1?"mouse":"touch"}function p4(n){if(n.preventDefault(),Ui=n.target.parentElement,DE(),Vg=n.pageX,Wg=n.pageY,n.target.classList.add(cc),m(Yg)||!0!==Yg(n,this)){this.targetEle&&Ui&&Ui.querySelector("."+fJ)&&(Zt="body"===this.target?null:this.targetEle,Sh=this.targetEle.clientWidth,yh=this.targetEle.clientHeight);var e=m(Zt)?document:Zt;E.add(e,"mousemove",Qg,this),E.add(document,"mouseup",U0,this);for(var i=0;i=0||s.top<0)&&(e=!0):e=!0;var a=bE+(r-Wg);a=a>hf?a:hf;var l=0;m(Zt)||(l=o.top);var h=m(Zt)?0:Zt.offsetHeight-Zt.clientHeight,c=s.top-l-h/2;if(c=c<0?0:c,s.top>0&&c+a>yh){if(e=!1,Ui.classList.contains(a4))return;Ui.style.height=yh-parseInt(c.toString(),10)+"px"}else{var d=0;if(e){s.top<0&&t+(s.height+s.top)>0&&a+(d=s.top)<=30&&(a=s.height-(s.height+s.top)+30),a+s.top>=yh&&(Ui.style.height=s.height+(t-(s.height+s.top))+"px");var u=m(Zt)?d:c;a>=hf&&a+u<=yh&&(Ui.style.height=a+"px")}}}function TE(n){var e,t=!1,i="mouse"===f4(n.type)?n.pageY:n.touches[0].pageY,r=dc(Ui),s=m(Zt)?0:Zt.offsetHeight-Zt.clientHeight;m(Zt)||(e=dc(Zt)),(!m(Zt)&&r.top-e.top>0||m(Zt)&&i>0||!m(Zt)&&Math.floor(r.top-e.top+r.height+(e.bottom-r.bottom))-s<=yh)&&(t=!0);var o=bE-(i-Wg);if(t&&o>=hf&&o<=yh){var a=0;m(Zt)||(a=e.top);var l=h4-a+(i-Wg);l=l>0?l:1,Ui.style.height=o+"px",Ui.style.top=l+"px"}}function AE(n){var i,t=document.documentElement.clientWidth,e=!1;m(Zt)||(i=dc(Zt));var r="mouse"===f4(n.type)?n.pageX:n.touches[0].pageX,s=dc(Ui),o=m(Zt)?0:Zt.offsetWidth-Zt.clientWidth,a=m(Zt)?0:i.left,l=m(Zt)?0:i.width;m(Ih)&&(m(Zt)?Ih=t:(Ih=s.left-a-o/2+s.width,Ih+=l-o-Ih)),(!m(Zt)&&Math.floor(s.left-i.left+s.width+(i.right-s.right))-o<=Sh||m(Zt)&&r>=0)&&(e=!0);var h=IE-(r-Vg);if(_0&&(h=h>Ih?Ih:h),e&&h>=ME&&h<=Sh){var c=0;m(Zt)||(c=i.left);var d=l4-c+(r-Vg);d=d>0?d:1,h!==c4&&EE&&(Ui.style.width=h+"px"),_0&&(Ui.style.left=d+"px",EE=1!==d)}c4=h}function LE(n){var i,t=document.documentElement.clientWidth,e=!1;m(Zt)||(i=dc(Zt));var s=(n.touches?n.changedTouches[0]:n).pageX,o=dc(Ui);(!m(Zt)&&(o.left-i.left+o.width<=Sh||o.right-i.left>=o.width)||m(Zt)&&t-s>0)&&(e=!0);var a=IE+(s-Vg),l=0;if(m(Zt)||(l=i.left),o.left-l+a>Sh){if(e=!1,Ui.classList.contains(a4))return;Ui.style.width=Sh-(o.left-l)+"px"}e&&a>=ME&&a<=Sh&&(Ui.style.width=a+"px")}function v4(){for(var n=Ui.querySelectorAll("."+jg),t=0;t=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},bJ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return NE(t,n),Jt([I(!0)],t.prototype,"isFlat",void 0),Jt([I()],t.prototype,"buttonModel",void 0),Jt([I("Button")],t.prototype,"type",void 0),Jt([H()],t.prototype,"click",void 0),t}(Ee),MJ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return NE(t,n),Jt([I("Fade")],t.prototype,"effect",void 0),Jt([I(400)],t.prototype,"duration",void 0),Jt([I(0)],t.prototype,"delay",void 0),t}(Ee),j0="e-dialog",OE="e-rtl",kE="e-dlg-header-content",m4="e-dlg-header",V0="e-footer-content",W0="e-dlg-modal",y4="e-icon-dlg-close",Pa="e-dlg-target",ea="e-scroll-disabled",S4="e-device",Y0="e-dlg-fullscreen",I4="e-dlg-closeicon-btn",b4="e-popup-open",M4="Information",w4="e-scroll-disabled",C4="e-alert-dialog",E4="e-confirm-dialog",PE="e-dlg-resizable",cf="e-restrict-left",D4="e-resize-viewport",zE="user action",zJ=function(n){function t(e,i){var r=n.call(this,e,i)||this;return r.needsID=!0,r}return NE(t,n),t.prototype.render=function(){this.initialize(),this.initRender(),this.wireEvents(),"100%"===this.width&&(this.element.style.width=""),""!==this.minHeight&&(this.element.style.minHeight=Re(this.minHeight)),this.enableResize&&(this.setResize(),this.isModal&&(this.isModelResize=!0),"None"===this.animationSettings.effect&&this.getMinHeight()),this.renderComplete()},t.prototype.initializeValue=function(){this.dlgClosedBy=zE},t.prototype.preRender=function(){var e=this;if(this.initializeValue(),this.headerContent=null,this.allowMaxHeight=!0,this.preventVisibility=!0,this.clonedEle=this.element.cloneNode(!0),this.closeIconClickEventHandler=function(s){e.dlgClosedBy="close icon",e.hide(s)},this.dlgOverlayClickEventHandler=function(s){e.dlgClosedBy="overlayClick",s.preventFocus=!1,e.trigger("overlayClick",s,function(o){o.preventFocus||e.focusContent(),e.dlgClosedBy=zE})},this.l10n=new uo("dialog",{close:"Close"},this.locale),this.checkPositionData(),m(this.target)){var r=this.isProtectedOnChange;this.isProtectedOnChange=!0,this.target=document.body,this.isProtectedOnChange=r}},t.prototype.updatePersistData=function(){this.enablePersistence&&this.setProperties({width:parseFloat(this.element.style.width),height:parseFloat(this.element.style.height),position:{X:parseFloat(this.dragObj.element.style.left),Y:parseFloat(this.dragObj.element.style.top)}},!0)},t.prototype.isNumberValue=function(e){return/^[-+]?\d*\.?\d+$/.test(e)},t.prototype.checkPositionData=function(){if(!m(this.position)){if(!m(this.position.X)&&"number"!=typeof this.position.X&&this.isNumberValue(this.position.X)){var i=this.isProtectedOnChange;this.isProtectedOnChange=!0,this.position.X=parseFloat(this.position.X),this.isProtectedOnChange=i}m(this.position.Y)||"number"==typeof this.position.Y||this.isNumberValue(this.position.Y)&&(i=this.isProtectedOnChange,this.isProtectedOnChange=!0,this.position.Y=parseFloat(this.position.Y),this.isProtectedOnChange=i)}},t.prototype.getEle=function(e,i){for(var r=void 0,s=0;s=0&&t[e])vJ(t[e]);else if(""!==t[e].trim()){var i=Si("div",{className:"e-icons "+jg+" e-"+t[e]});Ui.appendChild(i)}hf=n.minHeight,ME=n.minWidth,Sh=n.maxWidth,yh=n.maxHeight,n.proxy&&n.proxy.element&&n.proxy.element.classList.contains("e-dialog")?u4(n.proxy):u4()}({element:this.element,direction:r,minHeight:parseInt(e.slice(0,i.indexOf("p")),10),maxHeight:this.targetEle.clientHeight,minWidth:parseInt(i.slice(0,i.indexOf("p")),10),maxWidth:this.targetEle.clientWidth,boundary:this.target===document.body?null:this.targetEle,resizeBegin:this.onResizeStart.bind(this),resizeComplete:this.onResizeComplete.bind(this),resizing:this.onResizing.bind(this),proxy:this}),this.wireWindowResizeEvent()}else v4(),this.unWireWindowResizeEvent(),this.element.classList.remove(this.isModal?cf:D4),this.element.classList.remove(PE)},t.prototype.getFocusElement=function(e){var r=e.querySelectorAll('input,select,textarea,button:enabled,a,[contenteditable="true"],[tabindex]');return{element:r[r.length-1]}},t.prototype.keyDown=function(e){var i=this;if(9===e.keyCode&&this.isModal){var r=void 0;m(this.btnObj)||(r=this.btnObj[this.btnObj.length-1]),m(this.btnObj)&&!m(this.ftrTemplateContent)&&(r=this.getFocusElement(this.ftrTemplateContent)),m(this.btnObj)&&m(this.ftrTemplateContent)&&!m(this.contentEle)&&(r=this.getFocusElement(this.contentEle)),!m(r)&&document.activeElement===r.element&&!e.shiftKey&&(e.preventDefault(),this.focusableElements(this.element).focus()),document.activeElement===this.focusableElements(this.element)&&e.shiftKey&&(e.preventDefault(),m(r)||r.element.focus())}var h,s=document.activeElement,o=["input","textarea"].indexOf(s.tagName.toLowerCase())>-1,a=!1;if(o||(a=s.hasAttribute("contenteditable")&&"true"===s.getAttribute("contenteditable")),27===e.keyCode&&this.closeOnEscape){this.dlgClosedBy="escape";var l=document.querySelector(".e-popup-open:not(.e-dialog)");!m(l)&&!l.classList.contains("e-toolbar-pop")&&!l.classList.contains("e-slider-tooltip")||this.hide(e)}(13===e.keyCode&&!e.ctrlKey&&"textarea"!==s.tagName.toLowerCase()&&o&&!m(this.primaryButtonEle)||13===e.keyCode&&e.ctrlKey&&("textarea"===s.tagName.toLowerCase()||a)&&!m(this.primaryButtonEle))&&this.buttons.some(function(d,u){h=u;var f=d.buttonModel;return!m(f)&&!0===f.isPrimary})&&"function"==typeof this.buttons[h].click&&setTimeout(function(){i.buttons[h].click.call(i,e)})},t.prototype.initialize=function(){m(this.target)||(this.targetEle="string"==typeof this.target?document.querySelector(this.target):this.target),this.isBlazorServerRender()||V([this.element],j0),X.isDevice&&V([this.element],S4),this.isBlazorServerRender()||this.setCSSClass(),this.setMaxHeight()},t.prototype.initRender=function(){var e=this;if(this.initialRender=!0,this.isBlazorServerRender()||Fe(this.element,{role:"dialog"}),1e3===this.zIndex?(this.setzIndex(this.element,!1),this.calculatezIndex=!0):this.calculatezIndex=!1,this.setTargetContent(),""!==this.header&&!m(this.header)&&this.setHeader(),this.renderCloseIcon(),this.setContent(),""===this.footerTemplate||m(this.footerTemplate)?!m(this.buttons[0])&&!m(this.buttons[0].buttonModel)&&this.setButton():this.setFooterTemplate(),this.allowDragging&&!m(this.headerContent)&&this.setAllowDragging(),Fe(this.element,{"aria-modal":this.isModal?"true":"false"}),this.isModal&&this.setIsModal(),!0!==this.element.classList.contains(C4)&&!0!==this.element.classList.contains(E4)&&!m(this.element.parentElement)){var i=this.isModal?this.dlgContainer.parentElement:this.element.parentElement;this.refElement=this.createElement("div",{className:"e-dlg-ref-element"}),i.insertBefore(this.refElement,this.isModal?this.dlgContainer:this.element)}if(m(this.targetEle)||this.targetEle.appendChild(this.isModal?this.dlgContainer:this.element),this.popupObj=new lc(this.element,{height:this.height,width:this.width,zIndex:this.zIndex,relateTo:this.target,actionOnScroll:"none",enableRtl:this.enableRtl,open:function(o){var a={container:e.isModal?e.dlgContainer:e.element,element:e.element,target:e.target,preventFocus:!1};e.enableResize&&e.resetResizeIcon(),e.trigger("open",a,function(l){l.preventFocus||e.focusContent()})},close:function(o){e.isModal&&V([e.dlgOverlay],"e-fade"),e.unBindEvent(e.element),e.isModal&&(e.dlgContainer.style.display="none"),e.trigger("close",e.closeArgs);var a=document.activeElement;!m(a)&&!m(a.blur)&&a.blur(),!m(e.storeActiveElement)&&!m(e.storeActiveElement.focus)&&e.storeActiveElement.focus()}}),this.positionChange(),this.setEnableRTL(),this.isBlazorServerRender()||(V([this.element],"e-popup-close"),this.isModal&&this.setOverlayZindex()),this.visible){if(this.show(),this.isModal){var r=this.getTargetContainer(this.target);r instanceof Element&&"rtl"===window.getComputedStyle(r).getPropertyValue("direction")&&this.setPopupPosition()}}else this.isModal&&(this.dlgOverlay.style.display="none");this.initialRender=!1},t.prototype.getTargetContainer=function(e){var i=null;if("string"==typeof e)if(e.startsWith("#"))i=document.getElementById(e.substring(1));else if(e.startsWith(".")){var r=document.getElementsByClassName(e.substring(1));i=r.length>0?r[0]:null}else!(e instanceof HTMLElement)&&e!==document.body&&(i=document.querySelector(e));else e instanceof HTMLElement&&(i=e);return i},t.prototype.resetResizeIcon=function(){var e=this.getMinHeight();if(this.targetEle.offsetHeight0&&("function"==typeof this.buttons[e].click&&E.add(s[e],"click",this.buttons[e].click,this),"object"==typeof this.buttons[e].click&&E.add(s[e],"click",this.buttonClickHandler.bind(this,e),this)),!this.isBlazorServerRender()&&!m(this.ftrTemplateContent)&&(this.btnObj[e].appendTo(this.ftrTemplateContent.children[e]),this.buttons[e].isFlat&&this.btnObj[e].element.classList.add("e-flat"),this.primaryButtonEle=this.element.getElementsByClassName("e-primary")[0]))},t.prototype.buttonClickHandler=function(e){this.trigger("buttons["+e+"].click",{})},t.prototype.setContent=function(){this.contentEle=this.createElement("div",{className:"e-dlg-content",id:this.element.id+"_dialog-content"}),Fe(this.element,this.headerEle?{"aria-describedby":this.element.id+"_title "+this.element.id+"_dialog-content"}:{"aria-describedby":this.element.id+"_dialog-content"}),this.innerContentElement?this.contentEle.appendChild(this.innerContentElement):(!m(this.content)&&""!==this.content||!this.initialRender)&&(("string"!=typeof this.content||ce())&&this.content instanceof HTMLElement?this.contentEle.appendChild(this.content):this.setTemplate(this.content,this.contentEle,"content")),m(this.headerContent)?this.element.insertBefore(this.contentEle,this.element.children[0]):this.element.insertBefore(this.contentEle,this.element.children[1]),"auto"===this.height&&(!this.isBlazorServerRender()&&X.isIE&&""===this.element.style.width&&!m(this.width)&&(this.element.style.width=Re(this.width)),this.setMaxHeight())},t.prototype.setTemplate=function(e,i,r){var s,o,a;o=i.classList.contains(m4)?this.element.id+"header":i.classList.contains(V0)?this.element.id+"footerTemplate":this.element.id+"content",m(e.outerHTML)?("string"==typeof e||"string"!=typeof e||ce()&&!this.isStringTemplate)&&("string"==typeof e&&(e=this.sanitizeHelper(e)),this.isVue||"string"!=typeof e?(s=oi(e),a=e):i.innerHTML=e):i.appendChild(e);var l=[];if(!m(s)){for(var c=0,d=s({},this,r,o,!(ce()&&!this.isStringTemplate&&0===a.indexOf("
Blazor"))||this.isStringTemplate);c/g,"");(this.element.children.length>0||i)&&(this.innerContentElement=document.createDocumentFragment(),[].slice.call(this.element.childNodes).forEach(function(r){8!==r.nodeType&&e.innerContentElement.appendChild(r)}))}},t.prototype.setHeader=function(){this.headerEle?this.headerEle.innerHTML="":this.headerEle=this.createElement("div",{id:this.element.id+"_title",className:m4}),this.createHeaderContent(),this.headerContent.appendChild(this.headerEle),this.setTemplate(this.header,this.headerEle,"header"),Fe(this.element,{"aria-describedby":this.element.id+"_title"}),Fe(this.element,{"aria-labelledby":this.element.id+"_dialog-header"}),this.element.insertBefore(this.headerContent,this.element.children[0]),this.allowDragging&&!m(this.headerContent)&&this.setAllowDragging()},t.prototype.setFooterTemplate=function(){this.ftrTemplateContent?this.ftrTemplateContent.innerHTML="":this.ftrTemplateContent=this.createElement("div",{className:V0}),""===this.footerTemplate||m(this.footerTemplate)?this.ftrTemplateContent.innerHTML=this.buttonContent.join(""):this.setTemplate(this.footerTemplate,this.ftrTemplateContent,"footerTemplate"),this.element.appendChild(this.ftrTemplateContent)},t.prototype.createHeaderContent=function(){m(this.headerContent)&&(this.headerContent=this.createElement("div",{id:this.element.id+"_dialog-header",className:kE}))},t.prototype.renderCloseIcon=function(){this.showCloseIcon&&(this.closeIcon=this.createElement("button",{className:I4,attrs:{type:"button"}}),this.closeIconBtnObj=new ys({cssClass:"e-flat",iconCss:y4+" e-icons"}),this.closeIconTitle(),m(this.headerContent)?(this.createHeaderContent(),gl([this.closeIcon],this.headerContent),this.element.insertBefore(this.headerContent,this.element.children[0])):gl([this.closeIcon],this.headerContent),this.closeIconBtnObj.appendTo(this.closeIcon))},t.prototype.closeIconTitle=function(){this.l10n.setLocale(this.locale);var e=this.l10n.getConstant("close");this.closeIcon.setAttribute("title",e),this.closeIcon.setAttribute("aria-label",e)},t.prototype.setCSSClass=function(e){e&&(K([this.element],e.split(" ")),this.isModal&&!m(this.dlgContainer)&&K([this.dlgContainer],e.split(" "))),this.cssClass&&(V([this.element],this.cssClass.split(" ")),this.isModal&&!m(this.dlgContainer)&&V([this.dlgContainer],this.cssClass.split(" ")))},t.prototype.setIsModal=function(){this.dlgContainer=this.createElement("div",{className:"e-dlg-container"}),this.setCSSClass(),this.element.classList.remove(b4),this.element.parentNode.insertBefore(this.dlgContainer,this.element),this.dlgContainer.appendChild(this.element),V([this.element],W0),this.dlgOverlay=this.createElement("div",{className:"e-dlg-overlay"}),this.dlgOverlay.style.zIndex=(this.zIndex-1).toString(),this.dlgContainer.appendChild(this.dlgOverlay)},t.prototype.getValidFocusNode=function(e){for(var i,r=0;r0||"a"===i.tagName.toLowerCase()&&i.hasAttribute("href"))&&i.tabIndex>-1&&!i.disabled&&!this.disableElement(i,'[disabled],[aria-disabled="true"],[type="hidden"]'))return i;i=null}return i},t.prototype.focusableElements=function(e){if(!m(e)){var r=e.querySelectorAll('input,select,textarea,button,a,[contenteditable="true"],[tabindex]');return this.getValidFocusNode(r)}return null},t.prototype.getAutoFocusNode=function(e){var i=e.querySelector("."+I4),s=e.querySelectorAll("[autofocus]"),o=this.getValidFocusNode(s);if(ce()&&(this.primaryButtonEle=this.element.getElementsByClassName("e-primary")[0]),m(o)){if(!m(o=this.focusableElements(this.contentEle)))return o;if(!m(this.primaryButtonEle))return this.element.querySelector(".e-primary")}else i=o;return i},t.prototype.disableElement=function(e,i){var r=e?e.matches||e.webkitMatchesSelector||e.msGetRegionContent:null;if(r)for(;e;e=e.parentNode)if(e instanceof Element&&r.call(e,i))return e;return null},t.prototype.focusContent=function(){var e=this.getAutoFocusNode(this.element),i=m(e)?this.element:e,r=X.userAgent;(r.indexOf("MSIE ")>0||r.indexOf("Trident/")>0)&&this.element.focus(),i.focus(),this.unBindEvent(this.element),this.bindEvent(this.element)},t.prototype.bindEvent=function(e){E.add(e,"keydown",this.keyDown,this)},t.prototype.unBindEvent=function(e){E.remove(e,"keydown",this.keyDown)},t.prototype.updateSanitizeContent=function(){this.isBlazorServerRender()||(this.contentEle.innerHTML=this.sanitizeHelper(this.content))},t.prototype.isBlazorServerRender=function(){return ce()&&this.isServerRendered},t.prototype.getModuleName=function(){return"dialog"},t.prototype.onPropertyChanged=function(e,i){if(this.element.classList.contains(j0))for(var r=0,s=Object.keys(e);r0?this.showCloseIcon||""!==this.header&&!m(this.header)?this.showCloseIcon||he(this.closeIcon):(he(this.headerContent),this.headerContent=null):(this.renderCloseIcon(),this.wireEvents());break;case"locale":this.showCloseIcon&&this.closeIconTitle();break;case"visible":this.visible?this.show():this.hide();break;case"isModal":this.updateIsModal();break;case"height":je(this.element,{height:Re(e.height)}),this.updatePersistData();break;case"width":je(this.element,{width:Re(e.width)}),this.updatePersistData();break;case"zIndex":this.popupObj.zIndex=this.zIndex,this.isModal&&this.setOverlayZindex(this.zIndex),this.element.style.zIndex!==this.zIndex.toString()&&(this.calculatezIndex=!1);break;case"cssClass":this.setCSSClass(i.cssClass);break;case"buttons":this.unWireButtonEvents(),this.destroyButtons(),m(this.ftrTemplateContent)||(he(this.ftrTemplateContent),this.ftrTemplateContent=null),this.footerTemplate="",this.setButton();break;case"allowDragging":this.allowDragging&&!m(this.headerContent)?this.setAllowDragging():this.dragObj.destroy();break;case"target":this.setTarget(e.target);break;case"position":if(this.checkPositionData(),this.isModal){var a=this.position.X,l=this.position.Y;m(i.position)||(m(i.position.X)||(a=i.position.X),m(i.position.Y)||(l=i.position.Y)),this.dlgContainer.classList.contains("e-dlg-"+a+"-"+l)&&this.dlgContainer.classList.remove("e-dlg-"+a+"-"+l)}this.positionChange(),this.updatePersistData();break;case"enableRtl":this.setEnableRTL();break;case"enableResize":this.setResize(),this.isModelResize=this.enableResize&&this.isModal,this.enableResize&&this.dialogOpen&&this.resetResizeIcon();break;case"minHeight":""!==this.minHeight&&(this.element.style.minHeight=Re(this.minHeight))}},t.prototype.setTarget=function(e){this.popupObj.relateTo=e,this.target=e,this.targetEle="string"==typeof this.target?document.querySelector(this.target):this.target,this.dragObj&&(this.dragObj.dragArea=this.targetEle),this.setMaxHeight(),this.isModal&&this.updateIsModal(),this.enableResize&&this.setResize(),m(this.targetEle)||(this.isModal&&!m(this.dlgContainer)?this.targetEle.appendChild(this.dlgContainer):m(this.element)||this.targetEle.appendChild(this.element))},t.prototype.updateIsModal=function(){if(this.element.setAttribute("aria-modal",this.isModal?"true":"false"),this.isModal)m(this.dlgOverlay)&&(this.setIsModal(),this.element.style.top="0px",this.element.style.left="0px",m(this.targetEle)||this.targetEle.appendChild(this.dlgContainer));else{for(K([this.element],W0),K([document.body],[Pa,ea]),he(this.dlgOverlay);this.dlgContainer.firstChild;)this.dlgContainer.parentElement.insertBefore(this.dlgContainer.firstChild,this.dlgContainer);this.dlgContainer.parentElement.removeChild(this.dlgContainer)}this.visible&&this.show(),this.positionChange(),this.isModal&&this.dlgOverlay&&E.add(this.dlgOverlay,"click",this.dlgOverlayClickEventHandler,this)},t.prototype.setzIndex=function(e,i){var r=this.isProtectedOnChange;this.isProtectedOnChange=!0;var s=hc(e);this.zIndex=s>this.zIndex?s:this.zIndex,this.isProtectedOnChange=r,i&&(this.popupObj.zIndex=this.zIndex)},t.prototype.windowResizeHandler=function(){(function yJ(n){Sh=n})(this.targetEle.clientWidth),function SJ(n){yh=n}(this.targetEle.clientHeight),this.setMaxHeight()},t.prototype.getPersistData=function(){return this.addOnPersist(["width","height","position"])},t.prototype.removeAllChildren=function(e){for(;e.children[0];)this.removeAllChildren(e.children[0]),e.removeChild(e.children[0])},t.prototype.destroy=function(){if(!this.isDestroyed){var e=[OE,W0,PE,cf,Y0,S4],i=["role","aria-modal","aria-labelledby","aria-describedby","aria-grabbed","tabindex","style"];K([this.targetEle],[Pa,ea]),!m(this.element)&&this.element.classList.contains(Y0)&&K([document.body],[Pa,ea]),this.isModal&&K([m(this.targetEle)?document.body:this.targetEle],ea),this.unWireEvents(),this.unWireButtonEvents(),this.destroyButtons(),m(this.closeIconBtnObj)||this.closeIconBtnObj.destroy(),m(this.dragObj)||this.dragObj.destroy(),!m(this.popupObj.element)&&this.popupObj.element.classList.contains("e-popup")&&this.popupObj.destroy(),K([this.element],e),!m(this.cssClass)&&""!==this.cssClass&&K([this.element],this.cssClass.split(" ")),!m(this.refElement)&&!m(this.refElement.parentElement)&&(this.refElement.parentElement.insertBefore(this.isModal?this.dlgContainer:this.element,this.refElement),he(this.refElement),this.refElement=void 0),this.isModal&&(he(this.dlgOverlay),this.dlgContainer.parentNode.insertBefore(this.element,this.dlgContainer),he(this.dlgContainer)),this.element.innerHTML=this.clonedEle.innerHTML;for(var r=0;r0&&""===this.footerTemplate&&this.ftrTemplateContent)for(var e=0;e=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},RE="e-tooltip",O4="e-icons",k4="e-tooltip-close",HE="e-tooltip-wrap",P4="e-tip-content",df="e-arrow-tip",z4="e-arrow-tip-outer",Q0="e-arrow-tip-inner",Gg="e-tip-bottom",BE="e-tip-top",R4="e-tip-left",FE="e-tip-right",_E="e-popup",Xg="e-popup-open",UE="e-popup-close",G0="e-lib",H4="e-tooltip-popup-container",UJ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return T4(t,n),Gi([I({effect:"FadeIn",duration:150,delay:0})],t.prototype,"open",void 0),Gi([I({effect:"FadeOut",duration:150,delay:0})],t.prototype,"close",void 0),t}(Ee),bh=function(n){function t(e,i){var r=n.call(this,e,i)||this;return r.mouseMoveEvent=null,r.mouseMoveTarget=null,r.containerElement=null,r.isBodyContainer=!0,r}return T4(t,n),t.prototype.initialize=function(){this.formatPosition(),V([this.element],RE)},t.prototype.formatPosition=function(){var e,i;this.position&&(0===this.position.indexOf("Top")||0===this.position.indexOf("Bottom")?(e=this.position.split(/(?=[A-Z])/),this.tooltipPositionY=e[0],this.tooltipPositionX=e[1]):(i=this.position.split(/(?=[A-Z])/),this.tooltipPositionX=i[0],this.tooltipPositionY=i[1]))},t.prototype.renderArrow=function(){this.setTipClass(this.position);var e=this.createElement("div",{className:df+" "+this.tipClass});e.appendChild(this.createElement("div",{className:z4+" "+this.tipClass})),e.appendChild(this.createElement("div",{className:Q0+" "+this.tipClass})),this.tooltipEle.appendChild(e)},t.prototype.setTipClass=function(e){this.tipClass=0===e.indexOf("Right")?R4:0===e.indexOf("Bottom")?BE:0===e.indexOf("Left")?FE:Gg},t.prototype.renderPopup=function(e){var i=this.mouseTrail?{top:0,left:0}:this.getTooltipPosition(e);this.tooltipEle.classList.remove(G0),this.popupObj=new lc(this.tooltipEle,{height:this.height,width:this.width,position:{X:i.left,Y:i.top},enableRtl:this.enableRtl,open:this.openPopupHandler.bind(this),close:this.closePopupHandler.bind(this)})},t.prototype.getScalingFactor=function(e){if(!e)return{x:1,y:1};var i={x:1,y:1},r=e.closest('[style*="transform: scale"]');if(r&&r!==this.tooltipEle&&r.contains(this.tooltipEle)){var a=window.getComputedStyle(r).getPropertyValue("transform").match(/matrix\(([^)]+)\)/)[1].split(",").map(parseFloat);i.x=a[0],i.y=a[3]}return i},t.prototype.getTooltipPosition=function(e){this.tooltipEle.style.display="block";var i=this.element.closest('[style*="zoom"]');i&&(i.contains(this.tooltipEle)||(this.tooltipEle.style.zoom=getComputedStyle(i).zoom));var r=ns(e,this.tooltipPositionX,this.tooltipPositionY,!this.isBodyContainer,this.isBodyContainer?null:this.containerElement.getBoundingClientRect()),s=this.getScalingFactor(e),o=this.calculateTooltipOffset(this.position,s.x,s.y),a=this.calculateElementPosition(r,o),c=this.collisionFlipFit(e,a[0],a[1]);return c.left=c.left/s.x,c.top=c.top/s.y,this.tooltipEle.style.display="",c},t.prototype.windowResize=function(){this.reposition(this.findTarget())},t.prototype.reposition=function(e){if(this.popupObj&&e){var i=this.getTooltipPosition(e);this.popupObj.position={X:i.left,Y:i.top},this.popupObj.dataBind()}},t.prototype.openPopupHandler=function(){!this.mouseTrail&&this.needTemplateReposition()&&this.reposition(this.findTarget()),this.trigger("afterOpen",this.tooltipEventArgs),this.tooltipEventArgs=null},t.prototype.closePopupHandler=function(){this.isReact&&!("Click"===this.opensOn||"function"==typeof this.content)&&this.clearTemplate(["content"]),this.clear();var e={type:this.tooltipEventArgs.event?this.tooltipEventArgs.event.type:null,cancel:!1,target:this.tooltipEventArgs.target,event:this.tooltipEventArgs.event?this.tooltipEventArgs.event:null,element:this.tooltipEle,isInteracted:!m(this.tooltipEventArgs.event)};this.trigger("afterClose",e),e=null},t.prototype.calculateTooltipOffset=function(e,i,r){void 0===i&&(i=1),void 0===r&&(r=1);var o,a,l,h,c,d,u,f,s={top:0,left:0};if(1!==i||1!==r){var p=this.tooltipEle.getBoundingClientRect(),g=void 0;l=Math.round(p.width),h=Math.round(p.height),(c=_("."+df,this.tooltipEle))&&(g=c.getBoundingClientRect()),o=c?Math.round(g.width):0,a=c?Math.round(g.height):0,d=this.showTipPointer?0:8,u=a/2+2+(h-this.tooltipEle.clientHeight*r),f=o/2+2+(l-this.tooltipEle.clientWidth*i)}else l=this.tooltipEle.offsetWidth,h=this.tooltipEle.offsetHeight,c=_("."+df,this.tooltipEle),d=this.showTipPointer?0:8,u=(a=c?c.offsetHeight:0)/2+2+(this.tooltipEle.offsetHeight-this.tooltipEle.clientHeight),f=(o=c?c.offsetWidth:0)/2+2+(this.tooltipEle.offsetWidth-this.tooltipEle.clientWidth);switch(this.mouseTrail&&(d+=2),e){case"RightTop":s.left+=o+d,s.top-=h-u;break;case"RightCenter":s.left+=o+d,s.top-=h/2;break;case"RightBottom":s.left+=o+d,s.top-=u;break;case"BottomRight":s.top+=a+d,s.left-=f;break;case"BottomCenter":s.top+=a+d,s.left-=l/2;break;case"BottomLeft":s.top+=a+d,s.left-=l-f;break;case"LeftBottom":s.left-=o+l+d,s.top-=u;break;case"LeftCenter":s.left-=o+l+d,s.top-=h/2;break;case"LeftTop":s.left-=o+l+d,s.top-=h-u;break;case"TopLeft":s.top-=h+a+d,s.left-=l-f;break;case"TopRight":s.top-=h+a+d,s.left-=f;break;default:s.top-=h+a+d,s.left-=l/2}return s.left+=this.offsetX,s.top+=this.offsetY,s},t.prototype.updateTipPosition=function(e){var i=we("."+df+",."+z4+",."+Q0,this.tooltipEle);K(i,[Gg,BE,R4,FE]),this.setTipClass(e),V(i,this.tipClass)},t.prototype.adjustArrow=function(e,i,r,s){var o=_("."+df,this.tooltipEle);if(!1!==this.showTipPointer&&null!==o){var a,l;this.updateTipPosition(i),this.tooltipEle.style.display="block";var p,h=this.tooltipEle.clientWidth,c=this.tooltipEle.clientHeight,d=_("."+Q0,this.tooltipEle),u=o.offsetWidth,f=o.offsetHeight;this.tooltipEle.style.display="",this.tipClass===Gg||this.tipClass===BE?(this.tipClass===Gg?(l="99.9%",d.style.top="-"+(f-2)+"px"):(l=-(f-1)+"px",d.style.top="-"+(f-6)+"px"),e&&(a=(p="Center"!==r||h>e.offsetWidth||this.mouseTrail)&&"Left"===r||!p&&"End"===this.tipPointerPosition?h-u-2+"px":p&&"Right"===r||!p&&"Start"===this.tipPointerPosition?"2px":!p||"End"!==this.tipPointerPosition&&"Start"!==this.tipPointerPosition?h/2-u/2+"px":"End"===this.tipPointerPosition?e.offsetWidth+(this.tooltipEle.offsetWidth-e.offsetWidth)/2-u/2-2+"px":(this.tooltipEle.offsetWidth-e.offsetWidth)/2-u/2+2+"px")):(this.tipClass===FE?(a="99.9%",d.style.left="-"+(u-2)+"px"):(a=-(u-1)+"px",d.style.left=u-2-u+"px"),l=(p="Center"!==s||c>e.offsetHeight||this.mouseTrail)&&"Top"===s||!p&&"End"===this.tipPointerPosition?c-f-2+"px":p&&"Bottom"===s||!p&&"Start"===this.tipPointerPosition?"2px":c/2-f/2+"px"),o.style.top=l,o.style.left=a}},t.prototype.renderContent=function(e){var i=this,r=_("."+P4,this.tooltipEle);if(this.cssClass&&V([this.tooltipEle],this.cssClass.split(" ")),e&&!m(e.getAttribute("title"))&&(e.setAttribute("data-content",e.getAttribute("title")),e.removeAttribute("title")),m(this.content))e&&!m(e.getAttribute("data-content"))&&(r.innerHTML=e.getAttribute("data-content"));else if(r.innerHTML="",this.content instanceof HTMLElement)r.appendChild(this.content);else if("string"==typeof this.content)this.isAngular?this.setProperties({content:Ai.sanitize(this.content)},!0):this.content=this.enableHtmlSanitizer?Ai.sanitize(this.content):this.content,this.enableHtmlParse?(o=oi(this.content)({},this,"content",this.element.id+"content",void 0,void 0,r,this.root))&&Dt(o,r):r.textContent=this.content;else{var o;(o=oi(this.content)({},this,"content",this.element.id+"content",void 0,void 0,r))&&(this.isAngular&&setTimeout(function(){i.reposition(e)},1),Dt(o,r)),this.renderReactTemplates()}},t.prototype.renderCloseIcon=function(){if(this.isSticky){var i=this.createElement("div",{className:O4+" "+k4});this.tooltipEle.appendChild(i),E.add(i,X.touchStartEvent,this.onStickyClose,this)}else{var e=this.tooltipEle.querySelector("."+O4+"."+k4);e&>(e)}},t.prototype.addDescribedBy=function(e,i){var r=(e.getAttribute("aria-describedby")||"").split(/\s+/);r.indexOf(i)<0&&r.push(i),Fe(e,{"aria-describedby":r.join(" ").trim(),"data-tooltip-id":i})},t.prototype.removeDescribedBy=function(e){var i=e.getAttribute("data-tooltip-id"),r=(e.getAttribute("aria-describedby")||"").split(/\s+/),s=r.indexOf(i);-1!==s&&r.splice(s,1),e.removeAttribute("data-tooltip-id");var o=r.join(" ").trim();o?e.setAttribute("aria-describedby",o):e.removeAttribute("aria-describedby")},t.prototype.tapHoldHandler=function(e){clearTimeout(this.autoCloseTimer),this.targetHover(e.originalEvent)},t.prototype.touchEndHandler=function(){var e=this;this.isSticky||(this.autoCloseTimer=setTimeout(function(){e.close()},1500))},t.prototype.targetClick=function(e){var i;!m(i=this.target?J(e.target,this.target):this.element)&&(null===i.getAttribute("data-tooltip-id")?this.targetHover(e):this.isSticky||this.hideTooltip(this.animation.close,e,i))},t.prototype.targetHover=function(e){var i;if(!(m(i=this.target?J(e.target,this.target):this.element)||null!==i.getAttribute("data-tooltip-id")&&0===this.closeDelay)){for(var s=0,o=[].slice.call(we('[data-tooltip-id= "'+this.ctrlId+'_content"]',document));s0?this.showTimer=setTimeout(function(){o.mouseTrail&&E.add(i,"mousemove touchstart mouseenter",o.onMouseMove,o),o.popupObj&&(o.popupObj.show(a,i),o.mouseMoveEvent&&o.mouseTrail&&o.onMouseMove(o.mouseMoveEvent))},this.openDelay):this.popupObj&&this.popupObj.show(a,i)}s&&this.wireMouseEvents(s,i)},t.prototype.needTemplateReposition=function(){return!m(this.viewContainerRef)&&"string"!=typeof this.viewContainerRef||this.isReact},t.prototype.checkCollision=function(e,i,r){var s={left:i,top:r,position:this.position,horizontal:this.tooltipPositionX,vertical:this.tooltipPositionY},o=ac(this.tooltipEle,this.checkCollideTarget(),i,r);return o.length>0&&(s.horizontal=o.indexOf("left")>=0?"Right":o.indexOf("right")>=0?"Left":this.tooltipPositionX,s.vertical=o.indexOf("top")>=0?"Bottom":o.indexOf("bottom")>=0?"Top":this.tooltipPositionY),s},t.prototype.calculateElementPosition=function(e,i){return[this.isBodyContainer?e.left+i.left:e.left-this.containerElement.getBoundingClientRect().left+i.left+window.pageXOffset+this.containerElement.scrollLeft,this.isBodyContainer?e.top+i.top:e.top-this.containerElement.getBoundingClientRect().top+i.top+window.pageYOffset+this.containerElement.scrollTop]},t.prototype.collisionFlipFit=function(e,i,r){var s=this.checkCollision(e,i,r),o=s.position;if(this.tooltipPositionY!==s.vertical&&(o=0===this.position.indexOf("Bottom")||0===this.position.indexOf("Top")?s.vertical+this.tooltipPositionX:this.tooltipPositionX+s.vertical),this.tooltipPositionX!==s.horizontal&&(0===o.indexOf("Left")&&(s.vertical="LeftTop"===o||"LeftCenter"===o?"Top":"Bottom",o=s.vertical+"Left"),0===o.indexOf("Right")&&(s.vertical="RightTop"===o||"RightCenter"===o?"Top":"Bottom",o=s.vertical+"Right"),s.horizontal=this.tooltipPositionX),this.tooltipEventArgs={type:null,cancel:!1,target:e,event:null,element:this.tooltipEle,collidedPosition:o},this.trigger("beforeCollision",this.tooltipEventArgs),this.tooltipEventArgs.cancel)o=this.position;else{var a=s.vertical,l=s.horizontal;if(s.position!==o){var h=ns(e,l,a,!this.isBodyContainer,this.isBodyContainer?null:this.containerElement.getBoundingClientRect());this.adjustArrow(e,o,l,a);var c=this.getScalingFactor(e),d=this.calculateTooltipOffset(o,c.x,c.y);d.top-=this.getOffSetPosition("TopBottom",o,this.offsetY),d.left-=this.getOffSetPosition("RightLeft",o,this.offsetX),s.position=o;var u=this.calculateElementPosition(h,d);s.left=u[0],s.top=u[1]}else this.adjustArrow(e,o,l,a)}var f={left:s.left,top:s.top},p=this.isBodyContainer?cE(this.tooltipEle,this.checkCollideTarget(),{X:!0,Y:this.windowCollision},f):f;this.tooltipEle.style.display="block";var g=_("."+df,this.tooltipEle);if(this.showTipPointer&&null!=g&&(0===o.indexOf("Bottom")||0===o.indexOf("Top"))){var v=parseInt(g.style.left,10)-(p.left-s.left);v<0?v=0:v+g.offsetWidth>this.tooltipEle.clientWidth&&(v=this.tooltipEle.clientWidth-g.offsetWidth),g.style.left=v.toString()+"px"}return this.tooltipEle.style.display="",f.left=p.left,f.top=p.top,f},t.prototype.getOffSetPosition=function(e,i,r){return-1!==e.indexOf(this.position.split(/(?=[A-Z])/)[0])&&-1!==e.indexOf(i.split(/(?=[A-Z])/)[0])?2*r:0},t.prototype.checkCollideTarget=function(){return!this.windowCollision&&this.target?this.element:null},t.prototype.hideTooltip=function(e,i,r){var s=this;this.closeDelay>0?(clearTimeout(this.hideTimer),clearTimeout(this.showTimer),this.hideTimer=setTimeout(function(){s.closeDelay&&s.tooltipEle&&s.isTooltipOpen||s.tooltipHide(e,i,r)},this.closeDelay)):this.tooltipHide(e,i,r)},t.prototype.tooltipHide=function(e,i,r){var o,s=this;o=i?this.target?r||i.target:this.element:_('[data-tooltip-id= "'+this.ctrlId+'_content"]',document),this.tooltipEventArgs={type:i?i.type:null,cancel:!1,target:o,event:i||null,element:this.tooltipEle,isInteracted:!m(i)},this.trigger("beforeClose",this.tooltipEventArgs,function(a){a.cancel?s.isHidden=!1:(s.mouseMoveBeforeRemove(),s.popupHide(e,o,i))})},t.prototype.popupHide=function(e,i,r){i&&r&&this.restoreElement(i),this.isHidden=!0;var s={name:this.animation.close.effect,duration:e.duration,delay:e.delay,timingFunction:"easeIn"};"None"===e.effect&&(s=void 0),this.popupObj&&this.popupObj.hide(s)},t.prototype.restoreElement=function(e){this.unwireMouseEvents(e),m(e.getAttribute("data-content"))||(e.setAttribute("title",e.getAttribute("data-content")),e.removeAttribute("data-content")),this.removeDescribedBy(e)},t.prototype.clear=function(){var e=this.findTarget();e&&this.restoreElement(e),this.tooltipEle&&(K([this.tooltipEle],UE),V([this.tooltipEle],Xg)),this.isHidden&&(this.popupObj&&this.popupObj.destroy(),this.tooltipEle&>(this.tooltipEle),this.tooltipEle=null,this.popupObj=null)},t.prototype.tooltipHover=function(){this.tooltipEle&&(this.isTooltipOpen=!0)},t.prototype.tooltipMouseOut=function(e){this.isTooltipOpen=!1,this.hideTooltip(this.animation.close,e,this.findTarget())},t.prototype.onMouseOut=function(e){var i=e.relatedTarget;if(i&&!this.mouseTrail){var r=J(i,"."+HE+"."+G0+"."+_E);r?E.add(r,"mouseleave",this.tooltipElementMouseOut,this):(this.hideTooltip(this.animation.close,e,this.findTarget()),0===this.closeDelay&&("None"===this.animation.close.effect||this.isReact&&"string"!=typeof this.content)&&this.clear())}else this.hideTooltip(this.animation.close,e,this.findTarget()),this.clear();this.popupObj&&!this.popupObj.element.classList.contains(Xg)&&this.clear()},t.prototype.tooltipElementMouseOut=function(e){this.hideTooltip(this.animation.close,e,this.findTarget()),E.remove(this.element,"mouseleave",this.tooltipElementMouseOut),this.clear()},t.prototype.onStickyClose=function(){this.close()},t.prototype.onMouseMove=function(e){var i=0,r=0;e.type.indexOf("touch")>-1?(e.preventDefault(),i=e.touches[0].pageX,r=e.touches[0].pageY):(i=e.pageX,r=e.pageY),Hs.stop(this.tooltipEle),K([this.tooltipEle],UE),V([this.tooltipEle],Xg),this.adjustArrow(e.target,this.position,this.tooltipPositionX,this.tooltipPositionY);var s=this.getScalingFactor(e.target),o=this.calculateTooltipOffset(this.position,s.x,s.y),h=this.checkCollision(e.target,i+o.left+this.offsetX,r+o.top+this.offsetY);if(this.tooltipPositionX!==h.horizontal||this.tooltipPositionY!==h.vertical){var c=0===this.position.indexOf("Bottom")||0===this.position.indexOf("Top")?h.vertical+h.horizontal:h.horizontal+h.vertical;h.position=c,this.adjustArrow(e.target,h.position,h.horizontal,h.vertical);var d=this.calculateTooltipOffset(h.position,s.x,s.y);h.left=i+d.left-this.offsetX,h.top=r+d.top-this.offsetY}this.tooltipEle.style.left=h.left+"px",this.tooltipEle.style.top=h.top+"px"},t.prototype.keyDown=function(e){this.tooltipEle&&27===e.keyCode&&this.close()},t.prototype.touchEnd=function(e){this.tooltipEle&&null===J(e.target,"."+RE)&&!this.isSticky&&this.close()},t.prototype.scrollHandler=function(e){this.tooltipEle&&!this.isSticky&&!J(e.target,"."+HE+"."+G0+"."+_E)&&!this.isSticky&&this.close()},t.prototype.render=function(){this.initialize(),this.wireEvents(this.opensOn),this.renderComplete()},t.prototype.preRender=function(){this.tipClass=Gg,this.tooltipPositionX="Center",this.tooltipPositionY="Top",this.isHidden=!0},t.prototype.wireEvents=function(e){for(var r=0,s=this.getTriggerList(e);r0)for(var i=0,r=e;i0)for(var i=0,r=e;i0&&this.condition&&-1!==this.condition.indexOf("not")&&(e[s].condition=e[s].condition?e[s].condition+"not":"not"),i=e[s].validate(t),r){if(!i)return!1}else if(i)return!0;return r},n.prototype.toJson=function(){var t,e;if(this.isComplex){t=[],e=this.predicates;for(var i=0;ie.length-3?(e=e.substring(0,e.length-1),n.endsWith(n.toLowerCase(t),n.toLowerCase(e))):(e.lastIndexOf("%")!==e.indexOf("%")&&e.lastIndexOf("%")>e.indexOf("%")+1&&(e=e.substring(e.indexOf("%")+1,e.lastIndexOf("%"))),-1!==t.indexOf(e)))},n.fnSort=function(t){return"ascending"===(t=t?n.toLowerCase(t):"ascending")?this.fnAscending:this.fnDescending},n.fnAscending=function(t,e){return m(t)&&m(e)||null==e?-1:"string"==typeof t?t.localeCompare(e):null==t?1:t-e},n.fnDescending=function(t,e){return m(t)&&m(e)?-1:null==e?1:"string"==typeof t?-1*t.localeCompare(e):null==t?-1:e-t},n.extractFields=function(t,e){for(var i={},r=0;r0||e.length>0;)o=t.length>0&&e.length>0?r?r(this.getVal(t,0,i),this.getVal(e,0,i),t[0],e[0])<=0?t:e:t[0][i]0?t:e,s.push(o.shift());return s},n.getVal=function(t,e,i){return i?this.getObject(i,t[e]):t[e]},n.toLowerCase=function(t){return t?"string"==typeof t?t.toLowerCase():t.toString():0===t||!1===t?t.toString():""},n.callAdaptorFunction=function(t,e,i,r){if(e in t){var s=t[e](i,r);m(s)||(i=s)}return i},n.getAddParams=function(t,e,i){var r={};return n.callAdaptorFunction(t,"addParams",{dm:e,query:i,params:i?i.params:[],reqParams:r}),r},n.isPlainObject=function(t){return!!t&&t.constructor===Object},n.isCors=function(){var t=null;try{t=new window.XMLHttpRequest}catch{}return!!t&&"withCredentials"in t},n.getGuid=function(t){var i;return(t||"")+"00000000-0000-4000-0000-000000000000".replace(/0/g,function(r,s){if("crypto"in window&&"getRandomValues"in crypto){var o=new Uint8Array(1);window.crypto.getRandomValues(o),i=o[0]%16|0}else i=16*Math.random()|0;return"0123456789abcdef"[19===s?3&i|8:i]})},n.isNull=function(t){return null==t},n.getItemFromComparer=function(t,e,i){var r,s,o,a=0,l="string"==typeof n.getVal(t,0,e);if(t.length)for(;m(r)&&a0&&(r=s,o=t[a]));return o},n.distinct=function(t,e,i){i=!m(i)&&i;var s,r=[],o={};return t.forEach(function(a,l){(s="object"==typeof t[l]?n.getVal(t,l,e):t[l])in o||(r.push(i?t[l]:s),o[s]=1)}),r},n.processData=function(t,e){var i=this.prepareQuery(t),r=new it(e);t.requiresCounts&&i.requiresCount();var s=r.executeLocal(i),o={result:t.requiresCounts?s.result:s,count:s.count,aggregates:JSON.stringify(s.aggregates)};return t.requiresCounts?o:s},n.prepareQuery=function(t){var e=this,i=new _t;return t.select&&i.select(t.select),t.where&&n.parse.parseJson(t.where).filter(function(o){if(m(o.condition))i.where(o.field,o.operator,o.value,o.ignoreCase,o.ignoreAccent);else{var a=[];o.field?a.push(new Ss(o.field,o.operator,o.value,o.ignoreCase,o.ignoreAccent)):a=a.concat(e.getPredicate(o.predicates)),"or"===o.condition?i.where(Ss.or(a)):"and"===o.condition&&i.where(Ss.and(a))}}),t.search&&n.parse.parseJson(t.search).filter(function(o){return i.search(o.key,o.fields,o.operator,o.ignoreCase,o.ignoreAccent)}),t.aggregates&&t.aggregates.filter(function(o){return i.aggregate(o.type,o.field)}),t.sorted&&t.sorted.filter(function(o){return i.sortBy(o.name,o.direction)}),t.skip&&i.skip(t.skip),t.take&&i.take(t.take),t.group&&t.group.filter(function(o){return i.group(o)}),i},n.getPredicate=function(t){for(var e=[],i=0;i":"greaterthan","<=":"lessthanorequal",">=":"greaterthanorequal","==":"equal","!=":"notequal","*=":"contains","$=":"endswith","^=":"startswith"},n.odBiOperator={"<":" lt ",">":" gt ","<=":" le ",">=":" ge ","==":" eq ","!=":" ne ",lessthan:" lt ",lessthanorequal:" le ",greaterthan:" gt ",greaterthanorequal:" ge ",equal:" eq ",notequal:" ne "},n.odUniOperator={"$=":"endswith","^=":"startswith","*=":"substringof",endswith:"endswith",startswith:"startswith",contains:"substringof",doesnotendwith:"not endswith",doesnotstartwith:"not startswith",doesnotcontain:"not substringof",wildcard:"wildcard",like:"like"},n.odv4UniOperator={"$=":"endswith","^=":"startswith","*=":"contains",endswith:"endswith",startswith:"startswith",contains:"contains",doesnotendwith:"not endswith",doesnotstartwith:"not startswith",doesnotcontain:"not contains",wildcard:"wildcard",like:"like"},n.diacritics={"\u24b6":"A",\uff21:"A",\u00c0:"A",\u00c1:"A",\u00c2:"A",\u1ea6:"A",\u1ea4:"A",\u1eaa:"A",\u1ea8:"A",\u00c3:"A",\u0100:"A",\u0102:"A",\u1eb0:"A",\u1eae:"A",\u1eb4:"A",\u1eb2:"A",\u0226:"A",\u01e0:"A",\u00c4:"A",\u01de:"A",\u1ea2:"A",\u00c5:"A",\u01fa:"A",\u01cd:"A",\u0200:"A",\u0202:"A",\u1ea0:"A",\u1eac:"A",\u1eb6:"A",\u1e00:"A",\u0104:"A",\u023a:"A",\u2c6f:"A",\ua732:"AA",\u00c6:"AE",\u01fc:"AE",\u01e2:"AE",\ua734:"AO",\ua736:"AU",\ua738:"AV",\ua73a:"AV",\ua73c:"AY","\u24b7":"B",\uff22:"B",\u1e02:"B",\u1e04:"B",\u1e06:"B",\u0243:"B",\u0182:"B",\u0181:"B","\u24b8":"C",\uff23:"C",\u0106:"C",\u0108:"C",\u010a:"C",\u010c:"C",\u00c7:"C",\u1e08:"C",\u0187:"C",\u023b:"C",\ua73e:"C","\u24b9":"D",\uff24:"D",\u1e0a:"D",\u010e:"D",\u1e0c:"D",\u1e10:"D",\u1e12:"D",\u1e0e:"D",\u0110:"D",\u018b:"D",\u018a:"D",\u0189:"D",\ua779:"D",\u01f1:"DZ",\u01c4:"DZ",\u01f2:"Dz",\u01c5:"Dz","\u24ba":"E",\uff25:"E",\u00c8:"E",\u00c9:"E",\u00ca:"E",\u1ec0:"E",\u1ebe:"E",\u1ec4:"E",\u1ec2:"E",\u1ebc:"E",\u0112:"E",\u1e14:"E",\u1e16:"E",\u0114:"E",\u0116:"E",\u00cb:"E",\u1eba:"E",\u011a:"E",\u0204:"E",\u0206:"E",\u1eb8:"E",\u1ec6:"E",\u0228:"E",\u1e1c:"E",\u0118:"E",\u1e18:"E",\u1e1a:"E",\u0190:"E",\u018e:"E","\u24bb":"F",\uff26:"F",\u1e1e:"F",\u0191:"F",\ua77b:"F","\u24bc":"G",\uff27:"G",\u01f4:"G",\u011c:"G",\u1e20:"G",\u011e:"G",\u0120:"G",\u01e6:"G",\u0122:"G",\u01e4:"G",\u0193:"G",\ua7a0:"G",\ua77d:"G",\ua77e:"G","\u24bd":"H",\uff28:"H",\u0124:"H",\u1e22:"H",\u1e26:"H",\u021e:"H",\u1e24:"H",\u1e28:"H",\u1e2a:"H",\u0126:"H",\u2c67:"H",\u2c75:"H",\ua78d:"H","\u24be":"I",\uff29:"I",\u00cc:"I",\u00cd:"I",\u00ce:"I",\u0128:"I",\u012a:"I",\u012c:"I",\u0130:"I",\u00cf:"I",\u1e2e:"I",\u1ec8:"I",\u01cf:"I",\u0208:"I",\u020a:"I",\u1eca:"I",\u012e:"I",\u1e2c:"I",\u0197:"I","\u24bf":"J",\uff2a:"J",\u0134:"J",\u0248:"J","\u24c0":"K",\uff2b:"K",\u1e30:"K",\u01e8:"K",\u1e32:"K",\u0136:"K",\u1e34:"K",\u0198:"K",\u2c69:"K",\ua740:"K",\ua742:"K",\ua744:"K",\ua7a2:"K","\u24c1":"L",\uff2c:"L",\u013f:"L",\u0139:"L",\u013d:"L",\u1e36:"L",\u1e38:"L",\u013b:"L",\u1e3c:"L",\u1e3a:"L",\u0141:"L",\u023d:"L",\u2c62:"L",\u2c60:"L",\ua748:"L",\ua746:"L",\ua780:"L",\u01c7:"LJ",\u01c8:"Lj","\u24c2":"M",\uff2d:"M",\u1e3e:"M",\u1e40:"M",\u1e42:"M",\u2c6e:"M",\u019c:"M","\u24c3":"N",\uff2e:"N",\u01f8:"N",\u0143:"N",\u00d1:"N",\u1e44:"N",\u0147:"N",\u1e46:"N",\u0145:"N",\u1e4a:"N",\u1e48:"N",\u0220:"N",\u019d:"N",\ua790:"N",\ua7a4:"N",\u01ca:"NJ",\u01cb:"Nj","\u24c4":"O",\uff2f:"O",\u00d2:"O",\u00d3:"O",\u00d4:"O",\u1ed2:"O",\u1ed0:"O",\u1ed6:"O",\u1ed4:"O",\u00d5:"O",\u1e4c:"O",\u022c:"O",\u1e4e:"O",\u014c:"O",\u1e50:"O",\u1e52:"O",\u014e:"O",\u022e:"O",\u0230:"O",\u00d6:"O",\u022a:"O",\u1ece:"O",\u0150:"O",\u01d1:"O",\u020c:"O",\u020e:"O",\u01a0:"O",\u1edc:"O",\u1eda:"O",\u1ee0:"O",\u1ede:"O",\u1ee2:"O",\u1ecc:"O",\u1ed8:"O",\u01ea:"O",\u01ec:"O",\u00d8:"O",\u01fe:"O",\u0186:"O",\u019f:"O",\ua74a:"O",\ua74c:"O",\u01a2:"OI",\ua74e:"OO",\u0222:"OU","\u24c5":"P",\uff30:"P",\u1e54:"P",\u1e56:"P",\u01a4:"P",\u2c63:"P",\ua750:"P",\ua752:"P",\ua754:"P","\u24c6":"Q",\uff31:"Q",\ua756:"Q",\ua758:"Q",\u024a:"Q","\u24c7":"R",\uff32:"R",\u0154:"R",\u1e58:"R",\u0158:"R",\u0210:"R",\u0212:"R",\u1e5a:"R",\u1e5c:"R",\u0156:"R",\u1e5e:"R",\u024c:"R",\u2c64:"R",\ua75a:"R",\ua7a6:"R",\ua782:"R","\u24c8":"S",\uff33:"S",\u1e9e:"S",\u015a:"S",\u1e64:"S",\u015c:"S",\u1e60:"S",\u0160:"S",\u1e66:"S",\u1e62:"S",\u1e68:"S",\u0218:"S",\u015e:"S",\u2c7e:"S",\ua7a8:"S",\ua784:"S","\u24c9":"T",\uff34:"T",\u1e6a:"T",\u0164:"T",\u1e6c:"T",\u021a:"T",\u0162:"T",\u1e70:"T",\u1e6e:"T",\u0166:"T",\u01ac:"T",\u01ae:"T",\u023e:"T",\ua786:"T",\ua728:"TZ","\u24ca":"U",\uff35:"U",\u00d9:"U",\u00da:"U",\u00db:"U",\u0168:"U",\u1e78:"U",\u016a:"U",\u1e7a:"U",\u016c:"U",\u00dc:"U",\u01db:"U",\u01d7:"U",\u01d5:"U",\u01d9:"U",\u1ee6:"U",\u016e:"U",\u0170:"U",\u01d3:"U",\u0214:"U",\u0216:"U",\u01af:"U",\u1eea:"U",\u1ee8:"U",\u1eee:"U",\u1eec:"U",\u1ef0:"U",\u1ee4:"U",\u1e72:"U",\u0172:"U",\u1e76:"U",\u1e74:"U",\u0244:"U","\u24cb":"V",\uff36:"V",\u1e7c:"V",\u1e7e:"V",\u01b2:"V",\ua75e:"V",\u0245:"V",\ua760:"VY","\u24cc":"W",\uff37:"W",\u1e80:"W",\u1e82:"W",\u0174:"W",\u1e86:"W",\u1e84:"W",\u1e88:"W",\u2c72:"W","\u24cd":"X",\uff38:"X",\u1e8a:"X",\u1e8c:"X","\u24ce":"Y",\uff39:"Y",\u1ef2:"Y",\u00dd:"Y",\u0176:"Y",\u1ef8:"Y",\u0232:"Y",\u1e8e:"Y",\u0178:"Y",\u1ef6:"Y",\u1ef4:"Y",\u01b3:"Y",\u024e:"Y",\u1efe:"Y","\u24cf":"Z",\uff3a:"Z",\u0179:"Z",\u1e90:"Z",\u017b:"Z",\u017d:"Z",\u1e92:"Z",\u1e94:"Z",\u01b5:"Z",\u0224:"Z",\u2c7f:"Z",\u2c6b:"Z",\ua762:"Z","\u24d0":"a",\uff41:"a",\u1e9a:"a",\u00e0:"a",\u00e1:"a",\u00e2:"a",\u1ea7:"a",\u1ea5:"a",\u1eab:"a",\u1ea9:"a",\u00e3:"a",\u0101:"a",\u0103:"a",\u1eb1:"a",\u1eaf:"a",\u1eb5:"a",\u1eb3:"a",\u0227:"a",\u01e1:"a",\u00e4:"a",\u01df:"a",\u1ea3:"a",\u00e5:"a",\u01fb:"a",\u01ce:"a",\u0201:"a",\u0203:"a",\u1ea1:"a",\u1ead:"a",\u1eb7:"a",\u1e01:"a",\u0105:"a",\u2c65:"a",\u0250:"a",\ua733:"aa",\u00e6:"ae",\u01fd:"ae",\u01e3:"ae",\ua735:"ao",\ua737:"au",\ua739:"av",\ua73b:"av",\ua73d:"ay","\u24d1":"b",\uff42:"b",\u1e03:"b",\u1e05:"b",\u1e07:"b",\u0180:"b",\u0183:"b",\u0253:"b","\u24d2":"c",\uff43:"c",\u0107:"c",\u0109:"c",\u010b:"c",\u010d:"c",\u00e7:"c",\u1e09:"c",\u0188:"c",\u023c:"c",\ua73f:"c",\u2184:"c","\u24d3":"d",\uff44:"d",\u1e0b:"d",\u010f:"d",\u1e0d:"d",\u1e11:"d",\u1e13:"d",\u1e0f:"d",\u0111:"d",\u018c:"d",\u0256:"d",\u0257:"d",\ua77a:"d",\u01f3:"dz",\u01c6:"dz","\u24d4":"e",\uff45:"e",\u00e8:"e",\u00e9:"e",\u00ea:"e",\u1ec1:"e",\u1ebf:"e",\u1ec5:"e",\u1ec3:"e",\u1ebd:"e",\u0113:"e",\u1e15:"e",\u1e17:"e",\u0115:"e",\u0117:"e",\u00eb:"e",\u1ebb:"e",\u011b:"e",\u0205:"e",\u0207:"e",\u1eb9:"e",\u1ec7:"e",\u0229:"e",\u1e1d:"e",\u0119:"e",\u1e19:"e",\u1e1b:"e",\u0247:"e",\u025b:"e",\u01dd:"e","\u24d5":"f",\uff46:"f",\u1e1f:"f",\u0192:"f",\ua77c:"f","\u24d6":"g",\uff47:"g",\u01f5:"g",\u011d:"g",\u1e21:"g",\u011f:"g",\u0121:"g",\u01e7:"g",\u0123:"g",\u01e5:"g",\u0260:"g",\ua7a1:"g",\u1d79:"g",\ua77f:"g","\u24d7":"h",\uff48:"h",\u0125:"h",\u1e23:"h",\u1e27:"h",\u021f:"h",\u1e25:"h",\u1e29:"h",\u1e2b:"h",\u1e96:"h",\u0127:"h",\u2c68:"h",\u2c76:"h",\u0265:"h",\u0195:"hv","\u24d8":"i",\uff49:"i",\u00ec:"i",\u00ed:"i",\u00ee:"i",\u0129:"i",\u012b:"i",\u012d:"i",\u00ef:"i",\u1e2f:"i",\u1ec9:"i",\u01d0:"i",\u0209:"i",\u020b:"i",\u1ecb:"i",\u012f:"i",\u1e2d:"i",\u0268:"i",\u0131:"i","\u24d9":"j",\uff4a:"j",\u0135:"j",\u01f0:"j",\u0249:"j","\u24da":"k",\uff4b:"k",\u1e31:"k",\u01e9:"k",\u1e33:"k",\u0137:"k",\u1e35:"k",\u0199:"k",\u2c6a:"k",\ua741:"k",\ua743:"k",\ua745:"k",\ua7a3:"k","\u24db":"l",\uff4c:"l",\u0140:"l",\u013a:"l",\u013e:"l",\u1e37:"l",\u1e39:"l",\u013c:"l",\u1e3d:"l",\u1e3b:"l",\u017f:"l",\u0142:"l",\u019a:"l",\u026b:"l",\u2c61:"l",\ua749:"l",\ua781:"l",\ua747:"l",\u01c9:"lj","\u24dc":"m",\uff4d:"m",\u1e3f:"m",\u1e41:"m",\u1e43:"m",\u0271:"m",\u026f:"m","\u24dd":"n",\uff4e:"n",\u01f9:"n",\u0144:"n",\u00f1:"n",\u1e45:"n",\u0148:"n",\u1e47:"n",\u0146:"n",\u1e4b:"n",\u1e49:"n",\u019e:"n",\u0272:"n",\u0149:"n",\ua791:"n",\ua7a5:"n",\u01cc:"nj","\u24de":"o",\uff4f:"o",\u00f2:"o",\u00f3:"o",\u00f4:"o",\u1ed3:"o",\u1ed1:"o",\u1ed7:"o",\u1ed5:"o",\u00f5:"o",\u1e4d:"o",\u022d:"o",\u1e4f:"o",\u014d:"o",\u1e51:"o",\u1e53:"o",\u014f:"o",\u022f:"o",\u0231:"o",\u00f6:"o",\u022b:"o",\u1ecf:"o",\u0151:"o",\u01d2:"o",\u020d:"o",\u020f:"o",\u01a1:"o",\u1edd:"o",\u1edb:"o",\u1ee1:"o",\u1edf:"o",\u1ee3:"o",\u1ecd:"o",\u1ed9:"o",\u01eb:"o",\u01ed:"o",\u00f8:"o",\u01ff:"o",\u0254:"o",\ua74b:"o",\ua74d:"o",\u0275:"o",\u01a3:"oi",\u0223:"ou",\ua74f:"oo","\u24df":"p",\uff50:"p",\u1e55:"p",\u1e57:"p",\u01a5:"p",\u1d7d:"p",\ua751:"p",\ua753:"p",\ua755:"p","\u24e0":"q",\uff51:"q",\u024b:"q",\ua757:"q",\ua759:"q","\u24e1":"r",\uff52:"r",\u0155:"r",\u1e59:"r",\u0159:"r",\u0211:"r",\u0213:"r",\u1e5b:"r",\u1e5d:"r",\u0157:"r",\u1e5f:"r",\u024d:"r",\u027d:"r",\ua75b:"r",\ua7a7:"r",\ua783:"r","\u24e2":"s",\uff53:"s",\u00df:"s",\u015b:"s",\u1e65:"s",\u015d:"s",\u1e61:"s",\u0161:"s",\u1e67:"s",\u1e63:"s",\u1e69:"s",\u0219:"s",\u015f:"s",\u023f:"s",\ua7a9:"s",\ua785:"s",\u1e9b:"s","\u24e3":"t",\uff54:"t",\u1e6b:"t",\u1e97:"t",\u0165:"t",\u1e6d:"t",\u021b:"t",\u0163:"t",\u1e71:"t",\u1e6f:"t",\u0167:"t",\u01ad:"t",\u0288:"t",\u2c66:"t",\ua787:"t",\ua729:"tz","\u24e4":"u",\uff55:"u",\u00f9:"u",\u00fa:"u",\u00fb:"u",\u0169:"u",\u1e79:"u",\u016b:"u",\u1e7b:"u",\u016d:"u",\u00fc:"u",\u01dc:"u",\u01d8:"u",\u01d6:"u",\u01da:"u",\u1ee7:"u",\u016f:"u",\u0171:"u",\u01d4:"u",\u0215:"u",\u0217:"u",\u01b0:"u",\u1eeb:"u",\u1ee9:"u",\u1eef:"u",\u1eed:"u",\u1ef1:"u",\u1ee5:"u",\u1e73:"u",\u0173:"u",\u1e77:"u",\u1e75:"u",\u0289:"u","\u24e5":"v",\uff56:"v",\u1e7d:"v",\u1e7f:"v",\u028b:"v",\ua75f:"v",\u028c:"v",\ua761:"vy","\u24e6":"w",\uff57:"w",\u1e81:"w",\u1e83:"w",\u0175:"w",\u1e87:"w",\u1e85:"w",\u1e98:"w",\u1e89:"w",\u2c73:"w","\u24e7":"x",\uff58:"x",\u1e8b:"x",\u1e8d:"x","\u24e8":"y",\uff59:"y",\u1ef3:"y",\u00fd:"y",\u0177:"y",\u1ef9:"y",\u0233:"y",\u1e8f:"y",\u00ff:"y",\u1ef7:"y",\u1e99:"y",\u1ef5:"y",\u01b4:"y",\u024f:"y",\u1eff:"y","\u24e9":"z",\uff5a:"z",\u017a:"z",\u1e91:"z",\u017c:"z",\u017e:"z",\u1e93:"z",\u1e95:"z",\u01b6:"z",\u0225:"z",\u0240:"z",\u2c6c:"z",\ua763:"z",\u0386:"\u0391",\u0388:"\u0395",\u0389:"\u0397",\u038a:"\u0399",\u03aa:"\u0399",\u038c:"\u039f",\u038e:"\u03a5",\u03ab:"\u03a5",\u038f:"\u03a9",\u03ac:"\u03b1",\u03ad:"\u03b5",\u03ae:"\u03b7",\u03af:"\u03b9",\u03ca:"\u03b9",\u0390:"\u03b9",\u03cc:"\u03bf",\u03cd:"\u03c5",\u03cb:"\u03c5",\u03b0:"\u03c5",\u03c9:"\u03c9",\u03c2:"\u03c3"},n.fnOperators={equal:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?n.toLowerCase(t)===n.toLowerCase(e):t===e},notequal:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),!n.fnOperators.equal(t,e,i)},lessthan:function(t,e,i){return i?n.toLowerCase(t)n.toLowerCase(e):t>e},lessthanorequal:function(t,e,i){return i?n.toLowerCase(t)<=n.toLowerCase(e):(m(t)&&(t=void 0),t<=e)},greaterthanorequal:function(t,e,i){return i?n.toLowerCase(t)>=n.toLowerCase(e):t>=e},contains:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?!m(t)&&!m(e)&&-1!==n.toLowerCase(t).indexOf(n.toLowerCase(e)):!m(t)&&!m(e)&&-1!==t.toString().indexOf(e)},doesnotcontain:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?!m(t)&&!m(e)&&-1===n.toLowerCase(t).indexOf(n.toLowerCase(e)):!m(t)&&!m(e)&&-1===t.toString().indexOf(e)},isnotnull:function(t){return null!=t},isnull:function(t){return null==t},startswith:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.startsWith(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.startsWith(t,e)},doesnotstartwith:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.notStartsWith(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.notStartsWith(t,e)},like:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.like(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.like(t,e)},isempty:function(t){return void 0===t||""===t},isnotempty:function(t){return void 0!==t&&""!==t},wildcard:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?(t||"boolean"==typeof t)&&e&&"object"!=typeof t&&n.wildCard(n.toLowerCase(t),n.toLowerCase(e)):(t||"boolean"==typeof t)&&e&&n.wildCard(t,e)},endswith:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.endsWith(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.endsWith(t,e)},doesnotendwith:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.notEndsWith(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.notEndsWith(t,e)},processSymbols:function(t){var e=n.operatorSymbols[t];return e?n.fnOperators[e]:n.throwError("Query - Process Operator : Invalid operator")},processOperator:function(t){return n.fnOperators[t]||n.fnOperators.processSymbols(t)}},n.parse={parseJson:function(t){return"string"!=typeof t||!/^[\s]*\[|^[\s]*\{(.)+:/g.test(t)&&-1!==t.indexOf('"')?t instanceof Array?n.parse.iterateAndReviveArray(t):"object"==typeof t&&null!==t&&n.parse.iterateAndReviveJson(t):t=JSON.parse(t,n.parse.jsonReviver),t},iterateAndReviveArray:function(t){for(var e=0;e-1||e.indexOf("z")>-1,o=e.split(/[^0-9.]/);if(s){if(o[5].indexOf(".")>-1){var a=o[5].split(".");o[5]=a[0],o[6]=new Date(e).getUTCMilliseconds().toString()}else o[6]="00";e=n.dateParse.toTimeZone(new Date(parseInt(o[0],10),parseInt(o[1],10)-1,parseInt(o[2],10),parseInt(o[3],10),parseInt(o[4],10),parseInt(o[5]?o[5]:"00",10),parseInt(o[6],10)),n.serverTimezoneOffset,!1)}else{var l=new Date(parseInt(o[0],10),parseInt(o[1],10)-1,parseInt(o[2],10),parseInt(o[3],10),parseInt(o[4],10),parseInt(o[5]?o[5]:"00",10)),h=parseInt(o[6],10),c=parseInt(o[7],10);if(isNaN(h)&&isNaN(c))return l;e.indexOf("+")>-1?l.setHours(l.getHours()-h,l.getMinutes()-c):l.setHours(l.getHours()+h,l.getMinutes()+c),e=n.dateParse.toTimeZone(l,n.serverTimezoneOffset,!1)}null==n.serverTimezoneOffset&&(e=n.dateParse.addSelfOffset(e))}}return e},isJson:function(t){return"string"==typeof t[0]?t:n.parse.parseJson(t)},isGuid:function(t){return null!=/[A-Fa-f0-9]{8}(?:-[A-Fa-f0-9]{4}){3}-[A-Fa-f0-9]{12}/i.exec(t)},replacer:function(t,e){return n.isPlainObject(t)?n.parse.jsonReplacer(t,e):t instanceof Array?n.parse.arrayReplacer(t):t instanceof Date?n.parse.jsonReplacer({val:t},e).val:t},jsonReplacer:function(t,e){for(var i,s=0,o=Object.keys(t);s=0?"+":"-",s=function(a){var l=Math.floor(Math.abs(a));return(l<10?"0":"")+l};return e.getFullYear()+"-"+s(e.getMonth()+1)+"-"+s(e.getDate())+"T"+s(e.getHours())+":"+s(e.getMinutes())+":"+s(e.getSeconds())+r+s(i/60)+":"+s(i%60)}},n}(),Ml=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),xK={GroupGuid:"{271bbba0-1ee7}"},t5=function(){function n(t){this.options={from:"table",requestType:"json",sortBy:"sorted",select:"select",skip:"skip",group:"group",take:"take",search:"search",count:"requiresCounts",where:"where",aggregates:"aggregates",expand:"expand"},this.type=n,this.dataSource=t,this.pvt={}}return n.prototype.processResponse=function(t,e,i,r){return t},n}(),WE=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ml(t,n),t.prototype.processQuery=function(e,i){for(var a,l,f,r=e.dataSource.json.slice(0),s=r.length,o=!0,h={},c=0,d=[],u=[],p=0;p1?e.sort.filter(function(f){return f.fieldName===c})[0]:e.sort[0];s=this.onSortBy(s,d,e.query,!0)}e.page&&(s=this.onPage(s,e.page,e.query)),this.formGroupResult(s,h)}else{for(var o=e.lazyLoad.onDemandGroupInfo,a=o.where.length-1;a>=0;a--)s=this.onWhere(s,o.where[a]);if(e.group.length!==o.level)s=le.group(s,e.group[o.level].fieldName,r,null,null,e.group[o.level].comparer,!0),e.sort.length&&(s=this.onSortBy(s,e.sort[parseInt(o.level.toString(),10)],e.query,!0));else for(a=e.sort.length-1;a>=o.level;a--)s=this.onSortBy(s,e.sort[parseInt(a.toString(),10)],e.query,!1);i=s.length,h=s,s=(s=s.slice(o.skip)).slice(0,o.take),e.group.length!==o.level&&this.formGroupResult(s,h)}return{result:s,count:i}},t.prototype.formGroupResult=function(e,i){if(e.length&&i.length){var r="GroupGuid",s="childLevels",o="level",a="records";e[r]=i[r],e[s]=i[s],e[o]=i[o],e[a]=i[a]}return e},t.prototype.getAggregate=function(e){var i=_t.filterQueries(e.queries,"onAggregates"),r=[];if(i.length)for(var s=void 0,o=0;o=0;l--)a[l]&&(o=i.comparer,le.endsWith(a[l]," desc")&&(o=le.fnSort("descending"),a[l]=a[l].replace(" desc","")),e=le.sort(e,a[l],o));return e}return le.sort(e,s?"key":a,i.comparer)},t.prototype.onGroup=function(e,i,r){if(!e||!e.length)return e;var s=this.getAggregate(r);return le.group(e,le.getValue(i.fieldName,r),s,null,null,i.comparer)},t.prototype.onPage=function(e,i,r){var s=le.getValue(i.pageSize,r),o=(le.getValue(i.pageIndex,r)-1)*s;return e&&e.length?e.slice(o,o+s):e},t.prototype.onRange=function(e,i){return e&&e.length?e.slice(le.getValue(i.start),le.getValue(i.end)):e},t.prototype.onTake=function(e,i){return e&&e.length?e.slice(0,le.getValue(i.nos)):e},t.prototype.onSkip=function(e,i){return e&&e.length?e.slice(le.getValue(i.nos)):e},t.prototype.onSelect=function(e,i){return e&&e.length?le.select(e,le.getValue(i.fieldNames)):e},t.prototype.insert=function(e,i,r,s,o){return m(o)?e.dataSource.json.push(i):e.dataSource.json.splice(o,0,i)},t.prototype.remove=function(e,i,r,s){var a,o=e.dataSource.json;for("object"==typeof r&&!(r instanceof Date)&&(r=le.getObject(i,r)),a=0;a1&&(g="("+g+")"),f.filters.push(g);for(var y=0,S="object"==typeof f.filters[p]?Object.keys(f.filters[p]):[];y-1&&this.formRemoteGroupedData(e[s].items,i+1,r-1);var o="GroupGuid",h="records";return e[o]=xK[o],e.level=i,e.childLevels=r,e[h]=e[0].items.length?this.getGroupedRecords(e,!m(e[0].items[h])):[],e},t.prototype.getGroupedRecords=function(e,i){for(var r=[],o=0;ol.length-3?(l=l.substring(0,l.length-1),o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.endswith:le.odv4UniOperator.endswith):l.lastIndexOf("%")!==l.indexOf("%")&&l.lastIndexOf("%")>l.indexOf("%")+1?(l=l.substring(l.indexOf("%")+1,l.lastIndexOf("%")),o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains):o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains),l="'"+(l=encodeURIComponent(l))+"'";else if("wildcard"===o)if(-1!==l.indexOf("*")){var d=l.split("*"),u=void 0,f=0;if(0!==l.indexOf("*")&&-1===d[0].indexOf("%3f")&&-1===d[0].indexOf("?")&&(u="'"+(u=d[0])+"'",s+=(o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.startswith:le.odv4UniOperator.startswith)+"(",s+=c+",",a&&(s+=a),s+=u+")",f++),l.lastIndexOf("*")!==l.length-1&&-1===d[d.length-1].indexOf("%3f")&&-1===d[d.length-1].indexOf("?")&&(u="'"+(u=d[d.length-1])+"'",f>0&&(s+=" and "),s+=(o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.endswith:le.odv4UniOperator.endswith)+"(",s+=c+",",a&&(s+=a),s+=u+")",f++),d.length>2)for(var p=1;p0&&(s+=" and "),"substringof"===(o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains)||"not substringof"===o){var g=u;u=c,c=g}s+=o+"(",s+=c+",",a&&(s+=a),s+=u+")",f++}0===f?(o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains,(-1!==l.indexOf("?")||-1!==l.indexOf("%3f"))&&(l=-1!==l.indexOf("?")?l.split("?").join(""):l.split("%3f").join("")),l="'"+l+"'"):o="wildcard"}else o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains,(-1!==l.indexOf("?")||-1!==l.indexOf("%3f"))&&(l=-1!==l.indexOf("?")?l.split("?").join(""):l.split("%3f").join("")),l="'"+l+"'";return"substringof"!==o&&"not substringof"!==o||(g=l,l=c,c=g),"wildcard"!==o&&(s+=o+"(",s+=c+",",a&&(s+=a),s+=l+")"),s},t.prototype.addParams=function(e){n.prototype.addParams.call(this,e),delete e.reqParams.params},t.prototype.onComplexPredicate=function(e,i,r){for(var s=[],o=0;o-1;f--)!/\bContent-ID:/i.test(c[f])||!/\bHTTP.+201/.test(c[f])||(l=parseInt(/\bContent-ID: (\d+)/i.exec(c[f])[1],10),o.addedRecords[l]&&(h=le.parse.parseJson(/^\{.+\}/m.exec(c[f])[0]),ze({},o.addedRecords[l],this.processResponse(h))));return o}return null},t.prototype.compareAndRemove=function(e,i,r){var s=this;return m(i)||Object.keys(e).forEach(function(o){o!==r&&"@odata.etag"!==o&&(le.isPlainObject(e[o])?(s.compareAndRemove(e[o],i[o]),0===Object.keys(e[o]).filter(function(l){return"@odata.etag"!==l}).length&&delete e[o]):(e[o]===i[o]||e[o]&&i[o]&&e[o].valueOf()===i[o].valueOf())&&delete e[o])}),e},t}(fc),TK=function(n){function t(){var e=n.call(this)||this;return yt("beforeSend",fc.prototype.beforeSend,e),e}return Ml(t,n),t.prototype.insert=function(e,i,r,s,o){return this.pvt.position=o,this.updateType="add",{url:e.dataSource.insertUrl||e.dataSource.crudUrl||e.dataSource.url,data:JSON.stringify(ze({},{value:i,table:r,action:"insert"},le.getAddParams(this,e,s)))}},t.prototype.remove=function(e,i,r,s,o){return n.prototype.remove.call(this,e,i,r),{type:"POST",url:e.dataSource.removeUrl||e.dataSource.crudUrl||e.dataSource.url,data:JSON.stringify(ze({},{key:r,keyColumn:i,table:s,action:"remove"},le.getAddParams(this,e,o)))}},t.prototype.update=function(e,i,r,s,o){return this.updateType="update",this.updateKey=i,{type:"POST",url:e.dataSource.updateUrl||e.dataSource.crudUrl||e.dataSource.url,data:JSON.stringify(ze({},{value:r,action:"update",keyColumn:i,key:r[i],table:s},le.getAddParams(this,e,o)))}},t.prototype.processResponse=function(e,i,r,s,o,a,l){var h;if(e="batch"===(o?JSON.parse(o.data):e).action?le.parse.parseJson(e):e,"add"===this.updateType&&n.prototype.insert.call(this,i,e,null,null,this.pvt.position),"update"===this.updateType&&n.prototype.update.call(this,i,this.updateKey,e),this.updateType=void 0,e.added)for(h=0;hi&&h.push(c)}for(c=0;cthis.pageSize;)h.results.splice(0,1),h.keys.splice(0,1);return window.localStorage.setItem(this.guidId,JSON.stringify(h)),e},t.prototype.beforeSend=function(e,i,r){!m(this.cacheAdaptor.options.batch)&&le.endsWith(r.url,this.cacheAdaptor.options.batch)&&"post"===r.type.toLowerCase()&&i.headers.set("Accept",this.cacheAdaptor.options.multipartAccept),e.dataSource.crossDomain||i.headers.set("Accept",this.cacheAdaptor.options.accept)},t.prototype.update=function(e,i,r,s){return this.isCrudAction=!0,this.cacheAdaptor.update(e,i,r,s)},t.prototype.insert=function(e,i,r){return this.isInsertAction=!0,this.cacheAdaptor.insert(e,i,r)},t.prototype.remove=function(e,i,r,s){return this.isCrudAction=!0,this.cacheAdaptor.remove(e,i,r,s)},t.prototype.batchRequest=function(e,i,r){return this.cacheAdaptor.batchRequest(e,i,r)},t}(fc),it=function(){function n(t,e,i){var s,r=this;return this.dateParse=!0,this.timeZoneHandling=!0,this.persistQuery={},this.isInitialLoad=!1,this.requests=[],this.isInitialLoad=!0,!t&&!this.dataSource&&(t=[]),i=i||t.adaptor,t&&!1===t.timeZoneHandling&&(this.timeZoneHandling=t.timeZoneHandling),t instanceof Array?s={json:t,offline:!0}:"object"==typeof t?(t.json||(t.json=[]),t.enablePersistence||(t.enablePersistence=!1),t.id||(t.id=""),t.ignoreOnPersist||(t.ignoreOnPersist=[]),s={url:t.url,insertUrl:t.insertUrl,removeUrl:t.removeUrl,updateUrl:t.updateUrl,crudUrl:t.crudUrl,batchUrl:t.batchUrl,json:t.json,headers:t.headers,accept:t.accept,data:t.data,timeTillExpiration:t.timeTillExpiration,cachingPageSize:t.cachingPageSize,enableCaching:t.enableCaching,requestType:t.requestType,key:t.key,crossDomain:t.crossDomain,jsonp:t.jsonp,dataType:t.dataType,offline:void 0!==t.offline?t.offline:!(t.adaptor instanceof TK||t.adaptor instanceof AK||t.url),requiresFormat:t.requiresFormat,enablePersistence:t.enablePersistence,id:t.id,ignoreOnPersist:t.ignoreOnPersist}):le.throwError("DataManager: Invalid arguments"),void 0===s.requiresFormat&&!le.isCors()&&(s.requiresFormat=!!m(s.crossDomain)||s.crossDomain),void 0===s.dataType&&(s.dataType="json"),this.dataSource=s,this.defaultQuery=e,this.dataSource.enablePersistence&&this.dataSource.id&&window.addEventListener("unload",this.setPersistData.bind(this)),s.url&&s.offline&&!s.json.length?(this.isDataAvailable=!1,this.adaptor=i||new pf,this.dataSource.offline=!1,this.ready=this.executeQuery(e||new _t),this.ready.then(function(o){r.dataSource.offline=!0,r.isDataAvailable=!0,s.json=o.result,r.adaptor=new WE})):this.adaptor=s.offline?new WE:new pf,!s.jsonp&&this.adaptor instanceof pf&&(s.jsonp="callback"),this.adaptor=i||this.adaptor,s.enableCaching&&(this.adaptor=new LK(this.adaptor,s.timeTillExpiration,s.cachingPageSize)),this}return Object.defineProperty(n.prototype,"moduleName",{get:function(){return"datamanager"},enumerable:!0,configurable:!0}),n.prototype.getPersistedData=function(t){var e=localStorage.getItem(t||this.dataSource.id);return JSON.parse(e)},n.prototype.setPersistData=function(t,e,i){localStorage.setItem(e||this.dataSource.id,JSON.stringify(i||this.persistQuery))},n.prototype.setPersistQuery=function(t){var e=this,i=this.getPersistedData();if(this.isInitialLoad&&i&&Object.keys(i).length){this.persistQuery=i,this.persistQuery.queries=this.persistQuery.queries.filter(function(s){if(e.dataSource.ignoreOnPersist&&e.dataSource.ignoreOnPersist.length&&s.fn&&e.dataSource.ignoreOnPersist.some(function(l){return s.fn===l}))return!1;if("onWhere"===s.fn){var o=s.e;if(o&&o.isComplex&&o.predicates instanceof Array){var a=o.predicates.map(function(l){if(l.predicates&&l.predicates instanceof Array){var h=l.predicates.map(function(v){return new Ss(v.field,v.operator,v.value,v.ignoreCase,v.ignoreAccent,v.matchCase)});return"and"===l.condition?Ss.and(h):Ss.or(h)}return new Ss(l.field,l.operator,l.value,l.ignoreCase,l.ignoreAccent,l.matchCase)});s.e=new Ss(a[0],o.condition,a.slice(1))}}return!0});var r=ze(new _t,this.persistQuery);return this.isInitialLoad=!1,r}return this.persistQuery=t,this.isInitialLoad=!1,t},n.prototype.setDefaultQuery=function(t){return this.defaultQuery=t,this},n.prototype.executeLocal=function(t){!this.defaultQuery&&!(t instanceof _t)&&le.throwError("DataManager - executeLocal() : A query is required to execute"),this.dataSource.json||le.throwError("DataManager - executeLocal() : Json data is required to execute"),this.dataSource.enablePersistence&&this.dataSource.id&&(t=this.setPersistQuery(t));var e=this.adaptor.processQuery(this,t=t||this.defaultQuery);if(t.subQuery){var i=t.subQuery.fromTable,r=t.subQuery.lookups,s=t.isCountRequired?e.result:e;r&&r instanceof Array&&le.buildHierarchy(t.subQuery.fKey,i,s,r,t.subQuery.key);for(var o=0;oli");z.classList.remove("json-parent");for(var j=0;j',W=ve.children[0].placeholder}return W}function Q(k,W,ve){!m(ve)&&""!==ve&&K(W,ve.split(" ")),!m(k)&&""!==k&&V(W,k.split(" "))}function oe(k,W,ve){if("multiselect"===ve||function Mo(k){if(!k)return!1;for(var W=k;W&&W!==document.body;){if("none"===window.getComputedStyle(W).display)return!1;W=W.parentElement}return!0}(k)){var Te="multiselect"===ve?k:k.clientWidth-parseInt(getComputedStyle(k,null).getPropertyValue("padding-left"),10);!m(W)&&!m(W.getElementsByClassName("e-float-text-content")[0])&&(W.getElementsByClassName("e-float-text-content")[0].classList.contains("e-float-text-overflow")&&W.getElementsByClassName("e-float-text-content")[0].classList.remove("e-float-text-overflow"),(Te0)for(var Ye=0;Ye<_e.length;Ye++)_e[parseInt(Ye.toString(),10)].addEventListener("mousedown",wo,!1),_e[parseInt(Ye.toString(),10)].addEventListener("mouseup",Ul,!1);else if(_e.length>0)for(Ye=0;Ye<_e.length;Ye++)_e[parseInt(Ye.toString(),10)].removeEventListener("mousedown",wo,this),_e[parseInt(Ye.toString(),10)].removeEventListener("mouseup",Ul,this)}function wo(){for(var W=this.parentElement;!W.classList.contains("e-input-group");)W=W.parentElement;!function Sa(k,W){!k.classList.contains("e-disabled")&&!k.querySelector("input").readOnly&&W.classList.add("e-input-btn-ripple")}(W,this)}function Ul(){var k=this;setTimeout(function(){k.classList.remove("e-input-btn-ripple")},500)}function gb(k,W){var ve=W("span",{className:k});return ve.classList.add("e-input-group-icon"),ve}function y_(k,W,ve,Te){var _e=m(Te)?Si:Te,Ye=gb(k,_e);W.classList.add("e-float-icon-left");var vi=W.querySelector(".e-input-in-wrap");if(m(vi)){vi=_e("span",{className:"e-input-in-wrap"}),ve.parentNode.insertBefore(vi,ve);var Gs=W.querySelectorAll(ve.tagName+" ~ *");vi.appendChild(ve);for(var ts=0;ts-1)if("class"===_e){var Ye=this.getInputValidClassList(k[""+_e]);""!==Ye&&V([W],Ye.split(" "))}else if("style"===_e){var vi=W.getAttribute(_e);vi=m(vi)?k[""+_e]:vi+k[""+_e],W.setAttribute(_e,vi)}else W.setAttribute(_e,k[""+_e])}},n.isBlank=function Hle(k){return!k||/^\s*$/.test(k)}}(Le||(Le={})),new RegExp("^(-)?(\\d*)$"),new RegExp("^[A-Za-z0-9._%+-]{1,}@[A-Za-z0-9._%+-]{1,}([.]{1}[a-zA-Z0-9]{2,}|[.]{1}[a-zA-Z0-9]{2,4}[.]{1}[a-zA-Z0-9]{2,4})$"),new RegExp("^([0-9]{4})-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])$"),new RegExp("^[0-9]*$"),new RegExp("^[+]?[0-9]{9,13}$"),new RegExp("^\\d{13,16}$");var me=function(){function n(t,e){this.width=t,this.height=e}return n.prototype.isEmpty=function(){return 0===this.height&&0===this.width},n.prototype.clone=function(){return new n(this.width,this.height)},n}(),Eie=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),GB=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},R=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Eie(t,n),t.equals=function(e,i){return e===i||!(!e||!i)&&(!e||!i||e.x===i.x&&e.y===i.y)},t.isEmptyPoint=function(e){return!(e.x&&e.y)},t.transform=function(e,i,r){var s={x:0,y:0};return s.x=Math.round(100*(e.x+r*Math.cos(i*Math.PI/180)))/100,s.y=Math.round(100*(e.y+r*Math.sin(i*Math.PI/180)))/100,s},t.findLength=function(e,i){return Math.sqrt(Math.pow(e.x-i.x,2)+Math.pow(e.y-i.y,2))},t.findAngle=function(e,i){var r=Math.atan2(i.y-e.y,i.x-e.x);return r=180*r/Math.PI,(r%=360)<0&&(r+=360),r},t.distancePoints=function(e,i){return Math.sqrt(Math.pow(i.x-e.x,2)+Math.pow(i.y-e.y,2))},t.getLengthFromListOfPoints=function(e){for(var i=0,r=0;ri.y&&!r?o.y+=s:o.y-=s:e.y===i.y?e.xi.x&&!r?o.x+=s:o.x-=s:r?(a=this.findAngle(e,i),o=this.transform(e,a,s)):(a=this.findAngle(i,e),o=this.transform(i,a,s)),o},t.direction=function(e,i){return Math.abs(i.x-e.x)>Math.abs(i.y-e.y)?e.x0)for(var r=0;rt.right||this.top>t.bottom||this.bottom=t.right&&this.top<=t.top&&this.bottom>=t.bottom},n.prototype.containsPoint=function(t,e){return void 0===e&&(e=0),this.left-e<=t.x&&this.right+e>=t.x&&this.top-e<=t.y&&this.bottom+e>=t.y},n.toBounds=function(t){for(var e=new n,i=0,r=t;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},KB=function(n){if(n)switch(n.type){case"Linear":default:return yI;case"Radial":return Rie}return yI},Pie=function(){return function n(t,e,i,r){this.left=t,this.right=e,this.top=i,this.bottom=r}}(),Jn=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),rt([I(0)],t.prototype,"left",void 0),rt([I(0)],t.prototype,"right",void 0),rt([I(0)],t.prototype,"top",void 0),rt([I(0)],t.prototype,"bottom",void 0),t}(Ee),zie=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),rt([I(45)],t.prototype,"angle",void 0),rt([I(5)],t.prototype,"distance",void 0),rt([I(.7)],t.prototype,"opacity",void 0),rt([I("lightgrey")],t.prototype,"color",void 0),t}(Ee),e3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),t.prototype.getClassName=function(){return"Stop"},rt([I("")],t.prototype,"color",void 0),rt([I(0)],t.prototype,"offset",void 0),rt([I(1)],t.prototype,"opacity",void 0),t}(Ee),Ix=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),rt([Bt([],e3)],t.prototype,"stops",void 0),rt([I("None")],t.prototype,"type",void 0),rt([I("")],t.prototype,"id",void 0),t}(Ee),yI=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),rt([I(0)],t.prototype,"x1",void 0),rt([I(0)],t.prototype,"x2",void 0),rt([I(0)],t.prototype,"y1",void 0),rt([I(0)],t.prototype,"y2",void 0),t}(Ix),Rie=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),rt([I(0)],t.prototype,"cx",void 0),rt([I(0)],t.prototype,"cy",void 0),rt([I(0)],t.prototype,"fx",void 0),rt([I(0)],t.prototype,"fy",void 0),rt([I(50)],t.prototype,"r",void 0),t}(Ix),Ll=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),rt([I("white")],t.prototype,"fill",void 0),rt([I("black")],t.prototype,"strokeColor",void 0),rt([I("")],t.prototype,"strokeDashArray",void 0),rt([I(1)],t.prototype,"strokeWidth",void 0),rt([I(1)],t.prototype,"opacity",void 0),rt([E0(KB)],t.prototype,"gradient",void 0),t}(Ee),t3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),rt([I("transparent")],t.prototype,"fill",void 0),t}(Ll),Qf=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),rt([I("black")],t.prototype,"color",void 0),rt([I("Arial")],t.prototype,"fontFamily",void 0),rt([I(12)],t.prototype,"fontSize",void 0),rt([I(!1)],t.prototype,"italic",void 0),rt([I(!1)],t.prototype,"bold",void 0),rt([I("CollapseSpace")],t.prototype,"whiteSpace",void 0),rt([I("WrapWithOverflow")],t.prototype,"textWrapping",void 0),rt([I("Center")],t.prototype,"textAlign",void 0),rt([I("None")],t.prototype,"textDecoration",void 0),rt([I("Wrap")],t.prototype,"textOverflow",void 0),rt([I("transparent")],t.prototype,"fill",void 0),t}(Ll),on=function(n){return n[n.Default=0]="Default",n[n.expandNode=2]="expandNode",n[n.interaction=4]="interaction",n[n.GroupingInProgress=8]="GroupingInProgress",n[n.GroupClipboardInProcess=16]="GroupClipboardInProcess",n[n.ClearObject=32]="ClearObject",n}(on||{}),Gt=function(n){return n[n.Visible=1]="Visible",n[n.Hidden=2]="Hidden",n[n.Hover=4]="Hover",n[n.Connect=8]="Connect",n}(Gt||{}),ei=function(n){return n[n.None=0]="None",n[n.ShowHorizontalLines=1]="ShowHorizontalLines",n[n.ShowVerticalLines=2]="ShowVerticalLines",n[n.ShowLines=3]="ShowLines",n[n.SnapToHorizontalLines=4]="SnapToHorizontalLines",n[n.SnapToVerticalLines=8]="SnapToVerticalLines",n[n.SnapToLines=12]="SnapToLines",n[n.SnapToObject=16]="SnapToObject",n[n.All=31]="All",n}(ei||{}),mr=function(n){return n[n.None=1]="None",n[n.ConnectorSourceThumb=2]="ConnectorSourceThumb",n[n.ConnectorTargetThumb=4]="ConnectorTargetThumb",n[n.ResizeSouthEast=8]="ResizeSouthEast",n[n.ResizeSouthWest=16]="ResizeSouthWest",n[n.ResizeNorthEast=32]="ResizeNorthEast",n[n.ResizeNorthWest=64]="ResizeNorthWest",n[n.ResizeEast=128]="ResizeEast",n[n.ResizeWest=256]="ResizeWest",n[n.ResizeSouth=512]="ResizeSouth",n[n.ResizeNorth=1024]="ResizeNorth",n[n.Rotate=2048]="Rotate",n[n.UserHandle=4096]="UserHandle",n[n.ToolTip=8192]="ToolTip",n[n.ResizeAll=2046]="ResizeAll",n[n.All=16382]="All",n}(mr||{}),qe=function(n){return n[n.None=1]="None",n[n.Select=2]="Select",n[n.Delete=4]="Delete",n[n.Drag=8]="Drag",n[n.DragSourceEnd=16]="DragSourceEnd",n[n.DragTargetEnd=32]="DragTargetEnd",n[n.DragSegmentThumb=64]="DragSegmentThumb",n[n.AllowDrop=128]="AllowDrop",n[n.Bridging=256]="Bridging",n[n.BridgeObstacle=512]="BridgeObstacle",n[n.InheritBridging=1024]="InheritBridging",n[n.PointerEvents=2048]="PointerEvents",n[n.Tooltip=4096]="Tooltip",n[n.InheritTooltip=8192]="InheritTooltip",n[n.Interaction=4218]="Interaction",n[n.ReadOnly=16384]="ReadOnly",n[n.LineRouting=32768]="LineRouting",n[n.InheritLineRouting=65536]="InheritLineRouting",n[n.ConnectToNearByNode=131072]="ConnectToNearByNode",n[n.ConnectToNearByPort=262144]="ConnectToNearByPort",n[n.ConnectToNearByElement=393216]="ConnectToNearByElement",n[n.InheritSegmentThumbShape=524288]="InheritSegmentThumbShape",n[n.InheritSegmentThumbSize=1048576]="InheritSegmentThumbSize",n[n.Default=2043454]="Default",n}(qe||{}),Nr=function(n){return n[n.ReadOnly=2]="ReadOnly",n[n.InheritReadOnly=4]="InheritReadOnly",n[n.Select=8]="Select",n[n.Drag=16]="Drag",n[n.Resize=32]="Resize",n[n.Rotate=64]="Rotate",n[n.Tooltip=128]="Tooltip",n[n.Interaction=120]="Interaction",n[n.None=0]="None",n}(Nr||{}),ie=function(n){return n[n.None=0]="None",n[n.Select=2]="Select",n[n.Drag=4]="Drag",n[n.Rotate=8]="Rotate",n[n.Shadow=16]="Shadow",n[n.PointerEvents=32]="PointerEvents",n[n.Delete=64]="Delete",n[n.InConnect=128]="InConnect",n[n.OutConnect=256]="OutConnect",n[n.Individual=512]="Individual",n[n.Expandable=1024]="Expandable",n[n.AllowDrop=2048]="AllowDrop",n[n.Inherit=78]="Inherit",n[n.ResizeNorthEast=4096]="ResizeNorthEast",n[n.ResizeEast=8192]="ResizeEast",n[n.ResizeSouthEast=16384]="ResizeSouthEast",n[n.ResizeSouth=32768]="ResizeSouth",n[n.ResizeSouthWest=65536]="ResizeSouthWest",n[n.ResizeWest=131072]="ResizeWest",n[n.ResizeNorthWest=262144]="ResizeNorthWest",n[n.ResizeNorth=524288]="ResizeNorth",n[n.Resize=1044480]="Resize",n[n.AspectRatio=1048576]="AspectRatio",n[n.Tooltip=2097152]="Tooltip",n[n.InheritTooltip=4194304]="InheritTooltip",n[n.ReadOnly=8388608]="ReadOnly",n[n.HideThumbs=16777216]="HideThumbs",n[n.AllowMovingOutsideLane=33554432]="AllowMovingOutsideLane",n[n.Default=5240814]="Default",n}(ie||{}),Xr=function(n){return n[n.None=0]="None",n[n.ElementIsPort=2]="ElementIsPort",n[n.ElementIsGroup=4]="ElementIsGroup",n[n.HorizontalLaneHeader=8]="HorizontalLaneHeader",n}(Xr||{}),bt=function(n){return n[n.Rotate=2]="Rotate",n[n.ConnectorSource=4]="ConnectorSource",n[n.ConnectorTarget=8]="ConnectorTarget",n[n.ResizeNorthEast=16]="ResizeNorthEast",n[n.ResizeEast=32]="ResizeEast",n[n.ResizeSouthEast=64]="ResizeSouthEast",n[n.ResizeSouth=128]="ResizeSouth",n[n.ResizeSouthWest=256]="ResizeSouthWest",n[n.ResizeWest=512]="ResizeWest",n[n.ResizeNorthWest=1024]="ResizeNorthWest",n[n.ResizeNorth=2048]="ResizeNorth",n[n.Default=4094]="Default",n}(bt||{}),nt=function(n){return n[n.None=1]="None",n[n.Bridging=2]="Bridging",n[n.UndoRedo=4]="UndoRedo",n[n.Tooltip=8]="Tooltip",n[n.UserInteraction=16]="UserInteraction",n[n.ApiUpdate=32]="ApiUpdate",n[n.PageEditable=48]="PageEditable",n[n.Zoom=64]="Zoom",n[n.PanX=128]="PanX",n[n.PanY=256]="PanY",n[n.Pan=384]="Pan",n[n.ZoomTextEdit=512]="ZoomTextEdit",n[n.Virtualization=1024]="Virtualization",n[n.LineRouting=2048]="LineRouting",n[n.Default=500]="Default",n}(nt||{}),ni=function(n){return n[n.None=0]="None",n[n.SingleSelect=1]="SingleSelect",n[n.MultipleSelect=2]="MultipleSelect",n[n.ZoomPan=4]="ZoomPan",n[n.DrawOnce=8]="DrawOnce",n[n.ContinuousDraw=16]="ContinuousDraw",n[n.Default=3]="Default",n}(ni||{}),Qa=function(n){return n[n.Self=1]="Self",n[n.Parent=2]="Parent",n}(Qa||{}),ft=function(n){return n[n.None=0]="None",n[n.Control=1]="Control",n[n.Meta=1]="Meta",n[n.Alt=2]="Alt",n[n.Shift=4]="Shift",n}(ft||{}),Mt=function(n){return n[n.None=null]="None",n[n.Number0=0]="Number0",n[n.Number1=1]="Number1",n[n.Number2=2]="Number2",n[n.Number3=3]="Number3",n[n.Number4=4]="Number4",n[n.Number5=5]="Number5",n[n.Number6=6]="Number6",n[n.Number7=7]="Number7",n[n.Number8=8]="Number8",n[n.Number9=9]="Number9",n[n.A=65]="A",n[n.B=66]="B",n[n.C=67]="C",n[n.D=68]="D",n[n.E=69]="E",n[n.F=70]="F",n[n.G=71]="G",n[n.H=72]="H",n[n.I=73]="I",n[n.J=74]="J",n[n.K=75]="K",n[n.L=76]="L",n[n.M=77]="M",n[n.N=78]="N",n[n.O=79]="O",n[n.P=80]="P",n[n.Q=81]="Q",n[n.R=82]="R",n[n.S=83]="S",n[n.T=84]="T",n[n.U=85]="U",n[n.V=86]="V",n[n.W=87]="W",n[n.X=88]="X",n[n.Y=89]="Y",n[n.Z=90]="Z",n[n.Left=37]="Left",n[n.Up=38]="Up",n[n.Right=39]="Right",n[n.Down=40]="Down",n[n.Escape=27]="Escape",n[n.Space=32]="Space",n[n.PageUp=33]="PageUp",n[n.PageDown=34]="PageDown",n[n.End=35]="End",n[n.Home=36]="Home",n[n.Delete=46]="Delete",n[n.Tab=9]="Tab",n[n.Enter=13]="Enter",n[n.BackSpace=8]="BackSpace",n[n.F1=112]="F1",n[n.F2=113]="F2",n[n.F3=114]="F3",n[n.F4=115]="F4",n[n.F5=116]="F5",n[n.F6=117]="F6",n[n.F7=118]="F7",n[n.F8=119]="F8",n[n.F9=120]="F9",n[n.F10=121]="F10",n[n.F11=122]="F11",n[n.F12=123]="F12",n[n.Star=56]="Star",n[n.Plus=187]="Plus",n[n.Minus=189]="Minus",n[n.BracketLeft=219]="BracketLeft",n[n.BracketRight=221]="BracketRight",n}(Mt||{}),ee=function(n){return n[n.Render=2]="Render",n[n.PublicMethod=4]="PublicMethod",n[n.ToolAction=8]="ToolAction",n[n.UndoRedo=16]="UndoRedo",n[n.TextEdit=32]="TextEdit",n[n.Group=64]="Group",n[n.Clear=128]="Clear",n[n.PreventClearSelection=256]="PreventClearSelection",n[n.Interactions=512]="Interactions",n[n.PreventHistory=1024]="PreventHistory",n[n.PreventIconsUpdate=2048]="PreventIconsUpdate",n[n.PreventCollectionChangeOnDragOver=4096]="PreventCollectionChangeOnDragOver",n[n.PreventZIndexOnDragging=8192]="PreventZIndexOnDragging",n[n.isGroupDragging=16384]="isGroupDragging",n[n.DragUsingMouse=32768]="DragUsingMouse",n[n.DecoratorPropertyChange=65536]="DecoratorPropertyChange",n[n.PreventLaneContainerUpdate=131072]="PreventLaneContainerUpdate",n}(ee||{}),Ga=function(n){return n[n.None=2]="None",n[n.DrawSelectorBorder=4]="DrawSelectorBorder",n[n.PreventRenderSelector=8]="PreventRenderSelector",n}(Ga||{}),$i=function(n){return n[n.None=0]="None",n[n.PreventDrag=2]="PreventDrag",n[n.PreventScale=4]="PreventScale",n[n.PreventDataInit=8]="PreventDataInit",n[n.hScrollbarMoved=16]="hScrollbarMoved",n[n.vScrollbarMoved=32]="vScrollbarMoved",n[n.AnimationClick=64]="AnimationClick",n[n.EnableGroupAction=128]="EnableGroupAction",n[n.PanInProgress=256]="PanInProgress",n[n.OverViewAction=512]="OverViewAction",n}($i||{}),da=function(n){return n[n.None=0]="None",n[n.PropertyChange=1024]="PropertyChange",n[n.Interaction=2048]="Interaction",n}(da||{}),Ae=function(n){return n[n.Zero=0]="Zero",n[n.One=1]="One",n[n.Two=2]="Two",n[n.Three=3]="Three",n[n.Four=4]="Four",n[n.Five=5]="Five",n}(Ae||{}),Ce=function(n){return n[n.collectionChange=0]="collectionChange",n[n.rotateChange=1]="rotateChange",n[n.positionChange=2]="positionChange",n[n.propertyChange=3]="propertyChange",n[n.selectionChange=4]="selectionChange",n[n.sizeChange=5]="sizeChange",n[n.drop=6]="drop",n[n.sourcePointChange=7]="sourcePointChange",n[n.targetPointChange=8]="targetPointChange",n[n.connectionChange=9]="connectionChange",n[n.animationComplete=10]="animationComplete",n[n.click=11]="click",n[n.doubleClick=12]="doubleClick",n[n.scrollChange=13]="scrollChange",n[n.dragEnter=14]="dragEnter",n[n.dragLeave=15]="dragLeave",n[n.dragOver=16]="dragOver",n[n.textEdit=17]="textEdit",n[n.paletteSelectionChange=18]="paletteSelectionChange",n[n.historyChange=19]="historyChange",n[n.mouseEnter=20]="mouseEnter",n[n.mouseLeave=21]="mouseLeave",n[n.mouseOver=22]="mouseOver",n[n.expandStateChange=23]="expandStateChange",n[n.segmentCollectionChange=24]="segmentCollectionChange",n[n.commandExecute=25]="commandExecute",n[n.historyStateChange=26]="historyStateChange",n[n.onUserHandleMouseDown=27]="onUserHandleMouseDown",n[n.onUserHandleMouseUp=28]="onUserHandleMouseUp",n[n.onUserHandleMouseEnter=29]="onUserHandleMouseEnter",n[n.onUserHandleMouseLeave=30]="onUserHandleMouseLeave",n[n.onImageLoad=31]="onImageLoad",n[n.onDoBindingInit=32]="onDoBindingInit",n[n.keyUp=33]="keyUp",n[n.keyDown=34]="keyDown",n[n.fixedUserHandleClick=35]="fixedUserHandleClick",n[n.elementDraw=36]="elementDraw",n[n.mouseWheel=37]="mouseWheel",n[n.segmentChange=38]="segmentChange",n[n.onFixedUserHandleMouseDown=39]="onFixedUserHandleMouseDown",n[n.onFixedUserHandleMouseUp=40]="onFixedUserHandleMouseUp",n[n.onFixedUserHandleMouseEnter=41]="onFixedUserHandleMouseEnter",n[n.onFixedUserHandleMouseLeave=42]="onFixedUserHandleMouseLeave",n[n.loaded=43]="loaded",n}(Ce||{}),ai=function(n){return n[n.None=1]="None",n[n.Drag=2]="Drag",n[n.Draw=4]="Draw",n[n.InConnect=8]="InConnect",n[n.OutConnect=16]="OutConnect",n[n.ToolTip=32]="ToolTip",n[n.InheritTooltip=64]="InheritTooltip",n[n.Default=24]="Default",n}(ai||{}),bx=function(n){return n[n.None=1]="None",n[n.Source=2]="Source",n[n.Target=4]="Target",n[n.Intermediate=8]="Intermediate",n[n.All=14]="All",n}(bx||{}),SI=function(n){return n[n.None=0]="None",n[n.SymmetricAngle=2]="SymmetricAngle",n[n.SymmetricDistance=4]="SymmetricDistance",n[n.Default=6]="Default",n}(SI||{}),hs=function(){function n(){this.pivot={x:.5,y:.5},this.isDirt=!0,this.isExport=!1,this.exportScaleValue={x:0,y:0},this.exportScaleOffset={x:0,y:0},this.canApplyStyle=!0,this.visible=!0,this.offsetX=0,this.offsetY=0,this.cornerRadius=0,this.minHeight=void 0,this.minWidth=void 0,this.maxWidth=void 0,this.maxHeight=void 0,this.width=void 0,this.height=void 0,this.rotateAngle=0,this.margin={left:0,right:0,top:0,bottom:0},this.connectionDirection="Auto",this.horizontalAlignment="Auto",this.verticalAlignment="Auto",this.flip="None",this.flipMode="All",this.relativeMode="Point",this.transform=Qa.Self|Qa.Parent,this.style={fill:"white",strokeColor:"black",opacity:1,strokeWidth:1},this.desiredSize=new me,this.actualSize=new me,this.parentTransform=0,this.preventContainer=!1,this.isSvgRender=!1,this.bounds=new Ne(0,0,0,0),this.shadow=null,this.description="",this.staticSize=!1,this.shapeType="",this.isRectElement=!1,this.isCalculateDesiredSize=!0,this.flipOffset={x:0,y:0},this.elementActions=Xr.None,this.inversedAlignment=!0,this.position=void 0,this.unitMode=void 0,this.float=!1,this.floatingBounds=void 0}return n.prototype.setOffsetWithRespectToBounds=function(t,e,i){this.unitMode=i,this.position={x:t,y:e}},n.prototype.getAbsolutePosition=function(t){if(void 0!==this.position)return"Absolute"===this.unitMode?this.position:{x:this.position.x*t.width,y:this.position.y*t.height}},Object.defineProperty(n.prototype,"outerBounds",{get:function(){return this.floatingBounds||this.bounds},set:function(t){this.floatingBounds=t},enumerable:!0,configurable:!0}),n.prototype.measure=function(t,e,i){var s=void 0!==this.height?this.height:(t.height||0)-this.margin.top-this.margin.bottom;return this.id&&0===s&&this.elementActions&Xr.HorizontalLaneHeader&&(s=this.actualSize.height),this.desiredSize=new me(void 0!==this.width?this.width:(t.width||0)-this.margin.left-this.margin.right,s),this.isCalculateDesiredSize&&(this.desiredSize=this.validateDesiredSize(this.desiredSize,t)),this.desiredSize},n.prototype.arrange=function(t){return this.actualSize=t,this.updateBounds(),this.actualSize},n.prototype.updateBounds=function(){this.bounds=yr(this)},n.prototype.validateDesiredSize=function(t,e){return this.isRectElement&&!this.width&&!this.minWidth&&!this.maxWidth&&(t.width=50),this.isRectElement&&!this.height&&!this.minHeight&&!this.maxHeight&&(t.height=50),(void 0===t||void 0!==this.width&&void 0!==this.height)&&((t=t||new me).width=void 0===this.width?(e.width||0)-this.margin.left-this.margin.right:this.width,t.height=void 0===this.height?(e.height||0)-this.margin.top-this.margin.bottom:this.height),void 0!==this.minWidth&&(t.width=Math.max(t.width,this.minWidth)),void 0!==this.minHeight&&(t.height=Math.max(t.height,this.minHeight)),void 0!==this.maxWidth&&0!==this.maxWidth&&(t.width=Math.min(t.width,this.maxWidth)),void 0!==this.maxHeight&&0!==this.maxHeight&&(t.height=Math.min(t.height,this.maxHeight)),t},n}(),Vie=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Cs=function(n){function t(){var e=null!==n&&n.apply(this,arguments)||this;return e.padding=new Pie(0,0,0,0),e.desiredBounds=void 0,e.measureChildren=!0,e.prevRotateAngle=0,e}return Vie(t,n),t.prototype.hasChildren=function(){return void 0!==this.children&&this.children.length>0},t.prototype.measure=function(e,i,r){this.desiredBounds=void 0;var o,a,s=void 0;if(this.hasChildren()){for(var l=0;l=n.width&&s.length>0)i[i.length]={text:s,x:0,dy:0,width:o},s="";else{(s+=a[r+1]||"").indexOf("\n")>-1&&(i[i.length]={text:s,x:0,dy:0,width:Bc(s,n)},s="");var l=Bc(s,n);Math.ceil(l)+2>=n.width&&s.length>0&&(i[i.length]={text:s,x:0,dy:0,width:l},s=""),r===a.length-1&&s.length>0&&(i[i.length]={text:s,x:0,dy:0,width:l},s="")}else i=function loe(n,t,e){var c,d,u,f,i=[],r="",s=0,o=0,a="nowrap"!==n.whiteSpace,h=(t||n.content).split("\n");for(s=0;s0?" ":"")+c[parseInt(o.toString(),10)];var p=Bc(d=c[o+1]?r+" "+c[o+1]:r,n);Math.floor(p)>(e||n.width)-2&&r.length>0?(i[i.length]={text:r,x:0,dy:0,width:d===r?p:r===f?u:Bc(r,n)},r=""):o===c.length-1&&(i[i.length]={text:r,x:0,dy:0,width:p},r=""),f=d,u=p}return i}(n,t,e);else i[i.length]={text:a,x:0,dy:0,width:Bc(a,n)};return i}(l,r,n.isLaneOrientation?i:void 0),n.wrapBounds=a=function hoe(n,t){var r,s,e={x:0,width:0},i=0;for(i=0;in.width&&("Ellipsis"===n.textOverflow||"Clip"===n.textOverflow)?0:-r/2:"right"===n.textAlign?-r:t.length>1?0:-r/2,t[parseInt(i.toString(),10)].dy=1.2*n.fontSize,t[parseInt(i.toString(),10)].x=r,e.x=Math.min(e.x,r),e.width=Math.max(e.width,s);return e}(l,o),s.width=a.width,n.wrapBounds.width>=i&&"Wrap"!==l.textOverflow&&(s.width=i),s.height=o.length*n.style.fontSize*1.2,s}(this,0,0,this.isLaneOrientation?e.height:this.width||e.width):this.desiredSize,this.desiredSize=void 0===this.width||void 0===this.height?new me(i.width,i.height):new me(this.width,this.height),this.desiredSize=this.validateDesiredSize(this.desiredSize,e),this.desiredSize},t.prototype.arrange=function(e){return(e.width!==this.actualSize.width||e.height!==this.actualSize.height||this.isDirt)&&(this.doWrap=!0),this.actualSize=e,this.updateBounds(),this.isDirt=!1,this.actualSize},t}(hs),Yie=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Mi=function(n){function t(){var e=null!==n&&n.apply(this,arguments)||this;return e.measureChildren=void 0,e}return Yie(t,n),t.prototype.measure=function(e,i,r){var s=void 0,o=void 0;if(this.hasChildren()){for(var a=0,l=this.children;a=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Dd=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return $ie(t,n),Oh([I("")],t.prototype,"content",void 0),Oh([I("TopLeft")],t.prototype,"position",void 0),Oh([I("Mouse")],t.prototype,"relativeMode",void 0),Oh([I(!0)],t.prototype,"showTipPointer",void 0),Oh([I("auto")],t.prototype,"width",void 0),Oh([I("auto")],t.prototype,"height",void 0),Oh([I("Auto")],t.prototype,"openOn",void 0),Oh([I()],t.prototype,"animation",void 0),Oh([I(!1)],t.prototype,"isSticky",void 0),t}(Ee);function i3(n){var t=new bh;t=r3(n.tooltip,t);var e=new bh(t);return e.beforeCollision=Jie,e.beforeOpen=Zie,e.cssClass="e-diagram-tooltip",e.opensOn="custom",e.appendTo("#"+n.element.id),e.close(),e}function Zie(n){(""===this.content||void 0===this.content)&&(n.element.style.display="none")}function Jie(n){n.collidedPosition&&n.collidedPosition!==this.position&&(n.element.style.display="none")}function Mx(n,t){var e=n.tooltipObject;return r3(t?t.tooltip:n.tooltip,e),e}function r3(n,t){return n.content?(t.content=n.content,"string"==typeof n.content&&(t.content=ko(function(){return n.content})),t.position=n.position,t.showTipPointer=n.showTipPointer,t.width=n.width,t.height=n.height,t.animation=n.animation?n.animation:{close:{effect:"None"}}):t.close(),t}var wx=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Bn=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Cx=function(n){function t(e,i,r,s){var o=n.call(this,e,i,r,s)||this;return o.inEdges=[],o.outEdges=[],o}return wx(t,n),Bn([I("")],t.prototype,"id",void 0),Bn([I("Center")],t.prototype,"horizontalAlignment",void 0),Bn([I("Center")],t.prototype,"verticalAlignment",void 0),Bn([re({},Jn)],t.prototype,"margin",void 0),Bn([I(12)],t.prototype,"width",void 0),Bn([I(12)],t.prototype,"height",void 0),Bn([re({},Ll)],t.prototype,"style",void 0),Bn([I("Square")],t.prototype,"shape",void 0),Bn([I("Auto")],t.prototype,"connectionDirection",void 0),Bn([I(Gt.Connect)],t.prototype,"visibility",void 0),Bn([I("")],t.prototype,"pathData",void 0),Bn([I(ai.Default)],t.prototype,"constraints",void 0),Bn([I()],t.prototype,"addInfo",void 0),Bn([I()],t.prototype,"outEdges",void 0),Bn([I()],t.prototype,"inEdges",void 0),Bn([re({},Dd)],t.prototype,"tooltip",void 0),t}(Ee),Es=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return wx(t,n),t.prototype.getClassName=function(){return"PointPort"},Bn([re({x:.5,y:.5},R)],t.prototype,"offset",void 0),t}(Cx),Tc=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return wx(t,n),t.prototype.getClassName=function(){return"PathPort"},Bn([I(.5)],t.prototype,"offset",void 0),Bn([re({x:0,y:0},R)],t.prototype,"displacement",void 0),Bn([I("Center")],t.prototype,"alignment",void 0),t}(Cx),MI=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),lr=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Kie=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return MI(t,n),lr([I("blue")],t.prototype,"color",void 0),lr([I("")],t.prototype,"content",void 0),lr([I("")],t.prototype,"link",void 0),lr([I("None")],t.prototype,"textDecoration",void 0),lr([I("NewTab")],t.prototype,"hyperlinkOpenState",void 0),t}(Ee),Ex=function(n){function t(e,i,r,s){var o=n.call(this,e,i,r,s)||this;return r.id||(o.id=e.parentObj&&e.parentObj.propName&&"phases"===e.parentObj.propName?e.parentObj.id:Qe()),o}return MI(t,n),lr([I("")],t.prototype,"content",void 0),lr([I(void 0)],t.prototype,"template",void 0),lr([I("String")],t.prototype,"annotationType",void 0),lr([I(!0)],t.prototype,"visibility",void 0),lr([I(Nr.InheritReadOnly)],t.prototype,"constraints",void 0),lr([re(void 0,Kie)],t.prototype,"hyperlink",void 0),lr([I("")],t.prototype,"id",void 0),lr([I()],t.prototype,"width",void 0),lr([I()],t.prototype,"height",void 0),lr([I(0)],t.prototype,"rotateAngle",void 0),lr([I("Parent")],t.prototype,"rotationReference",void 0),lr([re({strokeWidth:0,strokeColor:"transparent",fill:"transparent"},Qf)],t.prototype,"style",void 0),lr([I("Center")],t.prototype,"horizontalAlignment",void 0),lr([I("Center")],t.prototype,"verticalAlignment",void 0),lr([re({},Jn)],t.prototype,"margin",void 0),lr([re({top:void 0,bottom:void 0,left:void 0,right:void 0},Jn)],t.prototype,"dragLimit",void 0),lr([I("Shape")],t.prototype,"type",void 0),lr([re({},Dd)],t.prototype,"tooltip",void 0),lr([I()],t.prototype,"addInfo",void 0),t}(Ee),Kn=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return MI(t,n),t.prototype.getClassName=function(){return"ShapeAnnotation"},lr([re({x:.5,y:.5},R)],t.prototype,"offset",void 0),t}(Ex),Or=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return MI(t,n),t.prototype.getClassName=function(){return"PathAnnotation"},lr([I(.5)],t.prototype,"offset",void 0),lr([re({x:0,y:0},R)],t.prototype,"displacement",void 0),lr([I("Center")],t.prototype,"alignment",void 0),lr([I(!1)],t.prototype,"segmentAngle",void 0),t}(Ex);function Dx(n){return rre[n.toString()]}function n3(n){return ore[""+n]}var rre={X:"M14,14 L106,106 M106,14 L14,106",Circle:"M0,50 A50,50,0 1 1 100,50 A50,50,0 1 1 0,50 Z",Square:"M0,0 L10,0 L10,10 L0,10 z"},nre={OpenArrow:"M15.9,23 L5,16 L15.9,9 L17,10.7 L8.7,16 L17,21.3Z",Square:"M0,0 L10,0 L10,10 L0,10 z",Fletch:"M14.8,10c0,0-3.5,6,0.2,12c0,0-2.5-6-10.9-6C4.1,16,11.3,16,14.8,10z",OpenFetch:"M6,17c-0.6,0-1-0.4-1-1s0.4-1,1-1c10.9,0,11-5,11-5c0-0.6,0.4-1,1-1s1,0.4,1,1C19,10.3,18.9,17,6,17C6,17,6,17,6,17z M18,23c-0.5,0-1-0.4-1-1c0-0.2-0.3-5-11-5c-0.6,0-1-0.5-1-1s0.4-1,1-1c0,0,0,0,0,0c12.9,0,13,6.7,13,7 C19,22.6,18.6,23,18,23z",IndentedArrow:"M17,10c0,0-4.5,5.5,0,12L5,16L17,10z",OutdentedArrow:"M14.6,10c0,0,5.4,6,0,12L5,16L14.6,10z",DoubleArrow:"M19,10 L19,22 L13,16Z M12,10 L12,22 L6,16Z",Arrow:"M15,10 L15,22 L5,16Z",Diamond:"M12,23l-7-7l7-7l6.9,7L12,23z",Circle:"M0,50 A50,50,0 1 1 100,50 A50,50,0 1 1 0,50 Z"},sre={Square:"M0,0 L10,0 L10,10 L0,10 z",Rhombus:"M10,5 L5,10 L0,5 L5,0 L10,5 Z ",Rectangle:"M0,0 L15,0 L15,10 L0,10 z ",OpenArrow:"M15.9,23 L5,16 L15.9,9 L17,10.7 L8.7,16 L17,21.3Z",Fletch:"M9.82,0 C9.82,0,6.61,5,10,10 C10,10,7.71,5,0,5 C0,5,6.61,5,9.82,0 Z ",OpenFetch:"M0.71,5.71 C0.29,5.71,0,5.43,0,5 C0,4.57,0.29,4.29,0.71,4.29 C8.5,4.29,8.57,0.71,8.57,0.71 C8.57,0.29,8.86,0,9.29,0 C9.719999999999999,0,10,0.29,10,0.71 C10,0.93,9.93,5.71,0.71,5.71 C0.71,5.71,0.71,5.71,0.71,5.71 Z M9.29,10 C8.93,10,8.57,9.71,8.57,9.29 C8.57,9.14,8.36,5.71,0.71,5.71 C0.29,5.71,0,5.36,0,5 C0,4.64,0.29,4.29,0.71,4.29 C0.71,4.29,0.71,4.29,0.71,4.29 C9.93,4.29,10,9.07,10,9.29 C10,9.71,9.71,10,9.29,10 Z ",IndentedArrow:"M10,0 C10,0,6.25,4.58,10,10 L0,5 L10,0 Z ",OutdentedArrow:"M8,0 C8,0,12.5,5,8,10 L0,5 L8,0 Z ",DoubleArrow:"M19,10 L19,22 L13,16Z M12,10 L12,22 L6,16Z",Arrow:"M15,10 L15,22 L5,16Z",Diamond:"M10,5 L5,10 L0,5 L5,0 L10,5 Z ",Circle:"M10,5 C10,7.76,7.76,10,5,10 C2.24,10,0,7.76,0,5 C0,2.24,2.24,0,5,0 C7.76,0,10,2.24,10,5 Z ",Ellipse:"M15,5 C15,7.76,11.64,10,7.5,10 C3.36,10,0,7.76,0,5 C0,2.24,3.36,0,7.5,0 C11.64,0,15,2.24,15,5 Z "},ore={Square:"M0,0 L10,0 L10,10 L0,10 z",Rhombus:"M10,5 L5,10 L0,5 L5,0 L10,5 Z ",Rectangle:"M0,0 L15,0 L15,10 L0,10 z",OpenArrow:"M23,15.9 L16,5 L9,15.9 L10.7,17 L16,8.7 L21,17.3Z",Fletch:"M9.82,0 C9.82,0,6.61,5,10,10 C10,10,7.71,5,0,5 C0,5,6.61,5,9.82,0 Z ",OpenFetch:"M0.71,5.71 C0.29,5.71,0,5.43,0,5 C0,4.57,0.29,4.29,0.71,4.29 C8.5,4.29,8.57,0.71,8.57,0.71 C8.57,0.29,8.86,0,9.29,0 C9.719999999999999,0,10,0.29,10,0.71 C10,0.93,9.93,5.71,0.71,5.71 C0.71,5.71,0.71,5.71,0.71,5.71 Z M9.29,10 C8.93,10,8.57,9.71,8.57,9.29 C8.57,9.14,8.36,5.71,0.71,5.71 C0.29,5.71,0,5.36,0,5 C0,4.64,0.29,4.29,0.71,4.29 C0.71,4.29,0.71,4.29,0.71,4.29 C9.93,4.29,10,9.07,10,9.29 C10,9.71,9.71,10,9.29,10 Z ",IndentedArrow:"M10,0 C10,0,6.25,4.58,10,10 L0,5 L10,0 Z ",OutdentedArrow:"M8,0 C8,0,12.5,5,8,10 L0,5 L8,0 Z ",DoubleArrow:"M10,19 L22,19 L16,13Z M10,12 L22,12 L16,6Z",Arrow:"M10,15 L22,15 L16,5Z",Diamond:"M10,5 L5,10 L0,5 L5,0 L10,5 Z ",Circle:"M10,5 C10,7.76,7.76,10,5,10 C2.24,10,0,7.76,0,5 C0,2.24,2.24,0,5,0 C7.76,0,10,2.24,10,5 Z ",Ellipse:"M15,5 C15,7.76,11.64,10,7.5,10 C3.36,10,0,7.76,0,5 C0,2.24,3.36,0,7.5,0 C11.64,0,15,2.24,15,5 Z "};function xx(n){return are[n.toString()]}var are={Process:"M419.511,76.687L359.511,76.687L359.511,43.086L419.511,43.086z",Decision:"M 253.005,115.687L 200.567,146.071L 148.097,115.687L 200.534,85.304L 253.005,115.687 Z",Document:"M 60 31.9 c 0 0 -11 -7.7 -30 0 s -30 0 -30 0 V 0 h 60 V 31.9 Z",PreDefinedProcess:"M 0,0 L 50,0 L 50,50 L 0,50 Z M 8.334,0 L 8.334,50 M 41.667,0 L 41.667,50",Terminator:"M 269.711,29.33C 269.71,44.061 257.77,56 243.04,56L 158.058,56C 143.33,56 131.39,44.061 131.39,29.33L 131.39,29.33C 131.391,14.6057 143.33,2.669 158.058,2.669L 243.044,2.669C 257.772,2.669 269.711,14.6057 269.711,29.333 Z",PaperTap:"M0.0009,17.2042 L0.0009,47.165 C0.001,47.165 14.403,53.5455 25.00,47.165 C35.599,40.7852 44.403,43.5087 50.00,47.165L50.001,17.2042 M50.001,32.7987 L50.001,2.8405 C50.001,2.8405 35.599,-3.5427 25.001,2.8405C14.403,9.2237 5.599,6.494 0.0009,2.8405 L0.0009,32.7987",DirectData:"M 132.62 0 L 17.38 0 C 7.78 0 0 13.43 0 30 C 0 46.57 7.78 60 17.38 60 L 132.62 60 M 132.62 0C 123.02 0 115.24 13.43 115.24 30 C 115.24 46.57 123.02 60 132.62 60 C 142.22 60 150 46.57 150 30 C 150 13.43 142.22 0 132.62 0 z ",SequentialData:"M0.0029,24.999 C0.0029,11.1922 10.433,0.0021 23.295,0.0021 C36.159,0.00216 46.585,11.1922 46.585,24.999C46.585,38.8057 36.159,49.9979 23.295,49.9979 C10.433,49.9979 0.0029,38.8057 0.0029,24.999 z M23.294,49.999 L50.002,49.999",Sort:"M50.001,24.9971 L25.001,49.9971 L0.00097,24.9971 L25.001,-0.00286865 L50.001,24.9971 z M0.000976562,24.9971 L50.001,24.9971",MultiDocument:"M43.6826,40 C44.8746,40.6183 45.8586,41.3502 46.8366,42.1122 L46.8366,4.74487 L3.09857,4.74487 L3.09857,10.9544 M46.837,35.143 C48.027,35.765 49.025,36.604 50.003,37.369 L50.003,0.002 L6.264,0.002 L6.264,4.744 M43.682,47.113 L43.682,10.765 L0.0025,10.7652 L0.0025,47.1132 C0.0025,47.1132 12.5846,53.6101 21.8426,47.1132 C31.1006,40.6163 38.792,43.393 43.6826,47.1132 z",Collate:"M50.001,0.0028 L25.001,25.0029 L0.00097,0.0028 L50.001,0.002 z M0.0009,50.002 L25.001,25.002L50.001,50.002 L0.0009,50.0029 z",SummingJunction:"M7.3252,42.6768 L42.6772,7.3247 M42.6768,42.6768 L7.3248,7.3247 M0.0009,25.001 C0.0009,11.193 11.197,0.0009 25.001,0.0009 C38.809,0.0009 50.001,11.193 50.001,25.001 C50.001,38.809 38.809,50.001 25.001,50.001 C11.197,50.00 0.0009,38.809 0.0009,25.00 z",Or:"M 0 50 L 100 50 M 50 100 L 50 0.0 M 0 50 C 0 22.384 22.392 0 50 0 C 77.616 0 100 22.384 100 50 C 100 77.616 77.616 100 50 100 C 22.392 100 0 77.616 0 50 Z",InternalStorage:"M 0 3.81946A 2.5,3.81946 0 0,1 2.5,0L 47.5 0A 2.5,3.81946 0 0,1 50,3.81946L 50 45.836A 2.5,3.819446 0 0,1 47.5,49.652778L 2.5 49.652778A 2.5,3.819446 0 0,1 0,45.8336L 0 3.819446ZM 0 11.45834L 50 11.4583334M 12.5 0L 12.5 49.652778",Extract:"M0,35 L30,0 L60,35 Z",ManualOperation:"M46.4,28.8 L14.8,28.8 L0,0 L60,0 Z",Merge:"M60,0 L30,35 L0,0 Z",OffPageReference:"M60,33.3 L30.1,39 L0,33.3 L0,0 L60,0 Z",SequentialAccessStorage:"M 60 30 C 60 13.4 46.6 0 30 0 S 0 13.4 0 30 s 13.4 30 30 30 h 28.6 v -6.5 h -9.9C 55.5 48 60 39.5 60 30 Z",Annotation:"M49.9984,50.0029 L-0.00271199,50.0029 L-0.00271199,0.00286865 L49.9984,0.00286865",Annotation2:"M49.9977,50.0029 L25.416,50.0029 L25.416,0.00286865 L49.9977,0.00286865 M25.4166,25.0029 L-0.00227869,25.0029",Data:"M 10 0 L 40 0 L 30 40 L 0 40 Z",Card:"M275,60 L400,60 L400,110 L260,110 L260,75 Z",Delay:"M0,0 L12.029,0 C14.212999,0 16,1.7869979 16,3.9709952 C16,6.1549926 14.212999,7.9409904 12.029,7.9409904 L0,7.9409904 z",Preparation:"M 1048.17 572 C 1051.06 568.86 1055.17 567.05 1059.5 567 L 1094.51 567 C 1098.84 567.05 1102.95 568.86 1105.84 572 L 1126.43 595 C 1127.01 596.28 1127.01 597.72 1126.43 599 L 1105.84 622 C 1102.95 625.14 1098.84 626.95 1094.51 627 L 1059.5 627 C 1055.17 626.95 1051.06 625.14 1048.17 622 L 1027.58 599 C 1027 597.72 1027 596.28 1027.58 595 L 1048.17 572 Z",Display:"M47.8809,19.2914 L32.7968,-0.00594145 L11.3902,-0.00594145 C7.93166,-0.00594145 0.00124586,11.187 0.00124586,24.9968C0.00124586,38.8032 7.93166,49.9962 11.3902,49.9962 L32.7968,49.99 L47.615,31.038 C47.615,31.0388 52.798,24.9968 47.880,19.2914 z",ManualInput:"M 912 732 L 1006.85 707 C 1008.2 707 1009.5 707.53 1010.46 708.46 C 1011.41 709.4 1011.95 710.67 1011.95 712 L 1011.95 762C 1012 764.41 1010.28 766.52 1007.87 767 L 917.1 767 C 915.75 767 914.45 766.47 913.49 765.54 C 912.54 764.6 912 763.33 912 762 L 912 732 Z",LoopLimit:"M 8 9 L 27 9 L 33 15 L 33 26 C 33 27 33 27 32 27 L 4 27 C 3 27 2 27 2 26 L 2 15 L 8 9 Z",StoredData:"M 5.55 0L 50 0A 1.5,30 0 0,1 50,0A 5.555,25 0 0,0 50,50A 1.5,30 0 0,1 50,50L 5.555 50A 5.55,25 0 0,1 5.555,0Z"};function s3(n,t,e){var i;i="Straight"!==n.type&&n.sourceWrapper?n.sourceWrapper.corners.center:function lre(n){var t;if(n.sourcePortWrapper){var e=n.sourcePortWrapper;t={x:e.offsetX,y:e.offsetY}}else t=n.sourceID&&n.sourceWrapper&&n.targetWrapper?qa(n,0,n.sourceWrapper.corners.center,n.targetWrapper.corners.center,!1):n.sourcePoint;return t}(n);var r=function cre(n,t,e,i,r){var b,M,s=n.sourceWrapper,o=n.targetWrapper,a=n.sourcePortWrapper,l=n.targetPortWrapper,d=[],p=Xa(n),y={corners:undefined,point:t,direction:undefined,margin:{left:5,right:5,bottom:5,top:5}},S={corners:undefined,point:e,direction:undefined,margin:{left:5,right:5,bottom:5,top:5}};if(void 0!==s&&void 0!==o&&(b=xn(s),M=xn(o),y.corners=s.corners,S.corners=o.corners),void 0!==a&&(y.direction="Left"===a.connectionDirection||"Top"===a.connectionDirection||"Bottom"===a.connectionDirection||"Right"===a.connectionDirection?a.connectionDirection:zo({x:a.offsetX,y:a.offsetY},b,s.bounds)),void 0!==l&&(S.direction="Left"===l.connectionDirection||"Right"===l.connectionDirection||"Bottom"===l.connectionDirection||"Top"===l.connectionDirection?l.connectionDirection:zo({x:l.offsetX,y:l.offsetY},M,o.bounds)),"Bezier"===n.type&&!n.isBezierEditing&&n.segments.length>0)for(var D=n.segments.length-1;D>=0;)n.segments[parseInt(D.toString(),10)].isInternalSegment&&n.segments.pop(),D--;if(void 0!==s&&void 0!==o)return(void 0===y.direction||void 0===S.direction)&&(i?function hre(n,t,e){"LeftToRight"===e?(n.direction=n.direction?n.direction:"Right",t.direction=t.direction?t.direction:"Left"):"RightToLeft"===e?(n.direction=n.direction?n.direction:"Left",t.direction=t.direction?t.direction:"Right"):"TopToBottom"===e?(n.direction=n.direction?n.direction:"Bottom",t.direction=t.direction?t.direction:"Top"):"BottomToTop"===e&&(n.direction=n.direction?n.direction:"Top",t.direction=t.direction?t.direction:"Bottom")}(y,S,i):y.corners.top>S.corners.bottom&&Math.abs(y.corners.top-S.corners.bottom)>p?(y.direction=y.direction?y.direction:"Top",S.direction=S.direction?S.direction:"Bottom"):y.corners.bottomp?(y.direction=y.direction?y.direction:"Bottom",S.direction=S.direction?S.direction:"Top"):y.corners.rightp||y.corners.right+p=y.corners.left-p&&y.corners.left>S.corners.left?(y.direction=y.direction?y.direction:"Right",S.direction=S.direction?S.direction:"Left"):y.corners.left>S.corners.right&&Math.abs(y.corners.left-S.corners.right)>y.margin.left+y.margin.right||S.corners.right+p=S.corners.left-p&&y.corners.left0&&n.segments[0].direction&&(y.direction=n.segments[0].direction),y.point=Nl(b,y.direction),d=Nl(b,_n(y.direction)),y.point=qa(n,0,y.point,d,!1)):y.point=o.corners.center;if(void 0!==h){switch(S.point={x:h.offsetX,y:h.offsetY},S.direction){case"Bottom":case"Top":S.point.y=S.point.y;break;case"Left":case"Right":S.point.x=S.point.x}n.targetPadding&&!w&&(S.point=wI(n,y,S,!0))}else"Orthogonal"===n.type||"Bezier"===n.type?(S.point=Nl(M,S.direction),d=Nl(M,_n(S.direction)),S.point=qa(n,0,S.point,d,!0)):S.point=a.corners.center;if("Orthogonal"!==n.type){var C=void 0,D=void 0;if("Bezier"===n.type){if(n.bezierSettings.allowSegmentsReset||0===n.segments.length||!R.isEmptyPoint(n.segments[n.segments.length-1].point))return c=g3(n,y,S,void 0,s),Tx(n,y,S);Bv(n)}else Bv(n);if(void 0===n.sourcePortWrapper){y.point=y.corners.center,n.segments&&n.segments.length>0&&(C=R.isEmptyPoint((D=n.segments[0]).point)?void 0:D);var A=void 0!==C?C.point:S.point;if("Bezier"===n.type&&n.segments.length>0&&n.segments[0].vector1.angle&&n.segments[0].vector1.distance){var x=Math.max(y.corners.width,y.corners.height);A=R.transform(y.point,n.segments[0].vector1.angle,x/2)}y.point=w?n.sourceWrapper.bounds.center:qa(n,0,y.point,A,!1)}if(void 0===n.targetPortWrapper){S.point=S.corners.center,n.segments&&n.segments.length>1&&(C=R.isEmptyPoint((D=n.segments[n.segments.length-2]).point)?void 0:D);var P=C?C.point:y.point;"Bezier"===n.type&&n.segments.length>0&&n.segments[n.segments.length-1].vector2.angle&&n.segments[n.segments.length-1].vector2.distance&&(x=Math.max(y.corners.width,y.corners.height),P=R.transform(S.point,n.segments[0].vector2.angle,x/2)),S.point=w?n.targetWrapper.bounds.center:qa(n,0,P,S.point,!0)}c=Tx(n,y,S)}else"Orthogonal"===n.type&&n.segments&&n.segments.length>0&&null!==n.segments[0].direction?c=function Ire(n,t,e,i,r,s,o){var a,h,c,d;Bv(n);for(var u=0;u0&&n.segments[u-1].direction===h.direction?u=u3(n,u,t):h.direction?t.point=o3(t,n.segments[parseInt(u.toString(),10)]):(f=n.segments[u-1])&&f.points&&f.points.length>0&&(t.point=f.points[f.points.length-1]),u===n.segments.length-1)if(f3(n,t),c3(a=void 0===r?Sre(n,t,e):l3(n,t,e),n),h.points=[],a.length>=2)for(c=0;c2&&n.segments.length>2){var p={x:a[parseInt(c.toString(),10)].x,y:t.point.y};h.points=[],h.points.push(p),h.points.push(a[parseInt(c.toString(),10)]);var f=n.segments[u-1];n.segments.length<4&&f.points.pop(),f.points=f.points.concat(h.points)}else h.points.push(a[parseInt(c.toString(),10)]);else h.points.push(a[parseInt(c.toString(),10)]);else d=u;if(void 0!==d&&!n.selectedSegmentIndex&&(d===n.segments.length-1&&(n.segments[d-1].direction=null,n.segments[d-1].length=null),n.segments.splice(d,1)),i&&0===u){var g=h3(n,i,s);g&&(t.point=g)}}return p3(n,[])}(n,y,S,l,h,o):(n.segments[0]||(C=new wi(n,"segments",{type:"Orthogonal"},!0),n.segments.push(C)),n.segments[0].points=c=g3(n,y,S,void 0,s));return c}(n,y.direction,S.direction,y.point,S.point,r);if(Bv(n),(n.sourceWrapper||n.targetWrapper)&&function gre(n,t,e){var i=n.sourcePortWrapper,r=n.targetPortWrapper,s=n.sourceWrapper,o=t.point,a={left:0,right:0,top:0,bottom:0},l={x:0,y:0},c="Top";if(s?(o=e.point,a=t.margin):(s=n.targetWrapper,a=e.margin),"Orthogonal"===n.type)if(n.segments&&n.segments.length>0&&n.sourceWrapper&&n.segments[0].direction)t.direction=n.segments[0].direction,l=qa(n,0,l=Nl(s.corners,t.direction),Nl(s.corners,_n(t.direction)),!1);else{var u={corners:null,direction:null,point:null,margin:null};Fv(s,{corners:null,direction:null,point:o,margin:a},u,n),l=u.point,c=u.direction}else{var f=void 0;n.segments&&n.segments.length>1&&(f=s===n.sourceWrapper?n.segments[0].point:n.segments[n.segments.length-2].point),l=qa(n,0,s.bounds.center,n.segments&&n.segments.length>1?f:o,s===n.targetWrapper)}s===n.sourceWrapper?(t.direction=t.direction||c,t.point=l,n.sourcePortWrapper&&(t.point={x:i.offsetX,y:i.offsetY},n.sourcePadding&&(t.point=wI(n,t,e,!1)))):(e.direction=e.direction||c,e.point=l,n.targetPortWrapper&&(e.point={x:r.offsetX,y:r.offsetY},n.targetPadding&&(e.point=wI(n,t,e,!0))))}(n,y,S),"Straight"===n.type||"Bezier"===n.type)d=Tx(n,y,S);else if("Orthogonal"===n.type&&n.segments&&n.segments.length>0&&null!==n.segments[0].length&&null!==n.segments[0].direction)d=function pre(n,t,e,i,r,s,o){var a,l,c,u,h=[];if(Bv(n),n.segments.length>0){for(var f=0;f0&&n.segments[f-1].direction===p.direction)f=u3(n,f,t);else{var g=n.segments[f-1];t.point=p.direction?o3(t,p):g.points[g.points.length-1]}if(f===n.segments.length-1&&(o||r?n.targetWrapper&&void 0===n.targetPortWrapper?(f3(n,t),l=ure(n,t,e)):l=l3(n,t,e):l=dre(n,t,e),l))if(c3(l,n),p.points=[],l.length>=2)for(a=0;at.corners.top&&e.point.ye.point.x?"Left":"Right"):e.point.x>t.corners.left&&e.point.xe.point.y?"Top":"Bottom")),n.sourcePortWrapper&&s===_n(r)?(("Left"===s||"Right"===s)&&t.point.y>=t.corners.top&&t.point.y<=t.corners.center.y&&e.point.y>=t.corners.top&&e.point.y<=t.corners.center.y?(t.direction="Top",a=t.point.y-t.corners.top+20):("Left"===s||"Right"===s)&&t.point.y>t.corners.center.y&&t.point.y<=t.corners.bottom&&e.point.y>t.corners.center.y&&e.point.y<=t.corners.bottom?(t.direction="Bottom",a=t.corners.bottom-t.point.y+20):("Top"===s||"Bottom"===s)&&t.point.x>=t.corners.left&&t.point.x<=t.corners.center.x&&e.point.x>=t.corners.left&&e.point.x<=t.corners.center.x?(t.direction="Left",a=t.point.x-t.corners.left+20):("Top"===s||"Bottom"===s)&&t.point.x<=t.corners.right&&t.point.x>t.corners.center.x&&e.point.x<=t.corners.right&&e.point.xt.point.y&&t.point.y>=e.corners.top?(i="Top",r=t.point.y-e.corners.top+20):e.corners.center.y===t.point.y&&"Top"===n.segments[n.segments.length-2].direction||e.corners.center.ye.point.y?t.point.y-t.corners.top+20:t.corners.bottom-t.point.y+20):(i="Top",r=e.corners.height/2+20):e.corners.center.x!==t.point.x||e.corners.topt.point.x&&t.point.x>=e.corners.left?(i="Left",r=t.point.x-e.corners.left+20):e.corners.center.x===t.point.x&&"Left"===n.segments[n.segments.length-2].direction||e.corners.center.x<=t.point.x&&t.point.x<=e.corners.right?(i="Right",r=e.corners.right-t.point.x+20):void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&t.corners.left<=t.point.x&&t.point.x<=t.corners.right&&(i=t.direction,r=t.point.x>e.point.x?t.point.x-t.corners.left+20:t.corners.right-t.point.x+20):(i="Left",r=e.corners.width/2+20);var a=t.point;t.point=Fn(t.point,"Left"===i||"Top"===i?-r:r,"Left"===i||"Right"===i?0:90),t.direction=R.direction(t.point,e.point),void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&(t.corners.center.x===e.corners.center.x||t.corners.center.y===e.corners.center.y)&&(t.direction=e.direction);var l=Ys(n,t,e);return l.splice(0,0,a),l}function l3(n,t,e){var i,r;e.corners=n.targetWrapper.corners,void 0!==n.sourcePortWrapper&&(r=zo({x:n.sourcePortWrapper.offsetX,y:n.sourcePortWrapper.offsetY},xn(n.sourceWrapper),n.sourceWrapper.bounds));var a=function fre(n,t,e,i){var r=!1;switch(e.direction){case"Left":void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&"Right"===i&&t.point.x>e.point.x&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom||("Bottom"===i&&t.point.y>e.point.y||"Top"===i&&t.point.y=t.corners.left&&t.point.x<=t.corners.right?(t.direction="Right"===i?t.point.y>e.point.y?"Top":"Bottom":t.point.xe.point.x&&(t.point.y>e.point.y||t.point.yt.point.y&&e.corners.bottome.point.y||t.point.x>e.point.x&&t.point.y<=e.point.y&&e.corners.top=t.point.y?t.direction="Top":t.point.xe.point.x&&t.point.y>e.point.y&&e.corners.bottomt.point.y?t.direction="Bottom":t.point.y===e.point.y&&t.point.xe.point.y||"Top"===i&&t.point.ye.point.x&&t.point.x>=t.corners.left&&t.point.x<=t.corners.right?(t.direction=t.point.x>e.point.x?"Left":"Right",r=!0):void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&"Left"===i&&t.point.x=t.corners.top&&t.point.y<=t.corners.bottom?(t.direction=t.point.y>e.point.y?"Top":"Bottom",r=!0):t.point.x=t.point.y&&t.point.y===e.point.y||t.point.y>e.point.y&&t.point.x>e.point.x?t.direction="Top":t.point.ye.point.x?t.direction="Bottom":t.point.xe.point.y||t.point.ye.point.x&&(t.direction="Left");break;case"Top":void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&"Bottom"===i&&t.point.y>e.point.y&&t.point.x>=t.corners.left&&t.point.x<=t.corners.right||("Right"===i&&t.point.x>e.point.x||"Left"===i&&e.point.y>t.point.y&&e.point.x>t.point.x)&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom?(t.direction="Bottom"===i?t.point.x>e.point.x?"Left":"Right":t.point.ye.point.y&&t.point.x>e.corners.left&&t.point.x=e.point.y?t.direction="Top":t.point.ye.point.x?t.direction="Left":t.point.yt.point.x)&&t.point.y>e.point.y&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom||"Top"===i&&t.point.y=t.corners.left&&t.point.x<=t.corners.right)?(t.direction="Right"===i||"Left"===i?t.point.y>e.point.y?"Top":"Bottom":t.point.x>e.point.x?"Left":"Right",r=!0):t.point.ye.corners.left&&e.corners.right>t.point.x?t.point.ye.corners.left&&e.corners.center.x>=t.point.x?t.direction="Left":t.point.ye.point.y&&t.point.x>e.point.x?t.direction="Left":t.point.y>e.point.y&&t.point.xe.point.x||e.point.x>t.point.x)&&(t.direction="Bottom")}return r}(n,t,e,r);return!n.selectedSegmentIndex&&void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&e.direction===_n(r)&&(("Left"===e.direction&&t.point.x>e.point.x||"Right"===e.direction&&t.point.x=t.corners.top&&t.point.y<=t.corners.bottom||"Bottom"===e.direction&&t.point.y=t.corners.left&&t.point.x<=t.corners.right)?i=a3(n,t,e):n.selectedSegmentIndex||t.direction!==e.direction?!n.selectedSegmentIndex&&("Left"===e.direction&&t.point.x>e.point.x||"Right"===e.direction&&t.point.x=t.point.y||"Top"===e.direction&&t.point.y>e.point.y||"Bottom"===e.direction&&t.point.y=t.point.x?i=n.selectedSegmentIndex?Ol(t,e):a3(n,t,e):!n.selectedSegmentIndex&&void 0!==n.sourceWrapper&&void 0!==n.targetWrapper&&void 0!==n.targetPortWrapper&&("Left"===t.direction||"Right"===t.direction)&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom&&("Top"===e.direction||"Bottom"===e.direction)&&e.corners.center.x===t.corners.center.x?(t.direction="Top"===e.direction?"Bottom":"Top",i=Ys(n,t,e,"Top"===e.direction?t.corners.bottom-t.point.y+20:t.point.y-t.corners.top+20)):!n.selectedSegmentIndex&&void 0!==n.sourceWrapper&&void 0!==n.targetWrapper&&void 0!==n.targetPortWrapper&&("Top"===t.direction||"Bottom"===t.direction)&&t.point.x>=t.corners.left&&t.point.x<=t.corners.right&&("Left"===e.direction||"Right"===e.direction)&&e.corners.center.y===t.corners.center.y?(t.direction="Left"===e.direction?"Right":"Left",i=Ys(n,t,e,"Left"===e.direction?t.corners.right-t.point.x+20:t.point.x-t.corners.left+20)):i=a?Ys(n,t,e,"Left"===t.direction||"Right"===t.direction?"Left"===t.direction?t.point.x-t.corners.left+20:t.corners.right-t.point.x+20:"Top"===t.direction?t.point.y-t.corners.top+20:t.corners.bottom-t.point.y+20):Ol(t,e):i=Ys(n,t,e),i}function h3(n,t,e){var r,i={x:t.offsetX,y:t.offsetY},s=xn(e),o=zo(i,s,e.bounds),a=n.segments[0];return a.direction!==o&&(function bre(n,t,e,i,r,s){var a,h,o=13,l=[];l.push(i),i.y===r.y&&("Left"===t&&r.xi.x)||i.x===r.x&&("Top"===t&&r.yi.y)||("Top"===t||"Bottom"===t?"Top"===t&&r.yi.y-o||"Bottom"===t&&r.y>i.y&&r.yo&&("Top"===t&&r.yi.y)?l.push({x:i.x,y:r.y}):(a=r.xi.x-o||"right"===t&&r.x>i.x&&r.xo&&("Left"===t&&r.xi.x)?l.push({x:r.x,y:i.y}):(l.push({x:a="Left"===t?e.left-o:e.right+o,y:i.y}),l.push({x:a,y:r.y})),s&&(l.push(n.points[0]),l.reverse()),n.points=l)}(a,o,s,a.points[0],a.points[a.points.length-1],!1),r=a.points[a.points.length-1],a.direction=R.direction(a.points[a.points.length-2],a.points[a.points.length-1])),r}function c3(n,t,e){var s,i=t.segments[t.segments.length-2],r=i.points[i.points.length-1];(("Top"===i.direction||"Bottom"===i.direction)&&r.x===n[1].x||("Left"===i.direction||"Right"===i.direction)&&r.y===n[1].y)&&(i.points[i.points.length-1]=n[1],s=R.direction(i.points[0],i.points[i.points.length-1]),void 0!==t.sourceWrapper&&void 0===t.sourcePortWrapper&&s===_n(i.direction)&&("Left"===i.direction||"Right"===i.direction?i.points[0].x="Right"===i.direction?i.points[0].x-t.sourceWrapper.corners.width:i.points[0].x+t.sourceWrapper.corners.width:i.points[0].y="Bottom"===i.direction?i.points[0].y-t.sourceWrapper.corners.height:i.points[0].y+t.sourceWrapper.corners.height),i.direction=s,i.length=R.distancePoints(i.points[0],i.points[i.points.length-1]),n.splice(0,1))}function wI(n,t,e,i){var o=i?n.targetPadding:n.sourcePadding,a=i?n.targetPortWrapper:n.sourcePortWrapper,l=new Ne(a.bounds.x-o,a.bounds.y-o,a.actualSize.width+2*o,a.actualSize.height+2*o),h=[l.topLeft,l.topRight,l.bottomRight,l.bottomLeft];h[h.length]=h[0];var d=i?e.point:t.point;return Lx({x1:t.point.x,y1:t.point.y,x2:e.point.x,y2:e.point.y},h,0,d)||d}function d3(n,t){var e=[],i=dF(0,n.corners,t);i.push(i[0]);for(var r=0;r0){var r=void 0,s=[],o=t.point;for(r=0;r1&&R.equals(a.points[0],a.points[1])&&n.segments.splice(r,1),a)for(var l=0;l0||0===r)&&i.push(a.points[parseInt(l.toString(),10)])}}return i}function Ax(n,t,e){return"Top"===n||"Bottom"===n?e.x>t.x?"Right":"Left":e.y>t.y?"Bottom":"Top"}function Bv(n){if("Straight"===n.type||"Bezier"===n.type){if(0===n.segments.length||n.segments.length>0&&!R.isEmptyPoint(n.segments[n.segments.length-1].point))if("Bezier"===n.type){var t=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0},!0);n.segments.push(t)}else t=new Hl(n,"segments",{type:"Straight"},!0),n.segments.push(t)}else{if(n.segments.length>0)for(var e=!1,i=0;i=t.corners.left&&e.point.x<=t.corners.right&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom)t.direction=e.point.y>t.point.y?"Bottom":"Top",i=Ys(n,t,e,"Top"===t.direction?t.point.y-t.corners.top+20:t.corners.bottom-t.point.y+20);else if(n.sourcePortWrapper&&r===_n(o)){var h;("Left"===r||"Right"===r)&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom?(t.direction=e.point.y>t.point.y?"Bottom":"Top",h=t.corners.height/2+20):("Top"===r||"Bottom"===r)&&t.point.x>=t.corners.left&&t.point.x<=t.corners.right&&(t.direction=e.point.x>t.point.x?"Right":"Left",h=t.corners.width/2+20),t.direction&&h?i=Ys(n,t,e,h,!0):(t.direction=o,i=Ol(t,e))}else if(!n.sourcePortWrapper||r!==e.direction||"Top"!==r&&"Bottom"!==r||t.corners.center.x!==e.corners.center.x)if(t.direction===e.direction)if(("Left"===t.direction||"Right"===t.direction)&&e.point.y>t.corners.top-20&&e.point.yt.corners.left-20&&e.point.xt.point.y?"Bottom":"Top",i=Ys(n,t,e,"Bottom"===t.direction?t.corners.bottom-t.point.y+20:t.point.y-t.corners.top+20);else t.direction=o,i=Ys(n,t,e,"Top"===o||"Bottom"===o?n.sourceWrapper.height/2+20:n.sourceWrapper.width/2+20),t.point=i[1],"Left"===o||"Right"===o?(e.direction=o,e.point="Left"===o?e.corners.middleLeft:e.corners.middleRight):Fv(n.targetWrapper,t,e,n),i=Ys(n,t,e);return i}function f3(n,t){if(void 0!==n.targetWrapper&&void 0===n.targetPortWrapper&&xn(n.targetWrapper).containsPoint(t.point,1)){var i=n.targetWrapper,r=n.segments[n.segments.length-2],s=r.points[r.points.length-1],o=_n(r.direction);"Bottom"===o?s.yi.corners.top-1&&(r.points[r.points.length-1].y=i.corners.top-20,r.length=R.distancePoints(r.points[0],r.points[r.points.length-1])):"Left"===o?s.x>i.corners.left-1&&(r.points[r.points.length-1].x=i.corners.left-20,r.length=R.distancePoints(r.points[0],r.points[r.points.length-1])):"Right"===o&&s.x0||0===e)&&t.push(i.points[parseInt(r.toString(),10)]);return t}function Fv(n,t,e,i){var r,s={x:0,y:0},o=CI(n,n.corners,n.bounds),a=t.margin,l=t.point;if(o.bottomCenter.y+a.bottoml.y)r="Top",s=o.topCenter;else if(o.middleLeft.x-a.left>l.x)r="Left",s=o.middleLeft;else if(o.middleRight.x+a.rightc&&(f=c,r="Right",s=o.middleRight),f>d&&(f=d,r="Bottom",s=o.bottomCenter),f>u&&(r="Left",s=o.middleLeft)}e.point=s,e.direction=r;var p=Nl(o,_n(e.direction));e.point=qa(i,0,e.point,p,n===i.targetWrapper)}function g3(n,t,e,i,r){var s,o,a;if(s=function zre(n,t){var e=!1;switch(n){case"Left":switch(t){case"Right":case"Bottom":e=!0}break;case"Top":switch(t){case"Left":case"Right":case"Bottom":e=!0}break;case"Bottom":"Right"===t&&(e=!0)}return e}(t.direction,e.direction),s&&b3(t,e),"Right"===t.direction&&"Left"===e.direction)a=function Mre(n,t,e,i){var o=Math.round(Math.abs(t.point.y-e.point.y)),a={x:Math.max(t.point.x,t.corners.right),y:t.point.y},l={x:Math.min(e.point.x,e.corners.left),y:e.point.y},h=Xa(n);if(i){var c=l;l=a,a=c}return t.corners.bottom+he.corners.bottom+h||("Bezier"!==n.type||e.corners.left-t.corners.right<=2*h&&e.corners.left-t.corners.right>=5)&&(h=0),t.margin={left:h,right:h,top:h,bottom:h},e.margin={left:h,right:h,top:h,bottom:h},0===o&&(t.corners.right=e.corners.right?void 0!==i&&(i.offsetYe.corners.bottom+e.margin.bottom)||void 0===i&&t.corners.middleRight.ye.corners.bottom+e.margin.bottom&&t.corners.top>e.corners.bottom||void 0===i&&t.corners.middleRight.y>e.corners.bottom||void 0!==i&&i.offsetYe.corners.top||void 0===i&&t.corners.middleRight.y>e.corners.bottom?Ae.Three:t.corners.rightr.offsetY+e.margin.right||void 0===r&&t.corners.top>e.corners.middleRight.y||void 0!==r&&(void 0!==i&&i.offsetXr.offsetX||void 0===r&&t.corners.left>e.corners.topCenter.x?Ae.Four:Ae.Two:void 0!==s&&Math.abs(t.corners.right-e.corners.left)<=5&&Math.abs(s.offsetY-e.corners.top)<=5||void 0!==r&&t.corners.right=25&&t.corners.middleRight.y+t.margin.righte.corners.bottom+e.margin.bottom||void 0===o&&t.corners.middleRight.y>e.corners.bottom+e.margin.bottom?t.corners.top>e.corners.bottom?void 0!==a&&t.corners.right+t.margin.righta.offsetX||void 0===a&&t.corners.left>e.corners.bottomCenter.x?Ae.Four:Ae.Two:void 0!==o&&Math.abs(t.corners.right-e.corners.left)<=25&&Math.abs(o.offsetY-e.corners.bottom)<=25?Ae.Two:Ae.Four}(n,t,e,s);else if("Bottom"===t.direction&&"Top"===e.direction)a=function Dre(n,t,e){var r=t.point.x-e.point.x,s=Xa(n);return t.corners.right+se.corners.right+s||("Bezier"!==n.type||e.corners.top-t.corners.bottom<=2*s&&e.corners.top-t.corners.bottom>=5)&&(s=0),t.margin={left:s,right:s,top:s,bottom:s},e.margin={left:s,right:s,top:s,bottom:s},0===r&&t.corners.bottome.corners.right+e.margin.right||void 0===i&&t.corners.bottomCenter.x>e.corners.right+e.margin.right?Ae.Three:t.corners.bottomr.offsetX||void 0===r&&t.corners.left>e.corners.left||void 0!==r&&t.corners.right+t.margin.righte.corners.bottom?Ae.Five:0===s||0===o?Ae.One:Ae.Three}(n,t,e)}else"Bottom"===t.direction&&"Left"===e.direction?a=function xre(n,t,e,i){var r=n.sourcePortWrapper,s=n.targetPortWrapper,o=Xa(n);if(e.margin={left:o,right:o,top:o,bottom:o},t.margin={top:o,bottom:o,left:o,right:o},i){var l=r;r=s,s=l}return void 0!==r&&r.offsetXs.offsetY||void 0===s&&t.corners.top>e.corners.middleLeft.y?Ae.Four:Ae.Two:void 0!==s&&Math.abs(t.corners.right-e.corners.left)<=25&&Math.abs(s.offsetY-t.corners.bottom)<=25?Ae.Two:Ae.Four}(n,t,e,s):"Left"===t.direction&&"Left"===e.direction?a=function Lre(n,t,e){var i=n.sourcePortWrapper,r=n.targetPortWrapper,s=Xa(n);t.margin={left:s,right:s,top:s,bottom:s},e.margin={left:s,right:s,top:s,bottom:s};var o=Math.round(Math.abs(t.point.x-e.point.x)),a=Math.round(Math.abs(t.point.y-e.point.y));return t.corners.leftr.offsetY||void 0===r&&t.corners.top-t.margin.top>e.corners.middleLeft.y?Ae.Three:t.corners.righte.corners.bottom+e.margin.bottom||void 0===i&&t.corners.middleLeft.y>e.corners.bottom+e.margin.bottom?Ae.Three:t.corners.left>e.corners.right?Ae.Five:0===o||0===a?Ae.One:Ae.Three}(n,t,e):"Left"===t.direction&&"Top"===e.direction?a=function Are(n,t,e,i){var s=n.sourcePortWrapper,o=Xa(n);e.margin={left:o,right:o,top:o,bottom:o},t.margin={top:o,bottom:o,left:o,right:o};var a=n.targetPortWrapper,l={x:Math.min(t.point.x,t.corners.left),y:t.point.y},h={x:e.point.x,y:Math.min(e.point.y,e.corners.top)};if(i){var c=s;s=a,a=c;var d=l;l=h,h=d}return void 0!==s&&s.offsetYa.offsetX||void 0===a&&t.corners.left-t.margin.left>e.corners.topCenter.x?Ae.Two:Ae.Four:void 0!==a&&t.corners.rightr.offsetX||void 0===r&&t.corners.left>e.corners.left||void 0!==r&&t.corners.right+t.margin.righte.corners.right+e.margin.right||void 0===i&&t.corners.left>e.corners.right||void 0!==i&&i.offsetXe.corners.bottom?Ae.Five:0===s||0===o?Ae.One:Ae.Three}(n,t,e));return s&&b3(t,e),o=function Ore(n,t,e,i,r,s){var l,d,h=n.sourceWrapper.corners,c=n.targetWrapper.corners,u=20,f={corners:e.corners,point:e.point,direction:e.direction,margin:e.margin},p={corners:i.corners,point:i.point,direction:i.direction,margin:i.margin};if(!(f.direction===p.direction&&t!==Ae.Five||f.direction!==_n(p.direction)&&t!==Ae.Three))switch(f.direction){case"Left":h.middleLeft.x>c.middleRight.x&&(d=(h.middleLeft.x-c.middleRight.x)/2,u=s?d:Math.min(u,d));break;case"Right":h.middleRight.xc.bottomCenter.y&&(d=(h.topCenter.y-c.bottomCenter.y)/2,u=s?d:Math.min(u,d));break;case"Bottom":h.bottomCenter.yf&&hf)&&o>c&&o<=d&&e>=20&&(s=n.point.x-t.corners.left+s),i&&n.direction===t.direction&&n.corners.left>t.corners.left&&n.corners.left-t.corners.right>=20&&(s=(n.corners.left-t.corners.right)/2),p=Fn(n.point,s,180);break;case"Top":(o>c&&oc)&&h>f&&h<=u&&e>=20&&(s=n.point.y-t.corners.top+s),i&&n.direction===t.direction&&n.corners.top>t.corners.top&&n.corners.top-t.corners.bottom>=20&&(s=(n.corners.top-t.corners.bottom)/2),p=Fn(n.point,s,270);break;case"Right":(h>f&&hf)&&a=c&&e>=20&&(s=t.corners.right-n.point.x+s),i&&n.direction===t.direction&&n.corners.right=20&&(s=(t.corners.left-n.corners.right)/2),p=Fn(n.point,s,0);break;case"Bottom":(o>c&&oc)&&l=f&&e>=20&&(s=t.corners.bottom-n.point.y+s),i&&n.direction===t.direction&&n.corners.bottom=20&&(s=(t.corners.top-n.corners.bottom)/2),p=Fn(n.point,s,90)}r=[n.point,p];var g=void 0;if("Top"===n.direction||"Bottom"===n.direction){var v=n.direction;n.direction=p.x>t.point.x?"Left":"Right",n.point=p,r=EI(n,t,v,r,g=i?.5*Math.abs(p.x-t.point.x):g,i)}else v=n.direction,n.direction=p.y>t.point.y?"Top":"Bottom",n.point=p,r=EI(n,t,v,r,g=i?.5*Math.abs(p.y-t.point.y):g,i);return r}(f,p,u,g)),l}(n,a,t,e,i,r),"Bezier"===n.type&&function Pre(n,t,e){if("Bezier"===n.type)if(0===n.segments.length){var i=e[0],r=e[e.length-1];if(t===Ae.One){var s=Math.min(20,.5*R.findLength(i,r)),o={angle:Xt(i,r),distance:s},a={angle:Xt(r,i),distance:s},l=R.direction(i,r),c=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,orientation:"Left"===l||"Right"===l?"Horizontal":"Vertical"},!0);n.segments.push(c)}else if(t===Ae.Two)o={angle:Xt(i,d=e[1]),distance:.5*R.findLength(i,d)},a={angle:Xt(r,d),distance:.5*R.findLength(r,d)},l=R.direction(i,d),c=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,orientation:"Left"===l||"Right"===l?"Horizontal":"Vertical"},!0),n.segments.push(c);else if(t===Ae.Three){var d={x:.5*((u=e[1]).x+(f=e[e.length-2]).x),y:.5*(u.y+f.y)},p=(o={angle:Xt(i,u),distance:.5*R.findLength(i,u)},a={angle:Xt(d,u),distance:.5*R.findLength(d,u)},R.direction(i,u)),v=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,point:d,orientation:"Left"===p||"Right"===p?"Horizontal":"Vertical"},!0);n.segments.push(v);var y={angle:Xt(d,f),distance:.5*R.findLength(d,f)},S={angle:Xt(r,f),distance:.5*R.findLength(r,f)},b=R.direction(d,f),w=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:y,vector2:S,orientation:"Left"===b||"Right"===b?"Horizontal":"Vertical"},!0);n.segments.push(w)}else if(t===Ae.Four){var D={x:.5*((u=e[1]).x+(f=e[2]).x),y:.5*(u.y+f.y)},A={x:.5*(f.x+(C=e[3]).x),y:.5*(f.y+C.y)};o={angle:Xt(i,u),distance:.5*R.findLength(i,u)},a={angle:Xt(D,u),distance:.5*R.findLength(D,u)},p=R.direction(i,u),v=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,point:D,orientation:"Left"===p||"Right"===p?"Horizontal":"Vertical"},!0),n.segments.push(v),y={angle:Xt(D,f),distance:.5*R.findLength(D,f)},S={angle:Xt(A,f),distance:.5*R.findLength(A,f)},b=R.direction(D,f),w=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:y,vector2:S,point:A,orientation:"Left"===b||"Right"===b?"Horizontal":"Vertical"},!0),n.segments.push(w);var x={angle:Xt(A,C),distance:.5*R.findLength(A,C)},P={angle:Xt(r,C),distance:.5*R.findLength(r,C)},L=R.direction(A,C),N=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:x,vector2:P,orientation:"Left"===L||"Right"===L?"Horizontal":"Vertical"},!0);n.segments.push(N)}else if(t===Ae.Five){var u,f,C,T=e[4],z=(D={x:.5*((u=e[1]).x+(f=e[2]).x),y:.5*(u.y+f.y)},A={x:.5*(f.x+(C=e[3]).x),y:.5*(f.y+C.y)},{x:.5*(C.x+T.x),y:.5*(C.y+T.y)});o={angle:Xt(i,u),distance:.5*R.findLength(i,u)},a={angle:Xt(D,u),distance:.5*R.findLength(D,u)},p=R.direction(i,u),v=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,point:D,orientation:"Left"===p||"Right"===p?"Horizontal":"Vertical"},!0),n.segments.push(v),y={angle:Xt(D,f),distance:.5*R.findLength(D,f)},S={angle:Xt(A,f),distance:.5*R.findLength(A,f)},b=R.direction(D,f),w=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:y,vector2:S,point:A,orientation:"Left"===b||"Right"===b?"Horizontal":"Vertical"},!0),n.segments.push(w),x={angle:Xt(A,C),distance:.5*R.findLength(A,C)},P={angle:Xt(z,C),distance:.5*R.findLength(z,C)},L=R.direction(A,C),N=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:x,vector2:P,point:z,orientation:"Left"===L||"Right"===L?"Horizontal":"Vertical"},!0),n.segments.push(N);var U={angle:Xt(z,T),distance:.5*R.findLength(z,T)},B={angle:Xt(r,T),distance:.5*R.findLength(r,T)},j=R.direction(z,T),oe=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:U,vector2:B,orientation:"Left"===j||"Right"===j?"Horizontal":"Vertical"},!0);n.segments.push(oe)}else c=new fs(n,"segments",{type:"Bezier"},!0),n.segments.push(c)}else for(var ue=0;ue=13?13:n.connectorSpacing<=1?1:n.connectorSpacing}function Xt(n,t){var i=R.findLength({x:t.x,y:n.y},t),r=R.findLength(t,n),s=Math.asin(i/r);return s=180*s/Math.PI,n.xt.y&&(s=360-s):s=n.y0)for(var l=1;lc)&&(s=c,a=h),s>=0&&s<=1)break}}return a}function m3(n,t){var c,d,u,f,p,g,S,b,M,w,D,e=n.x1,i=n.y1,r=n.x2,s=n.y2,o=t.x1,a=t.y1,l=t.x2,h=t.y2;if(w=(c=s-i)*l+(u=e-r)*h+(p=r*i-e*s),0!==(M=c*o+u*a+p)&&0!==w&&y3(M,w)||(b=(d=h-a)*r+(f=o-l)*s+(g=l*a-o*h),0!==(S=d*e+f*i+g)&&0!==b&&y3(S,b)))return null;var A=c*f-d*u;return 0===A?null:(A<0?-A/2:A/2,0,{x:(D=u*g-f*p)<0?(D-0)/A:(D+0)/A,y:(D=d*p-c*g)<0?(D-0)/A:(D+0)/A})}function y3(n,t){return n*t>=0}function S3(n,t,e){switch(t.direction){case"Left":t.point.x>n.left&&(e=t.point.x-n.left>e?t.point.x-n.left+e:e);break;case"Right":t.point.xe?n.right-t.point.x+e:e);break;case"Top":t.point.y>n.top&&(e=t.point.y-n.top>e?t.point.y-n.top+e:e);break;case"Bottom":t.point.ye?n.bottom-t.point.y+e:e)}return e}function Ol(n,t){var e;switch(n.direction){case"Left":case"Right":var i={x:t.point.x,y:n.point.y};e=R.equals(n.point,i)||R.equals(t.point,i)?[n.point,t.point]:[n.point,i,t.point];break;case"Top":case"Bottom":var r={x:n.point.x,y:t.point.y};e=R.equals(n.point,r)||R.equals(t.point,r)?[n.point,t.point]:[n.point,r,t.point]}return e}function Ys(n,t,e,i,r,s){void 0===s&&(s=!1),i||(i=20),s&&t.direction!==e.direction&&(i="Left"===t.direction||"Right"===t.direction?Math.floor(.5*Math.abs(t.point.x-e.point.x)):Math.floor(.5*Math.abs(t.point.y-e.point.y)));var l,h,u,o=n.sourcePortWrapper,c=e.point.x-t.point.x,d=e.point.y-t.point.y;if(!r&&(Math.abs(c)<.001||Math.abs(d)<.001)&&void 0===e.direction)return[t.point,e.point];if(void 0===n.targetWrapper&&Math.abs(c)<=31&&Math.abs(d)<=31){if("Left"===t.direction||"Right"===t.direction?Math.abs(d)<12&&(t.direction=t.point.y>e.point.y?"Top":"Bottom"):Math.abs(c)<12&&(t.direction=t.point.x>e.point.x?"Left":"Right"),Math.abs(c)>12||Math.abs(d)>12)return Ol(t,e);i+=5}return"Left"===t.direction||"Right"===t.direction?("Right"===t.direction?(void 0!==e.direction&&"Right"===e.direction&&(i=Math.max(t.point.x,e.point.x)-t.point.x+i),t.point.x>e.point.x&&void 0===o&&(i=-i)):(void 0!==e.direction&&"Left"===e.direction&&(i=t.point.x-Math.min(t.point.x,e.point.x)+i),(t.point.x>e.point.x||void 0!==o||"Left"===t.direction)&&(i=-i)),u=e.point.y-t.point.y,l=Fn(t.point,i,0),0!=(u=e.point.y-l.y)&&(h=Fn(l,e.point.y-l.y,90))):("Top"===t.direction||"Bottom"===t.direction)&&("Bottom"===t.direction?void 0!==e.direction&&"Bottom"===e.direction&&(i=Math.max(t.point.y,e.point.y)-t.point.y+i):(void 0!==e.direction&&"Top"===e.direction&&(i=t.point.y-Math.min(t.point.y,e.point.y)+i),(t.point.y>e.point.y||void 0!==o||"Top"===t.direction)&&(i=-i)),u=e.point.x-t.point.x,l=Fn(t.point,i,90),0!=(u=e.point.x-l.x)&&(h=Fn(l,e.point.x-l.x,0))),0===u?[t.point,e.point]:[t.point,l,h,e.point]}function EI(n,t,e,i,r,s){var o;switch(void 0===r&&(r=20),void 0===s&&(s=!1),void 0===e?(n.margin={left:2,right:2,top:2,bottom:2},t.margin={left:0,right:5,top:0,bottom:5},s&&(n.margin={left:10,right:10,top:10,bottom:10},t.margin={left:10,right:10,top:10,bottom:10},"Left"===n.direction?(r=Ox(n,t,e,r),n.corners.left-t.corners.right>=5&&(r=Math.abs(n.point.x-n.corners.left)+.5*Math.floor(n.corners.left-t.corners.right))):"Right"===n.direction?(r=kx(n,t,r,e),t.corners.left-n.corners.right>=5&&(r=Math.abs(n.point.x-n.corners.right)+.5*Math.floor(t.corners.left-n.corners.right))):"Top"===n.direction?(r=Nx(n,t,e,r),n.corners.top-t.corners.bottom>=5&&(r=Math.abs(n.point.y-n.corners.top)+.5*Math.floor(n.corners.top-t.corners.bottom))):"Bottom"===n.direction&&(r=Px(n,t,r,e),t.corners.top-n.corners.bottom>=5&&(r=Math.abs(n.point.y-n.corners.bottom)+.5*Math.floor(t.corners.top-n.corners.bottom))))):("Bottom"===n.direction?s?t.corners.top-n.corners.bottom<20&&(r=t.corners.bottom-n.point.y+25):t.corners.top>n.corners.bottom&&t.corners.top-n.corners.bottom<20&&(r=(t.corners.top-n.corners.bottom)/2):"Top"===n.direction?s?n.corners.top-t.corners.bottom<20&&(r=n.point.y-t.corners.top+25):t.corners.bottomn.corners.right&&t.corners.left-n.corners.right<20&&(r=(t.corners.left-n.corners.right)/2):"Left"===n.direction&&(s?n.corners.left-t.corners.right<20&&(r=n.point.x-t.corners.left+25):t.corners.rightt.point.y||"Top"===t.direction&&n.point.yt.point.x||"Left"===t.direction&&n.point.xh||e.corners.top-e.margin.top<=i.point.y&&e.corners.bottom+e.margin.bottom>=i.point.y))if(!s||"Top"!==e.direction&&"Bottom"!==e.direction)c=Math.min(Math.abs(i.corners.left-e.corners.right)/2,20),h=e.corners.right-n.x+c;else{var c=Math.abs(i.corners.left-e.corners.right)/2;h=e.corners.right-n.x+c}else h="Top"===e.direction&&n.y>i.point.y||"Bottom"===e.direction&&n.y=e.corners.left-e.margin.left&&n.x<=e.corners.right+e.margin.right?Math.min(i.corners.left,e.corners.left)-n.x-20:i.corners.left-n.x-20;break;case"Right":if(e.corners.left-e.margin.left>i.corners.right+i.margin.right&&(e.corners.left-e.margin.right-i.corners.right>h||e.corners.top-e.margin.top<=i.point.y&&e.corners.bottom+e.margin.bottom>=i.point.y))if(!s||"Top"!==e.direction&&"Bottom"!==e.direction)c=Math.min(Math.abs(e.corners.left-i.corners.right)/2,20),h=e.corners.left-n.x-c;else{c=Math.abs(e.corners.left-i.corners.right)/2;h=e.corners.left-n.x-c}else h="Top"===e.direction&&n.y>i.point.y||"Bottom"===e.direction&&n.y=e.corners.left-e.margin.left&&n.x<=e.corners.right+e.margin.right?Math.max(i.corners.right,e.corners.right)-n.x+20:i.corners.right-n.x+20}o=Fn(n,h,0),a=Fn(o,i.point.y-n.y,90),l=i.point}else if("vertical"===t){switch(i.direction){case"Top":e.corners.bottom+e.margin.bottomh||e.corners.left-e.margin.left<=i.point.x&&e.corners.right+e.margin.right>=i.point.x)?!s||"Right"!==e.direction&&"Left"!==e.direction?(c=Math.min(Math.abs(i.corners.top-e.corners.bottom)/2,20),h=e.corners.bottom-n.y+c):(c=Math.abs(i.corners.top-e.corners.bottom)/2,h=e.corners.bottom-n.y+c):h="Left"===e.direction&&n.x>i.point.x||"Right"===e.direction&&n.x=e.corners.top-e.margin.top&&n.y<=e.corners.bottom+e.margin.bottom?Math.min(i.corners.top,e.corners.top)-n.y-20:i.corners.top-n.y-20;break;case"Bottom":e.corners.top-e.margin.top>i.corners.bottom+i.margin.bottom&&(e.corners.top-e.margin.top-i.corners.bottom>h||e.corners.left-e.margin.left<=i.point.x&&e.corners.right+e.margin.right>=i.point.x)?!s||"Right"!==e.direction&&"Left"!==e.direction?(c=Math.min(Math.abs(e.corners.top-i.corners.bottom)/2,20),h=e.corners.top-n.y-c):(c=Math.abs(e.corners.top-i.corners.bottom)/2,h=e.corners.top-n.y-c):h="Left"===e.direction&&n.x>i.point.x||"Right"===e.direction&&n.x=e.corners.top-e.margin.top&&n.y<=e.corners.bottom+e.margin.bottom?Math.max(i.corners.bottom,e.corners.bottom)-n.y+20:i.corners.bottom-n.y+20}o=Fn(n,h,90),a=Fn(o,i.point.x-n.x,0),l=i.point}r.push(o),r.push(a),r.push(l)}function Nx(n,t,e,i){return n.corners.top-n.margin.top>t.corners.top+t.margin.top&&n.corners.top-n.margin.top<=t.corners.bottom+t.margin.bottom?(("Right"===t.direction&&n.point.xt.point.x)&&(i+=n.corners.top-t.corners.top),i+=n.point.y-n.corners.top):i+=void 0!==e&&"Left"!==e&&"Right"===t.direction&&n.point.xt.corners.left-t.margin.left&&n.corners.left-n.margin.left<=t.corners.right+t.margin.right?(("Bottom"===t.direction&&n.point.yt.point.y)&&(i+=n.corners.left-t.corners.left),i+=n.point.x-n.corners.left):i+=void 0!==e&&"Top"!==e&&"Bottom"===t.direction&&n.point.y=t.corners.left-t.margin.left?(("Bottom"===t.direction&&n.point.yt.point.y)&&(e+=t.corners.right-n.corners.right),e+=n.corners.right-n.point.x):e+=void 0!==i&&"Top"!==i&&"Bottom"===t.direction&&n.point.y=t.corners.top-t.margin.top?(("Right"===t.direction&&n.point.xt.point.x)&&(e+=t.corners.bottom-n.corners.bottom),e+=n.corners.bottom-n.point.y):e+=void 0!==i&&"Left"!==i&&"Right"===t.direction&&n.point.xp&&d=u&&d=f&&d<=p?"Left":"Right"}function _n(n){switch(n){case"Top":return"Bottom";case"Bottom":return"Top";case"Left":return"Right";case"Right":return"Left"}return"auto"}var w3=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Ac=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},DI=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return w3(t,n),Ac([I()],t.prototype,"width",void 0),Ac([I()],t.prototype,"height",void 0),t}(Ee),Rre=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return w3(t,n),Ac([I()],t.prototype,"width",void 0),Ac([I()],t.prototype,"height",void 0),Ac([I()],t.prototype,"fit",void 0),Ac([I()],t.prototype,"description",void 0),Ac([I()],t.prototype,"template",void 0),Ac([I()],t.prototype,"tooltip",void 0),t}(Ee),Hre=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),kl=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},C3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Hre(t,n),kl([I("")],t.prototype,"id",void 0),kl([I(Number.MIN_VALUE)],t.prototype,"zIndex",void 0),kl([re({},Jn)],t.prototype,"margin",void 0),kl([I(!0)],t.prototype,"visible",void 0),kl([re({},Dd)],t.prototype,"tooltip",void 0),kl([I(!1)],t.prototype,"excludeFromLayout",void 0),kl([I()],t.prototype,"addInfo",void 0),kl([I("None")],t.prototype,"flip",void 0),kl([I("All")],t.prototype,"flipMode",void 0),kl([re({},Rre)],t.prototype,"symbolInfo",void 0),t}(Ee),Bre=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),es=function(n){function t(e,i,r,s){var o=n.call(this)||this;return o.data="",o.nodeId="",o.annotationId="",o.diagramId="",o.diagramId=i,o.nodeId=e,o.annotationId=r,o.templateFn=UF(s),o}return Bre(t,n),t.prototype.getNodeTemplate=function(){return this.templateFn},Object.defineProperty(t.prototype,"content",{get:function(){return this.data},set:function(e){this.data=e,this.canReset||(this.canReset=!0,this.isTemplate||(this.template=Hh(this,!0)),this.canReset=!1,this.isDirt=!0)},enumerable:!0,configurable:!0}),t}(hs),zx=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),cs=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},E3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return zx(t,n),cs([I("")],t.prototype,"id",void 0),cs([I("transparent")],t.prototype,"fill",void 0),cs([I("black")],t.prototype,"iconStrokeColor",void 0),cs([I(0)],t.prototype,"iconStrokeWidth",void 0),cs([I(!0)],t.prototype,"visibility",void 0),cs([I(10)],t.prototype,"width",void 0),cs([I(10)],t.prototype,"height",void 0),cs([I("transparent")],t.prototype,"handleStrokeColor",void 0),cs([I(1)],t.prototype,"handleStrokeWidth",void 0),cs([I("")],t.prototype,"pathData",void 0),cs([I(0)],t.prototype,"cornerRadius",void 0),cs([re({left:0,right:0,top:0,bottom:0},Jn)],t.prototype,"padding",void 0),cs([re({},Dd)],t.prototype,"tooltip",void 0),t}(Ee),D3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return zx(t,n),cs([re({x:0,y:0},R)],t.prototype,"offset",void 0),cs([re({},Jn)],t.prototype,"margin",void 0),t}(E3),xI=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return zx(t,n),cs([I(.5)],t.prototype,"offset",void 0),cs([I("Center")],t.prototype,"alignment",void 0),cs([re({x:0,y:0},R)],t.prototype,"displacement",void 0),t}(E3);function xd(n){return n?n instanceof Kn||n instanceof Or?n.constraints&Nr.Select:n instanceof de?n.constraints&qe.Select:n.constraints&ie.Select:1}function ro(n){return n?n instanceof Kn||n instanceof Or?n.constraints&Nr.Drag:n instanceof de?n.constraints&qe.Drag:n instanceof ti?1:n.constraints&ie.Drag:1}function Fre(n,t){return n instanceof de?n.constraints&qe.PointerEvents:n.constraints&ie.PointerEvents}function TI(n){return n instanceof de?n.constraints&qe.Delete:n.constraints&ie.Delete}function AI(n){return n.constraints&qe.DragSourceEnd}function LI(n){return n.constraints&qe.DragTargetEnd}function NI(n){return n.constraints&qe.DragSegmentThumb}function OI(n){return n instanceof Kn||n instanceof Or?n.constraints&Nr.Rotate:n.constraints&ie.Rotate}function kI(n){return n.constraints&ie.Shadow}function ua(n){return n instanceof te&&n.constraints&ie.InConnect?n.constraints&ie.InConnect:0}function kh(n){return n&&n.constraints&&!(n.constraints&ai.None)&&n.constraints&ai.InConnect?n.constraints&ai.InConnect:0}function Ph(n){return n instanceof te&&n.constraints&ie.OutConnect?n.constraints&ie.OutConnect:0}function Td(n){return n&&n.constraints&&!(n.constraints&ai.None)&&n.constraints&ai.OutConnect?n.constraints&ai.OutConnect:0}function Pl(n,t){var e=0;return n instanceof Kn||n instanceof Or?e=n.constraints&Nr.Resize:n&&("SouthEast"===t?e=n.constraints&ie.ResizeSouthEast:"East"===t?e=n.constraints&ie.ResizeEast:"NorthEast"===t?e=n.constraints&ie.ResizeNorthEast:"South"===t?e=n.constraints&ie.ResizeSouth:"North"===t?e=n.constraints&ie.ResizeNorth:"SouthWest"===t?e=n.constraints&ie.ResizeSouthWest:"West"===t?e=n.constraints&ie.ResizeWest:"NorthWest"===t&&(e=n.constraints&ie.ResizeNorthWest)),e}function PI(n){return n instanceof de?n.constraints&qe.AllowDrop:n.constraints&ie.AllowDrop}function Ds(n){return n.constraints&nt.Virtualization}function _v(n){return n.tool&ni.SingleSelect}function Uv(n){return n.tool&ni.MultipleSelect}function Lc(n){return n.tool&ni.ZoomPan}function zI(n){return n.tool&ni.ContinuousDraw}function x3(n){return n.tool&ni.DrawOnce}function RI(n){return n.tool&ni.SingleSelect||n.tool&ni.MultipleSelect}function jv(n){return n.constraints&nt.UserInteraction}function T3(n){return n.constraints&nt.ZoomTextEdit}function Vv(n){return function Yre(n){return n.constraints&nt.ApiUpdate}(n)||n.diagramActions&ee.ToolAction}function Rx(n,t){return n.constraints&ai.Draw}function Hx(n,t){return n.constraints&ai.Drag}function HI(n){return!(n&Ga.DrawSelectorBorder)}function A3(n){return!!(n&Ga.PreventRenderSelector)}var Bx=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Wv=function(n){function t(){var e=null!==n&&n.apply(this,arguments)||this;return e.childTable=[],e.cellStyle={},e.desiredRowHeight=[],e.desiredCellWidth=[],e}return Bx(t,n),t.prototype.rowDefinitions=function(){return this.rowDefns},t.prototype.columnDefinitions=function(){return this.colDefns},t.prototype.addObject=function(e,i,r,s,o){if(this.rows.length>=i){var a=this.rows[parseInt(i.toString(),10)];if(a.cells.length>r){o=o||1,s=s||1;var l=a.cells[parseInt(r.toString(),10)];l.columnSpan=Math.max(o,l.columnSpan),l.rowSpan=Math.max(s,l.rowSpan);var h=new $re;(h=e).rowId=i,h.columnId=r,h.columnSpan=o,this.childTable[h.id]=h,this.addObjectToCell(h,l)}}},t.prototype.addObjectToCell=function(e,i){i.children||(i.children=[]),e.style.strokeColor="black",e.style.strokeWidth=1,i.children.push(e)},t.prototype.updateProperties=function(e,i,r,s){this.offsetX=e,this.offsetY=i,this.width=r,this.height=s},t.prototype.setDefinitions=function(e,i){this.rowDefns=e,this.colDefns=i,this.children=[],this.rows=this.rows||[];for(var r=0;r0){for(var h=0;hi&&this.updateRowHeight(e,l,!1)}},t.prototype.setTextRefresh=function(e){if(e.children&&e.children.length)for(var i=e.children,r=0;ri&&this.updateColumnWidth(e,a,!1)}},t.prototype.calculateCellWidth=function(e){for(var i,r,s,o=0;os.bounds.width&&(0===s.children.length||void 0===s.children[0].maxWidth)?s.outerBounds.width:s.bounds.width,i=i?is.bounds.height?s.outerBounds.height:s.bounds.height,i=i?i0?e.children[0]:void 0;if(a&&1===e.columnSpan){o="Width"===i?a.bounds.right:a.bounds.bottom,s||(s="Width"===i?a.bounds.width:a.bounds.height);for(var l=0;lo){var d=c-o+("Width"===i?a.bounds.width:a.bounds.height);s&&(s=s0?this.rowDefns.splice(e,0,i):this.rowDefns.push(i);var s=new L3;s.cells=[],(new Ad).width=this.width,this.addCellInRow(this.colDefns,i,s),e>this.rows.length-1?this.rows.push(s):this.rows.splice(e,0,s),r&&(this.measure(new me(this.width,this.height)),this.arrange(this.desiredSize))},t.prototype.addColumn=function(e,i,r){var s,o,a,l,h=this.rows;this.colDefns.length>0?this.colDefns.splice(e,0,i):this.colDefns.push(i),void 0!==this.width&&(this.width+=i.width);for(var c=0;cs.cells.length-1?s.cells.push(l):s.cells.splice(e,0,l),this.children.push(l);r&&(this.measure(new me(this.width,this.height)),this.arrange(this.desiredSize))},t.prototype.removeRow=function(e){var i,r,o=this.rows[parseInt(e.toString(),10)];this.height-=this.rowDefns[parseInt(e.toString(),10)].height;for(var a=0;a0){var r=0,s=0;i=new me(0,0),this.calculateSize();for(var o=0,a=this.rows;o0){for(var o=this.offsetX-e.width*this.pivot.x,a=this.offsetY-e.height*this.pivot.y,l=o,h=0,c=this.rows;h1&&this.children.splice(this.children.indexOf(p)+1,p.columnSpan-1),p.rowSpan>1)for(y=s,S=0;y+p.rowSpan-10){for(var c=0;c0?1:0,v=0;v0||a.outEdges.length>0))for(f=a.inEdges.concat(a.outEdges),s=0;s0)for(o=0;o1)for(a=1;a0))if(h=n.wrapper.children[0],"Horizontal"===e.orientation)for(o=e.header&&e.hasHeader?h.rows[1]:h.rows[0],r=0;r0){var e=void 0;t.lineRoutingModule&&t.constraints&nt.LineRouting&&t.lineRoutingModule.renderVirtualRegion(t,!0);for(var i=0;i0?o+1:o)].height=t.wrapper.height;else if(t.isPhase)for(l[t.rowIndex-o].offset=t.wrapper.height,p=0;p0?1:0)].width=t.wrapper.width}function FI(n,t){var i=n.shape,r=i.header&&i.hasHeader?1:0;return"Horizontal"===i.orientation?t.rowIndex-(r+=i.phases.length>0?1:0):t.columnIndex-(i.phaseSize&&i.phases.length>0?1:0)}function _I(n){var t=0,e=n.shape;return"Horizontal"===e.orientation&&(t=e.header&&e.hasHeader?1:0),e.phases.length>0&&e.phaseSize&&(t+=1),t}function UI(n,t,e,i){var r=n.shape;if(r.phases.length>0){var s=t.nameTable[r.phases[parseInt(i.toString(),10)].header.id];s&&s.maxWidth0?u+1:u);var w=Nc(n,o),C=void 0!==i?i:l.lanes.length;if(u+=C,r={element:M,cause:n.diagramActions,diagramAction:n.getDiagramAction(n.diagramActions),state:"Changing",type:"Addition",cancel:!1,laneIndex:C},n.triggerEvent(Ce.collectionChange,r),!r.cancel){if(c){var D=new Yv;D.height=e.height,o.addRow(u,D,!1),s.height=void 0!==s.height?s.height+e.height:s.height,s.wrapper.height=o.height=s.height}else{var A=new Ad;A.width=e.width,o.addColumn(C+1,A,!1),s.width&&(s.width+=e.width,s.wrapper.width=o.width=s.width),n.diagramActions&ee.UndoRedo||(o.rows[0].cells[0].columnSpan+=1)}n.diagramActions&ee.UndoRedo||(M.id=""===M.id?Qe():M.id),void 0!==i?l.lanes.splice(i,0,M):l.lanes.push(M),r={element:M,cause:n.diagramActions,diagramAction:n.getDiagramAction(n.diagramActions),state:"Changed",type:"Addition",cancel:!1,laneIndex:C},n.triggerEvent(Ce.collectionChange,r),O3(o,n,s,u,C,c),h="Horizontal"===l.orientation?n.nameTable[o.rows[parseInt(u.toString(),10)].cells[0].children[0].id]:l.header&&l.hasHeader?n.nameTable[o.rows[1].cells[parseInt(u.toString(),10)].children[0].id]:n.nameTable[o.rows[0].cells[parseInt(u.toString(),10)].children[0].id],n.diagramActions&ee.UndoRedo||(d={type:"LaneCollectionChanged",changeType:"Insert",undoObject:$(M),redoObject:$(h),category:"Internal"},n.addHistoryEntry(d)),Xf(n,s,"Horizontal"===l.orientation?u:l.header&&l.hasHeader?1:0),Gf(s),Oc(n,s);var P=!1;if((f=e.children)&&f.length>0)for(p=0;p0){var o=t.children[0],a=n.nameTable[o.id];(function sne(n,t,e){return n.left-(e.left||0)<=t.x&&n.right+(e.right||0)>=t.x&&n.top-(e.top||0)<=t.y&&n.bottom+(e.bottom||0)>=t.y})(o.bounds,e,r)&&(n.addChild(a,i),s=!0)}return s}function one(n,t,e){if("SwimLane"===t.shape.type){var i=void 0,r=void 0,s=void 0,a=void 0,l=void 0,h=void 0,c=t.wrapper.bounds.x,d=t.wrapper.bounds.y,u=t.shape,f=u.padding,p=u.phases,g=void 0,v=t.wrapper.children[0],y="Horizontal"===u.orientation;if(i=u.header&&u.hasHeader?0:-1,u.phases.length>0&&(i+=1),e.offset>(y?u.lanes[0].header.width:u.lanes[0].header.height)){for(h=0;he.offset){if(g=h>0?e.offset-(h>0?p[h-1]:s).offset:e.offset,y){var b=v.columnDefinitions()[parseInt(h.toString(),10)];b.width-=g,(a=n.nameTable[u.phases[parseInt(h.toString(),10)].header.id]).maxWidth=a.wrapper.maxWidth=b.width,v.updateColumnWidth(h,b.width,!1);var M=new Ad;M.width=g,l=h,v.addColumn(h,M,!1);break}var w=v.rowDefinitions()[h+i];w.height-=g,a=n.nameTable[u.phases[parseInt(h.toString(),10)].header.id],v.updateRowHeight(h+i,w.height,!1);var C=new Yv;C.height=g,l=h,v.addRow(h+i,C,!1);break}if(n.diagramActions&ee.UndoRedo&&void 0===l&&(D=n.historyManager.currentEntry.next).isLastPhase&&function ane(n,t,e,i,r,s){var a=t.shape.phases[n-2],l=e.previousPhase.offset;if(r){var h=i.columnDefinitions()[n-1],c=new Ad;n>1?(c.width=h.width-(l-a.offset),h.width=l-a.offset):(c.width=h.width-l,h.width=l),i.updateColumnWidth(n-1,h.width,!1),i.addColumn(n,c,!1)}else{h=i.rowDefinitions()[parseInt(n.toString(),10)];var d=new Yv;n>1?(d.height=e.undoObject.offset-l,h.height=l-a.offset):(d.height=h.height-l,h.height=l),i.updateRowHeight(n,h.height,!1),i.addRow(1+n,d,!1)}}(l=p.length,t,D,v,y),l>=0){var A=new lb(t.shape,"phases",e,!0);if(n.diagramActions&ee.UndoRedo||(A.id+=Qe()),u.phases.splice(l,0,A),Fx(v,n,t,i,y,l),y){if(r=n.nameTable[v.rows[parseInt(i.toString(),10)].cells[parseInt(l.toString(),10)].children[0].id],0===l&&u.header&&u.hasHeader){v.rows[0].cells[0].children=v.rows[0].cells[1].children,v.rows[0].cells[1].children=[];for(var x=v.rows[0],P=0;Pl+1){var O=n.nameTable[v.rows[parseInt(i.toString(),10)].cells[l+1].children[0].id];v.updateColumnWidth(l+1,L[l+1].width,!0,f),O.maxWidth=O.wrapper.maxWidth=L[l+1].width}t.width=t.wrapper.width=t.wrapper.children[0].width=v.width}else{r=n.nameTable[v.rows[i+l].cells[0].children[0].id];var N=v.rowDefinitions(),T=N[i+l].height;(function hne(n,t,e,i,r){for(var o,a,l=e.rows[parseInt(i.toString(),10)],h=e.rows[i+1],c=e.rows[i-1],d=1;di+l+1&&v.updateRowHeight(i+l+1,T=N[i+l+1].height,!0,f),t.height=t.wrapper.height=t.wrapper.children[0].height=v.actualSize.height}if(Gf(t),t.width=t.wrapper.actualSize.width,Oc(n,t),n.drag(t,c-t.wrapper.bounds.x,d-t.wrapper.bounds.y),BI(t,n),n.commandHandler.select(r),!(n.diagramActions&ee.UndoRedo)){var D={type:"PhaseCollectionChanged",changeType:"Insert",undoObject:$(A),redoObject:$(r),category:"Internal"};n.addHistoryEntry(D)}n.updateDiagramObject(t)}}}}function H3(n,t,e,i,r,s,o){var a,l,p,h=t.shape,c="Horizontal"===h.orientation,d=t.wrapper.children[0],g=c?s:o;e?(a=c?e.bounds.x+e.bounds.width:e.bounds.x,l=c?e.bounds.y:e.bounds.y+e.bounds.height):(a=d.bounds.x,l=r.bounds.y);var v=new Ne(a,l,i.desiredCellWidth,i.desiredCellHeight),S=Qv(n,0,t,{id:t.id+(c?h.lanes[g-2]:h.lanes[g-1]).id+Qe()[0],rowIndex:s,columnIndex:o,width:i.minWidth,height:i.minHeight,style:(c?h.lanes[g-2]:h.lanes[g-1]).style,constraints:ie.Default|ie.AllowDrop,container:{type:"Canvas",orientation:c?"Horizontal":"Vertical"}},!1,!1,!0);if(S.children[0].isCalculateDesiredSize=!1,d.addObject(S,s,o),r&&r.children&&r.children.length)for(p=0;p1)for(var p=1;ph.margin.left&&(h.margin.left=f)):(h.margin.top-=e.desiredCellHeight,f>h.margin.top&&(h.margin.top=f)))}(n,r,i,v,S,c,e)}function B3(n,t,e){if("SwimLane"===t.shape.type&&("ResizeSouth"===e||"ResizeEast"===e)){var i=t.shape,r=t.wrapper.children[0],s=void 0,o=void 0;"ResizeSouth"===e?"Vertical"===i.orientation?s=r.rows[r.rows.length-1].cells[0]:(o=r.rows.length-1,s=r.rows[parseInt(o.toString(),10)].cells[r.rows[parseInt(o.toString(),10)].cells.length-1]):(o=i.header&&i.hasHeader?1:0,s=r.rows[parseInt(o.toString(),10)].cells[r.rows[parseInt(o.toString(),10)].cells.length-1]),n.commandHandler.select(n.nameTable[s.children[0].id])}}function jI(n,t,e,i,r,s){var o,a,l,c,u,f,p,d=Qe(),g=n.shape,v=g.phases,y=n.offsetX-n.wrapper.actualSize.width/2,S=n.offsetY-n.wrapper.actualSize.height/2;if("Vertical"===g.orientation&&(S+=g.header&&g.hasHeader?g.header.height:0),!s)for(r||(n.id+=d,g&&g.header&&g.hasHeader?g.header.id+=d:g.header=void 0),o=0;v&&o0&&s.columnIndex>0||s.isLane)?(a=function Sne(n,t,e){for(var i=new Ne,r="SwimLane"===n.shape.type?n.wrapper.children[0].rows:n.wrapper.rows,s=e?1:0;s=0;a--)i?i.id===o.children[parseInt(a.toString(),10)].id&&o.children.splice(a,1):(n.removeDependentConnector(o.children[parseInt(a.toString(),10)]),n.diagramActions&ee.UndoRedo||(n.diagramActions=n.diagramActions|ee.UndoRedo,s=!0),n.remove(o.children[parseInt(a.toString(),10)]),o.children.splice(a,1),s&&(n.diagramActions=n.diagramActions&~ee.UndoRedo))}function dne(n){return n.children[0]}function qv(n,t){t&&(n.nodes.splice(n.nodes.indexOf(t),1),n.removeFromAQuad(t),n.removeObjectsFromLayer(t),delete n.nameTable[t.id],n.removeElements(t))}function _3(n,t,e,i){var r;if("SwimLane"===e.shape.type){var s=e.shape,o=void 0;if(1===s.lanes.length)n.remove(e);else{var a=e.wrapper.bounds.x,l=e.wrapper.bounds.y,h=void 0,c=void 0,d=void 0,u=void 0,p=e.wrapper.children[0];if(o=i?s.lanes.indexOf(i):FI(e,t),r={element:t,cause:n.diagramActions,diagramAction:n.getDiagramAction(n.diagramActions),state:"Changing",type:"Removal",cancel:!1,laneIndex:o},n.triggerEvent(Ce.collectionChange,r),!r.cancel){var g=s.lanes[parseInt(o.toString(),10)],v=g.children;g.children=[];for(var y=0;y0)for(u=0;u0)for(u=0;u0)for(e=0;e1){c===l.phases.length-1&&(o=!0,a=$(l.phases[c-1]));var u=$(l.phases[parseInt(c.toString(),10)]);if(l.phases.splice(c,1),!(n.diagramActions&ee.UndoRedo)){var f={type:"PhaseCollectionChanged",changeType:"Remove",undoObject:u,previousPhase:a,redoObject:$(t),category:"Internal",isLastPhase:o};n.addHistoryEntry(f)}"Horizontal"===l.orientation?function fne(n,t,e,i){var r,s,o,a,l,h,c,d,u,f,p,g;for(i=void 0!==i?i:e.columnIndex,c=0;c1&&(s=r.cells[parseInt(i.toString(),10)],l=(o=r.cells.length-1===i?r.cells[i-1]:r.cells[i+1]).children[0],s.children.length>0))if(p=n.nameTable[(a=s.children[0]).id],0===o.children.length&&s.children.length>0)o.children=s.children,o.columnSpan=s.columnSpan-1;else{for(d=0;d0){var M=s.children[0],w=n.nameTable[M.id];if(i=e.x&&a.bounds.y<=e.y&&a.bounds.bottom>=e.y){var l=void 0,h=a.bounds.y,c=a.bounds.x,d=n.nameTable[r.parentId]||r;if("SwimLane"===d.shape.type)o=Zv(r,d,t,n,!0);else{var f=n.nameTable[r.parentId]||r,p=f.shape;l=f.wrapper,a.actualSize.widtha.outerBounds.x)&&(void 0!==r.rowIndex?(l.updateColumnWidth(r.columnIndex,a.outerBounds.width,!0),"Horizontal"===p.orientation&&p.phaseSize&&UI(f,n,a,r.columnIndex),Oc(n,f),n.drag(f,c-a.bounds.x,h-a.bounds.y)):n.scale(r,1+(a.outerBounds.width-a.actualSize.width)/a.actualSize.width,1,a.outerBounds.xa.outerBounds.y)&&(void 0!==r.rowIndex?(l.updateRowHeight(r.rowIndex,a.outerBounds.height,!0),n.drag(f,c-a.bounds.x,h-a.bounds.y)):n.scale(r,1,1+(a.outerBounds.height-a.actualSize.height)/a.actualSize.height,a.outerBounds.y=e.x&&a.bounds.y<=e.y&&a.bounds.bottom>=e.y)&&!(t.constraints&ie.AllowMovingOutsideLane)){var l=$(t);n.clearSelection(),W3(n,t),t.parentId="",t.parentObj=n,t.propName="nodes";var h={type:"ChildCollectionChanged",category:"Internal",undoObject:l,redoObject:$(t)};n.addHistoryEntry(h),n.commandHandler.isContainer&&(n.commandHandler.isContainer=!1,n.endGroupAction()),Y3(t,n)}n.protectPropertyChange(o)}}function VI(n,t){var e,i,r;return n.enableServerDataBinding(!1),ce()||(n.selectedObject.helperObject?r=n.selectedObject.helperObject:(n.selectedItems.nodes.length>0||n.selectedItems.connectors.length>0)&&(t instanceof ti&&t.nodes.length+t.connectors.length===1?(e=t.nodes.length>0?t.nodes[0]:t.connectors[0],i=n.selectedItems.wrapper.children[0]):(e=t,i=n.selectedItems.wrapper),n.selectedObject.actualObject=e,!n.currentSymbol&&(e.isLane&&Vx(e,n)&&Dn(n,e)||!e.isLane&&Dn(n,e)||n.constraints&nt.LineRouting&&n.selectedItems.nodes.length>0))&&(r=function Ine(n,t){for(var e,i={},r=0,s=Object.keys(t);r=t.x-e&&n.x<=t.x+e&&n.y>=t.y-e&&n.y<=t.y+e}function $a(n){return n.selectedItems.nodes.length>0||n.selectedItems.connectors.length>0}function G3(n){return 1===n.selectedItems.connectors.length&&!n.selectedItems.nodes.length}function _r(n,t,e,i){if(void 0===e&&(e=!0),t instanceof ti)return!0;if(t instanceof te)for(;t;){if(-1!==n.selectedItems.nodes.indexOf(t)&&void 0===n.selectedItems.annotation)return!0;if(e)break;t=n.nameTable[t.parentId]}else if(t instanceof de){if(-1!==n.selectedItems.connectors.indexOf(t)&&void 0===n.selectedItems.annotation)return!0}else if((t instanceof Kn||t instanceof Or)&&n.selectedItems.annotation&&n.selectedItems.wrapper.children[0].id===i.id)return!0;return!1}var Wx={None:"default",Rotate:"crosshair",Select:"default",Drag:"move",ResizeWest:"w-resize",ResizeEast:"e-resize",ResizeSouth:"s-resize",ResizeNorth:"n-resize",Draw:"crosshair",PortDraw:"crosshair",ResizeNorthEast:"ne-resize",ResizeNorthWest:"nw-resize",ResizeSouthEast:"se-resize",ResizeSouthWest:"sw-resize",ConnectorSourceEnd:"move",ConnectorTargetEnd:"move",BezierSourceThumb:"move",BezierTargetThumb:"move",OrthoThumb:"move",SegmentEnd:"move",Pan:"grab",Hyperlink:"pointer",PortDrag:"pointer",LabelSelect:"pointer",LabelDrag:"move",LabelRotate:"crosshair",LabelResizeWest:"w-resize",LabelResizeEast:"e-resize",LabelResizeSouth:"s-resize",LabelResizeNorth:"n-resize",LabelResizeNorthEast:"ne-resize",LabelResizeNorthWest:"nw-resize",LabelResizeSouthEast:"se-resize",LabelResizeSouthWest:"sw-resize"},ds=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Nd=function(n,t,e,i){return new(e||(e=Promise))(function(r,s){function o(h){try{l(i.next(h))}catch(c){s(c)}}function a(h){try{l(i.throw(h))}catch(c){s(c)}}function l(h){h.done?r(h.value):new e(function(c){c(h.value)}).then(o,a)}l((i=i.apply(n,t||[])).next())})},Od=function(n,t){var i,r,s,o,e={label:0,sent:function(){if(1&s[0])throw s[1];return s[1]},trys:[],ops:[]};return o={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function a(h){return function(c){return function l(h){if(i)throw new TypeError("Generator is already executing.");for(;e;)try{if(i=1,r&&(s=2&h[0]?r.return:h[0]?r.throw||((s=r.return)&&s.call(r),0):r.next)&&!(s=s.call(r,h[1])).done)return s;switch(r=0,s&&(h=[2&h[0],s.value]),h[0]){case 0:case 1:s=h;break;case 4:return e.label++,{value:h[1],done:!1};case 5:e.label++,r=h[1],h=[0];continue;case 7:h=e.ops.pop(),e.trys.pop();continue;default:if(!(s=(s=e.trys).length>0&&s[s.length-1])&&(6===h[0]||2===h[0])){e=0;continue}if(3===h[0]&&(!s||h[1]>s[0]&&h[1]-1&&(r=i.fixedUserHandles[parseInt(o.toString(),10)]);this.commandHandler.triggerEvent(Ce.fixedUserHandleClick,{fixedUserHandle:r,element:e.source}),n.prototype.mouseUp.call(this,e)},t}(us),kd=function(n){function t(e,i){var r=n.call(this,e,!0)||this;return r.isConnected=!1,r.endPoint=i,r}return ds(t,n),t.prototype.mouseDown=function(e){return Nd(this,void 0,void 0,function(){var r,s,o,a,l;return Od(this,function(h){if(this.inAction=!0,this.undoElement=void 0,this instanceof pa||(this.undoElement=$(e.source)),n.prototype.mouseDown.call(this,e),e.source&&e.source.connectors&&(this.oldConnector=$(r=e.source.connectors[0])),"BezierSourceThumb"===this.endPoint||"BezierTargetThumb"===this.endPoint)for(s=0;s0))},t.prototype.endAction=function(){n.prototype.endAction.call(this),this.prevPosition=null,this.endPoint=null},t}(us),fa=function(n){function t(e,i){var r=n.call(this,e,!0)||this;return r.currentTarget=null,r.isStartAction=!1,r.canCancel=!1,r.canTrigger=!1,r.objectType=i,r}return ds(t,n),t.prototype.mouseDown=function(e){if(e.source instanceof te||e.source instanceof de){var i=this.commandHandler.getSelectedObject();this.commandHandler.selectObjects([e.source],e.info&&e.info.ctrlKey,i);var r={nodes:[],connectors:[]};e.source instanceof te?r.nodes.push($(e.source)):r.connectors.push($(e.source)),this.undoElement=$(r)}else this.undoElement=$(e.source);this.undoParentElement=this.commandHandler.getSubProcess(e.source),"Port"===this.objectType&&(this.portId=e.sourceWrapper.id),this.commandHandler.insertBlazorConnector(e.source),n.prototype.mouseDown.call(this,e),this.initialOffset={x:0,y:0}},t.prototype.mouseUp=function(e,i){return Nd(this,void 0,void 0,function(){var s,o,a,l,h,c,d,u,p,g,v,y,S,b,M;return Od(this,function(w){if(this.checkPropertyValue(),a=!1,h={nodes:[],connectors:[]},"Port"!==this.objectType){if(e.source instanceof te||e.source instanceof de?(e.source instanceof te?h.nodes.push($(e.source)):h.connectors.push($(e.source)),(o=$(h)).offsetX=(c=e.source.wrapper).offsetX,o.offsetY=c.offsetY):o=$(e.source),("helper"===(l=this.commandHandler.renderContainerHelper(e.source)||e.source||this.commandHandler.renderContainerHelper(e.source)).id||"helper"!==l.id)&&((l instanceof ti&&(Math.round(l.width)===Math.round(this.undoElement.width)&&Math.round(l.height)===Math.round(this.undoElement.height)||l.selectedObjects&&1===l.selectedObjects.length)||!(l instanceof ti))&&(l.offsetX!==this.undoElement.offsetX||l.offsetY!==this.undoElement.offsetY||l.sourcePoint!==this.undoElement.sourcePoint||l.targetPoint!==this.undoElement.targetPoint)||this.isSelectionHasConnector(l))&&(e.source&&(s={offsetX:e.source.wrapper.offsetX,offsetY:e.source.wrapper.offsetY}),g={source:e.source,state:"Completed",oldValue:this.intialValue,newValue:s,target:this.currentTarget,targetPosition:this.currentPosition,allowDrop:(g={source:e.source,state:"Completed",oldValue:this.intialValue,newValue:s,target:this.currentTarget,targetPosition:this.currentPosition,allowDrop:!0,cancel:!1}).allowDrop,cancel:g.cancel},d=!0,"helper"===l.id?this.canTrigger?(this.commandHandler.triggerEvent(Ce.positionChange,g),this.connectorEndPointChangeEvent(g),d=!0):d=!1:(this.commandHandler.triggerEvent(Ce.positionChange,g),this.connectorEndPointChangeEvent(g)),!i&&d&&(this.commandHandler.startGroupAction(),a=!0,M={type:"PositionChanged",redoObject:$(o),undoObject:$(this.undoElement),category:"Internal"},o.nodes[0]&&o.nodes[0].processId&&(u={type:"SizeChanged",category:"Internal",undoObject:this.undoParentElement,redoObject:this.commandHandler.getSubProcess(e.source)},this.commandHandler.addHistoryEntry(u)),this.commandHandler.addHistoryEntry(M))),this.commandHandler.snapPoint(this.prevPosition,this.currentPosition,0,0),this.commandHandler.removeSnap(),this.commandHandler.removeHighlighter(),e.source&&this.currentTarget&&PI(this.currentTarget)&&this.commandHandler.isDroppable(e.source,this.currentTarget)){if(p=!0,this.commandHandler.drop(this.currentElement,this.currentTarget,this.currentPosition),this.currentTarget&&this.currentTarget instanceof de&&!0===this.commandHandler.diagram.enableConnectorSplit)if(this.currentElement&&this.currentElement instanceof te){if(void 0!==this.currentElement.children)for(b=0;b0)for(var s=0;s0)for(var a=0;a0)for(a=0;a0&&e.connectors.length>0)||e.width===this.undoElement.width&&e.height===this.undoElement.height)},t.prototype.mouseMove=function(e){n.prototype.mouseMove.call(this,e);var r,s,i=!1;(r=this.commandHandler.renderContainerHelper(e.source)||e.source)instanceof te||r instanceof de?r instanceof te?r.offsetX===this.undoElement.nodes[0].offsetX&&r.offsetY===this.undoElement.nodes[0].offsetY&&(i=!0):R.equals(r.sourcePoint,this.undoElement.connectors[0].sourcePoint)&&R.equals(r.targetPoint,this.undoElement.connectors[0].targetPoint)&&(i=!0):r.wrapper.offsetX===this.undoElement.wrapper.offsetX&&r.wrapper.offsetY===this.undoElement.wrapper.offsetY&&(i=!0),r&&(s={offsetX:r.wrapper.offsetX,offsetY:r.wrapper.offsetY});var o={source:r,state:"Start",oldValue:s,newValue:s,target:e.target,targetPosition:e.position,allowDrop:!0,cancel:!1};if(o={source:r,state:"Start",oldValue:s,newValue:s,target:e.target,targetPosition:e.position,allowDrop:o.allowDrop,cancel:o.cancel},this.isStartAction||(this.intialValue={offsetX:r.wrapper.offsetX,offsetY:r.wrapper.offsetY}),i&&!ce()&&(this.commandHandler.triggerEvent(Ce.positionChange,o),this.connectorEndPointChangeEvent(o),this.isStartAction=!0),this.currentPosition=e.position,"Port"!==this.objectType){var h=this.initialOffset.x+(this.currentPosition.x-this.prevPosition.x),c=this.initialOffset.y+(this.currentPosition.y-this.prevPosition.y);this.commandHandler.dragOverElement(e,this.currentPosition),this.commandHandler.disConnect(e.source),this.commandHandler.removeSnap();var d,u=void 0,f=this.commandHandler.snapPoint(this.prevPosition,this.currentPosition,h,c);this.initialOffset.x=h-f.x,this.initialOffset.y=c-f.y,r&&(d={offsetX:r.wrapper.offsetX,offsetY:r.wrapper.offsetY},u={offsetX:r.wrapper.offsetX+f.x,offsetY:r.wrapper.offsetY+f.y}),this.currentTarget&&e.target!==this.currentTarget&&this.commandHandler.removeChildFromBPmn(e.source,e.target,this.currentTarget),this.currentTarget=e.target;var p={source:r,state:"Progress",oldValue:d,newValue:u,target:e.target,targetPosition:e.position,allowDrop:!0,cancel:!1};if(this.commandHandler.triggerEvent(Ce.positionChange,p),this.canTrigger=!0,this.connectorEndPointChangeEvent(p,f),!p.cancel&&!this.canCancel){this.blocked=!this.commandHandler.dragSelectedObjects(f.x,f.y);var g=!this.commandHandler.mouseOver(this.currentElement,this.currentTarget,this.currentPosition);this.blocked=this.blocked||g}if(this.commandHandler.removeStackHighlighter(),this.commandHandler.renderStackHighlighter(e),this.currentTarget&&e.source!==this.currentTarget&&this.commandHandler.isDroppable(e.source,this.currentTarget)&&"helper"!==e.source.id){var v=e.source instanceof ti?e.source.nodes[0]:e.source;!this.commandHandler.isParentAsContainer(v,!0)&&"SwimLane"!==v.shape.type&&!v.shape.isPhase&&(this.currentTarget.isLane?this.commandHandler.renderStackHighlighter(e,this.currentTarget):this.commandHandler.drawHighlighter(this.currentTarget))}else this.commandHandler.removeHighlighter();if(this.commandHandler.canEnableDefaultTooltip()){var y=this.getTooltipContent(e.source);this.commandHandler.showTooltip(e.source,e.position,ko(function(){return y}),"MoveTool",this.isTooltipVisible),this.isTooltipVisible=!1}}else{var b=Bi(),M=e.source;qi(b,-M.rotateAngle||-M.wrapper.rotateAngle,M.offsetX||M.wrapper.offsetX,M.offsetY||M.wrapper.offsetY);var w=Ke(b,{x:this.prevPosition.x,y:this.prevPosition.y}),C=Ke(b,{x:e.position.x,y:e.position.y});this.commandHandler.portDrag(e.source,e.sourceWrapper,C.x-w.x,C.y-w.y)}return this.prevPosition=this.currentPosition,!this.blocked},t.prototype.getTooltipContent=function(e){return"X:"+Math.round(e.wrapper.bounds.x)+" Y:"+Math.round(e.wrapper.bounds.y)},t.prototype.mouseLeave=function(e){this.mouseUp(e)},t.prototype.endAction=function(){n.prototype.endAction.call(this),this.currentTarget=null,this.prevPosition=null},t}(us),Yx=function(n){function t(e){var i=n.call(this,e,!0)||this;return i.rotateStart=!1,i}return ds(t,n),t.prototype.mouseDown=function(e){if(this.undoElement=$(e.source),this.undoElement.nodes[0]&&this.undoElement.nodes[0].children)for(var r=this.commandHandler.getAllDescendants(this.undoElement.nodes[0],[]),s=0;s=2){var s=e.startTouches[0],o=e.startTouches[1],a=e.moveTouches[0],l=e.moveTouches[1],h=this.getDistance(a,l)/this.getDistance(s,o);this.commandHandler.zoom(h,0,0,e.position),this.updateTouch(s,a),this.updateTouch(o,l)}}else this.commandHandler.scroll(this.currentPosition.x-this.prevPosition.x,this.currentPosition.y-this.prevPosition.y,this.currentPosition);return this.commandHandler.dataBinding(),!this.blocked},t.prototype.mouseUp=function(e){this.commandHandler.setBlazorDiagramProps(!1),this.checkPropertyValue(),this.commandHandler.updatePanState(!1),n.prototype.mouseUp.call(this,e),this.inAction=!1},t.prototype.endAction=function(){n.prototype.endAction.call(this)},t.prototype.getDistance=function(e,i){var r=i.pageX-e.pageX,s=i.pageY-e.pageY;return Math.sqrt(r*r+s*s)},t.prototype.updateTouch=function(e,i){e.pageX=i.pageX,e.pageY=i.pageY},t}(us),Lne=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseUp=function(e){this.checkPropertyValue(),this.commandHandler.initExpand(e),n.prototype.mouseUp.call(this,e)},t}(us),X3=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseUp=function(e){this.checkPropertyValue();var i="_blank",r="",s=window.innerHeight,o=window.innerWidth,a=window.screenTop,l=window.screenLeft;"CurrentTab"===e.sourceWrapper.hyperlink.hyperlinkOpenState?i="_self":"NewWindow"===e.sourceWrapper.hyperlink.hyperlinkOpenState&&(r="height="+s+",width="+o+",top="+a+",left="+l),window.open(e.sourceWrapper.hyperlink.link,i,r).focus(),n.prototype.mouseUp.call(this,e)},t}(us),zl=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseDown=function(e){if(n.prototype.mouseDown.call(this,e),this.inAction=!0,this.drawingObject){var r=void 0,s=this.drawingObject.shape;this.drawingObject.shape.points.push(r={x:(r=s.points[s.points.length-1]).x,y:r.y})}else{this.startPoint={x:this.startPosition.x,y:this.startPosition.y};var i={offsetX:this.currentPosition.x,offsetY:this.currentPosition.y,width:5,height:5,shape:{type:"Basic",shape:"Polygon",points:[{x:this.startPoint.x,y:this.startPoint.y},{x:this.currentPosition.x,y:this.currentPosition.y}]}};this.triggerElementDrawEvent(e.source,"Start","Node",this.getShapeType(),!0),this.drawingObject=this.commandHandler.drawObject(i)}},t.prototype.mouseMove=function(e){if(n.prototype.mouseMove.call(this,e),this.inAction){var i=this.drawingObject.shape;if(i.points[i.points.length-1].x=this.currentPosition.x,i.points[i.points.length-1].y=this.currentPosition.y,this.drawingObject.wrapper.children[0].data=vx(this.drawingObject.shape.points),this.triggerElementDrawEvent(this.drawingObject,"Progress","Node",this.getShapeType(),!1),this.inAction&&!1===R.equals(this.currentPosition,this.prevPosition)){var r=Ne.toBounds(this.drawingObject.shape.points);this.commandHandler.updateNodeDimension(this.drawingObject,r)}}return!0},t.prototype.mouseUp=function(e,i){this.checkPropertyValue(),n.prototype.mouseMove.call(this,e),this.inAction&&(this.inAction=!1,this.commandHandler.addObjectToDiagram(this.drawingObject),this.triggerElementDrawEvent(this.drawingObject,"Completed","Node",this.getShapeType(),!1)),this.endAction()},t.prototype.mouseWheel=function(e){n.prototype.mouseWheel.call(this,e),this.mouseMove(e)},t.prototype.endAction=function(){this.inAction=!1,this.drawingObject=null},t}(us),Rl=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseMove=function(e){if(n.prototype.mouseMove.call(this,e),this.inAction){var i=this.drawingObject;i.targetPoint=this.currentPosition,this.triggerElementDrawEvent(this.drawingObject,"Progress","Connector",this.drawingObject.type,!1),this.commandHandler.updateConnectorPoints(i)}return!0},t.prototype.mouseDown=function(e){if(n.prototype.mouseDown.call(this,e),this.inAction=!0,this.drawingObject){var r=this.drawingObject,s=void 0;(s=new Hl(r,"segments",{type:"Straight"},!0)).point=this.currentPosition,r.segments[r.segments.length-1]=s}else{var i={id:"Connector",type:"Straight",sourcePoint:this.currentPosition,targetPoint:this.currentPosition};this.triggerElementDrawEvent(e.source,"Start","Connector",this.commandHandler.diagram.drawingObject.type,!0),this.inAction&&(this.drawingObject=this.commandHandler.drawObject(i))}},t.prototype.mouseWheel=function(e){n.prototype.mouseWheel.call(this,e),this.mouseMove(e)},t.prototype.mouseUp=function(e){if(this.checkPropertyValue(),n.prototype.mouseMove.call(this,e),this.inAction&&this.drawingObject){var i=this.drawingObject;i.segments[i.segments.length-1].point={x:0,y:0},this.commandHandler.addObjectToDiagram(this.drawingObject),this.triggerElementDrawEvent(this.drawingObject,"Completed","Connector",this.drawingObject.type,!1)}this.endAction()},t.prototype.endAction=function(){this.drawingObject=null,this.inAction=!1},t}(us),Nne=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseDown=function(e){this.inAction=!0,this.undoElement=$(e.source),this.annotationId=e.sourceWrapper.id,n.prototype.mouseDown.call(this,e)},t.prototype.mouseMove=function(e){n.prototype.mouseMove.call(this,e);var i=this.currentPosition.x-this.prevPosition.x,r=this.currentPosition.y-this.prevPosition.y,s=e.source;if(s instanceof te){var o=Bi();qi(o,-s.rotateAngle,0,0);var a=Ke(o,{x:i,y:r});i=a.x,r=a.y}return this.inAction&&(this.commandHandler.labelDrag(e.source,e.sourceWrapper,i,r),this.commandHandler.updateSelector()),this.prevPosition=this.currentPosition,!this.blocked},t.prototype.mouseUp=function(e){this.checkPropertyValue();var i=e.source;this.inAction=!1;var r={type:"AnnotationPropertyChanged",objectId:this.annotationId,undoObject:$(this.undoElement),category:"Internal",redoObject:$(i)};this.commandHandler.addHistoryEntry(r),n.prototype.mouseUp.call(this,e)},t.prototype.mouseLeave=function(e){this.mouseUp(e)},t}(us),One=function(n){function t(e,i){var r=n.call(this,e,!0)||this;return r.corner=i,r}return ds(t,n),t.prototype.mouseDown=function(e){this.inAction=!0;var i=e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0];this.annotationId=e.source.wrapper.children[0].id,this.undoElement=$(i);var r=e.source.wrapper.children[0];this.initialBounds={x:r.offsetX,y:r.offsetY,width:r.actualSize.width,height:r.actualSize.height},n.prototype.mouseDown.call(this,e)},t.prototype.mouseMove=function(e){return n.prototype.mouseMove.call(this,e),this.inAction&&this.resizeObject(e),!this.blocked},t.prototype.mouseUp=function(e){this.checkPropertyValue();var i=e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0];this.inAction=!1;var r={type:"AnnotationPropertyChanged",objectId:this.annotationId,redoObject:$(i),undoObject:$(this.undoElement),category:"Internal"};this.commandHandler.addHistoryEntry(r),n.prototype.mouseUp.call(this,e)},t.prototype.mouseLeave=function(e){this.mouseUp(e)},t.prototype.resizeObject=function(e){var i,s,o,r=e.source.wrapper.children[0],a={x:r.offsetX,y:r.offsetY},l=r.rotateAngle;l=((l+=(i=e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0])instanceof te?i.rotateAngle:0)+360)%360;var h=Bi();qi(h,l,a.x,a.y);var c=this.corner.slice(5),d=this.updateSize(r,this.startPosition,this.currentPosition,c,this.initialBounds,l),u=r.offsetX-r.actualSize.width*r.pivot.x,f=r.offsetY-r.actualSize.height*r.pivot.y,p=this.getPivot(c),g=Ke(h,p={x:u+r.actualSize.width*p.x,y:f+r.actualSize.height*p.y});d.x=g.x,d.y=g.y,this.commandHandler.labelResize(i,e.source.annotation,s=(s=d.width)<0?1:s,o=(o=d.height)<0?1:o,d,e.source),this.commandHandler.updateSelector()},t}(us),kne=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseDown=function(e){this.inAction=!0,this.annotationId=e.source.wrapper.children[0].id,this.undoElement=$(e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0]),n.prototype.mouseDown.call(this,e)},t.prototype.mouseMove=function(e){return n.prototype.mouseMove.call(this,e),e.source&&this.inAction&&(this.commandHandler.labelRotate(e.source.nodes[0]?e.source.nodes[0]:e.source.connectors[0],e.source.annotation,this.currentPosition,e.source),this.commandHandler.updateSelector()),this.prevPosition=this.currentPosition,!this.blocked},t.prototype.mouseUp=function(e){this.checkPropertyValue(),this.inAction=!1;var r={type:"AnnotationPropertyChanged",objectId:this.annotationId,redoObject:$(e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0]),undoObject:$(this.undoElement),category:"Internal"};this.commandHandler.addHistoryEntry(r),n.prototype.mouseUp.call(this,e)},t.prototype.mouseLeave=function(e){this.mouseUp(e)},t}(us),Pne=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseMove=function(e){if(n.prototype.mouseMove.call(this,e),this.inAction){var i=this.drawingObject.shape;if(i.points.push(this.currentPosition),this.drawingObject.wrapper.children[0].data=mx(this.drawingObject.shape.points),i.data=mx(i.points),this.triggerElementDrawEvent(e.source,"Progress","Connector",this.drawingObject.type,!1),this.inAction&&!1===R.equals(this.currentPosition,this.prevPosition)){var s=Ne.toBounds(this.drawingObject.shape.points);this.commandHandler.updateNodeDimension(this.drawingObject,s)}}return!0},t.prototype.mouseDown=function(e){n.prototype.mouseDown.call(this,e),this.inAction=!0,this.startPoint={x:this.startPosition.x,y:this.startPosition.y};var i={offsetX:this.currentPosition.x,offsetY:this.currentPosition.y,width:5,height:5,style:{strokeColor:"black",strokeWidth:1,fill:"transparent"},shape:{type:"Path",points:[{x:this.startPoint.x,y:this.startPoint.y},{x:this.currentPosition.x,y:this.currentPosition.y}]}};this.triggerElementDrawEvent(e.source,"Start","Connector",this.commandHandler.diagram.drawingObject.type,!0),this.drawingObject=this.commandHandler.drawObject(i)},t.prototype.mouseUp=function(e){if(this.checkPropertyValue(),this.inAction){this.inAction=!1;var s=this.drawingObject.shape,o=s.points;this.commandHandler.addObjectToDiagram(this.drawingObject),this.commandHandler.diagram.remove(this.commandHandler.diagram.nameTable[""+this.drawingObject.id]),o=this.pointReduction(o,10);var h={id:"newConnector"+Qe(),type:"Bezier",sourcePoint:{x:o[0].x,y:o[0].y},targetPoint:{x:o[o.length-1].x,y:o[o.length-1].y},segments:[],bezierSettings:{allowSegmentsReset:!1}};this.drawingObject=this.commandHandler.drawObject(h),this.drawingObject=this.bezierCurveSmoothness(o,.5,this.drawingObject,s),this.commandHandler.updateConnectorPoints(this.drawingObject),this.commandHandler.addObjectToDiagram(this.drawingObject),this.triggerElementDrawEvent(this.drawingObject,"Completed","Connector",this.drawingObject.type,!1),n.prototype.mouseUp.call(this,e)}},t.prototype.pointReduction=function(e,i){if(null===e||e.length<3)return e;var s=e.length-1,o=[];for(o.push(0),o.push(s);e[parseInt((0).toString(),10)]===e[parseInt(s.toString(),10)];)s--;this.reduction(e,0,s,i,o);var a=[];return o.sort(function(l,h){return l-h}),o.forEach(function(l){a.push(e[parseInt(l.toString(),10)])}),a},t.prototype.reduction=function(e,i,r,s,o){for(var a=0,l=0,h=i;ha&&(a=c,l=h)}a>s&&0!==l&&(o.push(l),this.reduction(e,i,l,s,o),this.reduction(e,l,r,s,o))},t.prototype.perpendicularDistance=function(e,i,r){return Math.abs(.5*(e.x*i.y-i.x*e.y+(i.x*r.y-r.x*i.y)+(r.x*e.y-e.x*r.y)))/Math.sqrt(Math.pow(e.x-i.x,2)+Math.pow(e.y-i.y,2))*2},t.prototype.bezierCurveSmoothness=function(e,i,r,s){if(e.length<3)return r;for(var o=0;o=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},zne=function(n){if(n)switch(n.type){case"Bpmn":return Fne;case"UmlActivity":return Bne;case"UmlClassifier":return jne;default:return em}return em},Rne=function(n){if(n)switch(n.type){case"Straight":default:return Hl;case"Bezier":return fs;case"Orthogonal":return wi}},q3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I(10)],t.prototype,"width",void 0),Pe([I(10)],t.prototype,"height",void 0),Pe([I("Arrow")],t.prototype,"shape",void 0),Pe([re({fill:"black",strokeColor:"black",strokeWidth:1},Ll)],t.prototype,"style",void 0),Pe([re({x:0,y:.5},R)],t.prototype,"pivot",void 0),Pe([I("")],t.prototype,"pathData",void 0),t}(Ee),QI=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I(0)],t.prototype,"angle",void 0),Pe([I(0)],t.prototype,"distance",void 0),t}(Ee),Hne=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I(bx.All)],t.prototype,"controlPointsVisibility",void 0),Pe([I("FreeForm")],t.prototype,"segmentEditOrientation",void 0),Pe([I(SI.Default)],t.prototype,"smoothness",void 0),Pe([I(!0)],t.prototype,"allowSegmentsReset",void 0),t}(Ee),em=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I("None")],t.prototype,"type",void 0),t}(Ee),Bne=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I("Object")],t.prototype,"flow",void 0),Pe([I(30)],t.prototype,"exceptionFlowHeight",void 0),t}(em),Fne=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I("Sequence")],t.prototype,"flow",void 0),Pe([I("Normal")],t.prototype,"sequence",void 0),Pe([I("Default")],t.prototype,"message",void 0),Pe([I("Default")],t.prototype,"association",void 0),t}(em),$3=function(n){function t(e,i,r,s){var o=n.call(this,e,i,r,s)||this;return o.points=[],o}return Qs(t,n),Pe([I("Straight")],t.prototype,"type",void 0),Pe([I(!0)],t.prototype,"allowDrag",void 0),t}(Ee),Hl=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),t.prototype.getClassName=function(){return"StraightSegment"},Pe([re({x:0,y:0},R)],t.prototype,"point",void 0),t}($3),fs=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),t.prototype.getClassName=function(){return"BezierSegment"},t.prototype.getPoints=function(e,i){var r=[];if(r.length>0||null!=i){var o=this.bezireToPoly(r.length>0?r[r.length-1]:i,e);r.push.apply(r,o)}return r},t.prototype.bezireToPoly=function(e,i){var r=[];return i&&this.flattenCubicBezier(r,e,i.bezierPoint1,i.bezierPoint2,{x:i.points[1].x,y:i.points[1].y},10),r},t.prototype.flattenCubicBezier=function(e,i,r,s,o,a){var h,l=(R.findLength(i,r)+R.findLength(r,s)+R.findLength(s,o))/a;for(h=0;h<=l;h++){var c=h/l;e.push({x:(1-c)*(1-c)*(1-c)*i.x+3*c*(1-c)*(1-c)*r.x+3*c*c*(1-c)*s.x+c*c*c*o.x,y:(1-c)*(1-c)*(1-c)*i.y+3*c*(1-c)*(1-c)*r.y+3*c*c*(1-c)*s.y+c*c*c*o.y})}},Pe([I("Horizontal")],t.prototype,"orientation",void 0),Pe([re({x:0,y:0},R)],t.prototype,"point1",void 0),Pe([re({x:0,y:0},R)],t.prototype,"point2",void 0),Pe([re({angle:0,distance:0},QI)],t.prototype,"vector1",void 0),Pe([re({angle:0,distance:0},QI)],t.prototype,"vector2",void 0),t}(Hl),wi=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),t.prototype.getClassName=function(){return"OrthogonalSegment"},Pe([I(null)],t.prototype,"length",void 0),Pe([I(null)],t.prototype,"direction",void 0),t}($3);function Z3(n,t,e){var s=e?45:180/(2+2/(n.height/n.width)),o=s,a=180-s,l=a+2*s,h=360-s,c=Xt(t,n.center);return c>o&&ca&&cl&&cMath.abs(t.y-n.y)?n.x=c)return s=R.findAngle(n[parseInt(d.toString(),10)],n[d+1]),{point:r=R.transform(n[parseInt(d.toString(),10)],s,c-(a||0)),index:l=d};a=o[parseInt(d.toString(),10)]}return{point:r,index:l}}(n,t),r=R.findAngle(n[i.index],n[i.index+1]),s=function vse(n){var e=0;switch(n.alignment){case"Center":case"After":e=0;break;case"Before":e=-0}return e}(t),o=R.transform(i.point,r+45,s);return i.point=o,i.angle=r,i}(i,e),h=l.point;s.id=this.id+"_"+e.id;var c=e.style;s.style={fill:c.fill,strokeColor:c.strokeColor,gradient:null,opacity:c.opacity,strokeDashArray:c.strokeDashArray,strokeWidth:c.strokeWidth},0===r.width&&(r.width=this.style.strokeWidth),0===r.height&&(r.height=this.style.strokeWidth);var d_y=(h.y-r.y)/r.height;a.x=r.width*((h.x-r.x)/r.width),a.y=r.height*d_y;var g,v,u=fF(e,l.angle,i),f=u.hAlign,p=u.vAlign;return"left"===f?(g="Left",a.x+=e.displacement.x):"right"===f?(g="Right",a.x-=e.displacement.x):"center"===f&&(g="Center"),"top"===p?(v="Top",a.y+=e.displacement.y):"bottom"===p?(v="Bottom",a.y-=e.displacement.y):"center"===p&&(v="Center"),s.horizontalAlignment=g,s.verticalAlignment=v,(s=rm(s,o&&"Label"!==o.flipMode&&"None"!==o.flipMode?this.flip:"None",e)).float=!0,s.connectionDirection=e.connectionDirection,s.setOffsetWithRespectToBounds(a.x,a.y,"Absolute"),s.relativeMode="Point",s.visible=!(!va(e,Gt.Visible)||va(e,Gt.Hover)||va(e,Gt.Connect)),s.elementActions=s.elementActions|Xr.ElementIsPort,s},t.prototype.getConnectorRelation=function(){var e=this.shape;"Association"===e.relationship?(this.segments[0].type="Straight",this.sourceDecorator.shape="None",this.targetDecorator.shape="Arrow"):"Inheritance"===e.relationship?(this.segments[0].type="Orthogonal",this.sourceDecorator.shape="None",this.targetDecorator.shape="Arrow"):"Composition"===e.relationship||"Aggregation"===e.relationship?(this.segments[0].type="Orthogonal",this.sourceDecorator.shape="Diamond",this.targetDecorator.shape="None"):"Dependency"===e.relationship?(this.segments[0].type="Orthogonal",this.sourceDecorator.shape="None",this.targetDecorator.shape="OpenArrow"):"Realization"===e.relationship&&(this.segments[0].type="Orthogonal",this.sourceDecorator.shape="None",this.targetDecorator.shape="Arrow"),"BiDirectional"===e.associationType&&(this.sourceDecorator.shape="None",this.targetDecorator.shape="None");var i,o,r="",s="";e.multiplicity.source&&(e.multiplicity.source.lowerBounds=e.multiplicity.source.lowerBounds,e.multiplicity.source.upperBounds=e.multiplicity.source.upperBounds),e.multiplicity.target&&(e.multiplicity.target.lowerBounds=e.multiplicity.target.lowerBounds,e.multiplicity.target.upperBounds=e.multiplicity.target.upperBounds);var a=e.multiplicity.source,l=e.multiplicity.target;o=a.upperBounds?a.lowerBounds+"..."+a.upperBounds:a.lowerBounds,i=l.upperBounds?l.lowerBounds+"..."+l.upperBounds:l.lowerBounds,"ManyToOne"===e.multiplicity.type&&(e.multiplicity.target.optional=!1,r=o||"*",s="1"),"OneToMany"===e.multiplicity.type&&(e.multiplicity.source.optional=!1,s=i||"*",r="1"),"ManyToMany"===e.multiplicity.type&&(r=o||"*",s=i||"*"),"OneToOne"===e.multiplicity.type&&(e.multiplicity.target.optional=!1,e.multiplicity.source.optional=!1,r="1",s="1"),this.annotations=[{id:this.id+"sourcelabel",content:r,offset:0,alignment:"Before",margin:{right:5,bottom:5}},{id:this.id+"targetlabel",content:s,offset:1,alignment:"Before",margin:{right:5,bottom:5}}]},t.prototype.getBpmnSequenceFlow=function(){var e=new Ze,i=new Ze;return"Normal"===this.shape.sequence&&"Bezier"!==this.type&&(this.targetDecorator.shape="Arrow"),"Default"===this.shape.sequence&&(e=this.getSegmentElement(this,e),i=IF(this.intermediatePoints,this),this.targetDecorator.shape="Arrow"),"Conditional"===this.shape.sequence&&(this.targetDecorator.shape="Arrow",this.sourceDecorator.shape="Diamond",i.id=this.id+this.shape.type),i},t.prototype.getUMLObjectFlow=function(){if(this.annotations)for(var e=0;e0&&(this.sourcePoint=o[0],this.targetPoint=o[o.length-1]),o},t.prototype.clipDecorator=function(e,i,r,s){var a,l,o={x:0,y:0},h=i.length,c=R.distancePoints(a=r?i[0]:i[h-1],l=r?i[1]:i[h-2]);c=0===c?1:c;var d=1,u=r?e.sourceWrapper:e.targetWrapper;u&&(d=u.style.strokeWidth,s&&s&ee.DecoratorPropertyChange&&(d=1));var f=d-1;return o.x=Math.round(a.x+f*(l.x-a.x)/c),o.y=Math.round(a.y+f*(l.y-a.y)/c),(r&&"None"!==e.sourceDecorator.shape||!r&&"None"!==e.targetDecorator.shape)&&(o=R.adjustPoint(o,l,!0,s&ee.DecoratorPropertyChange?0:d/2)),o},t.prototype.clipDecorators=function(e,i,r){return"None"!==e.sourceDecorator.shape&&(i[0]=this.clipDecorator(e,i,!0,r)),"None"!==e.targetDecorator.shape&&(i[i.length-1]=this.clipDecorator(e,i,!1,r)),i},t.prototype.updateSegmentElement=function(e,i,r,s){var o=new Ne,a=this.getSegmentPath(e,i,s);if("Bezier"===e.type){if(this.segments.length>0)for(var l=0;l0)if("Straight"===e.type&&e.segments.length<2)for(var o=0;o1)for(o=0;o0&&"Bezier"!==this.type)for(var f=0;f0&&(a=f0&&(p<2*this.cornerRadius?(l=R.adjustPoint(h[parseInt(f.toString(),10)],h[f+1],!0,p/2),f0&&(s=this.bridgePath(e,s,f),"Orthogonal"===e.type&&(s=this.bridgePath(e,s,f+1))),s+=" L"+a.x+" "+a.y))}else if("Bezier"===this.type){var g=void 0,v=void 0;if(this.parentObj.element){var y=this.parentObj.element.ej2_instances[0].eventHandler.action;g=this.parentObj.element.ej2_instances[0].eventHandler.tool instanceof Pd,v=y.includes("PortDraw")||y.includes("Drag")}for(var S=void 0,b=this.segments,M=0;M2&&(b[parseInt(M.toString(),10)].bezierPoint1={x:0,y:0},b[parseInt(M.toString(),10)].bezierPoint2={x:0,y:0}),!R.isEmptyPoint(b[parseInt(M.toString(),10)].point1)||b[parseInt(M.toString(),10)].vector1.angle||b[parseInt(M.toString(),10)].vector1.distance?b[parseInt(M.toString(),10)].vector1.angle||b[parseInt(M.toString(),10)].vector1.distance?b[parseInt(M.toString(),10)].bezierPoint1=R.transform(h[parseInt(M.toString(),10)],b[parseInt(M.toString(),10)].vector1.angle,b[parseInt(M.toString(),10)].vector1.distance):b[parseInt(M.toString(),10)].bezierPoint1={x:b[parseInt(M.toString(),10)].point1.x||b[parseInt(M.toString(),10)].bezierPoint1.x,y:b[parseInt(M.toString(),10)].point1.y||b[parseInt(M.toString(),10)].bezierPoint1.y}:((e.sourceID||this.sourcePortID)&&this.sourceWrapper&&!v&&!g&&(S=Z3(this.sourceWrapper.bounds,h[parseInt(M.toString(),10)],!0)),b[parseInt(M.toString(),10)].bezierPoint1=XI(h[parseInt(M.toString(),10)],h[M+1],S)),!R.isEmptyPoint(b[parseInt(M.toString(),10)].point2)||b[parseInt(M.toString(),10)].vector2.angle||b[parseInt(M.toString(),10)].vector2.distance?b[parseInt(M.toString(),10)].vector2.angle||b[parseInt(M.toString(),10)].vector2.distance?b[parseInt(M.toString(),10)].bezierPoint2=R.transform(h[M+1],b[parseInt(M.toString(),10)].vector2.angle,b[parseInt(M.toString(),10)].vector2.distance):b[parseInt(M.toString(),10)].bezierPoint2={x:b[parseInt(M.toString(),10)].point2.x||b[parseInt(M.toString(),10)].bezierPoint2.x,y:b[parseInt(M.toString(),10)].point2.y||b[parseInt(M.toString(),10)].bezierPoint2.y}:((e.targetID||this.targetPortID)&&this.targetWrapper&&!v&&!g&&(S=Z3(this.targetWrapper.bounds,h[M+1],!0)),b[parseInt(M.toString(),10)].bezierPoint2=XI(h[M+1],h[parseInt(M.toString(),10)],S));h.splice(1,0,{x:b[0].bezierPoint1.x,y:b[0].bezierPoint1.y}),h.splice(h.length-1,0,{x:b[b.length-1].bezierPoint2.x,y:b[b.length-1].bezierPoint2.y}),h=this.clipDecorators(e,h,r);for(var w=0;w0&&(s=this.bridgePath(e,s,D),s+=" L"+o.x+" "+o.y);return s},t.prototype.updateShapeElement=function(e){var i;switch(e.shape.type){case"Bpmn":e.wrapper.children[3]instanceof Ze&&(i=e.wrapper.children[3]),"Message"===e.shape.flow&&this.updateShapePosition(e,i);break;case"UmlActivity":"Exception"===e.shape.flow&&this.getUMLExceptionFlow(e.wrapper.children[0])}},t.prototype.updateShapePosition=function(e,i){var o=bF(this.intermediatePoints,i,.5);i.offsetX=o.x,i.offsetY=o.y},t.prototype.scale=function(e,i,r,s,o){var a=0,l=0;if(this.wrapper&&this.wrapper.outerBounds){var h=function M3(n){var t=n.wrapper.children[0].bounds;return"None"!==n.sourceDecorator.shape&&t.uniteRect(n.wrapper.children[1].bounds),"None"!==n.targetDecorator.shape&&t.uniteRect(n.wrapper.children[2].bounds),t}(this),c=Math.abs((this.wrapper.bounds.width||this.style.strokeWidth||1)-2),d=Math.abs((this.wrapper.bounds.height||this.style.strokeWidth||1)-2);a=h.width-c,l=h.height-d,e=Math.abs((r-Math.max(a,l))/c),i=Math.abs((s-Math.max(a,l))/d),a=l=Math.min(a,l)}e=i=Math.min(e,i);var u=Bi();qi(u,-(o=o||this.wrapper).rotateAngle,o.offsetX,o.offsetY),Yf(u,e,i,o.offsetX,o.offsetY),qi(u,o.rotateAngle,o.offsetX,o.offsetY);var f=function Lie(n,t){for(var e=[],i=0,r=t;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Wne=function(n){function t(e,i){var r=n.call(this,e,i)||this;return r.offset=0,r.scale=1,r}return Vne(t,n),t.prototype.preRender=function(){this.unWireEvents(),this.wireEvents()},t.prototype.render=function(){this.updateRulerGeometry(),this.renderComplete()},t.prototype.getModuleName=function(){return"Ruler"},t.prototype.destroy=function(){this.unWireEvents(),this.notify("destroy",{}),n.prototype.destroy.call(this),this.element.classList.remove("e-ruler")},t.prototype.getPersistData=function(){return this.addOnPersist(["loaded"])},t.prototype.onPropertyChanged=function(e,i){for(var r=0,s=Object.keys(e);r100;)r/=10,s/=10;for(;s<25;)r*=10,s*=10;return s>=25&&s%25!=0&&(s=25*Math.round(s/25)),s*e/r},t.prototype.createMarkerLine=function(e,i,r){var s;return i&&((s=e.getElementById(i.id+"_marker"))&&s.parentNode.removeChild(s),s=Fi("line",r)),s},t.prototype.drawRulerMarker=function(e,i,r){var s,o,h,d,u="Horizontal"===this.orientation,f=e.getElementsByTagName("svg");for(h=0;h0)for(var a=i.childNodes.length-1;a>=0;a--)i.childNodes[parseInt(a.toString(),10)].parentNode.removeChild(i.childNodes[parseInt(a.toString(),10)]);i.appendChild(s)}return s},t.prototype.wireEvents=function(){},t.prototype.unWireEvents=function(){},kc([I(5)],t.prototype,"interval",void 0),kc([I(100)],t.prototype,"segmentWidth",void 0),kc([I("Horizontal")],t.prototype,"orientation",void 0),kc([I("RightOrBottom")],t.prototype,"tickAlignment",void 0),kc([I("red")],t.prototype,"markerColor",void 0),kc([I(25)],t.prototype,"thickness",void 0),kc([I(null)],t.prototype,"arrangeTick",void 0),kc([I(400)],t.prototype,"length",void 0),t}(Ii);function eF(n,t){var e=document.getElementById(n.element.id+(t?"_hRuler":"_vRuler")),i=Za(n),r=tF(n);e||(e=Tt("div",{id:n.element.id+(t?"_hRuler":"_vRuler"),style:"height:"+(t?i.height:r.height+100)+"px;overflow:hidden;width:"+(t?r.width+100:i.width)+"px;position:absolute;font-size:11px;"+(t?"margin-left:"+i.width+"px;":"margin-top:"+i.height+"px;")})),n.element.insertBefore(e,n.element.firstChild);var l=t?n.rulerSettings.horizontalRuler:n.rulerSettings.verticalRuler,h=new Wne(l);h.orientation=t?"Horizontal":"Vertical",h.length=(t?r.width:r.height)+l.segmentWidth,h.appendTo("#"+n.element.id+(t?"_hRuler":"_vRuler")),t?n.hRuler=h:n.vRuler=h;var c=document.getElementById(n.element.id+(t?"_hRuler":"_vRuler"));t?n.hRuler.element=c:n.vRuler.element=c}function qI(n){var t=-n.scroller.horizontalOffset,e=-n.scroller.verticalOffset;n&&n.rulerSettings.showRulers?(n.hRuler.length=0,n.vRuler.length=0,void 0!==t&&n.hRuler.element&&iF(n,n.hRuler,t,!0),void 0!==e&&n.vRuler.element&&iF(n,n.vRuler,e,!1)):Qx(n)}function Qx(n){an(n.element.id+"_hRuler"),an(n.element.id+"_vRuler"),an(n.element.id+"_overlapRuler")}function Za(n){var t=0,e=0;return n.rulerSettings.showRulers&&(t=n.rulerSettings.horizontalRuler.thickness,e=n.rulerSettings.verticalRuler.thickness),new me(e,t)}function tF(n){var t=Za(n),e=n.scroller.viewPortHeight,i=n.scroller.viewPortWidth;return i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},rF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return $ne(t,n),t.prototype.getClassName=function(){return"UserHandle"},Un([I("")],t.prototype,"name",void 0),Un([I("")],t.prototype,"pathData",void 0),Un([I("")],t.prototype,"content",void 0),Un([I("")],t.prototype,"source",void 0),Un([I("#000000")],t.prototype,"backgroundColor",void 0),Un([I("Top")],t.prototype,"side",void 0),Un([I("")],t.prototype,"borderColor",void 0),Un([I(.5)],t.prototype,"borderWidth",void 0),Un([I(25)],t.prototype,"size",void 0),Un([I("white")],t.prototype,"pathColor",void 0),Un([I(10)],t.prototype,"displacement",void 0),Un([I(!0)],t.prototype,"visible",void 0),Un([I(0)],t.prototype,"offset",void 0),Un([re({},Jn)],t.prototype,"margin",void 0),Un([I("Center")],t.prototype,"horizontalAlignment",void 0),Un([I("Center")],t.prototype,"verticalAlignment",void 0),Un([I(!1)],t.prototype,"disableNodes",void 0),Un([I(!1)],t.prototype,"disableConnectors",void 0),Un([re({},Dd)],t.prototype,"tooltip",void 0),Un([I("")],t.prototype,"template",void 0),t}(Ee);function nF(n){return Zne[n.toString()]}var Zne={Action:"M 90 82.895 C 90 86.819 86.776 90 82.8 90 H 7.2 C 3.224 90 0 86.819 0 82.895 V 7.105 C 0 3.181 3.224 0 7.2 0 h 75.6 C 86.776 0 90 3.181 90 7.105 V 82.895 Z",Decision:"M10,19.707L0.293,10L10,0.293L19.707,10L10,19.707z",MergeNode:"M10,19.707L0.293,10L10,0.293L19.707,10L10,19.707z",InitialNode:"M10,19.5c-5.238,0-9.5-4.262-9.5-9.5S4.762,0.5,10,0.5s9.5,4.262,9.5,9.5S15.238,19.5,10,19.5z",ForkNode:"m0.75,0.75l636.00002,0l0,290l-636.00002,0l0,-290z",JoinNode:"m0.75,0.75l636.00002,0l0,290l-636.00002,0l0,-290z",TimeEvent:"M50.001,0.00286865 L25.001,25.0029 L0.000976562,0.00286865 L50.001,0.00286865 z M0.000976562,50.0029 L25.001,25.0029 L50.001,50.0029 L0.000976562,50.0029 z",AcceptingEvent:"M17.8336 32.164 L29.64 24 L17.32 16 L48.1664 16 L48.5 32 Z",SendSignal:"M48.164 31.8336 L56 23.832 L47.836 16 L16.168 16 L16.1668 31.8336 Z",ReceiveSignal:"M48.1664 31.8336 L39.836 24 L47.836 16 L16.168 16 L16.168 31.836 Z",StructuredNode:"M0,0 L50,0 L50,50 L0,50 z",Note:"M20 12 L4 12 L4 22 L22 22 L22 14 L20 14 L20 12 L22 14 Z"},$I=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Ja=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Jne=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return $I(t,n),Ja([I()],t.prototype,"key",void 0),Ja([I()],t.prototype,"keyModifiers",void 0),t}(Ee),sF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return $I(t,n),t.prototype.getClassName=function(){return"Command"},Ja([I("")],t.prototype,"name",void 0),Ja([I()],t.prototype,"canExecute",void 0),Ja([I()],t.prototype,"execute",void 0),Ja([re({},Jne)],t.prototype,"gesture",void 0),Ja([I("")],t.prototype,"parameter",void 0),t}(Ee),Kne=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return $I(t,n),Ja([Bt([],sF)],t.prototype,"commands",void 0),t}(Ee),ese=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return $I(t,n),Ja([I()],t.prototype,"show",void 0),Ja([I()],t.prototype,"showCustomMenuOnly",void 0),Ja([I()],t.prototype,"items",void 0),t}(Ee),$f=function(){function n(){}return n.prototype.renderShadow=function(t,e,i,r){void 0===i&&(i=null);var l,o=R.transform({x:0,y:0},t.shadow.angle,t.shadow.distance);r&&(l=r.getElementById(e.id+"_shadow")),l||(l=document.createElementNS("http://www.w3.org/2000/svg",i?"path":"rect"),e.appendChild(l));var h={id:e.id+"_shadow",fill:t.shadow.color,stroke:t.shadow.color,opacity:t.shadow.opacity.toString(),transform:"rotate("+t.angle+","+(t.x+t.width*t.pivotX)+","+(t.y+t.height*t.pivotY)+")translate("+(t.x+o.x)+","+(t.y+o.y)+")"};if(r){var c=r.getElementById(e.id);c&&c.insertBefore(l,c.firstChild)}ii(l,h),i?i&&this.renderPath(l,t,i):ii(l,{width:t.width,height:t.height})},n.prototype.parseDashArray=function(t){return[]},n.prototype.drawRectangle=function(t,e,i,r,s,o,a,l,h){var c,d,u,f;e.shadow&&!r&&this.renderShadow(e,t,void 0,o),c=e.id===t.id?e.id+"_container":e.id,o&&(d=o.getElementById(c)),(!d||s)&&(d=document.createElementNS("http://www.w3.org/2000/svg","rect"),t.appendChild(d)),o&&!e.shadow&&(u=o.getElementById(e.id+"_groupElement_shadow"))&&u.parentNode.removeChild(u),f=l?{id:c,x:e.x.toString(),y:e.y.toString(),width:e.width.toString(),height:e.height.toString(),visibility:e.visible?"visible":"hidden",transform:"rotate("+e.angle+","+(e.x+e.width/2)+","+(e.y+e.height/2)+")",rx:e.cornerRadius||0,ry:e.cornerRadius||0,opacity:e.opacity}:{id:c,x:e.x.toString(),y:e.y.toString(),width:e.width.toString(),height:e.height.toString(),visibility:e.visible?"visible":"hidden",transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")",rx:e.cornerRadius||0,ry:e.cornerRadius||0,opacity:e.opacity},a&&(f.role="img",f["aria-label"]=a);var p=e.class||"";h||(p.includes("e-diagram-resize-handle")||p.includes("e-diagram-endpoint-handle")||p.includes("e-diagram-bezier-control-handle"))&&(p+=" e-disabled"),e.class&&(f.class=p),a||(f["pointer-events"]="none"),ii(d,f),this.setSvgStyle(d,e,i)},n.prototype.updateSelectionRegion=function(t,e){var i;i=t.parentNode.getElementById(e.id);var r={id:e.id,x:e.x.toString(),y:e.y.toString(),width:e.width.toString(),height:e.height.toString(),transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")",class:"e-diagram-selected-region"};i||(i=document.createElementNS("http://www.w3.org/2000/svg","rect"),t.appendChild(i)),this.setSvgStyle(i,e),ii(i,r)},n.prototype.createGElement=function(t,e){return Fi(t,e)},n.prototype.drawLine=function(t,e){var i=document.createElementNS("http://www.w3.org/2000/svg","line");this.setSvgStyle(i,e);var r=e.x+e.width*e.pivotX,s=e.y+e.height*e.pivotY,o={id:e.id,x1:e.startPoint.x+e.x,y1:e.startPoint.y+e.y,x2:e.endPoint.x+e.x,y2:e.endPoint.y+e.y,stroke:e.stroke,"stroke-width":e.strokeWidth.toString(),opacity:e.opacity.toString(),transform:"rotate("+e.angle+" "+r+" "+s+")",visibility:e.visible?"visible":"hidden"};e.class&&(o.class=e.class),ii(i,o),t.appendChild(i)},n.prototype.drawCircle=function(t,e,i,r){var s=document.createElementNS("http://www.w3.org/2000/svg","circle");this.setSvgStyle(s,e);var o=e.class||"";i||(o+=" e-disabled");var a={id:e.id,cx:e.centerX,cy:e.centerY,r:e.radius,visibility:e.visible?"visible":"hidden",class:o};r&&(a.role="img",a["aria-label"]=r),s.style.display=e.visible?"block":"none",ii(s,a),t.appendChild(s)},n.prototype.drawPath=function(t,e,i,r,s,o,a){var h,c,l=[];l=XB(l=Ed(e.data)),e.shadow&&this.renderShadow(e,t,l,s),s&&!e.shadow&&(h=s.getElementById(e.id+"_groupElement_shadow"))&&h.parentNode.removeChild(h),s&&(c=s.getElementById(e.id)),(!c||r)&&(c=document.createElementNS("http://www.w3.org/2000/svg","path"),t.appendChild(c)),this.renderPath(c,e,l);var d={};d=a?{id:e.id,transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")translate("+e.x+","+e.y+"),scale("+a+")",visibility:e.visible?"visible":"hidden",opacity:e.opacity}:{id:e.id,transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")translate("+e.x+","+e.y+")",visibility:e.visible?"visible":"hidden",opacity:e.opacity},o&&(d.role="img",d["aria-label"]=o),e.class&&(d.class=e.class),ii(c,d),this.setSvgStyle(c,e,i)},n.prototype.renderPath=function(t,e,i){var r,s,o,a,l,h,c,d,u=i,f="";for(l=0,h=0,d=0,c=u.length;de.width&&"Wrap"!==e.textOverflow&&"NoWrap"===e.textWrapping&&(h[0].text=VF(e.content,e)),v=0;vD&&(u.text=u.text.slice(0,u.text.length-3),u.text=u.text.concat("..."),l.data=u.text),this.alignText(y,f,u,l,p,g,v,e,h),C+=u.dy}}C&&e.isHorizontalLane&&(M=e.parentOffsetX+e.pivotX,w=e.parentOffsetY+e.pivotY,e.y=e.parentOffsetY-C*e.pivotY+.5),e.textDecoration&&"LineThrough"===e.textDecoration&&(e.textDecoration=cb(e.textDecoration));var P={id:e.id+"_text",fill:e.color,visibility:e.visible?"visible":"hidden","text-decoration":e.textDecoration,transform:"rotate("+e.angle+","+M+","+w+")translate("+e.x+","+e.y+")",opacity:e.opacity};r&&(P.role="img",P["aria-label"]=r),ii(y,P)}},n.prototype.alignText=function(t,e,i,r,s,o,a,l,h){"justify"!==l.textAlign?this.setText(t,e,i,r,s,o,l):a!==h.length-1?this.setText(t,e,i,r,s,o,l,l.width,"spacing"):this.setText(t,e,i,r,s,o,l)},n.prototype.setText=function(t,e,i,r,s,o,a,l,h){ii(e,"justify"!==a.textAlign?{x:s.toString(),y:o.toString()}:{x:s.toString(),y:o.toString(),textLength:l||0,lengthAdjust:h||"spacing"}),t.setAttribute("fill",i.text),e.appendChild(r),t.appendChild(e)},n.prototype.drawImage=function(t,e,i,r){var s;i&&(s=i.getElementById(e.id+"image")),s||(s=document.createElementNS("http://www.w3.org/2000/svg","image"),t.appendChild(s));var o=new Image;o.src=e.source;var a="None"!==e.scale?e.scale:"",l=e.alignment,h=l.charAt(0).toLowerCase()+l.slice(1);"Stretch"!==a&&(h+=" "+a.charAt(0).toLowerCase()+a.slice(1)),ii(s,{id:e.id+"image",x:e.x.toString(),y:e.y.toString(),transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")",width:e.width.toString(),visibility:e.visible?"visible":"hidden",height:e.height.toString(),preserveAspectRatio:h,opacity:e.opacity.toString()}),s.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",o.src.toString())},n.prototype.drawHTMLContent=function(t,e,i,r,s){var o,a;if(e&&(o=e.querySelector("#"+t.id+"_html_element")),!o){(a=e.querySelector("#"+t.id+"_html_element")||e.querySelector("#"+t.nodeId+"_html_element"))||(a=Tt("div",{id:t.nodeId+"_html_element",class:"foreign-object"})),o=Tt("div",{id:t.id+"_html_element",class:"foreign-object"});var c=document.getElementById(t.diagramId).ej2_instances[0],d=!1;if(e.parentNode&&e.parentNode.parentNode&&e.parentNode.parentNode.parentNode&&e.parentNode.parentNode.parentNode.classList.contains("e-overview")&&(d=!0),d)c.isReact?c.renderReactTemplates(function(){o.appendChild(t.template.cloneNode(!0))}):o.appendChild(t.template.cloneNode(!0));else{if("string"==typeof t.template){var u=document.createElement("div");u.innerHTML=t.template,t.template=u,c.selectedItems.userHandles.filter(function(g){return g.name===t.id.split("_shape")[0]&&""!==g.template})[0].template=t.template}t.isTemplate&&t.template?o.appendChild(t.template):t.template&&o.appendChild(t.template.cloneNode(!0))}void 0!==s&&e.childNodes.length>s&&e.insertBefore(o,e.childNodes[parseInt(s.toString(),10)]),a.appendChild(o),e.appendChild(a)}var p=xn(t).topLeft;o.setAttribute("style","height:"+t.actualSize.height+"px; width:"+t.actualSize.width+"px;left:"+p.x+"px; top:"+p.y+"px;position:absolute;transform:rotate("+(t.rotateAngle+t.parentTransform)+"deg);pointer-events:"+(r?"all":"none")+";visibility:"+(t.visible?"visible":"hidden")+";opacity:"+t.style.opacity+";")},n.prototype.drawNativeContent=function(t,e,i,r,s){var o,a;if(s&&(o=s.getElementById(t.id+"_native_element"),a=s.getElementById(t.id+"_clip")),!o){(o=document.createElementNS("http://www.w3.org/2000/svg","g")).setAttribute("id",t.id+"_native_element"),o.appendChild(t.template.cloneNode(!0));var l=this.createGElement("g",{id:t.id+"_inner_native_element"});l.appendChild(o),e.appendChild(l)}a&&o.removeChild(a),o.setAttribute("style","visibility:"+(t.visible?"visible":"hidden")+";opacity:"+t.style.opacity+";"),this.setNativTransform(t,o,i,r),"Slice"===t.scale&&this.drawClipPath(t,o,i,r,s),ii(o,t.description?{role:"img","aria-label":t.description}:{})},n.prototype.setNativTransform=function(t,e,i,r){var s=0!==t.contentSize.width?t.contentSize.width:1,o=0!==t.contentSize.height?t.contentSize.height:1;e.setAttribute("transform","rotate("+t.parentTransform+","+t.offsetX+","+t.offsetY+") translate("+(t.offsetX-t.templatePosition.x*r/s-r*t.pivot.x)+","+(t.offsetY-t.templatePosition.y*i/o-i*t.pivot.y)+") scale("+r/s+","+i/o+")")},n.prototype.drawClipPath=function(t,e,i,r,s){var o=t.contentSize.width,a=t.contentSize.height,l=t.width/(r/o),h=t.height/(i/a),c=t.templatePosition.x+(t.width>=t.height?0:(o-l)/2),d=t.templatePosition.y+(t.height>=t.width?0:(a-h)/2),u=s.getElementById(t.id+"_clip");(u=document.createElementNS("http://www.w3.org/2000/svg","clipPath")).setAttribute("id",t.id+"_clip"),e.appendChild(u);var f=s.getElementById(t.id+"_clip_rect");return f=document.createElementNS("http://www.w3.org/2000/svg","rect"),u.appendChild(f),ii(f,{id:t.id+"_clip_rect",width:l.toString(),height:h.toString(),x:c.toString(),y:d.toString()}),sm()?e.setAttribute("clip-path","url("+location.protocol+"//"+location.host+location.pathname+"#"+t.id+"_clip)"):e.setAttribute("clip-path","url(#"+t.id+"_clip)"),e},n.prototype.renderGradient=function(t,e,i){var r,s,o,h,c,a=mT(i),l=a.getElementById(i+"gradient_pattern");if(l||(l=Fi("defs",{id:i+"gradient_pattern"}),a.insertBefore(l,a.firstChild)),gF(e.id),"None"!==t.gradient.type){for(var d=0;dt.width&&("Ellipsis"===t.textOverflow||"Clip"===t.textOverflow)&&"NoWrap"===t.textWrapping?0:.5*t.width:"right"===t.textAlign&&(c=1*t.width),s.x=0+c+(e?e.x:0),s.y=1.2+d-r.height/2,s},n}(),Pc=function(){function n(t,e,i){this.renderer=null,this.isSvgMode=!0,this.touchMove=void 0,this.transform={x:0,y:0},this.diagramId=t,this.element=xt(this.diagramId),this.svgRenderer=e,this.isSvgMode=i,this.renderer=i?new $f:new bo}return n.prototype.setCursor=function(t,e){t.style.cursor=e},n.prototype.setLayers=function(){this.iconSvgLayer=this.element.getElementsByClassName("e-ports-expand-layer")[0],this.adornerSvgLayer=this.element.getElementsByClassName("e-adorner-layer")[0],this.nativeSvgLayer=this.element.getElementsByClassName("e-native-layer")[0],this.diagramSvgLayer=this.element.getElementsByClassName("e-diagram-layer")[0]},n.prototype.getAdornerLayer=function(){return gT(this.diagramId)},n.prototype.getParentSvg=function(t,e,i){return this.diagramId&&t&&t.id?t.id.split("_icon_content").length>1||t.id.split("_nodeport").length>1||t.elementActions&Xr.ElementIsPort?this.iconSvgLayer:e&&"selector"===e?this.adornerSvgLayer:t instanceof En?this.nativeSvgLayer:this.diagramSvgLayer:i},n.prototype.getParentElement=function(t,e,i,r){var s=e;if(i&&this.diagramId&&t&&t.id){t.id.split("_icon_content").length>1?(s=i.getElementById(this.diagramId+"_diagramExpander"),e=null):t.id.split("_nodeport").length>1?s=i.getElementById(this.diagramId+"_diagramPorts"):t instanceof En?(s=i.getElementById(this.diagramId+"_nativeLayer"),e=null):t.elementActions&Xr.ElementIsPort?(s=i.getElementById(this.diagramId+"_diagramPorts"),e=null):s=i.getElementById(this.diagramId+"_diagramLayer");var o=this.getGroupElement(t,e||s,r);s=o.g,o.svg&&(i=o.svg)}return{g:s,svg:i}},n.prototype.getGroupElement=function(t,e,i){var r,o,s=this.getParentSvg(t);if(e&&s){if(s&&!(r=s.getElementById(t.id+"_groupElement"))&&s!==this.nativeSvgLayer){var a=this.nativeSvgLayer;r=a.getElementById(t.id+"_groupElement"),o=a}r||(r=this.svgRenderer.createGElement("g",{id:t.id+"_groupElement"}),void 0!==i&&e.childNodes.length>i?e.insertBefore(r,e.childNodes[parseInt(i.toString(),10)]):e.appendChild(r))}return{g:r,svg:o}},n.prototype.renderElement=function(t,e,i,r,s,o,a,l,h,c,d){t instanceof Cs?(t.id=t.id?t.id:Qe(),this.renderContainer(t,e,i,r,s,o,a,l,h,c,d)):t instanceof bI?this.renderImageElement(t,e,r,s,a):t instanceof Ze?this.renderPathElement(t,e,r,s,a,h,d):t instanceof li?this.renderTextElement(t,e,r,s,a,c):t instanceof En?this.renderNativeElement(t,e,r,s,a):t instanceof es?this.renderHTMLElement(t,e,i,r,s,a,l):this.renderRect(t,e,r,s,h)},n.prototype.drawSelectionRectangle=function(t,e,i,r,s,o){var a={width:i*o.scale,height:r*o.scale,x:.5+(t=(t+o.tx)*o.scale),y:.5+(e=(e+o.ty)*o.scale),fill:"transparent",stroke:"gray",angle:0,pivotX:.5,pivotY:.5,strokeWidth:1,dashArray:"6 3",opacity:1,visible:!0,id:s.id+"_selected_region"},l=this.getAdornerLayer();this.svgRenderer.updateSelectionRegion(l,a)},n.prototype.renderHighlighter=function(t,e,i){var r=t.actualSize.width||2,s=t.actualSize.height||2,o=t.offsetX-r*t.pivot.x,a=t.offsetY-s*t.pivot.y;this.svgRenderer.drawRectangle(e,{width:r*i.scale,height:s*i.scale,x:o=(o+i.tx)*i.scale,y:a=(a+i.ty)*i.scale,fill:"transparent",stroke:"#8CC63F",angle:t.rotateAngle,pivotX:t.pivot.x,pivotY:t.pivot.y,strokeWidth:4,dashArray:"",opacity:1,cornerRadius:0,visible:!0,id:e.id+"_highlighter",class:"e-diagram-highlighter"},this.diagramId,void 0,void 0,e)},n.prototype.renderSelectionRectangle=function(t,e,i,r){var s=t.actualSize.width||2,o=t.actualSize.height||2,a=t.offsetX-s*t.pivot.x,l=t.offsetY-o*t.pivot.y,h={width:s*i.scale,height:o*i.scale,x:a=(a+i.tx)*i.scale,y:l=(l+i.ty)*i.scale,fill:"transparent",stroke:"#00cc00",angle:t.rotateAngle,pivotX:t.pivot.x,pivotY:t.pivot.y,strokeWidth:r?2:1,dashArray:"",opacity:1,cornerRadius:0,visible:!0,id:t.id+"_highlighter",class:r?"e-diagram-first-selection-indicator e-diagram-selection-indicator":"e-diagram-selection-indicator"},c=this.getParentSvg(t,"selector");this.svgRenderer.drawRectangle(e,h,this.diagramId,void 0,void 0,c)},n.prototype.renderSelectionLine=function(t,e,i,r){var s=this.getBaseAttributes(t,i);s.data=t.absolutePath,s.id=s.id+"_highlighter";var o=t.description?t.description:t.id;this.isSvgMode||(s.x=t.flipOffset.x?t.flipOffset.x:s.x,s.y=t.flipOffset.y?t.flipOffset.y:s.y),i&&(s.x=s.x*i.scale,s.y=s.y*i.scale),s.stroke="#00cc00",s.strokeWidth=r?2:1,s.class=r?"e-diagram-first-selection-indicator e-diagram-selection-indicator":"e-diagram-selection-indicator";var a=this.getParentSvg(t,"selector");this.svgRenderer.drawPath(e,s,this.diagramId,void 0,a,o,i.scale)},n.prototype.renderStackHighlighter=function(t,e,i,r,s,o,a){var l=t.actualSize.width||2,h=t.offsetX-l*t.pivot.x,c=t.actualSize.height||2,d=t.offsetY-c*t.pivot.y;h=(h+i.tx)*i.scale;var u,f=t.bounds,p="";if(d=(d+i.ty)*i.scale,r)if(o){var v,y;u="M 0 0 L "+(2+(g=l*i.scale))+" 0 Z",v=t.actualSize.width/Number(f.width?f.width:1)*i.scale,y=t.actualSize.height/Number(f.height?f.height:1)*i.scale,p=vI(mI(Ed("M7,4 L8,4 8,7 11,7 11,8 8,8 8,11 7,11 7,8 4,8 4,7 7,7 z M7.5,0.99999994C3.9160004,1 1,3.9160004 0.99999994,7.5 1,11.084 3.9160004,14 7.5,14 11.084,14 14,11.084 14,7.5 14,3.9160004 11.084,1 7.5,0.99999994 z M7.5,0 C11.636002,0 15,3.3639984 15,7.5 15,11.636002 11.636002,15 7.5,15 3.3640003,15 0,11.636002 0,7.5 0,3.3639984 3.3640003,0 7.5,0 z")),v+g+2,y-8,!1,f.x,f.y,0,0),s.y>=t.offsetY&&(d+=c)}else{var g;a&&s.y>=t.offsetY&&(d+=c*i.scale),u="M -10 -10 L 0 0 Z M -10 10 L 0 0 Z M 0 0 L "+(g=l*i.scale)+" 0 Z M "+g+" 0 L "+(g+10)+" 10 Z L "+(g+10)+" -10 Z"}else u="M 10 -10 L 0 0 Z M -10 -10 L 0 0 Z M 0 0 L 0 "+(g=c*i.scale)+" Z M 0 "+g+" L -10 "+(g+10)+" Z L 10 "+(g+10)+" Z",s.x>=t.offsetX&&(h+=l*i.scale);this.svgRenderer.drawPath(e,{data:u+p,width:l*i.scale,height:c*i.scale,x:h,y:d,fill:"transparent",stroke:"#8CC63F",angle:t.rotateAngle,pivotX:t.pivot.x,pivotY:t.pivot.y,strokeWidth:1,dashArray:"",opacity:1,visible:!0,id:e.id+"_stack_highlighter",class:"e-diagram-highlighter"},this.diagramId)},n.prototype.drawLine=function(t,e){this.svgRenderer.drawLine(t,e)},n.prototype.drawPath=function(t,e){this.svgRenderer.drawPath(t,e,this.diagramId)},n.prototype.renderResizeHandle=function(t,e,i,r,s,o,a,l,h,c,d){var u=t.offsetX-t.actualSize.width*t.pivot.x,f=t.offsetY-t.actualSize.height*t.pivot.y,p=t.actualSize.height,g=t.actualSize.width;if(!c&&i&bt.Rotate&&HI(this.rendererActions)&&!A3(this.rendererActions))this.renderPivotLine(t,e,o,s,a),this.renderRotateThumb(t,e,o,s,a);else if(this.touchMove){var v=document.getElementById("rotateThumb");v&&v.setAttribute("visibility","hidden")}this.renderBorder(t,e,o,l,h,c);var y=t.actualSize.width*r,S=t.actualSize.height*r;!h&&HI(this.rendererActions)&&!A3(this.rendererActions)&&(t.isTextAnnotation||(y>=40&&S>=40&&(s&mr.ResizeNorthWest&&this.renderCircularHandle("resizeNorthWest",t,u,f,e,qr(s,"ResizeNorthWest"),i&bt.ResizeNorthWest,o,void 0,a,{"aria-label":"Thumb to resize the selected object on top left side direction"},void 0,"e-diagram-resize-handle e-northwest",d),s&mr.ResizeNorthEast&&this.renderCircularHandle("resizeNorthEast",t,u+g,f,e,qr(s,"ResizeNorthEast"),i&bt.ResizeNorthEast,o,void 0,a,{"aria-label":"Thumb to resize the selected object on top right side direction"},void 0,"e-diagram-resize-handle e-northeast",d),s&mr.ResizeSouthWest&&this.renderCircularHandle("resizeSouthWest",t,u,f+p,e,qr(s,"ResizeSouthWest"),i&bt.ResizeSouthWest,o,void 0,a,{"aria-label":"Thumb to resize the selected object on bottom left side direction"},void 0,"e-diagram-resize-handle e-southwest",d),s&mr.ResizeSouthEast&&this.renderCircularHandle("resizeSouthEast",t,u+g,f+p,e,qr(s,"ResizeSouthEast"),i&bt.ResizeSouthEast,o,void 0,a,{"aria-label":"Thumb to resize the selected object on bottom right side direction"},void 0,"e-diagram-resize-handle e-southeast",d)),s&mr.ResizeNorth&&this.renderCircularHandle("resizeNorth",t,u+g/2,f,e,qr(s,"ResizeNorth"),i&bt.ResizeNorth,o,void 0,a,{"aria-label":"Thumb to resize the selected object on top side direction"},void 0,"e-diagram-resize-handle e-north",d),s&mr.ResizeSouth&&this.renderCircularHandle("resizeSouth",t,u+g/2,f+p,e,qr(s,"ResizeSouth"),i&bt.ResizeSouth,o,void 0,a,{"aria-label":"Thumb to resize the selected object on bottom side direction"},void 0,"e-diagram-resize-handle e-south",d),s&mr.ResizeWest&&this.renderCircularHandle("resizeWest",t,u,f+p/2,e,qr(s,"ResizeWest"),i&bt.ResizeWest,o,void 0,a,{"aria-label":"Thumb to resize the selected object on left side direction"},void 0,"e-diagram-resize-handle e-west",d),s&mr.ResizeEast&&this.renderCircularHandle("resizeEast",t,u+g,f+p/2,e,qr(s,"ResizeEast"),i&bt.ResizeEast,o,void 0,a,{"aria-label":"Thumb to resize the selected object on right side direction"},void 0,"e-diagram-resize-handle e-east",d)))},n.prototype.renderEndPointHandle=function(t,e,i,r,s,o,a,l,h,c){var p,g,d=t.sourcePoint,u=t.targetPoint,f=t.wrapper;if(this.renderCircularHandle("connectorSourceThumb",f,d.x,d.y,e,qr(r,"ConnectorSourceThumb"),i&bt.ConnectorSource,s,o,void 0,{"aria-label":"Thumb to move the source point of the connector"},void 0,"e-diagram-endpoint-handle e-sourceend",c),this.renderCircularHandle("connectorTargetThumb",f,u.x,u.y,e,qr(r,"ConnectorTargetThumb"),i&bt.ConnectorTarget,s,a,void 0,{"aria-label":"Thumb to move the target point of the connector"},void 0,"e-diagram-endpoint-handle e-targetend",c),l)if("Straight"===t.type&&t.segments.length>0)for(p=0;p0)for(p=0;p=3&&3===t.segments.length&&(S=1,b=t.segments.length-1),S=t.segments.length>t.maxSegmentThumb+2?2:S,b=t.segments.length>t.maxSegmentThumb+2?t.segments.length-2:b,1===t.segments.length&&t.segments[0].points.length<=2&&(S=1,b=t.segments.length),p=S;p=50&&i.allowDrag),this.renderOrthogonalThumb(t+"_"+(d+1),e,(i.points[parseInt(d.toString(),10)].x+i.points[d+1].x)/2,(i.points[parseInt(d.toString(),10)].y+i.points[d+1].y)/2,r,h,l,o,a,u)}else for(d=0;d=50&&i.allowDrag),this.renderOrthogonalThumb(t+"_"+(d+1),e,(i.points[parseInt(d.toString(),10)].x+i.points[d+1].x)/2,(i.points[parseInt(d.toString(),10)].y+i.points[d+1].y)/2,r,h,l,o,a,u)},n.prototype.renderOrthogonalThumb=function(t,e,i,r,s,o,a,l,h,c){var d,g,u=0,f=document.getElementById(this.diagramId);f&&(g=f.ej2_instances[0]);var y=h.constraints&qe.InheritSegmentThumbShape?g.segmentThumbShape:h.segmentThumbShape,b=h.constraints&qe.InheritSegmentThumbSize?g.segmentThumbSize:h.segmentThumbSize;if(d="horizontal"===a?function tre(n){return sre[""+n]}(y):n3(y),"Arrow"===y||"DoubleArrow"===y||"OpenArrow"===y)switch(c){case"Bottom":case"Right":u=180;break;default:u=0}else if("Fletch"===y||"OpenFetch"===y||"IndentedArrow"===y||"OutdentedArrow"===y)switch(c){case"Bottom":u=-90;break;case"Top":u=90;break;case"Right":u=180;break;default:u=0}var M={x:(i+l.tx)*l.scale-b/2,y:(r+l.ty)*l.scale-b/2,angle:u,fill:"#e2e2e2",stroke:"black",strokeWidth:1,dashArray:"",data:d,width:b,height:b,pivotX:.5,pivotY:.5,opacity:1,visible:o,id:t,class:"e-diagram-ortho-segment-handle"},w=np(M.data),C=new me(M.width,M.height),D=new Ze;if(M.data=D.updatePath(M.data,w,C),this.touchMove){var A=document.getElementById(t);A?this.updateSegmentPosition(A,M):this.svgRenderer.drawPath(s,M,this.diagramId)}else this.svgRenderer.drawPath(s,M,this.diagramId)},n.prototype.renderPivotLine=function(t,e,i,r,s){var o=t,l=!!(r&mr.Rotate);s&&(l=!1);var h=this.getBaseAttributes(o,i);h.fill="None",h.stroke="black",h.strokeWidth=1,h.dashArray="2,3",h.visible=l;var c=i.scale;h.x*=c,h.y*=c,h.width*=c,h.height*=c,h.id="pivotLine",h.class="e-diagram-pivot-line";var u={x:o.actualSize.width*o.pivot.x*c,y:0};h.startPoint={x:o.actualSize.width*o.pivot.x*c,y:-20},h.endPoint=u,this.svgRenderer.drawLine(e,h)},n.prototype.renderBezierLine=function(t,e,i,r,s,o){var l=this.getBaseAttributes(e,o);l.id=t,l.stroke="black",l.strokeWidth=1,l.dashArray="3,3",l.fill="None",l.class="e-diagram-bezier-control-line",l.x=0,l.y=0;var h=o.scale,g={x:(s.x+o.tx)*h,y:(s.y+o.ty)*h};l.startPoint={x:(r.x+o.tx)*h,y:(r.y+o.ty)*h},l.endPoint=g,this.svgRenderer.drawLine(i,l)},n.prototype.renderCircularHandle=function(t,e,i,r,s,o,a,l,h,c,d,u,f,p){var g=e,v={x:i,y:r};if(0!==g.rotateAngle||0!==g.parentTransform){var y=Bi();qi(y,g.rotateAngle+g.parentTransform,g.offsetX,g.offsetY),v=Ke(y,v)}var S=this.getBaseAttributes(g);if(S.stroke="black",S.strokeWidth=1,void 0!==u?(S.id="segmentEnd_"+u,S.fill="#e2e2e2"):S.fill=h?"#8CC63F":"white",S.cornerRadius=p/2,S.angle=e.rotateAngle,S.id=t,S.visible=o,S.class=f,S.width=p,S.height=p,S.x=(v.x+l.tx)*l.scale,S.y=(v.y+l.ty)*l.scale,S.x=S.x-S.width/2,S.y=S.y-S.height/2,h&&(S.class+=" e-connected"),c&&(S.visible=!1),this.touchMove){var b=document.getElementById(t);if(b)this.updateResizeHandle(b,S);else{var M=this.getParentSvg(e,"selector");this.svgRenderer.drawRectangle(s,S,this.diagramId,!0,!0,M,d,!0,a)}}else M=this.getParentSvg(e,"selector"),this.svgRenderer.drawRectangle(s,S,this.diagramId,!0,!0,M,d,!0,a)},n.prototype.updateResizeHandle=function(t,e){ii(t,{id:e.id,x:e.x.toString(),y:e.y.toString(),width:e.width.toString(),height:e.height.toString(),visibility:e.visible?"visible":"hidden",transform:"rotate("+e.angle+","+(e.x+e.width/2)+","+(e.y+e.height/2)+")",rx:e.cornerRadius||0,ry:e.cornerRadius||0,opacity:e.opacity})},n.prototype.renderBezierHandle=function(t,e,i,r,s,o,a,l,h,c,d,u,f){var v,p=document.getElementById(this.diagramId);p&&(v=p.ej2_instances[0]);var y=e,S={x:i,y:r};if(0!==y.rotateAngle||0!==y.parentTransform){var b=Bi();qi(b,y.rotateAngle+y.parentTransform,y.offsetX,y.offsetY),S=Ke(b,S)}var D=a.constraints&qe.InheritSegmentThumbSize?v.segmentThumbSize:a.segmentThumbSize,A=n3(a.constraints&qe.InheritSegmentThumbShape?v.segmentThumbShape:a.segmentThumbShape),x=this.getBaseAttributes(y);x.stroke="black",x.strokeWidth=1,void 0!==d?(x.id="segmentEnd_"+d,x.fill="#e2e2e2"):x.fill=h?"#8CC63F":"white",x.angle=e.rotateAngle,x.id=t,x.visible=o,x.class=u,x.width=D,x.height=D,x.data=A,x.x=(S.x+l.tx)*l.scale,x.y=(S.y+l.ty)*l.scale,x.x=x.x-x.width/2,x.y=x.y-x.height/2,h&&(x.class+=" e-connected"),c&&(x.visible=!1);var P=np(x.data),L=new me(x.width,x.height),O=new Ze;if(x.data=O.updatePath(x.data,P,L),this.touchMove){var N=document.getElementById(t);if(N)this.updateSegmentPosition(N,x);else{var T=this.getParentSvg(e,"selector");this.svgRenderer.drawPath(s,x,this.diagramId,!0,T)}}else T=this.getParentSvg(e,"selector"),this.svgRenderer.drawPath(s,x,this.diagramId,!0,T)},n.prototype.updateSegmentPosition=function(t,e){ii(t,{id:e.id,transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")translate("+e.x+","+e.y+")",visibility:e.visible?"visible":"hidden",opacity:e.opacity})},n.prototype.renderBorder=function(t,e,i,r,s,o){var l=this.getBaseAttributes(t,i);l.x*=i.scale,l.y*=i.scale,l.width*=i.scale,l.height*=i.scale,l.fill="transparent",l.stroke="#097F7F",l.strokeWidth=1.2,l.gradient=null,l.dashArray="6,3",l.class="e-diagram-selector",o&&(l.class+=" e-diagram-lane"),l.id="borderRect",l.id=this.rendererActions&Ga.DrawSelectorBorder?"borderRect_symbol":"borderRect",r||(l.class+=" e-disabled"),s&&(l.class+=" e-thick-border"),l.cornerRadius=0;var h=this.getParentSvg(t,"selector");this.svgRenderer.drawRectangle(e,l,this.diagramId,void 0,!0,h)},n.prototype.renderUserHandler=function(t,e,i,r,s,o){for(var l,a=t.wrapper,h=0,c=t.userHandles;h0||d.disableNodes&&t.nodes.length>0||"Drag"===s&&o)&&(l=!1);var u=document.getElementById(d.name+"_template_hiddenUserHandle");u&&(d.template=u.childNodes[0].cloneNode(!0));var f=Kx(t,d,i);if(f.x=(f.x+i.tx)*i.scale,f.y=(f.y+i.ty)*i.scale,d.visible&&(d.visible=!!(t.constraints&mr.UserHandle)),l)if(d.pathData){var p=d.pathData?d.pathData:d.content,g=this.getBaseAttributes(a);g.id=d.name+"_userhandle",g.fill=d.backgroundColor,g.stroke=d.borderColor,g.strokeWidth=d.borderWidth,g.centerX=f.x,g.centerY=f.y,g.radius=.5*d.size,g.class="e-diagram-userhandle-circle",g.angle=0,g.visible=d.visible,g.opacity=1,this.svgRenderer.drawCircle(e,g,1,{"aria-label":d.name+"user handle"});var y=[];y=mI(y=Ed(p));var S=np(p),w=vI(y,(d.size-.45*d.size)/S.width,(d.size-.45*d.size)/S.height,!0,S.x,S.y,0,0);S=np(w),this.svgRenderer.drawPath(e,C={x:f.x-S.width/2,y:f.y-S.height/2,angle:0,id:"",class:"e-diagram-userhandle-path",fill:d.pathColor,stroke:d.backgroundColor,strokeWidth:.5,dashArray:"",data:w,width:d.size-5,height:d.size-5,pivotX:0,pivotY:0,opacity:1,visible:d.visible},this.diagramId,void 0,void 0,{"aria-label":d.name+"user handle"})}else if(d.content){var D=new En(d.name,this.diagramId);D.content=d.content,D.offsetX=f.x,D.offsetY=f.y,D.id=d.name+"_shape",D.horizontalAlignment="Center",D.verticalAlignment="Center",D.visible=d.visible,D.setOffsetWithRespectToBounds(f.x,f.y,"Fraction"),D.relativeMode="Object",D.description=d.name||"User handle",D.measure(new me(d.size,d.size)),D.arrange(D.desiredSize),this.svgRenderer.drawNativeContent(D,e,d.size,d.size,this.adornerSvgLayer)}else if(d.source){var C,A=new bI;(C=this.getBaseAttributes(A,i)).width=d.size,C.height=d.size,C.x=f.x-d.size/2,C.y=f.y-d.size/2,C.sourceWidth=d.size,C.sourceHeight=d.size,C.alignment=A.imageAlign,C.source=d.source,C.scale=A.imageScale,C.visible=d.visible,C.description=d.name||"User handle",C.id=d.name+"_",this.renderer.drawImage(e,C,this.adornerSvgLayer,!1)}else{var x=new es(d.name,this.diagramId);x.offsetX=f.x,x.offsetY=f.y,x.id=d.name+"_shape",x.visible=d.visible,x.relativeMode="Object",x.template=d.template,x.measure(new me(d.size,d.size)),x.arrange(x.desiredSize),this.svgRenderer.drawHTMLContent(x,r,void 0,!0,void 0)}}},n.prototype.renderRotateThumb=function(t,e,i,r,s){new Ze;var a,l=new me;l.width=18,l.height=16;var d=!!(r&mr.Rotate);s&&(d=!1);var f=t.offsetX-t.actualSize.width*t.pivot.x+t.pivot.x*t.actualSize.width,p=t.offsetY-t.actualSize.height*t.pivot.y;if(a={x:(f=(f+i.tx)*i.scale)-.5*l.width,y:(p=(p+i.ty)*i.scale)-30-.5*l.height},0!==t.rotateAngle||0!==t.parentTransform){var g=Bi();qi(g,t.rotateAngle+t.parentTransform,(i.tx+t.offsetX)*i.scale,(i.ty+t.offsetY)*i.scale),a=Ke(g,a)}var v={x:a.x,y:a.y,angle:t.rotateAngle+t.parentTransform,fill:"#231f20",stroke:"black",strokeWidth:.5,dashArray:"",data:"M 16.856144362449648 10.238890446662904 L 18.000144362449646 3.437890446662903L 15.811144362449646 4.254890446662903 C 14.837144362449646 2.5608904466629028 13.329144362449647 1.2598904466629026 11.485144362449645 0.5588904466629026 C 9.375144362449646 - 0.24510955333709716 7.071144362449646 - 0.18010955333709716 5.010144362449646 0.7438904466629028 C 2.942144362449646 1.6678904466629028 1.365144362449646 3.341890446662903 0.558144362449646 5.452890446662903 C - 0.244855637550354 7.567890446662903 - 0.17985563755035394 9.866890446662904 0.7431443624496461 11.930890446662904 C 1.6681443624496461 13.994890446662904 3.343144362449646 15.575890446662903 5.457144362449647 16.380890446662903 C 6.426144362449647 16.7518904466629 7.450144362449647 16.9348904466629 8.470144362449647 16.9348904466629 C 9.815144362449647 16.9348904466629 11.155144362449647 16.6178904466629 12.367144362449647 15.986890446662901 L 11.351144362449647 14.024890446662901 C 9.767144362449647 14.8468904466629 7.906144362449647 14.953890446662902 6.237144362449647 14.3178904466629 C 4.677144362449647 13.7218904466629 3.444144362449647 12.5558904466629 2.758144362449647 11.028890446662901 C 2.078144362449646 9.501890446662903 2.031144362449646 7.802890446662903 2.622144362449646 6.243890446662903 C 3.216144362449646 4.6798904466629025 4.387144362449646 3.442890446662903 5.914144362449646 2.760890446662903 C 7.437144362449646 2.078890446662903 9.137144362449646 2.0298904466629026 10.700144362449645 2.6258904466629027 C 11.946144362449646 3.100890446662903 12.971144362449646 3.9538904466629026 13.686144362449646 5.049890446662903 L 11.540144362449645 5.850890446662903 L 16.856144362449648 10.238890446662904 Z",width:20,height:20,pivotX:0,pivotY:0,opacity:1,visible:d,id:"rotateThumb",class:"e-diagram-rotate-handle"};if(this.touchMove){var y=document.getElementById("rotateThumb");y?this.updateSegmentPosition(y,v):this.svgRenderer.drawPath(e,v,this.diagramId,!0,void 0,{"aria-label":"Thumb to rotate the selected object"})}else this.svgRenderer.drawPath(e,v,this.diagramId,!0,void 0,{"aria-label":"Thumb to rotate the selected object"})},n.prototype.renderPathElement=function(t,e,i,r,s,o,a){var l=this.getBaseAttributes(t,i,o);if(l.data=t.absolutePath,l.data=t.absolutePath,t.isPathPort&&a){l.x=a[t.id]?a[t.id].cx:l.x,l.y=a[t.id]?a[t.id].cy:l.y,t.bounds.x=l.x,t.bounds.y=l.y;var h=document.getElementById(this.diagramId);h&&"PortDrag"!==h.ej2_instances[0].eventHandler.currentAction&&(t.offsetX=l.x+t.width/2,t.offsetY=l.y+t.height/2)}var u=t.description?t.description:t.id;if(this.isSvgMode||(l.x=t.flipOffset.x?t.flipOffset.x:l.x,l.y=t.flipOffset.y?t.flipOffset.y:l.y),t.isExport){var f=t.absoluteBounds,p=Ed(l.data),g=this.findAndStoreArcValues(p);l.arc=g,l.data=OF(t,f,0,l)}this.renderer.drawPath(e,l,this.diagramId,void 0,r,u)},n.prototype.findAndStoreArcValues=function(t){var e=[];return t.forEach(function(i){"A"===i.command&&e.push({r1:i.r1/2,r2:i.r2/2})}),e},n.prototype.renderSvgGridlines=function(t,e,i,r,s,o){var a=document.createElementNS("http://www.w3.org/2000/svg","pattern"),l=document.createElementNS("http://www.w3.org/2000/svg","defs");l.setAttribute("id",this.diagramId+"_grid_pattern_defn"),(t.constraints&ei.ShowHorizontalLines||t.constraints&ei.ShowVerticalLines)&&a.setAttribute("id",this.diagramId+"_pattern");var h=0,c=0,d=0,u=0,f=1,p=!1,g="Lines"===t.gridType,v=g?t.verticalGridlines.lineIntervals:t.verticalGridlines.dotIntervals,y=g?t.horizontalGridlines.lineIntervals:t.horizontalGridlines.dotIntervals;if(r.showRulers&&r.dynamicGrid&&s&&o)d=o.updateSegmentWidth(i.scale),u=s.updateSegmentWidth(i.scale),t.horizontalGridlines.scaledIntervals=[d/s.interval],t.verticalGridlines.scaledIntervals=[u/o.interval],p=!0;else{for(var S=0;S=2)for(;e>=2;)e/=2;else if(e<=.5)for(;e<=.5;)e*=2;var i;if(t.horizontalGridlines.scaledIntervals=t.horizontalGridlines.snapIntervals,t.verticalGridlines.scaledIntervals=t.verticalGridlines.snapIntervals,1!==e){var r=t.horizontalGridlines;for(r.scaledIntervals=[],i=0;ithis.groupElement.actualSize.height&&("Clip"===t.style.textOverflow||"Ellipsis"===t.style.textOverflow)&&(a.y=a.y+(a.height-this.groupElement.actualSize.height)/2),this.renderer.drawRectangle(e,a,this.diagramId,void 0,void 0,r),this.renderer.drawText(e,a,r,l,this.diagramId,t.isExport&&Math.min(t.exportScaleValue.x||t.exportScaleValue.y),this.groupElement),this.isSvgMode&&(t.doWrap=!1)},n.prototype.renderNativeElement=function(t,e,i,r,s){var o,a,l=this.getParentSvg(t,void 0,e)||r,h=this.getParentElement(t,e,l).g||e,c=this.getBaseAttributes(t,i);switch(c.fill="transparent",c.cornerRadius=t.cornerRadius,c.stroke="transparent",this.renderer.drawRectangle(e,c,this.diagramId,void 0,void 0,r),t.scale){case"None":o=t.contentSize.width,a=t.contentSize.height;break;case"Stretch":o=t.actualSize.width,a=t.actualSize.height;break;case"Meet":o=a=t.actualSize.width<=t.actualSize.height?t.actualSize.width:t.actualSize.height;break;case"Slice":o=a=t.actualSize.width>=t.actualSize.height?t.actualSize.width:t.actualSize.height}this.svgRenderer&&this.svgRenderer.drawNativeContent(t,h,a,o,l)},n.prototype.renderHTMLElement=function(t,e,i,r,s,o,a){var l=this.getBaseAttributes(t,r);l.fill="transparent",l.cornerRadius=t.cornerRadius,l.stroke="transparent",this.renderer.drawRectangle(e,l,this.diagramId,void 0,void 0,s),this.svgRenderer&&this.svgRenderer.drawHTMLContent(t,i.children[0],r,function lse(n){var t=n.parentElement;do{if(um(t,"e-diagram"))return!0;t=t.parentElement}while(t);return!1}(i),a)},n.prototype.renderImageElement=function(t,e,i,r,s){var o=this.getBaseAttributes(t,i);o.cornerRadius=0,this.renderer.drawRectangle(e,o,this.diagramId,void 0,void 0,r);var a,l,h,c,g,d=t.contentSize.width,u=t.contentSize.height,f=o.width/d,p=o.height/u;if("Stretch"===t.stretch)a=d*(g=Math.min(f,p)),l=u*g;else switch(t.stretch){case"Meet":a=d*(g=Math.min(f,p)),l=u*g,o.x+=Math.abs(o.width-a)/2,o.y+=Math.abs(o.height-l)/2;break;case"Slice":g=Math.max(f,p),h=o.width/(a=d*g)*d,c=o.height/(l=u*g)*u;break;case"None":a=d,l=u}o.width=a,o.height=l,o.sourceWidth=h,o.sourceHeight=c,o.source=t.source,o.alignment=t.imageAlign,o.scale=t.imageScale,o.description=t.description?t.description:t.id,this.renderer.drawImage(e,o,r,s)},n.prototype.renderContainer=function(t,e,i,r,s,o,a,l,h,c,d){var g,u={svg:s,g:e},f=document.getElementById(this.diagramId);if(f&&(g=f.ej2_instances[0]),this.diagramId&&(s=this.getParentSvg(t)||s,this.isSvgMode)){var v=this.getParentElement(t,e,s,l).g||e;s=this.getParentSvg(this.hasNativeParent(t.children))||s;var y=this.getParentElement(this.hasNativeParent(t.children),v,s,l);u.svg=y.svg||s,u.g=y.g||v,o&&s&&(s.getElementById(u.g.id)||e.appendChild(u.g)),e=u.g}if(this.renderRect(t,e,r,s),this.groupElement=t,t.hasChildren()){for(var b,S=void 0,M=0,w=t.children;M0&&(D=g.selectedItems.nodes[0]);var L,A=void 0,x=void 0,P=!1;if(g&&g.selectedItems&&(L=g.getObject(t.id)),"None"!==t.flip&&(D=L),"None"===t.flip&&(D=L),D&&D.flipMode&&(P=!0),!(t.elementActions&Xr.ElementIsGroup)&&g instanceof Fl&&g.nameTable[t.id]&&"connectors"!==g.nameTable[t.id].propName&&P&&D){if(A=t.children&&t.children[0]instanceof En?document.getElementById(D.id+"_content_inner_native_element"):document.getElementById(D.id+"_content_groupElement"),!(t.children[0]instanceof En)&&"Text"!==D.shape.type&&"None"!==D.flipMode&&"Label"!==D.flipMode&&"All"!==D.flipMode&&"PortAndLabel"!==D.flipMode&&"LabelText"!==D.flipMode&&"PortAndLabelText"!==D.flipMode&&"LabelAndLabelText"!==D.flipMode||t.children[0]instanceof En&&"Port"===D.flipMode)return void this.renderFlipElement(t,A,D.flip);if((t.children[0]instanceof En&&("All"===D.flipMode||"Label"===D.flipMode)||"Label"===D.flipMode||"PortAndLabel"===D.flipMode||"LabelText"===D.flipMode||"PortAndLabelText"===D.flipMode||"LabelAndLabelText"===D.flipMode||"Image"===D.shape.type&&"Label"===D.flipMode)&&this.renderFlipElement(t,A,t.flip),"None"!==t.flip&&"None"===D.flipMode)this.renderFlipElement(t,A,t.flip);else if("None"!==t.flip&&("Label"===D.flipMode||"PortAndLabel"===D.flipMode||"LabelText"===D.flipMode||"PortAndLabelText"===D.flipMode||"LabelAndLabelText"===D.flipMode)||t.children[0]instanceof En&&"None"!==t.flip&&D&&("None"===D.flipMode||"All"===D.flipMode)){for(var O=0;O0){var i=t[0];if(i instanceof En)return i;i.children&&i.children.length&&this.hasNativeParent(i.children,e++||0)}},n.prototype.renderRect=function(t,e,i,r,s){var o=this.getBaseAttributes(t,i,s);o.cornerRadius=t.cornerRadius||0,t.isExport&&(o.cornerRadius*=t.exportScaleValue.x),this.renderer.drawRectangle(e,o,this.diagramId,t.isExport,void 0,r,t.description?t.description:t.id)},n.prototype.drawRect=function(t,e){e.cornerRadius=0,this.svgRenderer.drawRectangle(t,e,this.diagramId)},n.prototype.getBaseAttributes=function(t,e,i){var r={width:t.actualSize.width,height:t.actualSize.height,x:t.offsetX-t.actualSize.width*t.pivot.x,y:t.offsetY-t.actualSize.height*t.pivot.y,fill:t.style.fill,stroke:t.style.strokeColor,angle:t.rotateAngle+t.parentTransform,pivotX:t.pivot.x,pivotY:t.pivot.y,strokeWidth:t.style.strokeWidth,dashArray:t.style.strokeDashArray||"",opacity:t.style.opacity,shadow:t.shadow,gradient:t.style.gradient,visible:t.visible,id:t.id,description:t.description,canApplyStyle:t.canApplyStyle,shapeType:t.shapeType};return"Page"===t.rotationReference&&(r.angle=t.rotateAngle),i&&(r.x=r.x-.5,r.y=r.y-.5),t.isExport&&(r.width*=t.exportScaleValue.x,r.height*=t.exportScaleValue.y,r.x*=t.exportScaleValue.x,r.y*=t.exportScaleValue.y,r.strokeWidth*=t.exportScaleValue.x),t.flip&&(r.flip=t.flip),e&&(r.x+=e.tx,r.y+=e.ty),r},n.renderSvgBackGroundImage=function(t,e,i,r,s,o){if(t.source){var l=mT(e.id).getElementById(e.id+"_image");if(!l){var h=function moe(n){return xt(n).getElementsByClassName("e-background-image-layer")[0]}(e.id);(l=document.createElementNS("http://www.w3.org/2000/svg","image")).setAttribute("id",e.id+"_image"),h.appendChild(l)}var c=new Image;c.src=t.source,l.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",c.src.toString());var d="None"!==t.scale?t.scale:"",u=t.align,f=u.charAt(0).toLowerCase()+u.slice(1);d&&(f+=" "+d.charAt(0).toLowerCase()+d.slice(1)),ii(l,{id:e.id+"_image",x:i,y:r,width:s,height:o,preserveAspectRatio:f})}},n.prototype.transformLayers=function(t,e){var i=t.tx*t.scale,r=t.ty*t.scale,s="domTable";if(i!==this.transform.x||r!==this.transform.y||0===i||0===r){e&&(window[""+s][this.diagramId+"_diagramLayer"]||(window[""+s][this.diagramId+"_diagramLayer"]=this.diagramSvgLayer.getElementById(this.diagramId+"_diagramLayer")),window[""+s][this.diagramId+"_diagramLayer"].setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+"),scale("+t.scale+")"));var a=function yoe(n){var t="domTable",e=null;return window[t][n+"_gridline"]?e=window[t][n+"_gridline"]:(e=Fd(n).getElementById(n+"_gridline"),window[t][n+"_gridline"]=e),e}(this.diagramId);return a.setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+")"),window[""+s][this.diagramId+"_diagramPorts"]||(window[""+s][this.diagramId+"_diagramPorts"]=this.iconSvgLayer.getElementById(this.diagramId+"_diagramPorts")),window[""+s][this.diagramId+"_diagramPorts"].setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+"),scale("+t.scale+")"),window[""+s][this.diagramId+"_diagramExpander"]||(window[""+s][this.diagramId+"_diagramExpander"]=this.iconSvgLayer.getElementById(this.diagramId+"_diagramExpander")),window[""+s][this.diagramId+"_diagramExpander"].setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+"),scale("+t.scale+")"),window[""+s][this.diagramId+"_nativeLayer"]||(window[""+s][this.diagramId+"_nativeLayer"]=this.nativeSvgLayer.getElementById(this.diagramId+"_nativeLayer")),window[""+s][this.diagramId+"_nativeLayer"].setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+"),scale("+t.scale+")"),Io(this.diagramId).children[0].style.transform="translate("+t.tx*t.scale+"px,"+t.ty*t.scale+"px)scale("+t.scale+")",this.transform={x:t.tx*t.scale,y:t.ty*t.scale},!0}return!1},n.prototype.updateNode=function(t,e,i,r,s,o,a){this.renderElement(t,e,i,r,this.getParentSvg(t),void 0,void 0,s,null,o,a)},n}(),tse=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),ZI=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},oF=function(n){function t(e,i){var r=n.call(this,e,i)||this;return r.mode="Canvas",r.id="overview",r.actionName="",r.startPoint=null,r.currentPoint=null,r.prevPoint=null,r.scale=null,r.inAction=!1,r.viewPortRatio=1,r.horizontalOffset=0,r.verticalOffset=0,r.model={},r.event=!0,r.overviewid=88123,r.model={width:r.width,height:r.height},r}return tse(t,n),t.prototype.onPropertyChanged=function(e,i){for(var r=0,s=Object.keys(e);r0||e.toString().indexOf("%")>0?e.toString():e.toString()+"px"},t.prototype.renderCanvas=function(e){var i=document.getElementById(this.element.id+"_canvas");i||(i=Tt("div",{}),this.element.appendChild(i)),Ho(i,{id:this.element.id+"_canvas",class:"drawing",style:"position:relative; height:"+this.getSizeValue(this.model.height)+"; width:"+this.getSizeValue(this.model.width)+";style:-ms-touch-action: none;touch-action: none;"}),this.element.setAttribute("tabindex",String(-1)),this.element.style.overflow="hidden",this.element.style.height=String(this.model.height),this.element.style.width=String(this.model.width),this.canvas=i},t.prototype.setParent=function(e){var i=document.getElementById(e);if(this.parent){var s=this.parent;this.parent=null,s.setOverview(null,this.element.id),this.removeDocument(this)}this.parent=this.getDiagram(i,"ej2_instances"),this.parent&&this.parent.setOverview(this)},t.prototype.getDiagram=function(e,i){for(var r,s=e[""+i].length,o=0;o0?f:Math.floor(window.innerWidth)}if(0===h){var p=Math.floor(window.innerHeight-u-Math.floor(c.top));h=p>0?p:Math.floor(window.innerHeight)}l>0&&(s.setAttribute("width",String(l)),this.model.height=h),h>0&&(s.setAttribute("height",String(h)),this.model.width=l),e.diagramLayerDiv||(e.diagramLayerDiv=Tt("div",{}),e.diagramLayer=bo.createCanvas(this.element.id+"_diagramLayer",this.model.width,this.model.height),e.diagramLayer.setAttribute("style","position:absolute; left:0px; top:0px "),e.diagramLayerDiv.appendChild(e.diagramLayer),e.canvas.appendChild(e.diagramLayerDiv)),Ho(e.diagramLayerDiv,{id:this.element.id+"_diagramLayer_div",style:"width:"+this.model.width+"px; height:"+this.model.height+"px;position:absolute;top:0px;left:0px"}),this.renderHtmlLayer(e.canvas),this.renderNativeLayer(e.canvas,e),this.addOverviewRectPanel(e)},t.prototype.removeDocument=function(e){var i=document.getElementById(this.canvas.id+"_svg");this.canvas.removeChild(i);var r=document.getElementById(this.element.id+"_htmlLayer");this.canvas.removeChild(r);var s=document.getElementById(this.element.id+"_diagramLayer_div");this.canvas.removeChild(s),e.diagramLayerDiv=null,e.diagramLayer=null,window.domTable[this.id+"html_layer"]=null},t.prototype.renderHtmlLayer=function(e){var i=Tt("div",{id:this.element.id+"_htmlLayer",class:"e-html-layer",style:"pointer-events:none;position:absolute;top:0px;left:0px;"}),s=Tt("div",{id:this.element.id+"_htmlLayer_div",style:"position:absolute;top:0px;left:0px;"});return i.appendChild(s),e.appendChild(i),i},t.prototype.renderNativeLayer=function(e,i){if(!document.getElementById(this.element.id+"_nativeLayer_svg")){var r=this.parent.createSvg(this.element.id+"_nativeLayer_svg",this.model.width,this.model.height),s=Fi("g",{id:this.element.id+"_nativeLayer"});r.appendChild(s),i.diagramLayerDiv.appendChild(r),ii(r,{class:"e-native-layer"})}},t.prototype.addOverviewRectPanel=function(e){var i=document.getElementById(this.canvas.id+"_overviewsvg");i&&i.parentNode.removeChild(i),i=Fi("svg",{id:this.canvas.id+"_overviewsvg",class:"overviewsvg",version:"1.1",style:"position:absolute;left:0px;top:0px; aria-label:Specifies overview",width:this.model.width,height:this.model.height}),e.canvas.appendChild(i);var s=Fi("g",{id:this.element.id+"_overviewlayer",style:"pointer-events:none"});i.appendChild(s);var o=Fi("rect",{fill:"transparent",width:"100%",height:"100%",class:"overviewbackrect",id:this.canvas.id+"overviewbackrect"});o.setAttribute("style"," pointer-events: none; "),s.appendChild(o);var a=Fi("g",{id:this.canvas.id+"overviewhandle",style:"pointer-events:all"});s.appendChild(a);var l=Fi("rect",{id:this.canvas.id+"overviewrect",fill:"transparent"});a.appendChild(l),this.renderOverviewCorner("left",a),this.renderOverviewCorner("right",a),this.renderOverviewCorner("top",a),this.renderOverviewCorner("bottom",a),this.renderOverviewCorner("topleft",a),this.renderOverviewCorner("topright",a),this.renderOverviewCorner("bottomleft",a),this.renderOverviewCorner("bottomright",a)},t.prototype.renderOverviewCorner=function(e,i){var s,o=Fi(s="top"===e||"bottom"===e||"right"===e||"left"===e?"rect":"circle",{id:this.canvas.id+"visible"+e,class:"overview-resizer"});i.appendChild(o);var a=Fi(s,{id:this.canvas.id+e,class:"overviewresizer",fill:"transparent"});i.appendChild(a)},t.prototype.updateOverviewRectangle=function(){var e=this.currentPoint.x-this.prevPoint.x,i=this.currentPoint.y-this.prevPoint.y,r=new me;r.width=0,r.height=0;var s=0,o=0;switch(this.resizeDirection){case"left":r.width-=e,r.height-=e/this.viewPortRatio,s=e,o=e/this.viewPortRatio,o/=2;break;case"right":r.width+=e,r.height+=e/this.viewPortRatio,o=e/this.viewPortRatio,o/=-2;break;case"top":r.height-=i,r.width-=i*this.viewPortRatio,o=i,s=i*this.viewPortRatio,s/=2;break;case"bottom":r.height+=i,r.width+=i*this.viewPortRatio,s=i*this.viewPortRatio,s/=-2;break;case"topleft":Math.abs(i)>Math.abs(e)?e=i*this.viewPortRatio:i=e/this.viewPortRatio,r.width-=e,r.height-=i,s=e,o=i;break;case"topright":Math.abs(i)>Math.abs(e)?e=-i*this.viewPortRatio:i=-e/this.viewPortRatio,o=i,r.width+=e,r.height-=i;break;case"bottomleft":Math.abs(i)>Math.abs(e)?e=-i*this.viewPortRatio:i=-e/this.viewPortRatio,s=e,r.width-=e,r.height+=i;break;case"bottomright":Math.abs(i)>Math.abs(e)?e=i*this.viewPortRatio:i=e/this.viewPortRatio,r.width+=e,r.height+=i}this.updateHelper(s,o,r,void 0,void 0)},t.prototype.updateHelper=function(e,i,r,s,o){var a,l,h,u,f,d=this.element.getElementsByTagName("svg")[2].getElementById("helper");r?(a=(h=d.getBBox()).x+e,l=h.y+i,s=h.width+r.width,o=h.height+r.height):(u=this.currentPoint.x>this.startPoint.x?this.currentPoint.x-this.prevPoint.x:this.prevPoint.x-this.currentPoint.x,f=this.currentPoint.y>this.startPoint.y?this.currentPoint.y-this.prevPoint.y:this.prevPoint.y-this.currentPoint.y,Math.abs(f)>Math.abs(u)?u=this.viewPortRatio*f:f=u/this.viewPortRatio,h=d.getBBox(),a=this.startPoint.x>this.currentPoint.x?h.x-u:h.x,l=this.startPoint.y>this.currentPoint.y?h.y-f:h.y,s=h.width+u,o=h.height+f),ii(this.helper,{id:this.helper.id,x:a,y:l,width:Math.max(0,s),height:Math.max(0,o)})},t.prototype.updateOverviewrect=function(e,i,r,s){Ho(document.getElementById(this.canvas.id+"overviewrect"),{x:e,y:i,width:Math.max(1,r),height:Math.max(1,s)}),this.updateOverviewCorner("top",e+8,i+1,Math.max(0,r-16),2),this.updateOverviewCorner("bottom",e+8,i+s+3,Math.max(0,r-16),2),this.updateOverviewCorner("left",e-2,i+11,2,Math.max(0,s-16)),this.updateOverviewCorner("right",e+r,i+11,2,Math.max(0,s-16)),this.updateOverviewCorner("topleft",e,i+3,5,5),this.updateOverviewCorner("topright",e+r,i+3,5,5),this.updateOverviewCorner("bottomleft",e,i+s+3,5,5),this.updateOverviewCorner("bottomright",e+r,i+s+3,5,5)},t.prototype.updateOverviewCorner=function(e,i,r,s,o){var a,l;"top"===e||"bottom"===e||"right"===e||"left"===e?(a={x:i,y:r,width:s,height:o,fill:"#ED1C24"},l={x:i-2,y:r-2,width:2===s?4:s,height:2===o?4:o}):(a={cx:i,cy:r,r:4,fill:"#ED1C24"},l={cx:i,cy:r,r:6,fill:"transparent"}),Ho(document.getElementById(this.canvas.id+"visible"+e),a),Ho(document.getElementById(this.canvas.id+e),l)},t.prototype.translateOverviewRectangle=function(){Number(this.model.width),Number(this.model.height);var r=this.currentPoint.x-this.prevPoint.x,s=this.currentPoint.y-this.prevPoint.y,l=this.element.getElementsByClassName("overviewsvg")[0].getElementById(this.canvas.id+"overviewrect").getBBox(),h=l.x+r,c=l.y+s,d=l.width,u=l.height;this.updateOverviewrect(h,c,d,u),this.updateParentView(this.parent.scroller.currentZoom,h,c,d,u,null)},t.prototype.renderOverviewRect=function(e,i,r,s){var o=Number(this.model.width),a=Number(this.model.height),c=Math.max(this.parent.scroller.viewPortWidth/(r/o*this.contentWidth),this.parent.scroller.viewPortHeight/(s/a*this.contentHeight));if(c>=.25&&c<=30){this.updateParentView(c,e,i,r,s,{x:0,y:0});var u=this.scrollOverviewRect(this.parent.scroller.horizontalOffset,this.parent.scroller.verticalOffset,this.parent.scroller.currentZoom,!0);if(this.helper){var p=this.element.getElementsByTagName("rect")[10].getBBox();u.x=p.x,u.y=p.y}"pan"===this.actionName?this.updateOverviewrect(-u.x,-u.y,u.width,u.height):this.updateOverviewrect(u.x,u.y,u.width,u.height)}},t.prototype.scrollOverviewRect=function(e,i,r,s){if(!this.actionName||s){var o=Number(this.model.width),a=Number(this.model.height),l=Math.min(this.contentWidth/o,this.contentHeight/a),h=new Ne,c=h.x=e/r/l,d=h.y=i/r/l,u=0;this.parent.rulerSettings.showRulers&&(u=25);var f=document.getElementById(this.parent.element.id+"content"),p=0,g=0;f&&(p=f.offsetWidth-f.clientWidth,g=f.offsetHeight-f.clientHeight);var v=h.width=(this.parent.scroller.viewPortWidth-u-p)/r/l,y=h.height=(this.parent.scroller.viewPortHeight-u-g)/r/l;if(s){var S=new Ne;return S.x=c,S.y=d,S.width=v,S.height=y,S}this.updateOverviewrect(-c,-d,v,y)}return null},t.prototype.updateParentView=function(e,i,r,s,o,a){var p,g,l=Number(this.model.width),h=Number(this.model.height),u=i*(this.contentWidth/l)*e,f=r*(this.contentHeight/h)*e;this.parent.scroller.getPageBounds(),(1!==e||"pan"===this.actionName)&&(p=-u-this.parent.scroller.horizontalOffset,g=-f-this.parent.scroller.verticalOffset),this.parent.setBlazorDiagramProps(!0),this.parent.realActions|=$i.OverViewAction,"scale"===this.actionName||"draw"===this.actionName?this.parent.scroller.zoom(e/this.parent.scroller.currentZoom,p,g,a):ce()?this.parent.scroller.zoom(1,p,g,a):this.parent.pan(p,g,a,!0)},t.prototype.updateHtmlLayer=function(e){var i=Io(e.element.id),r=this.parent.scroller.getPageBounds(!0),o=r.height,a=Math.max(r.width,this.parent.scroller.viewPortWidth),l=Math.max(o,this.parent.scroller.viewPortHeight/this.parent.scroller.currentZoom),h=Math.min(Number(this.model.width)/a,Number(this.model.height)/l);i.style.transform="scale("+h+") translate("+this.parent.scroller.transform.tx+"px,"+this.parent.scroller.transform.ty+"px)"},t.prototype.updateView=function(e){var i=this.parent.scroller.getPageBounds(),r=i.width,s=i.height,o=Number(this.model.width),a=Number(this.model.height),l=Math.max(r,this.parent.scroller.viewPortWidth),h=Math.max(s,this.parent.scroller.viewPortHeight);this.contentWidth=l=Math.max(l,o/a*h),this.contentHeight=h=Math.max(h,a/o*l);var c=Math.min(o/l,a/h),d=document.getElementById(this.element.id+"_htmlLayer");d.style.webkitTransform="scale("+c+") translate("+-i.x+"px,"+-i.y+"px)",d.style.transform="scale("+c+") translate("+-i.x+"px,"+-i.y+"px)",document.getElementById(this.element.id+"_overviewlayer").setAttribute("transform","translate("+-i.x*c+","+-i.y*c+")"),this.horizontalOffset=i.x*c,this.verticalOffset=i.y*c;var f=document.getElementById(this.element.id+"_diagramLayer"),p=zF(this.element.id),g=f.getContext("2d"),v=Number(this.model.width)/this.contentWidth,y=Number(this.model.height)/this.contentHeight;v=Math.min(v,y);var S=this.parent.scroller.transform;p.setAttribute("transform","translate("+S.tx*v+","+S.ty*y+"),scale("+v+")"),g.setTransform(v,0,0,v,0,0),g.fillStyle="red",this.scrollOverviewRect(this.parent.scroller.horizontalOffset,this.parent.scroller.verticalOffset,this.parent.scroller.currentZoom)},t.prototype.scrolled=function(e){if(this.event){var i=this.scrollOverviewRect(this.parent.scroller.horizontalOffset,this.parent.scroller.verticalOffset,this.parent.scroller.currentZoom,!0);this.updateOverviewrect(-i.x,-i.y,i.width,i.height),this.updateView(this)}},t.prototype.updateCursor=function(e){if(um(e.target,"overviewresizer"))switch(e.target.id){case this.canvas.id+"left":this.canvas.style.cursor="w-resize";break;case this.canvas.id+"right":this.canvas.style.cursor="e-resize";break;case this.canvas.id+"top":this.canvas.style.cursor="n-resize";break;case this.canvas.id+"bottom":this.canvas.style.cursor="s-resize";break;case this.canvas.id+"topleft":this.canvas.style.cursor="nw-resize";break;case this.canvas.id+"topright":this.canvas.style.cursor="ne-resize";break;case this.canvas.id+"bottomleft":this.canvas.style.cursor="sw-resize";break;case this.canvas.id+"bottomright":this.canvas.style.cursor="se-resize"}else this.canvas.style.cursor="default"},t.prototype.mouseMove=function(e){if(this.event=!1,this.updateCursor(e),this.currentPoint=this.mousePosition(e),this.actionName)switch(this.actionName){case"draw":!this.inAction&&(this.startPoint.x!==this.currentPoint.x||this.startPoint.y!==this.currentPoint.y)&&(this.initHelper(),this.inAction=!0),this.inAction&&this.updateHelper();break;case"scale":this.inAction||(this.initHelper(),this.inAction=!0),this.updateOverviewRectangle();break;case"pan":(this.startPoint.x!==this.currentPoint.x||this.startPoint.y===this.currentPoint.y||this.inAction)&&(this.inAction=!0,this.translateOverviewRectangle())}this.prevPoint=this.currentPoint},t.prototype.documentMouseUp=function(e){this.inAction=!1,this.actionName="",this.helper&&(this.helper.parentNode.removeChild(this.helper),this.helper=null),this.event=!0,document.getElementById(this.canvas.id+"overviewhandle").style.pointerEvents="all"},t.prototype.windowResize=function(e){var i=this;return this.resizeTo&&clearTimeout(this.resizeTo),this.resizeTo=setTimeout(function(){var s=document.getElementById(i.element.id).getBoundingClientRect();i.model.width=s.width>0?s.width:i.model.width,i.model.height=s.height>0?s.height:i.model.height,i.renderCanvas(),i.setParent(i.sourceID)},10),!1},t.prototype.mouseDown=function(e){if(e.target.id===this.canvas.id+"_overviewsvg"&&(this.actionName="draw"),e.target.id===this.canvas.id+"overviewrect"&&(this.actionName="pan"),um(e.target,"overviewresizer"))switch(this.actionName="scale",e.target.id){case this.canvas.id+"left":this.resizeDirection="left";break;case this.canvas.id+"right":this.resizeDirection="right";break;case this.canvas.id+"top":this.resizeDirection="top";break;case this.canvas.id+"bottom":this.resizeDirection="bottom";break;case this.canvas.id+"topleft":this.resizeDirection="topleft";break;case this.canvas.id+"topright":this.resizeDirection="topright";break;case this.canvas.id+"bottomleft":this.resizeDirection="bottomleft";break;case this.canvas.id+"bottomright":this.resizeDirection="bottomright"}this.startPoint=this.prevPoint=this.mousePosition(e),this.viewPortRatio=this.parent.scroller.viewPortWidth/this.parent.scroller.viewPortHeight,document.getElementById(this.canvas.id+"overviewhandle").style.pointerEvents="none"},t.prototype.mouseUp=function(e){if(this.currentPoint=this.mousePosition(e),this.actionName)if(this.startPoint.x!==this.currentPoint.x||this.startPoint.y!==this.currentPoint.y){if("pan"!==this.actionName&&this.helper){var i=this.element.getElementsByTagName("rect")[10].getBBox();this.resizeDirection=this.resizeDirection||"",this.renderOverviewRect(i.x,i.y,o=i.width,a=i.height)}}else if(e.target.id===this.canvas.id+"_overviewsvg"||"helper"===e.target.id){var o=(i=this.element.getElementsByTagName("svg")[2].getElementById(this.canvas.id+"overviewrect").getBBox()).width,a=i.height;this.inAction=!0,this.actionName="pan",this.renderOverviewRect(this.currentPoint.x-o/2,this.currentPoint.y-a/2,o,a),this.inAction=!1}this.helper&&(this.helper.parentNode.removeChild(this.helper),this.helper=null),this.actionName="",this.startPoint=null,this.currentPoint=null,this.prevPoint=null,this.helper=null,this.viewPortRatio=1,this.resizeDirection="",this.inAction=!1,this.event=!0,document.getElementById(this.canvas.id+"overviewhandle").style.pointerEvents="all"},t.prototype.initHelper=function(){var e=this.element.getElementsByTagName("svg")[2],i=this.startPoint.x,r=this.startPoint.y,s=1,o=1;if("scale"===this.actionName){var l=e.getElementById(this.canvas.id+"overviewrect").getBBox();i=l.x,r=l.y,s=l.width,o=l.height}var h=Fi("rect",{id:"helper",x:i,y:r,width:s,height:o,fill:"transparent",stroke:"gray","stroke-dasharray":"2 2","shape-rendering":"crispEdges"});e.getElementById(this.element.id+"_overviewlayer").appendChild(h),this.helper=h},t.prototype.mousePosition=function(e){var i,r,s;-1!==e.type.indexOf("touch")?(r=(i=e).changedTouches[0].clientX-this.element.offsetLeft,s=i.changedTouches[0].clientY-this.element.offsetTop):(r=e.clientX,s=e.clientY);var l=this.element.getBoundingClientRect();return{x:(r-=l.left)+this.horizontalOffset,y:(s-=l.top)+this.verticalOffset}},t.prototype.destroy=function(){if(this.unWireEvents(),this.notify("destroy",{}),n.prototype.destroy.call(this),document.getElementById(this.element.id)){this.element.classList.remove("e-overview");var e=document.getElementById(this.element.id+"_canvas");e&&this.element.removeChild(e)}this.parent.views.splice(this.parent.views.indexOf(this.element.id),1),this.diagramLayerDiv=null,this.canvas=null,this.parent=null},t.prototype.getModuleName=function(){return"Overview"},ZI([I("100%")],t.prototype,"width",void 0),ZI([I("100%")],t.prototype,"height",void 0),ZI([I("")],t.prototype,"sourceID",void 0),ZI([H()],t.prototype,"created",void 0),t}(Ii);function rse(n,t){for(var e=0;eR.findLength(e,n)?e:t;var o=R.findAngle(t,e),a=R.findAngle(i,n),l=R.findLength(i,n),h=a+2*(o-a);return{x:i.x+l*Math.cos(h*Math.PI/180),y:i.y+l*Math.sin(h*Math.PI/180)}}function Zf(n,t,e){if(n&&n.children&&n.children.length>0)for(var r=void 0,s=0;s0&&"annotations"!==r&&"ports"!==r)if(n[""+l].length>0)for(var h=0;h<=n[""+l].length;h++)Ro(n[""+l],t?t[""+l]:void 0,e[""+l],"annotations"===l||"ports"===l?n:void 0,l);else Ro(n[""+l],t?t[""+l]:void 0,e[""+l],"annotations"===l||"ports"===l?n:void 0,l);else if(s instanceof Object&&t&&"annotations"!==r&&"ports"!==r)Ro(n[""+l],t[""+l],e[""+l]);else if("annotations"!==r&&"ports"!==r&&t&&!t[""+l]||!t&&n&&(n[""+l]||void 0!==n[""+l]))n[""+l]=e[""+l];else{var c=void 0;("annotations"===r||"ports"===r)&&("annotations"===r?(n[""+l]&&Ro(n[""+l],t[""+l],e[""+l]),n[""+l]||(ps(i)===de?(c=new Or(i,"annotations",e[""+l]),i.annotations.push(c)):(c=new Kn(i,"annotations",e[""+l]),i.annotations.push(c)))):n[""+l]?Ro(n[""+l],t[""+l],e[""+l]):(c=new Es(i,"ports",e[""+l]),i.ports.push(c)))}}}function cse(n,t){for(var e="Bezier"===n.type?function ase(n){var t=[];if("Bezier"===n.type)for(var e=0,i=0;i0||n.ports.length>0){var f=n.wrapper.children;for(i=3;i0)return{enabled:!1,intersectPt:e};var l=o/s,h=a/s;return l>=0&&l<=1&&h>=0&&h<=1?(e.x=i.x1+l*(i.x2-i.x1),e.y=i.y1+l*(i.y2-i.y1),{enabled:!0,intersectPt:e}):{enabled:!1,intersectPt:e}}function KI(n,t,e,i){var a=tm(cF(n.x,n.y,t.x,t.y),cF(e.x,e.y,i.x,i.y));return a.enabled?a.intersectPt:{x:0,y:0}}function cF(n,t,e,i){return{x1:Number(n)||0,y1:Number(t)||0,x2:Number(e)||0,y2:Number(i)||0}}function dF(n,t,e){var i=[],s={x:t.topRight.x+(e=e||0),y:t.topRight.y},o={x:t.bottomRight.x,y:t.bottomRight.y-e},a={x:t.bottomLeft.x,y:t.bottomLeft.y+e};return i.push({x:t.topLeft.x-e,y:t.topLeft.y}),i.push(s),i.push(o),i.push(a),i}function zc(n,t,e,i,r,s){var o={},a=e.scroller.transform.scale,h=e.scroller.verticalOffset;return o.x=(i?n.x:t.x)*a+e.scroller.horizontalOffset-r,o.y=(i?n.y:t.y)*a+h-s,o}function uF(n,t){var e=new Ze;return e.data=n.pathData,e.height=n.height>10?n.height-(n.padding.bottom+n.padding.top):n.height,e.width=n.width>10?n.width-(n.padding.left+n.padding.right):n.width,e.visible=n.visibility,e.id=t.id+"_shape",e.inversedAlignment=!1,e.horizontalAlignment="Center",e.verticalAlignment="Center",e.style={fill:n.iconStrokeColor,strokeColor:n.iconStrokeColor,strokeWidth:n.iconStrokeWidth},e.setOffsetWithRespectToBounds(.5,.5,"Fraction"),e.relativeMode="Object",e.description=t.description||"",e}function Xx(n,t,e){var i=qx(n,t),r=R.findAngle(n[i.index],n[i.index+1]),s=function mse(n){var t;t=n instanceof xI?0:void 0===n.content?10:0;var e=0;switch(n.alignment){case"Center":e=0;break;case"Before":e=-(0+t);break;case"After":e=0+t}return e}(t),o=R.transform(i.point,r+45,s);return i.point=o,i.angle=r,i}function qx(n,t){for(var r,s,a,l,e=0,i=t.offset,o=[],h=0;h=c)return s=R.findAngle(n[parseInt(d.toString(),10)],n[d+1]),{point:r=R.transform(n[parseInt(d.toString(),10)],s,c-(a||0)),index:l=d};a=o[parseInt(d.toString(),10)]}return{point:r,index:l}}function fF(n,t,e){t%=360;var a,l,s=225;switch(n.alignment){case"Before":t>=45&&t<=135?(l="right",a=.5===n.offset?"center":"top"):t>=s&&t<=315?(l="left",a=.5===n.offset?"center":"bottom"):t>45&&t=45&&t<=135?(l="left",a=.5===n.offset?"center":"top"):t>=s&&t<=315?(l="right",a=.5===n.offset?"center":"bottom"):t>45&&tMath.abs(t.y-n.y)?n.x0)for(var e=0;e=0;r--)("nodes"===i||"connectors"===i)&&(n[""+i][parseInt(r.toString(),10)].wrapper=null),"dataManager"!==i&&(n[""+i][parseInt(r.toString(),10)]=Jx(n[""+i][parseInt(r.toString(),10)],e[""+i][parseInt(r.toString(),10)],void 0!==t[""+i]?t[""+i][parseInt(r.toString(),10)]:[]),("[]"===JSON.stringify(n[""+i][parseInt(r.toString(),10)])||"{}"===JSON.stringify(n[""+i][parseInt(r.toString(),10)])||void 0===n[""+i][parseInt(r.toString(),10)])&&n[""+i].splice(r,1));n=void 0}function zh(n,t){var e=t.style,i=t;t.canApplyStyle=!0;for(var r=0,s=Object.keys(n);r=0&&n.splice(e,1)}function Jf(n,t,e){var i;n.intermediatePoints=t,n.updateSegmentElement(n,t,n.wrapper.children[0],e);var r=n.sourceDecorator;if("Bezier"===n.type){var s=n.segments[0],o=n.segments[n.segments.length-1];i=[R.isEmptyPoint(o.point2)?o.bezierPoint2:o.point2,R.isEmptyPoint(s.point1)?s.bezierPoint1:s.point1]}else i=n.intermediatePoints;t=n.clipDecorators(n,t,e);var a=n.wrapper.children[0];a.canMeasurePath=!0,n.updateDecoratorElement(a=n.wrapper.children[1],t[0],i[1],r),n.updateDecoratorElement(a=n.wrapper.children[2],t[t.length-1],i[i.length-2],n.targetDecorator),n.updateShapeElement(n)}function Kx(n,t,e){var l,i=n.wrapper,s=t.offset,o=t.size/e.scale,a=t.margin,h=i.offsetX-i.actualSize.width*i.pivot.x,c=i.offsetY-i.actualSize.height*i.pivot.y;if(l={x:0,y:0},n.nodes.length>0){switch(t.side){case"Top":l.x+=h+s*i.actualSize.width,l.y+=c-o;break;case"Bottom":l.x+=h+s*i.actualSize.width,l.y+=c+i.actualSize.height+o;break;case"Left":l.x+=h-o,l.y+=c+s*i.actualSize.height;break;case"Right":l.x+=h+i.actualSize.width+o,l.y+=c+s*i.actualSize.height}l.x+=(a.left-a.right)/e.scale+o/2*("Center"===t.horizontalAlignment?0:"Right"===t.horizontalAlignment?-1:1),l.y+=(a.top-a.bottom)/e.scale+o/2*("Center"===t.verticalAlignment?0:"Top"===t.verticalAlignment?-1:1)}else if(n.connectors.length>0){var d=n.connectors[0],u={offset:s},f=qx(d.intermediatePoints,u),p=f.index;l=f.point;var y,v=Xx(d.intermediatePoints,u).angle;qi(y=Bi(),-v,d.intermediatePoints[parseInt(p.toString(),10)].x,d.intermediatePoints[parseInt(p.toString(),10)].y),(l=Ke(y,l)).x+=a.left-a.right+o/2*("Center"===t.horizontalAlignment?0:"Right"===t.horizontalAlignment?-1:1),l.y+=a.top-a.bottom+o/2*("Center"===t.verticalAlignment?0:"Top"===t.verticalAlignment?-1:1),qi(y=Bi(),v,d.intermediatePoints[parseInt(p.toString(),10)].x,d.intermediatePoints[parseInt(p.toString(),10)].y),l=Ke(y,l)}return 0===i.rotateAngle&&0===i.parentTransform||(qi(y=Bi(),i.rotateAngle+i.parentTransform,i.offsetX,i.offsetY),l=Ke(y,l)),l}function ga(n,t,e,i){if(i.annotation){if(Pl(i.annotation))return!0}else if(mr[""+t]&n&&bt[""+t]&e)return!0;return!1}function qr(n,t){return!!(mr[""+t]&n)}function Hc(n,t){return!!(bx[""+t]&n)}function va(n,t){return n.visibility&t}function eb(n,t){var e;if("Text"===n.shape.type)e=n.shape;else{var i=t.split("_");t=i[i.length-1];for(var r=0;rn[""+t]?e.splice(0,0,n):e.push(n);else if(e.length>1){for(var i=0,r=e.length-1,s=Math.floor((i+r)/2);s!==i;)if(e[parseInt(s.toString(),10)][""+t]n[""+t]))break;r=s,s=Math.floor((i+r)/2)}e[parseInt(r.toString(),10)][""+t]n[""+t]?e.splice(i,0,n):e[parseInt(i.toString(),10)][""+t]n[""+t]&&e.splice(r,0,n)}}function zse(n){var t=document.getElementById(n.diagramId),e="ej2_instances",i=t[""+e][0].nodes;void 0===i&&(i=function Rse(n){for(var t=[],e=0;e30?10:o/2;for(var h=0,c=0;c=l){var u=l-h;r=Xt(n[c],n[c+1]),s=R.transform(n[c],r,u);break}h+=d}return s},rb=function(n,t){if(n instanceof te||n instanceof de)for(var e=0;e=0||navigator.platform.indexOf("iPad")>=0||navigator.platform.indexOf("iPhone")>=0||navigator.platform.indexOf("MacIntel")>=0)&&("safari"===X.info.name||"webkit"===X.info.name)}function wF(n,t,e,i){return void 0!==t.previewSize[""+i]?t.previewSize[""+i]:void 0!==n.symbolPreview[""+i]?n.symbolPreview[""+i]:t[""+i]||e.actualSize[""+i]}function om(n,t,e){return n&&n.parentId&&(e=(n=t.nameTable[n.parentId]).parentId?om(n,t,e):n.id),e}function am(n,t){return n.selectedItems.connectors.length>1&&0===n.selectedItems.nodes.length&&0!==t.rotateAngle}function _se(n){if(n.arrowType&&""!==n.arrowType.trim())switch(n.arrowType){case"single-line-arrow":default:return{targetDecorator:"Arrow",strokeWidth:1};case"double-line-arrow":return{targetDecorator:"Arrow",strokeWidth:2};case"dotted-arrow":return{targetDecorator:"Arrow",strokeDashArray:"2,2"};case"single-line":return{targetDecorator:"None",strokeWidth:1};case"double-line":return{targetDecorator:"None",strokeWidth:2};case"dotted":return{targetDecorator:"None",strokeDashArray:"2,2"};case"wiggly-arrow":return{targetDecorator:"None",strokeWidth:1,opacity:0}}return{targetDecorator:"Arrow",strokeWidth:1}}var Use=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),no=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},CF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Use(t,n),no([I("None")],t.prototype,"shape",void 0),no([I("white")],t.prototype,"fill",void 0),no([I("Auto")],t.prototype,"horizontalAlignment",void 0),no([I("Auto")],t.prototype,"verticalAlignment",void 0),no([I(10)],t.prototype,"width",void 0),no([I(10)],t.prototype,"height",void 0),no([re({x:.5,y:1},R)],t.prototype,"offset",void 0),no([I("#1a1a1a")],t.prototype,"borderColor",void 0),no([I(1)],t.prototype,"borderWidth",void 0),no([re({},Jn)],t.prototype,"margin",void 0),no([I("")],t.prototype,"pathData",void 0),no([I("")],t.prototype,"content",void 0),no([I(0)],t.prototype,"cornerRadius",void 0),no([re({left:2,right:2,top:2,bottom:2},Jn)],t.prototype,"padding",void 0),no([I("#1a1a1a")],t.prototype,"iconColor",void 0),t}(Ee),jse=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),rT=function(n){function t(){var e=null!==n&&n.apply(this,arguments)||this;return e.orientation="Vertical",e.measureChildren=void 0,e.considerPadding=!0,e}return jse(t,n),t.prototype.measure=function(e){return this.desiredSize=this.measureStackPanel(e,"Horizontal"===this.orientation?this.updateHorizontalStack:this.updateVerticalStack),this.desiredSize},t.prototype.arrange=function(e){return this.actualSize=this.arrangeStackPanel(e,"Horizontal"===this.orientation?this.arrangeHorizontalStack:this.arrangeVerticalStack),this.updateBounds(),this.actualSize},t.prototype.measureStackPanel=function(e,i){var r=void 0;if(void 0!==this.children&&this.children.length>0)for(var s=0,o=this.children;s0){var r=void 0,s=void 0;r=this.offsetX-e.width*this.pivot.x+this.padding.left,s=this.offsetY-e.height*this.pivot.y+this.padding.top;for(var o=0,a=this.children;o0)for(var i=0,r=this.children;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},$se=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return qse(t,n),Rh([I("Horizontal")],t.prototype,"orientation",void 0),Rh([I("Center")],t.prototype,"type",void 0),Rh([I(void 0)],t.prototype,"offset",void 0),Rh([I(!1)],t.prototype,"enableRouting",void 0),Rh([I([])],t.prototype,"children",void 0),Rh([I("")],t.prototype,"assistants",void 0),Rh([I("")],t.prototype,"level",void 0),Rh([I("")],t.prototype,"hasSubTree",void 0),Rh([I("")],t.prototype,"rows",void 0),t}(Ee),Ni=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),q=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Zse=function(n){if(n)switch(n.type){case"Basic":default:return nb;case"Flow":return TF;case"Path":return EF;case"Image":return xF;case"Text":return zd;case"Bpmn":return hT;case"Native":return lm;case"HTML":return DF;case"UmlActivity":return AF;case"UmlClassifier":return LF;case"SwimLane":return Bd}return nb},ma=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),q([I("Basic")],t.prototype,"type",void 0),t}(Ee),EF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"Path"},q([I("Path")],t.prototype,"type",void 0),q([I("")],t.prototype,"data",void 0),t}(ma),lm=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"Native"},q([I("Native")],t.prototype,"type",void 0),q([I("")],t.prototype,"content",void 0),q([I("Stretch")],t.prototype,"scale",void 0),t}(ma),DF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"Html"},q([I("HTML")],t.prototype,"type",void 0),q([I("")],t.prototype,"content",void 0),t}(ma),xF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"Image"},q([I("Image")],t.prototype,"type",void 0),q([I("")],t.prototype,"source",void 0),q([I("None")],t.prototype,"scale",void 0),q([I("None")],t.prototype,"align",void 0),t}(ma),zd=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"Text"},q([I("Text")],t.prototype,"type",void 0),q([I("")],t.prototype,"content",void 0),q([re({},Jn)],t.prototype,"margin",void 0),t}(ma),nb=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"BasicShape"},q([I("Basic")],t.prototype,"type",void 0),q([I("Rectangle")],t.prototype,"shape",void 0),q([I(0)],t.prototype,"cornerRadius",void 0),q([Bt([],R)],t.prototype,"points",void 0),t}(ma),TF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"FlowShape"},q([I("Flow")],t.prototype,"type",void 0),q([I("Terminator")],t.prototype,"shape",void 0),t}(ma),sT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"BpmnGateway"},q([I("None")],t.prototype,"type",void 0),t}(Ee),oT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"BpmnDataObject"},q([I("None")],t.prototype,"type",void 0),q([I(!1)],t.prototype,"collection",void 0),t}(Ee),Jse=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),q([I("None")],t.prototype,"type",void 0),q([I("None")],t.prototype,"loop",void 0),q([I(!1)],t.prototype,"call",void 0),q([I(!1)],t.prototype,"compensation",void 0),t}(Ee),aT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"BpmnEvent"},q([I("Start")],t.prototype,"event",void 0),q([I("None")],t.prototype,"trigger",void 0),t}(Ee),Rd=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"BpmnSubEvent"},q([I("None")],t.prototype,"trigger",void 0),q([I("Start")],t.prototype,"event",void 0),q([I("")],t.prototype,"id",void 0),q([re({},R)],t.prototype,"offset",void 0),q([Bt([],Kn)],t.prototype,"annotations",void 0),q([Bt([],Es)],t.prototype,"ports",void 0),q([I()],t.prototype,"width",void 0),q([I()],t.prototype,"height",void 0),q([re({},Jn)],t.prototype,"margin",void 0),q([I("Center")],t.prototype,"horizontalAlignment",void 0),q([I("Center")],t.prototype,"verticalAlignment",void 0),q([I(!0)],t.prototype,"visible",void 0),t}(Ee),Kse=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),q([re({id:"success",event:"End",offset:{x:1,y:.5}},Rd)],t.prototype,"success",void 0),q([re({id:"failure",event:"Intermediate",trigger:"Error",offset:{x:.25,y:1}},Rd)],t.prototype,"failure",void 0),q([re({id:"cancel",event:"Intermediate",trigger:"Cancel",offset:{x:.75,y:1}},Rd)],t.prototype,"cancel",void 0),t}(Ee),eoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),q([I("None")],t.prototype,"type",void 0),q([I(!1)],t.prototype,"adhoc",void 0),q([I("Default")],t.prototype,"boundary",void 0),q([I(!1)],t.prototype,"compensation",void 0),q([I("None")],t.prototype,"loop",void 0),q([I(!0)],t.prototype,"collapsed",void 0),q([Bt([],Rd)],t.prototype,"events",void 0),q([re({},Kse)],t.prototype,"transaction",void 0),q([I(void 0)],t.prototype,"processes",void 0),t}(Ee),lT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"BpmnActivity"},q([I("Task")],t.prototype,"activity",void 0),q([re({},Jse)],t.prototype,"task",void 0),q([re({},eoe)],t.prototype,"subProcess",void 0),t}(Ee),hm=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return Ni(t,n),t.prototype.getClassName=function(){return"BpmnAnnotation"},q([I("")],t.prototype,"text",void 0),q([I("")],t.prototype,"id",void 0),q([I(0)],t.prototype,"angle",void 0),q([I()],t.prototype,"height",void 0),q([I()],t.prototype,"width",void 0),q([I(0)],t.prototype,"length",void 0),t}(Ee),toe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),q([I("")],t.prototype,"textAnnotationTarget",void 0),q([I("Auto")],t.prototype,"textAnnotationDirection",void 0),t}(Ee),hT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"BpmnShape"},q([I("Bpmn")],t.prototype,"type",void 0),q([I("Event")],t.prototype,"shape",void 0),q([re({},aT)],t.prototype,"event",void 0),q([re({},sT)],t.prototype,"gateway",void 0),q([re({},oT)],t.prototype,"dataObject",void 0),q([re({},lT)],t.prototype,"activity",void 0),q([re({},hm)],t.prototype,"annotation",void 0),q([Bt([],hm)],t.prototype,"annotations",void 0),q([re({},toe)],t.prototype,"textAnnotation",void 0),t}(ma),AF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"UmlActivityShape"},q([I("UmlActivity")],t.prototype,"type",void 0),q([I("Action")],t.prototype,"shape",void 0),t}(ma),cT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"MethodArguments"},q([I("")],t.prototype,"name",void 0),q([I("")],t.prototype,"type",void 0),q([re({},Qf)],t.prototype,"style",void 0),t}(Ee),rp=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"UmlClassAttribute"},q([I("Public")],t.prototype,"scope",void 0),q([I(!1)],t.prototype,"isSeparator",void 0),q([re({fill:"#F9F9F9",strokeColor:"#CCCCCC"},Ll)],t.prototype,"separatorStyle",void 0),t}(cT),cm=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"UmlClassMethod"},q([Bt([],cT)],t.prototype,"parameters",void 0),t}(rp),sb=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"UmlClass"},q([I("")],t.prototype,"name",void 0),q([Bt([],rp)],t.prototype,"attributes",void 0),q([Bt([],cm)],t.prototype,"methods",void 0),q([re({},Qf)],t.prototype,"style",void 0),t}(Ee),dT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"UmlInterface"},q([I(!1)],t.prototype,"isSeparator",void 0),q([re({fill:"#F9F9F9",strokeColor:"#CCCCCC"},Ll)],t.prototype,"separatorStyle",void 0),t}(sb),ob=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"UmlEnumerationMember"},q([I("")],t.prototype,"name",void 0),q([I("")],t.prototype,"value",void 0),q([I(!1)],t.prototype,"isSeparator",void 0),q([re({fill:"#F9F9F9",strokeColor:"#CCCCCC"},Ll)],t.prototype,"separatorStyle",void 0),q([re({},Qf)],t.prototype,"style",void 0),t}(Ee),uT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"UmlEnumeration"},q([I("")],t.prototype,"name",void 0),q([Bt([],ob)],t.prototype,"members",void 0),q([re({},Qf)],t.prototype,"style",void 0),t}(Ee),LF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"UmlClassifierShape"},q([I("UmlClassifier")],t.prototype,"type",void 0),q([re({},sb)],t.prototype,"classShape",void 0),q([re({},dT)],t.prototype,"interfaceShape",void 0),q([re({},uT)],t.prototype,"enumerationShape",void 0),q([I("Class")],t.prototype,"classifier",void 0),t}(ma),te=function(n){function t(e,i,r,s){var a,o=n.call(this,e,i,r,s)||this;return o.isCanvasUpdate=!1,o.status="None",o.parentId="",o.processId="",o.umlIndex=-1,o.outEdges=[],o.inEdges=[],o.isHeader=!1,o.isLane=!1,o.isPhase=!1,o.children&&o.children.length>0&&((!(a=r).style||!a.style.fill)&&(o.style.fill="transparent"),(!a.style||!a.style.strokeColor)&&(o.style.strokeColor="transparent")),o.shape&&"UmlActivity"===o.shape.type&&JI(r,o),o.shape&&"SwimLane"===o.shape.type&&aF(r,o),o.ports&&o.ports.length&&function sse(n){for(var t=0;t>";t=n;break;case"FinalNode":t=pF(e)}return t}(new Ze,i,this);break;case"Bpmn":if(e.bpmnModule){i=e.bpmnModule.initBPMNContent(i,this,e),this.wrapper.elementActions=this.wrapper.elementActions|Xr.ElementIsGroup;var v=this.shape.activity.subProcess;if(v.processes&&v.processes.length)for(var S=0,b=this.shape.activity.subProcess.processes;S>",margin:{left:10,right:10},id:"class",style:{fontSize:i.style.fontSize,color:i.style.color,fill:i.style.fill,textWrapping:r},offset:{x:.5,y:.3},constraints:Nr.ReadOnly}],constraints:(ie.Default|ie.HideThumbs)&~(ie.Rotate|ie.Drag|ie.Resize),verticalAlignment:"Stretch",horizontalAlignment:"Stretch",style:{fill:t.style.fill,strokeColor:"black"===t.style.strokeColor?"#ffffff00":t.style.strokeColor}},!0);return e.initObject(s),e.nodes.push(s),e.UpdateBlazorDiagramModel(s,"Node"),t.children.push(s.id),function Wse(n,t,e,i){if("Enumeration"===n.shape.classifier){var r=e.members;if(r&&r.length){tp(n,t);for(var s="",o=0;o0)for(var o=0;o0&&s.phaseSize&&(i+=s.phaseSize,Gv(n,s.phaseSize)),s.lanes.length>0)for(o=0;o0){var a=0;for(o=0;o0&&"Horizontal"===r.orientation)for(l=0;l0&&(i+=r.phaseSize,o=Xv(r.phaseSize),n.push(o)),a=0;a0&&o.phaseSize){for(var l=0;l0)for(l=0;l0?e.nameTable[this.nodes[0].id].wrapper:e.nameTable[this.connectors[0].id].wrapper,this.annotation.id);i.children.push(s)}else if(this.nodes||this.connectors){for(var o=0;o-1}function HF(n,t,e){n=[];for(var i=0,r=e.length;i0?c.getElementsByTagName("svg")[0].outerHTML:c.getElementsByTagName("g").length>0?c.getElementsByTagName("g")[0].outerHTML:"",s.shape.content=h,n.content=h,c.parentElement.removeChild(c)}l="nodeTemplate"}else a=s,l="annotationTemplate";var p=document.getElementById(n.diagramId).ej2_instances[0];if("string"!=typeof n.content&&"function"!=typeof n.content||n.isTemplate)if(n.isTemplate){if(v=void 0,v=p.isReact?n.getNodeTemplate()($(e),p,l+"_"+("nodeTemplate"===l?e.id:n.nodeId+e.id),void 0,void 0,!1,i):p.isVue||p.isVue3?n.getNodeTemplate()?n.getNodeTemplate()($(e),p,l+"_"+("nodeTemplate"===l?e.id:n.nodeId+e.id),void 0,void 0,!1,i):(v=oi("nodeTemplate"===l?p.nodeTemplate:p.annotationTemplate))($(e),p,l+"_"+("nodeTemplate"===l?e.id:n.nodeId+e.id),void 0,void 0,!1,i):n.getNodeTemplate()($(e),p,l+"_"+("nodeTemplate"===l?e.id:n.nodeId+e.id),void 0,void 0,!1))for(var M=0;M=1&&0===n.x&&("Clip"===i.textOverflow||"Ellipsis"===i.textOverflow)&&("Wrap"===i.textWrapping||"WrapWithOverflow"===i.textWrapping)&&(n.x=t[e-1]?t[e-1].x:-n.width/2),n.x}function _F(n,t,e,i){return e&&!t.template||t.template&&"function"==typeof t.template&&i.isReact?(n.isTemplate=!0,n.template=n.content=Hh(n,!0,t)):n.content=t.template,n}function Qe(){for(var e,t="",i=0;i<5;i++){if(typeof window<"u"&&"crypto"in window&&"getRandomValues"in crypto){var r=new Uint16Array(1);e=(window.msCrypto||window.crypto).getRandomValues(r)[0]%60}else e=Math.floor(61*Math.random());0===i&&e<10?i--:t+="0123456789ABCDEFGHIJKLMNOPQRSTUVWXTZabcdefghiklmnopqrstuvwxyz".substring(e,e+1)}return t}function UF(n){if(n)try{return"function"!=typeof n&&document.querySelectorAll(n).length?oi(document.querySelector(n).innerHTML.trim()):oi(n)}catch{return oi(n)}}function xn(n){new Ne;var e=n.offsetY-n.actualSize.height*n.pivot.y,i=n.offsetY+n.actualSize.height*(1-n.pivot.y),r=n.offsetX-n.actualSize.width*n.pivot.x,s=n.offsetX+n.actualSize.width*(1-n.pivot.x);return Ne.toBounds([{x:r,y:e},{x:s,y:e},{x:r,y:i},{x:s,y:i}])}function yr(n){var t=new Ne,e=xn(n),i=e.middleLeft,r=e.topCenter,s=e.bottomCenter,o=e.middleRight,a=e.topLeft,l=e.topRight,h=e.bottomLeft,c=e.bottomRight;if(n.corners={topLeft:a,topCenter:r,topRight:l,middleLeft:i,middleRight:o,bottomLeft:h,bottomCenter:s,bottomRight:c},0!==n.rotateAngle||0!==n.parentTransform){var d=Bi();qi(d,n.rotateAngle+n.parentTransform,n.offsetX,n.offsetY),n.corners.topLeft=a=Ke(d,a),n.corners.topCenter=r=Ke(d,r),n.corners.topRight=l=Ke(d,l),n.corners.middleLeft=i=Ke(d,i),n.corners.middleRight=o=Ke(d,o),n.corners.bottomLeft=h=Ke(d,h),n.corners.bottomCenter=s=Ke(d,s),n.corners.bottomRight=c=Ke(d,c)}return t=Ne.toBounds([a,l,h,c]),n.corners.left=t.left,n.corners.right=t.right,n.corners.top=t.top,n.corners.bottom=t.bottom,n.corners.center=t.center,n.corners.width=t.width,n.corners.height=t.height,t}function $(n,t,e,i){var r={},s="properties";if(n){e=n.propName;var l=[],h=[];if((l=l.concat(Object.keys(n[""+s]||n))).push("version"),e){var c=Zi(t);h=c?c(e):[],l=l.concat(h)}for(var d=function boe(n){switch(n){case"nodes":case"children":return["inEdges","outEdges","parentId","processId","nodeId","umlIndex","isPhase","isLane"];case"connectors":return["parentId"];case"annotation":case"annotations":return["nodeId"];case"shape":return["hasHeader"];case"layers":return["objectZIndex"]}return[]}(e),u=0,f=l=l.concat(d);u0&&(e=r),r=Math.floor(woe(e,i)),s=Bc(o+=n.substr(e,r),t)}while(s<=t.width);for(o=o.substr(0,e),a=e;a=t.width){n=n.substr(0,o.length-1);break}return"Ellipsis"===t.textOverflow?(n=n.substr(0,n.length-3),n+="..."):n=n.substr(0,n.length),n}function ST(n,t){if("NoWrap"===t&&"PreserveAll"===n)return"pre";var e="";switch(n){case"CollapseAll":e="nowrap";break;case"CollapseSpace":e="pre-line";break;case"PreserveAll":e="pre-wrap"}return e}function IT(n,t){var e=Bi();qi(e,t,0,0);var i=Ke(e,{x:0,y:0}),r=Ke(e,{x:n.width,y:0}),s=Ke(e,{x:0,y:n.height}),o=Ke(e,{x:n.width,y:n.height}),a=Math.min(i.x,r.x,s.x,o.x),l=Math.min(i.y,r.y,s.y,o.y),h=Math.max(i.x,r.x,s.x,o.x),c=Math.max(i.y,r.y,s.y,o.y);return new me(h-a,c-l)}function xs(n,t,e,i){if(0!==n){var r=Bi();return qi(r,n,t,e),Ke(r,i)}return i}function Zi(n){return void 0!==n&&"string"==typeof n&&(n=Y(n,window)),n}var bo=function(){function n(){}return n.getContext=function(t){return t.getContext("2d")},n.setCanvasSize=function(t,e,i){t&&(t.setAttribute("width",e.toString()),t.setAttribute("height",i.toString()))},n.prototype.renderGradient=function(t,e,i,r){var s,o,a;if("None"!==t.gradient.type){for(var l=0;l0?(w=0===S.r1?e.arc[parseInt(r.toString(),10)].r1:S.r1,C=0===S.r2?e.arc[parseInt(r.toString(),10)].r2:S.r2,r++):(w=S.r1,C=S.r2);var D=S.angle*(Math.PI/180),A=S.largeArc,x=S.sweep,P={x:u,y:f},L={x:Math.cos(D)*(M.x-P.x)/2+Math.sin(D)*(M.y-P.y)/2,y:-Math.sin(D)*(M.x-P.x)/2+Math.cos(D)*(M.y-P.y)/2},O=Math.pow(L.x,2)/Math.pow(w,2)+Math.pow(L.y,2)/Math.pow(C,2);O>1&&(w*=Math.sqrt(O),C*=Math.sqrt(O));var N=Math.pow(C,2)*Math.pow(L.x,2),T=(A===x?-1:1)*Math.sqrt((Math.pow(w,2)*Math.pow(C,2)-Math.pow(w,2)*Math.pow(L.y,2)-N)/(Math.pow(w,2)*Math.pow(L.y,2)+Math.pow(C,2)*Math.pow(L.x,2)));isNaN(T)&&(T=0);var z={x:T*w*L.y/C,y:T*-C*L.x/w},U={x:(M.x+P.x)/2+Math.cos(D)*z.x-Math.sin(D)*z.y,y:(M.y+P.y)/2+Math.sin(D)*z.x+Math.cos(D)*z.y},B=this.a([1,0],[(L.x-z.x)/w,(L.y-z.y)/C]),j=[(L.x-z.x)/w,(L.y-z.y)/C],Q=[(-L.x-z.x)/w,(-L.y-z.y)/C],oe=this.a(j,Q);this.r(j,Q)<=-1&&(oe=Math.PI),this.r(j,Q)>=1&&(oe=0);var fe=B+oe/2*(x?1:-1);if(Math.cos(fe),Math.sin(fe),S.centp=U,S.xAxisRotation=D,S.rx=w,S.ry=C,S.a1=B,S.ad=oe,S.sweep=x,null!=s){var De=w>C?w:C,xe=w>C?1:w/C,Ie=w>C?C/w:1;s.save(),s.translate(U.x,U.y),s.rotate(D),s.scale(xe,Ie),s.arc(0,0,De,B,B+oe,!x),s.scale(1/xe,1/Ie),s.rotate(-D),s.translate(-U.x,-U.y),s.restore()}break;case"Z":case"z":s.closePath(),u=o,f=a}o=u,a=f}}},n.prototype.drawText=function(t,e,i,r,s,o,a){if(e.content&&!0===e.visible){var l=n.getContext(t);l.save(),this.setStyle(t,e),o&&(e.fontSize*=o),this.applyFlipAndRotate(l,e,t,e.x+e.width*e.pivotX,e.y+e.height*e.pivotY),this.setFontStyle(t,e);var u,d=0;u=e.childNodes;var f=e.wrapBounds;if(l.fillStyle=e.color,f){var p=this.labelAlign(e,f,u);for(d=0;de.width&&"Wrap"!==e.textOverflow&&"NoWrap"===e.textWrapping&&(g.text=VF(g.text,e)),"Clip"!==e.textOverflow&&"Ellipsis"!==e.textOverflow||"Wrap"!==e.textWrapping?l.fillText(g.text,v,y):ya.actualSize.height+a.bounds.y&&(g.text=g.text.slice(0,g.text.length-3),g.text=g.text.concat("...")),l.fillText(g.text,v,y)),"Underline"===e.textDecoration||"Overline"===e.textDecoration||"LineThrough"===e.textDecoration){var M=v,w=void 0,D=v+l.measureText(g.text).width,A=void 0;switch(e.textDecoration){case"Underline":w=y+2,A=y+2;break;case"Overline":w=p.y+g.dy*d,A=p.y+g.dy*d;break;case"LineThrough":w=(y+p.y+g.dy*d)/2+2,A=(y+p.y+g.dy*d)/2+2}l.beginPath(),l.moveTo(M,w),l.lineTo(D,A),l.strokeStyle=e.color,l.lineWidth=.08*e.fontSize,l.globalAlpha=e.opacity,l.stroke()}}}l.restore()}},n.prototype.applyFlipAndRotate=function(t,e,i,r,s){"Horizontal"===e.flip||"Vertical"===e.flip?(t.translate(e.x+e.width/2,e.y+e.height/2),t.rotate(-e.angle*Math.PI/180),t.translate(-e.x-e.width/2,-e.y-e.height/2)):this.rotateContext(i,e.angle,r,s),t.translate(e.x,e.y),"Horizontal"===e.flip?(t.scale(-1,1),t.translate(-1*e.width,0)):"Vertical"===e.flip?(t.scale(1,-1),t.translate(0,-1*e.height)):"Both"===e.flip&&(t.scale(-1,-1),t.translate(-1*e.width,-1*e.height)),t.translate(-e.x,-e.y)},n.prototype.loadImage=function(t,e,i,r,s){var o=new Image;o.src=e.source,this.image(t,o,e.x,e.y,e.width,e.height,e)},n.prototype.drawImage=function(t,e,i,r){var s=this;if(e.visible){var o=n.getContext(t);o.save();var a=e.x+e.width*e.pivotX,l=e.y+e.height*e.pivotY,h=new Image;h.src=e.source,this.setStyle(t,e),o.canvas.id.split("_"),this.applyFlipAndRotate(o,e,t,a,l),r?h.onload=function(){s.loadImage(o,e,t,a,l)}:this.loadImage(o,e,t,a,l),o.restore()}},n.prototype.image=function(t,e,i,r,s,o,a){t.beginPath();var l=e.width,h=e.height,c=s,d=o,u=0,f=0;if(a&&"None"!==a.alignment){var p=a.alignment.toLowerCase().substr(1,3),g=a.alignment.toLowerCase().substr(5,3);if("Slice"===a.scale){var v=function(){u=c,f=h*c/l},y=function(){u=l*d/h,f=d};c>d?(v(),d>f&&y()):c===d?l>h?y():v():(y(),c>u&&v());var S=this.getSliceOffset(p,u,c,l),b=this.getSliceOffset(g,f,d,h),M=l-S,w=h-b,C=u-S*(u/l),D=f-b*(f/h),A=Tt("canvas",{width:s.toString(),height:o.toString()});A.getContext("2d").drawImage(e,S,b,M,w,0,0,C,D),t.drawImage(A,i,r,s,o)}else if("Meet"===a.scale){var P=h/l,L=d/c;f=L>P?c*P:d,i+=this.getMeetOffset(p,u=L>P?c:d/P,c),r+=this.getMeetOffset(g,f,d),t.drawImage(e,0,0,l,h,i,r,u,f)}else t.drawImage(e,i,r,s,o)}else if("None"!==a.flip){var O=1,N=1;("Horizontal"===a.flip||"Both"===a.flip)&&(i=-i,s=-s,O=-1),("Vertical"===a.flip||"Both"===a.flip)&&(r=-r,o=-o,N=-1),t.scale(O,N),t.drawImage(e,i,r,s,o)}else t.drawImage(e,i,r,s,o);t.closePath()},n.prototype.getSliceOffset=function(t,e,i,r){switch(t){case"min":default:return 0;case"mid":return(e-i)/2*r/e;case"max":return(e-i)*r/e}},n.prototype.getMeetOffset=function(t,e,i){var r=Math.max(e,i),s=Math.min(e,i);switch(t){case"min":default:return 0;case"mid":return(r-s)/2;case"max":return r-s}},n.prototype.m=function(t){return Math.sqrt(Math.pow(t[0],2)+Math.pow(t[1],2))},n.prototype.r=function(t,e){return(t[0]*e[0]+t[1]*e[1])/(this.m(t)*this.m(e))},n.prototype.a=function(t,e){return(t[0]*e[1]t.width&&("Ellipsis"===t.textOverflow||"Clip"===t.textOverflow)&&"NoWrap"===t.textWrapping?0:.5*t.width:"right"===t.textAlign&&(c=1*t.width),s.x=t.x+c+(e?e.x:0),s.y=a+d-r.height/2,s},n}(),db=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Vi=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Eoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return db(t,n),Vi([I("")],t.prototype,"source",void 0),Vi([I("transparent")],t.prototype,"color",void 0),Vi([I("None")],t.prototype,"scale",void 0),Vi([I("None")],t.prototype,"align",void 0),t}(Ee),Doe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return db(t,n),Vi([I("Page")],t.prototype,"mode",void 0),Vi([I("PageSettings")],t.prototype,"region",void 0),Vi([re({top:25,bottom:25,left:25,right:25},Jn)],t.prototype,"margin",void 0),Vi([I(!1)],t.prototype,"canZoomIn",void 0),Vi([I(void 0)],t.prototype,"customBounds",void 0),Vi([I(!1)],t.prototype,"canFit",void 0),t}(Ee),xoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return db(t,n),Vi([I(null)],t.prototype,"width",void 0),Vi([I(null)],t.prototype,"height",void 0),Vi([re({},Jn)],t.prototype,"margin",void 0),Vi([I("Landscape")],t.prototype,"orientation",void 0),Vi([I("Infinity")],t.prototype,"boundaryConstraints",void 0),Vi([re({},Eoe)],t.prototype,"background",void 0),Vi([I(!1)],t.prototype,"multiplePage",void 0),Vi([I(!1)],t.prototype,"showPageBreaks",void 0),Vi([re({},Doe)],t.prototype,"fitOptions",void 0),t}(Ee),Toe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return db(t,n),Vi([I(0)],t.prototype,"horizontalOffset",void 0),Vi([I(0)],t.prototype,"verticalOffset",void 0),Vi([I(1)],t.prototype,"currentZoom",void 0),Vi([I(0)],t.prototype,"viewPortWidth",void 0),Vi([I(0)],t.prototype,"viewPortHeight",void 0),Vi([I(.2)],t.prototype,"minZoom",void 0),Vi([I(30)],t.prototype,"maxZoom",void 0),Vi([I("Diagram")],t.prototype,"scrollLimit",void 0),Vi([I()],t.prototype,"scrollableArea",void 0),Vi([I(!1)],t.prototype,"canAutoScroll",void 0),Vi([I(100)],t.prototype,"autoScrollFrequency",void 0),Vi([re({left:15,right:15,top:15,bottom:15},Jn)],t.prototype,"autoScrollBorder",void 0),Vi([re({left:0,right:0,top:0,bottom:0},Jn)],t.prototype,"padding",void 0),Vi([I(.2)],t.prototype,"zoomFactor",void 0),t}(Ee),Aoe=function(){function n(){this.services={}}return n.prototype.register=function(t,e){this.services[""+t]=e},n.prototype.getService=function(t){return this.services[""+t]},n}(),WF=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),ya=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},YF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return WF(t,n),ya([I("lightgray")],t.prototype,"lineColor",void 0),ya([I("")],t.prototype,"lineDashArray",void 0),ya([I([1.25,18.75,.25,19.75,.25,19.75,.25,19.75,.25,19.75])],t.prototype,"lineIntervals",void 0),ya([I([1,19,.5,19.5,.5,19.5,.5,19.5,.5,19.5])],t.prototype,"dotIntervals",void 0),ya([I([20])],t.prototype,"snapIntervals",void 0),t}(Ee),Loe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return WF(t,n),ya([re({},YF)],t.prototype,"horizontalGridlines",void 0),ya([re({},YF)],t.prototype,"verticalGridlines",void 0),ya([I(ei.All)],t.prototype,"constraints",void 0),ya([I(5)],t.prototype,"snapAngle",void 0),ya([I("Lines")],t.prototype,"gridType",void 0),ya([I(5)],t.prototype,"snapObjectDistance",void 0),ya([I("#07EDE1")],t.prototype,"snapLineColor",void 0),t}(Ee),QF=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),el=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},GF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return QF(t,n),el([I(5)],t.prototype,"interval",void 0),el([I(100)],t.prototype,"segmentWidth",void 0),el([I("Horizontal")],t.prototype,"orientation",void 0),el([I("RightOrBottom")],t.prototype,"tickAlignment",void 0),el([I("red")],t.prototype,"markerColor",void 0),el([I(25)],t.prototype,"thickness",void 0),el([I(null)],t.prototype,"arrangeTick",void 0),t}(Ee),Noe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return QF(t,n),el([I(!1)],t.prototype,"showRulers",void 0),el([I(!0)],t.prototype,"dynamicGrid",void 0),el([re({orientation:"Horizontal"},GF)],t.prototype,"horizontalRuler",void 0),el([re({orientation:"Vertical"},GF)],t.prototype,"verticalRuler",void 0),t}(Ee),Ooe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),XF=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},koe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ooe(t,n),XF([I("")],t.prototype,"property",void 0),XF([I("")],t.prototype,"field",void 0),t}(Ee),bT=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),ln=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},qF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return bT(t,n),ln([I("")],t.prototype,"read",void 0),ln([I("")],t.prototype,"create",void 0),ln([I("")],t.prototype,"update",void 0),ln([I("")],t.prototype,"destroy",void 0),ln([I()],t.prototype,"customFields",void 0),t}(Ee),Poe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return bT(t,n),ln([I("")],t.prototype,"id",void 0),ln([I("")],t.prototype,"sourceID",void 0),ln([I("")],t.prototype,"targetID",void 0),ln([I(null)],t.prototype,"sourcePointX",void 0),ln([I(null)],t.prototype,"sourcePointY",void 0),ln([I(null)],t.prototype,"targetPointX",void 0),ln([I(null)],t.prototype,"targetPointY",void 0),ln([I(null)],t.prototype,"dataManager",void 0),ln([re({},qF)],t.prototype,"crudAction",void 0),t}(Ee),zoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return bT(t,n),ln([I("")],t.prototype,"id",void 0),ln([I(null)],t.prototype,"dataManager",void 0),ln([I(null)],t.prototype,"dataSource",void 0),ln([I("")],t.prototype,"root",void 0),ln([I("")],t.prototype,"parentId",void 0),ln([I()],t.prototype,"doBinding",void 0),ln([Bt([],koe)],t.prototype,"dataMapSettings",void 0),ln([re({},qF)],t.prototype,"crudAction",void 0),ln([re({},Poe)],t.prototype,"connectionDataSource",void 0),t}(Ee),$F=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Cr=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Roe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return $F(t,n),Cr([I("LeftInFlow")],t.prototype,"yesBranchDirection",void 0),Cr([I("RightInFlow")],t.prototype,"noBranchDirection",void 0),Cr([I(["Yes","True"])],t.prototype,"yesBranchValues",void 0),Cr([I(["No","False"])],t.prototype,"noBranchValues",void 0),t}(Ee),Hoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return $F(t,n),Cr([I("")],t.prototype,"fixedNode",void 0),Cr([I(30)],t.prototype,"horizontalSpacing",void 0),Cr([I("SamePoint")],t.prototype,"connectionPointOrigin",void 0),Cr([I("Nonlinear")],t.prototype,"arrangement",void 0),Cr([I(30)],t.prototype,"verticalSpacing",void 0),Cr([I(30)],t.prototype,"maxIteration",void 0),Cr([I(40)],t.prototype,"springFactor",void 0),Cr([I(50)],t.prototype,"springLength",void 0),Cr([re({left:50,top:50,right:0,bottom:0},Jn)],t.prototype,"margin",void 0),Cr([I("Auto")],t.prototype,"horizontalAlignment",void 0),Cr([I("Auto")],t.prototype,"verticalAlignment",void 0),Cr([I("TopToBottom")],t.prototype,"orientation",void 0),Cr([I("Auto")],t.prototype,"connectionDirection",void 0),Cr([I("Default")],t.prototype,"connectorSegments",void 0),Cr([I("None")],t.prototype,"type",void 0),Cr([I()],t.prototype,"getLayoutInfo",void 0),Cr([I()],t.prototype,"layoutInfo",void 0),Cr([I()],t.prototype,"getBranch",void 0),Cr([I()],t.prototype,"bounds",void 0),Cr([I(!0)],t.prototype,"enableAnimation",void 0),Cr([I(!1)],t.prototype,"enableRouting",void 0),Cr([I("")],t.prototype,"root",void 0),Cr([re({},Roe)],t.prototype,"flowchartLayoutSettings",void 0),t}(Ee),Boe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),ZF=function(n){function t(e,i){var r=n.call(this,e,!0)||this;return r.oldValue=null,r.endPoint=i,r}return Boe(t,n),t.prototype.mouseDown=function(e){var i,r=!0;if(e.source&&e.source.connectors&&(i=e.source.connectors[0]),e.info&&e.actualObject&&(r=e.info.ctrlKey&&"Orthogonal"!==e.actualObject.type),i&&r){this.inAction=!0,this.undoElement=$(e.source),n.prototype.mouseDown.call(this,e);for(var s=0;s0)1!==s&&this.removePrevSegment(i,s);else if(a){var l=R.distancePoints(a.points[0],a.points[1]);Math.abs(a.length||0===a.length?a.length:l)<=5&&this.removeNextSegment(i,s)}this.commandHandler.updateEndPoint(i,r),i.selectedSegmentIndex=0}if(this.undoElement){var c=$(e.source);this.commandHandler.addHistoryEntry({type:"SegmentChanged",redoObject:c,undoObject:this.undoElement,category:"Internal"})}if(i.isBezierEditing&&(i.isBezierEditing=!1),this.prevPosition!==this.startPosition){var u={source:i,state:"Completed",oldValue:this.oldValue,newValue:$(this.selectedSegment),cancel:!1,segment:this.selectedSegment};this.commandHandler.triggerEvent(Ce.segmentChange,u)}n.prototype.mouseUp.call(this,e)},t.prototype.removePrevSegment=function(e,i){var r=e.segments[i-2],s=e.segments[i+1];if(s&&!((s.length||0===s.length?s.length:R.distancePoints(s.points[0],s.points[1]))<=5)){var a=e.segments.slice(i-1,i+1),l={element:e,removeSegments:a,type:"Removal",cancel:!1};if(this.commandHandler.triggerEvent(Ce.segmentCollectionChange,l),!l.cancel){var h=e.segments[i+1];e.segments.splice(i-1,2);var c=this.selectedSegment;"Left"===c.direction||"Right"===c.direction?(r.points[r.points.length-1].x=h.points[0].x,h.points[0].y=r.points[r.points.length-1].y):(r.points[r.points.length-1].y=h.points[0].y,h.points[0].x=r.points[r.points.length-1].x),(c.length||0===c.length)&&this.findSegmentDirection(r),this.findSegmentDirection(h)}}},t.prototype.findSegmentDirection=function(e){e.direction&&(e.length||0===e.length)&&(e.length=R.distancePoints(e.points[0],e.points[e.points.length-1]),e.direction=R.direction(e.points[0],e.points[e.points.length-1]))},t.prototype.removeNextSegment=function(e,i){var l,h,r=this.selectedSegment,s=e.segments[i-1],o=e.segments[i+2],a=e.segments[i+1];if(a.length||0===a.length?(l=e.segments.slice(i,2),h={element:e,removeSegments:l,type:"Removal",cancel:!1},this.commandHandler.triggerEvent(Ce.segmentCollectionChange,h={element:e,removeSegments:l,type:"Removal",cancel:!1}),h.cancel||(e.segments.splice(i,2),"Top"===r.direction||"Bottom"===r.direction?(o.points[0].y=r.points[0].y,s.points[s.points.length-1].x=o.points[0].x):(o.points[0].x=r.points[0].x,s.points[s.points.length-1].y=o.points[0].y))):(l=e.segments.slice(i+1,1),this.commandHandler.triggerEvent(Ce.segmentCollectionChange,h={element:e,removeSegments:l,type:"Removal",cancel:!1}),h.cancel||(e.segments.splice(i+1,1),"Top"===r.direction||"Bottom"===r.direction?s.points[s.points.length-1].x=a.points[a.points.length-1].x:s.points[s.points.length-1].y=a.points[a.points.length-1].y,this.findSegmentDirection(s),r.length=r.direction=null)),s&&o&&!h.cancel&&(s.length=R.distancePoints(s.points[0],o.points[0]),s.direction=R.direction(s.points[0],o.points[0]),o.length||0===o.length)){o.length=R.distancePoints(s.points[s.points.length-1],o.points[o.points.length-1]);var c=s.points,d=o.points;o.direction=R.direction(c[c.length-1],d[d.length-1])}},t.prototype.addOrRemoveSegment=function(e,i,r){for(var s,o,a=[],l={segments:e.segments},h=0;h0?"Bottom":"Top":r>0?"Right":"Left",length:i.points[0].x===i.points[1].x?s:r},!0)),l.push(new wi(e,"segments",{type:"Orthogonal",direction:c,length:h/2},!0));var f={element:e,addSegments:l,type:"Addition",cancel:!1};return this.commandHandler.triggerEvent(Ce.segmentCollectionChange,f),f.cancel||(e.segments=l.concat(e.segments),a=o+2),a},t.prototype.insertFirstSegment=function(e,i,r,s,o){var a,l,d,u,h=[];if(e.sourcePortID&&i.length&&e.segments[0].points.length>2)for(var f=void 0,p=0;p0?"Bottom":"Top":r>0?"Right":"Left"),f=u,h.push(u)}else h.push(new wi(e,"segments",{type:"Orthogonal",direction:i.direction,length:i.length/3},!0)),"Bottom"===i.direction||"Top"===i.direction?(l=Math.abs(r),a=r>0?"Right":"Left"):(l=Math.abs(s),a=s>0?"Bottom":"Top"),u=new wi(e,"segments",{type:"Orthogonal",direction:a,length:l},!0),h.push(u);var y={element:e,addSegments:h,type:"Addition",cancel:!1};if(this.commandHandler.triggerEvent(Ce.segmentCollectionChange,y),!y.cancel){if(e.sourcePortID&&i.length&&e.segments[0].points.length>2)e.segments.splice(0,1),d=1;else{var S=e.segments[1];S&&S.length&&(S.length=a!==S.direction?S.length+l:S.length-l),d=2,i.length=2*i.length/3}e.segments=h.concat(e.segments)}return d},t.prototype.updateAdjacentSegments=function(e,i,r,s){var o=e.segments[parseInt(i.toString(),10)],a=o.points[o.points.length-1],h=!0;"Orthogonal"===o.type&&(o.points[0]=o.points[0],o.points[o.points.length-1]=a,e.segments[i-1]&&(h=this.updatePreviousSegment(r,s,e,i)),e.segments.length-1>i&&h&&this.updateNextSegment(e,o,e.segments[i+1],r,s))},t.prototype.addTerminalSegment=function(e,i,r,s,o){var l,h,c,d,a=e.segments.indexOf(i),u=[],f=e.segments.pop(),p=e.segments[e.segments.length-1];l=p&&"Orthogonal"===p.type?p:null;for(var g=0;g0&&"Left"===o.direction?c.middleLeft:c.middleRight,o.length>c.width/2?Math.abs(a.length)0&&"Top"===o.direction?c.topCenter:c.bottomCenter,o.length>c.height/2?Math.abs(a.length)1)for(var a=0,l=this.diagram.views;a0)for(var e=t===Ce.onUserHandleMouseLeave?this.previousAction:this.action,i={element:void 0},r=0;r0)for(var r={element:void 0},s=void 0,o=void 0,a=0;a-1&&(o=s,this.previousTarget=i,this.targetItem=e),o===e.fixedUserHandles[parseInt(a.toString(),10)].id&&(r.element=e.fixedUserHandles[parseInt(a.toString(),10)],this.userHandle(t,a,r,e))},n.prototype.mouseDown=function(t){var e=this;if("touchstart"===t.type&&(this.timeOutTapHold=setTimeout(function(){("Select"===e.action||"Drag"===e.action)&&e.mouseMove(t,void 0)},500)),!0!==this.inAction||!(this.tool instanceof WI||this.tool instanceof pa)){this.focus=!0;var i=t.touches,r=!!document.getElementsByClassName("e-dragclone")[0];if(this.isMouseOnScrollBar(t)&&!r)return this.isScrolling=!0,void t.preventDefault();if(this.checkFixedUserHandleEvent(Ce.onFixedUserHandleMouseDown,this.targetItem,this.previousTarget),this.checkUserHandleEvent(Ce.onUserHandleMouseDown),!this.checkEditBoxAsTarget(t)&&jv(this.diagram)||Lc(this.diagram)&&!RI(this.diagram))if(("Select"===this.action||"Drag"===this.action)&&this.diagram.updatePortVisibility(this.hoverElement,Gt.Hover,!0),!(this.tool instanceof zl||this.tool instanceof Rl)||2!==t.button&&2!==t.buttons)if(!0===this.inAction&&!0===this.isMouseDown&&(this.tool instanceof zl||this.tool instanceof Rl))this.isMouseDown=!0,this.eventArgs={},this.getMouseEventArgs(this.currentPosition,this.eventArgs),this.eventArgs.position=this.currentPosition,this.tool.mouseDown(this.eventArgs);else{this.isMouseDown=!0,this.currentPosition=this.prevPosition=this.getMousePosition(t),this.eventArgs={},this.diagram.textEditing&&!this.isMouseOnScrollBar(t)&&(this.diagram.endEdit(),this.diagram.textEditing=!1,"Canvas"===this.diagram.mode&&1!==this.diagram.scroller.currentZoom&&this.diagram.refreshDiagramLayer());var o=this.getTargetElement();this.action=this.diagram.findActionToBeDone(o.obj,o.sourceElement,this.currentPosition,o.target);var a=this.isMetaKey(t);a&&t.shiftKey&&this.diagram.connectorEditingToolModule?this.action="SegmentEnd":(a||t.shiftKey)&&(_v(this.diagram)||Uv(this.diagram))&&(this.action="Select"),this.tool=this.diagram.getTool(this.action),this.tool||(this.action="Select",this.tool=this.diagram.getTool(this.action)),this.getMouseEventArgs(this.currentPosition,this.eventArgs),(a||t.shiftKey)&&(this.eventArgs.info=a&&t.shiftKey?{ctrlKey:a,shiftKey:t.shiftKey}:{ctrlKey:!0}),this.eventArgs.position=this.currentPosition;var h=this.diagram.selectedItems.nodes;if(this.tool.mouseDown(this.eventArgs),this.diagram.selectedItems.canToggleSelection&&h&&this.diagram.selectedItems.nodes&&this.tool instanceof fa)for(var c=0;c=2&&(this.touchStartList=HF(this.touchStartList,0,i)),i||t.preventDefault())}else this.inAction=!1,this.tool.mouseUp(this.eventArgs);!this.isForeignObject(t.target)&&!this.isForeignObject(t.target,!0)&&!i&&t.preventDefault()}},n.prototype.mouseMoveExtend=function(t,e){(this.tool instanceof zl||this.tool instanceof Rl)&&this.tool.mouseMove(this.eventArgs),this.diagram.scrollSettings.canAutoScroll?this.checkAutoScroll(t):this.blocked||this.tool.mouseMove(this.eventArgs),this.eventArgs.target&&(this.hoverElement=this.eventArgs.target);var i=!((this.eventArgs.target instanceof te||this.eventArgs.target instanceof de)&&(e instanceof te||e instanceof de));this.tool instanceof kd&&this.diagram.updatePortVisibility(this.hoverElement instanceof te||this.hoverElement instanceof de?this.hoverElement:this.hoverNode,Gt.Connect|Gt.Hover,i),this.hoverElement instanceof te&&this.hoverNode instanceof te&&this.hoverNode&&this.hoverNode.id!==this.hoverElement.id&&this.diagram.updatePortVisibility(this.hoverNode,Gt.Connect|Gt.Hover,!0),this.hoverElement instanceof de&&this.hoverElement.ports.length>0&&this.diagram.updatePortVisibility(this.hoverElement,Gt.Connect|Gt.Hover,!0),this.previousElement instanceof te&&this.hoverElement&&this.previousElement.id!==this.hoverElement.id&&this.diagram.updatePortVisibility(this.previousElement,Gt.Connect|Gt.Hover,!0),this.previousElement=this.hoverElement,""!==this.diagram.tooltip.content&&(this.hoverElement=null),this.hoverNode=i?null:e},n.prototype.checkAction=function(t){if("LabelSelect"===this.action&&this.eventArgs.sourceWrapper&&(this.eventArgs.sourceWrapper instanceof li||this.eventArgs.sourceWrapper instanceof es)){var e=this.commandHandler.findTarget(this.eventArgs.sourceWrapper,this.eventArgs.source);!_r(this.diagram,e,!1,this.eventArgs.sourceWrapper)&&ro(e)&&(this.action="LabelDrag",this.tool=this.getTool(this.action),this.tool.mouseDown(this.initialEventArgs))}else ro(t)&&xd(t)&&this.initialEventArgs&&this.initialEventArgs.source&&"Select"===this.action&&(!_r(this.diagram,this.eventArgs.source,!1)&&this.eventArgs.source instanceof ti&&this.getMouseEventArgs(this.currentPosition,this.eventArgs),(!(t instanceof de)||t instanceof de&&!(wr(this.currentPosition,t.sourcePoint,t.hitPadding)||wr(this.currentPosition,t.targetPoint,t.hitPadding)))&&(this.action="Drag"),this.tool=this.getTool(this.action),this.tool.mouseDown(this.initialEventArgs))},n.prototype.isSwimlaneElements=function(t){return!(t&&(t.isLane||t.isPhase||t.isHeader))},n.prototype.canShowTouchTooltip=function(t){return!!("touchstart"===t.type&&this.diagram.tool&ni.SingleSelect&&this.diagram.tool&ni.ZoomPan)&&(this.isMouseDown=!1,!0)},n.prototype.mouseMove=function(t,e){if(this.focus=!0,"touchmove"===t.type&&(this.touchArgs={target:t.target,type:"touchmove"}),this.isScrolling)t.preventDefault();else if(jv(this.diagram)||Lc(this.diagram)&&!RI(this.diagram)){this.currentPosition=this.getMousePosition(t);var i=this.diagram.findObjectsUnderMouse(this.currentPosition),r=this.diagram.findObjectUnderMouse(i,this.action,this.inAction);!function Gne(n,t){n.rulerSettings.showRulers&&(n.hRuler.drawRulerMarker(n.hRuler.element,t,n.scroller.horizontalOffset),n.vRuler.drawRulerMarker(n.vRuler.element,t,n.scroller.verticalOffset))}(this.diagram,this.currentPosition);var s=!1,o=void 0;if("touchmove"===t.type&&(e=t.touches)&&e.length>1&&(this.touchMoveList=HF(this.touchMoveList,0,e),"PinchZoom"!==this.action&&(s=!0)),!1===R.equals(this.currentPosition,this.prevPosition)||this.inAction||this.canShowTouchTooltip(t)){if(!1===this.isMouseDown||s){this.eventArgs={};var a=null,l=void 0;if(null!==r){if((a=this.diagram.findElementUnderMouse(r,this.currentPosition,this.diagram))&&(l=this.commandHandler.findTarget(a,r)),(l instanceof Kn||l instanceof Or)&&(l.tooltip&&""!==l.tooltip.content||(l=r)),l!==this.hoverElement){var h=this.getContent();this.hoverElement&&"Auto"===this.hoverElement.tooltip.openOn&&""!==h&&this.elementLeave(),this.diagram.updatePortVisibility(this.hoverElement,Gt.Hover,!0),r instanceof te&&(this.hoverNode=r);var c=!0;!this.isSwimlaneElements(r)&&this.hoverElement&&this.isSwimlaneElements(this.hoverElement)&&(c=!1),this.hoverElement=c?r:this.hoverElement;var d,u=void 0;(d=this.diagram.findElementUnderMouse(r,this.currentPosition,this.diagram))instanceof Ze&&((u=this.commandHandler.findTarget(d,r))instanceof Es||u instanceof Tc)&&this.hoverElement.constraints&ai.ToolTip&&(this.hoverElement=u);var f=void 0;d instanceof li&&((f=this.commandHandler.findTarget(d,r))instanceof Kn||f instanceof Or)&&f.constraints&Nr.Tooltip&&(this.hoverElement=f),c?this.elementEnter(this.currentPosition,!1):this.hoverElement=r}else this.hoverElement&&this.hoverElement===l&&this.hoverElement.tooltip.content&&void 0!==this.diagram.tooltipObject&&"Mouse"===this.hoverElement.tooltip.relativeMode&&this.setTooltipOffset(this.currentPosition);a&&(o=this.commandHandler.findTarget(a,r))}this.action=this.diagram.findActionToBeDone(r,a,this.currentPosition,o),this.checkFixedUserHandleEvent(Ce.onFixedUserHandleMouseEnter,r,a),this.checkUserHandleEvent(Ce.onUserHandleMouseEnter),this.checkPreviousAction(),this.getMouseEventArgs(this.currentPosition,this.eventArgs),this.tool=this.getTool(this.action),this.mouseEvents(),this.tool instanceof pa||this.tool instanceof Rl||this.tool instanceof zl?this.tool.mouseMove(this.eventArgs):e&&this.tool instanceof Kv&&this.tool.mouseDown(this.eventArgs),this.updateCursor(),this.renderUmlHighLighter(this.eventArgs);var p=!1;this.hoverElement&&!(this.tool instanceof Kv)&&r instanceof te&&this.isSwimlaneElements(r)&&(0===this.diagram.selectedItems.nodes.length||!_r(this.diagram,this.hoverElement))||this.hoverElement instanceof de||(p=!0),this.hoverElement&&!(this.tool instanceof Kv)&&r instanceof de&&(0===this.diagram.selectedItems.connectors.length||!_r(this.diagram,this.hoverElement))||this.hoverElement instanceof te||(p=!0),this.diagram.updatePortVisibility(this.hoverElement,Gt.Hover,p);var g=this.getContent();null===r&&this.hoverElement&&"Auto"===this.hoverElement.tooltip.openOn&&g&&(this.hoverElement=null,this.elementLeave()),s=!1}else{this.eventArgs.position=this.currentPosition,"Drag"===this.action&&!_r(this.diagram,this.eventArgs.source,!1)&&this.eventArgs.source instanceof ti&&this.getMouseEventArgs(this.currentPosition,this.eventArgs),this.mouseEvents(),(t.ctrlKey||t.shiftKey)&&(this.eventArgs.info=t.ctrlKey&&t.shiftKey?{ctrlKey:t.ctrlKey,shiftKey:t.shiftKey}:{ctrlKey:!0}),this.checkAction(r);var y=this.getConnectorPadding(this.eventArgs);this.getMouseEventArgs(this.currentPosition,this.eventArgs,this.eventArgs.source,y),this.updateCursor(),this.inAction=!0,this.initialEventArgs=null,("Drag"===this.action||"Rotate"===this.action)&&(this.diagram.diagramActions=this.diagram.diagramActions|ee.Interactions);var S=this.diagram.scroller.getPageBounds();this.mouseMoveExtend(t,r);var b=this.diagram.scroller.getPageBounds();if(r&&(S.width!==b.width||S.height!==b.height||S.x!==b.x||S.y!==b.y)&&this.diagram.views&&this.diagram.views.overview){var M=this.diagram.views.overview;M.updateView(M)}}this.prevPosition=this.currentPosition,this.isForeignObject(t.target,!0)||t.preventDefault()}}},n.prototype.getContent=function(){var i,t=this.hoverElement instanceof te&&this.hoverElement.constraints&ie.Tooltip||this.hoverElement instanceof de&&this.hoverElement.constraints&qe.Tooltip||(this.hoverElement instanceof Es||this.hoverElement instanceof Tc)&&this.hoverElement.constraints&ai.ToolTip||(this.hoverElement instanceof Kn||this.hoverElement instanceof Or)&&this.hoverElement.constraints&Nr.Tooltip,e=this.hoverElement;e instanceof te&&e.children&&e.children.length>0&&(i=this.findIntersectChild(e));var r=t?this.hoverElement.tooltip.content:this.diagram.tooltip.content;return i?i.tooltip.content:r},n.prototype.findIntersectChild=function(t){for(var e,i=new Ne(this.currentPosition.x,this.currentPosition.y,8,8),r=0;r1&&1===t.which&&!function qre(n){return!!(n&ee.PreventClearSelection)}(this.diagram.diagramActions)&&(c=!1,this.commandHandler.clearSelection()),(!_r(this.diagram,h)||!c)&&(this.commandHandler.selectObjects([h],void 0,a),this.diagram.selectedItems.canToggleSelection)){var d=this.diagram.selectedItems.nodes;d?d[0].parentObj instanceof Hd&&(s=!0):this.diagram.selectedItems.connectors.length>0&&(s=!0)}}var u=!1,f=this.updateContainerProperties(),p=void 0;if(this.addUmlNode(),this.inAction=!1,this.isMouseDown=!1,this.diagram.selectedObject.helperObject&&(p=this.updateContainerBounds()),this.tool&&(this.tool.prevPosition||this.tool instanceof X3)){this.eventArgs.position=this.currentPosition;var g=this.getConnectorPadding(this.eventArgs);this.getMouseEventArgs(this.currentPosition,this.eventArgs,this.eventArgs.source,g);var v=this.isMetaKey(t);if((v||t.shiftKey)&&(this.eventArgs.info=v&&t.shiftKey?{ctrlKey:v,shiftKey:t.shiftKey}:{ctrlKey:!0}),this.diagram.diagramActions&ee.Interactions&&(this.diagram.diagramActions=this.diagram.diagramActions&~ee.Interactions),this.eventArgs.clickCount=t.detail,this.diagram.selectedObject.helperObject&&(this.tool instanceof fa||this.tool instanceof Pd)){if(this.diagram.selectedObject.actualObject&&""!==this.diagram.selectedObject.actualObject.parentId){var S=this.diagram.getObject(this.diagram.selectedObject.actualObject.parentId);S&&S.isLane&&(this.commandHandler.isContainer=!0)}(u=this.diagram.lineRoutingModule&&this.diagram.nameTable.helper&&this.eventArgs.target&&this.eventArgs.target.isLane&&(this.eventArgs.source instanceof ti&&this.eventArgs.source.nodes.length>0&&""===this.eventArgs.source.nodes[0].parentId||""===this.eventArgs.source.parentId))&&(this.diagram.diagramActions=this.diagram.diagramActions|ee.PreventLaneContainerUpdate),this.tool.mouseUp(this.eventArgs,f.isPreventHistory)}else{if(this.diagram.selectedItems.canToggleSelection){var b=void 0,M=void 0;if(this.diagram.selectedItems.nodes.length>0)for(var w=0;w1&&D[0].id===i[parseInt(w.toString(),10)].id||r.length>0)&&(M=!0);!this.isSwimlaneSelected&&!s&&!M&&this.tool instanceof fa&&"Select"===this.currentAction&&(!b||this.diagram.selectedItems.connectors.length>0)&&this.commandHandler.clearSelection(!0)}this.isSwimlaneSelected=!1,this.tool.mouseUp(this.eventArgs),this.diagram.checkMenu&&(-1!==window.navigator.userAgent.indexOf("Linux")||-1!==window.navigator.userAgent.indexOf("X11"))&&(!t.pageY&&t instanceof TouchEvent&&t.changedTouches?(window.getSelection().removeAllRanges(),this.diagram.contextMenuModule.contextMenu.open(t.changedTouches[0].pageY,t.changedTouches[0].pageX,this.diagram.element),t.preventDefault()):this.diagram.contextMenuModule.contextMenu.open(t.pageY,t.pageX,this.diagram.element),this.diagram.checkMenu=!1)}f.hasStack&&this.diagram.endGroupAction()}if(p&&this.diagram.endGroupAction(),this.updateContainerBounds(!0),2!==this.eventArgs.clickCount&&(this.commandHandler.updateSelectedNodeProperties(this.eventArgs.source),u)){this.diagram.diagramActions=this.diagram.diagramActions&~ee.PreventLaneContainerUpdate;var A=this.eventArgs.source instanceof ti?this.eventArgs.source.nodes:[this.eventArgs.source];if(A)for(w=0;w0&&!N&&this.diagram.renderSelector(!0),!this.inAction&&!this.diagram.currentSymbol&&this.eventArgs){var T=this.getTargetElement();this.diagram.tool!==ni.ZoomPan&&this.diagram.triggerEvent(Ce.click,{element:T.target instanceof Es?T.target:this.eventArgs.source||this.diagram,position:this.eventArgs.position,count:t.detail,actualObject:this.eventArgs.actualObject,button:0===t.button?"Left":1===t.button?"Middle":"Right"})}this.eventArgs={}}this.diagram.diagramActions=this.diagram.diagramActions&~ee.PreventLaneContainerUpdate,e&&this.updateAnnotation(this.diagram.selectedItems),this.previousElement=null,this.eventArgs={},this.diagram.commandHandler.removeStackHighlighter()},n.prototype.isSwimlaneChild=function(t){if(t.shape&&"SwimLane"!==t.shape.type){var e=this.diagram.nameTable[t.parentId];if(!e)return!1;var i=e.parentId?this.diagram.nameTable[e.parentId]:e;return i&&i.shape&&"SwimLane"===i.shape.type}return!1},n.prototype.updateAnnotation=function(t){var e=t.nodes;if(e.length>0)for(var i=0;i0&&(a+=1),h.isPhase){l="Horizontal"===r.orientation?this.currentPosition.x-e.wrapper.bounds.x:this.currentPosition.y-(e.wrapper.bounds.y+r.header.height);var g={id:Qe(),offset:l,header:{annotation:{content:void 0===h.phases[0].header?"Phase":h.phases[0].header.annotation.content,style:void 0===h.phases[0].header?{}:h.phases[0].header.annotation.style}},style:void 0===h.phases[0]?{}:h.phases[0].style};this.diagram.addPhases(e,[g])}else{var v={id:Qe(),style:h.lanes[0].style,header:{annotation:{content:h.lanes[0].header.annotation.content,style:h.lanes[0].header.annotation.style},style:h.lanes[0].header.style}};if("Horizontal"===h.orientation?v.height=h.lanes[0].height:v.width=h.lanes[0].width,"Horizontal"===r.orientation?(s=i.rowIndex?i.rowIndex:this.diagram.nameTable[i.parentId].rowIndex,i.wrapper.offsetYs)v.header.width=r.lanes[parseInt(s.toString(),10)].header.width,v.header.height=r.lanes[parseInt(s.toString(),10)].header.height;else{var S=void 0;S="Horizontal"===r.orientation?i.rowIndex<3?0:s-a-1:s-1,v.header.width=r.lanes[parseInt(S.toString(),10)].header.width,v.header.height=r.lanes[parseInt(S.toString(),10)].header.height}p&&("height"===p?(v.width=v.height,delete v.height):(v.height=v.width,delete v.width)),this.diagram.addLanes(e,[v],"Horizontal"===r.orientation?s-a:s)}this.commandHandler.select(e)}else if(h.isLane){var b={id:Qe(),width:t.width,height:t.height,addInfo:t.addInfo,shape:{type:"SwimLane",header:{annotation:{content:void 0===h.header?"Header":h.header.annotation.content,style:void 0===h.header?{}:h.header.annotation.style},height:50,style:h.header?h.header.style:h.lanes[0].header.style},phases:[{id:Qe(),header:{annotation:{content:void 0===h.phases||void 0===h.phases[0].header?"Phase":h.phases[0].header.annotation.content,style:void 0===h.phases||void 0===h.phases[0].header?{}:h.phases[0].header.annotation.style},style:void 0===h.phases||void 0===h.phases[0].header?{}:h.phases[0].header.style},style:void 0===h.phases?{}:h.phases[0].style}],lanes:[{id:Qe(),height:t.height,width:t.width,style:h.lanes[0].style,header:{annotation:{content:h.lanes[0].header.annotation.content,style:h.lanes[0].header.annotation.style},style:h.lanes[0].header.style}}],orientation:h.orientation}};"Vertical"===h.orientation&&(b.width+=20),b.offsetX=this.currentPosition.x+b.width/2,b.offsetY=this.currentPosition.y+b.height/2,b.style=t.style,this.diagram.add(b)}},n.prototype.mouseLeave=function(t){this.tool&&this.inAction&&this.tool.mouseLeave(this.eventArgs),this.diagram.selectedObject.helperObject&&(this.updateContainerProperties(),this.updateContainerBounds()&&this.diagram.endGroupAction()),this.eventArgs&&this.eventArgs.source&&(this.diagram.updatePortVisibility(this.eventArgs.source,Gt.Hover,!0),this.hoverElement=null),this.eventArgs&&!this.eventArgs.source&&this.hoverElement&&(this.hoverElement=null),this.tool instanceof kd&&this.eventArgs&&this.eventArgs.target&&this.eventArgs.target instanceof te&&(this.diagram.updatePortVisibility(this.eventArgs.target,Gt.Hover|Gt.Connect,!0),this.hoverElement=null);var i=this.diagram.selectedItems;i&&i.wrapper&&(am(this.diagram,i)||this.diagram.renderSelector(!0)),(this.diagram.diagramActions&ee.Interactions||this.diagram.diagramActions&ee.ToolAction)&&(this.diagram.diagramActions=this.diagram.diagramActions&~ee.ToolAction),this.isMouseDown=!1,this.focus=!1,this.touchStartList=null,this.touchMoveList=null,this.elementLeave(),this.commandHandler.removeSnap(),this.inAction=!1,this.eventArgs={},this.diagram.selectedObject&&this.diagram.selectedObject.helperObject&&(this.diagram.remove(this.diagram.selectedObject.helperObject),this.diagram.selectedObject={helperObject:void 0,actualObject:void 0}),this.tool=null,function Qne(){var t,e,n=document.getElementsByClassName("e-d-ruler-marker");if(n&&n.length>0)for(e=n.length-1;e>=0;e--)(t=n[parseInt(e.toString(),10)])&&t.parentNode.removeChild(t)}(),"Rotate"===this.action&&this.diagram.diagramCanvas.classList.remove("e-diagram-rotate"),t.preventDefault()},n.prototype.mouseWheel=function(t){this.diagram.blazorActions|=on.interaction;var e={event:t,cancel:!1};if(this.diagram.triggerEvent(Ce.mouseWheel,e),!e.cancel){var i=t.wheelDelta>0||-40*t.detail>0,r=this.getMousePosition(t);if(this.diagram.tooltipObject.close(),this.isMetaKey(t)){var o=this.diagram.scrollSettings.zoomFactor;this.diagram.zoomTo(i?{type:"ZoomIn",zoomFactor:o,focusPoint:r}:{type:"ZoomOut",zoomFactor:o,focusPoint:r}),t.preventDefault()}else{var a=this.diagram.scroller.horizontalOffset,l=this.diagram.scroller.verticalOffset,h=i?10:-10;this.tool&&(this.tool instanceof zl||this.tool instanceof Rl)&&(this.eventArgs={},this.getMouseEventArgs(r,this.eventArgs),this.eventArgs.position=r,this.tool.mouseWheel(this.eventArgs)),this.diagram.scrollActions|=da.Interaction;var c=!0;if(t.isTrusted){var d=!1;(Math.abs(t.deltaY)<100&&-0===Math.abs(t.deltaX)||Math.abs(t.deltaX)<100&&-0===Math.abs(t.deltaY))&&(d=!0);var u=!1;(0!==t.deltaX||0!==t.deltaY)&&(u=navigator.userAgent.includes("Macintosh")),u?Math.abs(t.deltaX)>Math.abs(t.deltaY)?(t.shiftKey||t.deltaX&&-0!==t.deltaX&&(d||!u))&&this.diagram.scroller.zoom(1,h,0,r,c,void 0,d):t.deltaY&&-0!==t.deltaY&&(d||!u)&&this.diagram.scroller.zoom(1,0,h,r,c,void 0,d):t.shiftKey||t.deltaX&&-0!==t.deltaX&&(d||!u)?this.diagram.scroller.zoom(1,h,0,r,c,void 0,d):t.deltaY&&-0!==t.deltaY&&(d||!u)&&this.diagram.scroller.zoom(1,0,h,r,c,void 0,d)}else t.shiftKey||t.deltaX&&-0!==t.deltaX?this.diagram.scroller.zoom(1,h,0,r,c):this.diagram.scroller.zoom(1,0,h,r,c);this.diagram.scrollActions&=~da.Interaction,(a!==this.diagram.scroller.horizontalOffset||l!==this.diagram.scroller.verticalOffset)&&t.preventDefault()}if(this.diagram.textEditing){if(this.diagram.isTriggerEvent=!0,this.diagram.activeLabel.parentId){var p=this.diagram.getObject(this.diagram.activeLabel.parentId);this.diagram.startTextEdit(p,this.diagram.activeLabel.id)}this.diagram.isTriggerEvent=!1}this.diagram.blazorActions=this.diagram.blazorActions&~on.interaction}},n.prototype.keyDown=function(t){if(t.fromMouseEvents&&(t.ctrlKey&&(this.keyArgs.keyModifiers=1),t.shiftKey&&(this.keyArgs.keyModifiers=4),t.shiftKey&&t.ctrlKey&&(this.keyArgs.keyModifiers=5)),!(this.diagram.diagramActions&ee.TextEdit)&&!this.checkEditBoxAsTarget(t)||"Escape"===t.key||27===t.keyCode){var i=void 0,r=t.keyCode?t.keyCode:t.which,s=t.key;("ArrowDown"===s||"ArrowUp"===s||"ArrowLeft"===s||"ArrowRight"===s)&&(this.isNudgeKey=!0);var o=this.isMetaKey(t);if(this.diagram.commandManager&&this.diagram.commands)for(var l=0,h=Object.keys(this.diagram.commands);l4&&(S({keyDownEventArgs:KeyboardEvent,parameter:i.parameter,type:"KEYDOWN"}),this.keyCount=0,this.keyArgs.newValue={offsetX:this.diagram.selectedItems.offsetX,offsetY:this.diagram.selectedItems.offsetY},this.diagram.triggerEvent(Ce.positionChange,this.keyArgs))),this.isKeyUp=!1):S({keyDownEventArgs:KeyboardEvent,parameter:i.parameter})}break}}}}this.keyArgs={element:this.diagram.selectedItems,key:t.key,keyCode:t.keyCode?t.keyCode:t.which},this.getKeyModifier(this.keyArgs,t),this.diagram.diagramActions&ee.TextEdit&&this.getlabel(this.keyArgs,t),this.diagram.triggerEvent(Ce.keyDown,this.keyArgs)},n.prototype.getlabel=function(t,e){var i=this.diagram.activeLabel;t.target=this.diagram.element.id+"_editBox";var r=this.diagram.nameTable[i.parentId];if(document.getElementById(this.diagram.element.id+"_editBox")){t.text=document.getElementById(this.diagram.element.id+"_editBox").value;for(var s=0;s=this.diagram.scroller.viewPortWidth-18?r="right":e.x+this.diagram.scroller.horizontalOffsetthis.diagram.scroller.viewPortHeight-18?r="bottom":e.y+this.diagram.scroller.verticalOffset0&&(s=this.findIntersectChild(this.hoverElement)),"Auto"===this.hoverElement.tooltip.openOn&&""!==r&&Mx(this.diagram,s||(i?this.hoverElement:void 0)),this.hoverElement.tooltip.content&&("Mouse"===this.hoverElement.tooltip.relativeMode?this.setTooltipOffset(t):(this.diagram.tooltipObject.offsetX=0,this.diagram.tooltipObject.offsetY=0));var o=this.diagram.findObjectsUnderMouse(this.currentPosition),a=this.diagram.findObjectUnderMouse(o,this.action,this.inAction);if(null!==a){var l=void 0;this.hoverElement.tooltip.isSticky&&(this.diagram.tooltipObject.isSticky=!0),a instanceof te&&a.children&&a.children.length>0&&(a=s||a),l=a.ports&&(this.hoverElement instanceof Es||this.hoverElement instanceof Tc)||a.annotations&&(this.hoverElement instanceof Kn||this.hoverElement instanceof Or)?document.getElementById(a.id+"_"+this.hoverElement.id):document.getElementById(a.id+(a.shape&&a.shape instanceof lm?"_content_native_element":"_groupElement")),"Auto"===this.hoverElement.tooltip.openOn&&""!==r&&(this.diagram.tooltipObject.close(),this.diagram.tooltipObject.openOn=this.hoverElement.tooltip.openOn,this.diagram.tooltipObject.dataBind()),function jre(n,t){var e=0;return n instanceof de?n.constraints&qe.Tooltip?e=n.constraints&qe.Tooltip:n.constraints&qe.InheritTooltip&&(e=t.constraints&nt.Tooltip):n instanceof Es||n instanceof Tc?n.constraints&ai.ToolTip?e=n.constraints&ai.ToolTip:n.constraints&ai.InheritTooltip&&(e=t.constraints&nt.Tooltip):n instanceof Kn||n instanceof Or?n.constraints&Nr.Tooltip&&(e=n.constraints&Nr.Tooltip):n.constraints&ie.Tooltip?e=n.constraints&ie.Tooltip:n.constraints&ie.InheritTooltip&&(e=t.constraints&nt.Tooltip),e}(this.hoverElement,this.diagram)&&"Auto"===this.hoverElement.tooltip.openOn&&(this.diagram.tooltipObject.target=this.hoverElement.id,this.diagram.tooltipObject.open("Mouse"===this.hoverElement.tooltip.relativeMode?this.diagram.element:l))}}},n.prototype.elementLeave=function(){this.diagram.tooltipObject&&!this.diagram.tooltipObject.isSticky&&"Custom"!==this.diagram.tooltipObject.openOn&&this.diagram.tooltipObject.close()},n.prototype.setTooltipOffset=function(t){var e=function dse(n,t,e,i){var o="Mouse"===(!(e instanceof te?e.constraints&ie.InheritTooltip:e instanceof de?e.constraints&qe.InheritTooltip:e.constraints&ai.InheritTooltip)&&(e instanceof te?e.constraints&ie.Tooltip:e instanceof de?e.constraints&qe.Tooltip:e.constraints&ai.ToolTip)?e.tooltip.relativeMode:n.tooltip.relativeMode);"Mouse"===i?o=!0:"Object"===i&&(o=!1);var a=function use(n,t,e,i){var o,r={},s=document.getElementById(e.element.id);if(n instanceof te||n instanceof de)o=n.wrapper.bounds;else{var a=e.findObjectsUnderMouse(t),l=e.findObjectUnderMouse(a,"Select",!1);o=e.findElementUnderMouse(l,t,e).bounds}var c=s.getBoundingClientRect();switch(e.tooltipObject.position){case"BottomCenter":r=zc(t,o.bottomCenter,e,i,c.width/2,c.height);break;case"BottomLeft":case"LeftBottom":r=zc(t,o.bottomLeft,e,i,0,c.height);break;case"BottomRight":case"RightBottom":r=zc(t,o.bottomRight,e,i,c.width,c.height);break;case"LeftCenter":r=zc(t,o.middleLeft,e,i,0,c.height/2);break;case"LeftTop":case"TopLeft":r=zc(t,o.topLeft,e,i,0,0);break;case"RightCenter":r=zc(t,o.middleRight,e,i,c.width,c.height/2);break;case"RightTop":case"TopRight":r=zc(t,o.topRight,e,i,c.width,0);break;case"TopCenter":r=zc(t,o.topCenter,e,i,c.width/2,0)}return r}(e,t,n,o),l=Za(n);return{x:a.x+l.width,y:a.y+l.height}}(this.diagram,t,this.hoverElement);this.diagram.tooltipObject.offsetX=e.x,this.diagram.tooltipObject.offsetY=e.y},n.prototype.altKeyPressed=function(t){return!!(t&ft.Alt)},n.prototype.ctrlKeyPressed=function(t){return!!(t&ft.Control)},n.prototype.shiftKeyPressed=function(t){return!!(t&ft.Shift)},n.prototype.scrolled=function(t){this.diagram.updateScrollOffset()},n.prototype.isMobileOrIPadDevice=function(){var t=navigator.userAgent||navigator.vendor||window.opera;return/iPhone|iPad|iPod/.test(t)&&!window.MSStream?"iOS":/android/i.test(t)?"Android":/Mobile|Tablet/.test(t)?"Mobile":"Desktop"},n.prototype.doubleClick=function(t){if(jv(this.diagram)){var e=this.isMobileOrIPadDevice(),i=this.diagram.tool;"Desktop"!==e&&this.tool&&(this.tool instanceof zl||this.tool instanceof Rl)&&(this.diagram.tool=0);var r=void 0,s=this.diagram.findObjectsUnderMouse(this.currentPosition),o=this.diagram.findObjectUnderMouse(s,this.action,this.inAction);if(null!==o&&jv(this.diagram))if(r=this.diagram.findElementUnderMouse(o,this.currentPosition,this.diagram),this.tool&&(this.tool instanceof zl||this.tool instanceof Rl))this.diagram.tool=i,this.tool.mouseUp(this.eventArgs),this.isMouseDown=!1,this.eventArgs={},this.tool=null,t.preventDefault();else{var l=this.diagram.commandHandler.getObjectLayer(o.id);!l||l.lock||!l.visible||this.diagram.diagramActions&ee.TextEdit||this.diagram.startTextEdit(o,r instanceof li?r.id.split(o.id+"_")[1]:void 0)}this.diagram.triggerEvent(Ce.doubleClick,{source:o||this.diagram,position:this.currentPosition,count:t.detail})}},n.prototype.itemClick=function(t,e){var i=t;return Dn(this.diagram,i,!0)?i:null},n.prototype.inputChange=function(t){var i,s,o,a,l,h,c,d,u,f=document.getElementById(this.diagram.element.id+"_editBox"),p=document.getElementById(this.diagram.element.id+"_editTextBoxDiv"),g=f.value,v=g.split("\n");(!(a=this.diagram.selectedItems.nodes[0]?this.diagram.selectedItems.nodes[0]:this.diagram.selectedItems.connectors[0])&&this.tool instanceof YI||a&&"SwimLane"===a.shape.type)&&(a=this.diagram.nameTable[this.diagram.activeLabel.parentId]),a&&("Text"!==a.shape.type&&a.annotations.length>0||"Text"===a.shape.type)&&(c=NF((o=this.diagram.getWrapper(a.wrapper,this.diagram.activeLabel.id)).style,g,void 0,void 0,i=(i=a.wrapper.bounds.width90?i:90),s=Number(f.style.fontSize.split("px")[0]),v.length>1&&""===v[v.length-1]&&(c.height=c.height+s),d=this.diagram.scroller.transform,u=T3(this.diagram)?d.scale:1,l=(12>c.height?12:c.height)*u,p.style.left=(o.bounds.center.x+d.tx)*d.scale-(h=(90>(h=c.width)?90:h)*u)/2-2.5+"px",p.style.top=(o.bounds.center.y+d.ty)*d.scale-l/2-3+"px",p.style.width=h+"px",p.style.height=l+"px",f.style.minHeight="12px",f.style.minWidth="90px",f.style.width=h+"px",f.style.height=l+"px")},n.prototype.isAddTextNode=function(t,e){return!(!(this.tool instanceof YI||e)||(this.tool=null,t&&!zI(this.diagram)&&(this.diagram.drawingObject=void 0,this.diagram.currentDrawingObject=void 0),vF(this.diagram.nodes,t.id)||vF(this.diagram.connectors,t.id)))},n.prototype.checkEditBoxAsTarget=function(t){return!(!t.target||t.target.id!==this.diagram.element.id+"_editBox")},n.prototype.getMouseEventArgs=function(t,e,i,r){var s,o,a;if(e.position=t,i?(o=this.diagram.findObjectsUnderMouse(this.currentPosition,i),s=this.diagram.findTargetObjectUnderMouse(o,this.action,this.inAction,e.position,i)):"Drag"===this.action||"ConnectorSourceEnd"===this.action||"SegmentEnd"===this.action||"OrthoThumb"===this.action||"BezierSourceThumb"===this.action||"BezierTargetThumb"===this.action||"ConnectorTargetEnd"===this.action||-1!==this.action.indexOf("Rotate")||-1!==this.action.indexOf("Resize")?(s=this.diagram.selectedItems,!this.diagram.currentSymbol&&"Drag"===this.action&&s&&this.diagram.selectedItems.nodes.length>0&&"SwimLane"===this.diagram.selectedItems.nodes[0].shape.type&&(o=this.diagram.findObjectsUnderMouse(this.currentPosition),s=this.diagram.findObjectUnderMouse(o,this.action,this.inAction))):(o=this.diagram.findObjectsUnderMouse(this.currentPosition),s=this.diagram.findObjectUnderMouse(o,this.action,this.inAction)),s&&s.isHeader&&(this.eventArgs.actualObject=s=this.diagram.nameTable[s.parentId]),s){var l=void 0,h=void 0,c=void 0;if(((a=this.diagram.findElementUnderMouse(s,this.currentPosition,this.diagram,r))&&s.ports&&s.ports.length&&!rb(s,a)||!a||!s)&&o&&o.length&&i instanceof ti)for(l=i.connectors[0],c=o.length-1;c>=0;c--)if(((h=o[parseInt(c.toString(),10)])instanceof te||h instanceof de)&&l&&l.connectionPadding){if(a=this.diagram.findElementUnderMouse(s=h,this.currentPosition,this.diagram,r),l.constraints&qe.ConnectToNearByPort&&s&&s.ports&&s.ports.length&&rb(s,a))break;if((h instanceof te||h instanceof de)&&l&&l.connectionPadding&&h.wrapper.outerBounds.containsPoint(this.currentPosition)&&l.constraints&qe.ConnectToNearByNode&&!(l.constraints&qe.ConnectToNearByPort)){a=this.diagram.findElementUnderMouse(s=h,this.currentPosition,this.diagram,0);break}}}return i?(e.target=s,e.targetWrapper=a):(e.source=s,e.sourceWrapper=a),e.actualObject=this.eventArgs.actualObject,e.source instanceof ti&&void 0===e.actualObject&&(e.source.nodes.length>0||e.source.connectors.length>0)&&(e.actualObject=e.source.nodes.length>0?this.diagram.nameTable[e.source.nodes[0].id]:this.diagram.nameTable[e.source.connectors[0].id]),e.startTouches=this.touchStartList,e.moveTouches=this.touchMoveList,e},n.prototype.resetTool=function(){this.action="Select",this.hoverElement=null,this.hoverNode=null,this.tool=this.diagram.getTool(this.action),this.updateCursor()},n.prototype.updateTool=function(){this.action=this.currentPosition&&"Pan"!==this.action?"Pan":"Select"},n.prototype.getTool=function(t){switch(t){case"Select":return new Jv(this.commandHandler,!0);case"Drag":return new fa(this.commandHandler);case"Rotate":return new Yx(this.commandHandler);case"LayoutAnimation":return new Lne(this.commandHandler);case"FixedUserHandle":return new Ane(this.commandHandler,!0);case"Hyperlink":return new X3(this.commandHandler);case"ResizeSouthEast":case"ResizeSouthWest":case"ResizeNorthEast":case"ResizeNorthWest":case"ResizeSouth":case"ResizeNorth":case"ResizeWest":case"ResizeEast":return new Pd(this.commandHandler,t);case"ConnectorSourceEnd":case"ConnectorTargetEnd":case"BezierSourceThumb":case"BezierTargetThumb":return new kd(this.commandHandler,t);case"SegmentEnd":case"OrthoThumb":return new ZF(this.commandHandler,t);case"Draw":var e="shape",i=function nse(n){var t;return n&&(n.type?t="Connector":n.shape&&!n.type&&(t="Node")),t}(this.diagram.drawingObject);if("Node"===i&&"Text"===this.diagram.drawingObject.shape.type)return new YI(this.commandHandler);if("Connector"===i&&"Freehand"===this.diagram.drawingObject.type)return new Pne(this.commandHandler);if("Node"===i&&"Polygon"===this.diagram.drawingObject.shape[""+e]&&!this.diagram.drawingObject.shape.points)return new zl(this.commandHandler);if("Node"===i||"Node"===i&&"Polygon"===this.diagram.drawingObject.shape[""+e]&&this.diagram.drawingObject.shape.points)return new WI(this.commandHandler,this.diagram.drawingObject);if("Connector"===i&&"Polyline"===this.diagram.drawingObject.type)return new Rl(this.commandHandler);if("Connector"===i)return new pa(this.commandHandler,"ConnectorSourceEnd",this.diagram.drawingObject);break;case"Pan":return new Kv(this.commandHandler,!1);case"PinchZoom":return new Kv(this.commandHandler,!0);case"PortDrag":return new fa(this.commandHandler,"Port");case"PortDraw":return new pa(this.commandHandler,"ConnectorSourceEnd",this.diagram.drawingObject);case"LabelSelect":return new Jv(this.commandHandler,!0,"LabelSelect");case"LabelDrag":return new Nne(this.commandHandler);case"LabelResizeSouthEast":case"LabelResizeSouthWest":case"LabelResizeNorthEast":case"LabelResizeNorthWest":case"LabelResizeSouth":case"LabelResizeNorth":case"LabelResizeWest":case"LabelResizeEast":return new One(this.commandHandler,t);case"LabelRotate":return new kne(this.commandHandler)}return null},n.prototype.getCursor=function(t){var e=this.diagram.selectedItems.annotation?this.diagram.selectedItems.wrapper.children[0]:this.diagram.selectedItems;return function Tne(n,t){if(t+=360,t%=360,-1===n.indexOf("Resize"))return Wx[""+n];var e=Wx[""+n];return t>=0&&t<25||t>=160&&t<=205||t>=340&&t<=360?e:t>=25&&t<=70||t>=205&&t<=250?"n-resize"===e||"s-resize"===e?"ne-resize":"nw-resize"===e||"se-resize"===e?"n-resize":"e-resize"===e||"w-resize"===e?"nw-resize":"e-resize":t>=70&&t<=115||t>=250&&t<=295?"n-resize"===e||"s-resize"===e?"e-resize":"nw-resize"===e||"se-resize"===e?"ne-resize":"e-resize"===e||"w-resize"===e?"n-resize":"nw-resize":t>=115&&t<=155||t>=295&&t<=340?"n-resize"===e||"s-resize"===e?"nw-resize":"nw-resize"===e||"se-resize"===e?"e-resize":"e-resize"===e||"w-resize"===e?"ne-resize":Wx[""+n]:"n-resize"}(t,this.diagram.selectedItems.annotation?e.rotateAngle+e.parentTransform:e.rotateAngle)},n.prototype.findElementUnderMouse=function(t,e,i,r){return this.objectFinder.findElementUnderSelectedItem(t,e,i,r)},n.prototype.findObjectsUnderMouse=function(t,e){return this.objectFinder.findObjectsUnderMouse(t,this.diagram,this.eventArgs,e)},n.prototype.findObjectUnderMouse=function(t,e,i){return this.objectFinder.findObjectUnderMouse(this.diagram,t,e,i,this.eventArgs,this.currentPosition)},n.prototype.findTargetUnderMouse=function(t,e,i,r,s){return this.objectFinder.findObjectUnderMouse(this.diagram,t,e,i,this.eventArgs,r,s)},n.prototype.findActionToBeDone=function(t,e,i,r){return function Mne(n,t,e,i,r,s,o){if(s&&s.length>1&&r&&r.length>1)return"PinchZoom";if(i.currentSymbol)return"Drag";if("PortDraw"===i.eventHandler.action&&(i.tool&=~ni.DrawOnce),(x3(i)||zI(i))&&i.drawingObject)return"Draw";if($a(i)&&(l=i.selectedItems).wrapper&&qr(l.constraints,"UserHandle"))for(var h=0,c=l.userHandles;h=50&&(l.x=(a.points[parseInt(h.toString(),10)].x+a.points[h+1].x)/2,l.y=(a.points[parseInt(h.toString(),10)].y+a.points[h+1].y)/2,wr(e,l,n.hitPadding?n.hitPadding:10)))return"OrthoThumb"}else NI(n)&&console.warn('[WARNING] :: Module "ConnectorEditing" is not available in Diagram component! You either misspelled the module name or forgot to load it.');return null}(g,l,e,i);if("OrthoThumb"===S)return S;if(qr(l.constraints,"ConnectorSourceThumb")&&AI(g)&&S||qr(l.constraints,"ConnectorTargetThumb")&&LI(g)&&S)return S}}else{var b=i.selectedItems.handleSize/2/i.scroller.currentZoom,M=10/i.scroller.currentZoom,w=Bi();qi(w,f.rotateAngle+f.parentTransform,f.offsetX,f.offsetY);var C=f.offsetX-f.pivot.x*f.actualSize.width,D=f.offsetY-f.pivot.y*f.actualSize.height,A={x:C+(.5===f.pivot.x?2*f.pivot.x:f.pivot.x)*f.actualSize.width/2,y:D-30/i.scroller.currentZoom};A=Ke(w,A);var x=!!i.selectedItems.annotation,P=!(!x||!OI(i.selectedItems.annotation));if(qr(l.constraints,"Rotate")&&wr(e,A,M)&&i.selectedItems.thumbsConstraints&bt.Rotate){if(x&&P)return"LabelRotate";if(!x)return"Rotate"}if(u.Inflate(b),u.containsPoint(e)&&(S=function wne(n,t,e,i,r,s){var o;return 1===n.selectedItems.nodes.length&&0===n.selectedItems.connectors.length&&n.selectedItems.nodes[0].container&&(o=function Dne(n,t,e,i,r){var s=10/n.scroller.currentZoom,o=n.selectedItems,a=t.actualSize.width,l=t.actualSize.height,h=new Ne(i,r,t.style.strokeWidth,l),c=new Ne(i+a,r,t.style.strokeWidth,l),d=new Ne(i,r,a,t.style.strokeWidth),u=new Ne(i,r+l,a,t.style.strokeWidth),f=Dn(n,n.selectedItems.nodes[0],!0)?n.nameTable[n.selectedItems.nodes[0].parentId]:n.selectedItems.nodes[0];if(ga(o.constraints,"ResizeEast",o.thumbsConstraints,o)&&c.containsPoint(e,s))return"ResizeEast";if(ga(o.constraints,"ResizeSouth",o.thumbsConstraints,o)&&u.containsPoint(e,s))return"ResizeSouth";if("Grid"!==f.container.type){if(ga(o.constraints,"ResizeWest",o.thumbsConstraints,o)&&h.containsPoint(e,s))return"ResizeWest";if(ga(o.constraints,"ResizeNorth",o.thumbsConstraints,o)&&d.containsPoint(e,s))return"ResizeNorth"}return null}(n,t,e,r,s)),!o&&(!n.selectedItems.nodes[0]||!n.selectedItems.nodes[0].isPhase&&!n.selectedItems.nodes[0].isLane&&"SwimLane"!==n.selectedItems.nodes[0].shape.type)&&(o=function xne(n,t,e,i,r,s){var o=40/n.scroller.currentZoom,a=n.selectedItems.handleSize/2/n.scroller.currentZoom,l=n.selectedItems,h=!!l.annotation;if(t.actualSize.width>=o&&t.actualSize.height>=o){if(ga(l.constraints,"ResizeSouthEast",l.thumbsConstraints,l)&&wr(e,Ke(i,{x:r+t.actualSize.width,y:s+t.actualSize.height}),a))return h?"LabelResizeSouthEast":"ResizeSouthEast";if(ga(l.constraints,"ResizeSouthWest",l.thumbsConstraints,l)&&wr(e,Ke(i,{x:r,y:s+t.actualSize.height}),a))return h?"LabelResizeSouthWest":"ResizeSouthWest";if(ga(l.constraints,"ResizeNorthEast",l.thumbsConstraints,l)&&wr(e,Ke(i,{x:r+t.actualSize.width,y:s}),a))return h?"LabelResizeNorthEast":"ResizeNorthEast";if(ga(l.constraints,"ResizeNorthWest",l.thumbsConstraints,l)&&wr(e,Ke(i,{x:r,y:s}),a))return h?"LabelResizeNorthWest":"ResizeNorthWest"}return ga(l.constraints,"ResizeEast",l.thumbsConstraints,l)&&wr(e,Ke(i,{x:r+t.actualSize.width,y:s+t.actualSize.height/2}),a)?h?"LabelResizeEast":"ResizeEast":ga(l.constraints,"ResizeWest",l.thumbsConstraints,l)&&wr(e,Ke(i,{x:r,y:s+t.actualSize.height/2}),a)?h?"LabelResizeWest":"ResizeWest":ga(l.constraints,"ResizeSouth",l.thumbsConstraints,l)&&wr(e,Ke(i,{x:r+t.actualSize.width/2,y:s+t.actualSize.height}),a)?h?"LabelResizeSouth":"ResizeSouth":ga(l.constraints,"ResizeNorth",l.thumbsConstraints,l)&&wr(e,Ke(i,{x:r+t.actualSize.width/2,y:s}),a)?h?"LabelResizeNorth":"ResizeNorth":null}(n,t,e,i,r,s)),o||null}(i,f,e,w,C,D),S))return S}}if(Lc(i)&&!n)return"Pan";if((o instanceof Es||o instanceof Tc)&&(!Lc(i)||_v(i)||Uv(i))&&(S=function Ene(n,t,e,i){if(Hx(t)&&(va(t,Gt.Hover)||va(t,Gt.Visible))){if(t.constraints&ai.Drag)return"PortDrag"}else if(Rx(t)&&(va(t,Gt.Hover)||va(t,Gt.Visible))&&t.constraints&ai.Draw){n.drawingObject={};var r={type:"Orthogonal",sourcePortID:t.id};return n.drawingObject=r,n.tool|=ni.DrawOnce,n.currentDrawingObject=r,"PortDraw"}return"None"}(i,o),"None"!==S))return S;if((o instanceof Kn||o instanceof Or)&&!Lc(i)&&xd(o))return _r(i,o,void 0,t)&&ro(o)?"LabelDrag":"LabelSelect";if(null!==n){if(!(n instanceof te||n instanceof de))return"Select";if(t&&t.id){var L=t.id.split(n.id)[1];if(L&&L.match("^_icon"))return"LayoutAnimation"}if(t&&t.id)for(var O=void 0,N=0;N-1)return"FixedUserHandle";if(t instanceof li&&t.hyperlink.link)return"Hyperlink";if(!ro(n)||!_r(i,n,!1)||void 0!==i.selectedItems.annotation)return n&&Lc(i)&&!RI(i)?"Pan":i.selectedItems.nodes.length&&i.selectedItems.nodes[0].isLane&&i.selectedItems.wrapper&&i.selectedItems.wrapper.bounds.containsPoint(e)?"Drag":"Select";if(n instanceof de&&!wr(e,n.sourcePoint,n.hitPadding)&&!wr(e,n.targetPoint,n.hitPadding)||!(n instanceof de))return"Drag"}return"Select"}(t,e,this.currentPosition,this.diagram,this.touchStartList,this.touchMoveList,r)},n.prototype.updateContainerBounds=function(t){var e=!1;if(this.diagram.selectedObject.helperObject&&this.diagram.selectedObject.actualObject)for(var i=this.diagram.selectedObject.actualObject,r=this.diagram.selectedObject.actualObject instanceof ti?i.nodes:[i],s=0;si.y&&(h+=u>0?-1:1,u+=u>0?-1:1):i&&e.wrapper.offsetYi.x&&(h+=u>0?-1:1,u+=u>0?-1:1):i&&e.wrapper.offsetX1)for(var S=t.offsetX-this.diagram.selectedItems.offsetX,b=t.offsetY-this.diagram.selectedItems.offsetY,M=t.rotateAngle-this.diagram.selectedItems.rotateAngle,w=0;w-1){var A=c.children;A.splice(A.indexOf(o.id),1),this.diagram.nameTable[o.id].parentId="",i=!0,c.wrapper.children.splice(D,1)}}if(function bne(n,t,e,i){var r=n,s=e.nameTable[r.parentId],o=e.nameTable[r.parentId];if(t&&o&&o.container&&"Stack"===o.container.type&&t.container&&"Stack"===t.container.type&&o.id!==t.parentId){var a=o.wrapper.children.indexOf(r.wrapper);a>-1&&(e.nameTable[r.id].parentId=t.id,o.wrapper.children.splice(a,1))}if(t&&t.parentId&&r.parentId&&"Drag"===i&&o.container&&"Stack"===o.container.type){var l=s.wrapper.children.indexOf(t.wrapper),h=s.wrapper.children.indexOf(r.wrapper),c={targetIndex:l,target:t,sourceIndex:h,source:n};s.wrapper.children.splice(h,1),s.wrapper.children.splice(l,0,r.wrapper),e.commandHandler.addHistoryEntry({type:"StackChildPositionChanged",redoObject:{targetIndex:h,target:t,sourceIndex:l,source:n},undoObject:c,category:"Internal"})}}(o,h,this.diagram,this.action),(c=Dn(this.diagram,o)?this.diagram.nameTable[o.parentId]:this.diagram.nameTable[o.parentId]||o)&&c.container&&"Canvas"===c.container.type&&(c.wrapper.maxWidth=c.maxWidth=c.wrapper.actualSize.width,c.wrapper.maxHeight=c.maxHeight=c.wrapper.actualSize.height,e=!0),Dn(this.diagram,o,!0)&&c&&"Canvas"===c.container.type)if(this.diagram.selectedItems.nodes.length>1)for(w=0;w0)for(var i=0;i0&&e.columnIndex>0||l&&e.isLane)){if("Horizontal"===t.container.orientation&&e.isPhase&&e.wrapper.width>e.maxWidth&&(e.maxWidth=e.wrapper.width,e.wrapper.maxWidth=e.wrapper.width),h.updateColumnWidth(e.columnIndex,r.width,!0,c),_x(this.diagram,e,t),e.isPhase){var p=this.diagram.nameTable[""+t.shape.phases[e.columnIndex].header.id];p.maxWidth0?(r=new rp(t,"",u),t.shape.classShape.attributes.push(r)):i.id.includes("_umlMethods")&&t.shape.classShape.methods.length>0&&(s=new cm(t,"",u),t.shape.classShape.methods.push(s))),"Interface"===t.shape.classifier&&(i.id.includes("_umlProperty")&&t.shape.interfaceShape.attributes.length>0?(r=new rp(t,"",u),t.shape.classShape.attributes.push(r)):i.id.includes("_umlMethods")&&t.shape.interfaceShape.methods.length>0&&(s=new cm(t,"",u),t.shape.interfaceShape.methods.push(s))),"Enumeration"===t.shape.classifier&&i.id.includes("_umlMember")&&t.shape.enumerationShape.members.length>0){var f=new ob(t,"",u);t.shape.enumerationShape.members.push(f)}t.wrapper.children.indexOf(c.wrapper),this.diagram.enableServerDataBinding(!0),this.diagram.add(c),this.diagram.updateConnectorEdges(t),this.diagram.clearSelection(),this.diagram.select([this.diagram.nameTable[c.id]]),this.diagram.endGroupAction(),this.diagram.startTextEdit()}}},n}(),_oe=function(){function n(){}return n.prototype.findObjectsUnderMouse=function(t,e,i,r,s){var o=[];r&&r instanceof ti&&r.nodes.length+r.connectors.length===1&&(r=r.nodes[0]||r.connectors[0]).children&&0===r.children.length&&(i.actualObject=r);for(var a,l,h,c,p,d=r&&r instanceof de&&(r.constraints&qe.ConnectToNearByNode||r.constraints&qe.ConnectToNearByPort)&&r.connectionPadding||0,f={},g=0,v=e.spatialSearch.findObjects(new Ne(t.x-50-d,t.y-50-d,100+d,100+d));g-1&&o.splice(T,1),"UmlClassifier"===y.shape.type&&y.container&&"Stack"===y.container.type&&(T=o.indexOf(e.nameTable[e.nameTable[y.id].wrapper.children[0].id]))>-1&&o.splice(T,1)}for(var z=0;zs.zIndex&&(t[parseInt(r.toString(),10)]=l),r>0&&i&&a&&(a.isLane||a.isPhase||a.isHeader)&&t[parseInt(r.toString(),10)].zIndex=2)for(var d=t.length-1;d>=0;d--)if(t[parseInt(d.toString(),10)].parentId){var u=om(t[parseInt(d.toString(),10)],e,""),f=om(t[d-1],e,""),g=e.nameTable[""+f];g&&u!==f&&e.nameTable[""+u].zIndex=0;p--){d=Kf(e[parseInt(p.toString(),10)],!1),c=Kf(e[parseInt(p.toString(),10)],!0);var g=t[""+l].tool,v=this.findTargetElement(e[parseInt(p.toString(),10)].wrapper,o,t,void 0);if("Draw"===i&&v&&(e[parseInt(p.toString(),10)]instanceof te||e[parseInt(p.toString(),10)]instanceof de)&&!rb(e[parseInt(p.toString(),10)],v)&&(g&&"ConnectorSourceEnd"===g[""+h]&&!Ph(e[parseInt(p.toString(),10)])||g&&"ConnectorTargetEnd"===g[""+h]&&!ua(e[parseInt(p.toString(),10)])))return u;if(e[parseInt(p.toString(),10)]instanceof te||e[parseInt(p.toString(),10)]instanceof de&&(Ph(e[parseInt(p.toString(),10)])||Td(d)||ua(e[parseInt(p.toString(),10)])||kh(c)||"PortDraw"===i&&g instanceof kd&&"ConnectorTargetEnd"===g[""+h]&&(ua(e[parseInt(p.toString(),10)])||kh(c))))return u=e[parseInt(p.toString(),10)],f&&(u=this.isTarget(u,t,i)),s.actualObject=u,u}else if("ConnectorTargetEnd"===i&&a){for(p=e.length-1;p>=0;p--)if(c=Kf(e[parseInt(p.toString(),10)],!0),(e[parseInt(p.toString(),10)]instanceof te||e[parseInt(p.toString(),10)]instanceof de)&&(ua(e[parseInt(p.toString(),10)])||kh(c)))return u=e[parseInt(p.toString(),10)],u=this.isTarget(u,t,i),s.actualObject=u,u}else{if(a&&("Drag"===i||t[""+l].tool instanceof fa)){var y=0;for(p=0;p=S.zIndex?u:S,y=Math.max(y,S.zIndex)):y=(u=S).zIndex)}return u&&"Bpmn"===u.shape.type&&(t.selectedItems.nodes.length>0&&"Bpmn"===t.selectedItems.nodes[0].shape.type||(u=null)),u&&(s.actualObject=u),u}if("Select"!==i&&"Pan"!==i||!t[""+l].tool)if("Pan"===i||"LayoutAnimation"===i){for(p=e.length-1;p>=0;p--)if((e[parseInt(p.toString(),10)]instanceof te||e[parseInt(p.toString(),10)]instanceof de)&&(v=this.findTargetElement(e[parseInt(p.toString(),10)].wrapper,o,t,void 0),"Pan"===i||v&&(v.id.match("_icon_content_shape$")||v.id.match("_icon_content_rect$"))))return e[parseInt(p.toString(),10)]}else u=e[e.length-1],s&&u&&(s.actualObject=u);else{for(p=e.length-1;p>=0;p--)if(e[parseInt(p.toString(),10)]instanceof de){var b=e[p-1];if(e[p-1]instanceof te&&b.ports){if((v=this.findTargetElement(b.wrapper,o,t,void 0))&&(v.id.match("_icon_content_shape$")||v.id.match("_icon_content_rect$")))return b;for(var M=0;M=0;s--){var o=t.children[parseInt(s.toString(),10)];if(o&&o.outerBounds.containsPoint(e,r||0))if(o.visible){if(o instanceof Cs){var a=this.findTargetElement(o,e,i);if(a)return a}var l="Clip"===o.style.textOverflow||"Ellipsis"===o.style.textOverflow;if(o.bounds.containsPoint(e,r||0)&&!l)return o;if(t.bounds.containsPoint(e,r||0)&&l)return o}else if(o instanceof Ze&&t&&t.id){var h=void 0;if(t.id.includes("group_container")){var c=t.id.slice(0,-15);h=i.getObject(c)}else h=i.getObject(t.id);if(tb(h,o.id))return o}}return t.bounds.containsPoint(e,r)&&"none"!==t.style.fill?t:null},n}(),Uoe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),sp=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},JF=function(n){function t(e,i,r,s){var o=n.call(this,e,i,r,s)||this;return o.objectZIndex=-1,o.zIndexTable={},o.objects=[],o}return Uoe(t,n),sp([I("")],t.prototype,"id",void 0),sp([I(!0)],t.prototype,"visible",void 0),sp([I(!1)],t.prototype,"lock",void 0),sp([I()],t.prototype,"objects",void 0),sp([I()],t.prototype,"addInfo",void 0),sp([I(-1)],t.prototype,"zIndex",void 0),t}(Ee),MT=function(n,t,e,i){return new(e||(e=Promise))(function(r,s){function o(h){try{l(i.next(h))}catch(c){s(c)}}function a(h){try{l(i.throw(h))}catch(c){s(c)}}function l(h){h.done?r(h.value):new e(function(c){c(h.value)}).then(o,a)}l((i=i.apply(n,t||[])).next())})},wT=function(n,t){var i,r,s,o,e={label:0,sent:function(){if(1&s[0])throw s[1];return s[1]},trys:[],ops:[]};return o={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function a(h){return function(c){return function l(h){if(i)throw new TypeError("Generator is already executing.");for(;e;)try{if(i=1,r&&(s=2&h[0]?r.return:h[0]?r.throw||((s=r.return)&&s.call(r),0):r.next)&&!(s=s.call(r,h[1])).done)return s;switch(r=0,s&&(h=[2&h[0],s.value]),h[0]){case 0:case 1:s=h;break;case 4:return e.label++,{value:h[1],done:!1};case 5:e.label++,r=h[1],h=[0];continue;case 7:h=e.ops.pop(),e.trys.pop();continue;default:if(!(s=(s=e.trys).length>0&&s[s.length-1])&&(6===h[0]||2===h[0])){e=0;continue}if(3===h[0]&&(!s||h[1]>s[0]&&h[1]1)for(var i=0;i-1)return e[parseInt(i.toString(),10)];return this.diagram.activeLayer},n.prototype.getLayer=function(t){for(var e=this.diagram.layers,i=0;i=0;o--)this.diagram.unSelect(this.diagram.nameTable[s[parseInt(o.toString(),10)]]),this.diagram.remove(this.diagram.nameTable[s[parseInt(o.toString(),10)]]),"default_layer"!==i.id&&this.diagram.activeLayer.id===t&&(this.diagram.activeLayer=this.diagram.layers[this.diagram.layers.length-1]);delete this.diagram.layerZIndexTable[i.zIndex],this.diagram.layers.splice(r,1),"SVG"!==this.diagram.mode&&this.diagram.refreshDiagramLayer()}},n.prototype.moveObjects=function(t,e){this.diagram.startGroupAction();for(var i={},r=[],s=0;s-1){if(r=[],(h=this.diagram.nameTable[""+s]).children)for(var p=0,g=h.children;p0){for(var y=void 0,S=0,b=r;S0)for(var r=0;r0)for(r=0;r0){t=t.concat(this.diagram.selectedItems.connectors);for(var i=0;i0)for(t=t.concat(this.diagram.selectedItems.nodes),i=0;i0){for(var i=0,r=t.shape.activity.subProcess.processes;i0&&this.copyProcesses(this.processTable[""+s])}this.clipboardData.processTable=this.processTable}},n.prototype.group=function(){this.oldSelectedObjects=nm(this.diagram);var e=this.diagram.isProtectedOnChange;this.diagram.protectPropertyChange(!0),this.diagram.diagramActions=this.diagram.diagramActions|ee.Group;var r={};r.id="group"+Qe(),(r=new te(this.diagram,"nodes",r,!0)).children=[];for(var s=this.diagram.selectedItems.nodes.concat(this.diagram.selectedItems.connectors).sort(function(h,c){return h.zIndex-c.zIndex}),o=0;o0){var a=this.diagram.add(r);a&&this.select(a),this.addHistoryEntry({type:"Group",undoObject:r,redoObject:r,category:"Internal"}),this.diagram.diagramActions=this.diagram.diagramActions&~ee.Group,this.diagram.protectPropertyChange(e)}},n.prototype.unGroup=function(t){var i=this.diagram.isProtectedOnChange;this.diagram.protectPropertyChange(!0),this.diagram.diagramActions=this.diagram.diagramActions|ee.Group;var r=[];t?r.push(t):r=this.diagram.selectedItems.nodes,this.diagram.startGroupAction();for(var s=0;s0&&this.diagram.removePorts(o,o.ports),o.annotations&&o.annotations.length>0&&!ce()&&this.diagram.removeLabels(o,o.annotations);for(var c=this.diagram.nameTable[o.parentId],d=o.children.length-1;d>=0;d--)this.diagram.nameTable[o.children[parseInt(d.toString(),10)]].parentId="",this.diagram.deleteChild(this.diagram.nameTable[o.children[parseInt(d.toString(),10)]],o),o.parentId&&o.children[parseInt(d.toString(),10)]&&this.diagram.addChild(c,o.children[parseInt(d.toString(),10)]);this.resetDependentConnectors(o.inEdges,!0),this.resetDependentConnectors(o.outEdges,!1),this.diagram.diagramActions&ee.UndoRedo||this.addHistoryEntry({type:"UnGroup",undoObject:a,redoObject:a,category:"Internal"}),o.parentId&&this.diagram.deleteChild(o,c)}this.diagram.removeNode(o,l),this.clearSelection()}this.diagram.endGroupAction(),this.diagram.diagramActions=this.diagram.diagramActions&~ee.Group,this.diagram.protectPropertyChange(i)},n.prototype.resetDependentConnectors=function(t,e){for(var i=0;i0&&(g=!1)}if(g){var y=this.cloneConnector(f,i);c.push(y),o[h.id]=y.id}}else{var S=this.cloneNode(h,i);if(c.push(S),S){o[h.id]=S.id;var b=h.inEdges;if(b)for(var M=0,w=b;M0)for(var u=0;u0)for(r=t.segments,s=0;s0&&this.diagram.drawingObject&&"Bezier"===this.diagram.drawingObject.type&&(t.segments=[]);var e=this.diagram.add(t);"SVG"!==this.diagram.mode&&this.diagram.refreshDiagramLayer(),this.selectObjects([e]),t&&!zI(this.diagram)&&(this.diagram.tool&=~ni.DrawOnce,this.diagram.currentDrawingObject=void 0)},n.prototype.enableServerDataBinding=function(t){this.diagram.enableServerDataBinding(t)},n.prototype.addText=function(t,e){var i=this.diagram.findElementUnderMouse(t,e,this.diagram);this.diagram.startTextEdit(t,i instanceof li?i.id.split("_")[1]:void 0)},n.prototype.isUserHandle=function(t){var e=this.diagram.selectedItems;if(e.wrapper&&qr(e.constraints,"UserHandle"))for(var i=0,r=e.userHandles;i0&&t[0]&&t[0].isLane)for(s=this.diagram.getObject(t[0].parentId),t[0].shape.header=[],a=0;a1||e&&1===t.length)){if(1!==t.length)return[2];this.clearSelection()}if(!(u||d||1!==t.length||e&&$a(this.diagram)))return this.clearSelection(),[2]}if(!r.cancel){for(f=0;f0||e)&&p.children&&!p.parentId)for(g=0;g0||e,!0)}else this.select(p,f>0||e,!0);void 0===i&&(i=c),r={oldValue:i||[],newValue:this.getSelectedObject(),cause:this.diagram.diagramActions,state:"Changed",type:"Addition",cancel:!1},this.diagram.renderSelector(e||t&&t.length>1),ce()||this.diagram.triggerEvent(Ce.selectionChange,r),this.diagram.enableServerDataBinding(!0)}return[2]})})},n.prototype.findParent=function(t){return t.parentId&&this.findParent(t=this.diagram.nameTable[t.parentId]),t},n.prototype.selectProcesses=function(t){if(this.hasProcesses(t))for(var e=t.shape.activity.subProcess.processes,i=0;i0)},n.prototype.select=function(t,e,i){var r=this.getObjectLayer(t.id);if(xd(t)&&!(t instanceof ti)&&!_r(this.diagram,t)&&r&&!r.lock&&r.visible&&t.wrapper.visible){(e=!!$a(this.diagram)&&e)||this.clearSelection(),this.diagram.enableServerDataBinding(!1);var s=this.diagram.selectedItems;if(t instanceof te?s.nodes.push(t.isHeader?this.diagram.nameTable[t.parentId]:t):s.connectors.push(t),s.selectedObjects.push(t),e)s.wrapper.rotateAngle=s.rotateAngle=0,s.wrapper.children.push(t.wrapper);else if(s.init(this.diagram),1===s.nodes.length&&0===s.connectors.length){var l=Ux(this.diagram,s);l&&(s.wrapper.children[0]=l),s.rotateAngle=s.nodes[0].rotateAngle,s.wrapper.rotateAngle=s.nodes[0].rotateAngle,s.wrapper.pivot=s.nodes[0].pivot}i||this.diagram.renderSelector(e),this.diagram.enableServerDataBinding(!0)}},n.prototype.labelSelect=function(t,e){this.oldSelectedObjects=nm(this.diagram);var i=this.diagram.selectedItems,r=this.diagram.allowServerDataBinding;this.diagram.allowServerDataBinding=!1,i.nodes=i.connectors=[],this.diagram.allowServerDataBinding=r,t instanceof te?i.nodes[0]=t:i.connectors[0]=t,i.annotation=this.findTarget(e,t),i.init(this.diagram),this.diagram.renderSelector(!1)},n.prototype.unSelect=function(t){var e=this.diagram.selectedItems.nodes.concat(this.diagram.selectedItems.connectors),i=e.filter(function(a){return a.id!==t.id}),r={oldValue:e,newValue:i,cause:this.diagram.diagramActions,state:"Changing",type:"Removal",cancel:!1};if(this.diagram.currentSymbol||ce()||this.diagram.triggerEvent(Ce.selectionChange,r),_r(this.diagram,t)){var s=this.diagram.selectedItems,o=void 0;t instanceof te?(o=s.nodes.indexOf(t,0),s.nodes.splice(o,1)):(o=s.connectors.indexOf(t,0),s.connectors.splice(o,1)),o=s.selectedObjects.indexOf(t,0),s.selectedObjects.splice(o,1),(r={oldValue:e,newValue:i,cause:this.diagram.diagramActions,state:"Changed",type:"Removal",cancel:(r={oldValue:e,newValue:i,cause:this.diagram.diagramActions,state:"Changed",type:"Removal",cancel:!1}).cancel}).cancel||(o=s.wrapper.children.indexOf(t.wrapper,0),s.wrapper.children.splice(o,1),this.diagram.updateSelector(),this.diagram.currentSymbol||this.diagram.triggerEvent(Ce.selectionChange,r))}},n.prototype.moveSvgNode=function(t,e){var i=this.diagram.nameTable[""+e];if("Native"===i.shape.type||"HTML"===i.shape.type)this.updateNativeNodeIndex(t,e);else{var r=xt(e+"_groupElement",this.diagram.element.id),s=xt(t+"_groupElement",this.diagram.element.id);r.parentNode.insertBefore(s,r)}},n.prototype.moveAfterSvgNode=function(t,e){var i=this.diagram.nameTable[""+e];if(!i||"HTML"!==i.shape.type&&"Native"!==i.shape.type)a=xt(e+"_groupElement",this.diagram.element.id),o=xt(t+"_groupElement",this.diagram.element.id),a.insertAdjacentElement("afterend",o);else for(var r=0;rd&&"SwimLane"!==p.shape.type){var S=$(p);p.zIndex=d-((-1!==i.indexOf(p)?i.indexOf(p):0)+1),p.children&&(d=this.findLowestZIndex(p,c)||d),this.triggerOrderCommand(S,p,p),p.children&&this.updateGroupZindex(p,"SendToBack",d)}else"SwimLane"===p.shape.type&&(y=this.swapZIndexObjects(a,h,r,g));if("SVG"===this.diagram.mode){for(var M="SwimLane"!==this.diagram.nameTable[""+r].shape.type?d:y,w=h[parseInt(M.toString(),10)];!w&&Md)&&(d=f.zIndex)}for(var p=JSON.parse(JSON.stringify(l)),v=Number(Object.keys(l).sort(function(wo,Ul){return Number(wo)-Number(Ul)}).reverse()[0]),y=this.diagram.nameTable[""+e].zIndex,S=[],M=0;M<=v;M++)S.push(l[parseInt(M.toString(),10)]);if("SwimLane"===this.diagram.nameTable[""+e].shape.type)for(var C=v;C>=y;C--)if(l[parseInt(C.toString(),10)]&&this.diagram.nameTable[l[parseInt(C.toString(),10)]].parentId!==e){v=C;break}var D=this.diagram.nameTable[""+e];if(D.zIndexx&&(x=L.zIndex)}}else x=d;D.zIndex=x+((-1!==r.indexOf(D)?r.indexOf(D):0)+1),this.triggerOrderCommand(A,D,D)}else if("SwimLane"===D.shape.type){for(var O=0,N=-1,T=0,z=0,U=JSON.parse(JSON.stringify(l)),B=0;B<=y;B++)if(l[parseInt(B.toString(),10)]&&this.diagram.nameTable[l[parseInt(B.toString(),10)]].parentId===e&&-1===N){N=B,T=B;break}for(var j=0;j<=v;j++)p[parseInt(j.toString(),10)]&&p[parseInt(j.toString(),10)]!==e&&this.diagram.nameTable[p[parseInt(j.toString(),10)]].parentId!==e&&this.diagram.nameTable[p[parseInt(j.toString(),10)]].zIndex>=this.diagram.nameTable[""+e].zIndex&&O++;for(var ue=N,fe=0;fe<=O;fe++){for(;!l[parseInt(ue.toString(),10)];)ue++;z=this.diagram.nameTable[l[parseInt(ue.toString(),10)]].zIndex,ue++}for(var Me=z;Me<=v;Me++){for(;!U[parseInt(N.toString(),10)];)N++;for(;!l[parseInt(Me.toString(),10)];)Me++;l[parseInt(Me.toString(),10)]=U[parseInt(N.toString(),10)],this.diagram.nameTable[l[parseInt(Me.toString(),10)]].zIndex=Me,N++}l[parseInt(v.toString(),10)]=this.diagram.nameTable[""+e].id,this.diagram.nameTable[""+e].zIndex=v,ue=y+1;for(var De=T,xe=0;xe0&&("Native"===hr[0].shape.type||"HTML"===hr[0].shape.type)){for(Ci.parentNode.removeChild(Ci),De=0;De0?r[0]:null},n.prototype.findLowestZIndex=function(t,e){var r=this.diagram.nodes.filter(function(s){return-1!==e.indexOf(s.id)}).filter(function(s){return""===s.parentId&&s.id!==t.id}).map(function(s){return s.zIndex});return r.sort(function(s,o){return s-o}),r.length>0?r[0]:null},n.prototype.triggerOrderCommand=function(t,e,i){var s={zIndex:$(t).zIndex},o={zIndex:e.zIndex},a={element:i,cause:this.diagram.diagramActions,diagramAction:this.diagram.getDiagramAction(this.diagram.diagramActions),oldValue:s,newValue:o};this.diagram.triggerEvent(Ce.propertyChange,a)},n.prototype.checkGroupNode=function(t,e,i){return i[""+e].parentId===i[""+t].parentId},n.prototype.sortByZIndex=function(t,e,i){if("BringForward"===i){var r=e||"zIndex";t=t.sort(function(o,a){return a[""+r]-o[""+r]})}else{var s=e||"zIndex";t=t.sort(function(o,a){return o[""+s]-a[""+s]})}return t},n.prototype.orderCommands=function(t,e,i){var r=this,s=e.nodes;if(s=s.concat(e.connectors),t)if("SendBackward"===i)for(var o=0;oa}),S=v.filter(function(D){return D0?Math.max.apply(Math,S):a,M=y.length>0?Math.min.apply(Math,y):a;if(a!==M){var w=c.zIndexTable[parseInt(M.toString(),10)],C=c.zIndexTable[parseInt(a.toString(),10)];this.moveSvgNode(C,w)}else"SendToBack"===i&&(w=c.zIndexTable[parseInt(a.toString(),10)],C=c.zIndexTable[parseInt(b.toString(),10)],this.moveAfterSvgNode(w,C))}}else this.diagram.refreshCanvasLayers()}},n.prototype.swapDomOrder=function(t,e){if(t){var i=this.diagram.getObject(e);if("Native"===i.shape.type||"HTML"===i.shape.type)this.updateNativeNodeIndex(e,t),this.updateNativeNodeIndex(t,e);else{var r=xt(e+"_groupElement",this.diagram.element.id),s=xt(t+"_groupElement",this.diagram.element.id);r.parentNode.insertBefore(r,s),r.parentNode.insertBefore(s,r)}}},n.prototype.sendForward=function(t){var e=this;if(this.diagram.protectPropertyChange(!0),$a(this.diagram)||t){$(t||(this.diagram.selectedItems.nodes.length?this.diagram.selectedItems.nodes[0]:this.diagram.selectedItems.connectors[0]));var s=t&&t.id,o=this.diagram.layers.indexOf(this.getObjectLayer(s=s||(this.diagram.selectedItems.nodes.length?this.diagram.selectedItems.nodes[0].id:this.diagram.selectedItems.connectors[0].id))),a=$(this.diagram.nameTable),h=(parseInt(o.toString(),10),this.diagram.nameTable[""+s]),c=[],d=this.diagram.spatialSearch.findObjects(h.wrapper.bounds);d.length>2&&(d=this.sortByZIndex(d,void 0,"BringForward"));for(var u=0,f=d;u=0;p--)this.diagram.nameTable[c[parseInt(p.toString(),10)].id].parentId===s&&c.splice(p,1);if(c.length>0){var y=this.diagram.nameTable[c[c.length-1].id];if(y.parentId){var b=om(y,this.diagram,""),M=this.diagram.nameTable[""+b];M.id!==s&&(c[0]=M)}var w={};for(p=0;p0&&(Object.values(O).forEach(function(ue){ue>=T&&N.push(ue)}),0!==N.length&&this.updateZIndexBySendForward(h,N,o))}var z=[];if(Object.keys(this.changedNodeZIndexes).forEach(function(ue){if((a[""+ue]?a[""+ue].zIndex:null)!==e.changedNodeZIndexes[""+ue]){var De=$(a[""+ue]);z.push(De)}}),this.updateLayerZindexTable(o),L.nodes.splice(0,L.nodes.length),z.forEach(function(ue){var fe=$(ue);L.nodes.push(fe)}),"SVG"===this.diagram.mode){var U=c[c.length-1].id,B=c[c.length-1];B&&!("HTML"===B.shape.type||"Native"===B.shape.type)&&this.moveAfterSvgNode(s,U),this.updateNativeNodeIndex(U,s)}else this.diagram.refreshCanvasLayers();var j=[];Object.keys(this.changedNodeZIndexes).forEach(function(ue){if((a[""+ue]?a[""+ue].zIndex:null)!==e.changedNodeZIndexes[""+ue]){var De=$(e.diagram.nameTable[""+ue]);j.push(De)}});var Q=$(this.diagram.selectedItems);Q.nodes.splice(0,Q.nodes.length),j.forEach(function(ue){var fe=$(ue);Q.nodes.push(fe)}),this.diagram.diagramActions&ee.UndoRedo||this.addHistoryEntry({type:"SendForward",category:"Internal",undoObject:L,redoObject:Q}),this.diagram.endGroupAction()}}this.diagram.protectPropertyChange(!1)},n.prototype.updateZIndexBySendForward=function(t,e,i){var r=$(t);t.zIndex=Math.min.apply(Math,e);var a,s=Math.min.apply(Math,e),o=Math.min.apply(Math,e),l=this.diagram.layers[parseInt(i.toString(),10)].objects,h=this.diagram.nodes.filter(function(S){return-1!==l.indexOf(S.id)});t.children&&this.updateGroupZindex(t,"BringForward",t.zIndex);var c=h.filter(function(S){return S.zIndex===Math.min.apply(Math,e)&&S.id!==t.id});if(c&&c.length>0&&c[0].children){for(var d=Math.min.apply(Math,e),u=0;uo&&g!==t&&g.parentId!==t.id&&c&&c.length>0&&g.parentId!==c[0].id){var v=$(g);g.zIndex=a+1,a++,this.triggerOrderCommand(v,g,g)}var y=g.zIndex;this.changedNodeZIndexes[g.id]=(this.changedNodeZIndexes.hasOwnProperty(g.id),y)}},n.prototype.arrangeZIndexForLowerNodes=function(t,e,i){var r=i.filter(function(o){return o.zIndex<=t&&o.parentId!==e.id});r.sort(function(o,a){return a.zIndex-o.zIndex});for(var s=0;se&&(e=r.zIndex)}return e},n.prototype.sendBackward=function(t){var e=this;if(this.diagram.protectPropertyChange(!0),$a(this.diagram)||t){$(t||(this.diagram.selectedItems.nodes.length?this.diagram.selectedItems.nodes[0]:this.diagram.selectedItems.connectors[0]));var s=t&&t.id,o=this.diagram.layers.indexOf(this.getObjectLayer(s=s||(this.diagram.selectedItems.nodes.length?this.diagram.selectedItems.nodes[0].id:this.diagram.selectedItems.connectors[0].id))),a=$(this.diagram.nameTable),h=(parseInt(o.toString(),10),this.diagram.nameTable[""+s]),c=[],d=this.diagram.spatialSearch.findObjects(h.wrapper.bounds);d.length>2&&(d=this.sortByZIndex(d));for(var u=0,f=d;uNumber(p.zIndex)&&""===p.parentId&&h.wrapper.bounds.intersects(p.wrapper.bounds)&&c.push(p);for(var p=c.length-1;p>=0;p--)(v=this.diagram.nameTable[c[parseInt(p.toString(),10)].id]).parentId===s&&c.splice(p,1);if(c.length>0){var v;if((v=this.diagram.nameTable[c[c.length-1].id]).parentId){var S=om(v,this.diagram,""),b=this.diagram.nameTable[""+S];s!==b.id&&(c[c.length-1]=b)}var M={};for(p=0;p0&&(Object.values(L).forEach(function(fe){fe<=N&&O.push(fe)}),0!==O.length&&this.updateZIndexBySendBackward(h,O,o))}var T=[];if(Object.keys(this.changedNodeZIndexes).forEach(function(fe){if((a[""+fe]?a[""+fe].zIndex:null)!==e.changedNodeZIndexes[""+fe]){var xe=$(a[""+fe]);T.push(xe)}}),this.updateLayerZindexTable(o),P.nodes.splice(0,P.nodes.length),T.forEach(function(fe){var Me=$(fe);P.nodes.push(Me)}),"SVG"===this.diagram.mode){var z=c[c.length-1].id,U=c[c.length-1];U&&"HTML"!==U.shape.type&&"Native"!==U.shape.type&&this.moveSvgNode(s,z);var B=this.diagram.nameTable[""+z];B.children&&B.children.length>0?this.updateNativeNodeIndex(s):this.updateNativeNodeIndex(s,z)}else this.diagram.refreshCanvasLayers();var j=[];Object.keys(this.changedNodeZIndexes).forEach(function(fe){if((a[""+fe]?a[""+fe].zIndex:null)!==e.changedNodeZIndexes[""+fe]){var xe=$(e.diagram.nameTable[""+fe]);j.push(xe)}});var Q=$(this.diagram.selectedItems);Q.nodes.splice(0,Q.nodes.length),j.forEach(function(fe){var Me=$(fe);Q.nodes.push(Me)}),this.diagram.diagramActions&ee.UndoRedo||this.addHistoryEntry({type:"SendBackward",category:"Internal",undoObject:P,redoObject:Q}),this.diagram.endGroupAction()}}this.diagram.protectPropertyChange(!1)},n.prototype.updateZIndexBySendBackward=function(t,e,i){var r=$(t);t.zIndex=Math.max.apply(Math,e);var f,s=t.zIndex,o=Math.max.apply(Math,e),a=this.diagram.layers[parseInt(i.toString(),10)].objects,l=this.diagram.nodes.filter(function(S){return-1!==a.indexOf(S.id)}),h=l.filter(function(S){return S.zIndex===Math.max.apply(Math,e)&&S.id!==t.id});if(h&&h.length>0&&h[0].children)for(var c=Math.max.apply(Math,e),d=0;d0&&g.parentId!==h[0].id){var v=$(g);g.zIndex=f-1,f--,this.triggerOrderCommand(v,g,g)}var y=g.zIndex;this.changedNodeZIndexes[""+g.id]=(this.changedNodeZIndexes.hasOwnProperty(g.id),y)}},n.prototype.findLowestChildZIndex=function(t){for(var e=t.zIndex,i=0;i0),this.selectObjects([t],!0))},n.prototype.clearSelection=function(t,e){return MT(this,void 0,void 0,function(){var i,r,s,o;return wT(this,function(a){return i=this.diagram.allowServerDataBinding,this.diagram.enableServerDataBinding(!1),$a(this.diagram)&&(r=this.diagram.selectedItems,s=this.getSelectedObject(),this.diagram.currentSymbol&&(this.diagram.previousSelectedObject=s),o={oldValue:s,newValue:[],cause:this.diagram.diagramActions,state:"Changing",type:"Removal",cancel:!1},t&&(ce()||this.diagram.triggerEvent(Ce.selectionChange,o)),o.cancel||(r.offsetX=0,r.offsetY=0,r.width=0,r.height=0,r.rotateAngle=0,r.nodes=[],r.connectors=[],r.wrapper=null,r.annotation=void 0,r.selectedObjects=[],this.diagram.clearSelectorLayer(),t&&(o={oldValue:s,newValue:[],cause:this.diagram.diagramActions,state:"Changed",type:"Removal",cancel:!1},ce()||this.diagram.triggerEvent(Ce.selectionChange,o))),this.diagram.enableServerDataBinding(i)),[2]})})},n.prototype.clearSelectedItems=function(){this.clearSelection((this.diagram.selectedItems.nodes?this.diagram.selectedItems.nodes.length:0)+(this.diagram.selectedItems.connectors?this.diagram.selectedItems.connectors.length:0)>0)},n.prototype.removeStackHighlighter=function(){var t=Bl(this.diagram.element.id),e=t.getElementById(t.id+"_stack_highlighter");e&&e.parentNode.removeChild(e)},n.prototype.renderStackHighlighter=function(t,e){var r,s,o,i=this.diagram.selectedItems.nodes[0];if(!e){var a=this.diagram.findObjectsUnderMouse(t.position);if((e=this.diagram.findObjectUnderMouse(a,"Drag",!0))&&!(e.isLane||e.isPhase||e.isHeader))for(var l=0;l0)for(var a=0;a1)if(i){var h=l.segments[0],c=l.segments[1],u=Nl(CI(t.wrapper,t.wrapper.corners,t.wrapper.bounds),h.direction),g=Ol({corners:void 0,point:u=qa(l,0,u,{x:l.sourceWrapper.offsetX,y:l.sourceWrapper.offsetY},!1),margin:void 0,direction:h.direction},{corners:void 0,point:c.points[1],margin:void 0,direction:void 0});h.length=R.distancePoints(g[0],g[1]),c.direction&&c.length&&(c.length=R.distancePoints(g[1],g[2]))}else if(o){switch(l.segments[0].direction){case"Bottom":r=t.wrapper.bounds.bottomCenter.x-e.bottomCenter.x,s=t.wrapper.bounds.bottomCenter.y-e.bottomCenter.y;break;case"Top":r=t.wrapper.bounds.topCenter.x-e.topCenter.x,s=t.wrapper.bounds.topCenter.y-e.topCenter.y;break;case"Left":r=t.wrapper.bounds.middleLeft.x-e.middleLeft.x,s=t.wrapper.bounds.middleLeft.y-e.middleLeft.y;break;case"Right":r=t.wrapper.bounds.middleRight.x-e.middleRight.x,s=t.wrapper.bounds.middleRight.y-e.middleRight.y}this.dragSourceEnd(l,r,s,!0,null,"ConnectorSourceEnd",void 0,void 0,void 0,!(t.parentId&&this.diagram.diagramActions&ee.isGroupDragging))}}},n.prototype.updateEndPoint=function(t,e){var r={sourcePoint:t.sourcePoint,targetPoint:t.targetPoint};t.sourceID&&(r.sourceID=t.sourceID),t.targetID&&(r.targetID=t.targetID),t.sourcePortID&&(r.sourcePortID=t.sourcePortID),t.targetPortID&&(r.targetPortID=t.targetPortID),t.segments&&(r.segments=t.segments),this.diagram.connectorPropertyChange(t,e||{},r),this.diagram.updateSelector()},n.prototype.dragSourceEnd=function(t,e,i,r,s,o,a,l,h,c,d){var u=this.diagram.nameTable[t.id],f={},p=this.checkBoundaryConstraints(e,i,u.wrapper.bounds);if(AI(u)&&p&&"BezierSourceThumb"!==o&&Vv(this.diagram)&&(f=$(f={sourcePoint:u.sourcePoint}),u.sourcePoint.x+=e,u.sourcePoint.y+=i,"ConnectorSourceEnd"===o&&"Orthogonal"===u.type&&this.changeSegmentLength(u,l,h,c),"Bpmn"===u.shape.type&&"Default"===u.shape.sequence&&"Sequence"===u.shape.flow&&this.updatePathElementOffset(u)),"Bezier"===u.type)if(f={sourcePoint:u.sourcePoint},d)this.translateBezierPoints(t,""===o?"ConnectorSourceEnd":o,e,i,d,s,!a);else for(var g=0;g2){var d=R.direction((c=t.segments[2]).points[0],c.points[1]);o.direction===_n(d)?("Right"===o.direction?c.points[0].x=o.points[o.points.length-1].x=l.wrapper.corners.middleRight.x+20:"Left"===o.direction?c.points[0].x=o.points[o.points.length-1].x=l.wrapper.corners.middleLeft.x-20:c.points[0].y=o.points[o.points.length-1].y="Top"===o.direction?l.wrapper.corners.topCenter.y-20:l.wrapper.corners.bottomCenter.y+20,c.direction&&c.length&&(c.length=R.distancePoints(c.points[0],c.points[c.points.length-1])),o.length=R.distancePoints(o.points[0],o.points[o.points.length-1])):o.direction===d&&c.direction&&c.length?("Top"===o.direction||"Bottom"===o.direction?(c.points[0]=o.points[0],c.points[c.points.length-1].x=c.points[0].x):(c.points[0]=o.points[0],c.points[c.points.length-1].y=c.points[0].y),c.length=R.distancePoints(c.points[0],c.points[c.points.length-1]),t.segments.splice(0,2)):o.length=20}else o.length=20;else if(o.length<1)if(""!==t.sourceID){var c;"Right"===a.direction?a.points[a.points.length-1].y=(h=l.wrapper.corners.middleRight).y:"Left"===a.direction?a.points[a.points.length-1].y=(h=l.wrapper.corners.middleLeft).y:a.points[a.points.length-1].x="Top"===a.direction?(h=l.wrapper.corners.topCenter).x:(h=l.wrapper.corners.bottomCenter).x,a.length=R.distancePoints(h,a.points[a.points.length-1]),t.segments.length>2&&(c=t.segments[2]).direction&&c.length&&(c.length=R.distancePoints(a.points[a.points.length-1],c.points[c.points.length-1])),t.segments.splice(0,1)}else t.segments.splice(0,1)}else e&&!i&&t.sourceID!==e.id&&t.segments&&null!==t.segments[0].direction&&e&&e instanceof te&&s&&this.changeSourceEndToNode(t,e),e&&i&&t.sourcePortID!==i&&t.segments&&null!==t.segments[0].direction&&e&&e instanceof te&&s&&this.changeSourceEndToPort(t,e,i)},n.prototype.canConnect=function(t,e){return!(!ua(e)||!Ph(e))},n.prototype.changeSourceEndToPort=function(t,e,i){var r=this.diagram.getWrapper(e.wrapper,i),s={x:r.offsetX,y:r.offsetY},o=zo(s,xn(e.wrapper),e.wrapper.bounds),a=t.segments[0],l=t.segments[1];if(a.direction!==o){var h=[],c={};if(a.direction===_n(o)){c={};var d=void 0;"Top"===o||"Bottom"===o?(d="Top"===o?{type:"Orthogonal",isTerminal:!0,direction:o,length:Math.abs(a.points[0].y-s.y)}:{type:"Orthogonal",isTerminal:!0,direction:o,length:Math.abs(s.y-a.points[0].y)},c=a.points[0].x>s.x?{type:"Orthogonal",isTerminal:!0,direction:"Right",length:a.points[0].x-s.x}:{type:"Orthogonal",isTerminal:!0,direction:"Left",length:s.x-a.points[0].x}):(d="Right"===o?{type:"Orthogonal",isTerminal:!0,direction:o,length:Math.abs(a.points[0].x-s.x)}:{type:"Orthogonal",isTerminal:!0,direction:o,length:Math.abs(s.x-a.points[0].x)},c=a.points[0].y>s.y?{type:"Orthogonal",direction:"Top",isTerminal:!0,length:a.points[0].y-s.y}:{type:"Orthogonal",direction:"Bottom",isTerminal:!0,length:s.y-a.points[0].y}),h.push(new wi(t,"segments",d,!0)),h.push(new wi(t,"segments",c,!0))}else h.push(new wi(t,"segments",c={type:"Orthogonal",direction:o,length:20,isTerminal:!0},!0));a.direction!==_n(o)&&("Top"===o||"Bottom"===o?(a.points[0].x=s.x,a.points[0].y=a.points[a.points.length-1].y="Top"===o?s.y-20:s.y+20):(a.points[0].y=s.y,a.points[0].x=a.points[a.points.length-1].x="Right"===o?s.x+20:s.x-20),a.length=R.distancePoints(a.points[0],a.points[a.points.length-1]),l.length=R.distancePoints(a.points[a.points.length-1],l.points[l.points.length-1])),t.segments=h.concat(t.segments)}else a.points[0]=s,"Top"===o||"Bottom"===o?a.points[a.points.length-1].x=s.x:a.points[a.points.length-1].y=s.y,a.length=R.distancePoints(a.points[0],a.points[a.points.length-1]),l.length=R.distancePoints(a.points[a.points.length-1],l.points[l.points.length-1])},n.prototype.removeTerminalSegment=function(t,e){for(var i=0;ii.width||"Left"===o.direction&&r.x>=o.points[0].x||"Right"===o.direction&&r.x<=o.points[0].x)o.points[0].y=o.points[o.points.length-1].y=r.y,o.points[0].x=r.x,o.length=R.distancePoints(o.points[0],o.points[o.points.length-1]),a.length=R.distancePoints(o.points[o.points.length-1],a.points[a.points.length-1]);else{var h=void 0;s="Bottom"===(h=a.direction?a.direction:R.direction(a.points[0],a.points[a.points.length-1]))?i.bottomCenter:i.topCenter,a.length&&a.direction&&(a.length="Top"===h?o.points[o.points.length-1].y-(s.y+20):s.y+20-o.points[o.points.length-1].y),o.length=o.points[o.points.length-1].x-s.x,o.direction=o.length>0?"Right":"Left",l.push(new wi(t,"segments",{type:"Orthogonal",direction:h,length:20},!0)),t.segments=l.concat(t.segments)}else r="Bottom"===o.direction?i.bottomCenter:i.topCenter,o.length>i.height||"Top"===o.direction&&r.y>=o.points[0].y||"Bottom"===o.direction&&r.y<=o.points[0].y?(o.points[0].x=o.points[o.points.length-1].x=r.x,o.points[0].y=r.y,o.length=R.distancePoints(o.points[0],o.points[o.points.length-1]),a.length=R.distancePoints(o.points[o.points.length-1],a.points[a.points.length-1])):(s="Left"===a.direction?i.middleLeft:i.middleRight,h=void 0,h=a.direction?a.direction:R.direction(a.points[0],a.points[a.points.length-1]),a.length&&a.direction&&(a.length="Left"===h?o.points[o.points.length-1].x-(s.x+20):s.x+20-o.points[o.points.length-1].x),o.length=o.points[o.points.length-1].y-s.y,o.direction=o.length>0?"Bottom":"Top",l.push(new wi(t,"segments",{type:"Orthogonal",direction:h,length:20},!0)),t.segments=l.concat(t.segments))},n.prototype.translateBezierPoints=function(t,e,i,r,s,o,a){var l=t.segments.indexOf(s),h=t.segments[parseInt(l.toString(),10)],c=l>0?t.segments[l-1]:null,d=null!==c?c.point:t.sourcePoint,u=l===t.segments.length-1?t.targetPoint:h.point;if(h)if("BezierSourceThumb"===e&&(h.vector1.angle||h.vector1.distance)){var f=h.vector1.distance,p=h.vector1.angle;h.vector1={distance:t.distance(d,o),angle:R.findAngle(d,o)},this.translateSubsequentSegment(t,s,!0,h.vector1.distance-f,h.vector1.angle-p)}else"BezierTargetThumb"===e&&(h.vector2.angle||h.vector2.distance)?(f=h.vector2.distance,p=h.vector2.angle,h.vector2={distance:t.distance(u,o),angle:R.findAngle(u,o)},this.translateSubsequentSegment(t,s,!1,h.vector2.distance-f,h.vector2.angle-p)):("ConnectorSourceEnd"===e&&!t.sourceID||"ConnectorTargetEnd"===e&&!t.targetID)&&a&&GI(h.vector1)&&GI(h.vector2)?(R.isEmptyPoint(h.point1)&&(h.bezierPoint1=XI(t.sourcePoint,t.targetPoint)),R.isEmptyPoint(h.point2)&&(h.bezierPoint2=XI(t.targetPoint,t.sourcePoint))):"BezierSourceThumb"===e||"ConnectorSourceEnd"===e&&!a&&GI(h.vector1)?(h.bezierPoint1.x+=i,h.bezierPoint1.y+=r,(!R.isEmptyPoint(h.point1)||a)&&(h.point1={x:h.bezierPoint1.x,y:h.bezierPoint1.y})):("BezierTargetThumb"===e||"ConnectorTargetEnd"===e&&!a&&GI(h.vector2))&&(h.bezierPoint2.x+=i,h.bezierPoint2.y+=r,(!R.isEmptyPoint(h.point2)||a)&&(h.point2={x:h.bezierPoint2.x,y:h.bezierPoint2.y}))},n.prototype.translateSubsequentSegment=function(t,e,i,r,s){var o=t.segments.indexOf(e);parseInt(o.toString(),10),t.bezierSettings.smoothness&SI.SymmetricAngle||(s=null),t.bezierSettings.smoothness&SI.SymmetricDistance||(r=null),(null!=r||null!=s)&&(i?0!==o&&this.updatePreviousBezierSegment(t,o,r,s):o!==t.segments.length-1&&this.updateNextBezierSegment(t,o,r,s))},n.prototype.updatePreviousBezierSegment=function(t,e,i,r){var s=t.segments[e-1],a=(s.vector2.angle+r)%360;a<0&&(a+=360),s.vector2={distance:s.vector2.distance+i,angle:a}},n.prototype.updateNextBezierSegment=function(t,e,i,r){var s=t.segments[e+1],a=(s.vector1.angle+r)%360;a<0&&(a+=360),s.vector1={distance:s.vector1.distance+i,angle:a}},n.prototype.dragTargetEnd=function(t,e,i,r,s,o,a,l){var c,h=this.diagram.nameTable[t.id],d=this.checkBoundaryConstraints(e,i,h.wrapper.bounds);if(LI(h)&&"BezierTargetThumb"!==o&&d&&Vv(this.diagram)){if(c=$(c={targetPoint:h.targetPoint}),h.targetPoint.x+=e,h.targetPoint.y+=i,"ConnectorTargetEnd"===o&&"Orthogonal"===h.type&&h.segments&&h.segments.length>0){var u=h.segments[h.segments.length-2];u&&2===h.segments[h.segments.length-1].points.length&&("Left"===u.direction||"Right"===u.direction?u.points[u.points.length-1].x=h.targetPoint.x:u.points[u.points.length-1].y=h.targetPoint.y,u.length=R.distancePoints(u.points[0],u.points[u.points.length-1]),u.direction=R.direction(u.points[0],u.points[u.points.length-1]))}"Bpmn"===h.shape.type&&"Default"===h.shape.sequence&&"Sequence"===h.shape.flow&&this.updatePathElementOffset(h)}if("Bezier"===h.type)if(c={targetPoint:h.targetPoint},l)this.translateBezierPoints(t,""===o?"ConnectorTargetEnd":o,e,i,l,s,!a);else for(var f=0;f0){if(void 0!==s&&o.segments[parseInt(s.toString(),10)])if("Bezier"===o.type){var a=o.segments[parseInt(s.toString(),10)],l=a.isInternalSegment;l&&null!==o.bezierSettings&&"FreeForm"!==o.bezierSettings.segmentEditOrientation?("Horizontal"===a.orientation?a.point.x+=e:a.point.y+=i,this.updateDirectionalBezierCurve(o)):(a.point.x+=e,a.point.y+=i),l&&(o.isBezierEditing=!0)}else o.segments[parseInt(s.toString(),10)].point.x+=e,o.segments[parseInt(s.toString(),10)].point.y+=i;else for(var h=0;h1){var a=e[1],l=e[2],h={x:.5*(a.x+l.x),y:.5*(a.y+l.y)},c=t.segments[0];c.vector1.angle=Xt(s,a),c.vector1.distance=.5*R.findLength(s,a),c.vector2.angle=Xt(h,a),c.vector2.distance=.5*R.findLength(h,a),c.point=h;var d=t.segments[1];if(d.vector1.angle=Xt(h,l),d.vector1.distance=.5*R.findLength(h,l),t.segments.length>2){var u=e[3],f={x:.5*(l.x+u.x),y:.5*(l.y+u.y)};d.vector2.angle=Xt(f,l),d.vector2.distance=.5*R.findLength(f,l),d.point=f;var p=t.segments[2];if(p.vector1.angle=Xt(f,u),p.vector1.distance=.5*R.findLength(f,u),t.segments.length>3){var g=e[4],v={x:.5*(u.x+g.x),y:.5*(u.y+g.y)};p.vector2.angle=Xt(v,u),p.vector2.distance=.5*R.findLength(v,u),p.point=v;var y=t.segments[3];y.vector1.angle=Xt(v,g),y.vector1.distance=.5*R.findLength(v,g),y.vector2.angle=Xt(o,g),y.vector2.distance=.5*R.findLength(o,g)}else p.vector2.angle=Xt(o,u),p.vector2.distance=.5*R.findLength(o,u)}else d.vector2.angle=Xt(o,l),d.vector2.distance=.5*R.findLength(o,l)}},n.prototype.rotateObjects=function(t,e,i,r,s){r=r||{};var o=Bi();qi(o,i,r.x,r.y);for(var l=0,h=e;l0){this.diagram.protectPropertyChange(!0);var o=t;o.segments=[],this.diagram.connectorPropertyChange(o,{},{segments:o.segments}),this.diagram.protectPropertyChange(!1)}}},n.prototype.updateInnerParentProperties=function(t){var r=this.diagram.isProtectedOnChange;this.diagram.protectPropertyChange(!0);for(var s=this.getAllDescendants(t,[],!1,!0),o=0;o0&&(f=this.diagram.bpmnModule.getChildrenBound(d,d.id,this.diagram),u=d.wrapper.bounds.containsRect(f)),h=d.wrapper.actualSize.width*t,c=d.wrapper.actualSize.height*e,void 0!==d.maxWidth&&0!==d.maxWidth&&(h=Math.min(d.maxWidth,h)),void 0!==d.minWidth&&0!==d.minWidth&&(h=Math.max(d.minWidth,h)),void 0!==d.maxHeight&&0!==d.maxHeight&&(c=Math.min(d.maxHeight,c)),void 0!==d.minHeight&&0!==d.minHeight&&(c=Math.max(d.minHeight,c)),u&&(h=Math.max(h,f.right-d.wrapper.bounds.x),c=Math.max(c,f.bottom-d.wrapper.bounds.y)),t=h/d.actualSize.width,e=c/d.actualSize.height}var p=Bi();o||(o=r);var g=o.wrapper;if(qi(p,-g.rotateAngle,i.x,i.y),Yf(p,t,e,i.x,i.y),qi(p,g.rotateAngle,i.x,i.y),r instanceof te){var d,v=Ke(p,{x:(d=r).wrapper.offsetX,y:d.wrapper.offsetY}),y=d.wrapper.offsetX-d.wrapper.actualSize.width*d.pivot.x,S=d.wrapper.offsetY-d.wrapper.actualSize.height*d.pivot.y;if(h>0)if(d.processId){var b=this.diagram.nameTable[d.processId];(!b.maxWidth||d.margin.left+h0)if(d.processId){var M=this.diagram.nameTable[d.processId];(!M.maxHeight||d.margin.top+c0){if(e.dragLimit=e.dragLimit?e.dragLimit:{},e.dragLimit.top||e.dragLimit.bottom||e.dragLimit.left||e.dragLimit.right){var b={minDistance:null};S=this.getRelativeOffset(v,d,b);var M={minDistance:null};g=this.getRelativeOffset(v,y,M),S=null!=b&&M.minDistance0){if(S=y[y.length-1]){var b=void 0;for(b=0;b=e.x-t.dragLimit.left-r.width/2&&i.x<=e.x+t.dragLimit.right+r.width/2&&(s=!0),i.y>=e.y-t.dragLimit.top-r.height/2&&i.y<=e.y+t.dragLimit.bottom+r.height/2&&(o=!0),{x:s,y:o}},n.prototype.updateLabelMargin=function(t,e,i,r,s,o,a){if(i=i||{x:e.offset,y:0},e&&i&&i.x>0&&i.x<1){var l=R.getLengthFromListOfPoints(t.intermediatePoints),h=this.getPointAtLength(l*i.x,t.intermediatePoints,0),c=this.diagram.scrollSettings.currentZoom,d=e.dragLimit?e.dragLimit:{left:0,right:0,top:0,bottom:0};if(d.top||d.bottom||d.left||d.right){this.diagram.getWrapper(t.wrapper,e.id);var f=new Ne(0,0,0,0),p=this.diagram.getWrapper(t.wrapper,e.id);f.x=p.offsetX/c+o,f.y=p.offsetY/c+a,f.width=p.bounds.width/c,f.height=p.bounds.height/c;var g=new Ne(h.x-(d.left||0)-f.width/2,h.y-(d.top||0)-f.height/2,(d.left||0)+(d.right||0)+f.width,(d.top||0)+(d.bottom||0)+f.height);if(g.containsPoint(r));else for(var S=0,b=this.boundsInterSects([h,r],g,!1);S=t){c=t-r,d=R.findAngle(s,a),u=c*Math.cos(d*Math.PI/180),f=c*Math.sin(d*Math.PI/180),o={x:s.x+u,y:s.y+f};break}r+=h,s=a}else s=a;return o},n.prototype.getInterceptWithSegment=function(t,e){for(var o,a,i=[],r=[],s=[],l=R.findLength({x:0,y:0},{x:this.diagram.scroller.viewPortWidth,y:this.diagram.scroller.viewPortHeight}),h=1;h0&&a<=90||a>180&&a<=270?90:-90;r.push(R.transform(t,a+c,l)),r.push(R.transform(t,o+c,l));var f=tm({x1:s[0].x,y1:s[0].y,x2:s[1].x,y2:s[1].y},{x1:r[0].x,y1:r[0].y,x2:r[1].x,y2:r[1].y});f.enabled&&i.push(f.intersectPt)}return i},n.prototype.getAnnotationChanges=function(t,e){var r={};return r[ib(t,e.id,!0)]={width:e.width,height:e.height,offset:t instanceof te?{x:e.offset.x,y:e.offset.y}:e.offset,rotateAngle:e.rotateAngle,margin:{left:e.margin.left,right:e.margin.right,top:e.margin.top,bottom:e.margin.bottom},horizontalAlignment:e.horizontalAlignment,verticalAlignment:e.verticalAlignment,alignment:t instanceof de?e.alignment:void 0},{annotations:r}},n.prototype.getConnectorPortChanges=function(t,e){var i=function kse(n,t,e){for(var i=n.ports,r=0;r1&&(v.width=g,v.offset.x=1/S),p>1&&(v.height=p,v.offset.y=1/b)}}e instanceof Or&&(e.alignment="Center"),l=this.getAnnotationChanges(t,e),t instanceof te?this.diagram.nodePropertyChange(t,a,l):this.diagram.connectorPropertyChange(t,a,l),this.diagram.updateDiagramObject(t)},n.prototype.getSubProcess=function(t){var i,e={nodes:[],connectors:[]};return t instanceof te?i=t.processId:t&&t.nodes&&t.nodes.length&&t.nodes[0].processId&&(i=t.nodes[0].processId),i&&e.nodes.push($(this.diagram.nameTable[i])),e},n.prototype.checkBoundaryConstraints=function(t,e,i,r){var s=this.diagram.pageSettings,o=this.diagram.pageSettings.boundaryConstraints,a=this.diagram.scroller;if("Page"===o||"Diagram"===o){var l=i?void 0:this.diagram.selectedItems.wrapper.bounds;return!!((i?i.right:l.right)+(t||0)<=("Page"===o?s.width:a.viewPortWidth)&&(i?i.left:l.left)+(t||0)>=0&&(i?i.bottom:l.bottom)+(e||0)<=("Page"===o?s.height:a.viewPortHeight)&&(i?i.top:l.top)+(e||0)>=0||"None"!==this.diagram.layout.type&&r)}return!0},n.prototype.dragSelectedObjects=function(t,e){var i=this,r=this.diagram.selectedItems;this.state&&!this.state.backup&&(this.state.backup={},this.state.backup.offsetX=r.offsetX,this.state.backup.offsetY=r.offsetY),r=VI(this.diagram,r)||r;var s=this.diagram.selectedItems.nodes.filter(function(c){return"SwimLane"===c.shape.type});if(s.length>0&&!this.diagram.currentSymbol&&this.diagram.selectedItems.nodes.length>1){var o=this.diagram.selectedItems.nodes.filter(function(c){return""===c.parentId||"SwimLane"!==i.diagram.nameTable[c.parentId].shape.type});if(o.length>0){for(var a=0;a0||l.length>1)&&(o=o.concat(l),this.diagram.selectedItems.nodes.splice(0,this.diagram.selectedItems.nodes.length),o.forEach(function(c){i.diagram.selectedItems.nodes.push(c)}),r=this.diagram.selectedItems,this.diagram.selectedObject.helperObject=void 0)}}if(this.checkBoundaryConstraints(t,e)){this.diagram.diagramActions=this.diagram.diagramActions|ee.PreventZIndexOnDragging|ee.DragUsingMouse;var h=this.diagram.selectedObject.actualObject;return(h&&h instanceof te&&h.isLane&&Vx(h,this.diagram)||!h||!h.isLane)&&this.diagram.drag(r,t,e),this.diagram.diagramActions=this.diagram.diagramActions&~(ee.PreventZIndexOnDragging|ee.DragUsingMouse),this.diagram.refreshCanvasLayers(),this.checkHtmlObjectDrag(r),!0}return!1},n.prototype.checkHtmlObjectDrag=function(t){var e=!1;this.diagram.views&&this.diagram.views.length>1&&(t instanceof ti?e=t.nodes.some(function(i){return i.shape&&"HTML"===i.shape.type}):t.shape&&"HTML"===t.shape.type&&(e=!0),e&&this.resetOverviewCanvas())},n.prototype.resetOverviewCanvas=function(){for(var t=0,e=this.diagram.views;t0&&(this.layoutAnimateModule.stopCurrentAnimation(this.objectStore[0],e,t),this.objectStore=[]),a=this.diagram.doLayout(),this.objectStore.push(a)),this.canUpdateTemplate=!1,this.diagram.blazorActions&=~on.expandNode,this.diagram.preventNodesUpdate=r,this.diagram.layoutAnimateModule&&this.diagram.organizationalChartModule&&!i)this.diagram.allowServerDataBinding=!1,this.layoutAnimateModule.expand(this.diagram.layout.enableAnimation,a,t,this.diagram);else{var l={element:$(t),state:!!t.isExpanded};this.triggerEvent(Ce.expandStateChange,l),this.diagram.lineRoutingModule&&this.diagram.constraints&nt.LineRouting&&"ComplexHierarchicalTree"!==this.diagram.layout.type&&this.diagram.resetSegments()}return this.diagram.layout.fixedNode=""===o?"":this.diagram.layout.fixedNode,a},n.prototype.getparentexpand=function(t,e,i,r){for(var s,o=0;o0&&(this.diagram.selectedItems.wrapper.rotateAngle=this.diagram.selectedItems.rotateAngle=s.rotateAngle),!(r instanceof te&&"SwimLane"!==r.shape.type)||r.isLane||r.isPhase||r.isHeader||Dn(this.diagram,r)){if(r instanceof ti)for(var d=0;d30||g.wrapper.outerBounds.topCenter.y-p.wrapper.outerBounds.bottomCenter.y>30)&&this.diagram.lineRoutingModule.refreshConnectorSegments(this.diagram,f,!0)}}this.updateSelector(),this.diagram.protectPropertyChange(!1)}},n.prototype.drawSelectionRectangle=function(t,e,i,r){this.diagram.drawSelectionRectangle(t,e,i,r)},n.prototype.startGroupAction=function(){this.diagram.startGroupAction()},n.prototype.endGroupAction=function(){this.diagram.endGroupAction()},n.prototype.removeChildFromBPmn=function(t,e,i){var r=this.diagram.nameTable[t.id]||t.nodes[0];if(i&&r&&r.processId&&r.processId===i.wrapper.id){var s=$(r);s.processId=r.processId,this.diagram.startGroupAction();var o=this.diagram.nameTable[r.processId].shape.activity.subProcess.processes||[];o.splice(o.indexOf(r.id),1),this.diagram.bpmnModule.removeChildFromBPMN(this.diagram.nameTable[r.processId].wrapper,r.id,this.diagram),this.diagram.nameTable[r.id].processId="",r.offsetX=r.wrapper.offsetX,r.offsetY=r.wrapper.offsetY;var a=$(r);this.addHistoryEntry({type:"PositionChanged",redoObject:{nodes:[a]},undoObject:{nodes:[s]},category:"Internal"}),this.diagram.endGroupAction()}},n.prototype.isDroppable=function(t,e){var i=this.diagram.nameTable[t.id]||t.nodes[0];return i instanceof te&&(!ce()&&"TextAnnotation"===i.shape.shape||("Group"===e.shape.shape&&(e.shape.activity.subProcess.collapsed=!1),!(i&&"Bpmn"===i.shape.type&&(i.processId===e.id||i.id===e.processId||"Bpmn"===e.shape.type&&!(e instanceof de)&&e.shape.activity&&e.shape.activity.subProcess&&e.shape.activity.subProcess.collapsed))))},n.prototype.renderHighlighter=function(t,e,i){if(new Ne,t.target instanceof te||t.target instanceof de||e&&(t.source instanceof te||t.source instanceof de)){var a=this.findTarget(e?t.sourceWrapper:t.targetWrapper,e?t.source:t.target,i,!0),l=void 0;if(a instanceof Rd)for(var h=a.id,c=t.target,u=0,f=c.wrapper.children[0].children[0].children[2].children;u0){var r=0;t[0]=this.diagram.nameTable[t[0].id]||t[0];var s="Object"===i?yr(t[0].wrapper):this.diagram.selectedItems.wrapper.bounds,o={nodes:[],connectors:[]},a={nodes:[],connectors:[]};for(r="Object"===i?r+1:r;r0){var i=0,r=0,s=0,o=0,a=0,l=0,h=0,c=0,d={nodes:[],connectors:[]},u={nodes:[],connectors:[]};for(i=0;io.center.y&&(r=n[parseInt(e.toString(),10)],n[parseInt(e.toString(),10)]=n[parseInt(i.toString(),10)],n[parseInt(i.toString(),10)]=r):s.center.x>o.center.x&&(r=n[parseInt(e.toString(),10)],n[parseInt(e.toString(),10)]=n[parseInt(i.toString(),10)],n[parseInt(i.toString(),10)]=r)}}return n}(t,e),i=1;i0){var i=0,r={x:.5,y:.5};t[0]=this.diagram.nameTable[t[0].id]||t[0];var s=yr(t[0].wrapper),o={nodes:[],connectors:[]},a={nodes:[],connectors:[]};for(i=1;ii.zIndex){for(var s=this.diagram.layers.indexOf(this.diagram.getActiveLayer()),o=this.diagram.layers[parseInt(s.toString(),10)].zIndexTable,a=JSON.parse(JSON.stringify(o)),l=i.zIndex,h=r.zIndex,c=h;c>=l;c--)l!==c?o[c-1]?(o[parseInt(c.toString(),10)]=o[c-1],this.diagram.nameTable[o[parseInt(c.toString(),10)]].zIndex=c):(o[c-1]=o[parseInt(c.toString(),10)],this.diagram.nameTable[o[c-1]].zIndex=c,delete o[parseInt(c.toString(),10)]):this.swapZIndexObjects(h,o,r.id,a);"SVG"===this.diagram.mode?(this.moveSvgNode(e.parentId,i.id),this.updateNativeNodeIndex(e.parentId,i.id)):this.diagram.refreshCanvasLayers()}},n.prototype.findLeastIndexConnector=function(t,e,i){for(var r=0;rs.zIndex&&(i=s)}return i},n.prototype.findLeastIndexObject=function(t,e){var i=t;return t instanceof te&&(i=this.findLeastIndexConnector(t.inEdges,e,i),i=this.findLeastIndexConnector(t.outEdges,e,i)),i},n.prototype.checkSelection=function(t,e){var i;if(1===t.nodes.length&&0===t.connectors.length)if(Dn(this.diagram,t.nodes[0],!0)){var r=t.nodes[0];if("SwimLane"===(i="SwimLane"===t.nodes[0].shape?t.nodes[0]:this.diagram.nameTable[t.nodes[0].parentId]).shape.type){var s="Horizontal"===i.shape.orientation;(r.isPhase&&(s&&"ResizeSouth"===e||!s&&"ResizeEast"===e)||r.isLane&&(s&&"ResizeEast"===e||!s&&"ResizeSouth"===e))&&B3(this.diagram,i,e)}else if("Grid"===i.container.type)if("Horizontal"===i.container.orientation&&1===r.rowIndex||"Vertical"===i.container.orientation&&r.rowIndex>0&&r.columnIndex>0){if("ResizeSouth"===e)for(var o=0;o1&&(this.diagram.realActions=this.diagram.realActions|$i.hScrollbarMoved,this.scrolled=!0),this.diagram.scrollSettings.horizontalOffset=t},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"verticalOffset",{get:function(){return this.vOffset},set:function(t){this.vOffset=t,Math.abs(this.vOffset-this.diagram.scrollSettings.verticalOffset)>1&&(this.diagram.realActions=this.diagram.realActions|$i.vScrollbarMoved,this.scrolled=!0),this.diagram.scrollSettings.verticalOffset=t},enumerable:!0,configurable:!0}),n.prototype.getBounds=function(){var e=this.diagram.spatialSearch.getPageBounds(0,0);return(e.x<0||e.y<0)&&!this.diagram.pageSettings.multiplePage?this.getPageBounds(void 0,void 0,!0,!0):this.getPageBounds(void 0,void 0,!0)},n.prototype.updateScrollOffsets=function(t,e){var i,r,s=this.getBounds();s.x*=this.currentZoom,s.y*=this.currentZoom,s.width*=this.currentZoom,s.height*=this.currentZoom,i=Math.max(0,t-s.left),r=Math.max(0,e-s.top),void 0!==t&&void 0!==e?(this.horizontalOffset=i,this.verticalOffset=r,this.diagram.setOffset(i,r)):this.diagram.setOffset(-this.horizontalOffset-s.x,-this.verticalOffset-s.y),this.transform={tx:Math.max(this.horizontalOffset,-s.left)/this.currentZoom,ty:Math.max(this.verticalOffset,-s.top)/this.currentZoom,scale:this.currentZoom}},n.prototype.setScrollOffset=function(t,e){this.scrolled=!1;var i=this.getBounds();i.x*=this.currentZoom,i.y*=this.currentZoom,i.width*=this.currentZoom,i.height*=this.currentZoom;var r=-i.left,s=-i.top,o=!1,a=this.viewPortWidth*this.currentZoom,l=this.viewPortHeight*this.currentZoom,h=r-t;if(h!==this.horizontalOffset){rh?this.horizontalOffset-=t:this.horizontalOffset=h,o=!0);var c=Math.max(i.right+this.vScrollSize,a);if(!o&&c<-h+this.viewPortWidth){var d=-h+a-this.vScrollSize,u=-this.horizontalOffset+a-this.vScrollSize;this.horizontalOffset=dd-u?h:-(i.right+this.vScrollSize-a),o=!0}o||(this.horizontalOffset=r-t)}o=!1;var f=s-e;if(f!==this.verticalOffset){sf?this.verticalOffset-=e:this.verticalOffset=f,o=!0);var p=Math.max(i.bottom+this.hScrollSize,l);if(!o&&p<-f+l){var g=-f+l-this.hScrollSize,v=-this.verticalOffset+l-this.hScrollSize;this.verticalOffset=gg-v?f:-(i.bottom+this.hScrollSize-l),o=!0}o||(this.verticalOffset=s-e)}this.transform={tx:Math.max(this.horizontalOffset,-i.left)/this.currentZoom,ty:Math.max(this.verticalOffset,-i.top)/this.currentZoom,scale:this.currentZoom},this.setSize()},n.prototype.getObjects=function(t,e){for(var i=[],r=0;r0){for(var l=0;l0){h.push(i[parseInt(o.toString(),10)].id);for(var d=0;d=e.bottom&&(l=0),-this.horizontalOffset<=e.x&&-this.horizontalOffset+this.viewPortWidth>=e.right&&(a=0),this.hScrollSize=a,this.vScrollSize=l;var h=this.diagramWidth,c=this.diagramHeight;this.diagramWidth=Math.max(e.right,-this.horizontalOffset+this.viewPortWidth-l)-i,this.diagramHeight=Math.max(e.bottom,-this.verticalOffset+this.viewPortHeight-a)-r,(h!==this.diagramWidth||c!==this.diagramHeight)&&"Diagram"!==this.diagram.scrollSettings.scrollLimit&&this.diagram.setSize(this.diagramWidth,this.diagramHeight),"Diagram"===this.diagram.scrollSettings.scrollLimit&&(h===this.diagramWidth&&c===this.diagramHeight&&1===this.currentZoom||this.diagram.diagramActions&&t&&(!this.diagram.diagramActions||!t||0===this.verticalOffset&&this.verticalOffset!==t.y||0===this.horizontalOffset&&this.horizontalOffset!==t.x)?t&&h===this.diagramWidth&&c===this.diagramHeight&&(this.diagram.diagramCanvas.scrollHeight>this.viewPortHeight&&t.y<0&&this.horizontalOffset===t.x&&0===this.verticalOffset||this.diagram.diagramCanvas.scrollWidth>this.viewPortWidth&&t.x<0&&this.verticalOffset===t.y&&0===this.horizontalOffset)&&(this.verticalOffset=t.y,this.horizontalOffset=t.x,this.transform={tx:Math.max(t.x,-e.left)/this.currentZoom,ty:Math.max(t.y,-e.top)/this.currentZoom,scale:this.currentZoom}):(this.diagram.scrollActions&da.Interaction&&t&&(this.transform={tx:Math.max(t.x,-e.left/this.currentZoom)/this.currentZoom,ty:Math.max(t.y,-e.top/this.currentZoom)/this.currentZoom,scale:this.currentZoom},this.horizontalOffset=t.x,this.verticalOffset=t.y),this.diagram.setSize(this.diagramWidth,this.diagramHeight),!(this.diagram.scrollActions&da.PropertyChange)&&t&&(this.horizontalOffset=t.x,this.verticalOffset=t.y,this.transform={tx:Math.max(t.x,-e.left)/this.currentZoom,ty:Math.max(t.y,-e.top)/this.currentZoom,scale:this.currentZoom}))),this.diagram.transformLayers(),this.diagram.element.style.overflow="hidden"},n.prototype.setViewPortSize=function(t,e){this.viewPortWidth=t,this.viewPortHeight=e},n.prototype.getPageBounds=function(t,e,i,r){var o,s=new Ne;if("Content"===e||r||null===this.diagram.pageSettings.width||null===this.diagram.pageSettings.height){var u=t?void 0:0;o=this.diagram.spatialSearch.getPageBounds(u,u)}else{var a=this.diagram.pageSettings.width,l=this.diagram.pageSettings.height,h=0,c=0;if(this.diagram.pageSettings.multiplePage){if((s=this.diagram.spatialSearch.getPageBounds(0,0)).right>a&&(a*=d=Math.ceil(s.right/a)),s.bottom>l&&(l*=d=Math.ceil(s.bottom/l)),s.left<0&&Math.abs(s.left)>h){var d=Math.ceil(Math.abs(s.left)/this.diagram.pageSettings.width);h=this.diagram.pageSettings.width*d}s.top<0&&Math.abs(s.top)>c&&(d=Math.ceil(Math.abs(s.top)/this.diagram.pageSettings.height),c=this.diagram.pageSettings.height*d)}o=new Ne(-h,-c,a+h,l+c)}if(i){var f=this.diagram.scrollSettings.padding;o.x-=f.left,o.y-=f.top,o.width+=f.left+f.right,o.height+=f.top+f.bottom}return o},n.prototype.getPageBreak=function(t){for(var e=0,i=0,r=-1,s=[],c=this.diagram.pageSettings.margin.left,d=this.diagram.pageSettings.margin.right,u=this.diagram.pageSettings.margin.top,f=this.diagram.pageSettings.margin.bottom,p=1,g=1;t.width>e;)(e+=this.diagram.pageSettings.width?this.diagram.pageSettings.width:t.width)===this.diagram.pageSettings.width&&(s[++r]={x1:t.left+c,y1:t.top+u,x2:t.left+c,y2:t.bottom-f}),ei;)(i+=this.diagram.pageSettings.height?this.diagram.pageSettings.height:t.height)===this.diagram.pageSettings.height&&(s[++r]={x1:t.left+c,y1:t.top+u,x2:t.right-d,y2:t.top+u}),i=this.diagram.scrollSettings.minZoom||l||t>=1)){this.currentZoom*=t;var c=this.getPageBounds(void 0,void 0,!0);c.x*=this.currentZoom,c.y*=this.currentZoom;var d=Bi();Yf(d,t,t,r.x,r.y),ZB(d,e||0,i||0),yx(h,d);var u=Ke(h,{x:0,y:0});if(1===t&&(u=this.applyScrollLimit(u.x,u.y,s,o,a)),a=-c.y>=u.y&&-c.x>=u.x&&a,(this.diagram.scrollActions&da.PropertyChange||!(this.diagram.scrollActions&da.Interaction)||"Diagram"!==this.diagram.scrollSettings.scrollLimit||a)&&(this.transform={tx:Math.max(u.x,-c.left)/this.currentZoom,ty:Math.max(u.y,-c.top)/this.currentZoom,scale:this.currentZoom},this.horizontalOffset=u.x,this.verticalOffset=u.y),this.setSize(u),"SVG"!==this.diagram.mode&&Ds(this.diagram)&&this.diagram.scroller.virtualizeElements(),"SVG"!==this.diagram.mode&&!Ds(this.diagram)&&this.diagram.refreshDiagramLayer(),this.diagram.setOffset(-this.horizontalOffset-c.x,-this.verticalOffset-c.y),qI(this.diagram),this.diagram.views&&this.diagram.views.overview){var f=this.diagram.views.overview,p=f.scrollOverviewRect(f.parent.scroller.horizontalOffset,f.parent.scroller.verticalOffset,f.parent.scroller.currentZoom,!0);f.updateOverviewrect(-p.x,-p.y,p.width,p.height),f.updateView(f)}}}},n.prototype.fitToPage=function(t){var e=(t=t||{}).mode,i=t.region,r=t.margin||{},s=t.canZoomIn,o=t.customBounds,a=t.canZoomOut;r.bottom=r.bottom||25,r.top=r.top||25,r.left=r.left||25,r.right=r.right||25;var h,l=o,c=-this.horizontalOffset,d=-this.verticalOffset;if("PageSettings"===(i=i||"PageSettings")&&this.diagram.pageSettings.width&&this.diagram.pageSettings.height||this.diagram.nodes.length>0||this.diagram.connectors.length>0){e=e||"Page","CustomBounds"!==i&&(l=this.getPageBounds(!0,i,!0));var u={x:0,y:0};r.left+r.right>this.viewPortWidth&&(this.viewPortWidth<=100?(r.left=5,r.right=5):(r.left=25,r.right=25)),r.top+r.bottom>this.viewPortHeight&&(this.viewPortHeight<=100?(r.top=5,r.bottom=5):(r.top=25,r.bottom=25)),u.x=(this.viewPortWidth-(r.left+r.right))/l.width,u.y=(this.viewPortHeight-(r.top+r.bottom))/l.height,!s&&l.width-this.horizontalOffset-a+this.viewPortWidth&&(i=o.right-this.viewPortWidth,i+=20),o.x<-a&&(i=o.x),o.bottom>-l+this.viewPortHeight&&(r=o.bottom-this.viewPortHeight,r+=20),o.y<-l&&(r=o.y),this.zoom(1,-this.horizontalOffset-i,-this.verticalOffset-r,null,void 0,e))},n.prototype.bringToCenter=function(t){var e=this.currentZoom,i=new Ne(t.x*e,t.y*e,t.width*e,t.height*e),r=i.x+i.width/2-this.viewPortWidth/2,s=i.y+i.height/2-this.viewPortHeight/2;this.zoom(1,-this.horizontalOffset-(r*=-1),-this.verticalOffset-(s*=-1),null)},n.prototype.applyScrollLimit=function(t,e,i,r,s){if("Infinity"===this.diagram.scrollSettings.scrollLimit&&void 0===i&&!r&&(t=-t,e=-e),"Infinity"!==this.diagram.scrollSettings.scrollLimit){var o=void 0;if("Limited"===this.diagram.scrollSettings.scrollLimit){var a=this.diagram.scrollSettings.scrollableArea;o=new Ne(a.x,a.y,a.width,a.height)}(o=o||(s?this.getPageBounds():this.getPageBounds(!0))).x*=this.currentZoom,o.y*=this.currentZoom,o.width*=this.currentZoom,o.height*=this.currentZoom,void 0!==i&&(t*=-1,e*=-1),r&&(t*=-1,e*=-1);var l=Math.max(o.right,this.viewPortWidth);if(!r&&!(t<=o.x&&(t+this.viewPortWidth>=o.right||t>=o.right-this.viewPortWidth)||t>=o.x&&t+this.viewPortWidth<=l))if(t>=o.x)t=Math.max(o.x,Math.min(t,t-(t+this.viewPortWidth-this.vScrollSize-l)));else{var h=o.right-this.viewPortWidth;t=Math.min(h,o.x)}var c=Math.max(o.bottom,this.viewPortHeight);r||e<=o.y&&e+this.viewPortHeight>=o.bottom||e>=o.y&&e+this.viewPortHeight<=c||(e>=o.y?e=Math.max(o.y,Math.min(e,e-(e+this.viewPortHeight-this.hScrollSize-c))):(h=o.bottom-this.viewPortHeight,e=Math.min(o.y,h))),t*=-1,e*=-1}return{x:t,y:e}},n}(),Woe=function(){function n(t,e,i,r,s){this.objects=[],this.left=t,this.top=e,this.width=i,this.height=r,this.spatialSearch=s}return n.prototype.findQuads=function(t,e){null!=this.first&&this.first.isIntersect(t)&&this.first.findQuads(t,e),null!=this.second&&this.second.isIntersect(t)&&this.second.findQuads(t,e),null!=this.third&&this.third.isIntersect(t)&&this.third.findQuads(t,e),null!=this.fourth&&this.fourth.isIntersect(t)&&this.fourth.findQuads(t,e),this.objects.length>0&&e.push(this)},n.prototype.isIntersect=function(t){return!(this.left+this.widtht.right||this.top>t.bottom)},n.prototype.selectQuad=function(){for(var i,t=null,e=this;null!=e;)i=e.getQuad(t),e=i.source,t=i.target||t;return t},n.prototype.getQuad=function(t){var e=this.width/2,i=this.height/2;if(e>=1e3&&i>=1e3){var r=this.left+e,s=this.top+i;if(this.spatialSearch.childRight<=r){if(this.spatialSearch.childBottom<=s)return this.first||((o=new n(this.left,this.top,e,i,this.spatialSearch)).parent=this,this.first=o),{source:this.first};if(this.spatialSearch.childTop>=s)return this.third||((o=new n(this.left,s,e,i,this.spatialSearch)).parent=this,this.third=o),{source:this.third}}else if(this.spatialSearch.childLeft>=r){if(this.spatialSearch.childBottom<=s)return this.second||((o=new n(r,this.top,e,i,this.spatialSearch)).parent=this,this.second=o),{source:this.second};var o;if(this.spatialSearch.childTop>=s)return this.fourth||((o=new n(r,s,e,i,this.spatialSearch)).parent=this,this.fourth=o),{source:this.fourth}}}return this.objects.push(this.spatialSearch.childNode),{target:this}},n.prototype.isContained=function(){return this.spatialSearch.childLeft>=this.left&&this.spatialSearch.childRight<=this.left+this.width&&this.spatialSearch.childTop>=this.top&&this.spatialSearch.childBottom<=this.top+this.height},n.prototype.addIntoAQuad=function(t){var e={};this.spatialSearch.setCurrentNode(t);for(var i=null;!e.isAdded;)i=(e=this.spatialSearch.parentQuad.add(i)).quad;return i},n.prototype.add=function(t){if(t=null,this.isContained())return{isAdded:!0,quad:t=this.selectQuad()};var e=void 0,i=!(0!==this.objects.length||this.first||this.second||this.third||this.fourth),r=2*this.width,s=2*this.height;return this.spatialSearch.childLeft=this.childLeft?(this.pageLeft=this.childLeft,this.leftElement=t,r=!0):t===this.leftElement&&(this.pageLeft=Number.MAX_VALUE,this.findLeft(this.parentQuad),r=!0)),(this.pageTop!==this.childTop||t!==this.topElement)&&(this.pageTop>=this.childTop?(this.pageTop=this.childTop,this.topElement=t,r=!0):t===this.topElement&&(this.pageTop=Number.MAX_VALUE,this.findTop(this.parentQuad),r=!0)),(this.pageBottom!==this.childBottom||t!==this.bottomElement)&&(this.pageBottom<=this.childBottom?(r=!0,this.pageBottom=this.childBottom,this.bottomElement=t):t===this.bottomElement&&(this.pageBottom=-Number.MAX_VALUE,this.findBottom(this.parentQuad),r=!0)),(this.pageRight!==this.childRight||t!==this.rightElement)&&(this.pageRight<=this.childRight?(this.pageRight=this.childRight,this.rightElement=t,r=!0):t===this.rightElement&&(this.pageRight=-Number.MAX_VALUE,this.findRight(this.parentQuad),r=!0)),r}return this.setCurrentNode(null),!1},n.prototype.isWithinPageBounds=function(t){return t.left>=this.pageLeft&&t.right<=this.pageRight&&t.top>=this.pageTop&&t.bottom<=this.pageBottom},n.prototype.findQuads=function(t){var e=[];return this.parentQuad.findQuads(t,e),e},n.prototype.findObjects=function(t){for(var i=[],r=0,s=this.findQuads(t);r=r.outerBounds.left&&(this.pageLeft=r.outerBounds.left,this.leftElement=r)}},n.prototype.findTop=function(t){t.first||t.second?(t.first&&this.findTop(t.first),t.second&&this.findTop(t.second)):(t.third&&this.findTop(t.third),t.fourth&&this.findTop(t.fourth));for(var e=0,i=t.objects;e=r.outerBounds.top&&(this.pageTop=r.outerBounds.top,this.topElement=r)}},n.prototype.setCurrentNode=function(t){if(this.childNode=t,t){var e=t.outerBounds;this.childLeft=Number(e.left),this.childTop=Number(e.top),this.childRight=Number(e.right),this.childBottom=Number(e.bottom)}else this.childLeft=Number.MAX_VALUE,this.childTop=Number.MAX_VALUE,this.childRight=-Number.MAX_VALUE,this.childBottom=-Number.MAX_VALUE},n.prototype.getPageBounds=function(t,e){if(this.pageLeft===Number.MAX_VALUE)return new Ne(0,0,0,0);var i=void 0!==t?Math.min(this.pageLeft,0):this.pageLeft,r=void 0!==e?Math.min(this.pageTop,0):this.pageTop;return new Ne(Math.round(i),Math.round(r),Math.round(this.pageRight-i),Math.round(this.pageBottom-r))},n.prototype.getQuad=function(t){return this.quadTable[t.id]},n}(),Yoe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Goe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Yoe(t,n),function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);r>3&&s&&Object.defineProperty(t,e,s)}([I(!1)],t.prototype,"preventDefaults",void 0),t}(Ee),Xoe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),e_=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},qoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Xoe(t,n),e_([I("")],t.prototype,"action",void 0),e_([I("")],t.prototype,"cursor",void 0),t}(Ee),t_=function(){function n(){this.size=20,this.intermediatePoints=[],this.gridCollection=[],this.startArray=[],this.targetGridCollection=[],this.sourceGridCollection=[],this.considerWalkable=[]}return n.prototype.lineRouting=function(t){var e=t.connectors.length;if(this.renderVirtualRegion(t),e>0)for(var i=0;i=t.right||e.right<=t.left||e.top>=t.bottom||e.bottom<=t.top)},n.prototype.findEndPoint=function(t,e,i){var r,s;if(e&&""!==t.sourcePortID&&t.sourcePortWrapper||!e&&""!==t.targetPortID&&t.targetPortWrapper){s=zo(r=e?{x:t.sourcePortWrapper.offsetX,y:t.sourcePortWrapper.offsetY}:{x:t.targetPortWrapper.offsetX,y:t.targetPortWrapper.offsetY},void 0,e?t.sourceWrapper.bounds:t.targetWrapper.bounds);var o=e?t.sourcePortWrapper.bounds:t.targetPortWrapper.bounds;r=i?"Top"===s?{x:o.topCenter.x,y:o.topCenter.y}:"Left"===s?{x:o.middleLeft.x,y:o.middleLeft.y}:"Right"===s?{x:o.middleRight.x,y:o.middleRight.y}:{x:o.bottomCenter.x,y:o.bottomCenter.y}:{x:o.center.x,y:o.center.y}}else r=e&&this.startNode||!e&&this.targetNode?e?{x:this.startNode.wrapper.offsetX,y:this.startNode.wrapper.offsetY}:{x:this.targetNode.wrapper.offsetX,y:this.targetNode.wrapper.offsetY}:e?{x:t.sourcePoint.x,y:t.sourcePoint.y}:{x:t.targetPoint.x,y:t.targetPoint.y};return r},n.prototype.refreshConnectorSegments=function(t,e,i,r){var h,c,f,p,g,y,S,b,M,w,C,s=e.sourceID,o=e.targetID,a=e.sourcePortID,l=e.targetPortID;if(function Ure(n,t){var e=0;return n.constraints&qe.LineRouting?e=n.constraints&qe.LineRouting:n.constraints&qe.InheritLineRouting&&(e=t.constraints&nt.LineRouting),e}(e,t)||r){this.startNode=t.nameTable[""+s],this.targetNode=t.nameTable[""+o],this.intermediatePoints=[],this.startArray=[],this.targetGridCollection=[],this.sourceGridCollection=[],this.startGrid=void 0,this.targetGrid=void 0;for(var D=0;D0;){var L=this.startArray.pop();if(L){for(D=0;D1&&(e.segments=[]),this.updateConnectorSegments(t,this.intermediatePoints,this.gridCollection,e,i)){this.considerWalkable=[];break e}this.targetGridCollection.splice(this.targetGridCollection.indexOf(O),1),L=this.startArray.pop()}}L&&this.findPath(L)}}}},n.prototype.checkChildNodes=function(t,e){var i=!1,r=!1;if(t.nodeId.length>=1&&!e)for(var s=0;s1&&this.targetGridCollection[0].nodeId.length>1)for(var c=0;c<=1;c++){for(var d=this.targetGridCollection[parseInt(c.toString(),10)].gridX,u=this.targetGridCollection[parseInt(c.toString(),10)].gridY,f=this.targetGridCollection[parseInt(c.toString(),10)].nodeId,p=void 0,g=0;g=e.right&&t.top<=e.top&&t.bottom>=e.bottom},n.prototype.getEndvalue=function(t,e){return this.gridCollection[t.gridX][t.gridY].walkable?t:"left"===e?this.getEndvalue(this.gridCollection[t.gridX-1][t.gridY],e):"right"===e?this.getEndvalue(this.gridCollection[t.gridX+1][t.gridY],e):"top"===e?this.getEndvalue(this.gridCollection[t.gridX][t.gridY-1],e):"bottom"===e?this.getEndvalue(this.gridCollection[t.gridX][t.gridY+1],e):t},n.prototype.changeValue=function(t,e,i){t.walkable||this.considerWalkable.push(t);for(var r,s=0;s<=e;s++)"left"===i?r=this.gridCollection[t.gridX-s][t.gridY]:"right"===i?r=this.gridCollection[t.gridX+s][t.gridY]:"top"===i?r=this.gridCollection[t.gridX][t.gridY-s]:"bottom"===i&&(r=this.gridCollection[t.gridX][t.gridY+s]),r.walkable||this.considerWalkable.push(r)},n.prototype.getIntermediatePoints=function(t){var e;for(this.intermediatePoints=[];t;)this.intermediatePoints.push({x:t.gridX,y:t.gridY}),t=t.parent;this.intermediatePoints.reverse(),this.intermediatePoints.length>=1&&void 0!==this.intermediatePoints[0]&&void 0!==this.intermediatePoints[1]&&(this.intermediatePoints[0].x===this.intermediatePoints[1].x?this.intermediatePoints[0].yi.y&&o.y>s.y){for(var a=i.xi.x&&o.x>s.x)){for(var u=i.y=1&&u.length>1&&(g=u[u.length-2].x!==u[u.length-1].x?u[u.length-2].x>u[u.length-1].x?"Left":"Right":u[u.length-2].y>u[u.length-1].y?"Top":"Bottom"),M>=2&&v===g&&u.length>1&&u.splice(u.length-2,1),v=g);if(u&&u.length>1){for(var w=0;wD.x?S.bounds.middleLeft:S.bounds.middleRight),w===u.length-2&&""===r.targetPortID&&y&&(l=C.x>D.x?y.bounds.middleRight:y.bounds.middleLeft),0===w&&b&&(C.x=b.x,C.y=D.y=b.y,b=qa(r,0,b,Nl(S.bounds,_n(C.x>D.x?"Left":"Right")),!1),C.x=b.x),w===u.length-2&&l&&(w>0&&r.targetDecorator&&l.x-D.x<0&&Math.abs(l.x-C.x)0&&r.targetDecorator&&l.x-D.x>0&&Math.abs(l.x-C.x)D.y?S.bounds.topCenter:S.bounds.bottomCenter),w===u.length-2&&""===r.targetPortID&&y&&(l=C.y>D.y?y.bounds.bottomCenter:y.bounds.topCenter),0===w&&b&&(C.y=b.y,C.x=D.x=b.x,b=qa(r,0,b,Nl(S.bounds,_n(C.y>D.y?"Top":"Bottom")),!1),C.y=b.y),w===u.length-2&&l&&(w>0&&r.targetDecorator&&l.y-D.y<0&&Math.abs(l.y-C.y)0&&r.targetDecorator&&l.y-D.y>0&&Math.abs(l.y-C.y)D.x?(f="Left",p=C.x-D.x):(f="Right",p=D.x-C.x):C.y>D.y?(f="Top",p=C.y-D.y):(f="Bottom",p=D.y-C.y),o.push({type:"Orthogonal",length:p,direction:f})}}if(o&&o.length>0){var L=o[o.length-1];if(1===o.length&&(L.length-=20),L.length<10&&2===o.length&&(o.pop(),o.length>0&&(o[0].length-=20,L=o[0])),r.targetDecorator&&("Top"===L.direction||"Bottom"===L.direction)&&L.length>r.targetDecorator.height+1||("Right"===L.direction||"Left"===L.direction)&&L.length>r.targetDecorator.width+1)return r.segments=o,s&&t.connectorPropertyChange(r,{},{type:"Orthogonal",segments:o}),!0}return!1},n.prototype.findPath=function(t){for(var e,i=[],r=this.findNearestNeigbours(t,this.gridCollection,!0),s=0;sl)&&(e.x!==t.gridX||e.y!==t.gridY)&&(i.push(e),o.previousDistance=l,o.afterDistance=o.afterDistance||this.manhattan(Math.abs(e.x-this.targetGrid.gridX),Math.abs(e.y-this.targetGrid.gridY)),o.totalDistance=o.previousDistance+o.afterDistance,o.parent=t)}if(i.length>0)for(s=0;st?i*t+e:i*e+t},n.prototype.manhattan=function(t,e){return t+e},n.prototype.findNearestNeigbours=function(t,e,i){var r=[],s=t.parent;if(s){var o=(t.gridX-s.gridX)/Math.max(Math.abs(t.gridX-s.gridX),1),a=(t.gridY-s.gridY)/Math.max(Math.abs(t.gridY-s.gridY),1);0!==o?(this.isWalkable(t.gridX,t.gridY-1,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX][t.gridY-1])&&r.push(e[t.gridX][t.gridY-1]),this.isWalkable(t.gridX,t.gridY+1,!0)&&this.sourceGridCollection.indexOf(e[t.gridX][t.gridY+1])&&r.push(e[t.gridX][t.gridY+1]),this.isWalkable(t.gridX+o,t.gridY,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX+o][t.gridY])&&r.push(e[t.gridX+o][t.gridY])):0!==a&&(this.isWalkable(t.gridX-1,t.gridY,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX-1][t.gridY])&&r.push(e[t.gridX-1][t.gridY]),this.isWalkable(t.gridX+1,t.gridY,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX+1][t.gridY])&&r.push(e[t.gridX+1][t.gridY]),this.isWalkable(t.gridX,t.gridY+a,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX][t.gridY+a])&&r.push(e[t.gridX][t.gridY+a]))}else this.neigbour(t,"top",r,i),this.neigbour(t,"right",r,i),this.neigbour(t,"bottom",r,i),this.neigbour(t,"left",r,i);return r},n.prototype.neigbour=function(t,e,i,r){for(var o,s=1;s>0;){var a="top"===e||"bottom"===e?t.gridX:"left"===e?t.gridX-s:t.gridX+s,l="right"===e||"left"===e?t.gridY:"top"===e?t.gridY-s:t.gridY+s;if((o=this.gridCollection[parseInt(a.toString(),10)][parseInt(l.toString(),10)])&&(r&&-1===this.sourceGridCollection.indexOf(o)||!r&&-1===this.targetGridCollection.indexOf(o)))return i&&this.isWalkable(a,l)&&i.push(o),s;if(!(a>0&&l>0))break;s++}return null},n.prototype.resetGridColl=function(t,e,i){for(var s,r=1;r>0;){var o="top"===e||"bottom"===e?t.gridX:"left"===e?t.gridX-r:t.gridX+r,a="right"===e||"left"===e?t.gridY:"top"===e?t.gridY-r:t.gridY+r;if((s=this.gridCollection[parseInt(o.toString(),10)][parseInt(a.toString(),10)])&&(i&&-1===this.sourceGridCollection.indexOf(s)||!i&&-1===this.targetGridCollection.indexOf(s))){if(this.isWalkable(o,a))break;var l=this.gridCollection[parseInt(o.toString(),10)][parseInt(a.toString(),10)];this.considerWalkable.push(l)}if(!(o>0&&a>0))break;"top"===e||"left"===e?r--:r++}return null},n.prototype.isWalkable=function(t,e,i){if(t>=0&&t=0&&e0?1:-1,this.isWalkable(h,c-1)&&!this.isWalkable(h-a,c-1)||this.isWalkable(h,c+1)&&!this.isWalkable(h-a,c+1)))return{x:t,y:e};if(0!==l){if(l=l>0?1:-1,this.isWalkable(h-1,c)&&!this.isWalkable(h-1,c-l)||this.isWalkable(h+1,c)&&!this.isWalkable(h+1,c-l))return{x:t,y:e};if(this.findIntermediatePoints(h+1,c,h,c,s,o)||this.findIntermediatePoints(h-1,c,h,c,s,o))return{x:t,y:e}}return this.findIntermediatePoints(h+a,c+l,h,c,s,o)},n.prototype.destroy=function(){},n.prototype.getModuleName=function(){return"LineRouting"},n}(),$oe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Joe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return $oe(t,n),function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);r>3&&s&&Object.defineProperty(t,e,s)}([I(!0)],t.prototype,"inversedAlignment",void 0),t}(Ee),Koe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Oe=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},CT=function(n,t,e,i){return new(e||(e=Promise))(function(r,s){function o(h){try{l(i.next(h))}catch(c){s(c)}}function a(h){try{l(i.throw(h))}catch(c){s(c)}}function l(h){h.done?r(h.value):new e(function(c){c(h.value)}).then(o,a)}l((i=i.apply(n,t||[])).next())})},ET=function(n,t){var i,r,s,o,e={label:0,sent:function(){if(1&s[0])throw s[1];return s[1]},trys:[],ops:[]};return o={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function a(h){return function(c){return function l(h){if(i)throw new TypeError("Generator is already executing.");for(;e;)try{if(i=1,r&&(s=2&h[0]?r.return:h[0]?r.throw||((s=r.return)&&s.call(r),0):r.next)&&!(s=s.call(r,h[1])).done)return s;switch(r=0,s&&(h=[2&h[0],s.value]),h[0]){case 0:case 1:s=h;break;case 4:return e.label++,{value:h[1],done:!1};case 5:e.label++,r=h[1],h=[0];continue;case 7:h=e.ops.pop(),e.trys.pop();continue;default:if(!(s=(s=e.trys).length>0&&s[s.length-1])&&(6===h[0]||2===h[0])){e=0;continue}if(3===h[0]&&(!s||h[1]>s[0]&&h[1]0&&((!s.style||!s.style.fill)&&(o.style.fill="transparent"),(!s.style||!s.style.strokeColor)&&(o.style.strokeColor="transparent")),s.shape&&"UmlActivity"===s.shape.type&&JI(s,o),s.shape&&"SwimLane"===s.shape.type&&aF(s,o),r.nodeDefaults&&Ro(o,s,r.nodeDefaults),r.updateAnnotationText(o.annotations);if(e&&e.connectors)for(a=0;e&&e.connectors&&a0&&0===i.nodes.length)this.clearCollection(),a=!0;else{for(var g=0,v=Object.keys(e.nodes);g0&&0===i.connectors.length)this.clearCollection(!0),a=!0;else{for(var C=0,D=Object.keys(e.connectors);C0){this.renderSelector(!0);break}if(e.selectedItems.constraints){this.renderSelector(!0);break}break;case"snapSettings":this.updateSnapSettings(e);break;case"commandManager":this.initCommands();break;case"layout":o=!0;break;case"segmentThumbShape":this.updateSelector();break;case"dataSourceSettings":this.clear(),"None"===this.layout.type?a=!0:(this.initObjects(),o=!0);break;case"tooltip":i3(this);break;case"rulerSettings":this.updateRulerSettings(e);break;case"layers":this.updateLayer(e);break;case"scrollSettings":this.scrollActions|=da.PropertyChange,this.updateScrollSettings(e),this.scrollActions&=~da.PropertyChange,this.scrollSettings.horizontalOffset=-this.scroller.horizontalOffset||0,this.scrollSettings.verticalOffset=-this.scroller.verticalOffset||0;break;case"locale":e.locale!==i.locale&&(this.realActions|=$i.PreventDataInit,n.prototype.refresh.call(this),this.realActions&=~$i.PreventDataInit);break;case"contextMenuSettings":if(void 0!==e.contextMenuSettings.showCustomMenuOnly&&(this.contextMenuSettings.showCustomMenuOnly=e.contextMenuSettings.showCustomMenuOnly),void 0!==e.contextMenuSettings.show&&(this.contextMenuSettings.show=e.contextMenuSettings.show),e.contextMenuSettings.items){for(var A=e.contextMenuSettings.items,x=0,P=Object.keys(A);x0){for(var N=[],T=O.ports.length-1;T>=0;T--)"LineDistribution"===O.ports[parseInt(T.toString(),10)].id.split("_")[1]&&N.push(O.ports[parseInt(T.toString(),10)]);this.removePorts(O,N)}}for(T=0;T0)for(var ue=0,fe=Object.keys(e.nodes);ue0)for(var De=0,xe=Object.keys(e.connectors);De=0;o--)this.commandHandler.expandNode(r[parseInt(o.toString(),10)],this,0!==o);this.canLayout&&this.doLayout(),this.lineRoutingModule?this.connectors.sourceID!==this.connectors.targetID&&this.lineRoutingModule.lineRouting(this):this.constraints&nt.LineRouting&&console.warn('[WARNING] :: Module "LineRouting" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),this.validatePageSize(),this.renderPageBreaks(),this.diagramRenderer.renderSvgGridlines(this.snapSettings,Fd(this.element.id),this.scroller.transform,this.rulerSettings,this.hRuler,this.vRuler),this.commandHandler.initSelectorWrapper(),this.notify("initial-load",{}),this.trigger("load"),this.scroller.setSize(),this.scroller.updateScrollOffsets(),this.isRefreshed||this.refreshDiagramLayer(),(this.scrollSettings.verticalOffset>0||this.scrollSettings.horizontalOffset>0)&&this.updateScrollOffset(),X.isDevice&&(this.tool=ni.ZoomPan|ni.SingleSelect),this.notify("initial-end",{}),this.isProtectedOnChange=!1,this.tooltipObject=i3(this),this.diagramActions=ee.Render,this.initCommands();var a=document.getElementsByClassName(this.element.id+"_hiddenUserHandleTemplate");(function Ioe(n,t,e,i){var r,s,o,a,l,d=document.getElementById(i).ej2_instances[0];if(n&&t){r=UF(n);for(var u=0,f=e.userHandles;u0;)e[0].parentNode.removeChild(e[0]);var i=document.getElementById(this.element.id+"content");i&&this.element.removeChild(i);var r="measureElement";if(window[""+r]){window[""+r].usageCount-=1;var s="measureElementCount";window[""+s]--,0===window[""+s]&&(window[""+r].parentNode.removeChild(window[""+r]),window[""+r]=null)}}window.domTable={};for(var a=0;a1&&(this.callBlazorModel=!1,this.insertBlazorDiagramObjects(this.selectedItems),this.commandHandler.group(),this.callBlazorModel=!0,this.commandHandler.getBlazorOldValues())},t.prototype.unGroup=function(){this.callBlazorModel=!1,this.insertBlazorDiagramObjects(this.selectedItems),this.commandHandler.unGroup(),this.callBlazorModel=!0,this.commandHandler.getBlazorOldValues()},t.prototype.sendToBack=function(){this.commandHandler.sendToBack()},t.prototype.setActiveLayer=function(e){var i=this.commandHandler.getLayer(e);this.activeLayer=i},t.prototype.addLayer=function(e,i){this.commandHandler.addLayer(e,i)},t.prototype.removeLayer=function(e){this.commandHandler.removeLayer(e,ce())},t.prototype.moveObjects=function(e,i){$(this.layers),this.enableServerDataBinding(!1),this.commandHandler.moveObjects(e,i)},t.prototype.layerObjectUpdate=function(){},t.prototype.sendLayerBackward=function(e){this.layerObjectUpdate(),this.commandHandler.sendLayerBackward(e)},t.prototype.bringLayerForward=function(e){this.layerObjectUpdate(),this.commandHandler.bringLayerForward(e)},t.prototype.cloneLayer=function(e){this.commandHandler.cloneLayer(e)},t.prototype.bringToFront=function(){this.commandHandler.bringToFront()},t.prototype.moveForward=function(){this.commandHandler.sendForward()},t.prototype.sendBackward=function(){this.commandHandler.sendBackward()},t.prototype.getObject=function(e){return this.nameTable[""+e]},t.prototype.getNodeObject=function(e){return $(this.nameTable[""+e])},t.prototype.getConnectorObject=function(e){return $(this.nameTable[""+e])},t.prototype.getActiveLayer=function(){return this.activeLayer},t.prototype.nudgeCommand=function(e,i,r){if("object"!=typeof e&&(this.selectedItems.nodes.length||this.selectedItems.connectors.length)>0){var s=void 0;i.type&&"KEYDOWN"===i.type&&(s=i.type),this.nudge(e,void 0,void 0,s)}},t.prototype.nudge=function(e,i,r,s){var o=0,a=0;"Left"===e||"Right"===e?o=("Left"===e?-1:1)*(i||1):a=("Up"===e?-1:1)*(r||1),"KEYDOWN"===s&&(o*=5,a*=5);var h=this.selectedItems,c=this.selectedItems.wrapper.children[0];if(c instanceof li)this.commandHandler.labelDrag(h.nodes[0],c,o,a);else{var d=$(this.selectedItems);this.protectPropertyChange(!0),this.drag(h,o,a),this.protectPropertyChange(!1);var u={type:"PositionChanged",redoObject:$(this.selectedItems),undoObject:d,category:"Internal"};this.addHistoryEntry(u)}this.refreshCanvasLayers()},t.prototype.insertBlazorDiagramObjects=function(e){},t.prototype.drag=function(e,i,r){if(this.insertBlazorDiagramObjects(e),!(this.bpmnModule&&e instanceof te&&this.bpmnModule.updateAnnotationDrag(e,this,i,r))){if(e instanceof ti){if(this.preventConnectorsUpdate=!0,e.nodes&&e.nodes.length){for(var o=0,a=e.nodes;o0&&o.nodes[0].children){this.fromUndo||(this.rotateUsingButton=!0);for(var h=this.commandHandler.getAllDescendants(o.nodes[0],[]),c=0;c0&&o.nodes[0].children){var g={type:"RotationChanged",redoObject:$(e),undoObject:$(o),category:"Internal",childTable:a};this.commandHandler.addHistoryEntry(g),this.commandHandler.updateSelector()}return u},t.prototype.dragSourceEnd=function(e,i,r){this.insertBlazorDiagramObjects(e),this.commandHandler.dragSourceEnd(e,i,r),this.callBlazorModel&&this.commandHandler.getBlazorOldValues()},t.prototype.dragTargetEnd=function(e,i,r){this.insertBlazorDiagramObjects(e),this.commandHandler.dragTargetEnd(e,i,r),this.callBlazorModel&&this.commandHandler.getBlazorOldValues()},t.prototype.findObjectsUnderMouse=function(e,i){return this.eventHandler.findObjectsUnderMouse(e,i)},t.prototype.findObjectUnderMouse=function(e,i,r){return this.eventHandler.findObjectUnderMouse(e,i,r)},t.prototype.findTargetObjectUnderMouse=function(e,i,r,s,o){return this.eventHandler.findTargetUnderMouse(e,i,r,s,o)},t.prototype.findElementUnderMouse=function(e,i,r,s){return this.eventHandler.findElementUnderMouse(e,i,r,s)},t.prototype.findActionToBeDone=function(e,i,r,s){return this.eventHandler.findActionToBeDone(e,i,r,s)},t.prototype.updateConnectorPort=function(e){if(e.ports.length)for(var i=void 0,r=0,s=e.ports;r=0;s--)if(i.push(r[parseInt(s.toString(),10)]),i.length>this.historyManager.stackLimit)return i}else i=r;return i},t.prototype.getEdges=function(e){return e.outEdge?this.nameTable[e.id].outEdges:this.nameTable[e.id].inEdges},t.prototype.getParentId=function(e){return this.nameTable[""+e].parentId},t.prototype.addConnector=function(e){return this.add(e)},t.prototype.UpdateBlazorDiagramModelCollection=function(e,i,r,s){},t.prototype.UpdateBlazorDiagramModel=function(e,i,r,s){},t.prototype.UpdateBlazorLabelOrPortObjects=function(e,i,r,s){},t.prototype.addBlazorDiagramObjects=function(){},t.prototype.removeNodeEdges=function(e,i,r){var s=this.nameTable[""+e],o=r?s.outEdges:s.inEdges;if(o.length>0)for(var a=0;a0)){for(var c=0;c0))}this.removePortEdges(l,a.element.sourcePortID,a.element.id,h)}a.element.targetID&&this.removeNodeEdges(a.element.targetID,a.element.id,!1)}}this.diagramActions=this.diagramActions|ee.PublicMethod,e.id=e.id||Qe();var u=this.activeLayer;if(!a.cancel&&u&&!u.lock){if(u.objects.indexOf(e.id)<0&&!u.lock&&(u.visible||(u.visible=!0,this.dataBind()),u.objects.push(e.id)),ps(e)===de)(r=new de(this,"connectors",e,!0)).status="New",this.nameTable[r.targetID]&&"TextAnnotation"===this.nameTable[r.targetID].shape.shape&&(r.isBpmnAnnotationConnector=!0,r.constraints=r.constraints&~qe.Delete),Ro(r,e,this.connectorDefaults),this.connectors.push(r),this.initObject(r),!1===e.visible&&this.updateElementVisibility(r.wrapper,r,e.visible),this.updateEdges(r),this.insertBlazorConnector(r);else{if(Ro(r=new te(this,"nodes",e,!0),e,this.nodeDefaults),r.parentId=e.parentId?e.parentId:r.parentId,r.umlIndex=e.umlIndex,r.status="New",(o="TextAnnotation"===r.shape.shape)&&!e.isTextAnnotationCopied&&(r.inEdges=e.inEdges?e.inEdges:r.inEdges),this.nodes.push(r),this.initObject(r,u,void 0,i),o&&this.bpmnModule)for(c=0;c-1&&e.parentId&&this.nameTable[e.parentId]&&"UmlClassifier"===this.nameTable[e.parentId].shape.type){var g=this.nameTable[e.parentId];g.children.splice(r.umlIndex,0,r.id),g.wrapper.children.splice(r.umlIndex,0,r.wrapper),g.wrapper.measure(new me),g.wrapper.arrange(g.wrapper.desiredSize),this.updateDiagramObject(g)}}if(a={element:r,cause:this.diagramActions,diagramAction:this.getDiagramAction(this.diagramActions),state:"Changed",type:"Addition",cancel:!1},this.parentObject&&(a.parentId=this.parentObject.id),"helper"!==e.id&&!(this.diagramActions&ee.PreventCollectionChangeOnDragOver)&&this.triggerEvent(Ce.collectionChange,a),!(this.diagramActions&ee.UndoRedo||this.diagramActions&ee.Group||this.diagramActions&ee.PreventHistory)){var v={type:"CollectionChanged",changeType:"Insert",undoObject:$(e),redoObject:$(e),category:"Internal"};this.addHistoryEntry(v)}this.parentObject=void 0,"SVG"===this.mode&&(this.updateSvgNodes(r),this.updateTextElementValue(r),this.updateDiagramObject(r),o&&this.updateDiagramObject(this.nameTable[r.inEdges[0]]),r.shape.activity&&r.shape.activity.subProcess.processes&&r.shape.activity.subProcess.processes.length&&this.updateProcesses(r),this.updateBridging())}}if(this.protectPropertyChange(s),this.resetDiagramActions(ee.PublicMethod),r&&this.layers.length>1&&this.moveNode(r),this.views)for(var S=0,b=this.views;S=0;l--)this.moveSvgNode(a[parseInt(l.toString(),10)])}for(var h=0,c=i;h=0;o--)r[parseInt(o.toString(),10)]===e.id&&r.splice(o,1);for(var a=0;s.ports&&a=0;s--)if(i=this.nameTable[r[parseInt(s.toString(),10)]])if(this.connectorTable[i.id]=$(i),i.isBpmnAnnotationConnector){var o=this.nameTable[i.targetID];this.removeObjectsFromLayer(i);var a=this.connectors.indexOf(i);-1!==a&&this.connectors.splice(a,1),this.removeElements(i),this.removeFromAQuad(i),delete this.nameTable[i.id];var l=this.nameTable[i.sourceID];if(l){var h=l.outEdges.indexOf(i.id);-1!==h&&l.outEdges.splice(h,1)}e.id!==i.targetID&&this.remove(o)}else this.remove(i)},t.prototype.removeObjectsFromLayer=function(e){if(e.children)for(var i=0;i-1&&(_r(this,e)&&this.unSelect(e),this.layers[parseInt(s.toString(),10)].objects.splice(a,1),delete this.layers[parseInt(s.toString(),10)].zIndexTable[this.nameTable[e.id].zIndex])},t.prototype.removeElements=function(e){if("SVG"===this.mode||"Canvas"===this.mode&&"Native"===e.shape.type){var i=xt(e.id+"_groupElement",this.element.id),r=e;if(r.ports&&r.ports.length>0)for(var s=0;s0){l[parseInt(s.toString(),10)].id.indexOf("icon_content")>0&&"SVG"===this.mode&&((h=xt(l[parseInt(s.toString(),10)].id+"_shape_groupElement",this.element.id))&&h.parentNode.removeChild(h),(h=xt(l[parseInt(s.toString(),10)].id+"_rect_groupElement",this.element.id))&&h.parentNode.removeChild(h));for(var c=0,d=this.views;c=0;o--)a.children[parseInt(o.toString(),10)].children&&(l=n.nameTable[a.children[parseInt(o.toString(),10)].id])&&(l.isLane?qv(n,l):(n.removeDependentConnector(l),n.diagramActions|=ee.PreventHistory,l.constraints&ie.Delete?n.remove(l):V3(n,l,{},!1),n.diagramActions&=~ee.PreventHistory));a&&(i=n.nameTable[a.id])&&qv(n,i)}}(this,e),!(this.diagramActions&ee.UndoRedo||this.diagramActions&ee.PreventHistory)&&(e instanceof te||e instanceof de)){var o={type:"CollectionChanged",changeType:"Remove",undoObject:$(e),redoObject:$(e),category:"Internal"};this.diagramActions&ee.Clear||e.children&&!e.isLane&&!e.isPhase&&e.children.length>0&&this.undoRedoModule&&"None"===this.layout.type&&(this.historyManager.startGroupAction(),s=!0),(e instanceof te||e instanceof de)&&this.deleteDependentConnector&&this.removeDependentConnector(e),!e.isLane&&!e.isPhase&&!(this.diagramActions&ee.Clear)&&!this.isStackChild(e)&&this.addHistoryEntry(o)}"TextAnnotation"===e.shape.shape&&this.removeDependentConnector(e),e.children&&!e.isLane&&!e.isPhase&&(!(this.diagramActions&ee.UndoRedo)||!ce())&&this.deleteGroup(e),e.parentId&&(this.deleteChild(e,void 0,!0),this.nameTable[e.parentId]&&"UmlClassifier"===this.nameTable[e.parentId].shape.type&&(this.updateDiagramObject(this.nameTable[e.parentId]),this.updateConnectorEdges(this.nameTable[e.parentId])));var a=void 0;this.diagramActions=this.diagramActions|ee.PublicMethod;var l=this.nameTable[e.id];if(l instanceof te?("Bpmn"===l.shape.type&&this.bpmnModule&&this.bpmnModule.removeBpmnProcesses(l,this),(l.isLane||l.isPhase||"SwimLane"===l.shape.type)&&(h=l.isLane||l.isPhase?this.nameTable[l.parentId]:this.nameTable[l.id],l.isLane?_3(this,l,h):l.isPhase&&U3(this,l,h)),-1!==(a=this.nodes.indexOf(l))&&(this.crudDeleteNodes.push(this.nameTable[l.id]),this.nodes.splice(a,1),this.updateNodeEdges(l))):(-1!==(a=this.connectors.indexOf(l))&&(this.crudDeleteNodes.push(this.nameTable[l.id]),this.connectors.splice(a,1)),this.updateEdges(l),this.spliceConnectorEdges(e,!0),this.spliceConnectorEdges(e,!1)),!this.isServerUpdate&&!(this.blazorActions&on.GroupClipboardInProcess)&&this.commandHandler.getBlazorOldValues(),s&&this.historyManager.endGroupAction(),_r(this,l)&&this.unSelect(l),!l.isPhase){if(this.removeObjectsFromLayer(e),this.currentDrawingObject&&(this.currentDrawingObject.wrapper=void 0),delete this.nameTable[e.id],i.length>0&&i[0].id===l.id&&l.parentId){var h,d=this.nameTable[l.parentId];d&&d.isLane&&"SwimLane"===this.nameTable[d.parentId].shape.type&&F3(this,h=this.nameTable[d.parentId],d,l)}this.removeElements(l),this.updateBridging(),"SVG"!==this.mode&&this.refreshDiagramLayer(),this.diagramActions&ee.Clear||(this.removeFromAQuad(l),r={element:e,cause:this.diagramActions,diagramAction:this.getDiagramAction(this.diagramActions),state:"Changed",type:"Removal",cancel:!1},"helper"!==e.id&&this.triggerEvent(Ce.collectionChange,r),this.resetTool())}}}else if(i.length>0){this.undoRedoModule&&(this.historyManager.startGroupAction(),this.blazorActions|=on.GroupingInProgress,s=!0);for(var u=0;u=p.wrapper.bounds.width&&"Horizontal"===p.shape.orientation||this.selectedItems.wrapper.bounds.y<=p.wrapper.bounds.y+g&&this.selectedItems.wrapper.bounds.height>=p.wrapper.bounds.height-g&&"Vertical"===p.shape.orientation)&&(TI(p)||p.shape.lanes.length>1)&&this.remove(i[parseInt(u.toString(),10)])}}else this.remove(i[parseInt(u.toString(),10)])}s&&(this.blazorActions&=~on.GroupingInProgress,this.isServerUpdate=!0,this.commandHandler.getBlazorOldValues(),this.UpdateBlazorDiagramModelCollection(void 0,void 0,void 0,!0),this.historyManager.endGroupAction(),this.isServerUpdate=!1),this.clearSelection()}e&&(TI(e)||this.diagramActions&ee.Clear)||this.diagramActions&ee.UndoRedo||this.diagramActions&ee.PreventHistory||!(e instanceof te||e instanceof de)||(o={type:"ConnectionChanged",undoObject:$(e),redoObject:$(e),category:"Internal"},!e.isLane&&!e.isPhase&&!(this.diagramActions&ee.Clear)&&!this.isStackChild(e)&&this.addHistoryEntry(o)),this.tooltipObject.close()},t.prototype.isStackChild=function(e){var i,r=this.nameTable[e.parentId];if(e&&e.parentId&&r.container&&"Stack"===r.container.type&&"UmlClassifier"!==this.nameTable[e.parentId].shape.type){i=!0;var s={sourceIndex:r.wrapper.children.indexOf(e.wrapper),source:e,target:void 0,targetIndex:void 0};this.diagramActions&ee.UndoRedo||this.addHistoryEntry({type:"StackChildPositionChanged",redoObject:{sourceIndex:void 0,source:e,target:void 0,targetIndex:void 0},undoObject:s,category:"Internal"})}return i},t.prototype.deleteChild=function(e,i,r){var s;if(s="string"==typeof e?e:e.id,(i=i?this.nameTable[i.id]:this.nameTable[e.parentId])&&i.children){for(var o=0;o=0;i--)this.removeLayer(this.layers[parseInt(i.toString(),10)].id);this.commandHandler.addLayer({id:"default_layer",visible:!0,lock:!1,objects:[],zIndex:0,objectZIndex:-1,zIndexTable:{}},null,!0),this.setActiveLayer(this.layers[this.layers.length-1].id)},t.prototype.clearObjects=function(e){var i=[];i=e||(i=i.concat(this.nodes)).concat(this.connectors),this.diagramActions=this.diagramActions|ee.Clear;for(var r=0,s=i;r0||"Text"===e.shape.type))if("Text"===e.shape.type)i=e.wrapper.children[0].id.split("_")[1];else for(var p=e.annotations.length-1;p>=0;p--)e.annotations[parseInt(p.toString(),10)].visibility&&(i=e.annotations[parseInt(p.toString(),10)].id);i&&(u=this.getWrapper(e.wrapper,i))}if(e&&u&&!(u instanceof es)&&(!function Xre(n,t){return"Text"===t.shape.type?t.constraints&ie.ReadOnly:t.constraints&(t instanceof de?qe.ReadOnly:ie.ReadOnly)?n.constraints&Nr.InheritReadOnly?1:0:n.constraints&Nr.ReadOnly?1:0}(u,e)||f)){var g=u.style,v=void 0;v=90>(v=u.bounds.width50?50:e.width,u.style.fontSize)),e.parentId&&"UmlClassifier"===this.nameTable[e.parentId].shape.type?(l.width=e.wrapper.bounds.width-20,c=(e.wrapper.bounds.center.x+r.tx)*r.scale-l.width/2*s-2.5,d=(e.wrapper.bounds.center.y+r.ty)*r.scale-l.height/2*s-3,u.style.textAlign="Left"):(l.width=Math.max(l.width,50),c=(u.bounds.center.x+r.tx)*r.scale-l.width/2*s-2.5,d=(u.bounds.center.y+r.ty)*r.scale-l.height/2*s-3),Ho(y,{id:this.element.id+"_editTextBoxDiv",style:"position: absolute;left:"+c+"px;top:"+d+"px;width:"+(l.width+1)*s+"px;height:"+l.height*s+"px; containerName:"+e.id+";"}),Ho(S,{"aria-label":a,id:this.element.id+"_editBox",style:"width:"+(l.width+1)*s+"px;height:"+l.height*s+"px;resize: none;outline: none;overflow: hidden;;font-family:"+g.fontFamily+";font-size:"+g.fontSize*s+"px;text-align:"+u.style.textAlign.toLocaleLowerCase()+";",class:"e-diagram-text-edit"}),S.style.fontWeight=g.bold?"bold":"",S.style.fontStyle=g.italic?"italic":"",S.style.lineHeight=(1.2*g.fontSize+"px;").toString(),S.style.textDecoration=g.textDecoration?g.textDecoration:"",this.activeLabel.parentId=e.id,this.activeLabel.id=i,u.visible=!1,this.updateDiagramObject(e),this.diagramActions=this.diagramActions|ee.TextEdit,this.isTriggerEvent||(E.add(S,"input",this.eventHandler.inputChange,this.eventHandler),E.add(S,"focusout",this.focusOutEdit,this),S.select())}}}},t.prototype.updateConnectorfixedUserHandles=function(e){if(e.fixedUserHandles.length)for(var i=void 0,r=0,s=e.fixedUserHandles;r0&&this.mindMapChartModule.updateLayout(o,this.nameTable,this.layout,l,this.dataSourceSettings.id,this.dataSourceSettings.root),e=!0;else if(this.radialTreeModule)this.radialTreeModule.updateLayout(o,this.nameTable,this.layout,l),e=!0;else if(this.symmetricalLayoutModule)this.symmetricalLayoutModule.maxIteration=this.layout.maxIteration,this.symmetricalLayoutModule.springLength=this.layout.springLength,this.symmetricalLayoutModule.springFactor=this.layout.springFactor,this.symmetricalLayoutModule.updateLayout(o,this.connectors,this.symmetricalLayoutModule,this.nameTable,this.layout,l),e=!0;else if(this.complexHierarchicalTreeModule){this.canDistribute(a,r)&&(this.lineDistributionModule.diagram=this,this.connectors.forEach(function(P){P.obstaclePointCollection=[]}));var c=this.complexHierarchicalTreeModule.getLayoutNodesCollection(this.nodes);c.length>0&&this.complexHierarchicalTreeModule.doLayout(c,this.nameTable,this.layout,l,this),e=!0,this.canDistribute(a,r)&&this.lineDistributionModule.initLineDistribution(this.layout,this)}else this.flowchartLayoutModule?(this.flowchartLayoutModule.updateLayout(this.nodes,this),e=!0):console.warn("[WARNING] :: Module "+("OrganizationalChart"===this.layout.type?"HierarchicalTree":this.layout.type)+" is not available in Diagram component! You either misspelled the module name or forgot to load it.");if(e){this.preventDiagramUpdate=!0;for(var u={},p=0,g=o;p0)for(var S=0;S0)for(var M=0;M0)for(var s=0,o=r.ports;s0&&function Ese(n){var t,e,i,r=[];for(t=0;t0&&y.connectors[w].bezierSettings&&y.connectors[w].bezierSettings.allowSegmentsReset&&(y.connectors[w].segments=[]);if(t.connectors=y.connectors||[],t.dataSourceSettings=y.dataSourceSettings||{},t.dataSourceSettings.doBinding=i,t.height=y.height||"100%",t.setNodeTemplate=r,t.getConnectorDefaults=v,t.getNodeDefaults=g,t.getCustomProperty=o,t.mode=y.mode||"SVG",y.nodes)for(w=0;w0)){var r=this.nodes.filter(function(a){return 0===a.inEdges.length})[0],s=this.convertMindmapToMermaid(r,0);i.push(s),this.updateTextDataSource(i,r.outEdges,1),e=(i=i.filter(function(a){return""!==a.trim()})).join("\n")}return e},t.prototype.updateTextDataSource=function(e,i,r){for(var s=0;s0&&this.updateTextDataSource(e,h,r+1),s++}},t.prototype.convertMindmapToMermaid=function(e,i){var r=e.id,o=" ".repeat(2*(i+1)),a=e.annotations.length>0?e.annotations[0].content.replace(/\n/g," "):"",l=o+a,h=o+r;if(e.shape&&"Basic"===e.shape.type){var c=e.shape;"Rectangle"===c.shape?l=h+"["+a+"]":"Ellipse"===c.shape?l=h+"(("+a+"))":"Hexagon"===c.shape&&(l=h+"{{"+a+"}}")}else if(e.shape&&"Flow"===e.shape.type)"Terminator"===e.shape.shape&&(l=h+"("+a+")");else if(e.shape&&"Path"===e.shape.type){var u=e.shape;u.data===this.bangShape?l=h+"))"+a+"((":u.data===this.cloudShape&&(l=h+")"+a+"(")}return l},t.prototype.saveFlowDiagramInMermaidFormat=function(){var e=this,i=[],r="graph TD\n",s={nodes:this.nodes,edges:this.connectors};return s.nodes.reduce(function(a,l){return a[l.id]=l.annotations.length?l.annotations[0].content:"",a},{}),s.edges.forEach(function(a){var l=a.sourceID,h=a.targetID,f=e.nameTable[""+h],p=e.getNodeShape(e.nameTable[""+l]),g=e.getNodeShape(f),v=a.annotations[0]&&""!==a.annotations[0].content?"|"+a.annotations[0].content+"|":"";-1===i.indexOf(l)?i.push(l):p="",-1===i.indexOf(h)?i.push(h):g="";var y=e.arrowType(a);r+=" "+l+p+" "+y+v+" "+h+g+"\n"}),s.nodes.forEach(function(a){r+=" style "+a.id+" fill:"+a.style.fill+",stroke:"+a.style.strokeColor+",stroke-width:"+a.style.strokeWidth+"px;\n"}),r},t.prototype.arrowType=function(e){var i=e.targetDecorator.shape;return e.style.opacity<1?"~~~":""!==e.style.strokeDashArray?"-.->":"Arrow"===i?e.style.strokeWidth>1?"==>":"--\x3e":"None"===i?"---":"--\x3e"},t.prototype.getNodeShape=function(e){var i=e.annotations.length>0?e.annotations[0].content:"",r=e.shape.shape;if(!r){var s=e.shape.data;return"M 0 0 A 1 1 0 0 0 7 0 A 1 1 0 0 0 0 0 M -1 0 A 1 1 0 0 0 8 0 A 1 1 0 0 0 -1 0"===s?"((("+i+")))":"M 0 0 L 1 -1 L 5 -1 L 6 0 L 0 0"===s?"[/"+i+"\\]":"M 0 1 L 0 6 C 2 7 4 7 6 6 L 6 1 C 5 0 1 0 0 1 C 1 2 5 2 6 1"===s?"[("+i+")]":"M 0 0 L 12 0 L 14 2 L 2 2 L 0 0"===s?"[\\"+i+"\\]":"M 0 0 L 5 0 L 4 1 L 1 1 L 0 0"===s?"[\\"+i+"/]":"M 0 0 L 2 -2 L 11 -2 L 13 0 L 11 2 L 2 2 L 0 0"===s?"{{"+i+"}}":">"+i+"]"}switch(r){case"Terminator":return"(["+i+"])";case"Process":default:return"["+i+"]";case"Decision":return"{"+i+"}";case"Parallelogram":return"[/"+i+"/]";case"Ellipse":return"(("+i+"))";case"PreDefinedProcess":return"[["+i+"]]"}},t.prototype.loadDiagramFromMermaid=function(e){this.layout&&"Flowchart"===this.layout.type&&this.flowchartLayoutModule?this.convertMermaidToFlowChart(e):this.layout&&"MindMap"===this.layout.type&&this.mindMapChartModule?this.convertMermaidToMindmap(e):console.warn('[WARNING] :: Module "FlowchartLayout" or "MindMap" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.countLeadingSpaces=function(e){for(var i=0,r=e.length;i0});this.clear(),this.mermaidNodeBaseCollection=[];var r=[],s={text:"",children:[],currentLevel:0,branch:"Left"},o=[],l=!1,h=!1,c=!1;if(i.length>0){for(var d=function(M){var w=i[parseInt(M.toString(),10)],C=0,D="",A=u.countLeadingSpaces(w),x=w.includes('"`');if(h=w.includes('`"'),c=(l=!!x||l)||c?c:0===A&&M>0,l&&h&&!x)return s.text+="\n"+w,l=!1,"continue";if(!x&&l)return s.text+="\n"+w,"continue";if(l=!h&&l,w.length>0&&(/\s/.test(w[0])&&M>0||0===A)){if(-1!==o.findIndex(function(B){return B.space===A.toString()}))for(var L=o.length-1;L>=0;L--){var O=o[parseInt(L.toString(),10)];if((N=parseFloat(O.space))>A)o.splice(L,1);else{if(N=0;L--){var N,T=o[parseInt(L.toString(),10)];if(!((N=parseFloat(T.space))>A)){var z=o[o.length-1];o.push({space:A.toString(),level:z.level+1});break}o.splice(L,1)}C=o[o.length-1].level}D=w.trim().replace(/^[+-]/,"")}var U={text:D,branch:void 0,children:[],currentLevel:0===M?0:C-1};if(r.length>0){for(;r.length>=C&&0!==r.length;)r.pop();r.length>0&&r[r.length-1].children.push(U)}r.push(U),s=U},u=this,f=0;f0){var c=h[h.length-1];c.arrowType=a[2],""!==a[3]&&(c.label&&c.label.some(function(d){return d.trim().length>0})?c.label.push(a[3]):(c.label=[],c.label[c.parentId.length-1]=a[3]))}h.filter(function(d){return d.parentId&&0===d.parentId.length}).forEach(function(d){d.parentId=null}),i=i.concat(h)}}this.createFlowChart(i),this.doLayout(),this.clearHistory()},t.prototype.createFlowChart=function(e){for(var i=[],r=0;r1)for(var h=0;h|---|--\s*.*?\s*-->|~~~|==>|===|==\s*.*?\s*==>|\s*-\.\s*->|\s*-\.\s*-|\s*-\.\s*.*?\s*\.\s*->|\s*-\..*?\.\s*->)(.*)$/);if(l){i=l[1].trim();var h=l[2].trim();r=l[3].trim();var d=h.match(/(-\.|\\-\\-|==|--|~~)(.*?)(\1>|\.->|==>|\\->|~~>)/),u=void 0,f="";o=null!==(u=d?{text:d[2].trim()||null,arrowType:d[1]+d[3]}:{text:null,arrowType:h}).text?u.text:"",s=(f=u.arrowType).includes("--\x3e")?"single-line-arrow":f.includes("---")?"single-line":f.includes("==>")?"double-line-arrow":f.includes("==")?"double-line":f.includes("~~~")?"wiggly-arrow":f.includes("-.->")||f.includes(".->")?"dotted-arrow":f.includes("-.-")||f.includes(".-")?"dotted":"single-line-arrow"}return[i,r,s,o]},t.prototype.parseStyle=function(e,i){if(e.startsWith("style")){var s=e.match(/^style\s+(\w+)\s+fill:([^,]+),stroke:([^,]+),stroke-width:(\d+)px;/);if(s){var c={id:s[1],fill:s[2],stroke:s[3],strokeWidth:parseInt(s[4],10)},d=i.filter(function(u){return u.id===c.id});d[0].color=c.fill,d[0].stroke=c.stroke,d[0].strokeWidth=c.strokeWidth}}},t.prototype.getNodeData=function(e,i,r){for(var s=[],o=null,a=null,l=0,h="",c=function(v){var y=e[parseInt(v.toString(),10)],S=d.splitNested(y);if(S[0].includes("|")){var b=S[0].match(/\|([^|]*)\|/);b&&(h=b[1]);var M=S[0].split("|");M.length>=3&&(S[0]=M[2].trim())}var w=S[0].trim();if(0===v?o=w:a=w,i.find(function(L){return L.id===w}))l++;else{var D=S.length>1?S[1]:S[0],A=d.getShape(D),x=D.replace(/[\\[\]\\(\\)\\{\\}\\{\\}\\/>]/g,"");s.push({id:w,name:x,shape:A,color:"white",parentId:[]})}},d=this,u=0;u"===h?0===s?(r.trim().length>0&&i.push(r.trim()),r=h,o=h,s++):(r+=h,s++):"]"===h||"}"===h||")"===h?1===s&&h===o?(i.push((r+=h).trim()),r="",s--):s>1?(r+=h,s--):r+=h:r+=h}return r.trim().length>0&&i.push(r.trim()),i},t.prototype.getShape=function(e){var i={};return e.startsWith("(((")?i={type:"Path",data:"M 0 0 A 1 1 0 0 0 7 0 A 1 1 0 0 0 0 0 M -1 0 A 1 1 0 0 0 8 0 A 1 1 0 0 0 -1 0"}:e.startsWith("((")?i={shape:"Ellipse",type:"Basic"}:e.startsWith("([")?i={type:"Flow",shape:"Terminator"}:e.startsWith("(")?i={type:"Flow",shape:"Process"}:e.startsWith("[[")?i={type:"Flow",shape:"PreDefinedProcess"}:e.startsWith("[/")?i=e.endsWith("/]")?{type:"Basic",shape:"Parallelogram"}:{type:"Path",data:"M 0 0 L 1 -1 L 5 -1 L 6 0 L 0 0"}:e.startsWith("[(")?i={type:"Path",data:"M 0 1 L 0 6 C 2 7 4 7 6 6 L 6 1 C 5 0 1 0 0 1 C 1 2 5 2 6 1"}:e.startsWith("[\\")?i=e.endsWith("\\]")?{type:"Path",data:"M 0 0 L 12 0 L 14 2 L 2 2 L 0 0"}:{type:"Path",data:"M 0 0 L 5 0 L 4 1 L 1 1 L 0 0"}:e.startsWith("[")?i={type:"Basic",shape:"Rectangle"}:e.startsWith("{{")?i={type:"Path",data:"M 0 0 L 2 -2 L 11 -2 L 13 0 L 11 2 L 2 2 L 0 0"}:e.startsWith("{")?i={type:"Flow",shape:"Decision"}:e.startsWith(">")&&(i={type:"Path",data:"M 0 0 L 8 0 L 8 2 L 0 2 L 2 1 L 0 0"}),i},t.prototype.getDiagramContent=function(e){return this.printandExportModule?this.printandExportModule.getDiagramContent(e):(console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),"")},t.prototype.exportImage=function(e,i){this.printandExportModule?this.printandExportModule.exportImages(e,i):console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.printImage=function(e,i){this.printandExportModule?(i.printOptions=!0,this.printandExportModule.exportImages(e,i)):console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.setStackLimit=function(e){this.undoRedoModule&&e&&(this.historyManager.stackLimit=e,this.undoRedoModule.applyLimit(this.historyManager.currentEntry,e,this,!0))},t.prototype.clearHistory=function(){this.undoRedoModule&&this.undoRedoModule.clearHistory(this)},t.prototype.getDiagramBounds=function(){if(this.printandExportModule){var e=this.printandExportModule.getDiagramBounds("",{});return e.width=e.width>this.scrollSettings.viewPortWidth?e.width+(e.x>0?e.x:0):this.scrollSettings.viewPortWidth,e.height=e.height>this.scrollSettings.viewPortHeight?e.height+(e.y>0?e.y:0):this.scrollSettings.viewPortHeight,e.x=e.x>0?0:e.x,e.y=e.y>0?0:e.y,e}return console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),new Ne},t.prototype.exportDiagram=function(e){return this.printandExportModule?this.printandExportModule.exportDiagram(e):(console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),"")},t.prototype.print=function(e){this.printandExportModule?this.printandExportModule.print(e):console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.addPorts=function(e,i){var s;this.protectPropertyChange(!0),e=this.nameTable[e.id]||e,i.length>1&&this.startGroupAction();for(var o=function(h){if(e.ports.some(function(y){return y.id===i[parseInt(h.toString(),10)].id}))return"continue";if(e instanceof te?(s=new Es(e,"ports",i[parseInt(h.toString(),10)],!0),e.ports.push(s)):e instanceof de&&(s=new Tc(e,"ports",i[parseInt(h.toString(),10)],!0),e.ports.push(s)),e.children)for(var c=e.wrapper,d=0;d1&&this.endGroupAction(),e.wrapper.measure(new me(e.width,e.height)),e.wrapper.arrange(e.wrapper.desiredSize),this.updateDiagramObject(e),this.protectPropertyChange(!1)},t.prototype.addConstraints=function(e,i){return e|i},t.prototype.removeConstraints=function(e,i){return e&~i},t.prototype.addNodeLabels=function(e,i){this.addLabels(e,i)},t.prototype.addConnectorLabels=function(e,i){this.addLabels(e,i)},t.prototype.addLabels=function(e,i){this.protectPropertyChange(!0);var s,r=(e=this.nameTable[e.id]||e).wrapper;i.length>1&&this.startGroupAction();for(var o=0;o1&&this.endGroupAction(),e.wrapper.measure(new me(r.width,r.height)),e.wrapper.arrange(r.desiredSize),this.updateDiagramObject(e),this.protectPropertyChange(!1),this.refreshCanvasLayers()},t.prototype.addChildToUmlNode=function(e,i,r){var s,o,a,l,h="NoWrap";"Class"===e.shape.classifier||"Interface"===e.shape.classifier?"Method"===r?(o=new cm(e,"",i),"Class"===e.shape.classifier?(e.shape.classShape.methods.push(o),s=e.shape.classShape):"Interface"===e.shape.classifier&&(e.shape.interfaceShape.methods.push(o),s=e.shape.interfaceShape),function Xse(n,t,e,i){if(e.methods&&e.methods.length){var r=e.methods,s="",o="",a=void 0,l=1,h=void 0,c=0,d=0,u=n.shape,g="Class"===u.classifier?u.classShape:u.interfaceShape;1===r.length?g.attributes.length>0?(c=g.attributes.filter(function(w){return w.isSeparator}).length,h=(l=2+g.attributes.length+c)+1,nT(n,t,l)):h=l+1:(c=g.attributes.filter(function(w){return w.isSeparator}).length,d=g.methods.filter(function(w){return w.isSeparator}).length,h=(l=2+g.attributes.length+c+g.methods.length+d)+1);for(var v=0;v1&&this.startGroupAction();for(var r=i.length-1;r>=0;r--)if(e.children&&e.children.length>0){var s=e.wrapper.children.filter(function(o){return o.id===e.id+"group_container"});s&&s.length>0&&this.removelabelExtension(e,i,r,s[0])}else this.removelabelExtension(e,i,r,e.wrapper);i.length>1&&this.endGroupAction(),this.refreshCanvasLayers()},t.prototype.removePortsExtenion=function(e,i,r,s){for(var o=0;o1&&this.startGroupAction();for(var r=i.length-1;r>=0;r--)if(e.children&&e.children.length>0)for(var s=0;s1&&this.endGroupAction()},t.prototype.getSizeValue=function(e,i){var r;return r=e.toString().indexOf("px")>0?e.toString():e.toString().indexOf("%")>0?void 0!==i?"100%":e.toString():e.toString()+"px",i&&(Za(this),r="calc("+r+" - "+i+"px)"),r},t.prototype.renderRulers=function(){this.rulerSettings.showRulers?(function Yne(n){var t=Za(n),i=Tt("div",{id:n.element.id+"_overlapRuler",style:"height:"+t.height+"px;width:"+t.width+"px;position:absolute;left:0;top:0",class:"e-ruler-overlap"});n.element.insertBefore(i,n.element.firstChild)}(this),eF(this,!0),eF(this,!1)):Qx(this)},t.prototype.intOffPageBackground=function(){var e=new me;e=Za(this);var i=document.getElementById(this.element.id+"content"),r=this.getSizeValue(this.width,e.width),s=this.getSizeValue(this.height,e.height),o=this.rulerSettings.showRulers?"width:"+r+"; height:"+s+";top:"+e.height+"px;left:"+e.width+"px;overflow: scroll;position:absolute;overflow:auto;":"width:"+r+"; height:"+s+";position:absolute; left:0px; top:0px;overflow: auto;",a={id:this.element.id+"content",tabindex:"0",style:o};i?(this.diagramCanvas=i,Ka(this.diagramCanvas,o)):(this.diagramCanvas=Tt("div",a),this.element.appendChild(this.diagramCanvas)),this.diagramCanvas.style.background=this.backgroundColor},t.prototype.initDiagram=function(){this.intOffPageBackground(),Ho(this.element,{style:"width:"+this.getSizeValue(this.width)+"; height:"+this.getSizeValue(this.height)+";position:relative;overflow:hidden;"})},t.prototype.renderHiddenUserHandleTemplateLayer=function(e){var r=Tt("div",{class:this.element.id+"_hiddenUserHandleTemplate",style:"width:"+e.width+"px; height:"+e.height+"px;visibility:hidden ; overflow: hidden;"});this.element.appendChild(r)},t.prototype.renderBackgroundLayer=function(e,i){var r=this.createSvg(this.element.id+"_backgroundLayer_svg",e.width,e.height);Ka(r,i);var s=Fi("g",{id:this.element.id+"_backgroundImageLayer",class:"e-background-image-layer"});r.appendChild(s);var a=Fi("g",{id:this.element.id+"_backgroundLayer",class:"e-background-layer"});r.appendChild(a),this.diagramCanvas.appendChild(r)},t.prototype.renderGridLayer=function(e,i){var r=this.createSvg(this.element.id+"_gridline_svg",e.width,e.height);r.setAttribute("class","e-grid-layer");var s=Fi("g",{id:this.element.id+"_gridline"}),o=Fi("rect",{id:this.element.id+"_grid_rect",x:"0",y:"0",width:"100%",height:"100%"});if(sm()){var a=new URL(window.location.href);o.setAttribute("fill",""!==a.search?"url(#"+this.element.id+"_pattern)":"url("+location.protocol+"//"+location.host+location.pathname+"#"+this.element.id+"_pattern)")}else o.setAttribute("fill","url(#"+this.element.id+"_pattern)");s.appendChild(o),r.appendChild(s),this.diagramCanvas.appendChild(r),ii(r,{style:i})},t.prototype.renderDiagramLayer=function(e,i){if(this.diagramLayerDiv=Tt("div",{id:this.element.id+"_diagramLayer_div",style:"width:"+e.width+"px; height:"+e.height+"px;"+i}),"SVG"===this.mode){var s=this.createSvg(this.element.id+"_diagramLayer_svg",e.width,e.height);s.style["pointer-events"]="none",s.setAttribute("class","e-diagram-layer");var o=Fi("g",{id:this.element.id+"_diagramLayer"}),a=Fi("g",{});this.diagramLayer=o,s.style["pointer-events"]="all",a.appendChild(o),s.appendChild(a),this.diagramLayerDiv.appendChild(s)}else this.diagramLayer=bo.createCanvas(this.element.id+"_diagram",e.width,e.height),Ka(this.diagramLayer,"position:absolute;left:0px;top:0px;"),this.diagramLayerDiv.appendChild(this.diagramLayer);this.diagramCanvas.appendChild(this.diagramLayerDiv)},t.prototype.initLayers=function(){var e="position:absolute;top:0px;left:0px;overflow:hidden;pointer-events:none;",r=document.getElementById(this.element.id).getBoundingClientRect(),s=function Soe(){var n=Tt("div",{style:"visibility:hidden; width: 100px"});document.body.appendChild(n);var t=n.getBoundingClientRect().width;n.style.overflow="scroll";var e=Tt("div",{style:"width:100%"});n.appendChild(e);var i=e.getBoundingClientRect().width;return n.parentNode.removeChild(n),t-i}();this.scroller.scrollerWidth=s,this.scroller.setViewPortSize(r.width,r.height),this.renderRulers();var o="measureElement";window[""+o]&&(window[""+o]=null,document.getElementById("measureElement").remove()),function BF(){var n="measureElement";if(window[""+n])window[""+n].usageCount+=1;else{var t=Tt("div",{id:"measureElement",style:"visibility:hidden ; height: 0px ; width: 0px; overflow: hidden;"}),e=Tt("span",{style:"display:inline-block ; line-height: normal"});t.appendChild(e);var i=Tt("img",{alt:"measureElementImage",src:"data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7"});t.appendChild(i);var r=document.createElementNS("http://www.w3.org/2000/svg","svg");r.setAttribute("xmlns:xlink","http://www.w3.org/1999/xlink"),t.appendChild(r);var s=document.createElementNS("http://www.w3.org/2000/svg","path");s.setAttribute("d",""),r.appendChild(s),document.createTextNode("");var a=document.createElementNS("http://www.w3.org/2000/svg","text");a.setAttributeNS("http://www.w3.org/XML/1998/namespace","xml:space","preserve"),r.appendChild(a),window[""+n]=t,window[""+n].usageCount=1,document.body.appendChild(t);var l="measureElementCount";window[""+l]?window[""+l]++:window[""+l]=1}}(),this.renderBackgroundLayer(r,e),this.renderGridLayer(r,e),this.renderDiagramLayer(r,e),this.renderHTMLLayer(r,e),this.renderPortsExpandLayer(r,e),this.renderNativeLayer(r,e),this.renderAdornerLayer(r,e),this.renderHiddenUserHandleTemplateLayer(r)},t.prototype.renderAdornerLayer=function(e,i){var r=Tt("div",{id:this.element.id+"_diagramAdornerLayer",style:"width:"+e.width+"px;height:"+e.height+"px;"+i}),s=Tt("div",{id:this.element.id+"_diagramUserHandleLayer",style:"width:"+e.width+"px;height:"+e.height+"px;"+i});s.setAttribute("class","e-userHandle-layer"),r.appendChild(s);var o=this.createSvg(this.element.id+"_diagramAdorner_svg",e.width,e.height);o.setAttribute("class","e-adorner-layer"),o.style["pointer-events"]="none",this.adornerLayer=Fi("g",{id:this.element.id+"_diagramAdorner"}),this.adornerLayer.style[" pointer-events"]="all",o.appendChild(this.adornerLayer),r.appendChild(o),this.diagramCanvas.appendChild(r);var a=Fi("g",{id:this.element.id+"_SelectorElement"});this.adornerLayer.appendChild(a),ii(o,{style:"pointer-events:none;"})},t.prototype.renderPortsExpandLayer=function(e,i){var r=this.createSvg(this.element.id+"_diagramPorts_svg",e.width,e.height);r.setAttribute("class","e-ports-expand-layer");var s=Fi("g",{id:this.element.id+"_diagramPorts",class:"e-ports-layer",style:"pointer-events: all;"});r.appendChild(s);var o=Fi("g",{id:this.element.id+"_diagramExpander",class:"e-expand-layer",style:"pointer-events: all;"});r.appendChild(o),this.diagramCanvas.appendChild(r),ii(r,{style:i})},t.prototype.renderHTMLLayer=function(e,i){this.htmlLayer=Tt("div",{id:this.element.id+"_htmlLayer",style:"width:"+e.width+"px; height:"+e.height+"px;position:absolute;top:0px;left:0px;overflow:hidden;pointer-events:none;",class:"e-html-layer"});var r=Tt("div",{id:this.element.id+"_htmlLayer_div",style:"position:absolute;top:0px;left:0px;pointer-events:all;"});this.htmlLayer.appendChild(r),this.diagramCanvas.appendChild(this.htmlLayer)},t.prototype.renderNativeLayer=function(e,i){var r=this.createSvg(this.element.id+"_nativeLayer_svg",e.width,e.height),s=Fi("g",{id:this.element.id+"_nativeLayer",style:"pointer-events:all;"});r.appendChild(s),this.diagramLayerDiv.appendChild(r),ii(r,{class:"e-native-layer",style:i})},t.prototype.createSvg=function(e,i,r){var s=document.createElementNS("http://www.w3.org/2000/svg","svg");return ii(s,{id:e,width:i,height:r}),s},t.prototype.updateBazorShape=function(){for(var e=0;e1,i=[],r={},s={},o=[],a=0,l=this.nodes;a0||b&&b.children&&b.children.length>0)&&(M=!1),S&&S.wrapper&&b&&b.wrapper&&M?this.initConnectors(r[""+h],p):i.push(r[""+h])}else b=r[y.targetID],(S=r[y.sourceID])&&S.children&&S.children.length>0||b&&b.children&&b.children.length>0?i.push(r[""+h]):this.initConnectors(r[""+h],p);else r[""+h].children?o.push(h):r[""+h].shape instanceof hT&&r[""+h].shape.activity.subProcess.processes&&r[""+h].shape.activity.subProcess.processes.length>0?s[r[""+h].id]=h:this.initNodes(r[""+h],p);if(this.bpmnModule)for(var w=0,C=this.bpmnModule.bpmnTextAnnotationConnector;w-1&&-1===r.indexOf(c)&&-1===s.indexOf(c)&&r.splice(0,0,c);-1===r.indexOf(o)&&s.push(o)}return r.concat(s)},t.prototype.addToLayer=function(e,i){var r;if(i&&(r=this.commandHandler.getObjectLayer(e.id)),(!i||!r)&&-1===this.activeLayer.objects.indexOf(e.id)&&this.activeLayer.objects.push(e.id),(e instanceof te||e instanceof de)&&("SwimLane"!==e.shape.type||e.children&&e.children.length>0)){if(e.parentId){var s=this.swimlaneZIndexTable[e.parentId],o=this.swimlaneChildTable[e.id];(s&&-1!==s||o&&-1!==o)&&(e.zIndex=this.swimlaneChildTable[e.id])}e instanceof de&&e.sourceID&&e.targetID?-1!==this.activeLayer.objects.indexOf(e.sourceID)&&-1!==this.activeLayer.objects.indexOf(e.targetID)&&this.setZIndex(r||this.activeLayer,e):this.setZIndex(r||this.activeLayer,e)}},t.prototype.updateLayer=function(e){for(var i=0,r=Object.keys(e.layers);i0)for(r=0;rs;l--)r.zIndexTable[parseInt(l.toString(),10)]=r.zIndexTable[l-1],this.nameTable[r.zIndexTable[parseInt(l.toString(),10)]]&&(this.nameTable[r.zIndexTable[parseInt(l.toString(),10)]].zIndex=l);r.zIndexTable[parseInt(a.toString(),10)]=i.id}}},t.prototype.initializeDiagramLayers=function(){for(var e=0;ethis.layers[parseInt(a.toString(),10)].zIndex&&(i=this.layers[parseInt(e.toString(),10)],this.layers[parseInt(e.toString(),10)]=this.layers[parseInt(a.toString(),10)],this.layers[parseInt(a.toString(),10)]=i);0===this.layers.length&&this.commandHandler.addLayer({id:"default_layer",visible:!0,lock:!1,objects:[],zIndex:0,objectZIndex:-1,zIndexTable:{}},null,!0),this.setActiveLayer(this.layers[this.layers.length-1].id)},t.prototype.resetTool=function(){this.eventHandler.resetTool()},t.prototype.initObjectExtend=function(e,i,r){if(r){var s=this.commandHandler.checkBoundaryConstraints(void 0,void 0,e.wrapper.bounds,!0);if("SwimLane"===e.shape.type)for(var o=0,a=Object.keys(i.zIndexTable);o0)&&this.setZIndex(i,e)),e instanceof te){if(r){if("helper"!==e.id&&(o=Zi(this.getNodeDefaults))){if((a=o(e,this))&&a.ports)for(var l=0;l0)for(l=0;l0&&!e.container||e.processId){var r=this.nameTable[e.id];if(!(this.realActions&$i.PreventScale||this.realActions&$i.PreventDrag)){if(r.offsetX&&(this.realActions&$i.EnableGroupAction||!(this.diagramActions&ee.UndoRedo||this.diagramActions&ee.ToolAction||this.diagramActions&ee.PublicMethod))){this.realActions|=$i.PreventScale;var s=r.offsetX-e.wrapper.offsetX;r.offsetX=e.wrapper.offsetX;var o=r.offsetY-e.wrapper.offsetY;r.offsetY=e.wrapper.offsetY,s+o!==0&&this.drag(r,s,o),this.realActions&=~$i.PreventScale}else r.offsetX=e.wrapper.offsetX;r.offsetY&&(this.realActions&$i.EnableGroupAction||!(this.diagramActions&ee.UndoRedo||this.diagramActions&ee.ToolAction||this.diagramActions&ee.PublicMethod))?(this.realActions|=$i.PreventScale,o=r.offsetY-e.wrapper.offsetY,r.offsetY=e.wrapper.offsetY,this.drag(r,0,o),this.realActions&=~$i.PreventScale):r.offsetY=e.wrapper.offsetY,this.diagramActions&&(r.width=e.wrapper.actualSize.width,r.height=e.wrapper.actualSize.height)}}i&&e.children&&e.children.length>0&&(void 0!==this.nameTable[e.id].width?this.scaleObject(e,this.nameTable[e.id].width,!0):this.nameTable[e.id].width=e.wrapper.actualSize.width,void 0!==this.nameTable[e.id].height?this.scaleObject(e,this.nameTable[e.id].height,!1):this.nameTable[e.id].height=e.wrapper.actualSize.height)},t.prototype.initNode=function(e,i,r){var a,f,s=e.initContainer(),o=new Mi;if(this.diagramSettings.inversedAlignment||(s.inversedAlignment=!1),s.children||(s.children=[]),e.children){s.measureChildren=!1,o.id=e.id+"group_container",o.style.fill=e.shape&&"SwimLane"===e.shape.type?e.style.fill:"none",o.style.strokeColor="none",o.horizontalAlignment="Stretch",o.verticalAlignment="Stretch",o.pivot=e.pivot,s.style=e.style,s.padding.left=e.padding.left,s.padding.right=e.padding.right,s.padding.top=e.padding.top,s.padding.bottom=e.padding.bottom,o.children=[],o.preventContainer=!0,e.container&&(o.relativeMode="Object");var l=!!(e.ports&&e.ports.length>0);if(m(e.container)&&!l&&s.children.push(o),e.container&&"Grid"===e.container.type)for(var h=0;h0&&e.wrapper.children[0]instanceof Wv){if(this.setZIndex(this.activeLayer,e),this.connectors.length>0)for(h=0;h0?i.phases.length:0,v="Horizontal"===i.orientation,y=v?i.phases.length||1:s.length+1,S=v?(i.header&&i.hasHeader?1:0)+(i.phases.length>0?1:0)+i.lanes.length:(i.header&&i.hasHeader?1:0)+i.phases.length;if(0===h&&!v&&i.lanes.length&&(S+=1),v?(a=(i.header&&i.hasHeader?1:0)+(h>0?1:0),l=0):(a=i.header&&i.hasHeader?1:0,l=h>0?1:0),s.length>0)for(o+=i.header&&i.hasHeader?i.header.height:0,f=0;fl?d.margin.left=d.margin.left-(u.bounds.left-e.bounds.left):u.children[0].children[1].actualSize.width+r>=d.margin.left&&(d.margin.left=u.children[0].children[1].actualSize.width+r),d.margin.lefta?d.margin.top=d.margin.top-(u.bounds.top-o):u.children[0].children[1].actualSize.height+r>=d.margin.top&&(d.margin.top=u.children[0].children[1].actualSize.height+r),d.margin.left0)for(o=0;o0&&this.updateChildPosition(e)},t.prototype.addBpmnAnnotationConnector=function(e,i){if(e.parentObj instanceof t||e.parentObj instanceof Hd){var r=e.shape,o=""!==r.textAnnotation.textAnnotationTarget&&this.nameTable[r.textAnnotation.textAnnotationTarget],a=o?this.nameTable[r.textAnnotation.textAnnotationTarget]:null,l=null!=a?a.wrapper:null,h=e.ports[0],c={x:0,y:0};switch(r.textAnnotation.textAnnotationDirection){case"Left":h.offset={x:0,y:.5},c.x=i.bounds.left-40,c.y=i.bounds.bottom+30;break;case"Right":h.offset={x:1,y:.5},c.x=i.bounds.right+40,c.y=i.bounds.bottom+30;break;case"Top":h.offset={x:.5,y:0},c.x=i.bounds.right+30,c.y=i.bounds.top-40;break;case"Bottom":h.offset={x:.5,y:1},c.x=i.bounds.right+30,c.y=i.bounds.bottom+40;break;default:h.offset={x:0,y:.5},c.x=i.bounds.left-40,c.y=i.bounds.bottom+30,o&&null!=i&&null!=l&&(i.bounds.left>l.bounds.right?h.offset={x:0,y:.5}:i.bounds.rightl.bounds.top?h.offset={x:.5,y:0}:i.bounds.top0&&this.updateChildPosition(r)}},t.prototype.canExecute=function(){return!0},t.prototype.updateStackProperty=function(e,i,r){e.container&&"Stack"===e.container.type&&(i.width||(i.wrapper.horizontalAlignment="Stretch",i.horizontalAlignment="Stretch"),i.height||(i.verticalAlignment="Stretch",i.wrapper.verticalAlignment="Stretch"),r&&"UmlClassifier"===e.shape.type&&(i.umlIndex=r))},t.prototype.initViews=function(){this.isLoading||(this.views.push(this.element.id),this.views[this.element.id]=this)},t.prototype.initCommands=function(){var e=this.commandManager.commands,i={copy:{execute:this.copyCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.C,keyModifiers:ft.Control}},paste:{execute:this.pasteCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.V,keyModifiers:ft.Control}},cut:{execute:this.cutCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.X,keyModifiers:ft.Control}},delete:{execute:this.removeCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Delete}},selectAll:{execute:this.selectAll.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.A,keyModifiers:ft.Control}},undo:{execute:this.undo.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Z,keyModifiers:ft.Control}},redo:{execute:this.redo.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Y,keyModifiers:ft.Control}},nudgeUp:{execute:this.nudgeCommand.bind(this,"Up"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Up},parameter:"up"},nudgeRight:{execute:this.nudgeCommand.bind(this,"Right"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Right},parameter:"right"},nudgeDown:{execute:this.nudgeCommand.bind(this,"Down"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Down},parameter:"down"},nudgeLeft:{execute:this.nudgeCommand.bind(this,"Left"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Left},parameter:"left"},startEdit:{execute:this.startEditCommad.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.F2}},endEdit:{execute:this.endEditCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Escape}},focusToNextItem:{execute:this.navigateItems.bind(this,!0),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Tab}},focusToPreviousItem:{execute:this.navigateItems.bind(this,!1),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Tab,keyModifiers:ft.Shift}},selectFocusedItem:{execute:this.startEditCommad.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Enter}},bold:{execute:this.fontStyleCommand.bind(this,"bold"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.B,keyModifiers:ft.Control}},italic:{execute:this.fontStyleCommand.bind(this,"italic"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.I,keyModifiers:ft.Control}},underline:{execute:this.fontStyleCommand.bind(this,"underline"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.U,keyModifiers:ft.Control}},duplicate:{execute:this.duplicateCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.D,keyModifiers:ft.Control}},group:{execute:this.groupCommand.bind(this,"group"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.G,keyModifiers:ft.Control}},ungroup:{execute:this.groupCommand.bind(this,"ungroup"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.U,keyModifiers:ft.Control|ft.Shift}},rotateClockwise:{execute:this.rotateCommand.bind(this,"clockwise"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.R,keyModifiers:ft.Control}},rotateAntiClockwise:{execute:this.rotateCommand.bind(this,"antiClockwise"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.L,keyModifiers:ft.Control}},flipHorizontal:{execute:this.flipCommand.bind(this,"horizontal"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.H,keyModifiers:ft.Control}},flipVertical:{execute:this.flipCommand.bind(this,"vertical"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.J,keyModifiers:ft.Control}},pointerTool:{execute:this.toolCommand.bind(this,"pointer"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number1,keyModifiers:ft.Control}},textTool:{execute:this.toolCommand.bind(this,"text"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number2,keyModifiers:ft.Control}},connectTool:{execute:this.toolCommand.bind(this,"connect"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number3,keyModifiers:ft.Control}},freeForm:{execute:this.toolCommand.bind(this,"freeForm"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number5,keyModifiers:ft.Control}},lineTool:{execute:this.toolCommand.bind(this,"line"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number6,keyModifiers:ft.Control}},rectangleTool:{execute:this.toolCommand.bind(this,"rectangle"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number8,keyModifiers:ft.Control}},ellipseTool:{execute:this.toolCommand.bind(this,"ellipse"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number9,keyModifiers:ft.Control}},zoomIn:{execute:this.zoomCommand.bind(this,"zoomIn"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Plus,keyModifiers:ft.Control}},zoomOut:{execute:this.zoomCommand.bind(this,"zoomOut"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Minus,keyModifiers:ft.Control}},shiftUp:{execute:this.shiftCommand.bind(this,"Up"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Up,keyModifiers:ft.Shift}},shiftDown:{execute:this.shiftCommand.bind(this,"Down"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Down,keyModifiers:ft.Shift}},shiftLeft:{execute:this.shiftCommand.bind(this,"Left"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Left,keyModifiers:ft.Shift}},shiftRight:{execute:this.shiftCommand.bind(this,"Right"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Right,keyModifiers:ft.Shift}},alignTextCenter:{execute:this.alignCommand.bind(this,"center"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.C,keyModifiers:ft.Control|ft.Shift}},alignTextLeft:{execute:this.alignCommand.bind(this,"right"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.L,keyModifiers:ft.Control|ft.Shift}},alignTextRight:{execute:this.alignCommand.bind(this,"left"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.R,keyModifiers:ft.Control|ft.Shift}},alignTextTop:{execute:this.alignCommand.bind(this,"top"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.E,keyModifiers:ft.Control|ft.Shift}},alignTextCenterVertical:{execute:this.alignCommand.bind(this,"centerVertical"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.M,keyModifiers:ft.Control|ft.Shift}},alignTextBottom:{execute:this.alignCommand.bind(this,"bottom"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.V,keyModifiers:ft.Control|ft.Shift}},alignJustify:{execute:this.alignCommand.bind(this,"justify"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.J,keyModifiers:ft.Control|ft.Shift}},sendToBack:{execute:this.orderCommand.bind(this,"sendToBack"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.B,keyModifiers:ft.Control|ft.Shift}},bringToFront:{execute:this.orderCommand.bind(this,"bringToFront"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.F,keyModifiers:ft.Control|ft.Shift}},sendBackward:{execute:this.orderCommand.bind(this,"sendBackward"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.BracketLeft,keyModifiers:ft.Control}},bringForward:{execute:this.orderCommand.bind(this,"bringForward"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.BracketRight,keyModifiers:ft.Control}}};this.initCommandManager(e,i)},t.prototype.overrideCommands=function(e,i){for(var r,s=0,o=Object.keys(i);se.zIndex){("HTML"===e.shape.type||"Native"===e.shape.type)&&(o="HTML"===e.shape.type?"html":"native"),s=poe(i,r[parseInt(a.toString(),10)].id,o);break}return s},t.prototype.updateDiagramObject=function(e,i,r){for(var s,o="domTable",a=0,l=this.views;a1&&(d=this.commandHandler.getObjectLayer(e.id)),void 0===d||d&&d.visible||r){var u=Io(this.element.id);window[""+o][s.element.id+"_diagramLayer"]||(window[""+o][s.element.id+"_diagramLayer"]=document.getElementById(s.element.id+"_diagramLayer"));var f=window[""+o][s.element.id+"_diagramLayer"];this.diagramActions&ee.Interactions&&this.updateCanupdateStyle(e.wrapper.children,!0);var p=this.getMidPoint(e);this.diagramRenderer.updateNode(e.wrapper,f,u,void 0,i?void 0:this.getZindexPosition(e,s.element.id),p,this.portCenterPoint),this.updateCanupdateStyle(e.wrapper.children,!0)}}},t.prototype.applyMarginBezier=function(e,i){i.cx=i.cx+e.margin.left,i.cx=i.cx-e.margin.right,i.cy=i.cy+e.margin.top,i.cy=i.cy-e.margin.bottom},t.prototype.getMidPoint=function(e){var i;if(e instanceof de&&"Bezier"===e.type){i=[];for(var r=this.getBezierPoints(e),s=R.getLengthFromListOfPoints(r),o=0;o0&&e.updateView(e));var s=Io(e.element.id);this.renderDiagramElements(e.diagramLayer,e.diagramRenderer,s,void 0,void 0,i);for(var o=0;o0&&this.renderBasicElement(e),!this.diagramActions||!(this.diagramActions&ee.Render)||ee.ToolAction&this.diagramActions||Ds(this)||1!==this.scroller.currentZoom?this.refreshElements(e):this.renderTimer||(this.renderTimer=setTimeout(function(){i.refreshElements(e)},40)))},t.prototype.updatePortVisibility=function(e,i,r){var s;if((e instanceof te||e instanceof de)&&(!this.drawingObject||!this.drawingObject.shape)&&ro(e)){for(var a=e.ports,l=!1,h=0;h=0&&this.scroller.removeCollection.splice(l,1);var h=this.nameTable[e[parseInt(a.toString(),10)]];this.updateTextElementValue(h),this.diagramRenderer.renderElement(h.wrapper,s,o,void 0,void 0,void 0,void 0,h.zIndex)}for(var c=0;c0?this.scroller.oldCollectionObjects:void 0,b=Object.keys(S||g.zIndexTable);b.sort(function(N,T){return parseInt(""+N,10)-parseInt(""+T,10)});for(var M=0,w=b;M0?h:0)+"px",y=(this.realActions&$i.vScrollbarMoved?0:-(this.scroller.verticalOffset<0?this.scroller.verticalOffset:0))+"px"):(v="0px",y="0px"),this.realActions&$i.hScrollbarMoved&&(this.realActions=this.realActions&~$i.hScrollbarMoved),this.realActions&$i.vScrollbarMoved&&(this.realActions=this.realActions&~$i.vScrollbarMoved)):(v=(l.x<0?h:-this.scroller.horizontalOffset)+"px",y=(l.y<0?c:-this.scroller.verticalOffset)+"px"),this.diagramLayer.style.left=v,this.diagramLayer.style.top=y,A.tx=-l.x/A.scale,A.ty=-l.y/A.scale);var P=!0;if(o&&(P=!1),this.updateTextElementValue(D),this.refreshing&&D.shape.activity&&D.shape.activity.subProcess&&D.shape.activity.subProcess.processes){for(var L=0;L0){var o=s.children[0],a=o.data;(r.isBezierEditing&&this.selectedItems.connectors[0].id===r.id||"Bezier"!==r.type)&&r.getSegmentElement(r,o,"ComplexHierarchicalTree"===this.layout.type||"HierarchicalTree"===this.layout.type?this.layout.orientation:void 0,void 0,!1),o.data!==a&&(s.measure(new me),s.arrange(s.desiredSize),"SVG"===this.mode&&!e&&this.updateDiagramObject(r))}}else this.constraints&nt.Bridging&&console.warn('[WARNING] :: Module "ConnectorBridging" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.setCursor=function(e){this.diagramRenderer.setCursor(this.diagramCanvas,e)},t.prototype.clearCanvas=function(e){var i=e.contentWidth||e.diagramLayer.width/this.scroller.currentZoom,r=e.contentHeight||e.diagramLayer.height/this.scroller.currentZoom;"SVG"!==e.mode&&bo.getContext(e.diagramLayer).clearRect(0,0,i,r)},t.prototype.updateScrollOffset=function(){this.scroller.setScrollOffset(this.diagramCanvas.scrollLeft,this.diagramCanvas.scrollTop),qI(this),Ds(this)&&this.scroller.virtualizeElements()},t.prototype.setOffset=function(e,i){var r="domTable";window[""+r][this.element.id+"content"]||(window[""+r][this.element.id+"content"]=document.getElementById(this.element.id+"content"));var s=window[""+r][this.element.id+"content"];s&&(s.scrollLeft=e,s.scrollTop=i)},t.prototype.setSize=function(e,i){if(this.diagramLayer&&!this.preventDiagramUpdate){var r=Za(this);e-=r.width,i-=r.height;var s=this.spatialSearch.getPageBounds();s.x*=this.scroller.currentZoom,s.y*=this.scroller.currentZoom,s.width*=this.scroller.currentZoom,s.height*=this.scroller.currentZoom;var o="SVG"===this.mode?1:1.5,a="SVG"===this.mode?pT(this.element.id):this.diagramLayer,h="Canvas"===this.mode&&this.constraints&nt.Virtualization?this.scroller.viewPortHeight:i;a.setAttribute("width",(o*("Canvas"===this.mode&&this.constraints&nt.Virtualization?this.scroller.viewPortWidth:e)).toString()),a.setAttribute("height",(o*h).toString());var c=document.getElementById(this.element.id+"_diagramUserHandleLayer");c&&(c.style.width=e+"px",c.style.height=i+"px");var d={width:e.toString(),height:i.toString()};this.diagramLayerDiv.style.width=e+"px",this.diagramLayerDiv.style.height=i+"px",ii(kF(this.element.id),d),ii(function voe(n){return xt(n).getElementsByClassName("e-ports-expand-layer")[0]}(this.element.id),d);var u=Bl(this.element.id);ii(u,d),u.parentNode.style.width=e+"px",u.parentNode.style.height=i+"px";var f=Fd(this.element.id);ii(f,d),this.diagramRenderer.updateGrid(this.snapSettings,f,this.scroller.transform,this.rulerSettings,this.hRuler,this.vRuler),ii(mT(this.element.id),d),this.htmlLayer.style.width=e+"px",this.htmlLayer.style.height=i+"px","SVG"!==this.mode&&!Ds(this)&&this.refreshDiagramLayer(),"SVG"===this.mode&&Ds(this)&&this.scroller.virtualizeElements()}},t.prototype.transformLayers=function(){var e=this.spatialSearch.getPageBounds();e.x*=this.scroller.currentZoom,e.y*=this.scroller.currentZoom,e.width*=this.scroller.currentZoom,e.height*=this.scroller.currentZoom,this.diagramRenderer.updateGrid(this.snapSettings,Fd(this.element.id),this.scroller.transform,this.rulerSettings,this.hRuler,this.vRuler),this.diagramRenderer.transformLayers(this.scroller.transform,"SVG"===this.mode),this.diagramActions&ee.DragUsingMouse||this.updateSelector(),this.renderPageBreaks(e)},t.prototype.removePageBreaks=function(){if(this.diagramLayer){var e=PF(this.element.id);if(e&&e.childNodes)for(var i=e.childNodes.length,r=0;rthis.pageSettings.height&&(e=this.pageSettings.height,this.pageSettings.height=this.pageSettings.width,this.pageSettings.width=e):this.pageSettings.height>this.pageSettings.width&&(e=this.pageSettings.width,this.pageSettings.width=this.pageSettings.height,this.pageSettings.height=e)},t.prototype.setOverview=function(e,i){if(e)e&&(this.views.push(e.id),this.views[e.id]=e,e.renderDocument(e),e.diagramRenderer.setLayers(),e.updateView(e),this.renderNodes(e));else{for(var r=0;r1&&this.updateSelectionRectangle(),this.isProtectedOnChange=s},t.prototype.updateSelectionRectangle=function(){for(var e=dm(this.element.id),i=!1,r=0;r1&&this.updateSelectionRectangle(),this.enableServerDataBinding(e)},t.prototype.renderSelectorForAnnotation=function(e,i){this.diagramRenderer.renderResizeHandle(e.wrapper.children[0],i,e.thumbsConstraints,this.scroller.currentZoom,e.constraints,this.scroller.transform,void 0,ro(e.annotation),void 0,void 0,e.handleSize)},t.prototype.drawSelectionRectangle=function(e,i,r,s){this.clearSelectorLayer(),this.diagramRenderer.drawSelectionRectangle(e,i,r,s,this.adornerLayer,this.scroller.transform)},t.prototype.renderHighlighter=function(e){var i=Bl(this.element.id);this.diagramRenderer.renderHighlighter(e,i,this.scroller.transform)},t.prototype.clearHighlighter=function(){var e=Bl(this.element.id),i=e.getElementById(e.id+"_highlighter");i&&i.parentNode.removeChild(i)},t.prototype.getNodesConnectors=function(e){for(var i=0;i0;h--)this.eventHandler&&this.eventHandler.touchArgs&&"touchmove"===this.eventHandler.touchArgs.type?(this.diagramRenderer.touchMove=!0,l&&l===o[h-1].id||(a=o[h-1]).parentNode.removeChild(a)):(a=o[h-1]).parentNode.removeChild(a);if(!ce()){var c=vT(this.element.id).childNodes;for(r=c.length;r>0;r--)c[r-1].parentNode.removeChild(c[r-1])}}},t.prototype.getWrapper=function(e,i){var r;i=e.id+"_"+i;for(var s=e instanceof Mi?e:this.getPortContainer(this.nameTable[e.id]),o=0;o0&&this.applyStyle(e,a=r.annotations)}for(i=0;i0){var a=this.selectedItems.connectors[parseInt(i.toString(),10)].annotations;this.applyStyle(e,a)}},t.prototype.applyStyle=function(e,i){for(var r=0;r0)for(var i=0;i0?r[0].zIndex+(e?1:-1):e?0:this.nodes.length+this.connectors.length-1)<0?i=this.nodes.length+this.connectors.length-1:i===this.nodes.length+this.connectors.length&&(i=0);for(var s=0;s0)for(var s=void 0,o=r.children.length-1;o>=0;o--){var a=r.children[parseInt(o.toString(),10)];i.length>0&&-1!==i.indexOf(a.id.split("_groupElement")[0])&&(r.parentNode.insertBefore(a,s||r),s=a)}r&&r.parentNode.removeChild(r)},t.prototype.deleteGroup=function(e){var r=[];e.children&&(r=this.commandHandler.getChildren(e,[])),this.UpdateBlazorDiagramModelCollection(e);for(var s=0,o=r;s0)for(var xe=0;xe0)if("Path"===t.shape.type&&void 0!==n.shape.data)t.wrapper.children[0].data=n.shape.data;else if("Text"===t.shape.type&&void 0!==n.shape.content)t.wrapper.children[0].content=n.shape.content;else if("Image"===t.shape.type&&void 0!==n.shape.source)t.wrapper.children[0].source=n.shape.source;else if("Native"===t.shape.type){for(var r=void 0,s=0;s-1)&&(this.diagramActions&ee.PreventZIndexOnDragging?this.updateDiagramObject(e,!0):this.updateDiagramObject(e)),!s&&d&&(this.lineRoutingModule&&this.diagramActions&&this.constraints&nt.LineRouting&&"helper"!==e.id?this.diagramActions&ee.ToolAction||this.lineRoutingModule.renderVirtualRegion(this,!0):this.diagramActions&&this.constraints&nt.LineRouting&&"helper"!==e.id&&console.warn('[WARNING] :: Module "LineRouting" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),this.updateConnectorEdges(e),"helper"!==e.id&&!(this.diagramActions&ee.ToolAction))))for(var Sa=this.spatialSearch.findObjects(e.wrapper.outerBounds),Mo=0;Moe?Math.abs(r-e):Math.abs(e-r),d=s>i?Math.abs(s-i):Math.abs(i-s);(0===c&&0===d||Number.isNaN(c)&&Number.isNaN(d))&&o.laneMargin&&(u=o.margin.left-o.laneMargin.left,f=o.margin.top-o.laneMargin.top);var p=o.width,g=o.height,v=new Ne(0,0,0,0);if(0!==p&&0!==g&&(v=new Ne((0!==r?r:o.offsetX)-p/2,(0!==s?s:o.offsetY)-g/2,p,g)),h){var y=l,b=this.selectedItems.nodes?this.selectedItems.nodes[0]:void 0;if(""!==y.textAnnotation.textAnnotationTarget&&this.nameTable[y.textAnnotation.textAnnotationTarget])if(""===o.parentId||b&&b.shape&&"TextAnnotation"===b.shape.shape){if("Auto"===y.textAnnotation.textAnnotationDirection&&a.children[0]instanceof Mi&&a.children[0].children[0]instanceof Ze){var w=a.children[0],C=document.getElementById(w.id+"_groupElement"),D=document.getElementById(w.children[0].id+"_groupElement");C.removeChild(D),w.children.splice(0,1),this.isProtectedOnChange=!0,this.bpmnModule.setAnnotationPath(v,w,o,y,y.textAnnotation.textAnnotationDirection,this),this.isProtectedOnChange=!1}}else this.isPositionUndo=!0,this.updateTextAnnotationInSwimlane(o,o),this.isPositionUndo=!1;else o.inEdges.length>0&&(x=this.nameTable[""+o.inEdges[0]])&&x.isBpmnAnnotationConnector&&(x.sourcePoint={x:r>e?x.sourcePoint.x+c:x.sourcePoint.x-c,y:s>i?x.sourcePoint.y+d:x.sourcePoint.y-d});this.nodePropertyChange(o,{},P={ports:[{offset:o.ports[0].offset}]})}else for(var L=0,O=o.outEdges;Le?T.offsetX+c:T.offsetX-c,T.offsetY=s>i?T.offsetY+d:T.offsetY-d,P={offsetX:T.offsetX,offsetY:T.offsetY}),this.nodePropertyChange(T,z,P)}}}},t.prototype.updatePorts=function(e,i){if(e&&e.ports.length>0)for(var r=0,s=Object.keys(e.ports);r0)for(var i=0;i0)for(var r=0;r0&&void 0===r.segments&&(e.segments=[]),void 0!==r.shape&&void 0!==e.shape&&e.shape&&"Bpmn"===e.shape.type&&this.bpmnModule&&this.bpmnModule.updateBPMNConnector(e,i,r,this),void 0!==e.constraints?(this.updateThumbConstraints(this.selectedItems.connectors,this.selectedItems),s=!0):s},t.prototype.connectorPropertyChange=function(e,i,r,s,o){if(this.canEnableBlazorObject){var a=$(e);this.insertValue(a,!1)}var d,u,f,p,l=e.wrapper.bounds,h=!1,c=[];if(h=this.connectorProprtyChangeExtend(e,i,r,h),void 0!==r.visible&&this.updateElementVisibility(e.wrapper,e,e.visible),void 0!==r.sourcePoint||void 0!==r.targetPoint||void 0!==r.sourceID||void 0!==r.targetID||void 0!==r.targetPadding||void 0!==r.sourcePortID||void 0!==r.targetPortID||void 0!==r.sourcePadding||void 0!==r.type||void 0!==r.segments||void 0!==r.flip){if(void 0!==r.sourceID&&r.sourceID!==i.sourceID||r.sourcePortID){if(u=this.findInOutConnectPorts(g=this.nameTable[e.sourceID],!1),(!g||Ph(g)||""!==e.sourcePortID&&Td(u))&&(e.sourceWrapper=g?this.getEndNodeWrapper(g,e,!0):void 0,e.sourcePortID&&void 0===r.sourcePortID&&(e.sourcePortWrapper=g?this.getWrapper(g.wrapper,e.sourcePortID):void 0),this.removePortEdges(this.nameTable[i.sourceID]||g,i.sourcePortID||e.sourcePortID,e.id,!1)),void 0!==r.sourceID&&void 0!==i.sourceID&&""!==i.sourceID){var v=this.nameTable[i.sourceID];void 0!==v&&v.outEdges&&-1!==v.outEdges.indexOf(e.id)&&im(v.outEdges,e.id)}this.updateEdges(e)}if(void 0!==r.targetID&&r.targetID!==i.targetID){if(d=this.findInOutConnectPorts(y=this.nameTable[r.targetID],!0),(!y||ua(y)||""!==e.targetPortID&&kh(d))&&(e.targetWrapper=y?this.getEndNodeWrapper(y,e,!1):void 0,e.targetPortID&&void 0===r.targetPortID&&(e.targetPortWrapper=y?this.getWrapper(y.wrapper,e.targetPortID):void 0),this.removePortEdges(this.nameTable[i.targetID]||y,i.targetPortID||e.targetPortID,e.id,!0)),void 0!==i&&void 0!==i.targetID&&""!==i.targetID){var S=this.nameTable[i.targetID];void 0!==S&&S.inEdges&&-1!==S.inEdges.indexOf(e.id)&&im(S.inEdges,e.id)}this.updateEdges(e)}var g,y;void 0!==r.sourcePortID&&r.sourcePortID!==i.sourcePortID&&(e.sourceID&&this.nameTable[e.sourceID]&&(f=this.nameTable[e.sourceID].wrapper),!(g=this.nameTable[e.sourceID])||Ph(g)||""!==e.sourcePortID&&Td(u)?e.sourcePortWrapper=f?this.getWrapper(f,r.sourcePortID):void 0:""===e.sourcePortID&&!Ph(g)&&(e.sourcePortWrapper=void 0)),void 0!==r.targetPortID&&r.targetPortID!==i.targetPortID&&(e.targetID&&this.nameTable[e.targetID]&&(p=this.nameTable[e.targetID].wrapper),!(y=this.nameTable[e.targetID])||ua(y)||""!==e.targetPortID&&kh(d)?e.targetPortWrapper=p?this.getWrapper(p,r.targetPortID):void 0:""===e.targetPortID&&!ua(y)&&(e.targetPortWrapper=void 0)),void 0!==r.flip&&(e.flip=r.flip,SF(e)),"Orthogonal"===e.type&&this.lineRoutingModule&&this.diagramActions&&this.constraints&nt.LineRouting&&!(this.diagramActions&ee.ToolAction)&&"ComplexHierarchicalTree"!==this.layout.type&&(this.lineRoutingModule.renderVirtualRegion(this,!0),e.sourceID!==e.targetID&&e.segments.length>1&&this.lineRoutingModule.refreshConnectorSegments(this,e,!1)),c=this.getPoints(e)}void 0!==r.style&&zh(r.style,e.wrapper.children[0]),(c.length>0||void 0!==r.sourceDecorator||void 0!==r.targetDecorator&&function Bse(n){return-1!==n.indexOf("shape")||-1!==n.indexOf("pathData")||-1!==n.indexOf("width")||-1!==n.indexOf("height")}(Object.keys(r.targetDecorator))||void 0!==r.cornerRadius)&&(Jf(e,c.length>0?c:e.intermediatePoints,this.diagramActions),void 0!==r.type&&(h=!0),c.length>0&&(e.wrapper.measure(new me(e.wrapper.width,e.wrapper.height)),e.wrapper.arrange(e.wrapper.desiredSize),this.updateConnectorAnnotation(e),this.updateConnectorPort(e),this.updateConnectorfixedUserHandles(e),this.updateObject(e,i,r))),(r.sourcePoint||r.targetPoint||r.segments)&&this.diagramActions===ee.Render&&(h=!0),"Bpmn"===e.shape.type&&"Default"===e.shape.sequence&&"Sequence"===e.shape.flow&&this.commandHandler.updatePathElementOffset(e),s||this.updateBridging(),this.updateAnnotations(r,e),this.updateConnectorPorts(r,e),this.updatefixedUserHandle(r,e),e.wrapper.measure(new me(e.wrapper.width,e.wrapper.height)),e.wrapper.arrange(e.wrapper.desiredSize),!1===l.equals(l,e.wrapper.bounds)&&(this.updateQuad(e),"Drag"!==this.eventHandler.currentAction&&this.updateGroupSize(e)),!0===h&&this.checkSelectedItem(e)&&(!(this.diagramActions&ee.ToolAction)||this.diagramActions&ee.UndoRedo)&&this.updateSelector(),this.preventConnectorsUpdate||(!Ds(this)||Ds(this)&&this.scroller.oldCollectionObjects.indexOf(e.id)>-1)&&(this.diagramActions&ee.PreventZIndexOnDragging?this.updateDiagramObject(e,!0):this.updateDiagramObject(e)),this.updateConnectorEdges(e),this.diagramActions&&"New"!==e.status&&(e.status="Update"),this.triggerPropertyChange(o,e,i,r)},t.prototype.removePortEdges=function(e,i,r,s){if(e)for(var o=0;o0&&e.id===s[s.length-1].id&&(r=!0),r},t.prototype.updateDiagramContainerVisibility=function(e,i){if(e instanceof Cs)for(var r=0;r>"),r instanceof es&&this.updateAnnotationWrapper(r,s,o,a)),void 0!==e.template&&(r.content=e.template,this.updateAnnotationWrapper(r,s,o,a))},t.prototype.updateAnnotationWrapper=function(e,i,r,s){for(var o=0,a=this.views;o=0&&this.nodes.splice(s,1),delete this.nameTable[""+r]}var o=this.nodes.indexOf(this.nameTable[this.currentSymbol.id]);o>=0&&this.nodes.splice(o,1)}},t.prototype.selectDragedNode=function(e,i,r){this.currentSymbol=e,"SVG"!==this.mode&&this.refreshDiagramLayer(),this.commandHandler.oldSelectedObjects=nm(this),this.commandHandler.select(e),this.eventHandler.mouseDown(i.event),this.eventHandler.mouseMove(i.event,i),this.preventDiagramUpdate=!1,this.updatePage(),r.style.opacity="0"},t.prototype.initDroppables=function(){var s,o,e=this,i={},r={},a="selectedSymbols";this.droppable=new lR(this.element);var l=5;this.droppable.over=function(h){if(e.rulerSettings.showRulers){var c=document.getElementById(e.element.id+"_vRuler"),d=parseFloat(c.style.width);l=d+1}if(0===e.previousSelectedObjects.length&&!e.currentSymbol&&(e.previousSelectedObjects=e.commandHandler.getSelectedObject()),e.commandHandler.PreventConnectorSplit=!0,e.currentSymbol)h.event.touches&&h.event.touches.length&&e.eventHandler.mouseMove(h.event,h.event.touches);else{var u=null;if(!h.dragData&&"drag"===h.name){var f=document.getElementsByClassName("e-dragclone")[0];f&&(u=f)}if(h.dragData||u){var p=void 0,g=void 0;document.getElementById(e.element.id+"content").focus();var v=e.eventHandler.getMousePosition(h.event),y=void 0,S=u||h.dragData.helper,b=S.getAttribute("paletteId"),M=void 0,w=void 0,C=void 0,D=void 0;if(!b&&h.dragData){e.triggerEvent(Ce.dragEnter,A={source:null,element:p,cancel:!1,diagram:e,dragData:h.dragData.draggedElement.ej2_instances[0].dragData,dragItem:p});var x=void 0,P=void 0;if(A.dragItem){if(A.dragItem.sourcePoint&&A.dragItem.targetPoint?P=new de(e,"connectors",A.dragItem,!0):x=new te(e,"nodes",A.dragItem,!0),e.initObject(p=x||P,void 0,void 0,!0),e.enterObject=p,e.enterTable=r,p instanceof te)x.offsetX=v.x+5+x.width*x.pivot.x,x.offsetY=v.y+x.height*x.pivot.y;else if(p instanceof de){var L=Ne.toBounds([p.sourcePoint,p.targetPoint]),O=v.x-L.left,N=v.y-L.top;p.sourcePoint.x+=O,p.sourcePoint.y+=N,p.targetPoint.x+=O,p.targetPoint.y+=N}e.preventDiagramUpdate=!0,e.currentSymbol=p,"SVG"!==e.mode&&e.refreshDiagramLayer(),e.selectDragedNode(p,h,S),delete e.enterObject,delete e.enterTable,e.droppable[""+a]=S,e.allowServerDataBinding=!0}}if(b){var T=document.getElementById(b).ej2_instances[0];if(e.droppable.sourceElement=T,T){var B=T[""+a];e.allowServerDataBinding=!1,y=$(T[""+a]),i=T.childTable;var j=B.wrapper.children[0].children[0];if(D=function Fse(n,t,e){var i=wF(n,t,e,"width"),r=wF(n,t,e,"height");return new me(i,r)}(T,y,j),T[""+a]instanceof te){"TextAnnotation"===B.shape.shape?(y.offsetX=v.x+11+D.width*y.pivot.x,y.offsetY=v.y+11+D.height*y.pivot.y):(y.offsetX=v.x+5+D.width*y.pivot.x,y.offsetY=v.y+D.height*y.pivot.y),"Bpmn"===(x=new te(e,"nodes",y,!0)).shape.type&&x.shape.activity.subProcess.processes&&x.shape.activity.subProcess.processes.length&&(x.shape.activity.subProcess.processes=[]),w=x.previewSize,C=T.symbolDragSize;var Q=T.symbolPreview;if(x.width=(M=x.dragSize).width||C.width||w.width||Q.width||x.width,x.height=M.height||C.height||w.height||Q.height||x.height,"SwimLane"===x.shape.type){if(e.diagramActions|=ee.PreventHistory,x.shape.isLane){x.children=[],s={id:"header"+Qe()},"Horizontal"===x.shape.orientation?(s.width=x.shape.lanes[0].header.width,s.height=x.shape.lanes[0].height):(s.width=x.shape.lanes[0].width,s.height=x.shape.lanes[0].header.height),s.style=x.shape.lanes[0].header.style,s.offsetX=v.x+l+s.width/2,s.offsetY=v.y+s.height/2,e.diagramActions|=ee.PreventCollectionChangeOnDragOver,s=e.add(s),o={id:"body"+Qe()},"Horizontal"===x.shape.orientation?(o.width=x.shape.lanes[0].width-s.width,o.height=x.shape.lanes[0].height,o.offsetX=v.x+l+(x.shape.lanes[0].header.width+o.width/2),o.offsetY=v.y+o.height/2):(o.width=x.shape.lanes[0].width,o.height=x.shape.lanes[0].height-s.height,o.offsetX=v.x+l+o.width/2,o.offsetY=v.y+(x.shape.lanes[0].header.height+o.height/2)),o.style=x.shape.lanes[0].style,o=e.add(o);var oe={id:"group"+Qe(),children:[s.id,o.id]};oe.shape=x.shape,oe.width=x.shape.lanes[0].width,oe.height=x.shape.lanes[0].height,oe.previewSize=x.previewSize,oe.dragSize=x.dragSize,oe.addInfo=x.addInfo,x=e.add(oe),e.diagramActions&=~ee.PreventCollectionChangeOnDragOver}e.diagramActions&=~ee.PreventHistory}if(x.shape.isPhase&&((g="Horizontal"===x.shape.orientation)?(x.offsetX=v.x+l+(x.width||j.actualSize.width)/2,x.offsetY=v.y,x.shape.data="M20,"+x.height/2+" L"+(x.width-20)+","+x.height/2+"z",x.height=1):(x.offsetX=v.x+5,x.offsetY=v.y+(x.height||j.actualSize.height)/2,x.shape.data="M"+x.width/2+",20 L"+x.width/2+","+(x.height-20)+"z",x.width=1)),"UmlClassifier"===x.shape.type&&(x.children=x.width=x.height=void 0,y.children=void 0,"Class"===x.shape.classifier&&x.shape.classShape.methods.length<=0&&x.shape.classShape.attributes.length<=0&&(x.shape.classShape.attributes=[{name:"Name",type:"Type",style:{}}]),"Enumeration"===x.shape.classifier&&x.shape.enumerationShape.members.length<=0&&(x.shape.enumerationShape.members=[{name:"Name"}]),"Interface"===x.shape.classifier&&x.shape.interfaceShape.methods.length<=0&&x.shape.interfaceShape.attributes.length<=0&&(x.shape.interfaceShape.attributes=[{name:"Name",type:"Type",style:{}}])),p=x,y.children){var ue=y;r=e.getChildren(ue,{},i),eT(ue,-ue.offsetX,-ue.offsetY,r,!0,e)}}else if(T[""+a]instanceof de){p=new de(e,"connectors",y,!0);var Me=Ne.toBounds([p.sourcePoint,p.targetPoint]),De=v.x-Me.left,xe=v.y-Me.top;p.sourcePoint.x+=De,p.sourcePoint.y+=xe,p.targetPoint.x+=De,p.targetPoint.y+=xe}p.shape.isLane||(p.id+=Qe());var A={source:T,element:p,cancel:!1,diagram:e,dragData:null,dragItem:p};if(e.enterObject=p,e.enterTable=r,e.triggerEvent(Ce.dragEnter,A),p instanceof te&&"SwimLane"===p.shape.type&&p.shape.isLane){var Ie=A.element,Ve=Ie.shape.lanes[0];g="Horizontal"===Ie.shape.orientation;var ot=e.nameTable[p.children[0]],$e=e.nameTable[p.children[1]];w=p.previewSize,C=T.symbolDragSize,Ve.width=(M=p.dragSize).width||C.width||w.width||Ve.width,Ve.height=M.height||C.height||w.height||Ve.height,g?(s.width=Ve.header.width,s.height=Ve.height,o.width=Ve.width-s.width,o.height=Ve.height,o.offsetX=v.x+l+(Ve.header.width+$e.width/2),o.offsetY=v.y+$e.height/2):(s.width=Ve.width,s.height=Ve.header.height,o.width=Ve.width,o.height=Ve.height-s.height,o.offsetX=v.x+l+$e.width/2,o.offsetY=v.y+(Ve.header.height+$e.height/2)),s.offsetX=v.x+l+ot.width/2,s.offsetY=v.y+ot.height/2,p.width=Ve.width,p.height=Ve.height}if(p instanceof te&&p.shape.isPhase&&(g?p.height=1:p.width=1),!e.activeLayer.lock&&!A.cancel){if(e.preventDiagramUpdate=!0,p.children&&e.findChild(p,r),e.preventDiagramUpdate=!0,p.zIndex!==Number.MIN_VALUE&&(p.zIndex=Number.MIN_VALUE),e.initObject(p,void 0,void 0,!0),e.bpmnModule)for(var Ci=0;Ci0&&(S.segments=[]),d=this.add(S,!0)),(S||d)&&(_v(this)||Uv(this))&&this.select([this.nameTable[S[""+b]]],!1,this.previousSelectedObjects),y.target&&y.target instanceof de&&!0===this.enableConnectorSplit&&this.nameTable[S[""+b]]instanceof te&&(this.commandHandler.connectorSplit(this.nameTable[S[""+b]],y.target),this.commandHandler.PreventConnectorSplit=!1))),this.protectPropertyChange(!1),v=this.nameTable[S[""+b]],S.hasTarget&&(S.nodeId=S.hasTarget,this.remove(S)),this.bpmnModule&&v instanceof te&&S.processId&&(v.processId=S.processId,this.bpmnModule.dropBPMNchild(this.nameTable[v.processId],v,this)),y.cancel||this.endGroupAction(),"SVG"!==this.mode&&this.refreshDiagramLayer(),delete this.droppable[""+c]):(this.triggerEvent(Ce.drop,y={source:h.droppedElement,element:void 0,target:this.eventHandler.hoverNode||this.eventHandler.lastObjectUnderMouse||this,cancel:!1,position:void 0}),S=void 0,b="id"),this.droppable[M="selectedSymbols"]&&this.droppable[""+M].parentNode)gt(this.droppable[""+M]);else for(w=document.getElementsByClassName("e-dragclone"),C=0;C0)for(var f=0;f1),e.previousSelectedObject=null}}},t.prototype.getDropEventArgs=function(e){if(this.eventHandler.lastObjectUnderMouse||this.eventHandler.hoverNode){var i=this.eventHandler.lastObjectUnderMouse||this.eventHandler.hoverNode;e.target=ps(i)===de?{connector:i}:{node:i}}else e.target.diagramId=this.element.id},t.prototype.removeChildInNodes=function(e){if(e){if(e.children)for(var i=0;i1){var l=2;if(e.children&&e.children.length>0)for(;e.children.indexOf(i.objects[s-l])>-1;)l++;this.commandHandler.moveSvgNode(e.id,i.objects[s-l]),this.commandHandler.moveSvgNode(i.objects[s-l],e.id)}else if(o){var h=this.commandHandler.getLayer(this.layerZIndexTable[o.zIndex]).objects[0];h?(this.commandHandler.moveSvgNode(e.id,h),this.commandHandler.updateNativeNodeIndex(e.id,h)):this.moveObjectsUp(e,i)}else this.moveObjectsUp(e,i)},t.prototype.moveObjectsUp=function(e,i){for(var r,s=this.layers.length-1;s>=0;s--)if(r=this.layers[parseInt(s.toString(),10)],i.id!==r.id){var o=this.commandHandler.getLayer(this.layerZIndexTable[r.zIndex]).objects[r.objects.length-1];if(o){this.commandHandler.moveSvgNode(e.id,o),this.commandHandler.moveSvgNode(o,e.id);break}}},t.prototype.insertData=function(e){return this.crudOperation(e,"create",this.getNewUpdateNodes("New"))},t.prototype.updateData=function(e){return this.crudOperation(e,"update",this.getNewUpdateNodes("Update"))},t.prototype.removeData=function(e){return this.crudOperation(e,"destroy",this.getDeletedNodes())},t.prototype.crudOperation=function(e,i,r){if(e){var s=this.parameterMap(e,!(e instanceof de));if(s){var o=e instanceof de?this.dataSourceSettings.connectionDataSource.crudAction[""+i]:this.dataSourceSettings.crudAction[""+i];this.raiseAjaxPost(JSON.stringify(s),o)}return s}var a=r;return this.processCrudCollection(a,this.dataSourceSettings.crudAction[""+i],this.dataSourceSettings.connectionDataSource.crudAction[""+i]),a},t.prototype.processCrudCollection=function(e,i,r){if(e.nodes){var s=[],o=void 0;for(o=0;o0&&this.raiseAjaxPost(JSON.stringify(s),i)}if(e.connectors){for(s=[],o=void 0,o=0;o0&&this.raiseAjaxPost(JSON.stringify(s),r)}},t.prototype.parameterMap=function(e,i){var s,r={},o=i?this.dataSourceSettings:this.dataSourceSettings.connectionDataSource;if(o.id&&(r[o.id]=e.id),o.sourcePointX&&o.sourcePointY&&(r[o.sourcePointX]=e.sourcePoint.x,r[o.sourcePointY]=e.sourcePoint.y),o.targetPointX&&o.targetPointY&&(r[o.targetPointX]=e.targetPoint.x,r[o.targetPointY]=e.targetPoint.y),o.sourceID&&(r[o.sourceID]=e.sourceID),o.targetID&&(r[o.targetID]=e.targetID),o.crudAction&&o.crudAction.customFields&&o.crudAction.customFields.length>0)for(s=0;s"u"||(y.innerHTML=v.innerHTML?v.innerHTML:"",void 0!==v.className&&(y.className=v.className),void 0!==v.id&&(y.id=v.id),void 0!==v.styles&&y.setAttribute("style",v.styles),void 0!==e.ngAttr&&y.setAttribute(e.ngAttr,""),void 0!==v.attrs&&Fe(y,v.attrs)),y};for(var i=0,r=e.tags;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s}!function DZ(n){EC.compile=n.compile}({compile:function Fae(n,t){if("string"==typeof n||"function"==typeof n&&n.prototype&&n.prototype.CSPTemplate)return Bae(n,t);var e=n.elementRef.nativeElement._viewContainerRef,i=n.elementRef.nativeElement.propName;return function(r,s,o){var l=e||s.viewContainerRef,h=l.createEmbeddedView(n,{$implicit:r});/EJS-MENTION|EJS-DROPDOWNLIST/.test(Y("currentInstance.element.nodeName",l))||/E-TABITEM/.test(Y("element.nativeElement.nodeName",l))?h.detectChanges():h.markForCheck();var c=s&&s.registeredTemplate?s.registeredTemplate:Y("currentInstance.registeredTemplate",l);return typeof c["".concat(o=o&&s.registeredTemplate?o:i)]>"u"&&(c["".concat(o)]=[]),c["".concat(o)].push(h),h.rootNodes}}});const Wae=["annotationTemplate"],Yae=["nodeTemplate"],Qae=["userHandleTemplate"];let Gae=["addInfo","id","lock","objects","visible","zIndex"],Xae=[],qae=(()=>{class n extends Bh{constructor(e){super(),this.viewContainerRef=e,_l("currentInstance",this,this.viewContainerRef),this.registerEvents(Xae),this.directivePropList=Gae}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-layer"]],inputs:{addInfo:"addInfo",id:"id",lock:"lock",objects:"objects",visible:"visible",zIndex:"zIndex"},features:[yn]}),n})(),$ae=(()=>{class n extends Fh{constructor(){super("layers")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-layers"]],contentQueries:function(e,i,r){if(1&e&&dn(r,qae,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),Zae=["action","cursor"],Jae=[],Kae=(()=>{class n extends Bh{constructor(e){super(),this.viewContainerRef=e,_l("currentInstance",this,this.viewContainerRef),this.registerEvents(Jae),this.directivePropList=Zae}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-cursormap"]],inputs:{action:"action",cursor:"cursor"},features:[yn]}),n})(),ele=(()=>{class n extends Fh{constructor(){super("customcursor")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-cursormaps"]],contentQueries:function(e,i,r){if(1&e&&dn(r,Kae,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),tle=["alignment","cornerRadius","displacement","fill","handleStrokeColor","handleStrokeWidth","height","iconStrokeColor","iconStrokeWidth","id","offset","padding","pathData","tooltip","visibility","width"],ile=[],rle=(()=>{class n extends Bh{constructor(e){super(),this.viewContainerRef=e,_l("currentInstance",this,this.viewContainerRef),this.registerEvents(ile),this.directivePropList=tle}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-connector-fixeduserhandle"]],inputs:{alignment:"alignment",cornerRadius:"cornerRadius",displacement:"displacement",fill:"fill",handleStrokeColor:"handleStrokeColor",handleStrokeWidth:"handleStrokeWidth",height:"height",iconStrokeColor:"iconStrokeColor",iconStrokeWidth:"iconStrokeWidth",id:"id",offset:"offset",padding:"padding",pathData:"pathData",tooltip:"tooltip",visibility:"visibility",width:"width"},features:[yn]}),n})(),nle=(()=>{class n extends Fh{constructor(){super("fixeduserhandles")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-connector-fixeduserhandles"]],contentQueries:function(e,i,r){if(1&e&&dn(r,rle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),sle=["addInfo","alignment","annotationType","constraints","content","displacement","dragLimit","height","horizontalAlignment","hyperlink","id","margin","offset","rotateAngle","rotationReference","segmentAngle","style","template","tooltip","type","verticalAlignment","visibility","width"],ole=[],ale=(()=>{class n extends Bh{constructor(e){super(),this.viewContainerRef=e,_l("currentInstance",this,this.viewContainerRef),this.registerEvents(ole),this.directivePropList=sle}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-connector-annotation"]],inputs:{addInfo:"addInfo",alignment:"alignment",annotationType:"annotationType",constraints:"constraints",content:"content",displacement:"displacement",dragLimit:"dragLimit",height:"height",horizontalAlignment:"horizontalAlignment",hyperlink:"hyperlink",id:"id",margin:"margin",offset:"offset",rotateAngle:"rotateAngle",rotationReference:"rotationReference",segmentAngle:"segmentAngle",style:"style",template:"template",tooltip:"tooltip",type:"type",verticalAlignment:"verticalAlignment",visibility:"visibility",width:"width"},features:[yn]}),n})(),lle=(()=>{class n extends Fh{constructor(){super("annotations")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-connector-annotations"]],contentQueries:function(e,i,r){if(1&e&&dn(r,ale,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),hle=["addInfo","allowNodeOverlap","annotations","bezierSettings","bridgeSpace","connectionPadding","connectorSpacing","constraints","cornerRadius","dragSize","excludeFromLayout","fixedUserHandles","flip","flipMode","hitPadding","id","margin","maxSegmentThumb","ports","previewSize","segmentThumbShape","segmentThumbSize","segments","shape","sourceDecorator","sourceID","sourcePadding","sourcePoint","sourcePortID","style","symbolInfo","targetDecorator","targetID","targetPadding","targetPoint","targetPortID","tooltip","type","visible","wrapper","zIndex"],cle=[],dle=(()=>{class n extends Bh{constructor(e){super(),this.viewContainerRef=e,this.tags=["fixedUserHandles","annotations"],_l("currentInstance",this,this.viewContainerRef),this.registerEvents(cle),this.directivePropList=hle}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-connector"]],contentQueries:function(e,i,r){if(1&e&&(dn(r,nle,5),dn(r,lle,5)),2&e){let s;Kr(s=en())&&(i.childFixedUserHandles=s.first),Kr(s=en())&&(i.childAnnotations=s.first)}},inputs:{addInfo:"addInfo",allowNodeOverlap:"allowNodeOverlap",annotations:"annotations",bezierSettings:"bezierSettings",bridgeSpace:"bridgeSpace",connectionPadding:"connectionPadding",connectorSpacing:"connectorSpacing",constraints:"constraints",cornerRadius:"cornerRadius",dragSize:"dragSize",excludeFromLayout:"excludeFromLayout",fixedUserHandles:"fixedUserHandles",flip:"flip",flipMode:"flipMode",hitPadding:"hitPadding",id:"id",margin:"margin",maxSegmentThumb:"maxSegmentThumb",ports:"ports",previewSize:"previewSize",segmentThumbShape:"segmentThumbShape",segmentThumbSize:"segmentThumbSize",segments:"segments",shape:"shape",sourceDecorator:"sourceDecorator",sourceID:"sourceID",sourcePadding:"sourcePadding",sourcePoint:"sourcePoint",sourcePortID:"sourcePortID",style:"style",symbolInfo:"symbolInfo",targetDecorator:"targetDecorator",targetID:"targetID",targetPadding:"targetPadding",targetPoint:"targetPoint",targetPortID:"targetPortID",tooltip:"tooltip",type:"type",visible:"visible",wrapper:"wrapper",zIndex:"zIndex"},features:[yn]}),n})(),ule=(()=>{class n extends Fh{constructor(){super("connectors")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-connectors"]],contentQueries:function(e,i,r){if(1&e&&dn(r,dle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),fle=["cornerRadius","fill","handleStrokeColor","handleStrokeWidth","height","iconStrokeColor","iconStrokeWidth","id","margin","offset","padding","pathData","tooltip","visibility","width"],ple=[],gle=(()=>{class n extends Bh{constructor(e){super(),this.viewContainerRef=e,_l("currentInstance",this,this.viewContainerRef),this.registerEvents(ple),this.directivePropList=fle}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-node-fixeduserhandle"]],inputs:{cornerRadius:"cornerRadius",fill:"fill",handleStrokeColor:"handleStrokeColor",handleStrokeWidth:"handleStrokeWidth",height:"height",iconStrokeColor:"iconStrokeColor",iconStrokeWidth:"iconStrokeWidth",id:"id",margin:"margin",offset:"offset",padding:"padding",pathData:"pathData",tooltip:"tooltip",visibility:"visibility",width:"width"},features:[yn]}),n})(),vle=(()=>{class n extends Fh{constructor(){super("fixeduserhandles")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-node-fixeduserhandles"]],contentQueries:function(e,i,r){if(1&e&&dn(r,gle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),mle=["addInfo","annotationType","constraints","content","dragLimit","height","horizontalAlignment","hyperlink","id","margin","offset","rotateAngle","rotationReference","style","template","tooltip","type","verticalAlignment","visibility","width"],yle=[],Sle=(()=>{class n extends Bh{constructor(e){super(),this.viewContainerRef=e,_l("currentInstance",this,this.viewContainerRef),this.registerEvents(yle),this.directivePropList=mle}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-node-annotation"]],inputs:{addInfo:"addInfo",annotationType:"annotationType",constraints:"constraints",content:"content",dragLimit:"dragLimit",height:"height",horizontalAlignment:"horizontalAlignment",hyperlink:"hyperlink",id:"id",margin:"margin",offset:"offset",rotateAngle:"rotateAngle",rotationReference:"rotationReference",style:"style",template:"template",tooltip:"tooltip",type:"type",verticalAlignment:"verticalAlignment",visibility:"visibility",width:"width"},features:[yn]}),n})(),Ile=(()=>{class n extends Fh{constructor(){super("annotations")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-node-annotations"]],contentQueries:function(e,i,r){if(1&e&&dn(r,Sle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),ble=["addInfo","connectionDirection","constraints","height","horizontalAlignment","id","inEdges","margin","offset","outEdges","pathData","shape","style","tooltip","verticalAlignment","visibility","width"],Mle=[],wle=(()=>{class n extends Bh{constructor(e){super(),this.viewContainerRef=e,_l("currentInstance",this,this.viewContainerRef),this.registerEvents(Mle),this.directivePropList=ble}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-node-port"]],inputs:{addInfo:"addInfo",connectionDirection:"connectionDirection",constraints:"constraints",height:"height",horizontalAlignment:"horizontalAlignment",id:"id",inEdges:"inEdges",margin:"margin",offset:"offset",outEdges:"outEdges",pathData:"pathData",shape:"shape",style:"style",tooltip:"tooltip",verticalAlignment:"verticalAlignment",visibility:"visibility",width:"width"},features:[yn]}),n})(),Cle=(()=>{class n extends Fh{constructor(){super("ports")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-node-ports"]],contentQueries:function(e,i,r){if(1&e&&dn(r,wle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),Ele=["addInfo","annotations","backgroundColor","borderColor","borderWidth","branch","children","collapseIcon","columnIndex","columnSpan","columns","constraints","container","data","dragSize","excludeFromLayout","expandIcon","fixedUserHandles","flip","flipMode","height","horizontalAlignment","id","isExpanded","layoutInfo","margin","maxHeight","maxWidth","minHeight","minWidth","offsetX","offsetY","padding","pivot","ports","previewSize","rotateAngle","rowIndex","rowSpan","rows","shadow","shape","style","symbolInfo","tooltip","verticalAlignment","visible","width","wrapper","zIndex"],Dle=[],v_=(()=>{class n extends Bh{constructor(e){super(),this.viewContainerRef=e,this.tags=["fixedUserHandles","annotations","ports"],_l("currentInstance",this,this.viewContainerRef),this.registerEvents(Dle),this.directivePropList=Ele}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-node"]],contentQueries:function(e,i,r){if(1&e&&(dn(r,vle,5),dn(r,Ile,5),dn(r,Cle,5)),2&e){let s;Kr(s=en())&&(i.childFixedUserHandles=s.first),Kr(s=en())&&(i.childAnnotations=s.first),Kr(s=en())&&(i.childPorts=s.first)}},inputs:{addInfo:"addInfo",annotations:"annotations",backgroundColor:"backgroundColor",borderColor:"borderColor",borderWidth:"borderWidth",branch:"branch",children:"children",collapseIcon:"collapseIcon",columnIndex:"columnIndex",columnSpan:"columnSpan",columns:"columns",constraints:"constraints",container:"container",data:"data",dragSize:"dragSize",excludeFromLayout:"excludeFromLayout",expandIcon:"expandIcon",fixedUserHandles:"fixedUserHandles",flip:"flip",flipMode:"flipMode",height:"height",horizontalAlignment:"horizontalAlignment",id:"id",isExpanded:"isExpanded",layoutInfo:"layoutInfo",margin:"margin",maxHeight:"maxHeight",maxWidth:"maxWidth",minHeight:"minHeight",minWidth:"minWidth",offsetX:"offsetX",offsetY:"offsetY",padding:"padding",pivot:"pivot",ports:"ports",previewSize:"previewSize",rotateAngle:"rotateAngle",rowIndex:"rowIndex",rowSpan:"rowSpan",rows:"rows",shadow:"shadow",shape:"shape",style:"style",symbolInfo:"symbolInfo",tooltip:"tooltip",verticalAlignment:"verticalAlignment",visible:"visible",width:"width",wrapper:"wrapper",zIndex:"zIndex"},features:[yn]}),n})(),m_=(()=>{class n extends Fh{constructor(){super("nodes")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-nodes"]],contentQueries:function(e,i,r){if(1&e&&dn(r,v_,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})();const xle=["animationComplete","click","collectionChange","commandExecute","connectionChange","contextMenuBeforeItemRender","contextMenuClick","contextMenuOpen","created","dataLoaded","doubleClick","dragEnter","dragLeave","dragOver","drop","elementDraw","expandStateChange","fixedUserHandleClick","historyChange","historyStateChange","keyDown","keyUp","load","loaded","mouseEnter","mouseLeave","mouseOver","mouseWheel","onFixedUserHandleMouseDown","onFixedUserHandleMouseEnter","onFixedUserHandleMouseLeave","onFixedUserHandleMouseUp","onImageLoad","onUserHandleMouseDown","onUserHandleMouseEnter","onUserHandleMouseLeave","onUserHandleMouseUp","positionChange","propertyChange","rotateChange","scrollChange","segmentChange","segmentCollectionChange","selectionChange","sizeChange","sourcePointChange","targetPointChange","textEdit"],Tle=[""];let Ale=(()=>{let n=class extends Fl{constructor(e,i,r,s){super(),this.ngEle=e,this.srenderer=i,this.viewContainerRef=r,this.injector=s,this.tags=["layers","customCursor","connectors","nodes"],this.element=this.ngEle.nativeElement,this.injectedModules=this.injectedModules||[];try{let o=this.injector.get("DiagramsHierarchicalTree");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsMindMap");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsRadialTree");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsComplexHierarchicalTree");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsDataBinding");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsSnapping");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsPrintAndExport");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsBpmnDiagrams");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsSymmetricLayout");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsConnectorBridging");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsUndoRedo");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsLayoutAnimation");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsDiagramContextMenu");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsLineRouting");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsConnectorEditing");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsLineDistribution");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsEj1Serialization");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsFlowchartLayout");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}this.registerEvents(xle),this.addTwoWay.call(this,Tle),_l("currentInstance",this,this.viewContainerRef),this.context=new u_}ngOnInit(){this.context.ngOnInit(this)}ngAfterViewInit(){this.context.ngAfterViewInit(this)}ngOnDestroy(){this.context.ngOnDestroy(this)}ngAfterContentChecked(){this.tagObjects[0].instance=this.childLayers,this.childCustomCursor&&(this.tagObjects[1].instance=this.childCustomCursor),this.childConnectors&&(this.tagObjects[2].instance=this.childConnectors),this.childNodes&&(this.tagObjects[3].instance=this.childNodes),this.context.ngAfterContentChecked(this)}};return n.\u0275fac=function(e){return new(e||n)(Ot($c),Ot(aM),Ot(An),Ot(Wo))},n.\u0275cmp=Hb({type:n,selectors:[["ejs-diagram"]],contentQueries:function(e,i,r){if(1&e&&(dn(r,Wae,5),dn(r,Yae,5),dn(r,Qae,5),dn(r,$ae,5),dn(r,ele,5),dn(r,ule,5),dn(r,m_,5)),2&e){let s;Kr(s=en())&&(i.annotationTemplate=s.first),Kr(s=en())&&(i.nodeTemplate=s.first),Kr(s=en())&&(i.userHandleTemplate=s.first),Kr(s=en())&&(i.childLayers=s.first),Kr(s=en())&&(i.childCustomCursor=s.first),Kr(s=en())&&(i.childConnectors=s.first),Kr(s=en())&&(i.childNodes=s.first)}},inputs:{addInfo:"addInfo",annotationTemplate:"annotationTemplate",backgroundColor:"backgroundColor",bridgeDirection:"bridgeDirection",commandManager:"commandManager",connectorDefaults:"connectorDefaults",connectors:"connectors",constraints:"constraints",contextMenuSettings:"contextMenuSettings",customCursor:"customCursor",dataSourceSettings:"dataSourceSettings",diagramSettings:"diagramSettings",drawingObject:"drawingObject",enableConnectorSplit:"enableConnectorSplit",enablePersistence:"enablePersistence",enableRtl:"enableRtl",fixedUserHandleTemplate:"fixedUserHandleTemplate",getConnectorDefaults:"getConnectorDefaults",getCustomCursor:"getCustomCursor",getCustomProperty:"getCustomProperty",getCustomTool:"getCustomTool",getDescription:"getDescription",getNodeDefaults:"getNodeDefaults",height:"height",historyManager:"historyManager",layers:"layers",layout:"layout",locale:"locale",mode:"mode",nodeDefaults:"nodeDefaults",nodeTemplate:"nodeTemplate",nodes:"nodes",pageSettings:"pageSettings",rulerSettings:"rulerSettings",scrollSettings:"scrollSettings",segmentThumbShape:"segmentThumbShape",segmentThumbSize:"segmentThumbSize",selectedItems:"selectedItems",serializationSettings:"serializationSettings",setNodeTemplate:"setNodeTemplate",snapSettings:"snapSettings",tool:"tool",tooltip:"tooltip",updateSelection:"updateSelection",userHandleTemplate:"userHandleTemplate",width:"width"},outputs:{animationComplete:"animationComplete",click:"click",collectionChange:"collectionChange",commandExecute:"commandExecute",connectionChange:"connectionChange",contextMenuBeforeItemRender:"contextMenuBeforeItemRender",contextMenuClick:"contextMenuClick",contextMenuOpen:"contextMenuOpen",created:"created",dataLoaded:"dataLoaded",doubleClick:"doubleClick",dragEnter:"dragEnter",dragLeave:"dragLeave",dragOver:"dragOver",drop:"drop",elementDraw:"elementDraw",expandStateChange:"expandStateChange",fixedUserHandleClick:"fixedUserHandleClick",historyChange:"historyChange",historyStateChange:"historyStateChange",keyDown:"keyDown",keyUp:"keyUp",load:"load",loaded:"loaded",mouseEnter:"mouseEnter",mouseLeave:"mouseLeave",mouseOver:"mouseOver",mouseWheel:"mouseWheel",onFixedUserHandleMouseDown:"onFixedUserHandleMouseDown",onFixedUserHandleMouseEnter:"onFixedUserHandleMouseEnter",onFixedUserHandleMouseLeave:"onFixedUserHandleMouseLeave",onFixedUserHandleMouseUp:"onFixedUserHandleMouseUp",onImageLoad:"onImageLoad",onUserHandleMouseDown:"onUserHandleMouseDown",onUserHandleMouseEnter:"onUserHandleMouseEnter",onUserHandleMouseLeave:"onUserHandleMouseLeave",onUserHandleMouseUp:"onUserHandleMouseUp",positionChange:"positionChange",propertyChange:"propertyChange",rotateChange:"rotateChange",scrollChange:"scrollChange",segmentChange:"segmentChange",segmentCollectionChange:"segmentCollectionChange",selectionChange:"selectionChange",sizeChange:"sizeChange",sourcePointChange:"sourcePointChange",targetPointChange:"targetPointChange",textEdit:"textEdit"},features:[yn],decls:0,vars:0,template:function(e,i){},encapsulation:2,changeDetection:0}),fb([TT()],n.prototype,"annotationTemplate",void 0),fb([TT()],n.prototype,"nodeTemplate",void 0),fb([TT()],n.prototype,"userHandleTemplate",void 0),n=fb([Rae([u_])],n),n})(),Lle=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Lm({type:n}),n.\u0275inj=gp({imports:[[rq]]}),n})();const Nle=["diagram"];let Ole=(()=>{class n{constructor(){this.ports=[{id:"port1",offset:{x:0,y:.5},visibility:Gt.Visible},{id:"port2",offset:{x:1,y:.5},visibility:Gt.Visible},{id:"port3",offset:{x:.5,y:0},visibility:Gt.Visible},{id:"port4",offset:{x:.5,y:1},visibility:Gt.Visible}]}addPort(){this.diagram.addPorts(this.diagram.nodes[0],this.ports)}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275cmp=Hb({type:n,selectors:[["app-container"]],viewQuery:function(i,r){if(1&i&&function uP(n,t,e){const i=Ti();i.firstCreatePass&&(cP(i,new aP(n,t,e),-1),2==(2&t)&&(i.staticViewQueries=!0)),hP(i,Se(),t)}(Nle,5),2&i){let s;Kr(s=en())&&(r.diagram=s.first)}},standalone:!0,features:[PP([]),RP],decls:6,vars:4,consts:[[3,"click"],["id","diagram","width","100%","height","580px"],["diagram",""],["id","node1",3,"offsetX","offsetY","width","height"]],template:function(i,r){1&i&&(lg(0,"button",0),aw("click",function(){return r.addPort()}),function MP(n,t=""){const e=Se(),i=Ti(),r=n+jt,s=i.firstCreatePass?Tu(i,r,1,t,null):i.data[r],o=wP(i,e,s,t,n);e[r]=o,Hm()&&hy(i,e,o,s),ll(s,!1)}(1,"AddPort"),hg(),lg(2,"ejs-diagram",1,2)(4,"e-nodes"),tw(5,"e-node",3),hg()()),2&i&&(function CN(n=1){EN(Ti(),Se(),zs()+n,!1)}(5),XM("offsetX",250)("offsetY",250)("width",100)("height",100))},dependencies:[Lle,Ale,v_,m_],encapsulation:2})}}return n})();jd(332),function Xq(n,t){return CG({rootComponent:n,...Ez(t)})}(Ole).catch(n=>console.error(n))},332:()=>{!function(Z){const se=Z.performance;function ye(zi){se&&se.mark&&se.mark(zi)}function pe(zi,ht){se&&se.measure&&se.measure(zi,ht)}ye("Zone");const be=Z.__Zone_symbol_prefix||"__zone_symbol__";function ke(zi){return be+zi}const at=!0===Z[ke("forceDuplicateZoneCheck")];if(Z.Zone){if(at||"function"!=typeof Z.Zone.__symbol__)throw new Error("Zone already loaded.");return Z.Zone}let tt=(()=>{class zi{static{this.__symbol__=ke}static assertZonePatched(){if(Z.Promise!==_o.ZoneAwarePromise)throw new Error("Zone.js has detected that ZoneAwarePromise `(window|global).Promise` has been overwritten.\nMost likely cause is that a Promise polyfill has been loaded after Zone.js (Polyfilling Promise api is not necessary when zone.js is loaded. If you must load one, do so before loading zone.js.)")}static get root(){let F=zi.current;for(;F.parent;)F=F.parent;return F}static get current(){return Ur.zone}static get currentTask(){return Do}static __load_patch(F,ae,Et=!1){if(_o.hasOwnProperty(F)){if(!Et&&at)throw Error("Already loaded patch: "+F)}else if(!Z["__Zone_disable_"+F]){const qt="Zone:"+F;ye(qt),_o[F]=ae(Z,zi,cn),pe(qt,qt)}}get parent(){return this._parent}get name(){return this._name}constructor(F,ae){this._parent=F,this._name=ae?ae.name||"unnamed":"",this._properties=ae&&ae.properties||{},this._zoneDelegate=new Lt(this,this._parent&&this._parent._zoneDelegate,ae)}get(F){const ae=this.getZoneWith(F);if(ae)return ae._properties[F]}getZoneWith(F){let ae=this;for(;ae;){if(ae._properties.hasOwnProperty(F))return ae;ae=ae._parent}return null}fork(F){if(!F)throw new Error("ZoneSpec required!");return this._zoneDelegate.fork(this,F)}wrap(F,ae){if("function"!=typeof F)throw new Error("Expecting function got: "+F);const Et=this._zoneDelegate.intercept(this,F,ae),qt=this;return function(){return qt.runGuarded(Et,this,arguments,ae)}}run(F,ae,Et,qt){Ur={parent:Ur,zone:this};try{return this._zoneDelegate.invoke(this,F,ae,Et,qt)}finally{Ur=Ur.parent}}runGuarded(F,ae=null,Et,qt){Ur={parent:Ur,zone:this};try{try{return this._zoneDelegate.invoke(this,F,ae,Et,qt)}catch(Vn){if(this._zoneDelegate.handleError(this,Vn))throw Vn}}finally{Ur=Ur.parent}}runTask(F,ae,Et){if(F.zone!=this)throw new Error("A task can only be run in the zone of creation! (Creation: "+(F.zone||jn).name+"; Execution: "+this.name+")");if(F.state===sr&&(F.type===rs||F.type===Pt))return;const qt=F.state!=lt;qt&&F._transitionTo(lt,Pi),F.runCount++;const Vn=Do;Do=F,Ur={parent:Ur,zone:this};try{F.type==Pt&&F.data&&!F.data.isPeriodic&&(F.cancelFn=void 0);try{return this._zoneDelegate.invokeTask(this,F,ae,Et)}catch(Ue){if(this._zoneDelegate.handleError(this,Ue))throw Ue}}finally{F.state!==sr&&F.state!==et&&(F.type==rs||F.data&&F.data.isPeriodic?qt&&F._transitionTo(Pi,lt):(F.runCount=0,this._updateTaskCount(F,-1),qt&&F._transitionTo(sr,lt,sr))),Ur=Ur.parent,Do=Vn}}scheduleTask(F){if(F.zone&&F.zone!==this){let Et=this;for(;Et;){if(Et===F.zone)throw Error(`can not reschedule task to ${this.name} which is descendants of the original zone ${F.zone.name}`);Et=Et.parent}}F._transitionTo(Zr,sr);const ae=[];F._zoneDelegates=ae,F._zone=this;try{F=this._zoneDelegate.scheduleTask(this,F)}catch(Et){throw F._transitionTo(et,Zr,sr),this._zoneDelegate.handleError(this,Et),Et}return F._zoneDelegates===ae&&this._updateTaskCount(F,1),F.state==Zr&&F._transitionTo(Pi,Zr),F}scheduleMicroTask(F,ae,Et,qt){return this.scheduleTask(new pt(yi,F,ae,Et,qt,void 0))}scheduleMacroTask(F,ae,Et,qt,Vn){return this.scheduleTask(new pt(Pt,F,ae,Et,qt,Vn))}scheduleEventTask(F,ae,Et,qt,Vn){return this.scheduleTask(new pt(rs,F,ae,Et,qt,Vn))}cancelTask(F){if(F.zone!=this)throw new Error("A task can only be cancelled in the zone of creation! (Creation: "+(F.zone||jn).name+"; Execution: "+this.name+")");if(F.state===Pi||F.state===lt){F._transitionTo(dr,Pi,lt);try{this._zoneDelegate.cancelTask(this,F)}catch(ae){throw F._transitionTo(et,dr),this._zoneDelegate.handleError(this,ae),ae}return this._updateTaskCount(F,-1),F._transitionTo(sr,dr),F.runCount=0,F}}_updateTaskCount(F,ae){const Et=F._zoneDelegates;-1==ae&&(F._zoneDelegates=null);for(let qt=0;qtzi.hasTask(F,ae),onScheduleTask:(zi,ht,F,ae)=>zi.scheduleTask(F,ae),onInvokeTask:(zi,ht,F,ae,Et,qt)=>zi.invokeTask(F,ae,Et,qt),onCancelTask:(zi,ht,F,ae)=>zi.cancelTask(F,ae)};class Lt{constructor(ht,F,ae){this._taskCounts={microTask:0,macroTask:0,eventTask:0},this.zone=ht,this._parentDelegate=F,this._forkZS=ae&&(ae&&ae.onFork?ae:F._forkZS),this._forkDlgt=ae&&(ae.onFork?F:F._forkDlgt),this._forkCurrZone=ae&&(ae.onFork?this.zone:F._forkCurrZone),this._interceptZS=ae&&(ae.onIntercept?ae:F._interceptZS),this._interceptDlgt=ae&&(ae.onIntercept?F:F._interceptDlgt),this._interceptCurrZone=ae&&(ae.onIntercept?this.zone:F._interceptCurrZone),this._invokeZS=ae&&(ae.onInvoke?ae:F._invokeZS),this._invokeDlgt=ae&&(ae.onInvoke?F:F._invokeDlgt),this._invokeCurrZone=ae&&(ae.onInvoke?this.zone:F._invokeCurrZone),this._handleErrorZS=ae&&(ae.onHandleError?ae:F._handleErrorZS),this._handleErrorDlgt=ae&&(ae.onHandleError?F:F._handleErrorDlgt),this._handleErrorCurrZone=ae&&(ae.onHandleError?this.zone:F._handleErrorCurrZone),this._scheduleTaskZS=ae&&(ae.onScheduleTask?ae:F._scheduleTaskZS),this._scheduleTaskDlgt=ae&&(ae.onScheduleTask?F:F._scheduleTaskDlgt),this._scheduleTaskCurrZone=ae&&(ae.onScheduleTask?this.zone:F._scheduleTaskCurrZone),this._invokeTaskZS=ae&&(ae.onInvokeTask?ae:F._invokeTaskZS),this._invokeTaskDlgt=ae&&(ae.onInvokeTask?F:F._invokeTaskDlgt),this._invokeTaskCurrZone=ae&&(ae.onInvokeTask?this.zone:F._invokeTaskCurrZone),this._cancelTaskZS=ae&&(ae.onCancelTask?ae:F._cancelTaskZS),this._cancelTaskDlgt=ae&&(ae.onCancelTask?F:F._cancelTaskDlgt),this._cancelTaskCurrZone=ae&&(ae.onCancelTask?this.zone:F._cancelTaskCurrZone),this._hasTaskZS=null,this._hasTaskDlgt=null,this._hasTaskDlgtOwner=null,this._hasTaskCurrZone=null;const Et=ae&&ae.onHasTask;(Et||F&&F._hasTaskZS)&&(this._hasTaskZS=Et?ae:At,this._hasTaskDlgt=F,this._hasTaskDlgtOwner=this,this._hasTaskCurrZone=ht,ae.onScheduleTask||(this._scheduleTaskZS=At,this._scheduleTaskDlgt=F,this._scheduleTaskCurrZone=this.zone),ae.onInvokeTask||(this._invokeTaskZS=At,this._invokeTaskDlgt=F,this._invokeTaskCurrZone=this.zone),ae.onCancelTask||(this._cancelTaskZS=At,this._cancelTaskDlgt=F,this._cancelTaskCurrZone=this.zone))}fork(ht,F){return this._forkZS?this._forkZS.onFork(this._forkDlgt,this.zone,ht,F):new tt(ht,F)}intercept(ht,F,ae){return this._interceptZS?this._interceptZS.onIntercept(this._interceptDlgt,this._interceptCurrZone,ht,F,ae):F}invoke(ht,F,ae,Et,qt){return this._invokeZS?this._invokeZS.onInvoke(this._invokeDlgt,this._invokeCurrZone,ht,F,ae,Et,qt):F.apply(ae,Et)}handleError(ht,F){return!this._handleErrorZS||this._handleErrorZS.onHandleError(this._handleErrorDlgt,this._handleErrorCurrZone,ht,F)}scheduleTask(ht,F){let ae=F;if(this._scheduleTaskZS)this._hasTaskZS&&ae._zoneDelegates.push(this._hasTaskDlgtOwner),ae=this._scheduleTaskZS.onScheduleTask(this._scheduleTaskDlgt,this._scheduleTaskCurrZone,ht,F),ae||(ae=F);else if(F.scheduleFn)F.scheduleFn(F);else{if(F.type!=yi)throw new Error("Task is missing scheduleFn.");Wt(F)}return ae}invokeTask(ht,F,ae,Et){return this._invokeTaskZS?this._invokeTaskZS.onInvokeTask(this._invokeTaskDlgt,this._invokeTaskCurrZone,ht,F,ae,Et):F.callback.apply(ae,Et)}cancelTask(ht,F){let ae;if(this._cancelTaskZS)ae=this._cancelTaskZS.onCancelTask(this._cancelTaskDlgt,this._cancelTaskCurrZone,ht,F);else{if(!F.cancelFn)throw Error("Task is not cancelable");ae=F.cancelFn(F)}return ae}hasTask(ht,F){try{this._hasTaskZS&&this._hasTaskZS.onHasTask(this._hasTaskDlgt,this._hasTaskCurrZone,ht,F)}catch(ae){this.handleError(ht,ae)}}_updateTaskCount(ht,F){const ae=this._taskCounts,Et=ae[ht],qt=ae[ht]=Et+F;if(qt<0)throw new Error("More tasks executed then were scheduled.");0!=Et&&0!=qt||this.hasTask(this.zone,{microTask:ae.microTask>0,macroTask:ae.macroTask>0,eventTask:ae.eventTask>0,change:ht})}}class pt{constructor(ht,F,ae,Et,qt,Vn){if(this._zone=null,this.runCount=0,this._zoneDelegates=null,this._state="notScheduled",this.type=ht,this.source=F,this.data=Et,this.scheduleFn=qt,this.cancelFn=Vn,!ae)throw new Error("callback is not defined");this.callback=ae;const Ue=this;this.invoke=ht===rs&&Et&&Et.useG?pt.invokeTask:function(){return pt.invokeTask.call(Z,Ue,this,arguments)}}static invokeTask(ht,F,ae){ht||(ht=this),Ls++;try{return ht.runCount++,ht.zone.runTask(ht,F,ae)}finally{1==Ls&&ct(),Ls--}}get zone(){return this._zone}get state(){return this._state}cancelScheduleRequest(){this._transitionTo(sr,Zr)}_transitionTo(ht,F,ae){if(this._state!==F&&this._state!==ae)throw new Error(`${this.type} '${this.source}': can not transition to '${ht}', expecting state '${F}'${ae?" or '"+ae+"'":""}, was '${this._state}'.`);this._state=ht,ht==sr&&(this._zoneDelegates=null)}toString(){return this.data&&typeof this.data.handleId<"u"?this.data.handleId.toString():Object.prototype.toString.call(this)}toJSON(){return{type:this.type,state:this.state,source:this.source,zone:this.zone.name,runCount:this.runCount}}}const Di=ke("setTimeout"),si=ke("Promise"),mi=ke("then");let is,cr=[],ki=!1;function Pr(zi){if(is||Z[si]&&(is=Z[si].resolve(0)),is){let ht=is[mi];ht||(ht=is.then),ht.call(is,zi)}else Z[Di](zi,0)}function Wt(zi){0===Ls&&0===cr.length&&Pr(ct),zi&&cr.push(zi)}function ct(){if(!ki){for(ki=!0;cr.length;){const zi=cr;cr=[];for(let ht=0;htUr,onUnhandledError:jr,microtaskDrainDone:jr,scheduleMicroTask:Wt,showUncaughtError:()=>!tt[ke("ignoreConsoleErrorUncaughtError")],patchEventTarget:()=>[],patchOnProperties:jr,patchMethod:()=>jr,bindArguments:()=>[],patchThen:()=>jr,patchMacroTask:()=>jr,patchEventPrototype:()=>jr,isIEOrEdge:()=>!1,getGlobalObjects:()=>{},ObjectDefineProperty:()=>jr,ObjectGetOwnPropertyDescriptor:()=>{},ObjectCreate:()=>{},ArraySlice:()=>[],patchClass:()=>jr,wrapWithCurrentZone:()=>jr,filterProperties:()=>[],attachOriginToPatched:()=>jr,_redefineProperty:()=>jr,patchCallbacks:()=>jr,nativeScheduleMicroTask:Pr};let Ur={parent:null,zone:new tt(null,null)},Do=null,Ls=0;function jr(){}pe("Zone","Zone"),Z.Zone=tt}(globalThis);const Wl=Object.getOwnPropertyDescriptor,Ud=Object.defineProperty,jd=Object.getPrototypeOf,Vd=Object.create,vb=Array.prototype.slice,pm="addEventListener",$r="removeEventListener",Yl=Zone.__symbol__(pm),_h=Zone.__symbol__($r),Ts="true",Wi="false",Wd=Zone.__symbol__("");function op(Z,se){return Zone.current.wrap(Z,se)}function gm(Z,se,ye,pe,be){return Zone.current.scheduleMacroTask(Z,se,ye,pe,be)}const Ji=Zone.__symbol__,Uh=typeof window<"u",jh=Uh?window:void 0,gn=Uh&&jh||globalThis,vm="removeAttribute";function Yd(Z,se){for(let ye=Z.length-1;ye>=0;ye--)"function"==typeof Z[ye]&&(Z[ye]=op(Z[ye],se+"_"+ye));return Z}function ap(Z){return!Z||!1!==Z.writable&&!("function"==typeof Z.get&&typeof Z.set>"u")}const lp=typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope,Vh=!("nw"in gn)&&typeof gn.process<"u"&&"[object process]"==={}.toString.call(gn.process),Qd=!Vh&&!lp&&!(!Uh||!jh.HTMLElement),hp=typeof gn.process<"u"&&"[object process]"==={}.toString.call(gn.process)&&!lp&&!(!Uh||!jh.HTMLElement),Ql={},Wh=function(Z){if(!(Z=Z||gn.event))return;let se=Ql[Z.type];se||(se=Ql[Z.type]=Ji("ON_PROPERTY"+Z.type));const ye=this||Z.target||gn,pe=ye[se];let be;return Qd&&ye===jh&&"error"===Z.type?(be=pe&&pe.call(this,Z.message,Z.filename,Z.lineno,Z.colno,Z.error),!0===be&&Z.preventDefault()):(be=pe&&pe.apply(this,arguments),null!=be&&!be&&Z.preventDefault()),be};function Gl(Z,se,ye){let pe=Wl(Z,se);if(!pe&&ye&&Wl(ye,se)&&(pe={enumerable:!0,configurable:!0}),!pe||!pe.configurable)return;const be=Ji("on"+se+"patched");if(Z.hasOwnProperty(be)&&Z[be])return;delete pe.writable,delete pe.value;const ke=pe.get,at=pe.set,tt=se.slice(2);let At=Ql[tt];At||(At=Ql[tt]=Ji("ON_PROPERTY"+tt)),pe.set=function(Lt){let pt=this;!pt&&Z===gn&&(pt=gn),pt&&("function"==typeof pt[At]&&pt.removeEventListener(tt,Wh),at&&at.call(pt,null),pt[At]=Lt,"function"==typeof Lt&&pt.addEventListener(tt,Wh,!1))},pe.get=function(){let Lt=this;if(!Lt&&Z===gn&&(Lt=gn),!Lt)return null;const pt=Lt[At];if(pt)return pt;if(ke){let Di=ke.call(this);if(Di)return pe.set.call(this,Di),"function"==typeof Lt[vm]&&Lt.removeAttribute(se),Di}return null},Ud(Z,se,pe),Z[be]=!0}function cp(Z,se,ye){if(se)for(let pe=0;pefunction(at,tt){const At=ye(at,tt);return At.cbIdx>=0&&"function"==typeof tt[At.cbIdx]?gm(At.name,tt[At.cbIdx],At,be):ke.apply(at,tt)})}function Ia(Z,se){Z[Ji("OriginalDelegate")]=se}let yb=!1,Xd=!1;function Sb(){if(yb)return Xd;yb=!0;try{const Z=jh.navigator.userAgent;(-1!==Z.indexOf("MSIE ")||-1!==Z.indexOf("Trident/")||-1!==Z.indexOf("Edge/"))&&(Xd=!0)}catch{}return Xd}Zone.__load_patch("ZoneAwarePromise",(Z,se,ye)=>{const pe=Object.getOwnPropertyDescriptor,be=Object.defineProperty,at=ye.symbol,tt=[],At=!1!==Z[at("DISABLE_WRAPPING_UNCAUGHT_PROMISE_REJECTION")],Lt=at("Promise"),pt=at("then"),Di="__creationTrace__";ye.onUnhandledError=Ue=>{if(ye.showUncaughtError()){const He=Ue&&Ue.rejection;He?console.error("Unhandled Promise rejection:",He instanceof Error?He.message:He,"; Zone:",Ue.zone.name,"; Task:",Ue.task&&Ue.task.source,"; Value:",He,He instanceof Error?He.stack:void 0):console.error(Ue)}},ye.microtaskDrainDone=()=>{for(;tt.length;){const Ue=tt.shift();try{Ue.zone.runGuarded(()=>{throw Ue.throwOriginal?Ue.rejection:Ue})}catch(He){mi(He)}}};const si=at("unhandledPromiseRejectionHandler");function mi(Ue){ye.onUnhandledError(Ue);try{const He=se[si];"function"==typeof He&&He.call(this,Ue)}catch{}}function cr(Ue){return Ue&&Ue.then}function ki(Ue){return Ue}function is(Ue){return F.reject(Ue)}const Pr=at("state"),Wt=at("value"),ct=at("finally"),jn=at("parentPromiseValue"),sr=at("parentPromiseState"),Zr="Promise.then",Pi=null,lt=!0,dr=!1,et=0;function yi(Ue,He){return ge=>{try{cn(Ue,He,ge)}catch(We){cn(Ue,!1,We)}}}const Pt=function(){let Ue=!1;return function(ge){return function(){Ue||(Ue=!0,ge.apply(null,arguments))}}},rs="Promise resolved with itself",_o=at("currentTaskTrace");function cn(Ue,He,ge){const We=Pt();if(Ue===ge)throw new TypeError(rs);if(Ue[Pr]===Pi){let wt=null;try{("object"==typeof ge||"function"==typeof ge)&&(wt=ge&&ge.then)}catch(Xe){return We(()=>{cn(Ue,!1,Xe)})(),Ue}if(He!==dr&&ge instanceof F&&ge.hasOwnProperty(Pr)&&ge.hasOwnProperty(Wt)&&ge[Pr]!==Pi)Do(ge),cn(Ue,ge[Pr],ge[Wt]);else if(He!==dr&&"function"==typeof wt)try{wt.call(ge,We(yi(Ue,He)),We(yi(Ue,!1)))}catch(Xe){We(()=>{cn(Ue,!1,Xe)})()}else{Ue[Pr]=He;const Xe=Ue[Wt];if(Ue[Wt]=ge,Ue[ct]===ct&&He===lt&&(Ue[Pr]=Ue[sr],Ue[Wt]=Ue[jn]),He===dr&&ge instanceof Error){const mt=se.currentTask&&se.currentTask.data&&se.currentTask.data[Di];mt&&be(ge,_o,{configurable:!0,enumerable:!1,writable:!0,value:mt})}for(let mt=0;mt{try{const dt=Ue[Wt],$t=!!ge&&ct===ge[ct];$t&&(ge[jn]=dt,ge[sr]=Xe);const hi=He.run(mt,void 0,$t&&mt!==is&&mt!==ki?[]:[dt]);cn(ge,!0,hi)}catch(dt){cn(ge,!1,dt)}},ge)}const zi=function(){},ht=Z.AggregateError;class F{static toString(){return"function ZoneAwarePromise() { [native code] }"}static resolve(He){return He instanceof F?He:cn(new this(null),lt,He)}static reject(He){return cn(new this(null),dr,He)}static withResolvers(){const He={};return He.promise=new F((ge,We)=>{He.resolve=ge,He.reject=We}),He}static any(He){if(!He||"function"!=typeof He[Symbol.iterator])return Promise.reject(new ht([],"All promises were rejected"));const ge=[];let We=0;try{for(let mt of He)We++,ge.push(F.resolve(mt))}catch{return Promise.reject(new ht([],"All promises were rejected"))}if(0===We)return Promise.reject(new ht([],"All promises were rejected"));let wt=!1;const Xe=[];return new F((mt,dt)=>{for(let $t=0;$t{wt||(wt=!0,mt(hi))},hi=>{Xe.push(hi),We--,0===We&&(wt=!0,dt(new ht(Xe,"All promises were rejected")))})})}static race(He){let ge,We,wt=new this((dt,$t)=>{ge=dt,We=$t});function Xe(dt){ge(dt)}function mt(dt){We(dt)}for(let dt of He)cr(dt)||(dt=this.resolve(dt)),dt.then(Xe,mt);return wt}static all(He){return F.allWithCallback(He)}static allSettled(He){return(this&&this.prototype instanceof F?this:F).allWithCallback(He,{thenCallback:We=>({status:"fulfilled",value:We}),errorCallback:We=>({status:"rejected",reason:We})})}static allWithCallback(He,ge){let We,wt,Xe=new this((hi,ur)=>{We=hi,wt=ur}),mt=2,dt=0;const $t=[];for(let hi of He){cr(hi)||(hi=this.resolve(hi));const ur=dt;try{hi.then(ir=>{$t[ur]=ge?ge.thenCallback(ir):ir,mt--,0===mt&&We($t)},ir=>{ge?($t[ur]=ge.errorCallback(ir),mt--,0===mt&&We($t)):wt(ir)})}catch(ir){wt(ir)}mt++,dt++}return mt-=2,0===mt&&We($t),Xe}constructor(He){const ge=this;if(!(ge instanceof F))throw new Error("Must be an instanceof Promise.");ge[Pr]=Pi,ge[Wt]=[];try{const We=Pt();He&&He(We(yi(ge,lt)),We(yi(ge,dr)))}catch(We){cn(ge,!1,We)}}get[Symbol.toStringTag](){return"Promise"}get[Symbol.species](){return F}then(He,ge){let We=this.constructor?.[Symbol.species];(!We||"function"!=typeof We)&&(We=this.constructor||F);const wt=new We(zi),Xe=se.current;return this[Pr]==Pi?this[Wt].push(Xe,wt,He,ge):Ls(this,Xe,wt,He,ge),wt}catch(He){return this.then(null,He)}finally(He){let ge=this.constructor?.[Symbol.species];(!ge||"function"!=typeof ge)&&(ge=F);const We=new ge(zi);We[ct]=ct;const wt=se.current;return this[Pr]==Pi?this[Wt].push(wt,We,He,He):Ls(this,wt,We,He,He),We}}F.resolve=F.resolve,F.reject=F.reject,F.race=F.race,F.all=F.all;const ae=Z[Lt]=Z.Promise;Z.Promise=F;const Et=at("thenPatched");function qt(Ue){const He=Ue.prototype,ge=pe(He,"then");if(ge&&(!1===ge.writable||!ge.configurable))return;const We=He.then;He[pt]=We,Ue.prototype.then=function(wt,Xe){return new F((dt,$t)=>{We.call(this,dt,$t)}).then(wt,Xe)},Ue[Et]=!0}return ye.patchThen=qt,ae&&(qt(ae),tl(Z,"fetch",Ue=>function Vn(Ue){return function(He,ge){let We=Ue.apply(He,ge);if(We instanceof F)return We;let wt=We.constructor;return wt[Et]||qt(wt),We}}(Ue))),Promise[se.__symbol__("uncaughtPromiseErrors")]=tt,F}),Zone.__load_patch("toString",Z=>{const se=Function.prototype.toString,ye=Ji("OriginalDelegate"),pe=Ji("Promise"),be=Ji("Error"),ke=function(){if("function"==typeof this){const Lt=this[ye];if(Lt)return"function"==typeof Lt?se.call(Lt):Object.prototype.toString.call(Lt);if(this===Promise){const pt=Z[pe];if(pt)return se.call(pt)}if(this===Error){const pt=Z[be];if(pt)return se.call(pt)}}return se.call(this)};ke[ye]=se,Function.prototype.toString=ke;const at=Object.prototype.toString;Object.prototype.toString=function(){return"function"==typeof Promise&&this instanceof Promise?"[object Promise]":at.call(this)}});let il=!1;if(typeof window<"u")try{const Z=Object.defineProperty({},"passive",{get:function(){il=!0}});window.addEventListener("test",Z,Z),window.removeEventListener("test",Z,Z)}catch{il=!1}const kT={useG:!0},Co={},Ib={},Sm=new RegExp("^"+Wd+"(\\w+)(true|false)$"),bb=Ji("propagationStopped");function Im(Z,se){const ye=(se?se(Z):Z)+Wi,pe=(se?se(Z):Z)+Ts,be=Wd+ye,ke=Wd+pe;Co[Z]={},Co[Z][Wi]=be,Co[Z][Ts]=ke}function Mb(Z,se,ye,pe){const be=pe&&pe.add||pm,ke=pe&&pe.rm||$r,at=pe&&pe.listeners||"eventListeners",tt=pe&&pe.rmAll||"removeAllListeners",At=Ji(be),Lt="."+be+":",pt="prependListener",Di="."+pt+":",si=function(Wt,ct,jn){if(Wt.isRemoved)return;const sr=Wt.callback;let Zr;"object"==typeof sr&&sr.handleEvent&&(Wt.callback=lt=>sr.handleEvent(lt),Wt.originalDelegate=sr);try{Wt.invoke(Wt,ct,[jn])}catch(lt){Zr=lt}const Pi=Wt.options;return Pi&&"object"==typeof Pi&&Pi.once&&ct[ke].call(ct,jn.type,Wt.originalDelegate?Wt.originalDelegate:Wt.callback,Pi),Zr};function mi(Wt,ct,jn){if(!(ct=ct||Z.event))return;const sr=Wt||ct.target||Z,Zr=sr[Co[ct.type][jn?Ts:Wi]];if(Zr){const Pi=[];if(1===Zr.length){const lt=si(Zr[0],sr,ct);lt&&Pi.push(lt)}else{const lt=Zr.slice();for(let dr=0;dr{throw dr})}}}const cr=function(Wt){return mi(this,Wt,!1)},ki=function(Wt){return mi(this,Wt,!0)};function is(Wt,ct){if(!Wt)return!1;let jn=!0;ct&&void 0!==ct.useG&&(jn=ct.useG);const sr=ct&&ct.vh;let Zr=!0;ct&&void 0!==ct.chkDup&&(Zr=ct.chkDup);let Pi=!1;ct&&void 0!==ct.rt&&(Pi=ct.rt);let lt=Wt;for(;lt&&!lt.hasOwnProperty(be);)lt=jd(lt);if(!lt&&Wt[be]&&(lt=Wt),!lt||lt[At])return!1;const dr=ct&&ct.eventNameToString,et={},yi=lt[At]=lt[be],Pt=lt[Ji(ke)]=lt[ke],rs=lt[Ji(at)]=lt[at],_o=lt[Ji(tt)]=lt[tt];let cn;ct&&ct.prepend&&(cn=lt[Ji(ct.prepend)]=lt[ct.prepend]);const F=jn?function(ge){if(!et.isExisting)return yi.call(et.target,et.eventName,et.capture?ki:cr,et.options)}:function(ge){return yi.call(et.target,et.eventName,ge.invoke,et.options)},ae=jn?function(ge){if(!ge.isRemoved){const We=Co[ge.eventName];let wt;We&&(wt=We[ge.capture?Ts:Wi]);const Xe=wt&&ge.target[wt];if(Xe)for(let mt=0;mt{Vo.zone.cancelTask(Vo)},{once:!0})),et.target=null,Fc&&(Fc.taskData=null),$d&&(Tn.once=!0),!il&&"boolean"==typeof Vo.options||(Vo.options=Tn),Vo.target=$t,Vo.capture=Zl,Vo.eventName=hi,ir&&(Vo.originalDelegate=ur),dt?jo.unshift(Vo):jo.push(Vo),mt?$t:void 0}};return lt[be]=He(yi,Lt,F,ae,Pi),cn&&(lt[pt]=He(cn,Di,function(ge){return cn.call(et.target,et.eventName,ge.invoke,et.options)},ae,Pi,!0)),lt[ke]=function(){const ge=this||Z;let We=arguments[0];ct&&ct.transferEventName&&(We=ct.transferEventName(We));const wt=arguments[2],Xe=!!wt&&("boolean"==typeof wt||wt.capture),mt=arguments[1];if(!mt)return Pt.apply(this,arguments);if(sr&&!sr(Pt,mt,ge,arguments))return;const dt=Co[We];let $t;dt&&($t=dt[Xe?Ts:Wi]);const hi=$t&&ge[$t];if(hi)for(let ur=0;urfunction(be,ke){be[bb]=!0,pe&&pe.apply(be,ke)})}function Cb(Z,se,ye,pe,be){const ke=Zone.__symbol__(pe);if(se[ke])return;const at=se[ke]=se[pe];se[pe]=function(tt,At,Lt){return At&&At.prototype&&be.forEach(function(pt){const Di=`${ye}.${pe}::`+pt,si=At.prototype;try{if(si.hasOwnProperty(pt)){const mi=Z.ObjectGetOwnPropertyDescriptor(si,pt);mi&&mi.value?(mi.value=Z.wrapWithCurrentZone(mi.value,Di),Z._redefineProperty(At.prototype,pt,mi)):si[pt]&&(si[pt]=Z.wrapWithCurrentZone(si[pt],Di))}else si[pt]&&(si[pt]=Z.wrapWithCurrentZone(si[pt],Di))}catch{}}),at.call(se,tt,At,Lt)},Z.attachOriginToPatched(se[pe],at)}function Eb(Z,se,ye){if(!ye||0===ye.length)return se;const pe=ye.filter(ke=>ke.target===Z);if(!pe||0===pe.length)return se;const be=pe[0].ignoreProperties;return se.filter(ke=>-1===be.indexOf(ke))}function Eo(Z,se,ye,pe){Z&&cp(Z,Eb(Z,se,ye),pe)}function qd(Z){return Object.getOwnPropertyNames(Z).filter(se=>se.startsWith("on")&&se.length>2).map(se=>se.substring(2))}Zone.__load_patch("util",(Z,se,ye)=>{const pe=qd(Z);ye.patchOnProperties=cp,ye.patchMethod=tl,ye.bindArguments=Yd,ye.patchMacroTask=mb;const be=se.__symbol__("BLACK_LISTED_EVENTS"),ke=se.__symbol__("UNPATCHED_EVENTS");Z[ke]&&(Z[be]=Z[ke]),Z[be]&&(se[be]=se[ke]=Z[be]),ye.patchEventPrototype=bm,ye.patchEventTarget=Mb,ye.isIEOrEdge=Sb,ye.ObjectDefineProperty=Ud,ye.ObjectGetOwnPropertyDescriptor=Wl,ye.ObjectCreate=Vd,ye.ArraySlice=vb,ye.patchClass=Gd,ye.wrapWithCurrentZone=op,ye.filterProperties=Eb,ye.attachOriginToPatched=Ia,ye._redefineProperty=Object.defineProperty,ye.patchCallbacks=Cb,ye.getGlobalObjects=()=>({globalSources:Ib,zoneSymbolEventNames:Co,eventNames:pe,isBrowser:Qd,isMix:hp,isNode:Vh,TRUE_STR:Ts,FALSE_STR:Wi,ZONE_SYMBOL_PREFIX:Wd,ADD_EVENT_LISTENER_STR:pm,REMOVE_EVENT_LISTENER_STR:$r})});const As=Ji("zoneTask");function Xl(Z,se,ye,pe){let be=null,ke=null;ye+=pe;const at={};function tt(Lt){const pt=Lt.data;return pt.args[0]=function(){return Lt.invoke.apply(this,arguments)},pt.handleId=be.apply(Z,pt.args),Lt}function At(Lt){return ke.call(Z,Lt.data.handleId)}be=tl(Z,se+=pe,Lt=>function(pt,Di){if("function"==typeof Di[0]){const si={isPeriodic:"Interval"===pe,delay:"Timeout"===pe||"Interval"===pe?Di[1]||0:void 0,args:Di},mi=Di[0];Di[0]=function(){try{return mi.apply(this,arguments)}finally{si.isPeriodic||("number"==typeof si.handleId?delete at[si.handleId]:si.handleId&&(si.handleId[As]=null))}};const cr=gm(se,Di[0],si,tt,At);if(!cr)return cr;const ki=cr.data.handleId;return"number"==typeof ki?at[ki]=cr:ki&&(ki[As]=cr),ki&&ki.ref&&ki.unref&&"function"==typeof ki.ref&&"function"==typeof ki.unref&&(cr.ref=ki.ref.bind(ki),cr.unref=ki.unref.bind(ki)),"number"==typeof ki||ki?ki:cr}return Lt.apply(Z,Di)}),ke=tl(Z,ye,Lt=>function(pt,Di){const si=Di[0];let mi;"number"==typeof si?mi=at[si]:(mi=si&&si[As],mi||(mi=si)),mi&&"string"==typeof mi.type?"notScheduled"!==mi.state&&(mi.cancelFn&&mi.data.isPeriodic||0===mi.runCount)&&("number"==typeof si?delete at[si]:si&&(si[As]=null),mi.zone.cancelTask(mi)):Lt.apply(Z,Di)})}Zone.__load_patch("legacy",Z=>{const se=Z[Zone.__symbol__("legacyPatch")];se&&se()}),Zone.__load_patch("timers",Z=>{const ye="clear";Xl(Z,"set",ye,"Timeout"),Xl(Z,"set",ye,"Interval"),Xl(Z,"set",ye,"Immediate")}),Zone.__load_patch("requestAnimationFrame",Z=>{Xl(Z,"request","cancel","AnimationFrame"),Xl(Z,"mozRequest","mozCancel","AnimationFrame"),Xl(Z,"webkitRequest","webkitCancel","AnimationFrame")}),Zone.__load_patch("blocking",(Z,se)=>{const ye=["alert","prompt","confirm"];for(let pe=0;pefunction(At,Lt){return se.current.run(ke,Z,Lt,tt)})}),Zone.__load_patch("EventTarget",(Z,se,ye)=>{(function ql(Z,se){se.patchEventPrototype(Z,se)})(Z,ye),function wm(Z,se){if(Zone[se.symbol("patchEventTarget")])return;const{eventNames:ye,zoneSymbolEventNames:pe,TRUE_STR:be,FALSE_STR:ke,ZONE_SYMBOL_PREFIX:at}=se.getGlobalObjects();for(let At=0;At{Gd("MutationObserver"),Gd("WebKitMutationObserver")}),Zone.__load_patch("IntersectionObserver",(Z,se,ye)=>{Gd("IntersectionObserver")}),Zone.__load_patch("FileReader",(Z,se,ye)=>{Gd("FileReader")}),Zone.__load_patch("on_property",(Z,se,ye)=>{!function dp(Z,se){if(Vh&&!hp||Zone[Z.symbol("patchEvents")])return;const ye=se.__Zone_ignore_on_properties;let pe=[];if(Qd){const be=window;pe=pe.concat(["Document","SVGElement","Element","HTMLElement","HTMLBodyElement","HTMLMediaElement","HTMLFrameSetElement","HTMLFrameElement","HTMLIFrameElement","HTMLMarqueeElement","Worker"]);const ke=function ym(){try{const Z=jh.navigator.userAgent;if(-1!==Z.indexOf("MSIE ")||-1!==Z.indexOf("Trident/"))return!0}catch{}return!1}()?[{target:be,ignoreProperties:["error"]}]:[];Eo(be,qd(be),ye&&ye.concat(ke),jd(be))}pe=pe.concat(["XMLHttpRequest","XMLHttpRequestEventTarget","IDBIndex","IDBRequest","IDBOpenDBRequest","IDBDatabase","IDBTransaction","IDBCursor","WebSocket"]);for(let be=0;be{!function Mm(Z,se){const{isBrowser:ye,isMix:pe}=se.getGlobalObjects();(ye||pe)&&Z.customElements&&"customElements"in Z&&se.patchCallbacks(se,Z.customElements,"customElements","define",["connectedCallback","disconnectedCallback","adoptedCallback","attributeChangedCallback"])}(Z,ye)}),Zone.__load_patch("XHR",(Z,se)=>{!function At(Lt){const pt=Lt.XMLHttpRequest;if(!pt)return;const Di=pt.prototype;let mi=Di[Yl],cr=Di[_h];if(!mi){const et=Lt.XMLHttpRequestEventTarget;if(et){const yi=et.prototype;mi=yi[Yl],cr=yi[_h]}}const ki="readystatechange",is="scheduled";function Pr(et){const yi=et.data,Pt=yi.target;Pt[ke]=!1,Pt[tt]=!1;const rs=Pt[be];mi||(mi=Pt[Yl],cr=Pt[_h]),rs&&cr.call(Pt,ki,rs);const _o=Pt[be]=()=>{if(Pt.readyState===Pt.DONE)if(!yi.aborted&&Pt[ke]&&et.state===is){const Ur=Pt[se.__symbol__("loadfalse")];if(0!==Pt.status&&Ur&&Ur.length>0){const Do=et.invoke;et.invoke=function(){const Ls=Pt[se.__symbol__("loadfalse")];for(let jr=0;jrfunction(et,yi){return et[pe]=0==yi[2],et[at]=yi[1],jn.apply(et,yi)}),Zr=Ji("fetchTaskAborting"),Pi=Ji("fetchTaskScheduling"),lt=tl(Di,"send",()=>function(et,yi){if(!0===se.current[Pi]||et[pe])return lt.apply(et,yi);{const Pt={target:et,url:et[at],isPeriodic:!1,args:yi,aborted:!1},rs=gm("XMLHttpRequest.send",Wt,Pt,Pr,ct);et&&!0===et[tt]&&!Pt.aborted&&rs.state===is&&rs.invoke()}}),dr=tl(Di,"abort",()=>function(et,yi){const Pt=function si(et){return et[ye]}(et);if(Pt&&"string"==typeof Pt.type){if(null==Pt.cancelFn||Pt.data&&Pt.data.aborted)return;Pt.zone.cancelTask(Pt)}else if(!0===se.current[Zr])return dr.apply(et,yi)})}(Z);const ye=Ji("xhrTask"),pe=Ji("xhrSync"),be=Ji("xhrListener"),ke=Ji("xhrScheduled"),at=Ji("xhrURL"),tt=Ji("xhrErrorBeforeScheduled")}),Zone.__load_patch("geolocation",Z=>{Z.navigator&&Z.navigator.geolocation&&function mm(Z,se){const ye=Z.constructor.name;for(let pe=0;pe{const At=function(){return tt.apply(this,Yd(arguments,ye+"."+be))};return Ia(At,tt),At})(ke)}}}(Z.navigator.geolocation,["getCurrentPosition","watchPosition"])}),Zone.__load_patch("PromiseRejectionEvent",(Z,se)=>{function ye(pe){return function(be){wb(Z,pe).forEach(at=>{const tt=Z.PromiseRejectionEvent;if(tt){const At=new tt(pe,{promise:be.promise,reason:be.rejection});at.invoke(At)}})}}Z.PromiseRejectionEvent&&(se[Ji("unhandledPromiseRejectionHandler")]=ye("unhandledrejection"),se[Ji("rejectionHandledHandler")]=ye("rejectionhandled"))}),Zone.__load_patch("queueMicrotask",(Z,se,ye)=>{!function up(Z,se){se.patchMethod(Z,"queueMicrotask",ye=>function(pe,be){Zone.current.scheduleMicroTask("queueMicrotask",be[0])})}(Z,ye)})}},Wl=>{Wl(Wl.s=51)}]); \ No newline at end of file diff --git a/ej2-angular/samples/diagram/ports/connectionPort/index.html b/ej2-angular/samples/diagram/ports/connectionPort/index.html index f11402c02f..76ac92329f 100644 --- a/ej2-angular/samples/diagram/ports/connectionPort/index.html +++ b/ej2-angular/samples/diagram/ports/connectionPort/index.html @@ -19,5 +19,5 @@
Loading....
- + \ No newline at end of file diff --git a/ej2-angular/samples/diagram/ports/connectionPort/main.af1e59c52e0906ea.js b/ej2-angular/samples/diagram/ports/connectionPort/main.af1e59c52e0906ea.js deleted file mode 100644 index 37a2a1b397..0000000000 --- a/ej2-angular/samples/diagram/ports/connectionPort/main.af1e59c52e0906ea.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";(self.webpackChunksyncfusion_component=self.webpackChunksyncfusion_component||[]).push([[179],{51:(_l,_d,Ud)=>{let $r=null,Fh=1;const Ts=Symbol("SIGNAL");function Wi(n){const t=$r;return $r=n,t}function gn(n){if((!Vh(n)||n.dirty)&&(n.dirty||n.lastCleanEpoch!==Fh)){if(!n.producerMustRecompute(n)&&!jh(n))return n.dirty=!1,void(n.lastCleanEpoch=Fh);n.producerRecomputeValue(n),n.dirty=!1,n.lastCleanEpoch=Fh}}function jh(n){Vl(n);for(let t=0;t0}function Vl(n){n.producerNode??=[],n.producerIndexOfThis??=[],n.producerLastReadVersion??=[]}let Gd=null;function Eo(n){return"function"==typeof n}function Xd(n){const e=n(i=>{Error.call(i),i.stack=(new Error).stack});return e.prototype=Object.create(Error.prototype),e.prototype.constructor=e,e}const pf=Xd(n=>function(e){n(this),this.message=e?`${e.length} errors occurred during unsubscription:\n${e.map((i,r)=>`${r+1}) ${i.toString()}`).join("\n ")}`:"",this.name="UnsubscriptionError",this.errors=e});function ff(n,t){if(n){const e=n.indexOf(t);0<=e&&n.splice(e,1)}}class As{constructor(t){this.initialTeardown=t,this.closed=!1,this._parentage=null,this._finalizers=null}unsubscribe(){let t;if(!this.closed){this.closed=!0;const{_parentage:e}=this;if(e)if(this._parentage=null,Array.isArray(e))for(const s of e)s.remove(this);else e.remove(this);const{initialTeardown:i}=this;if(Eo(i))try{i()}catch(s){t=s instanceof pf?s.errors:[s]}const{_finalizers:r}=this;if(r){this._finalizers=null;for(const s of r)try{Mm(s)}catch(o){t=t??[],o instanceof pf?t=[...t,...o.errors]:t.push(o)}}if(t)throw new pf(t)}}add(t){var e;if(t&&t!==this)if(this.closed)Mm(t);else{if(t instanceof As){if(t.closed||t._hasParent(this))return;t._addParent(this)}(this._finalizers=null!==(e=this._finalizers)&&void 0!==e?e:[]).push(t)}}_hasParent(t){const{_parentage:e}=this;return e===t||Array.isArray(e)&&e.includes(t)}_addParent(t){const{_parentage:e}=this;this._parentage=Array.isArray(e)?(e.push(t),e):e?[e,t]:t}_removeParent(t){const{_parentage:e}=this;e===t?this._parentage=null:Array.isArray(e)&&ff(e,t)}remove(t){const{_finalizers:e}=this;e&&ff(e,t),t instanceof As&&t._removeParent(this)}}As.EMPTY=(()=>{const n=new As;return n.closed=!0,n})();const Wl=As.EMPTY;function bm(n){return n instanceof As||n&&"closed"in n&&Eo(n.remove)&&Eo(n.add)&&Eo(n.unsubscribe)}function Mm(n){Eo(n)?n():n.unsubscribe()}const Yl={onUnhandledError:null,onStoppedNotification:null,Promise:void 0,useDeprecatedSynchronousErrorHandling:!1,useDeprecatedNextContext:!1},Z={setTimeout(n,t,...e){const{delegate:i}=Z;return i?.setTimeout?i.setTimeout(n,t,...e):setTimeout(n,t,...e)},clearTimeout(n){const{delegate:t}=Z;return(t?.clearTimeout||clearTimeout)(n)},delegate:void 0};function ye(){}const fe=at("C",void 0,void 0);function at(n,t,e){return{kind:n,value:t,error:e}}let tt=null;function At(n){if(Yl.useDeprecatedSynchronousErrorHandling){const t=!tt;if(t&&(tt={errorThrown:!1,error:null}),n(),t){const{errorThrown:e,error:i}=tt;if(tt=null,e)throw i}}else n()}class ft extends As{constructor(t){super(),this.isStopped=!1,t?(this.destination=t,bm(t)&&t.add(this)):this.destination=Wt}static create(t,e,i){return new cr(t,e,i)}next(t){this.isStopped?kr(function ke(n){return at("N",n,void 0)}(t),this):this._next(t)}error(t){this.isStopped?kr(function be(n){return at("E",void 0,n)}(t),this):(this.isStopped=!0,this._error(t))}complete(){this.isStopped?kr(fe,this):(this.isStopped=!0,this._complete())}unsubscribe(){this.closed||(this.isStopped=!0,super.unsubscribe(),this.destination=null)}_next(t){this.destination.next(t)}_error(t){try{this.destination.error(t)}finally{this.unsubscribe()}}_complete(){try{this.destination.complete()}finally{this.unsubscribe()}}}const Ei=Function.prototype.bind;function ii(n,t){return Ei.call(n,t)}class gi{constructor(t){this.partialObserver=t}next(t){const{partialObserver:e}=this;if(e.next)try{e.next(t)}catch(i){Oi(i)}}error(t){const{partialObserver:e}=this;if(e.error)try{e.error(t)}catch(i){Oi(i)}else Oi(t)}complete(){const{partialObserver:t}=this;if(t.complete)try{t.complete()}catch(e){Oi(e)}}}class cr extends ft{constructor(t,e,i){let r;if(super(),Eo(t)||!t)r={next:t??void 0,error:e??void 0,complete:i??void 0};else{let s;this&&Yl.useDeprecatedNextContext?(s=Object.create(t),s.unsubscribe=()=>this.unsubscribe(),r={next:t.next&&ii(t.next,s),error:t.error&&ii(t.error,s),complete:t.complete&&ii(t.complete,s)}):r=t}this.destination=new gi(r)}}function Oi(n){Yl.useDeprecatedSynchronousErrorHandling?function Lt(n){Yl.useDeprecatedSynchronousErrorHandling&&tt&&(tt.errorThrown=!0,tt.error=n)}(n):function se(n){Z.setTimeout(()=>{const{onUnhandledError:t}=Yl;if(!t)throw n;t(n)})}(n)}function kr(n,t){const{onStoppedNotification:e}=Yl;e&&Z.setTimeout(()=>e(n,t))}const Wt={closed:!0,next:ye,error:function es(n){throw n},complete:ye},ct="function"==typeof Symbol&&Symbol.observable||"@@observable";function _n(n){return n}let ki=(()=>{class n{constructor(e){e&&(this._subscribe=e)}lift(e){const i=new n;return i.source=this,i.operator=e,i}subscribe(e,i,r){const s=function et(n){return n&&n instanceof ft||function dr(n){return n&&Eo(n.next)&&Eo(n.error)&&Eo(n.complete)}(n)&&bm(n)}(e)?e:new cr(e,i,r);return At(()=>{const{operator:o,source:a}=this;s.add(o?o.call(s,a):a?this._subscribe(s):this._trySubscribe(s))}),s}_trySubscribe(e){try{return this._subscribe(e)}catch(i){e.error(i)}}forEach(e,i){return new(i=lt(i))((r,s)=>{const o=new cr({next:a=>{try{e(a)}catch(l){s(l),o.unsubscribe()}},error:s,complete:r});this.subscribe(o)})}_subscribe(e){var i;return null===(i=this.source)||void 0===i?void 0:i.subscribe(e)}[ct](){return this}pipe(...e){return function Zr(n){return 0===n.length?_n:1===n.length?n[0]:function(e){return n.reduce((i,r)=>r(i),e)}}(e)(this)}toPromise(e){return new(e=lt(e))((i,r)=>{let s;this.subscribe(o=>s=o,o=>r(o),()=>i(s))})}}return n.create=t=>new n(t),n})();function lt(n){var t;return null!==(t=n??Yl.Promise)&&void 0!==t?t:Promise}const vi=Xd(n=>function(){n(this),this.name="ObjectUnsubscribedError",this.message="object unsubscribed"});let Pt=(()=>{class n extends ki{constructor(){super(),this.closed=!1,this.currentObservers=null,this.observers=[],this.isStopped=!1,this.hasError=!1,this.thrownError=null}lift(e){const i=new ts(this,this);return i.operator=e,i}_throwIfClosed(){if(this.closed)throw new vi}next(e){At(()=>{if(this._throwIfClosed(),!this.isStopped){this.currentObservers||(this.currentObservers=Array.from(this.observers));for(const i of this.currentObservers)i.next(e)}})}error(e){At(()=>{if(this._throwIfClosed(),!this.isStopped){this.hasError=this.isStopped=!0,this.thrownError=e;const{observers:i}=this;for(;i.length;)i.shift().error(e)}})}complete(){At(()=>{if(this._throwIfClosed(),!this.isStopped){this.isStopped=!0;const{observers:e}=this;for(;e.length;)e.shift().complete()}})}unsubscribe(){this.isStopped=this.closed=!0,this.observers=this.currentObservers=null}get observed(){var e;return(null===(e=this.observers)||void 0===e?void 0:e.length)>0}_trySubscribe(e){return this._throwIfClosed(),super._trySubscribe(e)}_subscribe(e){return this._throwIfClosed(),this._checkFinalizedStatuses(e),this._innerSubscribe(e)}_innerSubscribe(e){const{hasError:i,isStopped:r,observers:s}=this;return i||r?Wl:(this.currentObservers=null,s.push(e),new As(()=>{this.currentObservers=null,ff(s,e)}))}_checkFinalizedStatuses(e){const{hasError:i,thrownError:r,isStopped:s}=this;i?e.error(r):s&&e.complete()}asObservable(){const e=new ki;return e.source=this,e}}return n.create=(t,e)=>new ts(t,e),n})();class ts extends Pt{constructor(t,e){super(),this.destination=t,this.source=e}next(t){var e,i;null===(i=null===(e=this.destination)||void 0===e?void 0:e.next)||void 0===i||i.call(e,t)}error(t){var e,i;null===(i=null===(e=this.destination)||void 0===e?void 0:e.error)||void 0===i||i.call(e,t)}complete(){var t,e;null===(e=null===(t=this.destination)||void 0===t?void 0:t.complete)||void 0===e||e.call(t)}_subscribe(t){var e,i;return null!==(i=null===(e=this.source)||void 0===e?void 0:e.subscribe(t))&&void 0!==i?i:Wl}}class _o extends Pt{constructor(t){super(),this._value=t}get value(){return this.getValue()}_subscribe(t){const e=super._subscribe(t);return!e.closed&&t.next(this._value),e}getValue(){const{hasError:t,thrownError:e,_value:i}=this;if(t)throw e;return this._throwIfClosed(),i}next(t){super.next(this._value=t)}}class Ls extends ft{constructor(t,e,i,r,s,o){super(t),this.onFinalize=s,this.shouldUnsubscribe=o,this._next=e?function(a){try{e(a)}catch(l){t.error(l)}}:super._next,this._error=r?function(a){try{r(a)}catch(l){t.error(l)}finally{this.unsubscribe()}}:super._error,this._complete=i?function(){try{i()}catch(a){t.error(a)}finally{this.unsubscribe()}}:super._complete}unsubscribe(){var t;if(!this.shouldUnsubscribe||this.shouldUnsubscribe()){const{closed:e}=this;super.unsubscribe(),!e&&(null===(t=this.onFinalize)||void 0===t||t.call(this))}}}function jr(n,t){return function Ur(n){return t=>{if(function cn(n){return Eo(n?.lift)}(t))return t.lift(function(e){try{return n(e,this)}catch(i){this.error(i)}});throw new TypeError("Unable to lift unknown Observable type")}}((e,i)=>{let r=0;e.subscribe(function Do(n,t,e,i,r){return new Ls(n,t,e,i,r)}(i,s=>{i.next(n.call(t,s,r++))}))})}class F extends Error{constructor(t,e){super(function ae(n,t){return`NG0${Math.abs(n)}${t?": "+t:""}`}(t,e)),this.code=t}}function Xe(n){for(let t in n)if(n[t]===Xe)return t;throw Error("Could not find renamed property on target object.")}function mt(n,t){for(const e in t)t.hasOwnProperty(e)&&!n.hasOwnProperty(e)&&(n[e]=t[e])}function dt(n){if("string"==typeof n)return n;if(Array.isArray(n))return"["+n.map(dt).join(", ")+"]";if(null==n)return""+n;if(n.overriddenName)return`${n.overriddenName}`;if(n.name)return`${n.name}`;const t=n.toString();if(null==t)return""+t;const e=t.indexOf("\n");return-1===e?t:t.substring(0,e)}function qt(n,t){return null==n||""===n?null===t?"":t:null==t||""===t?n:n+" "+t}const ur=Xe({__forward_ref__:Xe});function ir(n){return n.__forward_ref__=ir,n.toString=function(){return dt(this())},n}function vt(n){return function Dn(n){return"function"==typeof n&&n.hasOwnProperty(ur)&&n.__forward_ref__===ir}(n)?n():n}function Ql(n){return n&&!!n.\u0275providers}const Gl=Xe({\u0275cmp:Xe}),qd=Xe({\u0275dir:Xe}),gf=Xe({\u0275pipe:Xe}),Uo=Xe({\u0275fac:Xe}),jo=Xe({__NG_ELEMENT_ID__:Xe}),vf=Xe({__NG_ENV_ID__:Xe});function zi(n){return"function"==typeof n?n.name||n.toString():"object"==typeof n&&null!=n&&"function"==typeof n.type?n.type.name||n.type.toString():function Nt(n){return"string"==typeof n?n:null==n?"":String(n)}(n)}function Tb(n,t){throw new F(-201,!1)}function ro(n,t){null==n&&function zt(n,t,e,i){throw new Error(`ASSERTION ERROR: ${n}`+(null==i?"":` [Expected=> ${e} ${i} ${t} <=Actual]`))}(t,n,null,"!=")}function Yi(n){return{token:n.token,providedIn:n.providedIn||null,factory:n.factory,value:void 0}}function mf(n){return{providers:n.providers||[],imports:n.imports||[]}}function wm(n){return zT(n,Em)||zT(n,RT)}function zT(n,t){return n.hasOwnProperty(t)?n[t]:null}function Cm(n){return n&&(n.hasOwnProperty(Ab)||n.hasOwnProperty(x_))?n[Ab]:null}const Em=Xe({\u0275prov:Xe}),Ab=Xe({\u0275inj:Xe}),RT=Xe({ngInjectableDef:Xe}),x_=Xe({ngInjectorDef:Xe});var Di=function(n){return n[n.Default=0]="Default",n[n.Host=1]="Host",n[n.Self=2]="Self",n[n.SkipSelf=4]="SkipSelf",n[n.Optional=8]="Optional",n}(Di||{});let Lb;function no(n){const t=Lb;return Lb=n,t}function BT(n,t,e){const i=wm(n);return i&&"root"==i.providedIn?void 0===i.value?i.value=i.factory():i.value:e&Di.Optional?null:void 0!==t?t:void Tb()}const rr=globalThis;class Ht{constructor(t,e){this._desc=t,this.ngMetadataName="InjectionToken",this.\u0275prov=void 0,"number"==typeof e?this.__NG_ELEMENT_ID__=e:void 0!==e&&(this.\u0275prov=Yi({token:this,providedIn:e.providedIn||"root",factory:e.factory}))}get multi(){return this}toString(){return`InjectionToken ${this._desc}`}}const yf={},zb="__NG_DI_FLAG__",Dm="ngTempTokenPath",L_=/\n/gm,_T="__source";let Zd;function Qh(n){const t=Zd;return Zd=n,t}function k_(n,t=Di.Default){if(void 0===Zd)throw new F(-203,!1);return null===Zd?BT(n,void 0,t):Zd.get(n,t&Di.Optional?null:void 0,t)}function Fi(n,t=Di.Default){return(function HT(){return Lb}()||k_)(vt(n),t)}function Ri(n,t=Di.Default){return Fi(n,xm(t))}function xm(n){return typeof n>"u"||"number"==typeof n?n:0|(n.optional&&8)|(n.host&&1)|(n.self&&2)|(n.skipSelf&&4)}function Rb(n){const t=[];for(let e=0;et){o=s-1;break}}}for(;ss?"":r[d+1].toLowerCase();const p=8&i?u:null;if(p&&-1!==jT(p,h,0)||2&i&&h!==u){if(ba(i))return!1;o=!0}}}}else{if(!o&&!ba(i)&&!ba(l))return!1;if(o&&ba(l))continue;o=!1,i=l|1&i}}return ba(i)||o}function ba(n){return 0==(1&n)}function __(n,t,e,i){if(null===t)return-1;let r=0;if(i||!e){let s=!1;for(;r-1)for(e++;e0?'="'+a+'"':"")+"]"}else 8&i?r+="."+o:4&i&&(r+=" "+o);else""!==r&&!ba(o)&&(t+=qT(s,r),r=""),i=o,s=s||!ba(i);e++}return""!==r&&(t+=qT(s,r)),t}function Bb(n){return Xl(()=>{const t=ZT(n),e={...t,decls:n.decls,vars:n.vars,template:n.template,consts:n.consts||null,ngContentSelectors:n.ngContentSelectors,onPush:n.changeDetection===Tm.OnPush,directiveDefs:null,pipeDefs:null,dependencies:t.standalone&&n.dependencies||null,getStandaloneInjector:null,signals:n.signals??!1,data:n.data||{},encapsulation:n.encapsulation||Ia.Emulated,styles:n.styles||Qi,_:null,schemas:n.schemas||null,tView:null,id:""};JT(e);const i=n.dependencies;return e.directiveDefs=Lm(i,!1),e.pipeDefs=Lm(i,!0),e.id=function Z_(n){let t=0;const e=[n.selectors,n.ngContentSelectors,n.hostVars,n.hostAttrs,n.consts,n.vars,n.decls,n.encapsulation,n.standalone,n.signals,n.exportAs,JSON.stringify(n.inputs),JSON.stringify(n.outputs),Object.getOwnPropertyNames(n.type.prototype),!!n.contentQueries,!!n.viewQuery].join("|");for(const r of e)t=Math.imul(31,t)+r.charCodeAt(0)<<0;return t+=2147483648,"c"+t}(e),e})}function X_(n){return ci(n)||jn(n)}function q_(n){return null!==n}function Am(n){return Xl(()=>({type:n.type,bootstrap:n.bootstrap||Qi,declarations:n.declarations||Qi,imports:n.imports||Qi,exports:n.exports||Qi,transitiveCompileScopes:null,schemas:n.schemas||null,id:n.id||null}))}function $T(n,t){if(null==n)return tl;const e={};for(const i in n)if(n.hasOwnProperty(i)){const r=n[i];let s,o,a=Gh.None;Array.isArray(r)?(a=r[0],s=r[1],o=r[2]??s):(s=r,o=r),t?(e[s]=a!==Gh.None?[i,a]:i,t[s]=o):e[s]=i}return e}function nr(n){return Xl(()=>{const t=ZT(n);return JT(t),t})}function ci(n){return n[Gl]||null}function jn(n){return n[qd]||null}function gs(n){return n[gf]||null}function ZT(n){const t={};return{type:n.type,providersResolver:null,factory:null,hostBindings:n.hostBindings||null,hostVars:n.hostVars||0,hostAttrs:n.hostAttrs||null,contentQueries:n.contentQueries||null,declaredInputs:t,inputTransforms:null,inputConfig:n.inputs||tl,exportAs:n.exportAs||null,standalone:!0===n.standalone,signals:!0===n.signals,selectors:n.selectors||Qi,viewQuery:n.viewQuery||null,features:n.features||null,setInput:null,findHostDirectiveDefs:null,hostDirectives:null,inputs:$T(n.inputs,t),outputs:$T(n.outputs),debugInfo:null}}function JT(n){n.features?.forEach(t=>t(n))}function Lm(n,t){if(!n)return null;const e=t?gs:X_;return()=>("function"==typeof n?n():n).map(i=>e(i)).filter(q_)}const Vr=0,Be=1,Ct=2,vn=3,Ma=4,Os=5,wa=6,Jd=7,Er=8,Xs=9,ql=10,Yt=11,bf=12,KT=13,Kd=14,Jr=15,Mf=16,eu=17,il=18,wf=19,eA=20,Xh=21,Nm=22,Uc=23,Ut=25,Fb=1,rl=7,tu=9,mn=10;var _b=function(n){return n[n.None=0]="None",n[n.HasTransplantedViews=2]="HasTransplantedViews",n}(_b||{});function ks(n){return Array.isArray(n)&&"object"==typeof n[Fb]}function Ps(n){return Array.isArray(n)&&!0===n[Fb]}function Ub(n){return 0!=(4&n.flags)}function jc(n){return n.componentOffset>-1}function km(n){return 1==(1&n.flags)}function Ca(n){return!!n.template}function jb(n){return 0!=(512&n[Ct])}function Vc(n,t){return n.hasOwnProperty(Uo)?n[Uo]:null}class tU{constructor(t,e,i){this.previousValue=t,this.currentValue=e,this.firstChange=i}isFirstChange(){return this.firstChange}}function nA(n,t,e,i){null!==t?t.applyValueToInputSignal(t,i):n[e]=i}function sA(n){return n.type.prototype.ngOnChanges&&(n.setInput=rU),iU}function iU(){const n=aA(this),t=n?.current;if(t){const e=n.previous;if(e===tl)n.previous=t;else for(let i in t)e[i]=t[i];n.current=null,this.ngOnChanges(t)}}function rU(n,t,e,i,r){const s=this.declaredInputs[i],o=aA(n)||function nU(n,t){return n[oA]=t}(n,{previous:tl,current:null}),a=o.current||(o.current={}),l=o.previous,h=l[s];a[s]=new tU(h&&h.currentValue,e,l===tl),nA(n,t,r,e)}const oA="__ngSimpleChanges__";function aA(n){return n[oA]||null}const nl=function(n,t,e){};let cA=!1;function pr(n){for(;Array.isArray(n);)n=n[Vr];return n}function qs(n,t){return pr(t[n.index])}function Df(n,t){return n.data[t]}function To(n,t){const e=t[n];return ks(e)?e:e[Vr]}function Gb(n){return 128==(128&n[Ct])}function sl(n,t){return null==t?null:n[t]}function dA(n){n[eu]=0}function cU(n){1024&n[Ct]||(n[Ct]|=1024,Gb(n)&&xf(n))}function pA(n){return 9216&n[Ct]||n[Uc]?.dirty}function Xb(n){pA(n)?xf(n):64&n[Ct]&&(function oU(){return cA}()?(n[Ct]|=1024,xf(n)):n[ql].changeDetectionScheduler?.notify())}function xf(n){n[ql].changeDetectionScheduler?.notify();let t=Wc(n);for(;null!==t&&!(8192&t[Ct])&&(t[Ct]|=8192,Gb(t));)t=Wc(t)}function Wc(n){const t=n[vn];return Ps(t)?t[vn]:t}const Rt={lFrame:wA(null),bindingsEnabled:!0,skipHydrationRootTNode:null};function gA(){return Rt.bindingsEnabled}function Se(){return Rt.lFrame.lView}function xi(){return Rt.lFrame.tView}function fr(){let n=vA();for(;null!==n&&64===n.type;)n=n.parent;return n}function vA(){return Rt.lFrame.currentTNode}function ol(n,t){const e=Rt.lFrame;e.currentTNode=n,e.isParent=t}function $b(){return Rt.lFrame.isParent}function wU(n,t){const e=Rt.lFrame;e.bindingIndex=e.bindingRootIndex=n,Jb(t)}function Jb(n){Rt.lFrame.currentDirectiveIndex=n}function IA(){return Rt.lFrame.currentQueryIndex}function e1(n){Rt.lFrame.currentQueryIndex=n}function EU(n){const t=n[Be];return 2===t.type?t.declTNode:1===t.type?n[Os]:null}function bA(n,t,e){if(e&Di.SkipSelf){let r=t,s=n;for(;!(r=r.parent,null!==r||e&Di.Host||(r=EU(s),null===r||(s=s[Kd],10&r.type))););if(null===r)return!1;t=r,n=s}const i=Rt.lFrame=MA();return i.currentTNode=t,i.lView=n,!0}function t1(n){const t=MA(),e=n[Be];Rt.lFrame=t,t.currentTNode=e.firstChild,t.lView=n,t.tView=e,t.contextLView=n,t.bindingIndex=e.bindingStartIndex,t.inI18n=!1}function MA(){const n=Rt.lFrame,t=null===n?null:n.child;return null===t?wA(n):t}function wA(n){const t={currentTNode:null,isParent:!0,lView:null,tView:null,selectedIndex:-1,contextLView:null,elementDepthCount:0,currentNamespace:null,currentDirectiveIndex:-1,bindingRootIndex:-1,bindingIndex:-1,currentQueryIndex:0,parent:n,child:null,inI18n:!1};return null!==n&&(n.child=t),t}function CA(){const n=Rt.lFrame;return Rt.lFrame=n.parent,n.currentTNode=null,n.lView=null,n}const EA=CA;function i1(){const n=CA();n.isParent=!0,n.tView=null,n.selectedIndex=-1,n.contextLView=null,n.elementDepthCount=0,n.currentDirectiveIndex=-1,n.currentNamespace=null,n.bindingRootIndex=-1,n.bindingIndex=-1,n.currentQueryIndex=0}function zs(){return Rt.lFrame.selectedIndex}function Yc(n){Rt.lFrame.selectedIndex=n}let xA=!0;function Rm(){return xA}function qh(n){xA=n}function Hm(n,t){for(let e=t.directiveStart,i=t.directiveEnd;e=i)break}else t[l]<0&&(n[eu]+=65536),(a>14>16&&(3&n[Ct])===t&&(n[Ct]+=16384,AA(a,s)):AA(a,s)}const nu=-1;class Af{constructor(t,e,i){this.factory=t,this.resolving=!1,this.canSeeViewProviders=e,this.injectImpl=i}}function s1(n){return n!==nu}function Lf(n){return 32767&n}function Nf(n,t){let e=function HU(n){return n>>16}(n),i=t;for(;e>0;)i=i[Kd],e--;return i}let o1=!0;function _m(n){const t=o1;return o1=n,t}const LA=255,NA=5;let BU=0;const ll={};function Um(n,t){const e=OA(n,t);if(-1!==e)return e;const i=t[Be];i.firstCreatePass&&(n.injectorIndex=t.length,a1(i.data,n),a1(t,null),a1(i.blueprint,null));const r=jm(n,t),s=n.injectorIndex;if(s1(r)){const o=Lf(r),a=Nf(r,t),l=a[Be].data;for(let h=0;h<8;h++)t[s+h]=a[o+h]|l[o+h]}return t[s+8]=r,s}function a1(n,t){n.push(0,0,0,0,0,0,0,0,t)}function OA(n,t){return-1===n.injectorIndex||n.parent&&n.parent.injectorIndex===n.injectorIndex||null===t[n.injectorIndex+8]?-1:n.injectorIndex}function jm(n,t){if(n.parent&&-1!==n.parent.injectorIndex)return n.parent.injectorIndex;let e=0,i=null,r=t;for(;null!==r;){if(i=FA(r),null===i)return nu;if(e++,r=r[Kd],-1!==i.injectorIndex)return i.injectorIndex|e<<16}return nu}function l1(n,t,e){!function FU(n,t,e){let i;"string"==typeof e?i=e.charCodeAt(0)||0:e.hasOwnProperty(jo)&&(i=e[jo]),null==i&&(i=e[jo]=BU++);const r=i&LA;t.data[n+(r>>NA)]|=1<=0?t&LA:VU:t}(e);if("function"==typeof s){if(!bA(t,n,i))return i&Di.Host?kA(r,0,i):PA(t,e,i,r);try{let o;if(o=s(i),null!=o||i&Di.Optional)return o;Tb()}finally{EA()}}else if("number"==typeof s){let o=null,a=OA(n,t),l=nu,h=i&Di.Host?t[Jr][Os]:null;for((-1===a||i&Di.SkipSelf)&&(l=-1===a?jm(n,t):t[a+8],l!==nu&&BA(i,!1)?(o=t[Be],a=Lf(l),t=Nf(l,t)):a=-1);-1!==a;){const c=t[Be];if(HA(s,a,c.data)){const d=UU(a,t,e,o,i,h);if(d!==ll)return d}l=t[a+8],l!==nu&&BA(i,t[Be].data[a+8]===h)&&HA(s,a,t)?(o=c,a=Lf(l),t=Nf(l,t)):a=-1}}return r}function UU(n,t,e,i,r,s){const o=t[Be],a=o.data[n+8],c=Vm(a,o,e,null==i?jc(a)&&o1:i!=o&&0!=(3&a.type),r&Di.Host&&s===a);return null!==c?Qc(t,o,c,a):ll}function Vm(n,t,e,i,r){const s=n.providerIndexes,o=t.data,a=1048575&s,l=n.directiveStart,c=s>>20,u=r?a+c:n.directiveEnd;for(let p=i?a:a+c;p=l&&f.type===e)return p}if(r){const p=o[l];if(p&&Ca(p)&&p.type===e)return l}return null}function Qc(n,t,e,i){let r=n[e];const s=t.data;if(function kU(n){return n instanceof Af}(r)){const o=r;o.resolving&&function Vo(n,t){const e=t?`. Dependency path: ${t.join(" > ")} > ${n}`:"";throw new F(-200,`Circular dependency in DI detected for ${n}${e}`)}(zi(s[e]));const a=_m(o.canSeeViewProviders);o.resolving=!0;const h=o.injectImpl?no(o.injectImpl):null;bA(n,i,Di.Default);try{r=n[e]=o.factory(void 0,s,n,i),t.firstCreatePass&&e>=i.directiveStart&&function NU(n,t,e){const{ngOnChanges:i,ngOnInit:r,ngDoCheck:s}=t.type.prototype;if(i){const o=sA(t);(e.preOrderHooks??=[]).push(n,o),(e.preOrderCheckHooks??=[]).push(n,o)}r&&(e.preOrderHooks??=[]).push(0-n,r),s&&((e.preOrderHooks??=[]).push(n,s),(e.preOrderCheckHooks??=[]).push(n,s))}(e,s[e],t)}finally{null!==h&&no(h),_m(a),o.resolving=!1,EA()}}return r}function HA(n,t,e){return!!(e[t+(n>>NA)]&1<Array.isArray(e)?uu(e,t):t(e))}function UA(n,t,e){t>=n.length?n.push(e):n.splice(t,0,e)}function Wm(n,t){return t>=n.length-1?n.pop():n.splice(t,1)[0]}const gu=new Ht(""),GA=new Ht("",-1),y1=new Ht("");class Xm{get(t,e=yf){if(e===yf){const i=new Error(`NullInjectorError: No provider for ${dt(t)}!`);throw i.name="NullInjectorError",i}return e}}function pj(...n){return{\u0275providers:XA(0,n),\u0275fromNgModule:!0}}function XA(n,...t){const e=[],i=new Set;let r;const s=o=>{e.push(o)};return uu(t,o=>{const a=o;qm(a,s,[],i)&&(r||=[],r.push(a))}),void 0!==r&&qA(r,s),e}function qA(n,t){for(let e=0;e{t(s,i)})}}function qm(n,t,e,i){if(!(n=vt(n)))return!1;let r=null,s=Cm(n);const o=!s&&ci(n);if(s||o){if(o&&!o.standalone)return!1;r=n}else{const l=n.ngModule;if(s=Cm(l),!s)return!1;r=l}const a=i.has(r);if(o){if(a)return!1;if(i.add(r),o.dependencies){const l="function"==typeof o.dependencies?o.dependencies():o.dependencies;for(const h of l)qm(h,t,e,i)}}else{if(!s)return!1;{if(null!=s.imports&&!a){let h;i.add(r);try{uu(s.imports,c=>{qm(c,t,e,i)&&(h||=[],h.push(c))})}finally{}void 0!==h&&qA(h,t)}if(!a){const h=Vc(r)||(()=>new r);t({provide:r,useFactory:h,deps:Qi},r),t({provide:y1,useValue:r,multi:!0},r),t({provide:gu,useValue:()=>Fi(r),multi:!0},r)}const l=s.providers;if(null!=l&&!a){const h=n;I1(l,c=>{t(c,h)})}}}return r!==n&&void 0!==n.providers}function I1(n,t){for(let e of n)Ql(e)&&(e=e.\u0275providers),Array.isArray(e)?I1(e,t):t(e)}const fj=Xe({provide:String,useValue:Xe});function b1(n){return null!==n&&"object"==typeof n&&fj in n}function Gc(n){return"function"==typeof n}const M1=new Ht(""),$m={},vj={};let w1;function Zm(){return void 0===w1&&(w1=new Xm),w1}class Jl{}class vu extends Jl{get destroyed(){return this._destroyed}constructor(t,e,i,r){super(),this.parent=e,this.source=i,this.scopes=r,this.records=new Map,this._ngOnDestroyHooks=new Set,this._onDestroyHooks=[],this._destroyed=!1,E1(t,o=>this.processProvider(o)),this.records.set(GA,mu(void 0,this)),r.has("environment")&&this.records.set(Jl,mu(void 0,this));const s=this.records.get(M1);null!=s&&"string"==typeof s.value&&this.scopes.add(s.value),this.injectorDefTypes=new Set(this.get(y1,Qi,Di.Self))}destroy(){this.assertNotDestroyed(),this._destroyed=!0;try{for(const e of this._ngOnDestroyHooks)e.ngOnDestroy();const t=this._onDestroyHooks;this._onDestroyHooks=[];for(const e of t)e()}finally{this.records.clear(),this._ngOnDestroyHooks.clear(),this.injectorDefTypes.clear()}}onDestroy(t){return this.assertNotDestroyed(),this._onDestroyHooks.push(t),()=>this.removeOnDestroy(t)}runInContext(t){this.assertNotDestroyed();const e=Qh(this),i=no(void 0);try{return t()}finally{Qh(e),no(i)}}get(t,e=yf,i=Di.Default){if(this.assertNotDestroyed(),t.hasOwnProperty(vf))return t[vf](this);i=xm(i);const s=Qh(this),o=no(void 0);try{if(!(i&Di.SkipSelf)){let l=this.records.get(t);if(void 0===l){const h=function bj(n){return"function"==typeof n||"object"==typeof n&&n instanceof Ht}(t)&&wm(t);l=h&&this.injectableDefInScope(h)?mu(C1(t),$m):null,this.records.set(t,l)}if(null!=l)return this.hydrate(t,l)}return(i&Di.Self?Zm():this.parent).get(t,e=i&Di.Optional&&e===yf?null:e)}catch(a){if("NullInjectorError"===a.name){if((a[Dm]=a[Dm]||[]).unshift(dt(t)),s)throw a;return function z_(n,t,e,i){const r=n[Dm];throw t[_T]&&r.unshift(t[_T]),n.message=function R_(n,t,e,i=null){n=n&&"\n"===n.charAt(0)&&"\u0275"==n.charAt(1)?n.slice(2):n;let r=dt(t);if(Array.isArray(t))r=t.map(dt).join(" -> ");else if("object"==typeof t){let s=[];for(let o in t)if(t.hasOwnProperty(o)){let a=t[o];s.push(o+":"+("string"==typeof a?JSON.stringify(a):dt(a)))}r=`{${s.join(", ")}}`}return`${e}${i?"("+i+")":""}[${r}]: ${n.replace(L_,"\n ")}`}("\n"+n.message,r,e,i),n.ngTokenPath=r,n[Dm]=null,n}(a,t,"R3InjectorError",this.source)}throw a}finally{no(o),Qh(s)}}resolveInjectorInitializers(){const t=Qh(this),e=no(void 0);try{const r=this.get(gu,Qi,Di.Self);for(const s of r)s()}finally{Qh(t),no(e)}}toString(){const t=[],e=this.records;for(const i of e.keys())t.push(dt(i));return`R3Injector[${t.join(", ")}]`}assertNotDestroyed(){if(this._destroyed)throw new F(205,!1)}processProvider(t){let e=Gc(t=vt(t))?t:vt(t&&t.provide);const i=function yj(n){return b1(n)?mu(void 0,n.useValue):mu(JA(n),$m)}(t);if(!Gc(t)&&!0===t.multi){let r=this.records.get(e);r||(r=mu(void 0,$m,!0),r.factory=()=>Rb(r.multi),this.records.set(e,r)),e=t,r.multi.push(t)}this.records.set(e,i)}hydrate(t,e){return e.value===$m&&(e.value=vj,e.value=e.factory()),"object"==typeof e.value&&e.value&&function Ij(n){return null!==n&&"object"==typeof n&&"function"==typeof n.ngOnDestroy}(e.value)&&this._ngOnDestroyHooks.add(e.value),e.value}injectableDefInScope(t){if(!t.providedIn)return!1;const e=vt(t.providedIn);return"string"==typeof e?"any"===e||this.scopes.has(e):this.injectorDefTypes.has(e)}removeOnDestroy(t){const e=this._onDestroyHooks.indexOf(t);-1!==e&&this._onDestroyHooks.splice(e,1)}}function C1(n){const t=wm(n),e=null!==t?t.factory:Vc(n);if(null!==e)return e;if(n instanceof Ht)throw new F(204,!1);if(n instanceof Function)return function mj(n){if(n.length>0)throw new F(204,!1);const e=function D_(n){return n&&(n[Em]||n[RT])||null}(n);return null!==e?()=>e.factory(n):()=>new n}(n);throw new F(204,!1)}function JA(n,t,e){let i;if(Gc(n)){const r=vt(n);return Vc(r)||C1(r)}if(b1(n))i=()=>vt(n.useValue);else if(function ZA(n){return!(!n||!n.useFactory)}(n))i=()=>n.useFactory(...Rb(n.deps||[]));else if(function $A(n){return!(!n||!n.useExisting)}(n))i=()=>Fi(vt(n.useExisting));else{const r=vt(n&&(n.useClass||n.provide));if(!function Sj(n){return!!n.deps}(n))return Vc(r)||C1(r);i=()=>new r(...Rb(n.deps))}return i}function mu(n,t,e=!1){return{factory:n,value:t,multi:e?[]:void 0}}function E1(n,t){for(const e of n)Array.isArray(e)?E1(e,t):e&&Ql(e)?E1(e.\u0275providers,t):t(e)}function iL(n,t=null,e=null,i){const r=function rL(n,t=null,e=null,i,r=new Set){const s=[e||Qi,pj(n)];return i=i||("object"==typeof n?void 0:dt(n)),new vu(s,t||Zm(),i||null,r)}(n,t,e,i);return r.resolveInjectorInitializers(),r}let T1,Wo=(()=>{class n{static{this.THROW_IF_NOT_FOUND=yf}static{this.NULL=new Xm}static create(e,i){if(Array.isArray(e))return iL({name:""},i,e,"");{const r=e.name??"";return iL({name:r},e.parent,e.providers,r)}}static{this.\u0275prov=Yi({token:n,providedIn:"any",factory:()=>Fi(GA)})}static{this.__NG_ELEMENT_ID__=-1}}return n})();const A1=new Ht("",{providedIn:"root",factory:()=>Lj}),Lj="ng",sL=new Ht(""),yu=new Ht("",{providedIn:"platform",factory:()=>"unknown"}),oL=new Ht("",{providedIn:"root",factory:()=>function $h(){if(void 0!==T1)return T1;if(typeof document<"u")return document;throw new F(210,!1)}().body?.querySelector("[ngCspNonce]")?.getAttribute("ngCspNonce")||null});function iy(n){return 128==(128&n.flags)}var Kh=function(n){return n[n.Important=1]="Important",n[n.DashCase=2]="DashCase",n}(Kh||{});const P1=new Map;let Vj=0;const R1="__ngContext__";function Rs(n,t){ks(t)?(n[R1]=t[wf],function Yj(n){P1.set(n[wf],n)}(t)):n[R1]=t}let H1;function B1(n,t){return H1(n,t)}function Iu(n,t,e,i,r){if(null!=i){let s,o=!1;Ps(i)?s=i:ks(i)&&(o=!0,i=i[Vr]);const a=pr(i);0===n&&null!==e?null==r?TL(t,e,a):qc(t,e,a,r||null,!0):1===n&&null!==e?qc(t,e,a,r||null,!0):2===n?function hy(n,t,e){const i=ay(n,t);i&&function a6(n,t,e,i){n.removeChild(t,e,i)}(n,i,t,e)}(t,a,o):3===n&&t.destroyNode(a),null!=s&&function c6(n,t,e,i,r){const s=e[rl];s!==pr(e)&&Iu(t,n,i,s,r);for(let a=mn;a0&&(n[e-1][Ma]=i[Ma]);const s=Wm(n,mn+t);!function e6(n,t){EL(n,t),t[Vr]=null,t[Os]=null}(i[Be],i);const o=s[il];null!==o&&o.detachView(s[Be]),i[vn]=null,i[Ma]=null,i[Ct]&=-129}return i}function oy(n,t){if(!(256&t[Ct])){const e=t[Yt];e.destroyNode&&cy(n,t,e,3,null,null),function i6(n){let t=n[bf];if(!t)return _1(n[Be],n);for(;t;){let e=null;if(ks(t))e=t[bf];else{const i=t[mn];i&&(e=i)}if(!e){for(;t&&!t[Ma]&&t!==n;)ks(t)&&_1(t[Be],t),t=t[vn];null===t&&(t=n),ks(t)&&_1(t[Be],t),e=t&&t[Ma]}t=e}}(t)}}function _1(n,t){if(!(256&t[Ct])){t[Ct]&=-129,t[Ct]|=256,t[Uc]&&function Yd(n){if(Vl(n),Vh(n))for(let t=0;t=0?i[o]():i[-o].unsubscribe(),s+=2}else e[s].call(i[e[s+1]]);null!==i&&(t[Jd]=null);const r=t[Xh];if(null!==r){t[Xh]=null;for(let s=0;s-1){const{encapsulation:s}=n.data[i.directiveStart+r];if(s===Ia.None||s===Ia.Emulated)return null}return qs(i,e)}}(n,t.parent,e)}function qc(n,t,e,i,r){n.insertBefore(t,e,i,r)}function TL(n,t,e){n.appendChild(t,e)}function AL(n,t,e,i,r){null!==i?qc(n,t,e,i,r):TL(n,t,e)}function ay(n,t){return n.parentNode(t)}let j1,OL=function NL(n,t,e){return 40&n.type?qs(n,e):null};function ly(n,t,e,i){const r=U1(n,i,t),s=t[Yt],a=function LL(n,t,e){return OL(n,t,e)}(i.parent||t[Os],i,t);if(null!=r)if(Array.isArray(e))for(let l=0;lnull;function nM(n,t,e=!1){return JL(n,t,e)}class G6{}class rN{}class q6{resolveComponentFactory(t){throw function X6(n){const t=Error(`No component factory found for ${dt(n)}.`);return t.ngComponent=n,t}(t)}}let Sy=(()=>{class n{static{this.NULL=new q6}}return n})();function $6(){return Du(fr(),Se())}function Du(n,t){return new $c(qs(n,t))}let $c=(()=>{class n{constructor(e){this.nativeElement=e}static{this.__NG_ELEMENT_ID__=$6}}return n})();function Z6(n){return n instanceof $c?n.nativeElement:n}class sN{}let lM=(()=>{class n{constructor(){this.destroyNode=null}static{this.__NG_ELEMENT_ID__=()=>function J6(){const n=Se(),e=To(fr().index,n);return(ks(e)?e:n)[Yt]}()}}return n})(),K6=(()=>{class n{static{this.\u0275prov=Yi({token:n,providedIn:"root",factory:()=>null})}}return n})();const hM={};function Qf(n,t,e,i,r=!1){for(;null!==e;){const s=t[e.index];null!==s&&i.push(pr(s)),Ps(s)&&pN(s,i);const o=e.type;if(8&o)Qf(n,t,e.child,i);else if(32&o){const a=B1(e,t);let l;for(;l=a();)i.push(l)}else if(16&o){const a=PL(t,e);if(Array.isArray(a))i.push(...a);else{const l=Wc(t[Jr]);Qf(l[Be],l,a,i,!0)}}e=r?e.projectionNext:e.next}return i}function pN(n,t){for(let e=mn;e!1,producerRecomputeValue:()=>{},consumerMarkedDirty:()=>{},consumerOnSignalRead:()=>{},consumerIsAlwaysLive:!0,consumerMarkedDirty:n=>{xf(n.lView)},consumerOnSignalRead(){this.lView[Uc]=this}};function gN(n){return mN(n[bf])}function vN(n){return mN(n[Ma])}function mN(n){for(;null!==n&&!Ps(n);)n=n[Ma];return n}function uM(n){return n.ngOriginalError}class eh{constructor(){this._console=console}handleError(t){const e=this._findOriginalError(t);this._console.error("ERROR",t),e&&this._console.error("ORIGINAL ERROR",e)}_findOriginalError(t){let e=t&&uM(t);for(;e&&uM(e);)e=uM(e);return e||null}}const SN=new Ht("",{providedIn:"root",factory:()=>Ri(eh).handleError.bind(void 0)}),bN=new Ht("",{providedIn:"root",factory:()=>!1}),Qt={};function pM(n=1){EN(xi(),Se(),zs()+n,!1)}function EN(n,t,e,i){if(!i)if(3==(3&t[Ct])){const s=n.preOrderCheckHooks;null!==s&&Bm(t,s,e)}else{const s=n.preOrderHooks;null!==s&&Fm(t,s,0,e)}Yc(e)}function Ot(n,t=Di.Default){const e=Se();return null===e?Fi(n,t):zA(fr(),e,vt(n),t)}function DN(n,t,e,i,r,s){const o=Wi(null);try{let a=null;r&Gh.SignalBased&&(a=t[i][Ts]),null!==a&&void 0!==a.transformFn&&(s=a.transformFn(s)),r&Gh.HasDecoratorInputTransform&&(s=n.inputTransforms[i].call(t,s)),null!==n.setInput?n.setInput(t,a,s,e,i):nA(t,a,i,s)}finally{Wi(o)}}function wy(n,t,e,i,r,s,o,a,l,h,c){const d=t.blueprint.slice();return d[Vr]=r,d[Ct]=204|i,(null!==h||n&&2048&n[Ct])&&(d[Ct]|=2048),dA(d),d[vn]=d[Kd]=n,d[Er]=e,d[ql]=o||n&&n[ql],d[Yt]=a||n&&n[Yt],d[Xs]=l||n&&n[Xs]||null,d[Os]=s,d[wf]=function Wj(){return Vj++}(),d[wa]=c,d[eA]=h,d[Jr]=2==t.type?n[Jr]:d,d}function xu(n,t,e,i,r){let s=n.data[t];if(null===s)s=function fM(n,t,e,i,r){const s=vA(),o=$b(),l=n.data[t]=function LV(n,t,e,i,r,s){let o=t?t.injectorIndex:-1,a=0;return function ru(){return null!==Rt.skipHydrationRootTNode}()&&(a|=128),{type:e,index:i,insertBeforeIndex:null,injectorIndex:o,directiveStart:-1,directiveEnd:-1,directiveStylingLast:-1,componentOffset:-1,propertyBindings:null,flags:a,providerIndexes:0,value:r,attrs:s,mergedAttrs:null,localNames:null,initialInputs:void 0,inputs:null,outputs:null,tView:null,next:null,prev:null,projectionNext:null,child:null,parent:t,projection:null,styles:null,stylesWithoutHost:null,residualStyles:void 0,classes:null,classesWithoutHost:null,residualClasses:void 0,classBindings:0,styleBindings:0}}(0,o?s:s&&s.parent,e,t,i,r);return null===n.firstChild&&(n.firstChild=l),null!==s&&(o?null==s.child&&null!==l.parent&&(s.child=l):null===s.next&&(s.next=l,l.prev=s)),l}(n,t,e,i,r),function MU(){return Rt.lFrame.inI18n}()&&(s.flags|=32);else if(64&s.type){s.type=e,s.value=i,s.attrs=r;const o=function Tf(){const n=Rt.lFrame,t=n.currentTNode;return n.isParent?t:t.parent}();s.injectorIndex=null===o?-1:o.injectorIndex}return ol(s,!0),s}function Gf(n,t,e,i){if(0===e)return-1;const r=t.length;for(let s=0;sUt&&EN(n,t,Ut,!1),nl(o?2:0,r),e(i,r)}finally{Yc(s),nl(o?3:1,r)}}function gM(n,t,e){if(Ub(t)){const i=Wi(null);try{const s=t.directiveEnd;for(let o=t.directiveStart;onull;function LN(n,t,e,i,r){for(let s in t){if(!t.hasOwnProperty(s))continue;const o=t[s];if(void 0===o)continue;i??={};let a,l=Gh.None;Array.isArray(o)?(a=o[0],l=o[1]):a=o;let h=s;if(null!==r){if(!r.hasOwnProperty(s))continue;h=r[s]}0===n?NN(i,e,h,a,l):NN(i,e,h,a)}return i}function NN(n,t,e,i,r){let s;n.hasOwnProperty(e)?(s=n[e]).push(t,i):s=n[e]=[t,i],void 0!==r&&s.push(r)}function ON(n,t,e,i,r,s){for(let h=0;h0;){const e=n[--t];if("number"==typeof e&&e<0)return e}return 0})(o)!=a&&o.push(a),o.push(e,i,s)}}(n,t,i,Gf(n,e,r.hostVars,Qt),r)}function YV(n,t,e,i,r,s){const o=s[t];if(null!==o)for(let a=0;an.nextProducerIndex;)n.producerNode.pop(),n.producerLastReadVersion.pop(),n.producerIndexOfThis.pop()}}(a,o),function pV(n){n.lView[Uc]!==n&&(n.lView=null,fN.push(n))}(a)),i1()}}function FN(n,t){for(let e=gN(n);null!==e;e=vN(e))for(let i=mn;i-1&&(Bf(t,i),Wm(e,i))}this._attachedToViewContainer=!1}oy(this._lView[Be],this._lView)}onDestroy(t){!function zm(n,t){if(256==(256&n[Ct]))throw new F(911,!1);null===n[Xh]&&(n[Xh]=[]),n[Xh].push(t)}(this._lView,t)}markForCheck(){Xf(this._cdRefInjectingView||this._lView)}detach(){this._lView[Ct]&=-129}reattach(){Xb(this._lView),this._lView[Ct]|=128}detectChanges(){this._lView[Ct]|=1024,function CM(n,t=!0){const e=n[ql],i=e.rendererFactory;i.begin?.();try{!function XV(n){EM(n,0);let t=0;for(;pA(n);){if(100===t)throw new F(103,!1);t++,EM(n,1)}}(n)}catch(s){throw t&&Ey(n,s),s}finally{i.end?.(),e.inlineEffectRunner?.flush()}}(this._lView,this.notifyErrorHandler)}checkNoChanges(){}attachToViewContainerRef(){if(this._appRef)throw new F(902,!1);this._attachedToViewContainer=!0}detachFromAppRef(){this._appRef=null,EL(this._lView[Be],this._lView)}attachToAppRef(t){if(this._attachedToViewContainer)throw new F(902,!1);this._appRef=t,Xb(this._lView)}}const VN=new Set;function xM(n){return t=>{setTimeout(n,void 0,t)}}const Yo=class h7 extends Pt{constructor(t=!1){super(),this.__isAsync=t}emit(t){super.next(t)}subscribe(t,e,i){let r=t,s=e||(()=>null),o=i;if(t&&"object"==typeof t){const l=t;r=l.next?.bind(l),s=l.error?.bind(l),o=l.complete?.bind(l)}this.__isAsync&&(s=xM(s),r&&(r=xM(r)),o&&(o=xM(o)));const a=super.subscribe({next:r,error:s,complete:o});return t instanceof As&&t.add(a),a}};function WN(...n){}class zr{constructor({enableLongStackTrace:t=!1,shouldCoalesceEventChangeDetection:e=!1,shouldCoalesceRunChangeDetection:i=!1}){if(this.hasPendingMacrotasks=!1,this.hasPendingMicrotasks=!1,this.isStable=!0,this.onUnstable=new Yo(!1),this.onMicrotaskEmpty=new Yo(!1),this.onStable=new Yo(!1),this.onError=new Yo(!1),typeof Zone>"u")throw new F(908,!1);Zone.assertZonePatched();const r=this;r._nesting=0,r._outer=r._inner=Zone.current,Zone.TaskTrackingZoneSpec&&(r._inner=r._inner.fork(new Zone.TaskTrackingZoneSpec)),t&&Zone.longStackTraceZoneSpec&&(r._inner=r._inner.fork(Zone.longStackTraceZoneSpec)),r.shouldCoalesceEventChangeDetection=!i&&e,r.shouldCoalesceRunChangeDetection=i,r.lastRequestAnimationFrameId=-1,r.nativeRequestAnimationFrame=function c7(){const n="function"==typeof rr.requestAnimationFrame;let t=rr[n?"requestAnimationFrame":"setTimeout"],e=rr[n?"cancelAnimationFrame":"clearTimeout"];if(typeof Zone<"u"&&t&&e){const i=t[Zone.__symbol__("OriginalDelegate")];i&&(t=i);const r=e[Zone.__symbol__("OriginalDelegate")];r&&(e=r)}return{nativeRequestAnimationFrame:t,nativeCancelAnimationFrame:e}}().nativeRequestAnimationFrame,function p7(n){const t=()=>{!function u7(n){n.isCheckStableRunning||-1!==n.lastRequestAnimationFrameId||(n.lastRequestAnimationFrameId=n.nativeRequestAnimationFrame.call(rr,()=>{n.fakeTopEventTask||(n.fakeTopEventTask=Zone.root.scheduleEventTask("fakeTopEventTask",()=>{n.lastRequestAnimationFrameId=-1,AM(n),n.isCheckStableRunning=!0,TM(n),n.isCheckStableRunning=!1},void 0,()=>{},()=>{})),n.fakeTopEventTask.invoke()}),AM(n))}(n)};n._inner=n._inner.fork({name:"angular",properties:{isAngularZone:!0},onInvokeTask:(e,i,r,s,o,a)=>{if(function f7(n){return!(!Array.isArray(n)||1!==n.length)&&!0===n[0].data?.__ignore_ng_zone__}(a))return e.invokeTask(r,s,o,a);try{return YN(n),e.invokeTask(r,s,o,a)}finally{(n.shouldCoalesceEventChangeDetection&&"eventTask"===s.type||n.shouldCoalesceRunChangeDetection)&&t(),QN(n)}},onInvoke:(e,i,r,s,o,a,l)=>{try{return YN(n),e.invoke(r,s,o,a,l)}finally{n.shouldCoalesceRunChangeDetection&&t(),QN(n)}},onHasTask:(e,i,r,s)=>{e.hasTask(r,s),i===r&&("microTask"==s.change?(n._hasPendingMicrotasks=s.microTask,AM(n),TM(n)):"macroTask"==s.change&&(n.hasPendingMacrotasks=s.macroTask))},onHandleError:(e,i,r,s)=>(e.handleError(r,s),n.runOutsideAngular(()=>n.onError.emit(s)),!1)})}(r)}static isInAngularZone(){return typeof Zone<"u"&&!0===Zone.current.get("isAngularZone")}static assertInAngularZone(){if(!zr.isInAngularZone())throw new F(909,!1)}static assertNotInAngularZone(){if(zr.isInAngularZone())throw new F(909,!1)}run(t,e,i){return this._inner.run(t,e,i)}runTask(t,e,i,r){const s=this._inner,o=s.scheduleEventTask("NgZoneEvent: "+r,t,d7,WN,WN);try{return s.runTask(o,e,i)}finally{s.cancelTask(o)}}runGuarded(t,e,i){return this._inner.runGuarded(t,e,i)}runOutsideAngular(t){return this._outer.run(t)}}const d7={};function TM(n){if(0==n._nesting&&!n.hasPendingMicrotasks&&!n.isStable)try{n._nesting++,n.onMicrotaskEmpty.emit(null)}finally{if(n._nesting--,!n.hasPendingMicrotasks)try{n.runOutsideAngular(()=>n.onStable.emit(null))}finally{n.isStable=!0}}}function AM(n){n.hasPendingMicrotasks=!!(n._hasPendingMicrotasks||(n.shouldCoalesceEventChangeDetection||n.shouldCoalesceRunChangeDetection)&&-1!==n.lastRequestAnimationFrameId)}function YN(n){n._nesting++,n.isStable&&(n.isStable=!1,n.onUnstable.emit(null))}function QN(n){n._nesting--,TM(n)}let $f=(()=>{class n{constructor(){this.handler=null,this.internalCallbacks=[]}execute(){const e=[...this.internalCallbacks];this.internalCallbacks.length=0;for(const r of e)r();return!!this.handler?.execute()||e.length>0}ngOnDestroy(){this.handler?.destroy(),this.handler=null,this.internalCallbacks.length=0}static{this.\u0275prov=Yi({token:n,providedIn:"root",factory:()=>new n})}}return n})();function y7(n,t){const e=To(t,n),i=e[Be];!function S7(n,t){for(let e=t.length;e0&&HL(n,e,s.join(" "))}}(u,w,f,i),void 0!==e&&function A7(n,t,e){const i=n.projection=[];for(let r=0;r=0;i--){const r=n[i];r.hostVars=t+=r.hostVars,r.hostAttrs=If(r.hostAttrs,e=If(e,r.hostAttrs))}}(i)}function N7(n,t){for(const e in t.inputs){if(!t.inputs.hasOwnProperty(e)||n.inputs.hasOwnProperty(e))continue;const i=t.inputs[e];if(void 0!==i&&(n.inputs[e]=i,n.declaredInputs[e]=t.declaredInputs[e],null!==t.inputTransforms)){const r=Array.isArray(i)?i[0]:i;if(!t.inputTransforms.hasOwnProperty(r))continue;n.inputTransforms??={},n.inputTransforms[r]=t.inputTransforms[r]}}}function xy(n){return n===tl?{}:n===Qi?[]:n}function k7(n,t){const e=n.viewQuery;n.viewQuery=e?(i,r)=>{t(i,r),e(i,r)}:t}function P7(n,t){const e=n.contentQueries;n.contentQueries=e?(i,r,s)=>{t(i,r,s),e(i,r,s)}:t}function z7(n,t){const e=n.hostBindings;n.hostBindings=e?(i,r)=>{t(i,r),e(i,r)}:t}function Au(n,t){return!t||null===t.firstChild||iy(n)}function rg(n,t,e,i=!0){const r=t[Be];if(function r6(n,t,e,i){const r=mn+i,s=e.length;i>0&&(e[r-1][Ma]=t),i{class n{static{this.__NG_ELEMENT_ID__=h9}}return n})();function h9(){return pO(fr(),Se())}const c9=xn,dO=class extends c9{constructor(t,e,i){super(),this._lContainer=t,this._hostTNode=e,this._hostLView=i}get element(){return Du(this._hostTNode,this._hostLView)}get injector(){return new Vn(this._hostTNode,this._hostLView)}get parentInjector(){const t=jm(this._hostTNode,this._hostLView);if(s1(t)){const e=Nf(t,this._hostLView),i=Lf(t);return new Vn(e[Be].data[i+8],e)}return new Vn(null,this._hostLView)}clear(){for(;this.length>0;)this.remove(this.length-1)}get(t){const e=uO(this._lContainer);return null!==e&&e[t]||null}get length(){return this._lContainer.length-mn}createEmbeddedView(t,e,i){let r,s;"number"==typeof i?r=i:null!=i&&(r=i.index,s=i.injector);const a=t.createEmbeddedViewImpl(e||{},s,null);return this.insertImpl(a,r,Au(this._hostTNode,null)),a}createComponent(t,e,i,r,s){const o=t&&!function Of(n){return"function"==typeof n}(t);let a;if(o)a=e;else{const f=e||{};a=f.index,i=f.injector,r=f.projectableNodes,s=f.environmentInjector||f.ngModuleRef}const l=o?t:new Zf(ci(t)),h=i||this.parentInjector;if(!s&&null==l.ngModule){const g=(o?h:this.parentInjector).get(Jl,null);g&&(s=g)}ci(l.componentType??{});const p=l.create(h,r,null,s);return this.insertImpl(p.hostView,a,Au(this._hostTNode,null)),p}insert(t,e){return this.insertImpl(t,e,!0)}insertImpl(t,e,i){const r=t._lView;if(function hU(n){return Ps(n[vn])}(r)){const a=this.indexOf(t);if(-1!==a)this.detach(a);else{const l=r[vn],h=new dO(l,l[Os],l[vn]);h.detach(h.indexOf(t))}}const s=this._adjustIndex(e),o=this._lContainer;return rg(o,r,s,i),t.attachToViewContainerRef(),UA(HM(o),s,t),t}move(t,e){return this.insert(t,e)}indexOf(t){const e=uO(this._lContainer);return null!==e?e.indexOf(t):-1}remove(t){const e=this._adjustIndex(t,-1),i=Bf(this._lContainer,e);i&&(Wm(HM(this._lContainer),e),oy(i[Be],i))}detach(t){const e=this._adjustIndex(t,-1),i=Bf(this._lContainer,e);return i&&null!=Wm(HM(this._lContainer),e)?new qf(i):null}_adjustIndex(t,e=0){return t??this.length+e}};function uO(n){return n[8]}function HM(n){return n[8]||(n[8]=[])}function pO(n,t){let e;const i=t[n.index];return Ps(i)?e=i:(e=function PN(n,t,e,i){return[n,!0,0,t,null,i,null,e,null,null]}(i,t,null,n),t[n.index]=e,Cy(t,e)),fO(e,t,n,i),new dO(e,n,t)}let fO=function vO(n,t,e,i){if(n[rl])return;let r;r=8&e.type?pr(i):function d9(n,t){const e=n[Yt],i=e.createComment(""),r=qs(t,n);return qc(e,ay(e,r),i,function l6(n,t){return n.nextSibling(t)}(e,r),!1),i}(t,e),n[rl]=r};function Fy(n,t,e){const i=Se();return function Tn(n,t,e){return!Object.is(n[t],e)&&(n[t]=e,!0)}(i,function al(){return Rt.lFrame.bindingIndex++}(),t)&&function No(n,t,e,i,r,s,o,a){const l=qs(t,e);let c,h=t.inputs;!a&&null!=h&&(c=h[i])?(wM(n,e,c,i,r),jc(t)&&function kV(n,t){const e=To(t,n);16&e[Ct]||(e[Ct]|=64)}(e,t.index)):3&t.type&&(i=function OV(n){return"class"===n?"className":"for"===n?"htmlFor":"formaction"===n?"formAction":"innerHtml"===n?"innerHTML":"readonly"===n?"readOnly":"tabindex"===n?"tabIndex":n}(i),r=null!=o?o(r,t.value||"",i):r,s.setProperty(l,i,r))}(xi(),function Pr(){const n=Rt.lFrame;return Df(n.tView,n.selectedIndex)}(),i,n,t,i[Yt],e,!1),Fy}function $M(n,t,e,i,r){const o=r?"class":"style";wM(n,e,t.inputs[o],o,i)}function Qu(n,t,e,i){const r=Se(),s=xi(),o=Ut+n,a=r[Yt],l=s.firstCreatePass?function B8(n,t,e,i,r,s){const o=t.consts,l=xu(t,n,2,i,sl(o,r));return function SM(n,t,e,i){if(gA()){const r=null===i?null:{"":-1},s=function FV(n,t){const e=n.directiveRegistry;let i=null,r=null;if(e)for(let s=0;s(qh(!0),sy(i,r,function DA(){return Rt.lFrame.currentNamespace}()));const qu="en-US";let Mk=qu;function ow(n){return!!n&&"function"==typeof n.then}function Gk(n){return!!n&&"function"==typeof n.subscribe}function aw(n,t,e,i){const r=Se(),s=xi(),o=fr();return function qk(n,t,e,i,r,s,o){const a=km(i),h=n.firstCreatePass&&HN(n),c=t[Er],d=RN(t);let u=!0;if(3&i.type||o){const g=qs(i,t),v=o?o(g):g,y=d.length,S=o?M=>o(pr(M[i.index])):i.index;let b=null;if(!o&&a&&(b=function UW(n,t,e,i){const r=n.cleanup;if(null!=r)for(let s=0;sl?a[l]:null}"string"==typeof o&&(s+=2)}return null}(n,t,r,i.index)),null!==b)(b.__ngLastListenerFn__||b).__ngNextListenerFn__=s,b.__ngLastListenerFn__=s,u=!1;else{s=Zk(i,t,c,s,!1);const M=e.listen(v,r,s);d.push(s,M),h&&h.push(r,S,y,y+1)}}else s=Zk(i,t,c,s,!1);const p=i.outputs;let f;if(u&&null!==p&&(f=p[r])){const g=f.length;if(g)for(let v=0;v-1?To(n.index,t):t);let l=$k(t,e,i,o),h=s.__ngNextListenerFn__;for(;h;)l=$k(t,e,h,o)&&l,h=h.__ngNextListenerFn__;return r&&!1===l&&o.preventDefault(),l}}function QW(){return this._results[Symbol.iterator]()}class hw{get changes(){return this._changes??=new Yo}constructor(t=!1){this._emitDistinctChangesOnly=t,this.dirty=!0,this._results=[],this._changesDetected=!1,this._changes=void 0,this.length=0,this.first=void 0,this.last=void 0;const e=hw.prototype;e[Symbol.iterator]||(e[Symbol.iterator]=QW)}get(t){return this._results[t]}map(t){return this._results.map(t)}filter(t){return this._results.filter(t)}find(t){return this._results.find(t)}reduce(t,e){return this._results.reduce(t,e)}forEach(t){this._results.forEach(t)}some(t){return this._results.some(t)}toArray(){return this._results.slice()}toString(){return this._results.toString()}reset(t,e){this.dirty=!1;const i=function oo(n){return n.flat(Number.POSITIVE_INFINITY)}(t);(this._changesDetected=!function $U(n,t,e){if(n.length!==t.length)return!1;for(let i=0;i{class n{static{this.__NG_ELEMENT_ID__=qW}}return n})();const GW=ih,XW=class extends GW{constructor(t,e,i){super(),this._declarationLView=t,this._declarationTContainer=e,this.elementRef=i}get ssrId(){return this._declarationTContainer.tView?.ssrId||null}createEmbeddedView(t,e){return this.createEmbeddedViewImpl(t,e)}createEmbeddedViewImpl(t,e,i){const r=function ig(n,t,e,i){const r=t.tView,a=wy(n,r,e,4096&n[Ct]?4096:16,null,t,null,null,null,i?.injector??null,i?.dehydratedView??null);a[Mf]=n[t.index];const h=n[il];return null!==h&&(a[il]=h.createEmbeddedView(r)),LM(r,a,e),a}(this._declarationLView,this._declarationTContainer,t,{injector:e,dehydratedView:i});return new qf(r)}};function qW(){return Qy(fr(),Se())}function Qy(n,t){return 4&n.type?new XW(t,n,Du(n,t)):null}class cw{constructor(t){this.queryList=t,this.matches=null}clone(){return new cw(this.queryList)}setDirty(){this.queryList.setDirty()}}class dw{constructor(t=[]){this.queries=t}createEmbeddedView(t){const e=t.queries;if(null!==e){const i=null!==t.contentQueries?t.contentQueries[0]:e.length,r=[];for(let s=0;s0)i.push(o[a/2]);else{const h=s[a+1],c=t[-l];for(let d=mn;d(qh(!0),function ny(n,t){return n.createText(t)}(t[Yt],i));function vw(n,t,e,i,r){if(n=vt(n),Array.isArray(n))for(let s=0;s>20;if(Gc(n)||!n.multi){const p=new Af(h,r,Ot),f=yw(l,t,r?c:c+u,d);-1===f?(l1(Um(a,o),s,l),mw(s,n,t.length),t.push(l),a.directiveStart++,a.directiveEnd++,r&&(a.providerIndexes+=1048576),e.push(p),o.push(p)):(e[f]=p,o[f]=p)}else{const p=yw(l,t,c+u,d),f=yw(l,t,c,c+u),v=f>=0&&e[f];if(r&&!v||!r&&!(p>=0&&e[p])){l1(Um(a,o),s,l);const y=function yY(n,t,e,i,r){const s=new Af(n,e,Ot);return s.multi=[],s.index=t,s.componentProviders=0,kP(s,r,i&&!e),s}(r?mY:vY,e.length,r,i,h);!r&&v&&(e[f].providerFactory=y),mw(s,n,t.length,0),t.push(l),a.directiveStart++,a.directiveEnd++,r&&(a.providerIndexes+=1048576),e.push(y),o.push(y)}else mw(s,n,p>-1?p:f,kP(e[r?f:p],h,!r&&i));!r&&i&&v&&e[f].componentProviders++}}}function mw(n,t,e,i){const r=Gc(t),s=function gj(n){return!!n.useClass}(t);if(r||s){const l=(s?vt(t.useClass):t).prototype.ngOnDestroy;if(l){const h=n.destroyHooks||(n.destroyHooks=[]);if(!r&&t.multi){const c=h.indexOf(e);-1===c?h.push(e,[i,l]):h[c+1].push(i,l)}else h.push(e,l)}}}function kP(n,t,e){return e&&n.componentProviders++,n.multi.push(t)-1}function yw(n,t,e,i){for(let r=e;r{e.providersResolver=(i,r)=>function gY(n,t,e){const i=xi();if(i.firstCreatePass){const r=Ca(n);vw(e,i.data,i.blueprint,r,!0),vw(t,i.data,i.blueprint,r,!1)}}(i,r?r(n):n,t)}}class rd{}class zP extends rd{constructor(t){super(),this.componentFactoryResolver=new JN(this),this.instance=null;const e=new vu([...t.providers,{provide:rd,useValue:this},{provide:Sy,useValue:this.componentFactoryResolver}],t.parent||Zm(),t.debugName,new Set(["environment"]));this.injector=e,t.runEnvironmentInitializers&&e.resolveInjectorInitializers()}destroy(){this.injector.destroy()}onDestroy(t){this.injector.onDestroy(t)}}let wY=(()=>{class n{constructor(e){this._injector=e,this.cachedInjectors=new Map}getOrCreateStandaloneInjector(e){if(!e.standalone)return null;if(!this.cachedInjectors.has(e)){const i=XA(0,e.type),r=i.length>0?function MY(n,t,e=null){return new zP({providers:n,parent:t,debugName:e,runEnvironmentInitializers:!0}).injector}([i],this._injector,`Standalone[${e.type.name}]`):null;this.cachedInjectors.set(e,r)}return this.cachedInjectors.get(e)}ngOnDestroy(){try{for(const e of this.cachedInjectors.values())null!==e&&e.destroy()}finally{this.cachedInjectors.clear()}}static{this.\u0275prov=Yi({token:n,providedIn:"environment",factory:()=>new n(Fi(Jl))})}}return n})();function RP(n){(function Zc(n){VN.has(n)||(VN.add(n),performance?.mark?.("mark_feature_usage",{detail:{feature:n}}))})("NgStandalone"),n.getStandaloneInjector=t=>t.get(wY).getOrCreateStandaloneInjector(n)}let Tw=(()=>{class n{constructor(){this.taskId=0,this.pendingTasks=new Set,this.hasPendingTasks=new _o(!1)}get _hasPendingTasks(){return this.hasPendingTasks.value}add(){this._hasPendingTasks||this.hasPendingTasks.next(!0);const e=this.taskId++;return this.pendingTasks.add(e),e}remove(e){this.pendingTasks.delete(e),0===this.pendingTasks.size&&this._hasPendingTasks&&this.hasPendingTasks.next(!1)}ngOnDestroy(){this.pendingTasks.clear(),this._hasPendingTasks&&this.hasPendingTasks.next(!1)}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();const g2=new Ht(""),XQ=new Ht("");let kw=(()=>{class n{constructor(){this.initialized=!1,this.done=!1,this.donePromise=new Promise((e,i)=>{this.resolve=e,this.reject=i}),this.appInits=Ri(XQ,{optional:!0})??[]}runInitializers(){if(this.initialized)return;const e=[];for(const r of this.appInits){const s=r();if(ow(s))e.push(s);else if(Gk(s)){const o=new Promise((a,l)=>{s.subscribe({complete:a,error:l})});e.push(o)}}const i=()=>{this.done=!0,this.resolve()};Promise.all(e).then(()=>{i()}).catch(r=>{this.reject(r)}),0===e.length&&i(),this.initialized=!0}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();const v2=new Ht("");let Ju=(()=>{class n{constructor(){this._bootstrapListeners=[],this._runningTick=!1,this._destroyed=!1,this._destroyListeners=[],this._views=[],this.internalErrorHandler=Ri(SN),this.afterRenderEffectManager=Ri($f),this.componentTypes=[],this.components=[],this.isStable=Ri(Tw).hasPendingTasks.pipe(jr(e=>!e)),this._injector=Ri(Jl)}get destroyed(){return this._destroyed}get injector(){return this._injector}bootstrap(e,i){const r=e instanceof rN;if(!this._injector.get(kw).done)throw!r&&function _c(n){const t=ci(n)||jn(n)||gs(n);return null!==t&&t.standalone}(e),new F(405,!1);let o;o=r?e:this._injector.get(Sy).resolveComponentFactory(e),this.componentTypes.push(o.componentType);const a=function $Q(n){return n.isBoundToModule}(o)?void 0:this._injector.get(rd),h=o.create(Wo.NULL,[],i||o.selector,a),c=h.location.nativeElement,d=h.injector.get(g2,null);return d?.registerApplication(c),h.onDestroy(()=>{this.detachView(h.hostView),Jy(this.components,h),d?.unregisterApplication(c)}),this._loadComponent(h),h}tick(){if(this._runningTick)throw new F(101,!1);try{this._runningTick=!0;for(let e of this._views)e.detectChanges()}catch(e){this.internalErrorHandler(e)}finally{try{this.afterRenderEffectManager.execute()}catch(e){this.internalErrorHandler(e)}this._runningTick=!1}}attachView(e){const i=e;this._views.push(i),i.attachToAppRef(this)}detachView(e){const i=e;Jy(this._views,i),i.detachFromAppRef()}_loadComponent(e){this.attachView(e.hostView),this.tick(),this.components.push(e);const i=this._injector.get(v2,[]);[...this._bootstrapListeners,...i].forEach(r=>r(e))}ngOnDestroy(){if(!this._destroyed)try{this._destroyListeners.forEach(e=>e()),this._views.slice().forEach(e=>e.destroy())}finally{this._destroyed=!0,this._views=[],this._bootstrapListeners=[],this._destroyListeners=[]}}onDestroy(e){return this._destroyListeners.push(e),()=>Jy(this._destroyListeners,e)}destroy(){if(this._destroyed)throw new F(406,!1);const e=this._injector;e.destroy&&!e.destroyed&&e.destroy()}get viewCount(){return this._views.length}warnIfDestroyed(){}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();function Jy(n,t){const e=n.indexOf(t);e>-1&&n.splice(e,1)}let JQ=(()=>{class n{constructor(){this.zone=Ri(zr),this.applicationRef=Ri(Ju)}initialize(){this._onMicrotaskEmptySubscription||(this._onMicrotaskEmptySubscription=this.zone.onMicrotaskEmpty.subscribe({next:()=>{this.zone.run(()=>{this.applicationRef.tick()})}}))}ngOnDestroy(){this._onMicrotaskEmptySubscription?.unsubscribe()}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();function b2(n){return[{provide:zr,useFactory:n},{provide:gu,multi:!0,useFactory:()=>{const t=Ri(JQ,{optional:!0});return()=>t.initialize()}},{provide:gu,multi:!0,useFactory:()=>{const t=Ri(tG);return()=>{t.initialize()}}},{provide:SN,useFactory:KQ}]}function KQ(){const n=Ri(zr),t=Ri(eh);return e=>n.runOutsideAngular(()=>t.handleError(e))}function eG(n){return function S1(n){return{\u0275providers:n}}([[],b2(()=>new zr(function M2(n){return{enableLongStackTrace:!1,shouldCoalesceEventChangeDetection:n?.eventCoalescing??!1,shouldCoalesceRunChangeDetection:n?.runCoalescing??!1}}(n)))])}let tG=(()=>{class n{constructor(){this.subscription=new As,this.initialized=!1,this.zone=Ri(zr),this.pendingTasks=Ri(Tw)}initialize(){if(this.initialized)return;this.initialized=!0;let e=null;!this.zone.isStable&&!this.zone.hasPendingMacrotasks&&!this.zone.hasPendingMicrotasks&&(e=this.pendingTasks.add()),this.zone.runOutsideAngular(()=>{this.subscription.add(this.zone.onStable.subscribe(()=>{zr.assertNotInAngularZone(),queueMicrotask(()=>{null!==e&&!this.zone.hasPendingMacrotasks&&!this.zone.hasPendingMicrotasks&&(this.pendingTasks.remove(e),e=null)})}))}),this.subscription.add(this.zone.onUnstable.subscribe(()=>{zr.assertInAngularZone(),e??=this.pendingTasks.add()}))}ngOnDestroy(){this.subscription.unsubscribe()}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();const rh=new Ht("",{providedIn:"root",factory:()=>Ri(rh,Di.Optional|Di.SkipSelf)||function iG(){return typeof $localize<"u"&&$localize.locale||qu}()}),Pw=new Ht("");let rc=null;function DG(n){try{const{rootComponent:t,appProviders:e,platformProviders:i}=n,r=function aG(n=[]){if(rc)return rc;const t=function E2(n=[],t){return Wo.create({name:t,providers:[{provide:M1,useValue:"platform"},{provide:Pw,useValue:new Set([()=>rc=null])},...n]})}(n);return rc=t,function m2(){!function Ib(n){Gd=n}(()=>{throw new F(600,!1)})}(),function D2(n){n.get(sL,null)?.forEach(e=>e())}(t),t}(i),s=[eG(),...e||[]],a=new zP({providers:s,parent:r,debugName:"",runEnvironmentInitializers:!1}).injector,l=a.get(zr);return l.run(()=>{a.resolveInjectorInitializers();const h=a.get(eh,null);let c;l.runOutsideAngular(()=>{c=l.onError.subscribe({next:p=>{h.handleError(p)}})});const d=()=>a.destroy(),u=r.get(Pw);return u.add(d),a.onDestroy(()=>{c.unsubscribe(),u.delete(d)}),function y2(n,t,e){try{const i=e();return ow(i)?i.catch(r=>{throw t.runOutsideAngular(()=>n.handleError(r)),r}):i}catch(i){throw t.runOutsideAngular(()=>n.handleError(i)),i}}(h,l,()=>{const p=a.get(kw);return p.runInitializers(),p.donePromise.then(()=>{!function wk(n){ro(n,"Expected localeId to be defined"),"string"==typeof n&&(Mk=n.toLowerCase().replace(/_/g,"-"))}(a.get(rh,qu)||qu);const g=a.get(Ju);return void 0!==t&&g.bootstrap(t),g})})})}catch(t){return Promise.reject(t)}}let $2=null;function jw(){return $2}class UG{}const sd=new Ht("");let sq=(()=>{class n{static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275mod=Am({type:n})}static{this.\u0275inj=mf({})}}return n})();function uz(n){return"server"===n}class kq extends UG{constructor(){super(...arguments),this.supportsDOMEvents=!0}}class sC extends kq{static makeCurrent(){!function _G(n){$2??=n}(new sC)}onAndCancel(t,e,i){return t.addEventListener(e,i),()=>{t.removeEventListener(e,i)}}dispatchEvent(t,e){t.dispatchEvent(e)}remove(t){t.parentNode&&t.parentNode.removeChild(t)}createElement(t,e){return(e=e||this.getDefaultDocument()).createElement(t)}createHtmlDocument(){return document.implementation.createHTMLDocument("fakeTitle")}getDefaultDocument(){return document}isElementNode(t){return t.nodeType===Node.ELEMENT_NODE}isShadowRoot(t){return t instanceof DocumentFragment}getGlobalEventTarget(t,e){return"window"===e?window:"document"===e?t:"body"===e?t.body:null}getBaseHref(t){const e=function Pq(){return wg=wg||document.querySelector("base"),wg?wg.getAttribute("href"):null}();return null==e?null:function zq(n){return new URL(n,document.baseURI).pathname}(e)}resetBaseElement(){wg=null}getUserAgent(){return window.navigator.userAgent}getCookie(t){return function xX(n,t){t=encodeURIComponent(t);for(const e of n.split(";")){const i=e.indexOf("="),[r,s]=-1==i?[e,""]:[e.slice(0,i),e.slice(i+1)];if(r.trim()===t)return decodeURIComponent(s)}return null}(document.cookie,t)}}let wg=null,Hq=(()=>{class n{build(){return new XMLHttpRequest}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();const oC=new Ht("");let vz=(()=>{class n{constructor(e,i){this._zone=i,this._eventNameToPlugin=new Map,e.forEach(r=>{r.manager=this}),this._plugins=e.slice().reverse()}addEventListener(e,i,r){return this._findPluginFor(i).addEventListener(e,i,r)}getZone(){return this._zone}_findPluginFor(e){let i=this._eventNameToPlugin.get(e);if(i)return i;if(i=this._plugins.find(s=>s.supports(e)),!i)throw new F(5101,!1);return this._eventNameToPlugin.set(e,i),i}static{this.\u0275fac=function(i){return new(i||n)(Fi(oC),Fi(zr))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();class mz{constructor(t){this._doc=t}}const aC="ng-app-id";let yz=(()=>{class n{constructor(e,i,r,s={}){this.doc=e,this.appId=i,this.nonce=r,this.platformId=s,this.styleRef=new Map,this.hostNodes=new Set,this.styleNodesInDOM=this.collectServerRenderedStyles(),this.platformIsServer=uz(s),this.resetHostNodes()}addStyles(e){for(const i of e)1===this.changeUsageCount(i,1)&&this.onStyleAdded(i)}removeStyles(e){for(const i of e)this.changeUsageCount(i,-1)<=0&&this.onStyleRemoved(i)}ngOnDestroy(){const e=this.styleNodesInDOM;e&&(e.forEach(i=>i.remove()),e.clear());for(const i of this.getAllStyles())this.onStyleRemoved(i);this.resetHostNodes()}addHost(e){this.hostNodes.add(e);for(const i of this.getAllStyles())this.addStyleToHost(e,i)}removeHost(e){this.hostNodes.delete(e)}getAllStyles(){return this.styleRef.keys()}onStyleAdded(e){for(const i of this.hostNodes)this.addStyleToHost(i,e)}onStyleRemoved(e){const i=this.styleRef;i.get(e)?.elements?.forEach(r=>r.remove()),i.delete(e)}collectServerRenderedStyles(){const e=this.doc.head?.querySelectorAll(`style[${aC}="${this.appId}"]`);if(e?.length){const i=new Map;return e.forEach(r=>{null!=r.textContent&&i.set(r.textContent,r)}),i}return null}changeUsageCount(e,i){const r=this.styleRef;if(r.has(e)){const s=r.get(e);return s.usage+=i,s.usage}return r.set(e,{usage:i,elements:[]}),i}getStyleElement(e,i){const r=this.styleNodesInDOM,s=r?.get(i);if(s?.parentNode===e)return r.delete(i),s.removeAttribute(aC),s;{const o=this.doc.createElement("style");return this.nonce&&o.setAttribute("nonce",this.nonce),o.textContent=i,this.platformIsServer&&o.setAttribute(aC,this.appId),e.appendChild(o),o}}addStyleToHost(e,i){const r=this.getStyleElement(e,i),s=this.styleRef,o=s.get(i)?.elements;o?o.push(r):s.set(i,{elements:[r],usage:1})}resetHostNodes(){const e=this.hostNodes;e.clear(),e.add(this.doc.head)}static{this.\u0275fac=function(i){return new(i||n)(Fi(sd),Fi(A1),Fi(oL,8),Fi(yu))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();const lC={svg:"http://www.w3.org/2000/svg",xhtml:"http://www.w3.org/1999/xhtml",xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/",math:"http://www.w3.org/1998/MathML/"},hC=/%COMP%/g,Uq=new Ht("",{providedIn:"root",factory:()=>!0});function Iz(n,t){return t.map(e=>e.replace(hC,n))}let bz=(()=>{class n{constructor(e,i,r,s,o,a,l,h=null){this.eventManager=e,this.sharedStylesHost=i,this.appId=r,this.removeStylesOnCompDestroy=s,this.doc=o,this.platformId=a,this.ngZone=l,this.nonce=h,this.rendererByCompId=new Map,this.platformIsServer=uz(a),this.defaultRenderer=new cC(e,o,l,this.platformIsServer)}createRenderer(e,i){if(!e||!i)return this.defaultRenderer;this.platformIsServer&&i.encapsulation===Ia.ShadowDom&&(i={...i,encapsulation:Ia.Emulated});const r=this.getOrCreateRenderer(e,i);return r instanceof wz?r.applyToHost(e):r instanceof dC&&r.applyStyles(),r}getOrCreateRenderer(e,i){const r=this.rendererByCompId;let s=r.get(i.id);if(!s){const o=this.doc,a=this.ngZone,l=this.eventManager,h=this.sharedStylesHost,c=this.removeStylesOnCompDestroy,d=this.platformIsServer;switch(i.encapsulation){case Ia.Emulated:s=new wz(l,h,i,this.appId,c,o,a,d);break;case Ia.ShadowDom:return new Yq(l,h,e,i,o,a,this.nonce,d);default:s=new dC(l,h,i,c,o,a,d)}r.set(i.id,s)}return s}ngOnDestroy(){this.rendererByCompId.clear()}static{this.\u0275fac=function(i){return new(i||n)(Fi(vz),Fi(yz),Fi(A1),Fi(Uq),Fi(sd),Fi(yu),Fi(zr),Fi(oL))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();class cC{constructor(t,e,i,r){this.eventManager=t,this.doc=e,this.ngZone=i,this.platformIsServer=r,this.data=Object.create(null),this.throwOnSyntheticProps=!0,this.destroyNode=null}destroy(){}createElement(t,e){return e?this.doc.createElementNS(lC[e]||e,t):this.doc.createElement(t)}createComment(t){return this.doc.createComment(t)}createText(t){return this.doc.createTextNode(t)}appendChild(t,e){(Mz(t)?t.content:t).appendChild(e)}insertBefore(t,e,i){t&&(Mz(t)?t.content:t).insertBefore(e,i)}removeChild(t,e){t&&t.removeChild(e)}selectRootElement(t,e){let i="string"==typeof t?this.doc.querySelector(t):t;if(!i)throw new F(-5104,!1);return e||(i.textContent=""),i}parentNode(t){return t.parentNode}nextSibling(t){return t.nextSibling}setAttribute(t,e,i,r){if(r){e=r+":"+e;const s=lC[r];s?t.setAttributeNS(s,e,i):t.setAttribute(e,i)}else t.setAttribute(e,i)}removeAttribute(t,e,i){if(i){const r=lC[i];r?t.removeAttributeNS(r,e):t.removeAttribute(`${i}:${e}`)}else t.removeAttribute(e)}addClass(t,e){t.classList.add(e)}removeClass(t,e){t.classList.remove(e)}setStyle(t,e,i,r){r&(Kh.DashCase|Kh.Important)?t.style.setProperty(e,i,r&Kh.Important?"important":""):t.style[e]=i}removeStyle(t,e,i){i&Kh.DashCase?t.style.removeProperty(e):t.style[e]=""}setProperty(t,e,i){null!=t&&(t[e]=i)}setValue(t,e){t.nodeValue=e}listen(t,e,i){if("string"==typeof t&&!(t=jw().getGlobalEventTarget(this.doc,t)))throw new Error(`Unsupported event target ${t} for event ${e}`);return this.eventManager.addEventListener(t,e,this.decoratePreventDefault(i))}decoratePreventDefault(t){return e=>{if("__ngUnwrap__"===e)return t;!1===(this.platformIsServer?this.ngZone.runGuarded(()=>t(e)):t(e))&&e.preventDefault()}}}function Mz(n){return"TEMPLATE"===n.tagName&&void 0!==n.content}class Yq extends cC{constructor(t,e,i,r,s,o,a,l){super(t,s,o,l),this.sharedStylesHost=e,this.hostEl=i,this.shadowRoot=i.attachShadow({mode:"open"}),this.sharedStylesHost.addHost(this.shadowRoot);const h=Iz(r.id,r.styles);for(const c of h){const d=document.createElement("style");a&&d.setAttribute("nonce",a),d.textContent=c,this.shadowRoot.appendChild(d)}}nodeOrShadowRoot(t){return t===this.hostEl?this.shadowRoot:t}appendChild(t,e){return super.appendChild(this.nodeOrShadowRoot(t),e)}insertBefore(t,e,i){return super.insertBefore(this.nodeOrShadowRoot(t),e,i)}removeChild(t,e){return super.removeChild(this.nodeOrShadowRoot(t),e)}parentNode(t){return this.nodeOrShadowRoot(super.parentNode(this.nodeOrShadowRoot(t)))}destroy(){this.sharedStylesHost.removeHost(this.shadowRoot)}}class dC extends cC{constructor(t,e,i,r,s,o,a,l){super(t,s,o,a),this.sharedStylesHost=e,this.removeStylesOnCompDestroy=r,this.styles=l?Iz(l,i.styles):i.styles}applyStyles(){this.sharedStylesHost.addStyles(this.styles)}destroy(){this.removeStylesOnCompDestroy&&this.sharedStylesHost.removeStyles(this.styles)}}class wz extends dC{constructor(t,e,i,r,s,o,a,l){const h=r+"-"+i.id;super(t,e,i,s,o,a,l,h),this.contentAttr=function jq(n){return"_ngcontent-%COMP%".replace(hC,n)}(h),this.hostAttr=function Vq(n){return"_nghost-%COMP%".replace(hC,n)}(h)}applyToHost(t){this.applyStyles(),this.setAttribute(t,this.hostAttr,"")}createElement(t,e){const i=super.createElement(t,e);return super.setAttribute(i,this.contentAttr,""),i}}let Qq=(()=>{class n extends mz{constructor(e){super(e)}supports(e){return!0}addEventListener(e,i,r){return e.addEventListener(i,r,!1),()=>this.removeEventListener(e,i,r)}removeEventListener(e,i,r){return e.removeEventListener(i,r)}static{this.\u0275fac=function(i){return new(i||n)(Fi(sd))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();const Cz=["alt","control","meta","shift"],Gq={"\b":"Backspace","\t":"Tab","\x7f":"Delete","\x1b":"Escape",Del:"Delete",Esc:"Escape",Left:"ArrowLeft",Right:"ArrowRight",Up:"ArrowUp",Down:"ArrowDown",Menu:"ContextMenu",Scroll:"ScrollLock",Win:"OS"},Xq={alt:n=>n.altKey,control:n=>n.ctrlKey,meta:n=>n.metaKey,shift:n=>n.shiftKey};let qq=(()=>{class n extends mz{constructor(e){super(e)}supports(e){return null!=n.parseEventName(e)}addEventListener(e,i,r){const s=n.parseEventName(i),o=n.eventCallback(s.fullKey,r,this.manager.getZone());return this.manager.getZone().runOutsideAngular(()=>jw().onAndCancel(e,s.domEventName,o))}static parseEventName(e){const i=e.toLowerCase().split("."),r=i.shift();if(0===i.length||"keydown"!==r&&"keyup"!==r)return null;const s=n._normalizeKey(i.pop());let o="",a=i.indexOf("code");if(a>-1&&(i.splice(a,1),o="code."),Cz.forEach(h=>{const c=i.indexOf(h);c>-1&&(i.splice(c,1),o+=h+".")}),o+=s,0!=i.length||0===s.length)return null;const l={};return l.domEventName=r,l.fullKey=o,l}static matchEventFullKeyCode(e,i){let r=Gq[e.key]||e.key,s="";return i.indexOf("code.")>-1&&(r=e.code,s="code."),!(null==r||!r)&&(r=r.toLowerCase()," "===r?r="space":"."===r&&(r="dot"),Cz.forEach(o=>{o!==r&&(0,Xq[o])(e)&&(s+=o+".")}),s+=r,s===i)}static eventCallback(e,i,r){return s=>{n.matchEventFullKeyCode(s,e)&&r.runGuarded(()=>i(s))}}static _normalizeKey(e){return"esc"===e?"escape":e}static{this.\u0275fac=function(i){return new(i||n)(Fi(sd))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();function Ez(n){return{appProviders:[...i$,...n?.providers??[]],platformProviders:e$}}const e$=[{provide:yu,useValue:"browser"},{provide:sL,useValue:function Zq(){sC.makeCurrent()},multi:!0},{provide:sd,useFactory:function Kq(){return function Aj(n){T1=n}(document),document},deps:[]}],i$=[{provide:M1,useValue:"root"},{provide:eh,useFactory:function Jq(){return new eh},deps:[]},{provide:oC,useClass:Qq,multi:!0,deps:[sd,zr,yu]},{provide:oC,useClass:qq,multi:!0,deps:[sd]},bz,yz,vz,{provide:sN,useExisting:bz},{provide:class cq{},useClass:Hq,deps:[]},[]];var o$=0,uC=!1;function b0(n,t){var e=t;return e.unshift(void 0),new(Function.prototype.bind.apply(n,e))}function Y(n,t){for(var e=t,i=n.replace(/\[/g,".").replace(/\]/g,"").split("."),r=0;r"u"}function wi(n){return n+"_"+o$++}function w0(n,t){return n===t||!(n===document||!n)&&w0(n.parentNode,t)}function Dg(n){try{throw new Error(n)}catch(t){throw new Error(t.message+"\n"+t.stack)}}function Re(n){var t=n+"";return t.match(/auto|cm|mm|in|px|pt|pc|%|em|ex|ch|rem|vw|vh|vmin|vmax/)?t:t+"px"}function ce(){return uC}var xg,n,t,d$={latn:{_digits:"0123456789",_type:"numeric"}},Lz={decimal:".",group:",",percentSign:"%",plusSign:"+",minusSign:"-",infinity:"\u221e",nan:"NaN",exponential:"E"},Nz=[0,1,2,3,4,5,6,7,8,9],Rr=function(){function n(){}return n.getMainObject=function(t,e){return Y(ce()?e:"main."+e,t)},n.getNumberingSystem=function(t){return Y("supplemental.numberingSystems",t)||this.numberingSystems},n.reverseObject=function(t,e){for(var r={},s=0,o=e||Object.keys(t);s13&&(f+=1,o-=12),o-=1,a=f-4716;var y=u-24e5,S=10631/30,b=u-1948084,M=Math.floor(b/10631);b-=10631*M;var w=Math.floor((b-.1335)/S),C=30*M+w;b-=Math.floor(w*S+.1335);var D=Math.floor((b+28.5001)/29.5);13===D&&(D=12);for(var A=b-Math.floor(29.5001*D-29),x=0;xy);x++);var R=x+16260,L=Math.floor((R-1)/12),O=L+1,N=R-12*L,T=y-t[x-1]+1;return(T+"").length>2&&(T=A,N=D,O=C),{year:O,month:N,date:T}},n.toGregorian=function i(r,s,o){var g=Math.floor(o+t[12*(r-1)+1+(s-1)-16260-1]-1+24e5+.5),v=Math.floor((g-1867216.25)/36524.25),y=1524+(v=g+1+v-Math.floor(v/4)),S=Math.floor((y-122.1)/365.25),b=Math.floor(365.25*S),M=Math.floor((y-b)/30.6001),w=y-b-Math.floor(30.6001*M),C=M-(M>13.5?13:1),D=S-(C>2.5?4716:4715);return D<=0&&C--,new Date(D+"/"+C+"/"+w)};var ut,f$=/\/MMMMM|MMMM|MMM|a|LLLL|LLL|EEEEE|EEEE|E|K|cccc|ccc|WW|W|G+|z+/gi,Oz="stand-alone",g$=["sun","mon","tue","wed","thu","fri","sat"],kz={m:"getMinutes",h:"getHours",H:"getHours",s:"getSeconds",d:"getDate",f:"getMilliseconds"},Pz=function(){function n(){}return n.dateFormat=function(t,e,i){var r=this,s=ut.getDependables(i,t,e.calendar),o=Y("parserObject.numbers",s),a=s.dateObject,l={isIslamic:ut.islamicRegex.test(e.calendar)};ce()&&e.isServerRendered&&(e=ut.compareBlazorDateFormats(e,t));var h=e.format||ut.getResultantPattern(e.skeleton,s.dateObject,e.type,!1,ce()?t:"");if(l.dateSeperator=ce()?Y("dateSeperator",a):ut.getDateSeparator(s.dateObject),st(h))Dg("Format options or type given must be invalid");else{h=ut.ConvertDateToWeekFormat(h),ce()&&(h=h.replace(/tt/,"a")),l.pattern=h,l.numMapper=ce()?ze({},o):Rr.getNumberMapper(s.parserObject,Rr.getNumberingSystem(i));for(var d=0,u=h.match(f$)||[];d2?r+=e.month[""+u]:f=!0;break;case"E":case"c":r+=e.weekday[""+g$[t.getDay()]];break;case"H":case"h":case"m":case"s":case"d":case"f":if(f=!0,"d"===d)u=o.date;else if("f"===d){f=!1,g=!0;var y=(p=(p=t[""+kz[""+d]]().toString()).substring(0,c)).length;if(c!==y){if(c>3)continue;for(var S=0;S0?1:0],o=Math.abs(t);return s.replace(/HH?|mm/g,function(a){var l=a.length,h=-1!==a.indexOf("H");return i.checkTwodigitNumber(Math.floor(h?o/60:o%60),l)})},n}(),zz={ms:"minimumSignificantDigits",ls:"maximumSignificantDigits",mf:"minimumFractionDigits",lf:"maximumFractionDigits"},ip=["infinity","nan","group","decimal","exponential"],Rz=function(){function n(){}return n.numberFormatter=function(t,e,i){var l,r=this,s=ze({},e),o={},a={},h=ut.getDependables(i,t,"",!0),c=h.numericObject;a.numberMapper=ce()?ze({},c):Rr.getNumberMapper(h.parserObject,Rr.getNumberingSystem(i),!0),a.currencySymbol=ce()?Y("currencySymbol",c):ut.getCurrencySymbol(h.numericObject,s.currency||Lg,e.altSymbol,e.ignoreCurrency),a.percentSymbol=ce()?Y("numberSymbols.percentSign",c):a.numberMapper.numberSymbols.percentSign,a.minusSymbol=ce()?Y("numberSymbols.minusSign",c):a.numberMapper.numberSymbols.minusSign;var d=a.numberMapper.numberSymbols;if(e.format&&!ut.formatRegex.test(e.format))o=ut.customFormat(e.format,a,h.numericObject),!st(s.useGrouping)&&s.useGrouping&&(s.useGrouping=o.pData.useGrouping);else{if(ze(s,ut.getProperNumericSkeleton(e.format||"N")),s.isCurrency="currency"===s.type,s.isPercent="percent"===s.type,ce()||(l=ut.getSymbolPattern(s.type,a.numberMapper.numberSystem,h.numericObject,s.isAccount)),s.groupOne=this.checkValueRange(s.maximumSignificantDigits,s.minimumSignificantDigits,!0),this.checkValueRange(s.maximumFractionDigits,s.minimumFractionDigits,!1,!0),st(s.fractionDigits)||(s.minimumFractionDigits=s.maximumFractionDigits=s.fractionDigits),st(s.useGrouping)&&(s.useGrouping=!0),s.isCurrency&&!ce()&&(l=l.replace(/\u00A4/g,ut.defaultCurrency)),ce())o.nData=ze({},{},Y(s.type+"nData",c)),o.pData=ze({},{},Y(s.type+"pData",c)),"currency"===s.type&&e.currency&&ut.replaceBlazorCurrency([o.pData,o.nData],a.currencySymbol,e.currency);else{var u=l.split(";");o.nData=ut.getFormatData(u[1]||"-"+u[0],!0,a.currencySymbol),o.pData=ut.getFormatData(u[0],!1,a.currencySymbol),s.useGrouping&&(s.groupSeparator=d[ip[2]],s.groupData=this.getGroupingDetails(u[0]))}if(st(s.minimumFractionDigits)&&(s.minimumFractionDigits=o.nData.minimumFraction),st(s.maximumFractionDigits)){var f=o.nData.maximumFraction;s.maximumFractionDigits=st(f)&&s.isPercent?0:f}var g=s.minimumFractionDigits,v=s.maximumFractionDigits;!st(g)&&!st(v)&&g>v&&(s.maximumFractionDigits=g)}return ze(o.nData,s),ze(o.pData,s),function(y){return isNaN(y)?d[ip[1]]:isFinite(y)?r.intNumberFormatter(y,o,a,e):d[ip[0]]}},n.getGroupingDetails=function(t){var e={},i=t.match(ut.negativeDataRegex);if(i&&i[4]){var r=i[4],s=r.lastIndexOf(",");if(-1!==s){var o=r.split(".")[0];e.primary=o.length-s-1;var a=r.lastIndexOf(",",s-1);-1!==a&&(e.secondary=s-1-a)}}return e},n.checkValueRange=function(t,e,i,r){var s=r?"f":"s",o=0,a=zz["l"+s],l=zz["m"+s];if(st(t)||(this.checkRange(t,a,r),o++),st(e)||(this.checkRange(e,l,r),o++),2===o){if(!(tr[1])&&Dg(e+"value must be within the range"+r[0]+"to"+r[1])},n.intNumberFormatter=function(t,e,i,r){var s;if(!st(e.nData.type)){t<0?(t*=-1,s=e.nData):s=0===t&&e.zeroData||e.pData;var o="";if(s.isPercent&&(t*=100),s.groupOne)o=this.processSignificantDigits(t,s.minimumSignificantDigits,s.maximumSignificantDigits);else if(o=this.processFraction(t,s.minimumFractionDigits,s.maximumFractionDigits,r),s.minimumIntegerDigits&&(o=this.processMinimumIntegers(o,s.minimumIntegerDigits)),i.isCustomFormat&&s.minimumFractionDigits=0&&"0"===l[parseInt(c.toString(),10)]&&c>=s.minimumFractionDigits;c--)l=l.slice(0,c);o=a[0]+"."+l}return"scientific"===s.type&&(o=(o=t.toExponential(s.maximumFractionDigits)).replace("e",i.numberMapper.numberSymbols[ip[4]])),o=o.replace(".",i.numberMapper.numberSymbols[ip[3]]),o="#,###,,;(#,###,,)"===s.format?this.customPivotFormat(parseInt(o,10)):o,s.useGrouping&&(o=this.groupNumbers(o,s.groupData.primary,s.groupSeparator||",",i.numberMapper.numberSymbols[ip[3]]||".",s.groupData.secondary)),o=Rr.convertValueParts(o,ut.latnParseRegex,i.numberMapper.mapper),"N/A"===s.nlead?s.nlead:"0"===o&&r&&"0"===r.format?o+s.nend:s.nlead+o+s.nend}},n.processSignificantDigits=function(t,e,i){var r=t+"";return r.lengthe;)c=l.slice(h-e,h)+(c.length?i+c:""),h-=e,o&&(e=s,o=!1);return a[0]=l.slice(0,h)+(c.length?i:"")+c,a.join(r)},n.processFraction=function(t,e,i,r){var s=(t+"").split(".")[1],o=s?s.length:0;if(e&&oi||0===i))return t.toFixed(i);var h=t+"";return"0"===h[0]&&r&&"###.00"===r.format&&(h=h.slice(1)),h},n.processMinimumIntegers=function(t,e){var i=t.split("."),r=i[0],s=r.length;if(s=5e5){var r=(t/=1e6).toString().split(".")[1];return r&&+r.substring(0,1)>=5?Math.ceil(t).toString():Math.floor(t).toString()}return""},n}(),Tg=(new RegExp("^([^0-9]*)(([0-9,]*[0-9]+)(.[0-9]+)?)([Ee][+-]?[0-9]+)?([^0-9]*)$"),function(){function n(t){this.ranArray=[],this.boundedEvents={},!m(t)&&(this.context=t)}return n.prototype.on=function(t,e,i,r){if(!m(e)){var s=i||this.context;if(this.notExist(t))return void(this.boundedEvents[""+t]=[{handler:e,context:s,id:r}]);m(r)?this.isHandlerPresent(this.boundedEvents[""+t],e)||this.boundedEvents[""+t].push({handler:e,context:s}):-1===this.ranArray.indexOf(r)&&(this.ranArray.push(r),this.boundedEvents[""+t].push({handler:e,context:s,id:r}))}},n.prototype.off=function(t,e,i){if(!this.notExist(t)){var r=Y(t,this.boundedEvents);if(e){for(var s=0;s1&&(_.fractionDigits=parseInt(P[2],10)),_}function f(T,P,_,B){var j=B?{}:{nlead:"",nend:""},Q=T.match(n.customRegex);if(Q){B||(j.nlead=g(Q[1],_),j.nend=g(Q[10],_),j.groupPattern=Q[4]);var oe=Q[7];if(oe&&P){var ue=oe.match(t);j.minimumFraction=m(ue)?0:ue.length,j.maximumFraction=oe.length-1}}return j}function g(T,P){return T?(T=T.replace(n.defaultCurrency,P),""===P?T.trim():T):""}function v(T,P,_,B){return B?"$":Y("currencies."+P+(_?"."+_:".symbol"),T)||Y("currencies."+P+".symbol-alt-narrow",T)||"$"}function S(T,P,_){var B={type:"decimal",minimumFractionDigits:0,maximumFractionDigits:0},j=T.match(n.customRegex);if(m(j)||""===j[5]&&"N/A"!==T)return B.type=void 0,B;B.nlead=j[1],B.nend=j[10];var Q=j[6],oe=!!Q.match(/ $/g),ue=-1!==Q.replace(/ $/g,"").indexOf(" ");B.useGrouping=-1!==Q.indexOf(",")||ue,Q=Q.replace(/,/g,"");var pe=j[7];if(-1!==Q.indexOf("0")&&(B.minimumIntegerDigits=Q.length-Q.indexOf("0")),m(pe)||(B.minimumFractionDigits=pe.lastIndexOf("0"),B.maximumFractionDigits=pe.lastIndexOf("#"),-1===B.minimumFractionDigits&&(B.minimumFractionDigits=0),(-1===B.maximumFractionDigits||B.maximumFractionDigitsQ.lastIndexOf("'"))){B[""+a[parseInt(j.toString(),10)]]=Q.substr(0,oe)+_+Q.substr(oe+1),B[""+a[""+P]]=!0,B.type=B.isCurrency?"currency":"percent";break}}return B}function C(T,P){if(-1!==T.indexOf(",")){var _=T.split(",");T=_[0]+Y("numberMapper.numberSymbols.group",P)+_[1].replace(".",Y("numberMapper.numberSymbols.decimal",P))}else T=T.replace(".",Y("numberMapper.numberSymbols.decimal",P));return T}function A(T,P,_){T+=".";for(var B=0;B0;Q-=3)T=","+_[Q-2]+_[Q-1]+_[parseInt(Q.toString(),10)]+T;return T=T.slice(1),P[1]?T+"."+P[1]:T}n.dateParseRegex=/([a-z])\1*|'([^']|'')+'|''|./gi,n.basicPatterns=["short","medium","long","full"],n.defaultObject={dates:{calendars:{gregorian:{months:{"stand-alone":{abbreviated:{1:"Jan",2:"Feb",3:"Mar",4:"Apr",5:"May",6:"Jun",7:"Jul",8:"Aug",9:"Sep",10:"Oct",11:"Nov",12:"Dec"},narrow:{1:"J",2:"F",3:"M",4:"A",5:"M",6:"J",7:"J",8:"A",9:"S",10:"O",11:"N",12:"D"},wide:{1:"January",2:"February",3:"March",4:"April",5:"May",6:"June",7:"July",8:"August",9:"September",10:"October",11:"November",12:"December"}}},days:{"stand-alone":{abbreviated:{sun:"Sun",mon:"Mon",tue:"Tue",wed:"Wed",thu:"Thu",fri:"Fri",sat:"Sat"},narrow:{sun:"S",mon:"M",tue:"T",wed:"W",thu:"T",fri:"F",sat:"S"},short:{sun:"Su",mon:"Mo",tue:"Tu",wed:"We",thu:"Th",fri:"Fr",sat:"Sa"},wide:{sun:"Sunday",mon:"Monday",tue:"Tuesday",wed:"Wednesday",thu:"Thursday",fri:"Friday",sat:"Saturday"}}},dayPeriods:{format:{wide:{am:"AM",pm:"PM"}}},eras:{eraNames:{0:"Before Christ","0-alt-variant":"Before Common Era",1:"Anno Domini","1-alt-variant":"Common Era"},eraAbbr:{0:"BC","0-alt-variant":"BCE",1:"AD","1-alt-variant":"CE"},eraNarrow:{0:"B","0-alt-variant":"BCE",1:"A","1-alt-variant":"CE"}},dateFormats:{full:"EEEE, MMMM d, y",long:"MMMM d, y",medium:"MMM d, y",short:"M/d/yy"},timeFormats:{full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},dateTimeFormats:{full:"{1} 'at' {0}",long:"{1} 'at' {0}",medium:"{1}, {0}",short:"{1}, {0}",availableFormats:{d:"d",E:"ccc",Ed:"d E",Ehm:"E h:mm a",EHm:"E HH:mm",Ehms:"E h:mm:ss a",EHms:"E HH:mm:ss",Gy:"y G",GyMMM:"MMM y G",GyMMMd:"MMM d, y G",GyMMMEd:"E, MMM d, y G",h:"h a",H:"HH",hm:"h:mm a",Hm:"HH:mm",hms:"h:mm:ss a",Hms:"HH:mm:ss",hmsv:"h:mm:ss a v",Hmsv:"HH:mm:ss v",hmv:"h:mm a v",Hmv:"HH:mm v",M:"L",Md:"M/d",MEd:"E, M/d",MMM:"LLL",MMMd:"MMM d",MMMEd:"E, MMM d",MMMMd:"MMMM d",ms:"mm:ss",y:"y",yM:"M/y",yMd:"M/d/y",yMEd:"E, M/d/y",yMMM:"MMM y",yMMMd:"MMM d, y",yMMMEd:"E, MMM d, y",yMMMM:"MMMM y"}}},islamic:{months:{"stand-alone":{abbreviated:{1:"Muh.",2:"Saf.",3:"Rab. I",4:"Rab. II",5:"Jum. I",6:"Jum. II",7:"Raj.",8:"Sha.",9:"Ram.",10:"Shaw.",11:"Dhu\u02bbl-Q.",12:"Dhu\u02bbl-H."},narrow:{1:"1",2:"2",3:"3",4:"4",5:"5",6:"6",7:"7",8:"8",9:"9",10:"10",11:"11",12:"12"},wide:{1:"Muharram",2:"Safar",3:"Rabi\u02bb I",4:"Rabi\u02bb II",5:"Jumada I",6:"Jumada II",7:"Rajab",8:"Sha\u02bbban",9:"Ramadan",10:"Shawwal",11:"Dhu\u02bbl-Qi\u02bbdah",12:"Dhu\u02bbl-Hijjah"}}},days:{"stand-alone":{abbreviated:{sun:"Sun",mon:"Mon",tue:"Tue",wed:"Wed",thu:"Thu",fri:"Fri",sat:"Sat"},narrow:{sun:"S",mon:"M",tue:"T",wed:"W",thu:"T",fri:"F",sat:"S"},short:{sun:"Su",mon:"Mo",tue:"Tu",wed:"We",thu:"Th",fri:"Fr",sat:"Sa"},wide:{sun:"Sunday",mon:"Monday",tue:"Tuesday",wed:"Wednesday",thu:"Thursday",fri:"Friday",sat:"Saturday"}}},dayPeriods:{format:{wide:{am:"AM",pm:"PM"}}},eras:{eraNames:{0:"AH"},eraAbbr:{0:"AH"},eraNarrow:{0:"AH"}},dateFormats:{full:"EEEE, MMMM d, y G",long:"MMMM d, y G",medium:"MMM d, y G",short:"M/d/y GGGGG"},timeFormats:{full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},dateTimeFormats:{full:"{1} 'at' {0}",long:"{1} 'at' {0}",medium:"{1}, {0}",short:"{1}, {0}",availableFormats:{d:"d",E:"ccc",Ed:"d E",Ehm:"E h:mm a",EHm:"E HH:mm",Ehms:"E h:mm:ss a",EHms:"E HH:mm:ss",Gy:"y G",GyMMM:"MMM y G",GyMMMd:"MMM d, y G",GyMMMEd:"E, MMM d, y G",h:"h a",H:"HH",hm:"h:mm a",Hm:"HH:mm",hms:"h:mm:ss a",Hms:"HH:mm:ss",M:"L",Md:"M/d",MEd:"E, M/d",MMM:"LLL",MMMd:"MMM d",MMMEd:"E, MMM d",MMMMd:"MMMM d",ms:"mm:ss",y:"y G",yyyy:"y G",yyyyM:"M/y GGGGG",yyyyMd:"M/d/y GGGGG",yyyyMEd:"E, M/d/y GGGGG",yyyyMMM:"MMM y G",yyyyMMMd:"MMM d, y G",yyyyMMMEd:"E, MMM d, y G",yyyyMMMM:"MMMM y G",yyyyQQQ:"QQQ y G",yyyyQQQQ:"QQQQ y G"}}}},timeZoneNames:{hourFormat:"+HH:mm;-HH:mm",gmtFormat:"GMT{0}",gmtZeroFormat:"GMT"}},numbers:{currencies:{USD:{displayName:"US Dollar",symbol:"$","symbol-alt-narrow":"$"},EUR:{displayName:"Euro",symbol:"\u20ac","symbol-alt-narrow":"\u20ac"},GBP:{displayName:"British Pound","symbol-alt-narrow":"\xa3"}},defaultNumberingSystem:"latn",minimumGroupingDigits:"1","symbols-numberSystem-latn":{decimal:".",group:",",list:";",percentSign:"%",plusSign:"+",minusSign:"-",exponential:"E",superscriptingExponent:"\xd7",perMille:"\u2030",infinity:"\u221e",nan:"NaN",timeSeparator:":"},"decimalFormats-numberSystem-latn":{standard:"#,##0.###"},"percentFormats-numberSystem-latn":{standard:"#,##0%"},"currencyFormats-numberSystem-latn":{standard:"\xa4#,##0.00",accounting:"\xa4#,##0.00;(\xa4#,##0.00)"},"scientificFormats-numberSystem-latn":{standard:"#E0"}}},n.blazorDefaultObject={numbers:{mapper:{0:"0",1:"1",2:"2",3:"3",4:"4",5:"5",6:"6",7:"7",8:"8",9:"9"},mapperDigits:"0123456789",numberSymbols:{decimal:".",group:",",plusSign:"+",minusSign:"-",percentSign:"%",nan:"NaN",timeSeparator:":",infinity:"\u221e"},timeSeparator:":",currencySymbol:"$",currencypData:{nlead:"$",nend:"",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},percentpData:{nlead:"",nend:"%",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},percentnData:{nlead:"-",nend:"%",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},currencynData:{nlead:"($",nend:")",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},decimalnData:{nlead:"-",nend:"",groupData:{primary:3},maximumFraction:2,minimumFraction:2},decimalpData:{nlead:"",nend:"",groupData:{primary:3},maximumFraction:2,minimumFraction:2}},dates:{dayPeriods:{am:"AM",pm:"PM"},dateSeperator:"/",days:{abbreviated:{sun:"Sun",mon:"Mon",tue:"Tue",wed:"Wed",thu:"Thu",fri:"Fri",sat:"Sat"},short:{sun:"Su",mon:"Mo",tue:"Tu",wed:"We",thu:"Th",fri:"Fr",sat:"Sa"},wide:{sun:"Sunday",mon:"Monday",tue:"Tuesday",wed:"Wednesday",thu:"Thursday",fri:"Friday",sat:"Saturday"}},months:{abbreviated:{1:"Jan",2:"Feb",3:"Mar",4:"Apr",5:"May",6:"Jun",7:"Jul",8:"Aug",9:"Sep",10:"Oct",11:"Nov",12:"Dec"},wide:{1:"January",2:"February",3:"March",4:"April",5:"May",6:"June",7:"July",8:"August",9:"September",10:"October",11:"November",12:"December"}},eras:{1:"AD"}}},n.monthIndex={3:"abbreviated",4:"wide",5:"narrow",1:"abbreviated"},n.month="months",n.days="days",n.patternMatcher={C:"currency",P:"percent",N:"decimal",A:"currency",E:"scientific"},n.getResultantPattern=l,n.getDependables=h,n.getSymbolPattern=c,n.ConvertDateToWeekFormat=d,n.compareBlazorDateFormats=u,n.getProperNumericSkeleton=p,n.getFormatData=f,n.changeCurrencySymbol=g,n.getCurrencySymbol=v,n.customFormat=function y(T,P,_){for(var B={},j=T.split(";"),Q=["pData","nData","zeroData"],oe=0;oe1,pe.nData=ce()?Y(De.type+"nData",oe):f(ot[1]||"-"+ot[0],!0,Ie),pe.pData=ce()?Y(De.type+"pData",oe):f(ot[0],!1,Ie),!Me[2]&&!P.minimumFractionDigits&&!P.maximumFractionDigits&&(ue=f(Ve.split(";")[0],!0,"",!0).minimumFraction)}if(n.formatRegex.test(P.format)||!P.format){if(ze(Q,p(P.format||"N")),Q.custom=!1,$e="###0",(Q.fractionDigits||P.minimumFractionDigits||P.maximumFractionDigits||ue)&&(Q.fractionDigits&&(P.minimumFractionDigits=P.maximumFractionDigits=Q.fractionDigits),$e=A($e,ue||Q.fractionDigits||P.minimumFractionDigits||0,P.maximumFractionDigits||0)),P.minimumIntegerDigits&&($e=x($e,P.minimumIntegerDigits)),P.useGrouping&&($e=R($e)),"currency"===Q.type||Q.type&&ce()){ce()&&"currency"!==Q.type&&(pe.pData=Y(Q.type+"pData",oe),pe.nData=Y(Q.type+"nData",oe));var hr=$e;$e=pe.pData.nlead+hr+pe.pData.nend,(pe.hasNegativePattern||ce())&&($e+=";"+pe.nData.nlead+hr+pe.nData.nend)}"percent"===Q.type&&!ce()&&($e+=" %")}else $e=P.format.replace(/'/g,'"');return Object.keys(xe).length>0&&($e=B?$e:C($e,xe)),$e},n.fractionDigitsPattern=A,n.minimumIntegerPattern=x,n.groupingPattern=R,n.getWeekData=function L(T,P){var _="sun",B=Y("supplemental.weekData.firstDay",P),j=T;return/en-/.test(j)&&(j=j.slice(3)),j=j.slice(0,2).toUpperCase()+j.substr(2),B&&(_=B[""+j]||B[j.slice(0,2)]||"sun"),o[""+_]},n.replaceBlazorCurrency=function O(T,P,_){var B=function p$(n){return Y(n||"",u$)}(_);if(P!==B)for(var j=0,Q=T;j=0?_:_+7;var j=Math.floor((T.getTime()-P.getTime()-6e4*(T.getTimezoneOffset()-P.getTimezoneOffset()))/864e5)+1;if(_<4){if((B=Math.floor((j+_-1)/7)+1)>52){var oe=new Date(T.getFullYear()+1,0,1).getDay();B=(oe=oe>=0?oe:oe+7)<4?1:53}}else B=Math.floor((j+_-1)/7);return B}}(ut||(ut={}));var rp=function(){function n(t,e,i){this.type="GET",this.emitError=!0,"string"==typeof t?(this.url=t,this.type=m(e)?this.type:e.toUpperCase(),this.contentType=i):Aa(t)&&Object.keys(t).length>0&&Nn(this,t),this.contentType=m(this.contentType)?"application/json; charset=utf-8":this.contentType}return n.prototype.send=function(t){var e=this,i={"application/json":"json","multipart/form-data":"formData","application/octet-stream":"blob","application/x-www-form-urlencoded":"formData"};try{m(this.fetchRequest)&&"GET"===this.type?this.fetchRequest=new Request(this.url,{method:this.type}):m(this.fetchRequest)&&(this.data=m(t)?this.data:t,this.fetchRequest=new Request(this.url,{method:this.type,headers:{"Content-Type":this.contentType},body:this.data}));var r={cancel:!1,fetchRequest:this.fetchRequest};return this.triggerEvent(this.beforeSend,r),r.cancel?null:(this.fetchResponse=fetch(this.fetchRequest),this.fetchResponse.then(function(s){if(e.triggerEvent(e.onLoad,s),!s.ok)throw s;for(var o="text",a=0,l=Object.keys(i);a-1},n.getValue=function(t,e){var i=typeof window<"u"?window.browserDetails:{};return typeof navigator<"u"&&"MacIntel"===navigator.platform&&navigator.maxTouchPoints>1&&!0===n.isTouch&&!gC.CHROME.test(navigator.userAgent)&&(i.isIos=!0,i.isDevice=!0,i.isTouch=!0,i.isPointer=!0),typeof window<"u"&&window.Capacitor&&"ios"===window.Capacitor.getPlatform()&&(i.isPointer=!1),typeof i[""+t]>"u"?i[""+t]=e.test(n.userAgent):i[""+t]},Object.defineProperty(n,"userAgent",{get:function(){return n.uA},set:function(t){n.uA=t,window.browserDetails={}},enumerable:!0,configurable:!0}),Object.defineProperty(n,"info",{get:function(){return st(window.browserDetails.info)?window.browserDetails.info=n.extractBrowserDetail():window.browserDetails.info},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isIE",{get:function(){return n.getValue("isIE",A$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isTouch",{get:function(){return st(window.browserDetails.isTouch)?window.browserDetails.isTouch="ontouchstart"in window.navigator||window&&window.navigator&&window.navigator.maxTouchPoints>0||"ontouchstart"in window:window.browserDetails.isTouch},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isPointer",{get:function(){return st(window.browserDetails.isPointer)?window.browserDetails.isPointer="pointerEnabled"in window.navigator:window.browserDetails.isPointer},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isMSPointer",{get:function(){return st(window.browserDetails.isMSPointer)?window.browserDetails.isMSPointer="msPointerEnabled"in window.navigator:window.browserDetails.isMSPointer},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isDevice",{get:function(){return n.getValue("isDevice",T$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isIos",{get:function(){return n.getValue("isIos",N$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isIos7",{get:function(){return n.getValue("isIos7",O$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isAndroid",{get:function(){return n.getValue("isAndroid",k$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isWebView",{get:function(){return st(window.browserDetails.isWebView)&&(window.browserDetails.isWebView=!(st(window.cordova)&&st(window.PhoneGap)&&st(window.phonegap)&&"object"!==window.forge)),window.browserDetails.isWebView},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isWindows",{get:function(){return n.getValue("isWindows",P$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"touchStartEvent",{get:function(){return st(window.browserDetails.touchStartEvent)?window.browserDetails.touchStartEvent=n.getTouchStartEvent():window.browserDetails.touchStartEvent},enumerable:!0,configurable:!0}),Object.defineProperty(n,"touchMoveEvent",{get:function(){return st(window.browserDetails.touchMoveEvent)?window.browserDetails.touchMoveEvent=n.getTouchMoveEvent():window.browserDetails.touchMoveEvent},enumerable:!0,configurable:!0}),Object.defineProperty(n,"touchEndEvent",{get:function(){return st(window.browserDetails.touchEndEvent)?window.browserDetails.touchEndEvent=n.getTouchEndEvent():window.browserDetails.touchEndEvent},enumerable:!0,configurable:!0}),Object.defineProperty(n,"touchCancelEvent",{get:function(){return st(window.browserDetails.touchCancelEvent)?window.browserDetails.touchCancelEvent=n.getTouchCancelEvent():window.browserDetails.touchCancelEvent},enumerable:!0,configurable:!0}),n.uA=typeof navigator<"u"?navigator.userAgent:"",n}(),E=function(){function n(){}return n.addOrGetEventData=function(t){return"__eventList"in t?t.__eventList.events:(t.__eventList={},t.__eventList.events=[])},n.add=function(t,e,i,r,s){var a,o=n.addOrGetEventData(t);a=s?function l$(n,t){var e;return function(){for(var i=this,r=[],s=0;s"u"||(e.innerHTML=t.innerHTML?t.innerHTML:"",void 0!==t.className&&(e.className=t.className),void 0!==t.id&&(e.id=t.id),void 0!==t.styles&&e.setAttribute("style",t.styles),void 0!==t.attrs&&Fe(e,t.attrs)),e}function V(n,t){for(var e=Vz(t),i=RegExp,r=0,s=n;r0}function pl(n,t,e){for(var i=document.createDocumentFragment(),r=0,s=n;r0;)i.appendChild(n[0]);else for(var r=0,s=n;r-1&&!r[parseInt(s.toString(),10)].match(/\[.*\]/)){var o=r[parseInt(s.toString(),10)].split("#");if(o[1].match(/^\d/)||o[1].match(t)){var a=r[parseInt(s.toString(),10)].split(".");a[0]=a[0].replace(/#/,"[id='")+"']",r[parseInt(s.toString(),10)]=a.join(".")}}e[parseInt(i.toString(),10)]=r.join(" ")}return e.join(",")}return n}function J(n,t){var e=n;if("function"==typeof e.closest)return e.closest(t);for(;e&&1===e.nodeType;){if(vC(e,t))return e;e=e.parentNode}return null}function je(n,t){void 0!==t&&Object.keys(t).forEach(function(e){n.style[""+e]=t[""+e]})}function vC(n,t){var e=n.matches||n.msMatchesSelector||n.webkitMatchesSelector;return e?e.call(n,t):-1!==[].indexOf.call(document.querySelectorAll(t),n)}var H$=new RegExp("]"),ah=function(){function n(t,e){this.isRendered=!1,this.isComplexArraySetter=!1,this.isServerRendered=!1,this.allowServerDataBinding=!0,this.isProtectedOnChange=!0,this.properties={},this.changedProperties={},this.oldProperties={},this.bulkChanges={},this.refreshing=!1,this.ignoreCollectionWatch=!1,this.finalUpdate=function(){},this.childChangedProperties={},this.modelObserver=new Tg(this),st(e)||(this.element="string"==typeof e?document.querySelector(e):e,m(this.element)||(this.isProtectedOnChange=!1,this.addInstance())),st(t)||this.setProperties(t,!0),this.isDestroyed=!1}return n.prototype.setProperties=function(t,e){var i=this.isProtectedOnChange;this.isProtectedOnChange=!!e,Nn(this,t),!0!==e?(Nn(this.changedProperties,t),this.dataBind()):ce()&&this.isRendered&&this.serverDataBind(t),this.finalUpdate(),this.changedProperties={},this.oldProperties={},this.isProtectedOnChange=i},n.callChildDataBind=function(t,e){for(var r=0,s=Object.keys(t);r=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Hs=function(n){function t(i){var r=n.call(this,i,void 0)||this;return r.easing={ease:"cubic-bezier(0.250, 0.100, 0.250, 1.000)",linear:"cubic-bezier(0.250, 0.250, 0.750, 0.750)",easeIn:"cubic-bezier(0.420, 0.000, 1.000, 1.000)",easeOut:"cubic-bezier(0.000, 0.000, 0.580, 1.000)",easeInOut:"cubic-bezier(0.420, 0.000, 0.580, 1.000)",elasticInOut:"cubic-bezier(0.5,-0.58,0.38,1.81)",elasticIn:"cubic-bezier(0.17,0.67,0.59,1.81)",elasticOut:"cubic-bezier(0.7,-0.75,0.99,1.01)"},r}var e;return X$(t,n),e=t,t.prototype.animate=function(i,r){var s=this.getModel(r=r||{});if("string"==typeof i)for(var a=0,l=Array.prototype.slice.call(we(i,document));a0?r-1:0,i+=e=-1!==e?"-"+e:"-"+r}return this.controlParent!==this.parentObj&&(i=this.parentObj.getParentKey()+"."+this.propName+e),i},n}(),J$=["grid","pivotview","treegrid","spreadsheet","rangeNavigator","DocumentEditor","listbox","inplaceeditor","PdfViewer","richtexteditor","DashboardLayout","chart","stockChart","circulargauge","diagram","heatmap","lineargauge","maps","slider","smithchart","barcode","sparkline","treemap","bulletChart","kanban","daterangepicker","schedule","gantt","signature","query-builder","drop-down-tree","carousel","filemanager","uploader","accordion","tab","treeview"],tR=[115,121,110,99,102,117,115,105,111,110,46,105,115,76,105,99,86,97,108,105,100,97,116,101,100],iR=function(){function n(t){this.isValidated=!1,this.isLicensed=!0,this.version="27",this.platform=/JavaScript|ASPNET|ASPNETCORE|ASPNETMVC|FileFormats|essentialstudio/i,this.errors={noLicense:"This application was built using a trial version of Syncfusion Essential Studio. To remove the license validation message permanently, a valid license key must be included.",trailExpired:"This application was built using a trial version of Syncfusion Essential Studio. To remove the license validation message permanently, a valid license key must be included.",versionMismatched:"The included Syncfusion license key is invalid.",platformMismatched:"The included Syncfusion license key is invalid.",invalidKey:"The included Syncfusion license key is invalid."},this.manager=function(){var e=null;return{setKey:function i(s){e=s},getKey:function r(){return e}}}(),this.npxManager=function(){return{getKey:function i(){return"npxKeyReplace"}}}(),this.manager.setKey(t)}return n.prototype.validate=function(){if(!this.isValidated&&tp&&!Y(x0(tR),tp)&&!Y("Blazor",tp)){var i=void 0,r=void 0;if(this.manager&&this.manager.getKey()||this.npxManager&&"npxKeyReplace"!==this.npxManager.getKey()){var s=this.getInfoFromKey();if(s&&s.length)for(var o=0,a=s;o"+i+' Claim your FREE account\n
have a Syncfusion account? Sign In
\n
\n ';if(typeof document<"u"&&!m(document)){var t=mi("div",{innerHTML:n});document.body.appendChild(t)}}(),oR=!0),this.render(),this.mount?this.accessMount():this.trigger("created")}},t.prototype.renderComplete=function(e){ce()&&window.sfBlazor.renderComplete(this.element,e),this.isRendered=!0},t.prototype.dataBind=function(){this.injectModules(),n.prototype.dataBind.call(this)},t.prototype.on=function(e,i,r){if("string"==typeof e)this.localObserver.on(e,i,r);else for(var s=0,o=e;s=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},rZ={left:0,top:0,bottom:0,right:0},bC={isDragged:!1},nZ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return aR(t,n),gr([I(0)],t.prototype,"left",void 0),gr([I(0)],t.prototype,"top",void 0),t}(Ee),op=function(n){function t(i,r){var s=n.call(this,r,i)||this;return s.dragLimit=e.getDefaultPosition(),s.borderWidth=e.getDefaultPosition(),s.padding=e.getDefaultPosition(),s.diffX=0,s.prevLeft=0,s.prevTop=0,s.dragProcessStarted=!1,s.eleTop=0,s.tapHoldTimer=0,s.externalInitialize=!1,s.diffY=0,s.parentScrollX=0,s.parentScrollY=0,s.droppables={},s.bind(),s}var e;return aR(t,n),e=t,t.prototype.bind=function(){this.toggleEvents(),X.isIE&&V([this.element],"e-block-touch"),this.droppables[this.scope]={}},t.getDefaultPosition=function(){return ze({},rZ)},t.prototype.toggleEvents=function(i){var r;st(this.handle)||(r=U(this.handle,this.element));var s=this.enableTapHold&&X.isDevice&&X.isTouch?this.mobileInitialize:this.initialize;i?E.remove(r||this.element,X.isSafari()?"touchstart":X.touchStartEvent,s):E.add(r||this.element,X.isSafari()?"touchstart":X.touchStartEvent,s,this)},t.prototype.mobileInitialize=function(i){var r=this,s=i.currentTarget;this.tapHoldTimer=setTimeout(function(){r.externalInitialize=!0,r.removeTapholdTimer(),r.initialize(i,s)},this.tapHoldThreshold),E.add(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.removeTapholdTimer,this),E.add(document,X.isSafari()?"touchend":X.touchEndEvent,this.removeTapholdTimer,this)},t.prototype.removeTapholdTimer=function(){clearTimeout(this.tapHoldTimer),E.remove(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.removeTapholdTimer),E.remove(document,X.isSafari()?"touchend":X.touchEndEvent,this.removeTapholdTimer)},t.prototype.getScrollableParent=function(i,r){return m(i)?null:i[{vertical:"scrollHeight",horizontal:"scrollWidth"}[""+r]]>i[{vertical:"clientHeight",horizontal:"clientWidth"}[""+r]]&&("vertical"===r?i.scrollTop>0:i.scrollLeft>0)?("vertical"===r?(this.parentScrollY=this.parentScrollY+(0===this.parentScrollY?i.scrollTop:i.scrollTop-this.parentScrollY),this.tempScrollHeight=i.scrollHeight):(this.parentScrollX=this.parentScrollX+(0===this.parentScrollX?i.scrollLeft:i.scrollLeft-this.parentScrollX),this.tempScrollWidth=i.scrollWidth),m(i)?i:this.getScrollableParent(i.parentNode,r)):this.getScrollableParent(i.parentNode,r)},t.prototype.getScrollableValues=function(){this.parentScrollX=0,this.parentScrollY=0,this.element.classList.contains("e-dialog")&&this.element.classList.contains("e-dlg-modal"),this.getScrollableParent(this.element.parentNode,"vertical"),this.getScrollableParent(this.element.parentNode,"horizontal")},t.prototype.initialize=function(i,r){if(this.currentStateTarget=i.target,!this.isDragStarted()){if(this.isDragStarted(!0),this.externalInitialize=!1,this.target=i.currentTarget||r,this.dragProcessStarted=!1,this.abort){var s=this.abort;"string"==typeof s&&(s=[s]);for(var o=0;o=this.distance||this.externalInitialize){var p=this.getHelperElement(i);if(!p||m(p))return;r&&i.preventDefault();var f=this.helperElement=p;if(this.parentClientRect=this.calculateParentPosition(f.offsetParent),this.dragStart){var v={event:i,element:l,target:this.getProperTargetElement(i),bindEvents:ce()?this.bindDragEvents.bind(this):null,dragElement:f};this.trigger("dragStart",v)}this.dragArea?this.setDragArea():(this.dragLimit={left:0,right:0,bottom:0,top:0},this.borderWidth={top:0,left:0}),o={left:this.position.left-this.parentClientRect.left,top:this.position.top-this.parentClientRect.top},this.clone&&!this.enableTailMode&&(this.diffX=this.position.left-this.offset.left,this.diffY=this.position.top-this.offset.top),this.getScrollableValues();var y=getComputedStyle(l),S=parseFloat(y.marginTop);this.clone&&0!==S&&(o.top+=S),this.eleTop=isNaN(parseFloat(y.top))?0:parseFloat(y.top)-this.offset.top,this.enableScrollHandler&&!this.clone&&(o.top-=this.parentScrollY,o.left-=this.parentScrollX);var b=this.getProcessedPositionValue({top:o.top-this.diffY+"px",left:o.left-this.diffX+"px"});this.dragArea&&"string"!=typeof this.dragArea&&this.dragArea.classList.contains("e-kanban-content")&&"relative"===this.dragArea.style.position&&(o.top+=this.dragArea.scrollTop),this.dragElePosition={top:o.top,left:o.left},je(f,this.getDragPosition({position:"absolute",left:b.left,top:b.top})),E.remove(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.intDragStart),E.remove(document,X.isSafari()?"touchend":X.touchEndEvent,this.intDestroy),ce()||this.bindDragEvents(f)}}},t.prototype.bindDragEvents=function(i){Tr(i)?(E.add(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.intDrag,this),E.add(document,X.isSafari()?"touchend":X.touchEndEvent,this.intDragStop,this),this.setGlobalDroppables(!1,this.element,i)):(this.toggleEvents(),document.body.classList.remove("e-prevent-select"))},t.prototype.elementInViewport=function(i){for(this.top=i.offsetTop,this.left=i.offsetLeft,this.width=i.offsetWidth,this.height=i.offsetHeight;i.offsetParent;)this.top+=(i=i.offsetParent).offsetTop,this.left+=i.offsetLeft;return this.top>=window.pageYOffset&&this.left>=window.pageXOffset&&this.top+this.height<=window.pageYOffset+window.innerHeight&&this.left+this.width<=window.pageXOffset+window.innerWidth},t.prototype.getProcessedPositionValue=function(i){return this.queryPositionInfo?this.queryPositionInfo(i):i},t.prototype.calculateParentPosition=function(i){if(m(i))return{left:0,top:0};var r=i.getBoundingClientRect(),s=getComputedStyle(i);return{left:r.left+window.pageXOffset-parseInt(s.marginLeft,10),top:r.top+window.pageYOffset-parseInt(s.marginTop,10)}},t.prototype.intDrag=function(i){if(st(i.changedTouches)||1===i.changedTouches.length){var r,s;this.clone&&i.changedTouches&&X.isDevice&&X.isTouch&&i.preventDefault(),this.position=this.getMousePosition(i,this.isDragScroll);var o=this.getDocumentWidthHeight("Height");oy&&y>0?this.dragLimit.left:this.dragLimit.right+window.pageXOffset0?y-(y-this.dragLimit.right)+window.pageXOffset-M:y<0?this.dragLimit.left:y}if(this.pageY!==v||this.skipDistanceCheck){var w=d.offsetHeight+(parseFloat(b.marginTop)+parseFloat(b.marginBottom));s=this.dragLimit.top>S&&S>0?this.dragLimit.top:this.dragLimit.bottom+window.pageYOffset0?S-(S-this.dragLimit.bottom)+window.pageYOffset-w:S<0?this.dragLimit.top:S}}else r=y,s=S;var A,x,C=p+this.borderWidth.top,D=u+this.borderWidth.left;if(this.dragProcessStarted&&(m(s)&&(s=this.prevTop),m(r)&&(r=this.prevLeft)),this.helperElement.classList.contains("e-treeview"))this.dragArea?(this.dragLimit.top=this.clone?this.dragLimit.top:0,A=s-C<0?this.dragLimit.top:s-this.borderWidth.top,x=r-D<0?this.dragLimit.left:r-this.borderWidth.left):(A=s-this.borderWidth.top,x=r-this.borderWidth.left);else if(this.dragArea){var R=this.helperElement.classList.contains("e-dialog");this.dragLimit.top=this.clone?this.dragLimit.top:0,A=s-C<0?this.dragLimit.top:s-C,x=r-D<0?R?r-(D-this.borderWidth.left):this.dragElePosition.left:r-D}else A=s-C,x=r-D;var L=parseFloat(getComputedStyle(this.element).marginTop);if(L>0&&(this.clone&&(A+=L,S<0&&(L+S>=0?A=L+S:A-=L),this.dragArea&&(A=this.dragLimit.bottom=0){var O=this.dragLimit.top+S-C;O+L+C<0?A-=L+C:A=O}else A-=L+C;this.dragArea&&this.helperElement.classList.contains("e-treeview")&&(A=A+(w=d.offsetHeight+(parseFloat(b.marginTop)+parseFloat(b.marginBottom)))>this.dragLimit.bottom?this.dragLimit.bottom-w:A),this.enableScrollHandler&&!this.clone&&(A-=this.parentScrollY,x-=this.parentScrollX),this.dragArea&&"string"!=typeof this.dragArea&&this.dragArea.classList.contains("e-kanban-content")&&"relative"===this.dragArea.style.position&&(A+=this.dragArea.scrollTop);var N=this.getProcessedPositionValue({top:A+"px",left:x+"px"});this.isPreventScroll&&(N=this.getProcessedPositionValue({top:this.position.top-this.parentClientRect.top-2+"px",left:this.position.left-this.parentClientRect.left-2+"px"})),je(d,this.getDragPosition(N)),!this.elementInViewport(d)&&this.enableAutoScroll&&!this.helperElement.classList.contains("e-treeview")&&this.helperElement.scrollIntoView();var T=document.querySelectorAll(":hover");if(this.enableAutoScroll&&this.helperElement.classList.contains("e-treeview")){0===T.length&&(T=this.getPathElements(i));var P=this.getScrollParent(T,!1);this.elementInViewport(this.helperElement)?this.getScrollPosition(P,A):this.elementInViewport(this.helperElement)||(0===(T=[].slice.call(document.querySelectorAll(":hover"))).length&&(T=this.getPathElements(i)),P=this.getScrollParent(T,!0),this.getScrollPosition(P,A))}this.dragProcessStarted=!0,this.prevLeft=r,this.prevTop=s,this.position.left=r,this.position.top=s,this.pageX=g,this.pageY=v}},t.prototype.getScrollParent=function(i,r){for(var o,s=r?i.reverse():i,a=s.length-1;a>=0;a--)if(("auto"===(o=window.getComputedStyle(s[parseInt(a.toString(),10)])["overflow-y"])||"scroll"===o)&&s[parseInt(a.toString(),10)].scrollHeight>s[parseInt(a.toString(),10)].clientHeight)return s[parseInt(a.toString(),10)];if("visible"===(o=window.getComputedStyle(document.scrollingElement)["overflow-y"]))return document.scrollingElement.style.overflow="auto",document.scrollingElement},t.prototype.getScrollPosition=function(i,r){if(i&&i===document.scrollingElement)i.clientHeight+document.scrollingElement.scrollTop-this.helperElement.clientHeightr?i.scrollTop+=this.helperElement.clientHeight:i.scrollTop>r-this.helperElement.clientHeight&&(i.scrollTop-=this.helperElement.clientHeight);else if(i&&i!==document.scrollingElement){var s=document.scrollingElement.scrollTop,o=this.helperElement.clientHeight;i.clientHeight+i.getBoundingClientRect().top-o+sr-o-s&&(i.scrollTop-=this.helperElement.clientHeight)}},t.prototype.getPathElements=function(i){return document.elementsFromPoint(i.clientX>0?i.clientX:0,i.clientY>0?i.clientY:0)},t.prototype.triggerOutFunction=function(i,r){this.hoverObject.instance.intOut(i,r.target),this.hoverObject.instance.dragData[this.scope]=null,this.hoverObject=null},t.prototype.getDragPosition=function(i){var r=ze({},i);return this.axis&&("x"===this.axis?delete r.top:"y"===this.axis&&delete r.left),r},t.prototype.getDocumentWidthHeight=function(i){var r=document.body,s=document.documentElement;return Math.max(r["scroll"+i],s["scroll"+i],r["offset"+i],s["offset"+i],s["client"+i])},t.prototype.intDragStop=function(i){if(this.dragProcessStarted=!1,st(i.changedTouches)||1===i.changedTouches.length){if(-1!==["touchend","pointerup","mouseup"].indexOf(i.type)){if(this.dragStop){var s=this.getProperTargetElement(i);this.trigger("dragStop",{event:i,element:this.element,target:s,helper:this.helperElement})}this.intDestroy(i)}else this.element.setAttribute("aria-grabbed","false");var o=this.checkTargetElement(i);o.target&&o.instance&&(o.instance.dragStopCalled=!0,o.instance.dragData[this.scope]=this.droppables[this.scope],o.instance.intDrop(i,o.target)),this.setGlobalDroppables(!0),document.body.classList.remove("e-prevent-select")}},t.prototype.intDestroy=function(i){this.dragProcessStarted=!1,this.toggleEvents(),document.body.classList.remove("e-prevent-select"),this.element.setAttribute("aria-grabbed","false"),E.remove(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.intDragStart),E.remove(document,X.isSafari()?"touchend":X.touchEndEvent,this.intDragStop),E.remove(document,X.isSafari()?"touchend":X.touchEndEvent,this.intDestroy),E.remove(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.intDrag),this.isDragStarted()&&this.isDragStarted(!0)},t.prototype.onPropertyChanged=function(i,r){},t.prototype.getModuleName=function(){return"draggable"},t.prototype.isDragStarted=function(i){return i&&(bC.isDragged=!bC.isDragged),bC.isDragged},t.prototype.setDragArea=function(){var i,r,a,s=0,o=0;if(a="string"==typeof this.dragArea?U(this.dragArea):this.dragArea){var h=a.getBoundingClientRect();i=a.scrollWidth?a.scrollWidth:h.right-h.left,r=a.scrollHeight?this.dragArea&&!m(this.helperElement)&&this.helperElement.classList.contains("e-treeview")?a.clientHeight:a.scrollHeight:h.bottom-h.top;for(var c=["Top","Left","Bottom","Right"],d=getComputedStyle(a),u=0;u12;return w0(i.target,this.helperElement)||-1!==i.type.indexOf("touch")||a?(this.helperElement.style.pointerEvents="none",s=document.elementFromPoint(r.clientX,r.clientY),this.helperElement.style.pointerEvents=o):s=i.target,s},t.prototype.currentStateCheck=function(i,r){return m(this.currentStateTarget)||this.currentStateTarget===i?m(r)?i:r:this.currentStateTarget},t.prototype.getMousePosition=function(i,r){var a,l,s=void 0!==i.srcElement?i.srcElement:i.target,o=this.getCoordinates(i),h=m(s.offsetParent);if(r?(a=this.clone?o.pageX:o.pageX+(h?0:s.offsetParent.scrollLeft)-this.relativeXPosition,l=this.clone?o.pageY:o.pageY+(h?0:s.offsetParent.scrollTop)-this.relativeYPosition):(a=this.clone?o.pageX:o.pageX+window.pageXOffset-this.relativeXPosition,l=this.clone?o.pageY:o.pageY+window.pageYOffset-this.relativeYPosition),document.scrollingElement&&!r&&!this.clone){var c=document.scrollingElement;a=c.scrollWidth>0&&c.scrollWidth>c.clientWidth&&c.scrollLeft>0?a-c.scrollLeft:a,l=c.scrollHeight>0&&c.scrollHeight>c.clientHeight&&c.scrollTop>0?l-c.scrollTop:l}return{left:a-(this.margin.left+this.cursorAt.left),top:l-(this.margin.top+this.cursorAt.top)}},t.prototype.getCoordinates=function(i){return i.type.indexOf("touch")>-1?i.changedTouches[0]:i},t.prototype.getHelperElement=function(i){var r;return this.clone?this.helper?r=this.helper({sender:i,element:this.target}):(r=mi("div",{className:"e-drag-helper e-block-touch",innerHTML:"Draggable"}),document.body.appendChild(r)):r=this.element,r},t.prototype.setGlobalDroppables=function(i,r,s){this.droppables[this.scope]=i?null:{draggable:r,helper:s,draggedElement:this.element}},t.prototype.checkTargetElement=function(i){var r=this.getProperTargetElement(i),s=this.getDropInstance(r);if(!s&&r&&!m(r.parentNode)){var o=J(r.parentNode,".e-droppable")||r.parentElement;o&&(s=this.getDropInstance(o))}return{target:r,instance:s}},t.prototype.getDropInstance=function(i){var s,o=i&&i.ej2_instances;if(o)for(var a=0,l=o;a=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},lR=function(n){function t(e,i){var r=n.call(this,i,e)||this;return r.mouseOver=!1,r.dragData={},r.dragStopCalled=!1,r.bind(),r}return sZ(t,n),t.prototype.bind=function(){this.wireEvents()},t.prototype.wireEvents=function(){E.add(this.element,X.isSafari()?"touchend":X.touchEndEvent,this.intDrop,this)},t.prototype.onPropertyChanged=function(e,i){},t.prototype.getModuleName=function(){return"droppable"},t.prototype.intOver=function(e,i){this.mouseOver||(this.trigger("over",{event:e,target:i,dragData:this.dragData[this.scope]}),this.mouseOver=!0)},t.prototype.intOut=function(e,i){this.mouseOver&&(this.trigger("out",{evt:e,target:i}),this.mouseOver=!1)},t.prototype.intDrop=function(e,i){if(this.dragStopCalled){this.dragStopCalled=!1;var a,r=!0,s=this.dragData[this.scope],o=!!s&&s.helper&&Tr(s.helper);o&&(a=this.isDropArea(e,s.helper,i),this.accept&&(r=vC(s.helper,this.accept))),o&&this.drop&&a.canDrop&&r&&this.trigger("drop",{event:e,target:a.target,droppedElement:s.helper,dragData:s}),this.mouseOver=!1}},t.prototype.isDropArea=function(e,i,r){var s={canDrop:!0,target:r||e.target},o="touchend"===e.type;if(o||s.target===i){i.style.display="none";var a=o?e.changedTouches[0]:e,l=document.elementFromPoint(a.clientX,a.clientY);s.canDrop=!1,s.canDrop=w0(l,this.element),s.canDrop&&(s.target=l),i.style.display=""}return s},t.prototype.destroy=function(){E.remove(this.element,X.isSafari()?"touchend":X.touchEndEvent,this.intDrop),n.prototype.destroy.call(this)},ap([I()],t.prototype,"accept",void 0),ap([I("default")],t.prototype,"scope",void 0),ap([H()],t.prototype,"drop",void 0),ap([H()],t.prototype,"over",void 0),ap([H()],t.prototype,"out",void 0),ap([Ft],t)}(ah),ho=function(){function n(t,e,i){this.controlName=t,this.localeStrings=e,this.setLocale(i||"en-US")}return n.prototype.setLocale=function(t){var e=this.intGetControlConstant(n.locale,t);this.currentLocale=e||this.localeStrings},n.load=function(t){this.locale=ze(this.locale,t,{},!0)},n.prototype.getConstant=function(t){return m(this.currentLocale[""+t])?this.localeStrings[""+t]||"":this.currentLocale[""+t]},n.prototype.intGetControlConstant=function(t,e){return t[""+e]?t[""+e][this.controlName]:null},n.locale={},n}(),hR=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),hh=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},lZ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return hR(t,n),hh([I(50)],t.prototype,"swipeThresholdDistance",void 0),t}(Ee),hZ=/(Up|Down)/,Fs=function(n){function t(e,i){var r=n.call(this,i,e)||this;return r.touchAction=!0,r.tapCount=0,r.startEvent=function(s){if(!0===r.touchAction){var o=r.updateChangeTouches(s);void 0!==s.changedTouches&&(r.touchAction=!1),r.isTouchMoved=!1,r.movedDirection="",r.startPoint=r.lastMovedPoint={clientX:o.clientX,clientY:o.clientY},r.startEventData=o,r.hScrollLocked=r.vScrollLocked=!1,r.tStampStart=Date.now(),r.timeOutTapHold=setTimeout(function(){r.tapHoldEvent(s)},r.tapHoldThreshold),E.add(r.element,X.touchMoveEvent,r.moveEvent,r),E.add(r.element,X.touchEndEvent,r.endEvent,r),E.add(r.element,X.touchCancelEvent,r.cancelEvent,r)}},r.moveEvent=function(s){var o=r.updateChangeTouches(s);r.movedPoint=o,r.isTouchMoved=!(o.clientX===r.startPoint.clientX&&o.clientY===r.startPoint.clientY);var a={};r.isTouchMoved&&(clearTimeout(r.timeOutTapHold),r.calcScrollPoints(s),a=ze(a,{},{startEvents:r.startEventData,originalEvent:s,startX:r.startPoint.clientX,startY:r.startPoint.clientY,distanceX:r.distanceX,distanceY:r.distanceY,scrollDirection:r.scrollDirection,velocity:r.getVelocity(o)}),r.trigger("scroll",a),r.lastMovedPoint={clientX:o.clientX,clientY:o.clientY})},r.cancelEvent=function(s){clearTimeout(r.timeOutTapHold),clearTimeout(r.timeOutTap),r.tapCount=0,r.swipeFn(s),E.remove(r.element,X.touchCancelEvent,r.cancelEvent)},r.endEvent=function(s){r.swipeFn(s),r.isTouchMoved||"function"==typeof r.tap&&(r.trigger("tap",{originalEvent:s,tapCount:++r.tapCount}),r.timeOutTap=setTimeout(function(){r.tapCount=0},r.tapThreshold)),r.modeclear()},r.swipeFn=function(s){clearTimeout(r.timeOutTapHold),clearTimeout(r.timeOutTap);var o=r.updateChangeTouches(s),a=o.clientX-r.startPoint.clientX,l=o.clientY-r.startPoint.clientY;a=Math.floor(a<0?-1*a:a),l=Math.floor(l<0?-1*l:a),r.isTouchMoved=a>1||l>1,/Firefox/.test(X.userAgent)&&0===o.clientX&&0===o.clientY&&"mouseup"===s.type&&(r.isTouchMoved=!1),r.endPoint=o,r.calcPoints(s);var c={originalEvent:s,startEvents:r.startEventData,startX:r.startPoint.clientX,startY:r.startPoint.clientY,distanceX:r.distanceX,distanceY:r.distanceY,swipeDirection:r.movedDirection,velocity:r.getVelocity(o)};if(r.isTouchMoved){var d=r.swipeSettings.swipeThresholdDistance,u=ze(void 0,r.defaultArgs,c),p=!1,f=r.element,g=r.isScrollable(f),v=hZ.test(r.movedDirection);(dthis.distanceY?i.clientX>this.startPoint.clientX?"Right":"Left":i.clientYthis.distanceY||!0===this.hScrollLocked)&&!1===this.vScrollLocked?(this.scrollDirection=i.clientX>this.lastMovedPoint.clientX?"Right":"Left",this.hScrollLocked=!0):(this.scrollDirection=i.clientY=e[r[0]+s[0]]},t.prototype.updateChangeTouches=function(e){return e.changedTouches&&0!==e.changedTouches.length?e.changedTouches[0]:e},hh([H()],t.prototype,"tap",void 0),hh([H()],t.prototype,"tapHold",void 0),hh([H()],t.prototype,"swipe",void 0),hh([H()],t.prototype,"scroll",void 0),hh([I(350)],t.prototype,"tapThreshold",void 0),hh([I(750)],t.prototype,"tapHoldThreshold",void 0),hh([re({},lZ)],t.prototype,"swipeSettings",void 0),hh([Ft],t)}(ah),cZ=new RegExp("\\n|\\r|\\s\\s+","g"),dZ=new RegExp(/'|"/g),uZ=new RegExp("if ?\\("),pZ=new RegExp("else if ?\\("),cR=new RegExp("else"),fZ=new RegExp("for ?\\("),dR=new RegExp("(/if|/for)"),gZ=new RegExp("\\((.*)\\)",""),MC=new RegExp("^[0-9]+$","g"),vZ=new RegExp("[\\w\"'.\\s+]+","g"),mZ=new RegExp('"(.*?)"',"g"),yZ=new RegExp("[\\w\"'@#$.\\s-+]+","g"),uR=new RegExp("\\${([^}]*)}","g"),SZ=/^\..*/gm,wC=/\\/gi,IZ=/\\\\/gi,bZ=new RegExp("[\\w\"'@#$.\\s+]+","g"),MZ=/\window\./gm;function lp(n,t,e,i,r){return!t||MC.test(n)||-1!==i.indexOf(n.split(".")[0])||r||"true"===n||"false"===n?n:e+"."+n}function CC(n,t,e,i){return t&&!MC.test(n)&&-1===i.indexOf(n.split(".")[0])?e+'["'+n:n}function pR(n){return n.match(IZ)?n:n.replace(wC,"\\\\")}function fR(n,t,e,i){if(n=n.trim(),/\window\./gm.test(n))return n;var s=/'|"/gm;return/@|\$|#/gm.test(n)&&(n=CC(n,-1===e.indexOf(n),t,e)+'"]'),SZ.test(n)?function EZ(n,t,e,i){return!t||MC.test(n)||-1!==i.indexOf(n.split(".")[0])||/^\..*/gm.test(n)?n:e+"."+n}(n,!s.test(n)&&-1===e.indexOf(n),t,e):lp(n,!s.test(n)&&-1===e.indexOf(n),t,e,i)}var DZ=/^[\n\r.]+0&&t.forEach(function(e){he(e)})},n.removeJsEvents=function(){var t=this.wrapElement.querySelectorAll("["+vR.join("],[")+"]");t.length>0&&t.forEach(function(e){vR.forEach(function(i){e.hasAttribute(i)&&e.removeAttribute(i)})})},n.removeXssAttrs=function(){var t=this;this.removeAttrs.forEach(function(e,i){var r=t.wrapElement.querySelectorAll(e.selector);r.length>0&&r.forEach("a[href]"===e.selector?function(s){-1!==s.getAttribute(e.attribute).replace(/\t|\s|&/,"").indexOf("javascript:alert")&&s.removeAttribute(e.attribute)}:function(s){s.removeAttribute(e.attribute)})})},n}();function kZ(n){for(var t,e=n.childNodes,i=0;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Jo_RTL=(new Tg,"e-rtl"),ys=function(n){function t(e,i){return n.call(this,e,i)||this}return RZ(t,n),t.prototype.preRender=function(){},t.prototype.render=function(){this.initialize(),this.removeRippleEffect=function ms(n,t,e){var i=function q$(n){return{selector:n&&n.selector?n.selector:null,ignore:n&&n.ignore?n.ignore:null,rippleFlag:n&&n.rippleFlag,isCenterRipple:n&&n.isCenterRipple,duration:n&&n.duration?n.duration:350}}(t);return!1===i.rippleFlag||void 0===i.rippleFlag&&!Zo?function(){}:(n.setAttribute("data-ripple","true"),E.add(n,"mousedown",Zz,{parent:n,rippleOptions:i}),E.add(n,"mouseup",Jz,{parent:n,rippleOptions:i,done:e}),E.add(n,"mouseleave",sp,{parent:n,rippleOptions:i}),X.isPointer&&E.add(n,"transitionend",sp,{parent:n,rippleOptions:i}),function(){n.removeAttribute("data-ripple"),E.remove(n,"mousedown",Zz),E.remove(n,"mouseup",Jz),E.remove(n,"mouseleave",sp),E.remove(n,"transitionend",sp)})}(this.element,{selector:".e-btn"}),this.renderComplete()},t.prototype.initialize=function(){if(this.cssClass&&V([this.element],this.cssClass.replace(/\s+/g," ").trim().split(" ")),this.isPrimary&&this.element.classList.add("e-primary"),!ce()||ce()&&"progress-btn"!==this.getModuleName()){if(this.content){var e=this.enableHtmlSanitizer?Ti.sanitize(this.content):this.content;this.element.innerHTML=e}this.setIconCss()}this.enableRtl&&this.element.classList.add(Jo_RTL),this.disabled?this.controlStatus(this.disabled):this.wireEvents()},t.prototype.controlStatus=function(e){this.element.disabled=e},t.prototype.setIconCss=function(){if(this.iconCss){var e=this.createElement("span",{className:"e-btn-icon "+this.iconCss});this.element.textContent.trim()?(e.classList.add("e-icon-"+this.iconPosition.toLowerCase()),("Top"===this.iconPosition||"Bottom"===this.iconPosition)&&this.element.classList.add("e-"+this.iconPosition.toLowerCase()+"-icon-btn")):this.element.classList.add("e-icon-btn");var i=this.element.childNodes[0];!i||"Left"!==this.iconPosition&&"Top"!==this.iconPosition?this.element.appendChild(e):this.element.insertBefore(e,i)}},t.prototype.wireEvents=function(){this.isToggle&&E.add(this.element,"click",this.btnClickHandler,this)},t.prototype.unWireEvents=function(){this.isToggle&&E.remove(this.element,"click",this.btnClickHandler)},t.prototype.btnClickHandler=function(){this.element.classList.contains("e-active")?this.element.classList.remove("e-active"):this.element.classList.add("e-active")},t.prototype.destroy=function(){var e=["e-primary",Jo_RTL,"e-icon-btn","e-success","e-info","e-danger","e-warning","e-flat","e-outline","e-small","e-bigger","e-active","e-round","e-top-icon-btn","e-bottom-icon-btn"];this.cssClass&&(e=e.concat(this.cssClass.split(" "))),n.prototype.destroy.call(this),K([this.element],e),this.element.getAttribute("class")||this.element.removeAttribute("class"),this.disabled&&this.element.removeAttribute("disabled"),this.content&&(this.element.innerHTML=this.element.innerHTML.replace(this.content,""));var i=this.element.querySelector("span.e-btn-icon");i&&he(i),this.unWireEvents(),Zo&&this.removeRippleEffect()},t.prototype.getModuleName=function(){return"btn"},t.prototype.getPersistData=function(){return this.addOnPersist([])},t.Inject=function(){},t.prototype.onPropertyChanged=function(e,i){for(var r=this.element.querySelector("span.e-btn-icon"),s=0,o=Object.keys(e);s=ad.width?ad.width:0;return vl.right+QR()-n}function hE(){return B0()+vl.width/2}function cE(n,t,e,i){if(void 0===t&&(t=null),void 0===e&&(e={X:!1,Y:!1}),!e.Y&&!e.X)return{left:0,top:0};var r=n.getBoundingClientRect();if(uo=t,sc=n.ownerDocument,i||(i=is(n,"left","top")),e.X){var s=uo?ZR():i4(),o=gE(),a=vE(),l=o-i.left,h=i.left+r.width-a;r.width>s?i.left=l>0&&h<=0?a-r.width:h>0&&l<=0?o:l>h?a-r.width:o:l>0?i.left+=l:h>0&&(i.left-=h)}if(e.Y){var c=uo?JR():t4(),d=fE(),u=mE(),p=d-i.top,f=i.top+r.height-u;r.height>c?i.top=p>0&&f<=0?u-r.height:f>0&&p<=0?d:p>f?u-r.height:d:p>0?i.top+=p:f>0&&(i.top-=f)}return i}function oc(n,t,e,i){void 0===t&&(t=null);var r=is(n,"left","top");e&&(r.left=e),i&&(r.top=i);var s=[];uo=t,sc=n.ownerDocument;var o=n.getBoundingClientRect(),l=r.left,h=r.left+o.width,d=pE(r.top,r.top+o.height),u=XR(l,h);return d.topSide&&s.push("top"),u.rightSide&&s.push("right"),u.leftSide&&s.push("left"),d.bottomSide&&s.push("bottom"),s}function uJ(n,t,e,i,r,s,o,a,l){if(void 0===o&&(o=null),void 0===a&&(a={X:!0,Y:!0}),t&&n&&r&&s&&(a.X||a.Y)){var d,h={TL:null,TR:null,BL:null,BR:null},c={TL:null,TR:null,BL:null,BR:null};if("none"===window.getComputedStyle(n).display){var u=n.style.visibility;n.style.visibility="hidden",n.style.display="block",d=n.getBoundingClientRect(),n.style.removeProperty("display"),n.style.visibility=u}else d=n.getBoundingClientRect();var p={posX:r,posY:s,offsetX:e,offsetY:i,position:{left:0,top:0}};uo=o,sc=t.ownerDocument,function fJ(n,t,e,i,r){e.position=is(n,e.posX,e.posY,i,r),t.TL=is(n,"left","top",i,r),t.TR=is(n,"right","top",i,r),t.BR=is(n,"left","bottom",i,r),t.BL=is(n,"right","bottom",i,r)}(t,h,p,l,d),uE(c,p,d),a.X&&qR(t,c,h,p,d,!0),a.Y&&h.TL.top>-1&&$R(t,c,h,p,d,!0),function pJ(n,t,e){var i=0,r=0;if(null!=n.offsetParent&&("absolute"===getComputedStyle(n.offsetParent).position||"relative"===getComputedStyle(n.offsetParent).position)){var s=is(n.offsetParent,"left","top",!1,e);i=s.left,r=s.top}var o=1,a=1,l=GR(n);if(l){var h=getComputedStyle(l).transform;if("none"!==h){var c=new DOMMatrix(h);o=c.a,a=c.d}if("none"!==getComputedStyle(l).zoom){var u=dE(document.body);o*=u,a*=u}}n.style.top=t.position.top/a+t.offsetY-r/a+"px",n.style.left=t.position.left/o+t.offsetX-i/o+"px"}(n,p,d)}}function dE(n){var t=getComputedStyle(n).zoom;return parseFloat(t)||1}function GR(n){for(;n;){var t=window.getComputedStyle(n).transform,e=dE(document.body);if(t&&"none"!==t||e&&1!==e)return n;if(n===document.body)return null;n=n.offsetParent||n.parentElement}return null}function uE(n,t,e){n.TL={top:t.position.top+t.offsetY,left:t.position.left+t.offsetX},n.TR={top:n.TL.top,left:n.TL.left+e.width},n.BL={top:n.TL.top+e.height,left:n.TL.left},n.BR={top:n.TL.top+e.height,left:n.TL.left+e.width}}function XR(n,t){var e=!1,i=!1;return n-_0()vE()&&(i=!0),{leftSide:e,rightSide:i}}function qR(n,t,e,i,r,s){var o=XR(t.TL.left,t.TR.left),a=pE(t.TL.top,t.BL.top);e.TL.left-_0()<=gE()&&(o.leftSide=!1),e.TR.left>vE()&&(o.rightSide=!1),(o.leftSide&&!o.rightSide||!o.leftSide&&o.rightSide)&&(i.posX="right"===i.posX?"left":"right",i.offsetX=i.offsetX+r.width,i.offsetX=-1*i.offsetX,i.position=is(n,i.posX,i.posY,!1),uE(t,i,r),s&&qR(n,t,e,i,r,!1),!o.leftSide&&o.rightSide&&a.bottomSide&&(i.offsetX=0))}function $R(n,t,e,i,r,s){var o=pE(t.TL.top,t.BL.top);e.TL.top-F0()<=fE()&&(o.topSide=!1),e.BL.top>=mE()&&n.getBoundingClientRect().bottommE()&&(i=!0),{topSide:e,bottomSide:i}}function ZR(){return uo.getBoundingClientRect().width}function JR(){return uo.getBoundingClientRect().height}function KR(){return uo.getBoundingClientRect().left}function e4(){return uo.getBoundingClientRect().top}function fE(){return uo?e4():0}function gE(){return uo?KR():0}function vE(){return uo?_0()+KR()+ZR():_0()+i4()}function mE(){return uo?F0()+e4()+JR():F0()+t4()}function F0(){return sc.documentElement.scrollTop||sc.body.scrollTop}function _0(){return sc.documentElement.scrollLeft||sc.body.scrollLeft}function t4(){return window.innerHeight}function i4(){var n=window.innerWidth,t=document.documentElement.getBoundingClientRect();return n-(n-(m(document.documentElement)?0:t.width))}function r4(){uo=null,sc=null}var n4=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),bn=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},s4=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return n4(t,n),bn([I("left")],t.prototype,"X",void 0),bn([I("top")],t.prototype,"Y",void 0),t}(Ee),Gn_OPEN="e-popup-open",Gn_CLOSE="e-popup-close",ac=function(n){function t(e,i){return n.call(this,i,e)||this}return n4(t,n),t.prototype.onPropertyChanged=function(e,i){for(var r=0,s=Object.keys(e);r0&&c.left>0&&c.right>0&&c.bottom>0}var s=i.getBoundingClientRect();return!(r.bottoms.bottom||r.right>s.right||r.leftr.top?this.element.style.top="0px":s.bottomr.left&&(this.element.style.left=parseInt(this.element.style.left,10)+(s.left-r.left)+"px"))}},t.prototype.checkCollision=function(){var e=this.collision.X,i=this.collision.Y;"none"===e&&"none"===i||("flip"===e&&"flip"===i?this.callFlip({X:!0,Y:!0}):"fit"===e&&"fit"===i?this.callFit({X:!0,Y:!0}):("flip"===e?this.callFlip({X:!0,Y:!1}):"flip"===i&&this.callFlip({Y:!0,X:!1}),"fit"===e?this.callFit({X:!0,Y:!1}):"fit"===i&&this.callFit({X:!1,Y:!0})))},t.prototype.show=function(e,i){var r=this;if(this.getRelateToElement().classList.contains("e-filemanager")&&(this.fmDialogContainer=this.element.getElementsByClassName("e-file-select-wrap")[0]),this.wireEvents(),!m(this.fmDialogContainer)&&X.isIos&&(this.fmDialogContainer.style.display="block"),1e3===this.zIndex||!m(i)){var o=m(i)?this.element:i;this.zIndex=lc(o),je(this.element,{zIndex:this.zIndex})}e=m(e)||"object"!=typeof e?this.showAnimation:e,("none"!==this.collision.X||"none"!==this.collision.Y)&&(K([this.element],Gn_CLOSE),V([this.element],Gn_OPEN),this.checkCollision(),K([this.element],Gn_OPEN),V([this.element],Gn_CLOSE)),m(e)?(K([this.element],Gn_CLOSE),V([this.element],Gn_OPEN),this.trigger("open")):(e.begin=function(){r.isDestroyed||(K([r.element],Gn_CLOSE),V([r.element],Gn_OPEN))},e.end=function(){r.isDestroyed||r.trigger("open")},new Hs(e).animate(this.element))},t.prototype.hide=function(e){var i=this;e=m(e)||"object"!=typeof e?this.hideAnimation:e,m(e)?(K([this.element],Gn_OPEN),V([this.element],Gn_CLOSE),this.trigger("close")):(e.end=function(){i.isDestroyed||(K([i.element],Gn_OPEN),V([i.element],Gn_CLOSE),i.trigger("close"))},new Hs(e).animate(this.element)),this.unwireEvents()},t.prototype.getScrollableParent=function(e){return this.checkFixedParent(e),function yE(n,t){for(var e=getComputedStyle(n),i=[],r=/(auto|scroll)/,s=n.parentElement;s&&"HTML"!==s.tagName;){var o=getComputedStyle(s);!("absolute"===e.position&&"static"===o.position)&&r.test(o.overflow+o.overflowY+o.overflowX)&&i.push(s),s=s.parentElement}return t||i.push(document),i}(e,this.fixedParent)},t.prototype.checkFixedParent=function(e){for(var i=e.parentElement;i&&"HTML"!==i.tagName;){var r=getComputedStyle(i);("fixed"===r.position||"sticky"===r.position)&&!m(this.element)&&this.element.offsetParent&&"BODY"===this.element.offsetParent.tagName&&"hidden"!==getComputedStyle(this.element.offsetParent).overflow&&(this.element.style.top=window.scrollY>parseInt(this.element.style.top,10)?Re(window.scrollY-parseInt(this.element.style.top,10)):Re(parseInt(this.element.style.top,10)-window.scrollY),this.element.style.position="fixed",this.fixedParent=!0),i=i.parentElement,!m(this.element)&&m(this.element.offsetParent)&&"fixed"===r.position&&"fixed"===this.element.style.position&&(this.fixedParent=!0)}},bn([I("auto")],t.prototype,"height",void 0),bn([I("auto")],t.prototype,"width",void 0),bn([I(null)],t.prototype,"content",void 0),bn([I("container")],t.prototype,"targetType",void 0),bn([I(null)],t.prototype,"viewPortElement",void 0),bn([I({X:"none",Y:"none"})],t.prototype,"collision",void 0),bn([I("")],t.prototype,"relateTo",void 0),bn([re({},s4)],t.prototype,"position",void 0),bn([I(0)],t.prototype,"offsetX",void 0),bn([I(0)],t.prototype,"offsetY",void 0),bn([I(1e3)],t.prototype,"zIndex",void 0),bn([I(!1)],t.prototype,"enableRtl",void 0),bn([I("reposition")],t.prototype,"actionOnScroll",void 0),bn([I(null)],t.prototype,"showAnimation",void 0),bn([I(null)],t.prototype,"hideAnimation",void 0),bn([H()],t.prototype,"open",void 0),bn([H()],t.prototype,"close",void 0),bn([H()],t.prototype,"targetExitViewport",void 0),bn([Ft],t)}(yi);function lc(n){for(var t=n.parentElement,e=[];t&&"BODY"!==t.tagName;){var i=document.defaultView.getComputedStyle(t,null).getPropertyValue("z-index"),r=document.defaultView.getComputedStyle(t,null).getPropertyValue("position");"auto"!==i&&"static"!==r&&e.push(i),t=t.parentElement}for(var s=[],o=0;o2147483647?2147483647:c}var _i,Oa,hp,fh,ME,gh,$t,vh,SE=["north-west","north","north-east","west","east","south-west","south","south-east"],jg="e-resize-handle",hc="e-focused-handle",gJ="e-dlg-resizable",o4=["e-restrict-left"],a4="e-resize-viewport",vJ=["north","west","east","south"],IE=0,bE=0,l4=0,h4=0,Vg=0,Wg=0,Yg=null,wE=null,CE=null,U0=!0,c4=0,EE=!0;function yJ(n){DE();var t=mi("span",{attrs:{unselectable:"on",contenteditable:"false"}});t.setAttribute("class","e-dialog-border-resize e-"+n),"south"===n&&(t.style.height="2px",t.style.width="100%",t.style.bottom="0px",t.style.left="0px"),"north"===n&&(t.style.height="2px",t.style.width="100%",t.style.top="0px",t.style.left="0px"),"east"===n&&(t.style.height="100%",t.style.width="2px",t.style.right="0px",t.style.top="0px"),"west"===n&&(t.style.height="100%",t.style.width="2px",t.style.left="0px",t.style.top="0px"),_i.appendChild(t)}function d4(n){var t;return m(n)||(t="string"==typeof n?document.querySelector(n):n),t}function u4(n){for(var t=n||this,e=_i.querySelectorAll("."+jg),i=0;i-1?"mouse":"touch"}function f4(n){if(n.preventDefault(),_i=n.target.parentElement,DE(),Vg=n.pageX,Wg=n.pageY,n.target.classList.add(hc),m(Yg)||!0!==Yg(n,this)){this.targetEle&&_i&&_i.querySelector("."+gJ)&&($t="body"===this.target?null:this.targetEle,gh=this.targetEle.clientWidth,fh=this.targetEle.clientHeight);var e=m($t)?document:$t;E.add(e,"mousemove",Qg,this),E.add(document,"mouseup",j0,this);for(var i=0;i=0||s.top<0)&&(e=!0):e=!0;var a=bE+(r-Wg);a=a>hp?a:hp;var l=0;m($t)||(l=o.top);var h=m($t)?0:$t.offsetHeight-$t.clientHeight,c=s.top-l-h/2;if(c=c<0?0:c,s.top>0&&c+a>fh){if(e=!1,_i.classList.contains(a4))return;_i.style.height=fh-parseInt(c.toString(),10)+"px"}else{var d=0;if(e){s.top<0&&t+(s.height+s.top)>0&&a+(d=s.top)<=30&&(a=s.height-(s.height+s.top)+30),a+s.top>=fh&&(_i.style.height=s.height+(t-(s.height+s.top))+"px");var u=m($t)?d:c;a>=hp&&a+u<=fh&&(_i.style.height=a+"px")}}}function TE(n){var e,t=!1,i="mouse"===p4(n.type)?n.pageY:n.touches[0].pageY,r=cc(_i),s=m($t)?0:$t.offsetHeight-$t.clientHeight;m($t)||(e=cc($t)),(!m($t)&&r.top-e.top>0||m($t)&&i>0||!m($t)&&Math.floor(r.top-e.top+r.height+(e.bottom-r.bottom))-s<=fh)&&(t=!0);var o=bE-(i-Wg);if(t&&o>=hp&&o<=fh){var a=0;m($t)||(a=e.top);var l=h4-a+(i-Wg);l=l>0?l:1,_i.style.height=o+"px",_i.style.top=l+"px"}}function AE(n){var i,t=document.documentElement.clientWidth,e=!1;m($t)||(i=cc($t));var r="mouse"===p4(n.type)?n.pageX:n.touches[0].pageX,s=cc(_i),o=m($t)?0:$t.offsetWidth-$t.clientWidth,a=m($t)?0:i.left,l=m($t)?0:i.width;m(vh)&&(m($t)?vh=t:(vh=s.left-a-o/2+s.width,vh+=l-o-vh)),(!m($t)&&Math.floor(s.left-i.left+s.width+(i.right-s.right))-o<=gh||m($t)&&r>=0)&&(e=!0);var h=IE-(r-Vg);if(U0&&(h=h>vh?vh:h),e&&h>=ME&&h<=gh){var c=0;m($t)||(c=i.left);var d=l4-c+(r-Vg);d=d>0?d:1,h!==c4&&EE&&(_i.style.width=h+"px"),U0&&(_i.style.left=d+"px",EE=1!==d)}c4=h}function LE(n){var i,t=document.documentElement.clientWidth,e=!1;m($t)||(i=cc($t));var s=(n.touches?n.changedTouches[0]:n).pageX,o=cc(_i);(!m($t)&&(o.left-i.left+o.width<=gh||o.right-i.left>=o.width)||m($t)&&t-s>0)&&(e=!0);var a=IE+(s-Vg),l=0;if(m($t)||(l=i.left),o.left-l+a>gh){if(e=!1,_i.classList.contains(a4))return;_i.style.width=gh-(o.left-l)+"px"}e&&a>=ME&&a<=gh&&(_i.style.width=a+"px")}function v4(){for(var n=_i.querySelectorAll("."+jg),t=0;t=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},wJ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return NE(t,n),Zt([I(!0)],t.prototype,"isFlat",void 0),Zt([I()],t.prototype,"buttonModel",void 0),Zt([I("Button")],t.prototype,"type",void 0),Zt([H()],t.prototype,"click",void 0),t}(Ee),CJ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return NE(t,n),Zt([I("Fade")],t.prototype,"effect",void 0),Zt([I(400)],t.prototype,"duration",void 0),Zt([I(0)],t.prototype,"delay",void 0),t}(Ee),V0="e-dialog",OE="e-rtl",kE="e-dlg-header-content",m4="e-dlg-header",W0="e-footer-content",Y0="e-dlg-modal",y4="e-icon-dlg-close",ml="e-dlg-target",ka="e-scroll-disabled",S4="e-device",Q0="e-dlg-fullscreen",I4="e-dlg-closeicon-btn",b4="e-popup-open",M4="Information",w4="e-scroll-disabled",C4="e-alert-dialog",E4="e-confirm-dialog",PE="e-dlg-resizable",cp="e-restrict-left",D4="e-resize-viewport",zE="user action",HJ=function(n){function t(e,i){var r=n.call(this,e,i)||this;return r.needsID=!0,r}return NE(t,n),t.prototype.render=function(){this.initialize(),this.initRender(),this.wireEvents(),"100%"===this.width&&(this.element.style.width=""),""!==this.minHeight&&(this.element.style.minHeight=Re(this.minHeight)),this.enableResize&&(this.setResize(),this.isModal&&(this.isModelResize=!0),"None"===this.animationSettings.effect&&this.getMinHeight()),this.renderComplete()},t.prototype.initializeValue=function(){this.dlgClosedBy=zE},t.prototype.preRender=function(){var e=this;if(this.initializeValue(),this.headerContent=null,this.allowMaxHeight=!0,this.preventVisibility=!0,this.clonedEle=this.element.cloneNode(!0),this.closeIconClickEventHandler=function(s){e.dlgClosedBy="close icon",e.hide(s)},this.dlgOverlayClickEventHandler=function(s){e.dlgClosedBy="overlayClick",s.preventFocus=!1,e.trigger("overlayClick",s,function(o){o.preventFocus||e.focusContent(),e.dlgClosedBy=zE})},this.l10n=new ho("dialog",{close:"Close"},this.locale),this.checkPositionData(),m(this.target)){var r=this.isProtectedOnChange;this.isProtectedOnChange=!0,this.target=document.body,this.isProtectedOnChange=r}},t.prototype.updatePersistData=function(){this.enablePersistence&&this.setProperties({width:parseFloat(this.element.style.width),height:parseFloat(this.element.style.height),position:{X:parseFloat(this.dragObj.element.style.left),Y:parseFloat(this.dragObj.element.style.top)}},!0)},t.prototype.isNumberValue=function(e){return/^[-+]?\d*\.?\d+$/.test(e)},t.prototype.checkPositionData=function(){if(!m(this.position)){if(!m(this.position.X)&&"number"!=typeof this.position.X&&this.isNumberValue(this.position.X)){var i=this.isProtectedOnChange;this.isProtectedOnChange=!0,this.position.X=parseFloat(this.position.X),this.isProtectedOnChange=i}m(this.position.Y)||"number"==typeof this.position.Y||this.isNumberValue(this.position.Y)&&(i=this.isProtectedOnChange,this.isProtectedOnChange=!0,this.position.Y=parseFloat(this.position.Y),this.isProtectedOnChange=i)}},t.prototype.getEle=function(e,i){for(var r=void 0,s=0;s=0&&t[e])yJ(t[e]);else if(""!==t[e].trim()){var i=mi("div",{className:"e-icons "+jg+" e-"+t[e]});_i.appendChild(i)}hp=n.minHeight,ME=n.minWidth,gh=n.maxWidth,fh=n.maxHeight,n.proxy&&n.proxy.element&&n.proxy.element.classList.contains("e-dialog")?u4(n.proxy):u4()}({element:this.element,direction:r,minHeight:parseInt(e.slice(0,i.indexOf("p")),10),maxHeight:this.targetEle.clientHeight,minWidth:parseInt(i.slice(0,i.indexOf("p")),10),maxWidth:this.targetEle.clientWidth,boundary:this.target===document.body?null:this.targetEle,resizeBegin:this.onResizeStart.bind(this),resizeComplete:this.onResizeComplete.bind(this),resizing:this.onResizing.bind(this),proxy:this}),this.wireWindowResizeEvent()}else v4(),this.unWireWindowResizeEvent(),this.element.classList.remove(this.isModal?cp:D4),this.element.classList.remove(PE)},t.prototype.getFocusElement=function(e){var r=e.querySelectorAll('input,select,textarea,button:enabled,a,[contenteditable="true"],[tabindex]');return{element:r[r.length-1]}},t.prototype.keyDown=function(e){var i=this;if(9===e.keyCode&&this.isModal){var r=void 0;m(this.btnObj)||(r=this.btnObj[this.btnObj.length-1]),m(this.btnObj)&&!m(this.ftrTemplateContent)&&(r=this.getFocusElement(this.ftrTemplateContent)),m(this.btnObj)&&m(this.ftrTemplateContent)&&!m(this.contentEle)&&(r=this.getFocusElement(this.contentEle)),!m(r)&&document.activeElement===r.element&&!e.shiftKey&&(e.preventDefault(),this.focusableElements(this.element).focus()),document.activeElement===this.focusableElements(this.element)&&e.shiftKey&&(e.preventDefault(),m(r)||r.element.focus())}var h,s=document.activeElement,o=["input","textarea"].indexOf(s.tagName.toLowerCase())>-1,a=!1;if(o||(a=s.hasAttribute("contenteditable")&&"true"===s.getAttribute("contenteditable")),27===e.keyCode&&this.closeOnEscape){this.dlgClosedBy="escape";var l=document.querySelector(".e-popup-open:not(.e-dialog)");!m(l)&&!l.classList.contains("e-toolbar-pop")||this.hide(e)}(13===e.keyCode&&!e.ctrlKey&&"textarea"!==s.tagName.toLowerCase()&&o&&!m(this.primaryButtonEle)||13===e.keyCode&&e.ctrlKey&&("textarea"===s.tagName.toLowerCase()||a)&&!m(this.primaryButtonEle))&&this.buttons.some(function(d,u){h=u;var p=d.buttonModel;return!m(p)&&!0===p.isPrimary})&&"function"==typeof this.buttons[h].click&&setTimeout(function(){i.buttons[h].click.call(i,e)})},t.prototype.initialize=function(){m(this.target)||(this.targetEle="string"==typeof this.target?document.querySelector(this.target):this.target),this.isBlazorServerRender()||V([this.element],V0),X.isDevice&&V([this.element],S4),this.isBlazorServerRender()||this.setCSSClass(),this.setMaxHeight()},t.prototype.initRender=function(){var e=this;if(this.initialRender=!0,this.isBlazorServerRender()||Fe(this.element,{role:"dialog"}),1e3===this.zIndex?(this.setzIndex(this.element,!1),this.calculatezIndex=!0):this.calculatezIndex=!1,this.setTargetContent(),""!==this.header&&!m(this.header)&&this.setHeader(),this.renderCloseIcon(),this.setContent(),""===this.footerTemplate||m(this.footerTemplate)?!m(this.buttons[0])&&!m(this.buttons[0].buttonModel)&&this.setButton():this.setFooterTemplate(),this.allowDragging&&!m(this.headerContent)&&this.setAllowDragging(),Fe(this.element,{"aria-modal":this.isModal?"true":"false"}),this.isModal&&this.setIsModal(),!0!==this.element.classList.contains(C4)&&!0!==this.element.classList.contains(E4)&&!m(this.element.parentElement)){var i=this.isModal?this.dlgContainer.parentElement:this.element.parentElement;this.refElement=this.createElement("div",{className:"e-dlg-ref-element"}),i.insertBefore(this.refElement,this.isModal?this.dlgContainer:this.element)}if(m(this.targetEle)||this.targetEle.appendChild(this.isModal?this.dlgContainer:this.element),this.popupObj=new ac(this.element,{height:this.height,width:this.width,zIndex:this.zIndex,relateTo:this.target,actionOnScroll:"none",enableRtl:this.enableRtl,open:function(o){var a={container:e.isModal?e.dlgContainer:e.element,element:e.element,target:e.target,preventFocus:!1};e.enableResize&&e.resetResizeIcon(),e.trigger("open",a,function(l){l.preventFocus||e.focusContent()})},close:function(o){e.isModal&&V([e.dlgOverlay],"e-fade"),e.unBindEvent(e.element),e.isModal&&(e.dlgContainer.style.display="none"),e.trigger("close",e.closeArgs);var a=document.activeElement;!m(a)&&!m(a.blur)&&a.blur(),!m(e.storeActiveElement)&&!m(e.storeActiveElement.focus)&&e.storeActiveElement.focus()}}),this.positionChange(),this.setEnableRTL(),this.isBlazorServerRender()||(V([this.element],"e-popup-close"),this.isModal&&this.setOverlayZindex()),this.visible){if(this.show(),this.isModal){var r=this.getTargetContainer(this.target);r instanceof Element&&"rtl"===window.getComputedStyle(r).getPropertyValue("direction")&&this.setPopupPosition()}}else this.isModal&&(this.dlgOverlay.style.display="none");this.initialRender=!1},t.prototype.getTargetContainer=function(e){var i=null;if("string"==typeof e)if(e.startsWith("#"))i=document.getElementById(e.substring(1));else if(e.startsWith(".")){var r=document.getElementsByClassName(e.substring(1));i=r.length>0?r[0]:null}else!(e instanceof HTMLElement)&&e!==document.body&&(i=document.querySelector(e));else e instanceof HTMLElement&&(i=e);return i},t.prototype.resetResizeIcon=function(){var e=this.getMinHeight();if(this.targetEle.offsetHeight0&&("function"==typeof this.buttons[e].click&&E.add(s[e],"click",this.buttons[e].click,this),"object"==typeof this.buttons[e].click&&E.add(s[e],"click",this.buttonClickHandler.bind(this,e),this)),!this.isBlazorServerRender()&&!m(this.ftrTemplateContent)&&(this.btnObj[e].appendTo(this.ftrTemplateContent.children[e]),this.buttons[e].isFlat&&this.btnObj[e].element.classList.add("e-flat"),this.primaryButtonEle=this.element.getElementsByClassName("e-primary")[0]))},t.prototype.buttonClickHandler=function(e){this.trigger("buttons["+e+"].click",{})},t.prototype.setContent=function(){this.contentEle=this.createElement("div",{className:"e-dlg-content",id:this.element.id+"_dialog-content"}),Fe(this.element,this.headerEle?{"aria-describedby":this.element.id+"_title "+this.element.id+"_dialog-content"}:{"aria-describedby":this.element.id+"_dialog-content"}),this.innerContentElement?this.contentEle.appendChild(this.innerContentElement):(!m(this.content)&&""!==this.content||!this.initialRender)&&(("string"!=typeof this.content||ce())&&this.content instanceof HTMLElement?this.contentEle.appendChild(this.content):this.setTemplate(this.content,this.contentEle,"content")),m(this.headerContent)?this.element.insertBefore(this.contentEle,this.element.children[0]):this.element.insertBefore(this.contentEle,this.element.children[1]),"auto"===this.height&&(!this.isBlazorServerRender()&&X.isIE&&""===this.element.style.width&&!m(this.width)&&(this.element.style.width=Re(this.width)),this.setMaxHeight())},t.prototype.setTemplate=function(e,i,r){var s,o,a;o=i.classList.contains(m4)?this.element.id+"header":i.classList.contains(W0)?this.element.id+"footerTemplate":this.element.id+"content",m(e.outerHTML)?("string"==typeof e||"string"!=typeof e||ce()&&!this.isStringTemplate)&&("string"==typeof e&&(e=this.sanitizeHelper(e)),this.isVue||"string"!=typeof e?(s=ri(e),a=e):i.innerHTML=e):i.appendChild(e);var l=[];if(!m(s)){for(var c=0,d=s({},this,r,o,!(ce()&&!this.isStringTemplate&&0===a.indexOf("
Blazor"))||this.isStringTemplate);c/g,"");(this.element.children.length>0||i)&&(this.innerContentElement=document.createDocumentFragment(),[].slice.call(this.element.childNodes).forEach(function(r){8!==r.nodeType&&e.innerContentElement.appendChild(r)}))}},t.prototype.setHeader=function(){this.headerEle?this.headerEle.innerHTML="":this.headerEle=this.createElement("div",{id:this.element.id+"_title",className:m4}),this.createHeaderContent(),this.headerContent.appendChild(this.headerEle),this.setTemplate(this.header,this.headerEle,"header"),Fe(this.element,{"aria-describedby":this.element.id+"_title"}),Fe(this.element,{"aria-labelledby":this.element.id+"_dialog-header"}),this.element.insertBefore(this.headerContent,this.element.children[0]),this.allowDragging&&!m(this.headerContent)&&this.setAllowDragging()},t.prototype.setFooterTemplate=function(){this.ftrTemplateContent?this.ftrTemplateContent.innerHTML="":this.ftrTemplateContent=this.createElement("div",{className:W0}),""===this.footerTemplate||m(this.footerTemplate)?this.ftrTemplateContent.innerHTML=this.buttonContent.join(""):this.setTemplate(this.footerTemplate,this.ftrTemplateContent,"footerTemplate"),this.element.appendChild(this.ftrTemplateContent)},t.prototype.createHeaderContent=function(){m(this.headerContent)&&(this.headerContent=this.createElement("div",{id:this.element.id+"_dialog-header",className:kE}))},t.prototype.renderCloseIcon=function(){this.showCloseIcon&&(this.closeIcon=this.createElement("button",{className:I4,attrs:{type:"button"}}),this.closeIconBtnObj=new ys({cssClass:"e-flat",iconCss:y4+" e-icons"}),this.closeIconTitle(),m(this.headerContent)?(this.createHeaderContent(),pl([this.closeIcon],this.headerContent),this.element.insertBefore(this.headerContent,this.element.children[0])):pl([this.closeIcon],this.headerContent),this.closeIconBtnObj.appendTo(this.closeIcon))},t.prototype.closeIconTitle=function(){this.l10n.setLocale(this.locale);var e=this.l10n.getConstant("close");this.closeIcon.setAttribute("title",e),this.closeIcon.setAttribute("aria-label",e)},t.prototype.setCSSClass=function(e){e&&(K([this.element],e.split(" ")),this.isModal&&!m(this.dlgContainer)&&K([this.dlgContainer],e.split(" "))),this.cssClass&&(V([this.element],this.cssClass.split(" ")),this.isModal&&!m(this.dlgContainer)&&V([this.dlgContainer],this.cssClass.split(" ")))},t.prototype.setIsModal=function(){this.dlgContainer=this.createElement("div",{className:"e-dlg-container"}),this.setCSSClass(),this.element.classList.remove(b4),this.element.parentNode.insertBefore(this.dlgContainer,this.element),this.dlgContainer.appendChild(this.element),V([this.element],Y0),this.dlgOverlay=this.createElement("div",{className:"e-dlg-overlay"}),this.dlgOverlay.style.zIndex=(this.zIndex-1).toString(),this.dlgContainer.appendChild(this.dlgOverlay)},t.prototype.getValidFocusNode=function(e){for(var i,r=0;r0||"a"===i.tagName.toLowerCase()&&i.hasAttribute("href"))&&i.tabIndex>-1&&!i.disabled&&!this.disableElement(i,'[disabled],[aria-disabled="true"],[type="hidden"]'))return i;i=null}return i},t.prototype.focusableElements=function(e){if(!m(e)){var r=e.querySelectorAll('input,select,textarea,button,a,[contenteditable="true"],[tabindex]');return this.getValidFocusNode(r)}return null},t.prototype.getAutoFocusNode=function(e){var i=e.querySelector("."+I4),s=e.querySelectorAll("[autofocus]"),o=this.getValidFocusNode(s);if(ce()&&(this.primaryButtonEle=this.element.getElementsByClassName("e-primary")[0]),m(o)){if(!m(o=this.focusableElements(this.contentEle)))return o;if(!m(this.primaryButtonEle))return this.element.querySelector(".e-primary")}else i=o;return i},t.prototype.disableElement=function(e,i){var r=e?e.matches||e.webkitMatchesSelector||e.msGetRegionContent:null;if(r)for(;e;e=e.parentNode)if(e instanceof Element&&r.call(e,i))return e;return null},t.prototype.focusContent=function(){var e=this.getAutoFocusNode(this.element),i=m(e)?this.element:e,r=X.userAgent;(r.indexOf("MSIE ")>0||r.indexOf("Trident/")>0)&&this.element.focus(),i.focus(),this.unBindEvent(this.element),this.bindEvent(this.element)},t.prototype.bindEvent=function(e){E.add(e,"keydown",this.keyDown,this)},t.prototype.unBindEvent=function(e){E.remove(e,"keydown",this.keyDown)},t.prototype.updateSanitizeContent=function(){this.isBlazorServerRender()||(this.contentEle.innerHTML=this.sanitizeHelper(this.content))},t.prototype.isBlazorServerRender=function(){return ce()&&this.isServerRendered},t.prototype.getModuleName=function(){return"dialog"},t.prototype.onPropertyChanged=function(e,i){if(this.element.classList.contains(V0))for(var r=0,s=Object.keys(e);r0?this.showCloseIcon||""!==this.header&&!m(this.header)?this.showCloseIcon||he(this.closeIcon):(he(this.headerContent),this.headerContent=null):(this.renderCloseIcon(),this.wireEvents());break;case"locale":this.showCloseIcon&&this.closeIconTitle();break;case"visible":this.visible?this.show():this.hide();break;case"isModal":this.updateIsModal();break;case"height":je(this.element,{height:Re(e.height)}),this.updatePersistData();break;case"width":je(this.element,{width:Re(e.width)}),this.updatePersistData();break;case"zIndex":this.popupObj.zIndex=this.zIndex,this.isModal&&this.setOverlayZindex(this.zIndex),this.element.style.zIndex!==this.zIndex.toString()&&(this.calculatezIndex=!1);break;case"cssClass":this.setCSSClass(i.cssClass);break;case"buttons":this.unWireButtonEvents(),this.destroyButtons(),m(this.ftrTemplateContent)||(he(this.ftrTemplateContent),this.ftrTemplateContent=null),this.footerTemplate="",this.setButton();break;case"allowDragging":this.allowDragging&&!m(this.headerContent)?this.setAllowDragging():this.dragObj.destroy();break;case"target":this.setTarget(e.target);break;case"position":if(this.checkPositionData(),this.isModal){var a=this.position.X,l=this.position.Y;m(i.position)||(m(i.position.X)||(a=i.position.X),m(i.position.Y)||(l=i.position.Y)),this.dlgContainer.classList.contains("e-dlg-"+a+"-"+l)&&this.dlgContainer.classList.remove("e-dlg-"+a+"-"+l)}this.positionChange(),this.updatePersistData();break;case"enableRtl":this.setEnableRTL();break;case"enableResize":this.setResize();break;case"minHeight":""!==this.minHeight&&(this.element.style.minHeight=Re(this.minHeight))}},t.prototype.setTarget=function(e){this.popupObj.relateTo=e,this.target=e,this.targetEle="string"==typeof this.target?document.querySelector(this.target):this.target,this.dragObj&&(this.dragObj.dragArea=this.targetEle),this.setMaxHeight(),this.isModal&&this.updateIsModal(),this.enableResize&&this.setResize()},t.prototype.updateIsModal=function(){if(this.element.setAttribute("aria-modal",this.isModal?"true":"false"),this.isModal)m(this.dlgOverlay)&&(this.setIsModal(),this.element.style.top="0px",this.element.style.left="0px",m(this.targetEle)||this.targetEle.appendChild(this.dlgContainer));else{for(K([this.element],Y0),K([document.body],[ml,ka]),he(this.dlgOverlay);this.dlgContainer.firstChild;)this.dlgContainer.parentElement.insertBefore(this.dlgContainer.firstChild,this.dlgContainer);this.dlgContainer.parentElement.removeChild(this.dlgContainer)}this.visible&&this.show(),this.positionChange(),this.isModal&&this.dlgOverlay&&E.add(this.dlgOverlay,"click",this.dlgOverlayClickEventHandler,this)},t.prototype.setzIndex=function(e,i){var r=this.isProtectedOnChange;this.isProtectedOnChange=!0;var s=lc(e);this.zIndex=s>this.zIndex?s:this.zIndex,this.isProtectedOnChange=r,i&&(this.popupObj.zIndex=this.zIndex)},t.prototype.windowResizeHandler=function(){(function IJ(n){gh=n})(this.targetEle.clientWidth),function bJ(n){fh=n}(this.targetEle.clientHeight),this.setMaxHeight()},t.prototype.getPersistData=function(){return this.addOnPersist(["width","height","position"])},t.prototype.removeAllChildren=function(e){for(;e.children[0];)this.removeAllChildren(e.children[0]),e.removeChild(e.children[0])},t.prototype.destroy=function(){if(!this.isDestroyed){var e=[OE,Y0,PE,cp,Q0,S4],i=["role","aria-modal","aria-labelledby","aria-describedby","aria-grabbed","tabindex","style"];K([this.targetEle],[ml,ka]),!m(this.element)&&this.element.classList.contains(Q0)&&K([document.body],[ml,ka]),this.isModal&&K([m(this.targetEle)?document.body:this.targetEle],ka),this.unWireEvents(),this.unWireButtonEvents(),this.destroyButtons(),m(this.closeIconBtnObj)||this.closeIconBtnObj.destroy(),m(this.dragObj)||this.dragObj.destroy(),!m(this.popupObj.element)&&this.popupObj.element.classList.contains("e-popup")&&this.popupObj.destroy(),K([this.element],e),!m(this.cssClass)&&""!==this.cssClass&&K([this.element],this.cssClass.split(" ")),!m(this.refElement)&&!m(this.refElement.parentElement)&&(this.refElement.parentElement.insertBefore(this.isModal?this.dlgContainer:this.element,this.refElement),he(this.refElement),this.refElement=void 0),this.isModal&&(he(this.dlgOverlay),this.dlgContainer.parentNode.insertBefore(this.element,this.dlgContainer),he(this.dlgContainer)),this.element.innerHTML=this.clonedEle.innerHTML;for(var r=0;r0&&""===this.footerTemplate&&this.ftrTemplateContent)for(var e=0;e=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},RE="e-tooltip",O4="e-icons",k4="e-tooltip-close",HE="e-tooltip-wrap",P4="e-tip-content",dp="e-arrow-tip",z4="e-arrow-tip-outer",G0="e-arrow-tip-inner",Gg="e-tip-bottom",BE="e-tip-top",R4="e-tip-left",FE="e-tip-right",_E="e-popup",Xg="e-popup-open",UE="e-popup-close",X0="e-lib",H4="e-tooltip-popup-container",VJ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return T4(t,n),Gi([I({effect:"FadeIn",duration:150,delay:0})],t.prototype,"open",void 0),Gi([I({effect:"FadeOut",duration:150,delay:0})],t.prototype,"close",void 0),t}(Ee),mh=function(n){function t(e,i){var r=n.call(this,e,i)||this;return r.mouseMoveEvent=null,r.mouseMoveTarget=null,r.containerElement=null,r.isBodyContainer=!0,r}return T4(t,n),t.prototype.initialize=function(){this.formatPosition(),V([this.element],RE)},t.prototype.formatPosition=function(){var e,i;this.position&&(0===this.position.indexOf("Top")||0===this.position.indexOf("Bottom")?(e=this.position.split(/(?=[A-Z])/),this.tooltipPositionY=e[0],this.tooltipPositionX=e[1]):(i=this.position.split(/(?=[A-Z])/),this.tooltipPositionX=i[0],this.tooltipPositionY=i[1]))},t.prototype.renderArrow=function(){this.setTipClass(this.position);var e=this.createElement("div",{className:dp+" "+this.tipClass});e.appendChild(this.createElement("div",{className:z4+" "+this.tipClass})),e.appendChild(this.createElement("div",{className:G0+" "+this.tipClass})),this.tooltipEle.appendChild(e)},t.prototype.setTipClass=function(e){this.tipClass=0===e.indexOf("Right")?R4:0===e.indexOf("Bottom")?BE:0===e.indexOf("Left")?FE:Gg},t.prototype.renderPopup=function(e){var i=this.mouseTrail?{top:0,left:0}:this.getTooltipPosition(e);this.tooltipEle.classList.remove(X0),this.popupObj=new ac(this.tooltipEle,{height:this.height,width:this.width,position:{X:i.left,Y:i.top},enableRtl:this.enableRtl,open:this.openPopupHandler.bind(this),close:this.closePopupHandler.bind(this)})},t.prototype.getScalingFactor=function(e){if(!e)return{x:1,y:1};var i={x:1,y:1},r=e.closest('[style*="transform: scale"]');if(r&&r!==this.tooltipEle&&r.contains(this.tooltipEle)){var a=window.getComputedStyle(r).getPropertyValue("transform").match(/matrix\(([^)]+)\)/)[1].split(",").map(parseFloat);i.x=a[0],i.y=a[3]}return i},t.prototype.getTooltipPosition=function(e){this.tooltipEle.style.display="block";var i=this.element.closest('[style*="zoom"]');i&&(i.contains(this.tooltipEle)||(this.tooltipEle.style.zoom=getComputedStyle(i).zoom));var r=is(e,this.tooltipPositionX,this.tooltipPositionY,!this.isBodyContainer,this.isBodyContainer?null:this.containerElement.getBoundingClientRect()),s=this.getScalingFactor(e),o=this.calculateTooltipOffset(this.position,s.x,s.y),a=this.calculateElementPosition(r,o),c=this.collisionFlipFit(e,a[0],a[1]);return c.left=c.left/s.x,c.top=c.top/s.y,this.tooltipEle.style.display="",c},t.prototype.windowResize=function(){this.reposition(this.findTarget())},t.prototype.reposition=function(e){if(this.popupObj&&e){var i=this.getTooltipPosition(e);this.popupObj.position={X:i.left,Y:i.top},this.popupObj.dataBind()}},t.prototype.openPopupHandler=function(){!this.mouseTrail&&this.needTemplateReposition()&&this.reposition(this.findTarget()),this.trigger("afterOpen",this.tooltipEventArgs),this.tooltipEventArgs=null},t.prototype.closePopupHandler=function(){this.isReact&&!("Click"===this.opensOn||"function"==typeof this.content)&&this.clearTemplate(["content"]),this.clear();var e={type:this.tooltipEventArgs.event?this.tooltipEventArgs.event.type:null,cancel:!1,target:this.tooltipEventArgs.target,event:this.tooltipEventArgs.event?this.tooltipEventArgs.event:null,element:this.tooltipEle,isInteracted:!m(this.tooltipEventArgs.event)};this.trigger("afterClose",e),e=null},t.prototype.calculateTooltipOffset=function(e,i,r){void 0===i&&(i=1),void 0===r&&(r=1);var o,a,l,h,c,d,u,p,s={top:0,left:0};if(1!==i||1!==r){var f=this.tooltipEle.getBoundingClientRect(),g=void 0;l=Math.round(f.width),h=Math.round(f.height),(c=U("."+dp,this.tooltipEle))&&(g=c.getBoundingClientRect()),o=c?Math.round(g.width):0,a=c?Math.round(g.height):0,d=this.showTipPointer?0:8,u=a/2+2+(h-this.tooltipEle.clientHeight*r),p=o/2+2+(l-this.tooltipEle.clientWidth*i)}else l=this.tooltipEle.offsetWidth,h=this.tooltipEle.offsetHeight,c=U("."+dp,this.tooltipEle),d=this.showTipPointer?0:8,u=(a=c?c.offsetHeight:0)/2+2+(this.tooltipEle.offsetHeight-this.tooltipEle.clientHeight),p=(o=c?c.offsetWidth:0)/2+2+(this.tooltipEle.offsetWidth-this.tooltipEle.clientWidth);switch(this.mouseTrail&&(d+=2),e){case"RightTop":s.left+=o+d,s.top-=h-u;break;case"RightCenter":s.left+=o+d,s.top-=h/2;break;case"RightBottom":s.left+=o+d,s.top-=u;break;case"BottomRight":s.top+=a+d,s.left-=p;break;case"BottomCenter":s.top+=a+d,s.left-=l/2;break;case"BottomLeft":s.top+=a+d,s.left-=l-p;break;case"LeftBottom":s.left-=o+l+d,s.top-=u;break;case"LeftCenter":s.left-=o+l+d,s.top-=h/2;break;case"LeftTop":s.left-=o+l+d,s.top-=h-u;break;case"TopLeft":s.top-=h+a+d,s.left-=l-p;break;case"TopRight":s.top-=h+a+d,s.left-=p;break;default:s.top-=h+a+d,s.left-=l/2}return s.left+=this.offsetX,s.top+=this.offsetY,s},t.prototype.updateTipPosition=function(e){var i=we("."+dp+",."+z4+",."+G0,this.tooltipEle);K(i,[Gg,BE,R4,FE]),this.setTipClass(e),V(i,this.tipClass)},t.prototype.adjustArrow=function(e,i,r,s){var o=U("."+dp,this.tooltipEle);if(!1!==this.showTipPointer&&null!==o){var a,l;this.updateTipPosition(i),this.tooltipEle.style.display="block";var f,h=this.tooltipEle.clientWidth,c=this.tooltipEle.clientHeight,d=U("."+G0,this.tooltipEle),u=o.offsetWidth,p=o.offsetHeight;this.tooltipEle.style.display="",this.tipClass===Gg||this.tipClass===BE?(this.tipClass===Gg?(l="99.9%",d.style.top="-"+(p-2)+"px"):(l=-(p-1)+"px",d.style.top="-"+(p-6)+"px"),e&&(a=(f="Center"!==r||h>e.offsetWidth||this.mouseTrail)&&"Left"===r||!f&&"End"===this.tipPointerPosition?h-u-2+"px":f&&"Right"===r||!f&&"Start"===this.tipPointerPosition?"2px":!f||"End"!==this.tipPointerPosition&&"Start"!==this.tipPointerPosition?h/2-u/2+"px":"End"===this.tipPointerPosition?e.offsetWidth+(this.tooltipEle.offsetWidth-e.offsetWidth)/2-u/2-2+"px":(this.tooltipEle.offsetWidth-e.offsetWidth)/2-u/2+2+"px")):(this.tipClass===FE?(a="99.9%",d.style.left="-"+(u-2)+"px"):(a=-(u-1)+"px",d.style.left=u-2-u+"px"),l=(f="Center"!==s||c>e.offsetHeight||this.mouseTrail)&&"Top"===s||!f&&"End"===this.tipPointerPosition?c-p-2+"px":f&&"Bottom"===s||!f&&"Start"===this.tipPointerPosition?"2px":c/2-p/2+"px"),o.style.top=l,o.style.left=a}},t.prototype.renderContent=function(e){var i=this,r=U("."+P4,this.tooltipEle);if(this.cssClass&&V([this.tooltipEle],this.cssClass.split(" ")),e&&!m(e.getAttribute("title"))&&(e.setAttribute("data-content",e.getAttribute("title")),e.removeAttribute("title")),m(this.content))e&&!m(e.getAttribute("data-content"))&&(r.innerHTML=e.getAttribute("data-content"));else if(r.innerHTML="",this.content instanceof HTMLElement)r.appendChild(this.content);else if("string"==typeof this.content)this.isAngular?this.setProperties({content:Ti.sanitize(this.content)},!0):this.content=this.enableHtmlSanitizer?Ti.sanitize(this.content):this.content,this.enableHtmlParse?(o=ri(this.content)({},this,"content",this.element.id+"content",void 0,void 0,r,this.root))&&Dt(o,r):r.textContent=this.content;else{var o;(o=ri(this.content)({},this,"content",this.element.id+"content",void 0,void 0,r))&&(this.isAngular&&setTimeout(function(){i.reposition(e)},1),Dt(o,r)),this.renderReactTemplates()}},t.prototype.renderCloseIcon=function(){if(this.isSticky){var i=this.createElement("div",{className:O4+" "+k4});this.tooltipEle.appendChild(i),E.add(i,X.touchStartEvent,this.onStickyClose,this)}else{var e=this.tooltipEle.querySelector("."+O4+"."+k4);e&>(e)}},t.prototype.addDescribedBy=function(e,i){var r=(e.getAttribute("aria-describedby")||"").split(/\s+/);r.indexOf(i)<0&&r.push(i),Fe(e,{"aria-describedby":r.join(" ").trim(),"data-tooltip-id":i})},t.prototype.removeDescribedBy=function(e){var i=e.getAttribute("data-tooltip-id"),r=(e.getAttribute("aria-describedby")||"").split(/\s+/),s=r.indexOf(i);-1!==s&&r.splice(s,1),e.removeAttribute("data-tooltip-id");var o=r.join(" ").trim();o?e.setAttribute("aria-describedby",o):e.removeAttribute("aria-describedby")},t.prototype.tapHoldHandler=function(e){clearTimeout(this.autoCloseTimer),this.targetHover(e.originalEvent)},t.prototype.touchEndHandler=function(){var e=this;this.isSticky||(this.autoCloseTimer=setTimeout(function(){e.close()},1500))},t.prototype.targetClick=function(e){var i;!m(i=this.target?J(e.target,this.target):this.element)&&(null===i.getAttribute("data-tooltip-id")?this.targetHover(e):this.isSticky||this.hideTooltip(this.animation.close,e,i))},t.prototype.targetHover=function(e){var i;if(!(m(i=this.target?J(e.target,this.target):this.element)||null!==i.getAttribute("data-tooltip-id")&&0===this.closeDelay)){for(var s=0,o=[].slice.call(we('[data-tooltip-id= "'+this.ctrlId+'_content"]',document));s0?this.showTimer=setTimeout(function(){o.mouseTrail&&E.add(i,"mousemove touchstart mouseenter",o.onMouseMove,o),o.popupObj&&(o.popupObj.show(a,i),o.mouseMoveEvent&&o.mouseTrail&&o.onMouseMove(o.mouseMoveEvent))},this.openDelay):this.popupObj&&this.popupObj.show(a,i)}s&&this.wireMouseEvents(s,i)},t.prototype.needTemplateReposition=function(){return!m(this.viewContainerRef)&&"string"!=typeof this.viewContainerRef||this.isReact},t.prototype.checkCollision=function(e,i,r){var s={left:i,top:r,position:this.position,horizontal:this.tooltipPositionX,vertical:this.tooltipPositionY},o=oc(this.tooltipEle,this.checkCollideTarget(),i,r);return o.length>0&&(s.horizontal=o.indexOf("left")>=0?"Right":o.indexOf("right")>=0?"Left":this.tooltipPositionX,s.vertical=o.indexOf("top")>=0?"Bottom":o.indexOf("bottom")>=0?"Top":this.tooltipPositionY),s},t.prototype.calculateElementPosition=function(e,i){return[this.isBodyContainer?e.left+i.left:e.left-this.containerElement.getBoundingClientRect().left+i.left+window.pageXOffset+this.containerElement.scrollLeft,this.isBodyContainer?e.top+i.top:e.top-this.containerElement.getBoundingClientRect().top+i.top+window.pageYOffset+this.containerElement.scrollTop]},t.prototype.collisionFlipFit=function(e,i,r){var s=this.checkCollision(e,i,r),o=s.position;if(this.tooltipPositionY!==s.vertical&&(o=0===this.position.indexOf("Bottom")||0===this.position.indexOf("Top")?s.vertical+this.tooltipPositionX:this.tooltipPositionX+s.vertical),this.tooltipPositionX!==s.horizontal&&(0===o.indexOf("Left")&&(s.vertical="LeftTop"===o||"LeftCenter"===o?"Top":"Bottom",o=s.vertical+"Left"),0===o.indexOf("Right")&&(s.vertical="RightTop"===o||"RightCenter"===o?"Top":"Bottom",o=s.vertical+"Right"),s.horizontal=this.tooltipPositionX),this.tooltipEventArgs={type:null,cancel:!1,target:e,event:null,element:this.tooltipEle,collidedPosition:o},this.trigger("beforeCollision",this.tooltipEventArgs),this.tooltipEventArgs.cancel)o=this.position;else{var a=s.vertical,l=s.horizontal;if(s.position!==o){var h=is(e,l,a,!this.isBodyContainer,this.isBodyContainer?null:this.containerElement.getBoundingClientRect());this.adjustArrow(e,o,l,a);var c=this.getScalingFactor(e),d=this.calculateTooltipOffset(o,c.x,c.y);d.top-=this.getOffSetPosition("TopBottom",o,this.offsetY),d.left-=this.getOffSetPosition("RightLeft",o,this.offsetX),s.position=o;var u=this.calculateElementPosition(h,d);s.left=u[0],s.top=u[1]}else this.adjustArrow(e,o,l,a)}var p={left:s.left,top:s.top},f=this.isBodyContainer?cE(this.tooltipEle,this.checkCollideTarget(),{X:!0,Y:this.windowCollision},p):p;this.tooltipEle.style.display="block";var g=U("."+dp,this.tooltipEle);if(this.showTipPointer&&null!=g&&(0===o.indexOf("Bottom")||0===o.indexOf("Top"))){var v=parseInt(g.style.left,10)-(f.left-s.left);v<0?v=0:v+g.offsetWidth>this.tooltipEle.clientWidth&&(v=this.tooltipEle.clientWidth-g.offsetWidth),g.style.left=v.toString()+"px"}return this.tooltipEle.style.display="",p.left=f.left,p.top=f.top,p},t.prototype.getOffSetPosition=function(e,i,r){return-1!==e.indexOf(this.position.split(/(?=[A-Z])/)[0])&&-1!==e.indexOf(i.split(/(?=[A-Z])/)[0])?2*r:0},t.prototype.checkCollideTarget=function(){return!this.windowCollision&&this.target?this.element:null},t.prototype.hideTooltip=function(e,i,r){var s=this;this.closeDelay>0?(clearTimeout(this.hideTimer),clearTimeout(this.showTimer),this.hideTimer=setTimeout(function(){s.closeDelay&&s.tooltipEle&&s.isTooltipOpen||s.tooltipHide(e,i,r)},this.closeDelay)):this.tooltipHide(e,i,r)},t.prototype.tooltipHide=function(e,i,r){var o,s=this;o=i?this.target?r||i.target:this.element:U('[data-tooltip-id= "'+this.ctrlId+'_content"]',document),this.tooltipEventArgs={type:i?i.type:null,cancel:!1,target:o,event:i||null,element:this.tooltipEle,isInteracted:!m(i)},this.trigger("beforeClose",this.tooltipEventArgs,function(a){a.cancel?s.isHidden=!1:(s.mouseMoveBeforeRemove(),s.popupHide(e,o,i))})},t.prototype.popupHide=function(e,i,r){i&&r&&this.restoreElement(i),this.isHidden=!0;var s={name:this.animation.close.effect,duration:e.duration,delay:e.delay,timingFunction:"easeIn"};"None"===e.effect&&(s=void 0),this.popupObj&&this.popupObj.hide(s)},t.prototype.restoreElement=function(e){this.unwireMouseEvents(e),m(e.getAttribute("data-content"))||(e.setAttribute("title",e.getAttribute("data-content")),e.removeAttribute("data-content")),this.removeDescribedBy(e)},t.prototype.clear=function(){var e=this.findTarget();e&&this.restoreElement(e),this.tooltipEle&&(K([this.tooltipEle],UE),V([this.tooltipEle],Xg)),this.isHidden&&(this.popupObj&&this.popupObj.destroy(),this.tooltipEle&>(this.tooltipEle),this.tooltipEle=null,this.popupObj=null)},t.prototype.tooltipHover=function(){this.tooltipEle&&(this.isTooltipOpen=!0)},t.prototype.tooltipMouseOut=function(e){this.isTooltipOpen=!1,this.hideTooltip(this.animation.close,e,this.findTarget())},t.prototype.onMouseOut=function(e){var i=e.relatedTarget;if(i&&!this.mouseTrail){var r=J(i,"."+HE+"."+X0+"."+_E);r?E.add(r,"mouseleave",this.tooltipElementMouseOut,this):(this.hideTooltip(this.animation.close,e,this.findTarget()),0===this.closeDelay&&("None"===this.animation.close.effect||this.isReact&&"string"!=typeof this.content)&&this.clear())}else this.hideTooltip(this.animation.close,e,this.findTarget()),this.clear();this.popupObj&&!this.popupObj.element.classList.contains(Xg)&&this.clear()},t.prototype.tooltipElementMouseOut=function(e){this.hideTooltip(this.animation.close,e,this.findTarget()),E.remove(this.element,"mouseleave",this.tooltipElementMouseOut),this.clear()},t.prototype.onStickyClose=function(){this.close()},t.prototype.onMouseMove=function(e){var i=0,r=0;e.type.indexOf("touch")>-1?(e.preventDefault(),i=e.touches[0].pageX,r=e.touches[0].pageY):(i=e.pageX,r=e.pageY),Hs.stop(this.tooltipEle),K([this.tooltipEle],UE),V([this.tooltipEle],Xg),this.adjustArrow(e.target,this.position,this.tooltipPositionX,this.tooltipPositionY);var s=this.getScalingFactor(e.target),o=this.calculateTooltipOffset(this.position,s.x,s.y),h=this.checkCollision(e.target,i+o.left+this.offsetX,r+o.top+this.offsetY);if(this.tooltipPositionX!==h.horizontal||this.tooltipPositionY!==h.vertical){var c=0===this.position.indexOf("Bottom")||0===this.position.indexOf("Top")?h.vertical+h.horizontal:h.horizontal+h.vertical;h.position=c,this.adjustArrow(e.target,h.position,h.horizontal,h.vertical);var d=this.calculateTooltipOffset(h.position,s.x,s.y);h.left=i+d.left-this.offsetX,h.top=r+d.top-this.offsetY}this.tooltipEle.style.left=h.left+"px",this.tooltipEle.style.top=h.top+"px"},t.prototype.keyDown=function(e){this.tooltipEle&&27===e.keyCode&&this.close()},t.prototype.touchEnd=function(e){this.tooltipEle&&null===J(e.target,"."+RE)&&!this.isSticky&&this.close()},t.prototype.scrollHandler=function(e){this.tooltipEle&&!this.isSticky&&!J(e.target,"."+HE+"."+X0+"."+_E)&&!this.isSticky&&this.close()},t.prototype.render=function(){this.initialize(),this.wireEvents(this.opensOn),this.renderComplete()},t.prototype.preRender=function(){this.tipClass=Gg,this.tooltipPositionX="Center",this.tooltipPositionY="Top",this.isHidden=!0},t.prototype.wireEvents=function(e){for(var r=0,s=this.getTriggerList(e);r0)for(var i=0,r=e;i0)for(var i=0,r=e;i0&&this.condition&&-1!==this.condition.indexOf("not")&&(e[s].condition=e[s].condition?e[s].condition+"not":"not"),i=e[s].validate(t),r){if(!i)return!1}else if(i)return!0;return r},n.prototype.toJson=function(){var t,e;if(this.isComplex){t=[],e=this.predicates;for(var i=0;ie.length-3?(e=e.substring(0,e.length-1),n.endsWith(n.toLowerCase(t),n.toLowerCase(e))):(e.lastIndexOf("%")!==e.indexOf("%")&&e.lastIndexOf("%")>e.indexOf("%")+1&&(e=e.substring(e.indexOf("%")+1,e.lastIndexOf("%"))),-1!==t.indexOf(e)))},n.fnSort=function(t){return"ascending"===(t=t?n.toLowerCase(t):"ascending")?this.fnAscending:this.fnDescending},n.fnAscending=function(t,e){return m(t)&&m(e)||null==e?-1:"string"==typeof t?t.localeCompare(e):null==t?1:t-e},n.fnDescending=function(t,e){return m(t)&&m(e)?-1:null==e?1:"string"==typeof t?-1*t.localeCompare(e):null==t?-1:e-t},n.extractFields=function(t,e){for(var i={},r=0;r0||e.length>0;)o=t.length>0&&e.length>0?r?r(this.getVal(t,0,i),this.getVal(e,0,i),t[0],e[0])<=0?t:e:t[0][i]0?t:e,s.push(o.shift());return s},n.getVal=function(t,e,i){return i?this.getObject(i,t[e]):t[e]},n.toLowerCase=function(t){return t?"string"==typeof t?t.toLowerCase():t.toString():0===t||!1===t?t.toString():""},n.callAdaptorFunction=function(t,e,i,r){if(e in t){var s=t[e](i,r);m(s)||(i=s)}return i},n.getAddParams=function(t,e,i){var r={};return n.callAdaptorFunction(t,"addParams",{dm:e,query:i,params:i?i.params:[],reqParams:r}),r},n.isPlainObject=function(t){return!!t&&t.constructor===Object},n.isCors=function(){var t=null;try{t=new window.XMLHttpRequest}catch{}return!!t&&"withCredentials"in t},n.getGuid=function(t){var i;return(t||"")+"00000000-0000-4000-0000-000000000000".replace(/0/g,function(r,s){if("crypto"in window&&"getRandomValues"in crypto){var o=new Uint8Array(1);window.crypto.getRandomValues(o),i=o[0]%16|0}else i=16*Math.random()|0;return"0123456789abcdef"[19===s?3&i|8:i]})},n.isNull=function(t){return null==t},n.getItemFromComparer=function(t,e,i){var r,s,o,a=0,l="string"==typeof n.getVal(t,0,e);if(t.length)for(;m(r)&&a0&&(r=s,o=t[a]));return o},n.distinct=function(t,e,i){i=!m(i)&&i;var s,r=[],o={};return t.forEach(function(a,l){(s="object"==typeof t[l]?n.getVal(t,l,e):t[l])in o||(r.push(i?t[l]:s),o[s]=1)}),r},n.processData=function(t,e){var i=this.prepareQuery(t),r=new nt(e);t.requiresCounts&&i.requiresCount();var s=r.executeLocal(i),o={result:t.requiresCounts?s.result:s,count:s.count,aggregates:JSON.stringify(s.aggregates)};return t.requiresCounts?o:s},n.prepareQuery=function(t){var e=this,i=new jt;return t.select&&i.select(t.select),t.where&&n.parse.parseJson(t.where).filter(function(o){if(m(o.condition))i.where(o.field,o.operator,o.value,o.ignoreCase,o.ignoreAccent);else{var a=[];o.field?a.push(new Ss(o.field,o.operator,o.value,o.ignoreCase,o.ignoreAccent)):a=a.concat(e.getPredicate(o.predicates)),"or"===o.condition?i.where(Ss.or(a)):"and"===o.condition&&i.where(Ss.and(a))}}),t.search&&n.parse.parseJson(t.search).filter(function(o){return i.search(o.key,o.fields,o.operator,o.ignoreCase,o.ignoreAccent)}),t.aggregates&&t.aggregates.filter(function(o){return i.aggregate(o.type,o.field)}),t.sorted&&t.sorted.filter(function(o){return i.sortBy(o.name,o.direction)}),t.skip&&i.skip(t.skip),t.take&&i.take(t.take),t.group&&t.group.filter(function(o){return i.group(o)}),i},n.getPredicate=function(t){for(var e=[],i=0;i":"greaterthan","<=":"lessthanorequal",">=":"greaterthanorequal","==":"equal","!=":"notequal","*=":"contains","$=":"endswith","^=":"startswith"},n.odBiOperator={"<":" lt ",">":" gt ","<=":" le ",">=":" ge ","==":" eq ","!=":" ne ",lessthan:" lt ",lessthanorequal:" le ",greaterthan:" gt ",greaterthanorequal:" ge ",equal:" eq ",notequal:" ne "},n.odUniOperator={"$=":"endswith","^=":"startswith","*=":"substringof",endswith:"endswith",startswith:"startswith",contains:"substringof",doesnotendwith:"not endswith",doesnotstartwith:"not startswith",doesnotcontain:"not substringof",wildcard:"wildcard",like:"like"},n.odv4UniOperator={"$=":"endswith","^=":"startswith","*=":"contains",endswith:"endswith",startswith:"startswith",contains:"contains",doesnotendwith:"not endswith",doesnotstartwith:"not startswith",doesnotcontain:"not contains",wildcard:"wildcard",like:"like"},n.diacritics={"\u24b6":"A",\uff21:"A",\u00c0:"A",\u00c1:"A",\u00c2:"A",\u1ea6:"A",\u1ea4:"A",\u1eaa:"A",\u1ea8:"A",\u00c3:"A",\u0100:"A",\u0102:"A",\u1eb0:"A",\u1eae:"A",\u1eb4:"A",\u1eb2:"A",\u0226:"A",\u01e0:"A",\u00c4:"A",\u01de:"A",\u1ea2:"A",\u00c5:"A",\u01fa:"A",\u01cd:"A",\u0200:"A",\u0202:"A",\u1ea0:"A",\u1eac:"A",\u1eb6:"A",\u1e00:"A",\u0104:"A",\u023a:"A",\u2c6f:"A",\ua732:"AA",\u00c6:"AE",\u01fc:"AE",\u01e2:"AE",\ua734:"AO",\ua736:"AU",\ua738:"AV",\ua73a:"AV",\ua73c:"AY","\u24b7":"B",\uff22:"B",\u1e02:"B",\u1e04:"B",\u1e06:"B",\u0243:"B",\u0182:"B",\u0181:"B","\u24b8":"C",\uff23:"C",\u0106:"C",\u0108:"C",\u010a:"C",\u010c:"C",\u00c7:"C",\u1e08:"C",\u0187:"C",\u023b:"C",\ua73e:"C","\u24b9":"D",\uff24:"D",\u1e0a:"D",\u010e:"D",\u1e0c:"D",\u1e10:"D",\u1e12:"D",\u1e0e:"D",\u0110:"D",\u018b:"D",\u018a:"D",\u0189:"D",\ua779:"D",\u01f1:"DZ",\u01c4:"DZ",\u01f2:"Dz",\u01c5:"Dz","\u24ba":"E",\uff25:"E",\u00c8:"E",\u00c9:"E",\u00ca:"E",\u1ec0:"E",\u1ebe:"E",\u1ec4:"E",\u1ec2:"E",\u1ebc:"E",\u0112:"E",\u1e14:"E",\u1e16:"E",\u0114:"E",\u0116:"E",\u00cb:"E",\u1eba:"E",\u011a:"E",\u0204:"E",\u0206:"E",\u1eb8:"E",\u1ec6:"E",\u0228:"E",\u1e1c:"E",\u0118:"E",\u1e18:"E",\u1e1a:"E",\u0190:"E",\u018e:"E","\u24bb":"F",\uff26:"F",\u1e1e:"F",\u0191:"F",\ua77b:"F","\u24bc":"G",\uff27:"G",\u01f4:"G",\u011c:"G",\u1e20:"G",\u011e:"G",\u0120:"G",\u01e6:"G",\u0122:"G",\u01e4:"G",\u0193:"G",\ua7a0:"G",\ua77d:"G",\ua77e:"G","\u24bd":"H",\uff28:"H",\u0124:"H",\u1e22:"H",\u1e26:"H",\u021e:"H",\u1e24:"H",\u1e28:"H",\u1e2a:"H",\u0126:"H",\u2c67:"H",\u2c75:"H",\ua78d:"H","\u24be":"I",\uff29:"I",\u00cc:"I",\u00cd:"I",\u00ce:"I",\u0128:"I",\u012a:"I",\u012c:"I",\u0130:"I",\u00cf:"I",\u1e2e:"I",\u1ec8:"I",\u01cf:"I",\u0208:"I",\u020a:"I",\u1eca:"I",\u012e:"I",\u1e2c:"I",\u0197:"I","\u24bf":"J",\uff2a:"J",\u0134:"J",\u0248:"J","\u24c0":"K",\uff2b:"K",\u1e30:"K",\u01e8:"K",\u1e32:"K",\u0136:"K",\u1e34:"K",\u0198:"K",\u2c69:"K",\ua740:"K",\ua742:"K",\ua744:"K",\ua7a2:"K","\u24c1":"L",\uff2c:"L",\u013f:"L",\u0139:"L",\u013d:"L",\u1e36:"L",\u1e38:"L",\u013b:"L",\u1e3c:"L",\u1e3a:"L",\u0141:"L",\u023d:"L",\u2c62:"L",\u2c60:"L",\ua748:"L",\ua746:"L",\ua780:"L",\u01c7:"LJ",\u01c8:"Lj","\u24c2":"M",\uff2d:"M",\u1e3e:"M",\u1e40:"M",\u1e42:"M",\u2c6e:"M",\u019c:"M","\u24c3":"N",\uff2e:"N",\u01f8:"N",\u0143:"N",\u00d1:"N",\u1e44:"N",\u0147:"N",\u1e46:"N",\u0145:"N",\u1e4a:"N",\u1e48:"N",\u0220:"N",\u019d:"N",\ua790:"N",\ua7a4:"N",\u01ca:"NJ",\u01cb:"Nj","\u24c4":"O",\uff2f:"O",\u00d2:"O",\u00d3:"O",\u00d4:"O",\u1ed2:"O",\u1ed0:"O",\u1ed6:"O",\u1ed4:"O",\u00d5:"O",\u1e4c:"O",\u022c:"O",\u1e4e:"O",\u014c:"O",\u1e50:"O",\u1e52:"O",\u014e:"O",\u022e:"O",\u0230:"O",\u00d6:"O",\u022a:"O",\u1ece:"O",\u0150:"O",\u01d1:"O",\u020c:"O",\u020e:"O",\u01a0:"O",\u1edc:"O",\u1eda:"O",\u1ee0:"O",\u1ede:"O",\u1ee2:"O",\u1ecc:"O",\u1ed8:"O",\u01ea:"O",\u01ec:"O",\u00d8:"O",\u01fe:"O",\u0186:"O",\u019f:"O",\ua74a:"O",\ua74c:"O",\u01a2:"OI",\ua74e:"OO",\u0222:"OU","\u24c5":"P",\uff30:"P",\u1e54:"P",\u1e56:"P",\u01a4:"P",\u2c63:"P",\ua750:"P",\ua752:"P",\ua754:"P","\u24c6":"Q",\uff31:"Q",\ua756:"Q",\ua758:"Q",\u024a:"Q","\u24c7":"R",\uff32:"R",\u0154:"R",\u1e58:"R",\u0158:"R",\u0210:"R",\u0212:"R",\u1e5a:"R",\u1e5c:"R",\u0156:"R",\u1e5e:"R",\u024c:"R",\u2c64:"R",\ua75a:"R",\ua7a6:"R",\ua782:"R","\u24c8":"S",\uff33:"S",\u1e9e:"S",\u015a:"S",\u1e64:"S",\u015c:"S",\u1e60:"S",\u0160:"S",\u1e66:"S",\u1e62:"S",\u1e68:"S",\u0218:"S",\u015e:"S",\u2c7e:"S",\ua7a8:"S",\ua784:"S","\u24c9":"T",\uff34:"T",\u1e6a:"T",\u0164:"T",\u1e6c:"T",\u021a:"T",\u0162:"T",\u1e70:"T",\u1e6e:"T",\u0166:"T",\u01ac:"T",\u01ae:"T",\u023e:"T",\ua786:"T",\ua728:"TZ","\u24ca":"U",\uff35:"U",\u00d9:"U",\u00da:"U",\u00db:"U",\u0168:"U",\u1e78:"U",\u016a:"U",\u1e7a:"U",\u016c:"U",\u00dc:"U",\u01db:"U",\u01d7:"U",\u01d5:"U",\u01d9:"U",\u1ee6:"U",\u016e:"U",\u0170:"U",\u01d3:"U",\u0214:"U",\u0216:"U",\u01af:"U",\u1eea:"U",\u1ee8:"U",\u1eee:"U",\u1eec:"U",\u1ef0:"U",\u1ee4:"U",\u1e72:"U",\u0172:"U",\u1e76:"U",\u1e74:"U",\u0244:"U","\u24cb":"V",\uff36:"V",\u1e7c:"V",\u1e7e:"V",\u01b2:"V",\ua75e:"V",\u0245:"V",\ua760:"VY","\u24cc":"W",\uff37:"W",\u1e80:"W",\u1e82:"W",\u0174:"W",\u1e86:"W",\u1e84:"W",\u1e88:"W",\u2c72:"W","\u24cd":"X",\uff38:"X",\u1e8a:"X",\u1e8c:"X","\u24ce":"Y",\uff39:"Y",\u1ef2:"Y",\u00dd:"Y",\u0176:"Y",\u1ef8:"Y",\u0232:"Y",\u1e8e:"Y",\u0178:"Y",\u1ef6:"Y",\u1ef4:"Y",\u01b3:"Y",\u024e:"Y",\u1efe:"Y","\u24cf":"Z",\uff3a:"Z",\u0179:"Z",\u1e90:"Z",\u017b:"Z",\u017d:"Z",\u1e92:"Z",\u1e94:"Z",\u01b5:"Z",\u0224:"Z",\u2c7f:"Z",\u2c6b:"Z",\ua762:"Z","\u24d0":"a",\uff41:"a",\u1e9a:"a",\u00e0:"a",\u00e1:"a",\u00e2:"a",\u1ea7:"a",\u1ea5:"a",\u1eab:"a",\u1ea9:"a",\u00e3:"a",\u0101:"a",\u0103:"a",\u1eb1:"a",\u1eaf:"a",\u1eb5:"a",\u1eb3:"a",\u0227:"a",\u01e1:"a",\u00e4:"a",\u01df:"a",\u1ea3:"a",\u00e5:"a",\u01fb:"a",\u01ce:"a",\u0201:"a",\u0203:"a",\u1ea1:"a",\u1ead:"a",\u1eb7:"a",\u1e01:"a",\u0105:"a",\u2c65:"a",\u0250:"a",\ua733:"aa",\u00e6:"ae",\u01fd:"ae",\u01e3:"ae",\ua735:"ao",\ua737:"au",\ua739:"av",\ua73b:"av",\ua73d:"ay","\u24d1":"b",\uff42:"b",\u1e03:"b",\u1e05:"b",\u1e07:"b",\u0180:"b",\u0183:"b",\u0253:"b","\u24d2":"c",\uff43:"c",\u0107:"c",\u0109:"c",\u010b:"c",\u010d:"c",\u00e7:"c",\u1e09:"c",\u0188:"c",\u023c:"c",\ua73f:"c",\u2184:"c","\u24d3":"d",\uff44:"d",\u1e0b:"d",\u010f:"d",\u1e0d:"d",\u1e11:"d",\u1e13:"d",\u1e0f:"d",\u0111:"d",\u018c:"d",\u0256:"d",\u0257:"d",\ua77a:"d",\u01f3:"dz",\u01c6:"dz","\u24d4":"e",\uff45:"e",\u00e8:"e",\u00e9:"e",\u00ea:"e",\u1ec1:"e",\u1ebf:"e",\u1ec5:"e",\u1ec3:"e",\u1ebd:"e",\u0113:"e",\u1e15:"e",\u1e17:"e",\u0115:"e",\u0117:"e",\u00eb:"e",\u1ebb:"e",\u011b:"e",\u0205:"e",\u0207:"e",\u1eb9:"e",\u1ec7:"e",\u0229:"e",\u1e1d:"e",\u0119:"e",\u1e19:"e",\u1e1b:"e",\u0247:"e",\u025b:"e",\u01dd:"e","\u24d5":"f",\uff46:"f",\u1e1f:"f",\u0192:"f",\ua77c:"f","\u24d6":"g",\uff47:"g",\u01f5:"g",\u011d:"g",\u1e21:"g",\u011f:"g",\u0121:"g",\u01e7:"g",\u0123:"g",\u01e5:"g",\u0260:"g",\ua7a1:"g",\u1d79:"g",\ua77f:"g","\u24d7":"h",\uff48:"h",\u0125:"h",\u1e23:"h",\u1e27:"h",\u021f:"h",\u1e25:"h",\u1e29:"h",\u1e2b:"h",\u1e96:"h",\u0127:"h",\u2c68:"h",\u2c76:"h",\u0265:"h",\u0195:"hv","\u24d8":"i",\uff49:"i",\u00ec:"i",\u00ed:"i",\u00ee:"i",\u0129:"i",\u012b:"i",\u012d:"i",\u00ef:"i",\u1e2f:"i",\u1ec9:"i",\u01d0:"i",\u0209:"i",\u020b:"i",\u1ecb:"i",\u012f:"i",\u1e2d:"i",\u0268:"i",\u0131:"i","\u24d9":"j",\uff4a:"j",\u0135:"j",\u01f0:"j",\u0249:"j","\u24da":"k",\uff4b:"k",\u1e31:"k",\u01e9:"k",\u1e33:"k",\u0137:"k",\u1e35:"k",\u0199:"k",\u2c6a:"k",\ua741:"k",\ua743:"k",\ua745:"k",\ua7a3:"k","\u24db":"l",\uff4c:"l",\u0140:"l",\u013a:"l",\u013e:"l",\u1e37:"l",\u1e39:"l",\u013c:"l",\u1e3d:"l",\u1e3b:"l",\u017f:"l",\u0142:"l",\u019a:"l",\u026b:"l",\u2c61:"l",\ua749:"l",\ua781:"l",\ua747:"l",\u01c9:"lj","\u24dc":"m",\uff4d:"m",\u1e3f:"m",\u1e41:"m",\u1e43:"m",\u0271:"m",\u026f:"m","\u24dd":"n",\uff4e:"n",\u01f9:"n",\u0144:"n",\u00f1:"n",\u1e45:"n",\u0148:"n",\u1e47:"n",\u0146:"n",\u1e4b:"n",\u1e49:"n",\u019e:"n",\u0272:"n",\u0149:"n",\ua791:"n",\ua7a5:"n",\u01cc:"nj","\u24de":"o",\uff4f:"o",\u00f2:"o",\u00f3:"o",\u00f4:"o",\u1ed3:"o",\u1ed1:"o",\u1ed7:"o",\u1ed5:"o",\u00f5:"o",\u1e4d:"o",\u022d:"o",\u1e4f:"o",\u014d:"o",\u1e51:"o",\u1e53:"o",\u014f:"o",\u022f:"o",\u0231:"o",\u00f6:"o",\u022b:"o",\u1ecf:"o",\u0151:"o",\u01d2:"o",\u020d:"o",\u020f:"o",\u01a1:"o",\u1edd:"o",\u1edb:"o",\u1ee1:"o",\u1edf:"o",\u1ee3:"o",\u1ecd:"o",\u1ed9:"o",\u01eb:"o",\u01ed:"o",\u00f8:"o",\u01ff:"o",\u0254:"o",\ua74b:"o",\ua74d:"o",\u0275:"o",\u01a3:"oi",\u0223:"ou",\ua74f:"oo","\u24df":"p",\uff50:"p",\u1e55:"p",\u1e57:"p",\u01a5:"p",\u1d7d:"p",\ua751:"p",\ua753:"p",\ua755:"p","\u24e0":"q",\uff51:"q",\u024b:"q",\ua757:"q",\ua759:"q","\u24e1":"r",\uff52:"r",\u0155:"r",\u1e59:"r",\u0159:"r",\u0211:"r",\u0213:"r",\u1e5b:"r",\u1e5d:"r",\u0157:"r",\u1e5f:"r",\u024d:"r",\u027d:"r",\ua75b:"r",\ua7a7:"r",\ua783:"r","\u24e2":"s",\uff53:"s",\u00df:"s",\u015b:"s",\u1e65:"s",\u015d:"s",\u1e61:"s",\u0161:"s",\u1e67:"s",\u1e63:"s",\u1e69:"s",\u0219:"s",\u015f:"s",\u023f:"s",\ua7a9:"s",\ua785:"s",\u1e9b:"s","\u24e3":"t",\uff54:"t",\u1e6b:"t",\u1e97:"t",\u0165:"t",\u1e6d:"t",\u021b:"t",\u0163:"t",\u1e71:"t",\u1e6f:"t",\u0167:"t",\u01ad:"t",\u0288:"t",\u2c66:"t",\ua787:"t",\ua729:"tz","\u24e4":"u",\uff55:"u",\u00f9:"u",\u00fa:"u",\u00fb:"u",\u0169:"u",\u1e79:"u",\u016b:"u",\u1e7b:"u",\u016d:"u",\u00fc:"u",\u01dc:"u",\u01d8:"u",\u01d6:"u",\u01da:"u",\u1ee7:"u",\u016f:"u",\u0171:"u",\u01d4:"u",\u0215:"u",\u0217:"u",\u01b0:"u",\u1eeb:"u",\u1ee9:"u",\u1eef:"u",\u1eed:"u",\u1ef1:"u",\u1ee5:"u",\u1e73:"u",\u0173:"u",\u1e77:"u",\u1e75:"u",\u0289:"u","\u24e5":"v",\uff56:"v",\u1e7d:"v",\u1e7f:"v",\u028b:"v",\ua75f:"v",\u028c:"v",\ua761:"vy","\u24e6":"w",\uff57:"w",\u1e81:"w",\u1e83:"w",\u0175:"w",\u1e87:"w",\u1e85:"w",\u1e98:"w",\u1e89:"w",\u2c73:"w","\u24e7":"x",\uff58:"x",\u1e8b:"x",\u1e8d:"x","\u24e8":"y",\uff59:"y",\u1ef3:"y",\u00fd:"y",\u0177:"y",\u1ef9:"y",\u0233:"y",\u1e8f:"y",\u00ff:"y",\u1ef7:"y",\u1e99:"y",\u1ef5:"y",\u01b4:"y",\u024f:"y",\u1eff:"y","\u24e9":"z",\uff5a:"z",\u017a:"z",\u1e91:"z",\u017c:"z",\u017e:"z",\u1e93:"z",\u1e95:"z",\u01b6:"z",\u0225:"z",\u0240:"z",\u2c6c:"z",\ua763:"z",\u0386:"\u0391",\u0388:"\u0395",\u0389:"\u0397",\u038a:"\u0399",\u03aa:"\u0399",\u038c:"\u039f",\u038e:"\u03a5",\u03ab:"\u03a5",\u038f:"\u03a9",\u03ac:"\u03b1",\u03ad:"\u03b5",\u03ae:"\u03b7",\u03af:"\u03b9",\u03ca:"\u03b9",\u0390:"\u03b9",\u03cc:"\u03bf",\u03cd:"\u03c5",\u03cb:"\u03c5",\u03b0:"\u03c5",\u03c9:"\u03c9",\u03c2:"\u03c3"},n.fnOperators={equal:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?n.toLowerCase(t)===n.toLowerCase(e):t===e},notequal:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),!n.fnOperators.equal(t,e,i)},lessthan:function(t,e,i){return i?n.toLowerCase(t)n.toLowerCase(e):t>e},lessthanorequal:function(t,e,i){return i?n.toLowerCase(t)<=n.toLowerCase(e):(m(t)&&(t=void 0),t<=e)},greaterthanorequal:function(t,e,i){return i?n.toLowerCase(t)>=n.toLowerCase(e):t>=e},contains:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?!m(t)&&!m(e)&&-1!==n.toLowerCase(t).indexOf(n.toLowerCase(e)):!m(t)&&!m(e)&&-1!==t.toString().indexOf(e)},doesnotcontain:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?!m(t)&&!m(e)&&-1===n.toLowerCase(t).indexOf(n.toLowerCase(e)):!m(t)&&!m(e)&&-1===t.toString().indexOf(e)},isnotnull:function(t){return null!=t},isnull:function(t){return null==t},startswith:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.startsWith(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.startsWith(t,e)},doesnotstartwith:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.notStartsWith(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.notStartsWith(t,e)},like:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.like(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.like(t,e)},isempty:function(t){return void 0===t||""===t},isnotempty:function(t){return void 0!==t&&""!==t},wildcard:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?(t||"boolean"==typeof t)&&e&&"object"!=typeof t&&n.wildCard(n.toLowerCase(t),n.toLowerCase(e)):(t||"boolean"==typeof t)&&e&&n.wildCard(t,e)},endswith:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.endsWith(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.endsWith(t,e)},doesnotendwith:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.notEndsWith(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.notEndsWith(t,e)},processSymbols:function(t){var e=n.operatorSymbols[t];return e?n.fnOperators[e]:n.throwError("Query - Process Operator : Invalid operator")},processOperator:function(t){return n.fnOperators[t]||n.fnOperators.processSymbols(t)}},n.parse={parseJson:function(t){return"string"!=typeof t||!/^[\s]*\[|^[\s]*\{(.)+:/g.test(t)&&-1!==t.indexOf('"')?t instanceof Array?n.parse.iterateAndReviveArray(t):"object"==typeof t&&null!==t&&n.parse.iterateAndReviveJson(t):t=JSON.parse(t,n.parse.jsonReviver),t},iterateAndReviveArray:function(t){for(var e=0;e-1||e.indexOf("z")>-1,o=e.split(/[^0-9.]/);if(s){if(o[5].indexOf(".")>-1){var a=o[5].split(".");o[5]=a[0],o[6]=new Date(e).getUTCMilliseconds().toString()}else o[6]="00";e=n.dateParse.toTimeZone(new Date(parseInt(o[0],10),parseInt(o[1],10)-1,parseInt(o[2],10),parseInt(o[3],10),parseInt(o[4],10),parseInt(o[5]?o[5]:"00",10),parseInt(o[6],10)),n.serverTimezoneOffset,!1)}else{var l=new Date(parseInt(o[0],10),parseInt(o[1],10)-1,parseInt(o[2],10),parseInt(o[3],10),parseInt(o[4],10),parseInt(o[5]?o[5]:"00",10)),h=parseInt(o[6],10),c=parseInt(o[7],10);if(isNaN(h)&&isNaN(c))return l;e.indexOf("+")>-1?l.setHours(l.getHours()-h,l.getMinutes()-c):l.setHours(l.getHours()+h,l.getMinutes()+c),e=n.dateParse.toTimeZone(l,n.serverTimezoneOffset,!1)}null==n.serverTimezoneOffset&&(e=n.dateParse.addSelfOffset(e))}}return e},isJson:function(t){return"string"==typeof t[0]?t:n.parse.parseJson(t)},isGuid:function(t){return null!=/[A-Fa-f0-9]{8}(?:-[A-Fa-f0-9]{4}){3}-[A-Fa-f0-9]{12}/i.exec(t)},replacer:function(t,e){return n.isPlainObject(t)?n.parse.jsonReplacer(t,e):t instanceof Array?n.parse.arrayReplacer(t):t instanceof Date?n.parse.jsonReplacer({val:t},e).val:t},jsonReplacer:function(t,e){for(var i,s=0,o=Object.keys(t);s=0?"+":"-",s=function(a){var l=Math.floor(Math.abs(a));return(l<10?"0":"")+l};return e.getFullYear()+"-"+s(e.getMonth()+1)+"-"+s(e.getDate())+"T"+s(e.getHours())+":"+s(e.getMinutes())+":"+s(e.getSeconds())+r+s(i/60)+":"+s(i%60)}},n}(),bl=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),AK={GroupGuid:"{271bbba0-1ee7}"},t5=function(){function n(t){this.options={from:"table",requestType:"json",sortBy:"sorted",select:"select",skip:"skip",group:"group",take:"take",search:"search",count:"requiresCounts",where:"where",aggregates:"aggregates",expand:"expand"},this.type=n,this.dataSource=t,this.pvt={}}return n.prototype.processResponse=function(t,e,i,r){return t},n}(),WE=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return bl(t,n),t.prototype.processQuery=function(e,i){for(var a,l,p,r=e.dataSource.json.slice(0),s=r.length,o=!0,h={},c=0,d=[],u=[],f=0;f1?e.sort.filter(function(p){return p.fieldName===c})[0]:e.sort[0];s=this.onSortBy(s,d,e.query,!0)}e.page&&(s=this.onPage(s,e.page,e.query)),this.formGroupResult(s,h)}else{for(var o=e.lazyLoad.onDemandGroupInfo,a=o.where.length-1;a>=0;a--)s=this.onWhere(s,o.where[a]);if(e.group.length!==o.level)s=le.group(s,e.group[o.level].fieldName,r,null,null,e.group[o.level].comparer,!0),e.sort.length&&(s=this.onSortBy(s,e.sort[parseInt(o.level.toString(),10)],e.query,!0));else for(a=e.sort.length-1;a>=o.level;a--)s=this.onSortBy(s,e.sort[parseInt(a.toString(),10)],e.query,!1);i=s.length,h=s,s=(s=s.slice(o.skip)).slice(0,o.take),e.group.length!==o.level&&this.formGroupResult(s,h)}return{result:s,count:i}},t.prototype.formGroupResult=function(e,i){if(e.length&&i.length){var r="GroupGuid",s="childLevels",o="level",a="records";e[r]=i[r],e[s]=i[s],e[o]=i[o],e[a]=i[a]}return e},t.prototype.getAggregate=function(e){var i=jt.filterQueries(e.queries,"onAggregates"),r=[];if(i.length)for(var s=void 0,o=0;o=0;l--)a[l]&&(o=i.comparer,le.endsWith(a[l]," desc")&&(o=le.fnSort("descending"),a[l]=a[l].replace(" desc","")),e=le.sort(e,a[l],o));return e}return le.sort(e,s?"key":a,i.comparer)},t.prototype.onGroup=function(e,i,r){if(!e||!e.length)return e;var s=this.getAggregate(r);return le.group(e,le.getValue(i.fieldName,r),s,null,null,i.comparer)},t.prototype.onPage=function(e,i,r){var s=le.getValue(i.pageSize,r),o=(le.getValue(i.pageIndex,r)-1)*s;return e&&e.length?e.slice(o,o+s):e},t.prototype.onRange=function(e,i){return e&&e.length?e.slice(le.getValue(i.start),le.getValue(i.end)):e},t.prototype.onTake=function(e,i){return e&&e.length?e.slice(0,le.getValue(i.nos)):e},t.prototype.onSkip=function(e,i){return e&&e.length?e.slice(le.getValue(i.nos)):e},t.prototype.onSelect=function(e,i){return e&&e.length?le.select(e,le.getValue(i.fieldNames)):e},t.prototype.insert=function(e,i,r,s,o){return m(o)?e.dataSource.json.push(i):e.dataSource.json.splice(o,0,i)},t.prototype.remove=function(e,i,r,s){var a,o=e.dataSource.json;for("object"==typeof r&&!(r instanceof Date)&&(r=le.getObject(i,r)),a=0;a1&&(g="("+g+")"),p.filters.push(g);for(var y=0,S="object"==typeof p.filters[f]?Object.keys(p.filters[f]):[];y-1&&this.formRemoteGroupedData(e[s].items,i+1,r-1);var o="GroupGuid",h="records";return e[o]=AK[o],e.level=i,e.childLevels=r,e[h]=e[0].items.length?this.getGroupedRecords(e,!m(e[0].items[h])):[],e},t.prototype.getGroupedRecords=function(e,i){for(var r=[],o=0;ol.length-3?(l=l.substring(0,l.length-1),o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.endswith:le.odv4UniOperator.endswith):l.lastIndexOf("%")!==l.indexOf("%")&&l.lastIndexOf("%")>l.indexOf("%")+1?(l=l.substring(l.indexOf("%")+1,l.lastIndexOf("%")),o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains):o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains),l="'"+(l=encodeURIComponent(l))+"'";else if("wildcard"===o)if(-1!==l.indexOf("*")){var d=l.split("*"),u=void 0,p=0;if(0!==l.indexOf("*")&&-1===d[0].indexOf("%3f")&&-1===d[0].indexOf("?")&&(u="'"+(u=d[0])+"'",s+=(o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.startswith:le.odv4UniOperator.startswith)+"(",s+=c+",",a&&(s+=a),s+=u+")",p++),l.lastIndexOf("*")!==l.length-1&&-1===d[d.length-1].indexOf("%3f")&&-1===d[d.length-1].indexOf("?")&&(u="'"+(u=d[d.length-1])+"'",p>0&&(s+=" and "),s+=(o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.endswith:le.odv4UniOperator.endswith)+"(",s+=c+",",a&&(s+=a),s+=u+")",p++),d.length>2)for(var f=1;f0&&(s+=" and "),"substringof"===(o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains)||"not substringof"===o){var g=u;u=c,c=g}s+=o+"(",s+=c+",",a&&(s+=a),s+=u+")",p++}0===p?(o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains,(-1!==l.indexOf("?")||-1!==l.indexOf("%3f"))&&(l=-1!==l.indexOf("?")?l.split("?").join(""):l.split("%3f").join("")),l="'"+l+"'"):o="wildcard"}else o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains,(-1!==l.indexOf("?")||-1!==l.indexOf("%3f"))&&(l=-1!==l.indexOf("?")?l.split("?").join(""):l.split("%3f").join("")),l="'"+l+"'";return"substringof"!==o&&"not substringof"!==o||(g=l,l=c,c=g),"wildcard"!==o&&(s+=o+"(",s+=c+",",a&&(s+=a),s+=l+")"),s},t.prototype.addParams=function(e){n.prototype.addParams.call(this,e),delete e.reqParams.params},t.prototype.onComplexPredicate=function(e,i,r){for(var s=[],o=0;o-1;p--)!/\bContent-ID:/i.test(c[p])||!/\bHTTP.+201/.test(c[p])||(l=parseInt(/\bContent-ID: (\d+)/i.exec(c[p])[1],10),o.addedRecords[l]&&(h=le.parse.parseJson(/^\{.+\}/m.exec(c[p])[0]),ze({},o.addedRecords[l],this.processResponse(h))));return o}return null},t.prototype.compareAndRemove=function(e,i,r){var s=this;return m(i)||Object.keys(e).forEach(function(o){o!==r&&"@odata.etag"!==o&&(le.isPlainObject(e[o])?(s.compareAndRemove(e[o],i[o]),0===Object.keys(e[o]).filter(function(l){return"@odata.etag"!==l}).length&&delete e[o]):(e[o]===i[o]||e[o]&&i[o]&&e[o].valueOf()===i[o].valueOf())&&delete e[o])}),e},t}(uc),LK=function(n){function t(){var e=n.call(this)||this;return yt("beforeSend",uc.prototype.beforeSend,e),e}return bl(t,n),t.prototype.insert=function(e,i,r,s,o){return this.pvt.position=o,this.updateType="add",{url:e.dataSource.insertUrl||e.dataSource.crudUrl||e.dataSource.url,data:JSON.stringify(ze({},{value:i,table:r,action:"insert"},le.getAddParams(this,e,s)))}},t.prototype.remove=function(e,i,r,s,o){return n.prototype.remove.call(this,e,i,r),{type:"POST",url:e.dataSource.removeUrl||e.dataSource.crudUrl||e.dataSource.url,data:JSON.stringify(ze({},{key:r,keyColumn:i,table:s,action:"remove"},le.getAddParams(this,e,o)))}},t.prototype.update=function(e,i,r,s,o){return this.updateType="update",this.updateKey=i,{type:"POST",url:e.dataSource.updateUrl||e.dataSource.crudUrl||e.dataSource.url,data:JSON.stringify(ze({},{value:r,action:"update",keyColumn:i,key:r[i],table:s},le.getAddParams(this,e,o)))}},t.prototype.processResponse=function(e,i,r,s,o,a,l){var h;if(e="batch"===(o?JSON.parse(o.data):e).action?le.parse.parseJson(e):e,"add"===this.updateType&&n.prototype.insert.call(this,i,e,null,null,this.pvt.position),"update"===this.updateType&&n.prototype.update.call(this,i,this.updateKey,e),this.updateType=void 0,e.added)for(h=0;hi&&h.push(c)}for(c=0;cthis.pageSize;)h.results.splice(0,1),h.keys.splice(0,1);return window.localStorage.setItem(this.guidId,JSON.stringify(h)),e},t.prototype.beforeSend=function(e,i,r){!m(this.cacheAdaptor.options.batch)&&le.endsWith(r.url,this.cacheAdaptor.options.batch)&&"post"===r.type.toLowerCase()&&i.headers.set("Accept",this.cacheAdaptor.options.multipartAccept),e.dataSource.crossDomain||i.headers.set("Accept",this.cacheAdaptor.options.accept)},t.prototype.update=function(e,i,r,s){return this.isCrudAction=!0,this.cacheAdaptor.update(e,i,r,s)},t.prototype.insert=function(e,i,r){return this.isInsertAction=!0,this.cacheAdaptor.insert(e,i,r)},t.prototype.remove=function(e,i,r,s){return this.isCrudAction=!0,this.cacheAdaptor.remove(e,i,r,s)},t.prototype.batchRequest=function(e,i,r){return this.cacheAdaptor.batchRequest(e,i,r)},t}(uc),nt=function(){function n(t,e,i){var s,r=this;return this.dateParse=!0,this.timeZoneHandling=!0,this.persistQuery={},this.isInitialLoad=!1,this.requests=[],this.isInitialLoad=!0,!t&&!this.dataSource&&(t=[]),i=i||t.adaptor,t&&!1===t.timeZoneHandling&&(this.timeZoneHandling=t.timeZoneHandling),t instanceof Array?s={json:t,offline:!0}:"object"==typeof t?(t.json||(t.json=[]),t.enablePersistence||(t.enablePersistence=!1),t.id||(t.id=""),t.ignoreOnPersist||(t.ignoreOnPersist=[]),s={url:t.url,insertUrl:t.insertUrl,removeUrl:t.removeUrl,updateUrl:t.updateUrl,crudUrl:t.crudUrl,batchUrl:t.batchUrl,json:t.json,headers:t.headers,accept:t.accept,data:t.data,timeTillExpiration:t.timeTillExpiration,cachingPageSize:t.cachingPageSize,enableCaching:t.enableCaching,requestType:t.requestType,key:t.key,crossDomain:t.crossDomain,jsonp:t.jsonp,dataType:t.dataType,offline:void 0!==t.offline?t.offline:!(t.adaptor instanceof LK||t.adaptor instanceof NK||t.url),requiresFormat:t.requiresFormat,enablePersistence:t.enablePersistence,id:t.id,ignoreOnPersist:t.ignoreOnPersist}):le.throwError("DataManager: Invalid arguments"),void 0===s.requiresFormat&&!le.isCors()&&(s.requiresFormat=!!m(s.crossDomain)||s.crossDomain),void 0===s.dataType&&(s.dataType="json"),this.dataSource=s,this.defaultQuery=e,this.dataSource.enablePersistence&&this.dataSource.id&&window.addEventListener("unload",this.setPersistData.bind(this)),s.url&&s.offline&&!s.json.length?(this.isDataAvailable=!1,this.adaptor=i||new fp,this.dataSource.offline=!1,this.ready=this.executeQuery(e||new jt),this.ready.then(function(o){r.dataSource.offline=!0,r.isDataAvailable=!0,s.json=o.result,r.adaptor=new WE})):this.adaptor=s.offline?new WE:new fp,!s.jsonp&&this.adaptor instanceof fp&&(s.jsonp="callback"),this.adaptor=i||this.adaptor,s.enableCaching&&(this.adaptor=new OK(this.adaptor,s.timeTillExpiration,s.cachingPageSize)),this}return Object.defineProperty(n.prototype,"moduleName",{get:function(){return"datamanager"},enumerable:!0,configurable:!0}),n.prototype.getPersistedData=function(t){var e=localStorage.getItem(t||this.dataSource.id);return JSON.parse(e)},n.prototype.setPersistData=function(t,e,i){localStorage.setItem(e||this.dataSource.id,JSON.stringify(i||this.persistQuery))},n.prototype.setPersistQuery=function(t){var e=this,i=this.getPersistedData();if(this.isInitialLoad&&i&&Object.keys(i).length){this.persistQuery=i,this.persistQuery.queries=this.persistQuery.queries.filter(function(s){if(e.dataSource.ignoreOnPersist&&e.dataSource.ignoreOnPersist.length&&s.fn&&e.dataSource.ignoreOnPersist.some(function(l){return s.fn===l}))return!1;if("onWhere"===s.fn){var o=s.e;if(o&&o.isComplex&&o.predicates instanceof Array){var a=o.predicates.map(function(l){if(l.predicates&&l.predicates instanceof Array){var h=l.predicates.map(function(v){return new Ss(v.field,v.operator,v.value,v.ignoreCase,v.ignoreAccent,v.matchCase)});return"and"===l.condition?Ss.and(h):Ss.or(h)}return new Ss(l.field,l.operator,l.value,l.ignoreCase,l.ignoreAccent,l.matchCase)});s.e=new Ss(a[0],o.condition,a.slice(1))}}return!0});var r=ze(new jt,this.persistQuery);return this.isInitialLoad=!1,r}return this.persistQuery=t,this.isInitialLoad=!1,t},n.prototype.setDefaultQuery=function(t){return this.defaultQuery=t,this},n.prototype.executeLocal=function(t){!this.defaultQuery&&!(t instanceof jt)&&le.throwError("DataManager - executeLocal() : A query is required to execute"),this.dataSource.json||le.throwError("DataManager - executeLocal() : Json data is required to execute"),this.dataSource.enablePersistence&&this.dataSource.id&&(t=this.setPersistQuery(t));var e=this.adaptor.processQuery(this,t=t||this.defaultQuery);if(t.subQuery){var i=t.subQuery.fromTable,r=t.subQuery.lookups,s=t.isCountRequired?e.result:e;r&&r instanceof Array&&le.buildHierarchy(t.subQuery.fKey,i,s,r,t.subQuery.key);for(var o=0;oli");P.classList.remove("json-parent");for(var j=0;j',W=ve.children[0].placeholder}return W}function Q(k,W,ve){!m(ve)&&""!==ve&&K(W,ve.split(" ")),!m(k)&&""!==k&&V(W,k.split(" "))}function oe(k,W,ve){if("multiselect"===ve||function Mo(k){if(!k)return!1;for(var W=k;W&&W!==document.body;){if("none"===window.getComputedStyle(W).display)return!1;W=W.parentElement}return!0}(k)){var Te="multiselect"===ve?k:k.clientWidth-parseInt(getComputedStyle(k,null).getPropertyValue("padding-left"),10);!m(W)&&!m(W.getElementsByClassName("e-float-text-content")[0])&&(W.getElementsByClassName("e-float-text-content")[0].classList.contains("e-float-text-overflow")&&W.getElementsByClassName("e-float-text-content")[0].classList.remove("e-float-text-overflow"),(Te0)for(var Ye=0;Ye<_e.length;Ye++)_e[parseInt(Ye.toString(),10)].addEventListener("mousedown",wo,!1),_e[parseInt(Ye.toString(),10)].addEventListener("mouseup",Hl,!1);else if(_e.length>0)for(Ye=0;Ye<_e.length;Ye++)_e[parseInt(Ye.toString(),10)].removeEventListener("mousedown",wo,this),_e[parseInt(Ye.toString(),10)].removeEventListener("mouseup",Hl,this)}function wo(){for(var W=this.parentElement;!W.classList.contains("e-input-group");)W=W.parentElement;!function ya(k,W){!k.classList.contains("e-disabled")&&!k.querySelector("input").readOnly&&W.classList.add("e-input-btn-ripple")}(W,this)}function Hl(){var k=this;setTimeout(function(){k.classList.remove("e-input-btn-ripple")},500)}function vb(k,W){var ve=W("span",{className:k});return ve.classList.add("e-input-group-icon"),ve}function I_(k,W,ve,Te){var _e=m(Te)?mi:Te,Ye=vb(k,_e);W.classList.add("e-float-icon-left");var fi=W.querySelector(".e-input-in-wrap");if(m(fi)){fi=_e("span",{className:"e-input-in-wrap"}),ve.parentNode.insertBefore(fi,ve);var Gs=W.querySelectorAll(ve.tagName+" ~ *");fi.appendChild(ve);for(var Kn=0;Kn-1)if("class"===_e){var Ye=this.getInputValidClassList(k[""+_e]);""!==Ye&&V([W],Ye.split(" "))}else if("style"===_e){var fi=W.getAttribute(_e);fi=m(fi)?k[""+_e]:fi+k[""+_e],W.setAttribute(_e,fi)}else W.setAttribute(_e,k[""+_e])}},n.isBlank=function Hle(k){return!k||/^\s*$/.test(k)}}(Le||(Le={})),new RegExp("^(-)?(\\d*)$"),new RegExp("^[A-Za-z0-9._%+-]{1,}@[A-Za-z0-9._%+-]{1,}([.]{1}[a-zA-Z0-9]{2,}|[.]{1}[a-zA-Z0-9]{2,4}[.]{1}[a-zA-Z0-9]{2,4})$"),new RegExp("^([0-9]{4})-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])$"),new RegExp("^[0-9]*$"),new RegExp("^[+]?[0-9]{9,13}$"),new RegExp("^\\d{13,16}$");var me=function(){function n(t,e){this.width=t,this.height=e}return n.prototype.isEmpty=function(){return 0===this.height&&0===this.width},n.prototype.clone=function(){return new n(this.width,this.height)},n}(),xie=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),GB=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},z=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return xie(t,n),t.equals=function(e,i){return e===i||!(!e||!i)&&(!e||!i||e.x===i.x&&e.y===i.y)},t.isEmptyPoint=function(e){return!(e.x&&e.y)},t.transform=function(e,i,r){var s={x:0,y:0};return s.x=Math.round(100*(e.x+r*Math.cos(i*Math.PI/180)))/100,s.y=Math.round(100*(e.y+r*Math.sin(i*Math.PI/180)))/100,s},t.findLength=function(e,i){return Math.sqrt(Math.pow(e.x-i.x,2)+Math.pow(e.y-i.y,2))},t.findAngle=function(e,i){var r=Math.atan2(i.y-e.y,i.x-e.x);return r=180*r/Math.PI,(r%=360)<0&&(r+=360),r},t.distancePoints=function(e,i){return Math.sqrt(Math.pow(i.x-e.x,2)+Math.pow(i.y-e.y,2))},t.getLengthFromListOfPoints=function(e){for(var i=0,r=0;ri.y&&!r?o.y+=s:o.y-=s:e.y===i.y?e.xi.x&&!r?o.x+=s:o.x-=s:r?(a=this.findAngle(e,i),o=this.transform(e,a,s)):(a=this.findAngle(i,e),o=this.transform(i,a,s)),o},t.direction=function(e,i){return Math.abs(i.x-e.x)>Math.abs(i.y-e.y)?e.x0)for(var r=0;rt.right||this.top>t.bottom||this.bottom=t.right&&this.top<=t.top&&this.bottom>=t.bottom},n.prototype.containsPoint=function(t,e){return void 0===e&&(e=0),this.left-e<=t.x&&this.right+e>=t.x&&this.top-e<=t.y&&this.bottom+e>=t.y},n.toBounds=function(t){for(var e=new n,i=0,r=t;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},KB=function(n){if(n)switch(n.type){case"Linear":default:return yI;case"Radial":return Bie}return yI},Rie=function(){return function n(t,e,i,r){this.left=t,this.right=e,this.top=i,this.bottom=r}}(),$n=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),it([I(0)],t.prototype,"left",void 0),it([I(0)],t.prototype,"right",void 0),it([I(0)],t.prototype,"top",void 0),it([I(0)],t.prototype,"bottom",void 0),t}(Ee),Hie=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),it([I(45)],t.prototype,"angle",void 0),it([I(5)],t.prototype,"distance",void 0),it([I(.7)],t.prototype,"opacity",void 0),it([I("lightgrey")],t.prototype,"color",void 0),t}(Ee),e3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),t.prototype.getClassName=function(){return"Stop"},it([I("")],t.prototype,"color",void 0),it([I(0)],t.prototype,"offset",void 0),it([I(1)],t.prototype,"opacity",void 0),t}(Ee),bx=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),it([Bt([],e3)],t.prototype,"stops",void 0),it([I("None")],t.prototype,"type",void 0),it([I("")],t.prototype,"id",void 0),t}(Ee),yI=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),it([I(0)],t.prototype,"x1",void 0),it([I(0)],t.prototype,"x2",void 0),it([I(0)],t.prototype,"y1",void 0),it([I(0)],t.prototype,"y2",void 0),t}(bx),Bie=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),it([I(0)],t.prototype,"cx",void 0),it([I(0)],t.prototype,"cy",void 0),it([I(0)],t.prototype,"fx",void 0),it([I(0)],t.prototype,"fy",void 0),it([I(50)],t.prototype,"r",void 0),t}(bx),Al=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),it([I("white")],t.prototype,"fill",void 0),it([I("black")],t.prototype,"strokeColor",void 0),it([I("")],t.prototype,"strokeDashArray",void 0),it([I(1)],t.prototype,"strokeWidth",void 0),it([I(1)],t.prototype,"opacity",void 0),it([D0(KB)],t.prototype,"gradient",void 0),t}(Ee),t3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),it([I("transparent")],t.prototype,"fill",void 0),t}(Al),Gp=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),it([I("black")],t.prototype,"color",void 0),it([I("Arial")],t.prototype,"fontFamily",void 0),it([I(12)],t.prototype,"fontSize",void 0),it([I(!1)],t.prototype,"italic",void 0),it([I(!1)],t.prototype,"bold",void 0),it([I("CollapseSpace")],t.prototype,"whiteSpace",void 0),it([I("WrapWithOverflow")],t.prototype,"textWrapping",void 0),it([I("Center")],t.prototype,"textAlign",void 0),it([I("None")],t.prototype,"textDecoration",void 0),it([I("Wrap")],t.prototype,"textOverflow",void 0),it([I("transparent")],t.prototype,"fill",void 0),t}(Al),on=function(n){return n[n.Default=0]="Default",n[n.expandNode=2]="expandNode",n[n.interaction=4]="interaction",n[n.GroupingInProgress=8]="GroupingInProgress",n[n.GroupClipboardInProcess=16]="GroupClipboardInProcess",n[n.ClearObject=32]="ClearObject",n}(on||{}),ti=function(n){return n[n.Visible=1]="Visible",n[n.Hidden=2]="Hidden",n[n.Hover=4]="Hover",n[n.Connect=8]="Connect",n}(ti||{}),Kt=function(n){return n[n.None=0]="None",n[n.ShowHorizontalLines=1]="ShowHorizontalLines",n[n.ShowVerticalLines=2]="ShowVerticalLines",n[n.ShowLines=3]="ShowLines",n[n.SnapToHorizontalLines=4]="SnapToHorizontalLines",n[n.SnapToVerticalLines=8]="SnapToVerticalLines",n[n.SnapToLines=12]="SnapToLines",n[n.SnapToObject=16]="SnapToObject",n[n.All=31]="All",n}(Kt||{}),mr=function(n){return n[n.None=1]="None",n[n.ConnectorSourceThumb=2]="ConnectorSourceThumb",n[n.ConnectorTargetThumb=4]="ConnectorTargetThumb",n[n.ResizeSouthEast=8]="ResizeSouthEast",n[n.ResizeSouthWest=16]="ResizeSouthWest",n[n.ResizeNorthEast=32]="ResizeNorthEast",n[n.ResizeNorthWest=64]="ResizeNorthWest",n[n.ResizeEast=128]="ResizeEast",n[n.ResizeWest=256]="ResizeWest",n[n.ResizeSouth=512]="ResizeSouth",n[n.ResizeNorth=1024]="ResizeNorth",n[n.Rotate=2048]="Rotate",n[n.UserHandle=4096]="UserHandle",n[n.ToolTip=8192]="ToolTip",n[n.ResizeAll=2046]="ResizeAll",n[n.All=16382]="All",n}(mr||{}),qe=function(n){return n[n.None=1]="None",n[n.Select=2]="Select",n[n.Delete=4]="Delete",n[n.Drag=8]="Drag",n[n.DragSourceEnd=16]="DragSourceEnd",n[n.DragTargetEnd=32]="DragTargetEnd",n[n.DragSegmentThumb=64]="DragSegmentThumb",n[n.AllowDrop=128]="AllowDrop",n[n.Bridging=256]="Bridging",n[n.BridgeObstacle=512]="BridgeObstacle",n[n.InheritBridging=1024]="InheritBridging",n[n.PointerEvents=2048]="PointerEvents",n[n.Tooltip=4096]="Tooltip",n[n.InheritTooltip=8192]="InheritTooltip",n[n.Interaction=4218]="Interaction",n[n.ReadOnly=16384]="ReadOnly",n[n.LineRouting=32768]="LineRouting",n[n.InheritLineRouting=65536]="InheritLineRouting",n[n.ConnectToNearByNode=131072]="ConnectToNearByNode",n[n.ConnectToNearByPort=262144]="ConnectToNearByPort",n[n.ConnectToNearByElement=393216]="ConnectToNearByElement",n[n.InheritSegmentThumbShape=524288]="InheritSegmentThumbShape",n[n.InheritSegmentThumbSize=1048576]="InheritSegmentThumbSize",n[n.Default=2043454]="Default",n}(qe||{}),Lr=function(n){return n[n.ReadOnly=2]="ReadOnly",n[n.InheritReadOnly=4]="InheritReadOnly",n[n.Select=8]="Select",n[n.Drag=16]="Drag",n[n.Resize=32]="Resize",n[n.Rotate=64]="Rotate",n[n.Tooltip=128]="Tooltip",n[n.Interaction=120]="Interaction",n[n.None=0]="None",n}(Lr||{}),ie=function(n){return n[n.None=0]="None",n[n.Select=2]="Select",n[n.Drag=4]="Drag",n[n.Rotate=8]="Rotate",n[n.Shadow=16]="Shadow",n[n.PointerEvents=32]="PointerEvents",n[n.Delete=64]="Delete",n[n.InConnect=128]="InConnect",n[n.OutConnect=256]="OutConnect",n[n.Individual=512]="Individual",n[n.Expandable=1024]="Expandable",n[n.AllowDrop=2048]="AllowDrop",n[n.Inherit=78]="Inherit",n[n.ResizeNorthEast=4096]="ResizeNorthEast",n[n.ResizeEast=8192]="ResizeEast",n[n.ResizeSouthEast=16384]="ResizeSouthEast",n[n.ResizeSouth=32768]="ResizeSouth",n[n.ResizeSouthWest=65536]="ResizeSouthWest",n[n.ResizeWest=131072]="ResizeWest",n[n.ResizeNorthWest=262144]="ResizeNorthWest",n[n.ResizeNorth=524288]="ResizeNorth",n[n.Resize=1044480]="Resize",n[n.AspectRatio=1048576]="AspectRatio",n[n.Tooltip=2097152]="Tooltip",n[n.InheritTooltip=4194304]="InheritTooltip",n[n.ReadOnly=8388608]="ReadOnly",n[n.HideThumbs=16777216]="HideThumbs",n[n.AllowMovingOutsideLane=33554432]="AllowMovingOutsideLane",n[n.Default=5240814]="Default",n}(ie||{}),Xr=function(n){return n[n.None=0]="None",n[n.ElementIsPort=2]="ElementIsPort",n[n.ElementIsGroup=4]="ElementIsGroup",n[n.HorizontalLaneHeader=8]="HorizontalLaneHeader",n}(Xr||{}),bt=function(n){return n[n.Rotate=2]="Rotate",n[n.ConnectorSource=4]="ConnectorSource",n[n.ConnectorTarget=8]="ConnectorTarget",n[n.ResizeNorthEast=16]="ResizeNorthEast",n[n.ResizeEast=32]="ResizeEast",n[n.ResizeSouthEast=64]="ResizeSouthEast",n[n.ResizeSouth=128]="ResizeSouth",n[n.ResizeSouthWest=256]="ResizeSouthWest",n[n.ResizeWest=512]="ResizeWest",n[n.ResizeNorthWest=1024]="ResizeNorthWest",n[n.ResizeNorth=2048]="ResizeNorth",n[n.Default=4094]="Default",n}(bt||{}),rt=function(n){return n[n.None=1]="None",n[n.Bridging=2]="Bridging",n[n.UndoRedo=4]="UndoRedo",n[n.Tooltip=8]="Tooltip",n[n.UserInteraction=16]="UserInteraction",n[n.ApiUpdate=32]="ApiUpdate",n[n.PageEditable=48]="PageEditable",n[n.Zoom=64]="Zoom",n[n.PanX=128]="PanX",n[n.PanY=256]="PanY",n[n.Pan=384]="Pan",n[n.ZoomTextEdit=512]="ZoomTextEdit",n[n.Virtualization=1024]="Virtualization",n[n.LineRouting=2048]="LineRouting",n[n.Default=500]="Default",n}(rt||{}),Ci=function(n){return n[n.None=0]="None",n[n.SingleSelect=1]="SingleSelect",n[n.MultipleSelect=2]="MultipleSelect",n[n.ZoomPan=4]="ZoomPan",n[n.DrawOnce=8]="DrawOnce",n[n.ContinuousDraw=16]="ContinuousDraw",n[n.Default=3]="Default",n}(Ci||{}),Ya=function(n){return n[n.Self=1]="Self",n[n.Parent=2]="Parent",n}(Ya||{}),pt=function(n){return n[n.None=0]="None",n[n.Control=1]="Control",n[n.Meta=1]="Meta",n[n.Alt=2]="Alt",n[n.Shift=4]="Shift",n}(pt||{}),Mt=function(n){return n[n.None=null]="None",n[n.Number0=0]="Number0",n[n.Number1=1]="Number1",n[n.Number2=2]="Number2",n[n.Number3=3]="Number3",n[n.Number4=4]="Number4",n[n.Number5=5]="Number5",n[n.Number6=6]="Number6",n[n.Number7=7]="Number7",n[n.Number8=8]="Number8",n[n.Number9=9]="Number9",n[n.A=65]="A",n[n.B=66]="B",n[n.C=67]="C",n[n.D=68]="D",n[n.E=69]="E",n[n.F=70]="F",n[n.G=71]="G",n[n.H=72]="H",n[n.I=73]="I",n[n.J=74]="J",n[n.K=75]="K",n[n.L=76]="L",n[n.M=77]="M",n[n.N=78]="N",n[n.O=79]="O",n[n.P=80]="P",n[n.Q=81]="Q",n[n.R=82]="R",n[n.S=83]="S",n[n.T=84]="T",n[n.U=85]="U",n[n.V=86]="V",n[n.W=87]="W",n[n.X=88]="X",n[n.Y=89]="Y",n[n.Z=90]="Z",n[n.Left=37]="Left",n[n.Up=38]="Up",n[n.Right=39]="Right",n[n.Down=40]="Down",n[n.Escape=27]="Escape",n[n.Space=32]="Space",n[n.PageUp=33]="PageUp",n[n.PageDown=34]="PageDown",n[n.End=35]="End",n[n.Home=36]="Home",n[n.Delete=46]="Delete",n[n.Tab=9]="Tab",n[n.Enter=13]="Enter",n[n.BackSpace=8]="BackSpace",n[n.F1=112]="F1",n[n.F2=113]="F2",n[n.F3=114]="F3",n[n.F4=115]="F4",n[n.F5=116]="F5",n[n.F6=117]="F6",n[n.F7=118]="F7",n[n.F8=119]="F8",n[n.F9=120]="F9",n[n.F10=121]="F10",n[n.F11=122]="F11",n[n.F12=123]="F12",n[n.Star=56]="Star",n[n.Plus=187]="Plus",n[n.Minus=189]="Minus",n[n.BracketLeft=219]="BracketLeft",n[n.BracketRight=221]="BracketRight",n}(Mt||{}),ee=function(n){return n[n.Render=2]="Render",n[n.PublicMethod=4]="PublicMethod",n[n.ToolAction=8]="ToolAction",n[n.UndoRedo=16]="UndoRedo",n[n.TextEdit=32]="TextEdit",n[n.Group=64]="Group",n[n.Clear=128]="Clear",n[n.PreventClearSelection=256]="PreventClearSelection",n[n.Interactions=512]="Interactions",n[n.PreventHistory=1024]="PreventHistory",n[n.PreventIconsUpdate=2048]="PreventIconsUpdate",n[n.PreventCollectionChangeOnDragOver=4096]="PreventCollectionChangeOnDragOver",n[n.PreventZIndexOnDragging=8192]="PreventZIndexOnDragging",n[n.isGroupDragging=16384]="isGroupDragging",n[n.DragUsingMouse=32768]="DragUsingMouse",n[n.DecoratorPropertyChange=65536]="DecoratorPropertyChange",n[n.PreventLaneContainerUpdate=131072]="PreventLaneContainerUpdate",n}(ee||{}),Qa=function(n){return n[n.None=2]="None",n[n.DrawSelectorBorder=4]="DrawSelectorBorder",n[n.PreventRenderSelector=8]="PreventRenderSelector",n}(Qa||{}),$i=function(n){return n[n.None=0]="None",n[n.PreventDrag=2]="PreventDrag",n[n.PreventScale=4]="PreventScale",n[n.PreventDataInit=8]="PreventDataInit",n[n.hScrollbarMoved=16]="hScrollbarMoved",n[n.vScrollbarMoved=32]="vScrollbarMoved",n[n.AnimationClick=64]="AnimationClick",n[n.EnableGroupAction=128]="EnableGroupAction",n[n.PanInProgress=256]="PanInProgress",n[n.OverViewAction=512]="OverViewAction",n}($i||{}),ca=function(n){return n[n.None=0]="None",n[n.PropertyChange=1024]="PropertyChange",n[n.Interaction=2048]="Interaction",n}(ca||{}),Ae=function(n){return n[n.Zero=0]="Zero",n[n.One=1]="One",n[n.Two=2]="Two",n[n.Three=3]="Three",n[n.Four=4]="Four",n[n.Five=5]="Five",n}(Ae||{}),Ce=function(n){return n[n.collectionChange=0]="collectionChange",n[n.rotateChange=1]="rotateChange",n[n.positionChange=2]="positionChange",n[n.propertyChange=3]="propertyChange",n[n.selectionChange=4]="selectionChange",n[n.sizeChange=5]="sizeChange",n[n.drop=6]="drop",n[n.sourcePointChange=7]="sourcePointChange",n[n.targetPointChange=8]="targetPointChange",n[n.connectionChange=9]="connectionChange",n[n.animationComplete=10]="animationComplete",n[n.click=11]="click",n[n.doubleClick=12]="doubleClick",n[n.scrollChange=13]="scrollChange",n[n.dragEnter=14]="dragEnter",n[n.dragLeave=15]="dragLeave",n[n.dragOver=16]="dragOver",n[n.textEdit=17]="textEdit",n[n.paletteSelectionChange=18]="paletteSelectionChange",n[n.historyChange=19]="historyChange",n[n.mouseEnter=20]="mouseEnter",n[n.mouseLeave=21]="mouseLeave",n[n.mouseOver=22]="mouseOver",n[n.expandStateChange=23]="expandStateChange",n[n.segmentCollectionChange=24]="segmentCollectionChange",n[n.commandExecute=25]="commandExecute",n[n.historyStateChange=26]="historyStateChange",n[n.onUserHandleMouseDown=27]="onUserHandleMouseDown",n[n.onUserHandleMouseUp=28]="onUserHandleMouseUp",n[n.onUserHandleMouseEnter=29]="onUserHandleMouseEnter",n[n.onUserHandleMouseLeave=30]="onUserHandleMouseLeave",n[n.onImageLoad=31]="onImageLoad",n[n.onDoBindingInit=32]="onDoBindingInit",n[n.keyUp=33]="keyUp",n[n.keyDown=34]="keyDown",n[n.fixedUserHandleClick=35]="fixedUserHandleClick",n[n.elementDraw=36]="elementDraw",n[n.mouseWheel=37]="mouseWheel",n[n.segmentChange=38]="segmentChange",n[n.onFixedUserHandleMouseDown=39]="onFixedUserHandleMouseDown",n[n.onFixedUserHandleMouseUp=40]="onFixedUserHandleMouseUp",n[n.onFixedUserHandleMouseEnter=41]="onFixedUserHandleMouseEnter",n[n.onFixedUserHandleMouseLeave=42]="onFixedUserHandleMouseLeave",n[n.loaded=43]="loaded",n}(Ce||{}),ni=function(n){return n[n.None=1]="None",n[n.Drag=2]="Drag",n[n.Draw=4]="Draw",n[n.InConnect=8]="InConnect",n[n.OutConnect=16]="OutConnect",n[n.ToolTip=32]="ToolTip",n[n.InheritTooltip=64]="InheritTooltip",n[n.Default=24]="Default",n}(ni||{}),Mx=function(n){return n[n.None=1]="None",n[n.Source=2]="Source",n[n.Target=4]="Target",n[n.Intermediate=8]="Intermediate",n[n.All=14]="All",n}(Mx||{}),SI=function(n){return n[n.None=0]="None",n[n.SymmetricAngle=2]="SymmetricAngle",n[n.SymmetricDistance=4]="SymmetricDistance",n[n.Default=6]="Default",n}(SI||{}),as=function(){function n(){this.pivot={x:.5,y:.5},this.isDirt=!0,this.isExport=!1,this.exportScaleValue={x:0,y:0},this.exportScaleOffset={x:0,y:0},this.canApplyStyle=!0,this.visible=!0,this.offsetX=0,this.offsetY=0,this.cornerRadius=0,this.minHeight=void 0,this.minWidth=void 0,this.maxWidth=void 0,this.maxHeight=void 0,this.width=void 0,this.height=void 0,this.rotateAngle=0,this.margin={left:0,right:0,top:0,bottom:0},this.connectionDirection="Auto",this.horizontalAlignment="Auto",this.verticalAlignment="Auto",this.flip="None",this.flipMode="All",this.relativeMode="Point",this.transform=Ya.Self|Ya.Parent,this.style={fill:"white",strokeColor:"black",opacity:1,strokeWidth:1},this.desiredSize=new me,this.actualSize=new me,this.parentTransform=0,this.preventContainer=!1,this.isSvgRender=!1,this.bounds=new Ne(0,0,0,0),this.shadow=null,this.description="",this.staticSize=!1,this.shapeType="",this.isRectElement=!1,this.isCalculateDesiredSize=!0,this.flipOffset={x:0,y:0},this.elementActions=Xr.None,this.inversedAlignment=!0,this.position=void 0,this.unitMode=void 0,this.float=!1,this.floatingBounds=void 0}return n.prototype.setOffsetWithRespectToBounds=function(t,e,i){this.unitMode=i,this.position={x:t,y:e}},n.prototype.getAbsolutePosition=function(t){if(void 0!==this.position)return"Absolute"===this.unitMode?this.position:{x:this.position.x*t.width,y:this.position.y*t.height}},Object.defineProperty(n.prototype,"outerBounds",{get:function(){return this.floatingBounds||this.bounds},set:function(t){this.floatingBounds=t},enumerable:!0,configurable:!0}),n.prototype.measure=function(t,e,i){var s=void 0!==this.height?this.height:(t.height||0)-this.margin.top-this.margin.bottom;return this.id&&0===s&&this.elementActions&Xr.HorizontalLaneHeader&&(s=this.actualSize.height),this.desiredSize=new me(void 0!==this.width?this.width:(t.width||0)-this.margin.left-this.margin.right,s),this.isCalculateDesiredSize&&(this.desiredSize=this.validateDesiredSize(this.desiredSize,t)),this.desiredSize},n.prototype.arrange=function(t){return this.actualSize=t,this.updateBounds(),this.actualSize},n.prototype.updateBounds=function(){this.bounds=yr(this)},n.prototype.validateDesiredSize=function(t,e){return this.isRectElement&&!this.width&&!this.minWidth&&!this.maxWidth&&(t.width=50),this.isRectElement&&!this.height&&!this.minHeight&&!this.maxHeight&&(t.height=50),(void 0===t||void 0!==this.width&&void 0!==this.height)&&((t=t||new me).width=void 0===this.width?(e.width||0)-this.margin.left-this.margin.right:this.width,t.height=void 0===this.height?(e.height||0)-this.margin.top-this.margin.bottom:this.height),void 0!==this.minWidth&&(t.width=Math.max(t.width,this.minWidth)),void 0!==this.minHeight&&(t.height=Math.max(t.height,this.minHeight)),void 0!==this.maxWidth&&0!==this.maxWidth&&(t.width=Math.min(t.width,this.maxWidth)),void 0!==this.maxHeight&&0!==this.maxHeight&&(t.height=Math.min(t.height,this.maxHeight)),t},n}(),Yie=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Cs=function(n){function t(){var e=null!==n&&n.apply(this,arguments)||this;return e.padding=new Rie(0,0,0,0),e.desiredBounds=void 0,e.measureChildren=!0,e.prevRotateAngle=0,e}return Yie(t,n),t.prototype.hasChildren=function(){return void 0!==this.children&&this.children.length>0},t.prototype.measure=function(e,i,r){this.desiredBounds=void 0;var o,a,s=void 0;if(this.hasChildren()){for(var l=0;l=n.width&&s.length>0)i[i.length]={text:s,x:0,dy:0,width:o},s="";else{(s+=a[r+1]||"").indexOf("\n")>-1&&(i[i.length]={text:s,x:0,dy:0,width:Bc(s,n)},s="");var l=Bc(s,n);Math.ceil(l)+2>=n.width&&s.length>0&&(i[i.length]={text:s,x:0,dy:0,width:l},s=""),r===a.length-1&&s.length>0&&(i[i.length]={text:s,x:0,dy:0,width:l},s="")}else i=function coe(n,t,e){var c,d,u,p,i=[],r="",s=0,o=0,a="nowrap"!==n.whiteSpace,h=(t||n.content).split("\n");for(s=0;s0?" ":"")+c[parseInt(o.toString(),10)];var f=Bc(d=c[o+1]?r+" "+c[o+1]:r,n);Math.floor(f)>(e||n.width)-2&&r.length>0?(i[i.length]={text:r,x:0,dy:0,width:d===r?f:r===p?u:Bc(r,n)},r=""):o===c.length-1&&(i[i.length]={text:r,x:0,dy:0,width:f},r=""),p=d,u=f}return i}(n,t,e);else i[i.length]={text:a,x:0,dy:0,width:Bc(a,n)};return i}(l,r,n.isLaneOrientation?i:void 0),n.wrapBounds=a=function doe(n,t){var r,s,e={x:0,width:0},i=0;for(i=0;in.width&&("Ellipsis"===n.textOverflow||"Clip"===n.textOverflow)?0:-r/2:"right"===n.textAlign?-r:t.length>1?0:-r/2,t[parseInt(i.toString(),10)].dy=1.2*n.fontSize,t[parseInt(i.toString(),10)].x=r,e.x=Math.min(e.x,r),e.width=Math.max(e.width,s);return e}(l,o),s.width=a.width,n.wrapBounds.width>=i&&"Wrap"!==l.textOverflow&&(s.width=i),s.height=o.length*n.style.fontSize*1.2,s}(this,0,0,this.isLaneOrientation?e.height:this.width||e.width):this.desiredSize,this.desiredSize=void 0===this.width||void 0===this.height?new me(i.width,i.height):new me(this.width,this.height),this.desiredSize=this.validateDesiredSize(this.desiredSize,e),this.desiredSize},t.prototype.arrange=function(e){return(e.width!==this.actualSize.width||e.height!==this.actualSize.height||this.isDirt)&&(this.doWrap=!0),this.actualSize=e,this.updateBounds(),this.isDirt=!1,this.actualSize},t}(as),Gie=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Ii=function(n){function t(){var e=null!==n&&n.apply(this,arguments)||this;return e.measureChildren=void 0,e}return Gie(t,n),t.prototype.measure=function(e,i,r){var s=void 0,o=void 0;if(this.hasChildren()){for(var a=0,l=this.children;a=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Ed=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Jie(t,n),Th([I("")],t.prototype,"content",void 0),Th([I("TopLeft")],t.prototype,"position",void 0),Th([I("Mouse")],t.prototype,"relativeMode",void 0),Th([I(!0)],t.prototype,"showTipPointer",void 0),Th([I("auto")],t.prototype,"width",void 0),Th([I("auto")],t.prototype,"height",void 0),Th([I("Auto")],t.prototype,"openOn",void 0),Th([I()],t.prototype,"animation",void 0),Th([I(!1)],t.prototype,"isSticky",void 0),t}(Ee);function i3(n){var t=new mh;t=r3(n.tooltip,t);var e=new mh(t);return e.beforeCollision=ere,e.beforeOpen=Kie,e.cssClass="e-diagram-tooltip",e.opensOn="custom",e.appendTo("#"+n.element.id),e.close(),e}function Kie(n){(""===this.content||void 0===this.content)&&(n.element.style.display="none")}function ere(n){n.collidedPosition&&n.collidedPosition!==this.position&&(n.element.style.display="none")}function wx(n,t){var e=n.tooltipObject;return r3(t?t.tooltip:n.tooltip,e),e}function r3(n,t){return n.content?(t.content=n.content,"string"==typeof n.content&&(t.content=ko(function(){return n.content})),t.position=n.position,t.showTipPointer=n.showTipPointer,t.width=n.width,t.height=n.height,t.animation=n.animation?n.animation:{close:{effect:"None"}}):t.close(),t}var Cx=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Hn=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Ex=function(n){function t(e,i,r,s){var o=n.call(this,e,i,r,s)||this;return o.inEdges=[],o.outEdges=[],o}return Cx(t,n),Hn([I("")],t.prototype,"id",void 0),Hn([I("Center")],t.prototype,"horizontalAlignment",void 0),Hn([I("Center")],t.prototype,"verticalAlignment",void 0),Hn([re({},$n)],t.prototype,"margin",void 0),Hn([I(12)],t.prototype,"width",void 0),Hn([I(12)],t.prototype,"height",void 0),Hn([re({},Al)],t.prototype,"style",void 0),Hn([I("Square")],t.prototype,"shape",void 0),Hn([I("Auto")],t.prototype,"connectionDirection",void 0),Hn([I(ti.Connect)],t.prototype,"visibility",void 0),Hn([I("")],t.prototype,"pathData",void 0),Hn([I(ni.Default)],t.prototype,"constraints",void 0),Hn([I()],t.prototype,"addInfo",void 0),Hn([I()],t.prototype,"outEdges",void 0),Hn([I()],t.prototype,"inEdges",void 0),Hn([re({},Ed)],t.prototype,"tooltip",void 0),t}(Ee),Es=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return Cx(t,n),t.prototype.getClassName=function(){return"PointPort"},Hn([re({x:.5,y:.5},z)],t.prototype,"offset",void 0),t}(Ex),xc=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return Cx(t,n),t.prototype.getClassName=function(){return"PathPort"},Hn([I(.5)],t.prototype,"offset",void 0),Hn([re({x:0,y:0},z)],t.prototype,"displacement",void 0),Hn([I("Center")],t.prototype,"alignment",void 0),t}(Ex),MI=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),lr=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},tre=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return MI(t,n),lr([I("blue")],t.prototype,"color",void 0),lr([I("")],t.prototype,"content",void 0),lr([I("")],t.prototype,"link",void 0),lr([I("None")],t.prototype,"textDecoration",void 0),lr([I("NewTab")],t.prototype,"hyperlinkOpenState",void 0),t}(Ee),Dx=function(n){function t(e,i,r,s){var o=n.call(this,e,i,r,s)||this;return r.id||(o.id=e.parentObj&&e.parentObj.propName&&"phases"===e.parentObj.propName?e.parentObj.id:Qe()),o}return MI(t,n),lr([I("")],t.prototype,"content",void 0),lr([I(void 0)],t.prototype,"template",void 0),lr([I("String")],t.prototype,"annotationType",void 0),lr([I(!0)],t.prototype,"visibility",void 0),lr([I(Lr.InheritReadOnly)],t.prototype,"constraints",void 0),lr([re(void 0,tre)],t.prototype,"hyperlink",void 0),lr([I("")],t.prototype,"id",void 0),lr([I()],t.prototype,"width",void 0),lr([I()],t.prototype,"height",void 0),lr([I(0)],t.prototype,"rotateAngle",void 0),lr([I("Parent")],t.prototype,"rotationReference",void 0),lr([re({strokeWidth:0,strokeColor:"transparent",fill:"transparent"},Gp)],t.prototype,"style",void 0),lr([I("Center")],t.prototype,"horizontalAlignment",void 0),lr([I("Center")],t.prototype,"verticalAlignment",void 0),lr([re({},$n)],t.prototype,"margin",void 0),lr([re({top:void 0,bottom:void 0,left:void 0,right:void 0},$n)],t.prototype,"dragLimit",void 0),lr([I("Shape")],t.prototype,"type",void 0),lr([re({},Ed)],t.prototype,"tooltip",void 0),lr([I()],t.prototype,"addInfo",void 0),t}(Ee),Zn=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return MI(t,n),t.prototype.getClassName=function(){return"ShapeAnnotation"},lr([re({x:.5,y:.5},z)],t.prototype,"offset",void 0),t}(Dx),Nr=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return MI(t,n),t.prototype.getClassName=function(){return"PathAnnotation"},lr([I(.5)],t.prototype,"offset",void 0),lr([re({x:0,y:0},z)],t.prototype,"displacement",void 0),lr([I("Center")],t.prototype,"alignment",void 0),lr([I(!1)],t.prototype,"segmentAngle",void 0),t}(Dx);function xx(n){return sre[n.toString()]}function n3(n){return lre[""+n]}var sre={X:"M14,14 L106,106 M106,14 L14,106",Circle:"M0,50 A50,50,0 1 1 100,50 A50,50,0 1 1 0,50 Z",Square:"M0,0 L10,0 L10,10 L0,10 z"},ore={OpenArrow:"M15.9,23 L5,16 L15.9,9 L17,10.7 L8.7,16 L17,21.3Z",Square:"M0,0 L10,0 L10,10 L0,10 z",Fletch:"M14.8,10c0,0-3.5,6,0.2,12c0,0-2.5-6-10.9-6C4.1,16,11.3,16,14.8,10z",OpenFetch:"M6,17c-0.6,0-1-0.4-1-1s0.4-1,1-1c10.9,0,11-5,11-5c0-0.6,0.4-1,1-1s1,0.4,1,1C19,10.3,18.9,17,6,17C6,17,6,17,6,17z M18,23c-0.5,0-1-0.4-1-1c0-0.2-0.3-5-11-5c-0.6,0-1-0.5-1-1s0.4-1,1-1c0,0,0,0,0,0c12.9,0,13,6.7,13,7 C19,22.6,18.6,23,18,23z",IndentedArrow:"M17,10c0,0-4.5,5.5,0,12L5,16L17,10z",OutdentedArrow:"M14.6,10c0,0,5.4,6,0,12L5,16L14.6,10z",DoubleArrow:"M19,10 L19,22 L13,16Z M12,10 L12,22 L6,16Z",Arrow:"M15,10 L15,22 L5,16Z",Diamond:"M12,23l-7-7l7-7l6.9,7L12,23z",Circle:"M0,50 A50,50,0 1 1 100,50 A50,50,0 1 1 0,50 Z"},are={Square:"M0,0 L10,0 L10,10 L0,10 z",Rhombus:"M10,5 L5,10 L0,5 L5,0 L10,5 Z ",Rectangle:"M0,0 L15,0 L15,10 L0,10 z ",OpenArrow:"M15.9,23 L5,16 L15.9,9 L17,10.7 L8.7,16 L17,21.3Z",Fletch:"M9.82,0 C9.82,0,6.61,5,10,10 C10,10,7.71,5,0,5 C0,5,6.61,5,9.82,0 Z ",OpenFetch:"M0.71,5.71 C0.29,5.71,0,5.43,0,5 C0,4.57,0.29,4.29,0.71,4.29 C8.5,4.29,8.57,0.71,8.57,0.71 C8.57,0.29,8.86,0,9.29,0 C9.719999999999999,0,10,0.29,10,0.71 C10,0.93,9.93,5.71,0.71,5.71 C0.71,5.71,0.71,5.71,0.71,5.71 Z M9.29,10 C8.93,10,8.57,9.71,8.57,9.29 C8.57,9.14,8.36,5.71,0.71,5.71 C0.29,5.71,0,5.36,0,5 C0,4.64,0.29,4.29,0.71,4.29 C0.71,4.29,0.71,4.29,0.71,4.29 C9.93,4.29,10,9.07,10,9.29 C10,9.71,9.71,10,9.29,10 Z ",IndentedArrow:"M10,0 C10,0,6.25,4.58,10,10 L0,5 L10,0 Z ",OutdentedArrow:"M8,0 C8,0,12.5,5,8,10 L0,5 L8,0 Z ",DoubleArrow:"M19,10 L19,22 L13,16Z M12,10 L12,22 L6,16Z",Arrow:"M15,10 L15,22 L5,16Z",Diamond:"M10,5 L5,10 L0,5 L5,0 L10,5 Z ",Circle:"M10,5 C10,7.76,7.76,10,5,10 C2.24,10,0,7.76,0,5 C0,2.24,2.24,0,5,0 C7.76,0,10,2.24,10,5 Z ",Ellipse:"M15,5 C15,7.76,11.64,10,7.5,10 C3.36,10,0,7.76,0,5 C0,2.24,3.36,0,7.5,0 C11.64,0,15,2.24,15,5 Z "},lre={Square:"M0,0 L10,0 L10,10 L0,10 z",Rhombus:"M10,5 L5,10 L0,5 L5,0 L10,5 Z ",Rectangle:"M0,0 L15,0 L15,10 L0,10 z",OpenArrow:"M23,15.9 L16,5 L9,15.9 L10.7,17 L16,8.7 L21,17.3Z",Fletch:"M9.82,0 C9.82,0,6.61,5,10,10 C10,10,7.71,5,0,5 C0,5,6.61,5,9.82,0 Z ",OpenFetch:"M0.71,5.71 C0.29,5.71,0,5.43,0,5 C0,4.57,0.29,4.29,0.71,4.29 C8.5,4.29,8.57,0.71,8.57,0.71 C8.57,0.29,8.86,0,9.29,0 C9.719999999999999,0,10,0.29,10,0.71 C10,0.93,9.93,5.71,0.71,5.71 C0.71,5.71,0.71,5.71,0.71,5.71 Z M9.29,10 C8.93,10,8.57,9.71,8.57,9.29 C8.57,9.14,8.36,5.71,0.71,5.71 C0.29,5.71,0,5.36,0,5 C0,4.64,0.29,4.29,0.71,4.29 C0.71,4.29,0.71,4.29,0.71,4.29 C9.93,4.29,10,9.07,10,9.29 C10,9.71,9.71,10,9.29,10 Z ",IndentedArrow:"M10,0 C10,0,6.25,4.58,10,10 L0,5 L10,0 Z ",OutdentedArrow:"M8,0 C8,0,12.5,5,8,10 L0,5 L8,0 Z ",DoubleArrow:"M10,19 L22,19 L16,13Z M10,12 L22,12 L16,6Z",Arrow:"M10,15 L22,15 L16,5Z",Diamond:"M10,5 L5,10 L0,5 L5,0 L10,5 Z ",Circle:"M10,5 C10,7.76,7.76,10,5,10 C2.24,10,0,7.76,0,5 C0,2.24,2.24,0,5,0 C7.76,0,10,2.24,10,5 Z ",Ellipse:"M15,5 C15,7.76,11.64,10,7.5,10 C3.36,10,0,7.76,0,5 C0,2.24,3.36,0,7.5,0 C11.64,0,15,2.24,15,5 Z "};function Tx(n){return hre[n.toString()]}var hre={Process:"M419.511,76.687L359.511,76.687L359.511,43.086L419.511,43.086z",Decision:"M 253.005,115.687L 200.567,146.071L 148.097,115.687L 200.534,85.304L 253.005,115.687 Z",Document:"M 60 31.9 c 0 0 -11 -7.7 -30 0 s -30 0 -30 0 V 0 h 60 V 31.9 Z",PreDefinedProcess:"M 0,0 L 50,0 L 50,50 L 0,50 Z M 8.334,0 L 8.334,50 M 41.667,0 L 41.667,50",Terminator:"M 269.711,29.33C 269.71,44.061 257.77,56 243.04,56L 158.058,56C 143.33,56 131.39,44.061 131.39,29.33L 131.39,29.33C 131.391,14.6057 143.33,2.669 158.058,2.669L 243.044,2.669C 257.772,2.669 269.711,14.6057 269.711,29.333 Z",PaperTap:"M0.0009,17.2042 L0.0009,47.165 C0.001,47.165 14.403,53.5455 25.00,47.165 C35.599,40.7852 44.403,43.5087 50.00,47.165L50.001,17.2042 M50.001,32.7987 L50.001,2.8405 C50.001,2.8405 35.599,-3.5427 25.001,2.8405C14.403,9.2237 5.599,6.494 0.0009,2.8405 L0.0009,32.7987",DirectData:"M 132.62 0 L 17.38 0 C 7.78 0 0 13.43 0 30 C 0 46.57 7.78 60 17.38 60 L 132.62 60 M 132.62 0C 123.02 0 115.24 13.43 115.24 30 C 115.24 46.57 123.02 60 132.62 60 C 142.22 60 150 46.57 150 30 C 150 13.43 142.22 0 132.62 0 z ",SequentialData:"M0.0029,24.999 C0.0029,11.1922 10.433,0.0021 23.295,0.0021 C36.159,0.00216 46.585,11.1922 46.585,24.999C46.585,38.8057 36.159,49.9979 23.295,49.9979 C10.433,49.9979 0.0029,38.8057 0.0029,24.999 z M23.294,49.999 L50.002,49.999",Sort:"M50.001,24.9971 L25.001,49.9971 L0.00097,24.9971 L25.001,-0.00286865 L50.001,24.9971 z M0.000976562,24.9971 L50.001,24.9971",MultiDocument:"M43.6826,40 C44.8746,40.6183 45.8586,41.3502 46.8366,42.1122 L46.8366,4.74487 L3.09857,4.74487 L3.09857,10.9544 M46.837,35.143 C48.027,35.765 49.025,36.604 50.003,37.369 L50.003,0.002 L6.264,0.002 L6.264,4.744 M43.682,47.113 L43.682,10.765 L0.0025,10.7652 L0.0025,47.1132 C0.0025,47.1132 12.5846,53.6101 21.8426,47.1132 C31.1006,40.6163 38.792,43.393 43.6826,47.1132 z",Collate:"M50.001,0.0028 L25.001,25.0029 L0.00097,0.0028 L50.001,0.002 z M0.0009,50.002 L25.001,25.002L50.001,50.002 L0.0009,50.0029 z",SummingJunction:"M7.3252,42.6768 L42.6772,7.3247 M42.6768,42.6768 L7.3248,7.3247 M0.0009,25.001 C0.0009,11.193 11.197,0.0009 25.001,0.0009 C38.809,0.0009 50.001,11.193 50.001,25.001 C50.001,38.809 38.809,50.001 25.001,50.001 C11.197,50.00 0.0009,38.809 0.0009,25.00 z",Or:"M 0 50 L 100 50 M 50 100 L 50 0.0 M 0 50 C 0 22.384 22.392 0 50 0 C 77.616 0 100 22.384 100 50 C 100 77.616 77.616 100 50 100 C 22.392 100 0 77.616 0 50 Z",InternalStorage:"M 0 3.81946A 2.5,3.81946 0 0,1 2.5,0L 47.5 0A 2.5,3.81946 0 0,1 50,3.81946L 50 45.836A 2.5,3.819446 0 0,1 47.5,49.652778L 2.5 49.652778A 2.5,3.819446 0 0,1 0,45.8336L 0 3.819446ZM 0 11.45834L 50 11.4583334M 12.5 0L 12.5 49.652778",Extract:"M0,35 L30,0 L60,35 Z",ManualOperation:"M46.4,28.8 L14.8,28.8 L0,0 L60,0 Z",Merge:"M60,0 L30,35 L0,0 Z",OffPageReference:"M60,33.3 L30.1,39 L0,33.3 L0,0 L60,0 Z",SequentialAccessStorage:"M 60 30 C 60 13.4 46.6 0 30 0 S 0 13.4 0 30 s 13.4 30 30 30 h 28.6 v -6.5 h -9.9C 55.5 48 60 39.5 60 30 Z",Annotation:"M49.9984,50.0029 L-0.00271199,50.0029 L-0.00271199,0.00286865 L49.9984,0.00286865",Annotation2:"M49.9977,50.0029 L25.416,50.0029 L25.416,0.00286865 L49.9977,0.00286865 M25.4166,25.0029 L-0.00227869,25.0029",Data:"M 10 0 L 40 0 L 30 40 L 0 40 Z",Card:"M275,60 L400,60 L400,110 L260,110 L260,75 Z",Delay:"M0,0 L12.029,0 C14.212999,0 16,1.7869979 16,3.9709952 C16,6.1549926 14.212999,7.9409904 12.029,7.9409904 L0,7.9409904 z",Preparation:"M 1048.17 572 C 1051.06 568.86 1055.17 567.05 1059.5 567 L 1094.51 567 C 1098.84 567.05 1102.95 568.86 1105.84 572 L 1126.43 595 C 1127.01 596.28 1127.01 597.72 1126.43 599 L 1105.84 622 C 1102.95 625.14 1098.84 626.95 1094.51 627 L 1059.5 627 C 1055.17 626.95 1051.06 625.14 1048.17 622 L 1027.58 599 C 1027 597.72 1027 596.28 1027.58 595 L 1048.17 572 Z",Display:"M47.8809,19.2914 L32.7968,-0.00594145 L11.3902,-0.00594145 C7.93166,-0.00594145 0.00124586,11.187 0.00124586,24.9968C0.00124586,38.8032 7.93166,49.9962 11.3902,49.9962 L32.7968,49.99 L47.615,31.038 C47.615,31.0388 52.798,24.9968 47.880,19.2914 z",ManualInput:"M 912 732 L 1006.85 707 C 1008.2 707 1009.5 707.53 1010.46 708.46 C 1011.41 709.4 1011.95 710.67 1011.95 712 L 1011.95 762C 1012 764.41 1010.28 766.52 1007.87 767 L 917.1 767 C 915.75 767 914.45 766.47 913.49 765.54 C 912.54 764.6 912 763.33 912 762 L 912 732 Z",LoopLimit:"M 8 9 L 27 9 L 33 15 L 33 26 C 33 27 33 27 32 27 L 4 27 C 3 27 2 27 2 26 L 2 15 L 8 9 Z",StoredData:"M 5.55 0L 50 0A 1.5,30 0 0,1 50,0A 5.555,25 0 0,0 50,50A 1.5,30 0 0,1 50,50L 5.555 50A 5.55,25 0 0,1 5.555,0Z"};function s3(n,t,e){var i;i="Straight"!==n.type&&n.sourceWrapper?n.sourceWrapper.corners.center:function cre(n){var t;if(n.sourcePortWrapper){var e=n.sourcePortWrapper;t={x:e.offsetX,y:e.offsetY}}else t=n.sourceID&&n.sourceWrapper&&n.targetWrapper?Ah(n,0,n.sourceWrapper.corners.center,n.targetWrapper.corners.center,!1):n.sourcePoint;return t}(n);var r=function ure(n,t,e,i,r){var b,M,s=n.sourceWrapper,o=n.targetWrapper,a=n.sourcePortWrapper,l=n.targetPortWrapper,d=[],f=Ga(n),y={corners:undefined,point:t,direction:undefined,margin:{left:5,right:5,bottom:5,top:5}},S={corners:undefined,point:e,direction:undefined,margin:{left:5,right:5,bottom:5,top:5}};if(void 0!==s&&void 0!==o&&(b=En(s),M=En(o),y.corners=s.corners,S.corners=o.corners),void 0!==a&&(y.direction="Left"===a.connectionDirection||"Top"===a.connectionDirection||"Bottom"===a.connectionDirection||"Right"===a.connectionDirection?a.connectionDirection:zo({x:a.offsetX,y:a.offsetY},b,s.bounds)),void 0!==l&&(S.direction="Left"===l.connectionDirection||"Right"===l.connectionDirection||"Bottom"===l.connectionDirection||"Top"===l.connectionDirection?l.connectionDirection:zo({x:l.offsetX,y:l.offsetY},M,o.bounds)),"Bezier"===n.type&&!n.isBezierEditing&&n.segments.length>0)for(var D=n.segments.length-1;D>=0;)n.segments[parseInt(D.toString(),10)].isInternalSegment&&n.segments.pop(),D--;if(void 0!==s&&void 0!==o)return(void 0===y.direction||void 0===S.direction)&&(i?function dre(n,t,e){"LeftToRight"===e?(n.direction=n.direction?n.direction:"Right",t.direction=t.direction?t.direction:"Left"):"RightToLeft"===e?(n.direction=n.direction?n.direction:"Left",t.direction=t.direction?t.direction:"Right"):"TopToBottom"===e?(n.direction=n.direction?n.direction:"Bottom",t.direction=t.direction?t.direction:"Top"):"BottomToTop"===e&&(n.direction=n.direction?n.direction:"Top",t.direction=t.direction?t.direction:"Bottom")}(y,S,i):y.corners.top>S.corners.bottom&&Math.abs(y.corners.top-S.corners.bottom)>f?(y.direction=y.direction?y.direction:"Top",S.direction=S.direction?S.direction:"Bottom"):y.corners.bottomf?(y.direction=y.direction?y.direction:"Bottom",S.direction=S.direction?S.direction:"Top"):y.corners.rightf||y.corners.right+f=y.corners.left-f&&y.corners.left>S.corners.left?(y.direction=y.direction?y.direction:"Right",S.direction=S.direction?S.direction:"Left"):y.corners.left>S.corners.right&&Math.abs(y.corners.left-S.corners.right)>y.margin.left+y.margin.right||S.corners.right+f=S.corners.left-f&&y.corners.left0&&n.segments[0].direction&&(y.direction=n.segments[0].direction),y.point=Tc(b,y.direction),d=Tc(b,ls(y.direction)),y.point=Ah(n,0,y.point,d,!1)):y.point=o.corners.center;if(void 0!==h){switch(S.point={x:h.offsetX,y:h.offsetY},S.direction){case"Bottom":case"Top":S.point.y=S.point.y;break;case"Left":case"Right":S.point.x=S.point.x}n.targetPadding&&!w&&(S.point=wI(n,y,S,!0))}else"Orthogonal"===n.type||"Bezier"===n.type?(S.point=Tc(M,S.direction),d=Tc(M,ls(S.direction)),S.point=Ah(n,0,S.point,d,!0)):S.point=a.corners.center;if("Orthogonal"!==n.type){var C=void 0,D=void 0;if("Bezier"===n.type){if(n.bezierSettings.allowSegmentsReset||0===n.segments.length||!z.isEmptyPoint(n.segments[n.segments.length-1].point))return c=g3(n,y,S,void 0,s),Ax(n,y,S);Bv(n)}else Bv(n);if(void 0===n.sourcePortWrapper){y.point=y.corners.center,n.segments&&n.segments.length>0&&(C=z.isEmptyPoint((D=n.segments[0]).point)?void 0:D);var A=void 0!==C?C.point:S.point;if("Bezier"===n.type&&n.segments.length>0&&n.segments[0].vector1.angle&&n.segments[0].vector1.distance){var x=Math.max(y.corners.width,y.corners.height);A=z.transform(y.point,n.segments[0].vector1.angle,x/2)}y.point=w?n.sourceWrapper.bounds.center:Ah(n,0,y.point,A,!1)}if(void 0===n.targetPortWrapper){S.point=S.corners.center,n.segments&&n.segments.length>1&&(C=z.isEmptyPoint((D=n.segments[n.segments.length-2]).point)?void 0:D);var R=C?C.point:y.point;"Bezier"===n.type&&n.segments.length>0&&n.segments[n.segments.length-1].vector2.angle&&n.segments[n.segments.length-1].vector2.distance&&(x=Math.max(y.corners.width,y.corners.height),R=z.transform(S.point,n.segments[0].vector2.angle,x/2)),S.point=w?n.targetWrapper.bounds.center:Ah(n,0,R,S.point,!0)}c=Ax(n,y,S)}else"Orthogonal"===n.type&&n.segments&&n.segments.length>0&&null!==n.segments[0].direction?c=function Mre(n,t,e,i,r,s,o){var a,h,c,d;Bv(n);for(var u=0;u0&&n.segments[u-1].direction===h.direction?u=u3(n,u,t):h.direction?t.point=o3(t,n.segments[parseInt(u.toString(),10)]):(p=n.segments[u-1])&&p.points&&(t.point=p.points[p.points.length-1]),u===n.segments.length-1)if(p3(n,t),c3(a=void 0===r?bre(n,t,e):l3(n,t,e),n),h.points=[],a.length>=2)for(c=0;c2&&n.segments.length>2){var f={x:a[parseInt(c.toString(),10)].x,y:t.point.y};h.points=[],h.points.push(f),h.points.push(a[parseInt(c.toString(),10)]);var p=n.segments[u-1];n.segments.length<4&&p.points.pop(),p.points=p.points.concat(h.points)}else h.points.push(a[parseInt(c.toString(),10)]);else h.points.push(a[parseInt(c.toString(),10)]);else d=u;if(void 0!==d&&!n.selectedSegmentIndex&&(d===n.segments.length-1&&(n.segments[d-1].direction=null,n.segments[d-1].length=null),n.segments.splice(d,1)),i&&0===u){var g=h3(n,i,s);g&&(t.point=g)}}return f3(n,[])}(n,y,S,l,h,o):(n.segments[0]||(C=new bi(n,"segments",{type:"Orthogonal"},!0),n.segments.push(C)),n.segments[0].points=c=g3(n,y,S,void 0,s));return c}(n,y.direction,S.direction,y.point,S.point,r);if(Bv(n),(n.sourceWrapper||n.targetWrapper)&&function mre(n,t,e){var i=n.sourcePortWrapper,r=n.targetPortWrapper,s=n.sourceWrapper,o=t.point,a={left:0,right:0,top:0,bottom:0},l={x:0,y:0},c="Top";if(s?(o=e.point,a=t.margin):(s=n.targetWrapper,a=e.margin),"Orthogonal"===n.type)if(n.segments&&n.segments.length>0&&n.sourceWrapper&&n.segments[0].direction)t.direction=n.segments[0].direction,l=Ah(n,0,l=Tc(s.corners,t.direction),Tc(s.corners,ls(t.direction)),!1);else{var u={corners:null,direction:null,point:null,margin:null};Fv(s,{corners:null,direction:null,point:o,margin:a},u,n),l=u.point,c=u.direction}else{var p=void 0;n.segments&&n.segments.length>1&&(p=s===n.sourceWrapper?n.segments[0].point:n.segments[n.segments.length-2].point),l=Ah(n,0,s.bounds.center,n.segments&&n.segments.length>1?p:o,s===n.targetWrapper)}s===n.sourceWrapper?(t.direction=t.direction||c,t.point=l,n.sourcePortWrapper&&(t.point={x:i.offsetX,y:i.offsetY},n.sourcePadding&&(t.point=wI(n,t,e,!1)))):(e.direction=e.direction||c,e.point=l,n.targetPortWrapper&&(e.point={x:r.offsetX,y:r.offsetY},n.targetPadding&&(e.point=wI(n,t,e,!0))))}(n,y,S),"Straight"===n.type||"Bezier"===n.type)d=Ax(n,y,S);else if("Orthogonal"===n.type&&n.segments&&n.segments.length>0&&null!==n.segments[0].length&&null!==n.segments[0].direction)d=function vre(n,t,e,i,r,s,o){var a,l,c,u,h=[];if(Bv(n),n.segments.length>0){for(var p=0;p0&&n.segments[p-1].direction===f.direction)p=u3(n,p,t);else{var g=n.segments[p-1];t.point=f.direction?o3(t,f):g.points[g.points.length-1]}if(p===n.segments.length-1&&(o||r?n.targetWrapper&&void 0===n.targetPortWrapper?(p3(n,t),l=fre(n,t,e)):l=l3(n,t,e):l=pre(n,t,e),l))if(c3(l,n),f.points=[],l.length>=2)for(a=0;at.corners.top&&e.point.ye.point.x?"Left":"Right"):e.point.x>t.corners.left&&e.point.xe.point.y?"Top":"Bottom")),n.sourcePortWrapper&&s===ls(r)?(("Left"===s||"Right"===s)&&t.point.y>=t.corners.top&&t.point.y<=t.corners.center.y&&e.point.y>=t.corners.top&&e.point.y<=t.corners.center.y?(t.direction="Top",a=t.point.y-t.corners.top+20):("Left"===s||"Right"===s)&&t.point.y>t.corners.center.y&&t.point.y<=t.corners.bottom&&e.point.y>t.corners.center.y&&e.point.y<=t.corners.bottom?(t.direction="Bottom",a=t.corners.bottom-t.point.y+20):("Top"===s||"Bottom"===s)&&t.point.x>=t.corners.left&&t.point.x<=t.corners.center.x&&e.point.x>=t.corners.left&&e.point.x<=t.corners.center.x?(t.direction="Left",a=t.point.x-t.corners.left+20):("Top"===s||"Bottom"===s)&&t.point.x<=t.corners.right&&t.point.x>t.corners.center.x&&e.point.x<=t.corners.right&&e.point.xt.point.y&&t.point.y>=e.corners.top?(i="Top",r=t.point.y-e.corners.top+20):e.corners.center.y===t.point.y&&"Top"===n.segments[n.segments.length-2].direction||e.corners.center.ye.point.y?t.point.y-t.corners.top+20:t.corners.bottom-t.point.y+20):(i="Top",r=e.corners.height/2+20):e.corners.center.x!==t.point.x||e.corners.topt.point.x&&t.point.x>=e.corners.left?(i="Left",r=t.point.x-e.corners.left+20):e.corners.center.x===t.point.x&&"Left"===n.segments[n.segments.length-2].direction||e.corners.center.x<=t.point.x&&t.point.x<=e.corners.right?(i="Right",r=e.corners.right-t.point.x+20):void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&t.corners.left<=t.point.x&&t.point.x<=t.corners.right&&(i=t.direction,r=t.point.x>e.point.x?t.point.x-t.corners.left+20:t.corners.right-t.point.x+20):(i="Left",r=e.corners.width/2+20);var a=t.point;t.point=Bn(t.point,"Left"===i||"Top"===i?-r:r,"Left"===i||"Right"===i?0:90),t.direction=z.direction(t.point,e.point),void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&(t.corners.center.x===e.corners.center.x||t.corners.center.y===e.corners.center.y)&&(t.direction=e.direction);var l=Ys(n,t,e);return l.splice(0,0,a),l}function l3(n,t,e){var i,r;e.corners=n.targetWrapper.corners,void 0!==n.sourcePortWrapper&&(r=zo({x:n.sourcePortWrapper.offsetX,y:n.sourcePortWrapper.offsetY},En(n.sourceWrapper),n.sourceWrapper.bounds));var a=function gre(n,t,e,i){var r=!1;switch(e.direction){case"Left":void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&"Right"===i&&t.point.x>e.point.x&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom||("Bottom"===i&&t.point.y>e.point.y||"Top"===i&&t.point.y=t.corners.left&&t.point.x<=t.corners.right?(t.direction="Right"===i?t.point.y>e.point.y?"Top":"Bottom":t.point.xe.point.x&&(t.point.y>e.point.y||t.point.yt.point.y&&e.corners.bottome.point.y||t.point.x>e.point.x&&t.point.y<=e.point.y&&e.corners.top=t.point.y?t.direction="Top":t.point.xe.point.x&&t.point.y>e.point.y&&e.corners.bottomt.point.y?t.direction="Bottom":t.point.y===e.point.y&&t.point.xe.point.y||"Top"===i&&t.point.ye.point.x&&t.point.x>=t.corners.left&&t.point.x<=t.corners.right?(t.direction=t.point.x>e.point.x?"Left":"Right",r=!0):void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&"Left"===i&&t.point.x=t.corners.top&&t.point.y<=t.corners.bottom?(t.direction=t.point.y>e.point.y?"Top":"Bottom",r=!0):t.point.x=t.point.y&&t.point.y===e.point.y||t.point.y>e.point.y&&t.point.x>e.point.x?t.direction="Top":t.point.ye.point.x?t.direction="Bottom":t.point.xe.point.y||t.point.ye.point.x&&(t.direction="Left");break;case"Top":void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&"Bottom"===i&&t.point.y>e.point.y&&t.point.x>=t.corners.left&&t.point.x<=t.corners.right||("Right"===i&&t.point.x>e.point.x||"Left"===i&&e.point.y>t.point.y&&e.point.x>t.point.x)&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom?(t.direction="Bottom"===i?t.point.x>e.point.x?"Left":"Right":t.point.ye.point.y&&t.point.x>e.corners.left&&t.point.x=e.point.y?t.direction="Top":t.point.ye.point.x?t.direction="Left":t.point.yt.point.x)&&t.point.y>e.point.y&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom||"Top"===i&&t.point.y=t.corners.left&&t.point.x<=t.corners.right)?(t.direction="Right"===i||"Left"===i?t.point.y>e.point.y?"Top":"Bottom":t.point.x>e.point.x?"Left":"Right",r=!0):t.point.ye.corners.left&&e.corners.right>t.point.x?t.point.ye.corners.left&&e.corners.center.x>=t.point.x?t.direction="Left":t.point.ye.point.y&&t.point.x>e.point.x?t.direction="Left":t.point.y>e.point.y&&t.point.xe.point.x||e.point.x>t.point.x)&&(t.direction="Bottom")}return r}(n,t,e,r);return!n.selectedSegmentIndex&&void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&e.direction===ls(r)&&(("Left"===e.direction&&t.point.x>e.point.x||"Right"===e.direction&&t.point.x=t.corners.top&&t.point.y<=t.corners.bottom||"Bottom"===e.direction&&t.point.y=t.corners.left&&t.point.x<=t.corners.right)?i=a3(n,t,e):n.selectedSegmentIndex||t.direction!==e.direction?!n.selectedSegmentIndex&&("Left"===e.direction&&t.point.x>e.point.x||"Right"===e.direction&&t.point.x=t.point.y||"Top"===e.direction&&t.point.y>e.point.y||"Bottom"===e.direction&&t.point.y=t.point.x?i=n.selectedSegmentIndex?Ll(t,e):a3(n,t,e):!n.selectedSegmentIndex&&void 0!==n.sourceWrapper&&void 0!==n.targetWrapper&&void 0!==n.targetPortWrapper&&("Left"===t.direction||"Right"===t.direction)&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom&&("Top"===e.direction||"Bottom"===e.direction)&&e.corners.center.x===t.corners.center.x?(t.direction="Top"===e.direction?"Bottom":"Top",i=Ys(n,t,e,"Top"===e.direction?t.corners.bottom-t.point.y+20:t.point.y-t.corners.top+20)):!n.selectedSegmentIndex&&void 0!==n.sourceWrapper&&void 0!==n.targetWrapper&&void 0!==n.targetPortWrapper&&("Top"===t.direction||"Bottom"===t.direction)&&t.point.x>=t.corners.left&&t.point.x<=t.corners.right&&("Left"===e.direction||"Right"===e.direction)&&e.corners.center.y===t.corners.center.y?(t.direction="Left"===e.direction?"Right":"Left",i=Ys(n,t,e,"Left"===e.direction?t.corners.right-t.point.x+20:t.point.x-t.corners.left+20)):i=a?Ys(n,t,e,"Left"===t.direction||"Right"===t.direction?"Left"===t.direction?t.point.x-t.corners.left+20:t.corners.right-t.point.x+20:"Top"===t.direction?t.point.y-t.corners.top+20:t.corners.bottom-t.point.y+20):Ll(t,e):i=Ys(n,t,e),i}function h3(n,t,e){var r,i={x:t.offsetX,y:t.offsetY},s=En(e),o=zo(i,s,e.bounds),a=n.segments[0];return a.direction!==o&&(function wre(n,t,e,i,r,s){var a,h,o=13,l=[];l.push(i),i.y===r.y&&("Left"===t&&r.xi.x)||i.x===r.x&&("Top"===t&&r.yi.y)||("Top"===t||"Bottom"===t?"Top"===t&&r.yi.y-o||"Bottom"===t&&r.y>i.y&&r.yo&&("Top"===t&&r.yi.y)?l.push({x:i.x,y:r.y}):(a=r.xi.x-o||"right"===t&&r.x>i.x&&r.xo&&("Left"===t&&r.xi.x)?l.push({x:r.x,y:i.y}):(l.push({x:a="Left"===t?e.left-o:e.right+o,y:i.y}),l.push({x:a,y:r.y})),s&&(l.push(n.points[0]),l.reverse()),n.points=l)}(a,o,s,a.points[0],a.points[a.points.length-1],!1),r=a.points[a.points.length-1],a.direction=z.direction(a.points[a.points.length-2],a.points[a.points.length-1])),r}function c3(n,t,e){var s,i=t.segments[t.segments.length-2],r=i.points[i.points.length-1];(("Top"===i.direction||"Bottom"===i.direction)&&r.x===n[1].x||("Left"===i.direction||"Right"===i.direction)&&r.y===n[1].y)&&(i.points[i.points.length-1]=n[1],s=z.direction(i.points[0],i.points[i.points.length-1]),void 0!==t.sourceWrapper&&void 0===t.sourcePortWrapper&&s===ls(i.direction)&&("Left"===i.direction||"Right"===i.direction?i.points[0].x="Right"===i.direction?i.points[0].x-t.sourceWrapper.corners.width:i.points[0].x+t.sourceWrapper.corners.width:i.points[0].y="Bottom"===i.direction?i.points[0].y-t.sourceWrapper.corners.height:i.points[0].y+t.sourceWrapper.corners.height),i.direction=s,i.length=z.distancePoints(i.points[0],i.points[i.points.length-1]),n.splice(0,1))}function wI(n,t,e,i){var o=i?n.targetPadding:n.sourcePadding,a=i?n.targetPortWrapper:n.sourcePortWrapper,l=new Ne(a.bounds.x-o,a.bounds.y-o,a.actualSize.width+2*o,a.actualSize.height+2*o),h=[l.topLeft,l.topRight,l.bottomRight,l.bottomLeft];h[h.length]=h[0];var d=i?e.point:t.point;return Nx({x1:t.point.x,y1:t.point.y,x2:e.point.x,y2:e.point.y},h,0,d)||d}function d3(n,t){var e=[],i=dF(0,n.corners,t);i.push(i[0]);for(var r=0;r0){var r=void 0,s=[],o=t.point;for(r=0;r1&&z.equals(a.points[0],a.points[1])&&n.segments.splice(r,1),a)for(var l=0;l0||0===r)&&i.push(a.points[parseInt(l.toString(),10)])}}return i}function Lx(n,t,e){return"Top"===n||"Bottom"===n?e.x>t.x?"Right":"Left":e.y>t.y?"Bottom":"Top"}function Bv(n){if("Straight"===n.type||"Bezier"===n.type){if(0===n.segments.length||n.segments.length>0&&!z.isEmptyPoint(n.segments[n.segments.length-1].point))if("Bezier"===n.type){var t=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0},!0);n.segments.push(t)}else t=new kl(n,"segments",{type:"Straight"},!0),n.segments.push(t)}else{if(n.segments.length>0)for(var e=!1,i=0;i=t.corners.left&&e.point.x<=t.corners.right&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom)t.direction=e.point.y>t.point.y?"Bottom":"Top",i=Ys(n,t,e,"Top"===t.direction?t.point.y-t.corners.top+20:t.corners.bottom-t.point.y+20);else if(n.sourcePortWrapper&&r===ls(o)){var h;("Left"===r||"Right"===r)&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom?(t.direction=e.point.y>t.point.y?"Bottom":"Top",h=t.corners.height/2+20):("Top"===r||"Bottom"===r)&&t.point.x>=t.corners.left&&t.point.x<=t.corners.right&&(t.direction=e.point.x>t.point.x?"Right":"Left",h=t.corners.width/2+20),t.direction&&h?i=Ys(n,t,e,h,!0):(t.direction=o,i=Ll(t,e))}else if(!n.sourcePortWrapper||r!==e.direction||"Top"!==r&&"Bottom"!==r||t.corners.center.x!==e.corners.center.x)if(t.direction===e.direction)if(("Left"===t.direction||"Right"===t.direction)&&e.point.y>t.corners.top-20&&e.point.yt.corners.left-20&&e.point.xt.point.y?"Bottom":"Top",i=Ys(n,t,e,"Bottom"===t.direction?t.corners.bottom-t.point.y+20:t.point.y-t.corners.top+20);else t.direction=o,i=Ys(n,t,e,"Top"===o||"Bottom"===o?n.sourceWrapper.height/2+20:n.sourceWrapper.width/2+20),t.point=i[1],"Left"===o||"Right"===o?(e.direction=o,e.point="Left"===o?e.corners.middleLeft:e.corners.middleRight):Fv(n.targetWrapper,t,e,n),i=Ys(n,t,e);return i}function p3(n,t){if(void 0!==n.targetWrapper&&void 0===n.targetPortWrapper&&En(n.targetWrapper).containsPoint(t.point,1)){var i=n.targetWrapper,r=n.segments[n.segments.length-2],s=r.points[r.points.length-1],o=ls(r.direction);"Bottom"===o?s.yi.corners.top-1&&(r.points[r.points.length-1].y=i.corners.top-20,r.length=z.distancePoints(r.points[0],r.points[r.points.length-1])):"Left"===o?s.x>i.corners.left-1&&(r.points[r.points.length-1].x=i.corners.left-20,r.length=z.distancePoints(r.points[0],r.points[r.points.length-1])):"Right"===o&&s.x0||0===e)&&t.push(i.points[parseInt(r.toString(),10)]);return t}function Fv(n,t,e,i){var r,s={x:0,y:0},o=CI(n,n.corners,n.bounds),a=t.margin,l=t.point;if(o.bottomCenter.y+a.bottoml.y)r="Top",s=o.topCenter;else if(o.middleLeft.x-a.left>l.x)r="Left",s=o.middleLeft;else if(o.middleRight.x+a.rightc&&(p=c,r="Right",s=o.middleRight),p>d&&(p=d,r="Bottom",s=o.bottomCenter),p>u&&(r="Left",s=o.middleLeft)}e.point=s,e.direction=r;var f=Tc(o,ls(e.direction));e.point=Ah(i,0,e.point,f,n===i.targetWrapper)}function g3(n,t,e,i,r){var s,o,a;if(s=function Hre(n,t){var e=!1;switch(n){case"Left":switch(t){case"Right":case"Bottom":e=!0}break;case"Top":switch(t){case"Left":case"Right":case"Bottom":e=!0}break;case"Bottom":"Right"===t&&(e=!0)}return e}(t.direction,e.direction),s&&b3(t,e),"Right"===t.direction&&"Left"===e.direction)a=function Cre(n,t,e,i){var o=Math.round(Math.abs(t.point.y-e.point.y)),a={x:Math.max(t.point.x,t.corners.right),y:t.point.y},l={x:Math.min(e.point.x,e.corners.left),y:e.point.y},h=Ga(n);if(i){var c=l;l=a,a=c}return t.corners.bottom+he.corners.bottom+h||("Bezier"!==n.type||e.corners.left-t.corners.right<=2*h&&e.corners.left-t.corners.right>=5)&&(h=0),t.margin={left:h,right:h,top:h,bottom:h},e.margin={left:h,right:h,top:h,bottom:h},0===o&&(t.corners.right=e.corners.right?void 0!==i&&(i.offsetYe.corners.bottom+e.margin.bottom)||void 0===i&&t.corners.middleRight.ye.corners.bottom+e.margin.bottom&&t.corners.top>e.corners.bottom||void 0===i&&t.corners.middleRight.y>e.corners.bottom||void 0!==i&&i.offsetYe.corners.top||void 0===i&&t.corners.middleRight.y>e.corners.bottom?Ae.Three:t.corners.rightr.offsetY+e.margin.right||void 0===r&&t.corners.top>e.corners.middleRight.y||void 0!==r&&(void 0!==i&&i.offsetXr.offsetX||void 0===r&&t.corners.left>e.corners.topCenter.x?Ae.Four:Ae.Two:void 0!==s&&Math.abs(t.corners.right-e.corners.left)<=5&&Math.abs(s.offsetY-e.corners.top)<=5||void 0!==r&&t.corners.right=25&&t.corners.middleRight.y+t.margin.righte.corners.bottom+e.margin.bottom||void 0===o&&t.corners.middleRight.y>e.corners.bottom+e.margin.bottom?t.corners.top>e.corners.bottom?void 0!==a&&t.corners.right+t.margin.righta.offsetX||void 0===a&&t.corners.left>e.corners.bottomCenter.x?Ae.Four:Ae.Two:void 0!==o&&Math.abs(t.corners.right-e.corners.left)<=25&&Math.abs(o.offsetY-e.corners.bottom)<=25?Ae.Two:Ae.Four}(n,t,e,s);else if("Bottom"===t.direction&&"Top"===e.direction)a=function Tre(n,t,e){var r=t.point.x-e.point.x,s=Ga(n);return t.corners.right+se.corners.right+s||("Bezier"!==n.type||e.corners.top-t.corners.bottom<=2*s&&e.corners.top-t.corners.bottom>=5)&&(s=0),t.margin={left:s,right:s,top:s,bottom:s},e.margin={left:s,right:s,top:s,bottom:s},0===r&&t.corners.bottome.corners.right+e.margin.right||void 0===i&&t.corners.bottomCenter.x>e.corners.right+e.margin.right?Ae.Three:t.corners.bottomr.offsetX||void 0===r&&t.corners.left>e.corners.left||void 0!==r&&t.corners.right+t.margin.righte.corners.bottom?Ae.Five:0===s||0===o?Ae.One:Ae.Three}(n,t,e)}else"Bottom"===t.direction&&"Left"===e.direction?a=function Are(n,t,e,i){var r=n.sourcePortWrapper,s=n.targetPortWrapper,o=Ga(n);if(e.margin={left:o,right:o,top:o,bottom:o},t.margin={top:o,bottom:o,left:o,right:o},i){var l=r;r=s,s=l}return void 0!==r&&r.offsetXs.offsetY||void 0===s&&t.corners.top>e.corners.middleLeft.y?Ae.Four:Ae.Two:void 0!==s&&Math.abs(t.corners.right-e.corners.left)<=25&&Math.abs(s.offsetY-t.corners.bottom)<=25?Ae.Two:Ae.Four}(n,t,e,s):"Left"===t.direction&&"Left"===e.direction?a=function Ore(n,t,e){var i=n.sourcePortWrapper,r=n.targetPortWrapper,s=Ga(n);t.margin={left:s,right:s,top:s,bottom:s},e.margin={left:s,right:s,top:s,bottom:s};var o=Math.round(Math.abs(t.point.x-e.point.x)),a=Math.round(Math.abs(t.point.y-e.point.y));return t.corners.leftr.offsetY||void 0===r&&t.corners.top-t.margin.top>e.corners.middleLeft.y?Ae.Three:t.corners.righte.corners.bottom+e.margin.bottom||void 0===i&&t.corners.middleLeft.y>e.corners.bottom+e.margin.bottom?Ae.Three:t.corners.left>e.corners.right?Ae.Five:0===o||0===a?Ae.One:Ae.Three}(n,t,e):"Left"===t.direction&&"Top"===e.direction?a=function Nre(n,t,e,i){var s=n.sourcePortWrapper,o=Ga(n);e.margin={left:o,right:o,top:o,bottom:o},t.margin={top:o,bottom:o,left:o,right:o};var a=n.targetPortWrapper,l={x:Math.min(t.point.x,t.corners.left),y:t.point.y},h={x:e.point.x,y:Math.min(e.point.y,e.corners.top)};if(i){var c=s;s=a,a=c;var d=l;l=h,h=d}return void 0!==s&&s.offsetYa.offsetX||void 0===a&&t.corners.left-t.margin.left>e.corners.topCenter.x?Ae.Two:Ae.Four:void 0!==a&&t.corners.rightr.offsetX||void 0===r&&t.corners.left>e.corners.left||void 0!==r&&t.corners.right+t.margin.righte.corners.right+e.margin.right||void 0===i&&t.corners.left>e.corners.right||void 0!==i&&i.offsetXe.corners.bottom?Ae.Five:0===s||0===o?Ae.One:Ae.Three}(n,t,e));return s&&b3(t,e),o=function Pre(n,t,e,i,r,s){var l,d,h=n.sourceWrapper.corners,c=n.targetWrapper.corners,u=20,p={corners:e.corners,point:e.point,direction:e.direction,margin:e.margin},f={corners:i.corners,point:i.point,direction:i.direction,margin:i.margin};if(!(p.direction===f.direction&&t!==Ae.Five||p.direction!==ls(f.direction)&&t!==Ae.Three))switch(p.direction){case"Left":h.middleLeft.x>c.middleRight.x&&(d=(h.middleLeft.x-c.middleRight.x)/2,u=s?d:Math.min(u,d));break;case"Right":h.middleRight.xc.bottomCenter.y&&(d=(h.topCenter.y-c.bottomCenter.y)/2,u=s?d:Math.min(u,d));break;case"Bottom":h.bottomCenter.yp&&hp)&&o>c&&o<=d&&e>=20&&(s=n.point.x-t.corners.left+s),i&&n.direction===t.direction&&n.corners.left>t.corners.left&&n.corners.left-t.corners.right>=20&&(s=(n.corners.left-t.corners.right)/2),f=Bn(n.point,s,180);break;case"Top":(o>c&&oc)&&h>p&&h<=u&&e>=20&&(s=n.point.y-t.corners.top+s),i&&n.direction===t.direction&&n.corners.top>t.corners.top&&n.corners.top-t.corners.bottom>=20&&(s=(n.corners.top-t.corners.bottom)/2),f=Bn(n.point,s,270);break;case"Right":(h>p&&hp)&&a=c&&e>=20&&(s=t.corners.right-n.point.x+s),i&&n.direction===t.direction&&n.corners.right=20&&(s=(t.corners.left-n.corners.right)/2),f=Bn(n.point,s,0);break;case"Bottom":(o>c&&oc)&&l=p&&e>=20&&(s=t.corners.bottom-n.point.y+s),i&&n.direction===t.direction&&n.corners.bottom=20&&(s=(t.corners.top-n.corners.bottom)/2),f=Bn(n.point,s,90)}r=[n.point,f];var g=void 0;if("Top"===n.direction||"Bottom"===n.direction){var v=n.direction;n.direction=f.x>t.point.x?"Left":"Right",n.point=f,r=EI(n,t,v,r,g=i?.5*Math.abs(f.x-t.point.x):g,i)}else v=n.direction,n.direction=f.y>t.point.y?"Top":"Bottom",n.point=f,r=EI(n,t,v,r,g=i?.5*Math.abs(f.y-t.point.y):g,i);return r}(p,f,u,g)),l}(n,a,t,e,i,r),"Bezier"===n.type&&function Rre(n,t,e){if("Bezier"===n.type)if(0===n.segments.length){var i=e[0],r=e[e.length-1];if(t===Ae.One){var s=Math.min(20,.5*z.findLength(i,r)),o={angle:Gt(i,r),distance:s},a={angle:Gt(r,i),distance:s},l=z.direction(i,r),c=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,orientation:"Left"===l||"Right"===l?"Horizontal":"Vertical"},!0);n.segments.push(c)}else if(t===Ae.Two)o={angle:Gt(i,d=e[1]),distance:.5*z.findLength(i,d)},a={angle:Gt(r,d),distance:.5*z.findLength(r,d)},l=z.direction(i,d),c=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,orientation:"Left"===l||"Right"===l?"Horizontal":"Vertical"},!0),n.segments.push(c);else if(t===Ae.Three){var d={x:.5*((u=e[1]).x+(p=e[e.length-2]).x),y:.5*(u.y+p.y)},f=(o={angle:Gt(i,u),distance:.5*z.findLength(i,u)},a={angle:Gt(d,u),distance:.5*z.findLength(d,u)},z.direction(i,u)),v=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,point:d,orientation:"Left"===f||"Right"===f?"Horizontal":"Vertical"},!0);n.segments.push(v);var y={angle:Gt(d,p),distance:.5*z.findLength(d,p)},S={angle:Gt(r,p),distance:.5*z.findLength(r,p)},b=z.direction(d,p),w=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:y,vector2:S,orientation:"Left"===b||"Right"===b?"Horizontal":"Vertical"},!0);n.segments.push(w)}else if(t===Ae.Four){var D={x:.5*((u=e[1]).x+(p=e[2]).x),y:.5*(u.y+p.y)},A={x:.5*(p.x+(C=e[3]).x),y:.5*(p.y+C.y)};o={angle:Gt(i,u),distance:.5*z.findLength(i,u)},a={angle:Gt(D,u),distance:.5*z.findLength(D,u)},f=z.direction(i,u),v=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,point:D,orientation:"Left"===f||"Right"===f?"Horizontal":"Vertical"},!0),n.segments.push(v),y={angle:Gt(D,p),distance:.5*z.findLength(D,p)},S={angle:Gt(A,p),distance:.5*z.findLength(A,p)},b=z.direction(D,p),w=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:y,vector2:S,point:A,orientation:"Left"===b||"Right"===b?"Horizontal":"Vertical"},!0),n.segments.push(w);var x={angle:Gt(A,C),distance:.5*z.findLength(A,C)},R={angle:Gt(r,C),distance:.5*z.findLength(r,C)},L=z.direction(A,C),N=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:x,vector2:R,orientation:"Left"===L||"Right"===L?"Horizontal":"Vertical"},!0);n.segments.push(N)}else if(t===Ae.Five){var u,p,C,T=e[4],P=(D={x:.5*((u=e[1]).x+(p=e[2]).x),y:.5*(u.y+p.y)},A={x:.5*(p.x+(C=e[3]).x),y:.5*(p.y+C.y)},{x:.5*(C.x+T.x),y:.5*(C.y+T.y)});o={angle:Gt(i,u),distance:.5*z.findLength(i,u)},a={angle:Gt(D,u),distance:.5*z.findLength(D,u)},f=z.direction(i,u),v=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,point:D,orientation:"Left"===f||"Right"===f?"Horizontal":"Vertical"},!0),n.segments.push(v),y={angle:Gt(D,p),distance:.5*z.findLength(D,p)},S={angle:Gt(A,p),distance:.5*z.findLength(A,p)},b=z.direction(D,p),w=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:y,vector2:S,point:A,orientation:"Left"===b||"Right"===b?"Horizontal":"Vertical"},!0),n.segments.push(w),x={angle:Gt(A,C),distance:.5*z.findLength(A,C)},R={angle:Gt(P,C),distance:.5*z.findLength(P,C)},L=z.direction(A,C),N=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:x,vector2:R,point:P,orientation:"Left"===L||"Right"===L?"Horizontal":"Vertical"},!0),n.segments.push(N);var _={angle:Gt(P,T),distance:.5*z.findLength(P,T)},B={angle:Gt(r,T),distance:.5*z.findLength(r,T)},j=z.direction(P,T),oe=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:_,vector2:B,orientation:"Left"===j||"Right"===j?"Horizontal":"Vertical"},!0);n.segments.push(oe)}else c=new ps(n,"segments",{type:"Bezier"},!0),n.segments.push(c)}else for(var ue=0;ue=13?13:n.connectorSpacing<=1?1:n.connectorSpacing}function Gt(n,t){var i=z.findLength({x:t.x,y:n.y},t),r=z.findLength(t,n),s=Math.asin(i/r);return s=180*s/Math.PI,n.xt.y&&(s=360-s):s=n.y0)for(var l=1;lc)&&(s=c,a=h),s>=0&&s<=1)break}}return a}function m3(n,t){var c,d,u,p,f,g,S,b,M,w,D,e=n.x1,i=n.y1,r=n.x2,s=n.y2,o=t.x1,a=t.y1,l=t.x2,h=t.y2;if(w=(c=s-i)*l+(u=e-r)*h+(f=r*i-e*s),0!==(M=c*o+u*a+f)&&0!==w&&y3(M,w)||(b=(d=h-a)*r+(p=o-l)*s+(g=l*a-o*h),0!==(S=d*e+p*i+g)&&0!==b&&y3(S,b)))return null;var A=c*p-d*u;return 0===A?null:(A<0?-A/2:A/2,0,{x:(D=u*g-p*f)<0?(D-0)/A:(D+0)/A,y:(D=d*f-c*g)<0?(D-0)/A:(D+0)/A})}function y3(n,t){return n*t>=0}function S3(n,t,e){switch(t.direction){case"Left":t.point.x>n.left&&(e=t.point.x-n.left>e?t.point.x-n.left+e:e);break;case"Right":t.point.xe?n.right-t.point.x+e:e);break;case"Top":t.point.y>n.top&&(e=t.point.y-n.top>e?t.point.y-n.top+e:e);break;case"Bottom":t.point.ye?n.bottom-t.point.y+e:e)}return e}function Ll(n,t){var e;switch(n.direction){case"Left":case"Right":var i={x:t.point.x,y:n.point.y};e=z.equals(n.point,i)||z.equals(t.point,i)?[n.point,t.point]:[n.point,i,t.point];break;case"Top":case"Bottom":var r={x:n.point.x,y:t.point.y};e=z.equals(n.point,r)||z.equals(t.point,r)?[n.point,t.point]:[n.point,r,t.point]}return e}function Ys(n,t,e,i,r,s){void 0===s&&(s=!1),i||(i=20),s&&t.direction!==e.direction&&(i="Left"===t.direction||"Right"===t.direction?Math.floor(.5*Math.abs(t.point.x-e.point.x)):Math.floor(.5*Math.abs(t.point.y-e.point.y)));var l,h,u,o=n.sourcePortWrapper,c=e.point.x-t.point.x,d=e.point.y-t.point.y;if(!r&&(Math.abs(c)<.001||Math.abs(d)<.001)&&void 0===e.direction)return[t.point,e.point];if(void 0===n.targetWrapper&&Math.abs(c)<=31&&Math.abs(d)<=31){if("Left"===t.direction||"Right"===t.direction?Math.abs(d)<12&&(t.direction=t.point.y>e.point.y?"Top":"Bottom"):Math.abs(c)<12&&(t.direction=t.point.x>e.point.x?"Left":"Right"),Math.abs(c)>12||Math.abs(d)>12)return Ll(t,e);i+=5}return"Left"===t.direction||"Right"===t.direction?("Right"===t.direction?(void 0!==e.direction&&"Right"===e.direction&&(i=Math.max(t.point.x,e.point.x)-t.point.x+i),t.point.x>e.point.x&&void 0===o&&(i=-i)):(void 0!==e.direction&&"Left"===e.direction&&(i=t.point.x-Math.min(t.point.x,e.point.x)+i),(t.point.x>e.point.x||void 0!==o||"Left"===t.direction)&&(i=-i)),u=e.point.y-t.point.y,l=Bn(t.point,i,0),0!=(u=e.point.y-l.y)&&(h=Bn(l,e.point.y-l.y,90))):("Top"===t.direction||"Bottom"===t.direction)&&("Bottom"===t.direction?void 0!==e.direction&&"Bottom"===e.direction&&(i=Math.max(t.point.y,e.point.y)-t.point.y+i):(void 0!==e.direction&&"Top"===e.direction&&(i=t.point.y-Math.min(t.point.y,e.point.y)+i),(t.point.y>e.point.y||void 0!==o||"Top"===t.direction)&&(i=-i)),u=e.point.x-t.point.x,l=Bn(t.point,i,90),0!=(u=e.point.x-l.x)&&(h=Bn(l,e.point.x-l.x,0))),0===u?[t.point,e.point]:[t.point,l,h,e.point]}function EI(n,t,e,i,r,s){var o;switch(void 0===r&&(r=20),void 0===s&&(s=!1),void 0===e?(n.margin={left:2,right:2,top:2,bottom:2},t.margin={left:0,right:5,top:0,bottom:5},s&&(n.margin={left:10,right:10,top:10,bottom:10},t.margin={left:10,right:10,top:10,bottom:10},"Left"===n.direction?(r=kx(n,t,e,r),n.corners.left-t.corners.right>=5&&(r=Math.abs(n.point.x-n.corners.left)+.5*Math.floor(n.corners.left-t.corners.right))):"Right"===n.direction?(r=Px(n,t,r,e),t.corners.left-n.corners.right>=5&&(r=Math.abs(n.point.x-n.corners.right)+.5*Math.floor(t.corners.left-n.corners.right))):"Top"===n.direction?(r=Ox(n,t,e,r),n.corners.top-t.corners.bottom>=5&&(r=Math.abs(n.point.y-n.corners.top)+.5*Math.floor(n.corners.top-t.corners.bottom))):"Bottom"===n.direction&&(r=zx(n,t,r,e),t.corners.top-n.corners.bottom>=5&&(r=Math.abs(n.point.y-n.corners.bottom)+.5*Math.floor(t.corners.top-n.corners.bottom))))):("Bottom"===n.direction?s?t.corners.top-n.corners.bottom<20&&(r=t.corners.bottom-n.point.y+25):t.corners.top>n.corners.bottom&&t.corners.top-n.corners.bottom<20&&(r=(t.corners.top-n.corners.bottom)/2):"Top"===n.direction?s?n.corners.top-t.corners.bottom<20&&(r=n.point.y-t.corners.top+25):t.corners.bottomn.corners.right&&t.corners.left-n.corners.right<20&&(r=(t.corners.left-n.corners.right)/2):"Left"===n.direction&&(s?n.corners.left-t.corners.right<20&&(r=n.point.x-t.corners.left+25):t.corners.rightt.point.y||"Top"===t.direction&&n.point.yt.point.x||"Left"===t.direction&&n.point.xh||e.corners.top-e.margin.top<=i.point.y&&e.corners.bottom+e.margin.bottom>=i.point.y))if(!s||"Top"!==e.direction&&"Bottom"!==e.direction)c=Math.min(Math.abs(i.corners.left-e.corners.right)/2,20),h=e.corners.right-n.x+c;else{var c=Math.abs(i.corners.left-e.corners.right)/2;h=e.corners.right-n.x+c}else h="Top"===e.direction&&n.y>i.point.y||"Bottom"===e.direction&&n.y=e.corners.left-e.margin.left&&n.x<=e.corners.right+e.margin.right?Math.min(i.corners.left,e.corners.left)-n.x-20:i.corners.left-n.x-20;break;case"Right":if(e.corners.left-e.margin.left>i.corners.right+i.margin.right&&(e.corners.left-e.margin.right-i.corners.right>h||e.corners.top-e.margin.top<=i.point.y&&e.corners.bottom+e.margin.bottom>=i.point.y))if(!s||"Top"!==e.direction&&"Bottom"!==e.direction)c=Math.min(Math.abs(e.corners.left-i.corners.right)/2,20),h=e.corners.left-n.x-c;else{c=Math.abs(e.corners.left-i.corners.right)/2;h=e.corners.left-n.x-c}else h="Top"===e.direction&&n.y>i.point.y||"Bottom"===e.direction&&n.y=e.corners.left-e.margin.left&&n.x<=e.corners.right+e.margin.right?Math.max(i.corners.right,e.corners.right)-n.x+20:i.corners.right-n.x+20}o=Bn(n,h,0),a=Bn(o,i.point.y-n.y,90),l=i.point}else if("vertical"===t){switch(i.direction){case"Top":e.corners.bottom+e.margin.bottomh||e.corners.left-e.margin.left<=i.point.x&&e.corners.right+e.margin.right>=i.point.x)?!s||"Right"!==e.direction&&"Left"!==e.direction?(c=Math.min(Math.abs(i.corners.top-e.corners.bottom)/2,20),h=e.corners.bottom-n.y+c):(c=Math.abs(i.corners.top-e.corners.bottom)/2,h=e.corners.bottom-n.y+c):h="Left"===e.direction&&n.x>i.point.x||"Right"===e.direction&&n.x=e.corners.top-e.margin.top&&n.y<=e.corners.bottom+e.margin.bottom?Math.min(i.corners.top,e.corners.top)-n.y-20:i.corners.top-n.y-20;break;case"Bottom":e.corners.top-e.margin.top>i.corners.bottom+i.margin.bottom&&(e.corners.top-e.margin.top-i.corners.bottom>h||e.corners.left-e.margin.left<=i.point.x&&e.corners.right+e.margin.right>=i.point.x)?!s||"Right"!==e.direction&&"Left"!==e.direction?(c=Math.min(Math.abs(e.corners.top-i.corners.bottom)/2,20),h=e.corners.top-n.y-c):(c=Math.abs(e.corners.top-i.corners.bottom)/2,h=e.corners.top-n.y-c):h="Left"===e.direction&&n.x>i.point.x||"Right"===e.direction&&n.x=e.corners.top-e.margin.top&&n.y<=e.corners.bottom+e.margin.bottom?Math.max(i.corners.bottom,e.corners.bottom)-n.y+20:i.corners.bottom-n.y+20}o=Bn(n,h,90),a=Bn(o,i.point.x-n.x,0),l=i.point}r.push(o),r.push(a),r.push(l)}function Ox(n,t,e,i){return n.corners.top-n.margin.top>t.corners.top+t.margin.top&&n.corners.top-n.margin.top<=t.corners.bottom+t.margin.bottom?(("Right"===t.direction&&n.point.xt.point.x)&&(i+=n.corners.top-t.corners.top),i+=n.point.y-n.corners.top):i+=void 0!==e&&"Left"!==e&&"Right"===t.direction&&n.point.xt.corners.left-t.margin.left&&n.corners.left-n.margin.left<=t.corners.right+t.margin.right?(("Bottom"===t.direction&&n.point.yt.point.y)&&(i+=n.corners.left-t.corners.left),i+=n.point.x-n.corners.left):i+=void 0!==e&&"Top"!==e&&"Bottom"===t.direction&&n.point.y=t.corners.left-t.margin.left?(("Bottom"===t.direction&&n.point.yt.point.y)&&(e+=t.corners.right-n.corners.right),e+=n.corners.right-n.point.x):e+=void 0!==i&&"Top"!==i&&"Bottom"===t.direction&&n.point.y=t.corners.top-t.margin.top?(("Right"===t.direction&&n.point.xt.point.x)&&(e+=t.corners.bottom-n.corners.bottom),e+=n.corners.bottom-n.point.y):e+=void 0!==i&&"Left"!==i&&"Right"===t.direction&&n.point.xf&&d=u&&d=p&&d<=f?"Left":"Right"}function ls(n){switch(n){case"Top":return"Bottom";case"Bottom":return"Top";case"Left":return"Right";case"Right":return"Left"}return"auto"}var w3=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Ac=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},DI=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return w3(t,n),Ac([I()],t.prototype,"width",void 0),Ac([I()],t.prototype,"height",void 0),t}(Ee),Bre=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return w3(t,n),Ac([I()],t.prototype,"width",void 0),Ac([I()],t.prototype,"height",void 0),Ac([I()],t.prototype,"fit",void 0),Ac([I()],t.prototype,"description",void 0),Ac([I()],t.prototype,"template",void 0),Ac([I()],t.prototype,"tooltip",void 0),t}(Ee),Fre=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Nl=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},C3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Fre(t,n),Nl([I("")],t.prototype,"id",void 0),Nl([I(Number.MIN_VALUE)],t.prototype,"zIndex",void 0),Nl([re({},$n)],t.prototype,"margin",void 0),Nl([I(!0)],t.prototype,"visible",void 0),Nl([re({},Ed)],t.prototype,"tooltip",void 0),Nl([I(!1)],t.prototype,"excludeFromLayout",void 0),Nl([I()],t.prototype,"addInfo",void 0),Nl([I("None")],t.prototype,"flip",void 0),Nl([I("All")],t.prototype,"flipMode",void 0),Nl([re({},Bre)],t.prototype,"symbolInfo",void 0),t}(Ee),_re=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Jn=function(n){function t(e,i,r,s){var o=n.call(this)||this;return o.data="",o.nodeId="",o.annotationId="",o.diagramId="",o.diagramId=i,o.nodeId=e,o.annotationId=r,o.templateFn=UF(s),o}return _re(t,n),t.prototype.getNodeTemplate=function(){return this.templateFn},Object.defineProperty(t.prototype,"content",{get:function(){return this.data},set:function(e){this.data=e,this.canReset||(this.canReset=!0,this.isTemplate||(this.template=Rh(this,!0)),this.canReset=!1,this.isDirt=!0)},enumerable:!0,configurable:!0}),t}(as),Rx=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),hs=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},E3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Rx(t,n),hs([I("")],t.prototype,"id",void 0),hs([I("transparent")],t.prototype,"fill",void 0),hs([I("black")],t.prototype,"iconStrokeColor",void 0),hs([I(0)],t.prototype,"iconStrokeWidth",void 0),hs([I(!0)],t.prototype,"visibility",void 0),hs([I(10)],t.prototype,"width",void 0),hs([I(10)],t.prototype,"height",void 0),hs([I("transparent")],t.prototype,"handleStrokeColor",void 0),hs([I(1)],t.prototype,"handleStrokeWidth",void 0),hs([I("")],t.prototype,"pathData",void 0),hs([I(0)],t.prototype,"cornerRadius",void 0),hs([re({left:0,right:0,top:0,bottom:0},$n)],t.prototype,"padding",void 0),hs([re({},Ed)],t.prototype,"tooltip",void 0),t}(Ee),D3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Rx(t,n),hs([re({x:0,y:0},z)],t.prototype,"offset",void 0),hs([re({},$n)],t.prototype,"margin",void 0),t}(E3),xI=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Rx(t,n),hs([I(.5)],t.prototype,"offset",void 0),hs([I("Center")],t.prototype,"alignment",void 0),hs([re({x:0,y:0},z)],t.prototype,"displacement",void 0),t}(E3);function Dd(n){return n?n instanceof Zn||n instanceof Nr?n.constraints&Lr.Select:n instanceof de?n.constraints&qe.Select:n.constraints&ie.Select:1}function to(n){return n?n instanceof Zn||n instanceof Nr?n.constraints&Lr.Drag:n instanceof de?n.constraints&qe.Drag:n instanceof oi?1:n.constraints&ie.Drag:1}function Ure(n,t){return n instanceof de?n.constraints&qe.PointerEvents:n.constraints&ie.PointerEvents}function TI(n){return n instanceof de?n.constraints&qe.Delete:n.constraints&ie.Delete}function AI(n){return n.constraints&qe.DragSourceEnd}function LI(n){return n.constraints&qe.DragTargetEnd}function NI(n){return n.constraints&qe.DragSegmentThumb}function OI(n){return n instanceof Zn||n instanceof Nr?n.constraints&Lr.Rotate:n.constraints&ie.Rotate}function kI(n){return n.constraints&ie.Shadow}function da(n){return n instanceof te&&n.constraints&ie.InConnect?n.constraints&ie.InConnect:0}function Lh(n){return n&&n.constraints&&!(n.constraints&ni.None)&&n.constraints&ni.InConnect?n.constraints&ni.InConnect:0}function Nh(n){return n instanceof te&&n.constraints&ie.OutConnect?n.constraints&ie.OutConnect:0}function xd(n){return n&&n.constraints&&!(n.constraints&ni.None)&&n.constraints&ni.OutConnect?n.constraints&ni.OutConnect:0}function Ol(n,t){var e=0;return n instanceof Zn||n instanceof Nr?e=n.constraints&Lr.Resize:n&&("SouthEast"===t?e=n.constraints&ie.ResizeSouthEast:"East"===t?e=n.constraints&ie.ResizeEast:"NorthEast"===t?e=n.constraints&ie.ResizeNorthEast:"South"===t?e=n.constraints&ie.ResizeSouth:"North"===t?e=n.constraints&ie.ResizeNorth:"SouthWest"===t?e=n.constraints&ie.ResizeSouthWest:"West"===t?e=n.constraints&ie.ResizeWest:"NorthWest"===t&&(e=n.constraints&ie.ResizeNorthWest)),e}function PI(n){return n instanceof de?n.constraints&qe.AllowDrop:n.constraints&ie.AllowDrop}function Ds(n){return n.constraints&rt.Virtualization}function _v(n){return n.tool&Ci.SingleSelect}function Uv(n){return n.tool&Ci.MultipleSelect}function Lc(n){return n.tool&Ci.ZoomPan}function zI(n){return n.tool&Ci.ContinuousDraw}function x3(n){return n.tool&Ci.DrawOnce}function RI(n){return n.tool&Ci.SingleSelect||n.tool&Ci.MultipleSelect}function jv(n){return n.constraints&rt.UserInteraction}function T3(n){return n.constraints&rt.ZoomTextEdit}function Vv(n){return function Gre(n){return n.constraints&rt.ApiUpdate}(n)||n.diagramActions&ee.ToolAction}function Hx(n,t){return n.constraints&ni.Draw}function Bx(n,t){return n.constraints&ni.Drag}function HI(n){return!(n&Qa.DrawSelectorBorder)}function A3(n){return!!(n&Qa.PreventRenderSelector)}var Fx=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Wv=function(n){function t(){var e=null!==n&&n.apply(this,arguments)||this;return e.childTable=[],e.cellStyle={},e.desiredRowHeight=[],e.desiredCellWidth=[],e}return Fx(t,n),t.prototype.rowDefinitions=function(){return this.rowDefns},t.prototype.columnDefinitions=function(){return this.colDefns},t.prototype.addObject=function(e,i,r,s,o){if(this.rows.length>=i){var a=this.rows[parseInt(i.toString(),10)];if(a.cells.length>r){o=o||1,s=s||1;var l=a.cells[parseInt(r.toString(),10)];l.columnSpan=Math.max(o,l.columnSpan),l.rowSpan=Math.max(s,l.rowSpan);var h=new Jre;(h=e).rowId=i,h.columnId=r,h.columnSpan=o,this.childTable[h.id]=h,this.addObjectToCell(h,l)}}},t.prototype.addObjectToCell=function(e,i){i.children||(i.children=[]),e.style.strokeColor="black",e.style.strokeWidth=1,i.children.push(e)},t.prototype.updateProperties=function(e,i,r,s){this.offsetX=e,this.offsetY=i,this.width=r,this.height=s},t.prototype.setDefinitions=function(e,i){this.rowDefns=e,this.colDefns=i,this.children=[],this.rows=this.rows||[];for(var r=0;r0){for(var h=0;hi&&this.updateRowHeight(e,l,!1)}},t.prototype.setTextRefresh=function(e){if(e.children&&e.children.length)for(var i=e.children,r=0;ri&&this.updateColumnWidth(e,a,!1)}},t.prototype.calculateCellWidth=function(e){for(var i,r,s,o=0;os.bounds.width&&(0===s.children.length||void 0===s.children[0].maxWidth)?s.outerBounds.width:s.bounds.width,i=i?is.bounds.height?s.outerBounds.height:s.bounds.height,i=i?i0?e.children[0]:void 0;if(a&&1===e.columnSpan){o="Width"===i?a.bounds.right:a.bounds.bottom,s||(s="Width"===i?a.bounds.width:a.bounds.height);for(var l=0;lo){var d=c-o+("Width"===i?a.bounds.width:a.bounds.height);s&&(s=s0?this.rowDefns.splice(e,0,i):this.rowDefns.push(i);var s=new L3;s.cells=[],(new Td).width=this.width,this.addCellInRow(this.colDefns,i,s),e>this.rows.length-1?this.rows.push(s):this.rows.splice(e,0,s),r&&(this.measure(new me(this.width,this.height)),this.arrange(this.desiredSize))},t.prototype.addColumn=function(e,i,r){var s,o,a,l,h=this.rows;this.colDefns.length>0?this.colDefns.splice(e,0,i):this.colDefns.push(i),void 0!==this.width&&(this.width+=i.width);for(var c=0;cs.cells.length-1?s.cells.push(l):s.cells.splice(e,0,l),this.children.push(l);r&&(this.measure(new me(this.width,this.height)),this.arrange(this.desiredSize))},t.prototype.removeRow=function(e){var i,r,o=this.rows[parseInt(e.toString(),10)];this.height-=this.rowDefns[parseInt(e.toString(),10)].height;for(var a=0;a0){var r=0,s=0;i=new me(0,0),this.calculateSize();for(var o=0,a=this.rows;o0){for(var o=this.offsetX-e.width*this.pivot.x,a=this.offsetY-e.height*this.pivot.y,l=o,h=0,c=this.rows;h1&&this.children.splice(this.children.indexOf(f)+1,f.columnSpan-1),f.rowSpan>1)for(y=s,S=0;y+f.rowSpan-10){for(var c=0;c0?1:0,v=0;v0||a.outEdges.length>0))for(p=a.inEdges.concat(a.outEdges),s=0;s0)for(o=0;o1)for(a=1;a0))if(h=n.wrapper.children[0],"Horizontal"===e.orientation)for(o=e.header&&e.hasHeader?h.rows[1]:h.rows[0],r=0;r0){var e=void 0;t.lineRoutingModule&&t.constraints&rt.LineRouting&&t.lineRoutingModule.renderVirtualRegion(t,!0);for(var i=0;i0?o+1:o)].height=t.wrapper.height;else if(t.isPhase)for(l[t.rowIndex-o].offset=t.wrapper.height,f=0;f0?1:0)].width=t.wrapper.width}function FI(n,t){var i=n.shape,r=i.header&&i.hasHeader?1:0;return"Horizontal"===i.orientation?t.rowIndex-(r+=i.phases.length>0?1:0):t.columnIndex-(i.phaseSize&&i.phases.length>0?1:0)}function _I(n){var t=0,e=n.shape;return"Horizontal"===e.orientation&&(t=e.header&&e.hasHeader?1:0),e.phases.length>0&&e.phaseSize&&(t+=1),t}function UI(n,t,e,i){var r=n.shape;if(r.phases.length>0){var s=t.nameTable[r.phases[parseInt(i.toString(),10)].header.id];s&&s.maxWidth0?u+1:u);var w=Nc(n,o),C=void 0!==i?i:l.lanes.length;if(u+=C,r={element:M,cause:n.diagramActions,diagramAction:n.getDiagramAction(n.diagramActions),state:"Changing",type:"Addition",cancel:!1,laneIndex:C},n.triggerEvent(Ce.collectionChange,r),!r.cancel){if(c){var D=new Yv;D.height=e.height,o.addRow(u,D,!1),s.height=void 0!==s.height?s.height+e.height:s.height,s.wrapper.height=o.height=s.height}else{var A=new Td;A.width=e.width,o.addColumn(C+1,A,!1),s.width&&(s.width+=e.width,s.wrapper.width=o.width=s.width),n.diagramActions&ee.UndoRedo||(o.rows[0].cells[0].columnSpan+=1)}n.diagramActions&ee.UndoRedo||(M.id=""===M.id?Qe():M.id),void 0!==i?l.lanes.splice(i,0,M):l.lanes.push(M),r={element:M,cause:n.diagramActions,diagramAction:n.getDiagramAction(n.diagramActions),state:"Changed",type:"Addition",cancel:!1,laneIndex:C},n.triggerEvent(Ce.collectionChange,r),O3(o,n,s,u,C,c),h="Horizontal"===l.orientation?n.nameTable[o.rows[parseInt(u.toString(),10)].cells[0].children[0].id]:l.header&&l.hasHeader?n.nameTable[o.rows[1].cells[parseInt(u.toString(),10)].children[0].id]:n.nameTable[o.rows[0].cells[parseInt(u.toString(),10)].children[0].id],n.diagramActions&ee.UndoRedo||(d={type:"LaneCollectionChanged",changeType:"Insert",undoObject:$(M),redoObject:$(h),category:"Internal"},n.addHistoryEntry(d)),qp(n,s,"Horizontal"===l.orientation?u:l.header&&l.hasHeader?1:0),Xp(s),Oc(n,s);var R=!1;if((p=e.children)&&p.length>0)for(f=0;f0){var o=t.children[0],a=n.nameTable[o.id];(function ane(n,t,e){return n.left-(e.left||0)<=t.x&&n.right+(e.right||0)>=t.x&&n.top-(e.top||0)<=t.y&&n.bottom+(e.bottom||0)>=t.y})(o.bounds,e,r)&&(n.addChild(a,i),s=!0)}return s}function lne(n,t,e){if("SwimLane"===t.shape.type){var i=void 0,r=void 0,s=void 0,a=void 0,l=void 0,h=void 0,c=t.wrapper.bounds.x,d=t.wrapper.bounds.y,u=t.shape,p=u.padding,f=u.phases,g=void 0,v=t.wrapper.children[0],y="Horizontal"===u.orientation;if(i=u.header&&u.hasHeader?0:-1,u.phases.length>0&&(i+=1),e.offset>(y?u.lanes[0].header.width:u.lanes[0].header.height)){for(h=0;he.offset){if(g=h>0?e.offset-(h>0?f[h-1]:s).offset:e.offset,y){var b=v.columnDefinitions()[parseInt(h.toString(),10)];b.width-=g,(a=n.nameTable[u.phases[parseInt(h.toString(),10)].header.id]).maxWidth=a.wrapper.maxWidth=b.width,v.updateColumnWidth(h,b.width,!1);var M=new Td;M.width=g,l=h,v.addColumn(h,M,!1);break}var w=v.rowDefinitions()[h+i];w.height-=g,a=n.nameTable[u.phases[parseInt(h.toString(),10)].header.id],v.updateRowHeight(h+i,w.height,!1);var C=new Yv;C.height=g,l=h,v.addRow(h+i,C,!1);break}if(n.diagramActions&ee.UndoRedo&&void 0===l&&(D=n.historyManager.currentEntry.next).isLastPhase&&function hne(n,t,e,i,r,s){var a=t.shape.phases[n-2],l=e.previousPhase.offset;if(r){var h=i.columnDefinitions()[n-1],c=new Td;n>1?(c.width=h.width-(l-a.offset),h.width=l-a.offset):(c.width=h.width-l,h.width=l),i.updateColumnWidth(n-1,h.width,!1),i.addColumn(n,c,!1)}else{h=i.rowDefinitions()[parseInt(n.toString(),10)];var d=new Yv;n>1?(d.height=e.undoObject.offset-l,h.height=l-a.offset):(d.height=h.height-l,h.height=l),i.updateRowHeight(n,h.height,!1),i.addRow(1+n,d,!1)}}(l=f.length,t,D,v,y),l>=0){var A=new hb(t.shape,"phases",e,!0);if(n.diagramActions&ee.UndoRedo||(A.id+=Qe()),u.phases.splice(l,0,A),_x(v,n,t,i,y,l),y){if(r=n.nameTable[v.rows[parseInt(i.toString(),10)].cells[parseInt(l.toString(),10)].children[0].id],0===l&&u.header&&u.hasHeader){v.rows[0].cells[0].children=v.rows[0].cells[1].children,v.rows[0].cells[1].children=[];for(var x=v.rows[0],R=0;Rl+1){var O=n.nameTable[v.rows[parseInt(i.toString(),10)].cells[l+1].children[0].id];v.updateColumnWidth(l+1,L[l+1].width,!0,p),O.maxWidth=O.wrapper.maxWidth=L[l+1].width}t.width=t.wrapper.width=t.wrapper.children[0].width=v.width}else{r=n.nameTable[v.rows[i+l].cells[0].children[0].id];var N=v.rowDefinitions(),T=N[i+l].height;(function dne(n,t,e,i,r){for(var o,a,l=e.rows[parseInt(i.toString(),10)],h=e.rows[i+1],c=e.rows[i-1],d=1;di+l+1&&v.updateRowHeight(i+l+1,T=N[i+l+1].height,!0,p),t.height=t.wrapper.height=t.wrapper.children[0].height=v.actualSize.height}if(Xp(t),t.width=t.wrapper.actualSize.width,Oc(n,t),n.drag(t,c-t.wrapper.bounds.x,d-t.wrapper.bounds.y),BI(t,n),n.commandHandler.select(r),!(n.diagramActions&ee.UndoRedo)){var D={type:"PhaseCollectionChanged",changeType:"Insert",undoObject:$(A),redoObject:$(r),category:"Internal"};n.addHistoryEntry(D)}n.updateDiagramObject(t)}}}}function H3(n,t,e,i,r,s,o){var a,l,f,h=t.shape,c="Horizontal"===h.orientation,d=t.wrapper.children[0],g=c?s:o;e?(a=c?e.bounds.x+e.bounds.width:e.bounds.x,l=c?e.bounds.y:e.bounds.y+e.bounds.height):(a=d.bounds.x,l=r.bounds.y);var v=new Ne(a,l,i.desiredCellWidth,i.desiredCellHeight),S=Qv(n,0,t,{id:t.id+(c?h.lanes[g-2]:h.lanes[g-1]).id+Qe()[0],rowIndex:s,columnIndex:o,width:i.minWidth,height:i.minHeight,style:(c?h.lanes[g-2]:h.lanes[g-1]).style,constraints:ie.Default|ie.AllowDrop,container:{type:"Canvas",orientation:c?"Horizontal":"Vertical"}},!1,!1,!0);if(S.children[0].isCalculateDesiredSize=!1,d.addObject(S,s,o),r&&r.children&&r.children.length)for(f=0;f1)for(var f=1;fh.margin.left&&(h.margin.left=p)):(h.margin.top-=e.desiredCellHeight,p>h.margin.top&&(h.margin.top=p)))}(n,r,i,v,S,c,e)}function B3(n,t,e){if("SwimLane"===t.shape.type&&("ResizeSouth"===e||"ResizeEast"===e)){var i=t.shape,r=t.wrapper.children[0],s=void 0,o=void 0;"ResizeSouth"===e?"Vertical"===i.orientation?s=r.rows[r.rows.length-1].cells[0]:(o=r.rows.length-1,s=r.rows[parseInt(o.toString(),10)].cells[r.rows[parseInt(o.toString(),10)].cells.length-1]):(o=i.header&&i.hasHeader?1:0,s=r.rows[parseInt(o.toString(),10)].cells[r.rows[parseInt(o.toString(),10)].cells.length-1]),n.commandHandler.select(n.nameTable[s.children[0].id])}}function jI(n,t,e,i,r,s){var o,a,l,c,u,p,f,d=Qe(),g=n.shape,v=g.phases,y=n.offsetX-n.wrapper.actualSize.width/2,S=n.offsetY-n.wrapper.actualSize.height/2;if("Vertical"===g.orientation&&(S+=g.header&&g.hasHeader?g.header.height:0),!s)for(r||(n.id+=d,g&&g.header&&g.hasHeader?g.header.id+=d:g.header=void 0),o=0;v&&o0&&s.columnIndex>0||s.isLane)?(a=function bne(n,t,e){for(var i=new Ne,r="SwimLane"===n.shape.type?n.wrapper.children[0].rows:n.wrapper.rows,s=e?1:0;s=0;a--)i?i.id===o.children[parseInt(a.toString(),10)].id&&o.children.splice(a,1):(n.removeDependentConnector(o.children[parseInt(a.toString(),10)]),n.diagramActions&ee.UndoRedo||(n.diagramActions=n.diagramActions|ee.UndoRedo,s=!0),n.remove(o.children[parseInt(a.toString(),10)]),o.children.splice(a,1),s&&(n.diagramActions=n.diagramActions&~ee.UndoRedo))}function pne(n){return n.children[0]}function qv(n,t){t&&(n.nodes.splice(n.nodes.indexOf(t),1),n.removeFromAQuad(t),n.removeObjectsFromLayer(t),delete n.nameTable[t.id],n.removeElements(t))}function _3(n,t,e,i){var r;if("SwimLane"===e.shape.type){var s=e.shape,o=void 0;if(1===s.lanes.length)n.remove(e);else{var a=e.wrapper.bounds.x,l=e.wrapper.bounds.y,h=void 0,c=void 0,d=void 0,u=void 0,f=e.wrapper.children[0];if(o=i?s.lanes.indexOf(i):FI(e,t),r={element:t,cause:n.diagramActions,diagramAction:n.getDiagramAction(n.diagramActions),state:"Changing",type:"Removal",cancel:!1,laneIndex:o},n.triggerEvent(Ce.collectionChange,r),!r.cancel){var g=s.lanes[parseInt(o.toString(),10)],v=g.children;g.children=[];for(var y=0;y0)for(u=0;u0)for(u=0;u0)for(e=0;e1){c===l.phases.length-1&&(o=!0,a=$(l.phases[c-1]));var u=$(l.phases[parseInt(c.toString(),10)]);if(l.phases.splice(c,1),!(n.diagramActions&ee.UndoRedo)){var p={type:"PhaseCollectionChanged",changeType:"Remove",undoObject:u,previousPhase:a,redoObject:$(t),category:"Internal",isLastPhase:o};n.addHistoryEntry(p)}"Horizontal"===l.orientation?function gne(n,t,e,i){var r,s,o,a,l,h,c,d,u,p,f,g;for(i=void 0!==i?i:e.columnIndex,c=0;c1&&(s=r.cells[parseInt(i.toString(),10)],l=(o=r.cells.length-1===i?r.cells[i-1]:r.cells[i+1]).children[0],s.children.length>0))if(f=n.nameTable[(a=s.children[0]).id],0===o.children.length&&s.children.length>0)o.children=s.children,o.columnSpan=s.columnSpan-1;else{for(d=0;d0){var M=s.children[0],w=n.nameTable[M.id];if(i=e.x&&a.bounds.y<=e.y&&a.bounds.bottom>=e.y)&&!(t.constraints&ie.AllowMovingOutsideLane)){var l=$(t);n.clearSelection(),W3(n,t),t.parentId="",t.parentObj=n,t.propName="nodes";var h={type:"ChildCollectionChanged",category:"Internal",undoObject:l,redoObject:$(t)};n.addHistoryEntry(h),n.commandHandler.isContainer&&(n.commandHandler.isContainer=!1,n.endGroupAction()),Y3(t,n)}n.protectPropertyChange(o)}}function VI(n,t){var e,i,r;return n.enableServerDataBinding(!1),ce()||(n.selectedObject.helperObject?r=n.selectedObject.helperObject:(n.selectedItems.nodes.length>0||n.selectedItems.connectors.length>0)&&(t instanceof oi&&t.nodes.length+t.connectors.length===1?(e=t.nodes.length>0?t.nodes[0]:t.connectors[0],i=n.selectedItems.wrapper.children[0]):(e=t,i=n.selectedItems.wrapper),n.selectedObject.actualObject=e,!n.currentSymbol&&(e.isLane&&Wx(e,n)&&cs(n,e)||!e.isLane&&cs(n,e)||n.constraints&rt.LineRouting&&n.selectedItems.nodes.length>0))&&(r=function Mne(n,t){for(var e,i={},r=0,s=Object.keys(t);r=t.x-e&&n.x<=t.x+e&&n.y>=t.y-e&&n.y<=t.y+e}function Xa(n){return n.selectedItems.nodes.length>0||n.selectedItems.connectors.length>0}function G3(n){return 1===n.selectedItems.connectors.length&&!n.selectedItems.nodes.length}function _r(n,t,e,i){if(void 0===e&&(e=!0),t instanceof oi)return!0;if(t instanceof te)for(;t;){if(-1!==n.selectedItems.nodes.indexOf(t)&&void 0===n.selectedItems.annotation)return!0;if(e)break;t=n.nameTable[t.parentId]}else if(t instanceof de){if(-1!==n.selectedItems.connectors.indexOf(t)&&void 0===n.selectedItems.annotation)return!0}else if((t instanceof Zn||t instanceof Nr)&&n.selectedItems.annotation&&n.selectedItems.wrapper.children[0].id===i.id)return!0;return!1}var Yx={None:"default",Rotate:"crosshair",Select:"default",Drag:"move",ResizeWest:"w-resize",ResizeEast:"e-resize",ResizeSouth:"s-resize",ResizeNorth:"n-resize",Draw:"crosshair",PortDraw:"crosshair",ResizeNorthEast:"ne-resize",ResizeNorthWest:"nw-resize",ResizeSouthEast:"se-resize",ResizeSouthWest:"sw-resize",ConnectorSourceEnd:"move",ConnectorTargetEnd:"move",BezierSourceThumb:"move",BezierTargetThumb:"move",OrthoThumb:"move",SegmentEnd:"move",Pan:"grab",Hyperlink:"pointer",PortDrag:"pointer",LabelSelect:"pointer",LabelDrag:"move",LabelRotate:"crosshair",LabelResizeWest:"w-resize",LabelResizeEast:"e-resize",LabelResizeSouth:"s-resize",LabelResizeNorth:"n-resize",LabelResizeNorthEast:"ne-resize",LabelResizeNorthWest:"nw-resize",LabelResizeSouthEast:"se-resize",LabelResizeSouthWest:"sw-resize"},ds=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Ld=function(n,t,e,i){return new(e||(e=Promise))(function(r,s){function o(h){try{l(i.next(h))}catch(c){s(c)}}function a(h){try{l(i.throw(h))}catch(c){s(c)}}function l(h){h.done?r(h.value):new e(function(c){c(h.value)}).then(o,a)}l((i=i.apply(n,t||[])).next())})},Nd=function(n,t){var i,r,s,o,e={label:0,sent:function(){if(1&s[0])throw s[1];return s[1]},trys:[],ops:[]};return o={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function a(h){return function(c){return function l(h){if(i)throw new TypeError("Generator is already executing.");for(;e;)try{if(i=1,r&&(s=2&h[0]?r.return:h[0]?r.throw||((s=r.return)&&s.call(r),0):r.next)&&!(s=s.call(r,h[1])).done)return s;switch(r=0,s&&(h=[2&h[0],s.value]),h[0]){case 0:case 1:s=h;break;case 4:return e.label++,{value:h[1],done:!1};case 5:e.label++,r=h[1],h=[0];continue;case 7:h=e.ops.pop(),e.trys.pop();continue;default:if(!(s=(s=e.trys).length>0&&s[s.length-1])&&(6===h[0]||2===h[0])){e=0;continue}if(3===h[0]&&(!s||h[1]>s[0]&&h[1]-1&&(r=i.fixedUserHandles[parseInt(o.toString(),10)]);this.commandHandler.triggerEvent(Ce.fixedUserHandleClick,{fixedUserHandle:r,element:e.source}),n.prototype.mouseUp.call(this,e)},t}(us),Od=function(n){function t(e,i){var r=n.call(this,e,!0)||this;return r.isConnected=!1,r.endPoint=i,r}return ds(t,n),t.prototype.mouseDown=function(e){return Ld(this,void 0,void 0,function(){var r,s,o,a,l;return Nd(this,function(h){if(this.inAction=!0,this.undoElement=void 0,this instanceof pa||(this.undoElement=$(e.source)),n.prototype.mouseDown.call(this,e),e.source&&e.source.connectors&&(this.oldConnector=$(r=e.source.connectors[0])),"BezierSourceThumb"===this.endPoint||"BezierTargetThumb"===this.endPoint)for(s=0;s0))},t.prototype.endAction=function(){n.prototype.endAction.call(this),this.prevPosition=null,this.endPoint=null},t}(us),ua=function(n){function t(e,i){var r=n.call(this,e,!0)||this;return r.currentTarget=null,r.isStartAction=!1,r.canCancel=!1,r.canTrigger=!1,r.objectType=i,r}return ds(t,n),t.prototype.mouseDown=function(e){if(e.source instanceof te||e.source instanceof de){var i=this.commandHandler.getSelectedObject();this.commandHandler.selectObjects([e.source],e.info&&e.info.ctrlKey,i);var r={nodes:[],connectors:[]};e.source instanceof te?r.nodes.push($(e.source)):r.connectors.push($(e.source)),this.undoElement=$(r)}else this.undoElement=$(e.source);this.undoParentElement=this.commandHandler.getSubProcess(e.source),"Port"===this.objectType&&(this.portId=e.sourceWrapper.id),this.commandHandler.insertBlazorConnector(e.source),n.prototype.mouseDown.call(this,e),this.initialOffset={x:0,y:0}},t.prototype.mouseUp=function(e,i){return Ld(this,void 0,void 0,function(){var s,o,a,l,h,c,d,u,f,g,v,y,S,b,M;return Nd(this,function(w){if(this.checkPropertyValue(),a=!1,h={nodes:[],connectors:[]},"Port"!==this.objectType){if(e.source instanceof te||e.source instanceof de?(e.source instanceof te?h.nodes.push($(e.source)):h.connectors.push($(e.source)),(o=$(h)).offsetX=(c=e.source.wrapper).offsetX,o.offsetY=c.offsetY):o=$(e.source),("helper"===(l=this.commandHandler.renderContainerHelper(e.source)||e.source||this.commandHandler.renderContainerHelper(e.source)).id||"helper"!==l.id)&&((l instanceof oi&&(Math.round(l.width)===Math.round(this.undoElement.width)&&Math.round(l.height)===Math.round(this.undoElement.height)||l.selectedObjects&&1===l.selectedObjects.length)||!(l instanceof oi))&&(l.offsetX!==this.undoElement.offsetX||l.offsetY!==this.undoElement.offsetY||l.sourcePoint!==this.undoElement.sourcePoint||l.targetPoint!==this.undoElement.targetPoint)||this.isSelectionHasConnector(l))&&(e.source&&(s={offsetX:e.source.wrapper.offsetX,offsetY:e.source.wrapper.offsetY}),g={source:e.source,state:"Completed",oldValue:this.intialValue,newValue:s,target:this.currentTarget,targetPosition:this.currentPosition,allowDrop:(g={source:e.source,state:"Completed",oldValue:this.intialValue,newValue:s,target:this.currentTarget,targetPosition:this.currentPosition,allowDrop:!0,cancel:!1}).allowDrop,cancel:g.cancel},d=!0,"helper"===l.id?this.canTrigger?(this.commandHandler.triggerEvent(Ce.positionChange,g),this.connectorEndPointChangeEvent(g),d=!0):d=!1:(this.commandHandler.triggerEvent(Ce.positionChange,g),this.connectorEndPointChangeEvent(g)),!i&&d&&(this.commandHandler.startGroupAction(),a=!0,M={type:"PositionChanged",redoObject:$(o),undoObject:$(this.undoElement),category:"Internal"},o.nodes[0]&&o.nodes[0].processId&&(u={type:"SizeChanged",category:"Internal",undoObject:this.undoParentElement,redoObject:this.commandHandler.getSubProcess(e.source)},this.commandHandler.addHistoryEntry(u)),this.commandHandler.addHistoryEntry(M))),this.commandHandler.snapPoint(this.prevPosition,this.currentPosition,0,0),this.commandHandler.removeSnap(),this.commandHandler.removeHighlighter(),e.source&&this.currentTarget&&PI(this.currentTarget)&&this.commandHandler.isDroppable(e.source,this.currentTarget)){if(f=!0,this.commandHandler.drop(this.currentElement,this.currentTarget,this.currentPosition),this.currentTarget&&this.currentTarget instanceof de&&!0===this.commandHandler.diagram.enableConnectorSplit)if(this.currentElement&&this.currentElement instanceof te){if(void 0!==this.currentElement.children)for(b=0;b0)for(var s=0;s0)for(var a=0;a0)for(a=0;a0&&e.connectors.length>0)||e.width===this.undoElement.width&&e.height===this.undoElement.height)},t.prototype.mouseMove=function(e){n.prototype.mouseMove.call(this,e);var r,s,i=!1;(r=this.commandHandler.renderContainerHelper(e.source)||e.source)instanceof te||r instanceof de?r instanceof te?r.offsetX===this.undoElement.nodes[0].offsetX&&r.offsetY===this.undoElement.nodes[0].offsetY&&(i=!0):z.equals(r.sourcePoint,this.undoElement.connectors[0].sourcePoint)&&z.equals(r.targetPoint,this.undoElement.connectors[0].targetPoint)&&(i=!0):r.wrapper.offsetX===this.undoElement.wrapper.offsetX&&r.wrapper.offsetY===this.undoElement.wrapper.offsetY&&(i=!0),r&&(s={offsetX:r.wrapper.offsetX,offsetY:r.wrapper.offsetY});var o={source:r,state:"Start",oldValue:s,newValue:s,target:e.target,targetPosition:e.position,allowDrop:!0,cancel:!1};if(o={source:r,state:"Start",oldValue:s,newValue:s,target:e.target,targetPosition:e.position,allowDrop:o.allowDrop,cancel:o.cancel},this.isStartAction||(this.intialValue={offsetX:r.wrapper.offsetX,offsetY:r.wrapper.offsetY}),i&&!ce()&&(this.commandHandler.triggerEvent(Ce.positionChange,o),this.connectorEndPointChangeEvent(o),this.isStartAction=!0),this.currentPosition=e.position,"Port"!==this.objectType){var h=this.initialOffset.x+(this.currentPosition.x-this.prevPosition.x),c=this.initialOffset.y+(this.currentPosition.y-this.prevPosition.y);this.commandHandler.dragOverElement(e,this.currentPosition),this.commandHandler.disConnect(e.source),this.commandHandler.removeSnap();var d,u=void 0,p=this.commandHandler.snapPoint(this.prevPosition,this.currentPosition,h,c);this.initialOffset.x=h-p.x,this.initialOffset.y=c-p.y,r&&(d={offsetX:r.wrapper.offsetX,offsetY:r.wrapper.offsetY},u={offsetX:r.wrapper.offsetX+p.x,offsetY:r.wrapper.offsetY+p.y}),this.currentTarget&&e.target!==this.currentTarget&&this.commandHandler.removeChildFromBPmn(e.source,e.target,this.currentTarget),this.currentTarget=e.target;var f={source:r,state:"Progress",oldValue:d,newValue:u,target:e.target,targetPosition:e.position,allowDrop:!0,cancel:!1};if(this.commandHandler.triggerEvent(Ce.positionChange,f),this.canTrigger=!0,this.connectorEndPointChangeEvent(f,p),!f.cancel&&!this.canCancel){this.blocked=!this.commandHandler.dragSelectedObjects(p.x,p.y);var g=!this.commandHandler.mouseOver(this.currentElement,this.currentTarget,this.currentPosition);this.blocked=this.blocked||g}if(this.commandHandler.removeStackHighlighter(),this.commandHandler.renderStackHighlighter(e),this.currentTarget&&e.source!==this.currentTarget&&this.commandHandler.isDroppable(e.source,this.currentTarget)&&"helper"!==e.source.id){var v=e.source instanceof oi?e.source.nodes[0]:e.source;!this.commandHandler.isParentAsContainer(v,!0)&&"SwimLane"!==v.shape.type&&!v.shape.isPhase&&(this.currentTarget.isLane?this.commandHandler.renderStackHighlighter(e,this.currentTarget):this.commandHandler.drawHighlighter(this.currentTarget))}else this.commandHandler.removeHighlighter();if(this.commandHandler.canEnableDefaultTooltip()){var y=this.getTooltipContent(e.source);this.commandHandler.showTooltip(e.source,e.position,ko(function(){return y}),"MoveTool",this.isTooltipVisible),this.isTooltipVisible=!1}}else{var b=Hi(),M=e.source;qi(b,-M.rotateAngle||-M.wrapper.rotateAngle,M.offsetX||M.wrapper.offsetX,M.offsetY||M.wrapper.offsetY);var w=Je(b,{x:this.prevPosition.x,y:this.prevPosition.y}),C=Je(b,{x:e.position.x,y:e.position.y});this.commandHandler.portDrag(e.source,e.sourceWrapper,C.x-w.x,C.y-w.y)}return this.prevPosition=this.currentPosition,!this.blocked},t.prototype.getTooltipContent=function(e){return"X:"+Math.round(e.wrapper.bounds.x)+" Y:"+Math.round(e.wrapper.bounds.y)},t.prototype.mouseLeave=function(e){this.mouseUp(e)},t.prototype.endAction=function(){n.prototype.endAction.call(this),this.currentTarget=null,this.prevPosition=null},t}(us),Qx=function(n){function t(e){var i=n.call(this,e,!0)||this;return i.rotateStart=!1,i}return ds(t,n),t.prototype.mouseDown=function(e){if(this.undoElement=$(e.source),this.undoElement.nodes[0]&&this.undoElement.nodes[0].children)for(var r=this.commandHandler.getAllDescendants(this.undoElement.nodes[0],[]),s=0;s=2){var s=e.startTouches[0],o=e.startTouches[1],a=e.moveTouches[0],l=e.moveTouches[1],h=this.getDistance(a,l)/this.getDistance(s,o);this.commandHandler.zoom(h,0,0,e.position),this.updateTouch(s,a),this.updateTouch(o,l)}}else this.commandHandler.scroll(this.currentPosition.x-this.prevPosition.x,this.currentPosition.y-this.prevPosition.y,this.currentPosition);return this.commandHandler.dataBinding(),!this.blocked},t.prototype.mouseUp=function(e){this.commandHandler.setBlazorDiagramProps(!1),this.checkPropertyValue(),this.commandHandler.updatePanState(!1),n.prototype.mouseUp.call(this,e),this.inAction=!1},t.prototype.endAction=function(){n.prototype.endAction.call(this)},t.prototype.getDistance=function(e,i){var r=i.pageX-e.pageX,s=i.pageY-e.pageY;return Math.sqrt(r*r+s*s)},t.prototype.updateTouch=function(e,i){e.pageX=i.pageX,e.pageY=i.pageY},t}(us),One=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseUp=function(e){this.checkPropertyValue(),this.commandHandler.initExpand(e),n.prototype.mouseUp.call(this,e)},t}(us),X3=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseUp=function(e){this.checkPropertyValue();var i="_blank",r="",s=window.innerHeight,o=window.innerWidth,a=window.screenTop,l=window.screenLeft;"CurrentTab"===e.sourceWrapper.hyperlink.hyperlinkOpenState?i="_self":"NewWindow"===e.sourceWrapper.hyperlink.hyperlinkOpenState&&(r="height="+s+",width="+o+",top="+a+",left="+l),window.open(e.sourceWrapper.hyperlink.link,i,r).focus(),n.prototype.mouseUp.call(this,e)},t}(us),Oh=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseDown=function(e){if(n.prototype.mouseDown.call(this,e),this.inAction=!0,this.drawingObject){var r=void 0,s=this.drawingObject.shape;this.drawingObject.shape.points.push(r={x:(r=s.points[s.points.length-1]).x,y:r.y})}else this.startPoint={x:this.startPosition.x,y:this.startPosition.y},this.drawingObject=this.commandHandler.drawObject({offsetX:this.currentPosition.x,offsetY:this.currentPosition.y,width:5,height:5,style:{strokeColor:"black",strokeWidth:1},shape:{type:"Basic",shape:"Polygon",points:[{x:this.startPoint.x,y:this.startPoint.y},{x:this.currentPosition.x,y:this.currentPosition.y}]}})},t.prototype.mouseMove=function(e){if(n.prototype.mouseMove.call(this,e),this.inAction){var i=this.drawingObject.shape;if(i.points[i.points.length-1].x=this.currentPosition.x,i.points[i.points.length-1].y=this.currentPosition.y,this.drawingObject.wrapper.children[0].data=mx(this.drawingObject.shape.points),this.inAction&&!1===z.equals(this.currentPosition,this.prevPosition)){var r=Ne.toBounds(this.drawingObject.shape.points);this.commandHandler.updateNodeDimension(this.drawingObject,r)}}return!0},t.prototype.mouseUp=function(e,i){this.checkPropertyValue(),n.prototype.mouseMove.call(this,e),this.inAction&&(this.inAction=!1,this.commandHandler.addObjectToDiagram(this.drawingObject)),this.endAction()},t.prototype.mouseWheel=function(e){n.prototype.mouseWheel.call(this,e),this.mouseMove(e)},t.prototype.endAction=function(){this.inAction=!1,this.drawingObject=null},t}(us),kh=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseMove=function(e){if(n.prototype.mouseMove.call(this,e),this.inAction){var i=this.drawingObject;i.targetPoint=this.currentPosition,this.commandHandler.updateConnectorPoints(i)}return!0},t.prototype.mouseDown=function(e){if(n.prototype.mouseDown.call(this,e),this.inAction=!0,this.drawingObject){var r=this.drawingObject,s=void 0;(s=new kl(r,"segments",{type:"Straight"},!0)).point=this.currentPosition,r.segments[r.segments.length-1]=s}else this.drawingObject=this.commandHandler.drawObject({id:"Connector",type:"Straight",sourcePoint:this.currentPosition,targetPoint:this.currentPosition})},t.prototype.mouseWheel=function(e){n.prototype.mouseWheel.call(this,e),this.mouseMove(e)},t.prototype.mouseUp=function(e){if(this.checkPropertyValue(),n.prototype.mouseMove.call(this,e),this.inAction&&this.drawingObject){var i=this.drawingObject;i.segments[i.segments.length-1].point={x:0,y:0},this.commandHandler.addObjectToDiagram(this.drawingObject)}this.endAction()},t.prototype.endAction=function(){this.drawingObject=null,this.inAction=!1},t}(us),kne=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseDown=function(e){this.inAction=!0,this.undoElement=$(e.source),this.annotationId=e.sourceWrapper.id,n.prototype.mouseDown.call(this,e)},t.prototype.mouseMove=function(e){n.prototype.mouseMove.call(this,e);var i=this.currentPosition.x-this.prevPosition.x,r=this.currentPosition.y-this.prevPosition.y,s=e.source;if(s instanceof te){var o=Hi();qi(o,-s.rotateAngle,0,0);var a=Je(o,{x:i,y:r});i=a.x,r=a.y}return this.inAction&&(this.commandHandler.labelDrag(e.source,e.sourceWrapper,i,r),this.commandHandler.updateSelector()),this.prevPosition=this.currentPosition,!this.blocked},t.prototype.mouseUp=function(e){this.checkPropertyValue();var i=e.source;this.inAction=!1;var r={type:"AnnotationPropertyChanged",objectId:this.annotationId,undoObject:$(this.undoElement),category:"Internal",redoObject:$(i)};this.commandHandler.addHistoryEntry(r),n.prototype.mouseUp.call(this,e)},t.prototype.mouseLeave=function(e){this.mouseUp(e)},t}(us),Pne=function(n){function t(e,i){var r=n.call(this,e,!0)||this;return r.corner=i,r}return ds(t,n),t.prototype.mouseDown=function(e){this.inAction=!0;var i=e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0];this.annotationId=e.source.wrapper.children[0].id,this.undoElement=$(i);var r=e.source.wrapper.children[0];this.initialBounds={x:r.offsetX,y:r.offsetY,width:r.actualSize.width,height:r.actualSize.height},n.prototype.mouseDown.call(this,e)},t.prototype.mouseMove=function(e){return n.prototype.mouseMove.call(this,e),this.inAction&&this.resizeObject(e),!this.blocked},t.prototype.mouseUp=function(e){this.checkPropertyValue();var i=e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0];this.inAction=!1;var r={type:"AnnotationPropertyChanged",objectId:this.annotationId,redoObject:$(i),undoObject:$(this.undoElement),category:"Internal"};this.commandHandler.addHistoryEntry(r),n.prototype.mouseUp.call(this,e)},t.prototype.mouseLeave=function(e){this.mouseUp(e)},t.prototype.resizeObject=function(e){var i,s,o,r=e.source.wrapper.children[0],a={x:r.offsetX,y:r.offsetY},l=r.rotateAngle;l=((l+=(i=e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0])instanceof te?i.rotateAngle:0)+360)%360;var h=Hi();qi(h,l,a.x,a.y);var c=this.corner.slice(5),d=this.updateSize(r,this.startPosition,this.currentPosition,c,this.initialBounds,l),u=r.offsetX-r.actualSize.width*r.pivot.x,p=r.offsetY-r.actualSize.height*r.pivot.y,f=this.getPivot(c),g=Je(h,f={x:u+r.actualSize.width*f.x,y:p+r.actualSize.height*f.y});d.x=g.x,d.y=g.y,this.commandHandler.labelResize(i,e.source.annotation,s=(s=d.width)<0?1:s,o=(o=d.height)<0?1:o,d,e.source),this.commandHandler.updateSelector()},t}(us),zne=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseDown=function(e){this.inAction=!0,this.annotationId=e.source.wrapper.children[0].id,this.undoElement=$(e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0]),n.prototype.mouseDown.call(this,e)},t.prototype.mouseMove=function(e){return n.prototype.mouseMove.call(this,e),e.source&&this.inAction&&(this.commandHandler.labelRotate(e.source.nodes[0]?e.source.nodes[0]:e.source.connectors[0],e.source.annotation,this.currentPosition,e.source),this.commandHandler.updateSelector()),this.prevPosition=this.currentPosition,!this.blocked},t.prototype.mouseUp=function(e){this.checkPropertyValue(),this.inAction=!1;var r={type:"AnnotationPropertyChanged",objectId:this.annotationId,redoObject:$(e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0]),undoObject:$(this.undoElement),category:"Internal"};this.commandHandler.addHistoryEntry(r),n.prototype.mouseUp.call(this,e)},t.prototype.mouseLeave=function(e){this.mouseUp(e)},t}(us),Rne=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseMove=function(e){if(n.prototype.mouseMove.call(this,e),this.inAction){var i=this.drawingObject.shape;if(i.points.push(this.currentPosition),this.drawingObject.wrapper.children[0].data=yx(this.drawingObject.shape.points),i.data=yx(i.points),this.inAction&&!1===z.equals(this.currentPosition,this.prevPosition)){var s=Ne.toBounds(this.drawingObject.shape.points);this.commandHandler.updateNodeDimension(this.drawingObject,s)}}return!0},t.prototype.mouseDown=function(e){n.prototype.mouseDown.call(this,e),this.inAction=!0,this.startPoint={x:this.startPosition.x,y:this.startPosition.y},this.drawingObject=this.commandHandler.drawObject({offsetX:this.currentPosition.x,offsetY:this.currentPosition.y,width:5,height:5,style:{strokeColor:"black",strokeWidth:1,fill:"transparent"},shape:{type:"Path",points:[{x:this.startPoint.x,y:this.startPoint.y},{x:this.currentPosition.x,y:this.currentPosition.y}]}})},t.prototype.mouseUp=function(e){if(this.checkPropertyValue(),this.inAction){this.inAction=!1;var s=this.drawingObject.shape,o=s.points;this.commandHandler.addObjectToDiagram(this.drawingObject),this.commandHandler.diagram.remove(this.commandHandler.diagram.nameTable[""+this.drawingObject.id]),o=this.pointReduction(o,10);var h={id:"newConnector"+Qe(),type:"Bezier",sourcePoint:{x:o[0].x,y:o[0].y},targetPoint:{x:o[o.length-1].x,y:o[o.length-1].y},segments:[],bezierSettings:{allowSegmentsReset:!1}};this.drawingObject=this.commandHandler.drawObject(h),this.drawingObject=this.bezierCurveSmoothness(o,.5,this.drawingObject,s),this.commandHandler.updateConnectorPoints(this.drawingObject),this.commandHandler.addObjectToDiagram(this.drawingObject),n.prototype.mouseUp.call(this,e)}},t.prototype.pointReduction=function(e,i){if(null===e||e.length<3)return e;var s=e.length-1,o=[];for(o.push(0),o.push(s);e[parseInt((0).toString(),10)]===e[parseInt(s.toString(),10)];)s--;this.reduction(e,0,s,i,o);var a=[];return o.sort(function(l,h){return l-h}),o.forEach(function(l){a.push(e[parseInt(l.toString(),10)])}),a},t.prototype.reduction=function(e,i,r,s,o){for(var a=0,l=0,h=i;ha&&(a=c,l=h)}a>s&&0!==l&&(o.push(l),this.reduction(e,i,l,s,o),this.reduction(e,l,r,s,o))},t.prototype.perpendicularDistance=function(e,i,r){return Math.abs(.5*(e.x*i.y-i.x*e.y+(i.x*r.y-r.x*i.y)+(r.x*e.y-e.x*r.y)))/Math.sqrt(Math.pow(e.x-i.x,2)+Math.pow(e.y-i.y,2))*2},t.prototype.bezierCurveSmoothness=function(e,i,r,s){if(e.length<3)return r;for(var o=0;o=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Hne=function(n){if(n)switch(n.type){case"Bpmn":return Une;case"UmlActivity":return _ne;case"UmlClassifier":return Wne;default:return Kv}return Kv},Bne=function(n){if(n)switch(n.type){case"Straight":default:return kl;case"Bezier":return ps;case"Orthogonal":return bi}},q3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I(10)],t.prototype,"width",void 0),Pe([I(10)],t.prototype,"height",void 0),Pe([I("Arrow")],t.prototype,"shape",void 0),Pe([re({fill:"black",strokeColor:"black",strokeWidth:1},Al)],t.prototype,"style",void 0),Pe([re({x:0,y:.5},z)],t.prototype,"pivot",void 0),Pe([I("")],t.prototype,"pathData",void 0),t}(Ee),GI=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I(0)],t.prototype,"angle",void 0),Pe([I(0)],t.prototype,"distance",void 0),t}(Ee),Fne=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I(Mx.All)],t.prototype,"controlPointsVisibility",void 0),Pe([I("FreeForm")],t.prototype,"segmentEditOrientation",void 0),Pe([I(SI.Default)],t.prototype,"smoothness",void 0),Pe([I(!0)],t.prototype,"allowSegmentsReset",void 0),t}(Ee),Kv=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I("None")],t.prototype,"type",void 0),t}(Ee),_ne=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I("Object")],t.prototype,"flow",void 0),Pe([I(30)],t.prototype,"exceptionFlowHeight",void 0),t}(Kv),Une=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I("Sequence")],t.prototype,"flow",void 0),Pe([I("Normal")],t.prototype,"sequence",void 0),Pe([I("Default")],t.prototype,"message",void 0),Pe([I("Default")],t.prototype,"association",void 0),t}(Kv),$3=function(n){function t(e,i,r,s){var o=n.call(this,e,i,r,s)||this;return o.points=[],o}return Qs(t,n),Pe([I("Straight")],t.prototype,"type",void 0),Pe([I(!0)],t.prototype,"allowDrag",void 0),t}(Ee),kl=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),t.prototype.getClassName=function(){return"StraightSegment"},Pe([re({x:0,y:0},z)],t.prototype,"point",void 0),t}($3),ps=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),t.prototype.getClassName=function(){return"BezierSegment"},t.prototype.getPoints=function(e,i){var r=[];if(r.length>0||null!=i){var o=this.bezireToPoly(r.length>0?r[r.length-1]:i,e);r.push.apply(r,o)}return r},t.prototype.bezireToPoly=function(e,i){var r=[];return i&&this.flattenCubicBezier(r,e,i.bezierPoint1,i.bezierPoint2,{x:i.points[1].x,y:i.points[1].y},10),r},t.prototype.flattenCubicBezier=function(e,i,r,s,o,a){var h,l=(z.findLength(i,r)+z.findLength(r,s)+z.findLength(s,o))/a;for(h=0;h<=l;h++){var c=h/l;e.push({x:(1-c)*(1-c)*(1-c)*i.x+3*c*(1-c)*(1-c)*r.x+3*c*c*(1-c)*s.x+c*c*c*o.x,y:(1-c)*(1-c)*(1-c)*i.y+3*c*(1-c)*(1-c)*r.y+3*c*c*(1-c)*s.y+c*c*c*o.y})}},Pe([I("Horizontal")],t.prototype,"orientation",void 0),Pe([re({x:0,y:0},z)],t.prototype,"point1",void 0),Pe([re({x:0,y:0},z)],t.prototype,"point2",void 0),Pe([re({angle:0,distance:0},GI)],t.prototype,"vector1",void 0),Pe([re({angle:0,distance:0},GI)],t.prototype,"vector2",void 0),t}(kl),bi=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),t.prototype.getClassName=function(){return"OrthogonalSegment"},Pe([I(null)],t.prototype,"length",void 0),Pe([I(null)],t.prototype,"direction",void 0),t}($3);function Z3(n,t,e){var s=e?45:180/(2+2/(n.height/n.width)),o=s,a=180-s,l=a+2*s,h=360-s,c=Gt(t,n.center);return c>o&&ca&&cl&&cMath.abs(t.y-n.y)?n.x=c)return s=z.findAngle(n[parseInt(d.toString(),10)],n[d+1]),{point:r=z.transform(n[parseInt(d.toString(),10)],s,c-(a||0)),index:l=d};a=o[parseInt(d.toString(),10)]}return{point:r,index:l}}(n,t),r=z.findAngle(n[i.index],n[i.index+1]),s=function yse(n){var e=0;switch(n.alignment){case"Center":case"After":e=0;break;case"Before":e=-0}return e}(t),o=z.transform(i.point,r+45,s);return i.point=o,i.angle=r,i}(i,e),h=l.point;s.id=this.id+"_"+e.id;var c=e.style;s.style={fill:c.fill,strokeColor:c.strokeColor,gradient:null,opacity:c.opacity,strokeDashArray:c.strokeDashArray,strokeWidth:c.strokeWidth},0===r.width&&(r.width=this.style.strokeWidth),0===r.height&&(r.height=this.style.strokeWidth);var d_y=(h.y-r.y)/r.height;a.x=r.width*((h.x-r.x)/r.width),a.y=r.height*d_y;var g,v,u=pF(e,l.angle,i),p=u.hAlign,f=u.vAlign;return"left"===p?(g="Left",a.x+=e.displacement.x):"right"===p?(g="Right",a.x-=e.displacement.x):"center"===p&&(g="Center"),"top"===f?(v="Top",a.y+=e.displacement.y):"bottom"===f?(v="Bottom",a.y-=e.displacement.y):"center"===f&&(v="Center"),s.horizontalAlignment=g,s.verticalAlignment=v,(s=im(s,o&&"Label"!==o.flipMode&&"None"!==o.flipMode?this.flip:"None",e)).float=!0,s.connectionDirection=e.connectionDirection,s.setOffsetWithRespectToBounds(a.x,a.y,"Absolute"),s.relativeMode="Point",s.visible=!(!ga(e,ti.Visible)||ga(e,ti.Hover)||ga(e,ti.Connect)),s.elementActions=s.elementActions|Xr.ElementIsPort,s},t.prototype.getConnectorRelation=function(){var e=this.shape;"Association"===e.relationship?(this.segments[0].type="Straight",this.sourceDecorator.shape="None",this.targetDecorator.shape="Arrow"):"Inheritance"===e.relationship?(this.segments[0].type="Orthogonal",this.sourceDecorator.shape="None",this.targetDecorator.shape="Arrow"):"Composition"===e.relationship||"Aggregation"===e.relationship?(this.segments[0].type="Orthogonal",this.sourceDecorator.shape="Diamond",this.targetDecorator.shape="None"):"Dependency"===e.relationship?(this.segments[0].type="Orthogonal",this.sourceDecorator.shape="None",this.targetDecorator.shape="OpenArrow"):"Realization"===e.relationship&&(this.segments[0].type="Orthogonal",this.sourceDecorator.shape="None",this.targetDecorator.shape="Arrow"),"BiDirectional"===e.associationType&&(this.sourceDecorator.shape="None",this.targetDecorator.shape="None");var i,o,r="",s="";e.multiplicity.source&&(e.multiplicity.source.lowerBounds=e.multiplicity.source.lowerBounds,e.multiplicity.source.upperBounds=e.multiplicity.source.upperBounds),e.multiplicity.target&&(e.multiplicity.target.lowerBounds=e.multiplicity.target.lowerBounds,e.multiplicity.target.upperBounds=e.multiplicity.target.upperBounds);var a=e.multiplicity.source,l=e.multiplicity.target;o=a.upperBounds?a.lowerBounds+"..."+a.upperBounds:a.lowerBounds,i=l.upperBounds?l.lowerBounds+"..."+l.upperBounds:l.lowerBounds,"ManyToOne"===e.multiplicity.type&&(e.multiplicity.target.optional=!1,r=o||"*",s="1"),"OneToMany"===e.multiplicity.type&&(e.multiplicity.source.optional=!1,s=i||"*",r="1"),"ManyToMany"===e.multiplicity.type&&(r=o||"*",s=i||"*"),"OneToOne"===e.multiplicity.type&&(e.multiplicity.target.optional=!1,e.multiplicity.source.optional=!1,r="1",s="1"),this.annotations=[{id:this.id+"sourcelabel",content:r,offset:0,alignment:"Before",margin:{right:5,bottom:5}},{id:this.id+"targetlabel",content:s,offset:1,alignment:"Before",margin:{right:5,bottom:5}}]},t.prototype.getBpmnSequenceFlow=function(){var e=new Ke,i=new Ke;return"Normal"===this.shape.sequence&&"Bezier"!==this.type&&(this.targetDecorator.shape="Arrow"),"Default"===this.shape.sequence&&(e=this.getSegmentElement(this,e),i=IF(this.intermediatePoints,this),this.targetDecorator.shape="Arrow"),"Conditional"===this.shape.sequence&&(this.targetDecorator.shape="Arrow",this.sourceDecorator.shape="Diamond",i.id=this.id+this.shape.type),i},t.prototype.getUMLObjectFlow=function(){if(this.annotations)for(var e=0;e0&&(this.sourcePoint=o[0],this.targetPoint=o[o.length-1]),o},t.prototype.clipDecorator=function(e,i,r,s){var a,l,o={x:0,y:0},h=i.length,c=z.distancePoints(a=r?i[0]:i[h-1],l=r?i[1]:i[h-2]);c=0===c?1:c;var d=1,u=r?e.sourceWrapper:e.targetWrapper;u&&(d=u.style.strokeWidth,s&&s&ee.DecoratorPropertyChange&&(d=1));var p=d-1;return o.x=Math.round(a.x+p*(l.x-a.x)/c),o.y=Math.round(a.y+p*(l.y-a.y)/c),(r&&"None"!==e.sourceDecorator.shape||!r&&"None"!==e.targetDecorator.shape)&&(o=z.adjustPoint(o,l,!0,s&ee.DecoratorPropertyChange?0:d/2)),o},t.prototype.clipDecorators=function(e,i,r){return"None"!==e.sourceDecorator.shape&&(i[0]=this.clipDecorator(e,i,!0,r)),"None"!==e.targetDecorator.shape&&(i[i.length-1]=this.clipDecorator(e,i,!1,r)),i},t.prototype.updateSegmentElement=function(e,i,r,s){var o=new Ne,a=this.getSegmentPath(e,i,s);if("Bezier"===e.type){if(this.segments.length>0)for(var l=0;l0)if("Straight"===e.type&&e.segments.length<2)for(var o=0;o1)for(o=0;o0&&"Bezier"!==this.type)for(var p=0;p0&&(a=p0&&(f<2*this.cornerRadius?(l=z.adjustPoint(h[parseInt(p.toString(),10)],h[p+1],!0,f/2),p0&&(s=this.bridgePath(e,s,p),"Orthogonal"===e.type&&(s=this.bridgePath(e,s,p+1))),s+=" L"+a.x+" "+a.y))}else if("Bezier"===this.type){var g=void 0,v=void 0;if(this.parentObj.element){var y=this.parentObj.element.ej2_instances[0].eventHandler.action;g=this.parentObj.element.ej2_instances[0].eventHandler.tool instanceof kd,v=y.includes("PortDraw")||y.includes("Drag")}for(var S=void 0,b=this.segments,M=0;M2&&(b[parseInt(M.toString(),10)].bezierPoint1={x:0,y:0},b[parseInt(M.toString(),10)].bezierPoint2={x:0,y:0}),!z.isEmptyPoint(b[parseInt(M.toString(),10)].point1)||b[parseInt(M.toString(),10)].vector1.angle||b[parseInt(M.toString(),10)].vector1.distance?b[parseInt(M.toString(),10)].vector1.angle||b[parseInt(M.toString(),10)].vector1.distance?b[parseInt(M.toString(),10)].bezierPoint1=z.transform(h[parseInt(M.toString(),10)],b[parseInt(M.toString(),10)].vector1.angle,b[parseInt(M.toString(),10)].vector1.distance):b[parseInt(M.toString(),10)].bezierPoint1={x:b[parseInt(M.toString(),10)].point1.x||b[parseInt(M.toString(),10)].bezierPoint1.x,y:b[parseInt(M.toString(),10)].point1.y||b[parseInt(M.toString(),10)].bezierPoint1.y}:((e.sourceID||this.sourcePortID)&&this.sourceWrapper&&!v&&!g&&(S=Z3(this.sourceWrapper.bounds,h[parseInt(M.toString(),10)],!0)),b[parseInt(M.toString(),10)].bezierPoint1=qI(h[parseInt(M.toString(),10)],h[M+1],S)),!z.isEmptyPoint(b[parseInt(M.toString(),10)].point2)||b[parseInt(M.toString(),10)].vector2.angle||b[parseInt(M.toString(),10)].vector2.distance?b[parseInt(M.toString(),10)].vector2.angle||b[parseInt(M.toString(),10)].vector2.distance?b[parseInt(M.toString(),10)].bezierPoint2=z.transform(h[M+1],b[parseInt(M.toString(),10)].vector2.angle,b[parseInt(M.toString(),10)].vector2.distance):b[parseInt(M.toString(),10)].bezierPoint2={x:b[parseInt(M.toString(),10)].point2.x||b[parseInt(M.toString(),10)].bezierPoint2.x,y:b[parseInt(M.toString(),10)].point2.y||b[parseInt(M.toString(),10)].bezierPoint2.y}:((e.targetID||this.targetPortID)&&this.targetWrapper&&!v&&!g&&(S=Z3(this.targetWrapper.bounds,h[M+1],!0)),b[parseInt(M.toString(),10)].bezierPoint2=qI(h[M+1],h[parseInt(M.toString(),10)],S));h.splice(1,0,{x:b[0].bezierPoint1.x,y:b[0].bezierPoint1.y}),h.splice(h.length-1,0,{x:b[b.length-1].bezierPoint2.x,y:b[b.length-1].bezierPoint2.y}),h=this.clipDecorators(e,h,r);for(var w=0;w0&&(s=this.bridgePath(e,s,D),s+=" L"+o.x+" "+o.y);return s},t.prototype.updateShapeElement=function(e){var i;switch(e.shape.type){case"Bpmn":e.wrapper.children[3]instanceof Ke&&(i=e.wrapper.children[3]),"Message"===e.shape.flow&&this.updateShapePosition(e,i);break;case"UmlActivity":"Exception"===e.shape.flow&&this.getUMLExceptionFlow(e.wrapper.children[0])}},t.prototype.updateShapePosition=function(e,i){var o=bF(this.intermediatePoints,i,.5);i.offsetX=o.x,i.offsetY=o.y},t.prototype.scale=function(e,i,r,s,o){var a=0,l=0;if(this.wrapper&&this.wrapper.outerBounds){var h=function M3(n){var t=n.wrapper.children[0].bounds;return"None"!==n.sourceDecorator.shape&&t.uniteRect(n.wrapper.children[1].bounds),"None"!==n.targetDecorator.shape&&t.uniteRect(n.wrapper.children[2].bounds),t}(this),c=Math.abs((this.wrapper.bounds.width||this.style.strokeWidth||1)-2),d=Math.abs((this.wrapper.bounds.height||this.style.strokeWidth||1)-2);a=h.width-c,l=h.height-d,e=Math.abs((r-Math.max(a,l))/c),i=Math.abs((s-Math.max(a,l))/d),a=l=Math.min(a,l)}e=i=Math.min(e,i);var u=Hi();qi(u,-(o=o||this.wrapper).rotateAngle,o.offsetX,o.offsetY),Qp(u,e,i,o.offsetX,o.offsetY),qi(u,o.rotateAngle,o.offsetX,o.offsetY);var p=function Oie(n,t){for(var e=[],i=0,r=t;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Qne=function(n){function t(e,i){var r=n.call(this,e,i)||this;return r.offset=0,r.scale=1,r}return Yne(t,n),t.prototype.preRender=function(){this.unWireEvents(),this.wireEvents()},t.prototype.render=function(){this.updateRulerGeometry(),this.renderComplete()},t.prototype.getModuleName=function(){return"Ruler"},t.prototype.destroy=function(){this.unWireEvents(),this.notify("destroy",{}),n.prototype.destroy.call(this),this.element.classList.remove("e-ruler")},t.prototype.getPersistData=function(){return this.addOnPersist(["loaded"])},t.prototype.onPropertyChanged=function(e,i){for(var r=0,s=Object.keys(e);r100;)r/=10,s/=10;for(;s<25;)r*=10,s*=10;return s>=25&&s%25!=0&&(s=25*Math.round(s/25)),s*e/r},t.prototype.createMarkerLine=function(e,i,r){var s;return i&&((s=e.getElementById(i.id+"_marker"))&&s.parentNode.removeChild(s),s=Bi("line",r)),s},t.prototype.drawRulerMarker=function(e,i,r){var s,o,h,d,u="Horizontal"===this.orientation,p=e.getElementsByTagName("svg");for(h=0;h0)for(var a=i.childNodes.length-1;a>=0;a--)i.childNodes[parseInt(a.toString(),10)].parentNode.removeChild(i.childNodes[parseInt(a.toString(),10)]);i.appendChild(s)}return s},t.prototype.wireEvents=function(){},t.prototype.unWireEvents=function(){},kc([I(5)],t.prototype,"interval",void 0),kc([I(100)],t.prototype,"segmentWidth",void 0),kc([I("Horizontal")],t.prototype,"orientation",void 0),kc([I("RightOrBottom")],t.prototype,"tickAlignment",void 0),kc([I("red")],t.prototype,"markerColor",void 0),kc([I(25)],t.prototype,"thickness",void 0),kc([I(null)],t.prototype,"arrangeTick",void 0),kc([I(400)],t.prototype,"length",void 0),t}(yi);function eF(n,t){var e=document.getElementById(n.element.id+(t?"_hRuler":"_vRuler")),i=qa(n),r=tF(n);e||(e=Tt("div",{id:n.element.id+(t?"_hRuler":"_vRuler"),style:"height:"+(t?i.height:r.height+100)+"px;overflow:hidden;width:"+(t?r.width+100:i.width)+"px;position:absolute;font-size:11px;"+(t?"margin-left:"+i.width+"px;":"margin-top:"+i.height+"px;")})),n.element.insertBefore(e,n.element.firstChild);var l=t?n.rulerSettings.horizontalRuler:n.rulerSettings.verticalRuler,h=new Qne(l);h.orientation=t?"Horizontal":"Vertical",h.length=(t?r.width:r.height)+l.segmentWidth,h.appendTo("#"+n.element.id+(t?"_hRuler":"_vRuler")),t?n.hRuler=h:n.vRuler=h;var c=document.getElementById(n.element.id+(t?"_hRuler":"_vRuler"));t?n.hRuler.element=c:n.vRuler.element=c}function $I(n){var t=-n.scroller.horizontalOffset,e=-n.scroller.verticalOffset;n&&n.rulerSettings.showRulers?(n.hRuler.length=0,n.vRuler.length=0,void 0!==t&&n.hRuler.element&&iF(n,n.hRuler,t,!0),void 0!==e&&n.vRuler.element&&iF(n,n.vRuler,e,!1)):Gx(n)}function Gx(n){an(n.element.id+"_hRuler"),an(n.element.id+"_vRuler"),an(n.element.id+"_overlapRuler")}function qa(n){var t=0,e=0;return n.rulerSettings.showRulers&&(t=n.rulerSettings.horizontalRuler.thickness,e=n.rulerSettings.verticalRuler.thickness),new me(e,t)}function tF(n){var t=qa(n),e=n.scroller.viewPortHeight,i=n.scroller.viewPortWidth;return i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},rF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Jne(t,n),t.prototype.getClassName=function(){return"UserHandle"},Fn([I("")],t.prototype,"name",void 0),Fn([I("")],t.prototype,"pathData",void 0),Fn([I("")],t.prototype,"content",void 0),Fn([I("")],t.prototype,"source",void 0),Fn([I("#000000")],t.prototype,"backgroundColor",void 0),Fn([I("Top")],t.prototype,"side",void 0),Fn([I("")],t.prototype,"borderColor",void 0),Fn([I(.5)],t.prototype,"borderWidth",void 0),Fn([I(25)],t.prototype,"size",void 0),Fn([I("white")],t.prototype,"pathColor",void 0),Fn([I(10)],t.prototype,"displacement",void 0),Fn([I(!0)],t.prototype,"visible",void 0),Fn([I(0)],t.prototype,"offset",void 0),Fn([re({},$n)],t.prototype,"margin",void 0),Fn([I("Center")],t.prototype,"horizontalAlignment",void 0),Fn([I("Center")],t.prototype,"verticalAlignment",void 0),Fn([I(!1)],t.prototype,"disableNodes",void 0),Fn([I(!1)],t.prototype,"disableConnectors",void 0),Fn([re({},Ed)],t.prototype,"tooltip",void 0),Fn([I("")],t.prototype,"template",void 0),t}(Ee);function nF(n){return Kne[n.toString()]}var Kne={Action:"M 90 82.895 C 90 86.819 86.776 90 82.8 90 H 7.2 C 3.224 90 0 86.819 0 82.895 V 7.105 C 0 3.181 3.224 0 7.2 0 h 75.6 C 86.776 0 90 3.181 90 7.105 V 82.895 Z",Decision:"M10,19.707L0.293,10L10,0.293L19.707,10L10,19.707z",MergeNode:"M10,19.707L0.293,10L10,0.293L19.707,10L10,19.707z",InitialNode:"M10,19.5c-5.238,0-9.5-4.262-9.5-9.5S4.762,0.5,10,0.5s9.5,4.262,9.5,9.5S15.238,19.5,10,19.5z",ForkNode:"m0.75,0.75l636.00002,0l0,290l-636.00002,0l0,-290z",JoinNode:"m0.75,0.75l636.00002,0l0,290l-636.00002,0l0,-290z",TimeEvent:"M50.001,0.00286865 L25.001,25.0029 L0.000976562,0.00286865 L50.001,0.00286865 z M0.000976562,50.0029 L25.001,25.0029 L50.001,50.0029 L0.000976562,50.0029 z",AcceptingEvent:"M17.8336 32.164 L29.64 24 L17.32 16 L48.1664 16 L48.5 32 Z",SendSignal:"M48.164 31.8336 L56 23.832 L47.836 16 L16.168 16 L16.1668 31.8336 Z",ReceiveSignal:"M48.1664 31.8336 L39.836 24 L47.836 16 L16.168 16 L16.168 31.836 Z",StructuredNode:"M0,0 L50,0 L50,50 L0,50 z",Note:"M20 12 L4 12 L4 22 L22 22 L22 14 L20 14 L20 12 L22 14 Z"},ZI=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),$a=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},ese=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return ZI(t,n),$a([I()],t.prototype,"key",void 0),$a([I()],t.prototype,"keyModifiers",void 0),t}(Ee),sF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return ZI(t,n),t.prototype.getClassName=function(){return"Command"},$a([I("")],t.prototype,"name",void 0),$a([I()],t.prototype,"canExecute",void 0),$a([I()],t.prototype,"execute",void 0),$a([re({},ese)],t.prototype,"gesture",void 0),$a([I("")],t.prototype,"parameter",void 0),t}(Ee),tse=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return ZI(t,n),$a([Bt([],sF)],t.prototype,"commands",void 0),t}(Ee),ise=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return ZI(t,n),$a([I()],t.prototype,"show",void 0),$a([I()],t.prototype,"showCustomMenuOnly",void 0),$a([I()],t.prototype,"items",void 0),t}(Ee),Zp=function(){function n(){}return n.prototype.renderShadow=function(t,e,i,r){void 0===i&&(i=null);var l,o=z.transform({x:0,y:0},t.shadow.angle,t.shadow.distance);r&&(l=r.getElementById(e.id+"_shadow")),l||(l=document.createElementNS("http://www.w3.org/2000/svg",i?"path":"rect"),e.appendChild(l));var h={id:e.id+"_shadow",fill:t.shadow.color,stroke:t.shadow.color,opacity:t.shadow.opacity.toString(),transform:"rotate("+t.angle+","+(t.x+t.width*t.pivotX)+","+(t.y+t.height*t.pivotY)+")translate("+(t.x+o.x)+","+(t.y+o.y)+")"};if(r){var c=r.getElementById(e.id);c&&c.insertBefore(l,c.firstChild)}ai(l,h),i?i&&this.renderPath(l,t,i):ai(l,{width:t.width,height:t.height})},n.prototype.parseDashArray=function(t){return[]},n.prototype.drawRectangle=function(t,e,i,r,s,o,a,l,h){var c,d,u,p;e.shadow&&!r&&this.renderShadow(e,t,void 0,o),c=e.id===t.id?e.id+"_container":e.id,o&&(d=o.getElementById(c)),(!d||s)&&(d=document.createElementNS("http://www.w3.org/2000/svg","rect"),t.appendChild(d)),o&&!e.shadow&&(u=o.getElementById(e.id+"_groupElement_shadow"))&&u.parentNode.removeChild(u),p=l?{id:c,x:e.x.toString(),y:e.y.toString(),width:e.width.toString(),height:e.height.toString(),visibility:e.visible?"visible":"hidden",transform:"rotate("+e.angle+","+(e.x+e.width/2)+","+(e.y+e.height/2)+")",rx:e.cornerRadius||0,ry:e.cornerRadius||0,opacity:e.opacity}:{id:c,x:e.x.toString(),y:e.y.toString(),width:e.width.toString(),height:e.height.toString(),visibility:e.visible?"visible":"hidden",transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")",rx:e.cornerRadius||0,ry:e.cornerRadius||0,opacity:e.opacity},a&&(p.role="img",p["aria-label"]=a);var f=e.class||"";h||(f.includes("e-diagram-resize-handle")||f.includes("e-diagram-endpoint-handle")||f.includes("e-diagram-bezier-control-handle"))&&(f+=" e-disabled"),e.class&&(p.class=f),a||(p["pointer-events"]="none"),ai(d,p),this.setSvgStyle(d,e,i)},n.prototype.updateSelectionRegion=function(t,e){var i;i=t.parentNode.getElementById(e.id);var r={id:e.id,x:e.x.toString(),y:e.y.toString(),width:e.width.toString(),height:e.height.toString(),transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")",class:"e-diagram-selected-region"};i||(i=document.createElementNS("http://www.w3.org/2000/svg","rect"),t.appendChild(i)),this.setSvgStyle(i,e),ai(i,r)},n.prototype.createGElement=function(t,e){return Bi(t,e)},n.prototype.drawLine=function(t,e){var i=document.createElementNS("http://www.w3.org/2000/svg","line");this.setSvgStyle(i,e);var r=e.x+e.width*e.pivotX,s=e.y+e.height*e.pivotY,o={id:e.id,x1:e.startPoint.x+e.x,y1:e.startPoint.y+e.y,x2:e.endPoint.x+e.x,y2:e.endPoint.y+e.y,stroke:e.stroke,"stroke-width":e.strokeWidth.toString(),opacity:e.opacity.toString(),transform:"rotate("+e.angle+" "+r+" "+s+")",visibility:e.visible?"visible":"hidden"};e.class&&(o.class=e.class),ai(i,o),t.appendChild(i)},n.prototype.drawCircle=function(t,e,i,r){var s=document.createElementNS("http://www.w3.org/2000/svg","circle");this.setSvgStyle(s,e);var o=e.class||"";i||(o+=" e-disabled");var a={id:e.id,cx:e.centerX,cy:e.centerY,r:e.radius,visibility:e.visible?"visible":"hidden",class:o};r&&(a.role="img",a["aria-label"]=r),s.style.display=e.visible?"block":"none",ai(s,a),t.appendChild(s)},n.prototype.drawPath=function(t,e,i,r,s,o,a){var h,c,l=[];l=XB(l=Cd(e.data)),e.shadow&&this.renderShadow(e,t,l,s),s&&!e.shadow&&(h=s.getElementById(e.id+"_groupElement_shadow"))&&h.parentNode.removeChild(h),s&&(c=s.getElementById(e.id)),(!c||r)&&(c=document.createElementNS("http://www.w3.org/2000/svg","path"),t.appendChild(c)),this.renderPath(c,e,l);var d={};d=a?{id:e.id,transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")translate("+e.x+","+e.y+"),scale("+a+")",visibility:e.visible?"visible":"hidden",opacity:e.opacity}:{id:e.id,transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")translate("+e.x+","+e.y+")",visibility:e.visible?"visible":"hidden",opacity:e.opacity},o&&(d.role="img",d["aria-label"]=o),e.class&&(d.class=e.class),ai(c,d),this.setSvgStyle(c,e,i)},n.prototype.renderPath=function(t,e,i){var r,s,o,a,l,h,c,d,u=i,p="";for(l=0,h=0,d=0,c=u.length;de.width&&"Wrap"!==e.textOverflow&&"NoWrap"===e.textWrapping&&(h[0].text=VF(e.content,e)),v=0;vD&&(u.text=u.text.slice(0,u.text.length-3),u.text=u.text.concat("..."),l.data=u.text),this.alignText(y,p,u,l,f,g,v,e,h),C+=u.dy}}C&&e.isHorizontalLane&&(M=e.parentOffsetX+e.pivotX,w=e.parentOffsetY+e.pivotY,e.y=e.parentOffsetY-C*e.pivotY+.5),e.textDecoration&&"LineThrough"===e.textDecoration&&(e.textDecoration=db(e.textDecoration));var R={id:e.id+"_text",fill:e.color,visibility:e.visible?"visible":"hidden","text-decoration":e.textDecoration,transform:"rotate("+e.angle+","+M+","+w+")translate("+e.x+","+e.y+")",opacity:e.opacity};r&&(R.role="img",R["aria-label"]=r),ai(y,R)}},n.prototype.alignText=function(t,e,i,r,s,o,a,l,h){"justify"!==l.textAlign?this.setText(t,e,i,r,s,o,l):a!==h.length-1?this.setText(t,e,i,r,s,o,l,l.width,"spacing"):this.setText(t,e,i,r,s,o,l)},n.prototype.setText=function(t,e,i,r,s,o,a,l,h){ai(e,"justify"!==a.textAlign?{x:s.toString(),y:o.toString()}:{x:s.toString(),y:o.toString(),textLength:l||0,lengthAdjust:h||"spacing"}),t.setAttribute("fill",i.text),e.appendChild(r),t.appendChild(e)},n.prototype.drawImage=function(t,e,i,r){var s;i&&(s=i.getElementById(e.id+"image")),s||(s=document.createElementNS("http://www.w3.org/2000/svg","image"),t.appendChild(s));var o=new Image;o.src=e.source;var a="None"!==e.scale?e.scale:"",l=e.alignment,h=l.charAt(0).toLowerCase()+l.slice(1);"Stretch"!==a&&(h+=" "+a.charAt(0).toLowerCase()+a.slice(1)),ai(s,{id:e.id+"image",x:e.x.toString(),y:e.y.toString(),transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")",width:e.width.toString(),visibility:e.visible?"visible":"hidden",height:e.height.toString(),preserveAspectRatio:h,opacity:e.opacity.toString()}),s.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",o.src.toString())},n.prototype.drawHTMLContent=function(t,e,i,r,s){var o,a;if(e&&(o=e.querySelector("#"+t.id+"_html_element")),!o){(a=e.querySelector("#"+t.id+"_html_element")||e.querySelector("#"+t.nodeId+"_html_element"))||(a=Tt("div",{id:t.nodeId+"_html_element",class:"foreign-object"})),o=Tt("div",{id:t.id+"_html_element",class:"foreign-object"});var c=document.getElementById(t.diagramId).ej2_instances[0],d=!1;if(e.parentNode&&e.parentNode.parentNode&&e.parentNode.parentNode.parentNode&&e.parentNode.parentNode.parentNode.classList.contains("e-overview")&&(d=!0),d)c.isReact?c.renderReactTemplates(function(){o.appendChild(t.template.cloneNode(!0))}):o.appendChild(t.template.cloneNode(!0));else{if("string"==typeof t.template){var u=document.createElement("div");u.innerHTML=t.template,t.template=u,c.selectedItems.userHandles.filter(function(g){return g.name===t.id.split("_shape")[0]&&""!==g.template})[0].template=t.template}t.isTemplate&&t.template?o.appendChild(t.template):t.template&&o.appendChild(t.template.cloneNode(!0))}void 0!==s&&e.childNodes.length>s&&e.insertBefore(o,e.childNodes[parseInt(s.toString(),10)]),a.appendChild(o),e.appendChild(a)}var f=En(t).topLeft;o.setAttribute("style","height:"+t.actualSize.height+"px; width:"+t.actualSize.width+"px;left:"+f.x+"px; top:"+f.y+"px;position:absolute;transform:rotate("+(t.rotateAngle+t.parentTransform)+"deg);pointer-events:"+(r?"all":"none")+";visibility:"+(t.visible?"visible":"hidden")+";opacity:"+t.style.opacity+";")},n.prototype.drawNativeContent=function(t,e,i,r,s){var o,a;if(s&&(o=s.getElementById(t.id+"_native_element"),a=s.getElementById(t.id+"_clip")),!o){(o=document.createElementNS("http://www.w3.org/2000/svg","g")).setAttribute("id",t.id+"_native_element"),o.appendChild(t.template.cloneNode(!0));var l=this.createGElement("g",{id:t.id+"_inner_native_element"});l.appendChild(o),e.appendChild(l)}a&&o.removeChild(a),o.setAttribute("style","visibility:"+(t.visible?"visible":"hidden")+";opacity:"+t.style.opacity+";"),this.setNativTransform(t,o,i,r),"Slice"===t.scale&&this.drawClipPath(t,o,i,r,s),ai(o,t.description?{role:"img","aria-label":t.description}:{})},n.prototype.setNativTransform=function(t,e,i,r){var s=0!==t.contentSize.width?t.contentSize.width:1,o=0!==t.contentSize.height?t.contentSize.height:1;e.setAttribute("transform","rotate("+t.parentTransform+","+t.offsetX+","+t.offsetY+") translate("+(t.offsetX-t.templatePosition.x*r/s-r*t.pivot.x)+","+(t.offsetY-t.templatePosition.y*i/o-i*t.pivot.y)+") scale("+r/s+","+i/o+")")},n.prototype.drawClipPath=function(t,e,i,r,s){var o=t.contentSize.width,a=t.contentSize.height,l=t.width/(r/o),h=t.height/(i/a),c=t.templatePosition.x+(t.width>=t.height?0:(o-l)/2),d=t.templatePosition.y+(t.height>=t.width?0:(a-h)/2),u=s.getElementById(t.id+"_clip");(u=document.createElementNS("http://www.w3.org/2000/svg","clipPath")).setAttribute("id",t.id+"_clip"),e.appendChild(u);var p=s.getElementById(t.id+"_clip_rect");return p=document.createElementNS("http://www.w3.org/2000/svg","rect"),u.appendChild(p),ai(p,{id:t.id+"_clip_rect",width:l.toString(),height:h.toString(),x:c.toString(),y:d.toString()}),nm()?e.setAttribute("clip-path","url("+location.protocol+"//"+location.host+location.pathname+"#"+t.id+"_clip)"):e.setAttribute("clip-path","url(#"+t.id+"_clip)"),e},n.prototype.renderGradient=function(t,e,i){var r,s,o,h,c,a=yT(i),l=a.getElementById(i+"gradient_pattern");if(l||(l=Bi("defs",{id:i+"gradient_pattern"}),a.insertBefore(l,a.firstChild)),gF(e.id),"None"!==t.gradient.type){for(var d=0;dt.width&&("Ellipsis"===t.textOverflow||"Clip"===t.textOverflow)&&"NoWrap"===t.textWrapping?0:.5*t.width:"right"===t.textAlign&&(c=1*t.width),s.x=0+c+(e?e.x:0),s.y=1.2+d-r.height/2,s},n}(),Pc=function(){function n(t,e,i){this.renderer=null,this.isSvgMode=!0,this.transform={x:0,y:0},this.diagramId=t,this.element=xt(this.diagramId),this.svgRenderer=e,this.isSvgMode=i,this.renderer=i?new Zp:new bo}return n.prototype.setCursor=function(t,e){t.style.cursor=e},n.prototype.setLayers=function(){this.iconSvgLayer=this.element.getElementsByClassName("e-ports-expand-layer")[0],this.adornerSvgLayer=this.element.getElementsByClassName("e-adorner-layer")[0],this.nativeSvgLayer=this.element.getElementsByClassName("e-native-layer")[0],this.diagramSvgLayer=this.element.getElementsByClassName("e-diagram-layer")[0]},n.prototype.getAdornerLayer=function(){return vT(this.diagramId)},n.prototype.getParentSvg=function(t,e,i){return this.diagramId&&t&&t.id?t.id.split("_icon_content").length>1||t.id.split("_nodeport").length>1||t.elementActions&Xr.ElementIsPort?this.iconSvgLayer:e&&"selector"===e?this.adornerSvgLayer:t instanceof Cn?this.nativeSvgLayer:this.diagramSvgLayer:i},n.prototype.getParentElement=function(t,e,i,r){var s=e;if(i&&this.diagramId&&t&&t.id){t.id.split("_icon_content").length>1?(s=i.getElementById(this.diagramId+"_diagramExpander"),e=null):t.id.split("_nodeport").length>1?s=i.getElementById(this.diagramId+"_diagramPorts"):t instanceof Cn?(s=i.getElementById(this.diagramId+"_nativeLayer"),e=null):t.elementActions&Xr.ElementIsPort?(s=i.getElementById(this.diagramId+"_diagramPorts"),e=null):s=i.getElementById(this.diagramId+"_diagramLayer");var o=this.getGroupElement(t,e||s,r);s=o.g,o.svg&&(i=o.svg)}return{g:s,svg:i}},n.prototype.getGroupElement=function(t,e,i){var r,o,s=this.getParentSvg(t);if(e&&s){if(s&&!(r=s.getElementById(t.id+"_groupElement"))&&s!==this.nativeSvgLayer){var a=this.nativeSvgLayer;r=a.getElementById(t.id+"_groupElement"),o=a}r||(r=this.svgRenderer.createGElement("g",{id:t.id+"_groupElement"}),void 0!==i&&e.childNodes.length>i?e.insertBefore(r,e.childNodes[parseInt(i.toString(),10)]):e.appendChild(r))}return{g:r,svg:o}},n.prototype.renderElement=function(t,e,i,r,s,o,a,l,h,c,d){t instanceof Cs?(t.id=t.id?t.id:Qe(),this.renderContainer(t,e,i,r,s,o,a,l,h,c,d)):t instanceof bI?this.renderImageElement(t,e,r,s,a):t instanceof Ke?this.renderPathElement(t,e,r,s,a,h,d):t instanceof si?this.renderTextElement(t,e,r,s,a,c):t instanceof Cn?this.renderNativeElement(t,e,r,s,a):t instanceof Jn?this.renderHTMLElement(t,e,i,r,s,a,l):this.renderRect(t,e,r,s,h)},n.prototype.drawSelectionRectangle=function(t,e,i,r,s,o){var a={width:i*o.scale,height:r*o.scale,x:.5+(t=(t+o.tx)*o.scale),y:.5+(e=(e+o.ty)*o.scale),fill:"transparent",stroke:"gray",angle:0,pivotX:.5,pivotY:.5,strokeWidth:1,dashArray:"6 3",opacity:1,visible:!0,id:s.id+"_selected_region"},l=this.getAdornerLayer();this.svgRenderer.updateSelectionRegion(l,a)},n.prototype.renderHighlighter=function(t,e,i){var r=t.actualSize.width||2,s=t.actualSize.height||2,o=t.offsetX-r*t.pivot.x,a=t.offsetY-s*t.pivot.y;this.svgRenderer.drawRectangle(e,{width:r*i.scale,height:s*i.scale,x:o=(o+i.tx)*i.scale,y:a=(a+i.ty)*i.scale,fill:"transparent",stroke:"#8CC63F",angle:t.rotateAngle,pivotX:t.pivot.x,pivotY:t.pivot.y,strokeWidth:4,dashArray:"",opacity:1,cornerRadius:0,visible:!0,id:e.id+"_highlighter",class:"e-diagram-highlighter"},this.diagramId,void 0,void 0,e)},n.prototype.renderSelectionRectangle=function(t,e,i,r){var s=t.actualSize.width||2,o=t.actualSize.height||2,a=t.offsetX-s*t.pivot.x,l=t.offsetY-o*t.pivot.y,h={width:s*i.scale,height:o*i.scale,x:a=(a+i.tx)*i.scale,y:l=(l+i.ty)*i.scale,fill:"transparent",stroke:"#00cc00",angle:t.rotateAngle,pivotX:t.pivot.x,pivotY:t.pivot.y,strokeWidth:r?2:1,dashArray:"",opacity:1,cornerRadius:0,visible:!0,id:t.id+"_highlighter",class:r?"e-diagram-first-selection-indicator e-diagram-selection-indicator":"e-diagram-selection-indicator"},c=this.getParentSvg(t,"selector");this.svgRenderer.drawRectangle(e,h,this.diagramId,void 0,void 0,c)},n.prototype.renderSelectionLine=function(t,e,i,r){var s=this.getBaseAttributes(t,i);s.data=t.absolutePath,s.id=s.id+"_highlighter";var o=t.description?t.description:t.id;this.isSvgMode||(s.x=t.flipOffset.x?t.flipOffset.x:s.x,s.y=t.flipOffset.y?t.flipOffset.y:s.y),i&&(s.x=s.x*i.scale,s.y=s.y*i.scale),s.stroke="#00cc00",s.strokeWidth=r?2:1,s.class=r?"e-diagram-first-selection-indicator e-diagram-selection-indicator":"e-diagram-selection-indicator";var a=this.getParentSvg(t,"selector");this.svgRenderer.drawPath(e,s,this.diagramId,void 0,a,o,i.scale)},n.prototype.renderStackHighlighter=function(t,e,i,r,s,o,a){var l=t.actualSize.width||2,h=t.offsetX-l*t.pivot.x,c=t.actualSize.height||2,d=t.offsetY-c*t.pivot.y;h=(h+i.tx)*i.scale;var u,p=t.bounds,f="";if(d=(d+i.ty)*i.scale,r)if(o){var v,y;u="M 0 0 L "+(2+(g=l*i.scale))+" 0 Z",v=t.actualSize.width/Number(p.width?p.width:1)*i.scale,y=t.actualSize.height/Number(p.height?p.height:1)*i.scale,f=vI(mI(Cd("M7,4 L8,4 8,7 11,7 11,8 8,8 8,11 7,11 7,8 4,8 4,7 7,7 z M7.5,0.99999994C3.9160004,1 1,3.9160004 0.99999994,7.5 1,11.084 3.9160004,14 7.5,14 11.084,14 14,11.084 14,7.5 14,3.9160004 11.084,1 7.5,0.99999994 z M7.5,0 C11.636002,0 15,3.3639984 15,7.5 15,11.636002 11.636002,15 7.5,15 3.3640003,15 0,11.636002 0,7.5 0,3.3639984 3.3640003,0 7.5,0 z")),v+g+2,y-8,!1,p.x,p.y,0,0),s.y>=t.offsetY&&(d+=c)}else{var g;a&&s.y>=t.offsetY&&(d+=c*i.scale),u="M -10 -10 L 0 0 Z M -10 10 L 0 0 Z M 0 0 L "+(g=l*i.scale)+" 0 Z M "+g+" 0 L "+(g+10)+" 10 Z L "+(g+10)+" -10 Z"}else u="M 10 -10 L 0 0 Z M -10 -10 L 0 0 Z M 0 0 L 0 "+(g=c*i.scale)+" Z M 0 "+g+" L -10 "+(g+10)+" Z L 10 "+(g+10)+" Z",s.x>=t.offsetX&&(h+=l*i.scale);this.svgRenderer.drawPath(e,{data:u+f,width:l*i.scale,height:c*i.scale,x:h,y:d,fill:"transparent",stroke:"#8CC63F",angle:t.rotateAngle,pivotX:t.pivot.x,pivotY:t.pivot.y,strokeWidth:1,dashArray:"",opacity:1,visible:!0,id:e.id+"_stack_highlighter",class:"e-diagram-highlighter"},this.diagramId)},n.prototype.drawLine=function(t,e){this.svgRenderer.drawLine(t,e)},n.prototype.drawPath=function(t,e){this.svgRenderer.drawPath(t,e,this.diagramId)},n.prototype.renderResizeHandle=function(t,e,i,r,s,o,a,l,h,c,d){var u=t.offsetX-t.actualSize.width*t.pivot.x,p=t.offsetY-t.actualSize.height*t.pivot.y,f=t.actualSize.height,g=t.actualSize.width;!c&&i&bt.Rotate&&HI(this.rendererActions)&&!A3(this.rendererActions)&&(this.renderPivotLine(t,e,o,s,a),this.renderRotateThumb(t,e,o,s,a)),this.renderBorder(t,e,o,l,h,c);var v=t.actualSize.width*r,y=t.actualSize.height*r;!h&&HI(this.rendererActions)&&!A3(this.rendererActions)&&(t.isTextAnnotation||(v>=40&&y>=40&&(s&mr.ResizeNorthWest&&this.renderCircularHandle("resizeNorthWest",t,u,p,e,qr(s,"ResizeNorthWest"),i&bt.ResizeNorthWest,o,void 0,a,{"aria-label":"Thumb to resize the selected object on top left side direction"},void 0,"e-diagram-resize-handle e-northwest",d),s&mr.ResizeNorthEast&&this.renderCircularHandle("resizeNorthEast",t,u+g,p,e,qr(s,"ResizeNorthEast"),i&bt.ResizeNorthEast,o,void 0,a,{"aria-label":"Thumb to resize the selected object on top right side direction"},void 0,"e-diagram-resize-handle e-northeast",d),s&mr.ResizeSouthWest&&this.renderCircularHandle("resizeSouthWest",t,u,p+f,e,qr(s,"ResizeSouthWest"),i&bt.ResizeSouthWest,o,void 0,a,{"aria-label":"Thumb to resize the selected object on bottom left side direction"},void 0,"e-diagram-resize-handle e-southwest",d),s&mr.ResizeSouthEast&&this.renderCircularHandle("resizeSouthEast",t,u+g,p+f,e,qr(s,"ResizeSouthEast"),i&bt.ResizeSouthEast,o,void 0,a,{"aria-label":"Thumb to resize the selected object on bottom right side direction"},void 0,"e-diagram-resize-handle e-southeast",d)),s&mr.ResizeNorth&&this.renderCircularHandle("resizeNorth",t,u+g/2,p,e,qr(s,"ResizeNorth"),i&bt.ResizeNorth,o,void 0,a,{"aria-label":"Thumb to resize the selected object on top side direction"},void 0,"e-diagram-resize-handle e-north",d),s&mr.ResizeSouth&&this.renderCircularHandle("resizeSouth",t,u+g/2,p+f,e,qr(s,"ResizeSouth"),i&bt.ResizeSouth,o,void 0,a,{"aria-label":"Thumb to resize the selected object on bottom side direction"},void 0,"e-diagram-resize-handle e-south",d),s&mr.ResizeWest&&this.renderCircularHandle("resizeWest",t,u,p+f/2,e,qr(s,"ResizeWest"),i&bt.ResizeWest,o,void 0,a,{"aria-label":"Thumb to resize the selected object on left side direction"},void 0,"e-diagram-resize-handle e-west",d),s&mr.ResizeEast&&this.renderCircularHandle("resizeEast",t,u+g,p+f/2,e,qr(s,"ResizeEast"),i&bt.ResizeEast,o,void 0,a,{"aria-label":"Thumb to resize the selected object on right side direction"},void 0,"e-diagram-resize-handle e-east",d)))},n.prototype.renderEndPointHandle=function(t,e,i,r,s,o,a,l,h,c){var f,g,d=t.sourcePoint,u=t.targetPoint,p=t.wrapper;if(this.renderCircularHandle("connectorSourceThumb",p,d.x,d.y,e,qr(r,"ConnectorSourceThumb"),i&bt.ConnectorSource,s,o,void 0,{"aria-label":"Thumb to move the source point of the connector"},void 0,"e-diagram-endpoint-handle e-sourceend",c),this.renderCircularHandle("connectorTargetThumb",p,u.x,u.y,e,qr(r,"ConnectorTargetThumb"),i&bt.ConnectorTarget,s,a,void 0,{"aria-label":"Thumb to move the target point of the connector"},void 0,"e-diagram-endpoint-handle e-targetend",c),l)if("Straight"===t.type&&t.segments.length>0)for(f=0;f0)for(f=0;f=3&&3===t.segments.length&&(S=1,b=t.segments.length-1),S=t.segments.length>t.maxSegmentThumb+2?2:S,b=t.segments.length>t.maxSegmentThumb+2?t.segments.length-2:b,1===t.segments.length&&t.segments[0].points.length<=2&&(S=1,b=t.segments.length),f=S;f=50&&i.allowDrag),this.renderOrthogonalThumb(t+"_"+(d+1),e,(i.points[parseInt(d.toString(),10)].x+i.points[d+1].x)/2,(i.points[parseInt(d.toString(),10)].y+i.points[d+1].y)/2,r,h,l,o,a,u)}else for(d=0;d=50&&i.allowDrag),this.renderOrthogonalThumb(t+"_"+(d+1),e,(i.points[parseInt(d.toString(),10)].x+i.points[d+1].x)/2,(i.points[parseInt(d.toString(),10)].y+i.points[d+1].y)/2,r,h,l,o,a,u)},n.prototype.renderOrthogonalThumb=function(t,e,i,r,s,o,a,l,h,c){var d,g,u=0,p=document.getElementById(this.diagramId);p&&(g=p.ej2_instances[0]);var y=h.constraints&qe.InheritSegmentThumbShape?g.segmentThumbShape:h.segmentThumbShape,b=h.constraints&qe.InheritSegmentThumbSize?g.segmentThumbSize:h.segmentThumbSize;if(d="horizontal"===a?function rre(n){return are[""+n]}(y):n3(y),"Arrow"===y||"DoubleArrow"===y||"OpenArrow"===y)switch(c){case"Bottom":case"Right":u=180;break;default:u=0}else if("Fletch"===y||"OpenFetch"===y||"IndentedArrow"===y||"OutdentedArrow"===y)switch(c){case"Bottom":u=-90;break;case"Top":u=90;break;case"Right":u=180;break;default:u=0}var M={x:(i+l.tx)*l.scale-b/2,y:(r+l.ty)*l.scale-b/2,angle:u,fill:"#e2e2e2",stroke:"black",strokeWidth:1,dashArray:"",data:d,width:b,height:b,pivotX:.5,pivotY:.5,opacity:1,visible:o,id:t,class:"e-diagram-ortho-segment-handle"},w=of(M.data),C=new me(M.width,M.height),D=new Ke;M.data=D.updatePath(M.data,w,C),this.svgRenderer.drawPath(s,M,this.diagramId)},n.prototype.renderPivotLine=function(t,e,i,r,s){var o=t,l=!!(r&mr.Rotate);s&&(l=!1);var h=this.getBaseAttributes(o,i);h.fill="None",h.stroke="black",h.strokeWidth=1,h.dashArray="2,3",h.visible=l;var c=i.scale;h.x*=c,h.y*=c,h.width*=c,h.height*=c,h.id="pivotLine",h.class="e-diagram-pivot-line";var u={x:o.actualSize.width*o.pivot.x*c,y:0};h.startPoint={x:o.actualSize.width*o.pivot.x*c,y:-20},h.endPoint=u,this.svgRenderer.drawLine(e,h)},n.prototype.renderBezierLine=function(t,e,i,r,s,o){var l=this.getBaseAttributes(e,o);l.id=t,l.stroke="black",l.strokeWidth=1,l.dashArray="3,3",l.fill="None",l.class="e-diagram-bezier-control-line",l.x=0,l.y=0;var h=o.scale,g={x:(s.x+o.tx)*h,y:(s.y+o.ty)*h};l.startPoint={x:(r.x+o.tx)*h,y:(r.y+o.ty)*h},l.endPoint=g,this.svgRenderer.drawLine(i,l)},n.prototype.renderCircularHandle=function(t,e,i,r,s,o,a,l,h,c,d,u,p,f){var g=e,v={x:i,y:r};if(0!==g.rotateAngle||0!==g.parentTransform){var y=Hi();qi(y,g.rotateAngle+g.parentTransform,g.offsetX,g.offsetY),v=Je(y,v)}var S=this.getBaseAttributes(g);S.stroke="black",S.strokeWidth=1,void 0!==u?(S.id="segmentEnd_"+u,S.fill="#e2e2e2"):S.fill=h?"#8CC63F":"white",S.cornerRadius=f/2,S.angle=e.rotateAngle,S.id=t,S.visible=o,S.class=p,S.width=f,S.height=f,S.x=(v.x+l.tx)*l.scale,S.y=(v.y+l.ty)*l.scale,S.x=S.x-S.width/2,S.y=S.y-S.height/2,h&&(S.class+=" e-connected"),c&&(S.visible=!1);var b=this.getParentSvg(e,"selector");this.svgRenderer.drawRectangle(s,S,this.diagramId,!0,!0,b,d,!0,a)},n.prototype.renderBezierHandle=function(t,e,i,r,s,o,a,l,h,c,d,u,p){var v,f=document.getElementById(this.diagramId);f&&(v=f.ej2_instances[0]);var y=e,S={x:i,y:r};if(0!==y.rotateAngle||0!==y.parentTransform){var b=Hi();qi(b,y.rotateAngle+y.parentTransform,y.offsetX,y.offsetY),S=Je(b,S)}var D=a.constraints&qe.InheritSegmentThumbSize?v.segmentThumbSize:a.segmentThumbSize,A=n3(a.constraints&qe.InheritSegmentThumbShape?v.segmentThumbShape:a.segmentThumbShape),x=this.getBaseAttributes(y);x.stroke="black",x.strokeWidth=1,void 0!==d?(x.id="segmentEnd_"+d,x.fill="#e2e2e2"):x.fill=h?"#8CC63F":"white",x.angle=e.rotateAngle,x.id=t,x.visible=o,x.class=u,x.width=D,x.height=D,x.data=A,x.x=(S.x+l.tx)*l.scale,x.y=(S.y+l.ty)*l.scale,x.x=x.x-x.width/2,x.y=x.y-x.height/2,h&&(x.class+=" e-connected"),c&&(x.visible=!1);var R=of(x.data),L=new me(x.width,x.height),O=new Ke;x.data=O.updatePath(x.data,R,L);var N=this.getParentSvg(e,"selector");this.svgRenderer.drawPath(s,x,this.diagramId,!0,N)},n.prototype.renderBorder=function(t,e,i,r,s,o){var l=this.getBaseAttributes(t,i);l.x*=i.scale,l.y*=i.scale,l.width*=i.scale,l.height*=i.scale,l.fill="transparent",l.stroke="#097F7F",l.strokeWidth=1.2,l.gradient=null,l.dashArray="6,3",l.class="e-diagram-selector",o&&(l.class+=" e-diagram-lane"),l.id="borderRect",l.id=this.rendererActions&Qa.DrawSelectorBorder?"borderRect_symbol":"borderRect",r||(l.class+=" e-disabled"),s&&(l.class+=" e-thick-border"),l.cornerRadius=0;var h=this.getParentSvg(t,"selector");this.svgRenderer.drawRectangle(e,l,this.diagramId,void 0,!0,h)},n.prototype.renderUserHandler=function(t,e,i,r,s,o){for(var l,a=t.wrapper,h=0,c=t.userHandles;h0||d.disableNodes&&t.nodes.length>0||"Drag"===s&&o)&&(l=!1);var u=document.getElementById(d.name+"_template_hiddenUserHandle");u&&(d.template=u.childNodes[0].cloneNode(!0));var p=eT(t,d,i);if(p.x=(p.x+i.tx)*i.scale,p.y=(p.y+i.ty)*i.scale,d.visible&&(d.visible=!!(t.constraints&mr.UserHandle)),l)if(d.pathData){var f=d.pathData?d.pathData:d.content,g=this.getBaseAttributes(a);g.id=d.name+"_userhandle",g.fill=d.backgroundColor,g.stroke=d.borderColor,g.strokeWidth=d.borderWidth,g.centerX=p.x,g.centerY=p.y,g.radius=.5*d.size,g.class="e-diagram-userhandle-circle",g.angle=0,g.visible=d.visible,g.opacity=1,this.svgRenderer.drawCircle(e,g,1,{"aria-label":d.name+"user handle"});var y=[];y=mI(y=Cd(f));var S=of(f),w=vI(y,(d.size-.45*d.size)/S.width,(d.size-.45*d.size)/S.height,!0,S.x,S.y,0,0);S=of(w),this.svgRenderer.drawPath(e,C={x:p.x-S.width/2,y:p.y-S.height/2,angle:0,id:"",class:"e-diagram-userhandle-path",fill:d.pathColor,stroke:d.backgroundColor,strokeWidth:.5,dashArray:"",data:w,width:d.size-5,height:d.size-5,pivotX:0,pivotY:0,opacity:1,visible:d.visible},this.diagramId,void 0,void 0,{"aria-label":d.name+"user handle"})}else if(d.content){var D=new Cn(d.name,this.diagramId);D.content=d.content,D.offsetX=p.x,D.offsetY=p.y,D.id=d.name+"_shape",D.horizontalAlignment="Center",D.verticalAlignment="Center",D.visible=d.visible,D.setOffsetWithRespectToBounds(p.x,p.y,"Fraction"),D.relativeMode="Object",D.description=d.name||"User handle",D.measure(new me(d.size,d.size)),D.arrange(D.desiredSize),this.svgRenderer.drawNativeContent(D,e,d.size,d.size,this.adornerSvgLayer)}else if(d.source){var C,A=new bI;(C=this.getBaseAttributes(A,i)).width=d.size,C.height=d.size,C.x=p.x-d.size/2,C.y=p.y-d.size/2,C.sourceWidth=d.size,C.sourceHeight=d.size,C.alignment=A.imageAlign,C.source=d.source,C.scale=A.imageScale,C.visible=d.visible,C.description=d.name||"User handle",C.id=d.name+"_",this.renderer.drawImage(e,C,this.adornerSvgLayer,!1)}else{var x=new Jn(d.name,this.diagramId);x.offsetX=p.x,x.offsetY=p.y,x.id=d.name+"_shape",x.visible=d.visible,x.relativeMode="Object",x.template=d.template,x.measure(new me(d.size,d.size)),x.arrange(x.desiredSize),this.svgRenderer.drawHTMLContent(x,r,void 0,!0,void 0)}}},n.prototype.renderRotateThumb=function(t,e,i,r,s){new Ke;var a,l=new me;l.width=18,l.height=16;var d=!!(r&mr.Rotate);s&&(d=!1);var p=t.offsetX-t.actualSize.width*t.pivot.x+t.pivot.x*t.actualSize.width,f=t.offsetY-t.actualSize.height*t.pivot.y;if(a={x:(p=(p+i.tx)*i.scale)-.5*l.width,y:(f=(f+i.ty)*i.scale)-30-.5*l.height},0!==t.rotateAngle||0!==t.parentTransform){var g=Hi();qi(g,t.rotateAngle+t.parentTransform,(i.tx+t.offsetX)*i.scale,(i.ty+t.offsetY)*i.scale),a=Je(g,a)}this.svgRenderer.drawPath(e,{x:a.x,y:a.y,angle:t.rotateAngle+t.parentTransform,fill:"#231f20",stroke:"black",strokeWidth:.5,dashArray:"",data:"M 16.856144362449648 10.238890446662904 L 18.000144362449646 3.437890446662903L 15.811144362449646 4.254890446662903 C 14.837144362449646 2.5608904466629028 13.329144362449647 1.2598904466629026 11.485144362449645 0.5588904466629026 C 9.375144362449646 - 0.24510955333709716 7.071144362449646 - 0.18010955333709716 5.010144362449646 0.7438904466629028 C 2.942144362449646 1.6678904466629028 1.365144362449646 3.341890446662903 0.558144362449646 5.452890446662903 C - 0.244855637550354 7.567890446662903 - 0.17985563755035394 9.866890446662904 0.7431443624496461 11.930890446662904 C 1.6681443624496461 13.994890446662904 3.343144362449646 15.575890446662903 5.457144362449647 16.380890446662903 C 6.426144362449647 16.7518904466629 7.450144362449647 16.9348904466629 8.470144362449647 16.9348904466629 C 9.815144362449647 16.9348904466629 11.155144362449647 16.6178904466629 12.367144362449647 15.986890446662901 L 11.351144362449647 14.024890446662901 C 9.767144362449647 14.8468904466629 7.906144362449647 14.953890446662902 6.237144362449647 14.3178904466629 C 4.677144362449647 13.7218904466629 3.444144362449647 12.5558904466629 2.758144362449647 11.028890446662901 C 2.078144362449646 9.501890446662903 2.031144362449646 7.802890446662903 2.622144362449646 6.243890446662903 C 3.216144362449646 4.6798904466629025 4.387144362449646 3.442890446662903 5.914144362449646 2.760890446662903 C 7.437144362449646 2.078890446662903 9.137144362449646 2.0298904466629026 10.700144362449645 2.6258904466629027 C 11.946144362449646 3.100890446662903 12.971144362449646 3.9538904466629026 13.686144362449646 5.049890446662903 L 11.540144362449645 5.850890446662903 L 16.856144362449648 10.238890446662904 Z",width:20,height:20,pivotX:0,pivotY:0,opacity:1,visible:d,id:"rotateThumb",class:"e-diagram-rotate-handle"},this.diagramId,!0,void 0,{"aria-label":"Thumb to rotate the selected object"})},n.prototype.renderPathElement=function(t,e,i,r,s,o,a){var l=this.getBaseAttributes(t,i,o);if(l.data=t.absolutePath,l.data=t.absolutePath,t.isPathPort&&a){l.x=a[t.id]?a[t.id].cx:l.x,l.y=a[t.id]?a[t.id].cy:l.y,t.bounds.x=l.x,t.bounds.y=l.y;var h=document.getElementById(this.diagramId);h&&"PortDrag"!==h.ej2_instances[0].eventHandler.currentAction&&(t.offsetX=l.x+t.width/2,t.offsetY=l.y+t.height/2)}var u=t.description?t.description:t.id;if(this.isSvgMode||(l.x=t.flipOffset.x?t.flipOffset.x:l.x,l.y=t.flipOffset.y?t.flipOffset.y:l.y),t.isExport){var p=t.absoluteBounds,f=Cd(l.data),g=this.findAndStoreArcValues(f);l.arc=g,l.data=OF(t,p,0,l)}this.renderer.drawPath(e,l,this.diagramId,void 0,r,u)},n.prototype.findAndStoreArcValues=function(t){var e=[];return t.forEach(function(i){"A"===i.command&&e.push({r1:i.r1/2,r2:i.r2/2})}),e},n.prototype.renderSvgGridlines=function(t,e,i,r,s,o){var a=document.createElementNS("http://www.w3.org/2000/svg","pattern"),l=document.createElementNS("http://www.w3.org/2000/svg","defs");l.setAttribute("id",this.diagramId+"_grid_pattern_defn"),(t.constraints&Kt.ShowHorizontalLines||t.constraints&Kt.ShowVerticalLines)&&a.setAttribute("id",this.diagramId+"_pattern");var h=0,c=0,d=0,u=0,p=1,f=!1,g="Lines"===t.gridType,v=g?t.verticalGridlines.lineIntervals:t.verticalGridlines.dotIntervals,y=g?t.horizontalGridlines.lineIntervals:t.horizontalGridlines.dotIntervals;if(r.showRulers&&r.dynamicGrid&&s&&o)d=o.updateSegmentWidth(i.scale),u=s.updateSegmentWidth(i.scale),t.horizontalGridlines.scaledIntervals=[d/s.interval],t.verticalGridlines.scaledIntervals=[u/o.interval],f=!0;else{for(var S=0;S=2)for(;e>=2;)e/=2;else if(e<=.5)for(;e<=.5;)e*=2;var i;if(t.horizontalGridlines.scaledIntervals=t.horizontalGridlines.snapIntervals,t.verticalGridlines.scaledIntervals=t.verticalGridlines.snapIntervals,1!==e){var r=t.horizontalGridlines;for(r.scaledIntervals=[],i=0;ithis.groupElement.actualSize.height&&("Clip"===t.style.textOverflow||"Ellipsis"===t.style.textOverflow)&&(a.y=a.y+(a.height-this.groupElement.actualSize.height)/2),this.renderer.drawRectangle(e,a,this.diagramId,void 0,void 0,r),this.renderer.drawText(e,a,r,l,this.diagramId,t.isExport&&Math.min(t.exportScaleValue.x||t.exportScaleValue.y),this.groupElement),this.isSvgMode&&(t.doWrap=!1)},n.prototype.renderNativeElement=function(t,e,i,r,s){var o,a,l=this.getParentSvg(t,void 0,e)||r,h=this.getParentElement(t,e,l).g||e,c=this.getBaseAttributes(t,i);switch(c.fill="transparent",c.cornerRadius=t.cornerRadius,c.stroke="transparent",this.renderer.drawRectangle(e,c,this.diagramId,void 0,void 0,r),t.scale){case"None":o=t.contentSize.width,a=t.contentSize.height;break;case"Stretch":o=t.actualSize.width,a=t.actualSize.height;break;case"Meet":o=a=t.actualSize.width<=t.actualSize.height?t.actualSize.width:t.actualSize.height;break;case"Slice":o=a=t.actualSize.width>=t.actualSize.height?t.actualSize.width:t.actualSize.height}this.svgRenderer&&this.svgRenderer.drawNativeContent(t,h,a,o,l)},n.prototype.renderHTMLElement=function(t,e,i,r,s,o,a){var l=this.getBaseAttributes(t,r);l.fill="transparent",l.cornerRadius=t.cornerRadius,l.stroke="transparent",this.renderer.drawRectangle(e,l,this.diagramId,void 0,void 0,s),this.svgRenderer&&this.svgRenderer.drawHTMLContent(t,i.children[0],r,function cse(n){var t=n.parentElement;do{if(dm(t,"e-diagram"))return!0;t=t.parentElement}while(t);return!1}(i),a)},n.prototype.renderImageElement=function(t,e,i,r,s){var o=this.getBaseAttributes(t,i);o.cornerRadius=0,this.renderer.drawRectangle(e,o,this.diagramId,void 0,void 0,r);var a,l,h,c,g,d=t.contentSize.width,u=t.contentSize.height,p=o.width/d,f=o.height/u;if("Stretch"===t.stretch)a=d*(g=Math.min(p,f)),l=u*g;else switch(t.stretch){case"Meet":a=d*(g=Math.min(p,f)),l=u*g,o.x+=Math.abs(o.width-a)/2,o.y+=Math.abs(o.height-l)/2;break;case"Slice":g=Math.max(p,f),h=o.width/(a=d*g)*d,c=o.height/(l=u*g)*u;break;case"None":a=d,l=u}o.width=a,o.height=l,o.sourceWidth=h,o.sourceHeight=c,o.source=t.source,o.alignment=t.imageAlign,o.scale=t.imageScale,o.description=t.description?t.description:t.id,this.renderer.drawImage(e,o,r,s)},n.prototype.renderContainer=function(t,e,i,r,s,o,a,l,h,c,d){var g,u={svg:s,g:e},p=document.getElementById(this.diagramId);if(p&&(g=p.ej2_instances[0]),this.diagramId&&(s=this.getParentSvg(t)||s,this.isSvgMode)){var v=this.getParentElement(t,e,s,l).g||e;s=this.getParentSvg(this.hasNativeParent(t.children))||s;var y=this.getParentElement(this.hasNativeParent(t.children),v,s,l);u.svg=y.svg||s,u.g=y.g||v,o&&s&&(s.getElementById(u.g.id)||e.appendChild(u.g)),e=u.g}if(this.renderRect(t,e,r,s),this.groupElement=t,t.hasChildren()){for(var b,S=void 0,M=0,w=t.children;M0&&(D=g.selectedItems.nodes[0]);var L,A=void 0,x=void 0,R=!1;if(g&&g.selectedItems&&(L=g.getObject(t.id)),"None"!==t.flip&&(D=L),"None"===t.flip&&(D=L),D&&D.flipMode&&(R=!0),!(t.elementActions&Xr.ElementIsGroup)&&g instanceof zl&&g.nameTable[t.id]&&"connectors"!==g.nameTable[t.id].propName&&R&&D){if(A=t.children&&t.children[0]instanceof Cn?document.getElementById(D.id+"_content_inner_native_element"):document.getElementById(D.id+"_content_groupElement"),!(t.children[0]instanceof Cn)&&"Text"!==D.shape.type&&"None"!==D.flipMode&&"Label"!==D.flipMode&&"All"!==D.flipMode&&"PortAndLabel"!==D.flipMode&&"LabelText"!==D.flipMode&&"PortAndLabelText"!==D.flipMode&&"LabelAndLabelText"!==D.flipMode||t.children[0]instanceof Cn&&"Port"===D.flipMode)return void this.renderFlipElement(t,A,D.flip);if((t.children[0]instanceof Cn&&("All"===D.flipMode||"Label"===D.flipMode)||"Label"===D.flipMode||"PortAndLabel"===D.flipMode||"LabelText"===D.flipMode||"PortAndLabelText"===D.flipMode||"LabelAndLabelText"===D.flipMode||"Image"===D.shape.type&&"Label"===D.flipMode)&&this.renderFlipElement(t,A,t.flip),"None"!==t.flip&&"None"===D.flipMode)this.renderFlipElement(t,A,t.flip);else if("None"!==t.flip&&("Label"===D.flipMode||"PortAndLabel"===D.flipMode||"LabelText"===D.flipMode||"PortAndLabelText"===D.flipMode||"LabelAndLabelText"===D.flipMode)||t.children[0]instanceof Cn&&"None"!==t.flip&&D&&("None"===D.flipMode||"All"===D.flipMode)){for(var O=0;O0){var i=t[0];if(i instanceof Cn)return i;i.children&&i.children.length&&this.hasNativeParent(i.children,e++||0)}},n.prototype.renderRect=function(t,e,i,r,s){var o=this.getBaseAttributes(t,i,s);o.cornerRadius=t.cornerRadius||0,t.isExport&&(o.cornerRadius*=t.exportScaleValue.x),this.renderer.drawRectangle(e,o,this.diagramId,t.isExport,void 0,r,t.description?t.description:t.id)},n.prototype.drawRect=function(t,e){e.cornerRadius=0,this.svgRenderer.drawRectangle(t,e,this.diagramId)},n.prototype.getBaseAttributes=function(t,e,i){var r={width:t.actualSize.width,height:t.actualSize.height,x:t.offsetX-t.actualSize.width*t.pivot.x,y:t.offsetY-t.actualSize.height*t.pivot.y,fill:t.style.fill,stroke:t.style.strokeColor,angle:t.rotateAngle+t.parentTransform,pivotX:t.pivot.x,pivotY:t.pivot.y,strokeWidth:t.style.strokeWidth,dashArray:t.style.strokeDashArray||"",opacity:t.style.opacity,shadow:t.shadow,gradient:t.style.gradient,visible:t.visible,id:t.id,description:t.description,canApplyStyle:t.canApplyStyle,shapeType:t.shapeType};return"Page"===t.rotationReference&&(r.angle=t.rotateAngle),i&&(r.x=r.x-.5,r.y=r.y-.5),t.isExport&&(r.width*=t.exportScaleValue.x,r.height*=t.exportScaleValue.y,r.x*=t.exportScaleValue.x,r.y*=t.exportScaleValue.y,r.strokeWidth*=t.exportScaleValue.x),t.flip&&(r.flip=t.flip),e&&(r.x+=e.tx,r.y+=e.ty),r},n.renderSvgBackGroundImage=function(t,e,i,r,s,o){if(t.source){var l=yT(e.id).getElementById(e.id+"_image");if(!l){var h=function Soe(n){return xt(n).getElementsByClassName("e-background-image-layer")[0]}(e.id);(l=document.createElementNS("http://www.w3.org/2000/svg","image")).setAttribute("id",e.id+"_image"),h.appendChild(l)}var c=new Image;c.src=t.source,l.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",c.src.toString());var d="None"!==t.scale?t.scale:"",u=t.align,p=u.charAt(0).toLowerCase()+u.slice(1);d&&(p+=" "+d.charAt(0).toLowerCase()+d.slice(1)),ai(l,{id:e.id+"_image",x:i,y:r,width:s,height:o,preserveAspectRatio:p})}},n.prototype.transformLayers=function(t,e){var i=t.tx*t.scale,r=t.ty*t.scale,s="domTable";if(i!==this.transform.x||r!==this.transform.y||0===i||0===r){e&&(window[""+s][this.diagramId+"_diagramLayer"]||(window[""+s][this.diagramId+"_diagramLayer"]=this.diagramSvgLayer.getElementById(this.diagramId+"_diagramLayer")),window[""+s][this.diagramId+"_diagramLayer"].setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+"),scale("+t.scale+")"));var a=function Ioe(n){var t="domTable",e=null;return window[t][n+"_gridline"]?e=window[t][n+"_gridline"]:(e=Bd(n).getElementById(n+"_gridline"),window[t][n+"_gridline"]=e),e}(this.diagramId);return a.setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+")"),window[""+s][this.diagramId+"_diagramPorts"]||(window[""+s][this.diagramId+"_diagramPorts"]=this.iconSvgLayer.getElementById(this.diagramId+"_diagramPorts")),window[""+s][this.diagramId+"_diagramPorts"].setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+"),scale("+t.scale+")"),window[""+s][this.diagramId+"_diagramExpander"]||(window[""+s][this.diagramId+"_diagramExpander"]=this.iconSvgLayer.getElementById(this.diagramId+"_diagramExpander")),window[""+s][this.diagramId+"_diagramExpander"].setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+"),scale("+t.scale+")"),window[""+s][this.diagramId+"_nativeLayer"]||(window[""+s][this.diagramId+"_nativeLayer"]=this.nativeSvgLayer.getElementById(this.diagramId+"_nativeLayer")),window[""+s][this.diagramId+"_nativeLayer"].setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+"),scale("+t.scale+")"),Io(this.diagramId).children[0].style.transform="translate("+t.tx*t.scale+"px,"+t.ty*t.scale+"px)scale("+t.scale+")",this.transform={x:t.tx*t.scale,y:t.ty*t.scale},!0}return!1},n.prototype.updateNode=function(t,e,i,r,s,o,a){this.renderElement(t,e,i,r,this.getParentSvg(t),void 0,void 0,s,null,o,a)},n}(),rse=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),JI=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},oF=function(n){function t(e,i){var r=n.call(this,e,i)||this;return r.mode="Canvas",r.id="overview",r.actionName="",r.startPoint=null,r.currentPoint=null,r.prevPoint=null,r.scale=null,r.inAction=!1,r.viewPortRatio=1,r.horizontalOffset=0,r.verticalOffset=0,r.model={},r.event=!0,r.overviewid=88123,r.model={width:r.width,height:r.height},r}return rse(t,n),t.prototype.onPropertyChanged=function(e,i){for(var r=0,s=Object.keys(e);r0||e.toString().indexOf("%")>0?e.toString():e.toString()+"px"},t.prototype.renderCanvas=function(e){var i=document.getElementById(this.element.id+"_canvas");i||(i=Tt("div",{}),this.element.appendChild(i)),Ho(i,{id:this.element.id+"_canvas",class:"drawing",style:"position:relative; height:"+this.getSizeValue(this.model.height)+"; width:"+this.getSizeValue(this.model.width)+";style:-ms-touch-action: none;touch-action: none;"}),this.element.setAttribute("tabindex",String(-1)),this.element.style.overflow="hidden",this.element.style.height=String(this.model.height),this.element.style.width=String(this.model.width),this.canvas=i},t.prototype.setParent=function(e){var i=document.getElementById(e);if(this.parent){var s=this.parent;this.parent=null,s.setOverview(null,this.element.id),this.removeDocument(this)}this.parent=this.getDiagram(i,"ej2_instances"),this.parent&&this.parent.setOverview(this)},t.prototype.getDiagram=function(e,i){for(var r,s=e[""+i].length,o=0;o0?p:Math.floor(window.innerWidth)}if(0===h){var f=Math.floor(window.innerHeight-u-Math.floor(c.top));h=f>0?f:Math.floor(window.innerHeight)}l>0&&(s.setAttribute("width",String(l)),this.model.height=h),h>0&&(s.setAttribute("height",String(h)),this.model.width=l),e.diagramLayerDiv||(e.diagramLayerDiv=Tt("div",{}),e.diagramLayer=bo.createCanvas(this.element.id+"_diagramLayer",this.model.width,this.model.height),e.diagramLayer.setAttribute("style","position:absolute; left:0px; top:0px "),e.diagramLayerDiv.appendChild(e.diagramLayer),e.canvas.appendChild(e.diagramLayerDiv)),Ho(e.diagramLayerDiv,{id:this.element.id+"_diagramLayer_div",style:"width:"+this.model.width+"px; height:"+this.model.height+"px;position:absolute;top:0px;left:0px"}),this.renderHtmlLayer(e.canvas),this.renderNativeLayer(e.canvas,e),this.addOverviewRectPanel(e)},t.prototype.removeDocument=function(e){var i=document.getElementById(this.canvas.id+"_svg");this.canvas.removeChild(i);var r=document.getElementById(this.element.id+"_htmlLayer");this.canvas.removeChild(r);var s=document.getElementById(this.element.id+"_diagramLayer_div");this.canvas.removeChild(s),e.diagramLayerDiv=null,e.diagramLayer=null,window.domTable[this.id+"html_layer"]=null},t.prototype.renderHtmlLayer=function(e){var i=Tt("div",{id:this.element.id+"_htmlLayer",class:"e-html-layer",style:"pointer-events:none;position:absolute;top:0px;left:0px;"}),s=Tt("div",{id:this.element.id+"_htmlLayer_div",style:"position:absolute;top:0px;left:0px;"});return i.appendChild(s),e.appendChild(i),i},t.prototype.renderNativeLayer=function(e,i){if(!document.getElementById(this.element.id+"_nativeLayer_svg")){var r=this.parent.createSvg(this.element.id+"_nativeLayer_svg",this.model.width,this.model.height),s=Bi("g",{id:this.element.id+"_nativeLayer"});r.appendChild(s),i.diagramLayerDiv.appendChild(r),ai(r,{class:"e-native-layer"})}},t.prototype.addOverviewRectPanel=function(e){var i=document.getElementById(this.canvas.id+"_overviewsvg");i&&i.parentNode.removeChild(i),i=Bi("svg",{id:this.canvas.id+"_overviewsvg",class:"overviewsvg",version:"1.1",style:"position:absolute;left:0px;top:0px; aria-label:Specifies overview",width:this.model.width,height:this.model.height}),e.canvas.appendChild(i);var s=Bi("g",{id:this.element.id+"_overviewlayer",style:"pointer-events:none"});i.appendChild(s);var o=Bi("rect",{fill:"transparent",width:"100%",height:"100%",class:"overviewbackrect",id:this.canvas.id+"overviewbackrect"});o.setAttribute("style"," pointer-events: none; "),s.appendChild(o);var a=Bi("g",{id:this.canvas.id+"overviewhandle",style:"pointer-events:all"});s.appendChild(a);var l=Bi("rect",{id:this.canvas.id+"overviewrect",fill:"transparent"});a.appendChild(l),this.renderOverviewCorner("left",a),this.renderOverviewCorner("right",a),this.renderOverviewCorner("top",a),this.renderOverviewCorner("bottom",a),this.renderOverviewCorner("topleft",a),this.renderOverviewCorner("topright",a),this.renderOverviewCorner("bottomleft",a),this.renderOverviewCorner("bottomright",a)},t.prototype.renderOverviewCorner=function(e,i){var s,o=Bi(s="top"===e||"bottom"===e||"right"===e||"left"===e?"rect":"circle",{id:this.canvas.id+"visible"+e,class:"overview-resizer"});i.appendChild(o);var a=Bi(s,{id:this.canvas.id+e,class:"overviewresizer",fill:"transparent"});i.appendChild(a)},t.prototype.updateOverviewRectangle=function(){var e=this.currentPoint.x-this.prevPoint.x,i=this.currentPoint.y-this.prevPoint.y,r=new me;r.width=0,r.height=0;var s=0,o=0;switch(this.resizeDirection){case"left":r.width-=e,r.height-=e/this.viewPortRatio,s=e,o=e/this.viewPortRatio,o/=2;break;case"right":r.width+=e,r.height+=e/this.viewPortRatio,o=e/this.viewPortRatio,o/=-2;break;case"top":r.height-=i,r.width-=i*this.viewPortRatio,o=i,s=i*this.viewPortRatio,s/=2;break;case"bottom":r.height+=i,r.width+=i*this.viewPortRatio,s=i*this.viewPortRatio,s/=-2;break;case"topleft":Math.abs(i)>Math.abs(e)?e=i*this.viewPortRatio:i=e/this.viewPortRatio,r.width-=e,r.height-=i,s=e,o=i;break;case"topright":Math.abs(i)>Math.abs(e)?e=-i*this.viewPortRatio:i=-e/this.viewPortRatio,o=i,r.width+=e,r.height-=i;break;case"bottomleft":Math.abs(i)>Math.abs(e)?e=-i*this.viewPortRatio:i=-e/this.viewPortRatio,s=e,r.width-=e,r.height+=i;break;case"bottomright":Math.abs(i)>Math.abs(e)?e=i*this.viewPortRatio:i=e/this.viewPortRatio,r.width+=e,r.height+=i}this.updateHelper(s,o,r,void 0,void 0)},t.prototype.updateHelper=function(e,i,r,s,o){var a,l,h,u,p,d=this.element.getElementsByTagName("svg")[2].getElementById("helper");r?(a=(h=d.getBBox()).x+e,l=h.y+i,s=h.width+r.width,o=h.height+r.height):(u=this.currentPoint.x>this.startPoint.x?this.currentPoint.x-this.prevPoint.x:this.prevPoint.x-this.currentPoint.x,p=this.currentPoint.y>this.startPoint.y?this.currentPoint.y-this.prevPoint.y:this.prevPoint.y-this.currentPoint.y,Math.abs(p)>Math.abs(u)?u=this.viewPortRatio*p:p=u/this.viewPortRatio,h=d.getBBox(),a=this.startPoint.x>this.currentPoint.x?h.x-u:h.x,l=this.startPoint.y>this.currentPoint.y?h.y-p:h.y,s=h.width+u,o=h.height+p),ai(this.helper,{id:this.helper.id,x:a,y:l,width:Math.max(0,s),height:Math.max(0,o)})},t.prototype.updateOverviewrect=function(e,i,r,s){Ho(document.getElementById(this.canvas.id+"overviewrect"),{x:e,y:i,width:Math.max(1,r),height:Math.max(1,s)}),this.updateOverviewCorner("top",e+8,i+1,Math.max(0,r-16),2),this.updateOverviewCorner("bottom",e+8,i+s+3,Math.max(0,r-16),2),this.updateOverviewCorner("left",e-2,i+11,2,Math.max(0,s-16)),this.updateOverviewCorner("right",e+r,i+11,2,Math.max(0,s-16)),this.updateOverviewCorner("topleft",e,i+3,5,5),this.updateOverviewCorner("topright",e+r,i+3,5,5),this.updateOverviewCorner("bottomleft",e,i+s+3,5,5),this.updateOverviewCorner("bottomright",e+r,i+s+3,5,5)},t.prototype.updateOverviewCorner=function(e,i,r,s,o){var a,l;"top"===e||"bottom"===e||"right"===e||"left"===e?(a={x:i,y:r,width:s,height:o,fill:"#ED1C24"},l={x:i-2,y:r-2,width:2===s?4:s,height:2===o?4:o}):(a={cx:i,cy:r,r:4,fill:"#ED1C24"},l={cx:i,cy:r,r:6,fill:"transparent"}),Ho(document.getElementById(this.canvas.id+"visible"+e),a),Ho(document.getElementById(this.canvas.id+e),l)},t.prototype.translateOverviewRectangle=function(){Number(this.model.width),Number(this.model.height);var r=this.currentPoint.x-this.prevPoint.x,s=this.currentPoint.y-this.prevPoint.y,l=this.element.getElementsByClassName("overviewsvg")[0].getElementById(this.canvas.id+"overviewrect").getBBox(),h=l.x+r,c=l.y+s,d=l.width,u=l.height;this.updateOverviewrect(h,c,d,u),this.updateParentView(this.parent.scroller.currentZoom,h,c,d,u,null)},t.prototype.renderOverviewRect=function(e,i,r,s){var o=Number(this.model.width),a=Number(this.model.height),c=Math.max(this.parent.scroller.viewPortWidth/(r/o*this.contentWidth),this.parent.scroller.viewPortHeight/(s/a*this.contentHeight));if(c>=.25&&c<=30){this.updateParentView(c,e,i,r,s,{x:0,y:0});var u=this.scrollOverviewRect(this.parent.scroller.horizontalOffset,this.parent.scroller.verticalOffset,this.parent.scroller.currentZoom,!0);if(this.helper){var f=this.element.getElementsByTagName("rect")[10].getBBox();u.x=f.x,u.y=f.y}"pan"===this.actionName?this.updateOverviewrect(-u.x,-u.y,u.width,u.height):this.updateOverviewrect(u.x,u.y,u.width,u.height)}},t.prototype.scrollOverviewRect=function(e,i,r,s){if(!this.actionName||s){var o=Number(this.model.width),a=Number(this.model.height),l=Math.min(this.contentWidth/o,this.contentHeight/a),h=new Ne,c=h.x=e/r/l,d=h.y=i/r/l,u=0;this.parent.rulerSettings.showRulers&&(u=25);var p=document.getElementById(this.parent.element.id+"content"),f=0,g=0;p&&(f=p.offsetWidth-p.clientWidth,g=p.offsetHeight-p.clientHeight);var v=h.width=(this.parent.scroller.viewPortWidth-u-f)/r/l,y=h.height=(this.parent.scroller.viewPortHeight-u-g)/r/l;if(s){var S=new Ne;return S.x=c,S.y=d,S.width=v,S.height=y,S}this.updateOverviewrect(-c,-d,v,y)}return null},t.prototype.updateParentView=function(e,i,r,s,o,a){var f,g,l=Number(this.model.width),h=Number(this.model.height),u=i*(this.contentWidth/l)*e,p=r*(this.contentHeight/h)*e;this.parent.scroller.getPageBounds(),(1!==e||"pan"===this.actionName)&&(f=-u-this.parent.scroller.horizontalOffset,g=-p-this.parent.scroller.verticalOffset),this.parent.setBlazorDiagramProps(!0),this.parent.realActions|=$i.OverViewAction,"scale"===this.actionName||"draw"===this.actionName?this.parent.scroller.zoom(e/this.parent.scroller.currentZoom,f,g,a):ce()?this.parent.scroller.zoom(1,f,g,a):this.parent.pan(f,g,a,!0)},t.prototype.updateHtmlLayer=function(e){var i=Io(e.element.id),r=this.parent.scroller.getPageBounds(!0),o=r.height,a=Math.max(r.width,this.parent.scroller.viewPortWidth),l=Math.max(o,this.parent.scroller.viewPortHeight/this.parent.scroller.currentZoom),h=Math.min(Number(this.model.width)/a,Number(this.model.height)/l);i.style.transform="scale("+h+") translate("+this.parent.scroller.transform.tx+"px,"+this.parent.scroller.transform.ty+"px)"},t.prototype.updateView=function(e){var i=this.parent.scroller.getPageBounds(),r=i.width,s=i.height,o=Number(this.model.width),a=Number(this.model.height),l=Math.max(r,this.parent.scroller.viewPortWidth),h=Math.max(s,this.parent.scroller.viewPortHeight);this.contentWidth=l=Math.max(l,o/a*h),this.contentHeight=h=Math.max(h,a/o*l);var c=Math.min(o/l,a/h),d=document.getElementById(this.element.id+"_htmlLayer");d.style.webkitTransform="scale("+c+") translate("+-i.x+"px,"+-i.y+"px)",d.style.transform="scale("+c+") translate("+-i.x+"px,"+-i.y+"px)",document.getElementById(this.element.id+"_overviewlayer").setAttribute("transform","translate("+-i.x*c+","+-i.y*c+")"),this.horizontalOffset=i.x*c,this.verticalOffset=i.y*c;var p=document.getElementById(this.element.id+"_diagramLayer"),f=zF(this.element.id),g=p.getContext("2d"),v=Number(this.model.width)/this.contentWidth,y=Number(this.model.height)/this.contentHeight;v=Math.min(v,y);var S=this.parent.scroller.transform;f.setAttribute("transform","translate("+S.tx*v+","+S.ty*y+"),scale("+v+")"),g.setTransform(v,0,0,v,0,0),g.fillStyle="red",this.scrollOverviewRect(this.parent.scroller.horizontalOffset,this.parent.scroller.verticalOffset,this.parent.scroller.currentZoom)},t.prototype.scrolled=function(e){if(this.event){var i=this.scrollOverviewRect(this.parent.scroller.horizontalOffset,this.parent.scroller.verticalOffset,this.parent.scroller.currentZoom,!0);this.updateOverviewrect(-i.x,-i.y,i.width,i.height),this.updateView(this)}},t.prototype.updateCursor=function(e){if(dm(e.target,"overviewresizer"))switch(e.target.id){case this.canvas.id+"left":this.canvas.style.cursor="w-resize";break;case this.canvas.id+"right":this.canvas.style.cursor="e-resize";break;case this.canvas.id+"top":this.canvas.style.cursor="n-resize";break;case this.canvas.id+"bottom":this.canvas.style.cursor="s-resize";break;case this.canvas.id+"topleft":this.canvas.style.cursor="nw-resize";break;case this.canvas.id+"topright":this.canvas.style.cursor="ne-resize";break;case this.canvas.id+"bottomleft":this.canvas.style.cursor="sw-resize";break;case this.canvas.id+"bottomright":this.canvas.style.cursor="se-resize"}else this.canvas.style.cursor="default"},t.prototype.mouseMove=function(e){if(this.event=!1,this.updateCursor(e),this.currentPoint=this.mousePosition(e),this.actionName)switch(this.actionName){case"draw":!this.inAction&&(this.startPoint.x!==this.currentPoint.x||this.startPoint.y!==this.currentPoint.y)&&(this.initHelper(),this.inAction=!0),this.inAction&&this.updateHelper();break;case"scale":this.inAction||(this.initHelper(),this.inAction=!0),this.updateOverviewRectangle();break;case"pan":(this.startPoint.x!==this.currentPoint.x||this.startPoint.y===this.currentPoint.y||this.inAction)&&(this.inAction=!0,this.translateOverviewRectangle())}this.prevPoint=this.currentPoint},t.prototype.documentMouseUp=function(e){this.inAction=!1,this.actionName="",this.helper&&(this.helper.parentNode.removeChild(this.helper),this.helper=null),this.event=!0,document.getElementById(this.canvas.id+"overviewhandle").style.pointerEvents="all"},t.prototype.windowResize=function(e){var i=this;return this.resizeTo&&clearTimeout(this.resizeTo),this.resizeTo=setTimeout(function(){var s=document.getElementById(i.element.id).getBoundingClientRect();i.model.width=s.width>0?s.width:i.model.width,i.model.height=s.height>0?s.height:i.model.height,i.renderCanvas(),i.setParent(i.sourceID)},10),!1},t.prototype.mouseDown=function(e){if(e.target.id===this.canvas.id+"_overviewsvg"&&(this.actionName="draw"),e.target.id===this.canvas.id+"overviewrect"&&(this.actionName="pan"),dm(e.target,"overviewresizer"))switch(this.actionName="scale",e.target.id){case this.canvas.id+"left":this.resizeDirection="left";break;case this.canvas.id+"right":this.resizeDirection="right";break;case this.canvas.id+"top":this.resizeDirection="top";break;case this.canvas.id+"bottom":this.resizeDirection="bottom";break;case this.canvas.id+"topleft":this.resizeDirection="topleft";break;case this.canvas.id+"topright":this.resizeDirection="topright";break;case this.canvas.id+"bottomleft":this.resizeDirection="bottomleft";break;case this.canvas.id+"bottomright":this.resizeDirection="bottomright"}this.startPoint=this.prevPoint=this.mousePosition(e),this.viewPortRatio=this.parent.scroller.viewPortWidth/this.parent.scroller.viewPortHeight,document.getElementById(this.canvas.id+"overviewhandle").style.pointerEvents="none"},t.prototype.mouseUp=function(e){if(this.currentPoint=this.mousePosition(e),this.actionName)if(this.startPoint.x!==this.currentPoint.x||this.startPoint.y!==this.currentPoint.y){if("pan"!==this.actionName&&this.helper){var i=this.element.getElementsByTagName("rect")[10].getBBox();this.resizeDirection=this.resizeDirection||"",this.renderOverviewRect(i.x,i.y,o=i.width,a=i.height)}}else if(e.target.id===this.canvas.id+"_overviewsvg"||"helper"===e.target.id){var o=(i=this.element.getElementsByTagName("svg")[2].getElementById(this.canvas.id+"overviewrect").getBBox()).width,a=i.height;this.inAction=!0,this.actionName="pan",this.renderOverviewRect(this.currentPoint.x-o/2,this.currentPoint.y-a/2,o,a),this.inAction=!1}this.helper&&(this.helper.parentNode.removeChild(this.helper),this.helper=null),this.actionName="",this.startPoint=null,this.currentPoint=null,this.prevPoint=null,this.helper=null,this.viewPortRatio=1,this.resizeDirection="",this.inAction=!1,this.event=!0,document.getElementById(this.canvas.id+"overviewhandle").style.pointerEvents="all"},t.prototype.initHelper=function(){var e=this.element.getElementsByTagName("svg")[2],i=this.startPoint.x,r=this.startPoint.y,s=1,o=1;if("scale"===this.actionName){var l=e.getElementById(this.canvas.id+"overviewrect").getBBox();i=l.x,r=l.y,s=l.width,o=l.height}var h=Bi("rect",{id:"helper",x:i,y:r,width:s,height:o,fill:"transparent",stroke:"gray","stroke-dasharray":"2 2","shape-rendering":"crispEdges"});e.getElementById(this.element.id+"_overviewlayer").appendChild(h),this.helper=h},t.prototype.mousePosition=function(e){var i,r,s;-1!==e.type.indexOf("touch")?(r=(i=e).changedTouches[0].clientX-this.element.offsetLeft,s=i.changedTouches[0].clientY-this.element.offsetTop):(r=e.clientX,s=e.clientY);var l=this.element.getBoundingClientRect();return{x:(r-=l.left)+this.horizontalOffset,y:(s-=l.top)+this.verticalOffset}},t.prototype.destroy=function(){if(this.unWireEvents(),this.notify("destroy",{}),n.prototype.destroy.call(this),document.getElementById(this.element.id)){this.element.classList.remove("e-overview");var e=document.getElementById(this.element.id+"_canvas");e&&this.element.removeChild(e)}this.parent.views.splice(this.parent.views.indexOf(this.element.id),1),this.diagramLayerDiv=null,this.canvas=null,this.parent=null},t.prototype.getModuleName=function(){return"Overview"},JI([I("100%")],t.prototype,"width",void 0),JI([I("100%")],t.prototype,"height",void 0),JI([I("")],t.prototype,"sourceID",void 0),JI([H()],t.prototype,"created",void 0),t}(yi);function sse(n,t){for(var e=0;ez.findLength(e,n)?e:t;var o=z.findAngle(t,e),a=z.findAngle(i,n),l=z.findLength(i,n),h=a+2*(o-a);return{x:i.x+l*Math.cos(h*Math.PI/180),y:i.y+l*Math.sin(h*Math.PI/180)}}function Jp(n,t,e){if(n&&n.children&&n.children.length>0)for(var r=void 0,s=0;s0&&"annotations"!==r&&"ports"!==r)if(n[""+l].length>0)for(var h=0;h<=n[""+l].length;h++)Ro(n[""+l],t?t[""+l]:void 0,e[""+l],"annotations"===l||"ports"===l?n:void 0,l);else Ro(n[""+l],t?t[""+l]:void 0,e[""+l],"annotations"===l||"ports"===l?n:void 0,l);else if(s instanceof Object&&t&&"annotations"!==r&&"ports"!==r)Ro(n[""+l],t[""+l],e[""+l]);else if("annotations"!==r&&"ports"!==r&&t&&!t[""+l]||!t&&n&&(n[""+l]||void 0!==n[""+l]))n[""+l]=e[""+l];else{var c=void 0;("annotations"===r||"ports"===r)&&("annotations"===r?(n[""+l]&&Ro(n[""+l],t[""+l],e[""+l]),n[""+l]||(fs(i)===de?(c=new Nr(i,"annotations",e[""+l]),i.annotations.push(c)):(c=new Zn(i,"annotations",e[""+l]),i.annotations.push(c)))):n[""+l]?Ro(n[""+l],t[""+l],e[""+l]):(c=new Es(i,"ports",e[""+l]),i.ports.push(c)))}}}function use(n,t){for(var e="Bezier"===n.type?function hse(n){var t=[];if("Bezier"===n.type)for(var e=0,i=0;i0||n.ports.length>0){var p=n.wrapper.children;for(i=3;i0)return{enabled:!1,intersectPt:e};var l=o/s,h=a/s;return l>=0&&l<=1&&h>=0&&h<=1?(e.x=i.x1+l*(i.x2-i.x1),e.y=i.y1+l*(i.y2-i.y1),{enabled:!0,intersectPt:e}):{enabled:!1,intersectPt:e}}function eb(n,t,e,i){var a=em(cF(n.x,n.y,t.x,t.y),cF(e.x,e.y,i.x,i.y));return a.enabled?a.intersectPt:{x:0,y:0}}function cF(n,t,e,i){return{x1:Number(n)||0,y1:Number(t)||0,x2:Number(e)||0,y2:Number(i)||0}}function dF(n,t,e){var i=[],s={x:t.topRight.x+(e=e||0),y:t.topRight.y},o={x:t.bottomRight.x,y:t.bottomRight.y-e},a={x:t.bottomLeft.x,y:t.bottomLeft.y+e};return i.push({x:t.topLeft.x-e,y:t.topLeft.y}),i.push(s),i.push(o),i.push(a),i}function zc(n,t,e,i,r,s){var o={},a=e.scroller.transform.scale,h=e.scroller.verticalOffset;return o.x=(i?n.x:t.x)*a+e.scroller.horizontalOffset-r,o.y=(i?n.y:t.y)*a+h-s,o}function uF(n,t){var e=new Ke;return e.data=n.pathData,e.height=n.height>10?n.height-(n.padding.bottom+n.padding.top):n.height,e.width=n.width>10?n.width-(n.padding.left+n.padding.right):n.width,e.visible=n.visibility,e.id=t.id+"_shape",e.inversedAlignment=!1,e.horizontalAlignment="Center",e.verticalAlignment="Center",e.style={fill:n.iconStrokeColor,strokeColor:n.iconStrokeColor,strokeWidth:n.iconStrokeWidth},e.setOffsetWithRespectToBounds(.5,.5,"Fraction"),e.relativeMode="Object",e.description=t.description||"",e}function qx(n,t,e){var i=$x(n,t),r=z.findAngle(n[i.index],n[i.index+1]),s=function Sse(n){var t;t=n instanceof xI?0:void 0===n.content?10:0;var e=0;switch(n.alignment){case"Center":e=0;break;case"Before":e=-(0+t);break;case"After":e=0+t}return e}(t),o=z.transform(i.point,r+45,s);return i.point=o,i.angle=r,i}function $x(n,t){for(var r,s,a,l,e=0,i=t.offset,o=[],h=0;h=c)return s=z.findAngle(n[parseInt(d.toString(),10)],n[d+1]),{point:r=z.transform(n[parseInt(d.toString(),10)],s,c-(a||0)),index:l=d};a=o[parseInt(d.toString(),10)]}return{point:r,index:l}}function pF(n,t,e){t%=360;var a,l,s=225;switch(n.alignment){case"Before":t>=45&&t<=135?(l="right",a=.5===n.offset?"center":"top"):t>=s&&t<=315?(l="left",a=.5===n.offset?"center":"bottom"):t>45&&t=45&&t<=135?(l="left",a=.5===n.offset?"center":"top"):t>=s&&t<=315?(l="right",a=.5===n.offset?"center":"bottom"):t>45&&tMath.abs(t.y-n.y)?n.x0)for(var e=0;e=0;r--)("nodes"===i||"connectors"===i)&&(n[""+i][parseInt(r.toString(),10)].wrapper=null),"dataManager"!==i&&(n[""+i][parseInt(r.toString(),10)]=Kx(n[""+i][parseInt(r.toString(),10)],e[""+i][parseInt(r.toString(),10)],void 0!==t[""+i]?t[""+i][parseInt(r.toString(),10)]:[]),("[]"===JSON.stringify(n[""+i][parseInt(r.toString(),10)])||"{}"===JSON.stringify(n[""+i][parseInt(r.toString(),10)])||void 0===n[""+i][parseInt(r.toString(),10)])&&n[""+i].splice(r,1));n=void 0}function Ph(n,t){var e=t.style,i=t;t.canApplyStyle=!0;for(var r=0,s=Object.keys(n);r=0&&n.splice(e,1)}function Kp(n,t,e){var i;n.intermediatePoints=t,n.updateSegmentElement(n,t,n.wrapper.children[0],e);var r=n.sourceDecorator;if("Bezier"===n.type){var s=n.segments[0],o=n.segments[n.segments.length-1];i=[z.isEmptyPoint(o.point2)?o.bezierPoint2:o.point2,z.isEmptyPoint(s.point1)?s.bezierPoint1:s.point1]}else i=n.intermediatePoints;t=n.clipDecorators(n,t,e);var a=n.wrapper.children[0];a.canMeasurePath=!0,n.updateDecoratorElement(a=n.wrapper.children[1],t[0],i[1],r),n.updateDecoratorElement(a=n.wrapper.children[2],t[t.length-1],i[i.length-2],n.targetDecorator),n.updateShapeElement(n)}function eT(n,t,e){var l,i=n.wrapper,s=t.offset,o=t.size/e.scale,a=t.margin,h=i.offsetX-i.actualSize.width*i.pivot.x,c=i.offsetY-i.actualSize.height*i.pivot.y;if(l={x:0,y:0},n.nodes.length>0){switch(t.side){case"Top":l.x+=h+s*i.actualSize.width,l.y+=c-o;break;case"Bottom":l.x+=h+s*i.actualSize.width,l.y+=c+i.actualSize.height+o;break;case"Left":l.x+=h-o,l.y+=c+s*i.actualSize.height;break;case"Right":l.x+=h+i.actualSize.width+o,l.y+=c+s*i.actualSize.height}l.x+=(a.left-a.right)/e.scale+o/2*("Center"===t.horizontalAlignment?0:"Right"===t.horizontalAlignment?-1:1),l.y+=(a.top-a.bottom)/e.scale+o/2*("Center"===t.verticalAlignment?0:"Top"===t.verticalAlignment?-1:1)}else if(n.connectors.length>0){var d=n.connectors[0],u={offset:s},p=$x(d.intermediatePoints,u),f=p.index;l=p.point;var y,v=qx(d.intermediatePoints,u).angle;qi(y=Hi(),-v,d.intermediatePoints[parseInt(f.toString(),10)].x,d.intermediatePoints[parseInt(f.toString(),10)].y),(l=Je(y,l)).x+=a.left-a.right+o/2*("Center"===t.horizontalAlignment?0:"Right"===t.horizontalAlignment?-1:1),l.y+=a.top-a.bottom+o/2*("Center"===t.verticalAlignment?0:"Top"===t.verticalAlignment?-1:1),qi(y=Hi(),v,d.intermediatePoints[parseInt(f.toString(),10)].x,d.intermediatePoints[parseInt(f.toString(),10)].y),l=Je(y,l)}return 0===i.rotateAngle&&0===i.parentTransform||(qi(y=Hi(),i.rotateAngle+i.parentTransform,i.offsetX,i.offsetY),l=Je(y,l)),l}function fa(n,t,e,i){if(i.annotation){if(Ol(i.annotation))return!0}else if(mr[""+t]&n&&bt[""+t]&e)return!0;return!1}function qr(n,t){return!!(mr[""+t]&n)}function Hc(n,t){return!!(Mx[""+t]&n)}function ga(n,t){return n.visibility&t}function tb(n,t){var e;if("Text"===n.shape.type)e=n.shape;else{var i=t.split("_");t=i[i.length-1];for(var r=0;rn[""+t]?e.splice(0,0,n):e.push(n);else if(e.length>1){for(var i=0,r=e.length-1,s=Math.floor((i+r)/2);s!==i;)if(e[parseInt(s.toString(),10)][""+t]n[""+t]))break;r=s,s=Math.floor((i+r)/2)}e[parseInt(r.toString(),10)][""+t]n[""+t]?e.splice(i,0,n):e[parseInt(i.toString(),10)][""+t]n[""+t]&&e.splice(r,0,n)}}function Hse(n){var t=document.getElementById(n.diagramId),e="ej2_instances",i=t[""+e][0].nodes;void 0===i&&(i=function Bse(n){for(var t=[],e=0;e30?10:o/2;for(var h=0,c=0;c=l){var u=l-h;r=Gt(n[c],n[c+1]),s=z.transform(n[c],r,u);break}h+=d}return s},nb=function(n,t){if(n instanceof te||n instanceof de)for(var e=0;e=0||navigator.platform.indexOf("iPad")>=0||navigator.platform.indexOf("iPhone")>=0||navigator.platform.indexOf("MacIntel")>=0)&&("safari"===X.info.name||"webkit"===X.info.name)}function wF(n,t,e,i){return void 0!==t.previewSize[""+i]?t.previewSize[""+i]:void 0!==n.symbolPreview[""+i]?n.symbolPreview[""+i]:t[""+i]||e.actualSize[""+i]}function sm(n,t,e){return n&&n.parentId&&(e=(n=t.nameTable[n.parentId]).parentId?sm(n,t,e):n.id),e}function om(n,t){return n.selectedItems.connectors.length>1&&0===n.selectedItems.nodes.length&&0!==t.rotateAngle}function jse(n){if(n.arrowType&&""!==n.arrowType.trim())switch(n.arrowType){case"single-line-arrow":default:return{targetDecorator:"Arrow",strokeWidth:1};case"double-line-arrow":return{targetDecorator:"Arrow",strokeWidth:2};case"dotted-arrow":return{targetDecorator:"Arrow",strokeDashArray:"2,2"};case"single-line":return{targetDecorator:"None",strokeWidth:1};case"double-line":return{targetDecorator:"None",strokeWidth:2};case"dotted":return{targetDecorator:"None",strokeDashArray:"2,2"};case"wiggly-arrow":return{targetDecorator:"None",strokeWidth:1,opacity:0}}return{targetDecorator:"Arrow",strokeWidth:1}}var Vse=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),io=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},CF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Vse(t,n),io([I("None")],t.prototype,"shape",void 0),io([I("white")],t.prototype,"fill",void 0),io([I("Auto")],t.prototype,"horizontalAlignment",void 0),io([I("Auto")],t.prototype,"verticalAlignment",void 0),io([I(10)],t.prototype,"width",void 0),io([I(10)],t.prototype,"height",void 0),io([re({x:.5,y:1},z)],t.prototype,"offset",void 0),io([I("#1a1a1a")],t.prototype,"borderColor",void 0),io([I(1)],t.prototype,"borderWidth",void 0),io([re({},$n)],t.prototype,"margin",void 0),io([I("")],t.prototype,"pathData",void 0),io([I("")],t.prototype,"content",void 0),io([I(0)],t.prototype,"cornerRadius",void 0),io([re({left:2,right:2,top:2,bottom:2},$n)],t.prototype,"padding",void 0),io([I("#1a1a1a")],t.prototype,"iconColor",void 0),t}(Ee),Wse=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),nT=function(n){function t(){var e=null!==n&&n.apply(this,arguments)||this;return e.orientation="Vertical",e.measureChildren=void 0,e.considerPadding=!0,e}return Wse(t,n),t.prototype.measure=function(e){return this.desiredSize=this.measureStackPanel(e,"Horizontal"===this.orientation?this.updateHorizontalStack:this.updateVerticalStack),this.desiredSize},t.prototype.arrange=function(e){return this.actualSize=this.arrangeStackPanel(e,"Horizontal"===this.orientation?this.arrangeHorizontalStack:this.arrangeVerticalStack),this.updateBounds(),this.actualSize},t.prototype.measureStackPanel=function(e,i){var r=void 0;if(void 0!==this.children&&this.children.length>0)for(var s=0,o=this.children;s0){var r=void 0,s=void 0;r=this.offsetX-e.width*this.pivot.x+this.padding.left,s=this.offsetY-e.height*this.pivot.y+this.padding.top;for(var o=0,a=this.children;o0)for(var i=0,r=this.children;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Jse=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Zse(t,n),zh([I("Horizontal")],t.prototype,"orientation",void 0),zh([I("Center")],t.prototype,"type",void 0),zh([I(void 0)],t.prototype,"offset",void 0),zh([I(!1)],t.prototype,"enableRouting",void 0),zh([I([])],t.prototype,"children",void 0),zh([I("")],t.prototype,"assistants",void 0),zh([I("")],t.prototype,"level",void 0),zh([I("")],t.prototype,"hasSubTree",void 0),zh([I("")],t.prototype,"rows",void 0),t}(Ee),Li=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),q=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Kse=function(n){if(n)switch(n.type){case"Basic":default:return sb;case"Flow":return TF;case"Path":return EF;case"Image":return xF;case"Text":return Pd;case"Bpmn":return cT;case"Native":return am;case"HTML":return DF;case"UmlActivity":return AF;case"UmlClassifier":return LF;case"SwimLane":return Hd}return sb},va=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),q([I("Basic")],t.prototype,"type",void 0),t}(Ee),EF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"Path"},q([I("Path")],t.prototype,"type",void 0),q([I("")],t.prototype,"data",void 0),t}(va),am=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"Native"},q([I("Native")],t.prototype,"type",void 0),q([I("")],t.prototype,"content",void 0),q([I("Stretch")],t.prototype,"scale",void 0),t}(va),DF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"Html"},q([I("HTML")],t.prototype,"type",void 0),q([I("")],t.prototype,"content",void 0),t}(va),xF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"Image"},q([I("Image")],t.prototype,"type",void 0),q([I("")],t.prototype,"source",void 0),q([I("None")],t.prototype,"scale",void 0),q([I("None")],t.prototype,"align",void 0),t}(va),Pd=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"Text"},q([I("Text")],t.prototype,"type",void 0),q([I("")],t.prototype,"content",void 0),q([re({},$n)],t.prototype,"margin",void 0),t}(va),sb=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"BasicShape"},q([I("Basic")],t.prototype,"type",void 0),q([I("Rectangle")],t.prototype,"shape",void 0),q([I(0)],t.prototype,"cornerRadius",void 0),q([Bt([],z)],t.prototype,"points",void 0),t}(va),TF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"FlowShape"},q([I("Flow")],t.prototype,"type",void 0),q([I("Terminator")],t.prototype,"shape",void 0),t}(va),oT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"BpmnGateway"},q([I("None")],t.prototype,"type",void 0),t}(Ee),aT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"BpmnDataObject"},q([I("None")],t.prototype,"type",void 0),q([I(!1)],t.prototype,"collection",void 0),t}(Ee),eoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),q([I("None")],t.prototype,"type",void 0),q([I("None")],t.prototype,"loop",void 0),q([I(!1)],t.prototype,"call",void 0),q([I(!1)],t.prototype,"compensation",void 0),t}(Ee),lT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"BpmnEvent"},q([I("Start")],t.prototype,"event",void 0),q([I("None")],t.prototype,"trigger",void 0),t}(Ee),zd=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"BpmnSubEvent"},q([I("None")],t.prototype,"trigger",void 0),q([I("Start")],t.prototype,"event",void 0),q([I("")],t.prototype,"id",void 0),q([re({},z)],t.prototype,"offset",void 0),q([Bt([],Zn)],t.prototype,"annotations",void 0),q([Bt([],Es)],t.prototype,"ports",void 0),q([I()],t.prototype,"width",void 0),q([I()],t.prototype,"height",void 0),q([re({},$n)],t.prototype,"margin",void 0),q([I("Center")],t.prototype,"horizontalAlignment",void 0),q([I("Center")],t.prototype,"verticalAlignment",void 0),q([I(!0)],t.prototype,"visible",void 0),t}(Ee),toe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),q([re({id:"success",event:"End",offset:{x:1,y:.5}},zd)],t.prototype,"success",void 0),q([re({id:"failure",event:"Intermediate",trigger:"Error",offset:{x:.25,y:1}},zd)],t.prototype,"failure",void 0),q([re({id:"cancel",event:"Intermediate",trigger:"Cancel",offset:{x:.75,y:1}},zd)],t.prototype,"cancel",void 0),t}(Ee),ioe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),q([I("None")],t.prototype,"type",void 0),q([I(!1)],t.prototype,"adhoc",void 0),q([I("Default")],t.prototype,"boundary",void 0),q([I(!1)],t.prototype,"compensation",void 0),q([I("None")],t.prototype,"loop",void 0),q([I(!0)],t.prototype,"collapsed",void 0),q([Bt([],zd)],t.prototype,"events",void 0),q([re({},toe)],t.prototype,"transaction",void 0),q([I(void 0)],t.prototype,"processes",void 0),t}(Ee),hT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"BpmnActivity"},q([I("Task")],t.prototype,"activity",void 0),q([re({},eoe)],t.prototype,"task",void 0),q([re({},ioe)],t.prototype,"subProcess",void 0),t}(Ee),lm=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return Li(t,n),t.prototype.getClassName=function(){return"BpmnAnnotation"},q([I("")],t.prototype,"text",void 0),q([I("")],t.prototype,"id",void 0),q([I(0)],t.prototype,"angle",void 0),q([I()],t.prototype,"height",void 0),q([I()],t.prototype,"width",void 0),q([I(0)],t.prototype,"length",void 0),t}(Ee),roe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),q([I("")],t.prototype,"textAnnotationTarget",void 0),q([I("Auto")],t.prototype,"textAnnotationDirection",void 0),t}(Ee),cT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"BpmnShape"},q([I("Bpmn")],t.prototype,"type",void 0),q([I("Event")],t.prototype,"shape",void 0),q([re({},lT)],t.prototype,"event",void 0),q([re({},oT)],t.prototype,"gateway",void 0),q([re({},aT)],t.prototype,"dataObject",void 0),q([re({},hT)],t.prototype,"activity",void 0),q([re({},lm)],t.prototype,"annotation",void 0),q([Bt([],lm)],t.prototype,"annotations",void 0),q([re({},roe)],t.prototype,"textAnnotation",void 0),t}(va),AF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"UmlActivityShape"},q([I("UmlActivity")],t.prototype,"type",void 0),q([I("Action")],t.prototype,"shape",void 0),t}(va),dT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"MethodArguments"},q([I("")],t.prototype,"name",void 0),q([I("")],t.prototype,"type",void 0),q([re({},Gp)],t.prototype,"style",void 0),t}(Ee),sf=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"UmlClassAttribute"},q([I("Public")],t.prototype,"scope",void 0),q([I(!1)],t.prototype,"isSeparator",void 0),q([re({fill:"#F9F9F9",strokeColor:"#CCCCCC"},Al)],t.prototype,"separatorStyle",void 0),t}(dT),hm=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"UmlClassMethod"},q([Bt([],dT)],t.prototype,"parameters",void 0),t}(sf),ob=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"UmlClass"},q([I("")],t.prototype,"name",void 0),q([Bt([],sf)],t.prototype,"attributes",void 0),q([Bt([],hm)],t.prototype,"methods",void 0),q([re({},Gp)],t.prototype,"style",void 0),t}(Ee),uT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"UmlInterface"},q([I(!1)],t.prototype,"isSeparator",void 0),q([re({fill:"#F9F9F9",strokeColor:"#CCCCCC"},Al)],t.prototype,"separatorStyle",void 0),t}(ob),ab=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"UmlEnumerationMember"},q([I("")],t.prototype,"name",void 0),q([I("")],t.prototype,"value",void 0),q([I(!1)],t.prototype,"isSeparator",void 0),q([re({fill:"#F9F9F9",strokeColor:"#CCCCCC"},Al)],t.prototype,"separatorStyle",void 0),q([re({},Gp)],t.prototype,"style",void 0),t}(Ee),pT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"UmlEnumeration"},q([I("")],t.prototype,"name",void 0),q([Bt([],ab)],t.prototype,"members",void 0),q([re({},Gp)],t.prototype,"style",void 0),t}(Ee),LF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"UmlClassifierShape"},q([I("UmlClassifier")],t.prototype,"type",void 0),q([re({},ob)],t.prototype,"classShape",void 0),q([re({},uT)],t.prototype,"interfaceShape",void 0),q([re({},pT)],t.prototype,"enumerationShape",void 0),q([I("Class")],t.prototype,"classifier",void 0),t}(va),te=function(n){function t(e,i,r,s){var a,o=n.call(this,e,i,r,s)||this;return o.isCanvasUpdate=!1,o.status="None",o.parentId="",o.processId="",o.umlIndex=-1,o.outEdges=[],o.inEdges=[],o.isHeader=!1,o.isLane=!1,o.isPhase=!1,o.children&&o.children.length>0&&((!(a=r).style||!a.style.fill)&&(o.style.fill="transparent"),(!a.style||!a.style.strokeColor)&&(o.style.strokeColor="transparent")),o.shape&&"UmlActivity"===o.shape.type&&KI(r,o),o.shape&&"SwimLane"===o.shape.type&&aF(r,o),o.ports&&o.ports.length&&function ase(n){for(var t=0;t>";t=n;break;case"FinalNode":t=fF(e)}return t}(new Ke,i,this);break;case"Bpmn":if(e.bpmnModule){i=e.bpmnModule.initBPMNContent(i,this,e),this.wrapper.elementActions=this.wrapper.elementActions|Xr.ElementIsGroup;var v=this.shape.activity.subProcess;if(v.processes&&v.processes.length)for(var S=0,b=this.shape.activity.subProcess.processes;S>",margin:{left:10,right:10},id:"class",style:{fontSize:i.style.fontSize,color:i.style.color,fill:i.style.fill,textWrapping:r},offset:{x:.5,y:.3},constraints:Lr.ReadOnly}],constraints:(ie.Default|ie.HideThumbs)&~(ie.Rotate|ie.Drag|ie.Resize),verticalAlignment:"Stretch",horizontalAlignment:"Stretch",style:{fill:t.style.fill,strokeColor:"black"===t.style.strokeColor?"#ffffff00":t.style.strokeColor}},!0);return e.initObject(s),e.nodes.push(s),e.UpdateBlazorDiagramModel(s,"Node"),t.children.push(s.id),function Qse(n,t,e,i){if("Enumeration"===n.shape.classifier){var r=e.members;if(r&&r.length){rf(n,t);for(var s="",o=0;o0)for(var o=0;o0&&s.phaseSize&&(i+=s.phaseSize,Gv(n,s.phaseSize)),s.lanes.length>0)for(o=0;o0){var a=0;for(o=0;o0&&"Horizontal"===r.orientation)for(l=0;l0&&(i+=r.phaseSize,o=Xv(r.phaseSize),n.push(o)),a=0;a0&&o.phaseSize){for(var l=0;l0)for(l=0;l0?e.nameTable[this.nodes[0].id].wrapper:e.nameTable[this.connectors[0].id].wrapper,this.annotation.id);i.children.push(s)}else if(this.nodes||this.connectors){for(var o=0;o-1}function HF(n,t,e){n=[];for(var i=0,r=e.length;i0?c.getElementsByTagName("svg")[0].outerHTML:c.getElementsByTagName("g").length>0?c.getElementsByTagName("g")[0].outerHTML:"",s.shape.content=h,n.content=h,c.parentElement.removeChild(c)}l="nodeTemplate"}else a=s,l="annotationTemplate";var f=document.getElementById(n.diagramId).ej2_instances[0];if("string"!=typeof n.content&&"function"!=typeof n.content||n.isTemplate)if(n.isTemplate){if(v=void 0,v=f.isReact?n.getNodeTemplate()($(e),f,l+"_"+("nodeTemplate"===l?e.id:n.nodeId+e.id),void 0,void 0,!1,i):f.isVue||f.isVue3?n.getNodeTemplate()?n.getNodeTemplate()($(e),f,l+"_"+("nodeTemplate"===l?e.id:n.nodeId+e.id),void 0,void 0,!1,i):(v=ri("nodeTemplate"===l?f.nodeTemplate:f.annotationTemplate))($(e),f,l+"_"+("nodeTemplate"===l?e.id:n.nodeId+e.id),void 0,void 0,!1,i):n.getNodeTemplate()($(e),f,l+"_"+("nodeTemplate"===l?e.id:n.nodeId+e.id),void 0,void 0,!1))for(var M=0;M=1&&0===n.x&&("Clip"===i.textOverflow||"Ellipsis"===i.textOverflow)&&("Wrap"===i.textWrapping||"WrapWithOverflow"===i.textWrapping)&&(n.x=t[e-1]?t[e-1].x:-n.width/2),n.x}function _F(n,t,e,i){return e&&!t.template||t.template&&"function"==typeof t.template&&i.isReact?(n.isTemplate=!0,n.template=n.content=Rh(n,!0,t)):n.content=t.template,n}function Qe(){for(var e,t="",i=0;i<5;i++){if(typeof window<"u"&&"crypto"in window&&"getRandomValues"in crypto){var r=new Uint16Array(1);e=(window.msCrypto||window.crypto).getRandomValues(r)[0]%60}else e=Math.floor(61*Math.random());0===i&&e<10?i--:t+="0123456789ABCDEFGHIJKLMNOPQRSTUVWXTZabcdefghiklmnopqrstuvwxyz".substring(e,e+1)}return t}function UF(n){if(n)try{return"function"!=typeof n&&document.querySelectorAll(n).length?ri(document.querySelector(n).innerHTML.trim()):ri(n)}catch{return ri(n)}}function En(n){new Ne;var e=n.offsetY-n.actualSize.height*n.pivot.y,i=n.offsetY+n.actualSize.height*(1-n.pivot.y),r=n.offsetX-n.actualSize.width*n.pivot.x,s=n.offsetX+n.actualSize.width*(1-n.pivot.x);return Ne.toBounds([{x:r,y:e},{x:s,y:e},{x:r,y:i},{x:s,y:i}])}function yr(n){var t=new Ne,e=En(n),i=e.middleLeft,r=e.topCenter,s=e.bottomCenter,o=e.middleRight,a=e.topLeft,l=e.topRight,h=e.bottomLeft,c=e.bottomRight;if(n.corners={topLeft:a,topCenter:r,topRight:l,middleLeft:i,middleRight:o,bottomLeft:h,bottomCenter:s,bottomRight:c},0!==n.rotateAngle||0!==n.parentTransform){var d=Hi();qi(d,n.rotateAngle+n.parentTransform,n.offsetX,n.offsetY),n.corners.topLeft=a=Je(d,a),n.corners.topCenter=r=Je(d,r),n.corners.topRight=l=Je(d,l),n.corners.middleLeft=i=Je(d,i),n.corners.middleRight=o=Je(d,o),n.corners.bottomLeft=h=Je(d,h),n.corners.bottomCenter=s=Je(d,s),n.corners.bottomRight=c=Je(d,c)}return t=Ne.toBounds([a,l,h,c]),n.corners.left=t.left,n.corners.right=t.right,n.corners.top=t.top,n.corners.bottom=t.bottom,n.corners.center=t.center,n.corners.width=t.width,n.corners.height=t.height,t}function $(n,t,e,i){var r={},s="properties";if(n){e=n.propName;var l=[],h=[];if((l=l.concat(Object.keys(n[""+s]||n))).push("version"),e){var c=Zi(t);h=c?c(e):[],l=l.concat(h)}for(var d=function woe(n){switch(n){case"nodes":case"children":return["inEdges","outEdges","parentId","processId","nodeId","umlIndex","isPhase","isLane"];case"connectors":return["parentId"];case"annotation":case"annotations":return["nodeId"];case"shape":return["hasHeader"];case"layers":return["objectZIndex"]}return[]}(e),u=0,p=l=l.concat(d);u0&&(e=r),r=Math.floor(Eoe(e,i)),s=Bc(o+=n.substr(e,r),t)}while(s<=t.width);for(o=o.substr(0,e),a=e;a=t.width){n=n.substr(0,o.length-1);break}return"Ellipsis"===t.textOverflow?(n=n.substr(0,n.length-3),n+="..."):n=n.substr(0,n.length),n}function IT(n,t){if("NoWrap"===t&&"PreserveAll"===n)return"pre";var e="";switch(n){case"CollapseAll":e="nowrap";break;case"CollapseSpace":e="pre-line";break;case"PreserveAll":e="pre-wrap"}return e}function bT(n,t){var e=Hi();qi(e,t,0,0);var i=Je(e,{x:0,y:0}),r=Je(e,{x:n.width,y:0}),s=Je(e,{x:0,y:n.height}),o=Je(e,{x:n.width,y:n.height}),a=Math.min(i.x,r.x,s.x,o.x),l=Math.min(i.y,r.y,s.y,o.y),h=Math.max(i.x,r.x,s.x,o.x),c=Math.max(i.y,r.y,s.y,o.y);return new me(h-a,c-l)}function xs(n,t,e,i){if(0!==n){var r=Hi();return qi(r,n,t,e),Je(r,i)}return i}function Zi(n){return void 0!==n&&"string"==typeof n&&(n=Y(n,window)),n}var bo=function(){function n(){}return n.getContext=function(t){return t.getContext("2d")},n.setCanvasSize=function(t,e,i){t&&(t.setAttribute("width",e.toString()),t.setAttribute("height",i.toString()))},n.prototype.renderGradient=function(t,e,i,r){var s,o,a;if("None"!==t.gradient.type){for(var l=0;l0?(w=0===S.r1?e.arc[parseInt(r.toString(),10)].r1:S.r1,C=0===S.r2?e.arc[parseInt(r.toString(),10)].r2:S.r2,r++):(w=S.r1,C=S.r2);var D=S.angle*(Math.PI/180),A=S.largeArc,x=S.sweep,R={x:u,y:p},L={x:Math.cos(D)*(M.x-R.x)/2+Math.sin(D)*(M.y-R.y)/2,y:-Math.sin(D)*(M.x-R.x)/2+Math.cos(D)*(M.y-R.y)/2},O=Math.pow(L.x,2)/Math.pow(w,2)+Math.pow(L.y,2)/Math.pow(C,2);O>1&&(w*=Math.sqrt(O),C*=Math.sqrt(O));var N=Math.pow(C,2)*Math.pow(L.x,2),T=(A===x?-1:1)*Math.sqrt((Math.pow(w,2)*Math.pow(C,2)-Math.pow(w,2)*Math.pow(L.y,2)-N)/(Math.pow(w,2)*Math.pow(L.y,2)+Math.pow(C,2)*Math.pow(L.x,2)));isNaN(T)&&(T=0);var P={x:T*w*L.y/C,y:T*-C*L.x/w},_={x:(M.x+R.x)/2+Math.cos(D)*P.x-Math.sin(D)*P.y,y:(M.y+R.y)/2+Math.sin(D)*P.x+Math.cos(D)*P.y},B=this.a([1,0],[(L.x-P.x)/w,(L.y-P.y)/C]),j=[(L.x-P.x)/w,(L.y-P.y)/C],Q=[(-L.x-P.x)/w,(-L.y-P.y)/C],oe=this.a(j,Q);this.r(j,Q)<=-1&&(oe=Math.PI),this.r(j,Q)>=1&&(oe=0);var pe=B+oe/2*(x?1:-1);if(Math.cos(pe),Math.sin(pe),S.centp=_,S.xAxisRotation=D,S.rx=w,S.ry=C,S.a1=B,S.ad=oe,S.sweep=x,null!=s){var De=w>C?w:C,xe=w>C?1:w/C,Ie=w>C?C/w:1;s.save(),s.translate(_.x,_.y),s.rotate(D),s.scale(xe,Ie),s.arc(0,0,De,B,B+oe,!x),s.scale(1/xe,1/Ie),s.rotate(-D),s.translate(-_.x,-_.y),s.restore()}break;case"Z":case"z":s.closePath(),u=o,p=a}o=u,a=p}}},n.prototype.drawText=function(t,e,i,r,s,o,a){if(e.content&&!0===e.visible){var l=n.getContext(t);l.save(),this.setStyle(t,e),o&&(e.fontSize*=o),this.rotateContext(t,e.angle,e.x+e.width*e.pivotX,e.y+e.height*e.pivotY),this.setFontStyle(t,e);var u,d=0;u=e.childNodes;var p=e.wrapBounds;if(l.fillStyle=e.color,p){var f=this.labelAlign(e,p,u);for(d=0;de.width&&"Wrap"!==e.textOverflow&&"NoWrap"===e.textWrapping&&(g.text=VF(g.text,e)),"Clip"!==e.textOverflow&&"Ellipsis"!==e.textOverflow||"Wrap"!==e.textWrapping?l.fillText(g.text,v,y):ya.actualSize.height+a.bounds.y&&(g.text=g.text.slice(0,g.text.length-3),g.text=g.text.concat("...")),l.fillText(g.text,v,y)),"Underline"===e.textDecoration||"Overline"===e.textDecoration||"LineThrough"===e.textDecoration){var M=v,w=void 0,D=v+l.measureText(g.text).width,A=void 0;switch(e.textDecoration){case"Underline":w=y+2,A=y+2;break;case"Overline":w=f.y+g.dy*d,A=f.y+g.dy*d;break;case"LineThrough":w=(y+f.y+g.dy*d)/2+2,A=(y+f.y+g.dy*d)/2+2}l.beginPath(),l.moveTo(M,w),l.lineTo(D,A),l.strokeStyle=e.color,l.lineWidth=.08*e.fontSize,l.globalAlpha=e.opacity,l.stroke()}}}l.restore()}},n.prototype.loadImage=function(t,e,i,r,s){this.rotateContext(i,e.angle,r,s);var o=new Image;o.src=e.source,this.image(t,o,e.x,e.y,e.width,e.height,e)},n.prototype.drawImage=function(t,e,i,r){var s=this;if(e.visible){var o=n.getContext(t);o.save();var a=e.x+e.width*e.pivotX,l=e.y+e.height*e.pivotY,h=new Image;h.src=e.source,o.canvas.id.split("_"),r?h.onload=function(){s.loadImage(o,e,t,a,l)}:this.loadImage(o,e,t,a,l),o.restore()}},n.prototype.image=function(t,e,i,r,s,o,a){t.beginPath();var l=e.width,h=e.height,c=s,d=o,u=0,p=0;if(a&&"None"!==a.alignment){var f=a.alignment.toLowerCase().substr(1,3),g=a.alignment.toLowerCase().substr(5,3);if("Slice"===a.scale){var v=function(){u=c,p=h*c/l},y=function(){u=l*d/h,p=d};c>d?(v(),d>p&&y()):c===d?l>h?y():v():(y(),c>u&&v());var S=this.getSliceOffset(f,u,c,l),b=this.getSliceOffset(g,p,d,h),M=l-S,w=h-b,C=u-S*(u/l),D=p-b*(p/h),A=Tt("canvas",{width:s.toString(),height:o.toString()});A.getContext("2d").drawImage(e,S,b,M,w,0,0,C,D),t.drawImage(A,i,r,s,o)}else if("Meet"===a.scale){var R=h/l,L=d/c;p=L>R?c*R:d,i+=this.getMeetOffset(f,u=L>R?c:d/R,c),r+=this.getMeetOffset(g,p,d),t.drawImage(e,0,0,l,h,i,r,u,p)}else t.drawImage(e,i,r,s,o)}else if("None"!==a.flip){var O=1,N=1;("Horizontal"===a.flip||"Both"===a.flip)&&(i=-i,s=-s,O=-1),("Vertical"===a.flip||"Both"===a.flip)&&(r=-r,o=-o,N=-1),t.scale(O,N),t.drawImage(e,i,r,s,o)}else t.drawImage(e,i,r,s,o);t.closePath()},n.prototype.getSliceOffset=function(t,e,i,r){switch(t){case"min":default:return 0;case"mid":return(e-i)/2*r/e;case"max":return(e-i)*r/e}},n.prototype.getMeetOffset=function(t,e,i){var r=Math.max(e,i),s=Math.min(e,i);switch(t){case"min":default:return 0;case"mid":return(r-s)/2;case"max":return r-s}},n.prototype.m=function(t){return Math.sqrt(Math.pow(t[0],2)+Math.pow(t[1],2))},n.prototype.r=function(t,e){return(t[0]*e[0]+t[1]*e[1])/(this.m(t)*this.m(e))},n.prototype.a=function(t,e){return(t[0]*e[1]t.width&&("Ellipsis"===t.textOverflow||"Clip"===t.textOverflow)&&"NoWrap"===t.textWrapping?0:.5*t.width:"right"===t.textAlign&&(c=1*t.width),s.x=t.x+c+(e?e.x:0),s.y=a+d-r.height/2,s},n}(),ub=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Vi=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},xoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return ub(t,n),Vi([I("")],t.prototype,"source",void 0),Vi([I("transparent")],t.prototype,"color",void 0),Vi([I("None")],t.prototype,"scale",void 0),Vi([I("None")],t.prototype,"align",void 0),t}(Ee),Toe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return ub(t,n),Vi([I("Page")],t.prototype,"mode",void 0),Vi([I("PageSettings")],t.prototype,"region",void 0),Vi([re({top:25,bottom:25,left:25,right:25},$n)],t.prototype,"margin",void 0),Vi([I(!1)],t.prototype,"canZoomIn",void 0),Vi([I(void 0)],t.prototype,"customBounds",void 0),Vi([I(!1)],t.prototype,"canFit",void 0),t}(Ee),Aoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return ub(t,n),Vi([I(null)],t.prototype,"width",void 0),Vi([I(null)],t.prototype,"height",void 0),Vi([re({},$n)],t.prototype,"margin",void 0),Vi([I("Landscape")],t.prototype,"orientation",void 0),Vi([I("Infinity")],t.prototype,"boundaryConstraints",void 0),Vi([re({},xoe)],t.prototype,"background",void 0),Vi([I(!1)],t.prototype,"multiplePage",void 0),Vi([I(!1)],t.prototype,"showPageBreaks",void 0),Vi([re({},Toe)],t.prototype,"fitOptions",void 0),t}(Ee),Loe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return ub(t,n),Vi([I(0)],t.prototype,"horizontalOffset",void 0),Vi([I(0)],t.prototype,"verticalOffset",void 0),Vi([I(1)],t.prototype,"currentZoom",void 0),Vi([I(0)],t.prototype,"viewPortWidth",void 0),Vi([I(0)],t.prototype,"viewPortHeight",void 0),Vi([I(.2)],t.prototype,"minZoom",void 0),Vi([I(30)],t.prototype,"maxZoom",void 0),Vi([I("Diagram")],t.prototype,"scrollLimit",void 0),Vi([I()],t.prototype,"scrollableArea",void 0),Vi([I(!1)],t.prototype,"canAutoScroll",void 0),Vi([I(100)],t.prototype,"autoScrollFrequency",void 0),Vi([re({left:15,right:15,top:15,bottom:15},$n)],t.prototype,"autoScrollBorder",void 0),Vi([re({left:0,right:0,top:0,bottom:0},$n)],t.prototype,"padding",void 0),Vi([I(.2)],t.prototype,"zoomFactor",void 0),t}(Ee),Noe=function(){function n(){this.services={}}return n.prototype.register=function(t,e){this.services[""+t]=e},n.prototype.getService=function(t){return this.services[""+t]},n}(),WF=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),ma=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},YF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return WF(t,n),ma([I("lightgray")],t.prototype,"lineColor",void 0),ma([I("")],t.prototype,"lineDashArray",void 0),ma([I([1.25,18.75,.25,19.75,.25,19.75,.25,19.75,.25,19.75])],t.prototype,"lineIntervals",void 0),ma([I([1,19,.5,19.5,.5,19.5,.5,19.5,.5,19.5])],t.prototype,"dotIntervals",void 0),ma([I([20])],t.prototype,"snapIntervals",void 0),t}(Ee),Ooe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return WF(t,n),ma([re({},YF)],t.prototype,"horizontalGridlines",void 0),ma([re({},YF)],t.prototype,"verticalGridlines",void 0),ma([I(Kt.All)],t.prototype,"constraints",void 0),ma([I(5)],t.prototype,"snapAngle",void 0),ma([I("Lines")],t.prototype,"gridType",void 0),ma([I(5)],t.prototype,"snapObjectDistance",void 0),ma([I("#07EDE1")],t.prototype,"snapLineColor",void 0),t}(Ee),QF=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Ja=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},GF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return QF(t,n),Ja([I(5)],t.prototype,"interval",void 0),Ja([I(100)],t.prototype,"segmentWidth",void 0),Ja([I("Horizontal")],t.prototype,"orientation",void 0),Ja([I("RightOrBottom")],t.prototype,"tickAlignment",void 0),Ja([I("red")],t.prototype,"markerColor",void 0),Ja([I(25)],t.prototype,"thickness",void 0),Ja([I(null)],t.prototype,"arrangeTick",void 0),t}(Ee),koe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return QF(t,n),Ja([I(!1)],t.prototype,"showRulers",void 0),Ja([I(!0)],t.prototype,"dynamicGrid",void 0),Ja([re({orientation:"Horizontal"},GF)],t.prototype,"horizontalRuler",void 0),Ja([re({orientation:"Vertical"},GF)],t.prototype,"verticalRuler",void 0),t}(Ee),Poe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),XF=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},zoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Poe(t,n),XF([I("")],t.prototype,"property",void 0),XF([I("")],t.prototype,"field",void 0),t}(Ee),MT=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),ln=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},qF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return MT(t,n),ln([I("")],t.prototype,"read",void 0),ln([I("")],t.prototype,"create",void 0),ln([I("")],t.prototype,"update",void 0),ln([I("")],t.prototype,"destroy",void 0),ln([I()],t.prototype,"customFields",void 0),t}(Ee),Roe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return MT(t,n),ln([I("")],t.prototype,"id",void 0),ln([I("")],t.prototype,"sourceID",void 0),ln([I("")],t.prototype,"targetID",void 0),ln([I(null)],t.prototype,"sourcePointX",void 0),ln([I(null)],t.prototype,"sourcePointY",void 0),ln([I(null)],t.prototype,"targetPointX",void 0),ln([I(null)],t.prototype,"targetPointY",void 0),ln([I(null)],t.prototype,"dataManager",void 0),ln([re({},qF)],t.prototype,"crudAction",void 0),t}(Ee),Hoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return MT(t,n),ln([I("")],t.prototype,"id",void 0),ln([I(null)],t.prototype,"dataManager",void 0),ln([I(null)],t.prototype,"dataSource",void 0),ln([I("")],t.prototype,"root",void 0),ln([I("")],t.prototype,"parentId",void 0),ln([I()],t.prototype,"doBinding",void 0),ln([Bt([],zoe)],t.prototype,"dataMapSettings",void 0),ln([re({},qF)],t.prototype,"crudAction",void 0),ln([re({},Roe)],t.prototype,"connectionDataSource",void 0),t}(Ee),$F=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Cr=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Boe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return $F(t,n),Cr([I("LeftInFlow")],t.prototype,"yesBranchDirection",void 0),Cr([I("RightInFlow")],t.prototype,"noBranchDirection",void 0),Cr([I(["Yes","True"])],t.prototype,"yesBranchValues",void 0),Cr([I(["No","False"])],t.prototype,"noBranchValues",void 0),t}(Ee),Foe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return $F(t,n),Cr([I("")],t.prototype,"fixedNode",void 0),Cr([I(30)],t.prototype,"horizontalSpacing",void 0),Cr([I("SamePoint")],t.prototype,"connectionPointOrigin",void 0),Cr([I("Nonlinear")],t.prototype,"arrangement",void 0),Cr([I(30)],t.prototype,"verticalSpacing",void 0),Cr([I(30)],t.prototype,"maxIteration",void 0),Cr([I(40)],t.prototype,"springFactor",void 0),Cr([I(50)],t.prototype,"springLength",void 0),Cr([re({left:50,top:50,right:0,bottom:0},$n)],t.prototype,"margin",void 0),Cr([I("Auto")],t.prototype,"horizontalAlignment",void 0),Cr([I("Auto")],t.prototype,"verticalAlignment",void 0),Cr([I("TopToBottom")],t.prototype,"orientation",void 0),Cr([I("Auto")],t.prototype,"connectionDirection",void 0),Cr([I("Default")],t.prototype,"connectorSegments",void 0),Cr([I("None")],t.prototype,"type",void 0),Cr([I()],t.prototype,"getLayoutInfo",void 0),Cr([I()],t.prototype,"layoutInfo",void 0),Cr([I()],t.prototype,"getBranch",void 0),Cr([I()],t.prototype,"bounds",void 0),Cr([I(!0)],t.prototype,"enableAnimation",void 0),Cr([I(!1)],t.prototype,"enableRouting",void 0),Cr([I("")],t.prototype,"root",void 0),Cr([re({},Boe)],t.prototype,"flowchartLayoutSettings",void 0),t}(Ee),_oe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),ZF=function(n){function t(e,i){var r=n.call(this,e,!0)||this;return r.oldValue=null,r.endPoint=i,r}return _oe(t,n),t.prototype.mouseDown=function(e){var i,r=!0;if(e.source&&e.source.connectors&&(i=e.source.connectors[0]),e.info&&e.actualObject&&(r=e.info.ctrlKey&&"Orthogonal"!==e.actualObject.type),i&&r){this.inAction=!0,this.undoElement=$(e.source),n.prototype.mouseDown.call(this,e);for(var s=0;s0)1!==s&&this.removePrevSegment(i,s);else if(a){var l=z.distancePoints(a.points[0],a.points[1]);Math.abs(a.length||0===a.length?a.length:l)<=5&&this.removeNextSegment(i,s)}this.commandHandler.updateEndPoint(i,r),i.selectedSegmentIndex=0}if(this.undoElement){var c=$(e.source);this.commandHandler.addHistoryEntry({type:"SegmentChanged",redoObject:c,undoObject:this.undoElement,category:"Internal"})}if(i.isBezierEditing&&(i.isBezierEditing=!1),this.prevPosition!==this.startPosition){var u={source:i,state:"Completed",oldValue:this.oldValue,newValue:$(this.selectedSegment),cancel:!1,segment:this.selectedSegment};this.commandHandler.triggerEvent(Ce.segmentChange,u)}n.prototype.mouseUp.call(this,e)},t.prototype.removePrevSegment=function(e,i){var r=e.segments[i-2],s=e.segments[i+1];if(s&&!((s.length||0===s.length?s.length:z.distancePoints(s.points[0],s.points[1]))<=5)){var a=e.segments.slice(i-1,i+1),l={element:e,removeSegments:a,type:"Removal",cancel:!1};if(this.commandHandler.triggerEvent(Ce.segmentCollectionChange,l),!l.cancel){var h=e.segments[i+1];e.segments.splice(i-1,2);var c=this.selectedSegment;"Left"===c.direction||"Right"===c.direction?(r.points[r.points.length-1].x=h.points[0].x,h.points[0].y=r.points[r.points.length-1].y):(r.points[r.points.length-1].y=h.points[0].y,h.points[0].x=r.points[r.points.length-1].x),(c.length||0===c.length)&&this.findSegmentDirection(r),this.findSegmentDirection(h)}}},t.prototype.findSegmentDirection=function(e){e.direction&&(e.length||0===e.length)&&(e.length=z.distancePoints(e.points[0],e.points[e.points.length-1]),e.direction=z.direction(e.points[0],e.points[e.points.length-1]))},t.prototype.removeNextSegment=function(e,i){var l,h,r=this.selectedSegment,s=e.segments[i-1],o=e.segments[i+2],a=e.segments[i+1];if(a.length||0===a.length?(l=e.segments.slice(i,2),h={element:e,removeSegments:l,type:"Removal",cancel:!1},this.commandHandler.triggerEvent(Ce.segmentCollectionChange,h={element:e,removeSegments:l,type:"Removal",cancel:!1}),h.cancel||(e.segments.splice(i,2),"Top"===r.direction||"Bottom"===r.direction?(o.points[0].y=r.points[0].y,s.points[s.points.length-1].x=o.points[0].x):(o.points[0].x=r.points[0].x,s.points[s.points.length-1].y=o.points[0].y))):(l=e.segments.slice(i+1,1),this.commandHandler.triggerEvent(Ce.segmentCollectionChange,h={element:e,removeSegments:l,type:"Removal",cancel:!1}),h.cancel||(e.segments.splice(i+1,1),"Top"===r.direction||"Bottom"===r.direction?s.points[s.points.length-1].x=a.points[a.points.length-1].x:s.points[s.points.length-1].y=a.points[a.points.length-1].y,this.findSegmentDirection(s),r.length=r.direction=null)),s&&o&&!h.cancel&&(s.length=z.distancePoints(s.points[0],o.points[0]),s.direction=z.direction(s.points[0],o.points[0]),o.length||0===o.length)){o.length=z.distancePoints(s.points[s.points.length-1],o.points[o.points.length-1]);var c=s.points,d=o.points;o.direction=z.direction(c[c.length-1],d[d.length-1])}},t.prototype.addOrRemoveSegment=function(e,i,r){for(var s,o,a=[],l={segments:e.segments},h=0;h0?"Bottom":"Top":r>0?"Right":"Left",length:i.points[0].x===i.points[1].x?s:r},!0)),l.push(new bi(e,"segments",{type:"Orthogonal",direction:c,length:h/2},!0));var p={element:e,addSegments:l,type:"Addition",cancel:!1};return this.commandHandler.triggerEvent(Ce.segmentCollectionChange,p),p.cancel||(e.segments=l.concat(e.segments),a=o+2),a},t.prototype.insertFirstSegment=function(e,i,r,s,o){var a,l,d,u,h=[];if(e.sourcePortID&&i.length&&e.segments[0].points.length>2)for(var p=void 0,f=0;f0?"Bottom":"Top":r>0?"Right":"Left"),p=u,h.push(u)}else h.push(new bi(e,"segments",{type:"Orthogonal",direction:i.direction,length:i.length/3},!0)),"Bottom"===i.direction||"Top"===i.direction?(l=Math.abs(r),a=r>0?"Right":"Left"):(l=Math.abs(s),a=s>0?"Bottom":"Top"),u=new bi(e,"segments",{type:"Orthogonal",direction:a,length:l},!0),h.push(u);var y={element:e,addSegments:h,type:"Addition",cancel:!1};if(this.commandHandler.triggerEvent(Ce.segmentCollectionChange,y),!y.cancel){if(e.sourcePortID&&i.length&&e.segments[0].points.length>2)e.segments.splice(0,1),d=1;else{var S=e.segments[1];S&&S.length&&(S.length=a!==S.direction?S.length+l:S.length-l),d=2,i.length=2*i.length/3}e.segments=h.concat(e.segments)}return d},t.prototype.updateAdjacentSegments=function(e,i,r,s){var o=e.segments[parseInt(i.toString(),10)],a=o.points[o.points.length-1],h=!0;"Orthogonal"===o.type&&(o.points[0]=o.points[0],o.points[o.points.length-1]=a,e.segments[i-1]&&(h=this.updatePreviousSegment(r,s,e,i)),e.segments.length-1>i&&h&&this.updateNextSegment(e,o,e.segments[i+1],r,s))},t.prototype.addTerminalSegment=function(e,i,r,s,o){var l,h,c,d,a=e.segments.indexOf(i),u=[],p=e.segments.pop(),f=e.segments[e.segments.length-1];l=f&&"Orthogonal"===f.type?f:null;for(var g=0;g0&&"Left"===o.direction?c.middleLeft:c.middleRight,o.length>c.width/2?Math.abs(a.length)0&&"Top"===o.direction?c.topCenter:c.bottomCenter,o.length>c.height/2?Math.abs(a.length)1)for(var a=0,l=this.diagram.views;a0)for(var e=t===Ce.onUserHandleMouseLeave?this.previousAction:this.action,i={element:void 0},r=0;r0)for(var r={element:void 0},s=void 0,o=void 0,a=0;a-1&&(o=s,this.previousTarget=i,this.targetItem=e),o===e.fixedUserHandles[parseInt(a.toString(),10)].id&&(r.element=e.fixedUserHandles[parseInt(a.toString(),10)],this.userHandle(t,a,r,e))},n.prototype.mouseDown=function(t){if(!0!==this.inAction||!(this.tool instanceof YI||this.tool instanceof pa)){this.focus=!0;var e=t.touches,i=!!document.getElementsByClassName("e-dragclone")[0];if(this.isMouseOnScrollBar(t)&&!i)return this.isScrolling=!0,void t.preventDefault();if(this.checkFixedUserHandleEvent(Ce.onFixedUserHandleMouseDown,this.targetItem,this.previousTarget),this.checkUserHandleEvent(Ce.onUserHandleMouseDown),!this.checkEditBoxAsTarget(t)&&jv(this.diagram)||Lc(this.diagram)&&!RI(this.diagram))if(("Select"===this.action||"Drag"===this.action)&&this.diagram.updatePortVisibility(this.hoverElement,ti.Hover,!0),!(this.tool instanceof Oh||this.tool instanceof kh)||2!==t.button&&2!==t.buttons)if(!0===this.inAction&&!0===this.isMouseDown&&(this.tool instanceof Oh||this.tool instanceof kh))this.isMouseDown=!0,this.eventArgs={},this.getMouseEventArgs(this.currentPosition,this.eventArgs),this.eventArgs.position=this.currentPosition,this.tool.mouseDown(this.eventArgs);else{this.isMouseDown=!0,this.currentPosition=this.prevPosition=this.getMousePosition(t),this.eventArgs={},this.diagram.textEditing&&!this.isMouseOnScrollBar(t)&&(this.diagram.endEdit(),this.diagram.textEditing=!1,"Canvas"===this.diagram.mode&&1!==this.diagram.scroller.currentZoom&&this.diagram.refreshDiagramLayer());var s=this.getTargetElement();this.action=this.diagram.findActionToBeDone(s.obj,s.sourceElement,this.currentPosition,s.target);var o=this.isMetaKey(t);o&&t.shiftKey&&this.diagram.connectorEditingToolModule?this.action="SegmentEnd":(o||t.shiftKey)&&(_v(this.diagram)||Uv(this.diagram))&&(this.action="Select"),this.tool=this.diagram.getTool(this.action),this.tool||(this.action="Select",this.tool=this.diagram.getTool(this.action)),this.getMouseEventArgs(this.currentPosition,this.eventArgs),(o||t.shiftKey)&&(this.eventArgs.info=o&&t.shiftKey?{ctrlKey:o,shiftKey:t.shiftKey}:{ctrlKey:!0}),this.eventArgs.position=this.currentPosition;var l=this.diagram.selectedItems.nodes;if(this.tool.mouseDown(this.eventArgs),this.diagram.selectedItems.canToggleSelection&&l&&this.diagram.selectedItems.nodes&&this.tool instanceof ua)for(var h=0;h=2&&(this.touchStartList=HF(this.touchStartList,0,e)),e||t.preventDefault())}else this.inAction=!1,this.tool.mouseUp(this.eventArgs);!this.isForeignObject(t.target)&&!this.isForeignObject(t.target,!0)&&!e&&t.preventDefault()}},n.prototype.mouseMoveExtend=function(t,e){(this.tool instanceof Oh||this.tool instanceof kh)&&this.tool.mouseMove(this.eventArgs),this.diagram.scrollSettings.canAutoScroll?this.checkAutoScroll(t):this.blocked||this.tool.mouseMove(this.eventArgs),this.eventArgs.target&&(this.hoverElement=this.eventArgs.target);var i=!((this.eventArgs.target instanceof te||this.eventArgs.target instanceof de)&&(e instanceof te||e instanceof de));this.tool instanceof Od&&this.diagram.updatePortVisibility(this.hoverElement instanceof te||this.hoverElement instanceof de?this.hoverElement:this.hoverNode,ti.Connect|ti.Hover,i),this.hoverElement instanceof te&&this.hoverNode instanceof te&&this.hoverNode&&this.hoverNode.id!==this.hoverElement.id&&this.diagram.updatePortVisibility(this.hoverNode,ti.Connect|ti.Hover,!0),this.hoverElement instanceof de&&this.hoverElement.ports.length>0&&this.diagram.updatePortVisibility(this.hoverElement,ti.Connect|ti.Hover,!0),this.previousElement instanceof te&&this.hoverElement&&this.previousElement.id!==this.hoverElement.id&&this.diagram.updatePortVisibility(this.previousElement,ti.Connect|ti.Hover,!0),this.previousElement=this.hoverElement,""!==this.diagram.tooltip.content&&(this.hoverElement=null),this.hoverNode=i?null:e},n.prototype.checkAction=function(t){if("LabelSelect"===this.action&&this.eventArgs.sourceWrapper&&(this.eventArgs.sourceWrapper instanceof si||this.eventArgs.sourceWrapper instanceof Jn)){var e=this.commandHandler.findTarget(this.eventArgs.sourceWrapper,this.eventArgs.source);!_r(this.diagram,e,!1,this.eventArgs.sourceWrapper)&&to(e)&&(this.action="LabelDrag",this.tool=this.getTool(this.action),this.tool.mouseDown(this.initialEventArgs))}else to(t)&&Dd(t)&&this.initialEventArgs&&this.initialEventArgs.source&&"Select"===this.action&&(!_r(this.diagram,this.eventArgs.source,!1)&&this.eventArgs.source instanceof oi&&this.getMouseEventArgs(this.currentPosition,this.eventArgs),(!(t instanceof de)||t instanceof de&&!(wr(this.currentPosition,t.sourcePoint,t.hitPadding)||wr(this.currentPosition,t.targetPoint,t.hitPadding)))&&(this.action="Drag"),this.tool=this.getTool(this.action),this.tool.mouseDown(this.initialEventArgs))},n.prototype.isSwimlaneElements=function(t){return!(t&&(t.isLane||t.isPhase||t.isHeader))},n.prototype.mouseMove=function(t,e){if(this.focus=!0,this.isScrolling)t.preventDefault();else if(jv(this.diagram)||Lc(this.diagram)&&!RI(this.diagram)){this.currentPosition=this.getMousePosition(t);var i=this.diagram.findObjectsUnderMouse(this.currentPosition),r=this.diagram.findObjectUnderMouse(i,this.action,this.inAction);!function qne(n,t){n.rulerSettings.showRulers&&(n.hRuler.drawRulerMarker(n.hRuler.element,t,n.scroller.horizontalOffset),n.vRuler.drawRulerMarker(n.vRuler.element,t,n.scroller.verticalOffset))}(this.diagram,this.currentPosition);var s=!1,o=void 0;if("touchmove"===t.type&&(e=t.touches)&&e.length>1&&(this.touchMoveList=HF(this.touchMoveList,0,e),"PinchZoom"!==this.action&&(s=!0)),!1===z.equals(this.currentPosition,this.prevPosition)||this.inAction){if(!1===this.isMouseDown||s){this.eventArgs={};var a=null,l=void 0;if(null!==r){if((a=this.diagram.findElementUnderMouse(r,this.currentPosition,this.diagram))&&(l=this.commandHandler.findTarget(a,r)),(l instanceof Zn||l instanceof Nr)&&(l.tooltip&&""!==l.tooltip.content||(l=r)),l!==this.hoverElement){var h=this.getContent();this.hoverElement&&"Auto"===this.hoverElement.tooltip.openOn&&""!==h&&this.elementLeave(),this.diagram.updatePortVisibility(this.hoverElement,ti.Hover,!0),r instanceof te&&(this.hoverNode=r);var c=!0;!this.isSwimlaneElements(r)&&this.hoverElement&&this.isSwimlaneElements(this.hoverElement)&&(c=!1),this.hoverElement=c?r:this.hoverElement;var d,u=void 0;(d=this.diagram.findElementUnderMouse(r,this.currentPosition,this.diagram))instanceof Ke&&((u=this.commandHandler.findTarget(d,r))instanceof Es||u instanceof xc)&&this.hoverElement.constraints&ni.ToolTip&&(this.hoverElement=u);var p=void 0;d instanceof si&&((p=this.commandHandler.findTarget(d,r))instanceof Zn||p instanceof Nr)&&p.constraints&Lr.Tooltip&&(this.hoverElement=p),c?this.elementEnter(this.currentPosition,!1):this.hoverElement=r}else this.hoverElement&&this.hoverElement===l&&this.hoverElement.tooltip.content&&void 0!==this.diagram.tooltipObject&&"Mouse"===this.hoverElement.tooltip.relativeMode&&this.setTooltipOffset(this.currentPosition);a&&(o=this.commandHandler.findTarget(a,r))}this.action=this.diagram.findActionToBeDone(r,a,this.currentPosition,o),this.checkFixedUserHandleEvent(Ce.onFixedUserHandleMouseEnter,r,a),this.checkUserHandleEvent(Ce.onUserHandleMouseEnter),this.checkPreviousAction(),this.getMouseEventArgs(this.currentPosition,this.eventArgs),this.tool=this.getTool(this.action),this.mouseEvents(),this.tool instanceof pa||this.tool instanceof kh||this.tool instanceof Oh?this.tool.mouseMove(this.eventArgs):e&&this.tool instanceof Jv&&this.tool.mouseDown(this.eventArgs),this.updateCursor(),this.renderUmlHighLighter(this.eventArgs);var f=!1;this.hoverElement&&!(this.tool instanceof Jv)&&r instanceof te&&this.isSwimlaneElements(r)&&(0===this.diagram.selectedItems.nodes.length||!_r(this.diagram,this.hoverElement))||this.hoverElement instanceof de||(f=!0),this.hoverElement&&!(this.tool instanceof Jv)&&r instanceof de&&(0===this.diagram.selectedItems.connectors.length||!_r(this.diagram,this.hoverElement))||this.hoverElement instanceof te||(f=!0),this.diagram.updatePortVisibility(this.hoverElement,ti.Hover,f);var g=this.getContent();null===r&&this.hoverElement&&"Auto"===this.hoverElement.tooltip.openOn&&g&&(this.hoverElement=null,this.elementLeave()),s=!1}else{this.eventArgs.position=this.currentPosition,"Drag"===this.action&&!_r(this.diagram,this.eventArgs.source,!1)&&this.eventArgs.source instanceof oi&&this.getMouseEventArgs(this.currentPosition,this.eventArgs),this.mouseEvents(),(t.ctrlKey||t.shiftKey)&&(this.eventArgs.info=t.ctrlKey&&t.shiftKey?{ctrlKey:t.ctrlKey,shiftKey:t.shiftKey}:{ctrlKey:!0}),this.checkAction(r);var y=this.getConnectorPadding(this.eventArgs);this.getMouseEventArgs(this.currentPosition,this.eventArgs,this.eventArgs.source,y),this.updateCursor(),this.inAction=!0,this.initialEventArgs=null,("Drag"===this.action||"Rotate"===this.action)&&(this.diagram.diagramActions=this.diagram.diagramActions|ee.Interactions);var S=this.diagram.scroller.getPageBounds();this.mouseMoveExtend(t,r);var b=this.diagram.scroller.getPageBounds();if(r&&(S.width!==b.width||S.height!==b.height||S.x!==b.x||S.y!==b.y)&&this.diagram.views&&this.diagram.views.overview){var M=this.diagram.views.overview;M.updateView(M)}}this.prevPosition=this.currentPosition,this.isForeignObject(t.target,!0)||t.preventDefault()}}},n.prototype.getContent=function(){var i,t=this.hoverElement instanceof te&&this.hoverElement.constraints&ie.Tooltip||this.hoverElement instanceof de&&this.hoverElement.constraints&qe.Tooltip||(this.hoverElement instanceof Es||this.hoverElement instanceof xc)&&this.hoverElement.constraints&ni.ToolTip||(this.hoverElement instanceof Zn||this.hoverElement instanceof Nr)&&this.hoverElement.constraints&Lr.Tooltip,e=this.hoverElement;e instanceof te&&e.children&&e.children.length>0&&(i=this.findIntersectChild(e));var r=t?this.hoverElement.tooltip.content:this.diagram.tooltip.content;return i?i.tooltip.content:r},n.prototype.findIntersectChild=function(t){for(var e,i=new Ne(this.currentPosition.x,this.currentPosition.y,8,8),r=0;r1&&1===t.which&&!function Zre(n){return!!(n&ee.PreventClearSelection)}(this.diagram.diagramActions)&&(c=!1,this.commandHandler.clearSelection()),(!_r(this.diagram,h)||!c)&&(this.commandHandler.selectObjects([h],void 0,a),this.diagram.selectedItems.canToggleSelection)){var d=this.diagram.selectedItems.nodes;d?d[0].parentObj instanceof Rd&&(s=!0):this.diagram.selectedItems.connectors.length>0&&(s=!0)}}var u=!1,p=this.updateContainerProperties(),f=void 0;if(this.addUmlNode(),this.inAction=!1,this.isMouseDown=!1,this.diagram.selectedObject.helperObject&&(f=this.updateContainerBounds()),this.tool&&(this.tool.prevPosition||this.tool instanceof X3)){this.eventArgs.position=this.currentPosition;var g=this.getConnectorPadding(this.eventArgs);this.getMouseEventArgs(this.currentPosition,this.eventArgs,this.eventArgs.source,g);var v=this.isMetaKey(t);if((v||t.shiftKey)&&(this.eventArgs.info=v&&t.shiftKey?{ctrlKey:v,shiftKey:t.shiftKey}:{ctrlKey:!0}),this.diagram.diagramActions&ee.Interactions&&(this.diagram.diagramActions=this.diagram.diagramActions&~ee.Interactions),this.eventArgs.clickCount=t.detail,this.diagram.selectedObject.helperObject&&(this.tool instanceof ua||this.tool instanceof kd)){if(this.diagram.selectedObject.actualObject&&""!==this.diagram.selectedObject.actualObject.parentId){var S=this.diagram.getObject(this.diagram.selectedObject.actualObject.parentId);S&&S.isLane&&(this.commandHandler.isContainer=!0)}(u=this.diagram.lineRoutingModule&&this.diagram.nameTable.helper&&this.eventArgs.target&&this.eventArgs.target.isLane&&(this.eventArgs.source instanceof oi&&this.eventArgs.source.nodes.length>0&&""===this.eventArgs.source.nodes[0].parentId||""===this.eventArgs.source.parentId))&&(this.diagram.diagramActions=this.diagram.diagramActions|ee.PreventLaneContainerUpdate),this.tool.mouseUp(this.eventArgs,p.isPreventHistory)}else{if(this.diagram.selectedItems.canToggleSelection){var b=void 0,M=void 0;if(this.diagram.selectedItems.nodes.length>0)for(var w=0;w1&&D[0].id===i[parseInt(w.toString(),10)].id||r.length>0)&&(M=!0);!this.isSwimlaneSelected&&!s&&!M&&this.tool instanceof ua&&"Select"===this.currentAction&&(!b||this.diagram.selectedItems.connectors.length>0)&&this.commandHandler.clearSelection(!0)}this.isSwimlaneSelected=!1,this.tool.mouseUp(this.eventArgs),this.diagram.checkMenu&&(-1!==window.navigator.userAgent.indexOf("Linux")||-1!==window.navigator.userAgent.indexOf("X11"))&&(!t.pageY&&t instanceof TouchEvent&&t.changedTouches?(window.getSelection().removeAllRanges(),this.diagram.contextMenuModule.contextMenu.open(t.changedTouches[0].pageY,t.changedTouches[0].pageX,this.diagram.element),t.preventDefault()):this.diagram.contextMenuModule.contextMenu.open(t.pageY,t.pageX,this.diagram.element),this.diagram.checkMenu=!1)}p.hasStack&&this.diagram.endGroupAction()}if(f&&this.diagram.endGroupAction(),this.updateContainerBounds(!0),2!==this.eventArgs.clickCount&&(this.commandHandler.updateSelectedNodeProperties(this.eventArgs.source),u)){this.diagram.diagramActions=this.diagram.diagramActions&~ee.PreventLaneContainerUpdate;var A=this.eventArgs.source instanceof oi?this.eventArgs.source.nodes:[this.eventArgs.source];if(A)for(w=0;w0&&!N&&this.diagram.renderSelector(!0),!this.inAction&&!this.diagram.currentSymbol&&this.eventArgs){var T=this.getTargetElement();this.diagram.tool!==Ci.ZoomPan&&this.diagram.triggerEvent(Ce.click,{element:T.target instanceof Es?T.target:this.eventArgs.source||this.diagram,position:this.eventArgs.position,count:t.detail,actualObject:this.eventArgs.actualObject,button:0===t.button?"Left":1===t.button?"Middle":"Right"})}this.eventArgs={}}this.diagram.diagramActions=this.diagram.diagramActions&~ee.PreventLaneContainerUpdate,e&&this.updateAnnotation(this.diagram.selectedItems),this.eventArgs={},this.diagram.commandHandler.removeStackHighlighter()},n.prototype.isSwimlaneChild=function(t){if(t.shape&&"SwimLane"!==t.shape.type){var e=this.diagram.nameTable[t.parentId];if(!e)return!1;var i=e.parentId?this.diagram.nameTable[e.parentId]:e;return i&&i.shape&&"SwimLane"===i.shape.type}return!1},n.prototype.updateAnnotation=function(t){var e=t.nodes;if(e.length>0)for(var i=0;i0&&(a+=1),h.isPhase){l="Horizontal"===r.orientation?this.currentPosition.x-e.wrapper.bounds.x:this.currentPosition.y-(e.wrapper.bounds.y+r.header.height);var g={id:Qe(),offset:l,header:{annotation:{content:void 0===h.phases[0].header?"Phase":h.phases[0].header.annotation.content,style:void 0===h.phases[0].header?{}:h.phases[0].header.annotation.style}},style:void 0===h.phases[0]?{}:h.phases[0].style};this.diagram.addPhases(e,[g])}else{var v={id:Qe(),style:h.lanes[0].style,header:{annotation:{content:h.lanes[0].header.annotation.content,style:h.lanes[0].header.annotation.style},style:h.lanes[0].header.style}};if("Horizontal"===h.orientation?v.height=h.lanes[0].height:v.width=h.lanes[0].width,"Horizontal"===r.orientation?(s=i.rowIndex?i.rowIndex:this.diagram.nameTable[i.parentId].rowIndex,i.wrapper.offsetYs)v.header.width=r.lanes[parseInt(s.toString(),10)].header.width,v.header.height=r.lanes[parseInt(s.toString(),10)].header.height;else{var S=void 0;S="Horizontal"===r.orientation?i.rowIndex<3?0:s-a-1:s-1,v.header.width=r.lanes[parseInt(S.toString(),10)].header.width,v.header.height=r.lanes[parseInt(S.toString(),10)].header.height}f&&("height"===f?(v.width=v.height,delete v.height):(v.height=v.width,delete v.width)),this.diagram.addLanes(e,[v],"Horizontal"===r.orientation?s-a:s)}this.commandHandler.select(e)}else if(h.isLane){var b={id:Qe(),width:t.width,height:t.height,addInfo:t.addInfo,shape:{type:"SwimLane",header:{annotation:{content:void 0===h.header?"Header":h.header.annotation.content,style:void 0===h.header?{}:h.header.annotation.style},height:50,style:h.header?h.header.style:h.lanes[0].header.style},phases:[{id:Qe(),header:{annotation:{content:void 0===h.phases||void 0===h.phases[0].header?"Phase":h.phases[0].header.annotation.content,style:void 0===h.phases||void 0===h.phases[0].header?{}:h.phases[0].header.annotation.style},style:void 0===h.phases||void 0===h.phases[0].header?{}:h.phases[0].header.style},style:void 0===h.phases?{}:h.phases[0].style}],lanes:[{id:Qe(),height:t.height,width:t.width,style:h.lanes[0].style,header:{annotation:{content:h.lanes[0].header.annotation.content,style:h.lanes[0].header.annotation.style},style:h.lanes[0].header.style}}],orientation:h.orientation}};"Vertical"===h.orientation&&(b.width+=20),b.offsetX=this.currentPosition.x+b.width/2,b.offsetY=this.currentPosition.y+b.height/2,b.style=t.style,this.diagram.add(b)}},n.prototype.mouseLeave=function(t){this.tool&&this.inAction&&this.tool.mouseLeave(this.eventArgs),this.diagram.selectedObject.helperObject&&(this.updateContainerProperties(),this.updateContainerBounds()&&this.diagram.endGroupAction()),this.eventArgs&&this.eventArgs.source&&(this.diagram.updatePortVisibility(this.eventArgs.source,ti.Hover,!0),this.hoverElement=null),this.eventArgs&&!this.eventArgs.source&&this.hoverElement&&(this.hoverElement=null),this.tool instanceof Od&&this.eventArgs&&this.eventArgs.target&&this.eventArgs.target instanceof te&&(this.diagram.updatePortVisibility(this.eventArgs.target,ti.Hover|ti.Connect,!0),this.hoverElement=null);var i=this.diagram.selectedItems;i&&i.wrapper&&(om(this.diagram,i)||this.diagram.renderSelector(!0)),(this.diagram.diagramActions&ee.Interactions||this.diagram.diagramActions&ee.ToolAction)&&(this.diagram.diagramActions=this.diagram.diagramActions&~ee.ToolAction),this.isMouseDown=!1,this.focus=!1,this.touchStartList=null,this.touchMoveList=null,this.elementLeave(),this.commandHandler.removeSnap(),this.inAction=!1,this.eventArgs={},this.diagram.selectedObject&&this.diagram.selectedObject.helperObject&&(this.diagram.remove(this.diagram.selectedObject.helperObject),this.diagram.selectedObject={helperObject:void 0,actualObject:void 0}),this.tool=null,function Xne(){var t,e,n=document.getElementsByClassName("e-d-ruler-marker");if(n&&n.length>0)for(e=n.length-1;e>=0;e--)(t=n[parseInt(e.toString(),10)])&&t.parentNode.removeChild(t)}(),"Rotate"===this.action&&this.diagram.diagramCanvas.classList.remove("e-diagram-rotate"),t.preventDefault()},n.prototype.mouseWheel=function(t){this.diagram.blazorActions|=on.interaction;var e={event:t,cancel:!1};if(this.diagram.triggerEvent(Ce.mouseWheel,e),!e.cancel){var i=t.wheelDelta>0||-40*t.detail>0,r=this.getMousePosition(t);if(this.diagram.tooltipObject.close(),this.isMetaKey(t)){var o=this.diagram.scrollSettings.zoomFactor;this.diagram.zoomTo(i?{type:"ZoomIn",zoomFactor:o,focusPoint:r}:{type:"ZoomOut",zoomFactor:o,focusPoint:r}),t.preventDefault()}else{var a=this.diagram.scroller.horizontalOffset,l=this.diagram.scroller.verticalOffset,h=i?10:-10;this.tool&&(this.tool instanceof Oh||this.tool instanceof kh)&&(this.eventArgs={},this.getMouseEventArgs(r,this.eventArgs),this.eventArgs.position=r,this.tool.mouseWheel(this.eventArgs)),this.diagram.scrollActions|=ca.Interaction;var c=!0;if(t.isTrusted){var d=!1;(Math.abs(t.deltaY)<100&&-0===Math.abs(t.deltaX)||Math.abs(t.deltaX)<100&&-0===Math.abs(t.deltaY))&&(d=!0);var u=!1;(0!==t.deltaX||0!==t.deltaY)&&(u=navigator.userAgent.includes("Macintosh")),u?Math.abs(t.deltaX)>Math.abs(t.deltaY)?(t.shiftKey||t.deltaX&&-0!==t.deltaX&&(d||!u))&&this.diagram.scroller.zoom(1,h,0,r,c,void 0,d):t.deltaY&&-0!==t.deltaY&&(d||!u)&&this.diagram.scroller.zoom(1,0,h,r,c,void 0,d):t.shiftKey||t.deltaX&&-0!==t.deltaX&&(d||!u)?this.diagram.scroller.zoom(1,h,0,r,c,void 0,d):t.deltaY&&-0!==t.deltaY&&(d||!u)&&this.diagram.scroller.zoom(1,0,h,r,c,void 0,d)}else t.shiftKey||t.deltaX&&-0!==t.deltaX?this.diagram.scroller.zoom(1,h,0,r,c):this.diagram.scroller.zoom(1,0,h,r,c);this.diagram.scrollActions&=~ca.Interaction,(a!==this.diagram.scroller.horizontalOffset||l!==this.diagram.scroller.verticalOffset)&&t.preventDefault()}if(this.diagram.textEditing){if(this.diagram.isTriggerEvent=!0,this.diagram.activeLabel.parentId){var f=this.diagram.getObject(this.diagram.activeLabel.parentId);this.diagram.startTextEdit(f,this.diagram.activeLabel.id)}this.diagram.isTriggerEvent=!1}this.diagram.blazorActions=this.diagram.blazorActions&~on.interaction}},n.prototype.keyDown=function(t){if(t.fromMouseEvents&&(t.ctrlKey&&(this.keyArgs.keyModifiers=1),t.shiftKey&&(this.keyArgs.keyModifiers=4),t.shiftKey&&t.ctrlKey&&(this.keyArgs.keyModifiers=5)),!(this.diagram.diagramActions&ee.TextEdit)&&!this.checkEditBoxAsTarget(t)||"Escape"===t.key||27===t.keyCode){var i=void 0,r=t.keyCode?t.keyCode:t.which,s=t.key;("ArrowDown"===s||"ArrowUp"===s||"ArrowLeft"===s||"ArrowRight"===s)&&(this.isNudgeKey=!0);var o=this.isMetaKey(t);if(this.diagram.commandManager&&this.diagram.commands)for(var l=0,h=Object.keys(this.diagram.commands);l4&&(S({keyDownEventArgs:KeyboardEvent,parameter:i.parameter,type:"KEYDOWN"}),this.keyCount=0)),this.isKeyUp=!1):S({keyDownEventArgs:KeyboardEvent,parameter:i.parameter})}break}}}}this.keyArgs={element:this.diagram.selectedItems,key:t.key,keyCode:t.keyCode?t.keyCode:t.which},this.getKeyModifier(this.keyArgs,t),this.diagram.diagramActions&ee.TextEdit&&this.getlabel(this.keyArgs,t),this.diagram.triggerEvent(Ce.keyDown,this.keyArgs)},n.prototype.getlabel=function(t,e){var i=this.diagram.activeLabel;t.target=this.diagram.element.id+"_editBox";var r=this.diagram.nameTable[i.parentId];if(document.getElementById(this.diagram.element.id+"_editBox")){t.text=document.getElementById(this.diagram.element.id+"_editBox").value;for(var s=0;s=this.diagram.scroller.viewPortWidth-18?r="right":e.x+this.diagram.scroller.horizontalOffsetthis.diagram.scroller.viewPortHeight-18?r="bottom":e.y+this.diagram.scroller.verticalOffset0&&(s=this.findIntersectChild(this.hoverElement)),"Auto"===this.hoverElement.tooltip.openOn&&""!==r&&wx(this.diagram,s||(i?this.hoverElement:void 0)),this.hoverElement.tooltip.content&&("Mouse"===this.hoverElement.tooltip.relativeMode?this.setTooltipOffset(t):(this.diagram.tooltipObject.offsetX=0,this.diagram.tooltipObject.offsetY=0));var o=this.diagram.findObjectsUnderMouse(this.currentPosition),a=this.diagram.findObjectUnderMouse(o,this.action,this.inAction);if(null!==a){var l=void 0;this.hoverElement.tooltip.isSticky&&(this.diagram.tooltipObject.isSticky=!0),a instanceof te&&a.children&&a.children.length>0&&(a=s||a),l=a.ports&&(this.hoverElement instanceof Es||this.hoverElement instanceof xc)||a.annotations&&(this.hoverElement instanceof Zn||this.hoverElement instanceof Nr)?document.getElementById(a.id+"_"+this.hoverElement.id):document.getElementById(a.id+(a.shape&&a.shape instanceof am?"_content_native_element":"_groupElement")),"Auto"===this.hoverElement.tooltip.openOn&&""!==r&&(this.diagram.tooltipObject.close(),this.diagram.tooltipObject.openOn=this.hoverElement.tooltip.openOn,this.diagram.tooltipObject.dataBind()),function Wre(n,t){var e=0;return n instanceof de?n.constraints&qe.Tooltip?e=n.constraints&qe.Tooltip:n.constraints&qe.InheritTooltip&&(e=t.constraints&rt.Tooltip):n instanceof Es||n instanceof xc?n.constraints&ni.ToolTip?e=n.constraints&ni.ToolTip:n.constraints&ni.InheritTooltip&&(e=t.constraints&rt.Tooltip):n instanceof Zn||n instanceof Nr?n.constraints&Lr.Tooltip&&(e=n.constraints&Lr.Tooltip):n.constraints&ie.Tooltip?e=n.constraints&ie.Tooltip:n.constraints&ie.InheritTooltip&&(e=t.constraints&rt.Tooltip),e}(this.hoverElement,this.diagram)&&"Auto"===this.hoverElement.tooltip.openOn&&(this.diagram.tooltipObject.target=this.hoverElement.id,this.diagram.tooltipObject.open("Mouse"===this.hoverElement.tooltip.relativeMode?this.diagram.element:l))}}},n.prototype.elementLeave=function(){this.diagram.tooltipObject&&!this.diagram.tooltipObject.isSticky&&"Custom"!==this.diagram.tooltipObject.openOn&&this.diagram.tooltipObject.close()},n.prototype.setTooltipOffset=function(t){var e=function pse(n,t,e,i){var o="Mouse"===(!(e instanceof te?e.constraints&ie.InheritTooltip:e instanceof de?e.constraints&qe.InheritTooltip:e.constraints&ni.InheritTooltip)&&(e instanceof te?e.constraints&ie.Tooltip:e instanceof de?e.constraints&qe.Tooltip:e.constraints&ni.ToolTip)?e.tooltip.relativeMode:n.tooltip.relativeMode);"Mouse"===i?o=!0:"Object"===i&&(o=!1);var a=function fse(n,t,e,i){var o,r={},s=document.getElementById(e.element.id);if(n instanceof te||n instanceof de)o=n.wrapper.bounds;else{var a=e.findObjectsUnderMouse(t),l=e.findObjectUnderMouse(a,"Select",!1);o=e.findElementUnderMouse(l,t,e).bounds}var c=s.getBoundingClientRect();switch(e.tooltipObject.position){case"BottomCenter":r=zc(t,o.bottomCenter,e,i,c.width/2,c.height);break;case"BottomLeft":case"LeftBottom":r=zc(t,o.bottomLeft,e,i,0,c.height);break;case"BottomRight":case"RightBottom":r=zc(t,o.bottomRight,e,i,c.width,c.height);break;case"LeftCenter":r=zc(t,o.middleLeft,e,i,0,c.height/2);break;case"LeftTop":case"TopLeft":r=zc(t,o.topLeft,e,i,0,0);break;case"RightCenter":r=zc(t,o.middleRight,e,i,c.width,c.height/2);break;case"RightTop":case"TopRight":r=zc(t,o.topRight,e,i,c.width,0);break;case"TopCenter":r=zc(t,o.topCenter,e,i,c.width/2,0)}return r}(e,t,n,o),l=qa(n);return{x:a.x+l.width,y:a.y+l.height}}(this.diagram,t,this.hoverElement);this.diagram.tooltipObject.offsetX=e.x,this.diagram.tooltipObject.offsetY=e.y},n.prototype.altKeyPressed=function(t){return!!(t&pt.Alt)},n.prototype.ctrlKeyPressed=function(t){return!!(t&pt.Control)},n.prototype.shiftKeyPressed=function(t){return!!(t&pt.Shift)},n.prototype.scrolled=function(t){this.diagram.updateScrollOffset()},n.prototype.doubleClick=function(t){if(jv(this.diagram)){var e=void 0,i=this.diagram.findObjectsUnderMouse(this.currentPosition),r=this.diagram.findObjectUnderMouse(i,this.action,this.inAction);if(null!==r&&jv(this.diagram))if(e=this.diagram.findElementUnderMouse(r,this.currentPosition,this.diagram),this.tool&&(this.tool instanceof Oh||this.tool instanceof kh))this.tool.mouseUp(this.eventArgs),this.isMouseDown=!1,this.eventArgs={},this.tool=null,t.preventDefault();else{var o=this.diagram.commandHandler.getObjectLayer(r.id);!o||o.lock||!o.visible||this.diagram.diagramActions&ee.TextEdit||this.diagram.startTextEdit(r,e instanceof si?e.id.split(r.id+"_")[1]:void 0)}this.diagram.triggerEvent(Ce.doubleClick,{source:r||this.diagram,position:this.currentPosition,count:t.detail})}},n.prototype.itemClick=function(t,e){var i=t;return cs(this.diagram,i,!0)?i:null},n.prototype.inputChange=function(t){var i,s,o,a,l,h,c,d,u,p=document.getElementById(this.diagram.element.id+"_editBox"),f=document.getElementById(this.diagram.element.id+"_editTextBoxDiv"),g=p.value,v=g.split("\n");(!(a=this.diagram.selectedItems.nodes[0]?this.diagram.selectedItems.nodes[0]:this.diagram.selectedItems.connectors[0])&&this.tool instanceof QI||a&&"SwimLane"===a.shape.type)&&(a=this.diagram.nameTable[this.diagram.activeLabel.parentId]),a&&("Text"!==a.shape.type&&a.annotations.length>0||"Text"===a.shape.type)&&(c=NF((o=this.diagram.getWrapper(a.wrapper,this.diagram.activeLabel.id)).style,g,void 0,void 0,i=(i=a.wrapper.bounds.width90?i:90),s=Number(p.style.fontSize.split("px")[0]),v.length>1&&""===v[v.length-1]&&(c.height=c.height+s),d=this.diagram.scroller.transform,u=T3(this.diagram)?d.scale:1,l=(12>c.height?12:c.height)*u,f.style.left=(o.bounds.center.x+d.tx)*d.scale-(h=(90>(h=c.width)?90:h)*u)/2-2.5+"px",f.style.top=(o.bounds.center.y+d.ty)*d.scale-l/2-3+"px",f.style.width=h+"px",f.style.height=l+"px",p.style.minHeight="12px",p.style.minWidth="90px",p.style.width=h+"px",p.style.height=l+"px")},n.prototype.isAddTextNode=function(t,e){return!(!(this.tool instanceof QI||e)||(this.tool=null,t&&!zI(this.diagram)&&(this.diagram.drawingObject=void 0,this.diagram.currentDrawingObject=void 0),vF(this.diagram.nodes,t.id)||vF(this.diagram.connectors,t.id)))},n.prototype.checkEditBoxAsTarget=function(t){return!(!t.target||t.target.id!==this.diagram.element.id+"_editBox")},n.prototype.getMouseEventArgs=function(t,e,i,r){var s,o,a;if(e.position=t,i?(o=this.diagram.findObjectsUnderMouse(this.currentPosition,i),s=this.diagram.findTargetObjectUnderMouse(o,this.action,this.inAction,e.position,i)):"Drag"===this.action||"ConnectorSourceEnd"===this.action||"SegmentEnd"===this.action||"OrthoThumb"===this.action||"BezierSourceThumb"===this.action||"BezierTargetThumb"===this.action||"ConnectorTargetEnd"===this.action||-1!==this.action.indexOf("Rotate")||-1!==this.action.indexOf("Resize")?(s=this.diagram.selectedItems,!this.diagram.currentSymbol&&"Drag"===this.action&&s&&this.diagram.selectedItems.nodes.length>0&&"SwimLane"===this.diagram.selectedItems.nodes[0].shape.type&&(o=this.diagram.findObjectsUnderMouse(this.currentPosition),s=this.diagram.findObjectUnderMouse(o,this.action,this.inAction))):(o=this.diagram.findObjectsUnderMouse(this.currentPosition),s=this.diagram.findObjectUnderMouse(o,this.action,this.inAction)),s&&s.isHeader&&(this.eventArgs.actualObject=s=this.diagram.nameTable[s.parentId]),s){var l=void 0,h=void 0,c=void 0;if(((a=this.diagram.findElementUnderMouse(s,this.currentPosition,this.diagram,r))&&s.ports&&s.ports.length&&!nb(s,a)||!a||!s)&&o&&o.length&&i instanceof oi)for(l=i.connectors[0],c=o.length-1;c>=0;c--)if(((h=o[parseInt(c.toString(),10)])instanceof te||h instanceof de)&&l&&l.connectionPadding){if(a=this.diagram.findElementUnderMouse(s=h,this.currentPosition,this.diagram,r),l.constraints&qe.ConnectToNearByPort&&s&&s.ports&&s.ports.length&&nb(s,a))break;if((h instanceof te||h instanceof de)&&l&&l.connectionPadding&&h.wrapper.outerBounds.containsPoint(this.currentPosition)&&l.constraints&qe.ConnectToNearByNode&&!(l.constraints&qe.ConnectToNearByPort)){a=this.diagram.findElementUnderMouse(s=h,this.currentPosition,this.diagram,0);break}}}return i?(e.target=s,e.targetWrapper=a):(e.source=s,e.sourceWrapper=a),e.actualObject=this.eventArgs.actualObject,e.source instanceof oi&&void 0===e.actualObject&&(e.source.nodes.length>0||e.source.connectors.length>0)&&(e.actualObject=e.source.nodes.length>0?this.diagram.nameTable[e.source.nodes[0].id]:this.diagram.nameTable[e.source.connectors[0].id]),e.startTouches=this.touchStartList,e.moveTouches=this.touchMoveList,e},n.prototype.resetTool=function(){this.action="Select",this.hoverElement=null,this.hoverNode=null,this.tool=this.diagram.getTool(this.action),this.updateCursor()},n.prototype.updateTool=function(){this.eventArgs&&!this.eventArgs.position&&(this.action="Select")},n.prototype.getTool=function(t){switch(t){case"Select":return new Zv(this.commandHandler,!0);case"Drag":return new ua(this.commandHandler);case"Rotate":return new Qx(this.commandHandler);case"LayoutAnimation":return new One(this.commandHandler);case"FixedUserHandle":return new Nne(this.commandHandler,!0);case"Hyperlink":return new X3(this.commandHandler);case"ResizeSouthEast":case"ResizeSouthWest":case"ResizeNorthEast":case"ResizeNorthWest":case"ResizeSouth":case"ResizeNorth":case"ResizeWest":case"ResizeEast":return new kd(this.commandHandler,t);case"ConnectorSourceEnd":case"ConnectorTargetEnd":case"BezierSourceThumb":case"BezierTargetThumb":return new Od(this.commandHandler,t);case"SegmentEnd":case"OrthoThumb":return new ZF(this.commandHandler,t);case"Draw":var e="shape",i=function ose(n){var t;return n&&(n.type?t="Connector":n.shape&&!n.type&&(t="Node")),t}(this.diagram.drawingObject);if("Node"===i&&"Text"===this.diagram.drawingObject.shape.type)return new QI(this.commandHandler);if("Connector"===i&&"Freehand"===this.diagram.drawingObject.type)return new Rne(this.commandHandler);if("Node"===i&&"Polygon"===this.diagram.drawingObject.shape[""+e]&&!this.diagram.drawingObject.shape.points)return new Oh(this.commandHandler);if("Node"===i||"Node"===i&&"Polygon"===this.diagram.drawingObject.shape[""+e]&&this.diagram.drawingObject.shape.points)return new YI(this.commandHandler,this.diagram.drawingObject);if("Connector"===i&&"Polyline"===this.diagram.drawingObject.type)return new kh(this.commandHandler);if("Connector"===i)return new pa(this.commandHandler,"ConnectorSourceEnd",this.diagram.drawingObject);break;case"Pan":return new Jv(this.commandHandler,!1);case"PinchZoom":return new Jv(this.commandHandler,!0);case"PortDrag":return new ua(this.commandHandler,"Port");case"PortDraw":return new pa(this.commandHandler,"ConnectorSourceEnd",this.diagram.drawingObject);case"LabelSelect":return new Zv(this.commandHandler,!0,"LabelSelect");case"LabelDrag":return new kne(this.commandHandler);case"LabelResizeSouthEast":case"LabelResizeSouthWest":case"LabelResizeNorthEast":case"LabelResizeNorthWest":case"LabelResizeSouth":case"LabelResizeNorth":case"LabelResizeWest":case"LabelResizeEast":return new Pne(this.commandHandler,t);case"LabelRotate":return new zne(this.commandHandler)}return null},n.prototype.getCursor=function(t){var e=this.diagram.selectedItems.annotation?this.diagram.selectedItems.wrapper.children[0]:this.diagram.selectedItems;return function Lne(n,t){if(t+=360,t%=360,-1===n.indexOf("Resize"))return Yx[""+n];var e=Yx[""+n];return t>=0&&t<25||t>=160&&t<=205||t>=340&&t<=360?e:t>=25&&t<=70||t>=205&&t<=250?"n-resize"===e||"s-resize"===e?"ne-resize":"nw-resize"===e||"se-resize"===e?"n-resize":"e-resize"===e||"w-resize"===e?"nw-resize":"e-resize":t>=70&&t<=115||t>=250&&t<=295?"n-resize"===e||"s-resize"===e?"e-resize":"nw-resize"===e||"se-resize"===e?"ne-resize":"e-resize"===e||"w-resize"===e?"n-resize":"nw-resize":t>=115&&t<=155||t>=295&&t<=340?"n-resize"===e||"s-resize"===e?"nw-resize":"nw-resize"===e||"se-resize"===e?"e-resize":"e-resize"===e||"w-resize"===e?"ne-resize":Yx[""+n]:"n-resize"}(t,this.diagram.selectedItems.annotation?e.rotateAngle+e.parentTransform:e.rotateAngle)},n.prototype.findElementUnderMouse=function(t,e,i,r){return this.objectFinder.findElementUnderSelectedItem(t,e,i,r)},n.prototype.findObjectsUnderMouse=function(t,e){return this.objectFinder.findObjectsUnderMouse(t,this.diagram,this.eventArgs,e)},n.prototype.findObjectUnderMouse=function(t,e,i){return this.objectFinder.findObjectUnderMouse(this.diagram,t,e,i,this.eventArgs,this.currentPosition)},n.prototype.findTargetUnderMouse=function(t,e,i,r,s){return this.objectFinder.findObjectUnderMouse(this.diagram,t,e,i,this.eventArgs,r,s)},n.prototype.findActionToBeDone=function(t,e,i,r){return function Cne(n,t,e,i,r,s,o){if(s&&s.length>1&&r&&r.length>1)return"PinchZoom";if(i.currentSymbol)return"Drag";if("PortDraw"===i.eventHandler.action&&(i.tool&=~Ci.DrawOnce),(x3(i)||zI(i))&&i.drawingObject)return"Draw";if(Xa(i)&&(l=i.selectedItems).wrapper&&qr(l.constraints,"UserHandle"))for(var h=0,c=l.userHandles;h=50&&(l.x=(a.points[parseInt(h.toString(),10)].x+a.points[h+1].x)/2,l.y=(a.points[parseInt(h.toString(),10)].y+a.points[h+1].y)/2,wr(e,l,n.hitPadding?n.hitPadding:10)))return"OrthoThumb"}else NI(n)&&console.warn('[WARNING] :: Module "ConnectorEditing" is not available in Diagram component! You either misspelled the module name or forgot to load it.');return null}(g,l,e,i);if("OrthoThumb"===S)return S;if(qr(l.constraints,"ConnectorSourceThumb")&&AI(g)&&S||qr(l.constraints,"ConnectorTargetThumb")&&LI(g)&&S)return S}}else{var b=i.selectedItems.handleSize/2/i.scroller.currentZoom,M=10/i.scroller.currentZoom,w=Hi();qi(w,p.rotateAngle+p.parentTransform,p.offsetX,p.offsetY);var C=p.offsetX-p.pivot.x*p.actualSize.width,D=p.offsetY-p.pivot.y*p.actualSize.height,A={x:C+(.5===p.pivot.x?2*p.pivot.x:p.pivot.x)*p.actualSize.width/2,y:D-30/i.scroller.currentZoom};A=Je(w,A);var x=!!i.selectedItems.annotation,R=!(!x||!OI(i.selectedItems.annotation));if(qr(l.constraints,"Rotate")&&wr(e,A,M)&&i.selectedItems.thumbsConstraints&bt.Rotate){if(x&&R)return"LabelRotate";if(!x)return"Rotate"}if(u.Inflate(b),u.containsPoint(e)&&(S=function Ene(n,t,e,i,r,s){var o;return 1===n.selectedItems.nodes.length&&0===n.selectedItems.connectors.length&&n.selectedItems.nodes[0].container&&(o=function Tne(n,t,e,i,r){var s=10/n.scroller.currentZoom,o=40/n.scroller.currentZoom,a=n.selectedItems,l=t.actualSize.width,h=t.actualSize.height,c=new Ne(i,r,t.style.strokeWidth,h),d=new Ne(i+l,r,t.style.strokeWidth,h),u=new Ne(i,r,l,t.style.strokeWidth),p=new Ne(i,r+h,l,t.style.strokeWidth),f=cs(n,n.selectedItems.nodes[0],!0)?n.nameTable[n.selectedItems.nodes[0].parentId]:n.selectedItems.nodes[0];if(l>=o&&h>=o){if(fa(a.constraints,"ResizeEast",a.thumbsConstraints,a)&&d.containsPoint(e,s))return"ResizeEast";if(fa(a.constraints,"ResizeSouth",a.thumbsConstraints,a)&&p.containsPoint(e,s))return"ResizeSouth";if("Grid"!==f.container.type){if(fa(a.constraints,"ResizeWest",a.thumbsConstraints,a)&&c.containsPoint(e,s))return"ResizeWest";if(fa(a.constraints,"ResizeNorth",a.thumbsConstraints,a)&&u.containsPoint(e,s))return"ResizeNorth"}}return null}(n,t,e,r,s)),!o&&(!n.selectedItems.nodes[0]||!n.selectedItems.nodes[0].isPhase&&!n.selectedItems.nodes[0].isLane&&"SwimLane"!==n.selectedItems.nodes[0].shape.type)&&(o=function Ane(n,t,e,i,r,s){var o=40/n.scroller.currentZoom,a=n.selectedItems.handleSize/2/n.scroller.currentZoom,l=n.selectedItems,h=!!l.annotation;if(t.actualSize.width>=o&&t.actualSize.height>=o){if(fa(l.constraints,"ResizeSouthEast",l.thumbsConstraints,l)&&wr(e,Je(i,{x:r+t.actualSize.width,y:s+t.actualSize.height}),a))return h?"LabelResizeSouthEast":"ResizeSouthEast";if(fa(l.constraints,"ResizeSouthWest",l.thumbsConstraints,l)&&wr(e,Je(i,{x:r,y:s+t.actualSize.height}),a))return h?"LabelResizeSouthWest":"ResizeSouthWest";if(fa(l.constraints,"ResizeNorthEast",l.thumbsConstraints,l)&&wr(e,Je(i,{x:r+t.actualSize.width,y:s}),a))return h?"LabelResizeNorthEast":"ResizeNorthEast";if(fa(l.constraints,"ResizeNorthWest",l.thumbsConstraints,l)&&wr(e,Je(i,{x:r,y:s}),a))return h?"LabelResizeNorthWest":"ResizeNorthWest"}return fa(l.constraints,"ResizeEast",l.thumbsConstraints,l)&&wr(e,Je(i,{x:r+t.actualSize.width,y:s+t.actualSize.height/2}),a)?h?"LabelResizeEast":"ResizeEast":fa(l.constraints,"ResizeWest",l.thumbsConstraints,l)&&wr(e,Je(i,{x:r,y:s+t.actualSize.height/2}),a)?h?"LabelResizeWest":"ResizeWest":fa(l.constraints,"ResizeSouth",l.thumbsConstraints,l)&&wr(e,Je(i,{x:r+t.actualSize.width/2,y:s+t.actualSize.height}),a)?h?"LabelResizeSouth":"ResizeSouth":fa(l.constraints,"ResizeNorth",l.thumbsConstraints,l)&&wr(e,Je(i,{x:r+t.actualSize.width/2,y:s}),a)?h?"LabelResizeNorth":"ResizeNorth":null}(n,t,e,i,r,s)),o||null}(i,p,e,w,C,D),S))return S}}if(Lc(i)&&!n)return"Pan";if((o instanceof Es||o instanceof xc)&&(!Lc(i)||_v(i)||Uv(i))&&(S=function xne(n,t,e,i){if(Bx(t)&&(ga(t,ti.Hover)||ga(t,ti.Visible))){if(t.constraints&ni.Drag)return"PortDrag"}else if(Hx(t)&&(ga(t,ti.Hover)||ga(t,ti.Visible))&&t.constraints&ni.Draw){n.drawingObject={};var r={type:"Orthogonal",sourcePortID:t.id};return n.drawingObject=r,n.tool|=Ci.DrawOnce,n.currentDrawingObject=r,"PortDraw"}return"None"}(i,o),"None"!==S))return S;if((o instanceof Zn||o instanceof Nr)&&!Lc(i)&&Dd(o))return _r(i,o,void 0,t)&&to(o)?"LabelDrag":"LabelSelect";if(null!==n){if(!(n instanceof te||n instanceof de))return"Select";if(t&&t.id){var L=t.id.split(n.id)[1];if(L&&L.match("^_icon"))return"LayoutAnimation"}if(t&&t.id)for(var O=void 0,N=0;N-1)return"FixedUserHandle";if(t instanceof si&&t.hyperlink.link)return"Hyperlink";if(!to(n)||!_r(i,n,!1)||void 0!==i.selectedItems.annotation)return n&&Lc(i)&&!RI(i)?"Pan":i.selectedItems.nodes.length&&i.selectedItems.nodes[0].isLane&&i.selectedItems.wrapper&&i.selectedItems.wrapper.bounds.containsPoint(e)?"Drag":"Select";if(n instanceof de&&!wr(e,n.sourcePoint,n.hitPadding)&&!wr(e,n.targetPoint,n.hitPadding)||!(n instanceof de))return"Drag"}return"Select"}(t,e,this.currentPosition,this.diagram,this.touchStartList,this.touchMoveList,r)},n.prototype.updateContainerBounds=function(t){var e=!1;if(this.diagram.selectedObject.helperObject&&this.diagram.selectedObject.actualObject instanceof te){var i=this.tool instanceof kd,r=this.diagram.selectedObject.actualObject,s=this.diagram.nameTable[r.parentId];t?V3(this.diagram,r,this.currentPosition,i):((!s||s&&"SwimLane"!==s.shape.type)&&this.diagram.updateDiagramObject(r),e=function Ine(n,t,e,i){var r,o=!1;if(cs(n,t,!0)){n.protectPropertyChange(!0);var a=(r=n.nameTable[t.parentId]).wrapper;if(r&&"Canvas"===r.container.type){if(i||a.bounds.x<=e.x&&a.bounds.right>=e.x&&a.bounds.y<=e.y&&a.bounds.bottom>=e.y){var l=void 0,h=a.bounds.y,c=a.bounds.x,d=n.nameTable[r.parentId]||r;if("SwimLane"===d.shape.type)o=$v(r,d,t,n,!0);else{var p=n.nameTable[r.parentId]||r,f=p.shape;l=p.wrapper,a.actualSize.widtha.outerBounds.x)&&(void 0!==r.rowIndex?(l.updateColumnWidth(r.columnIndex,a.outerBounds.width,!0),"Horizontal"===f.orientation&&f.phaseSize&&UI(p,n,a,r.columnIndex),Oc(n,p),n.drag(p,c-a.bounds.x,h-a.bounds.y)):n.scale(r,1+(a.outerBounds.width-a.actualSize.width)/a.actualSize.width,1,a.outerBounds.xa.outerBounds.y)&&(void 0!==r.rowIndex?(l.updateRowHeight(r.rowIndex,a.outerBounds.height,!0),n.drag(p,c-a.bounds.x,h-a.bounds.y)):n.scale(r,1,1+(a.outerBounds.height-a.actualSize.height)/a.actualSize.height,a.outerBounds.yi.y&&(h+=u>0?-1:1,u+=u>0?-1:1):i&&e.wrapper.offsetYi.x&&(h+=u>0?-1:1,u+=u>0?-1:1):i&&e.wrapper.offsetX1&&!(this.diagram.lineRoutingModule&&this.diagram.constraints&rt.LineRouting))for(var b=t.offsetX-this.diagram.selectedItems.offsetX,M=t.offsetY-this.diagram.selectedItems.offsetY,w=t.rotateAngle-this.diagram.selectedItems.rotateAngle,C=0;C-1){var x=c.children;x.splice(x.indexOf(o.id),1),this.diagram.nameTable[o.id].parentId="",i=!0,c.wrapper.children.splice(A,1)}}if(function wne(n,t,e,i){var r=n,s=e.nameTable[r.parentId],o=e.nameTable[r.parentId];if(t&&o&&o.container&&"Stack"===o.container.type&&t.container&&"Stack"===t.container.type&&o.id!==t.parentId){var a=o.wrapper.children.indexOf(r.wrapper);a>-1&&(e.nameTable[r.id].parentId=t.id,o.wrapper.children.splice(a,1))}if(t&&t.parentId&&r.parentId&&"Drag"===i&&o.container&&"Stack"===o.container.type){var l=s.wrapper.children.indexOf(t.wrapper),h=s.wrapper.children.indexOf(r.wrapper),c={targetIndex:l,target:t,sourceIndex:h,source:n};s.wrapper.children.splice(h,1),s.wrapper.children.splice(l,0,r.wrapper),e.commandHandler.addHistoryEntry({type:"StackChildPositionChanged",redoObject:{targetIndex:h,target:t,sourceIndex:l,source:n},undoObject:c,category:"Internal"})}}(o,h,this.diagram,this.action),(c=cs(this.diagram,o)?this.diagram.nameTable[o.parentId]:this.diagram.nameTable[o.parentId]||o)&&c.container&&"Canvas"===c.container.type&&(c.wrapper.maxWidth=c.maxWidth=c.wrapper.actualSize.width,c.wrapper.maxHeight=c.maxHeight=c.wrapper.actualSize.height,e=!0),cs(this.diagram,o,!0)&&c&&"Canvas"===c.container.type)if(this.diagram.selectedItems.nodes.length>1)for(C=0;C0)for(var i=0;i0&&e.columnIndex>0||l&&e.isLane)){if("Horizontal"===t.container.orientation&&e.isPhase&&e.wrapper.width>e.maxWidth&&(e.maxWidth=e.wrapper.width,e.wrapper.maxWidth=e.wrapper.width),h.updateColumnWidth(e.columnIndex,r.width,!0,c),Ux(this.diagram,e,t),e.isPhase){var f=this.diagram.nameTable[""+t.shape.phases[e.columnIndex].header.id];f.maxWidth0?(r=new sf(t,"",u),t.shape.classShape.attributes.push(r)):i.id.includes("_umlMethods")&&t.shape.classShape.methods.length>0&&(s=new hm(t,"",u),t.shape.classShape.methods.push(s))),"Interface"===t.shape.classifier&&(i.id.includes("_umlProperty")&&t.shape.interfaceShape.attributes.length>0?(r=new sf(t,"",u),t.shape.classShape.attributes.push(r)):i.id.includes("_umlMethods")&&t.shape.interfaceShape.methods.length>0&&(s=new hm(t,"",u),t.shape.interfaceShape.methods.push(s))),"Enumeration"===t.shape.classifier&&i.id.includes("_umlMember")&&t.shape.enumerationShape.members.length>0){var p=new ab(t,"",u);t.shape.enumerationShape.members.push(p)}t.wrapper.children.indexOf(c.wrapper),this.diagram.enableServerDataBinding(!0),this.diagram.add(c),this.diagram.updateConnectorEdges(t),this.diagram.clearSelection(),this.diagram.select([this.diagram.nameTable[c.id]]),this.diagram.endGroupAction(),this.diagram.startTextEdit()}}},n}(),joe=function(){function n(){}return n.prototype.findObjectsUnderMouse=function(t,e,i,r,s){var o=[];r&&r instanceof oi&&r.nodes.length+r.connectors.length===1&&(r=r.nodes[0]||r.connectors[0]).children&&0===r.children.length&&(i.actualObject=r);for(var a,l,h,c,f,d=r&&r instanceof de&&(r.constraints&qe.ConnectToNearByNode||r.constraints&qe.ConnectToNearByPort)&&r.connectionPadding||0,p={},g=0,v=e.spatialSearch.findObjects(new Ne(t.x-50-d,t.y-50-d,100+d,100+d));g-1&&o.splice(T,1),"UmlClassifier"===y.shape.type&&y.container&&"Stack"===y.container.type&&(T=o.indexOf(e.nameTable[e.nameTable[y.id].wrapper.children[0].id]))>-1&&o.splice(T,1)}for(var P=0;Ps.zIndex&&(t[parseInt(r.toString(),10)]=l),r>0&&i&&a&&(a.isLane||a.isPhase||a.isHeader)&&t[parseInt(r.toString(),10)].zIndex=2)for(var d=t.length-1;d>=0;d--)if(t[parseInt(d.toString(),10)].parentId){var u=sm(t[parseInt(d.toString(),10)],e,""),p=sm(t[d-1],e,""),g=e.nameTable[""+p];g&&u!==p&&e.nameTable[""+u].zIndex=0;f--){d=ef(e[parseInt(f.toString(),10)],!1),c=ef(e[parseInt(f.toString(),10)],!0);var g=t[""+l].tool,v=this.findTargetElement(e[parseInt(f.toString(),10)].wrapper,o,t,void 0);if("Draw"===i&&v&&(e[parseInt(f.toString(),10)]instanceof te||e[parseInt(f.toString(),10)]instanceof de)&&!nb(e[parseInt(f.toString(),10)],v)&&(g&&"ConnectorSourceEnd"===g[""+h]&&!Nh(e[parseInt(f.toString(),10)])||g&&"ConnectorTargetEnd"===g[""+h]&&!da(e[parseInt(f.toString(),10)])))return u;if(e[parseInt(f.toString(),10)]instanceof te||e[parseInt(f.toString(),10)]instanceof de&&(Nh(e[parseInt(f.toString(),10)])||xd(d)||da(e[parseInt(f.toString(),10)])||Lh(c)||"PortDraw"===i&&g instanceof Od&&"ConnectorTargetEnd"===g[""+h]&&(da(e[parseInt(f.toString(),10)])||Lh(c))))return u=e[parseInt(f.toString(),10)],p&&(u=this.isTarget(u,t,i)),s.actualObject=u,u}else if("ConnectorTargetEnd"===i&&a){for(f=e.length-1;f>=0;f--)if(c=ef(e[parseInt(f.toString(),10)],!0),(e[parseInt(f.toString(),10)]instanceof te||e[parseInt(f.toString(),10)]instanceof de)&&(da(e[parseInt(f.toString(),10)])||Lh(c)))return u=e[parseInt(f.toString(),10)],u=this.isTarget(u,t,i),s.actualObject=u,u}else{if(a&&("Drag"===i||t[""+l].tool instanceof ua)){var y=0;for(f=0;f=S.zIndex?u:S,y=Math.max(y,S.zIndex)):y=(u=S).zIndex)}return u&&"Bpmn"===u.shape.type&&(t.selectedItems.nodes.length>0&&"Bpmn"===t.selectedItems.nodes[0].shape.type||(u=null)),u&&(s.actualObject=u),u}if("Select"!==i&&"Pan"!==i||!t[""+l].tool)if("Pan"===i||"LayoutAnimation"===i){for(f=e.length-1;f>=0;f--)if((e[parseInt(f.toString(),10)]instanceof te||e[parseInt(f.toString(),10)]instanceof de)&&(v=this.findTargetElement(e[parseInt(f.toString(),10)].wrapper,o,t,void 0),"Pan"===i||v&&(v.id.match("_icon_content_shape$")||v.id.match("_icon_content_rect$"))))return e[parseInt(f.toString(),10)]}else u=e[e.length-1],s&&u&&(s.actualObject=u);else{for(f=e.length-1;f>=0;f--)if(e[parseInt(f.toString(),10)]instanceof de){var b=e[f-1];if(e[f-1]instanceof te&&b.ports){if((v=this.findTargetElement(b.wrapper,o,t,void 0))&&(v.id.match("_icon_content_shape$")||v.id.match("_icon_content_rect$")))return b;for(var M=0;M=0;s--){var o=t.children[parseInt(s.toString(),10)];if(o&&o.outerBounds.containsPoint(e,r||0))if(o.visible){if(o instanceof Cs){var a=this.findTargetElement(o,e,i);if(a)return a}var l="Clip"===o.style.textOverflow||"Ellipsis"===o.style.textOverflow;if(o.bounds.containsPoint(e,r||0)&&!l)return o;if(t.bounds.containsPoint(e,r||0)&&l)return o}else if(o instanceof Ke&&t&&t.id){var h=void 0;if(t.id.includes("group_container")){var c=t.id.slice(0,-15);h=i.getObject(c)}else h=i.getObject(t.id);if(ib(h,o.id))return o}}return t.bounds.containsPoint(e,r)&&"none"!==t.style.fill?t:null},n}(),Voe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),af=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},JF=function(n){function t(e,i,r,s){var o=n.call(this,e,i,r,s)||this;return o.objectZIndex=-1,o.zIndexTable={},o.objects=[],o}return Voe(t,n),af([I("")],t.prototype,"id",void 0),af([I(!0)],t.prototype,"visible",void 0),af([I(!1)],t.prototype,"lock",void 0),af([I()],t.prototype,"objects",void 0),af([I()],t.prototype,"addInfo",void 0),af([I(-1)],t.prototype,"zIndex",void 0),t}(Ee),wT=function(n,t,e,i){return new(e||(e=Promise))(function(r,s){function o(h){try{l(i.next(h))}catch(c){s(c)}}function a(h){try{l(i.throw(h))}catch(c){s(c)}}function l(h){h.done?r(h.value):new e(function(c){c(h.value)}).then(o,a)}l((i=i.apply(n,t||[])).next())})},CT=function(n,t){var i,r,s,o,e={label:0,sent:function(){if(1&s[0])throw s[1];return s[1]},trys:[],ops:[]};return o={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function a(h){return function(c){return function l(h){if(i)throw new TypeError("Generator is already executing.");for(;e;)try{if(i=1,r&&(s=2&h[0]?r.return:h[0]?r.throw||((s=r.return)&&s.call(r),0):r.next)&&!(s=s.call(r,h[1])).done)return s;switch(r=0,s&&(h=[2&h[0],s.value]),h[0]){case 0:case 1:s=h;break;case 4:return e.label++,{value:h[1],done:!1};case 5:e.label++,r=h[1],h=[0];continue;case 7:h=e.ops.pop(),e.trys.pop();continue;default:if(!(s=(s=e.trys).length>0&&s[s.length-1])&&(6===h[0]||2===h[0])){e=0;continue}if(3===h[0]&&(!s||h[1]>s[0]&&h[1]1)for(var i=0;i-1)return e[parseInt(i.toString(),10)];return this.diagram.activeLayer},n.prototype.getLayer=function(t){for(var e=this.diagram.layers,i=0;i=0;o--)this.diagram.unSelect(this.diagram.nameTable[s[parseInt(o.toString(),10)]]),this.diagram.remove(this.diagram.nameTable[s[parseInt(o.toString(),10)]]),"default_layer"!==i.id&&this.diagram.activeLayer.id===t&&(this.diagram.activeLayer=this.diagram.layers[this.diagram.layers.length-1]);delete this.diagram.layerZIndexTable[i.zIndex],this.diagram.layers.splice(r,1),"SVG"!==this.diagram.mode&&this.diagram.refreshDiagramLayer()}},n.prototype.moveObjects=function(t,e){this.diagram.startGroupAction();for(var i={},r=[],s=0;s-1){if(r=[],(h=this.diagram.nameTable[""+s]).children)for(var f=0,g=h.children;f0){for(var y=void 0,S=0,b=r;S0)for(var r=0;r0)for(r=0;r0){t=t.concat(this.diagram.selectedItems.connectors);for(var i=0;i0)for(t=t.concat(this.diagram.selectedItems.nodes),i=0;i0){for(var i=0,r=t.shape.activity.subProcess.processes;i0&&this.copyProcesses(this.processTable[""+s])}this.clipboardData.processTable=this.processTable}},n.prototype.group=function(){this.oldSelectedObjects=rm(this.diagram);var e=this.diagram.isProtectedOnChange;this.diagram.protectPropertyChange(!0),this.diagram.diagramActions=this.diagram.diagramActions|ee.Group;var r={};r.id="group"+Qe(),(r=new te(this.diagram,"nodes",r,!0)).children=[];for(var s=this.diagram.selectedItems.nodes.concat(this.diagram.selectedItems.connectors).sort(function(h,c){return h.zIndex-c.zIndex}),o=0;o0){var a=this.diagram.add(r);a&&this.select(a),this.addHistoryEntry({type:"Group",undoObject:r,redoObject:r,category:"Internal"}),this.diagram.diagramActions=this.diagram.diagramActions&~ee.Group,this.diagram.protectPropertyChange(e)}},n.prototype.unGroup=function(t){var i=this.diagram.isProtectedOnChange;this.diagram.protectPropertyChange(!0),this.diagram.diagramActions=this.diagram.diagramActions|ee.Group;var r=[];t?r.push(t):r=this.diagram.selectedItems.nodes,this.diagram.startGroupAction();for(var s=0;s0&&this.diagram.removePorts(o,o.ports),o.annotations&&o.annotations.length>0&&!ce()&&this.diagram.removeLabels(o,o.annotations);for(var c=this.diagram.nameTable[o.parentId],d=o.children.length-1;d>=0;d--)this.diagram.nameTable[o.children[parseInt(d.toString(),10)]].parentId="",this.diagram.deleteChild(this.diagram.nameTable[o.children[parseInt(d.toString(),10)]],o),o.parentId&&o.children[parseInt(d.toString(),10)]&&this.diagram.addChild(c,o.children[parseInt(d.toString(),10)]);this.resetDependentConnectors(o.inEdges,!0),this.resetDependentConnectors(o.outEdges,!1),this.diagram.diagramActions&ee.UndoRedo||this.addHistoryEntry({type:"UnGroup",undoObject:a,redoObject:a,category:"Internal"}),o.parentId&&this.diagram.deleteChild(o,c)}this.diagram.removeNode(o,l),this.clearSelection()}this.diagram.endGroupAction(),this.diagram.diagramActions=this.diagram.diagramActions&~ee.Group,this.diagram.protectPropertyChange(i)},n.prototype.resetDependentConnectors=function(t,e){for(var i=0;i0&&(g=!1)}if(g){var y=this.cloneConnector(p,i);c.push(y),o[h.id]=y.id}}else{var S=this.cloneNode(h,i);if(c.push(S),S){o[h.id]=S.id;var b=h.inEdges;if(b)for(var M=0,w=b;M0)for(var u=0;u0)for(r=t.segments,s=0;s0&&this.diagram.drawingObject&&"Bezier"===this.diagram.drawingObject.type&&(t.segments=[]);var e=this.diagram.add(t);"SVG"!==this.diagram.mode&&this.diagram.refreshDiagramLayer(),this.selectObjects([e]),t&&!zI(this.diagram)&&(this.diagram.tool&=~Ci.DrawOnce,this.diagram.currentDrawingObject=void 0)},n.prototype.enableServerDataBinding=function(t){this.diagram.enableServerDataBinding(t)},n.prototype.addText=function(t,e){var i=this.diagram.findElementUnderMouse(t,e,this.diagram);this.diagram.startTextEdit(t,i instanceof si?i.id.split("_")[1]:void 0)},n.prototype.isUserHandle=function(t){var e=this.diagram.selectedItems;if(e.wrapper&&qr(e.constraints,"UserHandle"))for(var i=0,r=e.userHandles;i0&&t[0]&&t[0].isLane)for(s=this.diagram.getObject(t[0].parentId),t[0].shape.header=[],a=0;a1||e&&1===t.length)){if(1!==t.length)return[2];this.clearSelection()}if(!(u||d||1!==t.length||e&&Xa(this.diagram)))return this.clearSelection(),[2]}if(!r.cancel){for(p=0;p0||e)&&f.children&&!f.parentId)for(g=0;g0||e,!0)}else this.select(f,p>0||e,!0);void 0===i&&(i=c),r={oldValue:i||[],newValue:this.getSelectedObject(),cause:this.diagram.diagramActions,state:"Changed",type:"Addition",cancel:!1},this.diagram.renderSelector(e||t&&t.length>1),ce()||this.diagram.triggerEvent(Ce.selectionChange,r),this.diagram.enableServerDataBinding(!0)}return[2]})})},n.prototype.findParent=function(t){return t.parentId&&this.findParent(t=this.diagram.nameTable[t.parentId]),t},n.prototype.selectProcesses=function(t){if(this.hasProcesses(t))for(var e=t.shape.activity.subProcess.processes,i=0;i0)},n.prototype.select=function(t,e,i){var r=this.getObjectLayer(t.id);if(Dd(t)&&!(t instanceof oi)&&!_r(this.diagram,t)&&r&&!r.lock&&r.visible&&t.wrapper.visible){(e=!!Xa(this.diagram)&&e)||this.clearSelection(),this.diagram.enableServerDataBinding(!1);var s=this.diagram.selectedItems;if(t instanceof te?s.nodes.push(t.isHeader?this.diagram.nameTable[t.parentId]:t):s.connectors.push(t),s.selectedObjects.push(t),e)s.wrapper.rotateAngle=s.rotateAngle=0,s.wrapper.children.push(t.wrapper);else if(s.init(this.diagram),1===s.nodes.length&&0===s.connectors.length){var l=jx(this.diagram,s);l&&(s.wrapper.children[0]=l),s.rotateAngle=s.nodes[0].rotateAngle,s.wrapper.rotateAngle=s.nodes[0].rotateAngle,s.wrapper.pivot=s.nodes[0].pivot}i||this.diagram.renderSelector(e),this.diagram.enableServerDataBinding(!0)}},n.prototype.labelSelect=function(t,e){this.oldSelectedObjects=rm(this.diagram);var i=this.diagram.selectedItems,r=this.diagram.allowServerDataBinding;this.diagram.allowServerDataBinding=!1,i.nodes=i.connectors=[],this.diagram.allowServerDataBinding=r,t instanceof te?i.nodes[0]=t:i.connectors[0]=t,i.annotation=this.findTarget(e,t),i.init(this.diagram),this.diagram.renderSelector(!1)},n.prototype.unSelect=function(t){var e=this.diagram.selectedItems.nodes.concat(this.diagram.selectedItems.connectors),i=e.filter(function(a){return a.id!==t.id}),r={oldValue:e,newValue:i,cause:this.diagram.diagramActions,state:"Changing",type:"Removal",cancel:!1};if(this.diagram.currentSymbol||ce()||this.diagram.triggerEvent(Ce.selectionChange,r),_r(this.diagram,t)){var s=this.diagram.selectedItems,o=void 0;t instanceof te?(o=s.nodes.indexOf(t,0),s.nodes.splice(o,1)):(o=s.connectors.indexOf(t,0),s.connectors.splice(o,1)),o=s.selectedObjects.indexOf(t,0),s.selectedObjects.splice(o,1),(r={oldValue:e,newValue:i,cause:this.diagram.diagramActions,state:"Changed",type:"Removal",cancel:(r={oldValue:e,newValue:i,cause:this.diagram.diagramActions,state:"Changed",type:"Removal",cancel:!1}).cancel}).cancel||(o=s.wrapper.children.indexOf(t.wrapper,0),s.wrapper.children.splice(o,1),this.diagram.updateSelector(),this.diagram.currentSymbol||this.diagram.triggerEvent(Ce.selectionChange,r))}},n.prototype.moveSvgNode=function(t,e){var i=xt(e+"_groupElement",this.diagram.element.id),r=xt(t+"_groupElement",this.diagram.element.id);i.parentNode.insertBefore(r,i)},n.prototype.moveAfterSvgNode=function(t,e){var i=xt(e+"_groupElement",this.diagram.element.id),r=xt(t+"_groupElement",this.diagram.element.id);i.insertAdjacentElement("afterend",r)},n.prototype.sendLayerBackward=function(t){var e=this.getLayer(t);if(e&&0!==e.zIndex){var i=e.zIndex;if("SVG"===this.diagram.mode){var r=e.objects,s=this.getLayer(this.diagram.layerZIndexTable[i-1]).objects[0];if(s)for(var o=0,a=r;od&&"SwimLane"!==f.shape.type){var S=$(f);f.zIndex=d-((-1!==i.indexOf(f)?i.indexOf(f):0)+1),f.children&&(d=this.findLowestZIndex(f,c)||d),this.triggerOrderCommand(S,f,f),f.children&&this.updateGroupZindex(f,"SendToBack",d)}else"SwimLane"===f.shape.type&&(y=this.swapZIndexObjects(a,h,r,g));if("SVG"===this.diagram.mode){for(var M="SwimLane"!==this.diagram.nameTable[""+r].shape.type?d:y,w=h[parseInt(M.toString(),10)];!w&&Md)&&(d=p.zIndex)}for(var f=JSON.parse(JSON.stringify(l)),v=Number(Object.keys(l).sort(function(wo,Hl){return Number(wo)-Number(Hl)}).reverse()[0]),y=this.diagram.nameTable[""+e].zIndex,S=[],M=0;M<=v;M++)S.push(l[parseInt(M.toString(),10)]);if("SwimLane"===this.diagram.nameTable[""+e].shape.type)for(var C=v;C>=y;C--)if(l[parseInt(C.toString(),10)]&&this.diagram.nameTable[l[parseInt(C.toString(),10)]].parentId!==e){v=C;break}var D=this.diagram.nameTable[""+e];if(D.zIndexx&&(x=L.zIndex)}}else x=d;D.zIndex=x+((-1!==r.indexOf(D)?r.indexOf(D):0)+1),this.triggerOrderCommand(A,D,D)}else if("SwimLane"===D.shape.type){for(var O=0,N=-1,T=0,P=0,_=JSON.parse(JSON.stringify(l)),B=0;B<=y;B++)if(l[parseInt(B.toString(),10)]&&this.diagram.nameTable[l[parseInt(B.toString(),10)]].parentId===e&&-1===N){N=B,T=B;break}for(var j=0;j<=v;j++)f[parseInt(j.toString(),10)]&&f[parseInt(j.toString(),10)]!==e&&this.diagram.nameTable[f[parseInt(j.toString(),10)]].parentId!==e&&this.diagram.nameTable[f[parseInt(j.toString(),10)]].zIndex>=this.diagram.nameTable[""+e].zIndex&&O++;for(var ue=N,pe=0;pe<=O;pe++){for(;!l[parseInt(ue.toString(),10)];)ue++;P=this.diagram.nameTable[l[parseInt(ue.toString(),10)]].zIndex,ue++}for(var Me=P;Me<=v;Me++){for(;!_[parseInt(N.toString(),10)];)N++;for(;!l[parseInt(Me.toString(),10)];)Me++;l[parseInt(Me.toString(),10)]=_[parseInt(N.toString(),10)],this.diagram.nameTable[l[parseInt(Me.toString(),10)]].zIndex=Me,N++}l[parseInt(v.toString(),10)]=this.diagram.nameTable[""+e].id,this.diagram.nameTable[""+e].zIndex=v,ue=y+1;for(var De=T,xe=0;xe0&&("Native"===hr[0].shape.type||"HTML"===hr[0].shape.type)){for(Mi.parentNode.removeChild(Mi),De=0;De0?r[0]:null},n.prototype.findLowestZIndex=function(t,e){var r=this.diagram.nodes.filter(function(s){return-1!==e.indexOf(s.id)}).filter(function(s){return""===s.parentId&&s.id!==t.id}).map(function(s){return s.zIndex});return r.sort(function(s,o){return s-o}),r.length>0?r[0]:null},n.prototype.triggerOrderCommand=function(t,e,i){var s={zIndex:$(t).zIndex},o={zIndex:e.zIndex},a={element:i,cause:this.diagram.diagramActions,diagramAction:this.diagram.getDiagramAction(this.diagram.diagramActions),oldValue:s,newValue:o};this.diagram.triggerEvent(Ce.propertyChange,a)},n.prototype.checkGroupNode=function(t,e,i){return i[""+e].parentId===i[""+t].parentId},n.prototype.sortByZIndex=function(t,e,i){if("BringForward"===i){var r=e||"zIndex";t=t.sort(function(o,a){return a[""+r]-o[""+r]})}else{var s=e||"zIndex";t=t.sort(function(o,a){return o[""+s]-a[""+s]})}return t},n.prototype.orderCommands=function(t,e,i){var r=this,s=e.nodes;if(s=s.concat(e.connectors),t)if("SendBackward"===i)for(var o=0;oa}),S=v.filter(function(D){return D0?Math.max.apply(Math,S):a,M=y.length>0?Math.min.apply(Math,y):a;if(a!==M){var w=c.zIndexTable[parseInt(M.toString(),10)],C=c.zIndexTable[parseInt(a.toString(),10)];this.moveSvgNode(C,w)}else"SendToBack"===i&&(w=c.zIndexTable[parseInt(a.toString(),10)],C=c.zIndexTable[parseInt(b.toString(),10)],this.moveAfterSvgNode(w,C))}}else this.diagram.refreshCanvasLayers()}},n.prototype.sendForward=function(t){var e=this;if(this.diagram.protectPropertyChange(!0),Xa(this.diagram)||t){$(t||(this.diagram.selectedItems.nodes.length?this.diagram.selectedItems.nodes[0]:this.diagram.selectedItems.connectors[0]));var s=t&&t.id,o=this.diagram.layers.indexOf(this.getObjectLayer(s=s||(this.diagram.selectedItems.nodes.length?this.diagram.selectedItems.nodes[0].id:this.diagram.selectedItems.connectors[0].id))),a=$(this.diagram.nameTable),h=(parseInt(o.toString(),10),this.diagram.nameTable[""+s]),c=[],d=this.diagram.spatialSearch.findObjects(h.wrapper.bounds);d.length>2&&(d=this.sortByZIndex(d,void 0,"BringForward"));for(var u=0,p=d;u=0;f--)this.diagram.nameTable[c[parseInt(f.toString(),10)].id].parentId===s&&c.splice(f,1);if(c.length>0){var y=this.diagram.nameTable[c[c.length-1].id];if(y.parentId){var b=sm(y,this.diagram,""),M=this.diagram.nameTable[""+b];M.id!==s&&(c[0]=M)}var w={};for(f=0;f0&&(Object.values(O).forEach(function(ue){ue>=T&&N.push(ue)}),0!==N.length&&this.updateZIndexBySendForward(h,N,o))}var P=[];if(Object.keys(this.changedNodeZIndexes).forEach(function(ue){if((a[""+ue]?a[""+ue].zIndex:null)!==e.changedNodeZIndexes[""+ue]){var De=$(a[""+ue]);P.push(De)}}),this.updateLayerZindexTable(o),L.nodes.splice(0,L.nodes.length),P.forEach(function(ue){var pe=$(ue);L.nodes.push(pe)}),"SVG"===this.diagram.mode){var _=c[c.length-1].id,B=c[c.length-1];B&&!("HTML"===B.shape.type||"Native"===B.shape.type)&&this.moveAfterSvgNode(s,_),this.updateNativeNodeIndex(_,s)}else this.diagram.refreshCanvasLayers();var j=[];Object.keys(this.changedNodeZIndexes).forEach(function(ue){if((a[""+ue]?a[""+ue].zIndex:null)!==e.changedNodeZIndexes[""+ue]){var De=$(e.diagram.nameTable[""+ue]);j.push(De)}});var Q=$(this.diagram.selectedItems);Q.nodes.splice(0,Q.nodes.length),j.forEach(function(ue){var pe=$(ue);Q.nodes.push(pe)}),this.diagram.diagramActions&ee.UndoRedo||this.addHistoryEntry({type:"SendForward",category:"Internal",undoObject:L,redoObject:Q}),this.diagram.endGroupAction()}}this.diagram.protectPropertyChange(!1)},n.prototype.updateZIndexBySendForward=function(t,e,i){var r=$(t);t.zIndex=Math.min.apply(Math,e);var a,s=Math.min.apply(Math,e),o=Math.min.apply(Math,e),l=this.diagram.layers[parseInt(i.toString(),10)].objects,h=this.diagram.nodes.filter(function(S){return-1!==l.indexOf(S.id)});t.children&&this.updateGroupZindex(t,"BringForward",t.zIndex);var c=h.filter(function(S){return S.zIndex===Math.min.apply(Math,e)&&S.id!==t.id});if(c&&c.length>0&&c[0].children){for(var d=Math.min.apply(Math,e),u=0;uo&&g!==t&&g.parentId!==t.id&&c&&c.length>0&&g.parentId!==c[0].id){var v=$(g);g.zIndex=a+1,a++,this.triggerOrderCommand(v,g,g)}var y=g.zIndex;this.changedNodeZIndexes[g.id]=(this.changedNodeZIndexes.hasOwnProperty(g.id),y)}},n.prototype.arrangeZIndexForLowerNodes=function(t,e,i){var r=i.filter(function(o){return o.zIndex<=t&&o.parentId!==e.id});r.sort(function(o,a){return a.zIndex-o.zIndex});for(var s=0;se&&(e=r.zIndex)}return e},n.prototype.sendBackward=function(t){var e=this;if(this.diagram.protectPropertyChange(!0),Xa(this.diagram)||t){$(t||(this.diagram.selectedItems.nodes.length?this.diagram.selectedItems.nodes[0]:this.diagram.selectedItems.connectors[0]));var s=t&&t.id,o=this.diagram.layers.indexOf(this.getObjectLayer(s=s||(this.diagram.selectedItems.nodes.length?this.diagram.selectedItems.nodes[0].id:this.diagram.selectedItems.connectors[0].id))),a=$(this.diagram.nameTable),h=(parseInt(o.toString(),10),this.diagram.nameTable[""+s]),c=[],d=this.diagram.spatialSearch.findObjects(h.wrapper.bounds);d.length>2&&(d=this.sortByZIndex(d));for(var u=0,p=d;uNumber(f.zIndex)&&""===f.parentId&&h.wrapper.bounds.intersects(f.wrapper.bounds)&&c.push(f);for(var f=c.length-1;f>=0;f--)(v=this.diagram.nameTable[c[parseInt(f.toString(),10)].id]).parentId===s&&c.splice(f,1);if(c.length>0){var v;if((v=this.diagram.nameTable[c[c.length-1].id]).parentId){var S=sm(v,this.diagram,""),b=this.diagram.nameTable[""+S];s!==b.id&&(c[c.length-1]=b)}var M={};for(f=0;f0&&(Object.values(L).forEach(function(pe){pe<=N&&O.push(pe)}),0!==O.length&&this.updateZIndexBySendBackward(h,O,o))}var T=[];if(Object.keys(this.changedNodeZIndexes).forEach(function(pe){if((a[""+pe]?a[""+pe].zIndex:null)!==e.changedNodeZIndexes[""+pe]){var xe=$(a[""+pe]);T.push(xe)}}),this.updateLayerZindexTable(o),R.nodes.splice(0,R.nodes.length),T.forEach(function(pe){var Me=$(pe);R.nodes.push(Me)}),"SVG"===this.diagram.mode){var P=c[c.length-1].id,_=c[c.length-1];_&&"HTML"!==_.shape.type&&"Native"!==_.shape.type&&this.moveSvgNode(s,P);var B=this.diagram.nameTable[""+P];B.children&&B.children.length>0?this.updateNativeNodeIndex(s):this.updateNativeNodeIndex(s,P)}else this.diagram.refreshCanvasLayers();var j=[];Object.keys(this.changedNodeZIndexes).forEach(function(pe){if((a[""+pe]?a[""+pe].zIndex:null)!==e.changedNodeZIndexes[""+pe]){var xe=$(e.diagram.nameTable[""+pe]);j.push(xe)}});var Q=$(this.diagram.selectedItems);Q.nodes.splice(0,Q.nodes.length),j.forEach(function(pe){var Me=$(pe);Q.nodes.push(Me)}),this.diagram.diagramActions&ee.UndoRedo||this.addHistoryEntry({type:"SendBackward",category:"Internal",undoObject:R,redoObject:Q}),this.diagram.endGroupAction()}}this.diagram.protectPropertyChange(!1)},n.prototype.updateZIndexBySendBackward=function(t,e,i){var r=$(t);t.zIndex=Math.max.apply(Math,e);var p,s=t.zIndex,o=Math.max.apply(Math,e),a=this.diagram.layers[parseInt(i.toString(),10)].objects,l=this.diagram.nodes.filter(function(S){return-1!==a.indexOf(S.id)}),h=l.filter(function(S){return S.zIndex===Math.max.apply(Math,e)&&S.id!==t.id});if(h&&h.length>0&&h[0].children)for(var c=Math.max.apply(Math,e),d=0;d0&&g.parentId!==h[0].id){var v=$(g);g.zIndex=p-1,p--,this.triggerOrderCommand(v,g,g)}var y=g.zIndex;this.changedNodeZIndexes[""+g.id]=(this.changedNodeZIndexes.hasOwnProperty(g.id),y)}},n.prototype.findLowestChildZIndex=function(t){for(var e=t.zIndex,i=0;i0),this.selectObjects([t],!0))},n.prototype.clearSelection=function(t,e){return wT(this,void 0,void 0,function(){var i,r,s,o;return CT(this,function(a){return i=this.diagram.allowServerDataBinding,this.diagram.enableServerDataBinding(!1),Xa(this.diagram)&&(r=this.diagram.selectedItems,s=this.getSelectedObject(),this.diagram.currentSymbol&&(this.diagram.previousSelectedObject=s),o={oldValue:s,newValue:[],cause:this.diagram.diagramActions,state:"Changing",type:"Removal",cancel:!1},t&&(ce()||this.diagram.triggerEvent(Ce.selectionChange,o)),o.cancel||(r.offsetX=0,r.offsetY=0,r.width=0,r.height=0,r.rotateAngle=0,r.nodes=[],r.connectors=[],r.wrapper=null,r.annotation=void 0,r.selectedObjects=[],this.diagram.clearSelectorLayer(),t&&(o={oldValue:s,newValue:[],cause:this.diagram.diagramActions,state:"Changed",type:"Removal",cancel:!1},ce()||this.diagram.triggerEvent(Ce.selectionChange,o))),this.diagram.enableServerDataBinding(i)),[2]})})},n.prototype.clearSelectedItems=function(){this.clearSelection((this.diagram.selectedItems.nodes?this.diagram.selectedItems.nodes.length:0)+(this.diagram.selectedItems.connectors?this.diagram.selectedItems.connectors.length:0)>0)},n.prototype.removeStackHighlighter=function(){var t=Pl(this.diagram.element.id),e=t.getElementById(t.id+"_stack_highlighter");e&&e.parentNode.removeChild(e)},n.prototype.renderStackHighlighter=function(t,e){var r,s,o,i=this.diagram.selectedItems.nodes[0];if(!e){var a=this.diagram.findObjectsUnderMouse(t.position);if((e=this.diagram.findObjectUnderMouse(a,"Drag",!0))&&!(e.isLane||e.isPhase||e.isHeader))for(var l=0;l0)for(var a=0;a1)if(i){var h=l.segments[0],c=l.segments[1],u=Tc(CI(t.wrapper,t.wrapper.corners,t.wrapper.bounds),h.direction),g=Ll({corners:void 0,point:u=Ah(l,0,u,{x:l.sourceWrapper.offsetX,y:l.sourceWrapper.offsetY},!1),margin:void 0,direction:h.direction},{corners:void 0,point:c.points[1],margin:void 0,direction:void 0});h.length=z.distancePoints(g[0],g[1]),c.direction&&c.length&&(c.length=z.distancePoints(g[1],g[2]))}else if(o){switch(l.segments[0].direction){case"Bottom":r=t.wrapper.bounds.bottomCenter.x-e.bottomCenter.x,s=t.wrapper.bounds.bottomCenter.y-e.bottomCenter.y;break;case"Top":r=t.wrapper.bounds.topCenter.x-e.topCenter.x,s=t.wrapper.bounds.topCenter.y-e.topCenter.y;break;case"Left":r=t.wrapper.bounds.middleLeft.x-e.middleLeft.x,s=t.wrapper.bounds.middleLeft.y-e.middleLeft.y;break;case"Right":r=t.wrapper.bounds.middleRight.x-e.middleRight.x,s=t.wrapper.bounds.middleRight.y-e.middleRight.y}this.dragSourceEnd(l,r,s,!0,null,"ConnectorSourceEnd",void 0,void 0,void 0,!(t.parentId&&this.diagram.diagramActions&ee.isGroupDragging))}}},n.prototype.updateEndPoint=function(t,e){var r={sourcePoint:t.sourcePoint,targetPoint:t.targetPoint};t.sourceID&&(r.sourceID=t.sourceID),t.targetID&&(r.targetID=t.targetID),t.sourcePortID&&(r.sourcePortID=t.sourcePortID),t.targetPortID&&(r.targetPortID=t.targetPortID),t.segments&&(r.segments=t.segments),this.diagram.connectorPropertyChange(t,e||{},r),this.diagram.updateSelector()},n.prototype.dragSourceEnd=function(t,e,i,r,s,o,a,l,h,c,d){var u=this.diagram.nameTable[t.id],p={},f=this.checkBoundaryConstraints(e,i,u.wrapper.bounds);if(AI(u)&&f&&"BezierSourceThumb"!==o&&Vv(this.diagram)&&(p=$(p={sourcePoint:u.sourcePoint}),u.sourcePoint.x+=e,u.sourcePoint.y+=i,"ConnectorSourceEnd"===o&&"Orthogonal"===u.type&&this.changeSegmentLength(u,l,h,c),"Bpmn"===u.shape.type&&"Default"===u.shape.sequence&&"Sequence"===u.shape.flow&&this.updatePathElementOffset(u)),"Bezier"===u.type)if(p={sourcePoint:u.sourcePoint},d)this.translateBezierPoints(t,""===o?"ConnectorSourceEnd":o,e,i,d,s,!a);else for(var g=0;g2){var d=z.direction((c=t.segments[2]).points[0],c.points[1]);o.direction===ls(d)?("Right"===o.direction?c.points[0].x=o.points[o.points.length-1].x=l.wrapper.corners.middleRight.x+20:"Left"===o.direction?c.points[0].x=o.points[o.points.length-1].x=l.wrapper.corners.middleLeft.x-20:c.points[0].y=o.points[o.points.length-1].y="Top"===o.direction?l.wrapper.corners.topCenter.y-20:l.wrapper.corners.bottomCenter.y+20,c.direction&&c.length&&(c.length=z.distancePoints(c.points[0],c.points[c.points.length-1])),o.length=z.distancePoints(o.points[0],o.points[o.points.length-1])):o.direction===d&&c.direction&&c.length?("Top"===o.direction||"Bottom"===o.direction?(c.points[0]=o.points[0],c.points[c.points.length-1].x=c.points[0].x):(c.points[0]=o.points[0],c.points[c.points.length-1].y=c.points[0].y),c.length=z.distancePoints(c.points[0],c.points[c.points.length-1]),t.segments.splice(0,2)):o.length=20}else o.length=20;else if(o.length<1)if(""!==t.sourceID){var c;"Right"===a.direction?a.points[a.points.length-1].y=(h=l.wrapper.corners.middleRight).y:"Left"===a.direction?a.points[a.points.length-1].y=(h=l.wrapper.corners.middleLeft).y:a.points[a.points.length-1].x="Top"===a.direction?(h=l.wrapper.corners.topCenter).x:(h=l.wrapper.corners.bottomCenter).x,a.length=z.distancePoints(h,a.points[a.points.length-1]),t.segments.length>2&&(c=t.segments[2]).direction&&c.length&&(c.length=z.distancePoints(a.points[a.points.length-1],c.points[c.points.length-1])),t.segments.splice(0,1)}else t.segments.splice(0,1)}else e&&!i&&t.sourceID!==e.id&&t.segments&&null!==t.segments[0].direction&&e&&e instanceof te&&s&&this.changeSourceEndToNode(t,e),e&&i&&t.sourcePortID!==i&&t.segments&&null!==t.segments[0].direction&&e&&e instanceof te&&s&&this.changeSourceEndToPort(t,e,i)},n.prototype.canConnect=function(t,e){return!(!da(e)||!Nh(e))},n.prototype.changeSourceEndToPort=function(t,e,i){var r=this.diagram.getWrapper(e.wrapper,i),s={x:r.offsetX,y:r.offsetY},o=zo(s,En(e.wrapper),e.wrapper.bounds),a=t.segments[0],l=t.segments[1];if(a.direction!==o){var h=[],c={};if(a.direction===ls(o)){c={};var d=void 0;"Top"===o||"Bottom"===o?(d="Top"===o?{type:"Orthogonal",isTerminal:!0,direction:o,length:Math.abs(a.points[0].y-s.y)}:{type:"Orthogonal",isTerminal:!0,direction:o,length:Math.abs(s.y-a.points[0].y)},c=a.points[0].x>s.x?{type:"Orthogonal",isTerminal:!0,direction:"Right",length:a.points[0].x-s.x}:{type:"Orthogonal",isTerminal:!0,direction:"Left",length:s.x-a.points[0].x}):(d="Right"===o?{type:"Orthogonal",isTerminal:!0,direction:o,length:Math.abs(a.points[0].x-s.x)}:{type:"Orthogonal",isTerminal:!0,direction:o,length:Math.abs(s.x-a.points[0].x)},c=a.points[0].y>s.y?{type:"Orthogonal",direction:"Top",isTerminal:!0,length:a.points[0].y-s.y}:{type:"Orthogonal",direction:"Bottom",isTerminal:!0,length:s.y-a.points[0].y}),h.push(new bi(t,"segments",d,!0)),h.push(new bi(t,"segments",c,!0))}else h.push(new bi(t,"segments",c={type:"Orthogonal",direction:o,length:20,isTerminal:!0},!0));a.direction!==ls(o)&&("Top"===o||"Bottom"===o?(a.points[0].x=s.x,a.points[0].y=a.points[a.points.length-1].y="Top"===o?s.y-20:s.y+20):(a.points[0].y=s.y,a.points[0].x=a.points[a.points.length-1].x="Right"===o?s.x+20:s.x-20),a.length=z.distancePoints(a.points[0],a.points[a.points.length-1]),l.length=z.distancePoints(a.points[a.points.length-1],l.points[l.points.length-1])),t.segments=h.concat(t.segments)}else a.points[0]=s,"Top"===o||"Bottom"===o?a.points[a.points.length-1].x=s.x:a.points[a.points.length-1].y=s.y,a.length=z.distancePoints(a.points[0],a.points[a.points.length-1]),l.length=z.distancePoints(a.points[a.points.length-1],l.points[l.points.length-1])},n.prototype.removeTerminalSegment=function(t,e){for(var i=0;ii.width||"Left"===o.direction&&r.x>=o.points[0].x||"Right"===o.direction&&r.x<=o.points[0].x)o.points[0].y=o.points[o.points.length-1].y=r.y,o.points[0].x=r.x,o.length=z.distancePoints(o.points[0],o.points[o.points.length-1]),a.length=z.distancePoints(o.points[o.points.length-1],a.points[a.points.length-1]);else{var h=void 0;s="Bottom"===(h=a.direction?a.direction:z.direction(a.points[0],a.points[a.points.length-1]))?i.bottomCenter:i.topCenter,a.length&&a.direction&&(a.length="Top"===h?o.points[o.points.length-1].y-(s.y+20):s.y+20-o.points[o.points.length-1].y),o.length=o.points[o.points.length-1].x-s.x,o.direction=o.length>0?"Right":"Left",l.push(new bi(t,"segments",{type:"Orthogonal",direction:h,length:20},!0)),t.segments=l.concat(t.segments)}else r="Bottom"===o.direction?i.bottomCenter:i.topCenter,o.length>i.height||"Top"===o.direction&&r.y>=o.points[0].y||"Bottom"===o.direction&&r.y<=o.points[0].y?(o.points[0].x=o.points[o.points.length-1].x=r.x,o.points[0].y=r.y,o.length=z.distancePoints(o.points[0],o.points[o.points.length-1]),a.length=z.distancePoints(o.points[o.points.length-1],a.points[a.points.length-1])):(s="Left"===a.direction?i.middleLeft:i.middleRight,h=void 0,h=a.direction?a.direction:z.direction(a.points[0],a.points[a.points.length-1]),a.length&&a.direction&&(a.length="Left"===h?o.points[o.points.length-1].x-(s.x+20):s.x+20-o.points[o.points.length-1].x),o.length=o.points[o.points.length-1].y-s.y,o.direction=o.length>0?"Bottom":"Top",l.push(new bi(t,"segments",{type:"Orthogonal",direction:h,length:20},!0)),t.segments=l.concat(t.segments))},n.prototype.translateBezierPoints=function(t,e,i,r,s,o,a){var l=t.segments.indexOf(s),h=t.segments[parseInt(l.toString(),10)],c=l>0?t.segments[l-1]:null,d=null!==c?c.point:t.sourcePoint,u=l===t.segments.length-1?t.targetPoint:h.point;if(h)if("BezierSourceThumb"===e&&(h.vector1.angle||h.vector1.distance)){var p=h.vector1.distance,f=h.vector1.angle;h.vector1={distance:t.distance(d,o),angle:z.findAngle(d,o)},this.translateSubsequentSegment(t,s,!0,h.vector1.distance-p,h.vector1.angle-f)}else"BezierTargetThumb"===e&&(h.vector2.angle||h.vector2.distance)?(p=h.vector2.distance,f=h.vector2.angle,h.vector2={distance:t.distance(u,o),angle:z.findAngle(u,o)},this.translateSubsequentSegment(t,s,!1,h.vector2.distance-p,h.vector2.angle-f)):("ConnectorSourceEnd"===e&&!t.sourceID||"ConnectorTargetEnd"===e&&!t.targetID)&&a&&XI(h.vector1)&&XI(h.vector2)?(z.isEmptyPoint(h.point1)&&(h.bezierPoint1=qI(t.sourcePoint,t.targetPoint)),z.isEmptyPoint(h.point2)&&(h.bezierPoint2=qI(t.targetPoint,t.sourcePoint))):"BezierSourceThumb"===e||"ConnectorSourceEnd"===e&&!a&&XI(h.vector1)?(h.bezierPoint1.x+=i,h.bezierPoint1.y+=r,(!z.isEmptyPoint(h.point1)||a)&&(h.point1={x:h.bezierPoint1.x,y:h.bezierPoint1.y})):("BezierTargetThumb"===e||"ConnectorTargetEnd"===e&&!a&&XI(h.vector2))&&(h.bezierPoint2.x+=i,h.bezierPoint2.y+=r,(!z.isEmptyPoint(h.point2)||a)&&(h.point2={x:h.bezierPoint2.x,y:h.bezierPoint2.y}))},n.prototype.translateSubsequentSegment=function(t,e,i,r,s){var o=t.segments.indexOf(e);parseInt(o.toString(),10),t.bezierSettings.smoothness&SI.SymmetricAngle||(s=null),t.bezierSettings.smoothness&SI.SymmetricDistance||(r=null),(null!=r||null!=s)&&(i?0!==o&&this.updatePreviousBezierSegment(t,o,r,s):o!==t.segments.length-1&&this.updateNextBezierSegment(t,o,r,s))},n.prototype.updatePreviousBezierSegment=function(t,e,i,r){var s=t.segments[e-1],a=(s.vector2.angle+r)%360;a<0&&(a+=360),s.vector2={distance:s.vector2.distance+i,angle:a}},n.prototype.updateNextBezierSegment=function(t,e,i,r){var s=t.segments[e+1],a=(s.vector1.angle+r)%360;a<0&&(a+=360),s.vector1={distance:s.vector1.distance+i,angle:a}},n.prototype.dragTargetEnd=function(t,e,i,r,s,o,a,l){var c,h=this.diagram.nameTable[t.id],d=this.checkBoundaryConstraints(e,i,h.wrapper.bounds);if(LI(h)&&"BezierTargetThumb"!==o&&d&&Vv(this.diagram)){if(c=$(c={targetPoint:h.targetPoint}),h.targetPoint.x+=e,h.targetPoint.y+=i,"ConnectorTargetEnd"===o&&"Orthogonal"===h.type&&h.segments&&h.segments.length>0){var u=h.segments[h.segments.length-2];u&&2===h.segments[h.segments.length-1].points.length&&("Left"===u.direction||"Right"===u.direction?u.points[u.points.length-1].x=h.targetPoint.x:u.points[u.points.length-1].y=h.targetPoint.y,u.length=z.distancePoints(u.points[0],u.points[u.points.length-1]),u.direction=z.direction(u.points[0],u.points[u.points.length-1]))}"Bpmn"===h.shape.type&&"Default"===h.shape.sequence&&"Sequence"===h.shape.flow&&this.updatePathElementOffset(h)}if("Bezier"===h.type)if(c={targetPoint:h.targetPoint},l)this.translateBezierPoints(t,""===o?"ConnectorTargetEnd":o,e,i,l,s,!a);else for(var p=0;p0){if(void 0!==s&&o.segments[parseInt(s.toString(),10)])if("Bezier"===o.type){var a=o.segments[parseInt(s.toString(),10)],l=a.isInternalSegment;l&&null!==o.bezierSettings&&"FreeForm"!==o.bezierSettings.segmentEditOrientation?("Horizontal"===a.orientation?a.point.x+=e:a.point.y+=i,this.updateDirectionalBezierCurve(o)):(a.point.x+=e,a.point.y+=i),l&&(o.isBezierEditing=!0)}else o.segments[parseInt(s.toString(),10)].point.x+=e,o.segments[parseInt(s.toString(),10)].point.y+=i;else for(var h=0;h1){var a=e[1],l=e[2],h={x:.5*(a.x+l.x),y:.5*(a.y+l.y)},c=t.segments[0];c.vector1.angle=Gt(s,a),c.vector1.distance=.5*z.findLength(s,a),c.vector2.angle=Gt(h,a),c.vector2.distance=.5*z.findLength(h,a),c.point=h;var d=t.segments[1];if(d.vector1.angle=Gt(h,l),d.vector1.distance=.5*z.findLength(h,l),t.segments.length>2){var u=e[3],p={x:.5*(l.x+u.x),y:.5*(l.y+u.y)};d.vector2.angle=Gt(p,l),d.vector2.distance=.5*z.findLength(p,l),d.point=p;var f=t.segments[2];if(f.vector1.angle=Gt(p,u),f.vector1.distance=.5*z.findLength(p,u),t.segments.length>3){var g=e[4],v={x:.5*(u.x+g.x),y:.5*(u.y+g.y)};f.vector2.angle=Gt(v,u),f.vector2.distance=.5*z.findLength(v,u),f.point=v;var y=t.segments[3];y.vector1.angle=Gt(v,g),y.vector1.distance=.5*z.findLength(v,g),y.vector2.angle=Gt(o,g),y.vector2.distance=.5*z.findLength(o,g)}else f.vector2.angle=Gt(o,u),f.vector2.distance=.5*z.findLength(o,u)}else d.vector2.angle=Gt(o,l),d.vector2.distance=.5*z.findLength(o,l)}},n.prototype.rotateObjects=function(t,e,i,r,s){r=r||{};var o=Hi();qi(o,i,r.x,r.y);for(var l=0,h=e;l0){this.diagram.protectPropertyChange(!0);var o=t;o.segments=[],this.diagram.connectorPropertyChange(o,{},{segments:o.segments}),this.diagram.protectPropertyChange(!1)}}},n.prototype.updateInnerParentProperties=function(t){var r=this.diagram.isProtectedOnChange;this.diagram.protectPropertyChange(!0);for(var s=this.getAllDescendants(t,[],!1,!0),o=0;o0&&(p=this.diagram.bpmnModule.getChildrenBound(d,d.id,this.diagram),u=d.wrapper.bounds.containsRect(p)),h=d.wrapper.actualSize.width*t,c=d.wrapper.actualSize.height*e,void 0!==d.maxWidth&&0!==d.maxWidth&&(h=Math.min(d.maxWidth,h)),void 0!==d.minWidth&&0!==d.minWidth&&(h=Math.max(d.minWidth,h)),void 0!==d.maxHeight&&0!==d.maxHeight&&(c=Math.min(d.maxHeight,c)),void 0!==d.minHeight&&0!==d.minHeight&&(c=Math.max(d.minHeight,c)),u&&(h=Math.max(h,p.right-d.wrapper.bounds.x),c=Math.max(c,p.bottom-d.wrapper.bounds.y)),t=h/d.actualSize.width,e=c/d.actualSize.height}var f=Hi();o||(o=r);var g=o.wrapper;if(qi(f,-g.rotateAngle,i.x,i.y),Qp(f,t,e,i.x,i.y),qi(f,g.rotateAngle,i.x,i.y),r instanceof te){var d,v=Je(f,{x:(d=r).wrapper.offsetX,y:d.wrapper.offsetY}),y=d.wrapper.offsetX-d.wrapper.actualSize.width*d.pivot.x,S=d.wrapper.offsetY-d.wrapper.actualSize.height*d.pivot.y;if(h>0)if(d.processId){var b=this.diagram.nameTable[d.processId];(!b.maxWidth||d.margin.left+h0)if(d.processId){var M=this.diagram.nameTable[d.processId];(!M.maxHeight||d.margin.top+c0){if(e.dragLimit=e.dragLimit?e.dragLimit:{},e.dragLimit.top||e.dragLimit.bottom||e.dragLimit.left||e.dragLimit.right){var b={minDistance:null};S=this.getRelativeOffset(v,d,b);var M={minDistance:null};g=this.getRelativeOffset(v,y,M),S=null!=b&&M.minDistance0){if(S=y[y.length-1]){var b=void 0;for(b=0;b=e.x-t.dragLimit.left-r.width/2&&i.x<=e.x+t.dragLimit.right+r.width/2&&(s=!0),i.y>=e.y-t.dragLimit.top-r.height/2&&i.y<=e.y+t.dragLimit.bottom+r.height/2&&(o=!0),{x:s,y:o}},n.prototype.updateLabelMargin=function(t,e,i,r,s,o,a){if(i=i||{x:e.offset,y:0},e&&i&&i.x>0&&i.x<1){var l=z.getLengthFromListOfPoints(t.intermediatePoints),h=this.getPointAtLength(l*i.x,t.intermediatePoints,0),c=this.diagram.scrollSettings.currentZoom,d=e.dragLimit?e.dragLimit:{left:0,right:0,top:0,bottom:0};if(d.top||d.bottom||d.left||d.right){this.diagram.getWrapper(t.wrapper,e.id);var p=new Ne(0,0,0,0),f=this.diagram.getWrapper(t.wrapper,e.id);p.x=f.offsetX/c+o,p.y=f.offsetY/c+a,p.width=f.bounds.width/c,p.height=f.bounds.height/c;var g=new Ne(h.x-(d.left||0)-p.width/2,h.y-(d.top||0)-p.height/2,(d.left||0)+(d.right||0)+p.width,(d.top||0)+(d.bottom||0)+p.height);if(g.containsPoint(r));else for(var S=0,b=this.boundsInterSects([h,r],g,!1);S=t){c=t-r,d=z.findAngle(s,a),u=c*Math.cos(d*Math.PI/180),p=c*Math.sin(d*Math.PI/180),o={x:s.x+u,y:s.y+p};break}r+=h,s=a}else s=a;return o},n.prototype.getInterceptWithSegment=function(t,e){for(var o,a,i=[],r=[],s=[],l=z.findLength({x:0,y:0},{x:this.diagram.scroller.viewPortWidth,y:this.diagram.scroller.viewPortHeight}),h=1;h0&&a<=90||a>180&&a<=270?90:-90;r.push(z.transform(t,a+c,l)),r.push(z.transform(t,o+c,l));var p=em({x1:s[0].x,y1:s[0].y,x2:s[1].x,y2:s[1].y},{x1:r[0].x,y1:r[0].y,x2:r[1].x,y2:r[1].y});p.enabled&&i.push(p.intersectPt)}return i},n.prototype.getAnnotationChanges=function(t,e){var r={};return r[rb(t,e.id,!0)]={width:e.width,height:e.height,offset:t instanceof te?{x:e.offset.x,y:e.offset.y}:e.offset,rotateAngle:e.rotateAngle,margin:{left:e.margin.left,right:e.margin.right,top:e.margin.top,bottom:e.margin.bottom},horizontalAlignment:e.horizontalAlignment,verticalAlignment:e.verticalAlignment,alignment:t instanceof de?e.alignment:void 0},{annotations:r}},n.prototype.getConnectorPortChanges=function(t,e){var i=function zse(n,t,e){for(var i=n.ports,r=0;r1&&(v.width=g,v.offset.x=1/S),f>1&&(v.height=f,v.offset.y=1/b)}}e instanceof Nr&&(e.alignment="Center"),l=this.getAnnotationChanges(t,e),t instanceof te?this.diagram.nodePropertyChange(t,a,l):this.diagram.connectorPropertyChange(t,a,l),this.diagram.updateDiagramObject(t)},n.prototype.getSubProcess=function(t){var i,e={nodes:[],connectors:[]};return t instanceof te?i=t.processId:t&&t.nodes&&t.nodes.length&&t.nodes[0].processId&&(i=t.nodes[0].processId),i&&e.nodes.push($(this.diagram.nameTable[i])),e},n.prototype.checkBoundaryConstraints=function(t,e,i,r){var s=this.diagram.pageSettings,o=this.diagram.pageSettings.boundaryConstraints,a=this.diagram.scroller;if("Page"===o||"Diagram"===o){var l=i?void 0:this.diagram.selectedItems.wrapper.bounds;return!!((i?i.right:l.right)+(t||0)<=("Page"===o?s.width:a.viewPortWidth)&&(i?i.left:l.left)+(t||0)>=0&&(i?i.bottom:l.bottom)+(e||0)<=("Page"===o?s.height:a.viewPortHeight)&&(i?i.top:l.top)+(e||0)>=0||"None"!==this.diagram.layout.type&&r)}return!0},n.prototype.dragSelectedObjects=function(t,e){var i=this,r=this.diagram.selectedItems;this.state&&!this.state.backup&&(this.state.backup={},this.state.backup.offsetX=r.offsetX,this.state.backup.offsetY=r.offsetY),r=VI(this.diagram,r)||r;var s=this.diagram.selectedItems.nodes.filter(function(c){return"SwimLane"===c.shape.type});if(s.length>0&&!this.diagram.currentSymbol&&this.diagram.selectedItems.nodes.length>1){var o=this.diagram.selectedItems.nodes.filter(function(c){return""===c.parentId||"SwimLane"!==i.diagram.nameTable[c.parentId].shape.type});if(o.length>0){for(var a=0;a0||l.length>1)&&(o=o.concat(l),this.diagram.selectedItems.nodes.splice(0,this.diagram.selectedItems.nodes.length),o.forEach(function(c){i.diagram.selectedItems.nodes.push(c)}),r=this.diagram.selectedItems,this.diagram.selectedObject.helperObject=void 0)}}if(this.checkBoundaryConstraints(t,e)){this.diagram.diagramActions=this.diagram.diagramActions|ee.PreventZIndexOnDragging|ee.DragUsingMouse;var h=this.diagram.selectedObject.actualObject;return(h&&h instanceof te&&h.isLane&&Wx(h,this.diagram)||!h||!h.isLane)&&this.diagram.drag(r,t,e),this.diagram.diagramActions=this.diagram.diagramActions&~(ee.PreventZIndexOnDragging|ee.DragUsingMouse),this.diagram.refreshCanvasLayers(),this.checkHtmlObjectDrag(r),!0}return!1},n.prototype.checkHtmlObjectDrag=function(t){var e=!1;this.diagram.views&&this.diagram.views.length>1&&(t instanceof oi?e=t.nodes.some(function(i){return i.shape&&"HTML"===i.shape.type}):t.shape&&"HTML"===t.shape.type&&(e=!0),e&&this.resetOverviewCanvas())},n.prototype.resetOverviewCanvas=function(){for(var t=0,e=this.diagram.views;t0&&(this.layoutAnimateModule.stopCurrentAnimation(this.objectStore[0],e,t),this.objectStore=[]),a=this.diagram.doLayout(),this.objectStore.push(a)),this.canUpdateTemplate=!1,this.diagram.blazorActions&=~on.expandNode,this.diagram.preventNodesUpdate=r,this.diagram.layoutAnimateModule&&this.diagram.organizationalChartModule&&!i)this.diagram.allowServerDataBinding=!1,this.layoutAnimateModule.expand(this.diagram.layout.enableAnimation,a,t,this.diagram);else{var l={element:$(t),state:!!t.isExpanded};this.triggerEvent(Ce.expandStateChange,l),this.diagram.lineRoutingModule&&this.diagram.constraints&rt.LineRouting&&"ComplexHierarchicalTree"!==this.diagram.layout.type&&this.diagram.resetSegments()}return this.diagram.layout.fixedNode=""===o?"":this.diagram.layout.fixedNode,a},n.prototype.getparentexpand=function(t,e,i,r){for(var s,o=0;o0&&(this.diagram.selectedItems.wrapper.rotateAngle=this.diagram.selectedItems.rotateAngle=s.rotateAngle),r instanceof te&&"SwimLane"!==r.shape.type&&!r.isLane&&!r.isPhase&&!r.isHeader)(r.offsetX!==r.wrapper.offsetX||r.offsetY!==r.wrapper.offsetY||r.width!==r.wrapper.width||r.height!==r.wrapper.height||r.rotateAngle!==r.wrapper.rotateAngle)&&(r.offsetX+=o,r.offsetY+=a,r.width+=l,r.height+=h,r.rotateAngle+=c,this.diagram.nodePropertyChange(r,{},{offsetX:r.offsetX,offsetY:r.offsetY,width:r.width,height:r.height,rotateAngle:r.rotateAngle})),e=this.diagram.spatialSearch.findObjects(r.wrapper.outerBounds);else if(r instanceof oi)for(var d=0;d30||g.wrapper.outerBounds.topCenter.y-f.wrapper.outerBounds.bottomCenter.y>30)&&this.diagram.lineRoutingModule.refreshConnectorSegments(this.diagram,p,!0)}}this.updateSelector(),this.diagram.protectPropertyChange(!1)}},n.prototype.drawSelectionRectangle=function(t,e,i,r){this.diagram.drawSelectionRectangle(t,e,i,r)},n.prototype.startGroupAction=function(){this.diagram.startGroupAction()},n.prototype.endGroupAction=function(){this.diagram.endGroupAction()},n.prototype.removeChildFromBPmn=function(t,e,i){var r=this.diagram.nameTable[t.id]||t.nodes[0];if(i&&r&&r.processId&&r.processId===i.wrapper.id){var s=$(r);s.processId=r.processId,this.diagram.startGroupAction();var o=this.diagram.nameTable[r.processId].shape.activity.subProcess.processes||[];o.splice(o.indexOf(r.id),1),this.diagram.bpmnModule.removeChildFromBPMN(this.diagram.nameTable[r.processId].wrapper,r.id,this.diagram),this.diagram.nameTable[r.id].processId="",r.offsetX=r.wrapper.offsetX,r.offsetY=r.wrapper.offsetY;var a=$(r);this.addHistoryEntry({type:"PositionChanged",redoObject:{nodes:[a]},undoObject:{nodes:[s]},category:"Internal"}),this.diagram.endGroupAction()}},n.prototype.isDroppable=function(t,e){var i=this.diagram.nameTable[t.id]||t.nodes[0];return i instanceof te&&(!ce()&&"TextAnnotation"===i.shape.shape||("Group"===e.shape.shape&&(e.shape.activity.subProcess.collapsed=!1),!(i&&"Bpmn"===i.shape.type&&(i.processId===e.id||i.id===e.processId||"Bpmn"===e.shape.type&&!(e instanceof de)&&e.shape.activity&&e.shape.activity.subProcess&&e.shape.activity.subProcess.collapsed))))},n.prototype.renderHighlighter=function(t,e,i){if(new Ne,t.target instanceof te||t.target instanceof de||e&&(t.source instanceof te||t.source instanceof de)){var a=this.findTarget(e?t.sourceWrapper:t.targetWrapper,e?t.source:t.target,i,!0),l=void 0;if(a instanceof zd)for(var h=a.id,c=t.target,u=0,p=c.wrapper.children[0].children[0].children[2].children;u0){var r=0;t[0]=this.diagram.nameTable[t[0].id]||t[0];var s="Object"===i?yr(t[0].wrapper):this.diagram.selectedItems.wrapper.bounds,o={nodes:[],connectors:[]},a={nodes:[],connectors:[]};for(r="Object"===i?r+1:r;r0){var i=0,r=0,s=0,o=0,a=0,l=0,h=0,c=0,d={nodes:[],connectors:[]},u={nodes:[],connectors:[]};for(i=0;io.center.y&&(r=n[parseInt(e.toString(),10)],n[parseInt(e.toString(),10)]=n[parseInt(i.toString(),10)],n[parseInt(i.toString(),10)]=r):s.center.x>o.center.x&&(r=n[parseInt(e.toString(),10)],n[parseInt(e.toString(),10)]=n[parseInt(i.toString(),10)],n[parseInt(i.toString(),10)]=r)}}return n}(t,e),i=1;i0){var i=0,r={x:.5,y:.5};t[0]=this.diagram.nameTable[t[0].id]||t[0];var s=yr(t[0].wrapper),o={nodes:[],connectors:[]},a={nodes:[],connectors:[]};for(i=1;ii.zIndex){for(var s=this.diagram.layers.indexOf(this.diagram.getActiveLayer()),o=this.diagram.layers[parseInt(s.toString(),10)].zIndexTable,a=JSON.parse(JSON.stringify(o)),l=i.zIndex,h=r.zIndex,c=h;c>=l;c--)l!==c?o[c-1]?(o[parseInt(c.toString(),10)]=o[c-1],this.diagram.nameTable[o[parseInt(c.toString(),10)]].zIndex=c):(o[c-1]=o[parseInt(c.toString(),10)],this.diagram.nameTable[o[c-1]].zIndex=c,delete o[parseInt(c.toString(),10)]):this.swapZIndexObjects(h,o,r.id,a);"SVG"===this.diagram.mode?(this.moveSvgNode(e.parentId,i.id),this.updateNativeNodeIndex(e.parentId,i.id)):this.diagram.refreshCanvasLayers()}},n.prototype.findLeastIndexConnector=function(t,e,i){for(var r=0;rs.zIndex&&(i=s)}return i},n.prototype.findLeastIndexObject=function(t,e){var i=t;return t instanceof te&&(i=this.findLeastIndexConnector(t.inEdges,e,i),i=this.findLeastIndexConnector(t.outEdges,e,i)),i},n.prototype.checkSelection=function(t,e){var i;if(1===t.nodes.length&&0===t.connectors.length)if(cs(this.diagram,t.nodes[0],!0)){var r=t.nodes[0];if("SwimLane"===(i="SwimLane"===t.nodes[0].shape?t.nodes[0]:this.diagram.nameTable[t.nodes[0].parentId]).shape.type){var s="Horizontal"===i.shape.orientation;(r.isPhase&&(s&&"ResizeSouth"===e||!s&&"ResizeEast"===e)||r.isLane&&(s&&"ResizeEast"===e||!s&&"ResizeSouth"===e))&&B3(this.diagram,i,e)}else if("Grid"===i.container.type)if("Horizontal"===i.container.orientation&&1===r.rowIndex||"Vertical"===i.container.orientation&&r.rowIndex>0&&r.columnIndex>0){if("ResizeSouth"===e)for(var o=0;o1&&(this.diagram.realActions=this.diagram.realActions|$i.hScrollbarMoved,this.scrolled=!0),this.diagram.scrollSettings.horizontalOffset=t},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"verticalOffset",{get:function(){return this.vOffset},set:function(t){this.vOffset=t,Math.abs(this.vOffset-this.diagram.scrollSettings.verticalOffset)>1&&(this.diagram.realActions=this.diagram.realActions|$i.vScrollbarMoved,this.scrolled=!0),this.diagram.scrollSettings.verticalOffset=t},enumerable:!0,configurable:!0}),n.prototype.getBounds=function(){var e=this.diagram.spatialSearch.getPageBounds(0,0);return(e.x<0||e.y<0)&&!this.diagram.pageSettings.multiplePage?this.getPageBounds(void 0,void 0,!0,!0):this.getPageBounds(void 0,void 0,!0)},n.prototype.updateScrollOffsets=function(t,e){var i,r,s=this.getBounds();s.x*=this.currentZoom,s.y*=this.currentZoom,s.width*=this.currentZoom,s.height*=this.currentZoom,i=Math.max(0,t-s.left),r=Math.max(0,e-s.top),void 0!==t&&void 0!==e?(this.horizontalOffset=i,this.verticalOffset=r,this.diagram.setOffset(i,r)):this.diagram.setOffset(-this.horizontalOffset-s.x,-this.verticalOffset-s.y),this.transform={tx:Math.max(this.horizontalOffset,-s.left)/this.currentZoom,ty:Math.max(this.verticalOffset,-s.top)/this.currentZoom,scale:this.currentZoom}},n.prototype.setScrollOffset=function(t,e){this.scrolled=!1;var i=this.getBounds();i.x*=this.currentZoom,i.y*=this.currentZoom,i.width*=this.currentZoom,i.height*=this.currentZoom;var r=-i.left,s=-i.top,o=!1,a=this.viewPortWidth*this.currentZoom,l=this.viewPortHeight*this.currentZoom,h=r-t;if(h!==this.horizontalOffset){rh?this.horizontalOffset-=t:this.horizontalOffset=h,o=!0);var c=Math.max(i.right+this.vScrollSize,a);if(!o&&c<-h+this.viewPortWidth){var d=-h+a-this.vScrollSize,u=-this.horizontalOffset+a-this.vScrollSize;this.horizontalOffset=dd-u?h:-(i.right+this.vScrollSize-a),o=!0}o||(this.horizontalOffset=r-t)}o=!1;var p=s-e;if(p!==this.verticalOffset){sp?this.verticalOffset-=e:this.verticalOffset=p,o=!0);var f=Math.max(i.bottom+this.hScrollSize,l);if(!o&&f<-p+l){var g=-p+l-this.hScrollSize,v=-this.verticalOffset+l-this.hScrollSize;this.verticalOffset=gg-v?p:-(i.bottom+this.hScrollSize-l),o=!0}o||(this.verticalOffset=s-e)}this.transform={tx:Math.max(this.horizontalOffset,-i.left)/this.currentZoom,ty:Math.max(this.verticalOffset,-i.top)/this.currentZoom,scale:this.currentZoom},this.setSize()},n.prototype.getObjects=function(t,e){for(var i=[],r=0;r0){for(var l=0;l0){h.push(i[parseInt(o.toString(),10)].id);for(var d=0;d=e.bottom&&(l=0),-this.horizontalOffset<=e.x&&-this.horizontalOffset+this.viewPortWidth>=e.right&&(a=0),this.hScrollSize=a,this.vScrollSize=l;var h=this.diagramWidth,c=this.diagramHeight;this.diagramWidth=Math.max(e.right,-this.horizontalOffset+this.viewPortWidth-l)-i,this.diagramHeight=Math.max(e.bottom,-this.verticalOffset+this.viewPortHeight-a)-r,(h!==this.diagramWidth||c!==this.diagramHeight)&&"Diagram"!==this.diagram.scrollSettings.scrollLimit&&this.diagram.setSize(this.diagramWidth,this.diagramHeight),"Diagram"===this.diagram.scrollSettings.scrollLimit&&(h===this.diagramWidth&&c===this.diagramHeight&&1===this.currentZoom||this.diagram.diagramActions&&t&&(!this.diagram.diagramActions||!t||0===this.verticalOffset&&this.verticalOffset!==t.y||0===this.horizontalOffset&&this.horizontalOffset!==t.x)?t&&h===this.diagramWidth&&c===this.diagramHeight&&(this.diagram.diagramCanvas.scrollHeight>this.viewPortHeight&&t.y<0&&this.horizontalOffset===t.x&&0===this.verticalOffset||this.diagram.diagramCanvas.scrollWidth>this.viewPortWidth&&t.x<0&&this.verticalOffset===t.y&&0===this.horizontalOffset)&&(this.verticalOffset=t.y,this.horizontalOffset=t.x,this.transform={tx:Math.max(t.x,-e.left)/this.currentZoom,ty:Math.max(t.y,-e.top)/this.currentZoom,scale:this.currentZoom}):(this.diagram.scrollActions&ca.Interaction&&t&&(this.transform={tx:Math.max(t.x,-e.left/this.currentZoom)/this.currentZoom,ty:Math.max(t.y,-e.top/this.currentZoom)/this.currentZoom,scale:this.currentZoom},this.horizontalOffset=t.x,this.verticalOffset=t.y),this.diagram.setSize(this.diagramWidth,this.diagramHeight),!(this.diagram.scrollActions&ca.PropertyChange)&&t&&(this.horizontalOffset=t.x,this.verticalOffset=t.y,this.transform={tx:Math.max(t.x,-e.left)/this.currentZoom,ty:Math.max(t.y,-e.top)/this.currentZoom,scale:this.currentZoom}))),this.diagram.transformLayers(),this.diagram.element.style.overflow="hidden"},n.prototype.setViewPortSize=function(t,e){this.viewPortWidth=t,this.viewPortHeight=e},n.prototype.getPageBounds=function(t,e,i,r){var o,s=new Ne;if("Content"===e||r||null===this.diagram.pageSettings.width||null===this.diagram.pageSettings.height){var u=t?void 0:0;o=this.diagram.spatialSearch.getPageBounds(u,u)}else{var a=this.diagram.pageSettings.width,l=this.diagram.pageSettings.height,h=0,c=0;if(this.diagram.pageSettings.multiplePage){if((s=this.diagram.spatialSearch.getPageBounds(0,0)).right>a&&(a*=d=Math.ceil(s.right/a)),s.bottom>l&&(l*=d=Math.ceil(s.bottom/l)),s.left<0&&Math.abs(s.left)>h){var d=Math.ceil(Math.abs(s.left)/this.diagram.pageSettings.width);h=this.diagram.pageSettings.width*d}s.top<0&&Math.abs(s.top)>c&&(d=Math.ceil(Math.abs(s.top)/this.diagram.pageSettings.height),c=this.diagram.pageSettings.height*d)}o=new Ne(-h,-c,a+h,l+c)}if(i){var p=this.diagram.scrollSettings.padding;o.x-=p.left,o.y-=p.top,o.width+=p.left+p.right,o.height+=p.top+p.bottom}return o},n.prototype.getPageBreak=function(t){for(var e=0,i=0,r=-1,s=[],c=this.diagram.pageSettings.margin.left,d=this.diagram.pageSettings.margin.right,u=this.diagram.pageSettings.margin.top,p=this.diagram.pageSettings.margin.bottom,f=1,g=1;t.width>e;)(e+=this.diagram.pageSettings.width?this.diagram.pageSettings.width:t.width)===this.diagram.pageSettings.width&&(s[++r]={x1:t.left+c,y1:t.top+u,x2:t.left+c,y2:t.bottom-p}),ei;)(i+=this.diagram.pageSettings.height?this.diagram.pageSettings.height:t.height)===this.diagram.pageSettings.height&&(s[++r]={x1:t.left+c,y1:t.top+u,x2:t.right-d,y2:t.top+u}),i=this.diagram.scrollSettings.minZoom||l||t>=1)){this.currentZoom*=t;var c=this.getPageBounds(void 0,void 0,!0);c.x*=this.currentZoom,c.y*=this.currentZoom;var d=Hi();Qp(d,t,t,r.x,r.y),ZB(d,e||0,i||0),Sx(h,d);var u=Je(h,{x:0,y:0});if(1===t&&(u=this.applyScrollLimit(u.x,u.y,s,o,a)),a=-c.y>=u.y&&-c.x>=u.x&&a,(this.diagram.scrollActions&ca.PropertyChange||!(this.diagram.scrollActions&ca.Interaction)||"Diagram"!==this.diagram.scrollSettings.scrollLimit||a)&&(this.transform={tx:Math.max(u.x,-c.left)/this.currentZoom,ty:Math.max(u.y,-c.top)/this.currentZoom,scale:this.currentZoom},this.horizontalOffset=u.x,this.verticalOffset=u.y),this.setSize(u),"SVG"!==this.diagram.mode&&Ds(this.diagram)&&this.diagram.scroller.virtualizeElements(),"SVG"!==this.diagram.mode&&!Ds(this.diagram)&&this.diagram.refreshDiagramLayer(),this.diagram.setOffset(-this.horizontalOffset-c.x,-this.verticalOffset-c.y),$I(this.diagram),this.diagram.views&&this.diagram.views.overview){var p=this.diagram.views.overview,f=p.scrollOverviewRect(p.parent.scroller.horizontalOffset,p.parent.scroller.verticalOffset,p.parent.scroller.currentZoom,!0);p.updateOverviewrect(-f.x,-f.y,f.width,f.height),p.updateView(p)}}}},n.prototype.fitToPage=function(t){var e=(t=t||{}).mode,i=t.region,r=t.margin||{},s=t.canZoomIn,o=t.customBounds,a=t.canZoomOut;r.bottom=r.bottom||25,r.top=r.top||25,r.left=r.left||25,r.right=r.right||25;var h,l=o,c=-this.horizontalOffset,d=-this.verticalOffset;if("PageSettings"===(i=i||"PageSettings")&&this.diagram.pageSettings.width&&this.diagram.pageSettings.height||this.diagram.nodes.length>0||this.diagram.connectors.length>0){e=e||"Page","CustomBounds"!==i&&(l=this.getPageBounds(!0,i,!0));var u={x:0,y:0};r.left+r.right>this.viewPortWidth&&(this.viewPortWidth<=100?(r.left=5,r.right=5):(r.left=25,r.right=25)),r.top+r.bottom>this.viewPortHeight&&(this.viewPortHeight<=100?(r.top=5,r.bottom=5):(r.top=25,r.bottom=25)),u.x=(this.viewPortWidth-(r.left+r.right))/l.width,u.y=(this.viewPortHeight-(r.top+r.bottom))/l.height,!s&&l.width-this.horizontalOffset-a+this.viewPortWidth&&(i=o.right-this.viewPortWidth,i+=20),o.x<-a&&(i=o.x),o.bottom>-l+this.viewPortHeight&&(r=o.bottom-this.viewPortHeight,r+=20),o.y<-l&&(r=o.y),this.zoom(1,-this.horizontalOffset-i,-this.verticalOffset-r,null,void 0,e))},n.prototype.bringToCenter=function(t){var e=this.currentZoom,i=new Ne(t.x*e,t.y*e,t.width*e,t.height*e),r=i.x+i.width/2-this.viewPortWidth/2,s=i.y+i.height/2-this.viewPortHeight/2;this.zoom(1,-this.horizontalOffset-(r*=-1),-this.verticalOffset-(s*=-1),null)},n.prototype.applyScrollLimit=function(t,e,i,r,s){if("Infinity"===this.diagram.scrollSettings.scrollLimit&&void 0===i&&!r&&(t=-t,e=-e),"Infinity"!==this.diagram.scrollSettings.scrollLimit){var o=void 0;if("Limited"===this.diagram.scrollSettings.scrollLimit){var a=this.diagram.scrollSettings.scrollableArea;o=new Ne(a.x,a.y,a.width,a.height)}(o=o||(s?this.getPageBounds():this.getPageBounds(!0))).x*=this.currentZoom,o.y*=this.currentZoom,o.width*=this.currentZoom,o.height*=this.currentZoom,void 0!==i&&(t*=-1,e*=-1),r&&(t*=-1,e*=-1);var l=Math.max(o.right,this.viewPortWidth);if(!r&&!(t<=o.x&&(t+this.viewPortWidth>=o.right||t>=o.right-this.viewPortWidth)||t>=o.x&&t+this.viewPortWidth<=l))if(t>=o.x)t=Math.max(o.x,Math.min(t,t-(t+this.viewPortWidth-this.vScrollSize-l)));else{var h=o.right-this.viewPortWidth;t=Math.min(h,o.x)}var c=Math.max(o.bottom,this.viewPortHeight);r||e<=o.y&&e+this.viewPortHeight>=o.bottom||e>=o.y&&e+this.viewPortHeight<=c||(e>=o.y?e=Math.max(o.y,Math.min(e,e-(e+this.viewPortHeight-this.hScrollSize-c))):(h=o.bottom-this.viewPortHeight,e=Math.min(o.y,h))),t*=-1,e*=-1}return{x:t,y:e}},n}(),Qoe=function(){function n(t,e,i,r,s){this.objects=[],this.left=t,this.top=e,this.width=i,this.height=r,this.spatialSearch=s}return n.prototype.findQuads=function(t,e){null!=this.first&&this.first.isIntersect(t)&&this.first.findQuads(t,e),null!=this.second&&this.second.isIntersect(t)&&this.second.findQuads(t,e),null!=this.third&&this.third.isIntersect(t)&&this.third.findQuads(t,e),null!=this.fourth&&this.fourth.isIntersect(t)&&this.fourth.findQuads(t,e),this.objects.length>0&&e.push(this)},n.prototype.isIntersect=function(t){return!(this.left+this.widtht.right||this.top>t.bottom)},n.prototype.selectQuad=function(){for(var i,t=null,e=this;null!=e;)i=e.getQuad(t),e=i.source,t=i.target||t;return t},n.prototype.getQuad=function(t){var e=this.width/2,i=this.height/2;if(e>=1e3&&i>=1e3){var r=this.left+e,s=this.top+i;if(this.spatialSearch.childRight<=r){if(this.spatialSearch.childBottom<=s)return this.first||((o=new n(this.left,this.top,e,i,this.spatialSearch)).parent=this,this.first=o),{source:this.first};if(this.spatialSearch.childTop>=s)return this.third||((o=new n(this.left,s,e,i,this.spatialSearch)).parent=this,this.third=o),{source:this.third}}else if(this.spatialSearch.childLeft>=r){if(this.spatialSearch.childBottom<=s)return this.second||((o=new n(r,this.top,e,i,this.spatialSearch)).parent=this,this.second=o),{source:this.second};var o;if(this.spatialSearch.childTop>=s)return this.fourth||((o=new n(r,s,e,i,this.spatialSearch)).parent=this,this.fourth=o),{source:this.fourth}}}return this.objects.push(this.spatialSearch.childNode),{target:this}},n.prototype.isContained=function(){return this.spatialSearch.childLeft>=this.left&&this.spatialSearch.childRight<=this.left+this.width&&this.spatialSearch.childTop>=this.top&&this.spatialSearch.childBottom<=this.top+this.height},n.prototype.addIntoAQuad=function(t){var e={};this.spatialSearch.setCurrentNode(t);for(var i=null;!e.isAdded;)i=(e=this.spatialSearch.parentQuad.add(i)).quad;return i},n.prototype.add=function(t){if(t=null,this.isContained())return{isAdded:!0,quad:t=this.selectQuad()};var e=void 0,i=!(0!==this.objects.length||this.first||this.second||this.third||this.fourth),r=2*this.width,s=2*this.height;return this.spatialSearch.childLeft=this.childLeft?(this.pageLeft=this.childLeft,this.leftElement=t,r=!0):t===this.leftElement&&(this.pageLeft=Number.MAX_VALUE,this.findLeft(this.parentQuad),r=!0)),(this.pageTop!==this.childTop||t!==this.topElement)&&(this.pageTop>=this.childTop?(this.pageTop=this.childTop,this.topElement=t,r=!0):t===this.topElement&&(this.pageTop=Number.MAX_VALUE,this.findTop(this.parentQuad),r=!0)),(this.pageBottom!==this.childBottom||t!==this.bottomElement)&&(this.pageBottom<=this.childBottom?(r=!0,this.pageBottom=this.childBottom,this.bottomElement=t):t===this.bottomElement&&(this.pageBottom=-Number.MAX_VALUE,this.findBottom(this.parentQuad),r=!0)),(this.pageRight!==this.childRight||t!==this.rightElement)&&(this.pageRight<=this.childRight?(this.pageRight=this.childRight,this.rightElement=t,r=!0):t===this.rightElement&&(this.pageRight=-Number.MAX_VALUE,this.findRight(this.parentQuad),r=!0)),r}return this.setCurrentNode(null),!1},n.prototype.isWithinPageBounds=function(t){return t.left>=this.pageLeft&&t.right<=this.pageRight&&t.top>=this.pageTop&&t.bottom<=this.pageBottom},n.prototype.findQuads=function(t){var e=[];return this.parentQuad.findQuads(t,e),e},n.prototype.findObjects=function(t){for(var i=[],r=0,s=this.findQuads(t);r=r.outerBounds.left&&(this.pageLeft=r.outerBounds.left,this.leftElement=r)}},n.prototype.findTop=function(t){t.first||t.second?(t.first&&this.findTop(t.first),t.second&&this.findTop(t.second)):(t.third&&this.findTop(t.third),t.fourth&&this.findTop(t.fourth));for(var e=0,i=t.objects;e=r.outerBounds.top&&(this.pageTop=r.outerBounds.top,this.topElement=r)}},n.prototype.setCurrentNode=function(t){if(this.childNode=t,t){var e=t.outerBounds;this.childLeft=Number(e.left),this.childTop=Number(e.top),this.childRight=Number(e.right),this.childBottom=Number(e.bottom)}else this.childLeft=Number.MAX_VALUE,this.childTop=Number.MAX_VALUE,this.childRight=-Number.MAX_VALUE,this.childBottom=-Number.MAX_VALUE},n.prototype.getPageBounds=function(t,e){if(this.pageLeft===Number.MAX_VALUE)return new Ne(0,0,0,0);var i=void 0!==t?Math.min(this.pageLeft,0):this.pageLeft,r=void 0!==e?Math.min(this.pageTop,0):this.pageTop;return new Ne(Math.round(i),Math.round(r),Math.round(this.pageRight-i),Math.round(this.pageBottom-r))},n.prototype.getQuad=function(t){return this.quadTable[t.id]},n}(),Goe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),qoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Goe(t,n),function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);r>3&&s&&Object.defineProperty(t,e,s)}([I(!1)],t.prototype,"preventDefaults",void 0),t}(Ee),$oe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),e_=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Zoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return $oe(t,n),e_([I("")],t.prototype,"action",void 0),e_([I("")],t.prototype,"cursor",void 0),t}(Ee),t_=function(){function n(){this.size=20,this.intermediatePoints=[],this.gridCollection=[],this.startArray=[],this.targetGridCollection=[],this.sourceGridCollection=[],this.considerWalkable=[]}return n.prototype.lineRouting=function(t){var e=t.connectors.length;if(this.renderVirtualRegion(t),e>0)for(var i=0;i=t.right||e.right<=t.left||e.top>=t.bottom||e.bottom<=t.top)},n.prototype.findEndPoint=function(t,e,i){var r,s;if(e&&""!==t.sourcePortID&&t.sourcePortWrapper||!e&&""!==t.targetPortID&&t.targetPortWrapper){s=zo(r=e?{x:t.sourcePortWrapper.offsetX,y:t.sourcePortWrapper.offsetY}:{x:t.targetPortWrapper.offsetX,y:t.targetPortWrapper.offsetY},void 0,e?t.sourceWrapper.bounds:t.targetWrapper.bounds);var o=e?t.sourcePortWrapper.bounds:t.targetPortWrapper.bounds;r=i?"Top"===s?{x:o.topCenter.x,y:o.topCenter.y}:"Left"===s?{x:o.middleLeft.x,y:o.middleLeft.y}:"Right"===s?{x:o.middleRight.x,y:o.middleRight.y}:{x:o.bottomCenter.x,y:o.bottomCenter.y}:{x:o.center.x,y:o.center.y}}else r=e&&this.startNode||!e&&this.targetNode?e?{x:this.startNode.wrapper.offsetX,y:this.startNode.wrapper.offsetY}:{x:this.targetNode.wrapper.offsetX,y:this.targetNode.wrapper.offsetY}:e?{x:t.sourcePoint.x,y:t.sourcePoint.y}:{x:t.targetPoint.x,y:t.targetPoint.y};return r},n.prototype.refreshConnectorSegments=function(t,e,i,r){var h,c,p,f,g,y,S,b,M,w,C,s=e.sourceID,o=e.targetID,a=e.sourcePortID,l=e.targetPortID;if(function Vre(n,t){var e=0;return n.constraints&qe.LineRouting?e=n.constraints&qe.LineRouting:n.constraints&qe.InheritLineRouting&&(e=t.constraints&rt.LineRouting),e}(e,t)||r){this.startNode=t.nameTable[""+s],this.targetNode=t.nameTable[""+o],this.intermediatePoints=[],this.startArray=[],this.targetGridCollection=[],this.sourceGridCollection=[],this.startGrid=void 0,this.targetGrid=void 0;for(var D=0;D0;){var L=this.startArray.pop();if(L){for(D=0;D1&&(e.segments=[]),this.updateConnectorSegments(t,this.intermediatePoints,this.gridCollection,e,i)){this.considerWalkable=[];break e}this.targetGridCollection.splice(this.targetGridCollection.indexOf(O),1),L=this.startArray.pop()}}L&&this.findPath(L)}}}},n.prototype.checkChildNodes=function(t,e){var i=!1,r=!1;if(t.nodeId.length>=1&&!e)for(var s=0;s1&&this.targetGridCollection[0].nodeId.length>1)for(var c=0;c<=1;c++){for(var d=this.targetGridCollection[parseInt(c.toString(),10)].gridX,u=this.targetGridCollection[parseInt(c.toString(),10)].gridY,p=this.targetGridCollection[parseInt(c.toString(),10)].nodeId,f=void 0,g=0;g=e.right&&t.top<=e.top&&t.bottom>=e.bottom},n.prototype.getEndvalue=function(t,e){return this.gridCollection[t.gridX][t.gridY].walkable?t:"left"===e?this.getEndvalue(this.gridCollection[t.gridX-1][t.gridY],e):"right"===e?this.getEndvalue(this.gridCollection[t.gridX+1][t.gridY],e):"top"===e?this.getEndvalue(this.gridCollection[t.gridX][t.gridY-1],e):"bottom"===e?this.getEndvalue(this.gridCollection[t.gridX][t.gridY+1],e):t},n.prototype.changeValue=function(t,e,i){t.walkable||this.considerWalkable.push(t);for(var r,s=0;s<=e;s++)"left"===i?r=this.gridCollection[t.gridX-s][t.gridY]:"right"===i?r=this.gridCollection[t.gridX+s][t.gridY]:"top"===i?r=this.gridCollection[t.gridX][t.gridY-s]:"bottom"===i&&(r=this.gridCollection[t.gridX][t.gridY+s]),r.walkable||this.considerWalkable.push(r)},n.prototype.getIntermediatePoints=function(t){var e;for(this.intermediatePoints=[];t;)this.intermediatePoints.push({x:t.gridX,y:t.gridY}),t=t.parent;this.intermediatePoints.reverse(),this.intermediatePoints.length>=1&&void 0!==this.intermediatePoints[0]&&void 0!==this.intermediatePoints[1]&&(this.intermediatePoints[0].x===this.intermediatePoints[1].x?this.intermediatePoints[0].y=1&&u.length>1&&(g=u[u.length-2].x!==u[u.length-1].x?u[u.length-2].x>u[u.length-1].x?"Left":"Right":u[u.length-2].y>u[u.length-1].y?"Top":"Bottom"),M>=2&&v===g&&u.length>1&&u.splice(u.length-2,1),v=g);if(u&&u.length>1){for(var w=0;wD.x?S.bounds.middleLeft:S.bounds.middleRight),w===u.length-2&&""===r.targetPortID&&y&&(l=C.x>D.x?y.bounds.middleRight:y.bounds.middleLeft),0===w&&b&&(C.x=b.x,C.y=D.y=b.y),w===u.length-2&&l&&(w>0&&r.targetDecorator&&l.x-D.x<0&&Math.abs(l.x-C.x)0&&r.targetDecorator&&l.x-D.x>0&&Math.abs(l.x-C.x)D.y?S.bounds.topCenter:S.bounds.bottomCenter),w===u.length-2&&""===r.targetPortID&&y&&(l=C.y>D.y?y.bounds.bottomCenter:y.bounds.topCenter),0===w&&b&&(C.y=b.y,C.x=D.x=b.x),w===u.length-2&&l&&(w>0&&r.targetDecorator&&l.y-D.y<0&&Math.abs(l.y-C.y)0&&r.targetDecorator&&l.y-D.y>0&&Math.abs(l.y-C.y)D.x?(p="Left",f=C.x-D.x):(p="Right",f=D.x-C.x):C.y>D.y?(p="Top",f=C.y-D.y):(p="Bottom",f=D.y-C.y),o.push({type:"Orthogonal",length:f,direction:p})}}if(o&&o.length>0){var A=o[o.length-1];if(1===o.length&&(A.length-=20),A.length<10&&2===o.length&&(o.pop(),o.length>0&&(o[0].length-=20,A=o[0])),r.targetDecorator&&("Top"===A.direction||"Bottom"===A.direction)&&A.length>r.targetDecorator.height+1||("Right"===A.direction||"Left"===A.direction)&&A.length>r.targetDecorator.width+1)return r.segments=o,s&&t.connectorPropertyChange(r,{},{type:"Orthogonal",segments:o}),!0}return!1},n.prototype.findPath=function(t){for(var e,i=[],r=this.findNearestNeigbours(t,this.gridCollection,!0),s=0;sl)&&(e.x!==t.gridX||e.y!==t.gridY)&&(i.push(e),o.previousDistance=l,o.afterDistance=o.afterDistance||this.manhattan(Math.abs(e.x-this.targetGrid.gridX),Math.abs(e.y-this.targetGrid.gridY)),o.totalDistance=o.previousDistance+o.afterDistance,o.parent=t)}if(i.length>0)for(s=0;st?i*t+e:i*e+t},n.prototype.manhattan=function(t,e){return t+e},n.prototype.findNearestNeigbours=function(t,e,i){var r=[],s=t.parent;if(s){var o=(t.gridX-s.gridX)/Math.max(Math.abs(t.gridX-s.gridX),1),a=(t.gridY-s.gridY)/Math.max(Math.abs(t.gridY-s.gridY),1);0!==o?(this.isWalkable(t.gridX,t.gridY-1,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX][t.gridY-1])&&r.push(e[t.gridX][t.gridY-1]),this.isWalkable(t.gridX,t.gridY+1,!0)&&this.sourceGridCollection.indexOf(e[t.gridX][t.gridY+1])&&r.push(e[t.gridX][t.gridY+1]),this.isWalkable(t.gridX+o,t.gridY,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX+o][t.gridY])&&r.push(e[t.gridX+o][t.gridY])):0!==a&&(this.isWalkable(t.gridX-1,t.gridY,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX-1][t.gridY])&&r.push(e[t.gridX-1][t.gridY]),this.isWalkable(t.gridX+1,t.gridY,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX+1][t.gridY])&&r.push(e[t.gridX+1][t.gridY]),this.isWalkable(t.gridX,t.gridY+a,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX][t.gridY+a])&&r.push(e[t.gridX][t.gridY+a]))}else this.neigbour(t,"top",r,i),this.neigbour(t,"right",r,i),this.neigbour(t,"bottom",r,i),this.neigbour(t,"left",r,i);return r},n.prototype.neigbour=function(t,e,i,r){for(var o,s=1;s>0;){var a="top"===e||"bottom"===e?t.gridX:"left"===e?t.gridX-s:t.gridX+s,l="right"===e||"left"===e?t.gridY:"top"===e?t.gridY-s:t.gridY+s;if((o=this.gridCollection[parseInt(a.toString(),10)][parseInt(l.toString(),10)])&&(r&&-1===this.sourceGridCollection.indexOf(o)||!r&&-1===this.targetGridCollection.indexOf(o)))return i&&this.isWalkable(a,l)&&i.push(o),s;if(!(a>0&&l>0))break;s++}return null},n.prototype.resetGridColl=function(t,e,i){for(var s,r=1;r>0;){var o="top"===e||"bottom"===e?t.gridX:"left"===e?t.gridX-r:t.gridX+r,a="right"===e||"left"===e?t.gridY:"top"===e?t.gridY-r:t.gridY+r;if((s=this.gridCollection[parseInt(o.toString(),10)][parseInt(a.toString(),10)])&&(i&&-1===this.sourceGridCollection.indexOf(s)||!i&&-1===this.targetGridCollection.indexOf(s))){if(this.isWalkable(o,a))break;var l=this.gridCollection[parseInt(o.toString(),10)][parseInt(a.toString(),10)];this.considerWalkable.push(l)}if(!(o>0&&a>0))break;"top"===e||"left"===e?r--:r++}return null},n.prototype.isWalkable=function(t,e,i){if(t>=0&&t=0&&e0?1:-1,this.isWalkable(h,c-1)&&!this.isWalkable(h-a,c-1)||this.isWalkable(h,c+1)&&!this.isWalkable(h-a,c+1)))return{x:t,y:e};if(0!==l){if(l=l>0?1:-1,this.isWalkable(h-1,c)&&!this.isWalkable(h-1,c-l)||this.isWalkable(h+1,c)&&!this.isWalkable(h+1,c-l))return{x:t,y:e};if(this.findIntermediatePoints(h+1,c,h,c,s,o)||this.findIntermediatePoints(h-1,c,h,c,s,o))return{x:t,y:e}}return this.findIntermediatePoints(h+a,c+l,h,c,s,o)},n.prototype.destroy=function(){},n.prototype.getModuleName=function(){return"LineRouting"},n}(),Joe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),eae=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Joe(t,n),function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);r>3&&s&&Object.defineProperty(t,e,s)}([I(!0)],t.prototype,"inversedAlignment",void 0),t}(Ee),tae=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Oe=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},ET=function(n,t,e,i){return new(e||(e=Promise))(function(r,s){function o(h){try{l(i.next(h))}catch(c){s(c)}}function a(h){try{l(i.throw(h))}catch(c){s(c)}}function l(h){h.done?r(h.value):new e(function(c){c(h.value)}).then(o,a)}l((i=i.apply(n,t||[])).next())})},DT=function(n,t){var i,r,s,o,e={label:0,sent:function(){if(1&s[0])throw s[1];return s[1]},trys:[],ops:[]};return o={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function a(h){return function(c){return function l(h){if(i)throw new TypeError("Generator is already executing.");for(;e;)try{if(i=1,r&&(s=2&h[0]?r.return:h[0]?r.throw||((s=r.return)&&s.call(r),0):r.next)&&!(s=s.call(r,h[1])).done)return s;switch(r=0,s&&(h=[2&h[0],s.value]),h[0]){case 0:case 1:s=h;break;case 4:return e.label++,{value:h[1],done:!1};case 5:e.label++,r=h[1],h=[0];continue;case 7:h=e.ops.pop(),e.trys.pop();continue;default:if(!(s=(s=e.trys).length>0&&s[s.length-1])&&(6===h[0]||2===h[0])){e=0;continue}if(3===h[0]&&(!s||h[1]>s[0]&&h[1]0&&((!s.style||!s.style.fill)&&(o.style.fill="transparent"),(!s.style||!s.style.strokeColor)&&(o.style.strokeColor="transparent")),s.shape&&"UmlActivity"===s.shape.type&&KI(s,o),s.shape&&"SwimLane"===s.shape.type&&aF(s,o),r.nodeDefaults&&Ro(o,s,r.nodeDefaults),r.updateAnnotationText(o.annotations);if(e&&e.connectors)for(a=0;e&&e.connectors&&a0&&0===i.nodes.length)this.clearCollection(),a=!0;else{for(var g=0,v=Object.keys(e.nodes);g0&&0===i.connectors.length)this.clearCollection(!0),a=!0;else{for(var C=0,D=Object.keys(e.connectors);C0){this.renderSelector(!0);break}if(e.selectedItems.constraints){this.renderSelector(!0);break}break;case"snapSettings":this.updateSnapSettings(e);break;case"commandManager":this.initCommands();break;case"layout":o=!0;break;case"segmentThumbShape":this.updateSelector();break;case"dataSourceSettings":this.clear(),"None"===this.layout.type?a=!0:(this.initObjects(),o=!0);break;case"tooltip":i3(this);break;case"rulerSettings":this.updateRulerSettings(e);break;case"layers":this.updateLayer(e);break;case"scrollSettings":this.scrollActions|=ca.PropertyChange,this.updateScrollSettings(e),this.scrollActions&=~ca.PropertyChange,this.scrollSettings.horizontalOffset=-this.scroller.horizontalOffset||0,this.scrollSettings.verticalOffset=-this.scroller.verticalOffset||0;break;case"locale":e.locale!==i.locale&&(this.realActions|=$i.PreventDataInit,n.prototype.refresh.call(this),this.realActions&=~$i.PreventDataInit);break;case"contextMenuSettings":if(void 0!==e.contextMenuSettings.showCustomMenuOnly&&(this.contextMenuSettings.showCustomMenuOnly=e.contextMenuSettings.showCustomMenuOnly),void 0!==e.contextMenuSettings.show&&(this.contextMenuSettings.show=e.contextMenuSettings.show),e.contextMenuSettings.items){for(var A=e.contextMenuSettings.items,x=0,R=Object.keys(A);x0){for(var N=[],T=O.ports.length-1;T>=0;T--)"LineDistribution"===O.ports[parseInt(T.toString(),10)].id.split("_")[1]&&N.push(O.ports[parseInt(T.toString(),10)]);this.removePorts(O,N)}}for(T=0;T0)for(var ue=0,pe=Object.keys(e.nodes);ue0)for(var De=0,xe=Object.keys(e.connectors);De=0;o--)this.commandHandler.expandNode(r[parseInt(o.toString(),10)],this,0!==o);this.canLayout&&this.doLayout(),this.lineRoutingModule?this.connectors.sourceID!==this.connectors.targetID&&this.lineRoutingModule.lineRouting(this):this.constraints&rt.LineRouting&&console.warn('[WARNING] :: Module "LineRouting" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),this.validatePageSize(),this.renderPageBreaks(),this.diagramRenderer.renderSvgGridlines(this.snapSettings,Bd(this.element.id),this.scroller.transform,this.rulerSettings,this.hRuler,this.vRuler),this.commandHandler.initSelectorWrapper(),this.notify("initial-load",{}),this.trigger("load"),this.scroller.setSize(),this.scroller.updateScrollOffsets(),this.isRefreshed||this.refreshDiagramLayer(),(this.scrollSettings.verticalOffset>0||this.scrollSettings.horizontalOffset>0)&&this.updateScrollOffset(),X.isDevice&&(this.tool=Ci.ZoomPan|Ci.SingleSelect),this.notify("initial-end",{}),this.isProtectedOnChange=!1,this.tooltipObject=i3(this),this.diagramActions=ee.Render,this.initCommands();var a=document.getElementsByClassName(this.element.id+"_hiddenUserHandleTemplate");(function Moe(n,t,e,i){var r,s,o,a,l,d=document.getElementById(i).ej2_instances[0];if(n&&t){r=UF(n);for(var u=0,p=e.userHandles;u0;)e[0].parentNode.removeChild(e[0]);var i=document.getElementById(this.element.id+"content");i&&this.element.removeChild(i);var r="measureElement";if(window[""+r]){window[""+r].usageCount-=1;var s="measureElementCount";window[""+s]--,0===window[""+s]&&(window[""+r].parentNode.removeChild(window[""+r]),window[""+r]=null)}}window.domTable={};for(var a=0;a1&&(this.callBlazorModel=!1,this.insertBlazorDiagramObjects(this.selectedItems),this.commandHandler.group(),this.callBlazorModel=!0,this.commandHandler.getBlazorOldValues())},t.prototype.unGroup=function(){this.callBlazorModel=!1,this.insertBlazorDiagramObjects(this.selectedItems),this.commandHandler.unGroup(),this.callBlazorModel=!0,this.commandHandler.getBlazorOldValues()},t.prototype.sendToBack=function(){this.commandHandler.sendToBack()},t.prototype.setActiveLayer=function(e){var i=this.commandHandler.getLayer(e);this.activeLayer=i},t.prototype.addLayer=function(e,i){this.commandHandler.addLayer(e,i)},t.prototype.removeLayer=function(e){this.commandHandler.removeLayer(e,ce())},t.prototype.moveObjects=function(e,i){$(this.layers),this.enableServerDataBinding(!1),this.commandHandler.moveObjects(e,i)},t.prototype.layerObjectUpdate=function(){},t.prototype.sendLayerBackward=function(e){this.layerObjectUpdate(),this.commandHandler.sendLayerBackward(e)},t.prototype.bringLayerForward=function(e){this.layerObjectUpdate(),this.commandHandler.bringLayerForward(e)},t.prototype.cloneLayer=function(e){this.commandHandler.cloneLayer(e)},t.prototype.bringToFront=function(){this.commandHandler.bringToFront()},t.prototype.moveForward=function(){this.commandHandler.sendForward()},t.prototype.sendBackward=function(){this.commandHandler.sendBackward()},t.prototype.getObject=function(e){return this.nameTable[""+e]},t.prototype.getNodeObject=function(e){return $(this.nameTable[""+e])},t.prototype.getConnectorObject=function(e){return $(this.nameTable[""+e])},t.prototype.getActiveLayer=function(){return this.activeLayer},t.prototype.nudgeCommand=function(e,i,r){if("object"!=typeof e&&(this.selectedItems.nodes.length||this.selectedItems.connectors.length)>0){var s=void 0;i.type&&"KEYDOWN"===i.type&&(s=i.type),this.nudge(e,void 0,void 0,s)}},t.prototype.nudge=function(e,i,r,s){var o=0,a=0;"Left"===e||"Right"===e?o=("Left"===e?-1:1)*(i||1):a=("Up"===e?-1:1)*(r||1),"KEYDOWN"===s&&(o*=5,a*=5);var h=this.selectedItems,c=this.selectedItems.wrapper.children[0];if(c instanceof si)this.commandHandler.labelDrag(h.nodes[0],c,o,a);else{var d=$(this.selectedItems);this.protectPropertyChange(!0),this.drag(h,o,a),this.protectPropertyChange(!1);var u={type:"PositionChanged",redoObject:$(this.selectedItems),undoObject:d,category:"Internal"};this.addHistoryEntry(u)}this.refreshCanvasLayers()},t.prototype.insertBlazorDiagramObjects=function(e){},t.prototype.drag=function(e,i,r){if(this.insertBlazorDiagramObjects(e),!(this.bpmnModule&&e instanceof te&&this.bpmnModule.updateAnnotationDrag(e,this,i,r))){if(e instanceof oi){if(this.preventConnectorsUpdate=!0,e.nodes&&e.nodes.length){for(var o=0,a=e.nodes;o0&&o.nodes[0].children){this.fromUndo||(this.rotateUsingButton=!0);for(var h=this.commandHandler.getAllDescendants(o.nodes[0],[]),c=0;c0&&o.nodes[0].children){var g={type:"RotationChanged",redoObject:$(e),undoObject:$(o),category:"Internal",childTable:a};this.commandHandler.addHistoryEntry(g),this.commandHandler.updateSelector()}return u},t.prototype.dragSourceEnd=function(e,i,r){this.insertBlazorDiagramObjects(e),this.commandHandler.dragSourceEnd(e,i,r),this.callBlazorModel&&this.commandHandler.getBlazorOldValues()},t.prototype.dragTargetEnd=function(e,i,r){this.insertBlazorDiagramObjects(e),this.commandHandler.dragTargetEnd(e,i,r),this.callBlazorModel&&this.commandHandler.getBlazorOldValues()},t.prototype.findObjectsUnderMouse=function(e,i){return this.eventHandler.findObjectsUnderMouse(e,i)},t.prototype.findObjectUnderMouse=function(e,i,r){return this.eventHandler.findObjectUnderMouse(e,i,r)},t.prototype.findTargetObjectUnderMouse=function(e,i,r,s,o){return this.eventHandler.findTargetUnderMouse(e,i,r,s,o)},t.prototype.findElementUnderMouse=function(e,i,r,s){return this.eventHandler.findElementUnderMouse(e,i,r,s)},t.prototype.findActionToBeDone=function(e,i,r,s){return this.eventHandler.findActionToBeDone(e,i,r,s)},t.prototype.updateConnectorPort=function(e){if(e.ports.length)for(var i=void 0,r=0,s=e.ports;r=0;s--)if(i.push(r[parseInt(s.toString(),10)]),i.length>this.historyManager.stackLimit)return i}else i=r;return i},t.prototype.getEdges=function(e){return e.outEdge?this.nameTable[e.id].outEdges:this.nameTable[e.id].inEdges},t.prototype.getParentId=function(e){return this.nameTable[""+e].parentId},t.prototype.addConnector=function(e){return this.add(e)},t.prototype.UpdateBlazorDiagramModelCollection=function(e,i,r,s){},t.prototype.UpdateBlazorDiagramModel=function(e,i,r,s){},t.prototype.UpdateBlazorLabelOrPortObjects=function(e,i,r,s){},t.prototype.addBlazorDiagramObjects=function(){},t.prototype.removeNodeEdges=function(e,i,r){var s=this.nameTable[""+e],o=r?s.outEdges:s.inEdges;if(o.length>0)for(var a=0;a0)){for(var c=0;c0))}this.removePortEdges(l,a.element.sourcePortID,a.element.id,h)}a.element.targetID&&this.removeNodeEdges(a.element.targetID,a.element.id,!1)}}this.diagramActions=this.diagramActions|ee.PublicMethod,e.id=e.id||Qe();var u=this.activeLayer;if(!a.cancel&&u&&!u.lock){if(u.objects.indexOf(e.id)<0&&!u.lock&&(u.visible||(u.visible=!0,this.dataBind()),u.objects.push(e.id)),fs(e)===de)(r=new de(this,"connectors",e,!0)).status="New",this.nameTable[r.targetID]&&"TextAnnotation"===this.nameTable[r.targetID].shape.shape&&(r.isBpmnAnnotationConnector=!0,r.constraints=r.constraints&~qe.Delete),Ro(r,e,this.connectorDefaults),this.connectors.push(r),this.initObject(r),!1===e.visible&&this.updateElementVisibility(r.wrapper,r,e.visible),this.updateEdges(r),this.insertBlazorConnector(r);else{if(Ro(r=new te(this,"nodes",e,!0),e,this.nodeDefaults),r.parentId=e.parentId?e.parentId:r.parentId,r.umlIndex=e.umlIndex,r.status="New",(o="TextAnnotation"===r.shape.shape)&&!e.isTextAnnotationCopied&&(r.inEdges=e.inEdges?e.inEdges:r.inEdges),this.nodes.push(r),this.initObject(r,u,void 0,i),o&&this.bpmnModule)for(c=0;c-1&&e.parentId&&this.nameTable[e.parentId]&&"UmlClassifier"===this.nameTable[e.parentId].shape.type){var g=this.nameTable[e.parentId];g.children.splice(r.umlIndex,0,r.id),g.wrapper.children.splice(r.umlIndex,0,r.wrapper),g.wrapper.measure(new me),g.wrapper.arrange(g.wrapper.desiredSize),this.updateDiagramObject(g)}}if(a={element:r,cause:this.diagramActions,diagramAction:this.getDiagramAction(this.diagramActions),state:"Changed",type:"Addition",cancel:!1},this.parentObject&&(a.parentId=this.parentObject.id),"helper"!==e.id&&!(this.diagramActions&ee.PreventCollectionChangeOnDragOver)&&this.triggerEvent(Ce.collectionChange,a),!(this.diagramActions&ee.UndoRedo||this.diagramActions&ee.Group||this.diagramActions&ee.PreventHistory)){var v={type:"CollectionChanged",changeType:"Insert",undoObject:$(e),redoObject:$(e),category:"Internal"};this.addHistoryEntry(v)}this.parentObject=void 0,"SVG"===this.mode&&(this.updateSvgNodes(r),this.updateTextElementValue(r),this.updateDiagramObject(r),o&&this.updateDiagramObject(this.nameTable[r.inEdges[0]]),r.shape.activity&&r.shape.activity.subProcess.processes&&r.shape.activity.subProcess.processes.length&&this.updateProcesses(r),this.updateBridging())}}if(this.protectPropertyChange(s),this.resetDiagramActions(ee.PublicMethod),r&&this.layers.length>1&&this.moveNode(r),this.views)for(var S=0,b=this.views;S=0;l--)this.moveSvgNode(a[parseInt(l.toString(),10)])}for(var h=0,c=i;h=0;o--)r[parseInt(o.toString(),10)]===e.id&&r.splice(o,1);for(var a=0;s.ports&&a=0;s--)if(i=this.nameTable[r[parseInt(s.toString(),10)]])if(this.connectorTable[i.id]=$(i),i.isBpmnAnnotationConnector){var o=this.nameTable[i.targetID];this.removeObjectsFromLayer(i);var a=this.connectors.indexOf(i);-1!==a&&this.connectors.splice(a,1),this.removeElements(i),this.removeFromAQuad(i),delete this.nameTable[i.id];var l=this.nameTable[i.sourceID];if(l){var h=l.outEdges.indexOf(i.id);-1!==h&&l.outEdges.splice(h,1)}e.id!==i.targetID&&this.remove(o)}else this.remove(i)},t.prototype.removeObjectsFromLayer=function(e){if(e.children)for(var i=0;i-1&&(_r(this,e)&&this.unSelect(e),this.layers[parseInt(s.toString(),10)].objects.splice(a,1),delete this.layers[parseInt(s.toString(),10)].zIndexTable[this.nameTable[e.id].zIndex])},t.prototype.removeElements=function(e){if("SVG"===this.mode||"Canvas"===this.mode&&"Native"===e.shape.type){var i=xt(e.id+"_groupElement",this.element.id),r=e;if(r.ports&&r.ports.length>0)for(var s=0;s0){l[parseInt(s.toString(),10)].id.indexOf("icon_content")>0&&"SVG"===this.mode&&((h=xt(l[parseInt(s.toString(),10)].id+"_shape_groupElement",this.element.id))&&h.parentNode.removeChild(h),(h=xt(l[parseInt(s.toString(),10)].id+"_rect_groupElement",this.element.id))&&h.parentNode.removeChild(h));for(var c=0,d=this.views;c=0;o--)a.children[parseInt(o.toString(),10)].children&&(l=n.nameTable[a.children[parseInt(o.toString(),10)].id])&&(l.isLane?qv(n,l):(n.removeDependentConnector(l),n.diagramActions|=ee.PreventHistory,l.constraints&ie.Delete?n.remove(l):V3(n,l,{},!1),n.diagramActions&=~ee.PreventHistory));a&&(i=n.nameTable[a.id])&&qv(n,i)}}(this,e),!(this.diagramActions&ee.UndoRedo||this.diagramActions&ee.PreventHistory)&&(e instanceof te||e instanceof de)){var o={type:"CollectionChanged",changeType:"Remove",undoObject:$(e),redoObject:$(e),category:"Internal"};this.diagramActions&ee.Clear||e.children&&!e.isLane&&!e.isPhase&&e.children.length>0&&this.undoRedoModule&&"None"===this.layout.type&&(this.historyManager.startGroupAction(),s=!0),(e instanceof te||e instanceof de)&&this.deleteDependentConnector&&this.removeDependentConnector(e),!e.isLane&&!e.isPhase&&!(this.diagramActions&ee.Clear)&&!this.isStackChild(e)&&this.addHistoryEntry(o)}"TextAnnotation"===e.shape.shape&&this.removeDependentConnector(e),e.children&&!e.isLane&&!e.isPhase&&(!(this.diagramActions&ee.UndoRedo)||!ce())&&this.deleteGroup(e),e.parentId&&(this.deleteChild(e,void 0,!0),this.nameTable[e.parentId]&&"UmlClassifier"===this.nameTable[e.parentId].shape.type&&(this.updateDiagramObject(this.nameTable[e.parentId]),this.updateConnectorEdges(this.nameTable[e.parentId])));var a=void 0;this.diagramActions=this.diagramActions|ee.PublicMethod;var l=this.nameTable[e.id];if(l instanceof te?("Bpmn"===l.shape.type&&this.bpmnModule&&this.bpmnModule.removeBpmnProcesses(l,this),(l.isLane||l.isPhase||"SwimLane"===l.shape.type)&&(h=l.isLane||l.isPhase?this.nameTable[l.parentId]:this.nameTable[l.id],l.isLane?_3(this,l,h):l.isPhase&&U3(this,l,h)),-1!==(a=this.nodes.indexOf(l))&&(this.crudDeleteNodes.push(this.nameTable[l.id]),this.nodes.splice(a,1),this.updateNodeEdges(l))):(-1!==(a=this.connectors.indexOf(l))&&(this.crudDeleteNodes.push(this.nameTable[l.id]),this.connectors.splice(a,1)),this.updateEdges(l),this.spliceConnectorEdges(e,!0),this.spliceConnectorEdges(e,!1)),!this.isServerUpdate&&!(this.blazorActions&on.GroupClipboardInProcess)&&this.commandHandler.getBlazorOldValues(),s&&this.historyManager.endGroupAction(),_r(this,l)&&this.unSelect(l),!l.isPhase){if(this.removeObjectsFromLayer(e),this.currentDrawingObject&&(this.currentDrawingObject.wrapper=void 0),delete this.nameTable[e.id],i.length>0&&i[0].id===l.id&&l.parentId){var h,d=this.nameTable[l.parentId];d&&d.isLane&&"SwimLane"===this.nameTable[d.parentId].shape.type&&F3(this,h=this.nameTable[d.parentId],d,l)}this.removeElements(l),this.updateBridging(),"SVG"!==this.mode&&this.refreshDiagramLayer(),this.diagramActions&ee.Clear||(this.removeFromAQuad(l),r={element:e,cause:this.diagramActions,diagramAction:this.getDiagramAction(this.diagramActions),state:"Changed",type:"Removal",cancel:!1},"helper"!==e.id&&this.triggerEvent(Ce.collectionChange,r),this.resetTool())}}}else if(i.length>0){this.undoRedoModule&&(this.historyManager.startGroupAction(),this.blazorActions|=on.GroupingInProgress,s=!0);for(var u=0;u=f.wrapper.bounds.width&&"Horizontal"===f.shape.orientation||this.selectedItems.wrapper.bounds.y<=f.wrapper.bounds.y+g&&this.selectedItems.wrapper.bounds.height>=f.wrapper.bounds.height-g&&"Vertical"===f.shape.orientation)&&(TI(f)||f.shape.lanes.length>1)&&this.remove(i[parseInt(u.toString(),10)])}}else this.remove(i[parseInt(u.toString(),10)])}s&&(this.blazorActions&=~on.GroupingInProgress,this.isServerUpdate=!0,this.commandHandler.getBlazorOldValues(),this.UpdateBlazorDiagramModelCollection(void 0,void 0,void 0,!0),this.historyManager.endGroupAction(),this.isServerUpdate=!1),this.clearSelection()}e&&(TI(e)||this.diagramActions&ee.Clear)||this.diagramActions&ee.UndoRedo||this.diagramActions&ee.PreventHistory||!(e instanceof te||e instanceof de)||(o={type:"ConnectionChanged",undoObject:$(e),redoObject:$(e),category:"Internal"},!e.isLane&&!e.isPhase&&!(this.diagramActions&ee.Clear)&&!this.isStackChild(e)&&this.addHistoryEntry(o)),this.tooltipObject.close()},t.prototype.isStackChild=function(e){var i,r=this.nameTable[e.parentId];if(e&&e.parentId&&r.container&&"Stack"===r.container.type&&"UmlClassifier"!==this.nameTable[e.parentId].shape.type){i=!0;var s={sourceIndex:r.wrapper.children.indexOf(e.wrapper),source:e,target:void 0,targetIndex:void 0};this.diagramActions&ee.UndoRedo||this.addHistoryEntry({type:"StackChildPositionChanged",redoObject:{sourceIndex:void 0,source:e,target:void 0,targetIndex:void 0},undoObject:s,category:"Internal"})}return i},t.prototype.deleteChild=function(e,i,r){var s;if(s="string"==typeof e?e:e.id,(i=i?this.nameTable[i.id]:this.nameTable[e.parentId])&&i.children){for(var o=0;o=0;i--)this.removeLayer(this.layers[parseInt(i.toString(),10)].id);this.commandHandler.addLayer({id:"default_layer",visible:!0,lock:!1,objects:[],zIndex:0,objectZIndex:-1,zIndexTable:{}},null,!0),this.setActiveLayer(this.layers[this.layers.length-1].id)},t.prototype.clearObjects=function(e){var i=[];i=e||(i=i.concat(this.nodes)).concat(this.connectors),this.diagramActions=this.diagramActions|ee.Clear;for(var r=0,s=i;r0||"Text"===e.shape.type))if("Text"===e.shape.type)i=e.wrapper.children[0].id.split("_")[1];else for(var f=e.annotations.length-1;f>=0;f--)e.annotations[parseInt(f.toString(),10)].visibility&&(i=e.annotations[parseInt(f.toString(),10)].id);i&&(u=this.getWrapper(e.wrapper,i))}if(e&&u&&!(u instanceof Jn)&&(!function $re(n,t){return"Text"===t.shape.type?t.constraints&ie.ReadOnly:t.constraints&(t instanceof de?qe.ReadOnly:ie.ReadOnly)?n.constraints&Lr.InheritReadOnly?1:0:n.constraints&Lr.ReadOnly?1:0}(u,e)||p)){var g=u.style,v=void 0;v=90>(v=u.bounds.width50?50:e.width,u.style.fontSize)),e.parentId&&"UmlClassifier"===this.nameTable[e.parentId].shape.type?(l.width=e.wrapper.bounds.width-20,c=(e.wrapper.bounds.center.x+r.tx)*r.scale-l.width/2*s-2.5,d=(e.wrapper.bounds.center.y+r.ty)*r.scale-l.height/2*s-3,u.style.textAlign="Left"):(l.width=Math.max(l.width,50),c=(u.bounds.center.x+r.tx)*r.scale-l.width/2*s-2.5,d=(u.bounds.center.y+r.ty)*r.scale-l.height/2*s-3),Ho(y,{id:this.element.id+"_editTextBoxDiv",style:"position: absolute;left:"+c+"px;top:"+d+"px;width:"+(l.width+1)*s+"px;height:"+l.height*s+"px; containerName:"+e.id+";"}),Ho(S,{"aria-label":a,id:this.element.id+"_editBox",style:"width:"+(l.width+1)*s+"px;height:"+l.height*s+"px;resize: none;outline: none;overflow: hidden;;font-family:"+g.fontFamily+";font-size:"+g.fontSize*s+"px;text-align:"+u.style.textAlign.toLocaleLowerCase()+";",class:"e-diagram-text-edit"}),S.style.fontWeight=g.bold?"bold":"",S.style.fontStyle=g.italic?"italic":"",S.style.lineHeight=(1.2*g.fontSize+"px;").toString(),S.style.textDecoration=g.textDecoration?g.textDecoration:"",this.activeLabel.parentId=e.id,this.activeLabel.id=i,u.visible=!1,this.updateDiagramObject(e),this.diagramActions=this.diagramActions|ee.TextEdit,this.isTriggerEvent||(E.add(S,"input",this.eventHandler.inputChange,this.eventHandler),E.add(S,"focusout",this.focusOutEdit,this),S.select())}}}},t.prototype.updateConnectorfixedUserHandles=function(e){if(e.fixedUserHandles.length)for(var i=void 0,r=0,s=e.fixedUserHandles;r0&&this.mindMapChartModule.updateLayout(o,this.nameTable,this.layout,l,this.dataSourceSettings.id,this.dataSourceSettings.root),e=!0;else if(this.radialTreeModule)this.radialTreeModule.updateLayout(o,this.nameTable,this.layout,l),e=!0;else if(this.symmetricalLayoutModule)this.symmetricalLayoutModule.maxIteration=this.layout.maxIteration,this.symmetricalLayoutModule.springLength=this.layout.springLength,this.symmetricalLayoutModule.springFactor=this.layout.springFactor,this.symmetricalLayoutModule.updateLayout(o,this.connectors,this.symmetricalLayoutModule,this.nameTable,this.layout,l),e=!0;else if(this.complexHierarchicalTreeModule){this.canDistribute(a,r)&&(this.lineDistributionModule.diagram=this,this.connectors.forEach(function(R){R.obstaclePointCollection=[]}));var c=this.complexHierarchicalTreeModule.getLayoutNodesCollection(this.nodes);c.length>0&&this.complexHierarchicalTreeModule.doLayout(c,this.nameTable,this.layout,l,this),e=!0,this.canDistribute(a,r)&&this.lineDistributionModule.initLineDistribution(this.layout,this)}else this.flowchartLayoutModule?(this.flowchartLayoutModule.updateLayout(this.nodes,this),e=!0):console.warn("[WARNING] :: Module "+("OrganizationalChart"===this.layout.type?"HierarchicalTree":this.layout.type)+" is not available in Diagram component! You either misspelled the module name or forgot to load it.");if(e){this.preventDiagramUpdate=!0;for(var u={},f=0,g=o;f0)for(var S=0;S0)for(var M=0;M0)for(var s=0,o=r.ports;s0&&function xse(n){var t,e,i,r=[];for(t=0;t0&&y.connectors[w].bezierSettings&&y.connectors[w].bezierSettings.allowSegmentsReset&&(y.connectors[w].segments=[]);if(t.connectors=y.connectors||[],t.dataSourceSettings=y.dataSourceSettings||{},t.dataSourceSettings.doBinding=i,t.height=y.height||"100%",t.setNodeTemplate=r,t.getConnectorDefaults=v,t.getNodeDefaults=g,t.getCustomProperty=o,t.mode=y.mode||"SVG",y.nodes)for(w=0;w0)){var r=this.nodes.filter(function(a){return 0===a.inEdges.length})[0],s=this.convertMindmapToMermaid(r,0);i.push(s),this.updateTextDataSource(i,r.outEdges,1),e=(i=i.filter(function(a){return""!==a.trim()})).join("\n")}return e},t.prototype.updateTextDataSource=function(e,i,r){for(var s=0;s0&&this.updateTextDataSource(e,h,r+1),s++}},t.prototype.convertMindmapToMermaid=function(e,i){var r=e.id,o=" ".repeat(2*(i+1)),a=e.annotations.length>0?e.annotations[0].content.replace(/\n/g," "):"",l=o+a,h=o+r;if(e.shape&&"Basic"===e.shape.type){var c=e.shape;"Rectangle"===c.shape?l=h+"["+a+"]":"Ellipse"===c.shape?l=h+"(("+a+"))":"Hexagon"===c.shape&&(l=h+"{{"+a+"}}")}else if(e.shape&&"Flow"===e.shape.type)"Terminator"===e.shape.shape&&(l=h+"("+a+")");else if(e.shape&&"Path"===e.shape.type){var u=e.shape;u.data===this.bangShape?l=h+"))"+a+"((":u.data===this.cloudShape&&(l=h+")"+a+"(")}return l},t.prototype.saveFlowDiagramInMermaidFormat=function(){var e=this,i=[],r="graph TD\n",s={nodes:this.nodes,edges:this.connectors};return s.nodes.reduce(function(a,l){return a[l.id]=l.annotations.length?l.annotations[0].content:"",a},{}),s.edges.forEach(function(a){var l=a.sourceID,h=a.targetID,p=e.nameTable[""+h],f=e.getNodeShape(e.nameTable[""+l]),g=e.getNodeShape(p),v=a.annotations[0]&&""!==a.annotations[0].content?"|"+a.annotations[0].content+"|":"";-1===i.indexOf(l)?i.push(l):f="",-1===i.indexOf(h)?i.push(h):g="";var y=e.arrowType(a);r+=" "+l+f+" "+y+v+" "+h+g+"\n"}),s.nodes.forEach(function(a){r+=" style "+a.id+" fill:"+a.style.fill+",stroke:"+a.style.strokeColor+",stroke-width:"+a.style.strokeWidth+"px;\n"}),r},t.prototype.arrowType=function(e){var i=e.targetDecorator.shape;return e.style.opacity<1?"~~~":""!==e.style.strokeDashArray?"-.->":"Arrow"===i?e.style.strokeWidth>1?"==>":"--\x3e":"None"===i?"---":"--\x3e"},t.prototype.getNodeShape=function(e){var i=e.annotations.length>0?e.annotations[0].content:"",r=e.shape.shape;if(!r){var s=e.shape.data;return"M 0 0 A 1 1 0 0 0 7 0 A 1 1 0 0 0 0 0 M -1 0 A 1 1 0 0 0 8 0 A 1 1 0 0 0 -1 0"===s?"((("+i+")))":"M 0 0 L 1 -1 L 5 -1 L 6 0 L 0 0"===s?"[/"+i+"\\]":"M 0 1 L 0 6 C 2 7 4 7 6 6 L 6 1 C 5 0 1 0 0 1 C 1 2 5 2 6 1"===s?"[("+i+")]":"M 0 0 L 12 0 L 14 2 L 2 2 L 0 0"===s?"[\\"+i+"\\]":"M 0 0 L 5 0 L 4 1 L 1 1 L 0 0"===s?"[\\"+i+"/]":"M 0 0 L 2 -2 L 11 -2 L 13 0 L 11 2 L 2 2 L 0 0"===s?"{{"+i+"}}":">"+i+"]"}switch(r){case"Terminator":return"(["+i+"])";case"Process":default:return"["+i+"]";case"Decision":return"{"+i+"}";case"Parallelogram":return"[/"+i+"/]";case"Ellipse":return"(("+i+"))";case"PreDefinedProcess":return"[["+i+"]]"}},t.prototype.loadDiagramFromMermaid=function(e){this.layout&&"Flowchart"===this.layout.type&&this.flowchartLayoutModule?this.convertMermaidToFlowChart(e):this.layout&&"MindMap"===this.layout.type&&this.mindMapChartModule?this.convertMermaidToMindmap(e):console.warn('[WARNING] :: Module "FlowchartLayout" or "MindMap" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.countLeadingSpaces=function(e){for(var i=0,r=e.length;i0});this.clear(),this.mermaidNodeBaseCollection=[];var r=[],s={text:"",children:[],currentLevel:0,branch:"Left"},o=[],l=!1,h=!1,c=!1;if(i.length>0){for(var d=function(M){var w=i[parseInt(M.toString(),10)],C=0,D="",A=u.countLeadingSpaces(w),x=w.includes('"`');if(h=w.includes('`"'),c=(l=!!x||l)||c?c:0===A&&M>0,l&&h&&!x)return s.text+="\n"+w,l=!1,"continue";if(!x&&l)return s.text+="\n"+w,"continue";if(l=!h&&l,w.length>0&&(/\s/.test(w[0])&&M>0||0===A)){if(-1!==o.findIndex(function(B){return B.space===A.toString()}))for(var L=o.length-1;L>=0;L--){var O=o[parseInt(L.toString(),10)];if((N=parseFloat(O.space))>A)o.splice(L,1);else{if(N=0;L--){var N,T=o[parseInt(L.toString(),10)];if(!((N=parseFloat(T.space))>A)){var P=o[o.length-1];o.push({space:A.toString(),level:P.level+1});break}o.splice(L,1)}C=o[o.length-1].level}D=w.trim().replace(/^[+-]/,"")}var _={text:D,branch:void 0,children:[],currentLevel:0===M?0:C-1};if(r.length>0){for(;r.length>=C&&0!==r.length;)r.pop();r.length>0&&r[r.length-1].children.push(_)}r.push(_),s=_},u=this,p=0;p0){var c=h[h.length-1];c.arrowType=a[2],""!==a[3]&&(c.label&&c.label.some(function(d){return d.trim().length>0})?c.label.push(a[3]):(c.label=[],c.label[c.parentId.length-1]=a[3]))}h.filter(function(d){return d.parentId&&0===d.parentId.length}).forEach(function(d){d.parentId=null}),i=i.concat(h)}}this.createFlowChart(i),this.doLayout(),this.clearHistory()},t.prototype.createFlowChart=function(e){for(var i=[],r=0;r1)for(var h=0;h|---|--\s*.*?\s*-->|~~~|==>|===|==\s*.*?\s*==>|\s*-\.\s*->|\s*-\.\s*-|\s*-\.\s*.*?\s*\.\s*->|\s*-\..*?\.\s*->)(.*)$/);if(l){i=l[1].trim();var h=l[2].trim();r=l[3].trim();var d=h.match(/(-\.|\\-\\-|==|--|~~)(.*?)(\1>|\.->|==>|\\->|~~>)/),u=void 0,p="";o=null!==(u=d?{text:d[2].trim()||null,arrowType:d[1]+d[3]}:{text:null,arrowType:h}).text?u.text:"",s=(p=u.arrowType).includes("--\x3e")?"single-line-arrow":p.includes("---")?"single-line":p.includes("==>")?"double-line-arrow":p.includes("==")?"double-line":p.includes("~~~")?"wiggly-arrow":p.includes("-.->")||p.includes(".->")?"dotted-arrow":p.includes("-.-")||p.includes(".-")?"dotted":"single-line-arrow"}return[i,r,s,o]},t.prototype.parseStyle=function(e,i){if(e.startsWith("style")){var s=e.match(/^style\s+(\w+)\s+fill:([^,]+),stroke:([^,]+),stroke-width:(\d+)px;/);if(s){var c={id:s[1],fill:s[2],stroke:s[3],strokeWidth:parseInt(s[4],10)},d=i.filter(function(u){return u.id===c.id});d[0].color=c.fill,d[0].stroke=c.stroke,d[0].strokeWidth=c.strokeWidth}}},t.prototype.getNodeData=function(e,i,r){for(var s=[],o=null,a=null,l=0,h="",c=function(v){var y=e[parseInt(v.toString(),10)],S=d.splitNested(y);if(S[0].includes("|")){var b=S[0].match(/\|([^|]*)\|/);b&&(h=b[1]);var M=S[0].split("|");M.length>=3&&(S[0]=M[2].trim())}var w=S[0].trim();if(0===v?o=w:a=w,i.find(function(L){return L.id===w}))l++;else{var D=S.length>1?S[1]:S[0],A=d.getShape(D),x=D.replace(/[\\[\]\\(\\)\\{\\}\\{\\}\\/>]/g,"");s.push({id:w,name:x,shape:A,color:"white",parentId:[]})}},d=this,u=0;u"===h?0===s?(r.trim().length>0&&i.push(r.trim()),r=h,o=h,s++):(r+=h,s++):"]"===h||"}"===h||")"===h?1===s&&h===o?(i.push((r+=h).trim()),r="",s--):s>1?(r+=h,s--):r+=h:r+=h}return r.trim().length>0&&i.push(r.trim()),i},t.prototype.getShape=function(e){var i={};return e.startsWith("(((")?i={type:"Path",data:"M 0 0 A 1 1 0 0 0 7 0 A 1 1 0 0 0 0 0 M -1 0 A 1 1 0 0 0 8 0 A 1 1 0 0 0 -1 0"}:e.startsWith("((")?i={shape:"Ellipse",type:"Basic"}:e.startsWith("([")?i={type:"Flow",shape:"Terminator"}:e.startsWith("(")?i={type:"Flow",shape:"Process"}:e.startsWith("[[")?i={type:"Flow",shape:"PreDefinedProcess"}:e.startsWith("[/")?i=e.endsWith("/]")?{type:"Basic",shape:"Parallelogram"}:{type:"Path",data:"M 0 0 L 1 -1 L 5 -1 L 6 0 L 0 0"}:e.startsWith("[(")?i={type:"Path",data:"M 0 1 L 0 6 C 2 7 4 7 6 6 L 6 1 C 5 0 1 0 0 1 C 1 2 5 2 6 1"}:e.startsWith("[\\")?i=e.endsWith("\\]")?{type:"Path",data:"M 0 0 L 12 0 L 14 2 L 2 2 L 0 0"}:{type:"Path",data:"M 0 0 L 5 0 L 4 1 L 1 1 L 0 0"}:e.startsWith("[")?i={type:"Basic",shape:"Rectangle"}:e.startsWith("{{")?i={type:"Path",data:"M 0 0 L 2 -2 L 11 -2 L 13 0 L 11 2 L 2 2 L 0 0"}:e.startsWith("{")?i={type:"Flow",shape:"Decision"}:e.startsWith(">")&&(i={type:"Path",data:"M 0 0 L 8 0 L 8 2 L 0 2 L 2 1 L 0 0"}),i},t.prototype.getDiagramContent=function(e){return this.printandExportModule?this.printandExportModule.getDiagramContent(e):(console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),"")},t.prototype.exportImage=function(e,i){this.printandExportModule?this.printandExportModule.exportImages(e,i):console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.printImage=function(e,i){this.printandExportModule?(i.printOptions=!0,this.printandExportModule.exportImages(e,i)):console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.setStackLimit=function(e){this.undoRedoModule&&e&&(this.historyManager.stackLimit=e,this.undoRedoModule.applyLimit(this.historyManager.currentEntry,e,this,!0))},t.prototype.clearHistory=function(){this.undoRedoModule&&this.undoRedoModule.clearHistory(this)},t.prototype.getDiagramBounds=function(){if(this.printandExportModule){var e=this.printandExportModule.getDiagramBounds("",{});return e.width=e.width>this.scrollSettings.viewPortWidth?e.width+(e.x>0?e.x:0):this.scrollSettings.viewPortWidth,e.height=e.height>this.scrollSettings.viewPortHeight?e.height+(e.y>0?e.y:0):this.scrollSettings.viewPortHeight,e.x=e.x>0?0:e.x,e.y=e.y>0?0:e.y,e}return console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),new Ne},t.prototype.exportDiagram=function(e){return this.printandExportModule?this.printandExportModule.exportDiagram(e):(console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),"")},t.prototype.print=function(e){this.printandExportModule?this.printandExportModule.print(e):console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.addPorts=function(e,i){var s;this.protectPropertyChange(!0),e=this.nameTable[e.id]||e,i.length>1&&this.startGroupAction();for(var o=function(h){if(e.ports.some(function(y){return y.id===i[parseInt(h.toString(),10)].id}))return"continue";if(e instanceof te?(s=new Es(e,"ports",i[parseInt(h.toString(),10)],!0),e.ports.push(s)):e instanceof de&&(s=new xc(e,"ports",i[parseInt(h.toString(),10)],!0),e.ports.push(s)),e.children)for(var c=e.wrapper,d=0;d1&&this.endGroupAction(),e.wrapper.measure(new me(e.width,e.height)),e.wrapper.arrange(e.wrapper.desiredSize),this.updateDiagramObject(e),this.protectPropertyChange(!1)},t.prototype.addConstraints=function(e,i){return e|i},t.prototype.removeConstraints=function(e,i){return e&~i},t.prototype.addNodeLabels=function(e,i){this.addLabels(e,i)},t.prototype.addConnectorLabels=function(e,i){this.addLabels(e,i)},t.prototype.addLabels=function(e,i){this.protectPropertyChange(!0);var s,r=(e=this.nameTable[e.id]||e).wrapper;i.length>1&&this.startGroupAction();for(var o=0;o1&&this.endGroupAction(),e.wrapper.measure(new me(r.width,r.height)),e.wrapper.arrange(r.desiredSize),this.updateDiagramObject(e),this.protectPropertyChange(!1),this.refreshCanvasLayers()},t.prototype.addChildToUmlNode=function(e,i,r){var s,o,a,l,h="NoWrap";"Class"===e.shape.classifier||"Interface"===e.shape.classifier?"Method"===r?(o=new hm(e,"",i),"Class"===e.shape.classifier?(e.shape.classShape.methods.push(o),s=e.shape.classShape):"Interface"===e.shape.classifier&&(e.shape.interfaceShape.methods.push(o),s=e.shape.interfaceShape),function $se(n,t,e,i){if(e.methods&&e.methods.length){var r=e.methods,s="",o="",a=void 0,l=1,h=void 0,c=0,d=0,u=n.shape,g="Class"===u.classifier?u.classShape:u.interfaceShape;1===r.length?g.attributes.length>0?(c=g.attributes.filter(function(w){return w.isSeparator}).length,h=(l=2+g.attributes.length+c)+1,sT(n,t,l)):h=l+1:(c=g.attributes.filter(function(w){return w.isSeparator}).length,d=g.methods.filter(function(w){return w.isSeparator}).length,h=(l=2+g.attributes.length+c+g.methods.length+d)+1);for(var v=0;v1&&this.startGroupAction();for(var r=i.length-1;r>=0;r--)if(e.children&&e.children.length>0){var s=e.wrapper.children.filter(function(o){return o.id===e.id+"group_container"});s&&s.length>0&&this.removelabelExtension(e,i,r,s[0])}else this.removelabelExtension(e,i,r,e.wrapper);i.length>1&&this.endGroupAction(),this.refreshCanvasLayers()},t.prototype.removePortsExtenion=function(e,i,r,s){for(var o=0;o1&&this.startGroupAction();for(var r=i.length-1;r>=0;r--)if(e.children&&e.children.length>0)for(var s=0;s1&&this.endGroupAction()},t.prototype.getSizeValue=function(e,i){var r;return r=e.toString().indexOf("px")>0?e.toString():e.toString().indexOf("%")>0?void 0!==i?"100%":e.toString():e.toString()+"px",i&&(qa(this),r="calc("+r+" - "+i+"px)"),r},t.prototype.renderRulers=function(){this.rulerSettings.showRulers?(function Gne(n){var t=qa(n),i=Tt("div",{id:n.element.id+"_overlapRuler",style:"height:"+t.height+"px;width:"+t.width+"px;position:absolute;left:0;top:0",class:"e-ruler-overlap"});n.element.insertBefore(i,n.element.firstChild)}(this),eF(this,!0),eF(this,!1)):Gx(this)},t.prototype.intOffPageBackground=function(){var e=new me;e=qa(this);var i=document.getElementById(this.element.id+"content"),r=this.getSizeValue(this.width,e.width),s=this.getSizeValue(this.height,e.height),o=this.rulerSettings.showRulers?"width:"+r+"; height:"+s+";top:"+e.height+"px;left:"+e.width+"px;overflow: scroll;position:absolute;overflow:auto;":"width:"+r+"; height:"+s+";position:absolute; left:0px; top:0px;overflow: auto;",a={id:this.element.id+"content",tabindex:"0",style:o};i?(this.diagramCanvas=i,Za(this.diagramCanvas,o)):(this.diagramCanvas=Tt("div",a),this.element.appendChild(this.diagramCanvas)),this.diagramCanvas.style.background=this.backgroundColor},t.prototype.initDiagram=function(){this.intOffPageBackground(),Ho(this.element,{style:"width:"+this.getSizeValue(this.width)+"; height:"+this.getSizeValue(this.height)+";position:relative;overflow:hidden;"})},t.prototype.renderHiddenUserHandleTemplateLayer=function(e){var r=Tt("div",{class:this.element.id+"_hiddenUserHandleTemplate",style:"width:"+e.width+"px; height:"+e.height+"px;visibility:hidden ; overflow: hidden;"});this.element.appendChild(r)},t.prototype.renderBackgroundLayer=function(e,i){var r=this.createSvg(this.element.id+"_backgroundLayer_svg",e.width,e.height);Za(r,i);var s=Bi("g",{id:this.element.id+"_backgroundImageLayer",class:"e-background-image-layer"});r.appendChild(s);var a=Bi("g",{id:this.element.id+"_backgroundLayer",class:"e-background-layer"});r.appendChild(a),this.diagramCanvas.appendChild(r)},t.prototype.renderGridLayer=function(e,i){var r=this.createSvg(this.element.id+"_gridline_svg",e.width,e.height);r.setAttribute("class","e-grid-layer");var s=Bi("g",{id:this.element.id+"_gridline"}),o=Bi("rect",{id:this.element.id+"_grid_rect",x:"0",y:"0",width:"100%",height:"100%"});if(nm()){var a=new URL(window.location.href);o.setAttribute("fill",""!==a.search?"url(#"+this.element.id+"_pattern)":"url("+location.protocol+"//"+location.host+location.pathname+"#"+this.element.id+"_pattern)")}else o.setAttribute("fill","url(#"+this.element.id+"_pattern)");s.appendChild(o),r.appendChild(s),this.diagramCanvas.appendChild(r),ai(r,{style:i})},t.prototype.renderDiagramLayer=function(e,i){if(this.diagramLayerDiv=Tt("div",{id:this.element.id+"_diagramLayer_div",style:"width:"+e.width+"px; height:"+e.height+"px;"+i}),"SVG"===this.mode){var s=this.createSvg(this.element.id+"_diagramLayer_svg",e.width,e.height);s.style["pointer-events"]="none",s.setAttribute("class","e-diagram-layer");var o=Bi("g",{id:this.element.id+"_diagramLayer"}),a=Bi("g",{});this.diagramLayer=o,s.style["pointer-events"]="all",a.appendChild(o),s.appendChild(a),this.diagramLayerDiv.appendChild(s)}else this.diagramLayer=bo.createCanvas(this.element.id+"_diagram",e.width,e.height),Za(this.diagramLayer,"position:absolute;left:0px;top:0px;"),this.diagramLayerDiv.appendChild(this.diagramLayer);this.diagramCanvas.appendChild(this.diagramLayerDiv)},t.prototype.initLayers=function(){var e="position:absolute;top:0px;left:0px;overflow:hidden;pointer-events:none;",r=document.getElementById(this.element.id).getBoundingClientRect(),s=function boe(){var n=Tt("div",{style:"visibility:hidden; width: 100px"});document.body.appendChild(n);var t=n.getBoundingClientRect().width;n.style.overflow="scroll";var e=Tt("div",{style:"width:100%"});n.appendChild(e);var i=e.getBoundingClientRect().width;return n.parentNode.removeChild(n),t-i}();this.scroller.scrollerWidth=s,this.scroller.setViewPortSize(r.width,r.height),this.renderRulers();var o="measureElement";window[""+o]&&(window[""+o]=null,document.getElementById("measureElement").remove()),function BF(){var n="measureElement";if(window[""+n])window[""+n].usageCount+=1;else{var t=Tt("div",{id:"measureElement",style:"visibility:hidden ; height: 0px ; width: 0px; overflow: hidden;"}),e=Tt("span",{style:"display:inline-block ; line-height: normal"});t.appendChild(e);var i=Tt("img",{alt:"measureElementImage",src:"data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7"});t.appendChild(i);var r=document.createElementNS("http://www.w3.org/2000/svg","svg");r.setAttribute("xmlns:xlink","http://www.w3.org/1999/xlink"),t.appendChild(r);var s=document.createElementNS("http://www.w3.org/2000/svg","path");s.setAttribute("d",""),r.appendChild(s),document.createTextNode("");var a=document.createElementNS("http://www.w3.org/2000/svg","text");a.setAttributeNS("http://www.w3.org/XML/1998/namespace","xml:space","preserve"),r.appendChild(a),window[""+n]=t,window[""+n].usageCount=1,document.body.appendChild(t);var l="measureElementCount";window[""+l]?window[""+l]++:window[""+l]=1}}(),this.renderBackgroundLayer(r,e),this.renderGridLayer(r,e),this.renderDiagramLayer(r,e),this.renderHTMLLayer(r,e),this.renderPortsExpandLayer(r,e),this.renderNativeLayer(r,e),this.renderAdornerLayer(r,e),this.renderHiddenUserHandleTemplateLayer(r)},t.prototype.renderAdornerLayer=function(e,i){var r=Tt("div",{id:this.element.id+"_diagramAdornerLayer",style:"width:"+e.width+"px;height:"+e.height+"px;"+i}),s=Tt("div",{id:this.element.id+"_diagramUserHandleLayer",style:"width:"+e.width+"px;height:"+e.height+"px;"+i});s.setAttribute("class","e-userHandle-layer"),r.appendChild(s);var o=this.createSvg(this.element.id+"_diagramAdorner_svg",e.width,e.height);o.setAttribute("class","e-adorner-layer"),o.style["pointer-events"]="none",this.adornerLayer=Bi("g",{id:this.element.id+"_diagramAdorner"}),this.adornerLayer.style[" pointer-events"]="all",o.appendChild(this.adornerLayer),r.appendChild(o),this.diagramCanvas.appendChild(r);var a=Bi("g",{id:this.element.id+"_SelectorElement"});this.adornerLayer.appendChild(a),ai(o,{style:"pointer-events:none;"})},t.prototype.renderPortsExpandLayer=function(e,i){var r=this.createSvg(this.element.id+"_diagramPorts_svg",e.width,e.height);r.setAttribute("class","e-ports-expand-layer");var s=Bi("g",{id:this.element.id+"_diagramPorts",class:"e-ports-layer",style:"pointer-events: all;"});r.appendChild(s);var o=Bi("g",{id:this.element.id+"_diagramExpander",class:"e-expand-layer",style:"pointer-events: all;"});r.appendChild(o),this.diagramCanvas.appendChild(r),ai(r,{style:i})},t.prototype.renderHTMLLayer=function(e,i){this.htmlLayer=Tt("div",{id:this.element.id+"_htmlLayer",style:"width:"+e.width+"px; height:"+e.height+"px;position:absolute;top:0px;left:0px;overflow:hidden;pointer-events:none;",class:"e-html-layer"});var r=Tt("div",{id:this.element.id+"_htmlLayer_div",style:"position:absolute;top:0px;left:0px;pointer-events:all;"});this.htmlLayer.appendChild(r),this.diagramCanvas.appendChild(this.htmlLayer)},t.prototype.renderNativeLayer=function(e,i){var r=this.createSvg(this.element.id+"_nativeLayer_svg",e.width,e.height),s=Bi("g",{id:this.element.id+"_nativeLayer",style:"pointer-events:all;"});r.appendChild(s),this.diagramLayerDiv.appendChild(r),ai(r,{class:"e-native-layer",style:i})},t.prototype.createSvg=function(e,i,r){var s=document.createElementNS("http://www.w3.org/2000/svg","svg");return ai(s,{id:e,width:i,height:r}),s},t.prototype.updateBazorShape=function(){for(var e=0;e1,i=[],r={},s={},o=[],a=0,l=this.nodes;a0||b&&b.children&&b.children.length>0)&&(M=!1),S&&S.wrapper&&b&&b.wrapper&&M?this.initConnectors(r[""+h],f):i.push(r[""+h])}else b=r[y.targetID],(S=r[y.sourceID])&&S.children&&S.children.length>0||b&&b.children&&b.children.length>0?i.push(r[""+h]):this.initConnectors(r[""+h],f);else r[""+h].children?o.push(h):r[""+h].shape instanceof cT&&r[""+h].shape.activity.subProcess.processes&&r[""+h].shape.activity.subProcess.processes.length>0?s[r[""+h].id]=h:this.initNodes(r[""+h],f);if(this.bpmnModule)for(var w=0,C=this.bpmnModule.bpmnTextAnnotationConnector;w-1&&-1===r.indexOf(c)&&-1===s.indexOf(c)&&r.splice(0,0,c);-1===r.indexOf(o)&&s.push(o)}return r.concat(s)},t.prototype.addToLayer=function(e,i){var r;if(i&&(r=this.commandHandler.getObjectLayer(e.id)),(!i||!r)&&-1===this.activeLayer.objects.indexOf(e.id)&&this.activeLayer.objects.push(e.id),(e instanceof te||e instanceof de)&&("SwimLane"!==e.shape.type||e.children&&e.children.length>0)){if(e.parentId){var s=this.swimlaneZIndexTable[e.parentId],o=this.swimlaneChildTable[e.id];(s&&-1!==s||o&&-1!==o)&&(e.zIndex=this.swimlaneChildTable[e.id])}e instanceof de&&e.sourceID&&e.targetID?-1!==this.activeLayer.objects.indexOf(e.sourceID)&&-1!==this.activeLayer.objects.indexOf(e.targetID)&&this.setZIndex(r||this.activeLayer,e):this.setZIndex(r||this.activeLayer,e)}},t.prototype.updateLayer=function(e){for(var i=0,r=Object.keys(e.layers);i0)for(r=0;rs;l--)r.zIndexTable[parseInt(l.toString(),10)]=r.zIndexTable[l-1],this.nameTable[r.zIndexTable[parseInt(l.toString(),10)]]&&(this.nameTable[r.zIndexTable[parseInt(l.toString(),10)]].zIndex=l);r.zIndexTable[parseInt(a.toString(),10)]=i.id}}},t.prototype.initializeDiagramLayers=function(){for(var e=0;ethis.layers[parseInt(a.toString(),10)].zIndex&&(i=this.layers[parseInt(e.toString(),10)],this.layers[parseInt(e.toString(),10)]=this.layers[parseInt(a.toString(),10)],this.layers[parseInt(a.toString(),10)]=i);0===this.layers.length&&this.commandHandler.addLayer({id:"default_layer",visible:!0,lock:!1,objects:[],zIndex:0,objectZIndex:-1,zIndexTable:{}},null,!0),this.setActiveLayer(this.layers[this.layers.length-1].id)},t.prototype.resetTool=function(){this.eventHandler.resetTool()},t.prototype.initObjectExtend=function(e,i,r){if(r){var s=this.commandHandler.checkBoundaryConstraints(void 0,void 0,e.wrapper.bounds,!0);if("SwimLane"===e.shape.type)for(var o=0,a=Object.keys(i.zIndexTable);o0)&&this.setZIndex(i,e)),e instanceof te){if(r){if("helper"!==e.id&&(o=Zi(this.getNodeDefaults))){if((a=o(e,this))&&a.ports)for(var l=0;l0)for(l=0;l0&&!e.container||e.processId){var r=this.nameTable[e.id];if(!(this.realActions&$i.PreventScale||this.realActions&$i.PreventDrag)){if(r.offsetX&&(this.realActions&$i.EnableGroupAction||!(this.diagramActions&ee.UndoRedo||this.diagramActions&ee.ToolAction||this.diagramActions&ee.PublicMethod))){this.realActions|=$i.PreventScale;var s=r.offsetX-e.wrapper.offsetX;r.offsetX=e.wrapper.offsetX;var o=r.offsetY-e.wrapper.offsetY;r.offsetY=e.wrapper.offsetY,s+o!==0&&this.drag(r,s,o),this.realActions&=~$i.PreventScale}else r.offsetX=e.wrapper.offsetX;r.offsetY&&(this.realActions&$i.EnableGroupAction||!(this.diagramActions&ee.UndoRedo||this.diagramActions&ee.ToolAction||this.diagramActions&ee.PublicMethod))?(this.realActions|=$i.PreventScale,o=r.offsetY-e.wrapper.offsetY,r.offsetY=e.wrapper.offsetY,this.drag(r,0,o),this.realActions&=~$i.PreventScale):r.offsetY=e.wrapper.offsetY,this.diagramActions&&(r.width=e.wrapper.actualSize.width,r.height=e.wrapper.actualSize.height)}}i&&e.children&&e.children.length>0&&(void 0!==this.nameTable[e.id].width?this.scaleObject(e,this.nameTable[e.id].width,!0):this.nameTable[e.id].width=e.wrapper.actualSize.width,void 0!==this.nameTable[e.id].height?this.scaleObject(e,this.nameTable[e.id].height,!1):this.nameTable[e.id].height=e.wrapper.actualSize.height)},t.prototype.initNode=function(e,i,r){var a,p,s=e.initContainer(),o=new Ii;if(this.diagramSettings.inversedAlignment||(s.inversedAlignment=!1),s.children||(s.children=[]),e.children){s.measureChildren=!1,o.id=e.id+"group_container",o.style.fill=e.shape&&"SwimLane"===e.shape.type?e.style.fill:"none",o.style.strokeColor="none",o.horizontalAlignment="Stretch",o.verticalAlignment="Stretch",o.pivot=e.pivot,s.style=e.style,s.padding.left=e.padding.left,s.padding.right=e.padding.right,s.padding.top=e.padding.top,s.padding.bottom=e.padding.bottom,o.children=[],o.preventContainer=!0,e.container&&(o.relativeMode="Object");var l=!!(e.ports&&e.ports.length>0);if(m(e.container)&&!l&&s.children.push(o),e.container&&"Grid"===e.container.type)for(var h=0;h0&&e.wrapper.children[0]instanceof Wv){if(this.setZIndex(this.activeLayer,e),this.connectors.length>0)for(h=0;h0?i.phases.length:0,v="Horizontal"===i.orientation,y=v?i.phases.length||1:s.length+1,S=v?(i.header&&i.hasHeader?1:0)+(i.phases.length>0?1:0)+i.lanes.length:(i.header&&i.hasHeader?1:0)+i.phases.length;if(0===h&&!v&&i.lanes.length&&(S+=1),v?(a=(i.header&&i.hasHeader?1:0)+(h>0?1:0),l=0):(a=i.header&&i.hasHeader?1:0,l=h>0?1:0),s.length>0)for(o+=i.header&&i.hasHeader?i.header.height:0,p=0;pl?d.margin.left=d.margin.left-(u.bounds.left-e.bounds.left):u.children[0].children[1].actualSize.width+r>=d.margin.left&&(d.margin.left=u.children[0].children[1].actualSize.width+r),d.margin.lefta?d.margin.top=d.margin.top-(u.bounds.top-o):u.children[0].children[1].actualSize.height+r>=d.margin.top&&(d.margin.top=u.children[0].children[1].actualSize.height+r),d.margin.left0)for(o=0;o0&&this.updateChildPosition(e)},t.prototype.addBpmnAnnotationConnector=function(e,i){if(e.parentObj instanceof t||e.parentObj instanceof Rd){var r=e.shape,o=""!==r.textAnnotation.textAnnotationTarget&&this.nameTable[r.textAnnotation.textAnnotationTarget],a=o?this.nameTable[r.textAnnotation.textAnnotationTarget]:null,l=null!=a?a.wrapper:null,h=e.ports[0],c={x:0,y:0};switch(r.textAnnotation.textAnnotationDirection){case"Left":h.offset={x:0,y:.5},c.x=i.bounds.left-40,c.y=i.bounds.bottom+30;break;case"Right":h.offset={x:1,y:.5},c.x=i.bounds.right+40,c.y=i.bounds.bottom+30;break;case"Top":h.offset={x:.5,y:0},c.x=i.bounds.right+30,c.y=i.bounds.top-40;break;case"Bottom":h.offset={x:.5,y:1},c.x=i.bounds.right+30,c.y=i.bounds.bottom+40;break;default:h.offset={x:0,y:.5},c.x=i.bounds.left-40,c.y=i.bounds.bottom+30,o&&null!=i&&null!=l&&(i.bounds.left>l.bounds.right?h.offset={x:0,y:.5}:i.bounds.rightl.bounds.top?h.offset={x:.5,y:0}:i.bounds.top0&&this.updateChildPosition(r)}},t.prototype.canExecute=function(){return!0},t.prototype.updateStackProperty=function(e,i,r){e.container&&"Stack"===e.container.type&&(i.width||(i.wrapper.horizontalAlignment="Stretch",i.horizontalAlignment="Stretch"),i.height||(i.verticalAlignment="Stretch",i.wrapper.verticalAlignment="Stretch"),r&&"UmlClassifier"===e.shape.type&&(i.umlIndex=r))},t.prototype.initViews=function(){this.isLoading||(this.views.push(this.element.id),this.views[this.element.id]=this)},t.prototype.initCommands=function(){var e=this.commandManager.commands,i={copy:{execute:this.copyCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.C,keyModifiers:pt.Control}},paste:{execute:this.pasteCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.V,keyModifiers:pt.Control}},cut:{execute:this.cutCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.X,keyModifiers:pt.Control}},delete:{execute:this.removeCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Delete}},selectAll:{execute:this.selectAll.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.A,keyModifiers:pt.Control}},undo:{execute:this.undo.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Z,keyModifiers:pt.Control}},redo:{execute:this.redo.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Y,keyModifiers:pt.Control}},nudgeUp:{execute:this.nudgeCommand.bind(this,"Up"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Up},parameter:"up"},nudgeRight:{execute:this.nudgeCommand.bind(this,"Right"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Right},parameter:"right"},nudgeDown:{execute:this.nudgeCommand.bind(this,"Down"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Down},parameter:"down"},nudgeLeft:{execute:this.nudgeCommand.bind(this,"Left"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Left},parameter:"left"},startEdit:{execute:this.startEditCommad.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.F2}},endEdit:{execute:this.endEditCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Escape}},focusToNextItem:{execute:this.navigateItems.bind(this,!0),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Tab}},focusToPreviousItem:{execute:this.navigateItems.bind(this,!1),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Tab,keyModifiers:pt.Shift}},selectFocusedItem:{execute:this.startEditCommad.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Enter}},bold:{execute:this.fontStyleCommand.bind(this,"bold"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.B,keyModifiers:pt.Control}},italic:{execute:this.fontStyleCommand.bind(this,"italic"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.I,keyModifiers:pt.Control}},underline:{execute:this.fontStyleCommand.bind(this,"underline"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.U,keyModifiers:pt.Control}},duplicate:{execute:this.duplicateCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.D,keyModifiers:pt.Control}},group:{execute:this.groupCommand.bind(this,"group"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.G,keyModifiers:pt.Control}},ungroup:{execute:this.groupCommand.bind(this,"ungroup"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.U,keyModifiers:pt.Control|pt.Shift}},rotateClockwise:{execute:this.rotateCommand.bind(this,"clockwise"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.R,keyModifiers:pt.Control}},rotateAntiClockwise:{execute:this.rotateCommand.bind(this,"antiClockwise"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.L,keyModifiers:pt.Control}},flipHorizontal:{execute:this.flipCommand.bind(this,"horizontal"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.H,keyModifiers:pt.Control}},flipVertical:{execute:this.flipCommand.bind(this,"vertical"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.J,keyModifiers:pt.Control}},pointerTool:{execute:this.toolCommand.bind(this,"pointer"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number1,keyModifiers:pt.Control}},textTool:{execute:this.toolCommand.bind(this,"text"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number2,keyModifiers:pt.Control}},connectTool:{execute:this.toolCommand.bind(this,"connect"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number3,keyModifiers:pt.Control}},freeForm:{execute:this.toolCommand.bind(this,"freeForm"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number5,keyModifiers:pt.Control}},lineTool:{execute:this.toolCommand.bind(this,"line"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number6,keyModifiers:pt.Control}},rectangleTool:{execute:this.toolCommand.bind(this,"rectangle"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number8,keyModifiers:pt.Control}},ellipseTool:{execute:this.toolCommand.bind(this,"ellipse"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number9,keyModifiers:pt.Control}},zoomIn:{execute:this.zoomCommand.bind(this,"zoomIn"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Plus,keyModifiers:pt.Control}},zoomOut:{execute:this.zoomCommand.bind(this,"zoomOut"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Minus,keyModifiers:pt.Control}},shiftUp:{execute:this.shiftCommand.bind(this,"Up"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Up,keyModifiers:pt.Shift}},shiftDown:{execute:this.shiftCommand.bind(this,"Down"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Down,keyModifiers:pt.Shift}},shiftLeft:{execute:this.shiftCommand.bind(this,"Left"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Left,keyModifiers:pt.Shift}},shiftRight:{execute:this.shiftCommand.bind(this,"Right"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Right,keyModifiers:pt.Shift}},alignTextCenter:{execute:this.alignCommand.bind(this,"center"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.C,keyModifiers:pt.Control|pt.Shift}},alignTextLeft:{execute:this.alignCommand.bind(this,"right"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.L,keyModifiers:pt.Control|pt.Shift}},alignTextRight:{execute:this.alignCommand.bind(this,"left"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.R,keyModifiers:pt.Control|pt.Shift}},alignTextTop:{execute:this.alignCommand.bind(this,"top"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.E,keyModifiers:pt.Control|pt.Shift}},alignTextCenterVertical:{execute:this.alignCommand.bind(this,"centerVertical"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.M,keyModifiers:pt.Control|pt.Shift}},alignTextBottom:{execute:this.alignCommand.bind(this,"bottom"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.V,keyModifiers:pt.Control|pt.Shift}},alignJustify:{execute:this.alignCommand.bind(this,"justify"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.J,keyModifiers:pt.Control|pt.Shift}},sendToBack:{execute:this.orderCommand.bind(this,"sendToBack"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.B,keyModifiers:pt.Control|pt.Shift}},bringToFront:{execute:this.orderCommand.bind(this,"bringToFront"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.F,keyModifiers:pt.Control|pt.Shift}},sendBackward:{execute:this.orderCommand.bind(this,"sendBackward"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.BracketLeft,keyModifiers:pt.Control}},bringForward:{execute:this.orderCommand.bind(this,"bringForward"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.BracketRight,keyModifiers:pt.Control}}};this.initCommandManager(e,i)},t.prototype.overrideCommands=function(e,i){for(var r,s=0,o=Object.keys(i);se.zIndex){("HTML"===e.shape.type||"Native"===e.shape.type)&&(o="HTML"===e.shape.type?"html":"native"),s=voe(i,r[parseInt(a.toString(),10)].id,o);break}return s},t.prototype.updateDiagramObject=function(e,i,r){for(var s,o="domTable",a=0,l=this.views;a1&&(d=this.commandHandler.getObjectLayer(e.id)),void 0===d||d&&d.visible||r){var u=Io(this.element.id);window[""+o][s.element.id+"_diagramLayer"]||(window[""+o][s.element.id+"_diagramLayer"]=document.getElementById(s.element.id+"_diagramLayer"));var p=window[""+o][s.element.id+"_diagramLayer"];this.diagramActions&ee.Interactions&&this.updateCanupdateStyle(e.wrapper.children,!0);var f=this.getMidPoint(e);this.diagramRenderer.updateNode(e.wrapper,p,u,void 0,i?void 0:this.getZindexPosition(e,s.element.id),f,this.portCenterPoint),this.updateCanupdateStyle(e.wrapper.children,!0)}}},t.prototype.applyMarginBezier=function(e,i){i.cx=i.cx+e.margin.left,i.cx=i.cx-e.margin.right,i.cy=i.cy+e.margin.top,i.cy=i.cy-e.margin.bottom},t.prototype.getMidPoint=function(e){var i;if(e instanceof de&&"Bezier"===e.type){i=[];for(var r=this.getBezierPoints(e),s=z.getLengthFromListOfPoints(r),o=0;o0&&e.updateView(e));var s=Io(e.element.id);this.renderDiagramElements(e.diagramLayer,e.diagramRenderer,s,void 0,void 0,i);for(var o=0;o0&&this.renderBasicElement(e),!this.diagramActions||!(this.diagramActions&ee.Render)||ee.ToolAction&this.diagramActions||Ds(this)||1!==this.scroller.currentZoom?this.refreshElements(e):this.renderTimer||(this.renderTimer=setTimeout(function(){i.refreshElements(e)},40)))},t.prototype.updatePortVisibility=function(e,i,r){var s;if((e instanceof te||e instanceof de)&&(!this.drawingObject||!this.drawingObject.shape)&&to(e)){for(var a=e.ports,l=!1,h=0;h=0&&this.scroller.removeCollection.splice(l,1);var h=this.nameTable[e[parseInt(a.toString(),10)]];this.updateTextElementValue(h),this.diagramRenderer.renderElement(h.wrapper,s,o,void 0,void 0,void 0,void 0,h.zIndex)}for(var c=0;c0?this.scroller.oldCollectionObjects:void 0,b=Object.keys(S||g.zIndexTable);b.sort(function(N,T){return parseInt(""+N,10)-parseInt(""+T,10)});for(var M=0,w=b;M0?h:0)+"px",y=(this.realActions&$i.vScrollbarMoved?0:-(this.scroller.verticalOffset<0?this.scroller.verticalOffset:0))+"px"):(v="0px",y="0px"),this.realActions&$i.hScrollbarMoved&&(this.realActions=this.realActions&~$i.hScrollbarMoved),this.realActions&$i.vScrollbarMoved&&(this.realActions=this.realActions&~$i.vScrollbarMoved)):(v=(l.x<0?h:-this.scroller.horizontalOffset)+"px",y=(l.y<0?c:-this.scroller.verticalOffset)+"px"),this.diagramLayer.style.left=v,this.diagramLayer.style.top=y,A.tx=-l.x/A.scale,A.ty=-l.y/A.scale);var R=!0;if(o&&(R=!1),this.updateTextElementValue(D),this.refreshing&&D.shape.activity&&D.shape.activity.subProcess&&D.shape.activity.subProcess.processes){for(var L=0;L0){var o=s.children[0],a=o.data;(r.isBezierEditing&&this.selectedItems.connectors[0].id===r.id||"Bezier"!==r.type)&&r.getSegmentElement(r,o,"ComplexHierarchicalTree"===this.layout.type||"HierarchicalTree"===this.layout.type?this.layout.orientation:void 0,void 0,!1),o.data!==a&&(s.measure(new me),s.arrange(s.desiredSize),"SVG"===this.mode&&!e&&this.updateDiagramObject(r))}}else this.constraints&rt.Bridging&&console.warn('[WARNING] :: Module "ConnectorBridging" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.setCursor=function(e){this.diagramRenderer.setCursor(this.diagramCanvas,e)},t.prototype.clearCanvas=function(e){var i=e.contentWidth||e.diagramLayer.width/this.scroller.currentZoom,r=e.contentHeight||e.diagramLayer.height/this.scroller.currentZoom;"SVG"!==e.mode&&bo.getContext(e.diagramLayer).clearRect(0,0,i,r)},t.prototype.updateScrollOffset=function(){this.scroller.setScrollOffset(this.diagramCanvas.scrollLeft,this.diagramCanvas.scrollTop),$I(this),Ds(this)&&this.scroller.virtualizeElements()},t.prototype.setOffset=function(e,i){var r="domTable";window[""+r][this.element.id+"content"]||(window[""+r][this.element.id+"content"]=document.getElementById(this.element.id+"content"));var s=window[""+r][this.element.id+"content"];s&&(s.scrollLeft=e,s.scrollTop=i)},t.prototype.setSize=function(e,i){if(this.diagramLayer&&!this.preventDiagramUpdate){var r=qa(this);e-=r.width,i-=r.height;var s=this.spatialSearch.getPageBounds();s.x*=this.scroller.currentZoom,s.y*=this.scroller.currentZoom,s.width*=this.scroller.currentZoom,s.height*=this.scroller.currentZoom;var o="SVG"===this.mode?1:1.5,a="SVG"===this.mode?gT(this.element.id):this.diagramLayer,h="Canvas"===this.mode&&this.constraints&rt.Virtualization?this.scroller.viewPortHeight:i;a.setAttribute("width",(o*("Canvas"===this.mode&&this.constraints&rt.Virtualization?this.scroller.viewPortWidth:e)).toString()),a.setAttribute("height",(o*h).toString());var c=document.getElementById(this.element.id+"_diagramUserHandleLayer");c&&(c.style.width=e+"px",c.style.height=i+"px");var d={width:e.toString(),height:i.toString()};this.diagramLayerDiv.style.width=e+"px",this.diagramLayerDiv.style.height=i+"px",ai(kF(this.element.id),d),ai(function yoe(n){return xt(n).getElementsByClassName("e-ports-expand-layer")[0]}(this.element.id),d);var u=Pl(this.element.id);ai(u,d),u.parentNode.style.width=e+"px",u.parentNode.style.height=i+"px";var p=Bd(this.element.id);ai(p,d),this.diagramRenderer.updateGrid(this.snapSettings,p,this.scroller.transform,this.rulerSettings,this.hRuler,this.vRuler),ai(yT(this.element.id),d),this.htmlLayer.style.width=e+"px",this.htmlLayer.style.height=i+"px","SVG"!==this.mode&&!Ds(this)&&this.refreshDiagramLayer(),"SVG"===this.mode&&Ds(this)&&this.scroller.virtualizeElements()}},t.prototype.transformLayers=function(){var e=this.spatialSearch.getPageBounds();e.x*=this.scroller.currentZoom,e.y*=this.scroller.currentZoom,e.width*=this.scroller.currentZoom,e.height*=this.scroller.currentZoom,this.diagramRenderer.updateGrid(this.snapSettings,Bd(this.element.id),this.scroller.transform,this.rulerSettings,this.hRuler,this.vRuler),this.diagramRenderer.transformLayers(this.scroller.transform,"SVG"===this.mode),this.diagramActions&ee.DragUsingMouse||this.updateSelector(),this.renderPageBreaks(e)},t.prototype.removePageBreaks=function(){if(this.diagramLayer){var e=PF(this.element.id);if(e&&e.childNodes)for(var i=e.childNodes.length,r=0;rthis.pageSettings.height&&(e=this.pageSettings.height,this.pageSettings.height=this.pageSettings.width,this.pageSettings.width=e):this.pageSettings.height>this.pageSettings.width&&(e=this.pageSettings.width,this.pageSettings.width=this.pageSettings.height,this.pageSettings.height=e)},t.prototype.setOverview=function(e,i){if(e)e&&(this.views.push(e.id),this.views[e.id]=e,e.renderDocument(e),e.diagramRenderer.setLayers(),e.updateView(e),this.renderNodes(e));else{for(var r=0;r1&&this.updateSelectionRectangle(),this.isProtectedOnChange=s},t.prototype.updateSelectionRectangle=function(){for(var e=cm(this.element.id),i=!1,r=0;r1&&this.updateSelectionRectangle(),this.enableServerDataBinding(e)},t.prototype.renderSelectorForAnnotation=function(e,i){this.diagramRenderer.renderResizeHandle(e.wrapper.children[0],i,e.thumbsConstraints,this.scroller.currentZoom,e.constraints,this.scroller.transform,void 0,to(e.annotation),void 0,void 0,e.handleSize)},t.prototype.drawSelectionRectangle=function(e,i,r,s){this.clearSelectorLayer(),this.diagramRenderer.drawSelectionRectangle(e,i,r,s,this.adornerLayer,this.scroller.transform)},t.prototype.renderHighlighter=function(e){var i=Pl(this.element.id);this.diagramRenderer.renderHighlighter(e,i,this.scroller.transform)},t.prototype.clearHighlighter=function(){var e=Pl(this.element.id),i=e.getElementById(e.id+"_highlighter");i&&i.parentNode.removeChild(i)},t.prototype.getNodesConnectors=function(e){for(var i=0;i0;l--)(a=o[l-1]).parentNode.removeChild(a);if(!ce()){var h=mT(this.element.id).childNodes;for(r=h.length;r>0;r--)h[r-1].parentNode.removeChild(h[r-1])}}},t.prototype.getWrapper=function(e,i){var r;i=e.id+"_"+i;for(var s=e instanceof Ii?e:this.getPortContainer(this.nameTable[e.id]),o=0;o0&&this.applyStyle(e,a=r.annotations)}for(i=0;i0){var a=this.selectedItems.connectors[parseInt(i.toString(),10)].annotations;this.applyStyle(e,a)}},t.prototype.applyStyle=function(e,i){for(var r=0;r0)for(var i=0;i0?r[0].zIndex+(e?1:-1):e?0:this.nodes.length+this.connectors.length-1)<0?i=this.nodes.length+this.connectors.length-1:i===this.nodes.length+this.connectors.length&&(i=0);for(var s=0;s0)for(var s=void 0,o=r.children.length-1;o>=0;o--){var a=r.children[parseInt(o.toString(),10)];i.length>0&&-1!==i.indexOf(a.id.split("_groupElement")[0])&&(r.parentNode.insertBefore(a,s||r),s=a)}r&&r.parentNode.removeChild(r)},t.prototype.deleteGroup=function(e){var r=[];e.children&&(r=this.commandHandler.getChildren(e,[])),this.UpdateBlazorDiagramModelCollection(e);for(var s=0,o=r;s0)for(var xe=0;xe0)if("Path"===t.shape.type&&void 0!==n.shape.data)t.wrapper.children[0].data=n.shape.data;else if("Text"===t.shape.type&&void 0!==n.shape.content)t.wrapper.children[0].content=n.shape.content;else if("Image"===t.shape.type&&void 0!==n.shape.source)t.wrapper.children[0].source=n.shape.source;else if("Native"===t.shape.type){for(var r=void 0,s=0;s-1)&&(this.diagramActions&ee.PreventZIndexOnDragging?this.updateDiagramObject(e,!0):this.updateDiagramObject(e)),!s&&d&&(this.lineRoutingModule&&this.diagramActions&&this.constraints&rt.LineRouting&&"helper"!==e.id?this.diagramActions&ee.ToolAction||this.lineRoutingModule.renderVirtualRegion(this,!0):this.diagramActions&&this.constraints&rt.LineRouting&&"helper"!==e.id&&console.warn('[WARNING] :: Module "LineRouting" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),this.updateConnectorEdges(e),"helper"!==e.id&&!(this.diagramActions&ee.ToolAction))))for(var ya=this.spatialSearch.findObjects(e.wrapper.outerBounds),Mo=0;Moe?Math.abs(r-e):Math.abs(e-r),d=s>i?Math.abs(s-i):Math.abs(i-s);(0===c&&0===d||Number.isNaN(c)&&Number.isNaN(d))&&o.laneMargin&&(u=o.margin.left-o.laneMargin.left,p=o.margin.top-o.laneMargin.top);var f=o.width,g=o.height,v=new Ne(0,0,0,0);if(0!==f&&0!==g&&(v=new Ne((0!==r?r:o.offsetX)-f/2,(0!==s?s:o.offsetY)-g/2,f,g)),h){var y=l,b=this.selectedItems.nodes?this.selectedItems.nodes[0]:void 0;if(""!==y.textAnnotation.textAnnotationTarget&&this.nameTable[y.textAnnotation.textAnnotationTarget])if(""===o.parentId||b&&b.shape&&"TextAnnotation"===b.shape.shape){if("Auto"===y.textAnnotation.textAnnotationDirection&&a.children[0]instanceof Ii&&a.children[0].children[0]instanceof Ke){var w=a.children[0],C=document.getElementById(w.id+"_groupElement"),D=document.getElementById(w.children[0].id+"_groupElement");C.removeChild(D),w.children.splice(0,1),this.isProtectedOnChange=!0,this.bpmnModule.setAnnotationPath(v,w,o,y,y.textAnnotation.textAnnotationDirection,this),this.isProtectedOnChange=!1}}else this.isPositionUndo=!0,this.updateTextAnnotationInSwimlane(o,o),this.isPositionUndo=!1;else o.inEdges.length>0&&(x=this.nameTable[""+o.inEdges[0]])&&x.isBpmnAnnotationConnector&&(x.sourcePoint={x:r>e?x.sourcePoint.x+c:x.sourcePoint.x-c,y:s>i?x.sourcePoint.y+d:x.sourcePoint.y-d});this.nodePropertyChange(o,{},R={ports:[{offset:o.ports[0].offset}]})}else for(var L=0,O=o.outEdges;Le?T.offsetX+c:T.offsetX-c,T.offsetY=s>i?T.offsetY+d:T.offsetY-d,R={offsetX:T.offsetX,offsetY:T.offsetY}),this.nodePropertyChange(T,P,R)}}}},t.prototype.updatePorts=function(e,i){if(e&&e.ports.length>0)for(var r=0,s=Object.keys(e.ports);r0)for(var i=0;i0)for(var r=0;r0&&void 0===r.segments&&(e.segments=[]),void 0!==r.shape&&void 0!==e.shape&&e.shape&&"Bpmn"===e.shape.type&&this.bpmnModule&&this.bpmnModule.updateBPMNConnector(e,i,r,this),void 0!==e.constraints?(this.updateThumbConstraints(this.selectedItems.connectors,this.selectedItems),s=!0):s},t.prototype.connectorPropertyChange=function(e,i,r,s,o){if(this.canEnableBlazorObject){var a=$(e);this.insertValue(a,!1)}var d,u,p,f,l=e.wrapper.bounds,h=!1,c=[];if(h=this.connectorProprtyChangeExtend(e,i,r,h),void 0!==r.visible&&this.updateElementVisibility(e.wrapper,e,e.visible),void 0!==r.sourcePoint||void 0!==r.targetPoint||void 0!==r.sourceID||void 0!==r.targetID||void 0!==r.targetPadding||void 0!==r.sourcePortID||void 0!==r.targetPortID||void 0!==r.sourcePadding||void 0!==r.type||void 0!==r.segments||void 0!==r.flip){if(void 0!==r.sourceID&&r.sourceID!==i.sourceID||r.sourcePortID){if(u=this.findInOutConnectPorts(g=this.nameTable[e.sourceID],!1),(!g||Nh(g)||""!==e.sourcePortID&&xd(u))&&(e.sourceWrapper=g?this.getEndNodeWrapper(g,e,!0):void 0,e.sourcePortID&&void 0===r.sourcePortID&&(e.sourcePortWrapper=g?this.getWrapper(g.wrapper,e.sourcePortID):void 0),this.removePortEdges(this.nameTable[i.sourceID]||g,i.sourcePortID||e.sourcePortID,e.id,!1)),void 0!==r.sourceID&&void 0!==i.sourceID&&""!==i.sourceID){var v=this.nameTable[i.sourceID];void 0!==v&&v.outEdges&&-1!==v.outEdges.indexOf(e.id)&&tm(v.outEdges,e.id)}this.updateEdges(e)}if(void 0!==r.targetID&&r.targetID!==i.targetID){if(d=this.findInOutConnectPorts(y=this.nameTable[r.targetID],!0),(!y||da(y)||""!==e.targetPortID&&Lh(d))&&(e.targetWrapper=y?this.getEndNodeWrapper(y,e,!1):void 0,e.targetPortID&&void 0===r.targetPortID&&(e.targetPortWrapper=y?this.getWrapper(y.wrapper,e.targetPortID):void 0),this.removePortEdges(this.nameTable[i.targetID]||y,i.targetPortID||e.targetPortID,e.id,!0)),void 0!==i&&void 0!==i.targetID&&""!==i.targetID){var S=this.nameTable[i.targetID];void 0!==S&&S.inEdges&&-1!==S.inEdges.indexOf(e.id)&&tm(S.inEdges,e.id)}this.updateEdges(e)}var g,y;void 0!==r.sourcePortID&&r.sourcePortID!==i.sourcePortID&&(e.sourceID&&this.nameTable[e.sourceID]&&(p=this.nameTable[e.sourceID].wrapper),!(g=this.nameTable[e.sourceID])||Nh(g)||""!==e.sourcePortID&&xd(u)?e.sourcePortWrapper=p?this.getWrapper(p,r.sourcePortID):void 0:""===e.sourcePortID&&!Nh(g)&&(e.sourcePortWrapper=void 0)),void 0!==r.targetPortID&&r.targetPortID!==i.targetPortID&&(e.targetID&&this.nameTable[e.targetID]&&(f=this.nameTable[e.targetID].wrapper),!(y=this.nameTable[e.targetID])||da(y)||""!==e.targetPortID&&Lh(d)?e.targetPortWrapper=f?this.getWrapper(f,r.targetPortID):void 0:""===e.targetPortID&&!da(y)&&(e.targetPortWrapper=void 0)),void 0!==r.flip&&(e.flip=r.flip,SF(e)),"Orthogonal"===e.type&&this.lineRoutingModule&&this.diagramActions&&this.constraints&rt.LineRouting&&!(this.diagramActions&ee.ToolAction)&&"ComplexHierarchicalTree"!==this.layout.type&&(this.lineRoutingModule.renderVirtualRegion(this,!0),e.sourceID!==e.targetID&&e.segments.length>1&&this.lineRoutingModule.refreshConnectorSegments(this,e,!1)),c=this.getPoints(e)}void 0!==r.style&&Ph(r.style,e.wrapper.children[0]),(c.length>0||void 0!==r.sourceDecorator||void 0!==r.targetDecorator&&function _se(n){return-1!==n.indexOf("shape")||-1!==n.indexOf("pathData")||-1!==n.indexOf("width")||-1!==n.indexOf("height")}(Object.keys(r.targetDecorator))||void 0!==r.cornerRadius)&&(Kp(e,c.length>0?c:e.intermediatePoints,this.diagramActions),void 0!==r.type&&(h=!0),c.length>0&&(e.wrapper.measure(new me(e.wrapper.width,e.wrapper.height)),e.wrapper.arrange(e.wrapper.desiredSize),this.updateConnectorAnnotation(e),this.updateConnectorPort(e),this.updateConnectorfixedUserHandles(e),this.updateObject(e,i,r))),(r.sourcePoint||r.targetPoint||r.segments)&&this.diagramActions===ee.Render&&(h=!0),"Bpmn"===e.shape.type&&"Default"===e.shape.sequence&&"Sequence"===e.shape.flow&&this.commandHandler.updatePathElementOffset(e),s||this.updateBridging(),this.updateAnnotations(r,e),this.updateConnectorPorts(r,e),this.updatefixedUserHandle(r,e),e.wrapper.measure(new me(e.wrapper.width,e.wrapper.height)),e.wrapper.arrange(e.wrapper.desiredSize),!1===l.equals(l,e.wrapper.bounds)&&(this.updateQuad(e),"Drag"!==this.eventHandler.currentAction&&this.updateGroupSize(e)),!0===h&&this.checkSelectedItem(e)&&(!(this.diagramActions&ee.ToolAction)||this.diagramActions&ee.UndoRedo)&&this.updateSelector(),this.preventConnectorsUpdate||(!Ds(this)||Ds(this)&&this.scroller.oldCollectionObjects.indexOf(e.id)>-1)&&(this.diagramActions&ee.PreventZIndexOnDragging?this.updateDiagramObject(e,!0):this.updateDiagramObject(e)),this.updateConnectorEdges(e),this.diagramActions&&"New"!==e.status&&(e.status="Update"),this.triggerPropertyChange(o,e,i,r)},t.prototype.removePortEdges=function(e,i,r,s){if(e)for(var o=0;o0&&e.id===s[s.length-1].id&&(r=!0),r},t.prototype.updateDiagramContainerVisibility=function(e,i){if(e instanceof Cs)for(var r=0;r>"),r instanceof Jn&&this.updateAnnotationWrapper(r,s,o,a)),void 0!==e.template&&(r.content=e.template,this.updateAnnotationWrapper(r,s,o,a))},t.prototype.updateAnnotationWrapper=function(e,i,r,s){for(var o=0,a=this.views;o=0&&this.nodes.splice(s,1),delete this.nameTable[""+r]}var o=this.nodes.indexOf(this.nameTable[this.currentSymbol.id]);o>=0&&this.nodes.splice(o,1)}},t.prototype.selectDragedNode=function(e,i,r){this.currentSymbol=e,"SVG"!==this.mode&&this.refreshDiagramLayer(),this.commandHandler.oldSelectedObjects=rm(this),this.commandHandler.select(e),this.eventHandler.mouseDown(i.event),this.eventHandler.mouseMove(i.event,i),this.preventDiagramUpdate=!1,this.updatePage(),r.style.opacity="0"},t.prototype.initDroppables=function(){var s,o,e=this,i={},r={},a="selectedSymbols";this.droppable=new lR(this.element);var l=5;this.droppable.over=function(h){if(e.rulerSettings.showRulers){var c=document.getElementById(e.element.id+"_vRuler"),d=parseFloat(c.style.width);l=d+1}if(0===e.previousSelectedObjects.length&&!e.currentSymbol&&(e.previousSelectedObjects=e.commandHandler.getSelectedObject()),e.commandHandler.PreventConnectorSplit=!0,e.currentSymbol)h.event.touches&&h.event.touches.length&&e.eventHandler.mouseMove(h.event,h.event.touches);else{var u=null;if(!h.dragData&&"drag"===h.name){var p=document.getElementsByClassName("e-dragclone")[0];p&&(u=p)}if(h.dragData||u){var f=void 0,g=void 0;document.getElementById(e.element.id+"content").focus();var v=e.eventHandler.getMousePosition(h.event),y=void 0,S=u||h.dragData.helper,b=S.getAttribute("paletteId"),M=void 0,w=void 0,C=void 0,D=void 0;if(!b&&h.dragData){e.triggerEvent(Ce.dragEnter,A={source:null,element:f,cancel:!1,diagram:e,dragData:h.dragData.draggedElement.ej2_instances[0].dragData,dragItem:f});var x=void 0,R=void 0;if(A.dragItem){if(A.dragItem.sourcePoint&&A.dragItem.targetPoint?R=new de(e,"connectors",A.dragItem,!0):x=new te(e,"nodes",A.dragItem,!0),e.initObject(f=x||R,void 0,void 0,!0),e.enterObject=f,e.enterTable=r,f instanceof te)x.offsetX=v.x+5+x.width*x.pivot.x,x.offsetY=v.y+x.height*x.pivot.y;else if(f instanceof de){var L=Ne.toBounds([f.sourcePoint,f.targetPoint]),O=v.x-L.left,N=v.y-L.top;f.sourcePoint.x+=O,f.sourcePoint.y+=N,f.targetPoint.x+=O,f.targetPoint.y+=N}e.preventDiagramUpdate=!0,e.currentSymbol=f,"SVG"!==e.mode&&e.refreshDiagramLayer(),e.selectDragedNode(f,h,S),delete e.enterObject,delete e.enterTable,e.droppable[""+a]=S,e.allowServerDataBinding=!0}}if(b){var T=document.getElementById(b).ej2_instances[0];if(e.droppable.sourceElement=T,T){var B=T[""+a];e.allowServerDataBinding=!1,y=$(T[""+a]),i=T.childTable;var j=B.wrapper.children[0].children[0];if(D=function Use(n,t,e){var i=wF(n,t,e,"width"),r=wF(n,t,e,"height");return new me(i,r)}(T,y,j),T[""+a]instanceof te){"TextAnnotation"===B.shape.shape?(y.offsetX=v.x+11+D.width*y.pivot.x,y.offsetY=v.y+11+D.height*y.pivot.y):(y.offsetX=v.x+5+D.width*y.pivot.x,y.offsetY=v.y+D.height*y.pivot.y),"Bpmn"===(x=new te(e,"nodes",y,!0)).shape.type&&x.shape.activity.subProcess.processes&&x.shape.activity.subProcess.processes.length&&(x.shape.activity.subProcess.processes=[]),w=x.previewSize,C=T.symbolDragSize;var Q=T.symbolPreview;if(x.width=(M=x.dragSize).width||C.width||w.width||Q.width||x.width,x.height=M.height||C.height||w.height||Q.height||x.height,"SwimLane"===x.shape.type){if(e.diagramActions|=ee.PreventHistory,x.shape.isLane){x.children=[],s={id:"header"+Qe()},"Horizontal"===x.shape.orientation?(s.width=x.shape.lanes[0].header.width,s.height=x.shape.lanes[0].height):(s.width=x.shape.lanes[0].width,s.height=x.shape.lanes[0].header.height),s.style=x.shape.lanes[0].header.style,s.offsetX=v.x+l+s.width/2,s.offsetY=v.y+s.height/2,e.diagramActions|=ee.PreventCollectionChangeOnDragOver,s=e.add(s),o={id:"body"+Qe()},"Horizontal"===x.shape.orientation?(o.width=x.shape.lanes[0].width-s.width,o.height=x.shape.lanes[0].height,o.offsetX=v.x+l+(x.shape.lanes[0].header.width+o.width/2),o.offsetY=v.y+o.height/2):(o.width=x.shape.lanes[0].width,o.height=x.shape.lanes[0].height-s.height,o.offsetX=v.x+l+o.width/2,o.offsetY=v.y+(x.shape.lanes[0].header.height+o.height/2)),o.style=x.shape.lanes[0].style,o=e.add(o);var oe={id:"group"+Qe(),children:[s.id,o.id]};oe.shape=x.shape,oe.width=x.shape.lanes[0].width,oe.height=x.shape.lanes[0].height,oe.previewSize=x.previewSize,oe.dragSize=x.dragSize,oe.addInfo=x.addInfo,x=e.add(oe),e.diagramActions&=~ee.PreventCollectionChangeOnDragOver}e.diagramActions&=~ee.PreventHistory}if(x.shape.isPhase&&((g="Horizontal"===x.shape.orientation)?(x.offsetX=v.x+l+(x.width||j.actualSize.width)/2,x.offsetY=v.y,x.shape.data="M20,"+x.height/2+" L"+(x.width-20)+","+x.height/2+"z",x.height=1):(x.offsetX=v.x+5,x.offsetY=v.y+(x.height||j.actualSize.height)/2,x.shape.data="M"+x.width/2+",20 L"+x.width/2+","+(x.height-20)+"z",x.width=1)),"UmlClassifier"===x.shape.type&&(x.children=x.width=x.height=void 0,y.children=void 0,"Class"===x.shape.classifier&&x.shape.classShape.methods.length<=0&&x.shape.classShape.attributes.length<=0&&(x.shape.classShape.attributes=[{name:"Name",type:"Type",style:{}}]),"Enumeration"===x.shape.classifier&&x.shape.enumerationShape.members.length<=0&&(x.shape.enumerationShape.members=[{name:"Name"}]),"Interface"===x.shape.classifier&&x.shape.interfaceShape.methods.length<=0&&x.shape.interfaceShape.attributes.length<=0&&(x.shape.interfaceShape.attributes=[{name:"Name",type:"Type",style:{}}])),f=x,y.children){var ue=y;r=e.getChildren(ue,{},i),tT(ue,-ue.offsetX,-ue.offsetY,r,!0,e)}}else if(T[""+a]instanceof de){f=new de(e,"connectors",y,!0);var Me=Ne.toBounds([f.sourcePoint,f.targetPoint]),De=v.x-Me.left,xe=v.y-Me.top;f.sourcePoint.x+=De,f.sourcePoint.y+=xe,f.targetPoint.x+=De,f.targetPoint.y+=xe}f.shape.isLane||(f.id+=Qe());var A={source:T,element:f,cancel:!1,diagram:e,dragData:null,dragItem:f};if(e.enterObject=f,e.enterTable=r,e.triggerEvent(Ce.dragEnter,A),f instanceof te&&"SwimLane"===f.shape.type&&f.shape.isLane){var Ie=A.element,Ve=Ie.shape.lanes[0];g="Horizontal"===Ie.shape.orientation;var ot=e.nameTable[f.children[0]],$e=e.nameTable[f.children[1]];w=f.previewSize,C=T.symbolDragSize,Ve.width=(M=f.dragSize).width||C.width||w.width||Ve.width,Ve.height=M.height||C.height||w.height||Ve.height,g?(s.width=Ve.header.width,s.height=Ve.height,o.width=Ve.width-s.width,o.height=Ve.height,o.offsetX=v.x+l+(Ve.header.width+$e.width/2),o.offsetY=v.y+$e.height/2):(s.width=Ve.width,s.height=Ve.header.height,o.width=Ve.width,o.height=Ve.height-s.height,o.offsetX=v.x+l+$e.width/2,o.offsetY=v.y+(Ve.header.height+$e.height/2)),s.offsetX=v.x+l+ot.width/2,s.offsetY=v.y+ot.height/2,f.width=Ve.width,f.height=Ve.height}if(f instanceof te&&f.shape.isPhase&&(g?f.height=1:f.width=1),!e.activeLayer.lock&&!A.cancel){if(e.preventDiagramUpdate=!0,f.children&&e.findChild(f,r),e.preventDiagramUpdate=!0,f.zIndex!==Number.MIN_VALUE&&(f.zIndex=Number.MIN_VALUE),e.initObject(f,void 0,void 0,!0),e.bpmnModule)for(var Mi=0;Mi0&&(S.segments=[]),d=this.add(S,!0)),(S||d)&&(_v(this)||Uv(this))&&this.select([this.nameTable[S[""+b]]],!1,this.previousSelectedObjects),y.target&&y.target instanceof de&&!0===this.enableConnectorSplit&&this.nameTable[S[""+b]]instanceof te&&(this.commandHandler.connectorSplit(this.nameTable[S[""+b]],y.target),this.commandHandler.PreventConnectorSplit=!1))),this.protectPropertyChange(!1),v=this.nameTable[S[""+b]],S.hasTarget&&(S.nodeId=S.hasTarget,this.remove(S)),this.bpmnModule&&v instanceof te&&S.processId&&(v.processId=S.processId,this.bpmnModule.dropBPMNchild(this.nameTable[v.processId],v,this)),y.cancel||this.endGroupAction(),"SVG"!==this.mode&&this.refreshDiagramLayer(),delete this.droppable[""+c]):(this.triggerEvent(Ce.drop,y={source:h.droppedElement,element:void 0,target:this.eventHandler.hoverNode||this.eventHandler.lastObjectUnderMouse||this,cancel:!1,position:void 0}),S=void 0,b="id"),this.droppable[M="selectedSymbols"]&&this.droppable[""+M].parentNode)gt(this.droppable[""+M]);else for(w=document.getElementsByClassName("e-dragclone"),C=0;C0)for(var p=0;p1),e.previousSelectedObject=null}}},t.prototype.getDropEventArgs=function(e){if(this.eventHandler.lastObjectUnderMouse||this.eventHandler.hoverNode){var i=this.eventHandler.lastObjectUnderMouse||this.eventHandler.hoverNode;e.target=fs(i)===de?{connector:i}:{node:i}}else e.target.diagramId=this.element.id},t.prototype.removeChildInNodes=function(e){if(e){if(e.children)for(var i=0;i1){var l=2;if(e.children&&e.children.length>0)for(;e.children.indexOf(i.objects[s-l])>-1;)l++;this.commandHandler.moveSvgNode(e.id,i.objects[s-l]),this.commandHandler.moveSvgNode(i.objects[s-l],e.id)}else if(o){var h=this.commandHandler.getLayer(this.layerZIndexTable[o.zIndex]).objects[0];h?(this.commandHandler.moveSvgNode(e.id,h),this.commandHandler.updateNativeNodeIndex(e.id,h)):this.moveObjectsUp(e,i)}else this.moveObjectsUp(e,i)},t.prototype.moveObjectsUp=function(e,i){for(var r,s=this.layers.length-1;s>=0;s--)if(r=this.layers[parseInt(s.toString(),10)],i.id!==r.id){var o=this.commandHandler.getLayer(this.layerZIndexTable[r.zIndex]).objects[r.objects.length-1];if(o){this.commandHandler.moveSvgNode(e.id,o),this.commandHandler.moveSvgNode(o,e.id);break}}},t.prototype.insertData=function(e){return this.crudOperation(e,"create",this.getNewUpdateNodes("New"))},t.prototype.updateData=function(e){return this.crudOperation(e,"update",this.getNewUpdateNodes("Update"))},t.prototype.removeData=function(e){return this.crudOperation(e,"destroy",this.getDeletedNodes())},t.prototype.crudOperation=function(e,i,r){if(e){var s=this.parameterMap(e,!(e instanceof de));if(s){var o=e instanceof de?this.dataSourceSettings.connectionDataSource.crudAction[""+i]:this.dataSourceSettings.crudAction[""+i];this.raiseAjaxPost(JSON.stringify(s),o)}return s}var a=r;return this.processCrudCollection(a,this.dataSourceSettings.crudAction[""+i],this.dataSourceSettings.connectionDataSource.crudAction[""+i]),a},t.prototype.processCrudCollection=function(e,i,r){if(e.nodes){var s=[],o=void 0;for(o=0;o0&&this.raiseAjaxPost(JSON.stringify(s),i)}if(e.connectors){for(s=[],o=void 0,o=0;o0&&this.raiseAjaxPost(JSON.stringify(s),r)}},t.prototype.parameterMap=function(e,i){var s,r={},o=i?this.dataSourceSettings:this.dataSourceSettings.connectionDataSource;if(o.id&&(r[o.id]=e.id),o.sourcePointX&&o.sourcePointY&&(r[o.sourcePointX]=e.sourcePoint.x,r[o.sourcePointY]=e.sourcePoint.y),o.targetPointX&&o.targetPointY&&(r[o.targetPointX]=e.targetPoint.x,r[o.targetPointY]=e.targetPoint.y),o.sourceID&&(r[o.sourceID]=e.sourceID),o.targetID&&(r[o.targetID]=e.targetID),o.crudAction&&o.crudAction.customFields&&o.crudAction.customFields.length>0)for(s=0;s"u"||(y.innerHTML=v.innerHTML?v.innerHTML:"",void 0!==v.className&&(y.className=v.className),void 0!==v.id&&(y.id=v.id),void 0!==v.styles&&y.setAttribute("style",v.styles),void 0!==e.ngAttr&&y.setAttribute(e.ngAttr,""),void 0!==v.attrs&&Fe(y,v.attrs)),y};for(var i=0,r=e.tags;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s}!function TZ(n){EC.compile=n.compile}({compile:function Uae(n,t){if("string"==typeof n||"function"==typeof n&&n.prototype&&n.prototype.CSPTemplate)return _ae(n,t);var e=n.elementRef.nativeElement._viewContainerRef,i=n.elementRef.nativeElement.propName;return function(r,s,o){var l=e||s.viewContainerRef,h=l.createEmbeddedView(n,{$implicit:r});/EJS-MENTION|EJS-DROPDOWNLIST/.test(Y("currentInstance.element.nodeName",l))||/E-TABITEM/.test(Y("element.nativeElement.nodeName",l))?h.detectChanges():h.markForCheck();var c=s&&s.registeredTemplate?s.registeredTemplate:Y("currentInstance.registeredTemplate",l);return typeof c["".concat(o=o&&s.registeredTemplate?o:i)]>"u"&&(c["".concat(o)]=[]),c["".concat(o)].push(h),h.rootNodes}}});const Qae=["annotationTemplate"],Gae=["nodeTemplate"],Xae=["userHandleTemplate"];let qae=["addInfo","id","lock","objects","visible","zIndex"],$ae=[],Zae=(()=>{class n extends Hh{constructor(e){super(),this.viewContainerRef=e,Rl("currentInstance",this,this.viewContainerRef),this.registerEvents($ae),this.directivePropList=qae}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-layer"]],inputs:{addInfo:"addInfo",id:"id",lock:"lock",objects:"objects",visible:"visible",zIndex:"zIndex"},features:[yn]}),n})(),Jae=(()=>{class n extends Bh{constructor(){super("layers")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-layers"]],contentQueries:function(e,i,r){if(1&e&&dn(r,Zae,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),Kae=["action","cursor"],ele=[],tle=(()=>{class n extends Hh{constructor(e){super(),this.viewContainerRef=e,Rl("currentInstance",this,this.viewContainerRef),this.registerEvents(ele),this.directivePropList=Kae}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-cursormap"]],inputs:{action:"action",cursor:"cursor"},features:[yn]}),n})(),ile=(()=>{class n extends Bh{constructor(){super("customcursor")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-cursormaps"]],contentQueries:function(e,i,r){if(1&e&&dn(r,tle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),rle=["alignment","cornerRadius","displacement","fill","handleStrokeColor","handleStrokeWidth","height","iconStrokeColor","iconStrokeWidth","id","offset","padding","pathData","tooltip","visibility","width"],nle=[],sle=(()=>{class n extends Hh{constructor(e){super(),this.viewContainerRef=e,Rl("currentInstance",this,this.viewContainerRef),this.registerEvents(nle),this.directivePropList=rle}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-connector-fixeduserhandle"]],inputs:{alignment:"alignment",cornerRadius:"cornerRadius",displacement:"displacement",fill:"fill",handleStrokeColor:"handleStrokeColor",handleStrokeWidth:"handleStrokeWidth",height:"height",iconStrokeColor:"iconStrokeColor",iconStrokeWidth:"iconStrokeWidth",id:"id",offset:"offset",padding:"padding",pathData:"pathData",tooltip:"tooltip",visibility:"visibility",width:"width"},features:[yn]}),n})(),ole=(()=>{class n extends Bh{constructor(){super("fixeduserhandles")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-connector-fixeduserhandles"]],contentQueries:function(e,i,r){if(1&e&&dn(r,sle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),ale=["addInfo","alignment","annotationType","constraints","content","displacement","dragLimit","height","horizontalAlignment","hyperlink","id","margin","offset","rotateAngle","rotationReference","segmentAngle","style","template","tooltip","type","verticalAlignment","visibility","width"],lle=[],hle=(()=>{class n extends Hh{constructor(e){super(),this.viewContainerRef=e,Rl("currentInstance",this,this.viewContainerRef),this.registerEvents(lle),this.directivePropList=ale}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-connector-annotation"]],inputs:{addInfo:"addInfo",alignment:"alignment",annotationType:"annotationType",constraints:"constraints",content:"content",displacement:"displacement",dragLimit:"dragLimit",height:"height",horizontalAlignment:"horizontalAlignment",hyperlink:"hyperlink",id:"id",margin:"margin",offset:"offset",rotateAngle:"rotateAngle",rotationReference:"rotationReference",segmentAngle:"segmentAngle",style:"style",template:"template",tooltip:"tooltip",type:"type",verticalAlignment:"verticalAlignment",visibility:"visibility",width:"width"},features:[yn]}),n})(),cle=(()=>{class n extends Bh{constructor(){super("annotations")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-connector-annotations"]],contentQueries:function(e,i,r){if(1&e&&dn(r,hle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),dle=["addInfo","allowNodeOverlap","annotations","bezierSettings","bridgeSpace","connectionPadding","connectorSpacing","constraints","cornerRadius","dragSize","excludeFromLayout","fixedUserHandles","flip","flipMode","hitPadding","id","margin","maxSegmentThumb","ports","previewSize","segmentThumbShape","segmentThumbSize","segments","shape","sourceDecorator","sourceID","sourcePadding","sourcePoint","sourcePortID","style","symbolInfo","targetDecorator","targetID","targetPadding","targetPoint","targetPortID","tooltip","type","visible","wrapper","zIndex"],ule=[],v_=(()=>{class n extends Hh{constructor(e){super(),this.viewContainerRef=e,this.tags=["fixedUserHandles","annotations"],Rl("currentInstance",this,this.viewContainerRef),this.registerEvents(ule),this.directivePropList=dle}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-connector"]],contentQueries:function(e,i,r){if(1&e&&(dn(r,ole,5),dn(r,cle,5)),2&e){let s;Kr(s=en())&&(i.childFixedUserHandles=s.first),Kr(s=en())&&(i.childAnnotations=s.first)}},inputs:{addInfo:"addInfo",allowNodeOverlap:"allowNodeOverlap",annotations:"annotations",bezierSettings:"bezierSettings",bridgeSpace:"bridgeSpace",connectionPadding:"connectionPadding",connectorSpacing:"connectorSpacing",constraints:"constraints",cornerRadius:"cornerRadius",dragSize:"dragSize",excludeFromLayout:"excludeFromLayout",fixedUserHandles:"fixedUserHandles",flip:"flip",flipMode:"flipMode",hitPadding:"hitPadding",id:"id",margin:"margin",maxSegmentThumb:"maxSegmentThumb",ports:"ports",previewSize:"previewSize",segmentThumbShape:"segmentThumbShape",segmentThumbSize:"segmentThumbSize",segments:"segments",shape:"shape",sourceDecorator:"sourceDecorator",sourceID:"sourceID",sourcePadding:"sourcePadding",sourcePoint:"sourcePoint",sourcePortID:"sourcePortID",style:"style",symbolInfo:"symbolInfo",targetDecorator:"targetDecorator",targetID:"targetID",targetPadding:"targetPadding",targetPoint:"targetPoint",targetPortID:"targetPortID",tooltip:"tooltip",type:"type",visible:"visible",wrapper:"wrapper",zIndex:"zIndex"},features:[yn]}),n})(),m_=(()=>{class n extends Bh{constructor(){super("connectors")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-connectors"]],contentQueries:function(e,i,r){if(1&e&&dn(r,v_,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),ple=["cornerRadius","fill","handleStrokeColor","handleStrokeWidth","height","iconStrokeColor","iconStrokeWidth","id","margin","offset","padding","pathData","tooltip","visibility","width"],fle=[],gle=(()=>{class n extends Hh{constructor(e){super(),this.viewContainerRef=e,Rl("currentInstance",this,this.viewContainerRef),this.registerEvents(fle),this.directivePropList=ple}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-node-fixeduserhandle"]],inputs:{cornerRadius:"cornerRadius",fill:"fill",handleStrokeColor:"handleStrokeColor",handleStrokeWidth:"handleStrokeWidth",height:"height",iconStrokeColor:"iconStrokeColor",iconStrokeWidth:"iconStrokeWidth",id:"id",margin:"margin",offset:"offset",padding:"padding",pathData:"pathData",tooltip:"tooltip",visibility:"visibility",width:"width"},features:[yn]}),n})(),vle=(()=>{class n extends Bh{constructor(){super("fixeduserhandles")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-node-fixeduserhandles"]],contentQueries:function(e,i,r){if(1&e&&dn(r,gle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),mle=["addInfo","annotationType","constraints","content","dragLimit","height","horizontalAlignment","hyperlink","id","margin","offset","rotateAngle","rotationReference","style","template","tooltip","type","verticalAlignment","visibility","width"],yle=[],Sle=(()=>{class n extends Hh{constructor(e){super(),this.viewContainerRef=e,Rl("currentInstance",this,this.viewContainerRef),this.registerEvents(yle),this.directivePropList=mle}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-node-annotation"]],inputs:{addInfo:"addInfo",annotationType:"annotationType",constraints:"constraints",content:"content",dragLimit:"dragLimit",height:"height",horizontalAlignment:"horizontalAlignment",hyperlink:"hyperlink",id:"id",margin:"margin",offset:"offset",rotateAngle:"rotateAngle",rotationReference:"rotationReference",style:"style",template:"template",tooltip:"tooltip",type:"type",verticalAlignment:"verticalAlignment",visibility:"visibility",width:"width"},features:[yn]}),n})(),Ile=(()=>{class n extends Bh{constructor(){super("annotations")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-node-annotations"]],contentQueries:function(e,i,r){if(1&e&&dn(r,Sle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),ble=["addInfo","connectionDirection","constraints","height","horizontalAlignment","id","inEdges","margin","offset","outEdges","pathData","shape","style","tooltip","verticalAlignment","visibility","width"],Mle=[],wle=(()=>{class n extends Hh{constructor(e){super(),this.viewContainerRef=e,Rl("currentInstance",this,this.viewContainerRef),this.registerEvents(Mle),this.directivePropList=ble}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-node-port"]],inputs:{addInfo:"addInfo",connectionDirection:"connectionDirection",constraints:"constraints",height:"height",horizontalAlignment:"horizontalAlignment",id:"id",inEdges:"inEdges",margin:"margin",offset:"offset",outEdges:"outEdges",pathData:"pathData",shape:"shape",style:"style",tooltip:"tooltip",verticalAlignment:"verticalAlignment",visibility:"visibility",width:"width"},features:[yn]}),n})(),Cle=(()=>{class n extends Bh{constructor(){super("ports")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-node-ports"]],contentQueries:function(e,i,r){if(1&e&&dn(r,wle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),Ele=["addInfo","annotations","backgroundColor","borderColor","borderWidth","branch","children","collapseIcon","columnIndex","columnSpan","columns","constraints","container","data","dragSize","excludeFromLayout","expandIcon","fixedUserHandles","flip","flipMode","height","horizontalAlignment","id","isExpanded","layoutInfo","margin","maxHeight","maxWidth","minHeight","minWidth","offsetX","offsetY","padding","pivot","ports","previewSize","rotateAngle","rowIndex","rowSpan","rows","shadow","shape","style","symbolInfo","tooltip","verticalAlignment","visible","width","wrapper","zIndex"],Dle=[],y_=(()=>{class n extends Hh{constructor(e){super(),this.viewContainerRef=e,this.tags=["fixedUserHandles","annotations","ports"],Rl("currentInstance",this,this.viewContainerRef),this.registerEvents(Dle),this.directivePropList=Ele}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-node"]],contentQueries:function(e,i,r){if(1&e&&(dn(r,vle,5),dn(r,Ile,5),dn(r,Cle,5)),2&e){let s;Kr(s=en())&&(i.childFixedUserHandles=s.first),Kr(s=en())&&(i.childAnnotations=s.first),Kr(s=en())&&(i.childPorts=s.first)}},inputs:{addInfo:"addInfo",annotations:"annotations",backgroundColor:"backgroundColor",borderColor:"borderColor",borderWidth:"borderWidth",branch:"branch",children:"children",collapseIcon:"collapseIcon",columnIndex:"columnIndex",columnSpan:"columnSpan",columns:"columns",constraints:"constraints",container:"container",data:"data",dragSize:"dragSize",excludeFromLayout:"excludeFromLayout",expandIcon:"expandIcon",fixedUserHandles:"fixedUserHandles",flip:"flip",flipMode:"flipMode",height:"height",horizontalAlignment:"horizontalAlignment",id:"id",isExpanded:"isExpanded",layoutInfo:"layoutInfo",margin:"margin",maxHeight:"maxHeight",maxWidth:"maxWidth",minHeight:"minHeight",minWidth:"minWidth",offsetX:"offsetX",offsetY:"offsetY",padding:"padding",pivot:"pivot",ports:"ports",previewSize:"previewSize",rotateAngle:"rotateAngle",rowIndex:"rowIndex",rowSpan:"rowSpan",rows:"rows",shadow:"shadow",shape:"shape",style:"style",symbolInfo:"symbolInfo",tooltip:"tooltip",verticalAlignment:"verticalAlignment",visible:"visible",width:"width",wrapper:"wrapper",zIndex:"zIndex"},features:[yn]}),n})(),S_=(()=>{class n extends Bh{constructor(){super("nodes")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-nodes"]],contentQueries:function(e,i,r){if(1&e&&dn(r,y_,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})();const xle=["animationComplete","click","collectionChange","commandExecute","connectionChange","contextMenuBeforeItemRender","contextMenuClick","contextMenuOpen","created","dataLoaded","doubleClick","dragEnter","dragLeave","dragOver","drop","elementDraw","expandStateChange","fixedUserHandleClick","historyChange","historyStateChange","keyDown","keyUp","load","loaded","mouseEnter","mouseLeave","mouseOver","mouseWheel","onFixedUserHandleMouseDown","onFixedUserHandleMouseEnter","onFixedUserHandleMouseLeave","onFixedUserHandleMouseUp","onImageLoad","onUserHandleMouseDown","onUserHandleMouseEnter","onUserHandleMouseLeave","onUserHandleMouseUp","positionChange","propertyChange","rotateChange","scrollChange","segmentChange","segmentCollectionChange","selectionChange","sizeChange","sourcePointChange","targetPointChange","textEdit"],Tle=[""];let Ale=(()=>{let n=class extends zl{constructor(e,i,r,s){super(),this.ngEle=e,this.srenderer=i,this.viewContainerRef=r,this.injector=s,this.tags=["layers","customCursor","connectors","nodes"],this.element=this.ngEle.nativeElement,this.injectedModules=this.injectedModules||[];try{let o=this.injector.get("DiagramsHierarchicalTree");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsMindMap");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsRadialTree");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsComplexHierarchicalTree");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsDataBinding");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsSnapping");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsPrintAndExport");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsBpmnDiagrams");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsSymmetricLayout");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsConnectorBridging");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsUndoRedo");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsLayoutAnimation");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsDiagramContextMenu");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsLineRouting");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsConnectorEditing");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsLineDistribution");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsEj1Serialization");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsFlowchartLayout");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}this.registerEvents(xle),this.addTwoWay.call(this,Tle),Rl("currentInstance",this,this.viewContainerRef),this.context=new u_}ngOnInit(){this.context.ngOnInit(this)}ngAfterViewInit(){this.context.ngAfterViewInit(this)}ngOnDestroy(){this.context.ngOnDestroy(this)}ngAfterContentChecked(){this.tagObjects[0].instance=this.childLayers,this.childCustomCursor&&(this.tagObjects[1].instance=this.childCustomCursor),this.childConnectors&&(this.tagObjects[2].instance=this.childConnectors),this.childNodes&&(this.tagObjects[3].instance=this.childNodes),this.context.ngAfterContentChecked(this)}};return n.\u0275fac=function(e){return new(e||n)(Ot($c),Ot(lM),Ot(xn),Ot(Wo))},n.\u0275cmp=Bb({type:n,selectors:[["ejs-diagram"]],contentQueries:function(e,i,r){if(1&e&&(dn(r,Qae,5),dn(r,Gae,5),dn(r,Xae,5),dn(r,Jae,5),dn(r,ile,5),dn(r,m_,5),dn(r,S_,5)),2&e){let s;Kr(s=en())&&(i.annotationTemplate=s.first),Kr(s=en())&&(i.nodeTemplate=s.first),Kr(s=en())&&(i.userHandleTemplate=s.first),Kr(s=en())&&(i.childLayers=s.first),Kr(s=en())&&(i.childCustomCursor=s.first),Kr(s=en())&&(i.childConnectors=s.first),Kr(s=en())&&(i.childNodes=s.first)}},inputs:{addInfo:"addInfo",annotationTemplate:"annotationTemplate",backgroundColor:"backgroundColor",bridgeDirection:"bridgeDirection",commandManager:"commandManager",connectorDefaults:"connectorDefaults",connectors:"connectors",constraints:"constraints",contextMenuSettings:"contextMenuSettings",customCursor:"customCursor",dataSourceSettings:"dataSourceSettings",diagramSettings:"diagramSettings",drawingObject:"drawingObject",enableConnectorSplit:"enableConnectorSplit",enablePersistence:"enablePersistence",enableRtl:"enableRtl",fixedUserHandleTemplate:"fixedUserHandleTemplate",getConnectorDefaults:"getConnectorDefaults",getCustomCursor:"getCustomCursor",getCustomProperty:"getCustomProperty",getCustomTool:"getCustomTool",getDescription:"getDescription",getNodeDefaults:"getNodeDefaults",height:"height",historyManager:"historyManager",layers:"layers",layout:"layout",locale:"locale",mode:"mode",nodeDefaults:"nodeDefaults",nodeTemplate:"nodeTemplate",nodes:"nodes",pageSettings:"pageSettings",rulerSettings:"rulerSettings",scrollSettings:"scrollSettings",segmentThumbShape:"segmentThumbShape",segmentThumbSize:"segmentThumbSize",selectedItems:"selectedItems",serializationSettings:"serializationSettings",setNodeTemplate:"setNodeTemplate",snapSettings:"snapSettings",tool:"tool",tooltip:"tooltip",updateSelection:"updateSelection",userHandleTemplate:"userHandleTemplate",width:"width"},outputs:{animationComplete:"animationComplete",click:"click",collectionChange:"collectionChange",commandExecute:"commandExecute",connectionChange:"connectionChange",contextMenuBeforeItemRender:"contextMenuBeforeItemRender",contextMenuClick:"contextMenuClick",contextMenuOpen:"contextMenuOpen",created:"created",dataLoaded:"dataLoaded",doubleClick:"doubleClick",dragEnter:"dragEnter",dragLeave:"dragLeave",dragOver:"dragOver",drop:"drop",elementDraw:"elementDraw",expandStateChange:"expandStateChange",fixedUserHandleClick:"fixedUserHandleClick",historyChange:"historyChange",historyStateChange:"historyStateChange",keyDown:"keyDown",keyUp:"keyUp",load:"load",loaded:"loaded",mouseEnter:"mouseEnter",mouseLeave:"mouseLeave",mouseOver:"mouseOver",mouseWheel:"mouseWheel",onFixedUserHandleMouseDown:"onFixedUserHandleMouseDown",onFixedUserHandleMouseEnter:"onFixedUserHandleMouseEnter",onFixedUserHandleMouseLeave:"onFixedUserHandleMouseLeave",onFixedUserHandleMouseUp:"onFixedUserHandleMouseUp",onImageLoad:"onImageLoad",onUserHandleMouseDown:"onUserHandleMouseDown",onUserHandleMouseEnter:"onUserHandleMouseEnter",onUserHandleMouseLeave:"onUserHandleMouseLeave",onUserHandleMouseUp:"onUserHandleMouseUp",positionChange:"positionChange",propertyChange:"propertyChange",rotateChange:"rotateChange",scrollChange:"scrollChange",segmentChange:"segmentChange",segmentCollectionChange:"segmentCollectionChange",selectionChange:"selectionChange",sizeChange:"sizeChange",sourcePointChange:"sourcePointChange",targetPointChange:"targetPointChange",textEdit:"textEdit"},features:[yn],decls:0,vars:0,template:function(e,i){},encapsulation:2,changeDetection:0}),fb([AT()],n.prototype,"annotationTemplate",void 0),fb([AT()],n.prototype,"nodeTemplate",void 0),fb([AT()],n.prototype,"userHandleTemplate",void 0),n=fb([Bae([u_])],n),n})(),Lle=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Am({type:n}),n.\u0275inj=mf({imports:[[sq]]}),n})();const Nle=["diagram"];let Ole=(()=>{class n{constructor(){this.port1=[{id:"port1",offset:{x:.5,y:.5},visibility:ti.Visible,connectionDirection:"Right"}],this.port2=[{id:"port2",offset:{x:0,y:0},visibility:ti.Visible,connectionDirection:"Left"}]}portDirection(){this.diagram.nodes[0].ports[0].connectionDirection="Top"}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275cmp=Bb({type:n,selectors:[["app-container"]],viewQuery:function(i,r){if(1&i&&function uP(n,t,e){const i=xi();i.firstCreatePass&&(cP(i,new aP(n,t,e),-1),2==(2&t)&&(i.staticViewQueries=!0)),hP(i,Se(),t)}(Nle,5),2&i){let s;Kr(s=en())&&(r.diagram=s.first)}},standalone:!0,features:[PP([]),RP],decls:9,vars:10,consts:[["id","diagram","width","100%","height","580px"],["diagram",""],["id","node1",3,"offsetX","offsetY","width","height","ports"],["id","node2",3,"offsetX","offsetY","width","height","ports"],["id","connector","type","Orthogonal","sourceID","node1","sourcePortID","port1","targetID","node2","targetPortID","port2"],[3,"click"]],template:function(i,r){1&i&&(Qu(0,"ejs-diagram",0,1)(2,"e-nodes"),Uy(3,"e-node",2)(4,"e-node",3),Gu(),Qu(5,"e-connectors"),Uy(6,"e-connector",4),Gu()(),Qu(7,"button",5),aw("click",function(){return r.portDirection()}),function MP(n,t=""){const e=Se(),i=xi(),r=n+Ut,s=i.firstCreatePass?xu(i,r,1,t,null):i.data[r],o=wP(i,e,s,t,n);e[r]=o,Rm()&&ly(i,e,o,s),ol(s,!1)}(8,"Update Port Direction"),Gu()),2&i&&(pM(3),Fy("offsetX",200)("offsetY",300)("width",100)("height",100)("ports",r.port1),pM(),Fy("offsetX",400)("offsetY",200)("width",100)("height",100)("ports",r.port2))},dependencies:[Lle,Ale,v_,m_,y_,S_],encapsulation:2})}}return n})();Ud(332),function $q(n,t){return DG({rootComponent:n,...Ez(t)})}(Ole).catch(n=>console.error(n))},332:()=>{!function(Z){const se=Z.performance;function ye(Pi){se&&se.mark&&se.mark(Pi)}function fe(Pi,ht){se&&se.measure&&se.measure(Pi,ht)}ye("Zone");const be=Z.__Zone_symbol_prefix||"__zone_symbol__";function ke(Pi){return be+Pi}const at=!0===Z[ke("forceDuplicateZoneCheck")];if(Z.Zone){if(at||"function"!=typeof Z.Zone.__symbol__)throw new Error("Zone already loaded.");return Z.Zone}let tt=(()=>{class Pi{static{this.__symbol__=ke}static assertZonePatched(){if(Z.Promise!==_o.ZoneAwarePromise)throw new Error("Zone.js has detected that ZoneAwarePromise `(window|global).Promise` has been overwritten.\nMost likely cause is that a Promise polyfill has been loaded after Zone.js (Polyfilling Promise api is not necessary when zone.js is loaded. If you must load one, do so before loading zone.js.)")}static get root(){let F=Pi.current;for(;F.parent;)F=F.parent;return F}static get current(){return Ur.zone}static get currentTask(){return Do}static __load_patch(F,ae,Et=!1){if(_o.hasOwnProperty(F)){if(!Et&&at)throw Error("Already loaded patch: "+F)}else if(!Z["__Zone_disable_"+F]){const Xt="Zone:"+F;ye(Xt),_o[F]=ae(Z,Pi,cn),fe(Xt,Xt)}}get parent(){return this._parent}get name(){return this._name}constructor(F,ae){this._parent=F,this._name=ae?ae.name||"unnamed":"",this._properties=ae&&ae.properties||{},this._zoneDelegate=new Lt(this,this._parent&&this._parent._zoneDelegate,ae)}get(F){const ae=this.getZoneWith(F);if(ae)return ae._properties[F]}getZoneWith(F){let ae=this;for(;ae;){if(ae._properties.hasOwnProperty(F))return ae;ae=ae._parent}return null}fork(F){if(!F)throw new Error("ZoneSpec required!");return this._zoneDelegate.fork(this,F)}wrap(F,ae){if("function"!=typeof F)throw new Error("Expecting function got: "+F);const Et=this._zoneDelegate.intercept(this,F,ae),Xt=this;return function(){return Xt.runGuarded(Et,this,arguments,ae)}}run(F,ae,Et,Xt){Ur={parent:Ur,zone:this};try{return this._zoneDelegate.invoke(this,F,ae,Et,Xt)}finally{Ur=Ur.parent}}runGuarded(F,ae=null,Et,Xt){Ur={parent:Ur,zone:this};try{try{return this._zoneDelegate.invoke(this,F,ae,Et,Xt)}catch(Un){if(this._zoneDelegate.handleError(this,Un))throw Un}}finally{Ur=Ur.parent}}runTask(F,ae,Et){if(F.zone!=this)throw new Error("A task can only be run in the zone of creation! (Creation: "+(F.zone||_n).name+"; Execution: "+this.name+")");if(F.state===sr&&(F.type===ts||F.type===Pt))return;const Xt=F.state!=lt;Xt&&F._transitionTo(lt,ki),F.runCount++;const Un=Do;Do=F,Ur={parent:Ur,zone:this};try{F.type==Pt&&F.data&&!F.data.isPeriodic&&(F.cancelFn=void 0);try{return this._zoneDelegate.invokeTask(this,F,ae,Et)}catch(Ue){if(this._zoneDelegate.handleError(this,Ue))throw Ue}}finally{F.state!==sr&&F.state!==et&&(F.type==ts||F.data&&F.data.isPeriodic?Xt&&F._transitionTo(ki,lt):(F.runCount=0,this._updateTaskCount(F,-1),Xt&&F._transitionTo(sr,lt,sr))),Ur=Ur.parent,Do=Un}}scheduleTask(F){if(F.zone&&F.zone!==this){let Et=this;for(;Et;){if(Et===F.zone)throw Error(`can not reschedule task to ${this.name} which is descendants of the original zone ${F.zone.name}`);Et=Et.parent}}F._transitionTo(Zr,sr);const ae=[];F._zoneDelegates=ae,F._zone=this;try{F=this._zoneDelegate.scheduleTask(this,F)}catch(Et){throw F._transitionTo(et,Zr,sr),this._zoneDelegate.handleError(this,Et),Et}return F._zoneDelegates===ae&&this._updateTaskCount(F,1),F.state==Zr&&F._transitionTo(ki,Zr),F}scheduleMicroTask(F,ae,Et,Xt){return this.scheduleTask(new ft(vi,F,ae,Et,Xt,void 0))}scheduleMacroTask(F,ae,Et,Xt,Un){return this.scheduleTask(new ft(Pt,F,ae,Et,Xt,Un))}scheduleEventTask(F,ae,Et,Xt,Un){return this.scheduleTask(new ft(ts,F,ae,Et,Xt,Un))}cancelTask(F){if(F.zone!=this)throw new Error("A task can only be cancelled in the zone of creation! (Creation: "+(F.zone||_n).name+"; Execution: "+this.name+")");if(F.state===ki||F.state===lt){F._transitionTo(dr,ki,lt);try{this._zoneDelegate.cancelTask(this,F)}catch(ae){throw F._transitionTo(et,dr),this._zoneDelegate.handleError(this,ae),ae}return this._updateTaskCount(F,-1),F._transitionTo(sr,dr),F.runCount=0,F}}_updateTaskCount(F,ae){const Et=F._zoneDelegates;-1==ae&&(F._zoneDelegates=null);for(let Xt=0;XtPi.hasTask(F,ae),onScheduleTask:(Pi,ht,F,ae)=>Pi.scheduleTask(F,ae),onInvokeTask:(Pi,ht,F,ae,Et,Xt)=>Pi.invokeTask(F,ae,Et,Xt),onCancelTask:(Pi,ht,F,ae)=>Pi.cancelTask(F,ae)};class Lt{constructor(ht,F,ae){this._taskCounts={microTask:0,macroTask:0,eventTask:0},this.zone=ht,this._parentDelegate=F,this._forkZS=ae&&(ae&&ae.onFork?ae:F._forkZS),this._forkDlgt=ae&&(ae.onFork?F:F._forkDlgt),this._forkCurrZone=ae&&(ae.onFork?this.zone:F._forkCurrZone),this._interceptZS=ae&&(ae.onIntercept?ae:F._interceptZS),this._interceptDlgt=ae&&(ae.onIntercept?F:F._interceptDlgt),this._interceptCurrZone=ae&&(ae.onIntercept?this.zone:F._interceptCurrZone),this._invokeZS=ae&&(ae.onInvoke?ae:F._invokeZS),this._invokeDlgt=ae&&(ae.onInvoke?F:F._invokeDlgt),this._invokeCurrZone=ae&&(ae.onInvoke?this.zone:F._invokeCurrZone),this._handleErrorZS=ae&&(ae.onHandleError?ae:F._handleErrorZS),this._handleErrorDlgt=ae&&(ae.onHandleError?F:F._handleErrorDlgt),this._handleErrorCurrZone=ae&&(ae.onHandleError?this.zone:F._handleErrorCurrZone),this._scheduleTaskZS=ae&&(ae.onScheduleTask?ae:F._scheduleTaskZS),this._scheduleTaskDlgt=ae&&(ae.onScheduleTask?F:F._scheduleTaskDlgt),this._scheduleTaskCurrZone=ae&&(ae.onScheduleTask?this.zone:F._scheduleTaskCurrZone),this._invokeTaskZS=ae&&(ae.onInvokeTask?ae:F._invokeTaskZS),this._invokeTaskDlgt=ae&&(ae.onInvokeTask?F:F._invokeTaskDlgt),this._invokeTaskCurrZone=ae&&(ae.onInvokeTask?this.zone:F._invokeTaskCurrZone),this._cancelTaskZS=ae&&(ae.onCancelTask?ae:F._cancelTaskZS),this._cancelTaskDlgt=ae&&(ae.onCancelTask?F:F._cancelTaskDlgt),this._cancelTaskCurrZone=ae&&(ae.onCancelTask?this.zone:F._cancelTaskCurrZone),this._hasTaskZS=null,this._hasTaskDlgt=null,this._hasTaskDlgtOwner=null,this._hasTaskCurrZone=null;const Et=ae&&ae.onHasTask;(Et||F&&F._hasTaskZS)&&(this._hasTaskZS=Et?ae:At,this._hasTaskDlgt=F,this._hasTaskDlgtOwner=this,this._hasTaskCurrZone=ht,ae.onScheduleTask||(this._scheduleTaskZS=At,this._scheduleTaskDlgt=F,this._scheduleTaskCurrZone=this.zone),ae.onInvokeTask||(this._invokeTaskZS=At,this._invokeTaskDlgt=F,this._invokeTaskCurrZone=this.zone),ae.onCancelTask||(this._cancelTaskZS=At,this._cancelTaskDlgt=F,this._cancelTaskCurrZone=this.zone))}fork(ht,F){return this._forkZS?this._forkZS.onFork(this._forkDlgt,this.zone,ht,F):new tt(ht,F)}intercept(ht,F,ae){return this._interceptZS?this._interceptZS.onIntercept(this._interceptDlgt,this._interceptCurrZone,ht,F,ae):F}invoke(ht,F,ae,Et,Xt){return this._invokeZS?this._invokeZS.onInvoke(this._invokeDlgt,this._invokeCurrZone,ht,F,ae,Et,Xt):F.apply(ae,Et)}handleError(ht,F){return!this._handleErrorZS||this._handleErrorZS.onHandleError(this._handleErrorDlgt,this._handleErrorCurrZone,ht,F)}scheduleTask(ht,F){let ae=F;if(this._scheduleTaskZS)this._hasTaskZS&&ae._zoneDelegates.push(this._hasTaskDlgtOwner),ae=this._scheduleTaskZS.onScheduleTask(this._scheduleTaskDlgt,this._scheduleTaskCurrZone,ht,F),ae||(ae=F);else if(F.scheduleFn)F.scheduleFn(F);else{if(F.type!=vi)throw new Error("Task is missing scheduleFn.");Wt(F)}return ae}invokeTask(ht,F,ae,Et){return this._invokeTaskZS?this._invokeTaskZS.onInvokeTask(this._invokeTaskDlgt,this._invokeTaskCurrZone,ht,F,ae,Et):F.callback.apply(ae,Et)}cancelTask(ht,F){let ae;if(this._cancelTaskZS)ae=this._cancelTaskZS.onCancelTask(this._cancelTaskDlgt,this._cancelTaskCurrZone,ht,F);else{if(!F.cancelFn)throw Error("Task is not cancelable");ae=F.cancelFn(F)}return ae}hasTask(ht,F){try{this._hasTaskZS&&this._hasTaskZS.onHasTask(this._hasTaskDlgt,this._hasTaskCurrZone,ht,F)}catch(ae){this.handleError(ht,ae)}}_updateTaskCount(ht,F){const ae=this._taskCounts,Et=ae[ht],Xt=ae[ht]=Et+F;if(Xt<0)throw new Error("More tasks executed then were scheduled.");0!=Et&&0!=Xt||this.hasTask(this.zone,{microTask:ae.microTask>0,macroTask:ae.macroTask>0,eventTask:ae.eventTask>0,change:ht})}}class ft{constructor(ht,F,ae,Et,Xt,Un){if(this._zone=null,this.runCount=0,this._zoneDelegates=null,this._state="notScheduled",this.type=ht,this.source=F,this.data=Et,this.scheduleFn=Xt,this.cancelFn=Un,!ae)throw new Error("callback is not defined");this.callback=ae;const Ue=this;this.invoke=ht===ts&&Et&&Et.useG?ft.invokeTask:function(){return ft.invokeTask.call(Z,Ue,this,arguments)}}static invokeTask(ht,F,ae){ht||(ht=this),Ls++;try{return ht.runCount++,ht.zone.runTask(ht,F,ae)}finally{1==Ls&&ct(),Ls--}}get zone(){return this._zone}get state(){return this._state}cancelScheduleRequest(){this._transitionTo(sr,Zr)}_transitionTo(ht,F,ae){if(this._state!==F&&this._state!==ae)throw new Error(`${this.type} '${this.source}': can not transition to '${ht}', expecting state '${F}'${ae?" or '"+ae+"'":""}, was '${this._state}'.`);this._state=ht,ht==sr&&(this._zoneDelegates=null)}toString(){return this.data&&typeof this.data.handleId<"u"?this.data.handleId.toString():Object.prototype.toString.call(this)}toJSON(){return{type:this.type,state:this.state,source:this.source,zone:this.zone.name,runCount:this.runCount}}}const Ei=ke("setTimeout"),ii=ke("Promise"),gi=ke("then");let es,cr=[],Oi=!1;function kr(Pi){if(es||Z[ii]&&(es=Z[ii].resolve(0)),es){let ht=es[gi];ht||(ht=es.then),ht.call(es,Pi)}else Z[Ei](Pi,0)}function Wt(Pi){0===Ls&&0===cr.length&&kr(ct),Pi&&cr.push(Pi)}function ct(){if(!Oi){for(Oi=!0;cr.length;){const Pi=cr;cr=[];for(let ht=0;htUr,onUnhandledError:jr,microtaskDrainDone:jr,scheduleMicroTask:Wt,showUncaughtError:()=>!tt[ke("ignoreConsoleErrorUncaughtError")],patchEventTarget:()=>[],patchOnProperties:jr,patchMethod:()=>jr,bindArguments:()=>[],patchThen:()=>jr,patchMacroTask:()=>jr,patchEventPrototype:()=>jr,isIEOrEdge:()=>!1,getGlobalObjects:()=>{},ObjectDefineProperty:()=>jr,ObjectGetOwnPropertyDescriptor:()=>{},ObjectCreate:()=>{},ArraySlice:()=>[],patchClass:()=>jr,wrapWithCurrentZone:()=>jr,filterProperties:()=>[],attachOriginToPatched:()=>jr,_redefineProperty:()=>jr,patchCallbacks:()=>jr,nativeScheduleMicroTask:kr};let Ur={parent:null,zone:new tt(null,null)},Do=null,Ls=0;function jr(){}fe("Zone","Zone"),Z.Zone=tt}(globalThis);const _l=Object.getOwnPropertyDescriptor,_d=Object.defineProperty,Ud=Object.getPrototypeOf,jd=Object.create,mb=Array.prototype.slice,pm="addEventListener",$r="removeEventListener",Ul=Zone.__symbol__(pm),Fh=Zone.__symbol__($r),Ts="true",Wi="false",Vd=Zone.__symbol__("");function lf(Z,se){return Zone.current.wrap(Z,se)}function fm(Z,se,ye,fe,be){return Zone.current.scheduleMacroTask(Z,se,ye,fe,be)}const Ji=Zone.__symbol__,_h=typeof window<"u",Uh=_h?window:void 0,gn=_h&&Uh||globalThis,gm="removeAttribute";function Wd(Z,se){for(let ye=Z.length-1;ye>=0;ye--)"function"==typeof Z[ye]&&(Z[ye]=lf(Z[ye],se+"_"+ye));return Z}function hf(Z){return!Z||!1!==Z.writable&&!("function"==typeof Z.get&&typeof Z.set>"u")}const cf=typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope,jh=!("nw"in gn)&&typeof gn.process<"u"&&"[object process]"==={}.toString.call(gn.process),Yd=!jh&&!cf&&!(!_h||!Uh.HTMLElement),df=typeof gn.process<"u"&&"[object process]"==={}.toString.call(gn.process)&&!cf&&!(!_h||!Uh.HTMLElement),jl={},Vh=function(Z){if(!(Z=Z||gn.event))return;let se=jl[Z.type];se||(se=jl[Z.type]=Ji("ON_PROPERTY"+Z.type));const ye=this||Z.target||gn,fe=ye[se];let be;return Yd&&ye===Uh&&"error"===Z.type?(be=fe&&fe.call(this,Z.message,Z.filename,Z.lineno,Z.colno,Z.error),!0===be&&Z.preventDefault()):(be=fe&&fe.apply(this,arguments),null!=be&&!be&&Z.preventDefault()),be};function Vl(Z,se,ye){let fe=_l(Z,se);if(!fe&&ye&&_l(ye,se)&&(fe={enumerable:!0,configurable:!0}),!fe||!fe.configurable)return;const be=Ji("on"+se+"patched");if(Z.hasOwnProperty(be)&&Z[be])return;delete fe.writable,delete fe.value;const ke=fe.get,at=fe.set,tt=se.slice(2);let At=jl[tt];At||(At=jl[tt]=Ji("ON_PROPERTY"+tt)),fe.set=function(Lt){let ft=this;!ft&&Z===gn&&(ft=gn),ft&&("function"==typeof ft[At]&&ft.removeEventListener(tt,Vh),at&&at.call(ft,null),ft[At]=Lt,"function"==typeof Lt&&ft.addEventListener(tt,Vh,!1))},fe.get=function(){let Lt=this;if(!Lt&&Z===gn&&(Lt=gn),!Lt)return null;const ft=Lt[At];if(ft)return ft;if(ke){let Ei=ke.call(this);if(Ei)return fe.set.call(this,Ei),"function"==typeof Lt[gm]&&Lt.removeAttribute(se),Ei}return null},_d(Z,se,fe),Z[be]=!0}function uf(Z,se,ye){if(se)for(let fe=0;fefunction(at,tt){const At=ye(at,tt);return At.cbIdx>=0&&"function"==typeof tt[At.cbIdx]?fm(At.name,tt[At.cbIdx],At,be):ke.apply(at,tt)})}function Sa(Z,se){Z[Ji("OriginalDelegate")]=se}let Sb=!1,Gd=!1;function Ib(){if(Sb)return Gd;Sb=!0;try{const Z=Uh.navigator.userAgent;(-1!==Z.indexOf("MSIE ")||-1!==Z.indexOf("Trident/")||-1!==Z.indexOf("Edge/"))&&(Gd=!0)}catch{}return Gd}Zone.__load_patch("ZoneAwarePromise",(Z,se,ye)=>{const fe=Object.getOwnPropertyDescriptor,be=Object.defineProperty,at=ye.symbol,tt=[],At=!1!==Z[at("DISABLE_WRAPPING_UNCAUGHT_PROMISE_REJECTION")],Lt=at("Promise"),ft=at("then"),Ei="__creationTrace__";ye.onUnhandledError=Ue=>{if(ye.showUncaughtError()){const He=Ue&&Ue.rejection;He?console.error("Unhandled Promise rejection:",He instanceof Error?He.message:He,"; Zone:",Ue.zone.name,"; Task:",Ue.task&&Ue.task.source,"; Value:",He,He instanceof Error?He.stack:void 0):console.error(Ue)}},ye.microtaskDrainDone=()=>{for(;tt.length;){const Ue=tt.shift();try{Ue.zone.runGuarded(()=>{throw Ue.throwOriginal?Ue.rejection:Ue})}catch(He){gi(He)}}};const ii=at("unhandledPromiseRejectionHandler");function gi(Ue){ye.onUnhandledError(Ue);try{const He=se[ii];"function"==typeof He&&He.call(this,Ue)}catch{}}function cr(Ue){return Ue&&Ue.then}function Oi(Ue){return Ue}function es(Ue){return F.reject(Ue)}const kr=at("state"),Wt=at("value"),ct=at("finally"),_n=at("parentPromiseValue"),sr=at("parentPromiseState"),Zr="Promise.then",ki=null,lt=!0,dr=!1,et=0;function vi(Ue,He){return ge=>{try{cn(Ue,He,ge)}catch(We){cn(Ue,!1,We)}}}const Pt=function(){let Ue=!1;return function(ge){return function(){Ue||(Ue=!0,ge.apply(null,arguments))}}},ts="Promise resolved with itself",_o=at("currentTaskTrace");function cn(Ue,He,ge){const We=Pt();if(Ue===ge)throw new TypeError(ts);if(Ue[kr]===ki){let wt=null;try{("object"==typeof ge||"function"==typeof ge)&&(wt=ge&&ge.then)}catch(Xe){return We(()=>{cn(Ue,!1,Xe)})(),Ue}if(He!==dr&&ge instanceof F&&ge.hasOwnProperty(kr)&&ge.hasOwnProperty(Wt)&&ge[kr]!==ki)Do(ge),cn(Ue,ge[kr],ge[Wt]);else if(He!==dr&&"function"==typeof wt)try{wt.call(ge,We(vi(Ue,He)),We(vi(Ue,!1)))}catch(Xe){We(()=>{cn(Ue,!1,Xe)})()}else{Ue[kr]=He;const Xe=Ue[Wt];if(Ue[Wt]=ge,Ue[ct]===ct&&He===lt&&(Ue[kr]=Ue[sr],Ue[Wt]=Ue[_n]),He===dr&&ge instanceof Error){const mt=se.currentTask&&se.currentTask.data&&se.currentTask.data[Ei];mt&&be(ge,_o,{configurable:!0,enumerable:!1,writable:!0,value:mt})}for(let mt=0;mt{try{const dt=Ue[Wt],qt=!!ge&&ct===ge[ct];qt&&(ge[_n]=dt,ge[sr]=Xe);const li=He.run(mt,void 0,qt&&mt!==es&&mt!==Oi?[]:[dt]);cn(ge,!0,li)}catch(dt){cn(ge,!1,dt)}},ge)}const Pi=function(){},ht=Z.AggregateError;class F{static toString(){return"function ZoneAwarePromise() { [native code] }"}static resolve(He){return He instanceof F?He:cn(new this(null),lt,He)}static reject(He){return cn(new this(null),dr,He)}static withResolvers(){const He={};return He.promise=new F((ge,We)=>{He.resolve=ge,He.reject=We}),He}static any(He){if(!He||"function"!=typeof He[Symbol.iterator])return Promise.reject(new ht([],"All promises were rejected"));const ge=[];let We=0;try{for(let mt of He)We++,ge.push(F.resolve(mt))}catch{return Promise.reject(new ht([],"All promises were rejected"))}if(0===We)return Promise.reject(new ht([],"All promises were rejected"));let wt=!1;const Xe=[];return new F((mt,dt)=>{for(let qt=0;qt{wt||(wt=!0,mt(li))},li=>{Xe.push(li),We--,0===We&&(wt=!0,dt(new ht(Xe,"All promises were rejected")))})})}static race(He){let ge,We,wt=new this((dt,qt)=>{ge=dt,We=qt});function Xe(dt){ge(dt)}function mt(dt){We(dt)}for(let dt of He)cr(dt)||(dt=this.resolve(dt)),dt.then(Xe,mt);return wt}static all(He){return F.allWithCallback(He)}static allSettled(He){return(this&&this.prototype instanceof F?this:F).allWithCallback(He,{thenCallback:We=>({status:"fulfilled",value:We}),errorCallback:We=>({status:"rejected",reason:We})})}static allWithCallback(He,ge){let We,wt,Xe=new this((li,ur)=>{We=li,wt=ur}),mt=2,dt=0;const qt=[];for(let li of He){cr(li)||(li=this.resolve(li));const ur=dt;try{li.then(ir=>{qt[ur]=ge?ge.thenCallback(ir):ir,mt--,0===mt&&We(qt)},ir=>{ge?(qt[ur]=ge.errorCallback(ir),mt--,0===mt&&We(qt)):wt(ir)})}catch(ir){wt(ir)}mt++,dt++}return mt-=2,0===mt&&We(qt),Xe}constructor(He){const ge=this;if(!(ge instanceof F))throw new Error("Must be an instanceof Promise.");ge[kr]=ki,ge[Wt]=[];try{const We=Pt();He&&He(We(vi(ge,lt)),We(vi(ge,dr)))}catch(We){cn(ge,!1,We)}}get[Symbol.toStringTag](){return"Promise"}get[Symbol.species](){return F}then(He,ge){let We=this.constructor?.[Symbol.species];(!We||"function"!=typeof We)&&(We=this.constructor||F);const wt=new We(Pi),Xe=se.current;return this[kr]==ki?this[Wt].push(Xe,wt,He,ge):Ls(this,Xe,wt,He,ge),wt}catch(He){return this.then(null,He)}finally(He){let ge=this.constructor?.[Symbol.species];(!ge||"function"!=typeof ge)&&(ge=F);const We=new ge(Pi);We[ct]=ct;const wt=se.current;return this[kr]==ki?this[Wt].push(wt,We,He,He):Ls(this,wt,We,He,He),We}}F.resolve=F.resolve,F.reject=F.reject,F.race=F.race,F.all=F.all;const ae=Z[Lt]=Z.Promise;Z.Promise=F;const Et=at("thenPatched");function Xt(Ue){const He=Ue.prototype,ge=fe(He,"then");if(ge&&(!1===ge.writable||!ge.configurable))return;const We=He.then;He[ft]=We,Ue.prototype.then=function(wt,Xe){return new F((dt,qt)=>{We.call(this,dt,qt)}).then(wt,Xe)},Ue[Et]=!0}return ye.patchThen=Xt,ae&&(Xt(ae),Ka(Z,"fetch",Ue=>function Un(Ue){return function(He,ge){let We=Ue.apply(He,ge);if(We instanceof F)return We;let wt=We.constructor;return wt[Et]||Xt(wt),We}}(Ue))),Promise[se.__symbol__("uncaughtPromiseErrors")]=tt,F}),Zone.__load_patch("toString",Z=>{const se=Function.prototype.toString,ye=Ji("OriginalDelegate"),fe=Ji("Promise"),be=Ji("Error"),ke=function(){if("function"==typeof this){const Lt=this[ye];if(Lt)return"function"==typeof Lt?se.call(Lt):Object.prototype.toString.call(Lt);if(this===Promise){const ft=Z[fe];if(ft)return se.call(ft)}if(this===Error){const ft=Z[be];if(ft)return se.call(ft)}}return se.call(this)};ke[ye]=se,Function.prototype.toString=ke;const at=Object.prototype.toString;Object.prototype.toString=function(){return"function"==typeof Promise&&this instanceof Promise?"[object Promise]":at.call(this)}});let el=!1;if(typeof window<"u")try{const Z=Object.defineProperty({},"passive",{get:function(){el=!0}});window.addEventListener("test",Z,Z),window.removeEventListener("test",Z,Z)}catch{el=!1}const PT={useG:!0},Co={},bb={},ym=new RegExp("^"+Vd+"(\\w+)(true|false)$"),Mb=Ji("propagationStopped");function Sm(Z,se){const ye=(se?se(Z):Z)+Wi,fe=(se?se(Z):Z)+Ts,be=Vd+ye,ke=Vd+fe;Co[Z]={},Co[Z][Wi]=be,Co[Z][Ts]=ke}function wb(Z,se,ye,fe){const be=fe&&fe.add||pm,ke=fe&&fe.rm||$r,at=fe&&fe.listeners||"eventListeners",tt=fe&&fe.rmAll||"removeAllListeners",At=Ji(be),Lt="."+be+":",ft="prependListener",Ei="."+ft+":",ii=function(Wt,ct,_n){if(Wt.isRemoved)return;const sr=Wt.callback;let Zr;"object"==typeof sr&&sr.handleEvent&&(Wt.callback=lt=>sr.handleEvent(lt),Wt.originalDelegate=sr);try{Wt.invoke(Wt,ct,[_n])}catch(lt){Zr=lt}const ki=Wt.options;return ki&&"object"==typeof ki&&ki.once&&ct[ke].call(ct,_n.type,Wt.originalDelegate?Wt.originalDelegate:Wt.callback,ki),Zr};function gi(Wt,ct,_n){if(!(ct=ct||Z.event))return;const sr=Wt||ct.target||Z,Zr=sr[Co[ct.type][_n?Ts:Wi]];if(Zr){const ki=[];if(1===Zr.length){const lt=ii(Zr[0],sr,ct);lt&&ki.push(lt)}else{const lt=Zr.slice();for(let dr=0;dr{throw dr})}}}const cr=function(Wt){return gi(this,Wt,!1)},Oi=function(Wt){return gi(this,Wt,!0)};function es(Wt,ct){if(!Wt)return!1;let _n=!0;ct&&void 0!==ct.useG&&(_n=ct.useG);const sr=ct&&ct.vh;let Zr=!0;ct&&void 0!==ct.chkDup&&(Zr=ct.chkDup);let ki=!1;ct&&void 0!==ct.rt&&(ki=ct.rt);let lt=Wt;for(;lt&&!lt.hasOwnProperty(be);)lt=Ud(lt);if(!lt&&Wt[be]&&(lt=Wt),!lt||lt[At])return!1;const dr=ct&&ct.eventNameToString,et={},vi=lt[At]=lt[be],Pt=lt[Ji(ke)]=lt[ke],ts=lt[Ji(at)]=lt[at],_o=lt[Ji(tt)]=lt[tt];let cn;ct&&ct.prepend&&(cn=lt[Ji(ct.prepend)]=lt[ct.prepend]);const F=_n?function(ge){if(!et.isExisting)return vi.call(et.target,et.eventName,et.capture?Oi:cr,et.options)}:function(ge){return vi.call(et.target,et.eventName,ge.invoke,et.options)},ae=_n?function(ge){if(!ge.isRemoved){const We=Co[ge.eventName];let wt;We&&(wt=We[ge.capture?Ts:Wi]);const Xe=wt&&ge.target[wt];if(Xe)for(let mt=0;mt{Vo.zone.cancelTask(Vo)},{once:!0})),et.target=null,Fc&&(Fc.taskData=null),qd&&(Dn.once=!0),!el&&"boolean"==typeof Vo.options||(Vo.options=Dn),Vo.target=qt,Vo.capture=Gl,Vo.eventName=li,ir&&(Vo.originalDelegate=ur),dt?jo.unshift(Vo):jo.push(Vo),mt?qt:void 0}};return lt[be]=He(vi,Lt,F,ae,ki),cn&&(lt[ft]=He(cn,Ei,function(ge){return cn.call(et.target,et.eventName,ge.invoke,et.options)},ae,ki,!0)),lt[ke]=function(){const ge=this||Z;let We=arguments[0];ct&&ct.transferEventName&&(We=ct.transferEventName(We));const wt=arguments[2],Xe=!!wt&&("boolean"==typeof wt||wt.capture),mt=arguments[1];if(!mt)return Pt.apply(this,arguments);if(sr&&!sr(Pt,mt,ge,arguments))return;const dt=Co[We];let qt;dt&&(qt=dt[Xe?Ts:Wi]);const li=qt&&ge[qt];if(li)for(let ur=0;urfunction(be,ke){be[Mb]=!0,fe&&fe.apply(be,ke)})}function Eb(Z,se,ye,fe,be){const ke=Zone.__symbol__(fe);if(se[ke])return;const at=se[ke]=se[fe];se[fe]=function(tt,At,Lt){return At&&At.prototype&&be.forEach(function(ft){const Ei=`${ye}.${fe}::`+ft,ii=At.prototype;try{if(ii.hasOwnProperty(ft)){const gi=Z.ObjectGetOwnPropertyDescriptor(ii,ft);gi&&gi.value?(gi.value=Z.wrapWithCurrentZone(gi.value,Ei),Z._redefineProperty(At.prototype,ft,gi)):ii[ft]&&(ii[ft]=Z.wrapWithCurrentZone(ii[ft],Ei))}else ii[ft]&&(ii[ft]=Z.wrapWithCurrentZone(ii[ft],Ei))}catch{}}),at.call(se,tt,At,Lt)},Z.attachOriginToPatched(se[fe],at)}function Db(Z,se,ye){if(!ye||0===ye.length)return se;const fe=ye.filter(ke=>ke.target===Z);if(!fe||0===fe.length)return se;const be=fe[0].ignoreProperties;return se.filter(ke=>-1===be.indexOf(ke))}function Eo(Z,se,ye,fe){Z&&uf(Z,Db(Z,se,ye),fe)}function Xd(Z){return Object.getOwnPropertyNames(Z).filter(se=>se.startsWith("on")&&se.length>2).map(se=>se.substring(2))}Zone.__load_patch("util",(Z,se,ye)=>{const fe=Xd(Z);ye.patchOnProperties=uf,ye.patchMethod=Ka,ye.bindArguments=Wd,ye.patchMacroTask=yb;const be=se.__symbol__("BLACK_LISTED_EVENTS"),ke=se.__symbol__("UNPATCHED_EVENTS");Z[ke]&&(Z[be]=Z[ke]),Z[be]&&(se[be]=se[ke]=Z[be]),ye.patchEventPrototype=Im,ye.patchEventTarget=wb,ye.isIEOrEdge=Ib,ye.ObjectDefineProperty=_d,ye.ObjectGetOwnPropertyDescriptor=_l,ye.ObjectCreate=jd,ye.ArraySlice=mb,ye.patchClass=Qd,ye.wrapWithCurrentZone=lf,ye.filterProperties=Db,ye.attachOriginToPatched=Sa,ye._redefineProperty=Object.defineProperty,ye.patchCallbacks=Eb,ye.getGlobalObjects=()=>({globalSources:bb,zoneSymbolEventNames:Co,eventNames:fe,isBrowser:Yd,isMix:df,isNode:jh,TRUE_STR:Ts,FALSE_STR:Wi,ZONE_SYMBOL_PREFIX:Vd,ADD_EVENT_LISTENER_STR:pm,REMOVE_EVENT_LISTENER_STR:$r})});const As=Ji("zoneTask");function Wl(Z,se,ye,fe){let be=null,ke=null;ye+=fe;const at={};function tt(Lt){const ft=Lt.data;return ft.args[0]=function(){return Lt.invoke.apply(this,arguments)},ft.handleId=be.apply(Z,ft.args),Lt}function At(Lt){return ke.call(Z,Lt.data.handleId)}be=Ka(Z,se+=fe,Lt=>function(ft,Ei){if("function"==typeof Ei[0]){const ii={isPeriodic:"Interval"===fe,delay:"Timeout"===fe||"Interval"===fe?Ei[1]||0:void 0,args:Ei},gi=Ei[0];Ei[0]=function(){try{return gi.apply(this,arguments)}finally{ii.isPeriodic||("number"==typeof ii.handleId?delete at[ii.handleId]:ii.handleId&&(ii.handleId[As]=null))}};const cr=fm(se,Ei[0],ii,tt,At);if(!cr)return cr;const Oi=cr.data.handleId;return"number"==typeof Oi?at[Oi]=cr:Oi&&(Oi[As]=cr),Oi&&Oi.ref&&Oi.unref&&"function"==typeof Oi.ref&&"function"==typeof Oi.unref&&(cr.ref=Oi.ref.bind(Oi),cr.unref=Oi.unref.bind(Oi)),"number"==typeof Oi||Oi?Oi:cr}return Lt.apply(Z,Ei)}),ke=Ka(Z,ye,Lt=>function(ft,Ei){const ii=Ei[0];let gi;"number"==typeof ii?gi=at[ii]:(gi=ii&&ii[As],gi||(gi=ii)),gi&&"string"==typeof gi.type?"notScheduled"!==gi.state&&(gi.cancelFn&&gi.data.isPeriodic||0===gi.runCount)&&("number"==typeof ii?delete at[ii]:ii&&(ii[As]=null),gi.zone.cancelTask(gi)):Lt.apply(Z,Ei)})}Zone.__load_patch("legacy",Z=>{const se=Z[Zone.__symbol__("legacyPatch")];se&&se()}),Zone.__load_patch("timers",Z=>{const ye="clear";Wl(Z,"set",ye,"Timeout"),Wl(Z,"set",ye,"Interval"),Wl(Z,"set",ye,"Immediate")}),Zone.__load_patch("requestAnimationFrame",Z=>{Wl(Z,"request","cancel","AnimationFrame"),Wl(Z,"mozRequest","mozCancel","AnimationFrame"),Wl(Z,"webkitRequest","webkitCancel","AnimationFrame")}),Zone.__load_patch("blocking",(Z,se)=>{const ye=["alert","prompt","confirm"];for(let fe=0;fefunction(At,Lt){return se.current.run(ke,Z,Lt,tt)})}),Zone.__load_patch("EventTarget",(Z,se,ye)=>{(function Yl(Z,se){se.patchEventPrototype(Z,se)})(Z,ye),function Mm(Z,se){if(Zone[se.symbol("patchEventTarget")])return;const{eventNames:ye,zoneSymbolEventNames:fe,TRUE_STR:be,FALSE_STR:ke,ZONE_SYMBOL_PREFIX:at}=se.getGlobalObjects();for(let At=0;At{Qd("MutationObserver"),Qd("WebKitMutationObserver")}),Zone.__load_patch("IntersectionObserver",(Z,se,ye)=>{Qd("IntersectionObserver")}),Zone.__load_patch("FileReader",(Z,se,ye)=>{Qd("FileReader")}),Zone.__load_patch("on_property",(Z,se,ye)=>{!function pf(Z,se){if(jh&&!df||Zone[Z.symbol("patchEvents")])return;const ye=se.__Zone_ignore_on_properties;let fe=[];if(Yd){const be=window;fe=fe.concat(["Document","SVGElement","Element","HTMLElement","HTMLBodyElement","HTMLMediaElement","HTMLFrameSetElement","HTMLFrameElement","HTMLIFrameElement","HTMLMarqueeElement","Worker"]);const ke=function mm(){try{const Z=Uh.navigator.userAgent;if(-1!==Z.indexOf("MSIE ")||-1!==Z.indexOf("Trident/"))return!0}catch{}return!1}()?[{target:be,ignoreProperties:["error"]}]:[];Eo(be,Xd(be),ye&&ye.concat(ke),Ud(be))}fe=fe.concat(["XMLHttpRequest","XMLHttpRequestEventTarget","IDBIndex","IDBRequest","IDBOpenDBRequest","IDBDatabase","IDBTransaction","IDBCursor","WebSocket"]);for(let be=0;be{!function bm(Z,se){const{isBrowser:ye,isMix:fe}=se.getGlobalObjects();(ye||fe)&&Z.customElements&&"customElements"in Z&&se.patchCallbacks(se,Z.customElements,"customElements","define",["connectedCallback","disconnectedCallback","adoptedCallback","attributeChangedCallback"])}(Z,ye)}),Zone.__load_patch("XHR",(Z,se)=>{!function At(Lt){const ft=Lt.XMLHttpRequest;if(!ft)return;const Ei=ft.prototype;let gi=Ei[Ul],cr=Ei[Fh];if(!gi){const et=Lt.XMLHttpRequestEventTarget;if(et){const vi=et.prototype;gi=vi[Ul],cr=vi[Fh]}}const Oi="readystatechange",es="scheduled";function kr(et){const vi=et.data,Pt=vi.target;Pt[ke]=!1,Pt[tt]=!1;const ts=Pt[be];gi||(gi=Pt[Ul],cr=Pt[Fh]),ts&&cr.call(Pt,Oi,ts);const _o=Pt[be]=()=>{if(Pt.readyState===Pt.DONE)if(!vi.aborted&&Pt[ke]&&et.state===es){const Ur=Pt[se.__symbol__("loadfalse")];if(0!==Pt.status&&Ur&&Ur.length>0){const Do=et.invoke;et.invoke=function(){const Ls=Pt[se.__symbol__("loadfalse")];for(let jr=0;jrfunction(et,vi){return et[fe]=0==vi[2],et[at]=vi[1],_n.apply(et,vi)}),Zr=Ji("fetchTaskAborting"),ki=Ji("fetchTaskScheduling"),lt=Ka(Ei,"send",()=>function(et,vi){if(!0===se.current[ki]||et[fe])return lt.apply(et,vi);{const Pt={target:et,url:et[at],isPeriodic:!1,args:vi,aborted:!1},ts=fm("XMLHttpRequest.send",Wt,Pt,kr,ct);et&&!0===et[tt]&&!Pt.aborted&&ts.state===es&&ts.invoke()}}),dr=Ka(Ei,"abort",()=>function(et,vi){const Pt=function ii(et){return et[ye]}(et);if(Pt&&"string"==typeof Pt.type){if(null==Pt.cancelFn||Pt.data&&Pt.data.aborted)return;Pt.zone.cancelTask(Pt)}else if(!0===se.current[Zr])return dr.apply(et,vi)})}(Z);const ye=Ji("xhrTask"),fe=Ji("xhrSync"),be=Ji("xhrListener"),ke=Ji("xhrScheduled"),at=Ji("xhrURL"),tt=Ji("xhrErrorBeforeScheduled")}),Zone.__load_patch("geolocation",Z=>{Z.navigator&&Z.navigator.geolocation&&function vm(Z,se){const ye=Z.constructor.name;for(let fe=0;fe{const At=function(){return tt.apply(this,Wd(arguments,ye+"."+be))};return Sa(At,tt),At})(ke)}}}(Z.navigator.geolocation,["getCurrentPosition","watchPosition"])}),Zone.__load_patch("PromiseRejectionEvent",(Z,se)=>{function ye(fe){return function(be){Cb(Z,fe).forEach(at=>{const tt=Z.PromiseRejectionEvent;if(tt){const At=new tt(fe,{promise:be.promise,reason:be.rejection});at.invoke(At)}})}}Z.PromiseRejectionEvent&&(se[Ji("unhandledPromiseRejectionHandler")]=ye("unhandledrejection"),se[Ji("rejectionHandledHandler")]=ye("rejectionhandled"))}),Zone.__load_patch("queueMicrotask",(Z,se,ye)=>{!function ff(Z,se){se.patchMethod(Z,"queueMicrotask",ye=>function(fe,be){Zone.current.scheduleMicroTask("queueMicrotask",be[0])})}(Z,ye)})}},_l=>{_l(_l.s=51)}]); \ No newline at end of file diff --git a/ej2-angular/samples/diagram/ports/connectionPort/main.de0f5aa53693d70c.js b/ej2-angular/samples/diagram/ports/connectionPort/main.de0f5aa53693d70c.js new file mode 100644 index 0000000000..7715d195c4 --- /dev/null +++ b/ej2-angular/samples/diagram/ports/connectionPort/main.de0f5aa53693d70c.js @@ -0,0 +1 @@ +"use strict";(self.webpackChunksyncfusion_component=self.webpackChunksyncfusion_component||[]).push([[179],{51:(Wl,Ud,jd)=>{let $r=null,_h=1;const Ts=Symbol("SIGNAL");function Wi(n){const t=$r;return $r=n,t}function gn(n){if((!Wh(n)||n.dirty)&&(n.dirty||n.lastCleanEpoch!==_h)){if(!n.producerMustRecompute(n)&&!Vh(n))return n.dirty=!1,void(n.lastCleanEpoch=_h);n.producerRecomputeValue(n),n.dirty=!1,n.lastCleanEpoch=_h}}function Vh(n){Gl(n);for(let t=0;t0}function Gl(n){n.producerNode??=[],n.producerIndexOfThis??=[],n.producerLastReadVersion??=[]}let Xd=null;function Eo(n){return"function"==typeof n}function qd(n){const e=n(i=>{Error.call(i),i.stack=(new Error).stack});return e.prototype=Object.create(Error.prototype),e.prototype.constructor=e,e}const fp=qd(n=>function(e){n(this),this.message=e?`${e.length} errors occurred during unsubscription:\n${e.map((i,r)=>`${r+1}) ${i.toString()}`).join("\n ")}`:"",this.name="UnsubscriptionError",this.errors=e});function pp(n,t){if(n){const e=n.indexOf(t);0<=e&&n.splice(e,1)}}class As{constructor(t){this.initialTeardown=t,this.closed=!1,this._parentage=null,this._finalizers=null}unsubscribe(){let t;if(!this.closed){this.closed=!0;const{_parentage:e}=this;if(e)if(this._parentage=null,Array.isArray(e))for(const s of e)s.remove(this);else e.remove(this);const{initialTeardown:i}=this;if(Eo(i))try{i()}catch(s){t=s instanceof fp?s.errors:[s]}const{_finalizers:r}=this;if(r){this._finalizers=null;for(const s of r)try{wm(s)}catch(o){t=t??[],o instanceof fp?t=[...t,...o.errors]:t.push(o)}}if(t)throw new fp(t)}}add(t){var e;if(t&&t!==this)if(this.closed)wm(t);else{if(t instanceof As){if(t.closed||t._hasParent(this))return;t._addParent(this)}(this._finalizers=null!==(e=this._finalizers)&&void 0!==e?e:[]).push(t)}}_hasParent(t){const{_parentage:e}=this;return e===t||Array.isArray(e)&&e.includes(t)}_addParent(t){const{_parentage:e}=this;this._parentage=Array.isArray(e)?(e.push(t),e):e?[e,t]:t}_removeParent(t){const{_parentage:e}=this;e===t?this._parentage=null:Array.isArray(e)&&pp(e,t)}remove(t){const{_finalizers:e}=this;e&&pp(e,t),t instanceof As&&t._removeParent(this)}}As.EMPTY=(()=>{const n=new As;return n.closed=!0,n})();const Xl=As.EMPTY;function Mm(n){return n instanceof As||n&&"closed"in n&&Eo(n.remove)&&Eo(n.add)&&Eo(n.unsubscribe)}function wm(n){Eo(n)?n():n.unsubscribe()}const ql={onUnhandledError:null,onStoppedNotification:null,Promise:void 0,useDeprecatedSynchronousErrorHandling:!1,useDeprecatedNextContext:!1},Z={setTimeout(n,t,...e){const{delegate:i}=Z;return i?.setTimeout?i.setTimeout(n,t,...e):setTimeout(n,t,...e)},clearTimeout(n){const{delegate:t}=Z;return(t?.clearTimeout||clearTimeout)(n)},delegate:void 0};function ye(){}const pe=at("C",void 0,void 0);function at(n,t,e){return{kind:n,value:t,error:e}}let tt=null;function At(n){if(ql.useDeprecatedSynchronousErrorHandling){const t=!tt;if(t&&(tt={errorThrown:!1,error:null}),n(),t){const{errorThrown:e,error:i}=tt;if(tt=null,e)throw i}}else n()}class pt extends As{constructor(t){super(),this.isStopped=!1,t?(this.destination=t,Mm(t)&&t.add(this)):this.destination=Wt}static create(t,e,i){return new cr(t,e,i)}next(t){this.isStopped?Pr(function ke(n){return at("N",n,void 0)}(t),this):this._next(t)}error(t){this.isStopped?Pr(function be(n){return at("E",void 0,n)}(t),this):(this.isStopped=!0,this._error(t))}complete(){this.isStopped?Pr(pe,this):(this.isStopped=!0,this._complete())}unsubscribe(){this.closed||(this.isStopped=!0,super.unsubscribe(),this.destination=null)}_next(t){this.destination.next(t)}_error(t){try{this.destination.error(t)}finally{this.unsubscribe()}}_complete(){try{this.destination.complete()}finally{this.unsubscribe()}}}const Di=Function.prototype.bind;function si(n,t){return Di.call(n,t)}class mi{constructor(t){this.partialObserver=t}next(t){const{partialObserver:e}=this;if(e.next)try{e.next(t)}catch(i){ki(i)}}error(t){const{partialObserver:e}=this;if(e.error)try{e.error(t)}catch(i){ki(i)}else ki(t)}complete(){const{partialObserver:t}=this;if(t.complete)try{t.complete()}catch(e){ki(e)}}}class cr extends pt{constructor(t,e,i){let r;if(super(),Eo(t)||!t)r={next:t??void 0,error:e??void 0,complete:i??void 0};else{let s;this&&ql.useDeprecatedNextContext?(s=Object.create(t),s.unsubscribe=()=>this.unsubscribe(),r={next:t.next&&si(t.next,s),error:t.error&&si(t.error,s),complete:t.complete&&si(t.complete,s)}):r=t}this.destination=new mi(r)}}function ki(n){ql.useDeprecatedSynchronousErrorHandling?function Lt(n){ql.useDeprecatedSynchronousErrorHandling&&tt&&(tt.errorThrown=!0,tt.error=n)}(n):function se(n){Z.setTimeout(()=>{const{onUnhandledError:t}=ql;if(!t)throw n;t(n)})}(n)}function Pr(n,t){const{onStoppedNotification:e}=ql;e&&Z.setTimeout(()=>e(n,t))}const Wt={closed:!0,next:ye,error:function is(n){throw n},complete:ye},ct="function"==typeof Symbol&&Symbol.observable||"@@observable";function jn(n){return n}let Pi=(()=>{class n{constructor(e){e&&(this._subscribe=e)}lift(e){const i=new n;return i.source=this,i.operator=e,i}subscribe(e,i,r){const s=function et(n){return n&&n instanceof pt||function dr(n){return n&&Eo(n.next)&&Eo(n.error)&&Eo(n.complete)}(n)&&Mm(n)}(e)?e:new cr(e,i,r);return At(()=>{const{operator:o,source:a}=this;s.add(o?o.call(s,a):a?this._subscribe(s):this._trySubscribe(s))}),s}_trySubscribe(e){try{return this._subscribe(e)}catch(i){e.error(i)}}forEach(e,i){return new(i=lt(i))((r,s)=>{const o=new cr({next:a=>{try{e(a)}catch(l){s(l),o.unsubscribe()}},error:s,complete:r});this.subscribe(o)})}_subscribe(e){var i;return null===(i=this.source)||void 0===i?void 0:i.subscribe(e)}[ct](){return this}pipe(...e){return function Zr(n){return 0===n.length?jn:1===n.length?n[0]:function(e){return n.reduce((i,r)=>r(i),e)}}(e)(this)}toPromise(e){return new(e=lt(e))((i,r)=>{let s;this.subscribe(o=>s=o,o=>r(o),()=>i(s))})}}return n.create=t=>new n(t),n})();function lt(n){var t;return null!==(t=n??ql.Promise)&&void 0!==t?t:Promise}const yi=qd(n=>function(){n(this),this.name="ObjectUnsubscribedError",this.message="object unsubscribed"});let Pt=(()=>{class n extends Pi{constructor(){super(),this.closed=!1,this.currentObservers=null,this.observers=[],this.isStopped=!1,this.hasError=!1,this.thrownError=null}lift(e){const i=new rs(this,this);return i.operator=e,i}_throwIfClosed(){if(this.closed)throw new yi}next(e){At(()=>{if(this._throwIfClosed(),!this.isStopped){this.currentObservers||(this.currentObservers=Array.from(this.observers));for(const i of this.currentObservers)i.next(e)}})}error(e){At(()=>{if(this._throwIfClosed(),!this.isStopped){this.hasError=this.isStopped=!0,this.thrownError=e;const{observers:i}=this;for(;i.length;)i.shift().error(e)}})}complete(){At(()=>{if(this._throwIfClosed(),!this.isStopped){this.isStopped=!0;const{observers:e}=this;for(;e.length;)e.shift().complete()}})}unsubscribe(){this.isStopped=this.closed=!0,this.observers=this.currentObservers=null}get observed(){var e;return(null===(e=this.observers)||void 0===e?void 0:e.length)>0}_trySubscribe(e){return this._throwIfClosed(),super._trySubscribe(e)}_subscribe(e){return this._throwIfClosed(),this._checkFinalizedStatuses(e),this._innerSubscribe(e)}_innerSubscribe(e){const{hasError:i,isStopped:r,observers:s}=this;return i||r?Xl:(this.currentObservers=null,s.push(e),new As(()=>{this.currentObservers=null,pp(s,e)}))}_checkFinalizedStatuses(e){const{hasError:i,thrownError:r,isStopped:s}=this;i?e.error(r):s&&e.complete()}asObservable(){const e=new Pi;return e.source=this,e}}return n.create=(t,e)=>new rs(t,e),n})();class rs extends Pt{constructor(t,e){super(),this.destination=t,this.source=e}next(t){var e,i;null===(i=null===(e=this.destination)||void 0===e?void 0:e.next)||void 0===i||i.call(e,t)}error(t){var e,i;null===(i=null===(e=this.destination)||void 0===e?void 0:e.error)||void 0===i||i.call(e,t)}complete(){var t,e;null===(e=null===(t=this.destination)||void 0===t?void 0:t.complete)||void 0===e||e.call(t)}_subscribe(t){var e,i;return null!==(i=null===(e=this.source)||void 0===e?void 0:e.subscribe(t))&&void 0!==i?i:Xl}}class _o extends Pt{constructor(t){super(),this._value=t}get value(){return this.getValue()}_subscribe(t){const e=super._subscribe(t);return!e.closed&&t.next(this._value),e}getValue(){const{hasError:t,thrownError:e,_value:i}=this;if(t)throw e;return this._throwIfClosed(),i}next(t){super.next(this._value=t)}}class Ls extends pt{constructor(t,e,i,r,s,o){super(t),this.onFinalize=s,this.shouldUnsubscribe=o,this._next=e?function(a){try{e(a)}catch(l){t.error(l)}}:super._next,this._error=r?function(a){try{r(a)}catch(l){t.error(l)}finally{this.unsubscribe()}}:super._error,this._complete=i?function(){try{i()}catch(a){t.error(a)}finally{this.unsubscribe()}}:super._complete}unsubscribe(){var t;if(!this.shouldUnsubscribe||this.shouldUnsubscribe()){const{closed:e}=this;super.unsubscribe(),!e&&(null===(t=this.onFinalize)||void 0===t||t.call(this))}}}function jr(n,t){return function Ur(n){return t=>{if(function cn(n){return Eo(n?.lift)}(t))return t.lift(function(e){try{return n(e,this)}catch(i){this.error(i)}});throw new TypeError("Unable to lift unknown Observable type")}}((e,i)=>{let r=0;e.subscribe(function Do(n,t,e,i,r){return new Ls(n,t,e,i,r)}(i,s=>{i.next(n.call(t,s,r++))}))})}class F extends Error{constructor(t,e){super(function ae(n,t){return`NG0${Math.abs(n)}${t?": "+t:""}`}(t,e)),this.code=t}}function Xe(n){for(let t in n)if(n[t]===Xe)return t;throw Error("Could not find renamed property on target object.")}function mt(n,t){for(const e in t)t.hasOwnProperty(e)&&!n.hasOwnProperty(e)&&(n[e]=t[e])}function dt(n){if("string"==typeof n)return n;if(Array.isArray(n))return"["+n.map(dt).join(", ")+"]";if(null==n)return""+n;if(n.overriddenName)return`${n.overriddenName}`;if(n.name)return`${n.name}`;const t=n.toString();if(null==t)return""+t;const e=t.indexOf("\n");return-1===e?t:t.substring(0,e)}function qt(n,t){return null==n||""===n?null===t?"":t:null==t||""===t?n:n+" "+t}const ur=Xe({__forward_ref__:Xe});function ir(n){return n.__forward_ref__=ir,n.toString=function(){return dt(this())},n}function vt(n){return function Tn(n){return"function"==typeof n&&n.hasOwnProperty(ur)&&n.__forward_ref__===ir}(n)?n():n}function $l(n){return n&&!!n.\u0275providers}const Zl=Xe({\u0275cmp:Xe}),$d=Xe({\u0275dir:Xe}),gp=Xe({\u0275pipe:Xe}),Uo=Xe({\u0275fac:Xe}),jo=Xe({__NG_ELEMENT_ID__:Xe}),vp=Xe({__NG_ENV_ID__:Xe});function Ri(n){return"function"==typeof n?n.name||n.toString():"object"==typeof n&&null!=n&&"function"==typeof n.type?n.type.name||n.type.toString():function Nt(n){return"string"==typeof n?n:null==n?"":String(n)}(n)}function Ab(n,t){throw new F(-201,!1)}function so(n,t){null==n&&function zt(n,t,e,i){throw new Error(`ASSERTION ERROR: ${n}`+(null==i?"":` [Expected=> ${e} ${i} ${t} <=Actual]`))}(t,n,null,"!=")}function Yi(n){return{token:n.token,providedIn:n.providedIn||null,factory:n.factory,value:void 0}}function mp(n){return{providers:n.providers||[],imports:n.imports||[]}}function Cm(n){return zT(n,Dm)||zT(n,RT)}function zT(n,t){return n.hasOwnProperty(t)?n[t]:null}function Em(n){return n&&(n.hasOwnProperty(Lb)||n.hasOwnProperty(x_))?n[Lb]:null}const Dm=Xe({\u0275prov:Xe}),Lb=Xe({\u0275inj:Xe}),RT=Xe({ngInjectableDef:Xe}),x_=Xe({ngInjectorDef:Xe});var xi=function(n){return n[n.Default=0]="Default",n[n.Host=1]="Host",n[n.Self=2]="Self",n[n.SkipSelf=4]="SkipSelf",n[n.Optional=8]="Optional",n}(xi||{});let Nb;function oo(n){const t=Nb;return Nb=n,t}function BT(n,t,e){const i=Cm(n);return i&&"root"==i.providedIn?void 0===i.value?i.value=i.factory():i.value:e&xi.Optional?null:void 0!==t?t:void Ab()}const rr=globalThis;class Ht{constructor(t,e){this._desc=t,this.ngMetadataName="InjectionToken",this.\u0275prov=void 0,"number"==typeof e?this.__NG_ELEMENT_ID__=e:void 0!==e&&(this.\u0275prov=Yi({token:this,providedIn:e.providedIn||"root",factory:e.factory}))}get multi(){return this}toString(){return`InjectionToken ${this._desc}`}}const yp={},Rb="__NG_DI_FLAG__",xm="ngTempTokenPath",L_=/\n/gm,_T="__source";let Jd;function Gh(n){const t=Jd;return Jd=n,t}function k_(n,t=xi.Default){if(void 0===Jd)throw new F(-203,!1);return null===Jd?BT(n,void 0,t):Jd.get(n,t&xi.Optional?null:void 0,t)}function _i(n,t=xi.Default){return(function HT(){return Nb}()||k_)(vt(n),t)}function Hi(n,t=xi.Default){return _i(n,Tm(t))}function Tm(n){return typeof n>"u"||"number"==typeof n?n:0|(n.optional&&8)|(n.host&&1)|(n.self&&2)|(n.skipSelf&&4)}function Hb(n){const t=[];for(let e=0;et){o=s-1;break}}}for(;ss?"":r[d+1].toLowerCase();const f=8&i?u:null;if(f&&-1!==jT(f,h,0)||2&i&&h!==u){if(Ma(i))return!1;o=!0}}}}else{if(!o&&!Ma(i)&&!Ma(l))return!1;if(o&&Ma(l))continue;o=!1,i=l|1&i}}return Ma(i)||o}function Ma(n){return 0==(1&n)}function __(n,t,e,i){if(null===t)return-1;let r=0;if(i||!e){let s=!1;for(;r-1)for(e++;e0?'="'+a+'"':"")+"]"}else 8&i?r+="."+o:4&i&&(r+=" "+o);else""!==r&&!Ma(o)&&(t+=qT(s,r),r=""),i=o,s=s||!Ma(i);e++}return""!==r&&(t+=qT(s,r)),t}function Fb(n){return Jl(()=>{const t=ZT(n),e={...t,decls:n.decls,vars:n.vars,template:n.template,consts:n.consts||null,ngContentSelectors:n.ngContentSelectors,onPush:n.changeDetection===Am.OnPush,directiveDefs:null,pipeDefs:null,dependencies:t.standalone&&n.dependencies||null,getStandaloneInjector:null,signals:n.signals??!1,data:n.data||{},encapsulation:n.encapsulation||ba.Emulated,styles:n.styles||Qi,_:null,schemas:n.schemas||null,tView:null,id:""};JT(e);const i=n.dependencies;return e.directiveDefs=Nm(i,!1),e.pipeDefs=Nm(i,!0),e.id=function Z_(n){let t=0;const e=[n.selectors,n.ngContentSelectors,n.hostVars,n.hostAttrs,n.consts,n.vars,n.decls,n.encapsulation,n.standalone,n.signals,n.exportAs,JSON.stringify(n.inputs),JSON.stringify(n.outputs),Object.getOwnPropertyNames(n.type.prototype),!!n.contentQueries,!!n.viewQuery].join("|");for(const r of e)t=Math.imul(31,t)+r.charCodeAt(0)<<0;return t+=2147483648,"c"+t}(e),e})}function X_(n){return di(n)||Wn(n)}function q_(n){return null!==n}function Lm(n){return Jl(()=>({type:n.type,bootstrap:n.bootstrap||Qi,declarations:n.declarations||Qi,imports:n.imports||Qi,exports:n.exports||Qi,transitiveCompileScopes:null,schemas:n.schemas||null,id:n.id||null}))}function $T(n,t){if(null==n)return rl;const e={};for(const i in n)if(n.hasOwnProperty(i)){const r=n[i];let s,o,a=Xh.None;Array.isArray(r)?(a=r[0],s=r[1],o=r[2]??s):(s=r,o=r),t?(e[s]=a!==Xh.None?[i,a]:i,t[s]=o):e[s]=i}return e}function nr(n){return Jl(()=>{const t=ZT(n);return JT(t),t})}function di(n){return n[Zl]||null}function Wn(n){return n[$d]||null}function gs(n){return n[gp]||null}function ZT(n){const t={};return{type:n.type,providersResolver:null,factory:null,hostBindings:n.hostBindings||null,hostVars:n.hostVars||0,hostAttrs:n.hostAttrs||null,contentQueries:n.contentQueries||null,declaredInputs:t,inputTransforms:null,inputConfig:n.inputs||rl,exportAs:n.exportAs||null,standalone:!0===n.standalone,signals:!0===n.signals,selectors:n.selectors||Qi,viewQuery:n.viewQuery||null,features:n.features||null,setInput:null,findHostDirectiveDefs:null,hostDirectives:null,inputs:$T(n.inputs,t),outputs:$T(n.outputs),debugInfo:null}}function JT(n){n.features?.forEach(t=>t(n))}function Nm(n,t){if(!n)return null;const e=t?gs:X_;return()=>("function"==typeof n?n():n).map(i=>e(i)).filter(q_)}const Vr=0,Be=1,Ct=2,vn=3,wa=4,Os=5,Ca=6,Kd=7,Er=8,Xs=9,Kl=10,Yt=11,bp=12,KT=13,eu=14,Jr=15,Mp=16,tu=17,nl=18,wp=19,eA=20,qh=21,Om=22,Uc=23,jt=25,_b=1,sl=7,iu=9,mn=10;var Ub=function(n){return n[n.None=0]="None",n[n.HasTransplantedViews=2]="HasTransplantedViews",n}(Ub||{});function ks(n){return Array.isArray(n)&&"object"==typeof n[_b]}function Ps(n){return Array.isArray(n)&&!0===n[_b]}function jb(n){return 0!=(4&n.flags)}function jc(n){return n.componentOffset>-1}function Pm(n){return 1==(1&n.flags)}function Ea(n){return!!n.template}function Vb(n){return 0!=(512&n[Ct])}function Vc(n,t){return n.hasOwnProperty(Uo)?n[Uo]:null}class tU{constructor(t,e,i){this.previousValue=t,this.currentValue=e,this.firstChange=i}isFirstChange(){return this.firstChange}}function nA(n,t,e,i){null!==t?t.applyValueToInputSignal(t,i):n[e]=i}function sA(n){return n.type.prototype.ngOnChanges&&(n.setInput=rU),iU}function iU(){const n=aA(this),t=n?.current;if(t){const e=n.previous;if(e===rl)n.previous=t;else for(let i in t)e[i]=t[i];n.current=null,this.ngOnChanges(t)}}function rU(n,t,e,i,r){const s=this.declaredInputs[i],o=aA(n)||function nU(n,t){return n[oA]=t}(n,{previous:rl,current:null}),a=o.current||(o.current={}),l=o.previous,h=l[s];a[s]=new tU(h&&h.currentValue,e,l===rl),nA(n,t,r,e)}const oA="__ngSimpleChanges__";function aA(n){return n[oA]||null}const ol=function(n,t,e){};let cA=!1;function fr(n){for(;Array.isArray(n);)n=n[Vr];return n}function qs(n,t){return fr(t[n.index])}function Dp(n,t){return n.data[t]}function To(n,t){const e=t[n];return ks(e)?e:e[Vr]}function Xb(n){return 128==(128&n[Ct])}function al(n,t){return null==t?null:n[t]}function dA(n){n[tu]=0}function cU(n){1024&n[Ct]||(n[Ct]|=1024,Xb(n)&&xp(n))}function fA(n){return 9216&n[Ct]||n[Uc]?.dirty}function qb(n){fA(n)?xp(n):64&n[Ct]&&(function oU(){return cA}()?(n[Ct]|=1024,xp(n)):n[Kl].changeDetectionScheduler?.notify())}function xp(n){n[Kl].changeDetectionScheduler?.notify();let t=Wc(n);for(;null!==t&&!(8192&t[Ct])&&(t[Ct]|=8192,Xb(t));)t=Wc(t)}function Wc(n){const t=n[vn];return Ps(t)?t[vn]:t}const Rt={lFrame:wA(null),bindingsEnabled:!0,skipHydrationRootTNode:null};function gA(){return Rt.bindingsEnabled}function Se(){return Rt.lFrame.lView}function Ti(){return Rt.lFrame.tView}function pr(){let n=vA();for(;null!==n&&64===n.type;)n=n.parent;return n}function vA(){return Rt.lFrame.currentTNode}function ll(n,t){const e=Rt.lFrame;e.currentTNode=n,e.isParent=t}function Zb(){return Rt.lFrame.isParent}function wU(n,t){const e=Rt.lFrame;e.bindingIndex=e.bindingRootIndex=n,Kb(t)}function Kb(n){Rt.lFrame.currentDirectiveIndex=n}function IA(){return Rt.lFrame.currentQueryIndex}function t1(n){Rt.lFrame.currentQueryIndex=n}function EU(n){const t=n[Be];return 2===t.type?t.declTNode:1===t.type?n[Os]:null}function bA(n,t,e){if(e&xi.SkipSelf){let r=t,s=n;for(;!(r=r.parent,null!==r||e&xi.Host||(r=EU(s),null===r||(s=s[eu],10&r.type))););if(null===r)return!1;t=r,n=s}const i=Rt.lFrame=MA();return i.currentTNode=t,i.lView=n,!0}function i1(n){const t=MA(),e=n[Be];Rt.lFrame=t,t.currentTNode=e.firstChild,t.lView=n,t.tView=e,t.contextLView=n,t.bindingIndex=e.bindingStartIndex,t.inI18n=!1}function MA(){const n=Rt.lFrame,t=null===n?null:n.child;return null===t?wA(n):t}function wA(n){const t={currentTNode:null,isParent:!0,lView:null,tView:null,selectedIndex:-1,contextLView:null,elementDepthCount:0,currentNamespace:null,currentDirectiveIndex:-1,bindingRootIndex:-1,bindingIndex:-1,currentQueryIndex:0,parent:n,child:null,inI18n:!1};return null!==n&&(n.child=t),t}function CA(){const n=Rt.lFrame;return Rt.lFrame=n.parent,n.currentTNode=null,n.lView=null,n}const EA=CA;function r1(){const n=CA();n.isParent=!0,n.tView=null,n.selectedIndex=-1,n.contextLView=null,n.elementDepthCount=0,n.currentDirectiveIndex=-1,n.currentNamespace=null,n.bindingRootIndex=-1,n.bindingIndex=-1,n.currentQueryIndex=0}function zs(){return Rt.lFrame.selectedIndex}function Yc(n){Rt.lFrame.selectedIndex=n}let xA=!0;function Hm(){return xA}function $h(n){xA=n}function Bm(n,t){for(let e=t.directiveStart,i=t.directiveEnd;e=i)break}else t[l]<0&&(n[tu]+=65536),(a>14>16&&(3&n[Ct])===t&&(n[Ct]+=16384,AA(a,s)):AA(a,s)}const su=-1;class Ap{constructor(t,e,i){this.factory=t,this.resolving=!1,this.canSeeViewProviders=e,this.injectImpl=i}}function o1(n){return n!==su}function Lp(n){return 32767&n}function Np(n,t){let e=function HU(n){return n>>16}(n),i=t;for(;e>0;)i=i[eu],e--;return i}let a1=!0;function Um(n){const t=a1;return a1=n,t}const LA=255,NA=5;let BU=0;const cl={};function jm(n,t){const e=OA(n,t);if(-1!==e)return e;const i=t[Be];i.firstCreatePass&&(n.injectorIndex=t.length,l1(i.data,n),l1(t,null),l1(i.blueprint,null));const r=Vm(n,t),s=n.injectorIndex;if(o1(r)){const o=Lp(r),a=Np(r,t),l=a[Be].data;for(let h=0;h<8;h++)t[s+h]=a[o+h]|l[o+h]}return t[s+8]=r,s}function l1(n,t){n.push(0,0,0,0,0,0,0,0,t)}function OA(n,t){return-1===n.injectorIndex||n.parent&&n.parent.injectorIndex===n.injectorIndex||null===t[n.injectorIndex+8]?-1:n.injectorIndex}function Vm(n,t){if(n.parent&&-1!==n.parent.injectorIndex)return n.parent.injectorIndex;let e=0,i=null,r=t;for(;null!==r;){if(i=FA(r),null===i)return su;if(e++,r=r[eu],-1!==i.injectorIndex)return i.injectorIndex|e<<16}return su}function h1(n,t,e){!function FU(n,t,e){let i;"string"==typeof e?i=e.charCodeAt(0)||0:e.hasOwnProperty(jo)&&(i=e[jo]),null==i&&(i=e[jo]=BU++);const r=i&LA;t.data[n+(r>>NA)]|=1<=0?t&LA:VU:t}(e);if("function"==typeof s){if(!bA(t,n,i))return i&xi.Host?kA(r,0,i):PA(t,e,i,r);try{let o;if(o=s(i),null!=o||i&xi.Optional)return o;Ab()}finally{EA()}}else if("number"==typeof s){let o=null,a=OA(n,t),l=su,h=i&xi.Host?t[Jr][Os]:null;for((-1===a||i&xi.SkipSelf)&&(l=-1===a?Vm(n,t):t[a+8],l!==su&&BA(i,!1)?(o=t[Be],a=Lp(l),t=Np(l,t)):a=-1);-1!==a;){const c=t[Be];if(HA(s,a,c.data)){const d=UU(a,t,e,o,i,h);if(d!==cl)return d}l=t[a+8],l!==su&&BA(i,t[Be].data[a+8]===h)&&HA(s,a,t)?(o=c,a=Lp(l),t=Np(l,t)):a=-1}}return r}function UU(n,t,e,i,r,s){const o=t[Be],a=o.data[n+8],c=Wm(a,o,e,null==i?jc(a)&&a1:i!=o&&0!=(3&a.type),r&xi.Host&&s===a);return null!==c?Qc(t,o,c,a):cl}function Wm(n,t,e,i,r){const s=n.providerIndexes,o=t.data,a=1048575&s,l=n.directiveStart,c=s>>20,u=r?a+c:n.directiveEnd;for(let f=i?a:a+c;f=l&&p.type===e)return f}if(r){const f=o[l];if(f&&Ea(f)&&f.type===e)return l}return null}function Qc(n,t,e,i){let r=n[e];const s=t.data;if(function kU(n){return n instanceof Ap}(r)){const o=r;o.resolving&&function Vo(n,t){const e=t?`. Dependency path: ${t.join(" > ")} > ${n}`:"";throw new F(-200,`Circular dependency in DI detected for ${n}${e}`)}(Ri(s[e]));const a=Um(o.canSeeViewProviders);o.resolving=!0;const h=o.injectImpl?oo(o.injectImpl):null;bA(n,i,xi.Default);try{r=n[e]=o.factory(void 0,s,n,i),t.firstCreatePass&&e>=i.directiveStart&&function NU(n,t,e){const{ngOnChanges:i,ngOnInit:r,ngDoCheck:s}=t.type.prototype;if(i){const o=sA(t);(e.preOrderHooks??=[]).push(n,o),(e.preOrderCheckHooks??=[]).push(n,o)}r&&(e.preOrderHooks??=[]).push(0-n,r),s&&((e.preOrderHooks??=[]).push(n,s),(e.preOrderCheckHooks??=[]).push(n,s))}(e,s[e],t)}finally{null!==h&&oo(h),Um(a),o.resolving=!1,EA()}}return r}function HA(n,t,e){return!!(e[t+(n>>NA)]&1<Array.isArray(e)?fu(e,t):t(e))}function UA(n,t,e){t>=n.length?n.push(e):n.splice(t,0,e)}function Ym(n,t){return t>=n.length-1?n.pop():n.splice(t,1)[0]}const vu=new Ht(""),GA=new Ht("",-1),S1=new Ht("");class qm{get(t,e=yp){if(e===yp){const i=new Error(`NullInjectorError: No provider for ${dt(t)}!`);throw i.name="NullInjectorError",i}return e}}function fj(...n){return{\u0275providers:XA(0,n),\u0275fromNgModule:!0}}function XA(n,...t){const e=[],i=new Set;let r;const s=o=>{e.push(o)};return fu(t,o=>{const a=o;$m(a,s,[],i)&&(r||=[],r.push(a))}),void 0!==r&&qA(r,s),e}function qA(n,t){for(let e=0;e{t(s,i)})}}function $m(n,t,e,i){if(!(n=vt(n)))return!1;let r=null,s=Em(n);const o=!s&&di(n);if(s||o){if(o&&!o.standalone)return!1;r=n}else{const l=n.ngModule;if(s=Em(l),!s)return!1;r=l}const a=i.has(r);if(o){if(a)return!1;if(i.add(r),o.dependencies){const l="function"==typeof o.dependencies?o.dependencies():o.dependencies;for(const h of l)$m(h,t,e,i)}}else{if(!s)return!1;{if(null!=s.imports&&!a){let h;i.add(r);try{fu(s.imports,c=>{$m(c,t,e,i)&&(h||=[],h.push(c))})}finally{}void 0!==h&&qA(h,t)}if(!a){const h=Vc(r)||(()=>new r);t({provide:r,useFactory:h,deps:Qi},r),t({provide:S1,useValue:r,multi:!0},r),t({provide:vu,useValue:()=>_i(r),multi:!0},r)}const l=s.providers;if(null!=l&&!a){const h=n;b1(l,c=>{t(c,h)})}}}return r!==n&&void 0!==n.providers}function b1(n,t){for(let e of n)$l(e)&&(e=e.\u0275providers),Array.isArray(e)?b1(e,t):t(e)}const pj=Xe({provide:String,useValue:Xe});function M1(n){return null!==n&&"object"==typeof n&&pj in n}function Gc(n){return"function"==typeof n}const w1=new Ht(""),Zm={},vj={};let C1;function Jm(){return void 0===C1&&(C1=new qm),C1}class ih{}class mu extends ih{get destroyed(){return this._destroyed}constructor(t,e,i,r){super(),this.parent=e,this.source=i,this.scopes=r,this.records=new Map,this._ngOnDestroyHooks=new Set,this._onDestroyHooks=[],this._destroyed=!1,D1(t,o=>this.processProvider(o)),this.records.set(GA,yu(void 0,this)),r.has("environment")&&this.records.set(ih,yu(void 0,this));const s=this.records.get(w1);null!=s&&"string"==typeof s.value&&this.scopes.add(s.value),this.injectorDefTypes=new Set(this.get(S1,Qi,xi.Self))}destroy(){this.assertNotDestroyed(),this._destroyed=!0;try{for(const e of this._ngOnDestroyHooks)e.ngOnDestroy();const t=this._onDestroyHooks;this._onDestroyHooks=[];for(const e of t)e()}finally{this.records.clear(),this._ngOnDestroyHooks.clear(),this.injectorDefTypes.clear()}}onDestroy(t){return this.assertNotDestroyed(),this._onDestroyHooks.push(t),()=>this.removeOnDestroy(t)}runInContext(t){this.assertNotDestroyed();const e=Gh(this),i=oo(void 0);try{return t()}finally{Gh(e),oo(i)}}get(t,e=yp,i=xi.Default){if(this.assertNotDestroyed(),t.hasOwnProperty(vp))return t[vp](this);i=Tm(i);const s=Gh(this),o=oo(void 0);try{if(!(i&xi.SkipSelf)){let l=this.records.get(t);if(void 0===l){const h=function bj(n){return"function"==typeof n||"object"==typeof n&&n instanceof Ht}(t)&&Cm(t);l=h&&this.injectableDefInScope(h)?yu(E1(t),Zm):null,this.records.set(t,l)}if(null!=l)return this.hydrate(t,l)}return(i&xi.Self?Jm():this.parent).get(t,e=i&xi.Optional&&e===yp?null:e)}catch(a){if("NullInjectorError"===a.name){if((a[xm]=a[xm]||[]).unshift(dt(t)),s)throw a;return function z_(n,t,e,i){const r=n[xm];throw t[_T]&&r.unshift(t[_T]),n.message=function R_(n,t,e,i=null){n=n&&"\n"===n.charAt(0)&&"\u0275"==n.charAt(1)?n.slice(2):n;let r=dt(t);if(Array.isArray(t))r=t.map(dt).join(" -> ");else if("object"==typeof t){let s=[];for(let o in t)if(t.hasOwnProperty(o)){let a=t[o];s.push(o+":"+("string"==typeof a?JSON.stringify(a):dt(a)))}r=`{${s.join(", ")}}`}return`${e}${i?"("+i+")":""}[${r}]: ${n.replace(L_,"\n ")}`}("\n"+n.message,r,e,i),n.ngTokenPath=r,n[xm]=null,n}(a,t,"R3InjectorError",this.source)}throw a}finally{oo(o),Gh(s)}}resolveInjectorInitializers(){const t=Gh(this),e=oo(void 0);try{const r=this.get(vu,Qi,xi.Self);for(const s of r)s()}finally{Gh(t),oo(e)}}toString(){const t=[],e=this.records;for(const i of e.keys())t.push(dt(i));return`R3Injector[${t.join(", ")}]`}assertNotDestroyed(){if(this._destroyed)throw new F(205,!1)}processProvider(t){let e=Gc(t=vt(t))?t:vt(t&&t.provide);const i=function yj(n){return M1(n)?yu(void 0,n.useValue):yu(JA(n),Zm)}(t);if(!Gc(t)&&!0===t.multi){let r=this.records.get(e);r||(r=yu(void 0,Zm,!0),r.factory=()=>Hb(r.multi),this.records.set(e,r)),e=t,r.multi.push(t)}this.records.set(e,i)}hydrate(t,e){return e.value===Zm&&(e.value=vj,e.value=e.factory()),"object"==typeof e.value&&e.value&&function Ij(n){return null!==n&&"object"==typeof n&&"function"==typeof n.ngOnDestroy}(e.value)&&this._ngOnDestroyHooks.add(e.value),e.value}injectableDefInScope(t){if(!t.providedIn)return!1;const e=vt(t.providedIn);return"string"==typeof e?"any"===e||this.scopes.has(e):this.injectorDefTypes.has(e)}removeOnDestroy(t){const e=this._onDestroyHooks.indexOf(t);-1!==e&&this._onDestroyHooks.splice(e,1)}}function E1(n){const t=Cm(n),e=null!==t?t.factory:Vc(n);if(null!==e)return e;if(n instanceof Ht)throw new F(204,!1);if(n instanceof Function)return function mj(n){if(n.length>0)throw new F(204,!1);const e=function D_(n){return n&&(n[Dm]||n[RT])||null}(n);return null!==e?()=>e.factory(n):()=>new n}(n);throw new F(204,!1)}function JA(n,t,e){let i;if(Gc(n)){const r=vt(n);return Vc(r)||E1(r)}if(M1(n))i=()=>vt(n.useValue);else if(function ZA(n){return!(!n||!n.useFactory)}(n))i=()=>n.useFactory(...Hb(n.deps||[]));else if(function $A(n){return!(!n||!n.useExisting)}(n))i=()=>_i(vt(n.useExisting));else{const r=vt(n&&(n.useClass||n.provide));if(!function Sj(n){return!!n.deps}(n))return Vc(r)||E1(r);i=()=>new r(...Hb(n.deps))}return i}function yu(n,t,e=!1){return{factory:n,value:t,multi:e?[]:void 0}}function D1(n,t){for(const e of n)Array.isArray(e)?D1(e,t):e&&$l(e)?D1(e.\u0275providers,t):t(e)}function iL(n,t=null,e=null,i){const r=function rL(n,t=null,e=null,i,r=new Set){const s=[e||Qi,fj(n)];return i=i||("object"==typeof n?void 0:dt(n)),new mu(s,t||Jm(),i||null,r)}(n,t,e,i);return r.resolveInjectorInitializers(),r}let A1,Wo=(()=>{class n{static{this.THROW_IF_NOT_FOUND=yp}static{this.NULL=new qm}static create(e,i){if(Array.isArray(e))return iL({name:""},i,e,"");{const r=e.name??"";return iL({name:r},e.parent,e.providers,r)}}static{this.\u0275prov=Yi({token:n,providedIn:"any",factory:()=>_i(GA)})}static{this.__NG_ELEMENT_ID__=-1}}return n})();const L1=new Ht("",{providedIn:"root",factory:()=>Lj}),Lj="ng",sL=new Ht(""),Su=new Ht("",{providedIn:"platform",factory:()=>"unknown"}),oL=new Ht("",{providedIn:"root",factory:()=>function Zh(){if(void 0!==A1)return A1;if(typeof document<"u")return document;throw new F(210,!1)}().body?.querySelector("[ngCspNonce]")?.getAttribute("ngCspNonce")||null});function ry(n){return 128==(128&n.flags)}var ec=function(n){return n[n.Important=1]="Important",n[n.DashCase=2]="DashCase",n}(ec||{});const z1=new Map;let Vj=0;const H1="__ngContext__";function Rs(n,t){ks(t)?(n[H1]=t[wp],function Yj(n){z1.set(n[wp],n)}(t)):n[H1]=t}let B1;function F1(n,t){return B1(n,t)}function bu(n,t,e,i,r){if(null!=i){let s,o=!1;Ps(i)?s=i:ks(i)&&(o=!0,i=i[Vr]);const a=fr(i);0===n&&null!==e?null==r?TL(t,e,a):qc(t,e,a,r||null,!0):1===n&&null!==e?qc(t,e,a,r||null,!0):2===n?function cy(n,t,e){const i=ly(n,t);i&&function a6(n,t,e,i){n.removeChild(t,e,i)}(n,i,t,e)}(t,a,o):3===n&&t.destroyNode(a),null!=s&&function c6(n,t,e,i,r){const s=e[sl];s!==fr(e)&&bu(t,n,i,s,r);for(let a=mn;a0&&(n[e-1][wa]=i[wa]);const s=Ym(n,mn+t);!function e6(n,t){EL(n,t),t[Vr]=null,t[Os]=null}(i[Be],i);const o=s[nl];null!==o&&o.detachView(s[Be]),i[vn]=null,i[wa]=null,i[Ct]&=-129}return i}function ay(n,t){if(!(256&t[Ct])){const e=t[Yt];e.destroyNode&&dy(n,t,e,3,null,null),function i6(n){let t=n[bp];if(!t)return U1(n[Be],n);for(;t;){let e=null;if(ks(t))e=t[bp];else{const i=t[mn];i&&(e=i)}if(!e){for(;t&&!t[wa]&&t!==n;)ks(t)&&U1(t[Be],t),t=t[vn];null===t&&(t=n),ks(t)&&U1(t[Be],t),e=t&&t[wa]}t=e}}(t)}}function U1(n,t){if(!(256&t[Ct])){t[Ct]&=-129,t[Ct]|=256,t[Uc]&&function Qd(n){if(Gl(n),Wh(n))for(let t=0;t=0?i[o]():i[-o].unsubscribe(),s+=2}else e[s].call(i[e[s+1]]);null!==i&&(t[Kd]=null);const r=t[qh];if(null!==r){t[qh]=null;for(let s=0;s-1){const{encapsulation:s}=n.data[i.directiveStart+r];if(s===ba.None||s===ba.Emulated)return null}return qs(i,e)}}(n,t.parent,e)}function qc(n,t,e,i,r){n.insertBefore(t,e,i,r)}function TL(n,t,e){n.appendChild(t,e)}function AL(n,t,e,i,r){null!==i?qc(n,t,e,i,r):TL(n,t,e)}function ly(n,t){return n.parentNode(t)}let V1,OL=function NL(n,t,e){return 40&n.type?qs(n,e):null};function hy(n,t,e,i){const r=j1(n,i,t),s=t[Yt],a=function LL(n,t,e){return OL(n,t,e)}(i.parent||t[Os],i,t);if(null!=r)if(Array.isArray(e))for(let l=0;lnull;function sM(n,t,e=!1){return JL(n,t,e)}class G6{}class rN{}class q6{resolveComponentFactory(t){throw function X6(n){const t=Error(`No component factory found for ${dt(n)}.`);return t.ngComponent=n,t}(t)}}let Iy=(()=>{class n{static{this.NULL=new q6}}return n})();function $6(){return xu(pr(),Se())}function xu(n,t){return new $c(qs(n,t))}let $c=(()=>{class n{constructor(e){this.nativeElement=e}static{this.__NG_ELEMENT_ID__=$6}}return n})();function Z6(n){return n instanceof $c?n.nativeElement:n}class sN{}let hM=(()=>{class n{constructor(){this.destroyNode=null}static{this.__NG_ELEMENT_ID__=()=>function J6(){const n=Se(),e=To(pr().index,n);return(ks(e)?e:n)[Yt]}()}}return n})(),K6=(()=>{class n{static{this.\u0275prov=Yi({token:n,providedIn:"root",factory:()=>null})}}return n})();const cM={};function Qp(n,t,e,i,r=!1){for(;null!==e;){const s=t[e.index];null!==s&&i.push(fr(s)),Ps(s)&&fN(s,i);const o=e.type;if(8&o)Qp(n,t,e.child,i);else if(32&o){const a=F1(e,t);let l;for(;l=a();)i.push(l)}else if(16&o){const a=PL(t,e);if(Array.isArray(a))i.push(...a);else{const l=Wc(t[Jr]);Qp(l[Be],l,a,i,!0)}}e=r?e.projectionNext:e.next}return i}function fN(n,t){for(let e=mn;e!1,producerRecomputeValue:()=>{},consumerMarkedDirty:()=>{},consumerOnSignalRead:()=>{},consumerIsAlwaysLive:!0,consumerMarkedDirty:n=>{xp(n.lView)},consumerOnSignalRead(){this.lView[Uc]=this}};function gN(n){return mN(n[bp])}function vN(n){return mN(n[wa])}function mN(n){for(;null!==n&&!Ps(n);)n=n[wa];return n}function fM(n){return n.ngOriginalError}class nh{constructor(){this._console=console}handleError(t){const e=this._findOriginalError(t);this._console.error("ERROR",t),e&&this._console.error("ORIGINAL ERROR",e)}_findOriginalError(t){let e=t&&fM(t);for(;e&&fM(e);)e=fM(e);return e||null}}const SN=new Ht("",{providedIn:"root",factory:()=>Hi(nh).handleError.bind(void 0)}),bN=new Ht("",{providedIn:"root",factory:()=>!1}),Qt={};function pM(n=1){EN(Ti(),Se(),zs()+n,!1)}function EN(n,t,e,i){if(!i)if(3==(3&t[Ct])){const s=n.preOrderCheckHooks;null!==s&&Fm(t,s,e)}else{const s=n.preOrderHooks;null!==s&&_m(t,s,0,e)}Yc(e)}function Ot(n,t=xi.Default){const e=Se();return null===e?_i(n,t):zA(pr(),e,vt(n),t)}function DN(n,t,e,i,r,s){const o=Wi(null);try{let a=null;r&Xh.SignalBased&&(a=t[i][Ts]),null!==a&&void 0!==a.transformFn&&(s=a.transformFn(s)),r&Xh.HasDecoratorInputTransform&&(s=n.inputTransforms[i].call(t,s)),null!==n.setInput?n.setInput(t,a,s,e,i):nA(t,a,i,s)}finally{Wi(o)}}function Cy(n,t,e,i,r,s,o,a,l,h,c){const d=t.blueprint.slice();return d[Vr]=r,d[Ct]=204|i,(null!==h||n&&2048&n[Ct])&&(d[Ct]|=2048),dA(d),d[vn]=d[eu]=n,d[Er]=e,d[Kl]=o||n&&n[Kl],d[Yt]=a||n&&n[Yt],d[Xs]=l||n&&n[Xs]||null,d[Os]=s,d[wp]=function Wj(){return Vj++}(),d[Ca]=c,d[eA]=h,d[Jr]=2==t.type?n[Jr]:d,d}function Tu(n,t,e,i,r){let s=n.data[t];if(null===s)s=function gM(n,t,e,i,r){const s=vA(),o=Zb(),l=n.data[t]=function LV(n,t,e,i,r,s){let o=t?t.injectorIndex:-1,a=0;return function nu(){return null!==Rt.skipHydrationRootTNode}()&&(a|=128),{type:e,index:i,insertBeforeIndex:null,injectorIndex:o,directiveStart:-1,directiveEnd:-1,directiveStylingLast:-1,componentOffset:-1,propertyBindings:null,flags:a,providerIndexes:0,value:r,attrs:s,mergedAttrs:null,localNames:null,initialInputs:void 0,inputs:null,outputs:null,tView:null,next:null,prev:null,projectionNext:null,child:null,parent:t,projection:null,styles:null,stylesWithoutHost:null,residualStyles:void 0,classes:null,classesWithoutHost:null,residualClasses:void 0,classBindings:0,styleBindings:0}}(0,o?s:s&&s.parent,e,t,i,r);return null===n.firstChild&&(n.firstChild=l),null!==s&&(o?null==s.child&&null!==l.parent&&(s.child=l):null===s.next&&(s.next=l,l.prev=s)),l}(n,t,e,i,r),function MU(){return Rt.lFrame.inI18n}()&&(s.flags|=32);else if(64&s.type){s.type=e,s.value=i,s.attrs=r;const o=function Tp(){const n=Rt.lFrame,t=n.currentTNode;return n.isParent?t:t.parent}();s.injectorIndex=null===o?-1:o.injectorIndex}return ll(s,!0),s}function Gp(n,t,e,i){if(0===e)return-1;const r=t.length;for(let s=0;sjt&&EN(n,t,jt,!1),ol(o?2:0,r),e(i,r)}finally{Yc(s),ol(o?3:1,r)}}function vM(n,t,e){if(jb(t)){const i=Wi(null);try{const s=t.directiveEnd;for(let o=t.directiveStart;onull;function LN(n,t,e,i,r){for(let s in t){if(!t.hasOwnProperty(s))continue;const o=t[s];if(void 0===o)continue;i??={};let a,l=Xh.None;Array.isArray(o)?(a=o[0],l=o[1]):a=o;let h=s;if(null!==r){if(!r.hasOwnProperty(s))continue;h=r[s]}0===n?NN(i,e,h,a,l):NN(i,e,h,a)}return i}function NN(n,t,e,i,r){let s;n.hasOwnProperty(e)?(s=n[e]).push(t,i):s=n[e]=[t,i],void 0!==r&&s.push(r)}function ON(n,t,e,i,r,s){for(let h=0;h0;){const e=n[--t];if("number"==typeof e&&e<0)return e}return 0})(o)!=a&&o.push(a),o.push(e,i,s)}}(n,t,i,Gp(n,e,r.hostVars,Qt),r)}function YV(n,t,e,i,r,s){const o=s[t];if(null!==o)for(let a=0;an.nextProducerIndex;)n.producerNode.pop(),n.producerLastReadVersion.pop(),n.producerIndexOfThis.pop()}}(a,o),function fV(n){n.lView[Uc]!==n&&(n.lView=null,pN.push(n))}(a)),r1()}}function FN(n,t){for(let e=gN(n);null!==e;e=vN(e))for(let i=mn;i-1&&(Bp(t,i),Ym(e,i))}this._attachedToViewContainer=!1}ay(this._lView[Be],this._lView)}onDestroy(t){!function Rm(n,t){if(256==(256&n[Ct]))throw new F(911,!1);null===n[qh]&&(n[qh]=[]),n[qh].push(t)}(this._lView,t)}markForCheck(){Xp(this._cdRefInjectingView||this._lView)}detach(){this._lView[Ct]&=-129}reattach(){qb(this._lView),this._lView[Ct]|=128}detectChanges(){this._lView[Ct]|=1024,function EM(n,t=!0){const e=n[Kl],i=e.rendererFactory;i.begin?.();try{!function XV(n){DM(n,0);let t=0;for(;fA(n);){if(100===t)throw new F(103,!1);t++,DM(n,1)}}(n)}catch(s){throw t&&Dy(n,s),s}finally{i.end?.(),e.inlineEffectRunner?.flush()}}(this._lView,this.notifyErrorHandler)}checkNoChanges(){}attachToViewContainerRef(){if(this._appRef)throw new F(902,!1);this._attachedToViewContainer=!0}detachFromAppRef(){this._appRef=null,EL(this._lView[Be],this._lView)}attachToAppRef(t){if(this._attachedToViewContainer)throw new F(902,!1);this._appRef=t,qb(this._lView)}}const VN=new Set;function TM(n){return t=>{setTimeout(n,void 0,t)}}const Yo=class h7 extends Pt{constructor(t=!1){super(),this.__isAsync=t}emit(t){super.next(t)}subscribe(t,e,i){let r=t,s=e||(()=>null),o=i;if(t&&"object"==typeof t){const l=t;r=l.next?.bind(l),s=l.error?.bind(l),o=l.complete?.bind(l)}this.__isAsync&&(s=TM(s),r&&(r=TM(r)),o&&(o=TM(o)));const a=super.subscribe({next:r,error:s,complete:o});return t instanceof As&&t.add(a),a}};function WN(...n){}class Rr{constructor({enableLongStackTrace:t=!1,shouldCoalesceEventChangeDetection:e=!1,shouldCoalesceRunChangeDetection:i=!1}){if(this.hasPendingMacrotasks=!1,this.hasPendingMicrotasks=!1,this.isStable=!0,this.onUnstable=new Yo(!1),this.onMicrotaskEmpty=new Yo(!1),this.onStable=new Yo(!1),this.onError=new Yo(!1),typeof Zone>"u")throw new F(908,!1);Zone.assertZonePatched();const r=this;r._nesting=0,r._outer=r._inner=Zone.current,Zone.TaskTrackingZoneSpec&&(r._inner=r._inner.fork(new Zone.TaskTrackingZoneSpec)),t&&Zone.longStackTraceZoneSpec&&(r._inner=r._inner.fork(Zone.longStackTraceZoneSpec)),r.shouldCoalesceEventChangeDetection=!i&&e,r.shouldCoalesceRunChangeDetection=i,r.lastRequestAnimationFrameId=-1,r.nativeRequestAnimationFrame=function c7(){const n="function"==typeof rr.requestAnimationFrame;let t=rr[n?"requestAnimationFrame":"setTimeout"],e=rr[n?"cancelAnimationFrame":"clearTimeout"];if(typeof Zone<"u"&&t&&e){const i=t[Zone.__symbol__("OriginalDelegate")];i&&(t=i);const r=e[Zone.__symbol__("OriginalDelegate")];r&&(e=r)}return{nativeRequestAnimationFrame:t,nativeCancelAnimationFrame:e}}().nativeRequestAnimationFrame,function f7(n){const t=()=>{!function u7(n){n.isCheckStableRunning||-1!==n.lastRequestAnimationFrameId||(n.lastRequestAnimationFrameId=n.nativeRequestAnimationFrame.call(rr,()=>{n.fakeTopEventTask||(n.fakeTopEventTask=Zone.root.scheduleEventTask("fakeTopEventTask",()=>{n.lastRequestAnimationFrameId=-1,LM(n),n.isCheckStableRunning=!0,AM(n),n.isCheckStableRunning=!1},void 0,()=>{},()=>{})),n.fakeTopEventTask.invoke()}),LM(n))}(n)};n._inner=n._inner.fork({name:"angular",properties:{isAngularZone:!0},onInvokeTask:(e,i,r,s,o,a)=>{if(function p7(n){return!(!Array.isArray(n)||1!==n.length)&&!0===n[0].data?.__ignore_ng_zone__}(a))return e.invokeTask(r,s,o,a);try{return YN(n),e.invokeTask(r,s,o,a)}finally{(n.shouldCoalesceEventChangeDetection&&"eventTask"===s.type||n.shouldCoalesceRunChangeDetection)&&t(),QN(n)}},onInvoke:(e,i,r,s,o,a,l)=>{try{return YN(n),e.invoke(r,s,o,a,l)}finally{n.shouldCoalesceRunChangeDetection&&t(),QN(n)}},onHasTask:(e,i,r,s)=>{e.hasTask(r,s),i===r&&("microTask"==s.change?(n._hasPendingMicrotasks=s.microTask,LM(n),AM(n)):"macroTask"==s.change&&(n.hasPendingMacrotasks=s.macroTask))},onHandleError:(e,i,r,s)=>(e.handleError(r,s),n.runOutsideAngular(()=>n.onError.emit(s)),!1)})}(r)}static isInAngularZone(){return typeof Zone<"u"&&!0===Zone.current.get("isAngularZone")}static assertInAngularZone(){if(!Rr.isInAngularZone())throw new F(909,!1)}static assertNotInAngularZone(){if(Rr.isInAngularZone())throw new F(909,!1)}run(t,e,i){return this._inner.run(t,e,i)}runTask(t,e,i,r){const s=this._inner,o=s.scheduleEventTask("NgZoneEvent: "+r,t,d7,WN,WN);try{return s.runTask(o,e,i)}finally{s.cancelTask(o)}}runGuarded(t,e,i){return this._inner.runGuarded(t,e,i)}runOutsideAngular(t){return this._outer.run(t)}}const d7={};function AM(n){if(0==n._nesting&&!n.hasPendingMicrotasks&&!n.isStable)try{n._nesting++,n.onMicrotaskEmpty.emit(null)}finally{if(n._nesting--,!n.hasPendingMicrotasks)try{n.runOutsideAngular(()=>n.onStable.emit(null))}finally{n.isStable=!0}}}function LM(n){n.hasPendingMicrotasks=!!(n._hasPendingMicrotasks||(n.shouldCoalesceEventChangeDetection||n.shouldCoalesceRunChangeDetection)&&-1!==n.lastRequestAnimationFrameId)}function YN(n){n._nesting++,n.isStable&&(n.isStable=!1,n.onUnstable.emit(null))}function QN(n){n._nesting--,AM(n)}let $p=(()=>{class n{constructor(){this.handler=null,this.internalCallbacks=[]}execute(){const e=[...this.internalCallbacks];this.internalCallbacks.length=0;for(const r of e)r();return!!this.handler?.execute()||e.length>0}ngOnDestroy(){this.handler?.destroy(),this.handler=null,this.internalCallbacks.length=0}static{this.\u0275prov=Yi({token:n,providedIn:"root",factory:()=>new n})}}return n})();function y7(n,t){const e=To(t,n),i=e[Be];!function S7(n,t){for(let e=t.length;e0&&HL(n,e,s.join(" "))}}(u,w,p,i),void 0!==e&&function A7(n,t,e){const i=n.projection=[];for(let r=0;r=0;i--){const r=n[i];r.hostVars=t+=r.hostVars,r.hostAttrs=Ip(r.hostAttrs,e=Ip(e,r.hostAttrs))}}(i)}function N7(n,t){for(const e in t.inputs){if(!t.inputs.hasOwnProperty(e)||n.inputs.hasOwnProperty(e))continue;const i=t.inputs[e];if(void 0!==i&&(n.inputs[e]=i,n.declaredInputs[e]=t.declaredInputs[e],null!==t.inputTransforms)){const r=Array.isArray(i)?i[0]:i;if(!t.inputTransforms.hasOwnProperty(r))continue;n.inputTransforms??={},n.inputTransforms[r]=t.inputTransforms[r]}}}function Ty(n){return n===rl?{}:n===Qi?[]:n}function k7(n,t){const e=n.viewQuery;n.viewQuery=e?(i,r)=>{t(i,r),e(i,r)}:t}function P7(n,t){const e=n.contentQueries;n.contentQueries=e?(i,r,s)=>{t(i,r,s),e(i,r,s)}:t}function z7(n,t){const e=n.hostBindings;n.hostBindings=e?(i,r)=>{t(i,r),e(i,r)}:t}function Lu(n,t){return!t||null===t.firstChild||ry(n)}function rg(n,t,e,i=!0){const r=t[Be];if(function r6(n,t,e,i){const r=mn+i,s=e.length;i>0&&(e[r-1][wa]=t),i{class n{static{this.__NG_ELEMENT_ID__=h9}}return n})();function h9(){return fO(pr(),Se())}const c9=An,dO=class extends c9{constructor(t,e,i){super(),this._lContainer=t,this._hostTNode=e,this._hostLView=i}get element(){return xu(this._hostTNode,this._hostLView)}get injector(){return new Yn(this._hostTNode,this._hostLView)}get parentInjector(){const t=Vm(this._hostTNode,this._hostLView);if(o1(t)){const e=Np(t,this._hostLView),i=Lp(t);return new Yn(e[Be].data[i+8],e)}return new Yn(null,this._hostLView)}clear(){for(;this.length>0;)this.remove(this.length-1)}get(t){const e=uO(this._lContainer);return null!==e&&e[t]||null}get length(){return this._lContainer.length-mn}createEmbeddedView(t,e,i){let r,s;"number"==typeof i?r=i:null!=i&&(r=i.index,s=i.injector);const a=t.createEmbeddedViewImpl(e||{},s,null);return this.insertImpl(a,r,Lu(this._hostTNode,null)),a}createComponent(t,e,i,r,s){const o=t&&!function Op(n){return"function"==typeof n}(t);let a;if(o)a=e;else{const p=e||{};a=p.index,i=p.injector,r=p.projectableNodes,s=p.environmentInjector||p.ngModuleRef}const l=o?t:new Zp(di(t)),h=i||this.parentInjector;if(!s&&null==l.ngModule){const g=(o?h:this.parentInjector).get(ih,null);g&&(s=g)}di(l.componentType??{});const f=l.create(h,r,null,s);return this.insertImpl(f.hostView,a,Lu(this._hostTNode,null)),f}insert(t,e){return this.insertImpl(t,e,!0)}insertImpl(t,e,i){const r=t._lView;if(function hU(n){return Ps(n[vn])}(r)){const a=this.indexOf(t);if(-1!==a)this.detach(a);else{const l=r[vn],h=new dO(l,l[Os],l[vn]);h.detach(h.indexOf(t))}}const s=this._adjustIndex(e),o=this._lContainer;return rg(o,r,s,i),t.attachToViewContainerRef(),UA(BM(o),s,t),t}move(t,e){return this.insert(t,e)}indexOf(t){const e=uO(this._lContainer);return null!==e?e.indexOf(t):-1}remove(t){const e=this._adjustIndex(t,-1),i=Bp(this._lContainer,e);i&&(Ym(BM(this._lContainer),e),ay(i[Be],i))}detach(t){const e=this._adjustIndex(t,-1),i=Bp(this._lContainer,e);return i&&null!=Ym(BM(this._lContainer),e)?new qp(i):null}_adjustIndex(t,e=0){return t??this.length+e}};function uO(n){return n[8]}function BM(n){return n[8]||(n[8]=[])}function fO(n,t){let e;const i=t[n.index];return Ps(i)?e=i:(e=function PN(n,t,e,i){return[n,!0,0,t,null,i,null,e,null,null]}(i,t,null,n),t[n.index]=e,Ey(t,e)),pO(e,t,n,i),new dO(e,n,t)}let pO=function vO(n,t,e,i){if(n[sl])return;let r;r=8&e.type?fr(i):function d9(n,t){const e=n[Yt],i=e.createComment(""),r=qs(t,n);return qc(e,ly(e,r),i,function l6(n,t){return n.nextSibling(t)}(e,r),!1),i}(t,e),n[sl]=r};function _y(n,t,e){const i=Se();return function Ln(n,t,e){return!Object.is(n[t],e)&&(n[t]=e,!0)}(i,function hl(){return Rt.lFrame.bindingIndex++}(),t)&&function No(n,t,e,i,r,s,o,a){const l=qs(t,e);let c,h=t.inputs;!a&&null!=h&&(c=h[i])?(CM(n,e,c,i,r),jc(t)&&function kV(n,t){const e=To(t,n);16&e[Ct]||(e[Ct]|=64)}(e,t.index)):3&t.type&&(i=function OV(n){return"class"===n?"className":"for"===n?"htmlFor":"formaction"===n?"formAction":"innerHtml"===n?"innerHTML":"readonly"===n?"readOnly":"tabindex"===n?"tabIndex":n}(i),r=null!=o?o(r,t.value||"",i):r,s.setProperty(l,i,r))}(Ti(),function zr(){const n=Rt.lFrame;return Dp(n.tView,n.selectedIndex)}(),i,n,t,i[Yt],e,!1),_y}function ZM(n,t,e,i,r){const o=r?"class":"style";CM(n,e,t.inputs[o],o,i)}function Gu(n,t,e,i){const r=Se(),s=Ti(),o=jt+n,a=r[Yt],l=s.firstCreatePass?function B8(n,t,e,i,r,s){const o=t.consts,l=Tu(t,n,2,i,al(o,r));return function IM(n,t,e,i){if(gA()){const r=null===i?null:{"":-1},s=function FV(n,t){const e=n.directiveRegistry;let i=null,r=null;if(e)for(let s=0;s($h(!0),oy(i,r,function DA(){return Rt.lFrame.currentNamespace}()));const $u="en-US";let Mk=$u;function aw(n){return!!n&&"function"==typeof n.then}function Gk(n){return!!n&&"function"==typeof n.subscribe}function lw(n,t,e,i){const r=Se(),s=Ti(),o=pr();return function qk(n,t,e,i,r,s,o){const a=Pm(i),h=n.firstCreatePass&&HN(n),c=t[Er],d=RN(t);let u=!0;if(3&i.type||o){const g=qs(i,t),v=o?o(g):g,y=d.length,S=o?M=>o(fr(M[i.index])):i.index;let b=null;if(!o&&a&&(b=function UW(n,t,e,i){const r=n.cleanup;if(null!=r)for(let s=0;sl?a[l]:null}"string"==typeof o&&(s+=2)}return null}(n,t,r,i.index)),null!==b)(b.__ngLastListenerFn__||b).__ngNextListenerFn__=s,b.__ngLastListenerFn__=s,u=!1;else{s=Zk(i,t,c,s,!1);const M=e.listen(v,r,s);d.push(s,M),h&&h.push(r,S,y,y+1)}}else s=Zk(i,t,c,s,!1);const f=i.outputs;let p;if(u&&null!==f&&(p=f[r])){const g=p.length;if(g)for(let v=0;v-1?To(n.index,t):t);let l=$k(t,e,i,o),h=s.__ngNextListenerFn__;for(;h;)l=$k(t,e,h,o)&&l,h=h.__ngNextListenerFn__;return r&&!1===l&&o.preventDefault(),l}}function QW(){return this._results[Symbol.iterator]()}class cw{get changes(){return this._changes??=new Yo}constructor(t=!1){this._emitDistinctChangesOnly=t,this.dirty=!0,this._results=[],this._changesDetected=!1,this._changes=void 0,this.length=0,this.first=void 0,this.last=void 0;const e=cw.prototype;e[Symbol.iterator]||(e[Symbol.iterator]=QW)}get(t){return this._results[t]}map(t){return this._results.map(t)}filter(t){return this._results.filter(t)}find(t){return this._results.find(t)}reduce(t,e){return this._results.reduce(t,e)}forEach(t){this._results.forEach(t)}some(t){return this._results.some(t)}toArray(){return this._results.slice()}toString(){return this._results.toString()}reset(t,e){this.dirty=!1;const i=function lo(n){return n.flat(Number.POSITIVE_INFINITY)}(t);(this._changesDetected=!function $U(n,t,e){if(n.length!==t.length)return!1;for(let i=0;i{class n{static{this.__NG_ELEMENT_ID__=qW}}return n})();const GW=oh,XW=class extends GW{constructor(t,e,i){super(),this._declarationLView=t,this._declarationTContainer=e,this.elementRef=i}get ssrId(){return this._declarationTContainer.tView?.ssrId||null}createEmbeddedView(t,e){return this.createEmbeddedViewImpl(t,e)}createEmbeddedViewImpl(t,e,i){const r=function ig(n,t,e,i){const r=t.tView,a=Cy(n,r,e,4096&n[Ct]?4096:16,null,t,null,null,null,i?.injector??null,i?.dehydratedView??null);a[Mp]=n[t.index];const h=n[nl];return null!==h&&(a[nl]=h.createEmbeddedView(r)),NM(r,a,e),a}(this._declarationLView,this._declarationTContainer,t,{injector:e,dehydratedView:i});return new qp(r)}};function qW(){return Gy(pr(),Se())}function Gy(n,t){return 4&n.type?new XW(t,n,xu(n,t)):null}class dw{constructor(t){this.queryList=t,this.matches=null}clone(){return new dw(this.queryList)}setDirty(){this.queryList.setDirty()}}class uw{constructor(t=[]){this.queries=t}createEmbeddedView(t){const e=t.queries;if(null!==e){const i=null!==t.contentQueries?t.contentQueries[0]:e.length,r=[];for(let s=0;s0)i.push(o[a/2]);else{const h=s[a+1],c=t[-l];for(let d=mn;d($h(!0),function sy(n,t){return n.createText(t)}(t[Yt],i));function mw(n,t,e,i,r){if(n=vt(n),Array.isArray(n))for(let s=0;s>20;if(Gc(n)||!n.multi){const f=new Ap(h,r,Ot),p=Sw(l,t,r?c:c+u,d);-1===p?(h1(jm(a,o),s,l),yw(s,n,t.length),t.push(l),a.directiveStart++,a.directiveEnd++,r&&(a.providerIndexes+=1048576),e.push(f),o.push(f)):(e[p]=f,o[p]=f)}else{const f=Sw(l,t,c+u,d),p=Sw(l,t,c,c+u),v=p>=0&&e[p];if(r&&!v||!r&&!(f>=0&&e[f])){h1(jm(a,o),s,l);const y=function yY(n,t,e,i,r){const s=new Ap(n,e,Ot);return s.multi=[],s.index=t,s.componentProviders=0,kP(s,r,i&&!e),s}(r?mY:vY,e.length,r,i,h);!r&&v&&(e[p].providerFactory=y),yw(s,n,t.length,0),t.push(l),a.directiveStart++,a.directiveEnd++,r&&(a.providerIndexes+=1048576),e.push(y),o.push(y)}else yw(s,n,f>-1?f:p,kP(e[r?p:f],h,!r&&i));!r&&i&&v&&e[p].componentProviders++}}}function yw(n,t,e,i){const r=Gc(t),s=function gj(n){return!!n.useClass}(t);if(r||s){const l=(s?vt(t.useClass):t).prototype.ngOnDestroy;if(l){const h=n.destroyHooks||(n.destroyHooks=[]);if(!r&&t.multi){const c=h.indexOf(e);-1===c?h.push(e,[i,l]):h[c+1].push(i,l)}else h.push(e,l)}}}function kP(n,t,e){return e&&n.componentProviders++,n.multi.push(t)-1}function Sw(n,t,e,i){for(let r=e;r{e.providersResolver=(i,r)=>function gY(n,t,e){const i=Ti();if(i.firstCreatePass){const r=Ea(n);mw(e,i.data,i.blueprint,r,!0),mw(t,i.data,i.blueprint,r,!1)}}(i,r?r(n):n,t)}}class rd{}class zP extends rd{constructor(t){super(),this.componentFactoryResolver=new JN(this),this.instance=null;const e=new mu([...t.providers,{provide:rd,useValue:this},{provide:Iy,useValue:this.componentFactoryResolver}],t.parent||Jm(),t.debugName,new Set(["environment"]));this.injector=e,t.runEnvironmentInitializers&&e.resolveInjectorInitializers()}destroy(){this.injector.destroy()}onDestroy(t){this.injector.onDestroy(t)}}let wY=(()=>{class n{constructor(e){this._injector=e,this.cachedInjectors=new Map}getOrCreateStandaloneInjector(e){if(!e.standalone)return null;if(!this.cachedInjectors.has(e)){const i=XA(0,e.type),r=i.length>0?function MY(n,t,e=null){return new zP({providers:n,parent:t,debugName:e,runEnvironmentInitializers:!0}).injector}([i],this._injector,`Standalone[${e.type.name}]`):null;this.cachedInjectors.set(e,r)}return this.cachedInjectors.get(e)}ngOnDestroy(){try{for(const e of this.cachedInjectors.values())null!==e&&e.destroy()}finally{this.cachedInjectors.clear()}}static{this.\u0275prov=Yi({token:n,providedIn:"environment",factory:()=>new n(_i(ih))})}}return n})();function RP(n){(function Zc(n){VN.has(n)||(VN.add(n),performance?.mark?.("mark_feature_usage",{detail:{feature:n}}))})("NgStandalone"),n.getStandaloneInjector=t=>t.get(wY).getOrCreateStandaloneInjector(n)}let Aw=(()=>{class n{constructor(){this.taskId=0,this.pendingTasks=new Set,this.hasPendingTasks=new _o(!1)}get _hasPendingTasks(){return this.hasPendingTasks.value}add(){this._hasPendingTasks||this.hasPendingTasks.next(!0);const e=this.taskId++;return this.pendingTasks.add(e),e}remove(e){this.pendingTasks.delete(e),0===this.pendingTasks.size&&this._hasPendingTasks&&this.hasPendingTasks.next(!1)}ngOnDestroy(){this.pendingTasks.clear(),this._hasPendingTasks&&this.hasPendingTasks.next(!1)}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();const g2=new Ht(""),XQ=new Ht("");let Pw=(()=>{class n{constructor(){this.initialized=!1,this.done=!1,this.donePromise=new Promise((e,i)=>{this.resolve=e,this.reject=i}),this.appInits=Hi(XQ,{optional:!0})??[]}runInitializers(){if(this.initialized)return;const e=[];for(const r of this.appInits){const s=r();if(aw(s))e.push(s);else if(Gk(s)){const o=new Promise((a,l)=>{s.subscribe({complete:a,error:l})});e.push(o)}}const i=()=>{this.done=!0,this.resolve()};Promise.all(e).then(()=>{i()}).catch(r=>{this.reject(r)}),0===e.length&&i(),this.initialized=!0}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();const v2=new Ht("");let Ku=(()=>{class n{constructor(){this._bootstrapListeners=[],this._runningTick=!1,this._destroyed=!1,this._destroyListeners=[],this._views=[],this.internalErrorHandler=Hi(SN),this.afterRenderEffectManager=Hi($p),this.componentTypes=[],this.components=[],this.isStable=Hi(Aw).hasPendingTasks.pipe(jr(e=>!e)),this._injector=Hi(ih)}get destroyed(){return this._destroyed}get injector(){return this._injector}bootstrap(e,i){const r=e instanceof rN;if(!this._injector.get(Pw).done)throw!r&&function _c(n){const t=di(n)||Wn(n)||gs(n);return null!==t&&t.standalone}(e),new F(405,!1);let o;o=r?e:this._injector.get(Iy).resolveComponentFactory(e),this.componentTypes.push(o.componentType);const a=function $Q(n){return n.isBoundToModule}(o)?void 0:this._injector.get(rd),h=o.create(Wo.NULL,[],i||o.selector,a),c=h.location.nativeElement,d=h.injector.get(g2,null);return d?.registerApplication(c),h.onDestroy(()=>{this.detachView(h.hostView),Ky(this.components,h),d?.unregisterApplication(c)}),this._loadComponent(h),h}tick(){if(this._runningTick)throw new F(101,!1);try{this._runningTick=!0;for(let e of this._views)e.detectChanges()}catch(e){this.internalErrorHandler(e)}finally{try{this.afterRenderEffectManager.execute()}catch(e){this.internalErrorHandler(e)}this._runningTick=!1}}attachView(e){const i=e;this._views.push(i),i.attachToAppRef(this)}detachView(e){const i=e;Ky(this._views,i),i.detachFromAppRef()}_loadComponent(e){this.attachView(e.hostView),this.tick(),this.components.push(e);const i=this._injector.get(v2,[]);[...this._bootstrapListeners,...i].forEach(r=>r(e))}ngOnDestroy(){if(!this._destroyed)try{this._destroyListeners.forEach(e=>e()),this._views.slice().forEach(e=>e.destroy())}finally{this._destroyed=!0,this._views=[],this._bootstrapListeners=[],this._destroyListeners=[]}}onDestroy(e){return this._destroyListeners.push(e),()=>Ky(this._destroyListeners,e)}destroy(){if(this._destroyed)throw new F(406,!1);const e=this._injector;e.destroy&&!e.destroyed&&e.destroy()}get viewCount(){return this._views.length}warnIfDestroyed(){}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();function Ky(n,t){const e=n.indexOf(t);e>-1&&n.splice(e,1)}let JQ=(()=>{class n{constructor(){this.zone=Hi(Rr),this.applicationRef=Hi(Ku)}initialize(){this._onMicrotaskEmptySubscription||(this._onMicrotaskEmptySubscription=this.zone.onMicrotaskEmpty.subscribe({next:()=>{this.zone.run(()=>{this.applicationRef.tick()})}}))}ngOnDestroy(){this._onMicrotaskEmptySubscription?.unsubscribe()}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();function b2(n){return[{provide:Rr,useFactory:n},{provide:vu,multi:!0,useFactory:()=>{const t=Hi(JQ,{optional:!0});return()=>t.initialize()}},{provide:vu,multi:!0,useFactory:()=>{const t=Hi(tG);return()=>{t.initialize()}}},{provide:SN,useFactory:KQ}]}function KQ(){const n=Hi(Rr),t=Hi(nh);return e=>n.runOutsideAngular(()=>t.handleError(e))}function eG(n){return function I1(n){return{\u0275providers:n}}([[],b2(()=>new Rr(function M2(n){return{enableLongStackTrace:!1,shouldCoalesceEventChangeDetection:n?.eventCoalescing??!1,shouldCoalesceRunChangeDetection:n?.runCoalescing??!1}}(n)))])}let tG=(()=>{class n{constructor(){this.subscription=new As,this.initialized=!1,this.zone=Hi(Rr),this.pendingTasks=Hi(Aw)}initialize(){if(this.initialized)return;this.initialized=!0;let e=null;!this.zone.isStable&&!this.zone.hasPendingMacrotasks&&!this.zone.hasPendingMicrotasks&&(e=this.pendingTasks.add()),this.zone.runOutsideAngular(()=>{this.subscription.add(this.zone.onStable.subscribe(()=>{Rr.assertNotInAngularZone(),queueMicrotask(()=>{null!==e&&!this.zone.hasPendingMacrotasks&&!this.zone.hasPendingMicrotasks&&(this.pendingTasks.remove(e),e=null)})}))}),this.subscription.add(this.zone.onUnstable.subscribe(()=>{Rr.assertInAngularZone(),e??=this.pendingTasks.add()}))}ngOnDestroy(){this.subscription.unsubscribe()}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();const ah=new Ht("",{providedIn:"root",factory:()=>Hi(ah,xi.Optional|xi.SkipSelf)||function iG(){return typeof $localize<"u"&&$localize.locale||$u}()}),zw=new Ht("");let nc=null;function DG(n){try{const{rootComponent:t,appProviders:e,platformProviders:i}=n,r=function aG(n=[]){if(nc)return nc;const t=function E2(n=[],t){return Wo.create({name:t,providers:[{provide:w1,useValue:"platform"},{provide:zw,useValue:new Set([()=>nc=null])},...n]})}(n);return nc=t,function m2(){!function bb(n){Xd=n}(()=>{throw new F(600,!1)})}(),function D2(n){n.get(sL,null)?.forEach(e=>e())}(t),t}(i),s=[eG(),...e||[]],a=new zP({providers:s,parent:r,debugName:"",runEnvironmentInitializers:!1}).injector,l=a.get(Rr);return l.run(()=>{a.resolveInjectorInitializers();const h=a.get(nh,null);let c;l.runOutsideAngular(()=>{c=l.onError.subscribe({next:f=>{h.handleError(f)}})});const d=()=>a.destroy(),u=r.get(zw);return u.add(d),a.onDestroy(()=>{c.unsubscribe(),u.delete(d)}),function y2(n,t,e){try{const i=e();return aw(i)?i.catch(r=>{throw t.runOutsideAngular(()=>n.handleError(r)),r}):i}catch(i){throw t.runOutsideAngular(()=>n.handleError(i)),i}}(h,l,()=>{const f=a.get(Pw);return f.runInitializers(),f.donePromise.then(()=>{!function wk(n){so(n,"Expected localeId to be defined"),"string"==typeof n&&(Mk=n.toLowerCase().replace(/_/g,"-"))}(a.get(ah,$u)||$u);const g=a.get(Ku);return void 0!==t&&g.bootstrap(t),g})})})}catch(t){return Promise.reject(t)}}let $2=null;function Vw(){return $2}class UG{}const sd=new Ht("");let sq=(()=>{class n{static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275mod=Lm({type:n})}static{this.\u0275inj=mp({})}}return n})();function uz(n){return"server"===n}class kq extends UG{constructor(){super(...arguments),this.supportsDOMEvents=!0}}class oC extends kq{static makeCurrent(){!function _G(n){$2??=n}(new oC)}onAndCancel(t,e,i){return t.addEventListener(e,i),()=>{t.removeEventListener(e,i)}}dispatchEvent(t,e){t.dispatchEvent(e)}remove(t){t.parentNode&&t.parentNode.removeChild(t)}createElement(t,e){return(e=e||this.getDefaultDocument()).createElement(t)}createHtmlDocument(){return document.implementation.createHTMLDocument("fakeTitle")}getDefaultDocument(){return document}isElementNode(t){return t.nodeType===Node.ELEMENT_NODE}isShadowRoot(t){return t instanceof DocumentFragment}getGlobalEventTarget(t,e){return"window"===e?window:"document"===e?t:"body"===e?t.body:null}getBaseHref(t){const e=function Pq(){return wg=wg||document.querySelector("base"),wg?wg.getAttribute("href"):null}();return null==e?null:function zq(n){return new URL(n,document.baseURI).pathname}(e)}resetBaseElement(){wg=null}getUserAgent(){return window.navigator.userAgent}getCookie(t){return function xX(n,t){t=encodeURIComponent(t);for(const e of n.split(";")){const i=e.indexOf("="),[r,s]=-1==i?[e,""]:[e.slice(0,i),e.slice(i+1)];if(r.trim()===t)return decodeURIComponent(s)}return null}(document.cookie,t)}}let wg=null,Hq=(()=>{class n{build(){return new XMLHttpRequest}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();const aC=new Ht("");let vz=(()=>{class n{constructor(e,i){this._zone=i,this._eventNameToPlugin=new Map,e.forEach(r=>{r.manager=this}),this._plugins=e.slice().reverse()}addEventListener(e,i,r){return this._findPluginFor(i).addEventListener(e,i,r)}getZone(){return this._zone}_findPluginFor(e){let i=this._eventNameToPlugin.get(e);if(i)return i;if(i=this._plugins.find(s=>s.supports(e)),!i)throw new F(5101,!1);return this._eventNameToPlugin.set(e,i),i}static{this.\u0275fac=function(i){return new(i||n)(_i(aC),_i(Rr))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();class mz{constructor(t){this._doc=t}}const lC="ng-app-id";let yz=(()=>{class n{constructor(e,i,r,s={}){this.doc=e,this.appId=i,this.nonce=r,this.platformId=s,this.styleRef=new Map,this.hostNodes=new Set,this.styleNodesInDOM=this.collectServerRenderedStyles(),this.platformIsServer=uz(s),this.resetHostNodes()}addStyles(e){for(const i of e)1===this.changeUsageCount(i,1)&&this.onStyleAdded(i)}removeStyles(e){for(const i of e)this.changeUsageCount(i,-1)<=0&&this.onStyleRemoved(i)}ngOnDestroy(){const e=this.styleNodesInDOM;e&&(e.forEach(i=>i.remove()),e.clear());for(const i of this.getAllStyles())this.onStyleRemoved(i);this.resetHostNodes()}addHost(e){this.hostNodes.add(e);for(const i of this.getAllStyles())this.addStyleToHost(e,i)}removeHost(e){this.hostNodes.delete(e)}getAllStyles(){return this.styleRef.keys()}onStyleAdded(e){for(const i of this.hostNodes)this.addStyleToHost(i,e)}onStyleRemoved(e){const i=this.styleRef;i.get(e)?.elements?.forEach(r=>r.remove()),i.delete(e)}collectServerRenderedStyles(){const e=this.doc.head?.querySelectorAll(`style[${lC}="${this.appId}"]`);if(e?.length){const i=new Map;return e.forEach(r=>{null!=r.textContent&&i.set(r.textContent,r)}),i}return null}changeUsageCount(e,i){const r=this.styleRef;if(r.has(e)){const s=r.get(e);return s.usage+=i,s.usage}return r.set(e,{usage:i,elements:[]}),i}getStyleElement(e,i){const r=this.styleNodesInDOM,s=r?.get(i);if(s?.parentNode===e)return r.delete(i),s.removeAttribute(lC),s;{const o=this.doc.createElement("style");return this.nonce&&o.setAttribute("nonce",this.nonce),o.textContent=i,this.platformIsServer&&o.setAttribute(lC,this.appId),e.appendChild(o),o}}addStyleToHost(e,i){const r=this.getStyleElement(e,i),s=this.styleRef,o=s.get(i)?.elements;o?o.push(r):s.set(i,{elements:[r],usage:1})}resetHostNodes(){const e=this.hostNodes;e.clear(),e.add(this.doc.head)}static{this.\u0275fac=function(i){return new(i||n)(_i(sd),_i(L1),_i(oL,8),_i(Su))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();const hC={svg:"http://www.w3.org/2000/svg",xhtml:"http://www.w3.org/1999/xhtml",xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/",math:"http://www.w3.org/1998/MathML/"},cC=/%COMP%/g,Uq=new Ht("",{providedIn:"root",factory:()=>!0});function Iz(n,t){return t.map(e=>e.replace(cC,n))}let bz=(()=>{class n{constructor(e,i,r,s,o,a,l,h=null){this.eventManager=e,this.sharedStylesHost=i,this.appId=r,this.removeStylesOnCompDestroy=s,this.doc=o,this.platformId=a,this.ngZone=l,this.nonce=h,this.rendererByCompId=new Map,this.platformIsServer=uz(a),this.defaultRenderer=new dC(e,o,l,this.platformIsServer)}createRenderer(e,i){if(!e||!i)return this.defaultRenderer;this.platformIsServer&&i.encapsulation===ba.ShadowDom&&(i={...i,encapsulation:ba.Emulated});const r=this.getOrCreateRenderer(e,i);return r instanceof wz?r.applyToHost(e):r instanceof uC&&r.applyStyles(),r}getOrCreateRenderer(e,i){const r=this.rendererByCompId;let s=r.get(i.id);if(!s){const o=this.doc,a=this.ngZone,l=this.eventManager,h=this.sharedStylesHost,c=this.removeStylesOnCompDestroy,d=this.platformIsServer;switch(i.encapsulation){case ba.Emulated:s=new wz(l,h,i,this.appId,c,o,a,d);break;case ba.ShadowDom:return new Yq(l,h,e,i,o,a,this.nonce,d);default:s=new uC(l,h,i,c,o,a,d)}r.set(i.id,s)}return s}ngOnDestroy(){this.rendererByCompId.clear()}static{this.\u0275fac=function(i){return new(i||n)(_i(vz),_i(yz),_i(L1),_i(Uq),_i(sd),_i(Su),_i(Rr),_i(oL))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();class dC{constructor(t,e,i,r){this.eventManager=t,this.doc=e,this.ngZone=i,this.platformIsServer=r,this.data=Object.create(null),this.throwOnSyntheticProps=!0,this.destroyNode=null}destroy(){}createElement(t,e){return e?this.doc.createElementNS(hC[e]||e,t):this.doc.createElement(t)}createComment(t){return this.doc.createComment(t)}createText(t){return this.doc.createTextNode(t)}appendChild(t,e){(Mz(t)?t.content:t).appendChild(e)}insertBefore(t,e,i){t&&(Mz(t)?t.content:t).insertBefore(e,i)}removeChild(t,e){t&&t.removeChild(e)}selectRootElement(t,e){let i="string"==typeof t?this.doc.querySelector(t):t;if(!i)throw new F(-5104,!1);return e||(i.textContent=""),i}parentNode(t){return t.parentNode}nextSibling(t){return t.nextSibling}setAttribute(t,e,i,r){if(r){e=r+":"+e;const s=hC[r];s?t.setAttributeNS(s,e,i):t.setAttribute(e,i)}else t.setAttribute(e,i)}removeAttribute(t,e,i){if(i){const r=hC[i];r?t.removeAttributeNS(r,e):t.removeAttribute(`${i}:${e}`)}else t.removeAttribute(e)}addClass(t,e){t.classList.add(e)}removeClass(t,e){t.classList.remove(e)}setStyle(t,e,i,r){r&(ec.DashCase|ec.Important)?t.style.setProperty(e,i,r&ec.Important?"important":""):t.style[e]=i}removeStyle(t,e,i){i&ec.DashCase?t.style.removeProperty(e):t.style[e]=""}setProperty(t,e,i){null!=t&&(t[e]=i)}setValue(t,e){t.nodeValue=e}listen(t,e,i){if("string"==typeof t&&!(t=Vw().getGlobalEventTarget(this.doc,t)))throw new Error(`Unsupported event target ${t} for event ${e}`);return this.eventManager.addEventListener(t,e,this.decoratePreventDefault(i))}decoratePreventDefault(t){return e=>{if("__ngUnwrap__"===e)return t;!1===(this.platformIsServer?this.ngZone.runGuarded(()=>t(e)):t(e))&&e.preventDefault()}}}function Mz(n){return"TEMPLATE"===n.tagName&&void 0!==n.content}class Yq extends dC{constructor(t,e,i,r,s,o,a,l){super(t,s,o,l),this.sharedStylesHost=e,this.hostEl=i,this.shadowRoot=i.attachShadow({mode:"open"}),this.sharedStylesHost.addHost(this.shadowRoot);const h=Iz(r.id,r.styles);for(const c of h){const d=document.createElement("style");a&&d.setAttribute("nonce",a),d.textContent=c,this.shadowRoot.appendChild(d)}}nodeOrShadowRoot(t){return t===this.hostEl?this.shadowRoot:t}appendChild(t,e){return super.appendChild(this.nodeOrShadowRoot(t),e)}insertBefore(t,e,i){return super.insertBefore(this.nodeOrShadowRoot(t),e,i)}removeChild(t,e){return super.removeChild(this.nodeOrShadowRoot(t),e)}parentNode(t){return this.nodeOrShadowRoot(super.parentNode(this.nodeOrShadowRoot(t)))}destroy(){this.sharedStylesHost.removeHost(this.shadowRoot)}}class uC extends dC{constructor(t,e,i,r,s,o,a,l){super(t,s,o,a),this.sharedStylesHost=e,this.removeStylesOnCompDestroy=r,this.styles=l?Iz(l,i.styles):i.styles}applyStyles(){this.sharedStylesHost.addStyles(this.styles)}destroy(){this.removeStylesOnCompDestroy&&this.sharedStylesHost.removeStyles(this.styles)}}class wz extends uC{constructor(t,e,i,r,s,o,a,l){const h=r+"-"+i.id;super(t,e,i,s,o,a,l,h),this.contentAttr=function jq(n){return"_ngcontent-%COMP%".replace(cC,n)}(h),this.hostAttr=function Vq(n){return"_nghost-%COMP%".replace(cC,n)}(h)}applyToHost(t){this.applyStyles(),this.setAttribute(t,this.hostAttr,"")}createElement(t,e){const i=super.createElement(t,e);return super.setAttribute(i,this.contentAttr,""),i}}let Qq=(()=>{class n extends mz{constructor(e){super(e)}supports(e){return!0}addEventListener(e,i,r){return e.addEventListener(i,r,!1),()=>this.removeEventListener(e,i,r)}removeEventListener(e,i,r){return e.removeEventListener(i,r)}static{this.\u0275fac=function(i){return new(i||n)(_i(sd))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();const Cz=["alt","control","meta","shift"],Gq={"\b":"Backspace","\t":"Tab","\x7f":"Delete","\x1b":"Escape",Del:"Delete",Esc:"Escape",Left:"ArrowLeft",Right:"ArrowRight",Up:"ArrowUp",Down:"ArrowDown",Menu:"ContextMenu",Scroll:"ScrollLock",Win:"OS"},Xq={alt:n=>n.altKey,control:n=>n.ctrlKey,meta:n=>n.metaKey,shift:n=>n.shiftKey};let qq=(()=>{class n extends mz{constructor(e){super(e)}supports(e){return null!=n.parseEventName(e)}addEventListener(e,i,r){const s=n.parseEventName(i),o=n.eventCallback(s.fullKey,r,this.manager.getZone());return this.manager.getZone().runOutsideAngular(()=>Vw().onAndCancel(e,s.domEventName,o))}static parseEventName(e){const i=e.toLowerCase().split("."),r=i.shift();if(0===i.length||"keydown"!==r&&"keyup"!==r)return null;const s=n._normalizeKey(i.pop());let o="",a=i.indexOf("code");if(a>-1&&(i.splice(a,1),o="code."),Cz.forEach(h=>{const c=i.indexOf(h);c>-1&&(i.splice(c,1),o+=h+".")}),o+=s,0!=i.length||0===s.length)return null;const l={};return l.domEventName=r,l.fullKey=o,l}static matchEventFullKeyCode(e,i){let r=Gq[e.key]||e.key,s="";return i.indexOf("code.")>-1&&(r=e.code,s="code."),!(null==r||!r)&&(r=r.toLowerCase()," "===r?r="space":"."===r&&(r="dot"),Cz.forEach(o=>{o!==r&&(0,Xq[o])(e)&&(s+=o+".")}),s+=r,s===i)}static eventCallback(e,i,r){return s=>{n.matchEventFullKeyCode(s,e)&&r.runGuarded(()=>i(s))}}static _normalizeKey(e){return"esc"===e?"escape":e}static{this.\u0275fac=function(i){return new(i||n)(_i(sd))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();function Ez(n){return{appProviders:[...i$,...n?.providers??[]],platformProviders:e$}}const e$=[{provide:Su,useValue:"browser"},{provide:sL,useValue:function Zq(){oC.makeCurrent()},multi:!0},{provide:sd,useFactory:function Kq(){return function Aj(n){A1=n}(document),document},deps:[]}],i$=[{provide:w1,useValue:"root"},{provide:nh,useFactory:function Jq(){return new nh},deps:[]},{provide:aC,useClass:Qq,multi:!0,deps:[sd,Rr,Su]},{provide:aC,useClass:qq,multi:!0,deps:[sd]},bz,yz,vz,{provide:sN,useExisting:bz},{provide:class cq{},useClass:Hq,deps:[]},[]];var o$=0,fC=!1;function M0(n,t){var e=t;return e.unshift(void 0),new(Function.prototype.bind.apply(n,e))}function Y(n,t){for(var e=t,i=n.replace(/\[/g,".").replace(/\]/g,"").split("."),r=0;r"u"}function Ei(n){return n+"_"+o$++}function C0(n,t){return n===t||!(n===document||!n)&&C0(n.parentNode,t)}function Dg(n){try{throw new Error(n)}catch(t){throw new Error(t.message+"\n"+t.stack)}}function Re(n){var t=n+"";return t.match(/auto|cm|mm|in|px|pt|pc|%|em|ex|ch|rem|vw|vh|vmin|vmax/)?t:t+"px"}function ce(){return fC}var xg,n,t,d$={latn:{_digits:"0123456789",_type:"numeric"}},Lz={decimal:".",group:",",percentSign:"%",plusSign:"+",minusSign:"-",infinity:"\u221e",nan:"NaN",exponential:"E"},Nz=[0,1,2,3,4,5,6,7,8,9],Hr=function(){function n(){}return n.getMainObject=function(t,e){return Y(ce()?e:"main."+e,t)},n.getNumberingSystem=function(t){return Y("supplemental.numberingSystems",t)||this.numberingSystems},n.reverseObject=function(t,e){for(var r={},s=0,o=e||Object.keys(t);s13&&(p+=1,o-=12),o-=1,a=p-4716;var y=u-24e5,S=10631/30,b=u-1948084,M=Math.floor(b/10631);b-=10631*M;var w=Math.floor((b-.1335)/S),C=30*M+w;b-=Math.floor(w*S+.1335);var D=Math.floor((b+28.5001)/29.5);13===D&&(D=12);for(var A=b-Math.floor(29.5001*D-29),x=0;xy);x++);var P=x+16260,L=Math.floor((P-1)/12),O=L+1,N=P-12*L,T=y-t[x-1]+1;return(T+"").length>2&&(T=A,N=D,O=C),{year:O,month:N,date:T}},n.toGregorian=function i(r,s,o){var g=Math.floor(o+t[12*(r-1)+1+(s-1)-16260-1]-1+24e5+.5),v=Math.floor((g-1867216.25)/36524.25),y=1524+(v=g+1+v-Math.floor(v/4)),S=Math.floor((y-122.1)/365.25),b=Math.floor(365.25*S),M=Math.floor((y-b)/30.6001),w=y-b-Math.floor(30.6001*M),C=M-(M>13.5?13:1),D=S-(C>2.5?4716:4715);return D<=0&&C--,new Date(D+"/"+C+"/"+w)};var ut,p$=/\/MMMMM|MMMM|MMM|a|LLLL|LLL|EEEEE|EEEE|E|K|cccc|ccc|WW|W|G+|z+/gi,Oz="stand-alone",g$=["sun","mon","tue","wed","thu","fri","sat"],kz={m:"getMinutes",h:"getHours",H:"getHours",s:"getSeconds",d:"getDate",f:"getMilliseconds"},Pz=function(){function n(){}return n.dateFormat=function(t,e,i){var r=this,s=ut.getDependables(i,t,e.calendar),o=Y("parserObject.numbers",s),a=s.dateObject,l={isIslamic:ut.islamicRegex.test(e.calendar)};ce()&&e.isServerRendered&&(e=ut.compareBlazorDateFormats(e,t));var h=e.format||ut.getResultantPattern(e.skeleton,s.dateObject,e.type,!1,ce()?t:"");if(l.dateSeperator=ce()?Y("dateSeperator",a):ut.getDateSeparator(s.dateObject),st(h))Dg("Format options or type given must be invalid");else{h=ut.ConvertDateToWeekFormat(h),ce()&&(h=h.replace(/tt/,"a")),l.pattern=h,l.numMapper=ce()?ze({},o):Hr.getNumberMapper(s.parserObject,Hr.getNumberingSystem(i));for(var d=0,u=h.match(p$)||[];d2?r+=e.month[""+u]:p=!0;break;case"E":case"c":r+=e.weekday[""+g$[t.getDay()]];break;case"H":case"h":case"m":case"s":case"d":case"f":if(p=!0,"d"===d)u=o.date;else if("f"===d){p=!1,g=!0;var y=(f=(f=t[""+kz[""+d]]().toString()).substring(0,c)).length;if(c!==y){if(c>3)continue;for(var S=0;S0?1:0],o=Math.abs(t);return s.replace(/HH?|mm/g,function(a){var l=a.length,h=-1!==a.indexOf("H");return i.checkTwodigitNumber(Math.floor(h?o/60:o%60),l)})},n}(),zz={ms:"minimumSignificantDigits",ls:"maximumSignificantDigits",mf:"minimumFractionDigits",lf:"maximumFractionDigits"},nf=["infinity","nan","group","decimal","exponential"],Rz=function(){function n(){}return n.numberFormatter=function(t,e,i){var l,r=this,s=ze({},e),o={},a={},h=ut.getDependables(i,t,"",!0),c=h.numericObject;a.numberMapper=ce()?ze({},c):Hr.getNumberMapper(h.parserObject,Hr.getNumberingSystem(i),!0),a.currencySymbol=ce()?Y("currencySymbol",c):ut.getCurrencySymbol(h.numericObject,s.currency||Lg,e.altSymbol,e.ignoreCurrency),a.percentSymbol=ce()?Y("numberSymbols.percentSign",c):a.numberMapper.numberSymbols.percentSign,a.minusSymbol=ce()?Y("numberSymbols.minusSign",c):a.numberMapper.numberSymbols.minusSign;var d=a.numberMapper.numberSymbols;if(e.format&&!ut.formatRegex.test(e.format))o=ut.customFormat(e.format,a,h.numericObject),!st(s.useGrouping)&&s.useGrouping&&(s.useGrouping=o.pData.useGrouping);else{if(ze(s,ut.getProperNumericSkeleton(e.format||"N")),s.isCurrency="currency"===s.type,s.isPercent="percent"===s.type,ce()||(l=ut.getSymbolPattern(s.type,a.numberMapper.numberSystem,h.numericObject,s.isAccount)),s.groupOne=this.checkValueRange(s.maximumSignificantDigits,s.minimumSignificantDigits,!0),this.checkValueRange(s.maximumFractionDigits,s.minimumFractionDigits,!1,!0),st(s.fractionDigits)||(s.minimumFractionDigits=s.maximumFractionDigits=s.fractionDigits),st(s.useGrouping)&&(s.useGrouping=!0),s.isCurrency&&!ce()&&(l=l.replace(/\u00A4/g,ut.defaultCurrency)),ce())o.nData=ze({},{},Y(s.type+"nData",c)),o.pData=ze({},{},Y(s.type+"pData",c)),"currency"===s.type&&e.currency&&ut.replaceBlazorCurrency([o.pData,o.nData],a.currencySymbol,e.currency);else{var u=l.split(";");o.nData=ut.getFormatData(u[1]||"-"+u[0],!0,a.currencySymbol),o.pData=ut.getFormatData(u[0],!1,a.currencySymbol),s.useGrouping&&(s.groupSeparator=d[nf[2]],s.groupData=this.getGroupingDetails(u[0]))}if(st(s.minimumFractionDigits)&&(s.minimumFractionDigits=o.nData.minimumFraction),st(s.maximumFractionDigits)){var p=o.nData.maximumFraction;s.maximumFractionDigits=st(p)&&s.isPercent?0:p}var g=s.minimumFractionDigits,v=s.maximumFractionDigits;!st(g)&&!st(v)&&g>v&&(s.maximumFractionDigits=g)}return ze(o.nData,s),ze(o.pData,s),function(y){return isNaN(y)?d[nf[1]]:isFinite(y)?r.intNumberFormatter(y,o,a,e):d[nf[0]]}},n.getGroupingDetails=function(t){var e={},i=t.match(ut.negativeDataRegex);if(i&&i[4]){var r=i[4],s=r.lastIndexOf(",");if(-1!==s){var o=r.split(".")[0];e.primary=o.length-s-1;var a=r.lastIndexOf(",",s-1);-1!==a&&(e.secondary=s-1-a)}}return e},n.checkValueRange=function(t,e,i,r){var s=r?"f":"s",o=0,a=zz["l"+s],l=zz["m"+s];if(st(t)||(this.checkRange(t,a,r),o++),st(e)||(this.checkRange(e,l,r),o++),2===o){if(!(tr[1])&&Dg(e+"value must be within the range"+r[0]+"to"+r[1])},n.intNumberFormatter=function(t,e,i,r){var s;if(!st(e.nData.type)){t<0?(t*=-1,s=e.nData):s=0===t&&e.zeroData||e.pData;var o="";if(s.isPercent&&(t*=100),s.groupOne)o=this.processSignificantDigits(t,s.minimumSignificantDigits,s.maximumSignificantDigits);else if(o=this.processFraction(t,s.minimumFractionDigits,s.maximumFractionDigits,r),s.minimumIntegerDigits&&(o=this.processMinimumIntegers(o,s.minimumIntegerDigits)),i.isCustomFormat&&s.minimumFractionDigits=0&&"0"===l[parseInt(c.toString(),10)]&&c>=s.minimumFractionDigits;c--)l=l.slice(0,c);o=a[0]+"."+l}return"scientific"===s.type&&(o=(o=t.toExponential(s.maximumFractionDigits)).replace("e",i.numberMapper.numberSymbols[nf[4]])),o=o.replace(".",i.numberMapper.numberSymbols[nf[3]]),o="#,###,,;(#,###,,)"===s.format?this.customPivotFormat(parseInt(o,10)):o,s.useGrouping&&(o=this.groupNumbers(o,s.groupData.primary,s.groupSeparator||",",i.numberMapper.numberSymbols[nf[3]]||".",s.groupData.secondary)),o=Hr.convertValueParts(o,ut.latnParseRegex,i.numberMapper.mapper),"N/A"===s.nlead?s.nlead:"0"===o&&r&&"0"===r.format?o+s.nend:s.nlead+o+s.nend}},n.processSignificantDigits=function(t,e,i){var r=t+"";return r.lengthe;)c=l.slice(h-e,h)+(c.length?i+c:""),h-=e,o&&(e=s,o=!1);return a[0]=l.slice(0,h)+(c.length?i:"")+c,a.join(r)},n.processFraction=function(t,e,i,r){var s=(t+"").split(".")[1],o=s?s.length:0;if(e&&oi||0===i))return t.toFixed(i);var h=t+"";return"0"===h[0]&&r&&"###.00"===r.format&&(h=h.slice(1)),h},n.processMinimumIntegers=function(t,e){var i=t.split("."),r=i[0],s=r.length;if(s=5e5){var r=(t/=1e6).toString().split(".")[1];return r&&+r.substring(0,1)>=5?Math.ceil(t).toString():Math.floor(t).toString()}return""},n}(),Tg=(new RegExp("^([^0-9]*)(([0-9,]*[0-9]+)(.[0-9]+)?)([Ee][+-]?[0-9]+)?([^0-9]*)$"),function(){function n(t){this.ranArray=[],this.boundedEvents={},!m(t)&&(this.context=t)}return n.prototype.on=function(t,e,i,r){if(!m(e)){var s=i||this.context;if(this.notExist(t))return void(this.boundedEvents[""+t]=[{handler:e,context:s,id:r}]);m(r)?this.isHandlerPresent(this.boundedEvents[""+t],e)||this.boundedEvents[""+t].push({handler:e,context:s}):-1===this.ranArray.indexOf(r)&&(this.ranArray.push(r),this.boundedEvents[""+t].push({handler:e,context:s,id:r}))}},n.prototype.off=function(t,e,i){if(!this.notExist(t)){var r=Y(t,this.boundedEvents);if(e){for(var s=0;s1&&(U.fractionDigits=parseInt(z[2],10)),U}function p(T,z,U,B){var j=B?{}:{nlead:"",nend:""},Q=T.match(n.customRegex);if(Q){B||(j.nlead=g(Q[1],U),j.nend=g(Q[10],U),j.groupPattern=Q[4]);var oe=Q[7];if(oe&&z){var ue=oe.match(t);j.minimumFraction=m(ue)?0:ue.length,j.maximumFraction=oe.length-1}}return j}function g(T,z){return T?(T=T.replace(n.defaultCurrency,z),""===z?T.trim():T):""}function v(T,z,U,B){return B?"$":Y("currencies."+z+(U?"."+U:".symbol"),T)||Y("currencies."+z+".symbol-alt-narrow",T)||"$"}function S(T,z,U){var B={type:"decimal",minimumFractionDigits:0,maximumFractionDigits:0},j=T.match(n.customRegex);if(m(j)||""===j[5]&&"N/A"!==T)return B.type=void 0,B;B.nlead=j[1],B.nend=j[10];var Q=j[6],oe=!!Q.match(/ $/g),ue=-1!==Q.replace(/ $/g,"").indexOf(" ");B.useGrouping=-1!==Q.indexOf(",")||ue,Q=Q.replace(/,/g,"");var fe=j[7];if(-1!==Q.indexOf("0")&&(B.minimumIntegerDigits=Q.length-Q.indexOf("0")),m(fe)||(B.minimumFractionDigits=fe.lastIndexOf("0"),B.maximumFractionDigits=fe.lastIndexOf("#"),-1===B.minimumFractionDigits&&(B.minimumFractionDigits=0),(-1===B.maximumFractionDigits||B.maximumFractionDigitsQ.lastIndexOf("'"))){B[""+a[parseInt(j.toString(),10)]]=Q.substr(0,oe)+U+Q.substr(oe+1),B[""+a[""+z]]=!0,B.type=B.isCurrency?"currency":"percent";break}}return B}function C(T,z){if(-1!==T.indexOf(",")){var U=T.split(",");T=U[0]+Y("numberMapper.numberSymbols.group",z)+U[1].replace(".",Y("numberMapper.numberSymbols.decimal",z))}else T=T.replace(".",Y("numberMapper.numberSymbols.decimal",z));return T}function A(T,z,U){T+=".";for(var B=0;B0;Q-=3)T=","+U[Q-2]+U[Q-1]+U[parseInt(Q.toString(),10)]+T;return T=T.slice(1),z[1]?T+"."+z[1]:T}n.dateParseRegex=/([a-z])\1*|'([^']|'')+'|''|./gi,n.basicPatterns=["short","medium","long","full"],n.defaultObject={dates:{calendars:{gregorian:{months:{"stand-alone":{abbreviated:{1:"Jan",2:"Feb",3:"Mar",4:"Apr",5:"May",6:"Jun",7:"Jul",8:"Aug",9:"Sep",10:"Oct",11:"Nov",12:"Dec"},narrow:{1:"J",2:"F",3:"M",4:"A",5:"M",6:"J",7:"J",8:"A",9:"S",10:"O",11:"N",12:"D"},wide:{1:"January",2:"February",3:"March",4:"April",5:"May",6:"June",7:"July",8:"August",9:"September",10:"October",11:"November",12:"December"}}},days:{"stand-alone":{abbreviated:{sun:"Sun",mon:"Mon",tue:"Tue",wed:"Wed",thu:"Thu",fri:"Fri",sat:"Sat"},narrow:{sun:"S",mon:"M",tue:"T",wed:"W",thu:"T",fri:"F",sat:"S"},short:{sun:"Su",mon:"Mo",tue:"Tu",wed:"We",thu:"Th",fri:"Fr",sat:"Sa"},wide:{sun:"Sunday",mon:"Monday",tue:"Tuesday",wed:"Wednesday",thu:"Thursday",fri:"Friday",sat:"Saturday"}}},dayPeriods:{format:{wide:{am:"AM",pm:"PM"}}},eras:{eraNames:{0:"Before Christ","0-alt-variant":"Before Common Era",1:"Anno Domini","1-alt-variant":"Common Era"},eraAbbr:{0:"BC","0-alt-variant":"BCE",1:"AD","1-alt-variant":"CE"},eraNarrow:{0:"B","0-alt-variant":"BCE",1:"A","1-alt-variant":"CE"}},dateFormats:{full:"EEEE, MMMM d, y",long:"MMMM d, y",medium:"MMM d, y",short:"M/d/yy"},timeFormats:{full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},dateTimeFormats:{full:"{1} 'at' {0}",long:"{1} 'at' {0}",medium:"{1}, {0}",short:"{1}, {0}",availableFormats:{d:"d",E:"ccc",Ed:"d E",Ehm:"E h:mm a",EHm:"E HH:mm",Ehms:"E h:mm:ss a",EHms:"E HH:mm:ss",Gy:"y G",GyMMM:"MMM y G",GyMMMd:"MMM d, y G",GyMMMEd:"E, MMM d, y G",h:"h a",H:"HH",hm:"h:mm a",Hm:"HH:mm",hms:"h:mm:ss a",Hms:"HH:mm:ss",hmsv:"h:mm:ss a v",Hmsv:"HH:mm:ss v",hmv:"h:mm a v",Hmv:"HH:mm v",M:"L",Md:"M/d",MEd:"E, M/d",MMM:"LLL",MMMd:"MMM d",MMMEd:"E, MMM d",MMMMd:"MMMM d",ms:"mm:ss",y:"y",yM:"M/y",yMd:"M/d/y",yMEd:"E, M/d/y",yMMM:"MMM y",yMMMd:"MMM d, y",yMMMEd:"E, MMM d, y",yMMMM:"MMMM y"}}},islamic:{months:{"stand-alone":{abbreviated:{1:"Muh.",2:"Saf.",3:"Rab. I",4:"Rab. II",5:"Jum. I",6:"Jum. II",7:"Raj.",8:"Sha.",9:"Ram.",10:"Shaw.",11:"Dhu\u02bbl-Q.",12:"Dhu\u02bbl-H."},narrow:{1:"1",2:"2",3:"3",4:"4",5:"5",6:"6",7:"7",8:"8",9:"9",10:"10",11:"11",12:"12"},wide:{1:"Muharram",2:"Safar",3:"Rabi\u02bb I",4:"Rabi\u02bb II",5:"Jumada I",6:"Jumada II",7:"Rajab",8:"Sha\u02bbban",9:"Ramadan",10:"Shawwal",11:"Dhu\u02bbl-Qi\u02bbdah",12:"Dhu\u02bbl-Hijjah"}}},days:{"stand-alone":{abbreviated:{sun:"Sun",mon:"Mon",tue:"Tue",wed:"Wed",thu:"Thu",fri:"Fri",sat:"Sat"},narrow:{sun:"S",mon:"M",tue:"T",wed:"W",thu:"T",fri:"F",sat:"S"},short:{sun:"Su",mon:"Mo",tue:"Tu",wed:"We",thu:"Th",fri:"Fr",sat:"Sa"},wide:{sun:"Sunday",mon:"Monday",tue:"Tuesday",wed:"Wednesday",thu:"Thursday",fri:"Friday",sat:"Saturday"}}},dayPeriods:{format:{wide:{am:"AM",pm:"PM"}}},eras:{eraNames:{0:"AH"},eraAbbr:{0:"AH"},eraNarrow:{0:"AH"}},dateFormats:{full:"EEEE, MMMM d, y G",long:"MMMM d, y G",medium:"MMM d, y G",short:"M/d/y GGGGG"},timeFormats:{full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},dateTimeFormats:{full:"{1} 'at' {0}",long:"{1} 'at' {0}",medium:"{1}, {0}",short:"{1}, {0}",availableFormats:{d:"d",E:"ccc",Ed:"d E",Ehm:"E h:mm a",EHm:"E HH:mm",Ehms:"E h:mm:ss a",EHms:"E HH:mm:ss",Gy:"y G",GyMMM:"MMM y G",GyMMMd:"MMM d, y G",GyMMMEd:"E, MMM d, y G",h:"h a",H:"HH",hm:"h:mm a",Hm:"HH:mm",hms:"h:mm:ss a",Hms:"HH:mm:ss",M:"L",Md:"M/d",MEd:"E, M/d",MMM:"LLL",MMMd:"MMM d",MMMEd:"E, MMM d",MMMMd:"MMMM d",ms:"mm:ss",y:"y G",yyyy:"y G",yyyyM:"M/y GGGGG",yyyyMd:"M/d/y GGGGG",yyyyMEd:"E, M/d/y GGGGG",yyyyMMM:"MMM y G",yyyyMMMd:"MMM d, y G",yyyyMMMEd:"E, MMM d, y G",yyyyMMMM:"MMMM y G",yyyyQQQ:"QQQ y G",yyyyQQQQ:"QQQQ y G"}}}},timeZoneNames:{hourFormat:"+HH:mm;-HH:mm",gmtFormat:"GMT{0}",gmtZeroFormat:"GMT"}},numbers:{currencies:{USD:{displayName:"US Dollar",symbol:"$","symbol-alt-narrow":"$"},EUR:{displayName:"Euro",symbol:"\u20ac","symbol-alt-narrow":"\u20ac"},GBP:{displayName:"British Pound","symbol-alt-narrow":"\xa3"}},defaultNumberingSystem:"latn",minimumGroupingDigits:"1","symbols-numberSystem-latn":{decimal:".",group:",",list:";",percentSign:"%",plusSign:"+",minusSign:"-",exponential:"E",superscriptingExponent:"\xd7",perMille:"\u2030",infinity:"\u221e",nan:"NaN",timeSeparator:":"},"decimalFormats-numberSystem-latn":{standard:"#,##0.###"},"percentFormats-numberSystem-latn":{standard:"#,##0%"},"currencyFormats-numberSystem-latn":{standard:"\xa4#,##0.00",accounting:"\xa4#,##0.00;(\xa4#,##0.00)"},"scientificFormats-numberSystem-latn":{standard:"#E0"}}},n.blazorDefaultObject={numbers:{mapper:{0:"0",1:"1",2:"2",3:"3",4:"4",5:"5",6:"6",7:"7",8:"8",9:"9"},mapperDigits:"0123456789",numberSymbols:{decimal:".",group:",",plusSign:"+",minusSign:"-",percentSign:"%",nan:"NaN",timeSeparator:":",infinity:"\u221e"},timeSeparator:":",currencySymbol:"$",currencypData:{nlead:"$",nend:"",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},percentpData:{nlead:"",nend:"%",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},percentnData:{nlead:"-",nend:"%",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},currencynData:{nlead:"($",nend:")",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},decimalnData:{nlead:"-",nend:"",groupData:{primary:3},maximumFraction:2,minimumFraction:2},decimalpData:{nlead:"",nend:"",groupData:{primary:3},maximumFraction:2,minimumFraction:2}},dates:{dayPeriods:{am:"AM",pm:"PM"},dateSeperator:"/",days:{abbreviated:{sun:"Sun",mon:"Mon",tue:"Tue",wed:"Wed",thu:"Thu",fri:"Fri",sat:"Sat"},short:{sun:"Su",mon:"Mo",tue:"Tu",wed:"We",thu:"Th",fri:"Fr",sat:"Sa"},wide:{sun:"Sunday",mon:"Monday",tue:"Tuesday",wed:"Wednesday",thu:"Thursday",fri:"Friday",sat:"Saturday"}},months:{abbreviated:{1:"Jan",2:"Feb",3:"Mar",4:"Apr",5:"May",6:"Jun",7:"Jul",8:"Aug",9:"Sep",10:"Oct",11:"Nov",12:"Dec"},wide:{1:"January",2:"February",3:"March",4:"April",5:"May",6:"June",7:"July",8:"August",9:"September",10:"October",11:"November",12:"December"}},eras:{1:"AD"}}},n.monthIndex={3:"abbreviated",4:"wide",5:"narrow",1:"abbreviated"},n.month="months",n.days="days",n.patternMatcher={C:"currency",P:"percent",N:"decimal",A:"currency",E:"scientific"},n.getResultantPattern=l,n.getDependables=h,n.getSymbolPattern=c,n.ConvertDateToWeekFormat=d,n.compareBlazorDateFormats=u,n.getProperNumericSkeleton=f,n.getFormatData=p,n.changeCurrencySymbol=g,n.getCurrencySymbol=v,n.customFormat=function y(T,z,U){for(var B={},j=T.split(";"),Q=["pData","nData","zeroData"],oe=0;oe1,fe.nData=ce()?Y(De.type+"nData",oe):p(ot[1]||"-"+ot[0],!0,Ie),fe.pData=ce()?Y(De.type+"pData",oe):p(ot[0],!1,Ie),!Me[2]&&!z.minimumFractionDigits&&!z.maximumFractionDigits&&(ue=p(Ve.split(";")[0],!0,"",!0).minimumFraction)}if(n.formatRegex.test(z.format)||!z.format){if(ze(Q,f(z.format||"N")),Q.custom=!1,$e="###0",(Q.fractionDigits||z.minimumFractionDigits||z.maximumFractionDigits||ue)&&(Q.fractionDigits&&(z.minimumFractionDigits=z.maximumFractionDigits=Q.fractionDigits),$e=A($e,ue||Q.fractionDigits||z.minimumFractionDigits||0,z.maximumFractionDigits||0)),z.minimumIntegerDigits&&($e=x($e,z.minimumIntegerDigits)),z.useGrouping&&($e=P($e)),"currency"===Q.type||Q.type&&ce()){ce()&&"currency"!==Q.type&&(fe.pData=Y(Q.type+"pData",oe),fe.nData=Y(Q.type+"nData",oe));var hr=$e;$e=fe.pData.nlead+hr+fe.pData.nend,(fe.hasNegativePattern||ce())&&($e+=";"+fe.nData.nlead+hr+fe.nData.nend)}"percent"===Q.type&&!ce()&&($e+=" %")}else $e=z.format.replace(/'/g,'"');return Object.keys(xe).length>0&&($e=B?$e:C($e,xe)),$e},n.fractionDigitsPattern=A,n.minimumIntegerPattern=x,n.groupingPattern=P,n.getWeekData=function L(T,z){var U="sun",B=Y("supplemental.weekData.firstDay",z),j=T;return/en-/.test(j)&&(j=j.slice(3)),j=j.slice(0,2).toUpperCase()+j.substr(2),B&&(U=B[""+j]||B[j.slice(0,2)]||"sun"),o[""+U]},n.replaceBlazorCurrency=function O(T,z,U){var B=function f$(n){return Y(n||"",u$)}(U);if(z!==B)for(var j=0,Q=T;j=0?U:U+7;var j=Math.floor((T.getTime()-z.getTime()-6e4*(T.getTimezoneOffset()-z.getTimezoneOffset()))/864e5)+1;if(U<4){if((B=Math.floor((j+U-1)/7)+1)>52){var oe=new Date(T.getFullYear()+1,0,1).getDay();B=(oe=oe>=0?oe:oe+7)<4?1:53}}else B=Math.floor((j+U-1)/7);return B}}(ut||(ut={}));var sf=function(){function n(t,e,i){this.type="GET",this.emitError=!0,"string"==typeof t?(this.url=t,this.type=m(e)?this.type:e.toUpperCase(),this.contentType=i):La(t)&&Object.keys(t).length>0&&kn(this,t),this.contentType=m(this.contentType)?"application/json; charset=utf-8":this.contentType}return n.prototype.send=function(t){var e=this,i={"application/json":"json","multipart/form-data":"formData","application/octet-stream":"blob","application/x-www-form-urlencoded":"formData"};try{m(this.fetchRequest)&&"GET"===this.type?this.fetchRequest=new Request(this.url,{method:this.type}):m(this.fetchRequest)&&(this.data=m(t)?this.data:t,this.fetchRequest=new Request(this.url,{method:this.type,headers:{"Content-Type":this.contentType},body:this.data}));var r={cancel:!1,fetchRequest:this.fetchRequest};return this.triggerEvent(this.beforeSend,r),r.cancel?null:(this.fetchResponse=fetch(this.fetchRequest),this.fetchResponse.then(function(s){if(e.triggerEvent(e.onLoad,s),!s.ok)throw s;for(var o="text",a=0,l=Object.keys(i);a-1},n.getValue=function(t,e){var i=typeof window<"u"?window.browserDetails:{};return typeof navigator<"u"&&"MacIntel"===navigator.platform&&navigator.maxTouchPoints>1&&!0===n.isTouch&&!vC.CHROME.test(navigator.userAgent)&&(i.isIos=!0,i.isDevice=!0,i.isTouch=!0,i.isPointer=!0,i.isPointer="pointerEnabled"in window.navigator),typeof window<"u"&&window.Capacitor&&"ios"===window.Capacitor.getPlatform()&&(i.isPointer=!1),typeof i[""+t]>"u"?i[""+t]=e.test(n.userAgent):i[""+t]},Object.defineProperty(n,"userAgent",{get:function(){return n.uA},set:function(t){n.uA=t,window.browserDetails={}},enumerable:!0,configurable:!0}),Object.defineProperty(n,"info",{get:function(){return st(window.browserDetails.info)?window.browserDetails.info=n.extractBrowserDetail():window.browserDetails.info},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isIE",{get:function(){return n.getValue("isIE",A$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isTouch",{get:function(){return st(window.browserDetails.isTouch)?window.browserDetails.isTouch="ontouchstart"in window.navigator||window&&window.navigator&&window.navigator.maxTouchPoints>0||"ontouchstart"in window:window.browserDetails.isTouch},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isPointer",{get:function(){return st(window.browserDetails.isPointer)?window.browserDetails.isPointer="pointerEnabled"in window.navigator:window.browserDetails.isPointer},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isMSPointer",{get:function(){return st(window.browserDetails.isMSPointer)?window.browserDetails.isMSPointer="msPointerEnabled"in window.navigator:window.browserDetails.isMSPointer},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isDevice",{get:function(){return n.getValue("isDevice",T$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isIos",{get:function(){return n.getValue("isIos",N$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isIos7",{get:function(){return n.getValue("isIos7",O$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isAndroid",{get:function(){return n.getValue("isAndroid",k$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isWebView",{get:function(){return st(window.browserDetails.isWebView)&&(window.browserDetails.isWebView=!(st(window.cordova)&&st(window.PhoneGap)&&st(window.phonegap)&&"object"!==window.forge)),window.browserDetails.isWebView},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isWindows",{get:function(){return n.getValue("isWindows",P$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"touchStartEvent",{get:function(){return st(window.browserDetails.touchStartEvent)?window.browserDetails.touchStartEvent=n.getTouchStartEvent():window.browserDetails.touchStartEvent},enumerable:!0,configurable:!0}),Object.defineProperty(n,"touchMoveEvent",{get:function(){return st(window.browserDetails.touchMoveEvent)?window.browserDetails.touchMoveEvent=n.getTouchMoveEvent():window.browserDetails.touchMoveEvent},enumerable:!0,configurable:!0}),Object.defineProperty(n,"touchEndEvent",{get:function(){return st(window.browserDetails.touchEndEvent)?window.browserDetails.touchEndEvent=n.getTouchEndEvent():window.browserDetails.touchEndEvent},enumerable:!0,configurable:!0}),Object.defineProperty(n,"touchCancelEvent",{get:function(){return st(window.browserDetails.touchCancelEvent)?window.browserDetails.touchCancelEvent=n.getTouchCancelEvent():window.browserDetails.touchCancelEvent},enumerable:!0,configurable:!0}),n.uA=typeof navigator<"u"?navigator.userAgent:"",n}(),E=function(){function n(){}return n.addOrGetEventData=function(t){return"__eventList"in t?t.__eventList.events:(t.__eventList={},t.__eventList.events=[])},n.add=function(t,e,i,r,s){var a,o=n.addOrGetEventData(t);a=s?function l$(n,t){var e;return function(){for(var i=this,r=[],s=0;s"u"||(e.innerHTML=t.innerHTML?t.innerHTML:"",void 0!==t.className&&(e.className=t.className),void 0!==t.id&&(e.id=t.id),void 0!==t.styles&&e.setAttribute("style",t.styles),void 0!==t.attrs&&Fe(e,t.attrs)),e}function V(n,t){for(var e=Vz(t),i=RegExp,r=0,s=n;r0}function gl(n,t,e){for(var i=document.createDocumentFragment(),r=0,s=n;r0;)i.appendChild(n[0]);else for(var r=0,s=n;r-1&&!r[parseInt(s.toString(),10)].match(/\[.*\]/)){var o=r[parseInt(s.toString(),10)].split("#");if(o[1].match(/^\d/)||o[1].match(t)){var a=r[parseInt(s.toString(),10)].split(".");a[0]=a[0].replace(/#/,"[id='")+"']",r[parseInt(s.toString(),10)]=a.join(".")}}e[parseInt(i.toString(),10)]=r.join(" ")}return e.join(",")}return n}function J(n,t){var e=n;if("function"==typeof e.closest)return e.closest(t);for(;e&&1===e.nodeType;){if(mC(e,t))return e;e=e.parentNode}return null}function je(n,t){void 0!==t&&Object.keys(t).forEach(function(e){n.style[""+e]=t[""+e]})}function mC(n,t){var e=n.matches||n.msMatchesSelector||n.webkitMatchesSelector;return e?e.call(n,t):-1!==[].indexOf.call(document.querySelectorAll(t),n)}var H$=new RegExp("]"),dh=function(){function n(t,e){this.isRendered=!1,this.isComplexArraySetter=!1,this.isServerRendered=!1,this.allowServerDataBinding=!0,this.isProtectedOnChange=!0,this.properties={},this.changedProperties={},this.oldProperties={},this.bulkChanges={},this.refreshing=!1,this.ignoreCollectionWatch=!1,this.finalUpdate=function(){},this.childChangedProperties={},this.modelObserver=new Tg(this),st(e)||(this.element="string"==typeof e?document.querySelector(e):e,m(this.element)||(this.isProtectedOnChange=!1,this.addInstance())),st(t)||this.setProperties(t,!0),this.isDestroyed=!1}return n.prototype.setProperties=function(t,e){var i=this.isProtectedOnChange;this.isProtectedOnChange=!!e,kn(this,t),!0!==e?(kn(this.changedProperties,t),this.dataBind()):ce()&&this.isRendered&&this.serverDataBind(t),this.finalUpdate(),this.changedProperties={},this.oldProperties={},this.isProtectedOnChange=i},n.callChildDataBind=function(t,e){for(var r=0,s=Object.keys(t);r=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Hs=function(n){function t(i){var r=n.call(this,i,void 0)||this;return r.easing={ease:"cubic-bezier(0.250, 0.100, 0.250, 1.000)",linear:"cubic-bezier(0.250, 0.250, 0.750, 0.750)",easeIn:"cubic-bezier(0.420, 0.000, 1.000, 1.000)",easeOut:"cubic-bezier(0.000, 0.000, 0.580, 1.000)",easeInOut:"cubic-bezier(0.420, 0.000, 0.580, 1.000)",elasticInOut:"cubic-bezier(0.5,-0.58,0.38,1.81)",elasticIn:"cubic-bezier(0.17,0.67,0.59,1.81)",elasticOut:"cubic-bezier(0.7,-0.75,0.99,1.01)"},r}var e;return X$(t,n),e=t,t.prototype.animate=function(i,r){var s=this.getModel(r=r||{});if("string"==typeof i)for(var a=0,l=Array.prototype.slice.call(we(i,document));a0?r-1:0,i+=e=-1!==e?"-"+e:"-"+r}return this.controlParent!==this.parentObj&&(i=this.parentObj.getParentKey()+"."+this.propName+e),i},n}(),J$=["grid","pivotview","treegrid","spreadsheet","rangeNavigator","DocumentEditor","listbox","inplaceeditor","PdfViewer","richtexteditor","DashboardLayout","chart","stockChart","circulargauge","diagram","heatmap","lineargauge","maps","slider","smithchart","barcode","sparkline","treemap","bulletChart","kanban","daterangepicker","schedule","gantt","signature","query-builder","drop-down-tree","carousel","filemanager","uploader","accordion","tab","treeview"],tR=[115,121,110,99,102,117,115,105,111,110,46,105,115,76,105,99,86,97,108,105,100,97,116,101,100],iR=function(){function n(t){this.isValidated=!1,this.isLicensed=!0,this.version="27",this.platform=/JavaScript|ASPNET|ASPNETCORE|ASPNETMVC|FileFormats|essentialstudio/i,this.errors={noLicense:"This application was built using a trial version of Syncfusion Essential Studio. To remove the license validation message permanently, a valid license key must be included.",trailExpired:"This application was built using a trial version of Syncfusion Essential Studio. To remove the license validation message permanently, a valid license key must be included.",versionMismatched:"The included Syncfusion license key is invalid.",platformMismatched:"The included Syncfusion license key is invalid.",invalidKey:"The included Syncfusion license key is invalid."},this.manager=function(){var e=null;return{setKey:function i(s){e=s},getKey:function r(){return e}}}(),this.npxManager=function(){return{getKey:function i(){return"npxKeyReplace"}}}(),this.manager.setKey(t)}return n.prototype.validate=function(){if(!this.isValidated&&rf&&!Y(T0(tR),rf)&&!Y("Blazor",rf)){var i=void 0,r=void 0;if(this.manager&&this.manager.getKey()||this.npxManager&&"npxKeyReplace"!==this.npxManager.getKey()){var s=this.getInfoFromKey();if(s&&s.length)for(var o=0,a=s;o"+i+' Claim your FREE account\n
have a Syncfusion account? Sign In
\n
\n ';if(typeof document<"u"&&!m(document)){var t=Si("div",{innerHTML:n});document.body.appendChild(t)}}(),oR=!0),this.render(),this.mount?this.accessMount():this.trigger("created")}},t.prototype.renderComplete=function(e){ce()&&window.sfBlazor.renderComplete(this.element,e),this.isRendered=!0},t.prototype.dataBind=function(){this.injectModules(),n.prototype.dataBind.call(this)},t.prototype.on=function(e,i,r){if("string"==typeof e)this.localObserver.on(e,i,r);else for(var s=0,o=e;s=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},rZ={left:0,top:0,bottom:0,right:0},MC={isDragged:!1},nZ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return aR(t,n),gr([I(0)],t.prototype,"left",void 0),gr([I(0)],t.prototype,"top",void 0),t}(Ee),lf=function(n){function t(i,r){var s=n.call(this,r,i)||this;return s.dragLimit=e.getDefaultPosition(),s.borderWidth=e.getDefaultPosition(),s.padding=e.getDefaultPosition(),s.diffX=0,s.prevLeft=0,s.prevTop=0,s.dragProcessStarted=!1,s.eleTop=0,s.tapHoldTimer=0,s.externalInitialize=!1,s.diffY=0,s.parentScrollX=0,s.parentScrollY=0,s.droppables={},s.bind(),s}var e;return aR(t,n),e=t,t.prototype.bind=function(){this.toggleEvents(),X.isIE&&V([this.element],"e-block-touch"),this.droppables[this.scope]={}},t.getDefaultPosition=function(){return ze({},rZ)},t.prototype.toggleEvents=function(i){var r;st(this.handle)||(r=_(this.handle,this.element));var s=this.enableTapHold&&X.isDevice&&X.isTouch?this.mobileInitialize:this.initialize;i?E.remove(r||this.element,X.isSafari()?"touchstart":X.touchStartEvent,s):E.add(r||this.element,X.isSafari()?"touchstart":X.touchStartEvent,s,this)},t.prototype.mobileInitialize=function(i){var r=this,s=i.currentTarget;this.tapHoldTimer=setTimeout(function(){r.externalInitialize=!0,r.removeTapholdTimer(),r.initialize(i,s)},this.tapHoldThreshold),E.add(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.removeTapholdTimer,this),E.add(document,X.isSafari()?"touchend":X.touchEndEvent,this.removeTapholdTimer,this)},t.prototype.removeTapholdTimer=function(){clearTimeout(this.tapHoldTimer),E.remove(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.removeTapholdTimer),E.remove(document,X.isSafari()?"touchend":X.touchEndEvent,this.removeTapholdTimer)},t.prototype.getScrollableParent=function(i,r){return m(i)?null:i[{vertical:"scrollHeight",horizontal:"scrollWidth"}[""+r]]>i[{vertical:"clientHeight",horizontal:"clientWidth"}[""+r]]&&("vertical"===r?i.scrollTop>0:i.scrollLeft>0)?("vertical"===r?(this.parentScrollY=this.parentScrollY+(0===this.parentScrollY?i.scrollTop:i.scrollTop-this.parentScrollY),this.tempScrollHeight=i.scrollHeight):(this.parentScrollX=this.parentScrollX+(0===this.parentScrollX?i.scrollLeft:i.scrollLeft-this.parentScrollX),this.tempScrollWidth=i.scrollWidth),m(i)?i:this.getScrollableParent(i.parentNode,r)):this.getScrollableParent(i.parentNode,r)},t.prototype.getScrollableValues=function(){this.parentScrollX=0,this.parentScrollY=0,this.element.classList.contains("e-dialog")&&this.element.classList.contains("e-dlg-modal"),this.getScrollableParent(this.element.parentNode,"vertical"),this.getScrollableParent(this.element.parentNode,"horizontal")},t.prototype.initialize=function(i,r){if(this.currentStateTarget=i.target,!this.isDragStarted()){if(this.isDragStarted(!0),this.externalInitialize=!1,this.target=i.currentTarget||r,this.dragProcessStarted=!1,this.abort){var s=this.abort;"string"==typeof s&&(s=[s]);for(var o=0;o=this.distance||this.externalInitialize){var f=this.getHelperElement(i);if(!f||m(f))return;r&&i.preventDefault();var p=this.helperElement=f;if(this.parentClientRect=this.calculateParentPosition(p.offsetParent),this.dragStart){var v={event:i,element:l,target:this.getProperTargetElement(i),bindEvents:ce()?this.bindDragEvents.bind(this):null,dragElement:p};this.trigger("dragStart",v)}this.dragArea?this.setDragArea():(this.dragLimit={left:0,right:0,bottom:0,top:0},this.borderWidth={top:0,left:0}),o={left:this.position.left-this.parentClientRect.left,top:this.position.top-this.parentClientRect.top},this.clone&&!this.enableTailMode&&(this.diffX=this.position.left-this.offset.left,this.diffY=this.position.top-this.offset.top),this.getScrollableValues();var y=getComputedStyle(l),S=parseFloat(y.marginTop);this.clone&&0!==S&&(o.top+=S),this.eleTop=isNaN(parseFloat(y.top))?0:parseFloat(y.top)-this.offset.top,this.enableScrollHandler&&!this.clone&&(o.top-=this.parentScrollY,o.left-=this.parentScrollX);var b=this.getProcessedPositionValue({top:o.top-this.diffY+"px",left:o.left-this.diffX+"px"});this.dragArea&&"string"!=typeof this.dragArea&&this.dragArea.classList.contains("e-kanban-content")&&"relative"===this.dragArea.style.position&&(o.top+=this.dragArea.scrollTop),this.dragElePosition={top:o.top,left:o.left},je(p,this.getDragPosition({position:"absolute",left:b.left,top:b.top})),E.remove(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.intDragStart),E.remove(document,X.isSafari()?"touchend":X.touchEndEvent,this.intDestroy),ce()||this.bindDragEvents(p)}}},t.prototype.bindDragEvents=function(i){Tr(i)?(E.add(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.intDrag,this),E.add(document,X.isSafari()?"touchend":X.touchEndEvent,this.intDragStop,this),this.setGlobalDroppables(!1,this.element,i)):(this.toggleEvents(),document.body.classList.remove("e-prevent-select"))},t.prototype.elementInViewport=function(i){for(this.top=i.offsetTop,this.left=i.offsetLeft,this.width=i.offsetWidth,this.height=i.offsetHeight;i.offsetParent;)this.top+=(i=i.offsetParent).offsetTop,this.left+=i.offsetLeft;return this.top>=window.pageYOffset&&this.left>=window.pageXOffset&&this.top+this.height<=window.pageYOffset+window.innerHeight&&this.left+this.width<=window.pageXOffset+window.innerWidth},t.prototype.getProcessedPositionValue=function(i){return this.queryPositionInfo?this.queryPositionInfo(i):i},t.prototype.calculateParentPosition=function(i){if(m(i))return{left:0,top:0};var r=i.getBoundingClientRect(),s=getComputedStyle(i);return{left:r.left+window.pageXOffset-parseInt(s.marginLeft,10),top:r.top+window.pageYOffset-parseInt(s.marginTop,10)}},t.prototype.intDrag=function(i){if(st(i.changedTouches)||1===i.changedTouches.length){var r,s;this.clone&&i.changedTouches&&X.isDevice&&X.isTouch&&i.preventDefault(),this.position=this.getMousePosition(i,this.isDragScroll);var o=this.getDocumentWidthHeight("Height");oy&&y>0?this.dragLimit.left:this.dragLimit.right+window.pageXOffset0?y-(y-this.dragLimit.right)+window.pageXOffset-M:y<0?this.dragLimit.left:y}if(this.pageY!==v||this.skipDistanceCheck){var w=d.offsetHeight+(parseFloat(b.marginTop)+parseFloat(b.marginBottom));s=this.dragLimit.top>S&&S>0?this.dragLimit.top:this.dragLimit.bottom+window.pageYOffset0?S-(S-this.dragLimit.bottom)+window.pageYOffset-w:S<0?this.dragLimit.top:S}}else r=y,s=S;var A,x,C=f+this.borderWidth.top,D=u+this.borderWidth.left;if(this.dragProcessStarted&&(m(s)&&(s=this.prevTop),m(r)&&(r=this.prevLeft)),this.helperElement.classList.contains("e-treeview"))this.dragArea?(this.dragLimit.top=this.clone?this.dragLimit.top:0,A=s-C<0?this.dragLimit.top:s-this.borderWidth.top,x=r-D<0?this.dragLimit.left:r-this.borderWidth.left):(A=s-this.borderWidth.top,x=r-this.borderWidth.left);else if(this.dragArea){var P=this.helperElement.classList.contains("e-dialog");this.dragLimit.top=this.clone?this.dragLimit.top:0,A=s-C<0?this.dragLimit.top:s-C,x=r-D<0?P?r-(D-this.borderWidth.left):this.dragElePosition.left:r-D}else A=s-C,x=r-D;var L=parseFloat(getComputedStyle(this.element).marginTop);if(L>0&&(this.clone&&(A+=L,S<0&&(L+S>=0?A=L+S:A-=L),this.dragArea&&(A=this.dragLimit.bottom=0){var O=this.dragLimit.top+S-C;O+L+C<0?A-=L+C:A=O}else A-=L+C;this.dragArea&&this.helperElement.classList.contains("e-treeview")&&(A=A+(w=d.offsetHeight+(parseFloat(b.marginTop)+parseFloat(b.marginBottom)))>this.dragLimit.bottom?this.dragLimit.bottom-w:A),this.enableScrollHandler&&!this.clone&&(A-=this.parentScrollY,x-=this.parentScrollX),this.dragArea&&"string"!=typeof this.dragArea&&this.dragArea.classList.contains("e-kanban-content")&&"relative"===this.dragArea.style.position&&(A+=this.dragArea.scrollTop);var N=this.getProcessedPositionValue({top:A+"px",left:x+"px"});this.isPreventScroll&&(N=this.getProcessedPositionValue({top:this.position.top-this.parentClientRect.top-2+"px",left:this.position.left-this.parentClientRect.left-2+"px"})),je(d,this.getDragPosition(N)),!this.elementInViewport(d)&&this.enableAutoScroll&&!this.helperElement.classList.contains("e-treeview")&&this.helperElement.scrollIntoView();var T=document.querySelectorAll(":hover");if(this.enableAutoScroll&&this.helperElement.classList.contains("e-treeview")){0===T.length&&(T=this.getPathElements(i));var z=this.getScrollParent(T,!1);this.elementInViewport(this.helperElement)?this.getScrollPosition(z,A):this.elementInViewport(this.helperElement)||(0===(T=[].slice.call(document.querySelectorAll(":hover"))).length&&(T=this.getPathElements(i)),z=this.getScrollParent(T,!0),this.getScrollPosition(z,A))}this.dragProcessStarted=!0,this.prevLeft=r,this.prevTop=s,this.position.left=r,this.position.top=s,this.pageX=g,this.pageY=v}},t.prototype.getScrollParent=function(i,r){for(var o,s=r?i.reverse():i,a=s.length-1;a>=0;a--)if(("auto"===(o=window.getComputedStyle(s[parseInt(a.toString(),10)])["overflow-y"])||"scroll"===o)&&s[parseInt(a.toString(),10)].scrollHeight>s[parseInt(a.toString(),10)].clientHeight)return s[parseInt(a.toString(),10)];if("visible"===(o=window.getComputedStyle(document.scrollingElement)["overflow-y"]))return document.scrollingElement.style.overflow="auto",document.scrollingElement},t.prototype.getScrollPosition=function(i,r){if(i&&i===document.scrollingElement)i.clientHeight+document.scrollingElement.scrollTop-this.helperElement.clientHeightr?i.scrollTop+=this.helperElement.clientHeight:i.scrollTop>r-this.helperElement.clientHeight&&(i.scrollTop-=this.helperElement.clientHeight);else if(i&&i!==document.scrollingElement){var s=document.scrollingElement.scrollTop,o=this.helperElement.clientHeight;i.clientHeight+i.getBoundingClientRect().top-o+sr-o-s&&(i.scrollTop-=this.helperElement.clientHeight)}},t.prototype.getPathElements=function(i){return document.elementsFromPoint(i.clientX>0?i.clientX:0,i.clientY>0?i.clientY:0)},t.prototype.triggerOutFunction=function(i,r){this.hoverObject.instance.intOut(i,r.target),this.hoverObject.instance.dragData[this.scope]=null,this.hoverObject=null},t.prototype.getDragPosition=function(i){var r=ze({},i);return this.axis&&("x"===this.axis?delete r.top:"y"===this.axis&&delete r.left),r},t.prototype.getDocumentWidthHeight=function(i){var r=document.body,s=document.documentElement;return Math.max(r["scroll"+i],s["scroll"+i],r["offset"+i],s["offset"+i],s["client"+i])},t.prototype.intDragStop=function(i){if(this.dragProcessStarted=!1,st(i.changedTouches)||1===i.changedTouches.length){if(-1!==["touchend","pointerup","mouseup"].indexOf(i.type)){if(this.dragStop){var s=this.getProperTargetElement(i);this.trigger("dragStop",{event:i,element:this.element,target:s,helper:this.helperElement})}this.intDestroy(i)}else this.element.setAttribute("aria-grabbed","false");var o=this.checkTargetElement(i);o.target&&o.instance&&(o.instance.dragStopCalled=!0,o.instance.dragData[this.scope]=this.droppables[this.scope],o.instance.intDrop(i,o.target)),this.setGlobalDroppables(!0),document.body.classList.remove("e-prevent-select")}},t.prototype.intDestroy=function(i){this.dragProcessStarted=!1,this.toggleEvents(),document.body.classList.remove("e-prevent-select"),this.element.setAttribute("aria-grabbed","false"),E.remove(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.intDragStart),E.remove(document,X.isSafari()?"touchend":X.touchEndEvent,this.intDragStop),E.remove(document,X.isSafari()?"touchend":X.touchEndEvent,this.intDestroy),E.remove(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.intDrag),this.isDragStarted()&&this.isDragStarted(!0)},t.prototype.onPropertyChanged=function(i,r){},t.prototype.getModuleName=function(){return"draggable"},t.prototype.isDragStarted=function(i){return i&&(MC.isDragged=!MC.isDragged),MC.isDragged},t.prototype.setDragArea=function(){var i,r,a,s=0,o=0;if(a="string"==typeof this.dragArea?_(this.dragArea):this.dragArea){var h=a.getBoundingClientRect();i=a.scrollWidth?a.scrollWidth:h.right-h.left,r=a.scrollHeight?this.dragArea&&!m(this.helperElement)&&this.helperElement.classList.contains("e-treeview")?a.clientHeight:a.scrollHeight:h.bottom-h.top;for(var c=["Top","Left","Bottom","Right"],d=getComputedStyle(a),u=0;u12;return C0(i.target,this.helperElement)||-1!==i.type.indexOf("touch")||a?(this.helperElement.style.pointerEvents="none",s=document.elementFromPoint(r.clientX,r.clientY),this.helperElement.style.pointerEvents=o):s=i.target,s},t.prototype.currentStateCheck=function(i,r){return m(this.currentStateTarget)||this.currentStateTarget===i?m(r)?i:r:this.currentStateTarget},t.prototype.getMousePosition=function(i,r){var a,l,s=void 0!==i.srcElement?i.srcElement:i.target,o=this.getCoordinates(i),h=m(s.offsetParent);if(r?(a=this.clone?o.pageX:o.pageX+(h?0:s.offsetParent.scrollLeft)-this.relativeXPosition,l=this.clone?o.pageY:o.pageY+(h?0:s.offsetParent.scrollTop)-this.relativeYPosition):(a=this.clone?o.pageX:o.pageX+window.pageXOffset-this.relativeXPosition,l=this.clone?o.pageY:o.pageY+window.pageYOffset-this.relativeYPosition),document.scrollingElement&&!r&&!this.clone){var c=document.scrollingElement;a=c.scrollWidth>0&&c.scrollWidth>c.clientWidth&&c.scrollLeft>0?a-c.scrollLeft:a,l=c.scrollHeight>0&&c.scrollHeight>c.clientHeight&&c.scrollTop>0?l-c.scrollTop:l}return{left:a-(this.margin.left+this.cursorAt.left),top:l-(this.margin.top+this.cursorAt.top)}},t.prototype.getCoordinates=function(i){return i.type.indexOf("touch")>-1?i.changedTouches[0]:i},t.prototype.getHelperElement=function(i){var r;return this.clone?this.helper?r=this.helper({sender:i,element:this.target}):(r=Si("div",{className:"e-drag-helper e-block-touch",innerHTML:"Draggable"}),document.body.appendChild(r)):r=this.element,r},t.prototype.setGlobalDroppables=function(i,r,s){this.droppables[this.scope]=i?null:{draggable:r,helper:s,draggedElement:this.element}},t.prototype.checkTargetElement=function(i){var r=this.getProperTargetElement(i),s=this.getDropInstance(r);if(!s&&r&&!m(r.parentNode)){var o=J(r.parentNode,".e-droppable")||r.parentElement;o&&(s=this.getDropInstance(o))}return{target:r,instance:s}},t.prototype.getDropInstance=function(i){var s,o=i&&i.ej2_instances;if(o)for(var a=0,l=o;a=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},lR=function(n){function t(e,i){var r=n.call(this,i,e)||this;return r.mouseOver=!1,r.dragData={},r.dragStopCalled=!1,r.bind(),r}return sZ(t,n),t.prototype.bind=function(){this.wireEvents()},t.prototype.wireEvents=function(){E.add(this.element,X.isSafari()?"touchend":X.touchEndEvent,this.intDrop,this)},t.prototype.onPropertyChanged=function(e,i){},t.prototype.getModuleName=function(){return"droppable"},t.prototype.intOver=function(e,i){this.mouseOver||(this.trigger("over",{event:e,target:i,dragData:this.dragData[this.scope]}),this.mouseOver=!0)},t.prototype.intOut=function(e,i){this.mouseOver&&(this.trigger("out",{evt:e,target:i}),this.mouseOver=!1)},t.prototype.intDrop=function(e,i){if(this.dragStopCalled){this.dragStopCalled=!1;var a,r=!0,s=this.dragData[this.scope],o=!!s&&s.helper&&Tr(s.helper);o&&(a=this.isDropArea(e,s.helper,i),this.accept&&(r=mC(s.helper,this.accept))),o&&this.drop&&a.canDrop&&r&&this.trigger("drop",{event:e,target:a.target,droppedElement:s.helper,dragData:s}),this.mouseOver=!1}},t.prototype.isDropArea=function(e,i,r){var s={canDrop:!0,target:r||e.target},o="touchend"===e.type;if(o||s.target===i){i.style.display="none";var a=o?e.changedTouches[0]:e,l=document.elementFromPoint(a.clientX,a.clientY);s.canDrop=!1,s.canDrop=C0(l,this.element),s.canDrop&&(s.target=l),i.style.display=""}return s},t.prototype.destroy=function(){E.remove(this.element,X.isSafari()?"touchend":X.touchEndEvent,this.intDrop),n.prototype.destroy.call(this)},hf([I()],t.prototype,"accept",void 0),hf([I("default")],t.prototype,"scope",void 0),hf([H()],t.prototype,"drop",void 0),hf([H()],t.prototype,"over",void 0),hf([H()],t.prototype,"out",void 0),hf([Ft],t)}(dh),uo=function(){function n(t,e,i){this.controlName=t,this.localeStrings=e,this.setLocale(i||"en-US")}return n.prototype.setLocale=function(t){var e=this.intGetControlConstant(n.locale,t);this.currentLocale=e||this.localeStrings},n.load=function(t){this.locale=ze(this.locale,t,{},!0)},n.prototype.getConstant=function(t){return m(this.currentLocale[""+t])?this.localeStrings[""+t]||"":this.currentLocale[""+t]},n.prototype.intGetControlConstant=function(t,e){return t[""+e]?t[""+e][this.controlName]:null},n.locale={},n}(),hR=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),fh=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},lZ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return hR(t,n),fh([I(50)],t.prototype,"swipeThresholdDistance",void 0),t}(Ee),hZ=/(Up|Down)/,Fs=function(n){function t(e,i){var r=n.call(this,i,e)||this;return r.touchAction=!0,r.tapCount=0,r.startEvent=function(s){if(!0===r.touchAction){var o=r.updateChangeTouches(s);void 0!==s.changedTouches&&(r.touchAction=!1),r.isTouchMoved=!1,r.movedDirection="",r.startPoint=r.lastMovedPoint={clientX:o.clientX,clientY:o.clientY},r.startEventData=o,r.hScrollLocked=r.vScrollLocked=!1,r.tStampStart=Date.now(),r.timeOutTapHold=setTimeout(function(){r.tapHoldEvent(s)},r.tapHoldThreshold),E.add(r.element,X.touchMoveEvent,r.moveEvent,r),E.add(r.element,X.touchEndEvent,r.endEvent,r),E.add(r.element,X.touchCancelEvent,r.cancelEvent,r)}},r.moveEvent=function(s){var o=r.updateChangeTouches(s);r.movedPoint=o,r.isTouchMoved=!(o.clientX===r.startPoint.clientX&&o.clientY===r.startPoint.clientY);var a={};r.isTouchMoved&&(clearTimeout(r.timeOutTapHold),r.calcScrollPoints(s),a=ze(a,{},{startEvents:r.startEventData,originalEvent:s,startX:r.startPoint.clientX,startY:r.startPoint.clientY,distanceX:r.distanceX,distanceY:r.distanceY,scrollDirection:r.scrollDirection,velocity:r.getVelocity(o)}),r.trigger("scroll",a),r.lastMovedPoint={clientX:o.clientX,clientY:o.clientY})},r.cancelEvent=function(s){clearTimeout(r.timeOutTapHold),clearTimeout(r.timeOutTap),r.tapCount=0,r.swipeFn(s),E.remove(r.element,X.touchCancelEvent,r.cancelEvent)},r.endEvent=function(s){r.swipeFn(s),r.isTouchMoved||"function"==typeof r.tap&&(r.trigger("tap",{originalEvent:s,tapCount:++r.tapCount}),r.timeOutTap=setTimeout(function(){r.tapCount=0},r.tapThreshold)),r.modeclear()},r.swipeFn=function(s){clearTimeout(r.timeOutTapHold),clearTimeout(r.timeOutTap);var o=r.updateChangeTouches(s),a=o.clientX-r.startPoint.clientX,l=o.clientY-r.startPoint.clientY;a=Math.floor(a<0?-1*a:a),l=Math.floor(l<0?-1*l:a),r.isTouchMoved=a>1||l>1,/Firefox/.test(X.userAgent)&&0===o.clientX&&0===o.clientY&&"mouseup"===s.type&&(r.isTouchMoved=!1),r.endPoint=o,r.calcPoints(s);var c={originalEvent:s,startEvents:r.startEventData,startX:r.startPoint.clientX,startY:r.startPoint.clientY,distanceX:r.distanceX,distanceY:r.distanceY,swipeDirection:r.movedDirection,velocity:r.getVelocity(o)};if(r.isTouchMoved){var d=r.swipeSettings.swipeThresholdDistance,u=ze(void 0,r.defaultArgs,c),f=!1,p=r.element,g=r.isScrollable(p),v=hZ.test(r.movedDirection);(dthis.distanceY?i.clientX>this.startPoint.clientX?"Right":"Left":i.clientYthis.distanceY||!0===this.hScrollLocked)&&!1===this.vScrollLocked?(this.scrollDirection=i.clientX>this.lastMovedPoint.clientX?"Right":"Left",this.hScrollLocked=!0):(this.scrollDirection=i.clientY=e[r[0]+s[0]]},t.prototype.updateChangeTouches=function(e){return e.changedTouches&&0!==e.changedTouches.length?e.changedTouches[0]:e},fh([H()],t.prototype,"tap",void 0),fh([H()],t.prototype,"tapHold",void 0),fh([H()],t.prototype,"swipe",void 0),fh([H()],t.prototype,"scroll",void 0),fh([I(350)],t.prototype,"tapThreshold",void 0),fh([I(750)],t.prototype,"tapHoldThreshold",void 0),fh([re({},lZ)],t.prototype,"swipeSettings",void 0),fh([Ft],t)}(dh),cZ=new RegExp("\\n|\\r|\\s\\s+","g"),dZ=new RegExp(/'|"/g),uZ=new RegExp("if ?\\("),fZ=new RegExp("else if ?\\("),cR=new RegExp("else"),pZ=new RegExp("for ?\\("),dR=new RegExp("(/if|/for)"),gZ=new RegExp("\\((.*)\\)",""),wC=new RegExp("^[0-9]+$","g"),vZ=new RegExp("[\\w\"'.\\s+]+","g"),mZ=new RegExp('"(.*?)"',"g"),yZ=new RegExp("[\\w\"'@#$.\\s-+]+","g"),uR=new RegExp("\\${([^}]*)}","g"),SZ=/^\..*/gm,CC=/\\/gi,IZ=/\\\\/gi,bZ=new RegExp("[\\w\"'@#$.\\s+]+","g"),MZ=/\window\./gm;function cf(n,t,e,i,r){return!t||wC.test(n)||-1!==i.indexOf(n.split(".")[0])||r||"true"===n||"false"===n?n:e+"."+n}function EC(n,t,e,i){return t&&!wC.test(n)&&-1===i.indexOf(n.split(".")[0])?e+'["'+n:n}function fR(n){return n.match(IZ)?n:n.replace(CC,"\\\\")}function pR(n,t,e,i){if(n=n.trim(),/\window\./gm.test(n))return n;var s=/'|"/gm;return/@|\$|#/gm.test(n)&&(n=EC(n,-1===e.indexOf(n),t,e)+'"]'),SZ.test(n)?function EZ(n,t,e,i){return!t||wC.test(n)||-1!==i.indexOf(n.split(".")[0])||/^\..*/gm.test(n)?n:e+"."+n}(n,!s.test(n)&&-1===e.indexOf(n),t,e):cf(n,!s.test(n)&&-1===e.indexOf(n),t,e,i)}var DZ=/^[\n\r.]+0&&t.forEach(function(e){he(e)})},n.removeJsEvents=function(){var t=this.wrapElement.querySelectorAll("["+vR.join("],[")+"]");t.length>0&&t.forEach(function(e){vR.forEach(function(i){e.hasAttribute(i)&&e.removeAttribute(i)})})},n.removeXssAttrs=function(){var t=this;this.removeAttrs.forEach(function(e,i){var r=t.wrapElement.querySelectorAll(e.selector);r.length>0&&r.forEach("a[href]"===e.selector?function(s){-1!==s.getAttribute(e.attribute).replace(/\t|\s|&/,"").indexOf("javascript:alert")&&s.removeAttribute(e.attribute)}:function(s){s.removeAttribute(e.attribute)})})},n}();function kZ(n){for(var t,e=n.childNodes,i=0;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Jo_RTL=(new Tg,"e-rtl"),ys=function(n){function t(e,i){return n.call(this,e,i)||this}return RZ(t,n),t.prototype.preRender=function(){},t.prototype.render=function(){this.initialize(),this.removeRippleEffect=function ms(n,t,e){var i=function q$(n){return{selector:n&&n.selector?n.selector:null,ignore:n&&n.ignore?n.ignore:null,rippleFlag:n&&n.rippleFlag,isCenterRipple:n&&n.isCenterRipple,duration:n&&n.duration?n.duration:350}}(t);return!1===i.rippleFlag||void 0===i.rippleFlag&&!Zo?function(){}:(n.setAttribute("data-ripple","true"),E.add(n,"mousedown",Zz,{parent:n,rippleOptions:i}),E.add(n,"mouseup",Jz,{parent:n,rippleOptions:i,done:e}),E.add(n,"mouseleave",af,{parent:n,rippleOptions:i}),X.isPointer&&E.add(n,"transitionend",af,{parent:n,rippleOptions:i}),function(){n.removeAttribute("data-ripple"),E.remove(n,"mousedown",Zz),E.remove(n,"mouseup",Jz),E.remove(n,"mouseleave",af),E.remove(n,"transitionend",af)})}(this.element,{selector:".e-btn"}),this.renderComplete()},t.prototype.initialize=function(){if(this.cssClass&&V([this.element],this.cssClass.replace(/\s+/g," ").trim().split(" ")),this.isPrimary&&this.element.classList.add("e-primary"),!ce()||ce()&&"progress-btn"!==this.getModuleName()){if(this.content){var e=this.enableHtmlSanitizer?Ai.sanitize(this.content):this.content;this.element.innerHTML=e}this.setIconCss()}this.enableRtl&&this.element.classList.add(Jo_RTL),this.disabled?this.controlStatus(this.disabled):this.wireEvents()},t.prototype.controlStatus=function(e){this.element.disabled=e},t.prototype.setIconCss=function(){if(this.iconCss){var e=this.createElement("span",{className:"e-btn-icon "+this.iconCss});this.element.textContent.trim()?(e.classList.add("e-icon-"+this.iconPosition.toLowerCase()),("Top"===this.iconPosition||"Bottom"===this.iconPosition)&&this.element.classList.add("e-"+this.iconPosition.toLowerCase()+"-icon-btn")):this.element.classList.add("e-icon-btn");var i=this.element.childNodes[0];!i||"Left"!==this.iconPosition&&"Top"!==this.iconPosition?this.element.appendChild(e):this.element.insertBefore(e,i)}},t.prototype.wireEvents=function(){this.isToggle&&E.add(this.element,"click",this.btnClickHandler,this)},t.prototype.unWireEvents=function(){this.isToggle&&E.remove(this.element,"click",this.btnClickHandler)},t.prototype.btnClickHandler=function(){this.element.classList.contains("e-active")?this.element.classList.remove("e-active"):this.element.classList.add("e-active")},t.prototype.destroy=function(){var e=["e-primary",Jo_RTL,"e-icon-btn","e-success","e-info","e-danger","e-warning","e-flat","e-outline","e-small","e-bigger","e-active","e-round","e-top-icon-btn","e-bottom-icon-btn"];this.cssClass&&(e=e.concat(this.cssClass.split(" "))),n.prototype.destroy.call(this),K([this.element],e),this.element.getAttribute("class")||this.element.removeAttribute("class"),this.disabled&&this.element.removeAttribute("disabled"),this.content&&(this.element.innerHTML=this.element.innerHTML.replace(this.content,""));var i=this.element.querySelector("span.e-btn-icon");i&&he(i),this.unWireEvents(),Zo&&this.removeRippleEffect()},t.prototype.getModuleName=function(){return"btn"},t.prototype.getPersistData=function(){return this.addOnPersist([])},t.Inject=function(){},t.prototype.onPropertyChanged=function(e,i){for(var r=this.element.querySelector("span.e-btn-icon"),s=0,o=Object.keys(e);s=ad.width?ad.width:0;return yl.right+QR()-n}function cE(){return F0()+yl.width/2}function dE(n,t,e,i){if(void 0===t&&(t=null),void 0===e&&(e={X:!1,Y:!1}),!e.Y&&!e.X)return{left:0,top:0};var r=n.getBoundingClientRect();if(po=t,oc=n.ownerDocument,i||(i=ns(n,"left","top")),e.X){var s=po?ZR():i4(),o=vE(),a=mE(),l=o-i.left,h=i.left+r.width-a;r.width>s?i.left=l>0&&h<=0?a-r.width:h>0&&l<=0?o:l>h?a-r.width:o:l>0?i.left+=l:h>0&&(i.left-=h)}if(e.Y){var c=po?JR():t4(),d=gE(),u=yE(),f=d-i.top,p=i.top+r.height-u;r.height>c?i.top=f>0&&p<=0?u-r.height:p>0&&f<=0?d:f>p?u-r.height:d:f>0?i.top+=f:p>0&&(i.top-=p)}return i}function ac(n,t,e,i){void 0===t&&(t=null);var r=ns(n,"left","top");e&&(r.left=e),i&&(r.top=i);var s=[];po=t,oc=n.ownerDocument;var o=n.getBoundingClientRect(),l=r.left,h=r.left+o.width,d=pE(r.top,r.top+o.height),u=XR(l,h);return d.topSide&&s.push("top"),u.rightSide&&s.push("right"),u.leftSide&&s.push("left"),d.bottomSide&&s.push("bottom"),s}function uJ(n,t,e,i,r,s,o,a,l){if(void 0===o&&(o=null),void 0===a&&(a={X:!0,Y:!0}),t&&n&&r&&s&&(a.X||a.Y)){var d,h={TL:null,TR:null,BL:null,BR:null},c={TL:null,TR:null,BL:null,BR:null};if("none"===window.getComputedStyle(n).display){var u=n.style.visibility;n.style.visibility="hidden",n.style.display="block",d=n.getBoundingClientRect(),n.style.removeProperty("display"),n.style.visibility=u}else d=n.getBoundingClientRect();var f={posX:r,posY:s,offsetX:e,offsetY:i,position:{left:0,top:0}};po=o,oc=t.ownerDocument,function pJ(n,t,e,i,r){e.position=ns(n,e.posX,e.posY,i,r),t.TL=ns(n,"left","top",i,r),t.TR=ns(n,"right","top",i,r),t.BR=ns(n,"left","bottom",i,r),t.BL=ns(n,"right","bottom",i,r)}(t,h,f,l,d),fE(c,f,d),a.X&&qR(t,c,h,f,d,!0),a.Y&&h.TL.top>-1&&$R(t,c,h,f,d,!0),function fJ(n,t,e){var i=0,r=0;if(null!=n.offsetParent&&("absolute"===getComputedStyle(n.offsetParent).position||"relative"===getComputedStyle(n.offsetParent).position)){var s=ns(n.offsetParent,"left","top",!1,e);i=s.left,r=s.top}var o=1,a=1,l=GR(n);if(l){var h=getComputedStyle(l).transform;if("none"!==h){var c=new DOMMatrix(h);o=c.a,a=c.d}if("none"!==getComputedStyle(l).zoom){var u=uE(document.body);o*=u,a*=u}}n.style.top=t.position.top/a+t.offsetY-r/a+"px",n.style.left=t.position.left/o+t.offsetX-i/o+"px"}(n,f,d)}}function uE(n){var t=getComputedStyle(n).zoom;return parseFloat(t)||1}function GR(n){for(;n;){var t=window.getComputedStyle(n).transform,e=uE(document.body);if(t&&"none"!==t||e&&1!==e)return n;if(n===document.body)return null;n=n.offsetParent||n.parentElement}return null}function fE(n,t,e){n.TL={top:t.position.top+t.offsetY,left:t.position.left+t.offsetX},n.TR={top:n.TL.top,left:n.TL.left+e.width},n.BL={top:n.TL.top+e.height,left:n.TL.left},n.BR={top:n.TL.top+e.height,left:n.TL.left+e.width}}function XR(n,t){var e=!1,i=!1;return n-U0()mE()&&(i=!0),{leftSide:e,rightSide:i}}function qR(n,t,e,i,r,s){var o=XR(t.TL.left,t.TR.left),a=pE(t.TL.top,t.BL.top);e.TL.left-U0()<=vE()&&(o.leftSide=!1),e.TR.left>mE()&&(o.rightSide=!1),(o.leftSide&&!o.rightSide||!o.leftSide&&o.rightSide)&&(i.posX="right"===i.posX?"left":"right",i.offsetX=i.offsetX+r.width,i.offsetX=-1*i.offsetX,i.position=ns(n,i.posX,i.posY,!1),fE(t,i,r),s&&qR(n,t,e,i,r,!1),!o.leftSide&&o.rightSide&&a.bottomSide&&(i.offsetX=0))}function $R(n,t,e,i,r,s){var o=pE(t.TL.top,t.BL.top);e.TL.top-_0()<=gE()&&(o.topSide=!1),e.BL.top>=yE()&&n.getBoundingClientRect().bottomyE()&&(i=!0),{topSide:e,bottomSide:i}}function ZR(){return po.getBoundingClientRect().width}function JR(){return po.getBoundingClientRect().height}function KR(){return po.getBoundingClientRect().left}function e4(){return po.getBoundingClientRect().top}function gE(){return po?e4():0}function vE(){return po?KR():0}function mE(){return po?U0()+KR()+ZR():U0()+i4()}function yE(){return po?_0()+e4()+JR():_0()+t4()}function _0(){return oc.documentElement.scrollTop||oc.body.scrollTop}function U0(){return oc.documentElement.scrollLeft||oc.body.scrollLeft}function t4(){return window.innerHeight}function i4(){var n=window.innerWidth,t=document.documentElement.getBoundingClientRect();return n-(n-(m(document.documentElement)?0:t.width))}function r4(){po=null,oc=null}var n4=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),bn=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},s4=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return n4(t,n),bn([I("left")],t.prototype,"X",void 0),bn([I("top")],t.prototype,"Y",void 0),t}(Ee),qn_OPEN="e-popup-open",qn_CLOSE="e-popup-close",lc=function(n){function t(e,i){return n.call(this,i,e)||this}return n4(t,n),t.prototype.onPropertyChanged=function(e,i){for(var r=0,s=Object.keys(e);r0&&c.left>0&&c.right>0&&c.bottom>0}var s=i.getBoundingClientRect();return!(r.bottoms.bottom||r.right>s.right||r.leftr.top?this.element.style.top="0px":s.bottomr.left&&(this.element.style.left=parseInt(this.element.style.left,10)+(s.left-r.left)+"px"))}},t.prototype.checkCollision=function(){var e=this.collision.X,i=this.collision.Y;"none"===e&&"none"===i||("flip"===e&&"flip"===i?this.callFlip({X:!0,Y:!0}):"fit"===e&&"fit"===i?this.callFit({X:!0,Y:!0}):("flip"===e?this.callFlip({X:!0,Y:!1}):"flip"===i&&this.callFlip({Y:!0,X:!1}),"fit"===e?this.callFit({X:!0,Y:!1}):"fit"===i&&this.callFit({X:!1,Y:!0})))},t.prototype.show=function(e,i){var r=this;if(this.getRelateToElement().classList.contains("e-filemanager")&&(this.fmDialogContainer=this.element.getElementsByClassName("e-file-select-wrap")[0]),this.wireEvents(),!m(this.fmDialogContainer)&&X.isIos&&(this.fmDialogContainer.style.display="block"),1e3===this.zIndex||!m(i)){var o=m(i)?this.element:i;this.zIndex=hc(o),je(this.element,{zIndex:this.zIndex})}e=m(e)||"object"!=typeof e?this.showAnimation:e,("none"!==this.collision.X||"none"!==this.collision.Y)&&(K([this.element],qn_CLOSE),V([this.element],qn_OPEN),this.checkCollision(),K([this.element],qn_OPEN),V([this.element],qn_CLOSE)),m(e)?(K([this.element],qn_CLOSE),V([this.element],qn_OPEN),this.trigger("open")):(e.begin=function(){r.isDestroyed||(K([r.element],qn_CLOSE),V([r.element],qn_OPEN))},e.end=function(){r.isDestroyed||r.trigger("open")},new Hs(e).animate(this.element))},t.prototype.hide=function(e){var i=this;e=m(e)||"object"!=typeof e?this.hideAnimation:e,m(e)?(K([this.element],qn_OPEN),V([this.element],qn_CLOSE),this.trigger("close")):(e.end=function(){i.isDestroyed||(K([i.element],qn_OPEN),V([i.element],qn_CLOSE),i.trigger("close"))},new Hs(e).animate(this.element)),this.unwireEvents()},t.prototype.getScrollableParent=function(e){return this.checkFixedParent(e),function SE(n,t){for(var e=getComputedStyle(n),i=[],r=/(auto|scroll)/,s=n.parentElement;s&&"HTML"!==s.tagName;){var o=getComputedStyle(s);!("absolute"===e.position&&"static"===o.position)&&r.test(o.overflow+o.overflowY+o.overflowX)&&i.push(s),s=s.parentElement}return t||i.push(document),i}(e,this.fixedParent)},t.prototype.checkFixedParent=function(e){for(var i=e.parentElement;i&&"HTML"!==i.tagName;){var r=getComputedStyle(i);("fixed"===r.position||"sticky"===r.position)&&!m(this.element)&&this.element.offsetParent&&"BODY"===this.element.offsetParent.tagName&&"hidden"!==getComputedStyle(this.element.offsetParent).overflow&&(this.element.style.top=window.scrollY>parseInt(this.element.style.top,10)?Re(window.scrollY-parseInt(this.element.style.top,10)):Re(parseInt(this.element.style.top,10)-window.scrollY),this.element.style.position="fixed",this.fixedParent=!0),i=i.parentElement,!m(this.element)&&m(this.element.offsetParent)&&"fixed"===r.position&&"fixed"===this.element.style.position&&(this.fixedParent=!0)}},bn([I("auto")],t.prototype,"height",void 0),bn([I("auto")],t.prototype,"width",void 0),bn([I(null)],t.prototype,"content",void 0),bn([I("container")],t.prototype,"targetType",void 0),bn([I(null)],t.prototype,"viewPortElement",void 0),bn([I({X:"none",Y:"none"})],t.prototype,"collision",void 0),bn([I("")],t.prototype,"relateTo",void 0),bn([re({},s4)],t.prototype,"position",void 0),bn([I(0)],t.prototype,"offsetX",void 0),bn([I(0)],t.prototype,"offsetY",void 0),bn([I(1e3)],t.prototype,"zIndex",void 0),bn([I(!1)],t.prototype,"enableRtl",void 0),bn([I("reposition")],t.prototype,"actionOnScroll",void 0),bn([I(null)],t.prototype,"showAnimation",void 0),bn([I(null)],t.prototype,"hideAnimation",void 0),bn([H()],t.prototype,"open",void 0),bn([H()],t.prototype,"close",void 0),bn([H()],t.prototype,"targetExitViewport",void 0),bn([Ft],t)}(Ii);function hc(n){for(var t=n.parentElement,e=[];t&&"BODY"!==t.tagName;){var i=document.defaultView.getComputedStyle(t,null).getPropertyValue("z-index"),r=document.defaultView.getComputedStyle(t,null).getPropertyValue("position");"auto"!==i&&"static"!==r&&e.push(i),t=t.parentElement}for(var s=[],o=0;o2147483647?2147483647:c}var Ui,ka,df,yh,wE,Sh,$t,Ih,IE=["north-west","north","north-east","west","east","south-west","south","south-east"],jg="e-resize-handle",cc="e-focused-handle",gJ="e-dlg-resizable",o4=["e-restrict-left"],a4="e-resize-viewport",vJ=["north","west","east","south"],bE=0,ME=0,l4=0,h4=0,Vg=0,Wg=0,Yg=null,CE=null,EE=null,j0=!0,c4=0,DE=!0;function yJ(n){xE();var t=Si("span",{attrs:{unselectable:"on",contenteditable:"false"}});t.setAttribute("class","e-dialog-border-resize e-"+n),"south"===n&&(t.style.height="2px",t.style.width="100%",t.style.bottom="0px",t.style.left="0px"),"north"===n&&(t.style.height="2px",t.style.width="100%",t.style.top="0px",t.style.left="0px"),"east"===n&&(t.style.height="100%",t.style.width="2px",t.style.right="0px",t.style.top="0px"),"west"===n&&(t.style.height="100%",t.style.width="2px",t.style.left="0px",t.style.top="0px"),Ui.appendChild(t)}function d4(n){var t;return m(n)||(t="string"==typeof n?document.querySelector(n):n),t}function u4(n){for(var t=n||this,e=Ui.querySelectorAll("."+jg),i=0;i-1?"mouse":"touch"}function p4(n){if(n.preventDefault(),Ui=n.target.parentElement,xE(),Vg=n.pageX,Wg=n.pageY,n.target.classList.add(cc),m(Yg)||!0!==Yg(n,this)){this.targetEle&&Ui&&Ui.querySelector("."+gJ)&&($t="body"===this.target?null:this.targetEle,Sh=this.targetEle.clientWidth,yh=this.targetEle.clientHeight);var e=m($t)?document:$t;E.add(e,"mousemove",Qg,this),E.add(document,"mouseup",V0,this);for(var i=0;i=0||s.top<0)&&(e=!0):e=!0;var a=ME+(r-Wg);a=a>df?a:df;var l=0;m($t)||(l=o.top);var h=m($t)?0:$t.offsetHeight-$t.clientHeight,c=s.top-l-h/2;if(c=c<0?0:c,s.top>0&&c+a>yh){if(e=!1,Ui.classList.contains(a4))return;Ui.style.height=yh-parseInt(c.toString(),10)+"px"}else{var d=0;if(e){s.top<0&&t+(s.height+s.top)>0&&a+(d=s.top)<=30&&(a=s.height-(s.height+s.top)+30),a+s.top>=yh&&(Ui.style.height=s.height+(t-(s.height+s.top))+"px");var u=m($t)?d:c;a>=df&&a+u<=yh&&(Ui.style.height=a+"px")}}}function AE(n){var e,t=!1,i="mouse"===f4(n.type)?n.pageY:n.touches[0].pageY,r=dc(Ui),s=m($t)?0:$t.offsetHeight-$t.clientHeight;m($t)||(e=dc($t)),(!m($t)&&r.top-e.top>0||m($t)&&i>0||!m($t)&&Math.floor(r.top-e.top+r.height+(e.bottom-r.bottom))-s<=yh)&&(t=!0);var o=ME-(i-Wg);if(t&&o>=df&&o<=yh){var a=0;m($t)||(a=e.top);var l=h4-a+(i-Wg);l=l>0?l:1,Ui.style.height=o+"px",Ui.style.top=l+"px"}}function LE(n){var i,t=document.documentElement.clientWidth,e=!1;m($t)||(i=dc($t));var r="mouse"===f4(n.type)?n.pageX:n.touches[0].pageX,s=dc(Ui),o=m($t)?0:$t.offsetWidth-$t.clientWidth,a=m($t)?0:i.left,l=m($t)?0:i.width;m(Ih)&&(m($t)?Ih=t:(Ih=s.left-a-o/2+s.width,Ih+=l-o-Ih)),(!m($t)&&Math.floor(s.left-i.left+s.width+(i.right-s.right))-o<=Sh||m($t)&&r>=0)&&(e=!0);var h=bE-(r-Vg);if(j0&&(h=h>Ih?Ih:h),e&&h>=wE&&h<=Sh){var c=0;m($t)||(c=i.left);var d=l4-c+(r-Vg);d=d>0?d:1,h!==c4&&DE&&(Ui.style.width=h+"px"),j0&&(Ui.style.left=d+"px",DE=1!==d)}c4=h}function NE(n){var i,t=document.documentElement.clientWidth,e=!1;m($t)||(i=dc($t));var s=(n.touches?n.changedTouches[0]:n).pageX,o=dc(Ui);(!m($t)&&(o.left-i.left+o.width<=Sh||o.right-i.left>=o.width)||m($t)&&t-s>0)&&(e=!0);var a=bE+(s-Vg),l=0;if(m($t)||(l=i.left),o.left-l+a>Sh){if(e=!1,Ui.classList.contains(a4))return;Ui.style.width=Sh-(o.left-l)+"px"}e&&a>=wE&&a<=Sh&&(Ui.style.width=a+"px")}function v4(){for(var n=Ui.querySelectorAll("."+jg),t=0;t=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},wJ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return OE(t,n),Zt([I(!0)],t.prototype,"isFlat",void 0),Zt([I()],t.prototype,"buttonModel",void 0),Zt([I("Button")],t.prototype,"type",void 0),Zt([H()],t.prototype,"click",void 0),t}(Ee),CJ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return OE(t,n),Zt([I("Fade")],t.prototype,"effect",void 0),Zt([I(400)],t.prototype,"duration",void 0),Zt([I(0)],t.prototype,"delay",void 0),t}(Ee),W0="e-dialog",kE="e-rtl",PE="e-dlg-header-content",m4="e-dlg-header",Y0="e-footer-content",Q0="e-dlg-modal",y4="e-icon-dlg-close",Pa="e-dlg-target",ea="e-scroll-disabled",S4="e-device",G0="e-dlg-fullscreen",I4="e-dlg-closeicon-btn",b4="e-popup-open",M4="Information",w4="e-scroll-disabled",C4="e-alert-dialog",E4="e-confirm-dialog",zE="e-dlg-resizable",uf="e-restrict-left",D4="e-resize-viewport",RE="user action",HJ=function(n){function t(e,i){var r=n.call(this,e,i)||this;return r.needsID=!0,r}return OE(t,n),t.prototype.render=function(){this.initialize(),this.initRender(),this.wireEvents(),"100%"===this.width&&(this.element.style.width=""),""!==this.minHeight&&(this.element.style.minHeight=Re(this.minHeight)),this.enableResize&&(this.setResize(),this.isModal&&(this.isModelResize=!0),"None"===this.animationSettings.effect&&this.getMinHeight()),this.renderComplete()},t.prototype.initializeValue=function(){this.dlgClosedBy=RE},t.prototype.preRender=function(){var e=this;if(this.initializeValue(),this.headerContent=null,this.allowMaxHeight=!0,this.preventVisibility=!0,this.clonedEle=this.element.cloneNode(!0),this.closeIconClickEventHandler=function(s){e.dlgClosedBy="close icon",e.hide(s)},this.dlgOverlayClickEventHandler=function(s){e.dlgClosedBy="overlayClick",s.preventFocus=!1,e.trigger("overlayClick",s,function(o){o.preventFocus||e.focusContent(),e.dlgClosedBy=RE})},this.l10n=new uo("dialog",{close:"Close"},this.locale),this.checkPositionData(),m(this.target)){var r=this.isProtectedOnChange;this.isProtectedOnChange=!0,this.target=document.body,this.isProtectedOnChange=r}},t.prototype.updatePersistData=function(){this.enablePersistence&&this.setProperties({width:parseFloat(this.element.style.width),height:parseFloat(this.element.style.height),position:{X:parseFloat(this.dragObj.element.style.left),Y:parseFloat(this.dragObj.element.style.top)}},!0)},t.prototype.isNumberValue=function(e){return/^[-+]?\d*\.?\d+$/.test(e)},t.prototype.checkPositionData=function(){if(!m(this.position)){if(!m(this.position.X)&&"number"!=typeof this.position.X&&this.isNumberValue(this.position.X)){var i=this.isProtectedOnChange;this.isProtectedOnChange=!0,this.position.X=parseFloat(this.position.X),this.isProtectedOnChange=i}m(this.position.Y)||"number"==typeof this.position.Y||this.isNumberValue(this.position.Y)&&(i=this.isProtectedOnChange,this.isProtectedOnChange=!0,this.position.Y=parseFloat(this.position.Y),this.isProtectedOnChange=i)}},t.prototype.getEle=function(e,i){for(var r=void 0,s=0;s=0&&t[e])yJ(t[e]);else if(""!==t[e].trim()){var i=Si("div",{className:"e-icons "+jg+" e-"+t[e]});Ui.appendChild(i)}df=n.minHeight,wE=n.minWidth,Sh=n.maxWidth,yh=n.maxHeight,n.proxy&&n.proxy.element&&n.proxy.element.classList.contains("e-dialog")?u4(n.proxy):u4()}({element:this.element,direction:r,minHeight:parseInt(e.slice(0,i.indexOf("p")),10),maxHeight:this.targetEle.clientHeight,minWidth:parseInt(i.slice(0,i.indexOf("p")),10),maxWidth:this.targetEle.clientWidth,boundary:this.target===document.body?null:this.targetEle,resizeBegin:this.onResizeStart.bind(this),resizeComplete:this.onResizeComplete.bind(this),resizing:this.onResizing.bind(this),proxy:this}),this.wireWindowResizeEvent()}else v4(),this.unWireWindowResizeEvent(),this.element.classList.remove(this.isModal?uf:D4),this.element.classList.remove(zE)},t.prototype.getFocusElement=function(e){var r=e.querySelectorAll('input,select,textarea,button:enabled,a,[contenteditable="true"],[tabindex]');return{element:r[r.length-1]}},t.prototype.keyDown=function(e){var i=this;if(9===e.keyCode&&this.isModal){var r=void 0;m(this.btnObj)||(r=this.btnObj[this.btnObj.length-1]),m(this.btnObj)&&!m(this.ftrTemplateContent)&&(r=this.getFocusElement(this.ftrTemplateContent)),m(this.btnObj)&&m(this.ftrTemplateContent)&&!m(this.contentEle)&&(r=this.getFocusElement(this.contentEle)),!m(r)&&document.activeElement===r.element&&!e.shiftKey&&(e.preventDefault(),this.focusableElements(this.element).focus()),document.activeElement===this.focusableElements(this.element)&&e.shiftKey&&(e.preventDefault(),m(r)||r.element.focus())}var h,s=document.activeElement,o=["input","textarea"].indexOf(s.tagName.toLowerCase())>-1,a=!1;if(o||(a=s.hasAttribute("contenteditable")&&"true"===s.getAttribute("contenteditable")),27===e.keyCode&&this.closeOnEscape){this.dlgClosedBy="escape";var l=document.querySelector(".e-popup-open:not(.e-dialog)");!m(l)&&!l.classList.contains("e-toolbar-pop")&&!l.classList.contains("e-slider-tooltip")||this.hide(e)}(13===e.keyCode&&!e.ctrlKey&&"textarea"!==s.tagName.toLowerCase()&&o&&!m(this.primaryButtonEle)||13===e.keyCode&&e.ctrlKey&&("textarea"===s.tagName.toLowerCase()||a)&&!m(this.primaryButtonEle))&&this.buttons.some(function(d,u){h=u;var f=d.buttonModel;return!m(f)&&!0===f.isPrimary})&&"function"==typeof this.buttons[h].click&&setTimeout(function(){i.buttons[h].click.call(i,e)})},t.prototype.initialize=function(){m(this.target)||(this.targetEle="string"==typeof this.target?document.querySelector(this.target):this.target),this.isBlazorServerRender()||V([this.element],W0),X.isDevice&&V([this.element],S4),this.isBlazorServerRender()||this.setCSSClass(),this.setMaxHeight()},t.prototype.initRender=function(){var e=this;if(this.initialRender=!0,this.isBlazorServerRender()||Fe(this.element,{role:"dialog"}),1e3===this.zIndex?(this.setzIndex(this.element,!1),this.calculatezIndex=!0):this.calculatezIndex=!1,this.setTargetContent(),""!==this.header&&!m(this.header)&&this.setHeader(),this.renderCloseIcon(),this.setContent(),""===this.footerTemplate||m(this.footerTemplate)?!m(this.buttons[0])&&!m(this.buttons[0].buttonModel)&&this.setButton():this.setFooterTemplate(),this.allowDragging&&!m(this.headerContent)&&this.setAllowDragging(),Fe(this.element,{"aria-modal":this.isModal?"true":"false"}),this.isModal&&this.setIsModal(),!0!==this.element.classList.contains(C4)&&!0!==this.element.classList.contains(E4)&&!m(this.element.parentElement)){var i=this.isModal?this.dlgContainer.parentElement:this.element.parentElement;this.refElement=this.createElement("div",{className:"e-dlg-ref-element"}),i.insertBefore(this.refElement,this.isModal?this.dlgContainer:this.element)}if(m(this.targetEle)||this.targetEle.appendChild(this.isModal?this.dlgContainer:this.element),this.popupObj=new lc(this.element,{height:this.height,width:this.width,zIndex:this.zIndex,relateTo:this.target,actionOnScroll:"none",enableRtl:this.enableRtl,open:function(o){var a={container:e.isModal?e.dlgContainer:e.element,element:e.element,target:e.target,preventFocus:!1};e.enableResize&&e.resetResizeIcon(),e.trigger("open",a,function(l){l.preventFocus||e.focusContent()})},close:function(o){e.isModal&&V([e.dlgOverlay],"e-fade"),e.unBindEvent(e.element),e.isModal&&(e.dlgContainer.style.display="none"),e.trigger("close",e.closeArgs);var a=document.activeElement;!m(a)&&!m(a.blur)&&a.blur(),!m(e.storeActiveElement)&&!m(e.storeActiveElement.focus)&&e.storeActiveElement.focus()}}),this.positionChange(),this.setEnableRTL(),this.isBlazorServerRender()||(V([this.element],"e-popup-close"),this.isModal&&this.setOverlayZindex()),this.visible){if(this.show(),this.isModal){var r=this.getTargetContainer(this.target);r instanceof Element&&"rtl"===window.getComputedStyle(r).getPropertyValue("direction")&&this.setPopupPosition()}}else this.isModal&&(this.dlgOverlay.style.display="none");this.initialRender=!1},t.prototype.getTargetContainer=function(e){var i=null;if("string"==typeof e)if(e.startsWith("#"))i=document.getElementById(e.substring(1));else if(e.startsWith(".")){var r=document.getElementsByClassName(e.substring(1));i=r.length>0?r[0]:null}else!(e instanceof HTMLElement)&&e!==document.body&&(i=document.querySelector(e));else e instanceof HTMLElement&&(i=e);return i},t.prototype.resetResizeIcon=function(){var e=this.getMinHeight();if(this.targetEle.offsetHeight0&&("function"==typeof this.buttons[e].click&&E.add(s[e],"click",this.buttons[e].click,this),"object"==typeof this.buttons[e].click&&E.add(s[e],"click",this.buttonClickHandler.bind(this,e),this)),!this.isBlazorServerRender()&&!m(this.ftrTemplateContent)&&(this.btnObj[e].appendTo(this.ftrTemplateContent.children[e]),this.buttons[e].isFlat&&this.btnObj[e].element.classList.add("e-flat"),this.primaryButtonEle=this.element.getElementsByClassName("e-primary")[0]))},t.prototype.buttonClickHandler=function(e){this.trigger("buttons["+e+"].click",{})},t.prototype.setContent=function(){this.contentEle=this.createElement("div",{className:"e-dlg-content",id:this.element.id+"_dialog-content"}),Fe(this.element,this.headerEle?{"aria-describedby":this.element.id+"_title "+this.element.id+"_dialog-content"}:{"aria-describedby":this.element.id+"_dialog-content"}),this.innerContentElement?this.contentEle.appendChild(this.innerContentElement):(!m(this.content)&&""!==this.content||!this.initialRender)&&(("string"!=typeof this.content||ce())&&this.content instanceof HTMLElement?this.contentEle.appendChild(this.content):this.setTemplate(this.content,this.contentEle,"content")),m(this.headerContent)?this.element.insertBefore(this.contentEle,this.element.children[0]):this.element.insertBefore(this.contentEle,this.element.children[1]),"auto"===this.height&&(!this.isBlazorServerRender()&&X.isIE&&""===this.element.style.width&&!m(this.width)&&(this.element.style.width=Re(this.width)),this.setMaxHeight())},t.prototype.setTemplate=function(e,i,r){var s,o,a;o=i.classList.contains(m4)?this.element.id+"header":i.classList.contains(Y0)?this.element.id+"footerTemplate":this.element.id+"content",m(e.outerHTML)?("string"==typeof e||"string"!=typeof e||ce()&&!this.isStringTemplate)&&("string"==typeof e&&(e=this.sanitizeHelper(e)),this.isVue||"string"!=typeof e?(s=oi(e),a=e):i.innerHTML=e):i.appendChild(e);var l=[];if(!m(s)){for(var c=0,d=s({},this,r,o,!(ce()&&!this.isStringTemplate&&0===a.indexOf("
Blazor"))||this.isStringTemplate);c/g,"");(this.element.children.length>0||i)&&(this.innerContentElement=document.createDocumentFragment(),[].slice.call(this.element.childNodes).forEach(function(r){8!==r.nodeType&&e.innerContentElement.appendChild(r)}))}},t.prototype.setHeader=function(){this.headerEle?this.headerEle.innerHTML="":this.headerEle=this.createElement("div",{id:this.element.id+"_title",className:m4}),this.createHeaderContent(),this.headerContent.appendChild(this.headerEle),this.setTemplate(this.header,this.headerEle,"header"),Fe(this.element,{"aria-describedby":this.element.id+"_title"}),Fe(this.element,{"aria-labelledby":this.element.id+"_dialog-header"}),this.element.insertBefore(this.headerContent,this.element.children[0]),this.allowDragging&&!m(this.headerContent)&&this.setAllowDragging()},t.prototype.setFooterTemplate=function(){this.ftrTemplateContent?this.ftrTemplateContent.innerHTML="":this.ftrTemplateContent=this.createElement("div",{className:Y0}),""===this.footerTemplate||m(this.footerTemplate)?this.ftrTemplateContent.innerHTML=this.buttonContent.join(""):this.setTemplate(this.footerTemplate,this.ftrTemplateContent,"footerTemplate"),this.element.appendChild(this.ftrTemplateContent)},t.prototype.createHeaderContent=function(){m(this.headerContent)&&(this.headerContent=this.createElement("div",{id:this.element.id+"_dialog-header",className:PE}))},t.prototype.renderCloseIcon=function(){this.showCloseIcon&&(this.closeIcon=this.createElement("button",{className:I4,attrs:{type:"button"}}),this.closeIconBtnObj=new ys({cssClass:"e-flat",iconCss:y4+" e-icons"}),this.closeIconTitle(),m(this.headerContent)?(this.createHeaderContent(),gl([this.closeIcon],this.headerContent),this.element.insertBefore(this.headerContent,this.element.children[0])):gl([this.closeIcon],this.headerContent),this.closeIconBtnObj.appendTo(this.closeIcon))},t.prototype.closeIconTitle=function(){this.l10n.setLocale(this.locale);var e=this.l10n.getConstant("close");this.closeIcon.setAttribute("title",e),this.closeIcon.setAttribute("aria-label",e)},t.prototype.setCSSClass=function(e){e&&(K([this.element],e.split(" ")),this.isModal&&!m(this.dlgContainer)&&K([this.dlgContainer],e.split(" "))),this.cssClass&&(V([this.element],this.cssClass.split(" ")),this.isModal&&!m(this.dlgContainer)&&V([this.dlgContainer],this.cssClass.split(" ")))},t.prototype.setIsModal=function(){this.dlgContainer=this.createElement("div",{className:"e-dlg-container"}),this.setCSSClass(),this.element.classList.remove(b4),this.element.parentNode.insertBefore(this.dlgContainer,this.element),this.dlgContainer.appendChild(this.element),V([this.element],Q0),this.dlgOverlay=this.createElement("div",{className:"e-dlg-overlay"}),this.dlgOverlay.style.zIndex=(this.zIndex-1).toString(),this.dlgContainer.appendChild(this.dlgOverlay)},t.prototype.getValidFocusNode=function(e){for(var i,r=0;r0||"a"===i.tagName.toLowerCase()&&i.hasAttribute("href"))&&i.tabIndex>-1&&!i.disabled&&!this.disableElement(i,'[disabled],[aria-disabled="true"],[type="hidden"]'))return i;i=null}return i},t.prototype.focusableElements=function(e){if(!m(e)){var r=e.querySelectorAll('input,select,textarea,button,a,[contenteditable="true"],[tabindex]');return this.getValidFocusNode(r)}return null},t.prototype.getAutoFocusNode=function(e){var i=e.querySelector("."+I4),s=e.querySelectorAll("[autofocus]"),o=this.getValidFocusNode(s);if(ce()&&(this.primaryButtonEle=this.element.getElementsByClassName("e-primary")[0]),m(o)){if(!m(o=this.focusableElements(this.contentEle)))return o;if(!m(this.primaryButtonEle))return this.element.querySelector(".e-primary")}else i=o;return i},t.prototype.disableElement=function(e,i){var r=e?e.matches||e.webkitMatchesSelector||e.msGetRegionContent:null;if(r)for(;e;e=e.parentNode)if(e instanceof Element&&r.call(e,i))return e;return null},t.prototype.focusContent=function(){var e=this.getAutoFocusNode(this.element),i=m(e)?this.element:e,r=X.userAgent;(r.indexOf("MSIE ")>0||r.indexOf("Trident/")>0)&&this.element.focus(),i.focus(),this.unBindEvent(this.element),this.bindEvent(this.element)},t.prototype.bindEvent=function(e){E.add(e,"keydown",this.keyDown,this)},t.prototype.unBindEvent=function(e){E.remove(e,"keydown",this.keyDown)},t.prototype.updateSanitizeContent=function(){this.isBlazorServerRender()||(this.contentEle.innerHTML=this.sanitizeHelper(this.content))},t.prototype.isBlazorServerRender=function(){return ce()&&this.isServerRendered},t.prototype.getModuleName=function(){return"dialog"},t.prototype.onPropertyChanged=function(e,i){if(this.element.classList.contains(W0))for(var r=0,s=Object.keys(e);r0?this.showCloseIcon||""!==this.header&&!m(this.header)?this.showCloseIcon||he(this.closeIcon):(he(this.headerContent),this.headerContent=null):(this.renderCloseIcon(),this.wireEvents());break;case"locale":this.showCloseIcon&&this.closeIconTitle();break;case"visible":this.visible?this.show():this.hide();break;case"isModal":this.updateIsModal();break;case"height":je(this.element,{height:Re(e.height)}),this.updatePersistData();break;case"width":je(this.element,{width:Re(e.width)}),this.updatePersistData();break;case"zIndex":this.popupObj.zIndex=this.zIndex,this.isModal&&this.setOverlayZindex(this.zIndex),this.element.style.zIndex!==this.zIndex.toString()&&(this.calculatezIndex=!1);break;case"cssClass":this.setCSSClass(i.cssClass);break;case"buttons":this.unWireButtonEvents(),this.destroyButtons(),m(this.ftrTemplateContent)||(he(this.ftrTemplateContent),this.ftrTemplateContent=null),this.footerTemplate="",this.setButton();break;case"allowDragging":this.allowDragging&&!m(this.headerContent)?this.setAllowDragging():this.dragObj.destroy();break;case"target":this.setTarget(e.target);break;case"position":if(this.checkPositionData(),this.isModal){var a=this.position.X,l=this.position.Y;m(i.position)||(m(i.position.X)||(a=i.position.X),m(i.position.Y)||(l=i.position.Y)),this.dlgContainer.classList.contains("e-dlg-"+a+"-"+l)&&this.dlgContainer.classList.remove("e-dlg-"+a+"-"+l)}this.positionChange(),this.updatePersistData();break;case"enableRtl":this.setEnableRTL();break;case"enableResize":this.setResize(),this.isModelResize=this.enableResize&&this.isModal,this.enableResize&&this.dialogOpen&&this.resetResizeIcon();break;case"minHeight":""!==this.minHeight&&(this.element.style.minHeight=Re(this.minHeight))}},t.prototype.setTarget=function(e){this.popupObj.relateTo=e,this.target=e,this.targetEle="string"==typeof this.target?document.querySelector(this.target):this.target,this.dragObj&&(this.dragObj.dragArea=this.targetEle),this.setMaxHeight(),this.isModal&&this.updateIsModal(),this.enableResize&&this.setResize(),m(this.targetEle)||(this.isModal&&!m(this.dlgContainer)?this.targetEle.appendChild(this.dlgContainer):m(this.element)||this.targetEle.appendChild(this.element))},t.prototype.updateIsModal=function(){if(this.element.setAttribute("aria-modal",this.isModal?"true":"false"),this.isModal)m(this.dlgOverlay)&&(this.setIsModal(),this.element.style.top="0px",this.element.style.left="0px",m(this.targetEle)||this.targetEle.appendChild(this.dlgContainer));else{for(K([this.element],Q0),K([document.body],[Pa,ea]),he(this.dlgOverlay);this.dlgContainer.firstChild;)this.dlgContainer.parentElement.insertBefore(this.dlgContainer.firstChild,this.dlgContainer);this.dlgContainer.parentElement.removeChild(this.dlgContainer)}this.visible&&this.show(),this.positionChange(),this.isModal&&this.dlgOverlay&&E.add(this.dlgOverlay,"click",this.dlgOverlayClickEventHandler,this)},t.prototype.setzIndex=function(e,i){var r=this.isProtectedOnChange;this.isProtectedOnChange=!0;var s=hc(e);this.zIndex=s>this.zIndex?s:this.zIndex,this.isProtectedOnChange=r,i&&(this.popupObj.zIndex=this.zIndex)},t.prototype.windowResizeHandler=function(){(function IJ(n){Sh=n})(this.targetEle.clientWidth),function bJ(n){yh=n}(this.targetEle.clientHeight),this.setMaxHeight()},t.prototype.getPersistData=function(){return this.addOnPersist(["width","height","position"])},t.prototype.removeAllChildren=function(e){for(;e.children[0];)this.removeAllChildren(e.children[0]),e.removeChild(e.children[0])},t.prototype.destroy=function(){if(!this.isDestroyed){var e=[kE,Q0,zE,uf,G0,S4],i=["role","aria-modal","aria-labelledby","aria-describedby","aria-grabbed","tabindex","style"];K([this.targetEle],[Pa,ea]),!m(this.element)&&this.element.classList.contains(G0)&&K([document.body],[Pa,ea]),this.isModal&&K([m(this.targetEle)?document.body:this.targetEle],ea),this.unWireEvents(),this.unWireButtonEvents(),this.destroyButtons(),m(this.closeIconBtnObj)||this.closeIconBtnObj.destroy(),m(this.dragObj)||this.dragObj.destroy(),!m(this.popupObj.element)&&this.popupObj.element.classList.contains("e-popup")&&this.popupObj.destroy(),K([this.element],e),!m(this.cssClass)&&""!==this.cssClass&&K([this.element],this.cssClass.split(" ")),!m(this.refElement)&&!m(this.refElement.parentElement)&&(this.refElement.parentElement.insertBefore(this.isModal?this.dlgContainer:this.element,this.refElement),he(this.refElement),this.refElement=void 0),this.isModal&&(he(this.dlgOverlay),this.dlgContainer.parentNode.insertBefore(this.element,this.dlgContainer),he(this.dlgContainer)),this.element.innerHTML=this.clonedEle.innerHTML;for(var r=0;r0&&""===this.footerTemplate&&this.ftrTemplateContent)for(var e=0;e=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},HE="e-tooltip",O4="e-icons",k4="e-tooltip-close",BE="e-tooltip-wrap",P4="e-tip-content",ff="e-arrow-tip",z4="e-arrow-tip-outer",X0="e-arrow-tip-inner",Gg="e-tip-bottom",FE="e-tip-top",R4="e-tip-left",_E="e-tip-right",UE="e-popup",Xg="e-popup-open",jE="e-popup-close",q0="e-lib",H4="e-tooltip-popup-container",VJ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return T4(t,n),Gi([I({effect:"FadeIn",duration:150,delay:0})],t.prototype,"open",void 0),Gi([I({effect:"FadeOut",duration:150,delay:0})],t.prototype,"close",void 0),t}(Ee),bh=function(n){function t(e,i){var r=n.call(this,e,i)||this;return r.mouseMoveEvent=null,r.mouseMoveTarget=null,r.containerElement=null,r.isBodyContainer=!0,r}return T4(t,n),t.prototype.initialize=function(){this.formatPosition(),V([this.element],HE)},t.prototype.formatPosition=function(){var e,i;this.position&&(0===this.position.indexOf("Top")||0===this.position.indexOf("Bottom")?(e=this.position.split(/(?=[A-Z])/),this.tooltipPositionY=e[0],this.tooltipPositionX=e[1]):(i=this.position.split(/(?=[A-Z])/),this.tooltipPositionX=i[0],this.tooltipPositionY=i[1]))},t.prototype.renderArrow=function(){this.setTipClass(this.position);var e=this.createElement("div",{className:ff+" "+this.tipClass});e.appendChild(this.createElement("div",{className:z4+" "+this.tipClass})),e.appendChild(this.createElement("div",{className:X0+" "+this.tipClass})),this.tooltipEle.appendChild(e)},t.prototype.setTipClass=function(e){this.tipClass=0===e.indexOf("Right")?R4:0===e.indexOf("Bottom")?FE:0===e.indexOf("Left")?_E:Gg},t.prototype.renderPopup=function(e){var i=this.mouseTrail?{top:0,left:0}:this.getTooltipPosition(e);this.tooltipEle.classList.remove(q0),this.popupObj=new lc(this.tooltipEle,{height:this.height,width:this.width,position:{X:i.left,Y:i.top},enableRtl:this.enableRtl,open:this.openPopupHandler.bind(this),close:this.closePopupHandler.bind(this)})},t.prototype.getScalingFactor=function(e){if(!e)return{x:1,y:1};var i={x:1,y:1},r=e.closest('[style*="transform: scale"]');if(r&&r!==this.tooltipEle&&r.contains(this.tooltipEle)){var a=window.getComputedStyle(r).getPropertyValue("transform").match(/matrix\(([^)]+)\)/)[1].split(",").map(parseFloat);i.x=a[0],i.y=a[3]}return i},t.prototype.getTooltipPosition=function(e){this.tooltipEle.style.display="block";var i=this.element.closest('[style*="zoom"]');i&&(i.contains(this.tooltipEle)||(this.tooltipEle.style.zoom=getComputedStyle(i).zoom));var r=ns(e,this.tooltipPositionX,this.tooltipPositionY,!this.isBodyContainer,this.isBodyContainer?null:this.containerElement.getBoundingClientRect()),s=this.getScalingFactor(e),o=this.calculateTooltipOffset(this.position,s.x,s.y),a=this.calculateElementPosition(r,o),c=this.collisionFlipFit(e,a[0],a[1]);return c.left=c.left/s.x,c.top=c.top/s.y,this.tooltipEle.style.display="",c},t.prototype.windowResize=function(){this.reposition(this.findTarget())},t.prototype.reposition=function(e){if(this.popupObj&&e){var i=this.getTooltipPosition(e);this.popupObj.position={X:i.left,Y:i.top},this.popupObj.dataBind()}},t.prototype.openPopupHandler=function(){!this.mouseTrail&&this.needTemplateReposition()&&this.reposition(this.findTarget()),this.trigger("afterOpen",this.tooltipEventArgs),this.tooltipEventArgs=null},t.prototype.closePopupHandler=function(){this.isReact&&!("Click"===this.opensOn||"function"==typeof this.content)&&this.clearTemplate(["content"]),this.clear();var e={type:this.tooltipEventArgs.event?this.tooltipEventArgs.event.type:null,cancel:!1,target:this.tooltipEventArgs.target,event:this.tooltipEventArgs.event?this.tooltipEventArgs.event:null,element:this.tooltipEle,isInteracted:!m(this.tooltipEventArgs.event)};this.trigger("afterClose",e),e=null},t.prototype.calculateTooltipOffset=function(e,i,r){void 0===i&&(i=1),void 0===r&&(r=1);var o,a,l,h,c,d,u,f,s={top:0,left:0};if(1!==i||1!==r){var p=this.tooltipEle.getBoundingClientRect(),g=void 0;l=Math.round(p.width),h=Math.round(p.height),(c=_("."+ff,this.tooltipEle))&&(g=c.getBoundingClientRect()),o=c?Math.round(g.width):0,a=c?Math.round(g.height):0,d=this.showTipPointer?0:8,u=a/2+2+(h-this.tooltipEle.clientHeight*r),f=o/2+2+(l-this.tooltipEle.clientWidth*i)}else l=this.tooltipEle.offsetWidth,h=this.tooltipEle.offsetHeight,c=_("."+ff,this.tooltipEle),d=this.showTipPointer?0:8,u=(a=c?c.offsetHeight:0)/2+2+(this.tooltipEle.offsetHeight-this.tooltipEle.clientHeight),f=(o=c?c.offsetWidth:0)/2+2+(this.tooltipEle.offsetWidth-this.tooltipEle.clientWidth);switch(this.mouseTrail&&(d+=2),e){case"RightTop":s.left+=o+d,s.top-=h-u;break;case"RightCenter":s.left+=o+d,s.top-=h/2;break;case"RightBottom":s.left+=o+d,s.top-=u;break;case"BottomRight":s.top+=a+d,s.left-=f;break;case"BottomCenter":s.top+=a+d,s.left-=l/2;break;case"BottomLeft":s.top+=a+d,s.left-=l-f;break;case"LeftBottom":s.left-=o+l+d,s.top-=u;break;case"LeftCenter":s.left-=o+l+d,s.top-=h/2;break;case"LeftTop":s.left-=o+l+d,s.top-=h-u;break;case"TopLeft":s.top-=h+a+d,s.left-=l-f;break;case"TopRight":s.top-=h+a+d,s.left-=f;break;default:s.top-=h+a+d,s.left-=l/2}return s.left+=this.offsetX,s.top+=this.offsetY,s},t.prototype.updateTipPosition=function(e){var i=we("."+ff+",."+z4+",."+X0,this.tooltipEle);K(i,[Gg,FE,R4,_E]),this.setTipClass(e),V(i,this.tipClass)},t.prototype.adjustArrow=function(e,i,r,s){var o=_("."+ff,this.tooltipEle);if(!1!==this.showTipPointer&&null!==o){var a,l;this.updateTipPosition(i),this.tooltipEle.style.display="block";var p,h=this.tooltipEle.clientWidth,c=this.tooltipEle.clientHeight,d=_("."+X0,this.tooltipEle),u=o.offsetWidth,f=o.offsetHeight;this.tooltipEle.style.display="",this.tipClass===Gg||this.tipClass===FE?(this.tipClass===Gg?(l="99.9%",d.style.top="-"+(f-2)+"px"):(l=-(f-1)+"px",d.style.top="-"+(f-6)+"px"),e&&(a=(p="Center"!==r||h>e.offsetWidth||this.mouseTrail)&&"Left"===r||!p&&"End"===this.tipPointerPosition?h-u-2+"px":p&&"Right"===r||!p&&"Start"===this.tipPointerPosition?"2px":!p||"End"!==this.tipPointerPosition&&"Start"!==this.tipPointerPosition?h/2-u/2+"px":"End"===this.tipPointerPosition?e.offsetWidth+(this.tooltipEle.offsetWidth-e.offsetWidth)/2-u/2-2+"px":(this.tooltipEle.offsetWidth-e.offsetWidth)/2-u/2+2+"px")):(this.tipClass===_E?(a="99.9%",d.style.left="-"+(u-2)+"px"):(a=-(u-1)+"px",d.style.left=u-2-u+"px"),l=(p="Center"!==s||c>e.offsetHeight||this.mouseTrail)&&"Top"===s||!p&&"End"===this.tipPointerPosition?c-f-2+"px":p&&"Bottom"===s||!p&&"Start"===this.tipPointerPosition?"2px":c/2-f/2+"px"),o.style.top=l,o.style.left=a}},t.prototype.renderContent=function(e){var i=this,r=_("."+P4,this.tooltipEle);if(this.cssClass&&V([this.tooltipEle],this.cssClass.split(" ")),e&&!m(e.getAttribute("title"))&&(e.setAttribute("data-content",e.getAttribute("title")),e.removeAttribute("title")),m(this.content))e&&!m(e.getAttribute("data-content"))&&(r.innerHTML=e.getAttribute("data-content"));else if(r.innerHTML="",this.content instanceof HTMLElement)r.appendChild(this.content);else if("string"==typeof this.content)this.isAngular?this.setProperties({content:Ai.sanitize(this.content)},!0):this.content=this.enableHtmlSanitizer?Ai.sanitize(this.content):this.content,this.enableHtmlParse?(o=oi(this.content)({},this,"content",this.element.id+"content",void 0,void 0,r,this.root))&&Dt(o,r):r.textContent=this.content;else{var o;(o=oi(this.content)({},this,"content",this.element.id+"content",void 0,void 0,r))&&(this.isAngular&&setTimeout(function(){i.reposition(e)},1),Dt(o,r)),this.renderReactTemplates()}},t.prototype.renderCloseIcon=function(){if(this.isSticky){var i=this.createElement("div",{className:O4+" "+k4});this.tooltipEle.appendChild(i),E.add(i,X.touchStartEvent,this.onStickyClose,this)}else{var e=this.tooltipEle.querySelector("."+O4+"."+k4);e&>(e)}},t.prototype.addDescribedBy=function(e,i){var r=(e.getAttribute("aria-describedby")||"").split(/\s+/);r.indexOf(i)<0&&r.push(i),Fe(e,{"aria-describedby":r.join(" ").trim(),"data-tooltip-id":i})},t.prototype.removeDescribedBy=function(e){var i=e.getAttribute("data-tooltip-id"),r=(e.getAttribute("aria-describedby")||"").split(/\s+/),s=r.indexOf(i);-1!==s&&r.splice(s,1),e.removeAttribute("data-tooltip-id");var o=r.join(" ").trim();o?e.setAttribute("aria-describedby",o):e.removeAttribute("aria-describedby")},t.prototype.tapHoldHandler=function(e){clearTimeout(this.autoCloseTimer),this.targetHover(e.originalEvent)},t.prototype.touchEndHandler=function(){var e=this;this.isSticky||(this.autoCloseTimer=setTimeout(function(){e.close()},1500))},t.prototype.targetClick=function(e){var i;!m(i=this.target?J(e.target,this.target):this.element)&&(null===i.getAttribute("data-tooltip-id")?this.targetHover(e):this.isSticky||this.hideTooltip(this.animation.close,e,i))},t.prototype.targetHover=function(e){var i;if(!(m(i=this.target?J(e.target,this.target):this.element)||null!==i.getAttribute("data-tooltip-id")&&0===this.closeDelay)){for(var s=0,o=[].slice.call(we('[data-tooltip-id= "'+this.ctrlId+'_content"]',document));s0?this.showTimer=setTimeout(function(){o.mouseTrail&&E.add(i,"mousemove touchstart mouseenter",o.onMouseMove,o),o.popupObj&&(o.popupObj.show(a,i),o.mouseMoveEvent&&o.mouseTrail&&o.onMouseMove(o.mouseMoveEvent))},this.openDelay):this.popupObj&&this.popupObj.show(a,i)}s&&this.wireMouseEvents(s,i)},t.prototype.needTemplateReposition=function(){return!m(this.viewContainerRef)&&"string"!=typeof this.viewContainerRef||this.isReact},t.prototype.checkCollision=function(e,i,r){var s={left:i,top:r,position:this.position,horizontal:this.tooltipPositionX,vertical:this.tooltipPositionY},o=ac(this.tooltipEle,this.checkCollideTarget(),i,r);return o.length>0&&(s.horizontal=o.indexOf("left")>=0?"Right":o.indexOf("right")>=0?"Left":this.tooltipPositionX,s.vertical=o.indexOf("top")>=0?"Bottom":o.indexOf("bottom")>=0?"Top":this.tooltipPositionY),s},t.prototype.calculateElementPosition=function(e,i){return[this.isBodyContainer?e.left+i.left:e.left-this.containerElement.getBoundingClientRect().left+i.left+window.pageXOffset+this.containerElement.scrollLeft,this.isBodyContainer?e.top+i.top:e.top-this.containerElement.getBoundingClientRect().top+i.top+window.pageYOffset+this.containerElement.scrollTop]},t.prototype.collisionFlipFit=function(e,i,r){var s=this.checkCollision(e,i,r),o=s.position;if(this.tooltipPositionY!==s.vertical&&(o=0===this.position.indexOf("Bottom")||0===this.position.indexOf("Top")?s.vertical+this.tooltipPositionX:this.tooltipPositionX+s.vertical),this.tooltipPositionX!==s.horizontal&&(0===o.indexOf("Left")&&(s.vertical="LeftTop"===o||"LeftCenter"===o?"Top":"Bottom",o=s.vertical+"Left"),0===o.indexOf("Right")&&(s.vertical="RightTop"===o||"RightCenter"===o?"Top":"Bottom",o=s.vertical+"Right"),s.horizontal=this.tooltipPositionX),this.tooltipEventArgs={type:null,cancel:!1,target:e,event:null,element:this.tooltipEle,collidedPosition:o},this.trigger("beforeCollision",this.tooltipEventArgs),this.tooltipEventArgs.cancel)o=this.position;else{var a=s.vertical,l=s.horizontal;if(s.position!==o){var h=ns(e,l,a,!this.isBodyContainer,this.isBodyContainer?null:this.containerElement.getBoundingClientRect());this.adjustArrow(e,o,l,a);var c=this.getScalingFactor(e),d=this.calculateTooltipOffset(o,c.x,c.y);d.top-=this.getOffSetPosition("TopBottom",o,this.offsetY),d.left-=this.getOffSetPosition("RightLeft",o,this.offsetX),s.position=o;var u=this.calculateElementPosition(h,d);s.left=u[0],s.top=u[1]}else this.adjustArrow(e,o,l,a)}var f={left:s.left,top:s.top},p=this.isBodyContainer?dE(this.tooltipEle,this.checkCollideTarget(),{X:!0,Y:this.windowCollision},f):f;this.tooltipEle.style.display="block";var g=_("."+ff,this.tooltipEle);if(this.showTipPointer&&null!=g&&(0===o.indexOf("Bottom")||0===o.indexOf("Top"))){var v=parseInt(g.style.left,10)-(p.left-s.left);v<0?v=0:v+g.offsetWidth>this.tooltipEle.clientWidth&&(v=this.tooltipEle.clientWidth-g.offsetWidth),g.style.left=v.toString()+"px"}return this.tooltipEle.style.display="",f.left=p.left,f.top=p.top,f},t.prototype.getOffSetPosition=function(e,i,r){return-1!==e.indexOf(this.position.split(/(?=[A-Z])/)[0])&&-1!==e.indexOf(i.split(/(?=[A-Z])/)[0])?2*r:0},t.prototype.checkCollideTarget=function(){return!this.windowCollision&&this.target?this.element:null},t.prototype.hideTooltip=function(e,i,r){var s=this;this.closeDelay>0?(clearTimeout(this.hideTimer),clearTimeout(this.showTimer),this.hideTimer=setTimeout(function(){s.closeDelay&&s.tooltipEle&&s.isTooltipOpen||s.tooltipHide(e,i,r)},this.closeDelay)):this.tooltipHide(e,i,r)},t.prototype.tooltipHide=function(e,i,r){var o,s=this;o=i?this.target?r||i.target:this.element:_('[data-tooltip-id= "'+this.ctrlId+'_content"]',document),this.tooltipEventArgs={type:i?i.type:null,cancel:!1,target:o,event:i||null,element:this.tooltipEle,isInteracted:!m(i)},this.trigger("beforeClose",this.tooltipEventArgs,function(a){a.cancel?s.isHidden=!1:(s.mouseMoveBeforeRemove(),s.popupHide(e,o,i))})},t.prototype.popupHide=function(e,i,r){i&&r&&this.restoreElement(i),this.isHidden=!0;var s={name:this.animation.close.effect,duration:e.duration,delay:e.delay,timingFunction:"easeIn"};"None"===e.effect&&(s=void 0),this.popupObj&&this.popupObj.hide(s)},t.prototype.restoreElement=function(e){this.unwireMouseEvents(e),m(e.getAttribute("data-content"))||(e.setAttribute("title",e.getAttribute("data-content")),e.removeAttribute("data-content")),this.removeDescribedBy(e)},t.prototype.clear=function(){var e=this.findTarget();e&&this.restoreElement(e),this.tooltipEle&&(K([this.tooltipEle],jE),V([this.tooltipEle],Xg)),this.isHidden&&(this.popupObj&&this.popupObj.destroy(),this.tooltipEle&>(this.tooltipEle),this.tooltipEle=null,this.popupObj=null)},t.prototype.tooltipHover=function(){this.tooltipEle&&(this.isTooltipOpen=!0)},t.prototype.tooltipMouseOut=function(e){this.isTooltipOpen=!1,this.hideTooltip(this.animation.close,e,this.findTarget())},t.prototype.onMouseOut=function(e){var i=e.relatedTarget;if(i&&!this.mouseTrail){var r=J(i,"."+BE+"."+q0+"."+UE);r?E.add(r,"mouseleave",this.tooltipElementMouseOut,this):(this.hideTooltip(this.animation.close,e,this.findTarget()),0===this.closeDelay&&("None"===this.animation.close.effect||this.isReact&&"string"!=typeof this.content)&&this.clear())}else this.hideTooltip(this.animation.close,e,this.findTarget()),this.clear();this.popupObj&&!this.popupObj.element.classList.contains(Xg)&&this.clear()},t.prototype.tooltipElementMouseOut=function(e){this.hideTooltip(this.animation.close,e,this.findTarget()),E.remove(this.element,"mouseleave",this.tooltipElementMouseOut),this.clear()},t.prototype.onStickyClose=function(){this.close()},t.prototype.onMouseMove=function(e){var i=0,r=0;e.type.indexOf("touch")>-1?(e.preventDefault(),i=e.touches[0].pageX,r=e.touches[0].pageY):(i=e.pageX,r=e.pageY),Hs.stop(this.tooltipEle),K([this.tooltipEle],jE),V([this.tooltipEle],Xg),this.adjustArrow(e.target,this.position,this.tooltipPositionX,this.tooltipPositionY);var s=this.getScalingFactor(e.target),o=this.calculateTooltipOffset(this.position,s.x,s.y),h=this.checkCollision(e.target,i+o.left+this.offsetX,r+o.top+this.offsetY);if(this.tooltipPositionX!==h.horizontal||this.tooltipPositionY!==h.vertical){var c=0===this.position.indexOf("Bottom")||0===this.position.indexOf("Top")?h.vertical+h.horizontal:h.horizontal+h.vertical;h.position=c,this.adjustArrow(e.target,h.position,h.horizontal,h.vertical);var d=this.calculateTooltipOffset(h.position,s.x,s.y);h.left=i+d.left-this.offsetX,h.top=r+d.top-this.offsetY}this.tooltipEle.style.left=h.left+"px",this.tooltipEle.style.top=h.top+"px"},t.prototype.keyDown=function(e){this.tooltipEle&&27===e.keyCode&&this.close()},t.prototype.touchEnd=function(e){this.tooltipEle&&null===J(e.target,"."+HE)&&!this.isSticky&&this.close()},t.prototype.scrollHandler=function(e){this.tooltipEle&&!this.isSticky&&!J(e.target,"."+BE+"."+q0+"."+UE)&&!this.isSticky&&this.close()},t.prototype.render=function(){this.initialize(),this.wireEvents(this.opensOn),this.renderComplete()},t.prototype.preRender=function(){this.tipClass=Gg,this.tooltipPositionX="Center",this.tooltipPositionY="Top",this.isHidden=!0},t.prototype.wireEvents=function(e){for(var r=0,s=this.getTriggerList(e);r0)for(var i=0,r=e;i0)for(var i=0,r=e;i0&&this.condition&&-1!==this.condition.indexOf("not")&&(e[s].condition=e[s].condition?e[s].condition+"not":"not"),i=e[s].validate(t),r){if(!i)return!1}else if(i)return!0;return r},n.prototype.toJson=function(){var t,e;if(this.isComplex){t=[],e=this.predicates;for(var i=0;ie.length-3?(e=e.substring(0,e.length-1),n.endsWith(n.toLowerCase(t),n.toLowerCase(e))):(e.lastIndexOf("%")!==e.indexOf("%")&&e.lastIndexOf("%")>e.indexOf("%")+1&&(e=e.substring(e.indexOf("%")+1,e.lastIndexOf("%"))),-1!==t.indexOf(e)))},n.fnSort=function(t){return"ascending"===(t=t?n.toLowerCase(t):"ascending")?this.fnAscending:this.fnDescending},n.fnAscending=function(t,e){return m(t)&&m(e)||null==e?-1:"string"==typeof t?t.localeCompare(e):null==t?1:t-e},n.fnDescending=function(t,e){return m(t)&&m(e)?-1:null==e?1:"string"==typeof t?-1*t.localeCompare(e):null==t?-1:e-t},n.extractFields=function(t,e){for(var i={},r=0;r0||e.length>0;)o=t.length>0&&e.length>0?r?r(this.getVal(t,0,i),this.getVal(e,0,i),t[0],e[0])<=0?t:e:t[0][i]0?t:e,s.push(o.shift());return s},n.getVal=function(t,e,i){return i?this.getObject(i,t[e]):t[e]},n.toLowerCase=function(t){return t?"string"==typeof t?t.toLowerCase():t.toString():0===t||!1===t?t.toString():""},n.callAdaptorFunction=function(t,e,i,r){if(e in t){var s=t[e](i,r);m(s)||(i=s)}return i},n.getAddParams=function(t,e,i){var r={};return n.callAdaptorFunction(t,"addParams",{dm:e,query:i,params:i?i.params:[],reqParams:r}),r},n.isPlainObject=function(t){return!!t&&t.constructor===Object},n.isCors=function(){var t=null;try{t=new window.XMLHttpRequest}catch{}return!!t&&"withCredentials"in t},n.getGuid=function(t){var i;return(t||"")+"00000000-0000-4000-0000-000000000000".replace(/0/g,function(r,s){if("crypto"in window&&"getRandomValues"in crypto){var o=new Uint8Array(1);window.crypto.getRandomValues(o),i=o[0]%16|0}else i=16*Math.random()|0;return"0123456789abcdef"[19===s?3&i|8:i]})},n.isNull=function(t){return null==t},n.getItemFromComparer=function(t,e,i){var r,s,o,a=0,l="string"==typeof n.getVal(t,0,e);if(t.length)for(;m(r)&&a0&&(r=s,o=t[a]));return o},n.distinct=function(t,e,i){i=!m(i)&&i;var s,r=[],o={};return t.forEach(function(a,l){(s="object"==typeof t[l]?n.getVal(t,l,e):t[l])in o||(r.push(i?t[l]:s),o[s]=1)}),r},n.processData=function(t,e){var i=this.prepareQuery(t),r=new it(e);t.requiresCounts&&i.requiresCount();var s=r.executeLocal(i),o={result:t.requiresCounts?s.result:s,count:s.count,aggregates:JSON.stringify(s.aggregates)};return t.requiresCounts?o:s},n.prepareQuery=function(t){var e=this,i=new _t;return t.select&&i.select(t.select),t.where&&n.parse.parseJson(t.where).filter(function(o){if(m(o.condition))i.where(o.field,o.operator,o.value,o.ignoreCase,o.ignoreAccent);else{var a=[];o.field?a.push(new Ss(o.field,o.operator,o.value,o.ignoreCase,o.ignoreAccent)):a=a.concat(e.getPredicate(o.predicates)),"or"===o.condition?i.where(Ss.or(a)):"and"===o.condition&&i.where(Ss.and(a))}}),t.search&&n.parse.parseJson(t.search).filter(function(o){return i.search(o.key,o.fields,o.operator,o.ignoreCase,o.ignoreAccent)}),t.aggregates&&t.aggregates.filter(function(o){return i.aggregate(o.type,o.field)}),t.sorted&&t.sorted.filter(function(o){return i.sortBy(o.name,o.direction)}),t.skip&&i.skip(t.skip),t.take&&i.take(t.take),t.group&&t.group.filter(function(o){return i.group(o)}),i},n.getPredicate=function(t){for(var e=[],i=0;i":"greaterthan","<=":"lessthanorequal",">=":"greaterthanorequal","==":"equal","!=":"notequal","*=":"contains","$=":"endswith","^=":"startswith"},n.odBiOperator={"<":" lt ",">":" gt ","<=":" le ",">=":" ge ","==":" eq ","!=":" ne ",lessthan:" lt ",lessthanorequal:" le ",greaterthan:" gt ",greaterthanorequal:" ge ",equal:" eq ",notequal:" ne "},n.odUniOperator={"$=":"endswith","^=":"startswith","*=":"substringof",endswith:"endswith",startswith:"startswith",contains:"substringof",doesnotendwith:"not endswith",doesnotstartwith:"not startswith",doesnotcontain:"not substringof",wildcard:"wildcard",like:"like"},n.odv4UniOperator={"$=":"endswith","^=":"startswith","*=":"contains",endswith:"endswith",startswith:"startswith",contains:"contains",doesnotendwith:"not endswith",doesnotstartwith:"not startswith",doesnotcontain:"not contains",wildcard:"wildcard",like:"like"},n.diacritics={"\u24b6":"A",\uff21:"A",\u00c0:"A",\u00c1:"A",\u00c2:"A",\u1ea6:"A",\u1ea4:"A",\u1eaa:"A",\u1ea8:"A",\u00c3:"A",\u0100:"A",\u0102:"A",\u1eb0:"A",\u1eae:"A",\u1eb4:"A",\u1eb2:"A",\u0226:"A",\u01e0:"A",\u00c4:"A",\u01de:"A",\u1ea2:"A",\u00c5:"A",\u01fa:"A",\u01cd:"A",\u0200:"A",\u0202:"A",\u1ea0:"A",\u1eac:"A",\u1eb6:"A",\u1e00:"A",\u0104:"A",\u023a:"A",\u2c6f:"A",\ua732:"AA",\u00c6:"AE",\u01fc:"AE",\u01e2:"AE",\ua734:"AO",\ua736:"AU",\ua738:"AV",\ua73a:"AV",\ua73c:"AY","\u24b7":"B",\uff22:"B",\u1e02:"B",\u1e04:"B",\u1e06:"B",\u0243:"B",\u0182:"B",\u0181:"B","\u24b8":"C",\uff23:"C",\u0106:"C",\u0108:"C",\u010a:"C",\u010c:"C",\u00c7:"C",\u1e08:"C",\u0187:"C",\u023b:"C",\ua73e:"C","\u24b9":"D",\uff24:"D",\u1e0a:"D",\u010e:"D",\u1e0c:"D",\u1e10:"D",\u1e12:"D",\u1e0e:"D",\u0110:"D",\u018b:"D",\u018a:"D",\u0189:"D",\ua779:"D",\u01f1:"DZ",\u01c4:"DZ",\u01f2:"Dz",\u01c5:"Dz","\u24ba":"E",\uff25:"E",\u00c8:"E",\u00c9:"E",\u00ca:"E",\u1ec0:"E",\u1ebe:"E",\u1ec4:"E",\u1ec2:"E",\u1ebc:"E",\u0112:"E",\u1e14:"E",\u1e16:"E",\u0114:"E",\u0116:"E",\u00cb:"E",\u1eba:"E",\u011a:"E",\u0204:"E",\u0206:"E",\u1eb8:"E",\u1ec6:"E",\u0228:"E",\u1e1c:"E",\u0118:"E",\u1e18:"E",\u1e1a:"E",\u0190:"E",\u018e:"E","\u24bb":"F",\uff26:"F",\u1e1e:"F",\u0191:"F",\ua77b:"F","\u24bc":"G",\uff27:"G",\u01f4:"G",\u011c:"G",\u1e20:"G",\u011e:"G",\u0120:"G",\u01e6:"G",\u0122:"G",\u01e4:"G",\u0193:"G",\ua7a0:"G",\ua77d:"G",\ua77e:"G","\u24bd":"H",\uff28:"H",\u0124:"H",\u1e22:"H",\u1e26:"H",\u021e:"H",\u1e24:"H",\u1e28:"H",\u1e2a:"H",\u0126:"H",\u2c67:"H",\u2c75:"H",\ua78d:"H","\u24be":"I",\uff29:"I",\u00cc:"I",\u00cd:"I",\u00ce:"I",\u0128:"I",\u012a:"I",\u012c:"I",\u0130:"I",\u00cf:"I",\u1e2e:"I",\u1ec8:"I",\u01cf:"I",\u0208:"I",\u020a:"I",\u1eca:"I",\u012e:"I",\u1e2c:"I",\u0197:"I","\u24bf":"J",\uff2a:"J",\u0134:"J",\u0248:"J","\u24c0":"K",\uff2b:"K",\u1e30:"K",\u01e8:"K",\u1e32:"K",\u0136:"K",\u1e34:"K",\u0198:"K",\u2c69:"K",\ua740:"K",\ua742:"K",\ua744:"K",\ua7a2:"K","\u24c1":"L",\uff2c:"L",\u013f:"L",\u0139:"L",\u013d:"L",\u1e36:"L",\u1e38:"L",\u013b:"L",\u1e3c:"L",\u1e3a:"L",\u0141:"L",\u023d:"L",\u2c62:"L",\u2c60:"L",\ua748:"L",\ua746:"L",\ua780:"L",\u01c7:"LJ",\u01c8:"Lj","\u24c2":"M",\uff2d:"M",\u1e3e:"M",\u1e40:"M",\u1e42:"M",\u2c6e:"M",\u019c:"M","\u24c3":"N",\uff2e:"N",\u01f8:"N",\u0143:"N",\u00d1:"N",\u1e44:"N",\u0147:"N",\u1e46:"N",\u0145:"N",\u1e4a:"N",\u1e48:"N",\u0220:"N",\u019d:"N",\ua790:"N",\ua7a4:"N",\u01ca:"NJ",\u01cb:"Nj","\u24c4":"O",\uff2f:"O",\u00d2:"O",\u00d3:"O",\u00d4:"O",\u1ed2:"O",\u1ed0:"O",\u1ed6:"O",\u1ed4:"O",\u00d5:"O",\u1e4c:"O",\u022c:"O",\u1e4e:"O",\u014c:"O",\u1e50:"O",\u1e52:"O",\u014e:"O",\u022e:"O",\u0230:"O",\u00d6:"O",\u022a:"O",\u1ece:"O",\u0150:"O",\u01d1:"O",\u020c:"O",\u020e:"O",\u01a0:"O",\u1edc:"O",\u1eda:"O",\u1ee0:"O",\u1ede:"O",\u1ee2:"O",\u1ecc:"O",\u1ed8:"O",\u01ea:"O",\u01ec:"O",\u00d8:"O",\u01fe:"O",\u0186:"O",\u019f:"O",\ua74a:"O",\ua74c:"O",\u01a2:"OI",\ua74e:"OO",\u0222:"OU","\u24c5":"P",\uff30:"P",\u1e54:"P",\u1e56:"P",\u01a4:"P",\u2c63:"P",\ua750:"P",\ua752:"P",\ua754:"P","\u24c6":"Q",\uff31:"Q",\ua756:"Q",\ua758:"Q",\u024a:"Q","\u24c7":"R",\uff32:"R",\u0154:"R",\u1e58:"R",\u0158:"R",\u0210:"R",\u0212:"R",\u1e5a:"R",\u1e5c:"R",\u0156:"R",\u1e5e:"R",\u024c:"R",\u2c64:"R",\ua75a:"R",\ua7a6:"R",\ua782:"R","\u24c8":"S",\uff33:"S",\u1e9e:"S",\u015a:"S",\u1e64:"S",\u015c:"S",\u1e60:"S",\u0160:"S",\u1e66:"S",\u1e62:"S",\u1e68:"S",\u0218:"S",\u015e:"S",\u2c7e:"S",\ua7a8:"S",\ua784:"S","\u24c9":"T",\uff34:"T",\u1e6a:"T",\u0164:"T",\u1e6c:"T",\u021a:"T",\u0162:"T",\u1e70:"T",\u1e6e:"T",\u0166:"T",\u01ac:"T",\u01ae:"T",\u023e:"T",\ua786:"T",\ua728:"TZ","\u24ca":"U",\uff35:"U",\u00d9:"U",\u00da:"U",\u00db:"U",\u0168:"U",\u1e78:"U",\u016a:"U",\u1e7a:"U",\u016c:"U",\u00dc:"U",\u01db:"U",\u01d7:"U",\u01d5:"U",\u01d9:"U",\u1ee6:"U",\u016e:"U",\u0170:"U",\u01d3:"U",\u0214:"U",\u0216:"U",\u01af:"U",\u1eea:"U",\u1ee8:"U",\u1eee:"U",\u1eec:"U",\u1ef0:"U",\u1ee4:"U",\u1e72:"U",\u0172:"U",\u1e76:"U",\u1e74:"U",\u0244:"U","\u24cb":"V",\uff36:"V",\u1e7c:"V",\u1e7e:"V",\u01b2:"V",\ua75e:"V",\u0245:"V",\ua760:"VY","\u24cc":"W",\uff37:"W",\u1e80:"W",\u1e82:"W",\u0174:"W",\u1e86:"W",\u1e84:"W",\u1e88:"W",\u2c72:"W","\u24cd":"X",\uff38:"X",\u1e8a:"X",\u1e8c:"X","\u24ce":"Y",\uff39:"Y",\u1ef2:"Y",\u00dd:"Y",\u0176:"Y",\u1ef8:"Y",\u0232:"Y",\u1e8e:"Y",\u0178:"Y",\u1ef6:"Y",\u1ef4:"Y",\u01b3:"Y",\u024e:"Y",\u1efe:"Y","\u24cf":"Z",\uff3a:"Z",\u0179:"Z",\u1e90:"Z",\u017b:"Z",\u017d:"Z",\u1e92:"Z",\u1e94:"Z",\u01b5:"Z",\u0224:"Z",\u2c7f:"Z",\u2c6b:"Z",\ua762:"Z","\u24d0":"a",\uff41:"a",\u1e9a:"a",\u00e0:"a",\u00e1:"a",\u00e2:"a",\u1ea7:"a",\u1ea5:"a",\u1eab:"a",\u1ea9:"a",\u00e3:"a",\u0101:"a",\u0103:"a",\u1eb1:"a",\u1eaf:"a",\u1eb5:"a",\u1eb3:"a",\u0227:"a",\u01e1:"a",\u00e4:"a",\u01df:"a",\u1ea3:"a",\u00e5:"a",\u01fb:"a",\u01ce:"a",\u0201:"a",\u0203:"a",\u1ea1:"a",\u1ead:"a",\u1eb7:"a",\u1e01:"a",\u0105:"a",\u2c65:"a",\u0250:"a",\ua733:"aa",\u00e6:"ae",\u01fd:"ae",\u01e3:"ae",\ua735:"ao",\ua737:"au",\ua739:"av",\ua73b:"av",\ua73d:"ay","\u24d1":"b",\uff42:"b",\u1e03:"b",\u1e05:"b",\u1e07:"b",\u0180:"b",\u0183:"b",\u0253:"b","\u24d2":"c",\uff43:"c",\u0107:"c",\u0109:"c",\u010b:"c",\u010d:"c",\u00e7:"c",\u1e09:"c",\u0188:"c",\u023c:"c",\ua73f:"c",\u2184:"c","\u24d3":"d",\uff44:"d",\u1e0b:"d",\u010f:"d",\u1e0d:"d",\u1e11:"d",\u1e13:"d",\u1e0f:"d",\u0111:"d",\u018c:"d",\u0256:"d",\u0257:"d",\ua77a:"d",\u01f3:"dz",\u01c6:"dz","\u24d4":"e",\uff45:"e",\u00e8:"e",\u00e9:"e",\u00ea:"e",\u1ec1:"e",\u1ebf:"e",\u1ec5:"e",\u1ec3:"e",\u1ebd:"e",\u0113:"e",\u1e15:"e",\u1e17:"e",\u0115:"e",\u0117:"e",\u00eb:"e",\u1ebb:"e",\u011b:"e",\u0205:"e",\u0207:"e",\u1eb9:"e",\u1ec7:"e",\u0229:"e",\u1e1d:"e",\u0119:"e",\u1e19:"e",\u1e1b:"e",\u0247:"e",\u025b:"e",\u01dd:"e","\u24d5":"f",\uff46:"f",\u1e1f:"f",\u0192:"f",\ua77c:"f","\u24d6":"g",\uff47:"g",\u01f5:"g",\u011d:"g",\u1e21:"g",\u011f:"g",\u0121:"g",\u01e7:"g",\u0123:"g",\u01e5:"g",\u0260:"g",\ua7a1:"g",\u1d79:"g",\ua77f:"g","\u24d7":"h",\uff48:"h",\u0125:"h",\u1e23:"h",\u1e27:"h",\u021f:"h",\u1e25:"h",\u1e29:"h",\u1e2b:"h",\u1e96:"h",\u0127:"h",\u2c68:"h",\u2c76:"h",\u0265:"h",\u0195:"hv","\u24d8":"i",\uff49:"i",\u00ec:"i",\u00ed:"i",\u00ee:"i",\u0129:"i",\u012b:"i",\u012d:"i",\u00ef:"i",\u1e2f:"i",\u1ec9:"i",\u01d0:"i",\u0209:"i",\u020b:"i",\u1ecb:"i",\u012f:"i",\u1e2d:"i",\u0268:"i",\u0131:"i","\u24d9":"j",\uff4a:"j",\u0135:"j",\u01f0:"j",\u0249:"j","\u24da":"k",\uff4b:"k",\u1e31:"k",\u01e9:"k",\u1e33:"k",\u0137:"k",\u1e35:"k",\u0199:"k",\u2c6a:"k",\ua741:"k",\ua743:"k",\ua745:"k",\ua7a3:"k","\u24db":"l",\uff4c:"l",\u0140:"l",\u013a:"l",\u013e:"l",\u1e37:"l",\u1e39:"l",\u013c:"l",\u1e3d:"l",\u1e3b:"l",\u017f:"l",\u0142:"l",\u019a:"l",\u026b:"l",\u2c61:"l",\ua749:"l",\ua781:"l",\ua747:"l",\u01c9:"lj","\u24dc":"m",\uff4d:"m",\u1e3f:"m",\u1e41:"m",\u1e43:"m",\u0271:"m",\u026f:"m","\u24dd":"n",\uff4e:"n",\u01f9:"n",\u0144:"n",\u00f1:"n",\u1e45:"n",\u0148:"n",\u1e47:"n",\u0146:"n",\u1e4b:"n",\u1e49:"n",\u019e:"n",\u0272:"n",\u0149:"n",\ua791:"n",\ua7a5:"n",\u01cc:"nj","\u24de":"o",\uff4f:"o",\u00f2:"o",\u00f3:"o",\u00f4:"o",\u1ed3:"o",\u1ed1:"o",\u1ed7:"o",\u1ed5:"o",\u00f5:"o",\u1e4d:"o",\u022d:"o",\u1e4f:"o",\u014d:"o",\u1e51:"o",\u1e53:"o",\u014f:"o",\u022f:"o",\u0231:"o",\u00f6:"o",\u022b:"o",\u1ecf:"o",\u0151:"o",\u01d2:"o",\u020d:"o",\u020f:"o",\u01a1:"o",\u1edd:"o",\u1edb:"o",\u1ee1:"o",\u1edf:"o",\u1ee3:"o",\u1ecd:"o",\u1ed9:"o",\u01eb:"o",\u01ed:"o",\u00f8:"o",\u01ff:"o",\u0254:"o",\ua74b:"o",\ua74d:"o",\u0275:"o",\u01a3:"oi",\u0223:"ou",\ua74f:"oo","\u24df":"p",\uff50:"p",\u1e55:"p",\u1e57:"p",\u01a5:"p",\u1d7d:"p",\ua751:"p",\ua753:"p",\ua755:"p","\u24e0":"q",\uff51:"q",\u024b:"q",\ua757:"q",\ua759:"q","\u24e1":"r",\uff52:"r",\u0155:"r",\u1e59:"r",\u0159:"r",\u0211:"r",\u0213:"r",\u1e5b:"r",\u1e5d:"r",\u0157:"r",\u1e5f:"r",\u024d:"r",\u027d:"r",\ua75b:"r",\ua7a7:"r",\ua783:"r","\u24e2":"s",\uff53:"s",\u00df:"s",\u015b:"s",\u1e65:"s",\u015d:"s",\u1e61:"s",\u0161:"s",\u1e67:"s",\u1e63:"s",\u1e69:"s",\u0219:"s",\u015f:"s",\u023f:"s",\ua7a9:"s",\ua785:"s",\u1e9b:"s","\u24e3":"t",\uff54:"t",\u1e6b:"t",\u1e97:"t",\u0165:"t",\u1e6d:"t",\u021b:"t",\u0163:"t",\u1e71:"t",\u1e6f:"t",\u0167:"t",\u01ad:"t",\u0288:"t",\u2c66:"t",\ua787:"t",\ua729:"tz","\u24e4":"u",\uff55:"u",\u00f9:"u",\u00fa:"u",\u00fb:"u",\u0169:"u",\u1e79:"u",\u016b:"u",\u1e7b:"u",\u016d:"u",\u00fc:"u",\u01dc:"u",\u01d8:"u",\u01d6:"u",\u01da:"u",\u1ee7:"u",\u016f:"u",\u0171:"u",\u01d4:"u",\u0215:"u",\u0217:"u",\u01b0:"u",\u1eeb:"u",\u1ee9:"u",\u1eef:"u",\u1eed:"u",\u1ef1:"u",\u1ee5:"u",\u1e73:"u",\u0173:"u",\u1e77:"u",\u1e75:"u",\u0289:"u","\u24e5":"v",\uff56:"v",\u1e7d:"v",\u1e7f:"v",\u028b:"v",\ua75f:"v",\u028c:"v",\ua761:"vy","\u24e6":"w",\uff57:"w",\u1e81:"w",\u1e83:"w",\u0175:"w",\u1e87:"w",\u1e85:"w",\u1e98:"w",\u1e89:"w",\u2c73:"w","\u24e7":"x",\uff58:"x",\u1e8b:"x",\u1e8d:"x","\u24e8":"y",\uff59:"y",\u1ef3:"y",\u00fd:"y",\u0177:"y",\u1ef9:"y",\u0233:"y",\u1e8f:"y",\u00ff:"y",\u1ef7:"y",\u1e99:"y",\u1ef5:"y",\u01b4:"y",\u024f:"y",\u1eff:"y","\u24e9":"z",\uff5a:"z",\u017a:"z",\u1e91:"z",\u017c:"z",\u017e:"z",\u1e93:"z",\u1e95:"z",\u01b6:"z",\u0225:"z",\u0240:"z",\u2c6c:"z",\ua763:"z",\u0386:"\u0391",\u0388:"\u0395",\u0389:"\u0397",\u038a:"\u0399",\u03aa:"\u0399",\u038c:"\u039f",\u038e:"\u03a5",\u03ab:"\u03a5",\u038f:"\u03a9",\u03ac:"\u03b1",\u03ad:"\u03b5",\u03ae:"\u03b7",\u03af:"\u03b9",\u03ca:"\u03b9",\u0390:"\u03b9",\u03cc:"\u03bf",\u03cd:"\u03c5",\u03cb:"\u03c5",\u03b0:"\u03c5",\u03c9:"\u03c9",\u03c2:"\u03c3"},n.fnOperators={equal:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?n.toLowerCase(t)===n.toLowerCase(e):t===e},notequal:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),!n.fnOperators.equal(t,e,i)},lessthan:function(t,e,i){return i?n.toLowerCase(t)n.toLowerCase(e):t>e},lessthanorequal:function(t,e,i){return i?n.toLowerCase(t)<=n.toLowerCase(e):(m(t)&&(t=void 0),t<=e)},greaterthanorequal:function(t,e,i){return i?n.toLowerCase(t)>=n.toLowerCase(e):t>=e},contains:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?!m(t)&&!m(e)&&-1!==n.toLowerCase(t).indexOf(n.toLowerCase(e)):!m(t)&&!m(e)&&-1!==t.toString().indexOf(e)},doesnotcontain:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?!m(t)&&!m(e)&&-1===n.toLowerCase(t).indexOf(n.toLowerCase(e)):!m(t)&&!m(e)&&-1===t.toString().indexOf(e)},isnotnull:function(t){return null!=t},isnull:function(t){return null==t},startswith:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.startsWith(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.startsWith(t,e)},doesnotstartwith:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.notStartsWith(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.notStartsWith(t,e)},like:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.like(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.like(t,e)},isempty:function(t){return void 0===t||""===t},isnotempty:function(t){return void 0!==t&&""!==t},wildcard:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?(t||"boolean"==typeof t)&&e&&"object"!=typeof t&&n.wildCard(n.toLowerCase(t),n.toLowerCase(e)):(t||"boolean"==typeof t)&&e&&n.wildCard(t,e)},endswith:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.endsWith(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.endsWith(t,e)},doesnotendwith:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.notEndsWith(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.notEndsWith(t,e)},processSymbols:function(t){var e=n.operatorSymbols[t];return e?n.fnOperators[e]:n.throwError("Query - Process Operator : Invalid operator")},processOperator:function(t){return n.fnOperators[t]||n.fnOperators.processSymbols(t)}},n.parse={parseJson:function(t){return"string"!=typeof t||!/^[\s]*\[|^[\s]*\{(.)+:/g.test(t)&&-1!==t.indexOf('"')?t instanceof Array?n.parse.iterateAndReviveArray(t):"object"==typeof t&&null!==t&&n.parse.iterateAndReviveJson(t):t=JSON.parse(t,n.parse.jsonReviver),t},iterateAndReviveArray:function(t){for(var e=0;e-1||e.indexOf("z")>-1,o=e.split(/[^0-9.]/);if(s){if(o[5].indexOf(".")>-1){var a=o[5].split(".");o[5]=a[0],o[6]=new Date(e).getUTCMilliseconds().toString()}else o[6]="00";e=n.dateParse.toTimeZone(new Date(parseInt(o[0],10),parseInt(o[1],10)-1,parseInt(o[2],10),parseInt(o[3],10),parseInt(o[4],10),parseInt(o[5]?o[5]:"00",10),parseInt(o[6],10)),n.serverTimezoneOffset,!1)}else{var l=new Date(parseInt(o[0],10),parseInt(o[1],10)-1,parseInt(o[2],10),parseInt(o[3],10),parseInt(o[4],10),parseInt(o[5]?o[5]:"00",10)),h=parseInt(o[6],10),c=parseInt(o[7],10);if(isNaN(h)&&isNaN(c))return l;e.indexOf("+")>-1?l.setHours(l.getHours()-h,l.getMinutes()-c):l.setHours(l.getHours()+h,l.getMinutes()+c),e=n.dateParse.toTimeZone(l,n.serverTimezoneOffset,!1)}null==n.serverTimezoneOffset&&(e=n.dateParse.addSelfOffset(e))}}return e},isJson:function(t){return"string"==typeof t[0]?t:n.parse.parseJson(t)},isGuid:function(t){return null!=/[A-Fa-f0-9]{8}(?:-[A-Fa-f0-9]{4}){3}-[A-Fa-f0-9]{12}/i.exec(t)},replacer:function(t,e){return n.isPlainObject(t)?n.parse.jsonReplacer(t,e):t instanceof Array?n.parse.arrayReplacer(t):t instanceof Date?n.parse.jsonReplacer({val:t},e).val:t},jsonReplacer:function(t,e){for(var i,s=0,o=Object.keys(t);s=0?"+":"-",s=function(a){var l=Math.floor(Math.abs(a));return(l<10?"0":"")+l};return e.getFullYear()+"-"+s(e.getMonth()+1)+"-"+s(e.getDate())+"T"+s(e.getHours())+":"+s(e.getMinutes())+":"+s(e.getSeconds())+r+s(i/60)+":"+s(i%60)}},n}(),Ml=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),AK={GroupGuid:"{271bbba0-1ee7}"},t5=function(){function n(t){this.options={from:"table",requestType:"json",sortBy:"sorted",select:"select",skip:"skip",group:"group",take:"take",search:"search",count:"requiresCounts",where:"where",aggregates:"aggregates",expand:"expand"},this.type=n,this.dataSource=t,this.pvt={}}return n.prototype.processResponse=function(t,e,i,r){return t},n}(),YE=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ml(t,n),t.prototype.processQuery=function(e,i){for(var a,l,f,r=e.dataSource.json.slice(0),s=r.length,o=!0,h={},c=0,d=[],u=[],p=0;p1?e.sort.filter(function(f){return f.fieldName===c})[0]:e.sort[0];s=this.onSortBy(s,d,e.query,!0)}e.page&&(s=this.onPage(s,e.page,e.query)),this.formGroupResult(s,h)}else{for(var o=e.lazyLoad.onDemandGroupInfo,a=o.where.length-1;a>=0;a--)s=this.onWhere(s,o.where[a]);if(e.group.length!==o.level)s=le.group(s,e.group[o.level].fieldName,r,null,null,e.group[o.level].comparer,!0),e.sort.length&&(s=this.onSortBy(s,e.sort[parseInt(o.level.toString(),10)],e.query,!0));else for(a=e.sort.length-1;a>=o.level;a--)s=this.onSortBy(s,e.sort[parseInt(a.toString(),10)],e.query,!1);i=s.length,h=s,s=(s=s.slice(o.skip)).slice(0,o.take),e.group.length!==o.level&&this.formGroupResult(s,h)}return{result:s,count:i}},t.prototype.formGroupResult=function(e,i){if(e.length&&i.length){var r="GroupGuid",s="childLevels",o="level",a="records";e[r]=i[r],e[s]=i[s],e[o]=i[o],e[a]=i[a]}return e},t.prototype.getAggregate=function(e){var i=_t.filterQueries(e.queries,"onAggregates"),r=[];if(i.length)for(var s=void 0,o=0;o=0;l--)a[l]&&(o=i.comparer,le.endsWith(a[l]," desc")&&(o=le.fnSort("descending"),a[l]=a[l].replace(" desc","")),e=le.sort(e,a[l],o));return e}return le.sort(e,s?"key":a,i.comparer)},t.prototype.onGroup=function(e,i,r){if(!e||!e.length)return e;var s=this.getAggregate(r);return le.group(e,le.getValue(i.fieldName,r),s,null,null,i.comparer)},t.prototype.onPage=function(e,i,r){var s=le.getValue(i.pageSize,r),o=(le.getValue(i.pageIndex,r)-1)*s;return e&&e.length?e.slice(o,o+s):e},t.prototype.onRange=function(e,i){return e&&e.length?e.slice(le.getValue(i.start),le.getValue(i.end)):e},t.prototype.onTake=function(e,i){return e&&e.length?e.slice(0,le.getValue(i.nos)):e},t.prototype.onSkip=function(e,i){return e&&e.length?e.slice(le.getValue(i.nos)):e},t.prototype.onSelect=function(e,i){return e&&e.length?le.select(e,le.getValue(i.fieldNames)):e},t.prototype.insert=function(e,i,r,s,o){return m(o)?e.dataSource.json.push(i):e.dataSource.json.splice(o,0,i)},t.prototype.remove=function(e,i,r,s){var a,o=e.dataSource.json;for("object"==typeof r&&!(r instanceof Date)&&(r=le.getObject(i,r)),a=0;a1&&(g="("+g+")"),f.filters.push(g);for(var y=0,S="object"==typeof f.filters[p]?Object.keys(f.filters[p]):[];y-1&&this.formRemoteGroupedData(e[s].items,i+1,r-1);var o="GroupGuid",h="records";return e[o]=AK[o],e.level=i,e.childLevels=r,e[h]=e[0].items.length?this.getGroupedRecords(e,!m(e[0].items[h])):[],e},t.prototype.getGroupedRecords=function(e,i){for(var r=[],o=0;ol.length-3?(l=l.substring(0,l.length-1),o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.endswith:le.odv4UniOperator.endswith):l.lastIndexOf("%")!==l.indexOf("%")&&l.lastIndexOf("%")>l.indexOf("%")+1?(l=l.substring(l.indexOf("%")+1,l.lastIndexOf("%")),o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains):o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains),l="'"+(l=encodeURIComponent(l))+"'";else if("wildcard"===o)if(-1!==l.indexOf("*")){var d=l.split("*"),u=void 0,f=0;if(0!==l.indexOf("*")&&-1===d[0].indexOf("%3f")&&-1===d[0].indexOf("?")&&(u="'"+(u=d[0])+"'",s+=(o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.startswith:le.odv4UniOperator.startswith)+"(",s+=c+",",a&&(s+=a),s+=u+")",f++),l.lastIndexOf("*")!==l.length-1&&-1===d[d.length-1].indexOf("%3f")&&-1===d[d.length-1].indexOf("?")&&(u="'"+(u=d[d.length-1])+"'",f>0&&(s+=" and "),s+=(o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.endswith:le.odv4UniOperator.endswith)+"(",s+=c+",",a&&(s+=a),s+=u+")",f++),d.length>2)for(var p=1;p0&&(s+=" and "),"substringof"===(o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains)||"not substringof"===o){var g=u;u=c,c=g}s+=o+"(",s+=c+",",a&&(s+=a),s+=u+")",f++}0===f?(o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains,(-1!==l.indexOf("?")||-1!==l.indexOf("%3f"))&&(l=-1!==l.indexOf("?")?l.split("?").join(""):l.split("%3f").join("")),l="'"+l+"'"):o="wildcard"}else o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains,(-1!==l.indexOf("?")||-1!==l.indexOf("%3f"))&&(l=-1!==l.indexOf("?")?l.split("?").join(""):l.split("%3f").join("")),l="'"+l+"'";return"substringof"!==o&&"not substringof"!==o||(g=l,l=c,c=g),"wildcard"!==o&&(s+=o+"(",s+=c+",",a&&(s+=a),s+=l+")"),s},t.prototype.addParams=function(e){n.prototype.addParams.call(this,e),delete e.reqParams.params},t.prototype.onComplexPredicate=function(e,i,r){for(var s=[],o=0;o-1;f--)!/\bContent-ID:/i.test(c[f])||!/\bHTTP.+201/.test(c[f])||(l=parseInt(/\bContent-ID: (\d+)/i.exec(c[f])[1],10),o.addedRecords[l]&&(h=le.parse.parseJson(/^\{.+\}/m.exec(c[f])[0]),ze({},o.addedRecords[l],this.processResponse(h))));return o}return null},t.prototype.compareAndRemove=function(e,i,r){var s=this;return m(i)||Object.keys(e).forEach(function(o){o!==r&&"@odata.etag"!==o&&(le.isPlainObject(e[o])?(s.compareAndRemove(e[o],i[o]),0===Object.keys(e[o]).filter(function(l){return"@odata.etag"!==l}).length&&delete e[o]):(e[o]===i[o]||e[o]&&i[o]&&e[o].valueOf()===i[o].valueOf())&&delete e[o])}),e},t}(fc),LK=function(n){function t(){var e=n.call(this)||this;return yt("beforeSend",fc.prototype.beforeSend,e),e}return Ml(t,n),t.prototype.insert=function(e,i,r,s,o){return this.pvt.position=o,this.updateType="add",{url:e.dataSource.insertUrl||e.dataSource.crudUrl||e.dataSource.url,data:JSON.stringify(ze({},{value:i,table:r,action:"insert"},le.getAddParams(this,e,s)))}},t.prototype.remove=function(e,i,r,s,o){return n.prototype.remove.call(this,e,i,r),{type:"POST",url:e.dataSource.removeUrl||e.dataSource.crudUrl||e.dataSource.url,data:JSON.stringify(ze({},{key:r,keyColumn:i,table:s,action:"remove"},le.getAddParams(this,e,o)))}},t.prototype.update=function(e,i,r,s,o){return this.updateType="update",this.updateKey=i,{type:"POST",url:e.dataSource.updateUrl||e.dataSource.crudUrl||e.dataSource.url,data:JSON.stringify(ze({},{value:r,action:"update",keyColumn:i,key:r[i],table:s},le.getAddParams(this,e,o)))}},t.prototype.processResponse=function(e,i,r,s,o,a,l){var h;if(e="batch"===(o?JSON.parse(o.data):e).action?le.parse.parseJson(e):e,"add"===this.updateType&&n.prototype.insert.call(this,i,e,null,null,this.pvt.position),"update"===this.updateType&&n.prototype.update.call(this,i,this.updateKey,e),this.updateType=void 0,e.added)for(h=0;hi&&h.push(c)}for(c=0;cthis.pageSize;)h.results.splice(0,1),h.keys.splice(0,1);return window.localStorage.setItem(this.guidId,JSON.stringify(h)),e},t.prototype.beforeSend=function(e,i,r){!m(this.cacheAdaptor.options.batch)&&le.endsWith(r.url,this.cacheAdaptor.options.batch)&&"post"===r.type.toLowerCase()&&i.headers.set("Accept",this.cacheAdaptor.options.multipartAccept),e.dataSource.crossDomain||i.headers.set("Accept",this.cacheAdaptor.options.accept)},t.prototype.update=function(e,i,r,s){return this.isCrudAction=!0,this.cacheAdaptor.update(e,i,r,s)},t.prototype.insert=function(e,i,r){return this.isInsertAction=!0,this.cacheAdaptor.insert(e,i,r)},t.prototype.remove=function(e,i,r,s){return this.isCrudAction=!0,this.cacheAdaptor.remove(e,i,r,s)},t.prototype.batchRequest=function(e,i,r){return this.cacheAdaptor.batchRequest(e,i,r)},t}(fc),it=function(){function n(t,e,i){var s,r=this;return this.dateParse=!0,this.timeZoneHandling=!0,this.persistQuery={},this.isInitialLoad=!1,this.requests=[],this.isInitialLoad=!0,!t&&!this.dataSource&&(t=[]),i=i||t.adaptor,t&&!1===t.timeZoneHandling&&(this.timeZoneHandling=t.timeZoneHandling),t instanceof Array?s={json:t,offline:!0}:"object"==typeof t?(t.json||(t.json=[]),t.enablePersistence||(t.enablePersistence=!1),t.id||(t.id=""),t.ignoreOnPersist||(t.ignoreOnPersist=[]),s={url:t.url,insertUrl:t.insertUrl,removeUrl:t.removeUrl,updateUrl:t.updateUrl,crudUrl:t.crudUrl,batchUrl:t.batchUrl,json:t.json,headers:t.headers,accept:t.accept,data:t.data,timeTillExpiration:t.timeTillExpiration,cachingPageSize:t.cachingPageSize,enableCaching:t.enableCaching,requestType:t.requestType,key:t.key,crossDomain:t.crossDomain,jsonp:t.jsonp,dataType:t.dataType,offline:void 0!==t.offline?t.offline:!(t.adaptor instanceof LK||t.adaptor instanceof NK||t.url),requiresFormat:t.requiresFormat,enablePersistence:t.enablePersistence,id:t.id,ignoreOnPersist:t.ignoreOnPersist}):le.throwError("DataManager: Invalid arguments"),void 0===s.requiresFormat&&!le.isCors()&&(s.requiresFormat=!!m(s.crossDomain)||s.crossDomain),void 0===s.dataType&&(s.dataType="json"),this.dataSource=s,this.defaultQuery=e,this.dataSource.enablePersistence&&this.dataSource.id&&window.addEventListener("unload",this.setPersistData.bind(this)),s.url&&s.offline&&!s.json.length?(this.isDataAvailable=!1,this.adaptor=i||new vf,this.dataSource.offline=!1,this.ready=this.executeQuery(e||new _t),this.ready.then(function(o){r.dataSource.offline=!0,r.isDataAvailable=!0,s.json=o.result,r.adaptor=new YE})):this.adaptor=s.offline?new YE:new vf,!s.jsonp&&this.adaptor instanceof vf&&(s.jsonp="callback"),this.adaptor=i||this.adaptor,s.enableCaching&&(this.adaptor=new OK(this.adaptor,s.timeTillExpiration,s.cachingPageSize)),this}return Object.defineProperty(n.prototype,"moduleName",{get:function(){return"datamanager"},enumerable:!0,configurable:!0}),n.prototype.getPersistedData=function(t){var e=localStorage.getItem(t||this.dataSource.id);return JSON.parse(e)},n.prototype.setPersistData=function(t,e,i){localStorage.setItem(e||this.dataSource.id,JSON.stringify(i||this.persistQuery))},n.prototype.setPersistQuery=function(t){var e=this,i=this.getPersistedData();if(this.isInitialLoad&&i&&Object.keys(i).length){this.persistQuery=i,this.persistQuery.queries=this.persistQuery.queries.filter(function(s){if(e.dataSource.ignoreOnPersist&&e.dataSource.ignoreOnPersist.length&&s.fn&&e.dataSource.ignoreOnPersist.some(function(l){return s.fn===l}))return!1;if("onWhere"===s.fn){var o=s.e;if(o&&o.isComplex&&o.predicates instanceof Array){var a=o.predicates.map(function(l){if(l.predicates&&l.predicates instanceof Array){var h=l.predicates.map(function(v){return new Ss(v.field,v.operator,v.value,v.ignoreCase,v.ignoreAccent,v.matchCase)});return"and"===l.condition?Ss.and(h):Ss.or(h)}return new Ss(l.field,l.operator,l.value,l.ignoreCase,l.ignoreAccent,l.matchCase)});s.e=new Ss(a[0],o.condition,a.slice(1))}}return!0});var r=ze(new _t,this.persistQuery);return this.isInitialLoad=!1,r}return this.persistQuery=t,this.isInitialLoad=!1,t},n.prototype.setDefaultQuery=function(t){return this.defaultQuery=t,this},n.prototype.executeLocal=function(t){!this.defaultQuery&&!(t instanceof _t)&&le.throwError("DataManager - executeLocal() : A query is required to execute"),this.dataSource.json||le.throwError("DataManager - executeLocal() : Json data is required to execute"),this.dataSource.enablePersistence&&this.dataSource.id&&(t=this.setPersistQuery(t));var e=this.adaptor.processQuery(this,t=t||this.defaultQuery);if(t.subQuery){var i=t.subQuery.fromTable,r=t.subQuery.lookups,s=t.isCountRequired?e.result:e;r&&r instanceof Array&&le.buildHierarchy(t.subQuery.fKey,i,s,r,t.subQuery.key);for(var o=0;oli");z.classList.remove("json-parent");for(var j=0;j',W=ve.children[0].placeholder}return W}function Q(k,W,ve){!m(ve)&&""!==ve&&K(W,ve.split(" ")),!m(k)&&""!==k&&V(W,k.split(" "))}function oe(k,W,ve){if("multiselect"===ve||function Mo(k){if(!k)return!1;for(var W=k;W&&W!==document.body;){if("none"===window.getComputedStyle(W).display)return!1;W=W.parentElement}return!0}(k)){var Te="multiselect"===ve?k:k.clientWidth-parseInt(getComputedStyle(k,null).getPropertyValue("padding-left"),10);!m(W)&&!m(W.getElementsByClassName("e-float-text-content")[0])&&(W.getElementsByClassName("e-float-text-content")[0].classList.contains("e-float-text-overflow")&&W.getElementsByClassName("e-float-text-content")[0].classList.remove("e-float-text-overflow"),(Te0)for(var Ye=0;Ye<_e.length;Ye++)_e[parseInt(Ye.toString(),10)].addEventListener("mousedown",wo,!1),_e[parseInt(Ye.toString(),10)].addEventListener("mouseup",Ul,!1);else if(_e.length>0)for(Ye=0;Ye<_e.length;Ye++)_e[parseInt(Ye.toString(),10)].removeEventListener("mousedown",wo,this),_e[parseInt(Ye.toString(),10)].removeEventListener("mouseup",Ul,this)}function wo(){for(var W=this.parentElement;!W.classList.contains("e-input-group");)W=W.parentElement;!function Sa(k,W){!k.classList.contains("e-disabled")&&!k.querySelector("input").readOnly&&W.classList.add("e-input-btn-ripple")}(W,this)}function Ul(){var k=this;setTimeout(function(){k.classList.remove("e-input-btn-ripple")},500)}function mb(k,W){var ve=W("span",{className:k});return ve.classList.add("e-input-group-icon"),ve}function I_(k,W,ve,Te){var _e=m(Te)?Si:Te,Ye=mb(k,_e);W.classList.add("e-float-icon-left");var vi=W.querySelector(".e-input-in-wrap");if(m(vi)){vi=_e("span",{className:"e-input-in-wrap"}),ve.parentNode.insertBefore(vi,ve);var Gs=W.querySelectorAll(ve.tagName+" ~ *");vi.appendChild(ve);for(var ts=0;ts-1)if("class"===_e){var Ye=this.getInputValidClassList(k[""+_e]);""!==Ye&&V([W],Ye.split(" "))}else if("style"===_e){var vi=W.getAttribute(_e);vi=m(vi)?k[""+_e]:vi+k[""+_e],W.setAttribute(_e,vi)}else W.setAttribute(_e,k[""+_e])}},n.isBlank=function Hle(k){return!k||/^\s*$/.test(k)}}(Le||(Le={})),new RegExp("^(-)?(\\d*)$"),new RegExp("^[A-Za-z0-9._%+-]{1,}@[A-Za-z0-9._%+-]{1,}([.]{1}[a-zA-Z0-9]{2,}|[.]{1}[a-zA-Z0-9]{2,4}[.]{1}[a-zA-Z0-9]{2,4})$"),new RegExp("^([0-9]{4})-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])$"),new RegExp("^[0-9]*$"),new RegExp("^[+]?[0-9]{9,13}$"),new RegExp("^\\d{13,16}$");var me=function(){function n(t,e){this.width=t,this.height=e}return n.prototype.isEmpty=function(){return 0===this.height&&0===this.width},n.prototype.clone=function(){return new n(this.width,this.height)},n}(),xie=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),GB=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},R=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return xie(t,n),t.equals=function(e,i){return e===i||!(!e||!i)&&(!e||!i||e.x===i.x&&e.y===i.y)},t.isEmptyPoint=function(e){return!(e.x&&e.y)},t.transform=function(e,i,r){var s={x:0,y:0};return s.x=Math.round(100*(e.x+r*Math.cos(i*Math.PI/180)))/100,s.y=Math.round(100*(e.y+r*Math.sin(i*Math.PI/180)))/100,s},t.findLength=function(e,i){return Math.sqrt(Math.pow(e.x-i.x,2)+Math.pow(e.y-i.y,2))},t.findAngle=function(e,i){var r=Math.atan2(i.y-e.y,i.x-e.x);return r=180*r/Math.PI,(r%=360)<0&&(r+=360),r},t.distancePoints=function(e,i){return Math.sqrt(Math.pow(i.x-e.x,2)+Math.pow(i.y-e.y,2))},t.getLengthFromListOfPoints=function(e){for(var i=0,r=0;ri.y&&!r?o.y+=s:o.y-=s:e.y===i.y?e.xi.x&&!r?o.x+=s:o.x-=s:r?(a=this.findAngle(e,i),o=this.transform(e,a,s)):(a=this.findAngle(i,e),o=this.transform(i,a,s)),o},t.direction=function(e,i){return Math.abs(i.x-e.x)>Math.abs(i.y-e.y)?e.x0)for(var r=0;rt.right||this.top>t.bottom||this.bottom=t.right&&this.top<=t.top&&this.bottom>=t.bottom},n.prototype.containsPoint=function(t,e){return void 0===e&&(e=0),this.left-e<=t.x&&this.right+e>=t.x&&this.top-e<=t.y&&this.bottom+e>=t.y},n.toBounds=function(t){for(var e=new n,i=0,r=t;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},KB=function(n){if(n)switch(n.type){case"Linear":default:return II;case"Radial":return Bie}return II},Rie=function(){return function n(t,e,i,r){this.left=t,this.right=e,this.top=i,this.bottom=r}}(),Jn=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),rt([I(0)],t.prototype,"left",void 0),rt([I(0)],t.prototype,"right",void 0),rt([I(0)],t.prototype,"top",void 0),rt([I(0)],t.prototype,"bottom",void 0),t}(Ee),Hie=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),rt([I(45)],t.prototype,"angle",void 0),rt([I(5)],t.prototype,"distance",void 0),rt([I(.7)],t.prototype,"opacity",void 0),rt([I("lightgrey")],t.prototype,"color",void 0),t}(Ee),e3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),t.prototype.getClassName=function(){return"Stop"},rt([I("")],t.prototype,"color",void 0),rt([I(0)],t.prototype,"offset",void 0),rt([I(1)],t.prototype,"opacity",void 0),t}(Ee),bx=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),rt([Bt([],e3)],t.prototype,"stops",void 0),rt([I("None")],t.prototype,"type",void 0),rt([I("")],t.prototype,"id",void 0),t}(Ee),II=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),rt([I(0)],t.prototype,"x1",void 0),rt([I(0)],t.prototype,"x2",void 0),rt([I(0)],t.prototype,"y1",void 0),rt([I(0)],t.prototype,"y2",void 0),t}(bx),Bie=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),rt([I(0)],t.prototype,"cx",void 0),rt([I(0)],t.prototype,"cy",void 0),rt([I(0)],t.prototype,"fx",void 0),rt([I(0)],t.prototype,"fy",void 0),rt([I(50)],t.prototype,"r",void 0),t}(bx),Ll=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),rt([I("white")],t.prototype,"fill",void 0),rt([I("black")],t.prototype,"strokeColor",void 0),rt([I("")],t.prototype,"strokeDashArray",void 0),rt([I(1)],t.prototype,"strokeWidth",void 0),rt([I(1)],t.prototype,"opacity",void 0),rt([x0(KB)],t.prototype,"gradient",void 0),t}(Ee),t3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),rt([I("transparent")],t.prototype,"fill",void 0),t}(Ll),Xf=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),rt([I("black")],t.prototype,"color",void 0),rt([I("Arial")],t.prototype,"fontFamily",void 0),rt([I(12)],t.prototype,"fontSize",void 0),rt([I(!1)],t.prototype,"italic",void 0),rt([I(!1)],t.prototype,"bold",void 0),rt([I("CollapseSpace")],t.prototype,"whiteSpace",void 0),rt([I("WrapWithOverflow")],t.prototype,"textWrapping",void 0),rt([I("Center")],t.prototype,"textAlign",void 0),rt([I("None")],t.prototype,"textDecoration",void 0),rt([I("Wrap")],t.prototype,"textOverflow",void 0),rt([I("transparent")],t.prototype,"fill",void 0),t}(Ll),on=function(n){return n[n.Default=0]="Default",n[n.expandNode=2]="expandNode",n[n.interaction=4]="interaction",n[n.GroupingInProgress=8]="GroupingInProgress",n[n.GroupClipboardInProcess=16]="GroupClipboardInProcess",n[n.ClearObject=32]="ClearObject",n}(on||{}),ri=function(n){return n[n.Visible=1]="Visible",n[n.Hidden=2]="Hidden",n[n.Hover=4]="Hover",n[n.Connect=8]="Connect",n}(ri||{}),Kt=function(n){return n[n.None=0]="None",n[n.ShowHorizontalLines=1]="ShowHorizontalLines",n[n.ShowVerticalLines=2]="ShowVerticalLines",n[n.ShowLines=3]="ShowLines",n[n.SnapToHorizontalLines=4]="SnapToHorizontalLines",n[n.SnapToVerticalLines=8]="SnapToVerticalLines",n[n.SnapToLines=12]="SnapToLines",n[n.SnapToObject=16]="SnapToObject",n[n.All=31]="All",n}(Kt||{}),mr=function(n){return n[n.None=1]="None",n[n.ConnectorSourceThumb=2]="ConnectorSourceThumb",n[n.ConnectorTargetThumb=4]="ConnectorTargetThumb",n[n.ResizeSouthEast=8]="ResizeSouthEast",n[n.ResizeSouthWest=16]="ResizeSouthWest",n[n.ResizeNorthEast=32]="ResizeNorthEast",n[n.ResizeNorthWest=64]="ResizeNorthWest",n[n.ResizeEast=128]="ResizeEast",n[n.ResizeWest=256]="ResizeWest",n[n.ResizeSouth=512]="ResizeSouth",n[n.ResizeNorth=1024]="ResizeNorth",n[n.Rotate=2048]="Rotate",n[n.UserHandle=4096]="UserHandle",n[n.ToolTip=8192]="ToolTip",n[n.ResizeAll=2046]="ResizeAll",n[n.All=16382]="All",n}(mr||{}),qe=function(n){return n[n.None=1]="None",n[n.Select=2]="Select",n[n.Delete=4]="Delete",n[n.Drag=8]="Drag",n[n.DragSourceEnd=16]="DragSourceEnd",n[n.DragTargetEnd=32]="DragTargetEnd",n[n.DragSegmentThumb=64]="DragSegmentThumb",n[n.AllowDrop=128]="AllowDrop",n[n.Bridging=256]="Bridging",n[n.BridgeObstacle=512]="BridgeObstacle",n[n.InheritBridging=1024]="InheritBridging",n[n.PointerEvents=2048]="PointerEvents",n[n.Tooltip=4096]="Tooltip",n[n.InheritTooltip=8192]="InheritTooltip",n[n.Interaction=4218]="Interaction",n[n.ReadOnly=16384]="ReadOnly",n[n.LineRouting=32768]="LineRouting",n[n.InheritLineRouting=65536]="InheritLineRouting",n[n.ConnectToNearByNode=131072]="ConnectToNearByNode",n[n.ConnectToNearByPort=262144]="ConnectToNearByPort",n[n.ConnectToNearByElement=393216]="ConnectToNearByElement",n[n.InheritSegmentThumbShape=524288]="InheritSegmentThumbShape",n[n.InheritSegmentThumbSize=1048576]="InheritSegmentThumbSize",n[n.Default=2043454]="Default",n}(qe||{}),Nr=function(n){return n[n.ReadOnly=2]="ReadOnly",n[n.InheritReadOnly=4]="InheritReadOnly",n[n.Select=8]="Select",n[n.Drag=16]="Drag",n[n.Resize=32]="Resize",n[n.Rotate=64]="Rotate",n[n.Tooltip=128]="Tooltip",n[n.Interaction=120]="Interaction",n[n.None=0]="None",n}(Nr||{}),ie=function(n){return n[n.None=0]="None",n[n.Select=2]="Select",n[n.Drag=4]="Drag",n[n.Rotate=8]="Rotate",n[n.Shadow=16]="Shadow",n[n.PointerEvents=32]="PointerEvents",n[n.Delete=64]="Delete",n[n.InConnect=128]="InConnect",n[n.OutConnect=256]="OutConnect",n[n.Individual=512]="Individual",n[n.Expandable=1024]="Expandable",n[n.AllowDrop=2048]="AllowDrop",n[n.Inherit=78]="Inherit",n[n.ResizeNorthEast=4096]="ResizeNorthEast",n[n.ResizeEast=8192]="ResizeEast",n[n.ResizeSouthEast=16384]="ResizeSouthEast",n[n.ResizeSouth=32768]="ResizeSouth",n[n.ResizeSouthWest=65536]="ResizeSouthWest",n[n.ResizeWest=131072]="ResizeWest",n[n.ResizeNorthWest=262144]="ResizeNorthWest",n[n.ResizeNorth=524288]="ResizeNorth",n[n.Resize=1044480]="Resize",n[n.AspectRatio=1048576]="AspectRatio",n[n.Tooltip=2097152]="Tooltip",n[n.InheritTooltip=4194304]="InheritTooltip",n[n.ReadOnly=8388608]="ReadOnly",n[n.HideThumbs=16777216]="HideThumbs",n[n.AllowMovingOutsideLane=33554432]="AllowMovingOutsideLane",n[n.Default=5240814]="Default",n}(ie||{}),Xr=function(n){return n[n.None=0]="None",n[n.ElementIsPort=2]="ElementIsPort",n[n.ElementIsGroup=4]="ElementIsGroup",n[n.HorizontalLaneHeader=8]="HorizontalLaneHeader",n}(Xr||{}),bt=function(n){return n[n.Rotate=2]="Rotate",n[n.ConnectorSource=4]="ConnectorSource",n[n.ConnectorTarget=8]="ConnectorTarget",n[n.ResizeNorthEast=16]="ResizeNorthEast",n[n.ResizeEast=32]="ResizeEast",n[n.ResizeSouthEast=64]="ResizeSouthEast",n[n.ResizeSouth=128]="ResizeSouth",n[n.ResizeSouthWest=256]="ResizeSouthWest",n[n.ResizeWest=512]="ResizeWest",n[n.ResizeNorthWest=1024]="ResizeNorthWest",n[n.ResizeNorth=2048]="ResizeNorth",n[n.Default=4094]="Default",n}(bt||{}),nt=function(n){return n[n.None=1]="None",n[n.Bridging=2]="Bridging",n[n.UndoRedo=4]="UndoRedo",n[n.Tooltip=8]="Tooltip",n[n.UserInteraction=16]="UserInteraction",n[n.ApiUpdate=32]="ApiUpdate",n[n.PageEditable=48]="PageEditable",n[n.Zoom=64]="Zoom",n[n.PanX=128]="PanX",n[n.PanY=256]="PanY",n[n.Pan=384]="Pan",n[n.ZoomTextEdit=512]="ZoomTextEdit",n[n.Virtualization=1024]="Virtualization",n[n.LineRouting=2048]="LineRouting",n[n.Default=500]="Default",n}(nt||{}),ni=function(n){return n[n.None=0]="None",n[n.SingleSelect=1]="SingleSelect",n[n.MultipleSelect=2]="MultipleSelect",n[n.ZoomPan=4]="ZoomPan",n[n.DrawOnce=8]="DrawOnce",n[n.ContinuousDraw=16]="ContinuousDraw",n[n.Default=3]="Default",n}(ni||{}),Qa=function(n){return n[n.Self=1]="Self",n[n.Parent=2]="Parent",n}(Qa||{}),ft=function(n){return n[n.None=0]="None",n[n.Control=1]="Control",n[n.Meta=1]="Meta",n[n.Alt=2]="Alt",n[n.Shift=4]="Shift",n}(ft||{}),Mt=function(n){return n[n.None=null]="None",n[n.Number0=0]="Number0",n[n.Number1=1]="Number1",n[n.Number2=2]="Number2",n[n.Number3=3]="Number3",n[n.Number4=4]="Number4",n[n.Number5=5]="Number5",n[n.Number6=6]="Number6",n[n.Number7=7]="Number7",n[n.Number8=8]="Number8",n[n.Number9=9]="Number9",n[n.A=65]="A",n[n.B=66]="B",n[n.C=67]="C",n[n.D=68]="D",n[n.E=69]="E",n[n.F=70]="F",n[n.G=71]="G",n[n.H=72]="H",n[n.I=73]="I",n[n.J=74]="J",n[n.K=75]="K",n[n.L=76]="L",n[n.M=77]="M",n[n.N=78]="N",n[n.O=79]="O",n[n.P=80]="P",n[n.Q=81]="Q",n[n.R=82]="R",n[n.S=83]="S",n[n.T=84]="T",n[n.U=85]="U",n[n.V=86]="V",n[n.W=87]="W",n[n.X=88]="X",n[n.Y=89]="Y",n[n.Z=90]="Z",n[n.Left=37]="Left",n[n.Up=38]="Up",n[n.Right=39]="Right",n[n.Down=40]="Down",n[n.Escape=27]="Escape",n[n.Space=32]="Space",n[n.PageUp=33]="PageUp",n[n.PageDown=34]="PageDown",n[n.End=35]="End",n[n.Home=36]="Home",n[n.Delete=46]="Delete",n[n.Tab=9]="Tab",n[n.Enter=13]="Enter",n[n.BackSpace=8]="BackSpace",n[n.F1=112]="F1",n[n.F2=113]="F2",n[n.F3=114]="F3",n[n.F4=115]="F4",n[n.F5=116]="F5",n[n.F6=117]="F6",n[n.F7=118]="F7",n[n.F8=119]="F8",n[n.F9=120]="F9",n[n.F10=121]="F10",n[n.F11=122]="F11",n[n.F12=123]="F12",n[n.Star=56]="Star",n[n.Plus=187]="Plus",n[n.Minus=189]="Minus",n[n.BracketLeft=219]="BracketLeft",n[n.BracketRight=221]="BracketRight",n}(Mt||{}),ee=function(n){return n[n.Render=2]="Render",n[n.PublicMethod=4]="PublicMethod",n[n.ToolAction=8]="ToolAction",n[n.UndoRedo=16]="UndoRedo",n[n.TextEdit=32]="TextEdit",n[n.Group=64]="Group",n[n.Clear=128]="Clear",n[n.PreventClearSelection=256]="PreventClearSelection",n[n.Interactions=512]="Interactions",n[n.PreventHistory=1024]="PreventHistory",n[n.PreventIconsUpdate=2048]="PreventIconsUpdate",n[n.PreventCollectionChangeOnDragOver=4096]="PreventCollectionChangeOnDragOver",n[n.PreventZIndexOnDragging=8192]="PreventZIndexOnDragging",n[n.isGroupDragging=16384]="isGroupDragging",n[n.DragUsingMouse=32768]="DragUsingMouse",n[n.DecoratorPropertyChange=65536]="DecoratorPropertyChange",n[n.PreventLaneContainerUpdate=131072]="PreventLaneContainerUpdate",n}(ee||{}),Ga=function(n){return n[n.None=2]="None",n[n.DrawSelectorBorder=4]="DrawSelectorBorder",n[n.PreventRenderSelector=8]="PreventRenderSelector",n}(Ga||{}),$i=function(n){return n[n.None=0]="None",n[n.PreventDrag=2]="PreventDrag",n[n.PreventScale=4]="PreventScale",n[n.PreventDataInit=8]="PreventDataInit",n[n.hScrollbarMoved=16]="hScrollbarMoved",n[n.vScrollbarMoved=32]="vScrollbarMoved",n[n.AnimationClick=64]="AnimationClick",n[n.EnableGroupAction=128]="EnableGroupAction",n[n.PanInProgress=256]="PanInProgress",n[n.OverViewAction=512]="OverViewAction",n}($i||{}),da=function(n){return n[n.None=0]="None",n[n.PropertyChange=1024]="PropertyChange",n[n.Interaction=2048]="Interaction",n}(da||{}),Ae=function(n){return n[n.Zero=0]="Zero",n[n.One=1]="One",n[n.Two=2]="Two",n[n.Three=3]="Three",n[n.Four=4]="Four",n[n.Five=5]="Five",n}(Ae||{}),Ce=function(n){return n[n.collectionChange=0]="collectionChange",n[n.rotateChange=1]="rotateChange",n[n.positionChange=2]="positionChange",n[n.propertyChange=3]="propertyChange",n[n.selectionChange=4]="selectionChange",n[n.sizeChange=5]="sizeChange",n[n.drop=6]="drop",n[n.sourcePointChange=7]="sourcePointChange",n[n.targetPointChange=8]="targetPointChange",n[n.connectionChange=9]="connectionChange",n[n.animationComplete=10]="animationComplete",n[n.click=11]="click",n[n.doubleClick=12]="doubleClick",n[n.scrollChange=13]="scrollChange",n[n.dragEnter=14]="dragEnter",n[n.dragLeave=15]="dragLeave",n[n.dragOver=16]="dragOver",n[n.textEdit=17]="textEdit",n[n.paletteSelectionChange=18]="paletteSelectionChange",n[n.historyChange=19]="historyChange",n[n.mouseEnter=20]="mouseEnter",n[n.mouseLeave=21]="mouseLeave",n[n.mouseOver=22]="mouseOver",n[n.expandStateChange=23]="expandStateChange",n[n.segmentCollectionChange=24]="segmentCollectionChange",n[n.commandExecute=25]="commandExecute",n[n.historyStateChange=26]="historyStateChange",n[n.onUserHandleMouseDown=27]="onUserHandleMouseDown",n[n.onUserHandleMouseUp=28]="onUserHandleMouseUp",n[n.onUserHandleMouseEnter=29]="onUserHandleMouseEnter",n[n.onUserHandleMouseLeave=30]="onUserHandleMouseLeave",n[n.onImageLoad=31]="onImageLoad",n[n.onDoBindingInit=32]="onDoBindingInit",n[n.keyUp=33]="keyUp",n[n.keyDown=34]="keyDown",n[n.fixedUserHandleClick=35]="fixedUserHandleClick",n[n.elementDraw=36]="elementDraw",n[n.mouseWheel=37]="mouseWheel",n[n.segmentChange=38]="segmentChange",n[n.onFixedUserHandleMouseDown=39]="onFixedUserHandleMouseDown",n[n.onFixedUserHandleMouseUp=40]="onFixedUserHandleMouseUp",n[n.onFixedUserHandleMouseEnter=41]="onFixedUserHandleMouseEnter",n[n.onFixedUserHandleMouseLeave=42]="onFixedUserHandleMouseLeave",n[n.loaded=43]="loaded",n}(Ce||{}),ai=function(n){return n[n.None=1]="None",n[n.Drag=2]="Drag",n[n.Draw=4]="Draw",n[n.InConnect=8]="InConnect",n[n.OutConnect=16]="OutConnect",n[n.ToolTip=32]="ToolTip",n[n.InheritTooltip=64]="InheritTooltip",n[n.Default=24]="Default",n}(ai||{}),Mx=function(n){return n[n.None=1]="None",n[n.Source=2]="Source",n[n.Target=4]="Target",n[n.Intermediate=8]="Intermediate",n[n.All=14]="All",n}(Mx||{}),bI=function(n){return n[n.None=0]="None",n[n.SymmetricAngle=2]="SymmetricAngle",n[n.SymmetricDistance=4]="SymmetricDistance",n[n.Default=6]="Default",n}(bI||{}),hs=function(){function n(){this.pivot={x:.5,y:.5},this.isDirt=!0,this.isExport=!1,this.exportScaleValue={x:0,y:0},this.exportScaleOffset={x:0,y:0},this.canApplyStyle=!0,this.visible=!0,this.offsetX=0,this.offsetY=0,this.cornerRadius=0,this.minHeight=void 0,this.minWidth=void 0,this.maxWidth=void 0,this.maxHeight=void 0,this.width=void 0,this.height=void 0,this.rotateAngle=0,this.margin={left:0,right:0,top:0,bottom:0},this.connectionDirection="Auto",this.horizontalAlignment="Auto",this.verticalAlignment="Auto",this.flip="None",this.flipMode="All",this.relativeMode="Point",this.transform=Qa.Self|Qa.Parent,this.style={fill:"white",strokeColor:"black",opacity:1,strokeWidth:1},this.desiredSize=new me,this.actualSize=new me,this.parentTransform=0,this.preventContainer=!1,this.isSvgRender=!1,this.bounds=new Ne(0,0,0,0),this.shadow=null,this.description="",this.staticSize=!1,this.shapeType="",this.isRectElement=!1,this.isCalculateDesiredSize=!0,this.flipOffset={x:0,y:0},this.elementActions=Xr.None,this.inversedAlignment=!0,this.position=void 0,this.unitMode=void 0,this.float=!1,this.floatingBounds=void 0}return n.prototype.setOffsetWithRespectToBounds=function(t,e,i){this.unitMode=i,this.position={x:t,y:e}},n.prototype.getAbsolutePosition=function(t){if(void 0!==this.position)return"Absolute"===this.unitMode?this.position:{x:this.position.x*t.width,y:this.position.y*t.height}},Object.defineProperty(n.prototype,"outerBounds",{get:function(){return this.floatingBounds||this.bounds},set:function(t){this.floatingBounds=t},enumerable:!0,configurable:!0}),n.prototype.measure=function(t,e,i){var s=void 0!==this.height?this.height:(t.height||0)-this.margin.top-this.margin.bottom;return this.id&&0===s&&this.elementActions&Xr.HorizontalLaneHeader&&(s=this.actualSize.height),this.desiredSize=new me(void 0!==this.width?this.width:(t.width||0)-this.margin.left-this.margin.right,s),this.isCalculateDesiredSize&&(this.desiredSize=this.validateDesiredSize(this.desiredSize,t)),this.desiredSize},n.prototype.arrange=function(t){return this.actualSize=t,this.updateBounds(),this.actualSize},n.prototype.updateBounds=function(){this.bounds=yr(this)},n.prototype.validateDesiredSize=function(t,e){return this.isRectElement&&!this.width&&!this.minWidth&&!this.maxWidth&&(t.width=50),this.isRectElement&&!this.height&&!this.minHeight&&!this.maxHeight&&(t.height=50),(void 0===t||void 0!==this.width&&void 0!==this.height)&&((t=t||new me).width=void 0===this.width?(e.width||0)-this.margin.left-this.margin.right:this.width,t.height=void 0===this.height?(e.height||0)-this.margin.top-this.margin.bottom:this.height),void 0!==this.minWidth&&(t.width=Math.max(t.width,this.minWidth)),void 0!==this.minHeight&&(t.height=Math.max(t.height,this.minHeight)),void 0!==this.maxWidth&&0!==this.maxWidth&&(t.width=Math.min(t.width,this.maxWidth)),void 0!==this.maxHeight&&0!==this.maxHeight&&(t.height=Math.min(t.height,this.maxHeight)),t},n}(),Yie=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Cs=function(n){function t(){var e=null!==n&&n.apply(this,arguments)||this;return e.padding=new Rie(0,0,0,0),e.desiredBounds=void 0,e.measureChildren=!0,e.prevRotateAngle=0,e}return Yie(t,n),t.prototype.hasChildren=function(){return void 0!==this.children&&this.children.length>0},t.prototype.measure=function(e,i,r){this.desiredBounds=void 0;var o,a,s=void 0;if(this.hasChildren()){for(var l=0;l=n.width&&s.length>0)i[i.length]={text:s,x:0,dy:0,width:o},s="";else{(s+=a[r+1]||"").indexOf("\n")>-1&&(i[i.length]={text:s,x:0,dy:0,width:Bc(s,n)},s="");var l=Bc(s,n);Math.ceil(l)+2>=n.width&&s.length>0&&(i[i.length]={text:s,x:0,dy:0,width:l},s=""),r===a.length-1&&s.length>0&&(i[i.length]={text:s,x:0,dy:0,width:l},s="")}else i=function coe(n,t,e){var c,d,u,f,i=[],r="",s=0,o=0,a="nowrap"!==n.whiteSpace,h=(t||n.content).split("\n");for(s=0;s0?" ":"")+c[parseInt(o.toString(),10)];var p=Bc(d=c[o+1]?r+" "+c[o+1]:r,n);Math.floor(p)>(e||n.width)-2&&r.length>0?(i[i.length]={text:r,x:0,dy:0,width:d===r?p:r===f?u:Bc(r,n)},r=""):o===c.length-1&&(i[i.length]={text:r,x:0,dy:0,width:p},r=""),f=d,u=p}return i}(n,t,e);else i[i.length]={text:a,x:0,dy:0,width:Bc(a,n)};return i}(l,r,n.isLaneOrientation?i:void 0),n.wrapBounds=a=function doe(n,t){var r,s,e={x:0,width:0},i=0;for(i=0;in.width&&("Ellipsis"===n.textOverflow||"Clip"===n.textOverflow)?0:-r/2:"right"===n.textAlign?-r:t.length>1?0:-r/2,t[parseInt(i.toString(),10)].dy=1.2*n.fontSize,t[parseInt(i.toString(),10)].x=r,e.x=Math.min(e.x,r),e.width=Math.max(e.width,s);return e}(l,o),s.width=a.width,n.wrapBounds.width>=i&&"Wrap"!==l.textOverflow&&(s.width=i),s.height=o.length*n.style.fontSize*1.2,s}(this,0,0,this.isLaneOrientation?e.height:this.width||e.width):this.desiredSize,this.desiredSize=void 0===this.width||void 0===this.height?new me(i.width,i.height):new me(this.width,this.height),this.desiredSize=this.validateDesiredSize(this.desiredSize,e),this.desiredSize},t.prototype.arrange=function(e){return(e.width!==this.actualSize.width||e.height!==this.actualSize.height||this.isDirt)&&(this.doWrap=!0),this.actualSize=e,this.updateBounds(),this.isDirt=!1,this.actualSize},t}(hs),Gie=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Mi=function(n){function t(){var e=null!==n&&n.apply(this,arguments)||this;return e.measureChildren=void 0,e}return Gie(t,n),t.prototype.measure=function(e,i,r){var s=void 0,o=void 0;if(this.hasChildren()){for(var a=0,l=this.children;a=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Dd=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Jie(t,n),Oh([I("")],t.prototype,"content",void 0),Oh([I("TopLeft")],t.prototype,"position",void 0),Oh([I("Mouse")],t.prototype,"relativeMode",void 0),Oh([I(!0)],t.prototype,"showTipPointer",void 0),Oh([I("auto")],t.prototype,"width",void 0),Oh([I("auto")],t.prototype,"height",void 0),Oh([I("Auto")],t.prototype,"openOn",void 0),Oh([I()],t.prototype,"animation",void 0),Oh([I(!1)],t.prototype,"isSticky",void 0),t}(Ee);function i3(n){var t=new bh;t=r3(n.tooltip,t);var e=new bh(t);return e.beforeCollision=ere,e.beforeOpen=Kie,e.cssClass="e-diagram-tooltip",e.opensOn="custom",e.appendTo("#"+n.element.id),e.close(),e}function Kie(n){(""===this.content||void 0===this.content)&&(n.element.style.display="none")}function ere(n){n.collidedPosition&&n.collidedPosition!==this.position&&(n.element.style.display="none")}function wx(n,t){var e=n.tooltipObject;return r3(t?t.tooltip:n.tooltip,e),e}function r3(n,t){return n.content?(t.content=n.content,"string"==typeof n.content&&(t.content=ko(function(){return n.content})),t.position=n.position,t.showTipPointer=n.showTipPointer,t.width=n.width,t.height=n.height,t.animation=n.animation?n.animation:{close:{effect:"None"}}):t.close(),t}var Cx=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Bn=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Ex=function(n){function t(e,i,r,s){var o=n.call(this,e,i,r,s)||this;return o.inEdges=[],o.outEdges=[],o}return Cx(t,n),Bn([I("")],t.prototype,"id",void 0),Bn([I("Center")],t.prototype,"horizontalAlignment",void 0),Bn([I("Center")],t.prototype,"verticalAlignment",void 0),Bn([re({},Jn)],t.prototype,"margin",void 0),Bn([I(12)],t.prototype,"width",void 0),Bn([I(12)],t.prototype,"height",void 0),Bn([re({},Ll)],t.prototype,"style",void 0),Bn([I("Square")],t.prototype,"shape",void 0),Bn([I("Auto")],t.prototype,"connectionDirection",void 0),Bn([I(ri.Connect)],t.prototype,"visibility",void 0),Bn([I("")],t.prototype,"pathData",void 0),Bn([I(ai.Default)],t.prototype,"constraints",void 0),Bn([I()],t.prototype,"addInfo",void 0),Bn([I()],t.prototype,"outEdges",void 0),Bn([I()],t.prototype,"inEdges",void 0),Bn([re({},Dd)],t.prototype,"tooltip",void 0),t}(Ee),Es=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return Cx(t,n),t.prototype.getClassName=function(){return"PointPort"},Bn([re({x:.5,y:.5},R)],t.prototype,"offset",void 0),t}(Ex),Tc=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return Cx(t,n),t.prototype.getClassName=function(){return"PathPort"},Bn([I(.5)],t.prototype,"offset",void 0),Bn([re({x:0,y:0},R)],t.prototype,"displacement",void 0),Bn([I("Center")],t.prototype,"alignment",void 0),t}(Ex),CI=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),lr=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},tre=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return CI(t,n),lr([I("blue")],t.prototype,"color",void 0),lr([I("")],t.prototype,"content",void 0),lr([I("")],t.prototype,"link",void 0),lr([I("None")],t.prototype,"textDecoration",void 0),lr([I("NewTab")],t.prototype,"hyperlinkOpenState",void 0),t}(Ee),Dx=function(n){function t(e,i,r,s){var o=n.call(this,e,i,r,s)||this;return r.id||(o.id=e.parentObj&&e.parentObj.propName&&"phases"===e.parentObj.propName?e.parentObj.id:Qe()),o}return CI(t,n),lr([I("")],t.prototype,"content",void 0),lr([I(void 0)],t.prototype,"template",void 0),lr([I("String")],t.prototype,"annotationType",void 0),lr([I(!0)],t.prototype,"visibility",void 0),lr([I(Nr.InheritReadOnly)],t.prototype,"constraints",void 0),lr([re(void 0,tre)],t.prototype,"hyperlink",void 0),lr([I("")],t.prototype,"id",void 0),lr([I()],t.prototype,"width",void 0),lr([I()],t.prototype,"height",void 0),lr([I(0)],t.prototype,"rotateAngle",void 0),lr([I("Parent")],t.prototype,"rotationReference",void 0),lr([re({strokeWidth:0,strokeColor:"transparent",fill:"transparent"},Xf)],t.prototype,"style",void 0),lr([I("Center")],t.prototype,"horizontalAlignment",void 0),lr([I("Center")],t.prototype,"verticalAlignment",void 0),lr([re({},Jn)],t.prototype,"margin",void 0),lr([re({top:void 0,bottom:void 0,left:void 0,right:void 0},Jn)],t.prototype,"dragLimit",void 0),lr([I("Shape")],t.prototype,"type",void 0),lr([re({},Dd)],t.prototype,"tooltip",void 0),lr([I()],t.prototype,"addInfo",void 0),t}(Ee),Kn=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return CI(t,n),t.prototype.getClassName=function(){return"ShapeAnnotation"},lr([re({x:.5,y:.5},R)],t.prototype,"offset",void 0),t}(Dx),Or=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return CI(t,n),t.prototype.getClassName=function(){return"PathAnnotation"},lr([I(.5)],t.prototype,"offset",void 0),lr([re({x:0,y:0},R)],t.prototype,"displacement",void 0),lr([I("Center")],t.prototype,"alignment",void 0),lr([I(!1)],t.prototype,"segmentAngle",void 0),t}(Dx);function xx(n){return sre[n.toString()]}function n3(n){return lre[""+n]}var sre={X:"M14,14 L106,106 M106,14 L14,106",Circle:"M0,50 A50,50,0 1 1 100,50 A50,50,0 1 1 0,50 Z",Square:"M0,0 L10,0 L10,10 L0,10 z"},ore={OpenArrow:"M15.9,23 L5,16 L15.9,9 L17,10.7 L8.7,16 L17,21.3Z",Square:"M0,0 L10,0 L10,10 L0,10 z",Fletch:"M14.8,10c0,0-3.5,6,0.2,12c0,0-2.5-6-10.9-6C4.1,16,11.3,16,14.8,10z",OpenFetch:"M6,17c-0.6,0-1-0.4-1-1s0.4-1,1-1c10.9,0,11-5,11-5c0-0.6,0.4-1,1-1s1,0.4,1,1C19,10.3,18.9,17,6,17C6,17,6,17,6,17z M18,23c-0.5,0-1-0.4-1-1c0-0.2-0.3-5-11-5c-0.6,0-1-0.5-1-1s0.4-1,1-1c0,0,0,0,0,0c12.9,0,13,6.7,13,7 C19,22.6,18.6,23,18,23z",IndentedArrow:"M17,10c0,0-4.5,5.5,0,12L5,16L17,10z",OutdentedArrow:"M14.6,10c0,0,5.4,6,0,12L5,16L14.6,10z",DoubleArrow:"M19,10 L19,22 L13,16Z M12,10 L12,22 L6,16Z",Arrow:"M15,10 L15,22 L5,16Z",Diamond:"M12,23l-7-7l7-7l6.9,7L12,23z",Circle:"M0,50 A50,50,0 1 1 100,50 A50,50,0 1 1 0,50 Z"},are={Square:"M0,0 L10,0 L10,10 L0,10 z",Rhombus:"M10,5 L5,10 L0,5 L5,0 L10,5 Z ",Rectangle:"M0,0 L15,0 L15,10 L0,10 z ",OpenArrow:"M15.9,23 L5,16 L15.9,9 L17,10.7 L8.7,16 L17,21.3Z",Fletch:"M9.82,0 C9.82,0,6.61,5,10,10 C10,10,7.71,5,0,5 C0,5,6.61,5,9.82,0 Z ",OpenFetch:"M0.71,5.71 C0.29,5.71,0,5.43,0,5 C0,4.57,0.29,4.29,0.71,4.29 C8.5,4.29,8.57,0.71,8.57,0.71 C8.57,0.29,8.86,0,9.29,0 C9.719999999999999,0,10,0.29,10,0.71 C10,0.93,9.93,5.71,0.71,5.71 C0.71,5.71,0.71,5.71,0.71,5.71 Z M9.29,10 C8.93,10,8.57,9.71,8.57,9.29 C8.57,9.14,8.36,5.71,0.71,5.71 C0.29,5.71,0,5.36,0,5 C0,4.64,0.29,4.29,0.71,4.29 C0.71,4.29,0.71,4.29,0.71,4.29 C9.93,4.29,10,9.07,10,9.29 C10,9.71,9.71,10,9.29,10 Z ",IndentedArrow:"M10,0 C10,0,6.25,4.58,10,10 L0,5 L10,0 Z ",OutdentedArrow:"M8,0 C8,0,12.5,5,8,10 L0,5 L8,0 Z ",DoubleArrow:"M19,10 L19,22 L13,16Z M12,10 L12,22 L6,16Z",Arrow:"M15,10 L15,22 L5,16Z",Diamond:"M10,5 L5,10 L0,5 L5,0 L10,5 Z ",Circle:"M10,5 C10,7.76,7.76,10,5,10 C2.24,10,0,7.76,0,5 C0,2.24,2.24,0,5,0 C7.76,0,10,2.24,10,5 Z ",Ellipse:"M15,5 C15,7.76,11.64,10,7.5,10 C3.36,10,0,7.76,0,5 C0,2.24,3.36,0,7.5,0 C11.64,0,15,2.24,15,5 Z "},lre={Square:"M0,0 L10,0 L10,10 L0,10 z",Rhombus:"M10,5 L5,10 L0,5 L5,0 L10,5 Z ",Rectangle:"M0,0 L15,0 L15,10 L0,10 z",OpenArrow:"M23,15.9 L16,5 L9,15.9 L10.7,17 L16,8.7 L21,17.3Z",Fletch:"M9.82,0 C9.82,0,6.61,5,10,10 C10,10,7.71,5,0,5 C0,5,6.61,5,9.82,0 Z ",OpenFetch:"M0.71,5.71 C0.29,5.71,0,5.43,0,5 C0,4.57,0.29,4.29,0.71,4.29 C8.5,4.29,8.57,0.71,8.57,0.71 C8.57,0.29,8.86,0,9.29,0 C9.719999999999999,0,10,0.29,10,0.71 C10,0.93,9.93,5.71,0.71,5.71 C0.71,5.71,0.71,5.71,0.71,5.71 Z M9.29,10 C8.93,10,8.57,9.71,8.57,9.29 C8.57,9.14,8.36,5.71,0.71,5.71 C0.29,5.71,0,5.36,0,5 C0,4.64,0.29,4.29,0.71,4.29 C0.71,4.29,0.71,4.29,0.71,4.29 C9.93,4.29,10,9.07,10,9.29 C10,9.71,9.71,10,9.29,10 Z ",IndentedArrow:"M10,0 C10,0,6.25,4.58,10,10 L0,5 L10,0 Z ",OutdentedArrow:"M8,0 C8,0,12.5,5,8,10 L0,5 L8,0 Z ",DoubleArrow:"M10,19 L22,19 L16,13Z M10,12 L22,12 L16,6Z",Arrow:"M10,15 L22,15 L16,5Z",Diamond:"M10,5 L5,10 L0,5 L5,0 L10,5 Z ",Circle:"M10,5 C10,7.76,7.76,10,5,10 C2.24,10,0,7.76,0,5 C0,2.24,2.24,0,5,0 C7.76,0,10,2.24,10,5 Z ",Ellipse:"M15,5 C15,7.76,11.64,10,7.5,10 C3.36,10,0,7.76,0,5 C0,2.24,3.36,0,7.5,0 C11.64,0,15,2.24,15,5 Z "};function Tx(n){return hre[n.toString()]}var hre={Process:"M419.511,76.687L359.511,76.687L359.511,43.086L419.511,43.086z",Decision:"M 253.005,115.687L 200.567,146.071L 148.097,115.687L 200.534,85.304L 253.005,115.687 Z",Document:"M 60 31.9 c 0 0 -11 -7.7 -30 0 s -30 0 -30 0 V 0 h 60 V 31.9 Z",PreDefinedProcess:"M 0,0 L 50,0 L 50,50 L 0,50 Z M 8.334,0 L 8.334,50 M 41.667,0 L 41.667,50",Terminator:"M 269.711,29.33C 269.71,44.061 257.77,56 243.04,56L 158.058,56C 143.33,56 131.39,44.061 131.39,29.33L 131.39,29.33C 131.391,14.6057 143.33,2.669 158.058,2.669L 243.044,2.669C 257.772,2.669 269.711,14.6057 269.711,29.333 Z",PaperTap:"M0.0009,17.2042 L0.0009,47.165 C0.001,47.165 14.403,53.5455 25.00,47.165 C35.599,40.7852 44.403,43.5087 50.00,47.165L50.001,17.2042 M50.001,32.7987 L50.001,2.8405 C50.001,2.8405 35.599,-3.5427 25.001,2.8405C14.403,9.2237 5.599,6.494 0.0009,2.8405 L0.0009,32.7987",DirectData:"M 132.62 0 L 17.38 0 C 7.78 0 0 13.43 0 30 C 0 46.57 7.78 60 17.38 60 L 132.62 60 M 132.62 0C 123.02 0 115.24 13.43 115.24 30 C 115.24 46.57 123.02 60 132.62 60 C 142.22 60 150 46.57 150 30 C 150 13.43 142.22 0 132.62 0 z ",SequentialData:"M0.0029,24.999 C0.0029,11.1922 10.433,0.0021 23.295,0.0021 C36.159,0.00216 46.585,11.1922 46.585,24.999C46.585,38.8057 36.159,49.9979 23.295,49.9979 C10.433,49.9979 0.0029,38.8057 0.0029,24.999 z M23.294,49.999 L50.002,49.999",Sort:"M50.001,24.9971 L25.001,49.9971 L0.00097,24.9971 L25.001,-0.00286865 L50.001,24.9971 z M0.000976562,24.9971 L50.001,24.9971",MultiDocument:"M43.6826,40 C44.8746,40.6183 45.8586,41.3502 46.8366,42.1122 L46.8366,4.74487 L3.09857,4.74487 L3.09857,10.9544 M46.837,35.143 C48.027,35.765 49.025,36.604 50.003,37.369 L50.003,0.002 L6.264,0.002 L6.264,4.744 M43.682,47.113 L43.682,10.765 L0.0025,10.7652 L0.0025,47.1132 C0.0025,47.1132 12.5846,53.6101 21.8426,47.1132 C31.1006,40.6163 38.792,43.393 43.6826,47.1132 z",Collate:"M50.001,0.0028 L25.001,25.0029 L0.00097,0.0028 L50.001,0.002 z M0.0009,50.002 L25.001,25.002L50.001,50.002 L0.0009,50.0029 z",SummingJunction:"M7.3252,42.6768 L42.6772,7.3247 M42.6768,42.6768 L7.3248,7.3247 M0.0009,25.001 C0.0009,11.193 11.197,0.0009 25.001,0.0009 C38.809,0.0009 50.001,11.193 50.001,25.001 C50.001,38.809 38.809,50.001 25.001,50.001 C11.197,50.00 0.0009,38.809 0.0009,25.00 z",Or:"M 0 50 L 100 50 M 50 100 L 50 0.0 M 0 50 C 0 22.384 22.392 0 50 0 C 77.616 0 100 22.384 100 50 C 100 77.616 77.616 100 50 100 C 22.392 100 0 77.616 0 50 Z",InternalStorage:"M 0 3.81946A 2.5,3.81946 0 0,1 2.5,0L 47.5 0A 2.5,3.81946 0 0,1 50,3.81946L 50 45.836A 2.5,3.819446 0 0,1 47.5,49.652778L 2.5 49.652778A 2.5,3.819446 0 0,1 0,45.8336L 0 3.819446ZM 0 11.45834L 50 11.4583334M 12.5 0L 12.5 49.652778",Extract:"M0,35 L30,0 L60,35 Z",ManualOperation:"M46.4,28.8 L14.8,28.8 L0,0 L60,0 Z",Merge:"M60,0 L30,35 L0,0 Z",OffPageReference:"M60,33.3 L30.1,39 L0,33.3 L0,0 L60,0 Z",SequentialAccessStorage:"M 60 30 C 60 13.4 46.6 0 30 0 S 0 13.4 0 30 s 13.4 30 30 30 h 28.6 v -6.5 h -9.9C 55.5 48 60 39.5 60 30 Z",Annotation:"M49.9984,50.0029 L-0.00271199,50.0029 L-0.00271199,0.00286865 L49.9984,0.00286865",Annotation2:"M49.9977,50.0029 L25.416,50.0029 L25.416,0.00286865 L49.9977,0.00286865 M25.4166,25.0029 L-0.00227869,25.0029",Data:"M 10 0 L 40 0 L 30 40 L 0 40 Z",Card:"M275,60 L400,60 L400,110 L260,110 L260,75 Z",Delay:"M0,0 L12.029,0 C14.212999,0 16,1.7869979 16,3.9709952 C16,6.1549926 14.212999,7.9409904 12.029,7.9409904 L0,7.9409904 z",Preparation:"M 1048.17 572 C 1051.06 568.86 1055.17 567.05 1059.5 567 L 1094.51 567 C 1098.84 567.05 1102.95 568.86 1105.84 572 L 1126.43 595 C 1127.01 596.28 1127.01 597.72 1126.43 599 L 1105.84 622 C 1102.95 625.14 1098.84 626.95 1094.51 627 L 1059.5 627 C 1055.17 626.95 1051.06 625.14 1048.17 622 L 1027.58 599 C 1027 597.72 1027 596.28 1027.58 595 L 1048.17 572 Z",Display:"M47.8809,19.2914 L32.7968,-0.00594145 L11.3902,-0.00594145 C7.93166,-0.00594145 0.00124586,11.187 0.00124586,24.9968C0.00124586,38.8032 7.93166,49.9962 11.3902,49.9962 L32.7968,49.99 L47.615,31.038 C47.615,31.0388 52.798,24.9968 47.880,19.2914 z",ManualInput:"M 912 732 L 1006.85 707 C 1008.2 707 1009.5 707.53 1010.46 708.46 C 1011.41 709.4 1011.95 710.67 1011.95 712 L 1011.95 762C 1012 764.41 1010.28 766.52 1007.87 767 L 917.1 767 C 915.75 767 914.45 766.47 913.49 765.54 C 912.54 764.6 912 763.33 912 762 L 912 732 Z",LoopLimit:"M 8 9 L 27 9 L 33 15 L 33 26 C 33 27 33 27 32 27 L 4 27 C 3 27 2 27 2 26 L 2 15 L 8 9 Z",StoredData:"M 5.55 0L 50 0A 1.5,30 0 0,1 50,0A 5.555,25 0 0,0 50,50A 1.5,30 0 0,1 50,50L 5.555 50A 5.55,25 0 0,1 5.555,0Z"};function s3(n,t,e){var i;i="Straight"!==n.type&&n.sourceWrapper?n.sourceWrapper.corners.center:function cre(n){var t;if(n.sourcePortWrapper){var e=n.sourcePortWrapper;t={x:e.offsetX,y:e.offsetY}}else t=n.sourceID&&n.sourceWrapper&&n.targetWrapper?qa(n,0,n.sourceWrapper.corners.center,n.targetWrapper.corners.center,!1):n.sourcePoint;return t}(n);var r=function ure(n,t,e,i,r){var b,M,s=n.sourceWrapper,o=n.targetWrapper,a=n.sourcePortWrapper,l=n.targetPortWrapper,d=[],p=Xa(n),y={corners:undefined,point:t,direction:undefined,margin:{left:5,right:5,bottom:5,top:5}},S={corners:undefined,point:e,direction:undefined,margin:{left:5,right:5,bottom:5,top:5}};if(void 0!==s&&void 0!==o&&(b=xn(s),M=xn(o),y.corners=s.corners,S.corners=o.corners),void 0!==a&&(y.direction="Left"===a.connectionDirection||"Top"===a.connectionDirection||"Bottom"===a.connectionDirection||"Right"===a.connectionDirection?a.connectionDirection:zo({x:a.offsetX,y:a.offsetY},b,s.bounds)),void 0!==l&&(S.direction="Left"===l.connectionDirection||"Right"===l.connectionDirection||"Bottom"===l.connectionDirection||"Top"===l.connectionDirection?l.connectionDirection:zo({x:l.offsetX,y:l.offsetY},M,o.bounds)),"Bezier"===n.type&&!n.isBezierEditing&&n.segments.length>0)for(var D=n.segments.length-1;D>=0;)n.segments[parseInt(D.toString(),10)].isInternalSegment&&n.segments.pop(),D--;if(void 0!==s&&void 0!==o)return(void 0===y.direction||void 0===S.direction)&&(i?function dre(n,t,e){"LeftToRight"===e?(n.direction=n.direction?n.direction:"Right",t.direction=t.direction?t.direction:"Left"):"RightToLeft"===e?(n.direction=n.direction?n.direction:"Left",t.direction=t.direction?t.direction:"Right"):"TopToBottom"===e?(n.direction=n.direction?n.direction:"Bottom",t.direction=t.direction?t.direction:"Top"):"BottomToTop"===e&&(n.direction=n.direction?n.direction:"Top",t.direction=t.direction?t.direction:"Bottom")}(y,S,i):y.corners.top>S.corners.bottom&&Math.abs(y.corners.top-S.corners.bottom)>p?(y.direction=y.direction?y.direction:"Top",S.direction=S.direction?S.direction:"Bottom"):y.corners.bottomp?(y.direction=y.direction?y.direction:"Bottom",S.direction=S.direction?S.direction:"Top"):y.corners.rightp||y.corners.right+p=y.corners.left-p&&y.corners.left>S.corners.left?(y.direction=y.direction?y.direction:"Right",S.direction=S.direction?S.direction:"Left"):y.corners.left>S.corners.right&&Math.abs(y.corners.left-S.corners.right)>y.margin.left+y.margin.right||S.corners.right+p=S.corners.left-p&&y.corners.left0&&n.segments[0].direction&&(y.direction=n.segments[0].direction),y.point=Nl(b,y.direction),d=Nl(b,_n(y.direction)),y.point=qa(n,0,y.point,d,!1)):y.point=o.corners.center;if(void 0!==h){switch(S.point={x:h.offsetX,y:h.offsetY},S.direction){case"Bottom":case"Top":S.point.y=S.point.y;break;case"Left":case"Right":S.point.x=S.point.x}n.targetPadding&&!w&&(S.point=EI(n,y,S,!0))}else"Orthogonal"===n.type||"Bezier"===n.type?(S.point=Nl(M,S.direction),d=Nl(M,_n(S.direction)),S.point=qa(n,0,S.point,d,!0)):S.point=a.corners.center;if("Orthogonal"!==n.type){var C=void 0,D=void 0;if("Bezier"===n.type){if(n.bezierSettings.allowSegmentsReset||0===n.segments.length||!R.isEmptyPoint(n.segments[n.segments.length-1].point))return c=g3(n,y,S,void 0,s),Ax(n,y,S);Bv(n)}else Bv(n);if(void 0===n.sourcePortWrapper){y.point=y.corners.center,n.segments&&n.segments.length>0&&(C=R.isEmptyPoint((D=n.segments[0]).point)?void 0:D);var A=void 0!==C?C.point:S.point;if("Bezier"===n.type&&n.segments.length>0&&n.segments[0].vector1.angle&&n.segments[0].vector1.distance){var x=Math.max(y.corners.width,y.corners.height);A=R.transform(y.point,n.segments[0].vector1.angle,x/2)}y.point=w?n.sourceWrapper.bounds.center:qa(n,0,y.point,A,!1)}if(void 0===n.targetPortWrapper){S.point=S.corners.center,n.segments&&n.segments.length>1&&(C=R.isEmptyPoint((D=n.segments[n.segments.length-2]).point)?void 0:D);var P=C?C.point:y.point;"Bezier"===n.type&&n.segments.length>0&&n.segments[n.segments.length-1].vector2.angle&&n.segments[n.segments.length-1].vector2.distance&&(x=Math.max(y.corners.width,y.corners.height),P=R.transform(S.point,n.segments[0].vector2.angle,x/2)),S.point=w?n.targetWrapper.bounds.center:qa(n,0,P,S.point,!0)}c=Ax(n,y,S)}else"Orthogonal"===n.type&&n.segments&&n.segments.length>0&&null!==n.segments[0].direction?c=function Mre(n,t,e,i,r,s,o){var a,h,c,d;Bv(n);for(var u=0;u0&&n.segments[u-1].direction===h.direction?u=u3(n,u,t):h.direction?t.point=o3(t,n.segments[parseInt(u.toString(),10)]):(f=n.segments[u-1])&&f.points&&f.points.length>0&&(t.point=f.points[f.points.length-1]),u===n.segments.length-1)if(f3(n,t),c3(a=void 0===r?bre(n,t,e):l3(n,t,e),n),h.points=[],a.length>=2)for(c=0;c2&&n.segments.length>2){var p={x:a[parseInt(c.toString(),10)].x,y:t.point.y};h.points=[],h.points.push(p),h.points.push(a[parseInt(c.toString(),10)]);var f=n.segments[u-1];n.segments.length<4&&f.points.pop(),f.points=f.points.concat(h.points)}else h.points.push(a[parseInt(c.toString(),10)]);else h.points.push(a[parseInt(c.toString(),10)]);else d=u;if(void 0!==d&&!n.selectedSegmentIndex&&(d===n.segments.length-1&&(n.segments[d-1].direction=null,n.segments[d-1].length=null),n.segments.splice(d,1)),i&&0===u){var g=h3(n,i,s);g&&(t.point=g)}}return p3(n,[])}(n,y,S,l,h,o):(n.segments[0]||(C=new wi(n,"segments",{type:"Orthogonal"},!0),n.segments.push(C)),n.segments[0].points=c=g3(n,y,S,void 0,s));return c}(n,y.direction,S.direction,y.point,S.point,r);if(Bv(n),(n.sourceWrapper||n.targetWrapper)&&function mre(n,t,e){var i=n.sourcePortWrapper,r=n.targetPortWrapper,s=n.sourceWrapper,o=t.point,a={left:0,right:0,top:0,bottom:0},l={x:0,y:0},c="Top";if(s?(o=e.point,a=t.margin):(s=n.targetWrapper,a=e.margin),"Orthogonal"===n.type)if(n.segments&&n.segments.length>0&&n.sourceWrapper&&n.segments[0].direction)t.direction=n.segments[0].direction,l=qa(n,0,l=Nl(s.corners,t.direction),Nl(s.corners,_n(t.direction)),!1);else{var u={corners:null,direction:null,point:null,margin:null};Fv(s,{corners:null,direction:null,point:o,margin:a},u,n),l=u.point,c=u.direction}else{var f=void 0;n.segments&&n.segments.length>1&&(f=s===n.sourceWrapper?n.segments[0].point:n.segments[n.segments.length-2].point),l=qa(n,0,s.bounds.center,n.segments&&n.segments.length>1?f:o,s===n.targetWrapper)}s===n.sourceWrapper?(t.direction=t.direction||c,t.point=l,n.sourcePortWrapper&&(t.point={x:i.offsetX,y:i.offsetY},n.sourcePadding&&(t.point=EI(n,t,e,!1)))):(e.direction=e.direction||c,e.point=l,n.targetPortWrapper&&(e.point={x:r.offsetX,y:r.offsetY},n.targetPadding&&(e.point=EI(n,t,e,!0))))}(n,y,S),"Straight"===n.type||"Bezier"===n.type)d=Ax(n,y,S);else if("Orthogonal"===n.type&&n.segments&&n.segments.length>0&&null!==n.segments[0].length&&null!==n.segments[0].direction)d=function vre(n,t,e,i,r,s,o){var a,l,c,u,h=[];if(Bv(n),n.segments.length>0){for(var f=0;f0&&n.segments[f-1].direction===p.direction)f=u3(n,f,t);else{var g=n.segments[f-1];t.point=p.direction?o3(t,p):g.points[g.points.length-1]}if(f===n.segments.length-1&&(o||r?n.targetWrapper&&void 0===n.targetPortWrapper?(f3(n,t),l=pre(n,t,e)):l=l3(n,t,e):l=fre(n,t,e),l))if(c3(l,n),p.points=[],l.length>=2)for(a=0;at.corners.top&&e.point.ye.point.x?"Left":"Right"):e.point.x>t.corners.left&&e.point.xe.point.y?"Top":"Bottom")),n.sourcePortWrapper&&s===_n(r)?(("Left"===s||"Right"===s)&&t.point.y>=t.corners.top&&t.point.y<=t.corners.center.y&&e.point.y>=t.corners.top&&e.point.y<=t.corners.center.y?(t.direction="Top",a=t.point.y-t.corners.top+20):("Left"===s||"Right"===s)&&t.point.y>t.corners.center.y&&t.point.y<=t.corners.bottom&&e.point.y>t.corners.center.y&&e.point.y<=t.corners.bottom?(t.direction="Bottom",a=t.corners.bottom-t.point.y+20):("Top"===s||"Bottom"===s)&&t.point.x>=t.corners.left&&t.point.x<=t.corners.center.x&&e.point.x>=t.corners.left&&e.point.x<=t.corners.center.x?(t.direction="Left",a=t.point.x-t.corners.left+20):("Top"===s||"Bottom"===s)&&t.point.x<=t.corners.right&&t.point.x>t.corners.center.x&&e.point.x<=t.corners.right&&e.point.xt.point.y&&t.point.y>=e.corners.top?(i="Top",r=t.point.y-e.corners.top+20):e.corners.center.y===t.point.y&&"Top"===n.segments[n.segments.length-2].direction||e.corners.center.ye.point.y?t.point.y-t.corners.top+20:t.corners.bottom-t.point.y+20):(i="Top",r=e.corners.height/2+20):e.corners.center.x!==t.point.x||e.corners.topt.point.x&&t.point.x>=e.corners.left?(i="Left",r=t.point.x-e.corners.left+20):e.corners.center.x===t.point.x&&"Left"===n.segments[n.segments.length-2].direction||e.corners.center.x<=t.point.x&&t.point.x<=e.corners.right?(i="Right",r=e.corners.right-t.point.x+20):void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&t.corners.left<=t.point.x&&t.point.x<=t.corners.right&&(i=t.direction,r=t.point.x>e.point.x?t.point.x-t.corners.left+20:t.corners.right-t.point.x+20):(i="Left",r=e.corners.width/2+20);var a=t.point;t.point=Fn(t.point,"Left"===i||"Top"===i?-r:r,"Left"===i||"Right"===i?0:90),t.direction=R.direction(t.point,e.point),void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&(t.corners.center.x===e.corners.center.x||t.corners.center.y===e.corners.center.y)&&(t.direction=e.direction);var l=Ys(n,t,e);return l.splice(0,0,a),l}function l3(n,t,e){var i,r;e.corners=n.targetWrapper.corners,void 0!==n.sourcePortWrapper&&(r=zo({x:n.sourcePortWrapper.offsetX,y:n.sourcePortWrapper.offsetY},xn(n.sourceWrapper),n.sourceWrapper.bounds));var a=function gre(n,t,e,i){var r=!1;switch(e.direction){case"Left":void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&"Right"===i&&t.point.x>e.point.x&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom||("Bottom"===i&&t.point.y>e.point.y||"Top"===i&&t.point.y=t.corners.left&&t.point.x<=t.corners.right?(t.direction="Right"===i?t.point.y>e.point.y?"Top":"Bottom":t.point.xe.point.x&&(t.point.y>e.point.y||t.point.yt.point.y&&e.corners.bottome.point.y||t.point.x>e.point.x&&t.point.y<=e.point.y&&e.corners.top=t.point.y?t.direction="Top":t.point.xe.point.x&&t.point.y>e.point.y&&e.corners.bottomt.point.y?t.direction="Bottom":t.point.y===e.point.y&&t.point.xe.point.y||"Top"===i&&t.point.ye.point.x&&t.point.x>=t.corners.left&&t.point.x<=t.corners.right?(t.direction=t.point.x>e.point.x?"Left":"Right",r=!0):void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&"Left"===i&&t.point.x=t.corners.top&&t.point.y<=t.corners.bottom?(t.direction=t.point.y>e.point.y?"Top":"Bottom",r=!0):t.point.x=t.point.y&&t.point.y===e.point.y||t.point.y>e.point.y&&t.point.x>e.point.x?t.direction="Top":t.point.ye.point.x?t.direction="Bottom":t.point.xe.point.y||t.point.ye.point.x&&(t.direction="Left");break;case"Top":void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&"Bottom"===i&&t.point.y>e.point.y&&t.point.x>=t.corners.left&&t.point.x<=t.corners.right||("Right"===i&&t.point.x>e.point.x||"Left"===i&&e.point.y>t.point.y&&e.point.x>t.point.x)&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom?(t.direction="Bottom"===i?t.point.x>e.point.x?"Left":"Right":t.point.ye.point.y&&t.point.x>e.corners.left&&t.point.x=e.point.y?t.direction="Top":t.point.ye.point.x?t.direction="Left":t.point.yt.point.x)&&t.point.y>e.point.y&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom||"Top"===i&&t.point.y=t.corners.left&&t.point.x<=t.corners.right)?(t.direction="Right"===i||"Left"===i?t.point.y>e.point.y?"Top":"Bottom":t.point.x>e.point.x?"Left":"Right",r=!0):t.point.ye.corners.left&&e.corners.right>t.point.x?t.point.ye.corners.left&&e.corners.center.x>=t.point.x?t.direction="Left":t.point.ye.point.y&&t.point.x>e.point.x?t.direction="Left":t.point.y>e.point.y&&t.point.xe.point.x||e.point.x>t.point.x)&&(t.direction="Bottom")}return r}(n,t,e,r);return!n.selectedSegmentIndex&&void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&e.direction===_n(r)&&(("Left"===e.direction&&t.point.x>e.point.x||"Right"===e.direction&&t.point.x=t.corners.top&&t.point.y<=t.corners.bottom||"Bottom"===e.direction&&t.point.y=t.corners.left&&t.point.x<=t.corners.right)?i=a3(n,t,e):n.selectedSegmentIndex||t.direction!==e.direction?!n.selectedSegmentIndex&&("Left"===e.direction&&t.point.x>e.point.x||"Right"===e.direction&&t.point.x=t.point.y||"Top"===e.direction&&t.point.y>e.point.y||"Bottom"===e.direction&&t.point.y=t.point.x?i=n.selectedSegmentIndex?Ol(t,e):a3(n,t,e):!n.selectedSegmentIndex&&void 0!==n.sourceWrapper&&void 0!==n.targetWrapper&&void 0!==n.targetPortWrapper&&("Left"===t.direction||"Right"===t.direction)&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom&&("Top"===e.direction||"Bottom"===e.direction)&&e.corners.center.x===t.corners.center.x?(t.direction="Top"===e.direction?"Bottom":"Top",i=Ys(n,t,e,"Top"===e.direction?t.corners.bottom-t.point.y+20:t.point.y-t.corners.top+20)):!n.selectedSegmentIndex&&void 0!==n.sourceWrapper&&void 0!==n.targetWrapper&&void 0!==n.targetPortWrapper&&("Top"===t.direction||"Bottom"===t.direction)&&t.point.x>=t.corners.left&&t.point.x<=t.corners.right&&("Left"===e.direction||"Right"===e.direction)&&e.corners.center.y===t.corners.center.y?(t.direction="Left"===e.direction?"Right":"Left",i=Ys(n,t,e,"Left"===e.direction?t.corners.right-t.point.x+20:t.point.x-t.corners.left+20)):i=a?Ys(n,t,e,"Left"===t.direction||"Right"===t.direction?"Left"===t.direction?t.point.x-t.corners.left+20:t.corners.right-t.point.x+20:"Top"===t.direction?t.point.y-t.corners.top+20:t.corners.bottom-t.point.y+20):Ol(t,e):i=Ys(n,t,e),i}function h3(n,t,e){var r,i={x:t.offsetX,y:t.offsetY},s=xn(e),o=zo(i,s,e.bounds),a=n.segments[0];return a.direction!==o&&(function wre(n,t,e,i,r,s){var a,h,o=13,l=[];l.push(i),i.y===r.y&&("Left"===t&&r.xi.x)||i.x===r.x&&("Top"===t&&r.yi.y)||("Top"===t||"Bottom"===t?"Top"===t&&r.yi.y-o||"Bottom"===t&&r.y>i.y&&r.yo&&("Top"===t&&r.yi.y)?l.push({x:i.x,y:r.y}):(a=r.xi.x-o||"right"===t&&r.x>i.x&&r.xo&&("Left"===t&&r.xi.x)?l.push({x:r.x,y:i.y}):(l.push({x:a="Left"===t?e.left-o:e.right+o,y:i.y}),l.push({x:a,y:r.y})),s&&(l.push(n.points[0]),l.reverse()),n.points=l)}(a,o,s,a.points[0],a.points[a.points.length-1],!1),r=a.points[a.points.length-1],a.direction=R.direction(a.points[a.points.length-2],a.points[a.points.length-1])),r}function c3(n,t,e){var s,i=t.segments[t.segments.length-2],r=i.points[i.points.length-1];(("Top"===i.direction||"Bottom"===i.direction)&&r.x===n[1].x||("Left"===i.direction||"Right"===i.direction)&&r.y===n[1].y)&&(i.points[i.points.length-1]=n[1],s=R.direction(i.points[0],i.points[i.points.length-1]),void 0!==t.sourceWrapper&&void 0===t.sourcePortWrapper&&s===_n(i.direction)&&("Left"===i.direction||"Right"===i.direction?i.points[0].x="Right"===i.direction?i.points[0].x-t.sourceWrapper.corners.width:i.points[0].x+t.sourceWrapper.corners.width:i.points[0].y="Bottom"===i.direction?i.points[0].y-t.sourceWrapper.corners.height:i.points[0].y+t.sourceWrapper.corners.height),i.direction=s,i.length=R.distancePoints(i.points[0],i.points[i.points.length-1]),n.splice(0,1))}function EI(n,t,e,i){var o=i?n.targetPadding:n.sourcePadding,a=i?n.targetPortWrapper:n.sourcePortWrapper,l=new Ne(a.bounds.x-o,a.bounds.y-o,a.actualSize.width+2*o,a.actualSize.height+2*o),h=[l.topLeft,l.topRight,l.bottomRight,l.bottomLeft];h[h.length]=h[0];var d=i?e.point:t.point;return Nx({x1:t.point.x,y1:t.point.y,x2:e.point.x,y2:e.point.y},h,0,d)||d}function d3(n,t){var e=[],i=dF(0,n.corners,t);i.push(i[0]);for(var r=0;r0){var r=void 0,s=[],o=t.point;for(r=0;r1&&R.equals(a.points[0],a.points[1])&&n.segments.splice(r,1),a)for(var l=0;l0||0===r)&&i.push(a.points[parseInt(l.toString(),10)])}}return i}function Lx(n,t,e){return"Top"===n||"Bottom"===n?e.x>t.x?"Right":"Left":e.y>t.y?"Bottom":"Top"}function Bv(n){if("Straight"===n.type||"Bezier"===n.type){if(0===n.segments.length||n.segments.length>0&&!R.isEmptyPoint(n.segments[n.segments.length-1].point))if("Bezier"===n.type){var t=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0},!0);n.segments.push(t)}else t=new Hl(n,"segments",{type:"Straight"},!0),n.segments.push(t)}else{if(n.segments.length>0)for(var e=!1,i=0;i=t.corners.left&&e.point.x<=t.corners.right&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom)t.direction=e.point.y>t.point.y?"Bottom":"Top",i=Ys(n,t,e,"Top"===t.direction?t.point.y-t.corners.top+20:t.corners.bottom-t.point.y+20);else if(n.sourcePortWrapper&&r===_n(o)){var h;("Left"===r||"Right"===r)&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom?(t.direction=e.point.y>t.point.y?"Bottom":"Top",h=t.corners.height/2+20):("Top"===r||"Bottom"===r)&&t.point.x>=t.corners.left&&t.point.x<=t.corners.right&&(t.direction=e.point.x>t.point.x?"Right":"Left",h=t.corners.width/2+20),t.direction&&h?i=Ys(n,t,e,h,!0):(t.direction=o,i=Ol(t,e))}else if(!n.sourcePortWrapper||r!==e.direction||"Top"!==r&&"Bottom"!==r||t.corners.center.x!==e.corners.center.x)if(t.direction===e.direction)if(("Left"===t.direction||"Right"===t.direction)&&e.point.y>t.corners.top-20&&e.point.yt.corners.left-20&&e.point.xt.point.y?"Bottom":"Top",i=Ys(n,t,e,"Bottom"===t.direction?t.corners.bottom-t.point.y+20:t.point.y-t.corners.top+20);else t.direction=o,i=Ys(n,t,e,"Top"===o||"Bottom"===o?n.sourceWrapper.height/2+20:n.sourceWrapper.width/2+20),t.point=i[1],"Left"===o||"Right"===o?(e.direction=o,e.point="Left"===o?e.corners.middleLeft:e.corners.middleRight):Fv(n.targetWrapper,t,e,n),i=Ys(n,t,e);return i}function f3(n,t){if(void 0!==n.targetWrapper&&void 0===n.targetPortWrapper&&xn(n.targetWrapper).containsPoint(t.point,1)){var i=n.targetWrapper,r=n.segments[n.segments.length-2],s=r.points[r.points.length-1],o=_n(r.direction);"Bottom"===o?s.yi.corners.top-1&&(r.points[r.points.length-1].y=i.corners.top-20,r.length=R.distancePoints(r.points[0],r.points[r.points.length-1])):"Left"===o?s.x>i.corners.left-1&&(r.points[r.points.length-1].x=i.corners.left-20,r.length=R.distancePoints(r.points[0],r.points[r.points.length-1])):"Right"===o&&s.x0||0===e)&&t.push(i.points[parseInt(r.toString(),10)]);return t}function Fv(n,t,e,i){var r,s={x:0,y:0},o=DI(n,n.corners,n.bounds),a=t.margin,l=t.point;if(o.bottomCenter.y+a.bottoml.y)r="Top",s=o.topCenter;else if(o.middleLeft.x-a.left>l.x)r="Left",s=o.middleLeft;else if(o.middleRight.x+a.rightc&&(f=c,r="Right",s=o.middleRight),f>d&&(f=d,r="Bottom",s=o.bottomCenter),f>u&&(r="Left",s=o.middleLeft)}e.point=s,e.direction=r;var p=Nl(o,_n(e.direction));e.point=qa(i,0,e.point,p,n===i.targetWrapper)}function g3(n,t,e,i,r){var s,o,a;if(s=function Hre(n,t){var e=!1;switch(n){case"Left":switch(t){case"Right":case"Bottom":e=!0}break;case"Top":switch(t){case"Left":case"Right":case"Bottom":e=!0}break;case"Bottom":"Right"===t&&(e=!0)}return e}(t.direction,e.direction),s&&b3(t,e),"Right"===t.direction&&"Left"===e.direction)a=function Cre(n,t,e,i){var o=Math.round(Math.abs(t.point.y-e.point.y)),a={x:Math.max(t.point.x,t.corners.right),y:t.point.y},l={x:Math.min(e.point.x,e.corners.left),y:e.point.y},h=Xa(n);if(i){var c=l;l=a,a=c}return t.corners.bottom+he.corners.bottom+h||("Bezier"!==n.type||e.corners.left-t.corners.right<=2*h&&e.corners.left-t.corners.right>=5)&&(h=0),t.margin={left:h,right:h,top:h,bottom:h},e.margin={left:h,right:h,top:h,bottom:h},0===o&&(t.corners.right=e.corners.right?void 0!==i&&(i.offsetYe.corners.bottom+e.margin.bottom)||void 0===i&&t.corners.middleRight.ye.corners.bottom+e.margin.bottom&&t.corners.top>e.corners.bottom||void 0===i&&t.corners.middleRight.y>e.corners.bottom||void 0!==i&&i.offsetYe.corners.top||void 0===i&&t.corners.middleRight.y>e.corners.bottom?Ae.Three:t.corners.rightr.offsetY+e.margin.right||void 0===r&&t.corners.top>e.corners.middleRight.y||void 0!==r&&(void 0!==i&&i.offsetXr.offsetX||void 0===r&&t.corners.left>e.corners.topCenter.x?Ae.Four:Ae.Two:void 0!==s&&Math.abs(t.corners.right-e.corners.left)<=5&&Math.abs(s.offsetY-e.corners.top)<=5||void 0!==r&&t.corners.right=25&&t.corners.middleRight.y+t.margin.righte.corners.bottom+e.margin.bottom||void 0===o&&t.corners.middleRight.y>e.corners.bottom+e.margin.bottom?t.corners.top>e.corners.bottom?void 0!==a&&t.corners.right+t.margin.righta.offsetX||void 0===a&&t.corners.left>e.corners.bottomCenter.x?Ae.Four:Ae.Two:void 0!==o&&Math.abs(t.corners.right-e.corners.left)<=25&&Math.abs(o.offsetY-e.corners.bottom)<=25?Ae.Two:Ae.Four}(n,t,e,s);else if("Bottom"===t.direction&&"Top"===e.direction)a=function Tre(n,t,e){var r=t.point.x-e.point.x,s=Xa(n);return t.corners.right+se.corners.right+s||("Bezier"!==n.type||e.corners.top-t.corners.bottom<=2*s&&e.corners.top-t.corners.bottom>=5)&&(s=0),t.margin={left:s,right:s,top:s,bottom:s},e.margin={left:s,right:s,top:s,bottom:s},0===r&&t.corners.bottome.corners.right+e.margin.right||void 0===i&&t.corners.bottomCenter.x>e.corners.right+e.margin.right?Ae.Three:t.corners.bottomr.offsetX||void 0===r&&t.corners.left>e.corners.left||void 0!==r&&t.corners.right+t.margin.righte.corners.bottom?Ae.Five:0===s||0===o?Ae.One:Ae.Three}(n,t,e)}else"Bottom"===t.direction&&"Left"===e.direction?a=function Are(n,t,e,i){var r=n.sourcePortWrapper,s=n.targetPortWrapper,o=Xa(n);if(e.margin={left:o,right:o,top:o,bottom:o},t.margin={top:o,bottom:o,left:o,right:o},i){var l=r;r=s,s=l}return void 0!==r&&r.offsetXs.offsetY||void 0===s&&t.corners.top>e.corners.middleLeft.y?Ae.Four:Ae.Two:void 0!==s&&Math.abs(t.corners.right-e.corners.left)<=25&&Math.abs(s.offsetY-t.corners.bottom)<=25?Ae.Two:Ae.Four}(n,t,e,s):"Left"===t.direction&&"Left"===e.direction?a=function Ore(n,t,e){var i=n.sourcePortWrapper,r=n.targetPortWrapper,s=Xa(n);t.margin={left:s,right:s,top:s,bottom:s},e.margin={left:s,right:s,top:s,bottom:s};var o=Math.round(Math.abs(t.point.x-e.point.x)),a=Math.round(Math.abs(t.point.y-e.point.y));return t.corners.leftr.offsetY||void 0===r&&t.corners.top-t.margin.top>e.corners.middleLeft.y?Ae.Three:t.corners.righte.corners.bottom+e.margin.bottom||void 0===i&&t.corners.middleLeft.y>e.corners.bottom+e.margin.bottom?Ae.Three:t.corners.left>e.corners.right?Ae.Five:0===o||0===a?Ae.One:Ae.Three}(n,t,e):"Left"===t.direction&&"Top"===e.direction?a=function Nre(n,t,e,i){var s=n.sourcePortWrapper,o=Xa(n);e.margin={left:o,right:o,top:o,bottom:o},t.margin={top:o,bottom:o,left:o,right:o};var a=n.targetPortWrapper,l={x:Math.min(t.point.x,t.corners.left),y:t.point.y},h={x:e.point.x,y:Math.min(e.point.y,e.corners.top)};if(i){var c=s;s=a,a=c;var d=l;l=h,h=d}return void 0!==s&&s.offsetYa.offsetX||void 0===a&&t.corners.left-t.margin.left>e.corners.topCenter.x?Ae.Two:Ae.Four:void 0!==a&&t.corners.rightr.offsetX||void 0===r&&t.corners.left>e.corners.left||void 0!==r&&t.corners.right+t.margin.righte.corners.right+e.margin.right||void 0===i&&t.corners.left>e.corners.right||void 0!==i&&i.offsetXe.corners.bottom?Ae.Five:0===s||0===o?Ae.One:Ae.Three}(n,t,e));return s&&b3(t,e),o=function Pre(n,t,e,i,r,s){var l,d,h=n.sourceWrapper.corners,c=n.targetWrapper.corners,u=20,f={corners:e.corners,point:e.point,direction:e.direction,margin:e.margin},p={corners:i.corners,point:i.point,direction:i.direction,margin:i.margin};if(!(f.direction===p.direction&&t!==Ae.Five||f.direction!==_n(p.direction)&&t!==Ae.Three))switch(f.direction){case"Left":h.middleLeft.x>c.middleRight.x&&(d=(h.middleLeft.x-c.middleRight.x)/2,u=s?d:Math.min(u,d));break;case"Right":h.middleRight.xc.bottomCenter.y&&(d=(h.topCenter.y-c.bottomCenter.y)/2,u=s?d:Math.min(u,d));break;case"Bottom":h.bottomCenter.yf&&hf)&&o>c&&o<=d&&e>=20&&(s=n.point.x-t.corners.left+s),i&&n.direction===t.direction&&n.corners.left>t.corners.left&&n.corners.left-t.corners.right>=20&&(s=(n.corners.left-t.corners.right)/2),p=Fn(n.point,s,180);break;case"Top":(o>c&&oc)&&h>f&&h<=u&&e>=20&&(s=n.point.y-t.corners.top+s),i&&n.direction===t.direction&&n.corners.top>t.corners.top&&n.corners.top-t.corners.bottom>=20&&(s=(n.corners.top-t.corners.bottom)/2),p=Fn(n.point,s,270);break;case"Right":(h>f&&hf)&&a=c&&e>=20&&(s=t.corners.right-n.point.x+s),i&&n.direction===t.direction&&n.corners.right=20&&(s=(t.corners.left-n.corners.right)/2),p=Fn(n.point,s,0);break;case"Bottom":(o>c&&oc)&&l=f&&e>=20&&(s=t.corners.bottom-n.point.y+s),i&&n.direction===t.direction&&n.corners.bottom=20&&(s=(t.corners.top-n.corners.bottom)/2),p=Fn(n.point,s,90)}r=[n.point,p];var g=void 0;if("Top"===n.direction||"Bottom"===n.direction){var v=n.direction;n.direction=p.x>t.point.x?"Left":"Right",n.point=p,r=xI(n,t,v,r,g=i?.5*Math.abs(p.x-t.point.x):g,i)}else v=n.direction,n.direction=p.y>t.point.y?"Top":"Bottom",n.point=p,r=xI(n,t,v,r,g=i?.5*Math.abs(p.y-t.point.y):g,i);return r}(f,p,u,g)),l}(n,a,t,e,i,r),"Bezier"===n.type&&function Rre(n,t,e){if("Bezier"===n.type)if(0===n.segments.length){var i=e[0],r=e[e.length-1];if(t===Ae.One){var s=Math.min(20,.5*R.findLength(i,r)),o={angle:Gt(i,r),distance:s},a={angle:Gt(r,i),distance:s},l=R.direction(i,r),c=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,orientation:"Left"===l||"Right"===l?"Horizontal":"Vertical"},!0);n.segments.push(c)}else if(t===Ae.Two)o={angle:Gt(i,d=e[1]),distance:.5*R.findLength(i,d)},a={angle:Gt(r,d),distance:.5*R.findLength(r,d)},l=R.direction(i,d),c=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,orientation:"Left"===l||"Right"===l?"Horizontal":"Vertical"},!0),n.segments.push(c);else if(t===Ae.Three){var d={x:.5*((u=e[1]).x+(f=e[e.length-2]).x),y:.5*(u.y+f.y)},p=(o={angle:Gt(i,u),distance:.5*R.findLength(i,u)},a={angle:Gt(d,u),distance:.5*R.findLength(d,u)},R.direction(i,u)),v=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,point:d,orientation:"Left"===p||"Right"===p?"Horizontal":"Vertical"},!0);n.segments.push(v);var y={angle:Gt(d,f),distance:.5*R.findLength(d,f)},S={angle:Gt(r,f),distance:.5*R.findLength(r,f)},b=R.direction(d,f),w=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:y,vector2:S,orientation:"Left"===b||"Right"===b?"Horizontal":"Vertical"},!0);n.segments.push(w)}else if(t===Ae.Four){var D={x:.5*((u=e[1]).x+(f=e[2]).x),y:.5*(u.y+f.y)},A={x:.5*(f.x+(C=e[3]).x),y:.5*(f.y+C.y)};o={angle:Gt(i,u),distance:.5*R.findLength(i,u)},a={angle:Gt(D,u),distance:.5*R.findLength(D,u)},p=R.direction(i,u),v=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,point:D,orientation:"Left"===p||"Right"===p?"Horizontal":"Vertical"},!0),n.segments.push(v),y={angle:Gt(D,f),distance:.5*R.findLength(D,f)},S={angle:Gt(A,f),distance:.5*R.findLength(A,f)},b=R.direction(D,f),w=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:y,vector2:S,point:A,orientation:"Left"===b||"Right"===b?"Horizontal":"Vertical"},!0),n.segments.push(w);var x={angle:Gt(A,C),distance:.5*R.findLength(A,C)},P={angle:Gt(r,C),distance:.5*R.findLength(r,C)},L=R.direction(A,C),N=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:x,vector2:P,orientation:"Left"===L||"Right"===L?"Horizontal":"Vertical"},!0);n.segments.push(N)}else if(t===Ae.Five){var u,f,C,T=e[4],z=(D={x:.5*((u=e[1]).x+(f=e[2]).x),y:.5*(u.y+f.y)},A={x:.5*(f.x+(C=e[3]).x),y:.5*(f.y+C.y)},{x:.5*(C.x+T.x),y:.5*(C.y+T.y)});o={angle:Gt(i,u),distance:.5*R.findLength(i,u)},a={angle:Gt(D,u),distance:.5*R.findLength(D,u)},p=R.direction(i,u),v=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,point:D,orientation:"Left"===p||"Right"===p?"Horizontal":"Vertical"},!0),n.segments.push(v),y={angle:Gt(D,f),distance:.5*R.findLength(D,f)},S={angle:Gt(A,f),distance:.5*R.findLength(A,f)},b=R.direction(D,f),w=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:y,vector2:S,point:A,orientation:"Left"===b||"Right"===b?"Horizontal":"Vertical"},!0),n.segments.push(w),x={angle:Gt(A,C),distance:.5*R.findLength(A,C)},P={angle:Gt(z,C),distance:.5*R.findLength(z,C)},L=R.direction(A,C),N=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:x,vector2:P,point:z,orientation:"Left"===L||"Right"===L?"Horizontal":"Vertical"},!0),n.segments.push(N);var U={angle:Gt(z,T),distance:.5*R.findLength(z,T)},B={angle:Gt(r,T),distance:.5*R.findLength(r,T)},j=R.direction(z,T),oe=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:U,vector2:B,orientation:"Left"===j||"Right"===j?"Horizontal":"Vertical"},!0);n.segments.push(oe)}else c=new fs(n,"segments",{type:"Bezier"},!0),n.segments.push(c)}else for(var ue=0;ue=13?13:n.connectorSpacing<=1?1:n.connectorSpacing}function Gt(n,t){var i=R.findLength({x:t.x,y:n.y},t),r=R.findLength(t,n),s=Math.asin(i/r);return s=180*s/Math.PI,n.xt.y&&(s=360-s):s=n.y0)for(var l=1;lc)&&(s=c,a=h),s>=0&&s<=1)break}}return a}function m3(n,t){var c,d,u,f,p,g,S,b,M,w,D,e=n.x1,i=n.y1,r=n.x2,s=n.y2,o=t.x1,a=t.y1,l=t.x2,h=t.y2;if(w=(c=s-i)*l+(u=e-r)*h+(p=r*i-e*s),0!==(M=c*o+u*a+p)&&0!==w&&y3(M,w)||(b=(d=h-a)*r+(f=o-l)*s+(g=l*a-o*h),0!==(S=d*e+f*i+g)&&0!==b&&y3(S,b)))return null;var A=c*f-d*u;return 0===A?null:(A<0?-A/2:A/2,0,{x:(D=u*g-f*p)<0?(D-0)/A:(D+0)/A,y:(D=d*p-c*g)<0?(D-0)/A:(D+0)/A})}function y3(n,t){return n*t>=0}function S3(n,t,e){switch(t.direction){case"Left":t.point.x>n.left&&(e=t.point.x-n.left>e?t.point.x-n.left+e:e);break;case"Right":t.point.xe?n.right-t.point.x+e:e);break;case"Top":t.point.y>n.top&&(e=t.point.y-n.top>e?t.point.y-n.top+e:e);break;case"Bottom":t.point.ye?n.bottom-t.point.y+e:e)}return e}function Ol(n,t){var e;switch(n.direction){case"Left":case"Right":var i={x:t.point.x,y:n.point.y};e=R.equals(n.point,i)||R.equals(t.point,i)?[n.point,t.point]:[n.point,i,t.point];break;case"Top":case"Bottom":var r={x:n.point.x,y:t.point.y};e=R.equals(n.point,r)||R.equals(t.point,r)?[n.point,t.point]:[n.point,r,t.point]}return e}function Ys(n,t,e,i,r,s){void 0===s&&(s=!1),i||(i=20),s&&t.direction!==e.direction&&(i="Left"===t.direction||"Right"===t.direction?Math.floor(.5*Math.abs(t.point.x-e.point.x)):Math.floor(.5*Math.abs(t.point.y-e.point.y)));var l,h,u,o=n.sourcePortWrapper,c=e.point.x-t.point.x,d=e.point.y-t.point.y;if(!r&&(Math.abs(c)<.001||Math.abs(d)<.001)&&void 0===e.direction)return[t.point,e.point];if(void 0===n.targetWrapper&&Math.abs(c)<=31&&Math.abs(d)<=31){if("Left"===t.direction||"Right"===t.direction?Math.abs(d)<12&&(t.direction=t.point.y>e.point.y?"Top":"Bottom"):Math.abs(c)<12&&(t.direction=t.point.x>e.point.x?"Left":"Right"),Math.abs(c)>12||Math.abs(d)>12)return Ol(t,e);i+=5}return"Left"===t.direction||"Right"===t.direction?("Right"===t.direction?(void 0!==e.direction&&"Right"===e.direction&&(i=Math.max(t.point.x,e.point.x)-t.point.x+i),t.point.x>e.point.x&&void 0===o&&(i=-i)):(void 0!==e.direction&&"Left"===e.direction&&(i=t.point.x-Math.min(t.point.x,e.point.x)+i),(t.point.x>e.point.x||void 0!==o||"Left"===t.direction)&&(i=-i)),u=e.point.y-t.point.y,l=Fn(t.point,i,0),0!=(u=e.point.y-l.y)&&(h=Fn(l,e.point.y-l.y,90))):("Top"===t.direction||"Bottom"===t.direction)&&("Bottom"===t.direction?void 0!==e.direction&&"Bottom"===e.direction&&(i=Math.max(t.point.y,e.point.y)-t.point.y+i):(void 0!==e.direction&&"Top"===e.direction&&(i=t.point.y-Math.min(t.point.y,e.point.y)+i),(t.point.y>e.point.y||void 0!==o||"Top"===t.direction)&&(i=-i)),u=e.point.x-t.point.x,l=Fn(t.point,i,90),0!=(u=e.point.x-l.x)&&(h=Fn(l,e.point.x-l.x,0))),0===u?[t.point,e.point]:[t.point,l,h,e.point]}function xI(n,t,e,i,r,s){var o;switch(void 0===r&&(r=20),void 0===s&&(s=!1),void 0===e?(n.margin={left:2,right:2,top:2,bottom:2},t.margin={left:0,right:5,top:0,bottom:5},s&&(n.margin={left:10,right:10,top:10,bottom:10},t.margin={left:10,right:10,top:10,bottom:10},"Left"===n.direction?(r=kx(n,t,e,r),n.corners.left-t.corners.right>=5&&(r=Math.abs(n.point.x-n.corners.left)+.5*Math.floor(n.corners.left-t.corners.right))):"Right"===n.direction?(r=Px(n,t,r,e),t.corners.left-n.corners.right>=5&&(r=Math.abs(n.point.x-n.corners.right)+.5*Math.floor(t.corners.left-n.corners.right))):"Top"===n.direction?(r=Ox(n,t,e,r),n.corners.top-t.corners.bottom>=5&&(r=Math.abs(n.point.y-n.corners.top)+.5*Math.floor(n.corners.top-t.corners.bottom))):"Bottom"===n.direction&&(r=zx(n,t,r,e),t.corners.top-n.corners.bottom>=5&&(r=Math.abs(n.point.y-n.corners.bottom)+.5*Math.floor(t.corners.top-n.corners.bottom))))):("Bottom"===n.direction?s?t.corners.top-n.corners.bottom<20&&(r=t.corners.bottom-n.point.y+25):t.corners.top>n.corners.bottom&&t.corners.top-n.corners.bottom<20&&(r=(t.corners.top-n.corners.bottom)/2):"Top"===n.direction?s?n.corners.top-t.corners.bottom<20&&(r=n.point.y-t.corners.top+25):t.corners.bottomn.corners.right&&t.corners.left-n.corners.right<20&&(r=(t.corners.left-n.corners.right)/2):"Left"===n.direction&&(s?n.corners.left-t.corners.right<20&&(r=n.point.x-t.corners.left+25):t.corners.rightt.point.y||"Top"===t.direction&&n.point.yt.point.x||"Left"===t.direction&&n.point.xh||e.corners.top-e.margin.top<=i.point.y&&e.corners.bottom+e.margin.bottom>=i.point.y))if(!s||"Top"!==e.direction&&"Bottom"!==e.direction)c=Math.min(Math.abs(i.corners.left-e.corners.right)/2,20),h=e.corners.right-n.x+c;else{var c=Math.abs(i.corners.left-e.corners.right)/2;h=e.corners.right-n.x+c}else h="Top"===e.direction&&n.y>i.point.y||"Bottom"===e.direction&&n.y=e.corners.left-e.margin.left&&n.x<=e.corners.right+e.margin.right?Math.min(i.corners.left,e.corners.left)-n.x-20:i.corners.left-n.x-20;break;case"Right":if(e.corners.left-e.margin.left>i.corners.right+i.margin.right&&(e.corners.left-e.margin.right-i.corners.right>h||e.corners.top-e.margin.top<=i.point.y&&e.corners.bottom+e.margin.bottom>=i.point.y))if(!s||"Top"!==e.direction&&"Bottom"!==e.direction)c=Math.min(Math.abs(e.corners.left-i.corners.right)/2,20),h=e.corners.left-n.x-c;else{c=Math.abs(e.corners.left-i.corners.right)/2;h=e.corners.left-n.x-c}else h="Top"===e.direction&&n.y>i.point.y||"Bottom"===e.direction&&n.y=e.corners.left-e.margin.left&&n.x<=e.corners.right+e.margin.right?Math.max(i.corners.right,e.corners.right)-n.x+20:i.corners.right-n.x+20}o=Fn(n,h,0),a=Fn(o,i.point.y-n.y,90),l=i.point}else if("vertical"===t){switch(i.direction){case"Top":e.corners.bottom+e.margin.bottomh||e.corners.left-e.margin.left<=i.point.x&&e.corners.right+e.margin.right>=i.point.x)?!s||"Right"!==e.direction&&"Left"!==e.direction?(c=Math.min(Math.abs(i.corners.top-e.corners.bottom)/2,20),h=e.corners.bottom-n.y+c):(c=Math.abs(i.corners.top-e.corners.bottom)/2,h=e.corners.bottom-n.y+c):h="Left"===e.direction&&n.x>i.point.x||"Right"===e.direction&&n.x=e.corners.top-e.margin.top&&n.y<=e.corners.bottom+e.margin.bottom?Math.min(i.corners.top,e.corners.top)-n.y-20:i.corners.top-n.y-20;break;case"Bottom":e.corners.top-e.margin.top>i.corners.bottom+i.margin.bottom&&(e.corners.top-e.margin.top-i.corners.bottom>h||e.corners.left-e.margin.left<=i.point.x&&e.corners.right+e.margin.right>=i.point.x)?!s||"Right"!==e.direction&&"Left"!==e.direction?(c=Math.min(Math.abs(e.corners.top-i.corners.bottom)/2,20),h=e.corners.top-n.y-c):(c=Math.abs(e.corners.top-i.corners.bottom)/2,h=e.corners.top-n.y-c):h="Left"===e.direction&&n.x>i.point.x||"Right"===e.direction&&n.x=e.corners.top-e.margin.top&&n.y<=e.corners.bottom+e.margin.bottom?Math.max(i.corners.bottom,e.corners.bottom)-n.y+20:i.corners.bottom-n.y+20}o=Fn(n,h,90),a=Fn(o,i.point.x-n.x,0),l=i.point}r.push(o),r.push(a),r.push(l)}function Ox(n,t,e,i){return n.corners.top-n.margin.top>t.corners.top+t.margin.top&&n.corners.top-n.margin.top<=t.corners.bottom+t.margin.bottom?(("Right"===t.direction&&n.point.xt.point.x)&&(i+=n.corners.top-t.corners.top),i+=n.point.y-n.corners.top):i+=void 0!==e&&"Left"!==e&&"Right"===t.direction&&n.point.xt.corners.left-t.margin.left&&n.corners.left-n.margin.left<=t.corners.right+t.margin.right?(("Bottom"===t.direction&&n.point.yt.point.y)&&(i+=n.corners.left-t.corners.left),i+=n.point.x-n.corners.left):i+=void 0!==e&&"Top"!==e&&"Bottom"===t.direction&&n.point.y=t.corners.left-t.margin.left?(("Bottom"===t.direction&&n.point.yt.point.y)&&(e+=t.corners.right-n.corners.right),e+=n.corners.right-n.point.x):e+=void 0!==i&&"Top"!==i&&"Bottom"===t.direction&&n.point.y=t.corners.top-t.margin.top?(("Right"===t.direction&&n.point.xt.point.x)&&(e+=t.corners.bottom-n.corners.bottom),e+=n.corners.bottom-n.point.y):e+=void 0!==i&&"Left"!==i&&"Right"===t.direction&&n.point.xp&&d=u&&d=f&&d<=p?"Left":"Right"}function _n(n){switch(n){case"Top":return"Bottom";case"Bottom":return"Top";case"Left":return"Right";case"Right":return"Left"}return"auto"}var w3=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Ac=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},TI=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return w3(t,n),Ac([I()],t.prototype,"width",void 0),Ac([I()],t.prototype,"height",void 0),t}(Ee),Bre=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return w3(t,n),Ac([I()],t.prototype,"width",void 0),Ac([I()],t.prototype,"height",void 0),Ac([I()],t.prototype,"fit",void 0),Ac([I()],t.prototype,"description",void 0),Ac([I()],t.prototype,"template",void 0),Ac([I()],t.prototype,"tooltip",void 0),t}(Ee),Fre=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),kl=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},C3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Fre(t,n),kl([I("")],t.prototype,"id",void 0),kl([I(Number.MIN_VALUE)],t.prototype,"zIndex",void 0),kl([re({},Jn)],t.prototype,"margin",void 0),kl([I(!0)],t.prototype,"visible",void 0),kl([re({},Dd)],t.prototype,"tooltip",void 0),kl([I(!1)],t.prototype,"excludeFromLayout",void 0),kl([I()],t.prototype,"addInfo",void 0),kl([I("None")],t.prototype,"flip",void 0),kl([I("All")],t.prototype,"flipMode",void 0),kl([re({},Bre)],t.prototype,"symbolInfo",void 0),t}(Ee),_re=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),es=function(n){function t(e,i,r,s){var o=n.call(this)||this;return o.data="",o.nodeId="",o.annotationId="",o.diagramId="",o.diagramId=i,o.nodeId=e,o.annotationId=r,o.templateFn=UF(s),o}return _re(t,n),t.prototype.getNodeTemplate=function(){return this.templateFn},Object.defineProperty(t.prototype,"content",{get:function(){return this.data},set:function(e){this.data=e,this.canReset||(this.canReset=!0,this.isTemplate||(this.template=Hh(this,!0)),this.canReset=!1,this.isDirt=!0)},enumerable:!0,configurable:!0}),t}(hs),Rx=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),cs=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},E3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Rx(t,n),cs([I("")],t.prototype,"id",void 0),cs([I("transparent")],t.prototype,"fill",void 0),cs([I("black")],t.prototype,"iconStrokeColor",void 0),cs([I(0)],t.prototype,"iconStrokeWidth",void 0),cs([I(!0)],t.prototype,"visibility",void 0),cs([I(10)],t.prototype,"width",void 0),cs([I(10)],t.prototype,"height",void 0),cs([I("transparent")],t.prototype,"handleStrokeColor",void 0),cs([I(1)],t.prototype,"handleStrokeWidth",void 0),cs([I("")],t.prototype,"pathData",void 0),cs([I(0)],t.prototype,"cornerRadius",void 0),cs([re({left:0,right:0,top:0,bottom:0},Jn)],t.prototype,"padding",void 0),cs([re({},Dd)],t.prototype,"tooltip",void 0),t}(Ee),D3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Rx(t,n),cs([re({x:0,y:0},R)],t.prototype,"offset",void 0),cs([re({},Jn)],t.prototype,"margin",void 0),t}(E3),AI=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Rx(t,n),cs([I(.5)],t.prototype,"offset",void 0),cs([I("Center")],t.prototype,"alignment",void 0),cs([re({x:0,y:0},R)],t.prototype,"displacement",void 0),t}(E3);function xd(n){return n?n instanceof Kn||n instanceof Or?n.constraints&Nr.Select:n instanceof de?n.constraints&qe.Select:n.constraints&ie.Select:1}function ro(n){return n?n instanceof Kn||n instanceof Or?n.constraints&Nr.Drag:n instanceof de?n.constraints&qe.Drag:n instanceof ei?1:n.constraints&ie.Drag:1}function Ure(n,t){return n instanceof de?n.constraints&qe.PointerEvents:n.constraints&ie.PointerEvents}function LI(n){return n instanceof de?n.constraints&qe.Delete:n.constraints&ie.Delete}function NI(n){return n.constraints&qe.DragSourceEnd}function OI(n){return n.constraints&qe.DragTargetEnd}function kI(n){return n.constraints&qe.DragSegmentThumb}function PI(n){return n instanceof Kn||n instanceof Or?n.constraints&Nr.Rotate:n.constraints&ie.Rotate}function zI(n){return n.constraints&ie.Shadow}function ua(n){return n instanceof te&&n.constraints&ie.InConnect?n.constraints&ie.InConnect:0}function kh(n){return n&&n.constraints&&!(n.constraints&ai.None)&&n.constraints&ai.InConnect?n.constraints&ai.InConnect:0}function Ph(n){return n instanceof te&&n.constraints&ie.OutConnect?n.constraints&ie.OutConnect:0}function Td(n){return n&&n.constraints&&!(n.constraints&ai.None)&&n.constraints&ai.OutConnect?n.constraints&ai.OutConnect:0}function Pl(n,t){var e=0;return n instanceof Kn||n instanceof Or?e=n.constraints&Nr.Resize:n&&("SouthEast"===t?e=n.constraints&ie.ResizeSouthEast:"East"===t?e=n.constraints&ie.ResizeEast:"NorthEast"===t?e=n.constraints&ie.ResizeNorthEast:"South"===t?e=n.constraints&ie.ResizeSouth:"North"===t?e=n.constraints&ie.ResizeNorth:"SouthWest"===t?e=n.constraints&ie.ResizeSouthWest:"West"===t?e=n.constraints&ie.ResizeWest:"NorthWest"===t&&(e=n.constraints&ie.ResizeNorthWest)),e}function RI(n){return n instanceof de?n.constraints&qe.AllowDrop:n.constraints&ie.AllowDrop}function Ds(n){return n.constraints&nt.Virtualization}function _v(n){return n.tool&ni.SingleSelect}function Uv(n){return n.tool&ni.MultipleSelect}function Lc(n){return n.tool&ni.ZoomPan}function HI(n){return n.tool&ni.ContinuousDraw}function x3(n){return n.tool&ni.DrawOnce}function BI(n){return n.tool&ni.SingleSelect||n.tool&ni.MultipleSelect}function jv(n){return n.constraints&nt.UserInteraction}function T3(n){return n.constraints&nt.ZoomTextEdit}function Vv(n){return function Gre(n){return n.constraints&nt.ApiUpdate}(n)||n.diagramActions&ee.ToolAction}function Hx(n,t){return n.constraints&ai.Draw}function Bx(n,t){return n.constraints&ai.Drag}function FI(n){return!(n&Ga.DrawSelectorBorder)}function A3(n){return!!(n&Ga.PreventRenderSelector)}var Fx=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Wv=function(n){function t(){var e=null!==n&&n.apply(this,arguments)||this;return e.childTable=[],e.cellStyle={},e.desiredRowHeight=[],e.desiredCellWidth=[],e}return Fx(t,n),t.prototype.rowDefinitions=function(){return this.rowDefns},t.prototype.columnDefinitions=function(){return this.colDefns},t.prototype.addObject=function(e,i,r,s,o){if(this.rows.length>=i){var a=this.rows[parseInt(i.toString(),10)];if(a.cells.length>r){o=o||1,s=s||1;var l=a.cells[parseInt(r.toString(),10)];l.columnSpan=Math.max(o,l.columnSpan),l.rowSpan=Math.max(s,l.rowSpan);var h=new Jre;(h=e).rowId=i,h.columnId=r,h.columnSpan=o,this.childTable[h.id]=h,this.addObjectToCell(h,l)}}},t.prototype.addObjectToCell=function(e,i){i.children||(i.children=[]),e.style.strokeColor="black",e.style.strokeWidth=1,i.children.push(e)},t.prototype.updateProperties=function(e,i,r,s){this.offsetX=e,this.offsetY=i,this.width=r,this.height=s},t.prototype.setDefinitions=function(e,i){this.rowDefns=e,this.colDefns=i,this.children=[],this.rows=this.rows||[];for(var r=0;r0){for(var h=0;hi&&this.updateRowHeight(e,l,!1)}},t.prototype.setTextRefresh=function(e){if(e.children&&e.children.length)for(var i=e.children,r=0;ri&&this.updateColumnWidth(e,a,!1)}},t.prototype.calculateCellWidth=function(e){for(var i,r,s,o=0;os.bounds.width&&(0===s.children.length||void 0===s.children[0].maxWidth)?s.outerBounds.width:s.bounds.width,i=i?is.bounds.height?s.outerBounds.height:s.bounds.height,i=i?i0?e.children[0]:void 0;if(a&&1===e.columnSpan){o="Width"===i?a.bounds.right:a.bounds.bottom,s||(s="Width"===i?a.bounds.width:a.bounds.height);for(var l=0;lo){var d=c-o+("Width"===i?a.bounds.width:a.bounds.height);s&&(s=s0?this.rowDefns.splice(e,0,i):this.rowDefns.push(i);var s=new L3;s.cells=[],(new Ad).width=this.width,this.addCellInRow(this.colDefns,i,s),e>this.rows.length-1?this.rows.push(s):this.rows.splice(e,0,s),r&&(this.measure(new me(this.width,this.height)),this.arrange(this.desiredSize))},t.prototype.addColumn=function(e,i,r){var s,o,a,l,h=this.rows;this.colDefns.length>0?this.colDefns.splice(e,0,i):this.colDefns.push(i),void 0!==this.width&&(this.width+=i.width);for(var c=0;cs.cells.length-1?s.cells.push(l):s.cells.splice(e,0,l),this.children.push(l);r&&(this.measure(new me(this.width,this.height)),this.arrange(this.desiredSize))},t.prototype.removeRow=function(e){var i,r,o=this.rows[parseInt(e.toString(),10)];this.height-=this.rowDefns[parseInt(e.toString(),10)].height;for(var a=0;a0){var r=0,s=0;i=new me(0,0),this.calculateSize();for(var o=0,a=this.rows;o0){for(var o=this.offsetX-e.width*this.pivot.x,a=this.offsetY-e.height*this.pivot.y,l=o,h=0,c=this.rows;h1&&this.children.splice(this.children.indexOf(p)+1,p.columnSpan-1),p.rowSpan>1)for(y=s,S=0;y+p.rowSpan-10){for(var c=0;c0?1:0,v=0;v0||a.outEdges.length>0))for(f=a.inEdges.concat(a.outEdges),s=0;s0)for(o=0;o1)for(a=1;a0))if(h=n.wrapper.children[0],"Horizontal"===e.orientation)for(o=e.header&&e.hasHeader?h.rows[1]:h.rows[0],r=0;r0){var e=void 0;t.lineRoutingModule&&t.constraints&nt.LineRouting&&t.lineRoutingModule.renderVirtualRegion(t,!0);for(var i=0;i0?o+1:o)].height=t.wrapper.height;else if(t.isPhase)for(l[t.rowIndex-o].offset=t.wrapper.height,p=0;p0?1:0)].width=t.wrapper.width}function UI(n,t){var i=n.shape,r=i.header&&i.hasHeader?1:0;return"Horizontal"===i.orientation?t.rowIndex-(r+=i.phases.length>0?1:0):t.columnIndex-(i.phaseSize&&i.phases.length>0?1:0)}function jI(n){var t=0,e=n.shape;return"Horizontal"===e.orientation&&(t=e.header&&e.hasHeader?1:0),e.phases.length>0&&e.phaseSize&&(t+=1),t}function VI(n,t,e,i){var r=n.shape;if(r.phases.length>0){var s=t.nameTable[r.phases[parseInt(i.toString(),10)].header.id];s&&s.maxWidth0?u+1:u);var w=Nc(n,o),C=void 0!==i?i:l.lanes.length;if(u+=C,r={element:M,cause:n.diagramActions,diagramAction:n.getDiagramAction(n.diagramActions),state:"Changing",type:"Addition",cancel:!1,laneIndex:C},n.triggerEvent(Ce.collectionChange,r),!r.cancel){if(c){var D=new Yv;D.height=e.height,o.addRow(u,D,!1),s.height=void 0!==s.height?s.height+e.height:s.height,s.wrapper.height=o.height=s.height}else{var A=new Ad;A.width=e.width,o.addColumn(C+1,A,!1),s.width&&(s.width+=e.width,s.wrapper.width=o.width=s.width),n.diagramActions&ee.UndoRedo||(o.rows[0].cells[0].columnSpan+=1)}n.diagramActions&ee.UndoRedo||(M.id=""===M.id?Qe():M.id),void 0!==i?l.lanes.splice(i,0,M):l.lanes.push(M),r={element:M,cause:n.diagramActions,diagramAction:n.getDiagramAction(n.diagramActions),state:"Changed",type:"Addition",cancel:!1,laneIndex:C},n.triggerEvent(Ce.collectionChange,r),O3(o,n,s,u,C,c),h="Horizontal"===l.orientation?n.nameTable[o.rows[parseInt(u.toString(),10)].cells[0].children[0].id]:l.header&&l.hasHeader?n.nameTable[o.rows[1].cells[parseInt(u.toString(),10)].children[0].id]:n.nameTable[o.rows[0].cells[parseInt(u.toString(),10)].children[0].id],n.diagramActions&ee.UndoRedo||(d={type:"LaneCollectionChanged",changeType:"Insert",undoObject:$(M),redoObject:$(h),category:"Internal"},n.addHistoryEntry(d)),$f(n,s,"Horizontal"===l.orientation?u:l.header&&l.hasHeader?1:0),qf(s),Oc(n,s);var P=!1;if((f=e.children)&&f.length>0)for(p=0;p0){var o=t.children[0],a=n.nameTable[o.id];(function ane(n,t,e){return n.left-(e.left||0)<=t.x&&n.right+(e.right||0)>=t.x&&n.top-(e.top||0)<=t.y&&n.bottom+(e.bottom||0)>=t.y})(o.bounds,e,r)&&(n.addChild(a,i),s=!0)}return s}function lne(n,t,e){if("SwimLane"===t.shape.type){var i=void 0,r=void 0,s=void 0,a=void 0,l=void 0,h=void 0,c=t.wrapper.bounds.x,d=t.wrapper.bounds.y,u=t.shape,f=u.padding,p=u.phases,g=void 0,v=t.wrapper.children[0],y="Horizontal"===u.orientation;if(i=u.header&&u.hasHeader?0:-1,u.phases.length>0&&(i+=1),e.offset>(y?u.lanes[0].header.width:u.lanes[0].header.height)){for(h=0;he.offset){if(g=h>0?e.offset-(h>0?p[h-1]:s).offset:e.offset,y){var b=v.columnDefinitions()[parseInt(h.toString(),10)];b.width-=g,(a=n.nameTable[u.phases[parseInt(h.toString(),10)].header.id]).maxWidth=a.wrapper.maxWidth=b.width,v.updateColumnWidth(h,b.width,!1);var M=new Ad;M.width=g,l=h,v.addColumn(h,M,!1);break}var w=v.rowDefinitions()[h+i];w.height-=g,a=n.nameTable[u.phases[parseInt(h.toString(),10)].header.id],v.updateRowHeight(h+i,w.height,!1);var C=new Yv;C.height=g,l=h,v.addRow(h+i,C,!1);break}if(n.diagramActions&ee.UndoRedo&&void 0===l&&(D=n.historyManager.currentEntry.next).isLastPhase&&function hne(n,t,e,i,r,s){var a=t.shape.phases[n-2],l=e.previousPhase.offset;if(r){var h=i.columnDefinitions()[n-1],c=new Ad;n>1?(c.width=h.width-(l-a.offset),h.width=l-a.offset):(c.width=h.width-l,h.width=l),i.updateColumnWidth(n-1,h.width,!1),i.addColumn(n,c,!1)}else{h=i.rowDefinitions()[parseInt(n.toString(),10)];var d=new Yv;n>1?(d.height=e.undoObject.offset-l,h.height=l-a.offset):(d.height=h.height-l,h.height=l),i.updateRowHeight(n,h.height,!1),i.addRow(1+n,d,!1)}}(l=p.length,t,D,v,y),l>=0){var A=new cb(t.shape,"phases",e,!0);if(n.diagramActions&ee.UndoRedo||(A.id+=Qe()),u.phases.splice(l,0,A),_x(v,n,t,i,y,l),y){if(r=n.nameTable[v.rows[parseInt(i.toString(),10)].cells[parseInt(l.toString(),10)].children[0].id],0===l&&u.header&&u.hasHeader){v.rows[0].cells[0].children=v.rows[0].cells[1].children,v.rows[0].cells[1].children=[];for(var x=v.rows[0],P=0;Pl+1){var O=n.nameTable[v.rows[parseInt(i.toString(),10)].cells[l+1].children[0].id];v.updateColumnWidth(l+1,L[l+1].width,!0,f),O.maxWidth=O.wrapper.maxWidth=L[l+1].width}t.width=t.wrapper.width=t.wrapper.children[0].width=v.width}else{r=n.nameTable[v.rows[i+l].cells[0].children[0].id];var N=v.rowDefinitions(),T=N[i+l].height;(function dne(n,t,e,i,r){for(var o,a,l=e.rows[parseInt(i.toString(),10)],h=e.rows[i+1],c=e.rows[i-1],d=1;di+l+1&&v.updateRowHeight(i+l+1,T=N[i+l+1].height,!0,f),t.height=t.wrapper.height=t.wrapper.children[0].height=v.actualSize.height}if(qf(t),t.width=t.wrapper.actualSize.width,Oc(n,t),n.drag(t,c-t.wrapper.bounds.x,d-t.wrapper.bounds.y),_I(t,n),n.commandHandler.select(r),!(n.diagramActions&ee.UndoRedo)){var D={type:"PhaseCollectionChanged",changeType:"Insert",undoObject:$(A),redoObject:$(r),category:"Internal"};n.addHistoryEntry(D)}n.updateDiagramObject(t)}}}}function H3(n,t,e,i,r,s,o){var a,l,p,h=t.shape,c="Horizontal"===h.orientation,d=t.wrapper.children[0],g=c?s:o;e?(a=c?e.bounds.x+e.bounds.width:e.bounds.x,l=c?e.bounds.y:e.bounds.y+e.bounds.height):(a=d.bounds.x,l=r.bounds.y);var v=new Ne(a,l,i.desiredCellWidth,i.desiredCellHeight),S=Qv(n,0,t,{id:t.id+(c?h.lanes[g-2]:h.lanes[g-1]).id+Qe()[0],rowIndex:s,columnIndex:o,width:i.minWidth,height:i.minHeight,style:(c?h.lanes[g-2]:h.lanes[g-1]).style,constraints:ie.Default|ie.AllowDrop,container:{type:"Canvas",orientation:c?"Horizontal":"Vertical"}},!1,!1,!0);if(S.children[0].isCalculateDesiredSize=!1,d.addObject(S,s,o),r&&r.children&&r.children.length)for(p=0;p1)for(var p=1;ph.margin.left&&(h.margin.left=f)):(h.margin.top-=e.desiredCellHeight,f>h.margin.top&&(h.margin.top=f)))}(n,r,i,v,S,c,e)}function B3(n,t,e){if("SwimLane"===t.shape.type&&("ResizeSouth"===e||"ResizeEast"===e)){var i=t.shape,r=t.wrapper.children[0],s=void 0,o=void 0;"ResizeSouth"===e?"Vertical"===i.orientation?s=r.rows[r.rows.length-1].cells[0]:(o=r.rows.length-1,s=r.rows[parseInt(o.toString(),10)].cells[r.rows[parseInt(o.toString(),10)].cells.length-1]):(o=i.header&&i.hasHeader?1:0,s=r.rows[parseInt(o.toString(),10)].cells[r.rows[parseInt(o.toString(),10)].cells.length-1]),n.commandHandler.select(n.nameTable[s.children[0].id])}}function WI(n,t,e,i,r,s){var o,a,l,c,u,f,p,d=Qe(),g=n.shape,v=g.phases,y=n.offsetX-n.wrapper.actualSize.width/2,S=n.offsetY-n.wrapper.actualSize.height/2;if("Vertical"===g.orientation&&(S+=g.header&&g.hasHeader?g.header.height:0),!s)for(r||(n.id+=d,g&&g.header&&g.hasHeader?g.header.id+=d:g.header=void 0),o=0;v&&o0&&s.columnIndex>0||s.isLane)?(a=function bne(n,t,e){for(var i=new Ne,r="SwimLane"===n.shape.type?n.wrapper.children[0].rows:n.wrapper.rows,s=e?1:0;s=0;a--)i?i.id===o.children[parseInt(a.toString(),10)].id&&o.children.splice(a,1):(n.removeDependentConnector(o.children[parseInt(a.toString(),10)]),n.diagramActions&ee.UndoRedo||(n.diagramActions=n.diagramActions|ee.UndoRedo,s=!0),n.remove(o.children[parseInt(a.toString(),10)]),o.children.splice(a,1),s&&(n.diagramActions=n.diagramActions&~ee.UndoRedo))}function fne(n){return n.children[0]}function qv(n,t){t&&(n.nodes.splice(n.nodes.indexOf(t),1),n.removeFromAQuad(t),n.removeObjectsFromLayer(t),delete n.nameTable[t.id],n.removeElements(t))}function _3(n,t,e,i){var r;if("SwimLane"===e.shape.type){var s=e.shape,o=void 0;if(1===s.lanes.length)n.remove(e);else{var a=e.wrapper.bounds.x,l=e.wrapper.bounds.y,h=void 0,c=void 0,d=void 0,u=void 0,p=e.wrapper.children[0];if(o=i?s.lanes.indexOf(i):UI(e,t),r={element:t,cause:n.diagramActions,diagramAction:n.getDiagramAction(n.diagramActions),state:"Changing",type:"Removal",cancel:!1,laneIndex:o},n.triggerEvent(Ce.collectionChange,r),!r.cancel){var g=s.lanes[parseInt(o.toString(),10)],v=g.children;g.children=[];for(var y=0;y0)for(u=0;u0)for(u=0;u0)for(e=0;e1){c===l.phases.length-1&&(o=!0,a=$(l.phases[c-1]));var u=$(l.phases[parseInt(c.toString(),10)]);if(l.phases.splice(c,1),!(n.diagramActions&ee.UndoRedo)){var f={type:"PhaseCollectionChanged",changeType:"Remove",undoObject:u,previousPhase:a,redoObject:$(t),category:"Internal",isLastPhase:o};n.addHistoryEntry(f)}"Horizontal"===l.orientation?function gne(n,t,e,i){var r,s,o,a,l,h,c,d,u,f,p,g;for(i=void 0!==i?i:e.columnIndex,c=0;c1&&(s=r.cells[parseInt(i.toString(),10)],l=(o=r.cells.length-1===i?r.cells[i-1]:r.cells[i+1]).children[0],s.children.length>0))if(p=n.nameTable[(a=s.children[0]).id],0===o.children.length&&s.children.length>0)o.children=s.children,o.columnSpan=s.columnSpan-1;else{for(d=0;d0){var M=s.children[0],w=n.nameTable[M.id];if(i=e.x&&a.bounds.y<=e.y&&a.bounds.bottom>=e.y){var l=void 0,h=a.bounds.y,c=a.bounds.x,d=n.nameTable[r.parentId]||r;if("SwimLane"===d.shape.type)o=Zv(r,d,t,n,!0);else{var f=n.nameTable[r.parentId]||r,p=f.shape;l=f.wrapper,a.actualSize.widtha.outerBounds.x)&&(void 0!==r.rowIndex?(l.updateColumnWidth(r.columnIndex,a.outerBounds.width,!0),"Horizontal"===p.orientation&&p.phaseSize&&VI(f,n,a,r.columnIndex),Oc(n,f),n.drag(f,c-a.bounds.x,h-a.bounds.y)):n.scale(r,1+(a.outerBounds.width-a.actualSize.width)/a.actualSize.width,1,a.outerBounds.xa.outerBounds.y)&&(void 0!==r.rowIndex?(l.updateRowHeight(r.rowIndex,a.outerBounds.height,!0),n.drag(f,c-a.bounds.x,h-a.bounds.y)):n.scale(r,1,1+(a.outerBounds.height-a.actualSize.height)/a.actualSize.height,a.outerBounds.y=e.x&&a.bounds.y<=e.y&&a.bounds.bottom>=e.y)&&!(t.constraints&ie.AllowMovingOutsideLane)){var l=$(t);n.clearSelection(),W3(n,t),t.parentId="",t.parentObj=n,t.propName="nodes";var h={type:"ChildCollectionChanged",category:"Internal",undoObject:l,redoObject:$(t)};n.addHistoryEntry(h),n.commandHandler.isContainer&&(n.commandHandler.isContainer=!1,n.endGroupAction()),Y3(t,n)}n.protectPropertyChange(o)}}function YI(n,t){var e,i,r;return n.enableServerDataBinding(!1),ce()||(n.selectedObject.helperObject?r=n.selectedObject.helperObject:(n.selectedItems.nodes.length>0||n.selectedItems.connectors.length>0)&&(t instanceof ei&&t.nodes.length+t.connectors.length===1?(e=t.nodes.length>0?t.nodes[0]:t.connectors[0],i=n.selectedItems.wrapper.children[0]):(e=t,i=n.selectedItems.wrapper),n.selectedObject.actualObject=e,!n.currentSymbol&&(e.isLane&&Wx(e,n)&&Dn(n,e)||!e.isLane&&Dn(n,e)||n.constraints&nt.LineRouting&&n.selectedItems.nodes.length>0))&&(r=function Mne(n,t){for(var e,i={},r=0,s=Object.keys(t);r=t.x-e&&n.x<=t.x+e&&n.y>=t.y-e&&n.y<=t.y+e}function $a(n){return n.selectedItems.nodes.length>0||n.selectedItems.connectors.length>0}function G3(n){return 1===n.selectedItems.connectors.length&&!n.selectedItems.nodes.length}function _r(n,t,e,i){if(void 0===e&&(e=!0),t instanceof ei)return!0;if(t instanceof te)for(;t;){if(-1!==n.selectedItems.nodes.indexOf(t)&&void 0===n.selectedItems.annotation)return!0;if(e)break;t=n.nameTable[t.parentId]}else if(t instanceof de){if(-1!==n.selectedItems.connectors.indexOf(t)&&void 0===n.selectedItems.annotation)return!0}else if((t instanceof Kn||t instanceof Or)&&n.selectedItems.annotation&&n.selectedItems.wrapper.children[0].id===i.id)return!0;return!1}var Yx={None:"default",Rotate:"crosshair",Select:"default",Drag:"move",ResizeWest:"w-resize",ResizeEast:"e-resize",ResizeSouth:"s-resize",ResizeNorth:"n-resize",Draw:"crosshair",PortDraw:"crosshair",ResizeNorthEast:"ne-resize",ResizeNorthWest:"nw-resize",ResizeSouthEast:"se-resize",ResizeSouthWest:"sw-resize",ConnectorSourceEnd:"move",ConnectorTargetEnd:"move",BezierSourceThumb:"move",BezierTargetThumb:"move",OrthoThumb:"move",SegmentEnd:"move",Pan:"grab",Hyperlink:"pointer",PortDrag:"pointer",LabelSelect:"pointer",LabelDrag:"move",LabelRotate:"crosshair",LabelResizeWest:"w-resize",LabelResizeEast:"e-resize",LabelResizeSouth:"s-resize",LabelResizeNorth:"n-resize",LabelResizeNorthEast:"ne-resize",LabelResizeNorthWest:"nw-resize",LabelResizeSouthEast:"se-resize",LabelResizeSouthWest:"sw-resize"},ds=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Nd=function(n,t,e,i){return new(e||(e=Promise))(function(r,s){function o(h){try{l(i.next(h))}catch(c){s(c)}}function a(h){try{l(i.throw(h))}catch(c){s(c)}}function l(h){h.done?r(h.value):new e(function(c){c(h.value)}).then(o,a)}l((i=i.apply(n,t||[])).next())})},Od=function(n,t){var i,r,s,o,e={label:0,sent:function(){if(1&s[0])throw s[1];return s[1]},trys:[],ops:[]};return o={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function a(h){return function(c){return function l(h){if(i)throw new TypeError("Generator is already executing.");for(;e;)try{if(i=1,r&&(s=2&h[0]?r.return:h[0]?r.throw||((s=r.return)&&s.call(r),0):r.next)&&!(s=s.call(r,h[1])).done)return s;switch(r=0,s&&(h=[2&h[0],s.value]),h[0]){case 0:case 1:s=h;break;case 4:return e.label++,{value:h[1],done:!1};case 5:e.label++,r=h[1],h=[0];continue;case 7:h=e.ops.pop(),e.trys.pop();continue;default:if(!(s=(s=e.trys).length>0&&s[s.length-1])&&(6===h[0]||2===h[0])){e=0;continue}if(3===h[0]&&(!s||h[1]>s[0]&&h[1]-1&&(r=i.fixedUserHandles[parseInt(o.toString(),10)]);this.commandHandler.triggerEvent(Ce.fixedUserHandleClick,{fixedUserHandle:r,element:e.source}),n.prototype.mouseUp.call(this,e)},t}(us),kd=function(n){function t(e,i){var r=n.call(this,e,!0)||this;return r.isConnected=!1,r.endPoint=i,r}return ds(t,n),t.prototype.mouseDown=function(e){return Nd(this,void 0,void 0,function(){var r,s,o,a,l;return Od(this,function(h){if(this.inAction=!0,this.undoElement=void 0,this instanceof pa||(this.undoElement=$(e.source)),n.prototype.mouseDown.call(this,e),e.source&&e.source.connectors&&(this.oldConnector=$(r=e.source.connectors[0])),"BezierSourceThumb"===this.endPoint||"BezierTargetThumb"===this.endPoint)for(s=0;s0))},t.prototype.endAction=function(){n.prototype.endAction.call(this),this.prevPosition=null,this.endPoint=null},t}(us),fa=function(n){function t(e,i){var r=n.call(this,e,!0)||this;return r.currentTarget=null,r.isStartAction=!1,r.canCancel=!1,r.canTrigger=!1,r.objectType=i,r}return ds(t,n),t.prototype.mouseDown=function(e){if(e.source instanceof te||e.source instanceof de){var i=this.commandHandler.getSelectedObject();this.commandHandler.selectObjects([e.source],e.info&&e.info.ctrlKey,i);var r={nodes:[],connectors:[]};e.source instanceof te?r.nodes.push($(e.source)):r.connectors.push($(e.source)),this.undoElement=$(r)}else this.undoElement=$(e.source);this.undoParentElement=this.commandHandler.getSubProcess(e.source),"Port"===this.objectType&&(this.portId=e.sourceWrapper.id),this.commandHandler.insertBlazorConnector(e.source),n.prototype.mouseDown.call(this,e),this.initialOffset={x:0,y:0}},t.prototype.mouseUp=function(e,i){return Nd(this,void 0,void 0,function(){var s,o,a,l,h,c,d,u,p,g,v,y,S,b,M;return Od(this,function(w){if(this.checkPropertyValue(),a=!1,h={nodes:[],connectors:[]},"Port"!==this.objectType){if(e.source instanceof te||e.source instanceof de?(e.source instanceof te?h.nodes.push($(e.source)):h.connectors.push($(e.source)),(o=$(h)).offsetX=(c=e.source.wrapper).offsetX,o.offsetY=c.offsetY):o=$(e.source),("helper"===(l=this.commandHandler.renderContainerHelper(e.source)||e.source||this.commandHandler.renderContainerHelper(e.source)).id||"helper"!==l.id)&&((l instanceof ei&&(Math.round(l.width)===Math.round(this.undoElement.width)&&Math.round(l.height)===Math.round(this.undoElement.height)||l.selectedObjects&&1===l.selectedObjects.length)||!(l instanceof ei))&&(l.offsetX!==this.undoElement.offsetX||l.offsetY!==this.undoElement.offsetY||l.sourcePoint!==this.undoElement.sourcePoint||l.targetPoint!==this.undoElement.targetPoint)||this.isSelectionHasConnector(l))&&(e.source&&(s={offsetX:e.source.wrapper.offsetX,offsetY:e.source.wrapper.offsetY}),g={source:e.source,state:"Completed",oldValue:this.intialValue,newValue:s,target:this.currentTarget,targetPosition:this.currentPosition,allowDrop:(g={source:e.source,state:"Completed",oldValue:this.intialValue,newValue:s,target:this.currentTarget,targetPosition:this.currentPosition,allowDrop:!0,cancel:!1}).allowDrop,cancel:g.cancel},d=!0,"helper"===l.id?this.canTrigger?(this.commandHandler.triggerEvent(Ce.positionChange,g),this.connectorEndPointChangeEvent(g),d=!0):d=!1:(this.commandHandler.triggerEvent(Ce.positionChange,g),this.connectorEndPointChangeEvent(g)),!i&&d&&(this.commandHandler.startGroupAction(),a=!0,M={type:"PositionChanged",redoObject:$(o),undoObject:$(this.undoElement),category:"Internal"},o.nodes[0]&&o.nodes[0].processId&&(u={type:"SizeChanged",category:"Internal",undoObject:this.undoParentElement,redoObject:this.commandHandler.getSubProcess(e.source)},this.commandHandler.addHistoryEntry(u)),this.commandHandler.addHistoryEntry(M))),this.commandHandler.snapPoint(this.prevPosition,this.currentPosition,0,0),this.commandHandler.removeSnap(),this.commandHandler.removeHighlighter(),e.source&&this.currentTarget&&RI(this.currentTarget)&&this.commandHandler.isDroppable(e.source,this.currentTarget)){if(p=!0,this.commandHandler.drop(this.currentElement,this.currentTarget,this.currentPosition),this.currentTarget&&this.currentTarget instanceof de&&!0===this.commandHandler.diagram.enableConnectorSplit)if(this.currentElement&&this.currentElement instanceof te){if(void 0!==this.currentElement.children)for(b=0;b0)for(var s=0;s0)for(var a=0;a0)for(a=0;a0&&e.connectors.length>0)||e.width===this.undoElement.width&&e.height===this.undoElement.height)},t.prototype.mouseMove=function(e){n.prototype.mouseMove.call(this,e);var r,s,i=!1;(r=this.commandHandler.renderContainerHelper(e.source)||e.source)instanceof te||r instanceof de?r instanceof te?r.offsetX===this.undoElement.nodes[0].offsetX&&r.offsetY===this.undoElement.nodes[0].offsetY&&(i=!0):R.equals(r.sourcePoint,this.undoElement.connectors[0].sourcePoint)&&R.equals(r.targetPoint,this.undoElement.connectors[0].targetPoint)&&(i=!0):r.wrapper.offsetX===this.undoElement.wrapper.offsetX&&r.wrapper.offsetY===this.undoElement.wrapper.offsetY&&(i=!0),r&&(s={offsetX:r.wrapper.offsetX,offsetY:r.wrapper.offsetY});var o={source:r,state:"Start",oldValue:s,newValue:s,target:e.target,targetPosition:e.position,allowDrop:!0,cancel:!1};if(o={source:r,state:"Start",oldValue:s,newValue:s,target:e.target,targetPosition:e.position,allowDrop:o.allowDrop,cancel:o.cancel},this.isStartAction||(this.intialValue={offsetX:r.wrapper.offsetX,offsetY:r.wrapper.offsetY}),i&&!ce()&&(this.commandHandler.triggerEvent(Ce.positionChange,o),this.connectorEndPointChangeEvent(o),this.isStartAction=!0),this.currentPosition=e.position,"Port"!==this.objectType){var h=this.initialOffset.x+(this.currentPosition.x-this.prevPosition.x),c=this.initialOffset.y+(this.currentPosition.y-this.prevPosition.y);this.commandHandler.dragOverElement(e,this.currentPosition),this.commandHandler.disConnect(e.source),this.commandHandler.removeSnap();var d,u=void 0,f=this.commandHandler.snapPoint(this.prevPosition,this.currentPosition,h,c);this.initialOffset.x=h-f.x,this.initialOffset.y=c-f.y,r&&(d={offsetX:r.wrapper.offsetX,offsetY:r.wrapper.offsetY},u={offsetX:r.wrapper.offsetX+f.x,offsetY:r.wrapper.offsetY+f.y}),this.currentTarget&&e.target!==this.currentTarget&&this.commandHandler.removeChildFromBPmn(e.source,e.target,this.currentTarget),this.currentTarget=e.target;var p={source:r,state:"Progress",oldValue:d,newValue:u,target:e.target,targetPosition:e.position,allowDrop:!0,cancel:!1};if(this.commandHandler.triggerEvent(Ce.positionChange,p),this.canTrigger=!0,this.connectorEndPointChangeEvent(p,f),!p.cancel&&!this.canCancel){this.blocked=!this.commandHandler.dragSelectedObjects(f.x,f.y);var g=!this.commandHandler.mouseOver(this.currentElement,this.currentTarget,this.currentPosition);this.blocked=this.blocked||g}if(this.commandHandler.removeStackHighlighter(),this.commandHandler.renderStackHighlighter(e),this.currentTarget&&e.source!==this.currentTarget&&this.commandHandler.isDroppable(e.source,this.currentTarget)&&"helper"!==e.source.id){var v=e.source instanceof ei?e.source.nodes[0]:e.source;!this.commandHandler.isParentAsContainer(v,!0)&&"SwimLane"!==v.shape.type&&!v.shape.isPhase&&(this.currentTarget.isLane?this.commandHandler.renderStackHighlighter(e,this.currentTarget):this.commandHandler.drawHighlighter(this.currentTarget))}else this.commandHandler.removeHighlighter();if(this.commandHandler.canEnableDefaultTooltip()){var y=this.getTooltipContent(e.source);this.commandHandler.showTooltip(e.source,e.position,ko(function(){return y}),"MoveTool",this.isTooltipVisible),this.isTooltipVisible=!1}}else{var b=Bi(),M=e.source;qi(b,-M.rotateAngle||-M.wrapper.rotateAngle,M.offsetX||M.wrapper.offsetX,M.offsetY||M.wrapper.offsetY);var w=Ke(b,{x:this.prevPosition.x,y:this.prevPosition.y}),C=Ke(b,{x:e.position.x,y:e.position.y});this.commandHandler.portDrag(e.source,e.sourceWrapper,C.x-w.x,C.y-w.y)}return this.prevPosition=this.currentPosition,!this.blocked},t.prototype.getTooltipContent=function(e){return"X:"+Math.round(e.wrapper.bounds.x)+" Y:"+Math.round(e.wrapper.bounds.y)},t.prototype.mouseLeave=function(e){this.mouseUp(e)},t.prototype.endAction=function(){n.prototype.endAction.call(this),this.currentTarget=null,this.prevPosition=null},t}(us),Qx=function(n){function t(e){var i=n.call(this,e,!0)||this;return i.rotateStart=!1,i}return ds(t,n),t.prototype.mouseDown=function(e){if(this.undoElement=$(e.source),this.undoElement.nodes[0]&&this.undoElement.nodes[0].children)for(var r=this.commandHandler.getAllDescendants(this.undoElement.nodes[0],[]),s=0;s=2){var s=e.startTouches[0],o=e.startTouches[1],a=e.moveTouches[0],l=e.moveTouches[1],h=this.getDistance(a,l)/this.getDistance(s,o);this.commandHandler.zoom(h,0,0,e.position),this.updateTouch(s,a),this.updateTouch(o,l)}}else this.commandHandler.scroll(this.currentPosition.x-this.prevPosition.x,this.currentPosition.y-this.prevPosition.y,this.currentPosition);return this.commandHandler.dataBinding(),!this.blocked},t.prototype.mouseUp=function(e){this.commandHandler.setBlazorDiagramProps(!1),this.checkPropertyValue(),this.commandHandler.updatePanState(!1),n.prototype.mouseUp.call(this,e),this.inAction=!1},t.prototype.endAction=function(){n.prototype.endAction.call(this)},t.prototype.getDistance=function(e,i){var r=i.pageX-e.pageX,s=i.pageY-e.pageY;return Math.sqrt(r*r+s*s)},t.prototype.updateTouch=function(e,i){e.pageX=i.pageX,e.pageY=i.pageY},t}(us),One=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseUp=function(e){this.checkPropertyValue(),this.commandHandler.initExpand(e),n.prototype.mouseUp.call(this,e)},t}(us),X3=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseUp=function(e){this.checkPropertyValue();var i="_blank",r="",s=window.innerHeight,o=window.innerWidth,a=window.screenTop,l=window.screenLeft;"CurrentTab"===e.sourceWrapper.hyperlink.hyperlinkOpenState?i="_self":"NewWindow"===e.sourceWrapper.hyperlink.hyperlinkOpenState&&(r="height="+s+",width="+o+",top="+a+",left="+l),window.open(e.sourceWrapper.hyperlink.link,i,r).focus(),n.prototype.mouseUp.call(this,e)},t}(us),zl=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseDown=function(e){if(n.prototype.mouseDown.call(this,e),this.inAction=!0,this.drawingObject){var r=void 0,s=this.drawingObject.shape;this.drawingObject.shape.points.push(r={x:(r=s.points[s.points.length-1]).x,y:r.y})}else{this.startPoint={x:this.startPosition.x,y:this.startPosition.y};var i={offsetX:this.currentPosition.x,offsetY:this.currentPosition.y,width:5,height:5,shape:{type:"Basic",shape:"Polygon",points:[{x:this.startPoint.x,y:this.startPoint.y},{x:this.currentPosition.x,y:this.currentPosition.y}]}};this.triggerElementDrawEvent(e.source,"Start","Node",this.getShapeType(),!0),this.drawingObject=this.commandHandler.drawObject(i)}},t.prototype.mouseMove=function(e){if(n.prototype.mouseMove.call(this,e),this.inAction){var i=this.drawingObject.shape;if(i.points[i.points.length-1].x=this.currentPosition.x,i.points[i.points.length-1].y=this.currentPosition.y,this.drawingObject.wrapper.children[0].data=mx(this.drawingObject.shape.points),this.triggerElementDrawEvent(this.drawingObject,"Progress","Node",this.getShapeType(),!1),this.inAction&&!1===R.equals(this.currentPosition,this.prevPosition)){var r=Ne.toBounds(this.drawingObject.shape.points);this.commandHandler.updateNodeDimension(this.drawingObject,r)}}return!0},t.prototype.mouseUp=function(e,i){this.checkPropertyValue(),n.prototype.mouseMove.call(this,e),this.inAction&&(this.inAction=!1,this.commandHandler.addObjectToDiagram(this.drawingObject),this.triggerElementDrawEvent(this.drawingObject,"Completed","Node",this.getShapeType(),!1)),this.endAction()},t.prototype.mouseWheel=function(e){n.prototype.mouseWheel.call(this,e),this.mouseMove(e)},t.prototype.endAction=function(){this.inAction=!1,this.drawingObject=null},t}(us),Rl=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseMove=function(e){if(n.prototype.mouseMove.call(this,e),this.inAction){var i=this.drawingObject;i.targetPoint=this.currentPosition,this.triggerElementDrawEvent(this.drawingObject,"Progress","Connector",this.drawingObject.type,!1),this.commandHandler.updateConnectorPoints(i)}return!0},t.prototype.mouseDown=function(e){if(n.prototype.mouseDown.call(this,e),this.inAction=!0,this.drawingObject){var r=this.drawingObject,s=void 0;(s=new Hl(r,"segments",{type:"Straight"},!0)).point=this.currentPosition,r.segments[r.segments.length-1]=s}else{var i={id:"Connector",type:"Straight",sourcePoint:this.currentPosition,targetPoint:this.currentPosition};this.triggerElementDrawEvent(e.source,"Start","Connector",this.commandHandler.diagram.drawingObject.type,!0),this.inAction&&(this.drawingObject=this.commandHandler.drawObject(i))}},t.prototype.mouseWheel=function(e){n.prototype.mouseWheel.call(this,e),this.mouseMove(e)},t.prototype.mouseUp=function(e){if(this.checkPropertyValue(),n.prototype.mouseMove.call(this,e),this.inAction&&this.drawingObject){var i=this.drawingObject;i.segments[i.segments.length-1].point={x:0,y:0},this.commandHandler.addObjectToDiagram(this.drawingObject),this.triggerElementDrawEvent(this.drawingObject,"Completed","Connector",this.drawingObject.type,!1)}this.endAction()},t.prototype.endAction=function(){this.drawingObject=null,this.inAction=!1},t}(us),kne=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseDown=function(e){this.inAction=!0,this.undoElement=$(e.source),this.annotationId=e.sourceWrapper.id,n.prototype.mouseDown.call(this,e)},t.prototype.mouseMove=function(e){n.prototype.mouseMove.call(this,e);var i=this.currentPosition.x-this.prevPosition.x,r=this.currentPosition.y-this.prevPosition.y,s=e.source;if(s instanceof te){var o=Bi();qi(o,-s.rotateAngle,0,0);var a=Ke(o,{x:i,y:r});i=a.x,r=a.y}return this.inAction&&(this.commandHandler.labelDrag(e.source,e.sourceWrapper,i,r),this.commandHandler.updateSelector()),this.prevPosition=this.currentPosition,!this.blocked},t.prototype.mouseUp=function(e){this.checkPropertyValue();var i=e.source;this.inAction=!1;var r={type:"AnnotationPropertyChanged",objectId:this.annotationId,undoObject:$(this.undoElement),category:"Internal",redoObject:$(i)};this.commandHandler.addHistoryEntry(r),n.prototype.mouseUp.call(this,e)},t.prototype.mouseLeave=function(e){this.mouseUp(e)},t}(us),Pne=function(n){function t(e,i){var r=n.call(this,e,!0)||this;return r.corner=i,r}return ds(t,n),t.prototype.mouseDown=function(e){this.inAction=!0;var i=e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0];this.annotationId=e.source.wrapper.children[0].id,this.undoElement=$(i);var r=e.source.wrapper.children[0];this.initialBounds={x:r.offsetX,y:r.offsetY,width:r.actualSize.width,height:r.actualSize.height},n.prototype.mouseDown.call(this,e)},t.prototype.mouseMove=function(e){return n.prototype.mouseMove.call(this,e),this.inAction&&this.resizeObject(e),!this.blocked},t.prototype.mouseUp=function(e){this.checkPropertyValue();var i=e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0];this.inAction=!1;var r={type:"AnnotationPropertyChanged",objectId:this.annotationId,redoObject:$(i),undoObject:$(this.undoElement),category:"Internal"};this.commandHandler.addHistoryEntry(r),n.prototype.mouseUp.call(this,e)},t.prototype.mouseLeave=function(e){this.mouseUp(e)},t.prototype.resizeObject=function(e){var i,s,o,r=e.source.wrapper.children[0],a={x:r.offsetX,y:r.offsetY},l=r.rotateAngle;l=((l+=(i=e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0])instanceof te?i.rotateAngle:0)+360)%360;var h=Bi();qi(h,l,a.x,a.y);var c=this.corner.slice(5),d=this.updateSize(r,this.startPosition,this.currentPosition,c,this.initialBounds,l),u=r.offsetX-r.actualSize.width*r.pivot.x,f=r.offsetY-r.actualSize.height*r.pivot.y,p=this.getPivot(c),g=Ke(h,p={x:u+r.actualSize.width*p.x,y:f+r.actualSize.height*p.y});d.x=g.x,d.y=g.y,this.commandHandler.labelResize(i,e.source.annotation,s=(s=d.width)<0?1:s,o=(o=d.height)<0?1:o,d,e.source),this.commandHandler.updateSelector()},t}(us),zne=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseDown=function(e){this.inAction=!0,this.annotationId=e.source.wrapper.children[0].id,this.undoElement=$(e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0]),n.prototype.mouseDown.call(this,e)},t.prototype.mouseMove=function(e){return n.prototype.mouseMove.call(this,e),e.source&&this.inAction&&(this.commandHandler.labelRotate(e.source.nodes[0]?e.source.nodes[0]:e.source.connectors[0],e.source.annotation,this.currentPosition,e.source),this.commandHandler.updateSelector()),this.prevPosition=this.currentPosition,!this.blocked},t.prototype.mouseUp=function(e){this.checkPropertyValue(),this.inAction=!1;var r={type:"AnnotationPropertyChanged",objectId:this.annotationId,redoObject:$(e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0]),undoObject:$(this.undoElement),category:"Internal"};this.commandHandler.addHistoryEntry(r),n.prototype.mouseUp.call(this,e)},t.prototype.mouseLeave=function(e){this.mouseUp(e)},t}(us),Rne=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseMove=function(e){if(n.prototype.mouseMove.call(this,e),this.inAction){var i=this.drawingObject.shape;if(i.points.push(this.currentPosition),this.drawingObject.wrapper.children[0].data=yx(this.drawingObject.shape.points),i.data=yx(i.points),this.triggerElementDrawEvent(e.source,"Progress","Connector",this.drawingObject.type,!1),this.inAction&&!1===R.equals(this.currentPosition,this.prevPosition)){var s=Ne.toBounds(this.drawingObject.shape.points);this.commandHandler.updateNodeDimension(this.drawingObject,s)}}return!0},t.prototype.mouseDown=function(e){n.prototype.mouseDown.call(this,e),this.inAction=!0,this.startPoint={x:this.startPosition.x,y:this.startPosition.y};var i={offsetX:this.currentPosition.x,offsetY:this.currentPosition.y,width:5,height:5,style:{strokeColor:"black",strokeWidth:1,fill:"transparent"},shape:{type:"Path",points:[{x:this.startPoint.x,y:this.startPoint.y},{x:this.currentPosition.x,y:this.currentPosition.y}]}};this.triggerElementDrawEvent(e.source,"Start","Connector",this.commandHandler.diagram.drawingObject.type,!0),this.drawingObject=this.commandHandler.drawObject(i)},t.prototype.mouseUp=function(e){if(this.checkPropertyValue(),this.inAction){this.inAction=!1;var s=this.drawingObject.shape,o=s.points;this.commandHandler.addObjectToDiagram(this.drawingObject),this.commandHandler.diagram.remove(this.commandHandler.diagram.nameTable[""+this.drawingObject.id]),o=this.pointReduction(o,10);var h={id:"newConnector"+Qe(),type:"Bezier",sourcePoint:{x:o[0].x,y:o[0].y},targetPoint:{x:o[o.length-1].x,y:o[o.length-1].y},segments:[],bezierSettings:{allowSegmentsReset:!1}};this.drawingObject=this.commandHandler.drawObject(h),this.drawingObject=this.bezierCurveSmoothness(o,.5,this.drawingObject,s),this.commandHandler.updateConnectorPoints(this.drawingObject),this.commandHandler.addObjectToDiagram(this.drawingObject),this.triggerElementDrawEvent(this.drawingObject,"Completed","Connector",this.drawingObject.type,!1),n.prototype.mouseUp.call(this,e)}},t.prototype.pointReduction=function(e,i){if(null===e||e.length<3)return e;var s=e.length-1,o=[];for(o.push(0),o.push(s);e[parseInt((0).toString(),10)]===e[parseInt(s.toString(),10)];)s--;this.reduction(e,0,s,i,o);var a=[];return o.sort(function(l,h){return l-h}),o.forEach(function(l){a.push(e[parseInt(l.toString(),10)])}),a},t.prototype.reduction=function(e,i,r,s,o){for(var a=0,l=0,h=i;ha&&(a=c,l=h)}a>s&&0!==l&&(o.push(l),this.reduction(e,i,l,s,o),this.reduction(e,l,r,s,o))},t.prototype.perpendicularDistance=function(e,i,r){return Math.abs(.5*(e.x*i.y-i.x*e.y+(i.x*r.y-r.x*i.y)+(r.x*e.y-e.x*r.y)))/Math.sqrt(Math.pow(e.x-i.x,2)+Math.pow(e.y-i.y,2))*2},t.prototype.bezierCurveSmoothness=function(e,i,r,s){if(e.length<3)return r;for(var o=0;o=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Hne=function(n){if(n)switch(n.type){case"Bpmn":return Une;case"UmlActivity":return _ne;case"UmlClassifier":return Wne;default:return em}return em},Bne=function(n){if(n)switch(n.type){case"Straight":default:return Hl;case"Bezier":return fs;case"Orthogonal":return wi}},q3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I(10)],t.prototype,"width",void 0),Pe([I(10)],t.prototype,"height",void 0),Pe([I("Arrow")],t.prototype,"shape",void 0),Pe([re({fill:"black",strokeColor:"black",strokeWidth:1},Ll)],t.prototype,"style",void 0),Pe([re({x:0,y:.5},R)],t.prototype,"pivot",void 0),Pe([I("")],t.prototype,"pathData",void 0),t}(Ee),XI=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I(0)],t.prototype,"angle",void 0),Pe([I(0)],t.prototype,"distance",void 0),t}(Ee),Fne=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I(Mx.All)],t.prototype,"controlPointsVisibility",void 0),Pe([I("FreeForm")],t.prototype,"segmentEditOrientation",void 0),Pe([I(bI.Default)],t.prototype,"smoothness",void 0),Pe([I(!0)],t.prototype,"allowSegmentsReset",void 0),t}(Ee),em=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I("None")],t.prototype,"type",void 0),t}(Ee),_ne=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I("Object")],t.prototype,"flow",void 0),Pe([I(30)],t.prototype,"exceptionFlowHeight",void 0),t}(em),Une=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I("Sequence")],t.prototype,"flow",void 0),Pe([I("Normal")],t.prototype,"sequence",void 0),Pe([I("Default")],t.prototype,"message",void 0),Pe([I("Default")],t.prototype,"association",void 0),t}(em),$3=function(n){function t(e,i,r,s){var o=n.call(this,e,i,r,s)||this;return o.points=[],o}return Qs(t,n),Pe([I("Straight")],t.prototype,"type",void 0),Pe([I(!0)],t.prototype,"allowDrag",void 0),t}(Ee),Hl=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),t.prototype.getClassName=function(){return"StraightSegment"},Pe([re({x:0,y:0},R)],t.prototype,"point",void 0),t}($3),fs=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),t.prototype.getClassName=function(){return"BezierSegment"},t.prototype.getPoints=function(e,i){var r=[];if(r.length>0||null!=i){var o=this.bezireToPoly(r.length>0?r[r.length-1]:i,e);r.push.apply(r,o)}return r},t.prototype.bezireToPoly=function(e,i){var r=[];return i&&this.flattenCubicBezier(r,e,i.bezierPoint1,i.bezierPoint2,{x:i.points[1].x,y:i.points[1].y},10),r},t.prototype.flattenCubicBezier=function(e,i,r,s,o,a){var h,l=(R.findLength(i,r)+R.findLength(r,s)+R.findLength(s,o))/a;for(h=0;h<=l;h++){var c=h/l;e.push({x:(1-c)*(1-c)*(1-c)*i.x+3*c*(1-c)*(1-c)*r.x+3*c*c*(1-c)*s.x+c*c*c*o.x,y:(1-c)*(1-c)*(1-c)*i.y+3*c*(1-c)*(1-c)*r.y+3*c*c*(1-c)*s.y+c*c*c*o.y})}},Pe([I("Horizontal")],t.prototype,"orientation",void 0),Pe([re({x:0,y:0},R)],t.prototype,"point1",void 0),Pe([re({x:0,y:0},R)],t.prototype,"point2",void 0),Pe([re({angle:0,distance:0},XI)],t.prototype,"vector1",void 0),Pe([re({angle:0,distance:0},XI)],t.prototype,"vector2",void 0),t}(Hl),wi=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),t.prototype.getClassName=function(){return"OrthogonalSegment"},Pe([I(null)],t.prototype,"length",void 0),Pe([I(null)],t.prototype,"direction",void 0),t}($3);function Z3(n,t,e){var s=e?45:180/(2+2/(n.height/n.width)),o=s,a=180-s,l=a+2*s,h=360-s,c=Gt(t,n.center);return c>o&&ca&&cl&&cMath.abs(t.y-n.y)?n.x=c)return s=R.findAngle(n[parseInt(d.toString(),10)],n[d+1]),{point:r=R.transform(n[parseInt(d.toString(),10)],s,c-(a||0)),index:l=d};a=o[parseInt(d.toString(),10)]}return{point:r,index:l}}(n,t),r=R.findAngle(n[i.index],n[i.index+1]),s=function yse(n){var e=0;switch(n.alignment){case"Center":case"After":e=0;break;case"Before":e=-0}return e}(t),o=R.transform(i.point,r+45,s);return i.point=o,i.angle=r,i}(i,e),h=l.point;s.id=this.id+"_"+e.id;var c=e.style;s.style={fill:c.fill,strokeColor:c.strokeColor,gradient:null,opacity:c.opacity,strokeDashArray:c.strokeDashArray,strokeWidth:c.strokeWidth},0===r.width&&(r.width=this.style.strokeWidth),0===r.height&&(r.height=this.style.strokeWidth);var d_y=(h.y-r.y)/r.height;a.x=r.width*((h.x-r.x)/r.width),a.y=r.height*d_y;var g,v,u=fF(e,l.angle,i),f=u.hAlign,p=u.vAlign;return"left"===f?(g="Left",a.x+=e.displacement.x):"right"===f?(g="Right",a.x-=e.displacement.x):"center"===f&&(g="Center"),"top"===p?(v="Top",a.y+=e.displacement.y):"bottom"===p?(v="Bottom",a.y-=e.displacement.y):"center"===p&&(v="Center"),s.horizontalAlignment=g,s.verticalAlignment=v,(s=rm(s,o&&"Label"!==o.flipMode&&"None"!==o.flipMode?this.flip:"None",e)).float=!0,s.connectionDirection=e.connectionDirection,s.setOffsetWithRespectToBounds(a.x,a.y,"Absolute"),s.relativeMode="Point",s.visible=!(!va(e,ri.Visible)||va(e,ri.Hover)||va(e,ri.Connect)),s.elementActions=s.elementActions|Xr.ElementIsPort,s},t.prototype.getConnectorRelation=function(){var e=this.shape;"Association"===e.relationship?(this.segments[0].type="Straight",this.sourceDecorator.shape="None",this.targetDecorator.shape="Arrow"):"Inheritance"===e.relationship?(this.segments[0].type="Orthogonal",this.sourceDecorator.shape="None",this.targetDecorator.shape="Arrow"):"Composition"===e.relationship||"Aggregation"===e.relationship?(this.segments[0].type="Orthogonal",this.sourceDecorator.shape="Diamond",this.targetDecorator.shape="None"):"Dependency"===e.relationship?(this.segments[0].type="Orthogonal",this.sourceDecorator.shape="None",this.targetDecorator.shape="OpenArrow"):"Realization"===e.relationship&&(this.segments[0].type="Orthogonal",this.sourceDecorator.shape="None",this.targetDecorator.shape="Arrow"),"BiDirectional"===e.associationType&&(this.sourceDecorator.shape="None",this.targetDecorator.shape="None");var i,o,r="",s="";e.multiplicity.source&&(e.multiplicity.source.lowerBounds=e.multiplicity.source.lowerBounds,e.multiplicity.source.upperBounds=e.multiplicity.source.upperBounds),e.multiplicity.target&&(e.multiplicity.target.lowerBounds=e.multiplicity.target.lowerBounds,e.multiplicity.target.upperBounds=e.multiplicity.target.upperBounds);var a=e.multiplicity.source,l=e.multiplicity.target;o=a.upperBounds?a.lowerBounds+"..."+a.upperBounds:a.lowerBounds,i=l.upperBounds?l.lowerBounds+"..."+l.upperBounds:l.lowerBounds,"ManyToOne"===e.multiplicity.type&&(e.multiplicity.target.optional=!1,r=o||"*",s="1"),"OneToMany"===e.multiplicity.type&&(e.multiplicity.source.optional=!1,s=i||"*",r="1"),"ManyToMany"===e.multiplicity.type&&(r=o||"*",s=i||"*"),"OneToOne"===e.multiplicity.type&&(e.multiplicity.target.optional=!1,e.multiplicity.source.optional=!1,r="1",s="1"),this.annotations=[{id:this.id+"sourcelabel",content:r,offset:0,alignment:"Before",margin:{right:5,bottom:5}},{id:this.id+"targetlabel",content:s,offset:1,alignment:"Before",margin:{right:5,bottom:5}}]},t.prototype.getBpmnSequenceFlow=function(){var e=new Ze,i=new Ze;return"Normal"===this.shape.sequence&&"Bezier"!==this.type&&(this.targetDecorator.shape="Arrow"),"Default"===this.shape.sequence&&(e=this.getSegmentElement(this,e),i=IF(this.intermediatePoints,this),this.targetDecorator.shape="Arrow"),"Conditional"===this.shape.sequence&&(this.targetDecorator.shape="Arrow",this.sourceDecorator.shape="Diamond",i.id=this.id+this.shape.type),i},t.prototype.getUMLObjectFlow=function(){if(this.annotations)for(var e=0;e0&&(this.sourcePoint=o[0],this.targetPoint=o[o.length-1]),o},t.prototype.clipDecorator=function(e,i,r,s){var a,l,o={x:0,y:0},h=i.length,c=R.distancePoints(a=r?i[0]:i[h-1],l=r?i[1]:i[h-2]);c=0===c?1:c;var d=1,u=r?e.sourceWrapper:e.targetWrapper;u&&(d=u.style.strokeWidth,s&&s&ee.DecoratorPropertyChange&&(d=1));var f=d-1;return o.x=Math.round(a.x+f*(l.x-a.x)/c),o.y=Math.round(a.y+f*(l.y-a.y)/c),(r&&"None"!==e.sourceDecorator.shape||!r&&"None"!==e.targetDecorator.shape)&&(o=R.adjustPoint(o,l,!0,s&ee.DecoratorPropertyChange?0:d/2)),o},t.prototype.clipDecorators=function(e,i,r){return"None"!==e.sourceDecorator.shape&&(i[0]=this.clipDecorator(e,i,!0,r)),"None"!==e.targetDecorator.shape&&(i[i.length-1]=this.clipDecorator(e,i,!1,r)),i},t.prototype.updateSegmentElement=function(e,i,r,s){var o=new Ne,a=this.getSegmentPath(e,i,s);if("Bezier"===e.type){if(this.segments.length>0)for(var l=0;l0)if("Straight"===e.type&&e.segments.length<2)for(var o=0;o1)for(o=0;o0&&"Bezier"!==this.type)for(var f=0;f0&&(a=f0&&(p<2*this.cornerRadius?(l=R.adjustPoint(h[parseInt(f.toString(),10)],h[f+1],!0,p/2),f0&&(s=this.bridgePath(e,s,f),"Orthogonal"===e.type&&(s=this.bridgePath(e,s,f+1))),s+=" L"+a.x+" "+a.y))}else if("Bezier"===this.type){var g=void 0,v=void 0;if(this.parentObj.element){var y=this.parentObj.element.ej2_instances[0].eventHandler.action;g=this.parentObj.element.ej2_instances[0].eventHandler.tool instanceof Pd,v=y.includes("PortDraw")||y.includes("Drag")}for(var S=void 0,b=this.segments,M=0;M2&&(b[parseInt(M.toString(),10)].bezierPoint1={x:0,y:0},b[parseInt(M.toString(),10)].bezierPoint2={x:0,y:0}),!R.isEmptyPoint(b[parseInt(M.toString(),10)].point1)||b[parseInt(M.toString(),10)].vector1.angle||b[parseInt(M.toString(),10)].vector1.distance?b[parseInt(M.toString(),10)].vector1.angle||b[parseInt(M.toString(),10)].vector1.distance?b[parseInt(M.toString(),10)].bezierPoint1=R.transform(h[parseInt(M.toString(),10)],b[parseInt(M.toString(),10)].vector1.angle,b[parseInt(M.toString(),10)].vector1.distance):b[parseInt(M.toString(),10)].bezierPoint1={x:b[parseInt(M.toString(),10)].point1.x||b[parseInt(M.toString(),10)].bezierPoint1.x,y:b[parseInt(M.toString(),10)].point1.y||b[parseInt(M.toString(),10)].bezierPoint1.y}:((e.sourceID||this.sourcePortID)&&this.sourceWrapper&&!v&&!g&&(S=Z3(this.sourceWrapper.bounds,h[parseInt(M.toString(),10)],!0)),b[parseInt(M.toString(),10)].bezierPoint1=$I(h[parseInt(M.toString(),10)],h[M+1],S)),!R.isEmptyPoint(b[parseInt(M.toString(),10)].point2)||b[parseInt(M.toString(),10)].vector2.angle||b[parseInt(M.toString(),10)].vector2.distance?b[parseInt(M.toString(),10)].vector2.angle||b[parseInt(M.toString(),10)].vector2.distance?b[parseInt(M.toString(),10)].bezierPoint2=R.transform(h[M+1],b[parseInt(M.toString(),10)].vector2.angle,b[parseInt(M.toString(),10)].vector2.distance):b[parseInt(M.toString(),10)].bezierPoint2={x:b[parseInt(M.toString(),10)].point2.x||b[parseInt(M.toString(),10)].bezierPoint2.x,y:b[parseInt(M.toString(),10)].point2.y||b[parseInt(M.toString(),10)].bezierPoint2.y}:((e.targetID||this.targetPortID)&&this.targetWrapper&&!v&&!g&&(S=Z3(this.targetWrapper.bounds,h[M+1],!0)),b[parseInt(M.toString(),10)].bezierPoint2=$I(h[M+1],h[parseInt(M.toString(),10)],S));h.splice(1,0,{x:b[0].bezierPoint1.x,y:b[0].bezierPoint1.y}),h.splice(h.length-1,0,{x:b[b.length-1].bezierPoint2.x,y:b[b.length-1].bezierPoint2.y}),h=this.clipDecorators(e,h,r);for(var w=0;w0&&(s=this.bridgePath(e,s,D),s+=" L"+o.x+" "+o.y);return s},t.prototype.updateShapeElement=function(e){var i;switch(e.shape.type){case"Bpmn":e.wrapper.children[3]instanceof Ze&&(i=e.wrapper.children[3]),"Message"===e.shape.flow&&this.updateShapePosition(e,i);break;case"UmlActivity":"Exception"===e.shape.flow&&this.getUMLExceptionFlow(e.wrapper.children[0])}},t.prototype.updateShapePosition=function(e,i){var o=bF(this.intermediatePoints,i,.5);i.offsetX=o.x,i.offsetY=o.y},t.prototype.scale=function(e,i,r,s,o){var a=0,l=0;if(this.wrapper&&this.wrapper.outerBounds){var h=function M3(n){var t=n.wrapper.children[0].bounds;return"None"!==n.sourceDecorator.shape&&t.uniteRect(n.wrapper.children[1].bounds),"None"!==n.targetDecorator.shape&&t.uniteRect(n.wrapper.children[2].bounds),t}(this),c=Math.abs((this.wrapper.bounds.width||this.style.strokeWidth||1)-2),d=Math.abs((this.wrapper.bounds.height||this.style.strokeWidth||1)-2);a=h.width-c,l=h.height-d,e=Math.abs((r-Math.max(a,l))/c),i=Math.abs((s-Math.max(a,l))/d),a=l=Math.min(a,l)}e=i=Math.min(e,i);var u=Bi();qi(u,-(o=o||this.wrapper).rotateAngle,o.offsetX,o.offsetY),Gf(u,e,i,o.offsetX,o.offsetY),qi(u,o.rotateAngle,o.offsetX,o.offsetY);var f=function Oie(n,t){for(var e=[],i=0,r=t;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Qne=function(n){function t(e,i){var r=n.call(this,e,i)||this;return r.offset=0,r.scale=1,r}return Yne(t,n),t.prototype.preRender=function(){this.unWireEvents(),this.wireEvents()},t.prototype.render=function(){this.updateRulerGeometry(),this.renderComplete()},t.prototype.getModuleName=function(){return"Ruler"},t.prototype.destroy=function(){this.unWireEvents(),this.notify("destroy",{}),n.prototype.destroy.call(this),this.element.classList.remove("e-ruler")},t.prototype.getPersistData=function(){return this.addOnPersist(["loaded"])},t.prototype.onPropertyChanged=function(e,i){for(var r=0,s=Object.keys(e);r100;)r/=10,s/=10;for(;s<25;)r*=10,s*=10;return s>=25&&s%25!=0&&(s=25*Math.round(s/25)),s*e/r},t.prototype.createMarkerLine=function(e,i,r){var s;return i&&((s=e.getElementById(i.id+"_marker"))&&s.parentNode.removeChild(s),s=Fi("line",r)),s},t.prototype.drawRulerMarker=function(e,i,r){var s,o,h,d,u="Horizontal"===this.orientation,f=e.getElementsByTagName("svg");for(h=0;h0)for(var a=i.childNodes.length-1;a>=0;a--)i.childNodes[parseInt(a.toString(),10)].parentNode.removeChild(i.childNodes[parseInt(a.toString(),10)]);i.appendChild(s)}return s},t.prototype.wireEvents=function(){},t.prototype.unWireEvents=function(){},kc([I(5)],t.prototype,"interval",void 0),kc([I(100)],t.prototype,"segmentWidth",void 0),kc([I("Horizontal")],t.prototype,"orientation",void 0),kc([I("RightOrBottom")],t.prototype,"tickAlignment",void 0),kc([I("red")],t.prototype,"markerColor",void 0),kc([I(25)],t.prototype,"thickness",void 0),kc([I(null)],t.prototype,"arrangeTick",void 0),kc([I(400)],t.prototype,"length",void 0),t}(Ii);function eF(n,t){var e=document.getElementById(n.element.id+(t?"_hRuler":"_vRuler")),i=Za(n),r=tF(n);e||(e=Tt("div",{id:n.element.id+(t?"_hRuler":"_vRuler"),style:"height:"+(t?i.height:r.height+100)+"px;overflow:hidden;width:"+(t?r.width+100:i.width)+"px;position:absolute;font-size:11px;"+(t?"margin-left:"+i.width+"px;":"margin-top:"+i.height+"px;")})),n.element.insertBefore(e,n.element.firstChild);var l=t?n.rulerSettings.horizontalRuler:n.rulerSettings.verticalRuler,h=new Qne(l);h.orientation=t?"Horizontal":"Vertical",h.length=(t?r.width:r.height)+l.segmentWidth,h.appendTo("#"+n.element.id+(t?"_hRuler":"_vRuler")),t?n.hRuler=h:n.vRuler=h;var c=document.getElementById(n.element.id+(t?"_hRuler":"_vRuler"));t?n.hRuler.element=c:n.vRuler.element=c}function ZI(n){var t=-n.scroller.horizontalOffset,e=-n.scroller.verticalOffset;n&&n.rulerSettings.showRulers?(n.hRuler.length=0,n.vRuler.length=0,void 0!==t&&n.hRuler.element&&iF(n,n.hRuler,t,!0),void 0!==e&&n.vRuler.element&&iF(n,n.vRuler,e,!1)):Gx(n)}function Gx(n){an(n.element.id+"_hRuler"),an(n.element.id+"_vRuler"),an(n.element.id+"_overlapRuler")}function Za(n){var t=0,e=0;return n.rulerSettings.showRulers&&(t=n.rulerSettings.horizontalRuler.thickness,e=n.rulerSettings.verticalRuler.thickness),new me(e,t)}function tF(n){var t=Za(n),e=n.scroller.viewPortHeight,i=n.scroller.viewPortWidth;return i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},rF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Jne(t,n),t.prototype.getClassName=function(){return"UserHandle"},Un([I("")],t.prototype,"name",void 0),Un([I("")],t.prototype,"pathData",void 0),Un([I("")],t.prototype,"content",void 0),Un([I("")],t.prototype,"source",void 0),Un([I("#000000")],t.prototype,"backgroundColor",void 0),Un([I("Top")],t.prototype,"side",void 0),Un([I("")],t.prototype,"borderColor",void 0),Un([I(.5)],t.prototype,"borderWidth",void 0),Un([I(25)],t.prototype,"size",void 0),Un([I("white")],t.prototype,"pathColor",void 0),Un([I(10)],t.prototype,"displacement",void 0),Un([I(!0)],t.prototype,"visible",void 0),Un([I(0)],t.prototype,"offset",void 0),Un([re({},Jn)],t.prototype,"margin",void 0),Un([I("Center")],t.prototype,"horizontalAlignment",void 0),Un([I("Center")],t.prototype,"verticalAlignment",void 0),Un([I(!1)],t.prototype,"disableNodes",void 0),Un([I(!1)],t.prototype,"disableConnectors",void 0),Un([re({},Dd)],t.prototype,"tooltip",void 0),Un([I("")],t.prototype,"template",void 0),t}(Ee);function nF(n){return Kne[n.toString()]}var Kne={Action:"M 90 82.895 C 90 86.819 86.776 90 82.8 90 H 7.2 C 3.224 90 0 86.819 0 82.895 V 7.105 C 0 3.181 3.224 0 7.2 0 h 75.6 C 86.776 0 90 3.181 90 7.105 V 82.895 Z",Decision:"M10,19.707L0.293,10L10,0.293L19.707,10L10,19.707z",MergeNode:"M10,19.707L0.293,10L10,0.293L19.707,10L10,19.707z",InitialNode:"M10,19.5c-5.238,0-9.5-4.262-9.5-9.5S4.762,0.5,10,0.5s9.5,4.262,9.5,9.5S15.238,19.5,10,19.5z",ForkNode:"m0.75,0.75l636.00002,0l0,290l-636.00002,0l0,-290z",JoinNode:"m0.75,0.75l636.00002,0l0,290l-636.00002,0l0,-290z",TimeEvent:"M50.001,0.00286865 L25.001,25.0029 L0.000976562,0.00286865 L50.001,0.00286865 z M0.000976562,50.0029 L25.001,25.0029 L50.001,50.0029 L0.000976562,50.0029 z",AcceptingEvent:"M17.8336 32.164 L29.64 24 L17.32 16 L48.1664 16 L48.5 32 Z",SendSignal:"M48.164 31.8336 L56 23.832 L47.836 16 L16.168 16 L16.1668 31.8336 Z",ReceiveSignal:"M48.1664 31.8336 L39.836 24 L47.836 16 L16.168 16 L16.168 31.836 Z",StructuredNode:"M0,0 L50,0 L50,50 L0,50 z",Note:"M20 12 L4 12 L4 22 L22 22 L22 14 L20 14 L20 12 L22 14 Z"},JI=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Ja=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},ese=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return JI(t,n),Ja([I()],t.prototype,"key",void 0),Ja([I()],t.prototype,"keyModifiers",void 0),t}(Ee),sF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return JI(t,n),t.prototype.getClassName=function(){return"Command"},Ja([I("")],t.prototype,"name",void 0),Ja([I()],t.prototype,"canExecute",void 0),Ja([I()],t.prototype,"execute",void 0),Ja([re({},ese)],t.prototype,"gesture",void 0),Ja([I("")],t.prototype,"parameter",void 0),t}(Ee),tse=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return JI(t,n),Ja([Bt([],sF)],t.prototype,"commands",void 0),t}(Ee),ise=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return JI(t,n),Ja([I()],t.prototype,"show",void 0),Ja([I()],t.prototype,"showCustomMenuOnly",void 0),Ja([I()],t.prototype,"items",void 0),t}(Ee),Jf=function(){function n(){}return n.prototype.renderShadow=function(t,e,i,r){void 0===i&&(i=null);var l,o=R.transform({x:0,y:0},t.shadow.angle,t.shadow.distance);r&&(l=r.getElementById(e.id+"_shadow")),l||(l=document.createElementNS("http://www.w3.org/2000/svg",i?"path":"rect"),e.appendChild(l));var h={id:e.id+"_shadow",fill:t.shadow.color,stroke:t.shadow.color,opacity:t.shadow.opacity.toString(),transform:"rotate("+t.angle+","+(t.x+t.width*t.pivotX)+","+(t.y+t.height*t.pivotY)+")translate("+(t.x+o.x)+","+(t.y+o.y)+")"};if(r){var c=r.getElementById(e.id);c&&c.insertBefore(l,c.firstChild)}ti(l,h),i?i&&this.renderPath(l,t,i):ti(l,{width:t.width,height:t.height})},n.prototype.parseDashArray=function(t){return[]},n.prototype.drawRectangle=function(t,e,i,r,s,o,a,l,h){var c,d,u,f;e.shadow&&!r&&this.renderShadow(e,t,void 0,o),c=e.id===t.id?e.id+"_container":e.id,o&&(d=o.getElementById(c)),(!d||s)&&(d=document.createElementNS("http://www.w3.org/2000/svg","rect"),t.appendChild(d)),o&&!e.shadow&&(u=o.getElementById(e.id+"_groupElement_shadow"))&&u.parentNode.removeChild(u),f=l?{id:c,x:e.x.toString(),y:e.y.toString(),width:e.width.toString(),height:e.height.toString(),visibility:e.visible?"visible":"hidden",transform:"rotate("+e.angle+","+(e.x+e.width/2)+","+(e.y+e.height/2)+")",rx:e.cornerRadius||0,ry:e.cornerRadius||0,opacity:e.opacity}:{id:c,x:e.x.toString(),y:e.y.toString(),width:e.width.toString(),height:e.height.toString(),visibility:e.visible?"visible":"hidden",transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")",rx:e.cornerRadius||0,ry:e.cornerRadius||0,opacity:e.opacity},a&&(f.role="img",f["aria-label"]=a);var p=e.class||"";h||(p.includes("e-diagram-resize-handle")||p.includes("e-diagram-endpoint-handle")||p.includes("e-diagram-bezier-control-handle"))&&(p+=" e-disabled"),e.class&&(f.class=p),a||(f["pointer-events"]="none"),ti(d,f),this.setSvgStyle(d,e,i)},n.prototype.updateSelectionRegion=function(t,e){var i;i=t.parentNode.getElementById(e.id);var r={id:e.id,x:e.x.toString(),y:e.y.toString(),width:e.width.toString(),height:e.height.toString(),transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")",class:"e-diagram-selected-region"};i||(i=document.createElementNS("http://www.w3.org/2000/svg","rect"),t.appendChild(i)),this.setSvgStyle(i,e),ti(i,r)},n.prototype.createGElement=function(t,e){return Fi(t,e)},n.prototype.drawLine=function(t,e){var i=document.createElementNS("http://www.w3.org/2000/svg","line");this.setSvgStyle(i,e);var r=e.x+e.width*e.pivotX,s=e.y+e.height*e.pivotY,o={id:e.id,x1:e.startPoint.x+e.x,y1:e.startPoint.y+e.y,x2:e.endPoint.x+e.x,y2:e.endPoint.y+e.y,stroke:e.stroke,"stroke-width":e.strokeWidth.toString(),opacity:e.opacity.toString(),transform:"rotate("+e.angle+" "+r+" "+s+")",visibility:e.visible?"visible":"hidden"};e.class&&(o.class=e.class),ti(i,o),t.appendChild(i)},n.prototype.drawCircle=function(t,e,i,r){var s=document.createElementNS("http://www.w3.org/2000/svg","circle");this.setSvgStyle(s,e);var o=e.class||"";i||(o+=" e-disabled");var a={id:e.id,cx:e.centerX,cy:e.centerY,r:e.radius,visibility:e.visible?"visible":"hidden",class:o};r&&(a.role="img",a["aria-label"]=r),s.style.display=e.visible?"block":"none",ti(s,a),t.appendChild(s)},n.prototype.drawPath=function(t,e,i,r,s,o,a){var h,c,l=[];l=XB(l=Ed(e.data)),e.shadow&&this.renderShadow(e,t,l,s),s&&!e.shadow&&(h=s.getElementById(e.id+"_groupElement_shadow"))&&h.parentNode.removeChild(h),s&&(c=s.getElementById(e.id)),(!c||r)&&(c=document.createElementNS("http://www.w3.org/2000/svg","path"),t.appendChild(c)),this.renderPath(c,e,l);var d={};d=a?{id:e.id,transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")translate("+e.x+","+e.y+"),scale("+a+")",visibility:e.visible?"visible":"hidden",opacity:e.opacity}:{id:e.id,transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")translate("+e.x+","+e.y+")",visibility:e.visible?"visible":"hidden",opacity:e.opacity},o&&(d.role="img",d["aria-label"]=o),e.class&&(d.class=e.class),ti(c,d),this.setSvgStyle(c,e,i)},n.prototype.renderPath=function(t,e,i){var r,s,o,a,l,h,c,d,u=i,f="";for(l=0,h=0,d=0,c=u.length;de.width&&"Wrap"!==e.textOverflow&&"NoWrap"===e.textWrapping&&(h[0].text=VF(e.content,e)),v=0;vD&&(u.text=u.text.slice(0,u.text.length-3),u.text=u.text.concat("..."),l.data=u.text),this.alignText(y,f,u,l,p,g,v,e,h),C+=u.dy}}C&&e.isHorizontalLane&&(M=e.parentOffsetX+e.pivotX,w=e.parentOffsetY+e.pivotY,e.y=e.parentOffsetY-C*e.pivotY+.5),e.textDecoration&&"LineThrough"===e.textDecoration&&(e.textDecoration=ub(e.textDecoration));var P={id:e.id+"_text",fill:e.color,visibility:e.visible?"visible":"hidden","text-decoration":e.textDecoration,transform:"rotate("+e.angle+","+M+","+w+")translate("+e.x+","+e.y+")",opacity:e.opacity};r&&(P.role="img",P["aria-label"]=r),ti(y,P)}},n.prototype.alignText=function(t,e,i,r,s,o,a,l,h){"justify"!==l.textAlign?this.setText(t,e,i,r,s,o,l):a!==h.length-1?this.setText(t,e,i,r,s,o,l,l.width,"spacing"):this.setText(t,e,i,r,s,o,l)},n.prototype.setText=function(t,e,i,r,s,o,a,l,h){ti(e,"justify"!==a.textAlign?{x:s.toString(),y:o.toString()}:{x:s.toString(),y:o.toString(),textLength:l||0,lengthAdjust:h||"spacing"}),t.setAttribute("fill",i.text),e.appendChild(r),t.appendChild(e)},n.prototype.drawImage=function(t,e,i,r){var s;i&&(s=i.getElementById(e.id+"image")),s||(s=document.createElementNS("http://www.w3.org/2000/svg","image"),t.appendChild(s));var o=new Image;o.src=e.source;var a="None"!==e.scale?e.scale:"",l=e.alignment,h=l.charAt(0).toLowerCase()+l.slice(1);"Stretch"!==a&&(h+=" "+a.charAt(0).toLowerCase()+a.slice(1)),ti(s,{id:e.id+"image",x:e.x.toString(),y:e.y.toString(),transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")",width:e.width.toString(),visibility:e.visible?"visible":"hidden",height:e.height.toString(),preserveAspectRatio:h,opacity:e.opacity.toString()}),s.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",o.src.toString())},n.prototype.drawHTMLContent=function(t,e,i,r,s){var o,a;if(e&&(o=e.querySelector("#"+t.id+"_html_element")),!o){(a=e.querySelector("#"+t.id+"_html_element")||e.querySelector("#"+t.nodeId+"_html_element"))||(a=Tt("div",{id:t.nodeId+"_html_element",class:"foreign-object"})),o=Tt("div",{id:t.id+"_html_element",class:"foreign-object"});var c=document.getElementById(t.diagramId).ej2_instances[0],d=!1;if(e.parentNode&&e.parentNode.parentNode&&e.parentNode.parentNode.parentNode&&e.parentNode.parentNode.parentNode.classList.contains("e-overview")&&(d=!0),d)c.isReact?c.renderReactTemplates(function(){o.appendChild(t.template.cloneNode(!0))}):o.appendChild(t.template.cloneNode(!0));else{if("string"==typeof t.template){var u=document.createElement("div");u.innerHTML=t.template,t.template=u,c.selectedItems.userHandles.filter(function(g){return g.name===t.id.split("_shape")[0]&&""!==g.template})[0].template=t.template}t.isTemplate&&t.template?o.appendChild(t.template):t.template&&o.appendChild(t.template.cloneNode(!0))}void 0!==s&&e.childNodes.length>s&&e.insertBefore(o,e.childNodes[parseInt(s.toString(),10)]),a.appendChild(o),e.appendChild(a)}var p=xn(t).topLeft;o.setAttribute("style","height:"+t.actualSize.height+"px; width:"+t.actualSize.width+"px;left:"+p.x+"px; top:"+p.y+"px;position:absolute;transform:rotate("+(t.rotateAngle+t.parentTransform)+"deg);pointer-events:"+(r?"all":"none")+";visibility:"+(t.visible?"visible":"hidden")+";opacity:"+t.style.opacity+";")},n.prototype.drawNativeContent=function(t,e,i,r,s){var o,a;if(s&&(o=s.getElementById(t.id+"_native_element"),a=s.getElementById(t.id+"_clip")),!o){(o=document.createElementNS("http://www.w3.org/2000/svg","g")).setAttribute("id",t.id+"_native_element"),o.appendChild(t.template.cloneNode(!0));var l=this.createGElement("g",{id:t.id+"_inner_native_element"});l.appendChild(o),e.appendChild(l)}a&&o.removeChild(a),o.setAttribute("style","visibility:"+(t.visible?"visible":"hidden")+";opacity:"+t.style.opacity+";"),this.setNativTransform(t,o,i,r),"Slice"===t.scale&&this.drawClipPath(t,o,i,r,s),ti(o,t.description?{role:"img","aria-label":t.description}:{})},n.prototype.setNativTransform=function(t,e,i,r){var s=0!==t.contentSize.width?t.contentSize.width:1,o=0!==t.contentSize.height?t.contentSize.height:1;e.setAttribute("transform","rotate("+t.parentTransform+","+t.offsetX+","+t.offsetY+") translate("+(t.offsetX-t.templatePosition.x*r/s-r*t.pivot.x)+","+(t.offsetY-t.templatePosition.y*i/o-i*t.pivot.y)+") scale("+r/s+","+i/o+")")},n.prototype.drawClipPath=function(t,e,i,r,s){var o=t.contentSize.width,a=t.contentSize.height,l=t.width/(r/o),h=t.height/(i/a),c=t.templatePosition.x+(t.width>=t.height?0:(o-l)/2),d=t.templatePosition.y+(t.height>=t.width?0:(a-h)/2),u=s.getElementById(t.id+"_clip");(u=document.createElementNS("http://www.w3.org/2000/svg","clipPath")).setAttribute("id",t.id+"_clip"),e.appendChild(u);var f=s.getElementById(t.id+"_clip_rect");return f=document.createElementNS("http://www.w3.org/2000/svg","rect"),u.appendChild(f),ti(f,{id:t.id+"_clip_rect",width:l.toString(),height:h.toString(),x:c.toString(),y:d.toString()}),sm()?e.setAttribute("clip-path","url("+location.protocol+"//"+location.host+location.pathname+"#"+t.id+"_clip)"):e.setAttribute("clip-path","url(#"+t.id+"_clip)"),e},n.prototype.renderGradient=function(t,e,i){var r,s,o,h,c,a=yT(i),l=a.getElementById(i+"gradient_pattern");if(l||(l=Fi("defs",{id:i+"gradient_pattern"}),a.insertBefore(l,a.firstChild)),gF(e.id),"None"!==t.gradient.type){for(var d=0;dt.width&&("Ellipsis"===t.textOverflow||"Clip"===t.textOverflow)&&"NoWrap"===t.textWrapping?0:.5*t.width:"right"===t.textAlign&&(c=1*t.width),s.x=0+c+(e?e.x:0),s.y=1.2+d-r.height/2,s},n}(),Pc=function(){function n(t,e,i){this.renderer=null,this.isSvgMode=!0,this.touchMove=void 0,this.transform={x:0,y:0},this.diagramId=t,this.element=xt(this.diagramId),this.svgRenderer=e,this.isSvgMode=i,this.renderer=i?new Jf:new bo}return n.prototype.setCursor=function(t,e){t.style.cursor=e},n.prototype.setLayers=function(){this.iconSvgLayer=this.element.getElementsByClassName("e-ports-expand-layer")[0],this.adornerSvgLayer=this.element.getElementsByClassName("e-adorner-layer")[0],this.nativeSvgLayer=this.element.getElementsByClassName("e-native-layer")[0],this.diagramSvgLayer=this.element.getElementsByClassName("e-diagram-layer")[0]},n.prototype.getAdornerLayer=function(){return vT(this.diagramId)},n.prototype.getParentSvg=function(t,e,i){return this.diagramId&&t&&t.id?t.id.split("_icon_content").length>1||t.id.split("_nodeport").length>1||t.elementActions&Xr.ElementIsPort?this.iconSvgLayer:e&&"selector"===e?this.adornerSvgLayer:t instanceof En?this.nativeSvgLayer:this.diagramSvgLayer:i},n.prototype.getParentElement=function(t,e,i,r){var s=e;if(i&&this.diagramId&&t&&t.id){t.id.split("_icon_content").length>1?(s=i.getElementById(this.diagramId+"_diagramExpander"),e=null):t.id.split("_nodeport").length>1?s=i.getElementById(this.diagramId+"_diagramPorts"):t instanceof En?(s=i.getElementById(this.diagramId+"_nativeLayer"),e=null):t.elementActions&Xr.ElementIsPort?(s=i.getElementById(this.diagramId+"_diagramPorts"),e=null):s=i.getElementById(this.diagramId+"_diagramLayer");var o=this.getGroupElement(t,e||s,r);s=o.g,o.svg&&(i=o.svg)}return{g:s,svg:i}},n.prototype.getGroupElement=function(t,e,i){var r,o,s=this.getParentSvg(t);if(e&&s){if(s&&!(r=s.getElementById(t.id+"_groupElement"))&&s!==this.nativeSvgLayer){var a=this.nativeSvgLayer;r=a.getElementById(t.id+"_groupElement"),o=a}r||(r=this.svgRenderer.createGElement("g",{id:t.id+"_groupElement"}),void 0!==i&&e.childNodes.length>i?e.insertBefore(r,e.childNodes[parseInt(i.toString(),10)]):e.appendChild(r))}return{g:r,svg:o}},n.prototype.renderElement=function(t,e,i,r,s,o,a,l,h,c,d){t instanceof Cs?(t.id=t.id?t.id:Qe(),this.renderContainer(t,e,i,r,s,o,a,l,h,c,d)):t instanceof wI?this.renderImageElement(t,e,r,s,a):t instanceof Ze?this.renderPathElement(t,e,r,s,a,h,d):t instanceof li?this.renderTextElement(t,e,r,s,a,c):t instanceof En?this.renderNativeElement(t,e,r,s,a):t instanceof es?this.renderHTMLElement(t,e,i,r,s,a,l):this.renderRect(t,e,r,s,h)},n.prototype.drawSelectionRectangle=function(t,e,i,r,s,o){var a={width:i*o.scale,height:r*o.scale,x:.5+(t=(t+o.tx)*o.scale),y:.5+(e=(e+o.ty)*o.scale),fill:"transparent",stroke:"gray",angle:0,pivotX:.5,pivotY:.5,strokeWidth:1,dashArray:"6 3",opacity:1,visible:!0,id:s.id+"_selected_region"},l=this.getAdornerLayer();this.svgRenderer.updateSelectionRegion(l,a)},n.prototype.renderHighlighter=function(t,e,i){var r=t.actualSize.width||2,s=t.actualSize.height||2,o=t.offsetX-r*t.pivot.x,a=t.offsetY-s*t.pivot.y;this.svgRenderer.drawRectangle(e,{width:r*i.scale,height:s*i.scale,x:o=(o+i.tx)*i.scale,y:a=(a+i.ty)*i.scale,fill:"transparent",stroke:"#8CC63F",angle:t.rotateAngle,pivotX:t.pivot.x,pivotY:t.pivot.y,strokeWidth:4,dashArray:"",opacity:1,cornerRadius:0,visible:!0,id:e.id+"_highlighter",class:"e-diagram-highlighter"},this.diagramId,void 0,void 0,e)},n.prototype.renderSelectionRectangle=function(t,e,i,r){var s=t.actualSize.width||2,o=t.actualSize.height||2,a=t.offsetX-s*t.pivot.x,l=t.offsetY-o*t.pivot.y,h={width:s*i.scale,height:o*i.scale,x:a=(a+i.tx)*i.scale,y:l=(l+i.ty)*i.scale,fill:"transparent",stroke:"#00cc00",angle:t.rotateAngle,pivotX:t.pivot.x,pivotY:t.pivot.y,strokeWidth:r?2:1,dashArray:"",opacity:1,cornerRadius:0,visible:!0,id:t.id+"_highlighter",class:r?"e-diagram-first-selection-indicator e-diagram-selection-indicator":"e-diagram-selection-indicator"},c=this.getParentSvg(t,"selector");this.svgRenderer.drawRectangle(e,h,this.diagramId,void 0,void 0,c)},n.prototype.renderSelectionLine=function(t,e,i,r){var s=this.getBaseAttributes(t,i);s.data=t.absolutePath,s.id=s.id+"_highlighter";var o=t.description?t.description:t.id;this.isSvgMode||(s.x=t.flipOffset.x?t.flipOffset.x:s.x,s.y=t.flipOffset.y?t.flipOffset.y:s.y),i&&(s.x=s.x*i.scale,s.y=s.y*i.scale),s.stroke="#00cc00",s.strokeWidth=r?2:1,s.class=r?"e-diagram-first-selection-indicator e-diagram-selection-indicator":"e-diagram-selection-indicator";var a=this.getParentSvg(t,"selector");this.svgRenderer.drawPath(e,s,this.diagramId,void 0,a,o,i.scale)},n.prototype.renderStackHighlighter=function(t,e,i,r,s,o,a){var l=t.actualSize.width||2,h=t.offsetX-l*t.pivot.x,c=t.actualSize.height||2,d=t.offsetY-c*t.pivot.y;h=(h+i.tx)*i.scale;var u,f=t.bounds,p="";if(d=(d+i.ty)*i.scale,r)if(o){var v,y;u="M 0 0 L "+(2+(g=l*i.scale))+" 0 Z",v=t.actualSize.width/Number(f.width?f.width:1)*i.scale,y=t.actualSize.height/Number(f.height?f.height:1)*i.scale,p=yI(SI(Ed("M7,4 L8,4 8,7 11,7 11,8 8,8 8,11 7,11 7,8 4,8 4,7 7,7 z M7.5,0.99999994C3.9160004,1 1,3.9160004 0.99999994,7.5 1,11.084 3.9160004,14 7.5,14 11.084,14 14,11.084 14,7.5 14,3.9160004 11.084,1 7.5,0.99999994 z M7.5,0 C11.636002,0 15,3.3639984 15,7.5 15,11.636002 11.636002,15 7.5,15 3.3640003,15 0,11.636002 0,7.5 0,3.3639984 3.3640003,0 7.5,0 z")),v+g+2,y-8,!1,f.x,f.y,0,0),s.y>=t.offsetY&&(d+=c)}else{var g;a&&s.y>=t.offsetY&&(d+=c*i.scale),u="M -10 -10 L 0 0 Z M -10 10 L 0 0 Z M 0 0 L "+(g=l*i.scale)+" 0 Z M "+g+" 0 L "+(g+10)+" 10 Z L "+(g+10)+" -10 Z"}else u="M 10 -10 L 0 0 Z M -10 -10 L 0 0 Z M 0 0 L 0 "+(g=c*i.scale)+" Z M 0 "+g+" L -10 "+(g+10)+" Z L 10 "+(g+10)+" Z",s.x>=t.offsetX&&(h+=l*i.scale);this.svgRenderer.drawPath(e,{data:u+p,width:l*i.scale,height:c*i.scale,x:h,y:d,fill:"transparent",stroke:"#8CC63F",angle:t.rotateAngle,pivotX:t.pivot.x,pivotY:t.pivot.y,strokeWidth:1,dashArray:"",opacity:1,visible:!0,id:e.id+"_stack_highlighter",class:"e-diagram-highlighter"},this.diagramId)},n.prototype.drawLine=function(t,e){this.svgRenderer.drawLine(t,e)},n.prototype.drawPath=function(t,e){this.svgRenderer.drawPath(t,e,this.diagramId)},n.prototype.renderResizeHandle=function(t,e,i,r,s,o,a,l,h,c,d){var u=t.offsetX-t.actualSize.width*t.pivot.x,f=t.offsetY-t.actualSize.height*t.pivot.y,p=t.actualSize.height,g=t.actualSize.width;if(!c&&i&bt.Rotate&&FI(this.rendererActions)&&!A3(this.rendererActions))this.renderPivotLine(t,e,o,s,a),this.renderRotateThumb(t,e,o,s,a);else if(this.touchMove){var v=document.getElementById("rotateThumb");v&&v.setAttribute("visibility","hidden")}this.renderBorder(t,e,o,l,h,c);var y=t.actualSize.width*r,S=t.actualSize.height*r;!h&&FI(this.rendererActions)&&!A3(this.rendererActions)&&(t.isTextAnnotation||(y>=40&&S>=40&&(s&mr.ResizeNorthWest&&this.renderCircularHandle("resizeNorthWest",t,u,f,e,qr(s,"ResizeNorthWest"),i&bt.ResizeNorthWest,o,void 0,a,{"aria-label":"Thumb to resize the selected object on top left side direction"},void 0,"e-diagram-resize-handle e-northwest",d),s&mr.ResizeNorthEast&&this.renderCircularHandle("resizeNorthEast",t,u+g,f,e,qr(s,"ResizeNorthEast"),i&bt.ResizeNorthEast,o,void 0,a,{"aria-label":"Thumb to resize the selected object on top right side direction"},void 0,"e-diagram-resize-handle e-northeast",d),s&mr.ResizeSouthWest&&this.renderCircularHandle("resizeSouthWest",t,u,f+p,e,qr(s,"ResizeSouthWest"),i&bt.ResizeSouthWest,o,void 0,a,{"aria-label":"Thumb to resize the selected object on bottom left side direction"},void 0,"e-diagram-resize-handle e-southwest",d),s&mr.ResizeSouthEast&&this.renderCircularHandle("resizeSouthEast",t,u+g,f+p,e,qr(s,"ResizeSouthEast"),i&bt.ResizeSouthEast,o,void 0,a,{"aria-label":"Thumb to resize the selected object on bottom right side direction"},void 0,"e-diagram-resize-handle e-southeast",d)),s&mr.ResizeNorth&&this.renderCircularHandle("resizeNorth",t,u+g/2,f,e,qr(s,"ResizeNorth"),i&bt.ResizeNorth,o,void 0,a,{"aria-label":"Thumb to resize the selected object on top side direction"},void 0,"e-diagram-resize-handle e-north",d),s&mr.ResizeSouth&&this.renderCircularHandle("resizeSouth",t,u+g/2,f+p,e,qr(s,"ResizeSouth"),i&bt.ResizeSouth,o,void 0,a,{"aria-label":"Thumb to resize the selected object on bottom side direction"},void 0,"e-diagram-resize-handle e-south",d),s&mr.ResizeWest&&this.renderCircularHandle("resizeWest",t,u,f+p/2,e,qr(s,"ResizeWest"),i&bt.ResizeWest,o,void 0,a,{"aria-label":"Thumb to resize the selected object on left side direction"},void 0,"e-diagram-resize-handle e-west",d),s&mr.ResizeEast&&this.renderCircularHandle("resizeEast",t,u+g,f+p/2,e,qr(s,"ResizeEast"),i&bt.ResizeEast,o,void 0,a,{"aria-label":"Thumb to resize the selected object on right side direction"},void 0,"e-diagram-resize-handle e-east",d)))},n.prototype.renderEndPointHandle=function(t,e,i,r,s,o,a,l,h,c){var p,g,d=t.sourcePoint,u=t.targetPoint,f=t.wrapper;if(this.renderCircularHandle("connectorSourceThumb",f,d.x,d.y,e,qr(r,"ConnectorSourceThumb"),i&bt.ConnectorSource,s,o,void 0,{"aria-label":"Thumb to move the source point of the connector"},void 0,"e-diagram-endpoint-handle e-sourceend",c),this.renderCircularHandle("connectorTargetThumb",f,u.x,u.y,e,qr(r,"ConnectorTargetThumb"),i&bt.ConnectorTarget,s,a,void 0,{"aria-label":"Thumb to move the target point of the connector"},void 0,"e-diagram-endpoint-handle e-targetend",c),l)if("Straight"===t.type&&t.segments.length>0)for(p=0;p0)for(p=0;p=3&&3===t.segments.length&&(S=1,b=t.segments.length-1),S=t.segments.length>t.maxSegmentThumb+2?2:S,b=t.segments.length>t.maxSegmentThumb+2?t.segments.length-2:b,1===t.segments.length&&t.segments[0].points.length<=2&&(S=1,b=t.segments.length),p=S;p=50&&i.allowDrag),this.renderOrthogonalThumb(t+"_"+(d+1),e,(i.points[parseInt(d.toString(),10)].x+i.points[d+1].x)/2,(i.points[parseInt(d.toString(),10)].y+i.points[d+1].y)/2,r,h,l,o,a,u)}else for(d=0;d=50&&i.allowDrag),this.renderOrthogonalThumb(t+"_"+(d+1),e,(i.points[parseInt(d.toString(),10)].x+i.points[d+1].x)/2,(i.points[parseInt(d.toString(),10)].y+i.points[d+1].y)/2,r,h,l,o,a,u)},n.prototype.renderOrthogonalThumb=function(t,e,i,r,s,o,a,l,h,c){var d,g,u=0,f=document.getElementById(this.diagramId);f&&(g=f.ej2_instances[0]);var y=h.constraints&qe.InheritSegmentThumbShape?g.segmentThumbShape:h.segmentThumbShape,b=h.constraints&qe.InheritSegmentThumbSize?g.segmentThumbSize:h.segmentThumbSize;if(d="horizontal"===a?function rre(n){return are[""+n]}(y):n3(y),"Arrow"===y||"DoubleArrow"===y||"OpenArrow"===y)switch(c){case"Bottom":case"Right":u=180;break;default:u=0}else if("Fletch"===y||"OpenFetch"===y||"IndentedArrow"===y||"OutdentedArrow"===y)switch(c){case"Bottom":u=-90;break;case"Top":u=90;break;case"Right":u=180;break;default:u=0}var M={x:(i+l.tx)*l.scale-b/2,y:(r+l.ty)*l.scale-b/2,angle:u,fill:"#e2e2e2",stroke:"black",strokeWidth:1,dashArray:"",data:d,width:b,height:b,pivotX:.5,pivotY:.5,opacity:1,visible:o,id:t,class:"e-diagram-ortho-segment-handle"},w=op(M.data),C=new me(M.width,M.height),D=new Ze;if(M.data=D.updatePath(M.data,w,C),this.touchMove){var A=document.getElementById(t);A?this.updateSegmentPosition(A,M):this.svgRenderer.drawPath(s,M,this.diagramId)}else this.svgRenderer.drawPath(s,M,this.diagramId)},n.prototype.renderPivotLine=function(t,e,i,r,s){var o=t,l=!!(r&mr.Rotate);s&&(l=!1);var h=this.getBaseAttributes(o,i);h.fill="None",h.stroke="black",h.strokeWidth=1,h.dashArray="2,3",h.visible=l;var c=i.scale;h.x*=c,h.y*=c,h.width*=c,h.height*=c,h.id="pivotLine",h.class="e-diagram-pivot-line";var u={x:o.actualSize.width*o.pivot.x*c,y:0};h.startPoint={x:o.actualSize.width*o.pivot.x*c,y:-20},h.endPoint=u,this.svgRenderer.drawLine(e,h)},n.prototype.renderBezierLine=function(t,e,i,r,s,o){var l=this.getBaseAttributes(e,o);l.id=t,l.stroke="black",l.strokeWidth=1,l.dashArray="3,3",l.fill="None",l.class="e-diagram-bezier-control-line",l.x=0,l.y=0;var h=o.scale,g={x:(s.x+o.tx)*h,y:(s.y+o.ty)*h};l.startPoint={x:(r.x+o.tx)*h,y:(r.y+o.ty)*h},l.endPoint=g,this.svgRenderer.drawLine(i,l)},n.prototype.renderCircularHandle=function(t,e,i,r,s,o,a,l,h,c,d,u,f,p){var g=e,v={x:i,y:r};if(0!==g.rotateAngle||0!==g.parentTransform){var y=Bi();qi(y,g.rotateAngle+g.parentTransform,g.offsetX,g.offsetY),v=Ke(y,v)}var S=this.getBaseAttributes(g);if(S.stroke="black",S.strokeWidth=1,void 0!==u?(S.id="segmentEnd_"+u,S.fill="#e2e2e2"):S.fill=h?"#8CC63F":"white",S.cornerRadius=p/2,S.angle=e.rotateAngle,S.id=t,S.visible=o,S.class=f,S.width=p,S.height=p,S.x=(v.x+l.tx)*l.scale,S.y=(v.y+l.ty)*l.scale,S.x=S.x-S.width/2,S.y=S.y-S.height/2,h&&(S.class+=" e-connected"),c&&(S.visible=!1),this.touchMove){var b=document.getElementById(t);if(b)this.updateResizeHandle(b,S);else{var M=this.getParentSvg(e,"selector");this.svgRenderer.drawRectangle(s,S,this.diagramId,!0,!0,M,d,!0,a)}}else M=this.getParentSvg(e,"selector"),this.svgRenderer.drawRectangle(s,S,this.diagramId,!0,!0,M,d,!0,a)},n.prototype.updateResizeHandle=function(t,e){ti(t,{id:e.id,x:e.x.toString(),y:e.y.toString(),width:e.width.toString(),height:e.height.toString(),visibility:e.visible?"visible":"hidden",transform:"rotate("+e.angle+","+(e.x+e.width/2)+","+(e.y+e.height/2)+")",rx:e.cornerRadius||0,ry:e.cornerRadius||0,opacity:e.opacity})},n.prototype.renderBezierHandle=function(t,e,i,r,s,o,a,l,h,c,d,u,f){var v,p=document.getElementById(this.diagramId);p&&(v=p.ej2_instances[0]);var y=e,S={x:i,y:r};if(0!==y.rotateAngle||0!==y.parentTransform){var b=Bi();qi(b,y.rotateAngle+y.parentTransform,y.offsetX,y.offsetY),S=Ke(b,S)}var D=a.constraints&qe.InheritSegmentThumbSize?v.segmentThumbSize:a.segmentThumbSize,A=n3(a.constraints&qe.InheritSegmentThumbShape?v.segmentThumbShape:a.segmentThumbShape),x=this.getBaseAttributes(y);x.stroke="black",x.strokeWidth=1,void 0!==d?(x.id="segmentEnd_"+d,x.fill="#e2e2e2"):x.fill=h?"#8CC63F":"white",x.angle=e.rotateAngle,x.id=t,x.visible=o,x.class=u,x.width=D,x.height=D,x.data=A,x.x=(S.x+l.tx)*l.scale,x.y=(S.y+l.ty)*l.scale,x.x=x.x-x.width/2,x.y=x.y-x.height/2,h&&(x.class+=" e-connected"),c&&(x.visible=!1);var P=op(x.data),L=new me(x.width,x.height),O=new Ze;if(x.data=O.updatePath(x.data,P,L),this.touchMove){var N=document.getElementById(t);if(N)this.updateSegmentPosition(N,x);else{var T=this.getParentSvg(e,"selector");this.svgRenderer.drawPath(s,x,this.diagramId,!0,T)}}else T=this.getParentSvg(e,"selector"),this.svgRenderer.drawPath(s,x,this.diagramId,!0,T)},n.prototype.updateSegmentPosition=function(t,e){ti(t,{id:e.id,transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")translate("+e.x+","+e.y+")",visibility:e.visible?"visible":"hidden",opacity:e.opacity})},n.prototype.renderBorder=function(t,e,i,r,s,o){var l=this.getBaseAttributes(t,i);l.x*=i.scale,l.y*=i.scale,l.width*=i.scale,l.height*=i.scale,l.fill="transparent",l.stroke="#097F7F",l.strokeWidth=1.2,l.gradient=null,l.dashArray="6,3",l.class="e-diagram-selector",o&&(l.class+=" e-diagram-lane"),l.id="borderRect",l.id=this.rendererActions&Ga.DrawSelectorBorder?"borderRect_symbol":"borderRect",r||(l.class+=" e-disabled"),s&&(l.class+=" e-thick-border"),l.cornerRadius=0;var h=this.getParentSvg(t,"selector");this.svgRenderer.drawRectangle(e,l,this.diagramId,void 0,!0,h)},n.prototype.renderUserHandler=function(t,e,i,r,s,o){for(var l,a=t.wrapper,h=0,c=t.userHandles;h0||d.disableNodes&&t.nodes.length>0||"Drag"===s&&o)&&(l=!1);var u=document.getElementById(d.name+"_template_hiddenUserHandle");u&&(d.template=u.childNodes[0].cloneNode(!0));var f=eT(t,d,i);if(f.x=(f.x+i.tx)*i.scale,f.y=(f.y+i.ty)*i.scale,d.visible&&(d.visible=!!(t.constraints&mr.UserHandle)),l)if(d.pathData){var p=d.pathData?d.pathData:d.content,g=this.getBaseAttributes(a);g.id=d.name+"_userhandle",g.fill=d.backgroundColor,g.stroke=d.borderColor,g.strokeWidth=d.borderWidth,g.centerX=f.x,g.centerY=f.y,g.radius=.5*d.size,g.class="e-diagram-userhandle-circle",g.angle=0,g.visible=d.visible,g.opacity=1,this.svgRenderer.drawCircle(e,g,1,{"aria-label":d.name+"user handle"});var y=[];y=SI(y=Ed(p));var S=op(p),w=yI(y,(d.size-.45*d.size)/S.width,(d.size-.45*d.size)/S.height,!0,S.x,S.y,0,0);S=op(w),this.svgRenderer.drawPath(e,C={x:f.x-S.width/2,y:f.y-S.height/2,angle:0,id:"",class:"e-diagram-userhandle-path",fill:d.pathColor,stroke:d.backgroundColor,strokeWidth:.5,dashArray:"",data:w,width:d.size-5,height:d.size-5,pivotX:0,pivotY:0,opacity:1,visible:d.visible},this.diagramId,void 0,void 0,{"aria-label":d.name+"user handle"})}else if(d.content){var D=new En(d.name,this.diagramId);D.content=d.content,D.offsetX=f.x,D.offsetY=f.y,D.id=d.name+"_shape",D.horizontalAlignment="Center",D.verticalAlignment="Center",D.visible=d.visible,D.setOffsetWithRespectToBounds(f.x,f.y,"Fraction"),D.relativeMode="Object",D.description=d.name||"User handle",D.measure(new me(d.size,d.size)),D.arrange(D.desiredSize),this.svgRenderer.drawNativeContent(D,e,d.size,d.size,this.adornerSvgLayer)}else if(d.source){var C,A=new wI;(C=this.getBaseAttributes(A,i)).width=d.size,C.height=d.size,C.x=f.x-d.size/2,C.y=f.y-d.size/2,C.sourceWidth=d.size,C.sourceHeight=d.size,C.alignment=A.imageAlign,C.source=d.source,C.scale=A.imageScale,C.visible=d.visible,C.description=d.name||"User handle",C.id=d.name+"_",this.renderer.drawImage(e,C,this.adornerSvgLayer,!1)}else{var x=new es(d.name,this.diagramId);x.offsetX=f.x,x.offsetY=f.y,x.id=d.name+"_shape",x.visible=d.visible,x.relativeMode="Object",x.template=d.template,x.measure(new me(d.size,d.size)),x.arrange(x.desiredSize),this.svgRenderer.drawHTMLContent(x,r,void 0,!0,void 0)}}},n.prototype.renderRotateThumb=function(t,e,i,r,s){new Ze;var a,l=new me;l.width=18,l.height=16;var d=!!(r&mr.Rotate);s&&(d=!1);var f=t.offsetX-t.actualSize.width*t.pivot.x+t.pivot.x*t.actualSize.width,p=t.offsetY-t.actualSize.height*t.pivot.y;if(a={x:(f=(f+i.tx)*i.scale)-.5*l.width,y:(p=(p+i.ty)*i.scale)-30-.5*l.height},0!==t.rotateAngle||0!==t.parentTransform){var g=Bi();qi(g,t.rotateAngle+t.parentTransform,(i.tx+t.offsetX)*i.scale,(i.ty+t.offsetY)*i.scale),a=Ke(g,a)}var v={x:a.x,y:a.y,angle:t.rotateAngle+t.parentTransform,fill:"#231f20",stroke:"black",strokeWidth:.5,dashArray:"",data:"M 16.856144362449648 10.238890446662904 L 18.000144362449646 3.437890446662903L 15.811144362449646 4.254890446662903 C 14.837144362449646 2.5608904466629028 13.329144362449647 1.2598904466629026 11.485144362449645 0.5588904466629026 C 9.375144362449646 - 0.24510955333709716 7.071144362449646 - 0.18010955333709716 5.010144362449646 0.7438904466629028 C 2.942144362449646 1.6678904466629028 1.365144362449646 3.341890446662903 0.558144362449646 5.452890446662903 C - 0.244855637550354 7.567890446662903 - 0.17985563755035394 9.866890446662904 0.7431443624496461 11.930890446662904 C 1.6681443624496461 13.994890446662904 3.343144362449646 15.575890446662903 5.457144362449647 16.380890446662903 C 6.426144362449647 16.7518904466629 7.450144362449647 16.9348904466629 8.470144362449647 16.9348904466629 C 9.815144362449647 16.9348904466629 11.155144362449647 16.6178904466629 12.367144362449647 15.986890446662901 L 11.351144362449647 14.024890446662901 C 9.767144362449647 14.8468904466629 7.906144362449647 14.953890446662902 6.237144362449647 14.3178904466629 C 4.677144362449647 13.7218904466629 3.444144362449647 12.5558904466629 2.758144362449647 11.028890446662901 C 2.078144362449646 9.501890446662903 2.031144362449646 7.802890446662903 2.622144362449646 6.243890446662903 C 3.216144362449646 4.6798904466629025 4.387144362449646 3.442890446662903 5.914144362449646 2.760890446662903 C 7.437144362449646 2.078890446662903 9.137144362449646 2.0298904466629026 10.700144362449645 2.6258904466629027 C 11.946144362449646 3.100890446662903 12.971144362449646 3.9538904466629026 13.686144362449646 5.049890446662903 L 11.540144362449645 5.850890446662903 L 16.856144362449648 10.238890446662904 Z",width:20,height:20,pivotX:0,pivotY:0,opacity:1,visible:d,id:"rotateThumb",class:"e-diagram-rotate-handle"};if(this.touchMove){var y=document.getElementById("rotateThumb");y?this.updateSegmentPosition(y,v):this.svgRenderer.drawPath(e,v,this.diagramId,!0,void 0,{"aria-label":"Thumb to rotate the selected object"})}else this.svgRenderer.drawPath(e,v,this.diagramId,!0,void 0,{"aria-label":"Thumb to rotate the selected object"})},n.prototype.renderPathElement=function(t,e,i,r,s,o,a){var l=this.getBaseAttributes(t,i,o);if(l.data=t.absolutePath,l.data=t.absolutePath,t.isPathPort&&a){l.x=a[t.id]?a[t.id].cx:l.x,l.y=a[t.id]?a[t.id].cy:l.y,t.bounds.x=l.x,t.bounds.y=l.y;var h=document.getElementById(this.diagramId);h&&"PortDrag"!==h.ej2_instances[0].eventHandler.currentAction&&(t.offsetX=l.x+t.width/2,t.offsetY=l.y+t.height/2)}var u=t.description?t.description:t.id;if(this.isSvgMode||(l.x=t.flipOffset.x?t.flipOffset.x:l.x,l.y=t.flipOffset.y?t.flipOffset.y:l.y),t.isExport){var f=t.absoluteBounds,p=Ed(l.data),g=this.findAndStoreArcValues(p);l.arc=g,l.data=OF(t,f,0,l)}this.renderer.drawPath(e,l,this.diagramId,void 0,r,u)},n.prototype.findAndStoreArcValues=function(t){var e=[];return t.forEach(function(i){"A"===i.command&&e.push({r1:i.r1/2,r2:i.r2/2})}),e},n.prototype.renderSvgGridlines=function(t,e,i,r,s,o){var a=document.createElementNS("http://www.w3.org/2000/svg","pattern"),l=document.createElementNS("http://www.w3.org/2000/svg","defs");l.setAttribute("id",this.diagramId+"_grid_pattern_defn"),(t.constraints&Kt.ShowHorizontalLines||t.constraints&Kt.ShowVerticalLines)&&a.setAttribute("id",this.diagramId+"_pattern");var h=0,c=0,d=0,u=0,f=1,p=!1,g="Lines"===t.gridType,v=g?t.verticalGridlines.lineIntervals:t.verticalGridlines.dotIntervals,y=g?t.horizontalGridlines.lineIntervals:t.horizontalGridlines.dotIntervals;if(r.showRulers&&r.dynamicGrid&&s&&o)d=o.updateSegmentWidth(i.scale),u=s.updateSegmentWidth(i.scale),t.horizontalGridlines.scaledIntervals=[d/s.interval],t.verticalGridlines.scaledIntervals=[u/o.interval],p=!0;else{for(var S=0;S=2)for(;e>=2;)e/=2;else if(e<=.5)for(;e<=.5;)e*=2;var i;if(t.horizontalGridlines.scaledIntervals=t.horizontalGridlines.snapIntervals,t.verticalGridlines.scaledIntervals=t.verticalGridlines.snapIntervals,1!==e){var r=t.horizontalGridlines;for(r.scaledIntervals=[],i=0;ithis.groupElement.actualSize.height&&("Clip"===t.style.textOverflow||"Ellipsis"===t.style.textOverflow)&&(a.y=a.y+(a.height-this.groupElement.actualSize.height)/2),this.renderer.drawRectangle(e,a,this.diagramId,void 0,void 0,r),this.renderer.drawText(e,a,r,l,this.diagramId,t.isExport&&Math.min(t.exportScaleValue.x||t.exportScaleValue.y),this.groupElement),this.isSvgMode&&(t.doWrap=!1)},n.prototype.renderNativeElement=function(t,e,i,r,s){var o,a,l=this.getParentSvg(t,void 0,e)||r,h=this.getParentElement(t,e,l).g||e,c=this.getBaseAttributes(t,i);switch(c.fill="transparent",c.cornerRadius=t.cornerRadius,c.stroke="transparent",this.renderer.drawRectangle(e,c,this.diagramId,void 0,void 0,r),t.scale){case"None":o=t.contentSize.width,a=t.contentSize.height;break;case"Stretch":o=t.actualSize.width,a=t.actualSize.height;break;case"Meet":o=a=t.actualSize.width<=t.actualSize.height?t.actualSize.width:t.actualSize.height;break;case"Slice":o=a=t.actualSize.width>=t.actualSize.height?t.actualSize.width:t.actualSize.height}this.svgRenderer&&this.svgRenderer.drawNativeContent(t,h,a,o,l)},n.prototype.renderHTMLElement=function(t,e,i,r,s,o,a){var l=this.getBaseAttributes(t,r);l.fill="transparent",l.cornerRadius=t.cornerRadius,l.stroke="transparent",this.renderer.drawRectangle(e,l,this.diagramId,void 0,void 0,s),this.svgRenderer&&this.svgRenderer.drawHTMLContent(t,i.children[0],r,function cse(n){var t=n.parentElement;do{if(um(t,"e-diagram"))return!0;t=t.parentElement}while(t);return!1}(i),a)},n.prototype.renderImageElement=function(t,e,i,r,s){var o=this.getBaseAttributes(t,i);o.cornerRadius=0,this.renderer.drawRectangle(e,o,this.diagramId,void 0,void 0,r);var a,l,h,c,g,d=t.contentSize.width,u=t.contentSize.height,f=o.width/d,p=o.height/u;if("Stretch"===t.stretch)a=d*(g=Math.min(f,p)),l=u*g;else switch(t.stretch){case"Meet":a=d*(g=Math.min(f,p)),l=u*g,o.x+=Math.abs(o.width-a)/2,o.y+=Math.abs(o.height-l)/2;break;case"Slice":g=Math.max(f,p),h=o.width/(a=d*g)*d,c=o.height/(l=u*g)*u;break;case"None":a=d,l=u}o.width=a,o.height=l,o.sourceWidth=h,o.sourceHeight=c,o.source=t.source,o.alignment=t.imageAlign,o.scale=t.imageScale,o.description=t.description?t.description:t.id,this.renderer.drawImage(e,o,r,s)},n.prototype.renderContainer=function(t,e,i,r,s,o,a,l,h,c,d){var g,u={svg:s,g:e},f=document.getElementById(this.diagramId);if(f&&(g=f.ej2_instances[0]),this.diagramId&&(s=this.getParentSvg(t)||s,this.isSvgMode)){var v=this.getParentElement(t,e,s,l).g||e;s=this.getParentSvg(this.hasNativeParent(t.children))||s;var y=this.getParentElement(this.hasNativeParent(t.children),v,s,l);u.svg=y.svg||s,u.g=y.g||v,o&&s&&(s.getElementById(u.g.id)||e.appendChild(u.g)),e=u.g}if(this.renderRect(t,e,r,s),this.groupElement=t,t.hasChildren()){for(var b,S=void 0,M=0,w=t.children;M0&&(D=g.selectedItems.nodes[0]);var L,A=void 0,x=void 0,P=!1;if(g&&g.selectedItems&&(L=g.getObject(t.id)),"None"!==t.flip&&(D=L),"None"===t.flip&&(D=L),D&&D.flipMode&&(P=!0),!(t.elementActions&Xr.ElementIsGroup)&&g instanceof Fl&&g.nameTable[t.id]&&"connectors"!==g.nameTable[t.id].propName&&P&&D){if(A=t.children&&t.children[0]instanceof En?document.getElementById(D.id+"_content_inner_native_element"):document.getElementById(D.id+"_content_groupElement"),!(t.children[0]instanceof En)&&"Text"!==D.shape.type&&"None"!==D.flipMode&&"Label"!==D.flipMode&&"All"!==D.flipMode&&"PortAndLabel"!==D.flipMode&&"LabelText"!==D.flipMode&&"PortAndLabelText"!==D.flipMode&&"LabelAndLabelText"!==D.flipMode||t.children[0]instanceof En&&"Port"===D.flipMode)return void this.renderFlipElement(t,A,D.flip);if((t.children[0]instanceof En&&("All"===D.flipMode||"Label"===D.flipMode)||"Label"===D.flipMode||"PortAndLabel"===D.flipMode||"LabelText"===D.flipMode||"PortAndLabelText"===D.flipMode||"LabelAndLabelText"===D.flipMode||"Image"===D.shape.type&&"Label"===D.flipMode)&&this.renderFlipElement(t,A,t.flip),"None"!==t.flip&&"None"===D.flipMode)this.renderFlipElement(t,A,t.flip);else if("None"!==t.flip&&("Label"===D.flipMode||"PortAndLabel"===D.flipMode||"LabelText"===D.flipMode||"PortAndLabelText"===D.flipMode||"LabelAndLabelText"===D.flipMode)||t.children[0]instanceof En&&"None"!==t.flip&&D&&("None"===D.flipMode||"All"===D.flipMode)){for(var O=0;O0){var i=t[0];if(i instanceof En)return i;i.children&&i.children.length&&this.hasNativeParent(i.children,e++||0)}},n.prototype.renderRect=function(t,e,i,r,s){var o=this.getBaseAttributes(t,i,s);o.cornerRadius=t.cornerRadius||0,t.isExport&&(o.cornerRadius*=t.exportScaleValue.x),this.renderer.drawRectangle(e,o,this.diagramId,t.isExport,void 0,r,t.description?t.description:t.id)},n.prototype.drawRect=function(t,e){e.cornerRadius=0,this.svgRenderer.drawRectangle(t,e,this.diagramId)},n.prototype.getBaseAttributes=function(t,e,i){var r={width:t.actualSize.width,height:t.actualSize.height,x:t.offsetX-t.actualSize.width*t.pivot.x,y:t.offsetY-t.actualSize.height*t.pivot.y,fill:t.style.fill,stroke:t.style.strokeColor,angle:t.rotateAngle+t.parentTransform,pivotX:t.pivot.x,pivotY:t.pivot.y,strokeWidth:t.style.strokeWidth,dashArray:t.style.strokeDashArray||"",opacity:t.style.opacity,shadow:t.shadow,gradient:t.style.gradient,visible:t.visible,id:t.id,description:t.description,canApplyStyle:t.canApplyStyle,shapeType:t.shapeType};return"Page"===t.rotationReference&&(r.angle=t.rotateAngle),i&&(r.x=r.x-.5,r.y=r.y-.5),t.isExport&&(r.width*=t.exportScaleValue.x,r.height*=t.exportScaleValue.y,r.x*=t.exportScaleValue.x,r.y*=t.exportScaleValue.y,r.strokeWidth*=t.exportScaleValue.x),t.flip&&(r.flip=t.flip),e&&(r.x+=e.tx,r.y+=e.ty),r},n.renderSvgBackGroundImage=function(t,e,i,r,s,o){if(t.source){var l=yT(e.id).getElementById(e.id+"_image");if(!l){var h=function Soe(n){return xt(n).getElementsByClassName("e-background-image-layer")[0]}(e.id);(l=document.createElementNS("http://www.w3.org/2000/svg","image")).setAttribute("id",e.id+"_image"),h.appendChild(l)}var c=new Image;c.src=t.source,l.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",c.src.toString());var d="None"!==t.scale?t.scale:"",u=t.align,f=u.charAt(0).toLowerCase()+u.slice(1);d&&(f+=" "+d.charAt(0).toLowerCase()+d.slice(1)),ti(l,{id:e.id+"_image",x:i,y:r,width:s,height:o,preserveAspectRatio:f})}},n.prototype.transformLayers=function(t,e){var i=t.tx*t.scale,r=t.ty*t.scale,s="domTable";if(i!==this.transform.x||r!==this.transform.y||0===i||0===r){e&&(window[""+s][this.diagramId+"_diagramLayer"]||(window[""+s][this.diagramId+"_diagramLayer"]=this.diagramSvgLayer.getElementById(this.diagramId+"_diagramLayer")),window[""+s][this.diagramId+"_diagramLayer"].setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+"),scale("+t.scale+")"));var a=function Ioe(n){var t="domTable",e=null;return window[t][n+"_gridline"]?e=window[t][n+"_gridline"]:(e=Fd(n).getElementById(n+"_gridline"),window[t][n+"_gridline"]=e),e}(this.diagramId);return a.setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+")"),window[""+s][this.diagramId+"_diagramPorts"]||(window[""+s][this.diagramId+"_diagramPorts"]=this.iconSvgLayer.getElementById(this.diagramId+"_diagramPorts")),window[""+s][this.diagramId+"_diagramPorts"].setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+"),scale("+t.scale+")"),window[""+s][this.diagramId+"_diagramExpander"]||(window[""+s][this.diagramId+"_diagramExpander"]=this.iconSvgLayer.getElementById(this.diagramId+"_diagramExpander")),window[""+s][this.diagramId+"_diagramExpander"].setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+"),scale("+t.scale+")"),window[""+s][this.diagramId+"_nativeLayer"]||(window[""+s][this.diagramId+"_nativeLayer"]=this.nativeSvgLayer.getElementById(this.diagramId+"_nativeLayer")),window[""+s][this.diagramId+"_nativeLayer"].setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+"),scale("+t.scale+")"),Io(this.diagramId).children[0].style.transform="translate("+t.tx*t.scale+"px,"+t.ty*t.scale+"px)scale("+t.scale+")",this.transform={x:t.tx*t.scale,y:t.ty*t.scale},!0}return!1},n.prototype.updateNode=function(t,e,i,r,s,o,a){this.renderElement(t,e,i,r,this.getParentSvg(t),void 0,void 0,s,null,o,a)},n}(),rse=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),KI=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},oF=function(n){function t(e,i){var r=n.call(this,e,i)||this;return r.mode="Canvas",r.id="overview",r.actionName="",r.startPoint=null,r.currentPoint=null,r.prevPoint=null,r.scale=null,r.inAction=!1,r.viewPortRatio=1,r.horizontalOffset=0,r.verticalOffset=0,r.model={},r.event=!0,r.overviewid=88123,r.model={width:r.width,height:r.height},r}return rse(t,n),t.prototype.onPropertyChanged=function(e,i){for(var r=0,s=Object.keys(e);r0||e.toString().indexOf("%")>0?e.toString():e.toString()+"px"},t.prototype.renderCanvas=function(e){var i=document.getElementById(this.element.id+"_canvas");i||(i=Tt("div",{}),this.element.appendChild(i)),Ho(i,{id:this.element.id+"_canvas",class:"drawing",style:"position:relative; height:"+this.getSizeValue(this.model.height)+"; width:"+this.getSizeValue(this.model.width)+";style:-ms-touch-action: none;touch-action: none;"}),this.element.setAttribute("tabindex",String(-1)),this.element.style.overflow="hidden",this.element.style.height=String(this.model.height),this.element.style.width=String(this.model.width),this.canvas=i},t.prototype.setParent=function(e){var i=document.getElementById(e);if(this.parent){var s=this.parent;this.parent=null,s.setOverview(null,this.element.id),this.removeDocument(this)}this.parent=this.getDiagram(i,"ej2_instances"),this.parent&&this.parent.setOverview(this)},t.prototype.getDiagram=function(e,i){for(var r,s=e[""+i].length,o=0;o0?f:Math.floor(window.innerWidth)}if(0===h){var p=Math.floor(window.innerHeight-u-Math.floor(c.top));h=p>0?p:Math.floor(window.innerHeight)}l>0&&(s.setAttribute("width",String(l)),this.model.height=h),h>0&&(s.setAttribute("height",String(h)),this.model.width=l),e.diagramLayerDiv||(e.diagramLayerDiv=Tt("div",{}),e.diagramLayer=bo.createCanvas(this.element.id+"_diagramLayer",this.model.width,this.model.height),e.diagramLayer.setAttribute("style","position:absolute; left:0px; top:0px "),e.diagramLayerDiv.appendChild(e.diagramLayer),e.canvas.appendChild(e.diagramLayerDiv)),Ho(e.diagramLayerDiv,{id:this.element.id+"_diagramLayer_div",style:"width:"+this.model.width+"px; height:"+this.model.height+"px;position:absolute;top:0px;left:0px"}),this.renderHtmlLayer(e.canvas),this.renderNativeLayer(e.canvas,e),this.addOverviewRectPanel(e)},t.prototype.removeDocument=function(e){var i=document.getElementById(this.canvas.id+"_svg");this.canvas.removeChild(i);var r=document.getElementById(this.element.id+"_htmlLayer");this.canvas.removeChild(r);var s=document.getElementById(this.element.id+"_diagramLayer_div");this.canvas.removeChild(s),e.diagramLayerDiv=null,e.diagramLayer=null,window.domTable[this.id+"html_layer"]=null},t.prototype.renderHtmlLayer=function(e){var i=Tt("div",{id:this.element.id+"_htmlLayer",class:"e-html-layer",style:"pointer-events:none;position:absolute;top:0px;left:0px;"}),s=Tt("div",{id:this.element.id+"_htmlLayer_div",style:"position:absolute;top:0px;left:0px;"});return i.appendChild(s),e.appendChild(i),i},t.prototype.renderNativeLayer=function(e,i){if(!document.getElementById(this.element.id+"_nativeLayer_svg")){var r=this.parent.createSvg(this.element.id+"_nativeLayer_svg",this.model.width,this.model.height),s=Fi("g",{id:this.element.id+"_nativeLayer"});r.appendChild(s),i.diagramLayerDiv.appendChild(r),ti(r,{class:"e-native-layer"})}},t.prototype.addOverviewRectPanel=function(e){var i=document.getElementById(this.canvas.id+"_overviewsvg");i&&i.parentNode.removeChild(i),i=Fi("svg",{id:this.canvas.id+"_overviewsvg",class:"overviewsvg",version:"1.1",style:"position:absolute;left:0px;top:0px; aria-label:Specifies overview",width:this.model.width,height:this.model.height}),e.canvas.appendChild(i);var s=Fi("g",{id:this.element.id+"_overviewlayer",style:"pointer-events:none"});i.appendChild(s);var o=Fi("rect",{fill:"transparent",width:"100%",height:"100%",class:"overviewbackrect",id:this.canvas.id+"overviewbackrect"});o.setAttribute("style"," pointer-events: none; "),s.appendChild(o);var a=Fi("g",{id:this.canvas.id+"overviewhandle",style:"pointer-events:all"});s.appendChild(a);var l=Fi("rect",{id:this.canvas.id+"overviewrect",fill:"transparent"});a.appendChild(l),this.renderOverviewCorner("left",a),this.renderOverviewCorner("right",a),this.renderOverviewCorner("top",a),this.renderOverviewCorner("bottom",a),this.renderOverviewCorner("topleft",a),this.renderOverviewCorner("topright",a),this.renderOverviewCorner("bottomleft",a),this.renderOverviewCorner("bottomright",a)},t.prototype.renderOverviewCorner=function(e,i){var s,o=Fi(s="top"===e||"bottom"===e||"right"===e||"left"===e?"rect":"circle",{id:this.canvas.id+"visible"+e,class:"overview-resizer"});i.appendChild(o);var a=Fi(s,{id:this.canvas.id+e,class:"overviewresizer",fill:"transparent"});i.appendChild(a)},t.prototype.updateOverviewRectangle=function(){var e=this.currentPoint.x-this.prevPoint.x,i=this.currentPoint.y-this.prevPoint.y,r=new me;r.width=0,r.height=0;var s=0,o=0;switch(this.resizeDirection){case"left":r.width-=e,r.height-=e/this.viewPortRatio,s=e,o=e/this.viewPortRatio,o/=2;break;case"right":r.width+=e,r.height+=e/this.viewPortRatio,o=e/this.viewPortRatio,o/=-2;break;case"top":r.height-=i,r.width-=i*this.viewPortRatio,o=i,s=i*this.viewPortRatio,s/=2;break;case"bottom":r.height+=i,r.width+=i*this.viewPortRatio,s=i*this.viewPortRatio,s/=-2;break;case"topleft":Math.abs(i)>Math.abs(e)?e=i*this.viewPortRatio:i=e/this.viewPortRatio,r.width-=e,r.height-=i,s=e,o=i;break;case"topright":Math.abs(i)>Math.abs(e)?e=-i*this.viewPortRatio:i=-e/this.viewPortRatio,o=i,r.width+=e,r.height-=i;break;case"bottomleft":Math.abs(i)>Math.abs(e)?e=-i*this.viewPortRatio:i=-e/this.viewPortRatio,s=e,r.width-=e,r.height+=i;break;case"bottomright":Math.abs(i)>Math.abs(e)?e=i*this.viewPortRatio:i=e/this.viewPortRatio,r.width+=e,r.height+=i}this.updateHelper(s,o,r,void 0,void 0)},t.prototype.updateHelper=function(e,i,r,s,o){var a,l,h,u,f,d=this.element.getElementsByTagName("svg")[2].getElementById("helper");r?(a=(h=d.getBBox()).x+e,l=h.y+i,s=h.width+r.width,o=h.height+r.height):(u=this.currentPoint.x>this.startPoint.x?this.currentPoint.x-this.prevPoint.x:this.prevPoint.x-this.currentPoint.x,f=this.currentPoint.y>this.startPoint.y?this.currentPoint.y-this.prevPoint.y:this.prevPoint.y-this.currentPoint.y,Math.abs(f)>Math.abs(u)?u=this.viewPortRatio*f:f=u/this.viewPortRatio,h=d.getBBox(),a=this.startPoint.x>this.currentPoint.x?h.x-u:h.x,l=this.startPoint.y>this.currentPoint.y?h.y-f:h.y,s=h.width+u,o=h.height+f),ti(this.helper,{id:this.helper.id,x:a,y:l,width:Math.max(0,s),height:Math.max(0,o)})},t.prototype.updateOverviewrect=function(e,i,r,s){Ho(document.getElementById(this.canvas.id+"overviewrect"),{x:e,y:i,width:Math.max(1,r),height:Math.max(1,s)}),this.updateOverviewCorner("top",e+8,i+1,Math.max(0,r-16),2),this.updateOverviewCorner("bottom",e+8,i+s+3,Math.max(0,r-16),2),this.updateOverviewCorner("left",e-2,i+11,2,Math.max(0,s-16)),this.updateOverviewCorner("right",e+r,i+11,2,Math.max(0,s-16)),this.updateOverviewCorner("topleft",e,i+3,5,5),this.updateOverviewCorner("topright",e+r,i+3,5,5),this.updateOverviewCorner("bottomleft",e,i+s+3,5,5),this.updateOverviewCorner("bottomright",e+r,i+s+3,5,5)},t.prototype.updateOverviewCorner=function(e,i,r,s,o){var a,l;"top"===e||"bottom"===e||"right"===e||"left"===e?(a={x:i,y:r,width:s,height:o,fill:"#ED1C24"},l={x:i-2,y:r-2,width:2===s?4:s,height:2===o?4:o}):(a={cx:i,cy:r,r:4,fill:"#ED1C24"},l={cx:i,cy:r,r:6,fill:"transparent"}),Ho(document.getElementById(this.canvas.id+"visible"+e),a),Ho(document.getElementById(this.canvas.id+e),l)},t.prototype.translateOverviewRectangle=function(){Number(this.model.width),Number(this.model.height);var r=this.currentPoint.x-this.prevPoint.x,s=this.currentPoint.y-this.prevPoint.y,l=this.element.getElementsByClassName("overviewsvg")[0].getElementById(this.canvas.id+"overviewrect").getBBox(),h=l.x+r,c=l.y+s,d=l.width,u=l.height;this.updateOverviewrect(h,c,d,u),this.updateParentView(this.parent.scroller.currentZoom,h,c,d,u,null)},t.prototype.renderOverviewRect=function(e,i,r,s){var o=Number(this.model.width),a=Number(this.model.height),c=Math.max(this.parent.scroller.viewPortWidth/(r/o*this.contentWidth),this.parent.scroller.viewPortHeight/(s/a*this.contentHeight));if(c>=.25&&c<=30){this.updateParentView(c,e,i,r,s,{x:0,y:0});var u=this.scrollOverviewRect(this.parent.scroller.horizontalOffset,this.parent.scroller.verticalOffset,this.parent.scroller.currentZoom,!0);if(this.helper){var p=this.element.getElementsByTagName("rect")[10].getBBox();u.x=p.x,u.y=p.y}"pan"===this.actionName?this.updateOverviewrect(-u.x,-u.y,u.width,u.height):this.updateOverviewrect(u.x,u.y,u.width,u.height)}},t.prototype.scrollOverviewRect=function(e,i,r,s){if(!this.actionName||s){var o=Number(this.model.width),a=Number(this.model.height),l=Math.min(this.contentWidth/o,this.contentHeight/a),h=new Ne,c=h.x=e/r/l,d=h.y=i/r/l,u=0;this.parent.rulerSettings.showRulers&&(u=25);var f=document.getElementById(this.parent.element.id+"content"),p=0,g=0;f&&(p=f.offsetWidth-f.clientWidth,g=f.offsetHeight-f.clientHeight);var v=h.width=(this.parent.scroller.viewPortWidth-u-p)/r/l,y=h.height=(this.parent.scroller.viewPortHeight-u-g)/r/l;if(s){var S=new Ne;return S.x=c,S.y=d,S.width=v,S.height=y,S}this.updateOverviewrect(-c,-d,v,y)}return null},t.prototype.updateParentView=function(e,i,r,s,o,a){var p,g,l=Number(this.model.width),h=Number(this.model.height),u=i*(this.contentWidth/l)*e,f=r*(this.contentHeight/h)*e;this.parent.scroller.getPageBounds(),(1!==e||"pan"===this.actionName)&&(p=-u-this.parent.scroller.horizontalOffset,g=-f-this.parent.scroller.verticalOffset),this.parent.setBlazorDiagramProps(!0),this.parent.realActions|=$i.OverViewAction,"scale"===this.actionName||"draw"===this.actionName?this.parent.scroller.zoom(e/this.parent.scroller.currentZoom,p,g,a):ce()?this.parent.scroller.zoom(1,p,g,a):this.parent.pan(p,g,a,!0)},t.prototype.updateHtmlLayer=function(e){var i=Io(e.element.id),r=this.parent.scroller.getPageBounds(!0),o=r.height,a=Math.max(r.width,this.parent.scroller.viewPortWidth),l=Math.max(o,this.parent.scroller.viewPortHeight/this.parent.scroller.currentZoom),h=Math.min(Number(this.model.width)/a,Number(this.model.height)/l);i.style.transform="scale("+h+") translate("+this.parent.scroller.transform.tx+"px,"+this.parent.scroller.transform.ty+"px)"},t.prototype.updateView=function(e){var i=this.parent.scroller.getPageBounds(),r=i.width,s=i.height,o=Number(this.model.width),a=Number(this.model.height),l=Math.max(r,this.parent.scroller.viewPortWidth),h=Math.max(s,this.parent.scroller.viewPortHeight);this.contentWidth=l=Math.max(l,o/a*h),this.contentHeight=h=Math.max(h,a/o*l);var c=Math.min(o/l,a/h),d=document.getElementById(this.element.id+"_htmlLayer");d.style.webkitTransform="scale("+c+") translate("+-i.x+"px,"+-i.y+"px)",d.style.transform="scale("+c+") translate("+-i.x+"px,"+-i.y+"px)",document.getElementById(this.element.id+"_overviewlayer").setAttribute("transform","translate("+-i.x*c+","+-i.y*c+")"),this.horizontalOffset=i.x*c,this.verticalOffset=i.y*c;var f=document.getElementById(this.element.id+"_diagramLayer"),p=zF(this.element.id),g=f.getContext("2d"),v=Number(this.model.width)/this.contentWidth,y=Number(this.model.height)/this.contentHeight;v=Math.min(v,y);var S=this.parent.scroller.transform;p.setAttribute("transform","translate("+S.tx*v+","+S.ty*y+"),scale("+v+")"),g.setTransform(v,0,0,v,0,0),g.fillStyle="red",this.scrollOverviewRect(this.parent.scroller.horizontalOffset,this.parent.scroller.verticalOffset,this.parent.scroller.currentZoom)},t.prototype.scrolled=function(e){if(this.event){var i=this.scrollOverviewRect(this.parent.scroller.horizontalOffset,this.parent.scroller.verticalOffset,this.parent.scroller.currentZoom,!0);this.updateOverviewrect(-i.x,-i.y,i.width,i.height),this.updateView(this)}},t.prototype.updateCursor=function(e){if(um(e.target,"overviewresizer"))switch(e.target.id){case this.canvas.id+"left":this.canvas.style.cursor="w-resize";break;case this.canvas.id+"right":this.canvas.style.cursor="e-resize";break;case this.canvas.id+"top":this.canvas.style.cursor="n-resize";break;case this.canvas.id+"bottom":this.canvas.style.cursor="s-resize";break;case this.canvas.id+"topleft":this.canvas.style.cursor="nw-resize";break;case this.canvas.id+"topright":this.canvas.style.cursor="ne-resize";break;case this.canvas.id+"bottomleft":this.canvas.style.cursor="sw-resize";break;case this.canvas.id+"bottomright":this.canvas.style.cursor="se-resize"}else this.canvas.style.cursor="default"},t.prototype.mouseMove=function(e){if(this.event=!1,this.updateCursor(e),this.currentPoint=this.mousePosition(e),this.actionName)switch(this.actionName){case"draw":!this.inAction&&(this.startPoint.x!==this.currentPoint.x||this.startPoint.y!==this.currentPoint.y)&&(this.initHelper(),this.inAction=!0),this.inAction&&this.updateHelper();break;case"scale":this.inAction||(this.initHelper(),this.inAction=!0),this.updateOverviewRectangle();break;case"pan":(this.startPoint.x!==this.currentPoint.x||this.startPoint.y===this.currentPoint.y||this.inAction)&&(this.inAction=!0,this.translateOverviewRectangle())}this.prevPoint=this.currentPoint},t.prototype.documentMouseUp=function(e){this.inAction=!1,this.actionName="",this.helper&&(this.helper.parentNode.removeChild(this.helper),this.helper=null),this.event=!0,document.getElementById(this.canvas.id+"overviewhandle").style.pointerEvents="all"},t.prototype.windowResize=function(e){var i=this;return this.resizeTo&&clearTimeout(this.resizeTo),this.resizeTo=setTimeout(function(){var s=document.getElementById(i.element.id).getBoundingClientRect();i.model.width=s.width>0?s.width:i.model.width,i.model.height=s.height>0?s.height:i.model.height,i.renderCanvas(),i.setParent(i.sourceID)},10),!1},t.prototype.mouseDown=function(e){if(e.target.id===this.canvas.id+"_overviewsvg"&&(this.actionName="draw"),e.target.id===this.canvas.id+"overviewrect"&&(this.actionName="pan"),um(e.target,"overviewresizer"))switch(this.actionName="scale",e.target.id){case this.canvas.id+"left":this.resizeDirection="left";break;case this.canvas.id+"right":this.resizeDirection="right";break;case this.canvas.id+"top":this.resizeDirection="top";break;case this.canvas.id+"bottom":this.resizeDirection="bottom";break;case this.canvas.id+"topleft":this.resizeDirection="topleft";break;case this.canvas.id+"topright":this.resizeDirection="topright";break;case this.canvas.id+"bottomleft":this.resizeDirection="bottomleft";break;case this.canvas.id+"bottomright":this.resizeDirection="bottomright"}this.startPoint=this.prevPoint=this.mousePosition(e),this.viewPortRatio=this.parent.scroller.viewPortWidth/this.parent.scroller.viewPortHeight,document.getElementById(this.canvas.id+"overviewhandle").style.pointerEvents="none"},t.prototype.mouseUp=function(e){if(this.currentPoint=this.mousePosition(e),this.actionName)if(this.startPoint.x!==this.currentPoint.x||this.startPoint.y!==this.currentPoint.y){if("pan"!==this.actionName&&this.helper){var i=this.element.getElementsByTagName("rect")[10].getBBox();this.resizeDirection=this.resizeDirection||"",this.renderOverviewRect(i.x,i.y,o=i.width,a=i.height)}}else if(e.target.id===this.canvas.id+"_overviewsvg"||"helper"===e.target.id){var o=(i=this.element.getElementsByTagName("svg")[2].getElementById(this.canvas.id+"overviewrect").getBBox()).width,a=i.height;this.inAction=!0,this.actionName="pan",this.renderOverviewRect(this.currentPoint.x-o/2,this.currentPoint.y-a/2,o,a),this.inAction=!1}this.helper&&(this.helper.parentNode.removeChild(this.helper),this.helper=null),this.actionName="",this.startPoint=null,this.currentPoint=null,this.prevPoint=null,this.helper=null,this.viewPortRatio=1,this.resizeDirection="",this.inAction=!1,this.event=!0,document.getElementById(this.canvas.id+"overviewhandle").style.pointerEvents="all"},t.prototype.initHelper=function(){var e=this.element.getElementsByTagName("svg")[2],i=this.startPoint.x,r=this.startPoint.y,s=1,o=1;if("scale"===this.actionName){var l=e.getElementById(this.canvas.id+"overviewrect").getBBox();i=l.x,r=l.y,s=l.width,o=l.height}var h=Fi("rect",{id:"helper",x:i,y:r,width:s,height:o,fill:"transparent",stroke:"gray","stroke-dasharray":"2 2","shape-rendering":"crispEdges"});e.getElementById(this.element.id+"_overviewlayer").appendChild(h),this.helper=h},t.prototype.mousePosition=function(e){var i,r,s;-1!==e.type.indexOf("touch")?(r=(i=e).changedTouches[0].clientX-this.element.offsetLeft,s=i.changedTouches[0].clientY-this.element.offsetTop):(r=e.clientX,s=e.clientY);var l=this.element.getBoundingClientRect();return{x:(r-=l.left)+this.horizontalOffset,y:(s-=l.top)+this.verticalOffset}},t.prototype.destroy=function(){if(this.unWireEvents(),this.notify("destroy",{}),n.prototype.destroy.call(this),document.getElementById(this.element.id)){this.element.classList.remove("e-overview");var e=document.getElementById(this.element.id+"_canvas");e&&this.element.removeChild(e)}this.parent.views.splice(this.parent.views.indexOf(this.element.id),1),this.diagramLayerDiv=null,this.canvas=null,this.parent=null},t.prototype.getModuleName=function(){return"Overview"},KI([I("100%")],t.prototype,"width",void 0),KI([I("100%")],t.prototype,"height",void 0),KI([I("")],t.prototype,"sourceID",void 0),KI([H()],t.prototype,"created",void 0),t}(Ii);function sse(n,t){for(var e=0;eR.findLength(e,n)?e:t;var o=R.findAngle(t,e),a=R.findAngle(i,n),l=R.findLength(i,n),h=a+2*(o-a);return{x:i.x+l*Math.cos(h*Math.PI/180),y:i.y+l*Math.sin(h*Math.PI/180)}}function Kf(n,t,e){if(n&&n.children&&n.children.length>0)for(var r=void 0,s=0;s0&&"annotations"!==r&&"ports"!==r)if(n[""+l].length>0)for(var h=0;h<=n[""+l].length;h++)Ro(n[""+l],t?t[""+l]:void 0,e[""+l],"annotations"===l||"ports"===l?n:void 0,l);else Ro(n[""+l],t?t[""+l]:void 0,e[""+l],"annotations"===l||"ports"===l?n:void 0,l);else if(s instanceof Object&&t&&"annotations"!==r&&"ports"!==r)Ro(n[""+l],t[""+l],e[""+l]);else if("annotations"!==r&&"ports"!==r&&t&&!t[""+l]||!t&&n&&(n[""+l]||void 0!==n[""+l]))n[""+l]=e[""+l];else{var c=void 0;("annotations"===r||"ports"===r)&&("annotations"===r?(n[""+l]&&Ro(n[""+l],t[""+l],e[""+l]),n[""+l]||(ps(i)===de?(c=new Or(i,"annotations",e[""+l]),i.annotations.push(c)):(c=new Kn(i,"annotations",e[""+l]),i.annotations.push(c)))):n[""+l]?Ro(n[""+l],t[""+l],e[""+l]):(c=new Es(i,"ports",e[""+l]),i.ports.push(c)))}}}function use(n,t){for(var e="Bezier"===n.type?function hse(n){var t=[];if("Bezier"===n.type)for(var e=0,i=0;i0||n.ports.length>0){var f=n.wrapper.children;for(i=3;i0)return{enabled:!1,intersectPt:e};var l=o/s,h=a/s;return l>=0&&l<=1&&h>=0&&h<=1?(e.x=i.x1+l*(i.x2-i.x1),e.y=i.y1+l*(i.y2-i.y1),{enabled:!0,intersectPt:e}):{enabled:!1,intersectPt:e}}function tb(n,t,e,i){var a=tm(cF(n.x,n.y,t.x,t.y),cF(e.x,e.y,i.x,i.y));return a.enabled?a.intersectPt:{x:0,y:0}}function cF(n,t,e,i){return{x1:Number(n)||0,y1:Number(t)||0,x2:Number(e)||0,y2:Number(i)||0}}function dF(n,t,e){var i=[],s={x:t.topRight.x+(e=e||0),y:t.topRight.y},o={x:t.bottomRight.x,y:t.bottomRight.y-e},a={x:t.bottomLeft.x,y:t.bottomLeft.y+e};return i.push({x:t.topLeft.x-e,y:t.topLeft.y}),i.push(s),i.push(o),i.push(a),i}function zc(n,t,e,i,r,s){var o={},a=e.scroller.transform.scale,h=e.scroller.verticalOffset;return o.x=(i?n.x:t.x)*a+e.scroller.horizontalOffset-r,o.y=(i?n.y:t.y)*a+h-s,o}function uF(n,t){var e=new Ze;return e.data=n.pathData,e.height=n.height>10?n.height-(n.padding.bottom+n.padding.top):n.height,e.width=n.width>10?n.width-(n.padding.left+n.padding.right):n.width,e.visible=n.visibility,e.id=t.id+"_shape",e.inversedAlignment=!1,e.horizontalAlignment="Center",e.verticalAlignment="Center",e.style={fill:n.iconStrokeColor,strokeColor:n.iconStrokeColor,strokeWidth:n.iconStrokeWidth},e.setOffsetWithRespectToBounds(.5,.5,"Fraction"),e.relativeMode="Object",e.description=t.description||"",e}function qx(n,t,e){var i=$x(n,t),r=R.findAngle(n[i.index],n[i.index+1]),s=function Sse(n){var t;t=n instanceof AI?0:void 0===n.content?10:0;var e=0;switch(n.alignment){case"Center":e=0;break;case"Before":e=-(0+t);break;case"After":e=0+t}return e}(t),o=R.transform(i.point,r+45,s);return i.point=o,i.angle=r,i}function $x(n,t){for(var r,s,a,l,e=0,i=t.offset,o=[],h=0;h=c)return s=R.findAngle(n[parseInt(d.toString(),10)],n[d+1]),{point:r=R.transform(n[parseInt(d.toString(),10)],s,c-(a||0)),index:l=d};a=o[parseInt(d.toString(),10)]}return{point:r,index:l}}function fF(n,t,e){t%=360;var a,l,s=225;switch(n.alignment){case"Before":t>=45&&t<=135?(l="right",a=.5===n.offset?"center":"top"):t>=s&&t<=315?(l="left",a=.5===n.offset?"center":"bottom"):t>45&&t=45&&t<=135?(l="left",a=.5===n.offset?"center":"top"):t>=s&&t<=315?(l="right",a=.5===n.offset?"center":"bottom"):t>45&&tMath.abs(t.y-n.y)?n.x0)for(var e=0;e=0;r--)("nodes"===i||"connectors"===i)&&(n[""+i][parseInt(r.toString(),10)].wrapper=null),"dataManager"!==i&&(n[""+i][parseInt(r.toString(),10)]=Kx(n[""+i][parseInt(r.toString(),10)],e[""+i][parseInt(r.toString(),10)],void 0!==t[""+i]?t[""+i][parseInt(r.toString(),10)]:[]),("[]"===JSON.stringify(n[""+i][parseInt(r.toString(),10)])||"{}"===JSON.stringify(n[""+i][parseInt(r.toString(),10)])||void 0===n[""+i][parseInt(r.toString(),10)])&&n[""+i].splice(r,1));n=void 0}function zh(n,t){var e=t.style,i=t;t.canApplyStyle=!0;for(var r=0,s=Object.keys(n);r=0&&n.splice(e,1)}function ep(n,t,e){var i;n.intermediatePoints=t,n.updateSegmentElement(n,t,n.wrapper.children[0],e);var r=n.sourceDecorator;if("Bezier"===n.type){var s=n.segments[0],o=n.segments[n.segments.length-1];i=[R.isEmptyPoint(o.point2)?o.bezierPoint2:o.point2,R.isEmptyPoint(s.point1)?s.bezierPoint1:s.point1]}else i=n.intermediatePoints;t=n.clipDecorators(n,t,e);var a=n.wrapper.children[0];a.canMeasurePath=!0,n.updateDecoratorElement(a=n.wrapper.children[1],t[0],i[1],r),n.updateDecoratorElement(a=n.wrapper.children[2],t[t.length-1],i[i.length-2],n.targetDecorator),n.updateShapeElement(n)}function eT(n,t,e){var l,i=n.wrapper,s=t.offset,o=t.size/e.scale,a=t.margin,h=i.offsetX-i.actualSize.width*i.pivot.x,c=i.offsetY-i.actualSize.height*i.pivot.y;if(l={x:0,y:0},n.nodes.length>0){switch(t.side){case"Top":l.x+=h+s*i.actualSize.width,l.y+=c-o;break;case"Bottom":l.x+=h+s*i.actualSize.width,l.y+=c+i.actualSize.height+o;break;case"Left":l.x+=h-o,l.y+=c+s*i.actualSize.height;break;case"Right":l.x+=h+i.actualSize.width+o,l.y+=c+s*i.actualSize.height}l.x+=(a.left-a.right)/e.scale+o/2*("Center"===t.horizontalAlignment?0:"Right"===t.horizontalAlignment?-1:1),l.y+=(a.top-a.bottom)/e.scale+o/2*("Center"===t.verticalAlignment?0:"Top"===t.verticalAlignment?-1:1)}else if(n.connectors.length>0){var d=n.connectors[0],u={offset:s},f=$x(d.intermediatePoints,u),p=f.index;l=f.point;var y,v=qx(d.intermediatePoints,u).angle;qi(y=Bi(),-v,d.intermediatePoints[parseInt(p.toString(),10)].x,d.intermediatePoints[parseInt(p.toString(),10)].y),(l=Ke(y,l)).x+=a.left-a.right+o/2*("Center"===t.horizontalAlignment?0:"Right"===t.horizontalAlignment?-1:1),l.y+=a.top-a.bottom+o/2*("Center"===t.verticalAlignment?0:"Top"===t.verticalAlignment?-1:1),qi(y=Bi(),v,d.intermediatePoints[parseInt(p.toString(),10)].x,d.intermediatePoints[parseInt(p.toString(),10)].y),l=Ke(y,l)}return 0===i.rotateAngle&&0===i.parentTransform||(qi(y=Bi(),i.rotateAngle+i.parentTransform,i.offsetX,i.offsetY),l=Ke(y,l)),l}function ga(n,t,e,i){if(i.annotation){if(Pl(i.annotation))return!0}else if(mr[""+t]&n&&bt[""+t]&e)return!0;return!1}function qr(n,t){return!!(mr[""+t]&n)}function Hc(n,t){return!!(Mx[""+t]&n)}function va(n,t){return n.visibility&t}function ib(n,t){var e;if("Text"===n.shape.type)e=n.shape;else{var i=t.split("_");t=i[i.length-1];for(var r=0;rn[""+t]?e.splice(0,0,n):e.push(n);else if(e.length>1){for(var i=0,r=e.length-1,s=Math.floor((i+r)/2);s!==i;)if(e[parseInt(s.toString(),10)][""+t]n[""+t]))break;r=s,s=Math.floor((i+r)/2)}e[parseInt(r.toString(),10)][""+t]n[""+t]?e.splice(i,0,n):e[parseInt(i.toString(),10)][""+t]n[""+t]&&e.splice(r,0,n)}}function Hse(n){var t=document.getElementById(n.diagramId),e="ej2_instances",i=t[""+e][0].nodes;void 0===i&&(i=function Bse(n){for(var t=[],e=0;e30?10:o/2;for(var h=0,c=0;c=l){var u=l-h;r=Gt(n[c],n[c+1]),s=R.transform(n[c],r,u);break}h+=d}return s},sb=function(n,t){if(n instanceof te||n instanceof de)for(var e=0;e=0||navigator.platform.indexOf("iPad")>=0||navigator.platform.indexOf("iPhone")>=0||navigator.platform.indexOf("MacIntel")>=0)&&("safari"===X.info.name||"webkit"===X.info.name)}function wF(n,t,e,i){return void 0!==t.previewSize[""+i]?t.previewSize[""+i]:void 0!==n.symbolPreview[""+i]?n.symbolPreview[""+i]:t[""+i]||e.actualSize[""+i]}function om(n,t,e){return n&&n.parentId&&(e=(n=t.nameTable[n.parentId]).parentId?om(n,t,e):n.id),e}function am(n,t){return n.selectedItems.connectors.length>1&&0===n.selectedItems.nodes.length&&0!==t.rotateAngle}function jse(n){if(n.arrowType&&""!==n.arrowType.trim())switch(n.arrowType){case"single-line-arrow":default:return{targetDecorator:"Arrow",strokeWidth:1};case"double-line-arrow":return{targetDecorator:"Arrow",strokeWidth:2};case"dotted-arrow":return{targetDecorator:"Arrow",strokeDashArray:"2,2"};case"single-line":return{targetDecorator:"None",strokeWidth:1};case"double-line":return{targetDecorator:"None",strokeWidth:2};case"dotted":return{targetDecorator:"None",strokeDashArray:"2,2"};case"wiggly-arrow":return{targetDecorator:"None",strokeWidth:1,opacity:0}}return{targetDecorator:"Arrow",strokeWidth:1}}var Vse=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),no=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},CF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Vse(t,n),no([I("None")],t.prototype,"shape",void 0),no([I("white")],t.prototype,"fill",void 0),no([I("Auto")],t.prototype,"horizontalAlignment",void 0),no([I("Auto")],t.prototype,"verticalAlignment",void 0),no([I(10)],t.prototype,"width",void 0),no([I(10)],t.prototype,"height",void 0),no([re({x:.5,y:1},R)],t.prototype,"offset",void 0),no([I("#1a1a1a")],t.prototype,"borderColor",void 0),no([I(1)],t.prototype,"borderWidth",void 0),no([re({},Jn)],t.prototype,"margin",void 0),no([I("")],t.prototype,"pathData",void 0),no([I("")],t.prototype,"content",void 0),no([I(0)],t.prototype,"cornerRadius",void 0),no([re({left:2,right:2,top:2,bottom:2},Jn)],t.prototype,"padding",void 0),no([I("#1a1a1a")],t.prototype,"iconColor",void 0),t}(Ee),Wse=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),nT=function(n){function t(){var e=null!==n&&n.apply(this,arguments)||this;return e.orientation="Vertical",e.measureChildren=void 0,e.considerPadding=!0,e}return Wse(t,n),t.prototype.measure=function(e){return this.desiredSize=this.measureStackPanel(e,"Horizontal"===this.orientation?this.updateHorizontalStack:this.updateVerticalStack),this.desiredSize},t.prototype.arrange=function(e){return this.actualSize=this.arrangeStackPanel(e,"Horizontal"===this.orientation?this.arrangeHorizontalStack:this.arrangeVerticalStack),this.updateBounds(),this.actualSize},t.prototype.measureStackPanel=function(e,i){var r=void 0;if(void 0!==this.children&&this.children.length>0)for(var s=0,o=this.children;s0){var r=void 0,s=void 0;r=this.offsetX-e.width*this.pivot.x+this.padding.left,s=this.offsetY-e.height*this.pivot.y+this.padding.top;for(var o=0,a=this.children;o0)for(var i=0,r=this.children;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Jse=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Zse(t,n),Rh([I("Horizontal")],t.prototype,"orientation",void 0),Rh([I("Center")],t.prototype,"type",void 0),Rh([I(void 0)],t.prototype,"offset",void 0),Rh([I(!1)],t.prototype,"enableRouting",void 0),Rh([I([])],t.prototype,"children",void 0),Rh([I("")],t.prototype,"assistants",void 0),Rh([I("")],t.prototype,"level",void 0),Rh([I("")],t.prototype,"hasSubTree",void 0),Rh([I("")],t.prototype,"rows",void 0),t}(Ee),Ni=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),q=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Kse=function(n){if(n)switch(n.type){case"Basic":default:return ob;case"Flow":return TF;case"Path":return EF;case"Image":return xF;case"Text":return zd;case"Bpmn":return cT;case"Native":return lm;case"HTML":return DF;case"UmlActivity":return AF;case"UmlClassifier":return LF;case"SwimLane":return Bd}return ob},ma=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),q([I("Basic")],t.prototype,"type",void 0),t}(Ee),EF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"Path"},q([I("Path")],t.prototype,"type",void 0),q([I("")],t.prototype,"data",void 0),t}(ma),lm=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"Native"},q([I("Native")],t.prototype,"type",void 0),q([I("")],t.prototype,"content",void 0),q([I("Stretch")],t.prototype,"scale",void 0),t}(ma),DF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"Html"},q([I("HTML")],t.prototype,"type",void 0),q([I("")],t.prototype,"content",void 0),t}(ma),xF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"Image"},q([I("Image")],t.prototype,"type",void 0),q([I("")],t.prototype,"source",void 0),q([I("None")],t.prototype,"scale",void 0),q([I("None")],t.prototype,"align",void 0),t}(ma),zd=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"Text"},q([I("Text")],t.prototype,"type",void 0),q([I("")],t.prototype,"content",void 0),q([re({},Jn)],t.prototype,"margin",void 0),t}(ma),ob=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"BasicShape"},q([I("Basic")],t.prototype,"type",void 0),q([I("Rectangle")],t.prototype,"shape",void 0),q([I(0)],t.prototype,"cornerRadius",void 0),q([Bt([],R)],t.prototype,"points",void 0),t}(ma),TF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"FlowShape"},q([I("Flow")],t.prototype,"type",void 0),q([I("Terminator")],t.prototype,"shape",void 0),t}(ma),oT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"BpmnGateway"},q([I("None")],t.prototype,"type",void 0),t}(Ee),aT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"BpmnDataObject"},q([I("None")],t.prototype,"type",void 0),q([I(!1)],t.prototype,"collection",void 0),t}(Ee),eoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),q([I("None")],t.prototype,"type",void 0),q([I("None")],t.prototype,"loop",void 0),q([I(!1)],t.prototype,"call",void 0),q([I(!1)],t.prototype,"compensation",void 0),t}(Ee),lT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"BpmnEvent"},q([I("Start")],t.prototype,"event",void 0),q([I("None")],t.prototype,"trigger",void 0),t}(Ee),Rd=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"BpmnSubEvent"},q([I("None")],t.prototype,"trigger",void 0),q([I("Start")],t.prototype,"event",void 0),q([I("")],t.prototype,"id",void 0),q([re({},R)],t.prototype,"offset",void 0),q([Bt([],Kn)],t.prototype,"annotations",void 0),q([Bt([],Es)],t.prototype,"ports",void 0),q([I()],t.prototype,"width",void 0),q([I()],t.prototype,"height",void 0),q([re({},Jn)],t.prototype,"margin",void 0),q([I("Center")],t.prototype,"horizontalAlignment",void 0),q([I("Center")],t.prototype,"verticalAlignment",void 0),q([I(!0)],t.prototype,"visible",void 0),t}(Ee),toe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),q([re({id:"success",event:"End",offset:{x:1,y:.5}},Rd)],t.prototype,"success",void 0),q([re({id:"failure",event:"Intermediate",trigger:"Error",offset:{x:.25,y:1}},Rd)],t.prototype,"failure",void 0),q([re({id:"cancel",event:"Intermediate",trigger:"Cancel",offset:{x:.75,y:1}},Rd)],t.prototype,"cancel",void 0),t}(Ee),ioe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),q([I("None")],t.prototype,"type",void 0),q([I(!1)],t.prototype,"adhoc",void 0),q([I("Default")],t.prototype,"boundary",void 0),q([I(!1)],t.prototype,"compensation",void 0),q([I("None")],t.prototype,"loop",void 0),q([I(!0)],t.prototype,"collapsed",void 0),q([Bt([],Rd)],t.prototype,"events",void 0),q([re({},toe)],t.prototype,"transaction",void 0),q([I(void 0)],t.prototype,"processes",void 0),t}(Ee),hT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"BpmnActivity"},q([I("Task")],t.prototype,"activity",void 0),q([re({},eoe)],t.prototype,"task",void 0),q([re({},ioe)],t.prototype,"subProcess",void 0),t}(Ee),hm=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return Ni(t,n),t.prototype.getClassName=function(){return"BpmnAnnotation"},q([I("")],t.prototype,"text",void 0),q([I("")],t.prototype,"id",void 0),q([I(0)],t.prototype,"angle",void 0),q([I()],t.prototype,"height",void 0),q([I()],t.prototype,"width",void 0),q([I(0)],t.prototype,"length",void 0),t}(Ee),roe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),q([I("")],t.prototype,"textAnnotationTarget",void 0),q([I("Auto")],t.prototype,"textAnnotationDirection",void 0),t}(Ee),cT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"BpmnShape"},q([I("Bpmn")],t.prototype,"type",void 0),q([I("Event")],t.prototype,"shape",void 0),q([re({},lT)],t.prototype,"event",void 0),q([re({},oT)],t.prototype,"gateway",void 0),q([re({},aT)],t.prototype,"dataObject",void 0),q([re({},hT)],t.prototype,"activity",void 0),q([re({},hm)],t.prototype,"annotation",void 0),q([Bt([],hm)],t.prototype,"annotations",void 0),q([re({},roe)],t.prototype,"textAnnotation",void 0),t}(ma),AF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"UmlActivityShape"},q([I("UmlActivity")],t.prototype,"type",void 0),q([I("Action")],t.prototype,"shape",void 0),t}(ma),dT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"MethodArguments"},q([I("")],t.prototype,"name",void 0),q([I("")],t.prototype,"type",void 0),q([re({},Xf)],t.prototype,"style",void 0),t}(Ee),sp=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"UmlClassAttribute"},q([I("Public")],t.prototype,"scope",void 0),q([I(!1)],t.prototype,"isSeparator",void 0),q([re({fill:"#F9F9F9",strokeColor:"#CCCCCC"},Ll)],t.prototype,"separatorStyle",void 0),t}(dT),cm=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"UmlClassMethod"},q([Bt([],dT)],t.prototype,"parameters",void 0),t}(sp),ab=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"UmlClass"},q([I("")],t.prototype,"name",void 0),q([Bt([],sp)],t.prototype,"attributes",void 0),q([Bt([],cm)],t.prototype,"methods",void 0),q([re({},Xf)],t.prototype,"style",void 0),t}(Ee),uT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"UmlInterface"},q([I(!1)],t.prototype,"isSeparator",void 0),q([re({fill:"#F9F9F9",strokeColor:"#CCCCCC"},Ll)],t.prototype,"separatorStyle",void 0),t}(ab),lb=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"UmlEnumerationMember"},q([I("")],t.prototype,"name",void 0),q([I("")],t.prototype,"value",void 0),q([I(!1)],t.prototype,"isSeparator",void 0),q([re({fill:"#F9F9F9",strokeColor:"#CCCCCC"},Ll)],t.prototype,"separatorStyle",void 0),q([re({},Xf)],t.prototype,"style",void 0),t}(Ee),fT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"UmlEnumeration"},q([I("")],t.prototype,"name",void 0),q([Bt([],lb)],t.prototype,"members",void 0),q([re({},Xf)],t.prototype,"style",void 0),t}(Ee),LF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"UmlClassifierShape"},q([I("UmlClassifier")],t.prototype,"type",void 0),q([re({},ab)],t.prototype,"classShape",void 0),q([re({},uT)],t.prototype,"interfaceShape",void 0),q([re({},fT)],t.prototype,"enumerationShape",void 0),q([I("Class")],t.prototype,"classifier",void 0),t}(ma),te=function(n){function t(e,i,r,s){var a,o=n.call(this,e,i,r,s)||this;return o.isCanvasUpdate=!1,o.status="None",o.parentId="",o.processId="",o.umlIndex=-1,o.outEdges=[],o.inEdges=[],o.isHeader=!1,o.isLane=!1,o.isPhase=!1,o.children&&o.children.length>0&&((!(a=r).style||!a.style.fill)&&(o.style.fill="transparent"),(!a.style||!a.style.strokeColor)&&(o.style.strokeColor="transparent")),o.shape&&"UmlActivity"===o.shape.type&&eb(r,o),o.shape&&"SwimLane"===o.shape.type&&aF(r,o),o.ports&&o.ports.length&&function ase(n){for(var t=0;t>";t=n;break;case"FinalNode":t=pF(e)}return t}(new Ze,i,this);break;case"Bpmn":if(e.bpmnModule){i=e.bpmnModule.initBPMNContent(i,this,e),this.wrapper.elementActions=this.wrapper.elementActions|Xr.ElementIsGroup;var v=this.shape.activity.subProcess;if(v.processes&&v.processes.length)for(var S=0,b=this.shape.activity.subProcess.processes;S>",margin:{left:10,right:10},id:"class",style:{fontSize:i.style.fontSize,color:i.style.color,fill:i.style.fill,textWrapping:r},offset:{x:.5,y:.3},constraints:Nr.ReadOnly}],constraints:(ie.Default|ie.HideThumbs)&~(ie.Rotate|ie.Drag|ie.Resize),verticalAlignment:"Stretch",horizontalAlignment:"Stretch",style:{fill:t.style.fill,strokeColor:"black"===t.style.strokeColor?"#ffffff00":t.style.strokeColor}},!0);return e.initObject(s),e.nodes.push(s),e.UpdateBlazorDiagramModel(s,"Node"),t.children.push(s.id),function Qse(n,t,e,i){if("Enumeration"===n.shape.classifier){var r=e.members;if(r&&r.length){rp(n,t);for(var s="",o=0;o0)for(var o=0;o0&&s.phaseSize&&(i+=s.phaseSize,Gv(n,s.phaseSize)),s.lanes.length>0)for(o=0;o0){var a=0;for(o=0;o0&&"Horizontal"===r.orientation)for(l=0;l0&&(i+=r.phaseSize,o=Xv(r.phaseSize),n.push(o)),a=0;a0&&o.phaseSize){for(var l=0;l0)for(l=0;l0?e.nameTable[this.nodes[0].id].wrapper:e.nameTable[this.connectors[0].id].wrapper,this.annotation.id);i.children.push(s)}else if(this.nodes||this.connectors){for(var o=0;o-1}function HF(n,t,e){n=[];for(var i=0,r=e.length;i0?c.getElementsByTagName("svg")[0].outerHTML:c.getElementsByTagName("g").length>0?c.getElementsByTagName("g")[0].outerHTML:"",s.shape.content=h,n.content=h,c.parentElement.removeChild(c)}l="nodeTemplate"}else a=s,l="annotationTemplate";var p=document.getElementById(n.diagramId).ej2_instances[0];if("string"!=typeof n.content&&"function"!=typeof n.content||n.isTemplate)if(n.isTemplate){if(v=void 0,v=p.isReact?n.getNodeTemplate()($(e),p,l+"_"+("nodeTemplate"===l?e.id:n.nodeId+e.id),void 0,void 0,!1,i):p.isVue||p.isVue3?n.getNodeTemplate()?n.getNodeTemplate()($(e),p,l+"_"+("nodeTemplate"===l?e.id:n.nodeId+e.id),void 0,void 0,!1,i):(v=oi("nodeTemplate"===l?p.nodeTemplate:p.annotationTemplate))($(e),p,l+"_"+("nodeTemplate"===l?e.id:n.nodeId+e.id),void 0,void 0,!1,i):n.getNodeTemplate()($(e),p,l+"_"+("nodeTemplate"===l?e.id:n.nodeId+e.id),void 0,void 0,!1))for(var M=0;M=1&&0===n.x&&("Clip"===i.textOverflow||"Ellipsis"===i.textOverflow)&&("Wrap"===i.textWrapping||"WrapWithOverflow"===i.textWrapping)&&(n.x=t[e-1]?t[e-1].x:-n.width/2),n.x}function _F(n,t,e,i){return e&&!t.template||t.template&&"function"==typeof t.template&&i.isReact?(n.isTemplate=!0,n.template=n.content=Hh(n,!0,t)):n.content=t.template,n}function Qe(){for(var e,t="",i=0;i<5;i++){if(typeof window<"u"&&"crypto"in window&&"getRandomValues"in crypto){var r=new Uint16Array(1);e=(window.msCrypto||window.crypto).getRandomValues(r)[0]%60}else e=Math.floor(61*Math.random());0===i&&e<10?i--:t+="0123456789ABCDEFGHIJKLMNOPQRSTUVWXTZabcdefghiklmnopqrstuvwxyz".substring(e,e+1)}return t}function UF(n){if(n)try{return"function"!=typeof n&&document.querySelectorAll(n).length?oi(document.querySelector(n).innerHTML.trim()):oi(n)}catch{return oi(n)}}function xn(n){new Ne;var e=n.offsetY-n.actualSize.height*n.pivot.y,i=n.offsetY+n.actualSize.height*(1-n.pivot.y),r=n.offsetX-n.actualSize.width*n.pivot.x,s=n.offsetX+n.actualSize.width*(1-n.pivot.x);return Ne.toBounds([{x:r,y:e},{x:s,y:e},{x:r,y:i},{x:s,y:i}])}function yr(n){var t=new Ne,e=xn(n),i=e.middleLeft,r=e.topCenter,s=e.bottomCenter,o=e.middleRight,a=e.topLeft,l=e.topRight,h=e.bottomLeft,c=e.bottomRight;if(n.corners={topLeft:a,topCenter:r,topRight:l,middleLeft:i,middleRight:o,bottomLeft:h,bottomCenter:s,bottomRight:c},0!==n.rotateAngle||0!==n.parentTransform){var d=Bi();qi(d,n.rotateAngle+n.parentTransform,n.offsetX,n.offsetY),n.corners.topLeft=a=Ke(d,a),n.corners.topCenter=r=Ke(d,r),n.corners.topRight=l=Ke(d,l),n.corners.middleLeft=i=Ke(d,i),n.corners.middleRight=o=Ke(d,o),n.corners.bottomLeft=h=Ke(d,h),n.corners.bottomCenter=s=Ke(d,s),n.corners.bottomRight=c=Ke(d,c)}return t=Ne.toBounds([a,l,h,c]),n.corners.left=t.left,n.corners.right=t.right,n.corners.top=t.top,n.corners.bottom=t.bottom,n.corners.center=t.center,n.corners.width=t.width,n.corners.height=t.height,t}function $(n,t,e,i){var r={},s="properties";if(n){e=n.propName;var l=[],h=[];if((l=l.concat(Object.keys(n[""+s]||n))).push("version"),e){var c=Zi(t);h=c?c(e):[],l=l.concat(h)}for(var d=function woe(n){switch(n){case"nodes":case"children":return["inEdges","outEdges","parentId","processId","nodeId","umlIndex","isPhase","isLane"];case"connectors":return["parentId"];case"annotation":case"annotations":return["nodeId"];case"shape":return["hasHeader"];case"layers":return["objectZIndex"]}return[]}(e),u=0,f=l=l.concat(d);u0&&(e=r),r=Math.floor(Eoe(e,i)),s=Bc(o+=n.substr(e,r),t)}while(s<=t.width);for(o=o.substr(0,e),a=e;a=t.width){n=n.substr(0,o.length-1);break}return"Ellipsis"===t.textOverflow?(n=n.substr(0,n.length-3),n+="..."):n=n.substr(0,n.length),n}function IT(n,t){if("NoWrap"===t&&"PreserveAll"===n)return"pre";var e="";switch(n){case"CollapseAll":e="nowrap";break;case"CollapseSpace":e="pre-line";break;case"PreserveAll":e="pre-wrap"}return e}function bT(n,t){var e=Bi();qi(e,t,0,0);var i=Ke(e,{x:0,y:0}),r=Ke(e,{x:n.width,y:0}),s=Ke(e,{x:0,y:n.height}),o=Ke(e,{x:n.width,y:n.height}),a=Math.min(i.x,r.x,s.x,o.x),l=Math.min(i.y,r.y,s.y,o.y),h=Math.max(i.x,r.x,s.x,o.x),c=Math.max(i.y,r.y,s.y,o.y);return new me(h-a,c-l)}function xs(n,t,e,i){if(0!==n){var r=Bi();return qi(r,n,t,e),Ke(r,i)}return i}function Zi(n){return void 0!==n&&"string"==typeof n&&(n=Y(n,window)),n}var bo=function(){function n(){}return n.getContext=function(t){return t.getContext("2d")},n.setCanvasSize=function(t,e,i){t&&(t.setAttribute("width",e.toString()),t.setAttribute("height",i.toString()))},n.prototype.renderGradient=function(t,e,i,r){var s,o,a;if("None"!==t.gradient.type){for(var l=0;l0?(w=0===S.r1?e.arc[parseInt(r.toString(),10)].r1:S.r1,C=0===S.r2?e.arc[parseInt(r.toString(),10)].r2:S.r2,r++):(w=S.r1,C=S.r2);var D=S.angle*(Math.PI/180),A=S.largeArc,x=S.sweep,P={x:u,y:f},L={x:Math.cos(D)*(M.x-P.x)/2+Math.sin(D)*(M.y-P.y)/2,y:-Math.sin(D)*(M.x-P.x)/2+Math.cos(D)*(M.y-P.y)/2},O=Math.pow(L.x,2)/Math.pow(w,2)+Math.pow(L.y,2)/Math.pow(C,2);O>1&&(w*=Math.sqrt(O),C*=Math.sqrt(O));var N=Math.pow(C,2)*Math.pow(L.x,2),T=(A===x?-1:1)*Math.sqrt((Math.pow(w,2)*Math.pow(C,2)-Math.pow(w,2)*Math.pow(L.y,2)-N)/(Math.pow(w,2)*Math.pow(L.y,2)+Math.pow(C,2)*Math.pow(L.x,2)));isNaN(T)&&(T=0);var z={x:T*w*L.y/C,y:T*-C*L.x/w},U={x:(M.x+P.x)/2+Math.cos(D)*z.x-Math.sin(D)*z.y,y:(M.y+P.y)/2+Math.sin(D)*z.x+Math.cos(D)*z.y},B=this.a([1,0],[(L.x-z.x)/w,(L.y-z.y)/C]),j=[(L.x-z.x)/w,(L.y-z.y)/C],Q=[(-L.x-z.x)/w,(-L.y-z.y)/C],oe=this.a(j,Q);this.r(j,Q)<=-1&&(oe=Math.PI),this.r(j,Q)>=1&&(oe=0);var fe=B+oe/2*(x?1:-1);if(Math.cos(fe),Math.sin(fe),S.centp=U,S.xAxisRotation=D,S.rx=w,S.ry=C,S.a1=B,S.ad=oe,S.sweep=x,null!=s){var De=w>C?w:C,xe=w>C?1:w/C,Ie=w>C?C/w:1;s.save(),s.translate(U.x,U.y),s.rotate(D),s.scale(xe,Ie),s.arc(0,0,De,B,B+oe,!x),s.scale(1/xe,1/Ie),s.rotate(-D),s.translate(-U.x,-U.y),s.restore()}break;case"Z":case"z":s.closePath(),u=o,f=a}o=u,a=f}}},n.prototype.drawText=function(t,e,i,r,s,o,a){if(e.content&&!0===e.visible){var l=n.getContext(t);l.save(),this.setStyle(t,e),o&&(e.fontSize*=o),this.applyFlipAndRotate(l,e,t,e.x+e.width*e.pivotX,e.y+e.height*e.pivotY),this.setFontStyle(t,e);var u,d=0;u=e.childNodes;var f=e.wrapBounds;if(l.fillStyle=e.color,f){var p=this.labelAlign(e,f,u);for(d=0;de.width&&"Wrap"!==e.textOverflow&&"NoWrap"===e.textWrapping&&(g.text=VF(g.text,e)),"Clip"!==e.textOverflow&&"Ellipsis"!==e.textOverflow||"Wrap"!==e.textWrapping?l.fillText(g.text,v,y):ya.actualSize.height+a.bounds.y&&(g.text=g.text.slice(0,g.text.length-3),g.text=g.text.concat("...")),l.fillText(g.text,v,y)),"Underline"===e.textDecoration||"Overline"===e.textDecoration||"LineThrough"===e.textDecoration){var M=v,w=void 0,D=v+l.measureText(g.text).width,A=void 0;switch(e.textDecoration){case"Underline":w=y+2,A=y+2;break;case"Overline":w=p.y+g.dy*d,A=p.y+g.dy*d;break;case"LineThrough":w=(y+p.y+g.dy*d)/2+2,A=(y+p.y+g.dy*d)/2+2}l.beginPath(),l.moveTo(M,w),l.lineTo(D,A),l.strokeStyle=e.color,l.lineWidth=.08*e.fontSize,l.globalAlpha=e.opacity,l.stroke()}}}l.restore()}},n.prototype.applyFlipAndRotate=function(t,e,i,r,s){"Horizontal"===e.flip||"Vertical"===e.flip?(t.translate(e.x+e.width/2,e.y+e.height/2),t.rotate(-e.angle*Math.PI/180),t.translate(-e.x-e.width/2,-e.y-e.height/2)):this.rotateContext(i,e.angle,r,s),t.translate(e.x,e.y),"Horizontal"===e.flip?(t.scale(-1,1),t.translate(-1*e.width,0)):"Vertical"===e.flip?(t.scale(1,-1),t.translate(0,-1*e.height)):"Both"===e.flip&&(t.scale(-1,-1),t.translate(-1*e.width,-1*e.height)),t.translate(-e.x,-e.y)},n.prototype.loadImage=function(t,e,i,r,s){var o=new Image;o.src=e.source,this.image(t,o,e.x,e.y,e.width,e.height,e)},n.prototype.drawImage=function(t,e,i,r){var s=this;if(e.visible){var o=n.getContext(t);o.save();var a=e.x+e.width*e.pivotX,l=e.y+e.height*e.pivotY,h=new Image;h.src=e.source,this.setStyle(t,e),o.canvas.id.split("_"),this.applyFlipAndRotate(o,e,t,a,l),r?h.onload=function(){s.loadImage(o,e,t,a,l)}:this.loadImage(o,e,t,a,l),o.restore()}},n.prototype.image=function(t,e,i,r,s,o,a){t.beginPath();var l=e.width,h=e.height,c=s,d=o,u=0,f=0;if(a&&"None"!==a.alignment){var p=a.alignment.toLowerCase().substr(1,3),g=a.alignment.toLowerCase().substr(5,3);if("Slice"===a.scale){var v=function(){u=c,f=h*c/l},y=function(){u=l*d/h,f=d};c>d?(v(),d>f&&y()):c===d?l>h?y():v():(y(),c>u&&v());var S=this.getSliceOffset(p,u,c,l),b=this.getSliceOffset(g,f,d,h),M=l-S,w=h-b,C=u-S*(u/l),D=f-b*(f/h),A=Tt("canvas",{width:s.toString(),height:o.toString()});A.getContext("2d").drawImage(e,S,b,M,w,0,0,C,D),t.drawImage(A,i,r,s,o)}else if("Meet"===a.scale){var P=h/l,L=d/c;f=L>P?c*P:d,i+=this.getMeetOffset(p,u=L>P?c:d/P,c),r+=this.getMeetOffset(g,f,d),t.drawImage(e,0,0,l,h,i,r,u,f)}else t.drawImage(e,i,r,s,o)}else if("None"!==a.flip){var O=1,N=1;("Horizontal"===a.flip||"Both"===a.flip)&&(i=-i,s=-s,O=-1),("Vertical"===a.flip||"Both"===a.flip)&&(r=-r,o=-o,N=-1),t.scale(O,N),t.drawImage(e,i,r,s,o)}else t.drawImage(e,i,r,s,o);t.closePath()},n.prototype.getSliceOffset=function(t,e,i,r){switch(t){case"min":default:return 0;case"mid":return(e-i)/2*r/e;case"max":return(e-i)*r/e}},n.prototype.getMeetOffset=function(t,e,i){var r=Math.max(e,i),s=Math.min(e,i);switch(t){case"min":default:return 0;case"mid":return(r-s)/2;case"max":return r-s}},n.prototype.m=function(t){return Math.sqrt(Math.pow(t[0],2)+Math.pow(t[1],2))},n.prototype.r=function(t,e){return(t[0]*e[0]+t[1]*e[1])/(this.m(t)*this.m(e))},n.prototype.a=function(t,e){return(t[0]*e[1]t.width&&("Ellipsis"===t.textOverflow||"Clip"===t.textOverflow)&&"NoWrap"===t.textWrapping?0:.5*t.width:"right"===t.textAlign&&(c=1*t.width),s.x=t.x+c+(e?e.x:0),s.y=a+d-r.height/2,s},n}(),fb=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Vi=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},xoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return fb(t,n),Vi([I("")],t.prototype,"source",void 0),Vi([I("transparent")],t.prototype,"color",void 0),Vi([I("None")],t.prototype,"scale",void 0),Vi([I("None")],t.prototype,"align",void 0),t}(Ee),Toe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return fb(t,n),Vi([I("Page")],t.prototype,"mode",void 0),Vi([I("PageSettings")],t.prototype,"region",void 0),Vi([re({top:25,bottom:25,left:25,right:25},Jn)],t.prototype,"margin",void 0),Vi([I(!1)],t.prototype,"canZoomIn",void 0),Vi([I(void 0)],t.prototype,"customBounds",void 0),Vi([I(!1)],t.prototype,"canFit",void 0),t}(Ee),Aoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return fb(t,n),Vi([I(null)],t.prototype,"width",void 0),Vi([I(null)],t.prototype,"height",void 0),Vi([re({},Jn)],t.prototype,"margin",void 0),Vi([I("Landscape")],t.prototype,"orientation",void 0),Vi([I("Infinity")],t.prototype,"boundaryConstraints",void 0),Vi([re({},xoe)],t.prototype,"background",void 0),Vi([I(!1)],t.prototype,"multiplePage",void 0),Vi([I(!1)],t.prototype,"showPageBreaks",void 0),Vi([re({},Toe)],t.prototype,"fitOptions",void 0),t}(Ee),Loe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return fb(t,n),Vi([I(0)],t.prototype,"horizontalOffset",void 0),Vi([I(0)],t.prototype,"verticalOffset",void 0),Vi([I(1)],t.prototype,"currentZoom",void 0),Vi([I(0)],t.prototype,"viewPortWidth",void 0),Vi([I(0)],t.prototype,"viewPortHeight",void 0),Vi([I(.2)],t.prototype,"minZoom",void 0),Vi([I(30)],t.prototype,"maxZoom",void 0),Vi([I("Diagram")],t.prototype,"scrollLimit",void 0),Vi([I()],t.prototype,"scrollableArea",void 0),Vi([I(!1)],t.prototype,"canAutoScroll",void 0),Vi([I(100)],t.prototype,"autoScrollFrequency",void 0),Vi([re({left:15,right:15,top:15,bottom:15},Jn)],t.prototype,"autoScrollBorder",void 0),Vi([re({left:0,right:0,top:0,bottom:0},Jn)],t.prototype,"padding",void 0),Vi([I(.2)],t.prototype,"zoomFactor",void 0),t}(Ee),Noe=function(){function n(){this.services={}}return n.prototype.register=function(t,e){this.services[""+t]=e},n.prototype.getService=function(t){return this.services[""+t]},n}(),WF=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),ya=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},YF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return WF(t,n),ya([I("lightgray")],t.prototype,"lineColor",void 0),ya([I("")],t.prototype,"lineDashArray",void 0),ya([I([1.25,18.75,.25,19.75,.25,19.75,.25,19.75,.25,19.75])],t.prototype,"lineIntervals",void 0),ya([I([1,19,.5,19.5,.5,19.5,.5,19.5,.5,19.5])],t.prototype,"dotIntervals",void 0),ya([I([20])],t.prototype,"snapIntervals",void 0),t}(Ee),Ooe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return WF(t,n),ya([re({},YF)],t.prototype,"horizontalGridlines",void 0),ya([re({},YF)],t.prototype,"verticalGridlines",void 0),ya([I(Kt.All)],t.prototype,"constraints",void 0),ya([I(5)],t.prototype,"snapAngle",void 0),ya([I("Lines")],t.prototype,"gridType",void 0),ya([I(5)],t.prototype,"snapObjectDistance",void 0),ya([I("#07EDE1")],t.prototype,"snapLineColor",void 0),t}(Ee),QF=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),el=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},GF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return QF(t,n),el([I(5)],t.prototype,"interval",void 0),el([I(100)],t.prototype,"segmentWidth",void 0),el([I("Horizontal")],t.prototype,"orientation",void 0),el([I("RightOrBottom")],t.prototype,"tickAlignment",void 0),el([I("red")],t.prototype,"markerColor",void 0),el([I(25)],t.prototype,"thickness",void 0),el([I(null)],t.prototype,"arrangeTick",void 0),t}(Ee),koe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return QF(t,n),el([I(!1)],t.prototype,"showRulers",void 0),el([I(!0)],t.prototype,"dynamicGrid",void 0),el([re({orientation:"Horizontal"},GF)],t.prototype,"horizontalRuler",void 0),el([re({orientation:"Vertical"},GF)],t.prototype,"verticalRuler",void 0),t}(Ee),Poe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),XF=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},zoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Poe(t,n),XF([I("")],t.prototype,"property",void 0),XF([I("")],t.prototype,"field",void 0),t}(Ee),MT=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),ln=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},qF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return MT(t,n),ln([I("")],t.prototype,"read",void 0),ln([I("")],t.prototype,"create",void 0),ln([I("")],t.prototype,"update",void 0),ln([I("")],t.prototype,"destroy",void 0),ln([I()],t.prototype,"customFields",void 0),t}(Ee),Roe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return MT(t,n),ln([I("")],t.prototype,"id",void 0),ln([I("")],t.prototype,"sourceID",void 0),ln([I("")],t.prototype,"targetID",void 0),ln([I(null)],t.prototype,"sourcePointX",void 0),ln([I(null)],t.prototype,"sourcePointY",void 0),ln([I(null)],t.prototype,"targetPointX",void 0),ln([I(null)],t.prototype,"targetPointY",void 0),ln([I(null)],t.prototype,"dataManager",void 0),ln([re({},qF)],t.prototype,"crudAction",void 0),t}(Ee),Hoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return MT(t,n),ln([I("")],t.prototype,"id",void 0),ln([I(null)],t.prototype,"dataManager",void 0),ln([I(null)],t.prototype,"dataSource",void 0),ln([I("")],t.prototype,"root",void 0),ln([I("")],t.prototype,"parentId",void 0),ln([I()],t.prototype,"doBinding",void 0),ln([Bt([],zoe)],t.prototype,"dataMapSettings",void 0),ln([re({},qF)],t.prototype,"crudAction",void 0),ln([re({},Roe)],t.prototype,"connectionDataSource",void 0),t}(Ee),$F=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Cr=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Boe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return $F(t,n),Cr([I("LeftInFlow")],t.prototype,"yesBranchDirection",void 0),Cr([I("RightInFlow")],t.prototype,"noBranchDirection",void 0),Cr([I(["Yes","True"])],t.prototype,"yesBranchValues",void 0),Cr([I(["No","False"])],t.prototype,"noBranchValues",void 0),t}(Ee),Foe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return $F(t,n),Cr([I("")],t.prototype,"fixedNode",void 0),Cr([I(30)],t.prototype,"horizontalSpacing",void 0),Cr([I("SamePoint")],t.prototype,"connectionPointOrigin",void 0),Cr([I("Nonlinear")],t.prototype,"arrangement",void 0),Cr([I(30)],t.prototype,"verticalSpacing",void 0),Cr([I(30)],t.prototype,"maxIteration",void 0),Cr([I(40)],t.prototype,"springFactor",void 0),Cr([I(50)],t.prototype,"springLength",void 0),Cr([re({left:50,top:50,right:0,bottom:0},Jn)],t.prototype,"margin",void 0),Cr([I("Auto")],t.prototype,"horizontalAlignment",void 0),Cr([I("Auto")],t.prototype,"verticalAlignment",void 0),Cr([I("TopToBottom")],t.prototype,"orientation",void 0),Cr([I("Auto")],t.prototype,"connectionDirection",void 0),Cr([I("Default")],t.prototype,"connectorSegments",void 0),Cr([I("None")],t.prototype,"type",void 0),Cr([I()],t.prototype,"getLayoutInfo",void 0),Cr([I()],t.prototype,"layoutInfo",void 0),Cr([I()],t.prototype,"getBranch",void 0),Cr([I()],t.prototype,"bounds",void 0),Cr([I(!0)],t.prototype,"enableAnimation",void 0),Cr([I(!1)],t.prototype,"enableRouting",void 0),Cr([I("")],t.prototype,"root",void 0),Cr([re({},Boe)],t.prototype,"flowchartLayoutSettings",void 0),t}(Ee),_oe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),ZF=function(n){function t(e,i){var r=n.call(this,e,!0)||this;return r.oldValue=null,r.endPoint=i,r}return _oe(t,n),t.prototype.mouseDown=function(e){var i,r=!0;if(e.source&&e.source.connectors&&(i=e.source.connectors[0]),e.info&&e.actualObject&&(r=e.info.ctrlKey&&"Orthogonal"!==e.actualObject.type),i&&r){this.inAction=!0,this.undoElement=$(e.source),n.prototype.mouseDown.call(this,e);for(var s=0;s0)1!==s&&this.removePrevSegment(i,s);else if(a){var l=R.distancePoints(a.points[0],a.points[1]);Math.abs(a.length||0===a.length?a.length:l)<=5&&this.removeNextSegment(i,s)}this.commandHandler.updateEndPoint(i,r),i.selectedSegmentIndex=0}if(this.undoElement){var c=$(e.source);this.commandHandler.addHistoryEntry({type:"SegmentChanged",redoObject:c,undoObject:this.undoElement,category:"Internal"})}if(i.isBezierEditing&&(i.isBezierEditing=!1),this.prevPosition!==this.startPosition){var u={source:i,state:"Completed",oldValue:this.oldValue,newValue:$(this.selectedSegment),cancel:!1,segment:this.selectedSegment};this.commandHandler.triggerEvent(Ce.segmentChange,u)}n.prototype.mouseUp.call(this,e)},t.prototype.removePrevSegment=function(e,i){var r=e.segments[i-2],s=e.segments[i+1];if(s&&!((s.length||0===s.length?s.length:R.distancePoints(s.points[0],s.points[1]))<=5)){var a=e.segments.slice(i-1,i+1),l={element:e,removeSegments:a,type:"Removal",cancel:!1};if(this.commandHandler.triggerEvent(Ce.segmentCollectionChange,l),!l.cancel){var h=e.segments[i+1];e.segments.splice(i-1,2);var c=this.selectedSegment;"Left"===c.direction||"Right"===c.direction?(r.points[r.points.length-1].x=h.points[0].x,h.points[0].y=r.points[r.points.length-1].y):(r.points[r.points.length-1].y=h.points[0].y,h.points[0].x=r.points[r.points.length-1].x),(c.length||0===c.length)&&this.findSegmentDirection(r),this.findSegmentDirection(h)}}},t.prototype.findSegmentDirection=function(e){e.direction&&(e.length||0===e.length)&&(e.length=R.distancePoints(e.points[0],e.points[e.points.length-1]),e.direction=R.direction(e.points[0],e.points[e.points.length-1]))},t.prototype.removeNextSegment=function(e,i){var l,h,r=this.selectedSegment,s=e.segments[i-1],o=e.segments[i+2],a=e.segments[i+1];if(a.length||0===a.length?(l=e.segments.slice(i,2),h={element:e,removeSegments:l,type:"Removal",cancel:!1},this.commandHandler.triggerEvent(Ce.segmentCollectionChange,h={element:e,removeSegments:l,type:"Removal",cancel:!1}),h.cancel||(e.segments.splice(i,2),"Top"===r.direction||"Bottom"===r.direction?(o.points[0].y=r.points[0].y,s.points[s.points.length-1].x=o.points[0].x):(o.points[0].x=r.points[0].x,s.points[s.points.length-1].y=o.points[0].y))):(l=e.segments.slice(i+1,1),this.commandHandler.triggerEvent(Ce.segmentCollectionChange,h={element:e,removeSegments:l,type:"Removal",cancel:!1}),h.cancel||(e.segments.splice(i+1,1),"Top"===r.direction||"Bottom"===r.direction?s.points[s.points.length-1].x=a.points[a.points.length-1].x:s.points[s.points.length-1].y=a.points[a.points.length-1].y,this.findSegmentDirection(s),r.length=r.direction=null)),s&&o&&!h.cancel&&(s.length=R.distancePoints(s.points[0],o.points[0]),s.direction=R.direction(s.points[0],o.points[0]),o.length||0===o.length)){o.length=R.distancePoints(s.points[s.points.length-1],o.points[o.points.length-1]);var c=s.points,d=o.points;o.direction=R.direction(c[c.length-1],d[d.length-1])}},t.prototype.addOrRemoveSegment=function(e,i,r){for(var s,o,a=[],l={segments:e.segments},h=0;h0?"Bottom":"Top":r>0?"Right":"Left",length:i.points[0].x===i.points[1].x?s:r},!0)),l.push(new wi(e,"segments",{type:"Orthogonal",direction:c,length:h/2},!0));var f={element:e,addSegments:l,type:"Addition",cancel:!1};return this.commandHandler.triggerEvent(Ce.segmentCollectionChange,f),f.cancel||(e.segments=l.concat(e.segments),a=o+2),a},t.prototype.insertFirstSegment=function(e,i,r,s,o){var a,l,d,u,h=[];if(e.sourcePortID&&i.length&&e.segments[0].points.length>2)for(var f=void 0,p=0;p0?"Bottom":"Top":r>0?"Right":"Left"),f=u,h.push(u)}else h.push(new wi(e,"segments",{type:"Orthogonal",direction:i.direction,length:i.length/3},!0)),"Bottom"===i.direction||"Top"===i.direction?(l=Math.abs(r),a=r>0?"Right":"Left"):(l=Math.abs(s),a=s>0?"Bottom":"Top"),u=new wi(e,"segments",{type:"Orthogonal",direction:a,length:l},!0),h.push(u);var y={element:e,addSegments:h,type:"Addition",cancel:!1};if(this.commandHandler.triggerEvent(Ce.segmentCollectionChange,y),!y.cancel){if(e.sourcePortID&&i.length&&e.segments[0].points.length>2)e.segments.splice(0,1),d=1;else{var S=e.segments[1];S&&S.length&&(S.length=a!==S.direction?S.length+l:S.length-l),d=2,i.length=2*i.length/3}e.segments=h.concat(e.segments)}return d},t.prototype.updateAdjacentSegments=function(e,i,r,s){var o=e.segments[parseInt(i.toString(),10)],a=o.points[o.points.length-1],h=!0;"Orthogonal"===o.type&&(o.points[0]=o.points[0],o.points[o.points.length-1]=a,e.segments[i-1]&&(h=this.updatePreviousSegment(r,s,e,i)),e.segments.length-1>i&&h&&this.updateNextSegment(e,o,e.segments[i+1],r,s))},t.prototype.addTerminalSegment=function(e,i,r,s,o){var l,h,c,d,a=e.segments.indexOf(i),u=[],f=e.segments.pop(),p=e.segments[e.segments.length-1];l=p&&"Orthogonal"===p.type?p:null;for(var g=0;g0&&"Left"===o.direction?c.middleLeft:c.middleRight,o.length>c.width/2?Math.abs(a.length)0&&"Top"===o.direction?c.topCenter:c.bottomCenter,o.length>c.height/2?Math.abs(a.length)1)for(var a=0,l=this.diagram.views;a0)for(var e=t===Ce.onUserHandleMouseLeave?this.previousAction:this.action,i={element:void 0},r=0;r0)for(var r={element:void 0},s=void 0,o=void 0,a=0;a-1&&(o=s,this.previousTarget=i,this.targetItem=e),o===e.fixedUserHandles[parseInt(a.toString(),10)].id&&(r.element=e.fixedUserHandles[parseInt(a.toString(),10)],this.userHandle(t,a,r,e))},n.prototype.mouseDown=function(t){var e=this;if("touchstart"===t.type&&(this.timeOutTapHold=setTimeout(function(){("Select"===e.action||"Drag"===e.action)&&e.mouseMove(t,void 0)},500)),!0!==this.inAction||!(this.tool instanceof QI||this.tool instanceof pa)){this.focus=!0;var i=t.touches,r=!!document.getElementsByClassName("e-dragclone")[0];if(this.isMouseOnScrollBar(t)&&!r)return this.isScrolling=!0,void t.preventDefault();if(this.checkFixedUserHandleEvent(Ce.onFixedUserHandleMouseDown,this.targetItem,this.previousTarget),this.checkUserHandleEvent(Ce.onUserHandleMouseDown),!this.checkEditBoxAsTarget(t)&&jv(this.diagram)||Lc(this.diagram)&&!BI(this.diagram))if(("Select"===this.action||"Drag"===this.action)&&this.diagram.updatePortVisibility(this.hoverElement,ri.Hover,!0),!(this.tool instanceof zl||this.tool instanceof Rl)||2!==t.button&&2!==t.buttons)if(!0===this.inAction&&!0===this.isMouseDown&&(this.tool instanceof zl||this.tool instanceof Rl))this.isMouseDown=!0,this.eventArgs={},this.getMouseEventArgs(this.currentPosition,this.eventArgs),this.eventArgs.position=this.currentPosition,this.tool.mouseDown(this.eventArgs);else{this.isMouseDown=!0,this.currentPosition=this.prevPosition=this.getMousePosition(t),this.eventArgs={},this.diagram.textEditing&&!this.isMouseOnScrollBar(t)&&(this.diagram.endEdit(),this.diagram.textEditing=!1,"Canvas"===this.diagram.mode&&1!==this.diagram.scroller.currentZoom&&this.diagram.refreshDiagramLayer());var o=this.getTargetElement();this.action=this.diagram.findActionToBeDone(o.obj,o.sourceElement,this.currentPosition,o.target);var a=this.isMetaKey(t);a&&t.shiftKey&&this.diagram.connectorEditingToolModule?this.action="SegmentEnd":(a||t.shiftKey)&&(_v(this.diagram)||Uv(this.diagram))&&(this.action="Select"),this.tool=this.diagram.getTool(this.action),this.tool||(this.action="Select",this.tool=this.diagram.getTool(this.action)),this.getMouseEventArgs(this.currentPosition,this.eventArgs),(a||t.shiftKey)&&(this.eventArgs.info=a&&t.shiftKey?{ctrlKey:a,shiftKey:t.shiftKey}:{ctrlKey:!0}),this.eventArgs.position=this.currentPosition;var h=this.diagram.selectedItems.nodes;if(this.tool.mouseDown(this.eventArgs),this.diagram.selectedItems.canToggleSelection&&h&&this.diagram.selectedItems.nodes&&this.tool instanceof fa)for(var c=0;c=2&&(this.touchStartList=HF(this.touchStartList,0,i)),i||t.preventDefault())}else this.inAction=!1,this.tool.mouseUp(this.eventArgs);!this.isForeignObject(t.target)&&!this.isForeignObject(t.target,!0)&&!i&&t.preventDefault()}},n.prototype.mouseMoveExtend=function(t,e){(this.tool instanceof zl||this.tool instanceof Rl)&&this.tool.mouseMove(this.eventArgs),this.diagram.scrollSettings.canAutoScroll?this.checkAutoScroll(t):this.blocked||this.tool.mouseMove(this.eventArgs),this.eventArgs.target&&(this.hoverElement=this.eventArgs.target);var i=!((this.eventArgs.target instanceof te||this.eventArgs.target instanceof de)&&(e instanceof te||e instanceof de));this.tool instanceof kd&&this.diagram.updatePortVisibility(this.hoverElement instanceof te||this.hoverElement instanceof de?this.hoverElement:this.hoverNode,ri.Connect|ri.Hover,i),this.hoverElement instanceof te&&this.hoverNode instanceof te&&this.hoverNode&&this.hoverNode.id!==this.hoverElement.id&&this.diagram.updatePortVisibility(this.hoverNode,ri.Connect|ri.Hover,!0),this.hoverElement instanceof de&&this.hoverElement.ports.length>0&&this.diagram.updatePortVisibility(this.hoverElement,ri.Connect|ri.Hover,!0),this.previousElement instanceof te&&this.hoverElement&&this.previousElement.id!==this.hoverElement.id&&this.diagram.updatePortVisibility(this.previousElement,ri.Connect|ri.Hover,!0),this.previousElement=this.hoverElement,""!==this.diagram.tooltip.content&&(this.hoverElement=null),this.hoverNode=i?null:e},n.prototype.checkAction=function(t){if("LabelSelect"===this.action&&this.eventArgs.sourceWrapper&&(this.eventArgs.sourceWrapper instanceof li||this.eventArgs.sourceWrapper instanceof es)){var e=this.commandHandler.findTarget(this.eventArgs.sourceWrapper,this.eventArgs.source);!_r(this.diagram,e,!1,this.eventArgs.sourceWrapper)&&ro(e)&&(this.action="LabelDrag",this.tool=this.getTool(this.action),this.tool.mouseDown(this.initialEventArgs))}else ro(t)&&xd(t)&&this.initialEventArgs&&this.initialEventArgs.source&&"Select"===this.action&&(!_r(this.diagram,this.eventArgs.source,!1)&&this.eventArgs.source instanceof ei&&this.getMouseEventArgs(this.currentPosition,this.eventArgs),(!(t instanceof de)||t instanceof de&&!(wr(this.currentPosition,t.sourcePoint,t.hitPadding)||wr(this.currentPosition,t.targetPoint,t.hitPadding)))&&(this.action="Drag"),this.tool=this.getTool(this.action),this.tool.mouseDown(this.initialEventArgs))},n.prototype.isSwimlaneElements=function(t){return!(t&&(t.isLane||t.isPhase||t.isHeader))},n.prototype.canShowTouchTooltip=function(t){return!!("touchstart"===t.type&&this.diagram.tool&ni.SingleSelect&&this.diagram.tool&ni.ZoomPan)&&(this.isMouseDown=!1,!0)},n.prototype.mouseMove=function(t,e){if(this.focus=!0,"touchmove"===t.type&&(this.touchArgs={target:t.target,type:"touchmove"}),this.isScrolling)t.preventDefault();else if(jv(this.diagram)||Lc(this.diagram)&&!BI(this.diagram)){this.currentPosition=this.getMousePosition(t);var i=this.diagram.findObjectsUnderMouse(this.currentPosition),r=this.diagram.findObjectUnderMouse(i,this.action,this.inAction);!function qne(n,t){n.rulerSettings.showRulers&&(n.hRuler.drawRulerMarker(n.hRuler.element,t,n.scroller.horizontalOffset),n.vRuler.drawRulerMarker(n.vRuler.element,t,n.scroller.verticalOffset))}(this.diagram,this.currentPosition);var s=!1,o=void 0;if("touchmove"===t.type&&(e=t.touches)&&e.length>1&&(this.touchMoveList=HF(this.touchMoveList,0,e),"PinchZoom"!==this.action&&(s=!0)),!1===R.equals(this.currentPosition,this.prevPosition)||this.inAction||this.canShowTouchTooltip(t)){if(!1===this.isMouseDown||s){this.eventArgs={};var a=null,l=void 0;if(null!==r){if((a=this.diagram.findElementUnderMouse(r,this.currentPosition,this.diagram))&&(l=this.commandHandler.findTarget(a,r)),(l instanceof Kn||l instanceof Or)&&(l.tooltip&&""!==l.tooltip.content||(l=r)),l!==this.hoverElement){var h=this.getContent();this.hoverElement&&"Auto"===this.hoverElement.tooltip.openOn&&""!==h&&this.elementLeave(),this.diagram.updatePortVisibility(this.hoverElement,ri.Hover,!0),r instanceof te&&(this.hoverNode=r);var c=!0;!this.isSwimlaneElements(r)&&this.hoverElement&&this.isSwimlaneElements(this.hoverElement)&&(c=!1),this.hoverElement=c?r:this.hoverElement;var d,u=void 0;(d=this.diagram.findElementUnderMouse(r,this.currentPosition,this.diagram))instanceof Ze&&((u=this.commandHandler.findTarget(d,r))instanceof Es||u instanceof Tc)&&this.hoverElement.constraints&ai.ToolTip&&(this.hoverElement=u);var f=void 0;d instanceof li&&((f=this.commandHandler.findTarget(d,r))instanceof Kn||f instanceof Or)&&f.constraints&Nr.Tooltip&&(this.hoverElement=f),c?this.elementEnter(this.currentPosition,!1):this.hoverElement=r}else this.hoverElement&&this.hoverElement===l&&this.hoverElement.tooltip.content&&void 0!==this.diagram.tooltipObject&&"Mouse"===this.hoverElement.tooltip.relativeMode&&this.setTooltipOffset(this.currentPosition);a&&(o=this.commandHandler.findTarget(a,r))}this.action=this.diagram.findActionToBeDone(r,a,this.currentPosition,o),this.checkFixedUserHandleEvent(Ce.onFixedUserHandleMouseEnter,r,a),this.checkUserHandleEvent(Ce.onUserHandleMouseEnter),this.checkPreviousAction(),this.getMouseEventArgs(this.currentPosition,this.eventArgs),this.tool=this.getTool(this.action),this.mouseEvents(),this.tool instanceof pa||this.tool instanceof Rl||this.tool instanceof zl?this.tool.mouseMove(this.eventArgs):e&&this.tool instanceof Kv&&this.tool.mouseDown(this.eventArgs),this.updateCursor(),this.renderUmlHighLighter(this.eventArgs);var p=!1;this.hoverElement&&!(this.tool instanceof Kv)&&r instanceof te&&this.isSwimlaneElements(r)&&(0===this.diagram.selectedItems.nodes.length||!_r(this.diagram,this.hoverElement))||this.hoverElement instanceof de||(p=!0),this.hoverElement&&!(this.tool instanceof Kv)&&r instanceof de&&(0===this.diagram.selectedItems.connectors.length||!_r(this.diagram,this.hoverElement))||this.hoverElement instanceof te||(p=!0),this.diagram.updatePortVisibility(this.hoverElement,ri.Hover,p);var g=this.getContent();null===r&&this.hoverElement&&"Auto"===this.hoverElement.tooltip.openOn&&g&&(this.hoverElement=null,this.elementLeave()),s=!1}else{this.eventArgs.position=this.currentPosition,"Drag"===this.action&&!_r(this.diagram,this.eventArgs.source,!1)&&this.eventArgs.source instanceof ei&&this.getMouseEventArgs(this.currentPosition,this.eventArgs),this.mouseEvents(),(t.ctrlKey||t.shiftKey)&&(this.eventArgs.info=t.ctrlKey&&t.shiftKey?{ctrlKey:t.ctrlKey,shiftKey:t.shiftKey}:{ctrlKey:!0}),this.checkAction(r);var y=this.getConnectorPadding(this.eventArgs);this.getMouseEventArgs(this.currentPosition,this.eventArgs,this.eventArgs.source,y),this.updateCursor(),this.inAction=!0,this.initialEventArgs=null,("Drag"===this.action||"Rotate"===this.action)&&(this.diagram.diagramActions=this.diagram.diagramActions|ee.Interactions);var S=this.diagram.scroller.getPageBounds();this.mouseMoveExtend(t,r);var b=this.diagram.scroller.getPageBounds();if(r&&(S.width!==b.width||S.height!==b.height||S.x!==b.x||S.y!==b.y)&&this.diagram.views&&this.diagram.views.overview){var M=this.diagram.views.overview;M.updateView(M)}}this.prevPosition=this.currentPosition,this.isForeignObject(t.target,!0)||t.preventDefault()}}},n.prototype.getContent=function(){var i,t=this.hoverElement instanceof te&&this.hoverElement.constraints&ie.Tooltip||this.hoverElement instanceof de&&this.hoverElement.constraints&qe.Tooltip||(this.hoverElement instanceof Es||this.hoverElement instanceof Tc)&&this.hoverElement.constraints&ai.ToolTip||(this.hoverElement instanceof Kn||this.hoverElement instanceof Or)&&this.hoverElement.constraints&Nr.Tooltip,e=this.hoverElement;e instanceof te&&e.children&&e.children.length>0&&(i=this.findIntersectChild(e));var r=t?this.hoverElement.tooltip.content:this.diagram.tooltip.content;return i?i.tooltip.content:r},n.prototype.findIntersectChild=function(t){for(var e,i=new Ne(this.currentPosition.x,this.currentPosition.y,8,8),r=0;r1&&1===t.which&&!function Zre(n){return!!(n&ee.PreventClearSelection)}(this.diagram.diagramActions)&&(c=!1,this.commandHandler.clearSelection()),(!_r(this.diagram,h)||!c)&&(this.commandHandler.selectObjects([h],void 0,a),this.diagram.selectedItems.canToggleSelection)){var d=this.diagram.selectedItems.nodes;d?d[0].parentObj instanceof Hd&&(s=!0):this.diagram.selectedItems.connectors.length>0&&(s=!0)}}var u=!1,f=this.updateContainerProperties(),p=void 0;if(this.addUmlNode(),this.inAction=!1,this.isMouseDown=!1,this.diagram.selectedObject.helperObject&&(p=this.updateContainerBounds()),this.tool&&(this.tool.prevPosition||this.tool instanceof X3)){this.eventArgs.position=this.currentPosition;var g=this.getConnectorPadding(this.eventArgs);this.getMouseEventArgs(this.currentPosition,this.eventArgs,this.eventArgs.source,g);var v=this.isMetaKey(t);if((v||t.shiftKey)&&(this.eventArgs.info=v&&t.shiftKey?{ctrlKey:v,shiftKey:t.shiftKey}:{ctrlKey:!0}),this.diagram.diagramActions&ee.Interactions&&(this.diagram.diagramActions=this.diagram.diagramActions&~ee.Interactions),this.eventArgs.clickCount=t.detail,this.diagram.selectedObject.helperObject&&(this.tool instanceof fa||this.tool instanceof Pd)){if(this.diagram.selectedObject.actualObject&&""!==this.diagram.selectedObject.actualObject.parentId){var S=this.diagram.getObject(this.diagram.selectedObject.actualObject.parentId);S&&S.isLane&&(this.commandHandler.isContainer=!0)}(u=this.diagram.lineRoutingModule&&this.diagram.nameTable.helper&&this.eventArgs.target&&this.eventArgs.target.isLane&&(this.eventArgs.source instanceof ei&&this.eventArgs.source.nodes.length>0&&""===this.eventArgs.source.nodes[0].parentId||""===this.eventArgs.source.parentId))&&(this.diagram.diagramActions=this.diagram.diagramActions|ee.PreventLaneContainerUpdate),this.tool.mouseUp(this.eventArgs,f.isPreventHistory)}else{if(this.diagram.selectedItems.canToggleSelection){var b=void 0,M=void 0;if(this.diagram.selectedItems.nodes.length>0)for(var w=0;w1&&D[0].id===i[parseInt(w.toString(),10)].id||r.length>0)&&(M=!0);!this.isSwimlaneSelected&&!s&&!M&&this.tool instanceof fa&&"Select"===this.currentAction&&(!b||this.diagram.selectedItems.connectors.length>0)&&this.commandHandler.clearSelection(!0)}this.isSwimlaneSelected=!1,this.tool.mouseUp(this.eventArgs),this.diagram.checkMenu&&(-1!==window.navigator.userAgent.indexOf("Linux")||-1!==window.navigator.userAgent.indexOf("X11"))&&(!t.pageY&&t instanceof TouchEvent&&t.changedTouches?(window.getSelection().removeAllRanges(),this.diagram.contextMenuModule.contextMenu.open(t.changedTouches[0].pageY,t.changedTouches[0].pageX,this.diagram.element),t.preventDefault()):this.diagram.contextMenuModule.contextMenu.open(t.pageY,t.pageX,this.diagram.element),this.diagram.checkMenu=!1)}f.hasStack&&this.diagram.endGroupAction()}if(p&&this.diagram.endGroupAction(),this.updateContainerBounds(!0),2!==this.eventArgs.clickCount&&(this.commandHandler.updateSelectedNodeProperties(this.eventArgs.source),u)){this.diagram.diagramActions=this.diagram.diagramActions&~ee.PreventLaneContainerUpdate;var A=this.eventArgs.source instanceof ei?this.eventArgs.source.nodes:[this.eventArgs.source];if(A)for(w=0;w0&&!N&&this.diagram.renderSelector(!0),!this.inAction&&!this.diagram.currentSymbol&&this.eventArgs){var T=this.getTargetElement();this.diagram.tool!==ni.ZoomPan&&this.diagram.triggerEvent(Ce.click,{element:T.target instanceof Es?T.target:this.eventArgs.source||this.diagram,position:this.eventArgs.position,count:t.detail,actualObject:this.eventArgs.actualObject,button:0===t.button?"Left":1===t.button?"Middle":"Right"})}this.eventArgs={}}this.diagram.diagramActions=this.diagram.diagramActions&~ee.PreventLaneContainerUpdate,e&&this.updateAnnotation(this.diagram.selectedItems),this.previousElement=null,this.eventArgs={},this.diagram.commandHandler.removeStackHighlighter()},n.prototype.isSwimlaneChild=function(t){if(t.shape&&"SwimLane"!==t.shape.type){var e=this.diagram.nameTable[t.parentId];if(!e)return!1;var i=e.parentId?this.diagram.nameTable[e.parentId]:e;return i&&i.shape&&"SwimLane"===i.shape.type}return!1},n.prototype.updateAnnotation=function(t){var e=t.nodes;if(e.length>0)for(var i=0;i0&&(a+=1),h.isPhase){l="Horizontal"===r.orientation?this.currentPosition.x-e.wrapper.bounds.x:this.currentPosition.y-(e.wrapper.bounds.y+r.header.height);var g={id:Qe(),offset:l,header:{annotation:{content:void 0===h.phases[0].header?"Phase":h.phases[0].header.annotation.content,style:void 0===h.phases[0].header?{}:h.phases[0].header.annotation.style}},style:void 0===h.phases[0]?{}:h.phases[0].style};this.diagram.addPhases(e,[g])}else{var v={id:Qe(),style:h.lanes[0].style,header:{annotation:{content:h.lanes[0].header.annotation.content,style:h.lanes[0].header.annotation.style},style:h.lanes[0].header.style}};if("Horizontal"===h.orientation?v.height=h.lanes[0].height:v.width=h.lanes[0].width,"Horizontal"===r.orientation?(s=i.rowIndex?i.rowIndex:this.diagram.nameTable[i.parentId].rowIndex,i.wrapper.offsetYs)v.header.width=r.lanes[parseInt(s.toString(),10)].header.width,v.header.height=r.lanes[parseInt(s.toString(),10)].header.height;else{var S=void 0;S="Horizontal"===r.orientation?i.rowIndex<3?0:s-a-1:s-1,v.header.width=r.lanes[parseInt(S.toString(),10)].header.width,v.header.height=r.lanes[parseInt(S.toString(),10)].header.height}p&&("height"===p?(v.width=v.height,delete v.height):(v.height=v.width,delete v.width)),this.diagram.addLanes(e,[v],"Horizontal"===r.orientation?s-a:s)}this.commandHandler.select(e)}else if(h.isLane){var b={id:Qe(),width:t.width,height:t.height,addInfo:t.addInfo,shape:{type:"SwimLane",header:{annotation:{content:void 0===h.header?"Header":h.header.annotation.content,style:void 0===h.header?{}:h.header.annotation.style},height:50,style:h.header?h.header.style:h.lanes[0].header.style},phases:[{id:Qe(),header:{annotation:{content:void 0===h.phases||void 0===h.phases[0].header?"Phase":h.phases[0].header.annotation.content,style:void 0===h.phases||void 0===h.phases[0].header?{}:h.phases[0].header.annotation.style},style:void 0===h.phases||void 0===h.phases[0].header?{}:h.phases[0].header.style},style:void 0===h.phases?{}:h.phases[0].style}],lanes:[{id:Qe(),height:t.height,width:t.width,style:h.lanes[0].style,header:{annotation:{content:h.lanes[0].header.annotation.content,style:h.lanes[0].header.annotation.style},style:h.lanes[0].header.style}}],orientation:h.orientation}};"Vertical"===h.orientation&&(b.width+=20),b.offsetX=this.currentPosition.x+b.width/2,b.offsetY=this.currentPosition.y+b.height/2,b.style=t.style,this.diagram.add(b)}},n.prototype.mouseLeave=function(t){this.tool&&this.inAction&&this.tool.mouseLeave(this.eventArgs),this.diagram.selectedObject.helperObject&&(this.updateContainerProperties(),this.updateContainerBounds()&&this.diagram.endGroupAction()),this.eventArgs&&this.eventArgs.source&&(this.diagram.updatePortVisibility(this.eventArgs.source,ri.Hover,!0),this.hoverElement=null),this.eventArgs&&!this.eventArgs.source&&this.hoverElement&&(this.hoverElement=null),this.tool instanceof kd&&this.eventArgs&&this.eventArgs.target&&this.eventArgs.target instanceof te&&(this.diagram.updatePortVisibility(this.eventArgs.target,ri.Hover|ri.Connect,!0),this.hoverElement=null);var i=this.diagram.selectedItems;i&&i.wrapper&&(am(this.diagram,i)||this.diagram.renderSelector(!0)),(this.diagram.diagramActions&ee.Interactions||this.diagram.diagramActions&ee.ToolAction)&&(this.diagram.diagramActions=this.diagram.diagramActions&~ee.ToolAction),this.isMouseDown=!1,this.focus=!1,this.touchStartList=null,this.touchMoveList=null,this.elementLeave(),this.commandHandler.removeSnap(),this.inAction=!1,this.eventArgs={},this.diagram.selectedObject&&this.diagram.selectedObject.helperObject&&(this.diagram.remove(this.diagram.selectedObject.helperObject),this.diagram.selectedObject={helperObject:void 0,actualObject:void 0}),this.tool=null,function Xne(){var t,e,n=document.getElementsByClassName("e-d-ruler-marker");if(n&&n.length>0)for(e=n.length-1;e>=0;e--)(t=n[parseInt(e.toString(),10)])&&t.parentNode.removeChild(t)}(),"Rotate"===this.action&&this.diagram.diagramCanvas.classList.remove("e-diagram-rotate"),t.preventDefault()},n.prototype.mouseWheel=function(t){this.diagram.blazorActions|=on.interaction;var e={event:t,cancel:!1};if(this.diagram.triggerEvent(Ce.mouseWheel,e),!e.cancel){var i=t.wheelDelta>0||-40*t.detail>0,r=this.getMousePosition(t);if(this.diagram.tooltipObject.close(),this.isMetaKey(t)){var o=this.diagram.scrollSettings.zoomFactor;this.diagram.zoomTo(i?{type:"ZoomIn",zoomFactor:o,focusPoint:r}:{type:"ZoomOut",zoomFactor:o,focusPoint:r}),t.preventDefault()}else{var a=this.diagram.scroller.horizontalOffset,l=this.diagram.scroller.verticalOffset,h=i?10:-10;this.tool&&(this.tool instanceof zl||this.tool instanceof Rl)&&(this.eventArgs={},this.getMouseEventArgs(r,this.eventArgs),this.eventArgs.position=r,this.tool.mouseWheel(this.eventArgs)),this.diagram.scrollActions|=da.Interaction;var c=!0;if(t.isTrusted){var d=!1;(Math.abs(t.deltaY)<100&&-0===Math.abs(t.deltaX)||Math.abs(t.deltaX)<100&&-0===Math.abs(t.deltaY))&&(d=!0);var u=!1;(0!==t.deltaX||0!==t.deltaY)&&(u=navigator.userAgent.includes("Macintosh")),u?Math.abs(t.deltaX)>Math.abs(t.deltaY)?(t.shiftKey||t.deltaX&&-0!==t.deltaX&&(d||!u))&&this.diagram.scroller.zoom(1,h,0,r,c,void 0,d):t.deltaY&&-0!==t.deltaY&&(d||!u)&&this.diagram.scroller.zoom(1,0,h,r,c,void 0,d):t.shiftKey||t.deltaX&&-0!==t.deltaX&&(d||!u)?this.diagram.scroller.zoom(1,h,0,r,c,void 0,d):t.deltaY&&-0!==t.deltaY&&(d||!u)&&this.diagram.scroller.zoom(1,0,h,r,c,void 0,d)}else t.shiftKey||t.deltaX&&-0!==t.deltaX?this.diagram.scroller.zoom(1,h,0,r,c):this.diagram.scroller.zoom(1,0,h,r,c);this.diagram.scrollActions&=~da.Interaction,(a!==this.diagram.scroller.horizontalOffset||l!==this.diagram.scroller.verticalOffset)&&t.preventDefault()}if(this.diagram.textEditing){if(this.diagram.isTriggerEvent=!0,this.diagram.activeLabel.parentId){var p=this.diagram.getObject(this.diagram.activeLabel.parentId);this.diagram.startTextEdit(p,this.diagram.activeLabel.id)}this.diagram.isTriggerEvent=!1}this.diagram.blazorActions=this.diagram.blazorActions&~on.interaction}},n.prototype.keyDown=function(t){if(t.fromMouseEvents&&(t.ctrlKey&&(this.keyArgs.keyModifiers=1),t.shiftKey&&(this.keyArgs.keyModifiers=4),t.shiftKey&&t.ctrlKey&&(this.keyArgs.keyModifiers=5)),!(this.diagram.diagramActions&ee.TextEdit)&&!this.checkEditBoxAsTarget(t)||"Escape"===t.key||27===t.keyCode){var i=void 0,r=t.keyCode?t.keyCode:t.which,s=t.key;("ArrowDown"===s||"ArrowUp"===s||"ArrowLeft"===s||"ArrowRight"===s)&&(this.isNudgeKey=!0);var o=this.isMetaKey(t);if(this.diagram.commandManager&&this.diagram.commands)for(var l=0,h=Object.keys(this.diagram.commands);l4&&(S({keyDownEventArgs:KeyboardEvent,parameter:i.parameter,type:"KEYDOWN"}),this.keyCount=0,this.keyArgs.newValue={offsetX:this.diagram.selectedItems.offsetX,offsetY:this.diagram.selectedItems.offsetY},this.diagram.triggerEvent(Ce.positionChange,this.keyArgs))),this.isKeyUp=!1):S({keyDownEventArgs:KeyboardEvent,parameter:i.parameter})}break}}}}this.keyArgs={element:this.diagram.selectedItems,key:t.key,keyCode:t.keyCode?t.keyCode:t.which},this.getKeyModifier(this.keyArgs,t),this.diagram.diagramActions&ee.TextEdit&&this.getlabel(this.keyArgs,t),this.diagram.triggerEvent(Ce.keyDown,this.keyArgs)},n.prototype.getlabel=function(t,e){var i=this.diagram.activeLabel;t.target=this.diagram.element.id+"_editBox";var r=this.diagram.nameTable[i.parentId];if(document.getElementById(this.diagram.element.id+"_editBox")){t.text=document.getElementById(this.diagram.element.id+"_editBox").value;for(var s=0;s=this.diagram.scroller.viewPortWidth-18?r="right":e.x+this.diagram.scroller.horizontalOffsetthis.diagram.scroller.viewPortHeight-18?r="bottom":e.y+this.diagram.scroller.verticalOffset0&&(s=this.findIntersectChild(this.hoverElement)),"Auto"===this.hoverElement.tooltip.openOn&&""!==r&&wx(this.diagram,s||(i?this.hoverElement:void 0)),this.hoverElement.tooltip.content&&("Mouse"===this.hoverElement.tooltip.relativeMode?this.setTooltipOffset(t):(this.diagram.tooltipObject.offsetX=0,this.diagram.tooltipObject.offsetY=0));var o=this.diagram.findObjectsUnderMouse(this.currentPosition),a=this.diagram.findObjectUnderMouse(o,this.action,this.inAction);if(null!==a){var l=void 0;this.hoverElement.tooltip.isSticky&&(this.diagram.tooltipObject.isSticky=!0),a instanceof te&&a.children&&a.children.length>0&&(a=s||a),l=a.ports&&(this.hoverElement instanceof Es||this.hoverElement instanceof Tc)||a.annotations&&(this.hoverElement instanceof Kn||this.hoverElement instanceof Or)?document.getElementById(a.id+"_"+this.hoverElement.id):document.getElementById(a.id+(a.shape&&a.shape instanceof lm?"_content_native_element":"_groupElement")),"Auto"===this.hoverElement.tooltip.openOn&&""!==r&&(this.diagram.tooltipObject.close(),this.diagram.tooltipObject.openOn=this.hoverElement.tooltip.openOn,this.diagram.tooltipObject.dataBind()),function Wre(n,t){var e=0;return n instanceof de?n.constraints&qe.Tooltip?e=n.constraints&qe.Tooltip:n.constraints&qe.InheritTooltip&&(e=t.constraints&nt.Tooltip):n instanceof Es||n instanceof Tc?n.constraints&ai.ToolTip?e=n.constraints&ai.ToolTip:n.constraints&ai.InheritTooltip&&(e=t.constraints&nt.Tooltip):n instanceof Kn||n instanceof Or?n.constraints&Nr.Tooltip&&(e=n.constraints&Nr.Tooltip):n.constraints&ie.Tooltip?e=n.constraints&ie.Tooltip:n.constraints&ie.InheritTooltip&&(e=t.constraints&nt.Tooltip),e}(this.hoverElement,this.diagram)&&"Auto"===this.hoverElement.tooltip.openOn&&(this.diagram.tooltipObject.target=this.hoverElement.id,this.diagram.tooltipObject.open("Mouse"===this.hoverElement.tooltip.relativeMode?this.diagram.element:l))}}},n.prototype.elementLeave=function(){this.diagram.tooltipObject&&!this.diagram.tooltipObject.isSticky&&"Custom"!==this.diagram.tooltipObject.openOn&&this.diagram.tooltipObject.close()},n.prototype.setTooltipOffset=function(t){var e=function fse(n,t,e,i){var o="Mouse"===(!(e instanceof te?e.constraints&ie.InheritTooltip:e instanceof de?e.constraints&qe.InheritTooltip:e.constraints&ai.InheritTooltip)&&(e instanceof te?e.constraints&ie.Tooltip:e instanceof de?e.constraints&qe.Tooltip:e.constraints&ai.ToolTip)?e.tooltip.relativeMode:n.tooltip.relativeMode);"Mouse"===i?o=!0:"Object"===i&&(o=!1);var a=function pse(n,t,e,i){var o,r={},s=document.getElementById(e.element.id);if(n instanceof te||n instanceof de)o=n.wrapper.bounds;else{var a=e.findObjectsUnderMouse(t),l=e.findObjectUnderMouse(a,"Select",!1);o=e.findElementUnderMouse(l,t,e).bounds}var c=s.getBoundingClientRect();switch(e.tooltipObject.position){case"BottomCenter":r=zc(t,o.bottomCenter,e,i,c.width/2,c.height);break;case"BottomLeft":case"LeftBottom":r=zc(t,o.bottomLeft,e,i,0,c.height);break;case"BottomRight":case"RightBottom":r=zc(t,o.bottomRight,e,i,c.width,c.height);break;case"LeftCenter":r=zc(t,o.middleLeft,e,i,0,c.height/2);break;case"LeftTop":case"TopLeft":r=zc(t,o.topLeft,e,i,0,0);break;case"RightCenter":r=zc(t,o.middleRight,e,i,c.width,c.height/2);break;case"RightTop":case"TopRight":r=zc(t,o.topRight,e,i,c.width,0);break;case"TopCenter":r=zc(t,o.topCenter,e,i,c.width/2,0)}return r}(e,t,n,o),l=Za(n);return{x:a.x+l.width,y:a.y+l.height}}(this.diagram,t,this.hoverElement);this.diagram.tooltipObject.offsetX=e.x,this.diagram.tooltipObject.offsetY=e.y},n.prototype.altKeyPressed=function(t){return!!(t&ft.Alt)},n.prototype.ctrlKeyPressed=function(t){return!!(t&ft.Control)},n.prototype.shiftKeyPressed=function(t){return!!(t&ft.Shift)},n.prototype.scrolled=function(t){this.diagram.updateScrollOffset()},n.prototype.isMobileOrIPadDevice=function(){var t=navigator.userAgent||navigator.vendor||window.opera;return/iPhone|iPad|iPod/.test(t)&&!window.MSStream?"iOS":/android/i.test(t)?"Android":/Mobile|Tablet/.test(t)?"Mobile":"Desktop"},n.prototype.doubleClick=function(t){if(jv(this.diagram)){var e=this.isMobileOrIPadDevice(),i=this.diagram.tool;"Desktop"!==e&&this.tool&&(this.tool instanceof zl||this.tool instanceof Rl)&&(this.diagram.tool=0);var r=void 0,s=this.diagram.findObjectsUnderMouse(this.currentPosition),o=this.diagram.findObjectUnderMouse(s,this.action,this.inAction);if(null!==o&&jv(this.diagram))if(r=this.diagram.findElementUnderMouse(o,this.currentPosition,this.diagram),this.tool&&(this.tool instanceof zl||this.tool instanceof Rl))this.diagram.tool=i,this.tool.mouseUp(this.eventArgs),this.isMouseDown=!1,this.eventArgs={},this.tool=null,t.preventDefault();else{var l=this.diagram.commandHandler.getObjectLayer(o.id);!l||l.lock||!l.visible||this.diagram.diagramActions&ee.TextEdit||this.diagram.startTextEdit(o,r instanceof li?r.id.split(o.id+"_")[1]:void 0)}this.diagram.triggerEvent(Ce.doubleClick,{source:o||this.diagram,position:this.currentPosition,count:t.detail})}},n.prototype.itemClick=function(t,e){var i=t;return Dn(this.diagram,i,!0)?i:null},n.prototype.inputChange=function(t){var i,s,o,a,l,h,c,d,u,f=document.getElementById(this.diagram.element.id+"_editBox"),p=document.getElementById(this.diagram.element.id+"_editTextBoxDiv"),g=f.value,v=g.split("\n");(!(a=this.diagram.selectedItems.nodes[0]?this.diagram.selectedItems.nodes[0]:this.diagram.selectedItems.connectors[0])&&this.tool instanceof GI||a&&"SwimLane"===a.shape.type)&&(a=this.diagram.nameTable[this.diagram.activeLabel.parentId]),a&&("Text"!==a.shape.type&&a.annotations.length>0||"Text"===a.shape.type)&&(c=NF((o=this.diagram.getWrapper(a.wrapper,this.diagram.activeLabel.id)).style,g,void 0,void 0,i=(i=a.wrapper.bounds.width90?i:90),s=Number(f.style.fontSize.split("px")[0]),v.length>1&&""===v[v.length-1]&&(c.height=c.height+s),d=this.diagram.scroller.transform,u=T3(this.diagram)?d.scale:1,l=(12>c.height?12:c.height)*u,p.style.left=(o.bounds.center.x+d.tx)*d.scale-(h=(90>(h=c.width)?90:h)*u)/2-2.5+"px",p.style.top=(o.bounds.center.y+d.ty)*d.scale-l/2-3+"px",p.style.width=h+"px",p.style.height=l+"px",f.style.minHeight="12px",f.style.minWidth="90px",f.style.width=h+"px",f.style.height=l+"px")},n.prototype.isAddTextNode=function(t,e){return!(!(this.tool instanceof GI||e)||(this.tool=null,t&&!HI(this.diagram)&&(this.diagram.drawingObject=void 0,this.diagram.currentDrawingObject=void 0),vF(this.diagram.nodes,t.id)||vF(this.diagram.connectors,t.id)))},n.prototype.checkEditBoxAsTarget=function(t){return!(!t.target||t.target.id!==this.diagram.element.id+"_editBox")},n.prototype.getMouseEventArgs=function(t,e,i,r){var s,o,a;if(e.position=t,i?(o=this.diagram.findObjectsUnderMouse(this.currentPosition,i),s=this.diagram.findTargetObjectUnderMouse(o,this.action,this.inAction,e.position,i)):"Drag"===this.action||"ConnectorSourceEnd"===this.action||"SegmentEnd"===this.action||"OrthoThumb"===this.action||"BezierSourceThumb"===this.action||"BezierTargetThumb"===this.action||"ConnectorTargetEnd"===this.action||-1!==this.action.indexOf("Rotate")||-1!==this.action.indexOf("Resize")?(s=this.diagram.selectedItems,!this.diagram.currentSymbol&&"Drag"===this.action&&s&&this.diagram.selectedItems.nodes.length>0&&"SwimLane"===this.diagram.selectedItems.nodes[0].shape.type&&(o=this.diagram.findObjectsUnderMouse(this.currentPosition),s=this.diagram.findObjectUnderMouse(o,this.action,this.inAction))):(o=this.diagram.findObjectsUnderMouse(this.currentPosition),s=this.diagram.findObjectUnderMouse(o,this.action,this.inAction)),s&&s.isHeader&&(this.eventArgs.actualObject=s=this.diagram.nameTable[s.parentId]),s){var l=void 0,h=void 0,c=void 0;if(((a=this.diagram.findElementUnderMouse(s,this.currentPosition,this.diagram,r))&&s.ports&&s.ports.length&&!sb(s,a)||!a||!s)&&o&&o.length&&i instanceof ei)for(l=i.connectors[0],c=o.length-1;c>=0;c--)if(((h=o[parseInt(c.toString(),10)])instanceof te||h instanceof de)&&l&&l.connectionPadding){if(a=this.diagram.findElementUnderMouse(s=h,this.currentPosition,this.diagram,r),l.constraints&qe.ConnectToNearByPort&&s&&s.ports&&s.ports.length&&sb(s,a))break;if((h instanceof te||h instanceof de)&&l&&l.connectionPadding&&h.wrapper.outerBounds.containsPoint(this.currentPosition)&&l.constraints&qe.ConnectToNearByNode&&!(l.constraints&qe.ConnectToNearByPort)){a=this.diagram.findElementUnderMouse(s=h,this.currentPosition,this.diagram,0);break}}}return i?(e.target=s,e.targetWrapper=a):(e.source=s,e.sourceWrapper=a),e.actualObject=this.eventArgs.actualObject,e.source instanceof ei&&void 0===e.actualObject&&(e.source.nodes.length>0||e.source.connectors.length>0)&&(e.actualObject=e.source.nodes.length>0?this.diagram.nameTable[e.source.nodes[0].id]:this.diagram.nameTable[e.source.connectors[0].id]),e.startTouches=this.touchStartList,e.moveTouches=this.touchMoveList,e},n.prototype.resetTool=function(){this.action="Select",this.hoverElement=null,this.hoverNode=null,this.tool=this.diagram.getTool(this.action),this.updateCursor()},n.prototype.updateTool=function(){this.action=this.currentPosition&&"Pan"!==this.action?"Pan":"Select"},n.prototype.getTool=function(t){switch(t){case"Select":return new Jv(this.commandHandler,!0);case"Drag":return new fa(this.commandHandler);case"Rotate":return new Qx(this.commandHandler);case"LayoutAnimation":return new One(this.commandHandler);case"FixedUserHandle":return new Nne(this.commandHandler,!0);case"Hyperlink":return new X3(this.commandHandler);case"ResizeSouthEast":case"ResizeSouthWest":case"ResizeNorthEast":case"ResizeNorthWest":case"ResizeSouth":case"ResizeNorth":case"ResizeWest":case"ResizeEast":return new Pd(this.commandHandler,t);case"ConnectorSourceEnd":case"ConnectorTargetEnd":case"BezierSourceThumb":case"BezierTargetThumb":return new kd(this.commandHandler,t);case"SegmentEnd":case"OrthoThumb":return new ZF(this.commandHandler,t);case"Draw":var e="shape",i=function ose(n){var t;return n&&(n.type?t="Connector":n.shape&&!n.type&&(t="Node")),t}(this.diagram.drawingObject);if("Node"===i&&"Text"===this.diagram.drawingObject.shape.type)return new GI(this.commandHandler);if("Connector"===i&&"Freehand"===this.diagram.drawingObject.type)return new Rne(this.commandHandler);if("Node"===i&&"Polygon"===this.diagram.drawingObject.shape[""+e]&&!this.diagram.drawingObject.shape.points)return new zl(this.commandHandler);if("Node"===i||"Node"===i&&"Polygon"===this.diagram.drawingObject.shape[""+e]&&this.diagram.drawingObject.shape.points)return new QI(this.commandHandler,this.diagram.drawingObject);if("Connector"===i&&"Polyline"===this.diagram.drawingObject.type)return new Rl(this.commandHandler);if("Connector"===i)return new pa(this.commandHandler,"ConnectorSourceEnd",this.diagram.drawingObject);break;case"Pan":return new Kv(this.commandHandler,!1);case"PinchZoom":return new Kv(this.commandHandler,!0);case"PortDrag":return new fa(this.commandHandler,"Port");case"PortDraw":return new pa(this.commandHandler,"ConnectorSourceEnd",this.diagram.drawingObject);case"LabelSelect":return new Jv(this.commandHandler,!0,"LabelSelect");case"LabelDrag":return new kne(this.commandHandler);case"LabelResizeSouthEast":case"LabelResizeSouthWest":case"LabelResizeNorthEast":case"LabelResizeNorthWest":case"LabelResizeSouth":case"LabelResizeNorth":case"LabelResizeWest":case"LabelResizeEast":return new Pne(this.commandHandler,t);case"LabelRotate":return new zne(this.commandHandler)}return null},n.prototype.getCursor=function(t){var e=this.diagram.selectedItems.annotation?this.diagram.selectedItems.wrapper.children[0]:this.diagram.selectedItems;return function Lne(n,t){if(t+=360,t%=360,-1===n.indexOf("Resize"))return Yx[""+n];var e=Yx[""+n];return t>=0&&t<25||t>=160&&t<=205||t>=340&&t<=360?e:t>=25&&t<=70||t>=205&&t<=250?"n-resize"===e||"s-resize"===e?"ne-resize":"nw-resize"===e||"se-resize"===e?"n-resize":"e-resize"===e||"w-resize"===e?"nw-resize":"e-resize":t>=70&&t<=115||t>=250&&t<=295?"n-resize"===e||"s-resize"===e?"e-resize":"nw-resize"===e||"se-resize"===e?"ne-resize":"e-resize"===e||"w-resize"===e?"n-resize":"nw-resize":t>=115&&t<=155||t>=295&&t<=340?"n-resize"===e||"s-resize"===e?"nw-resize":"nw-resize"===e||"se-resize"===e?"e-resize":"e-resize"===e||"w-resize"===e?"ne-resize":Yx[""+n]:"n-resize"}(t,this.diagram.selectedItems.annotation?e.rotateAngle+e.parentTransform:e.rotateAngle)},n.prototype.findElementUnderMouse=function(t,e,i,r){return this.objectFinder.findElementUnderSelectedItem(t,e,i,r)},n.prototype.findObjectsUnderMouse=function(t,e){return this.objectFinder.findObjectsUnderMouse(t,this.diagram,this.eventArgs,e)},n.prototype.findObjectUnderMouse=function(t,e,i){return this.objectFinder.findObjectUnderMouse(this.diagram,t,e,i,this.eventArgs,this.currentPosition)},n.prototype.findTargetUnderMouse=function(t,e,i,r,s){return this.objectFinder.findObjectUnderMouse(this.diagram,t,e,i,this.eventArgs,r,s)},n.prototype.findActionToBeDone=function(t,e,i,r){return function Cne(n,t,e,i,r,s,o){if(s&&s.length>1&&r&&r.length>1)return"PinchZoom";if(i.currentSymbol)return"Drag";if("PortDraw"===i.eventHandler.action&&(i.tool&=~ni.DrawOnce),(x3(i)||HI(i))&&i.drawingObject)return"Draw";if($a(i)&&(l=i.selectedItems).wrapper&&qr(l.constraints,"UserHandle"))for(var h=0,c=l.userHandles;h=50&&(l.x=(a.points[parseInt(h.toString(),10)].x+a.points[h+1].x)/2,l.y=(a.points[parseInt(h.toString(),10)].y+a.points[h+1].y)/2,wr(e,l,n.hitPadding?n.hitPadding:10)))return"OrthoThumb"}else kI(n)&&console.warn('[WARNING] :: Module "ConnectorEditing" is not available in Diagram component! You either misspelled the module name or forgot to load it.');return null}(g,l,e,i);if("OrthoThumb"===S)return S;if(qr(l.constraints,"ConnectorSourceThumb")&&NI(g)&&S||qr(l.constraints,"ConnectorTargetThumb")&&OI(g)&&S)return S}}else{var b=i.selectedItems.handleSize/2/i.scroller.currentZoom,M=10/i.scroller.currentZoom,w=Bi();qi(w,f.rotateAngle+f.parentTransform,f.offsetX,f.offsetY);var C=f.offsetX-f.pivot.x*f.actualSize.width,D=f.offsetY-f.pivot.y*f.actualSize.height,A={x:C+(.5===f.pivot.x?2*f.pivot.x:f.pivot.x)*f.actualSize.width/2,y:D-30/i.scroller.currentZoom};A=Ke(w,A);var x=!!i.selectedItems.annotation,P=!(!x||!PI(i.selectedItems.annotation));if(qr(l.constraints,"Rotate")&&wr(e,A,M)&&i.selectedItems.thumbsConstraints&bt.Rotate){if(x&&P)return"LabelRotate";if(!x)return"Rotate"}if(u.Inflate(b),u.containsPoint(e)&&(S=function Ene(n,t,e,i,r,s){var o;return 1===n.selectedItems.nodes.length&&0===n.selectedItems.connectors.length&&n.selectedItems.nodes[0].container&&(o=function Tne(n,t,e,i,r){var s=10/n.scroller.currentZoom,o=n.selectedItems,a=t.actualSize.width,l=t.actualSize.height,h=new Ne(i,r,t.style.strokeWidth,l),c=new Ne(i+a,r,t.style.strokeWidth,l),d=new Ne(i,r,a,t.style.strokeWidth),u=new Ne(i,r+l,a,t.style.strokeWidth),f=Dn(n,n.selectedItems.nodes[0],!0)?n.nameTable[n.selectedItems.nodes[0].parentId]:n.selectedItems.nodes[0];if(ga(o.constraints,"ResizeEast",o.thumbsConstraints,o)&&c.containsPoint(e,s))return"ResizeEast";if(ga(o.constraints,"ResizeSouth",o.thumbsConstraints,o)&&u.containsPoint(e,s))return"ResizeSouth";if("Grid"!==f.container.type){if(ga(o.constraints,"ResizeWest",o.thumbsConstraints,o)&&h.containsPoint(e,s))return"ResizeWest";if(ga(o.constraints,"ResizeNorth",o.thumbsConstraints,o)&&d.containsPoint(e,s))return"ResizeNorth"}return null}(n,t,e,r,s)),!o&&(!n.selectedItems.nodes[0]||!n.selectedItems.nodes[0].isPhase&&!n.selectedItems.nodes[0].isLane&&"SwimLane"!==n.selectedItems.nodes[0].shape.type)&&(o=function Ane(n,t,e,i,r,s){var o=40/n.scroller.currentZoom,a=n.selectedItems.handleSize/2/n.scroller.currentZoom,l=n.selectedItems,h=!!l.annotation;if(t.actualSize.width>=o&&t.actualSize.height>=o){if(ga(l.constraints,"ResizeSouthEast",l.thumbsConstraints,l)&&wr(e,Ke(i,{x:r+t.actualSize.width,y:s+t.actualSize.height}),a))return h?"LabelResizeSouthEast":"ResizeSouthEast";if(ga(l.constraints,"ResizeSouthWest",l.thumbsConstraints,l)&&wr(e,Ke(i,{x:r,y:s+t.actualSize.height}),a))return h?"LabelResizeSouthWest":"ResizeSouthWest";if(ga(l.constraints,"ResizeNorthEast",l.thumbsConstraints,l)&&wr(e,Ke(i,{x:r+t.actualSize.width,y:s}),a))return h?"LabelResizeNorthEast":"ResizeNorthEast";if(ga(l.constraints,"ResizeNorthWest",l.thumbsConstraints,l)&&wr(e,Ke(i,{x:r,y:s}),a))return h?"LabelResizeNorthWest":"ResizeNorthWest"}return ga(l.constraints,"ResizeEast",l.thumbsConstraints,l)&&wr(e,Ke(i,{x:r+t.actualSize.width,y:s+t.actualSize.height/2}),a)?h?"LabelResizeEast":"ResizeEast":ga(l.constraints,"ResizeWest",l.thumbsConstraints,l)&&wr(e,Ke(i,{x:r,y:s+t.actualSize.height/2}),a)?h?"LabelResizeWest":"ResizeWest":ga(l.constraints,"ResizeSouth",l.thumbsConstraints,l)&&wr(e,Ke(i,{x:r+t.actualSize.width/2,y:s+t.actualSize.height}),a)?h?"LabelResizeSouth":"ResizeSouth":ga(l.constraints,"ResizeNorth",l.thumbsConstraints,l)&&wr(e,Ke(i,{x:r+t.actualSize.width/2,y:s}),a)?h?"LabelResizeNorth":"ResizeNorth":null}(n,t,e,i,r,s)),o||null}(i,f,e,w,C,D),S))return S}}if(Lc(i)&&!n)return"Pan";if((o instanceof Es||o instanceof Tc)&&(!Lc(i)||_v(i)||Uv(i))&&(S=function xne(n,t,e,i){if(Bx(t)&&(va(t,ri.Hover)||va(t,ri.Visible))){if(t.constraints&ai.Drag)return"PortDrag"}else if(Hx(t)&&(va(t,ri.Hover)||va(t,ri.Visible))&&t.constraints&ai.Draw){n.drawingObject={};var r={type:"Orthogonal",sourcePortID:t.id};return n.drawingObject=r,n.tool|=ni.DrawOnce,n.currentDrawingObject=r,"PortDraw"}return"None"}(i,o),"None"!==S))return S;if((o instanceof Kn||o instanceof Or)&&!Lc(i)&&xd(o))return _r(i,o,void 0,t)&&ro(o)?"LabelDrag":"LabelSelect";if(null!==n){if(!(n instanceof te||n instanceof de))return"Select";if(t&&t.id){var L=t.id.split(n.id)[1];if(L&&L.match("^_icon"))return"LayoutAnimation"}if(t&&t.id)for(var O=void 0,N=0;N-1)return"FixedUserHandle";if(t instanceof li&&t.hyperlink.link)return"Hyperlink";if(!ro(n)||!_r(i,n,!1)||void 0!==i.selectedItems.annotation)return n&&Lc(i)&&!BI(i)?"Pan":i.selectedItems.nodes.length&&i.selectedItems.nodes[0].isLane&&i.selectedItems.wrapper&&i.selectedItems.wrapper.bounds.containsPoint(e)?"Drag":"Select";if(n instanceof de&&!wr(e,n.sourcePoint,n.hitPadding)&&!wr(e,n.targetPoint,n.hitPadding)||!(n instanceof de))return"Drag"}return"Select"}(t,e,this.currentPosition,this.diagram,this.touchStartList,this.touchMoveList,r)},n.prototype.updateContainerBounds=function(t){var e=!1;if(this.diagram.selectedObject.helperObject&&this.diagram.selectedObject.actualObject)for(var i=this.diagram.selectedObject.actualObject,r=this.diagram.selectedObject.actualObject instanceof ei?i.nodes:[i],s=0;si.y&&(h+=u>0?-1:1,u+=u>0?-1:1):i&&e.wrapper.offsetYi.x&&(h+=u>0?-1:1,u+=u>0?-1:1):i&&e.wrapper.offsetX1)for(var S=t.offsetX-this.diagram.selectedItems.offsetX,b=t.offsetY-this.diagram.selectedItems.offsetY,M=t.rotateAngle-this.diagram.selectedItems.rotateAngle,w=0;w-1){var A=c.children;A.splice(A.indexOf(o.id),1),this.diagram.nameTable[o.id].parentId="",i=!0,c.wrapper.children.splice(D,1)}}if(function wne(n,t,e,i){var r=n,s=e.nameTable[r.parentId],o=e.nameTable[r.parentId];if(t&&o&&o.container&&"Stack"===o.container.type&&t.container&&"Stack"===t.container.type&&o.id!==t.parentId){var a=o.wrapper.children.indexOf(r.wrapper);a>-1&&(e.nameTable[r.id].parentId=t.id,o.wrapper.children.splice(a,1))}if(t&&t.parentId&&r.parentId&&"Drag"===i&&o.container&&"Stack"===o.container.type){var l=s.wrapper.children.indexOf(t.wrapper),h=s.wrapper.children.indexOf(r.wrapper),c={targetIndex:l,target:t,sourceIndex:h,source:n};s.wrapper.children.splice(h,1),s.wrapper.children.splice(l,0,r.wrapper),e.commandHandler.addHistoryEntry({type:"StackChildPositionChanged",redoObject:{targetIndex:h,target:t,sourceIndex:l,source:n},undoObject:c,category:"Internal"})}}(o,h,this.diagram,this.action),(c=Dn(this.diagram,o)?this.diagram.nameTable[o.parentId]:this.diagram.nameTable[o.parentId]||o)&&c.container&&"Canvas"===c.container.type&&(c.wrapper.maxWidth=c.maxWidth=c.wrapper.actualSize.width,c.wrapper.maxHeight=c.maxHeight=c.wrapper.actualSize.height,e=!0),Dn(this.diagram,o,!0)&&c&&"Canvas"===c.container.type)if(this.diagram.selectedItems.nodes.length>1)for(w=0;w0)for(var i=0;i0&&e.columnIndex>0||l&&e.isLane)){if("Horizontal"===t.container.orientation&&e.isPhase&&e.wrapper.width>e.maxWidth&&(e.maxWidth=e.wrapper.width,e.wrapper.maxWidth=e.wrapper.width),h.updateColumnWidth(e.columnIndex,r.width,!0,c),Ux(this.diagram,e,t),e.isPhase){var p=this.diagram.nameTable[""+t.shape.phases[e.columnIndex].header.id];p.maxWidth0?(r=new sp(t,"",u),t.shape.classShape.attributes.push(r)):i.id.includes("_umlMethods")&&t.shape.classShape.methods.length>0&&(s=new cm(t,"",u),t.shape.classShape.methods.push(s))),"Interface"===t.shape.classifier&&(i.id.includes("_umlProperty")&&t.shape.interfaceShape.attributes.length>0?(r=new sp(t,"",u),t.shape.classShape.attributes.push(r)):i.id.includes("_umlMethods")&&t.shape.interfaceShape.methods.length>0&&(s=new cm(t,"",u),t.shape.interfaceShape.methods.push(s))),"Enumeration"===t.shape.classifier&&i.id.includes("_umlMember")&&t.shape.enumerationShape.members.length>0){var f=new lb(t,"",u);t.shape.enumerationShape.members.push(f)}t.wrapper.children.indexOf(c.wrapper),this.diagram.enableServerDataBinding(!0),this.diagram.add(c),this.diagram.updateConnectorEdges(t),this.diagram.clearSelection(),this.diagram.select([this.diagram.nameTable[c.id]]),this.diagram.endGroupAction(),this.diagram.startTextEdit()}}},n}(),joe=function(){function n(){}return n.prototype.findObjectsUnderMouse=function(t,e,i,r,s){var o=[];r&&r instanceof ei&&r.nodes.length+r.connectors.length===1&&(r=r.nodes[0]||r.connectors[0]).children&&0===r.children.length&&(i.actualObject=r);for(var a,l,h,c,p,d=r&&r instanceof de&&(r.constraints&qe.ConnectToNearByNode||r.constraints&qe.ConnectToNearByPort)&&r.connectionPadding||0,f={},g=0,v=e.spatialSearch.findObjects(new Ne(t.x-50-d,t.y-50-d,100+d,100+d));g-1&&o.splice(T,1),"UmlClassifier"===y.shape.type&&y.container&&"Stack"===y.container.type&&(T=o.indexOf(e.nameTable[e.nameTable[y.id].wrapper.children[0].id]))>-1&&o.splice(T,1)}for(var z=0;zs.zIndex&&(t[parseInt(r.toString(),10)]=l),r>0&&i&&a&&(a.isLane||a.isPhase||a.isHeader)&&t[parseInt(r.toString(),10)].zIndex=2)for(var d=t.length-1;d>=0;d--)if(t[parseInt(d.toString(),10)].parentId){var u=om(t[parseInt(d.toString(),10)],e,""),f=om(t[d-1],e,""),g=e.nameTable[""+f];g&&u!==f&&e.nameTable[""+u].zIndex=0;p--){d=tp(e[parseInt(p.toString(),10)],!1),c=tp(e[parseInt(p.toString(),10)],!0);var g=t[""+l].tool,v=this.findTargetElement(e[parseInt(p.toString(),10)].wrapper,o,t,void 0);if("Draw"===i&&v&&(e[parseInt(p.toString(),10)]instanceof te||e[parseInt(p.toString(),10)]instanceof de)&&!sb(e[parseInt(p.toString(),10)],v)&&(g&&"ConnectorSourceEnd"===g[""+h]&&!Ph(e[parseInt(p.toString(),10)])||g&&"ConnectorTargetEnd"===g[""+h]&&!ua(e[parseInt(p.toString(),10)])))return u;if(e[parseInt(p.toString(),10)]instanceof te||e[parseInt(p.toString(),10)]instanceof de&&(Ph(e[parseInt(p.toString(),10)])||Td(d)||ua(e[parseInt(p.toString(),10)])||kh(c)||"PortDraw"===i&&g instanceof kd&&"ConnectorTargetEnd"===g[""+h]&&(ua(e[parseInt(p.toString(),10)])||kh(c))))return u=e[parseInt(p.toString(),10)],f&&(u=this.isTarget(u,t,i)),s.actualObject=u,u}else if("ConnectorTargetEnd"===i&&a){for(p=e.length-1;p>=0;p--)if(c=tp(e[parseInt(p.toString(),10)],!0),(e[parseInt(p.toString(),10)]instanceof te||e[parseInt(p.toString(),10)]instanceof de)&&(ua(e[parseInt(p.toString(),10)])||kh(c)))return u=e[parseInt(p.toString(),10)],u=this.isTarget(u,t,i),s.actualObject=u,u}else{if(a&&("Drag"===i||t[""+l].tool instanceof fa)){var y=0;for(p=0;p=S.zIndex?u:S,y=Math.max(y,S.zIndex)):y=(u=S).zIndex)}return u&&"Bpmn"===u.shape.type&&(t.selectedItems.nodes.length>0&&"Bpmn"===t.selectedItems.nodes[0].shape.type||(u=null)),u&&(s.actualObject=u),u}if("Select"!==i&&"Pan"!==i||!t[""+l].tool)if("Pan"===i||"LayoutAnimation"===i){for(p=e.length-1;p>=0;p--)if((e[parseInt(p.toString(),10)]instanceof te||e[parseInt(p.toString(),10)]instanceof de)&&(v=this.findTargetElement(e[parseInt(p.toString(),10)].wrapper,o,t,void 0),"Pan"===i||v&&(v.id.match("_icon_content_shape$")||v.id.match("_icon_content_rect$"))))return e[parseInt(p.toString(),10)]}else u=e[e.length-1],s&&u&&(s.actualObject=u);else{for(p=e.length-1;p>=0;p--)if(e[parseInt(p.toString(),10)]instanceof de){var b=e[p-1];if(e[p-1]instanceof te&&b.ports){if((v=this.findTargetElement(b.wrapper,o,t,void 0))&&(v.id.match("_icon_content_shape$")||v.id.match("_icon_content_rect$")))return b;for(var M=0;M=0;s--){var o=t.children[parseInt(s.toString(),10)];if(o&&o.outerBounds.containsPoint(e,r||0))if(o.visible){if(o instanceof Cs){var a=this.findTargetElement(o,e,i);if(a)return a}var l="Clip"===o.style.textOverflow||"Ellipsis"===o.style.textOverflow;if(o.bounds.containsPoint(e,r||0)&&!l)return o;if(t.bounds.containsPoint(e,r||0)&&l)return o}else if(o instanceof Ze&&t&&t.id){var h=void 0;if(t.id.includes("group_container")){var c=t.id.slice(0,-15);h=i.getObject(c)}else h=i.getObject(t.id);if(rb(h,o.id))return o}}return t.bounds.containsPoint(e,r)&&"none"!==t.style.fill?t:null},n}(),Voe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),ap=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},JF=function(n){function t(e,i,r,s){var o=n.call(this,e,i,r,s)||this;return o.objectZIndex=-1,o.zIndexTable={},o.objects=[],o}return Voe(t,n),ap([I("")],t.prototype,"id",void 0),ap([I(!0)],t.prototype,"visible",void 0),ap([I(!1)],t.prototype,"lock",void 0),ap([I()],t.prototype,"objects",void 0),ap([I()],t.prototype,"addInfo",void 0),ap([I(-1)],t.prototype,"zIndex",void 0),t}(Ee),wT=function(n,t,e,i){return new(e||(e=Promise))(function(r,s){function o(h){try{l(i.next(h))}catch(c){s(c)}}function a(h){try{l(i.throw(h))}catch(c){s(c)}}function l(h){h.done?r(h.value):new e(function(c){c(h.value)}).then(o,a)}l((i=i.apply(n,t||[])).next())})},CT=function(n,t){var i,r,s,o,e={label:0,sent:function(){if(1&s[0])throw s[1];return s[1]},trys:[],ops:[]};return o={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function a(h){return function(c){return function l(h){if(i)throw new TypeError("Generator is already executing.");for(;e;)try{if(i=1,r&&(s=2&h[0]?r.return:h[0]?r.throw||((s=r.return)&&s.call(r),0):r.next)&&!(s=s.call(r,h[1])).done)return s;switch(r=0,s&&(h=[2&h[0],s.value]),h[0]){case 0:case 1:s=h;break;case 4:return e.label++,{value:h[1],done:!1};case 5:e.label++,r=h[1],h=[0];continue;case 7:h=e.ops.pop(),e.trys.pop();continue;default:if(!(s=(s=e.trys).length>0&&s[s.length-1])&&(6===h[0]||2===h[0])){e=0;continue}if(3===h[0]&&(!s||h[1]>s[0]&&h[1]1)for(var i=0;i-1)return e[parseInt(i.toString(),10)];return this.diagram.activeLayer},n.prototype.getLayer=function(t){for(var e=this.diagram.layers,i=0;i=0;o--)this.diagram.unSelect(this.diagram.nameTable[s[parseInt(o.toString(),10)]]),this.diagram.remove(this.diagram.nameTable[s[parseInt(o.toString(),10)]]),"default_layer"!==i.id&&this.diagram.activeLayer.id===t&&(this.diagram.activeLayer=this.diagram.layers[this.diagram.layers.length-1]);delete this.diagram.layerZIndexTable[i.zIndex],this.diagram.layers.splice(r,1),"SVG"!==this.diagram.mode&&this.diagram.refreshDiagramLayer()}},n.prototype.moveObjects=function(t,e){this.diagram.startGroupAction();for(var i={},r=[],s=0;s-1){if(r=[],(h=this.diagram.nameTable[""+s]).children)for(var p=0,g=h.children;p0){for(var y=void 0,S=0,b=r;S0)for(var r=0;r0)for(r=0;r0){t=t.concat(this.diagram.selectedItems.connectors);for(var i=0;i0)for(t=t.concat(this.diagram.selectedItems.nodes),i=0;i0){for(var i=0,r=t.shape.activity.subProcess.processes;i0&&this.copyProcesses(this.processTable[""+s])}this.clipboardData.processTable=this.processTable}},n.prototype.group=function(){this.oldSelectedObjects=nm(this.diagram);var e=this.diagram.isProtectedOnChange;this.diagram.protectPropertyChange(!0),this.diagram.diagramActions=this.diagram.diagramActions|ee.Group;var r={};r.id="group"+Qe(),(r=new te(this.diagram,"nodes",r,!0)).children=[];for(var s=this.diagram.selectedItems.nodes.concat(this.diagram.selectedItems.connectors).sort(function(h,c){return h.zIndex-c.zIndex}),o=0;o0){var a=this.diagram.add(r);a&&this.select(a),this.addHistoryEntry({type:"Group",undoObject:r,redoObject:r,category:"Internal"}),this.diagram.diagramActions=this.diagram.diagramActions&~ee.Group,this.diagram.protectPropertyChange(e)}},n.prototype.unGroup=function(t){var i=this.diagram.isProtectedOnChange;this.diagram.protectPropertyChange(!0),this.diagram.diagramActions=this.diagram.diagramActions|ee.Group;var r=[];t?r.push(t):r=this.diagram.selectedItems.nodes,this.diagram.startGroupAction();for(var s=0;s0&&this.diagram.removePorts(o,o.ports),o.annotations&&o.annotations.length>0&&!ce()&&this.diagram.removeLabels(o,o.annotations);for(var c=this.diagram.nameTable[o.parentId],d=o.children.length-1;d>=0;d--)this.diagram.nameTable[o.children[parseInt(d.toString(),10)]].parentId="",this.diagram.deleteChild(this.diagram.nameTable[o.children[parseInt(d.toString(),10)]],o),o.parentId&&o.children[parseInt(d.toString(),10)]&&this.diagram.addChild(c,o.children[parseInt(d.toString(),10)]);this.resetDependentConnectors(o.inEdges,!0),this.resetDependentConnectors(o.outEdges,!1),this.diagram.diagramActions&ee.UndoRedo||this.addHistoryEntry({type:"UnGroup",undoObject:a,redoObject:a,category:"Internal"}),o.parentId&&this.diagram.deleteChild(o,c)}this.diagram.removeNode(o,l),this.clearSelection()}this.diagram.endGroupAction(),this.diagram.diagramActions=this.diagram.diagramActions&~ee.Group,this.diagram.protectPropertyChange(i)},n.prototype.resetDependentConnectors=function(t,e){for(var i=0;i0&&(g=!1)}if(g){var y=this.cloneConnector(f,i);c.push(y),o[h.id]=y.id}}else{var S=this.cloneNode(h,i);if(c.push(S),S){o[h.id]=S.id;var b=h.inEdges;if(b)for(var M=0,w=b;M0)for(var u=0;u0)for(r=t.segments,s=0;s0&&this.diagram.drawingObject&&"Bezier"===this.diagram.drawingObject.type&&(t.segments=[]);var e=this.diagram.add(t);"SVG"!==this.diagram.mode&&this.diagram.refreshDiagramLayer(),this.selectObjects([e]),t&&!HI(this.diagram)&&(this.diagram.tool&=~ni.DrawOnce,this.diagram.currentDrawingObject=void 0)},n.prototype.enableServerDataBinding=function(t){this.diagram.enableServerDataBinding(t)},n.prototype.addText=function(t,e){var i=this.diagram.findElementUnderMouse(t,e,this.diagram);this.diagram.startTextEdit(t,i instanceof li?i.id.split("_")[1]:void 0)},n.prototype.isUserHandle=function(t){var e=this.diagram.selectedItems;if(e.wrapper&&qr(e.constraints,"UserHandle"))for(var i=0,r=e.userHandles;i0&&t[0]&&t[0].isLane)for(s=this.diagram.getObject(t[0].parentId),t[0].shape.header=[],a=0;a1||e&&1===t.length)){if(1!==t.length)return[2];this.clearSelection()}if(!(u||d||1!==t.length||e&&$a(this.diagram)))return this.clearSelection(),[2]}if(!r.cancel){for(f=0;f0||e)&&p.children&&!p.parentId)for(g=0;g0||e,!0)}else this.select(p,f>0||e,!0);void 0===i&&(i=c),r={oldValue:i||[],newValue:this.getSelectedObject(),cause:this.diagram.diagramActions,state:"Changed",type:"Addition",cancel:!1},this.diagram.renderSelector(e||t&&t.length>1),ce()||this.diagram.triggerEvent(Ce.selectionChange,r),this.diagram.enableServerDataBinding(!0)}return[2]})})},n.prototype.findParent=function(t){return t.parentId&&this.findParent(t=this.diagram.nameTable[t.parentId]),t},n.prototype.selectProcesses=function(t){if(this.hasProcesses(t))for(var e=t.shape.activity.subProcess.processes,i=0;i0)},n.prototype.select=function(t,e,i){var r=this.getObjectLayer(t.id);if(xd(t)&&!(t instanceof ei)&&!_r(this.diagram,t)&&r&&!r.lock&&r.visible&&t.wrapper.visible){(e=!!$a(this.diagram)&&e)||this.clearSelection(),this.diagram.enableServerDataBinding(!1);var s=this.diagram.selectedItems;if(t instanceof te?s.nodes.push(t.isHeader?this.diagram.nameTable[t.parentId]:t):s.connectors.push(t),s.selectedObjects.push(t),e)s.wrapper.rotateAngle=s.rotateAngle=0,s.wrapper.children.push(t.wrapper);else if(s.init(this.diagram),1===s.nodes.length&&0===s.connectors.length){var l=jx(this.diagram,s);l&&(s.wrapper.children[0]=l),s.rotateAngle=s.nodes[0].rotateAngle,s.wrapper.rotateAngle=s.nodes[0].rotateAngle,s.wrapper.pivot=s.nodes[0].pivot}i||this.diagram.renderSelector(e),this.diagram.enableServerDataBinding(!0)}},n.prototype.labelSelect=function(t,e){this.oldSelectedObjects=nm(this.diagram);var i=this.diagram.selectedItems,r=this.diagram.allowServerDataBinding;this.diagram.allowServerDataBinding=!1,i.nodes=i.connectors=[],this.diagram.allowServerDataBinding=r,t instanceof te?i.nodes[0]=t:i.connectors[0]=t,i.annotation=this.findTarget(e,t),i.init(this.diagram),this.diagram.renderSelector(!1)},n.prototype.unSelect=function(t){var e=this.diagram.selectedItems.nodes.concat(this.diagram.selectedItems.connectors),i=e.filter(function(a){return a.id!==t.id}),r={oldValue:e,newValue:i,cause:this.diagram.diagramActions,state:"Changing",type:"Removal",cancel:!1};if(this.diagram.currentSymbol||ce()||this.diagram.triggerEvent(Ce.selectionChange,r),_r(this.diagram,t)){var s=this.diagram.selectedItems,o=void 0;t instanceof te?(o=s.nodes.indexOf(t,0),s.nodes.splice(o,1)):(o=s.connectors.indexOf(t,0),s.connectors.splice(o,1)),o=s.selectedObjects.indexOf(t,0),s.selectedObjects.splice(o,1),(r={oldValue:e,newValue:i,cause:this.diagram.diagramActions,state:"Changed",type:"Removal",cancel:(r={oldValue:e,newValue:i,cause:this.diagram.diagramActions,state:"Changed",type:"Removal",cancel:!1}).cancel}).cancel||(o=s.wrapper.children.indexOf(t.wrapper,0),s.wrapper.children.splice(o,1),this.diagram.updateSelector(),this.diagram.currentSymbol||this.diagram.triggerEvent(Ce.selectionChange,r))}},n.prototype.moveSvgNode=function(t,e){var i=this.diagram.nameTable[""+e];if("Native"===i.shape.type||"HTML"===i.shape.type)this.updateNativeNodeIndex(t,e);else{var r=xt(e+"_groupElement",this.diagram.element.id),s=xt(t+"_groupElement",this.diagram.element.id);r.parentNode.insertBefore(s,r)}},n.prototype.moveAfterSvgNode=function(t,e){var i=this.diagram.nameTable[""+e];if(!i||"HTML"!==i.shape.type&&"Native"!==i.shape.type)a=xt(e+"_groupElement",this.diagram.element.id),o=xt(t+"_groupElement",this.diagram.element.id),a.insertAdjacentElement("afterend",o);else for(var r=0;rd&&"SwimLane"!==p.shape.type){var S=$(p);p.zIndex=d-((-1!==i.indexOf(p)?i.indexOf(p):0)+1),p.children&&(d=this.findLowestZIndex(p,c)||d),this.triggerOrderCommand(S,p,p),p.children&&this.updateGroupZindex(p,"SendToBack",d)}else"SwimLane"===p.shape.type&&(y=this.swapZIndexObjects(a,h,r,g));if("SVG"===this.diagram.mode){for(var M="SwimLane"!==this.diagram.nameTable[""+r].shape.type?d:y,w=h[parseInt(M.toString(),10)];!w&&Md)&&(d=f.zIndex)}for(var p=JSON.parse(JSON.stringify(l)),v=Number(Object.keys(l).sort(function(wo,Ul){return Number(wo)-Number(Ul)}).reverse()[0]),y=this.diagram.nameTable[""+e].zIndex,S=[],M=0;M<=v;M++)S.push(l[parseInt(M.toString(),10)]);if("SwimLane"===this.diagram.nameTable[""+e].shape.type)for(var C=v;C>=y;C--)if(l[parseInt(C.toString(),10)]&&this.diagram.nameTable[l[parseInt(C.toString(),10)]].parentId!==e){v=C;break}var D=this.diagram.nameTable[""+e];if(D.zIndexx&&(x=L.zIndex)}}else x=d;D.zIndex=x+((-1!==r.indexOf(D)?r.indexOf(D):0)+1),this.triggerOrderCommand(A,D,D)}else if("SwimLane"===D.shape.type){for(var O=0,N=-1,T=0,z=0,U=JSON.parse(JSON.stringify(l)),B=0;B<=y;B++)if(l[parseInt(B.toString(),10)]&&this.diagram.nameTable[l[parseInt(B.toString(),10)]].parentId===e&&-1===N){N=B,T=B;break}for(var j=0;j<=v;j++)p[parseInt(j.toString(),10)]&&p[parseInt(j.toString(),10)]!==e&&this.diagram.nameTable[p[parseInt(j.toString(),10)]].parentId!==e&&this.diagram.nameTable[p[parseInt(j.toString(),10)]].zIndex>=this.diagram.nameTable[""+e].zIndex&&O++;for(var ue=N,fe=0;fe<=O;fe++){for(;!l[parseInt(ue.toString(),10)];)ue++;z=this.diagram.nameTable[l[parseInt(ue.toString(),10)]].zIndex,ue++}for(var Me=z;Me<=v;Me++){for(;!U[parseInt(N.toString(),10)];)N++;for(;!l[parseInt(Me.toString(),10)];)Me++;l[parseInt(Me.toString(),10)]=U[parseInt(N.toString(),10)],this.diagram.nameTable[l[parseInt(Me.toString(),10)]].zIndex=Me,N++}l[parseInt(v.toString(),10)]=this.diagram.nameTable[""+e].id,this.diagram.nameTable[""+e].zIndex=v,ue=y+1;for(var De=T,xe=0;xe0&&("Native"===hr[0].shape.type||"HTML"===hr[0].shape.type)){for(Ci.parentNode.removeChild(Ci),De=0;De0?r[0]:null},n.prototype.findLowestZIndex=function(t,e){var r=this.diagram.nodes.filter(function(s){return-1!==e.indexOf(s.id)}).filter(function(s){return""===s.parentId&&s.id!==t.id}).map(function(s){return s.zIndex});return r.sort(function(s,o){return s-o}),r.length>0?r[0]:null},n.prototype.triggerOrderCommand=function(t,e,i){var s={zIndex:$(t).zIndex},o={zIndex:e.zIndex},a={element:i,cause:this.diagram.diagramActions,diagramAction:this.diagram.getDiagramAction(this.diagram.diagramActions),oldValue:s,newValue:o};this.diagram.triggerEvent(Ce.propertyChange,a)},n.prototype.checkGroupNode=function(t,e,i){return i[""+e].parentId===i[""+t].parentId},n.prototype.sortByZIndex=function(t,e,i){if("BringForward"===i){var r=e||"zIndex";t=t.sort(function(o,a){return a[""+r]-o[""+r]})}else{var s=e||"zIndex";t=t.sort(function(o,a){return o[""+s]-a[""+s]})}return t},n.prototype.orderCommands=function(t,e,i){var r=this,s=e.nodes;if(s=s.concat(e.connectors),t)if("SendBackward"===i)for(var o=0;oa}),S=v.filter(function(D){return D0?Math.max.apply(Math,S):a,M=y.length>0?Math.min.apply(Math,y):a;if(a!==M){var w=c.zIndexTable[parseInt(M.toString(),10)],C=c.zIndexTable[parseInt(a.toString(),10)];this.moveSvgNode(C,w)}else"SendToBack"===i&&(w=c.zIndexTable[parseInt(a.toString(),10)],C=c.zIndexTable[parseInt(b.toString(),10)],this.moveAfterSvgNode(w,C))}}else this.diagram.refreshCanvasLayers()}},n.prototype.swapDomOrder=function(t,e){if(t){var i=this.diagram.getObject(e);if("Native"===i.shape.type||"HTML"===i.shape.type)this.updateNativeNodeIndex(e,t),this.updateNativeNodeIndex(t,e);else{var r=xt(e+"_groupElement",this.diagram.element.id),s=xt(t+"_groupElement",this.diagram.element.id);r.parentNode.insertBefore(r,s),r.parentNode.insertBefore(s,r)}}},n.prototype.sendForward=function(t){var e=this;if(this.diagram.protectPropertyChange(!0),$a(this.diagram)||t){$(t||(this.diagram.selectedItems.nodes.length?this.diagram.selectedItems.nodes[0]:this.diagram.selectedItems.connectors[0]));var s=t&&t.id,o=this.diagram.layers.indexOf(this.getObjectLayer(s=s||(this.diagram.selectedItems.nodes.length?this.diagram.selectedItems.nodes[0].id:this.diagram.selectedItems.connectors[0].id))),a=$(this.diagram.nameTable),h=(parseInt(o.toString(),10),this.diagram.nameTable[""+s]),c=[],d=this.diagram.spatialSearch.findObjects(h.wrapper.bounds);d.length>2&&(d=this.sortByZIndex(d,void 0,"BringForward"));for(var u=0,f=d;u=0;p--)this.diagram.nameTable[c[parseInt(p.toString(),10)].id].parentId===s&&c.splice(p,1);if(c.length>0){var y=this.diagram.nameTable[c[c.length-1].id];if(y.parentId){var b=om(y,this.diagram,""),M=this.diagram.nameTable[""+b];M.id!==s&&(c[0]=M)}var w={};for(p=0;p0&&(Object.values(O).forEach(function(ue){ue>=T&&N.push(ue)}),0!==N.length&&this.updateZIndexBySendForward(h,N,o))}var z=[];if(Object.keys(this.changedNodeZIndexes).forEach(function(ue){if((a[""+ue]?a[""+ue].zIndex:null)!==e.changedNodeZIndexes[""+ue]){var De=$(a[""+ue]);z.push(De)}}),this.updateLayerZindexTable(o),L.nodes.splice(0,L.nodes.length),z.forEach(function(ue){var fe=$(ue);L.nodes.push(fe)}),"SVG"===this.diagram.mode){var U=c[c.length-1].id,B=c[c.length-1];B&&!("HTML"===B.shape.type||"Native"===B.shape.type)&&this.moveAfterSvgNode(s,U),this.updateNativeNodeIndex(U,s)}else this.diagram.refreshCanvasLayers();var j=[];Object.keys(this.changedNodeZIndexes).forEach(function(ue){if((a[""+ue]?a[""+ue].zIndex:null)!==e.changedNodeZIndexes[""+ue]){var De=$(e.diagram.nameTable[""+ue]);j.push(De)}});var Q=$(this.diagram.selectedItems);Q.nodes.splice(0,Q.nodes.length),j.forEach(function(ue){var fe=$(ue);Q.nodes.push(fe)}),this.diagram.diagramActions&ee.UndoRedo||this.addHistoryEntry({type:"SendForward",category:"Internal",undoObject:L,redoObject:Q}),this.diagram.endGroupAction()}}this.diagram.protectPropertyChange(!1)},n.prototype.updateZIndexBySendForward=function(t,e,i){var r=$(t);t.zIndex=Math.min.apply(Math,e);var a,s=Math.min.apply(Math,e),o=Math.min.apply(Math,e),l=this.diagram.layers[parseInt(i.toString(),10)].objects,h=this.diagram.nodes.filter(function(S){return-1!==l.indexOf(S.id)});t.children&&this.updateGroupZindex(t,"BringForward",t.zIndex);var c=h.filter(function(S){return S.zIndex===Math.min.apply(Math,e)&&S.id!==t.id});if(c&&c.length>0&&c[0].children){for(var d=Math.min.apply(Math,e),u=0;uo&&g!==t&&g.parentId!==t.id&&c&&c.length>0&&g.parentId!==c[0].id){var v=$(g);g.zIndex=a+1,a++,this.triggerOrderCommand(v,g,g)}var y=g.zIndex;this.changedNodeZIndexes[g.id]=(this.changedNodeZIndexes.hasOwnProperty(g.id),y)}},n.prototype.arrangeZIndexForLowerNodes=function(t,e,i){var r=i.filter(function(o){return o.zIndex<=t&&o.parentId!==e.id});r.sort(function(o,a){return a.zIndex-o.zIndex});for(var s=0;se&&(e=r.zIndex)}return e},n.prototype.sendBackward=function(t){var e=this;if(this.diagram.protectPropertyChange(!0),$a(this.diagram)||t){$(t||(this.diagram.selectedItems.nodes.length?this.diagram.selectedItems.nodes[0]:this.diagram.selectedItems.connectors[0]));var s=t&&t.id,o=this.diagram.layers.indexOf(this.getObjectLayer(s=s||(this.diagram.selectedItems.nodes.length?this.diagram.selectedItems.nodes[0].id:this.diagram.selectedItems.connectors[0].id))),a=$(this.diagram.nameTable),h=(parseInt(o.toString(),10),this.diagram.nameTable[""+s]),c=[],d=this.diagram.spatialSearch.findObjects(h.wrapper.bounds);d.length>2&&(d=this.sortByZIndex(d));for(var u=0,f=d;uNumber(p.zIndex)&&""===p.parentId&&h.wrapper.bounds.intersects(p.wrapper.bounds)&&c.push(p);for(var p=c.length-1;p>=0;p--)(v=this.diagram.nameTable[c[parseInt(p.toString(),10)].id]).parentId===s&&c.splice(p,1);if(c.length>0){var v;if((v=this.diagram.nameTable[c[c.length-1].id]).parentId){var S=om(v,this.diagram,""),b=this.diagram.nameTable[""+S];s!==b.id&&(c[c.length-1]=b)}var M={};for(p=0;p0&&(Object.values(L).forEach(function(fe){fe<=N&&O.push(fe)}),0!==O.length&&this.updateZIndexBySendBackward(h,O,o))}var T=[];if(Object.keys(this.changedNodeZIndexes).forEach(function(fe){if((a[""+fe]?a[""+fe].zIndex:null)!==e.changedNodeZIndexes[""+fe]){var xe=$(a[""+fe]);T.push(xe)}}),this.updateLayerZindexTable(o),P.nodes.splice(0,P.nodes.length),T.forEach(function(fe){var Me=$(fe);P.nodes.push(Me)}),"SVG"===this.diagram.mode){var z=c[c.length-1].id,U=c[c.length-1];U&&"HTML"!==U.shape.type&&"Native"!==U.shape.type&&this.moveSvgNode(s,z);var B=this.diagram.nameTable[""+z];B.children&&B.children.length>0?this.updateNativeNodeIndex(s):this.updateNativeNodeIndex(s,z)}else this.diagram.refreshCanvasLayers();var j=[];Object.keys(this.changedNodeZIndexes).forEach(function(fe){if((a[""+fe]?a[""+fe].zIndex:null)!==e.changedNodeZIndexes[""+fe]){var xe=$(e.diagram.nameTable[""+fe]);j.push(xe)}});var Q=$(this.diagram.selectedItems);Q.nodes.splice(0,Q.nodes.length),j.forEach(function(fe){var Me=$(fe);Q.nodes.push(Me)}),this.diagram.diagramActions&ee.UndoRedo||this.addHistoryEntry({type:"SendBackward",category:"Internal",undoObject:P,redoObject:Q}),this.diagram.endGroupAction()}}this.diagram.protectPropertyChange(!1)},n.prototype.updateZIndexBySendBackward=function(t,e,i){var r=$(t);t.zIndex=Math.max.apply(Math,e);var f,s=t.zIndex,o=Math.max.apply(Math,e),a=this.diagram.layers[parseInt(i.toString(),10)].objects,l=this.diagram.nodes.filter(function(S){return-1!==a.indexOf(S.id)}),h=l.filter(function(S){return S.zIndex===Math.max.apply(Math,e)&&S.id!==t.id});if(h&&h.length>0&&h[0].children)for(var c=Math.max.apply(Math,e),d=0;d0&&g.parentId!==h[0].id){var v=$(g);g.zIndex=f-1,f--,this.triggerOrderCommand(v,g,g)}var y=g.zIndex;this.changedNodeZIndexes[""+g.id]=(this.changedNodeZIndexes.hasOwnProperty(g.id),y)}},n.prototype.findLowestChildZIndex=function(t){for(var e=t.zIndex,i=0;i0),this.selectObjects([t],!0))},n.prototype.clearSelection=function(t,e){return wT(this,void 0,void 0,function(){var i,r,s,o;return CT(this,function(a){return i=this.diagram.allowServerDataBinding,this.diagram.enableServerDataBinding(!1),$a(this.diagram)&&(r=this.diagram.selectedItems,s=this.getSelectedObject(),this.diagram.currentSymbol&&(this.diagram.previousSelectedObject=s),o={oldValue:s,newValue:[],cause:this.diagram.diagramActions,state:"Changing",type:"Removal",cancel:!1},t&&(ce()||this.diagram.triggerEvent(Ce.selectionChange,o)),o.cancel||(r.offsetX=0,r.offsetY=0,r.width=0,r.height=0,r.rotateAngle=0,r.nodes=[],r.connectors=[],r.wrapper=null,r.annotation=void 0,r.selectedObjects=[],this.diagram.clearSelectorLayer(),t&&(o={oldValue:s,newValue:[],cause:this.diagram.diagramActions,state:"Changed",type:"Removal",cancel:!1},ce()||this.diagram.triggerEvent(Ce.selectionChange,o))),this.diagram.enableServerDataBinding(i)),[2]})})},n.prototype.clearSelectedItems=function(){this.clearSelection((this.diagram.selectedItems.nodes?this.diagram.selectedItems.nodes.length:0)+(this.diagram.selectedItems.connectors?this.diagram.selectedItems.connectors.length:0)>0)},n.prototype.removeStackHighlighter=function(){var t=Bl(this.diagram.element.id),e=t.getElementById(t.id+"_stack_highlighter");e&&e.parentNode.removeChild(e)},n.prototype.renderStackHighlighter=function(t,e){var r,s,o,i=this.diagram.selectedItems.nodes[0];if(!e){var a=this.diagram.findObjectsUnderMouse(t.position);if((e=this.diagram.findObjectUnderMouse(a,"Drag",!0))&&!(e.isLane||e.isPhase||e.isHeader))for(var l=0;l0)for(var a=0;a1)if(i){var h=l.segments[0],c=l.segments[1],u=Nl(DI(t.wrapper,t.wrapper.corners,t.wrapper.bounds),h.direction),g=Ol({corners:void 0,point:u=qa(l,0,u,{x:l.sourceWrapper.offsetX,y:l.sourceWrapper.offsetY},!1),margin:void 0,direction:h.direction},{corners:void 0,point:c.points[1],margin:void 0,direction:void 0});h.length=R.distancePoints(g[0],g[1]),c.direction&&c.length&&(c.length=R.distancePoints(g[1],g[2]))}else if(o){switch(l.segments[0].direction){case"Bottom":r=t.wrapper.bounds.bottomCenter.x-e.bottomCenter.x,s=t.wrapper.bounds.bottomCenter.y-e.bottomCenter.y;break;case"Top":r=t.wrapper.bounds.topCenter.x-e.topCenter.x,s=t.wrapper.bounds.topCenter.y-e.topCenter.y;break;case"Left":r=t.wrapper.bounds.middleLeft.x-e.middleLeft.x,s=t.wrapper.bounds.middleLeft.y-e.middleLeft.y;break;case"Right":r=t.wrapper.bounds.middleRight.x-e.middleRight.x,s=t.wrapper.bounds.middleRight.y-e.middleRight.y}this.dragSourceEnd(l,r,s,!0,null,"ConnectorSourceEnd",void 0,void 0,void 0,!(t.parentId&&this.diagram.diagramActions&ee.isGroupDragging))}}},n.prototype.updateEndPoint=function(t,e){var r={sourcePoint:t.sourcePoint,targetPoint:t.targetPoint};t.sourceID&&(r.sourceID=t.sourceID),t.targetID&&(r.targetID=t.targetID),t.sourcePortID&&(r.sourcePortID=t.sourcePortID),t.targetPortID&&(r.targetPortID=t.targetPortID),t.segments&&(r.segments=t.segments),this.diagram.connectorPropertyChange(t,e||{},r),this.diagram.updateSelector()},n.prototype.dragSourceEnd=function(t,e,i,r,s,o,a,l,h,c,d){var u=this.diagram.nameTable[t.id],f={},p=this.checkBoundaryConstraints(e,i,u.wrapper.bounds);if(NI(u)&&p&&"BezierSourceThumb"!==o&&Vv(this.diagram)&&(f=$(f={sourcePoint:u.sourcePoint}),u.sourcePoint.x+=e,u.sourcePoint.y+=i,"ConnectorSourceEnd"===o&&"Orthogonal"===u.type&&this.changeSegmentLength(u,l,h,c),"Bpmn"===u.shape.type&&"Default"===u.shape.sequence&&"Sequence"===u.shape.flow&&this.updatePathElementOffset(u)),"Bezier"===u.type)if(f={sourcePoint:u.sourcePoint},d)this.translateBezierPoints(t,""===o?"ConnectorSourceEnd":o,e,i,d,s,!a);else for(var g=0;g2){var d=R.direction((c=t.segments[2]).points[0],c.points[1]);o.direction===_n(d)?("Right"===o.direction?c.points[0].x=o.points[o.points.length-1].x=l.wrapper.corners.middleRight.x+20:"Left"===o.direction?c.points[0].x=o.points[o.points.length-1].x=l.wrapper.corners.middleLeft.x-20:c.points[0].y=o.points[o.points.length-1].y="Top"===o.direction?l.wrapper.corners.topCenter.y-20:l.wrapper.corners.bottomCenter.y+20,c.direction&&c.length&&(c.length=R.distancePoints(c.points[0],c.points[c.points.length-1])),o.length=R.distancePoints(o.points[0],o.points[o.points.length-1])):o.direction===d&&c.direction&&c.length?("Top"===o.direction||"Bottom"===o.direction?(c.points[0]=o.points[0],c.points[c.points.length-1].x=c.points[0].x):(c.points[0]=o.points[0],c.points[c.points.length-1].y=c.points[0].y),c.length=R.distancePoints(c.points[0],c.points[c.points.length-1]),t.segments.splice(0,2)):o.length=20}else o.length=20;else if(o.length<1)if(""!==t.sourceID){var c;"Right"===a.direction?a.points[a.points.length-1].y=(h=l.wrapper.corners.middleRight).y:"Left"===a.direction?a.points[a.points.length-1].y=(h=l.wrapper.corners.middleLeft).y:a.points[a.points.length-1].x="Top"===a.direction?(h=l.wrapper.corners.topCenter).x:(h=l.wrapper.corners.bottomCenter).x,a.length=R.distancePoints(h,a.points[a.points.length-1]),t.segments.length>2&&(c=t.segments[2]).direction&&c.length&&(c.length=R.distancePoints(a.points[a.points.length-1],c.points[c.points.length-1])),t.segments.splice(0,1)}else t.segments.splice(0,1)}else e&&!i&&t.sourceID!==e.id&&t.segments&&null!==t.segments[0].direction&&e&&e instanceof te&&s&&this.changeSourceEndToNode(t,e),e&&i&&t.sourcePortID!==i&&t.segments&&null!==t.segments[0].direction&&e&&e instanceof te&&s&&this.changeSourceEndToPort(t,e,i)},n.prototype.canConnect=function(t,e){return!(!ua(e)||!Ph(e))},n.prototype.changeSourceEndToPort=function(t,e,i){var r=this.diagram.getWrapper(e.wrapper,i),s={x:r.offsetX,y:r.offsetY},o=zo(s,xn(e.wrapper),e.wrapper.bounds),a=t.segments[0],l=t.segments[1];if(a.direction!==o){var h=[],c={};if(a.direction===_n(o)){c={};var d=void 0;"Top"===o||"Bottom"===o?(d="Top"===o?{type:"Orthogonal",isTerminal:!0,direction:o,length:Math.abs(a.points[0].y-s.y)}:{type:"Orthogonal",isTerminal:!0,direction:o,length:Math.abs(s.y-a.points[0].y)},c=a.points[0].x>s.x?{type:"Orthogonal",isTerminal:!0,direction:"Right",length:a.points[0].x-s.x}:{type:"Orthogonal",isTerminal:!0,direction:"Left",length:s.x-a.points[0].x}):(d="Right"===o?{type:"Orthogonal",isTerminal:!0,direction:o,length:Math.abs(a.points[0].x-s.x)}:{type:"Orthogonal",isTerminal:!0,direction:o,length:Math.abs(s.x-a.points[0].x)},c=a.points[0].y>s.y?{type:"Orthogonal",direction:"Top",isTerminal:!0,length:a.points[0].y-s.y}:{type:"Orthogonal",direction:"Bottom",isTerminal:!0,length:s.y-a.points[0].y}),h.push(new wi(t,"segments",d,!0)),h.push(new wi(t,"segments",c,!0))}else h.push(new wi(t,"segments",c={type:"Orthogonal",direction:o,length:20,isTerminal:!0},!0));a.direction!==_n(o)&&("Top"===o||"Bottom"===o?(a.points[0].x=s.x,a.points[0].y=a.points[a.points.length-1].y="Top"===o?s.y-20:s.y+20):(a.points[0].y=s.y,a.points[0].x=a.points[a.points.length-1].x="Right"===o?s.x+20:s.x-20),a.length=R.distancePoints(a.points[0],a.points[a.points.length-1]),l.length=R.distancePoints(a.points[a.points.length-1],l.points[l.points.length-1])),t.segments=h.concat(t.segments)}else a.points[0]=s,"Top"===o||"Bottom"===o?a.points[a.points.length-1].x=s.x:a.points[a.points.length-1].y=s.y,a.length=R.distancePoints(a.points[0],a.points[a.points.length-1]),l.length=R.distancePoints(a.points[a.points.length-1],l.points[l.points.length-1])},n.prototype.removeTerminalSegment=function(t,e){for(var i=0;ii.width||"Left"===o.direction&&r.x>=o.points[0].x||"Right"===o.direction&&r.x<=o.points[0].x)o.points[0].y=o.points[o.points.length-1].y=r.y,o.points[0].x=r.x,o.length=R.distancePoints(o.points[0],o.points[o.points.length-1]),a.length=R.distancePoints(o.points[o.points.length-1],a.points[a.points.length-1]);else{var h=void 0;s="Bottom"===(h=a.direction?a.direction:R.direction(a.points[0],a.points[a.points.length-1]))?i.bottomCenter:i.topCenter,a.length&&a.direction&&(a.length="Top"===h?o.points[o.points.length-1].y-(s.y+20):s.y+20-o.points[o.points.length-1].y),o.length=o.points[o.points.length-1].x-s.x,o.direction=o.length>0?"Right":"Left",l.push(new wi(t,"segments",{type:"Orthogonal",direction:h,length:20},!0)),t.segments=l.concat(t.segments)}else r="Bottom"===o.direction?i.bottomCenter:i.topCenter,o.length>i.height||"Top"===o.direction&&r.y>=o.points[0].y||"Bottom"===o.direction&&r.y<=o.points[0].y?(o.points[0].x=o.points[o.points.length-1].x=r.x,o.points[0].y=r.y,o.length=R.distancePoints(o.points[0],o.points[o.points.length-1]),a.length=R.distancePoints(o.points[o.points.length-1],a.points[a.points.length-1])):(s="Left"===a.direction?i.middleLeft:i.middleRight,h=void 0,h=a.direction?a.direction:R.direction(a.points[0],a.points[a.points.length-1]),a.length&&a.direction&&(a.length="Left"===h?o.points[o.points.length-1].x-(s.x+20):s.x+20-o.points[o.points.length-1].x),o.length=o.points[o.points.length-1].y-s.y,o.direction=o.length>0?"Bottom":"Top",l.push(new wi(t,"segments",{type:"Orthogonal",direction:h,length:20},!0)),t.segments=l.concat(t.segments))},n.prototype.translateBezierPoints=function(t,e,i,r,s,o,a){var l=t.segments.indexOf(s),h=t.segments[parseInt(l.toString(),10)],c=l>0?t.segments[l-1]:null,d=null!==c?c.point:t.sourcePoint,u=l===t.segments.length-1?t.targetPoint:h.point;if(h)if("BezierSourceThumb"===e&&(h.vector1.angle||h.vector1.distance)){var f=h.vector1.distance,p=h.vector1.angle;h.vector1={distance:t.distance(d,o),angle:R.findAngle(d,o)},this.translateSubsequentSegment(t,s,!0,h.vector1.distance-f,h.vector1.angle-p)}else"BezierTargetThumb"===e&&(h.vector2.angle||h.vector2.distance)?(f=h.vector2.distance,p=h.vector2.angle,h.vector2={distance:t.distance(u,o),angle:R.findAngle(u,o)},this.translateSubsequentSegment(t,s,!1,h.vector2.distance-f,h.vector2.angle-p)):("ConnectorSourceEnd"===e&&!t.sourceID||"ConnectorTargetEnd"===e&&!t.targetID)&&a&&qI(h.vector1)&&qI(h.vector2)?(R.isEmptyPoint(h.point1)&&(h.bezierPoint1=$I(t.sourcePoint,t.targetPoint)),R.isEmptyPoint(h.point2)&&(h.bezierPoint2=$I(t.targetPoint,t.sourcePoint))):"BezierSourceThumb"===e||"ConnectorSourceEnd"===e&&!a&&qI(h.vector1)?(h.bezierPoint1.x+=i,h.bezierPoint1.y+=r,(!R.isEmptyPoint(h.point1)||a)&&(h.point1={x:h.bezierPoint1.x,y:h.bezierPoint1.y})):("BezierTargetThumb"===e||"ConnectorTargetEnd"===e&&!a&&qI(h.vector2))&&(h.bezierPoint2.x+=i,h.bezierPoint2.y+=r,(!R.isEmptyPoint(h.point2)||a)&&(h.point2={x:h.bezierPoint2.x,y:h.bezierPoint2.y}))},n.prototype.translateSubsequentSegment=function(t,e,i,r,s){var o=t.segments.indexOf(e);parseInt(o.toString(),10),t.bezierSettings.smoothness&bI.SymmetricAngle||(s=null),t.bezierSettings.smoothness&bI.SymmetricDistance||(r=null),(null!=r||null!=s)&&(i?0!==o&&this.updatePreviousBezierSegment(t,o,r,s):o!==t.segments.length-1&&this.updateNextBezierSegment(t,o,r,s))},n.prototype.updatePreviousBezierSegment=function(t,e,i,r){var s=t.segments[e-1],a=(s.vector2.angle+r)%360;a<0&&(a+=360),s.vector2={distance:s.vector2.distance+i,angle:a}},n.prototype.updateNextBezierSegment=function(t,e,i,r){var s=t.segments[e+1],a=(s.vector1.angle+r)%360;a<0&&(a+=360),s.vector1={distance:s.vector1.distance+i,angle:a}},n.prototype.dragTargetEnd=function(t,e,i,r,s,o,a,l){var c,h=this.diagram.nameTable[t.id],d=this.checkBoundaryConstraints(e,i,h.wrapper.bounds);if(OI(h)&&"BezierTargetThumb"!==o&&d&&Vv(this.diagram)){if(c=$(c={targetPoint:h.targetPoint}),h.targetPoint.x+=e,h.targetPoint.y+=i,"ConnectorTargetEnd"===o&&"Orthogonal"===h.type&&h.segments&&h.segments.length>0){var u=h.segments[h.segments.length-2];u&&2===h.segments[h.segments.length-1].points.length&&("Left"===u.direction||"Right"===u.direction?u.points[u.points.length-1].x=h.targetPoint.x:u.points[u.points.length-1].y=h.targetPoint.y,u.length=R.distancePoints(u.points[0],u.points[u.points.length-1]),u.direction=R.direction(u.points[0],u.points[u.points.length-1]))}"Bpmn"===h.shape.type&&"Default"===h.shape.sequence&&"Sequence"===h.shape.flow&&this.updatePathElementOffset(h)}if("Bezier"===h.type)if(c={targetPoint:h.targetPoint},l)this.translateBezierPoints(t,""===o?"ConnectorTargetEnd":o,e,i,l,s,!a);else for(var f=0;f0){if(void 0!==s&&o.segments[parseInt(s.toString(),10)])if("Bezier"===o.type){var a=o.segments[parseInt(s.toString(),10)],l=a.isInternalSegment;l&&null!==o.bezierSettings&&"FreeForm"!==o.bezierSettings.segmentEditOrientation?("Horizontal"===a.orientation?a.point.x+=e:a.point.y+=i,this.updateDirectionalBezierCurve(o)):(a.point.x+=e,a.point.y+=i),l&&(o.isBezierEditing=!0)}else o.segments[parseInt(s.toString(),10)].point.x+=e,o.segments[parseInt(s.toString(),10)].point.y+=i;else for(var h=0;h1){var a=e[1],l=e[2],h={x:.5*(a.x+l.x),y:.5*(a.y+l.y)},c=t.segments[0];c.vector1.angle=Gt(s,a),c.vector1.distance=.5*R.findLength(s,a),c.vector2.angle=Gt(h,a),c.vector2.distance=.5*R.findLength(h,a),c.point=h;var d=t.segments[1];if(d.vector1.angle=Gt(h,l),d.vector1.distance=.5*R.findLength(h,l),t.segments.length>2){var u=e[3],f={x:.5*(l.x+u.x),y:.5*(l.y+u.y)};d.vector2.angle=Gt(f,l),d.vector2.distance=.5*R.findLength(f,l),d.point=f;var p=t.segments[2];if(p.vector1.angle=Gt(f,u),p.vector1.distance=.5*R.findLength(f,u),t.segments.length>3){var g=e[4],v={x:.5*(u.x+g.x),y:.5*(u.y+g.y)};p.vector2.angle=Gt(v,u),p.vector2.distance=.5*R.findLength(v,u),p.point=v;var y=t.segments[3];y.vector1.angle=Gt(v,g),y.vector1.distance=.5*R.findLength(v,g),y.vector2.angle=Gt(o,g),y.vector2.distance=.5*R.findLength(o,g)}else p.vector2.angle=Gt(o,u),p.vector2.distance=.5*R.findLength(o,u)}else d.vector2.angle=Gt(o,l),d.vector2.distance=.5*R.findLength(o,l)}},n.prototype.rotateObjects=function(t,e,i,r,s){r=r||{};var o=Bi();qi(o,i,r.x,r.y);for(var l=0,h=e;l0){this.diagram.protectPropertyChange(!0);var o=t;o.segments=[],this.diagram.connectorPropertyChange(o,{},{segments:o.segments}),this.diagram.protectPropertyChange(!1)}}},n.prototype.updateInnerParentProperties=function(t){var r=this.diagram.isProtectedOnChange;this.diagram.protectPropertyChange(!0);for(var s=this.getAllDescendants(t,[],!1,!0),o=0;o0&&(f=this.diagram.bpmnModule.getChildrenBound(d,d.id,this.diagram),u=d.wrapper.bounds.containsRect(f)),h=d.wrapper.actualSize.width*t,c=d.wrapper.actualSize.height*e,void 0!==d.maxWidth&&0!==d.maxWidth&&(h=Math.min(d.maxWidth,h)),void 0!==d.minWidth&&0!==d.minWidth&&(h=Math.max(d.minWidth,h)),void 0!==d.maxHeight&&0!==d.maxHeight&&(c=Math.min(d.maxHeight,c)),void 0!==d.minHeight&&0!==d.minHeight&&(c=Math.max(d.minHeight,c)),u&&(h=Math.max(h,f.right-d.wrapper.bounds.x),c=Math.max(c,f.bottom-d.wrapper.bounds.y)),t=h/d.actualSize.width,e=c/d.actualSize.height}var p=Bi();o||(o=r);var g=o.wrapper;if(qi(p,-g.rotateAngle,i.x,i.y),Gf(p,t,e,i.x,i.y),qi(p,g.rotateAngle,i.x,i.y),r instanceof te){var d,v=Ke(p,{x:(d=r).wrapper.offsetX,y:d.wrapper.offsetY}),y=d.wrapper.offsetX-d.wrapper.actualSize.width*d.pivot.x,S=d.wrapper.offsetY-d.wrapper.actualSize.height*d.pivot.y;if(h>0)if(d.processId){var b=this.diagram.nameTable[d.processId];(!b.maxWidth||d.margin.left+h0)if(d.processId){var M=this.diagram.nameTable[d.processId];(!M.maxHeight||d.margin.top+c0){if(e.dragLimit=e.dragLimit?e.dragLimit:{},e.dragLimit.top||e.dragLimit.bottom||e.dragLimit.left||e.dragLimit.right){var b={minDistance:null};S=this.getRelativeOffset(v,d,b);var M={minDistance:null};g=this.getRelativeOffset(v,y,M),S=null!=b&&M.minDistance0){if(S=y[y.length-1]){var b=void 0;for(b=0;b=e.x-t.dragLimit.left-r.width/2&&i.x<=e.x+t.dragLimit.right+r.width/2&&(s=!0),i.y>=e.y-t.dragLimit.top-r.height/2&&i.y<=e.y+t.dragLimit.bottom+r.height/2&&(o=!0),{x:s,y:o}},n.prototype.updateLabelMargin=function(t,e,i,r,s,o,a){if(i=i||{x:e.offset,y:0},e&&i&&i.x>0&&i.x<1){var l=R.getLengthFromListOfPoints(t.intermediatePoints),h=this.getPointAtLength(l*i.x,t.intermediatePoints,0),c=this.diagram.scrollSettings.currentZoom,d=e.dragLimit?e.dragLimit:{left:0,right:0,top:0,bottom:0};if(d.top||d.bottom||d.left||d.right){this.diagram.getWrapper(t.wrapper,e.id);var f=new Ne(0,0,0,0),p=this.diagram.getWrapper(t.wrapper,e.id);f.x=p.offsetX/c+o,f.y=p.offsetY/c+a,f.width=p.bounds.width/c,f.height=p.bounds.height/c;var g=new Ne(h.x-(d.left||0)-f.width/2,h.y-(d.top||0)-f.height/2,(d.left||0)+(d.right||0)+f.width,(d.top||0)+(d.bottom||0)+f.height);if(g.containsPoint(r));else for(var S=0,b=this.boundsInterSects([h,r],g,!1);S=t){c=t-r,d=R.findAngle(s,a),u=c*Math.cos(d*Math.PI/180),f=c*Math.sin(d*Math.PI/180),o={x:s.x+u,y:s.y+f};break}r+=h,s=a}else s=a;return o},n.prototype.getInterceptWithSegment=function(t,e){for(var o,a,i=[],r=[],s=[],l=R.findLength({x:0,y:0},{x:this.diagram.scroller.viewPortWidth,y:this.diagram.scroller.viewPortHeight}),h=1;h0&&a<=90||a>180&&a<=270?90:-90;r.push(R.transform(t,a+c,l)),r.push(R.transform(t,o+c,l));var f=tm({x1:s[0].x,y1:s[0].y,x2:s[1].x,y2:s[1].y},{x1:r[0].x,y1:r[0].y,x2:r[1].x,y2:r[1].y});f.enabled&&i.push(f.intersectPt)}return i},n.prototype.getAnnotationChanges=function(t,e){var r={};return r[nb(t,e.id,!0)]={width:e.width,height:e.height,offset:t instanceof te?{x:e.offset.x,y:e.offset.y}:e.offset,rotateAngle:e.rotateAngle,margin:{left:e.margin.left,right:e.margin.right,top:e.margin.top,bottom:e.margin.bottom},horizontalAlignment:e.horizontalAlignment,verticalAlignment:e.verticalAlignment,alignment:t instanceof de?e.alignment:void 0},{annotations:r}},n.prototype.getConnectorPortChanges=function(t,e){var i=function zse(n,t,e){for(var i=n.ports,r=0;r1&&(v.width=g,v.offset.x=1/S),p>1&&(v.height=p,v.offset.y=1/b)}}e instanceof Or&&(e.alignment="Center"),l=this.getAnnotationChanges(t,e),t instanceof te?this.diagram.nodePropertyChange(t,a,l):this.diagram.connectorPropertyChange(t,a,l),this.diagram.updateDiagramObject(t)},n.prototype.getSubProcess=function(t){var i,e={nodes:[],connectors:[]};return t instanceof te?i=t.processId:t&&t.nodes&&t.nodes.length&&t.nodes[0].processId&&(i=t.nodes[0].processId),i&&e.nodes.push($(this.diagram.nameTable[i])),e},n.prototype.checkBoundaryConstraints=function(t,e,i,r){var s=this.diagram.pageSettings,o=this.diagram.pageSettings.boundaryConstraints,a=this.diagram.scroller;if("Page"===o||"Diagram"===o){var l=i?void 0:this.diagram.selectedItems.wrapper.bounds;return!!((i?i.right:l.right)+(t||0)<=("Page"===o?s.width:a.viewPortWidth)&&(i?i.left:l.left)+(t||0)>=0&&(i?i.bottom:l.bottom)+(e||0)<=("Page"===o?s.height:a.viewPortHeight)&&(i?i.top:l.top)+(e||0)>=0||"None"!==this.diagram.layout.type&&r)}return!0},n.prototype.dragSelectedObjects=function(t,e){var i=this,r=this.diagram.selectedItems;this.state&&!this.state.backup&&(this.state.backup={},this.state.backup.offsetX=r.offsetX,this.state.backup.offsetY=r.offsetY),r=YI(this.diagram,r)||r;var s=this.diagram.selectedItems.nodes.filter(function(c){return"SwimLane"===c.shape.type});if(s.length>0&&!this.diagram.currentSymbol&&this.diagram.selectedItems.nodes.length>1){var o=this.diagram.selectedItems.nodes.filter(function(c){return""===c.parentId||"SwimLane"!==i.diagram.nameTable[c.parentId].shape.type});if(o.length>0){for(var a=0;a0||l.length>1)&&(o=o.concat(l),this.diagram.selectedItems.nodes.splice(0,this.diagram.selectedItems.nodes.length),o.forEach(function(c){i.diagram.selectedItems.nodes.push(c)}),r=this.diagram.selectedItems,this.diagram.selectedObject.helperObject=void 0)}}if(this.checkBoundaryConstraints(t,e)){this.diagram.diagramActions=this.diagram.diagramActions|ee.PreventZIndexOnDragging|ee.DragUsingMouse;var h=this.diagram.selectedObject.actualObject;return(h&&h instanceof te&&h.isLane&&Wx(h,this.diagram)||!h||!h.isLane)&&this.diagram.drag(r,t,e),this.diagram.diagramActions=this.diagram.diagramActions&~(ee.PreventZIndexOnDragging|ee.DragUsingMouse),this.diagram.refreshCanvasLayers(),this.checkHtmlObjectDrag(r),!0}return!1},n.prototype.checkHtmlObjectDrag=function(t){var e=!1;this.diagram.views&&this.diagram.views.length>1&&(t instanceof ei?e=t.nodes.some(function(i){return i.shape&&"HTML"===i.shape.type}):t.shape&&"HTML"===t.shape.type&&(e=!0),e&&this.resetOverviewCanvas())},n.prototype.resetOverviewCanvas=function(){for(var t=0,e=this.diagram.views;t0&&(this.layoutAnimateModule.stopCurrentAnimation(this.objectStore[0],e,t),this.objectStore=[]),a=this.diagram.doLayout(),this.objectStore.push(a)),this.canUpdateTemplate=!1,this.diagram.blazorActions&=~on.expandNode,this.diagram.preventNodesUpdate=r,this.diagram.layoutAnimateModule&&this.diagram.organizationalChartModule&&!i)this.diagram.allowServerDataBinding=!1,this.layoutAnimateModule.expand(this.diagram.layout.enableAnimation,a,t,this.diagram);else{var l={element:$(t),state:!!t.isExpanded};this.triggerEvent(Ce.expandStateChange,l),this.diagram.lineRoutingModule&&this.diagram.constraints&nt.LineRouting&&"ComplexHierarchicalTree"!==this.diagram.layout.type&&this.diagram.resetSegments()}return this.diagram.layout.fixedNode=""===o?"":this.diagram.layout.fixedNode,a},n.prototype.getparentexpand=function(t,e,i,r){for(var s,o=0;o0&&(this.diagram.selectedItems.wrapper.rotateAngle=this.diagram.selectedItems.rotateAngle=s.rotateAngle),!(r instanceof te&&"SwimLane"!==r.shape.type)||r.isLane||r.isPhase||r.isHeader||Dn(this.diagram,r)){if(r instanceof ei)for(var d=0;d30||g.wrapper.outerBounds.topCenter.y-p.wrapper.outerBounds.bottomCenter.y>30)&&this.diagram.lineRoutingModule.refreshConnectorSegments(this.diagram,f,!0)}}this.updateSelector(),this.diagram.protectPropertyChange(!1)}},n.prototype.drawSelectionRectangle=function(t,e,i,r){this.diagram.drawSelectionRectangle(t,e,i,r)},n.prototype.startGroupAction=function(){this.diagram.startGroupAction()},n.prototype.endGroupAction=function(){this.diagram.endGroupAction()},n.prototype.removeChildFromBPmn=function(t,e,i){var r=this.diagram.nameTable[t.id]||t.nodes[0];if(i&&r&&r.processId&&r.processId===i.wrapper.id){var s=$(r);s.processId=r.processId,this.diagram.startGroupAction();var o=this.diagram.nameTable[r.processId].shape.activity.subProcess.processes||[];o.splice(o.indexOf(r.id),1),this.diagram.bpmnModule.removeChildFromBPMN(this.diagram.nameTable[r.processId].wrapper,r.id,this.diagram),this.diagram.nameTable[r.id].processId="",r.offsetX=r.wrapper.offsetX,r.offsetY=r.wrapper.offsetY;var a=$(r);this.addHistoryEntry({type:"PositionChanged",redoObject:{nodes:[a]},undoObject:{nodes:[s]},category:"Internal"}),this.diagram.endGroupAction()}},n.prototype.isDroppable=function(t,e){var i=this.diagram.nameTable[t.id]||t.nodes[0];return i instanceof te&&(!ce()&&"TextAnnotation"===i.shape.shape||("Group"===e.shape.shape&&(e.shape.activity.subProcess.collapsed=!1),!(i&&"Bpmn"===i.shape.type&&(i.processId===e.id||i.id===e.processId||"Bpmn"===e.shape.type&&!(e instanceof de)&&e.shape.activity&&e.shape.activity.subProcess&&e.shape.activity.subProcess.collapsed))))},n.prototype.renderHighlighter=function(t,e,i){if(new Ne,t.target instanceof te||t.target instanceof de||e&&(t.source instanceof te||t.source instanceof de)){var a=this.findTarget(e?t.sourceWrapper:t.targetWrapper,e?t.source:t.target,i,!0),l=void 0;if(a instanceof Rd)for(var h=a.id,c=t.target,u=0,f=c.wrapper.children[0].children[0].children[2].children;u0){var r=0;t[0]=this.diagram.nameTable[t[0].id]||t[0];var s="Object"===i?yr(t[0].wrapper):this.diagram.selectedItems.wrapper.bounds,o={nodes:[],connectors:[]},a={nodes:[],connectors:[]};for(r="Object"===i?r+1:r;r0){var i=0,r=0,s=0,o=0,a=0,l=0,h=0,c=0,d={nodes:[],connectors:[]},u={nodes:[],connectors:[]};for(i=0;io.center.y&&(r=n[parseInt(e.toString(),10)],n[parseInt(e.toString(),10)]=n[parseInt(i.toString(),10)],n[parseInt(i.toString(),10)]=r):s.center.x>o.center.x&&(r=n[parseInt(e.toString(),10)],n[parseInt(e.toString(),10)]=n[parseInt(i.toString(),10)],n[parseInt(i.toString(),10)]=r)}}return n}(t,e),i=1;i0){var i=0,r={x:.5,y:.5};t[0]=this.diagram.nameTable[t[0].id]||t[0];var s=yr(t[0].wrapper),o={nodes:[],connectors:[]},a={nodes:[],connectors:[]};for(i=1;ii.zIndex){for(var s=this.diagram.layers.indexOf(this.diagram.getActiveLayer()),o=this.diagram.layers[parseInt(s.toString(),10)].zIndexTable,a=JSON.parse(JSON.stringify(o)),l=i.zIndex,h=r.zIndex,c=h;c>=l;c--)l!==c?o[c-1]?(o[parseInt(c.toString(),10)]=o[c-1],this.diagram.nameTable[o[parseInt(c.toString(),10)]].zIndex=c):(o[c-1]=o[parseInt(c.toString(),10)],this.diagram.nameTable[o[c-1]].zIndex=c,delete o[parseInt(c.toString(),10)]):this.swapZIndexObjects(h,o,r.id,a);"SVG"===this.diagram.mode?(this.moveSvgNode(e.parentId,i.id),this.updateNativeNodeIndex(e.parentId,i.id)):this.diagram.refreshCanvasLayers()}},n.prototype.findLeastIndexConnector=function(t,e,i){for(var r=0;rs.zIndex&&(i=s)}return i},n.prototype.findLeastIndexObject=function(t,e){var i=t;return t instanceof te&&(i=this.findLeastIndexConnector(t.inEdges,e,i),i=this.findLeastIndexConnector(t.outEdges,e,i)),i},n.prototype.checkSelection=function(t,e){var i;if(1===t.nodes.length&&0===t.connectors.length)if(Dn(this.diagram,t.nodes[0],!0)){var r=t.nodes[0];if("SwimLane"===(i="SwimLane"===t.nodes[0].shape?t.nodes[0]:this.diagram.nameTable[t.nodes[0].parentId]).shape.type){var s="Horizontal"===i.shape.orientation;(r.isPhase&&(s&&"ResizeSouth"===e||!s&&"ResizeEast"===e)||r.isLane&&(s&&"ResizeEast"===e||!s&&"ResizeSouth"===e))&&B3(this.diagram,i,e)}else if("Grid"===i.container.type)if("Horizontal"===i.container.orientation&&1===r.rowIndex||"Vertical"===i.container.orientation&&r.rowIndex>0&&r.columnIndex>0){if("ResizeSouth"===e)for(var o=0;o1&&(this.diagram.realActions=this.diagram.realActions|$i.hScrollbarMoved,this.scrolled=!0),this.diagram.scrollSettings.horizontalOffset=t},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"verticalOffset",{get:function(){return this.vOffset},set:function(t){this.vOffset=t,Math.abs(this.vOffset-this.diagram.scrollSettings.verticalOffset)>1&&(this.diagram.realActions=this.diagram.realActions|$i.vScrollbarMoved,this.scrolled=!0),this.diagram.scrollSettings.verticalOffset=t},enumerable:!0,configurable:!0}),n.prototype.getBounds=function(){var e=this.diagram.spatialSearch.getPageBounds(0,0);return(e.x<0||e.y<0)&&!this.diagram.pageSettings.multiplePage?this.getPageBounds(void 0,void 0,!0,!0):this.getPageBounds(void 0,void 0,!0)},n.prototype.updateScrollOffsets=function(t,e){var i,r,s=this.getBounds();s.x*=this.currentZoom,s.y*=this.currentZoom,s.width*=this.currentZoom,s.height*=this.currentZoom,i=Math.max(0,t-s.left),r=Math.max(0,e-s.top),void 0!==t&&void 0!==e?(this.horizontalOffset=i,this.verticalOffset=r,this.diagram.setOffset(i,r)):this.diagram.setOffset(-this.horizontalOffset-s.x,-this.verticalOffset-s.y),this.transform={tx:Math.max(this.horizontalOffset,-s.left)/this.currentZoom,ty:Math.max(this.verticalOffset,-s.top)/this.currentZoom,scale:this.currentZoom}},n.prototype.setScrollOffset=function(t,e){this.scrolled=!1;var i=this.getBounds();i.x*=this.currentZoom,i.y*=this.currentZoom,i.width*=this.currentZoom,i.height*=this.currentZoom;var r=-i.left,s=-i.top,o=!1,a=this.viewPortWidth*this.currentZoom,l=this.viewPortHeight*this.currentZoom,h=r-t;if(h!==this.horizontalOffset){rh?this.horizontalOffset-=t:this.horizontalOffset=h,o=!0);var c=Math.max(i.right+this.vScrollSize,a);if(!o&&c<-h+this.viewPortWidth){var d=-h+a-this.vScrollSize,u=-this.horizontalOffset+a-this.vScrollSize;this.horizontalOffset=dd-u?h:-(i.right+this.vScrollSize-a),o=!0}o||(this.horizontalOffset=r-t)}o=!1;var f=s-e;if(f!==this.verticalOffset){sf?this.verticalOffset-=e:this.verticalOffset=f,o=!0);var p=Math.max(i.bottom+this.hScrollSize,l);if(!o&&p<-f+l){var g=-f+l-this.hScrollSize,v=-this.verticalOffset+l-this.hScrollSize;this.verticalOffset=gg-v?f:-(i.bottom+this.hScrollSize-l),o=!0}o||(this.verticalOffset=s-e)}this.transform={tx:Math.max(this.horizontalOffset,-i.left)/this.currentZoom,ty:Math.max(this.verticalOffset,-i.top)/this.currentZoom,scale:this.currentZoom},this.setSize()},n.prototype.getObjects=function(t,e){for(var i=[],r=0;r0){for(var l=0;l0){h.push(i[parseInt(o.toString(),10)].id);for(var d=0;d=e.bottom&&(l=0),-this.horizontalOffset<=e.x&&-this.horizontalOffset+this.viewPortWidth>=e.right&&(a=0),this.hScrollSize=a,this.vScrollSize=l;var h=this.diagramWidth,c=this.diagramHeight;this.diagramWidth=Math.max(e.right,-this.horizontalOffset+this.viewPortWidth-l)-i,this.diagramHeight=Math.max(e.bottom,-this.verticalOffset+this.viewPortHeight-a)-r,(h!==this.diagramWidth||c!==this.diagramHeight)&&"Diagram"!==this.diagram.scrollSettings.scrollLimit&&this.diagram.setSize(this.diagramWidth,this.diagramHeight),"Diagram"===this.diagram.scrollSettings.scrollLimit&&(h===this.diagramWidth&&c===this.diagramHeight&&1===this.currentZoom||this.diagram.diagramActions&&t&&(!this.diagram.diagramActions||!t||0===this.verticalOffset&&this.verticalOffset!==t.y||0===this.horizontalOffset&&this.horizontalOffset!==t.x)?t&&h===this.diagramWidth&&c===this.diagramHeight&&(this.diagram.diagramCanvas.scrollHeight>this.viewPortHeight&&t.y<0&&this.horizontalOffset===t.x&&0===this.verticalOffset||this.diagram.diagramCanvas.scrollWidth>this.viewPortWidth&&t.x<0&&this.verticalOffset===t.y&&0===this.horizontalOffset)&&(this.verticalOffset=t.y,this.horizontalOffset=t.x,this.transform={tx:Math.max(t.x,-e.left)/this.currentZoom,ty:Math.max(t.y,-e.top)/this.currentZoom,scale:this.currentZoom}):(this.diagram.scrollActions&da.Interaction&&t&&(this.transform={tx:Math.max(t.x,-e.left/this.currentZoom)/this.currentZoom,ty:Math.max(t.y,-e.top/this.currentZoom)/this.currentZoom,scale:this.currentZoom},this.horizontalOffset=t.x,this.verticalOffset=t.y),this.diagram.setSize(this.diagramWidth,this.diagramHeight),!(this.diagram.scrollActions&da.PropertyChange)&&t&&(this.horizontalOffset=t.x,this.verticalOffset=t.y,this.transform={tx:Math.max(t.x,-e.left)/this.currentZoom,ty:Math.max(t.y,-e.top)/this.currentZoom,scale:this.currentZoom}))),this.diagram.transformLayers(),this.diagram.element.style.overflow="hidden"},n.prototype.setViewPortSize=function(t,e){this.viewPortWidth=t,this.viewPortHeight=e},n.prototype.getPageBounds=function(t,e,i,r){var o,s=new Ne;if("Content"===e||r||null===this.diagram.pageSettings.width||null===this.diagram.pageSettings.height){var u=t?void 0:0;o=this.diagram.spatialSearch.getPageBounds(u,u)}else{var a=this.diagram.pageSettings.width,l=this.diagram.pageSettings.height,h=0,c=0;if(this.diagram.pageSettings.multiplePage){if((s=this.diagram.spatialSearch.getPageBounds(0,0)).right>a&&(a*=d=Math.ceil(s.right/a)),s.bottom>l&&(l*=d=Math.ceil(s.bottom/l)),s.left<0&&Math.abs(s.left)>h){var d=Math.ceil(Math.abs(s.left)/this.diagram.pageSettings.width);h=this.diagram.pageSettings.width*d}s.top<0&&Math.abs(s.top)>c&&(d=Math.ceil(Math.abs(s.top)/this.diagram.pageSettings.height),c=this.diagram.pageSettings.height*d)}o=new Ne(-h,-c,a+h,l+c)}if(i){var f=this.diagram.scrollSettings.padding;o.x-=f.left,o.y-=f.top,o.width+=f.left+f.right,o.height+=f.top+f.bottom}return o},n.prototype.getPageBreak=function(t){for(var e=0,i=0,r=-1,s=[],c=this.diagram.pageSettings.margin.left,d=this.diagram.pageSettings.margin.right,u=this.diagram.pageSettings.margin.top,f=this.diagram.pageSettings.margin.bottom,p=1,g=1;t.width>e;)(e+=this.diagram.pageSettings.width?this.diagram.pageSettings.width:t.width)===this.diagram.pageSettings.width&&(s[++r]={x1:t.left+c,y1:t.top+u,x2:t.left+c,y2:t.bottom-f}),ei;)(i+=this.diagram.pageSettings.height?this.diagram.pageSettings.height:t.height)===this.diagram.pageSettings.height&&(s[++r]={x1:t.left+c,y1:t.top+u,x2:t.right-d,y2:t.top+u}),i=this.diagram.scrollSettings.minZoom||l||t>=1)){this.currentZoom*=t;var c=this.getPageBounds(void 0,void 0,!0);c.x*=this.currentZoom,c.y*=this.currentZoom;var d=Bi();Gf(d,t,t,r.x,r.y),ZB(d,e||0,i||0),Sx(h,d);var u=Ke(h,{x:0,y:0});if(1===t&&(u=this.applyScrollLimit(u.x,u.y,s,o,a)),a=-c.y>=u.y&&-c.x>=u.x&&a,(this.diagram.scrollActions&da.PropertyChange||!(this.diagram.scrollActions&da.Interaction)||"Diagram"!==this.diagram.scrollSettings.scrollLimit||a)&&(this.transform={tx:Math.max(u.x,-c.left)/this.currentZoom,ty:Math.max(u.y,-c.top)/this.currentZoom,scale:this.currentZoom},this.horizontalOffset=u.x,this.verticalOffset=u.y),this.setSize(u),"SVG"!==this.diagram.mode&&Ds(this.diagram)&&this.diagram.scroller.virtualizeElements(),"SVG"!==this.diagram.mode&&!Ds(this.diagram)&&this.diagram.refreshDiagramLayer(),this.diagram.setOffset(-this.horizontalOffset-c.x,-this.verticalOffset-c.y),ZI(this.diagram),this.diagram.views&&this.diagram.views.overview){var f=this.diagram.views.overview,p=f.scrollOverviewRect(f.parent.scroller.horizontalOffset,f.parent.scroller.verticalOffset,f.parent.scroller.currentZoom,!0);f.updateOverviewrect(-p.x,-p.y,p.width,p.height),f.updateView(f)}}}},n.prototype.fitToPage=function(t){var e=(t=t||{}).mode,i=t.region,r=t.margin||{},s=t.canZoomIn,o=t.customBounds,a=t.canZoomOut;r.bottom=r.bottom||25,r.top=r.top||25,r.left=r.left||25,r.right=r.right||25;var h,l=o,c=-this.horizontalOffset,d=-this.verticalOffset;if("PageSettings"===(i=i||"PageSettings")&&this.diagram.pageSettings.width&&this.diagram.pageSettings.height||this.diagram.nodes.length>0||this.diagram.connectors.length>0){e=e||"Page","CustomBounds"!==i&&(l=this.getPageBounds(!0,i,!0));var u={x:0,y:0};r.left+r.right>this.viewPortWidth&&(this.viewPortWidth<=100?(r.left=5,r.right=5):(r.left=25,r.right=25)),r.top+r.bottom>this.viewPortHeight&&(this.viewPortHeight<=100?(r.top=5,r.bottom=5):(r.top=25,r.bottom=25)),u.x=(this.viewPortWidth-(r.left+r.right))/l.width,u.y=(this.viewPortHeight-(r.top+r.bottom))/l.height,!s&&l.width-this.horizontalOffset-a+this.viewPortWidth&&(i=o.right-this.viewPortWidth,i+=20),o.x<-a&&(i=o.x),o.bottom>-l+this.viewPortHeight&&(r=o.bottom-this.viewPortHeight,r+=20),o.y<-l&&(r=o.y),this.zoom(1,-this.horizontalOffset-i,-this.verticalOffset-r,null,void 0,e))},n.prototype.bringToCenter=function(t){var e=this.currentZoom,i=new Ne(t.x*e,t.y*e,t.width*e,t.height*e),r=i.x+i.width/2-this.viewPortWidth/2,s=i.y+i.height/2-this.viewPortHeight/2;this.zoom(1,-this.horizontalOffset-(r*=-1),-this.verticalOffset-(s*=-1),null)},n.prototype.applyScrollLimit=function(t,e,i,r,s){if("Infinity"===this.diagram.scrollSettings.scrollLimit&&void 0===i&&!r&&(t=-t,e=-e),"Infinity"!==this.diagram.scrollSettings.scrollLimit){var o=void 0;if("Limited"===this.diagram.scrollSettings.scrollLimit){var a=this.diagram.scrollSettings.scrollableArea;o=new Ne(a.x,a.y,a.width,a.height)}(o=o||(s?this.getPageBounds():this.getPageBounds(!0))).x*=this.currentZoom,o.y*=this.currentZoom,o.width*=this.currentZoom,o.height*=this.currentZoom,void 0!==i&&(t*=-1,e*=-1),r&&(t*=-1,e*=-1);var l=Math.max(o.right,this.viewPortWidth);if(!r&&!(t<=o.x&&(t+this.viewPortWidth>=o.right||t>=o.right-this.viewPortWidth)||t>=o.x&&t+this.viewPortWidth<=l))if(t>=o.x)t=Math.max(o.x,Math.min(t,t-(t+this.viewPortWidth-this.vScrollSize-l)));else{var h=o.right-this.viewPortWidth;t=Math.min(h,o.x)}var c=Math.max(o.bottom,this.viewPortHeight);r||e<=o.y&&e+this.viewPortHeight>=o.bottom||e>=o.y&&e+this.viewPortHeight<=c||(e>=o.y?e=Math.max(o.y,Math.min(e,e-(e+this.viewPortHeight-this.hScrollSize-c))):(h=o.bottom-this.viewPortHeight,e=Math.min(o.y,h))),t*=-1,e*=-1}return{x:t,y:e}},n}(),Qoe=function(){function n(t,e,i,r,s){this.objects=[],this.left=t,this.top=e,this.width=i,this.height=r,this.spatialSearch=s}return n.prototype.findQuads=function(t,e){null!=this.first&&this.first.isIntersect(t)&&this.first.findQuads(t,e),null!=this.second&&this.second.isIntersect(t)&&this.second.findQuads(t,e),null!=this.third&&this.third.isIntersect(t)&&this.third.findQuads(t,e),null!=this.fourth&&this.fourth.isIntersect(t)&&this.fourth.findQuads(t,e),this.objects.length>0&&e.push(this)},n.prototype.isIntersect=function(t){return!(this.left+this.widtht.right||this.top>t.bottom)},n.prototype.selectQuad=function(){for(var i,t=null,e=this;null!=e;)i=e.getQuad(t),e=i.source,t=i.target||t;return t},n.prototype.getQuad=function(t){var e=this.width/2,i=this.height/2;if(e>=1e3&&i>=1e3){var r=this.left+e,s=this.top+i;if(this.spatialSearch.childRight<=r){if(this.spatialSearch.childBottom<=s)return this.first||((o=new n(this.left,this.top,e,i,this.spatialSearch)).parent=this,this.first=o),{source:this.first};if(this.spatialSearch.childTop>=s)return this.third||((o=new n(this.left,s,e,i,this.spatialSearch)).parent=this,this.third=o),{source:this.third}}else if(this.spatialSearch.childLeft>=r){if(this.spatialSearch.childBottom<=s)return this.second||((o=new n(r,this.top,e,i,this.spatialSearch)).parent=this,this.second=o),{source:this.second};var o;if(this.spatialSearch.childTop>=s)return this.fourth||((o=new n(r,s,e,i,this.spatialSearch)).parent=this,this.fourth=o),{source:this.fourth}}}return this.objects.push(this.spatialSearch.childNode),{target:this}},n.prototype.isContained=function(){return this.spatialSearch.childLeft>=this.left&&this.spatialSearch.childRight<=this.left+this.width&&this.spatialSearch.childTop>=this.top&&this.spatialSearch.childBottom<=this.top+this.height},n.prototype.addIntoAQuad=function(t){var e={};this.spatialSearch.setCurrentNode(t);for(var i=null;!e.isAdded;)i=(e=this.spatialSearch.parentQuad.add(i)).quad;return i},n.prototype.add=function(t){if(t=null,this.isContained())return{isAdded:!0,quad:t=this.selectQuad()};var e=void 0,i=!(0!==this.objects.length||this.first||this.second||this.third||this.fourth),r=2*this.width,s=2*this.height;return this.spatialSearch.childLeft=this.childLeft?(this.pageLeft=this.childLeft,this.leftElement=t,r=!0):t===this.leftElement&&(this.pageLeft=Number.MAX_VALUE,this.findLeft(this.parentQuad),r=!0)),(this.pageTop!==this.childTop||t!==this.topElement)&&(this.pageTop>=this.childTop?(this.pageTop=this.childTop,this.topElement=t,r=!0):t===this.topElement&&(this.pageTop=Number.MAX_VALUE,this.findTop(this.parentQuad),r=!0)),(this.pageBottom!==this.childBottom||t!==this.bottomElement)&&(this.pageBottom<=this.childBottom?(r=!0,this.pageBottom=this.childBottom,this.bottomElement=t):t===this.bottomElement&&(this.pageBottom=-Number.MAX_VALUE,this.findBottom(this.parentQuad),r=!0)),(this.pageRight!==this.childRight||t!==this.rightElement)&&(this.pageRight<=this.childRight?(this.pageRight=this.childRight,this.rightElement=t,r=!0):t===this.rightElement&&(this.pageRight=-Number.MAX_VALUE,this.findRight(this.parentQuad),r=!0)),r}return this.setCurrentNode(null),!1},n.prototype.isWithinPageBounds=function(t){return t.left>=this.pageLeft&&t.right<=this.pageRight&&t.top>=this.pageTop&&t.bottom<=this.pageBottom},n.prototype.findQuads=function(t){var e=[];return this.parentQuad.findQuads(t,e),e},n.prototype.findObjects=function(t){for(var i=[],r=0,s=this.findQuads(t);r=r.outerBounds.left&&(this.pageLeft=r.outerBounds.left,this.leftElement=r)}},n.prototype.findTop=function(t){t.first||t.second?(t.first&&this.findTop(t.first),t.second&&this.findTop(t.second)):(t.third&&this.findTop(t.third),t.fourth&&this.findTop(t.fourth));for(var e=0,i=t.objects;e=r.outerBounds.top&&(this.pageTop=r.outerBounds.top,this.topElement=r)}},n.prototype.setCurrentNode=function(t){if(this.childNode=t,t){var e=t.outerBounds;this.childLeft=Number(e.left),this.childTop=Number(e.top),this.childRight=Number(e.right),this.childBottom=Number(e.bottom)}else this.childLeft=Number.MAX_VALUE,this.childTop=Number.MAX_VALUE,this.childRight=-Number.MAX_VALUE,this.childBottom=-Number.MAX_VALUE},n.prototype.getPageBounds=function(t,e){if(this.pageLeft===Number.MAX_VALUE)return new Ne(0,0,0,0);var i=void 0!==t?Math.min(this.pageLeft,0):this.pageLeft,r=void 0!==e?Math.min(this.pageTop,0):this.pageTop;return new Ne(Math.round(i),Math.round(r),Math.round(this.pageRight-i),Math.round(this.pageBottom-r))},n.prototype.getQuad=function(t){return this.quadTable[t.id]},n}(),Goe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),qoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Goe(t,n),function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);r>3&&s&&Object.defineProperty(t,e,s)}([I(!1)],t.prototype,"preventDefaults",void 0),t}(Ee),$oe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),e_=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Zoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return $oe(t,n),e_([I("")],t.prototype,"action",void 0),e_([I("")],t.prototype,"cursor",void 0),t}(Ee),t_=function(){function n(){this.size=20,this.intermediatePoints=[],this.gridCollection=[],this.startArray=[],this.targetGridCollection=[],this.sourceGridCollection=[],this.considerWalkable=[]}return n.prototype.lineRouting=function(t){var e=t.connectors.length;if(this.renderVirtualRegion(t),e>0)for(var i=0;i=t.right||e.right<=t.left||e.top>=t.bottom||e.bottom<=t.top)},n.prototype.findEndPoint=function(t,e,i){var r,s;if(e&&""!==t.sourcePortID&&t.sourcePortWrapper||!e&&""!==t.targetPortID&&t.targetPortWrapper){s=zo(r=e?{x:t.sourcePortWrapper.offsetX,y:t.sourcePortWrapper.offsetY}:{x:t.targetPortWrapper.offsetX,y:t.targetPortWrapper.offsetY},void 0,e?t.sourceWrapper.bounds:t.targetWrapper.bounds);var o=e?t.sourcePortWrapper.bounds:t.targetPortWrapper.bounds;r=i?"Top"===s?{x:o.topCenter.x,y:o.topCenter.y}:"Left"===s?{x:o.middleLeft.x,y:o.middleLeft.y}:"Right"===s?{x:o.middleRight.x,y:o.middleRight.y}:{x:o.bottomCenter.x,y:o.bottomCenter.y}:{x:o.center.x,y:o.center.y}}else r=e&&this.startNode||!e&&this.targetNode?e?{x:this.startNode.wrapper.offsetX,y:this.startNode.wrapper.offsetY}:{x:this.targetNode.wrapper.offsetX,y:this.targetNode.wrapper.offsetY}:e?{x:t.sourcePoint.x,y:t.sourcePoint.y}:{x:t.targetPoint.x,y:t.targetPoint.y};return r},n.prototype.refreshConnectorSegments=function(t,e,i,r){var h,c,f,p,g,y,S,b,M,w,C,s=e.sourceID,o=e.targetID,a=e.sourcePortID,l=e.targetPortID;if(function Vre(n,t){var e=0;return n.constraints&qe.LineRouting?e=n.constraints&qe.LineRouting:n.constraints&qe.InheritLineRouting&&(e=t.constraints&nt.LineRouting),e}(e,t)||r){this.startNode=t.nameTable[""+s],this.targetNode=t.nameTable[""+o],this.intermediatePoints=[],this.startArray=[],this.targetGridCollection=[],this.sourceGridCollection=[],this.startGrid=void 0,this.targetGrid=void 0;for(var D=0;D0;){var L=this.startArray.pop();if(L){for(D=0;D1&&(e.segments=[]),this.updateConnectorSegments(t,this.intermediatePoints,this.gridCollection,e,i)){this.considerWalkable=[];break e}this.targetGridCollection.splice(this.targetGridCollection.indexOf(O),1),L=this.startArray.pop()}}L&&this.findPath(L)}}}},n.prototype.checkChildNodes=function(t,e){var i=!1,r=!1;if(t.nodeId.length>=1&&!e)for(var s=0;s1&&this.targetGridCollection[0].nodeId.length>1)for(var c=0;c<=1;c++){for(var d=this.targetGridCollection[parseInt(c.toString(),10)].gridX,u=this.targetGridCollection[parseInt(c.toString(),10)].gridY,f=this.targetGridCollection[parseInt(c.toString(),10)].nodeId,p=void 0,g=0;g=e.right&&t.top<=e.top&&t.bottom>=e.bottom},n.prototype.getEndvalue=function(t,e){return this.gridCollection[t.gridX][t.gridY].walkable?t:"left"===e?this.getEndvalue(this.gridCollection[t.gridX-1][t.gridY],e):"right"===e?this.getEndvalue(this.gridCollection[t.gridX+1][t.gridY],e):"top"===e?this.getEndvalue(this.gridCollection[t.gridX][t.gridY-1],e):"bottom"===e?this.getEndvalue(this.gridCollection[t.gridX][t.gridY+1],e):t},n.prototype.changeValue=function(t,e,i){t.walkable||this.considerWalkable.push(t);for(var r,s=0;s<=e;s++)"left"===i?r=this.gridCollection[t.gridX-s][t.gridY]:"right"===i?r=this.gridCollection[t.gridX+s][t.gridY]:"top"===i?r=this.gridCollection[t.gridX][t.gridY-s]:"bottom"===i&&(r=this.gridCollection[t.gridX][t.gridY+s]),r.walkable||this.considerWalkable.push(r)},n.prototype.getIntermediatePoints=function(t){var e;for(this.intermediatePoints=[];t;)this.intermediatePoints.push({x:t.gridX,y:t.gridY}),t=t.parent;this.intermediatePoints.reverse(),this.intermediatePoints.length>=1&&void 0!==this.intermediatePoints[0]&&void 0!==this.intermediatePoints[1]&&(this.intermediatePoints[0].x===this.intermediatePoints[1].x?this.intermediatePoints[0].yi.y&&o.y>s.y){for(var a=i.xi.x&&o.x>s.x)){for(var u=i.y=1&&u.length>1&&(g=u[u.length-2].x!==u[u.length-1].x?u[u.length-2].x>u[u.length-1].x?"Left":"Right":u[u.length-2].y>u[u.length-1].y?"Top":"Bottom"),M>=2&&v===g&&u.length>1&&u.splice(u.length-2,1),v=g);if(u&&u.length>1){for(var w=0;wD.x?S.bounds.middleLeft:S.bounds.middleRight),w===u.length-2&&""===r.targetPortID&&y&&(l=C.x>D.x?y.bounds.middleRight:y.bounds.middleLeft),0===w&&b&&(C.x=b.x,C.y=D.y=b.y,b=qa(r,0,b,Nl(S.bounds,_n(C.x>D.x?"Left":"Right")),!1),C.x=b.x),w===u.length-2&&l&&(w>0&&r.targetDecorator&&l.x-D.x<0&&Math.abs(l.x-C.x)0&&r.targetDecorator&&l.x-D.x>0&&Math.abs(l.x-C.x)D.y?S.bounds.topCenter:S.bounds.bottomCenter),w===u.length-2&&""===r.targetPortID&&y&&(l=C.y>D.y?y.bounds.bottomCenter:y.bounds.topCenter),0===w&&b&&(C.y=b.y,C.x=D.x=b.x,b=qa(r,0,b,Nl(S.bounds,_n(C.y>D.y?"Top":"Bottom")),!1),C.y=b.y),w===u.length-2&&l&&(w>0&&r.targetDecorator&&l.y-D.y<0&&Math.abs(l.y-C.y)0&&r.targetDecorator&&l.y-D.y>0&&Math.abs(l.y-C.y)D.x?(f="Left",p=C.x-D.x):(f="Right",p=D.x-C.x):C.y>D.y?(f="Top",p=C.y-D.y):(f="Bottom",p=D.y-C.y),o.push({type:"Orthogonal",length:p,direction:f})}}if(o&&o.length>0){var L=o[o.length-1];if(1===o.length&&(L.length-=20),L.length<10&&2===o.length&&(o.pop(),o.length>0&&(o[0].length-=20,L=o[0])),r.targetDecorator&&("Top"===L.direction||"Bottom"===L.direction)&&L.length>r.targetDecorator.height+1||("Right"===L.direction||"Left"===L.direction)&&L.length>r.targetDecorator.width+1)return r.segments=o,s&&t.connectorPropertyChange(r,{},{type:"Orthogonal",segments:o}),!0}return!1},n.prototype.findPath=function(t){for(var e,i=[],r=this.findNearestNeigbours(t,this.gridCollection,!0),s=0;sl)&&(e.x!==t.gridX||e.y!==t.gridY)&&(i.push(e),o.previousDistance=l,o.afterDistance=o.afterDistance||this.manhattan(Math.abs(e.x-this.targetGrid.gridX),Math.abs(e.y-this.targetGrid.gridY)),o.totalDistance=o.previousDistance+o.afterDistance,o.parent=t)}if(i.length>0)for(s=0;st?i*t+e:i*e+t},n.prototype.manhattan=function(t,e){return t+e},n.prototype.findNearestNeigbours=function(t,e,i){var r=[],s=t.parent;if(s){var o=(t.gridX-s.gridX)/Math.max(Math.abs(t.gridX-s.gridX),1),a=(t.gridY-s.gridY)/Math.max(Math.abs(t.gridY-s.gridY),1);0!==o?(this.isWalkable(t.gridX,t.gridY-1,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX][t.gridY-1])&&r.push(e[t.gridX][t.gridY-1]),this.isWalkable(t.gridX,t.gridY+1,!0)&&this.sourceGridCollection.indexOf(e[t.gridX][t.gridY+1])&&r.push(e[t.gridX][t.gridY+1]),this.isWalkable(t.gridX+o,t.gridY,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX+o][t.gridY])&&r.push(e[t.gridX+o][t.gridY])):0!==a&&(this.isWalkable(t.gridX-1,t.gridY,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX-1][t.gridY])&&r.push(e[t.gridX-1][t.gridY]),this.isWalkable(t.gridX+1,t.gridY,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX+1][t.gridY])&&r.push(e[t.gridX+1][t.gridY]),this.isWalkable(t.gridX,t.gridY+a,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX][t.gridY+a])&&r.push(e[t.gridX][t.gridY+a]))}else this.neigbour(t,"top",r,i),this.neigbour(t,"right",r,i),this.neigbour(t,"bottom",r,i),this.neigbour(t,"left",r,i);return r},n.prototype.neigbour=function(t,e,i,r){for(var o,s=1;s>0;){var a="top"===e||"bottom"===e?t.gridX:"left"===e?t.gridX-s:t.gridX+s,l="right"===e||"left"===e?t.gridY:"top"===e?t.gridY-s:t.gridY+s;if((o=this.gridCollection[parseInt(a.toString(),10)][parseInt(l.toString(),10)])&&(r&&-1===this.sourceGridCollection.indexOf(o)||!r&&-1===this.targetGridCollection.indexOf(o)))return i&&this.isWalkable(a,l)&&i.push(o),s;if(!(a>0&&l>0))break;s++}return null},n.prototype.resetGridColl=function(t,e,i){for(var s,r=1;r>0;){var o="top"===e||"bottom"===e?t.gridX:"left"===e?t.gridX-r:t.gridX+r,a="right"===e||"left"===e?t.gridY:"top"===e?t.gridY-r:t.gridY+r;if((s=this.gridCollection[parseInt(o.toString(),10)][parseInt(a.toString(),10)])&&(i&&-1===this.sourceGridCollection.indexOf(s)||!i&&-1===this.targetGridCollection.indexOf(s))){if(this.isWalkable(o,a))break;var l=this.gridCollection[parseInt(o.toString(),10)][parseInt(a.toString(),10)];this.considerWalkable.push(l)}if(!(o>0&&a>0))break;"top"===e||"left"===e?r--:r++}return null},n.prototype.isWalkable=function(t,e,i){if(t>=0&&t=0&&e0?1:-1,this.isWalkable(h,c-1)&&!this.isWalkable(h-a,c-1)||this.isWalkable(h,c+1)&&!this.isWalkable(h-a,c+1)))return{x:t,y:e};if(0!==l){if(l=l>0?1:-1,this.isWalkable(h-1,c)&&!this.isWalkable(h-1,c-l)||this.isWalkable(h+1,c)&&!this.isWalkable(h+1,c-l))return{x:t,y:e};if(this.findIntermediatePoints(h+1,c,h,c,s,o)||this.findIntermediatePoints(h-1,c,h,c,s,o))return{x:t,y:e}}return this.findIntermediatePoints(h+a,c+l,h,c,s,o)},n.prototype.destroy=function(){},n.prototype.getModuleName=function(){return"LineRouting"},n}(),Joe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),eae=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Joe(t,n),function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);r>3&&s&&Object.defineProperty(t,e,s)}([I(!0)],t.prototype,"inversedAlignment",void 0),t}(Ee),tae=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Oe=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},ET=function(n,t,e,i){return new(e||(e=Promise))(function(r,s){function o(h){try{l(i.next(h))}catch(c){s(c)}}function a(h){try{l(i.throw(h))}catch(c){s(c)}}function l(h){h.done?r(h.value):new e(function(c){c(h.value)}).then(o,a)}l((i=i.apply(n,t||[])).next())})},DT=function(n,t){var i,r,s,o,e={label:0,sent:function(){if(1&s[0])throw s[1];return s[1]},trys:[],ops:[]};return o={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function a(h){return function(c){return function l(h){if(i)throw new TypeError("Generator is already executing.");for(;e;)try{if(i=1,r&&(s=2&h[0]?r.return:h[0]?r.throw||((s=r.return)&&s.call(r),0):r.next)&&!(s=s.call(r,h[1])).done)return s;switch(r=0,s&&(h=[2&h[0],s.value]),h[0]){case 0:case 1:s=h;break;case 4:return e.label++,{value:h[1],done:!1};case 5:e.label++,r=h[1],h=[0];continue;case 7:h=e.ops.pop(),e.trys.pop();continue;default:if(!(s=(s=e.trys).length>0&&s[s.length-1])&&(6===h[0]||2===h[0])){e=0;continue}if(3===h[0]&&(!s||h[1]>s[0]&&h[1]0&&((!s.style||!s.style.fill)&&(o.style.fill="transparent"),(!s.style||!s.style.strokeColor)&&(o.style.strokeColor="transparent")),s.shape&&"UmlActivity"===s.shape.type&&eb(s,o),s.shape&&"SwimLane"===s.shape.type&&aF(s,o),r.nodeDefaults&&Ro(o,s,r.nodeDefaults),r.updateAnnotationText(o.annotations);if(e&&e.connectors)for(a=0;e&&e.connectors&&a0&&0===i.nodes.length)this.clearCollection(),a=!0;else{for(var g=0,v=Object.keys(e.nodes);g0&&0===i.connectors.length)this.clearCollection(!0),a=!0;else{for(var C=0,D=Object.keys(e.connectors);C0){this.renderSelector(!0);break}if(e.selectedItems.constraints){this.renderSelector(!0);break}break;case"snapSettings":this.updateSnapSettings(e);break;case"commandManager":this.initCommands();break;case"layout":o=!0;break;case"segmentThumbShape":this.updateSelector();break;case"dataSourceSettings":this.clear(),"None"===this.layout.type?a=!0:(this.initObjects(),o=!0);break;case"tooltip":i3(this);break;case"rulerSettings":this.updateRulerSettings(e);break;case"layers":this.updateLayer(e);break;case"scrollSettings":this.scrollActions|=da.PropertyChange,this.updateScrollSettings(e),this.scrollActions&=~da.PropertyChange,this.scrollSettings.horizontalOffset=-this.scroller.horizontalOffset||0,this.scrollSettings.verticalOffset=-this.scroller.verticalOffset||0;break;case"locale":e.locale!==i.locale&&(this.realActions|=$i.PreventDataInit,n.prototype.refresh.call(this),this.realActions&=~$i.PreventDataInit);break;case"contextMenuSettings":if(void 0!==e.contextMenuSettings.showCustomMenuOnly&&(this.contextMenuSettings.showCustomMenuOnly=e.contextMenuSettings.showCustomMenuOnly),void 0!==e.contextMenuSettings.show&&(this.contextMenuSettings.show=e.contextMenuSettings.show),e.contextMenuSettings.items){for(var A=e.contextMenuSettings.items,x=0,P=Object.keys(A);x0){for(var N=[],T=O.ports.length-1;T>=0;T--)"LineDistribution"===O.ports[parseInt(T.toString(),10)].id.split("_")[1]&&N.push(O.ports[parseInt(T.toString(),10)]);this.removePorts(O,N)}}for(T=0;T0)for(var ue=0,fe=Object.keys(e.nodes);ue0)for(var De=0,xe=Object.keys(e.connectors);De=0;o--)this.commandHandler.expandNode(r[parseInt(o.toString(),10)],this,0!==o);this.canLayout&&this.doLayout(),this.lineRoutingModule?this.connectors.sourceID!==this.connectors.targetID&&this.lineRoutingModule.lineRouting(this):this.constraints&nt.LineRouting&&console.warn('[WARNING] :: Module "LineRouting" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),this.validatePageSize(),this.renderPageBreaks(),this.diagramRenderer.renderSvgGridlines(this.snapSettings,Fd(this.element.id),this.scroller.transform,this.rulerSettings,this.hRuler,this.vRuler),this.commandHandler.initSelectorWrapper(),this.notify("initial-load",{}),this.trigger("load"),this.scroller.setSize(),this.scroller.updateScrollOffsets(),this.isRefreshed||this.refreshDiagramLayer(),(this.scrollSettings.verticalOffset>0||this.scrollSettings.horizontalOffset>0)&&this.updateScrollOffset(),X.isDevice&&(this.tool=ni.ZoomPan|ni.SingleSelect),this.notify("initial-end",{}),this.isProtectedOnChange=!1,this.tooltipObject=i3(this),this.diagramActions=ee.Render,this.initCommands();var a=document.getElementsByClassName(this.element.id+"_hiddenUserHandleTemplate");(function Moe(n,t,e,i){var r,s,o,a,l,d=document.getElementById(i).ej2_instances[0];if(n&&t){r=UF(n);for(var u=0,f=e.userHandles;u0;)e[0].parentNode.removeChild(e[0]);var i=document.getElementById(this.element.id+"content");i&&this.element.removeChild(i);var r="measureElement";if(window[""+r]){window[""+r].usageCount-=1;var s="measureElementCount";window[""+s]--,0===window[""+s]&&(window[""+r].parentNode.removeChild(window[""+r]),window[""+r]=null)}}window.domTable={};for(var a=0;a1&&(this.callBlazorModel=!1,this.insertBlazorDiagramObjects(this.selectedItems),this.commandHandler.group(),this.callBlazorModel=!0,this.commandHandler.getBlazorOldValues())},t.prototype.unGroup=function(){this.callBlazorModel=!1,this.insertBlazorDiagramObjects(this.selectedItems),this.commandHandler.unGroup(),this.callBlazorModel=!0,this.commandHandler.getBlazorOldValues()},t.prototype.sendToBack=function(){this.commandHandler.sendToBack()},t.prototype.setActiveLayer=function(e){var i=this.commandHandler.getLayer(e);this.activeLayer=i},t.prototype.addLayer=function(e,i){this.commandHandler.addLayer(e,i)},t.prototype.removeLayer=function(e){this.commandHandler.removeLayer(e,ce())},t.prototype.moveObjects=function(e,i){$(this.layers),this.enableServerDataBinding(!1),this.commandHandler.moveObjects(e,i)},t.prototype.layerObjectUpdate=function(){},t.prototype.sendLayerBackward=function(e){this.layerObjectUpdate(),this.commandHandler.sendLayerBackward(e)},t.prototype.bringLayerForward=function(e){this.layerObjectUpdate(),this.commandHandler.bringLayerForward(e)},t.prototype.cloneLayer=function(e){this.commandHandler.cloneLayer(e)},t.prototype.bringToFront=function(){this.commandHandler.bringToFront()},t.prototype.moveForward=function(){this.commandHandler.sendForward()},t.prototype.sendBackward=function(){this.commandHandler.sendBackward()},t.prototype.getObject=function(e){return this.nameTable[""+e]},t.prototype.getNodeObject=function(e){return $(this.nameTable[""+e])},t.prototype.getConnectorObject=function(e){return $(this.nameTable[""+e])},t.prototype.getActiveLayer=function(){return this.activeLayer},t.prototype.nudgeCommand=function(e,i,r){if("object"!=typeof e&&(this.selectedItems.nodes.length||this.selectedItems.connectors.length)>0){var s=void 0;i.type&&"KEYDOWN"===i.type&&(s=i.type),this.nudge(e,void 0,void 0,s)}},t.prototype.nudge=function(e,i,r,s){var o=0,a=0;"Left"===e||"Right"===e?o=("Left"===e?-1:1)*(i||1):a=("Up"===e?-1:1)*(r||1),"KEYDOWN"===s&&(o*=5,a*=5);var h=this.selectedItems,c=this.selectedItems.wrapper.children[0];if(c instanceof li)this.commandHandler.labelDrag(h.nodes[0],c,o,a);else{var d=$(this.selectedItems);this.protectPropertyChange(!0),this.drag(h,o,a),this.protectPropertyChange(!1);var u={type:"PositionChanged",redoObject:$(this.selectedItems),undoObject:d,category:"Internal"};this.addHistoryEntry(u)}this.refreshCanvasLayers()},t.prototype.insertBlazorDiagramObjects=function(e){},t.prototype.drag=function(e,i,r){if(this.insertBlazorDiagramObjects(e),!(this.bpmnModule&&e instanceof te&&this.bpmnModule.updateAnnotationDrag(e,this,i,r))){if(e instanceof ei){if(this.preventConnectorsUpdate=!0,e.nodes&&e.nodes.length){for(var o=0,a=e.nodes;o0&&o.nodes[0].children){this.fromUndo||(this.rotateUsingButton=!0);for(var h=this.commandHandler.getAllDescendants(o.nodes[0],[]),c=0;c0&&o.nodes[0].children){var g={type:"RotationChanged",redoObject:$(e),undoObject:$(o),category:"Internal",childTable:a};this.commandHandler.addHistoryEntry(g),this.commandHandler.updateSelector()}return u},t.prototype.dragSourceEnd=function(e,i,r){this.insertBlazorDiagramObjects(e),this.commandHandler.dragSourceEnd(e,i,r),this.callBlazorModel&&this.commandHandler.getBlazorOldValues()},t.prototype.dragTargetEnd=function(e,i,r){this.insertBlazorDiagramObjects(e),this.commandHandler.dragTargetEnd(e,i,r),this.callBlazorModel&&this.commandHandler.getBlazorOldValues()},t.prototype.findObjectsUnderMouse=function(e,i){return this.eventHandler.findObjectsUnderMouse(e,i)},t.prototype.findObjectUnderMouse=function(e,i,r){return this.eventHandler.findObjectUnderMouse(e,i,r)},t.prototype.findTargetObjectUnderMouse=function(e,i,r,s,o){return this.eventHandler.findTargetUnderMouse(e,i,r,s,o)},t.prototype.findElementUnderMouse=function(e,i,r,s){return this.eventHandler.findElementUnderMouse(e,i,r,s)},t.prototype.findActionToBeDone=function(e,i,r,s){return this.eventHandler.findActionToBeDone(e,i,r,s)},t.prototype.updateConnectorPort=function(e){if(e.ports.length)for(var i=void 0,r=0,s=e.ports;r=0;s--)if(i.push(r[parseInt(s.toString(),10)]),i.length>this.historyManager.stackLimit)return i}else i=r;return i},t.prototype.getEdges=function(e){return e.outEdge?this.nameTable[e.id].outEdges:this.nameTable[e.id].inEdges},t.prototype.getParentId=function(e){return this.nameTable[""+e].parentId},t.prototype.addConnector=function(e){return this.add(e)},t.prototype.UpdateBlazorDiagramModelCollection=function(e,i,r,s){},t.prototype.UpdateBlazorDiagramModel=function(e,i,r,s){},t.prototype.UpdateBlazorLabelOrPortObjects=function(e,i,r,s){},t.prototype.addBlazorDiagramObjects=function(){},t.prototype.removeNodeEdges=function(e,i,r){var s=this.nameTable[""+e],o=r?s.outEdges:s.inEdges;if(o.length>0)for(var a=0;a0)){for(var c=0;c0))}this.removePortEdges(l,a.element.sourcePortID,a.element.id,h)}a.element.targetID&&this.removeNodeEdges(a.element.targetID,a.element.id,!1)}}this.diagramActions=this.diagramActions|ee.PublicMethod,e.id=e.id||Qe();var u=this.activeLayer;if(!a.cancel&&u&&!u.lock){if(u.objects.indexOf(e.id)<0&&!u.lock&&(u.visible||(u.visible=!0,this.dataBind()),u.objects.push(e.id)),ps(e)===de)(r=new de(this,"connectors",e,!0)).status="New",this.nameTable[r.targetID]&&"TextAnnotation"===this.nameTable[r.targetID].shape.shape&&(r.isBpmnAnnotationConnector=!0,r.constraints=r.constraints&~qe.Delete),Ro(r,e,this.connectorDefaults),this.connectors.push(r),this.initObject(r),!1===e.visible&&this.updateElementVisibility(r.wrapper,r,e.visible),this.updateEdges(r),this.insertBlazorConnector(r);else{if(Ro(r=new te(this,"nodes",e,!0),e,this.nodeDefaults),r.parentId=e.parentId?e.parentId:r.parentId,r.umlIndex=e.umlIndex,r.status="New",(o="TextAnnotation"===r.shape.shape)&&!e.isTextAnnotationCopied&&(r.inEdges=e.inEdges?e.inEdges:r.inEdges),this.nodes.push(r),this.initObject(r,u,void 0,i),o&&this.bpmnModule)for(c=0;c-1&&e.parentId&&this.nameTable[e.parentId]&&"UmlClassifier"===this.nameTable[e.parentId].shape.type){var g=this.nameTable[e.parentId];g.children.splice(r.umlIndex,0,r.id),g.wrapper.children.splice(r.umlIndex,0,r.wrapper),g.wrapper.measure(new me),g.wrapper.arrange(g.wrapper.desiredSize),this.updateDiagramObject(g)}}if(a={element:r,cause:this.diagramActions,diagramAction:this.getDiagramAction(this.diagramActions),state:"Changed",type:"Addition",cancel:!1},this.parentObject&&(a.parentId=this.parentObject.id),"helper"!==e.id&&!(this.diagramActions&ee.PreventCollectionChangeOnDragOver)&&this.triggerEvent(Ce.collectionChange,a),!(this.diagramActions&ee.UndoRedo||this.diagramActions&ee.Group||this.diagramActions&ee.PreventHistory)){var v={type:"CollectionChanged",changeType:"Insert",undoObject:$(e),redoObject:$(e),category:"Internal"};this.addHistoryEntry(v)}this.parentObject=void 0,"SVG"===this.mode&&(this.updateSvgNodes(r),this.updateTextElementValue(r),this.updateDiagramObject(r),o&&this.updateDiagramObject(this.nameTable[r.inEdges[0]]),r.shape.activity&&r.shape.activity.subProcess.processes&&r.shape.activity.subProcess.processes.length&&this.updateProcesses(r),this.updateBridging())}}if(this.protectPropertyChange(s),this.resetDiagramActions(ee.PublicMethod),r&&this.layers.length>1&&this.moveNode(r),this.views)for(var S=0,b=this.views;S=0;l--)this.moveSvgNode(a[parseInt(l.toString(),10)])}for(var h=0,c=i;h=0;o--)r[parseInt(o.toString(),10)]===e.id&&r.splice(o,1);for(var a=0;s.ports&&a=0;s--)if(i=this.nameTable[r[parseInt(s.toString(),10)]])if(this.connectorTable[i.id]=$(i),i.isBpmnAnnotationConnector){var o=this.nameTable[i.targetID];this.removeObjectsFromLayer(i);var a=this.connectors.indexOf(i);-1!==a&&this.connectors.splice(a,1),this.removeElements(i),this.removeFromAQuad(i),delete this.nameTable[i.id];var l=this.nameTable[i.sourceID];if(l){var h=l.outEdges.indexOf(i.id);-1!==h&&l.outEdges.splice(h,1)}e.id!==i.targetID&&this.remove(o)}else this.remove(i)},t.prototype.removeObjectsFromLayer=function(e){if(e.children)for(var i=0;i-1&&(_r(this,e)&&this.unSelect(e),this.layers[parseInt(s.toString(),10)].objects.splice(a,1),delete this.layers[parseInt(s.toString(),10)].zIndexTable[this.nameTable[e.id].zIndex])},t.prototype.removeElements=function(e){if("SVG"===this.mode||"Canvas"===this.mode&&"Native"===e.shape.type){var i=xt(e.id+"_groupElement",this.element.id),r=e;if(r.ports&&r.ports.length>0)for(var s=0;s0){l[parseInt(s.toString(),10)].id.indexOf("icon_content")>0&&"SVG"===this.mode&&((h=xt(l[parseInt(s.toString(),10)].id+"_shape_groupElement",this.element.id))&&h.parentNode.removeChild(h),(h=xt(l[parseInt(s.toString(),10)].id+"_rect_groupElement",this.element.id))&&h.parentNode.removeChild(h));for(var c=0,d=this.views;c=0;o--)a.children[parseInt(o.toString(),10)].children&&(l=n.nameTable[a.children[parseInt(o.toString(),10)].id])&&(l.isLane?qv(n,l):(n.removeDependentConnector(l),n.diagramActions|=ee.PreventHistory,l.constraints&ie.Delete?n.remove(l):V3(n,l,{},!1),n.diagramActions&=~ee.PreventHistory));a&&(i=n.nameTable[a.id])&&qv(n,i)}}(this,e),!(this.diagramActions&ee.UndoRedo||this.diagramActions&ee.PreventHistory)&&(e instanceof te||e instanceof de)){var o={type:"CollectionChanged",changeType:"Remove",undoObject:$(e),redoObject:$(e),category:"Internal"};this.diagramActions&ee.Clear||e.children&&!e.isLane&&!e.isPhase&&e.children.length>0&&this.undoRedoModule&&"None"===this.layout.type&&(this.historyManager.startGroupAction(),s=!0),(e instanceof te||e instanceof de)&&this.deleteDependentConnector&&this.removeDependentConnector(e),!e.isLane&&!e.isPhase&&!(this.diagramActions&ee.Clear)&&!this.isStackChild(e)&&this.addHistoryEntry(o)}"TextAnnotation"===e.shape.shape&&this.removeDependentConnector(e),e.children&&!e.isLane&&!e.isPhase&&(!(this.diagramActions&ee.UndoRedo)||!ce())&&this.deleteGroup(e),e.parentId&&(this.deleteChild(e,void 0,!0),this.nameTable[e.parentId]&&"UmlClassifier"===this.nameTable[e.parentId].shape.type&&(this.updateDiagramObject(this.nameTable[e.parentId]),this.updateConnectorEdges(this.nameTable[e.parentId])));var a=void 0;this.diagramActions=this.diagramActions|ee.PublicMethod;var l=this.nameTable[e.id];if(l instanceof te?("Bpmn"===l.shape.type&&this.bpmnModule&&this.bpmnModule.removeBpmnProcesses(l,this),(l.isLane||l.isPhase||"SwimLane"===l.shape.type)&&(h=l.isLane||l.isPhase?this.nameTable[l.parentId]:this.nameTable[l.id],l.isLane?_3(this,l,h):l.isPhase&&U3(this,l,h)),-1!==(a=this.nodes.indexOf(l))&&(this.crudDeleteNodes.push(this.nameTable[l.id]),this.nodes.splice(a,1),this.updateNodeEdges(l))):(-1!==(a=this.connectors.indexOf(l))&&(this.crudDeleteNodes.push(this.nameTable[l.id]),this.connectors.splice(a,1)),this.updateEdges(l),this.spliceConnectorEdges(e,!0),this.spliceConnectorEdges(e,!1)),!this.isServerUpdate&&!(this.blazorActions&on.GroupClipboardInProcess)&&this.commandHandler.getBlazorOldValues(),s&&this.historyManager.endGroupAction(),_r(this,l)&&this.unSelect(l),!l.isPhase){if(this.removeObjectsFromLayer(e),this.currentDrawingObject&&(this.currentDrawingObject.wrapper=void 0),delete this.nameTable[e.id],i.length>0&&i[0].id===l.id&&l.parentId){var h,d=this.nameTable[l.parentId];d&&d.isLane&&"SwimLane"===this.nameTable[d.parentId].shape.type&&F3(this,h=this.nameTable[d.parentId],d,l)}this.removeElements(l),this.updateBridging(),"SVG"!==this.mode&&this.refreshDiagramLayer(),this.diagramActions&ee.Clear||(this.removeFromAQuad(l),r={element:e,cause:this.diagramActions,diagramAction:this.getDiagramAction(this.diagramActions),state:"Changed",type:"Removal",cancel:!1},"helper"!==e.id&&this.triggerEvent(Ce.collectionChange,r),this.resetTool())}}}else if(i.length>0){this.undoRedoModule&&(this.historyManager.startGroupAction(),this.blazorActions|=on.GroupingInProgress,s=!0);for(var u=0;u=p.wrapper.bounds.width&&"Horizontal"===p.shape.orientation||this.selectedItems.wrapper.bounds.y<=p.wrapper.bounds.y+g&&this.selectedItems.wrapper.bounds.height>=p.wrapper.bounds.height-g&&"Vertical"===p.shape.orientation)&&(LI(p)||p.shape.lanes.length>1)&&this.remove(i[parseInt(u.toString(),10)])}}else this.remove(i[parseInt(u.toString(),10)])}s&&(this.blazorActions&=~on.GroupingInProgress,this.isServerUpdate=!0,this.commandHandler.getBlazorOldValues(),this.UpdateBlazorDiagramModelCollection(void 0,void 0,void 0,!0),this.historyManager.endGroupAction(),this.isServerUpdate=!1),this.clearSelection()}e&&(LI(e)||this.diagramActions&ee.Clear)||this.diagramActions&ee.UndoRedo||this.diagramActions&ee.PreventHistory||!(e instanceof te||e instanceof de)||(o={type:"ConnectionChanged",undoObject:$(e),redoObject:$(e),category:"Internal"},!e.isLane&&!e.isPhase&&!(this.diagramActions&ee.Clear)&&!this.isStackChild(e)&&this.addHistoryEntry(o)),this.tooltipObject.close()},t.prototype.isStackChild=function(e){var i,r=this.nameTable[e.parentId];if(e&&e.parentId&&r.container&&"Stack"===r.container.type&&"UmlClassifier"!==this.nameTable[e.parentId].shape.type){i=!0;var s={sourceIndex:r.wrapper.children.indexOf(e.wrapper),source:e,target:void 0,targetIndex:void 0};this.diagramActions&ee.UndoRedo||this.addHistoryEntry({type:"StackChildPositionChanged",redoObject:{sourceIndex:void 0,source:e,target:void 0,targetIndex:void 0},undoObject:s,category:"Internal"})}return i},t.prototype.deleteChild=function(e,i,r){var s;if(s="string"==typeof e?e:e.id,(i=i?this.nameTable[i.id]:this.nameTable[e.parentId])&&i.children){for(var o=0;o=0;i--)this.removeLayer(this.layers[parseInt(i.toString(),10)].id);this.commandHandler.addLayer({id:"default_layer",visible:!0,lock:!1,objects:[],zIndex:0,objectZIndex:-1,zIndexTable:{}},null,!0),this.setActiveLayer(this.layers[this.layers.length-1].id)},t.prototype.clearObjects=function(e){var i=[];i=e||(i=i.concat(this.nodes)).concat(this.connectors),this.diagramActions=this.diagramActions|ee.Clear;for(var r=0,s=i;r0||"Text"===e.shape.type))if("Text"===e.shape.type)i=e.wrapper.children[0].id.split("_")[1];else for(var p=e.annotations.length-1;p>=0;p--)e.annotations[parseInt(p.toString(),10)].visibility&&(i=e.annotations[parseInt(p.toString(),10)].id);i&&(u=this.getWrapper(e.wrapper,i))}if(e&&u&&!(u instanceof es)&&(!function $re(n,t){return"Text"===t.shape.type?t.constraints&ie.ReadOnly:t.constraints&(t instanceof de?qe.ReadOnly:ie.ReadOnly)?n.constraints&Nr.InheritReadOnly?1:0:n.constraints&Nr.ReadOnly?1:0}(u,e)||f)){var g=u.style,v=void 0;v=90>(v=u.bounds.width50?50:e.width,u.style.fontSize)),e.parentId&&"UmlClassifier"===this.nameTable[e.parentId].shape.type?(l.width=e.wrapper.bounds.width-20,c=(e.wrapper.bounds.center.x+r.tx)*r.scale-l.width/2*s-2.5,d=(e.wrapper.bounds.center.y+r.ty)*r.scale-l.height/2*s-3,u.style.textAlign="Left"):(l.width=Math.max(l.width,50),c=(u.bounds.center.x+r.tx)*r.scale-l.width/2*s-2.5,d=(u.bounds.center.y+r.ty)*r.scale-l.height/2*s-3),Ho(y,{id:this.element.id+"_editTextBoxDiv",style:"position: absolute;left:"+c+"px;top:"+d+"px;width:"+(l.width+1)*s+"px;height:"+l.height*s+"px; containerName:"+e.id+";"}),Ho(S,{"aria-label":a,id:this.element.id+"_editBox",style:"width:"+(l.width+1)*s+"px;height:"+l.height*s+"px;resize: none;outline: none;overflow: hidden;;font-family:"+g.fontFamily+";font-size:"+g.fontSize*s+"px;text-align:"+u.style.textAlign.toLocaleLowerCase()+";",class:"e-diagram-text-edit"}),S.style.fontWeight=g.bold?"bold":"",S.style.fontStyle=g.italic?"italic":"",S.style.lineHeight=(1.2*g.fontSize+"px;").toString(),S.style.textDecoration=g.textDecoration?g.textDecoration:"",this.activeLabel.parentId=e.id,this.activeLabel.id=i,u.visible=!1,this.updateDiagramObject(e),this.diagramActions=this.diagramActions|ee.TextEdit,this.isTriggerEvent||(E.add(S,"input",this.eventHandler.inputChange,this.eventHandler),E.add(S,"focusout",this.focusOutEdit,this),S.select())}}}},t.prototype.updateConnectorfixedUserHandles=function(e){if(e.fixedUserHandles.length)for(var i=void 0,r=0,s=e.fixedUserHandles;r0&&this.mindMapChartModule.updateLayout(o,this.nameTable,this.layout,l,this.dataSourceSettings.id,this.dataSourceSettings.root),e=!0;else if(this.radialTreeModule)this.radialTreeModule.updateLayout(o,this.nameTable,this.layout,l),e=!0;else if(this.symmetricalLayoutModule)this.symmetricalLayoutModule.maxIteration=this.layout.maxIteration,this.symmetricalLayoutModule.springLength=this.layout.springLength,this.symmetricalLayoutModule.springFactor=this.layout.springFactor,this.symmetricalLayoutModule.updateLayout(o,this.connectors,this.symmetricalLayoutModule,this.nameTable,this.layout,l),e=!0;else if(this.complexHierarchicalTreeModule){this.canDistribute(a,r)&&(this.lineDistributionModule.diagram=this,this.connectors.forEach(function(P){P.obstaclePointCollection=[]}));var c=this.complexHierarchicalTreeModule.getLayoutNodesCollection(this.nodes);c.length>0&&this.complexHierarchicalTreeModule.doLayout(c,this.nameTable,this.layout,l,this),e=!0,this.canDistribute(a,r)&&this.lineDistributionModule.initLineDistribution(this.layout,this)}else this.flowchartLayoutModule?(this.flowchartLayoutModule.updateLayout(this.nodes,this),e=!0):console.warn("[WARNING] :: Module "+("OrganizationalChart"===this.layout.type?"HierarchicalTree":this.layout.type)+" is not available in Diagram component! You either misspelled the module name or forgot to load it.");if(e){this.preventDiagramUpdate=!0;for(var u={},p=0,g=o;p0)for(var S=0;S0)for(var M=0;M0)for(var s=0,o=r.ports;s0&&function xse(n){var t,e,i,r=[];for(t=0;t0&&y.connectors[w].bezierSettings&&y.connectors[w].bezierSettings.allowSegmentsReset&&(y.connectors[w].segments=[]);if(t.connectors=y.connectors||[],t.dataSourceSettings=y.dataSourceSettings||{},t.dataSourceSettings.doBinding=i,t.height=y.height||"100%",t.setNodeTemplate=r,t.getConnectorDefaults=v,t.getNodeDefaults=g,t.getCustomProperty=o,t.mode=y.mode||"SVG",y.nodes)for(w=0;w0)){var r=this.nodes.filter(function(a){return 0===a.inEdges.length})[0],s=this.convertMindmapToMermaid(r,0);i.push(s),this.updateTextDataSource(i,r.outEdges,1),e=(i=i.filter(function(a){return""!==a.trim()})).join("\n")}return e},t.prototype.updateTextDataSource=function(e,i,r){for(var s=0;s0&&this.updateTextDataSource(e,h,r+1),s++}},t.prototype.convertMindmapToMermaid=function(e,i){var r=e.id,o=" ".repeat(2*(i+1)),a=e.annotations.length>0?e.annotations[0].content.replace(/\n/g," "):"",l=o+a,h=o+r;if(e.shape&&"Basic"===e.shape.type){var c=e.shape;"Rectangle"===c.shape?l=h+"["+a+"]":"Ellipse"===c.shape?l=h+"(("+a+"))":"Hexagon"===c.shape&&(l=h+"{{"+a+"}}")}else if(e.shape&&"Flow"===e.shape.type)"Terminator"===e.shape.shape&&(l=h+"("+a+")");else if(e.shape&&"Path"===e.shape.type){var u=e.shape;u.data===this.bangShape?l=h+"))"+a+"((":u.data===this.cloudShape&&(l=h+")"+a+"(")}return l},t.prototype.saveFlowDiagramInMermaidFormat=function(){var e=this,i=[],r="graph TD\n",s={nodes:this.nodes,edges:this.connectors};return s.nodes.reduce(function(a,l){return a[l.id]=l.annotations.length?l.annotations[0].content:"",a},{}),s.edges.forEach(function(a){var l=a.sourceID,h=a.targetID,f=e.nameTable[""+h],p=e.getNodeShape(e.nameTable[""+l]),g=e.getNodeShape(f),v=a.annotations[0]&&""!==a.annotations[0].content?"|"+a.annotations[0].content+"|":"";-1===i.indexOf(l)?i.push(l):p="",-1===i.indexOf(h)?i.push(h):g="";var y=e.arrowType(a);r+=" "+l+p+" "+y+v+" "+h+g+"\n"}),s.nodes.forEach(function(a){r+=" style "+a.id+" fill:"+a.style.fill+",stroke:"+a.style.strokeColor+",stroke-width:"+a.style.strokeWidth+"px;\n"}),r},t.prototype.arrowType=function(e){var i=e.targetDecorator.shape;return e.style.opacity<1?"~~~":""!==e.style.strokeDashArray?"-.->":"Arrow"===i?e.style.strokeWidth>1?"==>":"--\x3e":"None"===i?"---":"--\x3e"},t.prototype.getNodeShape=function(e){var i=e.annotations.length>0?e.annotations[0].content:"",r=e.shape.shape;if(!r){var s=e.shape.data;return"M 0 0 A 1 1 0 0 0 7 0 A 1 1 0 0 0 0 0 M -1 0 A 1 1 0 0 0 8 0 A 1 1 0 0 0 -1 0"===s?"((("+i+")))":"M 0 0 L 1 -1 L 5 -1 L 6 0 L 0 0"===s?"[/"+i+"\\]":"M 0 1 L 0 6 C 2 7 4 7 6 6 L 6 1 C 5 0 1 0 0 1 C 1 2 5 2 6 1"===s?"[("+i+")]":"M 0 0 L 12 0 L 14 2 L 2 2 L 0 0"===s?"[\\"+i+"\\]":"M 0 0 L 5 0 L 4 1 L 1 1 L 0 0"===s?"[\\"+i+"/]":"M 0 0 L 2 -2 L 11 -2 L 13 0 L 11 2 L 2 2 L 0 0"===s?"{{"+i+"}}":">"+i+"]"}switch(r){case"Terminator":return"(["+i+"])";case"Process":default:return"["+i+"]";case"Decision":return"{"+i+"}";case"Parallelogram":return"[/"+i+"/]";case"Ellipse":return"(("+i+"))";case"PreDefinedProcess":return"[["+i+"]]"}},t.prototype.loadDiagramFromMermaid=function(e){this.layout&&"Flowchart"===this.layout.type&&this.flowchartLayoutModule?this.convertMermaidToFlowChart(e):this.layout&&"MindMap"===this.layout.type&&this.mindMapChartModule?this.convertMermaidToMindmap(e):console.warn('[WARNING] :: Module "FlowchartLayout" or "MindMap" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.countLeadingSpaces=function(e){for(var i=0,r=e.length;i0});this.clear(),this.mermaidNodeBaseCollection=[];var r=[],s={text:"",children:[],currentLevel:0,branch:"Left"},o=[],l=!1,h=!1,c=!1;if(i.length>0){for(var d=function(M){var w=i[parseInt(M.toString(),10)],C=0,D="",A=u.countLeadingSpaces(w),x=w.includes('"`');if(h=w.includes('`"'),c=(l=!!x||l)||c?c:0===A&&M>0,l&&h&&!x)return s.text+="\n"+w,l=!1,"continue";if(!x&&l)return s.text+="\n"+w,"continue";if(l=!h&&l,w.length>0&&(/\s/.test(w[0])&&M>0||0===A)){if(-1!==o.findIndex(function(B){return B.space===A.toString()}))for(var L=o.length-1;L>=0;L--){var O=o[parseInt(L.toString(),10)];if((N=parseFloat(O.space))>A)o.splice(L,1);else{if(N=0;L--){var N,T=o[parseInt(L.toString(),10)];if(!((N=parseFloat(T.space))>A)){var z=o[o.length-1];o.push({space:A.toString(),level:z.level+1});break}o.splice(L,1)}C=o[o.length-1].level}D=w.trim().replace(/^[+-]/,"")}var U={text:D,branch:void 0,children:[],currentLevel:0===M?0:C-1};if(r.length>0){for(;r.length>=C&&0!==r.length;)r.pop();r.length>0&&r[r.length-1].children.push(U)}r.push(U),s=U},u=this,f=0;f0){var c=h[h.length-1];c.arrowType=a[2],""!==a[3]&&(c.label&&c.label.some(function(d){return d.trim().length>0})?c.label.push(a[3]):(c.label=[],c.label[c.parentId.length-1]=a[3]))}h.filter(function(d){return d.parentId&&0===d.parentId.length}).forEach(function(d){d.parentId=null}),i=i.concat(h)}}this.createFlowChart(i),this.doLayout(),this.clearHistory()},t.prototype.createFlowChart=function(e){for(var i=[],r=0;r1)for(var h=0;h|---|--\s*.*?\s*-->|~~~|==>|===|==\s*.*?\s*==>|\s*-\.\s*->|\s*-\.\s*-|\s*-\.\s*.*?\s*\.\s*->|\s*-\..*?\.\s*->)(.*)$/);if(l){i=l[1].trim();var h=l[2].trim();r=l[3].trim();var d=h.match(/(-\.|\\-\\-|==|--|~~)(.*?)(\1>|\.->|==>|\\->|~~>)/),u=void 0,f="";o=null!==(u=d?{text:d[2].trim()||null,arrowType:d[1]+d[3]}:{text:null,arrowType:h}).text?u.text:"",s=(f=u.arrowType).includes("--\x3e")?"single-line-arrow":f.includes("---")?"single-line":f.includes("==>")?"double-line-arrow":f.includes("==")?"double-line":f.includes("~~~")?"wiggly-arrow":f.includes("-.->")||f.includes(".->")?"dotted-arrow":f.includes("-.-")||f.includes(".-")?"dotted":"single-line-arrow"}return[i,r,s,o]},t.prototype.parseStyle=function(e,i){if(e.startsWith("style")){var s=e.match(/^style\s+(\w+)\s+fill:([^,]+),stroke:([^,]+),stroke-width:(\d+)px;/);if(s){var c={id:s[1],fill:s[2],stroke:s[3],strokeWidth:parseInt(s[4],10)},d=i.filter(function(u){return u.id===c.id});d[0].color=c.fill,d[0].stroke=c.stroke,d[0].strokeWidth=c.strokeWidth}}},t.prototype.getNodeData=function(e,i,r){for(var s=[],o=null,a=null,l=0,h="",c=function(v){var y=e[parseInt(v.toString(),10)],S=d.splitNested(y);if(S[0].includes("|")){var b=S[0].match(/\|([^|]*)\|/);b&&(h=b[1]);var M=S[0].split("|");M.length>=3&&(S[0]=M[2].trim())}var w=S[0].trim();if(0===v?o=w:a=w,i.find(function(L){return L.id===w}))l++;else{var D=S.length>1?S[1]:S[0],A=d.getShape(D),x=D.replace(/[\\[\]\\(\\)\\{\\}\\{\\}\\/>]/g,"");s.push({id:w,name:x,shape:A,color:"white",parentId:[]})}},d=this,u=0;u"===h?0===s?(r.trim().length>0&&i.push(r.trim()),r=h,o=h,s++):(r+=h,s++):"]"===h||"}"===h||")"===h?1===s&&h===o?(i.push((r+=h).trim()),r="",s--):s>1?(r+=h,s--):r+=h:r+=h}return r.trim().length>0&&i.push(r.trim()),i},t.prototype.getShape=function(e){var i={};return e.startsWith("(((")?i={type:"Path",data:"M 0 0 A 1 1 0 0 0 7 0 A 1 1 0 0 0 0 0 M -1 0 A 1 1 0 0 0 8 0 A 1 1 0 0 0 -1 0"}:e.startsWith("((")?i={shape:"Ellipse",type:"Basic"}:e.startsWith("([")?i={type:"Flow",shape:"Terminator"}:e.startsWith("(")?i={type:"Flow",shape:"Process"}:e.startsWith("[[")?i={type:"Flow",shape:"PreDefinedProcess"}:e.startsWith("[/")?i=e.endsWith("/]")?{type:"Basic",shape:"Parallelogram"}:{type:"Path",data:"M 0 0 L 1 -1 L 5 -1 L 6 0 L 0 0"}:e.startsWith("[(")?i={type:"Path",data:"M 0 1 L 0 6 C 2 7 4 7 6 6 L 6 1 C 5 0 1 0 0 1 C 1 2 5 2 6 1"}:e.startsWith("[\\")?i=e.endsWith("\\]")?{type:"Path",data:"M 0 0 L 12 0 L 14 2 L 2 2 L 0 0"}:{type:"Path",data:"M 0 0 L 5 0 L 4 1 L 1 1 L 0 0"}:e.startsWith("[")?i={type:"Basic",shape:"Rectangle"}:e.startsWith("{{")?i={type:"Path",data:"M 0 0 L 2 -2 L 11 -2 L 13 0 L 11 2 L 2 2 L 0 0"}:e.startsWith("{")?i={type:"Flow",shape:"Decision"}:e.startsWith(">")&&(i={type:"Path",data:"M 0 0 L 8 0 L 8 2 L 0 2 L 2 1 L 0 0"}),i},t.prototype.getDiagramContent=function(e){return this.printandExportModule?this.printandExportModule.getDiagramContent(e):(console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),"")},t.prototype.exportImage=function(e,i){this.printandExportModule?this.printandExportModule.exportImages(e,i):console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.printImage=function(e,i){this.printandExportModule?(i.printOptions=!0,this.printandExportModule.exportImages(e,i)):console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.setStackLimit=function(e){this.undoRedoModule&&e&&(this.historyManager.stackLimit=e,this.undoRedoModule.applyLimit(this.historyManager.currentEntry,e,this,!0))},t.prototype.clearHistory=function(){this.undoRedoModule&&this.undoRedoModule.clearHistory(this)},t.prototype.getDiagramBounds=function(){if(this.printandExportModule){var e=this.printandExportModule.getDiagramBounds("",{});return e.width=e.width>this.scrollSettings.viewPortWidth?e.width+(e.x>0?e.x:0):this.scrollSettings.viewPortWidth,e.height=e.height>this.scrollSettings.viewPortHeight?e.height+(e.y>0?e.y:0):this.scrollSettings.viewPortHeight,e.x=e.x>0?0:e.x,e.y=e.y>0?0:e.y,e}return console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),new Ne},t.prototype.exportDiagram=function(e){return this.printandExportModule?this.printandExportModule.exportDiagram(e):(console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),"")},t.prototype.print=function(e){this.printandExportModule?this.printandExportModule.print(e):console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.addPorts=function(e,i){var s;this.protectPropertyChange(!0),e=this.nameTable[e.id]||e,i.length>1&&this.startGroupAction();for(var o=function(h){if(e.ports.some(function(y){return y.id===i[parseInt(h.toString(),10)].id}))return"continue";if(e instanceof te?(s=new Es(e,"ports",i[parseInt(h.toString(),10)],!0),e.ports.push(s)):e instanceof de&&(s=new Tc(e,"ports",i[parseInt(h.toString(),10)],!0),e.ports.push(s)),e.children)for(var c=e.wrapper,d=0;d1&&this.endGroupAction(),e.wrapper.measure(new me(e.width,e.height)),e.wrapper.arrange(e.wrapper.desiredSize),this.updateDiagramObject(e),this.protectPropertyChange(!1)},t.prototype.addConstraints=function(e,i){return e|i},t.prototype.removeConstraints=function(e,i){return e&~i},t.prototype.addNodeLabels=function(e,i){this.addLabels(e,i)},t.prototype.addConnectorLabels=function(e,i){this.addLabels(e,i)},t.prototype.addLabels=function(e,i){this.protectPropertyChange(!0);var s,r=(e=this.nameTable[e.id]||e).wrapper;i.length>1&&this.startGroupAction();for(var o=0;o1&&this.endGroupAction(),e.wrapper.measure(new me(r.width,r.height)),e.wrapper.arrange(r.desiredSize),this.updateDiagramObject(e),this.protectPropertyChange(!1),this.refreshCanvasLayers()},t.prototype.addChildToUmlNode=function(e,i,r){var s,o,a,l,h="NoWrap";"Class"===e.shape.classifier||"Interface"===e.shape.classifier?"Method"===r?(o=new cm(e,"",i),"Class"===e.shape.classifier?(e.shape.classShape.methods.push(o),s=e.shape.classShape):"Interface"===e.shape.classifier&&(e.shape.interfaceShape.methods.push(o),s=e.shape.interfaceShape),function $se(n,t,e,i){if(e.methods&&e.methods.length){var r=e.methods,s="",o="",a=void 0,l=1,h=void 0,c=0,d=0,u=n.shape,g="Class"===u.classifier?u.classShape:u.interfaceShape;1===r.length?g.attributes.length>0?(c=g.attributes.filter(function(w){return w.isSeparator}).length,h=(l=2+g.attributes.length+c)+1,sT(n,t,l)):h=l+1:(c=g.attributes.filter(function(w){return w.isSeparator}).length,d=g.methods.filter(function(w){return w.isSeparator}).length,h=(l=2+g.attributes.length+c+g.methods.length+d)+1);for(var v=0;v1&&this.startGroupAction();for(var r=i.length-1;r>=0;r--)if(e.children&&e.children.length>0){var s=e.wrapper.children.filter(function(o){return o.id===e.id+"group_container"});s&&s.length>0&&this.removelabelExtension(e,i,r,s[0])}else this.removelabelExtension(e,i,r,e.wrapper);i.length>1&&this.endGroupAction(),this.refreshCanvasLayers()},t.prototype.removePortsExtenion=function(e,i,r,s){for(var o=0;o1&&this.startGroupAction();for(var r=i.length-1;r>=0;r--)if(e.children&&e.children.length>0)for(var s=0;s1&&this.endGroupAction()},t.prototype.getSizeValue=function(e,i){var r;return r=e.toString().indexOf("px")>0?e.toString():e.toString().indexOf("%")>0?void 0!==i?"100%":e.toString():e.toString()+"px",i&&(Za(this),r="calc("+r+" - "+i+"px)"),r},t.prototype.renderRulers=function(){this.rulerSettings.showRulers?(function Gne(n){var t=Za(n),i=Tt("div",{id:n.element.id+"_overlapRuler",style:"height:"+t.height+"px;width:"+t.width+"px;position:absolute;left:0;top:0",class:"e-ruler-overlap"});n.element.insertBefore(i,n.element.firstChild)}(this),eF(this,!0),eF(this,!1)):Gx(this)},t.prototype.intOffPageBackground=function(){var e=new me;e=Za(this);var i=document.getElementById(this.element.id+"content"),r=this.getSizeValue(this.width,e.width),s=this.getSizeValue(this.height,e.height),o=this.rulerSettings.showRulers?"width:"+r+"; height:"+s+";top:"+e.height+"px;left:"+e.width+"px;overflow: scroll;position:absolute;overflow:auto;":"width:"+r+"; height:"+s+";position:absolute; left:0px; top:0px;overflow: auto;",a={id:this.element.id+"content",tabindex:"0",style:o};i?(this.diagramCanvas=i,Ka(this.diagramCanvas,o)):(this.diagramCanvas=Tt("div",a),this.element.appendChild(this.diagramCanvas)),this.diagramCanvas.style.background=this.backgroundColor},t.prototype.initDiagram=function(){this.intOffPageBackground(),Ho(this.element,{style:"width:"+this.getSizeValue(this.width)+"; height:"+this.getSizeValue(this.height)+";position:relative;overflow:hidden;"})},t.prototype.renderHiddenUserHandleTemplateLayer=function(e){var r=Tt("div",{class:this.element.id+"_hiddenUserHandleTemplate",style:"width:"+e.width+"px; height:"+e.height+"px;visibility:hidden ; overflow: hidden;"});this.element.appendChild(r)},t.prototype.renderBackgroundLayer=function(e,i){var r=this.createSvg(this.element.id+"_backgroundLayer_svg",e.width,e.height);Ka(r,i);var s=Fi("g",{id:this.element.id+"_backgroundImageLayer",class:"e-background-image-layer"});r.appendChild(s);var a=Fi("g",{id:this.element.id+"_backgroundLayer",class:"e-background-layer"});r.appendChild(a),this.diagramCanvas.appendChild(r)},t.prototype.renderGridLayer=function(e,i){var r=this.createSvg(this.element.id+"_gridline_svg",e.width,e.height);r.setAttribute("class","e-grid-layer");var s=Fi("g",{id:this.element.id+"_gridline"}),o=Fi("rect",{id:this.element.id+"_grid_rect",x:"0",y:"0",width:"100%",height:"100%"});if(sm()){var a=new URL(window.location.href);o.setAttribute("fill",""!==a.search?"url(#"+this.element.id+"_pattern)":"url("+location.protocol+"//"+location.host+location.pathname+"#"+this.element.id+"_pattern)")}else o.setAttribute("fill","url(#"+this.element.id+"_pattern)");s.appendChild(o),r.appendChild(s),this.diagramCanvas.appendChild(r),ti(r,{style:i})},t.prototype.renderDiagramLayer=function(e,i){if(this.diagramLayerDiv=Tt("div",{id:this.element.id+"_diagramLayer_div",style:"width:"+e.width+"px; height:"+e.height+"px;"+i}),"SVG"===this.mode){var s=this.createSvg(this.element.id+"_diagramLayer_svg",e.width,e.height);s.style["pointer-events"]="none",s.setAttribute("class","e-diagram-layer");var o=Fi("g",{id:this.element.id+"_diagramLayer"}),a=Fi("g",{});this.diagramLayer=o,s.style["pointer-events"]="all",a.appendChild(o),s.appendChild(a),this.diagramLayerDiv.appendChild(s)}else this.diagramLayer=bo.createCanvas(this.element.id+"_diagram",e.width,e.height),Ka(this.diagramLayer,"position:absolute;left:0px;top:0px;"),this.diagramLayerDiv.appendChild(this.diagramLayer);this.diagramCanvas.appendChild(this.diagramLayerDiv)},t.prototype.initLayers=function(){var e="position:absolute;top:0px;left:0px;overflow:hidden;pointer-events:none;",r=document.getElementById(this.element.id).getBoundingClientRect(),s=function boe(){var n=Tt("div",{style:"visibility:hidden; width: 100px"});document.body.appendChild(n);var t=n.getBoundingClientRect().width;n.style.overflow="scroll";var e=Tt("div",{style:"width:100%"});n.appendChild(e);var i=e.getBoundingClientRect().width;return n.parentNode.removeChild(n),t-i}();this.scroller.scrollerWidth=s,this.scroller.setViewPortSize(r.width,r.height),this.renderRulers();var o="measureElement";window[""+o]&&(window[""+o]=null,document.getElementById("measureElement").remove()),function BF(){var n="measureElement";if(window[""+n])window[""+n].usageCount+=1;else{var t=Tt("div",{id:"measureElement",style:"visibility:hidden ; height: 0px ; width: 0px; overflow: hidden;"}),e=Tt("span",{style:"display:inline-block ; line-height: normal"});t.appendChild(e);var i=Tt("img",{alt:"measureElementImage",src:"data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7"});t.appendChild(i);var r=document.createElementNS("http://www.w3.org/2000/svg","svg");r.setAttribute("xmlns:xlink","http://www.w3.org/1999/xlink"),t.appendChild(r);var s=document.createElementNS("http://www.w3.org/2000/svg","path");s.setAttribute("d",""),r.appendChild(s),document.createTextNode("");var a=document.createElementNS("http://www.w3.org/2000/svg","text");a.setAttributeNS("http://www.w3.org/XML/1998/namespace","xml:space","preserve"),r.appendChild(a),window[""+n]=t,window[""+n].usageCount=1,document.body.appendChild(t);var l="measureElementCount";window[""+l]?window[""+l]++:window[""+l]=1}}(),this.renderBackgroundLayer(r,e),this.renderGridLayer(r,e),this.renderDiagramLayer(r,e),this.renderHTMLLayer(r,e),this.renderPortsExpandLayer(r,e),this.renderNativeLayer(r,e),this.renderAdornerLayer(r,e),this.renderHiddenUserHandleTemplateLayer(r)},t.prototype.renderAdornerLayer=function(e,i){var r=Tt("div",{id:this.element.id+"_diagramAdornerLayer",style:"width:"+e.width+"px;height:"+e.height+"px;"+i}),s=Tt("div",{id:this.element.id+"_diagramUserHandleLayer",style:"width:"+e.width+"px;height:"+e.height+"px;"+i});s.setAttribute("class","e-userHandle-layer"),r.appendChild(s);var o=this.createSvg(this.element.id+"_diagramAdorner_svg",e.width,e.height);o.setAttribute("class","e-adorner-layer"),o.style["pointer-events"]="none",this.adornerLayer=Fi("g",{id:this.element.id+"_diagramAdorner"}),this.adornerLayer.style[" pointer-events"]="all",o.appendChild(this.adornerLayer),r.appendChild(o),this.diagramCanvas.appendChild(r);var a=Fi("g",{id:this.element.id+"_SelectorElement"});this.adornerLayer.appendChild(a),ti(o,{style:"pointer-events:none;"})},t.prototype.renderPortsExpandLayer=function(e,i){var r=this.createSvg(this.element.id+"_diagramPorts_svg",e.width,e.height);r.setAttribute("class","e-ports-expand-layer");var s=Fi("g",{id:this.element.id+"_diagramPorts",class:"e-ports-layer",style:"pointer-events: all;"});r.appendChild(s);var o=Fi("g",{id:this.element.id+"_diagramExpander",class:"e-expand-layer",style:"pointer-events: all;"});r.appendChild(o),this.diagramCanvas.appendChild(r),ti(r,{style:i})},t.prototype.renderHTMLLayer=function(e,i){this.htmlLayer=Tt("div",{id:this.element.id+"_htmlLayer",style:"width:"+e.width+"px; height:"+e.height+"px;position:absolute;top:0px;left:0px;overflow:hidden;pointer-events:none;",class:"e-html-layer"});var r=Tt("div",{id:this.element.id+"_htmlLayer_div",style:"position:absolute;top:0px;left:0px;pointer-events:all;"});this.htmlLayer.appendChild(r),this.diagramCanvas.appendChild(this.htmlLayer)},t.prototype.renderNativeLayer=function(e,i){var r=this.createSvg(this.element.id+"_nativeLayer_svg",e.width,e.height),s=Fi("g",{id:this.element.id+"_nativeLayer",style:"pointer-events:all;"});r.appendChild(s),this.diagramLayerDiv.appendChild(r),ti(r,{class:"e-native-layer",style:i})},t.prototype.createSvg=function(e,i,r){var s=document.createElementNS("http://www.w3.org/2000/svg","svg");return ti(s,{id:e,width:i,height:r}),s},t.prototype.updateBazorShape=function(){for(var e=0;e1,i=[],r={},s={},o=[],a=0,l=this.nodes;a0||b&&b.children&&b.children.length>0)&&(M=!1),S&&S.wrapper&&b&&b.wrapper&&M?this.initConnectors(r[""+h],p):i.push(r[""+h])}else b=r[y.targetID],(S=r[y.sourceID])&&S.children&&S.children.length>0||b&&b.children&&b.children.length>0?i.push(r[""+h]):this.initConnectors(r[""+h],p);else r[""+h].children?o.push(h):r[""+h].shape instanceof cT&&r[""+h].shape.activity.subProcess.processes&&r[""+h].shape.activity.subProcess.processes.length>0?s[r[""+h].id]=h:this.initNodes(r[""+h],p);if(this.bpmnModule)for(var w=0,C=this.bpmnModule.bpmnTextAnnotationConnector;w-1&&-1===r.indexOf(c)&&-1===s.indexOf(c)&&r.splice(0,0,c);-1===r.indexOf(o)&&s.push(o)}return r.concat(s)},t.prototype.addToLayer=function(e,i){var r;if(i&&(r=this.commandHandler.getObjectLayer(e.id)),(!i||!r)&&-1===this.activeLayer.objects.indexOf(e.id)&&this.activeLayer.objects.push(e.id),(e instanceof te||e instanceof de)&&("SwimLane"!==e.shape.type||e.children&&e.children.length>0)){if(e.parentId){var s=this.swimlaneZIndexTable[e.parentId],o=this.swimlaneChildTable[e.id];(s&&-1!==s||o&&-1!==o)&&(e.zIndex=this.swimlaneChildTable[e.id])}e instanceof de&&e.sourceID&&e.targetID?-1!==this.activeLayer.objects.indexOf(e.sourceID)&&-1!==this.activeLayer.objects.indexOf(e.targetID)&&this.setZIndex(r||this.activeLayer,e):this.setZIndex(r||this.activeLayer,e)}},t.prototype.updateLayer=function(e){for(var i=0,r=Object.keys(e.layers);i0)for(r=0;rs;l--)r.zIndexTable[parseInt(l.toString(),10)]=r.zIndexTable[l-1],this.nameTable[r.zIndexTable[parseInt(l.toString(),10)]]&&(this.nameTable[r.zIndexTable[parseInt(l.toString(),10)]].zIndex=l);r.zIndexTable[parseInt(a.toString(),10)]=i.id}}},t.prototype.initializeDiagramLayers=function(){for(var e=0;ethis.layers[parseInt(a.toString(),10)].zIndex&&(i=this.layers[parseInt(e.toString(),10)],this.layers[parseInt(e.toString(),10)]=this.layers[parseInt(a.toString(),10)],this.layers[parseInt(a.toString(),10)]=i);0===this.layers.length&&this.commandHandler.addLayer({id:"default_layer",visible:!0,lock:!1,objects:[],zIndex:0,objectZIndex:-1,zIndexTable:{}},null,!0),this.setActiveLayer(this.layers[this.layers.length-1].id)},t.prototype.resetTool=function(){this.eventHandler.resetTool()},t.prototype.initObjectExtend=function(e,i,r){if(r){var s=this.commandHandler.checkBoundaryConstraints(void 0,void 0,e.wrapper.bounds,!0);if("SwimLane"===e.shape.type)for(var o=0,a=Object.keys(i.zIndexTable);o0)&&this.setZIndex(i,e)),e instanceof te){if(r){if("helper"!==e.id&&(o=Zi(this.getNodeDefaults))){if((a=o(e,this))&&a.ports)for(var l=0;l0)for(l=0;l0&&!e.container||e.processId){var r=this.nameTable[e.id];if(!(this.realActions&$i.PreventScale||this.realActions&$i.PreventDrag)){if(r.offsetX&&(this.realActions&$i.EnableGroupAction||!(this.diagramActions&ee.UndoRedo||this.diagramActions&ee.ToolAction||this.diagramActions&ee.PublicMethod))){this.realActions|=$i.PreventScale;var s=r.offsetX-e.wrapper.offsetX;r.offsetX=e.wrapper.offsetX;var o=r.offsetY-e.wrapper.offsetY;r.offsetY=e.wrapper.offsetY,s+o!==0&&this.drag(r,s,o),this.realActions&=~$i.PreventScale}else r.offsetX=e.wrapper.offsetX;r.offsetY&&(this.realActions&$i.EnableGroupAction||!(this.diagramActions&ee.UndoRedo||this.diagramActions&ee.ToolAction||this.diagramActions&ee.PublicMethod))?(this.realActions|=$i.PreventScale,o=r.offsetY-e.wrapper.offsetY,r.offsetY=e.wrapper.offsetY,this.drag(r,0,o),this.realActions&=~$i.PreventScale):r.offsetY=e.wrapper.offsetY,this.diagramActions&&(r.width=e.wrapper.actualSize.width,r.height=e.wrapper.actualSize.height)}}i&&e.children&&e.children.length>0&&(void 0!==this.nameTable[e.id].width?this.scaleObject(e,this.nameTable[e.id].width,!0):this.nameTable[e.id].width=e.wrapper.actualSize.width,void 0!==this.nameTable[e.id].height?this.scaleObject(e,this.nameTable[e.id].height,!1):this.nameTable[e.id].height=e.wrapper.actualSize.height)},t.prototype.initNode=function(e,i,r){var a,f,s=e.initContainer(),o=new Mi;if(this.diagramSettings.inversedAlignment||(s.inversedAlignment=!1),s.children||(s.children=[]),e.children){s.measureChildren=!1,o.id=e.id+"group_container",o.style.fill=e.shape&&"SwimLane"===e.shape.type?e.style.fill:"none",o.style.strokeColor="none",o.horizontalAlignment="Stretch",o.verticalAlignment="Stretch",o.pivot=e.pivot,s.style=e.style,s.padding.left=e.padding.left,s.padding.right=e.padding.right,s.padding.top=e.padding.top,s.padding.bottom=e.padding.bottom,o.children=[],o.preventContainer=!0,e.container&&(o.relativeMode="Object");var l=!!(e.ports&&e.ports.length>0);if(m(e.container)&&!l&&s.children.push(o),e.container&&"Grid"===e.container.type)for(var h=0;h0&&e.wrapper.children[0]instanceof Wv){if(this.setZIndex(this.activeLayer,e),this.connectors.length>0)for(h=0;h0?i.phases.length:0,v="Horizontal"===i.orientation,y=v?i.phases.length||1:s.length+1,S=v?(i.header&&i.hasHeader?1:0)+(i.phases.length>0?1:0)+i.lanes.length:(i.header&&i.hasHeader?1:0)+i.phases.length;if(0===h&&!v&&i.lanes.length&&(S+=1),v?(a=(i.header&&i.hasHeader?1:0)+(h>0?1:0),l=0):(a=i.header&&i.hasHeader?1:0,l=h>0?1:0),s.length>0)for(o+=i.header&&i.hasHeader?i.header.height:0,f=0;fl?d.margin.left=d.margin.left-(u.bounds.left-e.bounds.left):u.children[0].children[1].actualSize.width+r>=d.margin.left&&(d.margin.left=u.children[0].children[1].actualSize.width+r),d.margin.lefta?d.margin.top=d.margin.top-(u.bounds.top-o):u.children[0].children[1].actualSize.height+r>=d.margin.top&&(d.margin.top=u.children[0].children[1].actualSize.height+r),d.margin.left0)for(o=0;o0&&this.updateChildPosition(e)},t.prototype.addBpmnAnnotationConnector=function(e,i){if(e.parentObj instanceof t||e.parentObj instanceof Hd){var r=e.shape,o=""!==r.textAnnotation.textAnnotationTarget&&this.nameTable[r.textAnnotation.textAnnotationTarget],a=o?this.nameTable[r.textAnnotation.textAnnotationTarget]:null,l=null!=a?a.wrapper:null,h=e.ports[0],c={x:0,y:0};switch(r.textAnnotation.textAnnotationDirection){case"Left":h.offset={x:0,y:.5},c.x=i.bounds.left-40,c.y=i.bounds.bottom+30;break;case"Right":h.offset={x:1,y:.5},c.x=i.bounds.right+40,c.y=i.bounds.bottom+30;break;case"Top":h.offset={x:.5,y:0},c.x=i.bounds.right+30,c.y=i.bounds.top-40;break;case"Bottom":h.offset={x:.5,y:1},c.x=i.bounds.right+30,c.y=i.bounds.bottom+40;break;default:h.offset={x:0,y:.5},c.x=i.bounds.left-40,c.y=i.bounds.bottom+30,o&&null!=i&&null!=l&&(i.bounds.left>l.bounds.right?h.offset={x:0,y:.5}:i.bounds.rightl.bounds.top?h.offset={x:.5,y:0}:i.bounds.top0&&this.updateChildPosition(r)}},t.prototype.canExecute=function(){return!0},t.prototype.updateStackProperty=function(e,i,r){e.container&&"Stack"===e.container.type&&(i.width||(i.wrapper.horizontalAlignment="Stretch",i.horizontalAlignment="Stretch"),i.height||(i.verticalAlignment="Stretch",i.wrapper.verticalAlignment="Stretch"),r&&"UmlClassifier"===e.shape.type&&(i.umlIndex=r))},t.prototype.initViews=function(){this.isLoading||(this.views.push(this.element.id),this.views[this.element.id]=this)},t.prototype.initCommands=function(){var e=this.commandManager.commands,i={copy:{execute:this.copyCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.C,keyModifiers:ft.Control}},paste:{execute:this.pasteCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.V,keyModifiers:ft.Control}},cut:{execute:this.cutCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.X,keyModifiers:ft.Control}},delete:{execute:this.removeCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Delete}},selectAll:{execute:this.selectAll.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.A,keyModifiers:ft.Control}},undo:{execute:this.undo.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Z,keyModifiers:ft.Control}},redo:{execute:this.redo.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Y,keyModifiers:ft.Control}},nudgeUp:{execute:this.nudgeCommand.bind(this,"Up"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Up},parameter:"up"},nudgeRight:{execute:this.nudgeCommand.bind(this,"Right"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Right},parameter:"right"},nudgeDown:{execute:this.nudgeCommand.bind(this,"Down"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Down},parameter:"down"},nudgeLeft:{execute:this.nudgeCommand.bind(this,"Left"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Left},parameter:"left"},startEdit:{execute:this.startEditCommad.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.F2}},endEdit:{execute:this.endEditCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Escape}},focusToNextItem:{execute:this.navigateItems.bind(this,!0),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Tab}},focusToPreviousItem:{execute:this.navigateItems.bind(this,!1),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Tab,keyModifiers:ft.Shift}},selectFocusedItem:{execute:this.startEditCommad.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Enter}},bold:{execute:this.fontStyleCommand.bind(this,"bold"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.B,keyModifiers:ft.Control}},italic:{execute:this.fontStyleCommand.bind(this,"italic"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.I,keyModifiers:ft.Control}},underline:{execute:this.fontStyleCommand.bind(this,"underline"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.U,keyModifiers:ft.Control}},duplicate:{execute:this.duplicateCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.D,keyModifiers:ft.Control}},group:{execute:this.groupCommand.bind(this,"group"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.G,keyModifiers:ft.Control}},ungroup:{execute:this.groupCommand.bind(this,"ungroup"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.U,keyModifiers:ft.Control|ft.Shift}},rotateClockwise:{execute:this.rotateCommand.bind(this,"clockwise"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.R,keyModifiers:ft.Control}},rotateAntiClockwise:{execute:this.rotateCommand.bind(this,"antiClockwise"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.L,keyModifiers:ft.Control}},flipHorizontal:{execute:this.flipCommand.bind(this,"horizontal"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.H,keyModifiers:ft.Control}},flipVertical:{execute:this.flipCommand.bind(this,"vertical"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.J,keyModifiers:ft.Control}},pointerTool:{execute:this.toolCommand.bind(this,"pointer"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number1,keyModifiers:ft.Control}},textTool:{execute:this.toolCommand.bind(this,"text"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number2,keyModifiers:ft.Control}},connectTool:{execute:this.toolCommand.bind(this,"connect"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number3,keyModifiers:ft.Control}},freeForm:{execute:this.toolCommand.bind(this,"freeForm"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number5,keyModifiers:ft.Control}},lineTool:{execute:this.toolCommand.bind(this,"line"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number6,keyModifiers:ft.Control}},rectangleTool:{execute:this.toolCommand.bind(this,"rectangle"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number8,keyModifiers:ft.Control}},ellipseTool:{execute:this.toolCommand.bind(this,"ellipse"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number9,keyModifiers:ft.Control}},zoomIn:{execute:this.zoomCommand.bind(this,"zoomIn"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Plus,keyModifiers:ft.Control}},zoomOut:{execute:this.zoomCommand.bind(this,"zoomOut"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Minus,keyModifiers:ft.Control}},shiftUp:{execute:this.shiftCommand.bind(this,"Up"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Up,keyModifiers:ft.Shift}},shiftDown:{execute:this.shiftCommand.bind(this,"Down"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Down,keyModifiers:ft.Shift}},shiftLeft:{execute:this.shiftCommand.bind(this,"Left"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Left,keyModifiers:ft.Shift}},shiftRight:{execute:this.shiftCommand.bind(this,"Right"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Right,keyModifiers:ft.Shift}},alignTextCenter:{execute:this.alignCommand.bind(this,"center"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.C,keyModifiers:ft.Control|ft.Shift}},alignTextLeft:{execute:this.alignCommand.bind(this,"right"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.L,keyModifiers:ft.Control|ft.Shift}},alignTextRight:{execute:this.alignCommand.bind(this,"left"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.R,keyModifiers:ft.Control|ft.Shift}},alignTextTop:{execute:this.alignCommand.bind(this,"top"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.E,keyModifiers:ft.Control|ft.Shift}},alignTextCenterVertical:{execute:this.alignCommand.bind(this,"centerVertical"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.M,keyModifiers:ft.Control|ft.Shift}},alignTextBottom:{execute:this.alignCommand.bind(this,"bottom"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.V,keyModifiers:ft.Control|ft.Shift}},alignJustify:{execute:this.alignCommand.bind(this,"justify"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.J,keyModifiers:ft.Control|ft.Shift}},sendToBack:{execute:this.orderCommand.bind(this,"sendToBack"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.B,keyModifiers:ft.Control|ft.Shift}},bringToFront:{execute:this.orderCommand.bind(this,"bringToFront"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.F,keyModifiers:ft.Control|ft.Shift}},sendBackward:{execute:this.orderCommand.bind(this,"sendBackward"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.BracketLeft,keyModifiers:ft.Control}},bringForward:{execute:this.orderCommand.bind(this,"bringForward"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.BracketRight,keyModifiers:ft.Control}}};this.initCommandManager(e,i)},t.prototype.overrideCommands=function(e,i){for(var r,s=0,o=Object.keys(i);se.zIndex){("HTML"===e.shape.type||"Native"===e.shape.type)&&(o="HTML"===e.shape.type?"html":"native"),s=voe(i,r[parseInt(a.toString(),10)].id,o);break}return s},t.prototype.updateDiagramObject=function(e,i,r){for(var s,o="domTable",a=0,l=this.views;a1&&(d=this.commandHandler.getObjectLayer(e.id)),void 0===d||d&&d.visible||r){var u=Io(this.element.id);window[""+o][s.element.id+"_diagramLayer"]||(window[""+o][s.element.id+"_diagramLayer"]=document.getElementById(s.element.id+"_diagramLayer"));var f=window[""+o][s.element.id+"_diagramLayer"];this.diagramActions&ee.Interactions&&this.updateCanupdateStyle(e.wrapper.children,!0);var p=this.getMidPoint(e);this.diagramRenderer.updateNode(e.wrapper,f,u,void 0,i?void 0:this.getZindexPosition(e,s.element.id),p,this.portCenterPoint),this.updateCanupdateStyle(e.wrapper.children,!0)}}},t.prototype.applyMarginBezier=function(e,i){i.cx=i.cx+e.margin.left,i.cx=i.cx-e.margin.right,i.cy=i.cy+e.margin.top,i.cy=i.cy-e.margin.bottom},t.prototype.getMidPoint=function(e){var i;if(e instanceof de&&"Bezier"===e.type){i=[];for(var r=this.getBezierPoints(e),s=R.getLengthFromListOfPoints(r),o=0;o0&&e.updateView(e));var s=Io(e.element.id);this.renderDiagramElements(e.diagramLayer,e.diagramRenderer,s,void 0,void 0,i);for(var o=0;o0&&this.renderBasicElement(e),!this.diagramActions||!(this.diagramActions&ee.Render)||ee.ToolAction&this.diagramActions||Ds(this)||1!==this.scroller.currentZoom?this.refreshElements(e):this.renderTimer||(this.renderTimer=setTimeout(function(){i.refreshElements(e)},40)))},t.prototype.updatePortVisibility=function(e,i,r){var s;if((e instanceof te||e instanceof de)&&(!this.drawingObject||!this.drawingObject.shape)&&ro(e)){for(var a=e.ports,l=!1,h=0;h=0&&this.scroller.removeCollection.splice(l,1);var h=this.nameTable[e[parseInt(a.toString(),10)]];this.updateTextElementValue(h),this.diagramRenderer.renderElement(h.wrapper,s,o,void 0,void 0,void 0,void 0,h.zIndex)}for(var c=0;c0?this.scroller.oldCollectionObjects:void 0,b=Object.keys(S||g.zIndexTable);b.sort(function(N,T){return parseInt(""+N,10)-parseInt(""+T,10)});for(var M=0,w=b;M0?h:0)+"px",y=(this.realActions&$i.vScrollbarMoved?0:-(this.scroller.verticalOffset<0?this.scroller.verticalOffset:0))+"px"):(v="0px",y="0px"),this.realActions&$i.hScrollbarMoved&&(this.realActions=this.realActions&~$i.hScrollbarMoved),this.realActions&$i.vScrollbarMoved&&(this.realActions=this.realActions&~$i.vScrollbarMoved)):(v=(l.x<0?h:-this.scroller.horizontalOffset)+"px",y=(l.y<0?c:-this.scroller.verticalOffset)+"px"),this.diagramLayer.style.left=v,this.diagramLayer.style.top=y,A.tx=-l.x/A.scale,A.ty=-l.y/A.scale);var P=!0;if(o&&(P=!1),this.updateTextElementValue(D),this.refreshing&&D.shape.activity&&D.shape.activity.subProcess&&D.shape.activity.subProcess.processes){for(var L=0;L0){var o=s.children[0],a=o.data;(r.isBezierEditing&&this.selectedItems.connectors[0].id===r.id||"Bezier"!==r.type)&&r.getSegmentElement(r,o,"ComplexHierarchicalTree"===this.layout.type||"HierarchicalTree"===this.layout.type?this.layout.orientation:void 0,void 0,!1),o.data!==a&&(s.measure(new me),s.arrange(s.desiredSize),"SVG"===this.mode&&!e&&this.updateDiagramObject(r))}}else this.constraints&nt.Bridging&&console.warn('[WARNING] :: Module "ConnectorBridging" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.setCursor=function(e){this.diagramRenderer.setCursor(this.diagramCanvas,e)},t.prototype.clearCanvas=function(e){var i=e.contentWidth||e.diagramLayer.width/this.scroller.currentZoom,r=e.contentHeight||e.diagramLayer.height/this.scroller.currentZoom;"SVG"!==e.mode&&bo.getContext(e.diagramLayer).clearRect(0,0,i,r)},t.prototype.updateScrollOffset=function(){this.scroller.setScrollOffset(this.diagramCanvas.scrollLeft,this.diagramCanvas.scrollTop),ZI(this),Ds(this)&&this.scroller.virtualizeElements()},t.prototype.setOffset=function(e,i){var r="domTable";window[""+r][this.element.id+"content"]||(window[""+r][this.element.id+"content"]=document.getElementById(this.element.id+"content"));var s=window[""+r][this.element.id+"content"];s&&(s.scrollLeft=e,s.scrollTop=i)},t.prototype.setSize=function(e,i){if(this.diagramLayer&&!this.preventDiagramUpdate){var r=Za(this);e-=r.width,i-=r.height;var s=this.spatialSearch.getPageBounds();s.x*=this.scroller.currentZoom,s.y*=this.scroller.currentZoom,s.width*=this.scroller.currentZoom,s.height*=this.scroller.currentZoom;var o="SVG"===this.mode?1:1.5,a="SVG"===this.mode?gT(this.element.id):this.diagramLayer,h="Canvas"===this.mode&&this.constraints&nt.Virtualization?this.scroller.viewPortHeight:i;a.setAttribute("width",(o*("Canvas"===this.mode&&this.constraints&nt.Virtualization?this.scroller.viewPortWidth:e)).toString()),a.setAttribute("height",(o*h).toString());var c=document.getElementById(this.element.id+"_diagramUserHandleLayer");c&&(c.style.width=e+"px",c.style.height=i+"px");var d={width:e.toString(),height:i.toString()};this.diagramLayerDiv.style.width=e+"px",this.diagramLayerDiv.style.height=i+"px",ti(kF(this.element.id),d),ti(function yoe(n){return xt(n).getElementsByClassName("e-ports-expand-layer")[0]}(this.element.id),d);var u=Bl(this.element.id);ti(u,d),u.parentNode.style.width=e+"px",u.parentNode.style.height=i+"px";var f=Fd(this.element.id);ti(f,d),this.diagramRenderer.updateGrid(this.snapSettings,f,this.scroller.transform,this.rulerSettings,this.hRuler,this.vRuler),ti(yT(this.element.id),d),this.htmlLayer.style.width=e+"px",this.htmlLayer.style.height=i+"px","SVG"!==this.mode&&!Ds(this)&&this.refreshDiagramLayer(),"SVG"===this.mode&&Ds(this)&&this.scroller.virtualizeElements()}},t.prototype.transformLayers=function(){var e=this.spatialSearch.getPageBounds();e.x*=this.scroller.currentZoom,e.y*=this.scroller.currentZoom,e.width*=this.scroller.currentZoom,e.height*=this.scroller.currentZoom,this.diagramRenderer.updateGrid(this.snapSettings,Fd(this.element.id),this.scroller.transform,this.rulerSettings,this.hRuler,this.vRuler),this.diagramRenderer.transformLayers(this.scroller.transform,"SVG"===this.mode),this.diagramActions&ee.DragUsingMouse||this.updateSelector(),this.renderPageBreaks(e)},t.prototype.removePageBreaks=function(){if(this.diagramLayer){var e=PF(this.element.id);if(e&&e.childNodes)for(var i=e.childNodes.length,r=0;rthis.pageSettings.height&&(e=this.pageSettings.height,this.pageSettings.height=this.pageSettings.width,this.pageSettings.width=e):this.pageSettings.height>this.pageSettings.width&&(e=this.pageSettings.width,this.pageSettings.width=this.pageSettings.height,this.pageSettings.height=e)},t.prototype.setOverview=function(e,i){if(e)e&&(this.views.push(e.id),this.views[e.id]=e,e.renderDocument(e),e.diagramRenderer.setLayers(),e.updateView(e),this.renderNodes(e));else{for(var r=0;r1&&this.updateSelectionRectangle(),this.isProtectedOnChange=s},t.prototype.updateSelectionRectangle=function(){for(var e=dm(this.element.id),i=!1,r=0;r1&&this.updateSelectionRectangle(),this.enableServerDataBinding(e)},t.prototype.renderSelectorForAnnotation=function(e,i){this.diagramRenderer.renderResizeHandle(e.wrapper.children[0],i,e.thumbsConstraints,this.scroller.currentZoom,e.constraints,this.scroller.transform,void 0,ro(e.annotation),void 0,void 0,e.handleSize)},t.prototype.drawSelectionRectangle=function(e,i,r,s){this.clearSelectorLayer(),this.diagramRenderer.drawSelectionRectangle(e,i,r,s,this.adornerLayer,this.scroller.transform)},t.prototype.renderHighlighter=function(e){var i=Bl(this.element.id);this.diagramRenderer.renderHighlighter(e,i,this.scroller.transform)},t.prototype.clearHighlighter=function(){var e=Bl(this.element.id),i=e.getElementById(e.id+"_highlighter");i&&i.parentNode.removeChild(i)},t.prototype.getNodesConnectors=function(e){for(var i=0;i0;h--)this.eventHandler&&this.eventHandler.touchArgs&&"touchmove"===this.eventHandler.touchArgs.type?(this.diagramRenderer.touchMove=!0,l&&l===o[h-1].id||(a=o[h-1]).parentNode.removeChild(a)):(a=o[h-1]).parentNode.removeChild(a);if(!ce()){var c=mT(this.element.id).childNodes;for(r=c.length;r>0;r--)c[r-1].parentNode.removeChild(c[r-1])}}},t.prototype.getWrapper=function(e,i){var r;i=e.id+"_"+i;for(var s=e instanceof Mi?e:this.getPortContainer(this.nameTable[e.id]),o=0;o0&&this.applyStyle(e,a=r.annotations)}for(i=0;i0){var a=this.selectedItems.connectors[parseInt(i.toString(),10)].annotations;this.applyStyle(e,a)}},t.prototype.applyStyle=function(e,i){for(var r=0;r0)for(var i=0;i0?r[0].zIndex+(e?1:-1):e?0:this.nodes.length+this.connectors.length-1)<0?i=this.nodes.length+this.connectors.length-1:i===this.nodes.length+this.connectors.length&&(i=0);for(var s=0;s0)for(var s=void 0,o=r.children.length-1;o>=0;o--){var a=r.children[parseInt(o.toString(),10)];i.length>0&&-1!==i.indexOf(a.id.split("_groupElement")[0])&&(r.parentNode.insertBefore(a,s||r),s=a)}r&&r.parentNode.removeChild(r)},t.prototype.deleteGroup=function(e){var r=[];e.children&&(r=this.commandHandler.getChildren(e,[])),this.UpdateBlazorDiagramModelCollection(e);for(var s=0,o=r;s0)for(var xe=0;xe0)if("Path"===t.shape.type&&void 0!==n.shape.data)t.wrapper.children[0].data=n.shape.data;else if("Text"===t.shape.type&&void 0!==n.shape.content)t.wrapper.children[0].content=n.shape.content;else if("Image"===t.shape.type&&void 0!==n.shape.source)t.wrapper.children[0].source=n.shape.source;else if("Native"===t.shape.type){for(var r=void 0,s=0;s-1)&&(this.diagramActions&ee.PreventZIndexOnDragging?this.updateDiagramObject(e,!0):this.updateDiagramObject(e)),!s&&d&&(this.lineRoutingModule&&this.diagramActions&&this.constraints&nt.LineRouting&&"helper"!==e.id?this.diagramActions&ee.ToolAction||this.lineRoutingModule.renderVirtualRegion(this,!0):this.diagramActions&&this.constraints&nt.LineRouting&&"helper"!==e.id&&console.warn('[WARNING] :: Module "LineRouting" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),this.updateConnectorEdges(e),"helper"!==e.id&&!(this.diagramActions&ee.ToolAction))))for(var Sa=this.spatialSearch.findObjects(e.wrapper.outerBounds),Mo=0;Moe?Math.abs(r-e):Math.abs(e-r),d=s>i?Math.abs(s-i):Math.abs(i-s);(0===c&&0===d||Number.isNaN(c)&&Number.isNaN(d))&&o.laneMargin&&(u=o.margin.left-o.laneMargin.left,f=o.margin.top-o.laneMargin.top);var p=o.width,g=o.height,v=new Ne(0,0,0,0);if(0!==p&&0!==g&&(v=new Ne((0!==r?r:o.offsetX)-p/2,(0!==s?s:o.offsetY)-g/2,p,g)),h){var y=l,b=this.selectedItems.nodes?this.selectedItems.nodes[0]:void 0;if(""!==y.textAnnotation.textAnnotationTarget&&this.nameTable[y.textAnnotation.textAnnotationTarget])if(""===o.parentId||b&&b.shape&&"TextAnnotation"===b.shape.shape){if("Auto"===y.textAnnotation.textAnnotationDirection&&a.children[0]instanceof Mi&&a.children[0].children[0]instanceof Ze){var w=a.children[0],C=document.getElementById(w.id+"_groupElement"),D=document.getElementById(w.children[0].id+"_groupElement");C.removeChild(D),w.children.splice(0,1),this.isProtectedOnChange=!0,this.bpmnModule.setAnnotationPath(v,w,o,y,y.textAnnotation.textAnnotationDirection,this),this.isProtectedOnChange=!1}}else this.isPositionUndo=!0,this.updateTextAnnotationInSwimlane(o,o),this.isPositionUndo=!1;else o.inEdges.length>0&&(x=this.nameTable[""+o.inEdges[0]])&&x.isBpmnAnnotationConnector&&(x.sourcePoint={x:r>e?x.sourcePoint.x+c:x.sourcePoint.x-c,y:s>i?x.sourcePoint.y+d:x.sourcePoint.y-d});this.nodePropertyChange(o,{},P={ports:[{offset:o.ports[0].offset}]})}else for(var L=0,O=o.outEdges;Le?T.offsetX+c:T.offsetX-c,T.offsetY=s>i?T.offsetY+d:T.offsetY-d,P={offsetX:T.offsetX,offsetY:T.offsetY}),this.nodePropertyChange(T,z,P)}}}},t.prototype.updatePorts=function(e,i){if(e&&e.ports.length>0)for(var r=0,s=Object.keys(e.ports);r0)for(var i=0;i0)for(var r=0;r0&&void 0===r.segments&&(e.segments=[]),void 0!==r.shape&&void 0!==e.shape&&e.shape&&"Bpmn"===e.shape.type&&this.bpmnModule&&this.bpmnModule.updateBPMNConnector(e,i,r,this),void 0!==e.constraints?(this.updateThumbConstraints(this.selectedItems.connectors,this.selectedItems),s=!0):s},t.prototype.connectorPropertyChange=function(e,i,r,s,o){if(this.canEnableBlazorObject){var a=$(e);this.insertValue(a,!1)}var d,u,f,p,l=e.wrapper.bounds,h=!1,c=[];if(h=this.connectorProprtyChangeExtend(e,i,r,h),void 0!==r.visible&&this.updateElementVisibility(e.wrapper,e,e.visible),void 0!==r.sourcePoint||void 0!==r.targetPoint||void 0!==r.sourceID||void 0!==r.targetID||void 0!==r.targetPadding||void 0!==r.sourcePortID||void 0!==r.targetPortID||void 0!==r.sourcePadding||void 0!==r.type||void 0!==r.segments||void 0!==r.flip){if(void 0!==r.sourceID&&r.sourceID!==i.sourceID||r.sourcePortID){if(u=this.findInOutConnectPorts(g=this.nameTable[e.sourceID],!1),(!g||Ph(g)||""!==e.sourcePortID&&Td(u))&&(e.sourceWrapper=g?this.getEndNodeWrapper(g,e,!0):void 0,e.sourcePortID&&void 0===r.sourcePortID&&(e.sourcePortWrapper=g?this.getWrapper(g.wrapper,e.sourcePortID):void 0),this.removePortEdges(this.nameTable[i.sourceID]||g,i.sourcePortID||e.sourcePortID,e.id,!1)),void 0!==r.sourceID&&void 0!==i.sourceID&&""!==i.sourceID){var v=this.nameTable[i.sourceID];void 0!==v&&v.outEdges&&-1!==v.outEdges.indexOf(e.id)&&im(v.outEdges,e.id)}this.updateEdges(e)}if(void 0!==r.targetID&&r.targetID!==i.targetID){if(d=this.findInOutConnectPorts(y=this.nameTable[r.targetID],!0),(!y||ua(y)||""!==e.targetPortID&&kh(d))&&(e.targetWrapper=y?this.getEndNodeWrapper(y,e,!1):void 0,e.targetPortID&&void 0===r.targetPortID&&(e.targetPortWrapper=y?this.getWrapper(y.wrapper,e.targetPortID):void 0),this.removePortEdges(this.nameTable[i.targetID]||y,i.targetPortID||e.targetPortID,e.id,!0)),void 0!==i&&void 0!==i.targetID&&""!==i.targetID){var S=this.nameTable[i.targetID];void 0!==S&&S.inEdges&&-1!==S.inEdges.indexOf(e.id)&&im(S.inEdges,e.id)}this.updateEdges(e)}var g,y;void 0!==r.sourcePortID&&r.sourcePortID!==i.sourcePortID&&(e.sourceID&&this.nameTable[e.sourceID]&&(f=this.nameTable[e.sourceID].wrapper),!(g=this.nameTable[e.sourceID])||Ph(g)||""!==e.sourcePortID&&Td(u)?e.sourcePortWrapper=f?this.getWrapper(f,r.sourcePortID):void 0:""===e.sourcePortID&&!Ph(g)&&(e.sourcePortWrapper=void 0)),void 0!==r.targetPortID&&r.targetPortID!==i.targetPortID&&(e.targetID&&this.nameTable[e.targetID]&&(p=this.nameTable[e.targetID].wrapper),!(y=this.nameTable[e.targetID])||ua(y)||""!==e.targetPortID&&kh(d)?e.targetPortWrapper=p?this.getWrapper(p,r.targetPortID):void 0:""===e.targetPortID&&!ua(y)&&(e.targetPortWrapper=void 0)),void 0!==r.flip&&(e.flip=r.flip,SF(e)),"Orthogonal"===e.type&&this.lineRoutingModule&&this.diagramActions&&this.constraints&nt.LineRouting&&!(this.diagramActions&ee.ToolAction)&&"ComplexHierarchicalTree"!==this.layout.type&&(this.lineRoutingModule.renderVirtualRegion(this,!0),e.sourceID!==e.targetID&&e.segments.length>1&&this.lineRoutingModule.refreshConnectorSegments(this,e,!1)),c=this.getPoints(e)}void 0!==r.style&&zh(r.style,e.wrapper.children[0]),(c.length>0||void 0!==r.sourceDecorator||void 0!==r.targetDecorator&&function _se(n){return-1!==n.indexOf("shape")||-1!==n.indexOf("pathData")||-1!==n.indexOf("width")||-1!==n.indexOf("height")}(Object.keys(r.targetDecorator))||void 0!==r.cornerRadius)&&(ep(e,c.length>0?c:e.intermediatePoints,this.diagramActions),void 0!==r.type&&(h=!0),c.length>0&&(e.wrapper.measure(new me(e.wrapper.width,e.wrapper.height)),e.wrapper.arrange(e.wrapper.desiredSize),this.updateConnectorAnnotation(e),this.updateConnectorPort(e),this.updateConnectorfixedUserHandles(e),this.updateObject(e,i,r))),(r.sourcePoint||r.targetPoint||r.segments)&&this.diagramActions===ee.Render&&(h=!0),"Bpmn"===e.shape.type&&"Default"===e.shape.sequence&&"Sequence"===e.shape.flow&&this.commandHandler.updatePathElementOffset(e),s||this.updateBridging(),this.updateAnnotations(r,e),this.updateConnectorPorts(r,e),this.updatefixedUserHandle(r,e),e.wrapper.measure(new me(e.wrapper.width,e.wrapper.height)),e.wrapper.arrange(e.wrapper.desiredSize),!1===l.equals(l,e.wrapper.bounds)&&(this.updateQuad(e),"Drag"!==this.eventHandler.currentAction&&this.updateGroupSize(e)),!0===h&&this.checkSelectedItem(e)&&(!(this.diagramActions&ee.ToolAction)||this.diagramActions&ee.UndoRedo)&&this.updateSelector(),this.preventConnectorsUpdate||(!Ds(this)||Ds(this)&&this.scroller.oldCollectionObjects.indexOf(e.id)>-1)&&(this.diagramActions&ee.PreventZIndexOnDragging?this.updateDiagramObject(e,!0):this.updateDiagramObject(e)),this.updateConnectorEdges(e),this.diagramActions&&"New"!==e.status&&(e.status="Update"),this.triggerPropertyChange(o,e,i,r)},t.prototype.removePortEdges=function(e,i,r,s){if(e)for(var o=0;o0&&e.id===s[s.length-1].id&&(r=!0),r},t.prototype.updateDiagramContainerVisibility=function(e,i){if(e instanceof Cs)for(var r=0;r>"),r instanceof es&&this.updateAnnotationWrapper(r,s,o,a)),void 0!==e.template&&(r.content=e.template,this.updateAnnotationWrapper(r,s,o,a))},t.prototype.updateAnnotationWrapper=function(e,i,r,s){for(var o=0,a=this.views;o=0&&this.nodes.splice(s,1),delete this.nameTable[""+r]}var o=this.nodes.indexOf(this.nameTable[this.currentSymbol.id]);o>=0&&this.nodes.splice(o,1)}},t.prototype.selectDragedNode=function(e,i,r){this.currentSymbol=e,"SVG"!==this.mode&&this.refreshDiagramLayer(),this.commandHandler.oldSelectedObjects=nm(this),this.commandHandler.select(e),this.eventHandler.mouseDown(i.event),this.eventHandler.mouseMove(i.event,i),this.preventDiagramUpdate=!1,this.updatePage(),r.style.opacity="0"},t.prototype.initDroppables=function(){var s,o,e=this,i={},r={},a="selectedSymbols";this.droppable=new lR(this.element);var l=5;this.droppable.over=function(h){if(e.rulerSettings.showRulers){var c=document.getElementById(e.element.id+"_vRuler"),d=parseFloat(c.style.width);l=d+1}if(0===e.previousSelectedObjects.length&&!e.currentSymbol&&(e.previousSelectedObjects=e.commandHandler.getSelectedObject()),e.commandHandler.PreventConnectorSplit=!0,e.currentSymbol)h.event.touches&&h.event.touches.length&&e.eventHandler.mouseMove(h.event,h.event.touches);else{var u=null;if(!h.dragData&&"drag"===h.name){var f=document.getElementsByClassName("e-dragclone")[0];f&&(u=f)}if(h.dragData||u){var p=void 0,g=void 0;document.getElementById(e.element.id+"content").focus();var v=e.eventHandler.getMousePosition(h.event),y=void 0,S=u||h.dragData.helper,b=S.getAttribute("paletteId"),M=void 0,w=void 0,C=void 0,D=void 0;if(!b&&h.dragData){e.triggerEvent(Ce.dragEnter,A={source:null,element:p,cancel:!1,diagram:e,dragData:h.dragData.draggedElement.ej2_instances[0].dragData,dragItem:p});var x=void 0,P=void 0;if(A.dragItem){if(A.dragItem.sourcePoint&&A.dragItem.targetPoint?P=new de(e,"connectors",A.dragItem,!0):x=new te(e,"nodes",A.dragItem,!0),e.initObject(p=x||P,void 0,void 0,!0),e.enterObject=p,e.enterTable=r,p instanceof te)x.offsetX=v.x+5+x.width*x.pivot.x,x.offsetY=v.y+x.height*x.pivot.y;else if(p instanceof de){var L=Ne.toBounds([p.sourcePoint,p.targetPoint]),O=v.x-L.left,N=v.y-L.top;p.sourcePoint.x+=O,p.sourcePoint.y+=N,p.targetPoint.x+=O,p.targetPoint.y+=N}e.preventDiagramUpdate=!0,e.currentSymbol=p,"SVG"!==e.mode&&e.refreshDiagramLayer(),e.selectDragedNode(p,h,S),delete e.enterObject,delete e.enterTable,e.droppable[""+a]=S,e.allowServerDataBinding=!0}}if(b){var T=document.getElementById(b).ej2_instances[0];if(e.droppable.sourceElement=T,T){var B=T[""+a];e.allowServerDataBinding=!1,y=$(T[""+a]),i=T.childTable;var j=B.wrapper.children[0].children[0];if(D=function Use(n,t,e){var i=wF(n,t,e,"width"),r=wF(n,t,e,"height");return new me(i,r)}(T,y,j),T[""+a]instanceof te){"TextAnnotation"===B.shape.shape?(y.offsetX=v.x+11+D.width*y.pivot.x,y.offsetY=v.y+11+D.height*y.pivot.y):(y.offsetX=v.x+5+D.width*y.pivot.x,y.offsetY=v.y+D.height*y.pivot.y),"Bpmn"===(x=new te(e,"nodes",y,!0)).shape.type&&x.shape.activity.subProcess.processes&&x.shape.activity.subProcess.processes.length&&(x.shape.activity.subProcess.processes=[]),w=x.previewSize,C=T.symbolDragSize;var Q=T.symbolPreview;if(x.width=(M=x.dragSize).width||C.width||w.width||Q.width||x.width,x.height=M.height||C.height||w.height||Q.height||x.height,"SwimLane"===x.shape.type){if(e.diagramActions|=ee.PreventHistory,x.shape.isLane){x.children=[],s={id:"header"+Qe()},"Horizontal"===x.shape.orientation?(s.width=x.shape.lanes[0].header.width,s.height=x.shape.lanes[0].height):(s.width=x.shape.lanes[0].width,s.height=x.shape.lanes[0].header.height),s.style=x.shape.lanes[0].header.style,s.offsetX=v.x+l+s.width/2,s.offsetY=v.y+s.height/2,e.diagramActions|=ee.PreventCollectionChangeOnDragOver,s=e.add(s),o={id:"body"+Qe()},"Horizontal"===x.shape.orientation?(o.width=x.shape.lanes[0].width-s.width,o.height=x.shape.lanes[0].height,o.offsetX=v.x+l+(x.shape.lanes[0].header.width+o.width/2),o.offsetY=v.y+o.height/2):(o.width=x.shape.lanes[0].width,o.height=x.shape.lanes[0].height-s.height,o.offsetX=v.x+l+o.width/2,o.offsetY=v.y+(x.shape.lanes[0].header.height+o.height/2)),o.style=x.shape.lanes[0].style,o=e.add(o);var oe={id:"group"+Qe(),children:[s.id,o.id]};oe.shape=x.shape,oe.width=x.shape.lanes[0].width,oe.height=x.shape.lanes[0].height,oe.previewSize=x.previewSize,oe.dragSize=x.dragSize,oe.addInfo=x.addInfo,x=e.add(oe),e.diagramActions&=~ee.PreventCollectionChangeOnDragOver}e.diagramActions&=~ee.PreventHistory}if(x.shape.isPhase&&((g="Horizontal"===x.shape.orientation)?(x.offsetX=v.x+l+(x.width||j.actualSize.width)/2,x.offsetY=v.y,x.shape.data="M20,"+x.height/2+" L"+(x.width-20)+","+x.height/2+"z",x.height=1):(x.offsetX=v.x+5,x.offsetY=v.y+(x.height||j.actualSize.height)/2,x.shape.data="M"+x.width/2+",20 L"+x.width/2+","+(x.height-20)+"z",x.width=1)),"UmlClassifier"===x.shape.type&&(x.children=x.width=x.height=void 0,y.children=void 0,"Class"===x.shape.classifier&&x.shape.classShape.methods.length<=0&&x.shape.classShape.attributes.length<=0&&(x.shape.classShape.attributes=[{name:"Name",type:"Type",style:{}}]),"Enumeration"===x.shape.classifier&&x.shape.enumerationShape.members.length<=0&&(x.shape.enumerationShape.members=[{name:"Name"}]),"Interface"===x.shape.classifier&&x.shape.interfaceShape.methods.length<=0&&x.shape.interfaceShape.attributes.length<=0&&(x.shape.interfaceShape.attributes=[{name:"Name",type:"Type",style:{}}])),p=x,y.children){var ue=y;r=e.getChildren(ue,{},i),tT(ue,-ue.offsetX,-ue.offsetY,r,!0,e)}}else if(T[""+a]instanceof de){p=new de(e,"connectors",y,!0);var Me=Ne.toBounds([p.sourcePoint,p.targetPoint]),De=v.x-Me.left,xe=v.y-Me.top;p.sourcePoint.x+=De,p.sourcePoint.y+=xe,p.targetPoint.x+=De,p.targetPoint.y+=xe}p.shape.isLane||(p.id+=Qe());var A={source:T,element:p,cancel:!1,diagram:e,dragData:null,dragItem:p};if(e.enterObject=p,e.enterTable=r,e.triggerEvent(Ce.dragEnter,A),p instanceof te&&"SwimLane"===p.shape.type&&p.shape.isLane){var Ie=A.element,Ve=Ie.shape.lanes[0];g="Horizontal"===Ie.shape.orientation;var ot=e.nameTable[p.children[0]],$e=e.nameTable[p.children[1]];w=p.previewSize,C=T.symbolDragSize,Ve.width=(M=p.dragSize).width||C.width||w.width||Ve.width,Ve.height=M.height||C.height||w.height||Ve.height,g?(s.width=Ve.header.width,s.height=Ve.height,o.width=Ve.width-s.width,o.height=Ve.height,o.offsetX=v.x+l+(Ve.header.width+$e.width/2),o.offsetY=v.y+$e.height/2):(s.width=Ve.width,s.height=Ve.header.height,o.width=Ve.width,o.height=Ve.height-s.height,o.offsetX=v.x+l+$e.width/2,o.offsetY=v.y+(Ve.header.height+$e.height/2)),s.offsetX=v.x+l+ot.width/2,s.offsetY=v.y+ot.height/2,p.width=Ve.width,p.height=Ve.height}if(p instanceof te&&p.shape.isPhase&&(g?p.height=1:p.width=1),!e.activeLayer.lock&&!A.cancel){if(e.preventDiagramUpdate=!0,p.children&&e.findChild(p,r),e.preventDiagramUpdate=!0,p.zIndex!==Number.MIN_VALUE&&(p.zIndex=Number.MIN_VALUE),e.initObject(p,void 0,void 0,!0),e.bpmnModule)for(var Ci=0;Ci0&&(S.segments=[]),d=this.add(S,!0)),(S||d)&&(_v(this)||Uv(this))&&this.select([this.nameTable[S[""+b]]],!1,this.previousSelectedObjects),y.target&&y.target instanceof de&&!0===this.enableConnectorSplit&&this.nameTable[S[""+b]]instanceof te&&(this.commandHandler.connectorSplit(this.nameTable[S[""+b]],y.target),this.commandHandler.PreventConnectorSplit=!1))),this.protectPropertyChange(!1),v=this.nameTable[S[""+b]],S.hasTarget&&(S.nodeId=S.hasTarget,this.remove(S)),this.bpmnModule&&v instanceof te&&S.processId&&(v.processId=S.processId,this.bpmnModule.dropBPMNchild(this.nameTable[v.processId],v,this)),y.cancel||this.endGroupAction(),"SVG"!==this.mode&&this.refreshDiagramLayer(),delete this.droppable[""+c]):(this.triggerEvent(Ce.drop,y={source:h.droppedElement,element:void 0,target:this.eventHandler.hoverNode||this.eventHandler.lastObjectUnderMouse||this,cancel:!1,position:void 0}),S=void 0,b="id"),this.droppable[M="selectedSymbols"]&&this.droppable[""+M].parentNode)gt(this.droppable[""+M]);else for(w=document.getElementsByClassName("e-dragclone"),C=0;C0)for(var f=0;f1),e.previousSelectedObject=null}}},t.prototype.getDropEventArgs=function(e){if(this.eventHandler.lastObjectUnderMouse||this.eventHandler.hoverNode){var i=this.eventHandler.lastObjectUnderMouse||this.eventHandler.hoverNode;e.target=ps(i)===de?{connector:i}:{node:i}}else e.target.diagramId=this.element.id},t.prototype.removeChildInNodes=function(e){if(e){if(e.children)for(var i=0;i1){var l=2;if(e.children&&e.children.length>0)for(;e.children.indexOf(i.objects[s-l])>-1;)l++;this.commandHandler.moveSvgNode(e.id,i.objects[s-l]),this.commandHandler.moveSvgNode(i.objects[s-l],e.id)}else if(o){var h=this.commandHandler.getLayer(this.layerZIndexTable[o.zIndex]).objects[0];h?(this.commandHandler.moveSvgNode(e.id,h),this.commandHandler.updateNativeNodeIndex(e.id,h)):this.moveObjectsUp(e,i)}else this.moveObjectsUp(e,i)},t.prototype.moveObjectsUp=function(e,i){for(var r,s=this.layers.length-1;s>=0;s--)if(r=this.layers[parseInt(s.toString(),10)],i.id!==r.id){var o=this.commandHandler.getLayer(this.layerZIndexTable[r.zIndex]).objects[r.objects.length-1];if(o){this.commandHandler.moveSvgNode(e.id,o),this.commandHandler.moveSvgNode(o,e.id);break}}},t.prototype.insertData=function(e){return this.crudOperation(e,"create",this.getNewUpdateNodes("New"))},t.prototype.updateData=function(e){return this.crudOperation(e,"update",this.getNewUpdateNodes("Update"))},t.prototype.removeData=function(e){return this.crudOperation(e,"destroy",this.getDeletedNodes())},t.prototype.crudOperation=function(e,i,r){if(e){var s=this.parameterMap(e,!(e instanceof de));if(s){var o=e instanceof de?this.dataSourceSettings.connectionDataSource.crudAction[""+i]:this.dataSourceSettings.crudAction[""+i];this.raiseAjaxPost(JSON.stringify(s),o)}return s}var a=r;return this.processCrudCollection(a,this.dataSourceSettings.crudAction[""+i],this.dataSourceSettings.connectionDataSource.crudAction[""+i]),a},t.prototype.processCrudCollection=function(e,i,r){if(e.nodes){var s=[],o=void 0;for(o=0;o0&&this.raiseAjaxPost(JSON.stringify(s),i)}if(e.connectors){for(s=[],o=void 0,o=0;o0&&this.raiseAjaxPost(JSON.stringify(s),r)}},t.prototype.parameterMap=function(e,i){var s,r={},o=i?this.dataSourceSettings:this.dataSourceSettings.connectionDataSource;if(o.id&&(r[o.id]=e.id),o.sourcePointX&&o.sourcePointY&&(r[o.sourcePointX]=e.sourcePoint.x,r[o.sourcePointY]=e.sourcePoint.y),o.targetPointX&&o.targetPointY&&(r[o.targetPointX]=e.targetPoint.x,r[o.targetPointY]=e.targetPoint.y),o.sourceID&&(r[o.sourceID]=e.sourceID),o.targetID&&(r[o.targetID]=e.targetID),o.crudAction&&o.crudAction.customFields&&o.crudAction.customFields.length>0)for(s=0;s"u"||(y.innerHTML=v.innerHTML?v.innerHTML:"",void 0!==v.className&&(y.className=v.className),void 0!==v.id&&(y.id=v.id),void 0!==v.styles&&y.setAttribute("style",v.styles),void 0!==e.ngAttr&&y.setAttribute(e.ngAttr,""),void 0!==v.attrs&&Fe(y,v.attrs)),y};for(var i=0,r=e.tags;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s}!function TZ(n){DC.compile=n.compile}({compile:function Uae(n,t){if("string"==typeof n||"function"==typeof n&&n.prototype&&n.prototype.CSPTemplate)return _ae(n,t);var e=n.elementRef.nativeElement._viewContainerRef,i=n.elementRef.nativeElement.propName;return function(r,s,o){var l=e||s.viewContainerRef,h=l.createEmbeddedView(n,{$implicit:r});/EJS-MENTION|EJS-DROPDOWNLIST/.test(Y("currentInstance.element.nodeName",l))||/E-TABITEM/.test(Y("element.nativeElement.nodeName",l))?h.detectChanges():h.markForCheck();var c=s&&s.registeredTemplate?s.registeredTemplate:Y("currentInstance.registeredTemplate",l);return typeof c["".concat(o=o&&s.registeredTemplate?o:i)]>"u"&&(c["".concat(o)]=[]),c["".concat(o)].push(h),h.rootNodes}}});const Qae=["annotationTemplate"],Gae=["nodeTemplate"],Xae=["userHandleTemplate"];let qae=["addInfo","id","lock","objects","visible","zIndex"],$ae=[],Zae=(()=>{class n extends Bh{constructor(e){super(),this.viewContainerRef=e,_l("currentInstance",this,this.viewContainerRef),this.registerEvents($ae),this.directivePropList=qae}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-layer"]],inputs:{addInfo:"addInfo",id:"id",lock:"lock",objects:"objects",visible:"visible",zIndex:"zIndex"},features:[yn]}),n})(),Jae=(()=>{class n extends Fh{constructor(){super("layers")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-layers"]],contentQueries:function(e,i,r){if(1&e&&dn(r,Zae,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),Kae=["action","cursor"],ele=[],tle=(()=>{class n extends Bh{constructor(e){super(),this.viewContainerRef=e,_l("currentInstance",this,this.viewContainerRef),this.registerEvents(ele),this.directivePropList=Kae}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-cursormap"]],inputs:{action:"action",cursor:"cursor"},features:[yn]}),n})(),ile=(()=>{class n extends Fh{constructor(){super("customcursor")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-cursormaps"]],contentQueries:function(e,i,r){if(1&e&&dn(r,tle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),rle=["alignment","cornerRadius","displacement","fill","handleStrokeColor","handleStrokeWidth","height","iconStrokeColor","iconStrokeWidth","id","offset","padding","pathData","tooltip","visibility","width"],nle=[],sle=(()=>{class n extends Bh{constructor(e){super(),this.viewContainerRef=e,_l("currentInstance",this,this.viewContainerRef),this.registerEvents(nle),this.directivePropList=rle}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-connector-fixeduserhandle"]],inputs:{alignment:"alignment",cornerRadius:"cornerRadius",displacement:"displacement",fill:"fill",handleStrokeColor:"handleStrokeColor",handleStrokeWidth:"handleStrokeWidth",height:"height",iconStrokeColor:"iconStrokeColor",iconStrokeWidth:"iconStrokeWidth",id:"id",offset:"offset",padding:"padding",pathData:"pathData",tooltip:"tooltip",visibility:"visibility",width:"width"},features:[yn]}),n})(),ole=(()=>{class n extends Fh{constructor(){super("fixeduserhandles")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-connector-fixeduserhandles"]],contentQueries:function(e,i,r){if(1&e&&dn(r,sle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),ale=["addInfo","alignment","annotationType","constraints","content","displacement","dragLimit","height","horizontalAlignment","hyperlink","id","margin","offset","rotateAngle","rotationReference","segmentAngle","style","template","tooltip","type","verticalAlignment","visibility","width"],lle=[],hle=(()=>{class n extends Bh{constructor(e){super(),this.viewContainerRef=e,_l("currentInstance",this,this.viewContainerRef),this.registerEvents(lle),this.directivePropList=ale}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-connector-annotation"]],inputs:{addInfo:"addInfo",alignment:"alignment",annotationType:"annotationType",constraints:"constraints",content:"content",displacement:"displacement",dragLimit:"dragLimit",height:"height",horizontalAlignment:"horizontalAlignment",hyperlink:"hyperlink",id:"id",margin:"margin",offset:"offset",rotateAngle:"rotateAngle",rotationReference:"rotationReference",segmentAngle:"segmentAngle",style:"style",template:"template",tooltip:"tooltip",type:"type",verticalAlignment:"verticalAlignment",visibility:"visibility",width:"width"},features:[yn]}),n})(),cle=(()=>{class n extends Fh{constructor(){super("annotations")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-connector-annotations"]],contentQueries:function(e,i,r){if(1&e&&dn(r,hle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),dle=["addInfo","allowNodeOverlap","annotations","bezierSettings","bridgeSpace","connectionPadding","connectorSpacing","constraints","cornerRadius","dragSize","excludeFromLayout","fixedUserHandles","flip","flipMode","hitPadding","id","margin","maxSegmentThumb","ports","previewSize","segmentThumbShape","segmentThumbSize","segments","shape","sourceDecorator","sourceID","sourcePadding","sourcePoint","sourcePortID","style","symbolInfo","targetDecorator","targetID","targetPadding","targetPoint","targetPortID","tooltip","type","visible","wrapper","zIndex"],ule=[],v_=(()=>{class n extends Bh{constructor(e){super(),this.viewContainerRef=e,this.tags=["fixedUserHandles","annotations"],_l("currentInstance",this,this.viewContainerRef),this.registerEvents(ule),this.directivePropList=dle}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-connector"]],contentQueries:function(e,i,r){if(1&e&&(dn(r,ole,5),dn(r,cle,5)),2&e){let s;Kr(s=en())&&(i.childFixedUserHandles=s.first),Kr(s=en())&&(i.childAnnotations=s.first)}},inputs:{addInfo:"addInfo",allowNodeOverlap:"allowNodeOverlap",annotations:"annotations",bezierSettings:"bezierSettings",bridgeSpace:"bridgeSpace",connectionPadding:"connectionPadding",connectorSpacing:"connectorSpacing",constraints:"constraints",cornerRadius:"cornerRadius",dragSize:"dragSize",excludeFromLayout:"excludeFromLayout",fixedUserHandles:"fixedUserHandles",flip:"flip",flipMode:"flipMode",hitPadding:"hitPadding",id:"id",margin:"margin",maxSegmentThumb:"maxSegmentThumb",ports:"ports",previewSize:"previewSize",segmentThumbShape:"segmentThumbShape",segmentThumbSize:"segmentThumbSize",segments:"segments",shape:"shape",sourceDecorator:"sourceDecorator",sourceID:"sourceID",sourcePadding:"sourcePadding",sourcePoint:"sourcePoint",sourcePortID:"sourcePortID",style:"style",symbolInfo:"symbolInfo",targetDecorator:"targetDecorator",targetID:"targetID",targetPadding:"targetPadding",targetPoint:"targetPoint",targetPortID:"targetPortID",tooltip:"tooltip",type:"type",visible:"visible",wrapper:"wrapper",zIndex:"zIndex"},features:[yn]}),n})(),m_=(()=>{class n extends Fh{constructor(){super("connectors")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-connectors"]],contentQueries:function(e,i,r){if(1&e&&dn(r,v_,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),fle=["cornerRadius","fill","handleStrokeColor","handleStrokeWidth","height","iconStrokeColor","iconStrokeWidth","id","margin","offset","padding","pathData","tooltip","visibility","width"],ple=[],gle=(()=>{class n extends Bh{constructor(e){super(),this.viewContainerRef=e,_l("currentInstance",this,this.viewContainerRef),this.registerEvents(ple),this.directivePropList=fle}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-node-fixeduserhandle"]],inputs:{cornerRadius:"cornerRadius",fill:"fill",handleStrokeColor:"handleStrokeColor",handleStrokeWidth:"handleStrokeWidth",height:"height",iconStrokeColor:"iconStrokeColor",iconStrokeWidth:"iconStrokeWidth",id:"id",margin:"margin",offset:"offset",padding:"padding",pathData:"pathData",tooltip:"tooltip",visibility:"visibility",width:"width"},features:[yn]}),n})(),vle=(()=>{class n extends Fh{constructor(){super("fixeduserhandles")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-node-fixeduserhandles"]],contentQueries:function(e,i,r){if(1&e&&dn(r,gle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),mle=["addInfo","annotationType","constraints","content","dragLimit","height","horizontalAlignment","hyperlink","id","margin","offset","rotateAngle","rotationReference","style","template","tooltip","type","verticalAlignment","visibility","width"],yle=[],Sle=(()=>{class n extends Bh{constructor(e){super(),this.viewContainerRef=e,_l("currentInstance",this,this.viewContainerRef),this.registerEvents(yle),this.directivePropList=mle}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-node-annotation"]],inputs:{addInfo:"addInfo",annotationType:"annotationType",constraints:"constraints",content:"content",dragLimit:"dragLimit",height:"height",horizontalAlignment:"horizontalAlignment",hyperlink:"hyperlink",id:"id",margin:"margin",offset:"offset",rotateAngle:"rotateAngle",rotationReference:"rotationReference",style:"style",template:"template",tooltip:"tooltip",type:"type",verticalAlignment:"verticalAlignment",visibility:"visibility",width:"width"},features:[yn]}),n})(),Ile=(()=>{class n extends Fh{constructor(){super("annotations")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-node-annotations"]],contentQueries:function(e,i,r){if(1&e&&dn(r,Sle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),ble=["addInfo","connectionDirection","constraints","height","horizontalAlignment","id","inEdges","margin","offset","outEdges","pathData","shape","style","tooltip","verticalAlignment","visibility","width"],Mle=[],wle=(()=>{class n extends Bh{constructor(e){super(),this.viewContainerRef=e,_l("currentInstance",this,this.viewContainerRef),this.registerEvents(Mle),this.directivePropList=ble}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-node-port"]],inputs:{addInfo:"addInfo",connectionDirection:"connectionDirection",constraints:"constraints",height:"height",horizontalAlignment:"horizontalAlignment",id:"id",inEdges:"inEdges",margin:"margin",offset:"offset",outEdges:"outEdges",pathData:"pathData",shape:"shape",style:"style",tooltip:"tooltip",verticalAlignment:"verticalAlignment",visibility:"visibility",width:"width"},features:[yn]}),n})(),Cle=(()=>{class n extends Fh{constructor(){super("ports")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-node-ports"]],contentQueries:function(e,i,r){if(1&e&&dn(r,wle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),Ele=["addInfo","annotations","backgroundColor","borderColor","borderWidth","branch","children","collapseIcon","columnIndex","columnSpan","columns","constraints","container","data","dragSize","excludeFromLayout","expandIcon","fixedUserHandles","flip","flipMode","height","horizontalAlignment","id","isExpanded","layoutInfo","margin","maxHeight","maxWidth","minHeight","minWidth","offsetX","offsetY","padding","pivot","ports","previewSize","rotateAngle","rowIndex","rowSpan","rows","shadow","shape","style","symbolInfo","tooltip","verticalAlignment","visible","width","wrapper","zIndex"],Dle=[],y_=(()=>{class n extends Bh{constructor(e){super(),this.viewContainerRef=e,this.tags=["fixedUserHandles","annotations","ports"],_l("currentInstance",this,this.viewContainerRef),this.registerEvents(Dle),this.directivePropList=Ele}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-node"]],contentQueries:function(e,i,r){if(1&e&&(dn(r,vle,5),dn(r,Ile,5),dn(r,Cle,5)),2&e){let s;Kr(s=en())&&(i.childFixedUserHandles=s.first),Kr(s=en())&&(i.childAnnotations=s.first),Kr(s=en())&&(i.childPorts=s.first)}},inputs:{addInfo:"addInfo",annotations:"annotations",backgroundColor:"backgroundColor",borderColor:"borderColor",borderWidth:"borderWidth",branch:"branch",children:"children",collapseIcon:"collapseIcon",columnIndex:"columnIndex",columnSpan:"columnSpan",columns:"columns",constraints:"constraints",container:"container",data:"data",dragSize:"dragSize",excludeFromLayout:"excludeFromLayout",expandIcon:"expandIcon",fixedUserHandles:"fixedUserHandles",flip:"flip",flipMode:"flipMode",height:"height",horizontalAlignment:"horizontalAlignment",id:"id",isExpanded:"isExpanded",layoutInfo:"layoutInfo",margin:"margin",maxHeight:"maxHeight",maxWidth:"maxWidth",minHeight:"minHeight",minWidth:"minWidth",offsetX:"offsetX",offsetY:"offsetY",padding:"padding",pivot:"pivot",ports:"ports",previewSize:"previewSize",rotateAngle:"rotateAngle",rowIndex:"rowIndex",rowSpan:"rowSpan",rows:"rows",shadow:"shadow",shape:"shape",style:"style",symbolInfo:"symbolInfo",tooltip:"tooltip",verticalAlignment:"verticalAlignment",visible:"visible",width:"width",wrapper:"wrapper",zIndex:"zIndex"},features:[yn]}),n})(),S_=(()=>{class n extends Fh{constructor(){super("nodes")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-nodes"]],contentQueries:function(e,i,r){if(1&e&&dn(r,y_,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})();const xle=["animationComplete","click","collectionChange","commandExecute","connectionChange","contextMenuBeforeItemRender","contextMenuClick","contextMenuOpen","created","dataLoaded","doubleClick","dragEnter","dragLeave","dragOver","drop","elementDraw","expandStateChange","fixedUserHandleClick","historyChange","historyStateChange","keyDown","keyUp","load","loaded","mouseEnter","mouseLeave","mouseOver","mouseWheel","onFixedUserHandleMouseDown","onFixedUserHandleMouseEnter","onFixedUserHandleMouseLeave","onFixedUserHandleMouseUp","onImageLoad","onUserHandleMouseDown","onUserHandleMouseEnter","onUserHandleMouseLeave","onUserHandleMouseUp","positionChange","propertyChange","rotateChange","scrollChange","segmentChange","segmentCollectionChange","selectionChange","sizeChange","sourcePointChange","targetPointChange","textEdit"],Tle=[""];let Ale=(()=>{let n=class extends Fl{constructor(e,i,r,s){super(),this.ngEle=e,this.srenderer=i,this.viewContainerRef=r,this.injector=s,this.tags=["layers","customCursor","connectors","nodes"],this.element=this.ngEle.nativeElement,this.injectedModules=this.injectedModules||[];try{let o=this.injector.get("DiagramsHierarchicalTree");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsMindMap");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsRadialTree");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsComplexHierarchicalTree");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsDataBinding");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsSnapping");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsPrintAndExport");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsBpmnDiagrams");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsSymmetricLayout");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsConnectorBridging");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsUndoRedo");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsLayoutAnimation");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsDiagramContextMenu");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsLineRouting");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsConnectorEditing");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsLineDistribution");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsEj1Serialization");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsFlowchartLayout");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}this.registerEvents(xle),this.addTwoWay.call(this,Tle),_l("currentInstance",this,this.viewContainerRef),this.context=new u_}ngOnInit(){this.context.ngOnInit(this)}ngAfterViewInit(){this.context.ngAfterViewInit(this)}ngOnDestroy(){this.context.ngOnDestroy(this)}ngAfterContentChecked(){this.tagObjects[0].instance=this.childLayers,this.childCustomCursor&&(this.tagObjects[1].instance=this.childCustomCursor),this.childConnectors&&(this.tagObjects[2].instance=this.childConnectors),this.childNodes&&(this.tagObjects[3].instance=this.childNodes),this.context.ngAfterContentChecked(this)}};return n.\u0275fac=function(e){return new(e||n)(Ot($c),Ot(hM),Ot(An),Ot(Wo))},n.\u0275cmp=Fb({type:n,selectors:[["ejs-diagram"]],contentQueries:function(e,i,r){if(1&e&&(dn(r,Qae,5),dn(r,Gae,5),dn(r,Xae,5),dn(r,Jae,5),dn(r,ile,5),dn(r,m_,5),dn(r,S_,5)),2&e){let s;Kr(s=en())&&(i.annotationTemplate=s.first),Kr(s=en())&&(i.nodeTemplate=s.first),Kr(s=en())&&(i.userHandleTemplate=s.first),Kr(s=en())&&(i.childLayers=s.first),Kr(s=en())&&(i.childCustomCursor=s.first),Kr(s=en())&&(i.childConnectors=s.first),Kr(s=en())&&(i.childNodes=s.first)}},inputs:{addInfo:"addInfo",annotationTemplate:"annotationTemplate",backgroundColor:"backgroundColor",bridgeDirection:"bridgeDirection",commandManager:"commandManager",connectorDefaults:"connectorDefaults",connectors:"connectors",constraints:"constraints",contextMenuSettings:"contextMenuSettings",customCursor:"customCursor",dataSourceSettings:"dataSourceSettings",diagramSettings:"diagramSettings",drawingObject:"drawingObject",enableConnectorSplit:"enableConnectorSplit",enablePersistence:"enablePersistence",enableRtl:"enableRtl",fixedUserHandleTemplate:"fixedUserHandleTemplate",getConnectorDefaults:"getConnectorDefaults",getCustomCursor:"getCustomCursor",getCustomProperty:"getCustomProperty",getCustomTool:"getCustomTool",getDescription:"getDescription",getNodeDefaults:"getNodeDefaults",height:"height",historyManager:"historyManager",layers:"layers",layout:"layout",locale:"locale",mode:"mode",nodeDefaults:"nodeDefaults",nodeTemplate:"nodeTemplate",nodes:"nodes",pageSettings:"pageSettings",rulerSettings:"rulerSettings",scrollSettings:"scrollSettings",segmentThumbShape:"segmentThumbShape",segmentThumbSize:"segmentThumbSize",selectedItems:"selectedItems",serializationSettings:"serializationSettings",setNodeTemplate:"setNodeTemplate",snapSettings:"snapSettings",tool:"tool",tooltip:"tooltip",updateSelection:"updateSelection",userHandleTemplate:"userHandleTemplate",width:"width"},outputs:{animationComplete:"animationComplete",click:"click",collectionChange:"collectionChange",commandExecute:"commandExecute",connectionChange:"connectionChange",contextMenuBeforeItemRender:"contextMenuBeforeItemRender",contextMenuClick:"contextMenuClick",contextMenuOpen:"contextMenuOpen",created:"created",dataLoaded:"dataLoaded",doubleClick:"doubleClick",dragEnter:"dragEnter",dragLeave:"dragLeave",dragOver:"dragOver",drop:"drop",elementDraw:"elementDraw",expandStateChange:"expandStateChange",fixedUserHandleClick:"fixedUserHandleClick",historyChange:"historyChange",historyStateChange:"historyStateChange",keyDown:"keyDown",keyUp:"keyUp",load:"load",loaded:"loaded",mouseEnter:"mouseEnter",mouseLeave:"mouseLeave",mouseOver:"mouseOver",mouseWheel:"mouseWheel",onFixedUserHandleMouseDown:"onFixedUserHandleMouseDown",onFixedUserHandleMouseEnter:"onFixedUserHandleMouseEnter",onFixedUserHandleMouseLeave:"onFixedUserHandleMouseLeave",onFixedUserHandleMouseUp:"onFixedUserHandleMouseUp",onImageLoad:"onImageLoad",onUserHandleMouseDown:"onUserHandleMouseDown",onUserHandleMouseEnter:"onUserHandleMouseEnter",onUserHandleMouseLeave:"onUserHandleMouseLeave",onUserHandleMouseUp:"onUserHandleMouseUp",positionChange:"positionChange",propertyChange:"propertyChange",rotateChange:"rotateChange",scrollChange:"scrollChange",segmentChange:"segmentChange",segmentCollectionChange:"segmentCollectionChange",selectionChange:"selectionChange",sizeChange:"sizeChange",sourcePointChange:"sourcePointChange",targetPointChange:"targetPointChange",textEdit:"textEdit"},features:[yn],decls:0,vars:0,template:function(e,i){},encapsulation:2,changeDetection:0}),gb([AT()],n.prototype,"annotationTemplate",void 0),gb([AT()],n.prototype,"nodeTemplate",void 0),gb([AT()],n.prototype,"userHandleTemplate",void 0),n=gb([Bae([u_])],n),n})(),Lle=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Lm({type:n}),n.\u0275inj=mp({imports:[[sq]]}),n})();const Nle=["diagram"];let Ole=(()=>{class n{constructor(){this.port1=[{id:"port1",offset:{x:.5,y:.5},visibility:ri.Visible,connectionDirection:"Right"}],this.port2=[{id:"port2",offset:{x:0,y:0},visibility:ri.Visible,connectionDirection:"Left"}]}portDirection(){this.diagram.nodes[0].ports[0].connectionDirection="Top"}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275cmp=Fb({type:n,selectors:[["app-container"]],viewQuery:function(i,r){if(1&i&&function uP(n,t,e){const i=Ti();i.firstCreatePass&&(cP(i,new aP(n,t,e),-1),2==(2&t)&&(i.staticViewQueries=!0)),hP(i,Se(),t)}(Nle,5),2&i){let s;Kr(s=en())&&(r.diagram=s.first)}},standalone:!0,features:[PP([]),RP],decls:9,vars:10,consts:[[3,"click"],["id","diagram","width","100%","height","580px"],["diagram",""],["id","node1",3,"offsetX","offsetY","width","height","ports"],["id","node2",3,"offsetX","offsetY","width","height","ports"],["id","connector","type","Orthogonal","sourceID","node1","sourcePortID","port1","targetID","node2","targetPortID","port2"]],template:function(i,r){1&i&&(Gu(0,"button",0),lw("click",function(){return r.portDirection()}),function MP(n,t=""){const e=Se(),i=Ti(),r=n+jt,s=i.firstCreatePass?Tu(i,r,1,t,null):i.data[r],o=wP(i,e,s,t,n);e[r]=o,Hm()&&hy(i,e,o,s),ll(s,!1)}(1,"Update Port Direction"),Xu(),Gu(2,"ejs-diagram",1,2)(4,"e-nodes"),jy(5,"e-node",3)(6,"e-node",4),Xu(),Gu(7,"e-connectors"),jy(8,"e-connector",5),Xu()()),2&i&&(pM(5),_y("offsetX",200)("offsetY",300)("width",100)("height",100)("ports",r.port1),pM(),_y("offsetX",400)("offsetY",200)("width",100)("height",100)("ports",r.port2))},dependencies:[Lle,Ale,v_,m_,y_,S_],encapsulation:2})}}return n})();jd(332),function $q(n,t){return DG({rootComponent:n,...Ez(t)})}(Ole).catch(n=>console.error(n))},332:()=>{!function(Z){const se=Z.performance;function ye(zi){se&&se.mark&&se.mark(zi)}function pe(zi,ht){se&&se.measure&&se.measure(zi,ht)}ye("Zone");const be=Z.__Zone_symbol_prefix||"__zone_symbol__";function ke(zi){return be+zi}const at=!0===Z[ke("forceDuplicateZoneCheck")];if(Z.Zone){if(at||"function"!=typeof Z.Zone.__symbol__)throw new Error("Zone already loaded.");return Z.Zone}let tt=(()=>{class zi{static{this.__symbol__=ke}static assertZonePatched(){if(Z.Promise!==_o.ZoneAwarePromise)throw new Error("Zone.js has detected that ZoneAwarePromise `(window|global).Promise` has been overwritten.\nMost likely cause is that a Promise polyfill has been loaded after Zone.js (Polyfilling Promise api is not necessary when zone.js is loaded. If you must load one, do so before loading zone.js.)")}static get root(){let F=zi.current;for(;F.parent;)F=F.parent;return F}static get current(){return Ur.zone}static get currentTask(){return Do}static __load_patch(F,ae,Et=!1){if(_o.hasOwnProperty(F)){if(!Et&&at)throw Error("Already loaded patch: "+F)}else if(!Z["__Zone_disable_"+F]){const Xt="Zone:"+F;ye(Xt),_o[F]=ae(Z,zi,cn),pe(Xt,Xt)}}get parent(){return this._parent}get name(){return this._name}constructor(F,ae){this._parent=F,this._name=ae?ae.name||"unnamed":"",this._properties=ae&&ae.properties||{},this._zoneDelegate=new Lt(this,this._parent&&this._parent._zoneDelegate,ae)}get(F){const ae=this.getZoneWith(F);if(ae)return ae._properties[F]}getZoneWith(F){let ae=this;for(;ae;){if(ae._properties.hasOwnProperty(F))return ae;ae=ae._parent}return null}fork(F){if(!F)throw new Error("ZoneSpec required!");return this._zoneDelegate.fork(this,F)}wrap(F,ae){if("function"!=typeof F)throw new Error("Expecting function got: "+F);const Et=this._zoneDelegate.intercept(this,F,ae),Xt=this;return function(){return Xt.runGuarded(Et,this,arguments,ae)}}run(F,ae,Et,Xt){Ur={parent:Ur,zone:this};try{return this._zoneDelegate.invoke(this,F,ae,Et,Xt)}finally{Ur=Ur.parent}}runGuarded(F,ae=null,Et,Xt){Ur={parent:Ur,zone:this};try{try{return this._zoneDelegate.invoke(this,F,ae,Et,Xt)}catch(Vn){if(this._zoneDelegate.handleError(this,Vn))throw Vn}}finally{Ur=Ur.parent}}runTask(F,ae,Et){if(F.zone!=this)throw new Error("A task can only be run in the zone of creation! (Creation: "+(F.zone||jn).name+"; Execution: "+this.name+")");if(F.state===sr&&(F.type===rs||F.type===Pt))return;const Xt=F.state!=lt;Xt&&F._transitionTo(lt,Pi),F.runCount++;const Vn=Do;Do=F,Ur={parent:Ur,zone:this};try{F.type==Pt&&F.data&&!F.data.isPeriodic&&(F.cancelFn=void 0);try{return this._zoneDelegate.invokeTask(this,F,ae,Et)}catch(Ue){if(this._zoneDelegate.handleError(this,Ue))throw Ue}}finally{F.state!==sr&&F.state!==et&&(F.type==rs||F.data&&F.data.isPeriodic?Xt&&F._transitionTo(Pi,lt):(F.runCount=0,this._updateTaskCount(F,-1),Xt&&F._transitionTo(sr,lt,sr))),Ur=Ur.parent,Do=Vn}}scheduleTask(F){if(F.zone&&F.zone!==this){let Et=this;for(;Et;){if(Et===F.zone)throw Error(`can not reschedule task to ${this.name} which is descendants of the original zone ${F.zone.name}`);Et=Et.parent}}F._transitionTo(Zr,sr);const ae=[];F._zoneDelegates=ae,F._zone=this;try{F=this._zoneDelegate.scheduleTask(this,F)}catch(Et){throw F._transitionTo(et,Zr,sr),this._zoneDelegate.handleError(this,Et),Et}return F._zoneDelegates===ae&&this._updateTaskCount(F,1),F.state==Zr&&F._transitionTo(Pi,Zr),F}scheduleMicroTask(F,ae,Et,Xt){return this.scheduleTask(new pt(yi,F,ae,Et,Xt,void 0))}scheduleMacroTask(F,ae,Et,Xt,Vn){return this.scheduleTask(new pt(Pt,F,ae,Et,Xt,Vn))}scheduleEventTask(F,ae,Et,Xt,Vn){return this.scheduleTask(new pt(rs,F,ae,Et,Xt,Vn))}cancelTask(F){if(F.zone!=this)throw new Error("A task can only be cancelled in the zone of creation! (Creation: "+(F.zone||jn).name+"; Execution: "+this.name+")");if(F.state===Pi||F.state===lt){F._transitionTo(dr,Pi,lt);try{this._zoneDelegate.cancelTask(this,F)}catch(ae){throw F._transitionTo(et,dr),this._zoneDelegate.handleError(this,ae),ae}return this._updateTaskCount(F,-1),F._transitionTo(sr,dr),F.runCount=0,F}}_updateTaskCount(F,ae){const Et=F._zoneDelegates;-1==ae&&(F._zoneDelegates=null);for(let Xt=0;Xtzi.hasTask(F,ae),onScheduleTask:(zi,ht,F,ae)=>zi.scheduleTask(F,ae),onInvokeTask:(zi,ht,F,ae,Et,Xt)=>zi.invokeTask(F,ae,Et,Xt),onCancelTask:(zi,ht,F,ae)=>zi.cancelTask(F,ae)};class Lt{constructor(ht,F,ae){this._taskCounts={microTask:0,macroTask:0,eventTask:0},this.zone=ht,this._parentDelegate=F,this._forkZS=ae&&(ae&&ae.onFork?ae:F._forkZS),this._forkDlgt=ae&&(ae.onFork?F:F._forkDlgt),this._forkCurrZone=ae&&(ae.onFork?this.zone:F._forkCurrZone),this._interceptZS=ae&&(ae.onIntercept?ae:F._interceptZS),this._interceptDlgt=ae&&(ae.onIntercept?F:F._interceptDlgt),this._interceptCurrZone=ae&&(ae.onIntercept?this.zone:F._interceptCurrZone),this._invokeZS=ae&&(ae.onInvoke?ae:F._invokeZS),this._invokeDlgt=ae&&(ae.onInvoke?F:F._invokeDlgt),this._invokeCurrZone=ae&&(ae.onInvoke?this.zone:F._invokeCurrZone),this._handleErrorZS=ae&&(ae.onHandleError?ae:F._handleErrorZS),this._handleErrorDlgt=ae&&(ae.onHandleError?F:F._handleErrorDlgt),this._handleErrorCurrZone=ae&&(ae.onHandleError?this.zone:F._handleErrorCurrZone),this._scheduleTaskZS=ae&&(ae.onScheduleTask?ae:F._scheduleTaskZS),this._scheduleTaskDlgt=ae&&(ae.onScheduleTask?F:F._scheduleTaskDlgt),this._scheduleTaskCurrZone=ae&&(ae.onScheduleTask?this.zone:F._scheduleTaskCurrZone),this._invokeTaskZS=ae&&(ae.onInvokeTask?ae:F._invokeTaskZS),this._invokeTaskDlgt=ae&&(ae.onInvokeTask?F:F._invokeTaskDlgt),this._invokeTaskCurrZone=ae&&(ae.onInvokeTask?this.zone:F._invokeTaskCurrZone),this._cancelTaskZS=ae&&(ae.onCancelTask?ae:F._cancelTaskZS),this._cancelTaskDlgt=ae&&(ae.onCancelTask?F:F._cancelTaskDlgt),this._cancelTaskCurrZone=ae&&(ae.onCancelTask?this.zone:F._cancelTaskCurrZone),this._hasTaskZS=null,this._hasTaskDlgt=null,this._hasTaskDlgtOwner=null,this._hasTaskCurrZone=null;const Et=ae&&ae.onHasTask;(Et||F&&F._hasTaskZS)&&(this._hasTaskZS=Et?ae:At,this._hasTaskDlgt=F,this._hasTaskDlgtOwner=this,this._hasTaskCurrZone=ht,ae.onScheduleTask||(this._scheduleTaskZS=At,this._scheduleTaskDlgt=F,this._scheduleTaskCurrZone=this.zone),ae.onInvokeTask||(this._invokeTaskZS=At,this._invokeTaskDlgt=F,this._invokeTaskCurrZone=this.zone),ae.onCancelTask||(this._cancelTaskZS=At,this._cancelTaskDlgt=F,this._cancelTaskCurrZone=this.zone))}fork(ht,F){return this._forkZS?this._forkZS.onFork(this._forkDlgt,this.zone,ht,F):new tt(ht,F)}intercept(ht,F,ae){return this._interceptZS?this._interceptZS.onIntercept(this._interceptDlgt,this._interceptCurrZone,ht,F,ae):F}invoke(ht,F,ae,Et,Xt){return this._invokeZS?this._invokeZS.onInvoke(this._invokeDlgt,this._invokeCurrZone,ht,F,ae,Et,Xt):F.apply(ae,Et)}handleError(ht,F){return!this._handleErrorZS||this._handleErrorZS.onHandleError(this._handleErrorDlgt,this._handleErrorCurrZone,ht,F)}scheduleTask(ht,F){let ae=F;if(this._scheduleTaskZS)this._hasTaskZS&&ae._zoneDelegates.push(this._hasTaskDlgtOwner),ae=this._scheduleTaskZS.onScheduleTask(this._scheduleTaskDlgt,this._scheduleTaskCurrZone,ht,F),ae||(ae=F);else if(F.scheduleFn)F.scheduleFn(F);else{if(F.type!=yi)throw new Error("Task is missing scheduleFn.");Wt(F)}return ae}invokeTask(ht,F,ae,Et){return this._invokeTaskZS?this._invokeTaskZS.onInvokeTask(this._invokeTaskDlgt,this._invokeTaskCurrZone,ht,F,ae,Et):F.callback.apply(ae,Et)}cancelTask(ht,F){let ae;if(this._cancelTaskZS)ae=this._cancelTaskZS.onCancelTask(this._cancelTaskDlgt,this._cancelTaskCurrZone,ht,F);else{if(!F.cancelFn)throw Error("Task is not cancelable");ae=F.cancelFn(F)}return ae}hasTask(ht,F){try{this._hasTaskZS&&this._hasTaskZS.onHasTask(this._hasTaskDlgt,this._hasTaskCurrZone,ht,F)}catch(ae){this.handleError(ht,ae)}}_updateTaskCount(ht,F){const ae=this._taskCounts,Et=ae[ht],Xt=ae[ht]=Et+F;if(Xt<0)throw new Error("More tasks executed then were scheduled.");0!=Et&&0!=Xt||this.hasTask(this.zone,{microTask:ae.microTask>0,macroTask:ae.macroTask>0,eventTask:ae.eventTask>0,change:ht})}}class pt{constructor(ht,F,ae,Et,Xt,Vn){if(this._zone=null,this.runCount=0,this._zoneDelegates=null,this._state="notScheduled",this.type=ht,this.source=F,this.data=Et,this.scheduleFn=Xt,this.cancelFn=Vn,!ae)throw new Error("callback is not defined");this.callback=ae;const Ue=this;this.invoke=ht===rs&&Et&&Et.useG?pt.invokeTask:function(){return pt.invokeTask.call(Z,Ue,this,arguments)}}static invokeTask(ht,F,ae){ht||(ht=this),Ls++;try{return ht.runCount++,ht.zone.runTask(ht,F,ae)}finally{1==Ls&&ct(),Ls--}}get zone(){return this._zone}get state(){return this._state}cancelScheduleRequest(){this._transitionTo(sr,Zr)}_transitionTo(ht,F,ae){if(this._state!==F&&this._state!==ae)throw new Error(`${this.type} '${this.source}': can not transition to '${ht}', expecting state '${F}'${ae?" or '"+ae+"'":""}, was '${this._state}'.`);this._state=ht,ht==sr&&(this._zoneDelegates=null)}toString(){return this.data&&typeof this.data.handleId<"u"?this.data.handleId.toString():Object.prototype.toString.call(this)}toJSON(){return{type:this.type,state:this.state,source:this.source,zone:this.zone.name,runCount:this.runCount}}}const Di=ke("setTimeout"),si=ke("Promise"),mi=ke("then");let is,cr=[],ki=!1;function Pr(zi){if(is||Z[si]&&(is=Z[si].resolve(0)),is){let ht=is[mi];ht||(ht=is.then),ht.call(is,zi)}else Z[Di](zi,0)}function Wt(zi){0===Ls&&0===cr.length&&Pr(ct),zi&&cr.push(zi)}function ct(){if(!ki){for(ki=!0;cr.length;){const zi=cr;cr=[];for(let ht=0;htUr,onUnhandledError:jr,microtaskDrainDone:jr,scheduleMicroTask:Wt,showUncaughtError:()=>!tt[ke("ignoreConsoleErrorUncaughtError")],patchEventTarget:()=>[],patchOnProperties:jr,patchMethod:()=>jr,bindArguments:()=>[],patchThen:()=>jr,patchMacroTask:()=>jr,patchEventPrototype:()=>jr,isIEOrEdge:()=>!1,getGlobalObjects:()=>{},ObjectDefineProperty:()=>jr,ObjectGetOwnPropertyDescriptor:()=>{},ObjectCreate:()=>{},ArraySlice:()=>[],patchClass:()=>jr,wrapWithCurrentZone:()=>jr,filterProperties:()=>[],attachOriginToPatched:()=>jr,_redefineProperty:()=>jr,patchCallbacks:()=>jr,nativeScheduleMicroTask:Pr};let Ur={parent:null,zone:new tt(null,null)},Do=null,Ls=0;function jr(){}pe("Zone","Zone"),Z.Zone=tt}(globalThis);const Wl=Object.getOwnPropertyDescriptor,Ud=Object.defineProperty,jd=Object.getPrototypeOf,Vd=Object.create,yb=Array.prototype.slice,pm="addEventListener",$r="removeEventListener",Yl=Zone.__symbol__(pm),_h=Zone.__symbol__($r),Ts="true",Wi="false",Wd=Zone.__symbol__("");function lp(Z,se){return Zone.current.wrap(Z,se)}function gm(Z,se,ye,pe,be){return Zone.current.scheduleMacroTask(Z,se,ye,pe,be)}const Ji=Zone.__symbol__,Uh=typeof window<"u",jh=Uh?window:void 0,gn=Uh&&jh||globalThis,vm="removeAttribute";function Yd(Z,se){for(let ye=Z.length-1;ye>=0;ye--)"function"==typeof Z[ye]&&(Z[ye]=lp(Z[ye],se+"_"+ye));return Z}function hp(Z){return!Z||!1!==Z.writable&&!("function"==typeof Z.get&&typeof Z.set>"u")}const cp=typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope,Vh=!("nw"in gn)&&typeof gn.process<"u"&&"[object process]"==={}.toString.call(gn.process),Qd=!Vh&&!cp&&!(!Uh||!jh.HTMLElement),dp=typeof gn.process<"u"&&"[object process]"==={}.toString.call(gn.process)&&!cp&&!(!Uh||!jh.HTMLElement),Ql={},Wh=function(Z){if(!(Z=Z||gn.event))return;let se=Ql[Z.type];se||(se=Ql[Z.type]=Ji("ON_PROPERTY"+Z.type));const ye=this||Z.target||gn,pe=ye[se];let be;return Qd&&ye===jh&&"error"===Z.type?(be=pe&&pe.call(this,Z.message,Z.filename,Z.lineno,Z.colno,Z.error),!0===be&&Z.preventDefault()):(be=pe&&pe.apply(this,arguments),null!=be&&!be&&Z.preventDefault()),be};function Gl(Z,se,ye){let pe=Wl(Z,se);if(!pe&&ye&&Wl(ye,se)&&(pe={enumerable:!0,configurable:!0}),!pe||!pe.configurable)return;const be=Ji("on"+se+"patched");if(Z.hasOwnProperty(be)&&Z[be])return;delete pe.writable,delete pe.value;const ke=pe.get,at=pe.set,tt=se.slice(2);let At=Ql[tt];At||(At=Ql[tt]=Ji("ON_PROPERTY"+tt)),pe.set=function(Lt){let pt=this;!pt&&Z===gn&&(pt=gn),pt&&("function"==typeof pt[At]&&pt.removeEventListener(tt,Wh),at&&at.call(pt,null),pt[At]=Lt,"function"==typeof Lt&&pt.addEventListener(tt,Wh,!1))},pe.get=function(){let Lt=this;if(!Lt&&Z===gn&&(Lt=gn),!Lt)return null;const pt=Lt[At];if(pt)return pt;if(ke){let Di=ke.call(this);if(Di)return pe.set.call(this,Di),"function"==typeof Lt[vm]&&Lt.removeAttribute(se),Di}return null},Ud(Z,se,pe),Z[be]=!0}function up(Z,se,ye){if(se)for(let pe=0;pefunction(at,tt){const At=ye(at,tt);return At.cbIdx>=0&&"function"==typeof tt[At.cbIdx]?gm(At.name,tt[At.cbIdx],At,be):ke.apply(at,tt)})}function Ia(Z,se){Z[Ji("OriginalDelegate")]=se}let Ib=!1,Xd=!1;function bb(){if(Ib)return Xd;Ib=!0;try{const Z=jh.navigator.userAgent;(-1!==Z.indexOf("MSIE ")||-1!==Z.indexOf("Trident/")||-1!==Z.indexOf("Edge/"))&&(Xd=!0)}catch{}return Xd}Zone.__load_patch("ZoneAwarePromise",(Z,se,ye)=>{const pe=Object.getOwnPropertyDescriptor,be=Object.defineProperty,at=ye.symbol,tt=[],At=!1!==Z[at("DISABLE_WRAPPING_UNCAUGHT_PROMISE_REJECTION")],Lt=at("Promise"),pt=at("then"),Di="__creationTrace__";ye.onUnhandledError=Ue=>{if(ye.showUncaughtError()){const He=Ue&&Ue.rejection;He?console.error("Unhandled Promise rejection:",He instanceof Error?He.message:He,"; Zone:",Ue.zone.name,"; Task:",Ue.task&&Ue.task.source,"; Value:",He,He instanceof Error?He.stack:void 0):console.error(Ue)}},ye.microtaskDrainDone=()=>{for(;tt.length;){const Ue=tt.shift();try{Ue.zone.runGuarded(()=>{throw Ue.throwOriginal?Ue.rejection:Ue})}catch(He){mi(He)}}};const si=at("unhandledPromiseRejectionHandler");function mi(Ue){ye.onUnhandledError(Ue);try{const He=se[si];"function"==typeof He&&He.call(this,Ue)}catch{}}function cr(Ue){return Ue&&Ue.then}function ki(Ue){return Ue}function is(Ue){return F.reject(Ue)}const Pr=at("state"),Wt=at("value"),ct=at("finally"),jn=at("parentPromiseValue"),sr=at("parentPromiseState"),Zr="Promise.then",Pi=null,lt=!0,dr=!1,et=0;function yi(Ue,He){return ge=>{try{cn(Ue,He,ge)}catch(We){cn(Ue,!1,We)}}}const Pt=function(){let Ue=!1;return function(ge){return function(){Ue||(Ue=!0,ge.apply(null,arguments))}}},rs="Promise resolved with itself",_o=at("currentTaskTrace");function cn(Ue,He,ge){const We=Pt();if(Ue===ge)throw new TypeError(rs);if(Ue[Pr]===Pi){let wt=null;try{("object"==typeof ge||"function"==typeof ge)&&(wt=ge&&ge.then)}catch(Xe){return We(()=>{cn(Ue,!1,Xe)})(),Ue}if(He!==dr&&ge instanceof F&&ge.hasOwnProperty(Pr)&&ge.hasOwnProperty(Wt)&&ge[Pr]!==Pi)Do(ge),cn(Ue,ge[Pr],ge[Wt]);else if(He!==dr&&"function"==typeof wt)try{wt.call(ge,We(yi(Ue,He)),We(yi(Ue,!1)))}catch(Xe){We(()=>{cn(Ue,!1,Xe)})()}else{Ue[Pr]=He;const Xe=Ue[Wt];if(Ue[Wt]=ge,Ue[ct]===ct&&He===lt&&(Ue[Pr]=Ue[sr],Ue[Wt]=Ue[jn]),He===dr&&ge instanceof Error){const mt=se.currentTask&&se.currentTask.data&&se.currentTask.data[Di];mt&&be(ge,_o,{configurable:!0,enumerable:!1,writable:!0,value:mt})}for(let mt=0;mt{try{const dt=Ue[Wt],qt=!!ge&&ct===ge[ct];qt&&(ge[jn]=dt,ge[sr]=Xe);const hi=He.run(mt,void 0,qt&&mt!==is&&mt!==ki?[]:[dt]);cn(ge,!0,hi)}catch(dt){cn(ge,!1,dt)}},ge)}const zi=function(){},ht=Z.AggregateError;class F{static toString(){return"function ZoneAwarePromise() { [native code] }"}static resolve(He){return He instanceof F?He:cn(new this(null),lt,He)}static reject(He){return cn(new this(null),dr,He)}static withResolvers(){const He={};return He.promise=new F((ge,We)=>{He.resolve=ge,He.reject=We}),He}static any(He){if(!He||"function"!=typeof He[Symbol.iterator])return Promise.reject(new ht([],"All promises were rejected"));const ge=[];let We=0;try{for(let mt of He)We++,ge.push(F.resolve(mt))}catch{return Promise.reject(new ht([],"All promises were rejected"))}if(0===We)return Promise.reject(new ht([],"All promises were rejected"));let wt=!1;const Xe=[];return new F((mt,dt)=>{for(let qt=0;qt{wt||(wt=!0,mt(hi))},hi=>{Xe.push(hi),We--,0===We&&(wt=!0,dt(new ht(Xe,"All promises were rejected")))})})}static race(He){let ge,We,wt=new this((dt,qt)=>{ge=dt,We=qt});function Xe(dt){ge(dt)}function mt(dt){We(dt)}for(let dt of He)cr(dt)||(dt=this.resolve(dt)),dt.then(Xe,mt);return wt}static all(He){return F.allWithCallback(He)}static allSettled(He){return(this&&this.prototype instanceof F?this:F).allWithCallback(He,{thenCallback:We=>({status:"fulfilled",value:We}),errorCallback:We=>({status:"rejected",reason:We})})}static allWithCallback(He,ge){let We,wt,Xe=new this((hi,ur)=>{We=hi,wt=ur}),mt=2,dt=0;const qt=[];for(let hi of He){cr(hi)||(hi=this.resolve(hi));const ur=dt;try{hi.then(ir=>{qt[ur]=ge?ge.thenCallback(ir):ir,mt--,0===mt&&We(qt)},ir=>{ge?(qt[ur]=ge.errorCallback(ir),mt--,0===mt&&We(qt)):wt(ir)})}catch(ir){wt(ir)}mt++,dt++}return mt-=2,0===mt&&We(qt),Xe}constructor(He){const ge=this;if(!(ge instanceof F))throw new Error("Must be an instanceof Promise.");ge[Pr]=Pi,ge[Wt]=[];try{const We=Pt();He&&He(We(yi(ge,lt)),We(yi(ge,dr)))}catch(We){cn(ge,!1,We)}}get[Symbol.toStringTag](){return"Promise"}get[Symbol.species](){return F}then(He,ge){let We=this.constructor?.[Symbol.species];(!We||"function"!=typeof We)&&(We=this.constructor||F);const wt=new We(zi),Xe=se.current;return this[Pr]==Pi?this[Wt].push(Xe,wt,He,ge):Ls(this,Xe,wt,He,ge),wt}catch(He){return this.then(null,He)}finally(He){let ge=this.constructor?.[Symbol.species];(!ge||"function"!=typeof ge)&&(ge=F);const We=new ge(zi);We[ct]=ct;const wt=se.current;return this[Pr]==Pi?this[Wt].push(wt,We,He,He):Ls(this,wt,We,He,He),We}}F.resolve=F.resolve,F.reject=F.reject,F.race=F.race,F.all=F.all;const ae=Z[Lt]=Z.Promise;Z.Promise=F;const Et=at("thenPatched");function Xt(Ue){const He=Ue.prototype,ge=pe(He,"then");if(ge&&(!1===ge.writable||!ge.configurable))return;const We=He.then;He[pt]=We,Ue.prototype.then=function(wt,Xe){return new F((dt,qt)=>{We.call(this,dt,qt)}).then(wt,Xe)},Ue[Et]=!0}return ye.patchThen=Xt,ae&&(Xt(ae),tl(Z,"fetch",Ue=>function Vn(Ue){return function(He,ge){let We=Ue.apply(He,ge);if(We instanceof F)return We;let wt=We.constructor;return wt[Et]||Xt(wt),We}}(Ue))),Promise[se.__symbol__("uncaughtPromiseErrors")]=tt,F}),Zone.__load_patch("toString",Z=>{const se=Function.prototype.toString,ye=Ji("OriginalDelegate"),pe=Ji("Promise"),be=Ji("Error"),ke=function(){if("function"==typeof this){const Lt=this[ye];if(Lt)return"function"==typeof Lt?se.call(Lt):Object.prototype.toString.call(Lt);if(this===Promise){const pt=Z[pe];if(pt)return se.call(pt)}if(this===Error){const pt=Z[be];if(pt)return se.call(pt)}}return se.call(this)};ke[ye]=se,Function.prototype.toString=ke;const at=Object.prototype.toString;Object.prototype.toString=function(){return"function"==typeof Promise&&this instanceof Promise?"[object Promise]":at.call(this)}});let il=!1;if(typeof window<"u")try{const Z=Object.defineProperty({},"passive",{get:function(){il=!0}});window.addEventListener("test",Z,Z),window.removeEventListener("test",Z,Z)}catch{il=!1}const PT={useG:!0},Co={},Mb={},Sm=new RegExp("^"+Wd+"(\\w+)(true|false)$"),wb=Ji("propagationStopped");function Im(Z,se){const ye=(se?se(Z):Z)+Wi,pe=(se?se(Z):Z)+Ts,be=Wd+ye,ke=Wd+pe;Co[Z]={},Co[Z][Wi]=be,Co[Z][Ts]=ke}function Cb(Z,se,ye,pe){const be=pe&&pe.add||pm,ke=pe&&pe.rm||$r,at=pe&&pe.listeners||"eventListeners",tt=pe&&pe.rmAll||"removeAllListeners",At=Ji(be),Lt="."+be+":",pt="prependListener",Di="."+pt+":",si=function(Wt,ct,jn){if(Wt.isRemoved)return;const sr=Wt.callback;let Zr;"object"==typeof sr&&sr.handleEvent&&(Wt.callback=lt=>sr.handleEvent(lt),Wt.originalDelegate=sr);try{Wt.invoke(Wt,ct,[jn])}catch(lt){Zr=lt}const Pi=Wt.options;return Pi&&"object"==typeof Pi&&Pi.once&&ct[ke].call(ct,jn.type,Wt.originalDelegate?Wt.originalDelegate:Wt.callback,Pi),Zr};function mi(Wt,ct,jn){if(!(ct=ct||Z.event))return;const sr=Wt||ct.target||Z,Zr=sr[Co[ct.type][jn?Ts:Wi]];if(Zr){const Pi=[];if(1===Zr.length){const lt=si(Zr[0],sr,ct);lt&&Pi.push(lt)}else{const lt=Zr.slice();for(let dr=0;dr{throw dr})}}}const cr=function(Wt){return mi(this,Wt,!1)},ki=function(Wt){return mi(this,Wt,!0)};function is(Wt,ct){if(!Wt)return!1;let jn=!0;ct&&void 0!==ct.useG&&(jn=ct.useG);const sr=ct&&ct.vh;let Zr=!0;ct&&void 0!==ct.chkDup&&(Zr=ct.chkDup);let Pi=!1;ct&&void 0!==ct.rt&&(Pi=ct.rt);let lt=Wt;for(;lt&&!lt.hasOwnProperty(be);)lt=jd(lt);if(!lt&&Wt[be]&&(lt=Wt),!lt||lt[At])return!1;const dr=ct&&ct.eventNameToString,et={},yi=lt[At]=lt[be],Pt=lt[Ji(ke)]=lt[ke],rs=lt[Ji(at)]=lt[at],_o=lt[Ji(tt)]=lt[tt];let cn;ct&&ct.prepend&&(cn=lt[Ji(ct.prepend)]=lt[ct.prepend]);const F=jn?function(ge){if(!et.isExisting)return yi.call(et.target,et.eventName,et.capture?ki:cr,et.options)}:function(ge){return yi.call(et.target,et.eventName,ge.invoke,et.options)},ae=jn?function(ge){if(!ge.isRemoved){const We=Co[ge.eventName];let wt;We&&(wt=We[ge.capture?Ts:Wi]);const Xe=wt&&ge.target[wt];if(Xe)for(let mt=0;mt{Vo.zone.cancelTask(Vo)},{once:!0})),et.target=null,Fc&&(Fc.taskData=null),$d&&(Tn.once=!0),!il&&"boolean"==typeof Vo.options||(Vo.options=Tn),Vo.target=qt,Vo.capture=Zl,Vo.eventName=hi,ir&&(Vo.originalDelegate=ur),dt?jo.unshift(Vo):jo.push(Vo),mt?qt:void 0}};return lt[be]=He(yi,Lt,F,ae,Pi),cn&&(lt[pt]=He(cn,Di,function(ge){return cn.call(et.target,et.eventName,ge.invoke,et.options)},ae,Pi,!0)),lt[ke]=function(){const ge=this||Z;let We=arguments[0];ct&&ct.transferEventName&&(We=ct.transferEventName(We));const wt=arguments[2],Xe=!!wt&&("boolean"==typeof wt||wt.capture),mt=arguments[1];if(!mt)return Pt.apply(this,arguments);if(sr&&!sr(Pt,mt,ge,arguments))return;const dt=Co[We];let qt;dt&&(qt=dt[Xe?Ts:Wi]);const hi=qt&&ge[qt];if(hi)for(let ur=0;urfunction(be,ke){be[wb]=!0,pe&&pe.apply(be,ke)})}function Db(Z,se,ye,pe,be){const ke=Zone.__symbol__(pe);if(se[ke])return;const at=se[ke]=se[pe];se[pe]=function(tt,At,Lt){return At&&At.prototype&&be.forEach(function(pt){const Di=`${ye}.${pe}::`+pt,si=At.prototype;try{if(si.hasOwnProperty(pt)){const mi=Z.ObjectGetOwnPropertyDescriptor(si,pt);mi&&mi.value?(mi.value=Z.wrapWithCurrentZone(mi.value,Di),Z._redefineProperty(At.prototype,pt,mi)):si[pt]&&(si[pt]=Z.wrapWithCurrentZone(si[pt],Di))}else si[pt]&&(si[pt]=Z.wrapWithCurrentZone(si[pt],Di))}catch{}}),at.call(se,tt,At,Lt)},Z.attachOriginToPatched(se[pe],at)}function xb(Z,se,ye){if(!ye||0===ye.length)return se;const pe=ye.filter(ke=>ke.target===Z);if(!pe||0===pe.length)return se;const be=pe[0].ignoreProperties;return se.filter(ke=>-1===be.indexOf(ke))}function Eo(Z,se,ye,pe){Z&&up(Z,xb(Z,se,ye),pe)}function qd(Z){return Object.getOwnPropertyNames(Z).filter(se=>se.startsWith("on")&&se.length>2).map(se=>se.substring(2))}Zone.__load_patch("util",(Z,se,ye)=>{const pe=qd(Z);ye.patchOnProperties=up,ye.patchMethod=tl,ye.bindArguments=Yd,ye.patchMacroTask=Sb;const be=se.__symbol__("BLACK_LISTED_EVENTS"),ke=se.__symbol__("UNPATCHED_EVENTS");Z[ke]&&(Z[be]=Z[ke]),Z[be]&&(se[be]=se[ke]=Z[be]),ye.patchEventPrototype=bm,ye.patchEventTarget=Cb,ye.isIEOrEdge=bb,ye.ObjectDefineProperty=Ud,ye.ObjectGetOwnPropertyDescriptor=Wl,ye.ObjectCreate=Vd,ye.ArraySlice=yb,ye.patchClass=Gd,ye.wrapWithCurrentZone=lp,ye.filterProperties=xb,ye.attachOriginToPatched=Ia,ye._redefineProperty=Object.defineProperty,ye.patchCallbacks=Db,ye.getGlobalObjects=()=>({globalSources:Mb,zoneSymbolEventNames:Co,eventNames:pe,isBrowser:Qd,isMix:dp,isNode:Vh,TRUE_STR:Ts,FALSE_STR:Wi,ZONE_SYMBOL_PREFIX:Wd,ADD_EVENT_LISTENER_STR:pm,REMOVE_EVENT_LISTENER_STR:$r})});const As=Ji("zoneTask");function Xl(Z,se,ye,pe){let be=null,ke=null;ye+=pe;const at={};function tt(Lt){const pt=Lt.data;return pt.args[0]=function(){return Lt.invoke.apply(this,arguments)},pt.handleId=be.apply(Z,pt.args),Lt}function At(Lt){return ke.call(Z,Lt.data.handleId)}be=tl(Z,se+=pe,Lt=>function(pt,Di){if("function"==typeof Di[0]){const si={isPeriodic:"Interval"===pe,delay:"Timeout"===pe||"Interval"===pe?Di[1]||0:void 0,args:Di},mi=Di[0];Di[0]=function(){try{return mi.apply(this,arguments)}finally{si.isPeriodic||("number"==typeof si.handleId?delete at[si.handleId]:si.handleId&&(si.handleId[As]=null))}};const cr=gm(se,Di[0],si,tt,At);if(!cr)return cr;const ki=cr.data.handleId;return"number"==typeof ki?at[ki]=cr:ki&&(ki[As]=cr),ki&&ki.ref&&ki.unref&&"function"==typeof ki.ref&&"function"==typeof ki.unref&&(cr.ref=ki.ref.bind(ki),cr.unref=ki.unref.bind(ki)),"number"==typeof ki||ki?ki:cr}return Lt.apply(Z,Di)}),ke=tl(Z,ye,Lt=>function(pt,Di){const si=Di[0];let mi;"number"==typeof si?mi=at[si]:(mi=si&&si[As],mi||(mi=si)),mi&&"string"==typeof mi.type?"notScheduled"!==mi.state&&(mi.cancelFn&&mi.data.isPeriodic||0===mi.runCount)&&("number"==typeof si?delete at[si]:si&&(si[As]=null),mi.zone.cancelTask(mi)):Lt.apply(Z,Di)})}Zone.__load_patch("legacy",Z=>{const se=Z[Zone.__symbol__("legacyPatch")];se&&se()}),Zone.__load_patch("timers",Z=>{const ye="clear";Xl(Z,"set",ye,"Timeout"),Xl(Z,"set",ye,"Interval"),Xl(Z,"set",ye,"Immediate")}),Zone.__load_patch("requestAnimationFrame",Z=>{Xl(Z,"request","cancel","AnimationFrame"),Xl(Z,"mozRequest","mozCancel","AnimationFrame"),Xl(Z,"webkitRequest","webkitCancel","AnimationFrame")}),Zone.__load_patch("blocking",(Z,se)=>{const ye=["alert","prompt","confirm"];for(let pe=0;pefunction(At,Lt){return se.current.run(ke,Z,Lt,tt)})}),Zone.__load_patch("EventTarget",(Z,se,ye)=>{(function ql(Z,se){se.patchEventPrototype(Z,se)})(Z,ye),function wm(Z,se){if(Zone[se.symbol("patchEventTarget")])return;const{eventNames:ye,zoneSymbolEventNames:pe,TRUE_STR:be,FALSE_STR:ke,ZONE_SYMBOL_PREFIX:at}=se.getGlobalObjects();for(let At=0;At{Gd("MutationObserver"),Gd("WebKitMutationObserver")}),Zone.__load_patch("IntersectionObserver",(Z,se,ye)=>{Gd("IntersectionObserver")}),Zone.__load_patch("FileReader",(Z,se,ye)=>{Gd("FileReader")}),Zone.__load_patch("on_property",(Z,se,ye)=>{!function fp(Z,se){if(Vh&&!dp||Zone[Z.symbol("patchEvents")])return;const ye=se.__Zone_ignore_on_properties;let pe=[];if(Qd){const be=window;pe=pe.concat(["Document","SVGElement","Element","HTMLElement","HTMLBodyElement","HTMLMediaElement","HTMLFrameSetElement","HTMLFrameElement","HTMLIFrameElement","HTMLMarqueeElement","Worker"]);const ke=function ym(){try{const Z=jh.navigator.userAgent;if(-1!==Z.indexOf("MSIE ")||-1!==Z.indexOf("Trident/"))return!0}catch{}return!1}()?[{target:be,ignoreProperties:["error"]}]:[];Eo(be,qd(be),ye&&ye.concat(ke),jd(be))}pe=pe.concat(["XMLHttpRequest","XMLHttpRequestEventTarget","IDBIndex","IDBRequest","IDBOpenDBRequest","IDBDatabase","IDBTransaction","IDBCursor","WebSocket"]);for(let be=0;be{!function Mm(Z,se){const{isBrowser:ye,isMix:pe}=se.getGlobalObjects();(ye||pe)&&Z.customElements&&"customElements"in Z&&se.patchCallbacks(se,Z.customElements,"customElements","define",["connectedCallback","disconnectedCallback","adoptedCallback","attributeChangedCallback"])}(Z,ye)}),Zone.__load_patch("XHR",(Z,se)=>{!function At(Lt){const pt=Lt.XMLHttpRequest;if(!pt)return;const Di=pt.prototype;let mi=Di[Yl],cr=Di[_h];if(!mi){const et=Lt.XMLHttpRequestEventTarget;if(et){const yi=et.prototype;mi=yi[Yl],cr=yi[_h]}}const ki="readystatechange",is="scheduled";function Pr(et){const yi=et.data,Pt=yi.target;Pt[ke]=!1,Pt[tt]=!1;const rs=Pt[be];mi||(mi=Pt[Yl],cr=Pt[_h]),rs&&cr.call(Pt,ki,rs);const _o=Pt[be]=()=>{if(Pt.readyState===Pt.DONE)if(!yi.aborted&&Pt[ke]&&et.state===is){const Ur=Pt[se.__symbol__("loadfalse")];if(0!==Pt.status&&Ur&&Ur.length>0){const Do=et.invoke;et.invoke=function(){const Ls=Pt[se.__symbol__("loadfalse")];for(let jr=0;jrfunction(et,yi){return et[pe]=0==yi[2],et[at]=yi[1],jn.apply(et,yi)}),Zr=Ji("fetchTaskAborting"),Pi=Ji("fetchTaskScheduling"),lt=tl(Di,"send",()=>function(et,yi){if(!0===se.current[Pi]||et[pe])return lt.apply(et,yi);{const Pt={target:et,url:et[at],isPeriodic:!1,args:yi,aborted:!1},rs=gm("XMLHttpRequest.send",Wt,Pt,Pr,ct);et&&!0===et[tt]&&!Pt.aborted&&rs.state===is&&rs.invoke()}}),dr=tl(Di,"abort",()=>function(et,yi){const Pt=function si(et){return et[ye]}(et);if(Pt&&"string"==typeof Pt.type){if(null==Pt.cancelFn||Pt.data&&Pt.data.aborted)return;Pt.zone.cancelTask(Pt)}else if(!0===se.current[Zr])return dr.apply(et,yi)})}(Z);const ye=Ji("xhrTask"),pe=Ji("xhrSync"),be=Ji("xhrListener"),ke=Ji("xhrScheduled"),at=Ji("xhrURL"),tt=Ji("xhrErrorBeforeScheduled")}),Zone.__load_patch("geolocation",Z=>{Z.navigator&&Z.navigator.geolocation&&function mm(Z,se){const ye=Z.constructor.name;for(let pe=0;pe{const At=function(){return tt.apply(this,Yd(arguments,ye+"."+be))};return Ia(At,tt),At})(ke)}}}(Z.navigator.geolocation,["getCurrentPosition","watchPosition"])}),Zone.__load_patch("PromiseRejectionEvent",(Z,se)=>{function ye(pe){return function(be){Eb(Z,pe).forEach(at=>{const tt=Z.PromiseRejectionEvent;if(tt){const At=new tt(pe,{promise:be.promise,reason:be.rejection});at.invoke(At)}})}}Z.PromiseRejectionEvent&&(se[Ji("unhandledPromiseRejectionHandler")]=ye("unhandledrejection"),se[Ji("rejectionHandledHandler")]=ye("rejectionhandled"))}),Zone.__load_patch("queueMicrotask",(Z,se,ye)=>{!function pp(Z,se){se.patchMethod(Z,"queueMicrotask",ye=>function(pe,be){Zone.current.scheduleMicroTask("queueMicrotask",be[0])})}(Z,ye)})}},Wl=>{Wl(Wl.s=51)}]); \ No newline at end of file diff --git a/ej2-angular/samples/diagram/ports/edges-cs1/index.html b/ej2-angular/samples/diagram/ports/edges-cs1/index.html index a1de2f5e96..3ab6de0039 100644 --- a/ej2-angular/samples/diagram/ports/edges-cs1/index.html +++ b/ej2-angular/samples/diagram/ports/edges-cs1/index.html @@ -19,5 +19,5 @@
Loading....
- + \ No newline at end of file diff --git a/ej2-angular/samples/diagram/ports/edges-cs1/main.023313dfd9f60d96.js b/ej2-angular/samples/diagram/ports/edges-cs1/main.023313dfd9f60d96.js deleted file mode 100644 index 8291df1874..0000000000 --- a/ej2-angular/samples/diagram/ports/edges-cs1/main.023313dfd9f60d96.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";(self.webpackChunksyncfusion_component=self.webpackChunksyncfusion_component||[]).push([[179],{51:(_l,jd,Vd)=>{let $r=null,Fh=1;const Ts=Symbol("SIGNAL");function Wi(n){const t=$r;return $r=n,t}function gn(n){if((!Vh(n)||n.dirty)&&(n.dirty||n.lastCleanEpoch!==Fh)){if(!n.producerMustRecompute(n)&&!jh(n))return n.dirty=!1,void(n.lastCleanEpoch=Fh);n.producerRecomputeValue(n),n.dirty=!1,n.lastCleanEpoch=Fh}}function jh(n){Vl(n);for(let t=0;t0}function Vl(n){n.producerNode??=[],n.producerIndexOfThis??=[],n.producerLastReadVersion??=[]}let qd=null;function Eo(n){return"function"==typeof n}function $d(n){const e=n(i=>{Error.call(i),i.stack=(new Error).stack});return e.prototype=Object.create(Error.prototype),e.prototype.constructor=e,e}const pf=$d(n=>function(e){n(this),this.message=e?`${e.length} errors occurred during unsubscription:\n${e.map((i,r)=>`${r+1}) ${i.toString()}`).join("\n ")}`:"",this.name="UnsubscriptionError",this.errors=e});function ff(n,t){if(n){const e=n.indexOf(t);0<=e&&n.splice(e,1)}}class As{constructor(t){this.initialTeardown=t,this.closed=!1,this._parentage=null,this._finalizers=null}unsubscribe(){let t;if(!this.closed){this.closed=!0;const{_parentage:e}=this;if(e)if(this._parentage=null,Array.isArray(e))for(const s of e)s.remove(this);else e.remove(this);const{initialTeardown:i}=this;if(Eo(i))try{i()}catch(s){t=s instanceof pf?s.errors:[s]}const{_finalizers:r}=this;if(r){this._finalizers=null;for(const s of r)try{Mm(s)}catch(o){t=t??[],o instanceof pf?t=[...t,...o.errors]:t.push(o)}}if(t)throw new pf(t)}}add(t){var e;if(t&&t!==this)if(this.closed)Mm(t);else{if(t instanceof As){if(t.closed||t._hasParent(this))return;t._addParent(this)}(this._finalizers=null!==(e=this._finalizers)&&void 0!==e?e:[]).push(t)}}_hasParent(t){const{_parentage:e}=this;return e===t||Array.isArray(e)&&e.includes(t)}_addParent(t){const{_parentage:e}=this;this._parentage=Array.isArray(e)?(e.push(t),e):e?[e,t]:t}_removeParent(t){const{_parentage:e}=this;e===t?this._parentage=null:Array.isArray(e)&&ff(e,t)}remove(t){const{_finalizers:e}=this;e&&ff(e,t),t instanceof As&&t._removeParent(this)}}As.EMPTY=(()=>{const n=new As;return n.closed=!0,n})();const Wl=As.EMPTY;function bm(n){return n instanceof As||n&&"closed"in n&&Eo(n.remove)&&Eo(n.add)&&Eo(n.unsubscribe)}function Mm(n){Eo(n)?n():n.unsubscribe()}const Yl={onUnhandledError:null,onStoppedNotification:null,Promise:void 0,useDeprecatedSynchronousErrorHandling:!1,useDeprecatedNextContext:!1},Z={setTimeout(n,t,...e){const{delegate:i}=Z;return i?.setTimeout?i.setTimeout(n,t,...e):setTimeout(n,t,...e)},clearTimeout(n){const{delegate:t}=Z;return(t?.clearTimeout||clearTimeout)(n)},delegate:void 0};function ye(){}const fe=at("C",void 0,void 0);function at(n,t,e){return{kind:n,value:t,error:e}}let tt=null;function At(n){if(Yl.useDeprecatedSynchronousErrorHandling){const t=!tt;if(t&&(tt={errorThrown:!1,error:null}),n(),t){const{errorThrown:e,error:i}=tt;if(tt=null,e)throw i}}else n()}class ft extends As{constructor(t){super(),this.isStopped=!1,t?(this.destination=t,bm(t)&&t.add(this)):this.destination=Wt}static create(t,e,i){return new cr(t,e,i)}next(t){this.isStopped?kr(function ke(n){return at("N",n,void 0)}(t),this):this._next(t)}error(t){this.isStopped?kr(function be(n){return at("E",void 0,n)}(t),this):(this.isStopped=!0,this._error(t))}complete(){this.isStopped?kr(fe,this):(this.isStopped=!0,this._complete())}unsubscribe(){this.closed||(this.isStopped=!0,super.unsubscribe(),this.destination=null)}_next(t){this.destination.next(t)}_error(t){try{this.destination.error(t)}finally{this.unsubscribe()}}_complete(){try{this.destination.complete()}finally{this.unsubscribe()}}}const Ei=Function.prototype.bind;function ii(n,t){return Ei.call(n,t)}class gi{constructor(t){this.partialObserver=t}next(t){const{partialObserver:e}=this;if(e.next)try{e.next(t)}catch(i){Oi(i)}}error(t){const{partialObserver:e}=this;if(e.error)try{e.error(t)}catch(i){Oi(i)}else Oi(t)}complete(){const{partialObserver:t}=this;if(t.complete)try{t.complete()}catch(e){Oi(e)}}}class cr extends ft{constructor(t,e,i){let r;if(super(),Eo(t)||!t)r={next:t??void 0,error:e??void 0,complete:i??void 0};else{let s;this&&Yl.useDeprecatedNextContext?(s=Object.create(t),s.unsubscribe=()=>this.unsubscribe(),r={next:t.next&&ii(t.next,s),error:t.error&&ii(t.error,s),complete:t.complete&&ii(t.complete,s)}):r=t}this.destination=new gi(r)}}function Oi(n){Yl.useDeprecatedSynchronousErrorHandling?function Lt(n){Yl.useDeprecatedSynchronousErrorHandling&&tt&&(tt.errorThrown=!0,tt.error=n)}(n):function se(n){Z.setTimeout(()=>{const{onUnhandledError:t}=Yl;if(!t)throw n;t(n)})}(n)}function kr(n,t){const{onStoppedNotification:e}=Yl;e&&Z.setTimeout(()=>e(n,t))}const Wt={closed:!0,next:ye,error:function es(n){throw n},complete:ye},ct="function"==typeof Symbol&&Symbol.observable||"@@observable";function _n(n){return n}let ki=(()=>{class n{constructor(e){e&&(this._subscribe=e)}lift(e){const i=new n;return i.source=this,i.operator=e,i}subscribe(e,i,r){const s=function et(n){return n&&n instanceof ft||function dr(n){return n&&Eo(n.next)&&Eo(n.error)&&Eo(n.complete)}(n)&&bm(n)}(e)?e:new cr(e,i,r);return At(()=>{const{operator:o,source:a}=this;s.add(o?o.call(s,a):a?this._subscribe(s):this._trySubscribe(s))}),s}_trySubscribe(e){try{return this._subscribe(e)}catch(i){e.error(i)}}forEach(e,i){return new(i=lt(i))((r,s)=>{const o=new cr({next:a=>{try{e(a)}catch(l){s(l),o.unsubscribe()}},error:s,complete:r});this.subscribe(o)})}_subscribe(e){var i;return null===(i=this.source)||void 0===i?void 0:i.subscribe(e)}[ct](){return this}pipe(...e){return function Zr(n){return 0===n.length?_n:1===n.length?n[0]:function(e){return n.reduce((i,r)=>r(i),e)}}(e)(this)}toPromise(e){return new(e=lt(e))((i,r)=>{let s;this.subscribe(o=>s=o,o=>r(o),()=>i(s))})}}return n.create=t=>new n(t),n})();function lt(n){var t;return null!==(t=n??Yl.Promise)&&void 0!==t?t:Promise}const vi=$d(n=>function(){n(this),this.name="ObjectUnsubscribedError",this.message="object unsubscribed"});let Pt=(()=>{class n extends ki{constructor(){super(),this.closed=!1,this.currentObservers=null,this.observers=[],this.isStopped=!1,this.hasError=!1,this.thrownError=null}lift(e){const i=new ts(this,this);return i.operator=e,i}_throwIfClosed(){if(this.closed)throw new vi}next(e){At(()=>{if(this._throwIfClosed(),!this.isStopped){this.currentObservers||(this.currentObservers=Array.from(this.observers));for(const i of this.currentObservers)i.next(e)}})}error(e){At(()=>{if(this._throwIfClosed(),!this.isStopped){this.hasError=this.isStopped=!0,this.thrownError=e;const{observers:i}=this;for(;i.length;)i.shift().error(e)}})}complete(){At(()=>{if(this._throwIfClosed(),!this.isStopped){this.isStopped=!0;const{observers:e}=this;for(;e.length;)e.shift().complete()}})}unsubscribe(){this.isStopped=this.closed=!0,this.observers=this.currentObservers=null}get observed(){var e;return(null===(e=this.observers)||void 0===e?void 0:e.length)>0}_trySubscribe(e){return this._throwIfClosed(),super._trySubscribe(e)}_subscribe(e){return this._throwIfClosed(),this._checkFinalizedStatuses(e),this._innerSubscribe(e)}_innerSubscribe(e){const{hasError:i,isStopped:r,observers:s}=this;return i||r?Wl:(this.currentObservers=null,s.push(e),new As(()=>{this.currentObservers=null,ff(s,e)}))}_checkFinalizedStatuses(e){const{hasError:i,thrownError:r,isStopped:s}=this;i?e.error(r):s&&e.complete()}asObservable(){const e=new ki;return e.source=this,e}}return n.create=(t,e)=>new ts(t,e),n})();class ts extends Pt{constructor(t,e){super(),this.destination=t,this.source=e}next(t){var e,i;null===(i=null===(e=this.destination)||void 0===e?void 0:e.next)||void 0===i||i.call(e,t)}error(t){var e,i;null===(i=null===(e=this.destination)||void 0===e?void 0:e.error)||void 0===i||i.call(e,t)}complete(){var t,e;null===(e=null===(t=this.destination)||void 0===t?void 0:t.complete)||void 0===e||e.call(t)}_subscribe(t){var e,i;return null!==(i=null===(e=this.source)||void 0===e?void 0:e.subscribe(t))&&void 0!==i?i:Wl}}class _o extends Pt{constructor(t){super(),this._value=t}get value(){return this.getValue()}_subscribe(t){const e=super._subscribe(t);return!e.closed&&t.next(this._value),e}getValue(){const{hasError:t,thrownError:e,_value:i}=this;if(t)throw e;return this._throwIfClosed(),i}next(t){super.next(this._value=t)}}class Ls extends ft{constructor(t,e,i,r,s,o){super(t),this.onFinalize=s,this.shouldUnsubscribe=o,this._next=e?function(a){try{e(a)}catch(l){t.error(l)}}:super._next,this._error=r?function(a){try{r(a)}catch(l){t.error(l)}finally{this.unsubscribe()}}:super._error,this._complete=i?function(){try{i()}catch(a){t.error(a)}finally{this.unsubscribe()}}:super._complete}unsubscribe(){var t;if(!this.shouldUnsubscribe||this.shouldUnsubscribe()){const{closed:e}=this;super.unsubscribe(),!e&&(null===(t=this.onFinalize)||void 0===t||t.call(this))}}}function jr(n,t){return function Ur(n){return t=>{if(function cn(n){return Eo(n?.lift)}(t))return t.lift(function(e){try{return n(e,this)}catch(i){this.error(i)}});throw new TypeError("Unable to lift unknown Observable type")}}((e,i)=>{let r=0;e.subscribe(function Do(n,t,e,i,r){return new Ls(n,t,e,i,r)}(i,s=>{i.next(n.call(t,s,r++))}))})}class F extends Error{constructor(t,e){super(function ae(n,t){return`NG0${Math.abs(n)}${t?": "+t:""}`}(t,e)),this.code=t}}function Xe(n){for(let t in n)if(n[t]===Xe)return t;throw Error("Could not find renamed property on target object.")}function mt(n,t){for(const e in t)t.hasOwnProperty(e)&&!n.hasOwnProperty(e)&&(n[e]=t[e])}function dt(n){if("string"==typeof n)return n;if(Array.isArray(n))return"["+n.map(dt).join(", ")+"]";if(null==n)return""+n;if(n.overriddenName)return`${n.overriddenName}`;if(n.name)return`${n.name}`;const t=n.toString();if(null==t)return""+t;const e=t.indexOf("\n");return-1===e?t:t.substring(0,e)}function $t(n,t){return null==n||""===n?null===t?"":t:null==t||""===t?n:n+" "+t}const ur=Xe({__forward_ref__:Xe});function ir(n){return n.__forward_ref__=ir,n.toString=function(){return dt(this())},n}function vt(n){return function Dn(n){return"function"==typeof n&&n.hasOwnProperty(ur)&&n.__forward_ref__===ir}(n)?n():n}function Ql(n){return n&&!!n.\u0275providers}const Gl=Xe({\u0275cmp:Xe}),Zd=Xe({\u0275dir:Xe}),gf=Xe({\u0275pipe:Xe}),Uo=Xe({\u0275fac:Xe}),jo=Xe({__NG_ELEMENT_ID__:Xe}),vf=Xe({__NG_ENV_ID__:Xe});function zi(n){return"function"==typeof n?n.name||n.toString():"object"==typeof n&&null!=n&&"function"==typeof n.type?n.type.name||n.type.toString():function Nt(n){return"string"==typeof n?n:null==n?"":String(n)}(n)}function Ab(n,t){throw new F(-201,!1)}function ro(n,t){null==n&&function zt(n,t,e,i){throw new Error(`ASSERTION ERROR: ${n}`+(null==i?"":` [Expected=> ${e} ${i} ${t} <=Actual]`))}(t,n,null,"!=")}function Yi(n){return{token:n.token,providedIn:n.providedIn||null,factory:n.factory,value:void 0}}function mf(n){return{providers:n.providers||[],imports:n.imports||[]}}function wm(n){return RT(n,Em)||RT(n,HT)}function RT(n,t){return n.hasOwnProperty(t)?n[t]:null}function Cm(n){return n&&(n.hasOwnProperty(Lb)||n.hasOwnProperty(x_))?n[Lb]:null}const Em=Xe({\u0275prov:Xe}),Lb=Xe({\u0275inj:Xe}),HT=Xe({ngInjectableDef:Xe}),x_=Xe({ngInjectorDef:Xe});var Di=function(n){return n[n.Default=0]="Default",n[n.Host=1]="Host",n[n.Self=2]="Self",n[n.SkipSelf=4]="SkipSelf",n[n.Optional=8]="Optional",n}(Di||{});let Nb;function no(n){const t=Nb;return Nb=n,t}function FT(n,t,e){const i=wm(n);return i&&"root"==i.providedIn?void 0===i.value?i.value=i.factory():i.value:e&Di.Optional?null:void 0!==t?t:void Ab()}const rr=globalThis;class Ht{constructor(t,e){this._desc=t,this.ngMetadataName="InjectionToken",this.\u0275prov=void 0,"number"==typeof e?this.__NG_ELEMENT_ID__=e:void 0!==e&&(this.\u0275prov=Yi({token:this,providedIn:e.providedIn||"root",factory:e.factory}))}get multi(){return this}toString(){return`InjectionToken ${this._desc}`}}const yf={},Rb="__NG_DI_FLAG__",Dm="ngTempTokenPath",L_=/\n/gm,UT="__source";let Kd;function Qh(n){const t=Kd;return Kd=n,t}function k_(n,t=Di.Default){if(void 0===Kd)throw new F(-203,!1);return null===Kd?FT(n,void 0,t):Kd.get(n,t&Di.Optional?null:void 0,t)}function Fi(n,t=Di.Default){return(function BT(){return Nb}()||k_)(vt(n),t)}function Ri(n,t=Di.Default){return Fi(n,xm(t))}function xm(n){return typeof n>"u"||"number"==typeof n?n:0|(n.optional&&8)|(n.host&&1)|(n.self&&2)|(n.skipSelf&&4)}function Hb(n){const t=[];for(let e=0;et){o=s-1;break}}}for(;ss?"":r[d+1].toLowerCase();const p=8&i?u:null;if(p&&-1!==VT(p,h,0)||2&i&&h!==u){if(ba(i))return!1;o=!0}}}}else{if(!o&&!ba(i)&&!ba(l))return!1;if(o&&ba(l))continue;o=!1,i=l|1&i}}return ba(i)||o}function ba(n){return 0==(1&n)}function __(n,t,e,i){if(null===t)return-1;let r=0;if(i||!e){let s=!1;for(;r-1)for(e++;e0?'="'+a+'"':"")+"]"}else 8&i?r+="."+o:4&i&&(r+=" "+o);else""!==r&&!ba(o)&&(t+=$T(s,r),r=""),i=o,s=s||!ba(i);e++}return""!==r&&(t+=$T(s,r)),t}function Fb(n){return Xl(()=>{const t=JT(n),e={...t,decls:n.decls,vars:n.vars,template:n.template,consts:n.consts||null,ngContentSelectors:n.ngContentSelectors,onPush:n.changeDetection===Tm.OnPush,directiveDefs:null,pipeDefs:null,dependencies:t.standalone&&n.dependencies||null,getStandaloneInjector:null,signals:n.signals??!1,data:n.data||{},encapsulation:n.encapsulation||Ia.Emulated,styles:n.styles||Qi,_:null,schemas:n.schemas||null,tView:null,id:""};KT(e);const i=n.dependencies;return e.directiveDefs=Lm(i,!1),e.pipeDefs=Lm(i,!0),e.id=function Z_(n){let t=0;const e=[n.selectors,n.ngContentSelectors,n.hostVars,n.hostAttrs,n.consts,n.vars,n.decls,n.encapsulation,n.standalone,n.signals,n.exportAs,JSON.stringify(n.inputs),JSON.stringify(n.outputs),Object.getOwnPropertyNames(n.type.prototype),!!n.contentQueries,!!n.viewQuery].join("|");for(const r of e)t=Math.imul(31,t)+r.charCodeAt(0)<<0;return t+=2147483648,"c"+t}(e),e})}function X_(n){return ci(n)||jn(n)}function q_(n){return null!==n}function Am(n){return Xl(()=>({type:n.type,bootstrap:n.bootstrap||Qi,declarations:n.declarations||Qi,imports:n.imports||Qi,exports:n.exports||Qi,transitiveCompileScopes:null,schemas:n.schemas||null,id:n.id||null}))}function ZT(n,t){if(null==n)return tl;const e={};for(const i in n)if(n.hasOwnProperty(i)){const r=n[i];let s,o,a=Gh.None;Array.isArray(r)?(a=r[0],s=r[1],o=r[2]??s):(s=r,o=r),t?(e[s]=a!==Gh.None?[i,a]:i,t[s]=o):e[s]=i}return e}function nr(n){return Xl(()=>{const t=JT(n);return KT(t),t})}function ci(n){return n[Gl]||null}function jn(n){return n[Zd]||null}function gs(n){return n[gf]||null}function JT(n){const t={};return{type:n.type,providersResolver:null,factory:null,hostBindings:n.hostBindings||null,hostVars:n.hostVars||0,hostAttrs:n.hostAttrs||null,contentQueries:n.contentQueries||null,declaredInputs:t,inputTransforms:null,inputConfig:n.inputs||tl,exportAs:n.exportAs||null,standalone:!0===n.standalone,signals:!0===n.signals,selectors:n.selectors||Qi,viewQuery:n.viewQuery||null,features:n.features||null,setInput:null,findHostDirectiveDefs:null,hostDirectives:null,inputs:ZT(n.inputs,t),outputs:ZT(n.outputs),debugInfo:null}}function KT(n){n.features?.forEach(t=>t(n))}function Lm(n,t){if(!n)return null;const e=t?gs:X_;return()=>("function"==typeof n?n():n).map(i=>e(i)).filter(q_)}const Vr=0,Be=1,Ct=2,vn=3,Ma=4,Os=5,wa=6,eu=7,Er=8,Xs=9,ql=10,Yt=11,bf=12,eA=13,tu=14,Jr=15,Mf=16,iu=17,il=18,wf=19,tA=20,Xh=21,Nm=22,Uc=23,Ut=25,_b=1,rl=7,ru=9,mn=10;var Ub=function(n){return n[n.None=0]="None",n[n.HasTransplantedViews=2]="HasTransplantedViews",n}(Ub||{});function ks(n){return Array.isArray(n)&&"object"==typeof n[_b]}function Ps(n){return Array.isArray(n)&&!0===n[_b]}function jb(n){return 0!=(4&n.flags)}function jc(n){return n.componentOffset>-1}function km(n){return 1==(1&n.flags)}function Ca(n){return!!n.template}function Vb(n){return 0!=(512&n[Ct])}function Vc(n,t){return n.hasOwnProperty(Uo)?n[Uo]:null}class tU{constructor(t,e,i){this.previousValue=t,this.currentValue=e,this.firstChange=i}isFirstChange(){return this.firstChange}}function sA(n,t,e,i){null!==t?t.applyValueToInputSignal(t,i):n[e]=i}function oA(n){return n.type.prototype.ngOnChanges&&(n.setInput=rU),iU}function iU(){const n=lA(this),t=n?.current;if(t){const e=n.previous;if(e===tl)n.previous=t;else for(let i in t)e[i]=t[i];n.current=null,this.ngOnChanges(t)}}function rU(n,t,e,i,r){const s=this.declaredInputs[i],o=lA(n)||function nU(n,t){return n[aA]=t}(n,{previous:tl,current:null}),a=o.current||(o.current={}),l=o.previous,h=l[s];a[s]=new tU(h&&h.currentValue,e,l===tl),sA(n,t,r,e)}const aA="__ngSimpleChanges__";function lA(n){return n[aA]||null}const nl=function(n,t,e){};let dA=!1;function pr(n){for(;Array.isArray(n);)n=n[Vr];return n}function qs(n,t){return pr(t[n.index])}function Df(n,t){return n.data[t]}function To(n,t){const e=t[n];return ks(e)?e:e[Vr]}function Xb(n){return 128==(128&n[Ct])}function sl(n,t){return null==t?null:n[t]}function uA(n){n[iu]=0}function cU(n){1024&n[Ct]||(n[Ct]|=1024,Xb(n)&&xf(n))}function fA(n){return 9216&n[Ct]||n[Uc]?.dirty}function qb(n){fA(n)?xf(n):64&n[Ct]&&(function oU(){return dA}()?(n[Ct]|=1024,xf(n)):n[ql].changeDetectionScheduler?.notify())}function xf(n){n[ql].changeDetectionScheduler?.notify();let t=Wc(n);for(;null!==t&&!(8192&t[Ct])&&(t[Ct]|=8192,Xb(t));)t=Wc(t)}function Wc(n){const t=n[vn];return Ps(t)?t[vn]:t}const Rt={lFrame:CA(null),bindingsEnabled:!0,skipHydrationRootTNode:null};function vA(){return Rt.bindingsEnabled}function Se(){return Rt.lFrame.lView}function xi(){return Rt.lFrame.tView}function fr(){let n=mA();for(;null!==n&&64===n.type;)n=n.parent;return n}function mA(){return Rt.lFrame.currentTNode}function ol(n,t){const e=Rt.lFrame;e.currentTNode=n,e.isParent=t}function Zb(){return Rt.lFrame.isParent}function wU(n,t){const e=Rt.lFrame;e.bindingIndex=e.bindingRootIndex=n,Kb(t)}function Kb(n){Rt.lFrame.currentDirectiveIndex=n}function bA(){return Rt.lFrame.currentQueryIndex}function t1(n){Rt.lFrame.currentQueryIndex=n}function EU(n){const t=n[Be];return 2===t.type?t.declTNode:1===t.type?n[Os]:null}function MA(n,t,e){if(e&Di.SkipSelf){let r=t,s=n;for(;!(r=r.parent,null!==r||e&Di.Host||(r=EU(s),null===r||(s=s[tu],10&r.type))););if(null===r)return!1;t=r,n=s}const i=Rt.lFrame=wA();return i.currentTNode=t,i.lView=n,!0}function i1(n){const t=wA(),e=n[Be];Rt.lFrame=t,t.currentTNode=e.firstChild,t.lView=n,t.tView=e,t.contextLView=n,t.bindingIndex=e.bindingStartIndex,t.inI18n=!1}function wA(){const n=Rt.lFrame,t=null===n?null:n.child;return null===t?CA(n):t}function CA(n){const t={currentTNode:null,isParent:!0,lView:null,tView:null,selectedIndex:-1,contextLView:null,elementDepthCount:0,currentNamespace:null,currentDirectiveIndex:-1,bindingRootIndex:-1,bindingIndex:-1,currentQueryIndex:0,parent:n,child:null,inI18n:!1};return null!==n&&(n.child=t),t}function EA(){const n=Rt.lFrame;return Rt.lFrame=n.parent,n.currentTNode=null,n.lView=null,n}const DA=EA;function r1(){const n=EA();n.isParent=!0,n.tView=null,n.selectedIndex=-1,n.contextLView=null,n.elementDepthCount=0,n.currentDirectiveIndex=-1,n.currentNamespace=null,n.bindingRootIndex=-1,n.bindingIndex=-1,n.currentQueryIndex=0}function zs(){return Rt.lFrame.selectedIndex}function Yc(n){Rt.lFrame.selectedIndex=n}let TA=!0;function Rm(){return TA}function qh(n){TA=n}function Hm(n,t){for(let e=t.directiveStart,i=t.directiveEnd;e=i)break}else t[l]<0&&(n[iu]+=65536),(a>14>16&&(3&n[Ct])===t&&(n[Ct]+=16384,LA(a,s)):LA(a,s)}const ou=-1;class Af{constructor(t,e,i){this.factory=t,this.resolving=!1,this.canSeeViewProviders=e,this.injectImpl=i}}function o1(n){return n!==ou}function Lf(n){return 32767&n}function Nf(n,t){let e=function HU(n){return n>>16}(n),i=t;for(;e>0;)i=i[tu],e--;return i}let a1=!0;function _m(n){const t=a1;return a1=n,t}const NA=255,OA=5;let BU=0;const ll={};function Um(n,t){const e=kA(n,t);if(-1!==e)return e;const i=t[Be];i.firstCreatePass&&(n.injectorIndex=t.length,l1(i.data,n),l1(t,null),l1(i.blueprint,null));const r=jm(n,t),s=n.injectorIndex;if(o1(r)){const o=Lf(r),a=Nf(r,t),l=a[Be].data;for(let h=0;h<8;h++)t[s+h]=a[o+h]|l[o+h]}return t[s+8]=r,s}function l1(n,t){n.push(0,0,0,0,0,0,0,0,t)}function kA(n,t){return-1===n.injectorIndex||n.parent&&n.parent.injectorIndex===n.injectorIndex||null===t[n.injectorIndex+8]?-1:n.injectorIndex}function jm(n,t){if(n.parent&&-1!==n.parent.injectorIndex)return n.parent.injectorIndex;let e=0,i=null,r=t;for(;null!==r;){if(i=_A(r),null===i)return ou;if(e++,r=r[tu],-1!==i.injectorIndex)return i.injectorIndex|e<<16}return ou}function h1(n,t,e){!function FU(n,t,e){let i;"string"==typeof e?i=e.charCodeAt(0)||0:e.hasOwnProperty(jo)&&(i=e[jo]),null==i&&(i=e[jo]=BU++);const r=i&NA;t.data[n+(r>>OA)]|=1<=0?t&NA:VU:t}(e);if("function"==typeof s){if(!MA(t,n,i))return i&Di.Host?PA(r,0,i):zA(t,e,i,r);try{let o;if(o=s(i),null!=o||i&Di.Optional)return o;Ab()}finally{DA()}}else if("number"==typeof s){let o=null,a=kA(n,t),l=ou,h=i&Di.Host?t[Jr][Os]:null;for((-1===a||i&Di.SkipSelf)&&(l=-1===a?jm(n,t):t[a+8],l!==ou&&FA(i,!1)?(o=t[Be],a=Lf(l),t=Nf(l,t)):a=-1);-1!==a;){const c=t[Be];if(BA(s,a,c.data)){const d=UU(a,t,e,o,i,h);if(d!==ll)return d}l=t[a+8],l!==ou&&FA(i,t[Be].data[a+8]===h)&&BA(s,a,t)?(o=c,a=Lf(l),t=Nf(l,t)):a=-1}}return r}function UU(n,t,e,i,r,s){const o=t[Be],a=o.data[n+8],c=Vm(a,o,e,null==i?jc(a)&&a1:i!=o&&0!=(3&a.type),r&Di.Host&&s===a);return null!==c?Qc(t,o,c,a):ll}function Vm(n,t,e,i,r){const s=n.providerIndexes,o=t.data,a=1048575&s,l=n.directiveStart,c=s>>20,u=r?a+c:n.directiveEnd;for(let p=i?a:a+c;p=l&&f.type===e)return p}if(r){const p=o[l];if(p&&Ca(p)&&p.type===e)return l}return null}function Qc(n,t,e,i){let r=n[e];const s=t.data;if(function kU(n){return n instanceof Af}(r)){const o=r;o.resolving&&function Vo(n,t){const e=t?`. Dependency path: ${t.join(" > ")} > ${n}`:"";throw new F(-200,`Circular dependency in DI detected for ${n}${e}`)}(zi(s[e]));const a=_m(o.canSeeViewProviders);o.resolving=!0;const h=o.injectImpl?no(o.injectImpl):null;MA(n,i,Di.Default);try{r=n[e]=o.factory(void 0,s,n,i),t.firstCreatePass&&e>=i.directiveStart&&function NU(n,t,e){const{ngOnChanges:i,ngOnInit:r,ngDoCheck:s}=t.type.prototype;if(i){const o=oA(t);(e.preOrderHooks??=[]).push(n,o),(e.preOrderCheckHooks??=[]).push(n,o)}r&&(e.preOrderHooks??=[]).push(0-n,r),s&&((e.preOrderHooks??=[]).push(n,s),(e.preOrderCheckHooks??=[]).push(n,s))}(e,s[e],t)}finally{null!==h&&no(h),_m(a),o.resolving=!1,DA()}}return r}function BA(n,t,e){return!!(e[t+(n>>OA)]&1<Array.isArray(e)?fu(e,t):t(e))}function jA(n,t,e){t>=n.length?n.push(e):n.splice(t,0,e)}function Wm(n,t){return t>=n.length-1?n.pop():n.splice(t,1)[0]}const mu=new Ht(""),XA=new Ht("",-1),S1=new Ht("");class Xm{get(t,e=yf){if(e===yf){const i=new Error(`NullInjectorError: No provider for ${dt(t)}!`);throw i.name="NullInjectorError",i}return e}}function pj(...n){return{\u0275providers:qA(0,n),\u0275fromNgModule:!0}}function qA(n,...t){const e=[],i=new Set;let r;const s=o=>{e.push(o)};return fu(t,o=>{const a=o;qm(a,s,[],i)&&(r||=[],r.push(a))}),void 0!==r&&$A(r,s),e}function $A(n,t){for(let e=0;e{t(s,i)})}}function qm(n,t,e,i){if(!(n=vt(n)))return!1;let r=null,s=Cm(n);const o=!s&&ci(n);if(s||o){if(o&&!o.standalone)return!1;r=n}else{const l=n.ngModule;if(s=Cm(l),!s)return!1;r=l}const a=i.has(r);if(o){if(a)return!1;if(i.add(r),o.dependencies){const l="function"==typeof o.dependencies?o.dependencies():o.dependencies;for(const h of l)qm(h,t,e,i)}}else{if(!s)return!1;{if(null!=s.imports&&!a){let h;i.add(r);try{fu(s.imports,c=>{qm(c,t,e,i)&&(h||=[],h.push(c))})}finally{}void 0!==h&&$A(h,t)}if(!a){const h=Vc(r)||(()=>new r);t({provide:r,useFactory:h,deps:Qi},r),t({provide:S1,useValue:r,multi:!0},r),t({provide:mu,useValue:()=>Fi(r),multi:!0},r)}const l=s.providers;if(null!=l&&!a){const h=n;b1(l,c=>{t(c,h)})}}}return r!==n&&void 0!==n.providers}function b1(n,t){for(let e of n)Ql(e)&&(e=e.\u0275providers),Array.isArray(e)?b1(e,t):t(e)}const fj=Xe({provide:String,useValue:Xe});function M1(n){return null!==n&&"object"==typeof n&&fj in n}function Gc(n){return"function"==typeof n}const w1=new Ht(""),$m={},vj={};let C1;function Zm(){return void 0===C1&&(C1=new Xm),C1}class Jl{}class yu extends Jl{get destroyed(){return this._destroyed}constructor(t,e,i,r){super(),this.parent=e,this.source=i,this.scopes=r,this.records=new Map,this._ngOnDestroyHooks=new Set,this._onDestroyHooks=[],this._destroyed=!1,D1(t,o=>this.processProvider(o)),this.records.set(XA,Su(void 0,this)),r.has("environment")&&this.records.set(Jl,Su(void 0,this));const s=this.records.get(w1);null!=s&&"string"==typeof s.value&&this.scopes.add(s.value),this.injectorDefTypes=new Set(this.get(S1,Qi,Di.Self))}destroy(){this.assertNotDestroyed(),this._destroyed=!0;try{for(const e of this._ngOnDestroyHooks)e.ngOnDestroy();const t=this._onDestroyHooks;this._onDestroyHooks=[];for(const e of t)e()}finally{this.records.clear(),this._ngOnDestroyHooks.clear(),this.injectorDefTypes.clear()}}onDestroy(t){return this.assertNotDestroyed(),this._onDestroyHooks.push(t),()=>this.removeOnDestroy(t)}runInContext(t){this.assertNotDestroyed();const e=Qh(this),i=no(void 0);try{return t()}finally{Qh(e),no(i)}}get(t,e=yf,i=Di.Default){if(this.assertNotDestroyed(),t.hasOwnProperty(vf))return t[vf](this);i=xm(i);const s=Qh(this),o=no(void 0);try{if(!(i&Di.SkipSelf)){let l=this.records.get(t);if(void 0===l){const h=function bj(n){return"function"==typeof n||"object"==typeof n&&n instanceof Ht}(t)&&wm(t);l=h&&this.injectableDefInScope(h)?Su(E1(t),$m):null,this.records.set(t,l)}if(null!=l)return this.hydrate(t,l)}return(i&Di.Self?Zm():this.parent).get(t,e=i&Di.Optional&&e===yf?null:e)}catch(a){if("NullInjectorError"===a.name){if((a[Dm]=a[Dm]||[]).unshift(dt(t)),s)throw a;return function z_(n,t,e,i){const r=n[Dm];throw t[UT]&&r.unshift(t[UT]),n.message=function R_(n,t,e,i=null){n=n&&"\n"===n.charAt(0)&&"\u0275"==n.charAt(1)?n.slice(2):n;let r=dt(t);if(Array.isArray(t))r=t.map(dt).join(" -> ");else if("object"==typeof t){let s=[];for(let o in t)if(t.hasOwnProperty(o)){let a=t[o];s.push(o+":"+("string"==typeof a?JSON.stringify(a):dt(a)))}r=`{${s.join(", ")}}`}return`${e}${i?"("+i+")":""}[${r}]: ${n.replace(L_,"\n ")}`}("\n"+n.message,r,e,i),n.ngTokenPath=r,n[Dm]=null,n}(a,t,"R3InjectorError",this.source)}throw a}finally{no(o),Qh(s)}}resolveInjectorInitializers(){const t=Qh(this),e=no(void 0);try{const r=this.get(mu,Qi,Di.Self);for(const s of r)s()}finally{Qh(t),no(e)}}toString(){const t=[],e=this.records;for(const i of e.keys())t.push(dt(i));return`R3Injector[${t.join(", ")}]`}assertNotDestroyed(){if(this._destroyed)throw new F(205,!1)}processProvider(t){let e=Gc(t=vt(t))?t:vt(t&&t.provide);const i=function yj(n){return M1(n)?Su(void 0,n.useValue):Su(KA(n),$m)}(t);if(!Gc(t)&&!0===t.multi){let r=this.records.get(e);r||(r=Su(void 0,$m,!0),r.factory=()=>Hb(r.multi),this.records.set(e,r)),e=t,r.multi.push(t)}this.records.set(e,i)}hydrate(t,e){return e.value===$m&&(e.value=vj,e.value=e.factory()),"object"==typeof e.value&&e.value&&function Ij(n){return null!==n&&"object"==typeof n&&"function"==typeof n.ngOnDestroy}(e.value)&&this._ngOnDestroyHooks.add(e.value),e.value}injectableDefInScope(t){if(!t.providedIn)return!1;const e=vt(t.providedIn);return"string"==typeof e?"any"===e||this.scopes.has(e):this.injectorDefTypes.has(e)}removeOnDestroy(t){const e=this._onDestroyHooks.indexOf(t);-1!==e&&this._onDestroyHooks.splice(e,1)}}function E1(n){const t=wm(n),e=null!==t?t.factory:Vc(n);if(null!==e)return e;if(n instanceof Ht)throw new F(204,!1);if(n instanceof Function)return function mj(n){if(n.length>0)throw new F(204,!1);const e=function D_(n){return n&&(n[Em]||n[HT])||null}(n);return null!==e?()=>e.factory(n):()=>new n}(n);throw new F(204,!1)}function KA(n,t,e){let i;if(Gc(n)){const r=vt(n);return Vc(r)||E1(r)}if(M1(n))i=()=>vt(n.useValue);else if(function JA(n){return!(!n||!n.useFactory)}(n))i=()=>n.useFactory(...Hb(n.deps||[]));else if(function ZA(n){return!(!n||!n.useExisting)}(n))i=()=>Fi(vt(n.useExisting));else{const r=vt(n&&(n.useClass||n.provide));if(!function Sj(n){return!!n.deps}(n))return Vc(r)||E1(r);i=()=>new r(...Hb(n.deps))}return i}function Su(n,t,e=!1){return{factory:n,value:t,multi:e?[]:void 0}}function D1(n,t){for(const e of n)Array.isArray(e)?D1(e,t):e&&Ql(e)?D1(e.\u0275providers,t):t(e)}function rL(n,t=null,e=null,i){const r=function nL(n,t=null,e=null,i,r=new Set){const s=[e||Qi,pj(n)];return i=i||("object"==typeof n?void 0:dt(n)),new yu(s,t||Zm(),i||null,r)}(n,t,e,i);return r.resolveInjectorInitializers(),r}let A1,Wo=(()=>{class n{static{this.THROW_IF_NOT_FOUND=yf}static{this.NULL=new Xm}static create(e,i){if(Array.isArray(e))return rL({name:""},i,e,"");{const r=e.name??"";return rL({name:r},e.parent,e.providers,r)}}static{this.\u0275prov=Yi({token:n,providedIn:"any",factory:()=>Fi(XA)})}static{this.__NG_ELEMENT_ID__=-1}}return n})();const L1=new Ht("",{providedIn:"root",factory:()=>Lj}),Lj="ng",oL=new Ht(""),Iu=new Ht("",{providedIn:"platform",factory:()=>"unknown"}),aL=new Ht("",{providedIn:"root",factory:()=>function $h(){if(void 0!==A1)return A1;if(typeof document<"u")return document;throw new F(210,!1)}().body?.querySelector("[ngCspNonce]")?.getAttribute("ngCspNonce")||null});function iy(n){return 128==(128&n.flags)}var Kh=function(n){return n[n.Important=1]="Important",n[n.DashCase=2]="DashCase",n}(Kh||{});const z1=new Map;let Vj=0;const H1="__ngContext__";function Rs(n,t){ks(t)?(n[H1]=t[wf],function Yj(n){z1.set(n[wf],n)}(t)):n[H1]=t}let B1;function F1(n,t){return B1(n,t)}function Mu(n,t,e,i,r){if(null!=i){let s,o=!1;Ps(i)?s=i:ks(i)&&(o=!0,i=i[Vr]);const a=pr(i);0===n&&null!==e?null==r?AL(t,e,a):qc(t,e,a,r||null,!0):1===n&&null!==e?qc(t,e,a,r||null,!0):2===n?function hy(n,t,e){const i=ay(n,t);i&&function a6(n,t,e,i){n.removeChild(t,e,i)}(n,i,t,e)}(t,a,o):3===n&&t.destroyNode(a),null!=s&&function c6(n,t,e,i,r){const s=e[rl];s!==pr(e)&&Mu(t,n,i,s,r);for(let a=mn;a0&&(n[e-1][Ma]=i[Ma]);const s=Wm(n,mn+t);!function e6(n,t){DL(n,t),t[Vr]=null,t[Os]=null}(i[Be],i);const o=s[il];null!==o&&o.detachView(s[Be]),i[vn]=null,i[Ma]=null,i[Ct]&=-129}return i}function oy(n,t){if(!(256&t[Ct])){const e=t[Yt];e.destroyNode&&cy(n,t,e,3,null,null),function i6(n){let t=n[bf];if(!t)return U1(n[Be],n);for(;t;){let e=null;if(ks(t))e=t[bf];else{const i=t[mn];i&&(e=i)}if(!e){for(;t&&!t[Ma]&&t!==n;)ks(t)&&U1(t[Be],t),t=t[vn];null===t&&(t=n),ks(t)&&U1(t[Be],t),e=t&&t[Ma]}t=e}}(t)}}function U1(n,t){if(!(256&t[Ct])){t[Ct]&=-129,t[Ct]|=256,t[Uc]&&function Gd(n){if(Vl(n),Vh(n))for(let t=0;t=0?i[o]():i[-o].unsubscribe(),s+=2}else e[s].call(i[e[s+1]]);null!==i&&(t[eu]=null);const r=t[Xh];if(null!==r){t[Xh]=null;for(let s=0;s-1){const{encapsulation:s}=n.data[i.directiveStart+r];if(s===Ia.None||s===Ia.Emulated)return null}return qs(i,e)}}(n,t.parent,e)}function qc(n,t,e,i,r){n.insertBefore(t,e,i,r)}function AL(n,t,e){n.appendChild(t,e)}function LL(n,t,e,i,r){null!==i?qc(n,t,e,i,r):AL(n,t,e)}function ay(n,t){return n.parentNode(t)}let V1,kL=function OL(n,t,e){return 40&n.type?qs(n,e):null};function ly(n,t,e,i){const r=j1(n,i,t),s=t[Yt],a=function NL(n,t,e){return kL(n,t,e)}(i.parent||t[Os],i,t);if(null!=r)if(Array.isArray(e))for(let l=0;lnull;function sM(n,t,e=!1){return KL(n,t,e)}class G6{}class nN{}class q6{resolveComponentFactory(t){throw function X6(n){const t=Error(`No component factory found for ${dt(n)}.`);return t.ngComponent=n,t}(t)}}let Sy=(()=>{class n{static{this.NULL=new q6}}return n})();function $6(){return Tu(fr(),Se())}function Tu(n,t){return new $c(qs(n,t))}let $c=(()=>{class n{constructor(e){this.nativeElement=e}static{this.__NG_ELEMENT_ID__=$6}}return n})();function Z6(n){return n instanceof $c?n.nativeElement:n}class oN{}let hM=(()=>{class n{constructor(){this.destroyNode=null}static{this.__NG_ELEMENT_ID__=()=>function J6(){const n=Se(),e=To(fr().index,n);return(ks(e)?e:n)[Yt]}()}}return n})(),K6=(()=>{class n{static{this.\u0275prov=Yi({token:n,providedIn:"root",factory:()=>null})}}return n})();const cM={};function Qf(n,t,e,i,r=!1){for(;null!==e;){const s=t[e.index];null!==s&&i.push(pr(s)),Ps(s)&&fN(s,i);const o=e.type;if(8&o)Qf(n,t,e.child,i);else if(32&o){const a=F1(e,t);let l;for(;l=a();)i.push(l)}else if(16&o){const a=zL(t,e);if(Array.isArray(a))i.push(...a);else{const l=Wc(t[Jr]);Qf(l[Be],l,a,i,!0)}}e=r?e.projectionNext:e.next}return i}function fN(n,t){for(let e=mn;e!1,producerRecomputeValue:()=>{},consumerMarkedDirty:()=>{},consumerOnSignalRead:()=>{},consumerIsAlwaysLive:!0,consumerMarkedDirty:n=>{xf(n.lView)},consumerOnSignalRead(){this.lView[Uc]=this}};function vN(n){return yN(n[bf])}function mN(n){return yN(n[Ma])}function yN(n){for(;null!==n&&!Ps(n);)n=n[Ma];return n}function pM(n){return n.ngOriginalError}class eh{constructor(){this._console=console}handleError(t){const e=this._findOriginalError(t);this._console.error("ERROR",t),e&&this._console.error("ORIGINAL ERROR",e)}_findOriginalError(t){let e=t&&pM(t);for(;e&&pM(e);)e=pM(e);return e||null}}const IN=new Ht("",{providedIn:"root",factory:()=>Ri(eh).handleError.bind(void 0)}),MN=new Ht("",{providedIn:"root",factory:()=>!1}),Qt={};function fM(n=1){DN(xi(),Se(),zs()+n,!1)}function DN(n,t,e,i){if(!i)if(3==(3&t[Ct])){const s=n.preOrderCheckHooks;null!==s&&Bm(t,s,e)}else{const s=n.preOrderHooks;null!==s&&Fm(t,s,0,e)}Yc(e)}function Ot(n,t=Di.Default){const e=Se();return null===e?Fi(n,t):RA(fr(),e,vt(n),t)}function xN(n,t,e,i,r,s){const o=Wi(null);try{let a=null;r&Gh.SignalBased&&(a=t[i][Ts]),null!==a&&void 0!==a.transformFn&&(s=a.transformFn(s)),r&Gh.HasDecoratorInputTransform&&(s=n.inputTransforms[i].call(t,s)),null!==n.setInput?n.setInput(t,a,s,e,i):sA(t,a,i,s)}finally{Wi(o)}}function wy(n,t,e,i,r,s,o,a,l,h,c){const d=t.blueprint.slice();return d[Vr]=r,d[Ct]=204|i,(null!==h||n&&2048&n[Ct])&&(d[Ct]|=2048),uA(d),d[vn]=d[tu]=n,d[Er]=e,d[ql]=o||n&&n[ql],d[Yt]=a||n&&n[Yt],d[Xs]=l||n&&n[Xs]||null,d[Os]=s,d[wf]=function Wj(){return Vj++}(),d[wa]=c,d[tA]=h,d[Jr]=2==t.type?n[Jr]:d,d}function Au(n,t,e,i,r){let s=n.data[t];if(null===s)s=function gM(n,t,e,i,r){const s=mA(),o=Zb(),l=n.data[t]=function LV(n,t,e,i,r,s){let o=t?t.injectorIndex:-1,a=0;return function su(){return null!==Rt.skipHydrationRootTNode}()&&(a|=128),{type:e,index:i,insertBeforeIndex:null,injectorIndex:o,directiveStart:-1,directiveEnd:-1,directiveStylingLast:-1,componentOffset:-1,propertyBindings:null,flags:a,providerIndexes:0,value:r,attrs:s,mergedAttrs:null,localNames:null,initialInputs:void 0,inputs:null,outputs:null,tView:null,next:null,prev:null,projectionNext:null,child:null,parent:t,projection:null,styles:null,stylesWithoutHost:null,residualStyles:void 0,classes:null,classesWithoutHost:null,residualClasses:void 0,classBindings:0,styleBindings:0}}(0,o?s:s&&s.parent,e,t,i,r);return null===n.firstChild&&(n.firstChild=l),null!==s&&(o?null==s.child&&null!==l.parent&&(s.child=l):null===s.next&&(s.next=l,l.prev=s)),l}(n,t,e,i,r),function MU(){return Rt.lFrame.inI18n}()&&(s.flags|=32);else if(64&s.type){s.type=e,s.value=i,s.attrs=r;const o=function Tf(){const n=Rt.lFrame,t=n.currentTNode;return n.isParent?t:t.parent}();s.injectorIndex=null===o?-1:o.injectorIndex}return ol(s,!0),s}function Gf(n,t,e,i){if(0===e)return-1;const r=t.length;for(let s=0;sUt&&DN(n,t,Ut,!1),nl(o?2:0,r),e(i,r)}finally{Yc(s),nl(o?3:1,r)}}function vM(n,t,e){if(jb(t)){const i=Wi(null);try{const s=t.directiveEnd;for(let o=t.directiveStart;onull;function NN(n,t,e,i,r){for(let s in t){if(!t.hasOwnProperty(s))continue;const o=t[s];if(void 0===o)continue;i??={};let a,l=Gh.None;Array.isArray(o)?(a=o[0],l=o[1]):a=o;let h=s;if(null!==r){if(!r.hasOwnProperty(s))continue;h=r[s]}0===n?ON(i,e,h,a,l):ON(i,e,h,a)}return i}function ON(n,t,e,i,r){let s;n.hasOwnProperty(e)?(s=n[e]).push(t,i):s=n[e]=[t,i],void 0!==r&&s.push(r)}function kN(n,t,e,i,r,s){for(let h=0;h0;){const e=n[--t];if("number"==typeof e&&e<0)return e}return 0})(o)!=a&&o.push(a),o.push(e,i,s)}}(n,t,i,Gf(n,e,r.hostVars,Qt),r)}function YV(n,t,e,i,r,s){const o=s[t];if(null!==o)for(let a=0;an.nextProducerIndex;)n.producerNode.pop(),n.producerLastReadVersion.pop(),n.producerIndexOfThis.pop()}}(a,o),function pV(n){n.lView[Uc]!==n&&(n.lView=null,gN.push(n))}(a)),r1()}}function _N(n,t){for(let e=vN(n);null!==e;e=mN(e))for(let i=mn;i-1&&(Bf(t,i),Wm(e,i))}this._attachedToViewContainer=!1}oy(this._lView[Be],this._lView)}onDestroy(t){!function zm(n,t){if(256==(256&n[Ct]))throw new F(911,!1);null===n[Xh]&&(n[Xh]=[]),n[Xh].push(t)}(this._lView,t)}markForCheck(){Xf(this._cdRefInjectingView||this._lView)}detach(){this._lView[Ct]&=-129}reattach(){qb(this._lView),this._lView[Ct]|=128}detectChanges(){this._lView[Ct]|=1024,function EM(n,t=!0){const e=n[ql],i=e.rendererFactory;i.begin?.();try{!function XV(n){DM(n,0);let t=0;for(;fA(n);){if(100===t)throw new F(103,!1);t++,DM(n,1)}}(n)}catch(s){throw t&&Ey(n,s),s}finally{i.end?.(),e.inlineEffectRunner?.flush()}}(this._lView,this.notifyErrorHandler)}checkNoChanges(){}attachToViewContainerRef(){if(this._appRef)throw new F(902,!1);this._attachedToViewContainer=!0}detachFromAppRef(){this._appRef=null,DL(this._lView[Be],this._lView)}attachToAppRef(t){if(this._attachedToViewContainer)throw new F(902,!1);this._appRef=t,qb(this._lView)}}const WN=new Set;function TM(n){return t=>{setTimeout(n,void 0,t)}}const Yo=class h7 extends Pt{constructor(t=!1){super(),this.__isAsync=t}emit(t){super.next(t)}subscribe(t,e,i){let r=t,s=e||(()=>null),o=i;if(t&&"object"==typeof t){const l=t;r=l.next?.bind(l),s=l.error?.bind(l),o=l.complete?.bind(l)}this.__isAsync&&(s=TM(s),r&&(r=TM(r)),o&&(o=TM(o)));const a=super.subscribe({next:r,error:s,complete:o});return t instanceof As&&t.add(a),a}};function YN(...n){}class zr{constructor({enableLongStackTrace:t=!1,shouldCoalesceEventChangeDetection:e=!1,shouldCoalesceRunChangeDetection:i=!1}){if(this.hasPendingMacrotasks=!1,this.hasPendingMicrotasks=!1,this.isStable=!0,this.onUnstable=new Yo(!1),this.onMicrotaskEmpty=new Yo(!1),this.onStable=new Yo(!1),this.onError=new Yo(!1),typeof Zone>"u")throw new F(908,!1);Zone.assertZonePatched();const r=this;r._nesting=0,r._outer=r._inner=Zone.current,Zone.TaskTrackingZoneSpec&&(r._inner=r._inner.fork(new Zone.TaskTrackingZoneSpec)),t&&Zone.longStackTraceZoneSpec&&(r._inner=r._inner.fork(Zone.longStackTraceZoneSpec)),r.shouldCoalesceEventChangeDetection=!i&&e,r.shouldCoalesceRunChangeDetection=i,r.lastRequestAnimationFrameId=-1,r.nativeRequestAnimationFrame=function c7(){const n="function"==typeof rr.requestAnimationFrame;let t=rr[n?"requestAnimationFrame":"setTimeout"],e=rr[n?"cancelAnimationFrame":"clearTimeout"];if(typeof Zone<"u"&&t&&e){const i=t[Zone.__symbol__("OriginalDelegate")];i&&(t=i);const r=e[Zone.__symbol__("OriginalDelegate")];r&&(e=r)}return{nativeRequestAnimationFrame:t,nativeCancelAnimationFrame:e}}().nativeRequestAnimationFrame,function p7(n){const t=()=>{!function u7(n){n.isCheckStableRunning||-1!==n.lastRequestAnimationFrameId||(n.lastRequestAnimationFrameId=n.nativeRequestAnimationFrame.call(rr,()=>{n.fakeTopEventTask||(n.fakeTopEventTask=Zone.root.scheduleEventTask("fakeTopEventTask",()=>{n.lastRequestAnimationFrameId=-1,LM(n),n.isCheckStableRunning=!0,AM(n),n.isCheckStableRunning=!1},void 0,()=>{},()=>{})),n.fakeTopEventTask.invoke()}),LM(n))}(n)};n._inner=n._inner.fork({name:"angular",properties:{isAngularZone:!0},onInvokeTask:(e,i,r,s,o,a)=>{if(function f7(n){return!(!Array.isArray(n)||1!==n.length)&&!0===n[0].data?.__ignore_ng_zone__}(a))return e.invokeTask(r,s,o,a);try{return QN(n),e.invokeTask(r,s,o,a)}finally{(n.shouldCoalesceEventChangeDetection&&"eventTask"===s.type||n.shouldCoalesceRunChangeDetection)&&t(),GN(n)}},onInvoke:(e,i,r,s,o,a,l)=>{try{return QN(n),e.invoke(r,s,o,a,l)}finally{n.shouldCoalesceRunChangeDetection&&t(),GN(n)}},onHasTask:(e,i,r,s)=>{e.hasTask(r,s),i===r&&("microTask"==s.change?(n._hasPendingMicrotasks=s.microTask,LM(n),AM(n)):"macroTask"==s.change&&(n.hasPendingMacrotasks=s.macroTask))},onHandleError:(e,i,r,s)=>(e.handleError(r,s),n.runOutsideAngular(()=>n.onError.emit(s)),!1)})}(r)}static isInAngularZone(){return typeof Zone<"u"&&!0===Zone.current.get("isAngularZone")}static assertInAngularZone(){if(!zr.isInAngularZone())throw new F(909,!1)}static assertNotInAngularZone(){if(zr.isInAngularZone())throw new F(909,!1)}run(t,e,i){return this._inner.run(t,e,i)}runTask(t,e,i,r){const s=this._inner,o=s.scheduleEventTask("NgZoneEvent: "+r,t,d7,YN,YN);try{return s.runTask(o,e,i)}finally{s.cancelTask(o)}}runGuarded(t,e,i){return this._inner.runGuarded(t,e,i)}runOutsideAngular(t){return this._outer.run(t)}}const d7={};function AM(n){if(0==n._nesting&&!n.hasPendingMicrotasks&&!n.isStable)try{n._nesting++,n.onMicrotaskEmpty.emit(null)}finally{if(n._nesting--,!n.hasPendingMicrotasks)try{n.runOutsideAngular(()=>n.onStable.emit(null))}finally{n.isStable=!0}}}function LM(n){n.hasPendingMicrotasks=!!(n._hasPendingMicrotasks||(n.shouldCoalesceEventChangeDetection||n.shouldCoalesceRunChangeDetection)&&-1!==n.lastRequestAnimationFrameId)}function QN(n){n._nesting++,n.isStable&&(n.isStable=!1,n.onUnstable.emit(null))}function GN(n){n._nesting--,AM(n)}let $f=(()=>{class n{constructor(){this.handler=null,this.internalCallbacks=[]}execute(){const e=[...this.internalCallbacks];this.internalCallbacks.length=0;for(const r of e)r();return!!this.handler?.execute()||e.length>0}ngOnDestroy(){this.handler?.destroy(),this.handler=null,this.internalCallbacks.length=0}static{this.\u0275prov=Yi({token:n,providedIn:"root",factory:()=>new n})}}return n})();function y7(n,t){const e=To(t,n),i=e[Be];!function S7(n,t){for(let e=t.length;e0&&BL(n,e,s.join(" "))}}(u,w,f,i),void 0!==e&&function A7(n,t,e){const i=n.projection=[];for(let r=0;r=0;i--){const r=n[i];r.hostVars=t+=r.hostVars,r.hostAttrs=If(r.hostAttrs,e=If(e,r.hostAttrs))}}(i)}function N7(n,t){for(const e in t.inputs){if(!t.inputs.hasOwnProperty(e)||n.inputs.hasOwnProperty(e))continue;const i=t.inputs[e];if(void 0!==i&&(n.inputs[e]=i,n.declaredInputs[e]=t.declaredInputs[e],null!==t.inputTransforms)){const r=Array.isArray(i)?i[0]:i;if(!t.inputTransforms.hasOwnProperty(r))continue;n.inputTransforms??={},n.inputTransforms[r]=t.inputTransforms[r]}}}function xy(n){return n===tl?{}:n===Qi?[]:n}function k7(n,t){const e=n.viewQuery;n.viewQuery=e?(i,r)=>{t(i,r),e(i,r)}:t}function P7(n,t){const e=n.contentQueries;n.contentQueries=e?(i,r,s)=>{t(i,r,s),e(i,r,s)}:t}function z7(n,t){const e=n.hostBindings;n.hostBindings=e?(i,r)=>{t(i,r),e(i,r)}:t}function Nu(n,t){return!t||null===t.firstChild||iy(n)}function rg(n,t,e,i=!0){const r=t[Be];if(function r6(n,t,e,i){const r=mn+i,s=e.length;i>0&&(e[r-1][Ma]=t),i{class n{static{this.__NG_ELEMENT_ID__=h9}}return n})();function h9(){return fO(fr(),Se())}const c9=xn,uO=class extends c9{constructor(t,e,i){super(),this._lContainer=t,this._hostTNode=e,this._hostLView=i}get element(){return Tu(this._hostTNode,this._hostLView)}get injector(){return new Vn(this._hostTNode,this._hostLView)}get parentInjector(){const t=jm(this._hostTNode,this._hostLView);if(o1(t)){const e=Nf(t,this._hostLView),i=Lf(t);return new Vn(e[Be].data[i+8],e)}return new Vn(null,this._hostLView)}clear(){for(;this.length>0;)this.remove(this.length-1)}get(t){const e=pO(this._lContainer);return null!==e&&e[t]||null}get length(){return this._lContainer.length-mn}createEmbeddedView(t,e,i){let r,s;"number"==typeof i?r=i:null!=i&&(r=i.index,s=i.injector);const a=t.createEmbeddedViewImpl(e||{},s,null);return this.insertImpl(a,r,Nu(this._hostTNode,null)),a}createComponent(t,e,i,r,s){const o=t&&!function Of(n){return"function"==typeof n}(t);let a;if(o)a=e;else{const f=e||{};a=f.index,i=f.injector,r=f.projectableNodes,s=f.environmentInjector||f.ngModuleRef}const l=o?t:new Zf(ci(t)),h=i||this.parentInjector;if(!s&&null==l.ngModule){const g=(o?h:this.parentInjector).get(Jl,null);g&&(s=g)}ci(l.componentType??{});const p=l.create(h,r,null,s);return this.insertImpl(p.hostView,a,Nu(this._hostTNode,null)),p}insert(t,e){return this.insertImpl(t,e,!0)}insertImpl(t,e,i){const r=t._lView;if(function hU(n){return Ps(n[vn])}(r)){const a=this.indexOf(t);if(-1!==a)this.detach(a);else{const l=r[vn],h=new uO(l,l[Os],l[vn]);h.detach(h.indexOf(t))}}const s=this._adjustIndex(e),o=this._lContainer;return rg(o,r,s,i),t.attachToViewContainerRef(),jA(BM(o),s,t),t}move(t,e){return this.insert(t,e)}indexOf(t){const e=pO(this._lContainer);return null!==e?e.indexOf(t):-1}remove(t){const e=this._adjustIndex(t,-1),i=Bf(this._lContainer,e);i&&(Wm(BM(this._lContainer),e),oy(i[Be],i))}detach(t){const e=this._adjustIndex(t,-1),i=Bf(this._lContainer,e);return i&&null!=Wm(BM(this._lContainer),e)?new qf(i):null}_adjustIndex(t,e=0){return t??this.length+e}};function pO(n){return n[8]}function BM(n){return n[8]||(n[8]=[])}function fO(n,t){let e;const i=t[n.index];return Ps(i)?e=i:(e=function zN(n,t,e,i){return[n,!0,0,t,null,i,null,e,null,null]}(i,t,null,n),t[n.index]=e,Cy(t,e)),gO(e,t,n,i),new uO(e,n,t)}let gO=function mO(n,t,e,i){if(n[rl])return;let r;r=8&e.type?pr(i):function d9(n,t){const e=n[Yt],i=e.createComment(""),r=qs(t,n);return qc(e,ay(e,r),i,function l6(n,t){return n.nextSibling(t)}(e,r),!1),i}(t,e),n[rl]=r};function Fy(n,t,e){const i=Se();return function Tn(n,t,e){return!Object.is(n[t],e)&&(n[t]=e,!0)}(i,function al(){return Rt.lFrame.bindingIndex++}(),t)&&function No(n,t,e,i,r,s,o,a){const l=qs(t,e);let c,h=t.inputs;!a&&null!=h&&(c=h[i])?(CM(n,e,c,i,r),jc(t)&&function kV(n,t){const e=To(t,n);16&e[Ct]||(e[Ct]|=64)}(e,t.index)):3&t.type&&(i=function OV(n){return"class"===n?"className":"for"===n?"htmlFor":"formaction"===n?"formAction":"innerHtml"===n?"innerHTML":"readonly"===n?"readOnly":"tabindex"===n?"tabIndex":n}(i),r=null!=o?o(r,t.value||"",i):r,s.setProperty(l,i,r))}(xi(),function Pr(){const n=Rt.lFrame;return Df(n.tView,n.selectedIndex)}(),i,n,t,i[Yt],e,!1),Fy}function ZM(n,t,e,i,r){const o=r?"class":"style";CM(n,e,t.inputs[o],o,i)}function id(n,t,e,i){const r=Se(),s=xi(),o=Ut+n,a=r[Yt],l=s.firstCreatePass?function B8(n,t,e,i,r,s){const o=t.consts,l=Au(t,n,2,i,sl(o,r));return function IM(n,t,e,i){if(vA()){const r=null===i?null:{"":-1},s=function FV(n,t){const e=n.directiveRegistry;let i=null,r=null;if(e)for(let s=0;s(qh(!0),sy(i,r,function xA(){return Rt.lFrame.currentNamespace}()));const qu="en-US";let wk=qu;function aw(n){return!!n&&"function"==typeof n.then}function Xk(n){return!!n&&"function"==typeof n.subscribe}function Qy(n,t,e,i){const r=Se(),s=xi(),o=fr();return function $k(n,t,e,i,r,s,o){const a=km(i),h=n.firstCreatePass&&BN(n),c=t[Er],d=HN(t);let u=!0;if(3&i.type||o){const g=qs(i,t),v=o?o(g):g,y=d.length,S=o?M=>o(pr(M[i.index])):i.index;let b=null;if(!o&&a&&(b=function UW(n,t,e,i){const r=n.cleanup;if(null!=r)for(let s=0;sl?a[l]:null}"string"==typeof o&&(s+=2)}return null}(n,t,r,i.index)),null!==b)(b.__ngLastListenerFn__||b).__ngNextListenerFn__=s,b.__ngLastListenerFn__=s,u=!1;else{s=Jk(i,t,c,s,!1);const M=e.listen(v,r,s);d.push(s,M),h&&h.push(r,S,y,y+1)}}else s=Jk(i,t,c,s,!1);const p=i.outputs;let f;if(u&&null!==p&&(f=p[r])){const g=f.length;if(g)for(let v=0;v-1?To(n.index,t):t);let l=Zk(t,e,i,o),h=s.__ngNextListenerFn__;for(;h;)l=Zk(t,e,h,o)&&l,h=h.__ngNextListenerFn__;return r&&!1===l&&o.preventDefault(),l}}function QW(){return this._results[Symbol.iterator]()}class hw{get changes(){return this._changes??=new Yo}constructor(t=!1){this._emitDistinctChangesOnly=t,this.dirty=!0,this._results=[],this._changesDetected=!1,this._changes=void 0,this.length=0,this.first=void 0,this.last=void 0;const e=hw.prototype;e[Symbol.iterator]||(e[Symbol.iterator]=QW)}get(t){return this._results[t]}map(t){return this._results.map(t)}filter(t){return this._results.filter(t)}find(t){return this._results.find(t)}reduce(t,e){return this._results.reduce(t,e)}forEach(t){this._results.forEach(t)}some(t){return this._results.some(t)}toArray(){return this._results.slice()}toString(){return this._results.toString()}reset(t,e){this.dirty=!1;const i=function oo(n){return n.flat(Number.POSITIVE_INFINITY)}(t);(this._changesDetected=!function $U(n,t,e){if(n.length!==t.length)return!1;for(let i=0;i{class n{static{this.__NG_ELEMENT_ID__=qW}}return n})();const GW=ih,XW=class extends GW{constructor(t,e,i){super(),this._declarationLView=t,this._declarationTContainer=e,this.elementRef=i}get ssrId(){return this._declarationTContainer.tView?.ssrId||null}createEmbeddedView(t,e){return this.createEmbeddedViewImpl(t,e)}createEmbeddedViewImpl(t,e,i){const r=function ig(n,t,e,i){const r=t.tView,a=wy(n,r,e,4096&n[Ct]?4096:16,null,t,null,null,null,i?.injector??null,i?.dehydratedView??null);a[Mf]=n[t.index];const h=n[il];return null!==h&&(a[il]=h.createEmbeddedView(r)),NM(r,a,e),a}(this._declarationLView,this._declarationTContainer,t,{injector:e,dehydratedView:i});return new qf(r)}};function qW(){return Gy(fr(),Se())}function Gy(n,t){return 4&n.type?new XW(t,n,Tu(n,t)):null}class cw{constructor(t){this.queryList=t,this.matches=null}clone(){return new cw(this.queryList)}setDirty(){this.queryList.setDirty()}}class dw{constructor(t=[]){this.queries=t}createEmbeddedView(t){const e=t.queries;if(null!==e){const i=null!==t.contentQueries?t.contentQueries[0]:e.length,r=[];for(let s=0;s0)i.push(o[a/2]);else{const h=s[a+1],c=t[-l];for(let d=mn;d(qh(!0),function ny(n,t){return n.createText(t)}(t[Yt],i));function mw(n,t,e,i,r){if(n=vt(n),Array.isArray(n))for(let s=0;s>20;if(Gc(n)||!n.multi){const p=new Af(h,r,Ot),f=Sw(l,t,r?c:c+u,d);-1===f?(h1(Um(a,o),s,l),yw(s,n,t.length),t.push(l),a.directiveStart++,a.directiveEnd++,r&&(a.providerIndexes+=1048576),e.push(p),o.push(p)):(e[f]=p,o[f]=p)}else{const p=Sw(l,t,c+u,d),f=Sw(l,t,c,c+u),v=f>=0&&e[f];if(r&&!v||!r&&!(p>=0&&e[p])){h1(Um(a,o),s,l);const y=function yY(n,t,e,i,r){const s=new Af(n,e,Ot);return s.multi=[],s.index=t,s.componentProviders=0,kP(s,r,i&&!e),s}(r?mY:vY,e.length,r,i,h);!r&&v&&(e[f].providerFactory=y),yw(s,n,t.length,0),t.push(l),a.directiveStart++,a.directiveEnd++,r&&(a.providerIndexes+=1048576),e.push(y),o.push(y)}else yw(s,n,p>-1?p:f,kP(e[r?f:p],h,!r&&i));!r&&i&&v&&e[f].componentProviders++}}}function yw(n,t,e,i){const r=Gc(t),s=function gj(n){return!!n.useClass}(t);if(r||s){const l=(s?vt(t.useClass):t).prototype.ngOnDestroy;if(l){const h=n.destroyHooks||(n.destroyHooks=[]);if(!r&&t.multi){const c=h.indexOf(e);-1===c?h.push(e,[i,l]):h[c+1].push(i,l)}else h.push(e,l)}}}function kP(n,t,e){return e&&n.componentProviders++,n.multi.push(t)-1}function Sw(n,t,e,i){for(let r=e;r{e.providersResolver=(i,r)=>function gY(n,t,e){const i=xi();if(i.firstCreatePass){const r=Ca(n);mw(e,i.data,i.blueprint,r,!0),mw(t,i.data,i.blueprint,r,!1)}}(i,r?r(n):n,t)}}class sd{}class zP extends sd{constructor(t){super(),this.componentFactoryResolver=new KN(this),this.instance=null;const e=new yu([...t.providers,{provide:sd,useValue:this},{provide:Sy,useValue:this.componentFactoryResolver}],t.parent||Zm(),t.debugName,new Set(["environment"]));this.injector=e,t.runEnvironmentInitializers&&e.resolveInjectorInitializers()}destroy(){this.injector.destroy()}onDestroy(t){this.injector.onDestroy(t)}}let wY=(()=>{class n{constructor(e){this._injector=e,this.cachedInjectors=new Map}getOrCreateStandaloneInjector(e){if(!e.standalone)return null;if(!this.cachedInjectors.has(e)){const i=qA(0,e.type),r=i.length>0?function MY(n,t,e=null){return new zP({providers:n,parent:t,debugName:e,runEnvironmentInitializers:!0}).injector}([i],this._injector,`Standalone[${e.type.name}]`):null;this.cachedInjectors.set(e,r)}return this.cachedInjectors.get(e)}ngOnDestroy(){try{for(const e of this.cachedInjectors.values())null!==e&&e.destroy()}finally{this.cachedInjectors.clear()}}static{this.\u0275prov=Yi({token:n,providedIn:"environment",factory:()=>new n(Fi(Jl))})}}return n})();function RP(n){(function Zc(n){WN.has(n)||(WN.add(n),performance?.mark?.("mark_feature_usage",{detail:{feature:n}}))})("NgStandalone"),n.getStandaloneInjector=t=>t.get(wY).getOrCreateStandaloneInjector(n)}let Aw=(()=>{class n{constructor(){this.taskId=0,this.pendingTasks=new Set,this.hasPendingTasks=new _o(!1)}get _hasPendingTasks(){return this.hasPendingTasks.value}add(){this._hasPendingTasks||this.hasPendingTasks.next(!0);const e=this.taskId++;return this.pendingTasks.add(e),e}remove(e){this.pendingTasks.delete(e),0===this.pendingTasks.size&&this._hasPendingTasks&&this.hasPendingTasks.next(!1)}ngOnDestroy(){this.pendingTasks.clear(),this._hasPendingTasks&&this.hasPendingTasks.next(!1)}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();const g2=new Ht(""),XQ=new Ht("");let Pw=(()=>{class n{constructor(){this.initialized=!1,this.done=!1,this.donePromise=new Promise((e,i)=>{this.resolve=e,this.reject=i}),this.appInits=Ri(XQ,{optional:!0})??[]}runInitializers(){if(this.initialized)return;const e=[];for(const r of this.appInits){const s=r();if(aw(s))e.push(s);else if(Xk(s)){const o=new Promise((a,l)=>{s.subscribe({complete:a,error:l})});e.push(o)}}const i=()=>{this.done=!0,this.resolve()};Promise.all(e).then(()=>{i()}).catch(r=>{this.reject(r)}),0===e.length&&i(),this.initialized=!0}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();const v2=new Ht("");let Ju=(()=>{class n{constructor(){this._bootstrapListeners=[],this._runningTick=!1,this._destroyed=!1,this._destroyListeners=[],this._views=[],this.internalErrorHandler=Ri(IN),this.afterRenderEffectManager=Ri($f),this.componentTypes=[],this.components=[],this.isStable=Ri(Aw).hasPendingTasks.pipe(jr(e=>!e)),this._injector=Ri(Jl)}get destroyed(){return this._destroyed}get injector(){return this._injector}bootstrap(e,i){const r=e instanceof nN;if(!this._injector.get(Pw).done)throw!r&&function _c(n){const t=ci(n)||jn(n)||gs(n);return null!==t&&t.standalone}(e),new F(405,!1);let o;o=r?e:this._injector.get(Sy).resolveComponentFactory(e),this.componentTypes.push(o.componentType);const a=function $Q(n){return n.isBoundToModule}(o)?void 0:this._injector.get(sd),h=o.create(Wo.NULL,[],i||o.selector,a),c=h.location.nativeElement,d=h.injector.get(g2,null);return d?.registerApplication(c),h.onDestroy(()=>{this.detachView(h.hostView),Ky(this.components,h),d?.unregisterApplication(c)}),this._loadComponent(h),h}tick(){if(this._runningTick)throw new F(101,!1);try{this._runningTick=!0;for(let e of this._views)e.detectChanges()}catch(e){this.internalErrorHandler(e)}finally{try{this.afterRenderEffectManager.execute()}catch(e){this.internalErrorHandler(e)}this._runningTick=!1}}attachView(e){const i=e;this._views.push(i),i.attachToAppRef(this)}detachView(e){const i=e;Ky(this._views,i),i.detachFromAppRef()}_loadComponent(e){this.attachView(e.hostView),this.tick(),this.components.push(e);const i=this._injector.get(v2,[]);[...this._bootstrapListeners,...i].forEach(r=>r(e))}ngOnDestroy(){if(!this._destroyed)try{this._destroyListeners.forEach(e=>e()),this._views.slice().forEach(e=>e.destroy())}finally{this._destroyed=!0,this._views=[],this._bootstrapListeners=[],this._destroyListeners=[]}}onDestroy(e){return this._destroyListeners.push(e),()=>Ky(this._destroyListeners,e)}destroy(){if(this._destroyed)throw new F(406,!1);const e=this._injector;e.destroy&&!e.destroyed&&e.destroy()}get viewCount(){return this._views.length}warnIfDestroyed(){}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();function Ky(n,t){const e=n.indexOf(t);e>-1&&n.splice(e,1)}let JQ=(()=>{class n{constructor(){this.zone=Ri(zr),this.applicationRef=Ri(Ju)}initialize(){this._onMicrotaskEmptySubscription||(this._onMicrotaskEmptySubscription=this.zone.onMicrotaskEmpty.subscribe({next:()=>{this.zone.run(()=>{this.applicationRef.tick()})}}))}ngOnDestroy(){this._onMicrotaskEmptySubscription?.unsubscribe()}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();function b2(n){return[{provide:zr,useFactory:n},{provide:mu,multi:!0,useFactory:()=>{const t=Ri(JQ,{optional:!0});return()=>t.initialize()}},{provide:mu,multi:!0,useFactory:()=>{const t=Ri(tG);return()=>{t.initialize()}}},{provide:IN,useFactory:KQ}]}function KQ(){const n=Ri(zr),t=Ri(eh);return e=>n.runOutsideAngular(()=>t.handleError(e))}function eG(n){return function I1(n){return{\u0275providers:n}}([[],b2(()=>new zr(function M2(n){return{enableLongStackTrace:!1,shouldCoalesceEventChangeDetection:n?.eventCoalescing??!1,shouldCoalesceRunChangeDetection:n?.runCoalescing??!1}}(n)))])}let tG=(()=>{class n{constructor(){this.subscription=new As,this.initialized=!1,this.zone=Ri(zr),this.pendingTasks=Ri(Aw)}initialize(){if(this.initialized)return;this.initialized=!0;let e=null;!this.zone.isStable&&!this.zone.hasPendingMacrotasks&&!this.zone.hasPendingMicrotasks&&(e=this.pendingTasks.add()),this.zone.runOutsideAngular(()=>{this.subscription.add(this.zone.onStable.subscribe(()=>{zr.assertNotInAngularZone(),queueMicrotask(()=>{null!==e&&!this.zone.hasPendingMacrotasks&&!this.zone.hasPendingMicrotasks&&(this.pendingTasks.remove(e),e=null)})}))}),this.subscription.add(this.zone.onUnstable.subscribe(()=>{zr.assertInAngularZone(),e??=this.pendingTasks.add()}))}ngOnDestroy(){this.subscription.unsubscribe()}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();const rh=new Ht("",{providedIn:"root",factory:()=>Ri(rh,Di.Optional|Di.SkipSelf)||function iG(){return typeof $localize<"u"&&$localize.locale||qu}()}),zw=new Ht("");let rc=null;function DG(n){try{const{rootComponent:t,appProviders:e,platformProviders:i}=n,r=function aG(n=[]){if(rc)return rc;const t=function E2(n=[],t){return Wo.create({name:t,providers:[{provide:w1,useValue:"platform"},{provide:zw,useValue:new Set([()=>rc=null])},...n]})}(n);return rc=t,function m2(){!function bb(n){qd=n}(()=>{throw new F(600,!1)})}(),function D2(n){n.get(oL,null)?.forEach(e=>e())}(t),t}(i),s=[eG(),...e||[]],a=new zP({providers:s,parent:r,debugName:"",runEnvironmentInitializers:!1}).injector,l=a.get(zr);return l.run(()=>{a.resolveInjectorInitializers();const h=a.get(eh,null);let c;l.runOutsideAngular(()=>{c=l.onError.subscribe({next:p=>{h.handleError(p)}})});const d=()=>a.destroy(),u=r.get(zw);return u.add(d),a.onDestroy(()=>{c.unsubscribe(),u.delete(d)}),function y2(n,t,e){try{const i=e();return aw(i)?i.catch(r=>{throw t.runOutsideAngular(()=>n.handleError(r)),r}):i}catch(i){throw t.runOutsideAngular(()=>n.handleError(i)),i}}(h,l,()=>{const p=a.get(Pw);return p.runInitializers(),p.donePromise.then(()=>{!function Ck(n){ro(n,"Expected localeId to be defined"),"string"==typeof n&&(wk=n.toLowerCase().replace(/_/g,"-"))}(a.get(rh,qu)||qu);const g=a.get(Ju);return void 0!==t&&g.bootstrap(t),g})})})}catch(t){return Promise.reject(t)}}let $2=null;function Vw(){return $2}class UG{}const ad=new Ht("");let sq=(()=>{class n{static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275mod=Am({type:n})}static{this.\u0275inj=mf({})}}return n})();function uz(n){return"server"===n}class kq extends UG{constructor(){super(...arguments),this.supportsDOMEvents=!0}}class oC extends kq{static makeCurrent(){!function _G(n){$2??=n}(new oC)}onAndCancel(t,e,i){return t.addEventListener(e,i),()=>{t.removeEventListener(e,i)}}dispatchEvent(t,e){t.dispatchEvent(e)}remove(t){t.parentNode&&t.parentNode.removeChild(t)}createElement(t,e){return(e=e||this.getDefaultDocument()).createElement(t)}createHtmlDocument(){return document.implementation.createHTMLDocument("fakeTitle")}getDefaultDocument(){return document}isElementNode(t){return t.nodeType===Node.ELEMENT_NODE}isShadowRoot(t){return t instanceof DocumentFragment}getGlobalEventTarget(t,e){return"window"===e?window:"document"===e?t:"body"===e?t.body:null}getBaseHref(t){const e=function Pq(){return wg=wg||document.querySelector("base"),wg?wg.getAttribute("href"):null}();return null==e?null:function zq(n){return new URL(n,document.baseURI).pathname}(e)}resetBaseElement(){wg=null}getUserAgent(){return window.navigator.userAgent}getCookie(t){return function xX(n,t){t=encodeURIComponent(t);for(const e of n.split(";")){const i=e.indexOf("="),[r,s]=-1==i?[e,""]:[e.slice(0,i),e.slice(i+1)];if(r.trim()===t)return decodeURIComponent(s)}return null}(document.cookie,t)}}let wg=null,Hq=(()=>{class n{build(){return new XMLHttpRequest}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();const aC=new Ht("");let vz=(()=>{class n{constructor(e,i){this._zone=i,this._eventNameToPlugin=new Map,e.forEach(r=>{r.manager=this}),this._plugins=e.slice().reverse()}addEventListener(e,i,r){return this._findPluginFor(i).addEventListener(e,i,r)}getZone(){return this._zone}_findPluginFor(e){let i=this._eventNameToPlugin.get(e);if(i)return i;if(i=this._plugins.find(s=>s.supports(e)),!i)throw new F(5101,!1);return this._eventNameToPlugin.set(e,i),i}static{this.\u0275fac=function(i){return new(i||n)(Fi(aC),Fi(zr))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();class mz{constructor(t){this._doc=t}}const lC="ng-app-id";let yz=(()=>{class n{constructor(e,i,r,s={}){this.doc=e,this.appId=i,this.nonce=r,this.platformId=s,this.styleRef=new Map,this.hostNodes=new Set,this.styleNodesInDOM=this.collectServerRenderedStyles(),this.platformIsServer=uz(s),this.resetHostNodes()}addStyles(e){for(const i of e)1===this.changeUsageCount(i,1)&&this.onStyleAdded(i)}removeStyles(e){for(const i of e)this.changeUsageCount(i,-1)<=0&&this.onStyleRemoved(i)}ngOnDestroy(){const e=this.styleNodesInDOM;e&&(e.forEach(i=>i.remove()),e.clear());for(const i of this.getAllStyles())this.onStyleRemoved(i);this.resetHostNodes()}addHost(e){this.hostNodes.add(e);for(const i of this.getAllStyles())this.addStyleToHost(e,i)}removeHost(e){this.hostNodes.delete(e)}getAllStyles(){return this.styleRef.keys()}onStyleAdded(e){for(const i of this.hostNodes)this.addStyleToHost(i,e)}onStyleRemoved(e){const i=this.styleRef;i.get(e)?.elements?.forEach(r=>r.remove()),i.delete(e)}collectServerRenderedStyles(){const e=this.doc.head?.querySelectorAll(`style[${lC}="${this.appId}"]`);if(e?.length){const i=new Map;return e.forEach(r=>{null!=r.textContent&&i.set(r.textContent,r)}),i}return null}changeUsageCount(e,i){const r=this.styleRef;if(r.has(e)){const s=r.get(e);return s.usage+=i,s.usage}return r.set(e,{usage:i,elements:[]}),i}getStyleElement(e,i){const r=this.styleNodesInDOM,s=r?.get(i);if(s?.parentNode===e)return r.delete(i),s.removeAttribute(lC),s;{const o=this.doc.createElement("style");return this.nonce&&o.setAttribute("nonce",this.nonce),o.textContent=i,this.platformIsServer&&o.setAttribute(lC,this.appId),e.appendChild(o),o}}addStyleToHost(e,i){const r=this.getStyleElement(e,i),s=this.styleRef,o=s.get(i)?.elements;o?o.push(r):s.set(i,{elements:[r],usage:1})}resetHostNodes(){const e=this.hostNodes;e.clear(),e.add(this.doc.head)}static{this.\u0275fac=function(i){return new(i||n)(Fi(ad),Fi(L1),Fi(aL,8),Fi(Iu))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();const hC={svg:"http://www.w3.org/2000/svg",xhtml:"http://www.w3.org/1999/xhtml",xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/",math:"http://www.w3.org/1998/MathML/"},cC=/%COMP%/g,Uq=new Ht("",{providedIn:"root",factory:()=>!0});function Iz(n,t){return t.map(e=>e.replace(cC,n))}let bz=(()=>{class n{constructor(e,i,r,s,o,a,l,h=null){this.eventManager=e,this.sharedStylesHost=i,this.appId=r,this.removeStylesOnCompDestroy=s,this.doc=o,this.platformId=a,this.ngZone=l,this.nonce=h,this.rendererByCompId=new Map,this.platformIsServer=uz(a),this.defaultRenderer=new dC(e,o,l,this.platformIsServer)}createRenderer(e,i){if(!e||!i)return this.defaultRenderer;this.platformIsServer&&i.encapsulation===Ia.ShadowDom&&(i={...i,encapsulation:Ia.Emulated});const r=this.getOrCreateRenderer(e,i);return r instanceof wz?r.applyToHost(e):r instanceof uC&&r.applyStyles(),r}getOrCreateRenderer(e,i){const r=this.rendererByCompId;let s=r.get(i.id);if(!s){const o=this.doc,a=this.ngZone,l=this.eventManager,h=this.sharedStylesHost,c=this.removeStylesOnCompDestroy,d=this.platformIsServer;switch(i.encapsulation){case Ia.Emulated:s=new wz(l,h,i,this.appId,c,o,a,d);break;case Ia.ShadowDom:return new Yq(l,h,e,i,o,a,this.nonce,d);default:s=new uC(l,h,i,c,o,a,d)}r.set(i.id,s)}return s}ngOnDestroy(){this.rendererByCompId.clear()}static{this.\u0275fac=function(i){return new(i||n)(Fi(vz),Fi(yz),Fi(L1),Fi(Uq),Fi(ad),Fi(Iu),Fi(zr),Fi(aL))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();class dC{constructor(t,e,i,r){this.eventManager=t,this.doc=e,this.ngZone=i,this.platformIsServer=r,this.data=Object.create(null),this.throwOnSyntheticProps=!0,this.destroyNode=null}destroy(){}createElement(t,e){return e?this.doc.createElementNS(hC[e]||e,t):this.doc.createElement(t)}createComment(t){return this.doc.createComment(t)}createText(t){return this.doc.createTextNode(t)}appendChild(t,e){(Mz(t)?t.content:t).appendChild(e)}insertBefore(t,e,i){t&&(Mz(t)?t.content:t).insertBefore(e,i)}removeChild(t,e){t&&t.removeChild(e)}selectRootElement(t,e){let i="string"==typeof t?this.doc.querySelector(t):t;if(!i)throw new F(-5104,!1);return e||(i.textContent=""),i}parentNode(t){return t.parentNode}nextSibling(t){return t.nextSibling}setAttribute(t,e,i,r){if(r){e=r+":"+e;const s=hC[r];s?t.setAttributeNS(s,e,i):t.setAttribute(e,i)}else t.setAttribute(e,i)}removeAttribute(t,e,i){if(i){const r=hC[i];r?t.removeAttributeNS(r,e):t.removeAttribute(`${i}:${e}`)}else t.removeAttribute(e)}addClass(t,e){t.classList.add(e)}removeClass(t,e){t.classList.remove(e)}setStyle(t,e,i,r){r&(Kh.DashCase|Kh.Important)?t.style.setProperty(e,i,r&Kh.Important?"important":""):t.style[e]=i}removeStyle(t,e,i){i&Kh.DashCase?t.style.removeProperty(e):t.style[e]=""}setProperty(t,e,i){null!=t&&(t[e]=i)}setValue(t,e){t.nodeValue=e}listen(t,e,i){if("string"==typeof t&&!(t=Vw().getGlobalEventTarget(this.doc,t)))throw new Error(`Unsupported event target ${t} for event ${e}`);return this.eventManager.addEventListener(t,e,this.decoratePreventDefault(i))}decoratePreventDefault(t){return e=>{if("__ngUnwrap__"===e)return t;!1===(this.platformIsServer?this.ngZone.runGuarded(()=>t(e)):t(e))&&e.preventDefault()}}}function Mz(n){return"TEMPLATE"===n.tagName&&void 0!==n.content}class Yq extends dC{constructor(t,e,i,r,s,o,a,l){super(t,s,o,l),this.sharedStylesHost=e,this.hostEl=i,this.shadowRoot=i.attachShadow({mode:"open"}),this.sharedStylesHost.addHost(this.shadowRoot);const h=Iz(r.id,r.styles);for(const c of h){const d=document.createElement("style");a&&d.setAttribute("nonce",a),d.textContent=c,this.shadowRoot.appendChild(d)}}nodeOrShadowRoot(t){return t===this.hostEl?this.shadowRoot:t}appendChild(t,e){return super.appendChild(this.nodeOrShadowRoot(t),e)}insertBefore(t,e,i){return super.insertBefore(this.nodeOrShadowRoot(t),e,i)}removeChild(t,e){return super.removeChild(this.nodeOrShadowRoot(t),e)}parentNode(t){return this.nodeOrShadowRoot(super.parentNode(this.nodeOrShadowRoot(t)))}destroy(){this.sharedStylesHost.removeHost(this.shadowRoot)}}class uC extends dC{constructor(t,e,i,r,s,o,a,l){super(t,s,o,a),this.sharedStylesHost=e,this.removeStylesOnCompDestroy=r,this.styles=l?Iz(l,i.styles):i.styles}applyStyles(){this.sharedStylesHost.addStyles(this.styles)}destroy(){this.removeStylesOnCompDestroy&&this.sharedStylesHost.removeStyles(this.styles)}}class wz extends uC{constructor(t,e,i,r,s,o,a,l){const h=r+"-"+i.id;super(t,e,i,s,o,a,l,h),this.contentAttr=function jq(n){return"_ngcontent-%COMP%".replace(cC,n)}(h),this.hostAttr=function Vq(n){return"_nghost-%COMP%".replace(cC,n)}(h)}applyToHost(t){this.applyStyles(),this.setAttribute(t,this.hostAttr,"")}createElement(t,e){const i=super.createElement(t,e);return super.setAttribute(i,this.contentAttr,""),i}}let Qq=(()=>{class n extends mz{constructor(e){super(e)}supports(e){return!0}addEventListener(e,i,r){return e.addEventListener(i,r,!1),()=>this.removeEventListener(e,i,r)}removeEventListener(e,i,r){return e.removeEventListener(i,r)}static{this.\u0275fac=function(i){return new(i||n)(Fi(ad))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();const Cz=["alt","control","meta","shift"],Gq={"\b":"Backspace","\t":"Tab","\x7f":"Delete","\x1b":"Escape",Del:"Delete",Esc:"Escape",Left:"ArrowLeft",Right:"ArrowRight",Up:"ArrowUp",Down:"ArrowDown",Menu:"ContextMenu",Scroll:"ScrollLock",Win:"OS"},Xq={alt:n=>n.altKey,control:n=>n.ctrlKey,meta:n=>n.metaKey,shift:n=>n.shiftKey};let qq=(()=>{class n extends mz{constructor(e){super(e)}supports(e){return null!=n.parseEventName(e)}addEventListener(e,i,r){const s=n.parseEventName(i),o=n.eventCallback(s.fullKey,r,this.manager.getZone());return this.manager.getZone().runOutsideAngular(()=>Vw().onAndCancel(e,s.domEventName,o))}static parseEventName(e){const i=e.toLowerCase().split("."),r=i.shift();if(0===i.length||"keydown"!==r&&"keyup"!==r)return null;const s=n._normalizeKey(i.pop());let o="",a=i.indexOf("code");if(a>-1&&(i.splice(a,1),o="code."),Cz.forEach(h=>{const c=i.indexOf(h);c>-1&&(i.splice(c,1),o+=h+".")}),o+=s,0!=i.length||0===s.length)return null;const l={};return l.domEventName=r,l.fullKey=o,l}static matchEventFullKeyCode(e,i){let r=Gq[e.key]||e.key,s="";return i.indexOf("code.")>-1&&(r=e.code,s="code."),!(null==r||!r)&&(r=r.toLowerCase()," "===r?r="space":"."===r&&(r="dot"),Cz.forEach(o=>{o!==r&&(0,Xq[o])(e)&&(s+=o+".")}),s+=r,s===i)}static eventCallback(e,i,r){return s=>{n.matchEventFullKeyCode(s,e)&&r.runGuarded(()=>i(s))}}static _normalizeKey(e){return"esc"===e?"escape":e}static{this.\u0275fac=function(i){return new(i||n)(Fi(ad))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();function Ez(n){return{appProviders:[...i$,...n?.providers??[]],platformProviders:e$}}const e$=[{provide:Iu,useValue:"browser"},{provide:oL,useValue:function Zq(){oC.makeCurrent()},multi:!0},{provide:ad,useFactory:function Kq(){return function Aj(n){A1=n}(document),document},deps:[]}],i$=[{provide:w1,useValue:"root"},{provide:eh,useFactory:function Jq(){return new eh},deps:[]},{provide:aC,useClass:Qq,multi:!0,deps:[ad,zr,Iu]},{provide:aC,useClass:qq,multi:!0,deps:[ad]},bz,yz,vz,{provide:oN,useExisting:bz},{provide:class cq{},useClass:Hq,deps:[]},[]];var o$=0,pC=!1;function M0(n,t){var e=t;return e.unshift(void 0),new(Function.prototype.bind.apply(n,e))}function Y(n,t){for(var e=t,i=n.replace(/\[/g,".").replace(/\]/g,"").split("."),r=0;r"u"}function wi(n){return n+"_"+o$++}function C0(n,t){return n===t||!(n===document||!n)&&C0(n.parentNode,t)}function Dg(n){try{throw new Error(n)}catch(t){throw new Error(t.message+"\n"+t.stack)}}function Re(n){var t=n+"";return t.match(/auto|cm|mm|in|px|pt|pc|%|em|ex|ch|rem|vw|vh|vmin|vmax/)?t:t+"px"}function ce(){return pC}var xg,n,t,d$={latn:{_digits:"0123456789",_type:"numeric"}},Lz={decimal:".",group:",",percentSign:"%",plusSign:"+",minusSign:"-",infinity:"\u221e",nan:"NaN",exponential:"E"},Nz=[0,1,2,3,4,5,6,7,8,9],Rr=function(){function n(){}return n.getMainObject=function(t,e){return Y(ce()?e:"main."+e,t)},n.getNumberingSystem=function(t){return Y("supplemental.numberingSystems",t)||this.numberingSystems},n.reverseObject=function(t,e){for(var r={},s=0,o=e||Object.keys(t);s13&&(f+=1,o-=12),o-=1,a=f-4716;var y=u-24e5,S=10631/30,b=u-1948084,M=Math.floor(b/10631);b-=10631*M;var w=Math.floor((b-.1335)/S),C=30*M+w;b-=Math.floor(w*S+.1335);var D=Math.floor((b+28.5001)/29.5);13===D&&(D=12);for(var A=b-Math.floor(29.5001*D-29),x=0;xy);x++);var R=x+16260,L=Math.floor((R-1)/12),O=L+1,N=R-12*L,T=y-t[x-1]+1;return(T+"").length>2&&(T=A,N=D,O=C),{year:O,month:N,date:T}},n.toGregorian=function i(r,s,o){var g=Math.floor(o+t[12*(r-1)+1+(s-1)-16260-1]-1+24e5+.5),v=Math.floor((g-1867216.25)/36524.25),y=1524+(v=g+1+v-Math.floor(v/4)),S=Math.floor((y-122.1)/365.25),b=Math.floor(365.25*S),M=Math.floor((y-b)/30.6001),w=y-b-Math.floor(30.6001*M),C=M-(M>13.5?13:1),D=S-(C>2.5?4716:4715);return D<=0&&C--,new Date(D+"/"+C+"/"+w)};var ut,f$=/\/MMMMM|MMMM|MMM|a|LLLL|LLL|EEEEE|EEEE|E|K|cccc|ccc|WW|W|G+|z+/gi,Oz="stand-alone",g$=["sun","mon","tue","wed","thu","fri","sat"],kz={m:"getMinutes",h:"getHours",H:"getHours",s:"getSeconds",d:"getDate",f:"getMilliseconds"},Pz=function(){function n(){}return n.dateFormat=function(t,e,i){var r=this,s=ut.getDependables(i,t,e.calendar),o=Y("parserObject.numbers",s),a=s.dateObject,l={isIslamic:ut.islamicRegex.test(e.calendar)};ce()&&e.isServerRendered&&(e=ut.compareBlazorDateFormats(e,t));var h=e.format||ut.getResultantPattern(e.skeleton,s.dateObject,e.type,!1,ce()?t:"");if(l.dateSeperator=ce()?Y("dateSeperator",a):ut.getDateSeparator(s.dateObject),st(h))Dg("Format options or type given must be invalid");else{h=ut.ConvertDateToWeekFormat(h),ce()&&(h=h.replace(/tt/,"a")),l.pattern=h,l.numMapper=ce()?ze({},o):Rr.getNumberMapper(s.parserObject,Rr.getNumberingSystem(i));for(var d=0,u=h.match(f$)||[];d2?r+=e.month[""+u]:f=!0;break;case"E":case"c":r+=e.weekday[""+g$[t.getDay()]];break;case"H":case"h":case"m":case"s":case"d":case"f":if(f=!0,"d"===d)u=o.date;else if("f"===d){f=!1,g=!0;var y=(p=(p=t[""+kz[""+d]]().toString()).substring(0,c)).length;if(c!==y){if(c>3)continue;for(var S=0;S0?1:0],o=Math.abs(t);return s.replace(/HH?|mm/g,function(a){var l=a.length,h=-1!==a.indexOf("H");return i.checkTwodigitNumber(Math.floor(h?o/60:o%60),l)})},n}(),zz={ms:"minimumSignificantDigits",ls:"maximumSignificantDigits",mf:"minimumFractionDigits",lf:"maximumFractionDigits"},ip=["infinity","nan","group","decimal","exponential"],Rz=function(){function n(){}return n.numberFormatter=function(t,e,i){var l,r=this,s=ze({},e),o={},a={},h=ut.getDependables(i,t,"",!0),c=h.numericObject;a.numberMapper=ce()?ze({},c):Rr.getNumberMapper(h.parserObject,Rr.getNumberingSystem(i),!0),a.currencySymbol=ce()?Y("currencySymbol",c):ut.getCurrencySymbol(h.numericObject,s.currency||Lg,e.altSymbol,e.ignoreCurrency),a.percentSymbol=ce()?Y("numberSymbols.percentSign",c):a.numberMapper.numberSymbols.percentSign,a.minusSymbol=ce()?Y("numberSymbols.minusSign",c):a.numberMapper.numberSymbols.minusSign;var d=a.numberMapper.numberSymbols;if(e.format&&!ut.formatRegex.test(e.format))o=ut.customFormat(e.format,a,h.numericObject),!st(s.useGrouping)&&s.useGrouping&&(s.useGrouping=o.pData.useGrouping);else{if(ze(s,ut.getProperNumericSkeleton(e.format||"N")),s.isCurrency="currency"===s.type,s.isPercent="percent"===s.type,ce()||(l=ut.getSymbolPattern(s.type,a.numberMapper.numberSystem,h.numericObject,s.isAccount)),s.groupOne=this.checkValueRange(s.maximumSignificantDigits,s.minimumSignificantDigits,!0),this.checkValueRange(s.maximumFractionDigits,s.minimumFractionDigits,!1,!0),st(s.fractionDigits)||(s.minimumFractionDigits=s.maximumFractionDigits=s.fractionDigits),st(s.useGrouping)&&(s.useGrouping=!0),s.isCurrency&&!ce()&&(l=l.replace(/\u00A4/g,ut.defaultCurrency)),ce())o.nData=ze({},{},Y(s.type+"nData",c)),o.pData=ze({},{},Y(s.type+"pData",c)),"currency"===s.type&&e.currency&&ut.replaceBlazorCurrency([o.pData,o.nData],a.currencySymbol,e.currency);else{var u=l.split(";");o.nData=ut.getFormatData(u[1]||"-"+u[0],!0,a.currencySymbol),o.pData=ut.getFormatData(u[0],!1,a.currencySymbol),s.useGrouping&&(s.groupSeparator=d[ip[2]],s.groupData=this.getGroupingDetails(u[0]))}if(st(s.minimumFractionDigits)&&(s.minimumFractionDigits=o.nData.minimumFraction),st(s.maximumFractionDigits)){var f=o.nData.maximumFraction;s.maximumFractionDigits=st(f)&&s.isPercent?0:f}var g=s.minimumFractionDigits,v=s.maximumFractionDigits;!st(g)&&!st(v)&&g>v&&(s.maximumFractionDigits=g)}return ze(o.nData,s),ze(o.pData,s),function(y){return isNaN(y)?d[ip[1]]:isFinite(y)?r.intNumberFormatter(y,o,a,e):d[ip[0]]}},n.getGroupingDetails=function(t){var e={},i=t.match(ut.negativeDataRegex);if(i&&i[4]){var r=i[4],s=r.lastIndexOf(",");if(-1!==s){var o=r.split(".")[0];e.primary=o.length-s-1;var a=r.lastIndexOf(",",s-1);-1!==a&&(e.secondary=s-1-a)}}return e},n.checkValueRange=function(t,e,i,r){var s=r?"f":"s",o=0,a=zz["l"+s],l=zz["m"+s];if(st(t)||(this.checkRange(t,a,r),o++),st(e)||(this.checkRange(e,l,r),o++),2===o){if(!(tr[1])&&Dg(e+"value must be within the range"+r[0]+"to"+r[1])},n.intNumberFormatter=function(t,e,i,r){var s;if(!st(e.nData.type)){t<0?(t*=-1,s=e.nData):s=0===t&&e.zeroData||e.pData;var o="";if(s.isPercent&&(t*=100),s.groupOne)o=this.processSignificantDigits(t,s.minimumSignificantDigits,s.maximumSignificantDigits);else if(o=this.processFraction(t,s.minimumFractionDigits,s.maximumFractionDigits,r),s.minimumIntegerDigits&&(o=this.processMinimumIntegers(o,s.minimumIntegerDigits)),i.isCustomFormat&&s.minimumFractionDigits=0&&"0"===l[parseInt(c.toString(),10)]&&c>=s.minimumFractionDigits;c--)l=l.slice(0,c);o=a[0]+"."+l}return"scientific"===s.type&&(o=(o=t.toExponential(s.maximumFractionDigits)).replace("e",i.numberMapper.numberSymbols[ip[4]])),o=o.replace(".",i.numberMapper.numberSymbols[ip[3]]),o="#,###,,;(#,###,,)"===s.format?this.customPivotFormat(parseInt(o,10)):o,s.useGrouping&&(o=this.groupNumbers(o,s.groupData.primary,s.groupSeparator||",",i.numberMapper.numberSymbols[ip[3]]||".",s.groupData.secondary)),o=Rr.convertValueParts(o,ut.latnParseRegex,i.numberMapper.mapper),"N/A"===s.nlead?s.nlead:"0"===o&&r&&"0"===r.format?o+s.nend:s.nlead+o+s.nend}},n.processSignificantDigits=function(t,e,i){var r=t+"";return r.lengthe;)c=l.slice(h-e,h)+(c.length?i+c:""),h-=e,o&&(e=s,o=!1);return a[0]=l.slice(0,h)+(c.length?i:"")+c,a.join(r)},n.processFraction=function(t,e,i,r){var s=(t+"").split(".")[1],o=s?s.length:0;if(e&&oi||0===i))return t.toFixed(i);var h=t+"";return"0"===h[0]&&r&&"###.00"===r.format&&(h=h.slice(1)),h},n.processMinimumIntegers=function(t,e){var i=t.split("."),r=i[0],s=r.length;if(s=5e5){var r=(t/=1e6).toString().split(".")[1];return r&&+r.substring(0,1)>=5?Math.ceil(t).toString():Math.floor(t).toString()}return""},n}(),Tg=(new RegExp("^([^0-9]*)(([0-9,]*[0-9]+)(.[0-9]+)?)([Ee][+-]?[0-9]+)?([^0-9]*)$"),function(){function n(t){this.ranArray=[],this.boundedEvents={},!m(t)&&(this.context=t)}return n.prototype.on=function(t,e,i,r){if(!m(e)){var s=i||this.context;if(this.notExist(t))return void(this.boundedEvents[""+t]=[{handler:e,context:s,id:r}]);m(r)?this.isHandlerPresent(this.boundedEvents[""+t],e)||this.boundedEvents[""+t].push({handler:e,context:s}):-1===this.ranArray.indexOf(r)&&(this.ranArray.push(r),this.boundedEvents[""+t].push({handler:e,context:s,id:r}))}},n.prototype.off=function(t,e,i){if(!this.notExist(t)){var r=Y(t,this.boundedEvents);if(e){for(var s=0;s1&&(_.fractionDigits=parseInt(P[2],10)),_}function f(T,P,_,B){var j=B?{}:{nlead:"",nend:""},Q=T.match(n.customRegex);if(Q){B||(j.nlead=g(Q[1],_),j.nend=g(Q[10],_),j.groupPattern=Q[4]);var oe=Q[7];if(oe&&P){var ue=oe.match(t);j.minimumFraction=m(ue)?0:ue.length,j.maximumFraction=oe.length-1}}return j}function g(T,P){return T?(T=T.replace(n.defaultCurrency,P),""===P?T.trim():T):""}function v(T,P,_,B){return B?"$":Y("currencies."+P+(_?"."+_:".symbol"),T)||Y("currencies."+P+".symbol-alt-narrow",T)||"$"}function S(T,P,_){var B={type:"decimal",minimumFractionDigits:0,maximumFractionDigits:0},j=T.match(n.customRegex);if(m(j)||""===j[5]&&"N/A"!==T)return B.type=void 0,B;B.nlead=j[1],B.nend=j[10];var Q=j[6],oe=!!Q.match(/ $/g),ue=-1!==Q.replace(/ $/g,"").indexOf(" ");B.useGrouping=-1!==Q.indexOf(",")||ue,Q=Q.replace(/,/g,"");var pe=j[7];if(-1!==Q.indexOf("0")&&(B.minimumIntegerDigits=Q.length-Q.indexOf("0")),m(pe)||(B.minimumFractionDigits=pe.lastIndexOf("0"),B.maximumFractionDigits=pe.lastIndexOf("#"),-1===B.minimumFractionDigits&&(B.minimumFractionDigits=0),(-1===B.maximumFractionDigits||B.maximumFractionDigitsQ.lastIndexOf("'"))){B[""+a[parseInt(j.toString(),10)]]=Q.substr(0,oe)+_+Q.substr(oe+1),B[""+a[""+P]]=!0,B.type=B.isCurrency?"currency":"percent";break}}return B}function C(T,P){if(-1!==T.indexOf(",")){var _=T.split(",");T=_[0]+Y("numberMapper.numberSymbols.group",P)+_[1].replace(".",Y("numberMapper.numberSymbols.decimal",P))}else T=T.replace(".",Y("numberMapper.numberSymbols.decimal",P));return T}function A(T,P,_){T+=".";for(var B=0;B0;Q-=3)T=","+_[Q-2]+_[Q-1]+_[parseInt(Q.toString(),10)]+T;return T=T.slice(1),P[1]?T+"."+P[1]:T}n.dateParseRegex=/([a-z])\1*|'([^']|'')+'|''|./gi,n.basicPatterns=["short","medium","long","full"],n.defaultObject={dates:{calendars:{gregorian:{months:{"stand-alone":{abbreviated:{1:"Jan",2:"Feb",3:"Mar",4:"Apr",5:"May",6:"Jun",7:"Jul",8:"Aug",9:"Sep",10:"Oct",11:"Nov",12:"Dec"},narrow:{1:"J",2:"F",3:"M",4:"A",5:"M",6:"J",7:"J",8:"A",9:"S",10:"O",11:"N",12:"D"},wide:{1:"January",2:"February",3:"March",4:"April",5:"May",6:"June",7:"July",8:"August",9:"September",10:"October",11:"November",12:"December"}}},days:{"stand-alone":{abbreviated:{sun:"Sun",mon:"Mon",tue:"Tue",wed:"Wed",thu:"Thu",fri:"Fri",sat:"Sat"},narrow:{sun:"S",mon:"M",tue:"T",wed:"W",thu:"T",fri:"F",sat:"S"},short:{sun:"Su",mon:"Mo",tue:"Tu",wed:"We",thu:"Th",fri:"Fr",sat:"Sa"},wide:{sun:"Sunday",mon:"Monday",tue:"Tuesday",wed:"Wednesday",thu:"Thursday",fri:"Friday",sat:"Saturday"}}},dayPeriods:{format:{wide:{am:"AM",pm:"PM"}}},eras:{eraNames:{0:"Before Christ","0-alt-variant":"Before Common Era",1:"Anno Domini","1-alt-variant":"Common Era"},eraAbbr:{0:"BC","0-alt-variant":"BCE",1:"AD","1-alt-variant":"CE"},eraNarrow:{0:"B","0-alt-variant":"BCE",1:"A","1-alt-variant":"CE"}},dateFormats:{full:"EEEE, MMMM d, y",long:"MMMM d, y",medium:"MMM d, y",short:"M/d/yy"},timeFormats:{full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},dateTimeFormats:{full:"{1} 'at' {0}",long:"{1} 'at' {0}",medium:"{1}, {0}",short:"{1}, {0}",availableFormats:{d:"d",E:"ccc",Ed:"d E",Ehm:"E h:mm a",EHm:"E HH:mm",Ehms:"E h:mm:ss a",EHms:"E HH:mm:ss",Gy:"y G",GyMMM:"MMM y G",GyMMMd:"MMM d, y G",GyMMMEd:"E, MMM d, y G",h:"h a",H:"HH",hm:"h:mm a",Hm:"HH:mm",hms:"h:mm:ss a",Hms:"HH:mm:ss",hmsv:"h:mm:ss a v",Hmsv:"HH:mm:ss v",hmv:"h:mm a v",Hmv:"HH:mm v",M:"L",Md:"M/d",MEd:"E, M/d",MMM:"LLL",MMMd:"MMM d",MMMEd:"E, MMM d",MMMMd:"MMMM d",ms:"mm:ss",y:"y",yM:"M/y",yMd:"M/d/y",yMEd:"E, M/d/y",yMMM:"MMM y",yMMMd:"MMM d, y",yMMMEd:"E, MMM d, y",yMMMM:"MMMM y"}}},islamic:{months:{"stand-alone":{abbreviated:{1:"Muh.",2:"Saf.",3:"Rab. I",4:"Rab. II",5:"Jum. I",6:"Jum. II",7:"Raj.",8:"Sha.",9:"Ram.",10:"Shaw.",11:"Dhu\u02bbl-Q.",12:"Dhu\u02bbl-H."},narrow:{1:"1",2:"2",3:"3",4:"4",5:"5",6:"6",7:"7",8:"8",9:"9",10:"10",11:"11",12:"12"},wide:{1:"Muharram",2:"Safar",3:"Rabi\u02bb I",4:"Rabi\u02bb II",5:"Jumada I",6:"Jumada II",7:"Rajab",8:"Sha\u02bbban",9:"Ramadan",10:"Shawwal",11:"Dhu\u02bbl-Qi\u02bbdah",12:"Dhu\u02bbl-Hijjah"}}},days:{"stand-alone":{abbreviated:{sun:"Sun",mon:"Mon",tue:"Tue",wed:"Wed",thu:"Thu",fri:"Fri",sat:"Sat"},narrow:{sun:"S",mon:"M",tue:"T",wed:"W",thu:"T",fri:"F",sat:"S"},short:{sun:"Su",mon:"Mo",tue:"Tu",wed:"We",thu:"Th",fri:"Fr",sat:"Sa"},wide:{sun:"Sunday",mon:"Monday",tue:"Tuesday",wed:"Wednesday",thu:"Thursday",fri:"Friday",sat:"Saturday"}}},dayPeriods:{format:{wide:{am:"AM",pm:"PM"}}},eras:{eraNames:{0:"AH"},eraAbbr:{0:"AH"},eraNarrow:{0:"AH"}},dateFormats:{full:"EEEE, MMMM d, y G",long:"MMMM d, y G",medium:"MMM d, y G",short:"M/d/y GGGGG"},timeFormats:{full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},dateTimeFormats:{full:"{1} 'at' {0}",long:"{1} 'at' {0}",medium:"{1}, {0}",short:"{1}, {0}",availableFormats:{d:"d",E:"ccc",Ed:"d E",Ehm:"E h:mm a",EHm:"E HH:mm",Ehms:"E h:mm:ss a",EHms:"E HH:mm:ss",Gy:"y G",GyMMM:"MMM y G",GyMMMd:"MMM d, y G",GyMMMEd:"E, MMM d, y G",h:"h a",H:"HH",hm:"h:mm a",Hm:"HH:mm",hms:"h:mm:ss a",Hms:"HH:mm:ss",M:"L",Md:"M/d",MEd:"E, M/d",MMM:"LLL",MMMd:"MMM d",MMMEd:"E, MMM d",MMMMd:"MMMM d",ms:"mm:ss",y:"y G",yyyy:"y G",yyyyM:"M/y GGGGG",yyyyMd:"M/d/y GGGGG",yyyyMEd:"E, M/d/y GGGGG",yyyyMMM:"MMM y G",yyyyMMMd:"MMM d, y G",yyyyMMMEd:"E, MMM d, y G",yyyyMMMM:"MMMM y G",yyyyQQQ:"QQQ y G",yyyyQQQQ:"QQQQ y G"}}}},timeZoneNames:{hourFormat:"+HH:mm;-HH:mm",gmtFormat:"GMT{0}",gmtZeroFormat:"GMT"}},numbers:{currencies:{USD:{displayName:"US Dollar",symbol:"$","symbol-alt-narrow":"$"},EUR:{displayName:"Euro",symbol:"\u20ac","symbol-alt-narrow":"\u20ac"},GBP:{displayName:"British Pound","symbol-alt-narrow":"\xa3"}},defaultNumberingSystem:"latn",minimumGroupingDigits:"1","symbols-numberSystem-latn":{decimal:".",group:",",list:";",percentSign:"%",plusSign:"+",minusSign:"-",exponential:"E",superscriptingExponent:"\xd7",perMille:"\u2030",infinity:"\u221e",nan:"NaN",timeSeparator:":"},"decimalFormats-numberSystem-latn":{standard:"#,##0.###"},"percentFormats-numberSystem-latn":{standard:"#,##0%"},"currencyFormats-numberSystem-latn":{standard:"\xa4#,##0.00",accounting:"\xa4#,##0.00;(\xa4#,##0.00)"},"scientificFormats-numberSystem-latn":{standard:"#E0"}}},n.blazorDefaultObject={numbers:{mapper:{0:"0",1:"1",2:"2",3:"3",4:"4",5:"5",6:"6",7:"7",8:"8",9:"9"},mapperDigits:"0123456789",numberSymbols:{decimal:".",group:",",plusSign:"+",minusSign:"-",percentSign:"%",nan:"NaN",timeSeparator:":",infinity:"\u221e"},timeSeparator:":",currencySymbol:"$",currencypData:{nlead:"$",nend:"",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},percentpData:{nlead:"",nend:"%",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},percentnData:{nlead:"-",nend:"%",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},currencynData:{nlead:"($",nend:")",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},decimalnData:{nlead:"-",nend:"",groupData:{primary:3},maximumFraction:2,minimumFraction:2},decimalpData:{nlead:"",nend:"",groupData:{primary:3},maximumFraction:2,minimumFraction:2}},dates:{dayPeriods:{am:"AM",pm:"PM"},dateSeperator:"/",days:{abbreviated:{sun:"Sun",mon:"Mon",tue:"Tue",wed:"Wed",thu:"Thu",fri:"Fri",sat:"Sat"},short:{sun:"Su",mon:"Mo",tue:"Tu",wed:"We",thu:"Th",fri:"Fr",sat:"Sa"},wide:{sun:"Sunday",mon:"Monday",tue:"Tuesday",wed:"Wednesday",thu:"Thursday",fri:"Friday",sat:"Saturday"}},months:{abbreviated:{1:"Jan",2:"Feb",3:"Mar",4:"Apr",5:"May",6:"Jun",7:"Jul",8:"Aug",9:"Sep",10:"Oct",11:"Nov",12:"Dec"},wide:{1:"January",2:"February",3:"March",4:"April",5:"May",6:"June",7:"July",8:"August",9:"September",10:"October",11:"November",12:"December"}},eras:{1:"AD"}}},n.monthIndex={3:"abbreviated",4:"wide",5:"narrow",1:"abbreviated"},n.month="months",n.days="days",n.patternMatcher={C:"currency",P:"percent",N:"decimal",A:"currency",E:"scientific"},n.getResultantPattern=l,n.getDependables=h,n.getSymbolPattern=c,n.ConvertDateToWeekFormat=d,n.compareBlazorDateFormats=u,n.getProperNumericSkeleton=p,n.getFormatData=f,n.changeCurrencySymbol=g,n.getCurrencySymbol=v,n.customFormat=function y(T,P,_){for(var B={},j=T.split(";"),Q=["pData","nData","zeroData"],oe=0;oe1,pe.nData=ce()?Y(De.type+"nData",oe):f(ot[1]||"-"+ot[0],!0,Ie),pe.pData=ce()?Y(De.type+"pData",oe):f(ot[0],!1,Ie),!Me[2]&&!P.minimumFractionDigits&&!P.maximumFractionDigits&&(ue=f(Ve.split(";")[0],!0,"",!0).minimumFraction)}if(n.formatRegex.test(P.format)||!P.format){if(ze(Q,p(P.format||"N")),Q.custom=!1,$e="###0",(Q.fractionDigits||P.minimumFractionDigits||P.maximumFractionDigits||ue)&&(Q.fractionDigits&&(P.minimumFractionDigits=P.maximumFractionDigits=Q.fractionDigits),$e=A($e,ue||Q.fractionDigits||P.minimumFractionDigits||0,P.maximumFractionDigits||0)),P.minimumIntegerDigits&&($e=x($e,P.minimumIntegerDigits)),P.useGrouping&&($e=R($e)),"currency"===Q.type||Q.type&&ce()){ce()&&"currency"!==Q.type&&(pe.pData=Y(Q.type+"pData",oe),pe.nData=Y(Q.type+"nData",oe));var hr=$e;$e=pe.pData.nlead+hr+pe.pData.nend,(pe.hasNegativePattern||ce())&&($e+=";"+pe.nData.nlead+hr+pe.nData.nend)}"percent"===Q.type&&!ce()&&($e+=" %")}else $e=P.format.replace(/'/g,'"');return Object.keys(xe).length>0&&($e=B?$e:C($e,xe)),$e},n.fractionDigitsPattern=A,n.minimumIntegerPattern=x,n.groupingPattern=R,n.getWeekData=function L(T,P){var _="sun",B=Y("supplemental.weekData.firstDay",P),j=T;return/en-/.test(j)&&(j=j.slice(3)),j=j.slice(0,2).toUpperCase()+j.substr(2),B&&(_=B[""+j]||B[j.slice(0,2)]||"sun"),o[""+_]},n.replaceBlazorCurrency=function O(T,P,_){var B=function p$(n){return Y(n||"",u$)}(_);if(P!==B)for(var j=0,Q=T;j=0?_:_+7;var j=Math.floor((T.getTime()-P.getTime()-6e4*(T.getTimezoneOffset()-P.getTimezoneOffset()))/864e5)+1;if(_<4){if((B=Math.floor((j+_-1)/7)+1)>52){var oe=new Date(T.getFullYear()+1,0,1).getDay();B=(oe=oe>=0?oe:oe+7)<4?1:53}}else B=Math.floor((j+_-1)/7);return B}}(ut||(ut={}));var rp=function(){function n(t,e,i){this.type="GET",this.emitError=!0,"string"==typeof t?(this.url=t,this.type=m(e)?this.type:e.toUpperCase(),this.contentType=i):Aa(t)&&Object.keys(t).length>0&&Nn(this,t),this.contentType=m(this.contentType)?"application/json; charset=utf-8":this.contentType}return n.prototype.send=function(t){var e=this,i={"application/json":"json","multipart/form-data":"formData","application/octet-stream":"blob","application/x-www-form-urlencoded":"formData"};try{m(this.fetchRequest)&&"GET"===this.type?this.fetchRequest=new Request(this.url,{method:this.type}):m(this.fetchRequest)&&(this.data=m(t)?this.data:t,this.fetchRequest=new Request(this.url,{method:this.type,headers:{"Content-Type":this.contentType},body:this.data}));var r={cancel:!1,fetchRequest:this.fetchRequest};return this.triggerEvent(this.beforeSend,r),r.cancel?null:(this.fetchResponse=fetch(this.fetchRequest),this.fetchResponse.then(function(s){if(e.triggerEvent(e.onLoad,s),!s.ok)throw s;for(var o="text",a=0,l=Object.keys(i);a-1},n.getValue=function(t,e){var i=typeof window<"u"?window.browserDetails:{};return typeof navigator<"u"&&"MacIntel"===navigator.platform&&navigator.maxTouchPoints>1&&!0===n.isTouch&&!vC.CHROME.test(navigator.userAgent)&&(i.isIos=!0,i.isDevice=!0,i.isTouch=!0,i.isPointer=!0),typeof window<"u"&&window.Capacitor&&"ios"===window.Capacitor.getPlatform()&&(i.isPointer=!1),typeof i[""+t]>"u"?i[""+t]=e.test(n.userAgent):i[""+t]},Object.defineProperty(n,"userAgent",{get:function(){return n.uA},set:function(t){n.uA=t,window.browserDetails={}},enumerable:!0,configurable:!0}),Object.defineProperty(n,"info",{get:function(){return st(window.browserDetails.info)?window.browserDetails.info=n.extractBrowserDetail():window.browserDetails.info},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isIE",{get:function(){return n.getValue("isIE",A$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isTouch",{get:function(){return st(window.browserDetails.isTouch)?window.browserDetails.isTouch="ontouchstart"in window.navigator||window&&window.navigator&&window.navigator.maxTouchPoints>0||"ontouchstart"in window:window.browserDetails.isTouch},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isPointer",{get:function(){return st(window.browserDetails.isPointer)?window.browserDetails.isPointer="pointerEnabled"in window.navigator:window.browserDetails.isPointer},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isMSPointer",{get:function(){return st(window.browserDetails.isMSPointer)?window.browserDetails.isMSPointer="msPointerEnabled"in window.navigator:window.browserDetails.isMSPointer},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isDevice",{get:function(){return n.getValue("isDevice",T$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isIos",{get:function(){return n.getValue("isIos",N$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isIos7",{get:function(){return n.getValue("isIos7",O$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isAndroid",{get:function(){return n.getValue("isAndroid",k$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isWebView",{get:function(){return st(window.browserDetails.isWebView)&&(window.browserDetails.isWebView=!(st(window.cordova)&&st(window.PhoneGap)&&st(window.phonegap)&&"object"!==window.forge)),window.browserDetails.isWebView},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isWindows",{get:function(){return n.getValue("isWindows",P$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"touchStartEvent",{get:function(){return st(window.browserDetails.touchStartEvent)?window.browserDetails.touchStartEvent=n.getTouchStartEvent():window.browserDetails.touchStartEvent},enumerable:!0,configurable:!0}),Object.defineProperty(n,"touchMoveEvent",{get:function(){return st(window.browserDetails.touchMoveEvent)?window.browserDetails.touchMoveEvent=n.getTouchMoveEvent():window.browserDetails.touchMoveEvent},enumerable:!0,configurable:!0}),Object.defineProperty(n,"touchEndEvent",{get:function(){return st(window.browserDetails.touchEndEvent)?window.browserDetails.touchEndEvent=n.getTouchEndEvent():window.browserDetails.touchEndEvent},enumerable:!0,configurable:!0}),Object.defineProperty(n,"touchCancelEvent",{get:function(){return st(window.browserDetails.touchCancelEvent)?window.browserDetails.touchCancelEvent=n.getTouchCancelEvent():window.browserDetails.touchCancelEvent},enumerable:!0,configurable:!0}),n.uA=typeof navigator<"u"?navigator.userAgent:"",n}(),E=function(){function n(){}return n.addOrGetEventData=function(t){return"__eventList"in t?t.__eventList.events:(t.__eventList={},t.__eventList.events=[])},n.add=function(t,e,i,r,s){var a,o=n.addOrGetEventData(t);a=s?function l$(n,t){var e;return function(){for(var i=this,r=[],s=0;s"u"||(e.innerHTML=t.innerHTML?t.innerHTML:"",void 0!==t.className&&(e.className=t.className),void 0!==t.id&&(e.id=t.id),void 0!==t.styles&&e.setAttribute("style",t.styles),void 0!==t.attrs&&Fe(e,t.attrs)),e}function V(n,t){for(var e=Vz(t),i=RegExp,r=0,s=n;r0}function pl(n,t,e){for(var i=document.createDocumentFragment(),r=0,s=n;r0;)i.appendChild(n[0]);else for(var r=0,s=n;r-1&&!r[parseInt(s.toString(),10)].match(/\[.*\]/)){var o=r[parseInt(s.toString(),10)].split("#");if(o[1].match(/^\d/)||o[1].match(t)){var a=r[parseInt(s.toString(),10)].split(".");a[0]=a[0].replace(/#/,"[id='")+"']",r[parseInt(s.toString(),10)]=a.join(".")}}e[parseInt(i.toString(),10)]=r.join(" ")}return e.join(",")}return n}function J(n,t){var e=n;if("function"==typeof e.closest)return e.closest(t);for(;e&&1===e.nodeType;){if(mC(e,t))return e;e=e.parentNode}return null}function je(n,t){void 0!==t&&Object.keys(t).forEach(function(e){n.style[""+e]=t[""+e]})}function mC(n,t){var e=n.matches||n.msMatchesSelector||n.webkitMatchesSelector;return e?e.call(n,t):-1!==[].indexOf.call(document.querySelectorAll(t),n)}var H$=new RegExp("]"),ah=function(){function n(t,e){this.isRendered=!1,this.isComplexArraySetter=!1,this.isServerRendered=!1,this.allowServerDataBinding=!0,this.isProtectedOnChange=!0,this.properties={},this.changedProperties={},this.oldProperties={},this.bulkChanges={},this.refreshing=!1,this.ignoreCollectionWatch=!1,this.finalUpdate=function(){},this.childChangedProperties={},this.modelObserver=new Tg(this),st(e)||(this.element="string"==typeof e?document.querySelector(e):e,m(this.element)||(this.isProtectedOnChange=!1,this.addInstance())),st(t)||this.setProperties(t,!0),this.isDestroyed=!1}return n.prototype.setProperties=function(t,e){var i=this.isProtectedOnChange;this.isProtectedOnChange=!!e,Nn(this,t),!0!==e?(Nn(this.changedProperties,t),this.dataBind()):ce()&&this.isRendered&&this.serverDataBind(t),this.finalUpdate(),this.changedProperties={},this.oldProperties={},this.isProtectedOnChange=i},n.callChildDataBind=function(t,e){for(var r=0,s=Object.keys(t);r=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Hs=function(n){function t(i){var r=n.call(this,i,void 0)||this;return r.easing={ease:"cubic-bezier(0.250, 0.100, 0.250, 1.000)",linear:"cubic-bezier(0.250, 0.250, 0.750, 0.750)",easeIn:"cubic-bezier(0.420, 0.000, 1.000, 1.000)",easeOut:"cubic-bezier(0.000, 0.000, 0.580, 1.000)",easeInOut:"cubic-bezier(0.420, 0.000, 0.580, 1.000)",elasticInOut:"cubic-bezier(0.5,-0.58,0.38,1.81)",elasticIn:"cubic-bezier(0.17,0.67,0.59,1.81)",elasticOut:"cubic-bezier(0.7,-0.75,0.99,1.01)"},r}var e;return X$(t,n),e=t,t.prototype.animate=function(i,r){var s=this.getModel(r=r||{});if("string"==typeof i)for(var a=0,l=Array.prototype.slice.call(we(i,document));a0?r-1:0,i+=e=-1!==e?"-"+e:"-"+r}return this.controlParent!==this.parentObj&&(i=this.parentObj.getParentKey()+"."+this.propName+e),i},n}(),J$=["grid","pivotview","treegrid","spreadsheet","rangeNavigator","DocumentEditor","listbox","inplaceeditor","PdfViewer","richtexteditor","DashboardLayout","chart","stockChart","circulargauge","diagram","heatmap","lineargauge","maps","slider","smithchart","barcode","sparkline","treemap","bulletChart","kanban","daterangepicker","schedule","gantt","signature","query-builder","drop-down-tree","carousel","filemanager","uploader","accordion","tab","treeview"],tR=[115,121,110,99,102,117,115,105,111,110,46,105,115,76,105,99,86,97,108,105,100,97,116,101,100],iR=function(){function n(t){this.isValidated=!1,this.isLicensed=!0,this.version="27",this.platform=/JavaScript|ASPNET|ASPNETCORE|ASPNETMVC|FileFormats|essentialstudio/i,this.errors={noLicense:"This application was built using a trial version of Syncfusion Essential Studio. To remove the license validation message permanently, a valid license key must be included.",trailExpired:"This application was built using a trial version of Syncfusion Essential Studio. To remove the license validation message permanently, a valid license key must be included.",versionMismatched:"The included Syncfusion license key is invalid.",platformMismatched:"The included Syncfusion license key is invalid.",invalidKey:"The included Syncfusion license key is invalid."},this.manager=function(){var e=null;return{setKey:function i(s){e=s},getKey:function r(){return e}}}(),this.npxManager=function(){return{getKey:function i(){return"npxKeyReplace"}}}(),this.manager.setKey(t)}return n.prototype.validate=function(){if(!this.isValidated&&tp&&!Y(T0(tR),tp)&&!Y("Blazor",tp)){var i=void 0,r=void 0;if(this.manager&&this.manager.getKey()||this.npxManager&&"npxKeyReplace"!==this.npxManager.getKey()){var s=this.getInfoFromKey();if(s&&s.length)for(var o=0,a=s;o"+i+' Claim your FREE account\n
have a Syncfusion account? Sign In
\n
\n ';if(typeof document<"u"&&!m(document)){var t=mi("div",{innerHTML:n});document.body.appendChild(t)}}(),oR=!0),this.render(),this.mount?this.accessMount():this.trigger("created")}},t.prototype.renderComplete=function(e){ce()&&window.sfBlazor.renderComplete(this.element,e),this.isRendered=!0},t.prototype.dataBind=function(){this.injectModules(),n.prototype.dataBind.call(this)},t.prototype.on=function(e,i,r){if("string"==typeof e)this.localObserver.on(e,i,r);else for(var s=0,o=e;s=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},rZ={left:0,top:0,bottom:0,right:0},MC={isDragged:!1},nZ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return aR(t,n),gr([I(0)],t.prototype,"left",void 0),gr([I(0)],t.prototype,"top",void 0),t}(Ee),op=function(n){function t(i,r){var s=n.call(this,r,i)||this;return s.dragLimit=e.getDefaultPosition(),s.borderWidth=e.getDefaultPosition(),s.padding=e.getDefaultPosition(),s.diffX=0,s.prevLeft=0,s.prevTop=0,s.dragProcessStarted=!1,s.eleTop=0,s.tapHoldTimer=0,s.externalInitialize=!1,s.diffY=0,s.parentScrollX=0,s.parentScrollY=0,s.droppables={},s.bind(),s}var e;return aR(t,n),e=t,t.prototype.bind=function(){this.toggleEvents(),X.isIE&&V([this.element],"e-block-touch"),this.droppables[this.scope]={}},t.getDefaultPosition=function(){return ze({},rZ)},t.prototype.toggleEvents=function(i){var r;st(this.handle)||(r=U(this.handle,this.element));var s=this.enableTapHold&&X.isDevice&&X.isTouch?this.mobileInitialize:this.initialize;i?E.remove(r||this.element,X.isSafari()?"touchstart":X.touchStartEvent,s):E.add(r||this.element,X.isSafari()?"touchstart":X.touchStartEvent,s,this)},t.prototype.mobileInitialize=function(i){var r=this,s=i.currentTarget;this.tapHoldTimer=setTimeout(function(){r.externalInitialize=!0,r.removeTapholdTimer(),r.initialize(i,s)},this.tapHoldThreshold),E.add(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.removeTapholdTimer,this),E.add(document,X.isSafari()?"touchend":X.touchEndEvent,this.removeTapholdTimer,this)},t.prototype.removeTapholdTimer=function(){clearTimeout(this.tapHoldTimer),E.remove(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.removeTapholdTimer),E.remove(document,X.isSafari()?"touchend":X.touchEndEvent,this.removeTapholdTimer)},t.prototype.getScrollableParent=function(i,r){return m(i)?null:i[{vertical:"scrollHeight",horizontal:"scrollWidth"}[""+r]]>i[{vertical:"clientHeight",horizontal:"clientWidth"}[""+r]]&&("vertical"===r?i.scrollTop>0:i.scrollLeft>0)?("vertical"===r?(this.parentScrollY=this.parentScrollY+(0===this.parentScrollY?i.scrollTop:i.scrollTop-this.parentScrollY),this.tempScrollHeight=i.scrollHeight):(this.parentScrollX=this.parentScrollX+(0===this.parentScrollX?i.scrollLeft:i.scrollLeft-this.parentScrollX),this.tempScrollWidth=i.scrollWidth),m(i)?i:this.getScrollableParent(i.parentNode,r)):this.getScrollableParent(i.parentNode,r)},t.prototype.getScrollableValues=function(){this.parentScrollX=0,this.parentScrollY=0,this.element.classList.contains("e-dialog")&&this.element.classList.contains("e-dlg-modal"),this.getScrollableParent(this.element.parentNode,"vertical"),this.getScrollableParent(this.element.parentNode,"horizontal")},t.prototype.initialize=function(i,r){if(this.currentStateTarget=i.target,!this.isDragStarted()){if(this.isDragStarted(!0),this.externalInitialize=!1,this.target=i.currentTarget||r,this.dragProcessStarted=!1,this.abort){var s=this.abort;"string"==typeof s&&(s=[s]);for(var o=0;o=this.distance||this.externalInitialize){var p=this.getHelperElement(i);if(!p||m(p))return;r&&i.preventDefault();var f=this.helperElement=p;if(this.parentClientRect=this.calculateParentPosition(f.offsetParent),this.dragStart){var v={event:i,element:l,target:this.getProperTargetElement(i),bindEvents:ce()?this.bindDragEvents.bind(this):null,dragElement:f};this.trigger("dragStart",v)}this.dragArea?this.setDragArea():(this.dragLimit={left:0,right:0,bottom:0,top:0},this.borderWidth={top:0,left:0}),o={left:this.position.left-this.parentClientRect.left,top:this.position.top-this.parentClientRect.top},this.clone&&!this.enableTailMode&&(this.diffX=this.position.left-this.offset.left,this.diffY=this.position.top-this.offset.top),this.getScrollableValues();var y=getComputedStyle(l),S=parseFloat(y.marginTop);this.clone&&0!==S&&(o.top+=S),this.eleTop=isNaN(parseFloat(y.top))?0:parseFloat(y.top)-this.offset.top,this.enableScrollHandler&&!this.clone&&(o.top-=this.parentScrollY,o.left-=this.parentScrollX);var b=this.getProcessedPositionValue({top:o.top-this.diffY+"px",left:o.left-this.diffX+"px"});this.dragArea&&"string"!=typeof this.dragArea&&this.dragArea.classList.contains("e-kanban-content")&&"relative"===this.dragArea.style.position&&(o.top+=this.dragArea.scrollTop),this.dragElePosition={top:o.top,left:o.left},je(f,this.getDragPosition({position:"absolute",left:b.left,top:b.top})),E.remove(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.intDragStart),E.remove(document,X.isSafari()?"touchend":X.touchEndEvent,this.intDestroy),ce()||this.bindDragEvents(f)}}},t.prototype.bindDragEvents=function(i){Tr(i)?(E.add(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.intDrag,this),E.add(document,X.isSafari()?"touchend":X.touchEndEvent,this.intDragStop,this),this.setGlobalDroppables(!1,this.element,i)):(this.toggleEvents(),document.body.classList.remove("e-prevent-select"))},t.prototype.elementInViewport=function(i){for(this.top=i.offsetTop,this.left=i.offsetLeft,this.width=i.offsetWidth,this.height=i.offsetHeight;i.offsetParent;)this.top+=(i=i.offsetParent).offsetTop,this.left+=i.offsetLeft;return this.top>=window.pageYOffset&&this.left>=window.pageXOffset&&this.top+this.height<=window.pageYOffset+window.innerHeight&&this.left+this.width<=window.pageXOffset+window.innerWidth},t.prototype.getProcessedPositionValue=function(i){return this.queryPositionInfo?this.queryPositionInfo(i):i},t.prototype.calculateParentPosition=function(i){if(m(i))return{left:0,top:0};var r=i.getBoundingClientRect(),s=getComputedStyle(i);return{left:r.left+window.pageXOffset-parseInt(s.marginLeft,10),top:r.top+window.pageYOffset-parseInt(s.marginTop,10)}},t.prototype.intDrag=function(i){if(st(i.changedTouches)||1===i.changedTouches.length){var r,s;this.clone&&i.changedTouches&&X.isDevice&&X.isTouch&&i.preventDefault(),this.position=this.getMousePosition(i,this.isDragScroll);var o=this.getDocumentWidthHeight("Height");oy&&y>0?this.dragLimit.left:this.dragLimit.right+window.pageXOffset0?y-(y-this.dragLimit.right)+window.pageXOffset-M:y<0?this.dragLimit.left:y}if(this.pageY!==v||this.skipDistanceCheck){var w=d.offsetHeight+(parseFloat(b.marginTop)+parseFloat(b.marginBottom));s=this.dragLimit.top>S&&S>0?this.dragLimit.top:this.dragLimit.bottom+window.pageYOffset0?S-(S-this.dragLimit.bottom)+window.pageYOffset-w:S<0?this.dragLimit.top:S}}else r=y,s=S;var A,x,C=p+this.borderWidth.top,D=u+this.borderWidth.left;if(this.dragProcessStarted&&(m(s)&&(s=this.prevTop),m(r)&&(r=this.prevLeft)),this.helperElement.classList.contains("e-treeview"))this.dragArea?(this.dragLimit.top=this.clone?this.dragLimit.top:0,A=s-C<0?this.dragLimit.top:s-this.borderWidth.top,x=r-D<0?this.dragLimit.left:r-this.borderWidth.left):(A=s-this.borderWidth.top,x=r-this.borderWidth.left);else if(this.dragArea){var R=this.helperElement.classList.contains("e-dialog");this.dragLimit.top=this.clone?this.dragLimit.top:0,A=s-C<0?this.dragLimit.top:s-C,x=r-D<0?R?r-(D-this.borderWidth.left):this.dragElePosition.left:r-D}else A=s-C,x=r-D;var L=parseFloat(getComputedStyle(this.element).marginTop);if(L>0&&(this.clone&&(A+=L,S<0&&(L+S>=0?A=L+S:A-=L),this.dragArea&&(A=this.dragLimit.bottom=0){var O=this.dragLimit.top+S-C;O+L+C<0?A-=L+C:A=O}else A-=L+C;this.dragArea&&this.helperElement.classList.contains("e-treeview")&&(A=A+(w=d.offsetHeight+(parseFloat(b.marginTop)+parseFloat(b.marginBottom)))>this.dragLimit.bottom?this.dragLimit.bottom-w:A),this.enableScrollHandler&&!this.clone&&(A-=this.parentScrollY,x-=this.parentScrollX),this.dragArea&&"string"!=typeof this.dragArea&&this.dragArea.classList.contains("e-kanban-content")&&"relative"===this.dragArea.style.position&&(A+=this.dragArea.scrollTop);var N=this.getProcessedPositionValue({top:A+"px",left:x+"px"});this.isPreventScroll&&(N=this.getProcessedPositionValue({top:this.position.top-this.parentClientRect.top-2+"px",left:this.position.left-this.parentClientRect.left-2+"px"})),je(d,this.getDragPosition(N)),!this.elementInViewport(d)&&this.enableAutoScroll&&!this.helperElement.classList.contains("e-treeview")&&this.helperElement.scrollIntoView();var T=document.querySelectorAll(":hover");if(this.enableAutoScroll&&this.helperElement.classList.contains("e-treeview")){0===T.length&&(T=this.getPathElements(i));var P=this.getScrollParent(T,!1);this.elementInViewport(this.helperElement)?this.getScrollPosition(P,A):this.elementInViewport(this.helperElement)||(0===(T=[].slice.call(document.querySelectorAll(":hover"))).length&&(T=this.getPathElements(i)),P=this.getScrollParent(T,!0),this.getScrollPosition(P,A))}this.dragProcessStarted=!0,this.prevLeft=r,this.prevTop=s,this.position.left=r,this.position.top=s,this.pageX=g,this.pageY=v}},t.prototype.getScrollParent=function(i,r){for(var o,s=r?i.reverse():i,a=s.length-1;a>=0;a--)if(("auto"===(o=window.getComputedStyle(s[parseInt(a.toString(),10)])["overflow-y"])||"scroll"===o)&&s[parseInt(a.toString(),10)].scrollHeight>s[parseInt(a.toString(),10)].clientHeight)return s[parseInt(a.toString(),10)];if("visible"===(o=window.getComputedStyle(document.scrollingElement)["overflow-y"]))return document.scrollingElement.style.overflow="auto",document.scrollingElement},t.prototype.getScrollPosition=function(i,r){if(i&&i===document.scrollingElement)i.clientHeight+document.scrollingElement.scrollTop-this.helperElement.clientHeightr?i.scrollTop+=this.helperElement.clientHeight:i.scrollTop>r-this.helperElement.clientHeight&&(i.scrollTop-=this.helperElement.clientHeight);else if(i&&i!==document.scrollingElement){var s=document.scrollingElement.scrollTop,o=this.helperElement.clientHeight;i.clientHeight+i.getBoundingClientRect().top-o+sr-o-s&&(i.scrollTop-=this.helperElement.clientHeight)}},t.prototype.getPathElements=function(i){return document.elementsFromPoint(i.clientX>0?i.clientX:0,i.clientY>0?i.clientY:0)},t.prototype.triggerOutFunction=function(i,r){this.hoverObject.instance.intOut(i,r.target),this.hoverObject.instance.dragData[this.scope]=null,this.hoverObject=null},t.prototype.getDragPosition=function(i){var r=ze({},i);return this.axis&&("x"===this.axis?delete r.top:"y"===this.axis&&delete r.left),r},t.prototype.getDocumentWidthHeight=function(i){var r=document.body,s=document.documentElement;return Math.max(r["scroll"+i],s["scroll"+i],r["offset"+i],s["offset"+i],s["client"+i])},t.prototype.intDragStop=function(i){if(this.dragProcessStarted=!1,st(i.changedTouches)||1===i.changedTouches.length){if(-1!==["touchend","pointerup","mouseup"].indexOf(i.type)){if(this.dragStop){var s=this.getProperTargetElement(i);this.trigger("dragStop",{event:i,element:this.element,target:s,helper:this.helperElement})}this.intDestroy(i)}else this.element.setAttribute("aria-grabbed","false");var o=this.checkTargetElement(i);o.target&&o.instance&&(o.instance.dragStopCalled=!0,o.instance.dragData[this.scope]=this.droppables[this.scope],o.instance.intDrop(i,o.target)),this.setGlobalDroppables(!0),document.body.classList.remove("e-prevent-select")}},t.prototype.intDestroy=function(i){this.dragProcessStarted=!1,this.toggleEvents(),document.body.classList.remove("e-prevent-select"),this.element.setAttribute("aria-grabbed","false"),E.remove(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.intDragStart),E.remove(document,X.isSafari()?"touchend":X.touchEndEvent,this.intDragStop),E.remove(document,X.isSafari()?"touchend":X.touchEndEvent,this.intDestroy),E.remove(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.intDrag),this.isDragStarted()&&this.isDragStarted(!0)},t.prototype.onPropertyChanged=function(i,r){},t.prototype.getModuleName=function(){return"draggable"},t.prototype.isDragStarted=function(i){return i&&(MC.isDragged=!MC.isDragged),MC.isDragged},t.prototype.setDragArea=function(){var i,r,a,s=0,o=0;if(a="string"==typeof this.dragArea?U(this.dragArea):this.dragArea){var h=a.getBoundingClientRect();i=a.scrollWidth?a.scrollWidth:h.right-h.left,r=a.scrollHeight?this.dragArea&&!m(this.helperElement)&&this.helperElement.classList.contains("e-treeview")?a.clientHeight:a.scrollHeight:h.bottom-h.top;for(var c=["Top","Left","Bottom","Right"],d=getComputedStyle(a),u=0;u12;return C0(i.target,this.helperElement)||-1!==i.type.indexOf("touch")||a?(this.helperElement.style.pointerEvents="none",s=document.elementFromPoint(r.clientX,r.clientY),this.helperElement.style.pointerEvents=o):s=i.target,s},t.prototype.currentStateCheck=function(i,r){return m(this.currentStateTarget)||this.currentStateTarget===i?m(r)?i:r:this.currentStateTarget},t.prototype.getMousePosition=function(i,r){var a,l,s=void 0!==i.srcElement?i.srcElement:i.target,o=this.getCoordinates(i),h=m(s.offsetParent);if(r?(a=this.clone?o.pageX:o.pageX+(h?0:s.offsetParent.scrollLeft)-this.relativeXPosition,l=this.clone?o.pageY:o.pageY+(h?0:s.offsetParent.scrollTop)-this.relativeYPosition):(a=this.clone?o.pageX:o.pageX+window.pageXOffset-this.relativeXPosition,l=this.clone?o.pageY:o.pageY+window.pageYOffset-this.relativeYPosition),document.scrollingElement&&!r&&!this.clone){var c=document.scrollingElement;a=c.scrollWidth>0&&c.scrollWidth>c.clientWidth&&c.scrollLeft>0?a-c.scrollLeft:a,l=c.scrollHeight>0&&c.scrollHeight>c.clientHeight&&c.scrollTop>0?l-c.scrollTop:l}return{left:a-(this.margin.left+this.cursorAt.left),top:l-(this.margin.top+this.cursorAt.top)}},t.prototype.getCoordinates=function(i){return i.type.indexOf("touch")>-1?i.changedTouches[0]:i},t.prototype.getHelperElement=function(i){var r;return this.clone?this.helper?r=this.helper({sender:i,element:this.target}):(r=mi("div",{className:"e-drag-helper e-block-touch",innerHTML:"Draggable"}),document.body.appendChild(r)):r=this.element,r},t.prototype.setGlobalDroppables=function(i,r,s){this.droppables[this.scope]=i?null:{draggable:r,helper:s,draggedElement:this.element}},t.prototype.checkTargetElement=function(i){var r=this.getProperTargetElement(i),s=this.getDropInstance(r);if(!s&&r&&!m(r.parentNode)){var o=J(r.parentNode,".e-droppable")||r.parentElement;o&&(s=this.getDropInstance(o))}return{target:r,instance:s}},t.prototype.getDropInstance=function(i){var s,o=i&&i.ej2_instances;if(o)for(var a=0,l=o;a=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},lR=function(n){function t(e,i){var r=n.call(this,i,e)||this;return r.mouseOver=!1,r.dragData={},r.dragStopCalled=!1,r.bind(),r}return sZ(t,n),t.prototype.bind=function(){this.wireEvents()},t.prototype.wireEvents=function(){E.add(this.element,X.isSafari()?"touchend":X.touchEndEvent,this.intDrop,this)},t.prototype.onPropertyChanged=function(e,i){},t.prototype.getModuleName=function(){return"droppable"},t.prototype.intOver=function(e,i){this.mouseOver||(this.trigger("over",{event:e,target:i,dragData:this.dragData[this.scope]}),this.mouseOver=!0)},t.prototype.intOut=function(e,i){this.mouseOver&&(this.trigger("out",{evt:e,target:i}),this.mouseOver=!1)},t.prototype.intDrop=function(e,i){if(this.dragStopCalled){this.dragStopCalled=!1;var a,r=!0,s=this.dragData[this.scope],o=!!s&&s.helper&&Tr(s.helper);o&&(a=this.isDropArea(e,s.helper,i),this.accept&&(r=mC(s.helper,this.accept))),o&&this.drop&&a.canDrop&&r&&this.trigger("drop",{event:e,target:a.target,droppedElement:s.helper,dragData:s}),this.mouseOver=!1}},t.prototype.isDropArea=function(e,i,r){var s={canDrop:!0,target:r||e.target},o="touchend"===e.type;if(o||s.target===i){i.style.display="none";var a=o?e.changedTouches[0]:e,l=document.elementFromPoint(a.clientX,a.clientY);s.canDrop=!1,s.canDrop=C0(l,this.element),s.canDrop&&(s.target=l),i.style.display=""}return s},t.prototype.destroy=function(){E.remove(this.element,X.isSafari()?"touchend":X.touchEndEvent,this.intDrop),n.prototype.destroy.call(this)},ap([I()],t.prototype,"accept",void 0),ap([I("default")],t.prototype,"scope",void 0),ap([H()],t.prototype,"drop",void 0),ap([H()],t.prototype,"over",void 0),ap([H()],t.prototype,"out",void 0),ap([Ft],t)}(ah),ho=function(){function n(t,e,i){this.controlName=t,this.localeStrings=e,this.setLocale(i||"en-US")}return n.prototype.setLocale=function(t){var e=this.intGetControlConstant(n.locale,t);this.currentLocale=e||this.localeStrings},n.load=function(t){this.locale=ze(this.locale,t,{},!0)},n.prototype.getConstant=function(t){return m(this.currentLocale[""+t])?this.localeStrings[""+t]||"":this.currentLocale[""+t]},n.prototype.intGetControlConstant=function(t,e){return t[""+e]?t[""+e][this.controlName]:null},n.locale={},n}(),hR=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),hh=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},lZ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return hR(t,n),hh([I(50)],t.prototype,"swipeThresholdDistance",void 0),t}(Ee),hZ=/(Up|Down)/,Fs=function(n){function t(e,i){var r=n.call(this,i,e)||this;return r.touchAction=!0,r.tapCount=0,r.startEvent=function(s){if(!0===r.touchAction){var o=r.updateChangeTouches(s);void 0!==s.changedTouches&&(r.touchAction=!1),r.isTouchMoved=!1,r.movedDirection="",r.startPoint=r.lastMovedPoint={clientX:o.clientX,clientY:o.clientY},r.startEventData=o,r.hScrollLocked=r.vScrollLocked=!1,r.tStampStart=Date.now(),r.timeOutTapHold=setTimeout(function(){r.tapHoldEvent(s)},r.tapHoldThreshold),E.add(r.element,X.touchMoveEvent,r.moveEvent,r),E.add(r.element,X.touchEndEvent,r.endEvent,r),E.add(r.element,X.touchCancelEvent,r.cancelEvent,r)}},r.moveEvent=function(s){var o=r.updateChangeTouches(s);r.movedPoint=o,r.isTouchMoved=!(o.clientX===r.startPoint.clientX&&o.clientY===r.startPoint.clientY);var a={};r.isTouchMoved&&(clearTimeout(r.timeOutTapHold),r.calcScrollPoints(s),a=ze(a,{},{startEvents:r.startEventData,originalEvent:s,startX:r.startPoint.clientX,startY:r.startPoint.clientY,distanceX:r.distanceX,distanceY:r.distanceY,scrollDirection:r.scrollDirection,velocity:r.getVelocity(o)}),r.trigger("scroll",a),r.lastMovedPoint={clientX:o.clientX,clientY:o.clientY})},r.cancelEvent=function(s){clearTimeout(r.timeOutTapHold),clearTimeout(r.timeOutTap),r.tapCount=0,r.swipeFn(s),E.remove(r.element,X.touchCancelEvent,r.cancelEvent)},r.endEvent=function(s){r.swipeFn(s),r.isTouchMoved||"function"==typeof r.tap&&(r.trigger("tap",{originalEvent:s,tapCount:++r.tapCount}),r.timeOutTap=setTimeout(function(){r.tapCount=0},r.tapThreshold)),r.modeclear()},r.swipeFn=function(s){clearTimeout(r.timeOutTapHold),clearTimeout(r.timeOutTap);var o=r.updateChangeTouches(s),a=o.clientX-r.startPoint.clientX,l=o.clientY-r.startPoint.clientY;a=Math.floor(a<0?-1*a:a),l=Math.floor(l<0?-1*l:a),r.isTouchMoved=a>1||l>1,/Firefox/.test(X.userAgent)&&0===o.clientX&&0===o.clientY&&"mouseup"===s.type&&(r.isTouchMoved=!1),r.endPoint=o,r.calcPoints(s);var c={originalEvent:s,startEvents:r.startEventData,startX:r.startPoint.clientX,startY:r.startPoint.clientY,distanceX:r.distanceX,distanceY:r.distanceY,swipeDirection:r.movedDirection,velocity:r.getVelocity(o)};if(r.isTouchMoved){var d=r.swipeSettings.swipeThresholdDistance,u=ze(void 0,r.defaultArgs,c),p=!1,f=r.element,g=r.isScrollable(f),v=hZ.test(r.movedDirection);(dthis.distanceY?i.clientX>this.startPoint.clientX?"Right":"Left":i.clientYthis.distanceY||!0===this.hScrollLocked)&&!1===this.vScrollLocked?(this.scrollDirection=i.clientX>this.lastMovedPoint.clientX?"Right":"Left",this.hScrollLocked=!0):(this.scrollDirection=i.clientY=e[r[0]+s[0]]},t.prototype.updateChangeTouches=function(e){return e.changedTouches&&0!==e.changedTouches.length?e.changedTouches[0]:e},hh([H()],t.prototype,"tap",void 0),hh([H()],t.prototype,"tapHold",void 0),hh([H()],t.prototype,"swipe",void 0),hh([H()],t.prototype,"scroll",void 0),hh([I(350)],t.prototype,"tapThreshold",void 0),hh([I(750)],t.prototype,"tapHoldThreshold",void 0),hh([re({},lZ)],t.prototype,"swipeSettings",void 0),hh([Ft],t)}(ah),cZ=new RegExp("\\n|\\r|\\s\\s+","g"),dZ=new RegExp(/'|"/g),uZ=new RegExp("if ?\\("),pZ=new RegExp("else if ?\\("),cR=new RegExp("else"),fZ=new RegExp("for ?\\("),dR=new RegExp("(/if|/for)"),gZ=new RegExp("\\((.*)\\)",""),wC=new RegExp("^[0-9]+$","g"),vZ=new RegExp("[\\w\"'.\\s+]+","g"),mZ=new RegExp('"(.*?)"',"g"),yZ=new RegExp("[\\w\"'@#$.\\s-+]+","g"),uR=new RegExp("\\${([^}]*)}","g"),SZ=/^\..*/gm,CC=/\\/gi,IZ=/\\\\/gi,bZ=new RegExp("[\\w\"'@#$.\\s+]+","g"),MZ=/\window\./gm;function lp(n,t,e,i,r){return!t||wC.test(n)||-1!==i.indexOf(n.split(".")[0])||r||"true"===n||"false"===n?n:e+"."+n}function EC(n,t,e,i){return t&&!wC.test(n)&&-1===i.indexOf(n.split(".")[0])?e+'["'+n:n}function pR(n){return n.match(IZ)?n:n.replace(CC,"\\\\")}function fR(n,t,e,i){if(n=n.trim(),/\window\./gm.test(n))return n;var s=/'|"/gm;return/@|\$|#/gm.test(n)&&(n=EC(n,-1===e.indexOf(n),t,e)+'"]'),SZ.test(n)?function EZ(n,t,e,i){return!t||wC.test(n)||-1!==i.indexOf(n.split(".")[0])||/^\..*/gm.test(n)?n:e+"."+n}(n,!s.test(n)&&-1===e.indexOf(n),t,e):lp(n,!s.test(n)&&-1===e.indexOf(n),t,e,i)}var DZ=/^[\n\r.]+0&&t.forEach(function(e){he(e)})},n.removeJsEvents=function(){var t=this.wrapElement.querySelectorAll("["+vR.join("],[")+"]");t.length>0&&t.forEach(function(e){vR.forEach(function(i){e.hasAttribute(i)&&e.removeAttribute(i)})})},n.removeXssAttrs=function(){var t=this;this.removeAttrs.forEach(function(e,i){var r=t.wrapElement.querySelectorAll(e.selector);r.length>0&&r.forEach("a[href]"===e.selector?function(s){-1!==s.getAttribute(e.attribute).replace(/\t|\s|&/,"").indexOf("javascript:alert")&&s.removeAttribute(e.attribute)}:function(s){s.removeAttribute(e.attribute)})})},n}();function kZ(n){for(var t,e=n.childNodes,i=0;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Jo_RTL=(new Tg,"e-rtl"),ys=function(n){function t(e,i){return n.call(this,e,i)||this}return RZ(t,n),t.prototype.preRender=function(){},t.prototype.render=function(){this.initialize(),this.removeRippleEffect=function ms(n,t,e){var i=function q$(n){return{selector:n&&n.selector?n.selector:null,ignore:n&&n.ignore?n.ignore:null,rippleFlag:n&&n.rippleFlag,isCenterRipple:n&&n.isCenterRipple,duration:n&&n.duration?n.duration:350}}(t);return!1===i.rippleFlag||void 0===i.rippleFlag&&!Zo?function(){}:(n.setAttribute("data-ripple","true"),E.add(n,"mousedown",Zz,{parent:n,rippleOptions:i}),E.add(n,"mouseup",Jz,{parent:n,rippleOptions:i,done:e}),E.add(n,"mouseleave",sp,{parent:n,rippleOptions:i}),X.isPointer&&E.add(n,"transitionend",sp,{parent:n,rippleOptions:i}),function(){n.removeAttribute("data-ripple"),E.remove(n,"mousedown",Zz),E.remove(n,"mouseup",Jz),E.remove(n,"mouseleave",sp),E.remove(n,"transitionend",sp)})}(this.element,{selector:".e-btn"}),this.renderComplete()},t.prototype.initialize=function(){if(this.cssClass&&V([this.element],this.cssClass.replace(/\s+/g," ").trim().split(" ")),this.isPrimary&&this.element.classList.add("e-primary"),!ce()||ce()&&"progress-btn"!==this.getModuleName()){if(this.content){var e=this.enableHtmlSanitizer?Ti.sanitize(this.content):this.content;this.element.innerHTML=e}this.setIconCss()}this.enableRtl&&this.element.classList.add(Jo_RTL),this.disabled?this.controlStatus(this.disabled):this.wireEvents()},t.prototype.controlStatus=function(e){this.element.disabled=e},t.prototype.setIconCss=function(){if(this.iconCss){var e=this.createElement("span",{className:"e-btn-icon "+this.iconCss});this.element.textContent.trim()?(e.classList.add("e-icon-"+this.iconPosition.toLowerCase()),("Top"===this.iconPosition||"Bottom"===this.iconPosition)&&this.element.classList.add("e-"+this.iconPosition.toLowerCase()+"-icon-btn")):this.element.classList.add("e-icon-btn");var i=this.element.childNodes[0];!i||"Left"!==this.iconPosition&&"Top"!==this.iconPosition?this.element.appendChild(e):this.element.insertBefore(e,i)}},t.prototype.wireEvents=function(){this.isToggle&&E.add(this.element,"click",this.btnClickHandler,this)},t.prototype.unWireEvents=function(){this.isToggle&&E.remove(this.element,"click",this.btnClickHandler)},t.prototype.btnClickHandler=function(){this.element.classList.contains("e-active")?this.element.classList.remove("e-active"):this.element.classList.add("e-active")},t.prototype.destroy=function(){var e=["e-primary",Jo_RTL,"e-icon-btn","e-success","e-info","e-danger","e-warning","e-flat","e-outline","e-small","e-bigger","e-active","e-round","e-top-icon-btn","e-bottom-icon-btn"];this.cssClass&&(e=e.concat(this.cssClass.split(" "))),n.prototype.destroy.call(this),K([this.element],e),this.element.getAttribute("class")||this.element.removeAttribute("class"),this.disabled&&this.element.removeAttribute("disabled"),this.content&&(this.element.innerHTML=this.element.innerHTML.replace(this.content,""));var i=this.element.querySelector("span.e-btn-icon");i&&he(i),this.unWireEvents(),Zo&&this.removeRippleEffect()},t.prototype.getModuleName=function(){return"btn"},t.prototype.getPersistData=function(){return this.addOnPersist([])},t.Inject=function(){},t.prototype.onPropertyChanged=function(e,i){for(var r=this.element.querySelector("span.e-btn-icon"),s=0,o=Object.keys(e);s=hd.width?hd.width:0;return vl.right+QR()-n}function cE(){return F0()+vl.width/2}function dE(n,t,e,i){if(void 0===t&&(t=null),void 0===e&&(e={X:!1,Y:!1}),!e.Y&&!e.X)return{left:0,top:0};var r=n.getBoundingClientRect();if(uo=t,sc=n.ownerDocument,i||(i=is(n,"left","top")),e.X){var s=uo?ZR():i4(),o=vE(),a=mE(),l=o-i.left,h=i.left+r.width-a;r.width>s?i.left=l>0&&h<=0?a-r.width:h>0&&l<=0?o:l>h?a-r.width:o:l>0?i.left+=l:h>0&&(i.left-=h)}if(e.Y){var c=uo?JR():t4(),d=gE(),u=yE(),p=d-i.top,f=i.top+r.height-u;r.height>c?i.top=p>0&&f<=0?u-r.height:f>0&&p<=0?d:p>f?u-r.height:d:p>0?i.top+=p:f>0&&(i.top-=f)}return i}function oc(n,t,e,i){void 0===t&&(t=null);var r=is(n,"left","top");e&&(r.left=e),i&&(r.top=i);var s=[];uo=t,sc=n.ownerDocument;var o=n.getBoundingClientRect(),l=r.left,h=r.left+o.width,d=fE(r.top,r.top+o.height),u=XR(l,h);return d.topSide&&s.push("top"),u.rightSide&&s.push("right"),u.leftSide&&s.push("left"),d.bottomSide&&s.push("bottom"),s}function uJ(n,t,e,i,r,s,o,a,l){if(void 0===o&&(o=null),void 0===a&&(a={X:!0,Y:!0}),t&&n&&r&&s&&(a.X||a.Y)){var d,h={TL:null,TR:null,BL:null,BR:null},c={TL:null,TR:null,BL:null,BR:null};if("none"===window.getComputedStyle(n).display){var u=n.style.visibility;n.style.visibility="hidden",n.style.display="block",d=n.getBoundingClientRect(),n.style.removeProperty("display"),n.style.visibility=u}else d=n.getBoundingClientRect();var p={posX:r,posY:s,offsetX:e,offsetY:i,position:{left:0,top:0}};uo=o,sc=t.ownerDocument,function fJ(n,t,e,i,r){e.position=is(n,e.posX,e.posY,i,r),t.TL=is(n,"left","top",i,r),t.TR=is(n,"right","top",i,r),t.BR=is(n,"left","bottom",i,r),t.BL=is(n,"right","bottom",i,r)}(t,h,p,l,d),pE(c,p,d),a.X&&qR(t,c,h,p,d,!0),a.Y&&h.TL.top>-1&&$R(t,c,h,p,d,!0),function pJ(n,t,e){var i=0,r=0;if(null!=n.offsetParent&&("absolute"===getComputedStyle(n.offsetParent).position||"relative"===getComputedStyle(n.offsetParent).position)){var s=is(n.offsetParent,"left","top",!1,e);i=s.left,r=s.top}var o=1,a=1,l=GR(n);if(l){var h=getComputedStyle(l).transform;if("none"!==h){var c=new DOMMatrix(h);o=c.a,a=c.d}if("none"!==getComputedStyle(l).zoom){var u=uE(document.body);o*=u,a*=u}}n.style.top=t.position.top/a+t.offsetY-r/a+"px",n.style.left=t.position.left/o+t.offsetX-i/o+"px"}(n,p,d)}}function uE(n){var t=getComputedStyle(n).zoom;return parseFloat(t)||1}function GR(n){for(;n;){var t=window.getComputedStyle(n).transform,e=uE(document.body);if(t&&"none"!==t||e&&1!==e)return n;if(n===document.body)return null;n=n.offsetParent||n.parentElement}return null}function pE(n,t,e){n.TL={top:t.position.top+t.offsetY,left:t.position.left+t.offsetX},n.TR={top:n.TL.top,left:n.TL.left+e.width},n.BL={top:n.TL.top+e.height,left:n.TL.left},n.BR={top:n.TL.top+e.height,left:n.TL.left+e.width}}function XR(n,t){var e=!1,i=!1;return n-U0()mE()&&(i=!0),{leftSide:e,rightSide:i}}function qR(n,t,e,i,r,s){var o=XR(t.TL.left,t.TR.left),a=fE(t.TL.top,t.BL.top);e.TL.left-U0()<=vE()&&(o.leftSide=!1),e.TR.left>mE()&&(o.rightSide=!1),(o.leftSide&&!o.rightSide||!o.leftSide&&o.rightSide)&&(i.posX="right"===i.posX?"left":"right",i.offsetX=i.offsetX+r.width,i.offsetX=-1*i.offsetX,i.position=is(n,i.posX,i.posY,!1),pE(t,i,r),s&&qR(n,t,e,i,r,!1),!o.leftSide&&o.rightSide&&a.bottomSide&&(i.offsetX=0))}function $R(n,t,e,i,r,s){var o=fE(t.TL.top,t.BL.top);e.TL.top-_0()<=gE()&&(o.topSide=!1),e.BL.top>=yE()&&n.getBoundingClientRect().bottomyE()&&(i=!0),{topSide:e,bottomSide:i}}function ZR(){return uo.getBoundingClientRect().width}function JR(){return uo.getBoundingClientRect().height}function KR(){return uo.getBoundingClientRect().left}function e4(){return uo.getBoundingClientRect().top}function gE(){return uo?e4():0}function vE(){return uo?KR():0}function mE(){return uo?U0()+KR()+ZR():U0()+i4()}function yE(){return uo?_0()+e4()+JR():_0()+t4()}function _0(){return sc.documentElement.scrollTop||sc.body.scrollTop}function U0(){return sc.documentElement.scrollLeft||sc.body.scrollLeft}function t4(){return window.innerHeight}function i4(){var n=window.innerWidth,t=document.documentElement.getBoundingClientRect();return n-(n-(m(document.documentElement)?0:t.width))}function r4(){uo=null,sc=null}var n4=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),bn=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},s4=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return n4(t,n),bn([I("left")],t.prototype,"X",void 0),bn([I("top")],t.prototype,"Y",void 0),t}(Ee),Gn_OPEN="e-popup-open",Gn_CLOSE="e-popup-close",ac=function(n){function t(e,i){return n.call(this,i,e)||this}return n4(t,n),t.prototype.onPropertyChanged=function(e,i){for(var r=0,s=Object.keys(e);r0&&c.left>0&&c.right>0&&c.bottom>0}var s=i.getBoundingClientRect();return!(r.bottoms.bottom||r.right>s.right||r.leftr.top?this.element.style.top="0px":s.bottomr.left&&(this.element.style.left=parseInt(this.element.style.left,10)+(s.left-r.left)+"px"))}},t.prototype.checkCollision=function(){var e=this.collision.X,i=this.collision.Y;"none"===e&&"none"===i||("flip"===e&&"flip"===i?this.callFlip({X:!0,Y:!0}):"fit"===e&&"fit"===i?this.callFit({X:!0,Y:!0}):("flip"===e?this.callFlip({X:!0,Y:!1}):"flip"===i&&this.callFlip({Y:!0,X:!1}),"fit"===e?this.callFit({X:!0,Y:!1}):"fit"===i&&this.callFit({X:!1,Y:!0})))},t.prototype.show=function(e,i){var r=this;if(this.getRelateToElement().classList.contains("e-filemanager")&&(this.fmDialogContainer=this.element.getElementsByClassName("e-file-select-wrap")[0]),this.wireEvents(),!m(this.fmDialogContainer)&&X.isIos&&(this.fmDialogContainer.style.display="block"),1e3===this.zIndex||!m(i)){var o=m(i)?this.element:i;this.zIndex=lc(o),je(this.element,{zIndex:this.zIndex})}e=m(e)||"object"!=typeof e?this.showAnimation:e,("none"!==this.collision.X||"none"!==this.collision.Y)&&(K([this.element],Gn_CLOSE),V([this.element],Gn_OPEN),this.checkCollision(),K([this.element],Gn_OPEN),V([this.element],Gn_CLOSE)),m(e)?(K([this.element],Gn_CLOSE),V([this.element],Gn_OPEN),this.trigger("open")):(e.begin=function(){r.isDestroyed||(K([r.element],Gn_CLOSE),V([r.element],Gn_OPEN))},e.end=function(){r.isDestroyed||r.trigger("open")},new Hs(e).animate(this.element))},t.prototype.hide=function(e){var i=this;e=m(e)||"object"!=typeof e?this.hideAnimation:e,m(e)?(K([this.element],Gn_OPEN),V([this.element],Gn_CLOSE),this.trigger("close")):(e.end=function(){i.isDestroyed||(K([i.element],Gn_OPEN),V([i.element],Gn_CLOSE),i.trigger("close"))},new Hs(e).animate(this.element)),this.unwireEvents()},t.prototype.getScrollableParent=function(e){return this.checkFixedParent(e),function SE(n,t){for(var e=getComputedStyle(n),i=[],r=/(auto|scroll)/,s=n.parentElement;s&&"HTML"!==s.tagName;){var o=getComputedStyle(s);!("absolute"===e.position&&"static"===o.position)&&r.test(o.overflow+o.overflowY+o.overflowX)&&i.push(s),s=s.parentElement}return t||i.push(document),i}(e,this.fixedParent)},t.prototype.checkFixedParent=function(e){for(var i=e.parentElement;i&&"HTML"!==i.tagName;){var r=getComputedStyle(i);("fixed"===r.position||"sticky"===r.position)&&!m(this.element)&&this.element.offsetParent&&"BODY"===this.element.offsetParent.tagName&&"hidden"!==getComputedStyle(this.element.offsetParent).overflow&&(this.element.style.top=window.scrollY>parseInt(this.element.style.top,10)?Re(window.scrollY-parseInt(this.element.style.top,10)):Re(parseInt(this.element.style.top,10)-window.scrollY),this.element.style.position="fixed",this.fixedParent=!0),i=i.parentElement,!m(this.element)&&m(this.element.offsetParent)&&"fixed"===r.position&&"fixed"===this.element.style.position&&(this.fixedParent=!0)}},bn([I("auto")],t.prototype,"height",void 0),bn([I("auto")],t.prototype,"width",void 0),bn([I(null)],t.prototype,"content",void 0),bn([I("container")],t.prototype,"targetType",void 0),bn([I(null)],t.prototype,"viewPortElement",void 0),bn([I({X:"none",Y:"none"})],t.prototype,"collision",void 0),bn([I("")],t.prototype,"relateTo",void 0),bn([re({},s4)],t.prototype,"position",void 0),bn([I(0)],t.prototype,"offsetX",void 0),bn([I(0)],t.prototype,"offsetY",void 0),bn([I(1e3)],t.prototype,"zIndex",void 0),bn([I(!1)],t.prototype,"enableRtl",void 0),bn([I("reposition")],t.prototype,"actionOnScroll",void 0),bn([I(null)],t.prototype,"showAnimation",void 0),bn([I(null)],t.prototype,"hideAnimation",void 0),bn([H()],t.prototype,"open",void 0),bn([H()],t.prototype,"close",void 0),bn([H()],t.prototype,"targetExitViewport",void 0),bn([Ft],t)}(yi);function lc(n){for(var t=n.parentElement,e=[];t&&"BODY"!==t.tagName;){var i=document.defaultView.getComputedStyle(t,null).getPropertyValue("z-index"),r=document.defaultView.getComputedStyle(t,null).getPropertyValue("position");"auto"!==i&&"static"!==r&&e.push(i),t=t.parentElement}for(var s=[],o=0;o2147483647?2147483647:c}var _i,Oa,hp,fh,wE,gh,Zt,vh,IE=["north-west","north","north-east","west","east","south-west","south","south-east"],jg="e-resize-handle",hc="e-focused-handle",gJ="e-dlg-resizable",o4=["e-restrict-left"],a4="e-resize-viewport",vJ=["north","west","east","south"],bE=0,ME=0,l4=0,h4=0,Vg=0,Wg=0,Yg=null,CE=null,EE=null,j0=!0,c4=0,DE=!0;function yJ(n){xE();var t=mi("span",{attrs:{unselectable:"on",contenteditable:"false"}});t.setAttribute("class","e-dialog-border-resize e-"+n),"south"===n&&(t.style.height="2px",t.style.width="100%",t.style.bottom="0px",t.style.left="0px"),"north"===n&&(t.style.height="2px",t.style.width="100%",t.style.top="0px",t.style.left="0px"),"east"===n&&(t.style.height="100%",t.style.width="2px",t.style.right="0px",t.style.top="0px"),"west"===n&&(t.style.height="100%",t.style.width="2px",t.style.left="0px",t.style.top="0px"),_i.appendChild(t)}function d4(n){var t;return m(n)||(t="string"==typeof n?document.querySelector(n):n),t}function u4(n){for(var t=n||this,e=_i.querySelectorAll("."+jg),i=0;i-1?"mouse":"touch"}function f4(n){if(n.preventDefault(),_i=n.target.parentElement,xE(),Vg=n.pageX,Wg=n.pageY,n.target.classList.add(hc),m(Yg)||!0!==Yg(n,this)){this.targetEle&&_i&&_i.querySelector("."+gJ)&&(Zt="body"===this.target?null:this.targetEle,gh=this.targetEle.clientWidth,fh=this.targetEle.clientHeight);var e=m(Zt)?document:Zt;E.add(e,"mousemove",Qg,this),E.add(document,"mouseup",V0,this);for(var i=0;i=0||s.top<0)&&(e=!0):e=!0;var a=ME+(r-Wg);a=a>hp?a:hp;var l=0;m(Zt)||(l=o.top);var h=m(Zt)?0:Zt.offsetHeight-Zt.clientHeight,c=s.top-l-h/2;if(c=c<0?0:c,s.top>0&&c+a>fh){if(e=!1,_i.classList.contains(a4))return;_i.style.height=fh-parseInt(c.toString(),10)+"px"}else{var d=0;if(e){s.top<0&&t+(s.height+s.top)>0&&a+(d=s.top)<=30&&(a=s.height-(s.height+s.top)+30),a+s.top>=fh&&(_i.style.height=s.height+(t-(s.height+s.top))+"px");var u=m(Zt)?d:c;a>=hp&&a+u<=fh&&(_i.style.height=a+"px")}}}function AE(n){var e,t=!1,i="mouse"===p4(n.type)?n.pageY:n.touches[0].pageY,r=cc(_i),s=m(Zt)?0:Zt.offsetHeight-Zt.clientHeight;m(Zt)||(e=cc(Zt)),(!m(Zt)&&r.top-e.top>0||m(Zt)&&i>0||!m(Zt)&&Math.floor(r.top-e.top+r.height+(e.bottom-r.bottom))-s<=fh)&&(t=!0);var o=ME-(i-Wg);if(t&&o>=hp&&o<=fh){var a=0;m(Zt)||(a=e.top);var l=h4-a+(i-Wg);l=l>0?l:1,_i.style.height=o+"px",_i.style.top=l+"px"}}function LE(n){var i,t=document.documentElement.clientWidth,e=!1;m(Zt)||(i=cc(Zt));var r="mouse"===p4(n.type)?n.pageX:n.touches[0].pageX,s=cc(_i),o=m(Zt)?0:Zt.offsetWidth-Zt.clientWidth,a=m(Zt)?0:i.left,l=m(Zt)?0:i.width;m(vh)&&(m(Zt)?vh=t:(vh=s.left-a-o/2+s.width,vh+=l-o-vh)),(!m(Zt)&&Math.floor(s.left-i.left+s.width+(i.right-s.right))-o<=gh||m(Zt)&&r>=0)&&(e=!0);var h=bE-(r-Vg);if(j0&&(h=h>vh?vh:h),e&&h>=wE&&h<=gh){var c=0;m(Zt)||(c=i.left);var d=l4-c+(r-Vg);d=d>0?d:1,h!==c4&&DE&&(_i.style.width=h+"px"),j0&&(_i.style.left=d+"px",DE=1!==d)}c4=h}function NE(n){var i,t=document.documentElement.clientWidth,e=!1;m(Zt)||(i=cc(Zt));var s=(n.touches?n.changedTouches[0]:n).pageX,o=cc(_i);(!m(Zt)&&(o.left-i.left+o.width<=gh||o.right-i.left>=o.width)||m(Zt)&&t-s>0)&&(e=!0);var a=bE+(s-Vg),l=0;if(m(Zt)||(l=i.left),o.left-l+a>gh){if(e=!1,_i.classList.contains(a4))return;_i.style.width=gh-(o.left-l)+"px"}e&&a>=wE&&a<=gh&&(_i.style.width=a+"px")}function v4(){for(var n=_i.querySelectorAll("."+jg),t=0;t=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},wJ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return OE(t,n),Jt([I(!0)],t.prototype,"isFlat",void 0),Jt([I()],t.prototype,"buttonModel",void 0),Jt([I("Button")],t.prototype,"type",void 0),Jt([H()],t.prototype,"click",void 0),t}(Ee),CJ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return OE(t,n),Jt([I("Fade")],t.prototype,"effect",void 0),Jt([I(400)],t.prototype,"duration",void 0),Jt([I(0)],t.prototype,"delay",void 0),t}(Ee),W0="e-dialog",kE="e-rtl",PE="e-dlg-header-content",m4="e-dlg-header",Y0="e-footer-content",Q0="e-dlg-modal",y4="e-icon-dlg-close",ml="e-dlg-target",ka="e-scroll-disabled",S4="e-device",G0="e-dlg-fullscreen",I4="e-dlg-closeicon-btn",b4="e-popup-open",M4="Information",w4="e-scroll-disabled",C4="e-alert-dialog",E4="e-confirm-dialog",zE="e-dlg-resizable",cp="e-restrict-left",D4="e-resize-viewport",RE="user action",HJ=function(n){function t(e,i){var r=n.call(this,e,i)||this;return r.needsID=!0,r}return OE(t,n),t.prototype.render=function(){this.initialize(),this.initRender(),this.wireEvents(),"100%"===this.width&&(this.element.style.width=""),""!==this.minHeight&&(this.element.style.minHeight=Re(this.minHeight)),this.enableResize&&(this.setResize(),this.isModal&&(this.isModelResize=!0),"None"===this.animationSettings.effect&&this.getMinHeight()),this.renderComplete()},t.prototype.initializeValue=function(){this.dlgClosedBy=RE},t.prototype.preRender=function(){var e=this;if(this.initializeValue(),this.headerContent=null,this.allowMaxHeight=!0,this.preventVisibility=!0,this.clonedEle=this.element.cloneNode(!0),this.closeIconClickEventHandler=function(s){e.dlgClosedBy="close icon",e.hide(s)},this.dlgOverlayClickEventHandler=function(s){e.dlgClosedBy="overlayClick",s.preventFocus=!1,e.trigger("overlayClick",s,function(o){o.preventFocus||e.focusContent(),e.dlgClosedBy=RE})},this.l10n=new ho("dialog",{close:"Close"},this.locale),this.checkPositionData(),m(this.target)){var r=this.isProtectedOnChange;this.isProtectedOnChange=!0,this.target=document.body,this.isProtectedOnChange=r}},t.prototype.updatePersistData=function(){this.enablePersistence&&this.setProperties({width:parseFloat(this.element.style.width),height:parseFloat(this.element.style.height),position:{X:parseFloat(this.dragObj.element.style.left),Y:parseFloat(this.dragObj.element.style.top)}},!0)},t.prototype.isNumberValue=function(e){return/^[-+]?\d*\.?\d+$/.test(e)},t.prototype.checkPositionData=function(){if(!m(this.position)){if(!m(this.position.X)&&"number"!=typeof this.position.X&&this.isNumberValue(this.position.X)){var i=this.isProtectedOnChange;this.isProtectedOnChange=!0,this.position.X=parseFloat(this.position.X),this.isProtectedOnChange=i}m(this.position.Y)||"number"==typeof this.position.Y||this.isNumberValue(this.position.Y)&&(i=this.isProtectedOnChange,this.isProtectedOnChange=!0,this.position.Y=parseFloat(this.position.Y),this.isProtectedOnChange=i)}},t.prototype.getEle=function(e,i){for(var r=void 0,s=0;s=0&&t[e])yJ(t[e]);else if(""!==t[e].trim()){var i=mi("div",{className:"e-icons "+jg+" e-"+t[e]});_i.appendChild(i)}hp=n.minHeight,wE=n.minWidth,gh=n.maxWidth,fh=n.maxHeight,n.proxy&&n.proxy.element&&n.proxy.element.classList.contains("e-dialog")?u4(n.proxy):u4()}({element:this.element,direction:r,minHeight:parseInt(e.slice(0,i.indexOf("p")),10),maxHeight:this.targetEle.clientHeight,minWidth:parseInt(i.slice(0,i.indexOf("p")),10),maxWidth:this.targetEle.clientWidth,boundary:this.target===document.body?null:this.targetEle,resizeBegin:this.onResizeStart.bind(this),resizeComplete:this.onResizeComplete.bind(this),resizing:this.onResizing.bind(this),proxy:this}),this.wireWindowResizeEvent()}else v4(),this.unWireWindowResizeEvent(),this.element.classList.remove(this.isModal?cp:D4),this.element.classList.remove(zE)},t.prototype.getFocusElement=function(e){var r=e.querySelectorAll('input,select,textarea,button:enabled,a,[contenteditable="true"],[tabindex]');return{element:r[r.length-1]}},t.prototype.keyDown=function(e){var i=this;if(9===e.keyCode&&this.isModal){var r=void 0;m(this.btnObj)||(r=this.btnObj[this.btnObj.length-1]),m(this.btnObj)&&!m(this.ftrTemplateContent)&&(r=this.getFocusElement(this.ftrTemplateContent)),m(this.btnObj)&&m(this.ftrTemplateContent)&&!m(this.contentEle)&&(r=this.getFocusElement(this.contentEle)),!m(r)&&document.activeElement===r.element&&!e.shiftKey&&(e.preventDefault(),this.focusableElements(this.element).focus()),document.activeElement===this.focusableElements(this.element)&&e.shiftKey&&(e.preventDefault(),m(r)||r.element.focus())}var h,s=document.activeElement,o=["input","textarea"].indexOf(s.tagName.toLowerCase())>-1,a=!1;if(o||(a=s.hasAttribute("contenteditable")&&"true"===s.getAttribute("contenteditable")),27===e.keyCode&&this.closeOnEscape){this.dlgClosedBy="escape";var l=document.querySelector(".e-popup-open:not(.e-dialog)");!m(l)&&!l.classList.contains("e-toolbar-pop")||this.hide(e)}(13===e.keyCode&&!e.ctrlKey&&"textarea"!==s.tagName.toLowerCase()&&o&&!m(this.primaryButtonEle)||13===e.keyCode&&e.ctrlKey&&("textarea"===s.tagName.toLowerCase()||a)&&!m(this.primaryButtonEle))&&this.buttons.some(function(d,u){h=u;var p=d.buttonModel;return!m(p)&&!0===p.isPrimary})&&"function"==typeof this.buttons[h].click&&setTimeout(function(){i.buttons[h].click.call(i,e)})},t.prototype.initialize=function(){m(this.target)||(this.targetEle="string"==typeof this.target?document.querySelector(this.target):this.target),this.isBlazorServerRender()||V([this.element],W0),X.isDevice&&V([this.element],S4),this.isBlazorServerRender()||this.setCSSClass(),this.setMaxHeight()},t.prototype.initRender=function(){var e=this;if(this.initialRender=!0,this.isBlazorServerRender()||Fe(this.element,{role:"dialog"}),1e3===this.zIndex?(this.setzIndex(this.element,!1),this.calculatezIndex=!0):this.calculatezIndex=!1,this.setTargetContent(),""!==this.header&&!m(this.header)&&this.setHeader(),this.renderCloseIcon(),this.setContent(),""===this.footerTemplate||m(this.footerTemplate)?!m(this.buttons[0])&&!m(this.buttons[0].buttonModel)&&this.setButton():this.setFooterTemplate(),this.allowDragging&&!m(this.headerContent)&&this.setAllowDragging(),Fe(this.element,{"aria-modal":this.isModal?"true":"false"}),this.isModal&&this.setIsModal(),!0!==this.element.classList.contains(C4)&&!0!==this.element.classList.contains(E4)&&!m(this.element.parentElement)){var i=this.isModal?this.dlgContainer.parentElement:this.element.parentElement;this.refElement=this.createElement("div",{className:"e-dlg-ref-element"}),i.insertBefore(this.refElement,this.isModal?this.dlgContainer:this.element)}if(m(this.targetEle)||this.targetEle.appendChild(this.isModal?this.dlgContainer:this.element),this.popupObj=new ac(this.element,{height:this.height,width:this.width,zIndex:this.zIndex,relateTo:this.target,actionOnScroll:"none",enableRtl:this.enableRtl,open:function(o){var a={container:e.isModal?e.dlgContainer:e.element,element:e.element,target:e.target,preventFocus:!1};e.enableResize&&e.resetResizeIcon(),e.trigger("open",a,function(l){l.preventFocus||e.focusContent()})},close:function(o){e.isModal&&V([e.dlgOverlay],"e-fade"),e.unBindEvent(e.element),e.isModal&&(e.dlgContainer.style.display="none"),e.trigger("close",e.closeArgs);var a=document.activeElement;!m(a)&&!m(a.blur)&&a.blur(),!m(e.storeActiveElement)&&!m(e.storeActiveElement.focus)&&e.storeActiveElement.focus()}}),this.positionChange(),this.setEnableRTL(),this.isBlazorServerRender()||(V([this.element],"e-popup-close"),this.isModal&&this.setOverlayZindex()),this.visible){if(this.show(),this.isModal){var r=this.getTargetContainer(this.target);r instanceof Element&&"rtl"===window.getComputedStyle(r).getPropertyValue("direction")&&this.setPopupPosition()}}else this.isModal&&(this.dlgOverlay.style.display="none");this.initialRender=!1},t.prototype.getTargetContainer=function(e){var i=null;if("string"==typeof e)if(e.startsWith("#"))i=document.getElementById(e.substring(1));else if(e.startsWith(".")){var r=document.getElementsByClassName(e.substring(1));i=r.length>0?r[0]:null}else!(e instanceof HTMLElement)&&e!==document.body&&(i=document.querySelector(e));else e instanceof HTMLElement&&(i=e);return i},t.prototype.resetResizeIcon=function(){var e=this.getMinHeight();if(this.targetEle.offsetHeight0&&("function"==typeof this.buttons[e].click&&E.add(s[e],"click",this.buttons[e].click,this),"object"==typeof this.buttons[e].click&&E.add(s[e],"click",this.buttonClickHandler.bind(this,e),this)),!this.isBlazorServerRender()&&!m(this.ftrTemplateContent)&&(this.btnObj[e].appendTo(this.ftrTemplateContent.children[e]),this.buttons[e].isFlat&&this.btnObj[e].element.classList.add("e-flat"),this.primaryButtonEle=this.element.getElementsByClassName("e-primary")[0]))},t.prototype.buttonClickHandler=function(e){this.trigger("buttons["+e+"].click",{})},t.prototype.setContent=function(){this.contentEle=this.createElement("div",{className:"e-dlg-content",id:this.element.id+"_dialog-content"}),Fe(this.element,this.headerEle?{"aria-describedby":this.element.id+"_title "+this.element.id+"_dialog-content"}:{"aria-describedby":this.element.id+"_dialog-content"}),this.innerContentElement?this.contentEle.appendChild(this.innerContentElement):(!m(this.content)&&""!==this.content||!this.initialRender)&&(("string"!=typeof this.content||ce())&&this.content instanceof HTMLElement?this.contentEle.appendChild(this.content):this.setTemplate(this.content,this.contentEle,"content")),m(this.headerContent)?this.element.insertBefore(this.contentEle,this.element.children[0]):this.element.insertBefore(this.contentEle,this.element.children[1]),"auto"===this.height&&(!this.isBlazorServerRender()&&X.isIE&&""===this.element.style.width&&!m(this.width)&&(this.element.style.width=Re(this.width)),this.setMaxHeight())},t.prototype.setTemplate=function(e,i,r){var s,o,a;o=i.classList.contains(m4)?this.element.id+"header":i.classList.contains(Y0)?this.element.id+"footerTemplate":this.element.id+"content",m(e.outerHTML)?("string"==typeof e||"string"!=typeof e||ce()&&!this.isStringTemplate)&&("string"==typeof e&&(e=this.sanitizeHelper(e)),this.isVue||"string"!=typeof e?(s=ri(e),a=e):i.innerHTML=e):i.appendChild(e);var l=[];if(!m(s)){for(var c=0,d=s({},this,r,o,!(ce()&&!this.isStringTemplate&&0===a.indexOf("
Blazor"))||this.isStringTemplate);c/g,"");(this.element.children.length>0||i)&&(this.innerContentElement=document.createDocumentFragment(),[].slice.call(this.element.childNodes).forEach(function(r){8!==r.nodeType&&e.innerContentElement.appendChild(r)}))}},t.prototype.setHeader=function(){this.headerEle?this.headerEle.innerHTML="":this.headerEle=this.createElement("div",{id:this.element.id+"_title",className:m4}),this.createHeaderContent(),this.headerContent.appendChild(this.headerEle),this.setTemplate(this.header,this.headerEle,"header"),Fe(this.element,{"aria-describedby":this.element.id+"_title"}),Fe(this.element,{"aria-labelledby":this.element.id+"_dialog-header"}),this.element.insertBefore(this.headerContent,this.element.children[0]),this.allowDragging&&!m(this.headerContent)&&this.setAllowDragging()},t.prototype.setFooterTemplate=function(){this.ftrTemplateContent?this.ftrTemplateContent.innerHTML="":this.ftrTemplateContent=this.createElement("div",{className:Y0}),""===this.footerTemplate||m(this.footerTemplate)?this.ftrTemplateContent.innerHTML=this.buttonContent.join(""):this.setTemplate(this.footerTemplate,this.ftrTemplateContent,"footerTemplate"),this.element.appendChild(this.ftrTemplateContent)},t.prototype.createHeaderContent=function(){m(this.headerContent)&&(this.headerContent=this.createElement("div",{id:this.element.id+"_dialog-header",className:PE}))},t.prototype.renderCloseIcon=function(){this.showCloseIcon&&(this.closeIcon=this.createElement("button",{className:I4,attrs:{type:"button"}}),this.closeIconBtnObj=new ys({cssClass:"e-flat",iconCss:y4+" e-icons"}),this.closeIconTitle(),m(this.headerContent)?(this.createHeaderContent(),pl([this.closeIcon],this.headerContent),this.element.insertBefore(this.headerContent,this.element.children[0])):pl([this.closeIcon],this.headerContent),this.closeIconBtnObj.appendTo(this.closeIcon))},t.prototype.closeIconTitle=function(){this.l10n.setLocale(this.locale);var e=this.l10n.getConstant("close");this.closeIcon.setAttribute("title",e),this.closeIcon.setAttribute("aria-label",e)},t.prototype.setCSSClass=function(e){e&&(K([this.element],e.split(" ")),this.isModal&&!m(this.dlgContainer)&&K([this.dlgContainer],e.split(" "))),this.cssClass&&(V([this.element],this.cssClass.split(" ")),this.isModal&&!m(this.dlgContainer)&&V([this.dlgContainer],this.cssClass.split(" ")))},t.prototype.setIsModal=function(){this.dlgContainer=this.createElement("div",{className:"e-dlg-container"}),this.setCSSClass(),this.element.classList.remove(b4),this.element.parentNode.insertBefore(this.dlgContainer,this.element),this.dlgContainer.appendChild(this.element),V([this.element],Q0),this.dlgOverlay=this.createElement("div",{className:"e-dlg-overlay"}),this.dlgOverlay.style.zIndex=(this.zIndex-1).toString(),this.dlgContainer.appendChild(this.dlgOverlay)},t.prototype.getValidFocusNode=function(e){for(var i,r=0;r0||"a"===i.tagName.toLowerCase()&&i.hasAttribute("href"))&&i.tabIndex>-1&&!i.disabled&&!this.disableElement(i,'[disabled],[aria-disabled="true"],[type="hidden"]'))return i;i=null}return i},t.prototype.focusableElements=function(e){if(!m(e)){var r=e.querySelectorAll('input,select,textarea,button,a,[contenteditable="true"],[tabindex]');return this.getValidFocusNode(r)}return null},t.prototype.getAutoFocusNode=function(e){var i=e.querySelector("."+I4),s=e.querySelectorAll("[autofocus]"),o=this.getValidFocusNode(s);if(ce()&&(this.primaryButtonEle=this.element.getElementsByClassName("e-primary")[0]),m(o)){if(!m(o=this.focusableElements(this.contentEle)))return o;if(!m(this.primaryButtonEle))return this.element.querySelector(".e-primary")}else i=o;return i},t.prototype.disableElement=function(e,i){var r=e?e.matches||e.webkitMatchesSelector||e.msGetRegionContent:null;if(r)for(;e;e=e.parentNode)if(e instanceof Element&&r.call(e,i))return e;return null},t.prototype.focusContent=function(){var e=this.getAutoFocusNode(this.element),i=m(e)?this.element:e,r=X.userAgent;(r.indexOf("MSIE ")>0||r.indexOf("Trident/")>0)&&this.element.focus(),i.focus(),this.unBindEvent(this.element),this.bindEvent(this.element)},t.prototype.bindEvent=function(e){E.add(e,"keydown",this.keyDown,this)},t.prototype.unBindEvent=function(e){E.remove(e,"keydown",this.keyDown)},t.prototype.updateSanitizeContent=function(){this.isBlazorServerRender()||(this.contentEle.innerHTML=this.sanitizeHelper(this.content))},t.prototype.isBlazorServerRender=function(){return ce()&&this.isServerRendered},t.prototype.getModuleName=function(){return"dialog"},t.prototype.onPropertyChanged=function(e,i){if(this.element.classList.contains(W0))for(var r=0,s=Object.keys(e);r0?this.showCloseIcon||""!==this.header&&!m(this.header)?this.showCloseIcon||he(this.closeIcon):(he(this.headerContent),this.headerContent=null):(this.renderCloseIcon(),this.wireEvents());break;case"locale":this.showCloseIcon&&this.closeIconTitle();break;case"visible":this.visible?this.show():this.hide();break;case"isModal":this.updateIsModal();break;case"height":je(this.element,{height:Re(e.height)}),this.updatePersistData();break;case"width":je(this.element,{width:Re(e.width)}),this.updatePersistData();break;case"zIndex":this.popupObj.zIndex=this.zIndex,this.isModal&&this.setOverlayZindex(this.zIndex),this.element.style.zIndex!==this.zIndex.toString()&&(this.calculatezIndex=!1);break;case"cssClass":this.setCSSClass(i.cssClass);break;case"buttons":this.unWireButtonEvents(),this.destroyButtons(),m(this.ftrTemplateContent)||(he(this.ftrTemplateContent),this.ftrTemplateContent=null),this.footerTemplate="",this.setButton();break;case"allowDragging":this.allowDragging&&!m(this.headerContent)?this.setAllowDragging():this.dragObj.destroy();break;case"target":this.setTarget(e.target);break;case"position":if(this.checkPositionData(),this.isModal){var a=this.position.X,l=this.position.Y;m(i.position)||(m(i.position.X)||(a=i.position.X),m(i.position.Y)||(l=i.position.Y)),this.dlgContainer.classList.contains("e-dlg-"+a+"-"+l)&&this.dlgContainer.classList.remove("e-dlg-"+a+"-"+l)}this.positionChange(),this.updatePersistData();break;case"enableRtl":this.setEnableRTL();break;case"enableResize":this.setResize();break;case"minHeight":""!==this.minHeight&&(this.element.style.minHeight=Re(this.minHeight))}},t.prototype.setTarget=function(e){this.popupObj.relateTo=e,this.target=e,this.targetEle="string"==typeof this.target?document.querySelector(this.target):this.target,this.dragObj&&(this.dragObj.dragArea=this.targetEle),this.setMaxHeight(),this.isModal&&this.updateIsModal(),this.enableResize&&this.setResize()},t.prototype.updateIsModal=function(){if(this.element.setAttribute("aria-modal",this.isModal?"true":"false"),this.isModal)m(this.dlgOverlay)&&(this.setIsModal(),this.element.style.top="0px",this.element.style.left="0px",m(this.targetEle)||this.targetEle.appendChild(this.dlgContainer));else{for(K([this.element],Q0),K([document.body],[ml,ka]),he(this.dlgOverlay);this.dlgContainer.firstChild;)this.dlgContainer.parentElement.insertBefore(this.dlgContainer.firstChild,this.dlgContainer);this.dlgContainer.parentElement.removeChild(this.dlgContainer)}this.visible&&this.show(),this.positionChange(),this.isModal&&this.dlgOverlay&&E.add(this.dlgOverlay,"click",this.dlgOverlayClickEventHandler,this)},t.prototype.setzIndex=function(e,i){var r=this.isProtectedOnChange;this.isProtectedOnChange=!0;var s=lc(e);this.zIndex=s>this.zIndex?s:this.zIndex,this.isProtectedOnChange=r,i&&(this.popupObj.zIndex=this.zIndex)},t.prototype.windowResizeHandler=function(){(function IJ(n){gh=n})(this.targetEle.clientWidth),function bJ(n){fh=n}(this.targetEle.clientHeight),this.setMaxHeight()},t.prototype.getPersistData=function(){return this.addOnPersist(["width","height","position"])},t.prototype.removeAllChildren=function(e){for(;e.children[0];)this.removeAllChildren(e.children[0]),e.removeChild(e.children[0])},t.prototype.destroy=function(){if(!this.isDestroyed){var e=[kE,Q0,zE,cp,G0,S4],i=["role","aria-modal","aria-labelledby","aria-describedby","aria-grabbed","tabindex","style"];K([this.targetEle],[ml,ka]),!m(this.element)&&this.element.classList.contains(G0)&&K([document.body],[ml,ka]),this.isModal&&K([m(this.targetEle)?document.body:this.targetEle],ka),this.unWireEvents(),this.unWireButtonEvents(),this.destroyButtons(),m(this.closeIconBtnObj)||this.closeIconBtnObj.destroy(),m(this.dragObj)||this.dragObj.destroy(),!m(this.popupObj.element)&&this.popupObj.element.classList.contains("e-popup")&&this.popupObj.destroy(),K([this.element],e),!m(this.cssClass)&&""!==this.cssClass&&K([this.element],this.cssClass.split(" ")),!m(this.refElement)&&!m(this.refElement.parentElement)&&(this.refElement.parentElement.insertBefore(this.isModal?this.dlgContainer:this.element,this.refElement),he(this.refElement),this.refElement=void 0),this.isModal&&(he(this.dlgOverlay),this.dlgContainer.parentNode.insertBefore(this.element,this.dlgContainer),he(this.dlgContainer)),this.element.innerHTML=this.clonedEle.innerHTML;for(var r=0;r0&&""===this.footerTemplate&&this.ftrTemplateContent)for(var e=0;e=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},HE="e-tooltip",O4="e-icons",k4="e-tooltip-close",BE="e-tooltip-wrap",P4="e-tip-content",dp="e-arrow-tip",z4="e-arrow-tip-outer",X0="e-arrow-tip-inner",Gg="e-tip-bottom",FE="e-tip-top",R4="e-tip-left",_E="e-tip-right",UE="e-popup",Xg="e-popup-open",jE="e-popup-close",q0="e-lib",H4="e-tooltip-popup-container",VJ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return T4(t,n),Gi([I({effect:"FadeIn",duration:150,delay:0})],t.prototype,"open",void 0),Gi([I({effect:"FadeOut",duration:150,delay:0})],t.prototype,"close",void 0),t}(Ee),mh=function(n){function t(e,i){var r=n.call(this,e,i)||this;return r.mouseMoveEvent=null,r.mouseMoveTarget=null,r.containerElement=null,r.isBodyContainer=!0,r}return T4(t,n),t.prototype.initialize=function(){this.formatPosition(),V([this.element],HE)},t.prototype.formatPosition=function(){var e,i;this.position&&(0===this.position.indexOf("Top")||0===this.position.indexOf("Bottom")?(e=this.position.split(/(?=[A-Z])/),this.tooltipPositionY=e[0],this.tooltipPositionX=e[1]):(i=this.position.split(/(?=[A-Z])/),this.tooltipPositionX=i[0],this.tooltipPositionY=i[1]))},t.prototype.renderArrow=function(){this.setTipClass(this.position);var e=this.createElement("div",{className:dp+" "+this.tipClass});e.appendChild(this.createElement("div",{className:z4+" "+this.tipClass})),e.appendChild(this.createElement("div",{className:X0+" "+this.tipClass})),this.tooltipEle.appendChild(e)},t.prototype.setTipClass=function(e){this.tipClass=0===e.indexOf("Right")?R4:0===e.indexOf("Bottom")?FE:0===e.indexOf("Left")?_E:Gg},t.prototype.renderPopup=function(e){var i=this.mouseTrail?{top:0,left:0}:this.getTooltipPosition(e);this.tooltipEle.classList.remove(q0),this.popupObj=new ac(this.tooltipEle,{height:this.height,width:this.width,position:{X:i.left,Y:i.top},enableRtl:this.enableRtl,open:this.openPopupHandler.bind(this),close:this.closePopupHandler.bind(this)})},t.prototype.getScalingFactor=function(e){if(!e)return{x:1,y:1};var i={x:1,y:1},r=e.closest('[style*="transform: scale"]');if(r&&r!==this.tooltipEle&&r.contains(this.tooltipEle)){var a=window.getComputedStyle(r).getPropertyValue("transform").match(/matrix\(([^)]+)\)/)[1].split(",").map(parseFloat);i.x=a[0],i.y=a[3]}return i},t.prototype.getTooltipPosition=function(e){this.tooltipEle.style.display="block";var i=this.element.closest('[style*="zoom"]');i&&(i.contains(this.tooltipEle)||(this.tooltipEle.style.zoom=getComputedStyle(i).zoom));var r=is(e,this.tooltipPositionX,this.tooltipPositionY,!this.isBodyContainer,this.isBodyContainer?null:this.containerElement.getBoundingClientRect()),s=this.getScalingFactor(e),o=this.calculateTooltipOffset(this.position,s.x,s.y),a=this.calculateElementPosition(r,o),c=this.collisionFlipFit(e,a[0],a[1]);return c.left=c.left/s.x,c.top=c.top/s.y,this.tooltipEle.style.display="",c},t.prototype.windowResize=function(){this.reposition(this.findTarget())},t.prototype.reposition=function(e){if(this.popupObj&&e){var i=this.getTooltipPosition(e);this.popupObj.position={X:i.left,Y:i.top},this.popupObj.dataBind()}},t.prototype.openPopupHandler=function(){!this.mouseTrail&&this.needTemplateReposition()&&this.reposition(this.findTarget()),this.trigger("afterOpen",this.tooltipEventArgs),this.tooltipEventArgs=null},t.prototype.closePopupHandler=function(){this.isReact&&!("Click"===this.opensOn||"function"==typeof this.content)&&this.clearTemplate(["content"]),this.clear();var e={type:this.tooltipEventArgs.event?this.tooltipEventArgs.event.type:null,cancel:!1,target:this.tooltipEventArgs.target,event:this.tooltipEventArgs.event?this.tooltipEventArgs.event:null,element:this.tooltipEle,isInteracted:!m(this.tooltipEventArgs.event)};this.trigger("afterClose",e),e=null},t.prototype.calculateTooltipOffset=function(e,i,r){void 0===i&&(i=1),void 0===r&&(r=1);var o,a,l,h,c,d,u,p,s={top:0,left:0};if(1!==i||1!==r){var f=this.tooltipEle.getBoundingClientRect(),g=void 0;l=Math.round(f.width),h=Math.round(f.height),(c=U("."+dp,this.tooltipEle))&&(g=c.getBoundingClientRect()),o=c?Math.round(g.width):0,a=c?Math.round(g.height):0,d=this.showTipPointer?0:8,u=a/2+2+(h-this.tooltipEle.clientHeight*r),p=o/2+2+(l-this.tooltipEle.clientWidth*i)}else l=this.tooltipEle.offsetWidth,h=this.tooltipEle.offsetHeight,c=U("."+dp,this.tooltipEle),d=this.showTipPointer?0:8,u=(a=c?c.offsetHeight:0)/2+2+(this.tooltipEle.offsetHeight-this.tooltipEle.clientHeight),p=(o=c?c.offsetWidth:0)/2+2+(this.tooltipEle.offsetWidth-this.tooltipEle.clientWidth);switch(this.mouseTrail&&(d+=2),e){case"RightTop":s.left+=o+d,s.top-=h-u;break;case"RightCenter":s.left+=o+d,s.top-=h/2;break;case"RightBottom":s.left+=o+d,s.top-=u;break;case"BottomRight":s.top+=a+d,s.left-=p;break;case"BottomCenter":s.top+=a+d,s.left-=l/2;break;case"BottomLeft":s.top+=a+d,s.left-=l-p;break;case"LeftBottom":s.left-=o+l+d,s.top-=u;break;case"LeftCenter":s.left-=o+l+d,s.top-=h/2;break;case"LeftTop":s.left-=o+l+d,s.top-=h-u;break;case"TopLeft":s.top-=h+a+d,s.left-=l-p;break;case"TopRight":s.top-=h+a+d,s.left-=p;break;default:s.top-=h+a+d,s.left-=l/2}return s.left+=this.offsetX,s.top+=this.offsetY,s},t.prototype.updateTipPosition=function(e){var i=we("."+dp+",."+z4+",."+X0,this.tooltipEle);K(i,[Gg,FE,R4,_E]),this.setTipClass(e),V(i,this.tipClass)},t.prototype.adjustArrow=function(e,i,r,s){var o=U("."+dp,this.tooltipEle);if(!1!==this.showTipPointer&&null!==o){var a,l;this.updateTipPosition(i),this.tooltipEle.style.display="block";var f,h=this.tooltipEle.clientWidth,c=this.tooltipEle.clientHeight,d=U("."+X0,this.tooltipEle),u=o.offsetWidth,p=o.offsetHeight;this.tooltipEle.style.display="",this.tipClass===Gg||this.tipClass===FE?(this.tipClass===Gg?(l="99.9%",d.style.top="-"+(p-2)+"px"):(l=-(p-1)+"px",d.style.top="-"+(p-6)+"px"),e&&(a=(f="Center"!==r||h>e.offsetWidth||this.mouseTrail)&&"Left"===r||!f&&"End"===this.tipPointerPosition?h-u-2+"px":f&&"Right"===r||!f&&"Start"===this.tipPointerPosition?"2px":!f||"End"!==this.tipPointerPosition&&"Start"!==this.tipPointerPosition?h/2-u/2+"px":"End"===this.tipPointerPosition?e.offsetWidth+(this.tooltipEle.offsetWidth-e.offsetWidth)/2-u/2-2+"px":(this.tooltipEle.offsetWidth-e.offsetWidth)/2-u/2+2+"px")):(this.tipClass===_E?(a="99.9%",d.style.left="-"+(u-2)+"px"):(a=-(u-1)+"px",d.style.left=u-2-u+"px"),l=(f="Center"!==s||c>e.offsetHeight||this.mouseTrail)&&"Top"===s||!f&&"End"===this.tipPointerPosition?c-p-2+"px":f&&"Bottom"===s||!f&&"Start"===this.tipPointerPosition?"2px":c/2-p/2+"px"),o.style.top=l,o.style.left=a}},t.prototype.renderContent=function(e){var i=this,r=U("."+P4,this.tooltipEle);if(this.cssClass&&V([this.tooltipEle],this.cssClass.split(" ")),e&&!m(e.getAttribute("title"))&&(e.setAttribute("data-content",e.getAttribute("title")),e.removeAttribute("title")),m(this.content))e&&!m(e.getAttribute("data-content"))&&(r.innerHTML=e.getAttribute("data-content"));else if(r.innerHTML="",this.content instanceof HTMLElement)r.appendChild(this.content);else if("string"==typeof this.content)this.isAngular?this.setProperties({content:Ti.sanitize(this.content)},!0):this.content=this.enableHtmlSanitizer?Ti.sanitize(this.content):this.content,this.enableHtmlParse?(o=ri(this.content)({},this,"content",this.element.id+"content",void 0,void 0,r,this.root))&&Dt(o,r):r.textContent=this.content;else{var o;(o=ri(this.content)({},this,"content",this.element.id+"content",void 0,void 0,r))&&(this.isAngular&&setTimeout(function(){i.reposition(e)},1),Dt(o,r)),this.renderReactTemplates()}},t.prototype.renderCloseIcon=function(){if(this.isSticky){var i=this.createElement("div",{className:O4+" "+k4});this.tooltipEle.appendChild(i),E.add(i,X.touchStartEvent,this.onStickyClose,this)}else{var e=this.tooltipEle.querySelector("."+O4+"."+k4);e&>(e)}},t.prototype.addDescribedBy=function(e,i){var r=(e.getAttribute("aria-describedby")||"").split(/\s+/);r.indexOf(i)<0&&r.push(i),Fe(e,{"aria-describedby":r.join(" ").trim(),"data-tooltip-id":i})},t.prototype.removeDescribedBy=function(e){var i=e.getAttribute("data-tooltip-id"),r=(e.getAttribute("aria-describedby")||"").split(/\s+/),s=r.indexOf(i);-1!==s&&r.splice(s,1),e.removeAttribute("data-tooltip-id");var o=r.join(" ").trim();o?e.setAttribute("aria-describedby",o):e.removeAttribute("aria-describedby")},t.prototype.tapHoldHandler=function(e){clearTimeout(this.autoCloseTimer),this.targetHover(e.originalEvent)},t.prototype.touchEndHandler=function(){var e=this;this.isSticky||(this.autoCloseTimer=setTimeout(function(){e.close()},1500))},t.prototype.targetClick=function(e){var i;!m(i=this.target?J(e.target,this.target):this.element)&&(null===i.getAttribute("data-tooltip-id")?this.targetHover(e):this.isSticky||this.hideTooltip(this.animation.close,e,i))},t.prototype.targetHover=function(e){var i;if(!(m(i=this.target?J(e.target,this.target):this.element)||null!==i.getAttribute("data-tooltip-id")&&0===this.closeDelay)){for(var s=0,o=[].slice.call(we('[data-tooltip-id= "'+this.ctrlId+'_content"]',document));s0?this.showTimer=setTimeout(function(){o.mouseTrail&&E.add(i,"mousemove touchstart mouseenter",o.onMouseMove,o),o.popupObj&&(o.popupObj.show(a,i),o.mouseMoveEvent&&o.mouseTrail&&o.onMouseMove(o.mouseMoveEvent))},this.openDelay):this.popupObj&&this.popupObj.show(a,i)}s&&this.wireMouseEvents(s,i)},t.prototype.needTemplateReposition=function(){return!m(this.viewContainerRef)&&"string"!=typeof this.viewContainerRef||this.isReact},t.prototype.checkCollision=function(e,i,r){var s={left:i,top:r,position:this.position,horizontal:this.tooltipPositionX,vertical:this.tooltipPositionY},o=oc(this.tooltipEle,this.checkCollideTarget(),i,r);return o.length>0&&(s.horizontal=o.indexOf("left")>=0?"Right":o.indexOf("right")>=0?"Left":this.tooltipPositionX,s.vertical=o.indexOf("top")>=0?"Bottom":o.indexOf("bottom")>=0?"Top":this.tooltipPositionY),s},t.prototype.calculateElementPosition=function(e,i){return[this.isBodyContainer?e.left+i.left:e.left-this.containerElement.getBoundingClientRect().left+i.left+window.pageXOffset+this.containerElement.scrollLeft,this.isBodyContainer?e.top+i.top:e.top-this.containerElement.getBoundingClientRect().top+i.top+window.pageYOffset+this.containerElement.scrollTop]},t.prototype.collisionFlipFit=function(e,i,r){var s=this.checkCollision(e,i,r),o=s.position;if(this.tooltipPositionY!==s.vertical&&(o=0===this.position.indexOf("Bottom")||0===this.position.indexOf("Top")?s.vertical+this.tooltipPositionX:this.tooltipPositionX+s.vertical),this.tooltipPositionX!==s.horizontal&&(0===o.indexOf("Left")&&(s.vertical="LeftTop"===o||"LeftCenter"===o?"Top":"Bottom",o=s.vertical+"Left"),0===o.indexOf("Right")&&(s.vertical="RightTop"===o||"RightCenter"===o?"Top":"Bottom",o=s.vertical+"Right"),s.horizontal=this.tooltipPositionX),this.tooltipEventArgs={type:null,cancel:!1,target:e,event:null,element:this.tooltipEle,collidedPosition:o},this.trigger("beforeCollision",this.tooltipEventArgs),this.tooltipEventArgs.cancel)o=this.position;else{var a=s.vertical,l=s.horizontal;if(s.position!==o){var h=is(e,l,a,!this.isBodyContainer,this.isBodyContainer?null:this.containerElement.getBoundingClientRect());this.adjustArrow(e,o,l,a);var c=this.getScalingFactor(e),d=this.calculateTooltipOffset(o,c.x,c.y);d.top-=this.getOffSetPosition("TopBottom",o,this.offsetY),d.left-=this.getOffSetPosition("RightLeft",o,this.offsetX),s.position=o;var u=this.calculateElementPosition(h,d);s.left=u[0],s.top=u[1]}else this.adjustArrow(e,o,l,a)}var p={left:s.left,top:s.top},f=this.isBodyContainer?dE(this.tooltipEle,this.checkCollideTarget(),{X:!0,Y:this.windowCollision},p):p;this.tooltipEle.style.display="block";var g=U("."+dp,this.tooltipEle);if(this.showTipPointer&&null!=g&&(0===o.indexOf("Bottom")||0===o.indexOf("Top"))){var v=parseInt(g.style.left,10)-(f.left-s.left);v<0?v=0:v+g.offsetWidth>this.tooltipEle.clientWidth&&(v=this.tooltipEle.clientWidth-g.offsetWidth),g.style.left=v.toString()+"px"}return this.tooltipEle.style.display="",p.left=f.left,p.top=f.top,p},t.prototype.getOffSetPosition=function(e,i,r){return-1!==e.indexOf(this.position.split(/(?=[A-Z])/)[0])&&-1!==e.indexOf(i.split(/(?=[A-Z])/)[0])?2*r:0},t.prototype.checkCollideTarget=function(){return!this.windowCollision&&this.target?this.element:null},t.prototype.hideTooltip=function(e,i,r){var s=this;this.closeDelay>0?(clearTimeout(this.hideTimer),clearTimeout(this.showTimer),this.hideTimer=setTimeout(function(){s.closeDelay&&s.tooltipEle&&s.isTooltipOpen||s.tooltipHide(e,i,r)},this.closeDelay)):this.tooltipHide(e,i,r)},t.prototype.tooltipHide=function(e,i,r){var o,s=this;o=i?this.target?r||i.target:this.element:U('[data-tooltip-id= "'+this.ctrlId+'_content"]',document),this.tooltipEventArgs={type:i?i.type:null,cancel:!1,target:o,event:i||null,element:this.tooltipEle,isInteracted:!m(i)},this.trigger("beforeClose",this.tooltipEventArgs,function(a){a.cancel?s.isHidden=!1:(s.mouseMoveBeforeRemove(),s.popupHide(e,o,i))})},t.prototype.popupHide=function(e,i,r){i&&r&&this.restoreElement(i),this.isHidden=!0;var s={name:this.animation.close.effect,duration:e.duration,delay:e.delay,timingFunction:"easeIn"};"None"===e.effect&&(s=void 0),this.popupObj&&this.popupObj.hide(s)},t.prototype.restoreElement=function(e){this.unwireMouseEvents(e),m(e.getAttribute("data-content"))||(e.setAttribute("title",e.getAttribute("data-content")),e.removeAttribute("data-content")),this.removeDescribedBy(e)},t.prototype.clear=function(){var e=this.findTarget();e&&this.restoreElement(e),this.tooltipEle&&(K([this.tooltipEle],jE),V([this.tooltipEle],Xg)),this.isHidden&&(this.popupObj&&this.popupObj.destroy(),this.tooltipEle&>(this.tooltipEle),this.tooltipEle=null,this.popupObj=null)},t.prototype.tooltipHover=function(){this.tooltipEle&&(this.isTooltipOpen=!0)},t.prototype.tooltipMouseOut=function(e){this.isTooltipOpen=!1,this.hideTooltip(this.animation.close,e,this.findTarget())},t.prototype.onMouseOut=function(e){var i=e.relatedTarget;if(i&&!this.mouseTrail){var r=J(i,"."+BE+"."+q0+"."+UE);r?E.add(r,"mouseleave",this.tooltipElementMouseOut,this):(this.hideTooltip(this.animation.close,e,this.findTarget()),0===this.closeDelay&&("None"===this.animation.close.effect||this.isReact&&"string"!=typeof this.content)&&this.clear())}else this.hideTooltip(this.animation.close,e,this.findTarget()),this.clear();this.popupObj&&!this.popupObj.element.classList.contains(Xg)&&this.clear()},t.prototype.tooltipElementMouseOut=function(e){this.hideTooltip(this.animation.close,e,this.findTarget()),E.remove(this.element,"mouseleave",this.tooltipElementMouseOut),this.clear()},t.prototype.onStickyClose=function(){this.close()},t.prototype.onMouseMove=function(e){var i=0,r=0;e.type.indexOf("touch")>-1?(e.preventDefault(),i=e.touches[0].pageX,r=e.touches[0].pageY):(i=e.pageX,r=e.pageY),Hs.stop(this.tooltipEle),K([this.tooltipEle],jE),V([this.tooltipEle],Xg),this.adjustArrow(e.target,this.position,this.tooltipPositionX,this.tooltipPositionY);var s=this.getScalingFactor(e.target),o=this.calculateTooltipOffset(this.position,s.x,s.y),h=this.checkCollision(e.target,i+o.left+this.offsetX,r+o.top+this.offsetY);if(this.tooltipPositionX!==h.horizontal||this.tooltipPositionY!==h.vertical){var c=0===this.position.indexOf("Bottom")||0===this.position.indexOf("Top")?h.vertical+h.horizontal:h.horizontal+h.vertical;h.position=c,this.adjustArrow(e.target,h.position,h.horizontal,h.vertical);var d=this.calculateTooltipOffset(h.position,s.x,s.y);h.left=i+d.left-this.offsetX,h.top=r+d.top-this.offsetY}this.tooltipEle.style.left=h.left+"px",this.tooltipEle.style.top=h.top+"px"},t.prototype.keyDown=function(e){this.tooltipEle&&27===e.keyCode&&this.close()},t.prototype.touchEnd=function(e){this.tooltipEle&&null===J(e.target,"."+HE)&&!this.isSticky&&this.close()},t.prototype.scrollHandler=function(e){this.tooltipEle&&!this.isSticky&&!J(e.target,"."+BE+"."+q0+"."+UE)&&!this.isSticky&&this.close()},t.prototype.render=function(){this.initialize(),this.wireEvents(this.opensOn),this.renderComplete()},t.prototype.preRender=function(){this.tipClass=Gg,this.tooltipPositionX="Center",this.tooltipPositionY="Top",this.isHidden=!0},t.prototype.wireEvents=function(e){for(var r=0,s=this.getTriggerList(e);r0)for(var i=0,r=e;i0)for(var i=0,r=e;i0&&this.condition&&-1!==this.condition.indexOf("not")&&(e[s].condition=e[s].condition?e[s].condition+"not":"not"),i=e[s].validate(t),r){if(!i)return!1}else if(i)return!0;return r},n.prototype.toJson=function(){var t,e;if(this.isComplex){t=[],e=this.predicates;for(var i=0;ie.length-3?(e=e.substring(0,e.length-1),n.endsWith(n.toLowerCase(t),n.toLowerCase(e))):(e.lastIndexOf("%")!==e.indexOf("%")&&e.lastIndexOf("%")>e.indexOf("%")+1&&(e=e.substring(e.indexOf("%")+1,e.lastIndexOf("%"))),-1!==t.indexOf(e)))},n.fnSort=function(t){return"ascending"===(t=t?n.toLowerCase(t):"ascending")?this.fnAscending:this.fnDescending},n.fnAscending=function(t,e){return m(t)&&m(e)||null==e?-1:"string"==typeof t?t.localeCompare(e):null==t?1:t-e},n.fnDescending=function(t,e){return m(t)&&m(e)?-1:null==e?1:"string"==typeof t?-1*t.localeCompare(e):null==t?-1:e-t},n.extractFields=function(t,e){for(var i={},r=0;r0||e.length>0;)o=t.length>0&&e.length>0?r?r(this.getVal(t,0,i),this.getVal(e,0,i),t[0],e[0])<=0?t:e:t[0][i]0?t:e,s.push(o.shift());return s},n.getVal=function(t,e,i){return i?this.getObject(i,t[e]):t[e]},n.toLowerCase=function(t){return t?"string"==typeof t?t.toLowerCase():t.toString():0===t||!1===t?t.toString():""},n.callAdaptorFunction=function(t,e,i,r){if(e in t){var s=t[e](i,r);m(s)||(i=s)}return i},n.getAddParams=function(t,e,i){var r={};return n.callAdaptorFunction(t,"addParams",{dm:e,query:i,params:i?i.params:[],reqParams:r}),r},n.isPlainObject=function(t){return!!t&&t.constructor===Object},n.isCors=function(){var t=null;try{t=new window.XMLHttpRequest}catch{}return!!t&&"withCredentials"in t},n.getGuid=function(t){var i;return(t||"")+"00000000-0000-4000-0000-000000000000".replace(/0/g,function(r,s){if("crypto"in window&&"getRandomValues"in crypto){var o=new Uint8Array(1);window.crypto.getRandomValues(o),i=o[0]%16|0}else i=16*Math.random()|0;return"0123456789abcdef"[19===s?3&i|8:i]})},n.isNull=function(t){return null==t},n.getItemFromComparer=function(t,e,i){var r,s,o,a=0,l="string"==typeof n.getVal(t,0,e);if(t.length)for(;m(r)&&a0&&(r=s,o=t[a]));return o},n.distinct=function(t,e,i){i=!m(i)&&i;var s,r=[],o={};return t.forEach(function(a,l){(s="object"==typeof t[l]?n.getVal(t,l,e):t[l])in o||(r.push(i?t[l]:s),o[s]=1)}),r},n.processData=function(t,e){var i=this.prepareQuery(t),r=new nt(e);t.requiresCounts&&i.requiresCount();var s=r.executeLocal(i),o={result:t.requiresCounts?s.result:s,count:s.count,aggregates:JSON.stringify(s.aggregates)};return t.requiresCounts?o:s},n.prepareQuery=function(t){var e=this,i=new jt;return t.select&&i.select(t.select),t.where&&n.parse.parseJson(t.where).filter(function(o){if(m(o.condition))i.where(o.field,o.operator,o.value,o.ignoreCase,o.ignoreAccent);else{var a=[];o.field?a.push(new Ss(o.field,o.operator,o.value,o.ignoreCase,o.ignoreAccent)):a=a.concat(e.getPredicate(o.predicates)),"or"===o.condition?i.where(Ss.or(a)):"and"===o.condition&&i.where(Ss.and(a))}}),t.search&&n.parse.parseJson(t.search).filter(function(o){return i.search(o.key,o.fields,o.operator,o.ignoreCase,o.ignoreAccent)}),t.aggregates&&t.aggregates.filter(function(o){return i.aggregate(o.type,o.field)}),t.sorted&&t.sorted.filter(function(o){return i.sortBy(o.name,o.direction)}),t.skip&&i.skip(t.skip),t.take&&i.take(t.take),t.group&&t.group.filter(function(o){return i.group(o)}),i},n.getPredicate=function(t){for(var e=[],i=0;i":"greaterthan","<=":"lessthanorequal",">=":"greaterthanorequal","==":"equal","!=":"notequal","*=":"contains","$=":"endswith","^=":"startswith"},n.odBiOperator={"<":" lt ",">":" gt ","<=":" le ",">=":" ge ","==":" eq ","!=":" ne ",lessthan:" lt ",lessthanorequal:" le ",greaterthan:" gt ",greaterthanorequal:" ge ",equal:" eq ",notequal:" ne "},n.odUniOperator={"$=":"endswith","^=":"startswith","*=":"substringof",endswith:"endswith",startswith:"startswith",contains:"substringof",doesnotendwith:"not endswith",doesnotstartwith:"not startswith",doesnotcontain:"not substringof",wildcard:"wildcard",like:"like"},n.odv4UniOperator={"$=":"endswith","^=":"startswith","*=":"contains",endswith:"endswith",startswith:"startswith",contains:"contains",doesnotendwith:"not endswith",doesnotstartwith:"not startswith",doesnotcontain:"not contains",wildcard:"wildcard",like:"like"},n.diacritics={"\u24b6":"A",\uff21:"A",\u00c0:"A",\u00c1:"A",\u00c2:"A",\u1ea6:"A",\u1ea4:"A",\u1eaa:"A",\u1ea8:"A",\u00c3:"A",\u0100:"A",\u0102:"A",\u1eb0:"A",\u1eae:"A",\u1eb4:"A",\u1eb2:"A",\u0226:"A",\u01e0:"A",\u00c4:"A",\u01de:"A",\u1ea2:"A",\u00c5:"A",\u01fa:"A",\u01cd:"A",\u0200:"A",\u0202:"A",\u1ea0:"A",\u1eac:"A",\u1eb6:"A",\u1e00:"A",\u0104:"A",\u023a:"A",\u2c6f:"A",\ua732:"AA",\u00c6:"AE",\u01fc:"AE",\u01e2:"AE",\ua734:"AO",\ua736:"AU",\ua738:"AV",\ua73a:"AV",\ua73c:"AY","\u24b7":"B",\uff22:"B",\u1e02:"B",\u1e04:"B",\u1e06:"B",\u0243:"B",\u0182:"B",\u0181:"B","\u24b8":"C",\uff23:"C",\u0106:"C",\u0108:"C",\u010a:"C",\u010c:"C",\u00c7:"C",\u1e08:"C",\u0187:"C",\u023b:"C",\ua73e:"C","\u24b9":"D",\uff24:"D",\u1e0a:"D",\u010e:"D",\u1e0c:"D",\u1e10:"D",\u1e12:"D",\u1e0e:"D",\u0110:"D",\u018b:"D",\u018a:"D",\u0189:"D",\ua779:"D",\u01f1:"DZ",\u01c4:"DZ",\u01f2:"Dz",\u01c5:"Dz","\u24ba":"E",\uff25:"E",\u00c8:"E",\u00c9:"E",\u00ca:"E",\u1ec0:"E",\u1ebe:"E",\u1ec4:"E",\u1ec2:"E",\u1ebc:"E",\u0112:"E",\u1e14:"E",\u1e16:"E",\u0114:"E",\u0116:"E",\u00cb:"E",\u1eba:"E",\u011a:"E",\u0204:"E",\u0206:"E",\u1eb8:"E",\u1ec6:"E",\u0228:"E",\u1e1c:"E",\u0118:"E",\u1e18:"E",\u1e1a:"E",\u0190:"E",\u018e:"E","\u24bb":"F",\uff26:"F",\u1e1e:"F",\u0191:"F",\ua77b:"F","\u24bc":"G",\uff27:"G",\u01f4:"G",\u011c:"G",\u1e20:"G",\u011e:"G",\u0120:"G",\u01e6:"G",\u0122:"G",\u01e4:"G",\u0193:"G",\ua7a0:"G",\ua77d:"G",\ua77e:"G","\u24bd":"H",\uff28:"H",\u0124:"H",\u1e22:"H",\u1e26:"H",\u021e:"H",\u1e24:"H",\u1e28:"H",\u1e2a:"H",\u0126:"H",\u2c67:"H",\u2c75:"H",\ua78d:"H","\u24be":"I",\uff29:"I",\u00cc:"I",\u00cd:"I",\u00ce:"I",\u0128:"I",\u012a:"I",\u012c:"I",\u0130:"I",\u00cf:"I",\u1e2e:"I",\u1ec8:"I",\u01cf:"I",\u0208:"I",\u020a:"I",\u1eca:"I",\u012e:"I",\u1e2c:"I",\u0197:"I","\u24bf":"J",\uff2a:"J",\u0134:"J",\u0248:"J","\u24c0":"K",\uff2b:"K",\u1e30:"K",\u01e8:"K",\u1e32:"K",\u0136:"K",\u1e34:"K",\u0198:"K",\u2c69:"K",\ua740:"K",\ua742:"K",\ua744:"K",\ua7a2:"K","\u24c1":"L",\uff2c:"L",\u013f:"L",\u0139:"L",\u013d:"L",\u1e36:"L",\u1e38:"L",\u013b:"L",\u1e3c:"L",\u1e3a:"L",\u0141:"L",\u023d:"L",\u2c62:"L",\u2c60:"L",\ua748:"L",\ua746:"L",\ua780:"L",\u01c7:"LJ",\u01c8:"Lj","\u24c2":"M",\uff2d:"M",\u1e3e:"M",\u1e40:"M",\u1e42:"M",\u2c6e:"M",\u019c:"M","\u24c3":"N",\uff2e:"N",\u01f8:"N",\u0143:"N",\u00d1:"N",\u1e44:"N",\u0147:"N",\u1e46:"N",\u0145:"N",\u1e4a:"N",\u1e48:"N",\u0220:"N",\u019d:"N",\ua790:"N",\ua7a4:"N",\u01ca:"NJ",\u01cb:"Nj","\u24c4":"O",\uff2f:"O",\u00d2:"O",\u00d3:"O",\u00d4:"O",\u1ed2:"O",\u1ed0:"O",\u1ed6:"O",\u1ed4:"O",\u00d5:"O",\u1e4c:"O",\u022c:"O",\u1e4e:"O",\u014c:"O",\u1e50:"O",\u1e52:"O",\u014e:"O",\u022e:"O",\u0230:"O",\u00d6:"O",\u022a:"O",\u1ece:"O",\u0150:"O",\u01d1:"O",\u020c:"O",\u020e:"O",\u01a0:"O",\u1edc:"O",\u1eda:"O",\u1ee0:"O",\u1ede:"O",\u1ee2:"O",\u1ecc:"O",\u1ed8:"O",\u01ea:"O",\u01ec:"O",\u00d8:"O",\u01fe:"O",\u0186:"O",\u019f:"O",\ua74a:"O",\ua74c:"O",\u01a2:"OI",\ua74e:"OO",\u0222:"OU","\u24c5":"P",\uff30:"P",\u1e54:"P",\u1e56:"P",\u01a4:"P",\u2c63:"P",\ua750:"P",\ua752:"P",\ua754:"P","\u24c6":"Q",\uff31:"Q",\ua756:"Q",\ua758:"Q",\u024a:"Q","\u24c7":"R",\uff32:"R",\u0154:"R",\u1e58:"R",\u0158:"R",\u0210:"R",\u0212:"R",\u1e5a:"R",\u1e5c:"R",\u0156:"R",\u1e5e:"R",\u024c:"R",\u2c64:"R",\ua75a:"R",\ua7a6:"R",\ua782:"R","\u24c8":"S",\uff33:"S",\u1e9e:"S",\u015a:"S",\u1e64:"S",\u015c:"S",\u1e60:"S",\u0160:"S",\u1e66:"S",\u1e62:"S",\u1e68:"S",\u0218:"S",\u015e:"S",\u2c7e:"S",\ua7a8:"S",\ua784:"S","\u24c9":"T",\uff34:"T",\u1e6a:"T",\u0164:"T",\u1e6c:"T",\u021a:"T",\u0162:"T",\u1e70:"T",\u1e6e:"T",\u0166:"T",\u01ac:"T",\u01ae:"T",\u023e:"T",\ua786:"T",\ua728:"TZ","\u24ca":"U",\uff35:"U",\u00d9:"U",\u00da:"U",\u00db:"U",\u0168:"U",\u1e78:"U",\u016a:"U",\u1e7a:"U",\u016c:"U",\u00dc:"U",\u01db:"U",\u01d7:"U",\u01d5:"U",\u01d9:"U",\u1ee6:"U",\u016e:"U",\u0170:"U",\u01d3:"U",\u0214:"U",\u0216:"U",\u01af:"U",\u1eea:"U",\u1ee8:"U",\u1eee:"U",\u1eec:"U",\u1ef0:"U",\u1ee4:"U",\u1e72:"U",\u0172:"U",\u1e76:"U",\u1e74:"U",\u0244:"U","\u24cb":"V",\uff36:"V",\u1e7c:"V",\u1e7e:"V",\u01b2:"V",\ua75e:"V",\u0245:"V",\ua760:"VY","\u24cc":"W",\uff37:"W",\u1e80:"W",\u1e82:"W",\u0174:"W",\u1e86:"W",\u1e84:"W",\u1e88:"W",\u2c72:"W","\u24cd":"X",\uff38:"X",\u1e8a:"X",\u1e8c:"X","\u24ce":"Y",\uff39:"Y",\u1ef2:"Y",\u00dd:"Y",\u0176:"Y",\u1ef8:"Y",\u0232:"Y",\u1e8e:"Y",\u0178:"Y",\u1ef6:"Y",\u1ef4:"Y",\u01b3:"Y",\u024e:"Y",\u1efe:"Y","\u24cf":"Z",\uff3a:"Z",\u0179:"Z",\u1e90:"Z",\u017b:"Z",\u017d:"Z",\u1e92:"Z",\u1e94:"Z",\u01b5:"Z",\u0224:"Z",\u2c7f:"Z",\u2c6b:"Z",\ua762:"Z","\u24d0":"a",\uff41:"a",\u1e9a:"a",\u00e0:"a",\u00e1:"a",\u00e2:"a",\u1ea7:"a",\u1ea5:"a",\u1eab:"a",\u1ea9:"a",\u00e3:"a",\u0101:"a",\u0103:"a",\u1eb1:"a",\u1eaf:"a",\u1eb5:"a",\u1eb3:"a",\u0227:"a",\u01e1:"a",\u00e4:"a",\u01df:"a",\u1ea3:"a",\u00e5:"a",\u01fb:"a",\u01ce:"a",\u0201:"a",\u0203:"a",\u1ea1:"a",\u1ead:"a",\u1eb7:"a",\u1e01:"a",\u0105:"a",\u2c65:"a",\u0250:"a",\ua733:"aa",\u00e6:"ae",\u01fd:"ae",\u01e3:"ae",\ua735:"ao",\ua737:"au",\ua739:"av",\ua73b:"av",\ua73d:"ay","\u24d1":"b",\uff42:"b",\u1e03:"b",\u1e05:"b",\u1e07:"b",\u0180:"b",\u0183:"b",\u0253:"b","\u24d2":"c",\uff43:"c",\u0107:"c",\u0109:"c",\u010b:"c",\u010d:"c",\u00e7:"c",\u1e09:"c",\u0188:"c",\u023c:"c",\ua73f:"c",\u2184:"c","\u24d3":"d",\uff44:"d",\u1e0b:"d",\u010f:"d",\u1e0d:"d",\u1e11:"d",\u1e13:"d",\u1e0f:"d",\u0111:"d",\u018c:"d",\u0256:"d",\u0257:"d",\ua77a:"d",\u01f3:"dz",\u01c6:"dz","\u24d4":"e",\uff45:"e",\u00e8:"e",\u00e9:"e",\u00ea:"e",\u1ec1:"e",\u1ebf:"e",\u1ec5:"e",\u1ec3:"e",\u1ebd:"e",\u0113:"e",\u1e15:"e",\u1e17:"e",\u0115:"e",\u0117:"e",\u00eb:"e",\u1ebb:"e",\u011b:"e",\u0205:"e",\u0207:"e",\u1eb9:"e",\u1ec7:"e",\u0229:"e",\u1e1d:"e",\u0119:"e",\u1e19:"e",\u1e1b:"e",\u0247:"e",\u025b:"e",\u01dd:"e","\u24d5":"f",\uff46:"f",\u1e1f:"f",\u0192:"f",\ua77c:"f","\u24d6":"g",\uff47:"g",\u01f5:"g",\u011d:"g",\u1e21:"g",\u011f:"g",\u0121:"g",\u01e7:"g",\u0123:"g",\u01e5:"g",\u0260:"g",\ua7a1:"g",\u1d79:"g",\ua77f:"g","\u24d7":"h",\uff48:"h",\u0125:"h",\u1e23:"h",\u1e27:"h",\u021f:"h",\u1e25:"h",\u1e29:"h",\u1e2b:"h",\u1e96:"h",\u0127:"h",\u2c68:"h",\u2c76:"h",\u0265:"h",\u0195:"hv","\u24d8":"i",\uff49:"i",\u00ec:"i",\u00ed:"i",\u00ee:"i",\u0129:"i",\u012b:"i",\u012d:"i",\u00ef:"i",\u1e2f:"i",\u1ec9:"i",\u01d0:"i",\u0209:"i",\u020b:"i",\u1ecb:"i",\u012f:"i",\u1e2d:"i",\u0268:"i",\u0131:"i","\u24d9":"j",\uff4a:"j",\u0135:"j",\u01f0:"j",\u0249:"j","\u24da":"k",\uff4b:"k",\u1e31:"k",\u01e9:"k",\u1e33:"k",\u0137:"k",\u1e35:"k",\u0199:"k",\u2c6a:"k",\ua741:"k",\ua743:"k",\ua745:"k",\ua7a3:"k","\u24db":"l",\uff4c:"l",\u0140:"l",\u013a:"l",\u013e:"l",\u1e37:"l",\u1e39:"l",\u013c:"l",\u1e3d:"l",\u1e3b:"l",\u017f:"l",\u0142:"l",\u019a:"l",\u026b:"l",\u2c61:"l",\ua749:"l",\ua781:"l",\ua747:"l",\u01c9:"lj","\u24dc":"m",\uff4d:"m",\u1e3f:"m",\u1e41:"m",\u1e43:"m",\u0271:"m",\u026f:"m","\u24dd":"n",\uff4e:"n",\u01f9:"n",\u0144:"n",\u00f1:"n",\u1e45:"n",\u0148:"n",\u1e47:"n",\u0146:"n",\u1e4b:"n",\u1e49:"n",\u019e:"n",\u0272:"n",\u0149:"n",\ua791:"n",\ua7a5:"n",\u01cc:"nj","\u24de":"o",\uff4f:"o",\u00f2:"o",\u00f3:"o",\u00f4:"o",\u1ed3:"o",\u1ed1:"o",\u1ed7:"o",\u1ed5:"o",\u00f5:"o",\u1e4d:"o",\u022d:"o",\u1e4f:"o",\u014d:"o",\u1e51:"o",\u1e53:"o",\u014f:"o",\u022f:"o",\u0231:"o",\u00f6:"o",\u022b:"o",\u1ecf:"o",\u0151:"o",\u01d2:"o",\u020d:"o",\u020f:"o",\u01a1:"o",\u1edd:"o",\u1edb:"o",\u1ee1:"o",\u1edf:"o",\u1ee3:"o",\u1ecd:"o",\u1ed9:"o",\u01eb:"o",\u01ed:"o",\u00f8:"o",\u01ff:"o",\u0254:"o",\ua74b:"o",\ua74d:"o",\u0275:"o",\u01a3:"oi",\u0223:"ou",\ua74f:"oo","\u24df":"p",\uff50:"p",\u1e55:"p",\u1e57:"p",\u01a5:"p",\u1d7d:"p",\ua751:"p",\ua753:"p",\ua755:"p","\u24e0":"q",\uff51:"q",\u024b:"q",\ua757:"q",\ua759:"q","\u24e1":"r",\uff52:"r",\u0155:"r",\u1e59:"r",\u0159:"r",\u0211:"r",\u0213:"r",\u1e5b:"r",\u1e5d:"r",\u0157:"r",\u1e5f:"r",\u024d:"r",\u027d:"r",\ua75b:"r",\ua7a7:"r",\ua783:"r","\u24e2":"s",\uff53:"s",\u00df:"s",\u015b:"s",\u1e65:"s",\u015d:"s",\u1e61:"s",\u0161:"s",\u1e67:"s",\u1e63:"s",\u1e69:"s",\u0219:"s",\u015f:"s",\u023f:"s",\ua7a9:"s",\ua785:"s",\u1e9b:"s","\u24e3":"t",\uff54:"t",\u1e6b:"t",\u1e97:"t",\u0165:"t",\u1e6d:"t",\u021b:"t",\u0163:"t",\u1e71:"t",\u1e6f:"t",\u0167:"t",\u01ad:"t",\u0288:"t",\u2c66:"t",\ua787:"t",\ua729:"tz","\u24e4":"u",\uff55:"u",\u00f9:"u",\u00fa:"u",\u00fb:"u",\u0169:"u",\u1e79:"u",\u016b:"u",\u1e7b:"u",\u016d:"u",\u00fc:"u",\u01dc:"u",\u01d8:"u",\u01d6:"u",\u01da:"u",\u1ee7:"u",\u016f:"u",\u0171:"u",\u01d4:"u",\u0215:"u",\u0217:"u",\u01b0:"u",\u1eeb:"u",\u1ee9:"u",\u1eef:"u",\u1eed:"u",\u1ef1:"u",\u1ee5:"u",\u1e73:"u",\u0173:"u",\u1e77:"u",\u1e75:"u",\u0289:"u","\u24e5":"v",\uff56:"v",\u1e7d:"v",\u1e7f:"v",\u028b:"v",\ua75f:"v",\u028c:"v",\ua761:"vy","\u24e6":"w",\uff57:"w",\u1e81:"w",\u1e83:"w",\u0175:"w",\u1e87:"w",\u1e85:"w",\u1e98:"w",\u1e89:"w",\u2c73:"w","\u24e7":"x",\uff58:"x",\u1e8b:"x",\u1e8d:"x","\u24e8":"y",\uff59:"y",\u1ef3:"y",\u00fd:"y",\u0177:"y",\u1ef9:"y",\u0233:"y",\u1e8f:"y",\u00ff:"y",\u1ef7:"y",\u1e99:"y",\u1ef5:"y",\u01b4:"y",\u024f:"y",\u1eff:"y","\u24e9":"z",\uff5a:"z",\u017a:"z",\u1e91:"z",\u017c:"z",\u017e:"z",\u1e93:"z",\u1e95:"z",\u01b6:"z",\u0225:"z",\u0240:"z",\u2c6c:"z",\ua763:"z",\u0386:"\u0391",\u0388:"\u0395",\u0389:"\u0397",\u038a:"\u0399",\u03aa:"\u0399",\u038c:"\u039f",\u038e:"\u03a5",\u03ab:"\u03a5",\u038f:"\u03a9",\u03ac:"\u03b1",\u03ad:"\u03b5",\u03ae:"\u03b7",\u03af:"\u03b9",\u03ca:"\u03b9",\u0390:"\u03b9",\u03cc:"\u03bf",\u03cd:"\u03c5",\u03cb:"\u03c5",\u03b0:"\u03c5",\u03c9:"\u03c9",\u03c2:"\u03c3"},n.fnOperators={equal:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?n.toLowerCase(t)===n.toLowerCase(e):t===e},notequal:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),!n.fnOperators.equal(t,e,i)},lessthan:function(t,e,i){return i?n.toLowerCase(t)n.toLowerCase(e):t>e},lessthanorequal:function(t,e,i){return i?n.toLowerCase(t)<=n.toLowerCase(e):(m(t)&&(t=void 0),t<=e)},greaterthanorequal:function(t,e,i){return i?n.toLowerCase(t)>=n.toLowerCase(e):t>=e},contains:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?!m(t)&&!m(e)&&-1!==n.toLowerCase(t).indexOf(n.toLowerCase(e)):!m(t)&&!m(e)&&-1!==t.toString().indexOf(e)},doesnotcontain:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?!m(t)&&!m(e)&&-1===n.toLowerCase(t).indexOf(n.toLowerCase(e)):!m(t)&&!m(e)&&-1===t.toString().indexOf(e)},isnotnull:function(t){return null!=t},isnull:function(t){return null==t},startswith:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.startsWith(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.startsWith(t,e)},doesnotstartwith:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.notStartsWith(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.notStartsWith(t,e)},like:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.like(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.like(t,e)},isempty:function(t){return void 0===t||""===t},isnotempty:function(t){return void 0!==t&&""!==t},wildcard:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?(t||"boolean"==typeof t)&&e&&"object"!=typeof t&&n.wildCard(n.toLowerCase(t),n.toLowerCase(e)):(t||"boolean"==typeof t)&&e&&n.wildCard(t,e)},endswith:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.endsWith(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.endsWith(t,e)},doesnotendwith:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.notEndsWith(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.notEndsWith(t,e)},processSymbols:function(t){var e=n.operatorSymbols[t];return e?n.fnOperators[e]:n.throwError("Query - Process Operator : Invalid operator")},processOperator:function(t){return n.fnOperators[t]||n.fnOperators.processSymbols(t)}},n.parse={parseJson:function(t){return"string"!=typeof t||!/^[\s]*\[|^[\s]*\{(.)+:/g.test(t)&&-1!==t.indexOf('"')?t instanceof Array?n.parse.iterateAndReviveArray(t):"object"==typeof t&&null!==t&&n.parse.iterateAndReviveJson(t):t=JSON.parse(t,n.parse.jsonReviver),t},iterateAndReviveArray:function(t){for(var e=0;e-1||e.indexOf("z")>-1,o=e.split(/[^0-9.]/);if(s){if(o[5].indexOf(".")>-1){var a=o[5].split(".");o[5]=a[0],o[6]=new Date(e).getUTCMilliseconds().toString()}else o[6]="00";e=n.dateParse.toTimeZone(new Date(parseInt(o[0],10),parseInt(o[1],10)-1,parseInt(o[2],10),parseInt(o[3],10),parseInt(o[4],10),parseInt(o[5]?o[5]:"00",10),parseInt(o[6],10)),n.serverTimezoneOffset,!1)}else{var l=new Date(parseInt(o[0],10),parseInt(o[1],10)-1,parseInt(o[2],10),parseInt(o[3],10),parseInt(o[4],10),parseInt(o[5]?o[5]:"00",10)),h=parseInt(o[6],10),c=parseInt(o[7],10);if(isNaN(h)&&isNaN(c))return l;e.indexOf("+")>-1?l.setHours(l.getHours()-h,l.getMinutes()-c):l.setHours(l.getHours()+h,l.getMinutes()+c),e=n.dateParse.toTimeZone(l,n.serverTimezoneOffset,!1)}null==n.serverTimezoneOffset&&(e=n.dateParse.addSelfOffset(e))}}return e},isJson:function(t){return"string"==typeof t[0]?t:n.parse.parseJson(t)},isGuid:function(t){return null!=/[A-Fa-f0-9]{8}(?:-[A-Fa-f0-9]{4}){3}-[A-Fa-f0-9]{12}/i.exec(t)},replacer:function(t,e){return n.isPlainObject(t)?n.parse.jsonReplacer(t,e):t instanceof Array?n.parse.arrayReplacer(t):t instanceof Date?n.parse.jsonReplacer({val:t},e).val:t},jsonReplacer:function(t,e){for(var i,s=0,o=Object.keys(t);s=0?"+":"-",s=function(a){var l=Math.floor(Math.abs(a));return(l<10?"0":"")+l};return e.getFullYear()+"-"+s(e.getMonth()+1)+"-"+s(e.getDate())+"T"+s(e.getHours())+":"+s(e.getMinutes())+":"+s(e.getSeconds())+r+s(i/60)+":"+s(i%60)}},n}(),bl=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),AK={GroupGuid:"{271bbba0-1ee7}"},t5=function(){function n(t){this.options={from:"table",requestType:"json",sortBy:"sorted",select:"select",skip:"skip",group:"group",take:"take",search:"search",count:"requiresCounts",where:"where",aggregates:"aggregates",expand:"expand"},this.type=n,this.dataSource=t,this.pvt={}}return n.prototype.processResponse=function(t,e,i,r){return t},n}(),YE=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return bl(t,n),t.prototype.processQuery=function(e,i){for(var a,l,p,r=e.dataSource.json.slice(0),s=r.length,o=!0,h={},c=0,d=[],u=[],f=0;f1?e.sort.filter(function(p){return p.fieldName===c})[0]:e.sort[0];s=this.onSortBy(s,d,e.query,!0)}e.page&&(s=this.onPage(s,e.page,e.query)),this.formGroupResult(s,h)}else{for(var o=e.lazyLoad.onDemandGroupInfo,a=o.where.length-1;a>=0;a--)s=this.onWhere(s,o.where[a]);if(e.group.length!==o.level)s=le.group(s,e.group[o.level].fieldName,r,null,null,e.group[o.level].comparer,!0),e.sort.length&&(s=this.onSortBy(s,e.sort[parseInt(o.level.toString(),10)],e.query,!0));else for(a=e.sort.length-1;a>=o.level;a--)s=this.onSortBy(s,e.sort[parseInt(a.toString(),10)],e.query,!1);i=s.length,h=s,s=(s=s.slice(o.skip)).slice(0,o.take),e.group.length!==o.level&&this.formGroupResult(s,h)}return{result:s,count:i}},t.prototype.formGroupResult=function(e,i){if(e.length&&i.length){var r="GroupGuid",s="childLevels",o="level",a="records";e[r]=i[r],e[s]=i[s],e[o]=i[o],e[a]=i[a]}return e},t.prototype.getAggregate=function(e){var i=jt.filterQueries(e.queries,"onAggregates"),r=[];if(i.length)for(var s=void 0,o=0;o=0;l--)a[l]&&(o=i.comparer,le.endsWith(a[l]," desc")&&(o=le.fnSort("descending"),a[l]=a[l].replace(" desc","")),e=le.sort(e,a[l],o));return e}return le.sort(e,s?"key":a,i.comparer)},t.prototype.onGroup=function(e,i,r){if(!e||!e.length)return e;var s=this.getAggregate(r);return le.group(e,le.getValue(i.fieldName,r),s,null,null,i.comparer)},t.prototype.onPage=function(e,i,r){var s=le.getValue(i.pageSize,r),o=(le.getValue(i.pageIndex,r)-1)*s;return e&&e.length?e.slice(o,o+s):e},t.prototype.onRange=function(e,i){return e&&e.length?e.slice(le.getValue(i.start),le.getValue(i.end)):e},t.prototype.onTake=function(e,i){return e&&e.length?e.slice(0,le.getValue(i.nos)):e},t.prototype.onSkip=function(e,i){return e&&e.length?e.slice(le.getValue(i.nos)):e},t.prototype.onSelect=function(e,i){return e&&e.length?le.select(e,le.getValue(i.fieldNames)):e},t.prototype.insert=function(e,i,r,s,o){return m(o)?e.dataSource.json.push(i):e.dataSource.json.splice(o,0,i)},t.prototype.remove=function(e,i,r,s){var a,o=e.dataSource.json;for("object"==typeof r&&!(r instanceof Date)&&(r=le.getObject(i,r)),a=0;a1&&(g="("+g+")"),p.filters.push(g);for(var y=0,S="object"==typeof p.filters[f]?Object.keys(p.filters[f]):[];y-1&&this.formRemoteGroupedData(e[s].items,i+1,r-1);var o="GroupGuid",h="records";return e[o]=AK[o],e.level=i,e.childLevels=r,e[h]=e[0].items.length?this.getGroupedRecords(e,!m(e[0].items[h])):[],e},t.prototype.getGroupedRecords=function(e,i){for(var r=[],o=0;ol.length-3?(l=l.substring(0,l.length-1),o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.endswith:le.odv4UniOperator.endswith):l.lastIndexOf("%")!==l.indexOf("%")&&l.lastIndexOf("%")>l.indexOf("%")+1?(l=l.substring(l.indexOf("%")+1,l.lastIndexOf("%")),o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains):o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains),l="'"+(l=encodeURIComponent(l))+"'";else if("wildcard"===o)if(-1!==l.indexOf("*")){var d=l.split("*"),u=void 0,p=0;if(0!==l.indexOf("*")&&-1===d[0].indexOf("%3f")&&-1===d[0].indexOf("?")&&(u="'"+(u=d[0])+"'",s+=(o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.startswith:le.odv4UniOperator.startswith)+"(",s+=c+",",a&&(s+=a),s+=u+")",p++),l.lastIndexOf("*")!==l.length-1&&-1===d[d.length-1].indexOf("%3f")&&-1===d[d.length-1].indexOf("?")&&(u="'"+(u=d[d.length-1])+"'",p>0&&(s+=" and "),s+=(o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.endswith:le.odv4UniOperator.endswith)+"(",s+=c+",",a&&(s+=a),s+=u+")",p++),d.length>2)for(var f=1;f0&&(s+=" and "),"substringof"===(o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains)||"not substringof"===o){var g=u;u=c,c=g}s+=o+"(",s+=c+",",a&&(s+=a),s+=u+")",p++}0===p?(o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains,(-1!==l.indexOf("?")||-1!==l.indexOf("%3f"))&&(l=-1!==l.indexOf("?")?l.split("?").join(""):l.split("%3f").join("")),l="'"+l+"'"):o="wildcard"}else o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains,(-1!==l.indexOf("?")||-1!==l.indexOf("%3f"))&&(l=-1!==l.indexOf("?")?l.split("?").join(""):l.split("%3f").join("")),l="'"+l+"'";return"substringof"!==o&&"not substringof"!==o||(g=l,l=c,c=g),"wildcard"!==o&&(s+=o+"(",s+=c+",",a&&(s+=a),s+=l+")"),s},t.prototype.addParams=function(e){n.prototype.addParams.call(this,e),delete e.reqParams.params},t.prototype.onComplexPredicate=function(e,i,r){for(var s=[],o=0;o-1;p--)!/\bContent-ID:/i.test(c[p])||!/\bHTTP.+201/.test(c[p])||(l=parseInt(/\bContent-ID: (\d+)/i.exec(c[p])[1],10),o.addedRecords[l]&&(h=le.parse.parseJson(/^\{.+\}/m.exec(c[p])[0]),ze({},o.addedRecords[l],this.processResponse(h))));return o}return null},t.prototype.compareAndRemove=function(e,i,r){var s=this;return m(i)||Object.keys(e).forEach(function(o){o!==r&&"@odata.etag"!==o&&(le.isPlainObject(e[o])?(s.compareAndRemove(e[o],i[o]),0===Object.keys(e[o]).filter(function(l){return"@odata.etag"!==l}).length&&delete e[o]):(e[o]===i[o]||e[o]&&i[o]&&e[o].valueOf()===i[o].valueOf())&&delete e[o])}),e},t}(uc),LK=function(n){function t(){var e=n.call(this)||this;return yt("beforeSend",uc.prototype.beforeSend,e),e}return bl(t,n),t.prototype.insert=function(e,i,r,s,o){return this.pvt.position=o,this.updateType="add",{url:e.dataSource.insertUrl||e.dataSource.crudUrl||e.dataSource.url,data:JSON.stringify(ze({},{value:i,table:r,action:"insert"},le.getAddParams(this,e,s)))}},t.prototype.remove=function(e,i,r,s,o){return n.prototype.remove.call(this,e,i,r),{type:"POST",url:e.dataSource.removeUrl||e.dataSource.crudUrl||e.dataSource.url,data:JSON.stringify(ze({},{key:r,keyColumn:i,table:s,action:"remove"},le.getAddParams(this,e,o)))}},t.prototype.update=function(e,i,r,s,o){return this.updateType="update",this.updateKey=i,{type:"POST",url:e.dataSource.updateUrl||e.dataSource.crudUrl||e.dataSource.url,data:JSON.stringify(ze({},{value:r,action:"update",keyColumn:i,key:r[i],table:s},le.getAddParams(this,e,o)))}},t.prototype.processResponse=function(e,i,r,s,o,a,l){var h;if(e="batch"===(o?JSON.parse(o.data):e).action?le.parse.parseJson(e):e,"add"===this.updateType&&n.prototype.insert.call(this,i,e,null,null,this.pvt.position),"update"===this.updateType&&n.prototype.update.call(this,i,this.updateKey,e),this.updateType=void 0,e.added)for(h=0;hi&&h.push(c)}for(c=0;cthis.pageSize;)h.results.splice(0,1),h.keys.splice(0,1);return window.localStorage.setItem(this.guidId,JSON.stringify(h)),e},t.prototype.beforeSend=function(e,i,r){!m(this.cacheAdaptor.options.batch)&&le.endsWith(r.url,this.cacheAdaptor.options.batch)&&"post"===r.type.toLowerCase()&&i.headers.set("Accept",this.cacheAdaptor.options.multipartAccept),e.dataSource.crossDomain||i.headers.set("Accept",this.cacheAdaptor.options.accept)},t.prototype.update=function(e,i,r,s){return this.isCrudAction=!0,this.cacheAdaptor.update(e,i,r,s)},t.prototype.insert=function(e,i,r){return this.isInsertAction=!0,this.cacheAdaptor.insert(e,i,r)},t.prototype.remove=function(e,i,r,s){return this.isCrudAction=!0,this.cacheAdaptor.remove(e,i,r,s)},t.prototype.batchRequest=function(e,i,r){return this.cacheAdaptor.batchRequest(e,i,r)},t}(uc),nt=function(){function n(t,e,i){var s,r=this;return this.dateParse=!0,this.timeZoneHandling=!0,this.persistQuery={},this.isInitialLoad=!1,this.requests=[],this.isInitialLoad=!0,!t&&!this.dataSource&&(t=[]),i=i||t.adaptor,t&&!1===t.timeZoneHandling&&(this.timeZoneHandling=t.timeZoneHandling),t instanceof Array?s={json:t,offline:!0}:"object"==typeof t?(t.json||(t.json=[]),t.enablePersistence||(t.enablePersistence=!1),t.id||(t.id=""),t.ignoreOnPersist||(t.ignoreOnPersist=[]),s={url:t.url,insertUrl:t.insertUrl,removeUrl:t.removeUrl,updateUrl:t.updateUrl,crudUrl:t.crudUrl,batchUrl:t.batchUrl,json:t.json,headers:t.headers,accept:t.accept,data:t.data,timeTillExpiration:t.timeTillExpiration,cachingPageSize:t.cachingPageSize,enableCaching:t.enableCaching,requestType:t.requestType,key:t.key,crossDomain:t.crossDomain,jsonp:t.jsonp,dataType:t.dataType,offline:void 0!==t.offline?t.offline:!(t.adaptor instanceof LK||t.adaptor instanceof NK||t.url),requiresFormat:t.requiresFormat,enablePersistence:t.enablePersistence,id:t.id,ignoreOnPersist:t.ignoreOnPersist}):le.throwError("DataManager: Invalid arguments"),void 0===s.requiresFormat&&!le.isCors()&&(s.requiresFormat=!!m(s.crossDomain)||s.crossDomain),void 0===s.dataType&&(s.dataType="json"),this.dataSource=s,this.defaultQuery=e,this.dataSource.enablePersistence&&this.dataSource.id&&window.addEventListener("unload",this.setPersistData.bind(this)),s.url&&s.offline&&!s.json.length?(this.isDataAvailable=!1,this.adaptor=i||new fp,this.dataSource.offline=!1,this.ready=this.executeQuery(e||new jt),this.ready.then(function(o){r.dataSource.offline=!0,r.isDataAvailable=!0,s.json=o.result,r.adaptor=new YE})):this.adaptor=s.offline?new YE:new fp,!s.jsonp&&this.adaptor instanceof fp&&(s.jsonp="callback"),this.adaptor=i||this.adaptor,s.enableCaching&&(this.adaptor=new OK(this.adaptor,s.timeTillExpiration,s.cachingPageSize)),this}return Object.defineProperty(n.prototype,"moduleName",{get:function(){return"datamanager"},enumerable:!0,configurable:!0}),n.prototype.getPersistedData=function(t){var e=localStorage.getItem(t||this.dataSource.id);return JSON.parse(e)},n.prototype.setPersistData=function(t,e,i){localStorage.setItem(e||this.dataSource.id,JSON.stringify(i||this.persistQuery))},n.prototype.setPersistQuery=function(t){var e=this,i=this.getPersistedData();if(this.isInitialLoad&&i&&Object.keys(i).length){this.persistQuery=i,this.persistQuery.queries=this.persistQuery.queries.filter(function(s){if(e.dataSource.ignoreOnPersist&&e.dataSource.ignoreOnPersist.length&&s.fn&&e.dataSource.ignoreOnPersist.some(function(l){return s.fn===l}))return!1;if("onWhere"===s.fn){var o=s.e;if(o&&o.isComplex&&o.predicates instanceof Array){var a=o.predicates.map(function(l){if(l.predicates&&l.predicates instanceof Array){var h=l.predicates.map(function(v){return new Ss(v.field,v.operator,v.value,v.ignoreCase,v.ignoreAccent,v.matchCase)});return"and"===l.condition?Ss.and(h):Ss.or(h)}return new Ss(l.field,l.operator,l.value,l.ignoreCase,l.ignoreAccent,l.matchCase)});s.e=new Ss(a[0],o.condition,a.slice(1))}}return!0});var r=ze(new jt,this.persistQuery);return this.isInitialLoad=!1,r}return this.persistQuery=t,this.isInitialLoad=!1,t},n.prototype.setDefaultQuery=function(t){return this.defaultQuery=t,this},n.prototype.executeLocal=function(t){!this.defaultQuery&&!(t instanceof jt)&&le.throwError("DataManager - executeLocal() : A query is required to execute"),this.dataSource.json||le.throwError("DataManager - executeLocal() : Json data is required to execute"),this.dataSource.enablePersistence&&this.dataSource.id&&(t=this.setPersistQuery(t));var e=this.adaptor.processQuery(this,t=t||this.defaultQuery);if(t.subQuery){var i=t.subQuery.fromTable,r=t.subQuery.lookups,s=t.isCountRequired?e.result:e;r&&r instanceof Array&&le.buildHierarchy(t.subQuery.fKey,i,s,r,t.subQuery.key);for(var o=0;oli");P.classList.remove("json-parent");for(var j=0;j',W=ve.children[0].placeholder}return W}function Q(k,W,ve){!m(ve)&&""!==ve&&K(W,ve.split(" ")),!m(k)&&""!==k&&V(W,k.split(" "))}function oe(k,W,ve){if("multiselect"===ve||function Mo(k){if(!k)return!1;for(var W=k;W&&W!==document.body;){if("none"===window.getComputedStyle(W).display)return!1;W=W.parentElement}return!0}(k)){var Te="multiselect"===ve?k:k.clientWidth-parseInt(getComputedStyle(k,null).getPropertyValue("padding-left"),10);!m(W)&&!m(W.getElementsByClassName("e-float-text-content")[0])&&(W.getElementsByClassName("e-float-text-content")[0].classList.contains("e-float-text-overflow")&&W.getElementsByClassName("e-float-text-content")[0].classList.remove("e-float-text-overflow"),(Te0)for(var Ye=0;Ye<_e.length;Ye++)_e[parseInt(Ye.toString(),10)].addEventListener("mousedown",wo,!1),_e[parseInt(Ye.toString(),10)].addEventListener("mouseup",Hl,!1);else if(_e.length>0)for(Ye=0;Ye<_e.length;Ye++)_e[parseInt(Ye.toString(),10)].removeEventListener("mousedown",wo,this),_e[parseInt(Ye.toString(),10)].removeEventListener("mouseup",Hl,this)}function wo(){for(var W=this.parentElement;!W.classList.contains("e-input-group");)W=W.parentElement;!function ya(k,W){!k.classList.contains("e-disabled")&&!k.querySelector("input").readOnly&&W.classList.add("e-input-btn-ripple")}(W,this)}function Hl(){var k=this;setTimeout(function(){k.classList.remove("e-input-btn-ripple")},500)}function mb(k,W){var ve=W("span",{className:k});return ve.classList.add("e-input-group-icon"),ve}function I_(k,W,ve,Te){var _e=m(Te)?mi:Te,Ye=mb(k,_e);W.classList.add("e-float-icon-left");var fi=W.querySelector(".e-input-in-wrap");if(m(fi)){fi=_e("span",{className:"e-input-in-wrap"}),ve.parentNode.insertBefore(fi,ve);var Gs=W.querySelectorAll(ve.tagName+" ~ *");fi.appendChild(ve);for(var Kn=0;Kn-1)if("class"===_e){var Ye=this.getInputValidClassList(k[""+_e]);""!==Ye&&V([W],Ye.split(" "))}else if("style"===_e){var fi=W.getAttribute(_e);fi=m(fi)?k[""+_e]:fi+k[""+_e],W.setAttribute(_e,fi)}else W.setAttribute(_e,k[""+_e])}},n.isBlank=function Hle(k){return!k||/^\s*$/.test(k)}}(Le||(Le={})),new RegExp("^(-)?(\\d*)$"),new RegExp("^[A-Za-z0-9._%+-]{1,}@[A-Za-z0-9._%+-]{1,}([.]{1}[a-zA-Z0-9]{2,}|[.]{1}[a-zA-Z0-9]{2,4}[.]{1}[a-zA-Z0-9]{2,4})$"),new RegExp("^([0-9]{4})-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])$"),new RegExp("^[0-9]*$"),new RegExp("^[+]?[0-9]{9,13}$"),new RegExp("^\\d{13,16}$");var me=function(){function n(t,e){this.width=t,this.height=e}return n.prototype.isEmpty=function(){return 0===this.height&&0===this.width},n.prototype.clone=function(){return new n(this.width,this.height)},n}(),xie=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),GB=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},z=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return xie(t,n),t.equals=function(e,i){return e===i||!(!e||!i)&&(!e||!i||e.x===i.x&&e.y===i.y)},t.isEmptyPoint=function(e){return!(e.x&&e.y)},t.transform=function(e,i,r){var s={x:0,y:0};return s.x=Math.round(100*(e.x+r*Math.cos(i*Math.PI/180)))/100,s.y=Math.round(100*(e.y+r*Math.sin(i*Math.PI/180)))/100,s},t.findLength=function(e,i){return Math.sqrt(Math.pow(e.x-i.x,2)+Math.pow(e.y-i.y,2))},t.findAngle=function(e,i){var r=Math.atan2(i.y-e.y,i.x-e.x);return r=180*r/Math.PI,(r%=360)<0&&(r+=360),r},t.distancePoints=function(e,i){return Math.sqrt(Math.pow(i.x-e.x,2)+Math.pow(i.y-e.y,2))},t.getLengthFromListOfPoints=function(e){for(var i=0,r=0;ri.y&&!r?o.y+=s:o.y-=s:e.y===i.y?e.xi.x&&!r?o.x+=s:o.x-=s:r?(a=this.findAngle(e,i),o=this.transform(e,a,s)):(a=this.findAngle(i,e),o=this.transform(i,a,s)),o},t.direction=function(e,i){return Math.abs(i.x-e.x)>Math.abs(i.y-e.y)?e.x0)for(var r=0;rt.right||this.top>t.bottom||this.bottom=t.right&&this.top<=t.top&&this.bottom>=t.bottom},n.prototype.containsPoint=function(t,e){return void 0===e&&(e=0),this.left-e<=t.x&&this.right+e>=t.x&&this.top-e<=t.y&&this.bottom+e>=t.y},n.toBounds=function(t){for(var e=new n,i=0,r=t;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},KB=function(n){if(n)switch(n.type){case"Linear":default:return SI;case"Radial":return Bie}return SI},Rie=function(){return function n(t,e,i,r){this.left=t,this.right=e,this.top=i,this.bottom=r}}(),$n=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),it([I(0)],t.prototype,"left",void 0),it([I(0)],t.prototype,"right",void 0),it([I(0)],t.prototype,"top",void 0),it([I(0)],t.prototype,"bottom",void 0),t}(Ee),Hie=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),it([I(45)],t.prototype,"angle",void 0),it([I(5)],t.prototype,"distance",void 0),it([I(.7)],t.prototype,"opacity",void 0),it([I("lightgrey")],t.prototype,"color",void 0),t}(Ee),e3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),t.prototype.getClassName=function(){return"Stop"},it([I("")],t.prototype,"color",void 0),it([I(0)],t.prototype,"offset",void 0),it([I(1)],t.prototype,"opacity",void 0),t}(Ee),Mx=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),it([Bt([],e3)],t.prototype,"stops",void 0),it([I("None")],t.prototype,"type",void 0),it([I("")],t.prototype,"id",void 0),t}(Ee),SI=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),it([I(0)],t.prototype,"x1",void 0),it([I(0)],t.prototype,"x2",void 0),it([I(0)],t.prototype,"y1",void 0),it([I(0)],t.prototype,"y2",void 0),t}(Mx),Bie=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),it([I(0)],t.prototype,"cx",void 0),it([I(0)],t.prototype,"cy",void 0),it([I(0)],t.prototype,"fx",void 0),it([I(0)],t.prototype,"fy",void 0),it([I(50)],t.prototype,"r",void 0),t}(Mx),Al=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),it([I("white")],t.prototype,"fill",void 0),it([I("black")],t.prototype,"strokeColor",void 0),it([I("")],t.prototype,"strokeDashArray",void 0),it([I(1)],t.prototype,"strokeWidth",void 0),it([I(1)],t.prototype,"opacity",void 0),it([x0(KB)],t.prototype,"gradient",void 0),t}(Ee),t3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),it([I("transparent")],t.prototype,"fill",void 0),t}(Al),Gp=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),it([I("black")],t.prototype,"color",void 0),it([I("Arial")],t.prototype,"fontFamily",void 0),it([I(12)],t.prototype,"fontSize",void 0),it([I(!1)],t.prototype,"italic",void 0),it([I(!1)],t.prototype,"bold",void 0),it([I("CollapseSpace")],t.prototype,"whiteSpace",void 0),it([I("WrapWithOverflow")],t.prototype,"textWrapping",void 0),it([I("Center")],t.prototype,"textAlign",void 0),it([I("None")],t.prototype,"textDecoration",void 0),it([I("Wrap")],t.prototype,"textOverflow",void 0),it([I("transparent")],t.prototype,"fill",void 0),t}(Al),on=function(n){return n[n.Default=0]="Default",n[n.expandNode=2]="expandNode",n[n.interaction=4]="interaction",n[n.GroupingInProgress=8]="GroupingInProgress",n[n.GroupClipboardInProcess=16]="GroupClipboardInProcess",n[n.ClearObject=32]="ClearObject",n}(on||{}),Gt=function(n){return n[n.Visible=1]="Visible",n[n.Hidden=2]="Hidden",n[n.Hover=4]="Hover",n[n.Connect=8]="Connect",n}(Gt||{}),ei=function(n){return n[n.None=0]="None",n[n.ShowHorizontalLines=1]="ShowHorizontalLines",n[n.ShowVerticalLines=2]="ShowVerticalLines",n[n.ShowLines=3]="ShowLines",n[n.SnapToHorizontalLines=4]="SnapToHorizontalLines",n[n.SnapToVerticalLines=8]="SnapToVerticalLines",n[n.SnapToLines=12]="SnapToLines",n[n.SnapToObject=16]="SnapToObject",n[n.All=31]="All",n}(ei||{}),mr=function(n){return n[n.None=1]="None",n[n.ConnectorSourceThumb=2]="ConnectorSourceThumb",n[n.ConnectorTargetThumb=4]="ConnectorTargetThumb",n[n.ResizeSouthEast=8]="ResizeSouthEast",n[n.ResizeSouthWest=16]="ResizeSouthWest",n[n.ResizeNorthEast=32]="ResizeNorthEast",n[n.ResizeNorthWest=64]="ResizeNorthWest",n[n.ResizeEast=128]="ResizeEast",n[n.ResizeWest=256]="ResizeWest",n[n.ResizeSouth=512]="ResizeSouth",n[n.ResizeNorth=1024]="ResizeNorth",n[n.Rotate=2048]="Rotate",n[n.UserHandle=4096]="UserHandle",n[n.ToolTip=8192]="ToolTip",n[n.ResizeAll=2046]="ResizeAll",n[n.All=16382]="All",n}(mr||{}),qe=function(n){return n[n.None=1]="None",n[n.Select=2]="Select",n[n.Delete=4]="Delete",n[n.Drag=8]="Drag",n[n.DragSourceEnd=16]="DragSourceEnd",n[n.DragTargetEnd=32]="DragTargetEnd",n[n.DragSegmentThumb=64]="DragSegmentThumb",n[n.AllowDrop=128]="AllowDrop",n[n.Bridging=256]="Bridging",n[n.BridgeObstacle=512]="BridgeObstacle",n[n.InheritBridging=1024]="InheritBridging",n[n.PointerEvents=2048]="PointerEvents",n[n.Tooltip=4096]="Tooltip",n[n.InheritTooltip=8192]="InheritTooltip",n[n.Interaction=4218]="Interaction",n[n.ReadOnly=16384]="ReadOnly",n[n.LineRouting=32768]="LineRouting",n[n.InheritLineRouting=65536]="InheritLineRouting",n[n.ConnectToNearByNode=131072]="ConnectToNearByNode",n[n.ConnectToNearByPort=262144]="ConnectToNearByPort",n[n.ConnectToNearByElement=393216]="ConnectToNearByElement",n[n.InheritSegmentThumbShape=524288]="InheritSegmentThumbShape",n[n.InheritSegmentThumbSize=1048576]="InheritSegmentThumbSize",n[n.Default=2043454]="Default",n}(qe||{}),Lr=function(n){return n[n.ReadOnly=2]="ReadOnly",n[n.InheritReadOnly=4]="InheritReadOnly",n[n.Select=8]="Select",n[n.Drag=16]="Drag",n[n.Resize=32]="Resize",n[n.Rotate=64]="Rotate",n[n.Tooltip=128]="Tooltip",n[n.Interaction=120]="Interaction",n[n.None=0]="None",n}(Lr||{}),ie=function(n){return n[n.None=0]="None",n[n.Select=2]="Select",n[n.Drag=4]="Drag",n[n.Rotate=8]="Rotate",n[n.Shadow=16]="Shadow",n[n.PointerEvents=32]="PointerEvents",n[n.Delete=64]="Delete",n[n.InConnect=128]="InConnect",n[n.OutConnect=256]="OutConnect",n[n.Individual=512]="Individual",n[n.Expandable=1024]="Expandable",n[n.AllowDrop=2048]="AllowDrop",n[n.Inherit=78]="Inherit",n[n.ResizeNorthEast=4096]="ResizeNorthEast",n[n.ResizeEast=8192]="ResizeEast",n[n.ResizeSouthEast=16384]="ResizeSouthEast",n[n.ResizeSouth=32768]="ResizeSouth",n[n.ResizeSouthWest=65536]="ResizeSouthWest",n[n.ResizeWest=131072]="ResizeWest",n[n.ResizeNorthWest=262144]="ResizeNorthWest",n[n.ResizeNorth=524288]="ResizeNorth",n[n.Resize=1044480]="Resize",n[n.AspectRatio=1048576]="AspectRatio",n[n.Tooltip=2097152]="Tooltip",n[n.InheritTooltip=4194304]="InheritTooltip",n[n.ReadOnly=8388608]="ReadOnly",n[n.HideThumbs=16777216]="HideThumbs",n[n.AllowMovingOutsideLane=33554432]="AllowMovingOutsideLane",n[n.Default=5240814]="Default",n}(ie||{}),Xr=function(n){return n[n.None=0]="None",n[n.ElementIsPort=2]="ElementIsPort",n[n.ElementIsGroup=4]="ElementIsGroup",n[n.HorizontalLaneHeader=8]="HorizontalLaneHeader",n}(Xr||{}),bt=function(n){return n[n.Rotate=2]="Rotate",n[n.ConnectorSource=4]="ConnectorSource",n[n.ConnectorTarget=8]="ConnectorTarget",n[n.ResizeNorthEast=16]="ResizeNorthEast",n[n.ResizeEast=32]="ResizeEast",n[n.ResizeSouthEast=64]="ResizeSouthEast",n[n.ResizeSouth=128]="ResizeSouth",n[n.ResizeSouthWest=256]="ResizeSouthWest",n[n.ResizeWest=512]="ResizeWest",n[n.ResizeNorthWest=1024]="ResizeNorthWest",n[n.ResizeNorth=2048]="ResizeNorth",n[n.Default=4094]="Default",n}(bt||{}),rt=function(n){return n[n.None=1]="None",n[n.Bridging=2]="Bridging",n[n.UndoRedo=4]="UndoRedo",n[n.Tooltip=8]="Tooltip",n[n.UserInteraction=16]="UserInteraction",n[n.ApiUpdate=32]="ApiUpdate",n[n.PageEditable=48]="PageEditable",n[n.Zoom=64]="Zoom",n[n.PanX=128]="PanX",n[n.PanY=256]="PanY",n[n.Pan=384]="Pan",n[n.ZoomTextEdit=512]="ZoomTextEdit",n[n.Virtualization=1024]="Virtualization",n[n.LineRouting=2048]="LineRouting",n[n.Default=500]="Default",n}(rt||{}),Ci=function(n){return n[n.None=0]="None",n[n.SingleSelect=1]="SingleSelect",n[n.MultipleSelect=2]="MultipleSelect",n[n.ZoomPan=4]="ZoomPan",n[n.DrawOnce=8]="DrawOnce",n[n.ContinuousDraw=16]="ContinuousDraw",n[n.Default=3]="Default",n}(Ci||{}),Ya=function(n){return n[n.Self=1]="Self",n[n.Parent=2]="Parent",n}(Ya||{}),pt=function(n){return n[n.None=0]="None",n[n.Control=1]="Control",n[n.Meta=1]="Meta",n[n.Alt=2]="Alt",n[n.Shift=4]="Shift",n}(pt||{}),Mt=function(n){return n[n.None=null]="None",n[n.Number0=0]="Number0",n[n.Number1=1]="Number1",n[n.Number2=2]="Number2",n[n.Number3=3]="Number3",n[n.Number4=4]="Number4",n[n.Number5=5]="Number5",n[n.Number6=6]="Number6",n[n.Number7=7]="Number7",n[n.Number8=8]="Number8",n[n.Number9=9]="Number9",n[n.A=65]="A",n[n.B=66]="B",n[n.C=67]="C",n[n.D=68]="D",n[n.E=69]="E",n[n.F=70]="F",n[n.G=71]="G",n[n.H=72]="H",n[n.I=73]="I",n[n.J=74]="J",n[n.K=75]="K",n[n.L=76]="L",n[n.M=77]="M",n[n.N=78]="N",n[n.O=79]="O",n[n.P=80]="P",n[n.Q=81]="Q",n[n.R=82]="R",n[n.S=83]="S",n[n.T=84]="T",n[n.U=85]="U",n[n.V=86]="V",n[n.W=87]="W",n[n.X=88]="X",n[n.Y=89]="Y",n[n.Z=90]="Z",n[n.Left=37]="Left",n[n.Up=38]="Up",n[n.Right=39]="Right",n[n.Down=40]="Down",n[n.Escape=27]="Escape",n[n.Space=32]="Space",n[n.PageUp=33]="PageUp",n[n.PageDown=34]="PageDown",n[n.End=35]="End",n[n.Home=36]="Home",n[n.Delete=46]="Delete",n[n.Tab=9]="Tab",n[n.Enter=13]="Enter",n[n.BackSpace=8]="BackSpace",n[n.F1=112]="F1",n[n.F2=113]="F2",n[n.F3=114]="F3",n[n.F4=115]="F4",n[n.F5=116]="F5",n[n.F6=117]="F6",n[n.F7=118]="F7",n[n.F8=119]="F8",n[n.F9=120]="F9",n[n.F10=121]="F10",n[n.F11=122]="F11",n[n.F12=123]="F12",n[n.Star=56]="Star",n[n.Plus=187]="Plus",n[n.Minus=189]="Minus",n[n.BracketLeft=219]="BracketLeft",n[n.BracketRight=221]="BracketRight",n}(Mt||{}),ee=function(n){return n[n.Render=2]="Render",n[n.PublicMethod=4]="PublicMethod",n[n.ToolAction=8]="ToolAction",n[n.UndoRedo=16]="UndoRedo",n[n.TextEdit=32]="TextEdit",n[n.Group=64]="Group",n[n.Clear=128]="Clear",n[n.PreventClearSelection=256]="PreventClearSelection",n[n.Interactions=512]="Interactions",n[n.PreventHistory=1024]="PreventHistory",n[n.PreventIconsUpdate=2048]="PreventIconsUpdate",n[n.PreventCollectionChangeOnDragOver=4096]="PreventCollectionChangeOnDragOver",n[n.PreventZIndexOnDragging=8192]="PreventZIndexOnDragging",n[n.isGroupDragging=16384]="isGroupDragging",n[n.DragUsingMouse=32768]="DragUsingMouse",n[n.DecoratorPropertyChange=65536]="DecoratorPropertyChange",n[n.PreventLaneContainerUpdate=131072]="PreventLaneContainerUpdate",n}(ee||{}),Qa=function(n){return n[n.None=2]="None",n[n.DrawSelectorBorder=4]="DrawSelectorBorder",n[n.PreventRenderSelector=8]="PreventRenderSelector",n}(Qa||{}),$i=function(n){return n[n.None=0]="None",n[n.PreventDrag=2]="PreventDrag",n[n.PreventScale=4]="PreventScale",n[n.PreventDataInit=8]="PreventDataInit",n[n.hScrollbarMoved=16]="hScrollbarMoved",n[n.vScrollbarMoved=32]="vScrollbarMoved",n[n.AnimationClick=64]="AnimationClick",n[n.EnableGroupAction=128]="EnableGroupAction",n[n.PanInProgress=256]="PanInProgress",n[n.OverViewAction=512]="OverViewAction",n}($i||{}),ca=function(n){return n[n.None=0]="None",n[n.PropertyChange=1024]="PropertyChange",n[n.Interaction=2048]="Interaction",n}(ca||{}),Ae=function(n){return n[n.Zero=0]="Zero",n[n.One=1]="One",n[n.Two=2]="Two",n[n.Three=3]="Three",n[n.Four=4]="Four",n[n.Five=5]="Five",n}(Ae||{}),Ce=function(n){return n[n.collectionChange=0]="collectionChange",n[n.rotateChange=1]="rotateChange",n[n.positionChange=2]="positionChange",n[n.propertyChange=3]="propertyChange",n[n.selectionChange=4]="selectionChange",n[n.sizeChange=5]="sizeChange",n[n.drop=6]="drop",n[n.sourcePointChange=7]="sourcePointChange",n[n.targetPointChange=8]="targetPointChange",n[n.connectionChange=9]="connectionChange",n[n.animationComplete=10]="animationComplete",n[n.click=11]="click",n[n.doubleClick=12]="doubleClick",n[n.scrollChange=13]="scrollChange",n[n.dragEnter=14]="dragEnter",n[n.dragLeave=15]="dragLeave",n[n.dragOver=16]="dragOver",n[n.textEdit=17]="textEdit",n[n.paletteSelectionChange=18]="paletteSelectionChange",n[n.historyChange=19]="historyChange",n[n.mouseEnter=20]="mouseEnter",n[n.mouseLeave=21]="mouseLeave",n[n.mouseOver=22]="mouseOver",n[n.expandStateChange=23]="expandStateChange",n[n.segmentCollectionChange=24]="segmentCollectionChange",n[n.commandExecute=25]="commandExecute",n[n.historyStateChange=26]="historyStateChange",n[n.onUserHandleMouseDown=27]="onUserHandleMouseDown",n[n.onUserHandleMouseUp=28]="onUserHandleMouseUp",n[n.onUserHandleMouseEnter=29]="onUserHandleMouseEnter",n[n.onUserHandleMouseLeave=30]="onUserHandleMouseLeave",n[n.onImageLoad=31]="onImageLoad",n[n.onDoBindingInit=32]="onDoBindingInit",n[n.keyUp=33]="keyUp",n[n.keyDown=34]="keyDown",n[n.fixedUserHandleClick=35]="fixedUserHandleClick",n[n.elementDraw=36]="elementDraw",n[n.mouseWheel=37]="mouseWheel",n[n.segmentChange=38]="segmentChange",n[n.onFixedUserHandleMouseDown=39]="onFixedUserHandleMouseDown",n[n.onFixedUserHandleMouseUp=40]="onFixedUserHandleMouseUp",n[n.onFixedUserHandleMouseEnter=41]="onFixedUserHandleMouseEnter",n[n.onFixedUserHandleMouseLeave=42]="onFixedUserHandleMouseLeave",n[n.loaded=43]="loaded",n}(Ce||{}),ni=function(n){return n[n.None=1]="None",n[n.Drag=2]="Drag",n[n.Draw=4]="Draw",n[n.InConnect=8]="InConnect",n[n.OutConnect=16]="OutConnect",n[n.ToolTip=32]="ToolTip",n[n.InheritTooltip=64]="InheritTooltip",n[n.Default=24]="Default",n}(ni||{}),wx=function(n){return n[n.None=1]="None",n[n.Source=2]="Source",n[n.Target=4]="Target",n[n.Intermediate=8]="Intermediate",n[n.All=14]="All",n}(wx||{}),II=function(n){return n[n.None=0]="None",n[n.SymmetricAngle=2]="SymmetricAngle",n[n.SymmetricDistance=4]="SymmetricDistance",n[n.Default=6]="Default",n}(II||{}),as=function(){function n(){this.pivot={x:.5,y:.5},this.isDirt=!0,this.isExport=!1,this.exportScaleValue={x:0,y:0},this.exportScaleOffset={x:0,y:0},this.canApplyStyle=!0,this.visible=!0,this.offsetX=0,this.offsetY=0,this.cornerRadius=0,this.minHeight=void 0,this.minWidth=void 0,this.maxWidth=void 0,this.maxHeight=void 0,this.width=void 0,this.height=void 0,this.rotateAngle=0,this.margin={left:0,right:0,top:0,bottom:0},this.connectionDirection="Auto",this.horizontalAlignment="Auto",this.verticalAlignment="Auto",this.flip="None",this.flipMode="All",this.relativeMode="Point",this.transform=Ya.Self|Ya.Parent,this.style={fill:"white",strokeColor:"black",opacity:1,strokeWidth:1},this.desiredSize=new me,this.actualSize=new me,this.parentTransform=0,this.preventContainer=!1,this.isSvgRender=!1,this.bounds=new Ne(0,0,0,0),this.shadow=null,this.description="",this.staticSize=!1,this.shapeType="",this.isRectElement=!1,this.isCalculateDesiredSize=!0,this.flipOffset={x:0,y:0},this.elementActions=Xr.None,this.inversedAlignment=!0,this.position=void 0,this.unitMode=void 0,this.float=!1,this.floatingBounds=void 0}return n.prototype.setOffsetWithRespectToBounds=function(t,e,i){this.unitMode=i,this.position={x:t,y:e}},n.prototype.getAbsolutePosition=function(t){if(void 0!==this.position)return"Absolute"===this.unitMode?this.position:{x:this.position.x*t.width,y:this.position.y*t.height}},Object.defineProperty(n.prototype,"outerBounds",{get:function(){return this.floatingBounds||this.bounds},set:function(t){this.floatingBounds=t},enumerable:!0,configurable:!0}),n.prototype.measure=function(t,e,i){var s=void 0!==this.height?this.height:(t.height||0)-this.margin.top-this.margin.bottom;return this.id&&0===s&&this.elementActions&Xr.HorizontalLaneHeader&&(s=this.actualSize.height),this.desiredSize=new me(void 0!==this.width?this.width:(t.width||0)-this.margin.left-this.margin.right,s),this.isCalculateDesiredSize&&(this.desiredSize=this.validateDesiredSize(this.desiredSize,t)),this.desiredSize},n.prototype.arrange=function(t){return this.actualSize=t,this.updateBounds(),this.actualSize},n.prototype.updateBounds=function(){this.bounds=yr(this)},n.prototype.validateDesiredSize=function(t,e){return this.isRectElement&&!this.width&&!this.minWidth&&!this.maxWidth&&(t.width=50),this.isRectElement&&!this.height&&!this.minHeight&&!this.maxHeight&&(t.height=50),(void 0===t||void 0!==this.width&&void 0!==this.height)&&((t=t||new me).width=void 0===this.width?(e.width||0)-this.margin.left-this.margin.right:this.width,t.height=void 0===this.height?(e.height||0)-this.margin.top-this.margin.bottom:this.height),void 0!==this.minWidth&&(t.width=Math.max(t.width,this.minWidth)),void 0!==this.minHeight&&(t.height=Math.max(t.height,this.minHeight)),void 0!==this.maxWidth&&0!==this.maxWidth&&(t.width=Math.min(t.width,this.maxWidth)),void 0!==this.maxHeight&&0!==this.maxHeight&&(t.height=Math.min(t.height,this.maxHeight)),t},n}(),Yie=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Cs=function(n){function t(){var e=null!==n&&n.apply(this,arguments)||this;return e.padding=new Rie(0,0,0,0),e.desiredBounds=void 0,e.measureChildren=!0,e.prevRotateAngle=0,e}return Yie(t,n),t.prototype.hasChildren=function(){return void 0!==this.children&&this.children.length>0},t.prototype.measure=function(e,i,r){this.desiredBounds=void 0;var o,a,s=void 0;if(this.hasChildren()){for(var l=0;l=n.width&&s.length>0)i[i.length]={text:s,x:0,dy:0,width:o},s="";else{(s+=a[r+1]||"").indexOf("\n")>-1&&(i[i.length]={text:s,x:0,dy:0,width:Bc(s,n)},s="");var l=Bc(s,n);Math.ceil(l)+2>=n.width&&s.length>0&&(i[i.length]={text:s,x:0,dy:0,width:l},s=""),r===a.length-1&&s.length>0&&(i[i.length]={text:s,x:0,dy:0,width:l},s="")}else i=function coe(n,t,e){var c,d,u,p,i=[],r="",s=0,o=0,a="nowrap"!==n.whiteSpace,h=(t||n.content).split("\n");for(s=0;s0?" ":"")+c[parseInt(o.toString(),10)];var f=Bc(d=c[o+1]?r+" "+c[o+1]:r,n);Math.floor(f)>(e||n.width)-2&&r.length>0?(i[i.length]={text:r,x:0,dy:0,width:d===r?f:r===p?u:Bc(r,n)},r=""):o===c.length-1&&(i[i.length]={text:r,x:0,dy:0,width:f},r=""),p=d,u=f}return i}(n,t,e);else i[i.length]={text:a,x:0,dy:0,width:Bc(a,n)};return i}(l,r,n.isLaneOrientation?i:void 0),n.wrapBounds=a=function doe(n,t){var r,s,e={x:0,width:0},i=0;for(i=0;in.width&&("Ellipsis"===n.textOverflow||"Clip"===n.textOverflow)?0:-r/2:"right"===n.textAlign?-r:t.length>1?0:-r/2,t[parseInt(i.toString(),10)].dy=1.2*n.fontSize,t[parseInt(i.toString(),10)].x=r,e.x=Math.min(e.x,r),e.width=Math.max(e.width,s);return e}(l,o),s.width=a.width,n.wrapBounds.width>=i&&"Wrap"!==l.textOverflow&&(s.width=i),s.height=o.length*n.style.fontSize*1.2,s}(this,0,0,this.isLaneOrientation?e.height:this.width||e.width):this.desiredSize,this.desiredSize=void 0===this.width||void 0===this.height?new me(i.width,i.height):new me(this.width,this.height),this.desiredSize=this.validateDesiredSize(this.desiredSize,e),this.desiredSize},t.prototype.arrange=function(e){return(e.width!==this.actualSize.width||e.height!==this.actualSize.height||this.isDirt)&&(this.doWrap=!0),this.actualSize=e,this.updateBounds(),this.isDirt=!1,this.actualSize},t}(as),Gie=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Ii=function(n){function t(){var e=null!==n&&n.apply(this,arguments)||this;return e.measureChildren=void 0,e}return Gie(t,n),t.prototype.measure=function(e,i,r){var s=void 0,o=void 0;if(this.hasChildren()){for(var a=0,l=this.children;a=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},xd=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Jie(t,n),Th([I("")],t.prototype,"content",void 0),Th([I("TopLeft")],t.prototype,"position",void 0),Th([I("Mouse")],t.prototype,"relativeMode",void 0),Th([I(!0)],t.prototype,"showTipPointer",void 0),Th([I("auto")],t.prototype,"width",void 0),Th([I("auto")],t.prototype,"height",void 0),Th([I("Auto")],t.prototype,"openOn",void 0),Th([I()],t.prototype,"animation",void 0),Th([I(!1)],t.prototype,"isSticky",void 0),t}(Ee);function i3(n){var t=new mh;t=r3(n.tooltip,t);var e=new mh(t);return e.beforeCollision=ere,e.beforeOpen=Kie,e.cssClass="e-diagram-tooltip",e.opensOn="custom",e.appendTo("#"+n.element.id),e.close(),e}function Kie(n){(""===this.content||void 0===this.content)&&(n.element.style.display="none")}function ere(n){n.collidedPosition&&n.collidedPosition!==this.position&&(n.element.style.display="none")}function Cx(n,t){var e=n.tooltipObject;return r3(t?t.tooltip:n.tooltip,e),e}function r3(n,t){return n.content?(t.content=n.content,"string"==typeof n.content&&(t.content=ko(function(){return n.content})),t.position=n.position,t.showTipPointer=n.showTipPointer,t.width=n.width,t.height=n.height,t.animation=n.animation?n.animation:{close:{effect:"None"}}):t.close(),t}var Ex=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Hn=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Dx=function(n){function t(e,i,r,s){var o=n.call(this,e,i,r,s)||this;return o.inEdges=[],o.outEdges=[],o}return Ex(t,n),Hn([I("")],t.prototype,"id",void 0),Hn([I("Center")],t.prototype,"horizontalAlignment",void 0),Hn([I("Center")],t.prototype,"verticalAlignment",void 0),Hn([re({},$n)],t.prototype,"margin",void 0),Hn([I(12)],t.prototype,"width",void 0),Hn([I(12)],t.prototype,"height",void 0),Hn([re({},Al)],t.prototype,"style",void 0),Hn([I("Square")],t.prototype,"shape",void 0),Hn([I("Auto")],t.prototype,"connectionDirection",void 0),Hn([I(Gt.Connect)],t.prototype,"visibility",void 0),Hn([I("")],t.prototype,"pathData",void 0),Hn([I(ni.Default)],t.prototype,"constraints",void 0),Hn([I()],t.prototype,"addInfo",void 0),Hn([I()],t.prototype,"outEdges",void 0),Hn([I()],t.prototype,"inEdges",void 0),Hn([re({},xd)],t.prototype,"tooltip",void 0),t}(Ee),Es=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return Ex(t,n),t.prototype.getClassName=function(){return"PointPort"},Hn([re({x:.5,y:.5},z)],t.prototype,"offset",void 0),t}(Dx),xc=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return Ex(t,n),t.prototype.getClassName=function(){return"PathPort"},Hn([I(.5)],t.prototype,"offset",void 0),Hn([re({x:0,y:0},z)],t.prototype,"displacement",void 0),Hn([I("Center")],t.prototype,"alignment",void 0),t}(Dx),wI=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),lr=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},tre=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return wI(t,n),lr([I("blue")],t.prototype,"color",void 0),lr([I("")],t.prototype,"content",void 0),lr([I("")],t.prototype,"link",void 0),lr([I("None")],t.prototype,"textDecoration",void 0),lr([I("NewTab")],t.prototype,"hyperlinkOpenState",void 0),t}(Ee),xx=function(n){function t(e,i,r,s){var o=n.call(this,e,i,r,s)||this;return r.id||(o.id=e.parentObj&&e.parentObj.propName&&"phases"===e.parentObj.propName?e.parentObj.id:Qe()),o}return wI(t,n),lr([I("")],t.prototype,"content",void 0),lr([I(void 0)],t.prototype,"template",void 0),lr([I("String")],t.prototype,"annotationType",void 0),lr([I(!0)],t.prototype,"visibility",void 0),lr([I(Lr.InheritReadOnly)],t.prototype,"constraints",void 0),lr([re(void 0,tre)],t.prototype,"hyperlink",void 0),lr([I("")],t.prototype,"id",void 0),lr([I()],t.prototype,"width",void 0),lr([I()],t.prototype,"height",void 0),lr([I(0)],t.prototype,"rotateAngle",void 0),lr([I("Parent")],t.prototype,"rotationReference",void 0),lr([re({strokeWidth:0,strokeColor:"transparent",fill:"transparent"},Gp)],t.prototype,"style",void 0),lr([I("Center")],t.prototype,"horizontalAlignment",void 0),lr([I("Center")],t.prototype,"verticalAlignment",void 0),lr([re({},$n)],t.prototype,"margin",void 0),lr([re({top:void 0,bottom:void 0,left:void 0,right:void 0},$n)],t.prototype,"dragLimit",void 0),lr([I("Shape")],t.prototype,"type",void 0),lr([re({},xd)],t.prototype,"tooltip",void 0),lr([I()],t.prototype,"addInfo",void 0),t}(Ee),Zn=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return wI(t,n),t.prototype.getClassName=function(){return"ShapeAnnotation"},lr([re({x:.5,y:.5},z)],t.prototype,"offset",void 0),t}(xx),Nr=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return wI(t,n),t.prototype.getClassName=function(){return"PathAnnotation"},lr([I(.5)],t.prototype,"offset",void 0),lr([re({x:0,y:0},z)],t.prototype,"displacement",void 0),lr([I("Center")],t.prototype,"alignment",void 0),lr([I(!1)],t.prototype,"segmentAngle",void 0),t}(xx);function Tx(n){return sre[n.toString()]}function n3(n){return lre[""+n]}var sre={X:"M14,14 L106,106 M106,14 L14,106",Circle:"M0,50 A50,50,0 1 1 100,50 A50,50,0 1 1 0,50 Z",Square:"M0,0 L10,0 L10,10 L0,10 z"},ore={OpenArrow:"M15.9,23 L5,16 L15.9,9 L17,10.7 L8.7,16 L17,21.3Z",Square:"M0,0 L10,0 L10,10 L0,10 z",Fletch:"M14.8,10c0,0-3.5,6,0.2,12c0,0-2.5-6-10.9-6C4.1,16,11.3,16,14.8,10z",OpenFetch:"M6,17c-0.6,0-1-0.4-1-1s0.4-1,1-1c10.9,0,11-5,11-5c0-0.6,0.4-1,1-1s1,0.4,1,1C19,10.3,18.9,17,6,17C6,17,6,17,6,17z M18,23c-0.5,0-1-0.4-1-1c0-0.2-0.3-5-11-5c-0.6,0-1-0.5-1-1s0.4-1,1-1c0,0,0,0,0,0c12.9,0,13,6.7,13,7 C19,22.6,18.6,23,18,23z",IndentedArrow:"M17,10c0,0-4.5,5.5,0,12L5,16L17,10z",OutdentedArrow:"M14.6,10c0,0,5.4,6,0,12L5,16L14.6,10z",DoubleArrow:"M19,10 L19,22 L13,16Z M12,10 L12,22 L6,16Z",Arrow:"M15,10 L15,22 L5,16Z",Diamond:"M12,23l-7-7l7-7l6.9,7L12,23z",Circle:"M0,50 A50,50,0 1 1 100,50 A50,50,0 1 1 0,50 Z"},are={Square:"M0,0 L10,0 L10,10 L0,10 z",Rhombus:"M10,5 L5,10 L0,5 L5,0 L10,5 Z ",Rectangle:"M0,0 L15,0 L15,10 L0,10 z ",OpenArrow:"M15.9,23 L5,16 L15.9,9 L17,10.7 L8.7,16 L17,21.3Z",Fletch:"M9.82,0 C9.82,0,6.61,5,10,10 C10,10,7.71,5,0,5 C0,5,6.61,5,9.82,0 Z ",OpenFetch:"M0.71,5.71 C0.29,5.71,0,5.43,0,5 C0,4.57,0.29,4.29,0.71,4.29 C8.5,4.29,8.57,0.71,8.57,0.71 C8.57,0.29,8.86,0,9.29,0 C9.719999999999999,0,10,0.29,10,0.71 C10,0.93,9.93,5.71,0.71,5.71 C0.71,5.71,0.71,5.71,0.71,5.71 Z M9.29,10 C8.93,10,8.57,9.71,8.57,9.29 C8.57,9.14,8.36,5.71,0.71,5.71 C0.29,5.71,0,5.36,0,5 C0,4.64,0.29,4.29,0.71,4.29 C0.71,4.29,0.71,4.29,0.71,4.29 C9.93,4.29,10,9.07,10,9.29 C10,9.71,9.71,10,9.29,10 Z ",IndentedArrow:"M10,0 C10,0,6.25,4.58,10,10 L0,5 L10,0 Z ",OutdentedArrow:"M8,0 C8,0,12.5,5,8,10 L0,5 L8,0 Z ",DoubleArrow:"M19,10 L19,22 L13,16Z M12,10 L12,22 L6,16Z",Arrow:"M15,10 L15,22 L5,16Z",Diamond:"M10,5 L5,10 L0,5 L5,0 L10,5 Z ",Circle:"M10,5 C10,7.76,7.76,10,5,10 C2.24,10,0,7.76,0,5 C0,2.24,2.24,0,5,0 C7.76,0,10,2.24,10,5 Z ",Ellipse:"M15,5 C15,7.76,11.64,10,7.5,10 C3.36,10,0,7.76,0,5 C0,2.24,3.36,0,7.5,0 C11.64,0,15,2.24,15,5 Z "},lre={Square:"M0,0 L10,0 L10,10 L0,10 z",Rhombus:"M10,5 L5,10 L0,5 L5,0 L10,5 Z ",Rectangle:"M0,0 L15,0 L15,10 L0,10 z",OpenArrow:"M23,15.9 L16,5 L9,15.9 L10.7,17 L16,8.7 L21,17.3Z",Fletch:"M9.82,0 C9.82,0,6.61,5,10,10 C10,10,7.71,5,0,5 C0,5,6.61,5,9.82,0 Z ",OpenFetch:"M0.71,5.71 C0.29,5.71,0,5.43,0,5 C0,4.57,0.29,4.29,0.71,4.29 C8.5,4.29,8.57,0.71,8.57,0.71 C8.57,0.29,8.86,0,9.29,0 C9.719999999999999,0,10,0.29,10,0.71 C10,0.93,9.93,5.71,0.71,5.71 C0.71,5.71,0.71,5.71,0.71,5.71 Z M9.29,10 C8.93,10,8.57,9.71,8.57,9.29 C8.57,9.14,8.36,5.71,0.71,5.71 C0.29,5.71,0,5.36,0,5 C0,4.64,0.29,4.29,0.71,4.29 C0.71,4.29,0.71,4.29,0.71,4.29 C9.93,4.29,10,9.07,10,9.29 C10,9.71,9.71,10,9.29,10 Z ",IndentedArrow:"M10,0 C10,0,6.25,4.58,10,10 L0,5 L10,0 Z ",OutdentedArrow:"M8,0 C8,0,12.5,5,8,10 L0,5 L8,0 Z ",DoubleArrow:"M10,19 L22,19 L16,13Z M10,12 L22,12 L16,6Z",Arrow:"M10,15 L22,15 L16,5Z",Diamond:"M10,5 L5,10 L0,5 L5,0 L10,5 Z ",Circle:"M10,5 C10,7.76,7.76,10,5,10 C2.24,10,0,7.76,0,5 C0,2.24,2.24,0,5,0 C7.76,0,10,2.24,10,5 Z ",Ellipse:"M15,5 C15,7.76,11.64,10,7.5,10 C3.36,10,0,7.76,0,5 C0,2.24,3.36,0,7.5,0 C11.64,0,15,2.24,15,5 Z "};function Ax(n){return hre[n.toString()]}var hre={Process:"M419.511,76.687L359.511,76.687L359.511,43.086L419.511,43.086z",Decision:"M 253.005,115.687L 200.567,146.071L 148.097,115.687L 200.534,85.304L 253.005,115.687 Z",Document:"M 60 31.9 c 0 0 -11 -7.7 -30 0 s -30 0 -30 0 V 0 h 60 V 31.9 Z",PreDefinedProcess:"M 0,0 L 50,0 L 50,50 L 0,50 Z M 8.334,0 L 8.334,50 M 41.667,0 L 41.667,50",Terminator:"M 269.711,29.33C 269.71,44.061 257.77,56 243.04,56L 158.058,56C 143.33,56 131.39,44.061 131.39,29.33L 131.39,29.33C 131.391,14.6057 143.33,2.669 158.058,2.669L 243.044,2.669C 257.772,2.669 269.711,14.6057 269.711,29.333 Z",PaperTap:"M0.0009,17.2042 L0.0009,47.165 C0.001,47.165 14.403,53.5455 25.00,47.165 C35.599,40.7852 44.403,43.5087 50.00,47.165L50.001,17.2042 M50.001,32.7987 L50.001,2.8405 C50.001,2.8405 35.599,-3.5427 25.001,2.8405C14.403,9.2237 5.599,6.494 0.0009,2.8405 L0.0009,32.7987",DirectData:"M 132.62 0 L 17.38 0 C 7.78 0 0 13.43 0 30 C 0 46.57 7.78 60 17.38 60 L 132.62 60 M 132.62 0C 123.02 0 115.24 13.43 115.24 30 C 115.24 46.57 123.02 60 132.62 60 C 142.22 60 150 46.57 150 30 C 150 13.43 142.22 0 132.62 0 z ",SequentialData:"M0.0029,24.999 C0.0029,11.1922 10.433,0.0021 23.295,0.0021 C36.159,0.00216 46.585,11.1922 46.585,24.999C46.585,38.8057 36.159,49.9979 23.295,49.9979 C10.433,49.9979 0.0029,38.8057 0.0029,24.999 z M23.294,49.999 L50.002,49.999",Sort:"M50.001,24.9971 L25.001,49.9971 L0.00097,24.9971 L25.001,-0.00286865 L50.001,24.9971 z M0.000976562,24.9971 L50.001,24.9971",MultiDocument:"M43.6826,40 C44.8746,40.6183 45.8586,41.3502 46.8366,42.1122 L46.8366,4.74487 L3.09857,4.74487 L3.09857,10.9544 M46.837,35.143 C48.027,35.765 49.025,36.604 50.003,37.369 L50.003,0.002 L6.264,0.002 L6.264,4.744 M43.682,47.113 L43.682,10.765 L0.0025,10.7652 L0.0025,47.1132 C0.0025,47.1132 12.5846,53.6101 21.8426,47.1132 C31.1006,40.6163 38.792,43.393 43.6826,47.1132 z",Collate:"M50.001,0.0028 L25.001,25.0029 L0.00097,0.0028 L50.001,0.002 z M0.0009,50.002 L25.001,25.002L50.001,50.002 L0.0009,50.0029 z",SummingJunction:"M7.3252,42.6768 L42.6772,7.3247 M42.6768,42.6768 L7.3248,7.3247 M0.0009,25.001 C0.0009,11.193 11.197,0.0009 25.001,0.0009 C38.809,0.0009 50.001,11.193 50.001,25.001 C50.001,38.809 38.809,50.001 25.001,50.001 C11.197,50.00 0.0009,38.809 0.0009,25.00 z",Or:"M 0 50 L 100 50 M 50 100 L 50 0.0 M 0 50 C 0 22.384 22.392 0 50 0 C 77.616 0 100 22.384 100 50 C 100 77.616 77.616 100 50 100 C 22.392 100 0 77.616 0 50 Z",InternalStorage:"M 0 3.81946A 2.5,3.81946 0 0,1 2.5,0L 47.5 0A 2.5,3.81946 0 0,1 50,3.81946L 50 45.836A 2.5,3.819446 0 0,1 47.5,49.652778L 2.5 49.652778A 2.5,3.819446 0 0,1 0,45.8336L 0 3.819446ZM 0 11.45834L 50 11.4583334M 12.5 0L 12.5 49.652778",Extract:"M0,35 L30,0 L60,35 Z",ManualOperation:"M46.4,28.8 L14.8,28.8 L0,0 L60,0 Z",Merge:"M60,0 L30,35 L0,0 Z",OffPageReference:"M60,33.3 L30.1,39 L0,33.3 L0,0 L60,0 Z",SequentialAccessStorage:"M 60 30 C 60 13.4 46.6 0 30 0 S 0 13.4 0 30 s 13.4 30 30 30 h 28.6 v -6.5 h -9.9C 55.5 48 60 39.5 60 30 Z",Annotation:"M49.9984,50.0029 L-0.00271199,50.0029 L-0.00271199,0.00286865 L49.9984,0.00286865",Annotation2:"M49.9977,50.0029 L25.416,50.0029 L25.416,0.00286865 L49.9977,0.00286865 M25.4166,25.0029 L-0.00227869,25.0029",Data:"M 10 0 L 40 0 L 30 40 L 0 40 Z",Card:"M275,60 L400,60 L400,110 L260,110 L260,75 Z",Delay:"M0,0 L12.029,0 C14.212999,0 16,1.7869979 16,3.9709952 C16,6.1549926 14.212999,7.9409904 12.029,7.9409904 L0,7.9409904 z",Preparation:"M 1048.17 572 C 1051.06 568.86 1055.17 567.05 1059.5 567 L 1094.51 567 C 1098.84 567.05 1102.95 568.86 1105.84 572 L 1126.43 595 C 1127.01 596.28 1127.01 597.72 1126.43 599 L 1105.84 622 C 1102.95 625.14 1098.84 626.95 1094.51 627 L 1059.5 627 C 1055.17 626.95 1051.06 625.14 1048.17 622 L 1027.58 599 C 1027 597.72 1027 596.28 1027.58 595 L 1048.17 572 Z",Display:"M47.8809,19.2914 L32.7968,-0.00594145 L11.3902,-0.00594145 C7.93166,-0.00594145 0.00124586,11.187 0.00124586,24.9968C0.00124586,38.8032 7.93166,49.9962 11.3902,49.9962 L32.7968,49.99 L47.615,31.038 C47.615,31.0388 52.798,24.9968 47.880,19.2914 z",ManualInput:"M 912 732 L 1006.85 707 C 1008.2 707 1009.5 707.53 1010.46 708.46 C 1011.41 709.4 1011.95 710.67 1011.95 712 L 1011.95 762C 1012 764.41 1010.28 766.52 1007.87 767 L 917.1 767 C 915.75 767 914.45 766.47 913.49 765.54 C 912.54 764.6 912 763.33 912 762 L 912 732 Z",LoopLimit:"M 8 9 L 27 9 L 33 15 L 33 26 C 33 27 33 27 32 27 L 4 27 C 3 27 2 27 2 26 L 2 15 L 8 9 Z",StoredData:"M 5.55 0L 50 0A 1.5,30 0 0,1 50,0A 5.555,25 0 0,0 50,50A 1.5,30 0 0,1 50,50L 5.555 50A 5.55,25 0 0,1 5.555,0Z"};function s3(n,t,e){var i;i="Straight"!==n.type&&n.sourceWrapper?n.sourceWrapper.corners.center:function cre(n){var t;if(n.sourcePortWrapper){var e=n.sourcePortWrapper;t={x:e.offsetX,y:e.offsetY}}else t=n.sourceID&&n.sourceWrapper&&n.targetWrapper?Ah(n,0,n.sourceWrapper.corners.center,n.targetWrapper.corners.center,!1):n.sourcePoint;return t}(n);var r=function ure(n,t,e,i,r){var b,M,s=n.sourceWrapper,o=n.targetWrapper,a=n.sourcePortWrapper,l=n.targetPortWrapper,d=[],f=Ga(n),y={corners:undefined,point:t,direction:undefined,margin:{left:5,right:5,bottom:5,top:5}},S={corners:undefined,point:e,direction:undefined,margin:{left:5,right:5,bottom:5,top:5}};if(void 0!==s&&void 0!==o&&(b=En(s),M=En(o),y.corners=s.corners,S.corners=o.corners),void 0!==a&&(y.direction="Left"===a.connectionDirection||"Top"===a.connectionDirection||"Bottom"===a.connectionDirection||"Right"===a.connectionDirection?a.connectionDirection:zo({x:a.offsetX,y:a.offsetY},b,s.bounds)),void 0!==l&&(S.direction="Left"===l.connectionDirection||"Right"===l.connectionDirection||"Bottom"===l.connectionDirection||"Top"===l.connectionDirection?l.connectionDirection:zo({x:l.offsetX,y:l.offsetY},M,o.bounds)),"Bezier"===n.type&&!n.isBezierEditing&&n.segments.length>0)for(var D=n.segments.length-1;D>=0;)n.segments[parseInt(D.toString(),10)].isInternalSegment&&n.segments.pop(),D--;if(void 0!==s&&void 0!==o)return(void 0===y.direction||void 0===S.direction)&&(i?function dre(n,t,e){"LeftToRight"===e?(n.direction=n.direction?n.direction:"Right",t.direction=t.direction?t.direction:"Left"):"RightToLeft"===e?(n.direction=n.direction?n.direction:"Left",t.direction=t.direction?t.direction:"Right"):"TopToBottom"===e?(n.direction=n.direction?n.direction:"Bottom",t.direction=t.direction?t.direction:"Top"):"BottomToTop"===e&&(n.direction=n.direction?n.direction:"Top",t.direction=t.direction?t.direction:"Bottom")}(y,S,i):y.corners.top>S.corners.bottom&&Math.abs(y.corners.top-S.corners.bottom)>f?(y.direction=y.direction?y.direction:"Top",S.direction=S.direction?S.direction:"Bottom"):y.corners.bottomf?(y.direction=y.direction?y.direction:"Bottom",S.direction=S.direction?S.direction:"Top"):y.corners.rightf||y.corners.right+f=y.corners.left-f&&y.corners.left>S.corners.left?(y.direction=y.direction?y.direction:"Right",S.direction=S.direction?S.direction:"Left"):y.corners.left>S.corners.right&&Math.abs(y.corners.left-S.corners.right)>y.margin.left+y.margin.right||S.corners.right+f=S.corners.left-f&&y.corners.left0&&n.segments[0].direction&&(y.direction=n.segments[0].direction),y.point=Tc(b,y.direction),d=Tc(b,ls(y.direction)),y.point=Ah(n,0,y.point,d,!1)):y.point=o.corners.center;if(void 0!==h){switch(S.point={x:h.offsetX,y:h.offsetY},S.direction){case"Bottom":case"Top":S.point.y=S.point.y;break;case"Left":case"Right":S.point.x=S.point.x}n.targetPadding&&!w&&(S.point=CI(n,y,S,!0))}else"Orthogonal"===n.type||"Bezier"===n.type?(S.point=Tc(M,S.direction),d=Tc(M,ls(S.direction)),S.point=Ah(n,0,S.point,d,!0)):S.point=a.corners.center;if("Orthogonal"!==n.type){var C=void 0,D=void 0;if("Bezier"===n.type){if(n.bezierSettings.allowSegmentsReset||0===n.segments.length||!z.isEmptyPoint(n.segments[n.segments.length-1].point))return c=g3(n,y,S,void 0,s),Lx(n,y,S);Bv(n)}else Bv(n);if(void 0===n.sourcePortWrapper){y.point=y.corners.center,n.segments&&n.segments.length>0&&(C=z.isEmptyPoint((D=n.segments[0]).point)?void 0:D);var A=void 0!==C?C.point:S.point;if("Bezier"===n.type&&n.segments.length>0&&n.segments[0].vector1.angle&&n.segments[0].vector1.distance){var x=Math.max(y.corners.width,y.corners.height);A=z.transform(y.point,n.segments[0].vector1.angle,x/2)}y.point=w?n.sourceWrapper.bounds.center:Ah(n,0,y.point,A,!1)}if(void 0===n.targetPortWrapper){S.point=S.corners.center,n.segments&&n.segments.length>1&&(C=z.isEmptyPoint((D=n.segments[n.segments.length-2]).point)?void 0:D);var R=C?C.point:y.point;"Bezier"===n.type&&n.segments.length>0&&n.segments[n.segments.length-1].vector2.angle&&n.segments[n.segments.length-1].vector2.distance&&(x=Math.max(y.corners.width,y.corners.height),R=z.transform(S.point,n.segments[0].vector2.angle,x/2)),S.point=w?n.targetWrapper.bounds.center:Ah(n,0,R,S.point,!0)}c=Lx(n,y,S)}else"Orthogonal"===n.type&&n.segments&&n.segments.length>0&&null!==n.segments[0].direction?c=function Mre(n,t,e,i,r,s,o){var a,h,c,d;Bv(n);for(var u=0;u0&&n.segments[u-1].direction===h.direction?u=u3(n,u,t):h.direction?t.point=o3(t,n.segments[parseInt(u.toString(),10)]):(p=n.segments[u-1])&&p.points&&(t.point=p.points[p.points.length-1]),u===n.segments.length-1)if(p3(n,t),c3(a=void 0===r?bre(n,t,e):l3(n,t,e),n),h.points=[],a.length>=2)for(c=0;c2&&n.segments.length>2){var f={x:a[parseInt(c.toString(),10)].x,y:t.point.y};h.points=[],h.points.push(f),h.points.push(a[parseInt(c.toString(),10)]);var p=n.segments[u-1];n.segments.length<4&&p.points.pop(),p.points=p.points.concat(h.points)}else h.points.push(a[parseInt(c.toString(),10)]);else h.points.push(a[parseInt(c.toString(),10)]);else d=u;if(void 0!==d&&!n.selectedSegmentIndex&&(d===n.segments.length-1&&(n.segments[d-1].direction=null,n.segments[d-1].length=null),n.segments.splice(d,1)),i&&0===u){var g=h3(n,i,s);g&&(t.point=g)}}return f3(n,[])}(n,y,S,l,h,o):(n.segments[0]||(C=new bi(n,"segments",{type:"Orthogonal"},!0),n.segments.push(C)),n.segments[0].points=c=g3(n,y,S,void 0,s));return c}(n,y.direction,S.direction,y.point,S.point,r);if(Bv(n),(n.sourceWrapper||n.targetWrapper)&&function mre(n,t,e){var i=n.sourcePortWrapper,r=n.targetPortWrapper,s=n.sourceWrapper,o=t.point,a={left:0,right:0,top:0,bottom:0},l={x:0,y:0},c="Top";if(s?(o=e.point,a=t.margin):(s=n.targetWrapper,a=e.margin),"Orthogonal"===n.type)if(n.segments&&n.segments.length>0&&n.sourceWrapper&&n.segments[0].direction)t.direction=n.segments[0].direction,l=Ah(n,0,l=Tc(s.corners,t.direction),Tc(s.corners,ls(t.direction)),!1);else{var u={corners:null,direction:null,point:null,margin:null};Fv(s,{corners:null,direction:null,point:o,margin:a},u,n),l=u.point,c=u.direction}else{var p=void 0;n.segments&&n.segments.length>1&&(p=s===n.sourceWrapper?n.segments[0].point:n.segments[n.segments.length-2].point),l=Ah(n,0,s.bounds.center,n.segments&&n.segments.length>1?p:o,s===n.targetWrapper)}s===n.sourceWrapper?(t.direction=t.direction||c,t.point=l,n.sourcePortWrapper&&(t.point={x:i.offsetX,y:i.offsetY},n.sourcePadding&&(t.point=CI(n,t,e,!1)))):(e.direction=e.direction||c,e.point=l,n.targetPortWrapper&&(e.point={x:r.offsetX,y:r.offsetY},n.targetPadding&&(e.point=CI(n,t,e,!0))))}(n,y,S),"Straight"===n.type||"Bezier"===n.type)d=Lx(n,y,S);else if("Orthogonal"===n.type&&n.segments&&n.segments.length>0&&null!==n.segments[0].length&&null!==n.segments[0].direction)d=function vre(n,t,e,i,r,s,o){var a,l,c,u,h=[];if(Bv(n),n.segments.length>0){for(var p=0;p0&&n.segments[p-1].direction===f.direction)p=u3(n,p,t);else{var g=n.segments[p-1];t.point=f.direction?o3(t,f):g.points[g.points.length-1]}if(p===n.segments.length-1&&(o||r?n.targetWrapper&&void 0===n.targetPortWrapper?(p3(n,t),l=fre(n,t,e)):l=l3(n,t,e):l=pre(n,t,e),l))if(c3(l,n),f.points=[],l.length>=2)for(a=0;at.corners.top&&e.point.ye.point.x?"Left":"Right"):e.point.x>t.corners.left&&e.point.xe.point.y?"Top":"Bottom")),n.sourcePortWrapper&&s===ls(r)?(("Left"===s||"Right"===s)&&t.point.y>=t.corners.top&&t.point.y<=t.corners.center.y&&e.point.y>=t.corners.top&&e.point.y<=t.corners.center.y?(t.direction="Top",a=t.point.y-t.corners.top+20):("Left"===s||"Right"===s)&&t.point.y>t.corners.center.y&&t.point.y<=t.corners.bottom&&e.point.y>t.corners.center.y&&e.point.y<=t.corners.bottom?(t.direction="Bottom",a=t.corners.bottom-t.point.y+20):("Top"===s||"Bottom"===s)&&t.point.x>=t.corners.left&&t.point.x<=t.corners.center.x&&e.point.x>=t.corners.left&&e.point.x<=t.corners.center.x?(t.direction="Left",a=t.point.x-t.corners.left+20):("Top"===s||"Bottom"===s)&&t.point.x<=t.corners.right&&t.point.x>t.corners.center.x&&e.point.x<=t.corners.right&&e.point.xt.point.y&&t.point.y>=e.corners.top?(i="Top",r=t.point.y-e.corners.top+20):e.corners.center.y===t.point.y&&"Top"===n.segments[n.segments.length-2].direction||e.corners.center.ye.point.y?t.point.y-t.corners.top+20:t.corners.bottom-t.point.y+20):(i="Top",r=e.corners.height/2+20):e.corners.center.x!==t.point.x||e.corners.topt.point.x&&t.point.x>=e.corners.left?(i="Left",r=t.point.x-e.corners.left+20):e.corners.center.x===t.point.x&&"Left"===n.segments[n.segments.length-2].direction||e.corners.center.x<=t.point.x&&t.point.x<=e.corners.right?(i="Right",r=e.corners.right-t.point.x+20):void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&t.corners.left<=t.point.x&&t.point.x<=t.corners.right&&(i=t.direction,r=t.point.x>e.point.x?t.point.x-t.corners.left+20:t.corners.right-t.point.x+20):(i="Left",r=e.corners.width/2+20);var a=t.point;t.point=Bn(t.point,"Left"===i||"Top"===i?-r:r,"Left"===i||"Right"===i?0:90),t.direction=z.direction(t.point,e.point),void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&(t.corners.center.x===e.corners.center.x||t.corners.center.y===e.corners.center.y)&&(t.direction=e.direction);var l=Ys(n,t,e);return l.splice(0,0,a),l}function l3(n,t,e){var i,r;e.corners=n.targetWrapper.corners,void 0!==n.sourcePortWrapper&&(r=zo({x:n.sourcePortWrapper.offsetX,y:n.sourcePortWrapper.offsetY},En(n.sourceWrapper),n.sourceWrapper.bounds));var a=function gre(n,t,e,i){var r=!1;switch(e.direction){case"Left":void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&"Right"===i&&t.point.x>e.point.x&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom||("Bottom"===i&&t.point.y>e.point.y||"Top"===i&&t.point.y=t.corners.left&&t.point.x<=t.corners.right?(t.direction="Right"===i?t.point.y>e.point.y?"Top":"Bottom":t.point.xe.point.x&&(t.point.y>e.point.y||t.point.yt.point.y&&e.corners.bottome.point.y||t.point.x>e.point.x&&t.point.y<=e.point.y&&e.corners.top=t.point.y?t.direction="Top":t.point.xe.point.x&&t.point.y>e.point.y&&e.corners.bottomt.point.y?t.direction="Bottom":t.point.y===e.point.y&&t.point.xe.point.y||"Top"===i&&t.point.ye.point.x&&t.point.x>=t.corners.left&&t.point.x<=t.corners.right?(t.direction=t.point.x>e.point.x?"Left":"Right",r=!0):void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&"Left"===i&&t.point.x=t.corners.top&&t.point.y<=t.corners.bottom?(t.direction=t.point.y>e.point.y?"Top":"Bottom",r=!0):t.point.x=t.point.y&&t.point.y===e.point.y||t.point.y>e.point.y&&t.point.x>e.point.x?t.direction="Top":t.point.ye.point.x?t.direction="Bottom":t.point.xe.point.y||t.point.ye.point.x&&(t.direction="Left");break;case"Top":void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&"Bottom"===i&&t.point.y>e.point.y&&t.point.x>=t.corners.left&&t.point.x<=t.corners.right||("Right"===i&&t.point.x>e.point.x||"Left"===i&&e.point.y>t.point.y&&e.point.x>t.point.x)&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom?(t.direction="Bottom"===i?t.point.x>e.point.x?"Left":"Right":t.point.ye.point.y&&t.point.x>e.corners.left&&t.point.x=e.point.y?t.direction="Top":t.point.ye.point.x?t.direction="Left":t.point.yt.point.x)&&t.point.y>e.point.y&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom||"Top"===i&&t.point.y=t.corners.left&&t.point.x<=t.corners.right)?(t.direction="Right"===i||"Left"===i?t.point.y>e.point.y?"Top":"Bottom":t.point.x>e.point.x?"Left":"Right",r=!0):t.point.ye.corners.left&&e.corners.right>t.point.x?t.point.ye.corners.left&&e.corners.center.x>=t.point.x?t.direction="Left":t.point.ye.point.y&&t.point.x>e.point.x?t.direction="Left":t.point.y>e.point.y&&t.point.xe.point.x||e.point.x>t.point.x)&&(t.direction="Bottom")}return r}(n,t,e,r);return!n.selectedSegmentIndex&&void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&e.direction===ls(r)&&(("Left"===e.direction&&t.point.x>e.point.x||"Right"===e.direction&&t.point.x=t.corners.top&&t.point.y<=t.corners.bottom||"Bottom"===e.direction&&t.point.y=t.corners.left&&t.point.x<=t.corners.right)?i=a3(n,t,e):n.selectedSegmentIndex||t.direction!==e.direction?!n.selectedSegmentIndex&&("Left"===e.direction&&t.point.x>e.point.x||"Right"===e.direction&&t.point.x=t.point.y||"Top"===e.direction&&t.point.y>e.point.y||"Bottom"===e.direction&&t.point.y=t.point.x?i=n.selectedSegmentIndex?Ll(t,e):a3(n,t,e):!n.selectedSegmentIndex&&void 0!==n.sourceWrapper&&void 0!==n.targetWrapper&&void 0!==n.targetPortWrapper&&("Left"===t.direction||"Right"===t.direction)&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom&&("Top"===e.direction||"Bottom"===e.direction)&&e.corners.center.x===t.corners.center.x?(t.direction="Top"===e.direction?"Bottom":"Top",i=Ys(n,t,e,"Top"===e.direction?t.corners.bottom-t.point.y+20:t.point.y-t.corners.top+20)):!n.selectedSegmentIndex&&void 0!==n.sourceWrapper&&void 0!==n.targetWrapper&&void 0!==n.targetPortWrapper&&("Top"===t.direction||"Bottom"===t.direction)&&t.point.x>=t.corners.left&&t.point.x<=t.corners.right&&("Left"===e.direction||"Right"===e.direction)&&e.corners.center.y===t.corners.center.y?(t.direction="Left"===e.direction?"Right":"Left",i=Ys(n,t,e,"Left"===e.direction?t.corners.right-t.point.x+20:t.point.x-t.corners.left+20)):i=a?Ys(n,t,e,"Left"===t.direction||"Right"===t.direction?"Left"===t.direction?t.point.x-t.corners.left+20:t.corners.right-t.point.x+20:"Top"===t.direction?t.point.y-t.corners.top+20:t.corners.bottom-t.point.y+20):Ll(t,e):i=Ys(n,t,e),i}function h3(n,t,e){var r,i={x:t.offsetX,y:t.offsetY},s=En(e),o=zo(i,s,e.bounds),a=n.segments[0];return a.direction!==o&&(function wre(n,t,e,i,r,s){var a,h,o=13,l=[];l.push(i),i.y===r.y&&("Left"===t&&r.xi.x)||i.x===r.x&&("Top"===t&&r.yi.y)||("Top"===t||"Bottom"===t?"Top"===t&&r.yi.y-o||"Bottom"===t&&r.y>i.y&&r.yo&&("Top"===t&&r.yi.y)?l.push({x:i.x,y:r.y}):(a=r.xi.x-o||"right"===t&&r.x>i.x&&r.xo&&("Left"===t&&r.xi.x)?l.push({x:r.x,y:i.y}):(l.push({x:a="Left"===t?e.left-o:e.right+o,y:i.y}),l.push({x:a,y:r.y})),s&&(l.push(n.points[0]),l.reverse()),n.points=l)}(a,o,s,a.points[0],a.points[a.points.length-1],!1),r=a.points[a.points.length-1],a.direction=z.direction(a.points[a.points.length-2],a.points[a.points.length-1])),r}function c3(n,t,e){var s,i=t.segments[t.segments.length-2],r=i.points[i.points.length-1];(("Top"===i.direction||"Bottom"===i.direction)&&r.x===n[1].x||("Left"===i.direction||"Right"===i.direction)&&r.y===n[1].y)&&(i.points[i.points.length-1]=n[1],s=z.direction(i.points[0],i.points[i.points.length-1]),void 0!==t.sourceWrapper&&void 0===t.sourcePortWrapper&&s===ls(i.direction)&&("Left"===i.direction||"Right"===i.direction?i.points[0].x="Right"===i.direction?i.points[0].x-t.sourceWrapper.corners.width:i.points[0].x+t.sourceWrapper.corners.width:i.points[0].y="Bottom"===i.direction?i.points[0].y-t.sourceWrapper.corners.height:i.points[0].y+t.sourceWrapper.corners.height),i.direction=s,i.length=z.distancePoints(i.points[0],i.points[i.points.length-1]),n.splice(0,1))}function CI(n,t,e,i){var o=i?n.targetPadding:n.sourcePadding,a=i?n.targetPortWrapper:n.sourcePortWrapper,l=new Ne(a.bounds.x-o,a.bounds.y-o,a.actualSize.width+2*o,a.actualSize.height+2*o),h=[l.topLeft,l.topRight,l.bottomRight,l.bottomLeft];h[h.length]=h[0];var d=i?e.point:t.point;return Ox({x1:t.point.x,y1:t.point.y,x2:e.point.x,y2:e.point.y},h,0,d)||d}function d3(n,t){var e=[],i=dF(0,n.corners,t);i.push(i[0]);for(var r=0;r0){var r=void 0,s=[],o=t.point;for(r=0;r1&&z.equals(a.points[0],a.points[1])&&n.segments.splice(r,1),a)for(var l=0;l0||0===r)&&i.push(a.points[parseInt(l.toString(),10)])}}return i}function Nx(n,t,e){return"Top"===n||"Bottom"===n?e.x>t.x?"Right":"Left":e.y>t.y?"Bottom":"Top"}function Bv(n){if("Straight"===n.type||"Bezier"===n.type){if(0===n.segments.length||n.segments.length>0&&!z.isEmptyPoint(n.segments[n.segments.length-1].point))if("Bezier"===n.type){var t=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0},!0);n.segments.push(t)}else t=new kl(n,"segments",{type:"Straight"},!0),n.segments.push(t)}else{if(n.segments.length>0)for(var e=!1,i=0;i=t.corners.left&&e.point.x<=t.corners.right&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom)t.direction=e.point.y>t.point.y?"Bottom":"Top",i=Ys(n,t,e,"Top"===t.direction?t.point.y-t.corners.top+20:t.corners.bottom-t.point.y+20);else if(n.sourcePortWrapper&&r===ls(o)){var h;("Left"===r||"Right"===r)&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom?(t.direction=e.point.y>t.point.y?"Bottom":"Top",h=t.corners.height/2+20):("Top"===r||"Bottom"===r)&&t.point.x>=t.corners.left&&t.point.x<=t.corners.right&&(t.direction=e.point.x>t.point.x?"Right":"Left",h=t.corners.width/2+20),t.direction&&h?i=Ys(n,t,e,h,!0):(t.direction=o,i=Ll(t,e))}else if(!n.sourcePortWrapper||r!==e.direction||"Top"!==r&&"Bottom"!==r||t.corners.center.x!==e.corners.center.x)if(t.direction===e.direction)if(("Left"===t.direction||"Right"===t.direction)&&e.point.y>t.corners.top-20&&e.point.yt.corners.left-20&&e.point.xt.point.y?"Bottom":"Top",i=Ys(n,t,e,"Bottom"===t.direction?t.corners.bottom-t.point.y+20:t.point.y-t.corners.top+20);else t.direction=o,i=Ys(n,t,e,"Top"===o||"Bottom"===o?n.sourceWrapper.height/2+20:n.sourceWrapper.width/2+20),t.point=i[1],"Left"===o||"Right"===o?(e.direction=o,e.point="Left"===o?e.corners.middleLeft:e.corners.middleRight):Fv(n.targetWrapper,t,e,n),i=Ys(n,t,e);return i}function p3(n,t){if(void 0!==n.targetWrapper&&void 0===n.targetPortWrapper&&En(n.targetWrapper).containsPoint(t.point,1)){var i=n.targetWrapper,r=n.segments[n.segments.length-2],s=r.points[r.points.length-1],o=ls(r.direction);"Bottom"===o?s.yi.corners.top-1&&(r.points[r.points.length-1].y=i.corners.top-20,r.length=z.distancePoints(r.points[0],r.points[r.points.length-1])):"Left"===o?s.x>i.corners.left-1&&(r.points[r.points.length-1].x=i.corners.left-20,r.length=z.distancePoints(r.points[0],r.points[r.points.length-1])):"Right"===o&&s.x0||0===e)&&t.push(i.points[parseInt(r.toString(),10)]);return t}function Fv(n,t,e,i){var r,s={x:0,y:0},o=EI(n,n.corners,n.bounds),a=t.margin,l=t.point;if(o.bottomCenter.y+a.bottoml.y)r="Top",s=o.topCenter;else if(o.middleLeft.x-a.left>l.x)r="Left",s=o.middleLeft;else if(o.middleRight.x+a.rightc&&(p=c,r="Right",s=o.middleRight),p>d&&(p=d,r="Bottom",s=o.bottomCenter),p>u&&(r="Left",s=o.middleLeft)}e.point=s,e.direction=r;var f=Tc(o,ls(e.direction));e.point=Ah(i,0,e.point,f,n===i.targetWrapper)}function g3(n,t,e,i,r){var s,o,a;if(s=function Hre(n,t){var e=!1;switch(n){case"Left":switch(t){case"Right":case"Bottom":e=!0}break;case"Top":switch(t){case"Left":case"Right":case"Bottom":e=!0}break;case"Bottom":"Right"===t&&(e=!0)}return e}(t.direction,e.direction),s&&b3(t,e),"Right"===t.direction&&"Left"===e.direction)a=function Cre(n,t,e,i){var o=Math.round(Math.abs(t.point.y-e.point.y)),a={x:Math.max(t.point.x,t.corners.right),y:t.point.y},l={x:Math.min(e.point.x,e.corners.left),y:e.point.y},h=Ga(n);if(i){var c=l;l=a,a=c}return t.corners.bottom+he.corners.bottom+h||("Bezier"!==n.type||e.corners.left-t.corners.right<=2*h&&e.corners.left-t.corners.right>=5)&&(h=0),t.margin={left:h,right:h,top:h,bottom:h},e.margin={left:h,right:h,top:h,bottom:h},0===o&&(t.corners.right=e.corners.right?void 0!==i&&(i.offsetYe.corners.bottom+e.margin.bottom)||void 0===i&&t.corners.middleRight.ye.corners.bottom+e.margin.bottom&&t.corners.top>e.corners.bottom||void 0===i&&t.corners.middleRight.y>e.corners.bottom||void 0!==i&&i.offsetYe.corners.top||void 0===i&&t.corners.middleRight.y>e.corners.bottom?Ae.Three:t.corners.rightr.offsetY+e.margin.right||void 0===r&&t.corners.top>e.corners.middleRight.y||void 0!==r&&(void 0!==i&&i.offsetXr.offsetX||void 0===r&&t.corners.left>e.corners.topCenter.x?Ae.Four:Ae.Two:void 0!==s&&Math.abs(t.corners.right-e.corners.left)<=5&&Math.abs(s.offsetY-e.corners.top)<=5||void 0!==r&&t.corners.right=25&&t.corners.middleRight.y+t.margin.righte.corners.bottom+e.margin.bottom||void 0===o&&t.corners.middleRight.y>e.corners.bottom+e.margin.bottom?t.corners.top>e.corners.bottom?void 0!==a&&t.corners.right+t.margin.righta.offsetX||void 0===a&&t.corners.left>e.corners.bottomCenter.x?Ae.Four:Ae.Two:void 0!==o&&Math.abs(t.corners.right-e.corners.left)<=25&&Math.abs(o.offsetY-e.corners.bottom)<=25?Ae.Two:Ae.Four}(n,t,e,s);else if("Bottom"===t.direction&&"Top"===e.direction)a=function Tre(n,t,e){var r=t.point.x-e.point.x,s=Ga(n);return t.corners.right+se.corners.right+s||("Bezier"!==n.type||e.corners.top-t.corners.bottom<=2*s&&e.corners.top-t.corners.bottom>=5)&&(s=0),t.margin={left:s,right:s,top:s,bottom:s},e.margin={left:s,right:s,top:s,bottom:s},0===r&&t.corners.bottome.corners.right+e.margin.right||void 0===i&&t.corners.bottomCenter.x>e.corners.right+e.margin.right?Ae.Three:t.corners.bottomr.offsetX||void 0===r&&t.corners.left>e.corners.left||void 0!==r&&t.corners.right+t.margin.righte.corners.bottom?Ae.Five:0===s||0===o?Ae.One:Ae.Three}(n,t,e)}else"Bottom"===t.direction&&"Left"===e.direction?a=function Are(n,t,e,i){var r=n.sourcePortWrapper,s=n.targetPortWrapper,o=Ga(n);if(e.margin={left:o,right:o,top:o,bottom:o},t.margin={top:o,bottom:o,left:o,right:o},i){var l=r;r=s,s=l}return void 0!==r&&r.offsetXs.offsetY||void 0===s&&t.corners.top>e.corners.middleLeft.y?Ae.Four:Ae.Two:void 0!==s&&Math.abs(t.corners.right-e.corners.left)<=25&&Math.abs(s.offsetY-t.corners.bottom)<=25?Ae.Two:Ae.Four}(n,t,e,s):"Left"===t.direction&&"Left"===e.direction?a=function Ore(n,t,e){var i=n.sourcePortWrapper,r=n.targetPortWrapper,s=Ga(n);t.margin={left:s,right:s,top:s,bottom:s},e.margin={left:s,right:s,top:s,bottom:s};var o=Math.round(Math.abs(t.point.x-e.point.x)),a=Math.round(Math.abs(t.point.y-e.point.y));return t.corners.leftr.offsetY||void 0===r&&t.corners.top-t.margin.top>e.corners.middleLeft.y?Ae.Three:t.corners.righte.corners.bottom+e.margin.bottom||void 0===i&&t.corners.middleLeft.y>e.corners.bottom+e.margin.bottom?Ae.Three:t.corners.left>e.corners.right?Ae.Five:0===o||0===a?Ae.One:Ae.Three}(n,t,e):"Left"===t.direction&&"Top"===e.direction?a=function Nre(n,t,e,i){var s=n.sourcePortWrapper,o=Ga(n);e.margin={left:o,right:o,top:o,bottom:o},t.margin={top:o,bottom:o,left:o,right:o};var a=n.targetPortWrapper,l={x:Math.min(t.point.x,t.corners.left),y:t.point.y},h={x:e.point.x,y:Math.min(e.point.y,e.corners.top)};if(i){var c=s;s=a,a=c;var d=l;l=h,h=d}return void 0!==s&&s.offsetYa.offsetX||void 0===a&&t.corners.left-t.margin.left>e.corners.topCenter.x?Ae.Two:Ae.Four:void 0!==a&&t.corners.rightr.offsetX||void 0===r&&t.corners.left>e.corners.left||void 0!==r&&t.corners.right+t.margin.righte.corners.right+e.margin.right||void 0===i&&t.corners.left>e.corners.right||void 0!==i&&i.offsetXe.corners.bottom?Ae.Five:0===s||0===o?Ae.One:Ae.Three}(n,t,e));return s&&b3(t,e),o=function Pre(n,t,e,i,r,s){var l,d,h=n.sourceWrapper.corners,c=n.targetWrapper.corners,u=20,p={corners:e.corners,point:e.point,direction:e.direction,margin:e.margin},f={corners:i.corners,point:i.point,direction:i.direction,margin:i.margin};if(!(p.direction===f.direction&&t!==Ae.Five||p.direction!==ls(f.direction)&&t!==Ae.Three))switch(p.direction){case"Left":h.middleLeft.x>c.middleRight.x&&(d=(h.middleLeft.x-c.middleRight.x)/2,u=s?d:Math.min(u,d));break;case"Right":h.middleRight.xc.bottomCenter.y&&(d=(h.topCenter.y-c.bottomCenter.y)/2,u=s?d:Math.min(u,d));break;case"Bottom":h.bottomCenter.yp&&hp)&&o>c&&o<=d&&e>=20&&(s=n.point.x-t.corners.left+s),i&&n.direction===t.direction&&n.corners.left>t.corners.left&&n.corners.left-t.corners.right>=20&&(s=(n.corners.left-t.corners.right)/2),f=Bn(n.point,s,180);break;case"Top":(o>c&&oc)&&h>p&&h<=u&&e>=20&&(s=n.point.y-t.corners.top+s),i&&n.direction===t.direction&&n.corners.top>t.corners.top&&n.corners.top-t.corners.bottom>=20&&(s=(n.corners.top-t.corners.bottom)/2),f=Bn(n.point,s,270);break;case"Right":(h>p&&hp)&&a=c&&e>=20&&(s=t.corners.right-n.point.x+s),i&&n.direction===t.direction&&n.corners.right=20&&(s=(t.corners.left-n.corners.right)/2),f=Bn(n.point,s,0);break;case"Bottom":(o>c&&oc)&&l=p&&e>=20&&(s=t.corners.bottom-n.point.y+s),i&&n.direction===t.direction&&n.corners.bottom=20&&(s=(t.corners.top-n.corners.bottom)/2),f=Bn(n.point,s,90)}r=[n.point,f];var g=void 0;if("Top"===n.direction||"Bottom"===n.direction){var v=n.direction;n.direction=f.x>t.point.x?"Left":"Right",n.point=f,r=DI(n,t,v,r,g=i?.5*Math.abs(f.x-t.point.x):g,i)}else v=n.direction,n.direction=f.y>t.point.y?"Top":"Bottom",n.point=f,r=DI(n,t,v,r,g=i?.5*Math.abs(f.y-t.point.y):g,i);return r}(p,f,u,g)),l}(n,a,t,e,i,r),"Bezier"===n.type&&function Rre(n,t,e){if("Bezier"===n.type)if(0===n.segments.length){var i=e[0],r=e[e.length-1];if(t===Ae.One){var s=Math.min(20,.5*z.findLength(i,r)),o={angle:Xt(i,r),distance:s},a={angle:Xt(r,i),distance:s},l=z.direction(i,r),c=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,orientation:"Left"===l||"Right"===l?"Horizontal":"Vertical"},!0);n.segments.push(c)}else if(t===Ae.Two)o={angle:Xt(i,d=e[1]),distance:.5*z.findLength(i,d)},a={angle:Xt(r,d),distance:.5*z.findLength(r,d)},l=z.direction(i,d),c=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,orientation:"Left"===l||"Right"===l?"Horizontal":"Vertical"},!0),n.segments.push(c);else if(t===Ae.Three){var d={x:.5*((u=e[1]).x+(p=e[e.length-2]).x),y:.5*(u.y+p.y)},f=(o={angle:Xt(i,u),distance:.5*z.findLength(i,u)},a={angle:Xt(d,u),distance:.5*z.findLength(d,u)},z.direction(i,u)),v=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,point:d,orientation:"Left"===f||"Right"===f?"Horizontal":"Vertical"},!0);n.segments.push(v);var y={angle:Xt(d,p),distance:.5*z.findLength(d,p)},S={angle:Xt(r,p),distance:.5*z.findLength(r,p)},b=z.direction(d,p),w=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:y,vector2:S,orientation:"Left"===b||"Right"===b?"Horizontal":"Vertical"},!0);n.segments.push(w)}else if(t===Ae.Four){var D={x:.5*((u=e[1]).x+(p=e[2]).x),y:.5*(u.y+p.y)},A={x:.5*(p.x+(C=e[3]).x),y:.5*(p.y+C.y)};o={angle:Xt(i,u),distance:.5*z.findLength(i,u)},a={angle:Xt(D,u),distance:.5*z.findLength(D,u)},f=z.direction(i,u),v=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,point:D,orientation:"Left"===f||"Right"===f?"Horizontal":"Vertical"},!0),n.segments.push(v),y={angle:Xt(D,p),distance:.5*z.findLength(D,p)},S={angle:Xt(A,p),distance:.5*z.findLength(A,p)},b=z.direction(D,p),w=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:y,vector2:S,point:A,orientation:"Left"===b||"Right"===b?"Horizontal":"Vertical"},!0),n.segments.push(w);var x={angle:Xt(A,C),distance:.5*z.findLength(A,C)},R={angle:Xt(r,C),distance:.5*z.findLength(r,C)},L=z.direction(A,C),N=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:x,vector2:R,orientation:"Left"===L||"Right"===L?"Horizontal":"Vertical"},!0);n.segments.push(N)}else if(t===Ae.Five){var u,p,C,T=e[4],P=(D={x:.5*((u=e[1]).x+(p=e[2]).x),y:.5*(u.y+p.y)},A={x:.5*(p.x+(C=e[3]).x),y:.5*(p.y+C.y)},{x:.5*(C.x+T.x),y:.5*(C.y+T.y)});o={angle:Xt(i,u),distance:.5*z.findLength(i,u)},a={angle:Xt(D,u),distance:.5*z.findLength(D,u)},f=z.direction(i,u),v=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,point:D,orientation:"Left"===f||"Right"===f?"Horizontal":"Vertical"},!0),n.segments.push(v),y={angle:Xt(D,p),distance:.5*z.findLength(D,p)},S={angle:Xt(A,p),distance:.5*z.findLength(A,p)},b=z.direction(D,p),w=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:y,vector2:S,point:A,orientation:"Left"===b||"Right"===b?"Horizontal":"Vertical"},!0),n.segments.push(w),x={angle:Xt(A,C),distance:.5*z.findLength(A,C)},R={angle:Xt(P,C),distance:.5*z.findLength(P,C)},L=z.direction(A,C),N=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:x,vector2:R,point:P,orientation:"Left"===L||"Right"===L?"Horizontal":"Vertical"},!0),n.segments.push(N);var _={angle:Xt(P,T),distance:.5*z.findLength(P,T)},B={angle:Xt(r,T),distance:.5*z.findLength(r,T)},j=z.direction(P,T),oe=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:_,vector2:B,orientation:"Left"===j||"Right"===j?"Horizontal":"Vertical"},!0);n.segments.push(oe)}else c=new ps(n,"segments",{type:"Bezier"},!0),n.segments.push(c)}else for(var ue=0;ue=13?13:n.connectorSpacing<=1?1:n.connectorSpacing}function Xt(n,t){var i=z.findLength({x:t.x,y:n.y},t),r=z.findLength(t,n),s=Math.asin(i/r);return s=180*s/Math.PI,n.xt.y&&(s=360-s):s=n.y0)for(var l=1;lc)&&(s=c,a=h),s>=0&&s<=1)break}}return a}function m3(n,t){var c,d,u,p,f,g,S,b,M,w,D,e=n.x1,i=n.y1,r=n.x2,s=n.y2,o=t.x1,a=t.y1,l=t.x2,h=t.y2;if(w=(c=s-i)*l+(u=e-r)*h+(f=r*i-e*s),0!==(M=c*o+u*a+f)&&0!==w&&y3(M,w)||(b=(d=h-a)*r+(p=o-l)*s+(g=l*a-o*h),0!==(S=d*e+p*i+g)&&0!==b&&y3(S,b)))return null;var A=c*p-d*u;return 0===A?null:(A<0?-A/2:A/2,0,{x:(D=u*g-p*f)<0?(D-0)/A:(D+0)/A,y:(D=d*f-c*g)<0?(D-0)/A:(D+0)/A})}function y3(n,t){return n*t>=0}function S3(n,t,e){switch(t.direction){case"Left":t.point.x>n.left&&(e=t.point.x-n.left>e?t.point.x-n.left+e:e);break;case"Right":t.point.xe?n.right-t.point.x+e:e);break;case"Top":t.point.y>n.top&&(e=t.point.y-n.top>e?t.point.y-n.top+e:e);break;case"Bottom":t.point.ye?n.bottom-t.point.y+e:e)}return e}function Ll(n,t){var e;switch(n.direction){case"Left":case"Right":var i={x:t.point.x,y:n.point.y};e=z.equals(n.point,i)||z.equals(t.point,i)?[n.point,t.point]:[n.point,i,t.point];break;case"Top":case"Bottom":var r={x:n.point.x,y:t.point.y};e=z.equals(n.point,r)||z.equals(t.point,r)?[n.point,t.point]:[n.point,r,t.point]}return e}function Ys(n,t,e,i,r,s){void 0===s&&(s=!1),i||(i=20),s&&t.direction!==e.direction&&(i="Left"===t.direction||"Right"===t.direction?Math.floor(.5*Math.abs(t.point.x-e.point.x)):Math.floor(.5*Math.abs(t.point.y-e.point.y)));var l,h,u,o=n.sourcePortWrapper,c=e.point.x-t.point.x,d=e.point.y-t.point.y;if(!r&&(Math.abs(c)<.001||Math.abs(d)<.001)&&void 0===e.direction)return[t.point,e.point];if(void 0===n.targetWrapper&&Math.abs(c)<=31&&Math.abs(d)<=31){if("Left"===t.direction||"Right"===t.direction?Math.abs(d)<12&&(t.direction=t.point.y>e.point.y?"Top":"Bottom"):Math.abs(c)<12&&(t.direction=t.point.x>e.point.x?"Left":"Right"),Math.abs(c)>12||Math.abs(d)>12)return Ll(t,e);i+=5}return"Left"===t.direction||"Right"===t.direction?("Right"===t.direction?(void 0!==e.direction&&"Right"===e.direction&&(i=Math.max(t.point.x,e.point.x)-t.point.x+i),t.point.x>e.point.x&&void 0===o&&(i=-i)):(void 0!==e.direction&&"Left"===e.direction&&(i=t.point.x-Math.min(t.point.x,e.point.x)+i),(t.point.x>e.point.x||void 0!==o||"Left"===t.direction)&&(i=-i)),u=e.point.y-t.point.y,l=Bn(t.point,i,0),0!=(u=e.point.y-l.y)&&(h=Bn(l,e.point.y-l.y,90))):("Top"===t.direction||"Bottom"===t.direction)&&("Bottom"===t.direction?void 0!==e.direction&&"Bottom"===e.direction&&(i=Math.max(t.point.y,e.point.y)-t.point.y+i):(void 0!==e.direction&&"Top"===e.direction&&(i=t.point.y-Math.min(t.point.y,e.point.y)+i),(t.point.y>e.point.y||void 0!==o||"Top"===t.direction)&&(i=-i)),u=e.point.x-t.point.x,l=Bn(t.point,i,90),0!=(u=e.point.x-l.x)&&(h=Bn(l,e.point.x-l.x,0))),0===u?[t.point,e.point]:[t.point,l,h,e.point]}function DI(n,t,e,i,r,s){var o;switch(void 0===r&&(r=20),void 0===s&&(s=!1),void 0===e?(n.margin={left:2,right:2,top:2,bottom:2},t.margin={left:0,right:5,top:0,bottom:5},s&&(n.margin={left:10,right:10,top:10,bottom:10},t.margin={left:10,right:10,top:10,bottom:10},"Left"===n.direction?(r=Px(n,t,e,r),n.corners.left-t.corners.right>=5&&(r=Math.abs(n.point.x-n.corners.left)+.5*Math.floor(n.corners.left-t.corners.right))):"Right"===n.direction?(r=zx(n,t,r,e),t.corners.left-n.corners.right>=5&&(r=Math.abs(n.point.x-n.corners.right)+.5*Math.floor(t.corners.left-n.corners.right))):"Top"===n.direction?(r=kx(n,t,e,r),n.corners.top-t.corners.bottom>=5&&(r=Math.abs(n.point.y-n.corners.top)+.5*Math.floor(n.corners.top-t.corners.bottom))):"Bottom"===n.direction&&(r=Rx(n,t,r,e),t.corners.top-n.corners.bottom>=5&&(r=Math.abs(n.point.y-n.corners.bottom)+.5*Math.floor(t.corners.top-n.corners.bottom))))):("Bottom"===n.direction?s?t.corners.top-n.corners.bottom<20&&(r=t.corners.bottom-n.point.y+25):t.corners.top>n.corners.bottom&&t.corners.top-n.corners.bottom<20&&(r=(t.corners.top-n.corners.bottom)/2):"Top"===n.direction?s?n.corners.top-t.corners.bottom<20&&(r=n.point.y-t.corners.top+25):t.corners.bottomn.corners.right&&t.corners.left-n.corners.right<20&&(r=(t.corners.left-n.corners.right)/2):"Left"===n.direction&&(s?n.corners.left-t.corners.right<20&&(r=n.point.x-t.corners.left+25):t.corners.rightt.point.y||"Top"===t.direction&&n.point.yt.point.x||"Left"===t.direction&&n.point.xh||e.corners.top-e.margin.top<=i.point.y&&e.corners.bottom+e.margin.bottom>=i.point.y))if(!s||"Top"!==e.direction&&"Bottom"!==e.direction)c=Math.min(Math.abs(i.corners.left-e.corners.right)/2,20),h=e.corners.right-n.x+c;else{var c=Math.abs(i.corners.left-e.corners.right)/2;h=e.corners.right-n.x+c}else h="Top"===e.direction&&n.y>i.point.y||"Bottom"===e.direction&&n.y=e.corners.left-e.margin.left&&n.x<=e.corners.right+e.margin.right?Math.min(i.corners.left,e.corners.left)-n.x-20:i.corners.left-n.x-20;break;case"Right":if(e.corners.left-e.margin.left>i.corners.right+i.margin.right&&(e.corners.left-e.margin.right-i.corners.right>h||e.corners.top-e.margin.top<=i.point.y&&e.corners.bottom+e.margin.bottom>=i.point.y))if(!s||"Top"!==e.direction&&"Bottom"!==e.direction)c=Math.min(Math.abs(e.corners.left-i.corners.right)/2,20),h=e.corners.left-n.x-c;else{c=Math.abs(e.corners.left-i.corners.right)/2;h=e.corners.left-n.x-c}else h="Top"===e.direction&&n.y>i.point.y||"Bottom"===e.direction&&n.y=e.corners.left-e.margin.left&&n.x<=e.corners.right+e.margin.right?Math.max(i.corners.right,e.corners.right)-n.x+20:i.corners.right-n.x+20}o=Bn(n,h,0),a=Bn(o,i.point.y-n.y,90),l=i.point}else if("vertical"===t){switch(i.direction){case"Top":e.corners.bottom+e.margin.bottomh||e.corners.left-e.margin.left<=i.point.x&&e.corners.right+e.margin.right>=i.point.x)?!s||"Right"!==e.direction&&"Left"!==e.direction?(c=Math.min(Math.abs(i.corners.top-e.corners.bottom)/2,20),h=e.corners.bottom-n.y+c):(c=Math.abs(i.corners.top-e.corners.bottom)/2,h=e.corners.bottom-n.y+c):h="Left"===e.direction&&n.x>i.point.x||"Right"===e.direction&&n.x=e.corners.top-e.margin.top&&n.y<=e.corners.bottom+e.margin.bottom?Math.min(i.corners.top,e.corners.top)-n.y-20:i.corners.top-n.y-20;break;case"Bottom":e.corners.top-e.margin.top>i.corners.bottom+i.margin.bottom&&(e.corners.top-e.margin.top-i.corners.bottom>h||e.corners.left-e.margin.left<=i.point.x&&e.corners.right+e.margin.right>=i.point.x)?!s||"Right"!==e.direction&&"Left"!==e.direction?(c=Math.min(Math.abs(e.corners.top-i.corners.bottom)/2,20),h=e.corners.top-n.y-c):(c=Math.abs(e.corners.top-i.corners.bottom)/2,h=e.corners.top-n.y-c):h="Left"===e.direction&&n.x>i.point.x||"Right"===e.direction&&n.x=e.corners.top-e.margin.top&&n.y<=e.corners.bottom+e.margin.bottom?Math.max(i.corners.bottom,e.corners.bottom)-n.y+20:i.corners.bottom-n.y+20}o=Bn(n,h,90),a=Bn(o,i.point.x-n.x,0),l=i.point}r.push(o),r.push(a),r.push(l)}function kx(n,t,e,i){return n.corners.top-n.margin.top>t.corners.top+t.margin.top&&n.corners.top-n.margin.top<=t.corners.bottom+t.margin.bottom?(("Right"===t.direction&&n.point.xt.point.x)&&(i+=n.corners.top-t.corners.top),i+=n.point.y-n.corners.top):i+=void 0!==e&&"Left"!==e&&"Right"===t.direction&&n.point.xt.corners.left-t.margin.left&&n.corners.left-n.margin.left<=t.corners.right+t.margin.right?(("Bottom"===t.direction&&n.point.yt.point.y)&&(i+=n.corners.left-t.corners.left),i+=n.point.x-n.corners.left):i+=void 0!==e&&"Top"!==e&&"Bottom"===t.direction&&n.point.y=t.corners.left-t.margin.left?(("Bottom"===t.direction&&n.point.yt.point.y)&&(e+=t.corners.right-n.corners.right),e+=n.corners.right-n.point.x):e+=void 0!==i&&"Top"!==i&&"Bottom"===t.direction&&n.point.y=t.corners.top-t.margin.top?(("Right"===t.direction&&n.point.xt.point.x)&&(e+=t.corners.bottom-n.corners.bottom),e+=n.corners.bottom-n.point.y):e+=void 0!==i&&"Left"!==i&&"Right"===t.direction&&n.point.xf&&d=u&&d=p&&d<=f?"Left":"Right"}function ls(n){switch(n){case"Top":return"Bottom";case"Bottom":return"Top";case"Left":return"Right";case"Right":return"Left"}return"auto"}var w3=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Ac=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},xI=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return w3(t,n),Ac([I()],t.prototype,"width",void 0),Ac([I()],t.prototype,"height",void 0),t}(Ee),Bre=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return w3(t,n),Ac([I()],t.prototype,"width",void 0),Ac([I()],t.prototype,"height",void 0),Ac([I()],t.prototype,"fit",void 0),Ac([I()],t.prototype,"description",void 0),Ac([I()],t.prototype,"template",void 0),Ac([I()],t.prototype,"tooltip",void 0),t}(Ee),Fre=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Nl=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},C3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Fre(t,n),Nl([I("")],t.prototype,"id",void 0),Nl([I(Number.MIN_VALUE)],t.prototype,"zIndex",void 0),Nl([re({},$n)],t.prototype,"margin",void 0),Nl([I(!0)],t.prototype,"visible",void 0),Nl([re({},xd)],t.prototype,"tooltip",void 0),Nl([I(!1)],t.prototype,"excludeFromLayout",void 0),Nl([I()],t.prototype,"addInfo",void 0),Nl([I("None")],t.prototype,"flip",void 0),Nl([I("All")],t.prototype,"flipMode",void 0),Nl([re({},Bre)],t.prototype,"symbolInfo",void 0),t}(Ee),_re=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Jn=function(n){function t(e,i,r,s){var o=n.call(this)||this;return o.data="",o.nodeId="",o.annotationId="",o.diagramId="",o.diagramId=i,o.nodeId=e,o.annotationId=r,o.templateFn=UF(s),o}return _re(t,n),t.prototype.getNodeTemplate=function(){return this.templateFn},Object.defineProperty(t.prototype,"content",{get:function(){return this.data},set:function(e){this.data=e,this.canReset||(this.canReset=!0,this.isTemplate||(this.template=Rh(this,!0)),this.canReset=!1,this.isDirt=!0)},enumerable:!0,configurable:!0}),t}(as),Hx=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),hs=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},E3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Hx(t,n),hs([I("")],t.prototype,"id",void 0),hs([I("transparent")],t.prototype,"fill",void 0),hs([I("black")],t.prototype,"iconStrokeColor",void 0),hs([I(0)],t.prototype,"iconStrokeWidth",void 0),hs([I(!0)],t.prototype,"visibility",void 0),hs([I(10)],t.prototype,"width",void 0),hs([I(10)],t.prototype,"height",void 0),hs([I("transparent")],t.prototype,"handleStrokeColor",void 0),hs([I(1)],t.prototype,"handleStrokeWidth",void 0),hs([I("")],t.prototype,"pathData",void 0),hs([I(0)],t.prototype,"cornerRadius",void 0),hs([re({left:0,right:0,top:0,bottom:0},$n)],t.prototype,"padding",void 0),hs([re({},xd)],t.prototype,"tooltip",void 0),t}(Ee),D3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Hx(t,n),hs([re({x:0,y:0},z)],t.prototype,"offset",void 0),hs([re({},$n)],t.prototype,"margin",void 0),t}(E3),TI=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Hx(t,n),hs([I(.5)],t.prototype,"offset",void 0),hs([I("Center")],t.prototype,"alignment",void 0),hs([re({x:0,y:0},z)],t.prototype,"displacement",void 0),t}(E3);function Td(n){return n?n instanceof Zn||n instanceof Nr?n.constraints&Lr.Select:n instanceof de?n.constraints&qe.Select:n.constraints&ie.Select:1}function to(n){return n?n instanceof Zn||n instanceof Nr?n.constraints&Lr.Drag:n instanceof de?n.constraints&qe.Drag:n instanceof oi?1:n.constraints&ie.Drag:1}function Ure(n,t){return n instanceof de?n.constraints&qe.PointerEvents:n.constraints&ie.PointerEvents}function AI(n){return n instanceof de?n.constraints&qe.Delete:n.constraints&ie.Delete}function LI(n){return n.constraints&qe.DragSourceEnd}function NI(n){return n.constraints&qe.DragTargetEnd}function OI(n){return n.constraints&qe.DragSegmentThumb}function kI(n){return n instanceof Zn||n instanceof Nr?n.constraints&Lr.Rotate:n.constraints&ie.Rotate}function PI(n){return n.constraints&ie.Shadow}function da(n){return n instanceof te&&n.constraints&ie.InConnect?n.constraints&ie.InConnect:0}function Lh(n){return n&&n.constraints&&!(n.constraints&ni.None)&&n.constraints&ni.InConnect?n.constraints&ni.InConnect:0}function Nh(n){return n instanceof te&&n.constraints&ie.OutConnect?n.constraints&ie.OutConnect:0}function Ad(n){return n&&n.constraints&&!(n.constraints&ni.None)&&n.constraints&ni.OutConnect?n.constraints&ni.OutConnect:0}function Ol(n,t){var e=0;return n instanceof Zn||n instanceof Nr?e=n.constraints&Lr.Resize:n&&("SouthEast"===t?e=n.constraints&ie.ResizeSouthEast:"East"===t?e=n.constraints&ie.ResizeEast:"NorthEast"===t?e=n.constraints&ie.ResizeNorthEast:"South"===t?e=n.constraints&ie.ResizeSouth:"North"===t?e=n.constraints&ie.ResizeNorth:"SouthWest"===t?e=n.constraints&ie.ResizeSouthWest:"West"===t?e=n.constraints&ie.ResizeWest:"NorthWest"===t&&(e=n.constraints&ie.ResizeNorthWest)),e}function zI(n){return n instanceof de?n.constraints&qe.AllowDrop:n.constraints&ie.AllowDrop}function Ds(n){return n.constraints&rt.Virtualization}function _v(n){return n.tool&Ci.SingleSelect}function Uv(n){return n.tool&Ci.MultipleSelect}function Lc(n){return n.tool&Ci.ZoomPan}function RI(n){return n.tool&Ci.ContinuousDraw}function x3(n){return n.tool&Ci.DrawOnce}function HI(n){return n.tool&Ci.SingleSelect||n.tool&Ci.MultipleSelect}function jv(n){return n.constraints&rt.UserInteraction}function T3(n){return n.constraints&rt.ZoomTextEdit}function Vv(n){return function Gre(n){return n.constraints&rt.ApiUpdate}(n)||n.diagramActions&ee.ToolAction}function Bx(n,t){return n.constraints&ni.Draw}function Fx(n,t){return n.constraints&ni.Drag}function BI(n){return!(n&Qa.DrawSelectorBorder)}function A3(n){return!!(n&Qa.PreventRenderSelector)}var _x=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Wv=function(n){function t(){var e=null!==n&&n.apply(this,arguments)||this;return e.childTable=[],e.cellStyle={},e.desiredRowHeight=[],e.desiredCellWidth=[],e}return _x(t,n),t.prototype.rowDefinitions=function(){return this.rowDefns},t.prototype.columnDefinitions=function(){return this.colDefns},t.prototype.addObject=function(e,i,r,s,o){if(this.rows.length>=i){var a=this.rows[parseInt(i.toString(),10)];if(a.cells.length>r){o=o||1,s=s||1;var l=a.cells[parseInt(r.toString(),10)];l.columnSpan=Math.max(o,l.columnSpan),l.rowSpan=Math.max(s,l.rowSpan);var h=new Jre;(h=e).rowId=i,h.columnId=r,h.columnSpan=o,this.childTable[h.id]=h,this.addObjectToCell(h,l)}}},t.prototype.addObjectToCell=function(e,i){i.children||(i.children=[]),e.style.strokeColor="black",e.style.strokeWidth=1,i.children.push(e)},t.prototype.updateProperties=function(e,i,r,s){this.offsetX=e,this.offsetY=i,this.width=r,this.height=s},t.prototype.setDefinitions=function(e,i){this.rowDefns=e,this.colDefns=i,this.children=[],this.rows=this.rows||[];for(var r=0;r0){for(var h=0;hi&&this.updateRowHeight(e,l,!1)}},t.prototype.setTextRefresh=function(e){if(e.children&&e.children.length)for(var i=e.children,r=0;ri&&this.updateColumnWidth(e,a,!1)}},t.prototype.calculateCellWidth=function(e){for(var i,r,s,o=0;os.bounds.width&&(0===s.children.length||void 0===s.children[0].maxWidth)?s.outerBounds.width:s.bounds.width,i=i?is.bounds.height?s.outerBounds.height:s.bounds.height,i=i?i0?e.children[0]:void 0;if(a&&1===e.columnSpan){o="Width"===i?a.bounds.right:a.bounds.bottom,s||(s="Width"===i?a.bounds.width:a.bounds.height);for(var l=0;lo){var d=c-o+("Width"===i?a.bounds.width:a.bounds.height);s&&(s=s0?this.rowDefns.splice(e,0,i):this.rowDefns.push(i);var s=new L3;s.cells=[],(new Ld).width=this.width,this.addCellInRow(this.colDefns,i,s),e>this.rows.length-1?this.rows.push(s):this.rows.splice(e,0,s),r&&(this.measure(new me(this.width,this.height)),this.arrange(this.desiredSize))},t.prototype.addColumn=function(e,i,r){var s,o,a,l,h=this.rows;this.colDefns.length>0?this.colDefns.splice(e,0,i):this.colDefns.push(i),void 0!==this.width&&(this.width+=i.width);for(var c=0;cs.cells.length-1?s.cells.push(l):s.cells.splice(e,0,l),this.children.push(l);r&&(this.measure(new me(this.width,this.height)),this.arrange(this.desiredSize))},t.prototype.removeRow=function(e){var i,r,o=this.rows[parseInt(e.toString(),10)];this.height-=this.rowDefns[parseInt(e.toString(),10)].height;for(var a=0;a0){var r=0,s=0;i=new me(0,0),this.calculateSize();for(var o=0,a=this.rows;o0){for(var o=this.offsetX-e.width*this.pivot.x,a=this.offsetY-e.height*this.pivot.y,l=o,h=0,c=this.rows;h1&&this.children.splice(this.children.indexOf(f)+1,f.columnSpan-1),f.rowSpan>1)for(y=s,S=0;y+f.rowSpan-10){for(var c=0;c0?1:0,v=0;v0||a.outEdges.length>0))for(p=a.inEdges.concat(a.outEdges),s=0;s0)for(o=0;o1)for(a=1;a0))if(h=n.wrapper.children[0],"Horizontal"===e.orientation)for(o=e.header&&e.hasHeader?h.rows[1]:h.rows[0],r=0;r0){var e=void 0;t.lineRoutingModule&&t.constraints&rt.LineRouting&&t.lineRoutingModule.renderVirtualRegion(t,!0);for(var i=0;i0?o+1:o)].height=t.wrapper.height;else if(t.isPhase)for(l[t.rowIndex-o].offset=t.wrapper.height,f=0;f0?1:0)].width=t.wrapper.width}function _I(n,t){var i=n.shape,r=i.header&&i.hasHeader?1:0;return"Horizontal"===i.orientation?t.rowIndex-(r+=i.phases.length>0?1:0):t.columnIndex-(i.phaseSize&&i.phases.length>0?1:0)}function UI(n){var t=0,e=n.shape;return"Horizontal"===e.orientation&&(t=e.header&&e.hasHeader?1:0),e.phases.length>0&&e.phaseSize&&(t+=1),t}function jI(n,t,e,i){var r=n.shape;if(r.phases.length>0){var s=t.nameTable[r.phases[parseInt(i.toString(),10)].header.id];s&&s.maxWidth0?u+1:u);var w=Nc(n,o),C=void 0!==i?i:l.lanes.length;if(u+=C,r={element:M,cause:n.diagramActions,diagramAction:n.getDiagramAction(n.diagramActions),state:"Changing",type:"Addition",cancel:!1,laneIndex:C},n.triggerEvent(Ce.collectionChange,r),!r.cancel){if(c){var D=new Yv;D.height=e.height,o.addRow(u,D,!1),s.height=void 0!==s.height?s.height+e.height:s.height,s.wrapper.height=o.height=s.height}else{var A=new Ld;A.width=e.width,o.addColumn(C+1,A,!1),s.width&&(s.width+=e.width,s.wrapper.width=o.width=s.width),n.diagramActions&ee.UndoRedo||(o.rows[0].cells[0].columnSpan+=1)}n.diagramActions&ee.UndoRedo||(M.id=""===M.id?Qe():M.id),void 0!==i?l.lanes.splice(i,0,M):l.lanes.push(M),r={element:M,cause:n.diagramActions,diagramAction:n.getDiagramAction(n.diagramActions),state:"Changed",type:"Addition",cancel:!1,laneIndex:C},n.triggerEvent(Ce.collectionChange,r),O3(o,n,s,u,C,c),h="Horizontal"===l.orientation?n.nameTable[o.rows[parseInt(u.toString(),10)].cells[0].children[0].id]:l.header&&l.hasHeader?n.nameTable[o.rows[1].cells[parseInt(u.toString(),10)].children[0].id]:n.nameTable[o.rows[0].cells[parseInt(u.toString(),10)].children[0].id],n.diagramActions&ee.UndoRedo||(d={type:"LaneCollectionChanged",changeType:"Insert",undoObject:$(M),redoObject:$(h),category:"Internal"},n.addHistoryEntry(d)),qp(n,s,"Horizontal"===l.orientation?u:l.header&&l.hasHeader?1:0),Xp(s),Oc(n,s);var R=!1;if((p=e.children)&&p.length>0)for(f=0;f0){var o=t.children[0],a=n.nameTable[o.id];(function ane(n,t,e){return n.left-(e.left||0)<=t.x&&n.right+(e.right||0)>=t.x&&n.top-(e.top||0)<=t.y&&n.bottom+(e.bottom||0)>=t.y})(o.bounds,e,r)&&(n.addChild(a,i),s=!0)}return s}function lne(n,t,e){if("SwimLane"===t.shape.type){var i=void 0,r=void 0,s=void 0,a=void 0,l=void 0,h=void 0,c=t.wrapper.bounds.x,d=t.wrapper.bounds.y,u=t.shape,p=u.padding,f=u.phases,g=void 0,v=t.wrapper.children[0],y="Horizontal"===u.orientation;if(i=u.header&&u.hasHeader?0:-1,u.phases.length>0&&(i+=1),e.offset>(y?u.lanes[0].header.width:u.lanes[0].header.height)){for(h=0;he.offset){if(g=h>0?e.offset-(h>0?f[h-1]:s).offset:e.offset,y){var b=v.columnDefinitions()[parseInt(h.toString(),10)];b.width-=g,(a=n.nameTable[u.phases[parseInt(h.toString(),10)].header.id]).maxWidth=a.wrapper.maxWidth=b.width,v.updateColumnWidth(h,b.width,!1);var M=new Ld;M.width=g,l=h,v.addColumn(h,M,!1);break}var w=v.rowDefinitions()[h+i];w.height-=g,a=n.nameTable[u.phases[parseInt(h.toString(),10)].header.id],v.updateRowHeight(h+i,w.height,!1);var C=new Yv;C.height=g,l=h,v.addRow(h+i,C,!1);break}if(n.diagramActions&ee.UndoRedo&&void 0===l&&(D=n.historyManager.currentEntry.next).isLastPhase&&function hne(n,t,e,i,r,s){var a=t.shape.phases[n-2],l=e.previousPhase.offset;if(r){var h=i.columnDefinitions()[n-1],c=new Ld;n>1?(c.width=h.width-(l-a.offset),h.width=l-a.offset):(c.width=h.width-l,h.width=l),i.updateColumnWidth(n-1,h.width,!1),i.addColumn(n,c,!1)}else{h=i.rowDefinitions()[parseInt(n.toString(),10)];var d=new Yv;n>1?(d.height=e.undoObject.offset-l,h.height=l-a.offset):(d.height=h.height-l,h.height=l),i.updateRowHeight(n,h.height,!1),i.addRow(1+n,d,!1)}}(l=f.length,t,D,v,y),l>=0){var A=new cb(t.shape,"phases",e,!0);if(n.diagramActions&ee.UndoRedo||(A.id+=Qe()),u.phases.splice(l,0,A),Ux(v,n,t,i,y,l),y){if(r=n.nameTable[v.rows[parseInt(i.toString(),10)].cells[parseInt(l.toString(),10)].children[0].id],0===l&&u.header&&u.hasHeader){v.rows[0].cells[0].children=v.rows[0].cells[1].children,v.rows[0].cells[1].children=[];for(var x=v.rows[0],R=0;Rl+1){var O=n.nameTable[v.rows[parseInt(i.toString(),10)].cells[l+1].children[0].id];v.updateColumnWidth(l+1,L[l+1].width,!0,p),O.maxWidth=O.wrapper.maxWidth=L[l+1].width}t.width=t.wrapper.width=t.wrapper.children[0].width=v.width}else{r=n.nameTable[v.rows[i+l].cells[0].children[0].id];var N=v.rowDefinitions(),T=N[i+l].height;(function dne(n,t,e,i,r){for(var o,a,l=e.rows[parseInt(i.toString(),10)],h=e.rows[i+1],c=e.rows[i-1],d=1;di+l+1&&v.updateRowHeight(i+l+1,T=N[i+l+1].height,!0,p),t.height=t.wrapper.height=t.wrapper.children[0].height=v.actualSize.height}if(Xp(t),t.width=t.wrapper.actualSize.width,Oc(n,t),n.drag(t,c-t.wrapper.bounds.x,d-t.wrapper.bounds.y),FI(t,n),n.commandHandler.select(r),!(n.diagramActions&ee.UndoRedo)){var D={type:"PhaseCollectionChanged",changeType:"Insert",undoObject:$(A),redoObject:$(r),category:"Internal"};n.addHistoryEntry(D)}n.updateDiagramObject(t)}}}}function H3(n,t,e,i,r,s,o){var a,l,f,h=t.shape,c="Horizontal"===h.orientation,d=t.wrapper.children[0],g=c?s:o;e?(a=c?e.bounds.x+e.bounds.width:e.bounds.x,l=c?e.bounds.y:e.bounds.y+e.bounds.height):(a=d.bounds.x,l=r.bounds.y);var v=new Ne(a,l,i.desiredCellWidth,i.desiredCellHeight),S=Qv(n,0,t,{id:t.id+(c?h.lanes[g-2]:h.lanes[g-1]).id+Qe()[0],rowIndex:s,columnIndex:o,width:i.minWidth,height:i.minHeight,style:(c?h.lanes[g-2]:h.lanes[g-1]).style,constraints:ie.Default|ie.AllowDrop,container:{type:"Canvas",orientation:c?"Horizontal":"Vertical"}},!1,!1,!0);if(S.children[0].isCalculateDesiredSize=!1,d.addObject(S,s,o),r&&r.children&&r.children.length)for(f=0;f1)for(var f=1;fh.margin.left&&(h.margin.left=p)):(h.margin.top-=e.desiredCellHeight,p>h.margin.top&&(h.margin.top=p)))}(n,r,i,v,S,c,e)}function B3(n,t,e){if("SwimLane"===t.shape.type&&("ResizeSouth"===e||"ResizeEast"===e)){var i=t.shape,r=t.wrapper.children[0],s=void 0,o=void 0;"ResizeSouth"===e?"Vertical"===i.orientation?s=r.rows[r.rows.length-1].cells[0]:(o=r.rows.length-1,s=r.rows[parseInt(o.toString(),10)].cells[r.rows[parseInt(o.toString(),10)].cells.length-1]):(o=i.header&&i.hasHeader?1:0,s=r.rows[parseInt(o.toString(),10)].cells[r.rows[parseInt(o.toString(),10)].cells.length-1]),n.commandHandler.select(n.nameTable[s.children[0].id])}}function VI(n,t,e,i,r,s){var o,a,l,c,u,p,f,d=Qe(),g=n.shape,v=g.phases,y=n.offsetX-n.wrapper.actualSize.width/2,S=n.offsetY-n.wrapper.actualSize.height/2;if("Vertical"===g.orientation&&(S+=g.header&&g.hasHeader?g.header.height:0),!s)for(r||(n.id+=d,g&&g.header&&g.hasHeader?g.header.id+=d:g.header=void 0),o=0;v&&o0&&s.columnIndex>0||s.isLane)?(a=function bne(n,t,e){for(var i=new Ne,r="SwimLane"===n.shape.type?n.wrapper.children[0].rows:n.wrapper.rows,s=e?1:0;s=0;a--)i?i.id===o.children[parseInt(a.toString(),10)].id&&o.children.splice(a,1):(n.removeDependentConnector(o.children[parseInt(a.toString(),10)]),n.diagramActions&ee.UndoRedo||(n.diagramActions=n.diagramActions|ee.UndoRedo,s=!0),n.remove(o.children[parseInt(a.toString(),10)]),o.children.splice(a,1),s&&(n.diagramActions=n.diagramActions&~ee.UndoRedo))}function pne(n){return n.children[0]}function qv(n,t){t&&(n.nodes.splice(n.nodes.indexOf(t),1),n.removeFromAQuad(t),n.removeObjectsFromLayer(t),delete n.nameTable[t.id],n.removeElements(t))}function _3(n,t,e,i){var r;if("SwimLane"===e.shape.type){var s=e.shape,o=void 0;if(1===s.lanes.length)n.remove(e);else{var a=e.wrapper.bounds.x,l=e.wrapper.bounds.y,h=void 0,c=void 0,d=void 0,u=void 0,f=e.wrapper.children[0];if(o=i?s.lanes.indexOf(i):_I(e,t),r={element:t,cause:n.diagramActions,diagramAction:n.getDiagramAction(n.diagramActions),state:"Changing",type:"Removal",cancel:!1,laneIndex:o},n.triggerEvent(Ce.collectionChange,r),!r.cancel){var g=s.lanes[parseInt(o.toString(),10)],v=g.children;g.children=[];for(var y=0;y0)for(u=0;u0)for(u=0;u0)for(e=0;e1){c===l.phases.length-1&&(o=!0,a=$(l.phases[c-1]));var u=$(l.phases[parseInt(c.toString(),10)]);if(l.phases.splice(c,1),!(n.diagramActions&ee.UndoRedo)){var p={type:"PhaseCollectionChanged",changeType:"Remove",undoObject:u,previousPhase:a,redoObject:$(t),category:"Internal",isLastPhase:o};n.addHistoryEntry(p)}"Horizontal"===l.orientation?function gne(n,t,e,i){var r,s,o,a,l,h,c,d,u,p,f,g;for(i=void 0!==i?i:e.columnIndex,c=0;c1&&(s=r.cells[parseInt(i.toString(),10)],l=(o=r.cells.length-1===i?r.cells[i-1]:r.cells[i+1]).children[0],s.children.length>0))if(f=n.nameTable[(a=s.children[0]).id],0===o.children.length&&s.children.length>0)o.children=s.children,o.columnSpan=s.columnSpan-1;else{for(d=0;d0){var M=s.children[0],w=n.nameTable[M.id];if(i=e.x&&a.bounds.y<=e.y&&a.bounds.bottom>=e.y)&&!(t.constraints&ie.AllowMovingOutsideLane)){var l=$(t);n.clearSelection(),W3(n,t),t.parentId="",t.parentObj=n,t.propName="nodes";var h={type:"ChildCollectionChanged",category:"Internal",undoObject:l,redoObject:$(t)};n.addHistoryEntry(h),n.commandHandler.isContainer&&(n.commandHandler.isContainer=!1,n.endGroupAction()),Y3(t,n)}n.protectPropertyChange(o)}}function WI(n,t){var e,i,r;return n.enableServerDataBinding(!1),ce()||(n.selectedObject.helperObject?r=n.selectedObject.helperObject:(n.selectedItems.nodes.length>0||n.selectedItems.connectors.length>0)&&(t instanceof oi&&t.nodes.length+t.connectors.length===1?(e=t.nodes.length>0?t.nodes[0]:t.connectors[0],i=n.selectedItems.wrapper.children[0]):(e=t,i=n.selectedItems.wrapper),n.selectedObject.actualObject=e,!n.currentSymbol&&(e.isLane&&Yx(e,n)&&cs(n,e)||!e.isLane&&cs(n,e)||n.constraints&rt.LineRouting&&n.selectedItems.nodes.length>0))&&(r=function Mne(n,t){for(var e,i={},r=0,s=Object.keys(t);r=t.x-e&&n.x<=t.x+e&&n.y>=t.y-e&&n.y<=t.y+e}function Xa(n){return n.selectedItems.nodes.length>0||n.selectedItems.connectors.length>0}function G3(n){return 1===n.selectedItems.connectors.length&&!n.selectedItems.nodes.length}function _r(n,t,e,i){if(void 0===e&&(e=!0),t instanceof oi)return!0;if(t instanceof te)for(;t;){if(-1!==n.selectedItems.nodes.indexOf(t)&&void 0===n.selectedItems.annotation)return!0;if(e)break;t=n.nameTable[t.parentId]}else if(t instanceof de){if(-1!==n.selectedItems.connectors.indexOf(t)&&void 0===n.selectedItems.annotation)return!0}else if((t instanceof Zn||t instanceof Nr)&&n.selectedItems.annotation&&n.selectedItems.wrapper.children[0].id===i.id)return!0;return!1}var Qx={None:"default",Rotate:"crosshair",Select:"default",Drag:"move",ResizeWest:"w-resize",ResizeEast:"e-resize",ResizeSouth:"s-resize",ResizeNorth:"n-resize",Draw:"crosshair",PortDraw:"crosshair",ResizeNorthEast:"ne-resize",ResizeNorthWest:"nw-resize",ResizeSouthEast:"se-resize",ResizeSouthWest:"sw-resize",ConnectorSourceEnd:"move",ConnectorTargetEnd:"move",BezierSourceThumb:"move",BezierTargetThumb:"move",OrthoThumb:"move",SegmentEnd:"move",Pan:"grab",Hyperlink:"pointer",PortDrag:"pointer",LabelSelect:"pointer",LabelDrag:"move",LabelRotate:"crosshair",LabelResizeWest:"w-resize",LabelResizeEast:"e-resize",LabelResizeSouth:"s-resize",LabelResizeNorth:"n-resize",LabelResizeNorthEast:"ne-resize",LabelResizeNorthWest:"nw-resize",LabelResizeSouthEast:"se-resize",LabelResizeSouthWest:"sw-resize"},ds=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Od=function(n,t,e,i){return new(e||(e=Promise))(function(r,s){function o(h){try{l(i.next(h))}catch(c){s(c)}}function a(h){try{l(i.throw(h))}catch(c){s(c)}}function l(h){h.done?r(h.value):new e(function(c){c(h.value)}).then(o,a)}l((i=i.apply(n,t||[])).next())})},kd=function(n,t){var i,r,s,o,e={label:0,sent:function(){if(1&s[0])throw s[1];return s[1]},trys:[],ops:[]};return o={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function a(h){return function(c){return function l(h){if(i)throw new TypeError("Generator is already executing.");for(;e;)try{if(i=1,r&&(s=2&h[0]?r.return:h[0]?r.throw||((s=r.return)&&s.call(r),0):r.next)&&!(s=s.call(r,h[1])).done)return s;switch(r=0,s&&(h=[2&h[0],s.value]),h[0]){case 0:case 1:s=h;break;case 4:return e.label++,{value:h[1],done:!1};case 5:e.label++,r=h[1],h=[0];continue;case 7:h=e.ops.pop(),e.trys.pop();continue;default:if(!(s=(s=e.trys).length>0&&s[s.length-1])&&(6===h[0]||2===h[0])){e=0;continue}if(3===h[0]&&(!s||h[1]>s[0]&&h[1]-1&&(r=i.fixedUserHandles[parseInt(o.toString(),10)]);this.commandHandler.triggerEvent(Ce.fixedUserHandleClick,{fixedUserHandle:r,element:e.source}),n.prototype.mouseUp.call(this,e)},t}(us),Pd=function(n){function t(e,i){var r=n.call(this,e,!0)||this;return r.isConnected=!1,r.endPoint=i,r}return ds(t,n),t.prototype.mouseDown=function(e){return Od(this,void 0,void 0,function(){var r,s,o,a,l;return kd(this,function(h){if(this.inAction=!0,this.undoElement=void 0,this instanceof pa||(this.undoElement=$(e.source)),n.prototype.mouseDown.call(this,e),e.source&&e.source.connectors&&(this.oldConnector=$(r=e.source.connectors[0])),"BezierSourceThumb"===this.endPoint||"BezierTargetThumb"===this.endPoint)for(s=0;s0))},t.prototype.endAction=function(){n.prototype.endAction.call(this),this.prevPosition=null,this.endPoint=null},t}(us),ua=function(n){function t(e,i){var r=n.call(this,e,!0)||this;return r.currentTarget=null,r.isStartAction=!1,r.canCancel=!1,r.canTrigger=!1,r.objectType=i,r}return ds(t,n),t.prototype.mouseDown=function(e){if(e.source instanceof te||e.source instanceof de){var i=this.commandHandler.getSelectedObject();this.commandHandler.selectObjects([e.source],e.info&&e.info.ctrlKey,i);var r={nodes:[],connectors:[]};e.source instanceof te?r.nodes.push($(e.source)):r.connectors.push($(e.source)),this.undoElement=$(r)}else this.undoElement=$(e.source);this.undoParentElement=this.commandHandler.getSubProcess(e.source),"Port"===this.objectType&&(this.portId=e.sourceWrapper.id),this.commandHandler.insertBlazorConnector(e.source),n.prototype.mouseDown.call(this,e),this.initialOffset={x:0,y:0}},t.prototype.mouseUp=function(e,i){return Od(this,void 0,void 0,function(){var s,o,a,l,h,c,d,u,f,g,v,y,S,b,M;return kd(this,function(w){if(this.checkPropertyValue(),a=!1,h={nodes:[],connectors:[]},"Port"!==this.objectType){if(e.source instanceof te||e.source instanceof de?(e.source instanceof te?h.nodes.push($(e.source)):h.connectors.push($(e.source)),(o=$(h)).offsetX=(c=e.source.wrapper).offsetX,o.offsetY=c.offsetY):o=$(e.source),("helper"===(l=this.commandHandler.renderContainerHelper(e.source)||e.source||this.commandHandler.renderContainerHelper(e.source)).id||"helper"!==l.id)&&((l instanceof oi&&(Math.round(l.width)===Math.round(this.undoElement.width)&&Math.round(l.height)===Math.round(this.undoElement.height)||l.selectedObjects&&1===l.selectedObjects.length)||!(l instanceof oi))&&(l.offsetX!==this.undoElement.offsetX||l.offsetY!==this.undoElement.offsetY||l.sourcePoint!==this.undoElement.sourcePoint||l.targetPoint!==this.undoElement.targetPoint)||this.isSelectionHasConnector(l))&&(e.source&&(s={offsetX:e.source.wrapper.offsetX,offsetY:e.source.wrapper.offsetY}),g={source:e.source,state:"Completed",oldValue:this.intialValue,newValue:s,target:this.currentTarget,targetPosition:this.currentPosition,allowDrop:(g={source:e.source,state:"Completed",oldValue:this.intialValue,newValue:s,target:this.currentTarget,targetPosition:this.currentPosition,allowDrop:!0,cancel:!1}).allowDrop,cancel:g.cancel},d=!0,"helper"===l.id?this.canTrigger?(this.commandHandler.triggerEvent(Ce.positionChange,g),this.connectorEndPointChangeEvent(g),d=!0):d=!1:(this.commandHandler.triggerEvent(Ce.positionChange,g),this.connectorEndPointChangeEvent(g)),!i&&d&&(this.commandHandler.startGroupAction(),a=!0,M={type:"PositionChanged",redoObject:$(o),undoObject:$(this.undoElement),category:"Internal"},o.nodes[0]&&o.nodes[0].processId&&(u={type:"SizeChanged",category:"Internal",undoObject:this.undoParentElement,redoObject:this.commandHandler.getSubProcess(e.source)},this.commandHandler.addHistoryEntry(u)),this.commandHandler.addHistoryEntry(M))),this.commandHandler.snapPoint(this.prevPosition,this.currentPosition,0,0),this.commandHandler.removeSnap(),this.commandHandler.removeHighlighter(),e.source&&this.currentTarget&&zI(this.currentTarget)&&this.commandHandler.isDroppable(e.source,this.currentTarget)){if(f=!0,this.commandHandler.drop(this.currentElement,this.currentTarget,this.currentPosition),this.currentTarget&&this.currentTarget instanceof de&&!0===this.commandHandler.diagram.enableConnectorSplit)if(this.currentElement&&this.currentElement instanceof te){if(void 0!==this.currentElement.children)for(b=0;b0)for(var s=0;s0)for(var a=0;a0)for(a=0;a0&&e.connectors.length>0)||e.width===this.undoElement.width&&e.height===this.undoElement.height)},t.prototype.mouseMove=function(e){n.prototype.mouseMove.call(this,e);var r,s,i=!1;(r=this.commandHandler.renderContainerHelper(e.source)||e.source)instanceof te||r instanceof de?r instanceof te?r.offsetX===this.undoElement.nodes[0].offsetX&&r.offsetY===this.undoElement.nodes[0].offsetY&&(i=!0):z.equals(r.sourcePoint,this.undoElement.connectors[0].sourcePoint)&&z.equals(r.targetPoint,this.undoElement.connectors[0].targetPoint)&&(i=!0):r.wrapper.offsetX===this.undoElement.wrapper.offsetX&&r.wrapper.offsetY===this.undoElement.wrapper.offsetY&&(i=!0),r&&(s={offsetX:r.wrapper.offsetX,offsetY:r.wrapper.offsetY});var o={source:r,state:"Start",oldValue:s,newValue:s,target:e.target,targetPosition:e.position,allowDrop:!0,cancel:!1};if(o={source:r,state:"Start",oldValue:s,newValue:s,target:e.target,targetPosition:e.position,allowDrop:o.allowDrop,cancel:o.cancel},this.isStartAction||(this.intialValue={offsetX:r.wrapper.offsetX,offsetY:r.wrapper.offsetY}),i&&!ce()&&(this.commandHandler.triggerEvent(Ce.positionChange,o),this.connectorEndPointChangeEvent(o),this.isStartAction=!0),this.currentPosition=e.position,"Port"!==this.objectType){var h=this.initialOffset.x+(this.currentPosition.x-this.prevPosition.x),c=this.initialOffset.y+(this.currentPosition.y-this.prevPosition.y);this.commandHandler.dragOverElement(e,this.currentPosition),this.commandHandler.disConnect(e.source),this.commandHandler.removeSnap();var d,u=void 0,p=this.commandHandler.snapPoint(this.prevPosition,this.currentPosition,h,c);this.initialOffset.x=h-p.x,this.initialOffset.y=c-p.y,r&&(d={offsetX:r.wrapper.offsetX,offsetY:r.wrapper.offsetY},u={offsetX:r.wrapper.offsetX+p.x,offsetY:r.wrapper.offsetY+p.y}),this.currentTarget&&e.target!==this.currentTarget&&this.commandHandler.removeChildFromBPmn(e.source,e.target,this.currentTarget),this.currentTarget=e.target;var f={source:r,state:"Progress",oldValue:d,newValue:u,target:e.target,targetPosition:e.position,allowDrop:!0,cancel:!1};if(this.commandHandler.triggerEvent(Ce.positionChange,f),this.canTrigger=!0,this.connectorEndPointChangeEvent(f,p),!f.cancel&&!this.canCancel){this.blocked=!this.commandHandler.dragSelectedObjects(p.x,p.y);var g=!this.commandHandler.mouseOver(this.currentElement,this.currentTarget,this.currentPosition);this.blocked=this.blocked||g}if(this.commandHandler.removeStackHighlighter(),this.commandHandler.renderStackHighlighter(e),this.currentTarget&&e.source!==this.currentTarget&&this.commandHandler.isDroppable(e.source,this.currentTarget)&&"helper"!==e.source.id){var v=e.source instanceof oi?e.source.nodes[0]:e.source;!this.commandHandler.isParentAsContainer(v,!0)&&"SwimLane"!==v.shape.type&&!v.shape.isPhase&&(this.currentTarget.isLane?this.commandHandler.renderStackHighlighter(e,this.currentTarget):this.commandHandler.drawHighlighter(this.currentTarget))}else this.commandHandler.removeHighlighter();if(this.commandHandler.canEnableDefaultTooltip()){var y=this.getTooltipContent(e.source);this.commandHandler.showTooltip(e.source,e.position,ko(function(){return y}),"MoveTool",this.isTooltipVisible),this.isTooltipVisible=!1}}else{var b=Hi(),M=e.source;qi(b,-M.rotateAngle||-M.wrapper.rotateAngle,M.offsetX||M.wrapper.offsetX,M.offsetY||M.wrapper.offsetY);var w=Je(b,{x:this.prevPosition.x,y:this.prevPosition.y}),C=Je(b,{x:e.position.x,y:e.position.y});this.commandHandler.portDrag(e.source,e.sourceWrapper,C.x-w.x,C.y-w.y)}return this.prevPosition=this.currentPosition,!this.blocked},t.prototype.getTooltipContent=function(e){return"X:"+Math.round(e.wrapper.bounds.x)+" Y:"+Math.round(e.wrapper.bounds.y)},t.prototype.mouseLeave=function(e){this.mouseUp(e)},t.prototype.endAction=function(){n.prototype.endAction.call(this),this.currentTarget=null,this.prevPosition=null},t}(us),Gx=function(n){function t(e){var i=n.call(this,e,!0)||this;return i.rotateStart=!1,i}return ds(t,n),t.prototype.mouseDown=function(e){if(this.undoElement=$(e.source),this.undoElement.nodes[0]&&this.undoElement.nodes[0].children)for(var r=this.commandHandler.getAllDescendants(this.undoElement.nodes[0],[]),s=0;s=2){var s=e.startTouches[0],o=e.startTouches[1],a=e.moveTouches[0],l=e.moveTouches[1],h=this.getDistance(a,l)/this.getDistance(s,o);this.commandHandler.zoom(h,0,0,e.position),this.updateTouch(s,a),this.updateTouch(o,l)}}else this.commandHandler.scroll(this.currentPosition.x-this.prevPosition.x,this.currentPosition.y-this.prevPosition.y,this.currentPosition);return this.commandHandler.dataBinding(),!this.blocked},t.prototype.mouseUp=function(e){this.commandHandler.setBlazorDiagramProps(!1),this.checkPropertyValue(),this.commandHandler.updatePanState(!1),n.prototype.mouseUp.call(this,e),this.inAction=!1},t.prototype.endAction=function(){n.prototype.endAction.call(this)},t.prototype.getDistance=function(e,i){var r=i.pageX-e.pageX,s=i.pageY-e.pageY;return Math.sqrt(r*r+s*s)},t.prototype.updateTouch=function(e,i){e.pageX=i.pageX,e.pageY=i.pageY},t}(us),One=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseUp=function(e){this.checkPropertyValue(),this.commandHandler.initExpand(e),n.prototype.mouseUp.call(this,e)},t}(us),X3=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseUp=function(e){this.checkPropertyValue();var i="_blank",r="",s=window.innerHeight,o=window.innerWidth,a=window.screenTop,l=window.screenLeft;"CurrentTab"===e.sourceWrapper.hyperlink.hyperlinkOpenState?i="_self":"NewWindow"===e.sourceWrapper.hyperlink.hyperlinkOpenState&&(r="height="+s+",width="+o+",top="+a+",left="+l),window.open(e.sourceWrapper.hyperlink.link,i,r).focus(),n.prototype.mouseUp.call(this,e)},t}(us),Oh=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseDown=function(e){if(n.prototype.mouseDown.call(this,e),this.inAction=!0,this.drawingObject){var r=void 0,s=this.drawingObject.shape;this.drawingObject.shape.points.push(r={x:(r=s.points[s.points.length-1]).x,y:r.y})}else this.startPoint={x:this.startPosition.x,y:this.startPosition.y},this.drawingObject=this.commandHandler.drawObject({offsetX:this.currentPosition.x,offsetY:this.currentPosition.y,width:5,height:5,style:{strokeColor:"black",strokeWidth:1},shape:{type:"Basic",shape:"Polygon",points:[{x:this.startPoint.x,y:this.startPoint.y},{x:this.currentPosition.x,y:this.currentPosition.y}]}})},t.prototype.mouseMove=function(e){if(n.prototype.mouseMove.call(this,e),this.inAction){var i=this.drawingObject.shape;if(i.points[i.points.length-1].x=this.currentPosition.x,i.points[i.points.length-1].y=this.currentPosition.y,this.drawingObject.wrapper.children[0].data=yx(this.drawingObject.shape.points),this.inAction&&!1===z.equals(this.currentPosition,this.prevPosition)){var r=Ne.toBounds(this.drawingObject.shape.points);this.commandHandler.updateNodeDimension(this.drawingObject,r)}}return!0},t.prototype.mouseUp=function(e,i){this.checkPropertyValue(),n.prototype.mouseMove.call(this,e),this.inAction&&(this.inAction=!1,this.commandHandler.addObjectToDiagram(this.drawingObject)),this.endAction()},t.prototype.mouseWheel=function(e){n.prototype.mouseWheel.call(this,e),this.mouseMove(e)},t.prototype.endAction=function(){this.inAction=!1,this.drawingObject=null},t}(us),kh=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseMove=function(e){if(n.prototype.mouseMove.call(this,e),this.inAction){var i=this.drawingObject;i.targetPoint=this.currentPosition,this.commandHandler.updateConnectorPoints(i)}return!0},t.prototype.mouseDown=function(e){if(n.prototype.mouseDown.call(this,e),this.inAction=!0,this.drawingObject){var r=this.drawingObject,s=void 0;(s=new kl(r,"segments",{type:"Straight"},!0)).point=this.currentPosition,r.segments[r.segments.length-1]=s}else this.drawingObject=this.commandHandler.drawObject({id:"Connector",type:"Straight",sourcePoint:this.currentPosition,targetPoint:this.currentPosition})},t.prototype.mouseWheel=function(e){n.prototype.mouseWheel.call(this,e),this.mouseMove(e)},t.prototype.mouseUp=function(e){if(this.checkPropertyValue(),n.prototype.mouseMove.call(this,e),this.inAction&&this.drawingObject){var i=this.drawingObject;i.segments[i.segments.length-1].point={x:0,y:0},this.commandHandler.addObjectToDiagram(this.drawingObject)}this.endAction()},t.prototype.endAction=function(){this.drawingObject=null,this.inAction=!1},t}(us),kne=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseDown=function(e){this.inAction=!0,this.undoElement=$(e.source),this.annotationId=e.sourceWrapper.id,n.prototype.mouseDown.call(this,e)},t.prototype.mouseMove=function(e){n.prototype.mouseMove.call(this,e);var i=this.currentPosition.x-this.prevPosition.x,r=this.currentPosition.y-this.prevPosition.y,s=e.source;if(s instanceof te){var o=Hi();qi(o,-s.rotateAngle,0,0);var a=Je(o,{x:i,y:r});i=a.x,r=a.y}return this.inAction&&(this.commandHandler.labelDrag(e.source,e.sourceWrapper,i,r),this.commandHandler.updateSelector()),this.prevPosition=this.currentPosition,!this.blocked},t.prototype.mouseUp=function(e){this.checkPropertyValue();var i=e.source;this.inAction=!1;var r={type:"AnnotationPropertyChanged",objectId:this.annotationId,undoObject:$(this.undoElement),category:"Internal",redoObject:$(i)};this.commandHandler.addHistoryEntry(r),n.prototype.mouseUp.call(this,e)},t.prototype.mouseLeave=function(e){this.mouseUp(e)},t}(us),Pne=function(n){function t(e,i){var r=n.call(this,e,!0)||this;return r.corner=i,r}return ds(t,n),t.prototype.mouseDown=function(e){this.inAction=!0;var i=e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0];this.annotationId=e.source.wrapper.children[0].id,this.undoElement=$(i);var r=e.source.wrapper.children[0];this.initialBounds={x:r.offsetX,y:r.offsetY,width:r.actualSize.width,height:r.actualSize.height},n.prototype.mouseDown.call(this,e)},t.prototype.mouseMove=function(e){return n.prototype.mouseMove.call(this,e),this.inAction&&this.resizeObject(e),!this.blocked},t.prototype.mouseUp=function(e){this.checkPropertyValue();var i=e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0];this.inAction=!1;var r={type:"AnnotationPropertyChanged",objectId:this.annotationId,redoObject:$(i),undoObject:$(this.undoElement),category:"Internal"};this.commandHandler.addHistoryEntry(r),n.prototype.mouseUp.call(this,e)},t.prototype.mouseLeave=function(e){this.mouseUp(e)},t.prototype.resizeObject=function(e){var i,s,o,r=e.source.wrapper.children[0],a={x:r.offsetX,y:r.offsetY},l=r.rotateAngle;l=((l+=(i=e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0])instanceof te?i.rotateAngle:0)+360)%360;var h=Hi();qi(h,l,a.x,a.y);var c=this.corner.slice(5),d=this.updateSize(r,this.startPosition,this.currentPosition,c,this.initialBounds,l),u=r.offsetX-r.actualSize.width*r.pivot.x,p=r.offsetY-r.actualSize.height*r.pivot.y,f=this.getPivot(c),g=Je(h,f={x:u+r.actualSize.width*f.x,y:p+r.actualSize.height*f.y});d.x=g.x,d.y=g.y,this.commandHandler.labelResize(i,e.source.annotation,s=(s=d.width)<0?1:s,o=(o=d.height)<0?1:o,d,e.source),this.commandHandler.updateSelector()},t}(us),zne=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseDown=function(e){this.inAction=!0,this.annotationId=e.source.wrapper.children[0].id,this.undoElement=$(e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0]),n.prototype.mouseDown.call(this,e)},t.prototype.mouseMove=function(e){return n.prototype.mouseMove.call(this,e),e.source&&this.inAction&&(this.commandHandler.labelRotate(e.source.nodes[0]?e.source.nodes[0]:e.source.connectors[0],e.source.annotation,this.currentPosition,e.source),this.commandHandler.updateSelector()),this.prevPosition=this.currentPosition,!this.blocked},t.prototype.mouseUp=function(e){this.checkPropertyValue(),this.inAction=!1;var r={type:"AnnotationPropertyChanged",objectId:this.annotationId,redoObject:$(e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0]),undoObject:$(this.undoElement),category:"Internal"};this.commandHandler.addHistoryEntry(r),n.prototype.mouseUp.call(this,e)},t.prototype.mouseLeave=function(e){this.mouseUp(e)},t}(us),Rne=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseMove=function(e){if(n.prototype.mouseMove.call(this,e),this.inAction){var i=this.drawingObject.shape;if(i.points.push(this.currentPosition),this.drawingObject.wrapper.children[0].data=Sx(this.drawingObject.shape.points),i.data=Sx(i.points),this.inAction&&!1===z.equals(this.currentPosition,this.prevPosition)){var s=Ne.toBounds(this.drawingObject.shape.points);this.commandHandler.updateNodeDimension(this.drawingObject,s)}}return!0},t.prototype.mouseDown=function(e){n.prototype.mouseDown.call(this,e),this.inAction=!0,this.startPoint={x:this.startPosition.x,y:this.startPosition.y},this.drawingObject=this.commandHandler.drawObject({offsetX:this.currentPosition.x,offsetY:this.currentPosition.y,width:5,height:5,style:{strokeColor:"black",strokeWidth:1,fill:"transparent"},shape:{type:"Path",points:[{x:this.startPoint.x,y:this.startPoint.y},{x:this.currentPosition.x,y:this.currentPosition.y}]}})},t.prototype.mouseUp=function(e){if(this.checkPropertyValue(),this.inAction){this.inAction=!1;var s=this.drawingObject.shape,o=s.points;this.commandHandler.addObjectToDiagram(this.drawingObject),this.commandHandler.diagram.remove(this.commandHandler.diagram.nameTable[""+this.drawingObject.id]),o=this.pointReduction(o,10);var h={id:"newConnector"+Qe(),type:"Bezier",sourcePoint:{x:o[0].x,y:o[0].y},targetPoint:{x:o[o.length-1].x,y:o[o.length-1].y},segments:[],bezierSettings:{allowSegmentsReset:!1}};this.drawingObject=this.commandHandler.drawObject(h),this.drawingObject=this.bezierCurveSmoothness(o,.5,this.drawingObject,s),this.commandHandler.updateConnectorPoints(this.drawingObject),this.commandHandler.addObjectToDiagram(this.drawingObject),n.prototype.mouseUp.call(this,e)}},t.prototype.pointReduction=function(e,i){if(null===e||e.length<3)return e;var s=e.length-1,o=[];for(o.push(0),o.push(s);e[parseInt((0).toString(),10)]===e[parseInt(s.toString(),10)];)s--;this.reduction(e,0,s,i,o);var a=[];return o.sort(function(l,h){return l-h}),o.forEach(function(l){a.push(e[parseInt(l.toString(),10)])}),a},t.prototype.reduction=function(e,i,r,s,o){for(var a=0,l=0,h=i;ha&&(a=c,l=h)}a>s&&0!==l&&(o.push(l),this.reduction(e,i,l,s,o),this.reduction(e,l,r,s,o))},t.prototype.perpendicularDistance=function(e,i,r){return Math.abs(.5*(e.x*i.y-i.x*e.y+(i.x*r.y-r.x*i.y)+(r.x*e.y-e.x*r.y)))/Math.sqrt(Math.pow(e.x-i.x,2)+Math.pow(e.y-i.y,2))*2},t.prototype.bezierCurveSmoothness=function(e,i,r,s){if(e.length<3)return r;for(var o=0;o=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Hne=function(n){if(n)switch(n.type){case"Bpmn":return Une;case"UmlActivity":return _ne;case"UmlClassifier":return Wne;default:return Kv}return Kv},Bne=function(n){if(n)switch(n.type){case"Straight":default:return kl;case"Bezier":return ps;case"Orthogonal":return bi}},q3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I(10)],t.prototype,"width",void 0),Pe([I(10)],t.prototype,"height",void 0),Pe([I("Arrow")],t.prototype,"shape",void 0),Pe([re({fill:"black",strokeColor:"black",strokeWidth:1},Al)],t.prototype,"style",void 0),Pe([re({x:0,y:.5},z)],t.prototype,"pivot",void 0),Pe([I("")],t.prototype,"pathData",void 0),t}(Ee),XI=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I(0)],t.prototype,"angle",void 0),Pe([I(0)],t.prototype,"distance",void 0),t}(Ee),Fne=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I(wx.All)],t.prototype,"controlPointsVisibility",void 0),Pe([I("FreeForm")],t.prototype,"segmentEditOrientation",void 0),Pe([I(II.Default)],t.prototype,"smoothness",void 0),Pe([I(!0)],t.prototype,"allowSegmentsReset",void 0),t}(Ee),Kv=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I("None")],t.prototype,"type",void 0),t}(Ee),_ne=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I("Object")],t.prototype,"flow",void 0),Pe([I(30)],t.prototype,"exceptionFlowHeight",void 0),t}(Kv),Une=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I("Sequence")],t.prototype,"flow",void 0),Pe([I("Normal")],t.prototype,"sequence",void 0),Pe([I("Default")],t.prototype,"message",void 0),Pe([I("Default")],t.prototype,"association",void 0),t}(Kv),$3=function(n){function t(e,i,r,s){var o=n.call(this,e,i,r,s)||this;return o.points=[],o}return Qs(t,n),Pe([I("Straight")],t.prototype,"type",void 0),Pe([I(!0)],t.prototype,"allowDrag",void 0),t}(Ee),kl=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),t.prototype.getClassName=function(){return"StraightSegment"},Pe([re({x:0,y:0},z)],t.prototype,"point",void 0),t}($3),ps=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),t.prototype.getClassName=function(){return"BezierSegment"},t.prototype.getPoints=function(e,i){var r=[];if(r.length>0||null!=i){var o=this.bezireToPoly(r.length>0?r[r.length-1]:i,e);r.push.apply(r,o)}return r},t.prototype.bezireToPoly=function(e,i){var r=[];return i&&this.flattenCubicBezier(r,e,i.bezierPoint1,i.bezierPoint2,{x:i.points[1].x,y:i.points[1].y},10),r},t.prototype.flattenCubicBezier=function(e,i,r,s,o,a){var h,l=(z.findLength(i,r)+z.findLength(r,s)+z.findLength(s,o))/a;for(h=0;h<=l;h++){var c=h/l;e.push({x:(1-c)*(1-c)*(1-c)*i.x+3*c*(1-c)*(1-c)*r.x+3*c*c*(1-c)*s.x+c*c*c*o.x,y:(1-c)*(1-c)*(1-c)*i.y+3*c*(1-c)*(1-c)*r.y+3*c*c*(1-c)*s.y+c*c*c*o.y})}},Pe([I("Horizontal")],t.prototype,"orientation",void 0),Pe([re({x:0,y:0},z)],t.prototype,"point1",void 0),Pe([re({x:0,y:0},z)],t.prototype,"point2",void 0),Pe([re({angle:0,distance:0},XI)],t.prototype,"vector1",void 0),Pe([re({angle:0,distance:0},XI)],t.prototype,"vector2",void 0),t}(kl),bi=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),t.prototype.getClassName=function(){return"OrthogonalSegment"},Pe([I(null)],t.prototype,"length",void 0),Pe([I(null)],t.prototype,"direction",void 0),t}($3);function Z3(n,t,e){var s=e?45:180/(2+2/(n.height/n.width)),o=s,a=180-s,l=a+2*s,h=360-s,c=Xt(t,n.center);return c>o&&ca&&cl&&cMath.abs(t.y-n.y)?n.x=c)return s=z.findAngle(n[parseInt(d.toString(),10)],n[d+1]),{point:r=z.transform(n[parseInt(d.toString(),10)],s,c-(a||0)),index:l=d};a=o[parseInt(d.toString(),10)]}return{point:r,index:l}}(n,t),r=z.findAngle(n[i.index],n[i.index+1]),s=function yse(n){var e=0;switch(n.alignment){case"Center":case"After":e=0;break;case"Before":e=-0}return e}(t),o=z.transform(i.point,r+45,s);return i.point=o,i.angle=r,i}(i,e),h=l.point;s.id=this.id+"_"+e.id;var c=e.style;s.style={fill:c.fill,strokeColor:c.strokeColor,gradient:null,opacity:c.opacity,strokeDashArray:c.strokeDashArray,strokeWidth:c.strokeWidth},0===r.width&&(r.width=this.style.strokeWidth),0===r.height&&(r.height=this.style.strokeWidth);var d_y=(h.y-r.y)/r.height;a.x=r.width*((h.x-r.x)/r.width),a.y=r.height*d_y;var g,v,u=pF(e,l.angle,i),p=u.hAlign,f=u.vAlign;return"left"===p?(g="Left",a.x+=e.displacement.x):"right"===p?(g="Right",a.x-=e.displacement.x):"center"===p&&(g="Center"),"top"===f?(v="Top",a.y+=e.displacement.y):"bottom"===f?(v="Bottom",a.y-=e.displacement.y):"center"===f&&(v="Center"),s.horizontalAlignment=g,s.verticalAlignment=v,(s=im(s,o&&"Label"!==o.flipMode&&"None"!==o.flipMode?this.flip:"None",e)).float=!0,s.connectionDirection=e.connectionDirection,s.setOffsetWithRespectToBounds(a.x,a.y,"Absolute"),s.relativeMode="Point",s.visible=!(!ga(e,Gt.Visible)||ga(e,Gt.Hover)||ga(e,Gt.Connect)),s.elementActions=s.elementActions|Xr.ElementIsPort,s},t.prototype.getConnectorRelation=function(){var e=this.shape;"Association"===e.relationship?(this.segments[0].type="Straight",this.sourceDecorator.shape="None",this.targetDecorator.shape="Arrow"):"Inheritance"===e.relationship?(this.segments[0].type="Orthogonal",this.sourceDecorator.shape="None",this.targetDecorator.shape="Arrow"):"Composition"===e.relationship||"Aggregation"===e.relationship?(this.segments[0].type="Orthogonal",this.sourceDecorator.shape="Diamond",this.targetDecorator.shape="None"):"Dependency"===e.relationship?(this.segments[0].type="Orthogonal",this.sourceDecorator.shape="None",this.targetDecorator.shape="OpenArrow"):"Realization"===e.relationship&&(this.segments[0].type="Orthogonal",this.sourceDecorator.shape="None",this.targetDecorator.shape="Arrow"),"BiDirectional"===e.associationType&&(this.sourceDecorator.shape="None",this.targetDecorator.shape="None");var i,o,r="",s="";e.multiplicity.source&&(e.multiplicity.source.lowerBounds=e.multiplicity.source.lowerBounds,e.multiplicity.source.upperBounds=e.multiplicity.source.upperBounds),e.multiplicity.target&&(e.multiplicity.target.lowerBounds=e.multiplicity.target.lowerBounds,e.multiplicity.target.upperBounds=e.multiplicity.target.upperBounds);var a=e.multiplicity.source,l=e.multiplicity.target;o=a.upperBounds?a.lowerBounds+"..."+a.upperBounds:a.lowerBounds,i=l.upperBounds?l.lowerBounds+"..."+l.upperBounds:l.lowerBounds,"ManyToOne"===e.multiplicity.type&&(e.multiplicity.target.optional=!1,r=o||"*",s="1"),"OneToMany"===e.multiplicity.type&&(e.multiplicity.source.optional=!1,s=i||"*",r="1"),"ManyToMany"===e.multiplicity.type&&(r=o||"*",s=i||"*"),"OneToOne"===e.multiplicity.type&&(e.multiplicity.target.optional=!1,e.multiplicity.source.optional=!1,r="1",s="1"),this.annotations=[{id:this.id+"sourcelabel",content:r,offset:0,alignment:"Before",margin:{right:5,bottom:5}},{id:this.id+"targetlabel",content:s,offset:1,alignment:"Before",margin:{right:5,bottom:5}}]},t.prototype.getBpmnSequenceFlow=function(){var e=new Ke,i=new Ke;return"Normal"===this.shape.sequence&&"Bezier"!==this.type&&(this.targetDecorator.shape="Arrow"),"Default"===this.shape.sequence&&(e=this.getSegmentElement(this,e),i=IF(this.intermediatePoints,this),this.targetDecorator.shape="Arrow"),"Conditional"===this.shape.sequence&&(this.targetDecorator.shape="Arrow",this.sourceDecorator.shape="Diamond",i.id=this.id+this.shape.type),i},t.prototype.getUMLObjectFlow=function(){if(this.annotations)for(var e=0;e0&&(this.sourcePoint=o[0],this.targetPoint=o[o.length-1]),o},t.prototype.clipDecorator=function(e,i,r,s){var a,l,o={x:0,y:0},h=i.length,c=z.distancePoints(a=r?i[0]:i[h-1],l=r?i[1]:i[h-2]);c=0===c?1:c;var d=1,u=r?e.sourceWrapper:e.targetWrapper;u&&(d=u.style.strokeWidth,s&&s&ee.DecoratorPropertyChange&&(d=1));var p=d-1;return o.x=Math.round(a.x+p*(l.x-a.x)/c),o.y=Math.round(a.y+p*(l.y-a.y)/c),(r&&"None"!==e.sourceDecorator.shape||!r&&"None"!==e.targetDecorator.shape)&&(o=z.adjustPoint(o,l,!0,s&ee.DecoratorPropertyChange?0:d/2)),o},t.prototype.clipDecorators=function(e,i,r){return"None"!==e.sourceDecorator.shape&&(i[0]=this.clipDecorator(e,i,!0,r)),"None"!==e.targetDecorator.shape&&(i[i.length-1]=this.clipDecorator(e,i,!1,r)),i},t.prototype.updateSegmentElement=function(e,i,r,s){var o=new Ne,a=this.getSegmentPath(e,i,s);if("Bezier"===e.type){if(this.segments.length>0)for(var l=0;l0)if("Straight"===e.type&&e.segments.length<2)for(var o=0;o1)for(o=0;o0&&"Bezier"!==this.type)for(var p=0;p0&&(a=p0&&(f<2*this.cornerRadius?(l=z.adjustPoint(h[parseInt(p.toString(),10)],h[p+1],!0,f/2),p0&&(s=this.bridgePath(e,s,p),"Orthogonal"===e.type&&(s=this.bridgePath(e,s,p+1))),s+=" L"+a.x+" "+a.y))}else if("Bezier"===this.type){var g=void 0,v=void 0;if(this.parentObj.element){var y=this.parentObj.element.ej2_instances[0].eventHandler.action;g=this.parentObj.element.ej2_instances[0].eventHandler.tool instanceof zd,v=y.includes("PortDraw")||y.includes("Drag")}for(var S=void 0,b=this.segments,M=0;M2&&(b[parseInt(M.toString(),10)].bezierPoint1={x:0,y:0},b[parseInt(M.toString(),10)].bezierPoint2={x:0,y:0}),!z.isEmptyPoint(b[parseInt(M.toString(),10)].point1)||b[parseInt(M.toString(),10)].vector1.angle||b[parseInt(M.toString(),10)].vector1.distance?b[parseInt(M.toString(),10)].vector1.angle||b[parseInt(M.toString(),10)].vector1.distance?b[parseInt(M.toString(),10)].bezierPoint1=z.transform(h[parseInt(M.toString(),10)],b[parseInt(M.toString(),10)].vector1.angle,b[parseInt(M.toString(),10)].vector1.distance):b[parseInt(M.toString(),10)].bezierPoint1={x:b[parseInt(M.toString(),10)].point1.x||b[parseInt(M.toString(),10)].bezierPoint1.x,y:b[parseInt(M.toString(),10)].point1.y||b[parseInt(M.toString(),10)].bezierPoint1.y}:((e.sourceID||this.sourcePortID)&&this.sourceWrapper&&!v&&!g&&(S=Z3(this.sourceWrapper.bounds,h[parseInt(M.toString(),10)],!0)),b[parseInt(M.toString(),10)].bezierPoint1=$I(h[parseInt(M.toString(),10)],h[M+1],S)),!z.isEmptyPoint(b[parseInt(M.toString(),10)].point2)||b[parseInt(M.toString(),10)].vector2.angle||b[parseInt(M.toString(),10)].vector2.distance?b[parseInt(M.toString(),10)].vector2.angle||b[parseInt(M.toString(),10)].vector2.distance?b[parseInt(M.toString(),10)].bezierPoint2=z.transform(h[M+1],b[parseInt(M.toString(),10)].vector2.angle,b[parseInt(M.toString(),10)].vector2.distance):b[parseInt(M.toString(),10)].bezierPoint2={x:b[parseInt(M.toString(),10)].point2.x||b[parseInt(M.toString(),10)].bezierPoint2.x,y:b[parseInt(M.toString(),10)].point2.y||b[parseInt(M.toString(),10)].bezierPoint2.y}:((e.targetID||this.targetPortID)&&this.targetWrapper&&!v&&!g&&(S=Z3(this.targetWrapper.bounds,h[M+1],!0)),b[parseInt(M.toString(),10)].bezierPoint2=$I(h[M+1],h[parseInt(M.toString(),10)],S));h.splice(1,0,{x:b[0].bezierPoint1.x,y:b[0].bezierPoint1.y}),h.splice(h.length-1,0,{x:b[b.length-1].bezierPoint2.x,y:b[b.length-1].bezierPoint2.y}),h=this.clipDecorators(e,h,r);for(var w=0;w0&&(s=this.bridgePath(e,s,D),s+=" L"+o.x+" "+o.y);return s},t.prototype.updateShapeElement=function(e){var i;switch(e.shape.type){case"Bpmn":e.wrapper.children[3]instanceof Ke&&(i=e.wrapper.children[3]),"Message"===e.shape.flow&&this.updateShapePosition(e,i);break;case"UmlActivity":"Exception"===e.shape.flow&&this.getUMLExceptionFlow(e.wrapper.children[0])}},t.prototype.updateShapePosition=function(e,i){var o=bF(this.intermediatePoints,i,.5);i.offsetX=o.x,i.offsetY=o.y},t.prototype.scale=function(e,i,r,s,o){var a=0,l=0;if(this.wrapper&&this.wrapper.outerBounds){var h=function M3(n){var t=n.wrapper.children[0].bounds;return"None"!==n.sourceDecorator.shape&&t.uniteRect(n.wrapper.children[1].bounds),"None"!==n.targetDecorator.shape&&t.uniteRect(n.wrapper.children[2].bounds),t}(this),c=Math.abs((this.wrapper.bounds.width||this.style.strokeWidth||1)-2),d=Math.abs((this.wrapper.bounds.height||this.style.strokeWidth||1)-2);a=h.width-c,l=h.height-d,e=Math.abs((r-Math.max(a,l))/c),i=Math.abs((s-Math.max(a,l))/d),a=l=Math.min(a,l)}e=i=Math.min(e,i);var u=Hi();qi(u,-(o=o||this.wrapper).rotateAngle,o.offsetX,o.offsetY),Qp(u,e,i,o.offsetX,o.offsetY),qi(u,o.rotateAngle,o.offsetX,o.offsetY);var p=function Oie(n,t){for(var e=[],i=0,r=t;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Qne=function(n){function t(e,i){var r=n.call(this,e,i)||this;return r.offset=0,r.scale=1,r}return Yne(t,n),t.prototype.preRender=function(){this.unWireEvents(),this.wireEvents()},t.prototype.render=function(){this.updateRulerGeometry(),this.renderComplete()},t.prototype.getModuleName=function(){return"Ruler"},t.prototype.destroy=function(){this.unWireEvents(),this.notify("destroy",{}),n.prototype.destroy.call(this),this.element.classList.remove("e-ruler")},t.prototype.getPersistData=function(){return this.addOnPersist(["loaded"])},t.prototype.onPropertyChanged=function(e,i){for(var r=0,s=Object.keys(e);r100;)r/=10,s/=10;for(;s<25;)r*=10,s*=10;return s>=25&&s%25!=0&&(s=25*Math.round(s/25)),s*e/r},t.prototype.createMarkerLine=function(e,i,r){var s;return i&&((s=e.getElementById(i.id+"_marker"))&&s.parentNode.removeChild(s),s=Bi("line",r)),s},t.prototype.drawRulerMarker=function(e,i,r){var s,o,h,d,u="Horizontal"===this.orientation,p=e.getElementsByTagName("svg");for(h=0;h0)for(var a=i.childNodes.length-1;a>=0;a--)i.childNodes[parseInt(a.toString(),10)].parentNode.removeChild(i.childNodes[parseInt(a.toString(),10)]);i.appendChild(s)}return s},t.prototype.wireEvents=function(){},t.prototype.unWireEvents=function(){},kc([I(5)],t.prototype,"interval",void 0),kc([I(100)],t.prototype,"segmentWidth",void 0),kc([I("Horizontal")],t.prototype,"orientation",void 0),kc([I("RightOrBottom")],t.prototype,"tickAlignment",void 0),kc([I("red")],t.prototype,"markerColor",void 0),kc([I(25)],t.prototype,"thickness",void 0),kc([I(null)],t.prototype,"arrangeTick",void 0),kc([I(400)],t.prototype,"length",void 0),t}(yi);function eF(n,t){var e=document.getElementById(n.element.id+(t?"_hRuler":"_vRuler")),i=qa(n),r=tF(n);e||(e=Tt("div",{id:n.element.id+(t?"_hRuler":"_vRuler"),style:"height:"+(t?i.height:r.height+100)+"px;overflow:hidden;width:"+(t?r.width+100:i.width)+"px;position:absolute;font-size:11px;"+(t?"margin-left:"+i.width+"px;":"margin-top:"+i.height+"px;")})),n.element.insertBefore(e,n.element.firstChild);var l=t?n.rulerSettings.horizontalRuler:n.rulerSettings.verticalRuler,h=new Qne(l);h.orientation=t?"Horizontal":"Vertical",h.length=(t?r.width:r.height)+l.segmentWidth,h.appendTo("#"+n.element.id+(t?"_hRuler":"_vRuler")),t?n.hRuler=h:n.vRuler=h;var c=document.getElementById(n.element.id+(t?"_hRuler":"_vRuler"));t?n.hRuler.element=c:n.vRuler.element=c}function ZI(n){var t=-n.scroller.horizontalOffset,e=-n.scroller.verticalOffset;n&&n.rulerSettings.showRulers?(n.hRuler.length=0,n.vRuler.length=0,void 0!==t&&n.hRuler.element&&iF(n,n.hRuler,t,!0),void 0!==e&&n.vRuler.element&&iF(n,n.vRuler,e,!1)):Xx(n)}function Xx(n){an(n.element.id+"_hRuler"),an(n.element.id+"_vRuler"),an(n.element.id+"_overlapRuler")}function qa(n){var t=0,e=0;return n.rulerSettings.showRulers&&(t=n.rulerSettings.horizontalRuler.thickness,e=n.rulerSettings.verticalRuler.thickness),new me(e,t)}function tF(n){var t=qa(n),e=n.scroller.viewPortHeight,i=n.scroller.viewPortWidth;return i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},rF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Jne(t,n),t.prototype.getClassName=function(){return"UserHandle"},Fn([I("")],t.prototype,"name",void 0),Fn([I("")],t.prototype,"pathData",void 0),Fn([I("")],t.prototype,"content",void 0),Fn([I("")],t.prototype,"source",void 0),Fn([I("#000000")],t.prototype,"backgroundColor",void 0),Fn([I("Top")],t.prototype,"side",void 0),Fn([I("")],t.prototype,"borderColor",void 0),Fn([I(.5)],t.prototype,"borderWidth",void 0),Fn([I(25)],t.prototype,"size",void 0),Fn([I("white")],t.prototype,"pathColor",void 0),Fn([I(10)],t.prototype,"displacement",void 0),Fn([I(!0)],t.prototype,"visible",void 0),Fn([I(0)],t.prototype,"offset",void 0),Fn([re({},$n)],t.prototype,"margin",void 0),Fn([I("Center")],t.prototype,"horizontalAlignment",void 0),Fn([I("Center")],t.prototype,"verticalAlignment",void 0),Fn([I(!1)],t.prototype,"disableNodes",void 0),Fn([I(!1)],t.prototype,"disableConnectors",void 0),Fn([re({},xd)],t.prototype,"tooltip",void 0),Fn([I("")],t.prototype,"template",void 0),t}(Ee);function nF(n){return Kne[n.toString()]}var Kne={Action:"M 90 82.895 C 90 86.819 86.776 90 82.8 90 H 7.2 C 3.224 90 0 86.819 0 82.895 V 7.105 C 0 3.181 3.224 0 7.2 0 h 75.6 C 86.776 0 90 3.181 90 7.105 V 82.895 Z",Decision:"M10,19.707L0.293,10L10,0.293L19.707,10L10,19.707z",MergeNode:"M10,19.707L0.293,10L10,0.293L19.707,10L10,19.707z",InitialNode:"M10,19.5c-5.238,0-9.5-4.262-9.5-9.5S4.762,0.5,10,0.5s9.5,4.262,9.5,9.5S15.238,19.5,10,19.5z",ForkNode:"m0.75,0.75l636.00002,0l0,290l-636.00002,0l0,-290z",JoinNode:"m0.75,0.75l636.00002,0l0,290l-636.00002,0l0,-290z",TimeEvent:"M50.001,0.00286865 L25.001,25.0029 L0.000976562,0.00286865 L50.001,0.00286865 z M0.000976562,50.0029 L25.001,25.0029 L50.001,50.0029 L0.000976562,50.0029 z",AcceptingEvent:"M17.8336 32.164 L29.64 24 L17.32 16 L48.1664 16 L48.5 32 Z",SendSignal:"M48.164 31.8336 L56 23.832 L47.836 16 L16.168 16 L16.1668 31.8336 Z",ReceiveSignal:"M48.1664 31.8336 L39.836 24 L47.836 16 L16.168 16 L16.168 31.836 Z",StructuredNode:"M0,0 L50,0 L50,50 L0,50 z",Note:"M20 12 L4 12 L4 22 L22 22 L22 14 L20 14 L20 12 L22 14 Z"},JI=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),$a=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},ese=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return JI(t,n),$a([I()],t.prototype,"key",void 0),$a([I()],t.prototype,"keyModifiers",void 0),t}(Ee),sF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return JI(t,n),t.prototype.getClassName=function(){return"Command"},$a([I("")],t.prototype,"name",void 0),$a([I()],t.prototype,"canExecute",void 0),$a([I()],t.prototype,"execute",void 0),$a([re({},ese)],t.prototype,"gesture",void 0),$a([I("")],t.prototype,"parameter",void 0),t}(Ee),tse=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return JI(t,n),$a([Bt([],sF)],t.prototype,"commands",void 0),t}(Ee),ise=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return JI(t,n),$a([I()],t.prototype,"show",void 0),$a([I()],t.prototype,"showCustomMenuOnly",void 0),$a([I()],t.prototype,"items",void 0),t}(Ee),Zp=function(){function n(){}return n.prototype.renderShadow=function(t,e,i,r){void 0===i&&(i=null);var l,o=z.transform({x:0,y:0},t.shadow.angle,t.shadow.distance);r&&(l=r.getElementById(e.id+"_shadow")),l||(l=document.createElementNS("http://www.w3.org/2000/svg",i?"path":"rect"),e.appendChild(l));var h={id:e.id+"_shadow",fill:t.shadow.color,stroke:t.shadow.color,opacity:t.shadow.opacity.toString(),transform:"rotate("+t.angle+","+(t.x+t.width*t.pivotX)+","+(t.y+t.height*t.pivotY)+")translate("+(t.x+o.x)+","+(t.y+o.y)+")"};if(r){var c=r.getElementById(e.id);c&&c.insertBefore(l,c.firstChild)}ai(l,h),i?i&&this.renderPath(l,t,i):ai(l,{width:t.width,height:t.height})},n.prototype.parseDashArray=function(t){return[]},n.prototype.drawRectangle=function(t,e,i,r,s,o,a,l,h){var c,d,u,p;e.shadow&&!r&&this.renderShadow(e,t,void 0,o),c=e.id===t.id?e.id+"_container":e.id,o&&(d=o.getElementById(c)),(!d||s)&&(d=document.createElementNS("http://www.w3.org/2000/svg","rect"),t.appendChild(d)),o&&!e.shadow&&(u=o.getElementById(e.id+"_groupElement_shadow"))&&u.parentNode.removeChild(u),p=l?{id:c,x:e.x.toString(),y:e.y.toString(),width:e.width.toString(),height:e.height.toString(),visibility:e.visible?"visible":"hidden",transform:"rotate("+e.angle+","+(e.x+e.width/2)+","+(e.y+e.height/2)+")",rx:e.cornerRadius||0,ry:e.cornerRadius||0,opacity:e.opacity}:{id:c,x:e.x.toString(),y:e.y.toString(),width:e.width.toString(),height:e.height.toString(),visibility:e.visible?"visible":"hidden",transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")",rx:e.cornerRadius||0,ry:e.cornerRadius||0,opacity:e.opacity},a&&(p.role="img",p["aria-label"]=a);var f=e.class||"";h||(f.includes("e-diagram-resize-handle")||f.includes("e-diagram-endpoint-handle")||f.includes("e-diagram-bezier-control-handle"))&&(f+=" e-disabled"),e.class&&(p.class=f),a||(p["pointer-events"]="none"),ai(d,p),this.setSvgStyle(d,e,i)},n.prototype.updateSelectionRegion=function(t,e){var i;i=t.parentNode.getElementById(e.id);var r={id:e.id,x:e.x.toString(),y:e.y.toString(),width:e.width.toString(),height:e.height.toString(),transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")",class:"e-diagram-selected-region"};i||(i=document.createElementNS("http://www.w3.org/2000/svg","rect"),t.appendChild(i)),this.setSvgStyle(i,e),ai(i,r)},n.prototype.createGElement=function(t,e){return Bi(t,e)},n.prototype.drawLine=function(t,e){var i=document.createElementNS("http://www.w3.org/2000/svg","line");this.setSvgStyle(i,e);var r=e.x+e.width*e.pivotX,s=e.y+e.height*e.pivotY,o={id:e.id,x1:e.startPoint.x+e.x,y1:e.startPoint.y+e.y,x2:e.endPoint.x+e.x,y2:e.endPoint.y+e.y,stroke:e.stroke,"stroke-width":e.strokeWidth.toString(),opacity:e.opacity.toString(),transform:"rotate("+e.angle+" "+r+" "+s+")",visibility:e.visible?"visible":"hidden"};e.class&&(o.class=e.class),ai(i,o),t.appendChild(i)},n.prototype.drawCircle=function(t,e,i,r){var s=document.createElementNS("http://www.w3.org/2000/svg","circle");this.setSvgStyle(s,e);var o=e.class||"";i||(o+=" e-disabled");var a={id:e.id,cx:e.centerX,cy:e.centerY,r:e.radius,visibility:e.visible?"visible":"hidden",class:o};r&&(a.role="img",a["aria-label"]=r),s.style.display=e.visible?"block":"none",ai(s,a),t.appendChild(s)},n.prototype.drawPath=function(t,e,i,r,s,o,a){var h,c,l=[];l=XB(l=Dd(e.data)),e.shadow&&this.renderShadow(e,t,l,s),s&&!e.shadow&&(h=s.getElementById(e.id+"_groupElement_shadow"))&&h.parentNode.removeChild(h),s&&(c=s.getElementById(e.id)),(!c||r)&&(c=document.createElementNS("http://www.w3.org/2000/svg","path"),t.appendChild(c)),this.renderPath(c,e,l);var d={};d=a?{id:e.id,transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")translate("+e.x+","+e.y+"),scale("+a+")",visibility:e.visible?"visible":"hidden",opacity:e.opacity}:{id:e.id,transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")translate("+e.x+","+e.y+")",visibility:e.visible?"visible":"hidden",opacity:e.opacity},o&&(d.role="img",d["aria-label"]=o),e.class&&(d.class=e.class),ai(c,d),this.setSvgStyle(c,e,i)},n.prototype.renderPath=function(t,e,i){var r,s,o,a,l,h,c,d,u=i,p="";for(l=0,h=0,d=0,c=u.length;de.width&&"Wrap"!==e.textOverflow&&"NoWrap"===e.textWrapping&&(h[0].text=VF(e.content,e)),v=0;vD&&(u.text=u.text.slice(0,u.text.length-3),u.text=u.text.concat("..."),l.data=u.text),this.alignText(y,p,u,l,f,g,v,e,h),C+=u.dy}}C&&e.isHorizontalLane&&(M=e.parentOffsetX+e.pivotX,w=e.parentOffsetY+e.pivotY,e.y=e.parentOffsetY-C*e.pivotY+.5),e.textDecoration&&"LineThrough"===e.textDecoration&&(e.textDecoration=ub(e.textDecoration));var R={id:e.id+"_text",fill:e.color,visibility:e.visible?"visible":"hidden","text-decoration":e.textDecoration,transform:"rotate("+e.angle+","+M+","+w+")translate("+e.x+","+e.y+")",opacity:e.opacity};r&&(R.role="img",R["aria-label"]=r),ai(y,R)}},n.prototype.alignText=function(t,e,i,r,s,o,a,l,h){"justify"!==l.textAlign?this.setText(t,e,i,r,s,o,l):a!==h.length-1?this.setText(t,e,i,r,s,o,l,l.width,"spacing"):this.setText(t,e,i,r,s,o,l)},n.prototype.setText=function(t,e,i,r,s,o,a,l,h){ai(e,"justify"!==a.textAlign?{x:s.toString(),y:o.toString()}:{x:s.toString(),y:o.toString(),textLength:l||0,lengthAdjust:h||"spacing"}),t.setAttribute("fill",i.text),e.appendChild(r),t.appendChild(e)},n.prototype.drawImage=function(t,e,i,r){var s;i&&(s=i.getElementById(e.id+"image")),s||(s=document.createElementNS("http://www.w3.org/2000/svg","image"),t.appendChild(s));var o=new Image;o.src=e.source;var a="None"!==e.scale?e.scale:"",l=e.alignment,h=l.charAt(0).toLowerCase()+l.slice(1);"Stretch"!==a&&(h+=" "+a.charAt(0).toLowerCase()+a.slice(1)),ai(s,{id:e.id+"image",x:e.x.toString(),y:e.y.toString(),transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")",width:e.width.toString(),visibility:e.visible?"visible":"hidden",height:e.height.toString(),preserveAspectRatio:h,opacity:e.opacity.toString()}),s.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",o.src.toString())},n.prototype.drawHTMLContent=function(t,e,i,r,s){var o,a;if(e&&(o=e.querySelector("#"+t.id+"_html_element")),!o){(a=e.querySelector("#"+t.id+"_html_element")||e.querySelector("#"+t.nodeId+"_html_element"))||(a=Tt("div",{id:t.nodeId+"_html_element",class:"foreign-object"})),o=Tt("div",{id:t.id+"_html_element",class:"foreign-object"});var c=document.getElementById(t.diagramId).ej2_instances[0],d=!1;if(e.parentNode&&e.parentNode.parentNode&&e.parentNode.parentNode.parentNode&&e.parentNode.parentNode.parentNode.classList.contains("e-overview")&&(d=!0),d)c.isReact?c.renderReactTemplates(function(){o.appendChild(t.template.cloneNode(!0))}):o.appendChild(t.template.cloneNode(!0));else{if("string"==typeof t.template){var u=document.createElement("div");u.innerHTML=t.template,t.template=u,c.selectedItems.userHandles.filter(function(g){return g.name===t.id.split("_shape")[0]&&""!==g.template})[0].template=t.template}t.isTemplate&&t.template?o.appendChild(t.template):t.template&&o.appendChild(t.template.cloneNode(!0))}void 0!==s&&e.childNodes.length>s&&e.insertBefore(o,e.childNodes[parseInt(s.toString(),10)]),a.appendChild(o),e.appendChild(a)}var f=En(t).topLeft;o.setAttribute("style","height:"+t.actualSize.height+"px; width:"+t.actualSize.width+"px;left:"+f.x+"px; top:"+f.y+"px;position:absolute;transform:rotate("+(t.rotateAngle+t.parentTransform)+"deg);pointer-events:"+(r?"all":"none")+";visibility:"+(t.visible?"visible":"hidden")+";opacity:"+t.style.opacity+";")},n.prototype.drawNativeContent=function(t,e,i,r,s){var o,a;if(s&&(o=s.getElementById(t.id+"_native_element"),a=s.getElementById(t.id+"_clip")),!o){(o=document.createElementNS("http://www.w3.org/2000/svg","g")).setAttribute("id",t.id+"_native_element"),o.appendChild(t.template.cloneNode(!0));var l=this.createGElement("g",{id:t.id+"_inner_native_element"});l.appendChild(o),e.appendChild(l)}a&&o.removeChild(a),o.setAttribute("style","visibility:"+(t.visible?"visible":"hidden")+";opacity:"+t.style.opacity+";"),this.setNativTransform(t,o,i,r),"Slice"===t.scale&&this.drawClipPath(t,o,i,r,s),ai(o,t.description?{role:"img","aria-label":t.description}:{})},n.prototype.setNativTransform=function(t,e,i,r){var s=0!==t.contentSize.width?t.contentSize.width:1,o=0!==t.contentSize.height?t.contentSize.height:1;e.setAttribute("transform","rotate("+t.parentTransform+","+t.offsetX+","+t.offsetY+") translate("+(t.offsetX-t.templatePosition.x*r/s-r*t.pivot.x)+","+(t.offsetY-t.templatePosition.y*i/o-i*t.pivot.y)+") scale("+r/s+","+i/o+")")},n.prototype.drawClipPath=function(t,e,i,r,s){var o=t.contentSize.width,a=t.contentSize.height,l=t.width/(r/o),h=t.height/(i/a),c=t.templatePosition.x+(t.width>=t.height?0:(o-l)/2),d=t.templatePosition.y+(t.height>=t.width?0:(a-h)/2),u=s.getElementById(t.id+"_clip");(u=document.createElementNS("http://www.w3.org/2000/svg","clipPath")).setAttribute("id",t.id+"_clip"),e.appendChild(u);var p=s.getElementById(t.id+"_clip_rect");return p=document.createElementNS("http://www.w3.org/2000/svg","rect"),u.appendChild(p),ai(p,{id:t.id+"_clip_rect",width:l.toString(),height:h.toString(),x:c.toString(),y:d.toString()}),nm()?e.setAttribute("clip-path","url("+location.protocol+"//"+location.host+location.pathname+"#"+t.id+"_clip)"):e.setAttribute("clip-path","url(#"+t.id+"_clip)"),e},n.prototype.renderGradient=function(t,e,i){var r,s,o,h,c,a=ST(i),l=a.getElementById(i+"gradient_pattern");if(l||(l=Bi("defs",{id:i+"gradient_pattern"}),a.insertBefore(l,a.firstChild)),gF(e.id),"None"!==t.gradient.type){for(var d=0;dt.width&&("Ellipsis"===t.textOverflow||"Clip"===t.textOverflow)&&"NoWrap"===t.textWrapping?0:.5*t.width:"right"===t.textAlign&&(c=1*t.width),s.x=0+c+(e?e.x:0),s.y=1.2+d-r.height/2,s},n}(),Pc=function(){function n(t,e,i){this.renderer=null,this.isSvgMode=!0,this.transform={x:0,y:0},this.diagramId=t,this.element=xt(this.diagramId),this.svgRenderer=e,this.isSvgMode=i,this.renderer=i?new Zp:new bo}return n.prototype.setCursor=function(t,e){t.style.cursor=e},n.prototype.setLayers=function(){this.iconSvgLayer=this.element.getElementsByClassName("e-ports-expand-layer")[0],this.adornerSvgLayer=this.element.getElementsByClassName("e-adorner-layer")[0],this.nativeSvgLayer=this.element.getElementsByClassName("e-native-layer")[0],this.diagramSvgLayer=this.element.getElementsByClassName("e-diagram-layer")[0]},n.prototype.getAdornerLayer=function(){return mT(this.diagramId)},n.prototype.getParentSvg=function(t,e,i){return this.diagramId&&t&&t.id?t.id.split("_icon_content").length>1||t.id.split("_nodeport").length>1||t.elementActions&Xr.ElementIsPort?this.iconSvgLayer:e&&"selector"===e?this.adornerSvgLayer:t instanceof Cn?this.nativeSvgLayer:this.diagramSvgLayer:i},n.prototype.getParentElement=function(t,e,i,r){var s=e;if(i&&this.diagramId&&t&&t.id){t.id.split("_icon_content").length>1?(s=i.getElementById(this.diagramId+"_diagramExpander"),e=null):t.id.split("_nodeport").length>1?s=i.getElementById(this.diagramId+"_diagramPorts"):t instanceof Cn?(s=i.getElementById(this.diagramId+"_nativeLayer"),e=null):t.elementActions&Xr.ElementIsPort?(s=i.getElementById(this.diagramId+"_diagramPorts"),e=null):s=i.getElementById(this.diagramId+"_diagramLayer");var o=this.getGroupElement(t,e||s,r);s=o.g,o.svg&&(i=o.svg)}return{g:s,svg:i}},n.prototype.getGroupElement=function(t,e,i){var r,o,s=this.getParentSvg(t);if(e&&s){if(s&&!(r=s.getElementById(t.id+"_groupElement"))&&s!==this.nativeSvgLayer){var a=this.nativeSvgLayer;r=a.getElementById(t.id+"_groupElement"),o=a}r||(r=this.svgRenderer.createGElement("g",{id:t.id+"_groupElement"}),void 0!==i&&e.childNodes.length>i?e.insertBefore(r,e.childNodes[parseInt(i.toString(),10)]):e.appendChild(r))}return{g:r,svg:o}},n.prototype.renderElement=function(t,e,i,r,s,o,a,l,h,c,d){t instanceof Cs?(t.id=t.id?t.id:Qe(),this.renderContainer(t,e,i,r,s,o,a,l,h,c,d)):t instanceof MI?this.renderImageElement(t,e,r,s,a):t instanceof Ke?this.renderPathElement(t,e,r,s,a,h,d):t instanceof si?this.renderTextElement(t,e,r,s,a,c):t instanceof Cn?this.renderNativeElement(t,e,r,s,a):t instanceof Jn?this.renderHTMLElement(t,e,i,r,s,a,l):this.renderRect(t,e,r,s,h)},n.prototype.drawSelectionRectangle=function(t,e,i,r,s,o){var a={width:i*o.scale,height:r*o.scale,x:.5+(t=(t+o.tx)*o.scale),y:.5+(e=(e+o.ty)*o.scale),fill:"transparent",stroke:"gray",angle:0,pivotX:.5,pivotY:.5,strokeWidth:1,dashArray:"6 3",opacity:1,visible:!0,id:s.id+"_selected_region"},l=this.getAdornerLayer();this.svgRenderer.updateSelectionRegion(l,a)},n.prototype.renderHighlighter=function(t,e,i){var r=t.actualSize.width||2,s=t.actualSize.height||2,o=t.offsetX-r*t.pivot.x,a=t.offsetY-s*t.pivot.y;this.svgRenderer.drawRectangle(e,{width:r*i.scale,height:s*i.scale,x:o=(o+i.tx)*i.scale,y:a=(a+i.ty)*i.scale,fill:"transparent",stroke:"#8CC63F",angle:t.rotateAngle,pivotX:t.pivot.x,pivotY:t.pivot.y,strokeWidth:4,dashArray:"",opacity:1,cornerRadius:0,visible:!0,id:e.id+"_highlighter",class:"e-diagram-highlighter"},this.diagramId,void 0,void 0,e)},n.prototype.renderSelectionRectangle=function(t,e,i,r){var s=t.actualSize.width||2,o=t.actualSize.height||2,a=t.offsetX-s*t.pivot.x,l=t.offsetY-o*t.pivot.y,h={width:s*i.scale,height:o*i.scale,x:a=(a+i.tx)*i.scale,y:l=(l+i.ty)*i.scale,fill:"transparent",stroke:"#00cc00",angle:t.rotateAngle,pivotX:t.pivot.x,pivotY:t.pivot.y,strokeWidth:r?2:1,dashArray:"",opacity:1,cornerRadius:0,visible:!0,id:t.id+"_highlighter",class:r?"e-diagram-first-selection-indicator e-diagram-selection-indicator":"e-diagram-selection-indicator"},c=this.getParentSvg(t,"selector");this.svgRenderer.drawRectangle(e,h,this.diagramId,void 0,void 0,c)},n.prototype.renderSelectionLine=function(t,e,i,r){var s=this.getBaseAttributes(t,i);s.data=t.absolutePath,s.id=s.id+"_highlighter";var o=t.description?t.description:t.id;this.isSvgMode||(s.x=t.flipOffset.x?t.flipOffset.x:s.x,s.y=t.flipOffset.y?t.flipOffset.y:s.y),i&&(s.x=s.x*i.scale,s.y=s.y*i.scale),s.stroke="#00cc00",s.strokeWidth=r?2:1,s.class=r?"e-diagram-first-selection-indicator e-diagram-selection-indicator":"e-diagram-selection-indicator";var a=this.getParentSvg(t,"selector");this.svgRenderer.drawPath(e,s,this.diagramId,void 0,a,o,i.scale)},n.prototype.renderStackHighlighter=function(t,e,i,r,s,o,a){var l=t.actualSize.width||2,h=t.offsetX-l*t.pivot.x,c=t.actualSize.height||2,d=t.offsetY-c*t.pivot.y;h=(h+i.tx)*i.scale;var u,p=t.bounds,f="";if(d=(d+i.ty)*i.scale,r)if(o){var v,y;u="M 0 0 L "+(2+(g=l*i.scale))+" 0 Z",v=t.actualSize.width/Number(p.width?p.width:1)*i.scale,y=t.actualSize.height/Number(p.height?p.height:1)*i.scale,f=mI(yI(Dd("M7,4 L8,4 8,7 11,7 11,8 8,8 8,11 7,11 7,8 4,8 4,7 7,7 z M7.5,0.99999994C3.9160004,1 1,3.9160004 0.99999994,7.5 1,11.084 3.9160004,14 7.5,14 11.084,14 14,11.084 14,7.5 14,3.9160004 11.084,1 7.5,0.99999994 z M7.5,0 C11.636002,0 15,3.3639984 15,7.5 15,11.636002 11.636002,15 7.5,15 3.3640003,15 0,11.636002 0,7.5 0,3.3639984 3.3640003,0 7.5,0 z")),v+g+2,y-8,!1,p.x,p.y,0,0),s.y>=t.offsetY&&(d+=c)}else{var g;a&&s.y>=t.offsetY&&(d+=c*i.scale),u="M -10 -10 L 0 0 Z M -10 10 L 0 0 Z M 0 0 L "+(g=l*i.scale)+" 0 Z M "+g+" 0 L "+(g+10)+" 10 Z L "+(g+10)+" -10 Z"}else u="M 10 -10 L 0 0 Z M -10 -10 L 0 0 Z M 0 0 L 0 "+(g=c*i.scale)+" Z M 0 "+g+" L -10 "+(g+10)+" Z L 10 "+(g+10)+" Z",s.x>=t.offsetX&&(h+=l*i.scale);this.svgRenderer.drawPath(e,{data:u+f,width:l*i.scale,height:c*i.scale,x:h,y:d,fill:"transparent",stroke:"#8CC63F",angle:t.rotateAngle,pivotX:t.pivot.x,pivotY:t.pivot.y,strokeWidth:1,dashArray:"",opacity:1,visible:!0,id:e.id+"_stack_highlighter",class:"e-diagram-highlighter"},this.diagramId)},n.prototype.drawLine=function(t,e){this.svgRenderer.drawLine(t,e)},n.prototype.drawPath=function(t,e){this.svgRenderer.drawPath(t,e,this.diagramId)},n.prototype.renderResizeHandle=function(t,e,i,r,s,o,a,l,h,c,d){var u=t.offsetX-t.actualSize.width*t.pivot.x,p=t.offsetY-t.actualSize.height*t.pivot.y,f=t.actualSize.height,g=t.actualSize.width;!c&&i&bt.Rotate&&BI(this.rendererActions)&&!A3(this.rendererActions)&&(this.renderPivotLine(t,e,o,s,a),this.renderRotateThumb(t,e,o,s,a)),this.renderBorder(t,e,o,l,h,c);var v=t.actualSize.width*r,y=t.actualSize.height*r;!h&&BI(this.rendererActions)&&!A3(this.rendererActions)&&(t.isTextAnnotation||(v>=40&&y>=40&&(s&mr.ResizeNorthWest&&this.renderCircularHandle("resizeNorthWest",t,u,p,e,qr(s,"ResizeNorthWest"),i&bt.ResizeNorthWest,o,void 0,a,{"aria-label":"Thumb to resize the selected object on top left side direction"},void 0,"e-diagram-resize-handle e-northwest",d),s&mr.ResizeNorthEast&&this.renderCircularHandle("resizeNorthEast",t,u+g,p,e,qr(s,"ResizeNorthEast"),i&bt.ResizeNorthEast,o,void 0,a,{"aria-label":"Thumb to resize the selected object on top right side direction"},void 0,"e-diagram-resize-handle e-northeast",d),s&mr.ResizeSouthWest&&this.renderCircularHandle("resizeSouthWest",t,u,p+f,e,qr(s,"ResizeSouthWest"),i&bt.ResizeSouthWest,o,void 0,a,{"aria-label":"Thumb to resize the selected object on bottom left side direction"},void 0,"e-diagram-resize-handle e-southwest",d),s&mr.ResizeSouthEast&&this.renderCircularHandle("resizeSouthEast",t,u+g,p+f,e,qr(s,"ResizeSouthEast"),i&bt.ResizeSouthEast,o,void 0,a,{"aria-label":"Thumb to resize the selected object on bottom right side direction"},void 0,"e-diagram-resize-handle e-southeast",d)),s&mr.ResizeNorth&&this.renderCircularHandle("resizeNorth",t,u+g/2,p,e,qr(s,"ResizeNorth"),i&bt.ResizeNorth,o,void 0,a,{"aria-label":"Thumb to resize the selected object on top side direction"},void 0,"e-diagram-resize-handle e-north",d),s&mr.ResizeSouth&&this.renderCircularHandle("resizeSouth",t,u+g/2,p+f,e,qr(s,"ResizeSouth"),i&bt.ResizeSouth,o,void 0,a,{"aria-label":"Thumb to resize the selected object on bottom side direction"},void 0,"e-diagram-resize-handle e-south",d),s&mr.ResizeWest&&this.renderCircularHandle("resizeWest",t,u,p+f/2,e,qr(s,"ResizeWest"),i&bt.ResizeWest,o,void 0,a,{"aria-label":"Thumb to resize the selected object on left side direction"},void 0,"e-diagram-resize-handle e-west",d),s&mr.ResizeEast&&this.renderCircularHandle("resizeEast",t,u+g,p+f/2,e,qr(s,"ResizeEast"),i&bt.ResizeEast,o,void 0,a,{"aria-label":"Thumb to resize the selected object on right side direction"},void 0,"e-diagram-resize-handle e-east",d)))},n.prototype.renderEndPointHandle=function(t,e,i,r,s,o,a,l,h,c){var f,g,d=t.sourcePoint,u=t.targetPoint,p=t.wrapper;if(this.renderCircularHandle("connectorSourceThumb",p,d.x,d.y,e,qr(r,"ConnectorSourceThumb"),i&bt.ConnectorSource,s,o,void 0,{"aria-label":"Thumb to move the source point of the connector"},void 0,"e-diagram-endpoint-handle e-sourceend",c),this.renderCircularHandle("connectorTargetThumb",p,u.x,u.y,e,qr(r,"ConnectorTargetThumb"),i&bt.ConnectorTarget,s,a,void 0,{"aria-label":"Thumb to move the target point of the connector"},void 0,"e-diagram-endpoint-handle e-targetend",c),l)if("Straight"===t.type&&t.segments.length>0)for(f=0;f0)for(f=0;f=3&&3===t.segments.length&&(S=1,b=t.segments.length-1),S=t.segments.length>t.maxSegmentThumb+2?2:S,b=t.segments.length>t.maxSegmentThumb+2?t.segments.length-2:b,1===t.segments.length&&t.segments[0].points.length<=2&&(S=1,b=t.segments.length),f=S;f=50&&i.allowDrag),this.renderOrthogonalThumb(t+"_"+(d+1),e,(i.points[parseInt(d.toString(),10)].x+i.points[d+1].x)/2,(i.points[parseInt(d.toString(),10)].y+i.points[d+1].y)/2,r,h,l,o,a,u)}else for(d=0;d=50&&i.allowDrag),this.renderOrthogonalThumb(t+"_"+(d+1),e,(i.points[parseInt(d.toString(),10)].x+i.points[d+1].x)/2,(i.points[parseInt(d.toString(),10)].y+i.points[d+1].y)/2,r,h,l,o,a,u)},n.prototype.renderOrthogonalThumb=function(t,e,i,r,s,o,a,l,h,c){var d,g,u=0,p=document.getElementById(this.diagramId);p&&(g=p.ej2_instances[0]);var y=h.constraints&qe.InheritSegmentThumbShape?g.segmentThumbShape:h.segmentThumbShape,b=h.constraints&qe.InheritSegmentThumbSize?g.segmentThumbSize:h.segmentThumbSize;if(d="horizontal"===a?function rre(n){return are[""+n]}(y):n3(y),"Arrow"===y||"DoubleArrow"===y||"OpenArrow"===y)switch(c){case"Bottom":case"Right":u=180;break;default:u=0}else if("Fletch"===y||"OpenFetch"===y||"IndentedArrow"===y||"OutdentedArrow"===y)switch(c){case"Bottom":u=-90;break;case"Top":u=90;break;case"Right":u=180;break;default:u=0}var M={x:(i+l.tx)*l.scale-b/2,y:(r+l.ty)*l.scale-b/2,angle:u,fill:"#e2e2e2",stroke:"black",strokeWidth:1,dashArray:"",data:d,width:b,height:b,pivotX:.5,pivotY:.5,opacity:1,visible:o,id:t,class:"e-diagram-ortho-segment-handle"},w=of(M.data),C=new me(M.width,M.height),D=new Ke;M.data=D.updatePath(M.data,w,C),this.svgRenderer.drawPath(s,M,this.diagramId)},n.prototype.renderPivotLine=function(t,e,i,r,s){var o=t,l=!!(r&mr.Rotate);s&&(l=!1);var h=this.getBaseAttributes(o,i);h.fill="None",h.stroke="black",h.strokeWidth=1,h.dashArray="2,3",h.visible=l;var c=i.scale;h.x*=c,h.y*=c,h.width*=c,h.height*=c,h.id="pivotLine",h.class="e-diagram-pivot-line";var u={x:o.actualSize.width*o.pivot.x*c,y:0};h.startPoint={x:o.actualSize.width*o.pivot.x*c,y:-20},h.endPoint=u,this.svgRenderer.drawLine(e,h)},n.prototype.renderBezierLine=function(t,e,i,r,s,o){var l=this.getBaseAttributes(e,o);l.id=t,l.stroke="black",l.strokeWidth=1,l.dashArray="3,3",l.fill="None",l.class="e-diagram-bezier-control-line",l.x=0,l.y=0;var h=o.scale,g={x:(s.x+o.tx)*h,y:(s.y+o.ty)*h};l.startPoint={x:(r.x+o.tx)*h,y:(r.y+o.ty)*h},l.endPoint=g,this.svgRenderer.drawLine(i,l)},n.prototype.renderCircularHandle=function(t,e,i,r,s,o,a,l,h,c,d,u,p,f){var g=e,v={x:i,y:r};if(0!==g.rotateAngle||0!==g.parentTransform){var y=Hi();qi(y,g.rotateAngle+g.parentTransform,g.offsetX,g.offsetY),v=Je(y,v)}var S=this.getBaseAttributes(g);S.stroke="black",S.strokeWidth=1,void 0!==u?(S.id="segmentEnd_"+u,S.fill="#e2e2e2"):S.fill=h?"#8CC63F":"white",S.cornerRadius=f/2,S.angle=e.rotateAngle,S.id=t,S.visible=o,S.class=p,S.width=f,S.height=f,S.x=(v.x+l.tx)*l.scale,S.y=(v.y+l.ty)*l.scale,S.x=S.x-S.width/2,S.y=S.y-S.height/2,h&&(S.class+=" e-connected"),c&&(S.visible=!1);var b=this.getParentSvg(e,"selector");this.svgRenderer.drawRectangle(s,S,this.diagramId,!0,!0,b,d,!0,a)},n.prototype.renderBezierHandle=function(t,e,i,r,s,o,a,l,h,c,d,u,p){var v,f=document.getElementById(this.diagramId);f&&(v=f.ej2_instances[0]);var y=e,S={x:i,y:r};if(0!==y.rotateAngle||0!==y.parentTransform){var b=Hi();qi(b,y.rotateAngle+y.parentTransform,y.offsetX,y.offsetY),S=Je(b,S)}var D=a.constraints&qe.InheritSegmentThumbSize?v.segmentThumbSize:a.segmentThumbSize,A=n3(a.constraints&qe.InheritSegmentThumbShape?v.segmentThumbShape:a.segmentThumbShape),x=this.getBaseAttributes(y);x.stroke="black",x.strokeWidth=1,void 0!==d?(x.id="segmentEnd_"+d,x.fill="#e2e2e2"):x.fill=h?"#8CC63F":"white",x.angle=e.rotateAngle,x.id=t,x.visible=o,x.class=u,x.width=D,x.height=D,x.data=A,x.x=(S.x+l.tx)*l.scale,x.y=(S.y+l.ty)*l.scale,x.x=x.x-x.width/2,x.y=x.y-x.height/2,h&&(x.class+=" e-connected"),c&&(x.visible=!1);var R=of(x.data),L=new me(x.width,x.height),O=new Ke;x.data=O.updatePath(x.data,R,L);var N=this.getParentSvg(e,"selector");this.svgRenderer.drawPath(s,x,this.diagramId,!0,N)},n.prototype.renderBorder=function(t,e,i,r,s,o){var l=this.getBaseAttributes(t,i);l.x*=i.scale,l.y*=i.scale,l.width*=i.scale,l.height*=i.scale,l.fill="transparent",l.stroke="#097F7F",l.strokeWidth=1.2,l.gradient=null,l.dashArray="6,3",l.class="e-diagram-selector",o&&(l.class+=" e-diagram-lane"),l.id="borderRect",l.id=this.rendererActions&Qa.DrawSelectorBorder?"borderRect_symbol":"borderRect",r||(l.class+=" e-disabled"),s&&(l.class+=" e-thick-border"),l.cornerRadius=0;var h=this.getParentSvg(t,"selector");this.svgRenderer.drawRectangle(e,l,this.diagramId,void 0,!0,h)},n.prototype.renderUserHandler=function(t,e,i,r,s,o){for(var l,a=t.wrapper,h=0,c=t.userHandles;h0||d.disableNodes&&t.nodes.length>0||"Drag"===s&&o)&&(l=!1);var u=document.getElementById(d.name+"_template_hiddenUserHandle");u&&(d.template=u.childNodes[0].cloneNode(!0));var p=tT(t,d,i);if(p.x=(p.x+i.tx)*i.scale,p.y=(p.y+i.ty)*i.scale,d.visible&&(d.visible=!!(t.constraints&mr.UserHandle)),l)if(d.pathData){var f=d.pathData?d.pathData:d.content,g=this.getBaseAttributes(a);g.id=d.name+"_userhandle",g.fill=d.backgroundColor,g.stroke=d.borderColor,g.strokeWidth=d.borderWidth,g.centerX=p.x,g.centerY=p.y,g.radius=.5*d.size,g.class="e-diagram-userhandle-circle",g.angle=0,g.visible=d.visible,g.opacity=1,this.svgRenderer.drawCircle(e,g,1,{"aria-label":d.name+"user handle"});var y=[];y=yI(y=Dd(f));var S=of(f),w=mI(y,(d.size-.45*d.size)/S.width,(d.size-.45*d.size)/S.height,!0,S.x,S.y,0,0);S=of(w),this.svgRenderer.drawPath(e,C={x:p.x-S.width/2,y:p.y-S.height/2,angle:0,id:"",class:"e-diagram-userhandle-path",fill:d.pathColor,stroke:d.backgroundColor,strokeWidth:.5,dashArray:"",data:w,width:d.size-5,height:d.size-5,pivotX:0,pivotY:0,opacity:1,visible:d.visible},this.diagramId,void 0,void 0,{"aria-label":d.name+"user handle"})}else if(d.content){var D=new Cn(d.name,this.diagramId);D.content=d.content,D.offsetX=p.x,D.offsetY=p.y,D.id=d.name+"_shape",D.horizontalAlignment="Center",D.verticalAlignment="Center",D.visible=d.visible,D.setOffsetWithRespectToBounds(p.x,p.y,"Fraction"),D.relativeMode="Object",D.description=d.name||"User handle",D.measure(new me(d.size,d.size)),D.arrange(D.desiredSize),this.svgRenderer.drawNativeContent(D,e,d.size,d.size,this.adornerSvgLayer)}else if(d.source){var C,A=new MI;(C=this.getBaseAttributes(A,i)).width=d.size,C.height=d.size,C.x=p.x-d.size/2,C.y=p.y-d.size/2,C.sourceWidth=d.size,C.sourceHeight=d.size,C.alignment=A.imageAlign,C.source=d.source,C.scale=A.imageScale,C.visible=d.visible,C.description=d.name||"User handle",C.id=d.name+"_",this.renderer.drawImage(e,C,this.adornerSvgLayer,!1)}else{var x=new Jn(d.name,this.diagramId);x.offsetX=p.x,x.offsetY=p.y,x.id=d.name+"_shape",x.visible=d.visible,x.relativeMode="Object",x.template=d.template,x.measure(new me(d.size,d.size)),x.arrange(x.desiredSize),this.svgRenderer.drawHTMLContent(x,r,void 0,!0,void 0)}}},n.prototype.renderRotateThumb=function(t,e,i,r,s){new Ke;var a,l=new me;l.width=18,l.height=16;var d=!!(r&mr.Rotate);s&&(d=!1);var p=t.offsetX-t.actualSize.width*t.pivot.x+t.pivot.x*t.actualSize.width,f=t.offsetY-t.actualSize.height*t.pivot.y;if(a={x:(p=(p+i.tx)*i.scale)-.5*l.width,y:(f=(f+i.ty)*i.scale)-30-.5*l.height},0!==t.rotateAngle||0!==t.parentTransform){var g=Hi();qi(g,t.rotateAngle+t.parentTransform,(i.tx+t.offsetX)*i.scale,(i.ty+t.offsetY)*i.scale),a=Je(g,a)}this.svgRenderer.drawPath(e,{x:a.x,y:a.y,angle:t.rotateAngle+t.parentTransform,fill:"#231f20",stroke:"black",strokeWidth:.5,dashArray:"",data:"M 16.856144362449648 10.238890446662904 L 18.000144362449646 3.437890446662903L 15.811144362449646 4.254890446662903 C 14.837144362449646 2.5608904466629028 13.329144362449647 1.2598904466629026 11.485144362449645 0.5588904466629026 C 9.375144362449646 - 0.24510955333709716 7.071144362449646 - 0.18010955333709716 5.010144362449646 0.7438904466629028 C 2.942144362449646 1.6678904466629028 1.365144362449646 3.341890446662903 0.558144362449646 5.452890446662903 C - 0.244855637550354 7.567890446662903 - 0.17985563755035394 9.866890446662904 0.7431443624496461 11.930890446662904 C 1.6681443624496461 13.994890446662904 3.343144362449646 15.575890446662903 5.457144362449647 16.380890446662903 C 6.426144362449647 16.7518904466629 7.450144362449647 16.9348904466629 8.470144362449647 16.9348904466629 C 9.815144362449647 16.9348904466629 11.155144362449647 16.6178904466629 12.367144362449647 15.986890446662901 L 11.351144362449647 14.024890446662901 C 9.767144362449647 14.8468904466629 7.906144362449647 14.953890446662902 6.237144362449647 14.3178904466629 C 4.677144362449647 13.7218904466629 3.444144362449647 12.5558904466629 2.758144362449647 11.028890446662901 C 2.078144362449646 9.501890446662903 2.031144362449646 7.802890446662903 2.622144362449646 6.243890446662903 C 3.216144362449646 4.6798904466629025 4.387144362449646 3.442890446662903 5.914144362449646 2.760890446662903 C 7.437144362449646 2.078890446662903 9.137144362449646 2.0298904466629026 10.700144362449645 2.6258904466629027 C 11.946144362449646 3.100890446662903 12.971144362449646 3.9538904466629026 13.686144362449646 5.049890446662903 L 11.540144362449645 5.850890446662903 L 16.856144362449648 10.238890446662904 Z",width:20,height:20,pivotX:0,pivotY:0,opacity:1,visible:d,id:"rotateThumb",class:"e-diagram-rotate-handle"},this.diagramId,!0,void 0,{"aria-label":"Thumb to rotate the selected object"})},n.prototype.renderPathElement=function(t,e,i,r,s,o,a){var l=this.getBaseAttributes(t,i,o);if(l.data=t.absolutePath,l.data=t.absolutePath,t.isPathPort&&a){l.x=a[t.id]?a[t.id].cx:l.x,l.y=a[t.id]?a[t.id].cy:l.y,t.bounds.x=l.x,t.bounds.y=l.y;var h=document.getElementById(this.diagramId);h&&"PortDrag"!==h.ej2_instances[0].eventHandler.currentAction&&(t.offsetX=l.x+t.width/2,t.offsetY=l.y+t.height/2)}var u=t.description?t.description:t.id;if(this.isSvgMode||(l.x=t.flipOffset.x?t.flipOffset.x:l.x,l.y=t.flipOffset.y?t.flipOffset.y:l.y),t.isExport){var p=t.absoluteBounds,f=Dd(l.data),g=this.findAndStoreArcValues(f);l.arc=g,l.data=OF(t,p,0,l)}this.renderer.drawPath(e,l,this.diagramId,void 0,r,u)},n.prototype.findAndStoreArcValues=function(t){var e=[];return t.forEach(function(i){"A"===i.command&&e.push({r1:i.r1/2,r2:i.r2/2})}),e},n.prototype.renderSvgGridlines=function(t,e,i,r,s,o){var a=document.createElementNS("http://www.w3.org/2000/svg","pattern"),l=document.createElementNS("http://www.w3.org/2000/svg","defs");l.setAttribute("id",this.diagramId+"_grid_pattern_defn"),(t.constraints&ei.ShowHorizontalLines||t.constraints&ei.ShowVerticalLines)&&a.setAttribute("id",this.diagramId+"_pattern");var h=0,c=0,d=0,u=0,p=1,f=!1,g="Lines"===t.gridType,v=g?t.verticalGridlines.lineIntervals:t.verticalGridlines.dotIntervals,y=g?t.horizontalGridlines.lineIntervals:t.horizontalGridlines.dotIntervals;if(r.showRulers&&r.dynamicGrid&&s&&o)d=o.updateSegmentWidth(i.scale),u=s.updateSegmentWidth(i.scale),t.horizontalGridlines.scaledIntervals=[d/s.interval],t.verticalGridlines.scaledIntervals=[u/o.interval],f=!0;else{for(var S=0;S=2)for(;e>=2;)e/=2;else if(e<=.5)for(;e<=.5;)e*=2;var i;if(t.horizontalGridlines.scaledIntervals=t.horizontalGridlines.snapIntervals,t.verticalGridlines.scaledIntervals=t.verticalGridlines.snapIntervals,1!==e){var r=t.horizontalGridlines;for(r.scaledIntervals=[],i=0;ithis.groupElement.actualSize.height&&("Clip"===t.style.textOverflow||"Ellipsis"===t.style.textOverflow)&&(a.y=a.y+(a.height-this.groupElement.actualSize.height)/2),this.renderer.drawRectangle(e,a,this.diagramId,void 0,void 0,r),this.renderer.drawText(e,a,r,l,this.diagramId,t.isExport&&Math.min(t.exportScaleValue.x||t.exportScaleValue.y),this.groupElement),this.isSvgMode&&(t.doWrap=!1)},n.prototype.renderNativeElement=function(t,e,i,r,s){var o,a,l=this.getParentSvg(t,void 0,e)||r,h=this.getParentElement(t,e,l).g||e,c=this.getBaseAttributes(t,i);switch(c.fill="transparent",c.cornerRadius=t.cornerRadius,c.stroke="transparent",this.renderer.drawRectangle(e,c,this.diagramId,void 0,void 0,r),t.scale){case"None":o=t.contentSize.width,a=t.contentSize.height;break;case"Stretch":o=t.actualSize.width,a=t.actualSize.height;break;case"Meet":o=a=t.actualSize.width<=t.actualSize.height?t.actualSize.width:t.actualSize.height;break;case"Slice":o=a=t.actualSize.width>=t.actualSize.height?t.actualSize.width:t.actualSize.height}this.svgRenderer&&this.svgRenderer.drawNativeContent(t,h,a,o,l)},n.prototype.renderHTMLElement=function(t,e,i,r,s,o,a){var l=this.getBaseAttributes(t,r);l.fill="transparent",l.cornerRadius=t.cornerRadius,l.stroke="transparent",this.renderer.drawRectangle(e,l,this.diagramId,void 0,void 0,s),this.svgRenderer&&this.svgRenderer.drawHTMLContent(t,i.children[0],r,function cse(n){var t=n.parentElement;do{if(dm(t,"e-diagram"))return!0;t=t.parentElement}while(t);return!1}(i),a)},n.prototype.renderImageElement=function(t,e,i,r,s){var o=this.getBaseAttributes(t,i);o.cornerRadius=0,this.renderer.drawRectangle(e,o,this.diagramId,void 0,void 0,r);var a,l,h,c,g,d=t.contentSize.width,u=t.contentSize.height,p=o.width/d,f=o.height/u;if("Stretch"===t.stretch)a=d*(g=Math.min(p,f)),l=u*g;else switch(t.stretch){case"Meet":a=d*(g=Math.min(p,f)),l=u*g,o.x+=Math.abs(o.width-a)/2,o.y+=Math.abs(o.height-l)/2;break;case"Slice":g=Math.max(p,f),h=o.width/(a=d*g)*d,c=o.height/(l=u*g)*u;break;case"None":a=d,l=u}o.width=a,o.height=l,o.sourceWidth=h,o.sourceHeight=c,o.source=t.source,o.alignment=t.imageAlign,o.scale=t.imageScale,o.description=t.description?t.description:t.id,this.renderer.drawImage(e,o,r,s)},n.prototype.renderContainer=function(t,e,i,r,s,o,a,l,h,c,d){var g,u={svg:s,g:e},p=document.getElementById(this.diagramId);if(p&&(g=p.ej2_instances[0]),this.diagramId&&(s=this.getParentSvg(t)||s,this.isSvgMode)){var v=this.getParentElement(t,e,s,l).g||e;s=this.getParentSvg(this.hasNativeParent(t.children))||s;var y=this.getParentElement(this.hasNativeParent(t.children),v,s,l);u.svg=y.svg||s,u.g=y.g||v,o&&s&&(s.getElementById(u.g.id)||e.appendChild(u.g)),e=u.g}if(this.renderRect(t,e,r,s),this.groupElement=t,t.hasChildren()){for(var b,S=void 0,M=0,w=t.children;M0&&(D=g.selectedItems.nodes[0]);var L,A=void 0,x=void 0,R=!1;if(g&&g.selectedItems&&(L=g.getObject(t.id)),"None"!==t.flip&&(D=L),"None"===t.flip&&(D=L),D&&D.flipMode&&(R=!0),!(t.elementActions&Xr.ElementIsGroup)&&g instanceof zl&&g.nameTable[t.id]&&"connectors"!==g.nameTable[t.id].propName&&R&&D){if(A=t.children&&t.children[0]instanceof Cn?document.getElementById(D.id+"_content_inner_native_element"):document.getElementById(D.id+"_content_groupElement"),!(t.children[0]instanceof Cn)&&"Text"!==D.shape.type&&"None"!==D.flipMode&&"Label"!==D.flipMode&&"All"!==D.flipMode&&"PortAndLabel"!==D.flipMode&&"LabelText"!==D.flipMode&&"PortAndLabelText"!==D.flipMode&&"LabelAndLabelText"!==D.flipMode||t.children[0]instanceof Cn&&"Port"===D.flipMode)return void this.renderFlipElement(t,A,D.flip);if((t.children[0]instanceof Cn&&("All"===D.flipMode||"Label"===D.flipMode)||"Label"===D.flipMode||"PortAndLabel"===D.flipMode||"LabelText"===D.flipMode||"PortAndLabelText"===D.flipMode||"LabelAndLabelText"===D.flipMode||"Image"===D.shape.type&&"Label"===D.flipMode)&&this.renderFlipElement(t,A,t.flip),"None"!==t.flip&&"None"===D.flipMode)this.renderFlipElement(t,A,t.flip);else if("None"!==t.flip&&("Label"===D.flipMode||"PortAndLabel"===D.flipMode||"LabelText"===D.flipMode||"PortAndLabelText"===D.flipMode||"LabelAndLabelText"===D.flipMode)||t.children[0]instanceof Cn&&"None"!==t.flip&&D&&("None"===D.flipMode||"All"===D.flipMode)){for(var O=0;O0){var i=t[0];if(i instanceof Cn)return i;i.children&&i.children.length&&this.hasNativeParent(i.children,e++||0)}},n.prototype.renderRect=function(t,e,i,r,s){var o=this.getBaseAttributes(t,i,s);o.cornerRadius=t.cornerRadius||0,t.isExport&&(o.cornerRadius*=t.exportScaleValue.x),this.renderer.drawRectangle(e,o,this.diagramId,t.isExport,void 0,r,t.description?t.description:t.id)},n.prototype.drawRect=function(t,e){e.cornerRadius=0,this.svgRenderer.drawRectangle(t,e,this.diagramId)},n.prototype.getBaseAttributes=function(t,e,i){var r={width:t.actualSize.width,height:t.actualSize.height,x:t.offsetX-t.actualSize.width*t.pivot.x,y:t.offsetY-t.actualSize.height*t.pivot.y,fill:t.style.fill,stroke:t.style.strokeColor,angle:t.rotateAngle+t.parentTransform,pivotX:t.pivot.x,pivotY:t.pivot.y,strokeWidth:t.style.strokeWidth,dashArray:t.style.strokeDashArray||"",opacity:t.style.opacity,shadow:t.shadow,gradient:t.style.gradient,visible:t.visible,id:t.id,description:t.description,canApplyStyle:t.canApplyStyle,shapeType:t.shapeType};return"Page"===t.rotationReference&&(r.angle=t.rotateAngle),i&&(r.x=r.x-.5,r.y=r.y-.5),t.isExport&&(r.width*=t.exportScaleValue.x,r.height*=t.exportScaleValue.y,r.x*=t.exportScaleValue.x,r.y*=t.exportScaleValue.y,r.strokeWidth*=t.exportScaleValue.x),t.flip&&(r.flip=t.flip),e&&(r.x+=e.tx,r.y+=e.ty),r},n.renderSvgBackGroundImage=function(t,e,i,r,s,o){if(t.source){var l=ST(e.id).getElementById(e.id+"_image");if(!l){var h=function Soe(n){return xt(n).getElementsByClassName("e-background-image-layer")[0]}(e.id);(l=document.createElementNS("http://www.w3.org/2000/svg","image")).setAttribute("id",e.id+"_image"),h.appendChild(l)}var c=new Image;c.src=t.source,l.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",c.src.toString());var d="None"!==t.scale?t.scale:"",u=t.align,p=u.charAt(0).toLowerCase()+u.slice(1);d&&(p+=" "+d.charAt(0).toLowerCase()+d.slice(1)),ai(l,{id:e.id+"_image",x:i,y:r,width:s,height:o,preserveAspectRatio:p})}},n.prototype.transformLayers=function(t,e){var i=t.tx*t.scale,r=t.ty*t.scale,s="domTable";if(i!==this.transform.x||r!==this.transform.y||0===i||0===r){e&&(window[""+s][this.diagramId+"_diagramLayer"]||(window[""+s][this.diagramId+"_diagramLayer"]=this.diagramSvgLayer.getElementById(this.diagramId+"_diagramLayer")),window[""+s][this.diagramId+"_diagramLayer"].setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+"),scale("+t.scale+")"));var a=function Ioe(n){var t="domTable",e=null;return window[t][n+"_gridline"]?e=window[t][n+"_gridline"]:(e=_d(n).getElementById(n+"_gridline"),window[t][n+"_gridline"]=e),e}(this.diagramId);return a.setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+")"),window[""+s][this.diagramId+"_diagramPorts"]||(window[""+s][this.diagramId+"_diagramPorts"]=this.iconSvgLayer.getElementById(this.diagramId+"_diagramPorts")),window[""+s][this.diagramId+"_diagramPorts"].setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+"),scale("+t.scale+")"),window[""+s][this.diagramId+"_diagramExpander"]||(window[""+s][this.diagramId+"_diagramExpander"]=this.iconSvgLayer.getElementById(this.diagramId+"_diagramExpander")),window[""+s][this.diagramId+"_diagramExpander"].setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+"),scale("+t.scale+")"),window[""+s][this.diagramId+"_nativeLayer"]||(window[""+s][this.diagramId+"_nativeLayer"]=this.nativeSvgLayer.getElementById(this.diagramId+"_nativeLayer")),window[""+s][this.diagramId+"_nativeLayer"].setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+"),scale("+t.scale+")"),Io(this.diagramId).children[0].style.transform="translate("+t.tx*t.scale+"px,"+t.ty*t.scale+"px)scale("+t.scale+")",this.transform={x:t.tx*t.scale,y:t.ty*t.scale},!0}return!1},n.prototype.updateNode=function(t,e,i,r,s,o,a){this.renderElement(t,e,i,r,this.getParentSvg(t),void 0,void 0,s,null,o,a)},n}(),rse=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),KI=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},oF=function(n){function t(e,i){var r=n.call(this,e,i)||this;return r.mode="Canvas",r.id="overview",r.actionName="",r.startPoint=null,r.currentPoint=null,r.prevPoint=null,r.scale=null,r.inAction=!1,r.viewPortRatio=1,r.horizontalOffset=0,r.verticalOffset=0,r.model={},r.event=!0,r.overviewid=88123,r.model={width:r.width,height:r.height},r}return rse(t,n),t.prototype.onPropertyChanged=function(e,i){for(var r=0,s=Object.keys(e);r0||e.toString().indexOf("%")>0?e.toString():e.toString()+"px"},t.prototype.renderCanvas=function(e){var i=document.getElementById(this.element.id+"_canvas");i||(i=Tt("div",{}),this.element.appendChild(i)),Ho(i,{id:this.element.id+"_canvas",class:"drawing",style:"position:relative; height:"+this.getSizeValue(this.model.height)+"; width:"+this.getSizeValue(this.model.width)+";style:-ms-touch-action: none;touch-action: none;"}),this.element.setAttribute("tabindex",String(-1)),this.element.style.overflow="hidden",this.element.style.height=String(this.model.height),this.element.style.width=String(this.model.width),this.canvas=i},t.prototype.setParent=function(e){var i=document.getElementById(e);if(this.parent){var s=this.parent;this.parent=null,s.setOverview(null,this.element.id),this.removeDocument(this)}this.parent=this.getDiagram(i,"ej2_instances"),this.parent&&this.parent.setOverview(this)},t.prototype.getDiagram=function(e,i){for(var r,s=e[""+i].length,o=0;o0?p:Math.floor(window.innerWidth)}if(0===h){var f=Math.floor(window.innerHeight-u-Math.floor(c.top));h=f>0?f:Math.floor(window.innerHeight)}l>0&&(s.setAttribute("width",String(l)),this.model.height=h),h>0&&(s.setAttribute("height",String(h)),this.model.width=l),e.diagramLayerDiv||(e.diagramLayerDiv=Tt("div",{}),e.diagramLayer=bo.createCanvas(this.element.id+"_diagramLayer",this.model.width,this.model.height),e.diagramLayer.setAttribute("style","position:absolute; left:0px; top:0px "),e.diagramLayerDiv.appendChild(e.diagramLayer),e.canvas.appendChild(e.diagramLayerDiv)),Ho(e.diagramLayerDiv,{id:this.element.id+"_diagramLayer_div",style:"width:"+this.model.width+"px; height:"+this.model.height+"px;position:absolute;top:0px;left:0px"}),this.renderHtmlLayer(e.canvas),this.renderNativeLayer(e.canvas,e),this.addOverviewRectPanel(e)},t.prototype.removeDocument=function(e){var i=document.getElementById(this.canvas.id+"_svg");this.canvas.removeChild(i);var r=document.getElementById(this.element.id+"_htmlLayer");this.canvas.removeChild(r);var s=document.getElementById(this.element.id+"_diagramLayer_div");this.canvas.removeChild(s),e.diagramLayerDiv=null,e.diagramLayer=null,window.domTable[this.id+"html_layer"]=null},t.prototype.renderHtmlLayer=function(e){var i=Tt("div",{id:this.element.id+"_htmlLayer",class:"e-html-layer",style:"pointer-events:none;position:absolute;top:0px;left:0px;"}),s=Tt("div",{id:this.element.id+"_htmlLayer_div",style:"position:absolute;top:0px;left:0px;"});return i.appendChild(s),e.appendChild(i),i},t.prototype.renderNativeLayer=function(e,i){if(!document.getElementById(this.element.id+"_nativeLayer_svg")){var r=this.parent.createSvg(this.element.id+"_nativeLayer_svg",this.model.width,this.model.height),s=Bi("g",{id:this.element.id+"_nativeLayer"});r.appendChild(s),i.diagramLayerDiv.appendChild(r),ai(r,{class:"e-native-layer"})}},t.prototype.addOverviewRectPanel=function(e){var i=document.getElementById(this.canvas.id+"_overviewsvg");i&&i.parentNode.removeChild(i),i=Bi("svg",{id:this.canvas.id+"_overviewsvg",class:"overviewsvg",version:"1.1",style:"position:absolute;left:0px;top:0px; aria-label:Specifies overview",width:this.model.width,height:this.model.height}),e.canvas.appendChild(i);var s=Bi("g",{id:this.element.id+"_overviewlayer",style:"pointer-events:none"});i.appendChild(s);var o=Bi("rect",{fill:"transparent",width:"100%",height:"100%",class:"overviewbackrect",id:this.canvas.id+"overviewbackrect"});o.setAttribute("style"," pointer-events: none; "),s.appendChild(o);var a=Bi("g",{id:this.canvas.id+"overviewhandle",style:"pointer-events:all"});s.appendChild(a);var l=Bi("rect",{id:this.canvas.id+"overviewrect",fill:"transparent"});a.appendChild(l),this.renderOverviewCorner("left",a),this.renderOverviewCorner("right",a),this.renderOverviewCorner("top",a),this.renderOverviewCorner("bottom",a),this.renderOverviewCorner("topleft",a),this.renderOverviewCorner("topright",a),this.renderOverviewCorner("bottomleft",a),this.renderOverviewCorner("bottomright",a)},t.prototype.renderOverviewCorner=function(e,i){var s,o=Bi(s="top"===e||"bottom"===e||"right"===e||"left"===e?"rect":"circle",{id:this.canvas.id+"visible"+e,class:"overview-resizer"});i.appendChild(o);var a=Bi(s,{id:this.canvas.id+e,class:"overviewresizer",fill:"transparent"});i.appendChild(a)},t.prototype.updateOverviewRectangle=function(){var e=this.currentPoint.x-this.prevPoint.x,i=this.currentPoint.y-this.prevPoint.y,r=new me;r.width=0,r.height=0;var s=0,o=0;switch(this.resizeDirection){case"left":r.width-=e,r.height-=e/this.viewPortRatio,s=e,o=e/this.viewPortRatio,o/=2;break;case"right":r.width+=e,r.height+=e/this.viewPortRatio,o=e/this.viewPortRatio,o/=-2;break;case"top":r.height-=i,r.width-=i*this.viewPortRatio,o=i,s=i*this.viewPortRatio,s/=2;break;case"bottom":r.height+=i,r.width+=i*this.viewPortRatio,s=i*this.viewPortRatio,s/=-2;break;case"topleft":Math.abs(i)>Math.abs(e)?e=i*this.viewPortRatio:i=e/this.viewPortRatio,r.width-=e,r.height-=i,s=e,o=i;break;case"topright":Math.abs(i)>Math.abs(e)?e=-i*this.viewPortRatio:i=-e/this.viewPortRatio,o=i,r.width+=e,r.height-=i;break;case"bottomleft":Math.abs(i)>Math.abs(e)?e=-i*this.viewPortRatio:i=-e/this.viewPortRatio,s=e,r.width-=e,r.height+=i;break;case"bottomright":Math.abs(i)>Math.abs(e)?e=i*this.viewPortRatio:i=e/this.viewPortRatio,r.width+=e,r.height+=i}this.updateHelper(s,o,r,void 0,void 0)},t.prototype.updateHelper=function(e,i,r,s,o){var a,l,h,u,p,d=this.element.getElementsByTagName("svg")[2].getElementById("helper");r?(a=(h=d.getBBox()).x+e,l=h.y+i,s=h.width+r.width,o=h.height+r.height):(u=this.currentPoint.x>this.startPoint.x?this.currentPoint.x-this.prevPoint.x:this.prevPoint.x-this.currentPoint.x,p=this.currentPoint.y>this.startPoint.y?this.currentPoint.y-this.prevPoint.y:this.prevPoint.y-this.currentPoint.y,Math.abs(p)>Math.abs(u)?u=this.viewPortRatio*p:p=u/this.viewPortRatio,h=d.getBBox(),a=this.startPoint.x>this.currentPoint.x?h.x-u:h.x,l=this.startPoint.y>this.currentPoint.y?h.y-p:h.y,s=h.width+u,o=h.height+p),ai(this.helper,{id:this.helper.id,x:a,y:l,width:Math.max(0,s),height:Math.max(0,o)})},t.prototype.updateOverviewrect=function(e,i,r,s){Ho(document.getElementById(this.canvas.id+"overviewrect"),{x:e,y:i,width:Math.max(1,r),height:Math.max(1,s)}),this.updateOverviewCorner("top",e+8,i+1,Math.max(0,r-16),2),this.updateOverviewCorner("bottom",e+8,i+s+3,Math.max(0,r-16),2),this.updateOverviewCorner("left",e-2,i+11,2,Math.max(0,s-16)),this.updateOverviewCorner("right",e+r,i+11,2,Math.max(0,s-16)),this.updateOverviewCorner("topleft",e,i+3,5,5),this.updateOverviewCorner("topright",e+r,i+3,5,5),this.updateOverviewCorner("bottomleft",e,i+s+3,5,5),this.updateOverviewCorner("bottomright",e+r,i+s+3,5,5)},t.prototype.updateOverviewCorner=function(e,i,r,s,o){var a,l;"top"===e||"bottom"===e||"right"===e||"left"===e?(a={x:i,y:r,width:s,height:o,fill:"#ED1C24"},l={x:i-2,y:r-2,width:2===s?4:s,height:2===o?4:o}):(a={cx:i,cy:r,r:4,fill:"#ED1C24"},l={cx:i,cy:r,r:6,fill:"transparent"}),Ho(document.getElementById(this.canvas.id+"visible"+e),a),Ho(document.getElementById(this.canvas.id+e),l)},t.prototype.translateOverviewRectangle=function(){Number(this.model.width),Number(this.model.height);var r=this.currentPoint.x-this.prevPoint.x,s=this.currentPoint.y-this.prevPoint.y,l=this.element.getElementsByClassName("overviewsvg")[0].getElementById(this.canvas.id+"overviewrect").getBBox(),h=l.x+r,c=l.y+s,d=l.width,u=l.height;this.updateOverviewrect(h,c,d,u),this.updateParentView(this.parent.scroller.currentZoom,h,c,d,u,null)},t.prototype.renderOverviewRect=function(e,i,r,s){var o=Number(this.model.width),a=Number(this.model.height),c=Math.max(this.parent.scroller.viewPortWidth/(r/o*this.contentWidth),this.parent.scroller.viewPortHeight/(s/a*this.contentHeight));if(c>=.25&&c<=30){this.updateParentView(c,e,i,r,s,{x:0,y:0});var u=this.scrollOverviewRect(this.parent.scroller.horizontalOffset,this.parent.scroller.verticalOffset,this.parent.scroller.currentZoom,!0);if(this.helper){var f=this.element.getElementsByTagName("rect")[10].getBBox();u.x=f.x,u.y=f.y}"pan"===this.actionName?this.updateOverviewrect(-u.x,-u.y,u.width,u.height):this.updateOverviewrect(u.x,u.y,u.width,u.height)}},t.prototype.scrollOverviewRect=function(e,i,r,s){if(!this.actionName||s){var o=Number(this.model.width),a=Number(this.model.height),l=Math.min(this.contentWidth/o,this.contentHeight/a),h=new Ne,c=h.x=e/r/l,d=h.y=i/r/l,u=0;this.parent.rulerSettings.showRulers&&(u=25);var p=document.getElementById(this.parent.element.id+"content"),f=0,g=0;p&&(f=p.offsetWidth-p.clientWidth,g=p.offsetHeight-p.clientHeight);var v=h.width=(this.parent.scroller.viewPortWidth-u-f)/r/l,y=h.height=(this.parent.scroller.viewPortHeight-u-g)/r/l;if(s){var S=new Ne;return S.x=c,S.y=d,S.width=v,S.height=y,S}this.updateOverviewrect(-c,-d,v,y)}return null},t.prototype.updateParentView=function(e,i,r,s,o,a){var f,g,l=Number(this.model.width),h=Number(this.model.height),u=i*(this.contentWidth/l)*e,p=r*(this.contentHeight/h)*e;this.parent.scroller.getPageBounds(),(1!==e||"pan"===this.actionName)&&(f=-u-this.parent.scroller.horizontalOffset,g=-p-this.parent.scroller.verticalOffset),this.parent.setBlazorDiagramProps(!0),this.parent.realActions|=$i.OverViewAction,"scale"===this.actionName||"draw"===this.actionName?this.parent.scroller.zoom(e/this.parent.scroller.currentZoom,f,g,a):ce()?this.parent.scroller.zoom(1,f,g,a):this.parent.pan(f,g,a,!0)},t.prototype.updateHtmlLayer=function(e){var i=Io(e.element.id),r=this.parent.scroller.getPageBounds(!0),o=r.height,a=Math.max(r.width,this.parent.scroller.viewPortWidth),l=Math.max(o,this.parent.scroller.viewPortHeight/this.parent.scroller.currentZoom),h=Math.min(Number(this.model.width)/a,Number(this.model.height)/l);i.style.transform="scale("+h+") translate("+this.parent.scroller.transform.tx+"px,"+this.parent.scroller.transform.ty+"px)"},t.prototype.updateView=function(e){var i=this.parent.scroller.getPageBounds(),r=i.width,s=i.height,o=Number(this.model.width),a=Number(this.model.height),l=Math.max(r,this.parent.scroller.viewPortWidth),h=Math.max(s,this.parent.scroller.viewPortHeight);this.contentWidth=l=Math.max(l,o/a*h),this.contentHeight=h=Math.max(h,a/o*l);var c=Math.min(o/l,a/h),d=document.getElementById(this.element.id+"_htmlLayer");d.style.webkitTransform="scale("+c+") translate("+-i.x+"px,"+-i.y+"px)",d.style.transform="scale("+c+") translate("+-i.x+"px,"+-i.y+"px)",document.getElementById(this.element.id+"_overviewlayer").setAttribute("transform","translate("+-i.x*c+","+-i.y*c+")"),this.horizontalOffset=i.x*c,this.verticalOffset=i.y*c;var p=document.getElementById(this.element.id+"_diagramLayer"),f=zF(this.element.id),g=p.getContext("2d"),v=Number(this.model.width)/this.contentWidth,y=Number(this.model.height)/this.contentHeight;v=Math.min(v,y);var S=this.parent.scroller.transform;f.setAttribute("transform","translate("+S.tx*v+","+S.ty*y+"),scale("+v+")"),g.setTransform(v,0,0,v,0,0),g.fillStyle="red",this.scrollOverviewRect(this.parent.scroller.horizontalOffset,this.parent.scroller.verticalOffset,this.parent.scroller.currentZoom)},t.prototype.scrolled=function(e){if(this.event){var i=this.scrollOverviewRect(this.parent.scroller.horizontalOffset,this.parent.scroller.verticalOffset,this.parent.scroller.currentZoom,!0);this.updateOverviewrect(-i.x,-i.y,i.width,i.height),this.updateView(this)}},t.prototype.updateCursor=function(e){if(dm(e.target,"overviewresizer"))switch(e.target.id){case this.canvas.id+"left":this.canvas.style.cursor="w-resize";break;case this.canvas.id+"right":this.canvas.style.cursor="e-resize";break;case this.canvas.id+"top":this.canvas.style.cursor="n-resize";break;case this.canvas.id+"bottom":this.canvas.style.cursor="s-resize";break;case this.canvas.id+"topleft":this.canvas.style.cursor="nw-resize";break;case this.canvas.id+"topright":this.canvas.style.cursor="ne-resize";break;case this.canvas.id+"bottomleft":this.canvas.style.cursor="sw-resize";break;case this.canvas.id+"bottomright":this.canvas.style.cursor="se-resize"}else this.canvas.style.cursor="default"},t.prototype.mouseMove=function(e){if(this.event=!1,this.updateCursor(e),this.currentPoint=this.mousePosition(e),this.actionName)switch(this.actionName){case"draw":!this.inAction&&(this.startPoint.x!==this.currentPoint.x||this.startPoint.y!==this.currentPoint.y)&&(this.initHelper(),this.inAction=!0),this.inAction&&this.updateHelper();break;case"scale":this.inAction||(this.initHelper(),this.inAction=!0),this.updateOverviewRectangle();break;case"pan":(this.startPoint.x!==this.currentPoint.x||this.startPoint.y===this.currentPoint.y||this.inAction)&&(this.inAction=!0,this.translateOverviewRectangle())}this.prevPoint=this.currentPoint},t.prototype.documentMouseUp=function(e){this.inAction=!1,this.actionName="",this.helper&&(this.helper.parentNode.removeChild(this.helper),this.helper=null),this.event=!0,document.getElementById(this.canvas.id+"overviewhandle").style.pointerEvents="all"},t.prototype.windowResize=function(e){var i=this;return this.resizeTo&&clearTimeout(this.resizeTo),this.resizeTo=setTimeout(function(){var s=document.getElementById(i.element.id).getBoundingClientRect();i.model.width=s.width>0?s.width:i.model.width,i.model.height=s.height>0?s.height:i.model.height,i.renderCanvas(),i.setParent(i.sourceID)},10),!1},t.prototype.mouseDown=function(e){if(e.target.id===this.canvas.id+"_overviewsvg"&&(this.actionName="draw"),e.target.id===this.canvas.id+"overviewrect"&&(this.actionName="pan"),dm(e.target,"overviewresizer"))switch(this.actionName="scale",e.target.id){case this.canvas.id+"left":this.resizeDirection="left";break;case this.canvas.id+"right":this.resizeDirection="right";break;case this.canvas.id+"top":this.resizeDirection="top";break;case this.canvas.id+"bottom":this.resizeDirection="bottom";break;case this.canvas.id+"topleft":this.resizeDirection="topleft";break;case this.canvas.id+"topright":this.resizeDirection="topright";break;case this.canvas.id+"bottomleft":this.resizeDirection="bottomleft";break;case this.canvas.id+"bottomright":this.resizeDirection="bottomright"}this.startPoint=this.prevPoint=this.mousePosition(e),this.viewPortRatio=this.parent.scroller.viewPortWidth/this.parent.scroller.viewPortHeight,document.getElementById(this.canvas.id+"overviewhandle").style.pointerEvents="none"},t.prototype.mouseUp=function(e){if(this.currentPoint=this.mousePosition(e),this.actionName)if(this.startPoint.x!==this.currentPoint.x||this.startPoint.y!==this.currentPoint.y){if("pan"!==this.actionName&&this.helper){var i=this.element.getElementsByTagName("rect")[10].getBBox();this.resizeDirection=this.resizeDirection||"",this.renderOverviewRect(i.x,i.y,o=i.width,a=i.height)}}else if(e.target.id===this.canvas.id+"_overviewsvg"||"helper"===e.target.id){var o=(i=this.element.getElementsByTagName("svg")[2].getElementById(this.canvas.id+"overviewrect").getBBox()).width,a=i.height;this.inAction=!0,this.actionName="pan",this.renderOverviewRect(this.currentPoint.x-o/2,this.currentPoint.y-a/2,o,a),this.inAction=!1}this.helper&&(this.helper.parentNode.removeChild(this.helper),this.helper=null),this.actionName="",this.startPoint=null,this.currentPoint=null,this.prevPoint=null,this.helper=null,this.viewPortRatio=1,this.resizeDirection="",this.inAction=!1,this.event=!0,document.getElementById(this.canvas.id+"overviewhandle").style.pointerEvents="all"},t.prototype.initHelper=function(){var e=this.element.getElementsByTagName("svg")[2],i=this.startPoint.x,r=this.startPoint.y,s=1,o=1;if("scale"===this.actionName){var l=e.getElementById(this.canvas.id+"overviewrect").getBBox();i=l.x,r=l.y,s=l.width,o=l.height}var h=Bi("rect",{id:"helper",x:i,y:r,width:s,height:o,fill:"transparent",stroke:"gray","stroke-dasharray":"2 2","shape-rendering":"crispEdges"});e.getElementById(this.element.id+"_overviewlayer").appendChild(h),this.helper=h},t.prototype.mousePosition=function(e){var i,r,s;-1!==e.type.indexOf("touch")?(r=(i=e).changedTouches[0].clientX-this.element.offsetLeft,s=i.changedTouches[0].clientY-this.element.offsetTop):(r=e.clientX,s=e.clientY);var l=this.element.getBoundingClientRect();return{x:(r-=l.left)+this.horizontalOffset,y:(s-=l.top)+this.verticalOffset}},t.prototype.destroy=function(){if(this.unWireEvents(),this.notify("destroy",{}),n.prototype.destroy.call(this),document.getElementById(this.element.id)){this.element.classList.remove("e-overview");var e=document.getElementById(this.element.id+"_canvas");e&&this.element.removeChild(e)}this.parent.views.splice(this.parent.views.indexOf(this.element.id),1),this.diagramLayerDiv=null,this.canvas=null,this.parent=null},t.prototype.getModuleName=function(){return"Overview"},KI([I("100%")],t.prototype,"width",void 0),KI([I("100%")],t.prototype,"height",void 0),KI([I("")],t.prototype,"sourceID",void 0),KI([H()],t.prototype,"created",void 0),t}(yi);function sse(n,t){for(var e=0;ez.findLength(e,n)?e:t;var o=z.findAngle(t,e),a=z.findAngle(i,n),l=z.findLength(i,n),h=a+2*(o-a);return{x:i.x+l*Math.cos(h*Math.PI/180),y:i.y+l*Math.sin(h*Math.PI/180)}}function Jp(n,t,e){if(n&&n.children&&n.children.length>0)for(var r=void 0,s=0;s0&&"annotations"!==r&&"ports"!==r)if(n[""+l].length>0)for(var h=0;h<=n[""+l].length;h++)Ro(n[""+l],t?t[""+l]:void 0,e[""+l],"annotations"===l||"ports"===l?n:void 0,l);else Ro(n[""+l],t?t[""+l]:void 0,e[""+l],"annotations"===l||"ports"===l?n:void 0,l);else if(s instanceof Object&&t&&"annotations"!==r&&"ports"!==r)Ro(n[""+l],t[""+l],e[""+l]);else if("annotations"!==r&&"ports"!==r&&t&&!t[""+l]||!t&&n&&(n[""+l]||void 0!==n[""+l]))n[""+l]=e[""+l];else{var c=void 0;("annotations"===r||"ports"===r)&&("annotations"===r?(n[""+l]&&Ro(n[""+l],t[""+l],e[""+l]),n[""+l]||(fs(i)===de?(c=new Nr(i,"annotations",e[""+l]),i.annotations.push(c)):(c=new Zn(i,"annotations",e[""+l]),i.annotations.push(c)))):n[""+l]?Ro(n[""+l],t[""+l],e[""+l]):(c=new Es(i,"ports",e[""+l]),i.ports.push(c)))}}}function use(n,t){for(var e="Bezier"===n.type?function hse(n){var t=[];if("Bezier"===n.type)for(var e=0,i=0;i0||n.ports.length>0){var p=n.wrapper.children;for(i=3;i0)return{enabled:!1,intersectPt:e};var l=o/s,h=a/s;return l>=0&&l<=1&&h>=0&&h<=1?(e.x=i.x1+l*(i.x2-i.x1),e.y=i.y1+l*(i.y2-i.y1),{enabled:!0,intersectPt:e}):{enabled:!1,intersectPt:e}}function tb(n,t,e,i){var a=em(cF(n.x,n.y,t.x,t.y),cF(e.x,e.y,i.x,i.y));return a.enabled?a.intersectPt:{x:0,y:0}}function cF(n,t,e,i){return{x1:Number(n)||0,y1:Number(t)||0,x2:Number(e)||0,y2:Number(i)||0}}function dF(n,t,e){var i=[],s={x:t.topRight.x+(e=e||0),y:t.topRight.y},o={x:t.bottomRight.x,y:t.bottomRight.y-e},a={x:t.bottomLeft.x,y:t.bottomLeft.y+e};return i.push({x:t.topLeft.x-e,y:t.topLeft.y}),i.push(s),i.push(o),i.push(a),i}function zc(n,t,e,i,r,s){var o={},a=e.scroller.transform.scale,h=e.scroller.verticalOffset;return o.x=(i?n.x:t.x)*a+e.scroller.horizontalOffset-r,o.y=(i?n.y:t.y)*a+h-s,o}function uF(n,t){var e=new Ke;return e.data=n.pathData,e.height=n.height>10?n.height-(n.padding.bottom+n.padding.top):n.height,e.width=n.width>10?n.width-(n.padding.left+n.padding.right):n.width,e.visible=n.visibility,e.id=t.id+"_shape",e.inversedAlignment=!1,e.horizontalAlignment="Center",e.verticalAlignment="Center",e.style={fill:n.iconStrokeColor,strokeColor:n.iconStrokeColor,strokeWidth:n.iconStrokeWidth},e.setOffsetWithRespectToBounds(.5,.5,"Fraction"),e.relativeMode="Object",e.description=t.description||"",e}function $x(n,t,e){var i=Zx(n,t),r=z.findAngle(n[i.index],n[i.index+1]),s=function Sse(n){var t;t=n instanceof TI?0:void 0===n.content?10:0;var e=0;switch(n.alignment){case"Center":e=0;break;case"Before":e=-(0+t);break;case"After":e=0+t}return e}(t),o=z.transform(i.point,r+45,s);return i.point=o,i.angle=r,i}function Zx(n,t){for(var r,s,a,l,e=0,i=t.offset,o=[],h=0;h=c)return s=z.findAngle(n[parseInt(d.toString(),10)],n[d+1]),{point:r=z.transform(n[parseInt(d.toString(),10)],s,c-(a||0)),index:l=d};a=o[parseInt(d.toString(),10)]}return{point:r,index:l}}function pF(n,t,e){t%=360;var a,l,s=225;switch(n.alignment){case"Before":t>=45&&t<=135?(l="right",a=.5===n.offset?"center":"top"):t>=s&&t<=315?(l="left",a=.5===n.offset?"center":"bottom"):t>45&&t=45&&t<=135?(l="left",a=.5===n.offset?"center":"top"):t>=s&&t<=315?(l="right",a=.5===n.offset?"center":"bottom"):t>45&&tMath.abs(t.y-n.y)?n.x0)for(var e=0;e=0;r--)("nodes"===i||"connectors"===i)&&(n[""+i][parseInt(r.toString(),10)].wrapper=null),"dataManager"!==i&&(n[""+i][parseInt(r.toString(),10)]=eT(n[""+i][parseInt(r.toString(),10)],e[""+i][parseInt(r.toString(),10)],void 0!==t[""+i]?t[""+i][parseInt(r.toString(),10)]:[]),("[]"===JSON.stringify(n[""+i][parseInt(r.toString(),10)])||"{}"===JSON.stringify(n[""+i][parseInt(r.toString(),10)])||void 0===n[""+i][parseInt(r.toString(),10)])&&n[""+i].splice(r,1));n=void 0}function Ph(n,t){var e=t.style,i=t;t.canApplyStyle=!0;for(var r=0,s=Object.keys(n);r=0&&n.splice(e,1)}function Kp(n,t,e){var i;n.intermediatePoints=t,n.updateSegmentElement(n,t,n.wrapper.children[0],e);var r=n.sourceDecorator;if("Bezier"===n.type){var s=n.segments[0],o=n.segments[n.segments.length-1];i=[z.isEmptyPoint(o.point2)?o.bezierPoint2:o.point2,z.isEmptyPoint(s.point1)?s.bezierPoint1:s.point1]}else i=n.intermediatePoints;t=n.clipDecorators(n,t,e);var a=n.wrapper.children[0];a.canMeasurePath=!0,n.updateDecoratorElement(a=n.wrapper.children[1],t[0],i[1],r),n.updateDecoratorElement(a=n.wrapper.children[2],t[t.length-1],i[i.length-2],n.targetDecorator),n.updateShapeElement(n)}function tT(n,t,e){var l,i=n.wrapper,s=t.offset,o=t.size/e.scale,a=t.margin,h=i.offsetX-i.actualSize.width*i.pivot.x,c=i.offsetY-i.actualSize.height*i.pivot.y;if(l={x:0,y:0},n.nodes.length>0){switch(t.side){case"Top":l.x+=h+s*i.actualSize.width,l.y+=c-o;break;case"Bottom":l.x+=h+s*i.actualSize.width,l.y+=c+i.actualSize.height+o;break;case"Left":l.x+=h-o,l.y+=c+s*i.actualSize.height;break;case"Right":l.x+=h+i.actualSize.width+o,l.y+=c+s*i.actualSize.height}l.x+=(a.left-a.right)/e.scale+o/2*("Center"===t.horizontalAlignment?0:"Right"===t.horizontalAlignment?-1:1),l.y+=(a.top-a.bottom)/e.scale+o/2*("Center"===t.verticalAlignment?0:"Top"===t.verticalAlignment?-1:1)}else if(n.connectors.length>0){var d=n.connectors[0],u={offset:s},p=Zx(d.intermediatePoints,u),f=p.index;l=p.point;var y,v=$x(d.intermediatePoints,u).angle;qi(y=Hi(),-v,d.intermediatePoints[parseInt(f.toString(),10)].x,d.intermediatePoints[parseInt(f.toString(),10)].y),(l=Je(y,l)).x+=a.left-a.right+o/2*("Center"===t.horizontalAlignment?0:"Right"===t.horizontalAlignment?-1:1),l.y+=a.top-a.bottom+o/2*("Center"===t.verticalAlignment?0:"Top"===t.verticalAlignment?-1:1),qi(y=Hi(),v,d.intermediatePoints[parseInt(f.toString(),10)].x,d.intermediatePoints[parseInt(f.toString(),10)].y),l=Je(y,l)}return 0===i.rotateAngle&&0===i.parentTransform||(qi(y=Hi(),i.rotateAngle+i.parentTransform,i.offsetX,i.offsetY),l=Je(y,l)),l}function fa(n,t,e,i){if(i.annotation){if(Ol(i.annotation))return!0}else if(mr[""+t]&n&&bt[""+t]&e)return!0;return!1}function qr(n,t){return!!(mr[""+t]&n)}function Hc(n,t){return!!(wx[""+t]&n)}function ga(n,t){return n.visibility&t}function ib(n,t){var e;if("Text"===n.shape.type)e=n.shape;else{var i=t.split("_");t=i[i.length-1];for(var r=0;rn[""+t]?e.splice(0,0,n):e.push(n);else if(e.length>1){for(var i=0,r=e.length-1,s=Math.floor((i+r)/2);s!==i;)if(e[parseInt(s.toString(),10)][""+t]n[""+t]))break;r=s,s=Math.floor((i+r)/2)}e[parseInt(r.toString(),10)][""+t]n[""+t]?e.splice(i,0,n):e[parseInt(i.toString(),10)][""+t]n[""+t]&&e.splice(r,0,n)}}function Hse(n){var t=document.getElementById(n.diagramId),e="ej2_instances",i=t[""+e][0].nodes;void 0===i&&(i=function Bse(n){for(var t=[],e=0;e30?10:o/2;for(var h=0,c=0;c=l){var u=l-h;r=Xt(n[c],n[c+1]),s=z.transform(n[c],r,u);break}h+=d}return s},sb=function(n,t){if(n instanceof te||n instanceof de)for(var e=0;e=0||navigator.platform.indexOf("iPad")>=0||navigator.platform.indexOf("iPhone")>=0||navigator.platform.indexOf("MacIntel")>=0)&&("safari"===X.info.name||"webkit"===X.info.name)}function wF(n,t,e,i){return void 0!==t.previewSize[""+i]?t.previewSize[""+i]:void 0!==n.symbolPreview[""+i]?n.symbolPreview[""+i]:t[""+i]||e.actualSize[""+i]}function sm(n,t,e){return n&&n.parentId&&(e=(n=t.nameTable[n.parentId]).parentId?sm(n,t,e):n.id),e}function om(n,t){return n.selectedItems.connectors.length>1&&0===n.selectedItems.nodes.length&&0!==t.rotateAngle}function jse(n){if(n.arrowType&&""!==n.arrowType.trim())switch(n.arrowType){case"single-line-arrow":default:return{targetDecorator:"Arrow",strokeWidth:1};case"double-line-arrow":return{targetDecorator:"Arrow",strokeWidth:2};case"dotted-arrow":return{targetDecorator:"Arrow",strokeDashArray:"2,2"};case"single-line":return{targetDecorator:"None",strokeWidth:1};case"double-line":return{targetDecorator:"None",strokeWidth:2};case"dotted":return{targetDecorator:"None",strokeDashArray:"2,2"};case"wiggly-arrow":return{targetDecorator:"None",strokeWidth:1,opacity:0}}return{targetDecorator:"Arrow",strokeWidth:1}}var Vse=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),io=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},CF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Vse(t,n),io([I("None")],t.prototype,"shape",void 0),io([I("white")],t.prototype,"fill",void 0),io([I("Auto")],t.prototype,"horizontalAlignment",void 0),io([I("Auto")],t.prototype,"verticalAlignment",void 0),io([I(10)],t.prototype,"width",void 0),io([I(10)],t.prototype,"height",void 0),io([re({x:.5,y:1},z)],t.prototype,"offset",void 0),io([I("#1a1a1a")],t.prototype,"borderColor",void 0),io([I(1)],t.prototype,"borderWidth",void 0),io([re({},$n)],t.prototype,"margin",void 0),io([I("")],t.prototype,"pathData",void 0),io([I("")],t.prototype,"content",void 0),io([I(0)],t.prototype,"cornerRadius",void 0),io([re({left:2,right:2,top:2,bottom:2},$n)],t.prototype,"padding",void 0),io([I("#1a1a1a")],t.prototype,"iconColor",void 0),t}(Ee),Wse=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),sT=function(n){function t(){var e=null!==n&&n.apply(this,arguments)||this;return e.orientation="Vertical",e.measureChildren=void 0,e.considerPadding=!0,e}return Wse(t,n),t.prototype.measure=function(e){return this.desiredSize=this.measureStackPanel(e,"Horizontal"===this.orientation?this.updateHorizontalStack:this.updateVerticalStack),this.desiredSize},t.prototype.arrange=function(e){return this.actualSize=this.arrangeStackPanel(e,"Horizontal"===this.orientation?this.arrangeHorizontalStack:this.arrangeVerticalStack),this.updateBounds(),this.actualSize},t.prototype.measureStackPanel=function(e,i){var r=void 0;if(void 0!==this.children&&this.children.length>0)for(var s=0,o=this.children;s0){var r=void 0,s=void 0;r=this.offsetX-e.width*this.pivot.x+this.padding.left,s=this.offsetY-e.height*this.pivot.y+this.padding.top;for(var o=0,a=this.children;o0)for(var i=0,r=this.children;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Jse=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Zse(t,n),zh([I("Horizontal")],t.prototype,"orientation",void 0),zh([I("Center")],t.prototype,"type",void 0),zh([I(void 0)],t.prototype,"offset",void 0),zh([I(!1)],t.prototype,"enableRouting",void 0),zh([I([])],t.prototype,"children",void 0),zh([I("")],t.prototype,"assistants",void 0),zh([I("")],t.prototype,"level",void 0),zh([I("")],t.prototype,"hasSubTree",void 0),zh([I("")],t.prototype,"rows",void 0),t}(Ee),Li=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),q=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Kse=function(n){if(n)switch(n.type){case"Basic":default:return ob;case"Flow":return TF;case"Path":return EF;case"Image":return xF;case"Text":return Rd;case"Bpmn":return dT;case"Native":return am;case"HTML":return DF;case"UmlActivity":return AF;case"UmlClassifier":return LF;case"SwimLane":return Fd}return ob},va=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),q([I("Basic")],t.prototype,"type",void 0),t}(Ee),EF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"Path"},q([I("Path")],t.prototype,"type",void 0),q([I("")],t.prototype,"data",void 0),t}(va),am=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"Native"},q([I("Native")],t.prototype,"type",void 0),q([I("")],t.prototype,"content",void 0),q([I("Stretch")],t.prototype,"scale",void 0),t}(va),DF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"Html"},q([I("HTML")],t.prototype,"type",void 0),q([I("")],t.prototype,"content",void 0),t}(va),xF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"Image"},q([I("Image")],t.prototype,"type",void 0),q([I("")],t.prototype,"source",void 0),q([I("None")],t.prototype,"scale",void 0),q([I("None")],t.prototype,"align",void 0),t}(va),Rd=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"Text"},q([I("Text")],t.prototype,"type",void 0),q([I("")],t.prototype,"content",void 0),q([re({},$n)],t.prototype,"margin",void 0),t}(va),ob=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"BasicShape"},q([I("Basic")],t.prototype,"type",void 0),q([I("Rectangle")],t.prototype,"shape",void 0),q([I(0)],t.prototype,"cornerRadius",void 0),q([Bt([],z)],t.prototype,"points",void 0),t}(va),TF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"FlowShape"},q([I("Flow")],t.prototype,"type",void 0),q([I("Terminator")],t.prototype,"shape",void 0),t}(va),aT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"BpmnGateway"},q([I("None")],t.prototype,"type",void 0),t}(Ee),lT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"BpmnDataObject"},q([I("None")],t.prototype,"type",void 0),q([I(!1)],t.prototype,"collection",void 0),t}(Ee),eoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),q([I("None")],t.prototype,"type",void 0),q([I("None")],t.prototype,"loop",void 0),q([I(!1)],t.prototype,"call",void 0),q([I(!1)],t.prototype,"compensation",void 0),t}(Ee),hT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"BpmnEvent"},q([I("Start")],t.prototype,"event",void 0),q([I("None")],t.prototype,"trigger",void 0),t}(Ee),Hd=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"BpmnSubEvent"},q([I("None")],t.prototype,"trigger",void 0),q([I("Start")],t.prototype,"event",void 0),q([I("")],t.prototype,"id",void 0),q([re({},z)],t.prototype,"offset",void 0),q([Bt([],Zn)],t.prototype,"annotations",void 0),q([Bt([],Es)],t.prototype,"ports",void 0),q([I()],t.prototype,"width",void 0),q([I()],t.prototype,"height",void 0),q([re({},$n)],t.prototype,"margin",void 0),q([I("Center")],t.prototype,"horizontalAlignment",void 0),q([I("Center")],t.prototype,"verticalAlignment",void 0),q([I(!0)],t.prototype,"visible",void 0),t}(Ee),toe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),q([re({id:"success",event:"End",offset:{x:1,y:.5}},Hd)],t.prototype,"success",void 0),q([re({id:"failure",event:"Intermediate",trigger:"Error",offset:{x:.25,y:1}},Hd)],t.prototype,"failure",void 0),q([re({id:"cancel",event:"Intermediate",trigger:"Cancel",offset:{x:.75,y:1}},Hd)],t.prototype,"cancel",void 0),t}(Ee),ioe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),q([I("None")],t.prototype,"type",void 0),q([I(!1)],t.prototype,"adhoc",void 0),q([I("Default")],t.prototype,"boundary",void 0),q([I(!1)],t.prototype,"compensation",void 0),q([I("None")],t.prototype,"loop",void 0),q([I(!0)],t.prototype,"collapsed",void 0),q([Bt([],Hd)],t.prototype,"events",void 0),q([re({},toe)],t.prototype,"transaction",void 0),q([I(void 0)],t.prototype,"processes",void 0),t}(Ee),cT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"BpmnActivity"},q([I("Task")],t.prototype,"activity",void 0),q([re({},eoe)],t.prototype,"task",void 0),q([re({},ioe)],t.prototype,"subProcess",void 0),t}(Ee),lm=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return Li(t,n),t.prototype.getClassName=function(){return"BpmnAnnotation"},q([I("")],t.prototype,"text",void 0),q([I("")],t.prototype,"id",void 0),q([I(0)],t.prototype,"angle",void 0),q([I()],t.prototype,"height",void 0),q([I()],t.prototype,"width",void 0),q([I(0)],t.prototype,"length",void 0),t}(Ee),roe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),q([I("")],t.prototype,"textAnnotationTarget",void 0),q([I("Auto")],t.prototype,"textAnnotationDirection",void 0),t}(Ee),dT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"BpmnShape"},q([I("Bpmn")],t.prototype,"type",void 0),q([I("Event")],t.prototype,"shape",void 0),q([re({},hT)],t.prototype,"event",void 0),q([re({},aT)],t.prototype,"gateway",void 0),q([re({},lT)],t.prototype,"dataObject",void 0),q([re({},cT)],t.prototype,"activity",void 0),q([re({},lm)],t.prototype,"annotation",void 0),q([Bt([],lm)],t.prototype,"annotations",void 0),q([re({},roe)],t.prototype,"textAnnotation",void 0),t}(va),AF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"UmlActivityShape"},q([I("UmlActivity")],t.prototype,"type",void 0),q([I("Action")],t.prototype,"shape",void 0),t}(va),uT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"MethodArguments"},q([I("")],t.prototype,"name",void 0),q([I("")],t.prototype,"type",void 0),q([re({},Gp)],t.prototype,"style",void 0),t}(Ee),sf=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"UmlClassAttribute"},q([I("Public")],t.prototype,"scope",void 0),q([I(!1)],t.prototype,"isSeparator",void 0),q([re({fill:"#F9F9F9",strokeColor:"#CCCCCC"},Al)],t.prototype,"separatorStyle",void 0),t}(uT),hm=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"UmlClassMethod"},q([Bt([],uT)],t.prototype,"parameters",void 0),t}(sf),ab=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"UmlClass"},q([I("")],t.prototype,"name",void 0),q([Bt([],sf)],t.prototype,"attributes",void 0),q([Bt([],hm)],t.prototype,"methods",void 0),q([re({},Gp)],t.prototype,"style",void 0),t}(Ee),pT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"UmlInterface"},q([I(!1)],t.prototype,"isSeparator",void 0),q([re({fill:"#F9F9F9",strokeColor:"#CCCCCC"},Al)],t.prototype,"separatorStyle",void 0),t}(ab),lb=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"UmlEnumerationMember"},q([I("")],t.prototype,"name",void 0),q([I("")],t.prototype,"value",void 0),q([I(!1)],t.prototype,"isSeparator",void 0),q([re({fill:"#F9F9F9",strokeColor:"#CCCCCC"},Al)],t.prototype,"separatorStyle",void 0),q([re({},Gp)],t.prototype,"style",void 0),t}(Ee),fT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"UmlEnumeration"},q([I("")],t.prototype,"name",void 0),q([Bt([],lb)],t.prototype,"members",void 0),q([re({},Gp)],t.prototype,"style",void 0),t}(Ee),LF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"UmlClassifierShape"},q([I("UmlClassifier")],t.prototype,"type",void 0),q([re({},ab)],t.prototype,"classShape",void 0),q([re({},pT)],t.prototype,"interfaceShape",void 0),q([re({},fT)],t.prototype,"enumerationShape",void 0),q([I("Class")],t.prototype,"classifier",void 0),t}(va),te=function(n){function t(e,i,r,s){var a,o=n.call(this,e,i,r,s)||this;return o.isCanvasUpdate=!1,o.status="None",o.parentId="",o.processId="",o.umlIndex=-1,o.outEdges=[],o.inEdges=[],o.isHeader=!1,o.isLane=!1,o.isPhase=!1,o.children&&o.children.length>0&&((!(a=r).style||!a.style.fill)&&(o.style.fill="transparent"),(!a.style||!a.style.strokeColor)&&(o.style.strokeColor="transparent")),o.shape&&"UmlActivity"===o.shape.type&&eb(r,o),o.shape&&"SwimLane"===o.shape.type&&aF(r,o),o.ports&&o.ports.length&&function ase(n){for(var t=0;t>";t=n;break;case"FinalNode":t=fF(e)}return t}(new Ke,i,this);break;case"Bpmn":if(e.bpmnModule){i=e.bpmnModule.initBPMNContent(i,this,e),this.wrapper.elementActions=this.wrapper.elementActions|Xr.ElementIsGroup;var v=this.shape.activity.subProcess;if(v.processes&&v.processes.length)for(var S=0,b=this.shape.activity.subProcess.processes;S>",margin:{left:10,right:10},id:"class",style:{fontSize:i.style.fontSize,color:i.style.color,fill:i.style.fill,textWrapping:r},offset:{x:.5,y:.3},constraints:Lr.ReadOnly}],constraints:(ie.Default|ie.HideThumbs)&~(ie.Rotate|ie.Drag|ie.Resize),verticalAlignment:"Stretch",horizontalAlignment:"Stretch",style:{fill:t.style.fill,strokeColor:"black"===t.style.strokeColor?"#ffffff00":t.style.strokeColor}},!0);return e.initObject(s),e.nodes.push(s),e.UpdateBlazorDiagramModel(s,"Node"),t.children.push(s.id),function Qse(n,t,e,i){if("Enumeration"===n.shape.classifier){var r=e.members;if(r&&r.length){rf(n,t);for(var s="",o=0;o0)for(var o=0;o0&&s.phaseSize&&(i+=s.phaseSize,Gv(n,s.phaseSize)),s.lanes.length>0)for(o=0;o0){var a=0;for(o=0;o0&&"Horizontal"===r.orientation)for(l=0;l0&&(i+=r.phaseSize,o=Xv(r.phaseSize),n.push(o)),a=0;a0&&o.phaseSize){for(var l=0;l0)for(l=0;l0?e.nameTable[this.nodes[0].id].wrapper:e.nameTable[this.connectors[0].id].wrapper,this.annotation.id);i.children.push(s)}else if(this.nodes||this.connectors){for(var o=0;o-1}function HF(n,t,e){n=[];for(var i=0,r=e.length;i0?c.getElementsByTagName("svg")[0].outerHTML:c.getElementsByTagName("g").length>0?c.getElementsByTagName("g")[0].outerHTML:"",s.shape.content=h,n.content=h,c.parentElement.removeChild(c)}l="nodeTemplate"}else a=s,l="annotationTemplate";var f=document.getElementById(n.diagramId).ej2_instances[0];if("string"!=typeof n.content&&"function"!=typeof n.content||n.isTemplate)if(n.isTemplate){if(v=void 0,v=f.isReact?n.getNodeTemplate()($(e),f,l+"_"+("nodeTemplate"===l?e.id:n.nodeId+e.id),void 0,void 0,!1,i):f.isVue||f.isVue3?n.getNodeTemplate()?n.getNodeTemplate()($(e),f,l+"_"+("nodeTemplate"===l?e.id:n.nodeId+e.id),void 0,void 0,!1,i):(v=ri("nodeTemplate"===l?f.nodeTemplate:f.annotationTemplate))($(e),f,l+"_"+("nodeTemplate"===l?e.id:n.nodeId+e.id),void 0,void 0,!1,i):n.getNodeTemplate()($(e),f,l+"_"+("nodeTemplate"===l?e.id:n.nodeId+e.id),void 0,void 0,!1))for(var M=0;M=1&&0===n.x&&("Clip"===i.textOverflow||"Ellipsis"===i.textOverflow)&&("Wrap"===i.textWrapping||"WrapWithOverflow"===i.textWrapping)&&(n.x=t[e-1]?t[e-1].x:-n.width/2),n.x}function _F(n,t,e,i){return e&&!t.template||t.template&&"function"==typeof t.template&&i.isReact?(n.isTemplate=!0,n.template=n.content=Rh(n,!0,t)):n.content=t.template,n}function Qe(){for(var e,t="",i=0;i<5;i++){if(typeof window<"u"&&"crypto"in window&&"getRandomValues"in crypto){var r=new Uint16Array(1);e=(window.msCrypto||window.crypto).getRandomValues(r)[0]%60}else e=Math.floor(61*Math.random());0===i&&e<10?i--:t+="0123456789ABCDEFGHIJKLMNOPQRSTUVWXTZabcdefghiklmnopqrstuvwxyz".substring(e,e+1)}return t}function UF(n){if(n)try{return"function"!=typeof n&&document.querySelectorAll(n).length?ri(document.querySelector(n).innerHTML.trim()):ri(n)}catch{return ri(n)}}function En(n){new Ne;var e=n.offsetY-n.actualSize.height*n.pivot.y,i=n.offsetY+n.actualSize.height*(1-n.pivot.y),r=n.offsetX-n.actualSize.width*n.pivot.x,s=n.offsetX+n.actualSize.width*(1-n.pivot.x);return Ne.toBounds([{x:r,y:e},{x:s,y:e},{x:r,y:i},{x:s,y:i}])}function yr(n){var t=new Ne,e=En(n),i=e.middleLeft,r=e.topCenter,s=e.bottomCenter,o=e.middleRight,a=e.topLeft,l=e.topRight,h=e.bottomLeft,c=e.bottomRight;if(n.corners={topLeft:a,topCenter:r,topRight:l,middleLeft:i,middleRight:o,bottomLeft:h,bottomCenter:s,bottomRight:c},0!==n.rotateAngle||0!==n.parentTransform){var d=Hi();qi(d,n.rotateAngle+n.parentTransform,n.offsetX,n.offsetY),n.corners.topLeft=a=Je(d,a),n.corners.topCenter=r=Je(d,r),n.corners.topRight=l=Je(d,l),n.corners.middleLeft=i=Je(d,i),n.corners.middleRight=o=Je(d,o),n.corners.bottomLeft=h=Je(d,h),n.corners.bottomCenter=s=Je(d,s),n.corners.bottomRight=c=Je(d,c)}return t=Ne.toBounds([a,l,h,c]),n.corners.left=t.left,n.corners.right=t.right,n.corners.top=t.top,n.corners.bottom=t.bottom,n.corners.center=t.center,n.corners.width=t.width,n.corners.height=t.height,t}function $(n,t,e,i){var r={},s="properties";if(n){e=n.propName;var l=[],h=[];if((l=l.concat(Object.keys(n[""+s]||n))).push("version"),e){var c=Zi(t);h=c?c(e):[],l=l.concat(h)}for(var d=function woe(n){switch(n){case"nodes":case"children":return["inEdges","outEdges","parentId","processId","nodeId","umlIndex","isPhase","isLane"];case"connectors":return["parentId"];case"annotation":case"annotations":return["nodeId"];case"shape":return["hasHeader"];case"layers":return["objectZIndex"]}return[]}(e),u=0,p=l=l.concat(d);u0&&(e=r),r=Math.floor(Eoe(e,i)),s=Bc(o+=n.substr(e,r),t)}while(s<=t.width);for(o=o.substr(0,e),a=e;a=t.width){n=n.substr(0,o.length-1);break}return"Ellipsis"===t.textOverflow?(n=n.substr(0,n.length-3),n+="..."):n=n.substr(0,n.length),n}function bT(n,t){if("NoWrap"===t&&"PreserveAll"===n)return"pre";var e="";switch(n){case"CollapseAll":e="nowrap";break;case"CollapseSpace":e="pre-line";break;case"PreserveAll":e="pre-wrap"}return e}function MT(n,t){var e=Hi();qi(e,t,0,0);var i=Je(e,{x:0,y:0}),r=Je(e,{x:n.width,y:0}),s=Je(e,{x:0,y:n.height}),o=Je(e,{x:n.width,y:n.height}),a=Math.min(i.x,r.x,s.x,o.x),l=Math.min(i.y,r.y,s.y,o.y),h=Math.max(i.x,r.x,s.x,o.x),c=Math.max(i.y,r.y,s.y,o.y);return new me(h-a,c-l)}function xs(n,t,e,i){if(0!==n){var r=Hi();return qi(r,n,t,e),Je(r,i)}return i}function Zi(n){return void 0!==n&&"string"==typeof n&&(n=Y(n,window)),n}var bo=function(){function n(){}return n.getContext=function(t){return t.getContext("2d")},n.setCanvasSize=function(t,e,i){t&&(t.setAttribute("width",e.toString()),t.setAttribute("height",i.toString()))},n.prototype.renderGradient=function(t,e,i,r){var s,o,a;if("None"!==t.gradient.type){for(var l=0;l0?(w=0===S.r1?e.arc[parseInt(r.toString(),10)].r1:S.r1,C=0===S.r2?e.arc[parseInt(r.toString(),10)].r2:S.r2,r++):(w=S.r1,C=S.r2);var D=S.angle*(Math.PI/180),A=S.largeArc,x=S.sweep,R={x:u,y:p},L={x:Math.cos(D)*(M.x-R.x)/2+Math.sin(D)*(M.y-R.y)/2,y:-Math.sin(D)*(M.x-R.x)/2+Math.cos(D)*(M.y-R.y)/2},O=Math.pow(L.x,2)/Math.pow(w,2)+Math.pow(L.y,2)/Math.pow(C,2);O>1&&(w*=Math.sqrt(O),C*=Math.sqrt(O));var N=Math.pow(C,2)*Math.pow(L.x,2),T=(A===x?-1:1)*Math.sqrt((Math.pow(w,2)*Math.pow(C,2)-Math.pow(w,2)*Math.pow(L.y,2)-N)/(Math.pow(w,2)*Math.pow(L.y,2)+Math.pow(C,2)*Math.pow(L.x,2)));isNaN(T)&&(T=0);var P={x:T*w*L.y/C,y:T*-C*L.x/w},_={x:(M.x+R.x)/2+Math.cos(D)*P.x-Math.sin(D)*P.y,y:(M.y+R.y)/2+Math.sin(D)*P.x+Math.cos(D)*P.y},B=this.a([1,0],[(L.x-P.x)/w,(L.y-P.y)/C]),j=[(L.x-P.x)/w,(L.y-P.y)/C],Q=[(-L.x-P.x)/w,(-L.y-P.y)/C],oe=this.a(j,Q);this.r(j,Q)<=-1&&(oe=Math.PI),this.r(j,Q)>=1&&(oe=0);var pe=B+oe/2*(x?1:-1);if(Math.cos(pe),Math.sin(pe),S.centp=_,S.xAxisRotation=D,S.rx=w,S.ry=C,S.a1=B,S.ad=oe,S.sweep=x,null!=s){var De=w>C?w:C,xe=w>C?1:w/C,Ie=w>C?C/w:1;s.save(),s.translate(_.x,_.y),s.rotate(D),s.scale(xe,Ie),s.arc(0,0,De,B,B+oe,!x),s.scale(1/xe,1/Ie),s.rotate(-D),s.translate(-_.x,-_.y),s.restore()}break;case"Z":case"z":s.closePath(),u=o,p=a}o=u,a=p}}},n.prototype.drawText=function(t,e,i,r,s,o,a){if(e.content&&!0===e.visible){var l=n.getContext(t);l.save(),this.setStyle(t,e),o&&(e.fontSize*=o),this.rotateContext(t,e.angle,e.x+e.width*e.pivotX,e.y+e.height*e.pivotY),this.setFontStyle(t,e);var u,d=0;u=e.childNodes;var p=e.wrapBounds;if(l.fillStyle=e.color,p){var f=this.labelAlign(e,p,u);for(d=0;de.width&&"Wrap"!==e.textOverflow&&"NoWrap"===e.textWrapping&&(g.text=VF(g.text,e)),"Clip"!==e.textOverflow&&"Ellipsis"!==e.textOverflow||"Wrap"!==e.textWrapping?l.fillText(g.text,v,y):ya.actualSize.height+a.bounds.y&&(g.text=g.text.slice(0,g.text.length-3),g.text=g.text.concat("...")),l.fillText(g.text,v,y)),"Underline"===e.textDecoration||"Overline"===e.textDecoration||"LineThrough"===e.textDecoration){var M=v,w=void 0,D=v+l.measureText(g.text).width,A=void 0;switch(e.textDecoration){case"Underline":w=y+2,A=y+2;break;case"Overline":w=f.y+g.dy*d,A=f.y+g.dy*d;break;case"LineThrough":w=(y+f.y+g.dy*d)/2+2,A=(y+f.y+g.dy*d)/2+2}l.beginPath(),l.moveTo(M,w),l.lineTo(D,A),l.strokeStyle=e.color,l.lineWidth=.08*e.fontSize,l.globalAlpha=e.opacity,l.stroke()}}}l.restore()}},n.prototype.loadImage=function(t,e,i,r,s){this.rotateContext(i,e.angle,r,s);var o=new Image;o.src=e.source,this.image(t,o,e.x,e.y,e.width,e.height,e)},n.prototype.drawImage=function(t,e,i,r){var s=this;if(e.visible){var o=n.getContext(t);o.save();var a=e.x+e.width*e.pivotX,l=e.y+e.height*e.pivotY,h=new Image;h.src=e.source,o.canvas.id.split("_"),r?h.onload=function(){s.loadImage(o,e,t,a,l)}:this.loadImage(o,e,t,a,l),o.restore()}},n.prototype.image=function(t,e,i,r,s,o,a){t.beginPath();var l=e.width,h=e.height,c=s,d=o,u=0,p=0;if(a&&"None"!==a.alignment){var f=a.alignment.toLowerCase().substr(1,3),g=a.alignment.toLowerCase().substr(5,3);if("Slice"===a.scale){var v=function(){u=c,p=h*c/l},y=function(){u=l*d/h,p=d};c>d?(v(),d>p&&y()):c===d?l>h?y():v():(y(),c>u&&v());var S=this.getSliceOffset(f,u,c,l),b=this.getSliceOffset(g,p,d,h),M=l-S,w=h-b,C=u-S*(u/l),D=p-b*(p/h),A=Tt("canvas",{width:s.toString(),height:o.toString()});A.getContext("2d").drawImage(e,S,b,M,w,0,0,C,D),t.drawImage(A,i,r,s,o)}else if("Meet"===a.scale){var R=h/l,L=d/c;p=L>R?c*R:d,i+=this.getMeetOffset(f,u=L>R?c:d/R,c),r+=this.getMeetOffset(g,p,d),t.drawImage(e,0,0,l,h,i,r,u,p)}else t.drawImage(e,i,r,s,o)}else if("None"!==a.flip){var O=1,N=1;("Horizontal"===a.flip||"Both"===a.flip)&&(i=-i,s=-s,O=-1),("Vertical"===a.flip||"Both"===a.flip)&&(r=-r,o=-o,N=-1),t.scale(O,N),t.drawImage(e,i,r,s,o)}else t.drawImage(e,i,r,s,o);t.closePath()},n.prototype.getSliceOffset=function(t,e,i,r){switch(t){case"min":default:return 0;case"mid":return(e-i)/2*r/e;case"max":return(e-i)*r/e}},n.prototype.getMeetOffset=function(t,e,i){var r=Math.max(e,i),s=Math.min(e,i);switch(t){case"min":default:return 0;case"mid":return(r-s)/2;case"max":return r-s}},n.prototype.m=function(t){return Math.sqrt(Math.pow(t[0],2)+Math.pow(t[1],2))},n.prototype.r=function(t,e){return(t[0]*e[0]+t[1]*e[1])/(this.m(t)*this.m(e))},n.prototype.a=function(t,e){return(t[0]*e[1]t.width&&("Ellipsis"===t.textOverflow||"Clip"===t.textOverflow)&&"NoWrap"===t.textWrapping?0:.5*t.width:"right"===t.textAlign&&(c=1*t.width),s.x=t.x+c+(e?e.x:0),s.y=a+d-r.height/2,s},n}(),pb=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Vi=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},xoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return pb(t,n),Vi([I("")],t.prototype,"source",void 0),Vi([I("transparent")],t.prototype,"color",void 0),Vi([I("None")],t.prototype,"scale",void 0),Vi([I("None")],t.prototype,"align",void 0),t}(Ee),Toe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return pb(t,n),Vi([I("Page")],t.prototype,"mode",void 0),Vi([I("PageSettings")],t.prototype,"region",void 0),Vi([re({top:25,bottom:25,left:25,right:25},$n)],t.prototype,"margin",void 0),Vi([I(!1)],t.prototype,"canZoomIn",void 0),Vi([I(void 0)],t.prototype,"customBounds",void 0),Vi([I(!1)],t.prototype,"canFit",void 0),t}(Ee),Aoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return pb(t,n),Vi([I(null)],t.prototype,"width",void 0),Vi([I(null)],t.prototype,"height",void 0),Vi([re({},$n)],t.prototype,"margin",void 0),Vi([I("Landscape")],t.prototype,"orientation",void 0),Vi([I("Infinity")],t.prototype,"boundaryConstraints",void 0),Vi([re({},xoe)],t.prototype,"background",void 0),Vi([I(!1)],t.prototype,"multiplePage",void 0),Vi([I(!1)],t.prototype,"showPageBreaks",void 0),Vi([re({},Toe)],t.prototype,"fitOptions",void 0),t}(Ee),Loe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return pb(t,n),Vi([I(0)],t.prototype,"horizontalOffset",void 0),Vi([I(0)],t.prototype,"verticalOffset",void 0),Vi([I(1)],t.prototype,"currentZoom",void 0),Vi([I(0)],t.prototype,"viewPortWidth",void 0),Vi([I(0)],t.prototype,"viewPortHeight",void 0),Vi([I(.2)],t.prototype,"minZoom",void 0),Vi([I(30)],t.prototype,"maxZoom",void 0),Vi([I("Diagram")],t.prototype,"scrollLimit",void 0),Vi([I()],t.prototype,"scrollableArea",void 0),Vi([I(!1)],t.prototype,"canAutoScroll",void 0),Vi([I(100)],t.prototype,"autoScrollFrequency",void 0),Vi([re({left:15,right:15,top:15,bottom:15},$n)],t.prototype,"autoScrollBorder",void 0),Vi([re({left:0,right:0,top:0,bottom:0},$n)],t.prototype,"padding",void 0),Vi([I(.2)],t.prototype,"zoomFactor",void 0),t}(Ee),Noe=function(){function n(){this.services={}}return n.prototype.register=function(t,e){this.services[""+t]=e},n.prototype.getService=function(t){return this.services[""+t]},n}(),WF=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),ma=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},YF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return WF(t,n),ma([I("lightgray")],t.prototype,"lineColor",void 0),ma([I("")],t.prototype,"lineDashArray",void 0),ma([I([1.25,18.75,.25,19.75,.25,19.75,.25,19.75,.25,19.75])],t.prototype,"lineIntervals",void 0),ma([I([1,19,.5,19.5,.5,19.5,.5,19.5,.5,19.5])],t.prototype,"dotIntervals",void 0),ma([I([20])],t.prototype,"snapIntervals",void 0),t}(Ee),Ooe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return WF(t,n),ma([re({},YF)],t.prototype,"horizontalGridlines",void 0),ma([re({},YF)],t.prototype,"verticalGridlines",void 0),ma([I(ei.All)],t.prototype,"constraints",void 0),ma([I(5)],t.prototype,"snapAngle",void 0),ma([I("Lines")],t.prototype,"gridType",void 0),ma([I(5)],t.prototype,"snapObjectDistance",void 0),ma([I("#07EDE1")],t.prototype,"snapLineColor",void 0),t}(Ee),QF=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Ja=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},GF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return QF(t,n),Ja([I(5)],t.prototype,"interval",void 0),Ja([I(100)],t.prototype,"segmentWidth",void 0),Ja([I("Horizontal")],t.prototype,"orientation",void 0),Ja([I("RightOrBottom")],t.prototype,"tickAlignment",void 0),Ja([I("red")],t.prototype,"markerColor",void 0),Ja([I(25)],t.prototype,"thickness",void 0),Ja([I(null)],t.prototype,"arrangeTick",void 0),t}(Ee),koe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return QF(t,n),Ja([I(!1)],t.prototype,"showRulers",void 0),Ja([I(!0)],t.prototype,"dynamicGrid",void 0),Ja([re({orientation:"Horizontal"},GF)],t.prototype,"horizontalRuler",void 0),Ja([re({orientation:"Vertical"},GF)],t.prototype,"verticalRuler",void 0),t}(Ee),Poe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),XF=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},zoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Poe(t,n),XF([I("")],t.prototype,"property",void 0),XF([I("")],t.prototype,"field",void 0),t}(Ee),wT=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),ln=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},qF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return wT(t,n),ln([I("")],t.prototype,"read",void 0),ln([I("")],t.prototype,"create",void 0),ln([I("")],t.prototype,"update",void 0),ln([I("")],t.prototype,"destroy",void 0),ln([I()],t.prototype,"customFields",void 0),t}(Ee),Roe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return wT(t,n),ln([I("")],t.prototype,"id",void 0),ln([I("")],t.prototype,"sourceID",void 0),ln([I("")],t.prototype,"targetID",void 0),ln([I(null)],t.prototype,"sourcePointX",void 0),ln([I(null)],t.prototype,"sourcePointY",void 0),ln([I(null)],t.prototype,"targetPointX",void 0),ln([I(null)],t.prototype,"targetPointY",void 0),ln([I(null)],t.prototype,"dataManager",void 0),ln([re({},qF)],t.prototype,"crudAction",void 0),t}(Ee),Hoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return wT(t,n),ln([I("")],t.prototype,"id",void 0),ln([I(null)],t.prototype,"dataManager",void 0),ln([I(null)],t.prototype,"dataSource",void 0),ln([I("")],t.prototype,"root",void 0),ln([I("")],t.prototype,"parentId",void 0),ln([I()],t.prototype,"doBinding",void 0),ln([Bt([],zoe)],t.prototype,"dataMapSettings",void 0),ln([re({},qF)],t.prototype,"crudAction",void 0),ln([re({},Roe)],t.prototype,"connectionDataSource",void 0),t}(Ee),$F=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Cr=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Boe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return $F(t,n),Cr([I("LeftInFlow")],t.prototype,"yesBranchDirection",void 0),Cr([I("RightInFlow")],t.prototype,"noBranchDirection",void 0),Cr([I(["Yes","True"])],t.prototype,"yesBranchValues",void 0),Cr([I(["No","False"])],t.prototype,"noBranchValues",void 0),t}(Ee),Foe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return $F(t,n),Cr([I("")],t.prototype,"fixedNode",void 0),Cr([I(30)],t.prototype,"horizontalSpacing",void 0),Cr([I("SamePoint")],t.prototype,"connectionPointOrigin",void 0),Cr([I("Nonlinear")],t.prototype,"arrangement",void 0),Cr([I(30)],t.prototype,"verticalSpacing",void 0),Cr([I(30)],t.prototype,"maxIteration",void 0),Cr([I(40)],t.prototype,"springFactor",void 0),Cr([I(50)],t.prototype,"springLength",void 0),Cr([re({left:50,top:50,right:0,bottom:0},$n)],t.prototype,"margin",void 0),Cr([I("Auto")],t.prototype,"horizontalAlignment",void 0),Cr([I("Auto")],t.prototype,"verticalAlignment",void 0),Cr([I("TopToBottom")],t.prototype,"orientation",void 0),Cr([I("Auto")],t.prototype,"connectionDirection",void 0),Cr([I("Default")],t.prototype,"connectorSegments",void 0),Cr([I("None")],t.prototype,"type",void 0),Cr([I()],t.prototype,"getLayoutInfo",void 0),Cr([I()],t.prototype,"layoutInfo",void 0),Cr([I()],t.prototype,"getBranch",void 0),Cr([I()],t.prototype,"bounds",void 0),Cr([I(!0)],t.prototype,"enableAnimation",void 0),Cr([I(!1)],t.prototype,"enableRouting",void 0),Cr([I("")],t.prototype,"root",void 0),Cr([re({},Boe)],t.prototype,"flowchartLayoutSettings",void 0),t}(Ee),_oe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),ZF=function(n){function t(e,i){var r=n.call(this,e,!0)||this;return r.oldValue=null,r.endPoint=i,r}return _oe(t,n),t.prototype.mouseDown=function(e){var i,r=!0;if(e.source&&e.source.connectors&&(i=e.source.connectors[0]),e.info&&e.actualObject&&(r=e.info.ctrlKey&&"Orthogonal"!==e.actualObject.type),i&&r){this.inAction=!0,this.undoElement=$(e.source),n.prototype.mouseDown.call(this,e);for(var s=0;s0)1!==s&&this.removePrevSegment(i,s);else if(a){var l=z.distancePoints(a.points[0],a.points[1]);Math.abs(a.length||0===a.length?a.length:l)<=5&&this.removeNextSegment(i,s)}this.commandHandler.updateEndPoint(i,r),i.selectedSegmentIndex=0}if(this.undoElement){var c=$(e.source);this.commandHandler.addHistoryEntry({type:"SegmentChanged",redoObject:c,undoObject:this.undoElement,category:"Internal"})}if(i.isBezierEditing&&(i.isBezierEditing=!1),this.prevPosition!==this.startPosition){var u={source:i,state:"Completed",oldValue:this.oldValue,newValue:$(this.selectedSegment),cancel:!1,segment:this.selectedSegment};this.commandHandler.triggerEvent(Ce.segmentChange,u)}n.prototype.mouseUp.call(this,e)},t.prototype.removePrevSegment=function(e,i){var r=e.segments[i-2],s=e.segments[i+1];if(s&&!((s.length||0===s.length?s.length:z.distancePoints(s.points[0],s.points[1]))<=5)){var a=e.segments.slice(i-1,i+1),l={element:e,removeSegments:a,type:"Removal",cancel:!1};if(this.commandHandler.triggerEvent(Ce.segmentCollectionChange,l),!l.cancel){var h=e.segments[i+1];e.segments.splice(i-1,2);var c=this.selectedSegment;"Left"===c.direction||"Right"===c.direction?(r.points[r.points.length-1].x=h.points[0].x,h.points[0].y=r.points[r.points.length-1].y):(r.points[r.points.length-1].y=h.points[0].y,h.points[0].x=r.points[r.points.length-1].x),(c.length||0===c.length)&&this.findSegmentDirection(r),this.findSegmentDirection(h)}}},t.prototype.findSegmentDirection=function(e){e.direction&&(e.length||0===e.length)&&(e.length=z.distancePoints(e.points[0],e.points[e.points.length-1]),e.direction=z.direction(e.points[0],e.points[e.points.length-1]))},t.prototype.removeNextSegment=function(e,i){var l,h,r=this.selectedSegment,s=e.segments[i-1],o=e.segments[i+2],a=e.segments[i+1];if(a.length||0===a.length?(l=e.segments.slice(i,2),h={element:e,removeSegments:l,type:"Removal",cancel:!1},this.commandHandler.triggerEvent(Ce.segmentCollectionChange,h={element:e,removeSegments:l,type:"Removal",cancel:!1}),h.cancel||(e.segments.splice(i,2),"Top"===r.direction||"Bottom"===r.direction?(o.points[0].y=r.points[0].y,s.points[s.points.length-1].x=o.points[0].x):(o.points[0].x=r.points[0].x,s.points[s.points.length-1].y=o.points[0].y))):(l=e.segments.slice(i+1,1),this.commandHandler.triggerEvent(Ce.segmentCollectionChange,h={element:e,removeSegments:l,type:"Removal",cancel:!1}),h.cancel||(e.segments.splice(i+1,1),"Top"===r.direction||"Bottom"===r.direction?s.points[s.points.length-1].x=a.points[a.points.length-1].x:s.points[s.points.length-1].y=a.points[a.points.length-1].y,this.findSegmentDirection(s),r.length=r.direction=null)),s&&o&&!h.cancel&&(s.length=z.distancePoints(s.points[0],o.points[0]),s.direction=z.direction(s.points[0],o.points[0]),o.length||0===o.length)){o.length=z.distancePoints(s.points[s.points.length-1],o.points[o.points.length-1]);var c=s.points,d=o.points;o.direction=z.direction(c[c.length-1],d[d.length-1])}},t.prototype.addOrRemoveSegment=function(e,i,r){for(var s,o,a=[],l={segments:e.segments},h=0;h0?"Bottom":"Top":r>0?"Right":"Left",length:i.points[0].x===i.points[1].x?s:r},!0)),l.push(new bi(e,"segments",{type:"Orthogonal",direction:c,length:h/2},!0));var p={element:e,addSegments:l,type:"Addition",cancel:!1};return this.commandHandler.triggerEvent(Ce.segmentCollectionChange,p),p.cancel||(e.segments=l.concat(e.segments),a=o+2),a},t.prototype.insertFirstSegment=function(e,i,r,s,o){var a,l,d,u,h=[];if(e.sourcePortID&&i.length&&e.segments[0].points.length>2)for(var p=void 0,f=0;f0?"Bottom":"Top":r>0?"Right":"Left"),p=u,h.push(u)}else h.push(new bi(e,"segments",{type:"Orthogonal",direction:i.direction,length:i.length/3},!0)),"Bottom"===i.direction||"Top"===i.direction?(l=Math.abs(r),a=r>0?"Right":"Left"):(l=Math.abs(s),a=s>0?"Bottom":"Top"),u=new bi(e,"segments",{type:"Orthogonal",direction:a,length:l},!0),h.push(u);var y={element:e,addSegments:h,type:"Addition",cancel:!1};if(this.commandHandler.triggerEvent(Ce.segmentCollectionChange,y),!y.cancel){if(e.sourcePortID&&i.length&&e.segments[0].points.length>2)e.segments.splice(0,1),d=1;else{var S=e.segments[1];S&&S.length&&(S.length=a!==S.direction?S.length+l:S.length-l),d=2,i.length=2*i.length/3}e.segments=h.concat(e.segments)}return d},t.prototype.updateAdjacentSegments=function(e,i,r,s){var o=e.segments[parseInt(i.toString(),10)],a=o.points[o.points.length-1],h=!0;"Orthogonal"===o.type&&(o.points[0]=o.points[0],o.points[o.points.length-1]=a,e.segments[i-1]&&(h=this.updatePreviousSegment(r,s,e,i)),e.segments.length-1>i&&h&&this.updateNextSegment(e,o,e.segments[i+1],r,s))},t.prototype.addTerminalSegment=function(e,i,r,s,o){var l,h,c,d,a=e.segments.indexOf(i),u=[],p=e.segments.pop(),f=e.segments[e.segments.length-1];l=f&&"Orthogonal"===f.type?f:null;for(var g=0;g0&&"Left"===o.direction?c.middleLeft:c.middleRight,o.length>c.width/2?Math.abs(a.length)0&&"Top"===o.direction?c.topCenter:c.bottomCenter,o.length>c.height/2?Math.abs(a.length)1)for(var a=0,l=this.diagram.views;a0)for(var e=t===Ce.onUserHandleMouseLeave?this.previousAction:this.action,i={element:void 0},r=0;r0)for(var r={element:void 0},s=void 0,o=void 0,a=0;a-1&&(o=s,this.previousTarget=i,this.targetItem=e),o===e.fixedUserHandles[parseInt(a.toString(),10)].id&&(r.element=e.fixedUserHandles[parseInt(a.toString(),10)],this.userHandle(t,a,r,e))},n.prototype.mouseDown=function(t){if(!0!==this.inAction||!(this.tool instanceof QI||this.tool instanceof pa)){this.focus=!0;var e=t.touches,i=!!document.getElementsByClassName("e-dragclone")[0];if(this.isMouseOnScrollBar(t)&&!i)return this.isScrolling=!0,void t.preventDefault();if(this.checkFixedUserHandleEvent(Ce.onFixedUserHandleMouseDown,this.targetItem,this.previousTarget),this.checkUserHandleEvent(Ce.onUserHandleMouseDown),!this.checkEditBoxAsTarget(t)&&jv(this.diagram)||Lc(this.diagram)&&!HI(this.diagram))if(("Select"===this.action||"Drag"===this.action)&&this.diagram.updatePortVisibility(this.hoverElement,Gt.Hover,!0),!(this.tool instanceof Oh||this.tool instanceof kh)||2!==t.button&&2!==t.buttons)if(!0===this.inAction&&!0===this.isMouseDown&&(this.tool instanceof Oh||this.tool instanceof kh))this.isMouseDown=!0,this.eventArgs={},this.getMouseEventArgs(this.currentPosition,this.eventArgs),this.eventArgs.position=this.currentPosition,this.tool.mouseDown(this.eventArgs);else{this.isMouseDown=!0,this.currentPosition=this.prevPosition=this.getMousePosition(t),this.eventArgs={},this.diagram.textEditing&&!this.isMouseOnScrollBar(t)&&(this.diagram.endEdit(),this.diagram.textEditing=!1,"Canvas"===this.diagram.mode&&1!==this.diagram.scroller.currentZoom&&this.diagram.refreshDiagramLayer());var s=this.getTargetElement();this.action=this.diagram.findActionToBeDone(s.obj,s.sourceElement,this.currentPosition,s.target);var o=this.isMetaKey(t);o&&t.shiftKey&&this.diagram.connectorEditingToolModule?this.action="SegmentEnd":(o||t.shiftKey)&&(_v(this.diagram)||Uv(this.diagram))&&(this.action="Select"),this.tool=this.diagram.getTool(this.action),this.tool||(this.action="Select",this.tool=this.diagram.getTool(this.action)),this.getMouseEventArgs(this.currentPosition,this.eventArgs),(o||t.shiftKey)&&(this.eventArgs.info=o&&t.shiftKey?{ctrlKey:o,shiftKey:t.shiftKey}:{ctrlKey:!0}),this.eventArgs.position=this.currentPosition;var l=this.diagram.selectedItems.nodes;if(this.tool.mouseDown(this.eventArgs),this.diagram.selectedItems.canToggleSelection&&l&&this.diagram.selectedItems.nodes&&this.tool instanceof ua)for(var h=0;h=2&&(this.touchStartList=HF(this.touchStartList,0,e)),e||t.preventDefault())}else this.inAction=!1,this.tool.mouseUp(this.eventArgs);!this.isForeignObject(t.target)&&!this.isForeignObject(t.target,!0)&&!e&&t.preventDefault()}},n.prototype.mouseMoveExtend=function(t,e){(this.tool instanceof Oh||this.tool instanceof kh)&&this.tool.mouseMove(this.eventArgs),this.diagram.scrollSettings.canAutoScroll?this.checkAutoScroll(t):this.blocked||this.tool.mouseMove(this.eventArgs),this.eventArgs.target&&(this.hoverElement=this.eventArgs.target);var i=!((this.eventArgs.target instanceof te||this.eventArgs.target instanceof de)&&(e instanceof te||e instanceof de));this.tool instanceof Pd&&this.diagram.updatePortVisibility(this.hoverElement instanceof te||this.hoverElement instanceof de?this.hoverElement:this.hoverNode,Gt.Connect|Gt.Hover,i),this.hoverElement instanceof te&&this.hoverNode instanceof te&&this.hoverNode&&this.hoverNode.id!==this.hoverElement.id&&this.diagram.updatePortVisibility(this.hoverNode,Gt.Connect|Gt.Hover,!0),this.hoverElement instanceof de&&this.hoverElement.ports.length>0&&this.diagram.updatePortVisibility(this.hoverElement,Gt.Connect|Gt.Hover,!0),this.previousElement instanceof te&&this.hoverElement&&this.previousElement.id!==this.hoverElement.id&&this.diagram.updatePortVisibility(this.previousElement,Gt.Connect|Gt.Hover,!0),this.previousElement=this.hoverElement,""!==this.diagram.tooltip.content&&(this.hoverElement=null),this.hoverNode=i?null:e},n.prototype.checkAction=function(t){if("LabelSelect"===this.action&&this.eventArgs.sourceWrapper&&(this.eventArgs.sourceWrapper instanceof si||this.eventArgs.sourceWrapper instanceof Jn)){var e=this.commandHandler.findTarget(this.eventArgs.sourceWrapper,this.eventArgs.source);!_r(this.diagram,e,!1,this.eventArgs.sourceWrapper)&&to(e)&&(this.action="LabelDrag",this.tool=this.getTool(this.action),this.tool.mouseDown(this.initialEventArgs))}else to(t)&&Td(t)&&this.initialEventArgs&&this.initialEventArgs.source&&"Select"===this.action&&(!_r(this.diagram,this.eventArgs.source,!1)&&this.eventArgs.source instanceof oi&&this.getMouseEventArgs(this.currentPosition,this.eventArgs),(!(t instanceof de)||t instanceof de&&!(wr(this.currentPosition,t.sourcePoint,t.hitPadding)||wr(this.currentPosition,t.targetPoint,t.hitPadding)))&&(this.action="Drag"),this.tool=this.getTool(this.action),this.tool.mouseDown(this.initialEventArgs))},n.prototype.isSwimlaneElements=function(t){return!(t&&(t.isLane||t.isPhase||t.isHeader))},n.prototype.mouseMove=function(t,e){if(this.focus=!0,this.isScrolling)t.preventDefault();else if(jv(this.diagram)||Lc(this.diagram)&&!HI(this.diagram)){this.currentPosition=this.getMousePosition(t);var i=this.diagram.findObjectsUnderMouse(this.currentPosition),r=this.diagram.findObjectUnderMouse(i,this.action,this.inAction);!function qne(n,t){n.rulerSettings.showRulers&&(n.hRuler.drawRulerMarker(n.hRuler.element,t,n.scroller.horizontalOffset),n.vRuler.drawRulerMarker(n.vRuler.element,t,n.scroller.verticalOffset))}(this.diagram,this.currentPosition);var s=!1,o=void 0;if("touchmove"===t.type&&(e=t.touches)&&e.length>1&&(this.touchMoveList=HF(this.touchMoveList,0,e),"PinchZoom"!==this.action&&(s=!0)),!1===z.equals(this.currentPosition,this.prevPosition)||this.inAction){if(!1===this.isMouseDown||s){this.eventArgs={};var a=null,l=void 0;if(null!==r){if((a=this.diagram.findElementUnderMouse(r,this.currentPosition,this.diagram))&&(l=this.commandHandler.findTarget(a,r)),(l instanceof Zn||l instanceof Nr)&&(l.tooltip&&""!==l.tooltip.content||(l=r)),l!==this.hoverElement){var h=this.getContent();this.hoverElement&&"Auto"===this.hoverElement.tooltip.openOn&&""!==h&&this.elementLeave(),this.diagram.updatePortVisibility(this.hoverElement,Gt.Hover,!0),r instanceof te&&(this.hoverNode=r);var c=!0;!this.isSwimlaneElements(r)&&this.hoverElement&&this.isSwimlaneElements(this.hoverElement)&&(c=!1),this.hoverElement=c?r:this.hoverElement;var d,u=void 0;(d=this.diagram.findElementUnderMouse(r,this.currentPosition,this.diagram))instanceof Ke&&((u=this.commandHandler.findTarget(d,r))instanceof Es||u instanceof xc)&&this.hoverElement.constraints&ni.ToolTip&&(this.hoverElement=u);var p=void 0;d instanceof si&&((p=this.commandHandler.findTarget(d,r))instanceof Zn||p instanceof Nr)&&p.constraints&Lr.Tooltip&&(this.hoverElement=p),c?this.elementEnter(this.currentPosition,!1):this.hoverElement=r}else this.hoverElement&&this.hoverElement===l&&this.hoverElement.tooltip.content&&void 0!==this.diagram.tooltipObject&&"Mouse"===this.hoverElement.tooltip.relativeMode&&this.setTooltipOffset(this.currentPosition);a&&(o=this.commandHandler.findTarget(a,r))}this.action=this.diagram.findActionToBeDone(r,a,this.currentPosition,o),this.checkFixedUserHandleEvent(Ce.onFixedUserHandleMouseEnter,r,a),this.checkUserHandleEvent(Ce.onUserHandleMouseEnter),this.checkPreviousAction(),this.getMouseEventArgs(this.currentPosition,this.eventArgs),this.tool=this.getTool(this.action),this.mouseEvents(),this.tool instanceof pa||this.tool instanceof kh||this.tool instanceof Oh?this.tool.mouseMove(this.eventArgs):e&&this.tool instanceof Jv&&this.tool.mouseDown(this.eventArgs),this.updateCursor(),this.renderUmlHighLighter(this.eventArgs);var f=!1;this.hoverElement&&!(this.tool instanceof Jv)&&r instanceof te&&this.isSwimlaneElements(r)&&(0===this.diagram.selectedItems.nodes.length||!_r(this.diagram,this.hoverElement))||this.hoverElement instanceof de||(f=!0),this.hoverElement&&!(this.tool instanceof Jv)&&r instanceof de&&(0===this.diagram.selectedItems.connectors.length||!_r(this.diagram,this.hoverElement))||this.hoverElement instanceof te||(f=!0),this.diagram.updatePortVisibility(this.hoverElement,Gt.Hover,f);var g=this.getContent();null===r&&this.hoverElement&&"Auto"===this.hoverElement.tooltip.openOn&&g&&(this.hoverElement=null,this.elementLeave()),s=!1}else{this.eventArgs.position=this.currentPosition,"Drag"===this.action&&!_r(this.diagram,this.eventArgs.source,!1)&&this.eventArgs.source instanceof oi&&this.getMouseEventArgs(this.currentPosition,this.eventArgs),this.mouseEvents(),(t.ctrlKey||t.shiftKey)&&(this.eventArgs.info=t.ctrlKey&&t.shiftKey?{ctrlKey:t.ctrlKey,shiftKey:t.shiftKey}:{ctrlKey:!0}),this.checkAction(r);var y=this.getConnectorPadding(this.eventArgs);this.getMouseEventArgs(this.currentPosition,this.eventArgs,this.eventArgs.source,y),this.updateCursor(),this.inAction=!0,this.initialEventArgs=null,("Drag"===this.action||"Rotate"===this.action)&&(this.diagram.diagramActions=this.diagram.diagramActions|ee.Interactions);var S=this.diagram.scroller.getPageBounds();this.mouseMoveExtend(t,r);var b=this.diagram.scroller.getPageBounds();if(r&&(S.width!==b.width||S.height!==b.height||S.x!==b.x||S.y!==b.y)&&this.diagram.views&&this.diagram.views.overview){var M=this.diagram.views.overview;M.updateView(M)}}this.prevPosition=this.currentPosition,this.isForeignObject(t.target,!0)||t.preventDefault()}}},n.prototype.getContent=function(){var i,t=this.hoverElement instanceof te&&this.hoverElement.constraints&ie.Tooltip||this.hoverElement instanceof de&&this.hoverElement.constraints&qe.Tooltip||(this.hoverElement instanceof Es||this.hoverElement instanceof xc)&&this.hoverElement.constraints&ni.ToolTip||(this.hoverElement instanceof Zn||this.hoverElement instanceof Nr)&&this.hoverElement.constraints&Lr.Tooltip,e=this.hoverElement;e instanceof te&&e.children&&e.children.length>0&&(i=this.findIntersectChild(e));var r=t?this.hoverElement.tooltip.content:this.diagram.tooltip.content;return i?i.tooltip.content:r},n.prototype.findIntersectChild=function(t){for(var e,i=new Ne(this.currentPosition.x,this.currentPosition.y,8,8),r=0;r1&&1===t.which&&!function Zre(n){return!!(n&ee.PreventClearSelection)}(this.diagram.diagramActions)&&(c=!1,this.commandHandler.clearSelection()),(!_r(this.diagram,h)||!c)&&(this.commandHandler.selectObjects([h],void 0,a),this.diagram.selectedItems.canToggleSelection)){var d=this.diagram.selectedItems.nodes;d?d[0].parentObj instanceof Bd&&(s=!0):this.diagram.selectedItems.connectors.length>0&&(s=!0)}}var u=!1,p=this.updateContainerProperties(),f=void 0;if(this.addUmlNode(),this.inAction=!1,this.isMouseDown=!1,this.diagram.selectedObject.helperObject&&(f=this.updateContainerBounds()),this.tool&&(this.tool.prevPosition||this.tool instanceof X3)){this.eventArgs.position=this.currentPosition;var g=this.getConnectorPadding(this.eventArgs);this.getMouseEventArgs(this.currentPosition,this.eventArgs,this.eventArgs.source,g);var v=this.isMetaKey(t);if((v||t.shiftKey)&&(this.eventArgs.info=v&&t.shiftKey?{ctrlKey:v,shiftKey:t.shiftKey}:{ctrlKey:!0}),this.diagram.diagramActions&ee.Interactions&&(this.diagram.diagramActions=this.diagram.diagramActions&~ee.Interactions),this.eventArgs.clickCount=t.detail,this.diagram.selectedObject.helperObject&&(this.tool instanceof ua||this.tool instanceof zd)){if(this.diagram.selectedObject.actualObject&&""!==this.diagram.selectedObject.actualObject.parentId){var S=this.diagram.getObject(this.diagram.selectedObject.actualObject.parentId);S&&S.isLane&&(this.commandHandler.isContainer=!0)}(u=this.diagram.lineRoutingModule&&this.diagram.nameTable.helper&&this.eventArgs.target&&this.eventArgs.target.isLane&&(this.eventArgs.source instanceof oi&&this.eventArgs.source.nodes.length>0&&""===this.eventArgs.source.nodes[0].parentId||""===this.eventArgs.source.parentId))&&(this.diagram.diagramActions=this.diagram.diagramActions|ee.PreventLaneContainerUpdate),this.tool.mouseUp(this.eventArgs,p.isPreventHistory)}else{if(this.diagram.selectedItems.canToggleSelection){var b=void 0,M=void 0;if(this.diagram.selectedItems.nodes.length>0)for(var w=0;w1&&D[0].id===i[parseInt(w.toString(),10)].id||r.length>0)&&(M=!0);!this.isSwimlaneSelected&&!s&&!M&&this.tool instanceof ua&&"Select"===this.currentAction&&(!b||this.diagram.selectedItems.connectors.length>0)&&this.commandHandler.clearSelection(!0)}this.isSwimlaneSelected=!1,this.tool.mouseUp(this.eventArgs),this.diagram.checkMenu&&(-1!==window.navigator.userAgent.indexOf("Linux")||-1!==window.navigator.userAgent.indexOf("X11"))&&(!t.pageY&&t instanceof TouchEvent&&t.changedTouches?(window.getSelection().removeAllRanges(),this.diagram.contextMenuModule.contextMenu.open(t.changedTouches[0].pageY,t.changedTouches[0].pageX,this.diagram.element),t.preventDefault()):this.diagram.contextMenuModule.contextMenu.open(t.pageY,t.pageX,this.diagram.element),this.diagram.checkMenu=!1)}p.hasStack&&this.diagram.endGroupAction()}if(f&&this.diagram.endGroupAction(),this.updateContainerBounds(!0),2!==this.eventArgs.clickCount&&(this.commandHandler.updateSelectedNodeProperties(this.eventArgs.source),u)){this.diagram.diagramActions=this.diagram.diagramActions&~ee.PreventLaneContainerUpdate;var A=this.eventArgs.source instanceof oi?this.eventArgs.source.nodes:[this.eventArgs.source];if(A)for(w=0;w0&&!N&&this.diagram.renderSelector(!0),!this.inAction&&!this.diagram.currentSymbol&&this.eventArgs){var T=this.getTargetElement();this.diagram.tool!==Ci.ZoomPan&&this.diagram.triggerEvent(Ce.click,{element:T.target instanceof Es?T.target:this.eventArgs.source||this.diagram,position:this.eventArgs.position,count:t.detail,actualObject:this.eventArgs.actualObject,button:0===t.button?"Left":1===t.button?"Middle":"Right"})}this.eventArgs={}}this.diagram.diagramActions=this.diagram.diagramActions&~ee.PreventLaneContainerUpdate,e&&this.updateAnnotation(this.diagram.selectedItems),this.eventArgs={},this.diagram.commandHandler.removeStackHighlighter()},n.prototype.isSwimlaneChild=function(t){if(t.shape&&"SwimLane"!==t.shape.type){var e=this.diagram.nameTable[t.parentId];if(!e)return!1;var i=e.parentId?this.diagram.nameTable[e.parentId]:e;return i&&i.shape&&"SwimLane"===i.shape.type}return!1},n.prototype.updateAnnotation=function(t){var e=t.nodes;if(e.length>0)for(var i=0;i0&&(a+=1),h.isPhase){l="Horizontal"===r.orientation?this.currentPosition.x-e.wrapper.bounds.x:this.currentPosition.y-(e.wrapper.bounds.y+r.header.height);var g={id:Qe(),offset:l,header:{annotation:{content:void 0===h.phases[0].header?"Phase":h.phases[0].header.annotation.content,style:void 0===h.phases[0].header?{}:h.phases[0].header.annotation.style}},style:void 0===h.phases[0]?{}:h.phases[0].style};this.diagram.addPhases(e,[g])}else{var v={id:Qe(),style:h.lanes[0].style,header:{annotation:{content:h.lanes[0].header.annotation.content,style:h.lanes[0].header.annotation.style},style:h.lanes[0].header.style}};if("Horizontal"===h.orientation?v.height=h.lanes[0].height:v.width=h.lanes[0].width,"Horizontal"===r.orientation?(s=i.rowIndex?i.rowIndex:this.diagram.nameTable[i.parentId].rowIndex,i.wrapper.offsetYs)v.header.width=r.lanes[parseInt(s.toString(),10)].header.width,v.header.height=r.lanes[parseInt(s.toString(),10)].header.height;else{var S=void 0;S="Horizontal"===r.orientation?i.rowIndex<3?0:s-a-1:s-1,v.header.width=r.lanes[parseInt(S.toString(),10)].header.width,v.header.height=r.lanes[parseInt(S.toString(),10)].header.height}f&&("height"===f?(v.width=v.height,delete v.height):(v.height=v.width,delete v.width)),this.diagram.addLanes(e,[v],"Horizontal"===r.orientation?s-a:s)}this.commandHandler.select(e)}else if(h.isLane){var b={id:Qe(),width:t.width,height:t.height,addInfo:t.addInfo,shape:{type:"SwimLane",header:{annotation:{content:void 0===h.header?"Header":h.header.annotation.content,style:void 0===h.header?{}:h.header.annotation.style},height:50,style:h.header?h.header.style:h.lanes[0].header.style},phases:[{id:Qe(),header:{annotation:{content:void 0===h.phases||void 0===h.phases[0].header?"Phase":h.phases[0].header.annotation.content,style:void 0===h.phases||void 0===h.phases[0].header?{}:h.phases[0].header.annotation.style},style:void 0===h.phases||void 0===h.phases[0].header?{}:h.phases[0].header.style},style:void 0===h.phases?{}:h.phases[0].style}],lanes:[{id:Qe(),height:t.height,width:t.width,style:h.lanes[0].style,header:{annotation:{content:h.lanes[0].header.annotation.content,style:h.lanes[0].header.annotation.style},style:h.lanes[0].header.style}}],orientation:h.orientation}};"Vertical"===h.orientation&&(b.width+=20),b.offsetX=this.currentPosition.x+b.width/2,b.offsetY=this.currentPosition.y+b.height/2,b.style=t.style,this.diagram.add(b)}},n.prototype.mouseLeave=function(t){this.tool&&this.inAction&&this.tool.mouseLeave(this.eventArgs),this.diagram.selectedObject.helperObject&&(this.updateContainerProperties(),this.updateContainerBounds()&&this.diagram.endGroupAction()),this.eventArgs&&this.eventArgs.source&&(this.diagram.updatePortVisibility(this.eventArgs.source,Gt.Hover,!0),this.hoverElement=null),this.eventArgs&&!this.eventArgs.source&&this.hoverElement&&(this.hoverElement=null),this.tool instanceof Pd&&this.eventArgs&&this.eventArgs.target&&this.eventArgs.target instanceof te&&(this.diagram.updatePortVisibility(this.eventArgs.target,Gt.Hover|Gt.Connect,!0),this.hoverElement=null);var i=this.diagram.selectedItems;i&&i.wrapper&&(om(this.diagram,i)||this.diagram.renderSelector(!0)),(this.diagram.diagramActions&ee.Interactions||this.diagram.diagramActions&ee.ToolAction)&&(this.diagram.diagramActions=this.diagram.diagramActions&~ee.ToolAction),this.isMouseDown=!1,this.focus=!1,this.touchStartList=null,this.touchMoveList=null,this.elementLeave(),this.commandHandler.removeSnap(),this.inAction=!1,this.eventArgs={},this.diagram.selectedObject&&this.diagram.selectedObject.helperObject&&(this.diagram.remove(this.diagram.selectedObject.helperObject),this.diagram.selectedObject={helperObject:void 0,actualObject:void 0}),this.tool=null,function Xne(){var t,e,n=document.getElementsByClassName("e-d-ruler-marker");if(n&&n.length>0)for(e=n.length-1;e>=0;e--)(t=n[parseInt(e.toString(),10)])&&t.parentNode.removeChild(t)}(),"Rotate"===this.action&&this.diagram.diagramCanvas.classList.remove("e-diagram-rotate"),t.preventDefault()},n.prototype.mouseWheel=function(t){this.diagram.blazorActions|=on.interaction;var e={event:t,cancel:!1};if(this.diagram.triggerEvent(Ce.mouseWheel,e),!e.cancel){var i=t.wheelDelta>0||-40*t.detail>0,r=this.getMousePosition(t);if(this.diagram.tooltipObject.close(),this.isMetaKey(t)){var o=this.diagram.scrollSettings.zoomFactor;this.diagram.zoomTo(i?{type:"ZoomIn",zoomFactor:o,focusPoint:r}:{type:"ZoomOut",zoomFactor:o,focusPoint:r}),t.preventDefault()}else{var a=this.diagram.scroller.horizontalOffset,l=this.diagram.scroller.verticalOffset,h=i?10:-10;this.tool&&(this.tool instanceof Oh||this.tool instanceof kh)&&(this.eventArgs={},this.getMouseEventArgs(r,this.eventArgs),this.eventArgs.position=r,this.tool.mouseWheel(this.eventArgs)),this.diagram.scrollActions|=ca.Interaction;var c=!0;if(t.isTrusted){var d=!1;(Math.abs(t.deltaY)<100&&-0===Math.abs(t.deltaX)||Math.abs(t.deltaX)<100&&-0===Math.abs(t.deltaY))&&(d=!0);var u=!1;(0!==t.deltaX||0!==t.deltaY)&&(u=navigator.userAgent.includes("Macintosh")),u?Math.abs(t.deltaX)>Math.abs(t.deltaY)?(t.shiftKey||t.deltaX&&-0!==t.deltaX&&(d||!u))&&this.diagram.scroller.zoom(1,h,0,r,c,void 0,d):t.deltaY&&-0!==t.deltaY&&(d||!u)&&this.diagram.scroller.zoom(1,0,h,r,c,void 0,d):t.shiftKey||t.deltaX&&-0!==t.deltaX&&(d||!u)?this.diagram.scroller.zoom(1,h,0,r,c,void 0,d):t.deltaY&&-0!==t.deltaY&&(d||!u)&&this.diagram.scroller.zoom(1,0,h,r,c,void 0,d)}else t.shiftKey||t.deltaX&&-0!==t.deltaX?this.diagram.scroller.zoom(1,h,0,r,c):this.diagram.scroller.zoom(1,0,h,r,c);this.diagram.scrollActions&=~ca.Interaction,(a!==this.diagram.scroller.horizontalOffset||l!==this.diagram.scroller.verticalOffset)&&t.preventDefault()}if(this.diagram.textEditing){if(this.diagram.isTriggerEvent=!0,this.diagram.activeLabel.parentId){var f=this.diagram.getObject(this.diagram.activeLabel.parentId);this.diagram.startTextEdit(f,this.diagram.activeLabel.id)}this.diagram.isTriggerEvent=!1}this.diagram.blazorActions=this.diagram.blazorActions&~on.interaction}},n.prototype.keyDown=function(t){if(t.fromMouseEvents&&(t.ctrlKey&&(this.keyArgs.keyModifiers=1),t.shiftKey&&(this.keyArgs.keyModifiers=4),t.shiftKey&&t.ctrlKey&&(this.keyArgs.keyModifiers=5)),!(this.diagram.diagramActions&ee.TextEdit)&&!this.checkEditBoxAsTarget(t)||"Escape"===t.key||27===t.keyCode){var i=void 0,r=t.keyCode?t.keyCode:t.which,s=t.key;("ArrowDown"===s||"ArrowUp"===s||"ArrowLeft"===s||"ArrowRight"===s)&&(this.isNudgeKey=!0);var o=this.isMetaKey(t);if(this.diagram.commandManager&&this.diagram.commands)for(var l=0,h=Object.keys(this.diagram.commands);l4&&(S({keyDownEventArgs:KeyboardEvent,parameter:i.parameter,type:"KEYDOWN"}),this.keyCount=0)),this.isKeyUp=!1):S({keyDownEventArgs:KeyboardEvent,parameter:i.parameter})}break}}}}this.keyArgs={element:this.diagram.selectedItems,key:t.key,keyCode:t.keyCode?t.keyCode:t.which},this.getKeyModifier(this.keyArgs,t),this.diagram.diagramActions&ee.TextEdit&&this.getlabel(this.keyArgs,t),this.diagram.triggerEvent(Ce.keyDown,this.keyArgs)},n.prototype.getlabel=function(t,e){var i=this.diagram.activeLabel;t.target=this.diagram.element.id+"_editBox";var r=this.diagram.nameTable[i.parentId];if(document.getElementById(this.diagram.element.id+"_editBox")){t.text=document.getElementById(this.diagram.element.id+"_editBox").value;for(var s=0;s=this.diagram.scroller.viewPortWidth-18?r="right":e.x+this.diagram.scroller.horizontalOffsetthis.diagram.scroller.viewPortHeight-18?r="bottom":e.y+this.diagram.scroller.verticalOffset0&&(s=this.findIntersectChild(this.hoverElement)),"Auto"===this.hoverElement.tooltip.openOn&&""!==r&&Cx(this.diagram,s||(i?this.hoverElement:void 0)),this.hoverElement.tooltip.content&&("Mouse"===this.hoverElement.tooltip.relativeMode?this.setTooltipOffset(t):(this.diagram.tooltipObject.offsetX=0,this.diagram.tooltipObject.offsetY=0));var o=this.diagram.findObjectsUnderMouse(this.currentPosition),a=this.diagram.findObjectUnderMouse(o,this.action,this.inAction);if(null!==a){var l=void 0;this.hoverElement.tooltip.isSticky&&(this.diagram.tooltipObject.isSticky=!0),a instanceof te&&a.children&&a.children.length>0&&(a=s||a),l=a.ports&&(this.hoverElement instanceof Es||this.hoverElement instanceof xc)||a.annotations&&(this.hoverElement instanceof Zn||this.hoverElement instanceof Nr)?document.getElementById(a.id+"_"+this.hoverElement.id):document.getElementById(a.id+(a.shape&&a.shape instanceof am?"_content_native_element":"_groupElement")),"Auto"===this.hoverElement.tooltip.openOn&&""!==r&&(this.diagram.tooltipObject.close(),this.diagram.tooltipObject.openOn=this.hoverElement.tooltip.openOn,this.diagram.tooltipObject.dataBind()),function Wre(n,t){var e=0;return n instanceof de?n.constraints&qe.Tooltip?e=n.constraints&qe.Tooltip:n.constraints&qe.InheritTooltip&&(e=t.constraints&rt.Tooltip):n instanceof Es||n instanceof xc?n.constraints&ni.ToolTip?e=n.constraints&ni.ToolTip:n.constraints&ni.InheritTooltip&&(e=t.constraints&rt.Tooltip):n instanceof Zn||n instanceof Nr?n.constraints&Lr.Tooltip&&(e=n.constraints&Lr.Tooltip):n.constraints&ie.Tooltip?e=n.constraints&ie.Tooltip:n.constraints&ie.InheritTooltip&&(e=t.constraints&rt.Tooltip),e}(this.hoverElement,this.diagram)&&"Auto"===this.hoverElement.tooltip.openOn&&(this.diagram.tooltipObject.target=this.hoverElement.id,this.diagram.tooltipObject.open("Mouse"===this.hoverElement.tooltip.relativeMode?this.diagram.element:l))}}},n.prototype.elementLeave=function(){this.diagram.tooltipObject&&!this.diagram.tooltipObject.isSticky&&"Custom"!==this.diagram.tooltipObject.openOn&&this.diagram.tooltipObject.close()},n.prototype.setTooltipOffset=function(t){var e=function pse(n,t,e,i){var o="Mouse"===(!(e instanceof te?e.constraints&ie.InheritTooltip:e instanceof de?e.constraints&qe.InheritTooltip:e.constraints&ni.InheritTooltip)&&(e instanceof te?e.constraints&ie.Tooltip:e instanceof de?e.constraints&qe.Tooltip:e.constraints&ni.ToolTip)?e.tooltip.relativeMode:n.tooltip.relativeMode);"Mouse"===i?o=!0:"Object"===i&&(o=!1);var a=function fse(n,t,e,i){var o,r={},s=document.getElementById(e.element.id);if(n instanceof te||n instanceof de)o=n.wrapper.bounds;else{var a=e.findObjectsUnderMouse(t),l=e.findObjectUnderMouse(a,"Select",!1);o=e.findElementUnderMouse(l,t,e).bounds}var c=s.getBoundingClientRect();switch(e.tooltipObject.position){case"BottomCenter":r=zc(t,o.bottomCenter,e,i,c.width/2,c.height);break;case"BottomLeft":case"LeftBottom":r=zc(t,o.bottomLeft,e,i,0,c.height);break;case"BottomRight":case"RightBottom":r=zc(t,o.bottomRight,e,i,c.width,c.height);break;case"LeftCenter":r=zc(t,o.middleLeft,e,i,0,c.height/2);break;case"LeftTop":case"TopLeft":r=zc(t,o.topLeft,e,i,0,0);break;case"RightCenter":r=zc(t,o.middleRight,e,i,c.width,c.height/2);break;case"RightTop":case"TopRight":r=zc(t,o.topRight,e,i,c.width,0);break;case"TopCenter":r=zc(t,o.topCenter,e,i,c.width/2,0)}return r}(e,t,n,o),l=qa(n);return{x:a.x+l.width,y:a.y+l.height}}(this.diagram,t,this.hoverElement);this.diagram.tooltipObject.offsetX=e.x,this.diagram.tooltipObject.offsetY=e.y},n.prototype.altKeyPressed=function(t){return!!(t&pt.Alt)},n.prototype.ctrlKeyPressed=function(t){return!!(t&pt.Control)},n.prototype.shiftKeyPressed=function(t){return!!(t&pt.Shift)},n.prototype.scrolled=function(t){this.diagram.updateScrollOffset()},n.prototype.doubleClick=function(t){if(jv(this.diagram)){var e=void 0,i=this.diagram.findObjectsUnderMouse(this.currentPosition),r=this.diagram.findObjectUnderMouse(i,this.action,this.inAction);if(null!==r&&jv(this.diagram))if(e=this.diagram.findElementUnderMouse(r,this.currentPosition,this.diagram),this.tool&&(this.tool instanceof Oh||this.tool instanceof kh))this.tool.mouseUp(this.eventArgs),this.isMouseDown=!1,this.eventArgs={},this.tool=null,t.preventDefault();else{var o=this.diagram.commandHandler.getObjectLayer(r.id);!o||o.lock||!o.visible||this.diagram.diagramActions&ee.TextEdit||this.diagram.startTextEdit(r,e instanceof si?e.id.split(r.id+"_")[1]:void 0)}this.diagram.triggerEvent(Ce.doubleClick,{source:r||this.diagram,position:this.currentPosition,count:t.detail})}},n.prototype.itemClick=function(t,e){var i=t;return cs(this.diagram,i,!0)?i:null},n.prototype.inputChange=function(t){var i,s,o,a,l,h,c,d,u,p=document.getElementById(this.diagram.element.id+"_editBox"),f=document.getElementById(this.diagram.element.id+"_editTextBoxDiv"),g=p.value,v=g.split("\n");(!(a=this.diagram.selectedItems.nodes[0]?this.diagram.selectedItems.nodes[0]:this.diagram.selectedItems.connectors[0])&&this.tool instanceof GI||a&&"SwimLane"===a.shape.type)&&(a=this.diagram.nameTable[this.diagram.activeLabel.parentId]),a&&("Text"!==a.shape.type&&a.annotations.length>0||"Text"===a.shape.type)&&(c=NF((o=this.diagram.getWrapper(a.wrapper,this.diagram.activeLabel.id)).style,g,void 0,void 0,i=(i=a.wrapper.bounds.width90?i:90),s=Number(p.style.fontSize.split("px")[0]),v.length>1&&""===v[v.length-1]&&(c.height=c.height+s),d=this.diagram.scroller.transform,u=T3(this.diagram)?d.scale:1,l=(12>c.height?12:c.height)*u,f.style.left=(o.bounds.center.x+d.tx)*d.scale-(h=(90>(h=c.width)?90:h)*u)/2-2.5+"px",f.style.top=(o.bounds.center.y+d.ty)*d.scale-l/2-3+"px",f.style.width=h+"px",f.style.height=l+"px",p.style.minHeight="12px",p.style.minWidth="90px",p.style.width=h+"px",p.style.height=l+"px")},n.prototype.isAddTextNode=function(t,e){return!(!(this.tool instanceof GI||e)||(this.tool=null,t&&!RI(this.diagram)&&(this.diagram.drawingObject=void 0,this.diagram.currentDrawingObject=void 0),vF(this.diagram.nodes,t.id)||vF(this.diagram.connectors,t.id)))},n.prototype.checkEditBoxAsTarget=function(t){return!(!t.target||t.target.id!==this.diagram.element.id+"_editBox")},n.prototype.getMouseEventArgs=function(t,e,i,r){var s,o,a;if(e.position=t,i?(o=this.diagram.findObjectsUnderMouse(this.currentPosition,i),s=this.diagram.findTargetObjectUnderMouse(o,this.action,this.inAction,e.position,i)):"Drag"===this.action||"ConnectorSourceEnd"===this.action||"SegmentEnd"===this.action||"OrthoThumb"===this.action||"BezierSourceThumb"===this.action||"BezierTargetThumb"===this.action||"ConnectorTargetEnd"===this.action||-1!==this.action.indexOf("Rotate")||-1!==this.action.indexOf("Resize")?(s=this.diagram.selectedItems,!this.diagram.currentSymbol&&"Drag"===this.action&&s&&this.diagram.selectedItems.nodes.length>0&&"SwimLane"===this.diagram.selectedItems.nodes[0].shape.type&&(o=this.diagram.findObjectsUnderMouse(this.currentPosition),s=this.diagram.findObjectUnderMouse(o,this.action,this.inAction))):(o=this.diagram.findObjectsUnderMouse(this.currentPosition),s=this.diagram.findObjectUnderMouse(o,this.action,this.inAction)),s&&s.isHeader&&(this.eventArgs.actualObject=s=this.diagram.nameTable[s.parentId]),s){var l=void 0,h=void 0,c=void 0;if(((a=this.diagram.findElementUnderMouse(s,this.currentPosition,this.diagram,r))&&s.ports&&s.ports.length&&!sb(s,a)||!a||!s)&&o&&o.length&&i instanceof oi)for(l=i.connectors[0],c=o.length-1;c>=0;c--)if(((h=o[parseInt(c.toString(),10)])instanceof te||h instanceof de)&&l&&l.connectionPadding){if(a=this.diagram.findElementUnderMouse(s=h,this.currentPosition,this.diagram,r),l.constraints&qe.ConnectToNearByPort&&s&&s.ports&&s.ports.length&&sb(s,a))break;if((h instanceof te||h instanceof de)&&l&&l.connectionPadding&&h.wrapper.outerBounds.containsPoint(this.currentPosition)&&l.constraints&qe.ConnectToNearByNode&&!(l.constraints&qe.ConnectToNearByPort)){a=this.diagram.findElementUnderMouse(s=h,this.currentPosition,this.diagram,0);break}}}return i?(e.target=s,e.targetWrapper=a):(e.source=s,e.sourceWrapper=a),e.actualObject=this.eventArgs.actualObject,e.source instanceof oi&&void 0===e.actualObject&&(e.source.nodes.length>0||e.source.connectors.length>0)&&(e.actualObject=e.source.nodes.length>0?this.diagram.nameTable[e.source.nodes[0].id]:this.diagram.nameTable[e.source.connectors[0].id]),e.startTouches=this.touchStartList,e.moveTouches=this.touchMoveList,e},n.prototype.resetTool=function(){this.action="Select",this.hoverElement=null,this.hoverNode=null,this.tool=this.diagram.getTool(this.action),this.updateCursor()},n.prototype.updateTool=function(){this.eventArgs&&!this.eventArgs.position&&(this.action="Select")},n.prototype.getTool=function(t){switch(t){case"Select":return new Zv(this.commandHandler,!0);case"Drag":return new ua(this.commandHandler);case"Rotate":return new Gx(this.commandHandler);case"LayoutAnimation":return new One(this.commandHandler);case"FixedUserHandle":return new Nne(this.commandHandler,!0);case"Hyperlink":return new X3(this.commandHandler);case"ResizeSouthEast":case"ResizeSouthWest":case"ResizeNorthEast":case"ResizeNorthWest":case"ResizeSouth":case"ResizeNorth":case"ResizeWest":case"ResizeEast":return new zd(this.commandHandler,t);case"ConnectorSourceEnd":case"ConnectorTargetEnd":case"BezierSourceThumb":case"BezierTargetThumb":return new Pd(this.commandHandler,t);case"SegmentEnd":case"OrthoThumb":return new ZF(this.commandHandler,t);case"Draw":var e="shape",i=function ose(n){var t;return n&&(n.type?t="Connector":n.shape&&!n.type&&(t="Node")),t}(this.diagram.drawingObject);if("Node"===i&&"Text"===this.diagram.drawingObject.shape.type)return new GI(this.commandHandler);if("Connector"===i&&"Freehand"===this.diagram.drawingObject.type)return new Rne(this.commandHandler);if("Node"===i&&"Polygon"===this.diagram.drawingObject.shape[""+e]&&!this.diagram.drawingObject.shape.points)return new Oh(this.commandHandler);if("Node"===i||"Node"===i&&"Polygon"===this.diagram.drawingObject.shape[""+e]&&this.diagram.drawingObject.shape.points)return new QI(this.commandHandler,this.diagram.drawingObject);if("Connector"===i&&"Polyline"===this.diagram.drawingObject.type)return new kh(this.commandHandler);if("Connector"===i)return new pa(this.commandHandler,"ConnectorSourceEnd",this.diagram.drawingObject);break;case"Pan":return new Jv(this.commandHandler,!1);case"PinchZoom":return new Jv(this.commandHandler,!0);case"PortDrag":return new ua(this.commandHandler,"Port");case"PortDraw":return new pa(this.commandHandler,"ConnectorSourceEnd",this.diagram.drawingObject);case"LabelSelect":return new Zv(this.commandHandler,!0,"LabelSelect");case"LabelDrag":return new kne(this.commandHandler);case"LabelResizeSouthEast":case"LabelResizeSouthWest":case"LabelResizeNorthEast":case"LabelResizeNorthWest":case"LabelResizeSouth":case"LabelResizeNorth":case"LabelResizeWest":case"LabelResizeEast":return new Pne(this.commandHandler,t);case"LabelRotate":return new zne(this.commandHandler)}return null},n.prototype.getCursor=function(t){var e=this.diagram.selectedItems.annotation?this.diagram.selectedItems.wrapper.children[0]:this.diagram.selectedItems;return function Lne(n,t){if(t+=360,t%=360,-1===n.indexOf("Resize"))return Qx[""+n];var e=Qx[""+n];return t>=0&&t<25||t>=160&&t<=205||t>=340&&t<=360?e:t>=25&&t<=70||t>=205&&t<=250?"n-resize"===e||"s-resize"===e?"ne-resize":"nw-resize"===e||"se-resize"===e?"n-resize":"e-resize"===e||"w-resize"===e?"nw-resize":"e-resize":t>=70&&t<=115||t>=250&&t<=295?"n-resize"===e||"s-resize"===e?"e-resize":"nw-resize"===e||"se-resize"===e?"ne-resize":"e-resize"===e||"w-resize"===e?"n-resize":"nw-resize":t>=115&&t<=155||t>=295&&t<=340?"n-resize"===e||"s-resize"===e?"nw-resize":"nw-resize"===e||"se-resize"===e?"e-resize":"e-resize"===e||"w-resize"===e?"ne-resize":Qx[""+n]:"n-resize"}(t,this.diagram.selectedItems.annotation?e.rotateAngle+e.parentTransform:e.rotateAngle)},n.prototype.findElementUnderMouse=function(t,e,i,r){return this.objectFinder.findElementUnderSelectedItem(t,e,i,r)},n.prototype.findObjectsUnderMouse=function(t,e){return this.objectFinder.findObjectsUnderMouse(t,this.diagram,this.eventArgs,e)},n.prototype.findObjectUnderMouse=function(t,e,i){return this.objectFinder.findObjectUnderMouse(this.diagram,t,e,i,this.eventArgs,this.currentPosition)},n.prototype.findTargetUnderMouse=function(t,e,i,r,s){return this.objectFinder.findObjectUnderMouse(this.diagram,t,e,i,this.eventArgs,r,s)},n.prototype.findActionToBeDone=function(t,e,i,r){return function Cne(n,t,e,i,r,s,o){if(s&&s.length>1&&r&&r.length>1)return"PinchZoom";if(i.currentSymbol)return"Drag";if("PortDraw"===i.eventHandler.action&&(i.tool&=~Ci.DrawOnce),(x3(i)||RI(i))&&i.drawingObject)return"Draw";if(Xa(i)&&(l=i.selectedItems).wrapper&&qr(l.constraints,"UserHandle"))for(var h=0,c=l.userHandles;h=50&&(l.x=(a.points[parseInt(h.toString(),10)].x+a.points[h+1].x)/2,l.y=(a.points[parseInt(h.toString(),10)].y+a.points[h+1].y)/2,wr(e,l,n.hitPadding?n.hitPadding:10)))return"OrthoThumb"}else OI(n)&&console.warn('[WARNING] :: Module "ConnectorEditing" is not available in Diagram component! You either misspelled the module name or forgot to load it.');return null}(g,l,e,i);if("OrthoThumb"===S)return S;if(qr(l.constraints,"ConnectorSourceThumb")&&LI(g)&&S||qr(l.constraints,"ConnectorTargetThumb")&&NI(g)&&S)return S}}else{var b=i.selectedItems.handleSize/2/i.scroller.currentZoom,M=10/i.scroller.currentZoom,w=Hi();qi(w,p.rotateAngle+p.parentTransform,p.offsetX,p.offsetY);var C=p.offsetX-p.pivot.x*p.actualSize.width,D=p.offsetY-p.pivot.y*p.actualSize.height,A={x:C+(.5===p.pivot.x?2*p.pivot.x:p.pivot.x)*p.actualSize.width/2,y:D-30/i.scroller.currentZoom};A=Je(w,A);var x=!!i.selectedItems.annotation,R=!(!x||!kI(i.selectedItems.annotation));if(qr(l.constraints,"Rotate")&&wr(e,A,M)&&i.selectedItems.thumbsConstraints&bt.Rotate){if(x&&R)return"LabelRotate";if(!x)return"Rotate"}if(u.Inflate(b),u.containsPoint(e)&&(S=function Ene(n,t,e,i,r,s){var o;return 1===n.selectedItems.nodes.length&&0===n.selectedItems.connectors.length&&n.selectedItems.nodes[0].container&&(o=function Tne(n,t,e,i,r){var s=10/n.scroller.currentZoom,o=40/n.scroller.currentZoom,a=n.selectedItems,l=t.actualSize.width,h=t.actualSize.height,c=new Ne(i,r,t.style.strokeWidth,h),d=new Ne(i+l,r,t.style.strokeWidth,h),u=new Ne(i,r,l,t.style.strokeWidth),p=new Ne(i,r+h,l,t.style.strokeWidth),f=cs(n,n.selectedItems.nodes[0],!0)?n.nameTable[n.selectedItems.nodes[0].parentId]:n.selectedItems.nodes[0];if(l>=o&&h>=o){if(fa(a.constraints,"ResizeEast",a.thumbsConstraints,a)&&d.containsPoint(e,s))return"ResizeEast";if(fa(a.constraints,"ResizeSouth",a.thumbsConstraints,a)&&p.containsPoint(e,s))return"ResizeSouth";if("Grid"!==f.container.type){if(fa(a.constraints,"ResizeWest",a.thumbsConstraints,a)&&c.containsPoint(e,s))return"ResizeWest";if(fa(a.constraints,"ResizeNorth",a.thumbsConstraints,a)&&u.containsPoint(e,s))return"ResizeNorth"}}return null}(n,t,e,r,s)),!o&&(!n.selectedItems.nodes[0]||!n.selectedItems.nodes[0].isPhase&&!n.selectedItems.nodes[0].isLane&&"SwimLane"!==n.selectedItems.nodes[0].shape.type)&&(o=function Ane(n,t,e,i,r,s){var o=40/n.scroller.currentZoom,a=n.selectedItems.handleSize/2/n.scroller.currentZoom,l=n.selectedItems,h=!!l.annotation;if(t.actualSize.width>=o&&t.actualSize.height>=o){if(fa(l.constraints,"ResizeSouthEast",l.thumbsConstraints,l)&&wr(e,Je(i,{x:r+t.actualSize.width,y:s+t.actualSize.height}),a))return h?"LabelResizeSouthEast":"ResizeSouthEast";if(fa(l.constraints,"ResizeSouthWest",l.thumbsConstraints,l)&&wr(e,Je(i,{x:r,y:s+t.actualSize.height}),a))return h?"LabelResizeSouthWest":"ResizeSouthWest";if(fa(l.constraints,"ResizeNorthEast",l.thumbsConstraints,l)&&wr(e,Je(i,{x:r+t.actualSize.width,y:s}),a))return h?"LabelResizeNorthEast":"ResizeNorthEast";if(fa(l.constraints,"ResizeNorthWest",l.thumbsConstraints,l)&&wr(e,Je(i,{x:r,y:s}),a))return h?"LabelResizeNorthWest":"ResizeNorthWest"}return fa(l.constraints,"ResizeEast",l.thumbsConstraints,l)&&wr(e,Je(i,{x:r+t.actualSize.width,y:s+t.actualSize.height/2}),a)?h?"LabelResizeEast":"ResizeEast":fa(l.constraints,"ResizeWest",l.thumbsConstraints,l)&&wr(e,Je(i,{x:r,y:s+t.actualSize.height/2}),a)?h?"LabelResizeWest":"ResizeWest":fa(l.constraints,"ResizeSouth",l.thumbsConstraints,l)&&wr(e,Je(i,{x:r+t.actualSize.width/2,y:s+t.actualSize.height}),a)?h?"LabelResizeSouth":"ResizeSouth":fa(l.constraints,"ResizeNorth",l.thumbsConstraints,l)&&wr(e,Je(i,{x:r+t.actualSize.width/2,y:s}),a)?h?"LabelResizeNorth":"ResizeNorth":null}(n,t,e,i,r,s)),o||null}(i,p,e,w,C,D),S))return S}}if(Lc(i)&&!n)return"Pan";if((o instanceof Es||o instanceof xc)&&(!Lc(i)||_v(i)||Uv(i))&&(S=function xne(n,t,e,i){if(Fx(t)&&(ga(t,Gt.Hover)||ga(t,Gt.Visible))){if(t.constraints&ni.Drag)return"PortDrag"}else if(Bx(t)&&(ga(t,Gt.Hover)||ga(t,Gt.Visible))&&t.constraints&ni.Draw){n.drawingObject={};var r={type:"Orthogonal",sourcePortID:t.id};return n.drawingObject=r,n.tool|=Ci.DrawOnce,n.currentDrawingObject=r,"PortDraw"}return"None"}(i,o),"None"!==S))return S;if((o instanceof Zn||o instanceof Nr)&&!Lc(i)&&Td(o))return _r(i,o,void 0,t)&&to(o)?"LabelDrag":"LabelSelect";if(null!==n){if(!(n instanceof te||n instanceof de))return"Select";if(t&&t.id){var L=t.id.split(n.id)[1];if(L&&L.match("^_icon"))return"LayoutAnimation"}if(t&&t.id)for(var O=void 0,N=0;N-1)return"FixedUserHandle";if(t instanceof si&&t.hyperlink.link)return"Hyperlink";if(!to(n)||!_r(i,n,!1)||void 0!==i.selectedItems.annotation)return n&&Lc(i)&&!HI(i)?"Pan":i.selectedItems.nodes.length&&i.selectedItems.nodes[0].isLane&&i.selectedItems.wrapper&&i.selectedItems.wrapper.bounds.containsPoint(e)?"Drag":"Select";if(n instanceof de&&!wr(e,n.sourcePoint,n.hitPadding)&&!wr(e,n.targetPoint,n.hitPadding)||!(n instanceof de))return"Drag"}return"Select"}(t,e,this.currentPosition,this.diagram,this.touchStartList,this.touchMoveList,r)},n.prototype.updateContainerBounds=function(t){var e=!1;if(this.diagram.selectedObject.helperObject&&this.diagram.selectedObject.actualObject instanceof te){var i=this.tool instanceof zd,r=this.diagram.selectedObject.actualObject,s=this.diagram.nameTable[r.parentId];t?V3(this.diagram,r,this.currentPosition,i):((!s||s&&"SwimLane"!==s.shape.type)&&this.diagram.updateDiagramObject(r),e=function Ine(n,t,e,i){var r,o=!1;if(cs(n,t,!0)){n.protectPropertyChange(!0);var a=(r=n.nameTable[t.parentId]).wrapper;if(r&&"Canvas"===r.container.type){if(i||a.bounds.x<=e.x&&a.bounds.right>=e.x&&a.bounds.y<=e.y&&a.bounds.bottom>=e.y){var l=void 0,h=a.bounds.y,c=a.bounds.x,d=n.nameTable[r.parentId]||r;if("SwimLane"===d.shape.type)o=$v(r,d,t,n,!0);else{var p=n.nameTable[r.parentId]||r,f=p.shape;l=p.wrapper,a.actualSize.widtha.outerBounds.x)&&(void 0!==r.rowIndex?(l.updateColumnWidth(r.columnIndex,a.outerBounds.width,!0),"Horizontal"===f.orientation&&f.phaseSize&&jI(p,n,a,r.columnIndex),Oc(n,p),n.drag(p,c-a.bounds.x,h-a.bounds.y)):n.scale(r,1+(a.outerBounds.width-a.actualSize.width)/a.actualSize.width,1,a.outerBounds.xa.outerBounds.y)&&(void 0!==r.rowIndex?(l.updateRowHeight(r.rowIndex,a.outerBounds.height,!0),n.drag(p,c-a.bounds.x,h-a.bounds.y)):n.scale(r,1,1+(a.outerBounds.height-a.actualSize.height)/a.actualSize.height,a.outerBounds.yi.y&&(h+=u>0?-1:1,u+=u>0?-1:1):i&&e.wrapper.offsetYi.x&&(h+=u>0?-1:1,u+=u>0?-1:1):i&&e.wrapper.offsetX1&&!(this.diagram.lineRoutingModule&&this.diagram.constraints&rt.LineRouting))for(var b=t.offsetX-this.diagram.selectedItems.offsetX,M=t.offsetY-this.diagram.selectedItems.offsetY,w=t.rotateAngle-this.diagram.selectedItems.rotateAngle,C=0;C-1){var x=c.children;x.splice(x.indexOf(o.id),1),this.diagram.nameTable[o.id].parentId="",i=!0,c.wrapper.children.splice(A,1)}}if(function wne(n,t,e,i){var r=n,s=e.nameTable[r.parentId],o=e.nameTable[r.parentId];if(t&&o&&o.container&&"Stack"===o.container.type&&t.container&&"Stack"===t.container.type&&o.id!==t.parentId){var a=o.wrapper.children.indexOf(r.wrapper);a>-1&&(e.nameTable[r.id].parentId=t.id,o.wrapper.children.splice(a,1))}if(t&&t.parentId&&r.parentId&&"Drag"===i&&o.container&&"Stack"===o.container.type){var l=s.wrapper.children.indexOf(t.wrapper),h=s.wrapper.children.indexOf(r.wrapper),c={targetIndex:l,target:t,sourceIndex:h,source:n};s.wrapper.children.splice(h,1),s.wrapper.children.splice(l,0,r.wrapper),e.commandHandler.addHistoryEntry({type:"StackChildPositionChanged",redoObject:{targetIndex:h,target:t,sourceIndex:l,source:n},undoObject:c,category:"Internal"})}}(o,h,this.diagram,this.action),(c=cs(this.diagram,o)?this.diagram.nameTable[o.parentId]:this.diagram.nameTable[o.parentId]||o)&&c.container&&"Canvas"===c.container.type&&(c.wrapper.maxWidth=c.maxWidth=c.wrapper.actualSize.width,c.wrapper.maxHeight=c.maxHeight=c.wrapper.actualSize.height,e=!0),cs(this.diagram,o,!0)&&c&&"Canvas"===c.container.type)if(this.diagram.selectedItems.nodes.length>1)for(C=0;C0)for(var i=0;i0&&e.columnIndex>0||l&&e.isLane)){if("Horizontal"===t.container.orientation&&e.isPhase&&e.wrapper.width>e.maxWidth&&(e.maxWidth=e.wrapper.width,e.wrapper.maxWidth=e.wrapper.width),h.updateColumnWidth(e.columnIndex,r.width,!0,c),jx(this.diagram,e,t),e.isPhase){var f=this.diagram.nameTable[""+t.shape.phases[e.columnIndex].header.id];f.maxWidth0?(r=new sf(t,"",u),t.shape.classShape.attributes.push(r)):i.id.includes("_umlMethods")&&t.shape.classShape.methods.length>0&&(s=new hm(t,"",u),t.shape.classShape.methods.push(s))),"Interface"===t.shape.classifier&&(i.id.includes("_umlProperty")&&t.shape.interfaceShape.attributes.length>0?(r=new sf(t,"",u),t.shape.classShape.attributes.push(r)):i.id.includes("_umlMethods")&&t.shape.interfaceShape.methods.length>0&&(s=new hm(t,"",u),t.shape.interfaceShape.methods.push(s))),"Enumeration"===t.shape.classifier&&i.id.includes("_umlMember")&&t.shape.enumerationShape.members.length>0){var p=new lb(t,"",u);t.shape.enumerationShape.members.push(p)}t.wrapper.children.indexOf(c.wrapper),this.diagram.enableServerDataBinding(!0),this.diagram.add(c),this.diagram.updateConnectorEdges(t),this.diagram.clearSelection(),this.diagram.select([this.diagram.nameTable[c.id]]),this.diagram.endGroupAction(),this.diagram.startTextEdit()}}},n}(),joe=function(){function n(){}return n.prototype.findObjectsUnderMouse=function(t,e,i,r,s){var o=[];r&&r instanceof oi&&r.nodes.length+r.connectors.length===1&&(r=r.nodes[0]||r.connectors[0]).children&&0===r.children.length&&(i.actualObject=r);for(var a,l,h,c,f,d=r&&r instanceof de&&(r.constraints&qe.ConnectToNearByNode||r.constraints&qe.ConnectToNearByPort)&&r.connectionPadding||0,p={},g=0,v=e.spatialSearch.findObjects(new Ne(t.x-50-d,t.y-50-d,100+d,100+d));g-1&&o.splice(T,1),"UmlClassifier"===y.shape.type&&y.container&&"Stack"===y.container.type&&(T=o.indexOf(e.nameTable[e.nameTable[y.id].wrapper.children[0].id]))>-1&&o.splice(T,1)}for(var P=0;Ps.zIndex&&(t[parseInt(r.toString(),10)]=l),r>0&&i&&a&&(a.isLane||a.isPhase||a.isHeader)&&t[parseInt(r.toString(),10)].zIndex=2)for(var d=t.length-1;d>=0;d--)if(t[parseInt(d.toString(),10)].parentId){var u=sm(t[parseInt(d.toString(),10)],e,""),p=sm(t[d-1],e,""),g=e.nameTable[""+p];g&&u!==p&&e.nameTable[""+u].zIndex=0;f--){d=ef(e[parseInt(f.toString(),10)],!1),c=ef(e[parseInt(f.toString(),10)],!0);var g=t[""+l].tool,v=this.findTargetElement(e[parseInt(f.toString(),10)].wrapper,o,t,void 0);if("Draw"===i&&v&&(e[parseInt(f.toString(),10)]instanceof te||e[parseInt(f.toString(),10)]instanceof de)&&!sb(e[parseInt(f.toString(),10)],v)&&(g&&"ConnectorSourceEnd"===g[""+h]&&!Nh(e[parseInt(f.toString(),10)])||g&&"ConnectorTargetEnd"===g[""+h]&&!da(e[parseInt(f.toString(),10)])))return u;if(e[parseInt(f.toString(),10)]instanceof te||e[parseInt(f.toString(),10)]instanceof de&&(Nh(e[parseInt(f.toString(),10)])||Ad(d)||da(e[parseInt(f.toString(),10)])||Lh(c)||"PortDraw"===i&&g instanceof Pd&&"ConnectorTargetEnd"===g[""+h]&&(da(e[parseInt(f.toString(),10)])||Lh(c))))return u=e[parseInt(f.toString(),10)],p&&(u=this.isTarget(u,t,i)),s.actualObject=u,u}else if("ConnectorTargetEnd"===i&&a){for(f=e.length-1;f>=0;f--)if(c=ef(e[parseInt(f.toString(),10)],!0),(e[parseInt(f.toString(),10)]instanceof te||e[parseInt(f.toString(),10)]instanceof de)&&(da(e[parseInt(f.toString(),10)])||Lh(c)))return u=e[parseInt(f.toString(),10)],u=this.isTarget(u,t,i),s.actualObject=u,u}else{if(a&&("Drag"===i||t[""+l].tool instanceof ua)){var y=0;for(f=0;f=S.zIndex?u:S,y=Math.max(y,S.zIndex)):y=(u=S).zIndex)}return u&&"Bpmn"===u.shape.type&&(t.selectedItems.nodes.length>0&&"Bpmn"===t.selectedItems.nodes[0].shape.type||(u=null)),u&&(s.actualObject=u),u}if("Select"!==i&&"Pan"!==i||!t[""+l].tool)if("Pan"===i||"LayoutAnimation"===i){for(f=e.length-1;f>=0;f--)if((e[parseInt(f.toString(),10)]instanceof te||e[parseInt(f.toString(),10)]instanceof de)&&(v=this.findTargetElement(e[parseInt(f.toString(),10)].wrapper,o,t,void 0),"Pan"===i||v&&(v.id.match("_icon_content_shape$")||v.id.match("_icon_content_rect$"))))return e[parseInt(f.toString(),10)]}else u=e[e.length-1],s&&u&&(s.actualObject=u);else{for(f=e.length-1;f>=0;f--)if(e[parseInt(f.toString(),10)]instanceof de){var b=e[f-1];if(e[f-1]instanceof te&&b.ports){if((v=this.findTargetElement(b.wrapper,o,t,void 0))&&(v.id.match("_icon_content_shape$")||v.id.match("_icon_content_rect$")))return b;for(var M=0;M=0;s--){var o=t.children[parseInt(s.toString(),10)];if(o&&o.outerBounds.containsPoint(e,r||0))if(o.visible){if(o instanceof Cs){var a=this.findTargetElement(o,e,i);if(a)return a}var l="Clip"===o.style.textOverflow||"Ellipsis"===o.style.textOverflow;if(o.bounds.containsPoint(e,r||0)&&!l)return o;if(t.bounds.containsPoint(e,r||0)&&l)return o}else if(o instanceof Ke&&t&&t.id){var h=void 0;if(t.id.includes("group_container")){var c=t.id.slice(0,-15);h=i.getObject(c)}else h=i.getObject(t.id);if(rb(h,o.id))return o}}return t.bounds.containsPoint(e,r)&&"none"!==t.style.fill?t:null},n}(),Voe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),af=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},JF=function(n){function t(e,i,r,s){var o=n.call(this,e,i,r,s)||this;return o.objectZIndex=-1,o.zIndexTable={},o.objects=[],o}return Voe(t,n),af([I("")],t.prototype,"id",void 0),af([I(!0)],t.prototype,"visible",void 0),af([I(!1)],t.prototype,"lock",void 0),af([I()],t.prototype,"objects",void 0),af([I()],t.prototype,"addInfo",void 0),af([I(-1)],t.prototype,"zIndex",void 0),t}(Ee),CT=function(n,t,e,i){return new(e||(e=Promise))(function(r,s){function o(h){try{l(i.next(h))}catch(c){s(c)}}function a(h){try{l(i.throw(h))}catch(c){s(c)}}function l(h){h.done?r(h.value):new e(function(c){c(h.value)}).then(o,a)}l((i=i.apply(n,t||[])).next())})},ET=function(n,t){var i,r,s,o,e={label:0,sent:function(){if(1&s[0])throw s[1];return s[1]},trys:[],ops:[]};return o={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function a(h){return function(c){return function l(h){if(i)throw new TypeError("Generator is already executing.");for(;e;)try{if(i=1,r&&(s=2&h[0]?r.return:h[0]?r.throw||((s=r.return)&&s.call(r),0):r.next)&&!(s=s.call(r,h[1])).done)return s;switch(r=0,s&&(h=[2&h[0],s.value]),h[0]){case 0:case 1:s=h;break;case 4:return e.label++,{value:h[1],done:!1};case 5:e.label++,r=h[1],h=[0];continue;case 7:h=e.ops.pop(),e.trys.pop();continue;default:if(!(s=(s=e.trys).length>0&&s[s.length-1])&&(6===h[0]||2===h[0])){e=0;continue}if(3===h[0]&&(!s||h[1]>s[0]&&h[1]1)for(var i=0;i-1)return e[parseInt(i.toString(),10)];return this.diagram.activeLayer},n.prototype.getLayer=function(t){for(var e=this.diagram.layers,i=0;i=0;o--)this.diagram.unSelect(this.diagram.nameTable[s[parseInt(o.toString(),10)]]),this.diagram.remove(this.diagram.nameTable[s[parseInt(o.toString(),10)]]),"default_layer"!==i.id&&this.diagram.activeLayer.id===t&&(this.diagram.activeLayer=this.diagram.layers[this.diagram.layers.length-1]);delete this.diagram.layerZIndexTable[i.zIndex],this.diagram.layers.splice(r,1),"SVG"!==this.diagram.mode&&this.diagram.refreshDiagramLayer()}},n.prototype.moveObjects=function(t,e){this.diagram.startGroupAction();for(var i={},r=[],s=0;s-1){if(r=[],(h=this.diagram.nameTable[""+s]).children)for(var f=0,g=h.children;f0){for(var y=void 0,S=0,b=r;S0)for(var r=0;r0)for(r=0;r0){t=t.concat(this.diagram.selectedItems.connectors);for(var i=0;i0)for(t=t.concat(this.diagram.selectedItems.nodes),i=0;i0){for(var i=0,r=t.shape.activity.subProcess.processes;i0&&this.copyProcesses(this.processTable[""+s])}this.clipboardData.processTable=this.processTable}},n.prototype.group=function(){this.oldSelectedObjects=rm(this.diagram);var e=this.diagram.isProtectedOnChange;this.diagram.protectPropertyChange(!0),this.diagram.diagramActions=this.diagram.diagramActions|ee.Group;var r={};r.id="group"+Qe(),(r=new te(this.diagram,"nodes",r,!0)).children=[];for(var s=this.diagram.selectedItems.nodes.concat(this.diagram.selectedItems.connectors).sort(function(h,c){return h.zIndex-c.zIndex}),o=0;o0){var a=this.diagram.add(r);a&&this.select(a),this.addHistoryEntry({type:"Group",undoObject:r,redoObject:r,category:"Internal"}),this.diagram.diagramActions=this.diagram.diagramActions&~ee.Group,this.diagram.protectPropertyChange(e)}},n.prototype.unGroup=function(t){var i=this.diagram.isProtectedOnChange;this.diagram.protectPropertyChange(!0),this.diagram.diagramActions=this.diagram.diagramActions|ee.Group;var r=[];t?r.push(t):r=this.diagram.selectedItems.nodes,this.diagram.startGroupAction();for(var s=0;s0&&this.diagram.removePorts(o,o.ports),o.annotations&&o.annotations.length>0&&!ce()&&this.diagram.removeLabels(o,o.annotations);for(var c=this.diagram.nameTable[o.parentId],d=o.children.length-1;d>=0;d--)this.diagram.nameTable[o.children[parseInt(d.toString(),10)]].parentId="",this.diagram.deleteChild(this.diagram.nameTable[o.children[parseInt(d.toString(),10)]],o),o.parentId&&o.children[parseInt(d.toString(),10)]&&this.diagram.addChild(c,o.children[parseInt(d.toString(),10)]);this.resetDependentConnectors(o.inEdges,!0),this.resetDependentConnectors(o.outEdges,!1),this.diagram.diagramActions&ee.UndoRedo||this.addHistoryEntry({type:"UnGroup",undoObject:a,redoObject:a,category:"Internal"}),o.parentId&&this.diagram.deleteChild(o,c)}this.diagram.removeNode(o,l),this.clearSelection()}this.diagram.endGroupAction(),this.diagram.diagramActions=this.diagram.diagramActions&~ee.Group,this.diagram.protectPropertyChange(i)},n.prototype.resetDependentConnectors=function(t,e){for(var i=0;i0&&(g=!1)}if(g){var y=this.cloneConnector(p,i);c.push(y),o[h.id]=y.id}}else{var S=this.cloneNode(h,i);if(c.push(S),S){o[h.id]=S.id;var b=h.inEdges;if(b)for(var M=0,w=b;M0)for(var u=0;u0)for(r=t.segments,s=0;s0&&this.diagram.drawingObject&&"Bezier"===this.diagram.drawingObject.type&&(t.segments=[]);var e=this.diagram.add(t);"SVG"!==this.diagram.mode&&this.diagram.refreshDiagramLayer(),this.selectObjects([e]),t&&!RI(this.diagram)&&(this.diagram.tool&=~Ci.DrawOnce,this.diagram.currentDrawingObject=void 0)},n.prototype.enableServerDataBinding=function(t){this.diagram.enableServerDataBinding(t)},n.prototype.addText=function(t,e){var i=this.diagram.findElementUnderMouse(t,e,this.diagram);this.diagram.startTextEdit(t,i instanceof si?i.id.split("_")[1]:void 0)},n.prototype.isUserHandle=function(t){var e=this.diagram.selectedItems;if(e.wrapper&&qr(e.constraints,"UserHandle"))for(var i=0,r=e.userHandles;i0&&t[0]&&t[0].isLane)for(s=this.diagram.getObject(t[0].parentId),t[0].shape.header=[],a=0;a1||e&&1===t.length)){if(1!==t.length)return[2];this.clearSelection()}if(!(u||d||1!==t.length||e&&Xa(this.diagram)))return this.clearSelection(),[2]}if(!r.cancel){for(p=0;p0||e)&&f.children&&!f.parentId)for(g=0;g0||e,!0)}else this.select(f,p>0||e,!0);void 0===i&&(i=c),r={oldValue:i||[],newValue:this.getSelectedObject(),cause:this.diagram.diagramActions,state:"Changed",type:"Addition",cancel:!1},this.diagram.renderSelector(e||t&&t.length>1),ce()||this.diagram.triggerEvent(Ce.selectionChange,r),this.diagram.enableServerDataBinding(!0)}return[2]})})},n.prototype.findParent=function(t){return t.parentId&&this.findParent(t=this.diagram.nameTable[t.parentId]),t},n.prototype.selectProcesses=function(t){if(this.hasProcesses(t))for(var e=t.shape.activity.subProcess.processes,i=0;i0)},n.prototype.select=function(t,e,i){var r=this.getObjectLayer(t.id);if(Td(t)&&!(t instanceof oi)&&!_r(this.diagram,t)&&r&&!r.lock&&r.visible&&t.wrapper.visible){(e=!!Xa(this.diagram)&&e)||this.clearSelection(),this.diagram.enableServerDataBinding(!1);var s=this.diagram.selectedItems;if(t instanceof te?s.nodes.push(t.isHeader?this.diagram.nameTable[t.parentId]:t):s.connectors.push(t),s.selectedObjects.push(t),e)s.wrapper.rotateAngle=s.rotateAngle=0,s.wrapper.children.push(t.wrapper);else if(s.init(this.diagram),1===s.nodes.length&&0===s.connectors.length){var l=Vx(this.diagram,s);l&&(s.wrapper.children[0]=l),s.rotateAngle=s.nodes[0].rotateAngle,s.wrapper.rotateAngle=s.nodes[0].rotateAngle,s.wrapper.pivot=s.nodes[0].pivot}i||this.diagram.renderSelector(e),this.diagram.enableServerDataBinding(!0)}},n.prototype.labelSelect=function(t,e){this.oldSelectedObjects=rm(this.diagram);var i=this.diagram.selectedItems,r=this.diagram.allowServerDataBinding;this.diagram.allowServerDataBinding=!1,i.nodes=i.connectors=[],this.diagram.allowServerDataBinding=r,t instanceof te?i.nodes[0]=t:i.connectors[0]=t,i.annotation=this.findTarget(e,t),i.init(this.diagram),this.diagram.renderSelector(!1)},n.prototype.unSelect=function(t){var e=this.diagram.selectedItems.nodes.concat(this.diagram.selectedItems.connectors),i=e.filter(function(a){return a.id!==t.id}),r={oldValue:e,newValue:i,cause:this.diagram.diagramActions,state:"Changing",type:"Removal",cancel:!1};if(this.diagram.currentSymbol||ce()||this.diagram.triggerEvent(Ce.selectionChange,r),_r(this.diagram,t)){var s=this.diagram.selectedItems,o=void 0;t instanceof te?(o=s.nodes.indexOf(t,0),s.nodes.splice(o,1)):(o=s.connectors.indexOf(t,0),s.connectors.splice(o,1)),o=s.selectedObjects.indexOf(t,0),s.selectedObjects.splice(o,1),(r={oldValue:e,newValue:i,cause:this.diagram.diagramActions,state:"Changed",type:"Removal",cancel:(r={oldValue:e,newValue:i,cause:this.diagram.diagramActions,state:"Changed",type:"Removal",cancel:!1}).cancel}).cancel||(o=s.wrapper.children.indexOf(t.wrapper,0),s.wrapper.children.splice(o,1),this.diagram.updateSelector(),this.diagram.currentSymbol||this.diagram.triggerEvent(Ce.selectionChange,r))}},n.prototype.moveSvgNode=function(t,e){var i=xt(e+"_groupElement",this.diagram.element.id),r=xt(t+"_groupElement",this.diagram.element.id);i.parentNode.insertBefore(r,i)},n.prototype.moveAfterSvgNode=function(t,e){var i=xt(e+"_groupElement",this.diagram.element.id),r=xt(t+"_groupElement",this.diagram.element.id);i.insertAdjacentElement("afterend",r)},n.prototype.sendLayerBackward=function(t){var e=this.getLayer(t);if(e&&0!==e.zIndex){var i=e.zIndex;if("SVG"===this.diagram.mode){var r=e.objects,s=this.getLayer(this.diagram.layerZIndexTable[i-1]).objects[0];if(s)for(var o=0,a=r;od&&"SwimLane"!==f.shape.type){var S=$(f);f.zIndex=d-((-1!==i.indexOf(f)?i.indexOf(f):0)+1),f.children&&(d=this.findLowestZIndex(f,c)||d),this.triggerOrderCommand(S,f,f),f.children&&this.updateGroupZindex(f,"SendToBack",d)}else"SwimLane"===f.shape.type&&(y=this.swapZIndexObjects(a,h,r,g));if("SVG"===this.diagram.mode){for(var M="SwimLane"!==this.diagram.nameTable[""+r].shape.type?d:y,w=h[parseInt(M.toString(),10)];!w&&Md)&&(d=p.zIndex)}for(var f=JSON.parse(JSON.stringify(l)),v=Number(Object.keys(l).sort(function(wo,Hl){return Number(wo)-Number(Hl)}).reverse()[0]),y=this.diagram.nameTable[""+e].zIndex,S=[],M=0;M<=v;M++)S.push(l[parseInt(M.toString(),10)]);if("SwimLane"===this.diagram.nameTable[""+e].shape.type)for(var C=v;C>=y;C--)if(l[parseInt(C.toString(),10)]&&this.diagram.nameTable[l[parseInt(C.toString(),10)]].parentId!==e){v=C;break}var D=this.diagram.nameTable[""+e];if(D.zIndexx&&(x=L.zIndex)}}else x=d;D.zIndex=x+((-1!==r.indexOf(D)?r.indexOf(D):0)+1),this.triggerOrderCommand(A,D,D)}else if("SwimLane"===D.shape.type){for(var O=0,N=-1,T=0,P=0,_=JSON.parse(JSON.stringify(l)),B=0;B<=y;B++)if(l[parseInt(B.toString(),10)]&&this.diagram.nameTable[l[parseInt(B.toString(),10)]].parentId===e&&-1===N){N=B,T=B;break}for(var j=0;j<=v;j++)f[parseInt(j.toString(),10)]&&f[parseInt(j.toString(),10)]!==e&&this.diagram.nameTable[f[parseInt(j.toString(),10)]].parentId!==e&&this.diagram.nameTable[f[parseInt(j.toString(),10)]].zIndex>=this.diagram.nameTable[""+e].zIndex&&O++;for(var ue=N,pe=0;pe<=O;pe++){for(;!l[parseInt(ue.toString(),10)];)ue++;P=this.diagram.nameTable[l[parseInt(ue.toString(),10)]].zIndex,ue++}for(var Me=P;Me<=v;Me++){for(;!_[parseInt(N.toString(),10)];)N++;for(;!l[parseInt(Me.toString(),10)];)Me++;l[parseInt(Me.toString(),10)]=_[parseInt(N.toString(),10)],this.diagram.nameTable[l[parseInt(Me.toString(),10)]].zIndex=Me,N++}l[parseInt(v.toString(),10)]=this.diagram.nameTable[""+e].id,this.diagram.nameTable[""+e].zIndex=v,ue=y+1;for(var De=T,xe=0;xe0&&("Native"===hr[0].shape.type||"HTML"===hr[0].shape.type)){for(Mi.parentNode.removeChild(Mi),De=0;De0?r[0]:null},n.prototype.findLowestZIndex=function(t,e){var r=this.diagram.nodes.filter(function(s){return-1!==e.indexOf(s.id)}).filter(function(s){return""===s.parentId&&s.id!==t.id}).map(function(s){return s.zIndex});return r.sort(function(s,o){return s-o}),r.length>0?r[0]:null},n.prototype.triggerOrderCommand=function(t,e,i){var s={zIndex:$(t).zIndex},o={zIndex:e.zIndex},a={element:i,cause:this.diagram.diagramActions,diagramAction:this.diagram.getDiagramAction(this.diagram.diagramActions),oldValue:s,newValue:o};this.diagram.triggerEvent(Ce.propertyChange,a)},n.prototype.checkGroupNode=function(t,e,i){return i[""+e].parentId===i[""+t].parentId},n.prototype.sortByZIndex=function(t,e,i){if("BringForward"===i){var r=e||"zIndex";t=t.sort(function(o,a){return a[""+r]-o[""+r]})}else{var s=e||"zIndex";t=t.sort(function(o,a){return o[""+s]-a[""+s]})}return t},n.prototype.orderCommands=function(t,e,i){var r=this,s=e.nodes;if(s=s.concat(e.connectors),t)if("SendBackward"===i)for(var o=0;oa}),S=v.filter(function(D){return D0?Math.max.apply(Math,S):a,M=y.length>0?Math.min.apply(Math,y):a;if(a!==M){var w=c.zIndexTable[parseInt(M.toString(),10)],C=c.zIndexTable[parseInt(a.toString(),10)];this.moveSvgNode(C,w)}else"SendToBack"===i&&(w=c.zIndexTable[parseInt(a.toString(),10)],C=c.zIndexTable[parseInt(b.toString(),10)],this.moveAfterSvgNode(w,C))}}else this.diagram.refreshCanvasLayers()}},n.prototype.sendForward=function(t){var e=this;if(this.diagram.protectPropertyChange(!0),Xa(this.diagram)||t){$(t||(this.diagram.selectedItems.nodes.length?this.diagram.selectedItems.nodes[0]:this.diagram.selectedItems.connectors[0]));var s=t&&t.id,o=this.diagram.layers.indexOf(this.getObjectLayer(s=s||(this.diagram.selectedItems.nodes.length?this.diagram.selectedItems.nodes[0].id:this.diagram.selectedItems.connectors[0].id))),a=$(this.diagram.nameTable),h=(parseInt(o.toString(),10),this.diagram.nameTable[""+s]),c=[],d=this.diagram.spatialSearch.findObjects(h.wrapper.bounds);d.length>2&&(d=this.sortByZIndex(d,void 0,"BringForward"));for(var u=0,p=d;u=0;f--)this.diagram.nameTable[c[parseInt(f.toString(),10)].id].parentId===s&&c.splice(f,1);if(c.length>0){var y=this.diagram.nameTable[c[c.length-1].id];if(y.parentId){var b=sm(y,this.diagram,""),M=this.diagram.nameTable[""+b];M.id!==s&&(c[0]=M)}var w={};for(f=0;f0&&(Object.values(O).forEach(function(ue){ue>=T&&N.push(ue)}),0!==N.length&&this.updateZIndexBySendForward(h,N,o))}var P=[];if(Object.keys(this.changedNodeZIndexes).forEach(function(ue){if((a[""+ue]?a[""+ue].zIndex:null)!==e.changedNodeZIndexes[""+ue]){var De=$(a[""+ue]);P.push(De)}}),this.updateLayerZindexTable(o),L.nodes.splice(0,L.nodes.length),P.forEach(function(ue){var pe=$(ue);L.nodes.push(pe)}),"SVG"===this.diagram.mode){var _=c[c.length-1].id,B=c[c.length-1];B&&!("HTML"===B.shape.type||"Native"===B.shape.type)&&this.moveAfterSvgNode(s,_),this.updateNativeNodeIndex(_,s)}else this.diagram.refreshCanvasLayers();var j=[];Object.keys(this.changedNodeZIndexes).forEach(function(ue){if((a[""+ue]?a[""+ue].zIndex:null)!==e.changedNodeZIndexes[""+ue]){var De=$(e.diagram.nameTable[""+ue]);j.push(De)}});var Q=$(this.diagram.selectedItems);Q.nodes.splice(0,Q.nodes.length),j.forEach(function(ue){var pe=$(ue);Q.nodes.push(pe)}),this.diagram.diagramActions&ee.UndoRedo||this.addHistoryEntry({type:"SendForward",category:"Internal",undoObject:L,redoObject:Q}),this.diagram.endGroupAction()}}this.diagram.protectPropertyChange(!1)},n.prototype.updateZIndexBySendForward=function(t,e,i){var r=$(t);t.zIndex=Math.min.apply(Math,e);var a,s=Math.min.apply(Math,e),o=Math.min.apply(Math,e),l=this.diagram.layers[parseInt(i.toString(),10)].objects,h=this.diagram.nodes.filter(function(S){return-1!==l.indexOf(S.id)});t.children&&this.updateGroupZindex(t,"BringForward",t.zIndex);var c=h.filter(function(S){return S.zIndex===Math.min.apply(Math,e)&&S.id!==t.id});if(c&&c.length>0&&c[0].children){for(var d=Math.min.apply(Math,e),u=0;uo&&g!==t&&g.parentId!==t.id&&c&&c.length>0&&g.parentId!==c[0].id){var v=$(g);g.zIndex=a+1,a++,this.triggerOrderCommand(v,g,g)}var y=g.zIndex;this.changedNodeZIndexes[g.id]=(this.changedNodeZIndexes.hasOwnProperty(g.id),y)}},n.prototype.arrangeZIndexForLowerNodes=function(t,e,i){var r=i.filter(function(o){return o.zIndex<=t&&o.parentId!==e.id});r.sort(function(o,a){return a.zIndex-o.zIndex});for(var s=0;se&&(e=r.zIndex)}return e},n.prototype.sendBackward=function(t){var e=this;if(this.diagram.protectPropertyChange(!0),Xa(this.diagram)||t){$(t||(this.diagram.selectedItems.nodes.length?this.diagram.selectedItems.nodes[0]:this.diagram.selectedItems.connectors[0]));var s=t&&t.id,o=this.diagram.layers.indexOf(this.getObjectLayer(s=s||(this.diagram.selectedItems.nodes.length?this.diagram.selectedItems.nodes[0].id:this.diagram.selectedItems.connectors[0].id))),a=$(this.diagram.nameTable),h=(parseInt(o.toString(),10),this.diagram.nameTable[""+s]),c=[],d=this.diagram.spatialSearch.findObjects(h.wrapper.bounds);d.length>2&&(d=this.sortByZIndex(d));for(var u=0,p=d;uNumber(f.zIndex)&&""===f.parentId&&h.wrapper.bounds.intersects(f.wrapper.bounds)&&c.push(f);for(var f=c.length-1;f>=0;f--)(v=this.diagram.nameTable[c[parseInt(f.toString(),10)].id]).parentId===s&&c.splice(f,1);if(c.length>0){var v;if((v=this.diagram.nameTable[c[c.length-1].id]).parentId){var S=sm(v,this.diagram,""),b=this.diagram.nameTable[""+S];s!==b.id&&(c[c.length-1]=b)}var M={};for(f=0;f0&&(Object.values(L).forEach(function(pe){pe<=N&&O.push(pe)}),0!==O.length&&this.updateZIndexBySendBackward(h,O,o))}var T=[];if(Object.keys(this.changedNodeZIndexes).forEach(function(pe){if((a[""+pe]?a[""+pe].zIndex:null)!==e.changedNodeZIndexes[""+pe]){var xe=$(a[""+pe]);T.push(xe)}}),this.updateLayerZindexTable(o),R.nodes.splice(0,R.nodes.length),T.forEach(function(pe){var Me=$(pe);R.nodes.push(Me)}),"SVG"===this.diagram.mode){var P=c[c.length-1].id,_=c[c.length-1];_&&"HTML"!==_.shape.type&&"Native"!==_.shape.type&&this.moveSvgNode(s,P);var B=this.diagram.nameTable[""+P];B.children&&B.children.length>0?this.updateNativeNodeIndex(s):this.updateNativeNodeIndex(s,P)}else this.diagram.refreshCanvasLayers();var j=[];Object.keys(this.changedNodeZIndexes).forEach(function(pe){if((a[""+pe]?a[""+pe].zIndex:null)!==e.changedNodeZIndexes[""+pe]){var xe=$(e.diagram.nameTable[""+pe]);j.push(xe)}});var Q=$(this.diagram.selectedItems);Q.nodes.splice(0,Q.nodes.length),j.forEach(function(pe){var Me=$(pe);Q.nodes.push(Me)}),this.diagram.diagramActions&ee.UndoRedo||this.addHistoryEntry({type:"SendBackward",category:"Internal",undoObject:R,redoObject:Q}),this.diagram.endGroupAction()}}this.diagram.protectPropertyChange(!1)},n.prototype.updateZIndexBySendBackward=function(t,e,i){var r=$(t);t.zIndex=Math.max.apply(Math,e);var p,s=t.zIndex,o=Math.max.apply(Math,e),a=this.diagram.layers[parseInt(i.toString(),10)].objects,l=this.diagram.nodes.filter(function(S){return-1!==a.indexOf(S.id)}),h=l.filter(function(S){return S.zIndex===Math.max.apply(Math,e)&&S.id!==t.id});if(h&&h.length>0&&h[0].children)for(var c=Math.max.apply(Math,e),d=0;d0&&g.parentId!==h[0].id){var v=$(g);g.zIndex=p-1,p--,this.triggerOrderCommand(v,g,g)}var y=g.zIndex;this.changedNodeZIndexes[""+g.id]=(this.changedNodeZIndexes.hasOwnProperty(g.id),y)}},n.prototype.findLowestChildZIndex=function(t){for(var e=t.zIndex,i=0;i0),this.selectObjects([t],!0))},n.prototype.clearSelection=function(t,e){return CT(this,void 0,void 0,function(){var i,r,s,o;return ET(this,function(a){return i=this.diagram.allowServerDataBinding,this.diagram.enableServerDataBinding(!1),Xa(this.diagram)&&(r=this.diagram.selectedItems,s=this.getSelectedObject(),this.diagram.currentSymbol&&(this.diagram.previousSelectedObject=s),o={oldValue:s,newValue:[],cause:this.diagram.diagramActions,state:"Changing",type:"Removal",cancel:!1},t&&(ce()||this.diagram.triggerEvent(Ce.selectionChange,o)),o.cancel||(r.offsetX=0,r.offsetY=0,r.width=0,r.height=0,r.rotateAngle=0,r.nodes=[],r.connectors=[],r.wrapper=null,r.annotation=void 0,r.selectedObjects=[],this.diagram.clearSelectorLayer(),t&&(o={oldValue:s,newValue:[],cause:this.diagram.diagramActions,state:"Changed",type:"Removal",cancel:!1},ce()||this.diagram.triggerEvent(Ce.selectionChange,o))),this.diagram.enableServerDataBinding(i)),[2]})})},n.prototype.clearSelectedItems=function(){this.clearSelection((this.diagram.selectedItems.nodes?this.diagram.selectedItems.nodes.length:0)+(this.diagram.selectedItems.connectors?this.diagram.selectedItems.connectors.length:0)>0)},n.prototype.removeStackHighlighter=function(){var t=Pl(this.diagram.element.id),e=t.getElementById(t.id+"_stack_highlighter");e&&e.parentNode.removeChild(e)},n.prototype.renderStackHighlighter=function(t,e){var r,s,o,i=this.diagram.selectedItems.nodes[0];if(!e){var a=this.diagram.findObjectsUnderMouse(t.position);if((e=this.diagram.findObjectUnderMouse(a,"Drag",!0))&&!(e.isLane||e.isPhase||e.isHeader))for(var l=0;l0)for(var a=0;a1)if(i){var h=l.segments[0],c=l.segments[1],u=Tc(EI(t.wrapper,t.wrapper.corners,t.wrapper.bounds),h.direction),g=Ll({corners:void 0,point:u=Ah(l,0,u,{x:l.sourceWrapper.offsetX,y:l.sourceWrapper.offsetY},!1),margin:void 0,direction:h.direction},{corners:void 0,point:c.points[1],margin:void 0,direction:void 0});h.length=z.distancePoints(g[0],g[1]),c.direction&&c.length&&(c.length=z.distancePoints(g[1],g[2]))}else if(o){switch(l.segments[0].direction){case"Bottom":r=t.wrapper.bounds.bottomCenter.x-e.bottomCenter.x,s=t.wrapper.bounds.bottomCenter.y-e.bottomCenter.y;break;case"Top":r=t.wrapper.bounds.topCenter.x-e.topCenter.x,s=t.wrapper.bounds.topCenter.y-e.topCenter.y;break;case"Left":r=t.wrapper.bounds.middleLeft.x-e.middleLeft.x,s=t.wrapper.bounds.middleLeft.y-e.middleLeft.y;break;case"Right":r=t.wrapper.bounds.middleRight.x-e.middleRight.x,s=t.wrapper.bounds.middleRight.y-e.middleRight.y}this.dragSourceEnd(l,r,s,!0,null,"ConnectorSourceEnd",void 0,void 0,void 0,!(t.parentId&&this.diagram.diagramActions&ee.isGroupDragging))}}},n.prototype.updateEndPoint=function(t,e){var r={sourcePoint:t.sourcePoint,targetPoint:t.targetPoint};t.sourceID&&(r.sourceID=t.sourceID),t.targetID&&(r.targetID=t.targetID),t.sourcePortID&&(r.sourcePortID=t.sourcePortID),t.targetPortID&&(r.targetPortID=t.targetPortID),t.segments&&(r.segments=t.segments),this.diagram.connectorPropertyChange(t,e||{},r),this.diagram.updateSelector()},n.prototype.dragSourceEnd=function(t,e,i,r,s,o,a,l,h,c,d){var u=this.diagram.nameTable[t.id],p={},f=this.checkBoundaryConstraints(e,i,u.wrapper.bounds);if(LI(u)&&f&&"BezierSourceThumb"!==o&&Vv(this.diagram)&&(p=$(p={sourcePoint:u.sourcePoint}),u.sourcePoint.x+=e,u.sourcePoint.y+=i,"ConnectorSourceEnd"===o&&"Orthogonal"===u.type&&this.changeSegmentLength(u,l,h,c),"Bpmn"===u.shape.type&&"Default"===u.shape.sequence&&"Sequence"===u.shape.flow&&this.updatePathElementOffset(u)),"Bezier"===u.type)if(p={sourcePoint:u.sourcePoint},d)this.translateBezierPoints(t,""===o?"ConnectorSourceEnd":o,e,i,d,s,!a);else for(var g=0;g2){var d=z.direction((c=t.segments[2]).points[0],c.points[1]);o.direction===ls(d)?("Right"===o.direction?c.points[0].x=o.points[o.points.length-1].x=l.wrapper.corners.middleRight.x+20:"Left"===o.direction?c.points[0].x=o.points[o.points.length-1].x=l.wrapper.corners.middleLeft.x-20:c.points[0].y=o.points[o.points.length-1].y="Top"===o.direction?l.wrapper.corners.topCenter.y-20:l.wrapper.corners.bottomCenter.y+20,c.direction&&c.length&&(c.length=z.distancePoints(c.points[0],c.points[c.points.length-1])),o.length=z.distancePoints(o.points[0],o.points[o.points.length-1])):o.direction===d&&c.direction&&c.length?("Top"===o.direction||"Bottom"===o.direction?(c.points[0]=o.points[0],c.points[c.points.length-1].x=c.points[0].x):(c.points[0]=o.points[0],c.points[c.points.length-1].y=c.points[0].y),c.length=z.distancePoints(c.points[0],c.points[c.points.length-1]),t.segments.splice(0,2)):o.length=20}else o.length=20;else if(o.length<1)if(""!==t.sourceID){var c;"Right"===a.direction?a.points[a.points.length-1].y=(h=l.wrapper.corners.middleRight).y:"Left"===a.direction?a.points[a.points.length-1].y=(h=l.wrapper.corners.middleLeft).y:a.points[a.points.length-1].x="Top"===a.direction?(h=l.wrapper.corners.topCenter).x:(h=l.wrapper.corners.bottomCenter).x,a.length=z.distancePoints(h,a.points[a.points.length-1]),t.segments.length>2&&(c=t.segments[2]).direction&&c.length&&(c.length=z.distancePoints(a.points[a.points.length-1],c.points[c.points.length-1])),t.segments.splice(0,1)}else t.segments.splice(0,1)}else e&&!i&&t.sourceID!==e.id&&t.segments&&null!==t.segments[0].direction&&e&&e instanceof te&&s&&this.changeSourceEndToNode(t,e),e&&i&&t.sourcePortID!==i&&t.segments&&null!==t.segments[0].direction&&e&&e instanceof te&&s&&this.changeSourceEndToPort(t,e,i)},n.prototype.canConnect=function(t,e){return!(!da(e)||!Nh(e))},n.prototype.changeSourceEndToPort=function(t,e,i){var r=this.diagram.getWrapper(e.wrapper,i),s={x:r.offsetX,y:r.offsetY},o=zo(s,En(e.wrapper),e.wrapper.bounds),a=t.segments[0],l=t.segments[1];if(a.direction!==o){var h=[],c={};if(a.direction===ls(o)){c={};var d=void 0;"Top"===o||"Bottom"===o?(d="Top"===o?{type:"Orthogonal",isTerminal:!0,direction:o,length:Math.abs(a.points[0].y-s.y)}:{type:"Orthogonal",isTerminal:!0,direction:o,length:Math.abs(s.y-a.points[0].y)},c=a.points[0].x>s.x?{type:"Orthogonal",isTerminal:!0,direction:"Right",length:a.points[0].x-s.x}:{type:"Orthogonal",isTerminal:!0,direction:"Left",length:s.x-a.points[0].x}):(d="Right"===o?{type:"Orthogonal",isTerminal:!0,direction:o,length:Math.abs(a.points[0].x-s.x)}:{type:"Orthogonal",isTerminal:!0,direction:o,length:Math.abs(s.x-a.points[0].x)},c=a.points[0].y>s.y?{type:"Orthogonal",direction:"Top",isTerminal:!0,length:a.points[0].y-s.y}:{type:"Orthogonal",direction:"Bottom",isTerminal:!0,length:s.y-a.points[0].y}),h.push(new bi(t,"segments",d,!0)),h.push(new bi(t,"segments",c,!0))}else h.push(new bi(t,"segments",c={type:"Orthogonal",direction:o,length:20,isTerminal:!0},!0));a.direction!==ls(o)&&("Top"===o||"Bottom"===o?(a.points[0].x=s.x,a.points[0].y=a.points[a.points.length-1].y="Top"===o?s.y-20:s.y+20):(a.points[0].y=s.y,a.points[0].x=a.points[a.points.length-1].x="Right"===o?s.x+20:s.x-20),a.length=z.distancePoints(a.points[0],a.points[a.points.length-1]),l.length=z.distancePoints(a.points[a.points.length-1],l.points[l.points.length-1])),t.segments=h.concat(t.segments)}else a.points[0]=s,"Top"===o||"Bottom"===o?a.points[a.points.length-1].x=s.x:a.points[a.points.length-1].y=s.y,a.length=z.distancePoints(a.points[0],a.points[a.points.length-1]),l.length=z.distancePoints(a.points[a.points.length-1],l.points[l.points.length-1])},n.prototype.removeTerminalSegment=function(t,e){for(var i=0;ii.width||"Left"===o.direction&&r.x>=o.points[0].x||"Right"===o.direction&&r.x<=o.points[0].x)o.points[0].y=o.points[o.points.length-1].y=r.y,o.points[0].x=r.x,o.length=z.distancePoints(o.points[0],o.points[o.points.length-1]),a.length=z.distancePoints(o.points[o.points.length-1],a.points[a.points.length-1]);else{var h=void 0;s="Bottom"===(h=a.direction?a.direction:z.direction(a.points[0],a.points[a.points.length-1]))?i.bottomCenter:i.topCenter,a.length&&a.direction&&(a.length="Top"===h?o.points[o.points.length-1].y-(s.y+20):s.y+20-o.points[o.points.length-1].y),o.length=o.points[o.points.length-1].x-s.x,o.direction=o.length>0?"Right":"Left",l.push(new bi(t,"segments",{type:"Orthogonal",direction:h,length:20},!0)),t.segments=l.concat(t.segments)}else r="Bottom"===o.direction?i.bottomCenter:i.topCenter,o.length>i.height||"Top"===o.direction&&r.y>=o.points[0].y||"Bottom"===o.direction&&r.y<=o.points[0].y?(o.points[0].x=o.points[o.points.length-1].x=r.x,o.points[0].y=r.y,o.length=z.distancePoints(o.points[0],o.points[o.points.length-1]),a.length=z.distancePoints(o.points[o.points.length-1],a.points[a.points.length-1])):(s="Left"===a.direction?i.middleLeft:i.middleRight,h=void 0,h=a.direction?a.direction:z.direction(a.points[0],a.points[a.points.length-1]),a.length&&a.direction&&(a.length="Left"===h?o.points[o.points.length-1].x-(s.x+20):s.x+20-o.points[o.points.length-1].x),o.length=o.points[o.points.length-1].y-s.y,o.direction=o.length>0?"Bottom":"Top",l.push(new bi(t,"segments",{type:"Orthogonal",direction:h,length:20},!0)),t.segments=l.concat(t.segments))},n.prototype.translateBezierPoints=function(t,e,i,r,s,o,a){var l=t.segments.indexOf(s),h=t.segments[parseInt(l.toString(),10)],c=l>0?t.segments[l-1]:null,d=null!==c?c.point:t.sourcePoint,u=l===t.segments.length-1?t.targetPoint:h.point;if(h)if("BezierSourceThumb"===e&&(h.vector1.angle||h.vector1.distance)){var p=h.vector1.distance,f=h.vector1.angle;h.vector1={distance:t.distance(d,o),angle:z.findAngle(d,o)},this.translateSubsequentSegment(t,s,!0,h.vector1.distance-p,h.vector1.angle-f)}else"BezierTargetThumb"===e&&(h.vector2.angle||h.vector2.distance)?(p=h.vector2.distance,f=h.vector2.angle,h.vector2={distance:t.distance(u,o),angle:z.findAngle(u,o)},this.translateSubsequentSegment(t,s,!1,h.vector2.distance-p,h.vector2.angle-f)):("ConnectorSourceEnd"===e&&!t.sourceID||"ConnectorTargetEnd"===e&&!t.targetID)&&a&&qI(h.vector1)&&qI(h.vector2)?(z.isEmptyPoint(h.point1)&&(h.bezierPoint1=$I(t.sourcePoint,t.targetPoint)),z.isEmptyPoint(h.point2)&&(h.bezierPoint2=$I(t.targetPoint,t.sourcePoint))):"BezierSourceThumb"===e||"ConnectorSourceEnd"===e&&!a&&qI(h.vector1)?(h.bezierPoint1.x+=i,h.bezierPoint1.y+=r,(!z.isEmptyPoint(h.point1)||a)&&(h.point1={x:h.bezierPoint1.x,y:h.bezierPoint1.y})):("BezierTargetThumb"===e||"ConnectorTargetEnd"===e&&!a&&qI(h.vector2))&&(h.bezierPoint2.x+=i,h.bezierPoint2.y+=r,(!z.isEmptyPoint(h.point2)||a)&&(h.point2={x:h.bezierPoint2.x,y:h.bezierPoint2.y}))},n.prototype.translateSubsequentSegment=function(t,e,i,r,s){var o=t.segments.indexOf(e);parseInt(o.toString(),10),t.bezierSettings.smoothness&II.SymmetricAngle||(s=null),t.bezierSettings.smoothness&II.SymmetricDistance||(r=null),(null!=r||null!=s)&&(i?0!==o&&this.updatePreviousBezierSegment(t,o,r,s):o!==t.segments.length-1&&this.updateNextBezierSegment(t,o,r,s))},n.prototype.updatePreviousBezierSegment=function(t,e,i,r){var s=t.segments[e-1],a=(s.vector2.angle+r)%360;a<0&&(a+=360),s.vector2={distance:s.vector2.distance+i,angle:a}},n.prototype.updateNextBezierSegment=function(t,e,i,r){var s=t.segments[e+1],a=(s.vector1.angle+r)%360;a<0&&(a+=360),s.vector1={distance:s.vector1.distance+i,angle:a}},n.prototype.dragTargetEnd=function(t,e,i,r,s,o,a,l){var c,h=this.diagram.nameTable[t.id],d=this.checkBoundaryConstraints(e,i,h.wrapper.bounds);if(NI(h)&&"BezierTargetThumb"!==o&&d&&Vv(this.diagram)){if(c=$(c={targetPoint:h.targetPoint}),h.targetPoint.x+=e,h.targetPoint.y+=i,"ConnectorTargetEnd"===o&&"Orthogonal"===h.type&&h.segments&&h.segments.length>0){var u=h.segments[h.segments.length-2];u&&2===h.segments[h.segments.length-1].points.length&&("Left"===u.direction||"Right"===u.direction?u.points[u.points.length-1].x=h.targetPoint.x:u.points[u.points.length-1].y=h.targetPoint.y,u.length=z.distancePoints(u.points[0],u.points[u.points.length-1]),u.direction=z.direction(u.points[0],u.points[u.points.length-1]))}"Bpmn"===h.shape.type&&"Default"===h.shape.sequence&&"Sequence"===h.shape.flow&&this.updatePathElementOffset(h)}if("Bezier"===h.type)if(c={targetPoint:h.targetPoint},l)this.translateBezierPoints(t,""===o?"ConnectorTargetEnd":o,e,i,l,s,!a);else for(var p=0;p0){if(void 0!==s&&o.segments[parseInt(s.toString(),10)])if("Bezier"===o.type){var a=o.segments[parseInt(s.toString(),10)],l=a.isInternalSegment;l&&null!==o.bezierSettings&&"FreeForm"!==o.bezierSettings.segmentEditOrientation?("Horizontal"===a.orientation?a.point.x+=e:a.point.y+=i,this.updateDirectionalBezierCurve(o)):(a.point.x+=e,a.point.y+=i),l&&(o.isBezierEditing=!0)}else o.segments[parseInt(s.toString(),10)].point.x+=e,o.segments[parseInt(s.toString(),10)].point.y+=i;else for(var h=0;h1){var a=e[1],l=e[2],h={x:.5*(a.x+l.x),y:.5*(a.y+l.y)},c=t.segments[0];c.vector1.angle=Xt(s,a),c.vector1.distance=.5*z.findLength(s,a),c.vector2.angle=Xt(h,a),c.vector2.distance=.5*z.findLength(h,a),c.point=h;var d=t.segments[1];if(d.vector1.angle=Xt(h,l),d.vector1.distance=.5*z.findLength(h,l),t.segments.length>2){var u=e[3],p={x:.5*(l.x+u.x),y:.5*(l.y+u.y)};d.vector2.angle=Xt(p,l),d.vector2.distance=.5*z.findLength(p,l),d.point=p;var f=t.segments[2];if(f.vector1.angle=Xt(p,u),f.vector1.distance=.5*z.findLength(p,u),t.segments.length>3){var g=e[4],v={x:.5*(u.x+g.x),y:.5*(u.y+g.y)};f.vector2.angle=Xt(v,u),f.vector2.distance=.5*z.findLength(v,u),f.point=v;var y=t.segments[3];y.vector1.angle=Xt(v,g),y.vector1.distance=.5*z.findLength(v,g),y.vector2.angle=Xt(o,g),y.vector2.distance=.5*z.findLength(o,g)}else f.vector2.angle=Xt(o,u),f.vector2.distance=.5*z.findLength(o,u)}else d.vector2.angle=Xt(o,l),d.vector2.distance=.5*z.findLength(o,l)}},n.prototype.rotateObjects=function(t,e,i,r,s){r=r||{};var o=Hi();qi(o,i,r.x,r.y);for(var l=0,h=e;l0){this.diagram.protectPropertyChange(!0);var o=t;o.segments=[],this.diagram.connectorPropertyChange(o,{},{segments:o.segments}),this.diagram.protectPropertyChange(!1)}}},n.prototype.updateInnerParentProperties=function(t){var r=this.diagram.isProtectedOnChange;this.diagram.protectPropertyChange(!0);for(var s=this.getAllDescendants(t,[],!1,!0),o=0;o0&&(p=this.diagram.bpmnModule.getChildrenBound(d,d.id,this.diagram),u=d.wrapper.bounds.containsRect(p)),h=d.wrapper.actualSize.width*t,c=d.wrapper.actualSize.height*e,void 0!==d.maxWidth&&0!==d.maxWidth&&(h=Math.min(d.maxWidth,h)),void 0!==d.minWidth&&0!==d.minWidth&&(h=Math.max(d.minWidth,h)),void 0!==d.maxHeight&&0!==d.maxHeight&&(c=Math.min(d.maxHeight,c)),void 0!==d.minHeight&&0!==d.minHeight&&(c=Math.max(d.minHeight,c)),u&&(h=Math.max(h,p.right-d.wrapper.bounds.x),c=Math.max(c,p.bottom-d.wrapper.bounds.y)),t=h/d.actualSize.width,e=c/d.actualSize.height}var f=Hi();o||(o=r);var g=o.wrapper;if(qi(f,-g.rotateAngle,i.x,i.y),Qp(f,t,e,i.x,i.y),qi(f,g.rotateAngle,i.x,i.y),r instanceof te){var d,v=Je(f,{x:(d=r).wrapper.offsetX,y:d.wrapper.offsetY}),y=d.wrapper.offsetX-d.wrapper.actualSize.width*d.pivot.x,S=d.wrapper.offsetY-d.wrapper.actualSize.height*d.pivot.y;if(h>0)if(d.processId){var b=this.diagram.nameTable[d.processId];(!b.maxWidth||d.margin.left+h0)if(d.processId){var M=this.diagram.nameTable[d.processId];(!M.maxHeight||d.margin.top+c0){if(e.dragLimit=e.dragLimit?e.dragLimit:{},e.dragLimit.top||e.dragLimit.bottom||e.dragLimit.left||e.dragLimit.right){var b={minDistance:null};S=this.getRelativeOffset(v,d,b);var M={minDistance:null};g=this.getRelativeOffset(v,y,M),S=null!=b&&M.minDistance0){if(S=y[y.length-1]){var b=void 0;for(b=0;b=e.x-t.dragLimit.left-r.width/2&&i.x<=e.x+t.dragLimit.right+r.width/2&&(s=!0),i.y>=e.y-t.dragLimit.top-r.height/2&&i.y<=e.y+t.dragLimit.bottom+r.height/2&&(o=!0),{x:s,y:o}},n.prototype.updateLabelMargin=function(t,e,i,r,s,o,a){if(i=i||{x:e.offset,y:0},e&&i&&i.x>0&&i.x<1){var l=z.getLengthFromListOfPoints(t.intermediatePoints),h=this.getPointAtLength(l*i.x,t.intermediatePoints,0),c=this.diagram.scrollSettings.currentZoom,d=e.dragLimit?e.dragLimit:{left:0,right:0,top:0,bottom:0};if(d.top||d.bottom||d.left||d.right){this.diagram.getWrapper(t.wrapper,e.id);var p=new Ne(0,0,0,0),f=this.diagram.getWrapper(t.wrapper,e.id);p.x=f.offsetX/c+o,p.y=f.offsetY/c+a,p.width=f.bounds.width/c,p.height=f.bounds.height/c;var g=new Ne(h.x-(d.left||0)-p.width/2,h.y-(d.top||0)-p.height/2,(d.left||0)+(d.right||0)+p.width,(d.top||0)+(d.bottom||0)+p.height);if(g.containsPoint(r));else for(var S=0,b=this.boundsInterSects([h,r],g,!1);S=t){c=t-r,d=z.findAngle(s,a),u=c*Math.cos(d*Math.PI/180),p=c*Math.sin(d*Math.PI/180),o={x:s.x+u,y:s.y+p};break}r+=h,s=a}else s=a;return o},n.prototype.getInterceptWithSegment=function(t,e){for(var o,a,i=[],r=[],s=[],l=z.findLength({x:0,y:0},{x:this.diagram.scroller.viewPortWidth,y:this.diagram.scroller.viewPortHeight}),h=1;h0&&a<=90||a>180&&a<=270?90:-90;r.push(z.transform(t,a+c,l)),r.push(z.transform(t,o+c,l));var p=em({x1:s[0].x,y1:s[0].y,x2:s[1].x,y2:s[1].y},{x1:r[0].x,y1:r[0].y,x2:r[1].x,y2:r[1].y});p.enabled&&i.push(p.intersectPt)}return i},n.prototype.getAnnotationChanges=function(t,e){var r={};return r[nb(t,e.id,!0)]={width:e.width,height:e.height,offset:t instanceof te?{x:e.offset.x,y:e.offset.y}:e.offset,rotateAngle:e.rotateAngle,margin:{left:e.margin.left,right:e.margin.right,top:e.margin.top,bottom:e.margin.bottom},horizontalAlignment:e.horizontalAlignment,verticalAlignment:e.verticalAlignment,alignment:t instanceof de?e.alignment:void 0},{annotations:r}},n.prototype.getConnectorPortChanges=function(t,e){var i=function zse(n,t,e){for(var i=n.ports,r=0;r1&&(v.width=g,v.offset.x=1/S),f>1&&(v.height=f,v.offset.y=1/b)}}e instanceof Nr&&(e.alignment="Center"),l=this.getAnnotationChanges(t,e),t instanceof te?this.diagram.nodePropertyChange(t,a,l):this.diagram.connectorPropertyChange(t,a,l),this.diagram.updateDiagramObject(t)},n.prototype.getSubProcess=function(t){var i,e={nodes:[],connectors:[]};return t instanceof te?i=t.processId:t&&t.nodes&&t.nodes.length&&t.nodes[0].processId&&(i=t.nodes[0].processId),i&&e.nodes.push($(this.diagram.nameTable[i])),e},n.prototype.checkBoundaryConstraints=function(t,e,i,r){var s=this.diagram.pageSettings,o=this.diagram.pageSettings.boundaryConstraints,a=this.diagram.scroller;if("Page"===o||"Diagram"===o){var l=i?void 0:this.diagram.selectedItems.wrapper.bounds;return!!((i?i.right:l.right)+(t||0)<=("Page"===o?s.width:a.viewPortWidth)&&(i?i.left:l.left)+(t||0)>=0&&(i?i.bottom:l.bottom)+(e||0)<=("Page"===o?s.height:a.viewPortHeight)&&(i?i.top:l.top)+(e||0)>=0||"None"!==this.diagram.layout.type&&r)}return!0},n.prototype.dragSelectedObjects=function(t,e){var i=this,r=this.diagram.selectedItems;this.state&&!this.state.backup&&(this.state.backup={},this.state.backup.offsetX=r.offsetX,this.state.backup.offsetY=r.offsetY),r=WI(this.diagram,r)||r;var s=this.diagram.selectedItems.nodes.filter(function(c){return"SwimLane"===c.shape.type});if(s.length>0&&!this.diagram.currentSymbol&&this.diagram.selectedItems.nodes.length>1){var o=this.diagram.selectedItems.nodes.filter(function(c){return""===c.parentId||"SwimLane"!==i.diagram.nameTable[c.parentId].shape.type});if(o.length>0){for(var a=0;a0||l.length>1)&&(o=o.concat(l),this.diagram.selectedItems.nodes.splice(0,this.diagram.selectedItems.nodes.length),o.forEach(function(c){i.diagram.selectedItems.nodes.push(c)}),r=this.diagram.selectedItems,this.diagram.selectedObject.helperObject=void 0)}}if(this.checkBoundaryConstraints(t,e)){this.diagram.diagramActions=this.diagram.diagramActions|ee.PreventZIndexOnDragging|ee.DragUsingMouse;var h=this.diagram.selectedObject.actualObject;return(h&&h instanceof te&&h.isLane&&Yx(h,this.diagram)||!h||!h.isLane)&&this.diagram.drag(r,t,e),this.diagram.diagramActions=this.diagram.diagramActions&~(ee.PreventZIndexOnDragging|ee.DragUsingMouse),this.diagram.refreshCanvasLayers(),this.checkHtmlObjectDrag(r),!0}return!1},n.prototype.checkHtmlObjectDrag=function(t){var e=!1;this.diagram.views&&this.diagram.views.length>1&&(t instanceof oi?e=t.nodes.some(function(i){return i.shape&&"HTML"===i.shape.type}):t.shape&&"HTML"===t.shape.type&&(e=!0),e&&this.resetOverviewCanvas())},n.prototype.resetOverviewCanvas=function(){for(var t=0,e=this.diagram.views;t0&&(this.layoutAnimateModule.stopCurrentAnimation(this.objectStore[0],e,t),this.objectStore=[]),a=this.diagram.doLayout(),this.objectStore.push(a)),this.canUpdateTemplate=!1,this.diagram.blazorActions&=~on.expandNode,this.diagram.preventNodesUpdate=r,this.diagram.layoutAnimateModule&&this.diagram.organizationalChartModule&&!i)this.diagram.allowServerDataBinding=!1,this.layoutAnimateModule.expand(this.diagram.layout.enableAnimation,a,t,this.diagram);else{var l={element:$(t),state:!!t.isExpanded};this.triggerEvent(Ce.expandStateChange,l),this.diagram.lineRoutingModule&&this.diagram.constraints&rt.LineRouting&&"ComplexHierarchicalTree"!==this.diagram.layout.type&&this.diagram.resetSegments()}return this.diagram.layout.fixedNode=""===o?"":this.diagram.layout.fixedNode,a},n.prototype.getparentexpand=function(t,e,i,r){for(var s,o=0;o0&&(this.diagram.selectedItems.wrapper.rotateAngle=this.diagram.selectedItems.rotateAngle=s.rotateAngle),r instanceof te&&"SwimLane"!==r.shape.type&&!r.isLane&&!r.isPhase&&!r.isHeader)(r.offsetX!==r.wrapper.offsetX||r.offsetY!==r.wrapper.offsetY||r.width!==r.wrapper.width||r.height!==r.wrapper.height||r.rotateAngle!==r.wrapper.rotateAngle)&&(r.offsetX+=o,r.offsetY+=a,r.width+=l,r.height+=h,r.rotateAngle+=c,this.diagram.nodePropertyChange(r,{},{offsetX:r.offsetX,offsetY:r.offsetY,width:r.width,height:r.height,rotateAngle:r.rotateAngle})),e=this.diagram.spatialSearch.findObjects(r.wrapper.outerBounds);else if(r instanceof oi)for(var d=0;d30||g.wrapper.outerBounds.topCenter.y-f.wrapper.outerBounds.bottomCenter.y>30)&&this.diagram.lineRoutingModule.refreshConnectorSegments(this.diagram,p,!0)}}this.updateSelector(),this.diagram.protectPropertyChange(!1)}},n.prototype.drawSelectionRectangle=function(t,e,i,r){this.diagram.drawSelectionRectangle(t,e,i,r)},n.prototype.startGroupAction=function(){this.diagram.startGroupAction()},n.prototype.endGroupAction=function(){this.diagram.endGroupAction()},n.prototype.removeChildFromBPmn=function(t,e,i){var r=this.diagram.nameTable[t.id]||t.nodes[0];if(i&&r&&r.processId&&r.processId===i.wrapper.id){var s=$(r);s.processId=r.processId,this.diagram.startGroupAction();var o=this.diagram.nameTable[r.processId].shape.activity.subProcess.processes||[];o.splice(o.indexOf(r.id),1),this.diagram.bpmnModule.removeChildFromBPMN(this.diagram.nameTable[r.processId].wrapper,r.id,this.diagram),this.diagram.nameTable[r.id].processId="",r.offsetX=r.wrapper.offsetX,r.offsetY=r.wrapper.offsetY;var a=$(r);this.addHistoryEntry({type:"PositionChanged",redoObject:{nodes:[a]},undoObject:{nodes:[s]},category:"Internal"}),this.diagram.endGroupAction()}},n.prototype.isDroppable=function(t,e){var i=this.diagram.nameTable[t.id]||t.nodes[0];return i instanceof te&&(!ce()&&"TextAnnotation"===i.shape.shape||("Group"===e.shape.shape&&(e.shape.activity.subProcess.collapsed=!1),!(i&&"Bpmn"===i.shape.type&&(i.processId===e.id||i.id===e.processId||"Bpmn"===e.shape.type&&!(e instanceof de)&&e.shape.activity&&e.shape.activity.subProcess&&e.shape.activity.subProcess.collapsed))))},n.prototype.renderHighlighter=function(t,e,i){if(new Ne,t.target instanceof te||t.target instanceof de||e&&(t.source instanceof te||t.source instanceof de)){var a=this.findTarget(e?t.sourceWrapper:t.targetWrapper,e?t.source:t.target,i,!0),l=void 0;if(a instanceof Hd)for(var h=a.id,c=t.target,u=0,p=c.wrapper.children[0].children[0].children[2].children;u0){var r=0;t[0]=this.diagram.nameTable[t[0].id]||t[0];var s="Object"===i?yr(t[0].wrapper):this.diagram.selectedItems.wrapper.bounds,o={nodes:[],connectors:[]},a={nodes:[],connectors:[]};for(r="Object"===i?r+1:r;r0){var i=0,r=0,s=0,o=0,a=0,l=0,h=0,c=0,d={nodes:[],connectors:[]},u={nodes:[],connectors:[]};for(i=0;io.center.y&&(r=n[parseInt(e.toString(),10)],n[parseInt(e.toString(),10)]=n[parseInt(i.toString(),10)],n[parseInt(i.toString(),10)]=r):s.center.x>o.center.x&&(r=n[parseInt(e.toString(),10)],n[parseInt(e.toString(),10)]=n[parseInt(i.toString(),10)],n[parseInt(i.toString(),10)]=r)}}return n}(t,e),i=1;i0){var i=0,r={x:.5,y:.5};t[0]=this.diagram.nameTable[t[0].id]||t[0];var s=yr(t[0].wrapper),o={nodes:[],connectors:[]},a={nodes:[],connectors:[]};for(i=1;ii.zIndex){for(var s=this.diagram.layers.indexOf(this.diagram.getActiveLayer()),o=this.diagram.layers[parseInt(s.toString(),10)].zIndexTable,a=JSON.parse(JSON.stringify(o)),l=i.zIndex,h=r.zIndex,c=h;c>=l;c--)l!==c?o[c-1]?(o[parseInt(c.toString(),10)]=o[c-1],this.diagram.nameTable[o[parseInt(c.toString(),10)]].zIndex=c):(o[c-1]=o[parseInt(c.toString(),10)],this.diagram.nameTable[o[c-1]].zIndex=c,delete o[parseInt(c.toString(),10)]):this.swapZIndexObjects(h,o,r.id,a);"SVG"===this.diagram.mode?(this.moveSvgNode(e.parentId,i.id),this.updateNativeNodeIndex(e.parentId,i.id)):this.diagram.refreshCanvasLayers()}},n.prototype.findLeastIndexConnector=function(t,e,i){for(var r=0;rs.zIndex&&(i=s)}return i},n.prototype.findLeastIndexObject=function(t,e){var i=t;return t instanceof te&&(i=this.findLeastIndexConnector(t.inEdges,e,i),i=this.findLeastIndexConnector(t.outEdges,e,i)),i},n.prototype.checkSelection=function(t,e){var i;if(1===t.nodes.length&&0===t.connectors.length)if(cs(this.diagram,t.nodes[0],!0)){var r=t.nodes[0];if("SwimLane"===(i="SwimLane"===t.nodes[0].shape?t.nodes[0]:this.diagram.nameTable[t.nodes[0].parentId]).shape.type){var s="Horizontal"===i.shape.orientation;(r.isPhase&&(s&&"ResizeSouth"===e||!s&&"ResizeEast"===e)||r.isLane&&(s&&"ResizeEast"===e||!s&&"ResizeSouth"===e))&&B3(this.diagram,i,e)}else if("Grid"===i.container.type)if("Horizontal"===i.container.orientation&&1===r.rowIndex||"Vertical"===i.container.orientation&&r.rowIndex>0&&r.columnIndex>0){if("ResizeSouth"===e)for(var o=0;o1&&(this.diagram.realActions=this.diagram.realActions|$i.hScrollbarMoved,this.scrolled=!0),this.diagram.scrollSettings.horizontalOffset=t},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"verticalOffset",{get:function(){return this.vOffset},set:function(t){this.vOffset=t,Math.abs(this.vOffset-this.diagram.scrollSettings.verticalOffset)>1&&(this.diagram.realActions=this.diagram.realActions|$i.vScrollbarMoved,this.scrolled=!0),this.diagram.scrollSettings.verticalOffset=t},enumerable:!0,configurable:!0}),n.prototype.getBounds=function(){var e=this.diagram.spatialSearch.getPageBounds(0,0);return(e.x<0||e.y<0)&&!this.diagram.pageSettings.multiplePage?this.getPageBounds(void 0,void 0,!0,!0):this.getPageBounds(void 0,void 0,!0)},n.prototype.updateScrollOffsets=function(t,e){var i,r,s=this.getBounds();s.x*=this.currentZoom,s.y*=this.currentZoom,s.width*=this.currentZoom,s.height*=this.currentZoom,i=Math.max(0,t-s.left),r=Math.max(0,e-s.top),void 0!==t&&void 0!==e?(this.horizontalOffset=i,this.verticalOffset=r,this.diagram.setOffset(i,r)):this.diagram.setOffset(-this.horizontalOffset-s.x,-this.verticalOffset-s.y),this.transform={tx:Math.max(this.horizontalOffset,-s.left)/this.currentZoom,ty:Math.max(this.verticalOffset,-s.top)/this.currentZoom,scale:this.currentZoom}},n.prototype.setScrollOffset=function(t,e){this.scrolled=!1;var i=this.getBounds();i.x*=this.currentZoom,i.y*=this.currentZoom,i.width*=this.currentZoom,i.height*=this.currentZoom;var r=-i.left,s=-i.top,o=!1,a=this.viewPortWidth*this.currentZoom,l=this.viewPortHeight*this.currentZoom,h=r-t;if(h!==this.horizontalOffset){rh?this.horizontalOffset-=t:this.horizontalOffset=h,o=!0);var c=Math.max(i.right+this.vScrollSize,a);if(!o&&c<-h+this.viewPortWidth){var d=-h+a-this.vScrollSize,u=-this.horizontalOffset+a-this.vScrollSize;this.horizontalOffset=dd-u?h:-(i.right+this.vScrollSize-a),o=!0}o||(this.horizontalOffset=r-t)}o=!1;var p=s-e;if(p!==this.verticalOffset){sp?this.verticalOffset-=e:this.verticalOffset=p,o=!0);var f=Math.max(i.bottom+this.hScrollSize,l);if(!o&&f<-p+l){var g=-p+l-this.hScrollSize,v=-this.verticalOffset+l-this.hScrollSize;this.verticalOffset=gg-v?p:-(i.bottom+this.hScrollSize-l),o=!0}o||(this.verticalOffset=s-e)}this.transform={tx:Math.max(this.horizontalOffset,-i.left)/this.currentZoom,ty:Math.max(this.verticalOffset,-i.top)/this.currentZoom,scale:this.currentZoom},this.setSize()},n.prototype.getObjects=function(t,e){for(var i=[],r=0;r0){for(var l=0;l0){h.push(i[parseInt(o.toString(),10)].id);for(var d=0;d=e.bottom&&(l=0),-this.horizontalOffset<=e.x&&-this.horizontalOffset+this.viewPortWidth>=e.right&&(a=0),this.hScrollSize=a,this.vScrollSize=l;var h=this.diagramWidth,c=this.diagramHeight;this.diagramWidth=Math.max(e.right,-this.horizontalOffset+this.viewPortWidth-l)-i,this.diagramHeight=Math.max(e.bottom,-this.verticalOffset+this.viewPortHeight-a)-r,(h!==this.diagramWidth||c!==this.diagramHeight)&&"Diagram"!==this.diagram.scrollSettings.scrollLimit&&this.diagram.setSize(this.diagramWidth,this.diagramHeight),"Diagram"===this.diagram.scrollSettings.scrollLimit&&(h===this.diagramWidth&&c===this.diagramHeight&&1===this.currentZoom||this.diagram.diagramActions&&t&&(!this.diagram.diagramActions||!t||0===this.verticalOffset&&this.verticalOffset!==t.y||0===this.horizontalOffset&&this.horizontalOffset!==t.x)?t&&h===this.diagramWidth&&c===this.diagramHeight&&(this.diagram.diagramCanvas.scrollHeight>this.viewPortHeight&&t.y<0&&this.horizontalOffset===t.x&&0===this.verticalOffset||this.diagram.diagramCanvas.scrollWidth>this.viewPortWidth&&t.x<0&&this.verticalOffset===t.y&&0===this.horizontalOffset)&&(this.verticalOffset=t.y,this.horizontalOffset=t.x,this.transform={tx:Math.max(t.x,-e.left)/this.currentZoom,ty:Math.max(t.y,-e.top)/this.currentZoom,scale:this.currentZoom}):(this.diagram.scrollActions&ca.Interaction&&t&&(this.transform={tx:Math.max(t.x,-e.left/this.currentZoom)/this.currentZoom,ty:Math.max(t.y,-e.top/this.currentZoom)/this.currentZoom,scale:this.currentZoom},this.horizontalOffset=t.x,this.verticalOffset=t.y),this.diagram.setSize(this.diagramWidth,this.diagramHeight),!(this.diagram.scrollActions&ca.PropertyChange)&&t&&(this.horizontalOffset=t.x,this.verticalOffset=t.y,this.transform={tx:Math.max(t.x,-e.left)/this.currentZoom,ty:Math.max(t.y,-e.top)/this.currentZoom,scale:this.currentZoom}))),this.diagram.transformLayers(),this.diagram.element.style.overflow="hidden"},n.prototype.setViewPortSize=function(t,e){this.viewPortWidth=t,this.viewPortHeight=e},n.prototype.getPageBounds=function(t,e,i,r){var o,s=new Ne;if("Content"===e||r||null===this.diagram.pageSettings.width||null===this.diagram.pageSettings.height){var u=t?void 0:0;o=this.diagram.spatialSearch.getPageBounds(u,u)}else{var a=this.diagram.pageSettings.width,l=this.diagram.pageSettings.height,h=0,c=0;if(this.diagram.pageSettings.multiplePage){if((s=this.diagram.spatialSearch.getPageBounds(0,0)).right>a&&(a*=d=Math.ceil(s.right/a)),s.bottom>l&&(l*=d=Math.ceil(s.bottom/l)),s.left<0&&Math.abs(s.left)>h){var d=Math.ceil(Math.abs(s.left)/this.diagram.pageSettings.width);h=this.diagram.pageSettings.width*d}s.top<0&&Math.abs(s.top)>c&&(d=Math.ceil(Math.abs(s.top)/this.diagram.pageSettings.height),c=this.diagram.pageSettings.height*d)}o=new Ne(-h,-c,a+h,l+c)}if(i){var p=this.diagram.scrollSettings.padding;o.x-=p.left,o.y-=p.top,o.width+=p.left+p.right,o.height+=p.top+p.bottom}return o},n.prototype.getPageBreak=function(t){for(var e=0,i=0,r=-1,s=[],c=this.diagram.pageSettings.margin.left,d=this.diagram.pageSettings.margin.right,u=this.diagram.pageSettings.margin.top,p=this.diagram.pageSettings.margin.bottom,f=1,g=1;t.width>e;)(e+=this.diagram.pageSettings.width?this.diagram.pageSettings.width:t.width)===this.diagram.pageSettings.width&&(s[++r]={x1:t.left+c,y1:t.top+u,x2:t.left+c,y2:t.bottom-p}),ei;)(i+=this.diagram.pageSettings.height?this.diagram.pageSettings.height:t.height)===this.diagram.pageSettings.height&&(s[++r]={x1:t.left+c,y1:t.top+u,x2:t.right-d,y2:t.top+u}),i=this.diagram.scrollSettings.minZoom||l||t>=1)){this.currentZoom*=t;var c=this.getPageBounds(void 0,void 0,!0);c.x*=this.currentZoom,c.y*=this.currentZoom;var d=Hi();Qp(d,t,t,r.x,r.y),ZB(d,e||0,i||0),Ix(h,d);var u=Je(h,{x:0,y:0});if(1===t&&(u=this.applyScrollLimit(u.x,u.y,s,o,a)),a=-c.y>=u.y&&-c.x>=u.x&&a,(this.diagram.scrollActions&ca.PropertyChange||!(this.diagram.scrollActions&ca.Interaction)||"Diagram"!==this.diagram.scrollSettings.scrollLimit||a)&&(this.transform={tx:Math.max(u.x,-c.left)/this.currentZoom,ty:Math.max(u.y,-c.top)/this.currentZoom,scale:this.currentZoom},this.horizontalOffset=u.x,this.verticalOffset=u.y),this.setSize(u),"SVG"!==this.diagram.mode&&Ds(this.diagram)&&this.diagram.scroller.virtualizeElements(),"SVG"!==this.diagram.mode&&!Ds(this.diagram)&&this.diagram.refreshDiagramLayer(),this.diagram.setOffset(-this.horizontalOffset-c.x,-this.verticalOffset-c.y),ZI(this.diagram),this.diagram.views&&this.diagram.views.overview){var p=this.diagram.views.overview,f=p.scrollOverviewRect(p.parent.scroller.horizontalOffset,p.parent.scroller.verticalOffset,p.parent.scroller.currentZoom,!0);p.updateOverviewrect(-f.x,-f.y,f.width,f.height),p.updateView(p)}}}},n.prototype.fitToPage=function(t){var e=(t=t||{}).mode,i=t.region,r=t.margin||{},s=t.canZoomIn,o=t.customBounds,a=t.canZoomOut;r.bottom=r.bottom||25,r.top=r.top||25,r.left=r.left||25,r.right=r.right||25;var h,l=o,c=-this.horizontalOffset,d=-this.verticalOffset;if("PageSettings"===(i=i||"PageSettings")&&this.diagram.pageSettings.width&&this.diagram.pageSettings.height||this.diagram.nodes.length>0||this.diagram.connectors.length>0){e=e||"Page","CustomBounds"!==i&&(l=this.getPageBounds(!0,i,!0));var u={x:0,y:0};r.left+r.right>this.viewPortWidth&&(this.viewPortWidth<=100?(r.left=5,r.right=5):(r.left=25,r.right=25)),r.top+r.bottom>this.viewPortHeight&&(this.viewPortHeight<=100?(r.top=5,r.bottom=5):(r.top=25,r.bottom=25)),u.x=(this.viewPortWidth-(r.left+r.right))/l.width,u.y=(this.viewPortHeight-(r.top+r.bottom))/l.height,!s&&l.width-this.horizontalOffset-a+this.viewPortWidth&&(i=o.right-this.viewPortWidth,i+=20),o.x<-a&&(i=o.x),o.bottom>-l+this.viewPortHeight&&(r=o.bottom-this.viewPortHeight,r+=20),o.y<-l&&(r=o.y),this.zoom(1,-this.horizontalOffset-i,-this.verticalOffset-r,null,void 0,e))},n.prototype.bringToCenter=function(t){var e=this.currentZoom,i=new Ne(t.x*e,t.y*e,t.width*e,t.height*e),r=i.x+i.width/2-this.viewPortWidth/2,s=i.y+i.height/2-this.viewPortHeight/2;this.zoom(1,-this.horizontalOffset-(r*=-1),-this.verticalOffset-(s*=-1),null)},n.prototype.applyScrollLimit=function(t,e,i,r,s){if("Infinity"===this.diagram.scrollSettings.scrollLimit&&void 0===i&&!r&&(t=-t,e=-e),"Infinity"!==this.diagram.scrollSettings.scrollLimit){var o=void 0;if("Limited"===this.diagram.scrollSettings.scrollLimit){var a=this.diagram.scrollSettings.scrollableArea;o=new Ne(a.x,a.y,a.width,a.height)}(o=o||(s?this.getPageBounds():this.getPageBounds(!0))).x*=this.currentZoom,o.y*=this.currentZoom,o.width*=this.currentZoom,o.height*=this.currentZoom,void 0!==i&&(t*=-1,e*=-1),r&&(t*=-1,e*=-1);var l=Math.max(o.right,this.viewPortWidth);if(!r&&!(t<=o.x&&(t+this.viewPortWidth>=o.right||t>=o.right-this.viewPortWidth)||t>=o.x&&t+this.viewPortWidth<=l))if(t>=o.x)t=Math.max(o.x,Math.min(t,t-(t+this.viewPortWidth-this.vScrollSize-l)));else{var h=o.right-this.viewPortWidth;t=Math.min(h,o.x)}var c=Math.max(o.bottom,this.viewPortHeight);r||e<=o.y&&e+this.viewPortHeight>=o.bottom||e>=o.y&&e+this.viewPortHeight<=c||(e>=o.y?e=Math.max(o.y,Math.min(e,e-(e+this.viewPortHeight-this.hScrollSize-c))):(h=o.bottom-this.viewPortHeight,e=Math.min(o.y,h))),t*=-1,e*=-1}return{x:t,y:e}},n}(),Qoe=function(){function n(t,e,i,r,s){this.objects=[],this.left=t,this.top=e,this.width=i,this.height=r,this.spatialSearch=s}return n.prototype.findQuads=function(t,e){null!=this.first&&this.first.isIntersect(t)&&this.first.findQuads(t,e),null!=this.second&&this.second.isIntersect(t)&&this.second.findQuads(t,e),null!=this.third&&this.third.isIntersect(t)&&this.third.findQuads(t,e),null!=this.fourth&&this.fourth.isIntersect(t)&&this.fourth.findQuads(t,e),this.objects.length>0&&e.push(this)},n.prototype.isIntersect=function(t){return!(this.left+this.widtht.right||this.top>t.bottom)},n.prototype.selectQuad=function(){for(var i,t=null,e=this;null!=e;)i=e.getQuad(t),e=i.source,t=i.target||t;return t},n.prototype.getQuad=function(t){var e=this.width/2,i=this.height/2;if(e>=1e3&&i>=1e3){var r=this.left+e,s=this.top+i;if(this.spatialSearch.childRight<=r){if(this.spatialSearch.childBottom<=s)return this.first||((o=new n(this.left,this.top,e,i,this.spatialSearch)).parent=this,this.first=o),{source:this.first};if(this.spatialSearch.childTop>=s)return this.third||((o=new n(this.left,s,e,i,this.spatialSearch)).parent=this,this.third=o),{source:this.third}}else if(this.spatialSearch.childLeft>=r){if(this.spatialSearch.childBottom<=s)return this.second||((o=new n(r,this.top,e,i,this.spatialSearch)).parent=this,this.second=o),{source:this.second};var o;if(this.spatialSearch.childTop>=s)return this.fourth||((o=new n(r,s,e,i,this.spatialSearch)).parent=this,this.fourth=o),{source:this.fourth}}}return this.objects.push(this.spatialSearch.childNode),{target:this}},n.prototype.isContained=function(){return this.spatialSearch.childLeft>=this.left&&this.spatialSearch.childRight<=this.left+this.width&&this.spatialSearch.childTop>=this.top&&this.spatialSearch.childBottom<=this.top+this.height},n.prototype.addIntoAQuad=function(t){var e={};this.spatialSearch.setCurrentNode(t);for(var i=null;!e.isAdded;)i=(e=this.spatialSearch.parentQuad.add(i)).quad;return i},n.prototype.add=function(t){if(t=null,this.isContained())return{isAdded:!0,quad:t=this.selectQuad()};var e=void 0,i=!(0!==this.objects.length||this.first||this.second||this.third||this.fourth),r=2*this.width,s=2*this.height;return this.spatialSearch.childLeft=this.childLeft?(this.pageLeft=this.childLeft,this.leftElement=t,r=!0):t===this.leftElement&&(this.pageLeft=Number.MAX_VALUE,this.findLeft(this.parentQuad),r=!0)),(this.pageTop!==this.childTop||t!==this.topElement)&&(this.pageTop>=this.childTop?(this.pageTop=this.childTop,this.topElement=t,r=!0):t===this.topElement&&(this.pageTop=Number.MAX_VALUE,this.findTop(this.parentQuad),r=!0)),(this.pageBottom!==this.childBottom||t!==this.bottomElement)&&(this.pageBottom<=this.childBottom?(r=!0,this.pageBottom=this.childBottom,this.bottomElement=t):t===this.bottomElement&&(this.pageBottom=-Number.MAX_VALUE,this.findBottom(this.parentQuad),r=!0)),(this.pageRight!==this.childRight||t!==this.rightElement)&&(this.pageRight<=this.childRight?(this.pageRight=this.childRight,this.rightElement=t,r=!0):t===this.rightElement&&(this.pageRight=-Number.MAX_VALUE,this.findRight(this.parentQuad),r=!0)),r}return this.setCurrentNode(null),!1},n.prototype.isWithinPageBounds=function(t){return t.left>=this.pageLeft&&t.right<=this.pageRight&&t.top>=this.pageTop&&t.bottom<=this.pageBottom},n.prototype.findQuads=function(t){var e=[];return this.parentQuad.findQuads(t,e),e},n.prototype.findObjects=function(t){for(var i=[],r=0,s=this.findQuads(t);r=r.outerBounds.left&&(this.pageLeft=r.outerBounds.left,this.leftElement=r)}},n.prototype.findTop=function(t){t.first||t.second?(t.first&&this.findTop(t.first),t.second&&this.findTop(t.second)):(t.third&&this.findTop(t.third),t.fourth&&this.findTop(t.fourth));for(var e=0,i=t.objects;e=r.outerBounds.top&&(this.pageTop=r.outerBounds.top,this.topElement=r)}},n.prototype.setCurrentNode=function(t){if(this.childNode=t,t){var e=t.outerBounds;this.childLeft=Number(e.left),this.childTop=Number(e.top),this.childRight=Number(e.right),this.childBottom=Number(e.bottom)}else this.childLeft=Number.MAX_VALUE,this.childTop=Number.MAX_VALUE,this.childRight=-Number.MAX_VALUE,this.childBottom=-Number.MAX_VALUE},n.prototype.getPageBounds=function(t,e){if(this.pageLeft===Number.MAX_VALUE)return new Ne(0,0,0,0);var i=void 0!==t?Math.min(this.pageLeft,0):this.pageLeft,r=void 0!==e?Math.min(this.pageTop,0):this.pageTop;return new Ne(Math.round(i),Math.round(r),Math.round(this.pageRight-i),Math.round(this.pageBottom-r))},n.prototype.getQuad=function(t){return this.quadTable[t.id]},n}(),Goe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),qoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Goe(t,n),function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);r>3&&s&&Object.defineProperty(t,e,s)}([I(!1)],t.prototype,"preventDefaults",void 0),t}(Ee),$oe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),e_=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Zoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return $oe(t,n),e_([I("")],t.prototype,"action",void 0),e_([I("")],t.prototype,"cursor",void 0),t}(Ee),t_=function(){function n(){this.size=20,this.intermediatePoints=[],this.gridCollection=[],this.startArray=[],this.targetGridCollection=[],this.sourceGridCollection=[],this.considerWalkable=[]}return n.prototype.lineRouting=function(t){var e=t.connectors.length;if(this.renderVirtualRegion(t),e>0)for(var i=0;i=t.right||e.right<=t.left||e.top>=t.bottom||e.bottom<=t.top)},n.prototype.findEndPoint=function(t,e,i){var r,s;if(e&&""!==t.sourcePortID&&t.sourcePortWrapper||!e&&""!==t.targetPortID&&t.targetPortWrapper){s=zo(r=e?{x:t.sourcePortWrapper.offsetX,y:t.sourcePortWrapper.offsetY}:{x:t.targetPortWrapper.offsetX,y:t.targetPortWrapper.offsetY},void 0,e?t.sourceWrapper.bounds:t.targetWrapper.bounds);var o=e?t.sourcePortWrapper.bounds:t.targetPortWrapper.bounds;r=i?"Top"===s?{x:o.topCenter.x,y:o.topCenter.y}:"Left"===s?{x:o.middleLeft.x,y:o.middleLeft.y}:"Right"===s?{x:o.middleRight.x,y:o.middleRight.y}:{x:o.bottomCenter.x,y:o.bottomCenter.y}:{x:o.center.x,y:o.center.y}}else r=e&&this.startNode||!e&&this.targetNode?e?{x:this.startNode.wrapper.offsetX,y:this.startNode.wrapper.offsetY}:{x:this.targetNode.wrapper.offsetX,y:this.targetNode.wrapper.offsetY}:e?{x:t.sourcePoint.x,y:t.sourcePoint.y}:{x:t.targetPoint.x,y:t.targetPoint.y};return r},n.prototype.refreshConnectorSegments=function(t,e,i,r){var h,c,p,f,g,y,S,b,M,w,C,s=e.sourceID,o=e.targetID,a=e.sourcePortID,l=e.targetPortID;if(function Vre(n,t){var e=0;return n.constraints&qe.LineRouting?e=n.constraints&qe.LineRouting:n.constraints&qe.InheritLineRouting&&(e=t.constraints&rt.LineRouting),e}(e,t)||r){this.startNode=t.nameTable[""+s],this.targetNode=t.nameTable[""+o],this.intermediatePoints=[],this.startArray=[],this.targetGridCollection=[],this.sourceGridCollection=[],this.startGrid=void 0,this.targetGrid=void 0;for(var D=0;D0;){var L=this.startArray.pop();if(L){for(D=0;D1&&(e.segments=[]),this.updateConnectorSegments(t,this.intermediatePoints,this.gridCollection,e,i)){this.considerWalkable=[];break e}this.targetGridCollection.splice(this.targetGridCollection.indexOf(O),1),L=this.startArray.pop()}}L&&this.findPath(L)}}}},n.prototype.checkChildNodes=function(t,e){var i=!1,r=!1;if(t.nodeId.length>=1&&!e)for(var s=0;s1&&this.targetGridCollection[0].nodeId.length>1)for(var c=0;c<=1;c++){for(var d=this.targetGridCollection[parseInt(c.toString(),10)].gridX,u=this.targetGridCollection[parseInt(c.toString(),10)].gridY,p=this.targetGridCollection[parseInt(c.toString(),10)].nodeId,f=void 0,g=0;g=e.right&&t.top<=e.top&&t.bottom>=e.bottom},n.prototype.getEndvalue=function(t,e){return this.gridCollection[t.gridX][t.gridY].walkable?t:"left"===e?this.getEndvalue(this.gridCollection[t.gridX-1][t.gridY],e):"right"===e?this.getEndvalue(this.gridCollection[t.gridX+1][t.gridY],e):"top"===e?this.getEndvalue(this.gridCollection[t.gridX][t.gridY-1],e):"bottom"===e?this.getEndvalue(this.gridCollection[t.gridX][t.gridY+1],e):t},n.prototype.changeValue=function(t,e,i){t.walkable||this.considerWalkable.push(t);for(var r,s=0;s<=e;s++)"left"===i?r=this.gridCollection[t.gridX-s][t.gridY]:"right"===i?r=this.gridCollection[t.gridX+s][t.gridY]:"top"===i?r=this.gridCollection[t.gridX][t.gridY-s]:"bottom"===i&&(r=this.gridCollection[t.gridX][t.gridY+s]),r.walkable||this.considerWalkable.push(r)},n.prototype.getIntermediatePoints=function(t){var e;for(this.intermediatePoints=[];t;)this.intermediatePoints.push({x:t.gridX,y:t.gridY}),t=t.parent;this.intermediatePoints.reverse(),this.intermediatePoints.length>=1&&void 0!==this.intermediatePoints[0]&&void 0!==this.intermediatePoints[1]&&(this.intermediatePoints[0].x===this.intermediatePoints[1].x?this.intermediatePoints[0].y=1&&u.length>1&&(g=u[u.length-2].x!==u[u.length-1].x?u[u.length-2].x>u[u.length-1].x?"Left":"Right":u[u.length-2].y>u[u.length-1].y?"Top":"Bottom"),M>=2&&v===g&&u.length>1&&u.splice(u.length-2,1),v=g);if(u&&u.length>1){for(var w=0;wD.x?S.bounds.middleLeft:S.bounds.middleRight),w===u.length-2&&""===r.targetPortID&&y&&(l=C.x>D.x?y.bounds.middleRight:y.bounds.middleLeft),0===w&&b&&(C.x=b.x,C.y=D.y=b.y),w===u.length-2&&l&&(w>0&&r.targetDecorator&&l.x-D.x<0&&Math.abs(l.x-C.x)0&&r.targetDecorator&&l.x-D.x>0&&Math.abs(l.x-C.x)D.y?S.bounds.topCenter:S.bounds.bottomCenter),w===u.length-2&&""===r.targetPortID&&y&&(l=C.y>D.y?y.bounds.bottomCenter:y.bounds.topCenter),0===w&&b&&(C.y=b.y,C.x=D.x=b.x),w===u.length-2&&l&&(w>0&&r.targetDecorator&&l.y-D.y<0&&Math.abs(l.y-C.y)0&&r.targetDecorator&&l.y-D.y>0&&Math.abs(l.y-C.y)D.x?(p="Left",f=C.x-D.x):(p="Right",f=D.x-C.x):C.y>D.y?(p="Top",f=C.y-D.y):(p="Bottom",f=D.y-C.y),o.push({type:"Orthogonal",length:f,direction:p})}}if(o&&o.length>0){var A=o[o.length-1];if(1===o.length&&(A.length-=20),A.length<10&&2===o.length&&(o.pop(),o.length>0&&(o[0].length-=20,A=o[0])),r.targetDecorator&&("Top"===A.direction||"Bottom"===A.direction)&&A.length>r.targetDecorator.height+1||("Right"===A.direction||"Left"===A.direction)&&A.length>r.targetDecorator.width+1)return r.segments=o,s&&t.connectorPropertyChange(r,{},{type:"Orthogonal",segments:o}),!0}return!1},n.prototype.findPath=function(t){for(var e,i=[],r=this.findNearestNeigbours(t,this.gridCollection,!0),s=0;sl)&&(e.x!==t.gridX||e.y!==t.gridY)&&(i.push(e),o.previousDistance=l,o.afterDistance=o.afterDistance||this.manhattan(Math.abs(e.x-this.targetGrid.gridX),Math.abs(e.y-this.targetGrid.gridY)),o.totalDistance=o.previousDistance+o.afterDistance,o.parent=t)}if(i.length>0)for(s=0;st?i*t+e:i*e+t},n.prototype.manhattan=function(t,e){return t+e},n.prototype.findNearestNeigbours=function(t,e,i){var r=[],s=t.parent;if(s){var o=(t.gridX-s.gridX)/Math.max(Math.abs(t.gridX-s.gridX),1),a=(t.gridY-s.gridY)/Math.max(Math.abs(t.gridY-s.gridY),1);0!==o?(this.isWalkable(t.gridX,t.gridY-1,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX][t.gridY-1])&&r.push(e[t.gridX][t.gridY-1]),this.isWalkable(t.gridX,t.gridY+1,!0)&&this.sourceGridCollection.indexOf(e[t.gridX][t.gridY+1])&&r.push(e[t.gridX][t.gridY+1]),this.isWalkable(t.gridX+o,t.gridY,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX+o][t.gridY])&&r.push(e[t.gridX+o][t.gridY])):0!==a&&(this.isWalkable(t.gridX-1,t.gridY,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX-1][t.gridY])&&r.push(e[t.gridX-1][t.gridY]),this.isWalkable(t.gridX+1,t.gridY,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX+1][t.gridY])&&r.push(e[t.gridX+1][t.gridY]),this.isWalkable(t.gridX,t.gridY+a,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX][t.gridY+a])&&r.push(e[t.gridX][t.gridY+a]))}else this.neigbour(t,"top",r,i),this.neigbour(t,"right",r,i),this.neigbour(t,"bottom",r,i),this.neigbour(t,"left",r,i);return r},n.prototype.neigbour=function(t,e,i,r){for(var o,s=1;s>0;){var a="top"===e||"bottom"===e?t.gridX:"left"===e?t.gridX-s:t.gridX+s,l="right"===e||"left"===e?t.gridY:"top"===e?t.gridY-s:t.gridY+s;if((o=this.gridCollection[parseInt(a.toString(),10)][parseInt(l.toString(),10)])&&(r&&-1===this.sourceGridCollection.indexOf(o)||!r&&-1===this.targetGridCollection.indexOf(o)))return i&&this.isWalkable(a,l)&&i.push(o),s;if(!(a>0&&l>0))break;s++}return null},n.prototype.resetGridColl=function(t,e,i){for(var s,r=1;r>0;){var o="top"===e||"bottom"===e?t.gridX:"left"===e?t.gridX-r:t.gridX+r,a="right"===e||"left"===e?t.gridY:"top"===e?t.gridY-r:t.gridY+r;if((s=this.gridCollection[parseInt(o.toString(),10)][parseInt(a.toString(),10)])&&(i&&-1===this.sourceGridCollection.indexOf(s)||!i&&-1===this.targetGridCollection.indexOf(s))){if(this.isWalkable(o,a))break;var l=this.gridCollection[parseInt(o.toString(),10)][parseInt(a.toString(),10)];this.considerWalkable.push(l)}if(!(o>0&&a>0))break;"top"===e||"left"===e?r--:r++}return null},n.prototype.isWalkable=function(t,e,i){if(t>=0&&t=0&&e0?1:-1,this.isWalkable(h,c-1)&&!this.isWalkable(h-a,c-1)||this.isWalkable(h,c+1)&&!this.isWalkable(h-a,c+1)))return{x:t,y:e};if(0!==l){if(l=l>0?1:-1,this.isWalkable(h-1,c)&&!this.isWalkable(h-1,c-l)||this.isWalkable(h+1,c)&&!this.isWalkable(h+1,c-l))return{x:t,y:e};if(this.findIntermediatePoints(h+1,c,h,c,s,o)||this.findIntermediatePoints(h-1,c,h,c,s,o))return{x:t,y:e}}return this.findIntermediatePoints(h+a,c+l,h,c,s,o)},n.prototype.destroy=function(){},n.prototype.getModuleName=function(){return"LineRouting"},n}(),Joe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),eae=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Joe(t,n),function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);r>3&&s&&Object.defineProperty(t,e,s)}([I(!0)],t.prototype,"inversedAlignment",void 0),t}(Ee),tae=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Oe=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},DT=function(n,t,e,i){return new(e||(e=Promise))(function(r,s){function o(h){try{l(i.next(h))}catch(c){s(c)}}function a(h){try{l(i.throw(h))}catch(c){s(c)}}function l(h){h.done?r(h.value):new e(function(c){c(h.value)}).then(o,a)}l((i=i.apply(n,t||[])).next())})},xT=function(n,t){var i,r,s,o,e={label:0,sent:function(){if(1&s[0])throw s[1];return s[1]},trys:[],ops:[]};return o={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function a(h){return function(c){return function l(h){if(i)throw new TypeError("Generator is already executing.");for(;e;)try{if(i=1,r&&(s=2&h[0]?r.return:h[0]?r.throw||((s=r.return)&&s.call(r),0):r.next)&&!(s=s.call(r,h[1])).done)return s;switch(r=0,s&&(h=[2&h[0],s.value]),h[0]){case 0:case 1:s=h;break;case 4:return e.label++,{value:h[1],done:!1};case 5:e.label++,r=h[1],h=[0];continue;case 7:h=e.ops.pop(),e.trys.pop();continue;default:if(!(s=(s=e.trys).length>0&&s[s.length-1])&&(6===h[0]||2===h[0])){e=0;continue}if(3===h[0]&&(!s||h[1]>s[0]&&h[1]0&&((!s.style||!s.style.fill)&&(o.style.fill="transparent"),(!s.style||!s.style.strokeColor)&&(o.style.strokeColor="transparent")),s.shape&&"UmlActivity"===s.shape.type&&eb(s,o),s.shape&&"SwimLane"===s.shape.type&&aF(s,o),r.nodeDefaults&&Ro(o,s,r.nodeDefaults),r.updateAnnotationText(o.annotations);if(e&&e.connectors)for(a=0;e&&e.connectors&&a0&&0===i.nodes.length)this.clearCollection(),a=!0;else{for(var g=0,v=Object.keys(e.nodes);g0&&0===i.connectors.length)this.clearCollection(!0),a=!0;else{for(var C=0,D=Object.keys(e.connectors);C0){this.renderSelector(!0);break}if(e.selectedItems.constraints){this.renderSelector(!0);break}break;case"snapSettings":this.updateSnapSettings(e);break;case"commandManager":this.initCommands();break;case"layout":o=!0;break;case"segmentThumbShape":this.updateSelector();break;case"dataSourceSettings":this.clear(),"None"===this.layout.type?a=!0:(this.initObjects(),o=!0);break;case"tooltip":i3(this);break;case"rulerSettings":this.updateRulerSettings(e);break;case"layers":this.updateLayer(e);break;case"scrollSettings":this.scrollActions|=ca.PropertyChange,this.updateScrollSettings(e),this.scrollActions&=~ca.PropertyChange,this.scrollSettings.horizontalOffset=-this.scroller.horizontalOffset||0,this.scrollSettings.verticalOffset=-this.scroller.verticalOffset||0;break;case"locale":e.locale!==i.locale&&(this.realActions|=$i.PreventDataInit,n.prototype.refresh.call(this),this.realActions&=~$i.PreventDataInit);break;case"contextMenuSettings":if(void 0!==e.contextMenuSettings.showCustomMenuOnly&&(this.contextMenuSettings.showCustomMenuOnly=e.contextMenuSettings.showCustomMenuOnly),void 0!==e.contextMenuSettings.show&&(this.contextMenuSettings.show=e.contextMenuSettings.show),e.contextMenuSettings.items){for(var A=e.contextMenuSettings.items,x=0,R=Object.keys(A);x0){for(var N=[],T=O.ports.length-1;T>=0;T--)"LineDistribution"===O.ports[parseInt(T.toString(),10)].id.split("_")[1]&&N.push(O.ports[parseInt(T.toString(),10)]);this.removePorts(O,N)}}for(T=0;T0)for(var ue=0,pe=Object.keys(e.nodes);ue0)for(var De=0,xe=Object.keys(e.connectors);De=0;o--)this.commandHandler.expandNode(r[parseInt(o.toString(),10)],this,0!==o);this.canLayout&&this.doLayout(),this.lineRoutingModule?this.connectors.sourceID!==this.connectors.targetID&&this.lineRoutingModule.lineRouting(this):this.constraints&rt.LineRouting&&console.warn('[WARNING] :: Module "LineRouting" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),this.validatePageSize(),this.renderPageBreaks(),this.diagramRenderer.renderSvgGridlines(this.snapSettings,_d(this.element.id),this.scroller.transform,this.rulerSettings,this.hRuler,this.vRuler),this.commandHandler.initSelectorWrapper(),this.notify("initial-load",{}),this.trigger("load"),this.scroller.setSize(),this.scroller.updateScrollOffsets(),this.isRefreshed||this.refreshDiagramLayer(),(this.scrollSettings.verticalOffset>0||this.scrollSettings.horizontalOffset>0)&&this.updateScrollOffset(),X.isDevice&&(this.tool=Ci.ZoomPan|Ci.SingleSelect),this.notify("initial-end",{}),this.isProtectedOnChange=!1,this.tooltipObject=i3(this),this.diagramActions=ee.Render,this.initCommands();var a=document.getElementsByClassName(this.element.id+"_hiddenUserHandleTemplate");(function Moe(n,t,e,i){var r,s,o,a,l,d=document.getElementById(i).ej2_instances[0];if(n&&t){r=UF(n);for(var u=0,p=e.userHandles;u0;)e[0].parentNode.removeChild(e[0]);var i=document.getElementById(this.element.id+"content");i&&this.element.removeChild(i);var r="measureElement";if(window[""+r]){window[""+r].usageCount-=1;var s="measureElementCount";window[""+s]--,0===window[""+s]&&(window[""+r].parentNode.removeChild(window[""+r]),window[""+r]=null)}}window.domTable={};for(var a=0;a1&&(this.callBlazorModel=!1,this.insertBlazorDiagramObjects(this.selectedItems),this.commandHandler.group(),this.callBlazorModel=!0,this.commandHandler.getBlazorOldValues())},t.prototype.unGroup=function(){this.callBlazorModel=!1,this.insertBlazorDiagramObjects(this.selectedItems),this.commandHandler.unGroup(),this.callBlazorModel=!0,this.commandHandler.getBlazorOldValues()},t.prototype.sendToBack=function(){this.commandHandler.sendToBack()},t.prototype.setActiveLayer=function(e){var i=this.commandHandler.getLayer(e);this.activeLayer=i},t.prototype.addLayer=function(e,i){this.commandHandler.addLayer(e,i)},t.prototype.removeLayer=function(e){this.commandHandler.removeLayer(e,ce())},t.prototype.moveObjects=function(e,i){$(this.layers),this.enableServerDataBinding(!1),this.commandHandler.moveObjects(e,i)},t.prototype.layerObjectUpdate=function(){},t.prototype.sendLayerBackward=function(e){this.layerObjectUpdate(),this.commandHandler.sendLayerBackward(e)},t.prototype.bringLayerForward=function(e){this.layerObjectUpdate(),this.commandHandler.bringLayerForward(e)},t.prototype.cloneLayer=function(e){this.commandHandler.cloneLayer(e)},t.prototype.bringToFront=function(){this.commandHandler.bringToFront()},t.prototype.moveForward=function(){this.commandHandler.sendForward()},t.prototype.sendBackward=function(){this.commandHandler.sendBackward()},t.prototype.getObject=function(e){return this.nameTable[""+e]},t.prototype.getNodeObject=function(e){return $(this.nameTable[""+e])},t.prototype.getConnectorObject=function(e){return $(this.nameTable[""+e])},t.prototype.getActiveLayer=function(){return this.activeLayer},t.prototype.nudgeCommand=function(e,i,r){if("object"!=typeof e&&(this.selectedItems.nodes.length||this.selectedItems.connectors.length)>0){var s=void 0;i.type&&"KEYDOWN"===i.type&&(s=i.type),this.nudge(e,void 0,void 0,s)}},t.prototype.nudge=function(e,i,r,s){var o=0,a=0;"Left"===e||"Right"===e?o=("Left"===e?-1:1)*(i||1):a=("Up"===e?-1:1)*(r||1),"KEYDOWN"===s&&(o*=5,a*=5);var h=this.selectedItems,c=this.selectedItems.wrapper.children[0];if(c instanceof si)this.commandHandler.labelDrag(h.nodes[0],c,o,a);else{var d=$(this.selectedItems);this.protectPropertyChange(!0),this.drag(h,o,a),this.protectPropertyChange(!1);var u={type:"PositionChanged",redoObject:$(this.selectedItems),undoObject:d,category:"Internal"};this.addHistoryEntry(u)}this.refreshCanvasLayers()},t.prototype.insertBlazorDiagramObjects=function(e){},t.prototype.drag=function(e,i,r){if(this.insertBlazorDiagramObjects(e),!(this.bpmnModule&&e instanceof te&&this.bpmnModule.updateAnnotationDrag(e,this,i,r))){if(e instanceof oi){if(this.preventConnectorsUpdate=!0,e.nodes&&e.nodes.length){for(var o=0,a=e.nodes;o0&&o.nodes[0].children){this.fromUndo||(this.rotateUsingButton=!0);for(var h=this.commandHandler.getAllDescendants(o.nodes[0],[]),c=0;c0&&o.nodes[0].children){var g={type:"RotationChanged",redoObject:$(e),undoObject:$(o),category:"Internal",childTable:a};this.commandHandler.addHistoryEntry(g),this.commandHandler.updateSelector()}return u},t.prototype.dragSourceEnd=function(e,i,r){this.insertBlazorDiagramObjects(e),this.commandHandler.dragSourceEnd(e,i,r),this.callBlazorModel&&this.commandHandler.getBlazorOldValues()},t.prototype.dragTargetEnd=function(e,i,r){this.insertBlazorDiagramObjects(e),this.commandHandler.dragTargetEnd(e,i,r),this.callBlazorModel&&this.commandHandler.getBlazorOldValues()},t.prototype.findObjectsUnderMouse=function(e,i){return this.eventHandler.findObjectsUnderMouse(e,i)},t.prototype.findObjectUnderMouse=function(e,i,r){return this.eventHandler.findObjectUnderMouse(e,i,r)},t.prototype.findTargetObjectUnderMouse=function(e,i,r,s,o){return this.eventHandler.findTargetUnderMouse(e,i,r,s,o)},t.prototype.findElementUnderMouse=function(e,i,r,s){return this.eventHandler.findElementUnderMouse(e,i,r,s)},t.prototype.findActionToBeDone=function(e,i,r,s){return this.eventHandler.findActionToBeDone(e,i,r,s)},t.prototype.updateConnectorPort=function(e){if(e.ports.length)for(var i=void 0,r=0,s=e.ports;r=0;s--)if(i.push(r[parseInt(s.toString(),10)]),i.length>this.historyManager.stackLimit)return i}else i=r;return i},t.prototype.getEdges=function(e){return e.outEdge?this.nameTable[e.id].outEdges:this.nameTable[e.id].inEdges},t.prototype.getParentId=function(e){return this.nameTable[""+e].parentId},t.prototype.addConnector=function(e){return this.add(e)},t.prototype.UpdateBlazorDiagramModelCollection=function(e,i,r,s){},t.prototype.UpdateBlazorDiagramModel=function(e,i,r,s){},t.prototype.UpdateBlazorLabelOrPortObjects=function(e,i,r,s){},t.prototype.addBlazorDiagramObjects=function(){},t.prototype.removeNodeEdges=function(e,i,r){var s=this.nameTable[""+e],o=r?s.outEdges:s.inEdges;if(o.length>0)for(var a=0;a0)){for(var c=0;c0))}this.removePortEdges(l,a.element.sourcePortID,a.element.id,h)}a.element.targetID&&this.removeNodeEdges(a.element.targetID,a.element.id,!1)}}this.diagramActions=this.diagramActions|ee.PublicMethod,e.id=e.id||Qe();var u=this.activeLayer;if(!a.cancel&&u&&!u.lock){if(u.objects.indexOf(e.id)<0&&!u.lock&&(u.visible||(u.visible=!0,this.dataBind()),u.objects.push(e.id)),fs(e)===de)(r=new de(this,"connectors",e,!0)).status="New",this.nameTable[r.targetID]&&"TextAnnotation"===this.nameTable[r.targetID].shape.shape&&(r.isBpmnAnnotationConnector=!0,r.constraints=r.constraints&~qe.Delete),Ro(r,e,this.connectorDefaults),this.connectors.push(r),this.initObject(r),!1===e.visible&&this.updateElementVisibility(r.wrapper,r,e.visible),this.updateEdges(r),this.insertBlazorConnector(r);else{if(Ro(r=new te(this,"nodes",e,!0),e,this.nodeDefaults),r.parentId=e.parentId?e.parentId:r.parentId,r.umlIndex=e.umlIndex,r.status="New",(o="TextAnnotation"===r.shape.shape)&&!e.isTextAnnotationCopied&&(r.inEdges=e.inEdges?e.inEdges:r.inEdges),this.nodes.push(r),this.initObject(r,u,void 0,i),o&&this.bpmnModule)for(c=0;c-1&&e.parentId&&this.nameTable[e.parentId]&&"UmlClassifier"===this.nameTable[e.parentId].shape.type){var g=this.nameTable[e.parentId];g.children.splice(r.umlIndex,0,r.id),g.wrapper.children.splice(r.umlIndex,0,r.wrapper),g.wrapper.measure(new me),g.wrapper.arrange(g.wrapper.desiredSize),this.updateDiagramObject(g)}}if(a={element:r,cause:this.diagramActions,diagramAction:this.getDiagramAction(this.diagramActions),state:"Changed",type:"Addition",cancel:!1},this.parentObject&&(a.parentId=this.parentObject.id),"helper"!==e.id&&!(this.diagramActions&ee.PreventCollectionChangeOnDragOver)&&this.triggerEvent(Ce.collectionChange,a),!(this.diagramActions&ee.UndoRedo||this.diagramActions&ee.Group||this.diagramActions&ee.PreventHistory)){var v={type:"CollectionChanged",changeType:"Insert",undoObject:$(e),redoObject:$(e),category:"Internal"};this.addHistoryEntry(v)}this.parentObject=void 0,"SVG"===this.mode&&(this.updateSvgNodes(r),this.updateTextElementValue(r),this.updateDiagramObject(r),o&&this.updateDiagramObject(this.nameTable[r.inEdges[0]]),r.shape.activity&&r.shape.activity.subProcess.processes&&r.shape.activity.subProcess.processes.length&&this.updateProcesses(r),this.updateBridging())}}if(this.protectPropertyChange(s),this.resetDiagramActions(ee.PublicMethod),r&&this.layers.length>1&&this.moveNode(r),this.views)for(var S=0,b=this.views;S=0;l--)this.moveSvgNode(a[parseInt(l.toString(),10)])}for(var h=0,c=i;h=0;o--)r[parseInt(o.toString(),10)]===e.id&&r.splice(o,1);for(var a=0;s.ports&&a=0;s--)if(i=this.nameTable[r[parseInt(s.toString(),10)]])if(this.connectorTable[i.id]=$(i),i.isBpmnAnnotationConnector){var o=this.nameTable[i.targetID];this.removeObjectsFromLayer(i);var a=this.connectors.indexOf(i);-1!==a&&this.connectors.splice(a,1),this.removeElements(i),this.removeFromAQuad(i),delete this.nameTable[i.id];var l=this.nameTable[i.sourceID];if(l){var h=l.outEdges.indexOf(i.id);-1!==h&&l.outEdges.splice(h,1)}e.id!==i.targetID&&this.remove(o)}else this.remove(i)},t.prototype.removeObjectsFromLayer=function(e){if(e.children)for(var i=0;i-1&&(_r(this,e)&&this.unSelect(e),this.layers[parseInt(s.toString(),10)].objects.splice(a,1),delete this.layers[parseInt(s.toString(),10)].zIndexTable[this.nameTable[e.id].zIndex])},t.prototype.removeElements=function(e){if("SVG"===this.mode||"Canvas"===this.mode&&"Native"===e.shape.type){var i=xt(e.id+"_groupElement",this.element.id),r=e;if(r.ports&&r.ports.length>0)for(var s=0;s0){l[parseInt(s.toString(),10)].id.indexOf("icon_content")>0&&"SVG"===this.mode&&((h=xt(l[parseInt(s.toString(),10)].id+"_shape_groupElement",this.element.id))&&h.parentNode.removeChild(h),(h=xt(l[parseInt(s.toString(),10)].id+"_rect_groupElement",this.element.id))&&h.parentNode.removeChild(h));for(var c=0,d=this.views;c=0;o--)a.children[parseInt(o.toString(),10)].children&&(l=n.nameTable[a.children[parseInt(o.toString(),10)].id])&&(l.isLane?qv(n,l):(n.removeDependentConnector(l),n.diagramActions|=ee.PreventHistory,l.constraints&ie.Delete?n.remove(l):V3(n,l,{},!1),n.diagramActions&=~ee.PreventHistory));a&&(i=n.nameTable[a.id])&&qv(n,i)}}(this,e),!(this.diagramActions&ee.UndoRedo||this.diagramActions&ee.PreventHistory)&&(e instanceof te||e instanceof de)){var o={type:"CollectionChanged",changeType:"Remove",undoObject:$(e),redoObject:$(e),category:"Internal"};this.diagramActions&ee.Clear||e.children&&!e.isLane&&!e.isPhase&&e.children.length>0&&this.undoRedoModule&&"None"===this.layout.type&&(this.historyManager.startGroupAction(),s=!0),(e instanceof te||e instanceof de)&&this.deleteDependentConnector&&this.removeDependentConnector(e),!e.isLane&&!e.isPhase&&!(this.diagramActions&ee.Clear)&&!this.isStackChild(e)&&this.addHistoryEntry(o)}"TextAnnotation"===e.shape.shape&&this.removeDependentConnector(e),e.children&&!e.isLane&&!e.isPhase&&(!(this.diagramActions&ee.UndoRedo)||!ce())&&this.deleteGroup(e),e.parentId&&(this.deleteChild(e,void 0,!0),this.nameTable[e.parentId]&&"UmlClassifier"===this.nameTable[e.parentId].shape.type&&(this.updateDiagramObject(this.nameTable[e.parentId]),this.updateConnectorEdges(this.nameTable[e.parentId])));var a=void 0;this.diagramActions=this.diagramActions|ee.PublicMethod;var l=this.nameTable[e.id];if(l instanceof te?("Bpmn"===l.shape.type&&this.bpmnModule&&this.bpmnModule.removeBpmnProcesses(l,this),(l.isLane||l.isPhase||"SwimLane"===l.shape.type)&&(h=l.isLane||l.isPhase?this.nameTable[l.parentId]:this.nameTable[l.id],l.isLane?_3(this,l,h):l.isPhase&&U3(this,l,h)),-1!==(a=this.nodes.indexOf(l))&&(this.crudDeleteNodes.push(this.nameTable[l.id]),this.nodes.splice(a,1),this.updateNodeEdges(l))):(-1!==(a=this.connectors.indexOf(l))&&(this.crudDeleteNodes.push(this.nameTable[l.id]),this.connectors.splice(a,1)),this.updateEdges(l),this.spliceConnectorEdges(e,!0),this.spliceConnectorEdges(e,!1)),!this.isServerUpdate&&!(this.blazorActions&on.GroupClipboardInProcess)&&this.commandHandler.getBlazorOldValues(),s&&this.historyManager.endGroupAction(),_r(this,l)&&this.unSelect(l),!l.isPhase){if(this.removeObjectsFromLayer(e),this.currentDrawingObject&&(this.currentDrawingObject.wrapper=void 0),delete this.nameTable[e.id],i.length>0&&i[0].id===l.id&&l.parentId){var h,d=this.nameTable[l.parentId];d&&d.isLane&&"SwimLane"===this.nameTable[d.parentId].shape.type&&F3(this,h=this.nameTable[d.parentId],d,l)}this.removeElements(l),this.updateBridging(),"SVG"!==this.mode&&this.refreshDiagramLayer(),this.diagramActions&ee.Clear||(this.removeFromAQuad(l),r={element:e,cause:this.diagramActions,diagramAction:this.getDiagramAction(this.diagramActions),state:"Changed",type:"Removal",cancel:!1},"helper"!==e.id&&this.triggerEvent(Ce.collectionChange,r),this.resetTool())}}}else if(i.length>0){this.undoRedoModule&&(this.historyManager.startGroupAction(),this.blazorActions|=on.GroupingInProgress,s=!0);for(var u=0;u=f.wrapper.bounds.width&&"Horizontal"===f.shape.orientation||this.selectedItems.wrapper.bounds.y<=f.wrapper.bounds.y+g&&this.selectedItems.wrapper.bounds.height>=f.wrapper.bounds.height-g&&"Vertical"===f.shape.orientation)&&(AI(f)||f.shape.lanes.length>1)&&this.remove(i[parseInt(u.toString(),10)])}}else this.remove(i[parseInt(u.toString(),10)])}s&&(this.blazorActions&=~on.GroupingInProgress,this.isServerUpdate=!0,this.commandHandler.getBlazorOldValues(),this.UpdateBlazorDiagramModelCollection(void 0,void 0,void 0,!0),this.historyManager.endGroupAction(),this.isServerUpdate=!1),this.clearSelection()}e&&(AI(e)||this.diagramActions&ee.Clear)||this.diagramActions&ee.UndoRedo||this.diagramActions&ee.PreventHistory||!(e instanceof te||e instanceof de)||(o={type:"ConnectionChanged",undoObject:$(e),redoObject:$(e),category:"Internal"},!e.isLane&&!e.isPhase&&!(this.diagramActions&ee.Clear)&&!this.isStackChild(e)&&this.addHistoryEntry(o)),this.tooltipObject.close()},t.prototype.isStackChild=function(e){var i,r=this.nameTable[e.parentId];if(e&&e.parentId&&r.container&&"Stack"===r.container.type&&"UmlClassifier"!==this.nameTable[e.parentId].shape.type){i=!0;var s={sourceIndex:r.wrapper.children.indexOf(e.wrapper),source:e,target:void 0,targetIndex:void 0};this.diagramActions&ee.UndoRedo||this.addHistoryEntry({type:"StackChildPositionChanged",redoObject:{sourceIndex:void 0,source:e,target:void 0,targetIndex:void 0},undoObject:s,category:"Internal"})}return i},t.prototype.deleteChild=function(e,i,r){var s;if(s="string"==typeof e?e:e.id,(i=i?this.nameTable[i.id]:this.nameTable[e.parentId])&&i.children){for(var o=0;o=0;i--)this.removeLayer(this.layers[parseInt(i.toString(),10)].id);this.commandHandler.addLayer({id:"default_layer",visible:!0,lock:!1,objects:[],zIndex:0,objectZIndex:-1,zIndexTable:{}},null,!0),this.setActiveLayer(this.layers[this.layers.length-1].id)},t.prototype.clearObjects=function(e){var i=[];i=e||(i=i.concat(this.nodes)).concat(this.connectors),this.diagramActions=this.diagramActions|ee.Clear;for(var r=0,s=i;r0||"Text"===e.shape.type))if("Text"===e.shape.type)i=e.wrapper.children[0].id.split("_")[1];else for(var f=e.annotations.length-1;f>=0;f--)e.annotations[parseInt(f.toString(),10)].visibility&&(i=e.annotations[parseInt(f.toString(),10)].id);i&&(u=this.getWrapper(e.wrapper,i))}if(e&&u&&!(u instanceof Jn)&&(!function $re(n,t){return"Text"===t.shape.type?t.constraints&ie.ReadOnly:t.constraints&(t instanceof de?qe.ReadOnly:ie.ReadOnly)?n.constraints&Lr.InheritReadOnly?1:0:n.constraints&Lr.ReadOnly?1:0}(u,e)||p)){var g=u.style,v=void 0;v=90>(v=u.bounds.width50?50:e.width,u.style.fontSize)),e.parentId&&"UmlClassifier"===this.nameTable[e.parentId].shape.type?(l.width=e.wrapper.bounds.width-20,c=(e.wrapper.bounds.center.x+r.tx)*r.scale-l.width/2*s-2.5,d=(e.wrapper.bounds.center.y+r.ty)*r.scale-l.height/2*s-3,u.style.textAlign="Left"):(l.width=Math.max(l.width,50),c=(u.bounds.center.x+r.tx)*r.scale-l.width/2*s-2.5,d=(u.bounds.center.y+r.ty)*r.scale-l.height/2*s-3),Ho(y,{id:this.element.id+"_editTextBoxDiv",style:"position: absolute;left:"+c+"px;top:"+d+"px;width:"+(l.width+1)*s+"px;height:"+l.height*s+"px; containerName:"+e.id+";"}),Ho(S,{"aria-label":a,id:this.element.id+"_editBox",style:"width:"+(l.width+1)*s+"px;height:"+l.height*s+"px;resize: none;outline: none;overflow: hidden;;font-family:"+g.fontFamily+";font-size:"+g.fontSize*s+"px;text-align:"+u.style.textAlign.toLocaleLowerCase()+";",class:"e-diagram-text-edit"}),S.style.fontWeight=g.bold?"bold":"",S.style.fontStyle=g.italic?"italic":"",S.style.lineHeight=(1.2*g.fontSize+"px;").toString(),S.style.textDecoration=g.textDecoration?g.textDecoration:"",this.activeLabel.parentId=e.id,this.activeLabel.id=i,u.visible=!1,this.updateDiagramObject(e),this.diagramActions=this.diagramActions|ee.TextEdit,this.isTriggerEvent||(E.add(S,"input",this.eventHandler.inputChange,this.eventHandler),E.add(S,"focusout",this.focusOutEdit,this),S.select())}}}},t.prototype.updateConnectorfixedUserHandles=function(e){if(e.fixedUserHandles.length)for(var i=void 0,r=0,s=e.fixedUserHandles;r0&&this.mindMapChartModule.updateLayout(o,this.nameTable,this.layout,l,this.dataSourceSettings.id,this.dataSourceSettings.root),e=!0;else if(this.radialTreeModule)this.radialTreeModule.updateLayout(o,this.nameTable,this.layout,l),e=!0;else if(this.symmetricalLayoutModule)this.symmetricalLayoutModule.maxIteration=this.layout.maxIteration,this.symmetricalLayoutModule.springLength=this.layout.springLength,this.symmetricalLayoutModule.springFactor=this.layout.springFactor,this.symmetricalLayoutModule.updateLayout(o,this.connectors,this.symmetricalLayoutModule,this.nameTable,this.layout,l),e=!0;else if(this.complexHierarchicalTreeModule){this.canDistribute(a,r)&&(this.lineDistributionModule.diagram=this,this.connectors.forEach(function(R){R.obstaclePointCollection=[]}));var c=this.complexHierarchicalTreeModule.getLayoutNodesCollection(this.nodes);c.length>0&&this.complexHierarchicalTreeModule.doLayout(c,this.nameTable,this.layout,l,this),e=!0,this.canDistribute(a,r)&&this.lineDistributionModule.initLineDistribution(this.layout,this)}else this.flowchartLayoutModule?(this.flowchartLayoutModule.updateLayout(this.nodes,this),e=!0):console.warn("[WARNING] :: Module "+("OrganizationalChart"===this.layout.type?"HierarchicalTree":this.layout.type)+" is not available in Diagram component! You either misspelled the module name or forgot to load it.");if(e){this.preventDiagramUpdate=!0;for(var u={},f=0,g=o;f0)for(var S=0;S0)for(var M=0;M0)for(var s=0,o=r.ports;s0&&function xse(n){var t,e,i,r=[];for(t=0;t0&&y.connectors[w].bezierSettings&&y.connectors[w].bezierSettings.allowSegmentsReset&&(y.connectors[w].segments=[]);if(t.connectors=y.connectors||[],t.dataSourceSettings=y.dataSourceSettings||{},t.dataSourceSettings.doBinding=i,t.height=y.height||"100%",t.setNodeTemplate=r,t.getConnectorDefaults=v,t.getNodeDefaults=g,t.getCustomProperty=o,t.mode=y.mode||"SVG",y.nodes)for(w=0;w0)){var r=this.nodes.filter(function(a){return 0===a.inEdges.length})[0],s=this.convertMindmapToMermaid(r,0);i.push(s),this.updateTextDataSource(i,r.outEdges,1),e=(i=i.filter(function(a){return""!==a.trim()})).join("\n")}return e},t.prototype.updateTextDataSource=function(e,i,r){for(var s=0;s0&&this.updateTextDataSource(e,h,r+1),s++}},t.prototype.convertMindmapToMermaid=function(e,i){var r=e.id,o=" ".repeat(2*(i+1)),a=e.annotations.length>0?e.annotations[0].content.replace(/\n/g," "):"",l=o+a,h=o+r;if(e.shape&&"Basic"===e.shape.type){var c=e.shape;"Rectangle"===c.shape?l=h+"["+a+"]":"Ellipse"===c.shape?l=h+"(("+a+"))":"Hexagon"===c.shape&&(l=h+"{{"+a+"}}")}else if(e.shape&&"Flow"===e.shape.type)"Terminator"===e.shape.shape&&(l=h+"("+a+")");else if(e.shape&&"Path"===e.shape.type){var u=e.shape;u.data===this.bangShape?l=h+"))"+a+"((":u.data===this.cloudShape&&(l=h+")"+a+"(")}return l},t.prototype.saveFlowDiagramInMermaidFormat=function(){var e=this,i=[],r="graph TD\n",s={nodes:this.nodes,edges:this.connectors};return s.nodes.reduce(function(a,l){return a[l.id]=l.annotations.length?l.annotations[0].content:"",a},{}),s.edges.forEach(function(a){var l=a.sourceID,h=a.targetID,p=e.nameTable[""+h],f=e.getNodeShape(e.nameTable[""+l]),g=e.getNodeShape(p),v=a.annotations[0]&&""!==a.annotations[0].content?"|"+a.annotations[0].content+"|":"";-1===i.indexOf(l)?i.push(l):f="",-1===i.indexOf(h)?i.push(h):g="";var y=e.arrowType(a);r+=" "+l+f+" "+y+v+" "+h+g+"\n"}),s.nodes.forEach(function(a){r+=" style "+a.id+" fill:"+a.style.fill+",stroke:"+a.style.strokeColor+",stroke-width:"+a.style.strokeWidth+"px;\n"}),r},t.prototype.arrowType=function(e){var i=e.targetDecorator.shape;return e.style.opacity<1?"~~~":""!==e.style.strokeDashArray?"-.->":"Arrow"===i?e.style.strokeWidth>1?"==>":"--\x3e":"None"===i?"---":"--\x3e"},t.prototype.getNodeShape=function(e){var i=e.annotations.length>0?e.annotations[0].content:"",r=e.shape.shape;if(!r){var s=e.shape.data;return"M 0 0 A 1 1 0 0 0 7 0 A 1 1 0 0 0 0 0 M -1 0 A 1 1 0 0 0 8 0 A 1 1 0 0 0 -1 0"===s?"((("+i+")))":"M 0 0 L 1 -1 L 5 -1 L 6 0 L 0 0"===s?"[/"+i+"\\]":"M 0 1 L 0 6 C 2 7 4 7 6 6 L 6 1 C 5 0 1 0 0 1 C 1 2 5 2 6 1"===s?"[("+i+")]":"M 0 0 L 12 0 L 14 2 L 2 2 L 0 0"===s?"[\\"+i+"\\]":"M 0 0 L 5 0 L 4 1 L 1 1 L 0 0"===s?"[\\"+i+"/]":"M 0 0 L 2 -2 L 11 -2 L 13 0 L 11 2 L 2 2 L 0 0"===s?"{{"+i+"}}":">"+i+"]"}switch(r){case"Terminator":return"(["+i+"])";case"Process":default:return"["+i+"]";case"Decision":return"{"+i+"}";case"Parallelogram":return"[/"+i+"/]";case"Ellipse":return"(("+i+"))";case"PreDefinedProcess":return"[["+i+"]]"}},t.prototype.loadDiagramFromMermaid=function(e){this.layout&&"Flowchart"===this.layout.type&&this.flowchartLayoutModule?this.convertMermaidToFlowChart(e):this.layout&&"MindMap"===this.layout.type&&this.mindMapChartModule?this.convertMermaidToMindmap(e):console.warn('[WARNING] :: Module "FlowchartLayout" or "MindMap" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.countLeadingSpaces=function(e){for(var i=0,r=e.length;i0});this.clear(),this.mermaidNodeBaseCollection=[];var r=[],s={text:"",children:[],currentLevel:0,branch:"Left"},o=[],l=!1,h=!1,c=!1;if(i.length>0){for(var d=function(M){var w=i[parseInt(M.toString(),10)],C=0,D="",A=u.countLeadingSpaces(w),x=w.includes('"`');if(h=w.includes('`"'),c=(l=!!x||l)||c?c:0===A&&M>0,l&&h&&!x)return s.text+="\n"+w,l=!1,"continue";if(!x&&l)return s.text+="\n"+w,"continue";if(l=!h&&l,w.length>0&&(/\s/.test(w[0])&&M>0||0===A)){if(-1!==o.findIndex(function(B){return B.space===A.toString()}))for(var L=o.length-1;L>=0;L--){var O=o[parseInt(L.toString(),10)];if((N=parseFloat(O.space))>A)o.splice(L,1);else{if(N=0;L--){var N,T=o[parseInt(L.toString(),10)];if(!((N=parseFloat(T.space))>A)){var P=o[o.length-1];o.push({space:A.toString(),level:P.level+1});break}o.splice(L,1)}C=o[o.length-1].level}D=w.trim().replace(/^[+-]/,"")}var _={text:D,branch:void 0,children:[],currentLevel:0===M?0:C-1};if(r.length>0){for(;r.length>=C&&0!==r.length;)r.pop();r.length>0&&r[r.length-1].children.push(_)}r.push(_),s=_},u=this,p=0;p0){var c=h[h.length-1];c.arrowType=a[2],""!==a[3]&&(c.label&&c.label.some(function(d){return d.trim().length>0})?c.label.push(a[3]):(c.label=[],c.label[c.parentId.length-1]=a[3]))}h.filter(function(d){return d.parentId&&0===d.parentId.length}).forEach(function(d){d.parentId=null}),i=i.concat(h)}}this.createFlowChart(i),this.doLayout(),this.clearHistory()},t.prototype.createFlowChart=function(e){for(var i=[],r=0;r1)for(var h=0;h|---|--\s*.*?\s*-->|~~~|==>|===|==\s*.*?\s*==>|\s*-\.\s*->|\s*-\.\s*-|\s*-\.\s*.*?\s*\.\s*->|\s*-\..*?\.\s*->)(.*)$/);if(l){i=l[1].trim();var h=l[2].trim();r=l[3].trim();var d=h.match(/(-\.|\\-\\-|==|--|~~)(.*?)(\1>|\.->|==>|\\->|~~>)/),u=void 0,p="";o=null!==(u=d?{text:d[2].trim()||null,arrowType:d[1]+d[3]}:{text:null,arrowType:h}).text?u.text:"",s=(p=u.arrowType).includes("--\x3e")?"single-line-arrow":p.includes("---")?"single-line":p.includes("==>")?"double-line-arrow":p.includes("==")?"double-line":p.includes("~~~")?"wiggly-arrow":p.includes("-.->")||p.includes(".->")?"dotted-arrow":p.includes("-.-")||p.includes(".-")?"dotted":"single-line-arrow"}return[i,r,s,o]},t.prototype.parseStyle=function(e,i){if(e.startsWith("style")){var s=e.match(/^style\s+(\w+)\s+fill:([^,]+),stroke:([^,]+),stroke-width:(\d+)px;/);if(s){var c={id:s[1],fill:s[2],stroke:s[3],strokeWidth:parseInt(s[4],10)},d=i.filter(function(u){return u.id===c.id});d[0].color=c.fill,d[0].stroke=c.stroke,d[0].strokeWidth=c.strokeWidth}}},t.prototype.getNodeData=function(e,i,r){for(var s=[],o=null,a=null,l=0,h="",c=function(v){var y=e[parseInt(v.toString(),10)],S=d.splitNested(y);if(S[0].includes("|")){var b=S[0].match(/\|([^|]*)\|/);b&&(h=b[1]);var M=S[0].split("|");M.length>=3&&(S[0]=M[2].trim())}var w=S[0].trim();if(0===v?o=w:a=w,i.find(function(L){return L.id===w}))l++;else{var D=S.length>1?S[1]:S[0],A=d.getShape(D),x=D.replace(/[\\[\]\\(\\)\\{\\}\\{\\}\\/>]/g,"");s.push({id:w,name:x,shape:A,color:"white",parentId:[]})}},d=this,u=0;u"===h?0===s?(r.trim().length>0&&i.push(r.trim()),r=h,o=h,s++):(r+=h,s++):"]"===h||"}"===h||")"===h?1===s&&h===o?(i.push((r+=h).trim()),r="",s--):s>1?(r+=h,s--):r+=h:r+=h}return r.trim().length>0&&i.push(r.trim()),i},t.prototype.getShape=function(e){var i={};return e.startsWith("(((")?i={type:"Path",data:"M 0 0 A 1 1 0 0 0 7 0 A 1 1 0 0 0 0 0 M -1 0 A 1 1 0 0 0 8 0 A 1 1 0 0 0 -1 0"}:e.startsWith("((")?i={shape:"Ellipse",type:"Basic"}:e.startsWith("([")?i={type:"Flow",shape:"Terminator"}:e.startsWith("(")?i={type:"Flow",shape:"Process"}:e.startsWith("[[")?i={type:"Flow",shape:"PreDefinedProcess"}:e.startsWith("[/")?i=e.endsWith("/]")?{type:"Basic",shape:"Parallelogram"}:{type:"Path",data:"M 0 0 L 1 -1 L 5 -1 L 6 0 L 0 0"}:e.startsWith("[(")?i={type:"Path",data:"M 0 1 L 0 6 C 2 7 4 7 6 6 L 6 1 C 5 0 1 0 0 1 C 1 2 5 2 6 1"}:e.startsWith("[\\")?i=e.endsWith("\\]")?{type:"Path",data:"M 0 0 L 12 0 L 14 2 L 2 2 L 0 0"}:{type:"Path",data:"M 0 0 L 5 0 L 4 1 L 1 1 L 0 0"}:e.startsWith("[")?i={type:"Basic",shape:"Rectangle"}:e.startsWith("{{")?i={type:"Path",data:"M 0 0 L 2 -2 L 11 -2 L 13 0 L 11 2 L 2 2 L 0 0"}:e.startsWith("{")?i={type:"Flow",shape:"Decision"}:e.startsWith(">")&&(i={type:"Path",data:"M 0 0 L 8 0 L 8 2 L 0 2 L 2 1 L 0 0"}),i},t.prototype.getDiagramContent=function(e){return this.printandExportModule?this.printandExportModule.getDiagramContent(e):(console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),"")},t.prototype.exportImage=function(e,i){this.printandExportModule?this.printandExportModule.exportImages(e,i):console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.printImage=function(e,i){this.printandExportModule?(i.printOptions=!0,this.printandExportModule.exportImages(e,i)):console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.setStackLimit=function(e){this.undoRedoModule&&e&&(this.historyManager.stackLimit=e,this.undoRedoModule.applyLimit(this.historyManager.currentEntry,e,this,!0))},t.prototype.clearHistory=function(){this.undoRedoModule&&this.undoRedoModule.clearHistory(this)},t.prototype.getDiagramBounds=function(){if(this.printandExportModule){var e=this.printandExportModule.getDiagramBounds("",{});return e.width=e.width>this.scrollSettings.viewPortWidth?e.width+(e.x>0?e.x:0):this.scrollSettings.viewPortWidth,e.height=e.height>this.scrollSettings.viewPortHeight?e.height+(e.y>0?e.y:0):this.scrollSettings.viewPortHeight,e.x=e.x>0?0:e.x,e.y=e.y>0?0:e.y,e}return console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),new Ne},t.prototype.exportDiagram=function(e){return this.printandExportModule?this.printandExportModule.exportDiagram(e):(console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),"")},t.prototype.print=function(e){this.printandExportModule?this.printandExportModule.print(e):console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.addPorts=function(e,i){var s;this.protectPropertyChange(!0),e=this.nameTable[e.id]||e,i.length>1&&this.startGroupAction();for(var o=function(h){if(e.ports.some(function(y){return y.id===i[parseInt(h.toString(),10)].id}))return"continue";if(e instanceof te?(s=new Es(e,"ports",i[parseInt(h.toString(),10)],!0),e.ports.push(s)):e instanceof de&&(s=new xc(e,"ports",i[parseInt(h.toString(),10)],!0),e.ports.push(s)),e.children)for(var c=e.wrapper,d=0;d1&&this.endGroupAction(),e.wrapper.measure(new me(e.width,e.height)),e.wrapper.arrange(e.wrapper.desiredSize),this.updateDiagramObject(e),this.protectPropertyChange(!1)},t.prototype.addConstraints=function(e,i){return e|i},t.prototype.removeConstraints=function(e,i){return e&~i},t.prototype.addNodeLabels=function(e,i){this.addLabels(e,i)},t.prototype.addConnectorLabels=function(e,i){this.addLabels(e,i)},t.prototype.addLabels=function(e,i){this.protectPropertyChange(!0);var s,r=(e=this.nameTable[e.id]||e).wrapper;i.length>1&&this.startGroupAction();for(var o=0;o1&&this.endGroupAction(),e.wrapper.measure(new me(r.width,r.height)),e.wrapper.arrange(r.desiredSize),this.updateDiagramObject(e),this.protectPropertyChange(!1),this.refreshCanvasLayers()},t.prototype.addChildToUmlNode=function(e,i,r){var s,o,a,l,h="NoWrap";"Class"===e.shape.classifier||"Interface"===e.shape.classifier?"Method"===r?(o=new hm(e,"",i),"Class"===e.shape.classifier?(e.shape.classShape.methods.push(o),s=e.shape.classShape):"Interface"===e.shape.classifier&&(e.shape.interfaceShape.methods.push(o),s=e.shape.interfaceShape),function $se(n,t,e,i){if(e.methods&&e.methods.length){var r=e.methods,s="",o="",a=void 0,l=1,h=void 0,c=0,d=0,u=n.shape,g="Class"===u.classifier?u.classShape:u.interfaceShape;1===r.length?g.attributes.length>0?(c=g.attributes.filter(function(w){return w.isSeparator}).length,h=(l=2+g.attributes.length+c)+1,oT(n,t,l)):h=l+1:(c=g.attributes.filter(function(w){return w.isSeparator}).length,d=g.methods.filter(function(w){return w.isSeparator}).length,h=(l=2+g.attributes.length+c+g.methods.length+d)+1);for(var v=0;v1&&this.startGroupAction();for(var r=i.length-1;r>=0;r--)if(e.children&&e.children.length>0){var s=e.wrapper.children.filter(function(o){return o.id===e.id+"group_container"});s&&s.length>0&&this.removelabelExtension(e,i,r,s[0])}else this.removelabelExtension(e,i,r,e.wrapper);i.length>1&&this.endGroupAction(),this.refreshCanvasLayers()},t.prototype.removePortsExtenion=function(e,i,r,s){for(var o=0;o1&&this.startGroupAction();for(var r=i.length-1;r>=0;r--)if(e.children&&e.children.length>0)for(var s=0;s1&&this.endGroupAction()},t.prototype.getSizeValue=function(e,i){var r;return r=e.toString().indexOf("px")>0?e.toString():e.toString().indexOf("%")>0?void 0!==i?"100%":e.toString():e.toString()+"px",i&&(qa(this),r="calc("+r+" - "+i+"px)"),r},t.prototype.renderRulers=function(){this.rulerSettings.showRulers?(function Gne(n){var t=qa(n),i=Tt("div",{id:n.element.id+"_overlapRuler",style:"height:"+t.height+"px;width:"+t.width+"px;position:absolute;left:0;top:0",class:"e-ruler-overlap"});n.element.insertBefore(i,n.element.firstChild)}(this),eF(this,!0),eF(this,!1)):Xx(this)},t.prototype.intOffPageBackground=function(){var e=new me;e=qa(this);var i=document.getElementById(this.element.id+"content"),r=this.getSizeValue(this.width,e.width),s=this.getSizeValue(this.height,e.height),o=this.rulerSettings.showRulers?"width:"+r+"; height:"+s+";top:"+e.height+"px;left:"+e.width+"px;overflow: scroll;position:absolute;overflow:auto;":"width:"+r+"; height:"+s+";position:absolute; left:0px; top:0px;overflow: auto;",a={id:this.element.id+"content",tabindex:"0",style:o};i?(this.diagramCanvas=i,Za(this.diagramCanvas,o)):(this.diagramCanvas=Tt("div",a),this.element.appendChild(this.diagramCanvas)),this.diagramCanvas.style.background=this.backgroundColor},t.prototype.initDiagram=function(){this.intOffPageBackground(),Ho(this.element,{style:"width:"+this.getSizeValue(this.width)+"; height:"+this.getSizeValue(this.height)+";position:relative;overflow:hidden;"})},t.prototype.renderHiddenUserHandleTemplateLayer=function(e){var r=Tt("div",{class:this.element.id+"_hiddenUserHandleTemplate",style:"width:"+e.width+"px; height:"+e.height+"px;visibility:hidden ; overflow: hidden;"});this.element.appendChild(r)},t.prototype.renderBackgroundLayer=function(e,i){var r=this.createSvg(this.element.id+"_backgroundLayer_svg",e.width,e.height);Za(r,i);var s=Bi("g",{id:this.element.id+"_backgroundImageLayer",class:"e-background-image-layer"});r.appendChild(s);var a=Bi("g",{id:this.element.id+"_backgroundLayer",class:"e-background-layer"});r.appendChild(a),this.diagramCanvas.appendChild(r)},t.prototype.renderGridLayer=function(e,i){var r=this.createSvg(this.element.id+"_gridline_svg",e.width,e.height);r.setAttribute("class","e-grid-layer");var s=Bi("g",{id:this.element.id+"_gridline"}),o=Bi("rect",{id:this.element.id+"_grid_rect",x:"0",y:"0",width:"100%",height:"100%"});if(nm()){var a=new URL(window.location.href);o.setAttribute("fill",""!==a.search?"url(#"+this.element.id+"_pattern)":"url("+location.protocol+"//"+location.host+location.pathname+"#"+this.element.id+"_pattern)")}else o.setAttribute("fill","url(#"+this.element.id+"_pattern)");s.appendChild(o),r.appendChild(s),this.diagramCanvas.appendChild(r),ai(r,{style:i})},t.prototype.renderDiagramLayer=function(e,i){if(this.diagramLayerDiv=Tt("div",{id:this.element.id+"_diagramLayer_div",style:"width:"+e.width+"px; height:"+e.height+"px;"+i}),"SVG"===this.mode){var s=this.createSvg(this.element.id+"_diagramLayer_svg",e.width,e.height);s.style["pointer-events"]="none",s.setAttribute("class","e-diagram-layer");var o=Bi("g",{id:this.element.id+"_diagramLayer"}),a=Bi("g",{});this.diagramLayer=o,s.style["pointer-events"]="all",a.appendChild(o),s.appendChild(a),this.diagramLayerDiv.appendChild(s)}else this.diagramLayer=bo.createCanvas(this.element.id+"_diagram",e.width,e.height),Za(this.diagramLayer,"position:absolute;left:0px;top:0px;"),this.diagramLayerDiv.appendChild(this.diagramLayer);this.diagramCanvas.appendChild(this.diagramLayerDiv)},t.prototype.initLayers=function(){var e="position:absolute;top:0px;left:0px;overflow:hidden;pointer-events:none;",r=document.getElementById(this.element.id).getBoundingClientRect(),s=function boe(){var n=Tt("div",{style:"visibility:hidden; width: 100px"});document.body.appendChild(n);var t=n.getBoundingClientRect().width;n.style.overflow="scroll";var e=Tt("div",{style:"width:100%"});n.appendChild(e);var i=e.getBoundingClientRect().width;return n.parentNode.removeChild(n),t-i}();this.scroller.scrollerWidth=s,this.scroller.setViewPortSize(r.width,r.height),this.renderRulers();var o="measureElement";window[""+o]&&(window[""+o]=null,document.getElementById("measureElement").remove()),function BF(){var n="measureElement";if(window[""+n])window[""+n].usageCount+=1;else{var t=Tt("div",{id:"measureElement",style:"visibility:hidden ; height: 0px ; width: 0px; overflow: hidden;"}),e=Tt("span",{style:"display:inline-block ; line-height: normal"});t.appendChild(e);var i=Tt("img",{alt:"measureElementImage",src:"data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7"});t.appendChild(i);var r=document.createElementNS("http://www.w3.org/2000/svg","svg");r.setAttribute("xmlns:xlink","http://www.w3.org/1999/xlink"),t.appendChild(r);var s=document.createElementNS("http://www.w3.org/2000/svg","path");s.setAttribute("d",""),r.appendChild(s),document.createTextNode("");var a=document.createElementNS("http://www.w3.org/2000/svg","text");a.setAttributeNS("http://www.w3.org/XML/1998/namespace","xml:space","preserve"),r.appendChild(a),window[""+n]=t,window[""+n].usageCount=1,document.body.appendChild(t);var l="measureElementCount";window[""+l]?window[""+l]++:window[""+l]=1}}(),this.renderBackgroundLayer(r,e),this.renderGridLayer(r,e),this.renderDiagramLayer(r,e),this.renderHTMLLayer(r,e),this.renderPortsExpandLayer(r,e),this.renderNativeLayer(r,e),this.renderAdornerLayer(r,e),this.renderHiddenUserHandleTemplateLayer(r)},t.prototype.renderAdornerLayer=function(e,i){var r=Tt("div",{id:this.element.id+"_diagramAdornerLayer",style:"width:"+e.width+"px;height:"+e.height+"px;"+i}),s=Tt("div",{id:this.element.id+"_diagramUserHandleLayer",style:"width:"+e.width+"px;height:"+e.height+"px;"+i});s.setAttribute("class","e-userHandle-layer"),r.appendChild(s);var o=this.createSvg(this.element.id+"_diagramAdorner_svg",e.width,e.height);o.setAttribute("class","e-adorner-layer"),o.style["pointer-events"]="none",this.adornerLayer=Bi("g",{id:this.element.id+"_diagramAdorner"}),this.adornerLayer.style[" pointer-events"]="all",o.appendChild(this.adornerLayer),r.appendChild(o),this.diagramCanvas.appendChild(r);var a=Bi("g",{id:this.element.id+"_SelectorElement"});this.adornerLayer.appendChild(a),ai(o,{style:"pointer-events:none;"})},t.prototype.renderPortsExpandLayer=function(e,i){var r=this.createSvg(this.element.id+"_diagramPorts_svg",e.width,e.height);r.setAttribute("class","e-ports-expand-layer");var s=Bi("g",{id:this.element.id+"_diagramPorts",class:"e-ports-layer",style:"pointer-events: all;"});r.appendChild(s);var o=Bi("g",{id:this.element.id+"_diagramExpander",class:"e-expand-layer",style:"pointer-events: all;"});r.appendChild(o),this.diagramCanvas.appendChild(r),ai(r,{style:i})},t.prototype.renderHTMLLayer=function(e,i){this.htmlLayer=Tt("div",{id:this.element.id+"_htmlLayer",style:"width:"+e.width+"px; height:"+e.height+"px;position:absolute;top:0px;left:0px;overflow:hidden;pointer-events:none;",class:"e-html-layer"});var r=Tt("div",{id:this.element.id+"_htmlLayer_div",style:"position:absolute;top:0px;left:0px;pointer-events:all;"});this.htmlLayer.appendChild(r),this.diagramCanvas.appendChild(this.htmlLayer)},t.prototype.renderNativeLayer=function(e,i){var r=this.createSvg(this.element.id+"_nativeLayer_svg",e.width,e.height),s=Bi("g",{id:this.element.id+"_nativeLayer",style:"pointer-events:all;"});r.appendChild(s),this.diagramLayerDiv.appendChild(r),ai(r,{class:"e-native-layer",style:i})},t.prototype.createSvg=function(e,i,r){var s=document.createElementNS("http://www.w3.org/2000/svg","svg");return ai(s,{id:e,width:i,height:r}),s},t.prototype.updateBazorShape=function(){for(var e=0;e1,i=[],r={},s={},o=[],a=0,l=this.nodes;a0||b&&b.children&&b.children.length>0)&&(M=!1),S&&S.wrapper&&b&&b.wrapper&&M?this.initConnectors(r[""+h],f):i.push(r[""+h])}else b=r[y.targetID],(S=r[y.sourceID])&&S.children&&S.children.length>0||b&&b.children&&b.children.length>0?i.push(r[""+h]):this.initConnectors(r[""+h],f);else r[""+h].children?o.push(h):r[""+h].shape instanceof dT&&r[""+h].shape.activity.subProcess.processes&&r[""+h].shape.activity.subProcess.processes.length>0?s[r[""+h].id]=h:this.initNodes(r[""+h],f);if(this.bpmnModule)for(var w=0,C=this.bpmnModule.bpmnTextAnnotationConnector;w-1&&-1===r.indexOf(c)&&-1===s.indexOf(c)&&r.splice(0,0,c);-1===r.indexOf(o)&&s.push(o)}return r.concat(s)},t.prototype.addToLayer=function(e,i){var r;if(i&&(r=this.commandHandler.getObjectLayer(e.id)),(!i||!r)&&-1===this.activeLayer.objects.indexOf(e.id)&&this.activeLayer.objects.push(e.id),(e instanceof te||e instanceof de)&&("SwimLane"!==e.shape.type||e.children&&e.children.length>0)){if(e.parentId){var s=this.swimlaneZIndexTable[e.parentId],o=this.swimlaneChildTable[e.id];(s&&-1!==s||o&&-1!==o)&&(e.zIndex=this.swimlaneChildTable[e.id])}e instanceof de&&e.sourceID&&e.targetID?-1!==this.activeLayer.objects.indexOf(e.sourceID)&&-1!==this.activeLayer.objects.indexOf(e.targetID)&&this.setZIndex(r||this.activeLayer,e):this.setZIndex(r||this.activeLayer,e)}},t.prototype.updateLayer=function(e){for(var i=0,r=Object.keys(e.layers);i0)for(r=0;rs;l--)r.zIndexTable[parseInt(l.toString(),10)]=r.zIndexTable[l-1],this.nameTable[r.zIndexTable[parseInt(l.toString(),10)]]&&(this.nameTable[r.zIndexTable[parseInt(l.toString(),10)]].zIndex=l);r.zIndexTable[parseInt(a.toString(),10)]=i.id}}},t.prototype.initializeDiagramLayers=function(){for(var e=0;ethis.layers[parseInt(a.toString(),10)].zIndex&&(i=this.layers[parseInt(e.toString(),10)],this.layers[parseInt(e.toString(),10)]=this.layers[parseInt(a.toString(),10)],this.layers[parseInt(a.toString(),10)]=i);0===this.layers.length&&this.commandHandler.addLayer({id:"default_layer",visible:!0,lock:!1,objects:[],zIndex:0,objectZIndex:-1,zIndexTable:{}},null,!0),this.setActiveLayer(this.layers[this.layers.length-1].id)},t.prototype.resetTool=function(){this.eventHandler.resetTool()},t.prototype.initObjectExtend=function(e,i,r){if(r){var s=this.commandHandler.checkBoundaryConstraints(void 0,void 0,e.wrapper.bounds,!0);if("SwimLane"===e.shape.type)for(var o=0,a=Object.keys(i.zIndexTable);o0)&&this.setZIndex(i,e)),e instanceof te){if(r){if("helper"!==e.id&&(o=Zi(this.getNodeDefaults))){if((a=o(e,this))&&a.ports)for(var l=0;l0)for(l=0;l0&&!e.container||e.processId){var r=this.nameTable[e.id];if(!(this.realActions&$i.PreventScale||this.realActions&$i.PreventDrag)){if(r.offsetX&&(this.realActions&$i.EnableGroupAction||!(this.diagramActions&ee.UndoRedo||this.diagramActions&ee.ToolAction||this.diagramActions&ee.PublicMethod))){this.realActions|=$i.PreventScale;var s=r.offsetX-e.wrapper.offsetX;r.offsetX=e.wrapper.offsetX;var o=r.offsetY-e.wrapper.offsetY;r.offsetY=e.wrapper.offsetY,s+o!==0&&this.drag(r,s,o),this.realActions&=~$i.PreventScale}else r.offsetX=e.wrapper.offsetX;r.offsetY&&(this.realActions&$i.EnableGroupAction||!(this.diagramActions&ee.UndoRedo||this.diagramActions&ee.ToolAction||this.diagramActions&ee.PublicMethod))?(this.realActions|=$i.PreventScale,o=r.offsetY-e.wrapper.offsetY,r.offsetY=e.wrapper.offsetY,this.drag(r,0,o),this.realActions&=~$i.PreventScale):r.offsetY=e.wrapper.offsetY,this.diagramActions&&(r.width=e.wrapper.actualSize.width,r.height=e.wrapper.actualSize.height)}}i&&e.children&&e.children.length>0&&(void 0!==this.nameTable[e.id].width?this.scaleObject(e,this.nameTable[e.id].width,!0):this.nameTable[e.id].width=e.wrapper.actualSize.width,void 0!==this.nameTable[e.id].height?this.scaleObject(e,this.nameTable[e.id].height,!1):this.nameTable[e.id].height=e.wrapper.actualSize.height)},t.prototype.initNode=function(e,i,r){var a,p,s=e.initContainer(),o=new Ii;if(this.diagramSettings.inversedAlignment||(s.inversedAlignment=!1),s.children||(s.children=[]),e.children){s.measureChildren=!1,o.id=e.id+"group_container",o.style.fill=e.shape&&"SwimLane"===e.shape.type?e.style.fill:"none",o.style.strokeColor="none",o.horizontalAlignment="Stretch",o.verticalAlignment="Stretch",o.pivot=e.pivot,s.style=e.style,s.padding.left=e.padding.left,s.padding.right=e.padding.right,s.padding.top=e.padding.top,s.padding.bottom=e.padding.bottom,o.children=[],o.preventContainer=!0,e.container&&(o.relativeMode="Object");var l=!!(e.ports&&e.ports.length>0);if(m(e.container)&&!l&&s.children.push(o),e.container&&"Grid"===e.container.type)for(var h=0;h0&&e.wrapper.children[0]instanceof Wv){if(this.setZIndex(this.activeLayer,e),this.connectors.length>0)for(h=0;h0?i.phases.length:0,v="Horizontal"===i.orientation,y=v?i.phases.length||1:s.length+1,S=v?(i.header&&i.hasHeader?1:0)+(i.phases.length>0?1:0)+i.lanes.length:(i.header&&i.hasHeader?1:0)+i.phases.length;if(0===h&&!v&&i.lanes.length&&(S+=1),v?(a=(i.header&&i.hasHeader?1:0)+(h>0?1:0),l=0):(a=i.header&&i.hasHeader?1:0,l=h>0?1:0),s.length>0)for(o+=i.header&&i.hasHeader?i.header.height:0,p=0;pl?d.margin.left=d.margin.left-(u.bounds.left-e.bounds.left):u.children[0].children[1].actualSize.width+r>=d.margin.left&&(d.margin.left=u.children[0].children[1].actualSize.width+r),d.margin.lefta?d.margin.top=d.margin.top-(u.bounds.top-o):u.children[0].children[1].actualSize.height+r>=d.margin.top&&(d.margin.top=u.children[0].children[1].actualSize.height+r),d.margin.left0)for(o=0;o0&&this.updateChildPosition(e)},t.prototype.addBpmnAnnotationConnector=function(e,i){if(e.parentObj instanceof t||e.parentObj instanceof Bd){var r=e.shape,o=""!==r.textAnnotation.textAnnotationTarget&&this.nameTable[r.textAnnotation.textAnnotationTarget],a=o?this.nameTable[r.textAnnotation.textAnnotationTarget]:null,l=null!=a?a.wrapper:null,h=e.ports[0],c={x:0,y:0};switch(r.textAnnotation.textAnnotationDirection){case"Left":h.offset={x:0,y:.5},c.x=i.bounds.left-40,c.y=i.bounds.bottom+30;break;case"Right":h.offset={x:1,y:.5},c.x=i.bounds.right+40,c.y=i.bounds.bottom+30;break;case"Top":h.offset={x:.5,y:0},c.x=i.bounds.right+30,c.y=i.bounds.top-40;break;case"Bottom":h.offset={x:.5,y:1},c.x=i.bounds.right+30,c.y=i.bounds.bottom+40;break;default:h.offset={x:0,y:.5},c.x=i.bounds.left-40,c.y=i.bounds.bottom+30,o&&null!=i&&null!=l&&(i.bounds.left>l.bounds.right?h.offset={x:0,y:.5}:i.bounds.rightl.bounds.top?h.offset={x:.5,y:0}:i.bounds.top0&&this.updateChildPosition(r)}},t.prototype.canExecute=function(){return!0},t.prototype.updateStackProperty=function(e,i,r){e.container&&"Stack"===e.container.type&&(i.width||(i.wrapper.horizontalAlignment="Stretch",i.horizontalAlignment="Stretch"),i.height||(i.verticalAlignment="Stretch",i.wrapper.verticalAlignment="Stretch"),r&&"UmlClassifier"===e.shape.type&&(i.umlIndex=r))},t.prototype.initViews=function(){this.isLoading||(this.views.push(this.element.id),this.views[this.element.id]=this)},t.prototype.initCommands=function(){var e=this.commandManager.commands,i={copy:{execute:this.copyCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.C,keyModifiers:pt.Control}},paste:{execute:this.pasteCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.V,keyModifiers:pt.Control}},cut:{execute:this.cutCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.X,keyModifiers:pt.Control}},delete:{execute:this.removeCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Delete}},selectAll:{execute:this.selectAll.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.A,keyModifiers:pt.Control}},undo:{execute:this.undo.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Z,keyModifiers:pt.Control}},redo:{execute:this.redo.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Y,keyModifiers:pt.Control}},nudgeUp:{execute:this.nudgeCommand.bind(this,"Up"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Up},parameter:"up"},nudgeRight:{execute:this.nudgeCommand.bind(this,"Right"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Right},parameter:"right"},nudgeDown:{execute:this.nudgeCommand.bind(this,"Down"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Down},parameter:"down"},nudgeLeft:{execute:this.nudgeCommand.bind(this,"Left"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Left},parameter:"left"},startEdit:{execute:this.startEditCommad.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.F2}},endEdit:{execute:this.endEditCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Escape}},focusToNextItem:{execute:this.navigateItems.bind(this,!0),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Tab}},focusToPreviousItem:{execute:this.navigateItems.bind(this,!1),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Tab,keyModifiers:pt.Shift}},selectFocusedItem:{execute:this.startEditCommad.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Enter}},bold:{execute:this.fontStyleCommand.bind(this,"bold"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.B,keyModifiers:pt.Control}},italic:{execute:this.fontStyleCommand.bind(this,"italic"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.I,keyModifiers:pt.Control}},underline:{execute:this.fontStyleCommand.bind(this,"underline"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.U,keyModifiers:pt.Control}},duplicate:{execute:this.duplicateCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.D,keyModifiers:pt.Control}},group:{execute:this.groupCommand.bind(this,"group"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.G,keyModifiers:pt.Control}},ungroup:{execute:this.groupCommand.bind(this,"ungroup"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.U,keyModifiers:pt.Control|pt.Shift}},rotateClockwise:{execute:this.rotateCommand.bind(this,"clockwise"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.R,keyModifiers:pt.Control}},rotateAntiClockwise:{execute:this.rotateCommand.bind(this,"antiClockwise"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.L,keyModifiers:pt.Control}},flipHorizontal:{execute:this.flipCommand.bind(this,"horizontal"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.H,keyModifiers:pt.Control}},flipVertical:{execute:this.flipCommand.bind(this,"vertical"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.J,keyModifiers:pt.Control}},pointerTool:{execute:this.toolCommand.bind(this,"pointer"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number1,keyModifiers:pt.Control}},textTool:{execute:this.toolCommand.bind(this,"text"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number2,keyModifiers:pt.Control}},connectTool:{execute:this.toolCommand.bind(this,"connect"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number3,keyModifiers:pt.Control}},freeForm:{execute:this.toolCommand.bind(this,"freeForm"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number5,keyModifiers:pt.Control}},lineTool:{execute:this.toolCommand.bind(this,"line"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number6,keyModifiers:pt.Control}},rectangleTool:{execute:this.toolCommand.bind(this,"rectangle"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number8,keyModifiers:pt.Control}},ellipseTool:{execute:this.toolCommand.bind(this,"ellipse"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number9,keyModifiers:pt.Control}},zoomIn:{execute:this.zoomCommand.bind(this,"zoomIn"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Plus,keyModifiers:pt.Control}},zoomOut:{execute:this.zoomCommand.bind(this,"zoomOut"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Minus,keyModifiers:pt.Control}},shiftUp:{execute:this.shiftCommand.bind(this,"Up"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Up,keyModifiers:pt.Shift}},shiftDown:{execute:this.shiftCommand.bind(this,"Down"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Down,keyModifiers:pt.Shift}},shiftLeft:{execute:this.shiftCommand.bind(this,"Left"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Left,keyModifiers:pt.Shift}},shiftRight:{execute:this.shiftCommand.bind(this,"Right"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Right,keyModifiers:pt.Shift}},alignTextCenter:{execute:this.alignCommand.bind(this,"center"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.C,keyModifiers:pt.Control|pt.Shift}},alignTextLeft:{execute:this.alignCommand.bind(this,"right"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.L,keyModifiers:pt.Control|pt.Shift}},alignTextRight:{execute:this.alignCommand.bind(this,"left"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.R,keyModifiers:pt.Control|pt.Shift}},alignTextTop:{execute:this.alignCommand.bind(this,"top"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.E,keyModifiers:pt.Control|pt.Shift}},alignTextCenterVertical:{execute:this.alignCommand.bind(this,"centerVertical"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.M,keyModifiers:pt.Control|pt.Shift}},alignTextBottom:{execute:this.alignCommand.bind(this,"bottom"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.V,keyModifiers:pt.Control|pt.Shift}},alignJustify:{execute:this.alignCommand.bind(this,"justify"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.J,keyModifiers:pt.Control|pt.Shift}},sendToBack:{execute:this.orderCommand.bind(this,"sendToBack"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.B,keyModifiers:pt.Control|pt.Shift}},bringToFront:{execute:this.orderCommand.bind(this,"bringToFront"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.F,keyModifiers:pt.Control|pt.Shift}},sendBackward:{execute:this.orderCommand.bind(this,"sendBackward"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.BracketLeft,keyModifiers:pt.Control}},bringForward:{execute:this.orderCommand.bind(this,"bringForward"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.BracketRight,keyModifiers:pt.Control}}};this.initCommandManager(e,i)},t.prototype.overrideCommands=function(e,i){for(var r,s=0,o=Object.keys(i);se.zIndex){("HTML"===e.shape.type||"Native"===e.shape.type)&&(o="HTML"===e.shape.type?"html":"native"),s=voe(i,r[parseInt(a.toString(),10)].id,o);break}return s},t.prototype.updateDiagramObject=function(e,i,r){for(var s,o="domTable",a=0,l=this.views;a1&&(d=this.commandHandler.getObjectLayer(e.id)),void 0===d||d&&d.visible||r){var u=Io(this.element.id);window[""+o][s.element.id+"_diagramLayer"]||(window[""+o][s.element.id+"_diagramLayer"]=document.getElementById(s.element.id+"_diagramLayer"));var p=window[""+o][s.element.id+"_diagramLayer"];this.diagramActions&ee.Interactions&&this.updateCanupdateStyle(e.wrapper.children,!0);var f=this.getMidPoint(e);this.diagramRenderer.updateNode(e.wrapper,p,u,void 0,i?void 0:this.getZindexPosition(e,s.element.id),f,this.portCenterPoint),this.updateCanupdateStyle(e.wrapper.children,!0)}}},t.prototype.applyMarginBezier=function(e,i){i.cx=i.cx+e.margin.left,i.cx=i.cx-e.margin.right,i.cy=i.cy+e.margin.top,i.cy=i.cy-e.margin.bottom},t.prototype.getMidPoint=function(e){var i;if(e instanceof de&&"Bezier"===e.type){i=[];for(var r=this.getBezierPoints(e),s=z.getLengthFromListOfPoints(r),o=0;o0&&e.updateView(e));var s=Io(e.element.id);this.renderDiagramElements(e.diagramLayer,e.diagramRenderer,s,void 0,void 0,i);for(var o=0;o0&&this.renderBasicElement(e),!this.diagramActions||!(this.diagramActions&ee.Render)||ee.ToolAction&this.diagramActions||Ds(this)||1!==this.scroller.currentZoom?this.refreshElements(e):this.renderTimer||(this.renderTimer=setTimeout(function(){i.refreshElements(e)},40)))},t.prototype.updatePortVisibility=function(e,i,r){var s;if((e instanceof te||e instanceof de)&&(!this.drawingObject||!this.drawingObject.shape)&&to(e)){for(var a=e.ports,l=!1,h=0;h=0&&this.scroller.removeCollection.splice(l,1);var h=this.nameTable[e[parseInt(a.toString(),10)]];this.updateTextElementValue(h),this.diagramRenderer.renderElement(h.wrapper,s,o,void 0,void 0,void 0,void 0,h.zIndex)}for(var c=0;c0?this.scroller.oldCollectionObjects:void 0,b=Object.keys(S||g.zIndexTable);b.sort(function(N,T){return parseInt(""+N,10)-parseInt(""+T,10)});for(var M=0,w=b;M0?h:0)+"px",y=(this.realActions&$i.vScrollbarMoved?0:-(this.scroller.verticalOffset<0?this.scroller.verticalOffset:0))+"px"):(v="0px",y="0px"),this.realActions&$i.hScrollbarMoved&&(this.realActions=this.realActions&~$i.hScrollbarMoved),this.realActions&$i.vScrollbarMoved&&(this.realActions=this.realActions&~$i.vScrollbarMoved)):(v=(l.x<0?h:-this.scroller.horizontalOffset)+"px",y=(l.y<0?c:-this.scroller.verticalOffset)+"px"),this.diagramLayer.style.left=v,this.diagramLayer.style.top=y,A.tx=-l.x/A.scale,A.ty=-l.y/A.scale);var R=!0;if(o&&(R=!1),this.updateTextElementValue(D),this.refreshing&&D.shape.activity&&D.shape.activity.subProcess&&D.shape.activity.subProcess.processes){for(var L=0;L0){var o=s.children[0],a=o.data;(r.isBezierEditing&&this.selectedItems.connectors[0].id===r.id||"Bezier"!==r.type)&&r.getSegmentElement(r,o,"ComplexHierarchicalTree"===this.layout.type||"HierarchicalTree"===this.layout.type?this.layout.orientation:void 0,void 0,!1),o.data!==a&&(s.measure(new me),s.arrange(s.desiredSize),"SVG"===this.mode&&!e&&this.updateDiagramObject(r))}}else this.constraints&rt.Bridging&&console.warn('[WARNING] :: Module "ConnectorBridging" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.setCursor=function(e){this.diagramRenderer.setCursor(this.diagramCanvas,e)},t.prototype.clearCanvas=function(e){var i=e.contentWidth||e.diagramLayer.width/this.scroller.currentZoom,r=e.contentHeight||e.diagramLayer.height/this.scroller.currentZoom;"SVG"!==e.mode&&bo.getContext(e.diagramLayer).clearRect(0,0,i,r)},t.prototype.updateScrollOffset=function(){this.scroller.setScrollOffset(this.diagramCanvas.scrollLeft,this.diagramCanvas.scrollTop),ZI(this),Ds(this)&&this.scroller.virtualizeElements()},t.prototype.setOffset=function(e,i){var r="domTable";window[""+r][this.element.id+"content"]||(window[""+r][this.element.id+"content"]=document.getElementById(this.element.id+"content"));var s=window[""+r][this.element.id+"content"];s&&(s.scrollLeft=e,s.scrollTop=i)},t.prototype.setSize=function(e,i){if(this.diagramLayer&&!this.preventDiagramUpdate){var r=qa(this);e-=r.width,i-=r.height;var s=this.spatialSearch.getPageBounds();s.x*=this.scroller.currentZoom,s.y*=this.scroller.currentZoom,s.width*=this.scroller.currentZoom,s.height*=this.scroller.currentZoom;var o="SVG"===this.mode?1:1.5,a="SVG"===this.mode?vT(this.element.id):this.diagramLayer,h="Canvas"===this.mode&&this.constraints&rt.Virtualization?this.scroller.viewPortHeight:i;a.setAttribute("width",(o*("Canvas"===this.mode&&this.constraints&rt.Virtualization?this.scroller.viewPortWidth:e)).toString()),a.setAttribute("height",(o*h).toString());var c=document.getElementById(this.element.id+"_diagramUserHandleLayer");c&&(c.style.width=e+"px",c.style.height=i+"px");var d={width:e.toString(),height:i.toString()};this.diagramLayerDiv.style.width=e+"px",this.diagramLayerDiv.style.height=i+"px",ai(kF(this.element.id),d),ai(function yoe(n){return xt(n).getElementsByClassName("e-ports-expand-layer")[0]}(this.element.id),d);var u=Pl(this.element.id);ai(u,d),u.parentNode.style.width=e+"px",u.parentNode.style.height=i+"px";var p=_d(this.element.id);ai(p,d),this.diagramRenderer.updateGrid(this.snapSettings,p,this.scroller.transform,this.rulerSettings,this.hRuler,this.vRuler),ai(ST(this.element.id),d),this.htmlLayer.style.width=e+"px",this.htmlLayer.style.height=i+"px","SVG"!==this.mode&&!Ds(this)&&this.refreshDiagramLayer(),"SVG"===this.mode&&Ds(this)&&this.scroller.virtualizeElements()}},t.prototype.transformLayers=function(){var e=this.spatialSearch.getPageBounds();e.x*=this.scroller.currentZoom,e.y*=this.scroller.currentZoom,e.width*=this.scroller.currentZoom,e.height*=this.scroller.currentZoom,this.diagramRenderer.updateGrid(this.snapSettings,_d(this.element.id),this.scroller.transform,this.rulerSettings,this.hRuler,this.vRuler),this.diagramRenderer.transformLayers(this.scroller.transform,"SVG"===this.mode),this.diagramActions&ee.DragUsingMouse||this.updateSelector(),this.renderPageBreaks(e)},t.prototype.removePageBreaks=function(){if(this.diagramLayer){var e=PF(this.element.id);if(e&&e.childNodes)for(var i=e.childNodes.length,r=0;rthis.pageSettings.height&&(e=this.pageSettings.height,this.pageSettings.height=this.pageSettings.width,this.pageSettings.width=e):this.pageSettings.height>this.pageSettings.width&&(e=this.pageSettings.width,this.pageSettings.width=this.pageSettings.height,this.pageSettings.height=e)},t.prototype.setOverview=function(e,i){if(e)e&&(this.views.push(e.id),this.views[e.id]=e,e.renderDocument(e),e.diagramRenderer.setLayers(),e.updateView(e),this.renderNodes(e));else{for(var r=0;r1&&this.updateSelectionRectangle(),this.isProtectedOnChange=s},t.prototype.updateSelectionRectangle=function(){for(var e=cm(this.element.id),i=!1,r=0;r1&&this.updateSelectionRectangle(),this.enableServerDataBinding(e)},t.prototype.renderSelectorForAnnotation=function(e,i){this.diagramRenderer.renderResizeHandle(e.wrapper.children[0],i,e.thumbsConstraints,this.scroller.currentZoom,e.constraints,this.scroller.transform,void 0,to(e.annotation),void 0,void 0,e.handleSize)},t.prototype.drawSelectionRectangle=function(e,i,r,s){this.clearSelectorLayer(),this.diagramRenderer.drawSelectionRectangle(e,i,r,s,this.adornerLayer,this.scroller.transform)},t.prototype.renderHighlighter=function(e){var i=Pl(this.element.id);this.diagramRenderer.renderHighlighter(e,i,this.scroller.transform)},t.prototype.clearHighlighter=function(){var e=Pl(this.element.id),i=e.getElementById(e.id+"_highlighter");i&&i.parentNode.removeChild(i)},t.prototype.getNodesConnectors=function(e){for(var i=0;i0;l--)(a=o[l-1]).parentNode.removeChild(a);if(!ce()){var h=yT(this.element.id).childNodes;for(r=h.length;r>0;r--)h[r-1].parentNode.removeChild(h[r-1])}}},t.prototype.getWrapper=function(e,i){var r;i=e.id+"_"+i;for(var s=e instanceof Ii?e:this.getPortContainer(this.nameTable[e.id]),o=0;o0&&this.applyStyle(e,a=r.annotations)}for(i=0;i0){var a=this.selectedItems.connectors[parseInt(i.toString(),10)].annotations;this.applyStyle(e,a)}},t.prototype.applyStyle=function(e,i){for(var r=0;r0)for(var i=0;i0?r[0].zIndex+(e?1:-1):e?0:this.nodes.length+this.connectors.length-1)<0?i=this.nodes.length+this.connectors.length-1:i===this.nodes.length+this.connectors.length&&(i=0);for(var s=0;s0)for(var s=void 0,o=r.children.length-1;o>=0;o--){var a=r.children[parseInt(o.toString(),10)];i.length>0&&-1!==i.indexOf(a.id.split("_groupElement")[0])&&(r.parentNode.insertBefore(a,s||r),s=a)}r&&r.parentNode.removeChild(r)},t.prototype.deleteGroup=function(e){var r=[];e.children&&(r=this.commandHandler.getChildren(e,[])),this.UpdateBlazorDiagramModelCollection(e);for(var s=0,o=r;s0)for(var xe=0;xe0)if("Path"===t.shape.type&&void 0!==n.shape.data)t.wrapper.children[0].data=n.shape.data;else if("Text"===t.shape.type&&void 0!==n.shape.content)t.wrapper.children[0].content=n.shape.content;else if("Image"===t.shape.type&&void 0!==n.shape.source)t.wrapper.children[0].source=n.shape.source;else if("Native"===t.shape.type){for(var r=void 0,s=0;s-1)&&(this.diagramActions&ee.PreventZIndexOnDragging?this.updateDiagramObject(e,!0):this.updateDiagramObject(e)),!s&&d&&(this.lineRoutingModule&&this.diagramActions&&this.constraints&rt.LineRouting&&"helper"!==e.id?this.diagramActions&ee.ToolAction||this.lineRoutingModule.renderVirtualRegion(this,!0):this.diagramActions&&this.constraints&rt.LineRouting&&"helper"!==e.id&&console.warn('[WARNING] :: Module "LineRouting" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),this.updateConnectorEdges(e),"helper"!==e.id&&!(this.diagramActions&ee.ToolAction))))for(var ya=this.spatialSearch.findObjects(e.wrapper.outerBounds),Mo=0;Moe?Math.abs(r-e):Math.abs(e-r),d=s>i?Math.abs(s-i):Math.abs(i-s);(0===c&&0===d||Number.isNaN(c)&&Number.isNaN(d))&&o.laneMargin&&(u=o.margin.left-o.laneMargin.left,p=o.margin.top-o.laneMargin.top);var f=o.width,g=o.height,v=new Ne(0,0,0,0);if(0!==f&&0!==g&&(v=new Ne((0!==r?r:o.offsetX)-f/2,(0!==s?s:o.offsetY)-g/2,f,g)),h){var y=l,b=this.selectedItems.nodes?this.selectedItems.nodes[0]:void 0;if(""!==y.textAnnotation.textAnnotationTarget&&this.nameTable[y.textAnnotation.textAnnotationTarget])if(""===o.parentId||b&&b.shape&&"TextAnnotation"===b.shape.shape){if("Auto"===y.textAnnotation.textAnnotationDirection&&a.children[0]instanceof Ii&&a.children[0].children[0]instanceof Ke){var w=a.children[0],C=document.getElementById(w.id+"_groupElement"),D=document.getElementById(w.children[0].id+"_groupElement");C.removeChild(D),w.children.splice(0,1),this.isProtectedOnChange=!0,this.bpmnModule.setAnnotationPath(v,w,o,y,y.textAnnotation.textAnnotationDirection,this),this.isProtectedOnChange=!1}}else this.isPositionUndo=!0,this.updateTextAnnotationInSwimlane(o,o),this.isPositionUndo=!1;else o.inEdges.length>0&&(x=this.nameTable[""+o.inEdges[0]])&&x.isBpmnAnnotationConnector&&(x.sourcePoint={x:r>e?x.sourcePoint.x+c:x.sourcePoint.x-c,y:s>i?x.sourcePoint.y+d:x.sourcePoint.y-d});this.nodePropertyChange(o,{},R={ports:[{offset:o.ports[0].offset}]})}else for(var L=0,O=o.outEdges;Le?T.offsetX+c:T.offsetX-c,T.offsetY=s>i?T.offsetY+d:T.offsetY-d,R={offsetX:T.offsetX,offsetY:T.offsetY}),this.nodePropertyChange(T,P,R)}}}},t.prototype.updatePorts=function(e,i){if(e&&e.ports.length>0)for(var r=0,s=Object.keys(e.ports);r0)for(var i=0;i0)for(var r=0;r0&&void 0===r.segments&&(e.segments=[]),void 0!==r.shape&&void 0!==e.shape&&e.shape&&"Bpmn"===e.shape.type&&this.bpmnModule&&this.bpmnModule.updateBPMNConnector(e,i,r,this),void 0!==e.constraints?(this.updateThumbConstraints(this.selectedItems.connectors,this.selectedItems),s=!0):s},t.prototype.connectorPropertyChange=function(e,i,r,s,o){if(this.canEnableBlazorObject){var a=$(e);this.insertValue(a,!1)}var d,u,p,f,l=e.wrapper.bounds,h=!1,c=[];if(h=this.connectorProprtyChangeExtend(e,i,r,h),void 0!==r.visible&&this.updateElementVisibility(e.wrapper,e,e.visible),void 0!==r.sourcePoint||void 0!==r.targetPoint||void 0!==r.sourceID||void 0!==r.targetID||void 0!==r.targetPadding||void 0!==r.sourcePortID||void 0!==r.targetPortID||void 0!==r.sourcePadding||void 0!==r.type||void 0!==r.segments||void 0!==r.flip){if(void 0!==r.sourceID&&r.sourceID!==i.sourceID||r.sourcePortID){if(u=this.findInOutConnectPorts(g=this.nameTable[e.sourceID],!1),(!g||Nh(g)||""!==e.sourcePortID&&Ad(u))&&(e.sourceWrapper=g?this.getEndNodeWrapper(g,e,!0):void 0,e.sourcePortID&&void 0===r.sourcePortID&&(e.sourcePortWrapper=g?this.getWrapper(g.wrapper,e.sourcePortID):void 0),this.removePortEdges(this.nameTable[i.sourceID]||g,i.sourcePortID||e.sourcePortID,e.id,!1)),void 0!==r.sourceID&&void 0!==i.sourceID&&""!==i.sourceID){var v=this.nameTable[i.sourceID];void 0!==v&&v.outEdges&&-1!==v.outEdges.indexOf(e.id)&&tm(v.outEdges,e.id)}this.updateEdges(e)}if(void 0!==r.targetID&&r.targetID!==i.targetID){if(d=this.findInOutConnectPorts(y=this.nameTable[r.targetID],!0),(!y||da(y)||""!==e.targetPortID&&Lh(d))&&(e.targetWrapper=y?this.getEndNodeWrapper(y,e,!1):void 0,e.targetPortID&&void 0===r.targetPortID&&(e.targetPortWrapper=y?this.getWrapper(y.wrapper,e.targetPortID):void 0),this.removePortEdges(this.nameTable[i.targetID]||y,i.targetPortID||e.targetPortID,e.id,!0)),void 0!==i&&void 0!==i.targetID&&""!==i.targetID){var S=this.nameTable[i.targetID];void 0!==S&&S.inEdges&&-1!==S.inEdges.indexOf(e.id)&&tm(S.inEdges,e.id)}this.updateEdges(e)}var g,y;void 0!==r.sourcePortID&&r.sourcePortID!==i.sourcePortID&&(e.sourceID&&this.nameTable[e.sourceID]&&(p=this.nameTable[e.sourceID].wrapper),!(g=this.nameTable[e.sourceID])||Nh(g)||""!==e.sourcePortID&&Ad(u)?e.sourcePortWrapper=p?this.getWrapper(p,r.sourcePortID):void 0:""===e.sourcePortID&&!Nh(g)&&(e.sourcePortWrapper=void 0)),void 0!==r.targetPortID&&r.targetPortID!==i.targetPortID&&(e.targetID&&this.nameTable[e.targetID]&&(f=this.nameTable[e.targetID].wrapper),!(y=this.nameTable[e.targetID])||da(y)||""!==e.targetPortID&&Lh(d)?e.targetPortWrapper=f?this.getWrapper(f,r.targetPortID):void 0:""===e.targetPortID&&!da(y)&&(e.targetPortWrapper=void 0)),void 0!==r.flip&&(e.flip=r.flip,SF(e)),"Orthogonal"===e.type&&this.lineRoutingModule&&this.diagramActions&&this.constraints&rt.LineRouting&&!(this.diagramActions&ee.ToolAction)&&"ComplexHierarchicalTree"!==this.layout.type&&(this.lineRoutingModule.renderVirtualRegion(this,!0),e.sourceID!==e.targetID&&e.segments.length>1&&this.lineRoutingModule.refreshConnectorSegments(this,e,!1)),c=this.getPoints(e)}void 0!==r.style&&Ph(r.style,e.wrapper.children[0]),(c.length>0||void 0!==r.sourceDecorator||void 0!==r.targetDecorator&&function _se(n){return-1!==n.indexOf("shape")||-1!==n.indexOf("pathData")||-1!==n.indexOf("width")||-1!==n.indexOf("height")}(Object.keys(r.targetDecorator))||void 0!==r.cornerRadius)&&(Kp(e,c.length>0?c:e.intermediatePoints,this.diagramActions),void 0!==r.type&&(h=!0),c.length>0&&(e.wrapper.measure(new me(e.wrapper.width,e.wrapper.height)),e.wrapper.arrange(e.wrapper.desiredSize),this.updateConnectorAnnotation(e),this.updateConnectorPort(e),this.updateConnectorfixedUserHandles(e),this.updateObject(e,i,r))),(r.sourcePoint||r.targetPoint||r.segments)&&this.diagramActions===ee.Render&&(h=!0),"Bpmn"===e.shape.type&&"Default"===e.shape.sequence&&"Sequence"===e.shape.flow&&this.commandHandler.updatePathElementOffset(e),s||this.updateBridging(),this.updateAnnotations(r,e),this.updateConnectorPorts(r,e),this.updatefixedUserHandle(r,e),e.wrapper.measure(new me(e.wrapper.width,e.wrapper.height)),e.wrapper.arrange(e.wrapper.desiredSize),!1===l.equals(l,e.wrapper.bounds)&&(this.updateQuad(e),"Drag"!==this.eventHandler.currentAction&&this.updateGroupSize(e)),!0===h&&this.checkSelectedItem(e)&&(!(this.diagramActions&ee.ToolAction)||this.diagramActions&ee.UndoRedo)&&this.updateSelector(),this.preventConnectorsUpdate||(!Ds(this)||Ds(this)&&this.scroller.oldCollectionObjects.indexOf(e.id)>-1)&&(this.diagramActions&ee.PreventZIndexOnDragging?this.updateDiagramObject(e,!0):this.updateDiagramObject(e)),this.updateConnectorEdges(e),this.diagramActions&&"New"!==e.status&&(e.status="Update"),this.triggerPropertyChange(o,e,i,r)},t.prototype.removePortEdges=function(e,i,r,s){if(e)for(var o=0;o0&&e.id===s[s.length-1].id&&(r=!0),r},t.prototype.updateDiagramContainerVisibility=function(e,i){if(e instanceof Cs)for(var r=0;r>"),r instanceof Jn&&this.updateAnnotationWrapper(r,s,o,a)),void 0!==e.template&&(r.content=e.template,this.updateAnnotationWrapper(r,s,o,a))},t.prototype.updateAnnotationWrapper=function(e,i,r,s){for(var o=0,a=this.views;o=0&&this.nodes.splice(s,1),delete this.nameTable[""+r]}var o=this.nodes.indexOf(this.nameTable[this.currentSymbol.id]);o>=0&&this.nodes.splice(o,1)}},t.prototype.selectDragedNode=function(e,i,r){this.currentSymbol=e,"SVG"!==this.mode&&this.refreshDiagramLayer(),this.commandHandler.oldSelectedObjects=rm(this),this.commandHandler.select(e),this.eventHandler.mouseDown(i.event),this.eventHandler.mouseMove(i.event,i),this.preventDiagramUpdate=!1,this.updatePage(),r.style.opacity="0"},t.prototype.initDroppables=function(){var s,o,e=this,i={},r={},a="selectedSymbols";this.droppable=new lR(this.element);var l=5;this.droppable.over=function(h){if(e.rulerSettings.showRulers){var c=document.getElementById(e.element.id+"_vRuler"),d=parseFloat(c.style.width);l=d+1}if(0===e.previousSelectedObjects.length&&!e.currentSymbol&&(e.previousSelectedObjects=e.commandHandler.getSelectedObject()),e.commandHandler.PreventConnectorSplit=!0,e.currentSymbol)h.event.touches&&h.event.touches.length&&e.eventHandler.mouseMove(h.event,h.event.touches);else{var u=null;if(!h.dragData&&"drag"===h.name){var p=document.getElementsByClassName("e-dragclone")[0];p&&(u=p)}if(h.dragData||u){var f=void 0,g=void 0;document.getElementById(e.element.id+"content").focus();var v=e.eventHandler.getMousePosition(h.event),y=void 0,S=u||h.dragData.helper,b=S.getAttribute("paletteId"),M=void 0,w=void 0,C=void 0,D=void 0;if(!b&&h.dragData){e.triggerEvent(Ce.dragEnter,A={source:null,element:f,cancel:!1,diagram:e,dragData:h.dragData.draggedElement.ej2_instances[0].dragData,dragItem:f});var x=void 0,R=void 0;if(A.dragItem){if(A.dragItem.sourcePoint&&A.dragItem.targetPoint?R=new de(e,"connectors",A.dragItem,!0):x=new te(e,"nodes",A.dragItem,!0),e.initObject(f=x||R,void 0,void 0,!0),e.enterObject=f,e.enterTable=r,f instanceof te)x.offsetX=v.x+5+x.width*x.pivot.x,x.offsetY=v.y+x.height*x.pivot.y;else if(f instanceof de){var L=Ne.toBounds([f.sourcePoint,f.targetPoint]),O=v.x-L.left,N=v.y-L.top;f.sourcePoint.x+=O,f.sourcePoint.y+=N,f.targetPoint.x+=O,f.targetPoint.y+=N}e.preventDiagramUpdate=!0,e.currentSymbol=f,"SVG"!==e.mode&&e.refreshDiagramLayer(),e.selectDragedNode(f,h,S),delete e.enterObject,delete e.enterTable,e.droppable[""+a]=S,e.allowServerDataBinding=!0}}if(b){var T=document.getElementById(b).ej2_instances[0];if(e.droppable.sourceElement=T,T){var B=T[""+a];e.allowServerDataBinding=!1,y=$(T[""+a]),i=T.childTable;var j=B.wrapper.children[0].children[0];if(D=function Use(n,t,e){var i=wF(n,t,e,"width"),r=wF(n,t,e,"height");return new me(i,r)}(T,y,j),T[""+a]instanceof te){"TextAnnotation"===B.shape.shape?(y.offsetX=v.x+11+D.width*y.pivot.x,y.offsetY=v.y+11+D.height*y.pivot.y):(y.offsetX=v.x+5+D.width*y.pivot.x,y.offsetY=v.y+D.height*y.pivot.y),"Bpmn"===(x=new te(e,"nodes",y,!0)).shape.type&&x.shape.activity.subProcess.processes&&x.shape.activity.subProcess.processes.length&&(x.shape.activity.subProcess.processes=[]),w=x.previewSize,C=T.symbolDragSize;var Q=T.symbolPreview;if(x.width=(M=x.dragSize).width||C.width||w.width||Q.width||x.width,x.height=M.height||C.height||w.height||Q.height||x.height,"SwimLane"===x.shape.type){if(e.diagramActions|=ee.PreventHistory,x.shape.isLane){x.children=[],s={id:"header"+Qe()},"Horizontal"===x.shape.orientation?(s.width=x.shape.lanes[0].header.width,s.height=x.shape.lanes[0].height):(s.width=x.shape.lanes[0].width,s.height=x.shape.lanes[0].header.height),s.style=x.shape.lanes[0].header.style,s.offsetX=v.x+l+s.width/2,s.offsetY=v.y+s.height/2,e.diagramActions|=ee.PreventCollectionChangeOnDragOver,s=e.add(s),o={id:"body"+Qe()},"Horizontal"===x.shape.orientation?(o.width=x.shape.lanes[0].width-s.width,o.height=x.shape.lanes[0].height,o.offsetX=v.x+l+(x.shape.lanes[0].header.width+o.width/2),o.offsetY=v.y+o.height/2):(o.width=x.shape.lanes[0].width,o.height=x.shape.lanes[0].height-s.height,o.offsetX=v.x+l+o.width/2,o.offsetY=v.y+(x.shape.lanes[0].header.height+o.height/2)),o.style=x.shape.lanes[0].style,o=e.add(o);var oe={id:"group"+Qe(),children:[s.id,o.id]};oe.shape=x.shape,oe.width=x.shape.lanes[0].width,oe.height=x.shape.lanes[0].height,oe.previewSize=x.previewSize,oe.dragSize=x.dragSize,oe.addInfo=x.addInfo,x=e.add(oe),e.diagramActions&=~ee.PreventCollectionChangeOnDragOver}e.diagramActions&=~ee.PreventHistory}if(x.shape.isPhase&&((g="Horizontal"===x.shape.orientation)?(x.offsetX=v.x+l+(x.width||j.actualSize.width)/2,x.offsetY=v.y,x.shape.data="M20,"+x.height/2+" L"+(x.width-20)+","+x.height/2+"z",x.height=1):(x.offsetX=v.x+5,x.offsetY=v.y+(x.height||j.actualSize.height)/2,x.shape.data="M"+x.width/2+",20 L"+x.width/2+","+(x.height-20)+"z",x.width=1)),"UmlClassifier"===x.shape.type&&(x.children=x.width=x.height=void 0,y.children=void 0,"Class"===x.shape.classifier&&x.shape.classShape.methods.length<=0&&x.shape.classShape.attributes.length<=0&&(x.shape.classShape.attributes=[{name:"Name",type:"Type",style:{}}]),"Enumeration"===x.shape.classifier&&x.shape.enumerationShape.members.length<=0&&(x.shape.enumerationShape.members=[{name:"Name"}]),"Interface"===x.shape.classifier&&x.shape.interfaceShape.methods.length<=0&&x.shape.interfaceShape.attributes.length<=0&&(x.shape.interfaceShape.attributes=[{name:"Name",type:"Type",style:{}}])),f=x,y.children){var ue=y;r=e.getChildren(ue,{},i),iT(ue,-ue.offsetX,-ue.offsetY,r,!0,e)}}else if(T[""+a]instanceof de){f=new de(e,"connectors",y,!0);var Me=Ne.toBounds([f.sourcePoint,f.targetPoint]),De=v.x-Me.left,xe=v.y-Me.top;f.sourcePoint.x+=De,f.sourcePoint.y+=xe,f.targetPoint.x+=De,f.targetPoint.y+=xe}f.shape.isLane||(f.id+=Qe());var A={source:T,element:f,cancel:!1,diagram:e,dragData:null,dragItem:f};if(e.enterObject=f,e.enterTable=r,e.triggerEvent(Ce.dragEnter,A),f instanceof te&&"SwimLane"===f.shape.type&&f.shape.isLane){var Ie=A.element,Ve=Ie.shape.lanes[0];g="Horizontal"===Ie.shape.orientation;var ot=e.nameTable[f.children[0]],$e=e.nameTable[f.children[1]];w=f.previewSize,C=T.symbolDragSize,Ve.width=(M=f.dragSize).width||C.width||w.width||Ve.width,Ve.height=M.height||C.height||w.height||Ve.height,g?(s.width=Ve.header.width,s.height=Ve.height,o.width=Ve.width-s.width,o.height=Ve.height,o.offsetX=v.x+l+(Ve.header.width+$e.width/2),o.offsetY=v.y+$e.height/2):(s.width=Ve.width,s.height=Ve.header.height,o.width=Ve.width,o.height=Ve.height-s.height,o.offsetX=v.x+l+$e.width/2,o.offsetY=v.y+(Ve.header.height+$e.height/2)),s.offsetX=v.x+l+ot.width/2,s.offsetY=v.y+ot.height/2,f.width=Ve.width,f.height=Ve.height}if(f instanceof te&&f.shape.isPhase&&(g?f.height=1:f.width=1),!e.activeLayer.lock&&!A.cancel){if(e.preventDiagramUpdate=!0,f.children&&e.findChild(f,r),e.preventDiagramUpdate=!0,f.zIndex!==Number.MIN_VALUE&&(f.zIndex=Number.MIN_VALUE),e.initObject(f,void 0,void 0,!0),e.bpmnModule)for(var Mi=0;Mi0&&(S.segments=[]),d=this.add(S,!0)),(S||d)&&(_v(this)||Uv(this))&&this.select([this.nameTable[S[""+b]]],!1,this.previousSelectedObjects),y.target&&y.target instanceof de&&!0===this.enableConnectorSplit&&this.nameTable[S[""+b]]instanceof te&&(this.commandHandler.connectorSplit(this.nameTable[S[""+b]],y.target),this.commandHandler.PreventConnectorSplit=!1))),this.protectPropertyChange(!1),v=this.nameTable[S[""+b]],S.hasTarget&&(S.nodeId=S.hasTarget,this.remove(S)),this.bpmnModule&&v instanceof te&&S.processId&&(v.processId=S.processId,this.bpmnModule.dropBPMNchild(this.nameTable[v.processId],v,this)),y.cancel||this.endGroupAction(),"SVG"!==this.mode&&this.refreshDiagramLayer(),delete this.droppable[""+c]):(this.triggerEvent(Ce.drop,y={source:h.droppedElement,element:void 0,target:this.eventHandler.hoverNode||this.eventHandler.lastObjectUnderMouse||this,cancel:!1,position:void 0}),S=void 0,b="id"),this.droppable[M="selectedSymbols"]&&this.droppable[""+M].parentNode)gt(this.droppable[""+M]);else for(w=document.getElementsByClassName("e-dragclone"),C=0;C0)for(var p=0;p1),e.previousSelectedObject=null}}},t.prototype.getDropEventArgs=function(e){if(this.eventHandler.lastObjectUnderMouse||this.eventHandler.hoverNode){var i=this.eventHandler.lastObjectUnderMouse||this.eventHandler.hoverNode;e.target=fs(i)===de?{connector:i}:{node:i}}else e.target.diagramId=this.element.id},t.prototype.removeChildInNodes=function(e){if(e){if(e.children)for(var i=0;i1){var l=2;if(e.children&&e.children.length>0)for(;e.children.indexOf(i.objects[s-l])>-1;)l++;this.commandHandler.moveSvgNode(e.id,i.objects[s-l]),this.commandHandler.moveSvgNode(i.objects[s-l],e.id)}else if(o){var h=this.commandHandler.getLayer(this.layerZIndexTable[o.zIndex]).objects[0];h?(this.commandHandler.moveSvgNode(e.id,h),this.commandHandler.updateNativeNodeIndex(e.id,h)):this.moveObjectsUp(e,i)}else this.moveObjectsUp(e,i)},t.prototype.moveObjectsUp=function(e,i){for(var r,s=this.layers.length-1;s>=0;s--)if(r=this.layers[parseInt(s.toString(),10)],i.id!==r.id){var o=this.commandHandler.getLayer(this.layerZIndexTable[r.zIndex]).objects[r.objects.length-1];if(o){this.commandHandler.moveSvgNode(e.id,o),this.commandHandler.moveSvgNode(o,e.id);break}}},t.prototype.insertData=function(e){return this.crudOperation(e,"create",this.getNewUpdateNodes("New"))},t.prototype.updateData=function(e){return this.crudOperation(e,"update",this.getNewUpdateNodes("Update"))},t.prototype.removeData=function(e){return this.crudOperation(e,"destroy",this.getDeletedNodes())},t.prototype.crudOperation=function(e,i,r){if(e){var s=this.parameterMap(e,!(e instanceof de));if(s){var o=e instanceof de?this.dataSourceSettings.connectionDataSource.crudAction[""+i]:this.dataSourceSettings.crudAction[""+i];this.raiseAjaxPost(JSON.stringify(s),o)}return s}var a=r;return this.processCrudCollection(a,this.dataSourceSettings.crudAction[""+i],this.dataSourceSettings.connectionDataSource.crudAction[""+i]),a},t.prototype.processCrudCollection=function(e,i,r){if(e.nodes){var s=[],o=void 0;for(o=0;o0&&this.raiseAjaxPost(JSON.stringify(s),i)}if(e.connectors){for(s=[],o=void 0,o=0;o0&&this.raiseAjaxPost(JSON.stringify(s),r)}},t.prototype.parameterMap=function(e,i){var s,r={},o=i?this.dataSourceSettings:this.dataSourceSettings.connectionDataSource;if(o.id&&(r[o.id]=e.id),o.sourcePointX&&o.sourcePointY&&(r[o.sourcePointX]=e.sourcePoint.x,r[o.sourcePointY]=e.sourcePoint.y),o.targetPointX&&o.targetPointY&&(r[o.targetPointX]=e.targetPoint.x,r[o.targetPointY]=e.targetPoint.y),o.sourceID&&(r[o.sourceID]=e.sourceID),o.targetID&&(r[o.targetID]=e.targetID),o.crudAction&&o.crudAction.customFields&&o.crudAction.customFields.length>0)for(s=0;s"u"||(y.innerHTML=v.innerHTML?v.innerHTML:"",void 0!==v.className&&(y.className=v.className),void 0!==v.id&&(y.id=v.id),void 0!==v.styles&&y.setAttribute("style",v.styles),void 0!==e.ngAttr&&y.setAttribute(e.ngAttr,""),void 0!==v.attrs&&Fe(y,v.attrs)),y};for(var i=0,r=e.tags;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s}!function TZ(n){DC.compile=n.compile}({compile:function Uae(n,t){if("string"==typeof n||"function"==typeof n&&n.prototype&&n.prototype.CSPTemplate)return _ae(n,t);var e=n.elementRef.nativeElement._viewContainerRef,i=n.elementRef.nativeElement.propName;return function(r,s,o){var l=e||s.viewContainerRef,h=l.createEmbeddedView(n,{$implicit:r});/EJS-MENTION|EJS-DROPDOWNLIST/.test(Y("currentInstance.element.nodeName",l))||/E-TABITEM/.test(Y("element.nativeElement.nodeName",l))?h.detectChanges():h.markForCheck();var c=s&&s.registeredTemplate?s.registeredTemplate:Y("currentInstance.registeredTemplate",l);return typeof c["".concat(o=o&&s.registeredTemplate?o:i)]>"u"&&(c["".concat(o)]=[]),c["".concat(o)].push(h),h.rootNodes}}});const Qae=["annotationTemplate"],Gae=["nodeTemplate"],Xae=["userHandleTemplate"];let qae=["addInfo","id","lock","objects","visible","zIndex"],$ae=[],Zae=(()=>{class n extends Hh{constructor(e){super(),this.viewContainerRef=e,Rl("currentInstance",this,this.viewContainerRef),this.registerEvents($ae),this.directivePropList=qae}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-layer"]],inputs:{addInfo:"addInfo",id:"id",lock:"lock",objects:"objects",visible:"visible",zIndex:"zIndex"},features:[yn]}),n})(),Jae=(()=>{class n extends Bh{constructor(){super("layers")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-layers"]],contentQueries:function(e,i,r){if(1&e&&dn(r,Zae,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),Kae=["action","cursor"],ele=[],tle=(()=>{class n extends Hh{constructor(e){super(),this.viewContainerRef=e,Rl("currentInstance",this,this.viewContainerRef),this.registerEvents(ele),this.directivePropList=Kae}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-cursormap"]],inputs:{action:"action",cursor:"cursor"},features:[yn]}),n})(),ile=(()=>{class n extends Bh{constructor(){super("customcursor")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-cursormaps"]],contentQueries:function(e,i,r){if(1&e&&dn(r,tle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),rle=["alignment","cornerRadius","displacement","fill","handleStrokeColor","handleStrokeWidth","height","iconStrokeColor","iconStrokeWidth","id","offset","padding","pathData","tooltip","visibility","width"],nle=[],sle=(()=>{class n extends Hh{constructor(e){super(),this.viewContainerRef=e,Rl("currentInstance",this,this.viewContainerRef),this.registerEvents(nle),this.directivePropList=rle}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-connector-fixeduserhandle"]],inputs:{alignment:"alignment",cornerRadius:"cornerRadius",displacement:"displacement",fill:"fill",handleStrokeColor:"handleStrokeColor",handleStrokeWidth:"handleStrokeWidth",height:"height",iconStrokeColor:"iconStrokeColor",iconStrokeWidth:"iconStrokeWidth",id:"id",offset:"offset",padding:"padding",pathData:"pathData",tooltip:"tooltip",visibility:"visibility",width:"width"},features:[yn]}),n})(),ole=(()=>{class n extends Bh{constructor(){super("fixeduserhandles")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-connector-fixeduserhandles"]],contentQueries:function(e,i,r){if(1&e&&dn(r,sle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),ale=["addInfo","alignment","annotationType","constraints","content","displacement","dragLimit","height","horizontalAlignment","hyperlink","id","margin","offset","rotateAngle","rotationReference","segmentAngle","style","template","tooltip","type","verticalAlignment","visibility","width"],lle=[],hle=(()=>{class n extends Hh{constructor(e){super(),this.viewContainerRef=e,Rl("currentInstance",this,this.viewContainerRef),this.registerEvents(lle),this.directivePropList=ale}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-connector-annotation"]],inputs:{addInfo:"addInfo",alignment:"alignment",annotationType:"annotationType",constraints:"constraints",content:"content",displacement:"displacement",dragLimit:"dragLimit",height:"height",horizontalAlignment:"horizontalAlignment",hyperlink:"hyperlink",id:"id",margin:"margin",offset:"offset",rotateAngle:"rotateAngle",rotationReference:"rotationReference",segmentAngle:"segmentAngle",style:"style",template:"template",tooltip:"tooltip",type:"type",verticalAlignment:"verticalAlignment",visibility:"visibility",width:"width"},features:[yn]}),n})(),cle=(()=>{class n extends Bh{constructor(){super("annotations")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-connector-annotations"]],contentQueries:function(e,i,r){if(1&e&&dn(r,hle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),dle=["addInfo","allowNodeOverlap","annotations","bezierSettings","bridgeSpace","connectionPadding","connectorSpacing","constraints","cornerRadius","dragSize","excludeFromLayout","fixedUserHandles","flip","flipMode","hitPadding","id","margin","maxSegmentThumb","ports","previewSize","segmentThumbShape","segmentThumbSize","segments","shape","sourceDecorator","sourceID","sourcePadding","sourcePoint","sourcePortID","style","symbolInfo","targetDecorator","targetID","targetPadding","targetPoint","targetPortID","tooltip","type","visible","wrapper","zIndex"],ule=[],v_=(()=>{class n extends Hh{constructor(e){super(),this.viewContainerRef=e,this.tags=["fixedUserHandles","annotations"],Rl("currentInstance",this,this.viewContainerRef),this.registerEvents(ule),this.directivePropList=dle}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-connector"]],contentQueries:function(e,i,r){if(1&e&&(dn(r,ole,5),dn(r,cle,5)),2&e){let s;Kr(s=en())&&(i.childFixedUserHandles=s.first),Kr(s=en())&&(i.childAnnotations=s.first)}},inputs:{addInfo:"addInfo",allowNodeOverlap:"allowNodeOverlap",annotations:"annotations",bezierSettings:"bezierSettings",bridgeSpace:"bridgeSpace",connectionPadding:"connectionPadding",connectorSpacing:"connectorSpacing",constraints:"constraints",cornerRadius:"cornerRadius",dragSize:"dragSize",excludeFromLayout:"excludeFromLayout",fixedUserHandles:"fixedUserHandles",flip:"flip",flipMode:"flipMode",hitPadding:"hitPadding",id:"id",margin:"margin",maxSegmentThumb:"maxSegmentThumb",ports:"ports",previewSize:"previewSize",segmentThumbShape:"segmentThumbShape",segmentThumbSize:"segmentThumbSize",segments:"segments",shape:"shape",sourceDecorator:"sourceDecorator",sourceID:"sourceID",sourcePadding:"sourcePadding",sourcePoint:"sourcePoint",sourcePortID:"sourcePortID",style:"style",symbolInfo:"symbolInfo",targetDecorator:"targetDecorator",targetID:"targetID",targetPadding:"targetPadding",targetPoint:"targetPoint",targetPortID:"targetPortID",tooltip:"tooltip",type:"type",visible:"visible",wrapper:"wrapper",zIndex:"zIndex"},features:[yn]}),n})(),m_=(()=>{class n extends Bh{constructor(){super("connectors")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-connectors"]],contentQueries:function(e,i,r){if(1&e&&dn(r,v_,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),ple=["cornerRadius","fill","handleStrokeColor","handleStrokeWidth","height","iconStrokeColor","iconStrokeWidth","id","margin","offset","padding","pathData","tooltip","visibility","width"],fle=[],gle=(()=>{class n extends Hh{constructor(e){super(),this.viewContainerRef=e,Rl("currentInstance",this,this.viewContainerRef),this.registerEvents(fle),this.directivePropList=ple}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-node-fixeduserhandle"]],inputs:{cornerRadius:"cornerRadius",fill:"fill",handleStrokeColor:"handleStrokeColor",handleStrokeWidth:"handleStrokeWidth",height:"height",iconStrokeColor:"iconStrokeColor",iconStrokeWidth:"iconStrokeWidth",id:"id",margin:"margin",offset:"offset",padding:"padding",pathData:"pathData",tooltip:"tooltip",visibility:"visibility",width:"width"},features:[yn]}),n})(),vle=(()=>{class n extends Bh{constructor(){super("fixeduserhandles")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-node-fixeduserhandles"]],contentQueries:function(e,i,r){if(1&e&&dn(r,gle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),mle=["addInfo","annotationType","constraints","content","dragLimit","height","horizontalAlignment","hyperlink","id","margin","offset","rotateAngle","rotationReference","style","template","tooltip","type","verticalAlignment","visibility","width"],yle=[],Sle=(()=>{class n extends Hh{constructor(e){super(),this.viewContainerRef=e,Rl("currentInstance",this,this.viewContainerRef),this.registerEvents(yle),this.directivePropList=mle}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-node-annotation"]],inputs:{addInfo:"addInfo",annotationType:"annotationType",constraints:"constraints",content:"content",dragLimit:"dragLimit",height:"height",horizontalAlignment:"horizontalAlignment",hyperlink:"hyperlink",id:"id",margin:"margin",offset:"offset",rotateAngle:"rotateAngle",rotationReference:"rotationReference",style:"style",template:"template",tooltip:"tooltip",type:"type",verticalAlignment:"verticalAlignment",visibility:"visibility",width:"width"},features:[yn]}),n})(),Ile=(()=>{class n extends Bh{constructor(){super("annotations")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-node-annotations"]],contentQueries:function(e,i,r){if(1&e&&dn(r,Sle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),ble=["addInfo","connectionDirection","constraints","height","horizontalAlignment","id","inEdges","margin","offset","outEdges","pathData","shape","style","tooltip","verticalAlignment","visibility","width"],Mle=[],wle=(()=>{class n extends Hh{constructor(e){super(),this.viewContainerRef=e,Rl("currentInstance",this,this.viewContainerRef),this.registerEvents(Mle),this.directivePropList=ble}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-node-port"]],inputs:{addInfo:"addInfo",connectionDirection:"connectionDirection",constraints:"constraints",height:"height",horizontalAlignment:"horizontalAlignment",id:"id",inEdges:"inEdges",margin:"margin",offset:"offset",outEdges:"outEdges",pathData:"pathData",shape:"shape",style:"style",tooltip:"tooltip",verticalAlignment:"verticalAlignment",visibility:"visibility",width:"width"},features:[yn]}),n})(),Cle=(()=>{class n extends Bh{constructor(){super("ports")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-node-ports"]],contentQueries:function(e,i,r){if(1&e&&dn(r,wle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),Ele=["addInfo","annotations","backgroundColor","borderColor","borderWidth","branch","children","collapseIcon","columnIndex","columnSpan","columns","constraints","container","data","dragSize","excludeFromLayout","expandIcon","fixedUserHandles","flip","flipMode","height","horizontalAlignment","id","isExpanded","layoutInfo","margin","maxHeight","maxWidth","minHeight","minWidth","offsetX","offsetY","padding","pivot","ports","previewSize","rotateAngle","rowIndex","rowSpan","rows","shadow","shape","style","symbolInfo","tooltip","verticalAlignment","visible","width","wrapper","zIndex"],Dle=[],y_=(()=>{class n extends Hh{constructor(e){super(),this.viewContainerRef=e,this.tags=["fixedUserHandles","annotations","ports"],Rl("currentInstance",this,this.viewContainerRef),this.registerEvents(Dle),this.directivePropList=Ele}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-node"]],contentQueries:function(e,i,r){if(1&e&&(dn(r,vle,5),dn(r,Ile,5),dn(r,Cle,5)),2&e){let s;Kr(s=en())&&(i.childFixedUserHandles=s.first),Kr(s=en())&&(i.childAnnotations=s.first),Kr(s=en())&&(i.childPorts=s.first)}},inputs:{addInfo:"addInfo",annotations:"annotations",backgroundColor:"backgroundColor",borderColor:"borderColor",borderWidth:"borderWidth",branch:"branch",children:"children",collapseIcon:"collapseIcon",columnIndex:"columnIndex",columnSpan:"columnSpan",columns:"columns",constraints:"constraints",container:"container",data:"data",dragSize:"dragSize",excludeFromLayout:"excludeFromLayout",expandIcon:"expandIcon",fixedUserHandles:"fixedUserHandles",flip:"flip",flipMode:"flipMode",height:"height",horizontalAlignment:"horizontalAlignment",id:"id",isExpanded:"isExpanded",layoutInfo:"layoutInfo",margin:"margin",maxHeight:"maxHeight",maxWidth:"maxWidth",minHeight:"minHeight",minWidth:"minWidth",offsetX:"offsetX",offsetY:"offsetY",padding:"padding",pivot:"pivot",ports:"ports",previewSize:"previewSize",rotateAngle:"rotateAngle",rowIndex:"rowIndex",rowSpan:"rowSpan",rows:"rows",shadow:"shadow",shape:"shape",style:"style",symbolInfo:"symbolInfo",tooltip:"tooltip",verticalAlignment:"verticalAlignment",visible:"visible",width:"width",wrapper:"wrapper",zIndex:"zIndex"},features:[yn]}),n})(),S_=(()=>{class n extends Bh{constructor(){super("nodes")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-nodes"]],contentQueries:function(e,i,r){if(1&e&&dn(r,y_,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})();const xle=["animationComplete","click","collectionChange","commandExecute","connectionChange","contextMenuBeforeItemRender","contextMenuClick","contextMenuOpen","created","dataLoaded","doubleClick","dragEnter","dragLeave","dragOver","drop","elementDraw","expandStateChange","fixedUserHandleClick","historyChange","historyStateChange","keyDown","keyUp","load","loaded","mouseEnter","mouseLeave","mouseOver","mouseWheel","onFixedUserHandleMouseDown","onFixedUserHandleMouseEnter","onFixedUserHandleMouseLeave","onFixedUserHandleMouseUp","onImageLoad","onUserHandleMouseDown","onUserHandleMouseEnter","onUserHandleMouseLeave","onUserHandleMouseUp","positionChange","propertyChange","rotateChange","scrollChange","segmentChange","segmentCollectionChange","selectionChange","sizeChange","sourcePointChange","targetPointChange","textEdit"],Tle=[""];let Ale=(()=>{let n=class extends zl{constructor(e,i,r,s){super(),this.ngEle=e,this.srenderer=i,this.viewContainerRef=r,this.injector=s,this.tags=["layers","customCursor","connectors","nodes"],this.element=this.ngEle.nativeElement,this.injectedModules=this.injectedModules||[];try{let o=this.injector.get("DiagramsHierarchicalTree");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsMindMap");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsRadialTree");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsComplexHierarchicalTree");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsDataBinding");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsSnapping");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsPrintAndExport");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsBpmnDiagrams");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsSymmetricLayout");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsConnectorBridging");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsUndoRedo");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsLayoutAnimation");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsDiagramContextMenu");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsLineRouting");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsConnectorEditing");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsLineDistribution");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsEj1Serialization");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsFlowchartLayout");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}this.registerEvents(xle),this.addTwoWay.call(this,Tle),Rl("currentInstance",this,this.viewContainerRef),this.context=new u_}ngOnInit(){this.context.ngOnInit(this)}ngAfterViewInit(){this.context.ngAfterViewInit(this)}ngOnDestroy(){this.context.ngOnDestroy(this)}ngAfterContentChecked(){this.tagObjects[0].instance=this.childLayers,this.childCustomCursor&&(this.tagObjects[1].instance=this.childCustomCursor),this.childConnectors&&(this.tagObjects[2].instance=this.childConnectors),this.childNodes&&(this.tagObjects[3].instance=this.childNodes),this.context.ngAfterContentChecked(this)}};return n.\u0275fac=function(e){return new(e||n)(Ot($c),Ot(hM),Ot(xn),Ot(Wo))},n.\u0275cmp=Fb({type:n,selectors:[["ejs-diagram"]],contentQueries:function(e,i,r){if(1&e&&(dn(r,Qae,5),dn(r,Gae,5),dn(r,Xae,5),dn(r,Jae,5),dn(r,ile,5),dn(r,m_,5),dn(r,S_,5)),2&e){let s;Kr(s=en())&&(i.annotationTemplate=s.first),Kr(s=en())&&(i.nodeTemplate=s.first),Kr(s=en())&&(i.userHandleTemplate=s.first),Kr(s=en())&&(i.childLayers=s.first),Kr(s=en())&&(i.childCustomCursor=s.first),Kr(s=en())&&(i.childConnectors=s.first),Kr(s=en())&&(i.childNodes=s.first)}},inputs:{addInfo:"addInfo",annotationTemplate:"annotationTemplate",backgroundColor:"backgroundColor",bridgeDirection:"bridgeDirection",commandManager:"commandManager",connectorDefaults:"connectorDefaults",connectors:"connectors",constraints:"constraints",contextMenuSettings:"contextMenuSettings",customCursor:"customCursor",dataSourceSettings:"dataSourceSettings",diagramSettings:"diagramSettings",drawingObject:"drawingObject",enableConnectorSplit:"enableConnectorSplit",enablePersistence:"enablePersistence",enableRtl:"enableRtl",fixedUserHandleTemplate:"fixedUserHandleTemplate",getConnectorDefaults:"getConnectorDefaults",getCustomCursor:"getCustomCursor",getCustomProperty:"getCustomProperty",getCustomTool:"getCustomTool",getDescription:"getDescription",getNodeDefaults:"getNodeDefaults",height:"height",historyManager:"historyManager",layers:"layers",layout:"layout",locale:"locale",mode:"mode",nodeDefaults:"nodeDefaults",nodeTemplate:"nodeTemplate",nodes:"nodes",pageSettings:"pageSettings",rulerSettings:"rulerSettings",scrollSettings:"scrollSettings",segmentThumbShape:"segmentThumbShape",segmentThumbSize:"segmentThumbSize",selectedItems:"selectedItems",serializationSettings:"serializationSettings",setNodeTemplate:"setNodeTemplate",snapSettings:"snapSettings",tool:"tool",tooltip:"tooltip",updateSelection:"updateSelection",userHandleTemplate:"userHandleTemplate",width:"width"},outputs:{animationComplete:"animationComplete",click:"click",collectionChange:"collectionChange",commandExecute:"commandExecute",connectionChange:"connectionChange",contextMenuBeforeItemRender:"contextMenuBeforeItemRender",contextMenuClick:"contextMenuClick",contextMenuOpen:"contextMenuOpen",created:"created",dataLoaded:"dataLoaded",doubleClick:"doubleClick",dragEnter:"dragEnter",dragLeave:"dragLeave",dragOver:"dragOver",drop:"drop",elementDraw:"elementDraw",expandStateChange:"expandStateChange",fixedUserHandleClick:"fixedUserHandleClick",historyChange:"historyChange",historyStateChange:"historyStateChange",keyDown:"keyDown",keyUp:"keyUp",load:"load",loaded:"loaded",mouseEnter:"mouseEnter",mouseLeave:"mouseLeave",mouseOver:"mouseOver",mouseWheel:"mouseWheel",onFixedUserHandleMouseDown:"onFixedUserHandleMouseDown",onFixedUserHandleMouseEnter:"onFixedUserHandleMouseEnter",onFixedUserHandleMouseLeave:"onFixedUserHandleMouseLeave",onFixedUserHandleMouseUp:"onFixedUserHandleMouseUp",onImageLoad:"onImageLoad",onUserHandleMouseDown:"onUserHandleMouseDown",onUserHandleMouseEnter:"onUserHandleMouseEnter",onUserHandleMouseLeave:"onUserHandleMouseLeave",onUserHandleMouseUp:"onUserHandleMouseUp",positionChange:"positionChange",propertyChange:"propertyChange",rotateChange:"rotateChange",scrollChange:"scrollChange",segmentChange:"segmentChange",segmentCollectionChange:"segmentCollectionChange",selectionChange:"selectionChange",sizeChange:"sizeChange",sourcePointChange:"sourcePointChange",targetPointChange:"targetPointChange",textEdit:"textEdit"},features:[yn],decls:0,vars:0,template:function(e,i){},encapsulation:2,changeDetection:0}),gb([LT()],n.prototype,"annotationTemplate",void 0),gb([LT()],n.prototype,"nodeTemplate",void 0),gb([LT()],n.prototype,"userHandleTemplate",void 0),n=gb([Bae([u_])],n),n})(),Lle=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Am({type:n}),n.\u0275inj=mf({imports:[[sq]]}),n})();const Nle=["diagram"];let Ole=(()=>{class n{constructor(){this.port1=[{id:"port1",offset:{x:0,y:.5},visibility:Gt.Visible},{id:"port2",offset:{x:.5,y:0},visibility:Gt.Visible}],this.port2=[{id:"port3",offset:{x:0,y:.5},visibility:Gt.Visible},{id:"port4",offset:{x:.5,y:1},visibility:Gt.Visible}]}getInEdges(){console.log(this.diagram.nodes[0].ports[1].inEdges[0])}getOutEdges(){console.log(this.diagram.nodes[0].ports[0].outEdges[0])}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275cmp=Fb({type:n,selectors:[["app-container"]],viewQuery:function(i,r){if(1&i&&function pP(n,t,e){const i=xi();i.firstCreatePass&&(dP(i,new lP(n,t,e),-1),2==(2&t)&&(i.staticViewQueries=!0)),cP(i,Se(),t)}(Nle,5),2&i){let s;Kr(s=en())&&(r.diagram=s.first)}},standalone:!0,features:[PP([]),RP],decls:12,vars:10,consts:[["id","diagram","width","100%","height","580px"],["diagram",""],["id","node1",3,"offsetX","offsetY","width","height","ports"],["id","node2",3,"offsetX","offsetY","width","height","ports"],["id","connector1","type","Orthogonal","sourceID","node1","sourcePortID","port1","targetID","node2","targetPortID","port3"],["id","connector2","type","Orthogonal","sourceID","node2","sourcePortID","port4","targetID","node1","targetPortID","port2"],[3,"click"]],template:function(i,r){1&i&&(id(0,"ejs-diagram",0,1)(2,"e-nodes"),Uy(3,"e-node",2)(4,"e-node",3),rd(),id(5,"e-connectors"),Uy(6,"e-connector",4)(7,"e-connector",5),rd()(),id(8,"button",6),Qy("click",function(){return r.getInEdges()}),gw(9,"Get InEdges"),rd(),id(10,"button",6),Qy("click",function(){return r.getOutEdges()}),gw(11,"Get OutEdges"),rd()),2&i&&(fM(3),Fy("offsetX",250)("offsetY",250)("width",100)("height",100)("ports",r.port1),fM(),Fy("offsetX",250)("offsetY",400)("width",100)("height",100)("ports",r.port2))},dependencies:[Lle,Ale,v_,m_,y_,S_],encapsulation:2})}}return n})();Vd(332),function $q(n,t){return DG({rootComponent:n,...Ez(t)})}(Ole).catch(n=>console.error(n))},332:()=>{!function(Z){const se=Z.performance;function ye(Pi){se&&se.mark&&se.mark(Pi)}function fe(Pi,ht){se&&se.measure&&se.measure(Pi,ht)}ye("Zone");const be=Z.__Zone_symbol_prefix||"__zone_symbol__";function ke(Pi){return be+Pi}const at=!0===Z[ke("forceDuplicateZoneCheck")];if(Z.Zone){if(at||"function"!=typeof Z.Zone.__symbol__)throw new Error("Zone already loaded.");return Z.Zone}let tt=(()=>{class Pi{static{this.__symbol__=ke}static assertZonePatched(){if(Z.Promise!==_o.ZoneAwarePromise)throw new Error("Zone.js has detected that ZoneAwarePromise `(window|global).Promise` has been overwritten.\nMost likely cause is that a Promise polyfill has been loaded after Zone.js (Polyfilling Promise api is not necessary when zone.js is loaded. If you must load one, do so before loading zone.js.)")}static get root(){let F=Pi.current;for(;F.parent;)F=F.parent;return F}static get current(){return Ur.zone}static get currentTask(){return Do}static __load_patch(F,ae,Et=!1){if(_o.hasOwnProperty(F)){if(!Et&&at)throw Error("Already loaded patch: "+F)}else if(!Z["__Zone_disable_"+F]){const qt="Zone:"+F;ye(qt),_o[F]=ae(Z,Pi,cn),fe(qt,qt)}}get parent(){return this._parent}get name(){return this._name}constructor(F,ae){this._parent=F,this._name=ae?ae.name||"unnamed":"",this._properties=ae&&ae.properties||{},this._zoneDelegate=new Lt(this,this._parent&&this._parent._zoneDelegate,ae)}get(F){const ae=this.getZoneWith(F);if(ae)return ae._properties[F]}getZoneWith(F){let ae=this;for(;ae;){if(ae._properties.hasOwnProperty(F))return ae;ae=ae._parent}return null}fork(F){if(!F)throw new Error("ZoneSpec required!");return this._zoneDelegate.fork(this,F)}wrap(F,ae){if("function"!=typeof F)throw new Error("Expecting function got: "+F);const Et=this._zoneDelegate.intercept(this,F,ae),qt=this;return function(){return qt.runGuarded(Et,this,arguments,ae)}}run(F,ae,Et,qt){Ur={parent:Ur,zone:this};try{return this._zoneDelegate.invoke(this,F,ae,Et,qt)}finally{Ur=Ur.parent}}runGuarded(F,ae=null,Et,qt){Ur={parent:Ur,zone:this};try{try{return this._zoneDelegate.invoke(this,F,ae,Et,qt)}catch(Un){if(this._zoneDelegate.handleError(this,Un))throw Un}}finally{Ur=Ur.parent}}runTask(F,ae,Et){if(F.zone!=this)throw new Error("A task can only be run in the zone of creation! (Creation: "+(F.zone||_n).name+"; Execution: "+this.name+")");if(F.state===sr&&(F.type===ts||F.type===Pt))return;const qt=F.state!=lt;qt&&F._transitionTo(lt,ki),F.runCount++;const Un=Do;Do=F,Ur={parent:Ur,zone:this};try{F.type==Pt&&F.data&&!F.data.isPeriodic&&(F.cancelFn=void 0);try{return this._zoneDelegate.invokeTask(this,F,ae,Et)}catch(Ue){if(this._zoneDelegate.handleError(this,Ue))throw Ue}}finally{F.state!==sr&&F.state!==et&&(F.type==ts||F.data&&F.data.isPeriodic?qt&&F._transitionTo(ki,lt):(F.runCount=0,this._updateTaskCount(F,-1),qt&&F._transitionTo(sr,lt,sr))),Ur=Ur.parent,Do=Un}}scheduleTask(F){if(F.zone&&F.zone!==this){let Et=this;for(;Et;){if(Et===F.zone)throw Error(`can not reschedule task to ${this.name} which is descendants of the original zone ${F.zone.name}`);Et=Et.parent}}F._transitionTo(Zr,sr);const ae=[];F._zoneDelegates=ae,F._zone=this;try{F=this._zoneDelegate.scheduleTask(this,F)}catch(Et){throw F._transitionTo(et,Zr,sr),this._zoneDelegate.handleError(this,Et),Et}return F._zoneDelegates===ae&&this._updateTaskCount(F,1),F.state==Zr&&F._transitionTo(ki,Zr),F}scheduleMicroTask(F,ae,Et,qt){return this.scheduleTask(new ft(vi,F,ae,Et,qt,void 0))}scheduleMacroTask(F,ae,Et,qt,Un){return this.scheduleTask(new ft(Pt,F,ae,Et,qt,Un))}scheduleEventTask(F,ae,Et,qt,Un){return this.scheduleTask(new ft(ts,F,ae,Et,qt,Un))}cancelTask(F){if(F.zone!=this)throw new Error("A task can only be cancelled in the zone of creation! (Creation: "+(F.zone||_n).name+"; Execution: "+this.name+")");if(F.state===ki||F.state===lt){F._transitionTo(dr,ki,lt);try{this._zoneDelegate.cancelTask(this,F)}catch(ae){throw F._transitionTo(et,dr),this._zoneDelegate.handleError(this,ae),ae}return this._updateTaskCount(F,-1),F._transitionTo(sr,dr),F.runCount=0,F}}_updateTaskCount(F,ae){const Et=F._zoneDelegates;-1==ae&&(F._zoneDelegates=null);for(let qt=0;qtPi.hasTask(F,ae),onScheduleTask:(Pi,ht,F,ae)=>Pi.scheduleTask(F,ae),onInvokeTask:(Pi,ht,F,ae,Et,qt)=>Pi.invokeTask(F,ae,Et,qt),onCancelTask:(Pi,ht,F,ae)=>Pi.cancelTask(F,ae)};class Lt{constructor(ht,F,ae){this._taskCounts={microTask:0,macroTask:0,eventTask:0},this.zone=ht,this._parentDelegate=F,this._forkZS=ae&&(ae&&ae.onFork?ae:F._forkZS),this._forkDlgt=ae&&(ae.onFork?F:F._forkDlgt),this._forkCurrZone=ae&&(ae.onFork?this.zone:F._forkCurrZone),this._interceptZS=ae&&(ae.onIntercept?ae:F._interceptZS),this._interceptDlgt=ae&&(ae.onIntercept?F:F._interceptDlgt),this._interceptCurrZone=ae&&(ae.onIntercept?this.zone:F._interceptCurrZone),this._invokeZS=ae&&(ae.onInvoke?ae:F._invokeZS),this._invokeDlgt=ae&&(ae.onInvoke?F:F._invokeDlgt),this._invokeCurrZone=ae&&(ae.onInvoke?this.zone:F._invokeCurrZone),this._handleErrorZS=ae&&(ae.onHandleError?ae:F._handleErrorZS),this._handleErrorDlgt=ae&&(ae.onHandleError?F:F._handleErrorDlgt),this._handleErrorCurrZone=ae&&(ae.onHandleError?this.zone:F._handleErrorCurrZone),this._scheduleTaskZS=ae&&(ae.onScheduleTask?ae:F._scheduleTaskZS),this._scheduleTaskDlgt=ae&&(ae.onScheduleTask?F:F._scheduleTaskDlgt),this._scheduleTaskCurrZone=ae&&(ae.onScheduleTask?this.zone:F._scheduleTaskCurrZone),this._invokeTaskZS=ae&&(ae.onInvokeTask?ae:F._invokeTaskZS),this._invokeTaskDlgt=ae&&(ae.onInvokeTask?F:F._invokeTaskDlgt),this._invokeTaskCurrZone=ae&&(ae.onInvokeTask?this.zone:F._invokeTaskCurrZone),this._cancelTaskZS=ae&&(ae.onCancelTask?ae:F._cancelTaskZS),this._cancelTaskDlgt=ae&&(ae.onCancelTask?F:F._cancelTaskDlgt),this._cancelTaskCurrZone=ae&&(ae.onCancelTask?this.zone:F._cancelTaskCurrZone),this._hasTaskZS=null,this._hasTaskDlgt=null,this._hasTaskDlgtOwner=null,this._hasTaskCurrZone=null;const Et=ae&&ae.onHasTask;(Et||F&&F._hasTaskZS)&&(this._hasTaskZS=Et?ae:At,this._hasTaskDlgt=F,this._hasTaskDlgtOwner=this,this._hasTaskCurrZone=ht,ae.onScheduleTask||(this._scheduleTaskZS=At,this._scheduleTaskDlgt=F,this._scheduleTaskCurrZone=this.zone),ae.onInvokeTask||(this._invokeTaskZS=At,this._invokeTaskDlgt=F,this._invokeTaskCurrZone=this.zone),ae.onCancelTask||(this._cancelTaskZS=At,this._cancelTaskDlgt=F,this._cancelTaskCurrZone=this.zone))}fork(ht,F){return this._forkZS?this._forkZS.onFork(this._forkDlgt,this.zone,ht,F):new tt(ht,F)}intercept(ht,F,ae){return this._interceptZS?this._interceptZS.onIntercept(this._interceptDlgt,this._interceptCurrZone,ht,F,ae):F}invoke(ht,F,ae,Et,qt){return this._invokeZS?this._invokeZS.onInvoke(this._invokeDlgt,this._invokeCurrZone,ht,F,ae,Et,qt):F.apply(ae,Et)}handleError(ht,F){return!this._handleErrorZS||this._handleErrorZS.onHandleError(this._handleErrorDlgt,this._handleErrorCurrZone,ht,F)}scheduleTask(ht,F){let ae=F;if(this._scheduleTaskZS)this._hasTaskZS&&ae._zoneDelegates.push(this._hasTaskDlgtOwner),ae=this._scheduleTaskZS.onScheduleTask(this._scheduleTaskDlgt,this._scheduleTaskCurrZone,ht,F),ae||(ae=F);else if(F.scheduleFn)F.scheduleFn(F);else{if(F.type!=vi)throw new Error("Task is missing scheduleFn.");Wt(F)}return ae}invokeTask(ht,F,ae,Et){return this._invokeTaskZS?this._invokeTaskZS.onInvokeTask(this._invokeTaskDlgt,this._invokeTaskCurrZone,ht,F,ae,Et):F.callback.apply(ae,Et)}cancelTask(ht,F){let ae;if(this._cancelTaskZS)ae=this._cancelTaskZS.onCancelTask(this._cancelTaskDlgt,this._cancelTaskCurrZone,ht,F);else{if(!F.cancelFn)throw Error("Task is not cancelable");ae=F.cancelFn(F)}return ae}hasTask(ht,F){try{this._hasTaskZS&&this._hasTaskZS.onHasTask(this._hasTaskDlgt,this._hasTaskCurrZone,ht,F)}catch(ae){this.handleError(ht,ae)}}_updateTaskCount(ht,F){const ae=this._taskCounts,Et=ae[ht],qt=ae[ht]=Et+F;if(qt<0)throw new Error("More tasks executed then were scheduled.");0!=Et&&0!=qt||this.hasTask(this.zone,{microTask:ae.microTask>0,macroTask:ae.macroTask>0,eventTask:ae.eventTask>0,change:ht})}}class ft{constructor(ht,F,ae,Et,qt,Un){if(this._zone=null,this.runCount=0,this._zoneDelegates=null,this._state="notScheduled",this.type=ht,this.source=F,this.data=Et,this.scheduleFn=qt,this.cancelFn=Un,!ae)throw new Error("callback is not defined");this.callback=ae;const Ue=this;this.invoke=ht===ts&&Et&&Et.useG?ft.invokeTask:function(){return ft.invokeTask.call(Z,Ue,this,arguments)}}static invokeTask(ht,F,ae){ht||(ht=this),Ls++;try{return ht.runCount++,ht.zone.runTask(ht,F,ae)}finally{1==Ls&&ct(),Ls--}}get zone(){return this._zone}get state(){return this._state}cancelScheduleRequest(){this._transitionTo(sr,Zr)}_transitionTo(ht,F,ae){if(this._state!==F&&this._state!==ae)throw new Error(`${this.type} '${this.source}': can not transition to '${ht}', expecting state '${F}'${ae?" or '"+ae+"'":""}, was '${this._state}'.`);this._state=ht,ht==sr&&(this._zoneDelegates=null)}toString(){return this.data&&typeof this.data.handleId<"u"?this.data.handleId.toString():Object.prototype.toString.call(this)}toJSON(){return{type:this.type,state:this.state,source:this.source,zone:this.zone.name,runCount:this.runCount}}}const Ei=ke("setTimeout"),ii=ke("Promise"),gi=ke("then");let es,cr=[],Oi=!1;function kr(Pi){if(es||Z[ii]&&(es=Z[ii].resolve(0)),es){let ht=es[gi];ht||(ht=es.then),ht.call(es,Pi)}else Z[Ei](Pi,0)}function Wt(Pi){0===Ls&&0===cr.length&&kr(ct),Pi&&cr.push(Pi)}function ct(){if(!Oi){for(Oi=!0;cr.length;){const Pi=cr;cr=[];for(let ht=0;htUr,onUnhandledError:jr,microtaskDrainDone:jr,scheduleMicroTask:Wt,showUncaughtError:()=>!tt[ke("ignoreConsoleErrorUncaughtError")],patchEventTarget:()=>[],patchOnProperties:jr,patchMethod:()=>jr,bindArguments:()=>[],patchThen:()=>jr,patchMacroTask:()=>jr,patchEventPrototype:()=>jr,isIEOrEdge:()=>!1,getGlobalObjects:()=>{},ObjectDefineProperty:()=>jr,ObjectGetOwnPropertyDescriptor:()=>{},ObjectCreate:()=>{},ArraySlice:()=>[],patchClass:()=>jr,wrapWithCurrentZone:()=>jr,filterProperties:()=>[],attachOriginToPatched:()=>jr,_redefineProperty:()=>jr,patchCallbacks:()=>jr,nativeScheduleMicroTask:kr};let Ur={parent:null,zone:new tt(null,null)},Do=null,Ls=0;function jr(){}fe("Zone","Zone"),Z.Zone=tt}(globalThis);const _l=Object.getOwnPropertyDescriptor,jd=Object.defineProperty,Vd=Object.getPrototypeOf,Wd=Object.create,yb=Array.prototype.slice,pm="addEventListener",$r="removeEventListener",Ul=Zone.__symbol__(pm),Fh=Zone.__symbol__($r),Ts="true",Wi="false",Yd=Zone.__symbol__("");function lf(Z,se){return Zone.current.wrap(Z,se)}function fm(Z,se,ye,fe,be){return Zone.current.scheduleMacroTask(Z,se,ye,fe,be)}const Ji=Zone.__symbol__,_h=typeof window<"u",Uh=_h?window:void 0,gn=_h&&Uh||globalThis,gm="removeAttribute";function Qd(Z,se){for(let ye=Z.length-1;ye>=0;ye--)"function"==typeof Z[ye]&&(Z[ye]=lf(Z[ye],se+"_"+ye));return Z}function hf(Z){return!Z||!1!==Z.writable&&!("function"==typeof Z.get&&typeof Z.set>"u")}const cf=typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope,jh=!("nw"in gn)&&typeof gn.process<"u"&&"[object process]"==={}.toString.call(gn.process),Gd=!jh&&!cf&&!(!_h||!Uh.HTMLElement),df=typeof gn.process<"u"&&"[object process]"==={}.toString.call(gn.process)&&!cf&&!(!_h||!Uh.HTMLElement),jl={},Vh=function(Z){if(!(Z=Z||gn.event))return;let se=jl[Z.type];se||(se=jl[Z.type]=Ji("ON_PROPERTY"+Z.type));const ye=this||Z.target||gn,fe=ye[se];let be;return Gd&&ye===Uh&&"error"===Z.type?(be=fe&&fe.call(this,Z.message,Z.filename,Z.lineno,Z.colno,Z.error),!0===be&&Z.preventDefault()):(be=fe&&fe.apply(this,arguments),null!=be&&!be&&Z.preventDefault()),be};function Vl(Z,se,ye){let fe=_l(Z,se);if(!fe&&ye&&_l(ye,se)&&(fe={enumerable:!0,configurable:!0}),!fe||!fe.configurable)return;const be=Ji("on"+se+"patched");if(Z.hasOwnProperty(be)&&Z[be])return;delete fe.writable,delete fe.value;const ke=fe.get,at=fe.set,tt=se.slice(2);let At=jl[tt];At||(At=jl[tt]=Ji("ON_PROPERTY"+tt)),fe.set=function(Lt){let ft=this;!ft&&Z===gn&&(ft=gn),ft&&("function"==typeof ft[At]&&ft.removeEventListener(tt,Vh),at&&at.call(ft,null),ft[At]=Lt,"function"==typeof Lt&&ft.addEventListener(tt,Vh,!1))},fe.get=function(){let Lt=this;if(!Lt&&Z===gn&&(Lt=gn),!Lt)return null;const ft=Lt[At];if(ft)return ft;if(ke){let Ei=ke.call(this);if(Ei)return fe.set.call(this,Ei),"function"==typeof Lt[gm]&&Lt.removeAttribute(se),Ei}return null},jd(Z,se,fe),Z[be]=!0}function uf(Z,se,ye){if(se)for(let fe=0;fefunction(at,tt){const At=ye(at,tt);return At.cbIdx>=0&&"function"==typeof tt[At.cbIdx]?fm(At.name,tt[At.cbIdx],At,be):ke.apply(at,tt)})}function Sa(Z,se){Z[Ji("OriginalDelegate")]=se}let Ib=!1,qd=!1;function bb(){if(Ib)return qd;Ib=!0;try{const Z=Uh.navigator.userAgent;(-1!==Z.indexOf("MSIE ")||-1!==Z.indexOf("Trident/")||-1!==Z.indexOf("Edge/"))&&(qd=!0)}catch{}return qd}Zone.__load_patch("ZoneAwarePromise",(Z,se,ye)=>{const fe=Object.getOwnPropertyDescriptor,be=Object.defineProperty,at=ye.symbol,tt=[],At=!1!==Z[at("DISABLE_WRAPPING_UNCAUGHT_PROMISE_REJECTION")],Lt=at("Promise"),ft=at("then"),Ei="__creationTrace__";ye.onUnhandledError=Ue=>{if(ye.showUncaughtError()){const He=Ue&&Ue.rejection;He?console.error("Unhandled Promise rejection:",He instanceof Error?He.message:He,"; Zone:",Ue.zone.name,"; Task:",Ue.task&&Ue.task.source,"; Value:",He,He instanceof Error?He.stack:void 0):console.error(Ue)}},ye.microtaskDrainDone=()=>{for(;tt.length;){const Ue=tt.shift();try{Ue.zone.runGuarded(()=>{throw Ue.throwOriginal?Ue.rejection:Ue})}catch(He){gi(He)}}};const ii=at("unhandledPromiseRejectionHandler");function gi(Ue){ye.onUnhandledError(Ue);try{const He=se[ii];"function"==typeof He&&He.call(this,Ue)}catch{}}function cr(Ue){return Ue&&Ue.then}function Oi(Ue){return Ue}function es(Ue){return F.reject(Ue)}const kr=at("state"),Wt=at("value"),ct=at("finally"),_n=at("parentPromiseValue"),sr=at("parentPromiseState"),Zr="Promise.then",ki=null,lt=!0,dr=!1,et=0;function vi(Ue,He){return ge=>{try{cn(Ue,He,ge)}catch(We){cn(Ue,!1,We)}}}const Pt=function(){let Ue=!1;return function(ge){return function(){Ue||(Ue=!0,ge.apply(null,arguments))}}},ts="Promise resolved with itself",_o=at("currentTaskTrace");function cn(Ue,He,ge){const We=Pt();if(Ue===ge)throw new TypeError(ts);if(Ue[kr]===ki){let wt=null;try{("object"==typeof ge||"function"==typeof ge)&&(wt=ge&&ge.then)}catch(Xe){return We(()=>{cn(Ue,!1,Xe)})(),Ue}if(He!==dr&&ge instanceof F&&ge.hasOwnProperty(kr)&&ge.hasOwnProperty(Wt)&&ge[kr]!==ki)Do(ge),cn(Ue,ge[kr],ge[Wt]);else if(He!==dr&&"function"==typeof wt)try{wt.call(ge,We(vi(Ue,He)),We(vi(Ue,!1)))}catch(Xe){We(()=>{cn(Ue,!1,Xe)})()}else{Ue[kr]=He;const Xe=Ue[Wt];if(Ue[Wt]=ge,Ue[ct]===ct&&He===lt&&(Ue[kr]=Ue[sr],Ue[Wt]=Ue[_n]),He===dr&&ge instanceof Error){const mt=se.currentTask&&se.currentTask.data&&se.currentTask.data[Ei];mt&&be(ge,_o,{configurable:!0,enumerable:!1,writable:!0,value:mt})}for(let mt=0;mt{try{const dt=Ue[Wt],$t=!!ge&&ct===ge[ct];$t&&(ge[_n]=dt,ge[sr]=Xe);const li=He.run(mt,void 0,$t&&mt!==es&&mt!==Oi?[]:[dt]);cn(ge,!0,li)}catch(dt){cn(ge,!1,dt)}},ge)}const Pi=function(){},ht=Z.AggregateError;class F{static toString(){return"function ZoneAwarePromise() { [native code] }"}static resolve(He){return He instanceof F?He:cn(new this(null),lt,He)}static reject(He){return cn(new this(null),dr,He)}static withResolvers(){const He={};return He.promise=new F((ge,We)=>{He.resolve=ge,He.reject=We}),He}static any(He){if(!He||"function"!=typeof He[Symbol.iterator])return Promise.reject(new ht([],"All promises were rejected"));const ge=[];let We=0;try{for(let mt of He)We++,ge.push(F.resolve(mt))}catch{return Promise.reject(new ht([],"All promises were rejected"))}if(0===We)return Promise.reject(new ht([],"All promises were rejected"));let wt=!1;const Xe=[];return new F((mt,dt)=>{for(let $t=0;$t{wt||(wt=!0,mt(li))},li=>{Xe.push(li),We--,0===We&&(wt=!0,dt(new ht(Xe,"All promises were rejected")))})})}static race(He){let ge,We,wt=new this((dt,$t)=>{ge=dt,We=$t});function Xe(dt){ge(dt)}function mt(dt){We(dt)}for(let dt of He)cr(dt)||(dt=this.resolve(dt)),dt.then(Xe,mt);return wt}static all(He){return F.allWithCallback(He)}static allSettled(He){return(this&&this.prototype instanceof F?this:F).allWithCallback(He,{thenCallback:We=>({status:"fulfilled",value:We}),errorCallback:We=>({status:"rejected",reason:We})})}static allWithCallback(He,ge){let We,wt,Xe=new this((li,ur)=>{We=li,wt=ur}),mt=2,dt=0;const $t=[];for(let li of He){cr(li)||(li=this.resolve(li));const ur=dt;try{li.then(ir=>{$t[ur]=ge?ge.thenCallback(ir):ir,mt--,0===mt&&We($t)},ir=>{ge?($t[ur]=ge.errorCallback(ir),mt--,0===mt&&We($t)):wt(ir)})}catch(ir){wt(ir)}mt++,dt++}return mt-=2,0===mt&&We($t),Xe}constructor(He){const ge=this;if(!(ge instanceof F))throw new Error("Must be an instanceof Promise.");ge[kr]=ki,ge[Wt]=[];try{const We=Pt();He&&He(We(vi(ge,lt)),We(vi(ge,dr)))}catch(We){cn(ge,!1,We)}}get[Symbol.toStringTag](){return"Promise"}get[Symbol.species](){return F}then(He,ge){let We=this.constructor?.[Symbol.species];(!We||"function"!=typeof We)&&(We=this.constructor||F);const wt=new We(Pi),Xe=se.current;return this[kr]==ki?this[Wt].push(Xe,wt,He,ge):Ls(this,Xe,wt,He,ge),wt}catch(He){return this.then(null,He)}finally(He){let ge=this.constructor?.[Symbol.species];(!ge||"function"!=typeof ge)&&(ge=F);const We=new ge(Pi);We[ct]=ct;const wt=se.current;return this[kr]==ki?this[Wt].push(wt,We,He,He):Ls(this,wt,We,He,He),We}}F.resolve=F.resolve,F.reject=F.reject,F.race=F.race,F.all=F.all;const ae=Z[Lt]=Z.Promise;Z.Promise=F;const Et=at("thenPatched");function qt(Ue){const He=Ue.prototype,ge=fe(He,"then");if(ge&&(!1===ge.writable||!ge.configurable))return;const We=He.then;He[ft]=We,Ue.prototype.then=function(wt,Xe){return new F((dt,$t)=>{We.call(this,dt,$t)}).then(wt,Xe)},Ue[Et]=!0}return ye.patchThen=qt,ae&&(qt(ae),Ka(Z,"fetch",Ue=>function Un(Ue){return function(He,ge){let We=Ue.apply(He,ge);if(We instanceof F)return We;let wt=We.constructor;return wt[Et]||qt(wt),We}}(Ue))),Promise[se.__symbol__("uncaughtPromiseErrors")]=tt,F}),Zone.__load_patch("toString",Z=>{const se=Function.prototype.toString,ye=Ji("OriginalDelegate"),fe=Ji("Promise"),be=Ji("Error"),ke=function(){if("function"==typeof this){const Lt=this[ye];if(Lt)return"function"==typeof Lt?se.call(Lt):Object.prototype.toString.call(Lt);if(this===Promise){const ft=Z[fe];if(ft)return se.call(ft)}if(this===Error){const ft=Z[be];if(ft)return se.call(ft)}}return se.call(this)};ke[ye]=se,Function.prototype.toString=ke;const at=Object.prototype.toString;Object.prototype.toString=function(){return"function"==typeof Promise&&this instanceof Promise?"[object Promise]":at.call(this)}});let el=!1;if(typeof window<"u")try{const Z=Object.defineProperty({},"passive",{get:function(){el=!0}});window.addEventListener("test",Z,Z),window.removeEventListener("test",Z,Z)}catch{el=!1}const zT={useG:!0},Co={},Mb={},ym=new RegExp("^"+Yd+"(\\w+)(true|false)$"),wb=Ji("propagationStopped");function Sm(Z,se){const ye=(se?se(Z):Z)+Wi,fe=(se?se(Z):Z)+Ts,be=Yd+ye,ke=Yd+fe;Co[Z]={},Co[Z][Wi]=be,Co[Z][Ts]=ke}function Cb(Z,se,ye,fe){const be=fe&&fe.add||pm,ke=fe&&fe.rm||$r,at=fe&&fe.listeners||"eventListeners",tt=fe&&fe.rmAll||"removeAllListeners",At=Ji(be),Lt="."+be+":",ft="prependListener",Ei="."+ft+":",ii=function(Wt,ct,_n){if(Wt.isRemoved)return;const sr=Wt.callback;let Zr;"object"==typeof sr&&sr.handleEvent&&(Wt.callback=lt=>sr.handleEvent(lt),Wt.originalDelegate=sr);try{Wt.invoke(Wt,ct,[_n])}catch(lt){Zr=lt}const ki=Wt.options;return ki&&"object"==typeof ki&&ki.once&&ct[ke].call(ct,_n.type,Wt.originalDelegate?Wt.originalDelegate:Wt.callback,ki),Zr};function gi(Wt,ct,_n){if(!(ct=ct||Z.event))return;const sr=Wt||ct.target||Z,Zr=sr[Co[ct.type][_n?Ts:Wi]];if(Zr){const ki=[];if(1===Zr.length){const lt=ii(Zr[0],sr,ct);lt&&ki.push(lt)}else{const lt=Zr.slice();for(let dr=0;dr{throw dr})}}}const cr=function(Wt){return gi(this,Wt,!1)},Oi=function(Wt){return gi(this,Wt,!0)};function es(Wt,ct){if(!Wt)return!1;let _n=!0;ct&&void 0!==ct.useG&&(_n=ct.useG);const sr=ct&&ct.vh;let Zr=!0;ct&&void 0!==ct.chkDup&&(Zr=ct.chkDup);let ki=!1;ct&&void 0!==ct.rt&&(ki=ct.rt);let lt=Wt;for(;lt&&!lt.hasOwnProperty(be);)lt=Vd(lt);if(!lt&&Wt[be]&&(lt=Wt),!lt||lt[At])return!1;const dr=ct&&ct.eventNameToString,et={},vi=lt[At]=lt[be],Pt=lt[Ji(ke)]=lt[ke],ts=lt[Ji(at)]=lt[at],_o=lt[Ji(tt)]=lt[tt];let cn;ct&&ct.prepend&&(cn=lt[Ji(ct.prepend)]=lt[ct.prepend]);const F=_n?function(ge){if(!et.isExisting)return vi.call(et.target,et.eventName,et.capture?Oi:cr,et.options)}:function(ge){return vi.call(et.target,et.eventName,ge.invoke,et.options)},ae=_n?function(ge){if(!ge.isRemoved){const We=Co[ge.eventName];let wt;We&&(wt=We[ge.capture?Ts:Wi]);const Xe=wt&&ge.target[wt];if(Xe)for(let mt=0;mt{Vo.zone.cancelTask(Vo)},{once:!0})),et.target=null,Fc&&(Fc.taskData=null),Zd&&(Dn.once=!0),!el&&"boolean"==typeof Vo.options||(Vo.options=Dn),Vo.target=$t,Vo.capture=Gl,Vo.eventName=li,ir&&(Vo.originalDelegate=ur),dt?jo.unshift(Vo):jo.push(Vo),mt?$t:void 0}};return lt[be]=He(vi,Lt,F,ae,ki),cn&&(lt[ft]=He(cn,Ei,function(ge){return cn.call(et.target,et.eventName,ge.invoke,et.options)},ae,ki,!0)),lt[ke]=function(){const ge=this||Z;let We=arguments[0];ct&&ct.transferEventName&&(We=ct.transferEventName(We));const wt=arguments[2],Xe=!!wt&&("boolean"==typeof wt||wt.capture),mt=arguments[1];if(!mt)return Pt.apply(this,arguments);if(sr&&!sr(Pt,mt,ge,arguments))return;const dt=Co[We];let $t;dt&&($t=dt[Xe?Ts:Wi]);const li=$t&&ge[$t];if(li)for(let ur=0;urfunction(be,ke){be[wb]=!0,fe&&fe.apply(be,ke)})}function Db(Z,se,ye,fe,be){const ke=Zone.__symbol__(fe);if(se[ke])return;const at=se[ke]=se[fe];se[fe]=function(tt,At,Lt){return At&&At.prototype&&be.forEach(function(ft){const Ei=`${ye}.${fe}::`+ft,ii=At.prototype;try{if(ii.hasOwnProperty(ft)){const gi=Z.ObjectGetOwnPropertyDescriptor(ii,ft);gi&&gi.value?(gi.value=Z.wrapWithCurrentZone(gi.value,Ei),Z._redefineProperty(At.prototype,ft,gi)):ii[ft]&&(ii[ft]=Z.wrapWithCurrentZone(ii[ft],Ei))}else ii[ft]&&(ii[ft]=Z.wrapWithCurrentZone(ii[ft],Ei))}catch{}}),at.call(se,tt,At,Lt)},Z.attachOriginToPatched(se[fe],at)}function xb(Z,se,ye){if(!ye||0===ye.length)return se;const fe=ye.filter(ke=>ke.target===Z);if(!fe||0===fe.length)return se;const be=fe[0].ignoreProperties;return se.filter(ke=>-1===be.indexOf(ke))}function Eo(Z,se,ye,fe){Z&&uf(Z,xb(Z,se,ye),fe)}function $d(Z){return Object.getOwnPropertyNames(Z).filter(se=>se.startsWith("on")&&se.length>2).map(se=>se.substring(2))}Zone.__load_patch("util",(Z,se,ye)=>{const fe=$d(Z);ye.patchOnProperties=uf,ye.patchMethod=Ka,ye.bindArguments=Qd,ye.patchMacroTask=Sb;const be=se.__symbol__("BLACK_LISTED_EVENTS"),ke=se.__symbol__("UNPATCHED_EVENTS");Z[ke]&&(Z[be]=Z[ke]),Z[be]&&(se[be]=se[ke]=Z[be]),ye.patchEventPrototype=Im,ye.patchEventTarget=Cb,ye.isIEOrEdge=bb,ye.ObjectDefineProperty=jd,ye.ObjectGetOwnPropertyDescriptor=_l,ye.ObjectCreate=Wd,ye.ArraySlice=yb,ye.patchClass=Xd,ye.wrapWithCurrentZone=lf,ye.filterProperties=xb,ye.attachOriginToPatched=Sa,ye._redefineProperty=Object.defineProperty,ye.patchCallbacks=Db,ye.getGlobalObjects=()=>({globalSources:Mb,zoneSymbolEventNames:Co,eventNames:fe,isBrowser:Gd,isMix:df,isNode:jh,TRUE_STR:Ts,FALSE_STR:Wi,ZONE_SYMBOL_PREFIX:Yd,ADD_EVENT_LISTENER_STR:pm,REMOVE_EVENT_LISTENER_STR:$r})});const As=Ji("zoneTask");function Wl(Z,se,ye,fe){let be=null,ke=null;ye+=fe;const at={};function tt(Lt){const ft=Lt.data;return ft.args[0]=function(){return Lt.invoke.apply(this,arguments)},ft.handleId=be.apply(Z,ft.args),Lt}function At(Lt){return ke.call(Z,Lt.data.handleId)}be=Ka(Z,se+=fe,Lt=>function(ft,Ei){if("function"==typeof Ei[0]){const ii={isPeriodic:"Interval"===fe,delay:"Timeout"===fe||"Interval"===fe?Ei[1]||0:void 0,args:Ei},gi=Ei[0];Ei[0]=function(){try{return gi.apply(this,arguments)}finally{ii.isPeriodic||("number"==typeof ii.handleId?delete at[ii.handleId]:ii.handleId&&(ii.handleId[As]=null))}};const cr=fm(se,Ei[0],ii,tt,At);if(!cr)return cr;const Oi=cr.data.handleId;return"number"==typeof Oi?at[Oi]=cr:Oi&&(Oi[As]=cr),Oi&&Oi.ref&&Oi.unref&&"function"==typeof Oi.ref&&"function"==typeof Oi.unref&&(cr.ref=Oi.ref.bind(Oi),cr.unref=Oi.unref.bind(Oi)),"number"==typeof Oi||Oi?Oi:cr}return Lt.apply(Z,Ei)}),ke=Ka(Z,ye,Lt=>function(ft,Ei){const ii=Ei[0];let gi;"number"==typeof ii?gi=at[ii]:(gi=ii&&ii[As],gi||(gi=ii)),gi&&"string"==typeof gi.type?"notScheduled"!==gi.state&&(gi.cancelFn&&gi.data.isPeriodic||0===gi.runCount)&&("number"==typeof ii?delete at[ii]:ii&&(ii[As]=null),gi.zone.cancelTask(gi)):Lt.apply(Z,Ei)})}Zone.__load_patch("legacy",Z=>{const se=Z[Zone.__symbol__("legacyPatch")];se&&se()}),Zone.__load_patch("timers",Z=>{const ye="clear";Wl(Z,"set",ye,"Timeout"),Wl(Z,"set",ye,"Interval"),Wl(Z,"set",ye,"Immediate")}),Zone.__load_patch("requestAnimationFrame",Z=>{Wl(Z,"request","cancel","AnimationFrame"),Wl(Z,"mozRequest","mozCancel","AnimationFrame"),Wl(Z,"webkitRequest","webkitCancel","AnimationFrame")}),Zone.__load_patch("blocking",(Z,se)=>{const ye=["alert","prompt","confirm"];for(let fe=0;fefunction(At,Lt){return se.current.run(ke,Z,Lt,tt)})}),Zone.__load_patch("EventTarget",(Z,se,ye)=>{(function Yl(Z,se){se.patchEventPrototype(Z,se)})(Z,ye),function Mm(Z,se){if(Zone[se.symbol("patchEventTarget")])return;const{eventNames:ye,zoneSymbolEventNames:fe,TRUE_STR:be,FALSE_STR:ke,ZONE_SYMBOL_PREFIX:at}=se.getGlobalObjects();for(let At=0;At{Xd("MutationObserver"),Xd("WebKitMutationObserver")}),Zone.__load_patch("IntersectionObserver",(Z,se,ye)=>{Xd("IntersectionObserver")}),Zone.__load_patch("FileReader",(Z,se,ye)=>{Xd("FileReader")}),Zone.__load_patch("on_property",(Z,se,ye)=>{!function pf(Z,se){if(jh&&!df||Zone[Z.symbol("patchEvents")])return;const ye=se.__Zone_ignore_on_properties;let fe=[];if(Gd){const be=window;fe=fe.concat(["Document","SVGElement","Element","HTMLElement","HTMLBodyElement","HTMLMediaElement","HTMLFrameSetElement","HTMLFrameElement","HTMLIFrameElement","HTMLMarqueeElement","Worker"]);const ke=function mm(){try{const Z=Uh.navigator.userAgent;if(-1!==Z.indexOf("MSIE ")||-1!==Z.indexOf("Trident/"))return!0}catch{}return!1}()?[{target:be,ignoreProperties:["error"]}]:[];Eo(be,$d(be),ye&&ye.concat(ke),Vd(be))}fe=fe.concat(["XMLHttpRequest","XMLHttpRequestEventTarget","IDBIndex","IDBRequest","IDBOpenDBRequest","IDBDatabase","IDBTransaction","IDBCursor","WebSocket"]);for(let be=0;be{!function bm(Z,se){const{isBrowser:ye,isMix:fe}=se.getGlobalObjects();(ye||fe)&&Z.customElements&&"customElements"in Z&&se.patchCallbacks(se,Z.customElements,"customElements","define",["connectedCallback","disconnectedCallback","adoptedCallback","attributeChangedCallback"])}(Z,ye)}),Zone.__load_patch("XHR",(Z,se)=>{!function At(Lt){const ft=Lt.XMLHttpRequest;if(!ft)return;const Ei=ft.prototype;let gi=Ei[Ul],cr=Ei[Fh];if(!gi){const et=Lt.XMLHttpRequestEventTarget;if(et){const vi=et.prototype;gi=vi[Ul],cr=vi[Fh]}}const Oi="readystatechange",es="scheduled";function kr(et){const vi=et.data,Pt=vi.target;Pt[ke]=!1,Pt[tt]=!1;const ts=Pt[be];gi||(gi=Pt[Ul],cr=Pt[Fh]),ts&&cr.call(Pt,Oi,ts);const _o=Pt[be]=()=>{if(Pt.readyState===Pt.DONE)if(!vi.aborted&&Pt[ke]&&et.state===es){const Ur=Pt[se.__symbol__("loadfalse")];if(0!==Pt.status&&Ur&&Ur.length>0){const Do=et.invoke;et.invoke=function(){const Ls=Pt[se.__symbol__("loadfalse")];for(let jr=0;jrfunction(et,vi){return et[fe]=0==vi[2],et[at]=vi[1],_n.apply(et,vi)}),Zr=Ji("fetchTaskAborting"),ki=Ji("fetchTaskScheduling"),lt=Ka(Ei,"send",()=>function(et,vi){if(!0===se.current[ki]||et[fe])return lt.apply(et,vi);{const Pt={target:et,url:et[at],isPeriodic:!1,args:vi,aborted:!1},ts=fm("XMLHttpRequest.send",Wt,Pt,kr,ct);et&&!0===et[tt]&&!Pt.aborted&&ts.state===es&&ts.invoke()}}),dr=Ka(Ei,"abort",()=>function(et,vi){const Pt=function ii(et){return et[ye]}(et);if(Pt&&"string"==typeof Pt.type){if(null==Pt.cancelFn||Pt.data&&Pt.data.aborted)return;Pt.zone.cancelTask(Pt)}else if(!0===se.current[Zr])return dr.apply(et,vi)})}(Z);const ye=Ji("xhrTask"),fe=Ji("xhrSync"),be=Ji("xhrListener"),ke=Ji("xhrScheduled"),at=Ji("xhrURL"),tt=Ji("xhrErrorBeforeScheduled")}),Zone.__load_patch("geolocation",Z=>{Z.navigator&&Z.navigator.geolocation&&function vm(Z,se){const ye=Z.constructor.name;for(let fe=0;fe{const At=function(){return tt.apply(this,Qd(arguments,ye+"."+be))};return Sa(At,tt),At})(ke)}}}(Z.navigator.geolocation,["getCurrentPosition","watchPosition"])}),Zone.__load_patch("PromiseRejectionEvent",(Z,se)=>{function ye(fe){return function(be){Eb(Z,fe).forEach(at=>{const tt=Z.PromiseRejectionEvent;if(tt){const At=new tt(fe,{promise:be.promise,reason:be.rejection});at.invoke(At)}})}}Z.PromiseRejectionEvent&&(se[Ji("unhandledPromiseRejectionHandler")]=ye("unhandledrejection"),se[Ji("rejectionHandledHandler")]=ye("rejectionhandled"))}),Zone.__load_patch("queueMicrotask",(Z,se,ye)=>{!function ff(Z,se){se.patchMethod(Z,"queueMicrotask",ye=>function(fe,be){Zone.current.scheduleMicroTask("queueMicrotask",be[0])})}(Z,ye)})}},_l=>{_l(_l.s=51)}]); \ No newline at end of file diff --git a/ej2-angular/samples/diagram/ports/edges-cs1/main.53ae47e68a59141c.js b/ej2-angular/samples/diagram/ports/edges-cs1/main.53ae47e68a59141c.js new file mode 100644 index 0000000000..9a07a7a0db --- /dev/null +++ b/ej2-angular/samples/diagram/ports/edges-cs1/main.53ae47e68a59141c.js @@ -0,0 +1 @@ +"use strict";(self.webpackChunksyncfusion_component=self.webpackChunksyncfusion_component||[]).push([[179],{51:(Wl,Vd,Wd)=>{let $r=null,_h=1;const Ts=Symbol("SIGNAL");function Wi(n){const t=$r;return $r=n,t}function gn(n){if((!Wh(n)||n.dirty)&&(n.dirty||n.lastCleanEpoch!==_h)){if(!n.producerMustRecompute(n)&&!Vh(n))return n.dirty=!1,void(n.lastCleanEpoch=_h);n.producerRecomputeValue(n),n.dirty=!1,n.lastCleanEpoch=_h}}function Vh(n){Gl(n);for(let t=0;t0}function Gl(n){n.producerNode??=[],n.producerIndexOfThis??=[],n.producerLastReadVersion??=[]}let $d=null;function Eo(n){return"function"==typeof n}function Zd(n){const e=n(i=>{Error.call(i),i.stack=(new Error).stack});return e.prototype=Object.create(Error.prototype),e.prototype.constructor=e,e}const fp=Zd(n=>function(e){n(this),this.message=e?`${e.length} errors occurred during unsubscription:\n${e.map((i,r)=>`${r+1}) ${i.toString()}`).join("\n ")}`:"",this.name="UnsubscriptionError",this.errors=e});function pp(n,t){if(n){const e=n.indexOf(t);0<=e&&n.splice(e,1)}}class As{constructor(t){this.initialTeardown=t,this.closed=!1,this._parentage=null,this._finalizers=null}unsubscribe(){let t;if(!this.closed){this.closed=!0;const{_parentage:e}=this;if(e)if(this._parentage=null,Array.isArray(e))for(const s of e)s.remove(this);else e.remove(this);const{initialTeardown:i}=this;if(Eo(i))try{i()}catch(s){t=s instanceof fp?s.errors:[s]}const{_finalizers:r}=this;if(r){this._finalizers=null;for(const s of r)try{wm(s)}catch(o){t=t??[],o instanceof fp?t=[...t,...o.errors]:t.push(o)}}if(t)throw new fp(t)}}add(t){var e;if(t&&t!==this)if(this.closed)wm(t);else{if(t instanceof As){if(t.closed||t._hasParent(this))return;t._addParent(this)}(this._finalizers=null!==(e=this._finalizers)&&void 0!==e?e:[]).push(t)}}_hasParent(t){const{_parentage:e}=this;return e===t||Array.isArray(e)&&e.includes(t)}_addParent(t){const{_parentage:e}=this;this._parentage=Array.isArray(e)?(e.push(t),e):e?[e,t]:t}_removeParent(t){const{_parentage:e}=this;e===t?this._parentage=null:Array.isArray(e)&&pp(e,t)}remove(t){const{_finalizers:e}=this;e&&pp(e,t),t instanceof As&&t._removeParent(this)}}As.EMPTY=(()=>{const n=new As;return n.closed=!0,n})();const Xl=As.EMPTY;function Mm(n){return n instanceof As||n&&"closed"in n&&Eo(n.remove)&&Eo(n.add)&&Eo(n.unsubscribe)}function wm(n){Eo(n)?n():n.unsubscribe()}const ql={onUnhandledError:null,onStoppedNotification:null,Promise:void 0,useDeprecatedSynchronousErrorHandling:!1,useDeprecatedNextContext:!1},Z={setTimeout(n,t,...e){const{delegate:i}=Z;return i?.setTimeout?i.setTimeout(n,t,...e):setTimeout(n,t,...e)},clearTimeout(n){const{delegate:t}=Z;return(t?.clearTimeout||clearTimeout)(n)},delegate:void 0};function ye(){}const pe=at("C",void 0,void 0);function at(n,t,e){return{kind:n,value:t,error:e}}let tt=null;function At(n){if(ql.useDeprecatedSynchronousErrorHandling){const t=!tt;if(t&&(tt={errorThrown:!1,error:null}),n(),t){const{errorThrown:e,error:i}=tt;if(tt=null,e)throw i}}else n()}class pt extends As{constructor(t){super(),this.isStopped=!1,t?(this.destination=t,Mm(t)&&t.add(this)):this.destination=Wt}static create(t,e,i){return new cr(t,e,i)}next(t){this.isStopped?Pr(function ke(n){return at("N",n,void 0)}(t),this):this._next(t)}error(t){this.isStopped?Pr(function be(n){return at("E",void 0,n)}(t),this):(this.isStopped=!0,this._error(t))}complete(){this.isStopped?Pr(pe,this):(this.isStopped=!0,this._complete())}unsubscribe(){this.closed||(this.isStopped=!0,super.unsubscribe(),this.destination=null)}_next(t){this.destination.next(t)}_error(t){try{this.destination.error(t)}finally{this.unsubscribe()}}_complete(){try{this.destination.complete()}finally{this.unsubscribe()}}}const Di=Function.prototype.bind;function si(n,t){return Di.call(n,t)}class mi{constructor(t){this.partialObserver=t}next(t){const{partialObserver:e}=this;if(e.next)try{e.next(t)}catch(i){ki(i)}}error(t){const{partialObserver:e}=this;if(e.error)try{e.error(t)}catch(i){ki(i)}else ki(t)}complete(){const{partialObserver:t}=this;if(t.complete)try{t.complete()}catch(e){ki(e)}}}class cr extends pt{constructor(t,e,i){let r;if(super(),Eo(t)||!t)r={next:t??void 0,error:e??void 0,complete:i??void 0};else{let s;this&&ql.useDeprecatedNextContext?(s=Object.create(t),s.unsubscribe=()=>this.unsubscribe(),r={next:t.next&&si(t.next,s),error:t.error&&si(t.error,s),complete:t.complete&&si(t.complete,s)}):r=t}this.destination=new mi(r)}}function ki(n){ql.useDeprecatedSynchronousErrorHandling?function Lt(n){ql.useDeprecatedSynchronousErrorHandling&&tt&&(tt.errorThrown=!0,tt.error=n)}(n):function se(n){Z.setTimeout(()=>{const{onUnhandledError:t}=ql;if(!t)throw n;t(n)})}(n)}function Pr(n,t){const{onStoppedNotification:e}=ql;e&&Z.setTimeout(()=>e(n,t))}const Wt={closed:!0,next:ye,error:function is(n){throw n},complete:ye},ct="function"==typeof Symbol&&Symbol.observable||"@@observable";function jn(n){return n}let Pi=(()=>{class n{constructor(e){e&&(this._subscribe=e)}lift(e){const i=new n;return i.source=this,i.operator=e,i}subscribe(e,i,r){const s=function et(n){return n&&n instanceof pt||function dr(n){return n&&Eo(n.next)&&Eo(n.error)&&Eo(n.complete)}(n)&&Mm(n)}(e)?e:new cr(e,i,r);return At(()=>{const{operator:o,source:a}=this;s.add(o?o.call(s,a):a?this._subscribe(s):this._trySubscribe(s))}),s}_trySubscribe(e){try{return this._subscribe(e)}catch(i){e.error(i)}}forEach(e,i){return new(i=lt(i))((r,s)=>{const o=new cr({next:a=>{try{e(a)}catch(l){s(l),o.unsubscribe()}},error:s,complete:r});this.subscribe(o)})}_subscribe(e){var i;return null===(i=this.source)||void 0===i?void 0:i.subscribe(e)}[ct](){return this}pipe(...e){return function Zr(n){return 0===n.length?jn:1===n.length?n[0]:function(e){return n.reduce((i,r)=>r(i),e)}}(e)(this)}toPromise(e){return new(e=lt(e))((i,r)=>{let s;this.subscribe(o=>s=o,o=>r(o),()=>i(s))})}}return n.create=t=>new n(t),n})();function lt(n){var t;return null!==(t=n??ql.Promise)&&void 0!==t?t:Promise}const yi=Zd(n=>function(){n(this),this.name="ObjectUnsubscribedError",this.message="object unsubscribed"});let Pt=(()=>{class n extends Pi{constructor(){super(),this.closed=!1,this.currentObservers=null,this.observers=[],this.isStopped=!1,this.hasError=!1,this.thrownError=null}lift(e){const i=new rs(this,this);return i.operator=e,i}_throwIfClosed(){if(this.closed)throw new yi}next(e){At(()=>{if(this._throwIfClosed(),!this.isStopped){this.currentObservers||(this.currentObservers=Array.from(this.observers));for(const i of this.currentObservers)i.next(e)}})}error(e){At(()=>{if(this._throwIfClosed(),!this.isStopped){this.hasError=this.isStopped=!0,this.thrownError=e;const{observers:i}=this;for(;i.length;)i.shift().error(e)}})}complete(){At(()=>{if(this._throwIfClosed(),!this.isStopped){this.isStopped=!0;const{observers:e}=this;for(;e.length;)e.shift().complete()}})}unsubscribe(){this.isStopped=this.closed=!0,this.observers=this.currentObservers=null}get observed(){var e;return(null===(e=this.observers)||void 0===e?void 0:e.length)>0}_trySubscribe(e){return this._throwIfClosed(),super._trySubscribe(e)}_subscribe(e){return this._throwIfClosed(),this._checkFinalizedStatuses(e),this._innerSubscribe(e)}_innerSubscribe(e){const{hasError:i,isStopped:r,observers:s}=this;return i||r?Xl:(this.currentObservers=null,s.push(e),new As(()=>{this.currentObservers=null,pp(s,e)}))}_checkFinalizedStatuses(e){const{hasError:i,thrownError:r,isStopped:s}=this;i?e.error(r):s&&e.complete()}asObservable(){const e=new Pi;return e.source=this,e}}return n.create=(t,e)=>new rs(t,e),n})();class rs extends Pt{constructor(t,e){super(),this.destination=t,this.source=e}next(t){var e,i;null===(i=null===(e=this.destination)||void 0===e?void 0:e.next)||void 0===i||i.call(e,t)}error(t){var e,i;null===(i=null===(e=this.destination)||void 0===e?void 0:e.error)||void 0===i||i.call(e,t)}complete(){var t,e;null===(e=null===(t=this.destination)||void 0===t?void 0:t.complete)||void 0===e||e.call(t)}_subscribe(t){var e,i;return null!==(i=null===(e=this.source)||void 0===e?void 0:e.subscribe(t))&&void 0!==i?i:Xl}}class _o extends Pt{constructor(t){super(),this._value=t}get value(){return this.getValue()}_subscribe(t){const e=super._subscribe(t);return!e.closed&&t.next(this._value),e}getValue(){const{hasError:t,thrownError:e,_value:i}=this;if(t)throw e;return this._throwIfClosed(),i}next(t){super.next(this._value=t)}}class Ls extends pt{constructor(t,e,i,r,s,o){super(t),this.onFinalize=s,this.shouldUnsubscribe=o,this._next=e?function(a){try{e(a)}catch(l){t.error(l)}}:super._next,this._error=r?function(a){try{r(a)}catch(l){t.error(l)}finally{this.unsubscribe()}}:super._error,this._complete=i?function(){try{i()}catch(a){t.error(a)}finally{this.unsubscribe()}}:super._complete}unsubscribe(){var t;if(!this.shouldUnsubscribe||this.shouldUnsubscribe()){const{closed:e}=this;super.unsubscribe(),!e&&(null===(t=this.onFinalize)||void 0===t||t.call(this))}}}function jr(n,t){return function Ur(n){return t=>{if(function cn(n){return Eo(n?.lift)}(t))return t.lift(function(e){try{return n(e,this)}catch(i){this.error(i)}});throw new TypeError("Unable to lift unknown Observable type")}}((e,i)=>{let r=0;e.subscribe(function Do(n,t,e,i,r){return new Ls(n,t,e,i,r)}(i,s=>{i.next(n.call(t,s,r++))}))})}class F extends Error{constructor(t,e){super(function ae(n,t){return`NG0${Math.abs(n)}${t?": "+t:""}`}(t,e)),this.code=t}}function Xe(n){for(let t in n)if(n[t]===Xe)return t;throw Error("Could not find renamed property on target object.")}function mt(n,t){for(const e in t)t.hasOwnProperty(e)&&!n.hasOwnProperty(e)&&(n[e]=t[e])}function dt(n){if("string"==typeof n)return n;if(Array.isArray(n))return"["+n.map(dt).join(", ")+"]";if(null==n)return""+n;if(n.overriddenName)return`${n.overriddenName}`;if(n.name)return`${n.name}`;const t=n.toString();if(null==t)return""+t;const e=t.indexOf("\n");return-1===e?t:t.substring(0,e)}function $t(n,t){return null==n||""===n?null===t?"":t:null==t||""===t?n:n+" "+t}const ur=Xe({__forward_ref__:Xe});function ir(n){return n.__forward_ref__=ir,n.toString=function(){return dt(this())},n}function vt(n){return function Tn(n){return"function"==typeof n&&n.hasOwnProperty(ur)&&n.__forward_ref__===ir}(n)?n():n}function $l(n){return n&&!!n.\u0275providers}const Zl=Xe({\u0275cmp:Xe}),Jd=Xe({\u0275dir:Xe}),gp=Xe({\u0275pipe:Xe}),Uo=Xe({\u0275fac:Xe}),jo=Xe({__NG_ELEMENT_ID__:Xe}),vp=Xe({__NG_ENV_ID__:Xe});function Ri(n){return"function"==typeof n?n.name||n.toString():"object"==typeof n&&null!=n&&"function"==typeof n.type?n.type.name||n.type.toString():function Nt(n){return"string"==typeof n?n:null==n?"":String(n)}(n)}function Lb(n,t){throw new F(-201,!1)}function so(n,t){null==n&&function zt(n,t,e,i){throw new Error(`ASSERTION ERROR: ${n}`+(null==i?"":` [Expected=> ${e} ${i} ${t} <=Actual]`))}(t,n,null,"!=")}function Yi(n){return{token:n.token,providedIn:n.providedIn||null,factory:n.factory,value:void 0}}function mp(n){return{providers:n.providers||[],imports:n.imports||[]}}function Cm(n){return RT(n,Dm)||RT(n,HT)}function RT(n,t){return n.hasOwnProperty(t)?n[t]:null}function Em(n){return n&&(n.hasOwnProperty(Nb)||n.hasOwnProperty(x_))?n[Nb]:null}const Dm=Xe({\u0275prov:Xe}),Nb=Xe({\u0275inj:Xe}),HT=Xe({ngInjectableDef:Xe}),x_=Xe({ngInjectorDef:Xe});var xi=function(n){return n[n.Default=0]="Default",n[n.Host=1]="Host",n[n.Self=2]="Self",n[n.SkipSelf=4]="SkipSelf",n[n.Optional=8]="Optional",n}(xi||{});let Ob;function oo(n){const t=Ob;return Ob=n,t}function FT(n,t,e){const i=Cm(n);return i&&"root"==i.providedIn?void 0===i.value?i.value=i.factory():i.value:e&xi.Optional?null:void 0!==t?t:void Lb()}const rr=globalThis;class Ht{constructor(t,e){this._desc=t,this.ngMetadataName="InjectionToken",this.\u0275prov=void 0,"number"==typeof e?this.__NG_ELEMENT_ID__=e:void 0!==e&&(this.\u0275prov=Yi({token:this,providedIn:e.providedIn||"root",factory:e.factory}))}get multi(){return this}toString(){return`InjectionToken ${this._desc}`}}const yp={},Hb="__NG_DI_FLAG__",xm="ngTempTokenPath",L_=/\n/gm,UT="__source";let eu;function Gh(n){const t=eu;return eu=n,t}function k_(n,t=xi.Default){if(void 0===eu)throw new F(-203,!1);return null===eu?FT(n,void 0,t):eu.get(n,t&xi.Optional?null:void 0,t)}function _i(n,t=xi.Default){return(function BT(){return Ob}()||k_)(vt(n),t)}function Hi(n,t=xi.Default){return _i(n,Tm(t))}function Tm(n){return typeof n>"u"||"number"==typeof n?n:0|(n.optional&&8)|(n.host&&1)|(n.self&&2)|(n.skipSelf&&4)}function Bb(n){const t=[];for(let e=0;et){o=s-1;break}}}for(;ss?"":r[d+1].toLowerCase();const f=8&i?u:null;if(f&&-1!==VT(f,h,0)||2&i&&h!==u){if(Ma(i))return!1;o=!0}}}}else{if(!o&&!Ma(i)&&!Ma(l))return!1;if(o&&Ma(l))continue;o=!1,i=l|1&i}}return Ma(i)||o}function Ma(n){return 0==(1&n)}function __(n,t,e,i){if(null===t)return-1;let r=0;if(i||!e){let s=!1;for(;r-1)for(e++;e0?'="'+a+'"':"")+"]"}else 8&i?r+="."+o:4&i&&(r+=" "+o);else""!==r&&!Ma(o)&&(t+=$T(s,r),r=""),i=o,s=s||!Ma(i);e++}return""!==r&&(t+=$T(s,r)),t}function _b(n){return Jl(()=>{const t=JT(n),e={...t,decls:n.decls,vars:n.vars,template:n.template,consts:n.consts||null,ngContentSelectors:n.ngContentSelectors,onPush:n.changeDetection===Am.OnPush,directiveDefs:null,pipeDefs:null,dependencies:t.standalone&&n.dependencies||null,getStandaloneInjector:null,signals:n.signals??!1,data:n.data||{},encapsulation:n.encapsulation||ba.Emulated,styles:n.styles||Qi,_:null,schemas:n.schemas||null,tView:null,id:""};KT(e);const i=n.dependencies;return e.directiveDefs=Nm(i,!1),e.pipeDefs=Nm(i,!0),e.id=function Z_(n){let t=0;const e=[n.selectors,n.ngContentSelectors,n.hostVars,n.hostAttrs,n.consts,n.vars,n.decls,n.encapsulation,n.standalone,n.signals,n.exportAs,JSON.stringify(n.inputs),JSON.stringify(n.outputs),Object.getOwnPropertyNames(n.type.prototype),!!n.contentQueries,!!n.viewQuery].join("|");for(const r of e)t=Math.imul(31,t)+r.charCodeAt(0)<<0;return t+=2147483648,"c"+t}(e),e})}function X_(n){return di(n)||Wn(n)}function q_(n){return null!==n}function Lm(n){return Jl(()=>({type:n.type,bootstrap:n.bootstrap||Qi,declarations:n.declarations||Qi,imports:n.imports||Qi,exports:n.exports||Qi,transitiveCompileScopes:null,schemas:n.schemas||null,id:n.id||null}))}function ZT(n,t){if(null==n)return rl;const e={};for(const i in n)if(n.hasOwnProperty(i)){const r=n[i];let s,o,a=Xh.None;Array.isArray(r)?(a=r[0],s=r[1],o=r[2]??s):(s=r,o=r),t?(e[s]=a!==Xh.None?[i,a]:i,t[s]=o):e[s]=i}return e}function nr(n){return Jl(()=>{const t=JT(n);return KT(t),t})}function di(n){return n[Zl]||null}function Wn(n){return n[Jd]||null}function gs(n){return n[gp]||null}function JT(n){const t={};return{type:n.type,providersResolver:null,factory:null,hostBindings:n.hostBindings||null,hostVars:n.hostVars||0,hostAttrs:n.hostAttrs||null,contentQueries:n.contentQueries||null,declaredInputs:t,inputTransforms:null,inputConfig:n.inputs||rl,exportAs:n.exportAs||null,standalone:!0===n.standalone,signals:!0===n.signals,selectors:n.selectors||Qi,viewQuery:n.viewQuery||null,features:n.features||null,setInput:null,findHostDirectiveDefs:null,hostDirectives:null,inputs:ZT(n.inputs,t),outputs:ZT(n.outputs),debugInfo:null}}function KT(n){n.features?.forEach(t=>t(n))}function Nm(n,t){if(!n)return null;const e=t?gs:X_;return()=>("function"==typeof n?n():n).map(i=>e(i)).filter(q_)}const Vr=0,Be=1,Ct=2,vn=3,wa=4,Os=5,Ca=6,tu=7,Er=8,Xs=9,Kl=10,Yt=11,bp=12,eA=13,iu=14,Jr=15,Mp=16,ru=17,nl=18,wp=19,tA=20,qh=21,Om=22,Uc=23,jt=25,Ub=1,sl=7,nu=9,mn=10;var jb=function(n){return n[n.None=0]="None",n[n.HasTransplantedViews=2]="HasTransplantedViews",n}(jb||{});function ks(n){return Array.isArray(n)&&"object"==typeof n[Ub]}function Ps(n){return Array.isArray(n)&&!0===n[Ub]}function Vb(n){return 0!=(4&n.flags)}function jc(n){return n.componentOffset>-1}function Pm(n){return 1==(1&n.flags)}function Ea(n){return!!n.template}function Wb(n){return 0!=(512&n[Ct])}function Vc(n,t){return n.hasOwnProperty(Uo)?n[Uo]:null}class tU{constructor(t,e,i){this.previousValue=t,this.currentValue=e,this.firstChange=i}isFirstChange(){return this.firstChange}}function sA(n,t,e,i){null!==t?t.applyValueToInputSignal(t,i):n[e]=i}function oA(n){return n.type.prototype.ngOnChanges&&(n.setInput=rU),iU}function iU(){const n=lA(this),t=n?.current;if(t){const e=n.previous;if(e===rl)n.previous=t;else for(let i in t)e[i]=t[i];n.current=null,this.ngOnChanges(t)}}function rU(n,t,e,i,r){const s=this.declaredInputs[i],o=lA(n)||function nU(n,t){return n[aA]=t}(n,{previous:rl,current:null}),a=o.current||(o.current={}),l=o.previous,h=l[s];a[s]=new tU(h&&h.currentValue,e,l===rl),sA(n,t,r,e)}const aA="__ngSimpleChanges__";function lA(n){return n[aA]||null}const ol=function(n,t,e){};let dA=!1;function fr(n){for(;Array.isArray(n);)n=n[Vr];return n}function qs(n,t){return fr(t[n.index])}function Dp(n,t){return n.data[t]}function To(n,t){const e=t[n];return ks(e)?e:e[Vr]}function qb(n){return 128==(128&n[Ct])}function al(n,t){return null==t?null:n[t]}function uA(n){n[ru]=0}function cU(n){1024&n[Ct]||(n[Ct]|=1024,qb(n)&&xp(n))}function pA(n){return 9216&n[Ct]||n[Uc]?.dirty}function $b(n){pA(n)?xp(n):64&n[Ct]&&(function oU(){return dA}()?(n[Ct]|=1024,xp(n)):n[Kl].changeDetectionScheduler?.notify())}function xp(n){n[Kl].changeDetectionScheduler?.notify();let t=Wc(n);for(;null!==t&&!(8192&t[Ct])&&(t[Ct]|=8192,qb(t));)t=Wc(t)}function Wc(n){const t=n[vn];return Ps(t)?t[vn]:t}const Rt={lFrame:CA(null),bindingsEnabled:!0,skipHydrationRootTNode:null};function vA(){return Rt.bindingsEnabled}function Se(){return Rt.lFrame.lView}function Ti(){return Rt.lFrame.tView}function pr(){let n=mA();for(;null!==n&&64===n.type;)n=n.parent;return n}function mA(){return Rt.lFrame.currentTNode}function ll(n,t){const e=Rt.lFrame;e.currentTNode=n,e.isParent=t}function Jb(){return Rt.lFrame.isParent}function wU(n,t){const e=Rt.lFrame;e.bindingIndex=e.bindingRootIndex=n,e1(t)}function e1(n){Rt.lFrame.currentDirectiveIndex=n}function bA(){return Rt.lFrame.currentQueryIndex}function i1(n){Rt.lFrame.currentQueryIndex=n}function EU(n){const t=n[Be];return 2===t.type?t.declTNode:1===t.type?n[Os]:null}function MA(n,t,e){if(e&xi.SkipSelf){let r=t,s=n;for(;!(r=r.parent,null!==r||e&xi.Host||(r=EU(s),null===r||(s=s[iu],10&r.type))););if(null===r)return!1;t=r,n=s}const i=Rt.lFrame=wA();return i.currentTNode=t,i.lView=n,!0}function r1(n){const t=wA(),e=n[Be];Rt.lFrame=t,t.currentTNode=e.firstChild,t.lView=n,t.tView=e,t.contextLView=n,t.bindingIndex=e.bindingStartIndex,t.inI18n=!1}function wA(){const n=Rt.lFrame,t=null===n?null:n.child;return null===t?CA(n):t}function CA(n){const t={currentTNode:null,isParent:!0,lView:null,tView:null,selectedIndex:-1,contextLView:null,elementDepthCount:0,currentNamespace:null,currentDirectiveIndex:-1,bindingRootIndex:-1,bindingIndex:-1,currentQueryIndex:0,parent:n,child:null,inI18n:!1};return null!==n&&(n.child=t),t}function EA(){const n=Rt.lFrame;return Rt.lFrame=n.parent,n.currentTNode=null,n.lView=null,n}const DA=EA;function n1(){const n=EA();n.isParent=!0,n.tView=null,n.selectedIndex=-1,n.contextLView=null,n.elementDepthCount=0,n.currentDirectiveIndex=-1,n.currentNamespace=null,n.bindingRootIndex=-1,n.bindingIndex=-1,n.currentQueryIndex=0}function zs(){return Rt.lFrame.selectedIndex}function Yc(n){Rt.lFrame.selectedIndex=n}let TA=!0;function Hm(){return TA}function $h(n){TA=n}function Bm(n,t){for(let e=t.directiveStart,i=t.directiveEnd;e=i)break}else t[l]<0&&(n[ru]+=65536),(a>14>16&&(3&n[Ct])===t&&(n[Ct]+=16384,LA(a,s)):LA(a,s)}const au=-1;class Ap{constructor(t,e,i){this.factory=t,this.resolving=!1,this.canSeeViewProviders=e,this.injectImpl=i}}function a1(n){return n!==au}function Lp(n){return 32767&n}function Np(n,t){let e=function HU(n){return n>>16}(n),i=t;for(;e>0;)i=i[iu],e--;return i}let l1=!0;function Um(n){const t=l1;return l1=n,t}const NA=255,OA=5;let BU=0;const cl={};function jm(n,t){const e=kA(n,t);if(-1!==e)return e;const i=t[Be];i.firstCreatePass&&(n.injectorIndex=t.length,h1(i.data,n),h1(t,null),h1(i.blueprint,null));const r=Vm(n,t),s=n.injectorIndex;if(a1(r)){const o=Lp(r),a=Np(r,t),l=a[Be].data;for(let h=0;h<8;h++)t[s+h]=a[o+h]|l[o+h]}return t[s+8]=r,s}function h1(n,t){n.push(0,0,0,0,0,0,0,0,t)}function kA(n,t){return-1===n.injectorIndex||n.parent&&n.parent.injectorIndex===n.injectorIndex||null===t[n.injectorIndex+8]?-1:n.injectorIndex}function Vm(n,t){if(n.parent&&-1!==n.parent.injectorIndex)return n.parent.injectorIndex;let e=0,i=null,r=t;for(;null!==r;){if(i=_A(r),null===i)return au;if(e++,r=r[iu],-1!==i.injectorIndex)return i.injectorIndex|e<<16}return au}function c1(n,t,e){!function FU(n,t,e){let i;"string"==typeof e?i=e.charCodeAt(0)||0:e.hasOwnProperty(jo)&&(i=e[jo]),null==i&&(i=e[jo]=BU++);const r=i&NA;t.data[n+(r>>OA)]|=1<=0?t&NA:VU:t}(e);if("function"==typeof s){if(!MA(t,n,i))return i&xi.Host?PA(r,0,i):zA(t,e,i,r);try{let o;if(o=s(i),null!=o||i&xi.Optional)return o;Lb()}finally{DA()}}else if("number"==typeof s){let o=null,a=kA(n,t),l=au,h=i&xi.Host?t[Jr][Os]:null;for((-1===a||i&xi.SkipSelf)&&(l=-1===a?Vm(n,t):t[a+8],l!==au&&FA(i,!1)?(o=t[Be],a=Lp(l),t=Np(l,t)):a=-1);-1!==a;){const c=t[Be];if(BA(s,a,c.data)){const d=UU(a,t,e,o,i,h);if(d!==cl)return d}l=t[a+8],l!==au&&FA(i,t[Be].data[a+8]===h)&&BA(s,a,t)?(o=c,a=Lp(l),t=Np(l,t)):a=-1}}return r}function UU(n,t,e,i,r,s){const o=t[Be],a=o.data[n+8],c=Wm(a,o,e,null==i?jc(a)&&l1:i!=o&&0!=(3&a.type),r&xi.Host&&s===a);return null!==c?Qc(t,o,c,a):cl}function Wm(n,t,e,i,r){const s=n.providerIndexes,o=t.data,a=1048575&s,l=n.directiveStart,c=s>>20,u=r?a+c:n.directiveEnd;for(let f=i?a:a+c;f=l&&p.type===e)return f}if(r){const f=o[l];if(f&&Ea(f)&&f.type===e)return l}return null}function Qc(n,t,e,i){let r=n[e];const s=t.data;if(function kU(n){return n instanceof Ap}(r)){const o=r;o.resolving&&function Vo(n,t){const e=t?`. Dependency path: ${t.join(" > ")} > ${n}`:"";throw new F(-200,`Circular dependency in DI detected for ${n}${e}`)}(Ri(s[e]));const a=Um(o.canSeeViewProviders);o.resolving=!0;const h=o.injectImpl?oo(o.injectImpl):null;MA(n,i,xi.Default);try{r=n[e]=o.factory(void 0,s,n,i),t.firstCreatePass&&e>=i.directiveStart&&function NU(n,t,e){const{ngOnChanges:i,ngOnInit:r,ngDoCheck:s}=t.type.prototype;if(i){const o=oA(t);(e.preOrderHooks??=[]).push(n,o),(e.preOrderCheckHooks??=[]).push(n,o)}r&&(e.preOrderHooks??=[]).push(0-n,r),s&&((e.preOrderHooks??=[]).push(n,s),(e.preOrderCheckHooks??=[]).push(n,s))}(e,s[e],t)}finally{null!==h&&oo(h),Um(a),o.resolving=!1,DA()}}return r}function BA(n,t,e){return!!(e[t+(n>>OA)]&1<Array.isArray(e)?gu(e,t):t(e))}function jA(n,t,e){t>=n.length?n.push(e):n.splice(t,0,e)}function Ym(n,t){return t>=n.length-1?n.pop():n.splice(t,1)[0]}const yu=new Ht(""),XA=new Ht("",-1),I1=new Ht("");class qm{get(t,e=yp){if(e===yp){const i=new Error(`NullInjectorError: No provider for ${dt(t)}!`);throw i.name="NullInjectorError",i}return e}}function fj(...n){return{\u0275providers:qA(0,n),\u0275fromNgModule:!0}}function qA(n,...t){const e=[],i=new Set;let r;const s=o=>{e.push(o)};return gu(t,o=>{const a=o;$m(a,s,[],i)&&(r||=[],r.push(a))}),void 0!==r&&$A(r,s),e}function $A(n,t){for(let e=0;e{t(s,i)})}}function $m(n,t,e,i){if(!(n=vt(n)))return!1;let r=null,s=Em(n);const o=!s&&di(n);if(s||o){if(o&&!o.standalone)return!1;r=n}else{const l=n.ngModule;if(s=Em(l),!s)return!1;r=l}const a=i.has(r);if(o){if(a)return!1;if(i.add(r),o.dependencies){const l="function"==typeof o.dependencies?o.dependencies():o.dependencies;for(const h of l)$m(h,t,e,i)}}else{if(!s)return!1;{if(null!=s.imports&&!a){let h;i.add(r);try{gu(s.imports,c=>{$m(c,t,e,i)&&(h||=[],h.push(c))})}finally{}void 0!==h&&$A(h,t)}if(!a){const h=Vc(r)||(()=>new r);t({provide:r,useFactory:h,deps:Qi},r),t({provide:I1,useValue:r,multi:!0},r),t({provide:yu,useValue:()=>_i(r),multi:!0},r)}const l=s.providers;if(null!=l&&!a){const h=n;M1(l,c=>{t(c,h)})}}}return r!==n&&void 0!==n.providers}function M1(n,t){for(let e of n)$l(e)&&(e=e.\u0275providers),Array.isArray(e)?M1(e,t):t(e)}const pj=Xe({provide:String,useValue:Xe});function w1(n){return null!==n&&"object"==typeof n&&pj in n}function Gc(n){return"function"==typeof n}const C1=new Ht(""),Zm={},vj={};let E1;function Jm(){return void 0===E1&&(E1=new qm),E1}class ih{}class Su extends ih{get destroyed(){return this._destroyed}constructor(t,e,i,r){super(),this.parent=e,this.source=i,this.scopes=r,this.records=new Map,this._ngOnDestroyHooks=new Set,this._onDestroyHooks=[],this._destroyed=!1,x1(t,o=>this.processProvider(o)),this.records.set(XA,Iu(void 0,this)),r.has("environment")&&this.records.set(ih,Iu(void 0,this));const s=this.records.get(C1);null!=s&&"string"==typeof s.value&&this.scopes.add(s.value),this.injectorDefTypes=new Set(this.get(I1,Qi,xi.Self))}destroy(){this.assertNotDestroyed(),this._destroyed=!0;try{for(const e of this._ngOnDestroyHooks)e.ngOnDestroy();const t=this._onDestroyHooks;this._onDestroyHooks=[];for(const e of t)e()}finally{this.records.clear(),this._ngOnDestroyHooks.clear(),this.injectorDefTypes.clear()}}onDestroy(t){return this.assertNotDestroyed(),this._onDestroyHooks.push(t),()=>this.removeOnDestroy(t)}runInContext(t){this.assertNotDestroyed();const e=Gh(this),i=oo(void 0);try{return t()}finally{Gh(e),oo(i)}}get(t,e=yp,i=xi.Default){if(this.assertNotDestroyed(),t.hasOwnProperty(vp))return t[vp](this);i=Tm(i);const s=Gh(this),o=oo(void 0);try{if(!(i&xi.SkipSelf)){let l=this.records.get(t);if(void 0===l){const h=function bj(n){return"function"==typeof n||"object"==typeof n&&n instanceof Ht}(t)&&Cm(t);l=h&&this.injectableDefInScope(h)?Iu(D1(t),Zm):null,this.records.set(t,l)}if(null!=l)return this.hydrate(t,l)}return(i&xi.Self?Jm():this.parent).get(t,e=i&xi.Optional&&e===yp?null:e)}catch(a){if("NullInjectorError"===a.name){if((a[xm]=a[xm]||[]).unshift(dt(t)),s)throw a;return function z_(n,t,e,i){const r=n[xm];throw t[UT]&&r.unshift(t[UT]),n.message=function R_(n,t,e,i=null){n=n&&"\n"===n.charAt(0)&&"\u0275"==n.charAt(1)?n.slice(2):n;let r=dt(t);if(Array.isArray(t))r=t.map(dt).join(" -> ");else if("object"==typeof t){let s=[];for(let o in t)if(t.hasOwnProperty(o)){let a=t[o];s.push(o+":"+("string"==typeof a?JSON.stringify(a):dt(a)))}r=`{${s.join(", ")}}`}return`${e}${i?"("+i+")":""}[${r}]: ${n.replace(L_,"\n ")}`}("\n"+n.message,r,e,i),n.ngTokenPath=r,n[xm]=null,n}(a,t,"R3InjectorError",this.source)}throw a}finally{oo(o),Gh(s)}}resolveInjectorInitializers(){const t=Gh(this),e=oo(void 0);try{const r=this.get(yu,Qi,xi.Self);for(const s of r)s()}finally{Gh(t),oo(e)}}toString(){const t=[],e=this.records;for(const i of e.keys())t.push(dt(i));return`R3Injector[${t.join(", ")}]`}assertNotDestroyed(){if(this._destroyed)throw new F(205,!1)}processProvider(t){let e=Gc(t=vt(t))?t:vt(t&&t.provide);const i=function yj(n){return w1(n)?Iu(void 0,n.useValue):Iu(KA(n),Zm)}(t);if(!Gc(t)&&!0===t.multi){let r=this.records.get(e);r||(r=Iu(void 0,Zm,!0),r.factory=()=>Bb(r.multi),this.records.set(e,r)),e=t,r.multi.push(t)}this.records.set(e,i)}hydrate(t,e){return e.value===Zm&&(e.value=vj,e.value=e.factory()),"object"==typeof e.value&&e.value&&function Ij(n){return null!==n&&"object"==typeof n&&"function"==typeof n.ngOnDestroy}(e.value)&&this._ngOnDestroyHooks.add(e.value),e.value}injectableDefInScope(t){if(!t.providedIn)return!1;const e=vt(t.providedIn);return"string"==typeof e?"any"===e||this.scopes.has(e):this.injectorDefTypes.has(e)}removeOnDestroy(t){const e=this._onDestroyHooks.indexOf(t);-1!==e&&this._onDestroyHooks.splice(e,1)}}function D1(n){const t=Cm(n),e=null!==t?t.factory:Vc(n);if(null!==e)return e;if(n instanceof Ht)throw new F(204,!1);if(n instanceof Function)return function mj(n){if(n.length>0)throw new F(204,!1);const e=function D_(n){return n&&(n[Dm]||n[HT])||null}(n);return null!==e?()=>e.factory(n):()=>new n}(n);throw new F(204,!1)}function KA(n,t,e){let i;if(Gc(n)){const r=vt(n);return Vc(r)||D1(r)}if(w1(n))i=()=>vt(n.useValue);else if(function JA(n){return!(!n||!n.useFactory)}(n))i=()=>n.useFactory(...Bb(n.deps||[]));else if(function ZA(n){return!(!n||!n.useExisting)}(n))i=()=>_i(vt(n.useExisting));else{const r=vt(n&&(n.useClass||n.provide));if(!function Sj(n){return!!n.deps}(n))return Vc(r)||D1(r);i=()=>new r(...Bb(n.deps))}return i}function Iu(n,t,e=!1){return{factory:n,value:t,multi:e?[]:void 0}}function x1(n,t){for(const e of n)Array.isArray(e)?x1(e,t):e&&$l(e)?x1(e.\u0275providers,t):t(e)}function rL(n,t=null,e=null,i){const r=function nL(n,t=null,e=null,i,r=new Set){const s=[e||Qi,fj(n)];return i=i||("object"==typeof n?void 0:dt(n)),new Su(s,t||Jm(),i||null,r)}(n,t,e,i);return r.resolveInjectorInitializers(),r}let L1,Wo=(()=>{class n{static{this.THROW_IF_NOT_FOUND=yp}static{this.NULL=new qm}static create(e,i){if(Array.isArray(e))return rL({name:""},i,e,"");{const r=e.name??"";return rL({name:r},e.parent,e.providers,r)}}static{this.\u0275prov=Yi({token:n,providedIn:"any",factory:()=>_i(XA)})}static{this.__NG_ELEMENT_ID__=-1}}return n})();const N1=new Ht("",{providedIn:"root",factory:()=>Lj}),Lj="ng",oL=new Ht(""),bu=new Ht("",{providedIn:"platform",factory:()=>"unknown"}),aL=new Ht("",{providedIn:"root",factory:()=>function Zh(){if(void 0!==L1)return L1;if(typeof document<"u")return document;throw new F(210,!1)}().body?.querySelector("[ngCspNonce]")?.getAttribute("ngCspNonce")||null});function ry(n){return 128==(128&n.flags)}var ec=function(n){return n[n.Important=1]="Important",n[n.DashCase=2]="DashCase",n}(ec||{});const R1=new Map;let Vj=0;const B1="__ngContext__";function Rs(n,t){ks(t)?(n[B1]=t[wp],function Yj(n){R1.set(n[wp],n)}(t)):n[B1]=t}let F1;function _1(n,t){return F1(n,t)}function wu(n,t,e,i,r){if(null!=i){let s,o=!1;Ps(i)?s=i:ks(i)&&(o=!0,i=i[Vr]);const a=fr(i);0===n&&null!==e?null==r?AL(t,e,a):qc(t,e,a,r||null,!0):1===n&&null!==e?qc(t,e,a,r||null,!0):2===n?function cy(n,t,e){const i=ly(n,t);i&&function a6(n,t,e,i){n.removeChild(t,e,i)}(n,i,t,e)}(t,a,o):3===n&&t.destroyNode(a),null!=s&&function c6(n,t,e,i,r){const s=e[sl];s!==fr(e)&&wu(t,n,i,s,r);for(let a=mn;a0&&(n[e-1][wa]=i[wa]);const s=Ym(n,mn+t);!function e6(n,t){DL(n,t),t[Vr]=null,t[Os]=null}(i[Be],i);const o=s[nl];null!==o&&o.detachView(s[Be]),i[vn]=null,i[wa]=null,i[Ct]&=-129}return i}function ay(n,t){if(!(256&t[Ct])){const e=t[Yt];e.destroyNode&&dy(n,t,e,3,null,null),function i6(n){let t=n[bp];if(!t)return j1(n[Be],n);for(;t;){let e=null;if(ks(t))e=t[bp];else{const i=t[mn];i&&(e=i)}if(!e){for(;t&&!t[wa]&&t!==n;)ks(t)&&j1(t[Be],t),t=t[vn];null===t&&(t=n),ks(t)&&j1(t[Be],t),e=t&&t[wa]}t=e}}(t)}}function j1(n,t){if(!(256&t[Ct])){t[Ct]&=-129,t[Ct]|=256,t[Uc]&&function Xd(n){if(Gl(n),Wh(n))for(let t=0;t=0?i[o]():i[-o].unsubscribe(),s+=2}else e[s].call(i[e[s+1]]);null!==i&&(t[tu]=null);const r=t[qh];if(null!==r){t[qh]=null;for(let s=0;s-1){const{encapsulation:s}=n.data[i.directiveStart+r];if(s===ba.None||s===ba.Emulated)return null}return qs(i,e)}}(n,t.parent,e)}function qc(n,t,e,i,r){n.insertBefore(t,e,i,r)}function AL(n,t,e){n.appendChild(t,e)}function LL(n,t,e,i,r){null!==i?qc(n,t,e,i,r):AL(n,t,e)}function ly(n,t){return n.parentNode(t)}let W1,kL=function OL(n,t,e){return 40&n.type?qs(n,e):null};function hy(n,t,e,i){const r=V1(n,i,t),s=t[Yt],a=function NL(n,t,e){return kL(n,t,e)}(i.parent||t[Os],i,t);if(null!=r)if(Array.isArray(e))for(let l=0;lnull;function oM(n,t,e=!1){return KL(n,t,e)}class G6{}class nN{}class q6{resolveComponentFactory(t){throw function X6(n){const t=Error(`No component factory found for ${dt(n)}.`);return t.ngComponent=n,t}(t)}}let Iy=(()=>{class n{static{this.NULL=new q6}}return n})();function $6(){return Au(pr(),Se())}function Au(n,t){return new $c(qs(n,t))}let $c=(()=>{class n{constructor(e){this.nativeElement=e}static{this.__NG_ELEMENT_ID__=$6}}return n})();function Z6(n){return n instanceof $c?n.nativeElement:n}class oN{}let cM=(()=>{class n{constructor(){this.destroyNode=null}static{this.__NG_ELEMENT_ID__=()=>function J6(){const n=Se(),e=To(pr().index,n);return(ks(e)?e:n)[Yt]}()}}return n})(),K6=(()=>{class n{static{this.\u0275prov=Yi({token:n,providedIn:"root",factory:()=>null})}}return n})();const dM={};function Qp(n,t,e,i,r=!1){for(;null!==e;){const s=t[e.index];null!==s&&i.push(fr(s)),Ps(s)&&pN(s,i);const o=e.type;if(8&o)Qp(n,t,e.child,i);else if(32&o){const a=_1(e,t);let l;for(;l=a();)i.push(l)}else if(16&o){const a=zL(t,e);if(Array.isArray(a))i.push(...a);else{const l=Wc(t[Jr]);Qp(l[Be],l,a,i,!0)}}e=r?e.projectionNext:e.next}return i}function pN(n,t){for(let e=mn;e!1,producerRecomputeValue:()=>{},consumerMarkedDirty:()=>{},consumerOnSignalRead:()=>{},consumerIsAlwaysLive:!0,consumerMarkedDirty:n=>{xp(n.lView)},consumerOnSignalRead(){this.lView[Uc]=this}};function vN(n){return yN(n[bp])}function mN(n){return yN(n[wa])}function yN(n){for(;null!==n&&!Ps(n);)n=n[wa];return n}function pM(n){return n.ngOriginalError}class nh{constructor(){this._console=console}handleError(t){const e=this._findOriginalError(t);this._console.error("ERROR",t),e&&this._console.error("ORIGINAL ERROR",e)}_findOriginalError(t){let e=t&&pM(t);for(;e&&pM(e);)e=pM(e);return e||null}}const IN=new Ht("",{providedIn:"root",factory:()=>Hi(nh).handleError.bind(void 0)}),MN=new Ht("",{providedIn:"root",factory:()=>!1}),Qt={};function gM(n=1){DN(Ti(),Se(),zs()+n,!1)}function DN(n,t,e,i){if(!i)if(3==(3&t[Ct])){const s=n.preOrderCheckHooks;null!==s&&Fm(t,s,e)}else{const s=n.preOrderHooks;null!==s&&_m(t,s,0,e)}Yc(e)}function Ot(n,t=xi.Default){const e=Se();return null===e?_i(n,t):RA(pr(),e,vt(n),t)}function xN(n,t,e,i,r,s){const o=Wi(null);try{let a=null;r&Xh.SignalBased&&(a=t[i][Ts]),null!==a&&void 0!==a.transformFn&&(s=a.transformFn(s)),r&Xh.HasDecoratorInputTransform&&(s=n.inputTransforms[i].call(t,s)),null!==n.setInput?n.setInput(t,a,s,e,i):sA(t,a,i,s)}finally{Wi(o)}}function Cy(n,t,e,i,r,s,o,a,l,h,c){const d=t.blueprint.slice();return d[Vr]=r,d[Ct]=204|i,(null!==h||n&&2048&n[Ct])&&(d[Ct]|=2048),uA(d),d[vn]=d[iu]=n,d[Er]=e,d[Kl]=o||n&&n[Kl],d[Yt]=a||n&&n[Yt],d[Xs]=l||n&&n[Xs]||null,d[Os]=s,d[wp]=function Wj(){return Vj++}(),d[Ca]=c,d[tA]=h,d[Jr]=2==t.type?n[Jr]:d,d}function Lu(n,t,e,i,r){let s=n.data[t];if(null===s)s=function vM(n,t,e,i,r){const s=mA(),o=Jb(),l=n.data[t]=function LV(n,t,e,i,r,s){let o=t?t.injectorIndex:-1,a=0;return function ou(){return null!==Rt.skipHydrationRootTNode}()&&(a|=128),{type:e,index:i,insertBeforeIndex:null,injectorIndex:o,directiveStart:-1,directiveEnd:-1,directiveStylingLast:-1,componentOffset:-1,propertyBindings:null,flags:a,providerIndexes:0,value:r,attrs:s,mergedAttrs:null,localNames:null,initialInputs:void 0,inputs:null,outputs:null,tView:null,next:null,prev:null,projectionNext:null,child:null,parent:t,projection:null,styles:null,stylesWithoutHost:null,residualStyles:void 0,classes:null,classesWithoutHost:null,residualClasses:void 0,classBindings:0,styleBindings:0}}(0,o?s:s&&s.parent,e,t,i,r);return null===n.firstChild&&(n.firstChild=l),null!==s&&(o?null==s.child&&null!==l.parent&&(s.child=l):null===s.next&&(s.next=l,l.prev=s)),l}(n,t,e,i,r),function MU(){return Rt.lFrame.inI18n}()&&(s.flags|=32);else if(64&s.type){s.type=e,s.value=i,s.attrs=r;const o=function Tp(){const n=Rt.lFrame,t=n.currentTNode;return n.isParent?t:t.parent}();s.injectorIndex=null===o?-1:o.injectorIndex}return ll(s,!0),s}function Gp(n,t,e,i){if(0===e)return-1;const r=t.length;for(let s=0;sjt&&DN(n,t,jt,!1),ol(o?2:0,r),e(i,r)}finally{Yc(s),ol(o?3:1,r)}}function mM(n,t,e){if(Vb(t)){const i=Wi(null);try{const s=t.directiveEnd;for(let o=t.directiveStart;onull;function NN(n,t,e,i,r){for(let s in t){if(!t.hasOwnProperty(s))continue;const o=t[s];if(void 0===o)continue;i??={};let a,l=Xh.None;Array.isArray(o)?(a=o[0],l=o[1]):a=o;let h=s;if(null!==r){if(!r.hasOwnProperty(s))continue;h=r[s]}0===n?ON(i,e,h,a,l):ON(i,e,h,a)}return i}function ON(n,t,e,i,r){let s;n.hasOwnProperty(e)?(s=n[e]).push(t,i):s=n[e]=[t,i],void 0!==r&&s.push(r)}function kN(n,t,e,i,r,s){for(let h=0;h0;){const e=n[--t];if("number"==typeof e&&e<0)return e}return 0})(o)!=a&&o.push(a),o.push(e,i,s)}}(n,t,i,Gp(n,e,r.hostVars,Qt),r)}function YV(n,t,e,i,r,s){const o=s[t];if(null!==o)for(let a=0;an.nextProducerIndex;)n.producerNode.pop(),n.producerLastReadVersion.pop(),n.producerIndexOfThis.pop()}}(a,o),function fV(n){n.lView[Uc]!==n&&(n.lView=null,gN.push(n))}(a)),n1()}}function _N(n,t){for(let e=vN(n);null!==e;e=mN(e))for(let i=mn;i-1&&(Bp(t,i),Ym(e,i))}this._attachedToViewContainer=!1}ay(this._lView[Be],this._lView)}onDestroy(t){!function Rm(n,t){if(256==(256&n[Ct]))throw new F(911,!1);null===n[qh]&&(n[qh]=[]),n[qh].push(t)}(this._lView,t)}markForCheck(){Xp(this._cdRefInjectingView||this._lView)}detach(){this._lView[Ct]&=-129}reattach(){$b(this._lView),this._lView[Ct]|=128}detectChanges(){this._lView[Ct]|=1024,function DM(n,t=!0){const e=n[Kl],i=e.rendererFactory;i.begin?.();try{!function XV(n){xM(n,0);let t=0;for(;pA(n);){if(100===t)throw new F(103,!1);t++,xM(n,1)}}(n)}catch(s){throw t&&Dy(n,s),s}finally{i.end?.(),e.inlineEffectRunner?.flush()}}(this._lView,this.notifyErrorHandler)}checkNoChanges(){}attachToViewContainerRef(){if(this._appRef)throw new F(902,!1);this._attachedToViewContainer=!0}detachFromAppRef(){this._appRef=null,DL(this._lView[Be],this._lView)}attachToAppRef(t){if(this._attachedToViewContainer)throw new F(902,!1);this._appRef=t,$b(this._lView)}}const WN=new Set;function AM(n){return t=>{setTimeout(n,void 0,t)}}const Yo=class h7 extends Pt{constructor(t=!1){super(),this.__isAsync=t}emit(t){super.next(t)}subscribe(t,e,i){let r=t,s=e||(()=>null),o=i;if(t&&"object"==typeof t){const l=t;r=l.next?.bind(l),s=l.error?.bind(l),o=l.complete?.bind(l)}this.__isAsync&&(s=AM(s),r&&(r=AM(r)),o&&(o=AM(o)));const a=super.subscribe({next:r,error:s,complete:o});return t instanceof As&&t.add(a),a}};function YN(...n){}class Rr{constructor({enableLongStackTrace:t=!1,shouldCoalesceEventChangeDetection:e=!1,shouldCoalesceRunChangeDetection:i=!1}){if(this.hasPendingMacrotasks=!1,this.hasPendingMicrotasks=!1,this.isStable=!0,this.onUnstable=new Yo(!1),this.onMicrotaskEmpty=new Yo(!1),this.onStable=new Yo(!1),this.onError=new Yo(!1),typeof Zone>"u")throw new F(908,!1);Zone.assertZonePatched();const r=this;r._nesting=0,r._outer=r._inner=Zone.current,Zone.TaskTrackingZoneSpec&&(r._inner=r._inner.fork(new Zone.TaskTrackingZoneSpec)),t&&Zone.longStackTraceZoneSpec&&(r._inner=r._inner.fork(Zone.longStackTraceZoneSpec)),r.shouldCoalesceEventChangeDetection=!i&&e,r.shouldCoalesceRunChangeDetection=i,r.lastRequestAnimationFrameId=-1,r.nativeRequestAnimationFrame=function c7(){const n="function"==typeof rr.requestAnimationFrame;let t=rr[n?"requestAnimationFrame":"setTimeout"],e=rr[n?"cancelAnimationFrame":"clearTimeout"];if(typeof Zone<"u"&&t&&e){const i=t[Zone.__symbol__("OriginalDelegate")];i&&(t=i);const r=e[Zone.__symbol__("OriginalDelegate")];r&&(e=r)}return{nativeRequestAnimationFrame:t,nativeCancelAnimationFrame:e}}().nativeRequestAnimationFrame,function f7(n){const t=()=>{!function u7(n){n.isCheckStableRunning||-1!==n.lastRequestAnimationFrameId||(n.lastRequestAnimationFrameId=n.nativeRequestAnimationFrame.call(rr,()=>{n.fakeTopEventTask||(n.fakeTopEventTask=Zone.root.scheduleEventTask("fakeTopEventTask",()=>{n.lastRequestAnimationFrameId=-1,NM(n),n.isCheckStableRunning=!0,LM(n),n.isCheckStableRunning=!1},void 0,()=>{},()=>{})),n.fakeTopEventTask.invoke()}),NM(n))}(n)};n._inner=n._inner.fork({name:"angular",properties:{isAngularZone:!0},onInvokeTask:(e,i,r,s,o,a)=>{if(function p7(n){return!(!Array.isArray(n)||1!==n.length)&&!0===n[0].data?.__ignore_ng_zone__}(a))return e.invokeTask(r,s,o,a);try{return QN(n),e.invokeTask(r,s,o,a)}finally{(n.shouldCoalesceEventChangeDetection&&"eventTask"===s.type||n.shouldCoalesceRunChangeDetection)&&t(),GN(n)}},onInvoke:(e,i,r,s,o,a,l)=>{try{return QN(n),e.invoke(r,s,o,a,l)}finally{n.shouldCoalesceRunChangeDetection&&t(),GN(n)}},onHasTask:(e,i,r,s)=>{e.hasTask(r,s),i===r&&("microTask"==s.change?(n._hasPendingMicrotasks=s.microTask,NM(n),LM(n)):"macroTask"==s.change&&(n.hasPendingMacrotasks=s.macroTask))},onHandleError:(e,i,r,s)=>(e.handleError(r,s),n.runOutsideAngular(()=>n.onError.emit(s)),!1)})}(r)}static isInAngularZone(){return typeof Zone<"u"&&!0===Zone.current.get("isAngularZone")}static assertInAngularZone(){if(!Rr.isInAngularZone())throw new F(909,!1)}static assertNotInAngularZone(){if(Rr.isInAngularZone())throw new F(909,!1)}run(t,e,i){return this._inner.run(t,e,i)}runTask(t,e,i,r){const s=this._inner,o=s.scheduleEventTask("NgZoneEvent: "+r,t,d7,YN,YN);try{return s.runTask(o,e,i)}finally{s.cancelTask(o)}}runGuarded(t,e,i){return this._inner.runGuarded(t,e,i)}runOutsideAngular(t){return this._outer.run(t)}}const d7={};function LM(n){if(0==n._nesting&&!n.hasPendingMicrotasks&&!n.isStable)try{n._nesting++,n.onMicrotaskEmpty.emit(null)}finally{if(n._nesting--,!n.hasPendingMicrotasks)try{n.runOutsideAngular(()=>n.onStable.emit(null))}finally{n.isStable=!0}}}function NM(n){n.hasPendingMicrotasks=!!(n._hasPendingMicrotasks||(n.shouldCoalesceEventChangeDetection||n.shouldCoalesceRunChangeDetection)&&-1!==n.lastRequestAnimationFrameId)}function QN(n){n._nesting++,n.isStable&&(n.isStable=!1,n.onUnstable.emit(null))}function GN(n){n._nesting--,LM(n)}let $p=(()=>{class n{constructor(){this.handler=null,this.internalCallbacks=[]}execute(){const e=[...this.internalCallbacks];this.internalCallbacks.length=0;for(const r of e)r();return!!this.handler?.execute()||e.length>0}ngOnDestroy(){this.handler?.destroy(),this.handler=null,this.internalCallbacks.length=0}static{this.\u0275prov=Yi({token:n,providedIn:"root",factory:()=>new n})}}return n})();function y7(n,t){const e=To(t,n),i=e[Be];!function S7(n,t){for(let e=t.length;e0&&BL(n,e,s.join(" "))}}(u,w,p,i),void 0!==e&&function A7(n,t,e){const i=n.projection=[];for(let r=0;r=0;i--){const r=n[i];r.hostVars=t+=r.hostVars,r.hostAttrs=Ip(r.hostAttrs,e=Ip(e,r.hostAttrs))}}(i)}function N7(n,t){for(const e in t.inputs){if(!t.inputs.hasOwnProperty(e)||n.inputs.hasOwnProperty(e))continue;const i=t.inputs[e];if(void 0!==i&&(n.inputs[e]=i,n.declaredInputs[e]=t.declaredInputs[e],null!==t.inputTransforms)){const r=Array.isArray(i)?i[0]:i;if(!t.inputTransforms.hasOwnProperty(r))continue;n.inputTransforms??={},n.inputTransforms[r]=t.inputTransforms[r]}}}function Ty(n){return n===rl?{}:n===Qi?[]:n}function k7(n,t){const e=n.viewQuery;n.viewQuery=e?(i,r)=>{t(i,r),e(i,r)}:t}function P7(n,t){const e=n.contentQueries;n.contentQueries=e?(i,r,s)=>{t(i,r,s),e(i,r,s)}:t}function z7(n,t){const e=n.hostBindings;n.hostBindings=e?(i,r)=>{t(i,r),e(i,r)}:t}function Ou(n,t){return!t||null===t.firstChild||ry(n)}function rg(n,t,e,i=!0){const r=t[Be];if(function r6(n,t,e,i){const r=mn+i,s=e.length;i>0&&(e[r-1][wa]=t),i{class n{static{this.__NG_ELEMENT_ID__=h9}}return n})();function h9(){return pO(pr(),Se())}const c9=An,uO=class extends c9{constructor(t,e,i){super(),this._lContainer=t,this._hostTNode=e,this._hostLView=i}get element(){return Au(this._hostTNode,this._hostLView)}get injector(){return new Yn(this._hostTNode,this._hostLView)}get parentInjector(){const t=Vm(this._hostTNode,this._hostLView);if(a1(t)){const e=Np(t,this._hostLView),i=Lp(t);return new Yn(e[Be].data[i+8],e)}return new Yn(null,this._hostLView)}clear(){for(;this.length>0;)this.remove(this.length-1)}get(t){const e=fO(this._lContainer);return null!==e&&e[t]||null}get length(){return this._lContainer.length-mn}createEmbeddedView(t,e,i){let r,s;"number"==typeof i?r=i:null!=i&&(r=i.index,s=i.injector);const a=t.createEmbeddedViewImpl(e||{},s,null);return this.insertImpl(a,r,Ou(this._hostTNode,null)),a}createComponent(t,e,i,r,s){const o=t&&!function Op(n){return"function"==typeof n}(t);let a;if(o)a=e;else{const p=e||{};a=p.index,i=p.injector,r=p.projectableNodes,s=p.environmentInjector||p.ngModuleRef}const l=o?t:new Zp(di(t)),h=i||this.parentInjector;if(!s&&null==l.ngModule){const g=(o?h:this.parentInjector).get(ih,null);g&&(s=g)}di(l.componentType??{});const f=l.create(h,r,null,s);return this.insertImpl(f.hostView,a,Ou(this._hostTNode,null)),f}insert(t,e){return this.insertImpl(t,e,!0)}insertImpl(t,e,i){const r=t._lView;if(function hU(n){return Ps(n[vn])}(r)){const a=this.indexOf(t);if(-1!==a)this.detach(a);else{const l=r[vn],h=new uO(l,l[Os],l[vn]);h.detach(h.indexOf(t))}}const s=this._adjustIndex(e),o=this._lContainer;return rg(o,r,s,i),t.attachToViewContainerRef(),jA(FM(o),s,t),t}move(t,e){return this.insert(t,e)}indexOf(t){const e=fO(this._lContainer);return null!==e?e.indexOf(t):-1}remove(t){const e=this._adjustIndex(t,-1),i=Bp(this._lContainer,e);i&&(Ym(FM(this._lContainer),e),ay(i[Be],i))}detach(t){const e=this._adjustIndex(t,-1),i=Bp(this._lContainer,e);return i&&null!=Ym(FM(this._lContainer),e)?new qp(i):null}_adjustIndex(t,e=0){return t??this.length+e}};function fO(n){return n[8]}function FM(n){return n[8]||(n[8]=[])}function pO(n,t){let e;const i=t[n.index];return Ps(i)?e=i:(e=function zN(n,t,e,i){return[n,!0,0,t,null,i,null,e,null,null]}(i,t,null,n),t[n.index]=e,Ey(t,e)),gO(e,t,n,i),new uO(e,n,t)}let gO=function mO(n,t,e,i){if(n[sl])return;let r;r=8&e.type?fr(i):function d9(n,t){const e=n[Yt],i=e.createComment(""),r=qs(t,n);return qc(e,ly(e,r),i,function l6(n,t){return n.nextSibling(t)}(e,r),!1),i}(t,e),n[sl]=r};function _y(n,t,e){const i=Se();return function Ln(n,t,e){return!Object.is(n[t],e)&&(n[t]=e,!0)}(i,function hl(){return Rt.lFrame.bindingIndex++}(),t)&&function No(n,t,e,i,r,s,o,a){const l=qs(t,e);let c,h=t.inputs;!a&&null!=h&&(c=h[i])?(EM(n,e,c,i,r),jc(t)&&function kV(n,t){const e=To(t,n);16&e[Ct]||(e[Ct]|=64)}(e,t.index)):3&t.type&&(i=function OV(n){return"class"===n?"className":"for"===n?"htmlFor":"formaction"===n?"formAction":"innerHtml"===n?"innerHTML":"readonly"===n?"readOnly":"tabindex"===n?"tabIndex":n}(i),r=null!=o?o(r,t.value||"",i):r,s.setProperty(l,i,r))}(Ti(),function zr(){const n=Rt.lFrame;return Dp(n.tView,n.selectedIndex)}(),i,n,t,i[Yt],e,!1),_y}function JM(n,t,e,i,r){const o=r?"class":"style";EM(n,e,t.inputs[o],o,i)}function id(n,t,e,i){const r=Se(),s=Ti(),o=jt+n,a=r[Yt],l=s.firstCreatePass?function B8(n,t,e,i,r,s){const o=t.consts,l=Lu(t,n,2,i,al(o,r));return function bM(n,t,e,i){if(vA()){const r=null===i?null:{"":-1},s=function FV(n,t){const e=n.directiveRegistry;let i=null,r=null;if(e)for(let s=0;s($h(!0),oy(i,r,function xA(){return Rt.lFrame.currentNamespace}()));const $u="en-US";let wk=$u;function lw(n){return!!n&&"function"==typeof n.then}function Xk(n){return!!n&&"function"==typeof n.subscribe}function Gy(n,t,e,i){const r=Se(),s=Ti(),o=pr();return function $k(n,t,e,i,r,s,o){const a=Pm(i),h=n.firstCreatePass&&BN(n),c=t[Er],d=HN(t);let u=!0;if(3&i.type||o){const g=qs(i,t),v=o?o(g):g,y=d.length,S=o?M=>o(fr(M[i.index])):i.index;let b=null;if(!o&&a&&(b=function UW(n,t,e,i){const r=n.cleanup;if(null!=r)for(let s=0;sl?a[l]:null}"string"==typeof o&&(s+=2)}return null}(n,t,r,i.index)),null!==b)(b.__ngLastListenerFn__||b).__ngNextListenerFn__=s,b.__ngLastListenerFn__=s,u=!1;else{s=Jk(i,t,c,s,!1);const M=e.listen(v,r,s);d.push(s,M),h&&h.push(r,S,y,y+1)}}else s=Jk(i,t,c,s,!1);const f=i.outputs;let p;if(u&&null!==f&&(p=f[r])){const g=p.length;if(g)for(let v=0;v-1?To(n.index,t):t);let l=Zk(t,e,i,o),h=s.__ngNextListenerFn__;for(;h;)l=Zk(t,e,h,o)&&l,h=h.__ngNextListenerFn__;return r&&!1===l&&o.preventDefault(),l}}function QW(){return this._results[Symbol.iterator]()}class cw{get changes(){return this._changes??=new Yo}constructor(t=!1){this._emitDistinctChangesOnly=t,this.dirty=!0,this._results=[],this._changesDetected=!1,this._changes=void 0,this.length=0,this.first=void 0,this.last=void 0;const e=cw.prototype;e[Symbol.iterator]||(e[Symbol.iterator]=QW)}get(t){return this._results[t]}map(t){return this._results.map(t)}filter(t){return this._results.filter(t)}find(t){return this._results.find(t)}reduce(t,e){return this._results.reduce(t,e)}forEach(t){this._results.forEach(t)}some(t){return this._results.some(t)}toArray(){return this._results.slice()}toString(){return this._results.toString()}reset(t,e){this.dirty=!1;const i=function lo(n){return n.flat(Number.POSITIVE_INFINITY)}(t);(this._changesDetected=!function $U(n,t,e){if(n.length!==t.length)return!1;for(let i=0;i{class n{static{this.__NG_ELEMENT_ID__=qW}}return n})();const GW=oh,XW=class extends GW{constructor(t,e,i){super(),this._declarationLView=t,this._declarationTContainer=e,this.elementRef=i}get ssrId(){return this._declarationTContainer.tView?.ssrId||null}createEmbeddedView(t,e){return this.createEmbeddedViewImpl(t,e)}createEmbeddedViewImpl(t,e,i){const r=function ig(n,t,e,i){const r=t.tView,a=Cy(n,r,e,4096&n[Ct]?4096:16,null,t,null,null,null,i?.injector??null,i?.dehydratedView??null);a[Mp]=n[t.index];const h=n[nl];return null!==h&&(a[nl]=h.createEmbeddedView(r)),OM(r,a,e),a}(this._declarationLView,this._declarationTContainer,t,{injector:e,dehydratedView:i});return new qp(r)}};function qW(){return Xy(pr(),Se())}function Xy(n,t){return 4&n.type?new XW(t,n,Au(n,t)):null}class dw{constructor(t){this.queryList=t,this.matches=null}clone(){return new dw(this.queryList)}setDirty(){this.queryList.setDirty()}}class uw{constructor(t=[]){this.queries=t}createEmbeddedView(t){const e=t.queries;if(null!==e){const i=null!==t.contentQueries?t.contentQueries[0]:e.length,r=[];for(let s=0;s0)i.push(o[a/2]);else{const h=s[a+1],c=t[-l];for(let d=mn;d($h(!0),function sy(n,t){return n.createText(t)}(t[Yt],i));function yw(n,t,e,i,r){if(n=vt(n),Array.isArray(n))for(let s=0;s>20;if(Gc(n)||!n.multi){const f=new Ap(h,r,Ot),p=Iw(l,t,r?c:c+u,d);-1===p?(c1(jm(a,o),s,l),Sw(s,n,t.length),t.push(l),a.directiveStart++,a.directiveEnd++,r&&(a.providerIndexes+=1048576),e.push(f),o.push(f)):(e[p]=f,o[p]=f)}else{const f=Iw(l,t,c+u,d),p=Iw(l,t,c,c+u),v=p>=0&&e[p];if(r&&!v||!r&&!(f>=0&&e[f])){c1(jm(a,o),s,l);const y=function yY(n,t,e,i,r){const s=new Ap(n,e,Ot);return s.multi=[],s.index=t,s.componentProviders=0,kP(s,r,i&&!e),s}(r?mY:vY,e.length,r,i,h);!r&&v&&(e[p].providerFactory=y),Sw(s,n,t.length,0),t.push(l),a.directiveStart++,a.directiveEnd++,r&&(a.providerIndexes+=1048576),e.push(y),o.push(y)}else Sw(s,n,f>-1?f:p,kP(e[r?p:f],h,!r&&i));!r&&i&&v&&e[p].componentProviders++}}}function Sw(n,t,e,i){const r=Gc(t),s=function gj(n){return!!n.useClass}(t);if(r||s){const l=(s?vt(t.useClass):t).prototype.ngOnDestroy;if(l){const h=n.destroyHooks||(n.destroyHooks=[]);if(!r&&t.multi){const c=h.indexOf(e);-1===c?h.push(e,[i,l]):h[c+1].push(i,l)}else h.push(e,l)}}}function kP(n,t,e){return e&&n.componentProviders++,n.multi.push(t)-1}function Iw(n,t,e,i){for(let r=e;r{e.providersResolver=(i,r)=>function gY(n,t,e){const i=Ti();if(i.firstCreatePass){const r=Ea(n);yw(e,i.data,i.blueprint,r,!0),yw(t,i.data,i.blueprint,r,!1)}}(i,r?r(n):n,t)}}class sd{}class zP extends sd{constructor(t){super(),this.componentFactoryResolver=new KN(this),this.instance=null;const e=new Su([...t.providers,{provide:sd,useValue:this},{provide:Iy,useValue:this.componentFactoryResolver}],t.parent||Jm(),t.debugName,new Set(["environment"]));this.injector=e,t.runEnvironmentInitializers&&e.resolveInjectorInitializers()}destroy(){this.injector.destroy()}onDestroy(t){this.injector.onDestroy(t)}}let wY=(()=>{class n{constructor(e){this._injector=e,this.cachedInjectors=new Map}getOrCreateStandaloneInjector(e){if(!e.standalone)return null;if(!this.cachedInjectors.has(e)){const i=qA(0,e.type),r=i.length>0?function MY(n,t,e=null){return new zP({providers:n,parent:t,debugName:e,runEnvironmentInitializers:!0}).injector}([i],this._injector,`Standalone[${e.type.name}]`):null;this.cachedInjectors.set(e,r)}return this.cachedInjectors.get(e)}ngOnDestroy(){try{for(const e of this.cachedInjectors.values())null!==e&&e.destroy()}finally{this.cachedInjectors.clear()}}static{this.\u0275prov=Yi({token:n,providedIn:"environment",factory:()=>new n(_i(ih))})}}return n})();function RP(n){(function Zc(n){WN.has(n)||(WN.add(n),performance?.mark?.("mark_feature_usage",{detail:{feature:n}}))})("NgStandalone"),n.getStandaloneInjector=t=>t.get(wY).getOrCreateStandaloneInjector(n)}let Lw=(()=>{class n{constructor(){this.taskId=0,this.pendingTasks=new Set,this.hasPendingTasks=new _o(!1)}get _hasPendingTasks(){return this.hasPendingTasks.value}add(){this._hasPendingTasks||this.hasPendingTasks.next(!0);const e=this.taskId++;return this.pendingTasks.add(e),e}remove(e){this.pendingTasks.delete(e),0===this.pendingTasks.size&&this._hasPendingTasks&&this.hasPendingTasks.next(!1)}ngOnDestroy(){this.pendingTasks.clear(),this._hasPendingTasks&&this.hasPendingTasks.next(!1)}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();const g2=new Ht(""),XQ=new Ht("");let zw=(()=>{class n{constructor(){this.initialized=!1,this.done=!1,this.donePromise=new Promise((e,i)=>{this.resolve=e,this.reject=i}),this.appInits=Hi(XQ,{optional:!0})??[]}runInitializers(){if(this.initialized)return;const e=[];for(const r of this.appInits){const s=r();if(lw(s))e.push(s);else if(Xk(s)){const o=new Promise((a,l)=>{s.subscribe({complete:a,error:l})});e.push(o)}}const i=()=>{this.done=!0,this.resolve()};Promise.all(e).then(()=>{i()}).catch(r=>{this.reject(r)}),0===e.length&&i(),this.initialized=!0}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();const v2=new Ht("");let Ku=(()=>{class n{constructor(){this._bootstrapListeners=[],this._runningTick=!1,this._destroyed=!1,this._destroyListeners=[],this._views=[],this.internalErrorHandler=Hi(IN),this.afterRenderEffectManager=Hi($p),this.componentTypes=[],this.components=[],this.isStable=Hi(Lw).hasPendingTasks.pipe(jr(e=>!e)),this._injector=Hi(ih)}get destroyed(){return this._destroyed}get injector(){return this._injector}bootstrap(e,i){const r=e instanceof nN;if(!this._injector.get(zw).done)throw!r&&function _c(n){const t=di(n)||Wn(n)||gs(n);return null!==t&&t.standalone}(e),new F(405,!1);let o;o=r?e:this._injector.get(Iy).resolveComponentFactory(e),this.componentTypes.push(o.componentType);const a=function $Q(n){return n.isBoundToModule}(o)?void 0:this._injector.get(sd),h=o.create(Wo.NULL,[],i||o.selector,a),c=h.location.nativeElement,d=h.injector.get(g2,null);return d?.registerApplication(c),h.onDestroy(()=>{this.detachView(h.hostView),e0(this.components,h),d?.unregisterApplication(c)}),this._loadComponent(h),h}tick(){if(this._runningTick)throw new F(101,!1);try{this._runningTick=!0;for(let e of this._views)e.detectChanges()}catch(e){this.internalErrorHandler(e)}finally{try{this.afterRenderEffectManager.execute()}catch(e){this.internalErrorHandler(e)}this._runningTick=!1}}attachView(e){const i=e;this._views.push(i),i.attachToAppRef(this)}detachView(e){const i=e;e0(this._views,i),i.detachFromAppRef()}_loadComponent(e){this.attachView(e.hostView),this.tick(),this.components.push(e);const i=this._injector.get(v2,[]);[...this._bootstrapListeners,...i].forEach(r=>r(e))}ngOnDestroy(){if(!this._destroyed)try{this._destroyListeners.forEach(e=>e()),this._views.slice().forEach(e=>e.destroy())}finally{this._destroyed=!0,this._views=[],this._bootstrapListeners=[],this._destroyListeners=[]}}onDestroy(e){return this._destroyListeners.push(e),()=>e0(this._destroyListeners,e)}destroy(){if(this._destroyed)throw new F(406,!1);const e=this._injector;e.destroy&&!e.destroyed&&e.destroy()}get viewCount(){return this._views.length}warnIfDestroyed(){}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();function e0(n,t){const e=n.indexOf(t);e>-1&&n.splice(e,1)}let JQ=(()=>{class n{constructor(){this.zone=Hi(Rr),this.applicationRef=Hi(Ku)}initialize(){this._onMicrotaskEmptySubscription||(this._onMicrotaskEmptySubscription=this.zone.onMicrotaskEmpty.subscribe({next:()=>{this.zone.run(()=>{this.applicationRef.tick()})}}))}ngOnDestroy(){this._onMicrotaskEmptySubscription?.unsubscribe()}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();function b2(n){return[{provide:Rr,useFactory:n},{provide:yu,multi:!0,useFactory:()=>{const t=Hi(JQ,{optional:!0});return()=>t.initialize()}},{provide:yu,multi:!0,useFactory:()=>{const t=Hi(tG);return()=>{t.initialize()}}},{provide:IN,useFactory:KQ}]}function KQ(){const n=Hi(Rr),t=Hi(nh);return e=>n.runOutsideAngular(()=>t.handleError(e))}function eG(n){return function b1(n){return{\u0275providers:n}}([[],b2(()=>new Rr(function M2(n){return{enableLongStackTrace:!1,shouldCoalesceEventChangeDetection:n?.eventCoalescing??!1,shouldCoalesceRunChangeDetection:n?.runCoalescing??!1}}(n)))])}let tG=(()=>{class n{constructor(){this.subscription=new As,this.initialized=!1,this.zone=Hi(Rr),this.pendingTasks=Hi(Lw)}initialize(){if(this.initialized)return;this.initialized=!0;let e=null;!this.zone.isStable&&!this.zone.hasPendingMacrotasks&&!this.zone.hasPendingMicrotasks&&(e=this.pendingTasks.add()),this.zone.runOutsideAngular(()=>{this.subscription.add(this.zone.onStable.subscribe(()=>{Rr.assertNotInAngularZone(),queueMicrotask(()=>{null!==e&&!this.zone.hasPendingMacrotasks&&!this.zone.hasPendingMicrotasks&&(this.pendingTasks.remove(e),e=null)})}))}),this.subscription.add(this.zone.onUnstable.subscribe(()=>{Rr.assertInAngularZone(),e??=this.pendingTasks.add()}))}ngOnDestroy(){this.subscription.unsubscribe()}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();const ah=new Ht("",{providedIn:"root",factory:()=>Hi(ah,xi.Optional|xi.SkipSelf)||function iG(){return typeof $localize<"u"&&$localize.locale||$u}()}),Rw=new Ht("");let nc=null;function DG(n){try{const{rootComponent:t,appProviders:e,platformProviders:i}=n,r=function aG(n=[]){if(nc)return nc;const t=function E2(n=[],t){return Wo.create({name:t,providers:[{provide:C1,useValue:"platform"},{provide:Rw,useValue:new Set([()=>nc=null])},...n]})}(n);return nc=t,function m2(){!function Mb(n){$d=n}(()=>{throw new F(600,!1)})}(),function D2(n){n.get(oL,null)?.forEach(e=>e())}(t),t}(i),s=[eG(),...e||[]],a=new zP({providers:s,parent:r,debugName:"",runEnvironmentInitializers:!1}).injector,l=a.get(Rr);return l.run(()=>{a.resolveInjectorInitializers();const h=a.get(nh,null);let c;l.runOutsideAngular(()=>{c=l.onError.subscribe({next:f=>{h.handleError(f)}})});const d=()=>a.destroy(),u=r.get(Rw);return u.add(d),a.onDestroy(()=>{c.unsubscribe(),u.delete(d)}),function y2(n,t,e){try{const i=e();return lw(i)?i.catch(r=>{throw t.runOutsideAngular(()=>n.handleError(r)),r}):i}catch(i){throw t.runOutsideAngular(()=>n.handleError(i)),i}}(h,l,()=>{const f=a.get(zw);return f.runInitializers(),f.donePromise.then(()=>{!function Ck(n){so(n,"Expected localeId to be defined"),"string"==typeof n&&(wk=n.toLowerCase().replace(/_/g,"-"))}(a.get(ah,$u)||$u);const g=a.get(Ku);return void 0!==t&&g.bootstrap(t),g})})})}catch(t){return Promise.reject(t)}}let $2=null;function Ww(){return $2}class UG{}const ad=new Ht("");let sq=(()=>{class n{static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275mod=Lm({type:n})}static{this.\u0275inj=mp({})}}return n})();function uz(n){return"server"===n}class kq extends UG{constructor(){super(...arguments),this.supportsDOMEvents=!0}}class aC extends kq{static makeCurrent(){!function _G(n){$2??=n}(new aC)}onAndCancel(t,e,i){return t.addEventListener(e,i),()=>{t.removeEventListener(e,i)}}dispatchEvent(t,e){t.dispatchEvent(e)}remove(t){t.parentNode&&t.parentNode.removeChild(t)}createElement(t,e){return(e=e||this.getDefaultDocument()).createElement(t)}createHtmlDocument(){return document.implementation.createHTMLDocument("fakeTitle")}getDefaultDocument(){return document}isElementNode(t){return t.nodeType===Node.ELEMENT_NODE}isShadowRoot(t){return t instanceof DocumentFragment}getGlobalEventTarget(t,e){return"window"===e?window:"document"===e?t:"body"===e?t.body:null}getBaseHref(t){const e=function Pq(){return wg=wg||document.querySelector("base"),wg?wg.getAttribute("href"):null}();return null==e?null:function zq(n){return new URL(n,document.baseURI).pathname}(e)}resetBaseElement(){wg=null}getUserAgent(){return window.navigator.userAgent}getCookie(t){return function xX(n,t){t=encodeURIComponent(t);for(const e of n.split(";")){const i=e.indexOf("="),[r,s]=-1==i?[e,""]:[e.slice(0,i),e.slice(i+1)];if(r.trim()===t)return decodeURIComponent(s)}return null}(document.cookie,t)}}let wg=null,Hq=(()=>{class n{build(){return new XMLHttpRequest}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();const lC=new Ht("");let vz=(()=>{class n{constructor(e,i){this._zone=i,this._eventNameToPlugin=new Map,e.forEach(r=>{r.manager=this}),this._plugins=e.slice().reverse()}addEventListener(e,i,r){return this._findPluginFor(i).addEventListener(e,i,r)}getZone(){return this._zone}_findPluginFor(e){let i=this._eventNameToPlugin.get(e);if(i)return i;if(i=this._plugins.find(s=>s.supports(e)),!i)throw new F(5101,!1);return this._eventNameToPlugin.set(e,i),i}static{this.\u0275fac=function(i){return new(i||n)(_i(lC),_i(Rr))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();class mz{constructor(t){this._doc=t}}const hC="ng-app-id";let yz=(()=>{class n{constructor(e,i,r,s={}){this.doc=e,this.appId=i,this.nonce=r,this.platformId=s,this.styleRef=new Map,this.hostNodes=new Set,this.styleNodesInDOM=this.collectServerRenderedStyles(),this.platformIsServer=uz(s),this.resetHostNodes()}addStyles(e){for(const i of e)1===this.changeUsageCount(i,1)&&this.onStyleAdded(i)}removeStyles(e){for(const i of e)this.changeUsageCount(i,-1)<=0&&this.onStyleRemoved(i)}ngOnDestroy(){const e=this.styleNodesInDOM;e&&(e.forEach(i=>i.remove()),e.clear());for(const i of this.getAllStyles())this.onStyleRemoved(i);this.resetHostNodes()}addHost(e){this.hostNodes.add(e);for(const i of this.getAllStyles())this.addStyleToHost(e,i)}removeHost(e){this.hostNodes.delete(e)}getAllStyles(){return this.styleRef.keys()}onStyleAdded(e){for(const i of this.hostNodes)this.addStyleToHost(i,e)}onStyleRemoved(e){const i=this.styleRef;i.get(e)?.elements?.forEach(r=>r.remove()),i.delete(e)}collectServerRenderedStyles(){const e=this.doc.head?.querySelectorAll(`style[${hC}="${this.appId}"]`);if(e?.length){const i=new Map;return e.forEach(r=>{null!=r.textContent&&i.set(r.textContent,r)}),i}return null}changeUsageCount(e,i){const r=this.styleRef;if(r.has(e)){const s=r.get(e);return s.usage+=i,s.usage}return r.set(e,{usage:i,elements:[]}),i}getStyleElement(e,i){const r=this.styleNodesInDOM,s=r?.get(i);if(s?.parentNode===e)return r.delete(i),s.removeAttribute(hC),s;{const o=this.doc.createElement("style");return this.nonce&&o.setAttribute("nonce",this.nonce),o.textContent=i,this.platformIsServer&&o.setAttribute(hC,this.appId),e.appendChild(o),o}}addStyleToHost(e,i){const r=this.getStyleElement(e,i),s=this.styleRef,o=s.get(i)?.elements;o?o.push(r):s.set(i,{elements:[r],usage:1})}resetHostNodes(){const e=this.hostNodes;e.clear(),e.add(this.doc.head)}static{this.\u0275fac=function(i){return new(i||n)(_i(ad),_i(N1),_i(aL,8),_i(bu))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();const cC={svg:"http://www.w3.org/2000/svg",xhtml:"http://www.w3.org/1999/xhtml",xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/",math:"http://www.w3.org/1998/MathML/"},dC=/%COMP%/g,Uq=new Ht("",{providedIn:"root",factory:()=>!0});function Iz(n,t){return t.map(e=>e.replace(dC,n))}let bz=(()=>{class n{constructor(e,i,r,s,o,a,l,h=null){this.eventManager=e,this.sharedStylesHost=i,this.appId=r,this.removeStylesOnCompDestroy=s,this.doc=o,this.platformId=a,this.ngZone=l,this.nonce=h,this.rendererByCompId=new Map,this.platformIsServer=uz(a),this.defaultRenderer=new uC(e,o,l,this.platformIsServer)}createRenderer(e,i){if(!e||!i)return this.defaultRenderer;this.platformIsServer&&i.encapsulation===ba.ShadowDom&&(i={...i,encapsulation:ba.Emulated});const r=this.getOrCreateRenderer(e,i);return r instanceof wz?r.applyToHost(e):r instanceof fC&&r.applyStyles(),r}getOrCreateRenderer(e,i){const r=this.rendererByCompId;let s=r.get(i.id);if(!s){const o=this.doc,a=this.ngZone,l=this.eventManager,h=this.sharedStylesHost,c=this.removeStylesOnCompDestroy,d=this.platformIsServer;switch(i.encapsulation){case ba.Emulated:s=new wz(l,h,i,this.appId,c,o,a,d);break;case ba.ShadowDom:return new Yq(l,h,e,i,o,a,this.nonce,d);default:s=new fC(l,h,i,c,o,a,d)}r.set(i.id,s)}return s}ngOnDestroy(){this.rendererByCompId.clear()}static{this.\u0275fac=function(i){return new(i||n)(_i(vz),_i(yz),_i(N1),_i(Uq),_i(ad),_i(bu),_i(Rr),_i(aL))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();class uC{constructor(t,e,i,r){this.eventManager=t,this.doc=e,this.ngZone=i,this.platformIsServer=r,this.data=Object.create(null),this.throwOnSyntheticProps=!0,this.destroyNode=null}destroy(){}createElement(t,e){return e?this.doc.createElementNS(cC[e]||e,t):this.doc.createElement(t)}createComment(t){return this.doc.createComment(t)}createText(t){return this.doc.createTextNode(t)}appendChild(t,e){(Mz(t)?t.content:t).appendChild(e)}insertBefore(t,e,i){t&&(Mz(t)?t.content:t).insertBefore(e,i)}removeChild(t,e){t&&t.removeChild(e)}selectRootElement(t,e){let i="string"==typeof t?this.doc.querySelector(t):t;if(!i)throw new F(-5104,!1);return e||(i.textContent=""),i}parentNode(t){return t.parentNode}nextSibling(t){return t.nextSibling}setAttribute(t,e,i,r){if(r){e=r+":"+e;const s=cC[r];s?t.setAttributeNS(s,e,i):t.setAttribute(e,i)}else t.setAttribute(e,i)}removeAttribute(t,e,i){if(i){const r=cC[i];r?t.removeAttributeNS(r,e):t.removeAttribute(`${i}:${e}`)}else t.removeAttribute(e)}addClass(t,e){t.classList.add(e)}removeClass(t,e){t.classList.remove(e)}setStyle(t,e,i,r){r&(ec.DashCase|ec.Important)?t.style.setProperty(e,i,r&ec.Important?"important":""):t.style[e]=i}removeStyle(t,e,i){i&ec.DashCase?t.style.removeProperty(e):t.style[e]=""}setProperty(t,e,i){null!=t&&(t[e]=i)}setValue(t,e){t.nodeValue=e}listen(t,e,i){if("string"==typeof t&&!(t=Ww().getGlobalEventTarget(this.doc,t)))throw new Error(`Unsupported event target ${t} for event ${e}`);return this.eventManager.addEventListener(t,e,this.decoratePreventDefault(i))}decoratePreventDefault(t){return e=>{if("__ngUnwrap__"===e)return t;!1===(this.platformIsServer?this.ngZone.runGuarded(()=>t(e)):t(e))&&e.preventDefault()}}}function Mz(n){return"TEMPLATE"===n.tagName&&void 0!==n.content}class Yq extends uC{constructor(t,e,i,r,s,o,a,l){super(t,s,o,l),this.sharedStylesHost=e,this.hostEl=i,this.shadowRoot=i.attachShadow({mode:"open"}),this.sharedStylesHost.addHost(this.shadowRoot);const h=Iz(r.id,r.styles);for(const c of h){const d=document.createElement("style");a&&d.setAttribute("nonce",a),d.textContent=c,this.shadowRoot.appendChild(d)}}nodeOrShadowRoot(t){return t===this.hostEl?this.shadowRoot:t}appendChild(t,e){return super.appendChild(this.nodeOrShadowRoot(t),e)}insertBefore(t,e,i){return super.insertBefore(this.nodeOrShadowRoot(t),e,i)}removeChild(t,e){return super.removeChild(this.nodeOrShadowRoot(t),e)}parentNode(t){return this.nodeOrShadowRoot(super.parentNode(this.nodeOrShadowRoot(t)))}destroy(){this.sharedStylesHost.removeHost(this.shadowRoot)}}class fC extends uC{constructor(t,e,i,r,s,o,a,l){super(t,s,o,a),this.sharedStylesHost=e,this.removeStylesOnCompDestroy=r,this.styles=l?Iz(l,i.styles):i.styles}applyStyles(){this.sharedStylesHost.addStyles(this.styles)}destroy(){this.removeStylesOnCompDestroy&&this.sharedStylesHost.removeStyles(this.styles)}}class wz extends fC{constructor(t,e,i,r,s,o,a,l){const h=r+"-"+i.id;super(t,e,i,s,o,a,l,h),this.contentAttr=function jq(n){return"_ngcontent-%COMP%".replace(dC,n)}(h),this.hostAttr=function Vq(n){return"_nghost-%COMP%".replace(dC,n)}(h)}applyToHost(t){this.applyStyles(),this.setAttribute(t,this.hostAttr,"")}createElement(t,e){const i=super.createElement(t,e);return super.setAttribute(i,this.contentAttr,""),i}}let Qq=(()=>{class n extends mz{constructor(e){super(e)}supports(e){return!0}addEventListener(e,i,r){return e.addEventListener(i,r,!1),()=>this.removeEventListener(e,i,r)}removeEventListener(e,i,r){return e.removeEventListener(i,r)}static{this.\u0275fac=function(i){return new(i||n)(_i(ad))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();const Cz=["alt","control","meta","shift"],Gq={"\b":"Backspace","\t":"Tab","\x7f":"Delete","\x1b":"Escape",Del:"Delete",Esc:"Escape",Left:"ArrowLeft",Right:"ArrowRight",Up:"ArrowUp",Down:"ArrowDown",Menu:"ContextMenu",Scroll:"ScrollLock",Win:"OS"},Xq={alt:n=>n.altKey,control:n=>n.ctrlKey,meta:n=>n.metaKey,shift:n=>n.shiftKey};let qq=(()=>{class n extends mz{constructor(e){super(e)}supports(e){return null!=n.parseEventName(e)}addEventListener(e,i,r){const s=n.parseEventName(i),o=n.eventCallback(s.fullKey,r,this.manager.getZone());return this.manager.getZone().runOutsideAngular(()=>Ww().onAndCancel(e,s.domEventName,o))}static parseEventName(e){const i=e.toLowerCase().split("."),r=i.shift();if(0===i.length||"keydown"!==r&&"keyup"!==r)return null;const s=n._normalizeKey(i.pop());let o="",a=i.indexOf("code");if(a>-1&&(i.splice(a,1),o="code."),Cz.forEach(h=>{const c=i.indexOf(h);c>-1&&(i.splice(c,1),o+=h+".")}),o+=s,0!=i.length||0===s.length)return null;const l={};return l.domEventName=r,l.fullKey=o,l}static matchEventFullKeyCode(e,i){let r=Gq[e.key]||e.key,s="";return i.indexOf("code.")>-1&&(r=e.code,s="code."),!(null==r||!r)&&(r=r.toLowerCase()," "===r?r="space":"."===r&&(r="dot"),Cz.forEach(o=>{o!==r&&(0,Xq[o])(e)&&(s+=o+".")}),s+=r,s===i)}static eventCallback(e,i,r){return s=>{n.matchEventFullKeyCode(s,e)&&r.runGuarded(()=>i(s))}}static _normalizeKey(e){return"esc"===e?"escape":e}static{this.\u0275fac=function(i){return new(i||n)(_i(ad))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();function Ez(n){return{appProviders:[...i$,...n?.providers??[]],platformProviders:e$}}const e$=[{provide:bu,useValue:"browser"},{provide:oL,useValue:function Zq(){aC.makeCurrent()},multi:!0},{provide:ad,useFactory:function Kq(){return function Aj(n){L1=n}(document),document},deps:[]}],i$=[{provide:C1,useValue:"root"},{provide:nh,useFactory:function Jq(){return new nh},deps:[]},{provide:lC,useClass:Qq,multi:!0,deps:[ad,Rr,bu]},{provide:lC,useClass:qq,multi:!0,deps:[ad]},bz,yz,vz,{provide:oN,useExisting:bz},{provide:class cq{},useClass:Hq,deps:[]},[]];var o$=0,pC=!1;function w0(n,t){var e=t;return e.unshift(void 0),new(Function.prototype.bind.apply(n,e))}function Y(n,t){for(var e=t,i=n.replace(/\[/g,".").replace(/\]/g,"").split("."),r=0;r"u"}function Ei(n){return n+"_"+o$++}function E0(n,t){return n===t||!(n===document||!n)&&E0(n.parentNode,t)}function Dg(n){try{throw new Error(n)}catch(t){throw new Error(t.message+"\n"+t.stack)}}function Re(n){var t=n+"";return t.match(/auto|cm|mm|in|px|pt|pc|%|em|ex|ch|rem|vw|vh|vmin|vmax/)?t:t+"px"}function ce(){return pC}var xg,n,t,d$={latn:{_digits:"0123456789",_type:"numeric"}},Lz={decimal:".",group:",",percentSign:"%",plusSign:"+",minusSign:"-",infinity:"\u221e",nan:"NaN",exponential:"E"},Nz=[0,1,2,3,4,5,6,7,8,9],Hr=function(){function n(){}return n.getMainObject=function(t,e){return Y(ce()?e:"main."+e,t)},n.getNumberingSystem=function(t){return Y("supplemental.numberingSystems",t)||this.numberingSystems},n.reverseObject=function(t,e){for(var r={},s=0,o=e||Object.keys(t);s13&&(p+=1,o-=12),o-=1,a=p-4716;var y=u-24e5,S=10631/30,b=u-1948084,M=Math.floor(b/10631);b-=10631*M;var w=Math.floor((b-.1335)/S),C=30*M+w;b-=Math.floor(w*S+.1335);var D=Math.floor((b+28.5001)/29.5);13===D&&(D=12);for(var A=b-Math.floor(29.5001*D-29),x=0;xy);x++);var P=x+16260,L=Math.floor((P-1)/12),O=L+1,N=P-12*L,T=y-t[x-1]+1;return(T+"").length>2&&(T=A,N=D,O=C),{year:O,month:N,date:T}},n.toGregorian=function i(r,s,o){var g=Math.floor(o+t[12*(r-1)+1+(s-1)-16260-1]-1+24e5+.5),v=Math.floor((g-1867216.25)/36524.25),y=1524+(v=g+1+v-Math.floor(v/4)),S=Math.floor((y-122.1)/365.25),b=Math.floor(365.25*S),M=Math.floor((y-b)/30.6001),w=y-b-Math.floor(30.6001*M),C=M-(M>13.5?13:1),D=S-(C>2.5?4716:4715);return D<=0&&C--,new Date(D+"/"+C+"/"+w)};var ut,p$=/\/MMMMM|MMMM|MMM|a|LLLL|LLL|EEEEE|EEEE|E|K|cccc|ccc|WW|W|G+|z+/gi,Oz="stand-alone",g$=["sun","mon","tue","wed","thu","fri","sat"],kz={m:"getMinutes",h:"getHours",H:"getHours",s:"getSeconds",d:"getDate",f:"getMilliseconds"},Pz=function(){function n(){}return n.dateFormat=function(t,e,i){var r=this,s=ut.getDependables(i,t,e.calendar),o=Y("parserObject.numbers",s),a=s.dateObject,l={isIslamic:ut.islamicRegex.test(e.calendar)};ce()&&e.isServerRendered&&(e=ut.compareBlazorDateFormats(e,t));var h=e.format||ut.getResultantPattern(e.skeleton,s.dateObject,e.type,!1,ce()?t:"");if(l.dateSeperator=ce()?Y("dateSeperator",a):ut.getDateSeparator(s.dateObject),st(h))Dg("Format options or type given must be invalid");else{h=ut.ConvertDateToWeekFormat(h),ce()&&(h=h.replace(/tt/,"a")),l.pattern=h,l.numMapper=ce()?ze({},o):Hr.getNumberMapper(s.parserObject,Hr.getNumberingSystem(i));for(var d=0,u=h.match(p$)||[];d2?r+=e.month[""+u]:p=!0;break;case"E":case"c":r+=e.weekday[""+g$[t.getDay()]];break;case"H":case"h":case"m":case"s":case"d":case"f":if(p=!0,"d"===d)u=o.date;else if("f"===d){p=!1,g=!0;var y=(f=(f=t[""+kz[""+d]]().toString()).substring(0,c)).length;if(c!==y){if(c>3)continue;for(var S=0;S0?1:0],o=Math.abs(t);return s.replace(/HH?|mm/g,function(a){var l=a.length,h=-1!==a.indexOf("H");return i.checkTwodigitNumber(Math.floor(h?o/60:o%60),l)})},n}(),zz={ms:"minimumSignificantDigits",ls:"maximumSignificantDigits",mf:"minimumFractionDigits",lf:"maximumFractionDigits"},nf=["infinity","nan","group","decimal","exponential"],Rz=function(){function n(){}return n.numberFormatter=function(t,e,i){var l,r=this,s=ze({},e),o={},a={},h=ut.getDependables(i,t,"",!0),c=h.numericObject;a.numberMapper=ce()?ze({},c):Hr.getNumberMapper(h.parserObject,Hr.getNumberingSystem(i),!0),a.currencySymbol=ce()?Y("currencySymbol",c):ut.getCurrencySymbol(h.numericObject,s.currency||Lg,e.altSymbol,e.ignoreCurrency),a.percentSymbol=ce()?Y("numberSymbols.percentSign",c):a.numberMapper.numberSymbols.percentSign,a.minusSymbol=ce()?Y("numberSymbols.minusSign",c):a.numberMapper.numberSymbols.minusSign;var d=a.numberMapper.numberSymbols;if(e.format&&!ut.formatRegex.test(e.format))o=ut.customFormat(e.format,a,h.numericObject),!st(s.useGrouping)&&s.useGrouping&&(s.useGrouping=o.pData.useGrouping);else{if(ze(s,ut.getProperNumericSkeleton(e.format||"N")),s.isCurrency="currency"===s.type,s.isPercent="percent"===s.type,ce()||(l=ut.getSymbolPattern(s.type,a.numberMapper.numberSystem,h.numericObject,s.isAccount)),s.groupOne=this.checkValueRange(s.maximumSignificantDigits,s.minimumSignificantDigits,!0),this.checkValueRange(s.maximumFractionDigits,s.minimumFractionDigits,!1,!0),st(s.fractionDigits)||(s.minimumFractionDigits=s.maximumFractionDigits=s.fractionDigits),st(s.useGrouping)&&(s.useGrouping=!0),s.isCurrency&&!ce()&&(l=l.replace(/\u00A4/g,ut.defaultCurrency)),ce())o.nData=ze({},{},Y(s.type+"nData",c)),o.pData=ze({},{},Y(s.type+"pData",c)),"currency"===s.type&&e.currency&&ut.replaceBlazorCurrency([o.pData,o.nData],a.currencySymbol,e.currency);else{var u=l.split(";");o.nData=ut.getFormatData(u[1]||"-"+u[0],!0,a.currencySymbol),o.pData=ut.getFormatData(u[0],!1,a.currencySymbol),s.useGrouping&&(s.groupSeparator=d[nf[2]],s.groupData=this.getGroupingDetails(u[0]))}if(st(s.minimumFractionDigits)&&(s.minimumFractionDigits=o.nData.minimumFraction),st(s.maximumFractionDigits)){var p=o.nData.maximumFraction;s.maximumFractionDigits=st(p)&&s.isPercent?0:p}var g=s.minimumFractionDigits,v=s.maximumFractionDigits;!st(g)&&!st(v)&&g>v&&(s.maximumFractionDigits=g)}return ze(o.nData,s),ze(o.pData,s),function(y){return isNaN(y)?d[nf[1]]:isFinite(y)?r.intNumberFormatter(y,o,a,e):d[nf[0]]}},n.getGroupingDetails=function(t){var e={},i=t.match(ut.negativeDataRegex);if(i&&i[4]){var r=i[4],s=r.lastIndexOf(",");if(-1!==s){var o=r.split(".")[0];e.primary=o.length-s-1;var a=r.lastIndexOf(",",s-1);-1!==a&&(e.secondary=s-1-a)}}return e},n.checkValueRange=function(t,e,i,r){var s=r?"f":"s",o=0,a=zz["l"+s],l=zz["m"+s];if(st(t)||(this.checkRange(t,a,r),o++),st(e)||(this.checkRange(e,l,r),o++),2===o){if(!(tr[1])&&Dg(e+"value must be within the range"+r[0]+"to"+r[1])},n.intNumberFormatter=function(t,e,i,r){var s;if(!st(e.nData.type)){t<0?(t*=-1,s=e.nData):s=0===t&&e.zeroData||e.pData;var o="";if(s.isPercent&&(t*=100),s.groupOne)o=this.processSignificantDigits(t,s.minimumSignificantDigits,s.maximumSignificantDigits);else if(o=this.processFraction(t,s.minimumFractionDigits,s.maximumFractionDigits,r),s.minimumIntegerDigits&&(o=this.processMinimumIntegers(o,s.minimumIntegerDigits)),i.isCustomFormat&&s.minimumFractionDigits=0&&"0"===l[parseInt(c.toString(),10)]&&c>=s.minimumFractionDigits;c--)l=l.slice(0,c);o=a[0]+"."+l}return"scientific"===s.type&&(o=(o=t.toExponential(s.maximumFractionDigits)).replace("e",i.numberMapper.numberSymbols[nf[4]])),o=o.replace(".",i.numberMapper.numberSymbols[nf[3]]),o="#,###,,;(#,###,,)"===s.format?this.customPivotFormat(parseInt(o,10)):o,s.useGrouping&&(o=this.groupNumbers(o,s.groupData.primary,s.groupSeparator||",",i.numberMapper.numberSymbols[nf[3]]||".",s.groupData.secondary)),o=Hr.convertValueParts(o,ut.latnParseRegex,i.numberMapper.mapper),"N/A"===s.nlead?s.nlead:"0"===o&&r&&"0"===r.format?o+s.nend:s.nlead+o+s.nend}},n.processSignificantDigits=function(t,e,i){var r=t+"";return r.lengthe;)c=l.slice(h-e,h)+(c.length?i+c:""),h-=e,o&&(e=s,o=!1);return a[0]=l.slice(0,h)+(c.length?i:"")+c,a.join(r)},n.processFraction=function(t,e,i,r){var s=(t+"").split(".")[1],o=s?s.length:0;if(e&&oi||0===i))return t.toFixed(i);var h=t+"";return"0"===h[0]&&r&&"###.00"===r.format&&(h=h.slice(1)),h},n.processMinimumIntegers=function(t,e){var i=t.split("."),r=i[0],s=r.length;if(s=5e5){var r=(t/=1e6).toString().split(".")[1];return r&&+r.substring(0,1)>=5?Math.ceil(t).toString():Math.floor(t).toString()}return""},n}(),Tg=(new RegExp("^([^0-9]*)(([0-9,]*[0-9]+)(.[0-9]+)?)([Ee][+-]?[0-9]+)?([^0-9]*)$"),function(){function n(t){this.ranArray=[],this.boundedEvents={},!m(t)&&(this.context=t)}return n.prototype.on=function(t,e,i,r){if(!m(e)){var s=i||this.context;if(this.notExist(t))return void(this.boundedEvents[""+t]=[{handler:e,context:s,id:r}]);m(r)?this.isHandlerPresent(this.boundedEvents[""+t],e)||this.boundedEvents[""+t].push({handler:e,context:s}):-1===this.ranArray.indexOf(r)&&(this.ranArray.push(r),this.boundedEvents[""+t].push({handler:e,context:s,id:r}))}},n.prototype.off=function(t,e,i){if(!this.notExist(t)){var r=Y(t,this.boundedEvents);if(e){for(var s=0;s1&&(U.fractionDigits=parseInt(z[2],10)),U}function p(T,z,U,B){var j=B?{}:{nlead:"",nend:""},Q=T.match(n.customRegex);if(Q){B||(j.nlead=g(Q[1],U),j.nend=g(Q[10],U),j.groupPattern=Q[4]);var oe=Q[7];if(oe&&z){var ue=oe.match(t);j.minimumFraction=m(ue)?0:ue.length,j.maximumFraction=oe.length-1}}return j}function g(T,z){return T?(T=T.replace(n.defaultCurrency,z),""===z?T.trim():T):""}function v(T,z,U,B){return B?"$":Y("currencies."+z+(U?"."+U:".symbol"),T)||Y("currencies."+z+".symbol-alt-narrow",T)||"$"}function S(T,z,U){var B={type:"decimal",minimumFractionDigits:0,maximumFractionDigits:0},j=T.match(n.customRegex);if(m(j)||""===j[5]&&"N/A"!==T)return B.type=void 0,B;B.nlead=j[1],B.nend=j[10];var Q=j[6],oe=!!Q.match(/ $/g),ue=-1!==Q.replace(/ $/g,"").indexOf(" ");B.useGrouping=-1!==Q.indexOf(",")||ue,Q=Q.replace(/,/g,"");var fe=j[7];if(-1!==Q.indexOf("0")&&(B.minimumIntegerDigits=Q.length-Q.indexOf("0")),m(fe)||(B.minimumFractionDigits=fe.lastIndexOf("0"),B.maximumFractionDigits=fe.lastIndexOf("#"),-1===B.minimumFractionDigits&&(B.minimumFractionDigits=0),(-1===B.maximumFractionDigits||B.maximumFractionDigitsQ.lastIndexOf("'"))){B[""+a[parseInt(j.toString(),10)]]=Q.substr(0,oe)+U+Q.substr(oe+1),B[""+a[""+z]]=!0,B.type=B.isCurrency?"currency":"percent";break}}return B}function C(T,z){if(-1!==T.indexOf(",")){var U=T.split(",");T=U[0]+Y("numberMapper.numberSymbols.group",z)+U[1].replace(".",Y("numberMapper.numberSymbols.decimal",z))}else T=T.replace(".",Y("numberMapper.numberSymbols.decimal",z));return T}function A(T,z,U){T+=".";for(var B=0;B0;Q-=3)T=","+U[Q-2]+U[Q-1]+U[parseInt(Q.toString(),10)]+T;return T=T.slice(1),z[1]?T+"."+z[1]:T}n.dateParseRegex=/([a-z])\1*|'([^']|'')+'|''|./gi,n.basicPatterns=["short","medium","long","full"],n.defaultObject={dates:{calendars:{gregorian:{months:{"stand-alone":{abbreviated:{1:"Jan",2:"Feb",3:"Mar",4:"Apr",5:"May",6:"Jun",7:"Jul",8:"Aug",9:"Sep",10:"Oct",11:"Nov",12:"Dec"},narrow:{1:"J",2:"F",3:"M",4:"A",5:"M",6:"J",7:"J",8:"A",9:"S",10:"O",11:"N",12:"D"},wide:{1:"January",2:"February",3:"March",4:"April",5:"May",6:"June",7:"July",8:"August",9:"September",10:"October",11:"November",12:"December"}}},days:{"stand-alone":{abbreviated:{sun:"Sun",mon:"Mon",tue:"Tue",wed:"Wed",thu:"Thu",fri:"Fri",sat:"Sat"},narrow:{sun:"S",mon:"M",tue:"T",wed:"W",thu:"T",fri:"F",sat:"S"},short:{sun:"Su",mon:"Mo",tue:"Tu",wed:"We",thu:"Th",fri:"Fr",sat:"Sa"},wide:{sun:"Sunday",mon:"Monday",tue:"Tuesday",wed:"Wednesday",thu:"Thursday",fri:"Friday",sat:"Saturday"}}},dayPeriods:{format:{wide:{am:"AM",pm:"PM"}}},eras:{eraNames:{0:"Before Christ","0-alt-variant":"Before Common Era",1:"Anno Domini","1-alt-variant":"Common Era"},eraAbbr:{0:"BC","0-alt-variant":"BCE",1:"AD","1-alt-variant":"CE"},eraNarrow:{0:"B","0-alt-variant":"BCE",1:"A","1-alt-variant":"CE"}},dateFormats:{full:"EEEE, MMMM d, y",long:"MMMM d, y",medium:"MMM d, y",short:"M/d/yy"},timeFormats:{full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},dateTimeFormats:{full:"{1} 'at' {0}",long:"{1} 'at' {0}",medium:"{1}, {0}",short:"{1}, {0}",availableFormats:{d:"d",E:"ccc",Ed:"d E",Ehm:"E h:mm a",EHm:"E HH:mm",Ehms:"E h:mm:ss a",EHms:"E HH:mm:ss",Gy:"y G",GyMMM:"MMM y G",GyMMMd:"MMM d, y G",GyMMMEd:"E, MMM d, y G",h:"h a",H:"HH",hm:"h:mm a",Hm:"HH:mm",hms:"h:mm:ss a",Hms:"HH:mm:ss",hmsv:"h:mm:ss a v",Hmsv:"HH:mm:ss v",hmv:"h:mm a v",Hmv:"HH:mm v",M:"L",Md:"M/d",MEd:"E, M/d",MMM:"LLL",MMMd:"MMM d",MMMEd:"E, MMM d",MMMMd:"MMMM d",ms:"mm:ss",y:"y",yM:"M/y",yMd:"M/d/y",yMEd:"E, M/d/y",yMMM:"MMM y",yMMMd:"MMM d, y",yMMMEd:"E, MMM d, y",yMMMM:"MMMM y"}}},islamic:{months:{"stand-alone":{abbreviated:{1:"Muh.",2:"Saf.",3:"Rab. I",4:"Rab. II",5:"Jum. I",6:"Jum. II",7:"Raj.",8:"Sha.",9:"Ram.",10:"Shaw.",11:"Dhu\u02bbl-Q.",12:"Dhu\u02bbl-H."},narrow:{1:"1",2:"2",3:"3",4:"4",5:"5",6:"6",7:"7",8:"8",9:"9",10:"10",11:"11",12:"12"},wide:{1:"Muharram",2:"Safar",3:"Rabi\u02bb I",4:"Rabi\u02bb II",5:"Jumada I",6:"Jumada II",7:"Rajab",8:"Sha\u02bbban",9:"Ramadan",10:"Shawwal",11:"Dhu\u02bbl-Qi\u02bbdah",12:"Dhu\u02bbl-Hijjah"}}},days:{"stand-alone":{abbreviated:{sun:"Sun",mon:"Mon",tue:"Tue",wed:"Wed",thu:"Thu",fri:"Fri",sat:"Sat"},narrow:{sun:"S",mon:"M",tue:"T",wed:"W",thu:"T",fri:"F",sat:"S"},short:{sun:"Su",mon:"Mo",tue:"Tu",wed:"We",thu:"Th",fri:"Fr",sat:"Sa"},wide:{sun:"Sunday",mon:"Monday",tue:"Tuesday",wed:"Wednesday",thu:"Thursday",fri:"Friday",sat:"Saturday"}}},dayPeriods:{format:{wide:{am:"AM",pm:"PM"}}},eras:{eraNames:{0:"AH"},eraAbbr:{0:"AH"},eraNarrow:{0:"AH"}},dateFormats:{full:"EEEE, MMMM d, y G",long:"MMMM d, y G",medium:"MMM d, y G",short:"M/d/y GGGGG"},timeFormats:{full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},dateTimeFormats:{full:"{1} 'at' {0}",long:"{1} 'at' {0}",medium:"{1}, {0}",short:"{1}, {0}",availableFormats:{d:"d",E:"ccc",Ed:"d E",Ehm:"E h:mm a",EHm:"E HH:mm",Ehms:"E h:mm:ss a",EHms:"E HH:mm:ss",Gy:"y G",GyMMM:"MMM y G",GyMMMd:"MMM d, y G",GyMMMEd:"E, MMM d, y G",h:"h a",H:"HH",hm:"h:mm a",Hm:"HH:mm",hms:"h:mm:ss a",Hms:"HH:mm:ss",M:"L",Md:"M/d",MEd:"E, M/d",MMM:"LLL",MMMd:"MMM d",MMMEd:"E, MMM d",MMMMd:"MMMM d",ms:"mm:ss",y:"y G",yyyy:"y G",yyyyM:"M/y GGGGG",yyyyMd:"M/d/y GGGGG",yyyyMEd:"E, M/d/y GGGGG",yyyyMMM:"MMM y G",yyyyMMMd:"MMM d, y G",yyyyMMMEd:"E, MMM d, y G",yyyyMMMM:"MMMM y G",yyyyQQQ:"QQQ y G",yyyyQQQQ:"QQQQ y G"}}}},timeZoneNames:{hourFormat:"+HH:mm;-HH:mm",gmtFormat:"GMT{0}",gmtZeroFormat:"GMT"}},numbers:{currencies:{USD:{displayName:"US Dollar",symbol:"$","symbol-alt-narrow":"$"},EUR:{displayName:"Euro",symbol:"\u20ac","symbol-alt-narrow":"\u20ac"},GBP:{displayName:"British Pound","symbol-alt-narrow":"\xa3"}},defaultNumberingSystem:"latn",minimumGroupingDigits:"1","symbols-numberSystem-latn":{decimal:".",group:",",list:";",percentSign:"%",plusSign:"+",minusSign:"-",exponential:"E",superscriptingExponent:"\xd7",perMille:"\u2030",infinity:"\u221e",nan:"NaN",timeSeparator:":"},"decimalFormats-numberSystem-latn":{standard:"#,##0.###"},"percentFormats-numberSystem-latn":{standard:"#,##0%"},"currencyFormats-numberSystem-latn":{standard:"\xa4#,##0.00",accounting:"\xa4#,##0.00;(\xa4#,##0.00)"},"scientificFormats-numberSystem-latn":{standard:"#E0"}}},n.blazorDefaultObject={numbers:{mapper:{0:"0",1:"1",2:"2",3:"3",4:"4",5:"5",6:"6",7:"7",8:"8",9:"9"},mapperDigits:"0123456789",numberSymbols:{decimal:".",group:",",plusSign:"+",minusSign:"-",percentSign:"%",nan:"NaN",timeSeparator:":",infinity:"\u221e"},timeSeparator:":",currencySymbol:"$",currencypData:{nlead:"$",nend:"",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},percentpData:{nlead:"",nend:"%",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},percentnData:{nlead:"-",nend:"%",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},currencynData:{nlead:"($",nend:")",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},decimalnData:{nlead:"-",nend:"",groupData:{primary:3},maximumFraction:2,minimumFraction:2},decimalpData:{nlead:"",nend:"",groupData:{primary:3},maximumFraction:2,minimumFraction:2}},dates:{dayPeriods:{am:"AM",pm:"PM"},dateSeperator:"/",days:{abbreviated:{sun:"Sun",mon:"Mon",tue:"Tue",wed:"Wed",thu:"Thu",fri:"Fri",sat:"Sat"},short:{sun:"Su",mon:"Mo",tue:"Tu",wed:"We",thu:"Th",fri:"Fr",sat:"Sa"},wide:{sun:"Sunday",mon:"Monday",tue:"Tuesday",wed:"Wednesday",thu:"Thursday",fri:"Friday",sat:"Saturday"}},months:{abbreviated:{1:"Jan",2:"Feb",3:"Mar",4:"Apr",5:"May",6:"Jun",7:"Jul",8:"Aug",9:"Sep",10:"Oct",11:"Nov",12:"Dec"},wide:{1:"January",2:"February",3:"March",4:"April",5:"May",6:"June",7:"July",8:"August",9:"September",10:"October",11:"November",12:"December"}},eras:{1:"AD"}}},n.monthIndex={3:"abbreviated",4:"wide",5:"narrow",1:"abbreviated"},n.month="months",n.days="days",n.patternMatcher={C:"currency",P:"percent",N:"decimal",A:"currency",E:"scientific"},n.getResultantPattern=l,n.getDependables=h,n.getSymbolPattern=c,n.ConvertDateToWeekFormat=d,n.compareBlazorDateFormats=u,n.getProperNumericSkeleton=f,n.getFormatData=p,n.changeCurrencySymbol=g,n.getCurrencySymbol=v,n.customFormat=function y(T,z,U){for(var B={},j=T.split(";"),Q=["pData","nData","zeroData"],oe=0;oe1,fe.nData=ce()?Y(De.type+"nData",oe):p(ot[1]||"-"+ot[0],!0,Ie),fe.pData=ce()?Y(De.type+"pData",oe):p(ot[0],!1,Ie),!Me[2]&&!z.minimumFractionDigits&&!z.maximumFractionDigits&&(ue=p(Ve.split(";")[0],!0,"",!0).minimumFraction)}if(n.formatRegex.test(z.format)||!z.format){if(ze(Q,f(z.format||"N")),Q.custom=!1,$e="###0",(Q.fractionDigits||z.minimumFractionDigits||z.maximumFractionDigits||ue)&&(Q.fractionDigits&&(z.minimumFractionDigits=z.maximumFractionDigits=Q.fractionDigits),$e=A($e,ue||Q.fractionDigits||z.minimumFractionDigits||0,z.maximumFractionDigits||0)),z.minimumIntegerDigits&&($e=x($e,z.minimumIntegerDigits)),z.useGrouping&&($e=P($e)),"currency"===Q.type||Q.type&&ce()){ce()&&"currency"!==Q.type&&(fe.pData=Y(Q.type+"pData",oe),fe.nData=Y(Q.type+"nData",oe));var hr=$e;$e=fe.pData.nlead+hr+fe.pData.nend,(fe.hasNegativePattern||ce())&&($e+=";"+fe.nData.nlead+hr+fe.nData.nend)}"percent"===Q.type&&!ce()&&($e+=" %")}else $e=z.format.replace(/'/g,'"');return Object.keys(xe).length>0&&($e=B?$e:C($e,xe)),$e},n.fractionDigitsPattern=A,n.minimumIntegerPattern=x,n.groupingPattern=P,n.getWeekData=function L(T,z){var U="sun",B=Y("supplemental.weekData.firstDay",z),j=T;return/en-/.test(j)&&(j=j.slice(3)),j=j.slice(0,2).toUpperCase()+j.substr(2),B&&(U=B[""+j]||B[j.slice(0,2)]||"sun"),o[""+U]},n.replaceBlazorCurrency=function O(T,z,U){var B=function f$(n){return Y(n||"",u$)}(U);if(z!==B)for(var j=0,Q=T;j=0?U:U+7;var j=Math.floor((T.getTime()-z.getTime()-6e4*(T.getTimezoneOffset()-z.getTimezoneOffset()))/864e5)+1;if(U<4){if((B=Math.floor((j+U-1)/7)+1)>52){var oe=new Date(T.getFullYear()+1,0,1).getDay();B=(oe=oe>=0?oe:oe+7)<4?1:53}}else B=Math.floor((j+U-1)/7);return B}}(ut||(ut={}));var sf=function(){function n(t,e,i){this.type="GET",this.emitError=!0,"string"==typeof t?(this.url=t,this.type=m(e)?this.type:e.toUpperCase(),this.contentType=i):La(t)&&Object.keys(t).length>0&&kn(this,t),this.contentType=m(this.contentType)?"application/json; charset=utf-8":this.contentType}return n.prototype.send=function(t){var e=this,i={"application/json":"json","multipart/form-data":"formData","application/octet-stream":"blob","application/x-www-form-urlencoded":"formData"};try{m(this.fetchRequest)&&"GET"===this.type?this.fetchRequest=new Request(this.url,{method:this.type}):m(this.fetchRequest)&&(this.data=m(t)?this.data:t,this.fetchRequest=new Request(this.url,{method:this.type,headers:{"Content-Type":this.contentType},body:this.data}));var r={cancel:!1,fetchRequest:this.fetchRequest};return this.triggerEvent(this.beforeSend,r),r.cancel?null:(this.fetchResponse=fetch(this.fetchRequest),this.fetchResponse.then(function(s){if(e.triggerEvent(e.onLoad,s),!s.ok)throw s;for(var o="text",a=0,l=Object.keys(i);a-1},n.getValue=function(t,e){var i=typeof window<"u"?window.browserDetails:{};return typeof navigator<"u"&&"MacIntel"===navigator.platform&&navigator.maxTouchPoints>1&&!0===n.isTouch&&!mC.CHROME.test(navigator.userAgent)&&(i.isIos=!0,i.isDevice=!0,i.isTouch=!0,i.isPointer=!0,i.isPointer="pointerEnabled"in window.navigator),typeof window<"u"&&window.Capacitor&&"ios"===window.Capacitor.getPlatform()&&(i.isPointer=!1),typeof i[""+t]>"u"?i[""+t]=e.test(n.userAgent):i[""+t]},Object.defineProperty(n,"userAgent",{get:function(){return n.uA},set:function(t){n.uA=t,window.browserDetails={}},enumerable:!0,configurable:!0}),Object.defineProperty(n,"info",{get:function(){return st(window.browserDetails.info)?window.browserDetails.info=n.extractBrowserDetail():window.browserDetails.info},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isIE",{get:function(){return n.getValue("isIE",A$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isTouch",{get:function(){return st(window.browserDetails.isTouch)?window.browserDetails.isTouch="ontouchstart"in window.navigator||window&&window.navigator&&window.navigator.maxTouchPoints>0||"ontouchstart"in window:window.browserDetails.isTouch},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isPointer",{get:function(){return st(window.browserDetails.isPointer)?window.browserDetails.isPointer="pointerEnabled"in window.navigator:window.browserDetails.isPointer},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isMSPointer",{get:function(){return st(window.browserDetails.isMSPointer)?window.browserDetails.isMSPointer="msPointerEnabled"in window.navigator:window.browserDetails.isMSPointer},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isDevice",{get:function(){return n.getValue("isDevice",T$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isIos",{get:function(){return n.getValue("isIos",N$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isIos7",{get:function(){return n.getValue("isIos7",O$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isAndroid",{get:function(){return n.getValue("isAndroid",k$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isWebView",{get:function(){return st(window.browserDetails.isWebView)&&(window.browserDetails.isWebView=!(st(window.cordova)&&st(window.PhoneGap)&&st(window.phonegap)&&"object"!==window.forge)),window.browserDetails.isWebView},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isWindows",{get:function(){return n.getValue("isWindows",P$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"touchStartEvent",{get:function(){return st(window.browserDetails.touchStartEvent)?window.browserDetails.touchStartEvent=n.getTouchStartEvent():window.browserDetails.touchStartEvent},enumerable:!0,configurable:!0}),Object.defineProperty(n,"touchMoveEvent",{get:function(){return st(window.browserDetails.touchMoveEvent)?window.browserDetails.touchMoveEvent=n.getTouchMoveEvent():window.browserDetails.touchMoveEvent},enumerable:!0,configurable:!0}),Object.defineProperty(n,"touchEndEvent",{get:function(){return st(window.browserDetails.touchEndEvent)?window.browserDetails.touchEndEvent=n.getTouchEndEvent():window.browserDetails.touchEndEvent},enumerable:!0,configurable:!0}),Object.defineProperty(n,"touchCancelEvent",{get:function(){return st(window.browserDetails.touchCancelEvent)?window.browserDetails.touchCancelEvent=n.getTouchCancelEvent():window.browserDetails.touchCancelEvent},enumerable:!0,configurable:!0}),n.uA=typeof navigator<"u"?navigator.userAgent:"",n}(),E=function(){function n(){}return n.addOrGetEventData=function(t){return"__eventList"in t?t.__eventList.events:(t.__eventList={},t.__eventList.events=[])},n.add=function(t,e,i,r,s){var a,o=n.addOrGetEventData(t);a=s?function l$(n,t){var e;return function(){for(var i=this,r=[],s=0;s"u"||(e.innerHTML=t.innerHTML?t.innerHTML:"",void 0!==t.className&&(e.className=t.className),void 0!==t.id&&(e.id=t.id),void 0!==t.styles&&e.setAttribute("style",t.styles),void 0!==t.attrs&&Fe(e,t.attrs)),e}function V(n,t){for(var e=Vz(t),i=RegExp,r=0,s=n;r0}function gl(n,t,e){for(var i=document.createDocumentFragment(),r=0,s=n;r0;)i.appendChild(n[0]);else for(var r=0,s=n;r-1&&!r[parseInt(s.toString(),10)].match(/\[.*\]/)){var o=r[parseInt(s.toString(),10)].split("#");if(o[1].match(/^\d/)||o[1].match(t)){var a=r[parseInt(s.toString(),10)].split(".");a[0]=a[0].replace(/#/,"[id='")+"']",r[parseInt(s.toString(),10)]=a.join(".")}}e[parseInt(i.toString(),10)]=r.join(" ")}return e.join(",")}return n}function J(n,t){var e=n;if("function"==typeof e.closest)return e.closest(t);for(;e&&1===e.nodeType;){if(yC(e,t))return e;e=e.parentNode}return null}function je(n,t){void 0!==t&&Object.keys(t).forEach(function(e){n.style[""+e]=t[""+e]})}function yC(n,t){var e=n.matches||n.msMatchesSelector||n.webkitMatchesSelector;return e?e.call(n,t):-1!==[].indexOf.call(document.querySelectorAll(t),n)}var H$=new RegExp("]"),dh=function(){function n(t,e){this.isRendered=!1,this.isComplexArraySetter=!1,this.isServerRendered=!1,this.allowServerDataBinding=!0,this.isProtectedOnChange=!0,this.properties={},this.changedProperties={},this.oldProperties={},this.bulkChanges={},this.refreshing=!1,this.ignoreCollectionWatch=!1,this.finalUpdate=function(){},this.childChangedProperties={},this.modelObserver=new Tg(this),st(e)||(this.element="string"==typeof e?document.querySelector(e):e,m(this.element)||(this.isProtectedOnChange=!1,this.addInstance())),st(t)||this.setProperties(t,!0),this.isDestroyed=!1}return n.prototype.setProperties=function(t,e){var i=this.isProtectedOnChange;this.isProtectedOnChange=!!e,kn(this,t),!0!==e?(kn(this.changedProperties,t),this.dataBind()):ce()&&this.isRendered&&this.serverDataBind(t),this.finalUpdate(),this.changedProperties={},this.oldProperties={},this.isProtectedOnChange=i},n.callChildDataBind=function(t,e){for(var r=0,s=Object.keys(t);r=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Hs=function(n){function t(i){var r=n.call(this,i,void 0)||this;return r.easing={ease:"cubic-bezier(0.250, 0.100, 0.250, 1.000)",linear:"cubic-bezier(0.250, 0.250, 0.750, 0.750)",easeIn:"cubic-bezier(0.420, 0.000, 1.000, 1.000)",easeOut:"cubic-bezier(0.000, 0.000, 0.580, 1.000)",easeInOut:"cubic-bezier(0.420, 0.000, 0.580, 1.000)",elasticInOut:"cubic-bezier(0.5,-0.58,0.38,1.81)",elasticIn:"cubic-bezier(0.17,0.67,0.59,1.81)",elasticOut:"cubic-bezier(0.7,-0.75,0.99,1.01)"},r}var e;return X$(t,n),e=t,t.prototype.animate=function(i,r){var s=this.getModel(r=r||{});if("string"==typeof i)for(var a=0,l=Array.prototype.slice.call(we(i,document));a0?r-1:0,i+=e=-1!==e?"-"+e:"-"+r}return this.controlParent!==this.parentObj&&(i=this.parentObj.getParentKey()+"."+this.propName+e),i},n}(),J$=["grid","pivotview","treegrid","spreadsheet","rangeNavigator","DocumentEditor","listbox","inplaceeditor","PdfViewer","richtexteditor","DashboardLayout","chart","stockChart","circulargauge","diagram","heatmap","lineargauge","maps","slider","smithchart","barcode","sparkline","treemap","bulletChart","kanban","daterangepicker","schedule","gantt","signature","query-builder","drop-down-tree","carousel","filemanager","uploader","accordion","tab","treeview"],tR=[115,121,110,99,102,117,115,105,111,110,46,105,115,76,105,99,86,97,108,105,100,97,116,101,100],iR=function(){function n(t){this.isValidated=!1,this.isLicensed=!0,this.version="27",this.platform=/JavaScript|ASPNET|ASPNETCORE|ASPNETMVC|FileFormats|essentialstudio/i,this.errors={noLicense:"This application was built using a trial version of Syncfusion Essential Studio. To remove the license validation message permanently, a valid license key must be included.",trailExpired:"This application was built using a trial version of Syncfusion Essential Studio. To remove the license validation message permanently, a valid license key must be included.",versionMismatched:"The included Syncfusion license key is invalid.",platformMismatched:"The included Syncfusion license key is invalid.",invalidKey:"The included Syncfusion license key is invalid."},this.manager=function(){var e=null;return{setKey:function i(s){e=s},getKey:function r(){return e}}}(),this.npxManager=function(){return{getKey:function i(){return"npxKeyReplace"}}}(),this.manager.setKey(t)}return n.prototype.validate=function(){if(!this.isValidated&&rf&&!Y(A0(tR),rf)&&!Y("Blazor",rf)){var i=void 0,r=void 0;if(this.manager&&this.manager.getKey()||this.npxManager&&"npxKeyReplace"!==this.npxManager.getKey()){var s=this.getInfoFromKey();if(s&&s.length)for(var o=0,a=s;o"+i+' Claim your FREE account\n
have a Syncfusion account? Sign In
\n
\n ';if(typeof document<"u"&&!m(document)){var t=Si("div",{innerHTML:n});document.body.appendChild(t)}}(),oR=!0),this.render(),this.mount?this.accessMount():this.trigger("created")}},t.prototype.renderComplete=function(e){ce()&&window.sfBlazor.renderComplete(this.element,e),this.isRendered=!0},t.prototype.dataBind=function(){this.injectModules(),n.prototype.dataBind.call(this)},t.prototype.on=function(e,i,r){if("string"==typeof e)this.localObserver.on(e,i,r);else for(var s=0,o=e;s=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},rZ={left:0,top:0,bottom:0,right:0},wC={isDragged:!1},nZ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return aR(t,n),gr([I(0)],t.prototype,"left",void 0),gr([I(0)],t.prototype,"top",void 0),t}(Ee),lf=function(n){function t(i,r){var s=n.call(this,r,i)||this;return s.dragLimit=e.getDefaultPosition(),s.borderWidth=e.getDefaultPosition(),s.padding=e.getDefaultPosition(),s.diffX=0,s.prevLeft=0,s.prevTop=0,s.dragProcessStarted=!1,s.eleTop=0,s.tapHoldTimer=0,s.externalInitialize=!1,s.diffY=0,s.parentScrollX=0,s.parentScrollY=0,s.droppables={},s.bind(),s}var e;return aR(t,n),e=t,t.prototype.bind=function(){this.toggleEvents(),X.isIE&&V([this.element],"e-block-touch"),this.droppables[this.scope]={}},t.getDefaultPosition=function(){return ze({},rZ)},t.prototype.toggleEvents=function(i){var r;st(this.handle)||(r=_(this.handle,this.element));var s=this.enableTapHold&&X.isDevice&&X.isTouch?this.mobileInitialize:this.initialize;i?E.remove(r||this.element,X.isSafari()?"touchstart":X.touchStartEvent,s):E.add(r||this.element,X.isSafari()?"touchstart":X.touchStartEvent,s,this)},t.prototype.mobileInitialize=function(i){var r=this,s=i.currentTarget;this.tapHoldTimer=setTimeout(function(){r.externalInitialize=!0,r.removeTapholdTimer(),r.initialize(i,s)},this.tapHoldThreshold),E.add(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.removeTapholdTimer,this),E.add(document,X.isSafari()?"touchend":X.touchEndEvent,this.removeTapholdTimer,this)},t.prototype.removeTapholdTimer=function(){clearTimeout(this.tapHoldTimer),E.remove(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.removeTapholdTimer),E.remove(document,X.isSafari()?"touchend":X.touchEndEvent,this.removeTapholdTimer)},t.prototype.getScrollableParent=function(i,r){return m(i)?null:i[{vertical:"scrollHeight",horizontal:"scrollWidth"}[""+r]]>i[{vertical:"clientHeight",horizontal:"clientWidth"}[""+r]]&&("vertical"===r?i.scrollTop>0:i.scrollLeft>0)?("vertical"===r?(this.parentScrollY=this.parentScrollY+(0===this.parentScrollY?i.scrollTop:i.scrollTop-this.parentScrollY),this.tempScrollHeight=i.scrollHeight):(this.parentScrollX=this.parentScrollX+(0===this.parentScrollX?i.scrollLeft:i.scrollLeft-this.parentScrollX),this.tempScrollWidth=i.scrollWidth),m(i)?i:this.getScrollableParent(i.parentNode,r)):this.getScrollableParent(i.parentNode,r)},t.prototype.getScrollableValues=function(){this.parentScrollX=0,this.parentScrollY=0,this.element.classList.contains("e-dialog")&&this.element.classList.contains("e-dlg-modal"),this.getScrollableParent(this.element.parentNode,"vertical"),this.getScrollableParent(this.element.parentNode,"horizontal")},t.prototype.initialize=function(i,r){if(this.currentStateTarget=i.target,!this.isDragStarted()){if(this.isDragStarted(!0),this.externalInitialize=!1,this.target=i.currentTarget||r,this.dragProcessStarted=!1,this.abort){var s=this.abort;"string"==typeof s&&(s=[s]);for(var o=0;o=this.distance||this.externalInitialize){var f=this.getHelperElement(i);if(!f||m(f))return;r&&i.preventDefault();var p=this.helperElement=f;if(this.parentClientRect=this.calculateParentPosition(p.offsetParent),this.dragStart){var v={event:i,element:l,target:this.getProperTargetElement(i),bindEvents:ce()?this.bindDragEvents.bind(this):null,dragElement:p};this.trigger("dragStart",v)}this.dragArea?this.setDragArea():(this.dragLimit={left:0,right:0,bottom:0,top:0},this.borderWidth={top:0,left:0}),o={left:this.position.left-this.parentClientRect.left,top:this.position.top-this.parentClientRect.top},this.clone&&!this.enableTailMode&&(this.diffX=this.position.left-this.offset.left,this.diffY=this.position.top-this.offset.top),this.getScrollableValues();var y=getComputedStyle(l),S=parseFloat(y.marginTop);this.clone&&0!==S&&(o.top+=S),this.eleTop=isNaN(parseFloat(y.top))?0:parseFloat(y.top)-this.offset.top,this.enableScrollHandler&&!this.clone&&(o.top-=this.parentScrollY,o.left-=this.parentScrollX);var b=this.getProcessedPositionValue({top:o.top-this.diffY+"px",left:o.left-this.diffX+"px"});this.dragArea&&"string"!=typeof this.dragArea&&this.dragArea.classList.contains("e-kanban-content")&&"relative"===this.dragArea.style.position&&(o.top+=this.dragArea.scrollTop),this.dragElePosition={top:o.top,left:o.left},je(p,this.getDragPosition({position:"absolute",left:b.left,top:b.top})),E.remove(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.intDragStart),E.remove(document,X.isSafari()?"touchend":X.touchEndEvent,this.intDestroy),ce()||this.bindDragEvents(p)}}},t.prototype.bindDragEvents=function(i){Tr(i)?(E.add(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.intDrag,this),E.add(document,X.isSafari()?"touchend":X.touchEndEvent,this.intDragStop,this),this.setGlobalDroppables(!1,this.element,i)):(this.toggleEvents(),document.body.classList.remove("e-prevent-select"))},t.prototype.elementInViewport=function(i){for(this.top=i.offsetTop,this.left=i.offsetLeft,this.width=i.offsetWidth,this.height=i.offsetHeight;i.offsetParent;)this.top+=(i=i.offsetParent).offsetTop,this.left+=i.offsetLeft;return this.top>=window.pageYOffset&&this.left>=window.pageXOffset&&this.top+this.height<=window.pageYOffset+window.innerHeight&&this.left+this.width<=window.pageXOffset+window.innerWidth},t.prototype.getProcessedPositionValue=function(i){return this.queryPositionInfo?this.queryPositionInfo(i):i},t.prototype.calculateParentPosition=function(i){if(m(i))return{left:0,top:0};var r=i.getBoundingClientRect(),s=getComputedStyle(i);return{left:r.left+window.pageXOffset-parseInt(s.marginLeft,10),top:r.top+window.pageYOffset-parseInt(s.marginTop,10)}},t.prototype.intDrag=function(i){if(st(i.changedTouches)||1===i.changedTouches.length){var r,s;this.clone&&i.changedTouches&&X.isDevice&&X.isTouch&&i.preventDefault(),this.position=this.getMousePosition(i,this.isDragScroll);var o=this.getDocumentWidthHeight("Height");oy&&y>0?this.dragLimit.left:this.dragLimit.right+window.pageXOffset0?y-(y-this.dragLimit.right)+window.pageXOffset-M:y<0?this.dragLimit.left:y}if(this.pageY!==v||this.skipDistanceCheck){var w=d.offsetHeight+(parseFloat(b.marginTop)+parseFloat(b.marginBottom));s=this.dragLimit.top>S&&S>0?this.dragLimit.top:this.dragLimit.bottom+window.pageYOffset0?S-(S-this.dragLimit.bottom)+window.pageYOffset-w:S<0?this.dragLimit.top:S}}else r=y,s=S;var A,x,C=f+this.borderWidth.top,D=u+this.borderWidth.left;if(this.dragProcessStarted&&(m(s)&&(s=this.prevTop),m(r)&&(r=this.prevLeft)),this.helperElement.classList.contains("e-treeview"))this.dragArea?(this.dragLimit.top=this.clone?this.dragLimit.top:0,A=s-C<0?this.dragLimit.top:s-this.borderWidth.top,x=r-D<0?this.dragLimit.left:r-this.borderWidth.left):(A=s-this.borderWidth.top,x=r-this.borderWidth.left);else if(this.dragArea){var P=this.helperElement.classList.contains("e-dialog");this.dragLimit.top=this.clone?this.dragLimit.top:0,A=s-C<0?this.dragLimit.top:s-C,x=r-D<0?P?r-(D-this.borderWidth.left):this.dragElePosition.left:r-D}else A=s-C,x=r-D;var L=parseFloat(getComputedStyle(this.element).marginTop);if(L>0&&(this.clone&&(A+=L,S<0&&(L+S>=0?A=L+S:A-=L),this.dragArea&&(A=this.dragLimit.bottom=0){var O=this.dragLimit.top+S-C;O+L+C<0?A-=L+C:A=O}else A-=L+C;this.dragArea&&this.helperElement.classList.contains("e-treeview")&&(A=A+(w=d.offsetHeight+(parseFloat(b.marginTop)+parseFloat(b.marginBottom)))>this.dragLimit.bottom?this.dragLimit.bottom-w:A),this.enableScrollHandler&&!this.clone&&(A-=this.parentScrollY,x-=this.parentScrollX),this.dragArea&&"string"!=typeof this.dragArea&&this.dragArea.classList.contains("e-kanban-content")&&"relative"===this.dragArea.style.position&&(A+=this.dragArea.scrollTop);var N=this.getProcessedPositionValue({top:A+"px",left:x+"px"});this.isPreventScroll&&(N=this.getProcessedPositionValue({top:this.position.top-this.parentClientRect.top-2+"px",left:this.position.left-this.parentClientRect.left-2+"px"})),je(d,this.getDragPosition(N)),!this.elementInViewport(d)&&this.enableAutoScroll&&!this.helperElement.classList.contains("e-treeview")&&this.helperElement.scrollIntoView();var T=document.querySelectorAll(":hover");if(this.enableAutoScroll&&this.helperElement.classList.contains("e-treeview")){0===T.length&&(T=this.getPathElements(i));var z=this.getScrollParent(T,!1);this.elementInViewport(this.helperElement)?this.getScrollPosition(z,A):this.elementInViewport(this.helperElement)||(0===(T=[].slice.call(document.querySelectorAll(":hover"))).length&&(T=this.getPathElements(i)),z=this.getScrollParent(T,!0),this.getScrollPosition(z,A))}this.dragProcessStarted=!0,this.prevLeft=r,this.prevTop=s,this.position.left=r,this.position.top=s,this.pageX=g,this.pageY=v}},t.prototype.getScrollParent=function(i,r){for(var o,s=r?i.reverse():i,a=s.length-1;a>=0;a--)if(("auto"===(o=window.getComputedStyle(s[parseInt(a.toString(),10)])["overflow-y"])||"scroll"===o)&&s[parseInt(a.toString(),10)].scrollHeight>s[parseInt(a.toString(),10)].clientHeight)return s[parseInt(a.toString(),10)];if("visible"===(o=window.getComputedStyle(document.scrollingElement)["overflow-y"]))return document.scrollingElement.style.overflow="auto",document.scrollingElement},t.prototype.getScrollPosition=function(i,r){if(i&&i===document.scrollingElement)i.clientHeight+document.scrollingElement.scrollTop-this.helperElement.clientHeightr?i.scrollTop+=this.helperElement.clientHeight:i.scrollTop>r-this.helperElement.clientHeight&&(i.scrollTop-=this.helperElement.clientHeight);else if(i&&i!==document.scrollingElement){var s=document.scrollingElement.scrollTop,o=this.helperElement.clientHeight;i.clientHeight+i.getBoundingClientRect().top-o+sr-o-s&&(i.scrollTop-=this.helperElement.clientHeight)}},t.prototype.getPathElements=function(i){return document.elementsFromPoint(i.clientX>0?i.clientX:0,i.clientY>0?i.clientY:0)},t.prototype.triggerOutFunction=function(i,r){this.hoverObject.instance.intOut(i,r.target),this.hoverObject.instance.dragData[this.scope]=null,this.hoverObject=null},t.prototype.getDragPosition=function(i){var r=ze({},i);return this.axis&&("x"===this.axis?delete r.top:"y"===this.axis&&delete r.left),r},t.prototype.getDocumentWidthHeight=function(i){var r=document.body,s=document.documentElement;return Math.max(r["scroll"+i],s["scroll"+i],r["offset"+i],s["offset"+i],s["client"+i])},t.prototype.intDragStop=function(i){if(this.dragProcessStarted=!1,st(i.changedTouches)||1===i.changedTouches.length){if(-1!==["touchend","pointerup","mouseup"].indexOf(i.type)){if(this.dragStop){var s=this.getProperTargetElement(i);this.trigger("dragStop",{event:i,element:this.element,target:s,helper:this.helperElement})}this.intDestroy(i)}else this.element.setAttribute("aria-grabbed","false");var o=this.checkTargetElement(i);o.target&&o.instance&&(o.instance.dragStopCalled=!0,o.instance.dragData[this.scope]=this.droppables[this.scope],o.instance.intDrop(i,o.target)),this.setGlobalDroppables(!0),document.body.classList.remove("e-prevent-select")}},t.prototype.intDestroy=function(i){this.dragProcessStarted=!1,this.toggleEvents(),document.body.classList.remove("e-prevent-select"),this.element.setAttribute("aria-grabbed","false"),E.remove(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.intDragStart),E.remove(document,X.isSafari()?"touchend":X.touchEndEvent,this.intDragStop),E.remove(document,X.isSafari()?"touchend":X.touchEndEvent,this.intDestroy),E.remove(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.intDrag),this.isDragStarted()&&this.isDragStarted(!0)},t.prototype.onPropertyChanged=function(i,r){},t.prototype.getModuleName=function(){return"draggable"},t.prototype.isDragStarted=function(i){return i&&(wC.isDragged=!wC.isDragged),wC.isDragged},t.prototype.setDragArea=function(){var i,r,a,s=0,o=0;if(a="string"==typeof this.dragArea?_(this.dragArea):this.dragArea){var h=a.getBoundingClientRect();i=a.scrollWidth?a.scrollWidth:h.right-h.left,r=a.scrollHeight?this.dragArea&&!m(this.helperElement)&&this.helperElement.classList.contains("e-treeview")?a.clientHeight:a.scrollHeight:h.bottom-h.top;for(var c=["Top","Left","Bottom","Right"],d=getComputedStyle(a),u=0;u12;return E0(i.target,this.helperElement)||-1!==i.type.indexOf("touch")||a?(this.helperElement.style.pointerEvents="none",s=document.elementFromPoint(r.clientX,r.clientY),this.helperElement.style.pointerEvents=o):s=i.target,s},t.prototype.currentStateCheck=function(i,r){return m(this.currentStateTarget)||this.currentStateTarget===i?m(r)?i:r:this.currentStateTarget},t.prototype.getMousePosition=function(i,r){var a,l,s=void 0!==i.srcElement?i.srcElement:i.target,o=this.getCoordinates(i),h=m(s.offsetParent);if(r?(a=this.clone?o.pageX:o.pageX+(h?0:s.offsetParent.scrollLeft)-this.relativeXPosition,l=this.clone?o.pageY:o.pageY+(h?0:s.offsetParent.scrollTop)-this.relativeYPosition):(a=this.clone?o.pageX:o.pageX+window.pageXOffset-this.relativeXPosition,l=this.clone?o.pageY:o.pageY+window.pageYOffset-this.relativeYPosition),document.scrollingElement&&!r&&!this.clone){var c=document.scrollingElement;a=c.scrollWidth>0&&c.scrollWidth>c.clientWidth&&c.scrollLeft>0?a-c.scrollLeft:a,l=c.scrollHeight>0&&c.scrollHeight>c.clientHeight&&c.scrollTop>0?l-c.scrollTop:l}return{left:a-(this.margin.left+this.cursorAt.left),top:l-(this.margin.top+this.cursorAt.top)}},t.prototype.getCoordinates=function(i){return i.type.indexOf("touch")>-1?i.changedTouches[0]:i},t.prototype.getHelperElement=function(i){var r;return this.clone?this.helper?r=this.helper({sender:i,element:this.target}):(r=Si("div",{className:"e-drag-helper e-block-touch",innerHTML:"Draggable"}),document.body.appendChild(r)):r=this.element,r},t.prototype.setGlobalDroppables=function(i,r,s){this.droppables[this.scope]=i?null:{draggable:r,helper:s,draggedElement:this.element}},t.prototype.checkTargetElement=function(i){var r=this.getProperTargetElement(i),s=this.getDropInstance(r);if(!s&&r&&!m(r.parentNode)){var o=J(r.parentNode,".e-droppable")||r.parentElement;o&&(s=this.getDropInstance(o))}return{target:r,instance:s}},t.prototype.getDropInstance=function(i){var s,o=i&&i.ej2_instances;if(o)for(var a=0,l=o;a=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},lR=function(n){function t(e,i){var r=n.call(this,i,e)||this;return r.mouseOver=!1,r.dragData={},r.dragStopCalled=!1,r.bind(),r}return sZ(t,n),t.prototype.bind=function(){this.wireEvents()},t.prototype.wireEvents=function(){E.add(this.element,X.isSafari()?"touchend":X.touchEndEvent,this.intDrop,this)},t.prototype.onPropertyChanged=function(e,i){},t.prototype.getModuleName=function(){return"droppable"},t.prototype.intOver=function(e,i){this.mouseOver||(this.trigger("over",{event:e,target:i,dragData:this.dragData[this.scope]}),this.mouseOver=!0)},t.prototype.intOut=function(e,i){this.mouseOver&&(this.trigger("out",{evt:e,target:i}),this.mouseOver=!1)},t.prototype.intDrop=function(e,i){if(this.dragStopCalled){this.dragStopCalled=!1;var a,r=!0,s=this.dragData[this.scope],o=!!s&&s.helper&&Tr(s.helper);o&&(a=this.isDropArea(e,s.helper,i),this.accept&&(r=yC(s.helper,this.accept))),o&&this.drop&&a.canDrop&&r&&this.trigger("drop",{event:e,target:a.target,droppedElement:s.helper,dragData:s}),this.mouseOver=!1}},t.prototype.isDropArea=function(e,i,r){var s={canDrop:!0,target:r||e.target},o="touchend"===e.type;if(o||s.target===i){i.style.display="none";var a=o?e.changedTouches[0]:e,l=document.elementFromPoint(a.clientX,a.clientY);s.canDrop=!1,s.canDrop=E0(l,this.element),s.canDrop&&(s.target=l),i.style.display=""}return s},t.prototype.destroy=function(){E.remove(this.element,X.isSafari()?"touchend":X.touchEndEvent,this.intDrop),n.prototype.destroy.call(this)},hf([I()],t.prototype,"accept",void 0),hf([I("default")],t.prototype,"scope",void 0),hf([H()],t.prototype,"drop",void 0),hf([H()],t.prototype,"over",void 0),hf([H()],t.prototype,"out",void 0),hf([Ft],t)}(dh),uo=function(){function n(t,e,i){this.controlName=t,this.localeStrings=e,this.setLocale(i||"en-US")}return n.prototype.setLocale=function(t){var e=this.intGetControlConstant(n.locale,t);this.currentLocale=e||this.localeStrings},n.load=function(t){this.locale=ze(this.locale,t,{},!0)},n.prototype.getConstant=function(t){return m(this.currentLocale[""+t])?this.localeStrings[""+t]||"":this.currentLocale[""+t]},n.prototype.intGetControlConstant=function(t,e){return t[""+e]?t[""+e][this.controlName]:null},n.locale={},n}(),hR=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),fh=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},lZ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return hR(t,n),fh([I(50)],t.prototype,"swipeThresholdDistance",void 0),t}(Ee),hZ=/(Up|Down)/,Fs=function(n){function t(e,i){var r=n.call(this,i,e)||this;return r.touchAction=!0,r.tapCount=0,r.startEvent=function(s){if(!0===r.touchAction){var o=r.updateChangeTouches(s);void 0!==s.changedTouches&&(r.touchAction=!1),r.isTouchMoved=!1,r.movedDirection="",r.startPoint=r.lastMovedPoint={clientX:o.clientX,clientY:o.clientY},r.startEventData=o,r.hScrollLocked=r.vScrollLocked=!1,r.tStampStart=Date.now(),r.timeOutTapHold=setTimeout(function(){r.tapHoldEvent(s)},r.tapHoldThreshold),E.add(r.element,X.touchMoveEvent,r.moveEvent,r),E.add(r.element,X.touchEndEvent,r.endEvent,r),E.add(r.element,X.touchCancelEvent,r.cancelEvent,r)}},r.moveEvent=function(s){var o=r.updateChangeTouches(s);r.movedPoint=o,r.isTouchMoved=!(o.clientX===r.startPoint.clientX&&o.clientY===r.startPoint.clientY);var a={};r.isTouchMoved&&(clearTimeout(r.timeOutTapHold),r.calcScrollPoints(s),a=ze(a,{},{startEvents:r.startEventData,originalEvent:s,startX:r.startPoint.clientX,startY:r.startPoint.clientY,distanceX:r.distanceX,distanceY:r.distanceY,scrollDirection:r.scrollDirection,velocity:r.getVelocity(o)}),r.trigger("scroll",a),r.lastMovedPoint={clientX:o.clientX,clientY:o.clientY})},r.cancelEvent=function(s){clearTimeout(r.timeOutTapHold),clearTimeout(r.timeOutTap),r.tapCount=0,r.swipeFn(s),E.remove(r.element,X.touchCancelEvent,r.cancelEvent)},r.endEvent=function(s){r.swipeFn(s),r.isTouchMoved||"function"==typeof r.tap&&(r.trigger("tap",{originalEvent:s,tapCount:++r.tapCount}),r.timeOutTap=setTimeout(function(){r.tapCount=0},r.tapThreshold)),r.modeclear()},r.swipeFn=function(s){clearTimeout(r.timeOutTapHold),clearTimeout(r.timeOutTap);var o=r.updateChangeTouches(s),a=o.clientX-r.startPoint.clientX,l=o.clientY-r.startPoint.clientY;a=Math.floor(a<0?-1*a:a),l=Math.floor(l<0?-1*l:a),r.isTouchMoved=a>1||l>1,/Firefox/.test(X.userAgent)&&0===o.clientX&&0===o.clientY&&"mouseup"===s.type&&(r.isTouchMoved=!1),r.endPoint=o,r.calcPoints(s);var c={originalEvent:s,startEvents:r.startEventData,startX:r.startPoint.clientX,startY:r.startPoint.clientY,distanceX:r.distanceX,distanceY:r.distanceY,swipeDirection:r.movedDirection,velocity:r.getVelocity(o)};if(r.isTouchMoved){var d=r.swipeSettings.swipeThresholdDistance,u=ze(void 0,r.defaultArgs,c),f=!1,p=r.element,g=r.isScrollable(p),v=hZ.test(r.movedDirection);(dthis.distanceY?i.clientX>this.startPoint.clientX?"Right":"Left":i.clientYthis.distanceY||!0===this.hScrollLocked)&&!1===this.vScrollLocked?(this.scrollDirection=i.clientX>this.lastMovedPoint.clientX?"Right":"Left",this.hScrollLocked=!0):(this.scrollDirection=i.clientY=e[r[0]+s[0]]},t.prototype.updateChangeTouches=function(e){return e.changedTouches&&0!==e.changedTouches.length?e.changedTouches[0]:e},fh([H()],t.prototype,"tap",void 0),fh([H()],t.prototype,"tapHold",void 0),fh([H()],t.prototype,"swipe",void 0),fh([H()],t.prototype,"scroll",void 0),fh([I(350)],t.prototype,"tapThreshold",void 0),fh([I(750)],t.prototype,"tapHoldThreshold",void 0),fh([re({},lZ)],t.prototype,"swipeSettings",void 0),fh([Ft],t)}(dh),cZ=new RegExp("\\n|\\r|\\s\\s+","g"),dZ=new RegExp(/'|"/g),uZ=new RegExp("if ?\\("),fZ=new RegExp("else if ?\\("),cR=new RegExp("else"),pZ=new RegExp("for ?\\("),dR=new RegExp("(/if|/for)"),gZ=new RegExp("\\((.*)\\)",""),CC=new RegExp("^[0-9]+$","g"),vZ=new RegExp("[\\w\"'.\\s+]+","g"),mZ=new RegExp('"(.*?)"',"g"),yZ=new RegExp("[\\w\"'@#$.\\s-+]+","g"),uR=new RegExp("\\${([^}]*)}","g"),SZ=/^\..*/gm,EC=/\\/gi,IZ=/\\\\/gi,bZ=new RegExp("[\\w\"'@#$.\\s+]+","g"),MZ=/\window\./gm;function cf(n,t,e,i,r){return!t||CC.test(n)||-1!==i.indexOf(n.split(".")[0])||r||"true"===n||"false"===n?n:e+"."+n}function DC(n,t,e,i){return t&&!CC.test(n)&&-1===i.indexOf(n.split(".")[0])?e+'["'+n:n}function fR(n){return n.match(IZ)?n:n.replace(EC,"\\\\")}function pR(n,t,e,i){if(n=n.trim(),/\window\./gm.test(n))return n;var s=/'|"/gm;return/@|\$|#/gm.test(n)&&(n=DC(n,-1===e.indexOf(n),t,e)+'"]'),SZ.test(n)?function EZ(n,t,e,i){return!t||CC.test(n)||-1!==i.indexOf(n.split(".")[0])||/^\..*/gm.test(n)?n:e+"."+n}(n,!s.test(n)&&-1===e.indexOf(n),t,e):cf(n,!s.test(n)&&-1===e.indexOf(n),t,e,i)}var DZ=/^[\n\r.]+0&&t.forEach(function(e){he(e)})},n.removeJsEvents=function(){var t=this.wrapElement.querySelectorAll("["+vR.join("],[")+"]");t.length>0&&t.forEach(function(e){vR.forEach(function(i){e.hasAttribute(i)&&e.removeAttribute(i)})})},n.removeXssAttrs=function(){var t=this;this.removeAttrs.forEach(function(e,i){var r=t.wrapElement.querySelectorAll(e.selector);r.length>0&&r.forEach("a[href]"===e.selector?function(s){-1!==s.getAttribute(e.attribute).replace(/\t|\s|&/,"").indexOf("javascript:alert")&&s.removeAttribute(e.attribute)}:function(s){s.removeAttribute(e.attribute)})})},n}();function kZ(n){for(var t,e=n.childNodes,i=0;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Jo_RTL=(new Tg,"e-rtl"),ys=function(n){function t(e,i){return n.call(this,e,i)||this}return RZ(t,n),t.prototype.preRender=function(){},t.prototype.render=function(){this.initialize(),this.removeRippleEffect=function ms(n,t,e){var i=function q$(n){return{selector:n&&n.selector?n.selector:null,ignore:n&&n.ignore?n.ignore:null,rippleFlag:n&&n.rippleFlag,isCenterRipple:n&&n.isCenterRipple,duration:n&&n.duration?n.duration:350}}(t);return!1===i.rippleFlag||void 0===i.rippleFlag&&!Zo?function(){}:(n.setAttribute("data-ripple","true"),E.add(n,"mousedown",Zz,{parent:n,rippleOptions:i}),E.add(n,"mouseup",Jz,{parent:n,rippleOptions:i,done:e}),E.add(n,"mouseleave",af,{parent:n,rippleOptions:i}),X.isPointer&&E.add(n,"transitionend",af,{parent:n,rippleOptions:i}),function(){n.removeAttribute("data-ripple"),E.remove(n,"mousedown",Zz),E.remove(n,"mouseup",Jz),E.remove(n,"mouseleave",af),E.remove(n,"transitionend",af)})}(this.element,{selector:".e-btn"}),this.renderComplete()},t.prototype.initialize=function(){if(this.cssClass&&V([this.element],this.cssClass.replace(/\s+/g," ").trim().split(" ")),this.isPrimary&&this.element.classList.add("e-primary"),!ce()||ce()&&"progress-btn"!==this.getModuleName()){if(this.content){var e=this.enableHtmlSanitizer?Ai.sanitize(this.content):this.content;this.element.innerHTML=e}this.setIconCss()}this.enableRtl&&this.element.classList.add(Jo_RTL),this.disabled?this.controlStatus(this.disabled):this.wireEvents()},t.prototype.controlStatus=function(e){this.element.disabled=e},t.prototype.setIconCss=function(){if(this.iconCss){var e=this.createElement("span",{className:"e-btn-icon "+this.iconCss});this.element.textContent.trim()?(e.classList.add("e-icon-"+this.iconPosition.toLowerCase()),("Top"===this.iconPosition||"Bottom"===this.iconPosition)&&this.element.classList.add("e-"+this.iconPosition.toLowerCase()+"-icon-btn")):this.element.classList.add("e-icon-btn");var i=this.element.childNodes[0];!i||"Left"!==this.iconPosition&&"Top"!==this.iconPosition?this.element.appendChild(e):this.element.insertBefore(e,i)}},t.prototype.wireEvents=function(){this.isToggle&&E.add(this.element,"click",this.btnClickHandler,this)},t.prototype.unWireEvents=function(){this.isToggle&&E.remove(this.element,"click",this.btnClickHandler)},t.prototype.btnClickHandler=function(){this.element.classList.contains("e-active")?this.element.classList.remove("e-active"):this.element.classList.add("e-active")},t.prototype.destroy=function(){var e=["e-primary",Jo_RTL,"e-icon-btn","e-success","e-info","e-danger","e-warning","e-flat","e-outline","e-small","e-bigger","e-active","e-round","e-top-icon-btn","e-bottom-icon-btn"];this.cssClass&&(e=e.concat(this.cssClass.split(" "))),n.prototype.destroy.call(this),K([this.element],e),this.element.getAttribute("class")||this.element.removeAttribute("class"),this.disabled&&this.element.removeAttribute("disabled"),this.content&&(this.element.innerHTML=this.element.innerHTML.replace(this.content,""));var i=this.element.querySelector("span.e-btn-icon");i&&he(i),this.unWireEvents(),Zo&&this.removeRippleEffect()},t.prototype.getModuleName=function(){return"btn"},t.prototype.getPersistData=function(){return this.addOnPersist([])},t.Inject=function(){},t.prototype.onPropertyChanged=function(e,i){for(var r=this.element.querySelector("span.e-btn-icon"),s=0,o=Object.keys(e);s=hd.width?hd.width:0;return yl.right+QR()-n}function dE(){return _0()+yl.width/2}function uE(n,t,e,i){if(void 0===t&&(t=null),void 0===e&&(e={X:!1,Y:!1}),!e.Y&&!e.X)return{left:0,top:0};var r=n.getBoundingClientRect();if(po=t,oc=n.ownerDocument,i||(i=ns(n,"left","top")),e.X){var s=po?ZR():i4(),o=mE(),a=yE(),l=o-i.left,h=i.left+r.width-a;r.width>s?i.left=l>0&&h<=0?a-r.width:h>0&&l<=0?o:l>h?a-r.width:o:l>0?i.left+=l:h>0&&(i.left-=h)}if(e.Y){var c=po?JR():t4(),d=vE(),u=SE(),f=d-i.top,p=i.top+r.height-u;r.height>c?i.top=f>0&&p<=0?u-r.height:p>0&&f<=0?d:f>p?u-r.height:d:f>0?i.top+=f:p>0&&(i.top-=p)}return i}function ac(n,t,e,i){void 0===t&&(t=null);var r=ns(n,"left","top");e&&(r.left=e),i&&(r.top=i);var s=[];po=t,oc=n.ownerDocument;var o=n.getBoundingClientRect(),l=r.left,h=r.left+o.width,d=gE(r.top,r.top+o.height),u=XR(l,h);return d.topSide&&s.push("top"),u.rightSide&&s.push("right"),u.leftSide&&s.push("left"),d.bottomSide&&s.push("bottom"),s}function uJ(n,t,e,i,r,s,o,a,l){if(void 0===o&&(o=null),void 0===a&&(a={X:!0,Y:!0}),t&&n&&r&&s&&(a.X||a.Y)){var d,h={TL:null,TR:null,BL:null,BR:null},c={TL:null,TR:null,BL:null,BR:null};if("none"===window.getComputedStyle(n).display){var u=n.style.visibility;n.style.visibility="hidden",n.style.display="block",d=n.getBoundingClientRect(),n.style.removeProperty("display"),n.style.visibility=u}else d=n.getBoundingClientRect();var f={posX:r,posY:s,offsetX:e,offsetY:i,position:{left:0,top:0}};po=o,oc=t.ownerDocument,function pJ(n,t,e,i,r){e.position=ns(n,e.posX,e.posY,i,r),t.TL=ns(n,"left","top",i,r),t.TR=ns(n,"right","top",i,r),t.BR=ns(n,"left","bottom",i,r),t.BL=ns(n,"right","bottom",i,r)}(t,h,f,l,d),pE(c,f,d),a.X&&qR(t,c,h,f,d,!0),a.Y&&h.TL.top>-1&&$R(t,c,h,f,d,!0),function fJ(n,t,e){var i=0,r=0;if(null!=n.offsetParent&&("absolute"===getComputedStyle(n.offsetParent).position||"relative"===getComputedStyle(n.offsetParent).position)){var s=ns(n.offsetParent,"left","top",!1,e);i=s.left,r=s.top}var o=1,a=1,l=GR(n);if(l){var h=getComputedStyle(l).transform;if("none"!==h){var c=new DOMMatrix(h);o=c.a,a=c.d}if("none"!==getComputedStyle(l).zoom){var u=fE(document.body);o*=u,a*=u}}n.style.top=t.position.top/a+t.offsetY-r/a+"px",n.style.left=t.position.left/o+t.offsetX-i/o+"px"}(n,f,d)}}function fE(n){var t=getComputedStyle(n).zoom;return parseFloat(t)||1}function GR(n){for(;n;){var t=window.getComputedStyle(n).transform,e=fE(document.body);if(t&&"none"!==t||e&&1!==e)return n;if(n===document.body)return null;n=n.offsetParent||n.parentElement}return null}function pE(n,t,e){n.TL={top:t.position.top+t.offsetY,left:t.position.left+t.offsetX},n.TR={top:n.TL.top,left:n.TL.left+e.width},n.BL={top:n.TL.top+e.height,left:n.TL.left},n.BR={top:n.TL.top+e.height,left:n.TL.left+e.width}}function XR(n,t){var e=!1,i=!1;return n-j0()yE()&&(i=!0),{leftSide:e,rightSide:i}}function qR(n,t,e,i,r,s){var o=XR(t.TL.left,t.TR.left),a=gE(t.TL.top,t.BL.top);e.TL.left-j0()<=mE()&&(o.leftSide=!1),e.TR.left>yE()&&(o.rightSide=!1),(o.leftSide&&!o.rightSide||!o.leftSide&&o.rightSide)&&(i.posX="right"===i.posX?"left":"right",i.offsetX=i.offsetX+r.width,i.offsetX=-1*i.offsetX,i.position=ns(n,i.posX,i.posY,!1),pE(t,i,r),s&&qR(n,t,e,i,r,!1),!o.leftSide&&o.rightSide&&a.bottomSide&&(i.offsetX=0))}function $R(n,t,e,i,r,s){var o=gE(t.TL.top,t.BL.top);e.TL.top-U0()<=vE()&&(o.topSide=!1),e.BL.top>=SE()&&n.getBoundingClientRect().bottomSE()&&(i=!0),{topSide:e,bottomSide:i}}function ZR(){return po.getBoundingClientRect().width}function JR(){return po.getBoundingClientRect().height}function KR(){return po.getBoundingClientRect().left}function e4(){return po.getBoundingClientRect().top}function vE(){return po?e4():0}function mE(){return po?KR():0}function yE(){return po?j0()+KR()+ZR():j0()+i4()}function SE(){return po?U0()+e4()+JR():U0()+t4()}function U0(){return oc.documentElement.scrollTop||oc.body.scrollTop}function j0(){return oc.documentElement.scrollLeft||oc.body.scrollLeft}function t4(){return window.innerHeight}function i4(){var n=window.innerWidth,t=document.documentElement.getBoundingClientRect();return n-(n-(m(document.documentElement)?0:t.width))}function r4(){po=null,oc=null}var n4=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),bn=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},s4=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return n4(t,n),bn([I("left")],t.prototype,"X",void 0),bn([I("top")],t.prototype,"Y",void 0),t}(Ee),qn_OPEN="e-popup-open",qn_CLOSE="e-popup-close",lc=function(n){function t(e,i){return n.call(this,i,e)||this}return n4(t,n),t.prototype.onPropertyChanged=function(e,i){for(var r=0,s=Object.keys(e);r0&&c.left>0&&c.right>0&&c.bottom>0}var s=i.getBoundingClientRect();return!(r.bottoms.bottom||r.right>s.right||r.leftr.top?this.element.style.top="0px":s.bottomr.left&&(this.element.style.left=parseInt(this.element.style.left,10)+(s.left-r.left)+"px"))}},t.prototype.checkCollision=function(){var e=this.collision.X,i=this.collision.Y;"none"===e&&"none"===i||("flip"===e&&"flip"===i?this.callFlip({X:!0,Y:!0}):"fit"===e&&"fit"===i?this.callFit({X:!0,Y:!0}):("flip"===e?this.callFlip({X:!0,Y:!1}):"flip"===i&&this.callFlip({Y:!0,X:!1}),"fit"===e?this.callFit({X:!0,Y:!1}):"fit"===i&&this.callFit({X:!1,Y:!0})))},t.prototype.show=function(e,i){var r=this;if(this.getRelateToElement().classList.contains("e-filemanager")&&(this.fmDialogContainer=this.element.getElementsByClassName("e-file-select-wrap")[0]),this.wireEvents(),!m(this.fmDialogContainer)&&X.isIos&&(this.fmDialogContainer.style.display="block"),1e3===this.zIndex||!m(i)){var o=m(i)?this.element:i;this.zIndex=hc(o),je(this.element,{zIndex:this.zIndex})}e=m(e)||"object"!=typeof e?this.showAnimation:e,("none"!==this.collision.X||"none"!==this.collision.Y)&&(K([this.element],qn_CLOSE),V([this.element],qn_OPEN),this.checkCollision(),K([this.element],qn_OPEN),V([this.element],qn_CLOSE)),m(e)?(K([this.element],qn_CLOSE),V([this.element],qn_OPEN),this.trigger("open")):(e.begin=function(){r.isDestroyed||(K([r.element],qn_CLOSE),V([r.element],qn_OPEN))},e.end=function(){r.isDestroyed||r.trigger("open")},new Hs(e).animate(this.element))},t.prototype.hide=function(e){var i=this;e=m(e)||"object"!=typeof e?this.hideAnimation:e,m(e)?(K([this.element],qn_OPEN),V([this.element],qn_CLOSE),this.trigger("close")):(e.end=function(){i.isDestroyed||(K([i.element],qn_OPEN),V([i.element],qn_CLOSE),i.trigger("close"))},new Hs(e).animate(this.element)),this.unwireEvents()},t.prototype.getScrollableParent=function(e){return this.checkFixedParent(e),function IE(n,t){for(var e=getComputedStyle(n),i=[],r=/(auto|scroll)/,s=n.parentElement;s&&"HTML"!==s.tagName;){var o=getComputedStyle(s);!("absolute"===e.position&&"static"===o.position)&&r.test(o.overflow+o.overflowY+o.overflowX)&&i.push(s),s=s.parentElement}return t||i.push(document),i}(e,this.fixedParent)},t.prototype.checkFixedParent=function(e){for(var i=e.parentElement;i&&"HTML"!==i.tagName;){var r=getComputedStyle(i);("fixed"===r.position||"sticky"===r.position)&&!m(this.element)&&this.element.offsetParent&&"BODY"===this.element.offsetParent.tagName&&"hidden"!==getComputedStyle(this.element.offsetParent).overflow&&(this.element.style.top=window.scrollY>parseInt(this.element.style.top,10)?Re(window.scrollY-parseInt(this.element.style.top,10)):Re(parseInt(this.element.style.top,10)-window.scrollY),this.element.style.position="fixed",this.fixedParent=!0),i=i.parentElement,!m(this.element)&&m(this.element.offsetParent)&&"fixed"===r.position&&"fixed"===this.element.style.position&&(this.fixedParent=!0)}},bn([I("auto")],t.prototype,"height",void 0),bn([I("auto")],t.prototype,"width",void 0),bn([I(null)],t.prototype,"content",void 0),bn([I("container")],t.prototype,"targetType",void 0),bn([I(null)],t.prototype,"viewPortElement",void 0),bn([I({X:"none",Y:"none"})],t.prototype,"collision",void 0),bn([I("")],t.prototype,"relateTo",void 0),bn([re({},s4)],t.prototype,"position",void 0),bn([I(0)],t.prototype,"offsetX",void 0),bn([I(0)],t.prototype,"offsetY",void 0),bn([I(1e3)],t.prototype,"zIndex",void 0),bn([I(!1)],t.prototype,"enableRtl",void 0),bn([I("reposition")],t.prototype,"actionOnScroll",void 0),bn([I(null)],t.prototype,"showAnimation",void 0),bn([I(null)],t.prototype,"hideAnimation",void 0),bn([H()],t.prototype,"open",void 0),bn([H()],t.prototype,"close",void 0),bn([H()],t.prototype,"targetExitViewport",void 0),bn([Ft],t)}(Ii);function hc(n){for(var t=n.parentElement,e=[];t&&"BODY"!==t.tagName;){var i=document.defaultView.getComputedStyle(t,null).getPropertyValue("z-index"),r=document.defaultView.getComputedStyle(t,null).getPropertyValue("position");"auto"!==i&&"static"!==r&&e.push(i),t=t.parentElement}for(var s=[],o=0;o2147483647?2147483647:c}var Ui,ka,df,yh,CE,Sh,Zt,Ih,bE=["north-west","north","north-east","west","east","south-west","south","south-east"],jg="e-resize-handle",cc="e-focused-handle",gJ="e-dlg-resizable",o4=["e-restrict-left"],a4="e-resize-viewport",vJ=["north","west","east","south"],ME=0,wE=0,l4=0,h4=0,Vg=0,Wg=0,Yg=null,EE=null,DE=null,V0=!0,c4=0,xE=!0;function yJ(n){TE();var t=Si("span",{attrs:{unselectable:"on",contenteditable:"false"}});t.setAttribute("class","e-dialog-border-resize e-"+n),"south"===n&&(t.style.height="2px",t.style.width="100%",t.style.bottom="0px",t.style.left="0px"),"north"===n&&(t.style.height="2px",t.style.width="100%",t.style.top="0px",t.style.left="0px"),"east"===n&&(t.style.height="100%",t.style.width="2px",t.style.right="0px",t.style.top="0px"),"west"===n&&(t.style.height="100%",t.style.width="2px",t.style.left="0px",t.style.top="0px"),Ui.appendChild(t)}function d4(n){var t;return m(n)||(t="string"==typeof n?document.querySelector(n):n),t}function u4(n){for(var t=n||this,e=Ui.querySelectorAll("."+jg),i=0;i-1?"mouse":"touch"}function p4(n){if(n.preventDefault(),Ui=n.target.parentElement,TE(),Vg=n.pageX,Wg=n.pageY,n.target.classList.add(cc),m(Yg)||!0!==Yg(n,this)){this.targetEle&&Ui&&Ui.querySelector("."+gJ)&&(Zt="body"===this.target?null:this.targetEle,Sh=this.targetEle.clientWidth,yh=this.targetEle.clientHeight);var e=m(Zt)?document:Zt;E.add(e,"mousemove",Qg,this),E.add(document,"mouseup",W0,this);for(var i=0;i=0||s.top<0)&&(e=!0):e=!0;var a=wE+(r-Wg);a=a>df?a:df;var l=0;m(Zt)||(l=o.top);var h=m(Zt)?0:Zt.offsetHeight-Zt.clientHeight,c=s.top-l-h/2;if(c=c<0?0:c,s.top>0&&c+a>yh){if(e=!1,Ui.classList.contains(a4))return;Ui.style.height=yh-parseInt(c.toString(),10)+"px"}else{var d=0;if(e){s.top<0&&t+(s.height+s.top)>0&&a+(d=s.top)<=30&&(a=s.height-(s.height+s.top)+30),a+s.top>=yh&&(Ui.style.height=s.height+(t-(s.height+s.top))+"px");var u=m(Zt)?d:c;a>=df&&a+u<=yh&&(Ui.style.height=a+"px")}}}function LE(n){var e,t=!1,i="mouse"===f4(n.type)?n.pageY:n.touches[0].pageY,r=dc(Ui),s=m(Zt)?0:Zt.offsetHeight-Zt.clientHeight;m(Zt)||(e=dc(Zt)),(!m(Zt)&&r.top-e.top>0||m(Zt)&&i>0||!m(Zt)&&Math.floor(r.top-e.top+r.height+(e.bottom-r.bottom))-s<=yh)&&(t=!0);var o=wE-(i-Wg);if(t&&o>=df&&o<=yh){var a=0;m(Zt)||(a=e.top);var l=h4-a+(i-Wg);l=l>0?l:1,Ui.style.height=o+"px",Ui.style.top=l+"px"}}function NE(n){var i,t=document.documentElement.clientWidth,e=!1;m(Zt)||(i=dc(Zt));var r="mouse"===f4(n.type)?n.pageX:n.touches[0].pageX,s=dc(Ui),o=m(Zt)?0:Zt.offsetWidth-Zt.clientWidth,a=m(Zt)?0:i.left,l=m(Zt)?0:i.width;m(Ih)&&(m(Zt)?Ih=t:(Ih=s.left-a-o/2+s.width,Ih+=l-o-Ih)),(!m(Zt)&&Math.floor(s.left-i.left+s.width+(i.right-s.right))-o<=Sh||m(Zt)&&r>=0)&&(e=!0);var h=ME-(r-Vg);if(V0&&(h=h>Ih?Ih:h),e&&h>=CE&&h<=Sh){var c=0;m(Zt)||(c=i.left);var d=l4-c+(r-Vg);d=d>0?d:1,h!==c4&&xE&&(Ui.style.width=h+"px"),V0&&(Ui.style.left=d+"px",xE=1!==d)}c4=h}function OE(n){var i,t=document.documentElement.clientWidth,e=!1;m(Zt)||(i=dc(Zt));var s=(n.touches?n.changedTouches[0]:n).pageX,o=dc(Ui);(!m(Zt)&&(o.left-i.left+o.width<=Sh||o.right-i.left>=o.width)||m(Zt)&&t-s>0)&&(e=!0);var a=ME+(s-Vg),l=0;if(m(Zt)||(l=i.left),o.left-l+a>Sh){if(e=!1,Ui.classList.contains(a4))return;Ui.style.width=Sh-(o.left-l)+"px"}e&&a>=CE&&a<=Sh&&(Ui.style.width=a+"px")}function v4(){for(var n=Ui.querySelectorAll("."+jg),t=0;t=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},wJ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return kE(t,n),Jt([I(!0)],t.prototype,"isFlat",void 0),Jt([I()],t.prototype,"buttonModel",void 0),Jt([I("Button")],t.prototype,"type",void 0),Jt([H()],t.prototype,"click",void 0),t}(Ee),CJ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return kE(t,n),Jt([I("Fade")],t.prototype,"effect",void 0),Jt([I(400)],t.prototype,"duration",void 0),Jt([I(0)],t.prototype,"delay",void 0),t}(Ee),Y0="e-dialog",PE="e-rtl",zE="e-dlg-header-content",m4="e-dlg-header",Q0="e-footer-content",G0="e-dlg-modal",y4="e-icon-dlg-close",Pa="e-dlg-target",ea="e-scroll-disabled",S4="e-device",X0="e-dlg-fullscreen",I4="e-dlg-closeicon-btn",b4="e-popup-open",M4="Information",w4="e-scroll-disabled",C4="e-alert-dialog",E4="e-confirm-dialog",RE="e-dlg-resizable",uf="e-restrict-left",D4="e-resize-viewport",HE="user action",HJ=function(n){function t(e,i){var r=n.call(this,e,i)||this;return r.needsID=!0,r}return kE(t,n),t.prototype.render=function(){this.initialize(),this.initRender(),this.wireEvents(),"100%"===this.width&&(this.element.style.width=""),""!==this.minHeight&&(this.element.style.minHeight=Re(this.minHeight)),this.enableResize&&(this.setResize(),this.isModal&&(this.isModelResize=!0),"None"===this.animationSettings.effect&&this.getMinHeight()),this.renderComplete()},t.prototype.initializeValue=function(){this.dlgClosedBy=HE},t.prototype.preRender=function(){var e=this;if(this.initializeValue(),this.headerContent=null,this.allowMaxHeight=!0,this.preventVisibility=!0,this.clonedEle=this.element.cloneNode(!0),this.closeIconClickEventHandler=function(s){e.dlgClosedBy="close icon",e.hide(s)},this.dlgOverlayClickEventHandler=function(s){e.dlgClosedBy="overlayClick",s.preventFocus=!1,e.trigger("overlayClick",s,function(o){o.preventFocus||e.focusContent(),e.dlgClosedBy=HE})},this.l10n=new uo("dialog",{close:"Close"},this.locale),this.checkPositionData(),m(this.target)){var r=this.isProtectedOnChange;this.isProtectedOnChange=!0,this.target=document.body,this.isProtectedOnChange=r}},t.prototype.updatePersistData=function(){this.enablePersistence&&this.setProperties({width:parseFloat(this.element.style.width),height:parseFloat(this.element.style.height),position:{X:parseFloat(this.dragObj.element.style.left),Y:parseFloat(this.dragObj.element.style.top)}},!0)},t.prototype.isNumberValue=function(e){return/^[-+]?\d*\.?\d+$/.test(e)},t.prototype.checkPositionData=function(){if(!m(this.position)){if(!m(this.position.X)&&"number"!=typeof this.position.X&&this.isNumberValue(this.position.X)){var i=this.isProtectedOnChange;this.isProtectedOnChange=!0,this.position.X=parseFloat(this.position.X),this.isProtectedOnChange=i}m(this.position.Y)||"number"==typeof this.position.Y||this.isNumberValue(this.position.Y)&&(i=this.isProtectedOnChange,this.isProtectedOnChange=!0,this.position.Y=parseFloat(this.position.Y),this.isProtectedOnChange=i)}},t.prototype.getEle=function(e,i){for(var r=void 0,s=0;s=0&&t[e])yJ(t[e]);else if(""!==t[e].trim()){var i=Si("div",{className:"e-icons "+jg+" e-"+t[e]});Ui.appendChild(i)}df=n.minHeight,CE=n.minWidth,Sh=n.maxWidth,yh=n.maxHeight,n.proxy&&n.proxy.element&&n.proxy.element.classList.contains("e-dialog")?u4(n.proxy):u4()}({element:this.element,direction:r,minHeight:parseInt(e.slice(0,i.indexOf("p")),10),maxHeight:this.targetEle.clientHeight,minWidth:parseInt(i.slice(0,i.indexOf("p")),10),maxWidth:this.targetEle.clientWidth,boundary:this.target===document.body?null:this.targetEle,resizeBegin:this.onResizeStart.bind(this),resizeComplete:this.onResizeComplete.bind(this),resizing:this.onResizing.bind(this),proxy:this}),this.wireWindowResizeEvent()}else v4(),this.unWireWindowResizeEvent(),this.element.classList.remove(this.isModal?uf:D4),this.element.classList.remove(RE)},t.prototype.getFocusElement=function(e){var r=e.querySelectorAll('input,select,textarea,button:enabled,a,[contenteditable="true"],[tabindex]');return{element:r[r.length-1]}},t.prototype.keyDown=function(e){var i=this;if(9===e.keyCode&&this.isModal){var r=void 0;m(this.btnObj)||(r=this.btnObj[this.btnObj.length-1]),m(this.btnObj)&&!m(this.ftrTemplateContent)&&(r=this.getFocusElement(this.ftrTemplateContent)),m(this.btnObj)&&m(this.ftrTemplateContent)&&!m(this.contentEle)&&(r=this.getFocusElement(this.contentEle)),!m(r)&&document.activeElement===r.element&&!e.shiftKey&&(e.preventDefault(),this.focusableElements(this.element).focus()),document.activeElement===this.focusableElements(this.element)&&e.shiftKey&&(e.preventDefault(),m(r)||r.element.focus())}var h,s=document.activeElement,o=["input","textarea"].indexOf(s.tagName.toLowerCase())>-1,a=!1;if(o||(a=s.hasAttribute("contenteditable")&&"true"===s.getAttribute("contenteditable")),27===e.keyCode&&this.closeOnEscape){this.dlgClosedBy="escape";var l=document.querySelector(".e-popup-open:not(.e-dialog)");!m(l)&&!l.classList.contains("e-toolbar-pop")&&!l.classList.contains("e-slider-tooltip")||this.hide(e)}(13===e.keyCode&&!e.ctrlKey&&"textarea"!==s.tagName.toLowerCase()&&o&&!m(this.primaryButtonEle)||13===e.keyCode&&e.ctrlKey&&("textarea"===s.tagName.toLowerCase()||a)&&!m(this.primaryButtonEle))&&this.buttons.some(function(d,u){h=u;var f=d.buttonModel;return!m(f)&&!0===f.isPrimary})&&"function"==typeof this.buttons[h].click&&setTimeout(function(){i.buttons[h].click.call(i,e)})},t.prototype.initialize=function(){m(this.target)||(this.targetEle="string"==typeof this.target?document.querySelector(this.target):this.target),this.isBlazorServerRender()||V([this.element],Y0),X.isDevice&&V([this.element],S4),this.isBlazorServerRender()||this.setCSSClass(),this.setMaxHeight()},t.prototype.initRender=function(){var e=this;if(this.initialRender=!0,this.isBlazorServerRender()||Fe(this.element,{role:"dialog"}),1e3===this.zIndex?(this.setzIndex(this.element,!1),this.calculatezIndex=!0):this.calculatezIndex=!1,this.setTargetContent(),""!==this.header&&!m(this.header)&&this.setHeader(),this.renderCloseIcon(),this.setContent(),""===this.footerTemplate||m(this.footerTemplate)?!m(this.buttons[0])&&!m(this.buttons[0].buttonModel)&&this.setButton():this.setFooterTemplate(),this.allowDragging&&!m(this.headerContent)&&this.setAllowDragging(),Fe(this.element,{"aria-modal":this.isModal?"true":"false"}),this.isModal&&this.setIsModal(),!0!==this.element.classList.contains(C4)&&!0!==this.element.classList.contains(E4)&&!m(this.element.parentElement)){var i=this.isModal?this.dlgContainer.parentElement:this.element.parentElement;this.refElement=this.createElement("div",{className:"e-dlg-ref-element"}),i.insertBefore(this.refElement,this.isModal?this.dlgContainer:this.element)}if(m(this.targetEle)||this.targetEle.appendChild(this.isModal?this.dlgContainer:this.element),this.popupObj=new lc(this.element,{height:this.height,width:this.width,zIndex:this.zIndex,relateTo:this.target,actionOnScroll:"none",enableRtl:this.enableRtl,open:function(o){var a={container:e.isModal?e.dlgContainer:e.element,element:e.element,target:e.target,preventFocus:!1};e.enableResize&&e.resetResizeIcon(),e.trigger("open",a,function(l){l.preventFocus||e.focusContent()})},close:function(o){e.isModal&&V([e.dlgOverlay],"e-fade"),e.unBindEvent(e.element),e.isModal&&(e.dlgContainer.style.display="none"),e.trigger("close",e.closeArgs);var a=document.activeElement;!m(a)&&!m(a.blur)&&a.blur(),!m(e.storeActiveElement)&&!m(e.storeActiveElement.focus)&&e.storeActiveElement.focus()}}),this.positionChange(),this.setEnableRTL(),this.isBlazorServerRender()||(V([this.element],"e-popup-close"),this.isModal&&this.setOverlayZindex()),this.visible){if(this.show(),this.isModal){var r=this.getTargetContainer(this.target);r instanceof Element&&"rtl"===window.getComputedStyle(r).getPropertyValue("direction")&&this.setPopupPosition()}}else this.isModal&&(this.dlgOverlay.style.display="none");this.initialRender=!1},t.prototype.getTargetContainer=function(e){var i=null;if("string"==typeof e)if(e.startsWith("#"))i=document.getElementById(e.substring(1));else if(e.startsWith(".")){var r=document.getElementsByClassName(e.substring(1));i=r.length>0?r[0]:null}else!(e instanceof HTMLElement)&&e!==document.body&&(i=document.querySelector(e));else e instanceof HTMLElement&&(i=e);return i},t.prototype.resetResizeIcon=function(){var e=this.getMinHeight();if(this.targetEle.offsetHeight0&&("function"==typeof this.buttons[e].click&&E.add(s[e],"click",this.buttons[e].click,this),"object"==typeof this.buttons[e].click&&E.add(s[e],"click",this.buttonClickHandler.bind(this,e),this)),!this.isBlazorServerRender()&&!m(this.ftrTemplateContent)&&(this.btnObj[e].appendTo(this.ftrTemplateContent.children[e]),this.buttons[e].isFlat&&this.btnObj[e].element.classList.add("e-flat"),this.primaryButtonEle=this.element.getElementsByClassName("e-primary")[0]))},t.prototype.buttonClickHandler=function(e){this.trigger("buttons["+e+"].click",{})},t.prototype.setContent=function(){this.contentEle=this.createElement("div",{className:"e-dlg-content",id:this.element.id+"_dialog-content"}),Fe(this.element,this.headerEle?{"aria-describedby":this.element.id+"_title "+this.element.id+"_dialog-content"}:{"aria-describedby":this.element.id+"_dialog-content"}),this.innerContentElement?this.contentEle.appendChild(this.innerContentElement):(!m(this.content)&&""!==this.content||!this.initialRender)&&(("string"!=typeof this.content||ce())&&this.content instanceof HTMLElement?this.contentEle.appendChild(this.content):this.setTemplate(this.content,this.contentEle,"content")),m(this.headerContent)?this.element.insertBefore(this.contentEle,this.element.children[0]):this.element.insertBefore(this.contentEle,this.element.children[1]),"auto"===this.height&&(!this.isBlazorServerRender()&&X.isIE&&""===this.element.style.width&&!m(this.width)&&(this.element.style.width=Re(this.width)),this.setMaxHeight())},t.prototype.setTemplate=function(e,i,r){var s,o,a;o=i.classList.contains(m4)?this.element.id+"header":i.classList.contains(Q0)?this.element.id+"footerTemplate":this.element.id+"content",m(e.outerHTML)?("string"==typeof e||"string"!=typeof e||ce()&&!this.isStringTemplate)&&("string"==typeof e&&(e=this.sanitizeHelper(e)),this.isVue||"string"!=typeof e?(s=oi(e),a=e):i.innerHTML=e):i.appendChild(e);var l=[];if(!m(s)){for(var c=0,d=s({},this,r,o,!(ce()&&!this.isStringTemplate&&0===a.indexOf("
Blazor"))||this.isStringTemplate);c/g,"");(this.element.children.length>0||i)&&(this.innerContentElement=document.createDocumentFragment(),[].slice.call(this.element.childNodes).forEach(function(r){8!==r.nodeType&&e.innerContentElement.appendChild(r)}))}},t.prototype.setHeader=function(){this.headerEle?this.headerEle.innerHTML="":this.headerEle=this.createElement("div",{id:this.element.id+"_title",className:m4}),this.createHeaderContent(),this.headerContent.appendChild(this.headerEle),this.setTemplate(this.header,this.headerEle,"header"),Fe(this.element,{"aria-describedby":this.element.id+"_title"}),Fe(this.element,{"aria-labelledby":this.element.id+"_dialog-header"}),this.element.insertBefore(this.headerContent,this.element.children[0]),this.allowDragging&&!m(this.headerContent)&&this.setAllowDragging()},t.prototype.setFooterTemplate=function(){this.ftrTemplateContent?this.ftrTemplateContent.innerHTML="":this.ftrTemplateContent=this.createElement("div",{className:Q0}),""===this.footerTemplate||m(this.footerTemplate)?this.ftrTemplateContent.innerHTML=this.buttonContent.join(""):this.setTemplate(this.footerTemplate,this.ftrTemplateContent,"footerTemplate"),this.element.appendChild(this.ftrTemplateContent)},t.prototype.createHeaderContent=function(){m(this.headerContent)&&(this.headerContent=this.createElement("div",{id:this.element.id+"_dialog-header",className:zE}))},t.prototype.renderCloseIcon=function(){this.showCloseIcon&&(this.closeIcon=this.createElement("button",{className:I4,attrs:{type:"button"}}),this.closeIconBtnObj=new ys({cssClass:"e-flat",iconCss:y4+" e-icons"}),this.closeIconTitle(),m(this.headerContent)?(this.createHeaderContent(),gl([this.closeIcon],this.headerContent),this.element.insertBefore(this.headerContent,this.element.children[0])):gl([this.closeIcon],this.headerContent),this.closeIconBtnObj.appendTo(this.closeIcon))},t.prototype.closeIconTitle=function(){this.l10n.setLocale(this.locale);var e=this.l10n.getConstant("close");this.closeIcon.setAttribute("title",e),this.closeIcon.setAttribute("aria-label",e)},t.prototype.setCSSClass=function(e){e&&(K([this.element],e.split(" ")),this.isModal&&!m(this.dlgContainer)&&K([this.dlgContainer],e.split(" "))),this.cssClass&&(V([this.element],this.cssClass.split(" ")),this.isModal&&!m(this.dlgContainer)&&V([this.dlgContainer],this.cssClass.split(" ")))},t.prototype.setIsModal=function(){this.dlgContainer=this.createElement("div",{className:"e-dlg-container"}),this.setCSSClass(),this.element.classList.remove(b4),this.element.parentNode.insertBefore(this.dlgContainer,this.element),this.dlgContainer.appendChild(this.element),V([this.element],G0),this.dlgOverlay=this.createElement("div",{className:"e-dlg-overlay"}),this.dlgOverlay.style.zIndex=(this.zIndex-1).toString(),this.dlgContainer.appendChild(this.dlgOverlay)},t.prototype.getValidFocusNode=function(e){for(var i,r=0;r0||"a"===i.tagName.toLowerCase()&&i.hasAttribute("href"))&&i.tabIndex>-1&&!i.disabled&&!this.disableElement(i,'[disabled],[aria-disabled="true"],[type="hidden"]'))return i;i=null}return i},t.prototype.focusableElements=function(e){if(!m(e)){var r=e.querySelectorAll('input,select,textarea,button,a,[contenteditable="true"],[tabindex]');return this.getValidFocusNode(r)}return null},t.prototype.getAutoFocusNode=function(e){var i=e.querySelector("."+I4),s=e.querySelectorAll("[autofocus]"),o=this.getValidFocusNode(s);if(ce()&&(this.primaryButtonEle=this.element.getElementsByClassName("e-primary")[0]),m(o)){if(!m(o=this.focusableElements(this.contentEle)))return o;if(!m(this.primaryButtonEle))return this.element.querySelector(".e-primary")}else i=o;return i},t.prototype.disableElement=function(e,i){var r=e?e.matches||e.webkitMatchesSelector||e.msGetRegionContent:null;if(r)for(;e;e=e.parentNode)if(e instanceof Element&&r.call(e,i))return e;return null},t.prototype.focusContent=function(){var e=this.getAutoFocusNode(this.element),i=m(e)?this.element:e,r=X.userAgent;(r.indexOf("MSIE ")>0||r.indexOf("Trident/")>0)&&this.element.focus(),i.focus(),this.unBindEvent(this.element),this.bindEvent(this.element)},t.prototype.bindEvent=function(e){E.add(e,"keydown",this.keyDown,this)},t.prototype.unBindEvent=function(e){E.remove(e,"keydown",this.keyDown)},t.prototype.updateSanitizeContent=function(){this.isBlazorServerRender()||(this.contentEle.innerHTML=this.sanitizeHelper(this.content))},t.prototype.isBlazorServerRender=function(){return ce()&&this.isServerRendered},t.prototype.getModuleName=function(){return"dialog"},t.prototype.onPropertyChanged=function(e,i){if(this.element.classList.contains(Y0))for(var r=0,s=Object.keys(e);r0?this.showCloseIcon||""!==this.header&&!m(this.header)?this.showCloseIcon||he(this.closeIcon):(he(this.headerContent),this.headerContent=null):(this.renderCloseIcon(),this.wireEvents());break;case"locale":this.showCloseIcon&&this.closeIconTitle();break;case"visible":this.visible?this.show():this.hide();break;case"isModal":this.updateIsModal();break;case"height":je(this.element,{height:Re(e.height)}),this.updatePersistData();break;case"width":je(this.element,{width:Re(e.width)}),this.updatePersistData();break;case"zIndex":this.popupObj.zIndex=this.zIndex,this.isModal&&this.setOverlayZindex(this.zIndex),this.element.style.zIndex!==this.zIndex.toString()&&(this.calculatezIndex=!1);break;case"cssClass":this.setCSSClass(i.cssClass);break;case"buttons":this.unWireButtonEvents(),this.destroyButtons(),m(this.ftrTemplateContent)||(he(this.ftrTemplateContent),this.ftrTemplateContent=null),this.footerTemplate="",this.setButton();break;case"allowDragging":this.allowDragging&&!m(this.headerContent)?this.setAllowDragging():this.dragObj.destroy();break;case"target":this.setTarget(e.target);break;case"position":if(this.checkPositionData(),this.isModal){var a=this.position.X,l=this.position.Y;m(i.position)||(m(i.position.X)||(a=i.position.X),m(i.position.Y)||(l=i.position.Y)),this.dlgContainer.classList.contains("e-dlg-"+a+"-"+l)&&this.dlgContainer.classList.remove("e-dlg-"+a+"-"+l)}this.positionChange(),this.updatePersistData();break;case"enableRtl":this.setEnableRTL();break;case"enableResize":this.setResize(),this.isModelResize=this.enableResize&&this.isModal,this.enableResize&&this.dialogOpen&&this.resetResizeIcon();break;case"minHeight":""!==this.minHeight&&(this.element.style.minHeight=Re(this.minHeight))}},t.prototype.setTarget=function(e){this.popupObj.relateTo=e,this.target=e,this.targetEle="string"==typeof this.target?document.querySelector(this.target):this.target,this.dragObj&&(this.dragObj.dragArea=this.targetEle),this.setMaxHeight(),this.isModal&&this.updateIsModal(),this.enableResize&&this.setResize(),m(this.targetEle)||(this.isModal&&!m(this.dlgContainer)?this.targetEle.appendChild(this.dlgContainer):m(this.element)||this.targetEle.appendChild(this.element))},t.prototype.updateIsModal=function(){if(this.element.setAttribute("aria-modal",this.isModal?"true":"false"),this.isModal)m(this.dlgOverlay)&&(this.setIsModal(),this.element.style.top="0px",this.element.style.left="0px",m(this.targetEle)||this.targetEle.appendChild(this.dlgContainer));else{for(K([this.element],G0),K([document.body],[Pa,ea]),he(this.dlgOverlay);this.dlgContainer.firstChild;)this.dlgContainer.parentElement.insertBefore(this.dlgContainer.firstChild,this.dlgContainer);this.dlgContainer.parentElement.removeChild(this.dlgContainer)}this.visible&&this.show(),this.positionChange(),this.isModal&&this.dlgOverlay&&E.add(this.dlgOverlay,"click",this.dlgOverlayClickEventHandler,this)},t.prototype.setzIndex=function(e,i){var r=this.isProtectedOnChange;this.isProtectedOnChange=!0;var s=hc(e);this.zIndex=s>this.zIndex?s:this.zIndex,this.isProtectedOnChange=r,i&&(this.popupObj.zIndex=this.zIndex)},t.prototype.windowResizeHandler=function(){(function IJ(n){Sh=n})(this.targetEle.clientWidth),function bJ(n){yh=n}(this.targetEle.clientHeight),this.setMaxHeight()},t.prototype.getPersistData=function(){return this.addOnPersist(["width","height","position"])},t.prototype.removeAllChildren=function(e){for(;e.children[0];)this.removeAllChildren(e.children[0]),e.removeChild(e.children[0])},t.prototype.destroy=function(){if(!this.isDestroyed){var e=[PE,G0,RE,uf,X0,S4],i=["role","aria-modal","aria-labelledby","aria-describedby","aria-grabbed","tabindex","style"];K([this.targetEle],[Pa,ea]),!m(this.element)&&this.element.classList.contains(X0)&&K([document.body],[Pa,ea]),this.isModal&&K([m(this.targetEle)?document.body:this.targetEle],ea),this.unWireEvents(),this.unWireButtonEvents(),this.destroyButtons(),m(this.closeIconBtnObj)||this.closeIconBtnObj.destroy(),m(this.dragObj)||this.dragObj.destroy(),!m(this.popupObj.element)&&this.popupObj.element.classList.contains("e-popup")&&this.popupObj.destroy(),K([this.element],e),!m(this.cssClass)&&""!==this.cssClass&&K([this.element],this.cssClass.split(" ")),!m(this.refElement)&&!m(this.refElement.parentElement)&&(this.refElement.parentElement.insertBefore(this.isModal?this.dlgContainer:this.element,this.refElement),he(this.refElement),this.refElement=void 0),this.isModal&&(he(this.dlgOverlay),this.dlgContainer.parentNode.insertBefore(this.element,this.dlgContainer),he(this.dlgContainer)),this.element.innerHTML=this.clonedEle.innerHTML;for(var r=0;r0&&""===this.footerTemplate&&this.ftrTemplateContent)for(var e=0;e=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},BE="e-tooltip",O4="e-icons",k4="e-tooltip-close",FE="e-tooltip-wrap",P4="e-tip-content",ff="e-arrow-tip",z4="e-arrow-tip-outer",q0="e-arrow-tip-inner",Gg="e-tip-bottom",_E="e-tip-top",R4="e-tip-left",UE="e-tip-right",jE="e-popup",Xg="e-popup-open",VE="e-popup-close",$0="e-lib",H4="e-tooltip-popup-container",VJ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return T4(t,n),Gi([I({effect:"FadeIn",duration:150,delay:0})],t.prototype,"open",void 0),Gi([I({effect:"FadeOut",duration:150,delay:0})],t.prototype,"close",void 0),t}(Ee),bh=function(n){function t(e,i){var r=n.call(this,e,i)||this;return r.mouseMoveEvent=null,r.mouseMoveTarget=null,r.containerElement=null,r.isBodyContainer=!0,r}return T4(t,n),t.prototype.initialize=function(){this.formatPosition(),V([this.element],BE)},t.prototype.formatPosition=function(){var e,i;this.position&&(0===this.position.indexOf("Top")||0===this.position.indexOf("Bottom")?(e=this.position.split(/(?=[A-Z])/),this.tooltipPositionY=e[0],this.tooltipPositionX=e[1]):(i=this.position.split(/(?=[A-Z])/),this.tooltipPositionX=i[0],this.tooltipPositionY=i[1]))},t.prototype.renderArrow=function(){this.setTipClass(this.position);var e=this.createElement("div",{className:ff+" "+this.tipClass});e.appendChild(this.createElement("div",{className:z4+" "+this.tipClass})),e.appendChild(this.createElement("div",{className:q0+" "+this.tipClass})),this.tooltipEle.appendChild(e)},t.prototype.setTipClass=function(e){this.tipClass=0===e.indexOf("Right")?R4:0===e.indexOf("Bottom")?_E:0===e.indexOf("Left")?UE:Gg},t.prototype.renderPopup=function(e){var i=this.mouseTrail?{top:0,left:0}:this.getTooltipPosition(e);this.tooltipEle.classList.remove($0),this.popupObj=new lc(this.tooltipEle,{height:this.height,width:this.width,position:{X:i.left,Y:i.top},enableRtl:this.enableRtl,open:this.openPopupHandler.bind(this),close:this.closePopupHandler.bind(this)})},t.prototype.getScalingFactor=function(e){if(!e)return{x:1,y:1};var i={x:1,y:1},r=e.closest('[style*="transform: scale"]');if(r&&r!==this.tooltipEle&&r.contains(this.tooltipEle)){var a=window.getComputedStyle(r).getPropertyValue("transform").match(/matrix\(([^)]+)\)/)[1].split(",").map(parseFloat);i.x=a[0],i.y=a[3]}return i},t.prototype.getTooltipPosition=function(e){this.tooltipEle.style.display="block";var i=this.element.closest('[style*="zoom"]');i&&(i.contains(this.tooltipEle)||(this.tooltipEle.style.zoom=getComputedStyle(i).zoom));var r=ns(e,this.tooltipPositionX,this.tooltipPositionY,!this.isBodyContainer,this.isBodyContainer?null:this.containerElement.getBoundingClientRect()),s=this.getScalingFactor(e),o=this.calculateTooltipOffset(this.position,s.x,s.y),a=this.calculateElementPosition(r,o),c=this.collisionFlipFit(e,a[0],a[1]);return c.left=c.left/s.x,c.top=c.top/s.y,this.tooltipEle.style.display="",c},t.prototype.windowResize=function(){this.reposition(this.findTarget())},t.prototype.reposition=function(e){if(this.popupObj&&e){var i=this.getTooltipPosition(e);this.popupObj.position={X:i.left,Y:i.top},this.popupObj.dataBind()}},t.prototype.openPopupHandler=function(){!this.mouseTrail&&this.needTemplateReposition()&&this.reposition(this.findTarget()),this.trigger("afterOpen",this.tooltipEventArgs),this.tooltipEventArgs=null},t.prototype.closePopupHandler=function(){this.isReact&&!("Click"===this.opensOn||"function"==typeof this.content)&&this.clearTemplate(["content"]),this.clear();var e={type:this.tooltipEventArgs.event?this.tooltipEventArgs.event.type:null,cancel:!1,target:this.tooltipEventArgs.target,event:this.tooltipEventArgs.event?this.tooltipEventArgs.event:null,element:this.tooltipEle,isInteracted:!m(this.tooltipEventArgs.event)};this.trigger("afterClose",e),e=null},t.prototype.calculateTooltipOffset=function(e,i,r){void 0===i&&(i=1),void 0===r&&(r=1);var o,a,l,h,c,d,u,f,s={top:0,left:0};if(1!==i||1!==r){var p=this.tooltipEle.getBoundingClientRect(),g=void 0;l=Math.round(p.width),h=Math.round(p.height),(c=_("."+ff,this.tooltipEle))&&(g=c.getBoundingClientRect()),o=c?Math.round(g.width):0,a=c?Math.round(g.height):0,d=this.showTipPointer?0:8,u=a/2+2+(h-this.tooltipEle.clientHeight*r),f=o/2+2+(l-this.tooltipEle.clientWidth*i)}else l=this.tooltipEle.offsetWidth,h=this.tooltipEle.offsetHeight,c=_("."+ff,this.tooltipEle),d=this.showTipPointer?0:8,u=(a=c?c.offsetHeight:0)/2+2+(this.tooltipEle.offsetHeight-this.tooltipEle.clientHeight),f=(o=c?c.offsetWidth:0)/2+2+(this.tooltipEle.offsetWidth-this.tooltipEle.clientWidth);switch(this.mouseTrail&&(d+=2),e){case"RightTop":s.left+=o+d,s.top-=h-u;break;case"RightCenter":s.left+=o+d,s.top-=h/2;break;case"RightBottom":s.left+=o+d,s.top-=u;break;case"BottomRight":s.top+=a+d,s.left-=f;break;case"BottomCenter":s.top+=a+d,s.left-=l/2;break;case"BottomLeft":s.top+=a+d,s.left-=l-f;break;case"LeftBottom":s.left-=o+l+d,s.top-=u;break;case"LeftCenter":s.left-=o+l+d,s.top-=h/2;break;case"LeftTop":s.left-=o+l+d,s.top-=h-u;break;case"TopLeft":s.top-=h+a+d,s.left-=l-f;break;case"TopRight":s.top-=h+a+d,s.left-=f;break;default:s.top-=h+a+d,s.left-=l/2}return s.left+=this.offsetX,s.top+=this.offsetY,s},t.prototype.updateTipPosition=function(e){var i=we("."+ff+",."+z4+",."+q0,this.tooltipEle);K(i,[Gg,_E,R4,UE]),this.setTipClass(e),V(i,this.tipClass)},t.prototype.adjustArrow=function(e,i,r,s){var o=_("."+ff,this.tooltipEle);if(!1!==this.showTipPointer&&null!==o){var a,l;this.updateTipPosition(i),this.tooltipEle.style.display="block";var p,h=this.tooltipEle.clientWidth,c=this.tooltipEle.clientHeight,d=_("."+q0,this.tooltipEle),u=o.offsetWidth,f=o.offsetHeight;this.tooltipEle.style.display="",this.tipClass===Gg||this.tipClass===_E?(this.tipClass===Gg?(l="99.9%",d.style.top="-"+(f-2)+"px"):(l=-(f-1)+"px",d.style.top="-"+(f-6)+"px"),e&&(a=(p="Center"!==r||h>e.offsetWidth||this.mouseTrail)&&"Left"===r||!p&&"End"===this.tipPointerPosition?h-u-2+"px":p&&"Right"===r||!p&&"Start"===this.tipPointerPosition?"2px":!p||"End"!==this.tipPointerPosition&&"Start"!==this.tipPointerPosition?h/2-u/2+"px":"End"===this.tipPointerPosition?e.offsetWidth+(this.tooltipEle.offsetWidth-e.offsetWidth)/2-u/2-2+"px":(this.tooltipEle.offsetWidth-e.offsetWidth)/2-u/2+2+"px")):(this.tipClass===UE?(a="99.9%",d.style.left="-"+(u-2)+"px"):(a=-(u-1)+"px",d.style.left=u-2-u+"px"),l=(p="Center"!==s||c>e.offsetHeight||this.mouseTrail)&&"Top"===s||!p&&"End"===this.tipPointerPosition?c-f-2+"px":p&&"Bottom"===s||!p&&"Start"===this.tipPointerPosition?"2px":c/2-f/2+"px"),o.style.top=l,o.style.left=a}},t.prototype.renderContent=function(e){var i=this,r=_("."+P4,this.tooltipEle);if(this.cssClass&&V([this.tooltipEle],this.cssClass.split(" ")),e&&!m(e.getAttribute("title"))&&(e.setAttribute("data-content",e.getAttribute("title")),e.removeAttribute("title")),m(this.content))e&&!m(e.getAttribute("data-content"))&&(r.innerHTML=e.getAttribute("data-content"));else if(r.innerHTML="",this.content instanceof HTMLElement)r.appendChild(this.content);else if("string"==typeof this.content)this.isAngular?this.setProperties({content:Ai.sanitize(this.content)},!0):this.content=this.enableHtmlSanitizer?Ai.sanitize(this.content):this.content,this.enableHtmlParse?(o=oi(this.content)({},this,"content",this.element.id+"content",void 0,void 0,r,this.root))&&Dt(o,r):r.textContent=this.content;else{var o;(o=oi(this.content)({},this,"content",this.element.id+"content",void 0,void 0,r))&&(this.isAngular&&setTimeout(function(){i.reposition(e)},1),Dt(o,r)),this.renderReactTemplates()}},t.prototype.renderCloseIcon=function(){if(this.isSticky){var i=this.createElement("div",{className:O4+" "+k4});this.tooltipEle.appendChild(i),E.add(i,X.touchStartEvent,this.onStickyClose,this)}else{var e=this.tooltipEle.querySelector("."+O4+"."+k4);e&>(e)}},t.prototype.addDescribedBy=function(e,i){var r=(e.getAttribute("aria-describedby")||"").split(/\s+/);r.indexOf(i)<0&&r.push(i),Fe(e,{"aria-describedby":r.join(" ").trim(),"data-tooltip-id":i})},t.prototype.removeDescribedBy=function(e){var i=e.getAttribute("data-tooltip-id"),r=(e.getAttribute("aria-describedby")||"").split(/\s+/),s=r.indexOf(i);-1!==s&&r.splice(s,1),e.removeAttribute("data-tooltip-id");var o=r.join(" ").trim();o?e.setAttribute("aria-describedby",o):e.removeAttribute("aria-describedby")},t.prototype.tapHoldHandler=function(e){clearTimeout(this.autoCloseTimer),this.targetHover(e.originalEvent)},t.prototype.touchEndHandler=function(){var e=this;this.isSticky||(this.autoCloseTimer=setTimeout(function(){e.close()},1500))},t.prototype.targetClick=function(e){var i;!m(i=this.target?J(e.target,this.target):this.element)&&(null===i.getAttribute("data-tooltip-id")?this.targetHover(e):this.isSticky||this.hideTooltip(this.animation.close,e,i))},t.prototype.targetHover=function(e){var i;if(!(m(i=this.target?J(e.target,this.target):this.element)||null!==i.getAttribute("data-tooltip-id")&&0===this.closeDelay)){for(var s=0,o=[].slice.call(we('[data-tooltip-id= "'+this.ctrlId+'_content"]',document));s0?this.showTimer=setTimeout(function(){o.mouseTrail&&E.add(i,"mousemove touchstart mouseenter",o.onMouseMove,o),o.popupObj&&(o.popupObj.show(a,i),o.mouseMoveEvent&&o.mouseTrail&&o.onMouseMove(o.mouseMoveEvent))},this.openDelay):this.popupObj&&this.popupObj.show(a,i)}s&&this.wireMouseEvents(s,i)},t.prototype.needTemplateReposition=function(){return!m(this.viewContainerRef)&&"string"!=typeof this.viewContainerRef||this.isReact},t.prototype.checkCollision=function(e,i,r){var s={left:i,top:r,position:this.position,horizontal:this.tooltipPositionX,vertical:this.tooltipPositionY},o=ac(this.tooltipEle,this.checkCollideTarget(),i,r);return o.length>0&&(s.horizontal=o.indexOf("left")>=0?"Right":o.indexOf("right")>=0?"Left":this.tooltipPositionX,s.vertical=o.indexOf("top")>=0?"Bottom":o.indexOf("bottom")>=0?"Top":this.tooltipPositionY),s},t.prototype.calculateElementPosition=function(e,i){return[this.isBodyContainer?e.left+i.left:e.left-this.containerElement.getBoundingClientRect().left+i.left+window.pageXOffset+this.containerElement.scrollLeft,this.isBodyContainer?e.top+i.top:e.top-this.containerElement.getBoundingClientRect().top+i.top+window.pageYOffset+this.containerElement.scrollTop]},t.prototype.collisionFlipFit=function(e,i,r){var s=this.checkCollision(e,i,r),o=s.position;if(this.tooltipPositionY!==s.vertical&&(o=0===this.position.indexOf("Bottom")||0===this.position.indexOf("Top")?s.vertical+this.tooltipPositionX:this.tooltipPositionX+s.vertical),this.tooltipPositionX!==s.horizontal&&(0===o.indexOf("Left")&&(s.vertical="LeftTop"===o||"LeftCenter"===o?"Top":"Bottom",o=s.vertical+"Left"),0===o.indexOf("Right")&&(s.vertical="RightTop"===o||"RightCenter"===o?"Top":"Bottom",o=s.vertical+"Right"),s.horizontal=this.tooltipPositionX),this.tooltipEventArgs={type:null,cancel:!1,target:e,event:null,element:this.tooltipEle,collidedPosition:o},this.trigger("beforeCollision",this.tooltipEventArgs),this.tooltipEventArgs.cancel)o=this.position;else{var a=s.vertical,l=s.horizontal;if(s.position!==o){var h=ns(e,l,a,!this.isBodyContainer,this.isBodyContainer?null:this.containerElement.getBoundingClientRect());this.adjustArrow(e,o,l,a);var c=this.getScalingFactor(e),d=this.calculateTooltipOffset(o,c.x,c.y);d.top-=this.getOffSetPosition("TopBottom",o,this.offsetY),d.left-=this.getOffSetPosition("RightLeft",o,this.offsetX),s.position=o;var u=this.calculateElementPosition(h,d);s.left=u[0],s.top=u[1]}else this.adjustArrow(e,o,l,a)}var f={left:s.left,top:s.top},p=this.isBodyContainer?uE(this.tooltipEle,this.checkCollideTarget(),{X:!0,Y:this.windowCollision},f):f;this.tooltipEle.style.display="block";var g=_("."+ff,this.tooltipEle);if(this.showTipPointer&&null!=g&&(0===o.indexOf("Bottom")||0===o.indexOf("Top"))){var v=parseInt(g.style.left,10)-(p.left-s.left);v<0?v=0:v+g.offsetWidth>this.tooltipEle.clientWidth&&(v=this.tooltipEle.clientWidth-g.offsetWidth),g.style.left=v.toString()+"px"}return this.tooltipEle.style.display="",f.left=p.left,f.top=p.top,f},t.prototype.getOffSetPosition=function(e,i,r){return-1!==e.indexOf(this.position.split(/(?=[A-Z])/)[0])&&-1!==e.indexOf(i.split(/(?=[A-Z])/)[0])?2*r:0},t.prototype.checkCollideTarget=function(){return!this.windowCollision&&this.target?this.element:null},t.prototype.hideTooltip=function(e,i,r){var s=this;this.closeDelay>0?(clearTimeout(this.hideTimer),clearTimeout(this.showTimer),this.hideTimer=setTimeout(function(){s.closeDelay&&s.tooltipEle&&s.isTooltipOpen||s.tooltipHide(e,i,r)},this.closeDelay)):this.tooltipHide(e,i,r)},t.prototype.tooltipHide=function(e,i,r){var o,s=this;o=i?this.target?r||i.target:this.element:_('[data-tooltip-id= "'+this.ctrlId+'_content"]',document),this.tooltipEventArgs={type:i?i.type:null,cancel:!1,target:o,event:i||null,element:this.tooltipEle,isInteracted:!m(i)},this.trigger("beforeClose",this.tooltipEventArgs,function(a){a.cancel?s.isHidden=!1:(s.mouseMoveBeforeRemove(),s.popupHide(e,o,i))})},t.prototype.popupHide=function(e,i,r){i&&r&&this.restoreElement(i),this.isHidden=!0;var s={name:this.animation.close.effect,duration:e.duration,delay:e.delay,timingFunction:"easeIn"};"None"===e.effect&&(s=void 0),this.popupObj&&this.popupObj.hide(s)},t.prototype.restoreElement=function(e){this.unwireMouseEvents(e),m(e.getAttribute("data-content"))||(e.setAttribute("title",e.getAttribute("data-content")),e.removeAttribute("data-content")),this.removeDescribedBy(e)},t.prototype.clear=function(){var e=this.findTarget();e&&this.restoreElement(e),this.tooltipEle&&(K([this.tooltipEle],VE),V([this.tooltipEle],Xg)),this.isHidden&&(this.popupObj&&this.popupObj.destroy(),this.tooltipEle&>(this.tooltipEle),this.tooltipEle=null,this.popupObj=null)},t.prototype.tooltipHover=function(){this.tooltipEle&&(this.isTooltipOpen=!0)},t.prototype.tooltipMouseOut=function(e){this.isTooltipOpen=!1,this.hideTooltip(this.animation.close,e,this.findTarget())},t.prototype.onMouseOut=function(e){var i=e.relatedTarget;if(i&&!this.mouseTrail){var r=J(i,"."+FE+"."+$0+"."+jE);r?E.add(r,"mouseleave",this.tooltipElementMouseOut,this):(this.hideTooltip(this.animation.close,e,this.findTarget()),0===this.closeDelay&&("None"===this.animation.close.effect||this.isReact&&"string"!=typeof this.content)&&this.clear())}else this.hideTooltip(this.animation.close,e,this.findTarget()),this.clear();this.popupObj&&!this.popupObj.element.classList.contains(Xg)&&this.clear()},t.prototype.tooltipElementMouseOut=function(e){this.hideTooltip(this.animation.close,e,this.findTarget()),E.remove(this.element,"mouseleave",this.tooltipElementMouseOut),this.clear()},t.prototype.onStickyClose=function(){this.close()},t.prototype.onMouseMove=function(e){var i=0,r=0;e.type.indexOf("touch")>-1?(e.preventDefault(),i=e.touches[0].pageX,r=e.touches[0].pageY):(i=e.pageX,r=e.pageY),Hs.stop(this.tooltipEle),K([this.tooltipEle],VE),V([this.tooltipEle],Xg),this.adjustArrow(e.target,this.position,this.tooltipPositionX,this.tooltipPositionY);var s=this.getScalingFactor(e.target),o=this.calculateTooltipOffset(this.position,s.x,s.y),h=this.checkCollision(e.target,i+o.left+this.offsetX,r+o.top+this.offsetY);if(this.tooltipPositionX!==h.horizontal||this.tooltipPositionY!==h.vertical){var c=0===this.position.indexOf("Bottom")||0===this.position.indexOf("Top")?h.vertical+h.horizontal:h.horizontal+h.vertical;h.position=c,this.adjustArrow(e.target,h.position,h.horizontal,h.vertical);var d=this.calculateTooltipOffset(h.position,s.x,s.y);h.left=i+d.left-this.offsetX,h.top=r+d.top-this.offsetY}this.tooltipEle.style.left=h.left+"px",this.tooltipEle.style.top=h.top+"px"},t.prototype.keyDown=function(e){this.tooltipEle&&27===e.keyCode&&this.close()},t.prototype.touchEnd=function(e){this.tooltipEle&&null===J(e.target,"."+BE)&&!this.isSticky&&this.close()},t.prototype.scrollHandler=function(e){this.tooltipEle&&!this.isSticky&&!J(e.target,"."+FE+"."+$0+"."+jE)&&!this.isSticky&&this.close()},t.prototype.render=function(){this.initialize(),this.wireEvents(this.opensOn),this.renderComplete()},t.prototype.preRender=function(){this.tipClass=Gg,this.tooltipPositionX="Center",this.tooltipPositionY="Top",this.isHidden=!0},t.prototype.wireEvents=function(e){for(var r=0,s=this.getTriggerList(e);r0)for(var i=0,r=e;i0)for(var i=0,r=e;i0&&this.condition&&-1!==this.condition.indexOf("not")&&(e[s].condition=e[s].condition?e[s].condition+"not":"not"),i=e[s].validate(t),r){if(!i)return!1}else if(i)return!0;return r},n.prototype.toJson=function(){var t,e;if(this.isComplex){t=[],e=this.predicates;for(var i=0;ie.length-3?(e=e.substring(0,e.length-1),n.endsWith(n.toLowerCase(t),n.toLowerCase(e))):(e.lastIndexOf("%")!==e.indexOf("%")&&e.lastIndexOf("%")>e.indexOf("%")+1&&(e=e.substring(e.indexOf("%")+1,e.lastIndexOf("%"))),-1!==t.indexOf(e)))},n.fnSort=function(t){return"ascending"===(t=t?n.toLowerCase(t):"ascending")?this.fnAscending:this.fnDescending},n.fnAscending=function(t,e){return m(t)&&m(e)||null==e?-1:"string"==typeof t?t.localeCompare(e):null==t?1:t-e},n.fnDescending=function(t,e){return m(t)&&m(e)?-1:null==e?1:"string"==typeof t?-1*t.localeCompare(e):null==t?-1:e-t},n.extractFields=function(t,e){for(var i={},r=0;r0||e.length>0;)o=t.length>0&&e.length>0?r?r(this.getVal(t,0,i),this.getVal(e,0,i),t[0],e[0])<=0?t:e:t[0][i]0?t:e,s.push(o.shift());return s},n.getVal=function(t,e,i){return i?this.getObject(i,t[e]):t[e]},n.toLowerCase=function(t){return t?"string"==typeof t?t.toLowerCase():t.toString():0===t||!1===t?t.toString():""},n.callAdaptorFunction=function(t,e,i,r){if(e in t){var s=t[e](i,r);m(s)||(i=s)}return i},n.getAddParams=function(t,e,i){var r={};return n.callAdaptorFunction(t,"addParams",{dm:e,query:i,params:i?i.params:[],reqParams:r}),r},n.isPlainObject=function(t){return!!t&&t.constructor===Object},n.isCors=function(){var t=null;try{t=new window.XMLHttpRequest}catch{}return!!t&&"withCredentials"in t},n.getGuid=function(t){var i;return(t||"")+"00000000-0000-4000-0000-000000000000".replace(/0/g,function(r,s){if("crypto"in window&&"getRandomValues"in crypto){var o=new Uint8Array(1);window.crypto.getRandomValues(o),i=o[0]%16|0}else i=16*Math.random()|0;return"0123456789abcdef"[19===s?3&i|8:i]})},n.isNull=function(t){return null==t},n.getItemFromComparer=function(t,e,i){var r,s,o,a=0,l="string"==typeof n.getVal(t,0,e);if(t.length)for(;m(r)&&a0&&(r=s,o=t[a]));return o},n.distinct=function(t,e,i){i=!m(i)&&i;var s,r=[],o={};return t.forEach(function(a,l){(s="object"==typeof t[l]?n.getVal(t,l,e):t[l])in o||(r.push(i?t[l]:s),o[s]=1)}),r},n.processData=function(t,e){var i=this.prepareQuery(t),r=new it(e);t.requiresCounts&&i.requiresCount();var s=r.executeLocal(i),o={result:t.requiresCounts?s.result:s,count:s.count,aggregates:JSON.stringify(s.aggregates)};return t.requiresCounts?o:s},n.prepareQuery=function(t){var e=this,i=new _t;return t.select&&i.select(t.select),t.where&&n.parse.parseJson(t.where).filter(function(o){if(m(o.condition))i.where(o.field,o.operator,o.value,o.ignoreCase,o.ignoreAccent);else{var a=[];o.field?a.push(new Ss(o.field,o.operator,o.value,o.ignoreCase,o.ignoreAccent)):a=a.concat(e.getPredicate(o.predicates)),"or"===o.condition?i.where(Ss.or(a)):"and"===o.condition&&i.where(Ss.and(a))}}),t.search&&n.parse.parseJson(t.search).filter(function(o){return i.search(o.key,o.fields,o.operator,o.ignoreCase,o.ignoreAccent)}),t.aggregates&&t.aggregates.filter(function(o){return i.aggregate(o.type,o.field)}),t.sorted&&t.sorted.filter(function(o){return i.sortBy(o.name,o.direction)}),t.skip&&i.skip(t.skip),t.take&&i.take(t.take),t.group&&t.group.filter(function(o){return i.group(o)}),i},n.getPredicate=function(t){for(var e=[],i=0;i":"greaterthan","<=":"lessthanorequal",">=":"greaterthanorequal","==":"equal","!=":"notequal","*=":"contains","$=":"endswith","^=":"startswith"},n.odBiOperator={"<":" lt ",">":" gt ","<=":" le ",">=":" ge ","==":" eq ","!=":" ne ",lessthan:" lt ",lessthanorequal:" le ",greaterthan:" gt ",greaterthanorequal:" ge ",equal:" eq ",notequal:" ne "},n.odUniOperator={"$=":"endswith","^=":"startswith","*=":"substringof",endswith:"endswith",startswith:"startswith",contains:"substringof",doesnotendwith:"not endswith",doesnotstartwith:"not startswith",doesnotcontain:"not substringof",wildcard:"wildcard",like:"like"},n.odv4UniOperator={"$=":"endswith","^=":"startswith","*=":"contains",endswith:"endswith",startswith:"startswith",contains:"contains",doesnotendwith:"not endswith",doesnotstartwith:"not startswith",doesnotcontain:"not contains",wildcard:"wildcard",like:"like"},n.diacritics={"\u24b6":"A",\uff21:"A",\u00c0:"A",\u00c1:"A",\u00c2:"A",\u1ea6:"A",\u1ea4:"A",\u1eaa:"A",\u1ea8:"A",\u00c3:"A",\u0100:"A",\u0102:"A",\u1eb0:"A",\u1eae:"A",\u1eb4:"A",\u1eb2:"A",\u0226:"A",\u01e0:"A",\u00c4:"A",\u01de:"A",\u1ea2:"A",\u00c5:"A",\u01fa:"A",\u01cd:"A",\u0200:"A",\u0202:"A",\u1ea0:"A",\u1eac:"A",\u1eb6:"A",\u1e00:"A",\u0104:"A",\u023a:"A",\u2c6f:"A",\ua732:"AA",\u00c6:"AE",\u01fc:"AE",\u01e2:"AE",\ua734:"AO",\ua736:"AU",\ua738:"AV",\ua73a:"AV",\ua73c:"AY","\u24b7":"B",\uff22:"B",\u1e02:"B",\u1e04:"B",\u1e06:"B",\u0243:"B",\u0182:"B",\u0181:"B","\u24b8":"C",\uff23:"C",\u0106:"C",\u0108:"C",\u010a:"C",\u010c:"C",\u00c7:"C",\u1e08:"C",\u0187:"C",\u023b:"C",\ua73e:"C","\u24b9":"D",\uff24:"D",\u1e0a:"D",\u010e:"D",\u1e0c:"D",\u1e10:"D",\u1e12:"D",\u1e0e:"D",\u0110:"D",\u018b:"D",\u018a:"D",\u0189:"D",\ua779:"D",\u01f1:"DZ",\u01c4:"DZ",\u01f2:"Dz",\u01c5:"Dz","\u24ba":"E",\uff25:"E",\u00c8:"E",\u00c9:"E",\u00ca:"E",\u1ec0:"E",\u1ebe:"E",\u1ec4:"E",\u1ec2:"E",\u1ebc:"E",\u0112:"E",\u1e14:"E",\u1e16:"E",\u0114:"E",\u0116:"E",\u00cb:"E",\u1eba:"E",\u011a:"E",\u0204:"E",\u0206:"E",\u1eb8:"E",\u1ec6:"E",\u0228:"E",\u1e1c:"E",\u0118:"E",\u1e18:"E",\u1e1a:"E",\u0190:"E",\u018e:"E","\u24bb":"F",\uff26:"F",\u1e1e:"F",\u0191:"F",\ua77b:"F","\u24bc":"G",\uff27:"G",\u01f4:"G",\u011c:"G",\u1e20:"G",\u011e:"G",\u0120:"G",\u01e6:"G",\u0122:"G",\u01e4:"G",\u0193:"G",\ua7a0:"G",\ua77d:"G",\ua77e:"G","\u24bd":"H",\uff28:"H",\u0124:"H",\u1e22:"H",\u1e26:"H",\u021e:"H",\u1e24:"H",\u1e28:"H",\u1e2a:"H",\u0126:"H",\u2c67:"H",\u2c75:"H",\ua78d:"H","\u24be":"I",\uff29:"I",\u00cc:"I",\u00cd:"I",\u00ce:"I",\u0128:"I",\u012a:"I",\u012c:"I",\u0130:"I",\u00cf:"I",\u1e2e:"I",\u1ec8:"I",\u01cf:"I",\u0208:"I",\u020a:"I",\u1eca:"I",\u012e:"I",\u1e2c:"I",\u0197:"I","\u24bf":"J",\uff2a:"J",\u0134:"J",\u0248:"J","\u24c0":"K",\uff2b:"K",\u1e30:"K",\u01e8:"K",\u1e32:"K",\u0136:"K",\u1e34:"K",\u0198:"K",\u2c69:"K",\ua740:"K",\ua742:"K",\ua744:"K",\ua7a2:"K","\u24c1":"L",\uff2c:"L",\u013f:"L",\u0139:"L",\u013d:"L",\u1e36:"L",\u1e38:"L",\u013b:"L",\u1e3c:"L",\u1e3a:"L",\u0141:"L",\u023d:"L",\u2c62:"L",\u2c60:"L",\ua748:"L",\ua746:"L",\ua780:"L",\u01c7:"LJ",\u01c8:"Lj","\u24c2":"M",\uff2d:"M",\u1e3e:"M",\u1e40:"M",\u1e42:"M",\u2c6e:"M",\u019c:"M","\u24c3":"N",\uff2e:"N",\u01f8:"N",\u0143:"N",\u00d1:"N",\u1e44:"N",\u0147:"N",\u1e46:"N",\u0145:"N",\u1e4a:"N",\u1e48:"N",\u0220:"N",\u019d:"N",\ua790:"N",\ua7a4:"N",\u01ca:"NJ",\u01cb:"Nj","\u24c4":"O",\uff2f:"O",\u00d2:"O",\u00d3:"O",\u00d4:"O",\u1ed2:"O",\u1ed0:"O",\u1ed6:"O",\u1ed4:"O",\u00d5:"O",\u1e4c:"O",\u022c:"O",\u1e4e:"O",\u014c:"O",\u1e50:"O",\u1e52:"O",\u014e:"O",\u022e:"O",\u0230:"O",\u00d6:"O",\u022a:"O",\u1ece:"O",\u0150:"O",\u01d1:"O",\u020c:"O",\u020e:"O",\u01a0:"O",\u1edc:"O",\u1eda:"O",\u1ee0:"O",\u1ede:"O",\u1ee2:"O",\u1ecc:"O",\u1ed8:"O",\u01ea:"O",\u01ec:"O",\u00d8:"O",\u01fe:"O",\u0186:"O",\u019f:"O",\ua74a:"O",\ua74c:"O",\u01a2:"OI",\ua74e:"OO",\u0222:"OU","\u24c5":"P",\uff30:"P",\u1e54:"P",\u1e56:"P",\u01a4:"P",\u2c63:"P",\ua750:"P",\ua752:"P",\ua754:"P","\u24c6":"Q",\uff31:"Q",\ua756:"Q",\ua758:"Q",\u024a:"Q","\u24c7":"R",\uff32:"R",\u0154:"R",\u1e58:"R",\u0158:"R",\u0210:"R",\u0212:"R",\u1e5a:"R",\u1e5c:"R",\u0156:"R",\u1e5e:"R",\u024c:"R",\u2c64:"R",\ua75a:"R",\ua7a6:"R",\ua782:"R","\u24c8":"S",\uff33:"S",\u1e9e:"S",\u015a:"S",\u1e64:"S",\u015c:"S",\u1e60:"S",\u0160:"S",\u1e66:"S",\u1e62:"S",\u1e68:"S",\u0218:"S",\u015e:"S",\u2c7e:"S",\ua7a8:"S",\ua784:"S","\u24c9":"T",\uff34:"T",\u1e6a:"T",\u0164:"T",\u1e6c:"T",\u021a:"T",\u0162:"T",\u1e70:"T",\u1e6e:"T",\u0166:"T",\u01ac:"T",\u01ae:"T",\u023e:"T",\ua786:"T",\ua728:"TZ","\u24ca":"U",\uff35:"U",\u00d9:"U",\u00da:"U",\u00db:"U",\u0168:"U",\u1e78:"U",\u016a:"U",\u1e7a:"U",\u016c:"U",\u00dc:"U",\u01db:"U",\u01d7:"U",\u01d5:"U",\u01d9:"U",\u1ee6:"U",\u016e:"U",\u0170:"U",\u01d3:"U",\u0214:"U",\u0216:"U",\u01af:"U",\u1eea:"U",\u1ee8:"U",\u1eee:"U",\u1eec:"U",\u1ef0:"U",\u1ee4:"U",\u1e72:"U",\u0172:"U",\u1e76:"U",\u1e74:"U",\u0244:"U","\u24cb":"V",\uff36:"V",\u1e7c:"V",\u1e7e:"V",\u01b2:"V",\ua75e:"V",\u0245:"V",\ua760:"VY","\u24cc":"W",\uff37:"W",\u1e80:"W",\u1e82:"W",\u0174:"W",\u1e86:"W",\u1e84:"W",\u1e88:"W",\u2c72:"W","\u24cd":"X",\uff38:"X",\u1e8a:"X",\u1e8c:"X","\u24ce":"Y",\uff39:"Y",\u1ef2:"Y",\u00dd:"Y",\u0176:"Y",\u1ef8:"Y",\u0232:"Y",\u1e8e:"Y",\u0178:"Y",\u1ef6:"Y",\u1ef4:"Y",\u01b3:"Y",\u024e:"Y",\u1efe:"Y","\u24cf":"Z",\uff3a:"Z",\u0179:"Z",\u1e90:"Z",\u017b:"Z",\u017d:"Z",\u1e92:"Z",\u1e94:"Z",\u01b5:"Z",\u0224:"Z",\u2c7f:"Z",\u2c6b:"Z",\ua762:"Z","\u24d0":"a",\uff41:"a",\u1e9a:"a",\u00e0:"a",\u00e1:"a",\u00e2:"a",\u1ea7:"a",\u1ea5:"a",\u1eab:"a",\u1ea9:"a",\u00e3:"a",\u0101:"a",\u0103:"a",\u1eb1:"a",\u1eaf:"a",\u1eb5:"a",\u1eb3:"a",\u0227:"a",\u01e1:"a",\u00e4:"a",\u01df:"a",\u1ea3:"a",\u00e5:"a",\u01fb:"a",\u01ce:"a",\u0201:"a",\u0203:"a",\u1ea1:"a",\u1ead:"a",\u1eb7:"a",\u1e01:"a",\u0105:"a",\u2c65:"a",\u0250:"a",\ua733:"aa",\u00e6:"ae",\u01fd:"ae",\u01e3:"ae",\ua735:"ao",\ua737:"au",\ua739:"av",\ua73b:"av",\ua73d:"ay","\u24d1":"b",\uff42:"b",\u1e03:"b",\u1e05:"b",\u1e07:"b",\u0180:"b",\u0183:"b",\u0253:"b","\u24d2":"c",\uff43:"c",\u0107:"c",\u0109:"c",\u010b:"c",\u010d:"c",\u00e7:"c",\u1e09:"c",\u0188:"c",\u023c:"c",\ua73f:"c",\u2184:"c","\u24d3":"d",\uff44:"d",\u1e0b:"d",\u010f:"d",\u1e0d:"d",\u1e11:"d",\u1e13:"d",\u1e0f:"d",\u0111:"d",\u018c:"d",\u0256:"d",\u0257:"d",\ua77a:"d",\u01f3:"dz",\u01c6:"dz","\u24d4":"e",\uff45:"e",\u00e8:"e",\u00e9:"e",\u00ea:"e",\u1ec1:"e",\u1ebf:"e",\u1ec5:"e",\u1ec3:"e",\u1ebd:"e",\u0113:"e",\u1e15:"e",\u1e17:"e",\u0115:"e",\u0117:"e",\u00eb:"e",\u1ebb:"e",\u011b:"e",\u0205:"e",\u0207:"e",\u1eb9:"e",\u1ec7:"e",\u0229:"e",\u1e1d:"e",\u0119:"e",\u1e19:"e",\u1e1b:"e",\u0247:"e",\u025b:"e",\u01dd:"e","\u24d5":"f",\uff46:"f",\u1e1f:"f",\u0192:"f",\ua77c:"f","\u24d6":"g",\uff47:"g",\u01f5:"g",\u011d:"g",\u1e21:"g",\u011f:"g",\u0121:"g",\u01e7:"g",\u0123:"g",\u01e5:"g",\u0260:"g",\ua7a1:"g",\u1d79:"g",\ua77f:"g","\u24d7":"h",\uff48:"h",\u0125:"h",\u1e23:"h",\u1e27:"h",\u021f:"h",\u1e25:"h",\u1e29:"h",\u1e2b:"h",\u1e96:"h",\u0127:"h",\u2c68:"h",\u2c76:"h",\u0265:"h",\u0195:"hv","\u24d8":"i",\uff49:"i",\u00ec:"i",\u00ed:"i",\u00ee:"i",\u0129:"i",\u012b:"i",\u012d:"i",\u00ef:"i",\u1e2f:"i",\u1ec9:"i",\u01d0:"i",\u0209:"i",\u020b:"i",\u1ecb:"i",\u012f:"i",\u1e2d:"i",\u0268:"i",\u0131:"i","\u24d9":"j",\uff4a:"j",\u0135:"j",\u01f0:"j",\u0249:"j","\u24da":"k",\uff4b:"k",\u1e31:"k",\u01e9:"k",\u1e33:"k",\u0137:"k",\u1e35:"k",\u0199:"k",\u2c6a:"k",\ua741:"k",\ua743:"k",\ua745:"k",\ua7a3:"k","\u24db":"l",\uff4c:"l",\u0140:"l",\u013a:"l",\u013e:"l",\u1e37:"l",\u1e39:"l",\u013c:"l",\u1e3d:"l",\u1e3b:"l",\u017f:"l",\u0142:"l",\u019a:"l",\u026b:"l",\u2c61:"l",\ua749:"l",\ua781:"l",\ua747:"l",\u01c9:"lj","\u24dc":"m",\uff4d:"m",\u1e3f:"m",\u1e41:"m",\u1e43:"m",\u0271:"m",\u026f:"m","\u24dd":"n",\uff4e:"n",\u01f9:"n",\u0144:"n",\u00f1:"n",\u1e45:"n",\u0148:"n",\u1e47:"n",\u0146:"n",\u1e4b:"n",\u1e49:"n",\u019e:"n",\u0272:"n",\u0149:"n",\ua791:"n",\ua7a5:"n",\u01cc:"nj","\u24de":"o",\uff4f:"o",\u00f2:"o",\u00f3:"o",\u00f4:"o",\u1ed3:"o",\u1ed1:"o",\u1ed7:"o",\u1ed5:"o",\u00f5:"o",\u1e4d:"o",\u022d:"o",\u1e4f:"o",\u014d:"o",\u1e51:"o",\u1e53:"o",\u014f:"o",\u022f:"o",\u0231:"o",\u00f6:"o",\u022b:"o",\u1ecf:"o",\u0151:"o",\u01d2:"o",\u020d:"o",\u020f:"o",\u01a1:"o",\u1edd:"o",\u1edb:"o",\u1ee1:"o",\u1edf:"o",\u1ee3:"o",\u1ecd:"o",\u1ed9:"o",\u01eb:"o",\u01ed:"o",\u00f8:"o",\u01ff:"o",\u0254:"o",\ua74b:"o",\ua74d:"o",\u0275:"o",\u01a3:"oi",\u0223:"ou",\ua74f:"oo","\u24df":"p",\uff50:"p",\u1e55:"p",\u1e57:"p",\u01a5:"p",\u1d7d:"p",\ua751:"p",\ua753:"p",\ua755:"p","\u24e0":"q",\uff51:"q",\u024b:"q",\ua757:"q",\ua759:"q","\u24e1":"r",\uff52:"r",\u0155:"r",\u1e59:"r",\u0159:"r",\u0211:"r",\u0213:"r",\u1e5b:"r",\u1e5d:"r",\u0157:"r",\u1e5f:"r",\u024d:"r",\u027d:"r",\ua75b:"r",\ua7a7:"r",\ua783:"r","\u24e2":"s",\uff53:"s",\u00df:"s",\u015b:"s",\u1e65:"s",\u015d:"s",\u1e61:"s",\u0161:"s",\u1e67:"s",\u1e63:"s",\u1e69:"s",\u0219:"s",\u015f:"s",\u023f:"s",\ua7a9:"s",\ua785:"s",\u1e9b:"s","\u24e3":"t",\uff54:"t",\u1e6b:"t",\u1e97:"t",\u0165:"t",\u1e6d:"t",\u021b:"t",\u0163:"t",\u1e71:"t",\u1e6f:"t",\u0167:"t",\u01ad:"t",\u0288:"t",\u2c66:"t",\ua787:"t",\ua729:"tz","\u24e4":"u",\uff55:"u",\u00f9:"u",\u00fa:"u",\u00fb:"u",\u0169:"u",\u1e79:"u",\u016b:"u",\u1e7b:"u",\u016d:"u",\u00fc:"u",\u01dc:"u",\u01d8:"u",\u01d6:"u",\u01da:"u",\u1ee7:"u",\u016f:"u",\u0171:"u",\u01d4:"u",\u0215:"u",\u0217:"u",\u01b0:"u",\u1eeb:"u",\u1ee9:"u",\u1eef:"u",\u1eed:"u",\u1ef1:"u",\u1ee5:"u",\u1e73:"u",\u0173:"u",\u1e77:"u",\u1e75:"u",\u0289:"u","\u24e5":"v",\uff56:"v",\u1e7d:"v",\u1e7f:"v",\u028b:"v",\ua75f:"v",\u028c:"v",\ua761:"vy","\u24e6":"w",\uff57:"w",\u1e81:"w",\u1e83:"w",\u0175:"w",\u1e87:"w",\u1e85:"w",\u1e98:"w",\u1e89:"w",\u2c73:"w","\u24e7":"x",\uff58:"x",\u1e8b:"x",\u1e8d:"x","\u24e8":"y",\uff59:"y",\u1ef3:"y",\u00fd:"y",\u0177:"y",\u1ef9:"y",\u0233:"y",\u1e8f:"y",\u00ff:"y",\u1ef7:"y",\u1e99:"y",\u1ef5:"y",\u01b4:"y",\u024f:"y",\u1eff:"y","\u24e9":"z",\uff5a:"z",\u017a:"z",\u1e91:"z",\u017c:"z",\u017e:"z",\u1e93:"z",\u1e95:"z",\u01b6:"z",\u0225:"z",\u0240:"z",\u2c6c:"z",\ua763:"z",\u0386:"\u0391",\u0388:"\u0395",\u0389:"\u0397",\u038a:"\u0399",\u03aa:"\u0399",\u038c:"\u039f",\u038e:"\u03a5",\u03ab:"\u03a5",\u038f:"\u03a9",\u03ac:"\u03b1",\u03ad:"\u03b5",\u03ae:"\u03b7",\u03af:"\u03b9",\u03ca:"\u03b9",\u0390:"\u03b9",\u03cc:"\u03bf",\u03cd:"\u03c5",\u03cb:"\u03c5",\u03b0:"\u03c5",\u03c9:"\u03c9",\u03c2:"\u03c3"},n.fnOperators={equal:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?n.toLowerCase(t)===n.toLowerCase(e):t===e},notequal:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),!n.fnOperators.equal(t,e,i)},lessthan:function(t,e,i){return i?n.toLowerCase(t)n.toLowerCase(e):t>e},lessthanorequal:function(t,e,i){return i?n.toLowerCase(t)<=n.toLowerCase(e):(m(t)&&(t=void 0),t<=e)},greaterthanorequal:function(t,e,i){return i?n.toLowerCase(t)>=n.toLowerCase(e):t>=e},contains:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?!m(t)&&!m(e)&&-1!==n.toLowerCase(t).indexOf(n.toLowerCase(e)):!m(t)&&!m(e)&&-1!==t.toString().indexOf(e)},doesnotcontain:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?!m(t)&&!m(e)&&-1===n.toLowerCase(t).indexOf(n.toLowerCase(e)):!m(t)&&!m(e)&&-1===t.toString().indexOf(e)},isnotnull:function(t){return null!=t},isnull:function(t){return null==t},startswith:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.startsWith(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.startsWith(t,e)},doesnotstartwith:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.notStartsWith(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.notStartsWith(t,e)},like:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.like(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.like(t,e)},isempty:function(t){return void 0===t||""===t},isnotempty:function(t){return void 0!==t&&""!==t},wildcard:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?(t||"boolean"==typeof t)&&e&&"object"!=typeof t&&n.wildCard(n.toLowerCase(t),n.toLowerCase(e)):(t||"boolean"==typeof t)&&e&&n.wildCard(t,e)},endswith:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.endsWith(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.endsWith(t,e)},doesnotendwith:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.notEndsWith(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.notEndsWith(t,e)},processSymbols:function(t){var e=n.operatorSymbols[t];return e?n.fnOperators[e]:n.throwError("Query - Process Operator : Invalid operator")},processOperator:function(t){return n.fnOperators[t]||n.fnOperators.processSymbols(t)}},n.parse={parseJson:function(t){return"string"!=typeof t||!/^[\s]*\[|^[\s]*\{(.)+:/g.test(t)&&-1!==t.indexOf('"')?t instanceof Array?n.parse.iterateAndReviveArray(t):"object"==typeof t&&null!==t&&n.parse.iterateAndReviveJson(t):t=JSON.parse(t,n.parse.jsonReviver),t},iterateAndReviveArray:function(t){for(var e=0;e-1||e.indexOf("z")>-1,o=e.split(/[^0-9.]/);if(s){if(o[5].indexOf(".")>-1){var a=o[5].split(".");o[5]=a[0],o[6]=new Date(e).getUTCMilliseconds().toString()}else o[6]="00";e=n.dateParse.toTimeZone(new Date(parseInt(o[0],10),parseInt(o[1],10)-1,parseInt(o[2],10),parseInt(o[3],10),parseInt(o[4],10),parseInt(o[5]?o[5]:"00",10),parseInt(o[6],10)),n.serverTimezoneOffset,!1)}else{var l=new Date(parseInt(o[0],10),parseInt(o[1],10)-1,parseInt(o[2],10),parseInt(o[3],10),parseInt(o[4],10),parseInt(o[5]?o[5]:"00",10)),h=parseInt(o[6],10),c=parseInt(o[7],10);if(isNaN(h)&&isNaN(c))return l;e.indexOf("+")>-1?l.setHours(l.getHours()-h,l.getMinutes()-c):l.setHours(l.getHours()+h,l.getMinutes()+c),e=n.dateParse.toTimeZone(l,n.serverTimezoneOffset,!1)}null==n.serverTimezoneOffset&&(e=n.dateParse.addSelfOffset(e))}}return e},isJson:function(t){return"string"==typeof t[0]?t:n.parse.parseJson(t)},isGuid:function(t){return null!=/[A-Fa-f0-9]{8}(?:-[A-Fa-f0-9]{4}){3}-[A-Fa-f0-9]{12}/i.exec(t)},replacer:function(t,e){return n.isPlainObject(t)?n.parse.jsonReplacer(t,e):t instanceof Array?n.parse.arrayReplacer(t):t instanceof Date?n.parse.jsonReplacer({val:t},e).val:t},jsonReplacer:function(t,e){for(var i,s=0,o=Object.keys(t);s=0?"+":"-",s=function(a){var l=Math.floor(Math.abs(a));return(l<10?"0":"")+l};return e.getFullYear()+"-"+s(e.getMonth()+1)+"-"+s(e.getDate())+"T"+s(e.getHours())+":"+s(e.getMinutes())+":"+s(e.getSeconds())+r+s(i/60)+":"+s(i%60)}},n}(),Ml=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),AK={GroupGuid:"{271bbba0-1ee7}"},t5=function(){function n(t){this.options={from:"table",requestType:"json",sortBy:"sorted",select:"select",skip:"skip",group:"group",take:"take",search:"search",count:"requiresCounts",where:"where",aggregates:"aggregates",expand:"expand"},this.type=n,this.dataSource=t,this.pvt={}}return n.prototype.processResponse=function(t,e,i,r){return t},n}(),QE=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ml(t,n),t.prototype.processQuery=function(e,i){for(var a,l,f,r=e.dataSource.json.slice(0),s=r.length,o=!0,h={},c=0,d=[],u=[],p=0;p1?e.sort.filter(function(f){return f.fieldName===c})[0]:e.sort[0];s=this.onSortBy(s,d,e.query,!0)}e.page&&(s=this.onPage(s,e.page,e.query)),this.formGroupResult(s,h)}else{for(var o=e.lazyLoad.onDemandGroupInfo,a=o.where.length-1;a>=0;a--)s=this.onWhere(s,o.where[a]);if(e.group.length!==o.level)s=le.group(s,e.group[o.level].fieldName,r,null,null,e.group[o.level].comparer,!0),e.sort.length&&(s=this.onSortBy(s,e.sort[parseInt(o.level.toString(),10)],e.query,!0));else for(a=e.sort.length-1;a>=o.level;a--)s=this.onSortBy(s,e.sort[parseInt(a.toString(),10)],e.query,!1);i=s.length,h=s,s=(s=s.slice(o.skip)).slice(0,o.take),e.group.length!==o.level&&this.formGroupResult(s,h)}return{result:s,count:i}},t.prototype.formGroupResult=function(e,i){if(e.length&&i.length){var r="GroupGuid",s="childLevels",o="level",a="records";e[r]=i[r],e[s]=i[s],e[o]=i[o],e[a]=i[a]}return e},t.prototype.getAggregate=function(e){var i=_t.filterQueries(e.queries,"onAggregates"),r=[];if(i.length)for(var s=void 0,o=0;o=0;l--)a[l]&&(o=i.comparer,le.endsWith(a[l]," desc")&&(o=le.fnSort("descending"),a[l]=a[l].replace(" desc","")),e=le.sort(e,a[l],o));return e}return le.sort(e,s?"key":a,i.comparer)},t.prototype.onGroup=function(e,i,r){if(!e||!e.length)return e;var s=this.getAggregate(r);return le.group(e,le.getValue(i.fieldName,r),s,null,null,i.comparer)},t.prototype.onPage=function(e,i,r){var s=le.getValue(i.pageSize,r),o=(le.getValue(i.pageIndex,r)-1)*s;return e&&e.length?e.slice(o,o+s):e},t.prototype.onRange=function(e,i){return e&&e.length?e.slice(le.getValue(i.start),le.getValue(i.end)):e},t.prototype.onTake=function(e,i){return e&&e.length?e.slice(0,le.getValue(i.nos)):e},t.prototype.onSkip=function(e,i){return e&&e.length?e.slice(le.getValue(i.nos)):e},t.prototype.onSelect=function(e,i){return e&&e.length?le.select(e,le.getValue(i.fieldNames)):e},t.prototype.insert=function(e,i,r,s,o){return m(o)?e.dataSource.json.push(i):e.dataSource.json.splice(o,0,i)},t.prototype.remove=function(e,i,r,s){var a,o=e.dataSource.json;for("object"==typeof r&&!(r instanceof Date)&&(r=le.getObject(i,r)),a=0;a1&&(g="("+g+")"),f.filters.push(g);for(var y=0,S="object"==typeof f.filters[p]?Object.keys(f.filters[p]):[];y-1&&this.formRemoteGroupedData(e[s].items,i+1,r-1);var o="GroupGuid",h="records";return e[o]=AK[o],e.level=i,e.childLevels=r,e[h]=e[0].items.length?this.getGroupedRecords(e,!m(e[0].items[h])):[],e},t.prototype.getGroupedRecords=function(e,i){for(var r=[],o=0;ol.length-3?(l=l.substring(0,l.length-1),o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.endswith:le.odv4UniOperator.endswith):l.lastIndexOf("%")!==l.indexOf("%")&&l.lastIndexOf("%")>l.indexOf("%")+1?(l=l.substring(l.indexOf("%")+1,l.lastIndexOf("%")),o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains):o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains),l="'"+(l=encodeURIComponent(l))+"'";else if("wildcard"===o)if(-1!==l.indexOf("*")){var d=l.split("*"),u=void 0,f=0;if(0!==l.indexOf("*")&&-1===d[0].indexOf("%3f")&&-1===d[0].indexOf("?")&&(u="'"+(u=d[0])+"'",s+=(o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.startswith:le.odv4UniOperator.startswith)+"(",s+=c+",",a&&(s+=a),s+=u+")",f++),l.lastIndexOf("*")!==l.length-1&&-1===d[d.length-1].indexOf("%3f")&&-1===d[d.length-1].indexOf("?")&&(u="'"+(u=d[d.length-1])+"'",f>0&&(s+=" and "),s+=(o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.endswith:le.odv4UniOperator.endswith)+"(",s+=c+",",a&&(s+=a),s+=u+")",f++),d.length>2)for(var p=1;p0&&(s+=" and "),"substringof"===(o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains)||"not substringof"===o){var g=u;u=c,c=g}s+=o+"(",s+=c+",",a&&(s+=a),s+=u+")",f++}0===f?(o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains,(-1!==l.indexOf("?")||-1!==l.indexOf("%3f"))&&(l=-1!==l.indexOf("?")?l.split("?").join(""):l.split("%3f").join("")),l="'"+l+"'"):o="wildcard"}else o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains,(-1!==l.indexOf("?")||-1!==l.indexOf("%3f"))&&(l=-1!==l.indexOf("?")?l.split("?").join(""):l.split("%3f").join("")),l="'"+l+"'";return"substringof"!==o&&"not substringof"!==o||(g=l,l=c,c=g),"wildcard"!==o&&(s+=o+"(",s+=c+",",a&&(s+=a),s+=l+")"),s},t.prototype.addParams=function(e){n.prototype.addParams.call(this,e),delete e.reqParams.params},t.prototype.onComplexPredicate=function(e,i,r){for(var s=[],o=0;o-1;f--)!/\bContent-ID:/i.test(c[f])||!/\bHTTP.+201/.test(c[f])||(l=parseInt(/\bContent-ID: (\d+)/i.exec(c[f])[1],10),o.addedRecords[l]&&(h=le.parse.parseJson(/^\{.+\}/m.exec(c[f])[0]),ze({},o.addedRecords[l],this.processResponse(h))));return o}return null},t.prototype.compareAndRemove=function(e,i,r){var s=this;return m(i)||Object.keys(e).forEach(function(o){o!==r&&"@odata.etag"!==o&&(le.isPlainObject(e[o])?(s.compareAndRemove(e[o],i[o]),0===Object.keys(e[o]).filter(function(l){return"@odata.etag"!==l}).length&&delete e[o]):(e[o]===i[o]||e[o]&&i[o]&&e[o].valueOf()===i[o].valueOf())&&delete e[o])}),e},t}(fc),LK=function(n){function t(){var e=n.call(this)||this;return yt("beforeSend",fc.prototype.beforeSend,e),e}return Ml(t,n),t.prototype.insert=function(e,i,r,s,o){return this.pvt.position=o,this.updateType="add",{url:e.dataSource.insertUrl||e.dataSource.crudUrl||e.dataSource.url,data:JSON.stringify(ze({},{value:i,table:r,action:"insert"},le.getAddParams(this,e,s)))}},t.prototype.remove=function(e,i,r,s,o){return n.prototype.remove.call(this,e,i,r),{type:"POST",url:e.dataSource.removeUrl||e.dataSource.crudUrl||e.dataSource.url,data:JSON.stringify(ze({},{key:r,keyColumn:i,table:s,action:"remove"},le.getAddParams(this,e,o)))}},t.prototype.update=function(e,i,r,s,o){return this.updateType="update",this.updateKey=i,{type:"POST",url:e.dataSource.updateUrl||e.dataSource.crudUrl||e.dataSource.url,data:JSON.stringify(ze({},{value:r,action:"update",keyColumn:i,key:r[i],table:s},le.getAddParams(this,e,o)))}},t.prototype.processResponse=function(e,i,r,s,o,a,l){var h;if(e="batch"===(o?JSON.parse(o.data):e).action?le.parse.parseJson(e):e,"add"===this.updateType&&n.prototype.insert.call(this,i,e,null,null,this.pvt.position),"update"===this.updateType&&n.prototype.update.call(this,i,this.updateKey,e),this.updateType=void 0,e.added)for(h=0;hi&&h.push(c)}for(c=0;cthis.pageSize;)h.results.splice(0,1),h.keys.splice(0,1);return window.localStorage.setItem(this.guidId,JSON.stringify(h)),e},t.prototype.beforeSend=function(e,i,r){!m(this.cacheAdaptor.options.batch)&&le.endsWith(r.url,this.cacheAdaptor.options.batch)&&"post"===r.type.toLowerCase()&&i.headers.set("Accept",this.cacheAdaptor.options.multipartAccept),e.dataSource.crossDomain||i.headers.set("Accept",this.cacheAdaptor.options.accept)},t.prototype.update=function(e,i,r,s){return this.isCrudAction=!0,this.cacheAdaptor.update(e,i,r,s)},t.prototype.insert=function(e,i,r){return this.isInsertAction=!0,this.cacheAdaptor.insert(e,i,r)},t.prototype.remove=function(e,i,r,s){return this.isCrudAction=!0,this.cacheAdaptor.remove(e,i,r,s)},t.prototype.batchRequest=function(e,i,r){return this.cacheAdaptor.batchRequest(e,i,r)},t}(fc),it=function(){function n(t,e,i){var s,r=this;return this.dateParse=!0,this.timeZoneHandling=!0,this.persistQuery={},this.isInitialLoad=!1,this.requests=[],this.isInitialLoad=!0,!t&&!this.dataSource&&(t=[]),i=i||t.adaptor,t&&!1===t.timeZoneHandling&&(this.timeZoneHandling=t.timeZoneHandling),t instanceof Array?s={json:t,offline:!0}:"object"==typeof t?(t.json||(t.json=[]),t.enablePersistence||(t.enablePersistence=!1),t.id||(t.id=""),t.ignoreOnPersist||(t.ignoreOnPersist=[]),s={url:t.url,insertUrl:t.insertUrl,removeUrl:t.removeUrl,updateUrl:t.updateUrl,crudUrl:t.crudUrl,batchUrl:t.batchUrl,json:t.json,headers:t.headers,accept:t.accept,data:t.data,timeTillExpiration:t.timeTillExpiration,cachingPageSize:t.cachingPageSize,enableCaching:t.enableCaching,requestType:t.requestType,key:t.key,crossDomain:t.crossDomain,jsonp:t.jsonp,dataType:t.dataType,offline:void 0!==t.offline?t.offline:!(t.adaptor instanceof LK||t.adaptor instanceof NK||t.url),requiresFormat:t.requiresFormat,enablePersistence:t.enablePersistence,id:t.id,ignoreOnPersist:t.ignoreOnPersist}):le.throwError("DataManager: Invalid arguments"),void 0===s.requiresFormat&&!le.isCors()&&(s.requiresFormat=!!m(s.crossDomain)||s.crossDomain),void 0===s.dataType&&(s.dataType="json"),this.dataSource=s,this.defaultQuery=e,this.dataSource.enablePersistence&&this.dataSource.id&&window.addEventListener("unload",this.setPersistData.bind(this)),s.url&&s.offline&&!s.json.length?(this.isDataAvailable=!1,this.adaptor=i||new vf,this.dataSource.offline=!1,this.ready=this.executeQuery(e||new _t),this.ready.then(function(o){r.dataSource.offline=!0,r.isDataAvailable=!0,s.json=o.result,r.adaptor=new QE})):this.adaptor=s.offline?new QE:new vf,!s.jsonp&&this.adaptor instanceof vf&&(s.jsonp="callback"),this.adaptor=i||this.adaptor,s.enableCaching&&(this.adaptor=new OK(this.adaptor,s.timeTillExpiration,s.cachingPageSize)),this}return Object.defineProperty(n.prototype,"moduleName",{get:function(){return"datamanager"},enumerable:!0,configurable:!0}),n.prototype.getPersistedData=function(t){var e=localStorage.getItem(t||this.dataSource.id);return JSON.parse(e)},n.prototype.setPersistData=function(t,e,i){localStorage.setItem(e||this.dataSource.id,JSON.stringify(i||this.persistQuery))},n.prototype.setPersistQuery=function(t){var e=this,i=this.getPersistedData();if(this.isInitialLoad&&i&&Object.keys(i).length){this.persistQuery=i,this.persistQuery.queries=this.persistQuery.queries.filter(function(s){if(e.dataSource.ignoreOnPersist&&e.dataSource.ignoreOnPersist.length&&s.fn&&e.dataSource.ignoreOnPersist.some(function(l){return s.fn===l}))return!1;if("onWhere"===s.fn){var o=s.e;if(o&&o.isComplex&&o.predicates instanceof Array){var a=o.predicates.map(function(l){if(l.predicates&&l.predicates instanceof Array){var h=l.predicates.map(function(v){return new Ss(v.field,v.operator,v.value,v.ignoreCase,v.ignoreAccent,v.matchCase)});return"and"===l.condition?Ss.and(h):Ss.or(h)}return new Ss(l.field,l.operator,l.value,l.ignoreCase,l.ignoreAccent,l.matchCase)});s.e=new Ss(a[0],o.condition,a.slice(1))}}return!0});var r=ze(new _t,this.persistQuery);return this.isInitialLoad=!1,r}return this.persistQuery=t,this.isInitialLoad=!1,t},n.prototype.setDefaultQuery=function(t){return this.defaultQuery=t,this},n.prototype.executeLocal=function(t){!this.defaultQuery&&!(t instanceof _t)&&le.throwError("DataManager - executeLocal() : A query is required to execute"),this.dataSource.json||le.throwError("DataManager - executeLocal() : Json data is required to execute"),this.dataSource.enablePersistence&&this.dataSource.id&&(t=this.setPersistQuery(t));var e=this.adaptor.processQuery(this,t=t||this.defaultQuery);if(t.subQuery){var i=t.subQuery.fromTable,r=t.subQuery.lookups,s=t.isCountRequired?e.result:e;r&&r instanceof Array&&le.buildHierarchy(t.subQuery.fKey,i,s,r,t.subQuery.key);for(var o=0;oli");z.classList.remove("json-parent");for(var j=0;j',W=ve.children[0].placeholder}return W}function Q(k,W,ve){!m(ve)&&""!==ve&&K(W,ve.split(" ")),!m(k)&&""!==k&&V(W,k.split(" "))}function oe(k,W,ve){if("multiselect"===ve||function Mo(k){if(!k)return!1;for(var W=k;W&&W!==document.body;){if("none"===window.getComputedStyle(W).display)return!1;W=W.parentElement}return!0}(k)){var Te="multiselect"===ve?k:k.clientWidth-parseInt(getComputedStyle(k,null).getPropertyValue("padding-left"),10);!m(W)&&!m(W.getElementsByClassName("e-float-text-content")[0])&&(W.getElementsByClassName("e-float-text-content")[0].classList.contains("e-float-text-overflow")&&W.getElementsByClassName("e-float-text-content")[0].classList.remove("e-float-text-overflow"),(Te0)for(var Ye=0;Ye<_e.length;Ye++)_e[parseInt(Ye.toString(),10)].addEventListener("mousedown",wo,!1),_e[parseInt(Ye.toString(),10)].addEventListener("mouseup",Ul,!1);else if(_e.length>0)for(Ye=0;Ye<_e.length;Ye++)_e[parseInt(Ye.toString(),10)].removeEventListener("mousedown",wo,this),_e[parseInt(Ye.toString(),10)].removeEventListener("mouseup",Ul,this)}function wo(){for(var W=this.parentElement;!W.classList.contains("e-input-group");)W=W.parentElement;!function Sa(k,W){!k.classList.contains("e-disabled")&&!k.querySelector("input").readOnly&&W.classList.add("e-input-btn-ripple")}(W,this)}function Ul(){var k=this;setTimeout(function(){k.classList.remove("e-input-btn-ripple")},500)}function yb(k,W){var ve=W("span",{className:k});return ve.classList.add("e-input-group-icon"),ve}function I_(k,W,ve,Te){var _e=m(Te)?Si:Te,Ye=yb(k,_e);W.classList.add("e-float-icon-left");var vi=W.querySelector(".e-input-in-wrap");if(m(vi)){vi=_e("span",{className:"e-input-in-wrap"}),ve.parentNode.insertBefore(vi,ve);var Gs=W.querySelectorAll(ve.tagName+" ~ *");vi.appendChild(ve);for(var ts=0;ts-1)if("class"===_e){var Ye=this.getInputValidClassList(k[""+_e]);""!==Ye&&V([W],Ye.split(" "))}else if("style"===_e){var vi=W.getAttribute(_e);vi=m(vi)?k[""+_e]:vi+k[""+_e],W.setAttribute(_e,vi)}else W.setAttribute(_e,k[""+_e])}},n.isBlank=function Hle(k){return!k||/^\s*$/.test(k)}}(Le||(Le={})),new RegExp("^(-)?(\\d*)$"),new RegExp("^[A-Za-z0-9._%+-]{1,}@[A-Za-z0-9._%+-]{1,}([.]{1}[a-zA-Z0-9]{2,}|[.]{1}[a-zA-Z0-9]{2,4}[.]{1}[a-zA-Z0-9]{2,4})$"),new RegExp("^([0-9]{4})-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])$"),new RegExp("^[0-9]*$"),new RegExp("^[+]?[0-9]{9,13}$"),new RegExp("^\\d{13,16}$");var me=function(){function n(t,e){this.width=t,this.height=e}return n.prototype.isEmpty=function(){return 0===this.height&&0===this.width},n.prototype.clone=function(){return new n(this.width,this.height)},n}(),xie=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),GB=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},R=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return xie(t,n),t.equals=function(e,i){return e===i||!(!e||!i)&&(!e||!i||e.x===i.x&&e.y===i.y)},t.isEmptyPoint=function(e){return!(e.x&&e.y)},t.transform=function(e,i,r){var s={x:0,y:0};return s.x=Math.round(100*(e.x+r*Math.cos(i*Math.PI/180)))/100,s.y=Math.round(100*(e.y+r*Math.sin(i*Math.PI/180)))/100,s},t.findLength=function(e,i){return Math.sqrt(Math.pow(e.x-i.x,2)+Math.pow(e.y-i.y,2))},t.findAngle=function(e,i){var r=Math.atan2(i.y-e.y,i.x-e.x);return r=180*r/Math.PI,(r%=360)<0&&(r+=360),r},t.distancePoints=function(e,i){return Math.sqrt(Math.pow(i.x-e.x,2)+Math.pow(i.y-e.y,2))},t.getLengthFromListOfPoints=function(e){for(var i=0,r=0;ri.y&&!r?o.y+=s:o.y-=s:e.y===i.y?e.xi.x&&!r?o.x+=s:o.x-=s:r?(a=this.findAngle(e,i),o=this.transform(e,a,s)):(a=this.findAngle(i,e),o=this.transform(i,a,s)),o},t.direction=function(e,i){return Math.abs(i.x-e.x)>Math.abs(i.y-e.y)?e.x0)for(var r=0;rt.right||this.top>t.bottom||this.bottom=t.right&&this.top<=t.top&&this.bottom>=t.bottom},n.prototype.containsPoint=function(t,e){return void 0===e&&(e=0),this.left-e<=t.x&&this.right+e>=t.x&&this.top-e<=t.y&&this.bottom+e>=t.y},n.toBounds=function(t){for(var e=new n,i=0,r=t;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},KB=function(n){if(n)switch(n.type){case"Linear":default:return bI;case"Radial":return Bie}return bI},Rie=function(){return function n(t,e,i,r){this.left=t,this.right=e,this.top=i,this.bottom=r}}(),Jn=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),rt([I(0)],t.prototype,"left",void 0),rt([I(0)],t.prototype,"right",void 0),rt([I(0)],t.prototype,"top",void 0),rt([I(0)],t.prototype,"bottom",void 0),t}(Ee),Hie=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),rt([I(45)],t.prototype,"angle",void 0),rt([I(5)],t.prototype,"distance",void 0),rt([I(.7)],t.prototype,"opacity",void 0),rt([I("lightgrey")],t.prototype,"color",void 0),t}(Ee),e3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),t.prototype.getClassName=function(){return"Stop"},rt([I("")],t.prototype,"color",void 0),rt([I(0)],t.prototype,"offset",void 0),rt([I(1)],t.prototype,"opacity",void 0),t}(Ee),Mx=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),rt([Bt([],e3)],t.prototype,"stops",void 0),rt([I("None")],t.prototype,"type",void 0),rt([I("")],t.prototype,"id",void 0),t}(Ee),bI=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),rt([I(0)],t.prototype,"x1",void 0),rt([I(0)],t.prototype,"x2",void 0),rt([I(0)],t.prototype,"y1",void 0),rt([I(0)],t.prototype,"y2",void 0),t}(Mx),Bie=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),rt([I(0)],t.prototype,"cx",void 0),rt([I(0)],t.prototype,"cy",void 0),rt([I(0)],t.prototype,"fx",void 0),rt([I(0)],t.prototype,"fy",void 0),rt([I(50)],t.prototype,"r",void 0),t}(Mx),Ll=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),rt([I("white")],t.prototype,"fill",void 0),rt([I("black")],t.prototype,"strokeColor",void 0),rt([I("")],t.prototype,"strokeDashArray",void 0),rt([I(1)],t.prototype,"strokeWidth",void 0),rt([I(1)],t.prototype,"opacity",void 0),rt([T0(KB)],t.prototype,"gradient",void 0),t}(Ee),t3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),rt([I("transparent")],t.prototype,"fill",void 0),t}(Ll),Xf=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),rt([I("black")],t.prototype,"color",void 0),rt([I("Arial")],t.prototype,"fontFamily",void 0),rt([I(12)],t.prototype,"fontSize",void 0),rt([I(!1)],t.prototype,"italic",void 0),rt([I(!1)],t.prototype,"bold",void 0),rt([I("CollapseSpace")],t.prototype,"whiteSpace",void 0),rt([I("WrapWithOverflow")],t.prototype,"textWrapping",void 0),rt([I("Center")],t.prototype,"textAlign",void 0),rt([I("None")],t.prototype,"textDecoration",void 0),rt([I("Wrap")],t.prototype,"textOverflow",void 0),rt([I("transparent")],t.prototype,"fill",void 0),t}(Ll),on=function(n){return n[n.Default=0]="Default",n[n.expandNode=2]="expandNode",n[n.interaction=4]="interaction",n[n.GroupingInProgress=8]="GroupingInProgress",n[n.GroupClipboardInProcess=16]="GroupClipboardInProcess",n[n.ClearObject=32]="ClearObject",n}(on||{}),Gt=function(n){return n[n.Visible=1]="Visible",n[n.Hidden=2]="Hidden",n[n.Hover=4]="Hover",n[n.Connect=8]="Connect",n}(Gt||{}),ei=function(n){return n[n.None=0]="None",n[n.ShowHorizontalLines=1]="ShowHorizontalLines",n[n.ShowVerticalLines=2]="ShowVerticalLines",n[n.ShowLines=3]="ShowLines",n[n.SnapToHorizontalLines=4]="SnapToHorizontalLines",n[n.SnapToVerticalLines=8]="SnapToVerticalLines",n[n.SnapToLines=12]="SnapToLines",n[n.SnapToObject=16]="SnapToObject",n[n.All=31]="All",n}(ei||{}),mr=function(n){return n[n.None=1]="None",n[n.ConnectorSourceThumb=2]="ConnectorSourceThumb",n[n.ConnectorTargetThumb=4]="ConnectorTargetThumb",n[n.ResizeSouthEast=8]="ResizeSouthEast",n[n.ResizeSouthWest=16]="ResizeSouthWest",n[n.ResizeNorthEast=32]="ResizeNorthEast",n[n.ResizeNorthWest=64]="ResizeNorthWest",n[n.ResizeEast=128]="ResizeEast",n[n.ResizeWest=256]="ResizeWest",n[n.ResizeSouth=512]="ResizeSouth",n[n.ResizeNorth=1024]="ResizeNorth",n[n.Rotate=2048]="Rotate",n[n.UserHandle=4096]="UserHandle",n[n.ToolTip=8192]="ToolTip",n[n.ResizeAll=2046]="ResizeAll",n[n.All=16382]="All",n}(mr||{}),qe=function(n){return n[n.None=1]="None",n[n.Select=2]="Select",n[n.Delete=4]="Delete",n[n.Drag=8]="Drag",n[n.DragSourceEnd=16]="DragSourceEnd",n[n.DragTargetEnd=32]="DragTargetEnd",n[n.DragSegmentThumb=64]="DragSegmentThumb",n[n.AllowDrop=128]="AllowDrop",n[n.Bridging=256]="Bridging",n[n.BridgeObstacle=512]="BridgeObstacle",n[n.InheritBridging=1024]="InheritBridging",n[n.PointerEvents=2048]="PointerEvents",n[n.Tooltip=4096]="Tooltip",n[n.InheritTooltip=8192]="InheritTooltip",n[n.Interaction=4218]="Interaction",n[n.ReadOnly=16384]="ReadOnly",n[n.LineRouting=32768]="LineRouting",n[n.InheritLineRouting=65536]="InheritLineRouting",n[n.ConnectToNearByNode=131072]="ConnectToNearByNode",n[n.ConnectToNearByPort=262144]="ConnectToNearByPort",n[n.ConnectToNearByElement=393216]="ConnectToNearByElement",n[n.InheritSegmentThumbShape=524288]="InheritSegmentThumbShape",n[n.InheritSegmentThumbSize=1048576]="InheritSegmentThumbSize",n[n.Default=2043454]="Default",n}(qe||{}),Nr=function(n){return n[n.ReadOnly=2]="ReadOnly",n[n.InheritReadOnly=4]="InheritReadOnly",n[n.Select=8]="Select",n[n.Drag=16]="Drag",n[n.Resize=32]="Resize",n[n.Rotate=64]="Rotate",n[n.Tooltip=128]="Tooltip",n[n.Interaction=120]="Interaction",n[n.None=0]="None",n}(Nr||{}),ie=function(n){return n[n.None=0]="None",n[n.Select=2]="Select",n[n.Drag=4]="Drag",n[n.Rotate=8]="Rotate",n[n.Shadow=16]="Shadow",n[n.PointerEvents=32]="PointerEvents",n[n.Delete=64]="Delete",n[n.InConnect=128]="InConnect",n[n.OutConnect=256]="OutConnect",n[n.Individual=512]="Individual",n[n.Expandable=1024]="Expandable",n[n.AllowDrop=2048]="AllowDrop",n[n.Inherit=78]="Inherit",n[n.ResizeNorthEast=4096]="ResizeNorthEast",n[n.ResizeEast=8192]="ResizeEast",n[n.ResizeSouthEast=16384]="ResizeSouthEast",n[n.ResizeSouth=32768]="ResizeSouth",n[n.ResizeSouthWest=65536]="ResizeSouthWest",n[n.ResizeWest=131072]="ResizeWest",n[n.ResizeNorthWest=262144]="ResizeNorthWest",n[n.ResizeNorth=524288]="ResizeNorth",n[n.Resize=1044480]="Resize",n[n.AspectRatio=1048576]="AspectRatio",n[n.Tooltip=2097152]="Tooltip",n[n.InheritTooltip=4194304]="InheritTooltip",n[n.ReadOnly=8388608]="ReadOnly",n[n.HideThumbs=16777216]="HideThumbs",n[n.AllowMovingOutsideLane=33554432]="AllowMovingOutsideLane",n[n.Default=5240814]="Default",n}(ie||{}),Xr=function(n){return n[n.None=0]="None",n[n.ElementIsPort=2]="ElementIsPort",n[n.ElementIsGroup=4]="ElementIsGroup",n[n.HorizontalLaneHeader=8]="HorizontalLaneHeader",n}(Xr||{}),bt=function(n){return n[n.Rotate=2]="Rotate",n[n.ConnectorSource=4]="ConnectorSource",n[n.ConnectorTarget=8]="ConnectorTarget",n[n.ResizeNorthEast=16]="ResizeNorthEast",n[n.ResizeEast=32]="ResizeEast",n[n.ResizeSouthEast=64]="ResizeSouthEast",n[n.ResizeSouth=128]="ResizeSouth",n[n.ResizeSouthWest=256]="ResizeSouthWest",n[n.ResizeWest=512]="ResizeWest",n[n.ResizeNorthWest=1024]="ResizeNorthWest",n[n.ResizeNorth=2048]="ResizeNorth",n[n.Default=4094]="Default",n}(bt||{}),nt=function(n){return n[n.None=1]="None",n[n.Bridging=2]="Bridging",n[n.UndoRedo=4]="UndoRedo",n[n.Tooltip=8]="Tooltip",n[n.UserInteraction=16]="UserInteraction",n[n.ApiUpdate=32]="ApiUpdate",n[n.PageEditable=48]="PageEditable",n[n.Zoom=64]="Zoom",n[n.PanX=128]="PanX",n[n.PanY=256]="PanY",n[n.Pan=384]="Pan",n[n.ZoomTextEdit=512]="ZoomTextEdit",n[n.Virtualization=1024]="Virtualization",n[n.LineRouting=2048]="LineRouting",n[n.Default=500]="Default",n}(nt||{}),ni=function(n){return n[n.None=0]="None",n[n.SingleSelect=1]="SingleSelect",n[n.MultipleSelect=2]="MultipleSelect",n[n.ZoomPan=4]="ZoomPan",n[n.DrawOnce=8]="DrawOnce",n[n.ContinuousDraw=16]="ContinuousDraw",n[n.Default=3]="Default",n}(ni||{}),Qa=function(n){return n[n.Self=1]="Self",n[n.Parent=2]="Parent",n}(Qa||{}),ft=function(n){return n[n.None=0]="None",n[n.Control=1]="Control",n[n.Meta=1]="Meta",n[n.Alt=2]="Alt",n[n.Shift=4]="Shift",n}(ft||{}),Mt=function(n){return n[n.None=null]="None",n[n.Number0=0]="Number0",n[n.Number1=1]="Number1",n[n.Number2=2]="Number2",n[n.Number3=3]="Number3",n[n.Number4=4]="Number4",n[n.Number5=5]="Number5",n[n.Number6=6]="Number6",n[n.Number7=7]="Number7",n[n.Number8=8]="Number8",n[n.Number9=9]="Number9",n[n.A=65]="A",n[n.B=66]="B",n[n.C=67]="C",n[n.D=68]="D",n[n.E=69]="E",n[n.F=70]="F",n[n.G=71]="G",n[n.H=72]="H",n[n.I=73]="I",n[n.J=74]="J",n[n.K=75]="K",n[n.L=76]="L",n[n.M=77]="M",n[n.N=78]="N",n[n.O=79]="O",n[n.P=80]="P",n[n.Q=81]="Q",n[n.R=82]="R",n[n.S=83]="S",n[n.T=84]="T",n[n.U=85]="U",n[n.V=86]="V",n[n.W=87]="W",n[n.X=88]="X",n[n.Y=89]="Y",n[n.Z=90]="Z",n[n.Left=37]="Left",n[n.Up=38]="Up",n[n.Right=39]="Right",n[n.Down=40]="Down",n[n.Escape=27]="Escape",n[n.Space=32]="Space",n[n.PageUp=33]="PageUp",n[n.PageDown=34]="PageDown",n[n.End=35]="End",n[n.Home=36]="Home",n[n.Delete=46]="Delete",n[n.Tab=9]="Tab",n[n.Enter=13]="Enter",n[n.BackSpace=8]="BackSpace",n[n.F1=112]="F1",n[n.F2=113]="F2",n[n.F3=114]="F3",n[n.F4=115]="F4",n[n.F5=116]="F5",n[n.F6=117]="F6",n[n.F7=118]="F7",n[n.F8=119]="F8",n[n.F9=120]="F9",n[n.F10=121]="F10",n[n.F11=122]="F11",n[n.F12=123]="F12",n[n.Star=56]="Star",n[n.Plus=187]="Plus",n[n.Minus=189]="Minus",n[n.BracketLeft=219]="BracketLeft",n[n.BracketRight=221]="BracketRight",n}(Mt||{}),ee=function(n){return n[n.Render=2]="Render",n[n.PublicMethod=4]="PublicMethod",n[n.ToolAction=8]="ToolAction",n[n.UndoRedo=16]="UndoRedo",n[n.TextEdit=32]="TextEdit",n[n.Group=64]="Group",n[n.Clear=128]="Clear",n[n.PreventClearSelection=256]="PreventClearSelection",n[n.Interactions=512]="Interactions",n[n.PreventHistory=1024]="PreventHistory",n[n.PreventIconsUpdate=2048]="PreventIconsUpdate",n[n.PreventCollectionChangeOnDragOver=4096]="PreventCollectionChangeOnDragOver",n[n.PreventZIndexOnDragging=8192]="PreventZIndexOnDragging",n[n.isGroupDragging=16384]="isGroupDragging",n[n.DragUsingMouse=32768]="DragUsingMouse",n[n.DecoratorPropertyChange=65536]="DecoratorPropertyChange",n[n.PreventLaneContainerUpdate=131072]="PreventLaneContainerUpdate",n}(ee||{}),Ga=function(n){return n[n.None=2]="None",n[n.DrawSelectorBorder=4]="DrawSelectorBorder",n[n.PreventRenderSelector=8]="PreventRenderSelector",n}(Ga||{}),$i=function(n){return n[n.None=0]="None",n[n.PreventDrag=2]="PreventDrag",n[n.PreventScale=4]="PreventScale",n[n.PreventDataInit=8]="PreventDataInit",n[n.hScrollbarMoved=16]="hScrollbarMoved",n[n.vScrollbarMoved=32]="vScrollbarMoved",n[n.AnimationClick=64]="AnimationClick",n[n.EnableGroupAction=128]="EnableGroupAction",n[n.PanInProgress=256]="PanInProgress",n[n.OverViewAction=512]="OverViewAction",n}($i||{}),da=function(n){return n[n.None=0]="None",n[n.PropertyChange=1024]="PropertyChange",n[n.Interaction=2048]="Interaction",n}(da||{}),Ae=function(n){return n[n.Zero=0]="Zero",n[n.One=1]="One",n[n.Two=2]="Two",n[n.Three=3]="Three",n[n.Four=4]="Four",n[n.Five=5]="Five",n}(Ae||{}),Ce=function(n){return n[n.collectionChange=0]="collectionChange",n[n.rotateChange=1]="rotateChange",n[n.positionChange=2]="positionChange",n[n.propertyChange=3]="propertyChange",n[n.selectionChange=4]="selectionChange",n[n.sizeChange=5]="sizeChange",n[n.drop=6]="drop",n[n.sourcePointChange=7]="sourcePointChange",n[n.targetPointChange=8]="targetPointChange",n[n.connectionChange=9]="connectionChange",n[n.animationComplete=10]="animationComplete",n[n.click=11]="click",n[n.doubleClick=12]="doubleClick",n[n.scrollChange=13]="scrollChange",n[n.dragEnter=14]="dragEnter",n[n.dragLeave=15]="dragLeave",n[n.dragOver=16]="dragOver",n[n.textEdit=17]="textEdit",n[n.paletteSelectionChange=18]="paletteSelectionChange",n[n.historyChange=19]="historyChange",n[n.mouseEnter=20]="mouseEnter",n[n.mouseLeave=21]="mouseLeave",n[n.mouseOver=22]="mouseOver",n[n.expandStateChange=23]="expandStateChange",n[n.segmentCollectionChange=24]="segmentCollectionChange",n[n.commandExecute=25]="commandExecute",n[n.historyStateChange=26]="historyStateChange",n[n.onUserHandleMouseDown=27]="onUserHandleMouseDown",n[n.onUserHandleMouseUp=28]="onUserHandleMouseUp",n[n.onUserHandleMouseEnter=29]="onUserHandleMouseEnter",n[n.onUserHandleMouseLeave=30]="onUserHandleMouseLeave",n[n.onImageLoad=31]="onImageLoad",n[n.onDoBindingInit=32]="onDoBindingInit",n[n.keyUp=33]="keyUp",n[n.keyDown=34]="keyDown",n[n.fixedUserHandleClick=35]="fixedUserHandleClick",n[n.elementDraw=36]="elementDraw",n[n.mouseWheel=37]="mouseWheel",n[n.segmentChange=38]="segmentChange",n[n.onFixedUserHandleMouseDown=39]="onFixedUserHandleMouseDown",n[n.onFixedUserHandleMouseUp=40]="onFixedUserHandleMouseUp",n[n.onFixedUserHandleMouseEnter=41]="onFixedUserHandleMouseEnter",n[n.onFixedUserHandleMouseLeave=42]="onFixedUserHandleMouseLeave",n[n.loaded=43]="loaded",n}(Ce||{}),ai=function(n){return n[n.None=1]="None",n[n.Drag=2]="Drag",n[n.Draw=4]="Draw",n[n.InConnect=8]="InConnect",n[n.OutConnect=16]="OutConnect",n[n.ToolTip=32]="ToolTip",n[n.InheritTooltip=64]="InheritTooltip",n[n.Default=24]="Default",n}(ai||{}),wx=function(n){return n[n.None=1]="None",n[n.Source=2]="Source",n[n.Target=4]="Target",n[n.Intermediate=8]="Intermediate",n[n.All=14]="All",n}(wx||{}),MI=function(n){return n[n.None=0]="None",n[n.SymmetricAngle=2]="SymmetricAngle",n[n.SymmetricDistance=4]="SymmetricDistance",n[n.Default=6]="Default",n}(MI||{}),hs=function(){function n(){this.pivot={x:.5,y:.5},this.isDirt=!0,this.isExport=!1,this.exportScaleValue={x:0,y:0},this.exportScaleOffset={x:0,y:0},this.canApplyStyle=!0,this.visible=!0,this.offsetX=0,this.offsetY=0,this.cornerRadius=0,this.minHeight=void 0,this.minWidth=void 0,this.maxWidth=void 0,this.maxHeight=void 0,this.width=void 0,this.height=void 0,this.rotateAngle=0,this.margin={left:0,right:0,top:0,bottom:0},this.connectionDirection="Auto",this.horizontalAlignment="Auto",this.verticalAlignment="Auto",this.flip="None",this.flipMode="All",this.relativeMode="Point",this.transform=Qa.Self|Qa.Parent,this.style={fill:"white",strokeColor:"black",opacity:1,strokeWidth:1},this.desiredSize=new me,this.actualSize=new me,this.parentTransform=0,this.preventContainer=!1,this.isSvgRender=!1,this.bounds=new Ne(0,0,0,0),this.shadow=null,this.description="",this.staticSize=!1,this.shapeType="",this.isRectElement=!1,this.isCalculateDesiredSize=!0,this.flipOffset={x:0,y:0},this.elementActions=Xr.None,this.inversedAlignment=!0,this.position=void 0,this.unitMode=void 0,this.float=!1,this.floatingBounds=void 0}return n.prototype.setOffsetWithRespectToBounds=function(t,e,i){this.unitMode=i,this.position={x:t,y:e}},n.prototype.getAbsolutePosition=function(t){if(void 0!==this.position)return"Absolute"===this.unitMode?this.position:{x:this.position.x*t.width,y:this.position.y*t.height}},Object.defineProperty(n.prototype,"outerBounds",{get:function(){return this.floatingBounds||this.bounds},set:function(t){this.floatingBounds=t},enumerable:!0,configurable:!0}),n.prototype.measure=function(t,e,i){var s=void 0!==this.height?this.height:(t.height||0)-this.margin.top-this.margin.bottom;return this.id&&0===s&&this.elementActions&Xr.HorizontalLaneHeader&&(s=this.actualSize.height),this.desiredSize=new me(void 0!==this.width?this.width:(t.width||0)-this.margin.left-this.margin.right,s),this.isCalculateDesiredSize&&(this.desiredSize=this.validateDesiredSize(this.desiredSize,t)),this.desiredSize},n.prototype.arrange=function(t){return this.actualSize=t,this.updateBounds(),this.actualSize},n.prototype.updateBounds=function(){this.bounds=yr(this)},n.prototype.validateDesiredSize=function(t,e){return this.isRectElement&&!this.width&&!this.minWidth&&!this.maxWidth&&(t.width=50),this.isRectElement&&!this.height&&!this.minHeight&&!this.maxHeight&&(t.height=50),(void 0===t||void 0!==this.width&&void 0!==this.height)&&((t=t||new me).width=void 0===this.width?(e.width||0)-this.margin.left-this.margin.right:this.width,t.height=void 0===this.height?(e.height||0)-this.margin.top-this.margin.bottom:this.height),void 0!==this.minWidth&&(t.width=Math.max(t.width,this.minWidth)),void 0!==this.minHeight&&(t.height=Math.max(t.height,this.minHeight)),void 0!==this.maxWidth&&0!==this.maxWidth&&(t.width=Math.min(t.width,this.maxWidth)),void 0!==this.maxHeight&&0!==this.maxHeight&&(t.height=Math.min(t.height,this.maxHeight)),t},n}(),Yie=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Cs=function(n){function t(){var e=null!==n&&n.apply(this,arguments)||this;return e.padding=new Rie(0,0,0,0),e.desiredBounds=void 0,e.measureChildren=!0,e.prevRotateAngle=0,e}return Yie(t,n),t.prototype.hasChildren=function(){return void 0!==this.children&&this.children.length>0},t.prototype.measure=function(e,i,r){this.desiredBounds=void 0;var o,a,s=void 0;if(this.hasChildren()){for(var l=0;l=n.width&&s.length>0)i[i.length]={text:s,x:0,dy:0,width:o},s="";else{(s+=a[r+1]||"").indexOf("\n")>-1&&(i[i.length]={text:s,x:0,dy:0,width:Bc(s,n)},s="");var l=Bc(s,n);Math.ceil(l)+2>=n.width&&s.length>0&&(i[i.length]={text:s,x:0,dy:0,width:l},s=""),r===a.length-1&&s.length>0&&(i[i.length]={text:s,x:0,dy:0,width:l},s="")}else i=function coe(n,t,e){var c,d,u,f,i=[],r="",s=0,o=0,a="nowrap"!==n.whiteSpace,h=(t||n.content).split("\n");for(s=0;s0?" ":"")+c[parseInt(o.toString(),10)];var p=Bc(d=c[o+1]?r+" "+c[o+1]:r,n);Math.floor(p)>(e||n.width)-2&&r.length>0?(i[i.length]={text:r,x:0,dy:0,width:d===r?p:r===f?u:Bc(r,n)},r=""):o===c.length-1&&(i[i.length]={text:r,x:0,dy:0,width:p},r=""),f=d,u=p}return i}(n,t,e);else i[i.length]={text:a,x:0,dy:0,width:Bc(a,n)};return i}(l,r,n.isLaneOrientation?i:void 0),n.wrapBounds=a=function doe(n,t){var r,s,e={x:0,width:0},i=0;for(i=0;in.width&&("Ellipsis"===n.textOverflow||"Clip"===n.textOverflow)?0:-r/2:"right"===n.textAlign?-r:t.length>1?0:-r/2,t[parseInt(i.toString(),10)].dy=1.2*n.fontSize,t[parseInt(i.toString(),10)].x=r,e.x=Math.min(e.x,r),e.width=Math.max(e.width,s);return e}(l,o),s.width=a.width,n.wrapBounds.width>=i&&"Wrap"!==l.textOverflow&&(s.width=i),s.height=o.length*n.style.fontSize*1.2,s}(this,0,0,this.isLaneOrientation?e.height:this.width||e.width):this.desiredSize,this.desiredSize=void 0===this.width||void 0===this.height?new me(i.width,i.height):new me(this.width,this.height),this.desiredSize=this.validateDesiredSize(this.desiredSize,e),this.desiredSize},t.prototype.arrange=function(e){return(e.width!==this.actualSize.width||e.height!==this.actualSize.height||this.isDirt)&&(this.doWrap=!0),this.actualSize=e,this.updateBounds(),this.isDirt=!1,this.actualSize},t}(hs),Gie=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Mi=function(n){function t(){var e=null!==n&&n.apply(this,arguments)||this;return e.measureChildren=void 0,e}return Gie(t,n),t.prototype.measure=function(e,i,r){var s=void 0,o=void 0;if(this.hasChildren()){for(var a=0,l=this.children;a=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Td=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Jie(t,n),Oh([I("")],t.prototype,"content",void 0),Oh([I("TopLeft")],t.prototype,"position",void 0),Oh([I("Mouse")],t.prototype,"relativeMode",void 0),Oh([I(!0)],t.prototype,"showTipPointer",void 0),Oh([I("auto")],t.prototype,"width",void 0),Oh([I("auto")],t.prototype,"height",void 0),Oh([I("Auto")],t.prototype,"openOn",void 0),Oh([I()],t.prototype,"animation",void 0),Oh([I(!1)],t.prototype,"isSticky",void 0),t}(Ee);function i3(n){var t=new bh;t=r3(n.tooltip,t);var e=new bh(t);return e.beforeCollision=ere,e.beforeOpen=Kie,e.cssClass="e-diagram-tooltip",e.opensOn="custom",e.appendTo("#"+n.element.id),e.close(),e}function Kie(n){(""===this.content||void 0===this.content)&&(n.element.style.display="none")}function ere(n){n.collidedPosition&&n.collidedPosition!==this.position&&(n.element.style.display="none")}function Cx(n,t){var e=n.tooltipObject;return r3(t?t.tooltip:n.tooltip,e),e}function r3(n,t){return n.content?(t.content=n.content,"string"==typeof n.content&&(t.content=ko(function(){return n.content})),t.position=n.position,t.showTipPointer=n.showTipPointer,t.width=n.width,t.height=n.height,t.animation=n.animation?n.animation:{close:{effect:"None"}}):t.close(),t}var Ex=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Bn=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Dx=function(n){function t(e,i,r,s){var o=n.call(this,e,i,r,s)||this;return o.inEdges=[],o.outEdges=[],o}return Ex(t,n),Bn([I("")],t.prototype,"id",void 0),Bn([I("Center")],t.prototype,"horizontalAlignment",void 0),Bn([I("Center")],t.prototype,"verticalAlignment",void 0),Bn([re({},Jn)],t.prototype,"margin",void 0),Bn([I(12)],t.prototype,"width",void 0),Bn([I(12)],t.prototype,"height",void 0),Bn([re({},Ll)],t.prototype,"style",void 0),Bn([I("Square")],t.prototype,"shape",void 0),Bn([I("Auto")],t.prototype,"connectionDirection",void 0),Bn([I(Gt.Connect)],t.prototype,"visibility",void 0),Bn([I("")],t.prototype,"pathData",void 0),Bn([I(ai.Default)],t.prototype,"constraints",void 0),Bn([I()],t.prototype,"addInfo",void 0),Bn([I()],t.prototype,"outEdges",void 0),Bn([I()],t.prototype,"inEdges",void 0),Bn([re({},Td)],t.prototype,"tooltip",void 0),t}(Ee),Es=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return Ex(t,n),t.prototype.getClassName=function(){return"PointPort"},Bn([re({x:.5,y:.5},R)],t.prototype,"offset",void 0),t}(Dx),Tc=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return Ex(t,n),t.prototype.getClassName=function(){return"PathPort"},Bn([I(.5)],t.prototype,"offset",void 0),Bn([re({x:0,y:0},R)],t.prototype,"displacement",void 0),Bn([I("Center")],t.prototype,"alignment",void 0),t}(Dx),EI=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),lr=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},tre=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return EI(t,n),lr([I("blue")],t.prototype,"color",void 0),lr([I("")],t.prototype,"content",void 0),lr([I("")],t.prototype,"link",void 0),lr([I("None")],t.prototype,"textDecoration",void 0),lr([I("NewTab")],t.prototype,"hyperlinkOpenState",void 0),t}(Ee),xx=function(n){function t(e,i,r,s){var o=n.call(this,e,i,r,s)||this;return r.id||(o.id=e.parentObj&&e.parentObj.propName&&"phases"===e.parentObj.propName?e.parentObj.id:Qe()),o}return EI(t,n),lr([I("")],t.prototype,"content",void 0),lr([I(void 0)],t.prototype,"template",void 0),lr([I("String")],t.prototype,"annotationType",void 0),lr([I(!0)],t.prototype,"visibility",void 0),lr([I(Nr.InheritReadOnly)],t.prototype,"constraints",void 0),lr([re(void 0,tre)],t.prototype,"hyperlink",void 0),lr([I("")],t.prototype,"id",void 0),lr([I()],t.prototype,"width",void 0),lr([I()],t.prototype,"height",void 0),lr([I(0)],t.prototype,"rotateAngle",void 0),lr([I("Parent")],t.prototype,"rotationReference",void 0),lr([re({strokeWidth:0,strokeColor:"transparent",fill:"transparent"},Xf)],t.prototype,"style",void 0),lr([I("Center")],t.prototype,"horizontalAlignment",void 0),lr([I("Center")],t.prototype,"verticalAlignment",void 0),lr([re({},Jn)],t.prototype,"margin",void 0),lr([re({top:void 0,bottom:void 0,left:void 0,right:void 0},Jn)],t.prototype,"dragLimit",void 0),lr([I("Shape")],t.prototype,"type",void 0),lr([re({},Td)],t.prototype,"tooltip",void 0),lr([I()],t.prototype,"addInfo",void 0),t}(Ee),Kn=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return EI(t,n),t.prototype.getClassName=function(){return"ShapeAnnotation"},lr([re({x:.5,y:.5},R)],t.prototype,"offset",void 0),t}(xx),Or=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return EI(t,n),t.prototype.getClassName=function(){return"PathAnnotation"},lr([I(.5)],t.prototype,"offset",void 0),lr([re({x:0,y:0},R)],t.prototype,"displacement",void 0),lr([I("Center")],t.prototype,"alignment",void 0),lr([I(!1)],t.prototype,"segmentAngle",void 0),t}(xx);function Tx(n){return sre[n.toString()]}function n3(n){return lre[""+n]}var sre={X:"M14,14 L106,106 M106,14 L14,106",Circle:"M0,50 A50,50,0 1 1 100,50 A50,50,0 1 1 0,50 Z",Square:"M0,0 L10,0 L10,10 L0,10 z"},ore={OpenArrow:"M15.9,23 L5,16 L15.9,9 L17,10.7 L8.7,16 L17,21.3Z",Square:"M0,0 L10,0 L10,10 L0,10 z",Fletch:"M14.8,10c0,0-3.5,6,0.2,12c0,0-2.5-6-10.9-6C4.1,16,11.3,16,14.8,10z",OpenFetch:"M6,17c-0.6,0-1-0.4-1-1s0.4-1,1-1c10.9,0,11-5,11-5c0-0.6,0.4-1,1-1s1,0.4,1,1C19,10.3,18.9,17,6,17C6,17,6,17,6,17z M18,23c-0.5,0-1-0.4-1-1c0-0.2-0.3-5-11-5c-0.6,0-1-0.5-1-1s0.4-1,1-1c0,0,0,0,0,0c12.9,0,13,6.7,13,7 C19,22.6,18.6,23,18,23z",IndentedArrow:"M17,10c0,0-4.5,5.5,0,12L5,16L17,10z",OutdentedArrow:"M14.6,10c0,0,5.4,6,0,12L5,16L14.6,10z",DoubleArrow:"M19,10 L19,22 L13,16Z M12,10 L12,22 L6,16Z",Arrow:"M15,10 L15,22 L5,16Z",Diamond:"M12,23l-7-7l7-7l6.9,7L12,23z",Circle:"M0,50 A50,50,0 1 1 100,50 A50,50,0 1 1 0,50 Z"},are={Square:"M0,0 L10,0 L10,10 L0,10 z",Rhombus:"M10,5 L5,10 L0,5 L5,0 L10,5 Z ",Rectangle:"M0,0 L15,0 L15,10 L0,10 z ",OpenArrow:"M15.9,23 L5,16 L15.9,9 L17,10.7 L8.7,16 L17,21.3Z",Fletch:"M9.82,0 C9.82,0,6.61,5,10,10 C10,10,7.71,5,0,5 C0,5,6.61,5,9.82,0 Z ",OpenFetch:"M0.71,5.71 C0.29,5.71,0,5.43,0,5 C0,4.57,0.29,4.29,0.71,4.29 C8.5,4.29,8.57,0.71,8.57,0.71 C8.57,0.29,8.86,0,9.29,0 C9.719999999999999,0,10,0.29,10,0.71 C10,0.93,9.93,5.71,0.71,5.71 C0.71,5.71,0.71,5.71,0.71,5.71 Z M9.29,10 C8.93,10,8.57,9.71,8.57,9.29 C8.57,9.14,8.36,5.71,0.71,5.71 C0.29,5.71,0,5.36,0,5 C0,4.64,0.29,4.29,0.71,4.29 C0.71,4.29,0.71,4.29,0.71,4.29 C9.93,4.29,10,9.07,10,9.29 C10,9.71,9.71,10,9.29,10 Z ",IndentedArrow:"M10,0 C10,0,6.25,4.58,10,10 L0,5 L10,0 Z ",OutdentedArrow:"M8,0 C8,0,12.5,5,8,10 L0,5 L8,0 Z ",DoubleArrow:"M19,10 L19,22 L13,16Z M12,10 L12,22 L6,16Z",Arrow:"M15,10 L15,22 L5,16Z",Diamond:"M10,5 L5,10 L0,5 L5,0 L10,5 Z ",Circle:"M10,5 C10,7.76,7.76,10,5,10 C2.24,10,0,7.76,0,5 C0,2.24,2.24,0,5,0 C7.76,0,10,2.24,10,5 Z ",Ellipse:"M15,5 C15,7.76,11.64,10,7.5,10 C3.36,10,0,7.76,0,5 C0,2.24,3.36,0,7.5,0 C11.64,0,15,2.24,15,5 Z "},lre={Square:"M0,0 L10,0 L10,10 L0,10 z",Rhombus:"M10,5 L5,10 L0,5 L5,0 L10,5 Z ",Rectangle:"M0,0 L15,0 L15,10 L0,10 z",OpenArrow:"M23,15.9 L16,5 L9,15.9 L10.7,17 L16,8.7 L21,17.3Z",Fletch:"M9.82,0 C9.82,0,6.61,5,10,10 C10,10,7.71,5,0,5 C0,5,6.61,5,9.82,0 Z ",OpenFetch:"M0.71,5.71 C0.29,5.71,0,5.43,0,5 C0,4.57,0.29,4.29,0.71,4.29 C8.5,4.29,8.57,0.71,8.57,0.71 C8.57,0.29,8.86,0,9.29,0 C9.719999999999999,0,10,0.29,10,0.71 C10,0.93,9.93,5.71,0.71,5.71 C0.71,5.71,0.71,5.71,0.71,5.71 Z M9.29,10 C8.93,10,8.57,9.71,8.57,9.29 C8.57,9.14,8.36,5.71,0.71,5.71 C0.29,5.71,0,5.36,0,5 C0,4.64,0.29,4.29,0.71,4.29 C0.71,4.29,0.71,4.29,0.71,4.29 C9.93,4.29,10,9.07,10,9.29 C10,9.71,9.71,10,9.29,10 Z ",IndentedArrow:"M10,0 C10,0,6.25,4.58,10,10 L0,5 L10,0 Z ",OutdentedArrow:"M8,0 C8,0,12.5,5,8,10 L0,5 L8,0 Z ",DoubleArrow:"M10,19 L22,19 L16,13Z M10,12 L22,12 L16,6Z",Arrow:"M10,15 L22,15 L16,5Z",Diamond:"M10,5 L5,10 L0,5 L5,0 L10,5 Z ",Circle:"M10,5 C10,7.76,7.76,10,5,10 C2.24,10,0,7.76,0,5 C0,2.24,2.24,0,5,0 C7.76,0,10,2.24,10,5 Z ",Ellipse:"M15,5 C15,7.76,11.64,10,7.5,10 C3.36,10,0,7.76,0,5 C0,2.24,3.36,0,7.5,0 C11.64,0,15,2.24,15,5 Z "};function Ax(n){return hre[n.toString()]}var hre={Process:"M419.511,76.687L359.511,76.687L359.511,43.086L419.511,43.086z",Decision:"M 253.005,115.687L 200.567,146.071L 148.097,115.687L 200.534,85.304L 253.005,115.687 Z",Document:"M 60 31.9 c 0 0 -11 -7.7 -30 0 s -30 0 -30 0 V 0 h 60 V 31.9 Z",PreDefinedProcess:"M 0,0 L 50,0 L 50,50 L 0,50 Z M 8.334,0 L 8.334,50 M 41.667,0 L 41.667,50",Terminator:"M 269.711,29.33C 269.71,44.061 257.77,56 243.04,56L 158.058,56C 143.33,56 131.39,44.061 131.39,29.33L 131.39,29.33C 131.391,14.6057 143.33,2.669 158.058,2.669L 243.044,2.669C 257.772,2.669 269.711,14.6057 269.711,29.333 Z",PaperTap:"M0.0009,17.2042 L0.0009,47.165 C0.001,47.165 14.403,53.5455 25.00,47.165 C35.599,40.7852 44.403,43.5087 50.00,47.165L50.001,17.2042 M50.001,32.7987 L50.001,2.8405 C50.001,2.8405 35.599,-3.5427 25.001,2.8405C14.403,9.2237 5.599,6.494 0.0009,2.8405 L0.0009,32.7987",DirectData:"M 132.62 0 L 17.38 0 C 7.78 0 0 13.43 0 30 C 0 46.57 7.78 60 17.38 60 L 132.62 60 M 132.62 0C 123.02 0 115.24 13.43 115.24 30 C 115.24 46.57 123.02 60 132.62 60 C 142.22 60 150 46.57 150 30 C 150 13.43 142.22 0 132.62 0 z ",SequentialData:"M0.0029,24.999 C0.0029,11.1922 10.433,0.0021 23.295,0.0021 C36.159,0.00216 46.585,11.1922 46.585,24.999C46.585,38.8057 36.159,49.9979 23.295,49.9979 C10.433,49.9979 0.0029,38.8057 0.0029,24.999 z M23.294,49.999 L50.002,49.999",Sort:"M50.001,24.9971 L25.001,49.9971 L0.00097,24.9971 L25.001,-0.00286865 L50.001,24.9971 z M0.000976562,24.9971 L50.001,24.9971",MultiDocument:"M43.6826,40 C44.8746,40.6183 45.8586,41.3502 46.8366,42.1122 L46.8366,4.74487 L3.09857,4.74487 L3.09857,10.9544 M46.837,35.143 C48.027,35.765 49.025,36.604 50.003,37.369 L50.003,0.002 L6.264,0.002 L6.264,4.744 M43.682,47.113 L43.682,10.765 L0.0025,10.7652 L0.0025,47.1132 C0.0025,47.1132 12.5846,53.6101 21.8426,47.1132 C31.1006,40.6163 38.792,43.393 43.6826,47.1132 z",Collate:"M50.001,0.0028 L25.001,25.0029 L0.00097,0.0028 L50.001,0.002 z M0.0009,50.002 L25.001,25.002L50.001,50.002 L0.0009,50.0029 z",SummingJunction:"M7.3252,42.6768 L42.6772,7.3247 M42.6768,42.6768 L7.3248,7.3247 M0.0009,25.001 C0.0009,11.193 11.197,0.0009 25.001,0.0009 C38.809,0.0009 50.001,11.193 50.001,25.001 C50.001,38.809 38.809,50.001 25.001,50.001 C11.197,50.00 0.0009,38.809 0.0009,25.00 z",Or:"M 0 50 L 100 50 M 50 100 L 50 0.0 M 0 50 C 0 22.384 22.392 0 50 0 C 77.616 0 100 22.384 100 50 C 100 77.616 77.616 100 50 100 C 22.392 100 0 77.616 0 50 Z",InternalStorage:"M 0 3.81946A 2.5,3.81946 0 0,1 2.5,0L 47.5 0A 2.5,3.81946 0 0,1 50,3.81946L 50 45.836A 2.5,3.819446 0 0,1 47.5,49.652778L 2.5 49.652778A 2.5,3.819446 0 0,1 0,45.8336L 0 3.819446ZM 0 11.45834L 50 11.4583334M 12.5 0L 12.5 49.652778",Extract:"M0,35 L30,0 L60,35 Z",ManualOperation:"M46.4,28.8 L14.8,28.8 L0,0 L60,0 Z",Merge:"M60,0 L30,35 L0,0 Z",OffPageReference:"M60,33.3 L30.1,39 L0,33.3 L0,0 L60,0 Z",SequentialAccessStorage:"M 60 30 C 60 13.4 46.6 0 30 0 S 0 13.4 0 30 s 13.4 30 30 30 h 28.6 v -6.5 h -9.9C 55.5 48 60 39.5 60 30 Z",Annotation:"M49.9984,50.0029 L-0.00271199,50.0029 L-0.00271199,0.00286865 L49.9984,0.00286865",Annotation2:"M49.9977,50.0029 L25.416,50.0029 L25.416,0.00286865 L49.9977,0.00286865 M25.4166,25.0029 L-0.00227869,25.0029",Data:"M 10 0 L 40 0 L 30 40 L 0 40 Z",Card:"M275,60 L400,60 L400,110 L260,110 L260,75 Z",Delay:"M0,0 L12.029,0 C14.212999,0 16,1.7869979 16,3.9709952 C16,6.1549926 14.212999,7.9409904 12.029,7.9409904 L0,7.9409904 z",Preparation:"M 1048.17 572 C 1051.06 568.86 1055.17 567.05 1059.5 567 L 1094.51 567 C 1098.84 567.05 1102.95 568.86 1105.84 572 L 1126.43 595 C 1127.01 596.28 1127.01 597.72 1126.43 599 L 1105.84 622 C 1102.95 625.14 1098.84 626.95 1094.51 627 L 1059.5 627 C 1055.17 626.95 1051.06 625.14 1048.17 622 L 1027.58 599 C 1027 597.72 1027 596.28 1027.58 595 L 1048.17 572 Z",Display:"M47.8809,19.2914 L32.7968,-0.00594145 L11.3902,-0.00594145 C7.93166,-0.00594145 0.00124586,11.187 0.00124586,24.9968C0.00124586,38.8032 7.93166,49.9962 11.3902,49.9962 L32.7968,49.99 L47.615,31.038 C47.615,31.0388 52.798,24.9968 47.880,19.2914 z",ManualInput:"M 912 732 L 1006.85 707 C 1008.2 707 1009.5 707.53 1010.46 708.46 C 1011.41 709.4 1011.95 710.67 1011.95 712 L 1011.95 762C 1012 764.41 1010.28 766.52 1007.87 767 L 917.1 767 C 915.75 767 914.45 766.47 913.49 765.54 C 912.54 764.6 912 763.33 912 762 L 912 732 Z",LoopLimit:"M 8 9 L 27 9 L 33 15 L 33 26 C 33 27 33 27 32 27 L 4 27 C 3 27 2 27 2 26 L 2 15 L 8 9 Z",StoredData:"M 5.55 0L 50 0A 1.5,30 0 0,1 50,0A 5.555,25 0 0,0 50,50A 1.5,30 0 0,1 50,50L 5.555 50A 5.55,25 0 0,1 5.555,0Z"};function s3(n,t,e){var i;i="Straight"!==n.type&&n.sourceWrapper?n.sourceWrapper.corners.center:function cre(n){var t;if(n.sourcePortWrapper){var e=n.sourcePortWrapper;t={x:e.offsetX,y:e.offsetY}}else t=n.sourceID&&n.sourceWrapper&&n.targetWrapper?qa(n,0,n.sourceWrapper.corners.center,n.targetWrapper.corners.center,!1):n.sourcePoint;return t}(n);var r=function ure(n,t,e,i,r){var b,M,s=n.sourceWrapper,o=n.targetWrapper,a=n.sourcePortWrapper,l=n.targetPortWrapper,d=[],p=Xa(n),y={corners:undefined,point:t,direction:undefined,margin:{left:5,right:5,bottom:5,top:5}},S={corners:undefined,point:e,direction:undefined,margin:{left:5,right:5,bottom:5,top:5}};if(void 0!==s&&void 0!==o&&(b=xn(s),M=xn(o),y.corners=s.corners,S.corners=o.corners),void 0!==a&&(y.direction="Left"===a.connectionDirection||"Top"===a.connectionDirection||"Bottom"===a.connectionDirection||"Right"===a.connectionDirection?a.connectionDirection:zo({x:a.offsetX,y:a.offsetY},b,s.bounds)),void 0!==l&&(S.direction="Left"===l.connectionDirection||"Right"===l.connectionDirection||"Bottom"===l.connectionDirection||"Top"===l.connectionDirection?l.connectionDirection:zo({x:l.offsetX,y:l.offsetY},M,o.bounds)),"Bezier"===n.type&&!n.isBezierEditing&&n.segments.length>0)for(var D=n.segments.length-1;D>=0;)n.segments[parseInt(D.toString(),10)].isInternalSegment&&n.segments.pop(),D--;if(void 0!==s&&void 0!==o)return(void 0===y.direction||void 0===S.direction)&&(i?function dre(n,t,e){"LeftToRight"===e?(n.direction=n.direction?n.direction:"Right",t.direction=t.direction?t.direction:"Left"):"RightToLeft"===e?(n.direction=n.direction?n.direction:"Left",t.direction=t.direction?t.direction:"Right"):"TopToBottom"===e?(n.direction=n.direction?n.direction:"Bottom",t.direction=t.direction?t.direction:"Top"):"BottomToTop"===e&&(n.direction=n.direction?n.direction:"Top",t.direction=t.direction?t.direction:"Bottom")}(y,S,i):y.corners.top>S.corners.bottom&&Math.abs(y.corners.top-S.corners.bottom)>p?(y.direction=y.direction?y.direction:"Top",S.direction=S.direction?S.direction:"Bottom"):y.corners.bottomp?(y.direction=y.direction?y.direction:"Bottom",S.direction=S.direction?S.direction:"Top"):y.corners.rightp||y.corners.right+p=y.corners.left-p&&y.corners.left>S.corners.left?(y.direction=y.direction?y.direction:"Right",S.direction=S.direction?S.direction:"Left"):y.corners.left>S.corners.right&&Math.abs(y.corners.left-S.corners.right)>y.margin.left+y.margin.right||S.corners.right+p=S.corners.left-p&&y.corners.left0&&n.segments[0].direction&&(y.direction=n.segments[0].direction),y.point=Nl(b,y.direction),d=Nl(b,_n(y.direction)),y.point=qa(n,0,y.point,d,!1)):y.point=o.corners.center;if(void 0!==h){switch(S.point={x:h.offsetX,y:h.offsetY},S.direction){case"Bottom":case"Top":S.point.y=S.point.y;break;case"Left":case"Right":S.point.x=S.point.x}n.targetPadding&&!w&&(S.point=DI(n,y,S,!0))}else"Orthogonal"===n.type||"Bezier"===n.type?(S.point=Nl(M,S.direction),d=Nl(M,_n(S.direction)),S.point=qa(n,0,S.point,d,!0)):S.point=a.corners.center;if("Orthogonal"!==n.type){var C=void 0,D=void 0;if("Bezier"===n.type){if(n.bezierSettings.allowSegmentsReset||0===n.segments.length||!R.isEmptyPoint(n.segments[n.segments.length-1].point))return c=g3(n,y,S,void 0,s),Lx(n,y,S);Bv(n)}else Bv(n);if(void 0===n.sourcePortWrapper){y.point=y.corners.center,n.segments&&n.segments.length>0&&(C=R.isEmptyPoint((D=n.segments[0]).point)?void 0:D);var A=void 0!==C?C.point:S.point;if("Bezier"===n.type&&n.segments.length>0&&n.segments[0].vector1.angle&&n.segments[0].vector1.distance){var x=Math.max(y.corners.width,y.corners.height);A=R.transform(y.point,n.segments[0].vector1.angle,x/2)}y.point=w?n.sourceWrapper.bounds.center:qa(n,0,y.point,A,!1)}if(void 0===n.targetPortWrapper){S.point=S.corners.center,n.segments&&n.segments.length>1&&(C=R.isEmptyPoint((D=n.segments[n.segments.length-2]).point)?void 0:D);var P=C?C.point:y.point;"Bezier"===n.type&&n.segments.length>0&&n.segments[n.segments.length-1].vector2.angle&&n.segments[n.segments.length-1].vector2.distance&&(x=Math.max(y.corners.width,y.corners.height),P=R.transform(S.point,n.segments[0].vector2.angle,x/2)),S.point=w?n.targetWrapper.bounds.center:qa(n,0,P,S.point,!0)}c=Lx(n,y,S)}else"Orthogonal"===n.type&&n.segments&&n.segments.length>0&&null!==n.segments[0].direction?c=function Mre(n,t,e,i,r,s,o){var a,h,c,d;Bv(n);for(var u=0;u0&&n.segments[u-1].direction===h.direction?u=u3(n,u,t):h.direction?t.point=o3(t,n.segments[parseInt(u.toString(),10)]):(f=n.segments[u-1])&&f.points&&f.points.length>0&&(t.point=f.points[f.points.length-1]),u===n.segments.length-1)if(f3(n,t),c3(a=void 0===r?bre(n,t,e):l3(n,t,e),n),h.points=[],a.length>=2)for(c=0;c2&&n.segments.length>2){var p={x:a[parseInt(c.toString(),10)].x,y:t.point.y};h.points=[],h.points.push(p),h.points.push(a[parseInt(c.toString(),10)]);var f=n.segments[u-1];n.segments.length<4&&f.points.pop(),f.points=f.points.concat(h.points)}else h.points.push(a[parseInt(c.toString(),10)]);else h.points.push(a[parseInt(c.toString(),10)]);else d=u;if(void 0!==d&&!n.selectedSegmentIndex&&(d===n.segments.length-1&&(n.segments[d-1].direction=null,n.segments[d-1].length=null),n.segments.splice(d,1)),i&&0===u){var g=h3(n,i,s);g&&(t.point=g)}}return p3(n,[])}(n,y,S,l,h,o):(n.segments[0]||(C=new wi(n,"segments",{type:"Orthogonal"},!0),n.segments.push(C)),n.segments[0].points=c=g3(n,y,S,void 0,s));return c}(n,y.direction,S.direction,y.point,S.point,r);if(Bv(n),(n.sourceWrapper||n.targetWrapper)&&function mre(n,t,e){var i=n.sourcePortWrapper,r=n.targetPortWrapper,s=n.sourceWrapper,o=t.point,a={left:0,right:0,top:0,bottom:0},l={x:0,y:0},c="Top";if(s?(o=e.point,a=t.margin):(s=n.targetWrapper,a=e.margin),"Orthogonal"===n.type)if(n.segments&&n.segments.length>0&&n.sourceWrapper&&n.segments[0].direction)t.direction=n.segments[0].direction,l=qa(n,0,l=Nl(s.corners,t.direction),Nl(s.corners,_n(t.direction)),!1);else{var u={corners:null,direction:null,point:null,margin:null};Fv(s,{corners:null,direction:null,point:o,margin:a},u,n),l=u.point,c=u.direction}else{var f=void 0;n.segments&&n.segments.length>1&&(f=s===n.sourceWrapper?n.segments[0].point:n.segments[n.segments.length-2].point),l=qa(n,0,s.bounds.center,n.segments&&n.segments.length>1?f:o,s===n.targetWrapper)}s===n.sourceWrapper?(t.direction=t.direction||c,t.point=l,n.sourcePortWrapper&&(t.point={x:i.offsetX,y:i.offsetY},n.sourcePadding&&(t.point=DI(n,t,e,!1)))):(e.direction=e.direction||c,e.point=l,n.targetPortWrapper&&(e.point={x:r.offsetX,y:r.offsetY},n.targetPadding&&(e.point=DI(n,t,e,!0))))}(n,y,S),"Straight"===n.type||"Bezier"===n.type)d=Lx(n,y,S);else if("Orthogonal"===n.type&&n.segments&&n.segments.length>0&&null!==n.segments[0].length&&null!==n.segments[0].direction)d=function vre(n,t,e,i,r,s,o){var a,l,c,u,h=[];if(Bv(n),n.segments.length>0){for(var f=0;f0&&n.segments[f-1].direction===p.direction)f=u3(n,f,t);else{var g=n.segments[f-1];t.point=p.direction?o3(t,p):g.points[g.points.length-1]}if(f===n.segments.length-1&&(o||r?n.targetWrapper&&void 0===n.targetPortWrapper?(f3(n,t),l=pre(n,t,e)):l=l3(n,t,e):l=fre(n,t,e),l))if(c3(l,n),p.points=[],l.length>=2)for(a=0;at.corners.top&&e.point.ye.point.x?"Left":"Right"):e.point.x>t.corners.left&&e.point.xe.point.y?"Top":"Bottom")),n.sourcePortWrapper&&s===_n(r)?(("Left"===s||"Right"===s)&&t.point.y>=t.corners.top&&t.point.y<=t.corners.center.y&&e.point.y>=t.corners.top&&e.point.y<=t.corners.center.y?(t.direction="Top",a=t.point.y-t.corners.top+20):("Left"===s||"Right"===s)&&t.point.y>t.corners.center.y&&t.point.y<=t.corners.bottom&&e.point.y>t.corners.center.y&&e.point.y<=t.corners.bottom?(t.direction="Bottom",a=t.corners.bottom-t.point.y+20):("Top"===s||"Bottom"===s)&&t.point.x>=t.corners.left&&t.point.x<=t.corners.center.x&&e.point.x>=t.corners.left&&e.point.x<=t.corners.center.x?(t.direction="Left",a=t.point.x-t.corners.left+20):("Top"===s||"Bottom"===s)&&t.point.x<=t.corners.right&&t.point.x>t.corners.center.x&&e.point.x<=t.corners.right&&e.point.xt.point.y&&t.point.y>=e.corners.top?(i="Top",r=t.point.y-e.corners.top+20):e.corners.center.y===t.point.y&&"Top"===n.segments[n.segments.length-2].direction||e.corners.center.ye.point.y?t.point.y-t.corners.top+20:t.corners.bottom-t.point.y+20):(i="Top",r=e.corners.height/2+20):e.corners.center.x!==t.point.x||e.corners.topt.point.x&&t.point.x>=e.corners.left?(i="Left",r=t.point.x-e.corners.left+20):e.corners.center.x===t.point.x&&"Left"===n.segments[n.segments.length-2].direction||e.corners.center.x<=t.point.x&&t.point.x<=e.corners.right?(i="Right",r=e.corners.right-t.point.x+20):void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&t.corners.left<=t.point.x&&t.point.x<=t.corners.right&&(i=t.direction,r=t.point.x>e.point.x?t.point.x-t.corners.left+20:t.corners.right-t.point.x+20):(i="Left",r=e.corners.width/2+20);var a=t.point;t.point=Fn(t.point,"Left"===i||"Top"===i?-r:r,"Left"===i||"Right"===i?0:90),t.direction=R.direction(t.point,e.point),void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&(t.corners.center.x===e.corners.center.x||t.corners.center.y===e.corners.center.y)&&(t.direction=e.direction);var l=Ys(n,t,e);return l.splice(0,0,a),l}function l3(n,t,e){var i,r;e.corners=n.targetWrapper.corners,void 0!==n.sourcePortWrapper&&(r=zo({x:n.sourcePortWrapper.offsetX,y:n.sourcePortWrapper.offsetY},xn(n.sourceWrapper),n.sourceWrapper.bounds));var a=function gre(n,t,e,i){var r=!1;switch(e.direction){case"Left":void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&"Right"===i&&t.point.x>e.point.x&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom||("Bottom"===i&&t.point.y>e.point.y||"Top"===i&&t.point.y=t.corners.left&&t.point.x<=t.corners.right?(t.direction="Right"===i?t.point.y>e.point.y?"Top":"Bottom":t.point.xe.point.x&&(t.point.y>e.point.y||t.point.yt.point.y&&e.corners.bottome.point.y||t.point.x>e.point.x&&t.point.y<=e.point.y&&e.corners.top=t.point.y?t.direction="Top":t.point.xe.point.x&&t.point.y>e.point.y&&e.corners.bottomt.point.y?t.direction="Bottom":t.point.y===e.point.y&&t.point.xe.point.y||"Top"===i&&t.point.ye.point.x&&t.point.x>=t.corners.left&&t.point.x<=t.corners.right?(t.direction=t.point.x>e.point.x?"Left":"Right",r=!0):void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&"Left"===i&&t.point.x=t.corners.top&&t.point.y<=t.corners.bottom?(t.direction=t.point.y>e.point.y?"Top":"Bottom",r=!0):t.point.x=t.point.y&&t.point.y===e.point.y||t.point.y>e.point.y&&t.point.x>e.point.x?t.direction="Top":t.point.ye.point.x?t.direction="Bottom":t.point.xe.point.y||t.point.ye.point.x&&(t.direction="Left");break;case"Top":void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&"Bottom"===i&&t.point.y>e.point.y&&t.point.x>=t.corners.left&&t.point.x<=t.corners.right||("Right"===i&&t.point.x>e.point.x||"Left"===i&&e.point.y>t.point.y&&e.point.x>t.point.x)&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom?(t.direction="Bottom"===i?t.point.x>e.point.x?"Left":"Right":t.point.ye.point.y&&t.point.x>e.corners.left&&t.point.x=e.point.y?t.direction="Top":t.point.ye.point.x?t.direction="Left":t.point.yt.point.x)&&t.point.y>e.point.y&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom||"Top"===i&&t.point.y=t.corners.left&&t.point.x<=t.corners.right)?(t.direction="Right"===i||"Left"===i?t.point.y>e.point.y?"Top":"Bottom":t.point.x>e.point.x?"Left":"Right",r=!0):t.point.ye.corners.left&&e.corners.right>t.point.x?t.point.ye.corners.left&&e.corners.center.x>=t.point.x?t.direction="Left":t.point.ye.point.y&&t.point.x>e.point.x?t.direction="Left":t.point.y>e.point.y&&t.point.xe.point.x||e.point.x>t.point.x)&&(t.direction="Bottom")}return r}(n,t,e,r);return!n.selectedSegmentIndex&&void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&e.direction===_n(r)&&(("Left"===e.direction&&t.point.x>e.point.x||"Right"===e.direction&&t.point.x=t.corners.top&&t.point.y<=t.corners.bottom||"Bottom"===e.direction&&t.point.y=t.corners.left&&t.point.x<=t.corners.right)?i=a3(n,t,e):n.selectedSegmentIndex||t.direction!==e.direction?!n.selectedSegmentIndex&&("Left"===e.direction&&t.point.x>e.point.x||"Right"===e.direction&&t.point.x=t.point.y||"Top"===e.direction&&t.point.y>e.point.y||"Bottom"===e.direction&&t.point.y=t.point.x?i=n.selectedSegmentIndex?Ol(t,e):a3(n,t,e):!n.selectedSegmentIndex&&void 0!==n.sourceWrapper&&void 0!==n.targetWrapper&&void 0!==n.targetPortWrapper&&("Left"===t.direction||"Right"===t.direction)&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom&&("Top"===e.direction||"Bottom"===e.direction)&&e.corners.center.x===t.corners.center.x?(t.direction="Top"===e.direction?"Bottom":"Top",i=Ys(n,t,e,"Top"===e.direction?t.corners.bottom-t.point.y+20:t.point.y-t.corners.top+20)):!n.selectedSegmentIndex&&void 0!==n.sourceWrapper&&void 0!==n.targetWrapper&&void 0!==n.targetPortWrapper&&("Top"===t.direction||"Bottom"===t.direction)&&t.point.x>=t.corners.left&&t.point.x<=t.corners.right&&("Left"===e.direction||"Right"===e.direction)&&e.corners.center.y===t.corners.center.y?(t.direction="Left"===e.direction?"Right":"Left",i=Ys(n,t,e,"Left"===e.direction?t.corners.right-t.point.x+20:t.point.x-t.corners.left+20)):i=a?Ys(n,t,e,"Left"===t.direction||"Right"===t.direction?"Left"===t.direction?t.point.x-t.corners.left+20:t.corners.right-t.point.x+20:"Top"===t.direction?t.point.y-t.corners.top+20:t.corners.bottom-t.point.y+20):Ol(t,e):i=Ys(n,t,e),i}function h3(n,t,e){var r,i={x:t.offsetX,y:t.offsetY},s=xn(e),o=zo(i,s,e.bounds),a=n.segments[0];return a.direction!==o&&(function wre(n,t,e,i,r,s){var a,h,o=13,l=[];l.push(i),i.y===r.y&&("Left"===t&&r.xi.x)||i.x===r.x&&("Top"===t&&r.yi.y)||("Top"===t||"Bottom"===t?"Top"===t&&r.yi.y-o||"Bottom"===t&&r.y>i.y&&r.yo&&("Top"===t&&r.yi.y)?l.push({x:i.x,y:r.y}):(a=r.xi.x-o||"right"===t&&r.x>i.x&&r.xo&&("Left"===t&&r.xi.x)?l.push({x:r.x,y:i.y}):(l.push({x:a="Left"===t?e.left-o:e.right+o,y:i.y}),l.push({x:a,y:r.y})),s&&(l.push(n.points[0]),l.reverse()),n.points=l)}(a,o,s,a.points[0],a.points[a.points.length-1],!1),r=a.points[a.points.length-1],a.direction=R.direction(a.points[a.points.length-2],a.points[a.points.length-1])),r}function c3(n,t,e){var s,i=t.segments[t.segments.length-2],r=i.points[i.points.length-1];(("Top"===i.direction||"Bottom"===i.direction)&&r.x===n[1].x||("Left"===i.direction||"Right"===i.direction)&&r.y===n[1].y)&&(i.points[i.points.length-1]=n[1],s=R.direction(i.points[0],i.points[i.points.length-1]),void 0!==t.sourceWrapper&&void 0===t.sourcePortWrapper&&s===_n(i.direction)&&("Left"===i.direction||"Right"===i.direction?i.points[0].x="Right"===i.direction?i.points[0].x-t.sourceWrapper.corners.width:i.points[0].x+t.sourceWrapper.corners.width:i.points[0].y="Bottom"===i.direction?i.points[0].y-t.sourceWrapper.corners.height:i.points[0].y+t.sourceWrapper.corners.height),i.direction=s,i.length=R.distancePoints(i.points[0],i.points[i.points.length-1]),n.splice(0,1))}function DI(n,t,e,i){var o=i?n.targetPadding:n.sourcePadding,a=i?n.targetPortWrapper:n.sourcePortWrapper,l=new Ne(a.bounds.x-o,a.bounds.y-o,a.actualSize.width+2*o,a.actualSize.height+2*o),h=[l.topLeft,l.topRight,l.bottomRight,l.bottomLeft];h[h.length]=h[0];var d=i?e.point:t.point;return Ox({x1:t.point.x,y1:t.point.y,x2:e.point.x,y2:e.point.y},h,0,d)||d}function d3(n,t){var e=[],i=dF(0,n.corners,t);i.push(i[0]);for(var r=0;r0){var r=void 0,s=[],o=t.point;for(r=0;r1&&R.equals(a.points[0],a.points[1])&&n.segments.splice(r,1),a)for(var l=0;l0||0===r)&&i.push(a.points[parseInt(l.toString(),10)])}}return i}function Nx(n,t,e){return"Top"===n||"Bottom"===n?e.x>t.x?"Right":"Left":e.y>t.y?"Bottom":"Top"}function Bv(n){if("Straight"===n.type||"Bezier"===n.type){if(0===n.segments.length||n.segments.length>0&&!R.isEmptyPoint(n.segments[n.segments.length-1].point))if("Bezier"===n.type){var t=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0},!0);n.segments.push(t)}else t=new Hl(n,"segments",{type:"Straight"},!0),n.segments.push(t)}else{if(n.segments.length>0)for(var e=!1,i=0;i=t.corners.left&&e.point.x<=t.corners.right&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom)t.direction=e.point.y>t.point.y?"Bottom":"Top",i=Ys(n,t,e,"Top"===t.direction?t.point.y-t.corners.top+20:t.corners.bottom-t.point.y+20);else if(n.sourcePortWrapper&&r===_n(o)){var h;("Left"===r||"Right"===r)&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom?(t.direction=e.point.y>t.point.y?"Bottom":"Top",h=t.corners.height/2+20):("Top"===r||"Bottom"===r)&&t.point.x>=t.corners.left&&t.point.x<=t.corners.right&&(t.direction=e.point.x>t.point.x?"Right":"Left",h=t.corners.width/2+20),t.direction&&h?i=Ys(n,t,e,h,!0):(t.direction=o,i=Ol(t,e))}else if(!n.sourcePortWrapper||r!==e.direction||"Top"!==r&&"Bottom"!==r||t.corners.center.x!==e.corners.center.x)if(t.direction===e.direction)if(("Left"===t.direction||"Right"===t.direction)&&e.point.y>t.corners.top-20&&e.point.yt.corners.left-20&&e.point.xt.point.y?"Bottom":"Top",i=Ys(n,t,e,"Bottom"===t.direction?t.corners.bottom-t.point.y+20:t.point.y-t.corners.top+20);else t.direction=o,i=Ys(n,t,e,"Top"===o||"Bottom"===o?n.sourceWrapper.height/2+20:n.sourceWrapper.width/2+20),t.point=i[1],"Left"===o||"Right"===o?(e.direction=o,e.point="Left"===o?e.corners.middleLeft:e.corners.middleRight):Fv(n.targetWrapper,t,e,n),i=Ys(n,t,e);return i}function f3(n,t){if(void 0!==n.targetWrapper&&void 0===n.targetPortWrapper&&xn(n.targetWrapper).containsPoint(t.point,1)){var i=n.targetWrapper,r=n.segments[n.segments.length-2],s=r.points[r.points.length-1],o=_n(r.direction);"Bottom"===o?s.yi.corners.top-1&&(r.points[r.points.length-1].y=i.corners.top-20,r.length=R.distancePoints(r.points[0],r.points[r.points.length-1])):"Left"===o?s.x>i.corners.left-1&&(r.points[r.points.length-1].x=i.corners.left-20,r.length=R.distancePoints(r.points[0],r.points[r.points.length-1])):"Right"===o&&s.x0||0===e)&&t.push(i.points[parseInt(r.toString(),10)]);return t}function Fv(n,t,e,i){var r,s={x:0,y:0},o=xI(n,n.corners,n.bounds),a=t.margin,l=t.point;if(o.bottomCenter.y+a.bottoml.y)r="Top",s=o.topCenter;else if(o.middleLeft.x-a.left>l.x)r="Left",s=o.middleLeft;else if(o.middleRight.x+a.rightc&&(f=c,r="Right",s=o.middleRight),f>d&&(f=d,r="Bottom",s=o.bottomCenter),f>u&&(r="Left",s=o.middleLeft)}e.point=s,e.direction=r;var p=Nl(o,_n(e.direction));e.point=qa(i,0,e.point,p,n===i.targetWrapper)}function g3(n,t,e,i,r){var s,o,a;if(s=function Hre(n,t){var e=!1;switch(n){case"Left":switch(t){case"Right":case"Bottom":e=!0}break;case"Top":switch(t){case"Left":case"Right":case"Bottom":e=!0}break;case"Bottom":"Right"===t&&(e=!0)}return e}(t.direction,e.direction),s&&b3(t,e),"Right"===t.direction&&"Left"===e.direction)a=function Cre(n,t,e,i){var o=Math.round(Math.abs(t.point.y-e.point.y)),a={x:Math.max(t.point.x,t.corners.right),y:t.point.y},l={x:Math.min(e.point.x,e.corners.left),y:e.point.y},h=Xa(n);if(i){var c=l;l=a,a=c}return t.corners.bottom+he.corners.bottom+h||("Bezier"!==n.type||e.corners.left-t.corners.right<=2*h&&e.corners.left-t.corners.right>=5)&&(h=0),t.margin={left:h,right:h,top:h,bottom:h},e.margin={left:h,right:h,top:h,bottom:h},0===o&&(t.corners.right=e.corners.right?void 0!==i&&(i.offsetYe.corners.bottom+e.margin.bottom)||void 0===i&&t.corners.middleRight.ye.corners.bottom+e.margin.bottom&&t.corners.top>e.corners.bottom||void 0===i&&t.corners.middleRight.y>e.corners.bottom||void 0!==i&&i.offsetYe.corners.top||void 0===i&&t.corners.middleRight.y>e.corners.bottom?Ae.Three:t.corners.rightr.offsetY+e.margin.right||void 0===r&&t.corners.top>e.corners.middleRight.y||void 0!==r&&(void 0!==i&&i.offsetXr.offsetX||void 0===r&&t.corners.left>e.corners.topCenter.x?Ae.Four:Ae.Two:void 0!==s&&Math.abs(t.corners.right-e.corners.left)<=5&&Math.abs(s.offsetY-e.corners.top)<=5||void 0!==r&&t.corners.right=25&&t.corners.middleRight.y+t.margin.righte.corners.bottom+e.margin.bottom||void 0===o&&t.corners.middleRight.y>e.corners.bottom+e.margin.bottom?t.corners.top>e.corners.bottom?void 0!==a&&t.corners.right+t.margin.righta.offsetX||void 0===a&&t.corners.left>e.corners.bottomCenter.x?Ae.Four:Ae.Two:void 0!==o&&Math.abs(t.corners.right-e.corners.left)<=25&&Math.abs(o.offsetY-e.corners.bottom)<=25?Ae.Two:Ae.Four}(n,t,e,s);else if("Bottom"===t.direction&&"Top"===e.direction)a=function Tre(n,t,e){var r=t.point.x-e.point.x,s=Xa(n);return t.corners.right+se.corners.right+s||("Bezier"!==n.type||e.corners.top-t.corners.bottom<=2*s&&e.corners.top-t.corners.bottom>=5)&&(s=0),t.margin={left:s,right:s,top:s,bottom:s},e.margin={left:s,right:s,top:s,bottom:s},0===r&&t.corners.bottome.corners.right+e.margin.right||void 0===i&&t.corners.bottomCenter.x>e.corners.right+e.margin.right?Ae.Three:t.corners.bottomr.offsetX||void 0===r&&t.corners.left>e.corners.left||void 0!==r&&t.corners.right+t.margin.righte.corners.bottom?Ae.Five:0===s||0===o?Ae.One:Ae.Three}(n,t,e)}else"Bottom"===t.direction&&"Left"===e.direction?a=function Are(n,t,e,i){var r=n.sourcePortWrapper,s=n.targetPortWrapper,o=Xa(n);if(e.margin={left:o,right:o,top:o,bottom:o},t.margin={top:o,bottom:o,left:o,right:o},i){var l=r;r=s,s=l}return void 0!==r&&r.offsetXs.offsetY||void 0===s&&t.corners.top>e.corners.middleLeft.y?Ae.Four:Ae.Two:void 0!==s&&Math.abs(t.corners.right-e.corners.left)<=25&&Math.abs(s.offsetY-t.corners.bottom)<=25?Ae.Two:Ae.Four}(n,t,e,s):"Left"===t.direction&&"Left"===e.direction?a=function Ore(n,t,e){var i=n.sourcePortWrapper,r=n.targetPortWrapper,s=Xa(n);t.margin={left:s,right:s,top:s,bottom:s},e.margin={left:s,right:s,top:s,bottom:s};var o=Math.round(Math.abs(t.point.x-e.point.x)),a=Math.round(Math.abs(t.point.y-e.point.y));return t.corners.leftr.offsetY||void 0===r&&t.corners.top-t.margin.top>e.corners.middleLeft.y?Ae.Three:t.corners.righte.corners.bottom+e.margin.bottom||void 0===i&&t.corners.middleLeft.y>e.corners.bottom+e.margin.bottom?Ae.Three:t.corners.left>e.corners.right?Ae.Five:0===o||0===a?Ae.One:Ae.Three}(n,t,e):"Left"===t.direction&&"Top"===e.direction?a=function Nre(n,t,e,i){var s=n.sourcePortWrapper,o=Xa(n);e.margin={left:o,right:o,top:o,bottom:o},t.margin={top:o,bottom:o,left:o,right:o};var a=n.targetPortWrapper,l={x:Math.min(t.point.x,t.corners.left),y:t.point.y},h={x:e.point.x,y:Math.min(e.point.y,e.corners.top)};if(i){var c=s;s=a,a=c;var d=l;l=h,h=d}return void 0!==s&&s.offsetYa.offsetX||void 0===a&&t.corners.left-t.margin.left>e.corners.topCenter.x?Ae.Two:Ae.Four:void 0!==a&&t.corners.rightr.offsetX||void 0===r&&t.corners.left>e.corners.left||void 0!==r&&t.corners.right+t.margin.righte.corners.right+e.margin.right||void 0===i&&t.corners.left>e.corners.right||void 0!==i&&i.offsetXe.corners.bottom?Ae.Five:0===s||0===o?Ae.One:Ae.Three}(n,t,e));return s&&b3(t,e),o=function Pre(n,t,e,i,r,s){var l,d,h=n.sourceWrapper.corners,c=n.targetWrapper.corners,u=20,f={corners:e.corners,point:e.point,direction:e.direction,margin:e.margin},p={corners:i.corners,point:i.point,direction:i.direction,margin:i.margin};if(!(f.direction===p.direction&&t!==Ae.Five||f.direction!==_n(p.direction)&&t!==Ae.Three))switch(f.direction){case"Left":h.middleLeft.x>c.middleRight.x&&(d=(h.middleLeft.x-c.middleRight.x)/2,u=s?d:Math.min(u,d));break;case"Right":h.middleRight.xc.bottomCenter.y&&(d=(h.topCenter.y-c.bottomCenter.y)/2,u=s?d:Math.min(u,d));break;case"Bottom":h.bottomCenter.yf&&hf)&&o>c&&o<=d&&e>=20&&(s=n.point.x-t.corners.left+s),i&&n.direction===t.direction&&n.corners.left>t.corners.left&&n.corners.left-t.corners.right>=20&&(s=(n.corners.left-t.corners.right)/2),p=Fn(n.point,s,180);break;case"Top":(o>c&&oc)&&h>f&&h<=u&&e>=20&&(s=n.point.y-t.corners.top+s),i&&n.direction===t.direction&&n.corners.top>t.corners.top&&n.corners.top-t.corners.bottom>=20&&(s=(n.corners.top-t.corners.bottom)/2),p=Fn(n.point,s,270);break;case"Right":(h>f&&hf)&&a=c&&e>=20&&(s=t.corners.right-n.point.x+s),i&&n.direction===t.direction&&n.corners.right=20&&(s=(t.corners.left-n.corners.right)/2),p=Fn(n.point,s,0);break;case"Bottom":(o>c&&oc)&&l=f&&e>=20&&(s=t.corners.bottom-n.point.y+s),i&&n.direction===t.direction&&n.corners.bottom=20&&(s=(t.corners.top-n.corners.bottom)/2),p=Fn(n.point,s,90)}r=[n.point,p];var g=void 0;if("Top"===n.direction||"Bottom"===n.direction){var v=n.direction;n.direction=p.x>t.point.x?"Left":"Right",n.point=p,r=TI(n,t,v,r,g=i?.5*Math.abs(p.x-t.point.x):g,i)}else v=n.direction,n.direction=p.y>t.point.y?"Top":"Bottom",n.point=p,r=TI(n,t,v,r,g=i?.5*Math.abs(p.y-t.point.y):g,i);return r}(f,p,u,g)),l}(n,a,t,e,i,r),"Bezier"===n.type&&function Rre(n,t,e){if("Bezier"===n.type)if(0===n.segments.length){var i=e[0],r=e[e.length-1];if(t===Ae.One){var s=Math.min(20,.5*R.findLength(i,r)),o={angle:Xt(i,r),distance:s},a={angle:Xt(r,i),distance:s},l=R.direction(i,r),c=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,orientation:"Left"===l||"Right"===l?"Horizontal":"Vertical"},!0);n.segments.push(c)}else if(t===Ae.Two)o={angle:Xt(i,d=e[1]),distance:.5*R.findLength(i,d)},a={angle:Xt(r,d),distance:.5*R.findLength(r,d)},l=R.direction(i,d),c=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,orientation:"Left"===l||"Right"===l?"Horizontal":"Vertical"},!0),n.segments.push(c);else if(t===Ae.Three){var d={x:.5*((u=e[1]).x+(f=e[e.length-2]).x),y:.5*(u.y+f.y)},p=(o={angle:Xt(i,u),distance:.5*R.findLength(i,u)},a={angle:Xt(d,u),distance:.5*R.findLength(d,u)},R.direction(i,u)),v=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,point:d,orientation:"Left"===p||"Right"===p?"Horizontal":"Vertical"},!0);n.segments.push(v);var y={angle:Xt(d,f),distance:.5*R.findLength(d,f)},S={angle:Xt(r,f),distance:.5*R.findLength(r,f)},b=R.direction(d,f),w=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:y,vector2:S,orientation:"Left"===b||"Right"===b?"Horizontal":"Vertical"},!0);n.segments.push(w)}else if(t===Ae.Four){var D={x:.5*((u=e[1]).x+(f=e[2]).x),y:.5*(u.y+f.y)},A={x:.5*(f.x+(C=e[3]).x),y:.5*(f.y+C.y)};o={angle:Xt(i,u),distance:.5*R.findLength(i,u)},a={angle:Xt(D,u),distance:.5*R.findLength(D,u)},p=R.direction(i,u),v=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,point:D,orientation:"Left"===p||"Right"===p?"Horizontal":"Vertical"},!0),n.segments.push(v),y={angle:Xt(D,f),distance:.5*R.findLength(D,f)},S={angle:Xt(A,f),distance:.5*R.findLength(A,f)},b=R.direction(D,f),w=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:y,vector2:S,point:A,orientation:"Left"===b||"Right"===b?"Horizontal":"Vertical"},!0),n.segments.push(w);var x={angle:Xt(A,C),distance:.5*R.findLength(A,C)},P={angle:Xt(r,C),distance:.5*R.findLength(r,C)},L=R.direction(A,C),N=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:x,vector2:P,orientation:"Left"===L||"Right"===L?"Horizontal":"Vertical"},!0);n.segments.push(N)}else if(t===Ae.Five){var u,f,C,T=e[4],z=(D={x:.5*((u=e[1]).x+(f=e[2]).x),y:.5*(u.y+f.y)},A={x:.5*(f.x+(C=e[3]).x),y:.5*(f.y+C.y)},{x:.5*(C.x+T.x),y:.5*(C.y+T.y)});o={angle:Xt(i,u),distance:.5*R.findLength(i,u)},a={angle:Xt(D,u),distance:.5*R.findLength(D,u)},p=R.direction(i,u),v=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,point:D,orientation:"Left"===p||"Right"===p?"Horizontal":"Vertical"},!0),n.segments.push(v),y={angle:Xt(D,f),distance:.5*R.findLength(D,f)},S={angle:Xt(A,f),distance:.5*R.findLength(A,f)},b=R.direction(D,f),w=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:y,vector2:S,point:A,orientation:"Left"===b||"Right"===b?"Horizontal":"Vertical"},!0),n.segments.push(w),x={angle:Xt(A,C),distance:.5*R.findLength(A,C)},P={angle:Xt(z,C),distance:.5*R.findLength(z,C)},L=R.direction(A,C),N=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:x,vector2:P,point:z,orientation:"Left"===L||"Right"===L?"Horizontal":"Vertical"},!0),n.segments.push(N);var U={angle:Xt(z,T),distance:.5*R.findLength(z,T)},B={angle:Xt(r,T),distance:.5*R.findLength(r,T)},j=R.direction(z,T),oe=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:U,vector2:B,orientation:"Left"===j||"Right"===j?"Horizontal":"Vertical"},!0);n.segments.push(oe)}else c=new fs(n,"segments",{type:"Bezier"},!0),n.segments.push(c)}else for(var ue=0;ue=13?13:n.connectorSpacing<=1?1:n.connectorSpacing}function Xt(n,t){var i=R.findLength({x:t.x,y:n.y},t),r=R.findLength(t,n),s=Math.asin(i/r);return s=180*s/Math.PI,n.xt.y&&(s=360-s):s=n.y0)for(var l=1;lc)&&(s=c,a=h),s>=0&&s<=1)break}}return a}function m3(n,t){var c,d,u,f,p,g,S,b,M,w,D,e=n.x1,i=n.y1,r=n.x2,s=n.y2,o=t.x1,a=t.y1,l=t.x2,h=t.y2;if(w=(c=s-i)*l+(u=e-r)*h+(p=r*i-e*s),0!==(M=c*o+u*a+p)&&0!==w&&y3(M,w)||(b=(d=h-a)*r+(f=o-l)*s+(g=l*a-o*h),0!==(S=d*e+f*i+g)&&0!==b&&y3(S,b)))return null;var A=c*f-d*u;return 0===A?null:(A<0?-A/2:A/2,0,{x:(D=u*g-f*p)<0?(D-0)/A:(D+0)/A,y:(D=d*p-c*g)<0?(D-0)/A:(D+0)/A})}function y3(n,t){return n*t>=0}function S3(n,t,e){switch(t.direction){case"Left":t.point.x>n.left&&(e=t.point.x-n.left>e?t.point.x-n.left+e:e);break;case"Right":t.point.xe?n.right-t.point.x+e:e);break;case"Top":t.point.y>n.top&&(e=t.point.y-n.top>e?t.point.y-n.top+e:e);break;case"Bottom":t.point.ye?n.bottom-t.point.y+e:e)}return e}function Ol(n,t){var e;switch(n.direction){case"Left":case"Right":var i={x:t.point.x,y:n.point.y};e=R.equals(n.point,i)||R.equals(t.point,i)?[n.point,t.point]:[n.point,i,t.point];break;case"Top":case"Bottom":var r={x:n.point.x,y:t.point.y};e=R.equals(n.point,r)||R.equals(t.point,r)?[n.point,t.point]:[n.point,r,t.point]}return e}function Ys(n,t,e,i,r,s){void 0===s&&(s=!1),i||(i=20),s&&t.direction!==e.direction&&(i="Left"===t.direction||"Right"===t.direction?Math.floor(.5*Math.abs(t.point.x-e.point.x)):Math.floor(.5*Math.abs(t.point.y-e.point.y)));var l,h,u,o=n.sourcePortWrapper,c=e.point.x-t.point.x,d=e.point.y-t.point.y;if(!r&&(Math.abs(c)<.001||Math.abs(d)<.001)&&void 0===e.direction)return[t.point,e.point];if(void 0===n.targetWrapper&&Math.abs(c)<=31&&Math.abs(d)<=31){if("Left"===t.direction||"Right"===t.direction?Math.abs(d)<12&&(t.direction=t.point.y>e.point.y?"Top":"Bottom"):Math.abs(c)<12&&(t.direction=t.point.x>e.point.x?"Left":"Right"),Math.abs(c)>12||Math.abs(d)>12)return Ol(t,e);i+=5}return"Left"===t.direction||"Right"===t.direction?("Right"===t.direction?(void 0!==e.direction&&"Right"===e.direction&&(i=Math.max(t.point.x,e.point.x)-t.point.x+i),t.point.x>e.point.x&&void 0===o&&(i=-i)):(void 0!==e.direction&&"Left"===e.direction&&(i=t.point.x-Math.min(t.point.x,e.point.x)+i),(t.point.x>e.point.x||void 0!==o||"Left"===t.direction)&&(i=-i)),u=e.point.y-t.point.y,l=Fn(t.point,i,0),0!=(u=e.point.y-l.y)&&(h=Fn(l,e.point.y-l.y,90))):("Top"===t.direction||"Bottom"===t.direction)&&("Bottom"===t.direction?void 0!==e.direction&&"Bottom"===e.direction&&(i=Math.max(t.point.y,e.point.y)-t.point.y+i):(void 0!==e.direction&&"Top"===e.direction&&(i=t.point.y-Math.min(t.point.y,e.point.y)+i),(t.point.y>e.point.y||void 0!==o||"Top"===t.direction)&&(i=-i)),u=e.point.x-t.point.x,l=Fn(t.point,i,90),0!=(u=e.point.x-l.x)&&(h=Fn(l,e.point.x-l.x,0))),0===u?[t.point,e.point]:[t.point,l,h,e.point]}function TI(n,t,e,i,r,s){var o;switch(void 0===r&&(r=20),void 0===s&&(s=!1),void 0===e?(n.margin={left:2,right:2,top:2,bottom:2},t.margin={left:0,right:5,top:0,bottom:5},s&&(n.margin={left:10,right:10,top:10,bottom:10},t.margin={left:10,right:10,top:10,bottom:10},"Left"===n.direction?(r=Px(n,t,e,r),n.corners.left-t.corners.right>=5&&(r=Math.abs(n.point.x-n.corners.left)+.5*Math.floor(n.corners.left-t.corners.right))):"Right"===n.direction?(r=zx(n,t,r,e),t.corners.left-n.corners.right>=5&&(r=Math.abs(n.point.x-n.corners.right)+.5*Math.floor(t.corners.left-n.corners.right))):"Top"===n.direction?(r=kx(n,t,e,r),n.corners.top-t.corners.bottom>=5&&(r=Math.abs(n.point.y-n.corners.top)+.5*Math.floor(n.corners.top-t.corners.bottom))):"Bottom"===n.direction&&(r=Rx(n,t,r,e),t.corners.top-n.corners.bottom>=5&&(r=Math.abs(n.point.y-n.corners.bottom)+.5*Math.floor(t.corners.top-n.corners.bottom))))):("Bottom"===n.direction?s?t.corners.top-n.corners.bottom<20&&(r=t.corners.bottom-n.point.y+25):t.corners.top>n.corners.bottom&&t.corners.top-n.corners.bottom<20&&(r=(t.corners.top-n.corners.bottom)/2):"Top"===n.direction?s?n.corners.top-t.corners.bottom<20&&(r=n.point.y-t.corners.top+25):t.corners.bottomn.corners.right&&t.corners.left-n.corners.right<20&&(r=(t.corners.left-n.corners.right)/2):"Left"===n.direction&&(s?n.corners.left-t.corners.right<20&&(r=n.point.x-t.corners.left+25):t.corners.rightt.point.y||"Top"===t.direction&&n.point.yt.point.x||"Left"===t.direction&&n.point.xh||e.corners.top-e.margin.top<=i.point.y&&e.corners.bottom+e.margin.bottom>=i.point.y))if(!s||"Top"!==e.direction&&"Bottom"!==e.direction)c=Math.min(Math.abs(i.corners.left-e.corners.right)/2,20),h=e.corners.right-n.x+c;else{var c=Math.abs(i.corners.left-e.corners.right)/2;h=e.corners.right-n.x+c}else h="Top"===e.direction&&n.y>i.point.y||"Bottom"===e.direction&&n.y=e.corners.left-e.margin.left&&n.x<=e.corners.right+e.margin.right?Math.min(i.corners.left,e.corners.left)-n.x-20:i.corners.left-n.x-20;break;case"Right":if(e.corners.left-e.margin.left>i.corners.right+i.margin.right&&(e.corners.left-e.margin.right-i.corners.right>h||e.corners.top-e.margin.top<=i.point.y&&e.corners.bottom+e.margin.bottom>=i.point.y))if(!s||"Top"!==e.direction&&"Bottom"!==e.direction)c=Math.min(Math.abs(e.corners.left-i.corners.right)/2,20),h=e.corners.left-n.x-c;else{c=Math.abs(e.corners.left-i.corners.right)/2;h=e.corners.left-n.x-c}else h="Top"===e.direction&&n.y>i.point.y||"Bottom"===e.direction&&n.y=e.corners.left-e.margin.left&&n.x<=e.corners.right+e.margin.right?Math.max(i.corners.right,e.corners.right)-n.x+20:i.corners.right-n.x+20}o=Fn(n,h,0),a=Fn(o,i.point.y-n.y,90),l=i.point}else if("vertical"===t){switch(i.direction){case"Top":e.corners.bottom+e.margin.bottomh||e.corners.left-e.margin.left<=i.point.x&&e.corners.right+e.margin.right>=i.point.x)?!s||"Right"!==e.direction&&"Left"!==e.direction?(c=Math.min(Math.abs(i.corners.top-e.corners.bottom)/2,20),h=e.corners.bottom-n.y+c):(c=Math.abs(i.corners.top-e.corners.bottom)/2,h=e.corners.bottom-n.y+c):h="Left"===e.direction&&n.x>i.point.x||"Right"===e.direction&&n.x=e.corners.top-e.margin.top&&n.y<=e.corners.bottom+e.margin.bottom?Math.min(i.corners.top,e.corners.top)-n.y-20:i.corners.top-n.y-20;break;case"Bottom":e.corners.top-e.margin.top>i.corners.bottom+i.margin.bottom&&(e.corners.top-e.margin.top-i.corners.bottom>h||e.corners.left-e.margin.left<=i.point.x&&e.corners.right+e.margin.right>=i.point.x)?!s||"Right"!==e.direction&&"Left"!==e.direction?(c=Math.min(Math.abs(e.corners.top-i.corners.bottom)/2,20),h=e.corners.top-n.y-c):(c=Math.abs(e.corners.top-i.corners.bottom)/2,h=e.corners.top-n.y-c):h="Left"===e.direction&&n.x>i.point.x||"Right"===e.direction&&n.x=e.corners.top-e.margin.top&&n.y<=e.corners.bottom+e.margin.bottom?Math.max(i.corners.bottom,e.corners.bottom)-n.y+20:i.corners.bottom-n.y+20}o=Fn(n,h,90),a=Fn(o,i.point.x-n.x,0),l=i.point}r.push(o),r.push(a),r.push(l)}function kx(n,t,e,i){return n.corners.top-n.margin.top>t.corners.top+t.margin.top&&n.corners.top-n.margin.top<=t.corners.bottom+t.margin.bottom?(("Right"===t.direction&&n.point.xt.point.x)&&(i+=n.corners.top-t.corners.top),i+=n.point.y-n.corners.top):i+=void 0!==e&&"Left"!==e&&"Right"===t.direction&&n.point.xt.corners.left-t.margin.left&&n.corners.left-n.margin.left<=t.corners.right+t.margin.right?(("Bottom"===t.direction&&n.point.yt.point.y)&&(i+=n.corners.left-t.corners.left),i+=n.point.x-n.corners.left):i+=void 0!==e&&"Top"!==e&&"Bottom"===t.direction&&n.point.y=t.corners.left-t.margin.left?(("Bottom"===t.direction&&n.point.yt.point.y)&&(e+=t.corners.right-n.corners.right),e+=n.corners.right-n.point.x):e+=void 0!==i&&"Top"!==i&&"Bottom"===t.direction&&n.point.y=t.corners.top-t.margin.top?(("Right"===t.direction&&n.point.xt.point.x)&&(e+=t.corners.bottom-n.corners.bottom),e+=n.corners.bottom-n.point.y):e+=void 0!==i&&"Left"!==i&&"Right"===t.direction&&n.point.xp&&d=u&&d=f&&d<=p?"Left":"Right"}function _n(n){switch(n){case"Top":return"Bottom";case"Bottom":return"Top";case"Left":return"Right";case"Right":return"Left"}return"auto"}var w3=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Ac=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},AI=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return w3(t,n),Ac([I()],t.prototype,"width",void 0),Ac([I()],t.prototype,"height",void 0),t}(Ee),Bre=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return w3(t,n),Ac([I()],t.prototype,"width",void 0),Ac([I()],t.prototype,"height",void 0),Ac([I()],t.prototype,"fit",void 0),Ac([I()],t.prototype,"description",void 0),Ac([I()],t.prototype,"template",void 0),Ac([I()],t.prototype,"tooltip",void 0),t}(Ee),Fre=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),kl=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},C3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Fre(t,n),kl([I("")],t.prototype,"id",void 0),kl([I(Number.MIN_VALUE)],t.prototype,"zIndex",void 0),kl([re({},Jn)],t.prototype,"margin",void 0),kl([I(!0)],t.prototype,"visible",void 0),kl([re({},Td)],t.prototype,"tooltip",void 0),kl([I(!1)],t.prototype,"excludeFromLayout",void 0),kl([I()],t.prototype,"addInfo",void 0),kl([I("None")],t.prototype,"flip",void 0),kl([I("All")],t.prototype,"flipMode",void 0),kl([re({},Bre)],t.prototype,"symbolInfo",void 0),t}(Ee),_re=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),es=function(n){function t(e,i,r,s){var o=n.call(this)||this;return o.data="",o.nodeId="",o.annotationId="",o.diagramId="",o.diagramId=i,o.nodeId=e,o.annotationId=r,o.templateFn=UF(s),o}return _re(t,n),t.prototype.getNodeTemplate=function(){return this.templateFn},Object.defineProperty(t.prototype,"content",{get:function(){return this.data},set:function(e){this.data=e,this.canReset||(this.canReset=!0,this.isTemplate||(this.template=Hh(this,!0)),this.canReset=!1,this.isDirt=!0)},enumerable:!0,configurable:!0}),t}(hs),Hx=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),cs=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},E3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Hx(t,n),cs([I("")],t.prototype,"id",void 0),cs([I("transparent")],t.prototype,"fill",void 0),cs([I("black")],t.prototype,"iconStrokeColor",void 0),cs([I(0)],t.prototype,"iconStrokeWidth",void 0),cs([I(!0)],t.prototype,"visibility",void 0),cs([I(10)],t.prototype,"width",void 0),cs([I(10)],t.prototype,"height",void 0),cs([I("transparent")],t.prototype,"handleStrokeColor",void 0),cs([I(1)],t.prototype,"handleStrokeWidth",void 0),cs([I("")],t.prototype,"pathData",void 0),cs([I(0)],t.prototype,"cornerRadius",void 0),cs([re({left:0,right:0,top:0,bottom:0},Jn)],t.prototype,"padding",void 0),cs([re({},Td)],t.prototype,"tooltip",void 0),t}(Ee),D3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Hx(t,n),cs([re({x:0,y:0},R)],t.prototype,"offset",void 0),cs([re({},Jn)],t.prototype,"margin",void 0),t}(E3),LI=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Hx(t,n),cs([I(.5)],t.prototype,"offset",void 0),cs([I("Center")],t.prototype,"alignment",void 0),cs([re({x:0,y:0},R)],t.prototype,"displacement",void 0),t}(E3);function Ad(n){return n?n instanceof Kn||n instanceof Or?n.constraints&Nr.Select:n instanceof de?n.constraints&qe.Select:n.constraints&ie.Select:1}function ro(n){return n?n instanceof Kn||n instanceof Or?n.constraints&Nr.Drag:n instanceof de?n.constraints&qe.Drag:n instanceof ti?1:n.constraints&ie.Drag:1}function Ure(n,t){return n instanceof de?n.constraints&qe.PointerEvents:n.constraints&ie.PointerEvents}function NI(n){return n instanceof de?n.constraints&qe.Delete:n.constraints&ie.Delete}function OI(n){return n.constraints&qe.DragSourceEnd}function kI(n){return n.constraints&qe.DragTargetEnd}function PI(n){return n.constraints&qe.DragSegmentThumb}function zI(n){return n instanceof Kn||n instanceof Or?n.constraints&Nr.Rotate:n.constraints&ie.Rotate}function RI(n){return n.constraints&ie.Shadow}function ua(n){return n instanceof te&&n.constraints&ie.InConnect?n.constraints&ie.InConnect:0}function kh(n){return n&&n.constraints&&!(n.constraints&ai.None)&&n.constraints&ai.InConnect?n.constraints&ai.InConnect:0}function Ph(n){return n instanceof te&&n.constraints&ie.OutConnect?n.constraints&ie.OutConnect:0}function Ld(n){return n&&n.constraints&&!(n.constraints&ai.None)&&n.constraints&ai.OutConnect?n.constraints&ai.OutConnect:0}function Pl(n,t){var e=0;return n instanceof Kn||n instanceof Or?e=n.constraints&Nr.Resize:n&&("SouthEast"===t?e=n.constraints&ie.ResizeSouthEast:"East"===t?e=n.constraints&ie.ResizeEast:"NorthEast"===t?e=n.constraints&ie.ResizeNorthEast:"South"===t?e=n.constraints&ie.ResizeSouth:"North"===t?e=n.constraints&ie.ResizeNorth:"SouthWest"===t?e=n.constraints&ie.ResizeSouthWest:"West"===t?e=n.constraints&ie.ResizeWest:"NorthWest"===t&&(e=n.constraints&ie.ResizeNorthWest)),e}function HI(n){return n instanceof de?n.constraints&qe.AllowDrop:n.constraints&ie.AllowDrop}function Ds(n){return n.constraints&nt.Virtualization}function _v(n){return n.tool&ni.SingleSelect}function Uv(n){return n.tool&ni.MultipleSelect}function Lc(n){return n.tool&ni.ZoomPan}function BI(n){return n.tool&ni.ContinuousDraw}function x3(n){return n.tool&ni.DrawOnce}function FI(n){return n.tool&ni.SingleSelect||n.tool&ni.MultipleSelect}function jv(n){return n.constraints&nt.UserInteraction}function T3(n){return n.constraints&nt.ZoomTextEdit}function Vv(n){return function Gre(n){return n.constraints&nt.ApiUpdate}(n)||n.diagramActions&ee.ToolAction}function Bx(n,t){return n.constraints&ai.Draw}function Fx(n,t){return n.constraints&ai.Drag}function _I(n){return!(n&Ga.DrawSelectorBorder)}function A3(n){return!!(n&Ga.PreventRenderSelector)}var _x=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Wv=function(n){function t(){var e=null!==n&&n.apply(this,arguments)||this;return e.childTable=[],e.cellStyle={},e.desiredRowHeight=[],e.desiredCellWidth=[],e}return _x(t,n),t.prototype.rowDefinitions=function(){return this.rowDefns},t.prototype.columnDefinitions=function(){return this.colDefns},t.prototype.addObject=function(e,i,r,s,o){if(this.rows.length>=i){var a=this.rows[parseInt(i.toString(),10)];if(a.cells.length>r){o=o||1,s=s||1;var l=a.cells[parseInt(r.toString(),10)];l.columnSpan=Math.max(o,l.columnSpan),l.rowSpan=Math.max(s,l.rowSpan);var h=new Jre;(h=e).rowId=i,h.columnId=r,h.columnSpan=o,this.childTable[h.id]=h,this.addObjectToCell(h,l)}}},t.prototype.addObjectToCell=function(e,i){i.children||(i.children=[]),e.style.strokeColor="black",e.style.strokeWidth=1,i.children.push(e)},t.prototype.updateProperties=function(e,i,r,s){this.offsetX=e,this.offsetY=i,this.width=r,this.height=s},t.prototype.setDefinitions=function(e,i){this.rowDefns=e,this.colDefns=i,this.children=[],this.rows=this.rows||[];for(var r=0;r0){for(var h=0;hi&&this.updateRowHeight(e,l,!1)}},t.prototype.setTextRefresh=function(e){if(e.children&&e.children.length)for(var i=e.children,r=0;ri&&this.updateColumnWidth(e,a,!1)}},t.prototype.calculateCellWidth=function(e){for(var i,r,s,o=0;os.bounds.width&&(0===s.children.length||void 0===s.children[0].maxWidth)?s.outerBounds.width:s.bounds.width,i=i?is.bounds.height?s.outerBounds.height:s.bounds.height,i=i?i0?e.children[0]:void 0;if(a&&1===e.columnSpan){o="Width"===i?a.bounds.right:a.bounds.bottom,s||(s="Width"===i?a.bounds.width:a.bounds.height);for(var l=0;lo){var d=c-o+("Width"===i?a.bounds.width:a.bounds.height);s&&(s=s0?this.rowDefns.splice(e,0,i):this.rowDefns.push(i);var s=new L3;s.cells=[],(new Nd).width=this.width,this.addCellInRow(this.colDefns,i,s),e>this.rows.length-1?this.rows.push(s):this.rows.splice(e,0,s),r&&(this.measure(new me(this.width,this.height)),this.arrange(this.desiredSize))},t.prototype.addColumn=function(e,i,r){var s,o,a,l,h=this.rows;this.colDefns.length>0?this.colDefns.splice(e,0,i):this.colDefns.push(i),void 0!==this.width&&(this.width+=i.width);for(var c=0;cs.cells.length-1?s.cells.push(l):s.cells.splice(e,0,l),this.children.push(l);r&&(this.measure(new me(this.width,this.height)),this.arrange(this.desiredSize))},t.prototype.removeRow=function(e){var i,r,o=this.rows[parseInt(e.toString(),10)];this.height-=this.rowDefns[parseInt(e.toString(),10)].height;for(var a=0;a0){var r=0,s=0;i=new me(0,0),this.calculateSize();for(var o=0,a=this.rows;o0){for(var o=this.offsetX-e.width*this.pivot.x,a=this.offsetY-e.height*this.pivot.y,l=o,h=0,c=this.rows;h1&&this.children.splice(this.children.indexOf(p)+1,p.columnSpan-1),p.rowSpan>1)for(y=s,S=0;y+p.rowSpan-10){for(var c=0;c0?1:0,v=0;v0||a.outEdges.length>0))for(f=a.inEdges.concat(a.outEdges),s=0;s0)for(o=0;o1)for(a=1;a0))if(h=n.wrapper.children[0],"Horizontal"===e.orientation)for(o=e.header&&e.hasHeader?h.rows[1]:h.rows[0],r=0;r0){var e=void 0;t.lineRoutingModule&&t.constraints&nt.LineRouting&&t.lineRoutingModule.renderVirtualRegion(t,!0);for(var i=0;i0?o+1:o)].height=t.wrapper.height;else if(t.isPhase)for(l[t.rowIndex-o].offset=t.wrapper.height,p=0;p0?1:0)].width=t.wrapper.width}function jI(n,t){var i=n.shape,r=i.header&&i.hasHeader?1:0;return"Horizontal"===i.orientation?t.rowIndex-(r+=i.phases.length>0?1:0):t.columnIndex-(i.phaseSize&&i.phases.length>0?1:0)}function VI(n){var t=0,e=n.shape;return"Horizontal"===e.orientation&&(t=e.header&&e.hasHeader?1:0),e.phases.length>0&&e.phaseSize&&(t+=1),t}function WI(n,t,e,i){var r=n.shape;if(r.phases.length>0){var s=t.nameTable[r.phases[parseInt(i.toString(),10)].header.id];s&&s.maxWidth0?u+1:u);var w=Nc(n,o),C=void 0!==i?i:l.lanes.length;if(u+=C,r={element:M,cause:n.diagramActions,diagramAction:n.getDiagramAction(n.diagramActions),state:"Changing",type:"Addition",cancel:!1,laneIndex:C},n.triggerEvent(Ce.collectionChange,r),!r.cancel){if(c){var D=new Yv;D.height=e.height,o.addRow(u,D,!1),s.height=void 0!==s.height?s.height+e.height:s.height,s.wrapper.height=o.height=s.height}else{var A=new Nd;A.width=e.width,o.addColumn(C+1,A,!1),s.width&&(s.width+=e.width,s.wrapper.width=o.width=s.width),n.diagramActions&ee.UndoRedo||(o.rows[0].cells[0].columnSpan+=1)}n.diagramActions&ee.UndoRedo||(M.id=""===M.id?Qe():M.id),void 0!==i?l.lanes.splice(i,0,M):l.lanes.push(M),r={element:M,cause:n.diagramActions,diagramAction:n.getDiagramAction(n.diagramActions),state:"Changed",type:"Addition",cancel:!1,laneIndex:C},n.triggerEvent(Ce.collectionChange,r),O3(o,n,s,u,C,c),h="Horizontal"===l.orientation?n.nameTable[o.rows[parseInt(u.toString(),10)].cells[0].children[0].id]:l.header&&l.hasHeader?n.nameTable[o.rows[1].cells[parseInt(u.toString(),10)].children[0].id]:n.nameTable[o.rows[0].cells[parseInt(u.toString(),10)].children[0].id],n.diagramActions&ee.UndoRedo||(d={type:"LaneCollectionChanged",changeType:"Insert",undoObject:$(M),redoObject:$(h),category:"Internal"},n.addHistoryEntry(d)),$f(n,s,"Horizontal"===l.orientation?u:l.header&&l.hasHeader?1:0),qf(s),Oc(n,s);var P=!1;if((f=e.children)&&f.length>0)for(p=0;p0){var o=t.children[0],a=n.nameTable[o.id];(function ane(n,t,e){return n.left-(e.left||0)<=t.x&&n.right+(e.right||0)>=t.x&&n.top-(e.top||0)<=t.y&&n.bottom+(e.bottom||0)>=t.y})(o.bounds,e,r)&&(n.addChild(a,i),s=!0)}return s}function lne(n,t,e){if("SwimLane"===t.shape.type){var i=void 0,r=void 0,s=void 0,a=void 0,l=void 0,h=void 0,c=t.wrapper.bounds.x,d=t.wrapper.bounds.y,u=t.shape,f=u.padding,p=u.phases,g=void 0,v=t.wrapper.children[0],y="Horizontal"===u.orientation;if(i=u.header&&u.hasHeader?0:-1,u.phases.length>0&&(i+=1),e.offset>(y?u.lanes[0].header.width:u.lanes[0].header.height)){for(h=0;he.offset){if(g=h>0?e.offset-(h>0?p[h-1]:s).offset:e.offset,y){var b=v.columnDefinitions()[parseInt(h.toString(),10)];b.width-=g,(a=n.nameTable[u.phases[parseInt(h.toString(),10)].header.id]).maxWidth=a.wrapper.maxWidth=b.width,v.updateColumnWidth(h,b.width,!1);var M=new Nd;M.width=g,l=h,v.addColumn(h,M,!1);break}var w=v.rowDefinitions()[h+i];w.height-=g,a=n.nameTable[u.phases[parseInt(h.toString(),10)].header.id],v.updateRowHeight(h+i,w.height,!1);var C=new Yv;C.height=g,l=h,v.addRow(h+i,C,!1);break}if(n.diagramActions&ee.UndoRedo&&void 0===l&&(D=n.historyManager.currentEntry.next).isLastPhase&&function hne(n,t,e,i,r,s){var a=t.shape.phases[n-2],l=e.previousPhase.offset;if(r){var h=i.columnDefinitions()[n-1],c=new Nd;n>1?(c.width=h.width-(l-a.offset),h.width=l-a.offset):(c.width=h.width-l,h.width=l),i.updateColumnWidth(n-1,h.width,!1),i.addColumn(n,c,!1)}else{h=i.rowDefinitions()[parseInt(n.toString(),10)];var d=new Yv;n>1?(d.height=e.undoObject.offset-l,h.height=l-a.offset):(d.height=h.height-l,h.height=l),i.updateRowHeight(n,h.height,!1),i.addRow(1+n,d,!1)}}(l=p.length,t,D,v,y),l>=0){var A=new db(t.shape,"phases",e,!0);if(n.diagramActions&ee.UndoRedo||(A.id+=Qe()),u.phases.splice(l,0,A),Ux(v,n,t,i,y,l),y){if(r=n.nameTable[v.rows[parseInt(i.toString(),10)].cells[parseInt(l.toString(),10)].children[0].id],0===l&&u.header&&u.hasHeader){v.rows[0].cells[0].children=v.rows[0].cells[1].children,v.rows[0].cells[1].children=[];for(var x=v.rows[0],P=0;Pl+1){var O=n.nameTable[v.rows[parseInt(i.toString(),10)].cells[l+1].children[0].id];v.updateColumnWidth(l+1,L[l+1].width,!0,f),O.maxWidth=O.wrapper.maxWidth=L[l+1].width}t.width=t.wrapper.width=t.wrapper.children[0].width=v.width}else{r=n.nameTable[v.rows[i+l].cells[0].children[0].id];var N=v.rowDefinitions(),T=N[i+l].height;(function dne(n,t,e,i,r){for(var o,a,l=e.rows[parseInt(i.toString(),10)],h=e.rows[i+1],c=e.rows[i-1],d=1;di+l+1&&v.updateRowHeight(i+l+1,T=N[i+l+1].height,!0,f),t.height=t.wrapper.height=t.wrapper.children[0].height=v.actualSize.height}if(qf(t),t.width=t.wrapper.actualSize.width,Oc(n,t),n.drag(t,c-t.wrapper.bounds.x,d-t.wrapper.bounds.y),UI(t,n),n.commandHandler.select(r),!(n.diagramActions&ee.UndoRedo)){var D={type:"PhaseCollectionChanged",changeType:"Insert",undoObject:$(A),redoObject:$(r),category:"Internal"};n.addHistoryEntry(D)}n.updateDiagramObject(t)}}}}function H3(n,t,e,i,r,s,o){var a,l,p,h=t.shape,c="Horizontal"===h.orientation,d=t.wrapper.children[0],g=c?s:o;e?(a=c?e.bounds.x+e.bounds.width:e.bounds.x,l=c?e.bounds.y:e.bounds.y+e.bounds.height):(a=d.bounds.x,l=r.bounds.y);var v=new Ne(a,l,i.desiredCellWidth,i.desiredCellHeight),S=Qv(n,0,t,{id:t.id+(c?h.lanes[g-2]:h.lanes[g-1]).id+Qe()[0],rowIndex:s,columnIndex:o,width:i.minWidth,height:i.minHeight,style:(c?h.lanes[g-2]:h.lanes[g-1]).style,constraints:ie.Default|ie.AllowDrop,container:{type:"Canvas",orientation:c?"Horizontal":"Vertical"}},!1,!1,!0);if(S.children[0].isCalculateDesiredSize=!1,d.addObject(S,s,o),r&&r.children&&r.children.length)for(p=0;p1)for(var p=1;ph.margin.left&&(h.margin.left=f)):(h.margin.top-=e.desiredCellHeight,f>h.margin.top&&(h.margin.top=f)))}(n,r,i,v,S,c,e)}function B3(n,t,e){if("SwimLane"===t.shape.type&&("ResizeSouth"===e||"ResizeEast"===e)){var i=t.shape,r=t.wrapper.children[0],s=void 0,o=void 0;"ResizeSouth"===e?"Vertical"===i.orientation?s=r.rows[r.rows.length-1].cells[0]:(o=r.rows.length-1,s=r.rows[parseInt(o.toString(),10)].cells[r.rows[parseInt(o.toString(),10)].cells.length-1]):(o=i.header&&i.hasHeader?1:0,s=r.rows[parseInt(o.toString(),10)].cells[r.rows[parseInt(o.toString(),10)].cells.length-1]),n.commandHandler.select(n.nameTable[s.children[0].id])}}function YI(n,t,e,i,r,s){var o,a,l,c,u,f,p,d=Qe(),g=n.shape,v=g.phases,y=n.offsetX-n.wrapper.actualSize.width/2,S=n.offsetY-n.wrapper.actualSize.height/2;if("Vertical"===g.orientation&&(S+=g.header&&g.hasHeader?g.header.height:0),!s)for(r||(n.id+=d,g&&g.header&&g.hasHeader?g.header.id+=d:g.header=void 0),o=0;v&&o0&&s.columnIndex>0||s.isLane)?(a=function bne(n,t,e){for(var i=new Ne,r="SwimLane"===n.shape.type?n.wrapper.children[0].rows:n.wrapper.rows,s=e?1:0;s=0;a--)i?i.id===o.children[parseInt(a.toString(),10)].id&&o.children.splice(a,1):(n.removeDependentConnector(o.children[parseInt(a.toString(),10)]),n.diagramActions&ee.UndoRedo||(n.diagramActions=n.diagramActions|ee.UndoRedo,s=!0),n.remove(o.children[parseInt(a.toString(),10)]),o.children.splice(a,1),s&&(n.diagramActions=n.diagramActions&~ee.UndoRedo))}function fne(n){return n.children[0]}function qv(n,t){t&&(n.nodes.splice(n.nodes.indexOf(t),1),n.removeFromAQuad(t),n.removeObjectsFromLayer(t),delete n.nameTable[t.id],n.removeElements(t))}function _3(n,t,e,i){var r;if("SwimLane"===e.shape.type){var s=e.shape,o=void 0;if(1===s.lanes.length)n.remove(e);else{var a=e.wrapper.bounds.x,l=e.wrapper.bounds.y,h=void 0,c=void 0,d=void 0,u=void 0,p=e.wrapper.children[0];if(o=i?s.lanes.indexOf(i):jI(e,t),r={element:t,cause:n.diagramActions,diagramAction:n.getDiagramAction(n.diagramActions),state:"Changing",type:"Removal",cancel:!1,laneIndex:o},n.triggerEvent(Ce.collectionChange,r),!r.cancel){var g=s.lanes[parseInt(o.toString(),10)],v=g.children;g.children=[];for(var y=0;y0)for(u=0;u0)for(u=0;u0)for(e=0;e1){c===l.phases.length-1&&(o=!0,a=$(l.phases[c-1]));var u=$(l.phases[parseInt(c.toString(),10)]);if(l.phases.splice(c,1),!(n.diagramActions&ee.UndoRedo)){var f={type:"PhaseCollectionChanged",changeType:"Remove",undoObject:u,previousPhase:a,redoObject:$(t),category:"Internal",isLastPhase:o};n.addHistoryEntry(f)}"Horizontal"===l.orientation?function gne(n,t,e,i){var r,s,o,a,l,h,c,d,u,f,p,g;for(i=void 0!==i?i:e.columnIndex,c=0;c1&&(s=r.cells[parseInt(i.toString(),10)],l=(o=r.cells.length-1===i?r.cells[i-1]:r.cells[i+1]).children[0],s.children.length>0))if(p=n.nameTable[(a=s.children[0]).id],0===o.children.length&&s.children.length>0)o.children=s.children,o.columnSpan=s.columnSpan-1;else{for(d=0;d0){var M=s.children[0],w=n.nameTable[M.id];if(i=e.x&&a.bounds.y<=e.y&&a.bounds.bottom>=e.y){var l=void 0,h=a.bounds.y,c=a.bounds.x,d=n.nameTable[r.parentId]||r;if("SwimLane"===d.shape.type)o=Zv(r,d,t,n,!0);else{var f=n.nameTable[r.parentId]||r,p=f.shape;l=f.wrapper,a.actualSize.widtha.outerBounds.x)&&(void 0!==r.rowIndex?(l.updateColumnWidth(r.columnIndex,a.outerBounds.width,!0),"Horizontal"===p.orientation&&p.phaseSize&&WI(f,n,a,r.columnIndex),Oc(n,f),n.drag(f,c-a.bounds.x,h-a.bounds.y)):n.scale(r,1+(a.outerBounds.width-a.actualSize.width)/a.actualSize.width,1,a.outerBounds.xa.outerBounds.y)&&(void 0!==r.rowIndex?(l.updateRowHeight(r.rowIndex,a.outerBounds.height,!0),n.drag(f,c-a.bounds.x,h-a.bounds.y)):n.scale(r,1,1+(a.outerBounds.height-a.actualSize.height)/a.actualSize.height,a.outerBounds.y=e.x&&a.bounds.y<=e.y&&a.bounds.bottom>=e.y)&&!(t.constraints&ie.AllowMovingOutsideLane)){var l=$(t);n.clearSelection(),W3(n,t),t.parentId="",t.parentObj=n,t.propName="nodes";var h={type:"ChildCollectionChanged",category:"Internal",undoObject:l,redoObject:$(t)};n.addHistoryEntry(h),n.commandHandler.isContainer&&(n.commandHandler.isContainer=!1,n.endGroupAction()),Y3(t,n)}n.protectPropertyChange(o)}}function QI(n,t){var e,i,r;return n.enableServerDataBinding(!1),ce()||(n.selectedObject.helperObject?r=n.selectedObject.helperObject:(n.selectedItems.nodes.length>0||n.selectedItems.connectors.length>0)&&(t instanceof ti&&t.nodes.length+t.connectors.length===1?(e=t.nodes.length>0?t.nodes[0]:t.connectors[0],i=n.selectedItems.wrapper.children[0]):(e=t,i=n.selectedItems.wrapper),n.selectedObject.actualObject=e,!n.currentSymbol&&(e.isLane&&Yx(e,n)&&Dn(n,e)||!e.isLane&&Dn(n,e)||n.constraints&nt.LineRouting&&n.selectedItems.nodes.length>0))&&(r=function Mne(n,t){for(var e,i={},r=0,s=Object.keys(t);r=t.x-e&&n.x<=t.x+e&&n.y>=t.y-e&&n.y<=t.y+e}function $a(n){return n.selectedItems.nodes.length>0||n.selectedItems.connectors.length>0}function G3(n){return 1===n.selectedItems.connectors.length&&!n.selectedItems.nodes.length}function _r(n,t,e,i){if(void 0===e&&(e=!0),t instanceof ti)return!0;if(t instanceof te)for(;t;){if(-1!==n.selectedItems.nodes.indexOf(t)&&void 0===n.selectedItems.annotation)return!0;if(e)break;t=n.nameTable[t.parentId]}else if(t instanceof de){if(-1!==n.selectedItems.connectors.indexOf(t)&&void 0===n.selectedItems.annotation)return!0}else if((t instanceof Kn||t instanceof Or)&&n.selectedItems.annotation&&n.selectedItems.wrapper.children[0].id===i.id)return!0;return!1}var Qx={None:"default",Rotate:"crosshair",Select:"default",Drag:"move",ResizeWest:"w-resize",ResizeEast:"e-resize",ResizeSouth:"s-resize",ResizeNorth:"n-resize",Draw:"crosshair",PortDraw:"crosshair",ResizeNorthEast:"ne-resize",ResizeNorthWest:"nw-resize",ResizeSouthEast:"se-resize",ResizeSouthWest:"sw-resize",ConnectorSourceEnd:"move",ConnectorTargetEnd:"move",BezierSourceThumb:"move",BezierTargetThumb:"move",OrthoThumb:"move",SegmentEnd:"move",Pan:"grab",Hyperlink:"pointer",PortDrag:"pointer",LabelSelect:"pointer",LabelDrag:"move",LabelRotate:"crosshair",LabelResizeWest:"w-resize",LabelResizeEast:"e-resize",LabelResizeSouth:"s-resize",LabelResizeNorth:"n-resize",LabelResizeNorthEast:"ne-resize",LabelResizeNorthWest:"nw-resize",LabelResizeSouthEast:"se-resize",LabelResizeSouthWest:"sw-resize"},ds=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),kd=function(n,t,e,i){return new(e||(e=Promise))(function(r,s){function o(h){try{l(i.next(h))}catch(c){s(c)}}function a(h){try{l(i.throw(h))}catch(c){s(c)}}function l(h){h.done?r(h.value):new e(function(c){c(h.value)}).then(o,a)}l((i=i.apply(n,t||[])).next())})},Pd=function(n,t){var i,r,s,o,e={label:0,sent:function(){if(1&s[0])throw s[1];return s[1]},trys:[],ops:[]};return o={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function a(h){return function(c){return function l(h){if(i)throw new TypeError("Generator is already executing.");for(;e;)try{if(i=1,r&&(s=2&h[0]?r.return:h[0]?r.throw||((s=r.return)&&s.call(r),0):r.next)&&!(s=s.call(r,h[1])).done)return s;switch(r=0,s&&(h=[2&h[0],s.value]),h[0]){case 0:case 1:s=h;break;case 4:return e.label++,{value:h[1],done:!1};case 5:e.label++,r=h[1],h=[0];continue;case 7:h=e.ops.pop(),e.trys.pop();continue;default:if(!(s=(s=e.trys).length>0&&s[s.length-1])&&(6===h[0]||2===h[0])){e=0;continue}if(3===h[0]&&(!s||h[1]>s[0]&&h[1]-1&&(r=i.fixedUserHandles[parseInt(o.toString(),10)]);this.commandHandler.triggerEvent(Ce.fixedUserHandleClick,{fixedUserHandle:r,element:e.source}),n.prototype.mouseUp.call(this,e)},t}(us),zd=function(n){function t(e,i){var r=n.call(this,e,!0)||this;return r.isConnected=!1,r.endPoint=i,r}return ds(t,n),t.prototype.mouseDown=function(e){return kd(this,void 0,void 0,function(){var r,s,o,a,l;return Pd(this,function(h){if(this.inAction=!0,this.undoElement=void 0,this instanceof pa||(this.undoElement=$(e.source)),n.prototype.mouseDown.call(this,e),e.source&&e.source.connectors&&(this.oldConnector=$(r=e.source.connectors[0])),"BezierSourceThumb"===this.endPoint||"BezierTargetThumb"===this.endPoint)for(s=0;s0))},t.prototype.endAction=function(){n.prototype.endAction.call(this),this.prevPosition=null,this.endPoint=null},t}(us),fa=function(n){function t(e,i){var r=n.call(this,e,!0)||this;return r.currentTarget=null,r.isStartAction=!1,r.canCancel=!1,r.canTrigger=!1,r.objectType=i,r}return ds(t,n),t.prototype.mouseDown=function(e){if(e.source instanceof te||e.source instanceof de){var i=this.commandHandler.getSelectedObject();this.commandHandler.selectObjects([e.source],e.info&&e.info.ctrlKey,i);var r={nodes:[],connectors:[]};e.source instanceof te?r.nodes.push($(e.source)):r.connectors.push($(e.source)),this.undoElement=$(r)}else this.undoElement=$(e.source);this.undoParentElement=this.commandHandler.getSubProcess(e.source),"Port"===this.objectType&&(this.portId=e.sourceWrapper.id),this.commandHandler.insertBlazorConnector(e.source),n.prototype.mouseDown.call(this,e),this.initialOffset={x:0,y:0}},t.prototype.mouseUp=function(e,i){return kd(this,void 0,void 0,function(){var s,o,a,l,h,c,d,u,p,g,v,y,S,b,M;return Pd(this,function(w){if(this.checkPropertyValue(),a=!1,h={nodes:[],connectors:[]},"Port"!==this.objectType){if(e.source instanceof te||e.source instanceof de?(e.source instanceof te?h.nodes.push($(e.source)):h.connectors.push($(e.source)),(o=$(h)).offsetX=(c=e.source.wrapper).offsetX,o.offsetY=c.offsetY):o=$(e.source),("helper"===(l=this.commandHandler.renderContainerHelper(e.source)||e.source||this.commandHandler.renderContainerHelper(e.source)).id||"helper"!==l.id)&&((l instanceof ti&&(Math.round(l.width)===Math.round(this.undoElement.width)&&Math.round(l.height)===Math.round(this.undoElement.height)||l.selectedObjects&&1===l.selectedObjects.length)||!(l instanceof ti))&&(l.offsetX!==this.undoElement.offsetX||l.offsetY!==this.undoElement.offsetY||l.sourcePoint!==this.undoElement.sourcePoint||l.targetPoint!==this.undoElement.targetPoint)||this.isSelectionHasConnector(l))&&(e.source&&(s={offsetX:e.source.wrapper.offsetX,offsetY:e.source.wrapper.offsetY}),g={source:e.source,state:"Completed",oldValue:this.intialValue,newValue:s,target:this.currentTarget,targetPosition:this.currentPosition,allowDrop:(g={source:e.source,state:"Completed",oldValue:this.intialValue,newValue:s,target:this.currentTarget,targetPosition:this.currentPosition,allowDrop:!0,cancel:!1}).allowDrop,cancel:g.cancel},d=!0,"helper"===l.id?this.canTrigger?(this.commandHandler.triggerEvent(Ce.positionChange,g),this.connectorEndPointChangeEvent(g),d=!0):d=!1:(this.commandHandler.triggerEvent(Ce.positionChange,g),this.connectorEndPointChangeEvent(g)),!i&&d&&(this.commandHandler.startGroupAction(),a=!0,M={type:"PositionChanged",redoObject:$(o),undoObject:$(this.undoElement),category:"Internal"},o.nodes[0]&&o.nodes[0].processId&&(u={type:"SizeChanged",category:"Internal",undoObject:this.undoParentElement,redoObject:this.commandHandler.getSubProcess(e.source)},this.commandHandler.addHistoryEntry(u)),this.commandHandler.addHistoryEntry(M))),this.commandHandler.snapPoint(this.prevPosition,this.currentPosition,0,0),this.commandHandler.removeSnap(),this.commandHandler.removeHighlighter(),e.source&&this.currentTarget&&HI(this.currentTarget)&&this.commandHandler.isDroppable(e.source,this.currentTarget)){if(p=!0,this.commandHandler.drop(this.currentElement,this.currentTarget,this.currentPosition),this.currentTarget&&this.currentTarget instanceof de&&!0===this.commandHandler.diagram.enableConnectorSplit)if(this.currentElement&&this.currentElement instanceof te){if(void 0!==this.currentElement.children)for(b=0;b0)for(var s=0;s0)for(var a=0;a0)for(a=0;a0&&e.connectors.length>0)||e.width===this.undoElement.width&&e.height===this.undoElement.height)},t.prototype.mouseMove=function(e){n.prototype.mouseMove.call(this,e);var r,s,i=!1;(r=this.commandHandler.renderContainerHelper(e.source)||e.source)instanceof te||r instanceof de?r instanceof te?r.offsetX===this.undoElement.nodes[0].offsetX&&r.offsetY===this.undoElement.nodes[0].offsetY&&(i=!0):R.equals(r.sourcePoint,this.undoElement.connectors[0].sourcePoint)&&R.equals(r.targetPoint,this.undoElement.connectors[0].targetPoint)&&(i=!0):r.wrapper.offsetX===this.undoElement.wrapper.offsetX&&r.wrapper.offsetY===this.undoElement.wrapper.offsetY&&(i=!0),r&&(s={offsetX:r.wrapper.offsetX,offsetY:r.wrapper.offsetY});var o={source:r,state:"Start",oldValue:s,newValue:s,target:e.target,targetPosition:e.position,allowDrop:!0,cancel:!1};if(o={source:r,state:"Start",oldValue:s,newValue:s,target:e.target,targetPosition:e.position,allowDrop:o.allowDrop,cancel:o.cancel},this.isStartAction||(this.intialValue={offsetX:r.wrapper.offsetX,offsetY:r.wrapper.offsetY}),i&&!ce()&&(this.commandHandler.triggerEvent(Ce.positionChange,o),this.connectorEndPointChangeEvent(o),this.isStartAction=!0),this.currentPosition=e.position,"Port"!==this.objectType){var h=this.initialOffset.x+(this.currentPosition.x-this.prevPosition.x),c=this.initialOffset.y+(this.currentPosition.y-this.prevPosition.y);this.commandHandler.dragOverElement(e,this.currentPosition),this.commandHandler.disConnect(e.source),this.commandHandler.removeSnap();var d,u=void 0,f=this.commandHandler.snapPoint(this.prevPosition,this.currentPosition,h,c);this.initialOffset.x=h-f.x,this.initialOffset.y=c-f.y,r&&(d={offsetX:r.wrapper.offsetX,offsetY:r.wrapper.offsetY},u={offsetX:r.wrapper.offsetX+f.x,offsetY:r.wrapper.offsetY+f.y}),this.currentTarget&&e.target!==this.currentTarget&&this.commandHandler.removeChildFromBPmn(e.source,e.target,this.currentTarget),this.currentTarget=e.target;var p={source:r,state:"Progress",oldValue:d,newValue:u,target:e.target,targetPosition:e.position,allowDrop:!0,cancel:!1};if(this.commandHandler.triggerEvent(Ce.positionChange,p),this.canTrigger=!0,this.connectorEndPointChangeEvent(p,f),!p.cancel&&!this.canCancel){this.blocked=!this.commandHandler.dragSelectedObjects(f.x,f.y);var g=!this.commandHandler.mouseOver(this.currentElement,this.currentTarget,this.currentPosition);this.blocked=this.blocked||g}if(this.commandHandler.removeStackHighlighter(),this.commandHandler.renderStackHighlighter(e),this.currentTarget&&e.source!==this.currentTarget&&this.commandHandler.isDroppable(e.source,this.currentTarget)&&"helper"!==e.source.id){var v=e.source instanceof ti?e.source.nodes[0]:e.source;!this.commandHandler.isParentAsContainer(v,!0)&&"SwimLane"!==v.shape.type&&!v.shape.isPhase&&(this.currentTarget.isLane?this.commandHandler.renderStackHighlighter(e,this.currentTarget):this.commandHandler.drawHighlighter(this.currentTarget))}else this.commandHandler.removeHighlighter();if(this.commandHandler.canEnableDefaultTooltip()){var y=this.getTooltipContent(e.source);this.commandHandler.showTooltip(e.source,e.position,ko(function(){return y}),"MoveTool",this.isTooltipVisible),this.isTooltipVisible=!1}}else{var b=Bi(),M=e.source;qi(b,-M.rotateAngle||-M.wrapper.rotateAngle,M.offsetX||M.wrapper.offsetX,M.offsetY||M.wrapper.offsetY);var w=Ke(b,{x:this.prevPosition.x,y:this.prevPosition.y}),C=Ke(b,{x:e.position.x,y:e.position.y});this.commandHandler.portDrag(e.source,e.sourceWrapper,C.x-w.x,C.y-w.y)}return this.prevPosition=this.currentPosition,!this.blocked},t.prototype.getTooltipContent=function(e){return"X:"+Math.round(e.wrapper.bounds.x)+" Y:"+Math.round(e.wrapper.bounds.y)},t.prototype.mouseLeave=function(e){this.mouseUp(e)},t.prototype.endAction=function(){n.prototype.endAction.call(this),this.currentTarget=null,this.prevPosition=null},t}(us),Gx=function(n){function t(e){var i=n.call(this,e,!0)||this;return i.rotateStart=!1,i}return ds(t,n),t.prototype.mouseDown=function(e){if(this.undoElement=$(e.source),this.undoElement.nodes[0]&&this.undoElement.nodes[0].children)for(var r=this.commandHandler.getAllDescendants(this.undoElement.nodes[0],[]),s=0;s=2){var s=e.startTouches[0],o=e.startTouches[1],a=e.moveTouches[0],l=e.moveTouches[1],h=this.getDistance(a,l)/this.getDistance(s,o);this.commandHandler.zoom(h,0,0,e.position),this.updateTouch(s,a),this.updateTouch(o,l)}}else this.commandHandler.scroll(this.currentPosition.x-this.prevPosition.x,this.currentPosition.y-this.prevPosition.y,this.currentPosition);return this.commandHandler.dataBinding(),!this.blocked},t.prototype.mouseUp=function(e){this.commandHandler.setBlazorDiagramProps(!1),this.checkPropertyValue(),this.commandHandler.updatePanState(!1),n.prototype.mouseUp.call(this,e),this.inAction=!1},t.prototype.endAction=function(){n.prototype.endAction.call(this)},t.prototype.getDistance=function(e,i){var r=i.pageX-e.pageX,s=i.pageY-e.pageY;return Math.sqrt(r*r+s*s)},t.prototype.updateTouch=function(e,i){e.pageX=i.pageX,e.pageY=i.pageY},t}(us),One=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseUp=function(e){this.checkPropertyValue(),this.commandHandler.initExpand(e),n.prototype.mouseUp.call(this,e)},t}(us),X3=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseUp=function(e){this.checkPropertyValue();var i="_blank",r="",s=window.innerHeight,o=window.innerWidth,a=window.screenTop,l=window.screenLeft;"CurrentTab"===e.sourceWrapper.hyperlink.hyperlinkOpenState?i="_self":"NewWindow"===e.sourceWrapper.hyperlink.hyperlinkOpenState&&(r="height="+s+",width="+o+",top="+a+",left="+l),window.open(e.sourceWrapper.hyperlink.link,i,r).focus(),n.prototype.mouseUp.call(this,e)},t}(us),zl=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseDown=function(e){if(n.prototype.mouseDown.call(this,e),this.inAction=!0,this.drawingObject){var r=void 0,s=this.drawingObject.shape;this.drawingObject.shape.points.push(r={x:(r=s.points[s.points.length-1]).x,y:r.y})}else{this.startPoint={x:this.startPosition.x,y:this.startPosition.y};var i={offsetX:this.currentPosition.x,offsetY:this.currentPosition.y,width:5,height:5,shape:{type:"Basic",shape:"Polygon",points:[{x:this.startPoint.x,y:this.startPoint.y},{x:this.currentPosition.x,y:this.currentPosition.y}]}};this.triggerElementDrawEvent(e.source,"Start","Node",this.getShapeType(),!0),this.drawingObject=this.commandHandler.drawObject(i)}},t.prototype.mouseMove=function(e){if(n.prototype.mouseMove.call(this,e),this.inAction){var i=this.drawingObject.shape;if(i.points[i.points.length-1].x=this.currentPosition.x,i.points[i.points.length-1].y=this.currentPosition.y,this.drawingObject.wrapper.children[0].data=yx(this.drawingObject.shape.points),this.triggerElementDrawEvent(this.drawingObject,"Progress","Node",this.getShapeType(),!1),this.inAction&&!1===R.equals(this.currentPosition,this.prevPosition)){var r=Ne.toBounds(this.drawingObject.shape.points);this.commandHandler.updateNodeDimension(this.drawingObject,r)}}return!0},t.prototype.mouseUp=function(e,i){this.checkPropertyValue(),n.prototype.mouseMove.call(this,e),this.inAction&&(this.inAction=!1,this.commandHandler.addObjectToDiagram(this.drawingObject),this.triggerElementDrawEvent(this.drawingObject,"Completed","Node",this.getShapeType(),!1)),this.endAction()},t.prototype.mouseWheel=function(e){n.prototype.mouseWheel.call(this,e),this.mouseMove(e)},t.prototype.endAction=function(){this.inAction=!1,this.drawingObject=null},t}(us),Rl=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseMove=function(e){if(n.prototype.mouseMove.call(this,e),this.inAction){var i=this.drawingObject;i.targetPoint=this.currentPosition,this.triggerElementDrawEvent(this.drawingObject,"Progress","Connector",this.drawingObject.type,!1),this.commandHandler.updateConnectorPoints(i)}return!0},t.prototype.mouseDown=function(e){if(n.prototype.mouseDown.call(this,e),this.inAction=!0,this.drawingObject){var r=this.drawingObject,s=void 0;(s=new Hl(r,"segments",{type:"Straight"},!0)).point=this.currentPosition,r.segments[r.segments.length-1]=s}else{var i={id:"Connector",type:"Straight",sourcePoint:this.currentPosition,targetPoint:this.currentPosition};this.triggerElementDrawEvent(e.source,"Start","Connector",this.commandHandler.diagram.drawingObject.type,!0),this.inAction&&(this.drawingObject=this.commandHandler.drawObject(i))}},t.prototype.mouseWheel=function(e){n.prototype.mouseWheel.call(this,e),this.mouseMove(e)},t.prototype.mouseUp=function(e){if(this.checkPropertyValue(),n.prototype.mouseMove.call(this,e),this.inAction&&this.drawingObject){var i=this.drawingObject;i.segments[i.segments.length-1].point={x:0,y:0},this.commandHandler.addObjectToDiagram(this.drawingObject),this.triggerElementDrawEvent(this.drawingObject,"Completed","Connector",this.drawingObject.type,!1)}this.endAction()},t.prototype.endAction=function(){this.drawingObject=null,this.inAction=!1},t}(us),kne=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseDown=function(e){this.inAction=!0,this.undoElement=$(e.source),this.annotationId=e.sourceWrapper.id,n.prototype.mouseDown.call(this,e)},t.prototype.mouseMove=function(e){n.prototype.mouseMove.call(this,e);var i=this.currentPosition.x-this.prevPosition.x,r=this.currentPosition.y-this.prevPosition.y,s=e.source;if(s instanceof te){var o=Bi();qi(o,-s.rotateAngle,0,0);var a=Ke(o,{x:i,y:r});i=a.x,r=a.y}return this.inAction&&(this.commandHandler.labelDrag(e.source,e.sourceWrapper,i,r),this.commandHandler.updateSelector()),this.prevPosition=this.currentPosition,!this.blocked},t.prototype.mouseUp=function(e){this.checkPropertyValue();var i=e.source;this.inAction=!1;var r={type:"AnnotationPropertyChanged",objectId:this.annotationId,undoObject:$(this.undoElement),category:"Internal",redoObject:$(i)};this.commandHandler.addHistoryEntry(r),n.prototype.mouseUp.call(this,e)},t.prototype.mouseLeave=function(e){this.mouseUp(e)},t}(us),Pne=function(n){function t(e,i){var r=n.call(this,e,!0)||this;return r.corner=i,r}return ds(t,n),t.prototype.mouseDown=function(e){this.inAction=!0;var i=e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0];this.annotationId=e.source.wrapper.children[0].id,this.undoElement=$(i);var r=e.source.wrapper.children[0];this.initialBounds={x:r.offsetX,y:r.offsetY,width:r.actualSize.width,height:r.actualSize.height},n.prototype.mouseDown.call(this,e)},t.prototype.mouseMove=function(e){return n.prototype.mouseMove.call(this,e),this.inAction&&this.resizeObject(e),!this.blocked},t.prototype.mouseUp=function(e){this.checkPropertyValue();var i=e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0];this.inAction=!1;var r={type:"AnnotationPropertyChanged",objectId:this.annotationId,redoObject:$(i),undoObject:$(this.undoElement),category:"Internal"};this.commandHandler.addHistoryEntry(r),n.prototype.mouseUp.call(this,e)},t.prototype.mouseLeave=function(e){this.mouseUp(e)},t.prototype.resizeObject=function(e){var i,s,o,r=e.source.wrapper.children[0],a={x:r.offsetX,y:r.offsetY},l=r.rotateAngle;l=((l+=(i=e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0])instanceof te?i.rotateAngle:0)+360)%360;var h=Bi();qi(h,l,a.x,a.y);var c=this.corner.slice(5),d=this.updateSize(r,this.startPosition,this.currentPosition,c,this.initialBounds,l),u=r.offsetX-r.actualSize.width*r.pivot.x,f=r.offsetY-r.actualSize.height*r.pivot.y,p=this.getPivot(c),g=Ke(h,p={x:u+r.actualSize.width*p.x,y:f+r.actualSize.height*p.y});d.x=g.x,d.y=g.y,this.commandHandler.labelResize(i,e.source.annotation,s=(s=d.width)<0?1:s,o=(o=d.height)<0?1:o,d,e.source),this.commandHandler.updateSelector()},t}(us),zne=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseDown=function(e){this.inAction=!0,this.annotationId=e.source.wrapper.children[0].id,this.undoElement=$(e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0]),n.prototype.mouseDown.call(this,e)},t.prototype.mouseMove=function(e){return n.prototype.mouseMove.call(this,e),e.source&&this.inAction&&(this.commandHandler.labelRotate(e.source.nodes[0]?e.source.nodes[0]:e.source.connectors[0],e.source.annotation,this.currentPosition,e.source),this.commandHandler.updateSelector()),this.prevPosition=this.currentPosition,!this.blocked},t.prototype.mouseUp=function(e){this.checkPropertyValue(),this.inAction=!1;var r={type:"AnnotationPropertyChanged",objectId:this.annotationId,redoObject:$(e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0]),undoObject:$(this.undoElement),category:"Internal"};this.commandHandler.addHistoryEntry(r),n.prototype.mouseUp.call(this,e)},t.prototype.mouseLeave=function(e){this.mouseUp(e)},t}(us),Rne=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseMove=function(e){if(n.prototype.mouseMove.call(this,e),this.inAction){var i=this.drawingObject.shape;if(i.points.push(this.currentPosition),this.drawingObject.wrapper.children[0].data=Sx(this.drawingObject.shape.points),i.data=Sx(i.points),this.triggerElementDrawEvent(e.source,"Progress","Connector",this.drawingObject.type,!1),this.inAction&&!1===R.equals(this.currentPosition,this.prevPosition)){var s=Ne.toBounds(this.drawingObject.shape.points);this.commandHandler.updateNodeDimension(this.drawingObject,s)}}return!0},t.prototype.mouseDown=function(e){n.prototype.mouseDown.call(this,e),this.inAction=!0,this.startPoint={x:this.startPosition.x,y:this.startPosition.y};var i={offsetX:this.currentPosition.x,offsetY:this.currentPosition.y,width:5,height:5,style:{strokeColor:"black",strokeWidth:1,fill:"transparent"},shape:{type:"Path",points:[{x:this.startPoint.x,y:this.startPoint.y},{x:this.currentPosition.x,y:this.currentPosition.y}]}};this.triggerElementDrawEvent(e.source,"Start","Connector",this.commandHandler.diagram.drawingObject.type,!0),this.drawingObject=this.commandHandler.drawObject(i)},t.prototype.mouseUp=function(e){if(this.checkPropertyValue(),this.inAction){this.inAction=!1;var s=this.drawingObject.shape,o=s.points;this.commandHandler.addObjectToDiagram(this.drawingObject),this.commandHandler.diagram.remove(this.commandHandler.diagram.nameTable[""+this.drawingObject.id]),o=this.pointReduction(o,10);var h={id:"newConnector"+Qe(),type:"Bezier",sourcePoint:{x:o[0].x,y:o[0].y},targetPoint:{x:o[o.length-1].x,y:o[o.length-1].y},segments:[],bezierSettings:{allowSegmentsReset:!1}};this.drawingObject=this.commandHandler.drawObject(h),this.drawingObject=this.bezierCurveSmoothness(o,.5,this.drawingObject,s),this.commandHandler.updateConnectorPoints(this.drawingObject),this.commandHandler.addObjectToDiagram(this.drawingObject),this.triggerElementDrawEvent(this.drawingObject,"Completed","Connector",this.drawingObject.type,!1),n.prototype.mouseUp.call(this,e)}},t.prototype.pointReduction=function(e,i){if(null===e||e.length<3)return e;var s=e.length-1,o=[];for(o.push(0),o.push(s);e[parseInt((0).toString(),10)]===e[parseInt(s.toString(),10)];)s--;this.reduction(e,0,s,i,o);var a=[];return o.sort(function(l,h){return l-h}),o.forEach(function(l){a.push(e[parseInt(l.toString(),10)])}),a},t.prototype.reduction=function(e,i,r,s,o){for(var a=0,l=0,h=i;ha&&(a=c,l=h)}a>s&&0!==l&&(o.push(l),this.reduction(e,i,l,s,o),this.reduction(e,l,r,s,o))},t.prototype.perpendicularDistance=function(e,i,r){return Math.abs(.5*(e.x*i.y-i.x*e.y+(i.x*r.y-r.x*i.y)+(r.x*e.y-e.x*r.y)))/Math.sqrt(Math.pow(e.x-i.x,2)+Math.pow(e.y-i.y,2))*2},t.prototype.bezierCurveSmoothness=function(e,i,r,s){if(e.length<3)return r;for(var o=0;o=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Hne=function(n){if(n)switch(n.type){case"Bpmn":return Une;case"UmlActivity":return _ne;case"UmlClassifier":return Wne;default:return em}return em},Bne=function(n){if(n)switch(n.type){case"Straight":default:return Hl;case"Bezier":return fs;case"Orthogonal":return wi}},q3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I(10)],t.prototype,"width",void 0),Pe([I(10)],t.prototype,"height",void 0),Pe([I("Arrow")],t.prototype,"shape",void 0),Pe([re({fill:"black",strokeColor:"black",strokeWidth:1},Ll)],t.prototype,"style",void 0),Pe([re({x:0,y:.5},R)],t.prototype,"pivot",void 0),Pe([I("")],t.prototype,"pathData",void 0),t}(Ee),qI=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I(0)],t.prototype,"angle",void 0),Pe([I(0)],t.prototype,"distance",void 0),t}(Ee),Fne=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I(wx.All)],t.prototype,"controlPointsVisibility",void 0),Pe([I("FreeForm")],t.prototype,"segmentEditOrientation",void 0),Pe([I(MI.Default)],t.prototype,"smoothness",void 0),Pe([I(!0)],t.prototype,"allowSegmentsReset",void 0),t}(Ee),em=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I("None")],t.prototype,"type",void 0),t}(Ee),_ne=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I("Object")],t.prototype,"flow",void 0),Pe([I(30)],t.prototype,"exceptionFlowHeight",void 0),t}(em),Une=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I("Sequence")],t.prototype,"flow",void 0),Pe([I("Normal")],t.prototype,"sequence",void 0),Pe([I("Default")],t.prototype,"message",void 0),Pe([I("Default")],t.prototype,"association",void 0),t}(em),$3=function(n){function t(e,i,r,s){var o=n.call(this,e,i,r,s)||this;return o.points=[],o}return Qs(t,n),Pe([I("Straight")],t.prototype,"type",void 0),Pe([I(!0)],t.prototype,"allowDrag",void 0),t}(Ee),Hl=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),t.prototype.getClassName=function(){return"StraightSegment"},Pe([re({x:0,y:0},R)],t.prototype,"point",void 0),t}($3),fs=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),t.prototype.getClassName=function(){return"BezierSegment"},t.prototype.getPoints=function(e,i){var r=[];if(r.length>0||null!=i){var o=this.bezireToPoly(r.length>0?r[r.length-1]:i,e);r.push.apply(r,o)}return r},t.prototype.bezireToPoly=function(e,i){var r=[];return i&&this.flattenCubicBezier(r,e,i.bezierPoint1,i.bezierPoint2,{x:i.points[1].x,y:i.points[1].y},10),r},t.prototype.flattenCubicBezier=function(e,i,r,s,o,a){var h,l=(R.findLength(i,r)+R.findLength(r,s)+R.findLength(s,o))/a;for(h=0;h<=l;h++){var c=h/l;e.push({x:(1-c)*(1-c)*(1-c)*i.x+3*c*(1-c)*(1-c)*r.x+3*c*c*(1-c)*s.x+c*c*c*o.x,y:(1-c)*(1-c)*(1-c)*i.y+3*c*(1-c)*(1-c)*r.y+3*c*c*(1-c)*s.y+c*c*c*o.y})}},Pe([I("Horizontal")],t.prototype,"orientation",void 0),Pe([re({x:0,y:0},R)],t.prototype,"point1",void 0),Pe([re({x:0,y:0},R)],t.prototype,"point2",void 0),Pe([re({angle:0,distance:0},qI)],t.prototype,"vector1",void 0),Pe([re({angle:0,distance:0},qI)],t.prototype,"vector2",void 0),t}(Hl),wi=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),t.prototype.getClassName=function(){return"OrthogonalSegment"},Pe([I(null)],t.prototype,"length",void 0),Pe([I(null)],t.prototype,"direction",void 0),t}($3);function Z3(n,t,e){var s=e?45:180/(2+2/(n.height/n.width)),o=s,a=180-s,l=a+2*s,h=360-s,c=Xt(t,n.center);return c>o&&ca&&cl&&cMath.abs(t.y-n.y)?n.x=c)return s=R.findAngle(n[parseInt(d.toString(),10)],n[d+1]),{point:r=R.transform(n[parseInt(d.toString(),10)],s,c-(a||0)),index:l=d};a=o[parseInt(d.toString(),10)]}return{point:r,index:l}}(n,t),r=R.findAngle(n[i.index],n[i.index+1]),s=function yse(n){var e=0;switch(n.alignment){case"Center":case"After":e=0;break;case"Before":e=-0}return e}(t),o=R.transform(i.point,r+45,s);return i.point=o,i.angle=r,i}(i,e),h=l.point;s.id=this.id+"_"+e.id;var c=e.style;s.style={fill:c.fill,strokeColor:c.strokeColor,gradient:null,opacity:c.opacity,strokeDashArray:c.strokeDashArray,strokeWidth:c.strokeWidth},0===r.width&&(r.width=this.style.strokeWidth),0===r.height&&(r.height=this.style.strokeWidth);var d_y=(h.y-r.y)/r.height;a.x=r.width*((h.x-r.x)/r.width),a.y=r.height*d_y;var g,v,u=fF(e,l.angle,i),f=u.hAlign,p=u.vAlign;return"left"===f?(g="Left",a.x+=e.displacement.x):"right"===f?(g="Right",a.x-=e.displacement.x):"center"===f&&(g="Center"),"top"===p?(v="Top",a.y+=e.displacement.y):"bottom"===p?(v="Bottom",a.y-=e.displacement.y):"center"===p&&(v="Center"),s.horizontalAlignment=g,s.verticalAlignment=v,(s=rm(s,o&&"Label"!==o.flipMode&&"None"!==o.flipMode?this.flip:"None",e)).float=!0,s.connectionDirection=e.connectionDirection,s.setOffsetWithRespectToBounds(a.x,a.y,"Absolute"),s.relativeMode="Point",s.visible=!(!va(e,Gt.Visible)||va(e,Gt.Hover)||va(e,Gt.Connect)),s.elementActions=s.elementActions|Xr.ElementIsPort,s},t.prototype.getConnectorRelation=function(){var e=this.shape;"Association"===e.relationship?(this.segments[0].type="Straight",this.sourceDecorator.shape="None",this.targetDecorator.shape="Arrow"):"Inheritance"===e.relationship?(this.segments[0].type="Orthogonal",this.sourceDecorator.shape="None",this.targetDecorator.shape="Arrow"):"Composition"===e.relationship||"Aggregation"===e.relationship?(this.segments[0].type="Orthogonal",this.sourceDecorator.shape="Diamond",this.targetDecorator.shape="None"):"Dependency"===e.relationship?(this.segments[0].type="Orthogonal",this.sourceDecorator.shape="None",this.targetDecorator.shape="OpenArrow"):"Realization"===e.relationship&&(this.segments[0].type="Orthogonal",this.sourceDecorator.shape="None",this.targetDecorator.shape="Arrow"),"BiDirectional"===e.associationType&&(this.sourceDecorator.shape="None",this.targetDecorator.shape="None");var i,o,r="",s="";e.multiplicity.source&&(e.multiplicity.source.lowerBounds=e.multiplicity.source.lowerBounds,e.multiplicity.source.upperBounds=e.multiplicity.source.upperBounds),e.multiplicity.target&&(e.multiplicity.target.lowerBounds=e.multiplicity.target.lowerBounds,e.multiplicity.target.upperBounds=e.multiplicity.target.upperBounds);var a=e.multiplicity.source,l=e.multiplicity.target;o=a.upperBounds?a.lowerBounds+"..."+a.upperBounds:a.lowerBounds,i=l.upperBounds?l.lowerBounds+"..."+l.upperBounds:l.lowerBounds,"ManyToOne"===e.multiplicity.type&&(e.multiplicity.target.optional=!1,r=o||"*",s="1"),"OneToMany"===e.multiplicity.type&&(e.multiplicity.source.optional=!1,s=i||"*",r="1"),"ManyToMany"===e.multiplicity.type&&(r=o||"*",s=i||"*"),"OneToOne"===e.multiplicity.type&&(e.multiplicity.target.optional=!1,e.multiplicity.source.optional=!1,r="1",s="1"),this.annotations=[{id:this.id+"sourcelabel",content:r,offset:0,alignment:"Before",margin:{right:5,bottom:5}},{id:this.id+"targetlabel",content:s,offset:1,alignment:"Before",margin:{right:5,bottom:5}}]},t.prototype.getBpmnSequenceFlow=function(){var e=new Ze,i=new Ze;return"Normal"===this.shape.sequence&&"Bezier"!==this.type&&(this.targetDecorator.shape="Arrow"),"Default"===this.shape.sequence&&(e=this.getSegmentElement(this,e),i=IF(this.intermediatePoints,this),this.targetDecorator.shape="Arrow"),"Conditional"===this.shape.sequence&&(this.targetDecorator.shape="Arrow",this.sourceDecorator.shape="Diamond",i.id=this.id+this.shape.type),i},t.prototype.getUMLObjectFlow=function(){if(this.annotations)for(var e=0;e0&&(this.sourcePoint=o[0],this.targetPoint=o[o.length-1]),o},t.prototype.clipDecorator=function(e,i,r,s){var a,l,o={x:0,y:0},h=i.length,c=R.distancePoints(a=r?i[0]:i[h-1],l=r?i[1]:i[h-2]);c=0===c?1:c;var d=1,u=r?e.sourceWrapper:e.targetWrapper;u&&(d=u.style.strokeWidth,s&&s&ee.DecoratorPropertyChange&&(d=1));var f=d-1;return o.x=Math.round(a.x+f*(l.x-a.x)/c),o.y=Math.round(a.y+f*(l.y-a.y)/c),(r&&"None"!==e.sourceDecorator.shape||!r&&"None"!==e.targetDecorator.shape)&&(o=R.adjustPoint(o,l,!0,s&ee.DecoratorPropertyChange?0:d/2)),o},t.prototype.clipDecorators=function(e,i,r){return"None"!==e.sourceDecorator.shape&&(i[0]=this.clipDecorator(e,i,!0,r)),"None"!==e.targetDecorator.shape&&(i[i.length-1]=this.clipDecorator(e,i,!1,r)),i},t.prototype.updateSegmentElement=function(e,i,r,s){var o=new Ne,a=this.getSegmentPath(e,i,s);if("Bezier"===e.type){if(this.segments.length>0)for(var l=0;l0)if("Straight"===e.type&&e.segments.length<2)for(var o=0;o1)for(o=0;o0&&"Bezier"!==this.type)for(var f=0;f0&&(a=f0&&(p<2*this.cornerRadius?(l=R.adjustPoint(h[parseInt(f.toString(),10)],h[f+1],!0,p/2),f0&&(s=this.bridgePath(e,s,f),"Orthogonal"===e.type&&(s=this.bridgePath(e,s,f+1))),s+=" L"+a.x+" "+a.y))}else if("Bezier"===this.type){var g=void 0,v=void 0;if(this.parentObj.element){var y=this.parentObj.element.ej2_instances[0].eventHandler.action;g=this.parentObj.element.ej2_instances[0].eventHandler.tool instanceof Rd,v=y.includes("PortDraw")||y.includes("Drag")}for(var S=void 0,b=this.segments,M=0;M2&&(b[parseInt(M.toString(),10)].bezierPoint1={x:0,y:0},b[parseInt(M.toString(),10)].bezierPoint2={x:0,y:0}),!R.isEmptyPoint(b[parseInt(M.toString(),10)].point1)||b[parseInt(M.toString(),10)].vector1.angle||b[parseInt(M.toString(),10)].vector1.distance?b[parseInt(M.toString(),10)].vector1.angle||b[parseInt(M.toString(),10)].vector1.distance?b[parseInt(M.toString(),10)].bezierPoint1=R.transform(h[parseInt(M.toString(),10)],b[parseInt(M.toString(),10)].vector1.angle,b[parseInt(M.toString(),10)].vector1.distance):b[parseInt(M.toString(),10)].bezierPoint1={x:b[parseInt(M.toString(),10)].point1.x||b[parseInt(M.toString(),10)].bezierPoint1.x,y:b[parseInt(M.toString(),10)].point1.y||b[parseInt(M.toString(),10)].bezierPoint1.y}:((e.sourceID||this.sourcePortID)&&this.sourceWrapper&&!v&&!g&&(S=Z3(this.sourceWrapper.bounds,h[parseInt(M.toString(),10)],!0)),b[parseInt(M.toString(),10)].bezierPoint1=ZI(h[parseInt(M.toString(),10)],h[M+1],S)),!R.isEmptyPoint(b[parseInt(M.toString(),10)].point2)||b[parseInt(M.toString(),10)].vector2.angle||b[parseInt(M.toString(),10)].vector2.distance?b[parseInt(M.toString(),10)].vector2.angle||b[parseInt(M.toString(),10)].vector2.distance?b[parseInt(M.toString(),10)].bezierPoint2=R.transform(h[M+1],b[parseInt(M.toString(),10)].vector2.angle,b[parseInt(M.toString(),10)].vector2.distance):b[parseInt(M.toString(),10)].bezierPoint2={x:b[parseInt(M.toString(),10)].point2.x||b[parseInt(M.toString(),10)].bezierPoint2.x,y:b[parseInt(M.toString(),10)].point2.y||b[parseInt(M.toString(),10)].bezierPoint2.y}:((e.targetID||this.targetPortID)&&this.targetWrapper&&!v&&!g&&(S=Z3(this.targetWrapper.bounds,h[M+1],!0)),b[parseInt(M.toString(),10)].bezierPoint2=ZI(h[M+1],h[parseInt(M.toString(),10)],S));h.splice(1,0,{x:b[0].bezierPoint1.x,y:b[0].bezierPoint1.y}),h.splice(h.length-1,0,{x:b[b.length-1].bezierPoint2.x,y:b[b.length-1].bezierPoint2.y}),h=this.clipDecorators(e,h,r);for(var w=0;w0&&(s=this.bridgePath(e,s,D),s+=" L"+o.x+" "+o.y);return s},t.prototype.updateShapeElement=function(e){var i;switch(e.shape.type){case"Bpmn":e.wrapper.children[3]instanceof Ze&&(i=e.wrapper.children[3]),"Message"===e.shape.flow&&this.updateShapePosition(e,i);break;case"UmlActivity":"Exception"===e.shape.flow&&this.getUMLExceptionFlow(e.wrapper.children[0])}},t.prototype.updateShapePosition=function(e,i){var o=bF(this.intermediatePoints,i,.5);i.offsetX=o.x,i.offsetY=o.y},t.prototype.scale=function(e,i,r,s,o){var a=0,l=0;if(this.wrapper&&this.wrapper.outerBounds){var h=function M3(n){var t=n.wrapper.children[0].bounds;return"None"!==n.sourceDecorator.shape&&t.uniteRect(n.wrapper.children[1].bounds),"None"!==n.targetDecorator.shape&&t.uniteRect(n.wrapper.children[2].bounds),t}(this),c=Math.abs((this.wrapper.bounds.width||this.style.strokeWidth||1)-2),d=Math.abs((this.wrapper.bounds.height||this.style.strokeWidth||1)-2);a=h.width-c,l=h.height-d,e=Math.abs((r-Math.max(a,l))/c),i=Math.abs((s-Math.max(a,l))/d),a=l=Math.min(a,l)}e=i=Math.min(e,i);var u=Bi();qi(u,-(o=o||this.wrapper).rotateAngle,o.offsetX,o.offsetY),Gf(u,e,i,o.offsetX,o.offsetY),qi(u,o.rotateAngle,o.offsetX,o.offsetY);var f=function Oie(n,t){for(var e=[],i=0,r=t;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Qne=function(n){function t(e,i){var r=n.call(this,e,i)||this;return r.offset=0,r.scale=1,r}return Yne(t,n),t.prototype.preRender=function(){this.unWireEvents(),this.wireEvents()},t.prototype.render=function(){this.updateRulerGeometry(),this.renderComplete()},t.prototype.getModuleName=function(){return"Ruler"},t.prototype.destroy=function(){this.unWireEvents(),this.notify("destroy",{}),n.prototype.destroy.call(this),this.element.classList.remove("e-ruler")},t.prototype.getPersistData=function(){return this.addOnPersist(["loaded"])},t.prototype.onPropertyChanged=function(e,i){for(var r=0,s=Object.keys(e);r100;)r/=10,s/=10;for(;s<25;)r*=10,s*=10;return s>=25&&s%25!=0&&(s=25*Math.round(s/25)),s*e/r},t.prototype.createMarkerLine=function(e,i,r){var s;return i&&((s=e.getElementById(i.id+"_marker"))&&s.parentNode.removeChild(s),s=Fi("line",r)),s},t.prototype.drawRulerMarker=function(e,i,r){var s,o,h,d,u="Horizontal"===this.orientation,f=e.getElementsByTagName("svg");for(h=0;h0)for(var a=i.childNodes.length-1;a>=0;a--)i.childNodes[parseInt(a.toString(),10)].parentNode.removeChild(i.childNodes[parseInt(a.toString(),10)]);i.appendChild(s)}return s},t.prototype.wireEvents=function(){},t.prototype.unWireEvents=function(){},kc([I(5)],t.prototype,"interval",void 0),kc([I(100)],t.prototype,"segmentWidth",void 0),kc([I("Horizontal")],t.prototype,"orientation",void 0),kc([I("RightOrBottom")],t.prototype,"tickAlignment",void 0),kc([I("red")],t.prototype,"markerColor",void 0),kc([I(25)],t.prototype,"thickness",void 0),kc([I(null)],t.prototype,"arrangeTick",void 0),kc([I(400)],t.prototype,"length",void 0),t}(Ii);function eF(n,t){var e=document.getElementById(n.element.id+(t?"_hRuler":"_vRuler")),i=Za(n),r=tF(n);e||(e=Tt("div",{id:n.element.id+(t?"_hRuler":"_vRuler"),style:"height:"+(t?i.height:r.height+100)+"px;overflow:hidden;width:"+(t?r.width+100:i.width)+"px;position:absolute;font-size:11px;"+(t?"margin-left:"+i.width+"px;":"margin-top:"+i.height+"px;")})),n.element.insertBefore(e,n.element.firstChild);var l=t?n.rulerSettings.horizontalRuler:n.rulerSettings.verticalRuler,h=new Qne(l);h.orientation=t?"Horizontal":"Vertical",h.length=(t?r.width:r.height)+l.segmentWidth,h.appendTo("#"+n.element.id+(t?"_hRuler":"_vRuler")),t?n.hRuler=h:n.vRuler=h;var c=document.getElementById(n.element.id+(t?"_hRuler":"_vRuler"));t?n.hRuler.element=c:n.vRuler.element=c}function JI(n){var t=-n.scroller.horizontalOffset,e=-n.scroller.verticalOffset;n&&n.rulerSettings.showRulers?(n.hRuler.length=0,n.vRuler.length=0,void 0!==t&&n.hRuler.element&&iF(n,n.hRuler,t,!0),void 0!==e&&n.vRuler.element&&iF(n,n.vRuler,e,!1)):Xx(n)}function Xx(n){an(n.element.id+"_hRuler"),an(n.element.id+"_vRuler"),an(n.element.id+"_overlapRuler")}function Za(n){var t=0,e=0;return n.rulerSettings.showRulers&&(t=n.rulerSettings.horizontalRuler.thickness,e=n.rulerSettings.verticalRuler.thickness),new me(e,t)}function tF(n){var t=Za(n),e=n.scroller.viewPortHeight,i=n.scroller.viewPortWidth;return i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},rF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Jne(t,n),t.prototype.getClassName=function(){return"UserHandle"},Un([I("")],t.prototype,"name",void 0),Un([I("")],t.prototype,"pathData",void 0),Un([I("")],t.prototype,"content",void 0),Un([I("")],t.prototype,"source",void 0),Un([I("#000000")],t.prototype,"backgroundColor",void 0),Un([I("Top")],t.prototype,"side",void 0),Un([I("")],t.prototype,"borderColor",void 0),Un([I(.5)],t.prototype,"borderWidth",void 0),Un([I(25)],t.prototype,"size",void 0),Un([I("white")],t.prototype,"pathColor",void 0),Un([I(10)],t.prototype,"displacement",void 0),Un([I(!0)],t.prototype,"visible",void 0),Un([I(0)],t.prototype,"offset",void 0),Un([re({},Jn)],t.prototype,"margin",void 0),Un([I("Center")],t.prototype,"horizontalAlignment",void 0),Un([I("Center")],t.prototype,"verticalAlignment",void 0),Un([I(!1)],t.prototype,"disableNodes",void 0),Un([I(!1)],t.prototype,"disableConnectors",void 0),Un([re({},Td)],t.prototype,"tooltip",void 0),Un([I("")],t.prototype,"template",void 0),t}(Ee);function nF(n){return Kne[n.toString()]}var Kne={Action:"M 90 82.895 C 90 86.819 86.776 90 82.8 90 H 7.2 C 3.224 90 0 86.819 0 82.895 V 7.105 C 0 3.181 3.224 0 7.2 0 h 75.6 C 86.776 0 90 3.181 90 7.105 V 82.895 Z",Decision:"M10,19.707L0.293,10L10,0.293L19.707,10L10,19.707z",MergeNode:"M10,19.707L0.293,10L10,0.293L19.707,10L10,19.707z",InitialNode:"M10,19.5c-5.238,0-9.5-4.262-9.5-9.5S4.762,0.5,10,0.5s9.5,4.262,9.5,9.5S15.238,19.5,10,19.5z",ForkNode:"m0.75,0.75l636.00002,0l0,290l-636.00002,0l0,-290z",JoinNode:"m0.75,0.75l636.00002,0l0,290l-636.00002,0l0,-290z",TimeEvent:"M50.001,0.00286865 L25.001,25.0029 L0.000976562,0.00286865 L50.001,0.00286865 z M0.000976562,50.0029 L25.001,25.0029 L50.001,50.0029 L0.000976562,50.0029 z",AcceptingEvent:"M17.8336 32.164 L29.64 24 L17.32 16 L48.1664 16 L48.5 32 Z",SendSignal:"M48.164 31.8336 L56 23.832 L47.836 16 L16.168 16 L16.1668 31.8336 Z",ReceiveSignal:"M48.1664 31.8336 L39.836 24 L47.836 16 L16.168 16 L16.168 31.836 Z",StructuredNode:"M0,0 L50,0 L50,50 L0,50 z",Note:"M20 12 L4 12 L4 22 L22 22 L22 14 L20 14 L20 12 L22 14 Z"},KI=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Ja=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},ese=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return KI(t,n),Ja([I()],t.prototype,"key",void 0),Ja([I()],t.prototype,"keyModifiers",void 0),t}(Ee),sF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return KI(t,n),t.prototype.getClassName=function(){return"Command"},Ja([I("")],t.prototype,"name",void 0),Ja([I()],t.prototype,"canExecute",void 0),Ja([I()],t.prototype,"execute",void 0),Ja([re({},ese)],t.prototype,"gesture",void 0),Ja([I("")],t.prototype,"parameter",void 0),t}(Ee),tse=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return KI(t,n),Ja([Bt([],sF)],t.prototype,"commands",void 0),t}(Ee),ise=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return KI(t,n),Ja([I()],t.prototype,"show",void 0),Ja([I()],t.prototype,"showCustomMenuOnly",void 0),Ja([I()],t.prototype,"items",void 0),t}(Ee),Jf=function(){function n(){}return n.prototype.renderShadow=function(t,e,i,r){void 0===i&&(i=null);var l,o=R.transform({x:0,y:0},t.shadow.angle,t.shadow.distance);r&&(l=r.getElementById(e.id+"_shadow")),l||(l=document.createElementNS("http://www.w3.org/2000/svg",i?"path":"rect"),e.appendChild(l));var h={id:e.id+"_shadow",fill:t.shadow.color,stroke:t.shadow.color,opacity:t.shadow.opacity.toString(),transform:"rotate("+t.angle+","+(t.x+t.width*t.pivotX)+","+(t.y+t.height*t.pivotY)+")translate("+(t.x+o.x)+","+(t.y+o.y)+")"};if(r){var c=r.getElementById(e.id);c&&c.insertBefore(l,c.firstChild)}ii(l,h),i?i&&this.renderPath(l,t,i):ii(l,{width:t.width,height:t.height})},n.prototype.parseDashArray=function(t){return[]},n.prototype.drawRectangle=function(t,e,i,r,s,o,a,l,h){var c,d,u,f;e.shadow&&!r&&this.renderShadow(e,t,void 0,o),c=e.id===t.id?e.id+"_container":e.id,o&&(d=o.getElementById(c)),(!d||s)&&(d=document.createElementNS("http://www.w3.org/2000/svg","rect"),t.appendChild(d)),o&&!e.shadow&&(u=o.getElementById(e.id+"_groupElement_shadow"))&&u.parentNode.removeChild(u),f=l?{id:c,x:e.x.toString(),y:e.y.toString(),width:e.width.toString(),height:e.height.toString(),visibility:e.visible?"visible":"hidden",transform:"rotate("+e.angle+","+(e.x+e.width/2)+","+(e.y+e.height/2)+")",rx:e.cornerRadius||0,ry:e.cornerRadius||0,opacity:e.opacity}:{id:c,x:e.x.toString(),y:e.y.toString(),width:e.width.toString(),height:e.height.toString(),visibility:e.visible?"visible":"hidden",transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")",rx:e.cornerRadius||0,ry:e.cornerRadius||0,opacity:e.opacity},a&&(f.role="img",f["aria-label"]=a);var p=e.class||"";h||(p.includes("e-diagram-resize-handle")||p.includes("e-diagram-endpoint-handle")||p.includes("e-diagram-bezier-control-handle"))&&(p+=" e-disabled"),e.class&&(f.class=p),a||(f["pointer-events"]="none"),ii(d,f),this.setSvgStyle(d,e,i)},n.prototype.updateSelectionRegion=function(t,e){var i;i=t.parentNode.getElementById(e.id);var r={id:e.id,x:e.x.toString(),y:e.y.toString(),width:e.width.toString(),height:e.height.toString(),transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")",class:"e-diagram-selected-region"};i||(i=document.createElementNS("http://www.w3.org/2000/svg","rect"),t.appendChild(i)),this.setSvgStyle(i,e),ii(i,r)},n.prototype.createGElement=function(t,e){return Fi(t,e)},n.prototype.drawLine=function(t,e){var i=document.createElementNS("http://www.w3.org/2000/svg","line");this.setSvgStyle(i,e);var r=e.x+e.width*e.pivotX,s=e.y+e.height*e.pivotY,o={id:e.id,x1:e.startPoint.x+e.x,y1:e.startPoint.y+e.y,x2:e.endPoint.x+e.x,y2:e.endPoint.y+e.y,stroke:e.stroke,"stroke-width":e.strokeWidth.toString(),opacity:e.opacity.toString(),transform:"rotate("+e.angle+" "+r+" "+s+")",visibility:e.visible?"visible":"hidden"};e.class&&(o.class=e.class),ii(i,o),t.appendChild(i)},n.prototype.drawCircle=function(t,e,i,r){var s=document.createElementNS("http://www.w3.org/2000/svg","circle");this.setSvgStyle(s,e);var o=e.class||"";i||(o+=" e-disabled");var a={id:e.id,cx:e.centerX,cy:e.centerY,r:e.radius,visibility:e.visible?"visible":"hidden",class:o};r&&(a.role="img",a["aria-label"]=r),s.style.display=e.visible?"block":"none",ii(s,a),t.appendChild(s)},n.prototype.drawPath=function(t,e,i,r,s,o,a){var h,c,l=[];l=XB(l=xd(e.data)),e.shadow&&this.renderShadow(e,t,l,s),s&&!e.shadow&&(h=s.getElementById(e.id+"_groupElement_shadow"))&&h.parentNode.removeChild(h),s&&(c=s.getElementById(e.id)),(!c||r)&&(c=document.createElementNS("http://www.w3.org/2000/svg","path"),t.appendChild(c)),this.renderPath(c,e,l);var d={};d=a?{id:e.id,transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")translate("+e.x+","+e.y+"),scale("+a+")",visibility:e.visible?"visible":"hidden",opacity:e.opacity}:{id:e.id,transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")translate("+e.x+","+e.y+")",visibility:e.visible?"visible":"hidden",opacity:e.opacity},o&&(d.role="img",d["aria-label"]=o),e.class&&(d.class=e.class),ii(c,d),this.setSvgStyle(c,e,i)},n.prototype.renderPath=function(t,e,i){var r,s,o,a,l,h,c,d,u=i,f="";for(l=0,h=0,d=0,c=u.length;de.width&&"Wrap"!==e.textOverflow&&"NoWrap"===e.textWrapping&&(h[0].text=VF(e.content,e)),v=0;vD&&(u.text=u.text.slice(0,u.text.length-3),u.text=u.text.concat("..."),l.data=u.text),this.alignText(y,f,u,l,p,g,v,e,h),C+=u.dy}}C&&e.isHorizontalLane&&(M=e.parentOffsetX+e.pivotX,w=e.parentOffsetY+e.pivotY,e.y=e.parentOffsetY-C*e.pivotY+.5),e.textDecoration&&"LineThrough"===e.textDecoration&&(e.textDecoration=fb(e.textDecoration));var P={id:e.id+"_text",fill:e.color,visibility:e.visible?"visible":"hidden","text-decoration":e.textDecoration,transform:"rotate("+e.angle+","+M+","+w+")translate("+e.x+","+e.y+")",opacity:e.opacity};r&&(P.role="img",P["aria-label"]=r),ii(y,P)}},n.prototype.alignText=function(t,e,i,r,s,o,a,l,h){"justify"!==l.textAlign?this.setText(t,e,i,r,s,o,l):a!==h.length-1?this.setText(t,e,i,r,s,o,l,l.width,"spacing"):this.setText(t,e,i,r,s,o,l)},n.prototype.setText=function(t,e,i,r,s,o,a,l,h){ii(e,"justify"!==a.textAlign?{x:s.toString(),y:o.toString()}:{x:s.toString(),y:o.toString(),textLength:l||0,lengthAdjust:h||"spacing"}),t.setAttribute("fill",i.text),e.appendChild(r),t.appendChild(e)},n.prototype.drawImage=function(t,e,i,r){var s;i&&(s=i.getElementById(e.id+"image")),s||(s=document.createElementNS("http://www.w3.org/2000/svg","image"),t.appendChild(s));var o=new Image;o.src=e.source;var a="None"!==e.scale?e.scale:"",l=e.alignment,h=l.charAt(0).toLowerCase()+l.slice(1);"Stretch"!==a&&(h+=" "+a.charAt(0).toLowerCase()+a.slice(1)),ii(s,{id:e.id+"image",x:e.x.toString(),y:e.y.toString(),transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")",width:e.width.toString(),visibility:e.visible?"visible":"hidden",height:e.height.toString(),preserveAspectRatio:h,opacity:e.opacity.toString()}),s.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",o.src.toString())},n.prototype.drawHTMLContent=function(t,e,i,r,s){var o,a;if(e&&(o=e.querySelector("#"+t.id+"_html_element")),!o){(a=e.querySelector("#"+t.id+"_html_element")||e.querySelector("#"+t.nodeId+"_html_element"))||(a=Tt("div",{id:t.nodeId+"_html_element",class:"foreign-object"})),o=Tt("div",{id:t.id+"_html_element",class:"foreign-object"});var c=document.getElementById(t.diagramId).ej2_instances[0],d=!1;if(e.parentNode&&e.parentNode.parentNode&&e.parentNode.parentNode.parentNode&&e.parentNode.parentNode.parentNode.classList.contains("e-overview")&&(d=!0),d)c.isReact?c.renderReactTemplates(function(){o.appendChild(t.template.cloneNode(!0))}):o.appendChild(t.template.cloneNode(!0));else{if("string"==typeof t.template){var u=document.createElement("div");u.innerHTML=t.template,t.template=u,c.selectedItems.userHandles.filter(function(g){return g.name===t.id.split("_shape")[0]&&""!==g.template})[0].template=t.template}t.isTemplate&&t.template?o.appendChild(t.template):t.template&&o.appendChild(t.template.cloneNode(!0))}void 0!==s&&e.childNodes.length>s&&e.insertBefore(o,e.childNodes[parseInt(s.toString(),10)]),a.appendChild(o),e.appendChild(a)}var p=xn(t).topLeft;o.setAttribute("style","height:"+t.actualSize.height+"px; width:"+t.actualSize.width+"px;left:"+p.x+"px; top:"+p.y+"px;position:absolute;transform:rotate("+(t.rotateAngle+t.parentTransform)+"deg);pointer-events:"+(r?"all":"none")+";visibility:"+(t.visible?"visible":"hidden")+";opacity:"+t.style.opacity+";")},n.prototype.drawNativeContent=function(t,e,i,r,s){var o,a;if(s&&(o=s.getElementById(t.id+"_native_element"),a=s.getElementById(t.id+"_clip")),!o){(o=document.createElementNS("http://www.w3.org/2000/svg","g")).setAttribute("id",t.id+"_native_element"),o.appendChild(t.template.cloneNode(!0));var l=this.createGElement("g",{id:t.id+"_inner_native_element"});l.appendChild(o),e.appendChild(l)}a&&o.removeChild(a),o.setAttribute("style","visibility:"+(t.visible?"visible":"hidden")+";opacity:"+t.style.opacity+";"),this.setNativTransform(t,o,i,r),"Slice"===t.scale&&this.drawClipPath(t,o,i,r,s),ii(o,t.description?{role:"img","aria-label":t.description}:{})},n.prototype.setNativTransform=function(t,e,i,r){var s=0!==t.contentSize.width?t.contentSize.width:1,o=0!==t.contentSize.height?t.contentSize.height:1;e.setAttribute("transform","rotate("+t.parentTransform+","+t.offsetX+","+t.offsetY+") translate("+(t.offsetX-t.templatePosition.x*r/s-r*t.pivot.x)+","+(t.offsetY-t.templatePosition.y*i/o-i*t.pivot.y)+") scale("+r/s+","+i/o+")")},n.prototype.drawClipPath=function(t,e,i,r,s){var o=t.contentSize.width,a=t.contentSize.height,l=t.width/(r/o),h=t.height/(i/a),c=t.templatePosition.x+(t.width>=t.height?0:(o-l)/2),d=t.templatePosition.y+(t.height>=t.width?0:(a-h)/2),u=s.getElementById(t.id+"_clip");(u=document.createElementNS("http://www.w3.org/2000/svg","clipPath")).setAttribute("id",t.id+"_clip"),e.appendChild(u);var f=s.getElementById(t.id+"_clip_rect");return f=document.createElementNS("http://www.w3.org/2000/svg","rect"),u.appendChild(f),ii(f,{id:t.id+"_clip_rect",width:l.toString(),height:h.toString(),x:c.toString(),y:d.toString()}),sm()?e.setAttribute("clip-path","url("+location.protocol+"//"+location.host+location.pathname+"#"+t.id+"_clip)"):e.setAttribute("clip-path","url(#"+t.id+"_clip)"),e},n.prototype.renderGradient=function(t,e,i){var r,s,o,h,c,a=ST(i),l=a.getElementById(i+"gradient_pattern");if(l||(l=Fi("defs",{id:i+"gradient_pattern"}),a.insertBefore(l,a.firstChild)),gF(e.id),"None"!==t.gradient.type){for(var d=0;dt.width&&("Ellipsis"===t.textOverflow||"Clip"===t.textOverflow)&&"NoWrap"===t.textWrapping?0:.5*t.width:"right"===t.textAlign&&(c=1*t.width),s.x=0+c+(e?e.x:0),s.y=1.2+d-r.height/2,s},n}(),Pc=function(){function n(t,e,i){this.renderer=null,this.isSvgMode=!0,this.touchMove=void 0,this.transform={x:0,y:0},this.diagramId=t,this.element=xt(this.diagramId),this.svgRenderer=e,this.isSvgMode=i,this.renderer=i?new Jf:new bo}return n.prototype.setCursor=function(t,e){t.style.cursor=e},n.prototype.setLayers=function(){this.iconSvgLayer=this.element.getElementsByClassName("e-ports-expand-layer")[0],this.adornerSvgLayer=this.element.getElementsByClassName("e-adorner-layer")[0],this.nativeSvgLayer=this.element.getElementsByClassName("e-native-layer")[0],this.diagramSvgLayer=this.element.getElementsByClassName("e-diagram-layer")[0]},n.prototype.getAdornerLayer=function(){return mT(this.diagramId)},n.prototype.getParentSvg=function(t,e,i){return this.diagramId&&t&&t.id?t.id.split("_icon_content").length>1||t.id.split("_nodeport").length>1||t.elementActions&Xr.ElementIsPort?this.iconSvgLayer:e&&"selector"===e?this.adornerSvgLayer:t instanceof En?this.nativeSvgLayer:this.diagramSvgLayer:i},n.prototype.getParentElement=function(t,e,i,r){var s=e;if(i&&this.diagramId&&t&&t.id){t.id.split("_icon_content").length>1?(s=i.getElementById(this.diagramId+"_diagramExpander"),e=null):t.id.split("_nodeport").length>1?s=i.getElementById(this.diagramId+"_diagramPorts"):t instanceof En?(s=i.getElementById(this.diagramId+"_nativeLayer"),e=null):t.elementActions&Xr.ElementIsPort?(s=i.getElementById(this.diagramId+"_diagramPorts"),e=null):s=i.getElementById(this.diagramId+"_diagramLayer");var o=this.getGroupElement(t,e||s,r);s=o.g,o.svg&&(i=o.svg)}return{g:s,svg:i}},n.prototype.getGroupElement=function(t,e,i){var r,o,s=this.getParentSvg(t);if(e&&s){if(s&&!(r=s.getElementById(t.id+"_groupElement"))&&s!==this.nativeSvgLayer){var a=this.nativeSvgLayer;r=a.getElementById(t.id+"_groupElement"),o=a}r||(r=this.svgRenderer.createGElement("g",{id:t.id+"_groupElement"}),void 0!==i&&e.childNodes.length>i?e.insertBefore(r,e.childNodes[parseInt(i.toString(),10)]):e.appendChild(r))}return{g:r,svg:o}},n.prototype.renderElement=function(t,e,i,r,s,o,a,l,h,c,d){t instanceof Cs?(t.id=t.id?t.id:Qe(),this.renderContainer(t,e,i,r,s,o,a,l,h,c,d)):t instanceof CI?this.renderImageElement(t,e,r,s,a):t instanceof Ze?this.renderPathElement(t,e,r,s,a,h,d):t instanceof li?this.renderTextElement(t,e,r,s,a,c):t instanceof En?this.renderNativeElement(t,e,r,s,a):t instanceof es?this.renderHTMLElement(t,e,i,r,s,a,l):this.renderRect(t,e,r,s,h)},n.prototype.drawSelectionRectangle=function(t,e,i,r,s,o){var a={width:i*o.scale,height:r*o.scale,x:.5+(t=(t+o.tx)*o.scale),y:.5+(e=(e+o.ty)*o.scale),fill:"transparent",stroke:"gray",angle:0,pivotX:.5,pivotY:.5,strokeWidth:1,dashArray:"6 3",opacity:1,visible:!0,id:s.id+"_selected_region"},l=this.getAdornerLayer();this.svgRenderer.updateSelectionRegion(l,a)},n.prototype.renderHighlighter=function(t,e,i){var r=t.actualSize.width||2,s=t.actualSize.height||2,o=t.offsetX-r*t.pivot.x,a=t.offsetY-s*t.pivot.y;this.svgRenderer.drawRectangle(e,{width:r*i.scale,height:s*i.scale,x:o=(o+i.tx)*i.scale,y:a=(a+i.ty)*i.scale,fill:"transparent",stroke:"#8CC63F",angle:t.rotateAngle,pivotX:t.pivot.x,pivotY:t.pivot.y,strokeWidth:4,dashArray:"",opacity:1,cornerRadius:0,visible:!0,id:e.id+"_highlighter",class:"e-diagram-highlighter"},this.diagramId,void 0,void 0,e)},n.prototype.renderSelectionRectangle=function(t,e,i,r){var s=t.actualSize.width||2,o=t.actualSize.height||2,a=t.offsetX-s*t.pivot.x,l=t.offsetY-o*t.pivot.y,h={width:s*i.scale,height:o*i.scale,x:a=(a+i.tx)*i.scale,y:l=(l+i.ty)*i.scale,fill:"transparent",stroke:"#00cc00",angle:t.rotateAngle,pivotX:t.pivot.x,pivotY:t.pivot.y,strokeWidth:r?2:1,dashArray:"",opacity:1,cornerRadius:0,visible:!0,id:t.id+"_highlighter",class:r?"e-diagram-first-selection-indicator e-diagram-selection-indicator":"e-diagram-selection-indicator"},c=this.getParentSvg(t,"selector");this.svgRenderer.drawRectangle(e,h,this.diagramId,void 0,void 0,c)},n.prototype.renderSelectionLine=function(t,e,i,r){var s=this.getBaseAttributes(t,i);s.data=t.absolutePath,s.id=s.id+"_highlighter";var o=t.description?t.description:t.id;this.isSvgMode||(s.x=t.flipOffset.x?t.flipOffset.x:s.x,s.y=t.flipOffset.y?t.flipOffset.y:s.y),i&&(s.x=s.x*i.scale,s.y=s.y*i.scale),s.stroke="#00cc00",s.strokeWidth=r?2:1,s.class=r?"e-diagram-first-selection-indicator e-diagram-selection-indicator":"e-diagram-selection-indicator";var a=this.getParentSvg(t,"selector");this.svgRenderer.drawPath(e,s,this.diagramId,void 0,a,o,i.scale)},n.prototype.renderStackHighlighter=function(t,e,i,r,s,o,a){var l=t.actualSize.width||2,h=t.offsetX-l*t.pivot.x,c=t.actualSize.height||2,d=t.offsetY-c*t.pivot.y;h=(h+i.tx)*i.scale;var u,f=t.bounds,p="";if(d=(d+i.ty)*i.scale,r)if(o){var v,y;u="M 0 0 L "+(2+(g=l*i.scale))+" 0 Z",v=t.actualSize.width/Number(f.width?f.width:1)*i.scale,y=t.actualSize.height/Number(f.height?f.height:1)*i.scale,p=SI(II(xd("M7,4 L8,4 8,7 11,7 11,8 8,8 8,11 7,11 7,8 4,8 4,7 7,7 z M7.5,0.99999994C3.9160004,1 1,3.9160004 0.99999994,7.5 1,11.084 3.9160004,14 7.5,14 11.084,14 14,11.084 14,7.5 14,3.9160004 11.084,1 7.5,0.99999994 z M7.5,0 C11.636002,0 15,3.3639984 15,7.5 15,11.636002 11.636002,15 7.5,15 3.3640003,15 0,11.636002 0,7.5 0,3.3639984 3.3640003,0 7.5,0 z")),v+g+2,y-8,!1,f.x,f.y,0,0),s.y>=t.offsetY&&(d+=c)}else{var g;a&&s.y>=t.offsetY&&(d+=c*i.scale),u="M -10 -10 L 0 0 Z M -10 10 L 0 0 Z M 0 0 L "+(g=l*i.scale)+" 0 Z M "+g+" 0 L "+(g+10)+" 10 Z L "+(g+10)+" -10 Z"}else u="M 10 -10 L 0 0 Z M -10 -10 L 0 0 Z M 0 0 L 0 "+(g=c*i.scale)+" Z M 0 "+g+" L -10 "+(g+10)+" Z L 10 "+(g+10)+" Z",s.x>=t.offsetX&&(h+=l*i.scale);this.svgRenderer.drawPath(e,{data:u+p,width:l*i.scale,height:c*i.scale,x:h,y:d,fill:"transparent",stroke:"#8CC63F",angle:t.rotateAngle,pivotX:t.pivot.x,pivotY:t.pivot.y,strokeWidth:1,dashArray:"",opacity:1,visible:!0,id:e.id+"_stack_highlighter",class:"e-diagram-highlighter"},this.diagramId)},n.prototype.drawLine=function(t,e){this.svgRenderer.drawLine(t,e)},n.prototype.drawPath=function(t,e){this.svgRenderer.drawPath(t,e,this.diagramId)},n.prototype.renderResizeHandle=function(t,e,i,r,s,o,a,l,h,c,d){var u=t.offsetX-t.actualSize.width*t.pivot.x,f=t.offsetY-t.actualSize.height*t.pivot.y,p=t.actualSize.height,g=t.actualSize.width;if(!c&&i&bt.Rotate&&_I(this.rendererActions)&&!A3(this.rendererActions))this.renderPivotLine(t,e,o,s,a),this.renderRotateThumb(t,e,o,s,a);else if(this.touchMove){var v=document.getElementById("rotateThumb");v&&v.setAttribute("visibility","hidden")}this.renderBorder(t,e,o,l,h,c);var y=t.actualSize.width*r,S=t.actualSize.height*r;!h&&_I(this.rendererActions)&&!A3(this.rendererActions)&&(t.isTextAnnotation||(y>=40&&S>=40&&(s&mr.ResizeNorthWest&&this.renderCircularHandle("resizeNorthWest",t,u,f,e,qr(s,"ResizeNorthWest"),i&bt.ResizeNorthWest,o,void 0,a,{"aria-label":"Thumb to resize the selected object on top left side direction"},void 0,"e-diagram-resize-handle e-northwest",d),s&mr.ResizeNorthEast&&this.renderCircularHandle("resizeNorthEast",t,u+g,f,e,qr(s,"ResizeNorthEast"),i&bt.ResizeNorthEast,o,void 0,a,{"aria-label":"Thumb to resize the selected object on top right side direction"},void 0,"e-diagram-resize-handle e-northeast",d),s&mr.ResizeSouthWest&&this.renderCircularHandle("resizeSouthWest",t,u,f+p,e,qr(s,"ResizeSouthWest"),i&bt.ResizeSouthWest,o,void 0,a,{"aria-label":"Thumb to resize the selected object on bottom left side direction"},void 0,"e-diagram-resize-handle e-southwest",d),s&mr.ResizeSouthEast&&this.renderCircularHandle("resizeSouthEast",t,u+g,f+p,e,qr(s,"ResizeSouthEast"),i&bt.ResizeSouthEast,o,void 0,a,{"aria-label":"Thumb to resize the selected object on bottom right side direction"},void 0,"e-diagram-resize-handle e-southeast",d)),s&mr.ResizeNorth&&this.renderCircularHandle("resizeNorth",t,u+g/2,f,e,qr(s,"ResizeNorth"),i&bt.ResizeNorth,o,void 0,a,{"aria-label":"Thumb to resize the selected object on top side direction"},void 0,"e-diagram-resize-handle e-north",d),s&mr.ResizeSouth&&this.renderCircularHandle("resizeSouth",t,u+g/2,f+p,e,qr(s,"ResizeSouth"),i&bt.ResizeSouth,o,void 0,a,{"aria-label":"Thumb to resize the selected object on bottom side direction"},void 0,"e-diagram-resize-handle e-south",d),s&mr.ResizeWest&&this.renderCircularHandle("resizeWest",t,u,f+p/2,e,qr(s,"ResizeWest"),i&bt.ResizeWest,o,void 0,a,{"aria-label":"Thumb to resize the selected object on left side direction"},void 0,"e-diagram-resize-handle e-west",d),s&mr.ResizeEast&&this.renderCircularHandle("resizeEast",t,u+g,f+p/2,e,qr(s,"ResizeEast"),i&bt.ResizeEast,o,void 0,a,{"aria-label":"Thumb to resize the selected object on right side direction"},void 0,"e-diagram-resize-handle e-east",d)))},n.prototype.renderEndPointHandle=function(t,e,i,r,s,o,a,l,h,c){var p,g,d=t.sourcePoint,u=t.targetPoint,f=t.wrapper;if(this.renderCircularHandle("connectorSourceThumb",f,d.x,d.y,e,qr(r,"ConnectorSourceThumb"),i&bt.ConnectorSource,s,o,void 0,{"aria-label":"Thumb to move the source point of the connector"},void 0,"e-diagram-endpoint-handle e-sourceend",c),this.renderCircularHandle("connectorTargetThumb",f,u.x,u.y,e,qr(r,"ConnectorTargetThumb"),i&bt.ConnectorTarget,s,a,void 0,{"aria-label":"Thumb to move the target point of the connector"},void 0,"e-diagram-endpoint-handle e-targetend",c),l)if("Straight"===t.type&&t.segments.length>0)for(p=0;p0)for(p=0;p=3&&3===t.segments.length&&(S=1,b=t.segments.length-1),S=t.segments.length>t.maxSegmentThumb+2?2:S,b=t.segments.length>t.maxSegmentThumb+2?t.segments.length-2:b,1===t.segments.length&&t.segments[0].points.length<=2&&(S=1,b=t.segments.length),p=S;p=50&&i.allowDrag),this.renderOrthogonalThumb(t+"_"+(d+1),e,(i.points[parseInt(d.toString(),10)].x+i.points[d+1].x)/2,(i.points[parseInt(d.toString(),10)].y+i.points[d+1].y)/2,r,h,l,o,a,u)}else for(d=0;d=50&&i.allowDrag),this.renderOrthogonalThumb(t+"_"+(d+1),e,(i.points[parseInt(d.toString(),10)].x+i.points[d+1].x)/2,(i.points[parseInt(d.toString(),10)].y+i.points[d+1].y)/2,r,h,l,o,a,u)},n.prototype.renderOrthogonalThumb=function(t,e,i,r,s,o,a,l,h,c){var d,g,u=0,f=document.getElementById(this.diagramId);f&&(g=f.ej2_instances[0]);var y=h.constraints&qe.InheritSegmentThumbShape?g.segmentThumbShape:h.segmentThumbShape,b=h.constraints&qe.InheritSegmentThumbSize?g.segmentThumbSize:h.segmentThumbSize;if(d="horizontal"===a?function rre(n){return are[""+n]}(y):n3(y),"Arrow"===y||"DoubleArrow"===y||"OpenArrow"===y)switch(c){case"Bottom":case"Right":u=180;break;default:u=0}else if("Fletch"===y||"OpenFetch"===y||"IndentedArrow"===y||"OutdentedArrow"===y)switch(c){case"Bottom":u=-90;break;case"Top":u=90;break;case"Right":u=180;break;default:u=0}var M={x:(i+l.tx)*l.scale-b/2,y:(r+l.ty)*l.scale-b/2,angle:u,fill:"#e2e2e2",stroke:"black",strokeWidth:1,dashArray:"",data:d,width:b,height:b,pivotX:.5,pivotY:.5,opacity:1,visible:o,id:t,class:"e-diagram-ortho-segment-handle"},w=op(M.data),C=new me(M.width,M.height),D=new Ze;if(M.data=D.updatePath(M.data,w,C),this.touchMove){var A=document.getElementById(t);A?this.updateSegmentPosition(A,M):this.svgRenderer.drawPath(s,M,this.diagramId)}else this.svgRenderer.drawPath(s,M,this.diagramId)},n.prototype.renderPivotLine=function(t,e,i,r,s){var o=t,l=!!(r&mr.Rotate);s&&(l=!1);var h=this.getBaseAttributes(o,i);h.fill="None",h.stroke="black",h.strokeWidth=1,h.dashArray="2,3",h.visible=l;var c=i.scale;h.x*=c,h.y*=c,h.width*=c,h.height*=c,h.id="pivotLine",h.class="e-diagram-pivot-line";var u={x:o.actualSize.width*o.pivot.x*c,y:0};h.startPoint={x:o.actualSize.width*o.pivot.x*c,y:-20},h.endPoint=u,this.svgRenderer.drawLine(e,h)},n.prototype.renderBezierLine=function(t,e,i,r,s,o){var l=this.getBaseAttributes(e,o);l.id=t,l.stroke="black",l.strokeWidth=1,l.dashArray="3,3",l.fill="None",l.class="e-diagram-bezier-control-line",l.x=0,l.y=0;var h=o.scale,g={x:(s.x+o.tx)*h,y:(s.y+o.ty)*h};l.startPoint={x:(r.x+o.tx)*h,y:(r.y+o.ty)*h},l.endPoint=g,this.svgRenderer.drawLine(i,l)},n.prototype.renderCircularHandle=function(t,e,i,r,s,o,a,l,h,c,d,u,f,p){var g=e,v={x:i,y:r};if(0!==g.rotateAngle||0!==g.parentTransform){var y=Bi();qi(y,g.rotateAngle+g.parentTransform,g.offsetX,g.offsetY),v=Ke(y,v)}var S=this.getBaseAttributes(g);if(S.stroke="black",S.strokeWidth=1,void 0!==u?(S.id="segmentEnd_"+u,S.fill="#e2e2e2"):S.fill=h?"#8CC63F":"white",S.cornerRadius=p/2,S.angle=e.rotateAngle,S.id=t,S.visible=o,S.class=f,S.width=p,S.height=p,S.x=(v.x+l.tx)*l.scale,S.y=(v.y+l.ty)*l.scale,S.x=S.x-S.width/2,S.y=S.y-S.height/2,h&&(S.class+=" e-connected"),c&&(S.visible=!1),this.touchMove){var b=document.getElementById(t);if(b)this.updateResizeHandle(b,S);else{var M=this.getParentSvg(e,"selector");this.svgRenderer.drawRectangle(s,S,this.diagramId,!0,!0,M,d,!0,a)}}else M=this.getParentSvg(e,"selector"),this.svgRenderer.drawRectangle(s,S,this.diagramId,!0,!0,M,d,!0,a)},n.prototype.updateResizeHandle=function(t,e){ii(t,{id:e.id,x:e.x.toString(),y:e.y.toString(),width:e.width.toString(),height:e.height.toString(),visibility:e.visible?"visible":"hidden",transform:"rotate("+e.angle+","+(e.x+e.width/2)+","+(e.y+e.height/2)+")",rx:e.cornerRadius||0,ry:e.cornerRadius||0,opacity:e.opacity})},n.prototype.renderBezierHandle=function(t,e,i,r,s,o,a,l,h,c,d,u,f){var v,p=document.getElementById(this.diagramId);p&&(v=p.ej2_instances[0]);var y=e,S={x:i,y:r};if(0!==y.rotateAngle||0!==y.parentTransform){var b=Bi();qi(b,y.rotateAngle+y.parentTransform,y.offsetX,y.offsetY),S=Ke(b,S)}var D=a.constraints&qe.InheritSegmentThumbSize?v.segmentThumbSize:a.segmentThumbSize,A=n3(a.constraints&qe.InheritSegmentThumbShape?v.segmentThumbShape:a.segmentThumbShape),x=this.getBaseAttributes(y);x.stroke="black",x.strokeWidth=1,void 0!==d?(x.id="segmentEnd_"+d,x.fill="#e2e2e2"):x.fill=h?"#8CC63F":"white",x.angle=e.rotateAngle,x.id=t,x.visible=o,x.class=u,x.width=D,x.height=D,x.data=A,x.x=(S.x+l.tx)*l.scale,x.y=(S.y+l.ty)*l.scale,x.x=x.x-x.width/2,x.y=x.y-x.height/2,h&&(x.class+=" e-connected"),c&&(x.visible=!1);var P=op(x.data),L=new me(x.width,x.height),O=new Ze;if(x.data=O.updatePath(x.data,P,L),this.touchMove){var N=document.getElementById(t);if(N)this.updateSegmentPosition(N,x);else{var T=this.getParentSvg(e,"selector");this.svgRenderer.drawPath(s,x,this.diagramId,!0,T)}}else T=this.getParentSvg(e,"selector"),this.svgRenderer.drawPath(s,x,this.diagramId,!0,T)},n.prototype.updateSegmentPosition=function(t,e){ii(t,{id:e.id,transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")translate("+e.x+","+e.y+")",visibility:e.visible?"visible":"hidden",opacity:e.opacity})},n.prototype.renderBorder=function(t,e,i,r,s,o){var l=this.getBaseAttributes(t,i);l.x*=i.scale,l.y*=i.scale,l.width*=i.scale,l.height*=i.scale,l.fill="transparent",l.stroke="#097F7F",l.strokeWidth=1.2,l.gradient=null,l.dashArray="6,3",l.class="e-diagram-selector",o&&(l.class+=" e-diagram-lane"),l.id="borderRect",l.id=this.rendererActions&Ga.DrawSelectorBorder?"borderRect_symbol":"borderRect",r||(l.class+=" e-disabled"),s&&(l.class+=" e-thick-border"),l.cornerRadius=0;var h=this.getParentSvg(t,"selector");this.svgRenderer.drawRectangle(e,l,this.diagramId,void 0,!0,h)},n.prototype.renderUserHandler=function(t,e,i,r,s,o){for(var l,a=t.wrapper,h=0,c=t.userHandles;h0||d.disableNodes&&t.nodes.length>0||"Drag"===s&&o)&&(l=!1);var u=document.getElementById(d.name+"_template_hiddenUserHandle");u&&(d.template=u.childNodes[0].cloneNode(!0));var f=tT(t,d,i);if(f.x=(f.x+i.tx)*i.scale,f.y=(f.y+i.ty)*i.scale,d.visible&&(d.visible=!!(t.constraints&mr.UserHandle)),l)if(d.pathData){var p=d.pathData?d.pathData:d.content,g=this.getBaseAttributes(a);g.id=d.name+"_userhandle",g.fill=d.backgroundColor,g.stroke=d.borderColor,g.strokeWidth=d.borderWidth,g.centerX=f.x,g.centerY=f.y,g.radius=.5*d.size,g.class="e-diagram-userhandle-circle",g.angle=0,g.visible=d.visible,g.opacity=1,this.svgRenderer.drawCircle(e,g,1,{"aria-label":d.name+"user handle"});var y=[];y=II(y=xd(p));var S=op(p),w=SI(y,(d.size-.45*d.size)/S.width,(d.size-.45*d.size)/S.height,!0,S.x,S.y,0,0);S=op(w),this.svgRenderer.drawPath(e,C={x:f.x-S.width/2,y:f.y-S.height/2,angle:0,id:"",class:"e-diagram-userhandle-path",fill:d.pathColor,stroke:d.backgroundColor,strokeWidth:.5,dashArray:"",data:w,width:d.size-5,height:d.size-5,pivotX:0,pivotY:0,opacity:1,visible:d.visible},this.diagramId,void 0,void 0,{"aria-label":d.name+"user handle"})}else if(d.content){var D=new En(d.name,this.diagramId);D.content=d.content,D.offsetX=f.x,D.offsetY=f.y,D.id=d.name+"_shape",D.horizontalAlignment="Center",D.verticalAlignment="Center",D.visible=d.visible,D.setOffsetWithRespectToBounds(f.x,f.y,"Fraction"),D.relativeMode="Object",D.description=d.name||"User handle",D.measure(new me(d.size,d.size)),D.arrange(D.desiredSize),this.svgRenderer.drawNativeContent(D,e,d.size,d.size,this.adornerSvgLayer)}else if(d.source){var C,A=new CI;(C=this.getBaseAttributes(A,i)).width=d.size,C.height=d.size,C.x=f.x-d.size/2,C.y=f.y-d.size/2,C.sourceWidth=d.size,C.sourceHeight=d.size,C.alignment=A.imageAlign,C.source=d.source,C.scale=A.imageScale,C.visible=d.visible,C.description=d.name||"User handle",C.id=d.name+"_",this.renderer.drawImage(e,C,this.adornerSvgLayer,!1)}else{var x=new es(d.name,this.diagramId);x.offsetX=f.x,x.offsetY=f.y,x.id=d.name+"_shape",x.visible=d.visible,x.relativeMode="Object",x.template=d.template,x.measure(new me(d.size,d.size)),x.arrange(x.desiredSize),this.svgRenderer.drawHTMLContent(x,r,void 0,!0,void 0)}}},n.prototype.renderRotateThumb=function(t,e,i,r,s){new Ze;var a,l=new me;l.width=18,l.height=16;var d=!!(r&mr.Rotate);s&&(d=!1);var f=t.offsetX-t.actualSize.width*t.pivot.x+t.pivot.x*t.actualSize.width,p=t.offsetY-t.actualSize.height*t.pivot.y;if(a={x:(f=(f+i.tx)*i.scale)-.5*l.width,y:(p=(p+i.ty)*i.scale)-30-.5*l.height},0!==t.rotateAngle||0!==t.parentTransform){var g=Bi();qi(g,t.rotateAngle+t.parentTransform,(i.tx+t.offsetX)*i.scale,(i.ty+t.offsetY)*i.scale),a=Ke(g,a)}var v={x:a.x,y:a.y,angle:t.rotateAngle+t.parentTransform,fill:"#231f20",stroke:"black",strokeWidth:.5,dashArray:"",data:"M 16.856144362449648 10.238890446662904 L 18.000144362449646 3.437890446662903L 15.811144362449646 4.254890446662903 C 14.837144362449646 2.5608904466629028 13.329144362449647 1.2598904466629026 11.485144362449645 0.5588904466629026 C 9.375144362449646 - 0.24510955333709716 7.071144362449646 - 0.18010955333709716 5.010144362449646 0.7438904466629028 C 2.942144362449646 1.6678904466629028 1.365144362449646 3.341890446662903 0.558144362449646 5.452890446662903 C - 0.244855637550354 7.567890446662903 - 0.17985563755035394 9.866890446662904 0.7431443624496461 11.930890446662904 C 1.6681443624496461 13.994890446662904 3.343144362449646 15.575890446662903 5.457144362449647 16.380890446662903 C 6.426144362449647 16.7518904466629 7.450144362449647 16.9348904466629 8.470144362449647 16.9348904466629 C 9.815144362449647 16.9348904466629 11.155144362449647 16.6178904466629 12.367144362449647 15.986890446662901 L 11.351144362449647 14.024890446662901 C 9.767144362449647 14.8468904466629 7.906144362449647 14.953890446662902 6.237144362449647 14.3178904466629 C 4.677144362449647 13.7218904466629 3.444144362449647 12.5558904466629 2.758144362449647 11.028890446662901 C 2.078144362449646 9.501890446662903 2.031144362449646 7.802890446662903 2.622144362449646 6.243890446662903 C 3.216144362449646 4.6798904466629025 4.387144362449646 3.442890446662903 5.914144362449646 2.760890446662903 C 7.437144362449646 2.078890446662903 9.137144362449646 2.0298904466629026 10.700144362449645 2.6258904466629027 C 11.946144362449646 3.100890446662903 12.971144362449646 3.9538904466629026 13.686144362449646 5.049890446662903 L 11.540144362449645 5.850890446662903 L 16.856144362449648 10.238890446662904 Z",width:20,height:20,pivotX:0,pivotY:0,opacity:1,visible:d,id:"rotateThumb",class:"e-diagram-rotate-handle"};if(this.touchMove){var y=document.getElementById("rotateThumb");y?this.updateSegmentPosition(y,v):this.svgRenderer.drawPath(e,v,this.diagramId,!0,void 0,{"aria-label":"Thumb to rotate the selected object"})}else this.svgRenderer.drawPath(e,v,this.diagramId,!0,void 0,{"aria-label":"Thumb to rotate the selected object"})},n.prototype.renderPathElement=function(t,e,i,r,s,o,a){var l=this.getBaseAttributes(t,i,o);if(l.data=t.absolutePath,l.data=t.absolutePath,t.isPathPort&&a){l.x=a[t.id]?a[t.id].cx:l.x,l.y=a[t.id]?a[t.id].cy:l.y,t.bounds.x=l.x,t.bounds.y=l.y;var h=document.getElementById(this.diagramId);h&&"PortDrag"!==h.ej2_instances[0].eventHandler.currentAction&&(t.offsetX=l.x+t.width/2,t.offsetY=l.y+t.height/2)}var u=t.description?t.description:t.id;if(this.isSvgMode||(l.x=t.flipOffset.x?t.flipOffset.x:l.x,l.y=t.flipOffset.y?t.flipOffset.y:l.y),t.isExport){var f=t.absoluteBounds,p=xd(l.data),g=this.findAndStoreArcValues(p);l.arc=g,l.data=OF(t,f,0,l)}this.renderer.drawPath(e,l,this.diagramId,void 0,r,u)},n.prototype.findAndStoreArcValues=function(t){var e=[];return t.forEach(function(i){"A"===i.command&&e.push({r1:i.r1/2,r2:i.r2/2})}),e},n.prototype.renderSvgGridlines=function(t,e,i,r,s,o){var a=document.createElementNS("http://www.w3.org/2000/svg","pattern"),l=document.createElementNS("http://www.w3.org/2000/svg","defs");l.setAttribute("id",this.diagramId+"_grid_pattern_defn"),(t.constraints&ei.ShowHorizontalLines||t.constraints&ei.ShowVerticalLines)&&a.setAttribute("id",this.diagramId+"_pattern");var h=0,c=0,d=0,u=0,f=1,p=!1,g="Lines"===t.gridType,v=g?t.verticalGridlines.lineIntervals:t.verticalGridlines.dotIntervals,y=g?t.horizontalGridlines.lineIntervals:t.horizontalGridlines.dotIntervals;if(r.showRulers&&r.dynamicGrid&&s&&o)d=o.updateSegmentWidth(i.scale),u=s.updateSegmentWidth(i.scale),t.horizontalGridlines.scaledIntervals=[d/s.interval],t.verticalGridlines.scaledIntervals=[u/o.interval],p=!0;else{for(var S=0;S=2)for(;e>=2;)e/=2;else if(e<=.5)for(;e<=.5;)e*=2;var i;if(t.horizontalGridlines.scaledIntervals=t.horizontalGridlines.snapIntervals,t.verticalGridlines.scaledIntervals=t.verticalGridlines.snapIntervals,1!==e){var r=t.horizontalGridlines;for(r.scaledIntervals=[],i=0;ithis.groupElement.actualSize.height&&("Clip"===t.style.textOverflow||"Ellipsis"===t.style.textOverflow)&&(a.y=a.y+(a.height-this.groupElement.actualSize.height)/2),this.renderer.drawRectangle(e,a,this.diagramId,void 0,void 0,r),this.renderer.drawText(e,a,r,l,this.diagramId,t.isExport&&Math.min(t.exportScaleValue.x||t.exportScaleValue.y),this.groupElement),this.isSvgMode&&(t.doWrap=!1)},n.prototype.renderNativeElement=function(t,e,i,r,s){var o,a,l=this.getParentSvg(t,void 0,e)||r,h=this.getParentElement(t,e,l).g||e,c=this.getBaseAttributes(t,i);switch(c.fill="transparent",c.cornerRadius=t.cornerRadius,c.stroke="transparent",this.renderer.drawRectangle(e,c,this.diagramId,void 0,void 0,r),t.scale){case"None":o=t.contentSize.width,a=t.contentSize.height;break;case"Stretch":o=t.actualSize.width,a=t.actualSize.height;break;case"Meet":o=a=t.actualSize.width<=t.actualSize.height?t.actualSize.width:t.actualSize.height;break;case"Slice":o=a=t.actualSize.width>=t.actualSize.height?t.actualSize.width:t.actualSize.height}this.svgRenderer&&this.svgRenderer.drawNativeContent(t,h,a,o,l)},n.prototype.renderHTMLElement=function(t,e,i,r,s,o,a){var l=this.getBaseAttributes(t,r);l.fill="transparent",l.cornerRadius=t.cornerRadius,l.stroke="transparent",this.renderer.drawRectangle(e,l,this.diagramId,void 0,void 0,s),this.svgRenderer&&this.svgRenderer.drawHTMLContent(t,i.children[0],r,function cse(n){var t=n.parentElement;do{if(um(t,"e-diagram"))return!0;t=t.parentElement}while(t);return!1}(i),a)},n.prototype.renderImageElement=function(t,e,i,r,s){var o=this.getBaseAttributes(t,i);o.cornerRadius=0,this.renderer.drawRectangle(e,o,this.diagramId,void 0,void 0,r);var a,l,h,c,g,d=t.contentSize.width,u=t.contentSize.height,f=o.width/d,p=o.height/u;if("Stretch"===t.stretch)a=d*(g=Math.min(f,p)),l=u*g;else switch(t.stretch){case"Meet":a=d*(g=Math.min(f,p)),l=u*g,o.x+=Math.abs(o.width-a)/2,o.y+=Math.abs(o.height-l)/2;break;case"Slice":g=Math.max(f,p),h=o.width/(a=d*g)*d,c=o.height/(l=u*g)*u;break;case"None":a=d,l=u}o.width=a,o.height=l,o.sourceWidth=h,o.sourceHeight=c,o.source=t.source,o.alignment=t.imageAlign,o.scale=t.imageScale,o.description=t.description?t.description:t.id,this.renderer.drawImage(e,o,r,s)},n.prototype.renderContainer=function(t,e,i,r,s,o,a,l,h,c,d){var g,u={svg:s,g:e},f=document.getElementById(this.diagramId);if(f&&(g=f.ej2_instances[0]),this.diagramId&&(s=this.getParentSvg(t)||s,this.isSvgMode)){var v=this.getParentElement(t,e,s,l).g||e;s=this.getParentSvg(this.hasNativeParent(t.children))||s;var y=this.getParentElement(this.hasNativeParent(t.children),v,s,l);u.svg=y.svg||s,u.g=y.g||v,o&&s&&(s.getElementById(u.g.id)||e.appendChild(u.g)),e=u.g}if(this.renderRect(t,e,r,s),this.groupElement=t,t.hasChildren()){for(var b,S=void 0,M=0,w=t.children;M0&&(D=g.selectedItems.nodes[0]);var L,A=void 0,x=void 0,P=!1;if(g&&g.selectedItems&&(L=g.getObject(t.id)),"None"!==t.flip&&(D=L),"None"===t.flip&&(D=L),D&&D.flipMode&&(P=!0),!(t.elementActions&Xr.ElementIsGroup)&&g instanceof Fl&&g.nameTable[t.id]&&"connectors"!==g.nameTable[t.id].propName&&P&&D){if(A=t.children&&t.children[0]instanceof En?document.getElementById(D.id+"_content_inner_native_element"):document.getElementById(D.id+"_content_groupElement"),!(t.children[0]instanceof En)&&"Text"!==D.shape.type&&"None"!==D.flipMode&&"Label"!==D.flipMode&&"All"!==D.flipMode&&"PortAndLabel"!==D.flipMode&&"LabelText"!==D.flipMode&&"PortAndLabelText"!==D.flipMode&&"LabelAndLabelText"!==D.flipMode||t.children[0]instanceof En&&"Port"===D.flipMode)return void this.renderFlipElement(t,A,D.flip);if((t.children[0]instanceof En&&("All"===D.flipMode||"Label"===D.flipMode)||"Label"===D.flipMode||"PortAndLabel"===D.flipMode||"LabelText"===D.flipMode||"PortAndLabelText"===D.flipMode||"LabelAndLabelText"===D.flipMode||"Image"===D.shape.type&&"Label"===D.flipMode)&&this.renderFlipElement(t,A,t.flip),"None"!==t.flip&&"None"===D.flipMode)this.renderFlipElement(t,A,t.flip);else if("None"!==t.flip&&("Label"===D.flipMode||"PortAndLabel"===D.flipMode||"LabelText"===D.flipMode||"PortAndLabelText"===D.flipMode||"LabelAndLabelText"===D.flipMode)||t.children[0]instanceof En&&"None"!==t.flip&&D&&("None"===D.flipMode||"All"===D.flipMode)){for(var O=0;O0){var i=t[0];if(i instanceof En)return i;i.children&&i.children.length&&this.hasNativeParent(i.children,e++||0)}},n.prototype.renderRect=function(t,e,i,r,s){var o=this.getBaseAttributes(t,i,s);o.cornerRadius=t.cornerRadius||0,t.isExport&&(o.cornerRadius*=t.exportScaleValue.x),this.renderer.drawRectangle(e,o,this.diagramId,t.isExport,void 0,r,t.description?t.description:t.id)},n.prototype.drawRect=function(t,e){e.cornerRadius=0,this.svgRenderer.drawRectangle(t,e,this.diagramId)},n.prototype.getBaseAttributes=function(t,e,i){var r={width:t.actualSize.width,height:t.actualSize.height,x:t.offsetX-t.actualSize.width*t.pivot.x,y:t.offsetY-t.actualSize.height*t.pivot.y,fill:t.style.fill,stroke:t.style.strokeColor,angle:t.rotateAngle+t.parentTransform,pivotX:t.pivot.x,pivotY:t.pivot.y,strokeWidth:t.style.strokeWidth,dashArray:t.style.strokeDashArray||"",opacity:t.style.opacity,shadow:t.shadow,gradient:t.style.gradient,visible:t.visible,id:t.id,description:t.description,canApplyStyle:t.canApplyStyle,shapeType:t.shapeType};return"Page"===t.rotationReference&&(r.angle=t.rotateAngle),i&&(r.x=r.x-.5,r.y=r.y-.5),t.isExport&&(r.width*=t.exportScaleValue.x,r.height*=t.exportScaleValue.y,r.x*=t.exportScaleValue.x,r.y*=t.exportScaleValue.y,r.strokeWidth*=t.exportScaleValue.x),t.flip&&(r.flip=t.flip),e&&(r.x+=e.tx,r.y+=e.ty),r},n.renderSvgBackGroundImage=function(t,e,i,r,s,o){if(t.source){var l=ST(e.id).getElementById(e.id+"_image");if(!l){var h=function Soe(n){return xt(n).getElementsByClassName("e-background-image-layer")[0]}(e.id);(l=document.createElementNS("http://www.w3.org/2000/svg","image")).setAttribute("id",e.id+"_image"),h.appendChild(l)}var c=new Image;c.src=t.source,l.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",c.src.toString());var d="None"!==t.scale?t.scale:"",u=t.align,f=u.charAt(0).toLowerCase()+u.slice(1);d&&(f+=" "+d.charAt(0).toLowerCase()+d.slice(1)),ii(l,{id:e.id+"_image",x:i,y:r,width:s,height:o,preserveAspectRatio:f})}},n.prototype.transformLayers=function(t,e){var i=t.tx*t.scale,r=t.ty*t.scale,s="domTable";if(i!==this.transform.x||r!==this.transform.y||0===i||0===r){e&&(window[""+s][this.diagramId+"_diagramLayer"]||(window[""+s][this.diagramId+"_diagramLayer"]=this.diagramSvgLayer.getElementById(this.diagramId+"_diagramLayer")),window[""+s][this.diagramId+"_diagramLayer"].setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+"),scale("+t.scale+")"));var a=function Ioe(n){var t="domTable",e=null;return window[t][n+"_gridline"]?e=window[t][n+"_gridline"]:(e=Ud(n).getElementById(n+"_gridline"),window[t][n+"_gridline"]=e),e}(this.diagramId);return a.setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+")"),window[""+s][this.diagramId+"_diagramPorts"]||(window[""+s][this.diagramId+"_diagramPorts"]=this.iconSvgLayer.getElementById(this.diagramId+"_diagramPorts")),window[""+s][this.diagramId+"_diagramPorts"].setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+"),scale("+t.scale+")"),window[""+s][this.diagramId+"_diagramExpander"]||(window[""+s][this.diagramId+"_diagramExpander"]=this.iconSvgLayer.getElementById(this.diagramId+"_diagramExpander")),window[""+s][this.diagramId+"_diagramExpander"].setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+"),scale("+t.scale+")"),window[""+s][this.diagramId+"_nativeLayer"]||(window[""+s][this.diagramId+"_nativeLayer"]=this.nativeSvgLayer.getElementById(this.diagramId+"_nativeLayer")),window[""+s][this.diagramId+"_nativeLayer"].setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+"),scale("+t.scale+")"),Io(this.diagramId).children[0].style.transform="translate("+t.tx*t.scale+"px,"+t.ty*t.scale+"px)scale("+t.scale+")",this.transform={x:t.tx*t.scale,y:t.ty*t.scale},!0}return!1},n.prototype.updateNode=function(t,e,i,r,s,o,a){this.renderElement(t,e,i,r,this.getParentSvg(t),void 0,void 0,s,null,o,a)},n}(),rse=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),eb=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},oF=function(n){function t(e,i){var r=n.call(this,e,i)||this;return r.mode="Canvas",r.id="overview",r.actionName="",r.startPoint=null,r.currentPoint=null,r.prevPoint=null,r.scale=null,r.inAction=!1,r.viewPortRatio=1,r.horizontalOffset=0,r.verticalOffset=0,r.model={},r.event=!0,r.overviewid=88123,r.model={width:r.width,height:r.height},r}return rse(t,n),t.prototype.onPropertyChanged=function(e,i){for(var r=0,s=Object.keys(e);r0||e.toString().indexOf("%")>0?e.toString():e.toString()+"px"},t.prototype.renderCanvas=function(e){var i=document.getElementById(this.element.id+"_canvas");i||(i=Tt("div",{}),this.element.appendChild(i)),Ho(i,{id:this.element.id+"_canvas",class:"drawing",style:"position:relative; height:"+this.getSizeValue(this.model.height)+"; width:"+this.getSizeValue(this.model.width)+";style:-ms-touch-action: none;touch-action: none;"}),this.element.setAttribute("tabindex",String(-1)),this.element.style.overflow="hidden",this.element.style.height=String(this.model.height),this.element.style.width=String(this.model.width),this.canvas=i},t.prototype.setParent=function(e){var i=document.getElementById(e);if(this.parent){var s=this.parent;this.parent=null,s.setOverview(null,this.element.id),this.removeDocument(this)}this.parent=this.getDiagram(i,"ej2_instances"),this.parent&&this.parent.setOverview(this)},t.prototype.getDiagram=function(e,i){for(var r,s=e[""+i].length,o=0;o0?f:Math.floor(window.innerWidth)}if(0===h){var p=Math.floor(window.innerHeight-u-Math.floor(c.top));h=p>0?p:Math.floor(window.innerHeight)}l>0&&(s.setAttribute("width",String(l)),this.model.height=h),h>0&&(s.setAttribute("height",String(h)),this.model.width=l),e.diagramLayerDiv||(e.diagramLayerDiv=Tt("div",{}),e.diagramLayer=bo.createCanvas(this.element.id+"_diagramLayer",this.model.width,this.model.height),e.diagramLayer.setAttribute("style","position:absolute; left:0px; top:0px "),e.diagramLayerDiv.appendChild(e.diagramLayer),e.canvas.appendChild(e.diagramLayerDiv)),Ho(e.diagramLayerDiv,{id:this.element.id+"_diagramLayer_div",style:"width:"+this.model.width+"px; height:"+this.model.height+"px;position:absolute;top:0px;left:0px"}),this.renderHtmlLayer(e.canvas),this.renderNativeLayer(e.canvas,e),this.addOverviewRectPanel(e)},t.prototype.removeDocument=function(e){var i=document.getElementById(this.canvas.id+"_svg");this.canvas.removeChild(i);var r=document.getElementById(this.element.id+"_htmlLayer");this.canvas.removeChild(r);var s=document.getElementById(this.element.id+"_diagramLayer_div");this.canvas.removeChild(s),e.diagramLayerDiv=null,e.diagramLayer=null,window.domTable[this.id+"html_layer"]=null},t.prototype.renderHtmlLayer=function(e){var i=Tt("div",{id:this.element.id+"_htmlLayer",class:"e-html-layer",style:"pointer-events:none;position:absolute;top:0px;left:0px;"}),s=Tt("div",{id:this.element.id+"_htmlLayer_div",style:"position:absolute;top:0px;left:0px;"});return i.appendChild(s),e.appendChild(i),i},t.prototype.renderNativeLayer=function(e,i){if(!document.getElementById(this.element.id+"_nativeLayer_svg")){var r=this.parent.createSvg(this.element.id+"_nativeLayer_svg",this.model.width,this.model.height),s=Fi("g",{id:this.element.id+"_nativeLayer"});r.appendChild(s),i.diagramLayerDiv.appendChild(r),ii(r,{class:"e-native-layer"})}},t.prototype.addOverviewRectPanel=function(e){var i=document.getElementById(this.canvas.id+"_overviewsvg");i&&i.parentNode.removeChild(i),i=Fi("svg",{id:this.canvas.id+"_overviewsvg",class:"overviewsvg",version:"1.1",style:"position:absolute;left:0px;top:0px; aria-label:Specifies overview",width:this.model.width,height:this.model.height}),e.canvas.appendChild(i);var s=Fi("g",{id:this.element.id+"_overviewlayer",style:"pointer-events:none"});i.appendChild(s);var o=Fi("rect",{fill:"transparent",width:"100%",height:"100%",class:"overviewbackrect",id:this.canvas.id+"overviewbackrect"});o.setAttribute("style"," pointer-events: none; "),s.appendChild(o);var a=Fi("g",{id:this.canvas.id+"overviewhandle",style:"pointer-events:all"});s.appendChild(a);var l=Fi("rect",{id:this.canvas.id+"overviewrect",fill:"transparent"});a.appendChild(l),this.renderOverviewCorner("left",a),this.renderOverviewCorner("right",a),this.renderOverviewCorner("top",a),this.renderOverviewCorner("bottom",a),this.renderOverviewCorner("topleft",a),this.renderOverviewCorner("topright",a),this.renderOverviewCorner("bottomleft",a),this.renderOverviewCorner("bottomright",a)},t.prototype.renderOverviewCorner=function(e,i){var s,o=Fi(s="top"===e||"bottom"===e||"right"===e||"left"===e?"rect":"circle",{id:this.canvas.id+"visible"+e,class:"overview-resizer"});i.appendChild(o);var a=Fi(s,{id:this.canvas.id+e,class:"overviewresizer",fill:"transparent"});i.appendChild(a)},t.prototype.updateOverviewRectangle=function(){var e=this.currentPoint.x-this.prevPoint.x,i=this.currentPoint.y-this.prevPoint.y,r=new me;r.width=0,r.height=0;var s=0,o=0;switch(this.resizeDirection){case"left":r.width-=e,r.height-=e/this.viewPortRatio,s=e,o=e/this.viewPortRatio,o/=2;break;case"right":r.width+=e,r.height+=e/this.viewPortRatio,o=e/this.viewPortRatio,o/=-2;break;case"top":r.height-=i,r.width-=i*this.viewPortRatio,o=i,s=i*this.viewPortRatio,s/=2;break;case"bottom":r.height+=i,r.width+=i*this.viewPortRatio,s=i*this.viewPortRatio,s/=-2;break;case"topleft":Math.abs(i)>Math.abs(e)?e=i*this.viewPortRatio:i=e/this.viewPortRatio,r.width-=e,r.height-=i,s=e,o=i;break;case"topright":Math.abs(i)>Math.abs(e)?e=-i*this.viewPortRatio:i=-e/this.viewPortRatio,o=i,r.width+=e,r.height-=i;break;case"bottomleft":Math.abs(i)>Math.abs(e)?e=-i*this.viewPortRatio:i=-e/this.viewPortRatio,s=e,r.width-=e,r.height+=i;break;case"bottomright":Math.abs(i)>Math.abs(e)?e=i*this.viewPortRatio:i=e/this.viewPortRatio,r.width+=e,r.height+=i}this.updateHelper(s,o,r,void 0,void 0)},t.prototype.updateHelper=function(e,i,r,s,o){var a,l,h,u,f,d=this.element.getElementsByTagName("svg")[2].getElementById("helper");r?(a=(h=d.getBBox()).x+e,l=h.y+i,s=h.width+r.width,o=h.height+r.height):(u=this.currentPoint.x>this.startPoint.x?this.currentPoint.x-this.prevPoint.x:this.prevPoint.x-this.currentPoint.x,f=this.currentPoint.y>this.startPoint.y?this.currentPoint.y-this.prevPoint.y:this.prevPoint.y-this.currentPoint.y,Math.abs(f)>Math.abs(u)?u=this.viewPortRatio*f:f=u/this.viewPortRatio,h=d.getBBox(),a=this.startPoint.x>this.currentPoint.x?h.x-u:h.x,l=this.startPoint.y>this.currentPoint.y?h.y-f:h.y,s=h.width+u,o=h.height+f),ii(this.helper,{id:this.helper.id,x:a,y:l,width:Math.max(0,s),height:Math.max(0,o)})},t.prototype.updateOverviewrect=function(e,i,r,s){Ho(document.getElementById(this.canvas.id+"overviewrect"),{x:e,y:i,width:Math.max(1,r),height:Math.max(1,s)}),this.updateOverviewCorner("top",e+8,i+1,Math.max(0,r-16),2),this.updateOverviewCorner("bottom",e+8,i+s+3,Math.max(0,r-16),2),this.updateOverviewCorner("left",e-2,i+11,2,Math.max(0,s-16)),this.updateOverviewCorner("right",e+r,i+11,2,Math.max(0,s-16)),this.updateOverviewCorner("topleft",e,i+3,5,5),this.updateOverviewCorner("topright",e+r,i+3,5,5),this.updateOverviewCorner("bottomleft",e,i+s+3,5,5),this.updateOverviewCorner("bottomright",e+r,i+s+3,5,5)},t.prototype.updateOverviewCorner=function(e,i,r,s,o){var a,l;"top"===e||"bottom"===e||"right"===e||"left"===e?(a={x:i,y:r,width:s,height:o,fill:"#ED1C24"},l={x:i-2,y:r-2,width:2===s?4:s,height:2===o?4:o}):(a={cx:i,cy:r,r:4,fill:"#ED1C24"},l={cx:i,cy:r,r:6,fill:"transparent"}),Ho(document.getElementById(this.canvas.id+"visible"+e),a),Ho(document.getElementById(this.canvas.id+e),l)},t.prototype.translateOverviewRectangle=function(){Number(this.model.width),Number(this.model.height);var r=this.currentPoint.x-this.prevPoint.x,s=this.currentPoint.y-this.prevPoint.y,l=this.element.getElementsByClassName("overviewsvg")[0].getElementById(this.canvas.id+"overviewrect").getBBox(),h=l.x+r,c=l.y+s,d=l.width,u=l.height;this.updateOverviewrect(h,c,d,u),this.updateParentView(this.parent.scroller.currentZoom,h,c,d,u,null)},t.prototype.renderOverviewRect=function(e,i,r,s){var o=Number(this.model.width),a=Number(this.model.height),c=Math.max(this.parent.scroller.viewPortWidth/(r/o*this.contentWidth),this.parent.scroller.viewPortHeight/(s/a*this.contentHeight));if(c>=.25&&c<=30){this.updateParentView(c,e,i,r,s,{x:0,y:0});var u=this.scrollOverviewRect(this.parent.scroller.horizontalOffset,this.parent.scroller.verticalOffset,this.parent.scroller.currentZoom,!0);if(this.helper){var p=this.element.getElementsByTagName("rect")[10].getBBox();u.x=p.x,u.y=p.y}"pan"===this.actionName?this.updateOverviewrect(-u.x,-u.y,u.width,u.height):this.updateOverviewrect(u.x,u.y,u.width,u.height)}},t.prototype.scrollOverviewRect=function(e,i,r,s){if(!this.actionName||s){var o=Number(this.model.width),a=Number(this.model.height),l=Math.min(this.contentWidth/o,this.contentHeight/a),h=new Ne,c=h.x=e/r/l,d=h.y=i/r/l,u=0;this.parent.rulerSettings.showRulers&&(u=25);var f=document.getElementById(this.parent.element.id+"content"),p=0,g=0;f&&(p=f.offsetWidth-f.clientWidth,g=f.offsetHeight-f.clientHeight);var v=h.width=(this.parent.scroller.viewPortWidth-u-p)/r/l,y=h.height=(this.parent.scroller.viewPortHeight-u-g)/r/l;if(s){var S=new Ne;return S.x=c,S.y=d,S.width=v,S.height=y,S}this.updateOverviewrect(-c,-d,v,y)}return null},t.prototype.updateParentView=function(e,i,r,s,o,a){var p,g,l=Number(this.model.width),h=Number(this.model.height),u=i*(this.contentWidth/l)*e,f=r*(this.contentHeight/h)*e;this.parent.scroller.getPageBounds(),(1!==e||"pan"===this.actionName)&&(p=-u-this.parent.scroller.horizontalOffset,g=-f-this.parent.scroller.verticalOffset),this.parent.setBlazorDiagramProps(!0),this.parent.realActions|=$i.OverViewAction,"scale"===this.actionName||"draw"===this.actionName?this.parent.scroller.zoom(e/this.parent.scroller.currentZoom,p,g,a):ce()?this.parent.scroller.zoom(1,p,g,a):this.parent.pan(p,g,a,!0)},t.prototype.updateHtmlLayer=function(e){var i=Io(e.element.id),r=this.parent.scroller.getPageBounds(!0),o=r.height,a=Math.max(r.width,this.parent.scroller.viewPortWidth),l=Math.max(o,this.parent.scroller.viewPortHeight/this.parent.scroller.currentZoom),h=Math.min(Number(this.model.width)/a,Number(this.model.height)/l);i.style.transform="scale("+h+") translate("+this.parent.scroller.transform.tx+"px,"+this.parent.scroller.transform.ty+"px)"},t.prototype.updateView=function(e){var i=this.parent.scroller.getPageBounds(),r=i.width,s=i.height,o=Number(this.model.width),a=Number(this.model.height),l=Math.max(r,this.parent.scroller.viewPortWidth),h=Math.max(s,this.parent.scroller.viewPortHeight);this.contentWidth=l=Math.max(l,o/a*h),this.contentHeight=h=Math.max(h,a/o*l);var c=Math.min(o/l,a/h),d=document.getElementById(this.element.id+"_htmlLayer");d.style.webkitTransform="scale("+c+") translate("+-i.x+"px,"+-i.y+"px)",d.style.transform="scale("+c+") translate("+-i.x+"px,"+-i.y+"px)",document.getElementById(this.element.id+"_overviewlayer").setAttribute("transform","translate("+-i.x*c+","+-i.y*c+")"),this.horizontalOffset=i.x*c,this.verticalOffset=i.y*c;var f=document.getElementById(this.element.id+"_diagramLayer"),p=zF(this.element.id),g=f.getContext("2d"),v=Number(this.model.width)/this.contentWidth,y=Number(this.model.height)/this.contentHeight;v=Math.min(v,y);var S=this.parent.scroller.transform;p.setAttribute("transform","translate("+S.tx*v+","+S.ty*y+"),scale("+v+")"),g.setTransform(v,0,0,v,0,0),g.fillStyle="red",this.scrollOverviewRect(this.parent.scroller.horizontalOffset,this.parent.scroller.verticalOffset,this.parent.scroller.currentZoom)},t.prototype.scrolled=function(e){if(this.event){var i=this.scrollOverviewRect(this.parent.scroller.horizontalOffset,this.parent.scroller.verticalOffset,this.parent.scroller.currentZoom,!0);this.updateOverviewrect(-i.x,-i.y,i.width,i.height),this.updateView(this)}},t.prototype.updateCursor=function(e){if(um(e.target,"overviewresizer"))switch(e.target.id){case this.canvas.id+"left":this.canvas.style.cursor="w-resize";break;case this.canvas.id+"right":this.canvas.style.cursor="e-resize";break;case this.canvas.id+"top":this.canvas.style.cursor="n-resize";break;case this.canvas.id+"bottom":this.canvas.style.cursor="s-resize";break;case this.canvas.id+"topleft":this.canvas.style.cursor="nw-resize";break;case this.canvas.id+"topright":this.canvas.style.cursor="ne-resize";break;case this.canvas.id+"bottomleft":this.canvas.style.cursor="sw-resize";break;case this.canvas.id+"bottomright":this.canvas.style.cursor="se-resize"}else this.canvas.style.cursor="default"},t.prototype.mouseMove=function(e){if(this.event=!1,this.updateCursor(e),this.currentPoint=this.mousePosition(e),this.actionName)switch(this.actionName){case"draw":!this.inAction&&(this.startPoint.x!==this.currentPoint.x||this.startPoint.y!==this.currentPoint.y)&&(this.initHelper(),this.inAction=!0),this.inAction&&this.updateHelper();break;case"scale":this.inAction||(this.initHelper(),this.inAction=!0),this.updateOverviewRectangle();break;case"pan":(this.startPoint.x!==this.currentPoint.x||this.startPoint.y===this.currentPoint.y||this.inAction)&&(this.inAction=!0,this.translateOverviewRectangle())}this.prevPoint=this.currentPoint},t.prototype.documentMouseUp=function(e){this.inAction=!1,this.actionName="",this.helper&&(this.helper.parentNode.removeChild(this.helper),this.helper=null),this.event=!0,document.getElementById(this.canvas.id+"overviewhandle").style.pointerEvents="all"},t.prototype.windowResize=function(e){var i=this;return this.resizeTo&&clearTimeout(this.resizeTo),this.resizeTo=setTimeout(function(){var s=document.getElementById(i.element.id).getBoundingClientRect();i.model.width=s.width>0?s.width:i.model.width,i.model.height=s.height>0?s.height:i.model.height,i.renderCanvas(),i.setParent(i.sourceID)},10),!1},t.prototype.mouseDown=function(e){if(e.target.id===this.canvas.id+"_overviewsvg"&&(this.actionName="draw"),e.target.id===this.canvas.id+"overviewrect"&&(this.actionName="pan"),um(e.target,"overviewresizer"))switch(this.actionName="scale",e.target.id){case this.canvas.id+"left":this.resizeDirection="left";break;case this.canvas.id+"right":this.resizeDirection="right";break;case this.canvas.id+"top":this.resizeDirection="top";break;case this.canvas.id+"bottom":this.resizeDirection="bottom";break;case this.canvas.id+"topleft":this.resizeDirection="topleft";break;case this.canvas.id+"topright":this.resizeDirection="topright";break;case this.canvas.id+"bottomleft":this.resizeDirection="bottomleft";break;case this.canvas.id+"bottomright":this.resizeDirection="bottomright"}this.startPoint=this.prevPoint=this.mousePosition(e),this.viewPortRatio=this.parent.scroller.viewPortWidth/this.parent.scroller.viewPortHeight,document.getElementById(this.canvas.id+"overviewhandle").style.pointerEvents="none"},t.prototype.mouseUp=function(e){if(this.currentPoint=this.mousePosition(e),this.actionName)if(this.startPoint.x!==this.currentPoint.x||this.startPoint.y!==this.currentPoint.y){if("pan"!==this.actionName&&this.helper){var i=this.element.getElementsByTagName("rect")[10].getBBox();this.resizeDirection=this.resizeDirection||"",this.renderOverviewRect(i.x,i.y,o=i.width,a=i.height)}}else if(e.target.id===this.canvas.id+"_overviewsvg"||"helper"===e.target.id){var o=(i=this.element.getElementsByTagName("svg")[2].getElementById(this.canvas.id+"overviewrect").getBBox()).width,a=i.height;this.inAction=!0,this.actionName="pan",this.renderOverviewRect(this.currentPoint.x-o/2,this.currentPoint.y-a/2,o,a),this.inAction=!1}this.helper&&(this.helper.parentNode.removeChild(this.helper),this.helper=null),this.actionName="",this.startPoint=null,this.currentPoint=null,this.prevPoint=null,this.helper=null,this.viewPortRatio=1,this.resizeDirection="",this.inAction=!1,this.event=!0,document.getElementById(this.canvas.id+"overviewhandle").style.pointerEvents="all"},t.prototype.initHelper=function(){var e=this.element.getElementsByTagName("svg")[2],i=this.startPoint.x,r=this.startPoint.y,s=1,o=1;if("scale"===this.actionName){var l=e.getElementById(this.canvas.id+"overviewrect").getBBox();i=l.x,r=l.y,s=l.width,o=l.height}var h=Fi("rect",{id:"helper",x:i,y:r,width:s,height:o,fill:"transparent",stroke:"gray","stroke-dasharray":"2 2","shape-rendering":"crispEdges"});e.getElementById(this.element.id+"_overviewlayer").appendChild(h),this.helper=h},t.prototype.mousePosition=function(e){var i,r,s;-1!==e.type.indexOf("touch")?(r=(i=e).changedTouches[0].clientX-this.element.offsetLeft,s=i.changedTouches[0].clientY-this.element.offsetTop):(r=e.clientX,s=e.clientY);var l=this.element.getBoundingClientRect();return{x:(r-=l.left)+this.horizontalOffset,y:(s-=l.top)+this.verticalOffset}},t.prototype.destroy=function(){if(this.unWireEvents(),this.notify("destroy",{}),n.prototype.destroy.call(this),document.getElementById(this.element.id)){this.element.classList.remove("e-overview");var e=document.getElementById(this.element.id+"_canvas");e&&this.element.removeChild(e)}this.parent.views.splice(this.parent.views.indexOf(this.element.id),1),this.diagramLayerDiv=null,this.canvas=null,this.parent=null},t.prototype.getModuleName=function(){return"Overview"},eb([I("100%")],t.prototype,"width",void 0),eb([I("100%")],t.prototype,"height",void 0),eb([I("")],t.prototype,"sourceID",void 0),eb([H()],t.prototype,"created",void 0),t}(Ii);function sse(n,t){for(var e=0;eR.findLength(e,n)?e:t;var o=R.findAngle(t,e),a=R.findAngle(i,n),l=R.findLength(i,n),h=a+2*(o-a);return{x:i.x+l*Math.cos(h*Math.PI/180),y:i.y+l*Math.sin(h*Math.PI/180)}}function Kf(n,t,e){if(n&&n.children&&n.children.length>0)for(var r=void 0,s=0;s0&&"annotations"!==r&&"ports"!==r)if(n[""+l].length>0)for(var h=0;h<=n[""+l].length;h++)Ro(n[""+l],t?t[""+l]:void 0,e[""+l],"annotations"===l||"ports"===l?n:void 0,l);else Ro(n[""+l],t?t[""+l]:void 0,e[""+l],"annotations"===l||"ports"===l?n:void 0,l);else if(s instanceof Object&&t&&"annotations"!==r&&"ports"!==r)Ro(n[""+l],t[""+l],e[""+l]);else if("annotations"!==r&&"ports"!==r&&t&&!t[""+l]||!t&&n&&(n[""+l]||void 0!==n[""+l]))n[""+l]=e[""+l];else{var c=void 0;("annotations"===r||"ports"===r)&&("annotations"===r?(n[""+l]&&Ro(n[""+l],t[""+l],e[""+l]),n[""+l]||(ps(i)===de?(c=new Or(i,"annotations",e[""+l]),i.annotations.push(c)):(c=new Kn(i,"annotations",e[""+l]),i.annotations.push(c)))):n[""+l]?Ro(n[""+l],t[""+l],e[""+l]):(c=new Es(i,"ports",e[""+l]),i.ports.push(c)))}}}function use(n,t){for(var e="Bezier"===n.type?function hse(n){var t=[];if("Bezier"===n.type)for(var e=0,i=0;i0||n.ports.length>0){var f=n.wrapper.children;for(i=3;i0)return{enabled:!1,intersectPt:e};var l=o/s,h=a/s;return l>=0&&l<=1&&h>=0&&h<=1?(e.x=i.x1+l*(i.x2-i.x1),e.y=i.y1+l*(i.y2-i.y1),{enabled:!0,intersectPt:e}):{enabled:!1,intersectPt:e}}function ib(n,t,e,i){var a=tm(cF(n.x,n.y,t.x,t.y),cF(e.x,e.y,i.x,i.y));return a.enabled?a.intersectPt:{x:0,y:0}}function cF(n,t,e,i){return{x1:Number(n)||0,y1:Number(t)||0,x2:Number(e)||0,y2:Number(i)||0}}function dF(n,t,e){var i=[],s={x:t.topRight.x+(e=e||0),y:t.topRight.y},o={x:t.bottomRight.x,y:t.bottomRight.y-e},a={x:t.bottomLeft.x,y:t.bottomLeft.y+e};return i.push({x:t.topLeft.x-e,y:t.topLeft.y}),i.push(s),i.push(o),i.push(a),i}function zc(n,t,e,i,r,s){var o={},a=e.scroller.transform.scale,h=e.scroller.verticalOffset;return o.x=(i?n.x:t.x)*a+e.scroller.horizontalOffset-r,o.y=(i?n.y:t.y)*a+h-s,o}function uF(n,t){var e=new Ze;return e.data=n.pathData,e.height=n.height>10?n.height-(n.padding.bottom+n.padding.top):n.height,e.width=n.width>10?n.width-(n.padding.left+n.padding.right):n.width,e.visible=n.visibility,e.id=t.id+"_shape",e.inversedAlignment=!1,e.horizontalAlignment="Center",e.verticalAlignment="Center",e.style={fill:n.iconStrokeColor,strokeColor:n.iconStrokeColor,strokeWidth:n.iconStrokeWidth},e.setOffsetWithRespectToBounds(.5,.5,"Fraction"),e.relativeMode="Object",e.description=t.description||"",e}function $x(n,t,e){var i=Zx(n,t),r=R.findAngle(n[i.index],n[i.index+1]),s=function Sse(n){var t;t=n instanceof LI?0:void 0===n.content?10:0;var e=0;switch(n.alignment){case"Center":e=0;break;case"Before":e=-(0+t);break;case"After":e=0+t}return e}(t),o=R.transform(i.point,r+45,s);return i.point=o,i.angle=r,i}function Zx(n,t){for(var r,s,a,l,e=0,i=t.offset,o=[],h=0;h=c)return s=R.findAngle(n[parseInt(d.toString(),10)],n[d+1]),{point:r=R.transform(n[parseInt(d.toString(),10)],s,c-(a||0)),index:l=d};a=o[parseInt(d.toString(),10)]}return{point:r,index:l}}function fF(n,t,e){t%=360;var a,l,s=225;switch(n.alignment){case"Before":t>=45&&t<=135?(l="right",a=.5===n.offset?"center":"top"):t>=s&&t<=315?(l="left",a=.5===n.offset?"center":"bottom"):t>45&&t=45&&t<=135?(l="left",a=.5===n.offset?"center":"top"):t>=s&&t<=315?(l="right",a=.5===n.offset?"center":"bottom"):t>45&&tMath.abs(t.y-n.y)?n.x0)for(var e=0;e=0;r--)("nodes"===i||"connectors"===i)&&(n[""+i][parseInt(r.toString(),10)].wrapper=null),"dataManager"!==i&&(n[""+i][parseInt(r.toString(),10)]=eT(n[""+i][parseInt(r.toString(),10)],e[""+i][parseInt(r.toString(),10)],void 0!==t[""+i]?t[""+i][parseInt(r.toString(),10)]:[]),("[]"===JSON.stringify(n[""+i][parseInt(r.toString(),10)])||"{}"===JSON.stringify(n[""+i][parseInt(r.toString(),10)])||void 0===n[""+i][parseInt(r.toString(),10)])&&n[""+i].splice(r,1));n=void 0}function zh(n,t){var e=t.style,i=t;t.canApplyStyle=!0;for(var r=0,s=Object.keys(n);r=0&&n.splice(e,1)}function ep(n,t,e){var i;n.intermediatePoints=t,n.updateSegmentElement(n,t,n.wrapper.children[0],e);var r=n.sourceDecorator;if("Bezier"===n.type){var s=n.segments[0],o=n.segments[n.segments.length-1];i=[R.isEmptyPoint(o.point2)?o.bezierPoint2:o.point2,R.isEmptyPoint(s.point1)?s.bezierPoint1:s.point1]}else i=n.intermediatePoints;t=n.clipDecorators(n,t,e);var a=n.wrapper.children[0];a.canMeasurePath=!0,n.updateDecoratorElement(a=n.wrapper.children[1],t[0],i[1],r),n.updateDecoratorElement(a=n.wrapper.children[2],t[t.length-1],i[i.length-2],n.targetDecorator),n.updateShapeElement(n)}function tT(n,t,e){var l,i=n.wrapper,s=t.offset,o=t.size/e.scale,a=t.margin,h=i.offsetX-i.actualSize.width*i.pivot.x,c=i.offsetY-i.actualSize.height*i.pivot.y;if(l={x:0,y:0},n.nodes.length>0){switch(t.side){case"Top":l.x+=h+s*i.actualSize.width,l.y+=c-o;break;case"Bottom":l.x+=h+s*i.actualSize.width,l.y+=c+i.actualSize.height+o;break;case"Left":l.x+=h-o,l.y+=c+s*i.actualSize.height;break;case"Right":l.x+=h+i.actualSize.width+o,l.y+=c+s*i.actualSize.height}l.x+=(a.left-a.right)/e.scale+o/2*("Center"===t.horizontalAlignment?0:"Right"===t.horizontalAlignment?-1:1),l.y+=(a.top-a.bottom)/e.scale+o/2*("Center"===t.verticalAlignment?0:"Top"===t.verticalAlignment?-1:1)}else if(n.connectors.length>0){var d=n.connectors[0],u={offset:s},f=Zx(d.intermediatePoints,u),p=f.index;l=f.point;var y,v=$x(d.intermediatePoints,u).angle;qi(y=Bi(),-v,d.intermediatePoints[parseInt(p.toString(),10)].x,d.intermediatePoints[parseInt(p.toString(),10)].y),(l=Ke(y,l)).x+=a.left-a.right+o/2*("Center"===t.horizontalAlignment?0:"Right"===t.horizontalAlignment?-1:1),l.y+=a.top-a.bottom+o/2*("Center"===t.verticalAlignment?0:"Top"===t.verticalAlignment?-1:1),qi(y=Bi(),v,d.intermediatePoints[parseInt(p.toString(),10)].x,d.intermediatePoints[parseInt(p.toString(),10)].y),l=Ke(y,l)}return 0===i.rotateAngle&&0===i.parentTransform||(qi(y=Bi(),i.rotateAngle+i.parentTransform,i.offsetX,i.offsetY),l=Ke(y,l)),l}function ga(n,t,e,i){if(i.annotation){if(Pl(i.annotation))return!0}else if(mr[""+t]&n&&bt[""+t]&e)return!0;return!1}function qr(n,t){return!!(mr[""+t]&n)}function Hc(n,t){return!!(wx[""+t]&n)}function va(n,t){return n.visibility&t}function rb(n,t){var e;if("Text"===n.shape.type)e=n.shape;else{var i=t.split("_");t=i[i.length-1];for(var r=0;rn[""+t]?e.splice(0,0,n):e.push(n);else if(e.length>1){for(var i=0,r=e.length-1,s=Math.floor((i+r)/2);s!==i;)if(e[parseInt(s.toString(),10)][""+t]n[""+t]))break;r=s,s=Math.floor((i+r)/2)}e[parseInt(r.toString(),10)][""+t]n[""+t]?e.splice(i,0,n):e[parseInt(i.toString(),10)][""+t]n[""+t]&&e.splice(r,0,n)}}function Hse(n){var t=document.getElementById(n.diagramId),e="ej2_instances",i=t[""+e][0].nodes;void 0===i&&(i=function Bse(n){for(var t=[],e=0;e30?10:o/2;for(var h=0,c=0;c=l){var u=l-h;r=Xt(n[c],n[c+1]),s=R.transform(n[c],r,u);break}h+=d}return s},ob=function(n,t){if(n instanceof te||n instanceof de)for(var e=0;e=0||navigator.platform.indexOf("iPad")>=0||navigator.platform.indexOf("iPhone")>=0||navigator.platform.indexOf("MacIntel")>=0)&&("safari"===X.info.name||"webkit"===X.info.name)}function wF(n,t,e,i){return void 0!==t.previewSize[""+i]?t.previewSize[""+i]:void 0!==n.symbolPreview[""+i]?n.symbolPreview[""+i]:t[""+i]||e.actualSize[""+i]}function om(n,t,e){return n&&n.parentId&&(e=(n=t.nameTable[n.parentId]).parentId?om(n,t,e):n.id),e}function am(n,t){return n.selectedItems.connectors.length>1&&0===n.selectedItems.nodes.length&&0!==t.rotateAngle}function jse(n){if(n.arrowType&&""!==n.arrowType.trim())switch(n.arrowType){case"single-line-arrow":default:return{targetDecorator:"Arrow",strokeWidth:1};case"double-line-arrow":return{targetDecorator:"Arrow",strokeWidth:2};case"dotted-arrow":return{targetDecorator:"Arrow",strokeDashArray:"2,2"};case"single-line":return{targetDecorator:"None",strokeWidth:1};case"double-line":return{targetDecorator:"None",strokeWidth:2};case"dotted":return{targetDecorator:"None",strokeDashArray:"2,2"};case"wiggly-arrow":return{targetDecorator:"None",strokeWidth:1,opacity:0}}return{targetDecorator:"Arrow",strokeWidth:1}}var Vse=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),no=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},CF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Vse(t,n),no([I("None")],t.prototype,"shape",void 0),no([I("white")],t.prototype,"fill",void 0),no([I("Auto")],t.prototype,"horizontalAlignment",void 0),no([I("Auto")],t.prototype,"verticalAlignment",void 0),no([I(10)],t.prototype,"width",void 0),no([I(10)],t.prototype,"height",void 0),no([re({x:.5,y:1},R)],t.prototype,"offset",void 0),no([I("#1a1a1a")],t.prototype,"borderColor",void 0),no([I(1)],t.prototype,"borderWidth",void 0),no([re({},Jn)],t.prototype,"margin",void 0),no([I("")],t.prototype,"pathData",void 0),no([I("")],t.prototype,"content",void 0),no([I(0)],t.prototype,"cornerRadius",void 0),no([re({left:2,right:2,top:2,bottom:2},Jn)],t.prototype,"padding",void 0),no([I("#1a1a1a")],t.prototype,"iconColor",void 0),t}(Ee),Wse=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),sT=function(n){function t(){var e=null!==n&&n.apply(this,arguments)||this;return e.orientation="Vertical",e.measureChildren=void 0,e.considerPadding=!0,e}return Wse(t,n),t.prototype.measure=function(e){return this.desiredSize=this.measureStackPanel(e,"Horizontal"===this.orientation?this.updateHorizontalStack:this.updateVerticalStack),this.desiredSize},t.prototype.arrange=function(e){return this.actualSize=this.arrangeStackPanel(e,"Horizontal"===this.orientation?this.arrangeHorizontalStack:this.arrangeVerticalStack),this.updateBounds(),this.actualSize},t.prototype.measureStackPanel=function(e,i){var r=void 0;if(void 0!==this.children&&this.children.length>0)for(var s=0,o=this.children;s0){var r=void 0,s=void 0;r=this.offsetX-e.width*this.pivot.x+this.padding.left,s=this.offsetY-e.height*this.pivot.y+this.padding.top;for(var o=0,a=this.children;o0)for(var i=0,r=this.children;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Jse=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Zse(t,n),Rh([I("Horizontal")],t.prototype,"orientation",void 0),Rh([I("Center")],t.prototype,"type",void 0),Rh([I(void 0)],t.prototype,"offset",void 0),Rh([I(!1)],t.prototype,"enableRouting",void 0),Rh([I([])],t.prototype,"children",void 0),Rh([I("")],t.prototype,"assistants",void 0),Rh([I("")],t.prototype,"level",void 0),Rh([I("")],t.prototype,"hasSubTree",void 0),Rh([I("")],t.prototype,"rows",void 0),t}(Ee),Ni=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),q=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Kse=function(n){if(n)switch(n.type){case"Basic":default:return ab;case"Flow":return TF;case"Path":return EF;case"Image":return xF;case"Text":return Hd;case"Bpmn":return dT;case"Native":return lm;case"HTML":return DF;case"UmlActivity":return AF;case"UmlClassifier":return LF;case"SwimLane":return _d}return ab},ma=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),q([I("Basic")],t.prototype,"type",void 0),t}(Ee),EF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"Path"},q([I("Path")],t.prototype,"type",void 0),q([I("")],t.prototype,"data",void 0),t}(ma),lm=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"Native"},q([I("Native")],t.prototype,"type",void 0),q([I("")],t.prototype,"content",void 0),q([I("Stretch")],t.prototype,"scale",void 0),t}(ma),DF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"Html"},q([I("HTML")],t.prototype,"type",void 0),q([I("")],t.prototype,"content",void 0),t}(ma),xF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"Image"},q([I("Image")],t.prototype,"type",void 0),q([I("")],t.prototype,"source",void 0),q([I("None")],t.prototype,"scale",void 0),q([I("None")],t.prototype,"align",void 0),t}(ma),Hd=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"Text"},q([I("Text")],t.prototype,"type",void 0),q([I("")],t.prototype,"content",void 0),q([re({},Jn)],t.prototype,"margin",void 0),t}(ma),ab=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"BasicShape"},q([I("Basic")],t.prototype,"type",void 0),q([I("Rectangle")],t.prototype,"shape",void 0),q([I(0)],t.prototype,"cornerRadius",void 0),q([Bt([],R)],t.prototype,"points",void 0),t}(ma),TF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"FlowShape"},q([I("Flow")],t.prototype,"type",void 0),q([I("Terminator")],t.prototype,"shape",void 0),t}(ma),aT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"BpmnGateway"},q([I("None")],t.prototype,"type",void 0),t}(Ee),lT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"BpmnDataObject"},q([I("None")],t.prototype,"type",void 0),q([I(!1)],t.prototype,"collection",void 0),t}(Ee),eoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),q([I("None")],t.prototype,"type",void 0),q([I("None")],t.prototype,"loop",void 0),q([I(!1)],t.prototype,"call",void 0),q([I(!1)],t.prototype,"compensation",void 0),t}(Ee),hT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"BpmnEvent"},q([I("Start")],t.prototype,"event",void 0),q([I("None")],t.prototype,"trigger",void 0),t}(Ee),Bd=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"BpmnSubEvent"},q([I("None")],t.prototype,"trigger",void 0),q([I("Start")],t.prototype,"event",void 0),q([I("")],t.prototype,"id",void 0),q([re({},R)],t.prototype,"offset",void 0),q([Bt([],Kn)],t.prototype,"annotations",void 0),q([Bt([],Es)],t.prototype,"ports",void 0),q([I()],t.prototype,"width",void 0),q([I()],t.prototype,"height",void 0),q([re({},Jn)],t.prototype,"margin",void 0),q([I("Center")],t.prototype,"horizontalAlignment",void 0),q([I("Center")],t.prototype,"verticalAlignment",void 0),q([I(!0)],t.prototype,"visible",void 0),t}(Ee),toe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),q([re({id:"success",event:"End",offset:{x:1,y:.5}},Bd)],t.prototype,"success",void 0),q([re({id:"failure",event:"Intermediate",trigger:"Error",offset:{x:.25,y:1}},Bd)],t.prototype,"failure",void 0),q([re({id:"cancel",event:"Intermediate",trigger:"Cancel",offset:{x:.75,y:1}},Bd)],t.prototype,"cancel",void 0),t}(Ee),ioe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),q([I("None")],t.prototype,"type",void 0),q([I(!1)],t.prototype,"adhoc",void 0),q([I("Default")],t.prototype,"boundary",void 0),q([I(!1)],t.prototype,"compensation",void 0),q([I("None")],t.prototype,"loop",void 0),q([I(!0)],t.prototype,"collapsed",void 0),q([Bt([],Bd)],t.prototype,"events",void 0),q([re({},toe)],t.prototype,"transaction",void 0),q([I(void 0)],t.prototype,"processes",void 0),t}(Ee),cT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"BpmnActivity"},q([I("Task")],t.prototype,"activity",void 0),q([re({},eoe)],t.prototype,"task",void 0),q([re({},ioe)],t.prototype,"subProcess",void 0),t}(Ee),hm=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return Ni(t,n),t.prototype.getClassName=function(){return"BpmnAnnotation"},q([I("")],t.prototype,"text",void 0),q([I("")],t.prototype,"id",void 0),q([I(0)],t.prototype,"angle",void 0),q([I()],t.prototype,"height",void 0),q([I()],t.prototype,"width",void 0),q([I(0)],t.prototype,"length",void 0),t}(Ee),roe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),q([I("")],t.prototype,"textAnnotationTarget",void 0),q([I("Auto")],t.prototype,"textAnnotationDirection",void 0),t}(Ee),dT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"BpmnShape"},q([I("Bpmn")],t.prototype,"type",void 0),q([I("Event")],t.prototype,"shape",void 0),q([re({},hT)],t.prototype,"event",void 0),q([re({},aT)],t.prototype,"gateway",void 0),q([re({},lT)],t.prototype,"dataObject",void 0),q([re({},cT)],t.prototype,"activity",void 0),q([re({},hm)],t.prototype,"annotation",void 0),q([Bt([],hm)],t.prototype,"annotations",void 0),q([re({},roe)],t.prototype,"textAnnotation",void 0),t}(ma),AF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"UmlActivityShape"},q([I("UmlActivity")],t.prototype,"type",void 0),q([I("Action")],t.prototype,"shape",void 0),t}(ma),uT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"MethodArguments"},q([I("")],t.prototype,"name",void 0),q([I("")],t.prototype,"type",void 0),q([re({},Xf)],t.prototype,"style",void 0),t}(Ee),sp=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"UmlClassAttribute"},q([I("Public")],t.prototype,"scope",void 0),q([I(!1)],t.prototype,"isSeparator",void 0),q([re({fill:"#F9F9F9",strokeColor:"#CCCCCC"},Ll)],t.prototype,"separatorStyle",void 0),t}(uT),cm=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"UmlClassMethod"},q([Bt([],uT)],t.prototype,"parameters",void 0),t}(sp),lb=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"UmlClass"},q([I("")],t.prototype,"name",void 0),q([Bt([],sp)],t.prototype,"attributes",void 0),q([Bt([],cm)],t.prototype,"methods",void 0),q([re({},Xf)],t.prototype,"style",void 0),t}(Ee),fT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"UmlInterface"},q([I(!1)],t.prototype,"isSeparator",void 0),q([re({fill:"#F9F9F9",strokeColor:"#CCCCCC"},Ll)],t.prototype,"separatorStyle",void 0),t}(lb),hb=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"UmlEnumerationMember"},q([I("")],t.prototype,"name",void 0),q([I("")],t.prototype,"value",void 0),q([I(!1)],t.prototype,"isSeparator",void 0),q([re({fill:"#F9F9F9",strokeColor:"#CCCCCC"},Ll)],t.prototype,"separatorStyle",void 0),q([re({},Xf)],t.prototype,"style",void 0),t}(Ee),pT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"UmlEnumeration"},q([I("")],t.prototype,"name",void 0),q([Bt([],hb)],t.prototype,"members",void 0),q([re({},Xf)],t.prototype,"style",void 0),t}(Ee),LF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"UmlClassifierShape"},q([I("UmlClassifier")],t.prototype,"type",void 0),q([re({},lb)],t.prototype,"classShape",void 0),q([re({},fT)],t.prototype,"interfaceShape",void 0),q([re({},pT)],t.prototype,"enumerationShape",void 0),q([I("Class")],t.prototype,"classifier",void 0),t}(ma),te=function(n){function t(e,i,r,s){var a,o=n.call(this,e,i,r,s)||this;return o.isCanvasUpdate=!1,o.status="None",o.parentId="",o.processId="",o.umlIndex=-1,o.outEdges=[],o.inEdges=[],o.isHeader=!1,o.isLane=!1,o.isPhase=!1,o.children&&o.children.length>0&&((!(a=r).style||!a.style.fill)&&(o.style.fill="transparent"),(!a.style||!a.style.strokeColor)&&(o.style.strokeColor="transparent")),o.shape&&"UmlActivity"===o.shape.type&&tb(r,o),o.shape&&"SwimLane"===o.shape.type&&aF(r,o),o.ports&&o.ports.length&&function ase(n){for(var t=0;t>";t=n;break;case"FinalNode":t=pF(e)}return t}(new Ze,i,this);break;case"Bpmn":if(e.bpmnModule){i=e.bpmnModule.initBPMNContent(i,this,e),this.wrapper.elementActions=this.wrapper.elementActions|Xr.ElementIsGroup;var v=this.shape.activity.subProcess;if(v.processes&&v.processes.length)for(var S=0,b=this.shape.activity.subProcess.processes;S>",margin:{left:10,right:10},id:"class",style:{fontSize:i.style.fontSize,color:i.style.color,fill:i.style.fill,textWrapping:r},offset:{x:.5,y:.3},constraints:Nr.ReadOnly}],constraints:(ie.Default|ie.HideThumbs)&~(ie.Rotate|ie.Drag|ie.Resize),verticalAlignment:"Stretch",horizontalAlignment:"Stretch",style:{fill:t.style.fill,strokeColor:"black"===t.style.strokeColor?"#ffffff00":t.style.strokeColor}},!0);return e.initObject(s),e.nodes.push(s),e.UpdateBlazorDiagramModel(s,"Node"),t.children.push(s.id),function Qse(n,t,e,i){if("Enumeration"===n.shape.classifier){var r=e.members;if(r&&r.length){rp(n,t);for(var s="",o=0;o0)for(var o=0;o0&&s.phaseSize&&(i+=s.phaseSize,Gv(n,s.phaseSize)),s.lanes.length>0)for(o=0;o0){var a=0;for(o=0;o0&&"Horizontal"===r.orientation)for(l=0;l0&&(i+=r.phaseSize,o=Xv(r.phaseSize),n.push(o)),a=0;a0&&o.phaseSize){for(var l=0;l0)for(l=0;l0?e.nameTable[this.nodes[0].id].wrapper:e.nameTable[this.connectors[0].id].wrapper,this.annotation.id);i.children.push(s)}else if(this.nodes||this.connectors){for(var o=0;o-1}function HF(n,t,e){n=[];for(var i=0,r=e.length;i0?c.getElementsByTagName("svg")[0].outerHTML:c.getElementsByTagName("g").length>0?c.getElementsByTagName("g")[0].outerHTML:"",s.shape.content=h,n.content=h,c.parentElement.removeChild(c)}l="nodeTemplate"}else a=s,l="annotationTemplate";var p=document.getElementById(n.diagramId).ej2_instances[0];if("string"!=typeof n.content&&"function"!=typeof n.content||n.isTemplate)if(n.isTemplate){if(v=void 0,v=p.isReact?n.getNodeTemplate()($(e),p,l+"_"+("nodeTemplate"===l?e.id:n.nodeId+e.id),void 0,void 0,!1,i):p.isVue||p.isVue3?n.getNodeTemplate()?n.getNodeTemplate()($(e),p,l+"_"+("nodeTemplate"===l?e.id:n.nodeId+e.id),void 0,void 0,!1,i):(v=oi("nodeTemplate"===l?p.nodeTemplate:p.annotationTemplate))($(e),p,l+"_"+("nodeTemplate"===l?e.id:n.nodeId+e.id),void 0,void 0,!1,i):n.getNodeTemplate()($(e),p,l+"_"+("nodeTemplate"===l?e.id:n.nodeId+e.id),void 0,void 0,!1))for(var M=0;M=1&&0===n.x&&("Clip"===i.textOverflow||"Ellipsis"===i.textOverflow)&&("Wrap"===i.textWrapping||"WrapWithOverflow"===i.textWrapping)&&(n.x=t[e-1]?t[e-1].x:-n.width/2),n.x}function _F(n,t,e,i){return e&&!t.template||t.template&&"function"==typeof t.template&&i.isReact?(n.isTemplate=!0,n.template=n.content=Hh(n,!0,t)):n.content=t.template,n}function Qe(){for(var e,t="",i=0;i<5;i++){if(typeof window<"u"&&"crypto"in window&&"getRandomValues"in crypto){var r=new Uint16Array(1);e=(window.msCrypto||window.crypto).getRandomValues(r)[0]%60}else e=Math.floor(61*Math.random());0===i&&e<10?i--:t+="0123456789ABCDEFGHIJKLMNOPQRSTUVWXTZabcdefghiklmnopqrstuvwxyz".substring(e,e+1)}return t}function UF(n){if(n)try{return"function"!=typeof n&&document.querySelectorAll(n).length?oi(document.querySelector(n).innerHTML.trim()):oi(n)}catch{return oi(n)}}function xn(n){new Ne;var e=n.offsetY-n.actualSize.height*n.pivot.y,i=n.offsetY+n.actualSize.height*(1-n.pivot.y),r=n.offsetX-n.actualSize.width*n.pivot.x,s=n.offsetX+n.actualSize.width*(1-n.pivot.x);return Ne.toBounds([{x:r,y:e},{x:s,y:e},{x:r,y:i},{x:s,y:i}])}function yr(n){var t=new Ne,e=xn(n),i=e.middleLeft,r=e.topCenter,s=e.bottomCenter,o=e.middleRight,a=e.topLeft,l=e.topRight,h=e.bottomLeft,c=e.bottomRight;if(n.corners={topLeft:a,topCenter:r,topRight:l,middleLeft:i,middleRight:o,bottomLeft:h,bottomCenter:s,bottomRight:c},0!==n.rotateAngle||0!==n.parentTransform){var d=Bi();qi(d,n.rotateAngle+n.parentTransform,n.offsetX,n.offsetY),n.corners.topLeft=a=Ke(d,a),n.corners.topCenter=r=Ke(d,r),n.corners.topRight=l=Ke(d,l),n.corners.middleLeft=i=Ke(d,i),n.corners.middleRight=o=Ke(d,o),n.corners.bottomLeft=h=Ke(d,h),n.corners.bottomCenter=s=Ke(d,s),n.corners.bottomRight=c=Ke(d,c)}return t=Ne.toBounds([a,l,h,c]),n.corners.left=t.left,n.corners.right=t.right,n.corners.top=t.top,n.corners.bottom=t.bottom,n.corners.center=t.center,n.corners.width=t.width,n.corners.height=t.height,t}function $(n,t,e,i){var r={},s="properties";if(n){e=n.propName;var l=[],h=[];if((l=l.concat(Object.keys(n[""+s]||n))).push("version"),e){var c=Zi(t);h=c?c(e):[],l=l.concat(h)}for(var d=function woe(n){switch(n){case"nodes":case"children":return["inEdges","outEdges","parentId","processId","nodeId","umlIndex","isPhase","isLane"];case"connectors":return["parentId"];case"annotation":case"annotations":return["nodeId"];case"shape":return["hasHeader"];case"layers":return["objectZIndex"]}return[]}(e),u=0,f=l=l.concat(d);u0&&(e=r),r=Math.floor(Eoe(e,i)),s=Bc(o+=n.substr(e,r),t)}while(s<=t.width);for(o=o.substr(0,e),a=e;a=t.width){n=n.substr(0,o.length-1);break}return"Ellipsis"===t.textOverflow?(n=n.substr(0,n.length-3),n+="..."):n=n.substr(0,n.length),n}function bT(n,t){if("NoWrap"===t&&"PreserveAll"===n)return"pre";var e="";switch(n){case"CollapseAll":e="nowrap";break;case"CollapseSpace":e="pre-line";break;case"PreserveAll":e="pre-wrap"}return e}function MT(n,t){var e=Bi();qi(e,t,0,0);var i=Ke(e,{x:0,y:0}),r=Ke(e,{x:n.width,y:0}),s=Ke(e,{x:0,y:n.height}),o=Ke(e,{x:n.width,y:n.height}),a=Math.min(i.x,r.x,s.x,o.x),l=Math.min(i.y,r.y,s.y,o.y),h=Math.max(i.x,r.x,s.x,o.x),c=Math.max(i.y,r.y,s.y,o.y);return new me(h-a,c-l)}function xs(n,t,e,i){if(0!==n){var r=Bi();return qi(r,n,t,e),Ke(r,i)}return i}function Zi(n){return void 0!==n&&"string"==typeof n&&(n=Y(n,window)),n}var bo=function(){function n(){}return n.getContext=function(t){return t.getContext("2d")},n.setCanvasSize=function(t,e,i){t&&(t.setAttribute("width",e.toString()),t.setAttribute("height",i.toString()))},n.prototype.renderGradient=function(t,e,i,r){var s,o,a;if("None"!==t.gradient.type){for(var l=0;l0?(w=0===S.r1?e.arc[parseInt(r.toString(),10)].r1:S.r1,C=0===S.r2?e.arc[parseInt(r.toString(),10)].r2:S.r2,r++):(w=S.r1,C=S.r2);var D=S.angle*(Math.PI/180),A=S.largeArc,x=S.sweep,P={x:u,y:f},L={x:Math.cos(D)*(M.x-P.x)/2+Math.sin(D)*(M.y-P.y)/2,y:-Math.sin(D)*(M.x-P.x)/2+Math.cos(D)*(M.y-P.y)/2},O=Math.pow(L.x,2)/Math.pow(w,2)+Math.pow(L.y,2)/Math.pow(C,2);O>1&&(w*=Math.sqrt(O),C*=Math.sqrt(O));var N=Math.pow(C,2)*Math.pow(L.x,2),T=(A===x?-1:1)*Math.sqrt((Math.pow(w,2)*Math.pow(C,2)-Math.pow(w,2)*Math.pow(L.y,2)-N)/(Math.pow(w,2)*Math.pow(L.y,2)+Math.pow(C,2)*Math.pow(L.x,2)));isNaN(T)&&(T=0);var z={x:T*w*L.y/C,y:T*-C*L.x/w},U={x:(M.x+P.x)/2+Math.cos(D)*z.x-Math.sin(D)*z.y,y:(M.y+P.y)/2+Math.sin(D)*z.x+Math.cos(D)*z.y},B=this.a([1,0],[(L.x-z.x)/w,(L.y-z.y)/C]),j=[(L.x-z.x)/w,(L.y-z.y)/C],Q=[(-L.x-z.x)/w,(-L.y-z.y)/C],oe=this.a(j,Q);this.r(j,Q)<=-1&&(oe=Math.PI),this.r(j,Q)>=1&&(oe=0);var fe=B+oe/2*(x?1:-1);if(Math.cos(fe),Math.sin(fe),S.centp=U,S.xAxisRotation=D,S.rx=w,S.ry=C,S.a1=B,S.ad=oe,S.sweep=x,null!=s){var De=w>C?w:C,xe=w>C?1:w/C,Ie=w>C?C/w:1;s.save(),s.translate(U.x,U.y),s.rotate(D),s.scale(xe,Ie),s.arc(0,0,De,B,B+oe,!x),s.scale(1/xe,1/Ie),s.rotate(-D),s.translate(-U.x,-U.y),s.restore()}break;case"Z":case"z":s.closePath(),u=o,f=a}o=u,a=f}}},n.prototype.drawText=function(t,e,i,r,s,o,a){if(e.content&&!0===e.visible){var l=n.getContext(t);l.save(),this.setStyle(t,e),o&&(e.fontSize*=o),this.applyFlipAndRotate(l,e,t,e.x+e.width*e.pivotX,e.y+e.height*e.pivotY),this.setFontStyle(t,e);var u,d=0;u=e.childNodes;var f=e.wrapBounds;if(l.fillStyle=e.color,f){var p=this.labelAlign(e,f,u);for(d=0;de.width&&"Wrap"!==e.textOverflow&&"NoWrap"===e.textWrapping&&(g.text=VF(g.text,e)),"Clip"!==e.textOverflow&&"Ellipsis"!==e.textOverflow||"Wrap"!==e.textWrapping?l.fillText(g.text,v,y):ya.actualSize.height+a.bounds.y&&(g.text=g.text.slice(0,g.text.length-3),g.text=g.text.concat("...")),l.fillText(g.text,v,y)),"Underline"===e.textDecoration||"Overline"===e.textDecoration||"LineThrough"===e.textDecoration){var M=v,w=void 0,D=v+l.measureText(g.text).width,A=void 0;switch(e.textDecoration){case"Underline":w=y+2,A=y+2;break;case"Overline":w=p.y+g.dy*d,A=p.y+g.dy*d;break;case"LineThrough":w=(y+p.y+g.dy*d)/2+2,A=(y+p.y+g.dy*d)/2+2}l.beginPath(),l.moveTo(M,w),l.lineTo(D,A),l.strokeStyle=e.color,l.lineWidth=.08*e.fontSize,l.globalAlpha=e.opacity,l.stroke()}}}l.restore()}},n.prototype.applyFlipAndRotate=function(t,e,i,r,s){"Horizontal"===e.flip||"Vertical"===e.flip?(t.translate(e.x+e.width/2,e.y+e.height/2),t.rotate(-e.angle*Math.PI/180),t.translate(-e.x-e.width/2,-e.y-e.height/2)):this.rotateContext(i,e.angle,r,s),t.translate(e.x,e.y),"Horizontal"===e.flip?(t.scale(-1,1),t.translate(-1*e.width,0)):"Vertical"===e.flip?(t.scale(1,-1),t.translate(0,-1*e.height)):"Both"===e.flip&&(t.scale(-1,-1),t.translate(-1*e.width,-1*e.height)),t.translate(-e.x,-e.y)},n.prototype.loadImage=function(t,e,i,r,s){var o=new Image;o.src=e.source,this.image(t,o,e.x,e.y,e.width,e.height,e)},n.prototype.drawImage=function(t,e,i,r){var s=this;if(e.visible){var o=n.getContext(t);o.save();var a=e.x+e.width*e.pivotX,l=e.y+e.height*e.pivotY,h=new Image;h.src=e.source,this.setStyle(t,e),o.canvas.id.split("_"),this.applyFlipAndRotate(o,e,t,a,l),r?h.onload=function(){s.loadImage(o,e,t,a,l)}:this.loadImage(o,e,t,a,l),o.restore()}},n.prototype.image=function(t,e,i,r,s,o,a){t.beginPath();var l=e.width,h=e.height,c=s,d=o,u=0,f=0;if(a&&"None"!==a.alignment){var p=a.alignment.toLowerCase().substr(1,3),g=a.alignment.toLowerCase().substr(5,3);if("Slice"===a.scale){var v=function(){u=c,f=h*c/l},y=function(){u=l*d/h,f=d};c>d?(v(),d>f&&y()):c===d?l>h?y():v():(y(),c>u&&v());var S=this.getSliceOffset(p,u,c,l),b=this.getSliceOffset(g,f,d,h),M=l-S,w=h-b,C=u-S*(u/l),D=f-b*(f/h),A=Tt("canvas",{width:s.toString(),height:o.toString()});A.getContext("2d").drawImage(e,S,b,M,w,0,0,C,D),t.drawImage(A,i,r,s,o)}else if("Meet"===a.scale){var P=h/l,L=d/c;f=L>P?c*P:d,i+=this.getMeetOffset(p,u=L>P?c:d/P,c),r+=this.getMeetOffset(g,f,d),t.drawImage(e,0,0,l,h,i,r,u,f)}else t.drawImage(e,i,r,s,o)}else if("None"!==a.flip){var O=1,N=1;("Horizontal"===a.flip||"Both"===a.flip)&&(i=-i,s=-s,O=-1),("Vertical"===a.flip||"Both"===a.flip)&&(r=-r,o=-o,N=-1),t.scale(O,N),t.drawImage(e,i,r,s,o)}else t.drawImage(e,i,r,s,o);t.closePath()},n.prototype.getSliceOffset=function(t,e,i,r){switch(t){case"min":default:return 0;case"mid":return(e-i)/2*r/e;case"max":return(e-i)*r/e}},n.prototype.getMeetOffset=function(t,e,i){var r=Math.max(e,i),s=Math.min(e,i);switch(t){case"min":default:return 0;case"mid":return(r-s)/2;case"max":return r-s}},n.prototype.m=function(t){return Math.sqrt(Math.pow(t[0],2)+Math.pow(t[1],2))},n.prototype.r=function(t,e){return(t[0]*e[0]+t[1]*e[1])/(this.m(t)*this.m(e))},n.prototype.a=function(t,e){return(t[0]*e[1]t.width&&("Ellipsis"===t.textOverflow||"Clip"===t.textOverflow)&&"NoWrap"===t.textWrapping?0:.5*t.width:"right"===t.textAlign&&(c=1*t.width),s.x=t.x+c+(e?e.x:0),s.y=a+d-r.height/2,s},n}(),pb=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Vi=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},xoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return pb(t,n),Vi([I("")],t.prototype,"source",void 0),Vi([I("transparent")],t.prototype,"color",void 0),Vi([I("None")],t.prototype,"scale",void 0),Vi([I("None")],t.prototype,"align",void 0),t}(Ee),Toe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return pb(t,n),Vi([I("Page")],t.prototype,"mode",void 0),Vi([I("PageSettings")],t.prototype,"region",void 0),Vi([re({top:25,bottom:25,left:25,right:25},Jn)],t.prototype,"margin",void 0),Vi([I(!1)],t.prototype,"canZoomIn",void 0),Vi([I(void 0)],t.prototype,"customBounds",void 0),Vi([I(!1)],t.prototype,"canFit",void 0),t}(Ee),Aoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return pb(t,n),Vi([I(null)],t.prototype,"width",void 0),Vi([I(null)],t.prototype,"height",void 0),Vi([re({},Jn)],t.prototype,"margin",void 0),Vi([I("Landscape")],t.prototype,"orientation",void 0),Vi([I("Infinity")],t.prototype,"boundaryConstraints",void 0),Vi([re({},xoe)],t.prototype,"background",void 0),Vi([I(!1)],t.prototype,"multiplePage",void 0),Vi([I(!1)],t.prototype,"showPageBreaks",void 0),Vi([re({},Toe)],t.prototype,"fitOptions",void 0),t}(Ee),Loe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return pb(t,n),Vi([I(0)],t.prototype,"horizontalOffset",void 0),Vi([I(0)],t.prototype,"verticalOffset",void 0),Vi([I(1)],t.prototype,"currentZoom",void 0),Vi([I(0)],t.prototype,"viewPortWidth",void 0),Vi([I(0)],t.prototype,"viewPortHeight",void 0),Vi([I(.2)],t.prototype,"minZoom",void 0),Vi([I(30)],t.prototype,"maxZoom",void 0),Vi([I("Diagram")],t.prototype,"scrollLimit",void 0),Vi([I()],t.prototype,"scrollableArea",void 0),Vi([I(!1)],t.prototype,"canAutoScroll",void 0),Vi([I(100)],t.prototype,"autoScrollFrequency",void 0),Vi([re({left:15,right:15,top:15,bottom:15},Jn)],t.prototype,"autoScrollBorder",void 0),Vi([re({left:0,right:0,top:0,bottom:0},Jn)],t.prototype,"padding",void 0),Vi([I(.2)],t.prototype,"zoomFactor",void 0),t}(Ee),Noe=function(){function n(){this.services={}}return n.prototype.register=function(t,e){this.services[""+t]=e},n.prototype.getService=function(t){return this.services[""+t]},n}(),WF=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),ya=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},YF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return WF(t,n),ya([I("lightgray")],t.prototype,"lineColor",void 0),ya([I("")],t.prototype,"lineDashArray",void 0),ya([I([1.25,18.75,.25,19.75,.25,19.75,.25,19.75,.25,19.75])],t.prototype,"lineIntervals",void 0),ya([I([1,19,.5,19.5,.5,19.5,.5,19.5,.5,19.5])],t.prototype,"dotIntervals",void 0),ya([I([20])],t.prototype,"snapIntervals",void 0),t}(Ee),Ooe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return WF(t,n),ya([re({},YF)],t.prototype,"horizontalGridlines",void 0),ya([re({},YF)],t.prototype,"verticalGridlines",void 0),ya([I(ei.All)],t.prototype,"constraints",void 0),ya([I(5)],t.prototype,"snapAngle",void 0),ya([I("Lines")],t.prototype,"gridType",void 0),ya([I(5)],t.prototype,"snapObjectDistance",void 0),ya([I("#07EDE1")],t.prototype,"snapLineColor",void 0),t}(Ee),QF=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),el=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},GF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return QF(t,n),el([I(5)],t.prototype,"interval",void 0),el([I(100)],t.prototype,"segmentWidth",void 0),el([I("Horizontal")],t.prototype,"orientation",void 0),el([I("RightOrBottom")],t.prototype,"tickAlignment",void 0),el([I("red")],t.prototype,"markerColor",void 0),el([I(25)],t.prototype,"thickness",void 0),el([I(null)],t.prototype,"arrangeTick",void 0),t}(Ee),koe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return QF(t,n),el([I(!1)],t.prototype,"showRulers",void 0),el([I(!0)],t.prototype,"dynamicGrid",void 0),el([re({orientation:"Horizontal"},GF)],t.prototype,"horizontalRuler",void 0),el([re({orientation:"Vertical"},GF)],t.prototype,"verticalRuler",void 0),t}(Ee),Poe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),XF=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},zoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Poe(t,n),XF([I("")],t.prototype,"property",void 0),XF([I("")],t.prototype,"field",void 0),t}(Ee),wT=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),ln=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},qF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return wT(t,n),ln([I("")],t.prototype,"read",void 0),ln([I("")],t.prototype,"create",void 0),ln([I("")],t.prototype,"update",void 0),ln([I("")],t.prototype,"destroy",void 0),ln([I()],t.prototype,"customFields",void 0),t}(Ee),Roe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return wT(t,n),ln([I("")],t.prototype,"id",void 0),ln([I("")],t.prototype,"sourceID",void 0),ln([I("")],t.prototype,"targetID",void 0),ln([I(null)],t.prototype,"sourcePointX",void 0),ln([I(null)],t.prototype,"sourcePointY",void 0),ln([I(null)],t.prototype,"targetPointX",void 0),ln([I(null)],t.prototype,"targetPointY",void 0),ln([I(null)],t.prototype,"dataManager",void 0),ln([re({},qF)],t.prototype,"crudAction",void 0),t}(Ee),Hoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return wT(t,n),ln([I("")],t.prototype,"id",void 0),ln([I(null)],t.prototype,"dataManager",void 0),ln([I(null)],t.prototype,"dataSource",void 0),ln([I("")],t.prototype,"root",void 0),ln([I("")],t.prototype,"parentId",void 0),ln([I()],t.prototype,"doBinding",void 0),ln([Bt([],zoe)],t.prototype,"dataMapSettings",void 0),ln([re({},qF)],t.prototype,"crudAction",void 0),ln([re({},Roe)],t.prototype,"connectionDataSource",void 0),t}(Ee),$F=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Cr=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Boe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return $F(t,n),Cr([I("LeftInFlow")],t.prototype,"yesBranchDirection",void 0),Cr([I("RightInFlow")],t.prototype,"noBranchDirection",void 0),Cr([I(["Yes","True"])],t.prototype,"yesBranchValues",void 0),Cr([I(["No","False"])],t.prototype,"noBranchValues",void 0),t}(Ee),Foe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return $F(t,n),Cr([I("")],t.prototype,"fixedNode",void 0),Cr([I(30)],t.prototype,"horizontalSpacing",void 0),Cr([I("SamePoint")],t.prototype,"connectionPointOrigin",void 0),Cr([I("Nonlinear")],t.prototype,"arrangement",void 0),Cr([I(30)],t.prototype,"verticalSpacing",void 0),Cr([I(30)],t.prototype,"maxIteration",void 0),Cr([I(40)],t.prototype,"springFactor",void 0),Cr([I(50)],t.prototype,"springLength",void 0),Cr([re({left:50,top:50,right:0,bottom:0},Jn)],t.prototype,"margin",void 0),Cr([I("Auto")],t.prototype,"horizontalAlignment",void 0),Cr([I("Auto")],t.prototype,"verticalAlignment",void 0),Cr([I("TopToBottom")],t.prototype,"orientation",void 0),Cr([I("Auto")],t.prototype,"connectionDirection",void 0),Cr([I("Default")],t.prototype,"connectorSegments",void 0),Cr([I("None")],t.prototype,"type",void 0),Cr([I()],t.prototype,"getLayoutInfo",void 0),Cr([I()],t.prototype,"layoutInfo",void 0),Cr([I()],t.prototype,"getBranch",void 0),Cr([I()],t.prototype,"bounds",void 0),Cr([I(!0)],t.prototype,"enableAnimation",void 0),Cr([I(!1)],t.prototype,"enableRouting",void 0),Cr([I("")],t.prototype,"root",void 0),Cr([re({},Boe)],t.prototype,"flowchartLayoutSettings",void 0),t}(Ee),_oe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),ZF=function(n){function t(e,i){var r=n.call(this,e,!0)||this;return r.oldValue=null,r.endPoint=i,r}return _oe(t,n),t.prototype.mouseDown=function(e){var i,r=!0;if(e.source&&e.source.connectors&&(i=e.source.connectors[0]),e.info&&e.actualObject&&(r=e.info.ctrlKey&&"Orthogonal"!==e.actualObject.type),i&&r){this.inAction=!0,this.undoElement=$(e.source),n.prototype.mouseDown.call(this,e);for(var s=0;s0)1!==s&&this.removePrevSegment(i,s);else if(a){var l=R.distancePoints(a.points[0],a.points[1]);Math.abs(a.length||0===a.length?a.length:l)<=5&&this.removeNextSegment(i,s)}this.commandHandler.updateEndPoint(i,r),i.selectedSegmentIndex=0}if(this.undoElement){var c=$(e.source);this.commandHandler.addHistoryEntry({type:"SegmentChanged",redoObject:c,undoObject:this.undoElement,category:"Internal"})}if(i.isBezierEditing&&(i.isBezierEditing=!1),this.prevPosition!==this.startPosition){var u={source:i,state:"Completed",oldValue:this.oldValue,newValue:$(this.selectedSegment),cancel:!1,segment:this.selectedSegment};this.commandHandler.triggerEvent(Ce.segmentChange,u)}n.prototype.mouseUp.call(this,e)},t.prototype.removePrevSegment=function(e,i){var r=e.segments[i-2],s=e.segments[i+1];if(s&&!((s.length||0===s.length?s.length:R.distancePoints(s.points[0],s.points[1]))<=5)){var a=e.segments.slice(i-1,i+1),l={element:e,removeSegments:a,type:"Removal",cancel:!1};if(this.commandHandler.triggerEvent(Ce.segmentCollectionChange,l),!l.cancel){var h=e.segments[i+1];e.segments.splice(i-1,2);var c=this.selectedSegment;"Left"===c.direction||"Right"===c.direction?(r.points[r.points.length-1].x=h.points[0].x,h.points[0].y=r.points[r.points.length-1].y):(r.points[r.points.length-1].y=h.points[0].y,h.points[0].x=r.points[r.points.length-1].x),(c.length||0===c.length)&&this.findSegmentDirection(r),this.findSegmentDirection(h)}}},t.prototype.findSegmentDirection=function(e){e.direction&&(e.length||0===e.length)&&(e.length=R.distancePoints(e.points[0],e.points[e.points.length-1]),e.direction=R.direction(e.points[0],e.points[e.points.length-1]))},t.prototype.removeNextSegment=function(e,i){var l,h,r=this.selectedSegment,s=e.segments[i-1],o=e.segments[i+2],a=e.segments[i+1];if(a.length||0===a.length?(l=e.segments.slice(i,2),h={element:e,removeSegments:l,type:"Removal",cancel:!1},this.commandHandler.triggerEvent(Ce.segmentCollectionChange,h={element:e,removeSegments:l,type:"Removal",cancel:!1}),h.cancel||(e.segments.splice(i,2),"Top"===r.direction||"Bottom"===r.direction?(o.points[0].y=r.points[0].y,s.points[s.points.length-1].x=o.points[0].x):(o.points[0].x=r.points[0].x,s.points[s.points.length-1].y=o.points[0].y))):(l=e.segments.slice(i+1,1),this.commandHandler.triggerEvent(Ce.segmentCollectionChange,h={element:e,removeSegments:l,type:"Removal",cancel:!1}),h.cancel||(e.segments.splice(i+1,1),"Top"===r.direction||"Bottom"===r.direction?s.points[s.points.length-1].x=a.points[a.points.length-1].x:s.points[s.points.length-1].y=a.points[a.points.length-1].y,this.findSegmentDirection(s),r.length=r.direction=null)),s&&o&&!h.cancel&&(s.length=R.distancePoints(s.points[0],o.points[0]),s.direction=R.direction(s.points[0],o.points[0]),o.length||0===o.length)){o.length=R.distancePoints(s.points[s.points.length-1],o.points[o.points.length-1]);var c=s.points,d=o.points;o.direction=R.direction(c[c.length-1],d[d.length-1])}},t.prototype.addOrRemoveSegment=function(e,i,r){for(var s,o,a=[],l={segments:e.segments},h=0;h0?"Bottom":"Top":r>0?"Right":"Left",length:i.points[0].x===i.points[1].x?s:r},!0)),l.push(new wi(e,"segments",{type:"Orthogonal",direction:c,length:h/2},!0));var f={element:e,addSegments:l,type:"Addition",cancel:!1};return this.commandHandler.triggerEvent(Ce.segmentCollectionChange,f),f.cancel||(e.segments=l.concat(e.segments),a=o+2),a},t.prototype.insertFirstSegment=function(e,i,r,s,o){var a,l,d,u,h=[];if(e.sourcePortID&&i.length&&e.segments[0].points.length>2)for(var f=void 0,p=0;p0?"Bottom":"Top":r>0?"Right":"Left"),f=u,h.push(u)}else h.push(new wi(e,"segments",{type:"Orthogonal",direction:i.direction,length:i.length/3},!0)),"Bottom"===i.direction||"Top"===i.direction?(l=Math.abs(r),a=r>0?"Right":"Left"):(l=Math.abs(s),a=s>0?"Bottom":"Top"),u=new wi(e,"segments",{type:"Orthogonal",direction:a,length:l},!0),h.push(u);var y={element:e,addSegments:h,type:"Addition",cancel:!1};if(this.commandHandler.triggerEvent(Ce.segmentCollectionChange,y),!y.cancel){if(e.sourcePortID&&i.length&&e.segments[0].points.length>2)e.segments.splice(0,1),d=1;else{var S=e.segments[1];S&&S.length&&(S.length=a!==S.direction?S.length+l:S.length-l),d=2,i.length=2*i.length/3}e.segments=h.concat(e.segments)}return d},t.prototype.updateAdjacentSegments=function(e,i,r,s){var o=e.segments[parseInt(i.toString(),10)],a=o.points[o.points.length-1],h=!0;"Orthogonal"===o.type&&(o.points[0]=o.points[0],o.points[o.points.length-1]=a,e.segments[i-1]&&(h=this.updatePreviousSegment(r,s,e,i)),e.segments.length-1>i&&h&&this.updateNextSegment(e,o,e.segments[i+1],r,s))},t.prototype.addTerminalSegment=function(e,i,r,s,o){var l,h,c,d,a=e.segments.indexOf(i),u=[],f=e.segments.pop(),p=e.segments[e.segments.length-1];l=p&&"Orthogonal"===p.type?p:null;for(var g=0;g0&&"Left"===o.direction?c.middleLeft:c.middleRight,o.length>c.width/2?Math.abs(a.length)0&&"Top"===o.direction?c.topCenter:c.bottomCenter,o.length>c.height/2?Math.abs(a.length)1)for(var a=0,l=this.diagram.views;a0)for(var e=t===Ce.onUserHandleMouseLeave?this.previousAction:this.action,i={element:void 0},r=0;r0)for(var r={element:void 0},s=void 0,o=void 0,a=0;a-1&&(o=s,this.previousTarget=i,this.targetItem=e),o===e.fixedUserHandles[parseInt(a.toString(),10)].id&&(r.element=e.fixedUserHandles[parseInt(a.toString(),10)],this.userHandle(t,a,r,e))},n.prototype.mouseDown=function(t){var e=this;if("touchstart"===t.type&&(this.timeOutTapHold=setTimeout(function(){("Select"===e.action||"Drag"===e.action)&&e.mouseMove(t,void 0)},500)),!0!==this.inAction||!(this.tool instanceof GI||this.tool instanceof pa)){this.focus=!0;var i=t.touches,r=!!document.getElementsByClassName("e-dragclone")[0];if(this.isMouseOnScrollBar(t)&&!r)return this.isScrolling=!0,void t.preventDefault();if(this.checkFixedUserHandleEvent(Ce.onFixedUserHandleMouseDown,this.targetItem,this.previousTarget),this.checkUserHandleEvent(Ce.onUserHandleMouseDown),!this.checkEditBoxAsTarget(t)&&jv(this.diagram)||Lc(this.diagram)&&!FI(this.diagram))if(("Select"===this.action||"Drag"===this.action)&&this.diagram.updatePortVisibility(this.hoverElement,Gt.Hover,!0),!(this.tool instanceof zl||this.tool instanceof Rl)||2!==t.button&&2!==t.buttons)if(!0===this.inAction&&!0===this.isMouseDown&&(this.tool instanceof zl||this.tool instanceof Rl))this.isMouseDown=!0,this.eventArgs={},this.getMouseEventArgs(this.currentPosition,this.eventArgs),this.eventArgs.position=this.currentPosition,this.tool.mouseDown(this.eventArgs);else{this.isMouseDown=!0,this.currentPosition=this.prevPosition=this.getMousePosition(t),this.eventArgs={},this.diagram.textEditing&&!this.isMouseOnScrollBar(t)&&(this.diagram.endEdit(),this.diagram.textEditing=!1,"Canvas"===this.diagram.mode&&1!==this.diagram.scroller.currentZoom&&this.diagram.refreshDiagramLayer());var o=this.getTargetElement();this.action=this.diagram.findActionToBeDone(o.obj,o.sourceElement,this.currentPosition,o.target);var a=this.isMetaKey(t);a&&t.shiftKey&&this.diagram.connectorEditingToolModule?this.action="SegmentEnd":(a||t.shiftKey)&&(_v(this.diagram)||Uv(this.diagram))&&(this.action="Select"),this.tool=this.diagram.getTool(this.action),this.tool||(this.action="Select",this.tool=this.diagram.getTool(this.action)),this.getMouseEventArgs(this.currentPosition,this.eventArgs),(a||t.shiftKey)&&(this.eventArgs.info=a&&t.shiftKey?{ctrlKey:a,shiftKey:t.shiftKey}:{ctrlKey:!0}),this.eventArgs.position=this.currentPosition;var h=this.diagram.selectedItems.nodes;if(this.tool.mouseDown(this.eventArgs),this.diagram.selectedItems.canToggleSelection&&h&&this.diagram.selectedItems.nodes&&this.tool instanceof fa)for(var c=0;c=2&&(this.touchStartList=HF(this.touchStartList,0,i)),i||t.preventDefault())}else this.inAction=!1,this.tool.mouseUp(this.eventArgs);!this.isForeignObject(t.target)&&!this.isForeignObject(t.target,!0)&&!i&&t.preventDefault()}},n.prototype.mouseMoveExtend=function(t,e){(this.tool instanceof zl||this.tool instanceof Rl)&&this.tool.mouseMove(this.eventArgs),this.diagram.scrollSettings.canAutoScroll?this.checkAutoScroll(t):this.blocked||this.tool.mouseMove(this.eventArgs),this.eventArgs.target&&(this.hoverElement=this.eventArgs.target);var i=!((this.eventArgs.target instanceof te||this.eventArgs.target instanceof de)&&(e instanceof te||e instanceof de));this.tool instanceof zd&&this.diagram.updatePortVisibility(this.hoverElement instanceof te||this.hoverElement instanceof de?this.hoverElement:this.hoverNode,Gt.Connect|Gt.Hover,i),this.hoverElement instanceof te&&this.hoverNode instanceof te&&this.hoverNode&&this.hoverNode.id!==this.hoverElement.id&&this.diagram.updatePortVisibility(this.hoverNode,Gt.Connect|Gt.Hover,!0),this.hoverElement instanceof de&&this.hoverElement.ports.length>0&&this.diagram.updatePortVisibility(this.hoverElement,Gt.Connect|Gt.Hover,!0),this.previousElement instanceof te&&this.hoverElement&&this.previousElement.id!==this.hoverElement.id&&this.diagram.updatePortVisibility(this.previousElement,Gt.Connect|Gt.Hover,!0),this.previousElement=this.hoverElement,""!==this.diagram.tooltip.content&&(this.hoverElement=null),this.hoverNode=i?null:e},n.prototype.checkAction=function(t){if("LabelSelect"===this.action&&this.eventArgs.sourceWrapper&&(this.eventArgs.sourceWrapper instanceof li||this.eventArgs.sourceWrapper instanceof es)){var e=this.commandHandler.findTarget(this.eventArgs.sourceWrapper,this.eventArgs.source);!_r(this.diagram,e,!1,this.eventArgs.sourceWrapper)&&ro(e)&&(this.action="LabelDrag",this.tool=this.getTool(this.action),this.tool.mouseDown(this.initialEventArgs))}else ro(t)&&Ad(t)&&this.initialEventArgs&&this.initialEventArgs.source&&"Select"===this.action&&(!_r(this.diagram,this.eventArgs.source,!1)&&this.eventArgs.source instanceof ti&&this.getMouseEventArgs(this.currentPosition,this.eventArgs),(!(t instanceof de)||t instanceof de&&!(wr(this.currentPosition,t.sourcePoint,t.hitPadding)||wr(this.currentPosition,t.targetPoint,t.hitPadding)))&&(this.action="Drag"),this.tool=this.getTool(this.action),this.tool.mouseDown(this.initialEventArgs))},n.prototype.isSwimlaneElements=function(t){return!(t&&(t.isLane||t.isPhase||t.isHeader))},n.prototype.canShowTouchTooltip=function(t){return!!("touchstart"===t.type&&this.diagram.tool&ni.SingleSelect&&this.diagram.tool&ni.ZoomPan)&&(this.isMouseDown=!1,!0)},n.prototype.mouseMove=function(t,e){if(this.focus=!0,"touchmove"===t.type&&(this.touchArgs={target:t.target,type:"touchmove"}),this.isScrolling)t.preventDefault();else if(jv(this.diagram)||Lc(this.diagram)&&!FI(this.diagram)){this.currentPosition=this.getMousePosition(t);var i=this.diagram.findObjectsUnderMouse(this.currentPosition),r=this.diagram.findObjectUnderMouse(i,this.action,this.inAction);!function qne(n,t){n.rulerSettings.showRulers&&(n.hRuler.drawRulerMarker(n.hRuler.element,t,n.scroller.horizontalOffset),n.vRuler.drawRulerMarker(n.vRuler.element,t,n.scroller.verticalOffset))}(this.diagram,this.currentPosition);var s=!1,o=void 0;if("touchmove"===t.type&&(e=t.touches)&&e.length>1&&(this.touchMoveList=HF(this.touchMoveList,0,e),"PinchZoom"!==this.action&&(s=!0)),!1===R.equals(this.currentPosition,this.prevPosition)||this.inAction||this.canShowTouchTooltip(t)){if(!1===this.isMouseDown||s){this.eventArgs={};var a=null,l=void 0;if(null!==r){if((a=this.diagram.findElementUnderMouse(r,this.currentPosition,this.diagram))&&(l=this.commandHandler.findTarget(a,r)),(l instanceof Kn||l instanceof Or)&&(l.tooltip&&""!==l.tooltip.content||(l=r)),l!==this.hoverElement){var h=this.getContent();this.hoverElement&&"Auto"===this.hoverElement.tooltip.openOn&&""!==h&&this.elementLeave(),this.diagram.updatePortVisibility(this.hoverElement,Gt.Hover,!0),r instanceof te&&(this.hoverNode=r);var c=!0;!this.isSwimlaneElements(r)&&this.hoverElement&&this.isSwimlaneElements(this.hoverElement)&&(c=!1),this.hoverElement=c?r:this.hoverElement;var d,u=void 0;(d=this.diagram.findElementUnderMouse(r,this.currentPosition,this.diagram))instanceof Ze&&((u=this.commandHandler.findTarget(d,r))instanceof Es||u instanceof Tc)&&this.hoverElement.constraints&ai.ToolTip&&(this.hoverElement=u);var f=void 0;d instanceof li&&((f=this.commandHandler.findTarget(d,r))instanceof Kn||f instanceof Or)&&f.constraints&Nr.Tooltip&&(this.hoverElement=f),c?this.elementEnter(this.currentPosition,!1):this.hoverElement=r}else this.hoverElement&&this.hoverElement===l&&this.hoverElement.tooltip.content&&void 0!==this.diagram.tooltipObject&&"Mouse"===this.hoverElement.tooltip.relativeMode&&this.setTooltipOffset(this.currentPosition);a&&(o=this.commandHandler.findTarget(a,r))}this.action=this.diagram.findActionToBeDone(r,a,this.currentPosition,o),this.checkFixedUserHandleEvent(Ce.onFixedUserHandleMouseEnter,r,a),this.checkUserHandleEvent(Ce.onUserHandleMouseEnter),this.checkPreviousAction(),this.getMouseEventArgs(this.currentPosition,this.eventArgs),this.tool=this.getTool(this.action),this.mouseEvents(),this.tool instanceof pa||this.tool instanceof Rl||this.tool instanceof zl?this.tool.mouseMove(this.eventArgs):e&&this.tool instanceof Kv&&this.tool.mouseDown(this.eventArgs),this.updateCursor(),this.renderUmlHighLighter(this.eventArgs);var p=!1;this.hoverElement&&!(this.tool instanceof Kv)&&r instanceof te&&this.isSwimlaneElements(r)&&(0===this.diagram.selectedItems.nodes.length||!_r(this.diagram,this.hoverElement))||this.hoverElement instanceof de||(p=!0),this.hoverElement&&!(this.tool instanceof Kv)&&r instanceof de&&(0===this.diagram.selectedItems.connectors.length||!_r(this.diagram,this.hoverElement))||this.hoverElement instanceof te||(p=!0),this.diagram.updatePortVisibility(this.hoverElement,Gt.Hover,p);var g=this.getContent();null===r&&this.hoverElement&&"Auto"===this.hoverElement.tooltip.openOn&&g&&(this.hoverElement=null,this.elementLeave()),s=!1}else{this.eventArgs.position=this.currentPosition,"Drag"===this.action&&!_r(this.diagram,this.eventArgs.source,!1)&&this.eventArgs.source instanceof ti&&this.getMouseEventArgs(this.currentPosition,this.eventArgs),this.mouseEvents(),(t.ctrlKey||t.shiftKey)&&(this.eventArgs.info=t.ctrlKey&&t.shiftKey?{ctrlKey:t.ctrlKey,shiftKey:t.shiftKey}:{ctrlKey:!0}),this.checkAction(r);var y=this.getConnectorPadding(this.eventArgs);this.getMouseEventArgs(this.currentPosition,this.eventArgs,this.eventArgs.source,y),this.updateCursor(),this.inAction=!0,this.initialEventArgs=null,("Drag"===this.action||"Rotate"===this.action)&&(this.diagram.diagramActions=this.diagram.diagramActions|ee.Interactions);var S=this.diagram.scroller.getPageBounds();this.mouseMoveExtend(t,r);var b=this.diagram.scroller.getPageBounds();if(r&&(S.width!==b.width||S.height!==b.height||S.x!==b.x||S.y!==b.y)&&this.diagram.views&&this.diagram.views.overview){var M=this.diagram.views.overview;M.updateView(M)}}this.prevPosition=this.currentPosition,this.isForeignObject(t.target,!0)||t.preventDefault()}}},n.prototype.getContent=function(){var i,t=this.hoverElement instanceof te&&this.hoverElement.constraints&ie.Tooltip||this.hoverElement instanceof de&&this.hoverElement.constraints&qe.Tooltip||(this.hoverElement instanceof Es||this.hoverElement instanceof Tc)&&this.hoverElement.constraints&ai.ToolTip||(this.hoverElement instanceof Kn||this.hoverElement instanceof Or)&&this.hoverElement.constraints&Nr.Tooltip,e=this.hoverElement;e instanceof te&&e.children&&e.children.length>0&&(i=this.findIntersectChild(e));var r=t?this.hoverElement.tooltip.content:this.diagram.tooltip.content;return i?i.tooltip.content:r},n.prototype.findIntersectChild=function(t){for(var e,i=new Ne(this.currentPosition.x,this.currentPosition.y,8,8),r=0;r1&&1===t.which&&!function Zre(n){return!!(n&ee.PreventClearSelection)}(this.diagram.diagramActions)&&(c=!1,this.commandHandler.clearSelection()),(!_r(this.diagram,h)||!c)&&(this.commandHandler.selectObjects([h],void 0,a),this.diagram.selectedItems.canToggleSelection)){var d=this.diagram.selectedItems.nodes;d?d[0].parentObj instanceof Fd&&(s=!0):this.diagram.selectedItems.connectors.length>0&&(s=!0)}}var u=!1,f=this.updateContainerProperties(),p=void 0;if(this.addUmlNode(),this.inAction=!1,this.isMouseDown=!1,this.diagram.selectedObject.helperObject&&(p=this.updateContainerBounds()),this.tool&&(this.tool.prevPosition||this.tool instanceof X3)){this.eventArgs.position=this.currentPosition;var g=this.getConnectorPadding(this.eventArgs);this.getMouseEventArgs(this.currentPosition,this.eventArgs,this.eventArgs.source,g);var v=this.isMetaKey(t);if((v||t.shiftKey)&&(this.eventArgs.info=v&&t.shiftKey?{ctrlKey:v,shiftKey:t.shiftKey}:{ctrlKey:!0}),this.diagram.diagramActions&ee.Interactions&&(this.diagram.diagramActions=this.diagram.diagramActions&~ee.Interactions),this.eventArgs.clickCount=t.detail,this.diagram.selectedObject.helperObject&&(this.tool instanceof fa||this.tool instanceof Rd)){if(this.diagram.selectedObject.actualObject&&""!==this.diagram.selectedObject.actualObject.parentId){var S=this.diagram.getObject(this.diagram.selectedObject.actualObject.parentId);S&&S.isLane&&(this.commandHandler.isContainer=!0)}(u=this.diagram.lineRoutingModule&&this.diagram.nameTable.helper&&this.eventArgs.target&&this.eventArgs.target.isLane&&(this.eventArgs.source instanceof ti&&this.eventArgs.source.nodes.length>0&&""===this.eventArgs.source.nodes[0].parentId||""===this.eventArgs.source.parentId))&&(this.diagram.diagramActions=this.diagram.diagramActions|ee.PreventLaneContainerUpdate),this.tool.mouseUp(this.eventArgs,f.isPreventHistory)}else{if(this.diagram.selectedItems.canToggleSelection){var b=void 0,M=void 0;if(this.diagram.selectedItems.nodes.length>0)for(var w=0;w1&&D[0].id===i[parseInt(w.toString(),10)].id||r.length>0)&&(M=!0);!this.isSwimlaneSelected&&!s&&!M&&this.tool instanceof fa&&"Select"===this.currentAction&&(!b||this.diagram.selectedItems.connectors.length>0)&&this.commandHandler.clearSelection(!0)}this.isSwimlaneSelected=!1,this.tool.mouseUp(this.eventArgs),this.diagram.checkMenu&&(-1!==window.navigator.userAgent.indexOf("Linux")||-1!==window.navigator.userAgent.indexOf("X11"))&&(!t.pageY&&t instanceof TouchEvent&&t.changedTouches?(window.getSelection().removeAllRanges(),this.diagram.contextMenuModule.contextMenu.open(t.changedTouches[0].pageY,t.changedTouches[0].pageX,this.diagram.element),t.preventDefault()):this.diagram.contextMenuModule.contextMenu.open(t.pageY,t.pageX,this.diagram.element),this.diagram.checkMenu=!1)}f.hasStack&&this.diagram.endGroupAction()}if(p&&this.diagram.endGroupAction(),this.updateContainerBounds(!0),2!==this.eventArgs.clickCount&&(this.commandHandler.updateSelectedNodeProperties(this.eventArgs.source),u)){this.diagram.diagramActions=this.diagram.diagramActions&~ee.PreventLaneContainerUpdate;var A=this.eventArgs.source instanceof ti?this.eventArgs.source.nodes:[this.eventArgs.source];if(A)for(w=0;w0&&!N&&this.diagram.renderSelector(!0),!this.inAction&&!this.diagram.currentSymbol&&this.eventArgs){var T=this.getTargetElement();this.diagram.tool!==ni.ZoomPan&&this.diagram.triggerEvent(Ce.click,{element:T.target instanceof Es?T.target:this.eventArgs.source||this.diagram,position:this.eventArgs.position,count:t.detail,actualObject:this.eventArgs.actualObject,button:0===t.button?"Left":1===t.button?"Middle":"Right"})}this.eventArgs={}}this.diagram.diagramActions=this.diagram.diagramActions&~ee.PreventLaneContainerUpdate,e&&this.updateAnnotation(this.diagram.selectedItems),this.previousElement=null,this.eventArgs={},this.diagram.commandHandler.removeStackHighlighter()},n.prototype.isSwimlaneChild=function(t){if(t.shape&&"SwimLane"!==t.shape.type){var e=this.diagram.nameTable[t.parentId];if(!e)return!1;var i=e.parentId?this.diagram.nameTable[e.parentId]:e;return i&&i.shape&&"SwimLane"===i.shape.type}return!1},n.prototype.updateAnnotation=function(t){var e=t.nodes;if(e.length>0)for(var i=0;i0&&(a+=1),h.isPhase){l="Horizontal"===r.orientation?this.currentPosition.x-e.wrapper.bounds.x:this.currentPosition.y-(e.wrapper.bounds.y+r.header.height);var g={id:Qe(),offset:l,header:{annotation:{content:void 0===h.phases[0].header?"Phase":h.phases[0].header.annotation.content,style:void 0===h.phases[0].header?{}:h.phases[0].header.annotation.style}},style:void 0===h.phases[0]?{}:h.phases[0].style};this.diagram.addPhases(e,[g])}else{var v={id:Qe(),style:h.lanes[0].style,header:{annotation:{content:h.lanes[0].header.annotation.content,style:h.lanes[0].header.annotation.style},style:h.lanes[0].header.style}};if("Horizontal"===h.orientation?v.height=h.lanes[0].height:v.width=h.lanes[0].width,"Horizontal"===r.orientation?(s=i.rowIndex?i.rowIndex:this.diagram.nameTable[i.parentId].rowIndex,i.wrapper.offsetYs)v.header.width=r.lanes[parseInt(s.toString(),10)].header.width,v.header.height=r.lanes[parseInt(s.toString(),10)].header.height;else{var S=void 0;S="Horizontal"===r.orientation?i.rowIndex<3?0:s-a-1:s-1,v.header.width=r.lanes[parseInt(S.toString(),10)].header.width,v.header.height=r.lanes[parseInt(S.toString(),10)].header.height}p&&("height"===p?(v.width=v.height,delete v.height):(v.height=v.width,delete v.width)),this.diagram.addLanes(e,[v],"Horizontal"===r.orientation?s-a:s)}this.commandHandler.select(e)}else if(h.isLane){var b={id:Qe(),width:t.width,height:t.height,addInfo:t.addInfo,shape:{type:"SwimLane",header:{annotation:{content:void 0===h.header?"Header":h.header.annotation.content,style:void 0===h.header?{}:h.header.annotation.style},height:50,style:h.header?h.header.style:h.lanes[0].header.style},phases:[{id:Qe(),header:{annotation:{content:void 0===h.phases||void 0===h.phases[0].header?"Phase":h.phases[0].header.annotation.content,style:void 0===h.phases||void 0===h.phases[0].header?{}:h.phases[0].header.annotation.style},style:void 0===h.phases||void 0===h.phases[0].header?{}:h.phases[0].header.style},style:void 0===h.phases?{}:h.phases[0].style}],lanes:[{id:Qe(),height:t.height,width:t.width,style:h.lanes[0].style,header:{annotation:{content:h.lanes[0].header.annotation.content,style:h.lanes[0].header.annotation.style},style:h.lanes[0].header.style}}],orientation:h.orientation}};"Vertical"===h.orientation&&(b.width+=20),b.offsetX=this.currentPosition.x+b.width/2,b.offsetY=this.currentPosition.y+b.height/2,b.style=t.style,this.diagram.add(b)}},n.prototype.mouseLeave=function(t){this.tool&&this.inAction&&this.tool.mouseLeave(this.eventArgs),this.diagram.selectedObject.helperObject&&(this.updateContainerProperties(),this.updateContainerBounds()&&this.diagram.endGroupAction()),this.eventArgs&&this.eventArgs.source&&(this.diagram.updatePortVisibility(this.eventArgs.source,Gt.Hover,!0),this.hoverElement=null),this.eventArgs&&!this.eventArgs.source&&this.hoverElement&&(this.hoverElement=null),this.tool instanceof zd&&this.eventArgs&&this.eventArgs.target&&this.eventArgs.target instanceof te&&(this.diagram.updatePortVisibility(this.eventArgs.target,Gt.Hover|Gt.Connect,!0),this.hoverElement=null);var i=this.diagram.selectedItems;i&&i.wrapper&&(am(this.diagram,i)||this.diagram.renderSelector(!0)),(this.diagram.diagramActions&ee.Interactions||this.diagram.diagramActions&ee.ToolAction)&&(this.diagram.diagramActions=this.diagram.diagramActions&~ee.ToolAction),this.isMouseDown=!1,this.focus=!1,this.touchStartList=null,this.touchMoveList=null,this.elementLeave(),this.commandHandler.removeSnap(),this.inAction=!1,this.eventArgs={},this.diagram.selectedObject&&this.diagram.selectedObject.helperObject&&(this.diagram.remove(this.diagram.selectedObject.helperObject),this.diagram.selectedObject={helperObject:void 0,actualObject:void 0}),this.tool=null,function Xne(){var t,e,n=document.getElementsByClassName("e-d-ruler-marker");if(n&&n.length>0)for(e=n.length-1;e>=0;e--)(t=n[parseInt(e.toString(),10)])&&t.parentNode.removeChild(t)}(),"Rotate"===this.action&&this.diagram.diagramCanvas.classList.remove("e-diagram-rotate"),t.preventDefault()},n.prototype.mouseWheel=function(t){this.diagram.blazorActions|=on.interaction;var e={event:t,cancel:!1};if(this.diagram.triggerEvent(Ce.mouseWheel,e),!e.cancel){var i=t.wheelDelta>0||-40*t.detail>0,r=this.getMousePosition(t);if(this.diagram.tooltipObject.close(),this.isMetaKey(t)){var o=this.diagram.scrollSettings.zoomFactor;this.diagram.zoomTo(i?{type:"ZoomIn",zoomFactor:o,focusPoint:r}:{type:"ZoomOut",zoomFactor:o,focusPoint:r}),t.preventDefault()}else{var a=this.diagram.scroller.horizontalOffset,l=this.diagram.scroller.verticalOffset,h=i?10:-10;this.tool&&(this.tool instanceof zl||this.tool instanceof Rl)&&(this.eventArgs={},this.getMouseEventArgs(r,this.eventArgs),this.eventArgs.position=r,this.tool.mouseWheel(this.eventArgs)),this.diagram.scrollActions|=da.Interaction;var c=!0;if(t.isTrusted){var d=!1;(Math.abs(t.deltaY)<100&&-0===Math.abs(t.deltaX)||Math.abs(t.deltaX)<100&&-0===Math.abs(t.deltaY))&&(d=!0);var u=!1;(0!==t.deltaX||0!==t.deltaY)&&(u=navigator.userAgent.includes("Macintosh")),u?Math.abs(t.deltaX)>Math.abs(t.deltaY)?(t.shiftKey||t.deltaX&&-0!==t.deltaX&&(d||!u))&&this.diagram.scroller.zoom(1,h,0,r,c,void 0,d):t.deltaY&&-0!==t.deltaY&&(d||!u)&&this.diagram.scroller.zoom(1,0,h,r,c,void 0,d):t.shiftKey||t.deltaX&&-0!==t.deltaX&&(d||!u)?this.diagram.scroller.zoom(1,h,0,r,c,void 0,d):t.deltaY&&-0!==t.deltaY&&(d||!u)&&this.diagram.scroller.zoom(1,0,h,r,c,void 0,d)}else t.shiftKey||t.deltaX&&-0!==t.deltaX?this.diagram.scroller.zoom(1,h,0,r,c):this.diagram.scroller.zoom(1,0,h,r,c);this.diagram.scrollActions&=~da.Interaction,(a!==this.diagram.scroller.horizontalOffset||l!==this.diagram.scroller.verticalOffset)&&t.preventDefault()}if(this.diagram.textEditing){if(this.diagram.isTriggerEvent=!0,this.diagram.activeLabel.parentId){var p=this.diagram.getObject(this.diagram.activeLabel.parentId);this.diagram.startTextEdit(p,this.diagram.activeLabel.id)}this.diagram.isTriggerEvent=!1}this.diagram.blazorActions=this.diagram.blazorActions&~on.interaction}},n.prototype.keyDown=function(t){if(t.fromMouseEvents&&(t.ctrlKey&&(this.keyArgs.keyModifiers=1),t.shiftKey&&(this.keyArgs.keyModifiers=4),t.shiftKey&&t.ctrlKey&&(this.keyArgs.keyModifiers=5)),!(this.diagram.diagramActions&ee.TextEdit)&&!this.checkEditBoxAsTarget(t)||"Escape"===t.key||27===t.keyCode){var i=void 0,r=t.keyCode?t.keyCode:t.which,s=t.key;("ArrowDown"===s||"ArrowUp"===s||"ArrowLeft"===s||"ArrowRight"===s)&&(this.isNudgeKey=!0);var o=this.isMetaKey(t);if(this.diagram.commandManager&&this.diagram.commands)for(var l=0,h=Object.keys(this.diagram.commands);l4&&(S({keyDownEventArgs:KeyboardEvent,parameter:i.parameter,type:"KEYDOWN"}),this.keyCount=0,this.keyArgs.newValue={offsetX:this.diagram.selectedItems.offsetX,offsetY:this.diagram.selectedItems.offsetY},this.diagram.triggerEvent(Ce.positionChange,this.keyArgs))),this.isKeyUp=!1):S({keyDownEventArgs:KeyboardEvent,parameter:i.parameter})}break}}}}this.keyArgs={element:this.diagram.selectedItems,key:t.key,keyCode:t.keyCode?t.keyCode:t.which},this.getKeyModifier(this.keyArgs,t),this.diagram.diagramActions&ee.TextEdit&&this.getlabel(this.keyArgs,t),this.diagram.triggerEvent(Ce.keyDown,this.keyArgs)},n.prototype.getlabel=function(t,e){var i=this.diagram.activeLabel;t.target=this.diagram.element.id+"_editBox";var r=this.diagram.nameTable[i.parentId];if(document.getElementById(this.diagram.element.id+"_editBox")){t.text=document.getElementById(this.diagram.element.id+"_editBox").value;for(var s=0;s=this.diagram.scroller.viewPortWidth-18?r="right":e.x+this.diagram.scroller.horizontalOffsetthis.diagram.scroller.viewPortHeight-18?r="bottom":e.y+this.diagram.scroller.verticalOffset0&&(s=this.findIntersectChild(this.hoverElement)),"Auto"===this.hoverElement.tooltip.openOn&&""!==r&&Cx(this.diagram,s||(i?this.hoverElement:void 0)),this.hoverElement.tooltip.content&&("Mouse"===this.hoverElement.tooltip.relativeMode?this.setTooltipOffset(t):(this.diagram.tooltipObject.offsetX=0,this.diagram.tooltipObject.offsetY=0));var o=this.diagram.findObjectsUnderMouse(this.currentPosition),a=this.diagram.findObjectUnderMouse(o,this.action,this.inAction);if(null!==a){var l=void 0;this.hoverElement.tooltip.isSticky&&(this.diagram.tooltipObject.isSticky=!0),a instanceof te&&a.children&&a.children.length>0&&(a=s||a),l=a.ports&&(this.hoverElement instanceof Es||this.hoverElement instanceof Tc)||a.annotations&&(this.hoverElement instanceof Kn||this.hoverElement instanceof Or)?document.getElementById(a.id+"_"+this.hoverElement.id):document.getElementById(a.id+(a.shape&&a.shape instanceof lm?"_content_native_element":"_groupElement")),"Auto"===this.hoverElement.tooltip.openOn&&""!==r&&(this.diagram.tooltipObject.close(),this.diagram.tooltipObject.openOn=this.hoverElement.tooltip.openOn,this.diagram.tooltipObject.dataBind()),function Wre(n,t){var e=0;return n instanceof de?n.constraints&qe.Tooltip?e=n.constraints&qe.Tooltip:n.constraints&qe.InheritTooltip&&(e=t.constraints&nt.Tooltip):n instanceof Es||n instanceof Tc?n.constraints&ai.ToolTip?e=n.constraints&ai.ToolTip:n.constraints&ai.InheritTooltip&&(e=t.constraints&nt.Tooltip):n instanceof Kn||n instanceof Or?n.constraints&Nr.Tooltip&&(e=n.constraints&Nr.Tooltip):n.constraints&ie.Tooltip?e=n.constraints&ie.Tooltip:n.constraints&ie.InheritTooltip&&(e=t.constraints&nt.Tooltip),e}(this.hoverElement,this.diagram)&&"Auto"===this.hoverElement.tooltip.openOn&&(this.diagram.tooltipObject.target=this.hoverElement.id,this.diagram.tooltipObject.open("Mouse"===this.hoverElement.tooltip.relativeMode?this.diagram.element:l))}}},n.prototype.elementLeave=function(){this.diagram.tooltipObject&&!this.diagram.tooltipObject.isSticky&&"Custom"!==this.diagram.tooltipObject.openOn&&this.diagram.tooltipObject.close()},n.prototype.setTooltipOffset=function(t){var e=function fse(n,t,e,i){var o="Mouse"===(!(e instanceof te?e.constraints&ie.InheritTooltip:e instanceof de?e.constraints&qe.InheritTooltip:e.constraints&ai.InheritTooltip)&&(e instanceof te?e.constraints&ie.Tooltip:e instanceof de?e.constraints&qe.Tooltip:e.constraints&ai.ToolTip)?e.tooltip.relativeMode:n.tooltip.relativeMode);"Mouse"===i?o=!0:"Object"===i&&(o=!1);var a=function pse(n,t,e,i){var o,r={},s=document.getElementById(e.element.id);if(n instanceof te||n instanceof de)o=n.wrapper.bounds;else{var a=e.findObjectsUnderMouse(t),l=e.findObjectUnderMouse(a,"Select",!1);o=e.findElementUnderMouse(l,t,e).bounds}var c=s.getBoundingClientRect();switch(e.tooltipObject.position){case"BottomCenter":r=zc(t,o.bottomCenter,e,i,c.width/2,c.height);break;case"BottomLeft":case"LeftBottom":r=zc(t,o.bottomLeft,e,i,0,c.height);break;case"BottomRight":case"RightBottom":r=zc(t,o.bottomRight,e,i,c.width,c.height);break;case"LeftCenter":r=zc(t,o.middleLeft,e,i,0,c.height/2);break;case"LeftTop":case"TopLeft":r=zc(t,o.topLeft,e,i,0,0);break;case"RightCenter":r=zc(t,o.middleRight,e,i,c.width,c.height/2);break;case"RightTop":case"TopRight":r=zc(t,o.topRight,e,i,c.width,0);break;case"TopCenter":r=zc(t,o.topCenter,e,i,c.width/2,0)}return r}(e,t,n,o),l=Za(n);return{x:a.x+l.width,y:a.y+l.height}}(this.diagram,t,this.hoverElement);this.diagram.tooltipObject.offsetX=e.x,this.diagram.tooltipObject.offsetY=e.y},n.prototype.altKeyPressed=function(t){return!!(t&ft.Alt)},n.prototype.ctrlKeyPressed=function(t){return!!(t&ft.Control)},n.prototype.shiftKeyPressed=function(t){return!!(t&ft.Shift)},n.prototype.scrolled=function(t){this.diagram.updateScrollOffset()},n.prototype.isMobileOrIPadDevice=function(){var t=navigator.userAgent||navigator.vendor||window.opera;return/iPhone|iPad|iPod/.test(t)&&!window.MSStream?"iOS":/android/i.test(t)?"Android":/Mobile|Tablet/.test(t)?"Mobile":"Desktop"},n.prototype.doubleClick=function(t){if(jv(this.diagram)){var e=this.isMobileOrIPadDevice(),i=this.diagram.tool;"Desktop"!==e&&this.tool&&(this.tool instanceof zl||this.tool instanceof Rl)&&(this.diagram.tool=0);var r=void 0,s=this.diagram.findObjectsUnderMouse(this.currentPosition),o=this.diagram.findObjectUnderMouse(s,this.action,this.inAction);if(null!==o&&jv(this.diagram))if(r=this.diagram.findElementUnderMouse(o,this.currentPosition,this.diagram),this.tool&&(this.tool instanceof zl||this.tool instanceof Rl))this.diagram.tool=i,this.tool.mouseUp(this.eventArgs),this.isMouseDown=!1,this.eventArgs={},this.tool=null,t.preventDefault();else{var l=this.diagram.commandHandler.getObjectLayer(o.id);!l||l.lock||!l.visible||this.diagram.diagramActions&ee.TextEdit||this.diagram.startTextEdit(o,r instanceof li?r.id.split(o.id+"_")[1]:void 0)}this.diagram.triggerEvent(Ce.doubleClick,{source:o||this.diagram,position:this.currentPosition,count:t.detail})}},n.prototype.itemClick=function(t,e){var i=t;return Dn(this.diagram,i,!0)?i:null},n.prototype.inputChange=function(t){var i,s,o,a,l,h,c,d,u,f=document.getElementById(this.diagram.element.id+"_editBox"),p=document.getElementById(this.diagram.element.id+"_editTextBoxDiv"),g=f.value,v=g.split("\n");(!(a=this.diagram.selectedItems.nodes[0]?this.diagram.selectedItems.nodes[0]:this.diagram.selectedItems.connectors[0])&&this.tool instanceof XI||a&&"SwimLane"===a.shape.type)&&(a=this.diagram.nameTable[this.diagram.activeLabel.parentId]),a&&("Text"!==a.shape.type&&a.annotations.length>0||"Text"===a.shape.type)&&(c=NF((o=this.diagram.getWrapper(a.wrapper,this.diagram.activeLabel.id)).style,g,void 0,void 0,i=(i=a.wrapper.bounds.width90?i:90),s=Number(f.style.fontSize.split("px")[0]),v.length>1&&""===v[v.length-1]&&(c.height=c.height+s),d=this.diagram.scroller.transform,u=T3(this.diagram)?d.scale:1,l=(12>c.height?12:c.height)*u,p.style.left=(o.bounds.center.x+d.tx)*d.scale-(h=(90>(h=c.width)?90:h)*u)/2-2.5+"px",p.style.top=(o.bounds.center.y+d.ty)*d.scale-l/2-3+"px",p.style.width=h+"px",p.style.height=l+"px",f.style.minHeight="12px",f.style.minWidth="90px",f.style.width=h+"px",f.style.height=l+"px")},n.prototype.isAddTextNode=function(t,e){return!(!(this.tool instanceof XI||e)||(this.tool=null,t&&!BI(this.diagram)&&(this.diagram.drawingObject=void 0,this.diagram.currentDrawingObject=void 0),vF(this.diagram.nodes,t.id)||vF(this.diagram.connectors,t.id)))},n.prototype.checkEditBoxAsTarget=function(t){return!(!t.target||t.target.id!==this.diagram.element.id+"_editBox")},n.prototype.getMouseEventArgs=function(t,e,i,r){var s,o,a;if(e.position=t,i?(o=this.diagram.findObjectsUnderMouse(this.currentPosition,i),s=this.diagram.findTargetObjectUnderMouse(o,this.action,this.inAction,e.position,i)):"Drag"===this.action||"ConnectorSourceEnd"===this.action||"SegmentEnd"===this.action||"OrthoThumb"===this.action||"BezierSourceThumb"===this.action||"BezierTargetThumb"===this.action||"ConnectorTargetEnd"===this.action||-1!==this.action.indexOf("Rotate")||-1!==this.action.indexOf("Resize")?(s=this.diagram.selectedItems,!this.diagram.currentSymbol&&"Drag"===this.action&&s&&this.diagram.selectedItems.nodes.length>0&&"SwimLane"===this.diagram.selectedItems.nodes[0].shape.type&&(o=this.diagram.findObjectsUnderMouse(this.currentPosition),s=this.diagram.findObjectUnderMouse(o,this.action,this.inAction))):(o=this.diagram.findObjectsUnderMouse(this.currentPosition),s=this.diagram.findObjectUnderMouse(o,this.action,this.inAction)),s&&s.isHeader&&(this.eventArgs.actualObject=s=this.diagram.nameTable[s.parentId]),s){var l=void 0,h=void 0,c=void 0;if(((a=this.diagram.findElementUnderMouse(s,this.currentPosition,this.diagram,r))&&s.ports&&s.ports.length&&!ob(s,a)||!a||!s)&&o&&o.length&&i instanceof ti)for(l=i.connectors[0],c=o.length-1;c>=0;c--)if(((h=o[parseInt(c.toString(),10)])instanceof te||h instanceof de)&&l&&l.connectionPadding){if(a=this.diagram.findElementUnderMouse(s=h,this.currentPosition,this.diagram,r),l.constraints&qe.ConnectToNearByPort&&s&&s.ports&&s.ports.length&&ob(s,a))break;if((h instanceof te||h instanceof de)&&l&&l.connectionPadding&&h.wrapper.outerBounds.containsPoint(this.currentPosition)&&l.constraints&qe.ConnectToNearByNode&&!(l.constraints&qe.ConnectToNearByPort)){a=this.diagram.findElementUnderMouse(s=h,this.currentPosition,this.diagram,0);break}}}return i?(e.target=s,e.targetWrapper=a):(e.source=s,e.sourceWrapper=a),e.actualObject=this.eventArgs.actualObject,e.source instanceof ti&&void 0===e.actualObject&&(e.source.nodes.length>0||e.source.connectors.length>0)&&(e.actualObject=e.source.nodes.length>0?this.diagram.nameTable[e.source.nodes[0].id]:this.diagram.nameTable[e.source.connectors[0].id]),e.startTouches=this.touchStartList,e.moveTouches=this.touchMoveList,e},n.prototype.resetTool=function(){this.action="Select",this.hoverElement=null,this.hoverNode=null,this.tool=this.diagram.getTool(this.action),this.updateCursor()},n.prototype.updateTool=function(){this.action=this.currentPosition&&"Pan"!==this.action?"Pan":"Select"},n.prototype.getTool=function(t){switch(t){case"Select":return new Jv(this.commandHandler,!0);case"Drag":return new fa(this.commandHandler);case"Rotate":return new Gx(this.commandHandler);case"LayoutAnimation":return new One(this.commandHandler);case"FixedUserHandle":return new Nne(this.commandHandler,!0);case"Hyperlink":return new X3(this.commandHandler);case"ResizeSouthEast":case"ResizeSouthWest":case"ResizeNorthEast":case"ResizeNorthWest":case"ResizeSouth":case"ResizeNorth":case"ResizeWest":case"ResizeEast":return new Rd(this.commandHandler,t);case"ConnectorSourceEnd":case"ConnectorTargetEnd":case"BezierSourceThumb":case"BezierTargetThumb":return new zd(this.commandHandler,t);case"SegmentEnd":case"OrthoThumb":return new ZF(this.commandHandler,t);case"Draw":var e="shape",i=function ose(n){var t;return n&&(n.type?t="Connector":n.shape&&!n.type&&(t="Node")),t}(this.diagram.drawingObject);if("Node"===i&&"Text"===this.diagram.drawingObject.shape.type)return new XI(this.commandHandler);if("Connector"===i&&"Freehand"===this.diagram.drawingObject.type)return new Rne(this.commandHandler);if("Node"===i&&"Polygon"===this.diagram.drawingObject.shape[""+e]&&!this.diagram.drawingObject.shape.points)return new zl(this.commandHandler);if("Node"===i||"Node"===i&&"Polygon"===this.diagram.drawingObject.shape[""+e]&&this.diagram.drawingObject.shape.points)return new GI(this.commandHandler,this.diagram.drawingObject);if("Connector"===i&&"Polyline"===this.diagram.drawingObject.type)return new Rl(this.commandHandler);if("Connector"===i)return new pa(this.commandHandler,"ConnectorSourceEnd",this.diagram.drawingObject);break;case"Pan":return new Kv(this.commandHandler,!1);case"PinchZoom":return new Kv(this.commandHandler,!0);case"PortDrag":return new fa(this.commandHandler,"Port");case"PortDraw":return new pa(this.commandHandler,"ConnectorSourceEnd",this.diagram.drawingObject);case"LabelSelect":return new Jv(this.commandHandler,!0,"LabelSelect");case"LabelDrag":return new kne(this.commandHandler);case"LabelResizeSouthEast":case"LabelResizeSouthWest":case"LabelResizeNorthEast":case"LabelResizeNorthWest":case"LabelResizeSouth":case"LabelResizeNorth":case"LabelResizeWest":case"LabelResizeEast":return new Pne(this.commandHandler,t);case"LabelRotate":return new zne(this.commandHandler)}return null},n.prototype.getCursor=function(t){var e=this.diagram.selectedItems.annotation?this.diagram.selectedItems.wrapper.children[0]:this.diagram.selectedItems;return function Lne(n,t){if(t+=360,t%=360,-1===n.indexOf("Resize"))return Qx[""+n];var e=Qx[""+n];return t>=0&&t<25||t>=160&&t<=205||t>=340&&t<=360?e:t>=25&&t<=70||t>=205&&t<=250?"n-resize"===e||"s-resize"===e?"ne-resize":"nw-resize"===e||"se-resize"===e?"n-resize":"e-resize"===e||"w-resize"===e?"nw-resize":"e-resize":t>=70&&t<=115||t>=250&&t<=295?"n-resize"===e||"s-resize"===e?"e-resize":"nw-resize"===e||"se-resize"===e?"ne-resize":"e-resize"===e||"w-resize"===e?"n-resize":"nw-resize":t>=115&&t<=155||t>=295&&t<=340?"n-resize"===e||"s-resize"===e?"nw-resize":"nw-resize"===e||"se-resize"===e?"e-resize":"e-resize"===e||"w-resize"===e?"ne-resize":Qx[""+n]:"n-resize"}(t,this.diagram.selectedItems.annotation?e.rotateAngle+e.parentTransform:e.rotateAngle)},n.prototype.findElementUnderMouse=function(t,e,i,r){return this.objectFinder.findElementUnderSelectedItem(t,e,i,r)},n.prototype.findObjectsUnderMouse=function(t,e){return this.objectFinder.findObjectsUnderMouse(t,this.diagram,this.eventArgs,e)},n.prototype.findObjectUnderMouse=function(t,e,i){return this.objectFinder.findObjectUnderMouse(this.diagram,t,e,i,this.eventArgs,this.currentPosition)},n.prototype.findTargetUnderMouse=function(t,e,i,r,s){return this.objectFinder.findObjectUnderMouse(this.diagram,t,e,i,this.eventArgs,r,s)},n.prototype.findActionToBeDone=function(t,e,i,r){return function Cne(n,t,e,i,r,s,o){if(s&&s.length>1&&r&&r.length>1)return"PinchZoom";if(i.currentSymbol)return"Drag";if("PortDraw"===i.eventHandler.action&&(i.tool&=~ni.DrawOnce),(x3(i)||BI(i))&&i.drawingObject)return"Draw";if($a(i)&&(l=i.selectedItems).wrapper&&qr(l.constraints,"UserHandle"))for(var h=0,c=l.userHandles;h=50&&(l.x=(a.points[parseInt(h.toString(),10)].x+a.points[h+1].x)/2,l.y=(a.points[parseInt(h.toString(),10)].y+a.points[h+1].y)/2,wr(e,l,n.hitPadding?n.hitPadding:10)))return"OrthoThumb"}else PI(n)&&console.warn('[WARNING] :: Module "ConnectorEditing" is not available in Diagram component! You either misspelled the module name or forgot to load it.');return null}(g,l,e,i);if("OrthoThumb"===S)return S;if(qr(l.constraints,"ConnectorSourceThumb")&&OI(g)&&S||qr(l.constraints,"ConnectorTargetThumb")&&kI(g)&&S)return S}}else{var b=i.selectedItems.handleSize/2/i.scroller.currentZoom,M=10/i.scroller.currentZoom,w=Bi();qi(w,f.rotateAngle+f.parentTransform,f.offsetX,f.offsetY);var C=f.offsetX-f.pivot.x*f.actualSize.width,D=f.offsetY-f.pivot.y*f.actualSize.height,A={x:C+(.5===f.pivot.x?2*f.pivot.x:f.pivot.x)*f.actualSize.width/2,y:D-30/i.scroller.currentZoom};A=Ke(w,A);var x=!!i.selectedItems.annotation,P=!(!x||!zI(i.selectedItems.annotation));if(qr(l.constraints,"Rotate")&&wr(e,A,M)&&i.selectedItems.thumbsConstraints&bt.Rotate){if(x&&P)return"LabelRotate";if(!x)return"Rotate"}if(u.Inflate(b),u.containsPoint(e)&&(S=function Ene(n,t,e,i,r,s){var o;return 1===n.selectedItems.nodes.length&&0===n.selectedItems.connectors.length&&n.selectedItems.nodes[0].container&&(o=function Tne(n,t,e,i,r){var s=10/n.scroller.currentZoom,o=n.selectedItems,a=t.actualSize.width,l=t.actualSize.height,h=new Ne(i,r,t.style.strokeWidth,l),c=new Ne(i+a,r,t.style.strokeWidth,l),d=new Ne(i,r,a,t.style.strokeWidth),u=new Ne(i,r+l,a,t.style.strokeWidth),f=Dn(n,n.selectedItems.nodes[0],!0)?n.nameTable[n.selectedItems.nodes[0].parentId]:n.selectedItems.nodes[0];if(ga(o.constraints,"ResizeEast",o.thumbsConstraints,o)&&c.containsPoint(e,s))return"ResizeEast";if(ga(o.constraints,"ResizeSouth",o.thumbsConstraints,o)&&u.containsPoint(e,s))return"ResizeSouth";if("Grid"!==f.container.type){if(ga(o.constraints,"ResizeWest",o.thumbsConstraints,o)&&h.containsPoint(e,s))return"ResizeWest";if(ga(o.constraints,"ResizeNorth",o.thumbsConstraints,o)&&d.containsPoint(e,s))return"ResizeNorth"}return null}(n,t,e,r,s)),!o&&(!n.selectedItems.nodes[0]||!n.selectedItems.nodes[0].isPhase&&!n.selectedItems.nodes[0].isLane&&"SwimLane"!==n.selectedItems.nodes[0].shape.type)&&(o=function Ane(n,t,e,i,r,s){var o=40/n.scroller.currentZoom,a=n.selectedItems.handleSize/2/n.scroller.currentZoom,l=n.selectedItems,h=!!l.annotation;if(t.actualSize.width>=o&&t.actualSize.height>=o){if(ga(l.constraints,"ResizeSouthEast",l.thumbsConstraints,l)&&wr(e,Ke(i,{x:r+t.actualSize.width,y:s+t.actualSize.height}),a))return h?"LabelResizeSouthEast":"ResizeSouthEast";if(ga(l.constraints,"ResizeSouthWest",l.thumbsConstraints,l)&&wr(e,Ke(i,{x:r,y:s+t.actualSize.height}),a))return h?"LabelResizeSouthWest":"ResizeSouthWest";if(ga(l.constraints,"ResizeNorthEast",l.thumbsConstraints,l)&&wr(e,Ke(i,{x:r+t.actualSize.width,y:s}),a))return h?"LabelResizeNorthEast":"ResizeNorthEast";if(ga(l.constraints,"ResizeNorthWest",l.thumbsConstraints,l)&&wr(e,Ke(i,{x:r,y:s}),a))return h?"LabelResizeNorthWest":"ResizeNorthWest"}return ga(l.constraints,"ResizeEast",l.thumbsConstraints,l)&&wr(e,Ke(i,{x:r+t.actualSize.width,y:s+t.actualSize.height/2}),a)?h?"LabelResizeEast":"ResizeEast":ga(l.constraints,"ResizeWest",l.thumbsConstraints,l)&&wr(e,Ke(i,{x:r,y:s+t.actualSize.height/2}),a)?h?"LabelResizeWest":"ResizeWest":ga(l.constraints,"ResizeSouth",l.thumbsConstraints,l)&&wr(e,Ke(i,{x:r+t.actualSize.width/2,y:s+t.actualSize.height}),a)?h?"LabelResizeSouth":"ResizeSouth":ga(l.constraints,"ResizeNorth",l.thumbsConstraints,l)&&wr(e,Ke(i,{x:r+t.actualSize.width/2,y:s}),a)?h?"LabelResizeNorth":"ResizeNorth":null}(n,t,e,i,r,s)),o||null}(i,f,e,w,C,D),S))return S}}if(Lc(i)&&!n)return"Pan";if((o instanceof Es||o instanceof Tc)&&(!Lc(i)||_v(i)||Uv(i))&&(S=function xne(n,t,e,i){if(Fx(t)&&(va(t,Gt.Hover)||va(t,Gt.Visible))){if(t.constraints&ai.Drag)return"PortDrag"}else if(Bx(t)&&(va(t,Gt.Hover)||va(t,Gt.Visible))&&t.constraints&ai.Draw){n.drawingObject={};var r={type:"Orthogonal",sourcePortID:t.id};return n.drawingObject=r,n.tool|=ni.DrawOnce,n.currentDrawingObject=r,"PortDraw"}return"None"}(i,o),"None"!==S))return S;if((o instanceof Kn||o instanceof Or)&&!Lc(i)&&Ad(o))return _r(i,o,void 0,t)&&ro(o)?"LabelDrag":"LabelSelect";if(null!==n){if(!(n instanceof te||n instanceof de))return"Select";if(t&&t.id){var L=t.id.split(n.id)[1];if(L&&L.match("^_icon"))return"LayoutAnimation"}if(t&&t.id)for(var O=void 0,N=0;N-1)return"FixedUserHandle";if(t instanceof li&&t.hyperlink.link)return"Hyperlink";if(!ro(n)||!_r(i,n,!1)||void 0!==i.selectedItems.annotation)return n&&Lc(i)&&!FI(i)?"Pan":i.selectedItems.nodes.length&&i.selectedItems.nodes[0].isLane&&i.selectedItems.wrapper&&i.selectedItems.wrapper.bounds.containsPoint(e)?"Drag":"Select";if(n instanceof de&&!wr(e,n.sourcePoint,n.hitPadding)&&!wr(e,n.targetPoint,n.hitPadding)||!(n instanceof de))return"Drag"}return"Select"}(t,e,this.currentPosition,this.diagram,this.touchStartList,this.touchMoveList,r)},n.prototype.updateContainerBounds=function(t){var e=!1;if(this.diagram.selectedObject.helperObject&&this.diagram.selectedObject.actualObject)for(var i=this.diagram.selectedObject.actualObject,r=this.diagram.selectedObject.actualObject instanceof ti?i.nodes:[i],s=0;si.y&&(h+=u>0?-1:1,u+=u>0?-1:1):i&&e.wrapper.offsetYi.x&&(h+=u>0?-1:1,u+=u>0?-1:1):i&&e.wrapper.offsetX1)for(var S=t.offsetX-this.diagram.selectedItems.offsetX,b=t.offsetY-this.diagram.selectedItems.offsetY,M=t.rotateAngle-this.diagram.selectedItems.rotateAngle,w=0;w-1){var A=c.children;A.splice(A.indexOf(o.id),1),this.diagram.nameTable[o.id].parentId="",i=!0,c.wrapper.children.splice(D,1)}}if(function wne(n,t,e,i){var r=n,s=e.nameTable[r.parentId],o=e.nameTable[r.parentId];if(t&&o&&o.container&&"Stack"===o.container.type&&t.container&&"Stack"===t.container.type&&o.id!==t.parentId){var a=o.wrapper.children.indexOf(r.wrapper);a>-1&&(e.nameTable[r.id].parentId=t.id,o.wrapper.children.splice(a,1))}if(t&&t.parentId&&r.parentId&&"Drag"===i&&o.container&&"Stack"===o.container.type){var l=s.wrapper.children.indexOf(t.wrapper),h=s.wrapper.children.indexOf(r.wrapper),c={targetIndex:l,target:t,sourceIndex:h,source:n};s.wrapper.children.splice(h,1),s.wrapper.children.splice(l,0,r.wrapper),e.commandHandler.addHistoryEntry({type:"StackChildPositionChanged",redoObject:{targetIndex:h,target:t,sourceIndex:l,source:n},undoObject:c,category:"Internal"})}}(o,h,this.diagram,this.action),(c=Dn(this.diagram,o)?this.diagram.nameTable[o.parentId]:this.diagram.nameTable[o.parentId]||o)&&c.container&&"Canvas"===c.container.type&&(c.wrapper.maxWidth=c.maxWidth=c.wrapper.actualSize.width,c.wrapper.maxHeight=c.maxHeight=c.wrapper.actualSize.height,e=!0),Dn(this.diagram,o,!0)&&c&&"Canvas"===c.container.type)if(this.diagram.selectedItems.nodes.length>1)for(w=0;w0)for(var i=0;i0&&e.columnIndex>0||l&&e.isLane)){if("Horizontal"===t.container.orientation&&e.isPhase&&e.wrapper.width>e.maxWidth&&(e.maxWidth=e.wrapper.width,e.wrapper.maxWidth=e.wrapper.width),h.updateColumnWidth(e.columnIndex,r.width,!0,c),jx(this.diagram,e,t),e.isPhase){var p=this.diagram.nameTable[""+t.shape.phases[e.columnIndex].header.id];p.maxWidth0?(r=new sp(t,"",u),t.shape.classShape.attributes.push(r)):i.id.includes("_umlMethods")&&t.shape.classShape.methods.length>0&&(s=new cm(t,"",u),t.shape.classShape.methods.push(s))),"Interface"===t.shape.classifier&&(i.id.includes("_umlProperty")&&t.shape.interfaceShape.attributes.length>0?(r=new sp(t,"",u),t.shape.classShape.attributes.push(r)):i.id.includes("_umlMethods")&&t.shape.interfaceShape.methods.length>0&&(s=new cm(t,"",u),t.shape.interfaceShape.methods.push(s))),"Enumeration"===t.shape.classifier&&i.id.includes("_umlMember")&&t.shape.enumerationShape.members.length>0){var f=new hb(t,"",u);t.shape.enumerationShape.members.push(f)}t.wrapper.children.indexOf(c.wrapper),this.diagram.enableServerDataBinding(!0),this.diagram.add(c),this.diagram.updateConnectorEdges(t),this.diagram.clearSelection(),this.diagram.select([this.diagram.nameTable[c.id]]),this.diagram.endGroupAction(),this.diagram.startTextEdit()}}},n}(),joe=function(){function n(){}return n.prototype.findObjectsUnderMouse=function(t,e,i,r,s){var o=[];r&&r instanceof ti&&r.nodes.length+r.connectors.length===1&&(r=r.nodes[0]||r.connectors[0]).children&&0===r.children.length&&(i.actualObject=r);for(var a,l,h,c,p,d=r&&r instanceof de&&(r.constraints&qe.ConnectToNearByNode||r.constraints&qe.ConnectToNearByPort)&&r.connectionPadding||0,f={},g=0,v=e.spatialSearch.findObjects(new Ne(t.x-50-d,t.y-50-d,100+d,100+d));g-1&&o.splice(T,1),"UmlClassifier"===y.shape.type&&y.container&&"Stack"===y.container.type&&(T=o.indexOf(e.nameTable[e.nameTable[y.id].wrapper.children[0].id]))>-1&&o.splice(T,1)}for(var z=0;zs.zIndex&&(t[parseInt(r.toString(),10)]=l),r>0&&i&&a&&(a.isLane||a.isPhase||a.isHeader)&&t[parseInt(r.toString(),10)].zIndex=2)for(var d=t.length-1;d>=0;d--)if(t[parseInt(d.toString(),10)].parentId){var u=om(t[parseInt(d.toString(),10)],e,""),f=om(t[d-1],e,""),g=e.nameTable[""+f];g&&u!==f&&e.nameTable[""+u].zIndex=0;p--){d=tp(e[parseInt(p.toString(),10)],!1),c=tp(e[parseInt(p.toString(),10)],!0);var g=t[""+l].tool,v=this.findTargetElement(e[parseInt(p.toString(),10)].wrapper,o,t,void 0);if("Draw"===i&&v&&(e[parseInt(p.toString(),10)]instanceof te||e[parseInt(p.toString(),10)]instanceof de)&&!ob(e[parseInt(p.toString(),10)],v)&&(g&&"ConnectorSourceEnd"===g[""+h]&&!Ph(e[parseInt(p.toString(),10)])||g&&"ConnectorTargetEnd"===g[""+h]&&!ua(e[parseInt(p.toString(),10)])))return u;if(e[parseInt(p.toString(),10)]instanceof te||e[parseInt(p.toString(),10)]instanceof de&&(Ph(e[parseInt(p.toString(),10)])||Ld(d)||ua(e[parseInt(p.toString(),10)])||kh(c)||"PortDraw"===i&&g instanceof zd&&"ConnectorTargetEnd"===g[""+h]&&(ua(e[parseInt(p.toString(),10)])||kh(c))))return u=e[parseInt(p.toString(),10)],f&&(u=this.isTarget(u,t,i)),s.actualObject=u,u}else if("ConnectorTargetEnd"===i&&a){for(p=e.length-1;p>=0;p--)if(c=tp(e[parseInt(p.toString(),10)],!0),(e[parseInt(p.toString(),10)]instanceof te||e[parseInt(p.toString(),10)]instanceof de)&&(ua(e[parseInt(p.toString(),10)])||kh(c)))return u=e[parseInt(p.toString(),10)],u=this.isTarget(u,t,i),s.actualObject=u,u}else{if(a&&("Drag"===i||t[""+l].tool instanceof fa)){var y=0;for(p=0;p=S.zIndex?u:S,y=Math.max(y,S.zIndex)):y=(u=S).zIndex)}return u&&"Bpmn"===u.shape.type&&(t.selectedItems.nodes.length>0&&"Bpmn"===t.selectedItems.nodes[0].shape.type||(u=null)),u&&(s.actualObject=u),u}if("Select"!==i&&"Pan"!==i||!t[""+l].tool)if("Pan"===i||"LayoutAnimation"===i){for(p=e.length-1;p>=0;p--)if((e[parseInt(p.toString(),10)]instanceof te||e[parseInt(p.toString(),10)]instanceof de)&&(v=this.findTargetElement(e[parseInt(p.toString(),10)].wrapper,o,t,void 0),"Pan"===i||v&&(v.id.match("_icon_content_shape$")||v.id.match("_icon_content_rect$"))))return e[parseInt(p.toString(),10)]}else u=e[e.length-1],s&&u&&(s.actualObject=u);else{for(p=e.length-1;p>=0;p--)if(e[parseInt(p.toString(),10)]instanceof de){var b=e[p-1];if(e[p-1]instanceof te&&b.ports){if((v=this.findTargetElement(b.wrapper,o,t,void 0))&&(v.id.match("_icon_content_shape$")||v.id.match("_icon_content_rect$")))return b;for(var M=0;M=0;s--){var o=t.children[parseInt(s.toString(),10)];if(o&&o.outerBounds.containsPoint(e,r||0))if(o.visible){if(o instanceof Cs){var a=this.findTargetElement(o,e,i);if(a)return a}var l="Clip"===o.style.textOverflow||"Ellipsis"===o.style.textOverflow;if(o.bounds.containsPoint(e,r||0)&&!l)return o;if(t.bounds.containsPoint(e,r||0)&&l)return o}else if(o instanceof Ze&&t&&t.id){var h=void 0;if(t.id.includes("group_container")){var c=t.id.slice(0,-15);h=i.getObject(c)}else h=i.getObject(t.id);if(nb(h,o.id))return o}}return t.bounds.containsPoint(e,r)&&"none"!==t.style.fill?t:null},n}(),Voe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),ap=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},JF=function(n){function t(e,i,r,s){var o=n.call(this,e,i,r,s)||this;return o.objectZIndex=-1,o.zIndexTable={},o.objects=[],o}return Voe(t,n),ap([I("")],t.prototype,"id",void 0),ap([I(!0)],t.prototype,"visible",void 0),ap([I(!1)],t.prototype,"lock",void 0),ap([I()],t.prototype,"objects",void 0),ap([I()],t.prototype,"addInfo",void 0),ap([I(-1)],t.prototype,"zIndex",void 0),t}(Ee),CT=function(n,t,e,i){return new(e||(e=Promise))(function(r,s){function o(h){try{l(i.next(h))}catch(c){s(c)}}function a(h){try{l(i.throw(h))}catch(c){s(c)}}function l(h){h.done?r(h.value):new e(function(c){c(h.value)}).then(o,a)}l((i=i.apply(n,t||[])).next())})},ET=function(n,t){var i,r,s,o,e={label:0,sent:function(){if(1&s[0])throw s[1];return s[1]},trys:[],ops:[]};return o={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function a(h){return function(c){return function l(h){if(i)throw new TypeError("Generator is already executing.");for(;e;)try{if(i=1,r&&(s=2&h[0]?r.return:h[0]?r.throw||((s=r.return)&&s.call(r),0):r.next)&&!(s=s.call(r,h[1])).done)return s;switch(r=0,s&&(h=[2&h[0],s.value]),h[0]){case 0:case 1:s=h;break;case 4:return e.label++,{value:h[1],done:!1};case 5:e.label++,r=h[1],h=[0];continue;case 7:h=e.ops.pop(),e.trys.pop();continue;default:if(!(s=(s=e.trys).length>0&&s[s.length-1])&&(6===h[0]||2===h[0])){e=0;continue}if(3===h[0]&&(!s||h[1]>s[0]&&h[1]1)for(var i=0;i-1)return e[parseInt(i.toString(),10)];return this.diagram.activeLayer},n.prototype.getLayer=function(t){for(var e=this.diagram.layers,i=0;i=0;o--)this.diagram.unSelect(this.diagram.nameTable[s[parseInt(o.toString(),10)]]),this.diagram.remove(this.diagram.nameTable[s[parseInt(o.toString(),10)]]),"default_layer"!==i.id&&this.diagram.activeLayer.id===t&&(this.diagram.activeLayer=this.diagram.layers[this.diagram.layers.length-1]);delete this.diagram.layerZIndexTable[i.zIndex],this.diagram.layers.splice(r,1),"SVG"!==this.diagram.mode&&this.diagram.refreshDiagramLayer()}},n.prototype.moveObjects=function(t,e){this.diagram.startGroupAction();for(var i={},r=[],s=0;s-1){if(r=[],(h=this.diagram.nameTable[""+s]).children)for(var p=0,g=h.children;p0){for(var y=void 0,S=0,b=r;S0)for(var r=0;r0)for(r=0;r0){t=t.concat(this.diagram.selectedItems.connectors);for(var i=0;i0)for(t=t.concat(this.diagram.selectedItems.nodes),i=0;i0){for(var i=0,r=t.shape.activity.subProcess.processes;i0&&this.copyProcesses(this.processTable[""+s])}this.clipboardData.processTable=this.processTable}},n.prototype.group=function(){this.oldSelectedObjects=nm(this.diagram);var e=this.diagram.isProtectedOnChange;this.diagram.protectPropertyChange(!0),this.diagram.diagramActions=this.diagram.diagramActions|ee.Group;var r={};r.id="group"+Qe(),(r=new te(this.diagram,"nodes",r,!0)).children=[];for(var s=this.diagram.selectedItems.nodes.concat(this.diagram.selectedItems.connectors).sort(function(h,c){return h.zIndex-c.zIndex}),o=0;o0){var a=this.diagram.add(r);a&&this.select(a),this.addHistoryEntry({type:"Group",undoObject:r,redoObject:r,category:"Internal"}),this.diagram.diagramActions=this.diagram.diagramActions&~ee.Group,this.diagram.protectPropertyChange(e)}},n.prototype.unGroup=function(t){var i=this.diagram.isProtectedOnChange;this.diagram.protectPropertyChange(!0),this.diagram.diagramActions=this.diagram.diagramActions|ee.Group;var r=[];t?r.push(t):r=this.diagram.selectedItems.nodes,this.diagram.startGroupAction();for(var s=0;s0&&this.diagram.removePorts(o,o.ports),o.annotations&&o.annotations.length>0&&!ce()&&this.diagram.removeLabels(o,o.annotations);for(var c=this.diagram.nameTable[o.parentId],d=o.children.length-1;d>=0;d--)this.diagram.nameTable[o.children[parseInt(d.toString(),10)]].parentId="",this.diagram.deleteChild(this.diagram.nameTable[o.children[parseInt(d.toString(),10)]],o),o.parentId&&o.children[parseInt(d.toString(),10)]&&this.diagram.addChild(c,o.children[parseInt(d.toString(),10)]);this.resetDependentConnectors(o.inEdges,!0),this.resetDependentConnectors(o.outEdges,!1),this.diagram.diagramActions&ee.UndoRedo||this.addHistoryEntry({type:"UnGroup",undoObject:a,redoObject:a,category:"Internal"}),o.parentId&&this.diagram.deleteChild(o,c)}this.diagram.removeNode(o,l),this.clearSelection()}this.diagram.endGroupAction(),this.diagram.diagramActions=this.diagram.diagramActions&~ee.Group,this.diagram.protectPropertyChange(i)},n.prototype.resetDependentConnectors=function(t,e){for(var i=0;i0&&(g=!1)}if(g){var y=this.cloneConnector(f,i);c.push(y),o[h.id]=y.id}}else{var S=this.cloneNode(h,i);if(c.push(S),S){o[h.id]=S.id;var b=h.inEdges;if(b)for(var M=0,w=b;M0)for(var u=0;u0)for(r=t.segments,s=0;s0&&this.diagram.drawingObject&&"Bezier"===this.diagram.drawingObject.type&&(t.segments=[]);var e=this.diagram.add(t);"SVG"!==this.diagram.mode&&this.diagram.refreshDiagramLayer(),this.selectObjects([e]),t&&!BI(this.diagram)&&(this.diagram.tool&=~ni.DrawOnce,this.diagram.currentDrawingObject=void 0)},n.prototype.enableServerDataBinding=function(t){this.diagram.enableServerDataBinding(t)},n.prototype.addText=function(t,e){var i=this.diagram.findElementUnderMouse(t,e,this.diagram);this.diagram.startTextEdit(t,i instanceof li?i.id.split("_")[1]:void 0)},n.prototype.isUserHandle=function(t){var e=this.diagram.selectedItems;if(e.wrapper&&qr(e.constraints,"UserHandle"))for(var i=0,r=e.userHandles;i0&&t[0]&&t[0].isLane)for(s=this.diagram.getObject(t[0].parentId),t[0].shape.header=[],a=0;a1||e&&1===t.length)){if(1!==t.length)return[2];this.clearSelection()}if(!(u||d||1!==t.length||e&&$a(this.diagram)))return this.clearSelection(),[2]}if(!r.cancel){for(f=0;f0||e)&&p.children&&!p.parentId)for(g=0;g0||e,!0)}else this.select(p,f>0||e,!0);void 0===i&&(i=c),r={oldValue:i||[],newValue:this.getSelectedObject(),cause:this.diagram.diagramActions,state:"Changed",type:"Addition",cancel:!1},this.diagram.renderSelector(e||t&&t.length>1),ce()||this.diagram.triggerEvent(Ce.selectionChange,r),this.diagram.enableServerDataBinding(!0)}return[2]})})},n.prototype.findParent=function(t){return t.parentId&&this.findParent(t=this.diagram.nameTable[t.parentId]),t},n.prototype.selectProcesses=function(t){if(this.hasProcesses(t))for(var e=t.shape.activity.subProcess.processes,i=0;i0)},n.prototype.select=function(t,e,i){var r=this.getObjectLayer(t.id);if(Ad(t)&&!(t instanceof ti)&&!_r(this.diagram,t)&&r&&!r.lock&&r.visible&&t.wrapper.visible){(e=!!$a(this.diagram)&&e)||this.clearSelection(),this.diagram.enableServerDataBinding(!1);var s=this.diagram.selectedItems;if(t instanceof te?s.nodes.push(t.isHeader?this.diagram.nameTable[t.parentId]:t):s.connectors.push(t),s.selectedObjects.push(t),e)s.wrapper.rotateAngle=s.rotateAngle=0,s.wrapper.children.push(t.wrapper);else if(s.init(this.diagram),1===s.nodes.length&&0===s.connectors.length){var l=Vx(this.diagram,s);l&&(s.wrapper.children[0]=l),s.rotateAngle=s.nodes[0].rotateAngle,s.wrapper.rotateAngle=s.nodes[0].rotateAngle,s.wrapper.pivot=s.nodes[0].pivot}i||this.diagram.renderSelector(e),this.diagram.enableServerDataBinding(!0)}},n.prototype.labelSelect=function(t,e){this.oldSelectedObjects=nm(this.diagram);var i=this.diagram.selectedItems,r=this.diagram.allowServerDataBinding;this.diagram.allowServerDataBinding=!1,i.nodes=i.connectors=[],this.diagram.allowServerDataBinding=r,t instanceof te?i.nodes[0]=t:i.connectors[0]=t,i.annotation=this.findTarget(e,t),i.init(this.diagram),this.diagram.renderSelector(!1)},n.prototype.unSelect=function(t){var e=this.diagram.selectedItems.nodes.concat(this.diagram.selectedItems.connectors),i=e.filter(function(a){return a.id!==t.id}),r={oldValue:e,newValue:i,cause:this.diagram.diagramActions,state:"Changing",type:"Removal",cancel:!1};if(this.diagram.currentSymbol||ce()||this.diagram.triggerEvent(Ce.selectionChange,r),_r(this.diagram,t)){var s=this.diagram.selectedItems,o=void 0;t instanceof te?(o=s.nodes.indexOf(t,0),s.nodes.splice(o,1)):(o=s.connectors.indexOf(t,0),s.connectors.splice(o,1)),o=s.selectedObjects.indexOf(t,0),s.selectedObjects.splice(o,1),(r={oldValue:e,newValue:i,cause:this.diagram.diagramActions,state:"Changed",type:"Removal",cancel:(r={oldValue:e,newValue:i,cause:this.diagram.diagramActions,state:"Changed",type:"Removal",cancel:!1}).cancel}).cancel||(o=s.wrapper.children.indexOf(t.wrapper,0),s.wrapper.children.splice(o,1),this.diagram.updateSelector(),this.diagram.currentSymbol||this.diagram.triggerEvent(Ce.selectionChange,r))}},n.prototype.moveSvgNode=function(t,e){var i=this.diagram.nameTable[""+e];if("Native"===i.shape.type||"HTML"===i.shape.type)this.updateNativeNodeIndex(t,e);else{var r=xt(e+"_groupElement",this.diagram.element.id),s=xt(t+"_groupElement",this.diagram.element.id);r.parentNode.insertBefore(s,r)}},n.prototype.moveAfterSvgNode=function(t,e){var i=this.diagram.nameTable[""+e];if(!i||"HTML"!==i.shape.type&&"Native"!==i.shape.type)a=xt(e+"_groupElement",this.diagram.element.id),o=xt(t+"_groupElement",this.diagram.element.id),a.insertAdjacentElement("afterend",o);else for(var r=0;rd&&"SwimLane"!==p.shape.type){var S=$(p);p.zIndex=d-((-1!==i.indexOf(p)?i.indexOf(p):0)+1),p.children&&(d=this.findLowestZIndex(p,c)||d),this.triggerOrderCommand(S,p,p),p.children&&this.updateGroupZindex(p,"SendToBack",d)}else"SwimLane"===p.shape.type&&(y=this.swapZIndexObjects(a,h,r,g));if("SVG"===this.diagram.mode){for(var M="SwimLane"!==this.diagram.nameTable[""+r].shape.type?d:y,w=h[parseInt(M.toString(),10)];!w&&Md)&&(d=f.zIndex)}for(var p=JSON.parse(JSON.stringify(l)),v=Number(Object.keys(l).sort(function(wo,Ul){return Number(wo)-Number(Ul)}).reverse()[0]),y=this.diagram.nameTable[""+e].zIndex,S=[],M=0;M<=v;M++)S.push(l[parseInt(M.toString(),10)]);if("SwimLane"===this.diagram.nameTable[""+e].shape.type)for(var C=v;C>=y;C--)if(l[parseInt(C.toString(),10)]&&this.diagram.nameTable[l[parseInt(C.toString(),10)]].parentId!==e){v=C;break}var D=this.diagram.nameTable[""+e];if(D.zIndexx&&(x=L.zIndex)}}else x=d;D.zIndex=x+((-1!==r.indexOf(D)?r.indexOf(D):0)+1),this.triggerOrderCommand(A,D,D)}else if("SwimLane"===D.shape.type){for(var O=0,N=-1,T=0,z=0,U=JSON.parse(JSON.stringify(l)),B=0;B<=y;B++)if(l[parseInt(B.toString(),10)]&&this.diagram.nameTable[l[parseInt(B.toString(),10)]].parentId===e&&-1===N){N=B,T=B;break}for(var j=0;j<=v;j++)p[parseInt(j.toString(),10)]&&p[parseInt(j.toString(),10)]!==e&&this.diagram.nameTable[p[parseInt(j.toString(),10)]].parentId!==e&&this.diagram.nameTable[p[parseInt(j.toString(),10)]].zIndex>=this.diagram.nameTable[""+e].zIndex&&O++;for(var ue=N,fe=0;fe<=O;fe++){for(;!l[parseInt(ue.toString(),10)];)ue++;z=this.diagram.nameTable[l[parseInt(ue.toString(),10)]].zIndex,ue++}for(var Me=z;Me<=v;Me++){for(;!U[parseInt(N.toString(),10)];)N++;for(;!l[parseInt(Me.toString(),10)];)Me++;l[parseInt(Me.toString(),10)]=U[parseInt(N.toString(),10)],this.diagram.nameTable[l[parseInt(Me.toString(),10)]].zIndex=Me,N++}l[parseInt(v.toString(),10)]=this.diagram.nameTable[""+e].id,this.diagram.nameTable[""+e].zIndex=v,ue=y+1;for(var De=T,xe=0;xe0&&("Native"===hr[0].shape.type||"HTML"===hr[0].shape.type)){for(Ci.parentNode.removeChild(Ci),De=0;De0?r[0]:null},n.prototype.findLowestZIndex=function(t,e){var r=this.diagram.nodes.filter(function(s){return-1!==e.indexOf(s.id)}).filter(function(s){return""===s.parentId&&s.id!==t.id}).map(function(s){return s.zIndex});return r.sort(function(s,o){return s-o}),r.length>0?r[0]:null},n.prototype.triggerOrderCommand=function(t,e,i){var s={zIndex:$(t).zIndex},o={zIndex:e.zIndex},a={element:i,cause:this.diagram.diagramActions,diagramAction:this.diagram.getDiagramAction(this.diagram.diagramActions),oldValue:s,newValue:o};this.diagram.triggerEvent(Ce.propertyChange,a)},n.prototype.checkGroupNode=function(t,e,i){return i[""+e].parentId===i[""+t].parentId},n.prototype.sortByZIndex=function(t,e,i){if("BringForward"===i){var r=e||"zIndex";t=t.sort(function(o,a){return a[""+r]-o[""+r]})}else{var s=e||"zIndex";t=t.sort(function(o,a){return o[""+s]-a[""+s]})}return t},n.prototype.orderCommands=function(t,e,i){var r=this,s=e.nodes;if(s=s.concat(e.connectors),t)if("SendBackward"===i)for(var o=0;oa}),S=v.filter(function(D){return D0?Math.max.apply(Math,S):a,M=y.length>0?Math.min.apply(Math,y):a;if(a!==M){var w=c.zIndexTable[parseInt(M.toString(),10)],C=c.zIndexTable[parseInt(a.toString(),10)];this.moveSvgNode(C,w)}else"SendToBack"===i&&(w=c.zIndexTable[parseInt(a.toString(),10)],C=c.zIndexTable[parseInt(b.toString(),10)],this.moveAfterSvgNode(w,C))}}else this.diagram.refreshCanvasLayers()}},n.prototype.swapDomOrder=function(t,e){if(t){var i=this.diagram.getObject(e);if("Native"===i.shape.type||"HTML"===i.shape.type)this.updateNativeNodeIndex(e,t),this.updateNativeNodeIndex(t,e);else{var r=xt(e+"_groupElement",this.diagram.element.id),s=xt(t+"_groupElement",this.diagram.element.id);r.parentNode.insertBefore(r,s),r.parentNode.insertBefore(s,r)}}},n.prototype.sendForward=function(t){var e=this;if(this.diagram.protectPropertyChange(!0),$a(this.diagram)||t){$(t||(this.diagram.selectedItems.nodes.length?this.diagram.selectedItems.nodes[0]:this.diagram.selectedItems.connectors[0]));var s=t&&t.id,o=this.diagram.layers.indexOf(this.getObjectLayer(s=s||(this.diagram.selectedItems.nodes.length?this.diagram.selectedItems.nodes[0].id:this.diagram.selectedItems.connectors[0].id))),a=$(this.diagram.nameTable),h=(parseInt(o.toString(),10),this.diagram.nameTable[""+s]),c=[],d=this.diagram.spatialSearch.findObjects(h.wrapper.bounds);d.length>2&&(d=this.sortByZIndex(d,void 0,"BringForward"));for(var u=0,f=d;u=0;p--)this.diagram.nameTable[c[parseInt(p.toString(),10)].id].parentId===s&&c.splice(p,1);if(c.length>0){var y=this.diagram.nameTable[c[c.length-1].id];if(y.parentId){var b=om(y,this.diagram,""),M=this.diagram.nameTable[""+b];M.id!==s&&(c[0]=M)}var w={};for(p=0;p0&&(Object.values(O).forEach(function(ue){ue>=T&&N.push(ue)}),0!==N.length&&this.updateZIndexBySendForward(h,N,o))}var z=[];if(Object.keys(this.changedNodeZIndexes).forEach(function(ue){if((a[""+ue]?a[""+ue].zIndex:null)!==e.changedNodeZIndexes[""+ue]){var De=$(a[""+ue]);z.push(De)}}),this.updateLayerZindexTable(o),L.nodes.splice(0,L.nodes.length),z.forEach(function(ue){var fe=$(ue);L.nodes.push(fe)}),"SVG"===this.diagram.mode){var U=c[c.length-1].id,B=c[c.length-1];B&&!("HTML"===B.shape.type||"Native"===B.shape.type)&&this.moveAfterSvgNode(s,U),this.updateNativeNodeIndex(U,s)}else this.diagram.refreshCanvasLayers();var j=[];Object.keys(this.changedNodeZIndexes).forEach(function(ue){if((a[""+ue]?a[""+ue].zIndex:null)!==e.changedNodeZIndexes[""+ue]){var De=$(e.diagram.nameTable[""+ue]);j.push(De)}});var Q=$(this.diagram.selectedItems);Q.nodes.splice(0,Q.nodes.length),j.forEach(function(ue){var fe=$(ue);Q.nodes.push(fe)}),this.diagram.diagramActions&ee.UndoRedo||this.addHistoryEntry({type:"SendForward",category:"Internal",undoObject:L,redoObject:Q}),this.diagram.endGroupAction()}}this.diagram.protectPropertyChange(!1)},n.prototype.updateZIndexBySendForward=function(t,e,i){var r=$(t);t.zIndex=Math.min.apply(Math,e);var a,s=Math.min.apply(Math,e),o=Math.min.apply(Math,e),l=this.diagram.layers[parseInt(i.toString(),10)].objects,h=this.diagram.nodes.filter(function(S){return-1!==l.indexOf(S.id)});t.children&&this.updateGroupZindex(t,"BringForward",t.zIndex);var c=h.filter(function(S){return S.zIndex===Math.min.apply(Math,e)&&S.id!==t.id});if(c&&c.length>0&&c[0].children){for(var d=Math.min.apply(Math,e),u=0;uo&&g!==t&&g.parentId!==t.id&&c&&c.length>0&&g.parentId!==c[0].id){var v=$(g);g.zIndex=a+1,a++,this.triggerOrderCommand(v,g,g)}var y=g.zIndex;this.changedNodeZIndexes[g.id]=(this.changedNodeZIndexes.hasOwnProperty(g.id),y)}},n.prototype.arrangeZIndexForLowerNodes=function(t,e,i){var r=i.filter(function(o){return o.zIndex<=t&&o.parentId!==e.id});r.sort(function(o,a){return a.zIndex-o.zIndex});for(var s=0;se&&(e=r.zIndex)}return e},n.prototype.sendBackward=function(t){var e=this;if(this.diagram.protectPropertyChange(!0),$a(this.diagram)||t){$(t||(this.diagram.selectedItems.nodes.length?this.diagram.selectedItems.nodes[0]:this.diagram.selectedItems.connectors[0]));var s=t&&t.id,o=this.diagram.layers.indexOf(this.getObjectLayer(s=s||(this.diagram.selectedItems.nodes.length?this.diagram.selectedItems.nodes[0].id:this.diagram.selectedItems.connectors[0].id))),a=$(this.diagram.nameTable),h=(parseInt(o.toString(),10),this.diagram.nameTable[""+s]),c=[],d=this.diagram.spatialSearch.findObjects(h.wrapper.bounds);d.length>2&&(d=this.sortByZIndex(d));for(var u=0,f=d;uNumber(p.zIndex)&&""===p.parentId&&h.wrapper.bounds.intersects(p.wrapper.bounds)&&c.push(p);for(var p=c.length-1;p>=0;p--)(v=this.diagram.nameTable[c[parseInt(p.toString(),10)].id]).parentId===s&&c.splice(p,1);if(c.length>0){var v;if((v=this.diagram.nameTable[c[c.length-1].id]).parentId){var S=om(v,this.diagram,""),b=this.diagram.nameTable[""+S];s!==b.id&&(c[c.length-1]=b)}var M={};for(p=0;p0&&(Object.values(L).forEach(function(fe){fe<=N&&O.push(fe)}),0!==O.length&&this.updateZIndexBySendBackward(h,O,o))}var T=[];if(Object.keys(this.changedNodeZIndexes).forEach(function(fe){if((a[""+fe]?a[""+fe].zIndex:null)!==e.changedNodeZIndexes[""+fe]){var xe=$(a[""+fe]);T.push(xe)}}),this.updateLayerZindexTable(o),P.nodes.splice(0,P.nodes.length),T.forEach(function(fe){var Me=$(fe);P.nodes.push(Me)}),"SVG"===this.diagram.mode){var z=c[c.length-1].id,U=c[c.length-1];U&&"HTML"!==U.shape.type&&"Native"!==U.shape.type&&this.moveSvgNode(s,z);var B=this.diagram.nameTable[""+z];B.children&&B.children.length>0?this.updateNativeNodeIndex(s):this.updateNativeNodeIndex(s,z)}else this.diagram.refreshCanvasLayers();var j=[];Object.keys(this.changedNodeZIndexes).forEach(function(fe){if((a[""+fe]?a[""+fe].zIndex:null)!==e.changedNodeZIndexes[""+fe]){var xe=$(e.diagram.nameTable[""+fe]);j.push(xe)}});var Q=$(this.diagram.selectedItems);Q.nodes.splice(0,Q.nodes.length),j.forEach(function(fe){var Me=$(fe);Q.nodes.push(Me)}),this.diagram.diagramActions&ee.UndoRedo||this.addHistoryEntry({type:"SendBackward",category:"Internal",undoObject:P,redoObject:Q}),this.diagram.endGroupAction()}}this.diagram.protectPropertyChange(!1)},n.prototype.updateZIndexBySendBackward=function(t,e,i){var r=$(t);t.zIndex=Math.max.apply(Math,e);var f,s=t.zIndex,o=Math.max.apply(Math,e),a=this.diagram.layers[parseInt(i.toString(),10)].objects,l=this.diagram.nodes.filter(function(S){return-1!==a.indexOf(S.id)}),h=l.filter(function(S){return S.zIndex===Math.max.apply(Math,e)&&S.id!==t.id});if(h&&h.length>0&&h[0].children)for(var c=Math.max.apply(Math,e),d=0;d0&&g.parentId!==h[0].id){var v=$(g);g.zIndex=f-1,f--,this.triggerOrderCommand(v,g,g)}var y=g.zIndex;this.changedNodeZIndexes[""+g.id]=(this.changedNodeZIndexes.hasOwnProperty(g.id),y)}},n.prototype.findLowestChildZIndex=function(t){for(var e=t.zIndex,i=0;i0),this.selectObjects([t],!0))},n.prototype.clearSelection=function(t,e){return CT(this,void 0,void 0,function(){var i,r,s,o;return ET(this,function(a){return i=this.diagram.allowServerDataBinding,this.diagram.enableServerDataBinding(!1),$a(this.diagram)&&(r=this.diagram.selectedItems,s=this.getSelectedObject(),this.diagram.currentSymbol&&(this.diagram.previousSelectedObject=s),o={oldValue:s,newValue:[],cause:this.diagram.diagramActions,state:"Changing",type:"Removal",cancel:!1},t&&(ce()||this.diagram.triggerEvent(Ce.selectionChange,o)),o.cancel||(r.offsetX=0,r.offsetY=0,r.width=0,r.height=0,r.rotateAngle=0,r.nodes=[],r.connectors=[],r.wrapper=null,r.annotation=void 0,r.selectedObjects=[],this.diagram.clearSelectorLayer(),t&&(o={oldValue:s,newValue:[],cause:this.diagram.diagramActions,state:"Changed",type:"Removal",cancel:!1},ce()||this.diagram.triggerEvent(Ce.selectionChange,o))),this.diagram.enableServerDataBinding(i)),[2]})})},n.prototype.clearSelectedItems=function(){this.clearSelection((this.diagram.selectedItems.nodes?this.diagram.selectedItems.nodes.length:0)+(this.diagram.selectedItems.connectors?this.diagram.selectedItems.connectors.length:0)>0)},n.prototype.removeStackHighlighter=function(){var t=Bl(this.diagram.element.id),e=t.getElementById(t.id+"_stack_highlighter");e&&e.parentNode.removeChild(e)},n.prototype.renderStackHighlighter=function(t,e){var r,s,o,i=this.diagram.selectedItems.nodes[0];if(!e){var a=this.diagram.findObjectsUnderMouse(t.position);if((e=this.diagram.findObjectUnderMouse(a,"Drag",!0))&&!(e.isLane||e.isPhase||e.isHeader))for(var l=0;l0)for(var a=0;a1)if(i){var h=l.segments[0],c=l.segments[1],u=Nl(xI(t.wrapper,t.wrapper.corners,t.wrapper.bounds),h.direction),g=Ol({corners:void 0,point:u=qa(l,0,u,{x:l.sourceWrapper.offsetX,y:l.sourceWrapper.offsetY},!1),margin:void 0,direction:h.direction},{corners:void 0,point:c.points[1],margin:void 0,direction:void 0});h.length=R.distancePoints(g[0],g[1]),c.direction&&c.length&&(c.length=R.distancePoints(g[1],g[2]))}else if(o){switch(l.segments[0].direction){case"Bottom":r=t.wrapper.bounds.bottomCenter.x-e.bottomCenter.x,s=t.wrapper.bounds.bottomCenter.y-e.bottomCenter.y;break;case"Top":r=t.wrapper.bounds.topCenter.x-e.topCenter.x,s=t.wrapper.bounds.topCenter.y-e.topCenter.y;break;case"Left":r=t.wrapper.bounds.middleLeft.x-e.middleLeft.x,s=t.wrapper.bounds.middleLeft.y-e.middleLeft.y;break;case"Right":r=t.wrapper.bounds.middleRight.x-e.middleRight.x,s=t.wrapper.bounds.middleRight.y-e.middleRight.y}this.dragSourceEnd(l,r,s,!0,null,"ConnectorSourceEnd",void 0,void 0,void 0,!(t.parentId&&this.diagram.diagramActions&ee.isGroupDragging))}}},n.prototype.updateEndPoint=function(t,e){var r={sourcePoint:t.sourcePoint,targetPoint:t.targetPoint};t.sourceID&&(r.sourceID=t.sourceID),t.targetID&&(r.targetID=t.targetID),t.sourcePortID&&(r.sourcePortID=t.sourcePortID),t.targetPortID&&(r.targetPortID=t.targetPortID),t.segments&&(r.segments=t.segments),this.diagram.connectorPropertyChange(t,e||{},r),this.diagram.updateSelector()},n.prototype.dragSourceEnd=function(t,e,i,r,s,o,a,l,h,c,d){var u=this.diagram.nameTable[t.id],f={},p=this.checkBoundaryConstraints(e,i,u.wrapper.bounds);if(OI(u)&&p&&"BezierSourceThumb"!==o&&Vv(this.diagram)&&(f=$(f={sourcePoint:u.sourcePoint}),u.sourcePoint.x+=e,u.sourcePoint.y+=i,"ConnectorSourceEnd"===o&&"Orthogonal"===u.type&&this.changeSegmentLength(u,l,h,c),"Bpmn"===u.shape.type&&"Default"===u.shape.sequence&&"Sequence"===u.shape.flow&&this.updatePathElementOffset(u)),"Bezier"===u.type)if(f={sourcePoint:u.sourcePoint},d)this.translateBezierPoints(t,""===o?"ConnectorSourceEnd":o,e,i,d,s,!a);else for(var g=0;g2){var d=R.direction((c=t.segments[2]).points[0],c.points[1]);o.direction===_n(d)?("Right"===o.direction?c.points[0].x=o.points[o.points.length-1].x=l.wrapper.corners.middleRight.x+20:"Left"===o.direction?c.points[0].x=o.points[o.points.length-1].x=l.wrapper.corners.middleLeft.x-20:c.points[0].y=o.points[o.points.length-1].y="Top"===o.direction?l.wrapper.corners.topCenter.y-20:l.wrapper.corners.bottomCenter.y+20,c.direction&&c.length&&(c.length=R.distancePoints(c.points[0],c.points[c.points.length-1])),o.length=R.distancePoints(o.points[0],o.points[o.points.length-1])):o.direction===d&&c.direction&&c.length?("Top"===o.direction||"Bottom"===o.direction?(c.points[0]=o.points[0],c.points[c.points.length-1].x=c.points[0].x):(c.points[0]=o.points[0],c.points[c.points.length-1].y=c.points[0].y),c.length=R.distancePoints(c.points[0],c.points[c.points.length-1]),t.segments.splice(0,2)):o.length=20}else o.length=20;else if(o.length<1)if(""!==t.sourceID){var c;"Right"===a.direction?a.points[a.points.length-1].y=(h=l.wrapper.corners.middleRight).y:"Left"===a.direction?a.points[a.points.length-1].y=(h=l.wrapper.corners.middleLeft).y:a.points[a.points.length-1].x="Top"===a.direction?(h=l.wrapper.corners.topCenter).x:(h=l.wrapper.corners.bottomCenter).x,a.length=R.distancePoints(h,a.points[a.points.length-1]),t.segments.length>2&&(c=t.segments[2]).direction&&c.length&&(c.length=R.distancePoints(a.points[a.points.length-1],c.points[c.points.length-1])),t.segments.splice(0,1)}else t.segments.splice(0,1)}else e&&!i&&t.sourceID!==e.id&&t.segments&&null!==t.segments[0].direction&&e&&e instanceof te&&s&&this.changeSourceEndToNode(t,e),e&&i&&t.sourcePortID!==i&&t.segments&&null!==t.segments[0].direction&&e&&e instanceof te&&s&&this.changeSourceEndToPort(t,e,i)},n.prototype.canConnect=function(t,e){return!(!ua(e)||!Ph(e))},n.prototype.changeSourceEndToPort=function(t,e,i){var r=this.diagram.getWrapper(e.wrapper,i),s={x:r.offsetX,y:r.offsetY},o=zo(s,xn(e.wrapper),e.wrapper.bounds),a=t.segments[0],l=t.segments[1];if(a.direction!==o){var h=[],c={};if(a.direction===_n(o)){c={};var d=void 0;"Top"===o||"Bottom"===o?(d="Top"===o?{type:"Orthogonal",isTerminal:!0,direction:o,length:Math.abs(a.points[0].y-s.y)}:{type:"Orthogonal",isTerminal:!0,direction:o,length:Math.abs(s.y-a.points[0].y)},c=a.points[0].x>s.x?{type:"Orthogonal",isTerminal:!0,direction:"Right",length:a.points[0].x-s.x}:{type:"Orthogonal",isTerminal:!0,direction:"Left",length:s.x-a.points[0].x}):(d="Right"===o?{type:"Orthogonal",isTerminal:!0,direction:o,length:Math.abs(a.points[0].x-s.x)}:{type:"Orthogonal",isTerminal:!0,direction:o,length:Math.abs(s.x-a.points[0].x)},c=a.points[0].y>s.y?{type:"Orthogonal",direction:"Top",isTerminal:!0,length:a.points[0].y-s.y}:{type:"Orthogonal",direction:"Bottom",isTerminal:!0,length:s.y-a.points[0].y}),h.push(new wi(t,"segments",d,!0)),h.push(new wi(t,"segments",c,!0))}else h.push(new wi(t,"segments",c={type:"Orthogonal",direction:o,length:20,isTerminal:!0},!0));a.direction!==_n(o)&&("Top"===o||"Bottom"===o?(a.points[0].x=s.x,a.points[0].y=a.points[a.points.length-1].y="Top"===o?s.y-20:s.y+20):(a.points[0].y=s.y,a.points[0].x=a.points[a.points.length-1].x="Right"===o?s.x+20:s.x-20),a.length=R.distancePoints(a.points[0],a.points[a.points.length-1]),l.length=R.distancePoints(a.points[a.points.length-1],l.points[l.points.length-1])),t.segments=h.concat(t.segments)}else a.points[0]=s,"Top"===o||"Bottom"===o?a.points[a.points.length-1].x=s.x:a.points[a.points.length-1].y=s.y,a.length=R.distancePoints(a.points[0],a.points[a.points.length-1]),l.length=R.distancePoints(a.points[a.points.length-1],l.points[l.points.length-1])},n.prototype.removeTerminalSegment=function(t,e){for(var i=0;ii.width||"Left"===o.direction&&r.x>=o.points[0].x||"Right"===o.direction&&r.x<=o.points[0].x)o.points[0].y=o.points[o.points.length-1].y=r.y,o.points[0].x=r.x,o.length=R.distancePoints(o.points[0],o.points[o.points.length-1]),a.length=R.distancePoints(o.points[o.points.length-1],a.points[a.points.length-1]);else{var h=void 0;s="Bottom"===(h=a.direction?a.direction:R.direction(a.points[0],a.points[a.points.length-1]))?i.bottomCenter:i.topCenter,a.length&&a.direction&&(a.length="Top"===h?o.points[o.points.length-1].y-(s.y+20):s.y+20-o.points[o.points.length-1].y),o.length=o.points[o.points.length-1].x-s.x,o.direction=o.length>0?"Right":"Left",l.push(new wi(t,"segments",{type:"Orthogonal",direction:h,length:20},!0)),t.segments=l.concat(t.segments)}else r="Bottom"===o.direction?i.bottomCenter:i.topCenter,o.length>i.height||"Top"===o.direction&&r.y>=o.points[0].y||"Bottom"===o.direction&&r.y<=o.points[0].y?(o.points[0].x=o.points[o.points.length-1].x=r.x,o.points[0].y=r.y,o.length=R.distancePoints(o.points[0],o.points[o.points.length-1]),a.length=R.distancePoints(o.points[o.points.length-1],a.points[a.points.length-1])):(s="Left"===a.direction?i.middleLeft:i.middleRight,h=void 0,h=a.direction?a.direction:R.direction(a.points[0],a.points[a.points.length-1]),a.length&&a.direction&&(a.length="Left"===h?o.points[o.points.length-1].x-(s.x+20):s.x+20-o.points[o.points.length-1].x),o.length=o.points[o.points.length-1].y-s.y,o.direction=o.length>0?"Bottom":"Top",l.push(new wi(t,"segments",{type:"Orthogonal",direction:h,length:20},!0)),t.segments=l.concat(t.segments))},n.prototype.translateBezierPoints=function(t,e,i,r,s,o,a){var l=t.segments.indexOf(s),h=t.segments[parseInt(l.toString(),10)],c=l>0?t.segments[l-1]:null,d=null!==c?c.point:t.sourcePoint,u=l===t.segments.length-1?t.targetPoint:h.point;if(h)if("BezierSourceThumb"===e&&(h.vector1.angle||h.vector1.distance)){var f=h.vector1.distance,p=h.vector1.angle;h.vector1={distance:t.distance(d,o),angle:R.findAngle(d,o)},this.translateSubsequentSegment(t,s,!0,h.vector1.distance-f,h.vector1.angle-p)}else"BezierTargetThumb"===e&&(h.vector2.angle||h.vector2.distance)?(f=h.vector2.distance,p=h.vector2.angle,h.vector2={distance:t.distance(u,o),angle:R.findAngle(u,o)},this.translateSubsequentSegment(t,s,!1,h.vector2.distance-f,h.vector2.angle-p)):("ConnectorSourceEnd"===e&&!t.sourceID||"ConnectorTargetEnd"===e&&!t.targetID)&&a&&$I(h.vector1)&&$I(h.vector2)?(R.isEmptyPoint(h.point1)&&(h.bezierPoint1=ZI(t.sourcePoint,t.targetPoint)),R.isEmptyPoint(h.point2)&&(h.bezierPoint2=ZI(t.targetPoint,t.sourcePoint))):"BezierSourceThumb"===e||"ConnectorSourceEnd"===e&&!a&&$I(h.vector1)?(h.bezierPoint1.x+=i,h.bezierPoint1.y+=r,(!R.isEmptyPoint(h.point1)||a)&&(h.point1={x:h.bezierPoint1.x,y:h.bezierPoint1.y})):("BezierTargetThumb"===e||"ConnectorTargetEnd"===e&&!a&&$I(h.vector2))&&(h.bezierPoint2.x+=i,h.bezierPoint2.y+=r,(!R.isEmptyPoint(h.point2)||a)&&(h.point2={x:h.bezierPoint2.x,y:h.bezierPoint2.y}))},n.prototype.translateSubsequentSegment=function(t,e,i,r,s){var o=t.segments.indexOf(e);parseInt(o.toString(),10),t.bezierSettings.smoothness&MI.SymmetricAngle||(s=null),t.bezierSettings.smoothness&MI.SymmetricDistance||(r=null),(null!=r||null!=s)&&(i?0!==o&&this.updatePreviousBezierSegment(t,o,r,s):o!==t.segments.length-1&&this.updateNextBezierSegment(t,o,r,s))},n.prototype.updatePreviousBezierSegment=function(t,e,i,r){var s=t.segments[e-1],a=(s.vector2.angle+r)%360;a<0&&(a+=360),s.vector2={distance:s.vector2.distance+i,angle:a}},n.prototype.updateNextBezierSegment=function(t,e,i,r){var s=t.segments[e+1],a=(s.vector1.angle+r)%360;a<0&&(a+=360),s.vector1={distance:s.vector1.distance+i,angle:a}},n.prototype.dragTargetEnd=function(t,e,i,r,s,o,a,l){var c,h=this.diagram.nameTable[t.id],d=this.checkBoundaryConstraints(e,i,h.wrapper.bounds);if(kI(h)&&"BezierTargetThumb"!==o&&d&&Vv(this.diagram)){if(c=$(c={targetPoint:h.targetPoint}),h.targetPoint.x+=e,h.targetPoint.y+=i,"ConnectorTargetEnd"===o&&"Orthogonal"===h.type&&h.segments&&h.segments.length>0){var u=h.segments[h.segments.length-2];u&&2===h.segments[h.segments.length-1].points.length&&("Left"===u.direction||"Right"===u.direction?u.points[u.points.length-1].x=h.targetPoint.x:u.points[u.points.length-1].y=h.targetPoint.y,u.length=R.distancePoints(u.points[0],u.points[u.points.length-1]),u.direction=R.direction(u.points[0],u.points[u.points.length-1]))}"Bpmn"===h.shape.type&&"Default"===h.shape.sequence&&"Sequence"===h.shape.flow&&this.updatePathElementOffset(h)}if("Bezier"===h.type)if(c={targetPoint:h.targetPoint},l)this.translateBezierPoints(t,""===o?"ConnectorTargetEnd":o,e,i,l,s,!a);else for(var f=0;f0){if(void 0!==s&&o.segments[parseInt(s.toString(),10)])if("Bezier"===o.type){var a=o.segments[parseInt(s.toString(),10)],l=a.isInternalSegment;l&&null!==o.bezierSettings&&"FreeForm"!==o.bezierSettings.segmentEditOrientation?("Horizontal"===a.orientation?a.point.x+=e:a.point.y+=i,this.updateDirectionalBezierCurve(o)):(a.point.x+=e,a.point.y+=i),l&&(o.isBezierEditing=!0)}else o.segments[parseInt(s.toString(),10)].point.x+=e,o.segments[parseInt(s.toString(),10)].point.y+=i;else for(var h=0;h1){var a=e[1],l=e[2],h={x:.5*(a.x+l.x),y:.5*(a.y+l.y)},c=t.segments[0];c.vector1.angle=Xt(s,a),c.vector1.distance=.5*R.findLength(s,a),c.vector2.angle=Xt(h,a),c.vector2.distance=.5*R.findLength(h,a),c.point=h;var d=t.segments[1];if(d.vector1.angle=Xt(h,l),d.vector1.distance=.5*R.findLength(h,l),t.segments.length>2){var u=e[3],f={x:.5*(l.x+u.x),y:.5*(l.y+u.y)};d.vector2.angle=Xt(f,l),d.vector2.distance=.5*R.findLength(f,l),d.point=f;var p=t.segments[2];if(p.vector1.angle=Xt(f,u),p.vector1.distance=.5*R.findLength(f,u),t.segments.length>3){var g=e[4],v={x:.5*(u.x+g.x),y:.5*(u.y+g.y)};p.vector2.angle=Xt(v,u),p.vector2.distance=.5*R.findLength(v,u),p.point=v;var y=t.segments[3];y.vector1.angle=Xt(v,g),y.vector1.distance=.5*R.findLength(v,g),y.vector2.angle=Xt(o,g),y.vector2.distance=.5*R.findLength(o,g)}else p.vector2.angle=Xt(o,u),p.vector2.distance=.5*R.findLength(o,u)}else d.vector2.angle=Xt(o,l),d.vector2.distance=.5*R.findLength(o,l)}},n.prototype.rotateObjects=function(t,e,i,r,s){r=r||{};var o=Bi();qi(o,i,r.x,r.y);for(var l=0,h=e;l0){this.diagram.protectPropertyChange(!0);var o=t;o.segments=[],this.diagram.connectorPropertyChange(o,{},{segments:o.segments}),this.diagram.protectPropertyChange(!1)}}},n.prototype.updateInnerParentProperties=function(t){var r=this.diagram.isProtectedOnChange;this.diagram.protectPropertyChange(!0);for(var s=this.getAllDescendants(t,[],!1,!0),o=0;o0&&(f=this.diagram.bpmnModule.getChildrenBound(d,d.id,this.diagram),u=d.wrapper.bounds.containsRect(f)),h=d.wrapper.actualSize.width*t,c=d.wrapper.actualSize.height*e,void 0!==d.maxWidth&&0!==d.maxWidth&&(h=Math.min(d.maxWidth,h)),void 0!==d.minWidth&&0!==d.minWidth&&(h=Math.max(d.minWidth,h)),void 0!==d.maxHeight&&0!==d.maxHeight&&(c=Math.min(d.maxHeight,c)),void 0!==d.minHeight&&0!==d.minHeight&&(c=Math.max(d.minHeight,c)),u&&(h=Math.max(h,f.right-d.wrapper.bounds.x),c=Math.max(c,f.bottom-d.wrapper.bounds.y)),t=h/d.actualSize.width,e=c/d.actualSize.height}var p=Bi();o||(o=r);var g=o.wrapper;if(qi(p,-g.rotateAngle,i.x,i.y),Gf(p,t,e,i.x,i.y),qi(p,g.rotateAngle,i.x,i.y),r instanceof te){var d,v=Ke(p,{x:(d=r).wrapper.offsetX,y:d.wrapper.offsetY}),y=d.wrapper.offsetX-d.wrapper.actualSize.width*d.pivot.x,S=d.wrapper.offsetY-d.wrapper.actualSize.height*d.pivot.y;if(h>0)if(d.processId){var b=this.diagram.nameTable[d.processId];(!b.maxWidth||d.margin.left+h0)if(d.processId){var M=this.diagram.nameTable[d.processId];(!M.maxHeight||d.margin.top+c0){if(e.dragLimit=e.dragLimit?e.dragLimit:{},e.dragLimit.top||e.dragLimit.bottom||e.dragLimit.left||e.dragLimit.right){var b={minDistance:null};S=this.getRelativeOffset(v,d,b);var M={minDistance:null};g=this.getRelativeOffset(v,y,M),S=null!=b&&M.minDistance0){if(S=y[y.length-1]){var b=void 0;for(b=0;b=e.x-t.dragLimit.left-r.width/2&&i.x<=e.x+t.dragLimit.right+r.width/2&&(s=!0),i.y>=e.y-t.dragLimit.top-r.height/2&&i.y<=e.y+t.dragLimit.bottom+r.height/2&&(o=!0),{x:s,y:o}},n.prototype.updateLabelMargin=function(t,e,i,r,s,o,a){if(i=i||{x:e.offset,y:0},e&&i&&i.x>0&&i.x<1){var l=R.getLengthFromListOfPoints(t.intermediatePoints),h=this.getPointAtLength(l*i.x,t.intermediatePoints,0),c=this.diagram.scrollSettings.currentZoom,d=e.dragLimit?e.dragLimit:{left:0,right:0,top:0,bottom:0};if(d.top||d.bottom||d.left||d.right){this.diagram.getWrapper(t.wrapper,e.id);var f=new Ne(0,0,0,0),p=this.diagram.getWrapper(t.wrapper,e.id);f.x=p.offsetX/c+o,f.y=p.offsetY/c+a,f.width=p.bounds.width/c,f.height=p.bounds.height/c;var g=new Ne(h.x-(d.left||0)-f.width/2,h.y-(d.top||0)-f.height/2,(d.left||0)+(d.right||0)+f.width,(d.top||0)+(d.bottom||0)+f.height);if(g.containsPoint(r));else for(var S=0,b=this.boundsInterSects([h,r],g,!1);S=t){c=t-r,d=R.findAngle(s,a),u=c*Math.cos(d*Math.PI/180),f=c*Math.sin(d*Math.PI/180),o={x:s.x+u,y:s.y+f};break}r+=h,s=a}else s=a;return o},n.prototype.getInterceptWithSegment=function(t,e){for(var o,a,i=[],r=[],s=[],l=R.findLength({x:0,y:0},{x:this.diagram.scroller.viewPortWidth,y:this.diagram.scroller.viewPortHeight}),h=1;h0&&a<=90||a>180&&a<=270?90:-90;r.push(R.transform(t,a+c,l)),r.push(R.transform(t,o+c,l));var f=tm({x1:s[0].x,y1:s[0].y,x2:s[1].x,y2:s[1].y},{x1:r[0].x,y1:r[0].y,x2:r[1].x,y2:r[1].y});f.enabled&&i.push(f.intersectPt)}return i},n.prototype.getAnnotationChanges=function(t,e){var r={};return r[sb(t,e.id,!0)]={width:e.width,height:e.height,offset:t instanceof te?{x:e.offset.x,y:e.offset.y}:e.offset,rotateAngle:e.rotateAngle,margin:{left:e.margin.left,right:e.margin.right,top:e.margin.top,bottom:e.margin.bottom},horizontalAlignment:e.horizontalAlignment,verticalAlignment:e.verticalAlignment,alignment:t instanceof de?e.alignment:void 0},{annotations:r}},n.prototype.getConnectorPortChanges=function(t,e){var i=function zse(n,t,e){for(var i=n.ports,r=0;r1&&(v.width=g,v.offset.x=1/S),p>1&&(v.height=p,v.offset.y=1/b)}}e instanceof Or&&(e.alignment="Center"),l=this.getAnnotationChanges(t,e),t instanceof te?this.diagram.nodePropertyChange(t,a,l):this.diagram.connectorPropertyChange(t,a,l),this.diagram.updateDiagramObject(t)},n.prototype.getSubProcess=function(t){var i,e={nodes:[],connectors:[]};return t instanceof te?i=t.processId:t&&t.nodes&&t.nodes.length&&t.nodes[0].processId&&(i=t.nodes[0].processId),i&&e.nodes.push($(this.diagram.nameTable[i])),e},n.prototype.checkBoundaryConstraints=function(t,e,i,r){var s=this.diagram.pageSettings,o=this.diagram.pageSettings.boundaryConstraints,a=this.diagram.scroller;if("Page"===o||"Diagram"===o){var l=i?void 0:this.diagram.selectedItems.wrapper.bounds;return!!((i?i.right:l.right)+(t||0)<=("Page"===o?s.width:a.viewPortWidth)&&(i?i.left:l.left)+(t||0)>=0&&(i?i.bottom:l.bottom)+(e||0)<=("Page"===o?s.height:a.viewPortHeight)&&(i?i.top:l.top)+(e||0)>=0||"None"!==this.diagram.layout.type&&r)}return!0},n.prototype.dragSelectedObjects=function(t,e){var i=this,r=this.diagram.selectedItems;this.state&&!this.state.backup&&(this.state.backup={},this.state.backup.offsetX=r.offsetX,this.state.backup.offsetY=r.offsetY),r=QI(this.diagram,r)||r;var s=this.diagram.selectedItems.nodes.filter(function(c){return"SwimLane"===c.shape.type});if(s.length>0&&!this.diagram.currentSymbol&&this.diagram.selectedItems.nodes.length>1){var o=this.diagram.selectedItems.nodes.filter(function(c){return""===c.parentId||"SwimLane"!==i.diagram.nameTable[c.parentId].shape.type});if(o.length>0){for(var a=0;a0||l.length>1)&&(o=o.concat(l),this.diagram.selectedItems.nodes.splice(0,this.diagram.selectedItems.nodes.length),o.forEach(function(c){i.diagram.selectedItems.nodes.push(c)}),r=this.diagram.selectedItems,this.diagram.selectedObject.helperObject=void 0)}}if(this.checkBoundaryConstraints(t,e)){this.diagram.diagramActions=this.diagram.diagramActions|ee.PreventZIndexOnDragging|ee.DragUsingMouse;var h=this.diagram.selectedObject.actualObject;return(h&&h instanceof te&&h.isLane&&Yx(h,this.diagram)||!h||!h.isLane)&&this.diagram.drag(r,t,e),this.diagram.diagramActions=this.diagram.diagramActions&~(ee.PreventZIndexOnDragging|ee.DragUsingMouse),this.diagram.refreshCanvasLayers(),this.checkHtmlObjectDrag(r),!0}return!1},n.prototype.checkHtmlObjectDrag=function(t){var e=!1;this.diagram.views&&this.diagram.views.length>1&&(t instanceof ti?e=t.nodes.some(function(i){return i.shape&&"HTML"===i.shape.type}):t.shape&&"HTML"===t.shape.type&&(e=!0),e&&this.resetOverviewCanvas())},n.prototype.resetOverviewCanvas=function(){for(var t=0,e=this.diagram.views;t0&&(this.layoutAnimateModule.stopCurrentAnimation(this.objectStore[0],e,t),this.objectStore=[]),a=this.diagram.doLayout(),this.objectStore.push(a)),this.canUpdateTemplate=!1,this.diagram.blazorActions&=~on.expandNode,this.diagram.preventNodesUpdate=r,this.diagram.layoutAnimateModule&&this.diagram.organizationalChartModule&&!i)this.diagram.allowServerDataBinding=!1,this.layoutAnimateModule.expand(this.diagram.layout.enableAnimation,a,t,this.diagram);else{var l={element:$(t),state:!!t.isExpanded};this.triggerEvent(Ce.expandStateChange,l),this.diagram.lineRoutingModule&&this.diagram.constraints&nt.LineRouting&&"ComplexHierarchicalTree"!==this.diagram.layout.type&&this.diagram.resetSegments()}return this.diagram.layout.fixedNode=""===o?"":this.diagram.layout.fixedNode,a},n.prototype.getparentexpand=function(t,e,i,r){for(var s,o=0;o0&&(this.diagram.selectedItems.wrapper.rotateAngle=this.diagram.selectedItems.rotateAngle=s.rotateAngle),!(r instanceof te&&"SwimLane"!==r.shape.type)||r.isLane||r.isPhase||r.isHeader||Dn(this.diagram,r)){if(r instanceof ti)for(var d=0;d30||g.wrapper.outerBounds.topCenter.y-p.wrapper.outerBounds.bottomCenter.y>30)&&this.diagram.lineRoutingModule.refreshConnectorSegments(this.diagram,f,!0)}}this.updateSelector(),this.diagram.protectPropertyChange(!1)}},n.prototype.drawSelectionRectangle=function(t,e,i,r){this.diagram.drawSelectionRectangle(t,e,i,r)},n.prototype.startGroupAction=function(){this.diagram.startGroupAction()},n.prototype.endGroupAction=function(){this.diagram.endGroupAction()},n.prototype.removeChildFromBPmn=function(t,e,i){var r=this.diagram.nameTable[t.id]||t.nodes[0];if(i&&r&&r.processId&&r.processId===i.wrapper.id){var s=$(r);s.processId=r.processId,this.diagram.startGroupAction();var o=this.diagram.nameTable[r.processId].shape.activity.subProcess.processes||[];o.splice(o.indexOf(r.id),1),this.diagram.bpmnModule.removeChildFromBPMN(this.diagram.nameTable[r.processId].wrapper,r.id,this.diagram),this.diagram.nameTable[r.id].processId="",r.offsetX=r.wrapper.offsetX,r.offsetY=r.wrapper.offsetY;var a=$(r);this.addHistoryEntry({type:"PositionChanged",redoObject:{nodes:[a]},undoObject:{nodes:[s]},category:"Internal"}),this.diagram.endGroupAction()}},n.prototype.isDroppable=function(t,e){var i=this.diagram.nameTable[t.id]||t.nodes[0];return i instanceof te&&(!ce()&&"TextAnnotation"===i.shape.shape||("Group"===e.shape.shape&&(e.shape.activity.subProcess.collapsed=!1),!(i&&"Bpmn"===i.shape.type&&(i.processId===e.id||i.id===e.processId||"Bpmn"===e.shape.type&&!(e instanceof de)&&e.shape.activity&&e.shape.activity.subProcess&&e.shape.activity.subProcess.collapsed))))},n.prototype.renderHighlighter=function(t,e,i){if(new Ne,t.target instanceof te||t.target instanceof de||e&&(t.source instanceof te||t.source instanceof de)){var a=this.findTarget(e?t.sourceWrapper:t.targetWrapper,e?t.source:t.target,i,!0),l=void 0;if(a instanceof Bd)for(var h=a.id,c=t.target,u=0,f=c.wrapper.children[0].children[0].children[2].children;u0){var r=0;t[0]=this.diagram.nameTable[t[0].id]||t[0];var s="Object"===i?yr(t[0].wrapper):this.diagram.selectedItems.wrapper.bounds,o={nodes:[],connectors:[]},a={nodes:[],connectors:[]};for(r="Object"===i?r+1:r;r0){var i=0,r=0,s=0,o=0,a=0,l=0,h=0,c=0,d={nodes:[],connectors:[]},u={nodes:[],connectors:[]};for(i=0;io.center.y&&(r=n[parseInt(e.toString(),10)],n[parseInt(e.toString(),10)]=n[parseInt(i.toString(),10)],n[parseInt(i.toString(),10)]=r):s.center.x>o.center.x&&(r=n[parseInt(e.toString(),10)],n[parseInt(e.toString(),10)]=n[parseInt(i.toString(),10)],n[parseInt(i.toString(),10)]=r)}}return n}(t,e),i=1;i0){var i=0,r={x:.5,y:.5};t[0]=this.diagram.nameTable[t[0].id]||t[0];var s=yr(t[0].wrapper),o={nodes:[],connectors:[]},a={nodes:[],connectors:[]};for(i=1;ii.zIndex){for(var s=this.diagram.layers.indexOf(this.diagram.getActiveLayer()),o=this.diagram.layers[parseInt(s.toString(),10)].zIndexTable,a=JSON.parse(JSON.stringify(o)),l=i.zIndex,h=r.zIndex,c=h;c>=l;c--)l!==c?o[c-1]?(o[parseInt(c.toString(),10)]=o[c-1],this.diagram.nameTable[o[parseInt(c.toString(),10)]].zIndex=c):(o[c-1]=o[parseInt(c.toString(),10)],this.diagram.nameTable[o[c-1]].zIndex=c,delete o[parseInt(c.toString(),10)]):this.swapZIndexObjects(h,o,r.id,a);"SVG"===this.diagram.mode?(this.moveSvgNode(e.parentId,i.id),this.updateNativeNodeIndex(e.parentId,i.id)):this.diagram.refreshCanvasLayers()}},n.prototype.findLeastIndexConnector=function(t,e,i){for(var r=0;rs.zIndex&&(i=s)}return i},n.prototype.findLeastIndexObject=function(t,e){var i=t;return t instanceof te&&(i=this.findLeastIndexConnector(t.inEdges,e,i),i=this.findLeastIndexConnector(t.outEdges,e,i)),i},n.prototype.checkSelection=function(t,e){var i;if(1===t.nodes.length&&0===t.connectors.length)if(Dn(this.diagram,t.nodes[0],!0)){var r=t.nodes[0];if("SwimLane"===(i="SwimLane"===t.nodes[0].shape?t.nodes[0]:this.diagram.nameTable[t.nodes[0].parentId]).shape.type){var s="Horizontal"===i.shape.orientation;(r.isPhase&&(s&&"ResizeSouth"===e||!s&&"ResizeEast"===e)||r.isLane&&(s&&"ResizeEast"===e||!s&&"ResizeSouth"===e))&&B3(this.diagram,i,e)}else if("Grid"===i.container.type)if("Horizontal"===i.container.orientation&&1===r.rowIndex||"Vertical"===i.container.orientation&&r.rowIndex>0&&r.columnIndex>0){if("ResizeSouth"===e)for(var o=0;o1&&(this.diagram.realActions=this.diagram.realActions|$i.hScrollbarMoved,this.scrolled=!0),this.diagram.scrollSettings.horizontalOffset=t},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"verticalOffset",{get:function(){return this.vOffset},set:function(t){this.vOffset=t,Math.abs(this.vOffset-this.diagram.scrollSettings.verticalOffset)>1&&(this.diagram.realActions=this.diagram.realActions|$i.vScrollbarMoved,this.scrolled=!0),this.diagram.scrollSettings.verticalOffset=t},enumerable:!0,configurable:!0}),n.prototype.getBounds=function(){var e=this.diagram.spatialSearch.getPageBounds(0,0);return(e.x<0||e.y<0)&&!this.diagram.pageSettings.multiplePage?this.getPageBounds(void 0,void 0,!0,!0):this.getPageBounds(void 0,void 0,!0)},n.prototype.updateScrollOffsets=function(t,e){var i,r,s=this.getBounds();s.x*=this.currentZoom,s.y*=this.currentZoom,s.width*=this.currentZoom,s.height*=this.currentZoom,i=Math.max(0,t-s.left),r=Math.max(0,e-s.top),void 0!==t&&void 0!==e?(this.horizontalOffset=i,this.verticalOffset=r,this.diagram.setOffset(i,r)):this.diagram.setOffset(-this.horizontalOffset-s.x,-this.verticalOffset-s.y),this.transform={tx:Math.max(this.horizontalOffset,-s.left)/this.currentZoom,ty:Math.max(this.verticalOffset,-s.top)/this.currentZoom,scale:this.currentZoom}},n.prototype.setScrollOffset=function(t,e){this.scrolled=!1;var i=this.getBounds();i.x*=this.currentZoom,i.y*=this.currentZoom,i.width*=this.currentZoom,i.height*=this.currentZoom;var r=-i.left,s=-i.top,o=!1,a=this.viewPortWidth*this.currentZoom,l=this.viewPortHeight*this.currentZoom,h=r-t;if(h!==this.horizontalOffset){rh?this.horizontalOffset-=t:this.horizontalOffset=h,o=!0);var c=Math.max(i.right+this.vScrollSize,a);if(!o&&c<-h+this.viewPortWidth){var d=-h+a-this.vScrollSize,u=-this.horizontalOffset+a-this.vScrollSize;this.horizontalOffset=dd-u?h:-(i.right+this.vScrollSize-a),o=!0}o||(this.horizontalOffset=r-t)}o=!1;var f=s-e;if(f!==this.verticalOffset){sf?this.verticalOffset-=e:this.verticalOffset=f,o=!0);var p=Math.max(i.bottom+this.hScrollSize,l);if(!o&&p<-f+l){var g=-f+l-this.hScrollSize,v=-this.verticalOffset+l-this.hScrollSize;this.verticalOffset=gg-v?f:-(i.bottom+this.hScrollSize-l),o=!0}o||(this.verticalOffset=s-e)}this.transform={tx:Math.max(this.horizontalOffset,-i.left)/this.currentZoom,ty:Math.max(this.verticalOffset,-i.top)/this.currentZoom,scale:this.currentZoom},this.setSize()},n.prototype.getObjects=function(t,e){for(var i=[],r=0;r0){for(var l=0;l0){h.push(i[parseInt(o.toString(),10)].id);for(var d=0;d=e.bottom&&(l=0),-this.horizontalOffset<=e.x&&-this.horizontalOffset+this.viewPortWidth>=e.right&&(a=0),this.hScrollSize=a,this.vScrollSize=l;var h=this.diagramWidth,c=this.diagramHeight;this.diagramWidth=Math.max(e.right,-this.horizontalOffset+this.viewPortWidth-l)-i,this.diagramHeight=Math.max(e.bottom,-this.verticalOffset+this.viewPortHeight-a)-r,(h!==this.diagramWidth||c!==this.diagramHeight)&&"Diagram"!==this.diagram.scrollSettings.scrollLimit&&this.diagram.setSize(this.diagramWidth,this.diagramHeight),"Diagram"===this.diagram.scrollSettings.scrollLimit&&(h===this.diagramWidth&&c===this.diagramHeight&&1===this.currentZoom||this.diagram.diagramActions&&t&&(!this.diagram.diagramActions||!t||0===this.verticalOffset&&this.verticalOffset!==t.y||0===this.horizontalOffset&&this.horizontalOffset!==t.x)?t&&h===this.diagramWidth&&c===this.diagramHeight&&(this.diagram.diagramCanvas.scrollHeight>this.viewPortHeight&&t.y<0&&this.horizontalOffset===t.x&&0===this.verticalOffset||this.diagram.diagramCanvas.scrollWidth>this.viewPortWidth&&t.x<0&&this.verticalOffset===t.y&&0===this.horizontalOffset)&&(this.verticalOffset=t.y,this.horizontalOffset=t.x,this.transform={tx:Math.max(t.x,-e.left)/this.currentZoom,ty:Math.max(t.y,-e.top)/this.currentZoom,scale:this.currentZoom}):(this.diagram.scrollActions&da.Interaction&&t&&(this.transform={tx:Math.max(t.x,-e.left/this.currentZoom)/this.currentZoom,ty:Math.max(t.y,-e.top/this.currentZoom)/this.currentZoom,scale:this.currentZoom},this.horizontalOffset=t.x,this.verticalOffset=t.y),this.diagram.setSize(this.diagramWidth,this.diagramHeight),!(this.diagram.scrollActions&da.PropertyChange)&&t&&(this.horizontalOffset=t.x,this.verticalOffset=t.y,this.transform={tx:Math.max(t.x,-e.left)/this.currentZoom,ty:Math.max(t.y,-e.top)/this.currentZoom,scale:this.currentZoom}))),this.diagram.transformLayers(),this.diagram.element.style.overflow="hidden"},n.prototype.setViewPortSize=function(t,e){this.viewPortWidth=t,this.viewPortHeight=e},n.prototype.getPageBounds=function(t,e,i,r){var o,s=new Ne;if("Content"===e||r||null===this.diagram.pageSettings.width||null===this.diagram.pageSettings.height){var u=t?void 0:0;o=this.diagram.spatialSearch.getPageBounds(u,u)}else{var a=this.diagram.pageSettings.width,l=this.diagram.pageSettings.height,h=0,c=0;if(this.diagram.pageSettings.multiplePage){if((s=this.diagram.spatialSearch.getPageBounds(0,0)).right>a&&(a*=d=Math.ceil(s.right/a)),s.bottom>l&&(l*=d=Math.ceil(s.bottom/l)),s.left<0&&Math.abs(s.left)>h){var d=Math.ceil(Math.abs(s.left)/this.diagram.pageSettings.width);h=this.diagram.pageSettings.width*d}s.top<0&&Math.abs(s.top)>c&&(d=Math.ceil(Math.abs(s.top)/this.diagram.pageSettings.height),c=this.diagram.pageSettings.height*d)}o=new Ne(-h,-c,a+h,l+c)}if(i){var f=this.diagram.scrollSettings.padding;o.x-=f.left,o.y-=f.top,o.width+=f.left+f.right,o.height+=f.top+f.bottom}return o},n.prototype.getPageBreak=function(t){for(var e=0,i=0,r=-1,s=[],c=this.diagram.pageSettings.margin.left,d=this.diagram.pageSettings.margin.right,u=this.diagram.pageSettings.margin.top,f=this.diagram.pageSettings.margin.bottom,p=1,g=1;t.width>e;)(e+=this.diagram.pageSettings.width?this.diagram.pageSettings.width:t.width)===this.diagram.pageSettings.width&&(s[++r]={x1:t.left+c,y1:t.top+u,x2:t.left+c,y2:t.bottom-f}),ei;)(i+=this.diagram.pageSettings.height?this.diagram.pageSettings.height:t.height)===this.diagram.pageSettings.height&&(s[++r]={x1:t.left+c,y1:t.top+u,x2:t.right-d,y2:t.top+u}),i=this.diagram.scrollSettings.minZoom||l||t>=1)){this.currentZoom*=t;var c=this.getPageBounds(void 0,void 0,!0);c.x*=this.currentZoom,c.y*=this.currentZoom;var d=Bi();Gf(d,t,t,r.x,r.y),ZB(d,e||0,i||0),Ix(h,d);var u=Ke(h,{x:0,y:0});if(1===t&&(u=this.applyScrollLimit(u.x,u.y,s,o,a)),a=-c.y>=u.y&&-c.x>=u.x&&a,(this.diagram.scrollActions&da.PropertyChange||!(this.diagram.scrollActions&da.Interaction)||"Diagram"!==this.diagram.scrollSettings.scrollLimit||a)&&(this.transform={tx:Math.max(u.x,-c.left)/this.currentZoom,ty:Math.max(u.y,-c.top)/this.currentZoom,scale:this.currentZoom},this.horizontalOffset=u.x,this.verticalOffset=u.y),this.setSize(u),"SVG"!==this.diagram.mode&&Ds(this.diagram)&&this.diagram.scroller.virtualizeElements(),"SVG"!==this.diagram.mode&&!Ds(this.diagram)&&this.diagram.refreshDiagramLayer(),this.diagram.setOffset(-this.horizontalOffset-c.x,-this.verticalOffset-c.y),JI(this.diagram),this.diagram.views&&this.diagram.views.overview){var f=this.diagram.views.overview,p=f.scrollOverviewRect(f.parent.scroller.horizontalOffset,f.parent.scroller.verticalOffset,f.parent.scroller.currentZoom,!0);f.updateOverviewrect(-p.x,-p.y,p.width,p.height),f.updateView(f)}}}},n.prototype.fitToPage=function(t){var e=(t=t||{}).mode,i=t.region,r=t.margin||{},s=t.canZoomIn,o=t.customBounds,a=t.canZoomOut;r.bottom=r.bottom||25,r.top=r.top||25,r.left=r.left||25,r.right=r.right||25;var h,l=o,c=-this.horizontalOffset,d=-this.verticalOffset;if("PageSettings"===(i=i||"PageSettings")&&this.diagram.pageSettings.width&&this.diagram.pageSettings.height||this.diagram.nodes.length>0||this.diagram.connectors.length>0){e=e||"Page","CustomBounds"!==i&&(l=this.getPageBounds(!0,i,!0));var u={x:0,y:0};r.left+r.right>this.viewPortWidth&&(this.viewPortWidth<=100?(r.left=5,r.right=5):(r.left=25,r.right=25)),r.top+r.bottom>this.viewPortHeight&&(this.viewPortHeight<=100?(r.top=5,r.bottom=5):(r.top=25,r.bottom=25)),u.x=(this.viewPortWidth-(r.left+r.right))/l.width,u.y=(this.viewPortHeight-(r.top+r.bottom))/l.height,!s&&l.width-this.horizontalOffset-a+this.viewPortWidth&&(i=o.right-this.viewPortWidth,i+=20),o.x<-a&&(i=o.x),o.bottom>-l+this.viewPortHeight&&(r=o.bottom-this.viewPortHeight,r+=20),o.y<-l&&(r=o.y),this.zoom(1,-this.horizontalOffset-i,-this.verticalOffset-r,null,void 0,e))},n.prototype.bringToCenter=function(t){var e=this.currentZoom,i=new Ne(t.x*e,t.y*e,t.width*e,t.height*e),r=i.x+i.width/2-this.viewPortWidth/2,s=i.y+i.height/2-this.viewPortHeight/2;this.zoom(1,-this.horizontalOffset-(r*=-1),-this.verticalOffset-(s*=-1),null)},n.prototype.applyScrollLimit=function(t,e,i,r,s){if("Infinity"===this.diagram.scrollSettings.scrollLimit&&void 0===i&&!r&&(t=-t,e=-e),"Infinity"!==this.diagram.scrollSettings.scrollLimit){var o=void 0;if("Limited"===this.diagram.scrollSettings.scrollLimit){var a=this.diagram.scrollSettings.scrollableArea;o=new Ne(a.x,a.y,a.width,a.height)}(o=o||(s?this.getPageBounds():this.getPageBounds(!0))).x*=this.currentZoom,o.y*=this.currentZoom,o.width*=this.currentZoom,o.height*=this.currentZoom,void 0!==i&&(t*=-1,e*=-1),r&&(t*=-1,e*=-1);var l=Math.max(o.right,this.viewPortWidth);if(!r&&!(t<=o.x&&(t+this.viewPortWidth>=o.right||t>=o.right-this.viewPortWidth)||t>=o.x&&t+this.viewPortWidth<=l))if(t>=o.x)t=Math.max(o.x,Math.min(t,t-(t+this.viewPortWidth-this.vScrollSize-l)));else{var h=o.right-this.viewPortWidth;t=Math.min(h,o.x)}var c=Math.max(o.bottom,this.viewPortHeight);r||e<=o.y&&e+this.viewPortHeight>=o.bottom||e>=o.y&&e+this.viewPortHeight<=c||(e>=o.y?e=Math.max(o.y,Math.min(e,e-(e+this.viewPortHeight-this.hScrollSize-c))):(h=o.bottom-this.viewPortHeight,e=Math.min(o.y,h))),t*=-1,e*=-1}return{x:t,y:e}},n}(),Qoe=function(){function n(t,e,i,r,s){this.objects=[],this.left=t,this.top=e,this.width=i,this.height=r,this.spatialSearch=s}return n.prototype.findQuads=function(t,e){null!=this.first&&this.first.isIntersect(t)&&this.first.findQuads(t,e),null!=this.second&&this.second.isIntersect(t)&&this.second.findQuads(t,e),null!=this.third&&this.third.isIntersect(t)&&this.third.findQuads(t,e),null!=this.fourth&&this.fourth.isIntersect(t)&&this.fourth.findQuads(t,e),this.objects.length>0&&e.push(this)},n.prototype.isIntersect=function(t){return!(this.left+this.widtht.right||this.top>t.bottom)},n.prototype.selectQuad=function(){for(var i,t=null,e=this;null!=e;)i=e.getQuad(t),e=i.source,t=i.target||t;return t},n.prototype.getQuad=function(t){var e=this.width/2,i=this.height/2;if(e>=1e3&&i>=1e3){var r=this.left+e,s=this.top+i;if(this.spatialSearch.childRight<=r){if(this.spatialSearch.childBottom<=s)return this.first||((o=new n(this.left,this.top,e,i,this.spatialSearch)).parent=this,this.first=o),{source:this.first};if(this.spatialSearch.childTop>=s)return this.third||((o=new n(this.left,s,e,i,this.spatialSearch)).parent=this,this.third=o),{source:this.third}}else if(this.spatialSearch.childLeft>=r){if(this.spatialSearch.childBottom<=s)return this.second||((o=new n(r,this.top,e,i,this.spatialSearch)).parent=this,this.second=o),{source:this.second};var o;if(this.spatialSearch.childTop>=s)return this.fourth||((o=new n(r,s,e,i,this.spatialSearch)).parent=this,this.fourth=o),{source:this.fourth}}}return this.objects.push(this.spatialSearch.childNode),{target:this}},n.prototype.isContained=function(){return this.spatialSearch.childLeft>=this.left&&this.spatialSearch.childRight<=this.left+this.width&&this.spatialSearch.childTop>=this.top&&this.spatialSearch.childBottom<=this.top+this.height},n.prototype.addIntoAQuad=function(t){var e={};this.spatialSearch.setCurrentNode(t);for(var i=null;!e.isAdded;)i=(e=this.spatialSearch.parentQuad.add(i)).quad;return i},n.prototype.add=function(t){if(t=null,this.isContained())return{isAdded:!0,quad:t=this.selectQuad()};var e=void 0,i=!(0!==this.objects.length||this.first||this.second||this.third||this.fourth),r=2*this.width,s=2*this.height;return this.spatialSearch.childLeft=this.childLeft?(this.pageLeft=this.childLeft,this.leftElement=t,r=!0):t===this.leftElement&&(this.pageLeft=Number.MAX_VALUE,this.findLeft(this.parentQuad),r=!0)),(this.pageTop!==this.childTop||t!==this.topElement)&&(this.pageTop>=this.childTop?(this.pageTop=this.childTop,this.topElement=t,r=!0):t===this.topElement&&(this.pageTop=Number.MAX_VALUE,this.findTop(this.parentQuad),r=!0)),(this.pageBottom!==this.childBottom||t!==this.bottomElement)&&(this.pageBottom<=this.childBottom?(r=!0,this.pageBottom=this.childBottom,this.bottomElement=t):t===this.bottomElement&&(this.pageBottom=-Number.MAX_VALUE,this.findBottom(this.parentQuad),r=!0)),(this.pageRight!==this.childRight||t!==this.rightElement)&&(this.pageRight<=this.childRight?(this.pageRight=this.childRight,this.rightElement=t,r=!0):t===this.rightElement&&(this.pageRight=-Number.MAX_VALUE,this.findRight(this.parentQuad),r=!0)),r}return this.setCurrentNode(null),!1},n.prototype.isWithinPageBounds=function(t){return t.left>=this.pageLeft&&t.right<=this.pageRight&&t.top>=this.pageTop&&t.bottom<=this.pageBottom},n.prototype.findQuads=function(t){var e=[];return this.parentQuad.findQuads(t,e),e},n.prototype.findObjects=function(t){for(var i=[],r=0,s=this.findQuads(t);r=r.outerBounds.left&&(this.pageLeft=r.outerBounds.left,this.leftElement=r)}},n.prototype.findTop=function(t){t.first||t.second?(t.first&&this.findTop(t.first),t.second&&this.findTop(t.second)):(t.third&&this.findTop(t.third),t.fourth&&this.findTop(t.fourth));for(var e=0,i=t.objects;e=r.outerBounds.top&&(this.pageTop=r.outerBounds.top,this.topElement=r)}},n.prototype.setCurrentNode=function(t){if(this.childNode=t,t){var e=t.outerBounds;this.childLeft=Number(e.left),this.childTop=Number(e.top),this.childRight=Number(e.right),this.childBottom=Number(e.bottom)}else this.childLeft=Number.MAX_VALUE,this.childTop=Number.MAX_VALUE,this.childRight=-Number.MAX_VALUE,this.childBottom=-Number.MAX_VALUE},n.prototype.getPageBounds=function(t,e){if(this.pageLeft===Number.MAX_VALUE)return new Ne(0,0,0,0);var i=void 0!==t?Math.min(this.pageLeft,0):this.pageLeft,r=void 0!==e?Math.min(this.pageTop,0):this.pageTop;return new Ne(Math.round(i),Math.round(r),Math.round(this.pageRight-i),Math.round(this.pageBottom-r))},n.prototype.getQuad=function(t){return this.quadTable[t.id]},n}(),Goe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),qoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Goe(t,n),function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);r>3&&s&&Object.defineProperty(t,e,s)}([I(!1)],t.prototype,"preventDefaults",void 0),t}(Ee),$oe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),e_=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Zoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return $oe(t,n),e_([I("")],t.prototype,"action",void 0),e_([I("")],t.prototype,"cursor",void 0),t}(Ee),t_=function(){function n(){this.size=20,this.intermediatePoints=[],this.gridCollection=[],this.startArray=[],this.targetGridCollection=[],this.sourceGridCollection=[],this.considerWalkable=[]}return n.prototype.lineRouting=function(t){var e=t.connectors.length;if(this.renderVirtualRegion(t),e>0)for(var i=0;i=t.right||e.right<=t.left||e.top>=t.bottom||e.bottom<=t.top)},n.prototype.findEndPoint=function(t,e,i){var r,s;if(e&&""!==t.sourcePortID&&t.sourcePortWrapper||!e&&""!==t.targetPortID&&t.targetPortWrapper){s=zo(r=e?{x:t.sourcePortWrapper.offsetX,y:t.sourcePortWrapper.offsetY}:{x:t.targetPortWrapper.offsetX,y:t.targetPortWrapper.offsetY},void 0,e?t.sourceWrapper.bounds:t.targetWrapper.bounds);var o=e?t.sourcePortWrapper.bounds:t.targetPortWrapper.bounds;r=i?"Top"===s?{x:o.topCenter.x,y:o.topCenter.y}:"Left"===s?{x:o.middleLeft.x,y:o.middleLeft.y}:"Right"===s?{x:o.middleRight.x,y:o.middleRight.y}:{x:o.bottomCenter.x,y:o.bottomCenter.y}:{x:o.center.x,y:o.center.y}}else r=e&&this.startNode||!e&&this.targetNode?e?{x:this.startNode.wrapper.offsetX,y:this.startNode.wrapper.offsetY}:{x:this.targetNode.wrapper.offsetX,y:this.targetNode.wrapper.offsetY}:e?{x:t.sourcePoint.x,y:t.sourcePoint.y}:{x:t.targetPoint.x,y:t.targetPoint.y};return r},n.prototype.refreshConnectorSegments=function(t,e,i,r){var h,c,f,p,g,y,S,b,M,w,C,s=e.sourceID,o=e.targetID,a=e.sourcePortID,l=e.targetPortID;if(function Vre(n,t){var e=0;return n.constraints&qe.LineRouting?e=n.constraints&qe.LineRouting:n.constraints&qe.InheritLineRouting&&(e=t.constraints&nt.LineRouting),e}(e,t)||r){this.startNode=t.nameTable[""+s],this.targetNode=t.nameTable[""+o],this.intermediatePoints=[],this.startArray=[],this.targetGridCollection=[],this.sourceGridCollection=[],this.startGrid=void 0,this.targetGrid=void 0;for(var D=0;D0;){var L=this.startArray.pop();if(L){for(D=0;D1&&(e.segments=[]),this.updateConnectorSegments(t,this.intermediatePoints,this.gridCollection,e,i)){this.considerWalkable=[];break e}this.targetGridCollection.splice(this.targetGridCollection.indexOf(O),1),L=this.startArray.pop()}}L&&this.findPath(L)}}}},n.prototype.checkChildNodes=function(t,e){var i=!1,r=!1;if(t.nodeId.length>=1&&!e)for(var s=0;s1&&this.targetGridCollection[0].nodeId.length>1)for(var c=0;c<=1;c++){for(var d=this.targetGridCollection[parseInt(c.toString(),10)].gridX,u=this.targetGridCollection[parseInt(c.toString(),10)].gridY,f=this.targetGridCollection[parseInt(c.toString(),10)].nodeId,p=void 0,g=0;g=e.right&&t.top<=e.top&&t.bottom>=e.bottom},n.prototype.getEndvalue=function(t,e){return this.gridCollection[t.gridX][t.gridY].walkable?t:"left"===e?this.getEndvalue(this.gridCollection[t.gridX-1][t.gridY],e):"right"===e?this.getEndvalue(this.gridCollection[t.gridX+1][t.gridY],e):"top"===e?this.getEndvalue(this.gridCollection[t.gridX][t.gridY-1],e):"bottom"===e?this.getEndvalue(this.gridCollection[t.gridX][t.gridY+1],e):t},n.prototype.changeValue=function(t,e,i){t.walkable||this.considerWalkable.push(t);for(var r,s=0;s<=e;s++)"left"===i?r=this.gridCollection[t.gridX-s][t.gridY]:"right"===i?r=this.gridCollection[t.gridX+s][t.gridY]:"top"===i?r=this.gridCollection[t.gridX][t.gridY-s]:"bottom"===i&&(r=this.gridCollection[t.gridX][t.gridY+s]),r.walkable||this.considerWalkable.push(r)},n.prototype.getIntermediatePoints=function(t){var e;for(this.intermediatePoints=[];t;)this.intermediatePoints.push({x:t.gridX,y:t.gridY}),t=t.parent;this.intermediatePoints.reverse(),this.intermediatePoints.length>=1&&void 0!==this.intermediatePoints[0]&&void 0!==this.intermediatePoints[1]&&(this.intermediatePoints[0].x===this.intermediatePoints[1].x?this.intermediatePoints[0].yi.y&&o.y>s.y){for(var a=i.xi.x&&o.x>s.x)){for(var u=i.y=1&&u.length>1&&(g=u[u.length-2].x!==u[u.length-1].x?u[u.length-2].x>u[u.length-1].x?"Left":"Right":u[u.length-2].y>u[u.length-1].y?"Top":"Bottom"),M>=2&&v===g&&u.length>1&&u.splice(u.length-2,1),v=g);if(u&&u.length>1){for(var w=0;wD.x?S.bounds.middleLeft:S.bounds.middleRight),w===u.length-2&&""===r.targetPortID&&y&&(l=C.x>D.x?y.bounds.middleRight:y.bounds.middleLeft),0===w&&b&&(C.x=b.x,C.y=D.y=b.y,b=qa(r,0,b,Nl(S.bounds,_n(C.x>D.x?"Left":"Right")),!1),C.x=b.x),w===u.length-2&&l&&(w>0&&r.targetDecorator&&l.x-D.x<0&&Math.abs(l.x-C.x)0&&r.targetDecorator&&l.x-D.x>0&&Math.abs(l.x-C.x)D.y?S.bounds.topCenter:S.bounds.bottomCenter),w===u.length-2&&""===r.targetPortID&&y&&(l=C.y>D.y?y.bounds.bottomCenter:y.bounds.topCenter),0===w&&b&&(C.y=b.y,C.x=D.x=b.x,b=qa(r,0,b,Nl(S.bounds,_n(C.y>D.y?"Top":"Bottom")),!1),C.y=b.y),w===u.length-2&&l&&(w>0&&r.targetDecorator&&l.y-D.y<0&&Math.abs(l.y-C.y)0&&r.targetDecorator&&l.y-D.y>0&&Math.abs(l.y-C.y)D.x?(f="Left",p=C.x-D.x):(f="Right",p=D.x-C.x):C.y>D.y?(f="Top",p=C.y-D.y):(f="Bottom",p=D.y-C.y),o.push({type:"Orthogonal",length:p,direction:f})}}if(o&&o.length>0){var L=o[o.length-1];if(1===o.length&&(L.length-=20),L.length<10&&2===o.length&&(o.pop(),o.length>0&&(o[0].length-=20,L=o[0])),r.targetDecorator&&("Top"===L.direction||"Bottom"===L.direction)&&L.length>r.targetDecorator.height+1||("Right"===L.direction||"Left"===L.direction)&&L.length>r.targetDecorator.width+1)return r.segments=o,s&&t.connectorPropertyChange(r,{},{type:"Orthogonal",segments:o}),!0}return!1},n.prototype.findPath=function(t){for(var e,i=[],r=this.findNearestNeigbours(t,this.gridCollection,!0),s=0;sl)&&(e.x!==t.gridX||e.y!==t.gridY)&&(i.push(e),o.previousDistance=l,o.afterDistance=o.afterDistance||this.manhattan(Math.abs(e.x-this.targetGrid.gridX),Math.abs(e.y-this.targetGrid.gridY)),o.totalDistance=o.previousDistance+o.afterDistance,o.parent=t)}if(i.length>0)for(s=0;st?i*t+e:i*e+t},n.prototype.manhattan=function(t,e){return t+e},n.prototype.findNearestNeigbours=function(t,e,i){var r=[],s=t.parent;if(s){var o=(t.gridX-s.gridX)/Math.max(Math.abs(t.gridX-s.gridX),1),a=(t.gridY-s.gridY)/Math.max(Math.abs(t.gridY-s.gridY),1);0!==o?(this.isWalkable(t.gridX,t.gridY-1,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX][t.gridY-1])&&r.push(e[t.gridX][t.gridY-1]),this.isWalkable(t.gridX,t.gridY+1,!0)&&this.sourceGridCollection.indexOf(e[t.gridX][t.gridY+1])&&r.push(e[t.gridX][t.gridY+1]),this.isWalkable(t.gridX+o,t.gridY,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX+o][t.gridY])&&r.push(e[t.gridX+o][t.gridY])):0!==a&&(this.isWalkable(t.gridX-1,t.gridY,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX-1][t.gridY])&&r.push(e[t.gridX-1][t.gridY]),this.isWalkable(t.gridX+1,t.gridY,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX+1][t.gridY])&&r.push(e[t.gridX+1][t.gridY]),this.isWalkable(t.gridX,t.gridY+a,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX][t.gridY+a])&&r.push(e[t.gridX][t.gridY+a]))}else this.neigbour(t,"top",r,i),this.neigbour(t,"right",r,i),this.neigbour(t,"bottom",r,i),this.neigbour(t,"left",r,i);return r},n.prototype.neigbour=function(t,e,i,r){for(var o,s=1;s>0;){var a="top"===e||"bottom"===e?t.gridX:"left"===e?t.gridX-s:t.gridX+s,l="right"===e||"left"===e?t.gridY:"top"===e?t.gridY-s:t.gridY+s;if((o=this.gridCollection[parseInt(a.toString(),10)][parseInt(l.toString(),10)])&&(r&&-1===this.sourceGridCollection.indexOf(o)||!r&&-1===this.targetGridCollection.indexOf(o)))return i&&this.isWalkable(a,l)&&i.push(o),s;if(!(a>0&&l>0))break;s++}return null},n.prototype.resetGridColl=function(t,e,i){for(var s,r=1;r>0;){var o="top"===e||"bottom"===e?t.gridX:"left"===e?t.gridX-r:t.gridX+r,a="right"===e||"left"===e?t.gridY:"top"===e?t.gridY-r:t.gridY+r;if((s=this.gridCollection[parseInt(o.toString(),10)][parseInt(a.toString(),10)])&&(i&&-1===this.sourceGridCollection.indexOf(s)||!i&&-1===this.targetGridCollection.indexOf(s))){if(this.isWalkable(o,a))break;var l=this.gridCollection[parseInt(o.toString(),10)][parseInt(a.toString(),10)];this.considerWalkable.push(l)}if(!(o>0&&a>0))break;"top"===e||"left"===e?r--:r++}return null},n.prototype.isWalkable=function(t,e,i){if(t>=0&&t=0&&e0?1:-1,this.isWalkable(h,c-1)&&!this.isWalkable(h-a,c-1)||this.isWalkable(h,c+1)&&!this.isWalkable(h-a,c+1)))return{x:t,y:e};if(0!==l){if(l=l>0?1:-1,this.isWalkable(h-1,c)&&!this.isWalkable(h-1,c-l)||this.isWalkable(h+1,c)&&!this.isWalkable(h+1,c-l))return{x:t,y:e};if(this.findIntermediatePoints(h+1,c,h,c,s,o)||this.findIntermediatePoints(h-1,c,h,c,s,o))return{x:t,y:e}}return this.findIntermediatePoints(h+a,c+l,h,c,s,o)},n.prototype.destroy=function(){},n.prototype.getModuleName=function(){return"LineRouting"},n}(),Joe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),eae=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Joe(t,n),function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);r>3&&s&&Object.defineProperty(t,e,s)}([I(!0)],t.prototype,"inversedAlignment",void 0),t}(Ee),tae=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Oe=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},DT=function(n,t,e,i){return new(e||(e=Promise))(function(r,s){function o(h){try{l(i.next(h))}catch(c){s(c)}}function a(h){try{l(i.throw(h))}catch(c){s(c)}}function l(h){h.done?r(h.value):new e(function(c){c(h.value)}).then(o,a)}l((i=i.apply(n,t||[])).next())})},xT=function(n,t){var i,r,s,o,e={label:0,sent:function(){if(1&s[0])throw s[1];return s[1]},trys:[],ops:[]};return o={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function a(h){return function(c){return function l(h){if(i)throw new TypeError("Generator is already executing.");for(;e;)try{if(i=1,r&&(s=2&h[0]?r.return:h[0]?r.throw||((s=r.return)&&s.call(r),0):r.next)&&!(s=s.call(r,h[1])).done)return s;switch(r=0,s&&(h=[2&h[0],s.value]),h[0]){case 0:case 1:s=h;break;case 4:return e.label++,{value:h[1],done:!1};case 5:e.label++,r=h[1],h=[0];continue;case 7:h=e.ops.pop(),e.trys.pop();continue;default:if(!(s=(s=e.trys).length>0&&s[s.length-1])&&(6===h[0]||2===h[0])){e=0;continue}if(3===h[0]&&(!s||h[1]>s[0]&&h[1]0&&((!s.style||!s.style.fill)&&(o.style.fill="transparent"),(!s.style||!s.style.strokeColor)&&(o.style.strokeColor="transparent")),s.shape&&"UmlActivity"===s.shape.type&&tb(s,o),s.shape&&"SwimLane"===s.shape.type&&aF(s,o),r.nodeDefaults&&Ro(o,s,r.nodeDefaults),r.updateAnnotationText(o.annotations);if(e&&e.connectors)for(a=0;e&&e.connectors&&a0&&0===i.nodes.length)this.clearCollection(),a=!0;else{for(var g=0,v=Object.keys(e.nodes);g0&&0===i.connectors.length)this.clearCollection(!0),a=!0;else{for(var C=0,D=Object.keys(e.connectors);C0){this.renderSelector(!0);break}if(e.selectedItems.constraints){this.renderSelector(!0);break}break;case"snapSettings":this.updateSnapSettings(e);break;case"commandManager":this.initCommands();break;case"layout":o=!0;break;case"segmentThumbShape":this.updateSelector();break;case"dataSourceSettings":this.clear(),"None"===this.layout.type?a=!0:(this.initObjects(),o=!0);break;case"tooltip":i3(this);break;case"rulerSettings":this.updateRulerSettings(e);break;case"layers":this.updateLayer(e);break;case"scrollSettings":this.scrollActions|=da.PropertyChange,this.updateScrollSettings(e),this.scrollActions&=~da.PropertyChange,this.scrollSettings.horizontalOffset=-this.scroller.horizontalOffset||0,this.scrollSettings.verticalOffset=-this.scroller.verticalOffset||0;break;case"locale":e.locale!==i.locale&&(this.realActions|=$i.PreventDataInit,n.prototype.refresh.call(this),this.realActions&=~$i.PreventDataInit);break;case"contextMenuSettings":if(void 0!==e.contextMenuSettings.showCustomMenuOnly&&(this.contextMenuSettings.showCustomMenuOnly=e.contextMenuSettings.showCustomMenuOnly),void 0!==e.contextMenuSettings.show&&(this.contextMenuSettings.show=e.contextMenuSettings.show),e.contextMenuSettings.items){for(var A=e.contextMenuSettings.items,x=0,P=Object.keys(A);x0){for(var N=[],T=O.ports.length-1;T>=0;T--)"LineDistribution"===O.ports[parseInt(T.toString(),10)].id.split("_")[1]&&N.push(O.ports[parseInt(T.toString(),10)]);this.removePorts(O,N)}}for(T=0;T0)for(var ue=0,fe=Object.keys(e.nodes);ue0)for(var De=0,xe=Object.keys(e.connectors);De=0;o--)this.commandHandler.expandNode(r[parseInt(o.toString(),10)],this,0!==o);this.canLayout&&this.doLayout(),this.lineRoutingModule?this.connectors.sourceID!==this.connectors.targetID&&this.lineRoutingModule.lineRouting(this):this.constraints&nt.LineRouting&&console.warn('[WARNING] :: Module "LineRouting" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),this.validatePageSize(),this.renderPageBreaks(),this.diagramRenderer.renderSvgGridlines(this.snapSettings,Ud(this.element.id),this.scroller.transform,this.rulerSettings,this.hRuler,this.vRuler),this.commandHandler.initSelectorWrapper(),this.notify("initial-load",{}),this.trigger("load"),this.scroller.setSize(),this.scroller.updateScrollOffsets(),this.isRefreshed||this.refreshDiagramLayer(),(this.scrollSettings.verticalOffset>0||this.scrollSettings.horizontalOffset>0)&&this.updateScrollOffset(),X.isDevice&&(this.tool=ni.ZoomPan|ni.SingleSelect),this.notify("initial-end",{}),this.isProtectedOnChange=!1,this.tooltipObject=i3(this),this.diagramActions=ee.Render,this.initCommands();var a=document.getElementsByClassName(this.element.id+"_hiddenUserHandleTemplate");(function Moe(n,t,e,i){var r,s,o,a,l,d=document.getElementById(i).ej2_instances[0];if(n&&t){r=UF(n);for(var u=0,f=e.userHandles;u0;)e[0].parentNode.removeChild(e[0]);var i=document.getElementById(this.element.id+"content");i&&this.element.removeChild(i);var r="measureElement";if(window[""+r]){window[""+r].usageCount-=1;var s="measureElementCount";window[""+s]--,0===window[""+s]&&(window[""+r].parentNode.removeChild(window[""+r]),window[""+r]=null)}}window.domTable={};for(var a=0;a1&&(this.callBlazorModel=!1,this.insertBlazorDiagramObjects(this.selectedItems),this.commandHandler.group(),this.callBlazorModel=!0,this.commandHandler.getBlazorOldValues())},t.prototype.unGroup=function(){this.callBlazorModel=!1,this.insertBlazorDiagramObjects(this.selectedItems),this.commandHandler.unGroup(),this.callBlazorModel=!0,this.commandHandler.getBlazorOldValues()},t.prototype.sendToBack=function(){this.commandHandler.sendToBack()},t.prototype.setActiveLayer=function(e){var i=this.commandHandler.getLayer(e);this.activeLayer=i},t.prototype.addLayer=function(e,i){this.commandHandler.addLayer(e,i)},t.prototype.removeLayer=function(e){this.commandHandler.removeLayer(e,ce())},t.prototype.moveObjects=function(e,i){$(this.layers),this.enableServerDataBinding(!1),this.commandHandler.moveObjects(e,i)},t.prototype.layerObjectUpdate=function(){},t.prototype.sendLayerBackward=function(e){this.layerObjectUpdate(),this.commandHandler.sendLayerBackward(e)},t.prototype.bringLayerForward=function(e){this.layerObjectUpdate(),this.commandHandler.bringLayerForward(e)},t.prototype.cloneLayer=function(e){this.commandHandler.cloneLayer(e)},t.prototype.bringToFront=function(){this.commandHandler.bringToFront()},t.prototype.moveForward=function(){this.commandHandler.sendForward()},t.prototype.sendBackward=function(){this.commandHandler.sendBackward()},t.prototype.getObject=function(e){return this.nameTable[""+e]},t.prototype.getNodeObject=function(e){return $(this.nameTable[""+e])},t.prototype.getConnectorObject=function(e){return $(this.nameTable[""+e])},t.prototype.getActiveLayer=function(){return this.activeLayer},t.prototype.nudgeCommand=function(e,i,r){if("object"!=typeof e&&(this.selectedItems.nodes.length||this.selectedItems.connectors.length)>0){var s=void 0;i.type&&"KEYDOWN"===i.type&&(s=i.type),this.nudge(e,void 0,void 0,s)}},t.prototype.nudge=function(e,i,r,s){var o=0,a=0;"Left"===e||"Right"===e?o=("Left"===e?-1:1)*(i||1):a=("Up"===e?-1:1)*(r||1),"KEYDOWN"===s&&(o*=5,a*=5);var h=this.selectedItems,c=this.selectedItems.wrapper.children[0];if(c instanceof li)this.commandHandler.labelDrag(h.nodes[0],c,o,a);else{var d=$(this.selectedItems);this.protectPropertyChange(!0),this.drag(h,o,a),this.protectPropertyChange(!1);var u={type:"PositionChanged",redoObject:$(this.selectedItems),undoObject:d,category:"Internal"};this.addHistoryEntry(u)}this.refreshCanvasLayers()},t.prototype.insertBlazorDiagramObjects=function(e){},t.prototype.drag=function(e,i,r){if(this.insertBlazorDiagramObjects(e),!(this.bpmnModule&&e instanceof te&&this.bpmnModule.updateAnnotationDrag(e,this,i,r))){if(e instanceof ti){if(this.preventConnectorsUpdate=!0,e.nodes&&e.nodes.length){for(var o=0,a=e.nodes;o0&&o.nodes[0].children){this.fromUndo||(this.rotateUsingButton=!0);for(var h=this.commandHandler.getAllDescendants(o.nodes[0],[]),c=0;c0&&o.nodes[0].children){var g={type:"RotationChanged",redoObject:$(e),undoObject:$(o),category:"Internal",childTable:a};this.commandHandler.addHistoryEntry(g),this.commandHandler.updateSelector()}return u},t.prototype.dragSourceEnd=function(e,i,r){this.insertBlazorDiagramObjects(e),this.commandHandler.dragSourceEnd(e,i,r),this.callBlazorModel&&this.commandHandler.getBlazorOldValues()},t.prototype.dragTargetEnd=function(e,i,r){this.insertBlazorDiagramObjects(e),this.commandHandler.dragTargetEnd(e,i,r),this.callBlazorModel&&this.commandHandler.getBlazorOldValues()},t.prototype.findObjectsUnderMouse=function(e,i){return this.eventHandler.findObjectsUnderMouse(e,i)},t.prototype.findObjectUnderMouse=function(e,i,r){return this.eventHandler.findObjectUnderMouse(e,i,r)},t.prototype.findTargetObjectUnderMouse=function(e,i,r,s,o){return this.eventHandler.findTargetUnderMouse(e,i,r,s,o)},t.prototype.findElementUnderMouse=function(e,i,r,s){return this.eventHandler.findElementUnderMouse(e,i,r,s)},t.prototype.findActionToBeDone=function(e,i,r,s){return this.eventHandler.findActionToBeDone(e,i,r,s)},t.prototype.updateConnectorPort=function(e){if(e.ports.length)for(var i=void 0,r=0,s=e.ports;r=0;s--)if(i.push(r[parseInt(s.toString(),10)]),i.length>this.historyManager.stackLimit)return i}else i=r;return i},t.prototype.getEdges=function(e){return e.outEdge?this.nameTable[e.id].outEdges:this.nameTable[e.id].inEdges},t.prototype.getParentId=function(e){return this.nameTable[""+e].parentId},t.prototype.addConnector=function(e){return this.add(e)},t.prototype.UpdateBlazorDiagramModelCollection=function(e,i,r,s){},t.prototype.UpdateBlazorDiagramModel=function(e,i,r,s){},t.prototype.UpdateBlazorLabelOrPortObjects=function(e,i,r,s){},t.prototype.addBlazorDiagramObjects=function(){},t.prototype.removeNodeEdges=function(e,i,r){var s=this.nameTable[""+e],o=r?s.outEdges:s.inEdges;if(o.length>0)for(var a=0;a0)){for(var c=0;c0))}this.removePortEdges(l,a.element.sourcePortID,a.element.id,h)}a.element.targetID&&this.removeNodeEdges(a.element.targetID,a.element.id,!1)}}this.diagramActions=this.diagramActions|ee.PublicMethod,e.id=e.id||Qe();var u=this.activeLayer;if(!a.cancel&&u&&!u.lock){if(u.objects.indexOf(e.id)<0&&!u.lock&&(u.visible||(u.visible=!0,this.dataBind()),u.objects.push(e.id)),ps(e)===de)(r=new de(this,"connectors",e,!0)).status="New",this.nameTable[r.targetID]&&"TextAnnotation"===this.nameTable[r.targetID].shape.shape&&(r.isBpmnAnnotationConnector=!0,r.constraints=r.constraints&~qe.Delete),Ro(r,e,this.connectorDefaults),this.connectors.push(r),this.initObject(r),!1===e.visible&&this.updateElementVisibility(r.wrapper,r,e.visible),this.updateEdges(r),this.insertBlazorConnector(r);else{if(Ro(r=new te(this,"nodes",e,!0),e,this.nodeDefaults),r.parentId=e.parentId?e.parentId:r.parentId,r.umlIndex=e.umlIndex,r.status="New",(o="TextAnnotation"===r.shape.shape)&&!e.isTextAnnotationCopied&&(r.inEdges=e.inEdges?e.inEdges:r.inEdges),this.nodes.push(r),this.initObject(r,u,void 0,i),o&&this.bpmnModule)for(c=0;c-1&&e.parentId&&this.nameTable[e.parentId]&&"UmlClassifier"===this.nameTable[e.parentId].shape.type){var g=this.nameTable[e.parentId];g.children.splice(r.umlIndex,0,r.id),g.wrapper.children.splice(r.umlIndex,0,r.wrapper),g.wrapper.measure(new me),g.wrapper.arrange(g.wrapper.desiredSize),this.updateDiagramObject(g)}}if(a={element:r,cause:this.diagramActions,diagramAction:this.getDiagramAction(this.diagramActions),state:"Changed",type:"Addition",cancel:!1},this.parentObject&&(a.parentId=this.parentObject.id),"helper"!==e.id&&!(this.diagramActions&ee.PreventCollectionChangeOnDragOver)&&this.triggerEvent(Ce.collectionChange,a),!(this.diagramActions&ee.UndoRedo||this.diagramActions&ee.Group||this.diagramActions&ee.PreventHistory)){var v={type:"CollectionChanged",changeType:"Insert",undoObject:$(e),redoObject:$(e),category:"Internal"};this.addHistoryEntry(v)}this.parentObject=void 0,"SVG"===this.mode&&(this.updateSvgNodes(r),this.updateTextElementValue(r),this.updateDiagramObject(r),o&&this.updateDiagramObject(this.nameTable[r.inEdges[0]]),r.shape.activity&&r.shape.activity.subProcess.processes&&r.shape.activity.subProcess.processes.length&&this.updateProcesses(r),this.updateBridging())}}if(this.protectPropertyChange(s),this.resetDiagramActions(ee.PublicMethod),r&&this.layers.length>1&&this.moveNode(r),this.views)for(var S=0,b=this.views;S=0;l--)this.moveSvgNode(a[parseInt(l.toString(),10)])}for(var h=0,c=i;h=0;o--)r[parseInt(o.toString(),10)]===e.id&&r.splice(o,1);for(var a=0;s.ports&&a=0;s--)if(i=this.nameTable[r[parseInt(s.toString(),10)]])if(this.connectorTable[i.id]=$(i),i.isBpmnAnnotationConnector){var o=this.nameTable[i.targetID];this.removeObjectsFromLayer(i);var a=this.connectors.indexOf(i);-1!==a&&this.connectors.splice(a,1),this.removeElements(i),this.removeFromAQuad(i),delete this.nameTable[i.id];var l=this.nameTable[i.sourceID];if(l){var h=l.outEdges.indexOf(i.id);-1!==h&&l.outEdges.splice(h,1)}e.id!==i.targetID&&this.remove(o)}else this.remove(i)},t.prototype.removeObjectsFromLayer=function(e){if(e.children)for(var i=0;i-1&&(_r(this,e)&&this.unSelect(e),this.layers[parseInt(s.toString(),10)].objects.splice(a,1),delete this.layers[parseInt(s.toString(),10)].zIndexTable[this.nameTable[e.id].zIndex])},t.prototype.removeElements=function(e){if("SVG"===this.mode||"Canvas"===this.mode&&"Native"===e.shape.type){var i=xt(e.id+"_groupElement",this.element.id),r=e;if(r.ports&&r.ports.length>0)for(var s=0;s0){l[parseInt(s.toString(),10)].id.indexOf("icon_content")>0&&"SVG"===this.mode&&((h=xt(l[parseInt(s.toString(),10)].id+"_shape_groupElement",this.element.id))&&h.parentNode.removeChild(h),(h=xt(l[parseInt(s.toString(),10)].id+"_rect_groupElement",this.element.id))&&h.parentNode.removeChild(h));for(var c=0,d=this.views;c=0;o--)a.children[parseInt(o.toString(),10)].children&&(l=n.nameTable[a.children[parseInt(o.toString(),10)].id])&&(l.isLane?qv(n,l):(n.removeDependentConnector(l),n.diagramActions|=ee.PreventHistory,l.constraints&ie.Delete?n.remove(l):V3(n,l,{},!1),n.diagramActions&=~ee.PreventHistory));a&&(i=n.nameTable[a.id])&&qv(n,i)}}(this,e),!(this.diagramActions&ee.UndoRedo||this.diagramActions&ee.PreventHistory)&&(e instanceof te||e instanceof de)){var o={type:"CollectionChanged",changeType:"Remove",undoObject:$(e),redoObject:$(e),category:"Internal"};this.diagramActions&ee.Clear||e.children&&!e.isLane&&!e.isPhase&&e.children.length>0&&this.undoRedoModule&&"None"===this.layout.type&&(this.historyManager.startGroupAction(),s=!0),(e instanceof te||e instanceof de)&&this.deleteDependentConnector&&this.removeDependentConnector(e),!e.isLane&&!e.isPhase&&!(this.diagramActions&ee.Clear)&&!this.isStackChild(e)&&this.addHistoryEntry(o)}"TextAnnotation"===e.shape.shape&&this.removeDependentConnector(e),e.children&&!e.isLane&&!e.isPhase&&(!(this.diagramActions&ee.UndoRedo)||!ce())&&this.deleteGroup(e),e.parentId&&(this.deleteChild(e,void 0,!0),this.nameTable[e.parentId]&&"UmlClassifier"===this.nameTable[e.parentId].shape.type&&(this.updateDiagramObject(this.nameTable[e.parentId]),this.updateConnectorEdges(this.nameTable[e.parentId])));var a=void 0;this.diagramActions=this.diagramActions|ee.PublicMethod;var l=this.nameTable[e.id];if(l instanceof te?("Bpmn"===l.shape.type&&this.bpmnModule&&this.bpmnModule.removeBpmnProcesses(l,this),(l.isLane||l.isPhase||"SwimLane"===l.shape.type)&&(h=l.isLane||l.isPhase?this.nameTable[l.parentId]:this.nameTable[l.id],l.isLane?_3(this,l,h):l.isPhase&&U3(this,l,h)),-1!==(a=this.nodes.indexOf(l))&&(this.crudDeleteNodes.push(this.nameTable[l.id]),this.nodes.splice(a,1),this.updateNodeEdges(l))):(-1!==(a=this.connectors.indexOf(l))&&(this.crudDeleteNodes.push(this.nameTable[l.id]),this.connectors.splice(a,1)),this.updateEdges(l),this.spliceConnectorEdges(e,!0),this.spliceConnectorEdges(e,!1)),!this.isServerUpdate&&!(this.blazorActions&on.GroupClipboardInProcess)&&this.commandHandler.getBlazorOldValues(),s&&this.historyManager.endGroupAction(),_r(this,l)&&this.unSelect(l),!l.isPhase){if(this.removeObjectsFromLayer(e),this.currentDrawingObject&&(this.currentDrawingObject.wrapper=void 0),delete this.nameTable[e.id],i.length>0&&i[0].id===l.id&&l.parentId){var h,d=this.nameTable[l.parentId];d&&d.isLane&&"SwimLane"===this.nameTable[d.parentId].shape.type&&F3(this,h=this.nameTable[d.parentId],d,l)}this.removeElements(l),this.updateBridging(),"SVG"!==this.mode&&this.refreshDiagramLayer(),this.diagramActions&ee.Clear||(this.removeFromAQuad(l),r={element:e,cause:this.diagramActions,diagramAction:this.getDiagramAction(this.diagramActions),state:"Changed",type:"Removal",cancel:!1},"helper"!==e.id&&this.triggerEvent(Ce.collectionChange,r),this.resetTool())}}}else if(i.length>0){this.undoRedoModule&&(this.historyManager.startGroupAction(),this.blazorActions|=on.GroupingInProgress,s=!0);for(var u=0;u=p.wrapper.bounds.width&&"Horizontal"===p.shape.orientation||this.selectedItems.wrapper.bounds.y<=p.wrapper.bounds.y+g&&this.selectedItems.wrapper.bounds.height>=p.wrapper.bounds.height-g&&"Vertical"===p.shape.orientation)&&(NI(p)||p.shape.lanes.length>1)&&this.remove(i[parseInt(u.toString(),10)])}}else this.remove(i[parseInt(u.toString(),10)])}s&&(this.blazorActions&=~on.GroupingInProgress,this.isServerUpdate=!0,this.commandHandler.getBlazorOldValues(),this.UpdateBlazorDiagramModelCollection(void 0,void 0,void 0,!0),this.historyManager.endGroupAction(),this.isServerUpdate=!1),this.clearSelection()}e&&(NI(e)||this.diagramActions&ee.Clear)||this.diagramActions&ee.UndoRedo||this.diagramActions&ee.PreventHistory||!(e instanceof te||e instanceof de)||(o={type:"ConnectionChanged",undoObject:$(e),redoObject:$(e),category:"Internal"},!e.isLane&&!e.isPhase&&!(this.diagramActions&ee.Clear)&&!this.isStackChild(e)&&this.addHistoryEntry(o)),this.tooltipObject.close()},t.prototype.isStackChild=function(e){var i,r=this.nameTable[e.parentId];if(e&&e.parentId&&r.container&&"Stack"===r.container.type&&"UmlClassifier"!==this.nameTable[e.parentId].shape.type){i=!0;var s={sourceIndex:r.wrapper.children.indexOf(e.wrapper),source:e,target:void 0,targetIndex:void 0};this.diagramActions&ee.UndoRedo||this.addHistoryEntry({type:"StackChildPositionChanged",redoObject:{sourceIndex:void 0,source:e,target:void 0,targetIndex:void 0},undoObject:s,category:"Internal"})}return i},t.prototype.deleteChild=function(e,i,r){var s;if(s="string"==typeof e?e:e.id,(i=i?this.nameTable[i.id]:this.nameTable[e.parentId])&&i.children){for(var o=0;o=0;i--)this.removeLayer(this.layers[parseInt(i.toString(),10)].id);this.commandHandler.addLayer({id:"default_layer",visible:!0,lock:!1,objects:[],zIndex:0,objectZIndex:-1,zIndexTable:{}},null,!0),this.setActiveLayer(this.layers[this.layers.length-1].id)},t.prototype.clearObjects=function(e){var i=[];i=e||(i=i.concat(this.nodes)).concat(this.connectors),this.diagramActions=this.diagramActions|ee.Clear;for(var r=0,s=i;r0||"Text"===e.shape.type))if("Text"===e.shape.type)i=e.wrapper.children[0].id.split("_")[1];else for(var p=e.annotations.length-1;p>=0;p--)e.annotations[parseInt(p.toString(),10)].visibility&&(i=e.annotations[parseInt(p.toString(),10)].id);i&&(u=this.getWrapper(e.wrapper,i))}if(e&&u&&!(u instanceof es)&&(!function $re(n,t){return"Text"===t.shape.type?t.constraints&ie.ReadOnly:t.constraints&(t instanceof de?qe.ReadOnly:ie.ReadOnly)?n.constraints&Nr.InheritReadOnly?1:0:n.constraints&Nr.ReadOnly?1:0}(u,e)||f)){var g=u.style,v=void 0;v=90>(v=u.bounds.width50?50:e.width,u.style.fontSize)),e.parentId&&"UmlClassifier"===this.nameTable[e.parentId].shape.type?(l.width=e.wrapper.bounds.width-20,c=(e.wrapper.bounds.center.x+r.tx)*r.scale-l.width/2*s-2.5,d=(e.wrapper.bounds.center.y+r.ty)*r.scale-l.height/2*s-3,u.style.textAlign="Left"):(l.width=Math.max(l.width,50),c=(u.bounds.center.x+r.tx)*r.scale-l.width/2*s-2.5,d=(u.bounds.center.y+r.ty)*r.scale-l.height/2*s-3),Ho(y,{id:this.element.id+"_editTextBoxDiv",style:"position: absolute;left:"+c+"px;top:"+d+"px;width:"+(l.width+1)*s+"px;height:"+l.height*s+"px; containerName:"+e.id+";"}),Ho(S,{"aria-label":a,id:this.element.id+"_editBox",style:"width:"+(l.width+1)*s+"px;height:"+l.height*s+"px;resize: none;outline: none;overflow: hidden;;font-family:"+g.fontFamily+";font-size:"+g.fontSize*s+"px;text-align:"+u.style.textAlign.toLocaleLowerCase()+";",class:"e-diagram-text-edit"}),S.style.fontWeight=g.bold?"bold":"",S.style.fontStyle=g.italic?"italic":"",S.style.lineHeight=(1.2*g.fontSize+"px;").toString(),S.style.textDecoration=g.textDecoration?g.textDecoration:"",this.activeLabel.parentId=e.id,this.activeLabel.id=i,u.visible=!1,this.updateDiagramObject(e),this.diagramActions=this.diagramActions|ee.TextEdit,this.isTriggerEvent||(E.add(S,"input",this.eventHandler.inputChange,this.eventHandler),E.add(S,"focusout",this.focusOutEdit,this),S.select())}}}},t.prototype.updateConnectorfixedUserHandles=function(e){if(e.fixedUserHandles.length)for(var i=void 0,r=0,s=e.fixedUserHandles;r0&&this.mindMapChartModule.updateLayout(o,this.nameTable,this.layout,l,this.dataSourceSettings.id,this.dataSourceSettings.root),e=!0;else if(this.radialTreeModule)this.radialTreeModule.updateLayout(o,this.nameTable,this.layout,l),e=!0;else if(this.symmetricalLayoutModule)this.symmetricalLayoutModule.maxIteration=this.layout.maxIteration,this.symmetricalLayoutModule.springLength=this.layout.springLength,this.symmetricalLayoutModule.springFactor=this.layout.springFactor,this.symmetricalLayoutModule.updateLayout(o,this.connectors,this.symmetricalLayoutModule,this.nameTable,this.layout,l),e=!0;else if(this.complexHierarchicalTreeModule){this.canDistribute(a,r)&&(this.lineDistributionModule.diagram=this,this.connectors.forEach(function(P){P.obstaclePointCollection=[]}));var c=this.complexHierarchicalTreeModule.getLayoutNodesCollection(this.nodes);c.length>0&&this.complexHierarchicalTreeModule.doLayout(c,this.nameTable,this.layout,l,this),e=!0,this.canDistribute(a,r)&&this.lineDistributionModule.initLineDistribution(this.layout,this)}else this.flowchartLayoutModule?(this.flowchartLayoutModule.updateLayout(this.nodes,this),e=!0):console.warn("[WARNING] :: Module "+("OrganizationalChart"===this.layout.type?"HierarchicalTree":this.layout.type)+" is not available in Diagram component! You either misspelled the module name or forgot to load it.");if(e){this.preventDiagramUpdate=!0;for(var u={},p=0,g=o;p0)for(var S=0;S0)for(var M=0;M0)for(var s=0,o=r.ports;s0&&function xse(n){var t,e,i,r=[];for(t=0;t0&&y.connectors[w].bezierSettings&&y.connectors[w].bezierSettings.allowSegmentsReset&&(y.connectors[w].segments=[]);if(t.connectors=y.connectors||[],t.dataSourceSettings=y.dataSourceSettings||{},t.dataSourceSettings.doBinding=i,t.height=y.height||"100%",t.setNodeTemplate=r,t.getConnectorDefaults=v,t.getNodeDefaults=g,t.getCustomProperty=o,t.mode=y.mode||"SVG",y.nodes)for(w=0;w0)){var r=this.nodes.filter(function(a){return 0===a.inEdges.length})[0],s=this.convertMindmapToMermaid(r,0);i.push(s),this.updateTextDataSource(i,r.outEdges,1),e=(i=i.filter(function(a){return""!==a.trim()})).join("\n")}return e},t.prototype.updateTextDataSource=function(e,i,r){for(var s=0;s0&&this.updateTextDataSource(e,h,r+1),s++}},t.prototype.convertMindmapToMermaid=function(e,i){var r=e.id,o=" ".repeat(2*(i+1)),a=e.annotations.length>0?e.annotations[0].content.replace(/\n/g," "):"",l=o+a,h=o+r;if(e.shape&&"Basic"===e.shape.type){var c=e.shape;"Rectangle"===c.shape?l=h+"["+a+"]":"Ellipse"===c.shape?l=h+"(("+a+"))":"Hexagon"===c.shape&&(l=h+"{{"+a+"}}")}else if(e.shape&&"Flow"===e.shape.type)"Terminator"===e.shape.shape&&(l=h+"("+a+")");else if(e.shape&&"Path"===e.shape.type){var u=e.shape;u.data===this.bangShape?l=h+"))"+a+"((":u.data===this.cloudShape&&(l=h+")"+a+"(")}return l},t.prototype.saveFlowDiagramInMermaidFormat=function(){var e=this,i=[],r="graph TD\n",s={nodes:this.nodes,edges:this.connectors};return s.nodes.reduce(function(a,l){return a[l.id]=l.annotations.length?l.annotations[0].content:"",a},{}),s.edges.forEach(function(a){var l=a.sourceID,h=a.targetID,f=e.nameTable[""+h],p=e.getNodeShape(e.nameTable[""+l]),g=e.getNodeShape(f),v=a.annotations[0]&&""!==a.annotations[0].content?"|"+a.annotations[0].content+"|":"";-1===i.indexOf(l)?i.push(l):p="",-1===i.indexOf(h)?i.push(h):g="";var y=e.arrowType(a);r+=" "+l+p+" "+y+v+" "+h+g+"\n"}),s.nodes.forEach(function(a){r+=" style "+a.id+" fill:"+a.style.fill+",stroke:"+a.style.strokeColor+",stroke-width:"+a.style.strokeWidth+"px;\n"}),r},t.prototype.arrowType=function(e){var i=e.targetDecorator.shape;return e.style.opacity<1?"~~~":""!==e.style.strokeDashArray?"-.->":"Arrow"===i?e.style.strokeWidth>1?"==>":"--\x3e":"None"===i?"---":"--\x3e"},t.prototype.getNodeShape=function(e){var i=e.annotations.length>0?e.annotations[0].content:"",r=e.shape.shape;if(!r){var s=e.shape.data;return"M 0 0 A 1 1 0 0 0 7 0 A 1 1 0 0 0 0 0 M -1 0 A 1 1 0 0 0 8 0 A 1 1 0 0 0 -1 0"===s?"((("+i+")))":"M 0 0 L 1 -1 L 5 -1 L 6 0 L 0 0"===s?"[/"+i+"\\]":"M 0 1 L 0 6 C 2 7 4 7 6 6 L 6 1 C 5 0 1 0 0 1 C 1 2 5 2 6 1"===s?"[("+i+")]":"M 0 0 L 12 0 L 14 2 L 2 2 L 0 0"===s?"[\\"+i+"\\]":"M 0 0 L 5 0 L 4 1 L 1 1 L 0 0"===s?"[\\"+i+"/]":"M 0 0 L 2 -2 L 11 -2 L 13 0 L 11 2 L 2 2 L 0 0"===s?"{{"+i+"}}":">"+i+"]"}switch(r){case"Terminator":return"(["+i+"])";case"Process":default:return"["+i+"]";case"Decision":return"{"+i+"}";case"Parallelogram":return"[/"+i+"/]";case"Ellipse":return"(("+i+"))";case"PreDefinedProcess":return"[["+i+"]]"}},t.prototype.loadDiagramFromMermaid=function(e){this.layout&&"Flowchart"===this.layout.type&&this.flowchartLayoutModule?this.convertMermaidToFlowChart(e):this.layout&&"MindMap"===this.layout.type&&this.mindMapChartModule?this.convertMermaidToMindmap(e):console.warn('[WARNING] :: Module "FlowchartLayout" or "MindMap" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.countLeadingSpaces=function(e){for(var i=0,r=e.length;i0});this.clear(),this.mermaidNodeBaseCollection=[];var r=[],s={text:"",children:[],currentLevel:0,branch:"Left"},o=[],l=!1,h=!1,c=!1;if(i.length>0){for(var d=function(M){var w=i[parseInt(M.toString(),10)],C=0,D="",A=u.countLeadingSpaces(w),x=w.includes('"`');if(h=w.includes('`"'),c=(l=!!x||l)||c?c:0===A&&M>0,l&&h&&!x)return s.text+="\n"+w,l=!1,"continue";if(!x&&l)return s.text+="\n"+w,"continue";if(l=!h&&l,w.length>0&&(/\s/.test(w[0])&&M>0||0===A)){if(-1!==o.findIndex(function(B){return B.space===A.toString()}))for(var L=o.length-1;L>=0;L--){var O=o[parseInt(L.toString(),10)];if((N=parseFloat(O.space))>A)o.splice(L,1);else{if(N=0;L--){var N,T=o[parseInt(L.toString(),10)];if(!((N=parseFloat(T.space))>A)){var z=o[o.length-1];o.push({space:A.toString(),level:z.level+1});break}o.splice(L,1)}C=o[o.length-1].level}D=w.trim().replace(/^[+-]/,"")}var U={text:D,branch:void 0,children:[],currentLevel:0===M?0:C-1};if(r.length>0){for(;r.length>=C&&0!==r.length;)r.pop();r.length>0&&r[r.length-1].children.push(U)}r.push(U),s=U},u=this,f=0;f0){var c=h[h.length-1];c.arrowType=a[2],""!==a[3]&&(c.label&&c.label.some(function(d){return d.trim().length>0})?c.label.push(a[3]):(c.label=[],c.label[c.parentId.length-1]=a[3]))}h.filter(function(d){return d.parentId&&0===d.parentId.length}).forEach(function(d){d.parentId=null}),i=i.concat(h)}}this.createFlowChart(i),this.doLayout(),this.clearHistory()},t.prototype.createFlowChart=function(e){for(var i=[],r=0;r1)for(var h=0;h|---|--\s*.*?\s*-->|~~~|==>|===|==\s*.*?\s*==>|\s*-\.\s*->|\s*-\.\s*-|\s*-\.\s*.*?\s*\.\s*->|\s*-\..*?\.\s*->)(.*)$/);if(l){i=l[1].trim();var h=l[2].trim();r=l[3].trim();var d=h.match(/(-\.|\\-\\-|==|--|~~)(.*?)(\1>|\.->|==>|\\->|~~>)/),u=void 0,f="";o=null!==(u=d?{text:d[2].trim()||null,arrowType:d[1]+d[3]}:{text:null,arrowType:h}).text?u.text:"",s=(f=u.arrowType).includes("--\x3e")?"single-line-arrow":f.includes("---")?"single-line":f.includes("==>")?"double-line-arrow":f.includes("==")?"double-line":f.includes("~~~")?"wiggly-arrow":f.includes("-.->")||f.includes(".->")?"dotted-arrow":f.includes("-.-")||f.includes(".-")?"dotted":"single-line-arrow"}return[i,r,s,o]},t.prototype.parseStyle=function(e,i){if(e.startsWith("style")){var s=e.match(/^style\s+(\w+)\s+fill:([^,]+),stroke:([^,]+),stroke-width:(\d+)px;/);if(s){var c={id:s[1],fill:s[2],stroke:s[3],strokeWidth:parseInt(s[4],10)},d=i.filter(function(u){return u.id===c.id});d[0].color=c.fill,d[0].stroke=c.stroke,d[0].strokeWidth=c.strokeWidth}}},t.prototype.getNodeData=function(e,i,r){for(var s=[],o=null,a=null,l=0,h="",c=function(v){var y=e[parseInt(v.toString(),10)],S=d.splitNested(y);if(S[0].includes("|")){var b=S[0].match(/\|([^|]*)\|/);b&&(h=b[1]);var M=S[0].split("|");M.length>=3&&(S[0]=M[2].trim())}var w=S[0].trim();if(0===v?o=w:a=w,i.find(function(L){return L.id===w}))l++;else{var D=S.length>1?S[1]:S[0],A=d.getShape(D),x=D.replace(/[\\[\]\\(\\)\\{\\}\\{\\}\\/>]/g,"");s.push({id:w,name:x,shape:A,color:"white",parentId:[]})}},d=this,u=0;u"===h?0===s?(r.trim().length>0&&i.push(r.trim()),r=h,o=h,s++):(r+=h,s++):"]"===h||"}"===h||")"===h?1===s&&h===o?(i.push((r+=h).trim()),r="",s--):s>1?(r+=h,s--):r+=h:r+=h}return r.trim().length>0&&i.push(r.trim()),i},t.prototype.getShape=function(e){var i={};return e.startsWith("(((")?i={type:"Path",data:"M 0 0 A 1 1 0 0 0 7 0 A 1 1 0 0 0 0 0 M -1 0 A 1 1 0 0 0 8 0 A 1 1 0 0 0 -1 0"}:e.startsWith("((")?i={shape:"Ellipse",type:"Basic"}:e.startsWith("([")?i={type:"Flow",shape:"Terminator"}:e.startsWith("(")?i={type:"Flow",shape:"Process"}:e.startsWith("[[")?i={type:"Flow",shape:"PreDefinedProcess"}:e.startsWith("[/")?i=e.endsWith("/]")?{type:"Basic",shape:"Parallelogram"}:{type:"Path",data:"M 0 0 L 1 -1 L 5 -1 L 6 0 L 0 0"}:e.startsWith("[(")?i={type:"Path",data:"M 0 1 L 0 6 C 2 7 4 7 6 6 L 6 1 C 5 0 1 0 0 1 C 1 2 5 2 6 1"}:e.startsWith("[\\")?i=e.endsWith("\\]")?{type:"Path",data:"M 0 0 L 12 0 L 14 2 L 2 2 L 0 0"}:{type:"Path",data:"M 0 0 L 5 0 L 4 1 L 1 1 L 0 0"}:e.startsWith("[")?i={type:"Basic",shape:"Rectangle"}:e.startsWith("{{")?i={type:"Path",data:"M 0 0 L 2 -2 L 11 -2 L 13 0 L 11 2 L 2 2 L 0 0"}:e.startsWith("{")?i={type:"Flow",shape:"Decision"}:e.startsWith(">")&&(i={type:"Path",data:"M 0 0 L 8 0 L 8 2 L 0 2 L 2 1 L 0 0"}),i},t.prototype.getDiagramContent=function(e){return this.printandExportModule?this.printandExportModule.getDiagramContent(e):(console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),"")},t.prototype.exportImage=function(e,i){this.printandExportModule?this.printandExportModule.exportImages(e,i):console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.printImage=function(e,i){this.printandExportModule?(i.printOptions=!0,this.printandExportModule.exportImages(e,i)):console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.setStackLimit=function(e){this.undoRedoModule&&e&&(this.historyManager.stackLimit=e,this.undoRedoModule.applyLimit(this.historyManager.currentEntry,e,this,!0))},t.prototype.clearHistory=function(){this.undoRedoModule&&this.undoRedoModule.clearHistory(this)},t.prototype.getDiagramBounds=function(){if(this.printandExportModule){var e=this.printandExportModule.getDiagramBounds("",{});return e.width=e.width>this.scrollSettings.viewPortWidth?e.width+(e.x>0?e.x:0):this.scrollSettings.viewPortWidth,e.height=e.height>this.scrollSettings.viewPortHeight?e.height+(e.y>0?e.y:0):this.scrollSettings.viewPortHeight,e.x=e.x>0?0:e.x,e.y=e.y>0?0:e.y,e}return console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),new Ne},t.prototype.exportDiagram=function(e){return this.printandExportModule?this.printandExportModule.exportDiagram(e):(console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),"")},t.prototype.print=function(e){this.printandExportModule?this.printandExportModule.print(e):console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.addPorts=function(e,i){var s;this.protectPropertyChange(!0),e=this.nameTable[e.id]||e,i.length>1&&this.startGroupAction();for(var o=function(h){if(e.ports.some(function(y){return y.id===i[parseInt(h.toString(),10)].id}))return"continue";if(e instanceof te?(s=new Es(e,"ports",i[parseInt(h.toString(),10)],!0),e.ports.push(s)):e instanceof de&&(s=new Tc(e,"ports",i[parseInt(h.toString(),10)],!0),e.ports.push(s)),e.children)for(var c=e.wrapper,d=0;d1&&this.endGroupAction(),e.wrapper.measure(new me(e.width,e.height)),e.wrapper.arrange(e.wrapper.desiredSize),this.updateDiagramObject(e),this.protectPropertyChange(!1)},t.prototype.addConstraints=function(e,i){return e|i},t.prototype.removeConstraints=function(e,i){return e&~i},t.prototype.addNodeLabels=function(e,i){this.addLabels(e,i)},t.prototype.addConnectorLabels=function(e,i){this.addLabels(e,i)},t.prototype.addLabels=function(e,i){this.protectPropertyChange(!0);var s,r=(e=this.nameTable[e.id]||e).wrapper;i.length>1&&this.startGroupAction();for(var o=0;o1&&this.endGroupAction(),e.wrapper.measure(new me(r.width,r.height)),e.wrapper.arrange(r.desiredSize),this.updateDiagramObject(e),this.protectPropertyChange(!1),this.refreshCanvasLayers()},t.prototype.addChildToUmlNode=function(e,i,r){var s,o,a,l,h="NoWrap";"Class"===e.shape.classifier||"Interface"===e.shape.classifier?"Method"===r?(o=new cm(e,"",i),"Class"===e.shape.classifier?(e.shape.classShape.methods.push(o),s=e.shape.classShape):"Interface"===e.shape.classifier&&(e.shape.interfaceShape.methods.push(o),s=e.shape.interfaceShape),function $se(n,t,e,i){if(e.methods&&e.methods.length){var r=e.methods,s="",o="",a=void 0,l=1,h=void 0,c=0,d=0,u=n.shape,g="Class"===u.classifier?u.classShape:u.interfaceShape;1===r.length?g.attributes.length>0?(c=g.attributes.filter(function(w){return w.isSeparator}).length,h=(l=2+g.attributes.length+c)+1,oT(n,t,l)):h=l+1:(c=g.attributes.filter(function(w){return w.isSeparator}).length,d=g.methods.filter(function(w){return w.isSeparator}).length,h=(l=2+g.attributes.length+c+g.methods.length+d)+1);for(var v=0;v1&&this.startGroupAction();for(var r=i.length-1;r>=0;r--)if(e.children&&e.children.length>0){var s=e.wrapper.children.filter(function(o){return o.id===e.id+"group_container"});s&&s.length>0&&this.removelabelExtension(e,i,r,s[0])}else this.removelabelExtension(e,i,r,e.wrapper);i.length>1&&this.endGroupAction(),this.refreshCanvasLayers()},t.prototype.removePortsExtenion=function(e,i,r,s){for(var o=0;o1&&this.startGroupAction();for(var r=i.length-1;r>=0;r--)if(e.children&&e.children.length>0)for(var s=0;s1&&this.endGroupAction()},t.prototype.getSizeValue=function(e,i){var r;return r=e.toString().indexOf("px")>0?e.toString():e.toString().indexOf("%")>0?void 0!==i?"100%":e.toString():e.toString()+"px",i&&(Za(this),r="calc("+r+" - "+i+"px)"),r},t.prototype.renderRulers=function(){this.rulerSettings.showRulers?(function Gne(n){var t=Za(n),i=Tt("div",{id:n.element.id+"_overlapRuler",style:"height:"+t.height+"px;width:"+t.width+"px;position:absolute;left:0;top:0",class:"e-ruler-overlap"});n.element.insertBefore(i,n.element.firstChild)}(this),eF(this,!0),eF(this,!1)):Xx(this)},t.prototype.intOffPageBackground=function(){var e=new me;e=Za(this);var i=document.getElementById(this.element.id+"content"),r=this.getSizeValue(this.width,e.width),s=this.getSizeValue(this.height,e.height),o=this.rulerSettings.showRulers?"width:"+r+"; height:"+s+";top:"+e.height+"px;left:"+e.width+"px;overflow: scroll;position:absolute;overflow:auto;":"width:"+r+"; height:"+s+";position:absolute; left:0px; top:0px;overflow: auto;",a={id:this.element.id+"content",tabindex:"0",style:o};i?(this.diagramCanvas=i,Ka(this.diagramCanvas,o)):(this.diagramCanvas=Tt("div",a),this.element.appendChild(this.diagramCanvas)),this.diagramCanvas.style.background=this.backgroundColor},t.prototype.initDiagram=function(){this.intOffPageBackground(),Ho(this.element,{style:"width:"+this.getSizeValue(this.width)+"; height:"+this.getSizeValue(this.height)+";position:relative;overflow:hidden;"})},t.prototype.renderHiddenUserHandleTemplateLayer=function(e){var r=Tt("div",{class:this.element.id+"_hiddenUserHandleTemplate",style:"width:"+e.width+"px; height:"+e.height+"px;visibility:hidden ; overflow: hidden;"});this.element.appendChild(r)},t.prototype.renderBackgroundLayer=function(e,i){var r=this.createSvg(this.element.id+"_backgroundLayer_svg",e.width,e.height);Ka(r,i);var s=Fi("g",{id:this.element.id+"_backgroundImageLayer",class:"e-background-image-layer"});r.appendChild(s);var a=Fi("g",{id:this.element.id+"_backgroundLayer",class:"e-background-layer"});r.appendChild(a),this.diagramCanvas.appendChild(r)},t.prototype.renderGridLayer=function(e,i){var r=this.createSvg(this.element.id+"_gridline_svg",e.width,e.height);r.setAttribute("class","e-grid-layer");var s=Fi("g",{id:this.element.id+"_gridline"}),o=Fi("rect",{id:this.element.id+"_grid_rect",x:"0",y:"0",width:"100%",height:"100%"});if(sm()){var a=new URL(window.location.href);o.setAttribute("fill",""!==a.search?"url(#"+this.element.id+"_pattern)":"url("+location.protocol+"//"+location.host+location.pathname+"#"+this.element.id+"_pattern)")}else o.setAttribute("fill","url(#"+this.element.id+"_pattern)");s.appendChild(o),r.appendChild(s),this.diagramCanvas.appendChild(r),ii(r,{style:i})},t.prototype.renderDiagramLayer=function(e,i){if(this.diagramLayerDiv=Tt("div",{id:this.element.id+"_diagramLayer_div",style:"width:"+e.width+"px; height:"+e.height+"px;"+i}),"SVG"===this.mode){var s=this.createSvg(this.element.id+"_diagramLayer_svg",e.width,e.height);s.style["pointer-events"]="none",s.setAttribute("class","e-diagram-layer");var o=Fi("g",{id:this.element.id+"_diagramLayer"}),a=Fi("g",{});this.diagramLayer=o,s.style["pointer-events"]="all",a.appendChild(o),s.appendChild(a),this.diagramLayerDiv.appendChild(s)}else this.diagramLayer=bo.createCanvas(this.element.id+"_diagram",e.width,e.height),Ka(this.diagramLayer,"position:absolute;left:0px;top:0px;"),this.diagramLayerDiv.appendChild(this.diagramLayer);this.diagramCanvas.appendChild(this.diagramLayerDiv)},t.prototype.initLayers=function(){var e="position:absolute;top:0px;left:0px;overflow:hidden;pointer-events:none;",r=document.getElementById(this.element.id).getBoundingClientRect(),s=function boe(){var n=Tt("div",{style:"visibility:hidden; width: 100px"});document.body.appendChild(n);var t=n.getBoundingClientRect().width;n.style.overflow="scroll";var e=Tt("div",{style:"width:100%"});n.appendChild(e);var i=e.getBoundingClientRect().width;return n.parentNode.removeChild(n),t-i}();this.scroller.scrollerWidth=s,this.scroller.setViewPortSize(r.width,r.height),this.renderRulers();var o="measureElement";window[""+o]&&(window[""+o]=null,document.getElementById("measureElement").remove()),function BF(){var n="measureElement";if(window[""+n])window[""+n].usageCount+=1;else{var t=Tt("div",{id:"measureElement",style:"visibility:hidden ; height: 0px ; width: 0px; overflow: hidden;"}),e=Tt("span",{style:"display:inline-block ; line-height: normal"});t.appendChild(e);var i=Tt("img",{alt:"measureElementImage",src:"data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7"});t.appendChild(i);var r=document.createElementNS("http://www.w3.org/2000/svg","svg");r.setAttribute("xmlns:xlink","http://www.w3.org/1999/xlink"),t.appendChild(r);var s=document.createElementNS("http://www.w3.org/2000/svg","path");s.setAttribute("d",""),r.appendChild(s),document.createTextNode("");var a=document.createElementNS("http://www.w3.org/2000/svg","text");a.setAttributeNS("http://www.w3.org/XML/1998/namespace","xml:space","preserve"),r.appendChild(a),window[""+n]=t,window[""+n].usageCount=1,document.body.appendChild(t);var l="measureElementCount";window[""+l]?window[""+l]++:window[""+l]=1}}(),this.renderBackgroundLayer(r,e),this.renderGridLayer(r,e),this.renderDiagramLayer(r,e),this.renderHTMLLayer(r,e),this.renderPortsExpandLayer(r,e),this.renderNativeLayer(r,e),this.renderAdornerLayer(r,e),this.renderHiddenUserHandleTemplateLayer(r)},t.prototype.renderAdornerLayer=function(e,i){var r=Tt("div",{id:this.element.id+"_diagramAdornerLayer",style:"width:"+e.width+"px;height:"+e.height+"px;"+i}),s=Tt("div",{id:this.element.id+"_diagramUserHandleLayer",style:"width:"+e.width+"px;height:"+e.height+"px;"+i});s.setAttribute("class","e-userHandle-layer"),r.appendChild(s);var o=this.createSvg(this.element.id+"_diagramAdorner_svg",e.width,e.height);o.setAttribute("class","e-adorner-layer"),o.style["pointer-events"]="none",this.adornerLayer=Fi("g",{id:this.element.id+"_diagramAdorner"}),this.adornerLayer.style[" pointer-events"]="all",o.appendChild(this.adornerLayer),r.appendChild(o),this.diagramCanvas.appendChild(r);var a=Fi("g",{id:this.element.id+"_SelectorElement"});this.adornerLayer.appendChild(a),ii(o,{style:"pointer-events:none;"})},t.prototype.renderPortsExpandLayer=function(e,i){var r=this.createSvg(this.element.id+"_diagramPorts_svg",e.width,e.height);r.setAttribute("class","e-ports-expand-layer");var s=Fi("g",{id:this.element.id+"_diagramPorts",class:"e-ports-layer",style:"pointer-events: all;"});r.appendChild(s);var o=Fi("g",{id:this.element.id+"_diagramExpander",class:"e-expand-layer",style:"pointer-events: all;"});r.appendChild(o),this.diagramCanvas.appendChild(r),ii(r,{style:i})},t.prototype.renderHTMLLayer=function(e,i){this.htmlLayer=Tt("div",{id:this.element.id+"_htmlLayer",style:"width:"+e.width+"px; height:"+e.height+"px;position:absolute;top:0px;left:0px;overflow:hidden;pointer-events:none;",class:"e-html-layer"});var r=Tt("div",{id:this.element.id+"_htmlLayer_div",style:"position:absolute;top:0px;left:0px;pointer-events:all;"});this.htmlLayer.appendChild(r),this.diagramCanvas.appendChild(this.htmlLayer)},t.prototype.renderNativeLayer=function(e,i){var r=this.createSvg(this.element.id+"_nativeLayer_svg",e.width,e.height),s=Fi("g",{id:this.element.id+"_nativeLayer",style:"pointer-events:all;"});r.appendChild(s),this.diagramLayerDiv.appendChild(r),ii(r,{class:"e-native-layer",style:i})},t.prototype.createSvg=function(e,i,r){var s=document.createElementNS("http://www.w3.org/2000/svg","svg");return ii(s,{id:e,width:i,height:r}),s},t.prototype.updateBazorShape=function(){for(var e=0;e1,i=[],r={},s={},o=[],a=0,l=this.nodes;a0||b&&b.children&&b.children.length>0)&&(M=!1),S&&S.wrapper&&b&&b.wrapper&&M?this.initConnectors(r[""+h],p):i.push(r[""+h])}else b=r[y.targetID],(S=r[y.sourceID])&&S.children&&S.children.length>0||b&&b.children&&b.children.length>0?i.push(r[""+h]):this.initConnectors(r[""+h],p);else r[""+h].children?o.push(h):r[""+h].shape instanceof dT&&r[""+h].shape.activity.subProcess.processes&&r[""+h].shape.activity.subProcess.processes.length>0?s[r[""+h].id]=h:this.initNodes(r[""+h],p);if(this.bpmnModule)for(var w=0,C=this.bpmnModule.bpmnTextAnnotationConnector;w-1&&-1===r.indexOf(c)&&-1===s.indexOf(c)&&r.splice(0,0,c);-1===r.indexOf(o)&&s.push(o)}return r.concat(s)},t.prototype.addToLayer=function(e,i){var r;if(i&&(r=this.commandHandler.getObjectLayer(e.id)),(!i||!r)&&-1===this.activeLayer.objects.indexOf(e.id)&&this.activeLayer.objects.push(e.id),(e instanceof te||e instanceof de)&&("SwimLane"!==e.shape.type||e.children&&e.children.length>0)){if(e.parentId){var s=this.swimlaneZIndexTable[e.parentId],o=this.swimlaneChildTable[e.id];(s&&-1!==s||o&&-1!==o)&&(e.zIndex=this.swimlaneChildTable[e.id])}e instanceof de&&e.sourceID&&e.targetID?-1!==this.activeLayer.objects.indexOf(e.sourceID)&&-1!==this.activeLayer.objects.indexOf(e.targetID)&&this.setZIndex(r||this.activeLayer,e):this.setZIndex(r||this.activeLayer,e)}},t.prototype.updateLayer=function(e){for(var i=0,r=Object.keys(e.layers);i0)for(r=0;rs;l--)r.zIndexTable[parseInt(l.toString(),10)]=r.zIndexTable[l-1],this.nameTable[r.zIndexTable[parseInt(l.toString(),10)]]&&(this.nameTable[r.zIndexTable[parseInt(l.toString(),10)]].zIndex=l);r.zIndexTable[parseInt(a.toString(),10)]=i.id}}},t.prototype.initializeDiagramLayers=function(){for(var e=0;ethis.layers[parseInt(a.toString(),10)].zIndex&&(i=this.layers[parseInt(e.toString(),10)],this.layers[parseInt(e.toString(),10)]=this.layers[parseInt(a.toString(),10)],this.layers[parseInt(a.toString(),10)]=i);0===this.layers.length&&this.commandHandler.addLayer({id:"default_layer",visible:!0,lock:!1,objects:[],zIndex:0,objectZIndex:-1,zIndexTable:{}},null,!0),this.setActiveLayer(this.layers[this.layers.length-1].id)},t.prototype.resetTool=function(){this.eventHandler.resetTool()},t.prototype.initObjectExtend=function(e,i,r){if(r){var s=this.commandHandler.checkBoundaryConstraints(void 0,void 0,e.wrapper.bounds,!0);if("SwimLane"===e.shape.type)for(var o=0,a=Object.keys(i.zIndexTable);o0)&&this.setZIndex(i,e)),e instanceof te){if(r){if("helper"!==e.id&&(o=Zi(this.getNodeDefaults))){if((a=o(e,this))&&a.ports)for(var l=0;l0)for(l=0;l0&&!e.container||e.processId){var r=this.nameTable[e.id];if(!(this.realActions&$i.PreventScale||this.realActions&$i.PreventDrag)){if(r.offsetX&&(this.realActions&$i.EnableGroupAction||!(this.diagramActions&ee.UndoRedo||this.diagramActions&ee.ToolAction||this.diagramActions&ee.PublicMethod))){this.realActions|=$i.PreventScale;var s=r.offsetX-e.wrapper.offsetX;r.offsetX=e.wrapper.offsetX;var o=r.offsetY-e.wrapper.offsetY;r.offsetY=e.wrapper.offsetY,s+o!==0&&this.drag(r,s,o),this.realActions&=~$i.PreventScale}else r.offsetX=e.wrapper.offsetX;r.offsetY&&(this.realActions&$i.EnableGroupAction||!(this.diagramActions&ee.UndoRedo||this.diagramActions&ee.ToolAction||this.diagramActions&ee.PublicMethod))?(this.realActions|=$i.PreventScale,o=r.offsetY-e.wrapper.offsetY,r.offsetY=e.wrapper.offsetY,this.drag(r,0,o),this.realActions&=~$i.PreventScale):r.offsetY=e.wrapper.offsetY,this.diagramActions&&(r.width=e.wrapper.actualSize.width,r.height=e.wrapper.actualSize.height)}}i&&e.children&&e.children.length>0&&(void 0!==this.nameTable[e.id].width?this.scaleObject(e,this.nameTable[e.id].width,!0):this.nameTable[e.id].width=e.wrapper.actualSize.width,void 0!==this.nameTable[e.id].height?this.scaleObject(e,this.nameTable[e.id].height,!1):this.nameTable[e.id].height=e.wrapper.actualSize.height)},t.prototype.initNode=function(e,i,r){var a,f,s=e.initContainer(),o=new Mi;if(this.diagramSettings.inversedAlignment||(s.inversedAlignment=!1),s.children||(s.children=[]),e.children){s.measureChildren=!1,o.id=e.id+"group_container",o.style.fill=e.shape&&"SwimLane"===e.shape.type?e.style.fill:"none",o.style.strokeColor="none",o.horizontalAlignment="Stretch",o.verticalAlignment="Stretch",o.pivot=e.pivot,s.style=e.style,s.padding.left=e.padding.left,s.padding.right=e.padding.right,s.padding.top=e.padding.top,s.padding.bottom=e.padding.bottom,o.children=[],o.preventContainer=!0,e.container&&(o.relativeMode="Object");var l=!!(e.ports&&e.ports.length>0);if(m(e.container)&&!l&&s.children.push(o),e.container&&"Grid"===e.container.type)for(var h=0;h0&&e.wrapper.children[0]instanceof Wv){if(this.setZIndex(this.activeLayer,e),this.connectors.length>0)for(h=0;h0?i.phases.length:0,v="Horizontal"===i.orientation,y=v?i.phases.length||1:s.length+1,S=v?(i.header&&i.hasHeader?1:0)+(i.phases.length>0?1:0)+i.lanes.length:(i.header&&i.hasHeader?1:0)+i.phases.length;if(0===h&&!v&&i.lanes.length&&(S+=1),v?(a=(i.header&&i.hasHeader?1:0)+(h>0?1:0),l=0):(a=i.header&&i.hasHeader?1:0,l=h>0?1:0),s.length>0)for(o+=i.header&&i.hasHeader?i.header.height:0,f=0;fl?d.margin.left=d.margin.left-(u.bounds.left-e.bounds.left):u.children[0].children[1].actualSize.width+r>=d.margin.left&&(d.margin.left=u.children[0].children[1].actualSize.width+r),d.margin.lefta?d.margin.top=d.margin.top-(u.bounds.top-o):u.children[0].children[1].actualSize.height+r>=d.margin.top&&(d.margin.top=u.children[0].children[1].actualSize.height+r),d.margin.left0)for(o=0;o0&&this.updateChildPosition(e)},t.prototype.addBpmnAnnotationConnector=function(e,i){if(e.parentObj instanceof t||e.parentObj instanceof Fd){var r=e.shape,o=""!==r.textAnnotation.textAnnotationTarget&&this.nameTable[r.textAnnotation.textAnnotationTarget],a=o?this.nameTable[r.textAnnotation.textAnnotationTarget]:null,l=null!=a?a.wrapper:null,h=e.ports[0],c={x:0,y:0};switch(r.textAnnotation.textAnnotationDirection){case"Left":h.offset={x:0,y:.5},c.x=i.bounds.left-40,c.y=i.bounds.bottom+30;break;case"Right":h.offset={x:1,y:.5},c.x=i.bounds.right+40,c.y=i.bounds.bottom+30;break;case"Top":h.offset={x:.5,y:0},c.x=i.bounds.right+30,c.y=i.bounds.top-40;break;case"Bottom":h.offset={x:.5,y:1},c.x=i.bounds.right+30,c.y=i.bounds.bottom+40;break;default:h.offset={x:0,y:.5},c.x=i.bounds.left-40,c.y=i.bounds.bottom+30,o&&null!=i&&null!=l&&(i.bounds.left>l.bounds.right?h.offset={x:0,y:.5}:i.bounds.rightl.bounds.top?h.offset={x:.5,y:0}:i.bounds.top0&&this.updateChildPosition(r)}},t.prototype.canExecute=function(){return!0},t.prototype.updateStackProperty=function(e,i,r){e.container&&"Stack"===e.container.type&&(i.width||(i.wrapper.horizontalAlignment="Stretch",i.horizontalAlignment="Stretch"),i.height||(i.verticalAlignment="Stretch",i.wrapper.verticalAlignment="Stretch"),r&&"UmlClassifier"===e.shape.type&&(i.umlIndex=r))},t.prototype.initViews=function(){this.isLoading||(this.views.push(this.element.id),this.views[this.element.id]=this)},t.prototype.initCommands=function(){var e=this.commandManager.commands,i={copy:{execute:this.copyCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.C,keyModifiers:ft.Control}},paste:{execute:this.pasteCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.V,keyModifiers:ft.Control}},cut:{execute:this.cutCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.X,keyModifiers:ft.Control}},delete:{execute:this.removeCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Delete}},selectAll:{execute:this.selectAll.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.A,keyModifiers:ft.Control}},undo:{execute:this.undo.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Z,keyModifiers:ft.Control}},redo:{execute:this.redo.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Y,keyModifiers:ft.Control}},nudgeUp:{execute:this.nudgeCommand.bind(this,"Up"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Up},parameter:"up"},nudgeRight:{execute:this.nudgeCommand.bind(this,"Right"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Right},parameter:"right"},nudgeDown:{execute:this.nudgeCommand.bind(this,"Down"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Down},parameter:"down"},nudgeLeft:{execute:this.nudgeCommand.bind(this,"Left"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Left},parameter:"left"},startEdit:{execute:this.startEditCommad.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.F2}},endEdit:{execute:this.endEditCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Escape}},focusToNextItem:{execute:this.navigateItems.bind(this,!0),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Tab}},focusToPreviousItem:{execute:this.navigateItems.bind(this,!1),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Tab,keyModifiers:ft.Shift}},selectFocusedItem:{execute:this.startEditCommad.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Enter}},bold:{execute:this.fontStyleCommand.bind(this,"bold"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.B,keyModifiers:ft.Control}},italic:{execute:this.fontStyleCommand.bind(this,"italic"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.I,keyModifiers:ft.Control}},underline:{execute:this.fontStyleCommand.bind(this,"underline"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.U,keyModifiers:ft.Control}},duplicate:{execute:this.duplicateCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.D,keyModifiers:ft.Control}},group:{execute:this.groupCommand.bind(this,"group"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.G,keyModifiers:ft.Control}},ungroup:{execute:this.groupCommand.bind(this,"ungroup"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.U,keyModifiers:ft.Control|ft.Shift}},rotateClockwise:{execute:this.rotateCommand.bind(this,"clockwise"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.R,keyModifiers:ft.Control}},rotateAntiClockwise:{execute:this.rotateCommand.bind(this,"antiClockwise"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.L,keyModifiers:ft.Control}},flipHorizontal:{execute:this.flipCommand.bind(this,"horizontal"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.H,keyModifiers:ft.Control}},flipVertical:{execute:this.flipCommand.bind(this,"vertical"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.J,keyModifiers:ft.Control}},pointerTool:{execute:this.toolCommand.bind(this,"pointer"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number1,keyModifiers:ft.Control}},textTool:{execute:this.toolCommand.bind(this,"text"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number2,keyModifiers:ft.Control}},connectTool:{execute:this.toolCommand.bind(this,"connect"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number3,keyModifiers:ft.Control}},freeForm:{execute:this.toolCommand.bind(this,"freeForm"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number5,keyModifiers:ft.Control}},lineTool:{execute:this.toolCommand.bind(this,"line"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number6,keyModifiers:ft.Control}},rectangleTool:{execute:this.toolCommand.bind(this,"rectangle"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number8,keyModifiers:ft.Control}},ellipseTool:{execute:this.toolCommand.bind(this,"ellipse"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number9,keyModifiers:ft.Control}},zoomIn:{execute:this.zoomCommand.bind(this,"zoomIn"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Plus,keyModifiers:ft.Control}},zoomOut:{execute:this.zoomCommand.bind(this,"zoomOut"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Minus,keyModifiers:ft.Control}},shiftUp:{execute:this.shiftCommand.bind(this,"Up"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Up,keyModifiers:ft.Shift}},shiftDown:{execute:this.shiftCommand.bind(this,"Down"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Down,keyModifiers:ft.Shift}},shiftLeft:{execute:this.shiftCommand.bind(this,"Left"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Left,keyModifiers:ft.Shift}},shiftRight:{execute:this.shiftCommand.bind(this,"Right"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Right,keyModifiers:ft.Shift}},alignTextCenter:{execute:this.alignCommand.bind(this,"center"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.C,keyModifiers:ft.Control|ft.Shift}},alignTextLeft:{execute:this.alignCommand.bind(this,"right"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.L,keyModifiers:ft.Control|ft.Shift}},alignTextRight:{execute:this.alignCommand.bind(this,"left"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.R,keyModifiers:ft.Control|ft.Shift}},alignTextTop:{execute:this.alignCommand.bind(this,"top"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.E,keyModifiers:ft.Control|ft.Shift}},alignTextCenterVertical:{execute:this.alignCommand.bind(this,"centerVertical"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.M,keyModifiers:ft.Control|ft.Shift}},alignTextBottom:{execute:this.alignCommand.bind(this,"bottom"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.V,keyModifiers:ft.Control|ft.Shift}},alignJustify:{execute:this.alignCommand.bind(this,"justify"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.J,keyModifiers:ft.Control|ft.Shift}},sendToBack:{execute:this.orderCommand.bind(this,"sendToBack"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.B,keyModifiers:ft.Control|ft.Shift}},bringToFront:{execute:this.orderCommand.bind(this,"bringToFront"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.F,keyModifiers:ft.Control|ft.Shift}},sendBackward:{execute:this.orderCommand.bind(this,"sendBackward"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.BracketLeft,keyModifiers:ft.Control}},bringForward:{execute:this.orderCommand.bind(this,"bringForward"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.BracketRight,keyModifiers:ft.Control}}};this.initCommandManager(e,i)},t.prototype.overrideCommands=function(e,i){for(var r,s=0,o=Object.keys(i);se.zIndex){("HTML"===e.shape.type||"Native"===e.shape.type)&&(o="HTML"===e.shape.type?"html":"native"),s=voe(i,r[parseInt(a.toString(),10)].id,o);break}return s},t.prototype.updateDiagramObject=function(e,i,r){for(var s,o="domTable",a=0,l=this.views;a1&&(d=this.commandHandler.getObjectLayer(e.id)),void 0===d||d&&d.visible||r){var u=Io(this.element.id);window[""+o][s.element.id+"_diagramLayer"]||(window[""+o][s.element.id+"_diagramLayer"]=document.getElementById(s.element.id+"_diagramLayer"));var f=window[""+o][s.element.id+"_diagramLayer"];this.diagramActions&ee.Interactions&&this.updateCanupdateStyle(e.wrapper.children,!0);var p=this.getMidPoint(e);this.diagramRenderer.updateNode(e.wrapper,f,u,void 0,i?void 0:this.getZindexPosition(e,s.element.id),p,this.portCenterPoint),this.updateCanupdateStyle(e.wrapper.children,!0)}}},t.prototype.applyMarginBezier=function(e,i){i.cx=i.cx+e.margin.left,i.cx=i.cx-e.margin.right,i.cy=i.cy+e.margin.top,i.cy=i.cy-e.margin.bottom},t.prototype.getMidPoint=function(e){var i;if(e instanceof de&&"Bezier"===e.type){i=[];for(var r=this.getBezierPoints(e),s=R.getLengthFromListOfPoints(r),o=0;o0&&e.updateView(e));var s=Io(e.element.id);this.renderDiagramElements(e.diagramLayer,e.diagramRenderer,s,void 0,void 0,i);for(var o=0;o0&&this.renderBasicElement(e),!this.diagramActions||!(this.diagramActions&ee.Render)||ee.ToolAction&this.diagramActions||Ds(this)||1!==this.scroller.currentZoom?this.refreshElements(e):this.renderTimer||(this.renderTimer=setTimeout(function(){i.refreshElements(e)},40)))},t.prototype.updatePortVisibility=function(e,i,r){var s;if((e instanceof te||e instanceof de)&&(!this.drawingObject||!this.drawingObject.shape)&&ro(e)){for(var a=e.ports,l=!1,h=0;h=0&&this.scroller.removeCollection.splice(l,1);var h=this.nameTable[e[parseInt(a.toString(),10)]];this.updateTextElementValue(h),this.diagramRenderer.renderElement(h.wrapper,s,o,void 0,void 0,void 0,void 0,h.zIndex)}for(var c=0;c0?this.scroller.oldCollectionObjects:void 0,b=Object.keys(S||g.zIndexTable);b.sort(function(N,T){return parseInt(""+N,10)-parseInt(""+T,10)});for(var M=0,w=b;M0?h:0)+"px",y=(this.realActions&$i.vScrollbarMoved?0:-(this.scroller.verticalOffset<0?this.scroller.verticalOffset:0))+"px"):(v="0px",y="0px"),this.realActions&$i.hScrollbarMoved&&(this.realActions=this.realActions&~$i.hScrollbarMoved),this.realActions&$i.vScrollbarMoved&&(this.realActions=this.realActions&~$i.vScrollbarMoved)):(v=(l.x<0?h:-this.scroller.horizontalOffset)+"px",y=(l.y<0?c:-this.scroller.verticalOffset)+"px"),this.diagramLayer.style.left=v,this.diagramLayer.style.top=y,A.tx=-l.x/A.scale,A.ty=-l.y/A.scale);var P=!0;if(o&&(P=!1),this.updateTextElementValue(D),this.refreshing&&D.shape.activity&&D.shape.activity.subProcess&&D.shape.activity.subProcess.processes){for(var L=0;L0){var o=s.children[0],a=o.data;(r.isBezierEditing&&this.selectedItems.connectors[0].id===r.id||"Bezier"!==r.type)&&r.getSegmentElement(r,o,"ComplexHierarchicalTree"===this.layout.type||"HierarchicalTree"===this.layout.type?this.layout.orientation:void 0,void 0,!1),o.data!==a&&(s.measure(new me),s.arrange(s.desiredSize),"SVG"===this.mode&&!e&&this.updateDiagramObject(r))}}else this.constraints&nt.Bridging&&console.warn('[WARNING] :: Module "ConnectorBridging" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.setCursor=function(e){this.diagramRenderer.setCursor(this.diagramCanvas,e)},t.prototype.clearCanvas=function(e){var i=e.contentWidth||e.diagramLayer.width/this.scroller.currentZoom,r=e.contentHeight||e.diagramLayer.height/this.scroller.currentZoom;"SVG"!==e.mode&&bo.getContext(e.diagramLayer).clearRect(0,0,i,r)},t.prototype.updateScrollOffset=function(){this.scroller.setScrollOffset(this.diagramCanvas.scrollLeft,this.diagramCanvas.scrollTop),JI(this),Ds(this)&&this.scroller.virtualizeElements()},t.prototype.setOffset=function(e,i){var r="domTable";window[""+r][this.element.id+"content"]||(window[""+r][this.element.id+"content"]=document.getElementById(this.element.id+"content"));var s=window[""+r][this.element.id+"content"];s&&(s.scrollLeft=e,s.scrollTop=i)},t.prototype.setSize=function(e,i){if(this.diagramLayer&&!this.preventDiagramUpdate){var r=Za(this);e-=r.width,i-=r.height;var s=this.spatialSearch.getPageBounds();s.x*=this.scroller.currentZoom,s.y*=this.scroller.currentZoom,s.width*=this.scroller.currentZoom,s.height*=this.scroller.currentZoom;var o="SVG"===this.mode?1:1.5,a="SVG"===this.mode?vT(this.element.id):this.diagramLayer,h="Canvas"===this.mode&&this.constraints&nt.Virtualization?this.scroller.viewPortHeight:i;a.setAttribute("width",(o*("Canvas"===this.mode&&this.constraints&nt.Virtualization?this.scroller.viewPortWidth:e)).toString()),a.setAttribute("height",(o*h).toString());var c=document.getElementById(this.element.id+"_diagramUserHandleLayer");c&&(c.style.width=e+"px",c.style.height=i+"px");var d={width:e.toString(),height:i.toString()};this.diagramLayerDiv.style.width=e+"px",this.diagramLayerDiv.style.height=i+"px",ii(kF(this.element.id),d),ii(function yoe(n){return xt(n).getElementsByClassName("e-ports-expand-layer")[0]}(this.element.id),d);var u=Bl(this.element.id);ii(u,d),u.parentNode.style.width=e+"px",u.parentNode.style.height=i+"px";var f=Ud(this.element.id);ii(f,d),this.diagramRenderer.updateGrid(this.snapSettings,f,this.scroller.transform,this.rulerSettings,this.hRuler,this.vRuler),ii(ST(this.element.id),d),this.htmlLayer.style.width=e+"px",this.htmlLayer.style.height=i+"px","SVG"!==this.mode&&!Ds(this)&&this.refreshDiagramLayer(),"SVG"===this.mode&&Ds(this)&&this.scroller.virtualizeElements()}},t.prototype.transformLayers=function(){var e=this.spatialSearch.getPageBounds();e.x*=this.scroller.currentZoom,e.y*=this.scroller.currentZoom,e.width*=this.scroller.currentZoom,e.height*=this.scroller.currentZoom,this.diagramRenderer.updateGrid(this.snapSettings,Ud(this.element.id),this.scroller.transform,this.rulerSettings,this.hRuler,this.vRuler),this.diagramRenderer.transformLayers(this.scroller.transform,"SVG"===this.mode),this.diagramActions&ee.DragUsingMouse||this.updateSelector(),this.renderPageBreaks(e)},t.prototype.removePageBreaks=function(){if(this.diagramLayer){var e=PF(this.element.id);if(e&&e.childNodes)for(var i=e.childNodes.length,r=0;rthis.pageSettings.height&&(e=this.pageSettings.height,this.pageSettings.height=this.pageSettings.width,this.pageSettings.width=e):this.pageSettings.height>this.pageSettings.width&&(e=this.pageSettings.width,this.pageSettings.width=this.pageSettings.height,this.pageSettings.height=e)},t.prototype.setOverview=function(e,i){if(e)e&&(this.views.push(e.id),this.views[e.id]=e,e.renderDocument(e),e.diagramRenderer.setLayers(),e.updateView(e),this.renderNodes(e));else{for(var r=0;r1&&this.updateSelectionRectangle(),this.isProtectedOnChange=s},t.prototype.updateSelectionRectangle=function(){for(var e=dm(this.element.id),i=!1,r=0;r1&&this.updateSelectionRectangle(),this.enableServerDataBinding(e)},t.prototype.renderSelectorForAnnotation=function(e,i){this.diagramRenderer.renderResizeHandle(e.wrapper.children[0],i,e.thumbsConstraints,this.scroller.currentZoom,e.constraints,this.scroller.transform,void 0,ro(e.annotation),void 0,void 0,e.handleSize)},t.prototype.drawSelectionRectangle=function(e,i,r,s){this.clearSelectorLayer(),this.diagramRenderer.drawSelectionRectangle(e,i,r,s,this.adornerLayer,this.scroller.transform)},t.prototype.renderHighlighter=function(e){var i=Bl(this.element.id);this.diagramRenderer.renderHighlighter(e,i,this.scroller.transform)},t.prototype.clearHighlighter=function(){var e=Bl(this.element.id),i=e.getElementById(e.id+"_highlighter");i&&i.parentNode.removeChild(i)},t.prototype.getNodesConnectors=function(e){for(var i=0;i0;h--)this.eventHandler&&this.eventHandler.touchArgs&&"touchmove"===this.eventHandler.touchArgs.type?(this.diagramRenderer.touchMove=!0,l&&l===o[h-1].id||(a=o[h-1]).parentNode.removeChild(a)):(a=o[h-1]).parentNode.removeChild(a);if(!ce()){var c=yT(this.element.id).childNodes;for(r=c.length;r>0;r--)c[r-1].parentNode.removeChild(c[r-1])}}},t.prototype.getWrapper=function(e,i){var r;i=e.id+"_"+i;for(var s=e instanceof Mi?e:this.getPortContainer(this.nameTable[e.id]),o=0;o0&&this.applyStyle(e,a=r.annotations)}for(i=0;i0){var a=this.selectedItems.connectors[parseInt(i.toString(),10)].annotations;this.applyStyle(e,a)}},t.prototype.applyStyle=function(e,i){for(var r=0;r0)for(var i=0;i0?r[0].zIndex+(e?1:-1):e?0:this.nodes.length+this.connectors.length-1)<0?i=this.nodes.length+this.connectors.length-1:i===this.nodes.length+this.connectors.length&&(i=0);for(var s=0;s0)for(var s=void 0,o=r.children.length-1;o>=0;o--){var a=r.children[parseInt(o.toString(),10)];i.length>0&&-1!==i.indexOf(a.id.split("_groupElement")[0])&&(r.parentNode.insertBefore(a,s||r),s=a)}r&&r.parentNode.removeChild(r)},t.prototype.deleteGroup=function(e){var r=[];e.children&&(r=this.commandHandler.getChildren(e,[])),this.UpdateBlazorDiagramModelCollection(e);for(var s=0,o=r;s0)for(var xe=0;xe0)if("Path"===t.shape.type&&void 0!==n.shape.data)t.wrapper.children[0].data=n.shape.data;else if("Text"===t.shape.type&&void 0!==n.shape.content)t.wrapper.children[0].content=n.shape.content;else if("Image"===t.shape.type&&void 0!==n.shape.source)t.wrapper.children[0].source=n.shape.source;else if("Native"===t.shape.type){for(var r=void 0,s=0;s-1)&&(this.diagramActions&ee.PreventZIndexOnDragging?this.updateDiagramObject(e,!0):this.updateDiagramObject(e)),!s&&d&&(this.lineRoutingModule&&this.diagramActions&&this.constraints&nt.LineRouting&&"helper"!==e.id?this.diagramActions&ee.ToolAction||this.lineRoutingModule.renderVirtualRegion(this,!0):this.diagramActions&&this.constraints&nt.LineRouting&&"helper"!==e.id&&console.warn('[WARNING] :: Module "LineRouting" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),this.updateConnectorEdges(e),"helper"!==e.id&&!(this.diagramActions&ee.ToolAction))))for(var Sa=this.spatialSearch.findObjects(e.wrapper.outerBounds),Mo=0;Moe?Math.abs(r-e):Math.abs(e-r),d=s>i?Math.abs(s-i):Math.abs(i-s);(0===c&&0===d||Number.isNaN(c)&&Number.isNaN(d))&&o.laneMargin&&(u=o.margin.left-o.laneMargin.left,f=o.margin.top-o.laneMargin.top);var p=o.width,g=o.height,v=new Ne(0,0,0,0);if(0!==p&&0!==g&&(v=new Ne((0!==r?r:o.offsetX)-p/2,(0!==s?s:o.offsetY)-g/2,p,g)),h){var y=l,b=this.selectedItems.nodes?this.selectedItems.nodes[0]:void 0;if(""!==y.textAnnotation.textAnnotationTarget&&this.nameTable[y.textAnnotation.textAnnotationTarget])if(""===o.parentId||b&&b.shape&&"TextAnnotation"===b.shape.shape){if("Auto"===y.textAnnotation.textAnnotationDirection&&a.children[0]instanceof Mi&&a.children[0].children[0]instanceof Ze){var w=a.children[0],C=document.getElementById(w.id+"_groupElement"),D=document.getElementById(w.children[0].id+"_groupElement");C.removeChild(D),w.children.splice(0,1),this.isProtectedOnChange=!0,this.bpmnModule.setAnnotationPath(v,w,o,y,y.textAnnotation.textAnnotationDirection,this),this.isProtectedOnChange=!1}}else this.isPositionUndo=!0,this.updateTextAnnotationInSwimlane(o,o),this.isPositionUndo=!1;else o.inEdges.length>0&&(x=this.nameTable[""+o.inEdges[0]])&&x.isBpmnAnnotationConnector&&(x.sourcePoint={x:r>e?x.sourcePoint.x+c:x.sourcePoint.x-c,y:s>i?x.sourcePoint.y+d:x.sourcePoint.y-d});this.nodePropertyChange(o,{},P={ports:[{offset:o.ports[0].offset}]})}else for(var L=0,O=o.outEdges;Le?T.offsetX+c:T.offsetX-c,T.offsetY=s>i?T.offsetY+d:T.offsetY-d,P={offsetX:T.offsetX,offsetY:T.offsetY}),this.nodePropertyChange(T,z,P)}}}},t.prototype.updatePorts=function(e,i){if(e&&e.ports.length>0)for(var r=0,s=Object.keys(e.ports);r0)for(var i=0;i0)for(var r=0;r0&&void 0===r.segments&&(e.segments=[]),void 0!==r.shape&&void 0!==e.shape&&e.shape&&"Bpmn"===e.shape.type&&this.bpmnModule&&this.bpmnModule.updateBPMNConnector(e,i,r,this),void 0!==e.constraints?(this.updateThumbConstraints(this.selectedItems.connectors,this.selectedItems),s=!0):s},t.prototype.connectorPropertyChange=function(e,i,r,s,o){if(this.canEnableBlazorObject){var a=$(e);this.insertValue(a,!1)}var d,u,f,p,l=e.wrapper.bounds,h=!1,c=[];if(h=this.connectorProprtyChangeExtend(e,i,r,h),void 0!==r.visible&&this.updateElementVisibility(e.wrapper,e,e.visible),void 0!==r.sourcePoint||void 0!==r.targetPoint||void 0!==r.sourceID||void 0!==r.targetID||void 0!==r.targetPadding||void 0!==r.sourcePortID||void 0!==r.targetPortID||void 0!==r.sourcePadding||void 0!==r.type||void 0!==r.segments||void 0!==r.flip){if(void 0!==r.sourceID&&r.sourceID!==i.sourceID||r.sourcePortID){if(u=this.findInOutConnectPorts(g=this.nameTable[e.sourceID],!1),(!g||Ph(g)||""!==e.sourcePortID&&Ld(u))&&(e.sourceWrapper=g?this.getEndNodeWrapper(g,e,!0):void 0,e.sourcePortID&&void 0===r.sourcePortID&&(e.sourcePortWrapper=g?this.getWrapper(g.wrapper,e.sourcePortID):void 0),this.removePortEdges(this.nameTable[i.sourceID]||g,i.sourcePortID||e.sourcePortID,e.id,!1)),void 0!==r.sourceID&&void 0!==i.sourceID&&""!==i.sourceID){var v=this.nameTable[i.sourceID];void 0!==v&&v.outEdges&&-1!==v.outEdges.indexOf(e.id)&&im(v.outEdges,e.id)}this.updateEdges(e)}if(void 0!==r.targetID&&r.targetID!==i.targetID){if(d=this.findInOutConnectPorts(y=this.nameTable[r.targetID],!0),(!y||ua(y)||""!==e.targetPortID&&kh(d))&&(e.targetWrapper=y?this.getEndNodeWrapper(y,e,!1):void 0,e.targetPortID&&void 0===r.targetPortID&&(e.targetPortWrapper=y?this.getWrapper(y.wrapper,e.targetPortID):void 0),this.removePortEdges(this.nameTable[i.targetID]||y,i.targetPortID||e.targetPortID,e.id,!0)),void 0!==i&&void 0!==i.targetID&&""!==i.targetID){var S=this.nameTable[i.targetID];void 0!==S&&S.inEdges&&-1!==S.inEdges.indexOf(e.id)&&im(S.inEdges,e.id)}this.updateEdges(e)}var g,y;void 0!==r.sourcePortID&&r.sourcePortID!==i.sourcePortID&&(e.sourceID&&this.nameTable[e.sourceID]&&(f=this.nameTable[e.sourceID].wrapper),!(g=this.nameTable[e.sourceID])||Ph(g)||""!==e.sourcePortID&&Ld(u)?e.sourcePortWrapper=f?this.getWrapper(f,r.sourcePortID):void 0:""===e.sourcePortID&&!Ph(g)&&(e.sourcePortWrapper=void 0)),void 0!==r.targetPortID&&r.targetPortID!==i.targetPortID&&(e.targetID&&this.nameTable[e.targetID]&&(p=this.nameTable[e.targetID].wrapper),!(y=this.nameTable[e.targetID])||ua(y)||""!==e.targetPortID&&kh(d)?e.targetPortWrapper=p?this.getWrapper(p,r.targetPortID):void 0:""===e.targetPortID&&!ua(y)&&(e.targetPortWrapper=void 0)),void 0!==r.flip&&(e.flip=r.flip,SF(e)),"Orthogonal"===e.type&&this.lineRoutingModule&&this.diagramActions&&this.constraints&nt.LineRouting&&!(this.diagramActions&ee.ToolAction)&&"ComplexHierarchicalTree"!==this.layout.type&&(this.lineRoutingModule.renderVirtualRegion(this,!0),e.sourceID!==e.targetID&&e.segments.length>1&&this.lineRoutingModule.refreshConnectorSegments(this,e,!1)),c=this.getPoints(e)}void 0!==r.style&&zh(r.style,e.wrapper.children[0]),(c.length>0||void 0!==r.sourceDecorator||void 0!==r.targetDecorator&&function _se(n){return-1!==n.indexOf("shape")||-1!==n.indexOf("pathData")||-1!==n.indexOf("width")||-1!==n.indexOf("height")}(Object.keys(r.targetDecorator))||void 0!==r.cornerRadius)&&(ep(e,c.length>0?c:e.intermediatePoints,this.diagramActions),void 0!==r.type&&(h=!0),c.length>0&&(e.wrapper.measure(new me(e.wrapper.width,e.wrapper.height)),e.wrapper.arrange(e.wrapper.desiredSize),this.updateConnectorAnnotation(e),this.updateConnectorPort(e),this.updateConnectorfixedUserHandles(e),this.updateObject(e,i,r))),(r.sourcePoint||r.targetPoint||r.segments)&&this.diagramActions===ee.Render&&(h=!0),"Bpmn"===e.shape.type&&"Default"===e.shape.sequence&&"Sequence"===e.shape.flow&&this.commandHandler.updatePathElementOffset(e),s||this.updateBridging(),this.updateAnnotations(r,e),this.updateConnectorPorts(r,e),this.updatefixedUserHandle(r,e),e.wrapper.measure(new me(e.wrapper.width,e.wrapper.height)),e.wrapper.arrange(e.wrapper.desiredSize),!1===l.equals(l,e.wrapper.bounds)&&(this.updateQuad(e),"Drag"!==this.eventHandler.currentAction&&this.updateGroupSize(e)),!0===h&&this.checkSelectedItem(e)&&(!(this.diagramActions&ee.ToolAction)||this.diagramActions&ee.UndoRedo)&&this.updateSelector(),this.preventConnectorsUpdate||(!Ds(this)||Ds(this)&&this.scroller.oldCollectionObjects.indexOf(e.id)>-1)&&(this.diagramActions&ee.PreventZIndexOnDragging?this.updateDiagramObject(e,!0):this.updateDiagramObject(e)),this.updateConnectorEdges(e),this.diagramActions&&"New"!==e.status&&(e.status="Update"),this.triggerPropertyChange(o,e,i,r)},t.prototype.removePortEdges=function(e,i,r,s){if(e)for(var o=0;o0&&e.id===s[s.length-1].id&&(r=!0),r},t.prototype.updateDiagramContainerVisibility=function(e,i){if(e instanceof Cs)for(var r=0;r>"),r instanceof es&&this.updateAnnotationWrapper(r,s,o,a)),void 0!==e.template&&(r.content=e.template,this.updateAnnotationWrapper(r,s,o,a))},t.prototype.updateAnnotationWrapper=function(e,i,r,s){for(var o=0,a=this.views;o=0&&this.nodes.splice(s,1),delete this.nameTable[""+r]}var o=this.nodes.indexOf(this.nameTable[this.currentSymbol.id]);o>=0&&this.nodes.splice(o,1)}},t.prototype.selectDragedNode=function(e,i,r){this.currentSymbol=e,"SVG"!==this.mode&&this.refreshDiagramLayer(),this.commandHandler.oldSelectedObjects=nm(this),this.commandHandler.select(e),this.eventHandler.mouseDown(i.event),this.eventHandler.mouseMove(i.event,i),this.preventDiagramUpdate=!1,this.updatePage(),r.style.opacity="0"},t.prototype.initDroppables=function(){var s,o,e=this,i={},r={},a="selectedSymbols";this.droppable=new lR(this.element);var l=5;this.droppable.over=function(h){if(e.rulerSettings.showRulers){var c=document.getElementById(e.element.id+"_vRuler"),d=parseFloat(c.style.width);l=d+1}if(0===e.previousSelectedObjects.length&&!e.currentSymbol&&(e.previousSelectedObjects=e.commandHandler.getSelectedObject()),e.commandHandler.PreventConnectorSplit=!0,e.currentSymbol)h.event.touches&&h.event.touches.length&&e.eventHandler.mouseMove(h.event,h.event.touches);else{var u=null;if(!h.dragData&&"drag"===h.name){var f=document.getElementsByClassName("e-dragclone")[0];f&&(u=f)}if(h.dragData||u){var p=void 0,g=void 0;document.getElementById(e.element.id+"content").focus();var v=e.eventHandler.getMousePosition(h.event),y=void 0,S=u||h.dragData.helper,b=S.getAttribute("paletteId"),M=void 0,w=void 0,C=void 0,D=void 0;if(!b&&h.dragData){e.triggerEvent(Ce.dragEnter,A={source:null,element:p,cancel:!1,diagram:e,dragData:h.dragData.draggedElement.ej2_instances[0].dragData,dragItem:p});var x=void 0,P=void 0;if(A.dragItem){if(A.dragItem.sourcePoint&&A.dragItem.targetPoint?P=new de(e,"connectors",A.dragItem,!0):x=new te(e,"nodes",A.dragItem,!0),e.initObject(p=x||P,void 0,void 0,!0),e.enterObject=p,e.enterTable=r,p instanceof te)x.offsetX=v.x+5+x.width*x.pivot.x,x.offsetY=v.y+x.height*x.pivot.y;else if(p instanceof de){var L=Ne.toBounds([p.sourcePoint,p.targetPoint]),O=v.x-L.left,N=v.y-L.top;p.sourcePoint.x+=O,p.sourcePoint.y+=N,p.targetPoint.x+=O,p.targetPoint.y+=N}e.preventDiagramUpdate=!0,e.currentSymbol=p,"SVG"!==e.mode&&e.refreshDiagramLayer(),e.selectDragedNode(p,h,S),delete e.enterObject,delete e.enterTable,e.droppable[""+a]=S,e.allowServerDataBinding=!0}}if(b){var T=document.getElementById(b).ej2_instances[0];if(e.droppable.sourceElement=T,T){var B=T[""+a];e.allowServerDataBinding=!1,y=$(T[""+a]),i=T.childTable;var j=B.wrapper.children[0].children[0];if(D=function Use(n,t,e){var i=wF(n,t,e,"width"),r=wF(n,t,e,"height");return new me(i,r)}(T,y,j),T[""+a]instanceof te){"TextAnnotation"===B.shape.shape?(y.offsetX=v.x+11+D.width*y.pivot.x,y.offsetY=v.y+11+D.height*y.pivot.y):(y.offsetX=v.x+5+D.width*y.pivot.x,y.offsetY=v.y+D.height*y.pivot.y),"Bpmn"===(x=new te(e,"nodes",y,!0)).shape.type&&x.shape.activity.subProcess.processes&&x.shape.activity.subProcess.processes.length&&(x.shape.activity.subProcess.processes=[]),w=x.previewSize,C=T.symbolDragSize;var Q=T.symbolPreview;if(x.width=(M=x.dragSize).width||C.width||w.width||Q.width||x.width,x.height=M.height||C.height||w.height||Q.height||x.height,"SwimLane"===x.shape.type){if(e.diagramActions|=ee.PreventHistory,x.shape.isLane){x.children=[],s={id:"header"+Qe()},"Horizontal"===x.shape.orientation?(s.width=x.shape.lanes[0].header.width,s.height=x.shape.lanes[0].height):(s.width=x.shape.lanes[0].width,s.height=x.shape.lanes[0].header.height),s.style=x.shape.lanes[0].header.style,s.offsetX=v.x+l+s.width/2,s.offsetY=v.y+s.height/2,e.diagramActions|=ee.PreventCollectionChangeOnDragOver,s=e.add(s),o={id:"body"+Qe()},"Horizontal"===x.shape.orientation?(o.width=x.shape.lanes[0].width-s.width,o.height=x.shape.lanes[0].height,o.offsetX=v.x+l+(x.shape.lanes[0].header.width+o.width/2),o.offsetY=v.y+o.height/2):(o.width=x.shape.lanes[0].width,o.height=x.shape.lanes[0].height-s.height,o.offsetX=v.x+l+o.width/2,o.offsetY=v.y+(x.shape.lanes[0].header.height+o.height/2)),o.style=x.shape.lanes[0].style,o=e.add(o);var oe={id:"group"+Qe(),children:[s.id,o.id]};oe.shape=x.shape,oe.width=x.shape.lanes[0].width,oe.height=x.shape.lanes[0].height,oe.previewSize=x.previewSize,oe.dragSize=x.dragSize,oe.addInfo=x.addInfo,x=e.add(oe),e.diagramActions&=~ee.PreventCollectionChangeOnDragOver}e.diagramActions&=~ee.PreventHistory}if(x.shape.isPhase&&((g="Horizontal"===x.shape.orientation)?(x.offsetX=v.x+l+(x.width||j.actualSize.width)/2,x.offsetY=v.y,x.shape.data="M20,"+x.height/2+" L"+(x.width-20)+","+x.height/2+"z",x.height=1):(x.offsetX=v.x+5,x.offsetY=v.y+(x.height||j.actualSize.height)/2,x.shape.data="M"+x.width/2+",20 L"+x.width/2+","+(x.height-20)+"z",x.width=1)),"UmlClassifier"===x.shape.type&&(x.children=x.width=x.height=void 0,y.children=void 0,"Class"===x.shape.classifier&&x.shape.classShape.methods.length<=0&&x.shape.classShape.attributes.length<=0&&(x.shape.classShape.attributes=[{name:"Name",type:"Type",style:{}}]),"Enumeration"===x.shape.classifier&&x.shape.enumerationShape.members.length<=0&&(x.shape.enumerationShape.members=[{name:"Name"}]),"Interface"===x.shape.classifier&&x.shape.interfaceShape.methods.length<=0&&x.shape.interfaceShape.attributes.length<=0&&(x.shape.interfaceShape.attributes=[{name:"Name",type:"Type",style:{}}])),p=x,y.children){var ue=y;r=e.getChildren(ue,{},i),iT(ue,-ue.offsetX,-ue.offsetY,r,!0,e)}}else if(T[""+a]instanceof de){p=new de(e,"connectors",y,!0);var Me=Ne.toBounds([p.sourcePoint,p.targetPoint]),De=v.x-Me.left,xe=v.y-Me.top;p.sourcePoint.x+=De,p.sourcePoint.y+=xe,p.targetPoint.x+=De,p.targetPoint.y+=xe}p.shape.isLane||(p.id+=Qe());var A={source:T,element:p,cancel:!1,diagram:e,dragData:null,dragItem:p};if(e.enterObject=p,e.enterTable=r,e.triggerEvent(Ce.dragEnter,A),p instanceof te&&"SwimLane"===p.shape.type&&p.shape.isLane){var Ie=A.element,Ve=Ie.shape.lanes[0];g="Horizontal"===Ie.shape.orientation;var ot=e.nameTable[p.children[0]],$e=e.nameTable[p.children[1]];w=p.previewSize,C=T.symbolDragSize,Ve.width=(M=p.dragSize).width||C.width||w.width||Ve.width,Ve.height=M.height||C.height||w.height||Ve.height,g?(s.width=Ve.header.width,s.height=Ve.height,o.width=Ve.width-s.width,o.height=Ve.height,o.offsetX=v.x+l+(Ve.header.width+$e.width/2),o.offsetY=v.y+$e.height/2):(s.width=Ve.width,s.height=Ve.header.height,o.width=Ve.width,o.height=Ve.height-s.height,o.offsetX=v.x+l+$e.width/2,o.offsetY=v.y+(Ve.header.height+$e.height/2)),s.offsetX=v.x+l+ot.width/2,s.offsetY=v.y+ot.height/2,p.width=Ve.width,p.height=Ve.height}if(p instanceof te&&p.shape.isPhase&&(g?p.height=1:p.width=1),!e.activeLayer.lock&&!A.cancel){if(e.preventDiagramUpdate=!0,p.children&&e.findChild(p,r),e.preventDiagramUpdate=!0,p.zIndex!==Number.MIN_VALUE&&(p.zIndex=Number.MIN_VALUE),e.initObject(p,void 0,void 0,!0),e.bpmnModule)for(var Ci=0;Ci0&&(S.segments=[]),d=this.add(S,!0)),(S||d)&&(_v(this)||Uv(this))&&this.select([this.nameTable[S[""+b]]],!1,this.previousSelectedObjects),y.target&&y.target instanceof de&&!0===this.enableConnectorSplit&&this.nameTable[S[""+b]]instanceof te&&(this.commandHandler.connectorSplit(this.nameTable[S[""+b]],y.target),this.commandHandler.PreventConnectorSplit=!1))),this.protectPropertyChange(!1),v=this.nameTable[S[""+b]],S.hasTarget&&(S.nodeId=S.hasTarget,this.remove(S)),this.bpmnModule&&v instanceof te&&S.processId&&(v.processId=S.processId,this.bpmnModule.dropBPMNchild(this.nameTable[v.processId],v,this)),y.cancel||this.endGroupAction(),"SVG"!==this.mode&&this.refreshDiagramLayer(),delete this.droppable[""+c]):(this.triggerEvent(Ce.drop,y={source:h.droppedElement,element:void 0,target:this.eventHandler.hoverNode||this.eventHandler.lastObjectUnderMouse||this,cancel:!1,position:void 0}),S=void 0,b="id"),this.droppable[M="selectedSymbols"]&&this.droppable[""+M].parentNode)gt(this.droppable[""+M]);else for(w=document.getElementsByClassName("e-dragclone"),C=0;C0)for(var f=0;f1),e.previousSelectedObject=null}}},t.prototype.getDropEventArgs=function(e){if(this.eventHandler.lastObjectUnderMouse||this.eventHandler.hoverNode){var i=this.eventHandler.lastObjectUnderMouse||this.eventHandler.hoverNode;e.target=ps(i)===de?{connector:i}:{node:i}}else e.target.diagramId=this.element.id},t.prototype.removeChildInNodes=function(e){if(e){if(e.children)for(var i=0;i1){var l=2;if(e.children&&e.children.length>0)for(;e.children.indexOf(i.objects[s-l])>-1;)l++;this.commandHandler.moveSvgNode(e.id,i.objects[s-l]),this.commandHandler.moveSvgNode(i.objects[s-l],e.id)}else if(o){var h=this.commandHandler.getLayer(this.layerZIndexTable[o.zIndex]).objects[0];h?(this.commandHandler.moveSvgNode(e.id,h),this.commandHandler.updateNativeNodeIndex(e.id,h)):this.moveObjectsUp(e,i)}else this.moveObjectsUp(e,i)},t.prototype.moveObjectsUp=function(e,i){for(var r,s=this.layers.length-1;s>=0;s--)if(r=this.layers[parseInt(s.toString(),10)],i.id!==r.id){var o=this.commandHandler.getLayer(this.layerZIndexTable[r.zIndex]).objects[r.objects.length-1];if(o){this.commandHandler.moveSvgNode(e.id,o),this.commandHandler.moveSvgNode(o,e.id);break}}},t.prototype.insertData=function(e){return this.crudOperation(e,"create",this.getNewUpdateNodes("New"))},t.prototype.updateData=function(e){return this.crudOperation(e,"update",this.getNewUpdateNodes("Update"))},t.prototype.removeData=function(e){return this.crudOperation(e,"destroy",this.getDeletedNodes())},t.prototype.crudOperation=function(e,i,r){if(e){var s=this.parameterMap(e,!(e instanceof de));if(s){var o=e instanceof de?this.dataSourceSettings.connectionDataSource.crudAction[""+i]:this.dataSourceSettings.crudAction[""+i];this.raiseAjaxPost(JSON.stringify(s),o)}return s}var a=r;return this.processCrudCollection(a,this.dataSourceSettings.crudAction[""+i],this.dataSourceSettings.connectionDataSource.crudAction[""+i]),a},t.prototype.processCrudCollection=function(e,i,r){if(e.nodes){var s=[],o=void 0;for(o=0;o0&&this.raiseAjaxPost(JSON.stringify(s),i)}if(e.connectors){for(s=[],o=void 0,o=0;o0&&this.raiseAjaxPost(JSON.stringify(s),r)}},t.prototype.parameterMap=function(e,i){var s,r={},o=i?this.dataSourceSettings:this.dataSourceSettings.connectionDataSource;if(o.id&&(r[o.id]=e.id),o.sourcePointX&&o.sourcePointY&&(r[o.sourcePointX]=e.sourcePoint.x,r[o.sourcePointY]=e.sourcePoint.y),o.targetPointX&&o.targetPointY&&(r[o.targetPointX]=e.targetPoint.x,r[o.targetPointY]=e.targetPoint.y),o.sourceID&&(r[o.sourceID]=e.sourceID),o.targetID&&(r[o.targetID]=e.targetID),o.crudAction&&o.crudAction.customFields&&o.crudAction.customFields.length>0)for(s=0;s"u"||(y.innerHTML=v.innerHTML?v.innerHTML:"",void 0!==v.className&&(y.className=v.className),void 0!==v.id&&(y.id=v.id),void 0!==v.styles&&y.setAttribute("style",v.styles),void 0!==e.ngAttr&&y.setAttribute(e.ngAttr,""),void 0!==v.attrs&&Fe(y,v.attrs)),y};for(var i=0,r=e.tags;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s}!function TZ(n){xC.compile=n.compile}({compile:function Uae(n,t){if("string"==typeof n||"function"==typeof n&&n.prototype&&n.prototype.CSPTemplate)return _ae(n,t);var e=n.elementRef.nativeElement._viewContainerRef,i=n.elementRef.nativeElement.propName;return function(r,s,o){var l=e||s.viewContainerRef,h=l.createEmbeddedView(n,{$implicit:r});/EJS-MENTION|EJS-DROPDOWNLIST/.test(Y("currentInstance.element.nodeName",l))||/E-TABITEM/.test(Y("element.nativeElement.nodeName",l))?h.detectChanges():h.markForCheck();var c=s&&s.registeredTemplate?s.registeredTemplate:Y("currentInstance.registeredTemplate",l);return typeof c["".concat(o=o&&s.registeredTemplate?o:i)]>"u"&&(c["".concat(o)]=[]),c["".concat(o)].push(h),h.rootNodes}}});const Qae=["annotationTemplate"],Gae=["nodeTemplate"],Xae=["userHandleTemplate"];let qae=["addInfo","id","lock","objects","visible","zIndex"],$ae=[],Zae=(()=>{class n extends Bh{constructor(e){super(),this.viewContainerRef=e,_l("currentInstance",this,this.viewContainerRef),this.registerEvents($ae),this.directivePropList=qae}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-layer"]],inputs:{addInfo:"addInfo",id:"id",lock:"lock",objects:"objects",visible:"visible",zIndex:"zIndex"},features:[yn]}),n})(),Jae=(()=>{class n extends Fh{constructor(){super("layers")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-layers"]],contentQueries:function(e,i,r){if(1&e&&dn(r,Zae,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),Kae=["action","cursor"],ele=[],tle=(()=>{class n extends Bh{constructor(e){super(),this.viewContainerRef=e,_l("currentInstance",this,this.viewContainerRef),this.registerEvents(ele),this.directivePropList=Kae}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-cursormap"]],inputs:{action:"action",cursor:"cursor"},features:[yn]}),n})(),ile=(()=>{class n extends Fh{constructor(){super("customcursor")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-cursormaps"]],contentQueries:function(e,i,r){if(1&e&&dn(r,tle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),rle=["alignment","cornerRadius","displacement","fill","handleStrokeColor","handleStrokeWidth","height","iconStrokeColor","iconStrokeWidth","id","offset","padding","pathData","tooltip","visibility","width"],nle=[],sle=(()=>{class n extends Bh{constructor(e){super(),this.viewContainerRef=e,_l("currentInstance",this,this.viewContainerRef),this.registerEvents(nle),this.directivePropList=rle}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-connector-fixeduserhandle"]],inputs:{alignment:"alignment",cornerRadius:"cornerRadius",displacement:"displacement",fill:"fill",handleStrokeColor:"handleStrokeColor",handleStrokeWidth:"handleStrokeWidth",height:"height",iconStrokeColor:"iconStrokeColor",iconStrokeWidth:"iconStrokeWidth",id:"id",offset:"offset",padding:"padding",pathData:"pathData",tooltip:"tooltip",visibility:"visibility",width:"width"},features:[yn]}),n})(),ole=(()=>{class n extends Fh{constructor(){super("fixeduserhandles")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-connector-fixeduserhandles"]],contentQueries:function(e,i,r){if(1&e&&dn(r,sle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),ale=["addInfo","alignment","annotationType","constraints","content","displacement","dragLimit","height","horizontalAlignment","hyperlink","id","margin","offset","rotateAngle","rotationReference","segmentAngle","style","template","tooltip","type","verticalAlignment","visibility","width"],lle=[],hle=(()=>{class n extends Bh{constructor(e){super(),this.viewContainerRef=e,_l("currentInstance",this,this.viewContainerRef),this.registerEvents(lle),this.directivePropList=ale}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-connector-annotation"]],inputs:{addInfo:"addInfo",alignment:"alignment",annotationType:"annotationType",constraints:"constraints",content:"content",displacement:"displacement",dragLimit:"dragLimit",height:"height",horizontalAlignment:"horizontalAlignment",hyperlink:"hyperlink",id:"id",margin:"margin",offset:"offset",rotateAngle:"rotateAngle",rotationReference:"rotationReference",segmentAngle:"segmentAngle",style:"style",template:"template",tooltip:"tooltip",type:"type",verticalAlignment:"verticalAlignment",visibility:"visibility",width:"width"},features:[yn]}),n})(),cle=(()=>{class n extends Fh{constructor(){super("annotations")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-connector-annotations"]],contentQueries:function(e,i,r){if(1&e&&dn(r,hle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),dle=["addInfo","allowNodeOverlap","annotations","bezierSettings","bridgeSpace","connectionPadding","connectorSpacing","constraints","cornerRadius","dragSize","excludeFromLayout","fixedUserHandles","flip","flipMode","hitPadding","id","margin","maxSegmentThumb","ports","previewSize","segmentThumbShape","segmentThumbSize","segments","shape","sourceDecorator","sourceID","sourcePadding","sourcePoint","sourcePortID","style","symbolInfo","targetDecorator","targetID","targetPadding","targetPoint","targetPortID","tooltip","type","visible","wrapper","zIndex"],ule=[],v_=(()=>{class n extends Bh{constructor(e){super(),this.viewContainerRef=e,this.tags=["fixedUserHandles","annotations"],_l("currentInstance",this,this.viewContainerRef),this.registerEvents(ule),this.directivePropList=dle}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-connector"]],contentQueries:function(e,i,r){if(1&e&&(dn(r,ole,5),dn(r,cle,5)),2&e){let s;Kr(s=en())&&(i.childFixedUserHandles=s.first),Kr(s=en())&&(i.childAnnotations=s.first)}},inputs:{addInfo:"addInfo",allowNodeOverlap:"allowNodeOverlap",annotations:"annotations",bezierSettings:"bezierSettings",bridgeSpace:"bridgeSpace",connectionPadding:"connectionPadding",connectorSpacing:"connectorSpacing",constraints:"constraints",cornerRadius:"cornerRadius",dragSize:"dragSize",excludeFromLayout:"excludeFromLayout",fixedUserHandles:"fixedUserHandles",flip:"flip",flipMode:"flipMode",hitPadding:"hitPadding",id:"id",margin:"margin",maxSegmentThumb:"maxSegmentThumb",ports:"ports",previewSize:"previewSize",segmentThumbShape:"segmentThumbShape",segmentThumbSize:"segmentThumbSize",segments:"segments",shape:"shape",sourceDecorator:"sourceDecorator",sourceID:"sourceID",sourcePadding:"sourcePadding",sourcePoint:"sourcePoint",sourcePortID:"sourcePortID",style:"style",symbolInfo:"symbolInfo",targetDecorator:"targetDecorator",targetID:"targetID",targetPadding:"targetPadding",targetPoint:"targetPoint",targetPortID:"targetPortID",tooltip:"tooltip",type:"type",visible:"visible",wrapper:"wrapper",zIndex:"zIndex"},features:[yn]}),n})(),m_=(()=>{class n extends Fh{constructor(){super("connectors")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-connectors"]],contentQueries:function(e,i,r){if(1&e&&dn(r,v_,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),fle=["cornerRadius","fill","handleStrokeColor","handleStrokeWidth","height","iconStrokeColor","iconStrokeWidth","id","margin","offset","padding","pathData","tooltip","visibility","width"],ple=[],gle=(()=>{class n extends Bh{constructor(e){super(),this.viewContainerRef=e,_l("currentInstance",this,this.viewContainerRef),this.registerEvents(ple),this.directivePropList=fle}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-node-fixeduserhandle"]],inputs:{cornerRadius:"cornerRadius",fill:"fill",handleStrokeColor:"handleStrokeColor",handleStrokeWidth:"handleStrokeWidth",height:"height",iconStrokeColor:"iconStrokeColor",iconStrokeWidth:"iconStrokeWidth",id:"id",margin:"margin",offset:"offset",padding:"padding",pathData:"pathData",tooltip:"tooltip",visibility:"visibility",width:"width"},features:[yn]}),n})(),vle=(()=>{class n extends Fh{constructor(){super("fixeduserhandles")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-node-fixeduserhandles"]],contentQueries:function(e,i,r){if(1&e&&dn(r,gle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),mle=["addInfo","annotationType","constraints","content","dragLimit","height","horizontalAlignment","hyperlink","id","margin","offset","rotateAngle","rotationReference","style","template","tooltip","type","verticalAlignment","visibility","width"],yle=[],Sle=(()=>{class n extends Bh{constructor(e){super(),this.viewContainerRef=e,_l("currentInstance",this,this.viewContainerRef),this.registerEvents(yle),this.directivePropList=mle}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-node-annotation"]],inputs:{addInfo:"addInfo",annotationType:"annotationType",constraints:"constraints",content:"content",dragLimit:"dragLimit",height:"height",horizontalAlignment:"horizontalAlignment",hyperlink:"hyperlink",id:"id",margin:"margin",offset:"offset",rotateAngle:"rotateAngle",rotationReference:"rotationReference",style:"style",template:"template",tooltip:"tooltip",type:"type",verticalAlignment:"verticalAlignment",visibility:"visibility",width:"width"},features:[yn]}),n})(),Ile=(()=>{class n extends Fh{constructor(){super("annotations")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-node-annotations"]],contentQueries:function(e,i,r){if(1&e&&dn(r,Sle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),ble=["addInfo","connectionDirection","constraints","height","horizontalAlignment","id","inEdges","margin","offset","outEdges","pathData","shape","style","tooltip","verticalAlignment","visibility","width"],Mle=[],wle=(()=>{class n extends Bh{constructor(e){super(),this.viewContainerRef=e,_l("currentInstance",this,this.viewContainerRef),this.registerEvents(Mle),this.directivePropList=ble}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-node-port"]],inputs:{addInfo:"addInfo",connectionDirection:"connectionDirection",constraints:"constraints",height:"height",horizontalAlignment:"horizontalAlignment",id:"id",inEdges:"inEdges",margin:"margin",offset:"offset",outEdges:"outEdges",pathData:"pathData",shape:"shape",style:"style",tooltip:"tooltip",verticalAlignment:"verticalAlignment",visibility:"visibility",width:"width"},features:[yn]}),n})(),Cle=(()=>{class n extends Fh{constructor(){super("ports")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-node-ports"]],contentQueries:function(e,i,r){if(1&e&&dn(r,wle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),Ele=["addInfo","annotations","backgroundColor","borderColor","borderWidth","branch","children","collapseIcon","columnIndex","columnSpan","columns","constraints","container","data","dragSize","excludeFromLayout","expandIcon","fixedUserHandles","flip","flipMode","height","horizontalAlignment","id","isExpanded","layoutInfo","margin","maxHeight","maxWidth","minHeight","minWidth","offsetX","offsetY","padding","pivot","ports","previewSize","rotateAngle","rowIndex","rowSpan","rows","shadow","shape","style","symbolInfo","tooltip","verticalAlignment","visible","width","wrapper","zIndex"],Dle=[],y_=(()=>{class n extends Bh{constructor(e){super(),this.viewContainerRef=e,this.tags=["fixedUserHandles","annotations","ports"],_l("currentInstance",this,this.viewContainerRef),this.registerEvents(Dle),this.directivePropList=Ele}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-node"]],contentQueries:function(e,i,r){if(1&e&&(dn(r,vle,5),dn(r,Ile,5),dn(r,Cle,5)),2&e){let s;Kr(s=en())&&(i.childFixedUserHandles=s.first),Kr(s=en())&&(i.childAnnotations=s.first),Kr(s=en())&&(i.childPorts=s.first)}},inputs:{addInfo:"addInfo",annotations:"annotations",backgroundColor:"backgroundColor",borderColor:"borderColor",borderWidth:"borderWidth",branch:"branch",children:"children",collapseIcon:"collapseIcon",columnIndex:"columnIndex",columnSpan:"columnSpan",columns:"columns",constraints:"constraints",container:"container",data:"data",dragSize:"dragSize",excludeFromLayout:"excludeFromLayout",expandIcon:"expandIcon",fixedUserHandles:"fixedUserHandles",flip:"flip",flipMode:"flipMode",height:"height",horizontalAlignment:"horizontalAlignment",id:"id",isExpanded:"isExpanded",layoutInfo:"layoutInfo",margin:"margin",maxHeight:"maxHeight",maxWidth:"maxWidth",minHeight:"minHeight",minWidth:"minWidth",offsetX:"offsetX",offsetY:"offsetY",padding:"padding",pivot:"pivot",ports:"ports",previewSize:"previewSize",rotateAngle:"rotateAngle",rowIndex:"rowIndex",rowSpan:"rowSpan",rows:"rows",shadow:"shadow",shape:"shape",style:"style",symbolInfo:"symbolInfo",tooltip:"tooltip",verticalAlignment:"verticalAlignment",visible:"visible",width:"width",wrapper:"wrapper",zIndex:"zIndex"},features:[yn]}),n})(),S_=(()=>{class n extends Fh{constructor(){super("nodes")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-nodes"]],contentQueries:function(e,i,r){if(1&e&&dn(r,y_,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})();const xle=["animationComplete","click","collectionChange","commandExecute","connectionChange","contextMenuBeforeItemRender","contextMenuClick","contextMenuOpen","created","dataLoaded","doubleClick","dragEnter","dragLeave","dragOver","drop","elementDraw","expandStateChange","fixedUserHandleClick","historyChange","historyStateChange","keyDown","keyUp","load","loaded","mouseEnter","mouseLeave","mouseOver","mouseWheel","onFixedUserHandleMouseDown","onFixedUserHandleMouseEnter","onFixedUserHandleMouseLeave","onFixedUserHandleMouseUp","onImageLoad","onUserHandleMouseDown","onUserHandleMouseEnter","onUserHandleMouseLeave","onUserHandleMouseUp","positionChange","propertyChange","rotateChange","scrollChange","segmentChange","segmentCollectionChange","selectionChange","sizeChange","sourcePointChange","targetPointChange","textEdit"],Tle=[""];let Ale=(()=>{let n=class extends Fl{constructor(e,i,r,s){super(),this.ngEle=e,this.srenderer=i,this.viewContainerRef=r,this.injector=s,this.tags=["layers","customCursor","connectors","nodes"],this.element=this.ngEle.nativeElement,this.injectedModules=this.injectedModules||[];try{let o=this.injector.get("DiagramsHierarchicalTree");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsMindMap");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsRadialTree");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsComplexHierarchicalTree");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsDataBinding");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsSnapping");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsPrintAndExport");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsBpmnDiagrams");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsSymmetricLayout");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsConnectorBridging");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsUndoRedo");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsLayoutAnimation");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsDiagramContextMenu");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsLineRouting");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsConnectorEditing");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsLineDistribution");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsEj1Serialization");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsFlowchartLayout");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}this.registerEvents(xle),this.addTwoWay.call(this,Tle),_l("currentInstance",this,this.viewContainerRef),this.context=new u_}ngOnInit(){this.context.ngOnInit(this)}ngAfterViewInit(){this.context.ngAfterViewInit(this)}ngOnDestroy(){this.context.ngOnDestroy(this)}ngAfterContentChecked(){this.tagObjects[0].instance=this.childLayers,this.childCustomCursor&&(this.tagObjects[1].instance=this.childCustomCursor),this.childConnectors&&(this.tagObjects[2].instance=this.childConnectors),this.childNodes&&(this.tagObjects[3].instance=this.childNodes),this.context.ngAfterContentChecked(this)}};return n.\u0275fac=function(e){return new(e||n)(Ot($c),Ot(cM),Ot(An),Ot(Wo))},n.\u0275cmp=_b({type:n,selectors:[["ejs-diagram"]],contentQueries:function(e,i,r){if(1&e&&(dn(r,Qae,5),dn(r,Gae,5),dn(r,Xae,5),dn(r,Jae,5),dn(r,ile,5),dn(r,m_,5),dn(r,S_,5)),2&e){let s;Kr(s=en())&&(i.annotationTemplate=s.first),Kr(s=en())&&(i.nodeTemplate=s.first),Kr(s=en())&&(i.userHandleTemplate=s.first),Kr(s=en())&&(i.childLayers=s.first),Kr(s=en())&&(i.childCustomCursor=s.first),Kr(s=en())&&(i.childConnectors=s.first),Kr(s=en())&&(i.childNodes=s.first)}},inputs:{addInfo:"addInfo",annotationTemplate:"annotationTemplate",backgroundColor:"backgroundColor",bridgeDirection:"bridgeDirection",commandManager:"commandManager",connectorDefaults:"connectorDefaults",connectors:"connectors",constraints:"constraints",contextMenuSettings:"contextMenuSettings",customCursor:"customCursor",dataSourceSettings:"dataSourceSettings",diagramSettings:"diagramSettings",drawingObject:"drawingObject",enableConnectorSplit:"enableConnectorSplit",enablePersistence:"enablePersistence",enableRtl:"enableRtl",fixedUserHandleTemplate:"fixedUserHandleTemplate",getConnectorDefaults:"getConnectorDefaults",getCustomCursor:"getCustomCursor",getCustomProperty:"getCustomProperty",getCustomTool:"getCustomTool",getDescription:"getDescription",getNodeDefaults:"getNodeDefaults",height:"height",historyManager:"historyManager",layers:"layers",layout:"layout",locale:"locale",mode:"mode",nodeDefaults:"nodeDefaults",nodeTemplate:"nodeTemplate",nodes:"nodes",pageSettings:"pageSettings",rulerSettings:"rulerSettings",scrollSettings:"scrollSettings",segmentThumbShape:"segmentThumbShape",segmentThumbSize:"segmentThumbSize",selectedItems:"selectedItems",serializationSettings:"serializationSettings",setNodeTemplate:"setNodeTemplate",snapSettings:"snapSettings",tool:"tool",tooltip:"tooltip",updateSelection:"updateSelection",userHandleTemplate:"userHandleTemplate",width:"width"},outputs:{animationComplete:"animationComplete",click:"click",collectionChange:"collectionChange",commandExecute:"commandExecute",connectionChange:"connectionChange",contextMenuBeforeItemRender:"contextMenuBeforeItemRender",contextMenuClick:"contextMenuClick",contextMenuOpen:"contextMenuOpen",created:"created",dataLoaded:"dataLoaded",doubleClick:"doubleClick",dragEnter:"dragEnter",dragLeave:"dragLeave",dragOver:"dragOver",drop:"drop",elementDraw:"elementDraw",expandStateChange:"expandStateChange",fixedUserHandleClick:"fixedUserHandleClick",historyChange:"historyChange",historyStateChange:"historyStateChange",keyDown:"keyDown",keyUp:"keyUp",load:"load",loaded:"loaded",mouseEnter:"mouseEnter",mouseLeave:"mouseLeave",mouseOver:"mouseOver",mouseWheel:"mouseWheel",onFixedUserHandleMouseDown:"onFixedUserHandleMouseDown",onFixedUserHandleMouseEnter:"onFixedUserHandleMouseEnter",onFixedUserHandleMouseLeave:"onFixedUserHandleMouseLeave",onFixedUserHandleMouseUp:"onFixedUserHandleMouseUp",onImageLoad:"onImageLoad",onUserHandleMouseDown:"onUserHandleMouseDown",onUserHandleMouseEnter:"onUserHandleMouseEnter",onUserHandleMouseLeave:"onUserHandleMouseLeave",onUserHandleMouseUp:"onUserHandleMouseUp",positionChange:"positionChange",propertyChange:"propertyChange",rotateChange:"rotateChange",scrollChange:"scrollChange",segmentChange:"segmentChange",segmentCollectionChange:"segmentCollectionChange",selectionChange:"selectionChange",sizeChange:"sizeChange",sourcePointChange:"sourcePointChange",targetPointChange:"targetPointChange",textEdit:"textEdit"},features:[yn],decls:0,vars:0,template:function(e,i){},encapsulation:2,changeDetection:0}),vb([LT()],n.prototype,"annotationTemplate",void 0),vb([LT()],n.prototype,"nodeTemplate",void 0),vb([LT()],n.prototype,"userHandleTemplate",void 0),n=vb([Bae([u_])],n),n})(),Lle=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Lm({type:n}),n.\u0275inj=mp({imports:[[sq]]}),n})();const Nle=["diagram"];let Ole=(()=>{class n{constructor(){this.port1=[{id:"port1",offset:{x:0,y:.5},visibility:Gt.Visible},{id:"port2",offset:{x:.5,y:0},visibility:Gt.Visible}],this.port2=[{id:"port3",offset:{x:0,y:.5},visibility:Gt.Visible},{id:"port4",offset:{x:.5,y:1},visibility:Gt.Visible}]}getInEdges(){console.log(this.diagram.nodes[0].ports[1].inEdges[0])}getOutEdges(){console.log(this.diagram.nodes[0].ports[0].outEdges[0])}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275cmp=_b({type:n,selectors:[["app-container"]],viewQuery:function(i,r){if(1&i&&function fP(n,t,e){const i=Ti();i.firstCreatePass&&(dP(i,new lP(n,t,e),-1),2==(2&t)&&(i.staticViewQueries=!0)),cP(i,Se(),t)}(Nle,5),2&i){let s;Kr(s=en())&&(r.diagram=s.first)}},standalone:!0,features:[PP([]),RP],decls:12,vars:10,consts:[[3,"click"],["id","diagram","width","100%","height","580px"],["diagram",""],["id","node1",3,"offsetX","offsetY","width","height","ports"],["id","node2",3,"offsetX","offsetY","width","height","ports"],["id","connector1","type","Orthogonal","sourceID","node1","sourcePortID","port1","targetID","node2","targetPortID","port3"],["id","connector2","type","Orthogonal","sourceID","node2","sourcePortID","port4","targetID","node1","targetPortID","port2"]],template:function(i,r){1&i&&(id(0,"button",0),Gy("click",function(){return r.getInEdges()}),vw(1,"Get InEdges"),rd(),id(2,"button",0),Gy("click",function(){return r.getOutEdges()}),vw(3,"Get OutEdges"),rd(),id(4,"ejs-diagram",1,2)(6,"e-nodes"),jy(7,"e-node",3)(8,"e-node",4),rd(),id(9,"e-connectors"),jy(10,"e-connector",5)(11,"e-connector",6),rd()()),2&i&&(gM(7),_y("offsetX",250)("offsetY",250)("width",100)("height",100)("ports",r.port1),gM(),_y("offsetX",250)("offsetY",400)("width",100)("height",100)("ports",r.port2))},dependencies:[Lle,Ale,v_,m_,y_,S_],encapsulation:2})}}return n})();Wd(332),function $q(n,t){return DG({rootComponent:n,...Ez(t)})}(Ole).catch(n=>console.error(n))},332:()=>{!function(Z){const se=Z.performance;function ye(zi){se&&se.mark&&se.mark(zi)}function pe(zi,ht){se&&se.measure&&se.measure(zi,ht)}ye("Zone");const be=Z.__Zone_symbol_prefix||"__zone_symbol__";function ke(zi){return be+zi}const at=!0===Z[ke("forceDuplicateZoneCheck")];if(Z.Zone){if(at||"function"!=typeof Z.Zone.__symbol__)throw new Error("Zone already loaded.");return Z.Zone}let tt=(()=>{class zi{static{this.__symbol__=ke}static assertZonePatched(){if(Z.Promise!==_o.ZoneAwarePromise)throw new Error("Zone.js has detected that ZoneAwarePromise `(window|global).Promise` has been overwritten.\nMost likely cause is that a Promise polyfill has been loaded after Zone.js (Polyfilling Promise api is not necessary when zone.js is loaded. If you must load one, do so before loading zone.js.)")}static get root(){let F=zi.current;for(;F.parent;)F=F.parent;return F}static get current(){return Ur.zone}static get currentTask(){return Do}static __load_patch(F,ae,Et=!1){if(_o.hasOwnProperty(F)){if(!Et&&at)throw Error("Already loaded patch: "+F)}else if(!Z["__Zone_disable_"+F]){const qt="Zone:"+F;ye(qt),_o[F]=ae(Z,zi,cn),pe(qt,qt)}}get parent(){return this._parent}get name(){return this._name}constructor(F,ae){this._parent=F,this._name=ae?ae.name||"unnamed":"",this._properties=ae&&ae.properties||{},this._zoneDelegate=new Lt(this,this._parent&&this._parent._zoneDelegate,ae)}get(F){const ae=this.getZoneWith(F);if(ae)return ae._properties[F]}getZoneWith(F){let ae=this;for(;ae;){if(ae._properties.hasOwnProperty(F))return ae;ae=ae._parent}return null}fork(F){if(!F)throw new Error("ZoneSpec required!");return this._zoneDelegate.fork(this,F)}wrap(F,ae){if("function"!=typeof F)throw new Error("Expecting function got: "+F);const Et=this._zoneDelegate.intercept(this,F,ae),qt=this;return function(){return qt.runGuarded(Et,this,arguments,ae)}}run(F,ae,Et,qt){Ur={parent:Ur,zone:this};try{return this._zoneDelegate.invoke(this,F,ae,Et,qt)}finally{Ur=Ur.parent}}runGuarded(F,ae=null,Et,qt){Ur={parent:Ur,zone:this};try{try{return this._zoneDelegate.invoke(this,F,ae,Et,qt)}catch(Vn){if(this._zoneDelegate.handleError(this,Vn))throw Vn}}finally{Ur=Ur.parent}}runTask(F,ae,Et){if(F.zone!=this)throw new Error("A task can only be run in the zone of creation! (Creation: "+(F.zone||jn).name+"; Execution: "+this.name+")");if(F.state===sr&&(F.type===rs||F.type===Pt))return;const qt=F.state!=lt;qt&&F._transitionTo(lt,Pi),F.runCount++;const Vn=Do;Do=F,Ur={parent:Ur,zone:this};try{F.type==Pt&&F.data&&!F.data.isPeriodic&&(F.cancelFn=void 0);try{return this._zoneDelegate.invokeTask(this,F,ae,Et)}catch(Ue){if(this._zoneDelegate.handleError(this,Ue))throw Ue}}finally{F.state!==sr&&F.state!==et&&(F.type==rs||F.data&&F.data.isPeriodic?qt&&F._transitionTo(Pi,lt):(F.runCount=0,this._updateTaskCount(F,-1),qt&&F._transitionTo(sr,lt,sr))),Ur=Ur.parent,Do=Vn}}scheduleTask(F){if(F.zone&&F.zone!==this){let Et=this;for(;Et;){if(Et===F.zone)throw Error(`can not reschedule task to ${this.name} which is descendants of the original zone ${F.zone.name}`);Et=Et.parent}}F._transitionTo(Zr,sr);const ae=[];F._zoneDelegates=ae,F._zone=this;try{F=this._zoneDelegate.scheduleTask(this,F)}catch(Et){throw F._transitionTo(et,Zr,sr),this._zoneDelegate.handleError(this,Et),Et}return F._zoneDelegates===ae&&this._updateTaskCount(F,1),F.state==Zr&&F._transitionTo(Pi,Zr),F}scheduleMicroTask(F,ae,Et,qt){return this.scheduleTask(new pt(yi,F,ae,Et,qt,void 0))}scheduleMacroTask(F,ae,Et,qt,Vn){return this.scheduleTask(new pt(Pt,F,ae,Et,qt,Vn))}scheduleEventTask(F,ae,Et,qt,Vn){return this.scheduleTask(new pt(rs,F,ae,Et,qt,Vn))}cancelTask(F){if(F.zone!=this)throw new Error("A task can only be cancelled in the zone of creation! (Creation: "+(F.zone||jn).name+"; Execution: "+this.name+")");if(F.state===Pi||F.state===lt){F._transitionTo(dr,Pi,lt);try{this._zoneDelegate.cancelTask(this,F)}catch(ae){throw F._transitionTo(et,dr),this._zoneDelegate.handleError(this,ae),ae}return this._updateTaskCount(F,-1),F._transitionTo(sr,dr),F.runCount=0,F}}_updateTaskCount(F,ae){const Et=F._zoneDelegates;-1==ae&&(F._zoneDelegates=null);for(let qt=0;qtzi.hasTask(F,ae),onScheduleTask:(zi,ht,F,ae)=>zi.scheduleTask(F,ae),onInvokeTask:(zi,ht,F,ae,Et,qt)=>zi.invokeTask(F,ae,Et,qt),onCancelTask:(zi,ht,F,ae)=>zi.cancelTask(F,ae)};class Lt{constructor(ht,F,ae){this._taskCounts={microTask:0,macroTask:0,eventTask:0},this.zone=ht,this._parentDelegate=F,this._forkZS=ae&&(ae&&ae.onFork?ae:F._forkZS),this._forkDlgt=ae&&(ae.onFork?F:F._forkDlgt),this._forkCurrZone=ae&&(ae.onFork?this.zone:F._forkCurrZone),this._interceptZS=ae&&(ae.onIntercept?ae:F._interceptZS),this._interceptDlgt=ae&&(ae.onIntercept?F:F._interceptDlgt),this._interceptCurrZone=ae&&(ae.onIntercept?this.zone:F._interceptCurrZone),this._invokeZS=ae&&(ae.onInvoke?ae:F._invokeZS),this._invokeDlgt=ae&&(ae.onInvoke?F:F._invokeDlgt),this._invokeCurrZone=ae&&(ae.onInvoke?this.zone:F._invokeCurrZone),this._handleErrorZS=ae&&(ae.onHandleError?ae:F._handleErrorZS),this._handleErrorDlgt=ae&&(ae.onHandleError?F:F._handleErrorDlgt),this._handleErrorCurrZone=ae&&(ae.onHandleError?this.zone:F._handleErrorCurrZone),this._scheduleTaskZS=ae&&(ae.onScheduleTask?ae:F._scheduleTaskZS),this._scheduleTaskDlgt=ae&&(ae.onScheduleTask?F:F._scheduleTaskDlgt),this._scheduleTaskCurrZone=ae&&(ae.onScheduleTask?this.zone:F._scheduleTaskCurrZone),this._invokeTaskZS=ae&&(ae.onInvokeTask?ae:F._invokeTaskZS),this._invokeTaskDlgt=ae&&(ae.onInvokeTask?F:F._invokeTaskDlgt),this._invokeTaskCurrZone=ae&&(ae.onInvokeTask?this.zone:F._invokeTaskCurrZone),this._cancelTaskZS=ae&&(ae.onCancelTask?ae:F._cancelTaskZS),this._cancelTaskDlgt=ae&&(ae.onCancelTask?F:F._cancelTaskDlgt),this._cancelTaskCurrZone=ae&&(ae.onCancelTask?this.zone:F._cancelTaskCurrZone),this._hasTaskZS=null,this._hasTaskDlgt=null,this._hasTaskDlgtOwner=null,this._hasTaskCurrZone=null;const Et=ae&&ae.onHasTask;(Et||F&&F._hasTaskZS)&&(this._hasTaskZS=Et?ae:At,this._hasTaskDlgt=F,this._hasTaskDlgtOwner=this,this._hasTaskCurrZone=ht,ae.onScheduleTask||(this._scheduleTaskZS=At,this._scheduleTaskDlgt=F,this._scheduleTaskCurrZone=this.zone),ae.onInvokeTask||(this._invokeTaskZS=At,this._invokeTaskDlgt=F,this._invokeTaskCurrZone=this.zone),ae.onCancelTask||(this._cancelTaskZS=At,this._cancelTaskDlgt=F,this._cancelTaskCurrZone=this.zone))}fork(ht,F){return this._forkZS?this._forkZS.onFork(this._forkDlgt,this.zone,ht,F):new tt(ht,F)}intercept(ht,F,ae){return this._interceptZS?this._interceptZS.onIntercept(this._interceptDlgt,this._interceptCurrZone,ht,F,ae):F}invoke(ht,F,ae,Et,qt){return this._invokeZS?this._invokeZS.onInvoke(this._invokeDlgt,this._invokeCurrZone,ht,F,ae,Et,qt):F.apply(ae,Et)}handleError(ht,F){return!this._handleErrorZS||this._handleErrorZS.onHandleError(this._handleErrorDlgt,this._handleErrorCurrZone,ht,F)}scheduleTask(ht,F){let ae=F;if(this._scheduleTaskZS)this._hasTaskZS&&ae._zoneDelegates.push(this._hasTaskDlgtOwner),ae=this._scheduleTaskZS.onScheduleTask(this._scheduleTaskDlgt,this._scheduleTaskCurrZone,ht,F),ae||(ae=F);else if(F.scheduleFn)F.scheduleFn(F);else{if(F.type!=yi)throw new Error("Task is missing scheduleFn.");Wt(F)}return ae}invokeTask(ht,F,ae,Et){return this._invokeTaskZS?this._invokeTaskZS.onInvokeTask(this._invokeTaskDlgt,this._invokeTaskCurrZone,ht,F,ae,Et):F.callback.apply(ae,Et)}cancelTask(ht,F){let ae;if(this._cancelTaskZS)ae=this._cancelTaskZS.onCancelTask(this._cancelTaskDlgt,this._cancelTaskCurrZone,ht,F);else{if(!F.cancelFn)throw Error("Task is not cancelable");ae=F.cancelFn(F)}return ae}hasTask(ht,F){try{this._hasTaskZS&&this._hasTaskZS.onHasTask(this._hasTaskDlgt,this._hasTaskCurrZone,ht,F)}catch(ae){this.handleError(ht,ae)}}_updateTaskCount(ht,F){const ae=this._taskCounts,Et=ae[ht],qt=ae[ht]=Et+F;if(qt<0)throw new Error("More tasks executed then were scheduled.");0!=Et&&0!=qt||this.hasTask(this.zone,{microTask:ae.microTask>0,macroTask:ae.macroTask>0,eventTask:ae.eventTask>0,change:ht})}}class pt{constructor(ht,F,ae,Et,qt,Vn){if(this._zone=null,this.runCount=0,this._zoneDelegates=null,this._state="notScheduled",this.type=ht,this.source=F,this.data=Et,this.scheduleFn=qt,this.cancelFn=Vn,!ae)throw new Error("callback is not defined");this.callback=ae;const Ue=this;this.invoke=ht===rs&&Et&&Et.useG?pt.invokeTask:function(){return pt.invokeTask.call(Z,Ue,this,arguments)}}static invokeTask(ht,F,ae){ht||(ht=this),Ls++;try{return ht.runCount++,ht.zone.runTask(ht,F,ae)}finally{1==Ls&&ct(),Ls--}}get zone(){return this._zone}get state(){return this._state}cancelScheduleRequest(){this._transitionTo(sr,Zr)}_transitionTo(ht,F,ae){if(this._state!==F&&this._state!==ae)throw new Error(`${this.type} '${this.source}': can not transition to '${ht}', expecting state '${F}'${ae?" or '"+ae+"'":""}, was '${this._state}'.`);this._state=ht,ht==sr&&(this._zoneDelegates=null)}toString(){return this.data&&typeof this.data.handleId<"u"?this.data.handleId.toString():Object.prototype.toString.call(this)}toJSON(){return{type:this.type,state:this.state,source:this.source,zone:this.zone.name,runCount:this.runCount}}}const Di=ke("setTimeout"),si=ke("Promise"),mi=ke("then");let is,cr=[],ki=!1;function Pr(zi){if(is||Z[si]&&(is=Z[si].resolve(0)),is){let ht=is[mi];ht||(ht=is.then),ht.call(is,zi)}else Z[Di](zi,0)}function Wt(zi){0===Ls&&0===cr.length&&Pr(ct),zi&&cr.push(zi)}function ct(){if(!ki){for(ki=!0;cr.length;){const zi=cr;cr=[];for(let ht=0;htUr,onUnhandledError:jr,microtaskDrainDone:jr,scheduleMicroTask:Wt,showUncaughtError:()=>!tt[ke("ignoreConsoleErrorUncaughtError")],patchEventTarget:()=>[],patchOnProperties:jr,patchMethod:()=>jr,bindArguments:()=>[],patchThen:()=>jr,patchMacroTask:()=>jr,patchEventPrototype:()=>jr,isIEOrEdge:()=>!1,getGlobalObjects:()=>{},ObjectDefineProperty:()=>jr,ObjectGetOwnPropertyDescriptor:()=>{},ObjectCreate:()=>{},ArraySlice:()=>[],patchClass:()=>jr,wrapWithCurrentZone:()=>jr,filterProperties:()=>[],attachOriginToPatched:()=>jr,_redefineProperty:()=>jr,patchCallbacks:()=>jr,nativeScheduleMicroTask:Pr};let Ur={parent:null,zone:new tt(null,null)},Do=null,Ls=0;function jr(){}pe("Zone","Zone"),Z.Zone=tt}(globalThis);const Wl=Object.getOwnPropertyDescriptor,Vd=Object.defineProperty,Wd=Object.getPrototypeOf,Yd=Object.create,Sb=Array.prototype.slice,pm="addEventListener",$r="removeEventListener",Yl=Zone.__symbol__(pm),_h=Zone.__symbol__($r),Ts="true",Wi="false",Qd=Zone.__symbol__("");function lp(Z,se){return Zone.current.wrap(Z,se)}function gm(Z,se,ye,pe,be){return Zone.current.scheduleMacroTask(Z,se,ye,pe,be)}const Ji=Zone.__symbol__,Uh=typeof window<"u",jh=Uh?window:void 0,gn=Uh&&jh||globalThis,vm="removeAttribute";function Gd(Z,se){for(let ye=Z.length-1;ye>=0;ye--)"function"==typeof Z[ye]&&(Z[ye]=lp(Z[ye],se+"_"+ye));return Z}function hp(Z){return!Z||!1!==Z.writable&&!("function"==typeof Z.get&&typeof Z.set>"u")}const cp=typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope,Vh=!("nw"in gn)&&typeof gn.process<"u"&&"[object process]"==={}.toString.call(gn.process),Xd=!Vh&&!cp&&!(!Uh||!jh.HTMLElement),dp=typeof gn.process<"u"&&"[object process]"==={}.toString.call(gn.process)&&!cp&&!(!Uh||!jh.HTMLElement),Ql={},Wh=function(Z){if(!(Z=Z||gn.event))return;let se=Ql[Z.type];se||(se=Ql[Z.type]=Ji("ON_PROPERTY"+Z.type));const ye=this||Z.target||gn,pe=ye[se];let be;return Xd&&ye===jh&&"error"===Z.type?(be=pe&&pe.call(this,Z.message,Z.filename,Z.lineno,Z.colno,Z.error),!0===be&&Z.preventDefault()):(be=pe&&pe.apply(this,arguments),null!=be&&!be&&Z.preventDefault()),be};function Gl(Z,se,ye){let pe=Wl(Z,se);if(!pe&&ye&&Wl(ye,se)&&(pe={enumerable:!0,configurable:!0}),!pe||!pe.configurable)return;const be=Ji("on"+se+"patched");if(Z.hasOwnProperty(be)&&Z[be])return;delete pe.writable,delete pe.value;const ke=pe.get,at=pe.set,tt=se.slice(2);let At=Ql[tt];At||(At=Ql[tt]=Ji("ON_PROPERTY"+tt)),pe.set=function(Lt){let pt=this;!pt&&Z===gn&&(pt=gn),pt&&("function"==typeof pt[At]&&pt.removeEventListener(tt,Wh),at&&at.call(pt,null),pt[At]=Lt,"function"==typeof Lt&&pt.addEventListener(tt,Wh,!1))},pe.get=function(){let Lt=this;if(!Lt&&Z===gn&&(Lt=gn),!Lt)return null;const pt=Lt[At];if(pt)return pt;if(ke){let Di=ke.call(this);if(Di)return pe.set.call(this,Di),"function"==typeof Lt[vm]&&Lt.removeAttribute(se),Di}return null},Vd(Z,se,pe),Z[be]=!0}function up(Z,se,ye){if(se)for(let pe=0;pefunction(at,tt){const At=ye(at,tt);return At.cbIdx>=0&&"function"==typeof tt[At.cbIdx]?gm(At.name,tt[At.cbIdx],At,be):ke.apply(at,tt)})}function Ia(Z,se){Z[Ji("OriginalDelegate")]=se}let bb=!1,$d=!1;function Mb(){if(bb)return $d;bb=!0;try{const Z=jh.navigator.userAgent;(-1!==Z.indexOf("MSIE ")||-1!==Z.indexOf("Trident/")||-1!==Z.indexOf("Edge/"))&&($d=!0)}catch{}return $d}Zone.__load_patch("ZoneAwarePromise",(Z,se,ye)=>{const pe=Object.getOwnPropertyDescriptor,be=Object.defineProperty,at=ye.symbol,tt=[],At=!1!==Z[at("DISABLE_WRAPPING_UNCAUGHT_PROMISE_REJECTION")],Lt=at("Promise"),pt=at("then"),Di="__creationTrace__";ye.onUnhandledError=Ue=>{if(ye.showUncaughtError()){const He=Ue&&Ue.rejection;He?console.error("Unhandled Promise rejection:",He instanceof Error?He.message:He,"; Zone:",Ue.zone.name,"; Task:",Ue.task&&Ue.task.source,"; Value:",He,He instanceof Error?He.stack:void 0):console.error(Ue)}},ye.microtaskDrainDone=()=>{for(;tt.length;){const Ue=tt.shift();try{Ue.zone.runGuarded(()=>{throw Ue.throwOriginal?Ue.rejection:Ue})}catch(He){mi(He)}}};const si=at("unhandledPromiseRejectionHandler");function mi(Ue){ye.onUnhandledError(Ue);try{const He=se[si];"function"==typeof He&&He.call(this,Ue)}catch{}}function cr(Ue){return Ue&&Ue.then}function ki(Ue){return Ue}function is(Ue){return F.reject(Ue)}const Pr=at("state"),Wt=at("value"),ct=at("finally"),jn=at("parentPromiseValue"),sr=at("parentPromiseState"),Zr="Promise.then",Pi=null,lt=!0,dr=!1,et=0;function yi(Ue,He){return ge=>{try{cn(Ue,He,ge)}catch(We){cn(Ue,!1,We)}}}const Pt=function(){let Ue=!1;return function(ge){return function(){Ue||(Ue=!0,ge.apply(null,arguments))}}},rs="Promise resolved with itself",_o=at("currentTaskTrace");function cn(Ue,He,ge){const We=Pt();if(Ue===ge)throw new TypeError(rs);if(Ue[Pr]===Pi){let wt=null;try{("object"==typeof ge||"function"==typeof ge)&&(wt=ge&&ge.then)}catch(Xe){return We(()=>{cn(Ue,!1,Xe)})(),Ue}if(He!==dr&&ge instanceof F&&ge.hasOwnProperty(Pr)&&ge.hasOwnProperty(Wt)&&ge[Pr]!==Pi)Do(ge),cn(Ue,ge[Pr],ge[Wt]);else if(He!==dr&&"function"==typeof wt)try{wt.call(ge,We(yi(Ue,He)),We(yi(Ue,!1)))}catch(Xe){We(()=>{cn(Ue,!1,Xe)})()}else{Ue[Pr]=He;const Xe=Ue[Wt];if(Ue[Wt]=ge,Ue[ct]===ct&&He===lt&&(Ue[Pr]=Ue[sr],Ue[Wt]=Ue[jn]),He===dr&&ge instanceof Error){const mt=se.currentTask&&se.currentTask.data&&se.currentTask.data[Di];mt&&be(ge,_o,{configurable:!0,enumerable:!1,writable:!0,value:mt})}for(let mt=0;mt{try{const dt=Ue[Wt],$t=!!ge&&ct===ge[ct];$t&&(ge[jn]=dt,ge[sr]=Xe);const hi=He.run(mt,void 0,$t&&mt!==is&&mt!==ki?[]:[dt]);cn(ge,!0,hi)}catch(dt){cn(ge,!1,dt)}},ge)}const zi=function(){},ht=Z.AggregateError;class F{static toString(){return"function ZoneAwarePromise() { [native code] }"}static resolve(He){return He instanceof F?He:cn(new this(null),lt,He)}static reject(He){return cn(new this(null),dr,He)}static withResolvers(){const He={};return He.promise=new F((ge,We)=>{He.resolve=ge,He.reject=We}),He}static any(He){if(!He||"function"!=typeof He[Symbol.iterator])return Promise.reject(new ht([],"All promises were rejected"));const ge=[];let We=0;try{for(let mt of He)We++,ge.push(F.resolve(mt))}catch{return Promise.reject(new ht([],"All promises were rejected"))}if(0===We)return Promise.reject(new ht([],"All promises were rejected"));let wt=!1;const Xe=[];return new F((mt,dt)=>{for(let $t=0;$t{wt||(wt=!0,mt(hi))},hi=>{Xe.push(hi),We--,0===We&&(wt=!0,dt(new ht(Xe,"All promises were rejected")))})})}static race(He){let ge,We,wt=new this((dt,$t)=>{ge=dt,We=$t});function Xe(dt){ge(dt)}function mt(dt){We(dt)}for(let dt of He)cr(dt)||(dt=this.resolve(dt)),dt.then(Xe,mt);return wt}static all(He){return F.allWithCallback(He)}static allSettled(He){return(this&&this.prototype instanceof F?this:F).allWithCallback(He,{thenCallback:We=>({status:"fulfilled",value:We}),errorCallback:We=>({status:"rejected",reason:We})})}static allWithCallback(He,ge){let We,wt,Xe=new this((hi,ur)=>{We=hi,wt=ur}),mt=2,dt=0;const $t=[];for(let hi of He){cr(hi)||(hi=this.resolve(hi));const ur=dt;try{hi.then(ir=>{$t[ur]=ge?ge.thenCallback(ir):ir,mt--,0===mt&&We($t)},ir=>{ge?($t[ur]=ge.errorCallback(ir),mt--,0===mt&&We($t)):wt(ir)})}catch(ir){wt(ir)}mt++,dt++}return mt-=2,0===mt&&We($t),Xe}constructor(He){const ge=this;if(!(ge instanceof F))throw new Error("Must be an instanceof Promise.");ge[Pr]=Pi,ge[Wt]=[];try{const We=Pt();He&&He(We(yi(ge,lt)),We(yi(ge,dr)))}catch(We){cn(ge,!1,We)}}get[Symbol.toStringTag](){return"Promise"}get[Symbol.species](){return F}then(He,ge){let We=this.constructor?.[Symbol.species];(!We||"function"!=typeof We)&&(We=this.constructor||F);const wt=new We(zi),Xe=se.current;return this[Pr]==Pi?this[Wt].push(Xe,wt,He,ge):Ls(this,Xe,wt,He,ge),wt}catch(He){return this.then(null,He)}finally(He){let ge=this.constructor?.[Symbol.species];(!ge||"function"!=typeof ge)&&(ge=F);const We=new ge(zi);We[ct]=ct;const wt=se.current;return this[Pr]==Pi?this[Wt].push(wt,We,He,He):Ls(this,wt,We,He,He),We}}F.resolve=F.resolve,F.reject=F.reject,F.race=F.race,F.all=F.all;const ae=Z[Lt]=Z.Promise;Z.Promise=F;const Et=at("thenPatched");function qt(Ue){const He=Ue.prototype,ge=pe(He,"then");if(ge&&(!1===ge.writable||!ge.configurable))return;const We=He.then;He[pt]=We,Ue.prototype.then=function(wt,Xe){return new F((dt,$t)=>{We.call(this,dt,$t)}).then(wt,Xe)},Ue[Et]=!0}return ye.patchThen=qt,ae&&(qt(ae),tl(Z,"fetch",Ue=>function Vn(Ue){return function(He,ge){let We=Ue.apply(He,ge);if(We instanceof F)return We;let wt=We.constructor;return wt[Et]||qt(wt),We}}(Ue))),Promise[se.__symbol__("uncaughtPromiseErrors")]=tt,F}),Zone.__load_patch("toString",Z=>{const se=Function.prototype.toString,ye=Ji("OriginalDelegate"),pe=Ji("Promise"),be=Ji("Error"),ke=function(){if("function"==typeof this){const Lt=this[ye];if(Lt)return"function"==typeof Lt?se.call(Lt):Object.prototype.toString.call(Lt);if(this===Promise){const pt=Z[pe];if(pt)return se.call(pt)}if(this===Error){const pt=Z[be];if(pt)return se.call(pt)}}return se.call(this)};ke[ye]=se,Function.prototype.toString=ke;const at=Object.prototype.toString;Object.prototype.toString=function(){return"function"==typeof Promise&&this instanceof Promise?"[object Promise]":at.call(this)}});let il=!1;if(typeof window<"u")try{const Z=Object.defineProperty({},"passive",{get:function(){il=!0}});window.addEventListener("test",Z,Z),window.removeEventListener("test",Z,Z)}catch{il=!1}const zT={useG:!0},Co={},wb={},Sm=new RegExp("^"+Qd+"(\\w+)(true|false)$"),Cb=Ji("propagationStopped");function Im(Z,se){const ye=(se?se(Z):Z)+Wi,pe=(se?se(Z):Z)+Ts,be=Qd+ye,ke=Qd+pe;Co[Z]={},Co[Z][Wi]=be,Co[Z][Ts]=ke}function Eb(Z,se,ye,pe){const be=pe&&pe.add||pm,ke=pe&&pe.rm||$r,at=pe&&pe.listeners||"eventListeners",tt=pe&&pe.rmAll||"removeAllListeners",At=Ji(be),Lt="."+be+":",pt="prependListener",Di="."+pt+":",si=function(Wt,ct,jn){if(Wt.isRemoved)return;const sr=Wt.callback;let Zr;"object"==typeof sr&&sr.handleEvent&&(Wt.callback=lt=>sr.handleEvent(lt),Wt.originalDelegate=sr);try{Wt.invoke(Wt,ct,[jn])}catch(lt){Zr=lt}const Pi=Wt.options;return Pi&&"object"==typeof Pi&&Pi.once&&ct[ke].call(ct,jn.type,Wt.originalDelegate?Wt.originalDelegate:Wt.callback,Pi),Zr};function mi(Wt,ct,jn){if(!(ct=ct||Z.event))return;const sr=Wt||ct.target||Z,Zr=sr[Co[ct.type][jn?Ts:Wi]];if(Zr){const Pi=[];if(1===Zr.length){const lt=si(Zr[0],sr,ct);lt&&Pi.push(lt)}else{const lt=Zr.slice();for(let dr=0;dr{throw dr})}}}const cr=function(Wt){return mi(this,Wt,!1)},ki=function(Wt){return mi(this,Wt,!0)};function is(Wt,ct){if(!Wt)return!1;let jn=!0;ct&&void 0!==ct.useG&&(jn=ct.useG);const sr=ct&&ct.vh;let Zr=!0;ct&&void 0!==ct.chkDup&&(Zr=ct.chkDup);let Pi=!1;ct&&void 0!==ct.rt&&(Pi=ct.rt);let lt=Wt;for(;lt&&!lt.hasOwnProperty(be);)lt=Wd(lt);if(!lt&&Wt[be]&&(lt=Wt),!lt||lt[At])return!1;const dr=ct&&ct.eventNameToString,et={},yi=lt[At]=lt[be],Pt=lt[Ji(ke)]=lt[ke],rs=lt[Ji(at)]=lt[at],_o=lt[Ji(tt)]=lt[tt];let cn;ct&&ct.prepend&&(cn=lt[Ji(ct.prepend)]=lt[ct.prepend]);const F=jn?function(ge){if(!et.isExisting)return yi.call(et.target,et.eventName,et.capture?ki:cr,et.options)}:function(ge){return yi.call(et.target,et.eventName,ge.invoke,et.options)},ae=jn?function(ge){if(!ge.isRemoved){const We=Co[ge.eventName];let wt;We&&(wt=We[ge.capture?Ts:Wi]);const Xe=wt&&ge.target[wt];if(Xe)for(let mt=0;mt{Vo.zone.cancelTask(Vo)},{once:!0})),et.target=null,Fc&&(Fc.taskData=null),Jd&&(Tn.once=!0),!il&&"boolean"==typeof Vo.options||(Vo.options=Tn),Vo.target=$t,Vo.capture=Zl,Vo.eventName=hi,ir&&(Vo.originalDelegate=ur),dt?jo.unshift(Vo):jo.push(Vo),mt?$t:void 0}};return lt[be]=He(yi,Lt,F,ae,Pi),cn&&(lt[pt]=He(cn,Di,function(ge){return cn.call(et.target,et.eventName,ge.invoke,et.options)},ae,Pi,!0)),lt[ke]=function(){const ge=this||Z;let We=arguments[0];ct&&ct.transferEventName&&(We=ct.transferEventName(We));const wt=arguments[2],Xe=!!wt&&("boolean"==typeof wt||wt.capture),mt=arguments[1];if(!mt)return Pt.apply(this,arguments);if(sr&&!sr(Pt,mt,ge,arguments))return;const dt=Co[We];let $t;dt&&($t=dt[Xe?Ts:Wi]);const hi=$t&&ge[$t];if(hi)for(let ur=0;urfunction(be,ke){be[Cb]=!0,pe&&pe.apply(be,ke)})}function xb(Z,se,ye,pe,be){const ke=Zone.__symbol__(pe);if(se[ke])return;const at=se[ke]=se[pe];se[pe]=function(tt,At,Lt){return At&&At.prototype&&be.forEach(function(pt){const Di=`${ye}.${pe}::`+pt,si=At.prototype;try{if(si.hasOwnProperty(pt)){const mi=Z.ObjectGetOwnPropertyDescriptor(si,pt);mi&&mi.value?(mi.value=Z.wrapWithCurrentZone(mi.value,Di),Z._redefineProperty(At.prototype,pt,mi)):si[pt]&&(si[pt]=Z.wrapWithCurrentZone(si[pt],Di))}else si[pt]&&(si[pt]=Z.wrapWithCurrentZone(si[pt],Di))}catch{}}),at.call(se,tt,At,Lt)},Z.attachOriginToPatched(se[pe],at)}function Tb(Z,se,ye){if(!ye||0===ye.length)return se;const pe=ye.filter(ke=>ke.target===Z);if(!pe||0===pe.length)return se;const be=pe[0].ignoreProperties;return se.filter(ke=>-1===be.indexOf(ke))}function Eo(Z,se,ye,pe){Z&&up(Z,Tb(Z,se,ye),pe)}function Zd(Z){return Object.getOwnPropertyNames(Z).filter(se=>se.startsWith("on")&&se.length>2).map(se=>se.substring(2))}Zone.__load_patch("util",(Z,se,ye)=>{const pe=Zd(Z);ye.patchOnProperties=up,ye.patchMethod=tl,ye.bindArguments=Gd,ye.patchMacroTask=Ib;const be=se.__symbol__("BLACK_LISTED_EVENTS"),ke=se.__symbol__("UNPATCHED_EVENTS");Z[ke]&&(Z[be]=Z[ke]),Z[be]&&(se[be]=se[ke]=Z[be]),ye.patchEventPrototype=bm,ye.patchEventTarget=Eb,ye.isIEOrEdge=Mb,ye.ObjectDefineProperty=Vd,ye.ObjectGetOwnPropertyDescriptor=Wl,ye.ObjectCreate=Yd,ye.ArraySlice=Sb,ye.patchClass=qd,ye.wrapWithCurrentZone=lp,ye.filterProperties=Tb,ye.attachOriginToPatched=Ia,ye._redefineProperty=Object.defineProperty,ye.patchCallbacks=xb,ye.getGlobalObjects=()=>({globalSources:wb,zoneSymbolEventNames:Co,eventNames:pe,isBrowser:Xd,isMix:dp,isNode:Vh,TRUE_STR:Ts,FALSE_STR:Wi,ZONE_SYMBOL_PREFIX:Qd,ADD_EVENT_LISTENER_STR:pm,REMOVE_EVENT_LISTENER_STR:$r})});const As=Ji("zoneTask");function Xl(Z,se,ye,pe){let be=null,ke=null;ye+=pe;const at={};function tt(Lt){const pt=Lt.data;return pt.args[0]=function(){return Lt.invoke.apply(this,arguments)},pt.handleId=be.apply(Z,pt.args),Lt}function At(Lt){return ke.call(Z,Lt.data.handleId)}be=tl(Z,se+=pe,Lt=>function(pt,Di){if("function"==typeof Di[0]){const si={isPeriodic:"Interval"===pe,delay:"Timeout"===pe||"Interval"===pe?Di[1]||0:void 0,args:Di},mi=Di[0];Di[0]=function(){try{return mi.apply(this,arguments)}finally{si.isPeriodic||("number"==typeof si.handleId?delete at[si.handleId]:si.handleId&&(si.handleId[As]=null))}};const cr=gm(se,Di[0],si,tt,At);if(!cr)return cr;const ki=cr.data.handleId;return"number"==typeof ki?at[ki]=cr:ki&&(ki[As]=cr),ki&&ki.ref&&ki.unref&&"function"==typeof ki.ref&&"function"==typeof ki.unref&&(cr.ref=ki.ref.bind(ki),cr.unref=ki.unref.bind(ki)),"number"==typeof ki||ki?ki:cr}return Lt.apply(Z,Di)}),ke=tl(Z,ye,Lt=>function(pt,Di){const si=Di[0];let mi;"number"==typeof si?mi=at[si]:(mi=si&&si[As],mi||(mi=si)),mi&&"string"==typeof mi.type?"notScheduled"!==mi.state&&(mi.cancelFn&&mi.data.isPeriodic||0===mi.runCount)&&("number"==typeof si?delete at[si]:si&&(si[As]=null),mi.zone.cancelTask(mi)):Lt.apply(Z,Di)})}Zone.__load_patch("legacy",Z=>{const se=Z[Zone.__symbol__("legacyPatch")];se&&se()}),Zone.__load_patch("timers",Z=>{const ye="clear";Xl(Z,"set",ye,"Timeout"),Xl(Z,"set",ye,"Interval"),Xl(Z,"set",ye,"Immediate")}),Zone.__load_patch("requestAnimationFrame",Z=>{Xl(Z,"request","cancel","AnimationFrame"),Xl(Z,"mozRequest","mozCancel","AnimationFrame"),Xl(Z,"webkitRequest","webkitCancel","AnimationFrame")}),Zone.__load_patch("blocking",(Z,se)=>{const ye=["alert","prompt","confirm"];for(let pe=0;pefunction(At,Lt){return se.current.run(ke,Z,Lt,tt)})}),Zone.__load_patch("EventTarget",(Z,se,ye)=>{(function ql(Z,se){se.patchEventPrototype(Z,se)})(Z,ye),function wm(Z,se){if(Zone[se.symbol("patchEventTarget")])return;const{eventNames:ye,zoneSymbolEventNames:pe,TRUE_STR:be,FALSE_STR:ke,ZONE_SYMBOL_PREFIX:at}=se.getGlobalObjects();for(let At=0;At{qd("MutationObserver"),qd("WebKitMutationObserver")}),Zone.__load_patch("IntersectionObserver",(Z,se,ye)=>{qd("IntersectionObserver")}),Zone.__load_patch("FileReader",(Z,se,ye)=>{qd("FileReader")}),Zone.__load_patch("on_property",(Z,se,ye)=>{!function fp(Z,se){if(Vh&&!dp||Zone[Z.symbol("patchEvents")])return;const ye=se.__Zone_ignore_on_properties;let pe=[];if(Xd){const be=window;pe=pe.concat(["Document","SVGElement","Element","HTMLElement","HTMLBodyElement","HTMLMediaElement","HTMLFrameSetElement","HTMLFrameElement","HTMLIFrameElement","HTMLMarqueeElement","Worker"]);const ke=function ym(){try{const Z=jh.navigator.userAgent;if(-1!==Z.indexOf("MSIE ")||-1!==Z.indexOf("Trident/"))return!0}catch{}return!1}()?[{target:be,ignoreProperties:["error"]}]:[];Eo(be,Zd(be),ye&&ye.concat(ke),Wd(be))}pe=pe.concat(["XMLHttpRequest","XMLHttpRequestEventTarget","IDBIndex","IDBRequest","IDBOpenDBRequest","IDBDatabase","IDBTransaction","IDBCursor","WebSocket"]);for(let be=0;be{!function Mm(Z,se){const{isBrowser:ye,isMix:pe}=se.getGlobalObjects();(ye||pe)&&Z.customElements&&"customElements"in Z&&se.patchCallbacks(se,Z.customElements,"customElements","define",["connectedCallback","disconnectedCallback","adoptedCallback","attributeChangedCallback"])}(Z,ye)}),Zone.__load_patch("XHR",(Z,se)=>{!function At(Lt){const pt=Lt.XMLHttpRequest;if(!pt)return;const Di=pt.prototype;let mi=Di[Yl],cr=Di[_h];if(!mi){const et=Lt.XMLHttpRequestEventTarget;if(et){const yi=et.prototype;mi=yi[Yl],cr=yi[_h]}}const ki="readystatechange",is="scheduled";function Pr(et){const yi=et.data,Pt=yi.target;Pt[ke]=!1,Pt[tt]=!1;const rs=Pt[be];mi||(mi=Pt[Yl],cr=Pt[_h]),rs&&cr.call(Pt,ki,rs);const _o=Pt[be]=()=>{if(Pt.readyState===Pt.DONE)if(!yi.aborted&&Pt[ke]&&et.state===is){const Ur=Pt[se.__symbol__("loadfalse")];if(0!==Pt.status&&Ur&&Ur.length>0){const Do=et.invoke;et.invoke=function(){const Ls=Pt[se.__symbol__("loadfalse")];for(let jr=0;jrfunction(et,yi){return et[pe]=0==yi[2],et[at]=yi[1],jn.apply(et,yi)}),Zr=Ji("fetchTaskAborting"),Pi=Ji("fetchTaskScheduling"),lt=tl(Di,"send",()=>function(et,yi){if(!0===se.current[Pi]||et[pe])return lt.apply(et,yi);{const Pt={target:et,url:et[at],isPeriodic:!1,args:yi,aborted:!1},rs=gm("XMLHttpRequest.send",Wt,Pt,Pr,ct);et&&!0===et[tt]&&!Pt.aborted&&rs.state===is&&rs.invoke()}}),dr=tl(Di,"abort",()=>function(et,yi){const Pt=function si(et){return et[ye]}(et);if(Pt&&"string"==typeof Pt.type){if(null==Pt.cancelFn||Pt.data&&Pt.data.aborted)return;Pt.zone.cancelTask(Pt)}else if(!0===se.current[Zr])return dr.apply(et,yi)})}(Z);const ye=Ji("xhrTask"),pe=Ji("xhrSync"),be=Ji("xhrListener"),ke=Ji("xhrScheduled"),at=Ji("xhrURL"),tt=Ji("xhrErrorBeforeScheduled")}),Zone.__load_patch("geolocation",Z=>{Z.navigator&&Z.navigator.geolocation&&function mm(Z,se){const ye=Z.constructor.name;for(let pe=0;pe{const At=function(){return tt.apply(this,Gd(arguments,ye+"."+be))};return Ia(At,tt),At})(ke)}}}(Z.navigator.geolocation,["getCurrentPosition","watchPosition"])}),Zone.__load_patch("PromiseRejectionEvent",(Z,se)=>{function ye(pe){return function(be){Db(Z,pe).forEach(at=>{const tt=Z.PromiseRejectionEvent;if(tt){const At=new tt(pe,{promise:be.promise,reason:be.rejection});at.invoke(At)}})}}Z.PromiseRejectionEvent&&(se[Ji("unhandledPromiseRejectionHandler")]=ye("unhandledrejection"),se[Ji("rejectionHandledHandler")]=ye("rejectionhandled"))}),Zone.__load_patch("queueMicrotask",(Z,se,ye)=>{!function pp(Z,se){se.patchMethod(Z,"queueMicrotask",ye=>function(pe,be){Zone.current.scheduleMicroTask("queueMicrotask",be[0])})}(Z,ye)})}},Wl=>{Wl(Wl.s=51)}]); \ No newline at end of file diff --git a/ej2-angular/samples/diagram/ports/node-cs1/index.html b/ej2-angular/samples/diagram/ports/node-cs1/index.html index 05bc38f311..451a1dbbfb 100644 --- a/ej2-angular/samples/diagram/ports/node-cs1/index.html +++ b/ej2-angular/samples/diagram/ports/node-cs1/index.html @@ -19,5 +19,5 @@
Loading....
- + \ No newline at end of file diff --git a/ej2-angular/samples/diagram/ports/node-cs1/main.5b5747e17b12a4e6.js b/ej2-angular/samples/diagram/ports/node-cs1/main.5b5747e17b12a4e6.js deleted file mode 100644 index b38b1b6039..0000000000 --- a/ej2-angular/samples/diagram/ports/node-cs1/main.5b5747e17b12a4e6.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";(self.webpackChunksyncfusion_component=self.webpackChunksyncfusion_component||[]).push([[179],{51:(_l,_d,Ud)=>{let $r=null,Fh=1;const Ts=Symbol("SIGNAL");function Wi(n){const t=$r;return $r=n,t}function gn(n){if((!Vh(n)||n.dirty)&&(n.dirty||n.lastCleanEpoch!==Fh)){if(!n.producerMustRecompute(n)&&!jh(n))return n.dirty=!1,void(n.lastCleanEpoch=Fh);n.producerRecomputeValue(n),n.dirty=!1,n.lastCleanEpoch=Fh}}function jh(n){Vl(n);for(let t=0;t0}function Vl(n){n.producerNode??=[],n.producerIndexOfThis??=[],n.producerLastReadVersion??=[]}let Gd=null;function Eo(n){return"function"==typeof n}function Xd(n){const e=n(i=>{Error.call(i),i.stack=(new Error).stack});return e.prototype=Object.create(Error.prototype),e.prototype.constructor=e,e}const df=Xd(n=>function(e){n(this),this.message=e?`${e.length} errors occurred during unsubscription:\n${e.map((i,r)=>`${r+1}) ${i.toString()}`).join("\n ")}`:"",this.name="UnsubscriptionError",this.errors=e});function uf(n,t){if(n){const e=n.indexOf(t);0<=e&&n.splice(e,1)}}class As{constructor(t){this.initialTeardown=t,this.closed=!1,this._parentage=null,this._finalizers=null}unsubscribe(){let t;if(!this.closed){this.closed=!0;const{_parentage:e}=this;if(e)if(this._parentage=null,Array.isArray(e))for(const s of e)s.remove(this);else e.remove(this);const{initialTeardown:i}=this;if(Eo(i))try{i()}catch(s){t=s instanceof df?s.errors:[s]}const{_finalizers:r}=this;if(r){this._finalizers=null;for(const s of r)try{Mm(s)}catch(o){t=t??[],o instanceof df?t=[...t,...o.errors]:t.push(o)}}if(t)throw new df(t)}}add(t){var e;if(t&&t!==this)if(this.closed)Mm(t);else{if(t instanceof As){if(t.closed||t._hasParent(this))return;t._addParent(this)}(this._finalizers=null!==(e=this._finalizers)&&void 0!==e?e:[]).push(t)}}_hasParent(t){const{_parentage:e}=this;return e===t||Array.isArray(e)&&e.includes(t)}_addParent(t){const{_parentage:e}=this;this._parentage=Array.isArray(e)?(e.push(t),e):e?[e,t]:t}_removeParent(t){const{_parentage:e}=this;e===t?this._parentage=null:Array.isArray(e)&&uf(e,t)}remove(t){const{_finalizers:e}=this;e&&uf(e,t),t instanceof As&&t._removeParent(this)}}As.EMPTY=(()=>{const n=new As;return n.closed=!0,n})();const Wl=As.EMPTY;function bm(n){return n instanceof As||n&&"closed"in n&&Eo(n.remove)&&Eo(n.add)&&Eo(n.unsubscribe)}function Mm(n){Eo(n)?n():n.unsubscribe()}const Yl={onUnhandledError:null,onStoppedNotification:null,Promise:void 0,useDeprecatedSynchronousErrorHandling:!1,useDeprecatedNextContext:!1},Z={setTimeout(n,t,...e){const{delegate:i}=Z;return i?.setTimeout?i.setTimeout(n,t,...e):setTimeout(n,t,...e)},clearTimeout(n){const{delegate:t}=Z;return(t?.clearTimeout||clearTimeout)(n)},delegate:void 0};function ye(){}const fe=at("C",void 0,void 0);function at(n,t,e){return{kind:n,value:t,error:e}}let tt=null;function At(n){if(Yl.useDeprecatedSynchronousErrorHandling){const t=!tt;if(t&&(tt={errorThrown:!1,error:null}),n(),t){const{errorThrown:e,error:i}=tt;if(tt=null,e)throw i}}else n()}class ft extends As{constructor(t){super(),this.isStopped=!1,t?(this.destination=t,bm(t)&&t.add(this)):this.destination=Wt}static create(t,e,i){return new cr(t,e,i)}next(t){this.isStopped?kr(function ke(n){return at("N",n,void 0)}(t),this):this._next(t)}error(t){this.isStopped?kr(function be(n){return at("E",void 0,n)}(t),this):(this.isStopped=!0,this._error(t))}complete(){this.isStopped?kr(fe,this):(this.isStopped=!0,this._complete())}unsubscribe(){this.closed||(this.isStopped=!0,super.unsubscribe(),this.destination=null)}_next(t){this.destination.next(t)}_error(t){try{this.destination.error(t)}finally{this.unsubscribe()}}_complete(){try{this.destination.complete()}finally{this.unsubscribe()}}}const Ei=Function.prototype.bind;function ti(n,t){return Ei.call(n,t)}class gi{constructor(t){this.partialObserver=t}next(t){const{partialObserver:e}=this;if(e.next)try{e.next(t)}catch(i){Oi(i)}}error(t){const{partialObserver:e}=this;if(e.error)try{e.error(t)}catch(i){Oi(i)}else Oi(t)}complete(){const{partialObserver:t}=this;if(t.complete)try{t.complete()}catch(e){Oi(e)}}}class cr extends ft{constructor(t,e,i){let r;if(super(),Eo(t)||!t)r={next:t??void 0,error:e??void 0,complete:i??void 0};else{let s;this&&Yl.useDeprecatedNextContext?(s=Object.create(t),s.unsubscribe=()=>this.unsubscribe(),r={next:t.next&&ti(t.next,s),error:t.error&&ti(t.error,s),complete:t.complete&&ti(t.complete,s)}):r=t}this.destination=new gi(r)}}function Oi(n){Yl.useDeprecatedSynchronousErrorHandling?function Lt(n){Yl.useDeprecatedSynchronousErrorHandling&&tt&&(tt.errorThrown=!0,tt.error=n)}(n):function se(n){Z.setTimeout(()=>{const{onUnhandledError:t}=Yl;if(!t)throw n;t(n)})}(n)}function kr(n,t){const{onStoppedNotification:e}=Yl;e&&Z.setTimeout(()=>e(n,t))}const Wt={closed:!0,next:ye,error:function es(n){throw n},complete:ye},ct="function"==typeof Symbol&&Symbol.observable||"@@observable";function _n(n){return n}let ki=(()=>{class n{constructor(e){e&&(this._subscribe=e)}lift(e){const i=new n;return i.source=this,i.operator=e,i}subscribe(e,i,r){const s=function et(n){return n&&n instanceof ft||function dr(n){return n&&Eo(n.next)&&Eo(n.error)&&Eo(n.complete)}(n)&&bm(n)}(e)?e:new cr(e,i,r);return At(()=>{const{operator:o,source:a}=this;s.add(o?o.call(s,a):a?this._subscribe(s):this._trySubscribe(s))}),s}_trySubscribe(e){try{return this._subscribe(e)}catch(i){e.error(i)}}forEach(e,i){return new(i=lt(i))((r,s)=>{const o=new cr({next:a=>{try{e(a)}catch(l){s(l),o.unsubscribe()}},error:s,complete:r});this.subscribe(o)})}_subscribe(e){var i;return null===(i=this.source)||void 0===i?void 0:i.subscribe(e)}[ct](){return this}pipe(...e){return function Zr(n){return 0===n.length?_n:1===n.length?n[0]:function(e){return n.reduce((i,r)=>r(i),e)}}(e)(this)}toPromise(e){return new(e=lt(e))((i,r)=>{let s;this.subscribe(o=>s=o,o=>r(o),()=>i(s))})}}return n.create=t=>new n(t),n})();function lt(n){var t;return null!==(t=n??Yl.Promise)&&void 0!==t?t:Promise}const vi=Xd(n=>function(){n(this),this.name="ObjectUnsubscribedError",this.message="object unsubscribed"});let Pt=(()=>{class n extends ki{constructor(){super(),this.closed=!1,this.currentObservers=null,this.observers=[],this.isStopped=!1,this.hasError=!1,this.thrownError=null}lift(e){const i=new ts(this,this);return i.operator=e,i}_throwIfClosed(){if(this.closed)throw new vi}next(e){At(()=>{if(this._throwIfClosed(),!this.isStopped){this.currentObservers||(this.currentObservers=Array.from(this.observers));for(const i of this.currentObservers)i.next(e)}})}error(e){At(()=>{if(this._throwIfClosed(),!this.isStopped){this.hasError=this.isStopped=!0,this.thrownError=e;const{observers:i}=this;for(;i.length;)i.shift().error(e)}})}complete(){At(()=>{if(this._throwIfClosed(),!this.isStopped){this.isStopped=!0;const{observers:e}=this;for(;e.length;)e.shift().complete()}})}unsubscribe(){this.isStopped=this.closed=!0,this.observers=this.currentObservers=null}get observed(){var e;return(null===(e=this.observers)||void 0===e?void 0:e.length)>0}_trySubscribe(e){return this._throwIfClosed(),super._trySubscribe(e)}_subscribe(e){return this._throwIfClosed(),this._checkFinalizedStatuses(e),this._innerSubscribe(e)}_innerSubscribe(e){const{hasError:i,isStopped:r,observers:s}=this;return i||r?Wl:(this.currentObservers=null,s.push(e),new As(()=>{this.currentObservers=null,uf(s,e)}))}_checkFinalizedStatuses(e){const{hasError:i,thrownError:r,isStopped:s}=this;i?e.error(r):s&&e.complete()}asObservable(){const e=new ki;return e.source=this,e}}return n.create=(t,e)=>new ts(t,e),n})();class ts extends Pt{constructor(t,e){super(),this.destination=t,this.source=e}next(t){var e,i;null===(i=null===(e=this.destination)||void 0===e?void 0:e.next)||void 0===i||i.call(e,t)}error(t){var e,i;null===(i=null===(e=this.destination)||void 0===e?void 0:e.error)||void 0===i||i.call(e,t)}complete(){var t,e;null===(e=null===(t=this.destination)||void 0===t?void 0:t.complete)||void 0===e||e.call(t)}_subscribe(t){var e,i;return null!==(i=null===(e=this.source)||void 0===e?void 0:e.subscribe(t))&&void 0!==i?i:Wl}}class _o extends Pt{constructor(t){super(),this._value=t}get value(){return this.getValue()}_subscribe(t){const e=super._subscribe(t);return!e.closed&&t.next(this._value),e}getValue(){const{hasError:t,thrownError:e,_value:i}=this;if(t)throw e;return this._throwIfClosed(),i}next(t){super.next(this._value=t)}}class Ls extends ft{constructor(t,e,i,r,s,o){super(t),this.onFinalize=s,this.shouldUnsubscribe=o,this._next=e?function(a){try{e(a)}catch(l){t.error(l)}}:super._next,this._error=r?function(a){try{r(a)}catch(l){t.error(l)}finally{this.unsubscribe()}}:super._error,this._complete=i?function(){try{i()}catch(a){t.error(a)}finally{this.unsubscribe()}}:super._complete}unsubscribe(){var t;if(!this.shouldUnsubscribe||this.shouldUnsubscribe()){const{closed:e}=this;super.unsubscribe(),!e&&(null===(t=this.onFinalize)||void 0===t||t.call(this))}}}function jr(n,t){return function Ur(n){return t=>{if(function cn(n){return Eo(n?.lift)}(t))return t.lift(function(e){try{return n(e,this)}catch(i){this.error(i)}});throw new TypeError("Unable to lift unknown Observable type")}}((e,i)=>{let r=0;e.subscribe(function Do(n,t,e,i,r){return new Ls(n,t,e,i,r)}(i,s=>{i.next(n.call(t,s,r++))}))})}class F extends Error{constructor(t,e){super(function ae(n,t){return`NG0${Math.abs(n)}${t?": "+t:""}`}(t,e)),this.code=t}}function Xe(n){for(let t in n)if(n[t]===Xe)return t;throw Error("Could not find renamed property on target object.")}function mt(n,t){for(const e in t)t.hasOwnProperty(e)&&!n.hasOwnProperty(e)&&(n[e]=t[e])}function dt(n){if("string"==typeof n)return n;if(Array.isArray(n))return"["+n.map(dt).join(", ")+"]";if(null==n)return""+n;if(n.overriddenName)return`${n.overriddenName}`;if(n.name)return`${n.name}`;const t=n.toString();if(null==t)return""+t;const e=t.indexOf("\n");return-1===e?t:t.substring(0,e)}function qt(n,t){return null==n||""===n?null===t?"":t:null==t||""===t?n:n+" "+t}const ur=Xe({__forward_ref__:Xe});function ir(n){return n.__forward_ref__=ir,n.toString=function(){return dt(this())},n}function vt(n){return function Dn(n){return"function"==typeof n&&n.hasOwnProperty(ur)&&n.__forward_ref__===ir}(n)?n():n}function Ql(n){return n&&!!n.\u0275providers}const Gl=Xe({\u0275cmp:Xe}),qd=Xe({\u0275dir:Xe}),pf=Xe({\u0275pipe:Xe}),Uo=Xe({\u0275fac:Xe}),jo=Xe({__NG_ELEMENT_ID__:Xe}),ff=Xe({__NG_ENV_ID__:Xe});function zi(n){return"function"==typeof n?n.name||n.toString():"object"==typeof n&&null!=n&&"function"==typeof n.type?n.type.name||n.type.toString():function Nt(n){return"string"==typeof n?n:null==n?"":String(n)}(n)}function Db(n,t){throw new F(-201,!1)}function ro(n,t){null==n&&function zt(n,t,e,i){throw new Error(`ASSERTION ERROR: ${n}`+(null==i?"":` [Expected=> ${e} ${i} ${t} <=Actual]`))}(t,n,null,"!=")}function Yi(n){return{token:n.token,providedIn:n.providedIn||null,factory:n.factory,value:void 0}}function gf(n){return{providers:n.providers||[],imports:n.imports||[]}}function wm(n){return PT(n,Em)||PT(n,zT)}function PT(n,t){return n.hasOwnProperty(t)?n[t]:null}function Cm(n){return n&&(n.hasOwnProperty(xb)||n.hasOwnProperty(E_))?n[xb]:null}const Em=Xe({\u0275prov:Xe}),xb=Xe({\u0275inj:Xe}),zT=Xe({ngInjectableDef:Xe}),E_=Xe({ngInjectorDef:Xe});var Di=function(n){return n[n.Default=0]="Default",n[n.Host=1]="Host",n[n.Self=2]="Self",n[n.SkipSelf=4]="SkipSelf",n[n.Optional=8]="Optional",n}(Di||{});let Tb;function no(n){const t=Tb;return Tb=n,t}function HT(n,t,e){const i=wm(n);return i&&"root"==i.providedIn?void 0===i.value?i.value=i.factory():i.value:e&Di.Optional?null:void 0!==t?t:void Db()}const rr=globalThis;class Ht{constructor(t,e){this._desc=t,this.ngMetadataName="InjectionToken",this.\u0275prov=void 0,"number"==typeof e?this.__NG_ELEMENT_ID__=e:void 0!==e&&(this.\u0275prov=Yi({token:this,providedIn:e.providedIn||"root",factory:e.factory}))}get multi(){return this}toString(){return`InjectionToken ${this._desc}`}}const vf={},kb="__NG_DI_FLAG__",Dm="ngTempTokenPath",T_=/\n/gm,FT="__source";let Zd;function Qh(n){const t=Zd;return Zd=n,t}function N_(n,t=Di.Default){if(void 0===Zd)throw new F(-203,!1);return null===Zd?HT(n,void 0,t):Zd.get(n,t&Di.Optional?null:void 0,t)}function Fi(n,t=Di.Default){return(function RT(){return Tb}()||N_)(vt(n),t)}function Ri(n,t=Di.Default){return Fi(n,xm(t))}function xm(n){return typeof n>"u"||"number"==typeof n?n:0|(n.optional&&8)|(n.host&&1)|(n.self&&2)|(n.skipSelf&&4)}function Pb(n){const t=[];for(let e=0;et){o=s-1;break}}}for(;ss?"":r[d+1].toLowerCase();const p=8&i?u:null;if(p&&-1!==UT(p,h,0)||2&i&&h!==u){if(ba(i))return!1;o=!0}}}}else{if(!o&&!ba(i)&&!ba(l))return!1;if(o&&ba(l))continue;o=!1,i=l|1&i}}return ba(i)||o}function ba(n){return 0==(1&n)}function B_(n,t,e,i){if(null===t)return-1;let r=0;if(i||!e){let s=!1;for(;r-1)for(e++;e0?'="'+a+'"':"")+"]"}else 8&i?r+="."+o:4&i&&(r+=" "+o);else""!==r&&!ba(o)&&(t+=XT(s,r),r=""),i=o,s=s||!ba(i);e++}return""!==r&&(t+=XT(s,r)),t}function Rb(n){return Xl(()=>{const t=$T(n),e={...t,decls:n.decls,vars:n.vars,template:n.template,consts:n.consts||null,ngContentSelectors:n.ngContentSelectors,onPush:n.changeDetection===Tm.OnPush,directiveDefs:null,pipeDefs:null,dependencies:t.standalone&&n.dependencies||null,getStandaloneInjector:null,signals:n.signals??!1,data:n.data||{},encapsulation:n.encapsulation||Ia.Emulated,styles:n.styles||Qi,_:null,schemas:n.schemas||null,tView:null,id:""};ZT(e);const i=n.dependencies;return e.directiveDefs=Lm(i,!1),e.pipeDefs=Lm(i,!0),e.id=function q_(n){let t=0;const e=[n.selectors,n.ngContentSelectors,n.hostVars,n.hostAttrs,n.consts,n.vars,n.decls,n.encapsulation,n.standalone,n.signals,n.exportAs,JSON.stringify(n.inputs),JSON.stringify(n.outputs),Object.getOwnPropertyNames(n.type.prototype),!!n.contentQueries,!!n.viewQuery].join("|");for(const r of e)t=Math.imul(31,t)+r.charCodeAt(0)<<0;return t+=2147483648,"c"+t}(e),e})}function Q_(n){return ci(n)||jn(n)}function G_(n){return null!==n}function Am(n){return Xl(()=>({type:n.type,bootstrap:n.bootstrap||Qi,declarations:n.declarations||Qi,imports:n.imports||Qi,exports:n.exports||Qi,transitiveCompileScopes:null,schemas:n.schemas||null,id:n.id||null}))}function qT(n,t){if(null==n)return tl;const e={};for(const i in n)if(n.hasOwnProperty(i)){const r=n[i];let s,o,a=Gh.None;Array.isArray(r)?(a=r[0],s=r[1],o=r[2]??s):(s=r,o=r),t?(e[s]=a!==Gh.None?[i,a]:i,t[s]=o):e[s]=i}return e}function nr(n){return Xl(()=>{const t=$T(n);return ZT(t),t})}function ci(n){return n[Gl]||null}function jn(n){return n[qd]||null}function gs(n){return n[pf]||null}function $T(n){const t={};return{type:n.type,providersResolver:null,factory:null,hostBindings:n.hostBindings||null,hostVars:n.hostVars||0,hostAttrs:n.hostAttrs||null,contentQueries:n.contentQueries||null,declaredInputs:t,inputTransforms:null,inputConfig:n.inputs||tl,exportAs:n.exportAs||null,standalone:!0===n.standalone,signals:!0===n.signals,selectors:n.selectors||Qi,viewQuery:n.viewQuery||null,features:n.features||null,setInput:null,findHostDirectiveDefs:null,hostDirectives:null,inputs:qT(n.inputs,t),outputs:qT(n.outputs),debugInfo:null}}function ZT(n){n.features?.forEach(t=>t(n))}function Lm(n,t){if(!n)return null;const e=t?gs:Q_;return()=>("function"==typeof n?n():n).map(i=>e(i)).filter(G_)}const Vr=0,Be=1,Ct=2,vn=3,Ma=4,Os=5,wa=6,Jd=7,Er=8,Xs=9,ql=10,Yt=11,Sf=12,JT=13,Kd=14,Jr=15,If=16,eu=17,il=18,bf=19,KT=20,Xh=21,Nm=22,Uc=23,Ut=25,Hb=1,rl=7,tu=9,mn=10;var Bb=function(n){return n[n.None=0]="None",n[n.HasTransplantedViews=2]="HasTransplantedViews",n}(Bb||{});function ks(n){return Array.isArray(n)&&"object"==typeof n[Hb]}function Ps(n){return Array.isArray(n)&&!0===n[Hb]}function Fb(n){return 0!=(4&n.flags)}function jc(n){return n.componentOffset>-1}function km(n){return 1==(1&n.flags)}function Ca(n){return!!n.template}function _b(n){return 0!=(512&n[Ct])}function Vc(n,t){return n.hasOwnProperty(Uo)?n[Uo]:null}class K_{constructor(t,e,i){this.previousValue=t,this.currentValue=e,this.firstChange=i}isFirstChange(){return this.firstChange}}function rA(n,t,e,i){null!==t?t.applyValueToInputSignal(t,i):n[e]=i}function nA(n){return n.type.prototype.ngOnChanges&&(n.setInput=tU),eU}function eU(){const n=oA(this),t=n?.current;if(t){const e=n.previous;if(e===tl)n.previous=t;else for(let i in t)e[i]=t[i];n.current=null,this.ngOnChanges(t)}}function tU(n,t,e,i,r){const s=this.declaredInputs[i],o=oA(n)||function iU(n,t){return n[sA]=t}(n,{previous:tl,current:null}),a=o.current||(o.current={}),l=o.previous,h=l[s];a[s]=new K_(h&&h.currentValue,e,l===tl),rA(n,t,r,e)}const sA="__ngSimpleChanges__";function oA(n){return n[sA]||null}const nl=function(n,t,e){};let hA=!1;function pr(n){for(;Array.isArray(n);)n=n[Vr];return n}function qs(n,t){return pr(t[n.index])}function Cf(n,t){return n.data[t]}function To(n,t){const e=t[n];return ks(e)?e:e[Vr]}function Yb(n){return 128==(128&n[Ct])}function sl(n,t){return null==t?null:n[t]}function cA(n){n[eu]=0}function lU(n){1024&n[Ct]||(n[Ct]|=1024,Yb(n)&&Ef(n))}function uA(n){return 9216&n[Ct]||n[Uc]?.dirty}function Qb(n){uA(n)?Ef(n):64&n[Ct]&&(function nU(){return hA}()?(n[Ct]|=1024,Ef(n)):n[ql].changeDetectionScheduler?.notify())}function Ef(n){n[ql].changeDetectionScheduler?.notify();let t=Wc(n);for(;null!==t&&!(8192&t[Ct])&&(t[Ct]|=8192,Yb(t));)t=Wc(t)}function Wc(n){const t=n[vn];return Ps(t)?t[vn]:t}const Rt={lFrame:MA(null),bindingsEnabled:!0,skipHydrationRootTNode:null};function fA(){return Rt.bindingsEnabled}function Se(){return Rt.lFrame.lView}function xi(){return Rt.lFrame.tView}function fr(){let n=gA();for(;null!==n&&64===n.type;)n=n.parent;return n}function gA(){return Rt.lFrame.currentTNode}function ol(n,t){const e=Rt.lFrame;e.currentTNode=n,e.isParent=t}function Xb(){return Rt.lFrame.isParent}function bU(n,t){const e=Rt.lFrame;e.bindingIndex=e.bindingRootIndex=n,$b(t)}function $b(n){Rt.lFrame.currentDirectiveIndex=n}function SA(){return Rt.lFrame.currentQueryIndex}function Jb(n){Rt.lFrame.currentQueryIndex=n}function wU(n){const t=n[Be];return 2===t.type?t.declTNode:1===t.type?n[Os]:null}function IA(n,t,e){if(e&Di.SkipSelf){let r=t,s=n;for(;!(r=r.parent,null!==r||e&Di.Host||(r=wU(s),null===r||(s=s[Kd],10&r.type))););if(null===r)return!1;t=r,n=s}const i=Rt.lFrame=bA();return i.currentTNode=t,i.lView=n,!0}function Kb(n){const t=bA(),e=n[Be];Rt.lFrame=t,t.currentTNode=e.firstChild,t.lView=n,t.tView=e,t.contextLView=n,t.bindingIndex=e.bindingStartIndex,t.inI18n=!1}function bA(){const n=Rt.lFrame,t=null===n?null:n.child;return null===t?MA(n):t}function MA(n){const t={currentTNode:null,isParent:!0,lView:null,tView:null,selectedIndex:-1,contextLView:null,elementDepthCount:0,currentNamespace:null,currentDirectiveIndex:-1,bindingRootIndex:-1,bindingIndex:-1,currentQueryIndex:0,parent:n,child:null,inI18n:!1};return null!==n&&(n.child=t),t}function wA(){const n=Rt.lFrame;return Rt.lFrame=n.parent,n.currentTNode=null,n.lView=null,n}const CA=wA;function e1(){const n=wA();n.isParent=!0,n.tView=null,n.selectedIndex=-1,n.contextLView=null,n.elementDepthCount=0,n.currentDirectiveIndex=-1,n.currentNamespace=null,n.bindingRootIndex=-1,n.bindingIndex=-1,n.currentQueryIndex=0}function zs(){return Rt.lFrame.selectedIndex}function Yc(n){Rt.lFrame.selectedIndex=n}let DA=!0;function Rm(){return DA}function qh(n){DA=n}function Hm(n,t){for(let e=t.directiveStart,i=t.directiveEnd;e=i)break}else t[l]<0&&(n[eu]+=65536),(a>14>16&&(3&n[Ct])===t&&(n[Ct]+=16384,TA(a,s)):TA(a,s)}const nu=-1;class xf{constructor(t,e,i){this.factory=t,this.resolving=!1,this.canSeeViewProviders=e,this.injectImpl=i}}function r1(n){return n!==nu}function Tf(n){return 32767&n}function Af(n,t){let e=function zU(n){return n>>16}(n),i=t;for(;e>0;)i=i[Kd],e--;return i}let n1=!0;function _m(n){const t=n1;return n1=n,t}const AA=255,LA=5;let RU=0;const ll={};function Um(n,t){const e=NA(n,t);if(-1!==e)return e;const i=t[Be];i.firstCreatePass&&(n.injectorIndex=t.length,s1(i.data,n),s1(t,null),s1(i.blueprint,null));const r=jm(n,t),s=n.injectorIndex;if(r1(r)){const o=Tf(r),a=Af(r,t),l=a[Be].data;for(let h=0;h<8;h++)t[s+h]=a[o+h]|l[o+h]}return t[s+8]=r,s}function s1(n,t){n.push(0,0,0,0,0,0,0,0,t)}function NA(n,t){return-1===n.injectorIndex||n.parent&&n.parent.injectorIndex===n.injectorIndex||null===t[n.injectorIndex+8]?-1:n.injectorIndex}function jm(n,t){if(n.parent&&-1!==n.parent.injectorIndex)return n.parent.injectorIndex;let e=0,i=null,r=t;for(;null!==r;){if(i=BA(r),null===i)return nu;if(e++,r=r[Kd],-1!==i.injectorIndex)return i.injectorIndex|e<<16}return nu}function o1(n,t,e){!function HU(n,t,e){let i;"string"==typeof e?i=e.charCodeAt(0)||0:e.hasOwnProperty(jo)&&(i=e[jo]),null==i&&(i=e[jo]=RU++);const r=i&AA;t.data[n+(r>>LA)]|=1<=0?t&AA:UU:t}(e);if("function"==typeof s){if(!IA(t,n,i))return i&Di.Host?OA(r,0,i):kA(t,e,i,r);try{let o;if(o=s(i),null!=o||i&Di.Optional)return o;Db()}finally{CA()}}else if("number"==typeof s){let o=null,a=NA(n,t),l=nu,h=i&Di.Host?t[Jr][Os]:null;for((-1===a||i&Di.SkipSelf)&&(l=-1===a?jm(n,t):t[a+8],l!==nu&&HA(i,!1)?(o=t[Be],a=Tf(l),t=Af(l,t)):a=-1);-1!==a;){const c=t[Be];if(RA(s,a,c.data)){const d=FU(a,t,e,o,i,h);if(d!==ll)return d}l=t[a+8],l!==nu&&HA(i,t[Be].data[a+8]===h)&&RA(s,a,t)?(o=c,a=Tf(l),t=Af(l,t)):a=-1}}return r}function FU(n,t,e,i,r,s){const o=t[Be],a=o.data[n+8],c=Vm(a,o,e,null==i?jc(a)&&n1:i!=o&&0!=(3&a.type),r&Di.Host&&s===a);return null!==c?Qc(t,o,c,a):ll}function Vm(n,t,e,i,r){const s=n.providerIndexes,o=t.data,a=1048575&s,l=n.directiveStart,c=s>>20,u=r?a+c:n.directiveEnd;for(let p=i?a:a+c;p=l&&f.type===e)return p}if(r){const p=o[l];if(p&&Ca(p)&&p.type===e)return l}return null}function Qc(n,t,e,i){let r=n[e];const s=t.data;if(function NU(n){return n instanceof xf}(r)){const o=r;o.resolving&&function Vo(n,t){const e=t?`. Dependency path: ${t.join(" > ")} > ${n}`:"";throw new F(-200,`Circular dependency in DI detected for ${n}${e}`)}(zi(s[e]));const a=_m(o.canSeeViewProviders);o.resolving=!0;const h=o.injectImpl?no(o.injectImpl):null;IA(n,i,Di.Default);try{r=n[e]=o.factory(void 0,s,n,i),t.firstCreatePass&&e>=i.directiveStart&&function AU(n,t,e){const{ngOnChanges:i,ngOnInit:r,ngDoCheck:s}=t.type.prototype;if(i){const o=nA(t);(e.preOrderHooks??=[]).push(n,o),(e.preOrderCheckHooks??=[]).push(n,o)}r&&(e.preOrderHooks??=[]).push(0-n,r),s&&((e.preOrderHooks??=[]).push(n,s),(e.preOrderCheckHooks??=[]).push(n,s))}(e,s[e],t)}finally{null!==h&&no(h),_m(a),o.resolving=!1,CA()}}return r}function RA(n,t,e){return!!(e[t+(n>>LA)]&1<Array.isArray(e)?uu(e,t):t(e))}function _A(n,t,e){t>=n.length?n.push(e):n.splice(t,0,e)}function Wm(n,t){return t>=n.length-1?n.pop():n.splice(t,1)[0]}const gu=new Ht(""),QA=new Ht("",-1),v1=new Ht("");class Xm{get(t,e=vf){if(e===vf){const i=new Error(`NullInjectorError: No provider for ${dt(t)}!`);throw i.name="NullInjectorError",i}return e}}function dj(...n){return{\u0275providers:GA(0,n),\u0275fromNgModule:!0}}function GA(n,...t){const e=[],i=new Set;let r;const s=o=>{e.push(o)};return uu(t,o=>{const a=o;qm(a,s,[],i)&&(r||=[],r.push(a))}),void 0!==r&&XA(r,s),e}function XA(n,t){for(let e=0;e{t(s,i)})}}function qm(n,t,e,i){if(!(n=vt(n)))return!1;let r=null,s=Cm(n);const o=!s&&ci(n);if(s||o){if(o&&!o.standalone)return!1;r=n}else{const l=n.ngModule;if(s=Cm(l),!s)return!1;r=l}const a=i.has(r);if(o){if(a)return!1;if(i.add(r),o.dependencies){const l="function"==typeof o.dependencies?o.dependencies():o.dependencies;for(const h of l)qm(h,t,e,i)}}else{if(!s)return!1;{if(null!=s.imports&&!a){let h;i.add(r);try{uu(s.imports,c=>{qm(c,t,e,i)&&(h||=[],h.push(c))})}finally{}void 0!==h&&XA(h,t)}if(!a){const h=Vc(r)||(()=>new r);t({provide:r,useFactory:h,deps:Qi},r),t({provide:v1,useValue:r,multi:!0},r),t({provide:gu,useValue:()=>Fi(r),multi:!0},r)}const l=s.providers;if(null!=l&&!a){const h=n;y1(l,c=>{t(c,h)})}}}return r!==n&&void 0!==n.providers}function y1(n,t){for(let e of n)Ql(e)&&(e=e.\u0275providers),Array.isArray(e)?y1(e,t):t(e)}const uj=Xe({provide:String,useValue:Xe});function S1(n){return null!==n&&"object"==typeof n&&uj in n}function Gc(n){return"function"==typeof n}const I1=new Ht(""),$m={},fj={};let b1;function Zm(){return void 0===b1&&(b1=new Xm),b1}class Jl{}class vu extends Jl{get destroyed(){return this._destroyed}constructor(t,e,i,r){super(),this.parent=e,this.source=i,this.scopes=r,this.records=new Map,this._ngOnDestroyHooks=new Set,this._onDestroyHooks=[],this._destroyed=!1,w1(t,o=>this.processProvider(o)),this.records.set(QA,mu(void 0,this)),r.has("environment")&&this.records.set(Jl,mu(void 0,this));const s=this.records.get(I1);null!=s&&"string"==typeof s.value&&this.scopes.add(s.value),this.injectorDefTypes=new Set(this.get(v1,Qi,Di.Self))}destroy(){this.assertNotDestroyed(),this._destroyed=!0;try{for(const e of this._ngOnDestroyHooks)e.ngOnDestroy();const t=this._onDestroyHooks;this._onDestroyHooks=[];for(const e of t)e()}finally{this.records.clear(),this._ngOnDestroyHooks.clear(),this.injectorDefTypes.clear()}}onDestroy(t){return this.assertNotDestroyed(),this._onDestroyHooks.push(t),()=>this.removeOnDestroy(t)}runInContext(t){this.assertNotDestroyed();const e=Qh(this),i=no(void 0);try{return t()}finally{Qh(e),no(i)}}get(t,e=vf,i=Di.Default){if(this.assertNotDestroyed(),t.hasOwnProperty(ff))return t[ff](this);i=xm(i);const s=Qh(this),o=no(void 0);try{if(!(i&Di.SkipSelf)){let l=this.records.get(t);if(void 0===l){const h=function Sj(n){return"function"==typeof n||"object"==typeof n&&n instanceof Ht}(t)&&wm(t);l=h&&this.injectableDefInScope(h)?mu(M1(t),$m):null,this.records.set(t,l)}if(null!=l)return this.hydrate(t,l)}return(i&Di.Self?Zm():this.parent).get(t,e=i&Di.Optional&&e===vf?null:e)}catch(a){if("NullInjectorError"===a.name){if((a[Dm]=a[Dm]||[]).unshift(dt(t)),s)throw a;return function k_(n,t,e,i){const r=n[Dm];throw t[FT]&&r.unshift(t[FT]),n.message=function P_(n,t,e,i=null){n=n&&"\n"===n.charAt(0)&&"\u0275"==n.charAt(1)?n.slice(2):n;let r=dt(t);if(Array.isArray(t))r=t.map(dt).join(" -> ");else if("object"==typeof t){let s=[];for(let o in t)if(t.hasOwnProperty(o)){let a=t[o];s.push(o+":"+("string"==typeof a?JSON.stringify(a):dt(a)))}r=`{${s.join(", ")}}`}return`${e}${i?"("+i+")":""}[${r}]: ${n.replace(T_,"\n ")}`}("\n"+n.message,r,e,i),n.ngTokenPath=r,n[Dm]=null,n}(a,t,"R3InjectorError",this.source)}throw a}finally{no(o),Qh(s)}}resolveInjectorInitializers(){const t=Qh(this),e=no(void 0);try{const r=this.get(gu,Qi,Di.Self);for(const s of r)s()}finally{Qh(t),no(e)}}toString(){const t=[],e=this.records;for(const i of e.keys())t.push(dt(i));return`R3Injector[${t.join(", ")}]`}assertNotDestroyed(){if(this._destroyed)throw new F(205,!1)}processProvider(t){let e=Gc(t=vt(t))?t:vt(t&&t.provide);const i=function vj(n){return S1(n)?mu(void 0,n.useValue):mu(ZA(n),$m)}(t);if(!Gc(t)&&!0===t.multi){let r=this.records.get(e);r||(r=mu(void 0,$m,!0),r.factory=()=>Pb(r.multi),this.records.set(e,r)),e=t,r.multi.push(t)}this.records.set(e,i)}hydrate(t,e){return e.value===$m&&(e.value=fj,e.value=e.factory()),"object"==typeof e.value&&e.value&&function yj(n){return null!==n&&"object"==typeof n&&"function"==typeof n.ngOnDestroy}(e.value)&&this._ngOnDestroyHooks.add(e.value),e.value}injectableDefInScope(t){if(!t.providedIn)return!1;const e=vt(t.providedIn);return"string"==typeof e?"any"===e||this.scopes.has(e):this.injectorDefTypes.has(e)}removeOnDestroy(t){const e=this._onDestroyHooks.indexOf(t);-1!==e&&this._onDestroyHooks.splice(e,1)}}function M1(n){const t=wm(n),e=null!==t?t.factory:Vc(n);if(null!==e)return e;if(n instanceof Ht)throw new F(204,!1);if(n instanceof Function)return function gj(n){if(n.length>0)throw new F(204,!1);const e=function C_(n){return n&&(n[Em]||n[zT])||null}(n);return null!==e?()=>e.factory(n):()=>new n}(n);throw new F(204,!1)}function ZA(n,t,e){let i;if(Gc(n)){const r=vt(n);return Vc(r)||M1(r)}if(S1(n))i=()=>vt(n.useValue);else if(function $A(n){return!(!n||!n.useFactory)}(n))i=()=>n.useFactory(...Pb(n.deps||[]));else if(function qA(n){return!(!n||!n.useExisting)}(n))i=()=>Fi(vt(n.useExisting));else{const r=vt(n&&(n.useClass||n.provide));if(!function mj(n){return!!n.deps}(n))return Vc(r)||M1(r);i=()=>new r(...Pb(n.deps))}return i}function mu(n,t,e=!1){return{factory:n,value:t,multi:e?[]:void 0}}function w1(n,t){for(const e of n)Array.isArray(e)?w1(e,t):e&&Ql(e)?w1(e.\u0275providers,t):t(e)}function tL(n,t=null,e=null,i){const r=function iL(n,t=null,e=null,i,r=new Set){const s=[e||Qi,dj(n)];return i=i||("object"==typeof n?void 0:dt(n)),new vu(s,t||Zm(),i||null,r)}(n,t,e,i);return r.resolveInjectorInitializers(),r}let D1,Wo=(()=>{class n{static{this.THROW_IF_NOT_FOUND=vf}static{this.NULL=new Xm}static create(e,i){if(Array.isArray(e))return tL({name:""},i,e,"");{const r=e.name??"";return tL({name:r},e.parent,e.providers,r)}}static{this.\u0275prov=Yi({token:n,providedIn:"any",factory:()=>Fi(QA)})}static{this.__NG_ELEMENT_ID__=-1}}return n})();const x1=new Ht("",{providedIn:"root",factory:()=>Tj}),Tj="ng",nL=new Ht(""),yu=new Ht("",{providedIn:"platform",factory:()=>"unknown"}),sL=new Ht("",{providedIn:"root",factory:()=>function $h(){if(void 0!==D1)return D1;if(typeof document<"u")return document;throw new F(210,!1)}().body?.querySelector("[ngCspNonce]")?.getAttribute("ngCspNonce")||null});function iy(n){return 128==(128&n.flags)}var Kh=function(n){return n[n.Important=1]="Important",n[n.DashCase=2]="DashCase",n}(Kh||{});const O1=new Map;let Uj=0;const P1="__ngContext__";function Rs(n,t){ks(t)?(n[P1]=t[bf],function Vj(n){O1.set(n[bf],n)}(t)):n[P1]=t}let z1;function R1(n,t){return z1(n,t)}function Iu(n,t,e,i,r){if(null!=i){let s,o=!1;Ps(i)?s=i:ks(i)&&(o=!0,i=i[Vr]);const a=pr(i);0===n&&null!==e?null==r?xL(t,e,a):qc(t,e,a,r||null,!0):1===n&&null!==e?qc(t,e,a,r||null,!0):2===n?function hy(n,t,e){const i=ay(n,t);i&&function s6(n,t,e,i){n.removeChild(t,e,i)}(n,i,t,e)}(t,a,o):3===n&&t.destroyNode(a),null!=s&&function l6(n,t,e,i,r){const s=e[rl];s!==pr(e)&&Iu(t,n,i,s,r);for(let a=mn;a0&&(n[e-1][Ma]=i[Ma]);const s=Wm(n,mn+t);!function Jj(n,t){CL(n,t),t[Vr]=null,t[Os]=null}(i[Be],i);const o=s[il];null!==o&&o.detachView(s[Be]),i[vn]=null,i[Ma]=null,i[Ct]&=-129}return i}function oy(n,t){if(!(256&t[Ct])){const e=t[Yt];e.destroyNode&&cy(n,t,e,3,null,null),function e6(n){let t=n[Sf];if(!t)return B1(n[Be],n);for(;t;){let e=null;if(ks(t))e=t[Sf];else{const i=t[mn];i&&(e=i)}if(!e){for(;t&&!t[Ma]&&t!==n;)ks(t)&&B1(t[Be],t),t=t[vn];null===t&&(t=n),ks(t)&&B1(t[Be],t),e=t&&t[Ma]}t=e}}(t)}}function B1(n,t){if(!(256&t[Ct])){t[Ct]&=-129,t[Ct]|=256,t[Uc]&&function Yd(n){if(Vl(n),Vh(n))for(let t=0;t=0?i[o]():i[-o].unsubscribe(),s+=2}else e[s].call(i[e[s+1]]);null!==i&&(t[Jd]=null);const r=t[Xh];if(null!==r){t[Xh]=null;for(let s=0;s-1){const{encapsulation:s}=n.data[i.directiveStart+r];if(s===Ia.None||s===Ia.Emulated)return null}return qs(i,e)}}(n,t.parent,e)}function qc(n,t,e,i,r){n.insertBefore(t,e,i,r)}function xL(n,t,e){n.appendChild(t,e)}function TL(n,t,e,i,r){null!==i?qc(n,t,e,i,r):xL(n,t,e)}function ay(n,t){return n.parentNode(t)}let _1,NL=function LL(n,t,e){return 40&n.type?qs(n,e):null};function ly(n,t,e,i){const r=F1(n,i,t),s=t[Yt],a=function AL(n,t,e){return NL(n,t,e)}(i.parent||t[Os],i,t);if(null!=r)if(Array.isArray(e))for(let l=0;lnull;function iM(n,t,e=!1){return ZL(n,t,e)}class Y6{}class iN{}class G6{resolveComponentFactory(t){throw function Q6(n){const t=Error(`No component factory found for ${dt(n)}.`);return t.ngComponent=n,t}(t)}}let Sy=(()=>{class n{static{this.NULL=new G6}}return n})();function X6(){return Du(fr(),Se())}function Du(n,t){return new $c(qs(n,t))}let $c=(()=>{class n{constructor(e){this.nativeElement=e}static{this.__NG_ELEMENT_ID__=X6}}return n})();function q6(n){return n instanceof $c?n.nativeElement:n}class nN{}let oM=(()=>{class n{constructor(){this.destroyNode=null}static{this.__NG_ELEMENT_ID__=()=>function $6(){const n=Se(),e=To(fr().index,n);return(ks(e)?e:n)[Yt]}()}}return n})(),Z6=(()=>{class n{static{this.\u0275prov=Yi({token:n,providedIn:"root",factory:()=>null})}}return n})();const aM={};function Wf(n,t,e,i,r=!1){for(;null!==e;){const s=t[e.index];null!==s&&i.push(pr(s)),Ps(s)&&uN(s,i);const o=e.type;if(8&o)Wf(n,t,e.child,i);else if(32&o){const a=R1(e,t);let l;for(;l=a();)i.push(l)}else if(16&o){const a=kL(t,e);if(Array.isArray(a))i.push(...a);else{const l=Wc(t[Jr]);Wf(l[Be],l,a,i,!0)}}e=r?e.projectionNext:e.next}return i}function uN(n,t){for(let e=mn;e!1,producerRecomputeValue:()=>{},consumerMarkedDirty:()=>{},consumerOnSignalRead:()=>{},consumerIsAlwaysLive:!0,consumerMarkedDirty:n=>{Ef(n.lView)},consumerOnSignalRead(){this.lView[Uc]=this}};function fN(n){return vN(n[Sf])}function gN(n){return vN(n[Ma])}function vN(n){for(;null!==n&&!Ps(n);)n=n[Ma];return n}function cM(n){return n.ngOriginalError}class eh{constructor(){this._console=console}handleError(t){const e=this._findOriginalError(t);this._console.error("ERROR",t),e&&this._console.error("ORIGINAL ERROR",e)}_findOriginalError(t){let e=t&&cM(t);for(;e&&cM(e);)e=cM(e);return e||null}}const yN=new Ht("",{providedIn:"root",factory:()=>Ri(eh).handleError.bind(void 0)}),IN=new Ht("",{providedIn:"root",factory:()=>!1}),Qt={};function EN(n,t,e,i){if(!i)if(3==(3&t[Ct])){const s=n.preOrderCheckHooks;null!==s&&Bm(t,s,e)}else{const s=n.preOrderHooks;null!==s&&Fm(t,s,0,e)}Yc(e)}function Ot(n,t=Di.Default){const e=Se();return null===e?Fi(n,t):PA(fr(),e,vt(n),t)}function DN(n,t,e,i,r,s){const o=Wi(null);try{let a=null;r&Gh.SignalBased&&(a=t[i][Ts]),null!==a&&void 0!==a.transformFn&&(s=a.transformFn(s)),r&Gh.HasDecoratorInputTransform&&(s=n.inputTransforms[i].call(t,s)),null!==n.setInput?n.setInput(t,a,s,e,i):rA(t,a,i,s)}finally{Wi(o)}}function wy(n,t,e,i,r,s,o,a,l,h,c){const d=t.blueprint.slice();return d[Vr]=r,d[Ct]=204|i,(null!==h||n&&2048&n[Ct])&&(d[Ct]|=2048),cA(d),d[vn]=d[Kd]=n,d[Er]=e,d[ql]=o||n&&n[ql],d[Yt]=a||n&&n[Yt],d[Xs]=l||n&&n[Xs]||null,d[Os]=s,d[bf]=function jj(){return Uj++}(),d[wa]=c,d[KT]=h,d[Jr]=2==t.type?n[Jr]:d,d}function xu(n,t,e,i,r){let s=n.data[t];if(null===s)s=function dM(n,t,e,i,r){const s=gA(),o=Xb(),l=n.data[t]=function TV(n,t,e,i,r,s){let o=t?t.injectorIndex:-1,a=0;return function ru(){return null!==Rt.skipHydrationRootTNode}()&&(a|=128),{type:e,index:i,insertBeforeIndex:null,injectorIndex:o,directiveStart:-1,directiveEnd:-1,directiveStylingLast:-1,componentOffset:-1,propertyBindings:null,flags:a,providerIndexes:0,value:r,attrs:s,mergedAttrs:null,localNames:null,initialInputs:void 0,inputs:null,outputs:null,tView:null,next:null,prev:null,projectionNext:null,child:null,parent:t,projection:null,styles:null,stylesWithoutHost:null,residualStyles:void 0,classes:null,classesWithoutHost:null,residualClasses:void 0,classBindings:0,styleBindings:0}}(0,o?s:s&&s.parent,e,t,i,r);return null===n.firstChild&&(n.firstChild=l),null!==s&&(o?null==s.child&&null!==l.parent&&(s.child=l):null===s.next&&(s.next=l,l.prev=s)),l}(n,t,e,i,r),function IU(){return Rt.lFrame.inI18n}()&&(s.flags|=32);else if(64&s.type){s.type=e,s.value=i,s.attrs=r;const o=function Df(){const n=Rt.lFrame,t=n.currentTNode;return n.isParent?t:t.parent}();s.injectorIndex=null===o?-1:o.injectorIndex}return ol(s,!0),s}function Yf(n,t,e,i){if(0===e)return-1;const r=t.length;for(let s=0;sUt&&EN(n,t,Ut,!1),nl(o?2:0,r),e(i,r)}finally{Yc(s),nl(o?3:1,r)}}function uM(n,t,e){if(Fb(t)){const i=Wi(null);try{const s=t.directiveEnd;for(let o=t.directiveStart;onull;function LN(n,t,e,i,r){for(let s in t){if(!t.hasOwnProperty(s))continue;const o=t[s];if(void 0===o)continue;i??={};let a,l=Gh.None;Array.isArray(o)?(a=o[0],l=o[1]):a=o;let h=s;if(null!==r){if(!r.hasOwnProperty(s))continue;h=r[s]}0===n?NN(i,e,h,a,l):NN(i,e,h,a)}return i}function NN(n,t,e,i,r){let s;n.hasOwnProperty(e)?(s=n[e]).push(t,i):s=n[e]=[t,i],void 0!==r&&s.push(r)}function ON(n,t,e,i,r,s){for(let h=0;h0;){const e=n[--t];if("number"==typeof e&&e<0)return e}return 0})(o)!=a&&o.push(a),o.push(e,i,s)}}(n,t,i,Yf(n,e,r.hostVars,Qt),r)}function VV(n,t,e,i,r,s){const o=s[t];if(null!==o)for(let a=0;an.nextProducerIndex;)n.producerNode.pop(),n.producerLastReadVersion.pop(),n.producerIndexOfThis.pop()}}(a,o),function dV(n){n.lView[Uc]!==n&&(n.lView=null,pN.push(n))}(a)),e1()}}function FN(n,t){for(let e=fN(n);null!==e;e=gN(e))for(let i=mn;i-1&&(Rf(t,i),Wm(e,i))}this._attachedToViewContainer=!1}oy(this._lView[Be],this._lView)}onDestroy(t){!function zm(n,t){if(256==(256&n[Ct]))throw new F(911,!1);null===n[Xh]&&(n[Xh]=[]),n[Xh].push(t)}(this._lView,t)}markForCheck(){Qf(this._cdRefInjectingView||this._lView)}detach(){this._lView[Ct]&=-129}reattach(){Qb(this._lView),this._lView[Ct]|=128}detectChanges(){this._lView[Ct]|=1024,function bM(n,t=!0){const e=n[ql],i=e.rendererFactory;i.begin?.();try{!function QV(n){MM(n,0);let t=0;for(;uA(n);){if(100===t)throw new F(103,!1);t++,MM(n,1)}}(n)}catch(s){throw t&&Ey(n,s),s}finally{i.end?.(),e.inlineEffectRunner?.flush()}}(this._lView,this.notifyErrorHandler)}checkNoChanges(){}attachToViewContainerRef(){if(this._appRef)throw new F(902,!1);this._attachedToViewContainer=!0}detachFromAppRef(){this._appRef=null,CL(this._lView[Be],this._lView)}attachToAppRef(t){if(this._attachedToViewContainer)throw new F(902,!1);this._appRef=t,Qb(this._lView)}}const VN=new Set;function CM(n){return t=>{setTimeout(n,void 0,t)}}const Yo=class a7 extends Pt{constructor(t=!1){super(),this.__isAsync=t}emit(t){super.next(t)}subscribe(t,e,i){let r=t,s=e||(()=>null),o=i;if(t&&"object"==typeof t){const l=t;r=l.next?.bind(l),s=l.error?.bind(l),o=l.complete?.bind(l)}this.__isAsync&&(s=CM(s),r&&(r=CM(r)),o&&(o=CM(o)));const a=super.subscribe({next:r,error:s,complete:o});return t instanceof As&&t.add(a),a}};function WN(...n){}class zr{constructor({enableLongStackTrace:t=!1,shouldCoalesceEventChangeDetection:e=!1,shouldCoalesceRunChangeDetection:i=!1}){if(this.hasPendingMacrotasks=!1,this.hasPendingMicrotasks=!1,this.isStable=!0,this.onUnstable=new Yo(!1),this.onMicrotaskEmpty=new Yo(!1),this.onStable=new Yo(!1),this.onError=new Yo(!1),typeof Zone>"u")throw new F(908,!1);Zone.assertZonePatched();const r=this;r._nesting=0,r._outer=r._inner=Zone.current,Zone.TaskTrackingZoneSpec&&(r._inner=r._inner.fork(new Zone.TaskTrackingZoneSpec)),t&&Zone.longStackTraceZoneSpec&&(r._inner=r._inner.fork(Zone.longStackTraceZoneSpec)),r.shouldCoalesceEventChangeDetection=!i&&e,r.shouldCoalesceRunChangeDetection=i,r.lastRequestAnimationFrameId=-1,r.nativeRequestAnimationFrame=function l7(){const n="function"==typeof rr.requestAnimationFrame;let t=rr[n?"requestAnimationFrame":"setTimeout"],e=rr[n?"cancelAnimationFrame":"clearTimeout"];if(typeof Zone<"u"&&t&&e){const i=t[Zone.__symbol__("OriginalDelegate")];i&&(t=i);const r=e[Zone.__symbol__("OriginalDelegate")];r&&(e=r)}return{nativeRequestAnimationFrame:t,nativeCancelAnimationFrame:e}}().nativeRequestAnimationFrame,function d7(n){const t=()=>{!function c7(n){n.isCheckStableRunning||-1!==n.lastRequestAnimationFrameId||(n.lastRequestAnimationFrameId=n.nativeRequestAnimationFrame.call(rr,()=>{n.fakeTopEventTask||(n.fakeTopEventTask=Zone.root.scheduleEventTask("fakeTopEventTask",()=>{n.lastRequestAnimationFrameId=-1,DM(n),n.isCheckStableRunning=!0,EM(n),n.isCheckStableRunning=!1},void 0,()=>{},()=>{})),n.fakeTopEventTask.invoke()}),DM(n))}(n)};n._inner=n._inner.fork({name:"angular",properties:{isAngularZone:!0},onInvokeTask:(e,i,r,s,o,a)=>{if(function u7(n){return!(!Array.isArray(n)||1!==n.length)&&!0===n[0].data?.__ignore_ng_zone__}(a))return e.invokeTask(r,s,o,a);try{return YN(n),e.invokeTask(r,s,o,a)}finally{(n.shouldCoalesceEventChangeDetection&&"eventTask"===s.type||n.shouldCoalesceRunChangeDetection)&&t(),QN(n)}},onInvoke:(e,i,r,s,o,a,l)=>{try{return YN(n),e.invoke(r,s,o,a,l)}finally{n.shouldCoalesceRunChangeDetection&&t(),QN(n)}},onHasTask:(e,i,r,s)=>{e.hasTask(r,s),i===r&&("microTask"==s.change?(n._hasPendingMicrotasks=s.microTask,DM(n),EM(n)):"macroTask"==s.change&&(n.hasPendingMacrotasks=s.macroTask))},onHandleError:(e,i,r,s)=>(e.handleError(r,s),n.runOutsideAngular(()=>n.onError.emit(s)),!1)})}(r)}static isInAngularZone(){return typeof Zone<"u"&&!0===Zone.current.get("isAngularZone")}static assertInAngularZone(){if(!zr.isInAngularZone())throw new F(909,!1)}static assertNotInAngularZone(){if(zr.isInAngularZone())throw new F(909,!1)}run(t,e,i){return this._inner.run(t,e,i)}runTask(t,e,i,r){const s=this._inner,o=s.scheduleEventTask("NgZoneEvent: "+r,t,h7,WN,WN);try{return s.runTask(o,e,i)}finally{s.cancelTask(o)}}runGuarded(t,e,i){return this._inner.runGuarded(t,e,i)}runOutsideAngular(t){return this._outer.run(t)}}const h7={};function EM(n){if(0==n._nesting&&!n.hasPendingMicrotasks&&!n.isStable)try{n._nesting++,n.onMicrotaskEmpty.emit(null)}finally{if(n._nesting--,!n.hasPendingMicrotasks)try{n.runOutsideAngular(()=>n.onStable.emit(null))}finally{n.isStable=!0}}}function DM(n){n.hasPendingMicrotasks=!!(n._hasPendingMicrotasks||(n.shouldCoalesceEventChangeDetection||n.shouldCoalesceRunChangeDetection)&&-1!==n.lastRequestAnimationFrameId)}function YN(n){n._nesting++,n.isStable&&(n.isStable=!1,n.onUnstable.emit(null))}function QN(n){n._nesting--,EM(n)}let Xf=(()=>{class n{constructor(){this.handler=null,this.internalCallbacks=[]}execute(){const e=[...this.internalCallbacks];this.internalCallbacks.length=0;for(const r of e)r();return!!this.handler?.execute()||e.length>0}ngOnDestroy(){this.handler?.destroy(),this.handler=null,this.internalCallbacks.length=0}static{this.\u0275prov=Yi({token:n,providedIn:"root",factory:()=>new n})}}return n})();function v7(n,t){const e=To(t,n),i=e[Be];!function m7(n,t){for(let e=t.length;e0&&RL(n,e,s.join(" "))}}(u,w,f,i),void 0!==e&&function x7(n,t,e){const i=n.projection=[];for(let r=0;r=0;i--){const r=n[i];r.hostVars=t+=r.hostVars,r.hostAttrs=yf(r.hostAttrs,e=yf(e,r.hostAttrs))}}(i)}function A7(n,t){for(const e in t.inputs){if(!t.inputs.hasOwnProperty(e)||n.inputs.hasOwnProperty(e))continue;const i=t.inputs[e];if(void 0!==i&&(n.inputs[e]=i,n.declaredInputs[e]=t.declaredInputs[e],null!==t.inputTransforms)){const r=Array.isArray(i)?i[0]:i;if(!t.inputTransforms.hasOwnProperty(r))continue;n.inputTransforms??={},n.inputTransforms[r]=t.inputTransforms[r]}}}function xy(n){return n===tl?{}:n===Qi?[]:n}function N7(n,t){const e=n.viewQuery;n.viewQuery=e?(i,r)=>{t(i,r),e(i,r)}:t}function O7(n,t){const e=n.contentQueries;n.contentQueries=e?(i,r,s)=>{t(i,r,s),e(i,r,s)}:t}function k7(n,t){const e=n.hostBindings;n.hostBindings=e?(i,r)=>{t(i,r),e(i,r)}:t}function Au(n,t){return!t||null===t.firstChild||iy(n)}function tg(n,t,e,i=!0){const r=t[Be];if(function t6(n,t,e,i){const r=mn+i,s=e.length;i>0&&(e[r-1][Ma]=t),i{class n{static{this.__NG_ELEMENT_ID__=a9}}return n})();function a9(){return pO(fr(),Se())}const l9=xn,dO=class extends l9{constructor(t,e,i){super(),this._lContainer=t,this._hostTNode=e,this._hostLView=i}get element(){return Du(this._hostTNode,this._hostLView)}get injector(){return new Vn(this._hostTNode,this._hostLView)}get parentInjector(){const t=jm(this._hostTNode,this._hostLView);if(r1(t)){const e=Af(t,this._hostLView),i=Tf(t);return new Vn(e[Be].data[i+8],e)}return new Vn(null,this._hostLView)}clear(){for(;this.length>0;)this.remove(this.length-1)}get(t){const e=uO(this._lContainer);return null!==e&&e[t]||null}get length(){return this._lContainer.length-mn}createEmbeddedView(t,e,i){let r,s;"number"==typeof i?r=i:null!=i&&(r=i.index,s=i.injector);const a=t.createEmbeddedViewImpl(e||{},s,null);return this.insertImpl(a,r,Au(this._hostTNode,null)),a}createComponent(t,e,i,r,s){const o=t&&!function Lf(n){return"function"==typeof n}(t);let a;if(o)a=e;else{const f=e||{};a=f.index,i=f.injector,r=f.projectableNodes,s=f.environmentInjector||f.ngModuleRef}const l=o?t:new qf(ci(t)),h=i||this.parentInjector;if(!s&&null==l.ngModule){const g=(o?h:this.parentInjector).get(Jl,null);g&&(s=g)}ci(l.componentType??{});const p=l.create(h,r,null,s);return this.insertImpl(p.hostView,a,Au(this._hostTNode,null)),p}insert(t,e){return this.insertImpl(t,e,!0)}insertImpl(t,e,i){const r=t._lView;if(function aU(n){return Ps(n[vn])}(r)){const a=this.indexOf(t);if(-1!==a)this.detach(a);else{const l=r[vn],h=new dO(l,l[Os],l[vn]);h.detach(h.indexOf(t))}}const s=this._adjustIndex(e),o=this._lContainer;return tg(o,r,s,i),t.attachToViewContainerRef(),_A(PM(o),s,t),t}move(t,e){return this.insert(t,e)}indexOf(t){const e=uO(this._lContainer);return null!==e?e.indexOf(t):-1}remove(t){const e=this._adjustIndex(t,-1),i=Rf(this._lContainer,e);i&&(Wm(PM(this._lContainer),e),oy(i[Be],i))}detach(t){const e=this._adjustIndex(t,-1),i=Rf(this._lContainer,e);return i&&null!=Wm(PM(this._lContainer),e)?new Gf(i):null}_adjustIndex(t,e=0){return t??this.length+e}};function uO(n){return n[8]}function PM(n){return n[8]||(n[8]=[])}function pO(n,t){let e;const i=t[n.index];return Ps(i)?e=i:(e=function PN(n,t,e,i){return[n,!0,0,t,null,i,null,e,null,null]}(i,t,null,n),t[n.index]=e,Cy(t,e)),fO(e,t,n,i),new dO(e,n,t)}let fO=function vO(n,t,e,i){if(n[rl])return;let r;r=8&e.type?pr(i):function h9(n,t){const e=n[Yt],i=e.createComment(""),r=qs(t,n);return qc(e,ay(e,r),i,function o6(n,t){return n.nextSibling(t)}(e,r),!1),i}(t,e),n[rl]=r};function GM(n,t,e){const i=Se();return function Tn(n,t,e){return!Object.is(n[t],e)&&(n[t]=e,!0)}(i,function al(){return Rt.lFrame.bindingIndex++}(),t)&&function No(n,t,e,i,r,s,o,a){const l=qs(t,e);let c,h=t.inputs;!a&&null!=h&&(c=h[i])?(IM(n,e,c,i,r),jc(t)&&function NV(n,t){const e=To(t,n);16&e[Ct]||(e[Ct]|=64)}(e,t.index)):3&t.type&&(i=function LV(n){return"class"===n?"className":"for"===n?"htmlFor":"formaction"===n?"formAction":"innerHtml"===n?"innerHTML":"readonly"===n?"readOnly":"tabindex"===n?"tabIndex":n}(i),r=null!=o?o(r,t.value||"",i):r,s.setProperty(l,i,r))}(xi(),function Pr(){const n=Rt.lFrame;return Cf(n.tView,n.selectedIndex)}(),i,n,t,i[Yt],e,!1),GM}function XM(n,t,e,i,r){const o=r?"class":"style";IM(n,e,t.inputs[o],o,i)}function lg(n,t,e,i){const r=Se(),s=xi(),o=Ut+n,a=r[Yt],l=s.firstCreatePass?function R8(n,t,e,i,r,s){const o=t.consts,l=xu(t,n,2,i,sl(o,r));return function vM(n,t,e,i){if(fA()){const r=null===i?null:{"":-1},s=function HV(n,t){const e=n.directiveRegistry;let i=null,r=null;if(e)for(let s=0;s(qh(!0),sy(i,r,function EA(){return Rt.lFrame.currentNamespace}()));const Gu="en-US";let Mk=Gu;function sw(n){return!!n&&"function"==typeof n.then}function Gk(n){return!!n&&"function"==typeof n.subscribe}function ow(n,t,e,i){const r=Se(),s=xi(),o=fr();return function qk(n,t,e,i,r,s,o){const a=km(i),h=n.firstCreatePass&&HN(n),c=t[Er],d=RN(t);let u=!0;if(3&i.type||o){const g=qs(i,t),v=o?o(g):g,y=d.length,S=o?M=>o(pr(M[i.index])):i.index;let b=null;if(!o&&a&&(b=function FW(n,t,e,i){const r=n.cleanup;if(null!=r)for(let s=0;sl?a[l]:null}"string"==typeof o&&(s+=2)}return null}(n,t,r,i.index)),null!==b)(b.__ngLastListenerFn__||b).__ngNextListenerFn__=s,b.__ngLastListenerFn__=s,u=!1;else{s=Zk(i,t,c,s,!1);const M=e.listen(v,r,s);d.push(s,M),h&&h.push(r,S,y,y+1)}}else s=Zk(i,t,c,s,!1);const p=i.outputs;let f;if(u&&null!==p&&(f=p[r])){const g=f.length;if(g)for(let v=0;v-1?To(n.index,t):t);let l=$k(t,e,i,o),h=s.__ngNextListenerFn__;for(;h;)l=$k(t,e,h,o)&&l,h=h.__ngNextListenerFn__;return r&&!1===l&&o.preventDefault(),l}}function WW(){return this._results[Symbol.iterator]()}class lw{get changes(){return this._changes??=new Yo}constructor(t=!1){this._emitDistinctChangesOnly=t,this.dirty=!0,this._results=[],this._changesDetected=!1,this._changes=void 0,this.length=0,this.first=void 0,this.last=void 0;const e=lw.prototype;e[Symbol.iterator]||(e[Symbol.iterator]=WW)}get(t){return this._results[t]}map(t){return this._results.map(t)}filter(t){return this._results.filter(t)}find(t){return this._results.find(t)}reduce(t,e){return this._results.reduce(t,e)}forEach(t){this._results.forEach(t)}some(t){return this._results.some(t)}toArray(){return this._results.slice()}toString(){return this._results.toString()}reset(t,e){this.dirty=!1;const i=function oo(n){return n.flat(Number.POSITIVE_INFINITY)}(t);(this._changesDetected=!function XU(n,t,e){if(n.length!==t.length)return!1;for(let i=0;i{class n{static{this.__NG_ELEMENT_ID__=GW}}return n})();const YW=ih,QW=class extends YW{constructor(t,e,i){super(),this._declarationLView=t,this._declarationTContainer=e,this.elementRef=i}get ssrId(){return this._declarationTContainer.tView?.ssrId||null}createEmbeddedView(t,e){return this.createEmbeddedViewImpl(t,e)}createEmbeddedViewImpl(t,e,i){const r=function eg(n,t,e,i){const r=t.tView,a=wy(n,r,e,4096&n[Ct]?4096:16,null,t,null,null,null,i?.injector??null,i?.dehydratedView??null);a[If]=n[t.index];const h=n[il];return null!==h&&(a[il]=h.createEmbeddedView(r)),xM(r,a,e),a}(this._declarationLView,this._declarationTContainer,t,{injector:e,dehydratedView:i});return new Gf(r)}};function GW(){return Wy(fr(),Se())}function Wy(n,t){return 4&n.type?new QW(t,n,Du(n,t)):null}class hw{constructor(t){this.queryList=t,this.matches=null}clone(){return new hw(this.queryList)}setDirty(){this.queryList.setDirty()}}class cw{constructor(t=[]){this.queries=t}createEmbeddedView(t){const e=t.queries;if(null!==e){const i=null!==t.contentQueries?t.contentQueries[0]:e.length,r=[];for(let s=0;s0)i.push(o[a/2]);else{const h=s[a+1],c=t[-l];for(let d=mn;d(qh(!0),function ny(n,t){return n.createText(t)}(t[Yt],i));function gw(n,t,e,i,r){if(n=vt(n),Array.isArray(n))for(let s=0;s>20;if(Gc(n)||!n.multi){const p=new xf(h,r,Ot),f=mw(l,t,r?c:c+u,d);-1===f?(o1(Um(a,o),s,l),vw(s,n,t.length),t.push(l),a.directiveStart++,a.directiveEnd++,r&&(a.providerIndexes+=1048576),e.push(p),o.push(p)):(e[f]=p,o[f]=p)}else{const p=mw(l,t,c+u,d),f=mw(l,t,c,c+u),v=f>=0&&e[f];if(r&&!v||!r&&!(p>=0&&e[p])){o1(Um(a,o),s,l);const y=function vY(n,t,e,i,r){const s=new xf(n,e,Ot);return s.multi=[],s.index=t,s.componentProviders=0,kP(s,r,i&&!e),s}(r?gY:fY,e.length,r,i,h);!r&&v&&(e[f].providerFactory=y),vw(s,n,t.length,0),t.push(l),a.directiveStart++,a.directiveEnd++,r&&(a.providerIndexes+=1048576),e.push(y),o.push(y)}else vw(s,n,p>-1?p:f,kP(e[r?f:p],h,!r&&i));!r&&i&&v&&e[f].componentProviders++}}}function vw(n,t,e,i){const r=Gc(t),s=function pj(n){return!!n.useClass}(t);if(r||s){const l=(s?vt(t.useClass):t).prototype.ngOnDestroy;if(l){const h=n.destroyHooks||(n.destroyHooks=[]);if(!r&&t.multi){const c=h.indexOf(e);-1===c?h.push(e,[i,l]):h[c+1].push(i,l)}else h.push(e,l)}}}function kP(n,t,e){return e&&n.componentProviders++,n.multi.push(t)-1}function mw(n,t,e,i){for(let r=e;r{e.providersResolver=(i,r)=>function pY(n,t,e){const i=xi();if(i.firstCreatePass){const r=Ca(n);gw(e,i.data,i.blueprint,r,!0),gw(t,i.data,i.blueprint,r,!1)}}(i,r?r(n):n,t)}}class rd{}class zP extends rd{constructor(t){super(),this.componentFactoryResolver=new JN(this),this.instance=null;const e=new vu([...t.providers,{provide:rd,useValue:this},{provide:Sy,useValue:this.componentFactoryResolver}],t.parent||Zm(),t.debugName,new Set(["environment"]));this.injector=e,t.runEnvironmentInitializers&&e.resolveInjectorInitializers()}destroy(){this.injector.destroy()}onDestroy(t){this.injector.onDestroy(t)}}let bY=(()=>{class n{constructor(e){this._injector=e,this.cachedInjectors=new Map}getOrCreateStandaloneInjector(e){if(!e.standalone)return null;if(!this.cachedInjectors.has(e)){const i=GA(0,e.type),r=i.length>0?function IY(n,t,e=null){return new zP({providers:n,parent:t,debugName:e,runEnvironmentInitializers:!0}).injector}([i],this._injector,`Standalone[${e.type.name}]`):null;this.cachedInjectors.set(e,r)}return this.cachedInjectors.get(e)}ngOnDestroy(){try{for(const e of this.cachedInjectors.values())null!==e&&e.destroy()}finally{this.cachedInjectors.clear()}}static{this.\u0275prov=Yi({token:n,providedIn:"environment",factory:()=>new n(Fi(Jl))})}}return n})();function RP(n){(function Zc(n){VN.has(n)||(VN.add(n),performance?.mark?.("mark_feature_usage",{detail:{feature:n}}))})("NgStandalone"),n.getStandaloneInjector=t=>t.get(bY).getOrCreateStandaloneInjector(n)}let xw=(()=>{class n{constructor(){this.taskId=0,this.pendingTasks=new Set,this.hasPendingTasks=new _o(!1)}get _hasPendingTasks(){return this.hasPendingTasks.value}add(){this._hasPendingTasks||this.hasPendingTasks.next(!0);const e=this.taskId++;return this.pendingTasks.add(e),e}remove(e){this.pendingTasks.delete(e),0===this.pendingTasks.size&&this._hasPendingTasks&&this.hasPendingTasks.next(!1)}ngOnDestroy(){this.pendingTasks.clear(),this._hasPendingTasks&&this.hasPendingTasks.next(!1)}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();const g2=new Ht(""),QQ=new Ht("");let Ow=(()=>{class n{constructor(){this.initialized=!1,this.done=!1,this.donePromise=new Promise((e,i)=>{this.resolve=e,this.reject=i}),this.appInits=Ri(QQ,{optional:!0})??[]}runInitializers(){if(this.initialized)return;const e=[];for(const r of this.appInits){const s=r();if(sw(s))e.push(s);else if(Gk(s)){const o=new Promise((a,l)=>{s.subscribe({complete:a,error:l})});e.push(o)}}const i=()=>{this.done=!0,this.resolve()};Promise.all(e).then(()=>{i()}).catch(r=>{this.reject(r)}),0===e.length&&i(),this.initialized=!0}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();const v2=new Ht("");let $u=(()=>{class n{constructor(){this._bootstrapListeners=[],this._runningTick=!1,this._destroyed=!1,this._destroyListeners=[],this._views=[],this.internalErrorHandler=Ri(yN),this.afterRenderEffectManager=Ri(Xf),this.componentTypes=[],this.components=[],this.isStable=Ri(xw).hasPendingTasks.pipe(jr(e=>!e)),this._injector=Ri(Jl)}get destroyed(){return this._destroyed}get injector(){return this._injector}bootstrap(e,i){const r=e instanceof iN;if(!this._injector.get(Ow).done)throw!r&&function _c(n){const t=ci(n)||jn(n)||gs(n);return null!==t&&t.standalone}(e),new F(405,!1);let o;o=r?e:this._injector.get(Sy).resolveComponentFactory(e),this.componentTypes.push(o.componentType);const a=function XQ(n){return n.isBoundToModule}(o)?void 0:this._injector.get(rd),h=o.create(Wo.NULL,[],i||o.selector,a),c=h.location.nativeElement,d=h.injector.get(g2,null);return d?.registerApplication(c),h.onDestroy(()=>{this.detachView(h.hostView),$y(this.components,h),d?.unregisterApplication(c)}),this._loadComponent(h),h}tick(){if(this._runningTick)throw new F(101,!1);try{this._runningTick=!0;for(let e of this._views)e.detectChanges()}catch(e){this.internalErrorHandler(e)}finally{try{this.afterRenderEffectManager.execute()}catch(e){this.internalErrorHandler(e)}this._runningTick=!1}}attachView(e){const i=e;this._views.push(i),i.attachToAppRef(this)}detachView(e){const i=e;$y(this._views,i),i.detachFromAppRef()}_loadComponent(e){this.attachView(e.hostView),this.tick(),this.components.push(e);const i=this._injector.get(v2,[]);[...this._bootstrapListeners,...i].forEach(r=>r(e))}ngOnDestroy(){if(!this._destroyed)try{this._destroyListeners.forEach(e=>e()),this._views.slice().forEach(e=>e.destroy())}finally{this._destroyed=!0,this._views=[],this._bootstrapListeners=[],this._destroyListeners=[]}}onDestroy(e){return this._destroyListeners.push(e),()=>$y(this._destroyListeners,e)}destroy(){if(this._destroyed)throw new F(406,!1);const e=this._injector;e.destroy&&!e.destroyed&&e.destroy()}get viewCount(){return this._views.length}warnIfDestroyed(){}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();function $y(n,t){const e=n.indexOf(t);e>-1&&n.splice(e,1)}let $Q=(()=>{class n{constructor(){this.zone=Ri(zr),this.applicationRef=Ri($u)}initialize(){this._onMicrotaskEmptySubscription||(this._onMicrotaskEmptySubscription=this.zone.onMicrotaskEmpty.subscribe({next:()=>{this.zone.run(()=>{this.applicationRef.tick()})}}))}ngOnDestroy(){this._onMicrotaskEmptySubscription?.unsubscribe()}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();function b2(n){return[{provide:zr,useFactory:n},{provide:gu,multi:!0,useFactory:()=>{const t=Ri($Q,{optional:!0});return()=>t.initialize()}},{provide:gu,multi:!0,useFactory:()=>{const t=Ri(KQ);return()=>{t.initialize()}}},{provide:yN,useFactory:ZQ}]}function ZQ(){const n=Ri(zr),t=Ri(eh);return e=>n.runOutsideAngular(()=>t.handleError(e))}function JQ(n){return function m1(n){return{\u0275providers:n}}([[],b2(()=>new zr(function M2(n){return{enableLongStackTrace:!1,shouldCoalesceEventChangeDetection:n?.eventCoalescing??!1,shouldCoalesceRunChangeDetection:n?.runCoalescing??!1}}(n)))])}let KQ=(()=>{class n{constructor(){this.subscription=new As,this.initialized=!1,this.zone=Ri(zr),this.pendingTasks=Ri(xw)}initialize(){if(this.initialized)return;this.initialized=!0;let e=null;!this.zone.isStable&&!this.zone.hasPendingMacrotasks&&!this.zone.hasPendingMicrotasks&&(e=this.pendingTasks.add()),this.zone.runOutsideAngular(()=>{this.subscription.add(this.zone.onStable.subscribe(()=>{zr.assertNotInAngularZone(),queueMicrotask(()=>{null!==e&&!this.zone.hasPendingMacrotasks&&!this.zone.hasPendingMicrotasks&&(this.pendingTasks.remove(e),e=null)})}))}),this.subscription.add(this.zone.onUnstable.subscribe(()=>{zr.assertInAngularZone(),e??=this.pendingTasks.add()}))}ngOnDestroy(){this.subscription.unsubscribe()}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();const rh=new Ht("",{providedIn:"root",factory:()=>Ri(rh,Di.Optional|Di.SkipSelf)||function eG(){return typeof $localize<"u"&&$localize.locale||Gu}()}),kw=new Ht("");let rc=null;function CG(n){try{const{rootComponent:t,appProviders:e,platformProviders:i}=n,r=function sG(n=[]){if(rc)return rc;const t=function E2(n=[],t){return Wo.create({name:t,providers:[{provide:I1,useValue:"platform"},{provide:kw,useValue:new Set([()=>rc=null])},...n]})}(n);return rc=t,function m2(){!function yb(n){Gd=n}(()=>{throw new F(600,!1)})}(),function D2(n){n.get(nL,null)?.forEach(e=>e())}(t),t}(i),s=[JQ(),...e||[]],a=new zP({providers:s,parent:r,debugName:"",runEnvironmentInitializers:!1}).injector,l=a.get(zr);return l.run(()=>{a.resolveInjectorInitializers();const h=a.get(eh,null);let c;l.runOutsideAngular(()=>{c=l.onError.subscribe({next:p=>{h.handleError(p)}})});const d=()=>a.destroy(),u=r.get(kw);return u.add(d),a.onDestroy(()=>{c.unsubscribe(),u.delete(d)}),function y2(n,t,e){try{const i=e();return sw(i)?i.catch(r=>{throw t.runOutsideAngular(()=>n.handleError(r)),r}):i}catch(i){throw t.runOutsideAngular(()=>n.handleError(i)),i}}(h,l,()=>{const p=a.get(Ow);return p.runInitializers(),p.donePromise.then(()=>{!function wk(n){ro(n,"Expected localeId to be defined"),"string"==typeof n&&(Mk=n.toLowerCase().replace(/_/g,"-"))}(a.get(rh,Gu)||Gu);const g=a.get($u);return void 0!==t&&g.bootstrap(t),g})})})}catch(t){return Promise.reject(t)}}let $2=null;function Uw(){return $2}class FG{}const sd=new Ht("");let rq=(()=>{class n{static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275mod=Am({type:n})}static{this.\u0275inj=gf({})}}return n})();function uz(n){return"server"===n}class Nq extends FG{constructor(){super(...arguments),this.supportsDOMEvents=!0}}class nC extends Nq{static makeCurrent(){!function BG(n){$2??=n}(new nC)}onAndCancel(t,e,i){return t.addEventListener(e,i),()=>{t.removeEventListener(e,i)}}dispatchEvent(t,e){t.dispatchEvent(e)}remove(t){t.parentNode&&t.parentNode.removeChild(t)}createElement(t,e){return(e=e||this.getDefaultDocument()).createElement(t)}createHtmlDocument(){return document.implementation.createHTMLDocument("fakeTitle")}getDefaultDocument(){return document}isElementNode(t){return t.nodeType===Node.ELEMENT_NODE}isShadowRoot(t){return t instanceof DocumentFragment}getGlobalEventTarget(t,e){return"window"===e?window:"document"===e?t:"body"===e?t.body:null}getBaseHref(t){const e=function Oq(){return wg=wg||document.querySelector("base"),wg?wg.getAttribute("href"):null}();return null==e?null:function kq(n){return new URL(n,document.baseURI).pathname}(e)}resetBaseElement(){wg=null}getUserAgent(){return window.navigator.userAgent}getCookie(t){return function EX(n,t){t=encodeURIComponent(t);for(const e of n.split(";")){const i=e.indexOf("="),[r,s]=-1==i?[e,""]:[e.slice(0,i),e.slice(i+1)];if(r.trim()===t)return decodeURIComponent(s)}return null}(document.cookie,t)}}let wg=null,zq=(()=>{class n{build(){return new XMLHttpRequest}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();const sC=new Ht("");let vz=(()=>{class n{constructor(e,i){this._zone=i,this._eventNameToPlugin=new Map,e.forEach(r=>{r.manager=this}),this._plugins=e.slice().reverse()}addEventListener(e,i,r){return this._findPluginFor(i).addEventListener(e,i,r)}getZone(){return this._zone}_findPluginFor(e){let i=this._eventNameToPlugin.get(e);if(i)return i;if(i=this._plugins.find(s=>s.supports(e)),!i)throw new F(5101,!1);return this._eventNameToPlugin.set(e,i),i}static{this.\u0275fac=function(i){return new(i||n)(Fi(sC),Fi(zr))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();class mz{constructor(t){this._doc=t}}const oC="ng-app-id";let yz=(()=>{class n{constructor(e,i,r,s={}){this.doc=e,this.appId=i,this.nonce=r,this.platformId=s,this.styleRef=new Map,this.hostNodes=new Set,this.styleNodesInDOM=this.collectServerRenderedStyles(),this.platformIsServer=uz(s),this.resetHostNodes()}addStyles(e){for(const i of e)1===this.changeUsageCount(i,1)&&this.onStyleAdded(i)}removeStyles(e){for(const i of e)this.changeUsageCount(i,-1)<=0&&this.onStyleRemoved(i)}ngOnDestroy(){const e=this.styleNodesInDOM;e&&(e.forEach(i=>i.remove()),e.clear());for(const i of this.getAllStyles())this.onStyleRemoved(i);this.resetHostNodes()}addHost(e){this.hostNodes.add(e);for(const i of this.getAllStyles())this.addStyleToHost(e,i)}removeHost(e){this.hostNodes.delete(e)}getAllStyles(){return this.styleRef.keys()}onStyleAdded(e){for(const i of this.hostNodes)this.addStyleToHost(i,e)}onStyleRemoved(e){const i=this.styleRef;i.get(e)?.elements?.forEach(r=>r.remove()),i.delete(e)}collectServerRenderedStyles(){const e=this.doc.head?.querySelectorAll(`style[${oC}="${this.appId}"]`);if(e?.length){const i=new Map;return e.forEach(r=>{null!=r.textContent&&i.set(r.textContent,r)}),i}return null}changeUsageCount(e,i){const r=this.styleRef;if(r.has(e)){const s=r.get(e);return s.usage+=i,s.usage}return r.set(e,{usage:i,elements:[]}),i}getStyleElement(e,i){const r=this.styleNodesInDOM,s=r?.get(i);if(s?.parentNode===e)return r.delete(i),s.removeAttribute(oC),s;{const o=this.doc.createElement("style");return this.nonce&&o.setAttribute("nonce",this.nonce),o.textContent=i,this.platformIsServer&&o.setAttribute(oC,this.appId),e.appendChild(o),o}}addStyleToHost(e,i){const r=this.getStyleElement(e,i),s=this.styleRef,o=s.get(i)?.elements;o?o.push(r):s.set(i,{elements:[r],usage:1})}resetHostNodes(){const e=this.hostNodes;e.clear(),e.add(this.doc.head)}static{this.\u0275fac=function(i){return new(i||n)(Fi(sd),Fi(x1),Fi(sL,8),Fi(yu))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();const aC={svg:"http://www.w3.org/2000/svg",xhtml:"http://www.w3.org/1999/xhtml",xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/",math:"http://www.w3.org/1998/MathML/"},lC=/%COMP%/g,Fq=new Ht("",{providedIn:"root",factory:()=>!0});function Iz(n,t){return t.map(e=>e.replace(lC,n))}let bz=(()=>{class n{constructor(e,i,r,s,o,a,l,h=null){this.eventManager=e,this.sharedStylesHost=i,this.appId=r,this.removeStylesOnCompDestroy=s,this.doc=o,this.platformId=a,this.ngZone=l,this.nonce=h,this.rendererByCompId=new Map,this.platformIsServer=uz(a),this.defaultRenderer=new hC(e,o,l,this.platformIsServer)}createRenderer(e,i){if(!e||!i)return this.defaultRenderer;this.platformIsServer&&i.encapsulation===Ia.ShadowDom&&(i={...i,encapsulation:Ia.Emulated});const r=this.getOrCreateRenderer(e,i);return r instanceof wz?r.applyToHost(e):r instanceof cC&&r.applyStyles(),r}getOrCreateRenderer(e,i){const r=this.rendererByCompId;let s=r.get(i.id);if(!s){const o=this.doc,a=this.ngZone,l=this.eventManager,h=this.sharedStylesHost,c=this.removeStylesOnCompDestroy,d=this.platformIsServer;switch(i.encapsulation){case Ia.Emulated:s=new wz(l,h,i,this.appId,c,o,a,d);break;case Ia.ShadowDom:return new Vq(l,h,e,i,o,a,this.nonce,d);default:s=new cC(l,h,i,c,o,a,d)}r.set(i.id,s)}return s}ngOnDestroy(){this.rendererByCompId.clear()}static{this.\u0275fac=function(i){return new(i||n)(Fi(vz),Fi(yz),Fi(x1),Fi(Fq),Fi(sd),Fi(yu),Fi(zr),Fi(sL))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();class hC{constructor(t,e,i,r){this.eventManager=t,this.doc=e,this.ngZone=i,this.platformIsServer=r,this.data=Object.create(null),this.throwOnSyntheticProps=!0,this.destroyNode=null}destroy(){}createElement(t,e){return e?this.doc.createElementNS(aC[e]||e,t):this.doc.createElement(t)}createComment(t){return this.doc.createComment(t)}createText(t){return this.doc.createTextNode(t)}appendChild(t,e){(Mz(t)?t.content:t).appendChild(e)}insertBefore(t,e,i){t&&(Mz(t)?t.content:t).insertBefore(e,i)}removeChild(t,e){t&&t.removeChild(e)}selectRootElement(t,e){let i="string"==typeof t?this.doc.querySelector(t):t;if(!i)throw new F(-5104,!1);return e||(i.textContent=""),i}parentNode(t){return t.parentNode}nextSibling(t){return t.nextSibling}setAttribute(t,e,i,r){if(r){e=r+":"+e;const s=aC[r];s?t.setAttributeNS(s,e,i):t.setAttribute(e,i)}else t.setAttribute(e,i)}removeAttribute(t,e,i){if(i){const r=aC[i];r?t.removeAttributeNS(r,e):t.removeAttribute(`${i}:${e}`)}else t.removeAttribute(e)}addClass(t,e){t.classList.add(e)}removeClass(t,e){t.classList.remove(e)}setStyle(t,e,i,r){r&(Kh.DashCase|Kh.Important)?t.style.setProperty(e,i,r&Kh.Important?"important":""):t.style[e]=i}removeStyle(t,e,i){i&Kh.DashCase?t.style.removeProperty(e):t.style[e]=""}setProperty(t,e,i){null!=t&&(t[e]=i)}setValue(t,e){t.nodeValue=e}listen(t,e,i){if("string"==typeof t&&!(t=Uw().getGlobalEventTarget(this.doc,t)))throw new Error(`Unsupported event target ${t} for event ${e}`);return this.eventManager.addEventListener(t,e,this.decoratePreventDefault(i))}decoratePreventDefault(t){return e=>{if("__ngUnwrap__"===e)return t;!1===(this.platformIsServer?this.ngZone.runGuarded(()=>t(e)):t(e))&&e.preventDefault()}}}function Mz(n){return"TEMPLATE"===n.tagName&&void 0!==n.content}class Vq extends hC{constructor(t,e,i,r,s,o,a,l){super(t,s,o,l),this.sharedStylesHost=e,this.hostEl=i,this.shadowRoot=i.attachShadow({mode:"open"}),this.sharedStylesHost.addHost(this.shadowRoot);const h=Iz(r.id,r.styles);for(const c of h){const d=document.createElement("style");a&&d.setAttribute("nonce",a),d.textContent=c,this.shadowRoot.appendChild(d)}}nodeOrShadowRoot(t){return t===this.hostEl?this.shadowRoot:t}appendChild(t,e){return super.appendChild(this.nodeOrShadowRoot(t),e)}insertBefore(t,e,i){return super.insertBefore(this.nodeOrShadowRoot(t),e,i)}removeChild(t,e){return super.removeChild(this.nodeOrShadowRoot(t),e)}parentNode(t){return this.nodeOrShadowRoot(super.parentNode(this.nodeOrShadowRoot(t)))}destroy(){this.sharedStylesHost.removeHost(this.shadowRoot)}}class cC extends hC{constructor(t,e,i,r,s,o,a,l){super(t,s,o,a),this.sharedStylesHost=e,this.removeStylesOnCompDestroy=r,this.styles=l?Iz(l,i.styles):i.styles}applyStyles(){this.sharedStylesHost.addStyles(this.styles)}destroy(){this.removeStylesOnCompDestroy&&this.sharedStylesHost.removeStyles(this.styles)}}class wz extends cC{constructor(t,e,i,r,s,o,a,l){const h=r+"-"+i.id;super(t,e,i,s,o,a,l,h),this.contentAttr=function _q(n){return"_ngcontent-%COMP%".replace(lC,n)}(h),this.hostAttr=function Uq(n){return"_nghost-%COMP%".replace(lC,n)}(h)}applyToHost(t){this.applyStyles(),this.setAttribute(t,this.hostAttr,"")}createElement(t,e){const i=super.createElement(t,e);return super.setAttribute(i,this.contentAttr,""),i}}let Wq=(()=>{class n extends mz{constructor(e){super(e)}supports(e){return!0}addEventListener(e,i,r){return e.addEventListener(i,r,!1),()=>this.removeEventListener(e,i,r)}removeEventListener(e,i,r){return e.removeEventListener(i,r)}static{this.\u0275fac=function(i){return new(i||n)(Fi(sd))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();const Cz=["alt","control","meta","shift"],Yq={"\b":"Backspace","\t":"Tab","\x7f":"Delete","\x1b":"Escape",Del:"Delete",Esc:"Escape",Left:"ArrowLeft",Right:"ArrowRight",Up:"ArrowUp",Down:"ArrowDown",Menu:"ContextMenu",Scroll:"ScrollLock",Win:"OS"},Qq={alt:n=>n.altKey,control:n=>n.ctrlKey,meta:n=>n.metaKey,shift:n=>n.shiftKey};let Gq=(()=>{class n extends mz{constructor(e){super(e)}supports(e){return null!=n.parseEventName(e)}addEventListener(e,i,r){const s=n.parseEventName(i),o=n.eventCallback(s.fullKey,r,this.manager.getZone());return this.manager.getZone().runOutsideAngular(()=>Uw().onAndCancel(e,s.domEventName,o))}static parseEventName(e){const i=e.toLowerCase().split("."),r=i.shift();if(0===i.length||"keydown"!==r&&"keyup"!==r)return null;const s=n._normalizeKey(i.pop());let o="",a=i.indexOf("code");if(a>-1&&(i.splice(a,1),o="code."),Cz.forEach(h=>{const c=i.indexOf(h);c>-1&&(i.splice(c,1),o+=h+".")}),o+=s,0!=i.length||0===s.length)return null;const l={};return l.domEventName=r,l.fullKey=o,l}static matchEventFullKeyCode(e,i){let r=Yq[e.key]||e.key,s="";return i.indexOf("code.")>-1&&(r=e.code,s="code."),!(null==r||!r)&&(r=r.toLowerCase()," "===r?r="space":"."===r&&(r="dot"),Cz.forEach(o=>{o!==r&&(0,Qq[o])(e)&&(s+=o+".")}),s+=r,s===i)}static eventCallback(e,i,r){return s=>{n.matchEventFullKeyCode(s,e)&&r.runGuarded(()=>i(s))}}static _normalizeKey(e){return"esc"===e?"escape":e}static{this.\u0275fac=function(i){return new(i||n)(Fi(sd))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();function Ez(n){return{appProviders:[...e$,...n?.providers??[]],platformProviders:Jq}}const Jq=[{provide:yu,useValue:"browser"},{provide:nL,useValue:function qq(){nC.makeCurrent()},multi:!0},{provide:sd,useFactory:function Zq(){return function xj(n){D1=n}(document),document},deps:[]}],e$=[{provide:I1,useValue:"root"},{provide:eh,useFactory:function $q(){return new eh},deps:[]},{provide:sC,useClass:Wq,multi:!0,deps:[sd,zr,yu]},{provide:sC,useClass:Gq,multi:!0,deps:[sd]},bz,yz,vz,{provide:nN,useExisting:bz},{provide:class lq{},useClass:zq,deps:[]},[]];var n$=0,dC=!1;function S0(n,t){var e=t;return e.unshift(void 0),new(Function.prototype.bind.apply(n,e))}function Y(n,t){for(var e=t,i=n.replace(/\[/g,".").replace(/\]/g,"").split("."),r=0;r"u"}function wi(n){return n+"_"+n$++}function b0(n,t){return n===t||!(n===document||!n)&&b0(n.parentNode,t)}function Dg(n){try{throw new Error(n)}catch(t){throw new Error(t.message+"\n"+t.stack)}}function Re(n){var t=n+"";return t.match(/auto|cm|mm|in|px|pt|pc|%|em|ex|ch|rem|vw|vh|vmin|vmax/)?t:t+"px"}function ce(){return dC}var xg,n,t,h$={latn:{_digits:"0123456789",_type:"numeric"}},Lz={decimal:".",group:",",percentSign:"%",plusSign:"+",minusSign:"-",infinity:"\u221e",nan:"NaN",exponential:"E"},Nz=[0,1,2,3,4,5,6,7,8,9],Rr=function(){function n(){}return n.getMainObject=function(t,e){return Y(ce()?e:"main."+e,t)},n.getNumberingSystem=function(t){return Y("supplemental.numberingSystems",t)||this.numberingSystems},n.reverseObject=function(t,e){for(var r={},s=0,o=e||Object.keys(t);s13&&(f+=1,o-=12),o-=1,a=f-4716;var y=u-24e5,S=10631/30,b=u-1948084,M=Math.floor(b/10631);b-=10631*M;var w=Math.floor((b-.1335)/S),C=30*M+w;b-=Math.floor(w*S+.1335);var D=Math.floor((b+28.5001)/29.5);13===D&&(D=12);for(var A=b-Math.floor(29.5001*D-29),x=0;xy);x++);var R=x+16260,L=Math.floor((R-1)/12),O=L+1,N=R-12*L,T=y-t[x-1]+1;return(T+"").length>2&&(T=A,N=D,O=C),{year:O,month:N,date:T}},n.toGregorian=function i(r,s,o){var g=Math.floor(o+t[12*(r-1)+1+(s-1)-16260-1]-1+24e5+.5),v=Math.floor((g-1867216.25)/36524.25),y=1524+(v=g+1+v-Math.floor(v/4)),S=Math.floor((y-122.1)/365.25),b=Math.floor(365.25*S),M=Math.floor((y-b)/30.6001),w=y-b-Math.floor(30.6001*M),C=M-(M>13.5?13:1),D=S-(C>2.5?4716:4715);return D<=0&&C--,new Date(D+"/"+C+"/"+w)};var ut,u$=/\/MMMMM|MMMM|MMM|a|LLLL|LLL|EEEEE|EEEE|E|K|cccc|ccc|WW|W|G+|z+/gi,Oz="stand-alone",p$=["sun","mon","tue","wed","thu","fri","sat"],kz={m:"getMinutes",h:"getHours",H:"getHours",s:"getSeconds",d:"getDate",f:"getMilliseconds"},Pz=function(){function n(){}return n.dateFormat=function(t,e,i){var r=this,s=ut.getDependables(i,t,e.calendar),o=Y("parserObject.numbers",s),a=s.dateObject,l={isIslamic:ut.islamicRegex.test(e.calendar)};ce()&&e.isServerRendered&&(e=ut.compareBlazorDateFormats(e,t));var h=e.format||ut.getResultantPattern(e.skeleton,s.dateObject,e.type,!1,ce()?t:"");if(l.dateSeperator=ce()?Y("dateSeperator",a):ut.getDateSeparator(s.dateObject),st(h))Dg("Format options or type given must be invalid");else{h=ut.ConvertDateToWeekFormat(h),ce()&&(h=h.replace(/tt/,"a")),l.pattern=h,l.numMapper=ce()?ze({},o):Rr.getNumberMapper(s.parserObject,Rr.getNumberingSystem(i));for(var d=0,u=h.match(u$)||[];d2?r+=e.month[""+u]:f=!0;break;case"E":case"c":r+=e.weekday[""+p$[t.getDay()]];break;case"H":case"h":case"m":case"s":case"d":case"f":if(f=!0,"d"===d)u=o.date;else if("f"===d){f=!1,g=!0;var y=(p=(p=t[""+kz[""+d]]().toString()).substring(0,c)).length;if(c!==y){if(c>3)continue;for(var S=0;S0?1:0],o=Math.abs(t);return s.replace(/HH?|mm/g,function(a){var l=a.length,h=-1!==a.indexOf("H");return i.checkTwodigitNumber(Math.floor(h?o/60:o%60),l)})},n}(),zz={ms:"minimumSignificantDigits",ls:"maximumSignificantDigits",mf:"minimumFractionDigits",lf:"maximumFractionDigits"},ep=["infinity","nan","group","decimal","exponential"],Rz=function(){function n(){}return n.numberFormatter=function(t,e,i){var l,r=this,s=ze({},e),o={},a={},h=ut.getDependables(i,t,"",!0),c=h.numericObject;a.numberMapper=ce()?ze({},c):Rr.getNumberMapper(h.parserObject,Rr.getNumberingSystem(i),!0),a.currencySymbol=ce()?Y("currencySymbol",c):ut.getCurrencySymbol(h.numericObject,s.currency||Lg,e.altSymbol,e.ignoreCurrency),a.percentSymbol=ce()?Y("numberSymbols.percentSign",c):a.numberMapper.numberSymbols.percentSign,a.minusSymbol=ce()?Y("numberSymbols.minusSign",c):a.numberMapper.numberSymbols.minusSign;var d=a.numberMapper.numberSymbols;if(e.format&&!ut.formatRegex.test(e.format))o=ut.customFormat(e.format,a,h.numericObject),!st(s.useGrouping)&&s.useGrouping&&(s.useGrouping=o.pData.useGrouping);else{if(ze(s,ut.getProperNumericSkeleton(e.format||"N")),s.isCurrency="currency"===s.type,s.isPercent="percent"===s.type,ce()||(l=ut.getSymbolPattern(s.type,a.numberMapper.numberSystem,h.numericObject,s.isAccount)),s.groupOne=this.checkValueRange(s.maximumSignificantDigits,s.minimumSignificantDigits,!0),this.checkValueRange(s.maximumFractionDigits,s.minimumFractionDigits,!1,!0),st(s.fractionDigits)||(s.minimumFractionDigits=s.maximumFractionDigits=s.fractionDigits),st(s.useGrouping)&&(s.useGrouping=!0),s.isCurrency&&!ce()&&(l=l.replace(/\u00A4/g,ut.defaultCurrency)),ce())o.nData=ze({},{},Y(s.type+"nData",c)),o.pData=ze({},{},Y(s.type+"pData",c)),"currency"===s.type&&e.currency&&ut.replaceBlazorCurrency([o.pData,o.nData],a.currencySymbol,e.currency);else{var u=l.split(";");o.nData=ut.getFormatData(u[1]||"-"+u[0],!0,a.currencySymbol),o.pData=ut.getFormatData(u[0],!1,a.currencySymbol),s.useGrouping&&(s.groupSeparator=d[ep[2]],s.groupData=this.getGroupingDetails(u[0]))}if(st(s.minimumFractionDigits)&&(s.minimumFractionDigits=o.nData.minimumFraction),st(s.maximumFractionDigits)){var f=o.nData.maximumFraction;s.maximumFractionDigits=st(f)&&s.isPercent?0:f}var g=s.minimumFractionDigits,v=s.maximumFractionDigits;!st(g)&&!st(v)&&g>v&&(s.maximumFractionDigits=g)}return ze(o.nData,s),ze(o.pData,s),function(y){return isNaN(y)?d[ep[1]]:isFinite(y)?r.intNumberFormatter(y,o,a,e):d[ep[0]]}},n.getGroupingDetails=function(t){var e={},i=t.match(ut.negativeDataRegex);if(i&&i[4]){var r=i[4],s=r.lastIndexOf(",");if(-1!==s){var o=r.split(".")[0];e.primary=o.length-s-1;var a=r.lastIndexOf(",",s-1);-1!==a&&(e.secondary=s-1-a)}}return e},n.checkValueRange=function(t,e,i,r){var s=r?"f":"s",o=0,a=zz["l"+s],l=zz["m"+s];if(st(t)||(this.checkRange(t,a,r),o++),st(e)||(this.checkRange(e,l,r),o++),2===o){if(!(tr[1])&&Dg(e+"value must be within the range"+r[0]+"to"+r[1])},n.intNumberFormatter=function(t,e,i,r){var s;if(!st(e.nData.type)){t<0?(t*=-1,s=e.nData):s=0===t&&e.zeroData||e.pData;var o="";if(s.isPercent&&(t*=100),s.groupOne)o=this.processSignificantDigits(t,s.minimumSignificantDigits,s.maximumSignificantDigits);else if(o=this.processFraction(t,s.minimumFractionDigits,s.maximumFractionDigits,r),s.minimumIntegerDigits&&(o=this.processMinimumIntegers(o,s.minimumIntegerDigits)),i.isCustomFormat&&s.minimumFractionDigits=0&&"0"===l[parseInt(c.toString(),10)]&&c>=s.minimumFractionDigits;c--)l=l.slice(0,c);o=a[0]+"."+l}return"scientific"===s.type&&(o=(o=t.toExponential(s.maximumFractionDigits)).replace("e",i.numberMapper.numberSymbols[ep[4]])),o=o.replace(".",i.numberMapper.numberSymbols[ep[3]]),o="#,###,,;(#,###,,)"===s.format?this.customPivotFormat(parseInt(o,10)):o,s.useGrouping&&(o=this.groupNumbers(o,s.groupData.primary,s.groupSeparator||",",i.numberMapper.numberSymbols[ep[3]]||".",s.groupData.secondary)),o=Rr.convertValueParts(o,ut.latnParseRegex,i.numberMapper.mapper),"N/A"===s.nlead?s.nlead:"0"===o&&r&&"0"===r.format?o+s.nend:s.nlead+o+s.nend}},n.processSignificantDigits=function(t,e,i){var r=t+"";return r.lengthe;)c=l.slice(h-e,h)+(c.length?i+c:""),h-=e,o&&(e=s,o=!1);return a[0]=l.slice(0,h)+(c.length?i:"")+c,a.join(r)},n.processFraction=function(t,e,i,r){var s=(t+"").split(".")[1],o=s?s.length:0;if(e&&oi||0===i))return t.toFixed(i);var h=t+"";return"0"===h[0]&&r&&"###.00"===r.format&&(h=h.slice(1)),h},n.processMinimumIntegers=function(t,e){var i=t.split("."),r=i[0],s=r.length;if(s=5e5){var r=(t/=1e6).toString().split(".")[1];return r&&+r.substring(0,1)>=5?Math.ceil(t).toString():Math.floor(t).toString()}return""},n}(),Tg=(new RegExp("^([^0-9]*)(([0-9,]*[0-9]+)(.[0-9]+)?)([Ee][+-]?[0-9]+)?([^0-9]*)$"),function(){function n(t){this.ranArray=[],this.boundedEvents={},!m(t)&&(this.context=t)}return n.prototype.on=function(t,e,i,r){if(!m(e)){var s=i||this.context;if(this.notExist(t))return void(this.boundedEvents[""+t]=[{handler:e,context:s,id:r}]);m(r)?this.isHandlerPresent(this.boundedEvents[""+t],e)||this.boundedEvents[""+t].push({handler:e,context:s}):-1===this.ranArray.indexOf(r)&&(this.ranArray.push(r),this.boundedEvents[""+t].push({handler:e,context:s,id:r}))}},n.prototype.off=function(t,e,i){if(!this.notExist(t)){var r=Y(t,this.boundedEvents);if(e){for(var s=0;s1&&(_.fractionDigits=parseInt(P[2],10)),_}function f(T,P,_,B){var j=B?{}:{nlead:"",nend:""},Q=T.match(n.customRegex);if(Q){B||(j.nlead=g(Q[1],_),j.nend=g(Q[10],_),j.groupPattern=Q[4]);var oe=Q[7];if(oe&&P){var ue=oe.match(t);j.minimumFraction=m(ue)?0:ue.length,j.maximumFraction=oe.length-1}}return j}function g(T,P){return T?(T=T.replace(n.defaultCurrency,P),""===P?T.trim():T):""}function v(T,P,_,B){return B?"$":Y("currencies."+P+(_?"."+_:".symbol"),T)||Y("currencies."+P+".symbol-alt-narrow",T)||"$"}function S(T,P,_){var B={type:"decimal",minimumFractionDigits:0,maximumFractionDigits:0},j=T.match(n.customRegex);if(m(j)||""===j[5]&&"N/A"!==T)return B.type=void 0,B;B.nlead=j[1],B.nend=j[10];var Q=j[6],oe=!!Q.match(/ $/g),ue=-1!==Q.replace(/ $/g,"").indexOf(" ");B.useGrouping=-1!==Q.indexOf(",")||ue,Q=Q.replace(/,/g,"");var pe=j[7];if(-1!==Q.indexOf("0")&&(B.minimumIntegerDigits=Q.length-Q.indexOf("0")),m(pe)||(B.minimumFractionDigits=pe.lastIndexOf("0"),B.maximumFractionDigits=pe.lastIndexOf("#"),-1===B.minimumFractionDigits&&(B.minimumFractionDigits=0),(-1===B.maximumFractionDigits||B.maximumFractionDigitsQ.lastIndexOf("'"))){B[""+a[parseInt(j.toString(),10)]]=Q.substr(0,oe)+_+Q.substr(oe+1),B[""+a[""+P]]=!0,B.type=B.isCurrency?"currency":"percent";break}}return B}function C(T,P){if(-1!==T.indexOf(",")){var _=T.split(",");T=_[0]+Y("numberMapper.numberSymbols.group",P)+_[1].replace(".",Y("numberMapper.numberSymbols.decimal",P))}else T=T.replace(".",Y("numberMapper.numberSymbols.decimal",P));return T}function A(T,P,_){T+=".";for(var B=0;B0;Q-=3)T=","+_[Q-2]+_[Q-1]+_[parseInt(Q.toString(),10)]+T;return T=T.slice(1),P[1]?T+"."+P[1]:T}n.dateParseRegex=/([a-z])\1*|'([^']|'')+'|''|./gi,n.basicPatterns=["short","medium","long","full"],n.defaultObject={dates:{calendars:{gregorian:{months:{"stand-alone":{abbreviated:{1:"Jan",2:"Feb",3:"Mar",4:"Apr",5:"May",6:"Jun",7:"Jul",8:"Aug",9:"Sep",10:"Oct",11:"Nov",12:"Dec"},narrow:{1:"J",2:"F",3:"M",4:"A",5:"M",6:"J",7:"J",8:"A",9:"S",10:"O",11:"N",12:"D"},wide:{1:"January",2:"February",3:"March",4:"April",5:"May",6:"June",7:"July",8:"August",9:"September",10:"October",11:"November",12:"December"}}},days:{"stand-alone":{abbreviated:{sun:"Sun",mon:"Mon",tue:"Tue",wed:"Wed",thu:"Thu",fri:"Fri",sat:"Sat"},narrow:{sun:"S",mon:"M",tue:"T",wed:"W",thu:"T",fri:"F",sat:"S"},short:{sun:"Su",mon:"Mo",tue:"Tu",wed:"We",thu:"Th",fri:"Fr",sat:"Sa"},wide:{sun:"Sunday",mon:"Monday",tue:"Tuesday",wed:"Wednesday",thu:"Thursday",fri:"Friday",sat:"Saturday"}}},dayPeriods:{format:{wide:{am:"AM",pm:"PM"}}},eras:{eraNames:{0:"Before Christ","0-alt-variant":"Before Common Era",1:"Anno Domini","1-alt-variant":"Common Era"},eraAbbr:{0:"BC","0-alt-variant":"BCE",1:"AD","1-alt-variant":"CE"},eraNarrow:{0:"B","0-alt-variant":"BCE",1:"A","1-alt-variant":"CE"}},dateFormats:{full:"EEEE, MMMM d, y",long:"MMMM d, y",medium:"MMM d, y",short:"M/d/yy"},timeFormats:{full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},dateTimeFormats:{full:"{1} 'at' {0}",long:"{1} 'at' {0}",medium:"{1}, {0}",short:"{1}, {0}",availableFormats:{d:"d",E:"ccc",Ed:"d E",Ehm:"E h:mm a",EHm:"E HH:mm",Ehms:"E h:mm:ss a",EHms:"E HH:mm:ss",Gy:"y G",GyMMM:"MMM y G",GyMMMd:"MMM d, y G",GyMMMEd:"E, MMM d, y G",h:"h a",H:"HH",hm:"h:mm a",Hm:"HH:mm",hms:"h:mm:ss a",Hms:"HH:mm:ss",hmsv:"h:mm:ss a v",Hmsv:"HH:mm:ss v",hmv:"h:mm a v",Hmv:"HH:mm v",M:"L",Md:"M/d",MEd:"E, M/d",MMM:"LLL",MMMd:"MMM d",MMMEd:"E, MMM d",MMMMd:"MMMM d",ms:"mm:ss",y:"y",yM:"M/y",yMd:"M/d/y",yMEd:"E, M/d/y",yMMM:"MMM y",yMMMd:"MMM d, y",yMMMEd:"E, MMM d, y",yMMMM:"MMMM y"}}},islamic:{months:{"stand-alone":{abbreviated:{1:"Muh.",2:"Saf.",3:"Rab. I",4:"Rab. II",5:"Jum. I",6:"Jum. II",7:"Raj.",8:"Sha.",9:"Ram.",10:"Shaw.",11:"Dhu\u02bbl-Q.",12:"Dhu\u02bbl-H."},narrow:{1:"1",2:"2",3:"3",4:"4",5:"5",6:"6",7:"7",8:"8",9:"9",10:"10",11:"11",12:"12"},wide:{1:"Muharram",2:"Safar",3:"Rabi\u02bb I",4:"Rabi\u02bb II",5:"Jumada I",6:"Jumada II",7:"Rajab",8:"Sha\u02bbban",9:"Ramadan",10:"Shawwal",11:"Dhu\u02bbl-Qi\u02bbdah",12:"Dhu\u02bbl-Hijjah"}}},days:{"stand-alone":{abbreviated:{sun:"Sun",mon:"Mon",tue:"Tue",wed:"Wed",thu:"Thu",fri:"Fri",sat:"Sat"},narrow:{sun:"S",mon:"M",tue:"T",wed:"W",thu:"T",fri:"F",sat:"S"},short:{sun:"Su",mon:"Mo",tue:"Tu",wed:"We",thu:"Th",fri:"Fr",sat:"Sa"},wide:{sun:"Sunday",mon:"Monday",tue:"Tuesday",wed:"Wednesday",thu:"Thursday",fri:"Friday",sat:"Saturday"}}},dayPeriods:{format:{wide:{am:"AM",pm:"PM"}}},eras:{eraNames:{0:"AH"},eraAbbr:{0:"AH"},eraNarrow:{0:"AH"}},dateFormats:{full:"EEEE, MMMM d, y G",long:"MMMM d, y G",medium:"MMM d, y G",short:"M/d/y GGGGG"},timeFormats:{full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},dateTimeFormats:{full:"{1} 'at' {0}",long:"{1} 'at' {0}",medium:"{1}, {0}",short:"{1}, {0}",availableFormats:{d:"d",E:"ccc",Ed:"d E",Ehm:"E h:mm a",EHm:"E HH:mm",Ehms:"E h:mm:ss a",EHms:"E HH:mm:ss",Gy:"y G",GyMMM:"MMM y G",GyMMMd:"MMM d, y G",GyMMMEd:"E, MMM d, y G",h:"h a",H:"HH",hm:"h:mm a",Hm:"HH:mm",hms:"h:mm:ss a",Hms:"HH:mm:ss",M:"L",Md:"M/d",MEd:"E, M/d",MMM:"LLL",MMMd:"MMM d",MMMEd:"E, MMM d",MMMMd:"MMMM d",ms:"mm:ss",y:"y G",yyyy:"y G",yyyyM:"M/y GGGGG",yyyyMd:"M/d/y GGGGG",yyyyMEd:"E, M/d/y GGGGG",yyyyMMM:"MMM y G",yyyyMMMd:"MMM d, y G",yyyyMMMEd:"E, MMM d, y G",yyyyMMMM:"MMMM y G",yyyyQQQ:"QQQ y G",yyyyQQQQ:"QQQQ y G"}}}},timeZoneNames:{hourFormat:"+HH:mm;-HH:mm",gmtFormat:"GMT{0}",gmtZeroFormat:"GMT"}},numbers:{currencies:{USD:{displayName:"US Dollar",symbol:"$","symbol-alt-narrow":"$"},EUR:{displayName:"Euro",symbol:"\u20ac","symbol-alt-narrow":"\u20ac"},GBP:{displayName:"British Pound","symbol-alt-narrow":"\xa3"}},defaultNumberingSystem:"latn",minimumGroupingDigits:"1","symbols-numberSystem-latn":{decimal:".",group:",",list:";",percentSign:"%",plusSign:"+",minusSign:"-",exponential:"E",superscriptingExponent:"\xd7",perMille:"\u2030",infinity:"\u221e",nan:"NaN",timeSeparator:":"},"decimalFormats-numberSystem-latn":{standard:"#,##0.###"},"percentFormats-numberSystem-latn":{standard:"#,##0%"},"currencyFormats-numberSystem-latn":{standard:"\xa4#,##0.00",accounting:"\xa4#,##0.00;(\xa4#,##0.00)"},"scientificFormats-numberSystem-latn":{standard:"#E0"}}},n.blazorDefaultObject={numbers:{mapper:{0:"0",1:"1",2:"2",3:"3",4:"4",5:"5",6:"6",7:"7",8:"8",9:"9"},mapperDigits:"0123456789",numberSymbols:{decimal:".",group:",",plusSign:"+",minusSign:"-",percentSign:"%",nan:"NaN",timeSeparator:":",infinity:"\u221e"},timeSeparator:":",currencySymbol:"$",currencypData:{nlead:"$",nend:"",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},percentpData:{nlead:"",nend:"%",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},percentnData:{nlead:"-",nend:"%",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},currencynData:{nlead:"($",nend:")",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},decimalnData:{nlead:"-",nend:"",groupData:{primary:3},maximumFraction:2,minimumFraction:2},decimalpData:{nlead:"",nend:"",groupData:{primary:3},maximumFraction:2,minimumFraction:2}},dates:{dayPeriods:{am:"AM",pm:"PM"},dateSeperator:"/",days:{abbreviated:{sun:"Sun",mon:"Mon",tue:"Tue",wed:"Wed",thu:"Thu",fri:"Fri",sat:"Sat"},short:{sun:"Su",mon:"Mo",tue:"Tu",wed:"We",thu:"Th",fri:"Fr",sat:"Sa"},wide:{sun:"Sunday",mon:"Monday",tue:"Tuesday",wed:"Wednesday",thu:"Thursday",fri:"Friday",sat:"Saturday"}},months:{abbreviated:{1:"Jan",2:"Feb",3:"Mar",4:"Apr",5:"May",6:"Jun",7:"Jul",8:"Aug",9:"Sep",10:"Oct",11:"Nov",12:"Dec"},wide:{1:"January",2:"February",3:"March",4:"April",5:"May",6:"June",7:"July",8:"August",9:"September",10:"October",11:"November",12:"December"}},eras:{1:"AD"}}},n.monthIndex={3:"abbreviated",4:"wide",5:"narrow",1:"abbreviated"},n.month="months",n.days="days",n.patternMatcher={C:"currency",P:"percent",N:"decimal",A:"currency",E:"scientific"},n.getResultantPattern=l,n.getDependables=h,n.getSymbolPattern=c,n.ConvertDateToWeekFormat=d,n.compareBlazorDateFormats=u,n.getProperNumericSkeleton=p,n.getFormatData=f,n.changeCurrencySymbol=g,n.getCurrencySymbol=v,n.customFormat=function y(T,P,_){for(var B={},j=T.split(";"),Q=["pData","nData","zeroData"],oe=0;oe1,pe.nData=ce()?Y(De.type+"nData",oe):f(ot[1]||"-"+ot[0],!0,Ie),pe.pData=ce()?Y(De.type+"pData",oe):f(ot[0],!1,Ie),!Me[2]&&!P.minimumFractionDigits&&!P.maximumFractionDigits&&(ue=f(Ve.split(";")[0],!0,"",!0).minimumFraction)}if(n.formatRegex.test(P.format)||!P.format){if(ze(Q,p(P.format||"N")),Q.custom=!1,$e="###0",(Q.fractionDigits||P.minimumFractionDigits||P.maximumFractionDigits||ue)&&(Q.fractionDigits&&(P.minimumFractionDigits=P.maximumFractionDigits=Q.fractionDigits),$e=A($e,ue||Q.fractionDigits||P.minimumFractionDigits||0,P.maximumFractionDigits||0)),P.minimumIntegerDigits&&($e=x($e,P.minimumIntegerDigits)),P.useGrouping&&($e=R($e)),"currency"===Q.type||Q.type&&ce()){ce()&&"currency"!==Q.type&&(pe.pData=Y(Q.type+"pData",oe),pe.nData=Y(Q.type+"nData",oe));var hr=$e;$e=pe.pData.nlead+hr+pe.pData.nend,(pe.hasNegativePattern||ce())&&($e+=";"+pe.nData.nlead+hr+pe.nData.nend)}"percent"===Q.type&&!ce()&&($e+=" %")}else $e=P.format.replace(/'/g,'"');return Object.keys(xe).length>0&&($e=B?$e:C($e,xe)),$e},n.fractionDigitsPattern=A,n.minimumIntegerPattern=x,n.groupingPattern=R,n.getWeekData=function L(T,P){var _="sun",B=Y("supplemental.weekData.firstDay",P),j=T;return/en-/.test(j)&&(j=j.slice(3)),j=j.slice(0,2).toUpperCase()+j.substr(2),B&&(_=B[""+j]||B[j.slice(0,2)]||"sun"),o[""+_]},n.replaceBlazorCurrency=function O(T,P,_){var B=function d$(n){return Y(n||"",c$)}(_);if(P!==B)for(var j=0,Q=T;j=0?_:_+7;var j=Math.floor((T.getTime()-P.getTime()-6e4*(T.getTimezoneOffset()-P.getTimezoneOffset()))/864e5)+1;if(_<4){if((B=Math.floor((j+_-1)/7)+1)>52){var oe=new Date(T.getFullYear()+1,0,1).getDay();B=(oe=oe>=0?oe:oe+7)<4?1:53}}else B=Math.floor((j+_-1)/7);return B}}(ut||(ut={}));var tp=function(){function n(t,e,i){this.type="GET",this.emitError=!0,"string"==typeof t?(this.url=t,this.type=m(e)?this.type:e.toUpperCase(),this.contentType=i):Aa(t)&&Object.keys(t).length>0&&Nn(this,t),this.contentType=m(this.contentType)?"application/json; charset=utf-8":this.contentType}return n.prototype.send=function(t){var e=this,i={"application/json":"json","multipart/form-data":"formData","application/octet-stream":"blob","application/x-www-form-urlencoded":"formData"};try{m(this.fetchRequest)&&"GET"===this.type?this.fetchRequest=new Request(this.url,{method:this.type}):m(this.fetchRequest)&&(this.data=m(t)?this.data:t,this.fetchRequest=new Request(this.url,{method:this.type,headers:{"Content-Type":this.contentType},body:this.data}));var r={cancel:!1,fetchRequest:this.fetchRequest};return this.triggerEvent(this.beforeSend,r),r.cancel?null:(this.fetchResponse=fetch(this.fetchRequest),this.fetchResponse.then(function(s){if(e.triggerEvent(e.onLoad,s),!s.ok)throw s;for(var o="text",a=0,l=Object.keys(i);a-1},n.getValue=function(t,e){var i=typeof window<"u"?window.browserDetails:{};return typeof navigator<"u"&&"MacIntel"===navigator.platform&&navigator.maxTouchPoints>1&&!0===n.isTouch&&!fC.CHROME.test(navigator.userAgent)&&(i.isIos=!0,i.isDevice=!0,i.isTouch=!0,i.isPointer=!0),typeof window<"u"&&window.Capacitor&&"ios"===window.Capacitor.getPlatform()&&(i.isPointer=!1),typeof i[""+t]>"u"?i[""+t]=e.test(n.userAgent):i[""+t]},Object.defineProperty(n,"userAgent",{get:function(){return n.uA},set:function(t){n.uA=t,window.browserDetails={}},enumerable:!0,configurable:!0}),Object.defineProperty(n,"info",{get:function(){return st(window.browserDetails.info)?window.browserDetails.info=n.extractBrowserDetail():window.browserDetails.info},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isIE",{get:function(){return n.getValue("isIE",x$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isTouch",{get:function(){return st(window.browserDetails.isTouch)?window.browserDetails.isTouch="ontouchstart"in window.navigator||window&&window.navigator&&window.navigator.maxTouchPoints>0||"ontouchstart"in window:window.browserDetails.isTouch},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isPointer",{get:function(){return st(window.browserDetails.isPointer)?window.browserDetails.isPointer="pointerEnabled"in window.navigator:window.browserDetails.isPointer},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isMSPointer",{get:function(){return st(window.browserDetails.isMSPointer)?window.browserDetails.isMSPointer="msPointerEnabled"in window.navigator:window.browserDetails.isMSPointer},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isDevice",{get:function(){return n.getValue("isDevice",D$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isIos",{get:function(){return n.getValue("isIos",A$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isIos7",{get:function(){return n.getValue("isIos7",L$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isAndroid",{get:function(){return n.getValue("isAndroid",N$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isWebView",{get:function(){return st(window.browserDetails.isWebView)&&(window.browserDetails.isWebView=!(st(window.cordova)&&st(window.PhoneGap)&&st(window.phonegap)&&"object"!==window.forge)),window.browserDetails.isWebView},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isWindows",{get:function(){return n.getValue("isWindows",O$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"touchStartEvent",{get:function(){return st(window.browserDetails.touchStartEvent)?window.browserDetails.touchStartEvent=n.getTouchStartEvent():window.browserDetails.touchStartEvent},enumerable:!0,configurable:!0}),Object.defineProperty(n,"touchMoveEvent",{get:function(){return st(window.browserDetails.touchMoveEvent)?window.browserDetails.touchMoveEvent=n.getTouchMoveEvent():window.browserDetails.touchMoveEvent},enumerable:!0,configurable:!0}),Object.defineProperty(n,"touchEndEvent",{get:function(){return st(window.browserDetails.touchEndEvent)?window.browserDetails.touchEndEvent=n.getTouchEndEvent():window.browserDetails.touchEndEvent},enumerable:!0,configurable:!0}),Object.defineProperty(n,"touchCancelEvent",{get:function(){return st(window.browserDetails.touchCancelEvent)?window.browserDetails.touchCancelEvent=n.getTouchCancelEvent():window.browserDetails.touchCancelEvent},enumerable:!0,configurable:!0}),n.uA=typeof navigator<"u"?navigator.userAgent:"",n}(),E=function(){function n(){}return n.addOrGetEventData=function(t){return"__eventList"in t?t.__eventList.events:(t.__eventList={},t.__eventList.events=[])},n.add=function(t,e,i,r,s){var a,o=n.addOrGetEventData(t);a=s?function o$(n,t){var e;return function(){for(var i=this,r=[],s=0;s"u"||(e.innerHTML=t.innerHTML?t.innerHTML:"",void 0!==t.className&&(e.className=t.className),void 0!==t.id&&(e.id=t.id),void 0!==t.styles&&e.setAttribute("style",t.styles),void 0!==t.attrs&&Fe(e,t.attrs)),e}function V(n,t){for(var e=Vz(t),i=RegExp,r=0,s=n;r0}function pl(n,t,e){for(var i=document.createDocumentFragment(),r=0,s=n;r0;)i.appendChild(n[0]);else for(var r=0,s=n;r-1&&!r[parseInt(s.toString(),10)].match(/\[.*\]/)){var o=r[parseInt(s.toString(),10)].split("#");if(o[1].match(/^\d/)||o[1].match(t)){var a=r[parseInt(s.toString(),10)].split(".");a[0]=a[0].replace(/#/,"[id='")+"']",r[parseInt(s.toString(),10)]=a.join(".")}}e[parseInt(i.toString(),10)]=r.join(" ")}return e.join(",")}return n}function J(n,t){var e=n;if("function"==typeof e.closest)return e.closest(t);for(;e&&1===e.nodeType;){if(gC(e,t))return e;e=e.parentNode}return null}function je(n,t){void 0!==t&&Object.keys(t).forEach(function(e){n.style[""+e]=t[""+e]})}function gC(n,t){var e=n.matches||n.msMatchesSelector||n.webkitMatchesSelector;return e?e.call(n,t):-1!==[].indexOf.call(document.querySelectorAll(t),n)}var z$=new RegExp("]"),ah=function(){function n(t,e){this.isRendered=!1,this.isComplexArraySetter=!1,this.isServerRendered=!1,this.allowServerDataBinding=!0,this.isProtectedOnChange=!0,this.properties={},this.changedProperties={},this.oldProperties={},this.bulkChanges={},this.refreshing=!1,this.ignoreCollectionWatch=!1,this.finalUpdate=function(){},this.childChangedProperties={},this.modelObserver=new Tg(this),st(e)||(this.element="string"==typeof e?document.querySelector(e):e,m(this.element)||(this.isProtectedOnChange=!1,this.addInstance())),st(t)||this.setProperties(t,!0),this.isDestroyed=!1}return n.prototype.setProperties=function(t,e){var i=this.isProtectedOnChange;this.isProtectedOnChange=!!e,Nn(this,t),!0!==e?(Nn(this.changedProperties,t),this.dataBind()):ce()&&this.isRendered&&this.serverDataBind(t),this.finalUpdate(),this.changedProperties={},this.oldProperties={},this.isProtectedOnChange=i},n.callChildDataBind=function(t,e){for(var r=0,s=Object.keys(t);r=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Hs=function(n){function t(i){var r=n.call(this,i,void 0)||this;return r.easing={ease:"cubic-bezier(0.250, 0.100, 0.250, 1.000)",linear:"cubic-bezier(0.250, 0.250, 0.750, 0.750)",easeIn:"cubic-bezier(0.420, 0.000, 1.000, 1.000)",easeOut:"cubic-bezier(0.000, 0.000, 0.580, 1.000)",easeInOut:"cubic-bezier(0.420, 0.000, 0.580, 1.000)",elasticInOut:"cubic-bezier(0.5,-0.58,0.38,1.81)",elasticIn:"cubic-bezier(0.17,0.67,0.59,1.81)",elasticOut:"cubic-bezier(0.7,-0.75,0.99,1.01)"},r}var e;return Q$(t,n),e=t,t.prototype.animate=function(i,r){var s=this.getModel(r=r||{});if("string"==typeof i)for(var a=0,l=Array.prototype.slice.call(we(i,document));a0?r-1:0,i+=e=-1!==e?"-"+e:"-"+r}return this.controlParent!==this.parentObj&&(i=this.parentObj.getParentKey()+"."+this.propName+e),i},n}(),$$=["grid","pivotview","treegrid","spreadsheet","rangeNavigator","DocumentEditor","listbox","inplaceeditor","PdfViewer","richtexteditor","DashboardLayout","chart","stockChart","circulargauge","diagram","heatmap","lineargauge","maps","slider","smithchart","barcode","sparkline","treemap","bulletChart","kanban","daterangepicker","schedule","gantt","signature","query-builder","drop-down-tree","carousel","filemanager","uploader","accordion","tab","treeview"],tR=[115,121,110,99,102,117,115,105,111,110,46,105,115,76,105,99,86,97,108,105,100,97,116,101,100],iR=function(){function n(t){this.isValidated=!1,this.isLicensed=!0,this.version="27",this.platform=/JavaScript|ASPNET|ASPNETCORE|ASPNETMVC|FileFormats|essentialstudio/i,this.errors={noLicense:"This application was built using a trial version of Syncfusion Essential Studio. To remove the license validation message permanently, a valid license key must be included.",trailExpired:"This application was built using a trial version of Syncfusion Essential Studio. To remove the license validation message permanently, a valid license key must be included.",versionMismatched:"The included Syncfusion license key is invalid.",platformMismatched:"The included Syncfusion license key is invalid.",invalidKey:"The included Syncfusion license key is invalid."},this.manager=function(){var e=null;return{setKey:function i(s){e=s},getKey:function r(){return e}}}(),this.npxManager=function(){return{getKey:function i(){return"npxKeyReplace"}}}(),this.manager.setKey(t)}return n.prototype.validate=function(){if(!this.isValidated&&Ku&&!Y(E0(tR),Ku)&&!Y("Blazor",Ku)){var i=void 0,r=void 0;if(this.manager&&this.manager.getKey()||this.npxManager&&"npxKeyReplace"!==this.npxManager.getKey()){var s=this.getInfoFromKey();if(s&&s.length)for(var o=0,a=s;o"+i+' Claim your FREE account\n
have a Syncfusion account? Sign In
\n
\n ';if(typeof document<"u"&&!m(document)){var t=mi("div",{innerHTML:n});document.body.appendChild(t)}}(),oR=!0),this.render(),this.mount?this.accessMount():this.trigger("created")}},t.prototype.renderComplete=function(e){ce()&&window.sfBlazor.renderComplete(this.element,e),this.isRendered=!0},t.prototype.dataBind=function(){this.injectModules(),n.prototype.dataBind.call(this)},t.prototype.on=function(e,i,r){if("string"==typeof e)this.localObserver.on(e,i,r);else for(var s=0,o=e;s=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},tZ={left:0,top:0,bottom:0,right:0},IC={isDragged:!1},iZ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return aR(t,n),gr([I(0)],t.prototype,"left",void 0),gr([I(0)],t.prototype,"top",void 0),t}(Ee),np=function(n){function t(i,r){var s=n.call(this,r,i)||this;return s.dragLimit=e.getDefaultPosition(),s.borderWidth=e.getDefaultPosition(),s.padding=e.getDefaultPosition(),s.diffX=0,s.prevLeft=0,s.prevTop=0,s.dragProcessStarted=!1,s.eleTop=0,s.tapHoldTimer=0,s.externalInitialize=!1,s.diffY=0,s.parentScrollX=0,s.parentScrollY=0,s.droppables={},s.bind(),s}var e;return aR(t,n),e=t,t.prototype.bind=function(){this.toggleEvents(),X.isIE&&V([this.element],"e-block-touch"),this.droppables[this.scope]={}},t.getDefaultPosition=function(){return ze({},tZ)},t.prototype.toggleEvents=function(i){var r;st(this.handle)||(r=U(this.handle,this.element));var s=this.enableTapHold&&X.isDevice&&X.isTouch?this.mobileInitialize:this.initialize;i?E.remove(r||this.element,X.isSafari()?"touchstart":X.touchStartEvent,s):E.add(r||this.element,X.isSafari()?"touchstart":X.touchStartEvent,s,this)},t.prototype.mobileInitialize=function(i){var r=this,s=i.currentTarget;this.tapHoldTimer=setTimeout(function(){r.externalInitialize=!0,r.removeTapholdTimer(),r.initialize(i,s)},this.tapHoldThreshold),E.add(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.removeTapholdTimer,this),E.add(document,X.isSafari()?"touchend":X.touchEndEvent,this.removeTapholdTimer,this)},t.prototype.removeTapholdTimer=function(){clearTimeout(this.tapHoldTimer),E.remove(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.removeTapholdTimer),E.remove(document,X.isSafari()?"touchend":X.touchEndEvent,this.removeTapholdTimer)},t.prototype.getScrollableParent=function(i,r){return m(i)?null:i[{vertical:"scrollHeight",horizontal:"scrollWidth"}[""+r]]>i[{vertical:"clientHeight",horizontal:"clientWidth"}[""+r]]&&("vertical"===r?i.scrollTop>0:i.scrollLeft>0)?("vertical"===r?(this.parentScrollY=this.parentScrollY+(0===this.parentScrollY?i.scrollTop:i.scrollTop-this.parentScrollY),this.tempScrollHeight=i.scrollHeight):(this.parentScrollX=this.parentScrollX+(0===this.parentScrollX?i.scrollLeft:i.scrollLeft-this.parentScrollX),this.tempScrollWidth=i.scrollWidth),m(i)?i:this.getScrollableParent(i.parentNode,r)):this.getScrollableParent(i.parentNode,r)},t.prototype.getScrollableValues=function(){this.parentScrollX=0,this.parentScrollY=0,this.element.classList.contains("e-dialog")&&this.element.classList.contains("e-dlg-modal"),this.getScrollableParent(this.element.parentNode,"vertical"),this.getScrollableParent(this.element.parentNode,"horizontal")},t.prototype.initialize=function(i,r){if(this.currentStateTarget=i.target,!this.isDragStarted()){if(this.isDragStarted(!0),this.externalInitialize=!1,this.target=i.currentTarget||r,this.dragProcessStarted=!1,this.abort){var s=this.abort;"string"==typeof s&&(s=[s]);for(var o=0;o=this.distance||this.externalInitialize){var p=this.getHelperElement(i);if(!p||m(p))return;r&&i.preventDefault();var f=this.helperElement=p;if(this.parentClientRect=this.calculateParentPosition(f.offsetParent),this.dragStart){var v={event:i,element:l,target:this.getProperTargetElement(i),bindEvents:ce()?this.bindDragEvents.bind(this):null,dragElement:f};this.trigger("dragStart",v)}this.dragArea?this.setDragArea():(this.dragLimit={left:0,right:0,bottom:0,top:0},this.borderWidth={top:0,left:0}),o={left:this.position.left-this.parentClientRect.left,top:this.position.top-this.parentClientRect.top},this.clone&&!this.enableTailMode&&(this.diffX=this.position.left-this.offset.left,this.diffY=this.position.top-this.offset.top),this.getScrollableValues();var y=getComputedStyle(l),S=parseFloat(y.marginTop);this.clone&&0!==S&&(o.top+=S),this.eleTop=isNaN(parseFloat(y.top))?0:parseFloat(y.top)-this.offset.top,this.enableScrollHandler&&!this.clone&&(o.top-=this.parentScrollY,o.left-=this.parentScrollX);var b=this.getProcessedPositionValue({top:o.top-this.diffY+"px",left:o.left-this.diffX+"px"});this.dragArea&&"string"!=typeof this.dragArea&&this.dragArea.classList.contains("e-kanban-content")&&"relative"===this.dragArea.style.position&&(o.top+=this.dragArea.scrollTop),this.dragElePosition={top:o.top,left:o.left},je(f,this.getDragPosition({position:"absolute",left:b.left,top:b.top})),E.remove(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.intDragStart),E.remove(document,X.isSafari()?"touchend":X.touchEndEvent,this.intDestroy),ce()||this.bindDragEvents(f)}}},t.prototype.bindDragEvents=function(i){Tr(i)?(E.add(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.intDrag,this),E.add(document,X.isSafari()?"touchend":X.touchEndEvent,this.intDragStop,this),this.setGlobalDroppables(!1,this.element,i)):(this.toggleEvents(),document.body.classList.remove("e-prevent-select"))},t.prototype.elementInViewport=function(i){for(this.top=i.offsetTop,this.left=i.offsetLeft,this.width=i.offsetWidth,this.height=i.offsetHeight;i.offsetParent;)this.top+=(i=i.offsetParent).offsetTop,this.left+=i.offsetLeft;return this.top>=window.pageYOffset&&this.left>=window.pageXOffset&&this.top+this.height<=window.pageYOffset+window.innerHeight&&this.left+this.width<=window.pageXOffset+window.innerWidth},t.prototype.getProcessedPositionValue=function(i){return this.queryPositionInfo?this.queryPositionInfo(i):i},t.prototype.calculateParentPosition=function(i){if(m(i))return{left:0,top:0};var r=i.getBoundingClientRect(),s=getComputedStyle(i);return{left:r.left+window.pageXOffset-parseInt(s.marginLeft,10),top:r.top+window.pageYOffset-parseInt(s.marginTop,10)}},t.prototype.intDrag=function(i){if(st(i.changedTouches)||1===i.changedTouches.length){var r,s;this.clone&&i.changedTouches&&X.isDevice&&X.isTouch&&i.preventDefault(),this.position=this.getMousePosition(i,this.isDragScroll);var o=this.getDocumentWidthHeight("Height");oy&&y>0?this.dragLimit.left:this.dragLimit.right+window.pageXOffset0?y-(y-this.dragLimit.right)+window.pageXOffset-M:y<0?this.dragLimit.left:y}if(this.pageY!==v||this.skipDistanceCheck){var w=d.offsetHeight+(parseFloat(b.marginTop)+parseFloat(b.marginBottom));s=this.dragLimit.top>S&&S>0?this.dragLimit.top:this.dragLimit.bottom+window.pageYOffset0?S-(S-this.dragLimit.bottom)+window.pageYOffset-w:S<0?this.dragLimit.top:S}}else r=y,s=S;var A,x,C=p+this.borderWidth.top,D=u+this.borderWidth.left;if(this.dragProcessStarted&&(m(s)&&(s=this.prevTop),m(r)&&(r=this.prevLeft)),this.helperElement.classList.contains("e-treeview"))this.dragArea?(this.dragLimit.top=this.clone?this.dragLimit.top:0,A=s-C<0?this.dragLimit.top:s-this.borderWidth.top,x=r-D<0?this.dragLimit.left:r-this.borderWidth.left):(A=s-this.borderWidth.top,x=r-this.borderWidth.left);else if(this.dragArea){var R=this.helperElement.classList.contains("e-dialog");this.dragLimit.top=this.clone?this.dragLimit.top:0,A=s-C<0?this.dragLimit.top:s-C,x=r-D<0?R?r-(D-this.borderWidth.left):this.dragElePosition.left:r-D}else A=s-C,x=r-D;var L=parseFloat(getComputedStyle(this.element).marginTop);if(L>0&&(this.clone&&(A+=L,S<0&&(L+S>=0?A=L+S:A-=L),this.dragArea&&(A=this.dragLimit.bottom=0){var O=this.dragLimit.top+S-C;O+L+C<0?A-=L+C:A=O}else A-=L+C;this.dragArea&&this.helperElement.classList.contains("e-treeview")&&(A=A+(w=d.offsetHeight+(parseFloat(b.marginTop)+parseFloat(b.marginBottom)))>this.dragLimit.bottom?this.dragLimit.bottom-w:A),this.enableScrollHandler&&!this.clone&&(A-=this.parentScrollY,x-=this.parentScrollX),this.dragArea&&"string"!=typeof this.dragArea&&this.dragArea.classList.contains("e-kanban-content")&&"relative"===this.dragArea.style.position&&(A+=this.dragArea.scrollTop);var N=this.getProcessedPositionValue({top:A+"px",left:x+"px"});this.isPreventScroll&&(N=this.getProcessedPositionValue({top:this.position.top-this.parentClientRect.top-2+"px",left:this.position.left-this.parentClientRect.left-2+"px"})),je(d,this.getDragPosition(N)),!this.elementInViewport(d)&&this.enableAutoScroll&&!this.helperElement.classList.contains("e-treeview")&&this.helperElement.scrollIntoView();var T=document.querySelectorAll(":hover");if(this.enableAutoScroll&&this.helperElement.classList.contains("e-treeview")){0===T.length&&(T=this.getPathElements(i));var P=this.getScrollParent(T,!1);this.elementInViewport(this.helperElement)?this.getScrollPosition(P,A):this.elementInViewport(this.helperElement)||(0===(T=[].slice.call(document.querySelectorAll(":hover"))).length&&(T=this.getPathElements(i)),P=this.getScrollParent(T,!0),this.getScrollPosition(P,A))}this.dragProcessStarted=!0,this.prevLeft=r,this.prevTop=s,this.position.left=r,this.position.top=s,this.pageX=g,this.pageY=v}},t.prototype.getScrollParent=function(i,r){for(var o,s=r?i.reverse():i,a=s.length-1;a>=0;a--)if(("auto"===(o=window.getComputedStyle(s[parseInt(a.toString(),10)])["overflow-y"])||"scroll"===o)&&s[parseInt(a.toString(),10)].scrollHeight>s[parseInt(a.toString(),10)].clientHeight)return s[parseInt(a.toString(),10)];if("visible"===(o=window.getComputedStyle(document.scrollingElement)["overflow-y"]))return document.scrollingElement.style.overflow="auto",document.scrollingElement},t.prototype.getScrollPosition=function(i,r){if(i&&i===document.scrollingElement)i.clientHeight+document.scrollingElement.scrollTop-this.helperElement.clientHeightr?i.scrollTop+=this.helperElement.clientHeight:i.scrollTop>r-this.helperElement.clientHeight&&(i.scrollTop-=this.helperElement.clientHeight);else if(i&&i!==document.scrollingElement){var s=document.scrollingElement.scrollTop,o=this.helperElement.clientHeight;i.clientHeight+i.getBoundingClientRect().top-o+sr-o-s&&(i.scrollTop-=this.helperElement.clientHeight)}},t.prototype.getPathElements=function(i){return document.elementsFromPoint(i.clientX>0?i.clientX:0,i.clientY>0?i.clientY:0)},t.prototype.triggerOutFunction=function(i,r){this.hoverObject.instance.intOut(i,r.target),this.hoverObject.instance.dragData[this.scope]=null,this.hoverObject=null},t.prototype.getDragPosition=function(i){var r=ze({},i);return this.axis&&("x"===this.axis?delete r.top:"y"===this.axis&&delete r.left),r},t.prototype.getDocumentWidthHeight=function(i){var r=document.body,s=document.documentElement;return Math.max(r["scroll"+i],s["scroll"+i],r["offset"+i],s["offset"+i],s["client"+i])},t.prototype.intDragStop=function(i){if(this.dragProcessStarted=!1,st(i.changedTouches)||1===i.changedTouches.length){if(-1!==["touchend","pointerup","mouseup"].indexOf(i.type)){if(this.dragStop){var s=this.getProperTargetElement(i);this.trigger("dragStop",{event:i,element:this.element,target:s,helper:this.helperElement})}this.intDestroy(i)}else this.element.setAttribute("aria-grabbed","false");var o=this.checkTargetElement(i);o.target&&o.instance&&(o.instance.dragStopCalled=!0,o.instance.dragData[this.scope]=this.droppables[this.scope],o.instance.intDrop(i,o.target)),this.setGlobalDroppables(!0),document.body.classList.remove("e-prevent-select")}},t.prototype.intDestroy=function(i){this.dragProcessStarted=!1,this.toggleEvents(),document.body.classList.remove("e-prevent-select"),this.element.setAttribute("aria-grabbed","false"),E.remove(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.intDragStart),E.remove(document,X.isSafari()?"touchend":X.touchEndEvent,this.intDragStop),E.remove(document,X.isSafari()?"touchend":X.touchEndEvent,this.intDestroy),E.remove(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.intDrag),this.isDragStarted()&&this.isDragStarted(!0)},t.prototype.onPropertyChanged=function(i,r){},t.prototype.getModuleName=function(){return"draggable"},t.prototype.isDragStarted=function(i){return i&&(IC.isDragged=!IC.isDragged),IC.isDragged},t.prototype.setDragArea=function(){var i,r,a,s=0,o=0;if(a="string"==typeof this.dragArea?U(this.dragArea):this.dragArea){var h=a.getBoundingClientRect();i=a.scrollWidth?a.scrollWidth:h.right-h.left,r=a.scrollHeight?this.dragArea&&!m(this.helperElement)&&this.helperElement.classList.contains("e-treeview")?a.clientHeight:a.scrollHeight:h.bottom-h.top;for(var c=["Top","Left","Bottom","Right"],d=getComputedStyle(a),u=0;u12;return b0(i.target,this.helperElement)||-1!==i.type.indexOf("touch")||a?(this.helperElement.style.pointerEvents="none",s=document.elementFromPoint(r.clientX,r.clientY),this.helperElement.style.pointerEvents=o):s=i.target,s},t.prototype.currentStateCheck=function(i,r){return m(this.currentStateTarget)||this.currentStateTarget===i?m(r)?i:r:this.currentStateTarget},t.prototype.getMousePosition=function(i,r){var a,l,s=void 0!==i.srcElement?i.srcElement:i.target,o=this.getCoordinates(i),h=m(s.offsetParent);if(r?(a=this.clone?o.pageX:o.pageX+(h?0:s.offsetParent.scrollLeft)-this.relativeXPosition,l=this.clone?o.pageY:o.pageY+(h?0:s.offsetParent.scrollTop)-this.relativeYPosition):(a=this.clone?o.pageX:o.pageX+window.pageXOffset-this.relativeXPosition,l=this.clone?o.pageY:o.pageY+window.pageYOffset-this.relativeYPosition),document.scrollingElement&&!r&&!this.clone){var c=document.scrollingElement;a=c.scrollWidth>0&&c.scrollWidth>c.clientWidth&&c.scrollLeft>0?a-c.scrollLeft:a,l=c.scrollHeight>0&&c.scrollHeight>c.clientHeight&&c.scrollTop>0?l-c.scrollTop:l}return{left:a-(this.margin.left+this.cursorAt.left),top:l-(this.margin.top+this.cursorAt.top)}},t.prototype.getCoordinates=function(i){return i.type.indexOf("touch")>-1?i.changedTouches[0]:i},t.prototype.getHelperElement=function(i){var r;return this.clone?this.helper?r=this.helper({sender:i,element:this.target}):(r=mi("div",{className:"e-drag-helper e-block-touch",innerHTML:"Draggable"}),document.body.appendChild(r)):r=this.element,r},t.prototype.setGlobalDroppables=function(i,r,s){this.droppables[this.scope]=i?null:{draggable:r,helper:s,draggedElement:this.element}},t.prototype.checkTargetElement=function(i){var r=this.getProperTargetElement(i),s=this.getDropInstance(r);if(!s&&r&&!m(r.parentNode)){var o=J(r.parentNode,".e-droppable")||r.parentElement;o&&(s=this.getDropInstance(o))}return{target:r,instance:s}},t.prototype.getDropInstance=function(i){var s,o=i&&i.ej2_instances;if(o)for(var a=0,l=o;a=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},lR=function(n){function t(e,i){var r=n.call(this,i,e)||this;return r.mouseOver=!1,r.dragData={},r.dragStopCalled=!1,r.bind(),r}return rZ(t,n),t.prototype.bind=function(){this.wireEvents()},t.prototype.wireEvents=function(){E.add(this.element,X.isSafari()?"touchend":X.touchEndEvent,this.intDrop,this)},t.prototype.onPropertyChanged=function(e,i){},t.prototype.getModuleName=function(){return"droppable"},t.prototype.intOver=function(e,i){this.mouseOver||(this.trigger("over",{event:e,target:i,dragData:this.dragData[this.scope]}),this.mouseOver=!0)},t.prototype.intOut=function(e,i){this.mouseOver&&(this.trigger("out",{evt:e,target:i}),this.mouseOver=!1)},t.prototype.intDrop=function(e,i){if(this.dragStopCalled){this.dragStopCalled=!1;var a,r=!0,s=this.dragData[this.scope],o=!!s&&s.helper&&Tr(s.helper);o&&(a=this.isDropArea(e,s.helper,i),this.accept&&(r=gC(s.helper,this.accept))),o&&this.drop&&a.canDrop&&r&&this.trigger("drop",{event:e,target:a.target,droppedElement:s.helper,dragData:s}),this.mouseOver=!1}},t.prototype.isDropArea=function(e,i,r){var s={canDrop:!0,target:r||e.target},o="touchend"===e.type;if(o||s.target===i){i.style.display="none";var a=o?e.changedTouches[0]:e,l=document.elementFromPoint(a.clientX,a.clientY);s.canDrop=!1,s.canDrop=b0(l,this.element),s.canDrop&&(s.target=l),i.style.display=""}return s},t.prototype.destroy=function(){E.remove(this.element,X.isSafari()?"touchend":X.touchEndEvent,this.intDrop),n.prototype.destroy.call(this)},sp([I()],t.prototype,"accept",void 0),sp([I("default")],t.prototype,"scope",void 0),sp([H()],t.prototype,"drop",void 0),sp([H()],t.prototype,"over",void 0),sp([H()],t.prototype,"out",void 0),sp([Ft],t)}(ah),ho=function(){function n(t,e,i){this.controlName=t,this.localeStrings=e,this.setLocale(i||"en-US")}return n.prototype.setLocale=function(t){var e=this.intGetControlConstant(n.locale,t);this.currentLocale=e||this.localeStrings},n.load=function(t){this.locale=ze(this.locale,t,{},!0)},n.prototype.getConstant=function(t){return m(this.currentLocale[""+t])?this.localeStrings[""+t]||"":this.currentLocale[""+t]},n.prototype.intGetControlConstant=function(t,e){return t[""+e]?t[""+e][this.controlName]:null},n.locale={},n}(),hR=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),hh=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},oZ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return hR(t,n),hh([I(50)],t.prototype,"swipeThresholdDistance",void 0),t}(Ee),aZ=/(Up|Down)/,Fs=function(n){function t(e,i){var r=n.call(this,i,e)||this;return r.touchAction=!0,r.tapCount=0,r.startEvent=function(s){if(!0===r.touchAction){var o=r.updateChangeTouches(s);void 0!==s.changedTouches&&(r.touchAction=!1),r.isTouchMoved=!1,r.movedDirection="",r.startPoint=r.lastMovedPoint={clientX:o.clientX,clientY:o.clientY},r.startEventData=o,r.hScrollLocked=r.vScrollLocked=!1,r.tStampStart=Date.now(),r.timeOutTapHold=setTimeout(function(){r.tapHoldEvent(s)},r.tapHoldThreshold),E.add(r.element,X.touchMoveEvent,r.moveEvent,r),E.add(r.element,X.touchEndEvent,r.endEvent,r),E.add(r.element,X.touchCancelEvent,r.cancelEvent,r)}},r.moveEvent=function(s){var o=r.updateChangeTouches(s);r.movedPoint=o,r.isTouchMoved=!(o.clientX===r.startPoint.clientX&&o.clientY===r.startPoint.clientY);var a={};r.isTouchMoved&&(clearTimeout(r.timeOutTapHold),r.calcScrollPoints(s),a=ze(a,{},{startEvents:r.startEventData,originalEvent:s,startX:r.startPoint.clientX,startY:r.startPoint.clientY,distanceX:r.distanceX,distanceY:r.distanceY,scrollDirection:r.scrollDirection,velocity:r.getVelocity(o)}),r.trigger("scroll",a),r.lastMovedPoint={clientX:o.clientX,clientY:o.clientY})},r.cancelEvent=function(s){clearTimeout(r.timeOutTapHold),clearTimeout(r.timeOutTap),r.tapCount=0,r.swipeFn(s),E.remove(r.element,X.touchCancelEvent,r.cancelEvent)},r.endEvent=function(s){r.swipeFn(s),r.isTouchMoved||"function"==typeof r.tap&&(r.trigger("tap",{originalEvent:s,tapCount:++r.tapCount}),r.timeOutTap=setTimeout(function(){r.tapCount=0},r.tapThreshold)),r.modeclear()},r.swipeFn=function(s){clearTimeout(r.timeOutTapHold),clearTimeout(r.timeOutTap);var o=r.updateChangeTouches(s),a=o.clientX-r.startPoint.clientX,l=o.clientY-r.startPoint.clientY;a=Math.floor(a<0?-1*a:a),l=Math.floor(l<0?-1*l:a),r.isTouchMoved=a>1||l>1,/Firefox/.test(X.userAgent)&&0===o.clientX&&0===o.clientY&&"mouseup"===s.type&&(r.isTouchMoved=!1),r.endPoint=o,r.calcPoints(s);var c={originalEvent:s,startEvents:r.startEventData,startX:r.startPoint.clientX,startY:r.startPoint.clientY,distanceX:r.distanceX,distanceY:r.distanceY,swipeDirection:r.movedDirection,velocity:r.getVelocity(o)};if(r.isTouchMoved){var d=r.swipeSettings.swipeThresholdDistance,u=ze(void 0,r.defaultArgs,c),p=!1,f=r.element,g=r.isScrollable(f),v=aZ.test(r.movedDirection);(dthis.distanceY?i.clientX>this.startPoint.clientX?"Right":"Left":i.clientYthis.distanceY||!0===this.hScrollLocked)&&!1===this.vScrollLocked?(this.scrollDirection=i.clientX>this.lastMovedPoint.clientX?"Right":"Left",this.hScrollLocked=!0):(this.scrollDirection=i.clientY=e[r[0]+s[0]]},t.prototype.updateChangeTouches=function(e){return e.changedTouches&&0!==e.changedTouches.length?e.changedTouches[0]:e},hh([H()],t.prototype,"tap",void 0),hh([H()],t.prototype,"tapHold",void 0),hh([H()],t.prototype,"swipe",void 0),hh([H()],t.prototype,"scroll",void 0),hh([I(350)],t.prototype,"tapThreshold",void 0),hh([I(750)],t.prototype,"tapHoldThreshold",void 0),hh([re({},oZ)],t.prototype,"swipeSettings",void 0),hh([Ft],t)}(ah),lZ=new RegExp("\\n|\\r|\\s\\s+","g"),hZ=new RegExp(/'|"/g),cZ=new RegExp("if ?\\("),dZ=new RegExp("else if ?\\("),cR=new RegExp("else"),uZ=new RegExp("for ?\\("),dR=new RegExp("(/if|/for)"),pZ=new RegExp("\\((.*)\\)",""),bC=new RegExp("^[0-9]+$","g"),fZ=new RegExp("[\\w\"'.\\s+]+","g"),gZ=new RegExp('"(.*?)"',"g"),vZ=new RegExp("[\\w\"'@#$.\\s-+]+","g"),uR=new RegExp("\\${([^}]*)}","g"),mZ=/^\..*/gm,MC=/\\/gi,yZ=/\\\\/gi,SZ=new RegExp("[\\w\"'@#$.\\s+]+","g"),IZ=/\window\./gm;function op(n,t,e,i,r){return!t||bC.test(n)||-1!==i.indexOf(n.split(".")[0])||r||"true"===n||"false"===n?n:e+"."+n}function wC(n,t,e,i){return t&&!bC.test(n)&&-1===i.indexOf(n.split(".")[0])?e+'["'+n:n}function pR(n){return n.match(yZ)?n:n.replace(MC,"\\\\")}function fR(n,t,e,i){if(n=n.trim(),/\window\./gm.test(n))return n;var s=/'|"/gm;return/@|\$|#/gm.test(n)&&(n=wC(n,-1===e.indexOf(n),t,e)+'"]'),mZ.test(n)?function wZ(n,t,e,i){return!t||bC.test(n)||-1!==i.indexOf(n.split(".")[0])||/^\..*/gm.test(n)?n:e+"."+n}(n,!s.test(n)&&-1===e.indexOf(n),t,e):op(n,!s.test(n)&&-1===e.indexOf(n),t,e,i)}var CZ=/^[\n\r.]+0&&t.forEach(function(e){he(e)})},n.removeJsEvents=function(){var t=this.wrapElement.querySelectorAll("["+vR.join("],[")+"]");t.length>0&&t.forEach(function(e){vR.forEach(function(i){e.hasAttribute(i)&&e.removeAttribute(i)})})},n.removeXssAttrs=function(){var t=this;this.removeAttrs.forEach(function(e,i){var r=t.wrapElement.querySelectorAll(e.selector);r.length>0&&r.forEach("a[href]"===e.selector?function(s){-1!==s.getAttribute(e.attribute).replace(/\t|\s|&/,"").indexOf("javascript:alert")&&s.removeAttribute(e.attribute)}:function(s){s.removeAttribute(e.attribute)})})},n}();function NZ(n){for(var t,e=n.childNodes,i=0;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Jo_RTL=(new Tg,"e-rtl"),ys=function(n){function t(e,i){return n.call(this,e,i)||this}return PZ(t,n),t.prototype.preRender=function(){},t.prototype.render=function(){this.initialize(),this.removeRippleEffect=function ms(n,t,e){var i=function G$(n){return{selector:n&&n.selector?n.selector:null,ignore:n&&n.ignore?n.ignore:null,rippleFlag:n&&n.rippleFlag,isCenterRipple:n&&n.isCenterRipple,duration:n&&n.duration?n.duration:350}}(t);return!1===i.rippleFlag||void 0===i.rippleFlag&&!Zo?function(){}:(n.setAttribute("data-ripple","true"),E.add(n,"mousedown",Zz,{parent:n,rippleOptions:i}),E.add(n,"mouseup",Jz,{parent:n,rippleOptions:i,done:e}),E.add(n,"mouseleave",rp,{parent:n,rippleOptions:i}),X.isPointer&&E.add(n,"transitionend",rp,{parent:n,rippleOptions:i}),function(){n.removeAttribute("data-ripple"),E.remove(n,"mousedown",Zz),E.remove(n,"mouseup",Jz),E.remove(n,"mouseleave",rp),E.remove(n,"transitionend",rp)})}(this.element,{selector:".e-btn"}),this.renderComplete()},t.prototype.initialize=function(){if(this.cssClass&&V([this.element],this.cssClass.replace(/\s+/g," ").trim().split(" ")),this.isPrimary&&this.element.classList.add("e-primary"),!ce()||ce()&&"progress-btn"!==this.getModuleName()){if(this.content){var e=this.enableHtmlSanitizer?Ti.sanitize(this.content):this.content;this.element.innerHTML=e}this.setIconCss()}this.enableRtl&&this.element.classList.add(Jo_RTL),this.disabled?this.controlStatus(this.disabled):this.wireEvents()},t.prototype.controlStatus=function(e){this.element.disabled=e},t.prototype.setIconCss=function(){if(this.iconCss){var e=this.createElement("span",{className:"e-btn-icon "+this.iconCss});this.element.textContent.trim()?(e.classList.add("e-icon-"+this.iconPosition.toLowerCase()),("Top"===this.iconPosition||"Bottom"===this.iconPosition)&&this.element.classList.add("e-"+this.iconPosition.toLowerCase()+"-icon-btn")):this.element.classList.add("e-icon-btn");var i=this.element.childNodes[0];!i||"Left"!==this.iconPosition&&"Top"!==this.iconPosition?this.element.appendChild(e):this.element.insertBefore(e,i)}},t.prototype.wireEvents=function(){this.isToggle&&E.add(this.element,"click",this.btnClickHandler,this)},t.prototype.unWireEvents=function(){this.isToggle&&E.remove(this.element,"click",this.btnClickHandler)},t.prototype.btnClickHandler=function(){this.element.classList.contains("e-active")?this.element.classList.remove("e-active"):this.element.classList.add("e-active")},t.prototype.destroy=function(){var e=["e-primary",Jo_RTL,"e-icon-btn","e-success","e-info","e-danger","e-warning","e-flat","e-outline","e-small","e-bigger","e-active","e-round","e-top-icon-btn","e-bottom-icon-btn"];this.cssClass&&(e=e.concat(this.cssClass.split(" "))),n.prototype.destroy.call(this),K([this.element],e),this.element.getAttribute("class")||this.element.removeAttribute("class"),this.disabled&&this.element.removeAttribute("disabled"),this.content&&(this.element.innerHTML=this.element.innerHTML.replace(this.content,""));var i=this.element.querySelector("span.e-btn-icon");i&&he(i),this.unWireEvents(),Zo&&this.removeRippleEffect()},t.prototype.getModuleName=function(){return"btn"},t.prototype.getPersistData=function(){return this.addOnPersist([])},t.Inject=function(){},t.prototype.onPropertyChanged=function(e,i){for(var r=this.element.querySelector("span.e-btn-icon"),s=0,o=Object.keys(e);s=ad.width?ad.width:0;return vl.right+QR()-n}function lE(){return R0()+vl.width/2}function hE(n,t,e,i){if(void 0===t&&(t=null),void 0===e&&(e={X:!1,Y:!1}),!e.Y&&!e.X)return{left:0,top:0};var r=n.getBoundingClientRect();if(uo=t,sc=n.ownerDocument,i||(i=is(n,"left","top")),e.X){var s=uo?ZR():i4(),o=fE(),a=gE(),l=o-i.left,h=i.left+r.width-a;r.width>s?i.left=l>0&&h<=0?a-r.width:h>0&&l<=0?o:l>h?a-r.width:o:l>0?i.left+=l:h>0&&(i.left-=h)}if(e.Y){var c=uo?JR():t4(),d=pE(),u=vE(),p=d-i.top,f=i.top+r.height-u;r.height>c?i.top=p>0&&f<=0?u-r.height:f>0&&p<=0?d:p>f?u-r.height:d:p>0?i.top+=p:f>0&&(i.top-=f)}return i}function oc(n,t,e,i){void 0===t&&(t=null);var r=is(n,"left","top");e&&(r.left=e),i&&(r.top=i);var s=[];uo=t,sc=n.ownerDocument;var o=n.getBoundingClientRect(),l=r.left,h=r.left+o.width,d=uE(r.top,r.top+o.height),u=XR(l,h);return d.topSide&&s.push("top"),u.rightSide&&s.push("right"),u.leftSide&&s.push("left"),d.bottomSide&&s.push("bottom"),s}function cJ(n,t,e,i,r,s,o,a,l){if(void 0===o&&(o=null),void 0===a&&(a={X:!0,Y:!0}),t&&n&&r&&s&&(a.X||a.Y)){var d,h={TL:null,TR:null,BL:null,BR:null},c={TL:null,TR:null,BL:null,BR:null};if("none"===window.getComputedStyle(n).display){var u=n.style.visibility;n.style.visibility="hidden",n.style.display="block",d=n.getBoundingClientRect(),n.style.removeProperty("display"),n.style.visibility=u}else d=n.getBoundingClientRect();var p={posX:r,posY:s,offsetX:e,offsetY:i,position:{left:0,top:0}};uo=o,sc=t.ownerDocument,function uJ(n,t,e,i,r){e.position=is(n,e.posX,e.posY,i,r),t.TL=is(n,"left","top",i,r),t.TR=is(n,"right","top",i,r),t.BR=is(n,"left","bottom",i,r),t.BL=is(n,"right","bottom",i,r)}(t,h,p,l,d),dE(c,p,d),a.X&&qR(t,c,h,p,d,!0),a.Y&&h.TL.top>-1&&$R(t,c,h,p,d,!0),function dJ(n,t,e){var i=0,r=0;if(null!=n.offsetParent&&("absolute"===getComputedStyle(n.offsetParent).position||"relative"===getComputedStyle(n.offsetParent).position)){var s=is(n.offsetParent,"left","top",!1,e);i=s.left,r=s.top}var o=1,a=1,l=GR(n);if(l){var h=getComputedStyle(l).transform;if("none"!==h){var c=new DOMMatrix(h);o=c.a,a=c.d}if("none"!==getComputedStyle(l).zoom){var u=cE(document.body);o*=u,a*=u}}n.style.top=t.position.top/a+t.offsetY-r/a+"px",n.style.left=t.position.left/o+t.offsetX-i/o+"px"}(n,p,d)}}function cE(n){var t=getComputedStyle(n).zoom;return parseFloat(t)||1}function GR(n){for(;n;){var t=window.getComputedStyle(n).transform,e=cE(document.body);if(t&&"none"!==t||e&&1!==e)return n;if(n===document.body)return null;n=n.offsetParent||n.parentElement}return null}function dE(n,t,e){n.TL={top:t.position.top+t.offsetY,left:t.position.left+t.offsetX},n.TR={top:n.TL.top,left:n.TL.left+e.width},n.BL={top:n.TL.top+e.height,left:n.TL.left},n.BR={top:n.TL.top+e.height,left:n.TL.left+e.width}}function XR(n,t){var e=!1,i=!1;return n-B0()gE()&&(i=!0),{leftSide:e,rightSide:i}}function qR(n,t,e,i,r,s){var o=XR(t.TL.left,t.TR.left),a=uE(t.TL.top,t.BL.top);e.TL.left-B0()<=fE()&&(o.leftSide=!1),e.TR.left>gE()&&(o.rightSide=!1),(o.leftSide&&!o.rightSide||!o.leftSide&&o.rightSide)&&(i.posX="right"===i.posX?"left":"right",i.offsetX=i.offsetX+r.width,i.offsetX=-1*i.offsetX,i.position=is(n,i.posX,i.posY,!1),dE(t,i,r),s&&qR(n,t,e,i,r,!1),!o.leftSide&&o.rightSide&&a.bottomSide&&(i.offsetX=0))}function $R(n,t,e,i,r,s){var o=uE(t.TL.top,t.BL.top);e.TL.top-H0()<=pE()&&(o.topSide=!1),e.BL.top>=vE()&&n.getBoundingClientRect().bottomvE()&&(i=!0),{topSide:e,bottomSide:i}}function ZR(){return uo.getBoundingClientRect().width}function JR(){return uo.getBoundingClientRect().height}function KR(){return uo.getBoundingClientRect().left}function e4(){return uo.getBoundingClientRect().top}function pE(){return uo?e4():0}function fE(){return uo?KR():0}function gE(){return uo?B0()+KR()+ZR():B0()+i4()}function vE(){return uo?H0()+e4()+JR():H0()+t4()}function H0(){return sc.documentElement.scrollTop||sc.body.scrollTop}function B0(){return sc.documentElement.scrollLeft||sc.body.scrollLeft}function t4(){return window.innerHeight}function i4(){var n=window.innerWidth,t=document.documentElement.getBoundingClientRect();return n-(n-(m(document.documentElement)?0:t.width))}function r4(){uo=null,sc=null}var n4=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),bn=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},s4=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return n4(t,n),bn([I("left")],t.prototype,"X",void 0),bn([I("top")],t.prototype,"Y",void 0),t}(Ee),Gn_OPEN="e-popup-open",Gn_CLOSE="e-popup-close",ac=function(n){function t(e,i){return n.call(this,i,e)||this}return n4(t,n),t.prototype.onPropertyChanged=function(e,i){for(var r=0,s=Object.keys(e);r0&&c.left>0&&c.right>0&&c.bottom>0}var s=i.getBoundingClientRect();return!(r.bottoms.bottom||r.right>s.right||r.leftr.top?this.element.style.top="0px":s.bottomr.left&&(this.element.style.left=parseInt(this.element.style.left,10)+(s.left-r.left)+"px"))}},t.prototype.checkCollision=function(){var e=this.collision.X,i=this.collision.Y;"none"===e&&"none"===i||("flip"===e&&"flip"===i?this.callFlip({X:!0,Y:!0}):"fit"===e&&"fit"===i?this.callFit({X:!0,Y:!0}):("flip"===e?this.callFlip({X:!0,Y:!1}):"flip"===i&&this.callFlip({Y:!0,X:!1}),"fit"===e?this.callFit({X:!0,Y:!1}):"fit"===i&&this.callFit({X:!1,Y:!0})))},t.prototype.show=function(e,i){var r=this;if(this.getRelateToElement().classList.contains("e-filemanager")&&(this.fmDialogContainer=this.element.getElementsByClassName("e-file-select-wrap")[0]),this.wireEvents(),!m(this.fmDialogContainer)&&X.isIos&&(this.fmDialogContainer.style.display="block"),1e3===this.zIndex||!m(i)){var o=m(i)?this.element:i;this.zIndex=lc(o),je(this.element,{zIndex:this.zIndex})}e=m(e)||"object"!=typeof e?this.showAnimation:e,("none"!==this.collision.X||"none"!==this.collision.Y)&&(K([this.element],Gn_CLOSE),V([this.element],Gn_OPEN),this.checkCollision(),K([this.element],Gn_OPEN),V([this.element],Gn_CLOSE)),m(e)?(K([this.element],Gn_CLOSE),V([this.element],Gn_OPEN),this.trigger("open")):(e.begin=function(){r.isDestroyed||(K([r.element],Gn_CLOSE),V([r.element],Gn_OPEN))},e.end=function(){r.isDestroyed||r.trigger("open")},new Hs(e).animate(this.element))},t.prototype.hide=function(e){var i=this;e=m(e)||"object"!=typeof e?this.hideAnimation:e,m(e)?(K([this.element],Gn_OPEN),V([this.element],Gn_CLOSE),this.trigger("close")):(e.end=function(){i.isDestroyed||(K([i.element],Gn_OPEN),V([i.element],Gn_CLOSE),i.trigger("close"))},new Hs(e).animate(this.element)),this.unwireEvents()},t.prototype.getScrollableParent=function(e){return this.checkFixedParent(e),function mE(n,t){for(var e=getComputedStyle(n),i=[],r=/(auto|scroll)/,s=n.parentElement;s&&"HTML"!==s.tagName;){var o=getComputedStyle(s);!("absolute"===e.position&&"static"===o.position)&&r.test(o.overflow+o.overflowY+o.overflowX)&&i.push(s),s=s.parentElement}return t||i.push(document),i}(e,this.fixedParent)},t.prototype.checkFixedParent=function(e){for(var i=e.parentElement;i&&"HTML"!==i.tagName;){var r=getComputedStyle(i);("fixed"===r.position||"sticky"===r.position)&&!m(this.element)&&this.element.offsetParent&&"BODY"===this.element.offsetParent.tagName&&"hidden"!==getComputedStyle(this.element.offsetParent).overflow&&(this.element.style.top=window.scrollY>parseInt(this.element.style.top,10)?Re(window.scrollY-parseInt(this.element.style.top,10)):Re(parseInt(this.element.style.top,10)-window.scrollY),this.element.style.position="fixed",this.fixedParent=!0),i=i.parentElement,!m(this.element)&&m(this.element.offsetParent)&&"fixed"===r.position&&"fixed"===this.element.style.position&&(this.fixedParent=!0)}},bn([I("auto")],t.prototype,"height",void 0),bn([I("auto")],t.prototype,"width",void 0),bn([I(null)],t.prototype,"content",void 0),bn([I("container")],t.prototype,"targetType",void 0),bn([I(null)],t.prototype,"viewPortElement",void 0),bn([I({X:"none",Y:"none"})],t.prototype,"collision",void 0),bn([I("")],t.prototype,"relateTo",void 0),bn([re({},s4)],t.prototype,"position",void 0),bn([I(0)],t.prototype,"offsetX",void 0),bn([I(0)],t.prototype,"offsetY",void 0),bn([I(1e3)],t.prototype,"zIndex",void 0),bn([I(!1)],t.prototype,"enableRtl",void 0),bn([I("reposition")],t.prototype,"actionOnScroll",void 0),bn([I(null)],t.prototype,"showAnimation",void 0),bn([I(null)],t.prototype,"hideAnimation",void 0),bn([H()],t.prototype,"open",void 0),bn([H()],t.prototype,"close",void 0),bn([H()],t.prototype,"targetExitViewport",void 0),bn([Ft],t)}(yi);function lc(n){for(var t=n.parentElement,e=[];t&&"BODY"!==t.tagName;){var i=document.defaultView.getComputedStyle(t,null).getPropertyValue("z-index"),r=document.defaultView.getComputedStyle(t,null).getPropertyValue("position");"auto"!==i&&"static"!==r&&e.push(i),t=t.parentElement}for(var s=[],o=0;o2147483647?2147483647:c}var _i,Oa,ap,fh,bE,gh,$t,vh,yE=["north-west","north","north-east","west","east","south-west","south","south-east"],jg="e-resize-handle",hc="e-focused-handle",pJ="e-dlg-resizable",o4=["e-restrict-left"],a4="e-resize-viewport",fJ=["north","west","east","south"],SE=0,IE=0,l4=0,h4=0,Vg=0,Wg=0,Yg=null,ME=null,wE=null,F0=!0,c4=0,CE=!0;function vJ(n){EE();var t=mi("span",{attrs:{unselectable:"on",contenteditable:"false"}});t.setAttribute("class","e-dialog-border-resize e-"+n),"south"===n&&(t.style.height="2px",t.style.width="100%",t.style.bottom="0px",t.style.left="0px"),"north"===n&&(t.style.height="2px",t.style.width="100%",t.style.top="0px",t.style.left="0px"),"east"===n&&(t.style.height="100%",t.style.width="2px",t.style.right="0px",t.style.top="0px"),"west"===n&&(t.style.height="100%",t.style.width="2px",t.style.left="0px",t.style.top="0px"),_i.appendChild(t)}function d4(n){var t;return m(n)||(t="string"==typeof n?document.querySelector(n):n),t}function u4(n){for(var t=n||this,e=_i.querySelectorAll("."+jg),i=0;i-1?"mouse":"touch"}function f4(n){if(n.preventDefault(),_i=n.target.parentElement,EE(),Vg=n.pageX,Wg=n.pageY,n.target.classList.add(hc),m(Yg)||!0!==Yg(n,this)){this.targetEle&&_i&&_i.querySelector("."+pJ)&&($t="body"===this.target?null:this.targetEle,gh=this.targetEle.clientWidth,fh=this.targetEle.clientHeight);var e=m($t)?document:$t;E.add(e,"mousemove",Qg,this),E.add(document,"mouseup",_0,this);for(var i=0;i=0||s.top<0)&&(e=!0):e=!0;var a=IE+(r-Wg);a=a>ap?a:ap;var l=0;m($t)||(l=o.top);var h=m($t)?0:$t.offsetHeight-$t.clientHeight,c=s.top-l-h/2;if(c=c<0?0:c,s.top>0&&c+a>fh){if(e=!1,_i.classList.contains(a4))return;_i.style.height=fh-parseInt(c.toString(),10)+"px"}else{var d=0;if(e){s.top<0&&t+(s.height+s.top)>0&&a+(d=s.top)<=30&&(a=s.height-(s.height+s.top)+30),a+s.top>=fh&&(_i.style.height=s.height+(t-(s.height+s.top))+"px");var u=m($t)?d:c;a>=ap&&a+u<=fh&&(_i.style.height=a+"px")}}}function xE(n){var e,t=!1,i="mouse"===p4(n.type)?n.pageY:n.touches[0].pageY,r=cc(_i),s=m($t)?0:$t.offsetHeight-$t.clientHeight;m($t)||(e=cc($t)),(!m($t)&&r.top-e.top>0||m($t)&&i>0||!m($t)&&Math.floor(r.top-e.top+r.height+(e.bottom-r.bottom))-s<=fh)&&(t=!0);var o=IE-(i-Wg);if(t&&o>=ap&&o<=fh){var a=0;m($t)||(a=e.top);var l=h4-a+(i-Wg);l=l>0?l:1,_i.style.height=o+"px",_i.style.top=l+"px"}}function TE(n){var i,t=document.documentElement.clientWidth,e=!1;m($t)||(i=cc($t));var r="mouse"===p4(n.type)?n.pageX:n.touches[0].pageX,s=cc(_i),o=m($t)?0:$t.offsetWidth-$t.clientWidth,a=m($t)?0:i.left,l=m($t)?0:i.width;m(vh)&&(m($t)?vh=t:(vh=s.left-a-o/2+s.width,vh+=l-o-vh)),(!m($t)&&Math.floor(s.left-i.left+s.width+(i.right-s.right))-o<=gh||m($t)&&r>=0)&&(e=!0);var h=SE-(r-Vg);if(F0&&(h=h>vh?vh:h),e&&h>=bE&&h<=gh){var c=0;m($t)||(c=i.left);var d=l4-c+(r-Vg);d=d>0?d:1,h!==c4&&CE&&(_i.style.width=h+"px"),F0&&(_i.style.left=d+"px",CE=1!==d)}c4=h}function AE(n){var i,t=document.documentElement.clientWidth,e=!1;m($t)||(i=cc($t));var s=(n.touches?n.changedTouches[0]:n).pageX,o=cc(_i);(!m($t)&&(o.left-i.left+o.width<=gh||o.right-i.left>=o.width)||m($t)&&t-s>0)&&(e=!0);var a=SE+(s-Vg),l=0;if(m($t)||(l=i.left),o.left-l+a>gh){if(e=!1,_i.classList.contains(a4))return;_i.style.width=gh-(o.left-l)+"px"}e&&a>=bE&&a<=gh&&(_i.style.width=a+"px")}function v4(){for(var n=_i.querySelectorAll("."+jg),t=0;t=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},bJ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return LE(t,n),Zt([I(!0)],t.prototype,"isFlat",void 0),Zt([I()],t.prototype,"buttonModel",void 0),Zt([I("Button")],t.prototype,"type",void 0),Zt([H()],t.prototype,"click",void 0),t}(Ee),MJ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return LE(t,n),Zt([I("Fade")],t.prototype,"effect",void 0),Zt([I(400)],t.prototype,"duration",void 0),Zt([I(0)],t.prototype,"delay",void 0),t}(Ee),U0="e-dialog",NE="e-rtl",OE="e-dlg-header-content",m4="e-dlg-header",j0="e-footer-content",V0="e-dlg-modal",y4="e-icon-dlg-close",ml="e-dlg-target",ka="e-scroll-disabled",S4="e-device",W0="e-dlg-fullscreen",I4="e-dlg-closeicon-btn",b4="e-popup-open",M4="Information",w4="e-scroll-disabled",C4="e-alert-dialog",E4="e-confirm-dialog",kE="e-dlg-resizable",lp="e-restrict-left",D4="e-resize-viewport",PE="user action",zJ=function(n){function t(e,i){var r=n.call(this,e,i)||this;return r.needsID=!0,r}return LE(t,n),t.prototype.render=function(){this.initialize(),this.initRender(),this.wireEvents(),"100%"===this.width&&(this.element.style.width=""),""!==this.minHeight&&(this.element.style.minHeight=Re(this.minHeight)),this.enableResize&&(this.setResize(),this.isModal&&(this.isModelResize=!0),"None"===this.animationSettings.effect&&this.getMinHeight()),this.renderComplete()},t.prototype.initializeValue=function(){this.dlgClosedBy=PE},t.prototype.preRender=function(){var e=this;if(this.initializeValue(),this.headerContent=null,this.allowMaxHeight=!0,this.preventVisibility=!0,this.clonedEle=this.element.cloneNode(!0),this.closeIconClickEventHandler=function(s){e.dlgClosedBy="close icon",e.hide(s)},this.dlgOverlayClickEventHandler=function(s){e.dlgClosedBy="overlayClick",s.preventFocus=!1,e.trigger("overlayClick",s,function(o){o.preventFocus||e.focusContent(),e.dlgClosedBy=PE})},this.l10n=new ho("dialog",{close:"Close"},this.locale),this.checkPositionData(),m(this.target)){var r=this.isProtectedOnChange;this.isProtectedOnChange=!0,this.target=document.body,this.isProtectedOnChange=r}},t.prototype.updatePersistData=function(){this.enablePersistence&&this.setProperties({width:parseFloat(this.element.style.width),height:parseFloat(this.element.style.height),position:{X:parseFloat(this.dragObj.element.style.left),Y:parseFloat(this.dragObj.element.style.top)}},!0)},t.prototype.isNumberValue=function(e){return/^[-+]?\d*\.?\d+$/.test(e)},t.prototype.checkPositionData=function(){if(!m(this.position)){if(!m(this.position.X)&&"number"!=typeof this.position.X&&this.isNumberValue(this.position.X)){var i=this.isProtectedOnChange;this.isProtectedOnChange=!0,this.position.X=parseFloat(this.position.X),this.isProtectedOnChange=i}m(this.position.Y)||"number"==typeof this.position.Y||this.isNumberValue(this.position.Y)&&(i=this.isProtectedOnChange,this.isProtectedOnChange=!0,this.position.Y=parseFloat(this.position.Y),this.isProtectedOnChange=i)}},t.prototype.getEle=function(e,i){for(var r=void 0,s=0;s=0&&t[e])vJ(t[e]);else if(""!==t[e].trim()){var i=mi("div",{className:"e-icons "+jg+" e-"+t[e]});_i.appendChild(i)}ap=n.minHeight,bE=n.minWidth,gh=n.maxWidth,fh=n.maxHeight,n.proxy&&n.proxy.element&&n.proxy.element.classList.contains("e-dialog")?u4(n.proxy):u4()}({element:this.element,direction:r,minHeight:parseInt(e.slice(0,i.indexOf("p")),10),maxHeight:this.targetEle.clientHeight,minWidth:parseInt(i.slice(0,i.indexOf("p")),10),maxWidth:this.targetEle.clientWidth,boundary:this.target===document.body?null:this.targetEle,resizeBegin:this.onResizeStart.bind(this),resizeComplete:this.onResizeComplete.bind(this),resizing:this.onResizing.bind(this),proxy:this}),this.wireWindowResizeEvent()}else v4(),this.unWireWindowResizeEvent(),this.element.classList.remove(this.isModal?lp:D4),this.element.classList.remove(kE)},t.prototype.getFocusElement=function(e){var r=e.querySelectorAll('input,select,textarea,button:enabled,a,[contenteditable="true"],[tabindex]');return{element:r[r.length-1]}},t.prototype.keyDown=function(e){var i=this;if(9===e.keyCode&&this.isModal){var r=void 0;m(this.btnObj)||(r=this.btnObj[this.btnObj.length-1]),m(this.btnObj)&&!m(this.ftrTemplateContent)&&(r=this.getFocusElement(this.ftrTemplateContent)),m(this.btnObj)&&m(this.ftrTemplateContent)&&!m(this.contentEle)&&(r=this.getFocusElement(this.contentEle)),!m(r)&&document.activeElement===r.element&&!e.shiftKey&&(e.preventDefault(),this.focusableElements(this.element).focus()),document.activeElement===this.focusableElements(this.element)&&e.shiftKey&&(e.preventDefault(),m(r)||r.element.focus())}var h,s=document.activeElement,o=["input","textarea"].indexOf(s.tagName.toLowerCase())>-1,a=!1;if(o||(a=s.hasAttribute("contenteditable")&&"true"===s.getAttribute("contenteditable")),27===e.keyCode&&this.closeOnEscape){this.dlgClosedBy="escape";var l=document.querySelector(".e-popup-open:not(.e-dialog)");!m(l)&&!l.classList.contains("e-toolbar-pop")||this.hide(e)}(13===e.keyCode&&!e.ctrlKey&&"textarea"!==s.tagName.toLowerCase()&&o&&!m(this.primaryButtonEle)||13===e.keyCode&&e.ctrlKey&&("textarea"===s.tagName.toLowerCase()||a)&&!m(this.primaryButtonEle))&&this.buttons.some(function(d,u){h=u;var p=d.buttonModel;return!m(p)&&!0===p.isPrimary})&&"function"==typeof this.buttons[h].click&&setTimeout(function(){i.buttons[h].click.call(i,e)})},t.prototype.initialize=function(){m(this.target)||(this.targetEle="string"==typeof this.target?document.querySelector(this.target):this.target),this.isBlazorServerRender()||V([this.element],U0),X.isDevice&&V([this.element],S4),this.isBlazorServerRender()||this.setCSSClass(),this.setMaxHeight()},t.prototype.initRender=function(){var e=this;if(this.initialRender=!0,this.isBlazorServerRender()||Fe(this.element,{role:"dialog"}),1e3===this.zIndex?(this.setzIndex(this.element,!1),this.calculatezIndex=!0):this.calculatezIndex=!1,this.setTargetContent(),""!==this.header&&!m(this.header)&&this.setHeader(),this.renderCloseIcon(),this.setContent(),""===this.footerTemplate||m(this.footerTemplate)?!m(this.buttons[0])&&!m(this.buttons[0].buttonModel)&&this.setButton():this.setFooterTemplate(),this.allowDragging&&!m(this.headerContent)&&this.setAllowDragging(),Fe(this.element,{"aria-modal":this.isModal?"true":"false"}),this.isModal&&this.setIsModal(),!0!==this.element.classList.contains(C4)&&!0!==this.element.classList.contains(E4)&&!m(this.element.parentElement)){var i=this.isModal?this.dlgContainer.parentElement:this.element.parentElement;this.refElement=this.createElement("div",{className:"e-dlg-ref-element"}),i.insertBefore(this.refElement,this.isModal?this.dlgContainer:this.element)}if(m(this.targetEle)||this.targetEle.appendChild(this.isModal?this.dlgContainer:this.element),this.popupObj=new ac(this.element,{height:this.height,width:this.width,zIndex:this.zIndex,relateTo:this.target,actionOnScroll:"none",enableRtl:this.enableRtl,open:function(o){var a={container:e.isModal?e.dlgContainer:e.element,element:e.element,target:e.target,preventFocus:!1};e.enableResize&&e.resetResizeIcon(),e.trigger("open",a,function(l){l.preventFocus||e.focusContent()})},close:function(o){e.isModal&&V([e.dlgOverlay],"e-fade"),e.unBindEvent(e.element),e.isModal&&(e.dlgContainer.style.display="none"),e.trigger("close",e.closeArgs);var a=document.activeElement;!m(a)&&!m(a.blur)&&a.blur(),!m(e.storeActiveElement)&&!m(e.storeActiveElement.focus)&&e.storeActiveElement.focus()}}),this.positionChange(),this.setEnableRTL(),this.isBlazorServerRender()||(V([this.element],"e-popup-close"),this.isModal&&this.setOverlayZindex()),this.visible){if(this.show(),this.isModal){var r=this.getTargetContainer(this.target);r instanceof Element&&"rtl"===window.getComputedStyle(r).getPropertyValue("direction")&&this.setPopupPosition()}}else this.isModal&&(this.dlgOverlay.style.display="none");this.initialRender=!1},t.prototype.getTargetContainer=function(e){var i=null;if("string"==typeof e)if(e.startsWith("#"))i=document.getElementById(e.substring(1));else if(e.startsWith(".")){var r=document.getElementsByClassName(e.substring(1));i=r.length>0?r[0]:null}else!(e instanceof HTMLElement)&&e!==document.body&&(i=document.querySelector(e));else e instanceof HTMLElement&&(i=e);return i},t.prototype.resetResizeIcon=function(){var e=this.getMinHeight();if(this.targetEle.offsetHeight0&&("function"==typeof this.buttons[e].click&&E.add(s[e],"click",this.buttons[e].click,this),"object"==typeof this.buttons[e].click&&E.add(s[e],"click",this.buttonClickHandler.bind(this,e),this)),!this.isBlazorServerRender()&&!m(this.ftrTemplateContent)&&(this.btnObj[e].appendTo(this.ftrTemplateContent.children[e]),this.buttons[e].isFlat&&this.btnObj[e].element.classList.add("e-flat"),this.primaryButtonEle=this.element.getElementsByClassName("e-primary")[0]))},t.prototype.buttonClickHandler=function(e){this.trigger("buttons["+e+"].click",{})},t.prototype.setContent=function(){this.contentEle=this.createElement("div",{className:"e-dlg-content",id:this.element.id+"_dialog-content"}),Fe(this.element,this.headerEle?{"aria-describedby":this.element.id+"_title "+this.element.id+"_dialog-content"}:{"aria-describedby":this.element.id+"_dialog-content"}),this.innerContentElement?this.contentEle.appendChild(this.innerContentElement):(!m(this.content)&&""!==this.content||!this.initialRender)&&(("string"!=typeof this.content||ce())&&this.content instanceof HTMLElement?this.contentEle.appendChild(this.content):this.setTemplate(this.content,this.contentEle,"content")),m(this.headerContent)?this.element.insertBefore(this.contentEle,this.element.children[0]):this.element.insertBefore(this.contentEle,this.element.children[1]),"auto"===this.height&&(!this.isBlazorServerRender()&&X.isIE&&""===this.element.style.width&&!m(this.width)&&(this.element.style.width=Re(this.width)),this.setMaxHeight())},t.prototype.setTemplate=function(e,i,r){var s,o,a;o=i.classList.contains(m4)?this.element.id+"header":i.classList.contains(j0)?this.element.id+"footerTemplate":this.element.id+"content",m(e.outerHTML)?("string"==typeof e||"string"!=typeof e||ce()&&!this.isStringTemplate)&&("string"==typeof e&&(e=this.sanitizeHelper(e)),this.isVue||"string"!=typeof e?(s=ii(e),a=e):i.innerHTML=e):i.appendChild(e);var l=[];if(!m(s)){for(var c=0,d=s({},this,r,o,!(ce()&&!this.isStringTemplate&&0===a.indexOf("
Blazor"))||this.isStringTemplate);c/g,"");(this.element.children.length>0||i)&&(this.innerContentElement=document.createDocumentFragment(),[].slice.call(this.element.childNodes).forEach(function(r){8!==r.nodeType&&e.innerContentElement.appendChild(r)}))}},t.prototype.setHeader=function(){this.headerEle?this.headerEle.innerHTML="":this.headerEle=this.createElement("div",{id:this.element.id+"_title",className:m4}),this.createHeaderContent(),this.headerContent.appendChild(this.headerEle),this.setTemplate(this.header,this.headerEle,"header"),Fe(this.element,{"aria-describedby":this.element.id+"_title"}),Fe(this.element,{"aria-labelledby":this.element.id+"_dialog-header"}),this.element.insertBefore(this.headerContent,this.element.children[0]),this.allowDragging&&!m(this.headerContent)&&this.setAllowDragging()},t.prototype.setFooterTemplate=function(){this.ftrTemplateContent?this.ftrTemplateContent.innerHTML="":this.ftrTemplateContent=this.createElement("div",{className:j0}),""===this.footerTemplate||m(this.footerTemplate)?this.ftrTemplateContent.innerHTML=this.buttonContent.join(""):this.setTemplate(this.footerTemplate,this.ftrTemplateContent,"footerTemplate"),this.element.appendChild(this.ftrTemplateContent)},t.prototype.createHeaderContent=function(){m(this.headerContent)&&(this.headerContent=this.createElement("div",{id:this.element.id+"_dialog-header",className:OE}))},t.prototype.renderCloseIcon=function(){this.showCloseIcon&&(this.closeIcon=this.createElement("button",{className:I4,attrs:{type:"button"}}),this.closeIconBtnObj=new ys({cssClass:"e-flat",iconCss:y4+" e-icons"}),this.closeIconTitle(),m(this.headerContent)?(this.createHeaderContent(),pl([this.closeIcon],this.headerContent),this.element.insertBefore(this.headerContent,this.element.children[0])):pl([this.closeIcon],this.headerContent),this.closeIconBtnObj.appendTo(this.closeIcon))},t.prototype.closeIconTitle=function(){this.l10n.setLocale(this.locale);var e=this.l10n.getConstant("close");this.closeIcon.setAttribute("title",e),this.closeIcon.setAttribute("aria-label",e)},t.prototype.setCSSClass=function(e){e&&(K([this.element],e.split(" ")),this.isModal&&!m(this.dlgContainer)&&K([this.dlgContainer],e.split(" "))),this.cssClass&&(V([this.element],this.cssClass.split(" ")),this.isModal&&!m(this.dlgContainer)&&V([this.dlgContainer],this.cssClass.split(" ")))},t.prototype.setIsModal=function(){this.dlgContainer=this.createElement("div",{className:"e-dlg-container"}),this.setCSSClass(),this.element.classList.remove(b4),this.element.parentNode.insertBefore(this.dlgContainer,this.element),this.dlgContainer.appendChild(this.element),V([this.element],V0),this.dlgOverlay=this.createElement("div",{className:"e-dlg-overlay"}),this.dlgOverlay.style.zIndex=(this.zIndex-1).toString(),this.dlgContainer.appendChild(this.dlgOverlay)},t.prototype.getValidFocusNode=function(e){for(var i,r=0;r0||"a"===i.tagName.toLowerCase()&&i.hasAttribute("href"))&&i.tabIndex>-1&&!i.disabled&&!this.disableElement(i,'[disabled],[aria-disabled="true"],[type="hidden"]'))return i;i=null}return i},t.prototype.focusableElements=function(e){if(!m(e)){var r=e.querySelectorAll('input,select,textarea,button,a,[contenteditable="true"],[tabindex]');return this.getValidFocusNode(r)}return null},t.prototype.getAutoFocusNode=function(e){var i=e.querySelector("."+I4),s=e.querySelectorAll("[autofocus]"),o=this.getValidFocusNode(s);if(ce()&&(this.primaryButtonEle=this.element.getElementsByClassName("e-primary")[0]),m(o)){if(!m(o=this.focusableElements(this.contentEle)))return o;if(!m(this.primaryButtonEle))return this.element.querySelector(".e-primary")}else i=o;return i},t.prototype.disableElement=function(e,i){var r=e?e.matches||e.webkitMatchesSelector||e.msGetRegionContent:null;if(r)for(;e;e=e.parentNode)if(e instanceof Element&&r.call(e,i))return e;return null},t.prototype.focusContent=function(){var e=this.getAutoFocusNode(this.element),i=m(e)?this.element:e,r=X.userAgent;(r.indexOf("MSIE ")>0||r.indexOf("Trident/")>0)&&this.element.focus(),i.focus(),this.unBindEvent(this.element),this.bindEvent(this.element)},t.prototype.bindEvent=function(e){E.add(e,"keydown",this.keyDown,this)},t.prototype.unBindEvent=function(e){E.remove(e,"keydown",this.keyDown)},t.prototype.updateSanitizeContent=function(){this.isBlazorServerRender()||(this.contentEle.innerHTML=this.sanitizeHelper(this.content))},t.prototype.isBlazorServerRender=function(){return ce()&&this.isServerRendered},t.prototype.getModuleName=function(){return"dialog"},t.prototype.onPropertyChanged=function(e,i){if(this.element.classList.contains(U0))for(var r=0,s=Object.keys(e);r0?this.showCloseIcon||""!==this.header&&!m(this.header)?this.showCloseIcon||he(this.closeIcon):(he(this.headerContent),this.headerContent=null):(this.renderCloseIcon(),this.wireEvents());break;case"locale":this.showCloseIcon&&this.closeIconTitle();break;case"visible":this.visible?this.show():this.hide();break;case"isModal":this.updateIsModal();break;case"height":je(this.element,{height:Re(e.height)}),this.updatePersistData();break;case"width":je(this.element,{width:Re(e.width)}),this.updatePersistData();break;case"zIndex":this.popupObj.zIndex=this.zIndex,this.isModal&&this.setOverlayZindex(this.zIndex),this.element.style.zIndex!==this.zIndex.toString()&&(this.calculatezIndex=!1);break;case"cssClass":this.setCSSClass(i.cssClass);break;case"buttons":this.unWireButtonEvents(),this.destroyButtons(),m(this.ftrTemplateContent)||(he(this.ftrTemplateContent),this.ftrTemplateContent=null),this.footerTemplate="",this.setButton();break;case"allowDragging":this.allowDragging&&!m(this.headerContent)?this.setAllowDragging():this.dragObj.destroy();break;case"target":this.setTarget(e.target);break;case"position":if(this.checkPositionData(),this.isModal){var a=this.position.X,l=this.position.Y;m(i.position)||(m(i.position.X)||(a=i.position.X),m(i.position.Y)||(l=i.position.Y)),this.dlgContainer.classList.contains("e-dlg-"+a+"-"+l)&&this.dlgContainer.classList.remove("e-dlg-"+a+"-"+l)}this.positionChange(),this.updatePersistData();break;case"enableRtl":this.setEnableRTL();break;case"enableResize":this.setResize();break;case"minHeight":""!==this.minHeight&&(this.element.style.minHeight=Re(this.minHeight))}},t.prototype.setTarget=function(e){this.popupObj.relateTo=e,this.target=e,this.targetEle="string"==typeof this.target?document.querySelector(this.target):this.target,this.dragObj&&(this.dragObj.dragArea=this.targetEle),this.setMaxHeight(),this.isModal&&this.updateIsModal(),this.enableResize&&this.setResize()},t.prototype.updateIsModal=function(){if(this.element.setAttribute("aria-modal",this.isModal?"true":"false"),this.isModal)m(this.dlgOverlay)&&(this.setIsModal(),this.element.style.top="0px",this.element.style.left="0px",m(this.targetEle)||this.targetEle.appendChild(this.dlgContainer));else{for(K([this.element],V0),K([document.body],[ml,ka]),he(this.dlgOverlay);this.dlgContainer.firstChild;)this.dlgContainer.parentElement.insertBefore(this.dlgContainer.firstChild,this.dlgContainer);this.dlgContainer.parentElement.removeChild(this.dlgContainer)}this.visible&&this.show(),this.positionChange(),this.isModal&&this.dlgOverlay&&E.add(this.dlgOverlay,"click",this.dlgOverlayClickEventHandler,this)},t.prototype.setzIndex=function(e,i){var r=this.isProtectedOnChange;this.isProtectedOnChange=!0;var s=lc(e);this.zIndex=s>this.zIndex?s:this.zIndex,this.isProtectedOnChange=r,i&&(this.popupObj.zIndex=this.zIndex)},t.prototype.windowResizeHandler=function(){(function yJ(n){gh=n})(this.targetEle.clientWidth),function SJ(n){fh=n}(this.targetEle.clientHeight),this.setMaxHeight()},t.prototype.getPersistData=function(){return this.addOnPersist(["width","height","position"])},t.prototype.removeAllChildren=function(e){for(;e.children[0];)this.removeAllChildren(e.children[0]),e.removeChild(e.children[0])},t.prototype.destroy=function(){if(!this.isDestroyed){var e=[NE,V0,kE,lp,W0,S4],i=["role","aria-modal","aria-labelledby","aria-describedby","aria-grabbed","tabindex","style"];K([this.targetEle],[ml,ka]),!m(this.element)&&this.element.classList.contains(W0)&&K([document.body],[ml,ka]),this.isModal&&K([m(this.targetEle)?document.body:this.targetEle],ka),this.unWireEvents(),this.unWireButtonEvents(),this.destroyButtons(),m(this.closeIconBtnObj)||this.closeIconBtnObj.destroy(),m(this.dragObj)||this.dragObj.destroy(),!m(this.popupObj.element)&&this.popupObj.element.classList.contains("e-popup")&&this.popupObj.destroy(),K([this.element],e),!m(this.cssClass)&&""!==this.cssClass&&K([this.element],this.cssClass.split(" ")),!m(this.refElement)&&!m(this.refElement.parentElement)&&(this.refElement.parentElement.insertBefore(this.isModal?this.dlgContainer:this.element,this.refElement),he(this.refElement),this.refElement=void 0),this.isModal&&(he(this.dlgOverlay),this.dlgContainer.parentNode.insertBefore(this.element,this.dlgContainer),he(this.dlgContainer)),this.element.innerHTML=this.clonedEle.innerHTML;for(var r=0;r0&&""===this.footerTemplate&&this.ftrTemplateContent)for(var e=0;e=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},zE="e-tooltip",O4="e-icons",k4="e-tooltip-close",RE="e-tooltip-wrap",P4="e-tip-content",hp="e-arrow-tip",z4="e-arrow-tip-outer",Y0="e-arrow-tip-inner",Gg="e-tip-bottom",HE="e-tip-top",R4="e-tip-left",BE="e-tip-right",FE="e-popup",Xg="e-popup-open",_E="e-popup-close",Q0="e-lib",H4="e-tooltip-popup-container",UJ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return T4(t,n),Gi([I({effect:"FadeIn",duration:150,delay:0})],t.prototype,"open",void 0),Gi([I({effect:"FadeOut",duration:150,delay:0})],t.prototype,"close",void 0),t}(Ee),mh=function(n){function t(e,i){var r=n.call(this,e,i)||this;return r.mouseMoveEvent=null,r.mouseMoveTarget=null,r.containerElement=null,r.isBodyContainer=!0,r}return T4(t,n),t.prototype.initialize=function(){this.formatPosition(),V([this.element],zE)},t.prototype.formatPosition=function(){var e,i;this.position&&(0===this.position.indexOf("Top")||0===this.position.indexOf("Bottom")?(e=this.position.split(/(?=[A-Z])/),this.tooltipPositionY=e[0],this.tooltipPositionX=e[1]):(i=this.position.split(/(?=[A-Z])/),this.tooltipPositionX=i[0],this.tooltipPositionY=i[1]))},t.prototype.renderArrow=function(){this.setTipClass(this.position);var e=this.createElement("div",{className:hp+" "+this.tipClass});e.appendChild(this.createElement("div",{className:z4+" "+this.tipClass})),e.appendChild(this.createElement("div",{className:Y0+" "+this.tipClass})),this.tooltipEle.appendChild(e)},t.prototype.setTipClass=function(e){this.tipClass=0===e.indexOf("Right")?R4:0===e.indexOf("Bottom")?HE:0===e.indexOf("Left")?BE:Gg},t.prototype.renderPopup=function(e){var i=this.mouseTrail?{top:0,left:0}:this.getTooltipPosition(e);this.tooltipEle.classList.remove(Q0),this.popupObj=new ac(this.tooltipEle,{height:this.height,width:this.width,position:{X:i.left,Y:i.top},enableRtl:this.enableRtl,open:this.openPopupHandler.bind(this),close:this.closePopupHandler.bind(this)})},t.prototype.getScalingFactor=function(e){if(!e)return{x:1,y:1};var i={x:1,y:1},r=e.closest('[style*="transform: scale"]');if(r&&r!==this.tooltipEle&&r.contains(this.tooltipEle)){var a=window.getComputedStyle(r).getPropertyValue("transform").match(/matrix\(([^)]+)\)/)[1].split(",").map(parseFloat);i.x=a[0],i.y=a[3]}return i},t.prototype.getTooltipPosition=function(e){this.tooltipEle.style.display="block";var i=this.element.closest('[style*="zoom"]');i&&(i.contains(this.tooltipEle)||(this.tooltipEle.style.zoom=getComputedStyle(i).zoom));var r=is(e,this.tooltipPositionX,this.tooltipPositionY,!this.isBodyContainer,this.isBodyContainer?null:this.containerElement.getBoundingClientRect()),s=this.getScalingFactor(e),o=this.calculateTooltipOffset(this.position,s.x,s.y),a=this.calculateElementPosition(r,o),c=this.collisionFlipFit(e,a[0],a[1]);return c.left=c.left/s.x,c.top=c.top/s.y,this.tooltipEle.style.display="",c},t.prototype.windowResize=function(){this.reposition(this.findTarget())},t.prototype.reposition=function(e){if(this.popupObj&&e){var i=this.getTooltipPosition(e);this.popupObj.position={X:i.left,Y:i.top},this.popupObj.dataBind()}},t.prototype.openPopupHandler=function(){!this.mouseTrail&&this.needTemplateReposition()&&this.reposition(this.findTarget()),this.trigger("afterOpen",this.tooltipEventArgs),this.tooltipEventArgs=null},t.prototype.closePopupHandler=function(){this.isReact&&!("Click"===this.opensOn||"function"==typeof this.content)&&this.clearTemplate(["content"]),this.clear();var e={type:this.tooltipEventArgs.event?this.tooltipEventArgs.event.type:null,cancel:!1,target:this.tooltipEventArgs.target,event:this.tooltipEventArgs.event?this.tooltipEventArgs.event:null,element:this.tooltipEle,isInteracted:!m(this.tooltipEventArgs.event)};this.trigger("afterClose",e),e=null},t.prototype.calculateTooltipOffset=function(e,i,r){void 0===i&&(i=1),void 0===r&&(r=1);var o,a,l,h,c,d,u,p,s={top:0,left:0};if(1!==i||1!==r){var f=this.tooltipEle.getBoundingClientRect(),g=void 0;l=Math.round(f.width),h=Math.round(f.height),(c=U("."+hp,this.tooltipEle))&&(g=c.getBoundingClientRect()),o=c?Math.round(g.width):0,a=c?Math.round(g.height):0,d=this.showTipPointer?0:8,u=a/2+2+(h-this.tooltipEle.clientHeight*r),p=o/2+2+(l-this.tooltipEle.clientWidth*i)}else l=this.tooltipEle.offsetWidth,h=this.tooltipEle.offsetHeight,c=U("."+hp,this.tooltipEle),d=this.showTipPointer?0:8,u=(a=c?c.offsetHeight:0)/2+2+(this.tooltipEle.offsetHeight-this.tooltipEle.clientHeight),p=(o=c?c.offsetWidth:0)/2+2+(this.tooltipEle.offsetWidth-this.tooltipEle.clientWidth);switch(this.mouseTrail&&(d+=2),e){case"RightTop":s.left+=o+d,s.top-=h-u;break;case"RightCenter":s.left+=o+d,s.top-=h/2;break;case"RightBottom":s.left+=o+d,s.top-=u;break;case"BottomRight":s.top+=a+d,s.left-=p;break;case"BottomCenter":s.top+=a+d,s.left-=l/2;break;case"BottomLeft":s.top+=a+d,s.left-=l-p;break;case"LeftBottom":s.left-=o+l+d,s.top-=u;break;case"LeftCenter":s.left-=o+l+d,s.top-=h/2;break;case"LeftTop":s.left-=o+l+d,s.top-=h-u;break;case"TopLeft":s.top-=h+a+d,s.left-=l-p;break;case"TopRight":s.top-=h+a+d,s.left-=p;break;default:s.top-=h+a+d,s.left-=l/2}return s.left+=this.offsetX,s.top+=this.offsetY,s},t.prototype.updateTipPosition=function(e){var i=we("."+hp+",."+z4+",."+Y0,this.tooltipEle);K(i,[Gg,HE,R4,BE]),this.setTipClass(e),V(i,this.tipClass)},t.prototype.adjustArrow=function(e,i,r,s){var o=U("."+hp,this.tooltipEle);if(!1!==this.showTipPointer&&null!==o){var a,l;this.updateTipPosition(i),this.tooltipEle.style.display="block";var f,h=this.tooltipEle.clientWidth,c=this.tooltipEle.clientHeight,d=U("."+Y0,this.tooltipEle),u=o.offsetWidth,p=o.offsetHeight;this.tooltipEle.style.display="",this.tipClass===Gg||this.tipClass===HE?(this.tipClass===Gg?(l="99.9%",d.style.top="-"+(p-2)+"px"):(l=-(p-1)+"px",d.style.top="-"+(p-6)+"px"),e&&(a=(f="Center"!==r||h>e.offsetWidth||this.mouseTrail)&&"Left"===r||!f&&"End"===this.tipPointerPosition?h-u-2+"px":f&&"Right"===r||!f&&"Start"===this.tipPointerPosition?"2px":!f||"End"!==this.tipPointerPosition&&"Start"!==this.tipPointerPosition?h/2-u/2+"px":"End"===this.tipPointerPosition?e.offsetWidth+(this.tooltipEle.offsetWidth-e.offsetWidth)/2-u/2-2+"px":(this.tooltipEle.offsetWidth-e.offsetWidth)/2-u/2+2+"px")):(this.tipClass===BE?(a="99.9%",d.style.left="-"+(u-2)+"px"):(a=-(u-1)+"px",d.style.left=u-2-u+"px"),l=(f="Center"!==s||c>e.offsetHeight||this.mouseTrail)&&"Top"===s||!f&&"End"===this.tipPointerPosition?c-p-2+"px":f&&"Bottom"===s||!f&&"Start"===this.tipPointerPosition?"2px":c/2-p/2+"px"),o.style.top=l,o.style.left=a}},t.prototype.renderContent=function(e){var i=this,r=U("."+P4,this.tooltipEle);if(this.cssClass&&V([this.tooltipEle],this.cssClass.split(" ")),e&&!m(e.getAttribute("title"))&&(e.setAttribute("data-content",e.getAttribute("title")),e.removeAttribute("title")),m(this.content))e&&!m(e.getAttribute("data-content"))&&(r.innerHTML=e.getAttribute("data-content"));else if(r.innerHTML="",this.content instanceof HTMLElement)r.appendChild(this.content);else if("string"==typeof this.content)this.isAngular?this.setProperties({content:Ti.sanitize(this.content)},!0):this.content=this.enableHtmlSanitizer?Ti.sanitize(this.content):this.content,this.enableHtmlParse?(o=ii(this.content)({},this,"content",this.element.id+"content",void 0,void 0,r,this.root))&&Dt(o,r):r.textContent=this.content;else{var o;(o=ii(this.content)({},this,"content",this.element.id+"content",void 0,void 0,r))&&(this.isAngular&&setTimeout(function(){i.reposition(e)},1),Dt(o,r)),this.renderReactTemplates()}},t.prototype.renderCloseIcon=function(){if(this.isSticky){var i=this.createElement("div",{className:O4+" "+k4});this.tooltipEle.appendChild(i),E.add(i,X.touchStartEvent,this.onStickyClose,this)}else{var e=this.tooltipEle.querySelector("."+O4+"."+k4);e&>(e)}},t.prototype.addDescribedBy=function(e,i){var r=(e.getAttribute("aria-describedby")||"").split(/\s+/);r.indexOf(i)<0&&r.push(i),Fe(e,{"aria-describedby":r.join(" ").trim(),"data-tooltip-id":i})},t.prototype.removeDescribedBy=function(e){var i=e.getAttribute("data-tooltip-id"),r=(e.getAttribute("aria-describedby")||"").split(/\s+/),s=r.indexOf(i);-1!==s&&r.splice(s,1),e.removeAttribute("data-tooltip-id");var o=r.join(" ").trim();o?e.setAttribute("aria-describedby",o):e.removeAttribute("aria-describedby")},t.prototype.tapHoldHandler=function(e){clearTimeout(this.autoCloseTimer),this.targetHover(e.originalEvent)},t.prototype.touchEndHandler=function(){var e=this;this.isSticky||(this.autoCloseTimer=setTimeout(function(){e.close()},1500))},t.prototype.targetClick=function(e){var i;!m(i=this.target?J(e.target,this.target):this.element)&&(null===i.getAttribute("data-tooltip-id")?this.targetHover(e):this.isSticky||this.hideTooltip(this.animation.close,e,i))},t.prototype.targetHover=function(e){var i;if(!(m(i=this.target?J(e.target,this.target):this.element)||null!==i.getAttribute("data-tooltip-id")&&0===this.closeDelay)){for(var s=0,o=[].slice.call(we('[data-tooltip-id= "'+this.ctrlId+'_content"]',document));s0?this.showTimer=setTimeout(function(){o.mouseTrail&&E.add(i,"mousemove touchstart mouseenter",o.onMouseMove,o),o.popupObj&&(o.popupObj.show(a,i),o.mouseMoveEvent&&o.mouseTrail&&o.onMouseMove(o.mouseMoveEvent))},this.openDelay):this.popupObj&&this.popupObj.show(a,i)}s&&this.wireMouseEvents(s,i)},t.prototype.needTemplateReposition=function(){return!m(this.viewContainerRef)&&"string"!=typeof this.viewContainerRef||this.isReact},t.prototype.checkCollision=function(e,i,r){var s={left:i,top:r,position:this.position,horizontal:this.tooltipPositionX,vertical:this.tooltipPositionY},o=oc(this.tooltipEle,this.checkCollideTarget(),i,r);return o.length>0&&(s.horizontal=o.indexOf("left")>=0?"Right":o.indexOf("right")>=0?"Left":this.tooltipPositionX,s.vertical=o.indexOf("top")>=0?"Bottom":o.indexOf("bottom")>=0?"Top":this.tooltipPositionY),s},t.prototype.calculateElementPosition=function(e,i){return[this.isBodyContainer?e.left+i.left:e.left-this.containerElement.getBoundingClientRect().left+i.left+window.pageXOffset+this.containerElement.scrollLeft,this.isBodyContainer?e.top+i.top:e.top-this.containerElement.getBoundingClientRect().top+i.top+window.pageYOffset+this.containerElement.scrollTop]},t.prototype.collisionFlipFit=function(e,i,r){var s=this.checkCollision(e,i,r),o=s.position;if(this.tooltipPositionY!==s.vertical&&(o=0===this.position.indexOf("Bottom")||0===this.position.indexOf("Top")?s.vertical+this.tooltipPositionX:this.tooltipPositionX+s.vertical),this.tooltipPositionX!==s.horizontal&&(0===o.indexOf("Left")&&(s.vertical="LeftTop"===o||"LeftCenter"===o?"Top":"Bottom",o=s.vertical+"Left"),0===o.indexOf("Right")&&(s.vertical="RightTop"===o||"RightCenter"===o?"Top":"Bottom",o=s.vertical+"Right"),s.horizontal=this.tooltipPositionX),this.tooltipEventArgs={type:null,cancel:!1,target:e,event:null,element:this.tooltipEle,collidedPosition:o},this.trigger("beforeCollision",this.tooltipEventArgs),this.tooltipEventArgs.cancel)o=this.position;else{var a=s.vertical,l=s.horizontal;if(s.position!==o){var h=is(e,l,a,!this.isBodyContainer,this.isBodyContainer?null:this.containerElement.getBoundingClientRect());this.adjustArrow(e,o,l,a);var c=this.getScalingFactor(e),d=this.calculateTooltipOffset(o,c.x,c.y);d.top-=this.getOffSetPosition("TopBottom",o,this.offsetY),d.left-=this.getOffSetPosition("RightLeft",o,this.offsetX),s.position=o;var u=this.calculateElementPosition(h,d);s.left=u[0],s.top=u[1]}else this.adjustArrow(e,o,l,a)}var p={left:s.left,top:s.top},f=this.isBodyContainer?hE(this.tooltipEle,this.checkCollideTarget(),{X:!0,Y:this.windowCollision},p):p;this.tooltipEle.style.display="block";var g=U("."+hp,this.tooltipEle);if(this.showTipPointer&&null!=g&&(0===o.indexOf("Bottom")||0===o.indexOf("Top"))){var v=parseInt(g.style.left,10)-(f.left-s.left);v<0?v=0:v+g.offsetWidth>this.tooltipEle.clientWidth&&(v=this.tooltipEle.clientWidth-g.offsetWidth),g.style.left=v.toString()+"px"}return this.tooltipEle.style.display="",p.left=f.left,p.top=f.top,p},t.prototype.getOffSetPosition=function(e,i,r){return-1!==e.indexOf(this.position.split(/(?=[A-Z])/)[0])&&-1!==e.indexOf(i.split(/(?=[A-Z])/)[0])?2*r:0},t.prototype.checkCollideTarget=function(){return!this.windowCollision&&this.target?this.element:null},t.prototype.hideTooltip=function(e,i,r){var s=this;this.closeDelay>0?(clearTimeout(this.hideTimer),clearTimeout(this.showTimer),this.hideTimer=setTimeout(function(){s.closeDelay&&s.tooltipEle&&s.isTooltipOpen||s.tooltipHide(e,i,r)},this.closeDelay)):this.tooltipHide(e,i,r)},t.prototype.tooltipHide=function(e,i,r){var o,s=this;o=i?this.target?r||i.target:this.element:U('[data-tooltip-id= "'+this.ctrlId+'_content"]',document),this.tooltipEventArgs={type:i?i.type:null,cancel:!1,target:o,event:i||null,element:this.tooltipEle,isInteracted:!m(i)},this.trigger("beforeClose",this.tooltipEventArgs,function(a){a.cancel?s.isHidden=!1:(s.mouseMoveBeforeRemove(),s.popupHide(e,o,i))})},t.prototype.popupHide=function(e,i,r){i&&r&&this.restoreElement(i),this.isHidden=!0;var s={name:this.animation.close.effect,duration:e.duration,delay:e.delay,timingFunction:"easeIn"};"None"===e.effect&&(s=void 0),this.popupObj&&this.popupObj.hide(s)},t.prototype.restoreElement=function(e){this.unwireMouseEvents(e),m(e.getAttribute("data-content"))||(e.setAttribute("title",e.getAttribute("data-content")),e.removeAttribute("data-content")),this.removeDescribedBy(e)},t.prototype.clear=function(){var e=this.findTarget();e&&this.restoreElement(e),this.tooltipEle&&(K([this.tooltipEle],_E),V([this.tooltipEle],Xg)),this.isHidden&&(this.popupObj&&this.popupObj.destroy(),this.tooltipEle&>(this.tooltipEle),this.tooltipEle=null,this.popupObj=null)},t.prototype.tooltipHover=function(){this.tooltipEle&&(this.isTooltipOpen=!0)},t.prototype.tooltipMouseOut=function(e){this.isTooltipOpen=!1,this.hideTooltip(this.animation.close,e,this.findTarget())},t.prototype.onMouseOut=function(e){var i=e.relatedTarget;if(i&&!this.mouseTrail){var r=J(i,"."+RE+"."+Q0+"."+FE);r?E.add(r,"mouseleave",this.tooltipElementMouseOut,this):(this.hideTooltip(this.animation.close,e,this.findTarget()),0===this.closeDelay&&("None"===this.animation.close.effect||this.isReact&&"string"!=typeof this.content)&&this.clear())}else this.hideTooltip(this.animation.close,e,this.findTarget()),this.clear();this.popupObj&&!this.popupObj.element.classList.contains(Xg)&&this.clear()},t.prototype.tooltipElementMouseOut=function(e){this.hideTooltip(this.animation.close,e,this.findTarget()),E.remove(this.element,"mouseleave",this.tooltipElementMouseOut),this.clear()},t.prototype.onStickyClose=function(){this.close()},t.prototype.onMouseMove=function(e){var i=0,r=0;e.type.indexOf("touch")>-1?(e.preventDefault(),i=e.touches[0].pageX,r=e.touches[0].pageY):(i=e.pageX,r=e.pageY),Hs.stop(this.tooltipEle),K([this.tooltipEle],_E),V([this.tooltipEle],Xg),this.adjustArrow(e.target,this.position,this.tooltipPositionX,this.tooltipPositionY);var s=this.getScalingFactor(e.target),o=this.calculateTooltipOffset(this.position,s.x,s.y),h=this.checkCollision(e.target,i+o.left+this.offsetX,r+o.top+this.offsetY);if(this.tooltipPositionX!==h.horizontal||this.tooltipPositionY!==h.vertical){var c=0===this.position.indexOf("Bottom")||0===this.position.indexOf("Top")?h.vertical+h.horizontal:h.horizontal+h.vertical;h.position=c,this.adjustArrow(e.target,h.position,h.horizontal,h.vertical);var d=this.calculateTooltipOffset(h.position,s.x,s.y);h.left=i+d.left-this.offsetX,h.top=r+d.top-this.offsetY}this.tooltipEle.style.left=h.left+"px",this.tooltipEle.style.top=h.top+"px"},t.prototype.keyDown=function(e){this.tooltipEle&&27===e.keyCode&&this.close()},t.prototype.touchEnd=function(e){this.tooltipEle&&null===J(e.target,"."+zE)&&!this.isSticky&&this.close()},t.prototype.scrollHandler=function(e){this.tooltipEle&&!this.isSticky&&!J(e.target,"."+RE+"."+Q0+"."+FE)&&!this.isSticky&&this.close()},t.prototype.render=function(){this.initialize(),this.wireEvents(this.opensOn),this.renderComplete()},t.prototype.preRender=function(){this.tipClass=Gg,this.tooltipPositionX="Center",this.tooltipPositionY="Top",this.isHidden=!0},t.prototype.wireEvents=function(e){for(var r=0,s=this.getTriggerList(e);r0)for(var i=0,r=e;i0)for(var i=0,r=e;i0&&this.condition&&-1!==this.condition.indexOf("not")&&(e[s].condition=e[s].condition?e[s].condition+"not":"not"),i=e[s].validate(t),r){if(!i)return!1}else if(i)return!0;return r},n.prototype.toJson=function(){var t,e;if(this.isComplex){t=[],e=this.predicates;for(var i=0;ie.length-3?(e=e.substring(0,e.length-1),n.endsWith(n.toLowerCase(t),n.toLowerCase(e))):(e.lastIndexOf("%")!==e.indexOf("%")&&e.lastIndexOf("%")>e.indexOf("%")+1&&(e=e.substring(e.indexOf("%")+1,e.lastIndexOf("%"))),-1!==t.indexOf(e)))},n.fnSort=function(t){return"ascending"===(t=t?n.toLowerCase(t):"ascending")?this.fnAscending:this.fnDescending},n.fnAscending=function(t,e){return m(t)&&m(e)||null==e?-1:"string"==typeof t?t.localeCompare(e):null==t?1:t-e},n.fnDescending=function(t,e){return m(t)&&m(e)?-1:null==e?1:"string"==typeof t?-1*t.localeCompare(e):null==t?-1:e-t},n.extractFields=function(t,e){for(var i={},r=0;r0||e.length>0;)o=t.length>0&&e.length>0?r?r(this.getVal(t,0,i),this.getVal(e,0,i),t[0],e[0])<=0?t:e:t[0][i]0?t:e,s.push(o.shift());return s},n.getVal=function(t,e,i){return i?this.getObject(i,t[e]):t[e]},n.toLowerCase=function(t){return t?"string"==typeof t?t.toLowerCase():t.toString():0===t||!1===t?t.toString():""},n.callAdaptorFunction=function(t,e,i,r){if(e in t){var s=t[e](i,r);m(s)||(i=s)}return i},n.getAddParams=function(t,e,i){var r={};return n.callAdaptorFunction(t,"addParams",{dm:e,query:i,params:i?i.params:[],reqParams:r}),r},n.isPlainObject=function(t){return!!t&&t.constructor===Object},n.isCors=function(){var t=null;try{t=new window.XMLHttpRequest}catch{}return!!t&&"withCredentials"in t},n.getGuid=function(t){var i;return(t||"")+"00000000-0000-4000-0000-000000000000".replace(/0/g,function(r,s){if("crypto"in window&&"getRandomValues"in crypto){var o=new Uint8Array(1);window.crypto.getRandomValues(o),i=o[0]%16|0}else i=16*Math.random()|0;return"0123456789abcdef"[19===s?3&i|8:i]})},n.isNull=function(t){return null==t},n.getItemFromComparer=function(t,e,i){var r,s,o,a=0,l="string"==typeof n.getVal(t,0,e);if(t.length)for(;m(r)&&a0&&(r=s,o=t[a]));return o},n.distinct=function(t,e,i){i=!m(i)&&i;var s,r=[],o={};return t.forEach(function(a,l){(s="object"==typeof t[l]?n.getVal(t,l,e):t[l])in o||(r.push(i?t[l]:s),o[s]=1)}),r},n.processData=function(t,e){var i=this.prepareQuery(t),r=new nt(e);t.requiresCounts&&i.requiresCount();var s=r.executeLocal(i),o={result:t.requiresCounts?s.result:s,count:s.count,aggregates:JSON.stringify(s.aggregates)};return t.requiresCounts?o:s},n.prepareQuery=function(t){var e=this,i=new jt;return t.select&&i.select(t.select),t.where&&n.parse.parseJson(t.where).filter(function(o){if(m(o.condition))i.where(o.field,o.operator,o.value,o.ignoreCase,o.ignoreAccent);else{var a=[];o.field?a.push(new Ss(o.field,o.operator,o.value,o.ignoreCase,o.ignoreAccent)):a=a.concat(e.getPredicate(o.predicates)),"or"===o.condition?i.where(Ss.or(a)):"and"===o.condition&&i.where(Ss.and(a))}}),t.search&&n.parse.parseJson(t.search).filter(function(o){return i.search(o.key,o.fields,o.operator,o.ignoreCase,o.ignoreAccent)}),t.aggregates&&t.aggregates.filter(function(o){return i.aggregate(o.type,o.field)}),t.sorted&&t.sorted.filter(function(o){return i.sortBy(o.name,o.direction)}),t.skip&&i.skip(t.skip),t.take&&i.take(t.take),t.group&&t.group.filter(function(o){return i.group(o)}),i},n.getPredicate=function(t){for(var e=[],i=0;i":"greaterthan","<=":"lessthanorequal",">=":"greaterthanorequal","==":"equal","!=":"notequal","*=":"contains","$=":"endswith","^=":"startswith"},n.odBiOperator={"<":" lt ",">":" gt ","<=":" le ",">=":" ge ","==":" eq ","!=":" ne ",lessthan:" lt ",lessthanorequal:" le ",greaterthan:" gt ",greaterthanorequal:" ge ",equal:" eq ",notequal:" ne "},n.odUniOperator={"$=":"endswith","^=":"startswith","*=":"substringof",endswith:"endswith",startswith:"startswith",contains:"substringof",doesnotendwith:"not endswith",doesnotstartwith:"not startswith",doesnotcontain:"not substringof",wildcard:"wildcard",like:"like"},n.odv4UniOperator={"$=":"endswith","^=":"startswith","*=":"contains",endswith:"endswith",startswith:"startswith",contains:"contains",doesnotendwith:"not endswith",doesnotstartwith:"not startswith",doesnotcontain:"not contains",wildcard:"wildcard",like:"like"},n.diacritics={"\u24b6":"A",\uff21:"A",\u00c0:"A",\u00c1:"A",\u00c2:"A",\u1ea6:"A",\u1ea4:"A",\u1eaa:"A",\u1ea8:"A",\u00c3:"A",\u0100:"A",\u0102:"A",\u1eb0:"A",\u1eae:"A",\u1eb4:"A",\u1eb2:"A",\u0226:"A",\u01e0:"A",\u00c4:"A",\u01de:"A",\u1ea2:"A",\u00c5:"A",\u01fa:"A",\u01cd:"A",\u0200:"A",\u0202:"A",\u1ea0:"A",\u1eac:"A",\u1eb6:"A",\u1e00:"A",\u0104:"A",\u023a:"A",\u2c6f:"A",\ua732:"AA",\u00c6:"AE",\u01fc:"AE",\u01e2:"AE",\ua734:"AO",\ua736:"AU",\ua738:"AV",\ua73a:"AV",\ua73c:"AY","\u24b7":"B",\uff22:"B",\u1e02:"B",\u1e04:"B",\u1e06:"B",\u0243:"B",\u0182:"B",\u0181:"B","\u24b8":"C",\uff23:"C",\u0106:"C",\u0108:"C",\u010a:"C",\u010c:"C",\u00c7:"C",\u1e08:"C",\u0187:"C",\u023b:"C",\ua73e:"C","\u24b9":"D",\uff24:"D",\u1e0a:"D",\u010e:"D",\u1e0c:"D",\u1e10:"D",\u1e12:"D",\u1e0e:"D",\u0110:"D",\u018b:"D",\u018a:"D",\u0189:"D",\ua779:"D",\u01f1:"DZ",\u01c4:"DZ",\u01f2:"Dz",\u01c5:"Dz","\u24ba":"E",\uff25:"E",\u00c8:"E",\u00c9:"E",\u00ca:"E",\u1ec0:"E",\u1ebe:"E",\u1ec4:"E",\u1ec2:"E",\u1ebc:"E",\u0112:"E",\u1e14:"E",\u1e16:"E",\u0114:"E",\u0116:"E",\u00cb:"E",\u1eba:"E",\u011a:"E",\u0204:"E",\u0206:"E",\u1eb8:"E",\u1ec6:"E",\u0228:"E",\u1e1c:"E",\u0118:"E",\u1e18:"E",\u1e1a:"E",\u0190:"E",\u018e:"E","\u24bb":"F",\uff26:"F",\u1e1e:"F",\u0191:"F",\ua77b:"F","\u24bc":"G",\uff27:"G",\u01f4:"G",\u011c:"G",\u1e20:"G",\u011e:"G",\u0120:"G",\u01e6:"G",\u0122:"G",\u01e4:"G",\u0193:"G",\ua7a0:"G",\ua77d:"G",\ua77e:"G","\u24bd":"H",\uff28:"H",\u0124:"H",\u1e22:"H",\u1e26:"H",\u021e:"H",\u1e24:"H",\u1e28:"H",\u1e2a:"H",\u0126:"H",\u2c67:"H",\u2c75:"H",\ua78d:"H","\u24be":"I",\uff29:"I",\u00cc:"I",\u00cd:"I",\u00ce:"I",\u0128:"I",\u012a:"I",\u012c:"I",\u0130:"I",\u00cf:"I",\u1e2e:"I",\u1ec8:"I",\u01cf:"I",\u0208:"I",\u020a:"I",\u1eca:"I",\u012e:"I",\u1e2c:"I",\u0197:"I","\u24bf":"J",\uff2a:"J",\u0134:"J",\u0248:"J","\u24c0":"K",\uff2b:"K",\u1e30:"K",\u01e8:"K",\u1e32:"K",\u0136:"K",\u1e34:"K",\u0198:"K",\u2c69:"K",\ua740:"K",\ua742:"K",\ua744:"K",\ua7a2:"K","\u24c1":"L",\uff2c:"L",\u013f:"L",\u0139:"L",\u013d:"L",\u1e36:"L",\u1e38:"L",\u013b:"L",\u1e3c:"L",\u1e3a:"L",\u0141:"L",\u023d:"L",\u2c62:"L",\u2c60:"L",\ua748:"L",\ua746:"L",\ua780:"L",\u01c7:"LJ",\u01c8:"Lj","\u24c2":"M",\uff2d:"M",\u1e3e:"M",\u1e40:"M",\u1e42:"M",\u2c6e:"M",\u019c:"M","\u24c3":"N",\uff2e:"N",\u01f8:"N",\u0143:"N",\u00d1:"N",\u1e44:"N",\u0147:"N",\u1e46:"N",\u0145:"N",\u1e4a:"N",\u1e48:"N",\u0220:"N",\u019d:"N",\ua790:"N",\ua7a4:"N",\u01ca:"NJ",\u01cb:"Nj","\u24c4":"O",\uff2f:"O",\u00d2:"O",\u00d3:"O",\u00d4:"O",\u1ed2:"O",\u1ed0:"O",\u1ed6:"O",\u1ed4:"O",\u00d5:"O",\u1e4c:"O",\u022c:"O",\u1e4e:"O",\u014c:"O",\u1e50:"O",\u1e52:"O",\u014e:"O",\u022e:"O",\u0230:"O",\u00d6:"O",\u022a:"O",\u1ece:"O",\u0150:"O",\u01d1:"O",\u020c:"O",\u020e:"O",\u01a0:"O",\u1edc:"O",\u1eda:"O",\u1ee0:"O",\u1ede:"O",\u1ee2:"O",\u1ecc:"O",\u1ed8:"O",\u01ea:"O",\u01ec:"O",\u00d8:"O",\u01fe:"O",\u0186:"O",\u019f:"O",\ua74a:"O",\ua74c:"O",\u01a2:"OI",\ua74e:"OO",\u0222:"OU","\u24c5":"P",\uff30:"P",\u1e54:"P",\u1e56:"P",\u01a4:"P",\u2c63:"P",\ua750:"P",\ua752:"P",\ua754:"P","\u24c6":"Q",\uff31:"Q",\ua756:"Q",\ua758:"Q",\u024a:"Q","\u24c7":"R",\uff32:"R",\u0154:"R",\u1e58:"R",\u0158:"R",\u0210:"R",\u0212:"R",\u1e5a:"R",\u1e5c:"R",\u0156:"R",\u1e5e:"R",\u024c:"R",\u2c64:"R",\ua75a:"R",\ua7a6:"R",\ua782:"R","\u24c8":"S",\uff33:"S",\u1e9e:"S",\u015a:"S",\u1e64:"S",\u015c:"S",\u1e60:"S",\u0160:"S",\u1e66:"S",\u1e62:"S",\u1e68:"S",\u0218:"S",\u015e:"S",\u2c7e:"S",\ua7a8:"S",\ua784:"S","\u24c9":"T",\uff34:"T",\u1e6a:"T",\u0164:"T",\u1e6c:"T",\u021a:"T",\u0162:"T",\u1e70:"T",\u1e6e:"T",\u0166:"T",\u01ac:"T",\u01ae:"T",\u023e:"T",\ua786:"T",\ua728:"TZ","\u24ca":"U",\uff35:"U",\u00d9:"U",\u00da:"U",\u00db:"U",\u0168:"U",\u1e78:"U",\u016a:"U",\u1e7a:"U",\u016c:"U",\u00dc:"U",\u01db:"U",\u01d7:"U",\u01d5:"U",\u01d9:"U",\u1ee6:"U",\u016e:"U",\u0170:"U",\u01d3:"U",\u0214:"U",\u0216:"U",\u01af:"U",\u1eea:"U",\u1ee8:"U",\u1eee:"U",\u1eec:"U",\u1ef0:"U",\u1ee4:"U",\u1e72:"U",\u0172:"U",\u1e76:"U",\u1e74:"U",\u0244:"U","\u24cb":"V",\uff36:"V",\u1e7c:"V",\u1e7e:"V",\u01b2:"V",\ua75e:"V",\u0245:"V",\ua760:"VY","\u24cc":"W",\uff37:"W",\u1e80:"W",\u1e82:"W",\u0174:"W",\u1e86:"W",\u1e84:"W",\u1e88:"W",\u2c72:"W","\u24cd":"X",\uff38:"X",\u1e8a:"X",\u1e8c:"X","\u24ce":"Y",\uff39:"Y",\u1ef2:"Y",\u00dd:"Y",\u0176:"Y",\u1ef8:"Y",\u0232:"Y",\u1e8e:"Y",\u0178:"Y",\u1ef6:"Y",\u1ef4:"Y",\u01b3:"Y",\u024e:"Y",\u1efe:"Y","\u24cf":"Z",\uff3a:"Z",\u0179:"Z",\u1e90:"Z",\u017b:"Z",\u017d:"Z",\u1e92:"Z",\u1e94:"Z",\u01b5:"Z",\u0224:"Z",\u2c7f:"Z",\u2c6b:"Z",\ua762:"Z","\u24d0":"a",\uff41:"a",\u1e9a:"a",\u00e0:"a",\u00e1:"a",\u00e2:"a",\u1ea7:"a",\u1ea5:"a",\u1eab:"a",\u1ea9:"a",\u00e3:"a",\u0101:"a",\u0103:"a",\u1eb1:"a",\u1eaf:"a",\u1eb5:"a",\u1eb3:"a",\u0227:"a",\u01e1:"a",\u00e4:"a",\u01df:"a",\u1ea3:"a",\u00e5:"a",\u01fb:"a",\u01ce:"a",\u0201:"a",\u0203:"a",\u1ea1:"a",\u1ead:"a",\u1eb7:"a",\u1e01:"a",\u0105:"a",\u2c65:"a",\u0250:"a",\ua733:"aa",\u00e6:"ae",\u01fd:"ae",\u01e3:"ae",\ua735:"ao",\ua737:"au",\ua739:"av",\ua73b:"av",\ua73d:"ay","\u24d1":"b",\uff42:"b",\u1e03:"b",\u1e05:"b",\u1e07:"b",\u0180:"b",\u0183:"b",\u0253:"b","\u24d2":"c",\uff43:"c",\u0107:"c",\u0109:"c",\u010b:"c",\u010d:"c",\u00e7:"c",\u1e09:"c",\u0188:"c",\u023c:"c",\ua73f:"c",\u2184:"c","\u24d3":"d",\uff44:"d",\u1e0b:"d",\u010f:"d",\u1e0d:"d",\u1e11:"d",\u1e13:"d",\u1e0f:"d",\u0111:"d",\u018c:"d",\u0256:"d",\u0257:"d",\ua77a:"d",\u01f3:"dz",\u01c6:"dz","\u24d4":"e",\uff45:"e",\u00e8:"e",\u00e9:"e",\u00ea:"e",\u1ec1:"e",\u1ebf:"e",\u1ec5:"e",\u1ec3:"e",\u1ebd:"e",\u0113:"e",\u1e15:"e",\u1e17:"e",\u0115:"e",\u0117:"e",\u00eb:"e",\u1ebb:"e",\u011b:"e",\u0205:"e",\u0207:"e",\u1eb9:"e",\u1ec7:"e",\u0229:"e",\u1e1d:"e",\u0119:"e",\u1e19:"e",\u1e1b:"e",\u0247:"e",\u025b:"e",\u01dd:"e","\u24d5":"f",\uff46:"f",\u1e1f:"f",\u0192:"f",\ua77c:"f","\u24d6":"g",\uff47:"g",\u01f5:"g",\u011d:"g",\u1e21:"g",\u011f:"g",\u0121:"g",\u01e7:"g",\u0123:"g",\u01e5:"g",\u0260:"g",\ua7a1:"g",\u1d79:"g",\ua77f:"g","\u24d7":"h",\uff48:"h",\u0125:"h",\u1e23:"h",\u1e27:"h",\u021f:"h",\u1e25:"h",\u1e29:"h",\u1e2b:"h",\u1e96:"h",\u0127:"h",\u2c68:"h",\u2c76:"h",\u0265:"h",\u0195:"hv","\u24d8":"i",\uff49:"i",\u00ec:"i",\u00ed:"i",\u00ee:"i",\u0129:"i",\u012b:"i",\u012d:"i",\u00ef:"i",\u1e2f:"i",\u1ec9:"i",\u01d0:"i",\u0209:"i",\u020b:"i",\u1ecb:"i",\u012f:"i",\u1e2d:"i",\u0268:"i",\u0131:"i","\u24d9":"j",\uff4a:"j",\u0135:"j",\u01f0:"j",\u0249:"j","\u24da":"k",\uff4b:"k",\u1e31:"k",\u01e9:"k",\u1e33:"k",\u0137:"k",\u1e35:"k",\u0199:"k",\u2c6a:"k",\ua741:"k",\ua743:"k",\ua745:"k",\ua7a3:"k","\u24db":"l",\uff4c:"l",\u0140:"l",\u013a:"l",\u013e:"l",\u1e37:"l",\u1e39:"l",\u013c:"l",\u1e3d:"l",\u1e3b:"l",\u017f:"l",\u0142:"l",\u019a:"l",\u026b:"l",\u2c61:"l",\ua749:"l",\ua781:"l",\ua747:"l",\u01c9:"lj","\u24dc":"m",\uff4d:"m",\u1e3f:"m",\u1e41:"m",\u1e43:"m",\u0271:"m",\u026f:"m","\u24dd":"n",\uff4e:"n",\u01f9:"n",\u0144:"n",\u00f1:"n",\u1e45:"n",\u0148:"n",\u1e47:"n",\u0146:"n",\u1e4b:"n",\u1e49:"n",\u019e:"n",\u0272:"n",\u0149:"n",\ua791:"n",\ua7a5:"n",\u01cc:"nj","\u24de":"o",\uff4f:"o",\u00f2:"o",\u00f3:"o",\u00f4:"o",\u1ed3:"o",\u1ed1:"o",\u1ed7:"o",\u1ed5:"o",\u00f5:"o",\u1e4d:"o",\u022d:"o",\u1e4f:"o",\u014d:"o",\u1e51:"o",\u1e53:"o",\u014f:"o",\u022f:"o",\u0231:"o",\u00f6:"o",\u022b:"o",\u1ecf:"o",\u0151:"o",\u01d2:"o",\u020d:"o",\u020f:"o",\u01a1:"o",\u1edd:"o",\u1edb:"o",\u1ee1:"o",\u1edf:"o",\u1ee3:"o",\u1ecd:"o",\u1ed9:"o",\u01eb:"o",\u01ed:"o",\u00f8:"o",\u01ff:"o",\u0254:"o",\ua74b:"o",\ua74d:"o",\u0275:"o",\u01a3:"oi",\u0223:"ou",\ua74f:"oo","\u24df":"p",\uff50:"p",\u1e55:"p",\u1e57:"p",\u01a5:"p",\u1d7d:"p",\ua751:"p",\ua753:"p",\ua755:"p","\u24e0":"q",\uff51:"q",\u024b:"q",\ua757:"q",\ua759:"q","\u24e1":"r",\uff52:"r",\u0155:"r",\u1e59:"r",\u0159:"r",\u0211:"r",\u0213:"r",\u1e5b:"r",\u1e5d:"r",\u0157:"r",\u1e5f:"r",\u024d:"r",\u027d:"r",\ua75b:"r",\ua7a7:"r",\ua783:"r","\u24e2":"s",\uff53:"s",\u00df:"s",\u015b:"s",\u1e65:"s",\u015d:"s",\u1e61:"s",\u0161:"s",\u1e67:"s",\u1e63:"s",\u1e69:"s",\u0219:"s",\u015f:"s",\u023f:"s",\ua7a9:"s",\ua785:"s",\u1e9b:"s","\u24e3":"t",\uff54:"t",\u1e6b:"t",\u1e97:"t",\u0165:"t",\u1e6d:"t",\u021b:"t",\u0163:"t",\u1e71:"t",\u1e6f:"t",\u0167:"t",\u01ad:"t",\u0288:"t",\u2c66:"t",\ua787:"t",\ua729:"tz","\u24e4":"u",\uff55:"u",\u00f9:"u",\u00fa:"u",\u00fb:"u",\u0169:"u",\u1e79:"u",\u016b:"u",\u1e7b:"u",\u016d:"u",\u00fc:"u",\u01dc:"u",\u01d8:"u",\u01d6:"u",\u01da:"u",\u1ee7:"u",\u016f:"u",\u0171:"u",\u01d4:"u",\u0215:"u",\u0217:"u",\u01b0:"u",\u1eeb:"u",\u1ee9:"u",\u1eef:"u",\u1eed:"u",\u1ef1:"u",\u1ee5:"u",\u1e73:"u",\u0173:"u",\u1e77:"u",\u1e75:"u",\u0289:"u","\u24e5":"v",\uff56:"v",\u1e7d:"v",\u1e7f:"v",\u028b:"v",\ua75f:"v",\u028c:"v",\ua761:"vy","\u24e6":"w",\uff57:"w",\u1e81:"w",\u1e83:"w",\u0175:"w",\u1e87:"w",\u1e85:"w",\u1e98:"w",\u1e89:"w",\u2c73:"w","\u24e7":"x",\uff58:"x",\u1e8b:"x",\u1e8d:"x","\u24e8":"y",\uff59:"y",\u1ef3:"y",\u00fd:"y",\u0177:"y",\u1ef9:"y",\u0233:"y",\u1e8f:"y",\u00ff:"y",\u1ef7:"y",\u1e99:"y",\u1ef5:"y",\u01b4:"y",\u024f:"y",\u1eff:"y","\u24e9":"z",\uff5a:"z",\u017a:"z",\u1e91:"z",\u017c:"z",\u017e:"z",\u1e93:"z",\u1e95:"z",\u01b6:"z",\u0225:"z",\u0240:"z",\u2c6c:"z",\ua763:"z",\u0386:"\u0391",\u0388:"\u0395",\u0389:"\u0397",\u038a:"\u0399",\u03aa:"\u0399",\u038c:"\u039f",\u038e:"\u03a5",\u03ab:"\u03a5",\u038f:"\u03a9",\u03ac:"\u03b1",\u03ad:"\u03b5",\u03ae:"\u03b7",\u03af:"\u03b9",\u03ca:"\u03b9",\u0390:"\u03b9",\u03cc:"\u03bf",\u03cd:"\u03c5",\u03cb:"\u03c5",\u03b0:"\u03c5",\u03c9:"\u03c9",\u03c2:"\u03c3"},n.fnOperators={equal:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?n.toLowerCase(t)===n.toLowerCase(e):t===e},notequal:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),!n.fnOperators.equal(t,e,i)},lessthan:function(t,e,i){return i?n.toLowerCase(t)n.toLowerCase(e):t>e},lessthanorequal:function(t,e,i){return i?n.toLowerCase(t)<=n.toLowerCase(e):(m(t)&&(t=void 0),t<=e)},greaterthanorequal:function(t,e,i){return i?n.toLowerCase(t)>=n.toLowerCase(e):t>=e},contains:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?!m(t)&&!m(e)&&-1!==n.toLowerCase(t).indexOf(n.toLowerCase(e)):!m(t)&&!m(e)&&-1!==t.toString().indexOf(e)},doesnotcontain:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?!m(t)&&!m(e)&&-1===n.toLowerCase(t).indexOf(n.toLowerCase(e)):!m(t)&&!m(e)&&-1===t.toString().indexOf(e)},isnotnull:function(t){return null!=t},isnull:function(t){return null==t},startswith:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.startsWith(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.startsWith(t,e)},doesnotstartwith:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.notStartsWith(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.notStartsWith(t,e)},like:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.like(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.like(t,e)},isempty:function(t){return void 0===t||""===t},isnotempty:function(t){return void 0!==t&&""!==t},wildcard:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?(t||"boolean"==typeof t)&&e&&"object"!=typeof t&&n.wildCard(n.toLowerCase(t),n.toLowerCase(e)):(t||"boolean"==typeof t)&&e&&n.wildCard(t,e)},endswith:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.endsWith(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.endsWith(t,e)},doesnotendwith:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.notEndsWith(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.notEndsWith(t,e)},processSymbols:function(t){var e=n.operatorSymbols[t];return e?n.fnOperators[e]:n.throwError("Query - Process Operator : Invalid operator")},processOperator:function(t){return n.fnOperators[t]||n.fnOperators.processSymbols(t)}},n.parse={parseJson:function(t){return"string"!=typeof t||!/^[\s]*\[|^[\s]*\{(.)+:/g.test(t)&&-1!==t.indexOf('"')?t instanceof Array?n.parse.iterateAndReviveArray(t):"object"==typeof t&&null!==t&&n.parse.iterateAndReviveJson(t):t=JSON.parse(t,n.parse.jsonReviver),t},iterateAndReviveArray:function(t){for(var e=0;e-1||e.indexOf("z")>-1,o=e.split(/[^0-9.]/);if(s){if(o[5].indexOf(".")>-1){var a=o[5].split(".");o[5]=a[0],o[6]=new Date(e).getUTCMilliseconds().toString()}else o[6]="00";e=n.dateParse.toTimeZone(new Date(parseInt(o[0],10),parseInt(o[1],10)-1,parseInt(o[2],10),parseInt(o[3],10),parseInt(o[4],10),parseInt(o[5]?o[5]:"00",10),parseInt(o[6],10)),n.serverTimezoneOffset,!1)}else{var l=new Date(parseInt(o[0],10),parseInt(o[1],10)-1,parseInt(o[2],10),parseInt(o[3],10),parseInt(o[4],10),parseInt(o[5]?o[5]:"00",10)),h=parseInt(o[6],10),c=parseInt(o[7],10);if(isNaN(h)&&isNaN(c))return l;e.indexOf("+")>-1?l.setHours(l.getHours()-h,l.getMinutes()-c):l.setHours(l.getHours()+h,l.getMinutes()+c),e=n.dateParse.toTimeZone(l,n.serverTimezoneOffset,!1)}null==n.serverTimezoneOffset&&(e=n.dateParse.addSelfOffset(e))}}return e},isJson:function(t){return"string"==typeof t[0]?t:n.parse.parseJson(t)},isGuid:function(t){return null!=/[A-Fa-f0-9]{8}(?:-[A-Fa-f0-9]{4}){3}-[A-Fa-f0-9]{12}/i.exec(t)},replacer:function(t,e){return n.isPlainObject(t)?n.parse.jsonReplacer(t,e):t instanceof Array?n.parse.arrayReplacer(t):t instanceof Date?n.parse.jsonReplacer({val:t},e).val:t},jsonReplacer:function(t,e){for(var i,s=0,o=Object.keys(t);s=0?"+":"-",s=function(a){var l=Math.floor(Math.abs(a));return(l<10?"0":"")+l};return e.getFullYear()+"-"+s(e.getMonth()+1)+"-"+s(e.getDate())+"T"+s(e.getHours())+":"+s(e.getMinutes())+":"+s(e.getSeconds())+r+s(i/60)+":"+s(i%60)}},n}(),bl=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),xK={GroupGuid:"{271bbba0-1ee7}"},t5=function(){function n(t){this.options={from:"table",requestType:"json",sortBy:"sorted",select:"select",skip:"skip",group:"group",take:"take",search:"search",count:"requiresCounts",where:"where",aggregates:"aggregates",expand:"expand"},this.type=n,this.dataSource=t,this.pvt={}}return n.prototype.processResponse=function(t,e,i,r){return t},n}(),VE=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return bl(t,n),t.prototype.processQuery=function(e,i){for(var a,l,p,r=e.dataSource.json.slice(0),s=r.length,o=!0,h={},c=0,d=[],u=[],f=0;f1?e.sort.filter(function(p){return p.fieldName===c})[0]:e.sort[0];s=this.onSortBy(s,d,e.query,!0)}e.page&&(s=this.onPage(s,e.page,e.query)),this.formGroupResult(s,h)}else{for(var o=e.lazyLoad.onDemandGroupInfo,a=o.where.length-1;a>=0;a--)s=this.onWhere(s,o.where[a]);if(e.group.length!==o.level)s=le.group(s,e.group[o.level].fieldName,r,null,null,e.group[o.level].comparer,!0),e.sort.length&&(s=this.onSortBy(s,e.sort[parseInt(o.level.toString(),10)],e.query,!0));else for(a=e.sort.length-1;a>=o.level;a--)s=this.onSortBy(s,e.sort[parseInt(a.toString(),10)],e.query,!1);i=s.length,h=s,s=(s=s.slice(o.skip)).slice(0,o.take),e.group.length!==o.level&&this.formGroupResult(s,h)}return{result:s,count:i}},t.prototype.formGroupResult=function(e,i){if(e.length&&i.length){var r="GroupGuid",s="childLevels",o="level",a="records";e[r]=i[r],e[s]=i[s],e[o]=i[o],e[a]=i[a]}return e},t.prototype.getAggregate=function(e){var i=jt.filterQueries(e.queries,"onAggregates"),r=[];if(i.length)for(var s=void 0,o=0;o=0;l--)a[l]&&(o=i.comparer,le.endsWith(a[l]," desc")&&(o=le.fnSort("descending"),a[l]=a[l].replace(" desc","")),e=le.sort(e,a[l],o));return e}return le.sort(e,s?"key":a,i.comparer)},t.prototype.onGroup=function(e,i,r){if(!e||!e.length)return e;var s=this.getAggregate(r);return le.group(e,le.getValue(i.fieldName,r),s,null,null,i.comparer)},t.prototype.onPage=function(e,i,r){var s=le.getValue(i.pageSize,r),o=(le.getValue(i.pageIndex,r)-1)*s;return e&&e.length?e.slice(o,o+s):e},t.prototype.onRange=function(e,i){return e&&e.length?e.slice(le.getValue(i.start),le.getValue(i.end)):e},t.prototype.onTake=function(e,i){return e&&e.length?e.slice(0,le.getValue(i.nos)):e},t.prototype.onSkip=function(e,i){return e&&e.length?e.slice(le.getValue(i.nos)):e},t.prototype.onSelect=function(e,i){return e&&e.length?le.select(e,le.getValue(i.fieldNames)):e},t.prototype.insert=function(e,i,r,s,o){return m(o)?e.dataSource.json.push(i):e.dataSource.json.splice(o,0,i)},t.prototype.remove=function(e,i,r,s){var a,o=e.dataSource.json;for("object"==typeof r&&!(r instanceof Date)&&(r=le.getObject(i,r)),a=0;a1&&(g="("+g+")"),p.filters.push(g);for(var y=0,S="object"==typeof p.filters[f]?Object.keys(p.filters[f]):[];y-1&&this.formRemoteGroupedData(e[s].items,i+1,r-1);var o="GroupGuid",h="records";return e[o]=xK[o],e.level=i,e.childLevels=r,e[h]=e[0].items.length?this.getGroupedRecords(e,!m(e[0].items[h])):[],e},t.prototype.getGroupedRecords=function(e,i){for(var r=[],o=0;ol.length-3?(l=l.substring(0,l.length-1),o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.endswith:le.odv4UniOperator.endswith):l.lastIndexOf("%")!==l.indexOf("%")&&l.lastIndexOf("%")>l.indexOf("%")+1?(l=l.substring(l.indexOf("%")+1,l.lastIndexOf("%")),o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains):o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains),l="'"+(l=encodeURIComponent(l))+"'";else if("wildcard"===o)if(-1!==l.indexOf("*")){var d=l.split("*"),u=void 0,p=0;if(0!==l.indexOf("*")&&-1===d[0].indexOf("%3f")&&-1===d[0].indexOf("?")&&(u="'"+(u=d[0])+"'",s+=(o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.startswith:le.odv4UniOperator.startswith)+"(",s+=c+",",a&&(s+=a),s+=u+")",p++),l.lastIndexOf("*")!==l.length-1&&-1===d[d.length-1].indexOf("%3f")&&-1===d[d.length-1].indexOf("?")&&(u="'"+(u=d[d.length-1])+"'",p>0&&(s+=" and "),s+=(o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.endswith:le.odv4UniOperator.endswith)+"(",s+=c+",",a&&(s+=a),s+=u+")",p++),d.length>2)for(var f=1;f0&&(s+=" and "),"substringof"===(o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains)||"not substringof"===o){var g=u;u=c,c=g}s+=o+"(",s+=c+",",a&&(s+=a),s+=u+")",p++}0===p?(o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains,(-1!==l.indexOf("?")||-1!==l.indexOf("%3f"))&&(l=-1!==l.indexOf("?")?l.split("?").join(""):l.split("%3f").join("")),l="'"+l+"'"):o="wildcard"}else o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains,(-1!==l.indexOf("?")||-1!==l.indexOf("%3f"))&&(l=-1!==l.indexOf("?")?l.split("?").join(""):l.split("%3f").join("")),l="'"+l+"'";return"substringof"!==o&&"not substringof"!==o||(g=l,l=c,c=g),"wildcard"!==o&&(s+=o+"(",s+=c+",",a&&(s+=a),s+=l+")"),s},t.prototype.addParams=function(e){n.prototype.addParams.call(this,e),delete e.reqParams.params},t.prototype.onComplexPredicate=function(e,i,r){for(var s=[],o=0;o-1;p--)!/\bContent-ID:/i.test(c[p])||!/\bHTTP.+201/.test(c[p])||(l=parseInt(/\bContent-ID: (\d+)/i.exec(c[p])[1],10),o.addedRecords[l]&&(h=le.parse.parseJson(/^\{.+\}/m.exec(c[p])[0]),ze({},o.addedRecords[l],this.processResponse(h))));return o}return null},t.prototype.compareAndRemove=function(e,i,r){var s=this;return m(i)||Object.keys(e).forEach(function(o){o!==r&&"@odata.etag"!==o&&(le.isPlainObject(e[o])?(s.compareAndRemove(e[o],i[o]),0===Object.keys(e[o]).filter(function(l){return"@odata.etag"!==l}).length&&delete e[o]):(e[o]===i[o]||e[o]&&i[o]&&e[o].valueOf()===i[o].valueOf())&&delete e[o])}),e},t}(uc),TK=function(n){function t(){var e=n.call(this)||this;return yt("beforeSend",uc.prototype.beforeSend,e),e}return bl(t,n),t.prototype.insert=function(e,i,r,s,o){return this.pvt.position=o,this.updateType="add",{url:e.dataSource.insertUrl||e.dataSource.crudUrl||e.dataSource.url,data:JSON.stringify(ze({},{value:i,table:r,action:"insert"},le.getAddParams(this,e,s)))}},t.prototype.remove=function(e,i,r,s,o){return n.prototype.remove.call(this,e,i,r),{type:"POST",url:e.dataSource.removeUrl||e.dataSource.crudUrl||e.dataSource.url,data:JSON.stringify(ze({},{key:r,keyColumn:i,table:s,action:"remove"},le.getAddParams(this,e,o)))}},t.prototype.update=function(e,i,r,s,o){return this.updateType="update",this.updateKey=i,{type:"POST",url:e.dataSource.updateUrl||e.dataSource.crudUrl||e.dataSource.url,data:JSON.stringify(ze({},{value:r,action:"update",keyColumn:i,key:r[i],table:s},le.getAddParams(this,e,o)))}},t.prototype.processResponse=function(e,i,r,s,o,a,l){var h;if(e="batch"===(o?JSON.parse(o.data):e).action?le.parse.parseJson(e):e,"add"===this.updateType&&n.prototype.insert.call(this,i,e,null,null,this.pvt.position),"update"===this.updateType&&n.prototype.update.call(this,i,this.updateKey,e),this.updateType=void 0,e.added)for(h=0;hi&&h.push(c)}for(c=0;cthis.pageSize;)h.results.splice(0,1),h.keys.splice(0,1);return window.localStorage.setItem(this.guidId,JSON.stringify(h)),e},t.prototype.beforeSend=function(e,i,r){!m(this.cacheAdaptor.options.batch)&&le.endsWith(r.url,this.cacheAdaptor.options.batch)&&"post"===r.type.toLowerCase()&&i.headers.set("Accept",this.cacheAdaptor.options.multipartAccept),e.dataSource.crossDomain||i.headers.set("Accept",this.cacheAdaptor.options.accept)},t.prototype.update=function(e,i,r,s){return this.isCrudAction=!0,this.cacheAdaptor.update(e,i,r,s)},t.prototype.insert=function(e,i,r){return this.isInsertAction=!0,this.cacheAdaptor.insert(e,i,r)},t.prototype.remove=function(e,i,r,s){return this.isCrudAction=!0,this.cacheAdaptor.remove(e,i,r,s)},t.prototype.batchRequest=function(e,i,r){return this.cacheAdaptor.batchRequest(e,i,r)},t}(uc),nt=function(){function n(t,e,i){var s,r=this;return this.dateParse=!0,this.timeZoneHandling=!0,this.persistQuery={},this.isInitialLoad=!1,this.requests=[],this.isInitialLoad=!0,!t&&!this.dataSource&&(t=[]),i=i||t.adaptor,t&&!1===t.timeZoneHandling&&(this.timeZoneHandling=t.timeZoneHandling),t instanceof Array?s={json:t,offline:!0}:"object"==typeof t?(t.json||(t.json=[]),t.enablePersistence||(t.enablePersistence=!1),t.id||(t.id=""),t.ignoreOnPersist||(t.ignoreOnPersist=[]),s={url:t.url,insertUrl:t.insertUrl,removeUrl:t.removeUrl,updateUrl:t.updateUrl,crudUrl:t.crudUrl,batchUrl:t.batchUrl,json:t.json,headers:t.headers,accept:t.accept,data:t.data,timeTillExpiration:t.timeTillExpiration,cachingPageSize:t.cachingPageSize,enableCaching:t.enableCaching,requestType:t.requestType,key:t.key,crossDomain:t.crossDomain,jsonp:t.jsonp,dataType:t.dataType,offline:void 0!==t.offline?t.offline:!(t.adaptor instanceof TK||t.adaptor instanceof AK||t.url),requiresFormat:t.requiresFormat,enablePersistence:t.enablePersistence,id:t.id,ignoreOnPersist:t.ignoreOnPersist}):le.throwError("DataManager: Invalid arguments"),void 0===s.requiresFormat&&!le.isCors()&&(s.requiresFormat=!!m(s.crossDomain)||s.crossDomain),void 0===s.dataType&&(s.dataType="json"),this.dataSource=s,this.defaultQuery=e,this.dataSource.enablePersistence&&this.dataSource.id&&window.addEventListener("unload",this.setPersistData.bind(this)),s.url&&s.offline&&!s.json.length?(this.isDataAvailable=!1,this.adaptor=i||new up,this.dataSource.offline=!1,this.ready=this.executeQuery(e||new jt),this.ready.then(function(o){r.dataSource.offline=!0,r.isDataAvailable=!0,s.json=o.result,r.adaptor=new VE})):this.adaptor=s.offline?new VE:new up,!s.jsonp&&this.adaptor instanceof up&&(s.jsonp="callback"),this.adaptor=i||this.adaptor,s.enableCaching&&(this.adaptor=new LK(this.adaptor,s.timeTillExpiration,s.cachingPageSize)),this}return Object.defineProperty(n.prototype,"moduleName",{get:function(){return"datamanager"},enumerable:!0,configurable:!0}),n.prototype.getPersistedData=function(t){var e=localStorage.getItem(t||this.dataSource.id);return JSON.parse(e)},n.prototype.setPersistData=function(t,e,i){localStorage.setItem(e||this.dataSource.id,JSON.stringify(i||this.persistQuery))},n.prototype.setPersistQuery=function(t){var e=this,i=this.getPersistedData();if(this.isInitialLoad&&i&&Object.keys(i).length){this.persistQuery=i,this.persistQuery.queries=this.persistQuery.queries.filter(function(s){if(e.dataSource.ignoreOnPersist&&e.dataSource.ignoreOnPersist.length&&s.fn&&e.dataSource.ignoreOnPersist.some(function(l){return s.fn===l}))return!1;if("onWhere"===s.fn){var o=s.e;if(o&&o.isComplex&&o.predicates instanceof Array){var a=o.predicates.map(function(l){if(l.predicates&&l.predicates instanceof Array){var h=l.predicates.map(function(v){return new Ss(v.field,v.operator,v.value,v.ignoreCase,v.ignoreAccent,v.matchCase)});return"and"===l.condition?Ss.and(h):Ss.or(h)}return new Ss(l.field,l.operator,l.value,l.ignoreCase,l.ignoreAccent,l.matchCase)});s.e=new Ss(a[0],o.condition,a.slice(1))}}return!0});var r=ze(new jt,this.persistQuery);return this.isInitialLoad=!1,r}return this.persistQuery=t,this.isInitialLoad=!1,t},n.prototype.setDefaultQuery=function(t){return this.defaultQuery=t,this},n.prototype.executeLocal=function(t){!this.defaultQuery&&!(t instanceof jt)&&le.throwError("DataManager - executeLocal() : A query is required to execute"),this.dataSource.json||le.throwError("DataManager - executeLocal() : Json data is required to execute"),this.dataSource.enablePersistence&&this.dataSource.id&&(t=this.setPersistQuery(t));var e=this.adaptor.processQuery(this,t=t||this.defaultQuery);if(t.subQuery){var i=t.subQuery.fromTable,r=t.subQuery.lookups,s=t.isCountRequired?e.result:e;r&&r instanceof Array&&le.buildHierarchy(t.subQuery.fKey,i,s,r,t.subQuery.key);for(var o=0;oli");P.classList.remove("json-parent");for(var j=0;j',W=ve.children[0].placeholder}return W}function Q(k,W,ve){!m(ve)&&""!==ve&&K(W,ve.split(" ")),!m(k)&&""!==k&&V(W,k.split(" "))}function oe(k,W,ve){if("multiselect"===ve||function Mo(k){if(!k)return!1;for(var W=k;W&&W!==document.body;){if("none"===window.getComputedStyle(W).display)return!1;W=W.parentElement}return!0}(k)){var Te="multiselect"===ve?k:k.clientWidth-parseInt(getComputedStyle(k,null).getPropertyValue("padding-left"),10);!m(W)&&!m(W.getElementsByClassName("e-float-text-content")[0])&&(W.getElementsByClassName("e-float-text-content")[0].classList.contains("e-float-text-overflow")&&W.getElementsByClassName("e-float-text-content")[0].classList.remove("e-float-text-overflow"),(Te0)for(var Ye=0;Ye<_e.length;Ye++)_e[parseInt(Ye.toString(),10)].addEventListener("mousedown",wo,!1),_e[parseInt(Ye.toString(),10)].addEventListener("mouseup",Hl,!1);else if(_e.length>0)for(Ye=0;Ye<_e.length;Ye++)_e[parseInt(Ye.toString(),10)].removeEventListener("mousedown",wo,this),_e[parseInt(Ye.toString(),10)].removeEventListener("mouseup",Hl,this)}function wo(){for(var W=this.parentElement;!W.classList.contains("e-input-group");)W=W.parentElement;!function ya(k,W){!k.classList.contains("e-disabled")&&!k.querySelector("input").readOnly&&W.classList.add("e-input-btn-ripple")}(W,this)}function Hl(){var k=this;setTimeout(function(){k.classList.remove("e-input-btn-ripple")},500)}function fb(k,W){var ve=W("span",{className:k});return ve.classList.add("e-input-group-icon"),ve}function y_(k,W,ve,Te){var _e=m(Te)?mi:Te,Ye=fb(k,_e);W.classList.add("e-float-icon-left");var fi=W.querySelector(".e-input-in-wrap");if(m(fi)){fi=_e("span",{className:"e-input-in-wrap"}),ve.parentNode.insertBefore(fi,ve);var Gs=W.querySelectorAll(ve.tagName+" ~ *");fi.appendChild(ve);for(var Kn=0;Kn-1)if("class"===_e){var Ye=this.getInputValidClassList(k[""+_e]);""!==Ye&&V([W],Ye.split(" "))}else if("style"===_e){var fi=W.getAttribute(_e);fi=m(fi)?k[""+_e]:fi+k[""+_e],W.setAttribute(_e,fi)}else W.setAttribute(_e,k[""+_e])}},n.isBlank=function Hle(k){return!k||/^\s*$/.test(k)}}(Le||(Le={})),new RegExp("^(-)?(\\d*)$"),new RegExp("^[A-Za-z0-9._%+-]{1,}@[A-Za-z0-9._%+-]{1,}([.]{1}[a-zA-Z0-9]{2,}|[.]{1}[a-zA-Z0-9]{2,4}[.]{1}[a-zA-Z0-9]{2,4})$"),new RegExp("^([0-9]{4})-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])$"),new RegExp("^[0-9]*$"),new RegExp("^[+]?[0-9]{9,13}$"),new RegExp("^\\d{13,16}$");var me=function(){function n(t,e){this.width=t,this.height=e}return n.prototype.isEmpty=function(){return 0===this.height&&0===this.width},n.prototype.clone=function(){return new n(this.width,this.height)},n}(),Eie=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),GB=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},z=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Eie(t,n),t.equals=function(e,i){return e===i||!(!e||!i)&&(!e||!i||e.x===i.x&&e.y===i.y)},t.isEmptyPoint=function(e){return!(e.x&&e.y)},t.transform=function(e,i,r){var s={x:0,y:0};return s.x=Math.round(100*(e.x+r*Math.cos(i*Math.PI/180)))/100,s.y=Math.round(100*(e.y+r*Math.sin(i*Math.PI/180)))/100,s},t.findLength=function(e,i){return Math.sqrt(Math.pow(e.x-i.x,2)+Math.pow(e.y-i.y,2))},t.findAngle=function(e,i){var r=Math.atan2(i.y-e.y,i.x-e.x);return r=180*r/Math.PI,(r%=360)<0&&(r+=360),r},t.distancePoints=function(e,i){return Math.sqrt(Math.pow(i.x-e.x,2)+Math.pow(i.y-e.y,2))},t.getLengthFromListOfPoints=function(e){for(var i=0,r=0;ri.y&&!r?o.y+=s:o.y-=s:e.y===i.y?e.xi.x&&!r?o.x+=s:o.x-=s:r?(a=this.findAngle(e,i),o=this.transform(e,a,s)):(a=this.findAngle(i,e),o=this.transform(i,a,s)),o},t.direction=function(e,i){return Math.abs(i.x-e.x)>Math.abs(i.y-e.y)?e.x0)for(var r=0;rt.right||this.top>t.bottom||this.bottom=t.right&&this.top<=t.top&&this.bottom>=t.bottom},n.prototype.containsPoint=function(t,e){return void 0===e&&(e=0),this.left-e<=t.x&&this.right+e>=t.x&&this.top-e<=t.y&&this.bottom+e>=t.y},n.toBounds=function(t){for(var e=new n,i=0,r=t;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},KB=function(n){if(n)switch(n.type){case"Linear":default:return vI;case"Radial":return Rie}return vI},Pie=function(){return function n(t,e,i,r){this.left=t,this.right=e,this.top=i,this.bottom=r}}(),$n=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),it([I(0)],t.prototype,"left",void 0),it([I(0)],t.prototype,"right",void 0),it([I(0)],t.prototype,"top",void 0),it([I(0)],t.prototype,"bottom",void 0),t}(Ee),zie=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),it([I(45)],t.prototype,"angle",void 0),it([I(5)],t.prototype,"distance",void 0),it([I(.7)],t.prototype,"opacity",void 0),it([I("lightgrey")],t.prototype,"color",void 0),t}(Ee),e3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),t.prototype.getClassName=function(){return"Stop"},it([I("")],t.prototype,"color",void 0),it([I(0)],t.prototype,"offset",void 0),it([I(1)],t.prototype,"opacity",void 0),t}(Ee),Ix=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),it([Bt([],e3)],t.prototype,"stops",void 0),it([I("None")],t.prototype,"type",void 0),it([I("")],t.prototype,"id",void 0),t}(Ee),vI=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),it([I(0)],t.prototype,"x1",void 0),it([I(0)],t.prototype,"x2",void 0),it([I(0)],t.prototype,"y1",void 0),it([I(0)],t.prototype,"y2",void 0),t}(Ix),Rie=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),it([I(0)],t.prototype,"cx",void 0),it([I(0)],t.prototype,"cy",void 0),it([I(0)],t.prototype,"fx",void 0),it([I(0)],t.prototype,"fy",void 0),it([I(50)],t.prototype,"r",void 0),t}(Ix),Al=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),it([I("white")],t.prototype,"fill",void 0),it([I("black")],t.prototype,"strokeColor",void 0),it([I("")],t.prototype,"strokeDashArray",void 0),it([I(1)],t.prototype,"strokeWidth",void 0),it([I(1)],t.prototype,"opacity",void 0),it([C0(KB)],t.prototype,"gradient",void 0),t}(Ee),t3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),it([I("transparent")],t.prototype,"fill",void 0),t}(Al),Yp=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),it([I("black")],t.prototype,"color",void 0),it([I("Arial")],t.prototype,"fontFamily",void 0),it([I(12)],t.prototype,"fontSize",void 0),it([I(!1)],t.prototype,"italic",void 0),it([I(!1)],t.prototype,"bold",void 0),it([I("CollapseSpace")],t.prototype,"whiteSpace",void 0),it([I("WrapWithOverflow")],t.prototype,"textWrapping",void 0),it([I("Center")],t.prototype,"textAlign",void 0),it([I("None")],t.prototype,"textDecoration",void 0),it([I("Wrap")],t.prototype,"textOverflow",void 0),it([I("transparent")],t.prototype,"fill",void 0),t}(Al),on=function(n){return n[n.Default=0]="Default",n[n.expandNode=2]="expandNode",n[n.interaction=4]="interaction",n[n.GroupingInProgress=8]="GroupingInProgress",n[n.GroupClipboardInProcess=16]="GroupClipboardInProcess",n[n.ClearObject=32]="ClearObject",n}(on||{}),ri=function(n){return n[n.Visible=1]="Visible",n[n.Hidden=2]="Hidden",n[n.Hover=4]="Hover",n[n.Connect=8]="Connect",n}(ri||{}),Kt=function(n){return n[n.None=0]="None",n[n.ShowHorizontalLines=1]="ShowHorizontalLines",n[n.ShowVerticalLines=2]="ShowVerticalLines",n[n.ShowLines=3]="ShowLines",n[n.SnapToHorizontalLines=4]="SnapToHorizontalLines",n[n.SnapToVerticalLines=8]="SnapToVerticalLines",n[n.SnapToLines=12]="SnapToLines",n[n.SnapToObject=16]="SnapToObject",n[n.All=31]="All",n}(Kt||{}),mr=function(n){return n[n.None=1]="None",n[n.ConnectorSourceThumb=2]="ConnectorSourceThumb",n[n.ConnectorTargetThumb=4]="ConnectorTargetThumb",n[n.ResizeSouthEast=8]="ResizeSouthEast",n[n.ResizeSouthWest=16]="ResizeSouthWest",n[n.ResizeNorthEast=32]="ResizeNorthEast",n[n.ResizeNorthWest=64]="ResizeNorthWest",n[n.ResizeEast=128]="ResizeEast",n[n.ResizeWest=256]="ResizeWest",n[n.ResizeSouth=512]="ResizeSouth",n[n.ResizeNorth=1024]="ResizeNorth",n[n.Rotate=2048]="Rotate",n[n.UserHandle=4096]="UserHandle",n[n.ToolTip=8192]="ToolTip",n[n.ResizeAll=2046]="ResizeAll",n[n.All=16382]="All",n}(mr||{}),qe=function(n){return n[n.None=1]="None",n[n.Select=2]="Select",n[n.Delete=4]="Delete",n[n.Drag=8]="Drag",n[n.DragSourceEnd=16]="DragSourceEnd",n[n.DragTargetEnd=32]="DragTargetEnd",n[n.DragSegmentThumb=64]="DragSegmentThumb",n[n.AllowDrop=128]="AllowDrop",n[n.Bridging=256]="Bridging",n[n.BridgeObstacle=512]="BridgeObstacle",n[n.InheritBridging=1024]="InheritBridging",n[n.PointerEvents=2048]="PointerEvents",n[n.Tooltip=4096]="Tooltip",n[n.InheritTooltip=8192]="InheritTooltip",n[n.Interaction=4218]="Interaction",n[n.ReadOnly=16384]="ReadOnly",n[n.LineRouting=32768]="LineRouting",n[n.InheritLineRouting=65536]="InheritLineRouting",n[n.ConnectToNearByNode=131072]="ConnectToNearByNode",n[n.ConnectToNearByPort=262144]="ConnectToNearByPort",n[n.ConnectToNearByElement=393216]="ConnectToNearByElement",n[n.InheritSegmentThumbShape=524288]="InheritSegmentThumbShape",n[n.InheritSegmentThumbSize=1048576]="InheritSegmentThumbSize",n[n.Default=2043454]="Default",n}(qe||{}),Lr=function(n){return n[n.ReadOnly=2]="ReadOnly",n[n.InheritReadOnly=4]="InheritReadOnly",n[n.Select=8]="Select",n[n.Drag=16]="Drag",n[n.Resize=32]="Resize",n[n.Rotate=64]="Rotate",n[n.Tooltip=128]="Tooltip",n[n.Interaction=120]="Interaction",n[n.None=0]="None",n}(Lr||{}),ie=function(n){return n[n.None=0]="None",n[n.Select=2]="Select",n[n.Drag=4]="Drag",n[n.Rotate=8]="Rotate",n[n.Shadow=16]="Shadow",n[n.PointerEvents=32]="PointerEvents",n[n.Delete=64]="Delete",n[n.InConnect=128]="InConnect",n[n.OutConnect=256]="OutConnect",n[n.Individual=512]="Individual",n[n.Expandable=1024]="Expandable",n[n.AllowDrop=2048]="AllowDrop",n[n.Inherit=78]="Inherit",n[n.ResizeNorthEast=4096]="ResizeNorthEast",n[n.ResizeEast=8192]="ResizeEast",n[n.ResizeSouthEast=16384]="ResizeSouthEast",n[n.ResizeSouth=32768]="ResizeSouth",n[n.ResizeSouthWest=65536]="ResizeSouthWest",n[n.ResizeWest=131072]="ResizeWest",n[n.ResizeNorthWest=262144]="ResizeNorthWest",n[n.ResizeNorth=524288]="ResizeNorth",n[n.Resize=1044480]="Resize",n[n.AspectRatio=1048576]="AspectRatio",n[n.Tooltip=2097152]="Tooltip",n[n.InheritTooltip=4194304]="InheritTooltip",n[n.ReadOnly=8388608]="ReadOnly",n[n.HideThumbs=16777216]="HideThumbs",n[n.AllowMovingOutsideLane=33554432]="AllowMovingOutsideLane",n[n.Default=5240814]="Default",n}(ie||{}),Xr=function(n){return n[n.None=0]="None",n[n.ElementIsPort=2]="ElementIsPort",n[n.ElementIsGroup=4]="ElementIsGroup",n[n.HorizontalLaneHeader=8]="HorizontalLaneHeader",n}(Xr||{}),bt=function(n){return n[n.Rotate=2]="Rotate",n[n.ConnectorSource=4]="ConnectorSource",n[n.ConnectorTarget=8]="ConnectorTarget",n[n.ResizeNorthEast=16]="ResizeNorthEast",n[n.ResizeEast=32]="ResizeEast",n[n.ResizeSouthEast=64]="ResizeSouthEast",n[n.ResizeSouth=128]="ResizeSouth",n[n.ResizeSouthWest=256]="ResizeSouthWest",n[n.ResizeWest=512]="ResizeWest",n[n.ResizeNorthWest=1024]="ResizeNorthWest",n[n.ResizeNorth=2048]="ResizeNorth",n[n.Default=4094]="Default",n}(bt||{}),rt=function(n){return n[n.None=1]="None",n[n.Bridging=2]="Bridging",n[n.UndoRedo=4]="UndoRedo",n[n.Tooltip=8]="Tooltip",n[n.UserInteraction=16]="UserInteraction",n[n.ApiUpdate=32]="ApiUpdate",n[n.PageEditable=48]="PageEditable",n[n.Zoom=64]="Zoom",n[n.PanX=128]="PanX",n[n.PanY=256]="PanY",n[n.Pan=384]="Pan",n[n.ZoomTextEdit=512]="ZoomTextEdit",n[n.Virtualization=1024]="Virtualization",n[n.LineRouting=2048]="LineRouting",n[n.Default=500]="Default",n}(rt||{}),Ci=function(n){return n[n.None=0]="None",n[n.SingleSelect=1]="SingleSelect",n[n.MultipleSelect=2]="MultipleSelect",n[n.ZoomPan=4]="ZoomPan",n[n.DrawOnce=8]="DrawOnce",n[n.ContinuousDraw=16]="ContinuousDraw",n[n.Default=3]="Default",n}(Ci||{}),Ya=function(n){return n[n.Self=1]="Self",n[n.Parent=2]="Parent",n}(Ya||{}),pt=function(n){return n[n.None=0]="None",n[n.Control=1]="Control",n[n.Meta=1]="Meta",n[n.Alt=2]="Alt",n[n.Shift=4]="Shift",n}(pt||{}),Mt=function(n){return n[n.None=null]="None",n[n.Number0=0]="Number0",n[n.Number1=1]="Number1",n[n.Number2=2]="Number2",n[n.Number3=3]="Number3",n[n.Number4=4]="Number4",n[n.Number5=5]="Number5",n[n.Number6=6]="Number6",n[n.Number7=7]="Number7",n[n.Number8=8]="Number8",n[n.Number9=9]="Number9",n[n.A=65]="A",n[n.B=66]="B",n[n.C=67]="C",n[n.D=68]="D",n[n.E=69]="E",n[n.F=70]="F",n[n.G=71]="G",n[n.H=72]="H",n[n.I=73]="I",n[n.J=74]="J",n[n.K=75]="K",n[n.L=76]="L",n[n.M=77]="M",n[n.N=78]="N",n[n.O=79]="O",n[n.P=80]="P",n[n.Q=81]="Q",n[n.R=82]="R",n[n.S=83]="S",n[n.T=84]="T",n[n.U=85]="U",n[n.V=86]="V",n[n.W=87]="W",n[n.X=88]="X",n[n.Y=89]="Y",n[n.Z=90]="Z",n[n.Left=37]="Left",n[n.Up=38]="Up",n[n.Right=39]="Right",n[n.Down=40]="Down",n[n.Escape=27]="Escape",n[n.Space=32]="Space",n[n.PageUp=33]="PageUp",n[n.PageDown=34]="PageDown",n[n.End=35]="End",n[n.Home=36]="Home",n[n.Delete=46]="Delete",n[n.Tab=9]="Tab",n[n.Enter=13]="Enter",n[n.BackSpace=8]="BackSpace",n[n.F1=112]="F1",n[n.F2=113]="F2",n[n.F3=114]="F3",n[n.F4=115]="F4",n[n.F5=116]="F5",n[n.F6=117]="F6",n[n.F7=118]="F7",n[n.F8=119]="F8",n[n.F9=120]="F9",n[n.F10=121]="F10",n[n.F11=122]="F11",n[n.F12=123]="F12",n[n.Star=56]="Star",n[n.Plus=187]="Plus",n[n.Minus=189]="Minus",n[n.BracketLeft=219]="BracketLeft",n[n.BracketRight=221]="BracketRight",n}(Mt||{}),ee=function(n){return n[n.Render=2]="Render",n[n.PublicMethod=4]="PublicMethod",n[n.ToolAction=8]="ToolAction",n[n.UndoRedo=16]="UndoRedo",n[n.TextEdit=32]="TextEdit",n[n.Group=64]="Group",n[n.Clear=128]="Clear",n[n.PreventClearSelection=256]="PreventClearSelection",n[n.Interactions=512]="Interactions",n[n.PreventHistory=1024]="PreventHistory",n[n.PreventIconsUpdate=2048]="PreventIconsUpdate",n[n.PreventCollectionChangeOnDragOver=4096]="PreventCollectionChangeOnDragOver",n[n.PreventZIndexOnDragging=8192]="PreventZIndexOnDragging",n[n.isGroupDragging=16384]="isGroupDragging",n[n.DragUsingMouse=32768]="DragUsingMouse",n[n.DecoratorPropertyChange=65536]="DecoratorPropertyChange",n[n.PreventLaneContainerUpdate=131072]="PreventLaneContainerUpdate",n}(ee||{}),Qa=function(n){return n[n.None=2]="None",n[n.DrawSelectorBorder=4]="DrawSelectorBorder",n[n.PreventRenderSelector=8]="PreventRenderSelector",n}(Qa||{}),$i=function(n){return n[n.None=0]="None",n[n.PreventDrag=2]="PreventDrag",n[n.PreventScale=4]="PreventScale",n[n.PreventDataInit=8]="PreventDataInit",n[n.hScrollbarMoved=16]="hScrollbarMoved",n[n.vScrollbarMoved=32]="vScrollbarMoved",n[n.AnimationClick=64]="AnimationClick",n[n.EnableGroupAction=128]="EnableGroupAction",n[n.PanInProgress=256]="PanInProgress",n[n.OverViewAction=512]="OverViewAction",n}($i||{}),ca=function(n){return n[n.None=0]="None",n[n.PropertyChange=1024]="PropertyChange",n[n.Interaction=2048]="Interaction",n}(ca||{}),Ae=function(n){return n[n.Zero=0]="Zero",n[n.One=1]="One",n[n.Two=2]="Two",n[n.Three=3]="Three",n[n.Four=4]="Four",n[n.Five=5]="Five",n}(Ae||{}),Ce=function(n){return n[n.collectionChange=0]="collectionChange",n[n.rotateChange=1]="rotateChange",n[n.positionChange=2]="positionChange",n[n.propertyChange=3]="propertyChange",n[n.selectionChange=4]="selectionChange",n[n.sizeChange=5]="sizeChange",n[n.drop=6]="drop",n[n.sourcePointChange=7]="sourcePointChange",n[n.targetPointChange=8]="targetPointChange",n[n.connectionChange=9]="connectionChange",n[n.animationComplete=10]="animationComplete",n[n.click=11]="click",n[n.doubleClick=12]="doubleClick",n[n.scrollChange=13]="scrollChange",n[n.dragEnter=14]="dragEnter",n[n.dragLeave=15]="dragLeave",n[n.dragOver=16]="dragOver",n[n.textEdit=17]="textEdit",n[n.paletteSelectionChange=18]="paletteSelectionChange",n[n.historyChange=19]="historyChange",n[n.mouseEnter=20]="mouseEnter",n[n.mouseLeave=21]="mouseLeave",n[n.mouseOver=22]="mouseOver",n[n.expandStateChange=23]="expandStateChange",n[n.segmentCollectionChange=24]="segmentCollectionChange",n[n.commandExecute=25]="commandExecute",n[n.historyStateChange=26]="historyStateChange",n[n.onUserHandleMouseDown=27]="onUserHandleMouseDown",n[n.onUserHandleMouseUp=28]="onUserHandleMouseUp",n[n.onUserHandleMouseEnter=29]="onUserHandleMouseEnter",n[n.onUserHandleMouseLeave=30]="onUserHandleMouseLeave",n[n.onImageLoad=31]="onImageLoad",n[n.onDoBindingInit=32]="onDoBindingInit",n[n.keyUp=33]="keyUp",n[n.keyDown=34]="keyDown",n[n.fixedUserHandleClick=35]="fixedUserHandleClick",n[n.elementDraw=36]="elementDraw",n[n.mouseWheel=37]="mouseWheel",n[n.segmentChange=38]="segmentChange",n[n.onFixedUserHandleMouseDown=39]="onFixedUserHandleMouseDown",n[n.onFixedUserHandleMouseUp=40]="onFixedUserHandleMouseUp",n[n.onFixedUserHandleMouseEnter=41]="onFixedUserHandleMouseEnter",n[n.onFixedUserHandleMouseLeave=42]="onFixedUserHandleMouseLeave",n[n.loaded=43]="loaded",n}(Ce||{}),ni=function(n){return n[n.None=1]="None",n[n.Drag=2]="Drag",n[n.Draw=4]="Draw",n[n.InConnect=8]="InConnect",n[n.OutConnect=16]="OutConnect",n[n.ToolTip=32]="ToolTip",n[n.InheritTooltip=64]="InheritTooltip",n[n.Default=24]="Default",n}(ni||{}),bx=function(n){return n[n.None=1]="None",n[n.Source=2]="Source",n[n.Target=4]="Target",n[n.Intermediate=8]="Intermediate",n[n.All=14]="All",n}(bx||{}),mI=function(n){return n[n.None=0]="None",n[n.SymmetricAngle=2]="SymmetricAngle",n[n.SymmetricDistance=4]="SymmetricDistance",n[n.Default=6]="Default",n}(mI||{}),as=function(){function n(){this.pivot={x:.5,y:.5},this.isDirt=!0,this.isExport=!1,this.exportScaleValue={x:0,y:0},this.exportScaleOffset={x:0,y:0},this.canApplyStyle=!0,this.visible=!0,this.offsetX=0,this.offsetY=0,this.cornerRadius=0,this.minHeight=void 0,this.minWidth=void 0,this.maxWidth=void 0,this.maxHeight=void 0,this.width=void 0,this.height=void 0,this.rotateAngle=0,this.margin={left:0,right:0,top:0,bottom:0},this.connectionDirection="Auto",this.horizontalAlignment="Auto",this.verticalAlignment="Auto",this.flip="None",this.flipMode="All",this.relativeMode="Point",this.transform=Ya.Self|Ya.Parent,this.style={fill:"white",strokeColor:"black",opacity:1,strokeWidth:1},this.desiredSize=new me,this.actualSize=new me,this.parentTransform=0,this.preventContainer=!1,this.isSvgRender=!1,this.bounds=new Ne(0,0,0,0),this.shadow=null,this.description="",this.staticSize=!1,this.shapeType="",this.isRectElement=!1,this.isCalculateDesiredSize=!0,this.flipOffset={x:0,y:0},this.elementActions=Xr.None,this.inversedAlignment=!0,this.position=void 0,this.unitMode=void 0,this.float=!1,this.floatingBounds=void 0}return n.prototype.setOffsetWithRespectToBounds=function(t,e,i){this.unitMode=i,this.position={x:t,y:e}},n.prototype.getAbsolutePosition=function(t){if(void 0!==this.position)return"Absolute"===this.unitMode?this.position:{x:this.position.x*t.width,y:this.position.y*t.height}},Object.defineProperty(n.prototype,"outerBounds",{get:function(){return this.floatingBounds||this.bounds},set:function(t){this.floatingBounds=t},enumerable:!0,configurable:!0}),n.prototype.measure=function(t,e,i){var s=void 0!==this.height?this.height:(t.height||0)-this.margin.top-this.margin.bottom;return this.id&&0===s&&this.elementActions&Xr.HorizontalLaneHeader&&(s=this.actualSize.height),this.desiredSize=new me(void 0!==this.width?this.width:(t.width||0)-this.margin.left-this.margin.right,s),this.isCalculateDesiredSize&&(this.desiredSize=this.validateDesiredSize(this.desiredSize,t)),this.desiredSize},n.prototype.arrange=function(t){return this.actualSize=t,this.updateBounds(),this.actualSize},n.prototype.updateBounds=function(){this.bounds=yr(this)},n.prototype.validateDesiredSize=function(t,e){return this.isRectElement&&!this.width&&!this.minWidth&&!this.maxWidth&&(t.width=50),this.isRectElement&&!this.height&&!this.minHeight&&!this.maxHeight&&(t.height=50),(void 0===t||void 0!==this.width&&void 0!==this.height)&&((t=t||new me).width=void 0===this.width?(e.width||0)-this.margin.left-this.margin.right:this.width,t.height=void 0===this.height?(e.height||0)-this.margin.top-this.margin.bottom:this.height),void 0!==this.minWidth&&(t.width=Math.max(t.width,this.minWidth)),void 0!==this.minHeight&&(t.height=Math.max(t.height,this.minHeight)),void 0!==this.maxWidth&&0!==this.maxWidth&&(t.width=Math.min(t.width,this.maxWidth)),void 0!==this.maxHeight&&0!==this.maxHeight&&(t.height=Math.min(t.height,this.maxHeight)),t},n}(),Vie=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Cs=function(n){function t(){var e=null!==n&&n.apply(this,arguments)||this;return e.padding=new Pie(0,0,0,0),e.desiredBounds=void 0,e.measureChildren=!0,e.prevRotateAngle=0,e}return Vie(t,n),t.prototype.hasChildren=function(){return void 0!==this.children&&this.children.length>0},t.prototype.measure=function(e,i,r){this.desiredBounds=void 0;var o,a,s=void 0;if(this.hasChildren()){for(var l=0;l=n.width&&s.length>0)i[i.length]={text:s,x:0,dy:0,width:o},s="";else{(s+=a[r+1]||"").indexOf("\n")>-1&&(i[i.length]={text:s,x:0,dy:0,width:Bc(s,n)},s="");var l=Bc(s,n);Math.ceil(l)+2>=n.width&&s.length>0&&(i[i.length]={text:s,x:0,dy:0,width:l},s=""),r===a.length-1&&s.length>0&&(i[i.length]={text:s,x:0,dy:0,width:l},s="")}else i=function loe(n,t,e){var c,d,u,p,i=[],r="",s=0,o=0,a="nowrap"!==n.whiteSpace,h=(t||n.content).split("\n");for(s=0;s0?" ":"")+c[parseInt(o.toString(),10)];var f=Bc(d=c[o+1]?r+" "+c[o+1]:r,n);Math.floor(f)>(e||n.width)-2&&r.length>0?(i[i.length]={text:r,x:0,dy:0,width:d===r?f:r===p?u:Bc(r,n)},r=""):o===c.length-1&&(i[i.length]={text:r,x:0,dy:0,width:f},r=""),p=d,u=f}return i}(n,t,e);else i[i.length]={text:a,x:0,dy:0,width:Bc(a,n)};return i}(l,r,n.isLaneOrientation?i:void 0),n.wrapBounds=a=function hoe(n,t){var r,s,e={x:0,width:0},i=0;for(i=0;in.width&&("Ellipsis"===n.textOverflow||"Clip"===n.textOverflow)?0:-r/2:"right"===n.textAlign?-r:t.length>1?0:-r/2,t[parseInt(i.toString(),10)].dy=1.2*n.fontSize,t[parseInt(i.toString(),10)].x=r,e.x=Math.min(e.x,r),e.width=Math.max(e.width,s);return e}(l,o),s.width=a.width,n.wrapBounds.width>=i&&"Wrap"!==l.textOverflow&&(s.width=i),s.height=o.length*n.style.fontSize*1.2,s}(this,0,0,this.isLaneOrientation?e.height:this.width||e.width):this.desiredSize,this.desiredSize=void 0===this.width||void 0===this.height?new me(i.width,i.height):new me(this.width,this.height),this.desiredSize=this.validateDesiredSize(this.desiredSize,e),this.desiredSize},t.prototype.arrange=function(e){return(e.width!==this.actualSize.width||e.height!==this.actualSize.height||this.isDirt)&&(this.doWrap=!0),this.actualSize=e,this.updateBounds(),this.isDirt=!1,this.actualSize},t}(as),Yie=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Ii=function(n){function t(){var e=null!==n&&n.apply(this,arguments)||this;return e.measureChildren=void 0,e}return Yie(t,n),t.prototype.measure=function(e,i,r){var s=void 0,o=void 0;if(this.hasChildren()){for(var a=0,l=this.children;a=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Ed=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return $ie(t,n),Th([I("")],t.prototype,"content",void 0),Th([I("TopLeft")],t.prototype,"position",void 0),Th([I("Mouse")],t.prototype,"relativeMode",void 0),Th([I(!0)],t.prototype,"showTipPointer",void 0),Th([I("auto")],t.prototype,"width",void 0),Th([I("auto")],t.prototype,"height",void 0),Th([I("Auto")],t.prototype,"openOn",void 0),Th([I()],t.prototype,"animation",void 0),Th([I(!1)],t.prototype,"isSticky",void 0),t}(Ee);function i3(n){var t=new mh;t=r3(n.tooltip,t);var e=new mh(t);return e.beforeCollision=Jie,e.beforeOpen=Zie,e.cssClass="e-diagram-tooltip",e.opensOn="custom",e.appendTo("#"+n.element.id),e.close(),e}function Zie(n){(""===this.content||void 0===this.content)&&(n.element.style.display="none")}function Jie(n){n.collidedPosition&&n.collidedPosition!==this.position&&(n.element.style.display="none")}function Mx(n,t){var e=n.tooltipObject;return r3(t?t.tooltip:n.tooltip,e),e}function r3(n,t){return n.content?(t.content=n.content,"string"==typeof n.content&&(t.content=ko(function(){return n.content})),t.position=n.position,t.showTipPointer=n.showTipPointer,t.width=n.width,t.height=n.height,t.animation=n.animation?n.animation:{close:{effect:"None"}}):t.close(),t}var wx=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Hn=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Cx=function(n){function t(e,i,r,s){var o=n.call(this,e,i,r,s)||this;return o.inEdges=[],o.outEdges=[],o}return wx(t,n),Hn([I("")],t.prototype,"id",void 0),Hn([I("Center")],t.prototype,"horizontalAlignment",void 0),Hn([I("Center")],t.prototype,"verticalAlignment",void 0),Hn([re({},$n)],t.prototype,"margin",void 0),Hn([I(12)],t.prototype,"width",void 0),Hn([I(12)],t.prototype,"height",void 0),Hn([re({},Al)],t.prototype,"style",void 0),Hn([I("Square")],t.prototype,"shape",void 0),Hn([I("Auto")],t.prototype,"connectionDirection",void 0),Hn([I(ri.Connect)],t.prototype,"visibility",void 0),Hn([I("")],t.prototype,"pathData",void 0),Hn([I(ni.Default)],t.prototype,"constraints",void 0),Hn([I()],t.prototype,"addInfo",void 0),Hn([I()],t.prototype,"outEdges",void 0),Hn([I()],t.prototype,"inEdges",void 0),Hn([re({},Ed)],t.prototype,"tooltip",void 0),t}(Ee),Es=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return wx(t,n),t.prototype.getClassName=function(){return"PointPort"},Hn([re({x:.5,y:.5},z)],t.prototype,"offset",void 0),t}(Cx),xc=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return wx(t,n),t.prototype.getClassName=function(){return"PathPort"},Hn([I(.5)],t.prototype,"offset",void 0),Hn([re({x:0,y:0},z)],t.prototype,"displacement",void 0),Hn([I("Center")],t.prototype,"alignment",void 0),t}(Cx),II=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),lr=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Kie=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return II(t,n),lr([I("blue")],t.prototype,"color",void 0),lr([I("")],t.prototype,"content",void 0),lr([I("")],t.prototype,"link",void 0),lr([I("None")],t.prototype,"textDecoration",void 0),lr([I("NewTab")],t.prototype,"hyperlinkOpenState",void 0),t}(Ee),Ex=function(n){function t(e,i,r,s){var o=n.call(this,e,i,r,s)||this;return r.id||(o.id=e.parentObj&&e.parentObj.propName&&"phases"===e.parentObj.propName?e.parentObj.id:Qe()),o}return II(t,n),lr([I("")],t.prototype,"content",void 0),lr([I(void 0)],t.prototype,"template",void 0),lr([I("String")],t.prototype,"annotationType",void 0),lr([I(!0)],t.prototype,"visibility",void 0),lr([I(Lr.InheritReadOnly)],t.prototype,"constraints",void 0),lr([re(void 0,Kie)],t.prototype,"hyperlink",void 0),lr([I("")],t.prototype,"id",void 0),lr([I()],t.prototype,"width",void 0),lr([I()],t.prototype,"height",void 0),lr([I(0)],t.prototype,"rotateAngle",void 0),lr([I("Parent")],t.prototype,"rotationReference",void 0),lr([re({strokeWidth:0,strokeColor:"transparent",fill:"transparent"},Yp)],t.prototype,"style",void 0),lr([I("Center")],t.prototype,"horizontalAlignment",void 0),lr([I("Center")],t.prototype,"verticalAlignment",void 0),lr([re({},$n)],t.prototype,"margin",void 0),lr([re({top:void 0,bottom:void 0,left:void 0,right:void 0},$n)],t.prototype,"dragLimit",void 0),lr([I("Shape")],t.prototype,"type",void 0),lr([re({},Ed)],t.prototype,"tooltip",void 0),lr([I()],t.prototype,"addInfo",void 0),t}(Ee),Zn=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return II(t,n),t.prototype.getClassName=function(){return"ShapeAnnotation"},lr([re({x:.5,y:.5},z)],t.prototype,"offset",void 0),t}(Ex),Nr=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return II(t,n),t.prototype.getClassName=function(){return"PathAnnotation"},lr([I(.5)],t.prototype,"offset",void 0),lr([re({x:0,y:0},z)],t.prototype,"displacement",void 0),lr([I("Center")],t.prototype,"alignment",void 0),lr([I(!1)],t.prototype,"segmentAngle",void 0),t}(Ex);function Dx(n){return rre[n.toString()]}function n3(n){return ore[""+n]}var rre={X:"M14,14 L106,106 M106,14 L14,106",Circle:"M0,50 A50,50,0 1 1 100,50 A50,50,0 1 1 0,50 Z",Square:"M0,0 L10,0 L10,10 L0,10 z"},nre={OpenArrow:"M15.9,23 L5,16 L15.9,9 L17,10.7 L8.7,16 L17,21.3Z",Square:"M0,0 L10,0 L10,10 L0,10 z",Fletch:"M14.8,10c0,0-3.5,6,0.2,12c0,0-2.5-6-10.9-6C4.1,16,11.3,16,14.8,10z",OpenFetch:"M6,17c-0.6,0-1-0.4-1-1s0.4-1,1-1c10.9,0,11-5,11-5c0-0.6,0.4-1,1-1s1,0.4,1,1C19,10.3,18.9,17,6,17C6,17,6,17,6,17z M18,23c-0.5,0-1-0.4-1-1c0-0.2-0.3-5-11-5c-0.6,0-1-0.5-1-1s0.4-1,1-1c0,0,0,0,0,0c12.9,0,13,6.7,13,7 C19,22.6,18.6,23,18,23z",IndentedArrow:"M17,10c0,0-4.5,5.5,0,12L5,16L17,10z",OutdentedArrow:"M14.6,10c0,0,5.4,6,0,12L5,16L14.6,10z",DoubleArrow:"M19,10 L19,22 L13,16Z M12,10 L12,22 L6,16Z",Arrow:"M15,10 L15,22 L5,16Z",Diamond:"M12,23l-7-7l7-7l6.9,7L12,23z",Circle:"M0,50 A50,50,0 1 1 100,50 A50,50,0 1 1 0,50 Z"},sre={Square:"M0,0 L10,0 L10,10 L0,10 z",Rhombus:"M10,5 L5,10 L0,5 L5,0 L10,5 Z ",Rectangle:"M0,0 L15,0 L15,10 L0,10 z ",OpenArrow:"M15.9,23 L5,16 L15.9,9 L17,10.7 L8.7,16 L17,21.3Z",Fletch:"M9.82,0 C9.82,0,6.61,5,10,10 C10,10,7.71,5,0,5 C0,5,6.61,5,9.82,0 Z ",OpenFetch:"M0.71,5.71 C0.29,5.71,0,5.43,0,5 C0,4.57,0.29,4.29,0.71,4.29 C8.5,4.29,8.57,0.71,8.57,0.71 C8.57,0.29,8.86,0,9.29,0 C9.719999999999999,0,10,0.29,10,0.71 C10,0.93,9.93,5.71,0.71,5.71 C0.71,5.71,0.71,5.71,0.71,5.71 Z M9.29,10 C8.93,10,8.57,9.71,8.57,9.29 C8.57,9.14,8.36,5.71,0.71,5.71 C0.29,5.71,0,5.36,0,5 C0,4.64,0.29,4.29,0.71,4.29 C0.71,4.29,0.71,4.29,0.71,4.29 C9.93,4.29,10,9.07,10,9.29 C10,9.71,9.71,10,9.29,10 Z ",IndentedArrow:"M10,0 C10,0,6.25,4.58,10,10 L0,5 L10,0 Z ",OutdentedArrow:"M8,0 C8,0,12.5,5,8,10 L0,5 L8,0 Z ",DoubleArrow:"M19,10 L19,22 L13,16Z M12,10 L12,22 L6,16Z",Arrow:"M15,10 L15,22 L5,16Z",Diamond:"M10,5 L5,10 L0,5 L5,0 L10,5 Z ",Circle:"M10,5 C10,7.76,7.76,10,5,10 C2.24,10,0,7.76,0,5 C0,2.24,2.24,0,5,0 C7.76,0,10,2.24,10,5 Z ",Ellipse:"M15,5 C15,7.76,11.64,10,7.5,10 C3.36,10,0,7.76,0,5 C0,2.24,3.36,0,7.5,0 C11.64,0,15,2.24,15,5 Z "},ore={Square:"M0,0 L10,0 L10,10 L0,10 z",Rhombus:"M10,5 L5,10 L0,5 L5,0 L10,5 Z ",Rectangle:"M0,0 L15,0 L15,10 L0,10 z",OpenArrow:"M23,15.9 L16,5 L9,15.9 L10.7,17 L16,8.7 L21,17.3Z",Fletch:"M9.82,0 C9.82,0,6.61,5,10,10 C10,10,7.71,5,0,5 C0,5,6.61,5,9.82,0 Z ",OpenFetch:"M0.71,5.71 C0.29,5.71,0,5.43,0,5 C0,4.57,0.29,4.29,0.71,4.29 C8.5,4.29,8.57,0.71,8.57,0.71 C8.57,0.29,8.86,0,9.29,0 C9.719999999999999,0,10,0.29,10,0.71 C10,0.93,9.93,5.71,0.71,5.71 C0.71,5.71,0.71,5.71,0.71,5.71 Z M9.29,10 C8.93,10,8.57,9.71,8.57,9.29 C8.57,9.14,8.36,5.71,0.71,5.71 C0.29,5.71,0,5.36,0,5 C0,4.64,0.29,4.29,0.71,4.29 C0.71,4.29,0.71,4.29,0.71,4.29 C9.93,4.29,10,9.07,10,9.29 C10,9.71,9.71,10,9.29,10 Z ",IndentedArrow:"M10,0 C10,0,6.25,4.58,10,10 L0,5 L10,0 Z ",OutdentedArrow:"M8,0 C8,0,12.5,5,8,10 L0,5 L8,0 Z ",DoubleArrow:"M10,19 L22,19 L16,13Z M10,12 L22,12 L16,6Z",Arrow:"M10,15 L22,15 L16,5Z",Diamond:"M10,5 L5,10 L0,5 L5,0 L10,5 Z ",Circle:"M10,5 C10,7.76,7.76,10,5,10 C2.24,10,0,7.76,0,5 C0,2.24,2.24,0,5,0 C7.76,0,10,2.24,10,5 Z ",Ellipse:"M15,5 C15,7.76,11.64,10,7.5,10 C3.36,10,0,7.76,0,5 C0,2.24,3.36,0,7.5,0 C11.64,0,15,2.24,15,5 Z "};function xx(n){return are[n.toString()]}var are={Process:"M419.511,76.687L359.511,76.687L359.511,43.086L419.511,43.086z",Decision:"M 253.005,115.687L 200.567,146.071L 148.097,115.687L 200.534,85.304L 253.005,115.687 Z",Document:"M 60 31.9 c 0 0 -11 -7.7 -30 0 s -30 0 -30 0 V 0 h 60 V 31.9 Z",PreDefinedProcess:"M 0,0 L 50,0 L 50,50 L 0,50 Z M 8.334,0 L 8.334,50 M 41.667,0 L 41.667,50",Terminator:"M 269.711,29.33C 269.71,44.061 257.77,56 243.04,56L 158.058,56C 143.33,56 131.39,44.061 131.39,29.33L 131.39,29.33C 131.391,14.6057 143.33,2.669 158.058,2.669L 243.044,2.669C 257.772,2.669 269.711,14.6057 269.711,29.333 Z",PaperTap:"M0.0009,17.2042 L0.0009,47.165 C0.001,47.165 14.403,53.5455 25.00,47.165 C35.599,40.7852 44.403,43.5087 50.00,47.165L50.001,17.2042 M50.001,32.7987 L50.001,2.8405 C50.001,2.8405 35.599,-3.5427 25.001,2.8405C14.403,9.2237 5.599,6.494 0.0009,2.8405 L0.0009,32.7987",DirectData:"M 132.62 0 L 17.38 0 C 7.78 0 0 13.43 0 30 C 0 46.57 7.78 60 17.38 60 L 132.62 60 M 132.62 0C 123.02 0 115.24 13.43 115.24 30 C 115.24 46.57 123.02 60 132.62 60 C 142.22 60 150 46.57 150 30 C 150 13.43 142.22 0 132.62 0 z ",SequentialData:"M0.0029,24.999 C0.0029,11.1922 10.433,0.0021 23.295,0.0021 C36.159,0.00216 46.585,11.1922 46.585,24.999C46.585,38.8057 36.159,49.9979 23.295,49.9979 C10.433,49.9979 0.0029,38.8057 0.0029,24.999 z M23.294,49.999 L50.002,49.999",Sort:"M50.001,24.9971 L25.001,49.9971 L0.00097,24.9971 L25.001,-0.00286865 L50.001,24.9971 z M0.000976562,24.9971 L50.001,24.9971",MultiDocument:"M43.6826,40 C44.8746,40.6183 45.8586,41.3502 46.8366,42.1122 L46.8366,4.74487 L3.09857,4.74487 L3.09857,10.9544 M46.837,35.143 C48.027,35.765 49.025,36.604 50.003,37.369 L50.003,0.002 L6.264,0.002 L6.264,4.744 M43.682,47.113 L43.682,10.765 L0.0025,10.7652 L0.0025,47.1132 C0.0025,47.1132 12.5846,53.6101 21.8426,47.1132 C31.1006,40.6163 38.792,43.393 43.6826,47.1132 z",Collate:"M50.001,0.0028 L25.001,25.0029 L0.00097,0.0028 L50.001,0.002 z M0.0009,50.002 L25.001,25.002L50.001,50.002 L0.0009,50.0029 z",SummingJunction:"M7.3252,42.6768 L42.6772,7.3247 M42.6768,42.6768 L7.3248,7.3247 M0.0009,25.001 C0.0009,11.193 11.197,0.0009 25.001,0.0009 C38.809,0.0009 50.001,11.193 50.001,25.001 C50.001,38.809 38.809,50.001 25.001,50.001 C11.197,50.00 0.0009,38.809 0.0009,25.00 z",Or:"M 0 50 L 100 50 M 50 100 L 50 0.0 M 0 50 C 0 22.384 22.392 0 50 0 C 77.616 0 100 22.384 100 50 C 100 77.616 77.616 100 50 100 C 22.392 100 0 77.616 0 50 Z",InternalStorage:"M 0 3.81946A 2.5,3.81946 0 0,1 2.5,0L 47.5 0A 2.5,3.81946 0 0,1 50,3.81946L 50 45.836A 2.5,3.819446 0 0,1 47.5,49.652778L 2.5 49.652778A 2.5,3.819446 0 0,1 0,45.8336L 0 3.819446ZM 0 11.45834L 50 11.4583334M 12.5 0L 12.5 49.652778",Extract:"M0,35 L30,0 L60,35 Z",ManualOperation:"M46.4,28.8 L14.8,28.8 L0,0 L60,0 Z",Merge:"M60,0 L30,35 L0,0 Z",OffPageReference:"M60,33.3 L30.1,39 L0,33.3 L0,0 L60,0 Z",SequentialAccessStorage:"M 60 30 C 60 13.4 46.6 0 30 0 S 0 13.4 0 30 s 13.4 30 30 30 h 28.6 v -6.5 h -9.9C 55.5 48 60 39.5 60 30 Z",Annotation:"M49.9984,50.0029 L-0.00271199,50.0029 L-0.00271199,0.00286865 L49.9984,0.00286865",Annotation2:"M49.9977,50.0029 L25.416,50.0029 L25.416,0.00286865 L49.9977,0.00286865 M25.4166,25.0029 L-0.00227869,25.0029",Data:"M 10 0 L 40 0 L 30 40 L 0 40 Z",Card:"M275,60 L400,60 L400,110 L260,110 L260,75 Z",Delay:"M0,0 L12.029,0 C14.212999,0 16,1.7869979 16,3.9709952 C16,6.1549926 14.212999,7.9409904 12.029,7.9409904 L0,7.9409904 z",Preparation:"M 1048.17 572 C 1051.06 568.86 1055.17 567.05 1059.5 567 L 1094.51 567 C 1098.84 567.05 1102.95 568.86 1105.84 572 L 1126.43 595 C 1127.01 596.28 1127.01 597.72 1126.43 599 L 1105.84 622 C 1102.95 625.14 1098.84 626.95 1094.51 627 L 1059.5 627 C 1055.17 626.95 1051.06 625.14 1048.17 622 L 1027.58 599 C 1027 597.72 1027 596.28 1027.58 595 L 1048.17 572 Z",Display:"M47.8809,19.2914 L32.7968,-0.00594145 L11.3902,-0.00594145 C7.93166,-0.00594145 0.00124586,11.187 0.00124586,24.9968C0.00124586,38.8032 7.93166,49.9962 11.3902,49.9962 L32.7968,49.99 L47.615,31.038 C47.615,31.0388 52.798,24.9968 47.880,19.2914 z",ManualInput:"M 912 732 L 1006.85 707 C 1008.2 707 1009.5 707.53 1010.46 708.46 C 1011.41 709.4 1011.95 710.67 1011.95 712 L 1011.95 762C 1012 764.41 1010.28 766.52 1007.87 767 L 917.1 767 C 915.75 767 914.45 766.47 913.49 765.54 C 912.54 764.6 912 763.33 912 762 L 912 732 Z",LoopLimit:"M 8 9 L 27 9 L 33 15 L 33 26 C 33 27 33 27 32 27 L 4 27 C 3 27 2 27 2 26 L 2 15 L 8 9 Z",StoredData:"M 5.55 0L 50 0A 1.5,30 0 0,1 50,0A 5.555,25 0 0,0 50,50A 1.5,30 0 0,1 50,50L 5.555 50A 5.55,25 0 0,1 5.555,0Z"};function s3(n,t,e){var i;i="Straight"!==n.type&&n.sourceWrapper?n.sourceWrapper.corners.center:function lre(n){var t;if(n.sourcePortWrapper){var e=n.sourcePortWrapper;t={x:e.offsetX,y:e.offsetY}}else t=n.sourceID&&n.sourceWrapper&&n.targetWrapper?Ah(n,0,n.sourceWrapper.corners.center,n.targetWrapper.corners.center,!1):n.sourcePoint;return t}(n);var r=function cre(n,t,e,i,r){var b,M,s=n.sourceWrapper,o=n.targetWrapper,a=n.sourcePortWrapper,l=n.targetPortWrapper,d=[],f=Ga(n),y={corners:undefined,point:t,direction:undefined,margin:{left:5,right:5,bottom:5,top:5}},S={corners:undefined,point:e,direction:undefined,margin:{left:5,right:5,bottom:5,top:5}};if(void 0!==s&&void 0!==o&&(b=En(s),M=En(o),y.corners=s.corners,S.corners=o.corners),void 0!==a&&(y.direction="Left"===a.connectionDirection||"Top"===a.connectionDirection||"Bottom"===a.connectionDirection||"Right"===a.connectionDirection?a.connectionDirection:zo({x:a.offsetX,y:a.offsetY},b,s.bounds)),void 0!==l&&(S.direction="Left"===l.connectionDirection||"Right"===l.connectionDirection||"Bottom"===l.connectionDirection||"Top"===l.connectionDirection?l.connectionDirection:zo({x:l.offsetX,y:l.offsetY},M,o.bounds)),"Bezier"===n.type&&!n.isBezierEditing&&n.segments.length>0)for(var D=n.segments.length-1;D>=0;)n.segments[parseInt(D.toString(),10)].isInternalSegment&&n.segments.pop(),D--;if(void 0!==s&&void 0!==o)return(void 0===y.direction||void 0===S.direction)&&(i?function hre(n,t,e){"LeftToRight"===e?(n.direction=n.direction?n.direction:"Right",t.direction=t.direction?t.direction:"Left"):"RightToLeft"===e?(n.direction=n.direction?n.direction:"Left",t.direction=t.direction?t.direction:"Right"):"TopToBottom"===e?(n.direction=n.direction?n.direction:"Bottom",t.direction=t.direction?t.direction:"Top"):"BottomToTop"===e&&(n.direction=n.direction?n.direction:"Top",t.direction=t.direction?t.direction:"Bottom")}(y,S,i):y.corners.top>S.corners.bottom&&Math.abs(y.corners.top-S.corners.bottom)>f?(y.direction=y.direction?y.direction:"Top",S.direction=S.direction?S.direction:"Bottom"):y.corners.bottomf?(y.direction=y.direction?y.direction:"Bottom",S.direction=S.direction?S.direction:"Top"):y.corners.rightf||y.corners.right+f=y.corners.left-f&&y.corners.left>S.corners.left?(y.direction=y.direction?y.direction:"Right",S.direction=S.direction?S.direction:"Left"):y.corners.left>S.corners.right&&Math.abs(y.corners.left-S.corners.right)>y.margin.left+y.margin.right||S.corners.right+f=S.corners.left-f&&y.corners.left0&&n.segments[0].direction&&(y.direction=n.segments[0].direction),y.point=Tc(b,y.direction),d=Tc(b,ls(y.direction)),y.point=Ah(n,0,y.point,d,!1)):y.point=o.corners.center;if(void 0!==h){switch(S.point={x:h.offsetX,y:h.offsetY},S.direction){case"Bottom":case"Top":S.point.y=S.point.y;break;case"Left":case"Right":S.point.x=S.point.x}n.targetPadding&&!w&&(S.point=bI(n,y,S,!0))}else"Orthogonal"===n.type||"Bezier"===n.type?(S.point=Tc(M,S.direction),d=Tc(M,ls(S.direction)),S.point=Ah(n,0,S.point,d,!0)):S.point=a.corners.center;if("Orthogonal"!==n.type){var C=void 0,D=void 0;if("Bezier"===n.type){if(n.bezierSettings.allowSegmentsReset||0===n.segments.length||!z.isEmptyPoint(n.segments[n.segments.length-1].point))return c=g3(n,y,S,void 0,s),Tx(n,y,S);Bv(n)}else Bv(n);if(void 0===n.sourcePortWrapper){y.point=y.corners.center,n.segments&&n.segments.length>0&&(C=z.isEmptyPoint((D=n.segments[0]).point)?void 0:D);var A=void 0!==C?C.point:S.point;if("Bezier"===n.type&&n.segments.length>0&&n.segments[0].vector1.angle&&n.segments[0].vector1.distance){var x=Math.max(y.corners.width,y.corners.height);A=z.transform(y.point,n.segments[0].vector1.angle,x/2)}y.point=w?n.sourceWrapper.bounds.center:Ah(n,0,y.point,A,!1)}if(void 0===n.targetPortWrapper){S.point=S.corners.center,n.segments&&n.segments.length>1&&(C=z.isEmptyPoint((D=n.segments[n.segments.length-2]).point)?void 0:D);var R=C?C.point:y.point;"Bezier"===n.type&&n.segments.length>0&&n.segments[n.segments.length-1].vector2.angle&&n.segments[n.segments.length-1].vector2.distance&&(x=Math.max(y.corners.width,y.corners.height),R=z.transform(S.point,n.segments[0].vector2.angle,x/2)),S.point=w?n.targetWrapper.bounds.center:Ah(n,0,R,S.point,!0)}c=Tx(n,y,S)}else"Orthogonal"===n.type&&n.segments&&n.segments.length>0&&null!==n.segments[0].direction?c=function Ire(n,t,e,i,r,s,o){var a,h,c,d;Bv(n);for(var u=0;u0&&n.segments[u-1].direction===h.direction?u=u3(n,u,t):h.direction?t.point=o3(t,n.segments[parseInt(u.toString(),10)]):(p=n.segments[u-1])&&p.points&&(t.point=p.points[p.points.length-1]),u===n.segments.length-1)if(p3(n,t),c3(a=void 0===r?Sre(n,t,e):l3(n,t,e),n),h.points=[],a.length>=2)for(c=0;c2&&n.segments.length>2){var f={x:a[parseInt(c.toString(),10)].x,y:t.point.y};h.points=[],h.points.push(f),h.points.push(a[parseInt(c.toString(),10)]);var p=n.segments[u-1];n.segments.length<4&&p.points.pop(),p.points=p.points.concat(h.points)}else h.points.push(a[parseInt(c.toString(),10)]);else h.points.push(a[parseInt(c.toString(),10)]);else d=u;if(void 0!==d&&!n.selectedSegmentIndex&&(d===n.segments.length-1&&(n.segments[d-1].direction=null,n.segments[d-1].length=null),n.segments.splice(d,1)),i&&0===u){var g=h3(n,i,s);g&&(t.point=g)}}return f3(n,[])}(n,y,S,l,h,o):(n.segments[0]||(C=new bi(n,"segments",{type:"Orthogonal"},!0),n.segments.push(C)),n.segments[0].points=c=g3(n,y,S,void 0,s));return c}(n,y.direction,S.direction,y.point,S.point,r);if(Bv(n),(n.sourceWrapper||n.targetWrapper)&&function gre(n,t,e){var i=n.sourcePortWrapper,r=n.targetPortWrapper,s=n.sourceWrapper,o=t.point,a={left:0,right:0,top:0,bottom:0},l={x:0,y:0},c="Top";if(s?(o=e.point,a=t.margin):(s=n.targetWrapper,a=e.margin),"Orthogonal"===n.type)if(n.segments&&n.segments.length>0&&n.sourceWrapper&&n.segments[0].direction)t.direction=n.segments[0].direction,l=Ah(n,0,l=Tc(s.corners,t.direction),Tc(s.corners,ls(t.direction)),!1);else{var u={corners:null,direction:null,point:null,margin:null};Fv(s,{corners:null,direction:null,point:o,margin:a},u,n),l=u.point,c=u.direction}else{var p=void 0;n.segments&&n.segments.length>1&&(p=s===n.sourceWrapper?n.segments[0].point:n.segments[n.segments.length-2].point),l=Ah(n,0,s.bounds.center,n.segments&&n.segments.length>1?p:o,s===n.targetWrapper)}s===n.sourceWrapper?(t.direction=t.direction||c,t.point=l,n.sourcePortWrapper&&(t.point={x:i.offsetX,y:i.offsetY},n.sourcePadding&&(t.point=bI(n,t,e,!1)))):(e.direction=e.direction||c,e.point=l,n.targetPortWrapper&&(e.point={x:r.offsetX,y:r.offsetY},n.targetPadding&&(e.point=bI(n,t,e,!0))))}(n,y,S),"Straight"===n.type||"Bezier"===n.type)d=Tx(n,y,S);else if("Orthogonal"===n.type&&n.segments&&n.segments.length>0&&null!==n.segments[0].length&&null!==n.segments[0].direction)d=function fre(n,t,e,i,r,s,o){var a,l,c,u,h=[];if(Bv(n),n.segments.length>0){for(var p=0;p0&&n.segments[p-1].direction===f.direction)p=u3(n,p,t);else{var g=n.segments[p-1];t.point=f.direction?o3(t,f):g.points[g.points.length-1]}if(p===n.segments.length-1&&(o||r?n.targetWrapper&&void 0===n.targetPortWrapper?(p3(n,t),l=ure(n,t,e)):l=l3(n,t,e):l=dre(n,t,e),l))if(c3(l,n),f.points=[],l.length>=2)for(a=0;at.corners.top&&e.point.ye.point.x?"Left":"Right"):e.point.x>t.corners.left&&e.point.xe.point.y?"Top":"Bottom")),n.sourcePortWrapper&&s===ls(r)?(("Left"===s||"Right"===s)&&t.point.y>=t.corners.top&&t.point.y<=t.corners.center.y&&e.point.y>=t.corners.top&&e.point.y<=t.corners.center.y?(t.direction="Top",a=t.point.y-t.corners.top+20):("Left"===s||"Right"===s)&&t.point.y>t.corners.center.y&&t.point.y<=t.corners.bottom&&e.point.y>t.corners.center.y&&e.point.y<=t.corners.bottom?(t.direction="Bottom",a=t.corners.bottom-t.point.y+20):("Top"===s||"Bottom"===s)&&t.point.x>=t.corners.left&&t.point.x<=t.corners.center.x&&e.point.x>=t.corners.left&&e.point.x<=t.corners.center.x?(t.direction="Left",a=t.point.x-t.corners.left+20):("Top"===s||"Bottom"===s)&&t.point.x<=t.corners.right&&t.point.x>t.corners.center.x&&e.point.x<=t.corners.right&&e.point.xt.point.y&&t.point.y>=e.corners.top?(i="Top",r=t.point.y-e.corners.top+20):e.corners.center.y===t.point.y&&"Top"===n.segments[n.segments.length-2].direction||e.corners.center.ye.point.y?t.point.y-t.corners.top+20:t.corners.bottom-t.point.y+20):(i="Top",r=e.corners.height/2+20):e.corners.center.x!==t.point.x||e.corners.topt.point.x&&t.point.x>=e.corners.left?(i="Left",r=t.point.x-e.corners.left+20):e.corners.center.x===t.point.x&&"Left"===n.segments[n.segments.length-2].direction||e.corners.center.x<=t.point.x&&t.point.x<=e.corners.right?(i="Right",r=e.corners.right-t.point.x+20):void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&t.corners.left<=t.point.x&&t.point.x<=t.corners.right&&(i=t.direction,r=t.point.x>e.point.x?t.point.x-t.corners.left+20:t.corners.right-t.point.x+20):(i="Left",r=e.corners.width/2+20);var a=t.point;t.point=Bn(t.point,"Left"===i||"Top"===i?-r:r,"Left"===i||"Right"===i?0:90),t.direction=z.direction(t.point,e.point),void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&(t.corners.center.x===e.corners.center.x||t.corners.center.y===e.corners.center.y)&&(t.direction=e.direction);var l=Ys(n,t,e);return l.splice(0,0,a),l}function l3(n,t,e){var i,r;e.corners=n.targetWrapper.corners,void 0!==n.sourcePortWrapper&&(r=zo({x:n.sourcePortWrapper.offsetX,y:n.sourcePortWrapper.offsetY},En(n.sourceWrapper),n.sourceWrapper.bounds));var a=function pre(n,t,e,i){var r=!1;switch(e.direction){case"Left":void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&"Right"===i&&t.point.x>e.point.x&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom||("Bottom"===i&&t.point.y>e.point.y||"Top"===i&&t.point.y=t.corners.left&&t.point.x<=t.corners.right?(t.direction="Right"===i?t.point.y>e.point.y?"Top":"Bottom":t.point.xe.point.x&&(t.point.y>e.point.y||t.point.yt.point.y&&e.corners.bottome.point.y||t.point.x>e.point.x&&t.point.y<=e.point.y&&e.corners.top=t.point.y?t.direction="Top":t.point.xe.point.x&&t.point.y>e.point.y&&e.corners.bottomt.point.y?t.direction="Bottom":t.point.y===e.point.y&&t.point.xe.point.y||"Top"===i&&t.point.ye.point.x&&t.point.x>=t.corners.left&&t.point.x<=t.corners.right?(t.direction=t.point.x>e.point.x?"Left":"Right",r=!0):void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&"Left"===i&&t.point.x=t.corners.top&&t.point.y<=t.corners.bottom?(t.direction=t.point.y>e.point.y?"Top":"Bottom",r=!0):t.point.x=t.point.y&&t.point.y===e.point.y||t.point.y>e.point.y&&t.point.x>e.point.x?t.direction="Top":t.point.ye.point.x?t.direction="Bottom":t.point.xe.point.y||t.point.ye.point.x&&(t.direction="Left");break;case"Top":void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&"Bottom"===i&&t.point.y>e.point.y&&t.point.x>=t.corners.left&&t.point.x<=t.corners.right||("Right"===i&&t.point.x>e.point.x||"Left"===i&&e.point.y>t.point.y&&e.point.x>t.point.x)&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom?(t.direction="Bottom"===i?t.point.x>e.point.x?"Left":"Right":t.point.ye.point.y&&t.point.x>e.corners.left&&t.point.x=e.point.y?t.direction="Top":t.point.ye.point.x?t.direction="Left":t.point.yt.point.x)&&t.point.y>e.point.y&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom||"Top"===i&&t.point.y=t.corners.left&&t.point.x<=t.corners.right)?(t.direction="Right"===i||"Left"===i?t.point.y>e.point.y?"Top":"Bottom":t.point.x>e.point.x?"Left":"Right",r=!0):t.point.ye.corners.left&&e.corners.right>t.point.x?t.point.ye.corners.left&&e.corners.center.x>=t.point.x?t.direction="Left":t.point.ye.point.y&&t.point.x>e.point.x?t.direction="Left":t.point.y>e.point.y&&t.point.xe.point.x||e.point.x>t.point.x)&&(t.direction="Bottom")}return r}(n,t,e,r);return!n.selectedSegmentIndex&&void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&e.direction===ls(r)&&(("Left"===e.direction&&t.point.x>e.point.x||"Right"===e.direction&&t.point.x=t.corners.top&&t.point.y<=t.corners.bottom||"Bottom"===e.direction&&t.point.y=t.corners.left&&t.point.x<=t.corners.right)?i=a3(n,t,e):n.selectedSegmentIndex||t.direction!==e.direction?!n.selectedSegmentIndex&&("Left"===e.direction&&t.point.x>e.point.x||"Right"===e.direction&&t.point.x=t.point.y||"Top"===e.direction&&t.point.y>e.point.y||"Bottom"===e.direction&&t.point.y=t.point.x?i=n.selectedSegmentIndex?Ll(t,e):a3(n,t,e):!n.selectedSegmentIndex&&void 0!==n.sourceWrapper&&void 0!==n.targetWrapper&&void 0!==n.targetPortWrapper&&("Left"===t.direction||"Right"===t.direction)&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom&&("Top"===e.direction||"Bottom"===e.direction)&&e.corners.center.x===t.corners.center.x?(t.direction="Top"===e.direction?"Bottom":"Top",i=Ys(n,t,e,"Top"===e.direction?t.corners.bottom-t.point.y+20:t.point.y-t.corners.top+20)):!n.selectedSegmentIndex&&void 0!==n.sourceWrapper&&void 0!==n.targetWrapper&&void 0!==n.targetPortWrapper&&("Top"===t.direction||"Bottom"===t.direction)&&t.point.x>=t.corners.left&&t.point.x<=t.corners.right&&("Left"===e.direction||"Right"===e.direction)&&e.corners.center.y===t.corners.center.y?(t.direction="Left"===e.direction?"Right":"Left",i=Ys(n,t,e,"Left"===e.direction?t.corners.right-t.point.x+20:t.point.x-t.corners.left+20)):i=a?Ys(n,t,e,"Left"===t.direction||"Right"===t.direction?"Left"===t.direction?t.point.x-t.corners.left+20:t.corners.right-t.point.x+20:"Top"===t.direction?t.point.y-t.corners.top+20:t.corners.bottom-t.point.y+20):Ll(t,e):i=Ys(n,t,e),i}function h3(n,t,e){var r,i={x:t.offsetX,y:t.offsetY},s=En(e),o=zo(i,s,e.bounds),a=n.segments[0];return a.direction!==o&&(function bre(n,t,e,i,r,s){var a,h,o=13,l=[];l.push(i),i.y===r.y&&("Left"===t&&r.xi.x)||i.x===r.x&&("Top"===t&&r.yi.y)||("Top"===t||"Bottom"===t?"Top"===t&&r.yi.y-o||"Bottom"===t&&r.y>i.y&&r.yo&&("Top"===t&&r.yi.y)?l.push({x:i.x,y:r.y}):(a=r.xi.x-o||"right"===t&&r.x>i.x&&r.xo&&("Left"===t&&r.xi.x)?l.push({x:r.x,y:i.y}):(l.push({x:a="Left"===t?e.left-o:e.right+o,y:i.y}),l.push({x:a,y:r.y})),s&&(l.push(n.points[0]),l.reverse()),n.points=l)}(a,o,s,a.points[0],a.points[a.points.length-1],!1),r=a.points[a.points.length-1],a.direction=z.direction(a.points[a.points.length-2],a.points[a.points.length-1])),r}function c3(n,t,e){var s,i=t.segments[t.segments.length-2],r=i.points[i.points.length-1];(("Top"===i.direction||"Bottom"===i.direction)&&r.x===n[1].x||("Left"===i.direction||"Right"===i.direction)&&r.y===n[1].y)&&(i.points[i.points.length-1]=n[1],s=z.direction(i.points[0],i.points[i.points.length-1]),void 0!==t.sourceWrapper&&void 0===t.sourcePortWrapper&&s===ls(i.direction)&&("Left"===i.direction||"Right"===i.direction?i.points[0].x="Right"===i.direction?i.points[0].x-t.sourceWrapper.corners.width:i.points[0].x+t.sourceWrapper.corners.width:i.points[0].y="Bottom"===i.direction?i.points[0].y-t.sourceWrapper.corners.height:i.points[0].y+t.sourceWrapper.corners.height),i.direction=s,i.length=z.distancePoints(i.points[0],i.points[i.points.length-1]),n.splice(0,1))}function bI(n,t,e,i){var o=i?n.targetPadding:n.sourcePadding,a=i?n.targetPortWrapper:n.sourcePortWrapper,l=new Ne(a.bounds.x-o,a.bounds.y-o,a.actualSize.width+2*o,a.actualSize.height+2*o),h=[l.topLeft,l.topRight,l.bottomRight,l.bottomLeft];h[h.length]=h[0];var d=i?e.point:t.point;return Lx({x1:t.point.x,y1:t.point.y,x2:e.point.x,y2:e.point.y},h,0,d)||d}function d3(n,t){var e=[],i=dF(0,n.corners,t);i.push(i[0]);for(var r=0;r0){var r=void 0,s=[],o=t.point;for(r=0;r1&&z.equals(a.points[0],a.points[1])&&n.segments.splice(r,1),a)for(var l=0;l0||0===r)&&i.push(a.points[parseInt(l.toString(),10)])}}return i}function Ax(n,t,e){return"Top"===n||"Bottom"===n?e.x>t.x?"Right":"Left":e.y>t.y?"Bottom":"Top"}function Bv(n){if("Straight"===n.type||"Bezier"===n.type){if(0===n.segments.length||n.segments.length>0&&!z.isEmptyPoint(n.segments[n.segments.length-1].point))if("Bezier"===n.type){var t=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0},!0);n.segments.push(t)}else t=new kl(n,"segments",{type:"Straight"},!0),n.segments.push(t)}else{if(n.segments.length>0)for(var e=!1,i=0;i=t.corners.left&&e.point.x<=t.corners.right&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom)t.direction=e.point.y>t.point.y?"Bottom":"Top",i=Ys(n,t,e,"Top"===t.direction?t.point.y-t.corners.top+20:t.corners.bottom-t.point.y+20);else if(n.sourcePortWrapper&&r===ls(o)){var h;("Left"===r||"Right"===r)&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom?(t.direction=e.point.y>t.point.y?"Bottom":"Top",h=t.corners.height/2+20):("Top"===r||"Bottom"===r)&&t.point.x>=t.corners.left&&t.point.x<=t.corners.right&&(t.direction=e.point.x>t.point.x?"Right":"Left",h=t.corners.width/2+20),t.direction&&h?i=Ys(n,t,e,h,!0):(t.direction=o,i=Ll(t,e))}else if(!n.sourcePortWrapper||r!==e.direction||"Top"!==r&&"Bottom"!==r||t.corners.center.x!==e.corners.center.x)if(t.direction===e.direction)if(("Left"===t.direction||"Right"===t.direction)&&e.point.y>t.corners.top-20&&e.point.yt.corners.left-20&&e.point.xt.point.y?"Bottom":"Top",i=Ys(n,t,e,"Bottom"===t.direction?t.corners.bottom-t.point.y+20:t.point.y-t.corners.top+20);else t.direction=o,i=Ys(n,t,e,"Top"===o||"Bottom"===o?n.sourceWrapper.height/2+20:n.sourceWrapper.width/2+20),t.point=i[1],"Left"===o||"Right"===o?(e.direction=o,e.point="Left"===o?e.corners.middleLeft:e.corners.middleRight):Fv(n.targetWrapper,t,e,n),i=Ys(n,t,e);return i}function p3(n,t){if(void 0!==n.targetWrapper&&void 0===n.targetPortWrapper&&En(n.targetWrapper).containsPoint(t.point,1)){var i=n.targetWrapper,r=n.segments[n.segments.length-2],s=r.points[r.points.length-1],o=ls(r.direction);"Bottom"===o?s.yi.corners.top-1&&(r.points[r.points.length-1].y=i.corners.top-20,r.length=z.distancePoints(r.points[0],r.points[r.points.length-1])):"Left"===o?s.x>i.corners.left-1&&(r.points[r.points.length-1].x=i.corners.left-20,r.length=z.distancePoints(r.points[0],r.points[r.points.length-1])):"Right"===o&&s.x0||0===e)&&t.push(i.points[parseInt(r.toString(),10)]);return t}function Fv(n,t,e,i){var r,s={x:0,y:0},o=MI(n,n.corners,n.bounds),a=t.margin,l=t.point;if(o.bottomCenter.y+a.bottoml.y)r="Top",s=o.topCenter;else if(o.middleLeft.x-a.left>l.x)r="Left",s=o.middleLeft;else if(o.middleRight.x+a.rightc&&(p=c,r="Right",s=o.middleRight),p>d&&(p=d,r="Bottom",s=o.bottomCenter),p>u&&(r="Left",s=o.middleLeft)}e.point=s,e.direction=r;var f=Tc(o,ls(e.direction));e.point=Ah(i,0,e.point,f,n===i.targetWrapper)}function g3(n,t,e,i,r){var s,o,a;if(s=function zre(n,t){var e=!1;switch(n){case"Left":switch(t){case"Right":case"Bottom":e=!0}break;case"Top":switch(t){case"Left":case"Right":case"Bottom":e=!0}break;case"Bottom":"Right"===t&&(e=!0)}return e}(t.direction,e.direction),s&&b3(t,e),"Right"===t.direction&&"Left"===e.direction)a=function Mre(n,t,e,i){var o=Math.round(Math.abs(t.point.y-e.point.y)),a={x:Math.max(t.point.x,t.corners.right),y:t.point.y},l={x:Math.min(e.point.x,e.corners.left),y:e.point.y},h=Ga(n);if(i){var c=l;l=a,a=c}return t.corners.bottom+he.corners.bottom+h||("Bezier"!==n.type||e.corners.left-t.corners.right<=2*h&&e.corners.left-t.corners.right>=5)&&(h=0),t.margin={left:h,right:h,top:h,bottom:h},e.margin={left:h,right:h,top:h,bottom:h},0===o&&(t.corners.right=e.corners.right?void 0!==i&&(i.offsetYe.corners.bottom+e.margin.bottom)||void 0===i&&t.corners.middleRight.ye.corners.bottom+e.margin.bottom&&t.corners.top>e.corners.bottom||void 0===i&&t.corners.middleRight.y>e.corners.bottom||void 0!==i&&i.offsetYe.corners.top||void 0===i&&t.corners.middleRight.y>e.corners.bottom?Ae.Three:t.corners.rightr.offsetY+e.margin.right||void 0===r&&t.corners.top>e.corners.middleRight.y||void 0!==r&&(void 0!==i&&i.offsetXr.offsetX||void 0===r&&t.corners.left>e.corners.topCenter.x?Ae.Four:Ae.Two:void 0!==s&&Math.abs(t.corners.right-e.corners.left)<=5&&Math.abs(s.offsetY-e.corners.top)<=5||void 0!==r&&t.corners.right=25&&t.corners.middleRight.y+t.margin.righte.corners.bottom+e.margin.bottom||void 0===o&&t.corners.middleRight.y>e.corners.bottom+e.margin.bottom?t.corners.top>e.corners.bottom?void 0!==a&&t.corners.right+t.margin.righta.offsetX||void 0===a&&t.corners.left>e.corners.bottomCenter.x?Ae.Four:Ae.Two:void 0!==o&&Math.abs(t.corners.right-e.corners.left)<=25&&Math.abs(o.offsetY-e.corners.bottom)<=25?Ae.Two:Ae.Four}(n,t,e,s);else if("Bottom"===t.direction&&"Top"===e.direction)a=function Dre(n,t,e){var r=t.point.x-e.point.x,s=Ga(n);return t.corners.right+se.corners.right+s||("Bezier"!==n.type||e.corners.top-t.corners.bottom<=2*s&&e.corners.top-t.corners.bottom>=5)&&(s=0),t.margin={left:s,right:s,top:s,bottom:s},e.margin={left:s,right:s,top:s,bottom:s},0===r&&t.corners.bottome.corners.right+e.margin.right||void 0===i&&t.corners.bottomCenter.x>e.corners.right+e.margin.right?Ae.Three:t.corners.bottomr.offsetX||void 0===r&&t.corners.left>e.corners.left||void 0!==r&&t.corners.right+t.margin.righte.corners.bottom?Ae.Five:0===s||0===o?Ae.One:Ae.Three}(n,t,e)}else"Bottom"===t.direction&&"Left"===e.direction?a=function xre(n,t,e,i){var r=n.sourcePortWrapper,s=n.targetPortWrapper,o=Ga(n);if(e.margin={left:o,right:o,top:o,bottom:o},t.margin={top:o,bottom:o,left:o,right:o},i){var l=r;r=s,s=l}return void 0!==r&&r.offsetXs.offsetY||void 0===s&&t.corners.top>e.corners.middleLeft.y?Ae.Four:Ae.Two:void 0!==s&&Math.abs(t.corners.right-e.corners.left)<=25&&Math.abs(s.offsetY-t.corners.bottom)<=25?Ae.Two:Ae.Four}(n,t,e,s):"Left"===t.direction&&"Left"===e.direction?a=function Lre(n,t,e){var i=n.sourcePortWrapper,r=n.targetPortWrapper,s=Ga(n);t.margin={left:s,right:s,top:s,bottom:s},e.margin={left:s,right:s,top:s,bottom:s};var o=Math.round(Math.abs(t.point.x-e.point.x)),a=Math.round(Math.abs(t.point.y-e.point.y));return t.corners.leftr.offsetY||void 0===r&&t.corners.top-t.margin.top>e.corners.middleLeft.y?Ae.Three:t.corners.righte.corners.bottom+e.margin.bottom||void 0===i&&t.corners.middleLeft.y>e.corners.bottom+e.margin.bottom?Ae.Three:t.corners.left>e.corners.right?Ae.Five:0===o||0===a?Ae.One:Ae.Three}(n,t,e):"Left"===t.direction&&"Top"===e.direction?a=function Are(n,t,e,i){var s=n.sourcePortWrapper,o=Ga(n);e.margin={left:o,right:o,top:o,bottom:o},t.margin={top:o,bottom:o,left:o,right:o};var a=n.targetPortWrapper,l={x:Math.min(t.point.x,t.corners.left),y:t.point.y},h={x:e.point.x,y:Math.min(e.point.y,e.corners.top)};if(i){var c=s;s=a,a=c;var d=l;l=h,h=d}return void 0!==s&&s.offsetYa.offsetX||void 0===a&&t.corners.left-t.margin.left>e.corners.topCenter.x?Ae.Two:Ae.Four:void 0!==a&&t.corners.rightr.offsetX||void 0===r&&t.corners.left>e.corners.left||void 0!==r&&t.corners.right+t.margin.righte.corners.right+e.margin.right||void 0===i&&t.corners.left>e.corners.right||void 0!==i&&i.offsetXe.corners.bottom?Ae.Five:0===s||0===o?Ae.One:Ae.Three}(n,t,e));return s&&b3(t,e),o=function Ore(n,t,e,i,r,s){var l,d,h=n.sourceWrapper.corners,c=n.targetWrapper.corners,u=20,p={corners:e.corners,point:e.point,direction:e.direction,margin:e.margin},f={corners:i.corners,point:i.point,direction:i.direction,margin:i.margin};if(!(p.direction===f.direction&&t!==Ae.Five||p.direction!==ls(f.direction)&&t!==Ae.Three))switch(p.direction){case"Left":h.middleLeft.x>c.middleRight.x&&(d=(h.middleLeft.x-c.middleRight.x)/2,u=s?d:Math.min(u,d));break;case"Right":h.middleRight.xc.bottomCenter.y&&(d=(h.topCenter.y-c.bottomCenter.y)/2,u=s?d:Math.min(u,d));break;case"Bottom":h.bottomCenter.yp&&hp)&&o>c&&o<=d&&e>=20&&(s=n.point.x-t.corners.left+s),i&&n.direction===t.direction&&n.corners.left>t.corners.left&&n.corners.left-t.corners.right>=20&&(s=(n.corners.left-t.corners.right)/2),f=Bn(n.point,s,180);break;case"Top":(o>c&&oc)&&h>p&&h<=u&&e>=20&&(s=n.point.y-t.corners.top+s),i&&n.direction===t.direction&&n.corners.top>t.corners.top&&n.corners.top-t.corners.bottom>=20&&(s=(n.corners.top-t.corners.bottom)/2),f=Bn(n.point,s,270);break;case"Right":(h>p&&hp)&&a=c&&e>=20&&(s=t.corners.right-n.point.x+s),i&&n.direction===t.direction&&n.corners.right=20&&(s=(t.corners.left-n.corners.right)/2),f=Bn(n.point,s,0);break;case"Bottom":(o>c&&oc)&&l=p&&e>=20&&(s=t.corners.bottom-n.point.y+s),i&&n.direction===t.direction&&n.corners.bottom=20&&(s=(t.corners.top-n.corners.bottom)/2),f=Bn(n.point,s,90)}r=[n.point,f];var g=void 0;if("Top"===n.direction||"Bottom"===n.direction){var v=n.direction;n.direction=f.x>t.point.x?"Left":"Right",n.point=f,r=wI(n,t,v,r,g=i?.5*Math.abs(f.x-t.point.x):g,i)}else v=n.direction,n.direction=f.y>t.point.y?"Top":"Bottom",n.point=f,r=wI(n,t,v,r,g=i?.5*Math.abs(f.y-t.point.y):g,i);return r}(p,f,u,g)),l}(n,a,t,e,i,r),"Bezier"===n.type&&function Pre(n,t,e){if("Bezier"===n.type)if(0===n.segments.length){var i=e[0],r=e[e.length-1];if(t===Ae.One){var s=Math.min(20,.5*z.findLength(i,r)),o={angle:Gt(i,r),distance:s},a={angle:Gt(r,i),distance:s},l=z.direction(i,r),c=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,orientation:"Left"===l||"Right"===l?"Horizontal":"Vertical"},!0);n.segments.push(c)}else if(t===Ae.Two)o={angle:Gt(i,d=e[1]),distance:.5*z.findLength(i,d)},a={angle:Gt(r,d),distance:.5*z.findLength(r,d)},l=z.direction(i,d),c=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,orientation:"Left"===l||"Right"===l?"Horizontal":"Vertical"},!0),n.segments.push(c);else if(t===Ae.Three){var d={x:.5*((u=e[1]).x+(p=e[e.length-2]).x),y:.5*(u.y+p.y)},f=(o={angle:Gt(i,u),distance:.5*z.findLength(i,u)},a={angle:Gt(d,u),distance:.5*z.findLength(d,u)},z.direction(i,u)),v=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,point:d,orientation:"Left"===f||"Right"===f?"Horizontal":"Vertical"},!0);n.segments.push(v);var y={angle:Gt(d,p),distance:.5*z.findLength(d,p)},S={angle:Gt(r,p),distance:.5*z.findLength(r,p)},b=z.direction(d,p),w=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:y,vector2:S,orientation:"Left"===b||"Right"===b?"Horizontal":"Vertical"},!0);n.segments.push(w)}else if(t===Ae.Four){var D={x:.5*((u=e[1]).x+(p=e[2]).x),y:.5*(u.y+p.y)},A={x:.5*(p.x+(C=e[3]).x),y:.5*(p.y+C.y)};o={angle:Gt(i,u),distance:.5*z.findLength(i,u)},a={angle:Gt(D,u),distance:.5*z.findLength(D,u)},f=z.direction(i,u),v=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,point:D,orientation:"Left"===f||"Right"===f?"Horizontal":"Vertical"},!0),n.segments.push(v),y={angle:Gt(D,p),distance:.5*z.findLength(D,p)},S={angle:Gt(A,p),distance:.5*z.findLength(A,p)},b=z.direction(D,p),w=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:y,vector2:S,point:A,orientation:"Left"===b||"Right"===b?"Horizontal":"Vertical"},!0),n.segments.push(w);var x={angle:Gt(A,C),distance:.5*z.findLength(A,C)},R={angle:Gt(r,C),distance:.5*z.findLength(r,C)},L=z.direction(A,C),N=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:x,vector2:R,orientation:"Left"===L||"Right"===L?"Horizontal":"Vertical"},!0);n.segments.push(N)}else if(t===Ae.Five){var u,p,C,T=e[4],P=(D={x:.5*((u=e[1]).x+(p=e[2]).x),y:.5*(u.y+p.y)},A={x:.5*(p.x+(C=e[3]).x),y:.5*(p.y+C.y)},{x:.5*(C.x+T.x),y:.5*(C.y+T.y)});o={angle:Gt(i,u),distance:.5*z.findLength(i,u)},a={angle:Gt(D,u),distance:.5*z.findLength(D,u)},f=z.direction(i,u),v=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,point:D,orientation:"Left"===f||"Right"===f?"Horizontal":"Vertical"},!0),n.segments.push(v),y={angle:Gt(D,p),distance:.5*z.findLength(D,p)},S={angle:Gt(A,p),distance:.5*z.findLength(A,p)},b=z.direction(D,p),w=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:y,vector2:S,point:A,orientation:"Left"===b||"Right"===b?"Horizontal":"Vertical"},!0),n.segments.push(w),x={angle:Gt(A,C),distance:.5*z.findLength(A,C)},R={angle:Gt(P,C),distance:.5*z.findLength(P,C)},L=z.direction(A,C),N=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:x,vector2:R,point:P,orientation:"Left"===L||"Right"===L?"Horizontal":"Vertical"},!0),n.segments.push(N);var _={angle:Gt(P,T),distance:.5*z.findLength(P,T)},B={angle:Gt(r,T),distance:.5*z.findLength(r,T)},j=z.direction(P,T),oe=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:_,vector2:B,orientation:"Left"===j||"Right"===j?"Horizontal":"Vertical"},!0);n.segments.push(oe)}else c=new ps(n,"segments",{type:"Bezier"},!0),n.segments.push(c)}else for(var ue=0;ue=13?13:n.connectorSpacing<=1?1:n.connectorSpacing}function Gt(n,t){var i=z.findLength({x:t.x,y:n.y},t),r=z.findLength(t,n),s=Math.asin(i/r);return s=180*s/Math.PI,n.xt.y&&(s=360-s):s=n.y0)for(var l=1;lc)&&(s=c,a=h),s>=0&&s<=1)break}}return a}function m3(n,t){var c,d,u,p,f,g,S,b,M,w,D,e=n.x1,i=n.y1,r=n.x2,s=n.y2,o=t.x1,a=t.y1,l=t.x2,h=t.y2;if(w=(c=s-i)*l+(u=e-r)*h+(f=r*i-e*s),0!==(M=c*o+u*a+f)&&0!==w&&y3(M,w)||(b=(d=h-a)*r+(p=o-l)*s+(g=l*a-o*h),0!==(S=d*e+p*i+g)&&0!==b&&y3(S,b)))return null;var A=c*p-d*u;return 0===A?null:(A<0?-A/2:A/2,0,{x:(D=u*g-p*f)<0?(D-0)/A:(D+0)/A,y:(D=d*f-c*g)<0?(D-0)/A:(D+0)/A})}function y3(n,t){return n*t>=0}function S3(n,t,e){switch(t.direction){case"Left":t.point.x>n.left&&(e=t.point.x-n.left>e?t.point.x-n.left+e:e);break;case"Right":t.point.xe?n.right-t.point.x+e:e);break;case"Top":t.point.y>n.top&&(e=t.point.y-n.top>e?t.point.y-n.top+e:e);break;case"Bottom":t.point.ye?n.bottom-t.point.y+e:e)}return e}function Ll(n,t){var e;switch(n.direction){case"Left":case"Right":var i={x:t.point.x,y:n.point.y};e=z.equals(n.point,i)||z.equals(t.point,i)?[n.point,t.point]:[n.point,i,t.point];break;case"Top":case"Bottom":var r={x:n.point.x,y:t.point.y};e=z.equals(n.point,r)||z.equals(t.point,r)?[n.point,t.point]:[n.point,r,t.point]}return e}function Ys(n,t,e,i,r,s){void 0===s&&(s=!1),i||(i=20),s&&t.direction!==e.direction&&(i="Left"===t.direction||"Right"===t.direction?Math.floor(.5*Math.abs(t.point.x-e.point.x)):Math.floor(.5*Math.abs(t.point.y-e.point.y)));var l,h,u,o=n.sourcePortWrapper,c=e.point.x-t.point.x,d=e.point.y-t.point.y;if(!r&&(Math.abs(c)<.001||Math.abs(d)<.001)&&void 0===e.direction)return[t.point,e.point];if(void 0===n.targetWrapper&&Math.abs(c)<=31&&Math.abs(d)<=31){if("Left"===t.direction||"Right"===t.direction?Math.abs(d)<12&&(t.direction=t.point.y>e.point.y?"Top":"Bottom"):Math.abs(c)<12&&(t.direction=t.point.x>e.point.x?"Left":"Right"),Math.abs(c)>12||Math.abs(d)>12)return Ll(t,e);i+=5}return"Left"===t.direction||"Right"===t.direction?("Right"===t.direction?(void 0!==e.direction&&"Right"===e.direction&&(i=Math.max(t.point.x,e.point.x)-t.point.x+i),t.point.x>e.point.x&&void 0===o&&(i=-i)):(void 0!==e.direction&&"Left"===e.direction&&(i=t.point.x-Math.min(t.point.x,e.point.x)+i),(t.point.x>e.point.x||void 0!==o||"Left"===t.direction)&&(i=-i)),u=e.point.y-t.point.y,l=Bn(t.point,i,0),0!=(u=e.point.y-l.y)&&(h=Bn(l,e.point.y-l.y,90))):("Top"===t.direction||"Bottom"===t.direction)&&("Bottom"===t.direction?void 0!==e.direction&&"Bottom"===e.direction&&(i=Math.max(t.point.y,e.point.y)-t.point.y+i):(void 0!==e.direction&&"Top"===e.direction&&(i=t.point.y-Math.min(t.point.y,e.point.y)+i),(t.point.y>e.point.y||void 0!==o||"Top"===t.direction)&&(i=-i)),u=e.point.x-t.point.x,l=Bn(t.point,i,90),0!=(u=e.point.x-l.x)&&(h=Bn(l,e.point.x-l.x,0))),0===u?[t.point,e.point]:[t.point,l,h,e.point]}function wI(n,t,e,i,r,s){var o;switch(void 0===r&&(r=20),void 0===s&&(s=!1),void 0===e?(n.margin={left:2,right:2,top:2,bottom:2},t.margin={left:0,right:5,top:0,bottom:5},s&&(n.margin={left:10,right:10,top:10,bottom:10},t.margin={left:10,right:10,top:10,bottom:10},"Left"===n.direction?(r=Ox(n,t,e,r),n.corners.left-t.corners.right>=5&&(r=Math.abs(n.point.x-n.corners.left)+.5*Math.floor(n.corners.left-t.corners.right))):"Right"===n.direction?(r=kx(n,t,r,e),t.corners.left-n.corners.right>=5&&(r=Math.abs(n.point.x-n.corners.right)+.5*Math.floor(t.corners.left-n.corners.right))):"Top"===n.direction?(r=Nx(n,t,e,r),n.corners.top-t.corners.bottom>=5&&(r=Math.abs(n.point.y-n.corners.top)+.5*Math.floor(n.corners.top-t.corners.bottom))):"Bottom"===n.direction&&(r=Px(n,t,r,e),t.corners.top-n.corners.bottom>=5&&(r=Math.abs(n.point.y-n.corners.bottom)+.5*Math.floor(t.corners.top-n.corners.bottom))))):("Bottom"===n.direction?s?t.corners.top-n.corners.bottom<20&&(r=t.corners.bottom-n.point.y+25):t.corners.top>n.corners.bottom&&t.corners.top-n.corners.bottom<20&&(r=(t.corners.top-n.corners.bottom)/2):"Top"===n.direction?s?n.corners.top-t.corners.bottom<20&&(r=n.point.y-t.corners.top+25):t.corners.bottomn.corners.right&&t.corners.left-n.corners.right<20&&(r=(t.corners.left-n.corners.right)/2):"Left"===n.direction&&(s?n.corners.left-t.corners.right<20&&(r=n.point.x-t.corners.left+25):t.corners.rightt.point.y||"Top"===t.direction&&n.point.yt.point.x||"Left"===t.direction&&n.point.xh||e.corners.top-e.margin.top<=i.point.y&&e.corners.bottom+e.margin.bottom>=i.point.y))if(!s||"Top"!==e.direction&&"Bottom"!==e.direction)c=Math.min(Math.abs(i.corners.left-e.corners.right)/2,20),h=e.corners.right-n.x+c;else{var c=Math.abs(i.corners.left-e.corners.right)/2;h=e.corners.right-n.x+c}else h="Top"===e.direction&&n.y>i.point.y||"Bottom"===e.direction&&n.y=e.corners.left-e.margin.left&&n.x<=e.corners.right+e.margin.right?Math.min(i.corners.left,e.corners.left)-n.x-20:i.corners.left-n.x-20;break;case"Right":if(e.corners.left-e.margin.left>i.corners.right+i.margin.right&&(e.corners.left-e.margin.right-i.corners.right>h||e.corners.top-e.margin.top<=i.point.y&&e.corners.bottom+e.margin.bottom>=i.point.y))if(!s||"Top"!==e.direction&&"Bottom"!==e.direction)c=Math.min(Math.abs(e.corners.left-i.corners.right)/2,20),h=e.corners.left-n.x-c;else{c=Math.abs(e.corners.left-i.corners.right)/2;h=e.corners.left-n.x-c}else h="Top"===e.direction&&n.y>i.point.y||"Bottom"===e.direction&&n.y=e.corners.left-e.margin.left&&n.x<=e.corners.right+e.margin.right?Math.max(i.corners.right,e.corners.right)-n.x+20:i.corners.right-n.x+20}o=Bn(n,h,0),a=Bn(o,i.point.y-n.y,90),l=i.point}else if("vertical"===t){switch(i.direction){case"Top":e.corners.bottom+e.margin.bottomh||e.corners.left-e.margin.left<=i.point.x&&e.corners.right+e.margin.right>=i.point.x)?!s||"Right"!==e.direction&&"Left"!==e.direction?(c=Math.min(Math.abs(i.corners.top-e.corners.bottom)/2,20),h=e.corners.bottom-n.y+c):(c=Math.abs(i.corners.top-e.corners.bottom)/2,h=e.corners.bottom-n.y+c):h="Left"===e.direction&&n.x>i.point.x||"Right"===e.direction&&n.x=e.corners.top-e.margin.top&&n.y<=e.corners.bottom+e.margin.bottom?Math.min(i.corners.top,e.corners.top)-n.y-20:i.corners.top-n.y-20;break;case"Bottom":e.corners.top-e.margin.top>i.corners.bottom+i.margin.bottom&&(e.corners.top-e.margin.top-i.corners.bottom>h||e.corners.left-e.margin.left<=i.point.x&&e.corners.right+e.margin.right>=i.point.x)?!s||"Right"!==e.direction&&"Left"!==e.direction?(c=Math.min(Math.abs(e.corners.top-i.corners.bottom)/2,20),h=e.corners.top-n.y-c):(c=Math.abs(e.corners.top-i.corners.bottom)/2,h=e.corners.top-n.y-c):h="Left"===e.direction&&n.x>i.point.x||"Right"===e.direction&&n.x=e.corners.top-e.margin.top&&n.y<=e.corners.bottom+e.margin.bottom?Math.max(i.corners.bottom,e.corners.bottom)-n.y+20:i.corners.bottom-n.y+20}o=Bn(n,h,90),a=Bn(o,i.point.x-n.x,0),l=i.point}r.push(o),r.push(a),r.push(l)}function Nx(n,t,e,i){return n.corners.top-n.margin.top>t.corners.top+t.margin.top&&n.corners.top-n.margin.top<=t.corners.bottom+t.margin.bottom?(("Right"===t.direction&&n.point.xt.point.x)&&(i+=n.corners.top-t.corners.top),i+=n.point.y-n.corners.top):i+=void 0!==e&&"Left"!==e&&"Right"===t.direction&&n.point.xt.corners.left-t.margin.left&&n.corners.left-n.margin.left<=t.corners.right+t.margin.right?(("Bottom"===t.direction&&n.point.yt.point.y)&&(i+=n.corners.left-t.corners.left),i+=n.point.x-n.corners.left):i+=void 0!==e&&"Top"!==e&&"Bottom"===t.direction&&n.point.y=t.corners.left-t.margin.left?(("Bottom"===t.direction&&n.point.yt.point.y)&&(e+=t.corners.right-n.corners.right),e+=n.corners.right-n.point.x):e+=void 0!==i&&"Top"!==i&&"Bottom"===t.direction&&n.point.y=t.corners.top-t.margin.top?(("Right"===t.direction&&n.point.xt.point.x)&&(e+=t.corners.bottom-n.corners.bottom),e+=n.corners.bottom-n.point.y):e+=void 0!==i&&"Left"!==i&&"Right"===t.direction&&n.point.xf&&d=u&&d=p&&d<=f?"Left":"Right"}function ls(n){switch(n){case"Top":return"Bottom";case"Bottom":return"Top";case"Left":return"Right";case"Right":return"Left"}return"auto"}var w3=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Ac=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},CI=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return w3(t,n),Ac([I()],t.prototype,"width",void 0),Ac([I()],t.prototype,"height",void 0),t}(Ee),Rre=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return w3(t,n),Ac([I()],t.prototype,"width",void 0),Ac([I()],t.prototype,"height",void 0),Ac([I()],t.prototype,"fit",void 0),Ac([I()],t.prototype,"description",void 0),Ac([I()],t.prototype,"template",void 0),Ac([I()],t.prototype,"tooltip",void 0),t}(Ee),Hre=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Nl=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},C3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Hre(t,n),Nl([I("")],t.prototype,"id",void 0),Nl([I(Number.MIN_VALUE)],t.prototype,"zIndex",void 0),Nl([re({},$n)],t.prototype,"margin",void 0),Nl([I(!0)],t.prototype,"visible",void 0),Nl([re({},Ed)],t.prototype,"tooltip",void 0),Nl([I(!1)],t.prototype,"excludeFromLayout",void 0),Nl([I()],t.prototype,"addInfo",void 0),Nl([I("None")],t.prototype,"flip",void 0),Nl([I("All")],t.prototype,"flipMode",void 0),Nl([re({},Rre)],t.prototype,"symbolInfo",void 0),t}(Ee),Bre=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Jn=function(n){function t(e,i,r,s){var o=n.call(this)||this;return o.data="",o.nodeId="",o.annotationId="",o.diagramId="",o.diagramId=i,o.nodeId=e,o.annotationId=r,o.templateFn=UF(s),o}return Bre(t,n),t.prototype.getNodeTemplate=function(){return this.templateFn},Object.defineProperty(t.prototype,"content",{get:function(){return this.data},set:function(e){this.data=e,this.canReset||(this.canReset=!0,this.isTemplate||(this.template=Rh(this,!0)),this.canReset=!1,this.isDirt=!0)},enumerable:!0,configurable:!0}),t}(as),zx=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),hs=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},E3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return zx(t,n),hs([I("")],t.prototype,"id",void 0),hs([I("transparent")],t.prototype,"fill",void 0),hs([I("black")],t.prototype,"iconStrokeColor",void 0),hs([I(0)],t.prototype,"iconStrokeWidth",void 0),hs([I(!0)],t.prototype,"visibility",void 0),hs([I(10)],t.prototype,"width",void 0),hs([I(10)],t.prototype,"height",void 0),hs([I("transparent")],t.prototype,"handleStrokeColor",void 0),hs([I(1)],t.prototype,"handleStrokeWidth",void 0),hs([I("")],t.prototype,"pathData",void 0),hs([I(0)],t.prototype,"cornerRadius",void 0),hs([re({left:0,right:0,top:0,bottom:0},$n)],t.prototype,"padding",void 0),hs([re({},Ed)],t.prototype,"tooltip",void 0),t}(Ee),D3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return zx(t,n),hs([re({x:0,y:0},z)],t.prototype,"offset",void 0),hs([re({},$n)],t.prototype,"margin",void 0),t}(E3),EI=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return zx(t,n),hs([I(.5)],t.prototype,"offset",void 0),hs([I("Center")],t.prototype,"alignment",void 0),hs([re({x:0,y:0},z)],t.prototype,"displacement",void 0),t}(E3);function Dd(n){return n?n instanceof Zn||n instanceof Nr?n.constraints&Lr.Select:n instanceof de?n.constraints&qe.Select:n.constraints&ie.Select:1}function to(n){return n?n instanceof Zn||n instanceof Nr?n.constraints&Lr.Drag:n instanceof de?n.constraints&qe.Drag:n instanceof oi?1:n.constraints&ie.Drag:1}function Fre(n,t){return n instanceof de?n.constraints&qe.PointerEvents:n.constraints&ie.PointerEvents}function DI(n){return n instanceof de?n.constraints&qe.Delete:n.constraints&ie.Delete}function xI(n){return n.constraints&qe.DragSourceEnd}function TI(n){return n.constraints&qe.DragTargetEnd}function AI(n){return n.constraints&qe.DragSegmentThumb}function LI(n){return n instanceof Zn||n instanceof Nr?n.constraints&Lr.Rotate:n.constraints&ie.Rotate}function NI(n){return n.constraints&ie.Shadow}function da(n){return n instanceof te&&n.constraints&ie.InConnect?n.constraints&ie.InConnect:0}function Lh(n){return n&&n.constraints&&!(n.constraints&ni.None)&&n.constraints&ni.InConnect?n.constraints&ni.InConnect:0}function Nh(n){return n instanceof te&&n.constraints&ie.OutConnect?n.constraints&ie.OutConnect:0}function xd(n){return n&&n.constraints&&!(n.constraints&ni.None)&&n.constraints&ni.OutConnect?n.constraints&ni.OutConnect:0}function Ol(n,t){var e=0;return n instanceof Zn||n instanceof Nr?e=n.constraints&Lr.Resize:n&&("SouthEast"===t?e=n.constraints&ie.ResizeSouthEast:"East"===t?e=n.constraints&ie.ResizeEast:"NorthEast"===t?e=n.constraints&ie.ResizeNorthEast:"South"===t?e=n.constraints&ie.ResizeSouth:"North"===t?e=n.constraints&ie.ResizeNorth:"SouthWest"===t?e=n.constraints&ie.ResizeSouthWest:"West"===t?e=n.constraints&ie.ResizeWest:"NorthWest"===t&&(e=n.constraints&ie.ResizeNorthWest)),e}function OI(n){return n instanceof de?n.constraints&qe.AllowDrop:n.constraints&ie.AllowDrop}function Ds(n){return n.constraints&rt.Virtualization}function _v(n){return n.tool&Ci.SingleSelect}function Uv(n){return n.tool&Ci.MultipleSelect}function Lc(n){return n.tool&Ci.ZoomPan}function kI(n){return n.tool&Ci.ContinuousDraw}function x3(n){return n.tool&Ci.DrawOnce}function PI(n){return n.tool&Ci.SingleSelect||n.tool&Ci.MultipleSelect}function jv(n){return n.constraints&rt.UserInteraction}function T3(n){return n.constraints&rt.ZoomTextEdit}function Vv(n){return function Yre(n){return n.constraints&rt.ApiUpdate}(n)||n.diagramActions&ee.ToolAction}function Rx(n,t){return n.constraints&ni.Draw}function Hx(n,t){return n.constraints&ni.Drag}function zI(n){return!(n&Qa.DrawSelectorBorder)}function A3(n){return!!(n&Qa.PreventRenderSelector)}var Bx=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Wv=function(n){function t(){var e=null!==n&&n.apply(this,arguments)||this;return e.childTable=[],e.cellStyle={},e.desiredRowHeight=[],e.desiredCellWidth=[],e}return Bx(t,n),t.prototype.rowDefinitions=function(){return this.rowDefns},t.prototype.columnDefinitions=function(){return this.colDefns},t.prototype.addObject=function(e,i,r,s,o){if(this.rows.length>=i){var a=this.rows[parseInt(i.toString(),10)];if(a.cells.length>r){o=o||1,s=s||1;var l=a.cells[parseInt(r.toString(),10)];l.columnSpan=Math.max(o,l.columnSpan),l.rowSpan=Math.max(s,l.rowSpan);var h=new $re;(h=e).rowId=i,h.columnId=r,h.columnSpan=o,this.childTable[h.id]=h,this.addObjectToCell(h,l)}}},t.prototype.addObjectToCell=function(e,i){i.children||(i.children=[]),e.style.strokeColor="black",e.style.strokeWidth=1,i.children.push(e)},t.prototype.updateProperties=function(e,i,r,s){this.offsetX=e,this.offsetY=i,this.width=r,this.height=s},t.prototype.setDefinitions=function(e,i){this.rowDefns=e,this.colDefns=i,this.children=[],this.rows=this.rows||[];for(var r=0;r0){for(var h=0;hi&&this.updateRowHeight(e,l,!1)}},t.prototype.setTextRefresh=function(e){if(e.children&&e.children.length)for(var i=e.children,r=0;ri&&this.updateColumnWidth(e,a,!1)}},t.prototype.calculateCellWidth=function(e){for(var i,r,s,o=0;os.bounds.width&&(0===s.children.length||void 0===s.children[0].maxWidth)?s.outerBounds.width:s.bounds.width,i=i?is.bounds.height?s.outerBounds.height:s.bounds.height,i=i?i0?e.children[0]:void 0;if(a&&1===e.columnSpan){o="Width"===i?a.bounds.right:a.bounds.bottom,s||(s="Width"===i?a.bounds.width:a.bounds.height);for(var l=0;lo){var d=c-o+("Width"===i?a.bounds.width:a.bounds.height);s&&(s=s0?this.rowDefns.splice(e,0,i):this.rowDefns.push(i);var s=new L3;s.cells=[],(new Td).width=this.width,this.addCellInRow(this.colDefns,i,s),e>this.rows.length-1?this.rows.push(s):this.rows.splice(e,0,s),r&&(this.measure(new me(this.width,this.height)),this.arrange(this.desiredSize))},t.prototype.addColumn=function(e,i,r){var s,o,a,l,h=this.rows;this.colDefns.length>0?this.colDefns.splice(e,0,i):this.colDefns.push(i),void 0!==this.width&&(this.width+=i.width);for(var c=0;cs.cells.length-1?s.cells.push(l):s.cells.splice(e,0,l),this.children.push(l);r&&(this.measure(new me(this.width,this.height)),this.arrange(this.desiredSize))},t.prototype.removeRow=function(e){var i,r,o=this.rows[parseInt(e.toString(),10)];this.height-=this.rowDefns[parseInt(e.toString(),10)].height;for(var a=0;a0){var r=0,s=0;i=new me(0,0),this.calculateSize();for(var o=0,a=this.rows;o0){for(var o=this.offsetX-e.width*this.pivot.x,a=this.offsetY-e.height*this.pivot.y,l=o,h=0,c=this.rows;h1&&this.children.splice(this.children.indexOf(f)+1,f.columnSpan-1),f.rowSpan>1)for(y=s,S=0;y+f.rowSpan-10){for(var c=0;c0?1:0,v=0;v0||a.outEdges.length>0))for(p=a.inEdges.concat(a.outEdges),s=0;s0)for(o=0;o1)for(a=1;a0))if(h=n.wrapper.children[0],"Horizontal"===e.orientation)for(o=e.header&&e.hasHeader?h.rows[1]:h.rows[0],r=0;r0){var e=void 0;t.lineRoutingModule&&t.constraints&rt.LineRouting&&t.lineRoutingModule.renderVirtualRegion(t,!0);for(var i=0;i0?o+1:o)].height=t.wrapper.height;else if(t.isPhase)for(l[t.rowIndex-o].offset=t.wrapper.height,f=0;f0?1:0)].width=t.wrapper.width}function HI(n,t){var i=n.shape,r=i.header&&i.hasHeader?1:0;return"Horizontal"===i.orientation?t.rowIndex-(r+=i.phases.length>0?1:0):t.columnIndex-(i.phaseSize&&i.phases.length>0?1:0)}function BI(n){var t=0,e=n.shape;return"Horizontal"===e.orientation&&(t=e.header&&e.hasHeader?1:0),e.phases.length>0&&e.phaseSize&&(t+=1),t}function FI(n,t,e,i){var r=n.shape;if(r.phases.length>0){var s=t.nameTable[r.phases[parseInt(i.toString(),10)].header.id];s&&s.maxWidth0?u+1:u);var w=Nc(n,o),C=void 0!==i?i:l.lanes.length;if(u+=C,r={element:M,cause:n.diagramActions,diagramAction:n.getDiagramAction(n.diagramActions),state:"Changing",type:"Addition",cancel:!1,laneIndex:C},n.triggerEvent(Ce.collectionChange,r),!r.cancel){if(c){var D=new Yv;D.height=e.height,o.addRow(u,D,!1),s.height=void 0!==s.height?s.height+e.height:s.height,s.wrapper.height=o.height=s.height}else{var A=new Td;A.width=e.width,o.addColumn(C+1,A,!1),s.width&&(s.width+=e.width,s.wrapper.width=o.width=s.width),n.diagramActions&ee.UndoRedo||(o.rows[0].cells[0].columnSpan+=1)}n.diagramActions&ee.UndoRedo||(M.id=""===M.id?Qe():M.id),void 0!==i?l.lanes.splice(i,0,M):l.lanes.push(M),r={element:M,cause:n.diagramActions,diagramAction:n.getDiagramAction(n.diagramActions),state:"Changed",type:"Addition",cancel:!1,laneIndex:C},n.triggerEvent(Ce.collectionChange,r),O3(o,n,s,u,C,c),h="Horizontal"===l.orientation?n.nameTable[o.rows[parseInt(u.toString(),10)].cells[0].children[0].id]:l.header&&l.hasHeader?n.nameTable[o.rows[1].cells[parseInt(u.toString(),10)].children[0].id]:n.nameTable[o.rows[0].cells[parseInt(u.toString(),10)].children[0].id],n.diagramActions&ee.UndoRedo||(d={type:"LaneCollectionChanged",changeType:"Insert",undoObject:$(M),redoObject:$(h),category:"Internal"},n.addHistoryEntry(d)),Gp(n,s,"Horizontal"===l.orientation?u:l.header&&l.hasHeader?1:0),Qp(s),Oc(n,s);var R=!1;if((p=e.children)&&p.length>0)for(f=0;f0){var o=t.children[0],a=n.nameTable[o.id];(function sne(n,t,e){return n.left-(e.left||0)<=t.x&&n.right+(e.right||0)>=t.x&&n.top-(e.top||0)<=t.y&&n.bottom+(e.bottom||0)>=t.y})(o.bounds,e,r)&&(n.addChild(a,i),s=!0)}return s}function one(n,t,e){if("SwimLane"===t.shape.type){var i=void 0,r=void 0,s=void 0,a=void 0,l=void 0,h=void 0,c=t.wrapper.bounds.x,d=t.wrapper.bounds.y,u=t.shape,p=u.padding,f=u.phases,g=void 0,v=t.wrapper.children[0],y="Horizontal"===u.orientation;if(i=u.header&&u.hasHeader?0:-1,u.phases.length>0&&(i+=1),e.offset>(y?u.lanes[0].header.width:u.lanes[0].header.height)){for(h=0;he.offset){if(g=h>0?e.offset-(h>0?f[h-1]:s).offset:e.offset,y){var b=v.columnDefinitions()[parseInt(h.toString(),10)];b.width-=g,(a=n.nameTable[u.phases[parseInt(h.toString(),10)].header.id]).maxWidth=a.wrapper.maxWidth=b.width,v.updateColumnWidth(h,b.width,!1);var M=new Td;M.width=g,l=h,v.addColumn(h,M,!1);break}var w=v.rowDefinitions()[h+i];w.height-=g,a=n.nameTable[u.phases[parseInt(h.toString(),10)].header.id],v.updateRowHeight(h+i,w.height,!1);var C=new Yv;C.height=g,l=h,v.addRow(h+i,C,!1);break}if(n.diagramActions&ee.UndoRedo&&void 0===l&&(D=n.historyManager.currentEntry.next).isLastPhase&&function ane(n,t,e,i,r,s){var a=t.shape.phases[n-2],l=e.previousPhase.offset;if(r){var h=i.columnDefinitions()[n-1],c=new Td;n>1?(c.width=h.width-(l-a.offset),h.width=l-a.offset):(c.width=h.width-l,h.width=l),i.updateColumnWidth(n-1,h.width,!1),i.addColumn(n,c,!1)}else{h=i.rowDefinitions()[parseInt(n.toString(),10)];var d=new Yv;n>1?(d.height=e.undoObject.offset-l,h.height=l-a.offset):(d.height=h.height-l,h.height=l),i.updateRowHeight(n,h.height,!1),i.addRow(1+n,d,!1)}}(l=f.length,t,D,v,y),l>=0){var A=new ab(t.shape,"phases",e,!0);if(n.diagramActions&ee.UndoRedo||(A.id+=Qe()),u.phases.splice(l,0,A),Fx(v,n,t,i,y,l),y){if(r=n.nameTable[v.rows[parseInt(i.toString(),10)].cells[parseInt(l.toString(),10)].children[0].id],0===l&&u.header&&u.hasHeader){v.rows[0].cells[0].children=v.rows[0].cells[1].children,v.rows[0].cells[1].children=[];for(var x=v.rows[0],R=0;Rl+1){var O=n.nameTable[v.rows[parseInt(i.toString(),10)].cells[l+1].children[0].id];v.updateColumnWidth(l+1,L[l+1].width,!0,p),O.maxWidth=O.wrapper.maxWidth=L[l+1].width}t.width=t.wrapper.width=t.wrapper.children[0].width=v.width}else{r=n.nameTable[v.rows[i+l].cells[0].children[0].id];var N=v.rowDefinitions(),T=N[i+l].height;(function hne(n,t,e,i,r){for(var o,a,l=e.rows[parseInt(i.toString(),10)],h=e.rows[i+1],c=e.rows[i-1],d=1;di+l+1&&v.updateRowHeight(i+l+1,T=N[i+l+1].height,!0,p),t.height=t.wrapper.height=t.wrapper.children[0].height=v.actualSize.height}if(Qp(t),t.width=t.wrapper.actualSize.width,Oc(n,t),n.drag(t,c-t.wrapper.bounds.x,d-t.wrapper.bounds.y),RI(t,n),n.commandHandler.select(r),!(n.diagramActions&ee.UndoRedo)){var D={type:"PhaseCollectionChanged",changeType:"Insert",undoObject:$(A),redoObject:$(r),category:"Internal"};n.addHistoryEntry(D)}n.updateDiagramObject(t)}}}}function H3(n,t,e,i,r,s,o){var a,l,f,h=t.shape,c="Horizontal"===h.orientation,d=t.wrapper.children[0],g=c?s:o;e?(a=c?e.bounds.x+e.bounds.width:e.bounds.x,l=c?e.bounds.y:e.bounds.y+e.bounds.height):(a=d.bounds.x,l=r.bounds.y);var v=new Ne(a,l,i.desiredCellWidth,i.desiredCellHeight),S=Qv(n,0,t,{id:t.id+(c?h.lanes[g-2]:h.lanes[g-1]).id+Qe()[0],rowIndex:s,columnIndex:o,width:i.minWidth,height:i.minHeight,style:(c?h.lanes[g-2]:h.lanes[g-1]).style,constraints:ie.Default|ie.AllowDrop,container:{type:"Canvas",orientation:c?"Horizontal":"Vertical"}},!1,!1,!0);if(S.children[0].isCalculateDesiredSize=!1,d.addObject(S,s,o),r&&r.children&&r.children.length)for(f=0;f1)for(var f=1;fh.margin.left&&(h.margin.left=p)):(h.margin.top-=e.desiredCellHeight,p>h.margin.top&&(h.margin.top=p)))}(n,r,i,v,S,c,e)}function B3(n,t,e){if("SwimLane"===t.shape.type&&("ResizeSouth"===e||"ResizeEast"===e)){var i=t.shape,r=t.wrapper.children[0],s=void 0,o=void 0;"ResizeSouth"===e?"Vertical"===i.orientation?s=r.rows[r.rows.length-1].cells[0]:(o=r.rows.length-1,s=r.rows[parseInt(o.toString(),10)].cells[r.rows[parseInt(o.toString(),10)].cells.length-1]):(o=i.header&&i.hasHeader?1:0,s=r.rows[parseInt(o.toString(),10)].cells[r.rows[parseInt(o.toString(),10)].cells.length-1]),n.commandHandler.select(n.nameTable[s.children[0].id])}}function _I(n,t,e,i,r,s){var o,a,l,c,u,p,f,d=Qe(),g=n.shape,v=g.phases,y=n.offsetX-n.wrapper.actualSize.width/2,S=n.offsetY-n.wrapper.actualSize.height/2;if("Vertical"===g.orientation&&(S+=g.header&&g.hasHeader?g.header.height:0),!s)for(r||(n.id+=d,g&&g.header&&g.hasHeader?g.header.id+=d:g.header=void 0),o=0;v&&o0&&s.columnIndex>0||s.isLane)?(a=function Sne(n,t,e){for(var i=new Ne,r="SwimLane"===n.shape.type?n.wrapper.children[0].rows:n.wrapper.rows,s=e?1:0;s=0;a--)i?i.id===o.children[parseInt(a.toString(),10)].id&&o.children.splice(a,1):(n.removeDependentConnector(o.children[parseInt(a.toString(),10)]),n.diagramActions&ee.UndoRedo||(n.diagramActions=n.diagramActions|ee.UndoRedo,s=!0),n.remove(o.children[parseInt(a.toString(),10)]),o.children.splice(a,1),s&&(n.diagramActions=n.diagramActions&~ee.UndoRedo))}function dne(n){return n.children[0]}function qv(n,t){t&&(n.nodes.splice(n.nodes.indexOf(t),1),n.removeFromAQuad(t),n.removeObjectsFromLayer(t),delete n.nameTable[t.id],n.removeElements(t))}function _3(n,t,e,i){var r;if("SwimLane"===e.shape.type){var s=e.shape,o=void 0;if(1===s.lanes.length)n.remove(e);else{var a=e.wrapper.bounds.x,l=e.wrapper.bounds.y,h=void 0,c=void 0,d=void 0,u=void 0,f=e.wrapper.children[0];if(o=i?s.lanes.indexOf(i):HI(e,t),r={element:t,cause:n.diagramActions,diagramAction:n.getDiagramAction(n.diagramActions),state:"Changing",type:"Removal",cancel:!1,laneIndex:o},n.triggerEvent(Ce.collectionChange,r),!r.cancel){var g=s.lanes[parseInt(o.toString(),10)],v=g.children;g.children=[];for(var y=0;y0)for(u=0;u0)for(u=0;u0)for(e=0;e1){c===l.phases.length-1&&(o=!0,a=$(l.phases[c-1]));var u=$(l.phases[parseInt(c.toString(),10)]);if(l.phases.splice(c,1),!(n.diagramActions&ee.UndoRedo)){var p={type:"PhaseCollectionChanged",changeType:"Remove",undoObject:u,previousPhase:a,redoObject:$(t),category:"Internal",isLastPhase:o};n.addHistoryEntry(p)}"Horizontal"===l.orientation?function pne(n,t,e,i){var r,s,o,a,l,h,c,d,u,p,f,g;for(i=void 0!==i?i:e.columnIndex,c=0;c1&&(s=r.cells[parseInt(i.toString(),10)],l=(o=r.cells.length-1===i?r.cells[i-1]:r.cells[i+1]).children[0],s.children.length>0))if(f=n.nameTable[(a=s.children[0]).id],0===o.children.length&&s.children.length>0)o.children=s.children,o.columnSpan=s.columnSpan-1;else{for(d=0;d0){var M=s.children[0],w=n.nameTable[M.id];if(i=e.x&&a.bounds.y<=e.y&&a.bounds.bottom>=e.y)&&!(t.constraints&ie.AllowMovingOutsideLane)){var l=$(t);n.clearSelection(),W3(n,t),t.parentId="",t.parentObj=n,t.propName="nodes";var h={type:"ChildCollectionChanged",category:"Internal",undoObject:l,redoObject:$(t)};n.addHistoryEntry(h),n.commandHandler.isContainer&&(n.commandHandler.isContainer=!1,n.endGroupAction()),Y3(t,n)}n.protectPropertyChange(o)}}function UI(n,t){var e,i,r;return n.enableServerDataBinding(!1),ce()||(n.selectedObject.helperObject?r=n.selectedObject.helperObject:(n.selectedItems.nodes.length>0||n.selectedItems.connectors.length>0)&&(t instanceof oi&&t.nodes.length+t.connectors.length===1?(e=t.nodes.length>0?t.nodes[0]:t.connectors[0],i=n.selectedItems.wrapper.children[0]):(e=t,i=n.selectedItems.wrapper),n.selectedObject.actualObject=e,!n.currentSymbol&&(e.isLane&&Vx(e,n)&&cs(n,e)||!e.isLane&&cs(n,e)||n.constraints&rt.LineRouting&&n.selectedItems.nodes.length>0))&&(r=function Ine(n,t){for(var e,i={},r=0,s=Object.keys(t);r=t.x-e&&n.x<=t.x+e&&n.y>=t.y-e&&n.y<=t.y+e}function Xa(n){return n.selectedItems.nodes.length>0||n.selectedItems.connectors.length>0}function G3(n){return 1===n.selectedItems.connectors.length&&!n.selectedItems.nodes.length}function _r(n,t,e,i){if(void 0===e&&(e=!0),t instanceof oi)return!0;if(t instanceof te)for(;t;){if(-1!==n.selectedItems.nodes.indexOf(t)&&void 0===n.selectedItems.annotation)return!0;if(e)break;t=n.nameTable[t.parentId]}else if(t instanceof de){if(-1!==n.selectedItems.connectors.indexOf(t)&&void 0===n.selectedItems.annotation)return!0}else if((t instanceof Zn||t instanceof Nr)&&n.selectedItems.annotation&&n.selectedItems.wrapper.children[0].id===i.id)return!0;return!1}var Wx={None:"default",Rotate:"crosshair",Select:"default",Drag:"move",ResizeWest:"w-resize",ResizeEast:"e-resize",ResizeSouth:"s-resize",ResizeNorth:"n-resize",Draw:"crosshair",PortDraw:"crosshair",ResizeNorthEast:"ne-resize",ResizeNorthWest:"nw-resize",ResizeSouthEast:"se-resize",ResizeSouthWest:"sw-resize",ConnectorSourceEnd:"move",ConnectorTargetEnd:"move",BezierSourceThumb:"move",BezierTargetThumb:"move",OrthoThumb:"move",SegmentEnd:"move",Pan:"grab",Hyperlink:"pointer",PortDrag:"pointer",LabelSelect:"pointer",LabelDrag:"move",LabelRotate:"crosshair",LabelResizeWest:"w-resize",LabelResizeEast:"e-resize",LabelResizeSouth:"s-resize",LabelResizeNorth:"n-resize",LabelResizeNorthEast:"ne-resize",LabelResizeNorthWest:"nw-resize",LabelResizeSouthEast:"se-resize",LabelResizeSouthWest:"sw-resize"},ds=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Ld=function(n,t,e,i){return new(e||(e=Promise))(function(r,s){function o(h){try{l(i.next(h))}catch(c){s(c)}}function a(h){try{l(i.throw(h))}catch(c){s(c)}}function l(h){h.done?r(h.value):new e(function(c){c(h.value)}).then(o,a)}l((i=i.apply(n,t||[])).next())})},Nd=function(n,t){var i,r,s,o,e={label:0,sent:function(){if(1&s[0])throw s[1];return s[1]},trys:[],ops:[]};return o={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function a(h){return function(c){return function l(h){if(i)throw new TypeError("Generator is already executing.");for(;e;)try{if(i=1,r&&(s=2&h[0]?r.return:h[0]?r.throw||((s=r.return)&&s.call(r),0):r.next)&&!(s=s.call(r,h[1])).done)return s;switch(r=0,s&&(h=[2&h[0],s.value]),h[0]){case 0:case 1:s=h;break;case 4:return e.label++,{value:h[1],done:!1};case 5:e.label++,r=h[1],h=[0];continue;case 7:h=e.ops.pop(),e.trys.pop();continue;default:if(!(s=(s=e.trys).length>0&&s[s.length-1])&&(6===h[0]||2===h[0])){e=0;continue}if(3===h[0]&&(!s||h[1]>s[0]&&h[1]-1&&(r=i.fixedUserHandles[parseInt(o.toString(),10)]);this.commandHandler.triggerEvent(Ce.fixedUserHandleClick,{fixedUserHandle:r,element:e.source}),n.prototype.mouseUp.call(this,e)},t}(us),Od=function(n){function t(e,i){var r=n.call(this,e,!0)||this;return r.isConnected=!1,r.endPoint=i,r}return ds(t,n),t.prototype.mouseDown=function(e){return Ld(this,void 0,void 0,function(){var r,s,o,a,l;return Nd(this,function(h){if(this.inAction=!0,this.undoElement=void 0,this instanceof pa||(this.undoElement=$(e.source)),n.prototype.mouseDown.call(this,e),e.source&&e.source.connectors&&(this.oldConnector=$(r=e.source.connectors[0])),"BezierSourceThumb"===this.endPoint||"BezierTargetThumb"===this.endPoint)for(s=0;s0))},t.prototype.endAction=function(){n.prototype.endAction.call(this),this.prevPosition=null,this.endPoint=null},t}(us),ua=function(n){function t(e,i){var r=n.call(this,e,!0)||this;return r.currentTarget=null,r.isStartAction=!1,r.canCancel=!1,r.canTrigger=!1,r.objectType=i,r}return ds(t,n),t.prototype.mouseDown=function(e){if(e.source instanceof te||e.source instanceof de){var i=this.commandHandler.getSelectedObject();this.commandHandler.selectObjects([e.source],e.info&&e.info.ctrlKey,i);var r={nodes:[],connectors:[]};e.source instanceof te?r.nodes.push($(e.source)):r.connectors.push($(e.source)),this.undoElement=$(r)}else this.undoElement=$(e.source);this.undoParentElement=this.commandHandler.getSubProcess(e.source),"Port"===this.objectType&&(this.portId=e.sourceWrapper.id),this.commandHandler.insertBlazorConnector(e.source),n.prototype.mouseDown.call(this,e),this.initialOffset={x:0,y:0}},t.prototype.mouseUp=function(e,i){return Ld(this,void 0,void 0,function(){var s,o,a,l,h,c,d,u,f,g,v,y,S,b,M;return Nd(this,function(w){if(this.checkPropertyValue(),a=!1,h={nodes:[],connectors:[]},"Port"!==this.objectType){if(e.source instanceof te||e.source instanceof de?(e.source instanceof te?h.nodes.push($(e.source)):h.connectors.push($(e.source)),(o=$(h)).offsetX=(c=e.source.wrapper).offsetX,o.offsetY=c.offsetY):o=$(e.source),("helper"===(l=this.commandHandler.renderContainerHelper(e.source)||e.source||this.commandHandler.renderContainerHelper(e.source)).id||"helper"!==l.id)&&((l instanceof oi&&(Math.round(l.width)===Math.round(this.undoElement.width)&&Math.round(l.height)===Math.round(this.undoElement.height)||l.selectedObjects&&1===l.selectedObjects.length)||!(l instanceof oi))&&(l.offsetX!==this.undoElement.offsetX||l.offsetY!==this.undoElement.offsetY||l.sourcePoint!==this.undoElement.sourcePoint||l.targetPoint!==this.undoElement.targetPoint)||this.isSelectionHasConnector(l))&&(e.source&&(s={offsetX:e.source.wrapper.offsetX,offsetY:e.source.wrapper.offsetY}),g={source:e.source,state:"Completed",oldValue:this.intialValue,newValue:s,target:this.currentTarget,targetPosition:this.currentPosition,allowDrop:(g={source:e.source,state:"Completed",oldValue:this.intialValue,newValue:s,target:this.currentTarget,targetPosition:this.currentPosition,allowDrop:!0,cancel:!1}).allowDrop,cancel:g.cancel},d=!0,"helper"===l.id?this.canTrigger?(this.commandHandler.triggerEvent(Ce.positionChange,g),this.connectorEndPointChangeEvent(g),d=!0):d=!1:(this.commandHandler.triggerEvent(Ce.positionChange,g),this.connectorEndPointChangeEvent(g)),!i&&d&&(this.commandHandler.startGroupAction(),a=!0,M={type:"PositionChanged",redoObject:$(o),undoObject:$(this.undoElement),category:"Internal"},o.nodes[0]&&o.nodes[0].processId&&(u={type:"SizeChanged",category:"Internal",undoObject:this.undoParentElement,redoObject:this.commandHandler.getSubProcess(e.source)},this.commandHandler.addHistoryEntry(u)),this.commandHandler.addHistoryEntry(M))),this.commandHandler.snapPoint(this.prevPosition,this.currentPosition,0,0),this.commandHandler.removeSnap(),this.commandHandler.removeHighlighter(),e.source&&this.currentTarget&&OI(this.currentTarget)&&this.commandHandler.isDroppable(e.source,this.currentTarget)){if(f=!0,this.commandHandler.drop(this.currentElement,this.currentTarget,this.currentPosition),this.currentTarget&&this.currentTarget instanceof de&&!0===this.commandHandler.diagram.enableConnectorSplit)if(this.currentElement&&this.currentElement instanceof te){if(void 0!==this.currentElement.children)for(b=0;b0)for(var s=0;s0)for(var a=0;a0)for(a=0;a0&&e.connectors.length>0)||e.width===this.undoElement.width&&e.height===this.undoElement.height)},t.prototype.mouseMove=function(e){n.prototype.mouseMove.call(this,e);var r,s,i=!1;(r=this.commandHandler.renderContainerHelper(e.source)||e.source)instanceof te||r instanceof de?r instanceof te?r.offsetX===this.undoElement.nodes[0].offsetX&&r.offsetY===this.undoElement.nodes[0].offsetY&&(i=!0):z.equals(r.sourcePoint,this.undoElement.connectors[0].sourcePoint)&&z.equals(r.targetPoint,this.undoElement.connectors[0].targetPoint)&&(i=!0):r.wrapper.offsetX===this.undoElement.wrapper.offsetX&&r.wrapper.offsetY===this.undoElement.wrapper.offsetY&&(i=!0),r&&(s={offsetX:r.wrapper.offsetX,offsetY:r.wrapper.offsetY});var o={source:r,state:"Start",oldValue:s,newValue:s,target:e.target,targetPosition:e.position,allowDrop:!0,cancel:!1};if(o={source:r,state:"Start",oldValue:s,newValue:s,target:e.target,targetPosition:e.position,allowDrop:o.allowDrop,cancel:o.cancel},this.isStartAction||(this.intialValue={offsetX:r.wrapper.offsetX,offsetY:r.wrapper.offsetY}),i&&!ce()&&(this.commandHandler.triggerEvent(Ce.positionChange,o),this.connectorEndPointChangeEvent(o),this.isStartAction=!0),this.currentPosition=e.position,"Port"!==this.objectType){var h=this.initialOffset.x+(this.currentPosition.x-this.prevPosition.x),c=this.initialOffset.y+(this.currentPosition.y-this.prevPosition.y);this.commandHandler.dragOverElement(e,this.currentPosition),this.commandHandler.disConnect(e.source),this.commandHandler.removeSnap();var d,u=void 0,p=this.commandHandler.snapPoint(this.prevPosition,this.currentPosition,h,c);this.initialOffset.x=h-p.x,this.initialOffset.y=c-p.y,r&&(d={offsetX:r.wrapper.offsetX,offsetY:r.wrapper.offsetY},u={offsetX:r.wrapper.offsetX+p.x,offsetY:r.wrapper.offsetY+p.y}),this.currentTarget&&e.target!==this.currentTarget&&this.commandHandler.removeChildFromBPmn(e.source,e.target,this.currentTarget),this.currentTarget=e.target;var f={source:r,state:"Progress",oldValue:d,newValue:u,target:e.target,targetPosition:e.position,allowDrop:!0,cancel:!1};if(this.commandHandler.triggerEvent(Ce.positionChange,f),this.canTrigger=!0,this.connectorEndPointChangeEvent(f,p),!f.cancel&&!this.canCancel){this.blocked=!this.commandHandler.dragSelectedObjects(p.x,p.y);var g=!this.commandHandler.mouseOver(this.currentElement,this.currentTarget,this.currentPosition);this.blocked=this.blocked||g}if(this.commandHandler.removeStackHighlighter(),this.commandHandler.renderStackHighlighter(e),this.currentTarget&&e.source!==this.currentTarget&&this.commandHandler.isDroppable(e.source,this.currentTarget)&&"helper"!==e.source.id){var v=e.source instanceof oi?e.source.nodes[0]:e.source;!this.commandHandler.isParentAsContainer(v,!0)&&"SwimLane"!==v.shape.type&&!v.shape.isPhase&&(this.currentTarget.isLane?this.commandHandler.renderStackHighlighter(e,this.currentTarget):this.commandHandler.drawHighlighter(this.currentTarget))}else this.commandHandler.removeHighlighter();if(this.commandHandler.canEnableDefaultTooltip()){var y=this.getTooltipContent(e.source);this.commandHandler.showTooltip(e.source,e.position,ko(function(){return y}),"MoveTool",this.isTooltipVisible),this.isTooltipVisible=!1}}else{var b=Hi(),M=e.source;qi(b,-M.rotateAngle||-M.wrapper.rotateAngle,M.offsetX||M.wrapper.offsetX,M.offsetY||M.wrapper.offsetY);var w=Je(b,{x:this.prevPosition.x,y:this.prevPosition.y}),C=Je(b,{x:e.position.x,y:e.position.y});this.commandHandler.portDrag(e.source,e.sourceWrapper,C.x-w.x,C.y-w.y)}return this.prevPosition=this.currentPosition,!this.blocked},t.prototype.getTooltipContent=function(e){return"X:"+Math.round(e.wrapper.bounds.x)+" Y:"+Math.round(e.wrapper.bounds.y)},t.prototype.mouseLeave=function(e){this.mouseUp(e)},t.prototype.endAction=function(){n.prototype.endAction.call(this),this.currentTarget=null,this.prevPosition=null},t}(us),Yx=function(n){function t(e){var i=n.call(this,e,!0)||this;return i.rotateStart=!1,i}return ds(t,n),t.prototype.mouseDown=function(e){if(this.undoElement=$(e.source),this.undoElement.nodes[0]&&this.undoElement.nodes[0].children)for(var r=this.commandHandler.getAllDescendants(this.undoElement.nodes[0],[]),s=0;s=2){var s=e.startTouches[0],o=e.startTouches[1],a=e.moveTouches[0],l=e.moveTouches[1],h=this.getDistance(a,l)/this.getDistance(s,o);this.commandHandler.zoom(h,0,0,e.position),this.updateTouch(s,a),this.updateTouch(o,l)}}else this.commandHandler.scroll(this.currentPosition.x-this.prevPosition.x,this.currentPosition.y-this.prevPosition.y,this.currentPosition);return this.commandHandler.dataBinding(),!this.blocked},t.prototype.mouseUp=function(e){this.commandHandler.setBlazorDiagramProps(!1),this.checkPropertyValue(),this.commandHandler.updatePanState(!1),n.prototype.mouseUp.call(this,e),this.inAction=!1},t.prototype.endAction=function(){n.prototype.endAction.call(this)},t.prototype.getDistance=function(e,i){var r=i.pageX-e.pageX,s=i.pageY-e.pageY;return Math.sqrt(r*r+s*s)},t.prototype.updateTouch=function(e,i){e.pageX=i.pageX,e.pageY=i.pageY},t}(us),Lne=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseUp=function(e){this.checkPropertyValue(),this.commandHandler.initExpand(e),n.prototype.mouseUp.call(this,e)},t}(us),X3=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseUp=function(e){this.checkPropertyValue();var i="_blank",r="",s=window.innerHeight,o=window.innerWidth,a=window.screenTop,l=window.screenLeft;"CurrentTab"===e.sourceWrapper.hyperlink.hyperlinkOpenState?i="_self":"NewWindow"===e.sourceWrapper.hyperlink.hyperlinkOpenState&&(r="height="+s+",width="+o+",top="+a+",left="+l),window.open(e.sourceWrapper.hyperlink.link,i,r).focus(),n.prototype.mouseUp.call(this,e)},t}(us),Oh=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseDown=function(e){if(n.prototype.mouseDown.call(this,e),this.inAction=!0,this.drawingObject){var r=void 0,s=this.drawingObject.shape;this.drawingObject.shape.points.push(r={x:(r=s.points[s.points.length-1]).x,y:r.y})}else this.startPoint={x:this.startPosition.x,y:this.startPosition.y},this.drawingObject=this.commandHandler.drawObject({offsetX:this.currentPosition.x,offsetY:this.currentPosition.y,width:5,height:5,style:{strokeColor:"black",strokeWidth:1},shape:{type:"Basic",shape:"Polygon",points:[{x:this.startPoint.x,y:this.startPoint.y},{x:this.currentPosition.x,y:this.currentPosition.y}]}})},t.prototype.mouseMove=function(e){if(n.prototype.mouseMove.call(this,e),this.inAction){var i=this.drawingObject.shape;if(i.points[i.points.length-1].x=this.currentPosition.x,i.points[i.points.length-1].y=this.currentPosition.y,this.drawingObject.wrapper.children[0].data=vx(this.drawingObject.shape.points),this.inAction&&!1===z.equals(this.currentPosition,this.prevPosition)){var r=Ne.toBounds(this.drawingObject.shape.points);this.commandHandler.updateNodeDimension(this.drawingObject,r)}}return!0},t.prototype.mouseUp=function(e,i){this.checkPropertyValue(),n.prototype.mouseMove.call(this,e),this.inAction&&(this.inAction=!1,this.commandHandler.addObjectToDiagram(this.drawingObject)),this.endAction()},t.prototype.mouseWheel=function(e){n.prototype.mouseWheel.call(this,e),this.mouseMove(e)},t.prototype.endAction=function(){this.inAction=!1,this.drawingObject=null},t}(us),kh=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseMove=function(e){if(n.prototype.mouseMove.call(this,e),this.inAction){var i=this.drawingObject;i.targetPoint=this.currentPosition,this.commandHandler.updateConnectorPoints(i)}return!0},t.prototype.mouseDown=function(e){if(n.prototype.mouseDown.call(this,e),this.inAction=!0,this.drawingObject){var r=this.drawingObject,s=void 0;(s=new kl(r,"segments",{type:"Straight"},!0)).point=this.currentPosition,r.segments[r.segments.length-1]=s}else this.drawingObject=this.commandHandler.drawObject({id:"Connector",type:"Straight",sourcePoint:this.currentPosition,targetPoint:this.currentPosition})},t.prototype.mouseWheel=function(e){n.prototype.mouseWheel.call(this,e),this.mouseMove(e)},t.prototype.mouseUp=function(e){if(this.checkPropertyValue(),n.prototype.mouseMove.call(this,e),this.inAction&&this.drawingObject){var i=this.drawingObject;i.segments[i.segments.length-1].point={x:0,y:0},this.commandHandler.addObjectToDiagram(this.drawingObject)}this.endAction()},t.prototype.endAction=function(){this.drawingObject=null,this.inAction=!1},t}(us),Nne=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseDown=function(e){this.inAction=!0,this.undoElement=$(e.source),this.annotationId=e.sourceWrapper.id,n.prototype.mouseDown.call(this,e)},t.prototype.mouseMove=function(e){n.prototype.mouseMove.call(this,e);var i=this.currentPosition.x-this.prevPosition.x,r=this.currentPosition.y-this.prevPosition.y,s=e.source;if(s instanceof te){var o=Hi();qi(o,-s.rotateAngle,0,0);var a=Je(o,{x:i,y:r});i=a.x,r=a.y}return this.inAction&&(this.commandHandler.labelDrag(e.source,e.sourceWrapper,i,r),this.commandHandler.updateSelector()),this.prevPosition=this.currentPosition,!this.blocked},t.prototype.mouseUp=function(e){this.checkPropertyValue();var i=e.source;this.inAction=!1;var r={type:"AnnotationPropertyChanged",objectId:this.annotationId,undoObject:$(this.undoElement),category:"Internal",redoObject:$(i)};this.commandHandler.addHistoryEntry(r),n.prototype.mouseUp.call(this,e)},t.prototype.mouseLeave=function(e){this.mouseUp(e)},t}(us),One=function(n){function t(e,i){var r=n.call(this,e,!0)||this;return r.corner=i,r}return ds(t,n),t.prototype.mouseDown=function(e){this.inAction=!0;var i=e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0];this.annotationId=e.source.wrapper.children[0].id,this.undoElement=$(i);var r=e.source.wrapper.children[0];this.initialBounds={x:r.offsetX,y:r.offsetY,width:r.actualSize.width,height:r.actualSize.height},n.prototype.mouseDown.call(this,e)},t.prototype.mouseMove=function(e){return n.prototype.mouseMove.call(this,e),this.inAction&&this.resizeObject(e),!this.blocked},t.prototype.mouseUp=function(e){this.checkPropertyValue();var i=e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0];this.inAction=!1;var r={type:"AnnotationPropertyChanged",objectId:this.annotationId,redoObject:$(i),undoObject:$(this.undoElement),category:"Internal"};this.commandHandler.addHistoryEntry(r),n.prototype.mouseUp.call(this,e)},t.prototype.mouseLeave=function(e){this.mouseUp(e)},t.prototype.resizeObject=function(e){var i,s,o,r=e.source.wrapper.children[0],a={x:r.offsetX,y:r.offsetY},l=r.rotateAngle;l=((l+=(i=e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0])instanceof te?i.rotateAngle:0)+360)%360;var h=Hi();qi(h,l,a.x,a.y);var c=this.corner.slice(5),d=this.updateSize(r,this.startPosition,this.currentPosition,c,this.initialBounds,l),u=r.offsetX-r.actualSize.width*r.pivot.x,p=r.offsetY-r.actualSize.height*r.pivot.y,f=this.getPivot(c),g=Je(h,f={x:u+r.actualSize.width*f.x,y:p+r.actualSize.height*f.y});d.x=g.x,d.y=g.y,this.commandHandler.labelResize(i,e.source.annotation,s=(s=d.width)<0?1:s,o=(o=d.height)<0?1:o,d,e.source),this.commandHandler.updateSelector()},t}(us),kne=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseDown=function(e){this.inAction=!0,this.annotationId=e.source.wrapper.children[0].id,this.undoElement=$(e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0]),n.prototype.mouseDown.call(this,e)},t.prototype.mouseMove=function(e){return n.prototype.mouseMove.call(this,e),e.source&&this.inAction&&(this.commandHandler.labelRotate(e.source.nodes[0]?e.source.nodes[0]:e.source.connectors[0],e.source.annotation,this.currentPosition,e.source),this.commandHandler.updateSelector()),this.prevPosition=this.currentPosition,!this.blocked},t.prototype.mouseUp=function(e){this.checkPropertyValue(),this.inAction=!1;var r={type:"AnnotationPropertyChanged",objectId:this.annotationId,redoObject:$(e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0]),undoObject:$(this.undoElement),category:"Internal"};this.commandHandler.addHistoryEntry(r),n.prototype.mouseUp.call(this,e)},t.prototype.mouseLeave=function(e){this.mouseUp(e)},t}(us),Pne=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseMove=function(e){if(n.prototype.mouseMove.call(this,e),this.inAction){var i=this.drawingObject.shape;if(i.points.push(this.currentPosition),this.drawingObject.wrapper.children[0].data=mx(this.drawingObject.shape.points),i.data=mx(i.points),this.inAction&&!1===z.equals(this.currentPosition,this.prevPosition)){var s=Ne.toBounds(this.drawingObject.shape.points);this.commandHandler.updateNodeDimension(this.drawingObject,s)}}return!0},t.prototype.mouseDown=function(e){n.prototype.mouseDown.call(this,e),this.inAction=!0,this.startPoint={x:this.startPosition.x,y:this.startPosition.y},this.drawingObject=this.commandHandler.drawObject({offsetX:this.currentPosition.x,offsetY:this.currentPosition.y,width:5,height:5,style:{strokeColor:"black",strokeWidth:1,fill:"transparent"},shape:{type:"Path",points:[{x:this.startPoint.x,y:this.startPoint.y},{x:this.currentPosition.x,y:this.currentPosition.y}]}})},t.prototype.mouseUp=function(e){if(this.checkPropertyValue(),this.inAction){this.inAction=!1;var s=this.drawingObject.shape,o=s.points;this.commandHandler.addObjectToDiagram(this.drawingObject),this.commandHandler.diagram.remove(this.commandHandler.diagram.nameTable[""+this.drawingObject.id]),o=this.pointReduction(o,10);var h={id:"newConnector"+Qe(),type:"Bezier",sourcePoint:{x:o[0].x,y:o[0].y},targetPoint:{x:o[o.length-1].x,y:o[o.length-1].y},segments:[],bezierSettings:{allowSegmentsReset:!1}};this.drawingObject=this.commandHandler.drawObject(h),this.drawingObject=this.bezierCurveSmoothness(o,.5,this.drawingObject,s),this.commandHandler.updateConnectorPoints(this.drawingObject),this.commandHandler.addObjectToDiagram(this.drawingObject),n.prototype.mouseUp.call(this,e)}},t.prototype.pointReduction=function(e,i){if(null===e||e.length<3)return e;var s=e.length-1,o=[];for(o.push(0),o.push(s);e[parseInt((0).toString(),10)]===e[parseInt(s.toString(),10)];)s--;this.reduction(e,0,s,i,o);var a=[];return o.sort(function(l,h){return l-h}),o.forEach(function(l){a.push(e[parseInt(l.toString(),10)])}),a},t.prototype.reduction=function(e,i,r,s,o){for(var a=0,l=0,h=i;ha&&(a=c,l=h)}a>s&&0!==l&&(o.push(l),this.reduction(e,i,l,s,o),this.reduction(e,l,r,s,o))},t.prototype.perpendicularDistance=function(e,i,r){return Math.abs(.5*(e.x*i.y-i.x*e.y+(i.x*r.y-r.x*i.y)+(r.x*e.y-e.x*r.y)))/Math.sqrt(Math.pow(e.x-i.x,2)+Math.pow(e.y-i.y,2))*2},t.prototype.bezierCurveSmoothness=function(e,i,r,s){if(e.length<3)return r;for(var o=0;o=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},zne=function(n){if(n)switch(n.type){case"Bpmn":return Fne;case"UmlActivity":return Bne;case"UmlClassifier":return jne;default:return Kv}return Kv},Rne=function(n){if(n)switch(n.type){case"Straight":default:return kl;case"Bezier":return ps;case"Orthogonal":return bi}},q3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I(10)],t.prototype,"width",void 0),Pe([I(10)],t.prototype,"height",void 0),Pe([I("Arrow")],t.prototype,"shape",void 0),Pe([re({fill:"black",strokeColor:"black",strokeWidth:1},Al)],t.prototype,"style",void 0),Pe([re({x:0,y:.5},z)],t.prototype,"pivot",void 0),Pe([I("")],t.prototype,"pathData",void 0),t}(Ee),YI=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I(0)],t.prototype,"angle",void 0),Pe([I(0)],t.prototype,"distance",void 0),t}(Ee),Hne=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I(bx.All)],t.prototype,"controlPointsVisibility",void 0),Pe([I("FreeForm")],t.prototype,"segmentEditOrientation",void 0),Pe([I(mI.Default)],t.prototype,"smoothness",void 0),Pe([I(!0)],t.prototype,"allowSegmentsReset",void 0),t}(Ee),Kv=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I("None")],t.prototype,"type",void 0),t}(Ee),Bne=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I("Object")],t.prototype,"flow",void 0),Pe([I(30)],t.prototype,"exceptionFlowHeight",void 0),t}(Kv),Fne=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I("Sequence")],t.prototype,"flow",void 0),Pe([I("Normal")],t.prototype,"sequence",void 0),Pe([I("Default")],t.prototype,"message",void 0),Pe([I("Default")],t.prototype,"association",void 0),t}(Kv),$3=function(n){function t(e,i,r,s){var o=n.call(this,e,i,r,s)||this;return o.points=[],o}return Qs(t,n),Pe([I("Straight")],t.prototype,"type",void 0),Pe([I(!0)],t.prototype,"allowDrag",void 0),t}(Ee),kl=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),t.prototype.getClassName=function(){return"StraightSegment"},Pe([re({x:0,y:0},z)],t.prototype,"point",void 0),t}($3),ps=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),t.prototype.getClassName=function(){return"BezierSegment"},t.prototype.getPoints=function(e,i){var r=[];if(r.length>0||null!=i){var o=this.bezireToPoly(r.length>0?r[r.length-1]:i,e);r.push.apply(r,o)}return r},t.prototype.bezireToPoly=function(e,i){var r=[];return i&&this.flattenCubicBezier(r,e,i.bezierPoint1,i.bezierPoint2,{x:i.points[1].x,y:i.points[1].y},10),r},t.prototype.flattenCubicBezier=function(e,i,r,s,o,a){var h,l=(z.findLength(i,r)+z.findLength(r,s)+z.findLength(s,o))/a;for(h=0;h<=l;h++){var c=h/l;e.push({x:(1-c)*(1-c)*(1-c)*i.x+3*c*(1-c)*(1-c)*r.x+3*c*c*(1-c)*s.x+c*c*c*o.x,y:(1-c)*(1-c)*(1-c)*i.y+3*c*(1-c)*(1-c)*r.y+3*c*c*(1-c)*s.y+c*c*c*o.y})}},Pe([I("Horizontal")],t.prototype,"orientation",void 0),Pe([re({x:0,y:0},z)],t.prototype,"point1",void 0),Pe([re({x:0,y:0},z)],t.prototype,"point2",void 0),Pe([re({angle:0,distance:0},YI)],t.prototype,"vector1",void 0),Pe([re({angle:0,distance:0},YI)],t.prototype,"vector2",void 0),t}(kl),bi=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),t.prototype.getClassName=function(){return"OrthogonalSegment"},Pe([I(null)],t.prototype,"length",void 0),Pe([I(null)],t.prototype,"direction",void 0),t}($3);function Z3(n,t,e){var s=e?45:180/(2+2/(n.height/n.width)),o=s,a=180-s,l=a+2*s,h=360-s,c=Gt(t,n.center);return c>o&&ca&&cl&&cMath.abs(t.y-n.y)?n.x=c)return s=z.findAngle(n[parseInt(d.toString(),10)],n[d+1]),{point:r=z.transform(n[parseInt(d.toString(),10)],s,c-(a||0)),index:l=d};a=o[parseInt(d.toString(),10)]}return{point:r,index:l}}(n,t),r=z.findAngle(n[i.index],n[i.index+1]),s=function vse(n){var e=0;switch(n.alignment){case"Center":case"After":e=0;break;case"Before":e=-0}return e}(t),o=z.transform(i.point,r+45,s);return i.point=o,i.angle=r,i}(i,e),h=l.point;s.id=this.id+"_"+e.id;var c=e.style;s.style={fill:c.fill,strokeColor:c.strokeColor,gradient:null,opacity:c.opacity,strokeDashArray:c.strokeDashArray,strokeWidth:c.strokeWidth},0===r.width&&(r.width=this.style.strokeWidth),0===r.height&&(r.height=this.style.strokeWidth);var d_y=(h.y-r.y)/r.height;a.x=r.width*((h.x-r.x)/r.width),a.y=r.height*d_y;var g,v,u=pF(e,l.angle,i),p=u.hAlign,f=u.vAlign;return"left"===p?(g="Left",a.x+=e.displacement.x):"right"===p?(g="Right",a.x-=e.displacement.x):"center"===p&&(g="Center"),"top"===f?(v="Top",a.y+=e.displacement.y):"bottom"===f?(v="Bottom",a.y-=e.displacement.y):"center"===f&&(v="Center"),s.horizontalAlignment=g,s.verticalAlignment=v,(s=im(s,o&&"Label"!==o.flipMode&&"None"!==o.flipMode?this.flip:"None",e)).float=!0,s.connectionDirection=e.connectionDirection,s.setOffsetWithRespectToBounds(a.x,a.y,"Absolute"),s.relativeMode="Point",s.visible=!(!ga(e,ri.Visible)||ga(e,ri.Hover)||ga(e,ri.Connect)),s.elementActions=s.elementActions|Xr.ElementIsPort,s},t.prototype.getConnectorRelation=function(){var e=this.shape;"Association"===e.relationship?(this.segments[0].type="Straight",this.sourceDecorator.shape="None",this.targetDecorator.shape="Arrow"):"Inheritance"===e.relationship?(this.segments[0].type="Orthogonal",this.sourceDecorator.shape="None",this.targetDecorator.shape="Arrow"):"Composition"===e.relationship||"Aggregation"===e.relationship?(this.segments[0].type="Orthogonal",this.sourceDecorator.shape="Diamond",this.targetDecorator.shape="None"):"Dependency"===e.relationship?(this.segments[0].type="Orthogonal",this.sourceDecorator.shape="None",this.targetDecorator.shape="OpenArrow"):"Realization"===e.relationship&&(this.segments[0].type="Orthogonal",this.sourceDecorator.shape="None",this.targetDecorator.shape="Arrow"),"BiDirectional"===e.associationType&&(this.sourceDecorator.shape="None",this.targetDecorator.shape="None");var i,o,r="",s="";e.multiplicity.source&&(e.multiplicity.source.lowerBounds=e.multiplicity.source.lowerBounds,e.multiplicity.source.upperBounds=e.multiplicity.source.upperBounds),e.multiplicity.target&&(e.multiplicity.target.lowerBounds=e.multiplicity.target.lowerBounds,e.multiplicity.target.upperBounds=e.multiplicity.target.upperBounds);var a=e.multiplicity.source,l=e.multiplicity.target;o=a.upperBounds?a.lowerBounds+"..."+a.upperBounds:a.lowerBounds,i=l.upperBounds?l.lowerBounds+"..."+l.upperBounds:l.lowerBounds,"ManyToOne"===e.multiplicity.type&&(e.multiplicity.target.optional=!1,r=o||"*",s="1"),"OneToMany"===e.multiplicity.type&&(e.multiplicity.source.optional=!1,s=i||"*",r="1"),"ManyToMany"===e.multiplicity.type&&(r=o||"*",s=i||"*"),"OneToOne"===e.multiplicity.type&&(e.multiplicity.target.optional=!1,e.multiplicity.source.optional=!1,r="1",s="1"),this.annotations=[{id:this.id+"sourcelabel",content:r,offset:0,alignment:"Before",margin:{right:5,bottom:5}},{id:this.id+"targetlabel",content:s,offset:1,alignment:"Before",margin:{right:5,bottom:5}}]},t.prototype.getBpmnSequenceFlow=function(){var e=new Ke,i=new Ke;return"Normal"===this.shape.sequence&&"Bezier"!==this.type&&(this.targetDecorator.shape="Arrow"),"Default"===this.shape.sequence&&(e=this.getSegmentElement(this,e),i=IF(this.intermediatePoints,this),this.targetDecorator.shape="Arrow"),"Conditional"===this.shape.sequence&&(this.targetDecorator.shape="Arrow",this.sourceDecorator.shape="Diamond",i.id=this.id+this.shape.type),i},t.prototype.getUMLObjectFlow=function(){if(this.annotations)for(var e=0;e0&&(this.sourcePoint=o[0],this.targetPoint=o[o.length-1]),o},t.prototype.clipDecorator=function(e,i,r,s){var a,l,o={x:0,y:0},h=i.length,c=z.distancePoints(a=r?i[0]:i[h-1],l=r?i[1]:i[h-2]);c=0===c?1:c;var d=1,u=r?e.sourceWrapper:e.targetWrapper;u&&(d=u.style.strokeWidth,s&&s&ee.DecoratorPropertyChange&&(d=1));var p=d-1;return o.x=Math.round(a.x+p*(l.x-a.x)/c),o.y=Math.round(a.y+p*(l.y-a.y)/c),(r&&"None"!==e.sourceDecorator.shape||!r&&"None"!==e.targetDecorator.shape)&&(o=z.adjustPoint(o,l,!0,s&ee.DecoratorPropertyChange?0:d/2)),o},t.prototype.clipDecorators=function(e,i,r){return"None"!==e.sourceDecorator.shape&&(i[0]=this.clipDecorator(e,i,!0,r)),"None"!==e.targetDecorator.shape&&(i[i.length-1]=this.clipDecorator(e,i,!1,r)),i},t.prototype.updateSegmentElement=function(e,i,r,s){var o=new Ne,a=this.getSegmentPath(e,i,s);if("Bezier"===e.type){if(this.segments.length>0)for(var l=0;l0)if("Straight"===e.type&&e.segments.length<2)for(var o=0;o1)for(o=0;o0&&"Bezier"!==this.type)for(var p=0;p0&&(a=p0&&(f<2*this.cornerRadius?(l=z.adjustPoint(h[parseInt(p.toString(),10)],h[p+1],!0,f/2),p0&&(s=this.bridgePath(e,s,p),"Orthogonal"===e.type&&(s=this.bridgePath(e,s,p+1))),s+=" L"+a.x+" "+a.y))}else if("Bezier"===this.type){var g=void 0,v=void 0;if(this.parentObj.element){var y=this.parentObj.element.ej2_instances[0].eventHandler.action;g=this.parentObj.element.ej2_instances[0].eventHandler.tool instanceof kd,v=y.includes("PortDraw")||y.includes("Drag")}for(var S=void 0,b=this.segments,M=0;M2&&(b[parseInt(M.toString(),10)].bezierPoint1={x:0,y:0},b[parseInt(M.toString(),10)].bezierPoint2={x:0,y:0}),!z.isEmptyPoint(b[parseInt(M.toString(),10)].point1)||b[parseInt(M.toString(),10)].vector1.angle||b[parseInt(M.toString(),10)].vector1.distance?b[parseInt(M.toString(),10)].vector1.angle||b[parseInt(M.toString(),10)].vector1.distance?b[parseInt(M.toString(),10)].bezierPoint1=z.transform(h[parseInt(M.toString(),10)],b[parseInt(M.toString(),10)].vector1.angle,b[parseInt(M.toString(),10)].vector1.distance):b[parseInt(M.toString(),10)].bezierPoint1={x:b[parseInt(M.toString(),10)].point1.x||b[parseInt(M.toString(),10)].bezierPoint1.x,y:b[parseInt(M.toString(),10)].point1.y||b[parseInt(M.toString(),10)].bezierPoint1.y}:((e.sourceID||this.sourcePortID)&&this.sourceWrapper&&!v&&!g&&(S=Z3(this.sourceWrapper.bounds,h[parseInt(M.toString(),10)],!0)),b[parseInt(M.toString(),10)].bezierPoint1=GI(h[parseInt(M.toString(),10)],h[M+1],S)),!z.isEmptyPoint(b[parseInt(M.toString(),10)].point2)||b[parseInt(M.toString(),10)].vector2.angle||b[parseInt(M.toString(),10)].vector2.distance?b[parseInt(M.toString(),10)].vector2.angle||b[parseInt(M.toString(),10)].vector2.distance?b[parseInt(M.toString(),10)].bezierPoint2=z.transform(h[M+1],b[parseInt(M.toString(),10)].vector2.angle,b[parseInt(M.toString(),10)].vector2.distance):b[parseInt(M.toString(),10)].bezierPoint2={x:b[parseInt(M.toString(),10)].point2.x||b[parseInt(M.toString(),10)].bezierPoint2.x,y:b[parseInt(M.toString(),10)].point2.y||b[parseInt(M.toString(),10)].bezierPoint2.y}:((e.targetID||this.targetPortID)&&this.targetWrapper&&!v&&!g&&(S=Z3(this.targetWrapper.bounds,h[M+1],!0)),b[parseInt(M.toString(),10)].bezierPoint2=GI(h[M+1],h[parseInt(M.toString(),10)],S));h.splice(1,0,{x:b[0].bezierPoint1.x,y:b[0].bezierPoint1.y}),h.splice(h.length-1,0,{x:b[b.length-1].bezierPoint2.x,y:b[b.length-1].bezierPoint2.y}),h=this.clipDecorators(e,h,r);for(var w=0;w0&&(s=this.bridgePath(e,s,D),s+=" L"+o.x+" "+o.y);return s},t.prototype.updateShapeElement=function(e){var i;switch(e.shape.type){case"Bpmn":e.wrapper.children[3]instanceof Ke&&(i=e.wrapper.children[3]),"Message"===e.shape.flow&&this.updateShapePosition(e,i);break;case"UmlActivity":"Exception"===e.shape.flow&&this.getUMLExceptionFlow(e.wrapper.children[0])}},t.prototype.updateShapePosition=function(e,i){var o=bF(this.intermediatePoints,i,.5);i.offsetX=o.x,i.offsetY=o.y},t.prototype.scale=function(e,i,r,s,o){var a=0,l=0;if(this.wrapper&&this.wrapper.outerBounds){var h=function M3(n){var t=n.wrapper.children[0].bounds;return"None"!==n.sourceDecorator.shape&&t.uniteRect(n.wrapper.children[1].bounds),"None"!==n.targetDecorator.shape&&t.uniteRect(n.wrapper.children[2].bounds),t}(this),c=Math.abs((this.wrapper.bounds.width||this.style.strokeWidth||1)-2),d=Math.abs((this.wrapper.bounds.height||this.style.strokeWidth||1)-2);a=h.width-c,l=h.height-d,e=Math.abs((r-Math.max(a,l))/c),i=Math.abs((s-Math.max(a,l))/d),a=l=Math.min(a,l)}e=i=Math.min(e,i);var u=Hi();qi(u,-(o=o||this.wrapper).rotateAngle,o.offsetX,o.offsetY),Wp(u,e,i,o.offsetX,o.offsetY),qi(u,o.rotateAngle,o.offsetX,o.offsetY);var p=function Lie(n,t){for(var e=[],i=0,r=t;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Wne=function(n){function t(e,i){var r=n.call(this,e,i)||this;return r.offset=0,r.scale=1,r}return Vne(t,n),t.prototype.preRender=function(){this.unWireEvents(),this.wireEvents()},t.prototype.render=function(){this.updateRulerGeometry(),this.renderComplete()},t.prototype.getModuleName=function(){return"Ruler"},t.prototype.destroy=function(){this.unWireEvents(),this.notify("destroy",{}),n.prototype.destroy.call(this),this.element.classList.remove("e-ruler")},t.prototype.getPersistData=function(){return this.addOnPersist(["loaded"])},t.prototype.onPropertyChanged=function(e,i){for(var r=0,s=Object.keys(e);r100;)r/=10,s/=10;for(;s<25;)r*=10,s*=10;return s>=25&&s%25!=0&&(s=25*Math.round(s/25)),s*e/r},t.prototype.createMarkerLine=function(e,i,r){var s;return i&&((s=e.getElementById(i.id+"_marker"))&&s.parentNode.removeChild(s),s=Bi("line",r)),s},t.prototype.drawRulerMarker=function(e,i,r){var s,o,h,d,u="Horizontal"===this.orientation,p=e.getElementsByTagName("svg");for(h=0;h0)for(var a=i.childNodes.length-1;a>=0;a--)i.childNodes[parseInt(a.toString(),10)].parentNode.removeChild(i.childNodes[parseInt(a.toString(),10)]);i.appendChild(s)}return s},t.prototype.wireEvents=function(){},t.prototype.unWireEvents=function(){},kc([I(5)],t.prototype,"interval",void 0),kc([I(100)],t.prototype,"segmentWidth",void 0),kc([I("Horizontal")],t.prototype,"orientation",void 0),kc([I("RightOrBottom")],t.prototype,"tickAlignment",void 0),kc([I("red")],t.prototype,"markerColor",void 0),kc([I(25)],t.prototype,"thickness",void 0),kc([I(null)],t.prototype,"arrangeTick",void 0),kc([I(400)],t.prototype,"length",void 0),t}(yi);function eF(n,t){var e=document.getElementById(n.element.id+(t?"_hRuler":"_vRuler")),i=qa(n),r=tF(n);e||(e=Tt("div",{id:n.element.id+(t?"_hRuler":"_vRuler"),style:"height:"+(t?i.height:r.height+100)+"px;overflow:hidden;width:"+(t?r.width+100:i.width)+"px;position:absolute;font-size:11px;"+(t?"margin-left:"+i.width+"px;":"margin-top:"+i.height+"px;")})),n.element.insertBefore(e,n.element.firstChild);var l=t?n.rulerSettings.horizontalRuler:n.rulerSettings.verticalRuler,h=new Wne(l);h.orientation=t?"Horizontal":"Vertical",h.length=(t?r.width:r.height)+l.segmentWidth,h.appendTo("#"+n.element.id+(t?"_hRuler":"_vRuler")),t?n.hRuler=h:n.vRuler=h;var c=document.getElementById(n.element.id+(t?"_hRuler":"_vRuler"));t?n.hRuler.element=c:n.vRuler.element=c}function XI(n){var t=-n.scroller.horizontalOffset,e=-n.scroller.verticalOffset;n&&n.rulerSettings.showRulers?(n.hRuler.length=0,n.vRuler.length=0,void 0!==t&&n.hRuler.element&&iF(n,n.hRuler,t,!0),void 0!==e&&n.vRuler.element&&iF(n,n.vRuler,e,!1)):Qx(n)}function Qx(n){an(n.element.id+"_hRuler"),an(n.element.id+"_vRuler"),an(n.element.id+"_overlapRuler")}function qa(n){var t=0,e=0;return n.rulerSettings.showRulers&&(t=n.rulerSettings.horizontalRuler.thickness,e=n.rulerSettings.verticalRuler.thickness),new me(e,t)}function tF(n){var t=qa(n),e=n.scroller.viewPortHeight,i=n.scroller.viewPortWidth;return i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},rF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return $ne(t,n),t.prototype.getClassName=function(){return"UserHandle"},Fn([I("")],t.prototype,"name",void 0),Fn([I("")],t.prototype,"pathData",void 0),Fn([I("")],t.prototype,"content",void 0),Fn([I("")],t.prototype,"source",void 0),Fn([I("#000000")],t.prototype,"backgroundColor",void 0),Fn([I("Top")],t.prototype,"side",void 0),Fn([I("")],t.prototype,"borderColor",void 0),Fn([I(.5)],t.prototype,"borderWidth",void 0),Fn([I(25)],t.prototype,"size",void 0),Fn([I("white")],t.prototype,"pathColor",void 0),Fn([I(10)],t.prototype,"displacement",void 0),Fn([I(!0)],t.prototype,"visible",void 0),Fn([I(0)],t.prototype,"offset",void 0),Fn([re({},$n)],t.prototype,"margin",void 0),Fn([I("Center")],t.prototype,"horizontalAlignment",void 0),Fn([I("Center")],t.prototype,"verticalAlignment",void 0),Fn([I(!1)],t.prototype,"disableNodes",void 0),Fn([I(!1)],t.prototype,"disableConnectors",void 0),Fn([re({},Ed)],t.prototype,"tooltip",void 0),Fn([I("")],t.prototype,"template",void 0),t}(Ee);function nF(n){return Zne[n.toString()]}var Zne={Action:"M 90 82.895 C 90 86.819 86.776 90 82.8 90 H 7.2 C 3.224 90 0 86.819 0 82.895 V 7.105 C 0 3.181 3.224 0 7.2 0 h 75.6 C 86.776 0 90 3.181 90 7.105 V 82.895 Z",Decision:"M10,19.707L0.293,10L10,0.293L19.707,10L10,19.707z",MergeNode:"M10,19.707L0.293,10L10,0.293L19.707,10L10,19.707z",InitialNode:"M10,19.5c-5.238,0-9.5-4.262-9.5-9.5S4.762,0.5,10,0.5s9.5,4.262,9.5,9.5S15.238,19.5,10,19.5z",ForkNode:"m0.75,0.75l636.00002,0l0,290l-636.00002,0l0,-290z",JoinNode:"m0.75,0.75l636.00002,0l0,290l-636.00002,0l0,-290z",TimeEvent:"M50.001,0.00286865 L25.001,25.0029 L0.000976562,0.00286865 L50.001,0.00286865 z M0.000976562,50.0029 L25.001,25.0029 L50.001,50.0029 L0.000976562,50.0029 z",AcceptingEvent:"M17.8336 32.164 L29.64 24 L17.32 16 L48.1664 16 L48.5 32 Z",SendSignal:"M48.164 31.8336 L56 23.832 L47.836 16 L16.168 16 L16.1668 31.8336 Z",ReceiveSignal:"M48.1664 31.8336 L39.836 24 L47.836 16 L16.168 16 L16.168 31.836 Z",StructuredNode:"M0,0 L50,0 L50,50 L0,50 z",Note:"M20 12 L4 12 L4 22 L22 22 L22 14 L20 14 L20 12 L22 14 Z"},qI=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),$a=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Jne=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return qI(t,n),$a([I()],t.prototype,"key",void 0),$a([I()],t.prototype,"keyModifiers",void 0),t}(Ee),sF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return qI(t,n),t.prototype.getClassName=function(){return"Command"},$a([I("")],t.prototype,"name",void 0),$a([I()],t.prototype,"canExecute",void 0),$a([I()],t.prototype,"execute",void 0),$a([re({},Jne)],t.prototype,"gesture",void 0),$a([I("")],t.prototype,"parameter",void 0),t}(Ee),Kne=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return qI(t,n),$a([Bt([],sF)],t.prototype,"commands",void 0),t}(Ee),ese=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return qI(t,n),$a([I()],t.prototype,"show",void 0),$a([I()],t.prototype,"showCustomMenuOnly",void 0),$a([I()],t.prototype,"items",void 0),t}(Ee),qp=function(){function n(){}return n.prototype.renderShadow=function(t,e,i,r){void 0===i&&(i=null);var l,o=z.transform({x:0,y:0},t.shadow.angle,t.shadow.distance);r&&(l=r.getElementById(e.id+"_shadow")),l||(l=document.createElementNS("http://www.w3.org/2000/svg",i?"path":"rect"),e.appendChild(l));var h={id:e.id+"_shadow",fill:t.shadow.color,stroke:t.shadow.color,opacity:t.shadow.opacity.toString(),transform:"rotate("+t.angle+","+(t.x+t.width*t.pivotX)+","+(t.y+t.height*t.pivotY)+")translate("+(t.x+o.x)+","+(t.y+o.y)+")"};if(r){var c=r.getElementById(e.id);c&&c.insertBefore(l,c.firstChild)}ai(l,h),i?i&&this.renderPath(l,t,i):ai(l,{width:t.width,height:t.height})},n.prototype.parseDashArray=function(t){return[]},n.prototype.drawRectangle=function(t,e,i,r,s,o,a,l,h){var c,d,u,p;e.shadow&&!r&&this.renderShadow(e,t,void 0,o),c=e.id===t.id?e.id+"_container":e.id,o&&(d=o.getElementById(c)),(!d||s)&&(d=document.createElementNS("http://www.w3.org/2000/svg","rect"),t.appendChild(d)),o&&!e.shadow&&(u=o.getElementById(e.id+"_groupElement_shadow"))&&u.parentNode.removeChild(u),p=l?{id:c,x:e.x.toString(),y:e.y.toString(),width:e.width.toString(),height:e.height.toString(),visibility:e.visible?"visible":"hidden",transform:"rotate("+e.angle+","+(e.x+e.width/2)+","+(e.y+e.height/2)+")",rx:e.cornerRadius||0,ry:e.cornerRadius||0,opacity:e.opacity}:{id:c,x:e.x.toString(),y:e.y.toString(),width:e.width.toString(),height:e.height.toString(),visibility:e.visible?"visible":"hidden",transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")",rx:e.cornerRadius||0,ry:e.cornerRadius||0,opacity:e.opacity},a&&(p.role="img",p["aria-label"]=a);var f=e.class||"";h||(f.includes("e-diagram-resize-handle")||f.includes("e-diagram-endpoint-handle")||f.includes("e-diagram-bezier-control-handle"))&&(f+=" e-disabled"),e.class&&(p.class=f),a||(p["pointer-events"]="none"),ai(d,p),this.setSvgStyle(d,e,i)},n.prototype.updateSelectionRegion=function(t,e){var i;i=t.parentNode.getElementById(e.id);var r={id:e.id,x:e.x.toString(),y:e.y.toString(),width:e.width.toString(),height:e.height.toString(),transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")",class:"e-diagram-selected-region"};i||(i=document.createElementNS("http://www.w3.org/2000/svg","rect"),t.appendChild(i)),this.setSvgStyle(i,e),ai(i,r)},n.prototype.createGElement=function(t,e){return Bi(t,e)},n.prototype.drawLine=function(t,e){var i=document.createElementNS("http://www.w3.org/2000/svg","line");this.setSvgStyle(i,e);var r=e.x+e.width*e.pivotX,s=e.y+e.height*e.pivotY,o={id:e.id,x1:e.startPoint.x+e.x,y1:e.startPoint.y+e.y,x2:e.endPoint.x+e.x,y2:e.endPoint.y+e.y,stroke:e.stroke,"stroke-width":e.strokeWidth.toString(),opacity:e.opacity.toString(),transform:"rotate("+e.angle+" "+r+" "+s+")",visibility:e.visible?"visible":"hidden"};e.class&&(o.class=e.class),ai(i,o),t.appendChild(i)},n.prototype.drawCircle=function(t,e,i,r){var s=document.createElementNS("http://www.w3.org/2000/svg","circle");this.setSvgStyle(s,e);var o=e.class||"";i||(o+=" e-disabled");var a={id:e.id,cx:e.centerX,cy:e.centerY,r:e.radius,visibility:e.visible?"visible":"hidden",class:o};r&&(a.role="img",a["aria-label"]=r),s.style.display=e.visible?"block":"none",ai(s,a),t.appendChild(s)},n.prototype.drawPath=function(t,e,i,r,s,o,a){var h,c,l=[];l=XB(l=Cd(e.data)),e.shadow&&this.renderShadow(e,t,l,s),s&&!e.shadow&&(h=s.getElementById(e.id+"_groupElement_shadow"))&&h.parentNode.removeChild(h),s&&(c=s.getElementById(e.id)),(!c||r)&&(c=document.createElementNS("http://www.w3.org/2000/svg","path"),t.appendChild(c)),this.renderPath(c,e,l);var d={};d=a?{id:e.id,transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")translate("+e.x+","+e.y+"),scale("+a+")",visibility:e.visible?"visible":"hidden",opacity:e.opacity}:{id:e.id,transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")translate("+e.x+","+e.y+")",visibility:e.visible?"visible":"hidden",opacity:e.opacity},o&&(d.role="img",d["aria-label"]=o),e.class&&(d.class=e.class),ai(c,d),this.setSvgStyle(c,e,i)},n.prototype.renderPath=function(t,e,i){var r,s,o,a,l,h,c,d,u=i,p="";for(l=0,h=0,d=0,c=u.length;de.width&&"Wrap"!==e.textOverflow&&"NoWrap"===e.textWrapping&&(h[0].text=VF(e.content,e)),v=0;vD&&(u.text=u.text.slice(0,u.text.length-3),u.text=u.text.concat("..."),l.data=u.text),this.alignText(y,p,u,l,f,g,v,e,h),C+=u.dy}}C&&e.isHorizontalLane&&(M=e.parentOffsetX+e.pivotX,w=e.parentOffsetY+e.pivotY,e.y=e.parentOffsetY-C*e.pivotY+.5),e.textDecoration&&"LineThrough"===e.textDecoration&&(e.textDecoration=hb(e.textDecoration));var R={id:e.id+"_text",fill:e.color,visibility:e.visible?"visible":"hidden","text-decoration":e.textDecoration,transform:"rotate("+e.angle+","+M+","+w+")translate("+e.x+","+e.y+")",opacity:e.opacity};r&&(R.role="img",R["aria-label"]=r),ai(y,R)}},n.prototype.alignText=function(t,e,i,r,s,o,a,l,h){"justify"!==l.textAlign?this.setText(t,e,i,r,s,o,l):a!==h.length-1?this.setText(t,e,i,r,s,o,l,l.width,"spacing"):this.setText(t,e,i,r,s,o,l)},n.prototype.setText=function(t,e,i,r,s,o,a,l,h){ai(e,"justify"!==a.textAlign?{x:s.toString(),y:o.toString()}:{x:s.toString(),y:o.toString(),textLength:l||0,lengthAdjust:h||"spacing"}),t.setAttribute("fill",i.text),e.appendChild(r),t.appendChild(e)},n.prototype.drawImage=function(t,e,i,r){var s;i&&(s=i.getElementById(e.id+"image")),s||(s=document.createElementNS("http://www.w3.org/2000/svg","image"),t.appendChild(s));var o=new Image;o.src=e.source;var a="None"!==e.scale?e.scale:"",l=e.alignment,h=l.charAt(0).toLowerCase()+l.slice(1);"Stretch"!==a&&(h+=" "+a.charAt(0).toLowerCase()+a.slice(1)),ai(s,{id:e.id+"image",x:e.x.toString(),y:e.y.toString(),transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")",width:e.width.toString(),visibility:e.visible?"visible":"hidden",height:e.height.toString(),preserveAspectRatio:h,opacity:e.opacity.toString()}),s.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",o.src.toString())},n.prototype.drawHTMLContent=function(t,e,i,r,s){var o,a;if(e&&(o=e.querySelector("#"+t.id+"_html_element")),!o){(a=e.querySelector("#"+t.id+"_html_element")||e.querySelector("#"+t.nodeId+"_html_element"))||(a=Tt("div",{id:t.nodeId+"_html_element",class:"foreign-object"})),o=Tt("div",{id:t.id+"_html_element",class:"foreign-object"});var c=document.getElementById(t.diagramId).ej2_instances[0],d=!1;if(e.parentNode&&e.parentNode.parentNode&&e.parentNode.parentNode.parentNode&&e.parentNode.parentNode.parentNode.classList.contains("e-overview")&&(d=!0),d)c.isReact?c.renderReactTemplates(function(){o.appendChild(t.template.cloneNode(!0))}):o.appendChild(t.template.cloneNode(!0));else{if("string"==typeof t.template){var u=document.createElement("div");u.innerHTML=t.template,t.template=u,c.selectedItems.userHandles.filter(function(g){return g.name===t.id.split("_shape")[0]&&""!==g.template})[0].template=t.template}t.isTemplate&&t.template?o.appendChild(t.template):t.template&&o.appendChild(t.template.cloneNode(!0))}void 0!==s&&e.childNodes.length>s&&e.insertBefore(o,e.childNodes[parseInt(s.toString(),10)]),a.appendChild(o),e.appendChild(a)}var f=En(t).topLeft;o.setAttribute("style","height:"+t.actualSize.height+"px; width:"+t.actualSize.width+"px;left:"+f.x+"px; top:"+f.y+"px;position:absolute;transform:rotate("+(t.rotateAngle+t.parentTransform)+"deg);pointer-events:"+(r?"all":"none")+";visibility:"+(t.visible?"visible":"hidden")+";opacity:"+t.style.opacity+";")},n.prototype.drawNativeContent=function(t,e,i,r,s){var o,a;if(s&&(o=s.getElementById(t.id+"_native_element"),a=s.getElementById(t.id+"_clip")),!o){(o=document.createElementNS("http://www.w3.org/2000/svg","g")).setAttribute("id",t.id+"_native_element"),o.appendChild(t.template.cloneNode(!0));var l=this.createGElement("g",{id:t.id+"_inner_native_element"});l.appendChild(o),e.appendChild(l)}a&&o.removeChild(a),o.setAttribute("style","visibility:"+(t.visible?"visible":"hidden")+";opacity:"+t.style.opacity+";"),this.setNativTransform(t,o,i,r),"Slice"===t.scale&&this.drawClipPath(t,o,i,r,s),ai(o,t.description?{role:"img","aria-label":t.description}:{})},n.prototype.setNativTransform=function(t,e,i,r){var s=0!==t.contentSize.width?t.contentSize.width:1,o=0!==t.contentSize.height?t.contentSize.height:1;e.setAttribute("transform","rotate("+t.parentTransform+","+t.offsetX+","+t.offsetY+") translate("+(t.offsetX-t.templatePosition.x*r/s-r*t.pivot.x)+","+(t.offsetY-t.templatePosition.y*i/o-i*t.pivot.y)+") scale("+r/s+","+i/o+")")},n.prototype.drawClipPath=function(t,e,i,r,s){var o=t.contentSize.width,a=t.contentSize.height,l=t.width/(r/o),h=t.height/(i/a),c=t.templatePosition.x+(t.width>=t.height?0:(o-l)/2),d=t.templatePosition.y+(t.height>=t.width?0:(a-h)/2),u=s.getElementById(t.id+"_clip");(u=document.createElementNS("http://www.w3.org/2000/svg","clipPath")).setAttribute("id",t.id+"_clip"),e.appendChild(u);var p=s.getElementById(t.id+"_clip_rect");return p=document.createElementNS("http://www.w3.org/2000/svg","rect"),u.appendChild(p),ai(p,{id:t.id+"_clip_rect",width:l.toString(),height:h.toString(),x:c.toString(),y:d.toString()}),nm()?e.setAttribute("clip-path","url("+location.protocol+"//"+location.host+location.pathname+"#"+t.id+"_clip)"):e.setAttribute("clip-path","url(#"+t.id+"_clip)"),e},n.prototype.renderGradient=function(t,e,i){var r,s,o,h,c,a=mT(i),l=a.getElementById(i+"gradient_pattern");if(l||(l=Bi("defs",{id:i+"gradient_pattern"}),a.insertBefore(l,a.firstChild)),gF(e.id),"None"!==t.gradient.type){for(var d=0;dt.width&&("Ellipsis"===t.textOverflow||"Clip"===t.textOverflow)&&"NoWrap"===t.textWrapping?0:.5*t.width:"right"===t.textAlign&&(c=1*t.width),s.x=0+c+(e?e.x:0),s.y=1.2+d-r.height/2,s},n}(),Pc=function(){function n(t,e,i){this.renderer=null,this.isSvgMode=!0,this.transform={x:0,y:0},this.diagramId=t,this.element=xt(this.diagramId),this.svgRenderer=e,this.isSvgMode=i,this.renderer=i?new qp:new bo}return n.prototype.setCursor=function(t,e){t.style.cursor=e},n.prototype.setLayers=function(){this.iconSvgLayer=this.element.getElementsByClassName("e-ports-expand-layer")[0],this.adornerSvgLayer=this.element.getElementsByClassName("e-adorner-layer")[0],this.nativeSvgLayer=this.element.getElementsByClassName("e-native-layer")[0],this.diagramSvgLayer=this.element.getElementsByClassName("e-diagram-layer")[0]},n.prototype.getAdornerLayer=function(){return gT(this.diagramId)},n.prototype.getParentSvg=function(t,e,i){return this.diagramId&&t&&t.id?t.id.split("_icon_content").length>1||t.id.split("_nodeport").length>1||t.elementActions&Xr.ElementIsPort?this.iconSvgLayer:e&&"selector"===e?this.adornerSvgLayer:t instanceof Cn?this.nativeSvgLayer:this.diagramSvgLayer:i},n.prototype.getParentElement=function(t,e,i,r){var s=e;if(i&&this.diagramId&&t&&t.id){t.id.split("_icon_content").length>1?(s=i.getElementById(this.diagramId+"_diagramExpander"),e=null):t.id.split("_nodeport").length>1?s=i.getElementById(this.diagramId+"_diagramPorts"):t instanceof Cn?(s=i.getElementById(this.diagramId+"_nativeLayer"),e=null):t.elementActions&Xr.ElementIsPort?(s=i.getElementById(this.diagramId+"_diagramPorts"),e=null):s=i.getElementById(this.diagramId+"_diagramLayer");var o=this.getGroupElement(t,e||s,r);s=o.g,o.svg&&(i=o.svg)}return{g:s,svg:i}},n.prototype.getGroupElement=function(t,e,i){var r,o,s=this.getParentSvg(t);if(e&&s){if(s&&!(r=s.getElementById(t.id+"_groupElement"))&&s!==this.nativeSvgLayer){var a=this.nativeSvgLayer;r=a.getElementById(t.id+"_groupElement"),o=a}r||(r=this.svgRenderer.createGElement("g",{id:t.id+"_groupElement"}),void 0!==i&&e.childNodes.length>i?e.insertBefore(r,e.childNodes[parseInt(i.toString(),10)]):e.appendChild(r))}return{g:r,svg:o}},n.prototype.renderElement=function(t,e,i,r,s,o,a,l,h,c,d){t instanceof Cs?(t.id=t.id?t.id:Qe(),this.renderContainer(t,e,i,r,s,o,a,l,h,c,d)):t instanceof SI?this.renderImageElement(t,e,r,s,a):t instanceof Ke?this.renderPathElement(t,e,r,s,a,h,d):t instanceof si?this.renderTextElement(t,e,r,s,a,c):t instanceof Cn?this.renderNativeElement(t,e,r,s,a):t instanceof Jn?this.renderHTMLElement(t,e,i,r,s,a,l):this.renderRect(t,e,r,s,h)},n.prototype.drawSelectionRectangle=function(t,e,i,r,s,o){var a={width:i*o.scale,height:r*o.scale,x:.5+(t=(t+o.tx)*o.scale),y:.5+(e=(e+o.ty)*o.scale),fill:"transparent",stroke:"gray",angle:0,pivotX:.5,pivotY:.5,strokeWidth:1,dashArray:"6 3",opacity:1,visible:!0,id:s.id+"_selected_region"},l=this.getAdornerLayer();this.svgRenderer.updateSelectionRegion(l,a)},n.prototype.renderHighlighter=function(t,e,i){var r=t.actualSize.width||2,s=t.actualSize.height||2,o=t.offsetX-r*t.pivot.x,a=t.offsetY-s*t.pivot.y;this.svgRenderer.drawRectangle(e,{width:r*i.scale,height:s*i.scale,x:o=(o+i.tx)*i.scale,y:a=(a+i.ty)*i.scale,fill:"transparent",stroke:"#8CC63F",angle:t.rotateAngle,pivotX:t.pivot.x,pivotY:t.pivot.y,strokeWidth:4,dashArray:"",opacity:1,cornerRadius:0,visible:!0,id:e.id+"_highlighter",class:"e-diagram-highlighter"},this.diagramId,void 0,void 0,e)},n.prototype.renderSelectionRectangle=function(t,e,i,r){var s=t.actualSize.width||2,o=t.actualSize.height||2,a=t.offsetX-s*t.pivot.x,l=t.offsetY-o*t.pivot.y,h={width:s*i.scale,height:o*i.scale,x:a=(a+i.tx)*i.scale,y:l=(l+i.ty)*i.scale,fill:"transparent",stroke:"#00cc00",angle:t.rotateAngle,pivotX:t.pivot.x,pivotY:t.pivot.y,strokeWidth:r?2:1,dashArray:"",opacity:1,cornerRadius:0,visible:!0,id:t.id+"_highlighter",class:r?"e-diagram-first-selection-indicator e-diagram-selection-indicator":"e-diagram-selection-indicator"},c=this.getParentSvg(t,"selector");this.svgRenderer.drawRectangle(e,h,this.diagramId,void 0,void 0,c)},n.prototype.renderSelectionLine=function(t,e,i,r){var s=this.getBaseAttributes(t,i);s.data=t.absolutePath,s.id=s.id+"_highlighter";var o=t.description?t.description:t.id;this.isSvgMode||(s.x=t.flipOffset.x?t.flipOffset.x:s.x,s.y=t.flipOffset.y?t.flipOffset.y:s.y),i&&(s.x=s.x*i.scale,s.y=s.y*i.scale),s.stroke="#00cc00",s.strokeWidth=r?2:1,s.class=r?"e-diagram-first-selection-indicator e-diagram-selection-indicator":"e-diagram-selection-indicator";var a=this.getParentSvg(t,"selector");this.svgRenderer.drawPath(e,s,this.diagramId,void 0,a,o,i.scale)},n.prototype.renderStackHighlighter=function(t,e,i,r,s,o,a){var l=t.actualSize.width||2,h=t.offsetX-l*t.pivot.x,c=t.actualSize.height||2,d=t.offsetY-c*t.pivot.y;h=(h+i.tx)*i.scale;var u,p=t.bounds,f="";if(d=(d+i.ty)*i.scale,r)if(o){var v,y;u="M 0 0 L "+(2+(g=l*i.scale))+" 0 Z",v=t.actualSize.width/Number(p.width?p.width:1)*i.scale,y=t.actualSize.height/Number(p.height?p.height:1)*i.scale,f=fI(gI(Cd("M7,4 L8,4 8,7 11,7 11,8 8,8 8,11 7,11 7,8 4,8 4,7 7,7 z M7.5,0.99999994C3.9160004,1 1,3.9160004 0.99999994,7.5 1,11.084 3.9160004,14 7.5,14 11.084,14 14,11.084 14,7.5 14,3.9160004 11.084,1 7.5,0.99999994 z M7.5,0 C11.636002,0 15,3.3639984 15,7.5 15,11.636002 11.636002,15 7.5,15 3.3640003,15 0,11.636002 0,7.5 0,3.3639984 3.3640003,0 7.5,0 z")),v+g+2,y-8,!1,p.x,p.y,0,0),s.y>=t.offsetY&&(d+=c)}else{var g;a&&s.y>=t.offsetY&&(d+=c*i.scale),u="M -10 -10 L 0 0 Z M -10 10 L 0 0 Z M 0 0 L "+(g=l*i.scale)+" 0 Z M "+g+" 0 L "+(g+10)+" 10 Z L "+(g+10)+" -10 Z"}else u="M 10 -10 L 0 0 Z M -10 -10 L 0 0 Z M 0 0 L 0 "+(g=c*i.scale)+" Z M 0 "+g+" L -10 "+(g+10)+" Z L 10 "+(g+10)+" Z",s.x>=t.offsetX&&(h+=l*i.scale);this.svgRenderer.drawPath(e,{data:u+f,width:l*i.scale,height:c*i.scale,x:h,y:d,fill:"transparent",stroke:"#8CC63F",angle:t.rotateAngle,pivotX:t.pivot.x,pivotY:t.pivot.y,strokeWidth:1,dashArray:"",opacity:1,visible:!0,id:e.id+"_stack_highlighter",class:"e-diagram-highlighter"},this.diagramId)},n.prototype.drawLine=function(t,e){this.svgRenderer.drawLine(t,e)},n.prototype.drawPath=function(t,e){this.svgRenderer.drawPath(t,e,this.diagramId)},n.prototype.renderResizeHandle=function(t,e,i,r,s,o,a,l,h,c,d){var u=t.offsetX-t.actualSize.width*t.pivot.x,p=t.offsetY-t.actualSize.height*t.pivot.y,f=t.actualSize.height,g=t.actualSize.width;!c&&i&bt.Rotate&&zI(this.rendererActions)&&!A3(this.rendererActions)&&(this.renderPivotLine(t,e,o,s,a),this.renderRotateThumb(t,e,o,s,a)),this.renderBorder(t,e,o,l,h,c);var v=t.actualSize.width*r,y=t.actualSize.height*r;!h&&zI(this.rendererActions)&&!A3(this.rendererActions)&&(t.isTextAnnotation||(v>=40&&y>=40&&(s&mr.ResizeNorthWest&&this.renderCircularHandle("resizeNorthWest",t,u,p,e,qr(s,"ResizeNorthWest"),i&bt.ResizeNorthWest,o,void 0,a,{"aria-label":"Thumb to resize the selected object on top left side direction"},void 0,"e-diagram-resize-handle e-northwest",d),s&mr.ResizeNorthEast&&this.renderCircularHandle("resizeNorthEast",t,u+g,p,e,qr(s,"ResizeNorthEast"),i&bt.ResizeNorthEast,o,void 0,a,{"aria-label":"Thumb to resize the selected object on top right side direction"},void 0,"e-diagram-resize-handle e-northeast",d),s&mr.ResizeSouthWest&&this.renderCircularHandle("resizeSouthWest",t,u,p+f,e,qr(s,"ResizeSouthWest"),i&bt.ResizeSouthWest,o,void 0,a,{"aria-label":"Thumb to resize the selected object on bottom left side direction"},void 0,"e-diagram-resize-handle e-southwest",d),s&mr.ResizeSouthEast&&this.renderCircularHandle("resizeSouthEast",t,u+g,p+f,e,qr(s,"ResizeSouthEast"),i&bt.ResizeSouthEast,o,void 0,a,{"aria-label":"Thumb to resize the selected object on bottom right side direction"},void 0,"e-diagram-resize-handle e-southeast",d)),s&mr.ResizeNorth&&this.renderCircularHandle("resizeNorth",t,u+g/2,p,e,qr(s,"ResizeNorth"),i&bt.ResizeNorth,o,void 0,a,{"aria-label":"Thumb to resize the selected object on top side direction"},void 0,"e-diagram-resize-handle e-north",d),s&mr.ResizeSouth&&this.renderCircularHandle("resizeSouth",t,u+g/2,p+f,e,qr(s,"ResizeSouth"),i&bt.ResizeSouth,o,void 0,a,{"aria-label":"Thumb to resize the selected object on bottom side direction"},void 0,"e-diagram-resize-handle e-south",d),s&mr.ResizeWest&&this.renderCircularHandle("resizeWest",t,u,p+f/2,e,qr(s,"ResizeWest"),i&bt.ResizeWest,o,void 0,a,{"aria-label":"Thumb to resize the selected object on left side direction"},void 0,"e-diagram-resize-handle e-west",d),s&mr.ResizeEast&&this.renderCircularHandle("resizeEast",t,u+g,p+f/2,e,qr(s,"ResizeEast"),i&bt.ResizeEast,o,void 0,a,{"aria-label":"Thumb to resize the selected object on right side direction"},void 0,"e-diagram-resize-handle e-east",d)))},n.prototype.renderEndPointHandle=function(t,e,i,r,s,o,a,l,h,c){var f,g,d=t.sourcePoint,u=t.targetPoint,p=t.wrapper;if(this.renderCircularHandle("connectorSourceThumb",p,d.x,d.y,e,qr(r,"ConnectorSourceThumb"),i&bt.ConnectorSource,s,o,void 0,{"aria-label":"Thumb to move the source point of the connector"},void 0,"e-diagram-endpoint-handle e-sourceend",c),this.renderCircularHandle("connectorTargetThumb",p,u.x,u.y,e,qr(r,"ConnectorTargetThumb"),i&bt.ConnectorTarget,s,a,void 0,{"aria-label":"Thumb to move the target point of the connector"},void 0,"e-diagram-endpoint-handle e-targetend",c),l)if("Straight"===t.type&&t.segments.length>0)for(f=0;f0)for(f=0;f=3&&3===t.segments.length&&(S=1,b=t.segments.length-1),S=t.segments.length>t.maxSegmentThumb+2?2:S,b=t.segments.length>t.maxSegmentThumb+2?t.segments.length-2:b,1===t.segments.length&&t.segments[0].points.length<=2&&(S=1,b=t.segments.length),f=S;f=50&&i.allowDrag),this.renderOrthogonalThumb(t+"_"+(d+1),e,(i.points[parseInt(d.toString(),10)].x+i.points[d+1].x)/2,(i.points[parseInt(d.toString(),10)].y+i.points[d+1].y)/2,r,h,l,o,a,u)}else for(d=0;d=50&&i.allowDrag),this.renderOrthogonalThumb(t+"_"+(d+1),e,(i.points[parseInt(d.toString(),10)].x+i.points[d+1].x)/2,(i.points[parseInt(d.toString(),10)].y+i.points[d+1].y)/2,r,h,l,o,a,u)},n.prototype.renderOrthogonalThumb=function(t,e,i,r,s,o,a,l,h,c){var d,g,u=0,p=document.getElementById(this.diagramId);p&&(g=p.ej2_instances[0]);var y=h.constraints&qe.InheritSegmentThumbShape?g.segmentThumbShape:h.segmentThumbShape,b=h.constraints&qe.InheritSegmentThumbSize?g.segmentThumbSize:h.segmentThumbSize;if(d="horizontal"===a?function tre(n){return sre[""+n]}(y):n3(y),"Arrow"===y||"DoubleArrow"===y||"OpenArrow"===y)switch(c){case"Bottom":case"Right":u=180;break;default:u=0}else if("Fletch"===y||"OpenFetch"===y||"IndentedArrow"===y||"OutdentedArrow"===y)switch(c){case"Bottom":u=-90;break;case"Top":u=90;break;case"Right":u=180;break;default:u=0}var M={x:(i+l.tx)*l.scale-b/2,y:(r+l.ty)*l.scale-b/2,angle:u,fill:"#e2e2e2",stroke:"black",strokeWidth:1,dashArray:"",data:d,width:b,height:b,pivotX:.5,pivotY:.5,opacity:1,visible:o,id:t,class:"e-diagram-ortho-segment-handle"},w=nf(M.data),C=new me(M.width,M.height),D=new Ke;M.data=D.updatePath(M.data,w,C),this.svgRenderer.drawPath(s,M,this.diagramId)},n.prototype.renderPivotLine=function(t,e,i,r,s){var o=t,l=!!(r&mr.Rotate);s&&(l=!1);var h=this.getBaseAttributes(o,i);h.fill="None",h.stroke="black",h.strokeWidth=1,h.dashArray="2,3",h.visible=l;var c=i.scale;h.x*=c,h.y*=c,h.width*=c,h.height*=c,h.id="pivotLine",h.class="e-diagram-pivot-line";var u={x:o.actualSize.width*o.pivot.x*c,y:0};h.startPoint={x:o.actualSize.width*o.pivot.x*c,y:-20},h.endPoint=u,this.svgRenderer.drawLine(e,h)},n.prototype.renderBezierLine=function(t,e,i,r,s,o){var l=this.getBaseAttributes(e,o);l.id=t,l.stroke="black",l.strokeWidth=1,l.dashArray="3,3",l.fill="None",l.class="e-diagram-bezier-control-line",l.x=0,l.y=0;var h=o.scale,g={x:(s.x+o.tx)*h,y:(s.y+o.ty)*h};l.startPoint={x:(r.x+o.tx)*h,y:(r.y+o.ty)*h},l.endPoint=g,this.svgRenderer.drawLine(i,l)},n.prototype.renderCircularHandle=function(t,e,i,r,s,o,a,l,h,c,d,u,p,f){var g=e,v={x:i,y:r};if(0!==g.rotateAngle||0!==g.parentTransform){var y=Hi();qi(y,g.rotateAngle+g.parentTransform,g.offsetX,g.offsetY),v=Je(y,v)}var S=this.getBaseAttributes(g);S.stroke="black",S.strokeWidth=1,void 0!==u?(S.id="segmentEnd_"+u,S.fill="#e2e2e2"):S.fill=h?"#8CC63F":"white",S.cornerRadius=f/2,S.angle=e.rotateAngle,S.id=t,S.visible=o,S.class=p,S.width=f,S.height=f,S.x=(v.x+l.tx)*l.scale,S.y=(v.y+l.ty)*l.scale,S.x=S.x-S.width/2,S.y=S.y-S.height/2,h&&(S.class+=" e-connected"),c&&(S.visible=!1);var b=this.getParentSvg(e,"selector");this.svgRenderer.drawRectangle(s,S,this.diagramId,!0,!0,b,d,!0,a)},n.prototype.renderBezierHandle=function(t,e,i,r,s,o,a,l,h,c,d,u,p){var v,f=document.getElementById(this.diagramId);f&&(v=f.ej2_instances[0]);var y=e,S={x:i,y:r};if(0!==y.rotateAngle||0!==y.parentTransform){var b=Hi();qi(b,y.rotateAngle+y.parentTransform,y.offsetX,y.offsetY),S=Je(b,S)}var D=a.constraints&qe.InheritSegmentThumbSize?v.segmentThumbSize:a.segmentThumbSize,A=n3(a.constraints&qe.InheritSegmentThumbShape?v.segmentThumbShape:a.segmentThumbShape),x=this.getBaseAttributes(y);x.stroke="black",x.strokeWidth=1,void 0!==d?(x.id="segmentEnd_"+d,x.fill="#e2e2e2"):x.fill=h?"#8CC63F":"white",x.angle=e.rotateAngle,x.id=t,x.visible=o,x.class=u,x.width=D,x.height=D,x.data=A,x.x=(S.x+l.tx)*l.scale,x.y=(S.y+l.ty)*l.scale,x.x=x.x-x.width/2,x.y=x.y-x.height/2,h&&(x.class+=" e-connected"),c&&(x.visible=!1);var R=nf(x.data),L=new me(x.width,x.height),O=new Ke;x.data=O.updatePath(x.data,R,L);var N=this.getParentSvg(e,"selector");this.svgRenderer.drawPath(s,x,this.diagramId,!0,N)},n.prototype.renderBorder=function(t,e,i,r,s,o){var l=this.getBaseAttributes(t,i);l.x*=i.scale,l.y*=i.scale,l.width*=i.scale,l.height*=i.scale,l.fill="transparent",l.stroke="#097F7F",l.strokeWidth=1.2,l.gradient=null,l.dashArray="6,3",l.class="e-diagram-selector",o&&(l.class+=" e-diagram-lane"),l.id="borderRect",l.id=this.rendererActions&Qa.DrawSelectorBorder?"borderRect_symbol":"borderRect",r||(l.class+=" e-disabled"),s&&(l.class+=" e-thick-border"),l.cornerRadius=0;var h=this.getParentSvg(t,"selector");this.svgRenderer.drawRectangle(e,l,this.diagramId,void 0,!0,h)},n.prototype.renderUserHandler=function(t,e,i,r,s,o){for(var l,a=t.wrapper,h=0,c=t.userHandles;h0||d.disableNodes&&t.nodes.length>0||"Drag"===s&&o)&&(l=!1);var u=document.getElementById(d.name+"_template_hiddenUserHandle");u&&(d.template=u.childNodes[0].cloneNode(!0));var p=Kx(t,d,i);if(p.x=(p.x+i.tx)*i.scale,p.y=(p.y+i.ty)*i.scale,d.visible&&(d.visible=!!(t.constraints&mr.UserHandle)),l)if(d.pathData){var f=d.pathData?d.pathData:d.content,g=this.getBaseAttributes(a);g.id=d.name+"_userhandle",g.fill=d.backgroundColor,g.stroke=d.borderColor,g.strokeWidth=d.borderWidth,g.centerX=p.x,g.centerY=p.y,g.radius=.5*d.size,g.class="e-diagram-userhandle-circle",g.angle=0,g.visible=d.visible,g.opacity=1,this.svgRenderer.drawCircle(e,g,1,{"aria-label":d.name+"user handle"});var y=[];y=gI(y=Cd(f));var S=nf(f),w=fI(y,(d.size-.45*d.size)/S.width,(d.size-.45*d.size)/S.height,!0,S.x,S.y,0,0);S=nf(w),this.svgRenderer.drawPath(e,C={x:p.x-S.width/2,y:p.y-S.height/2,angle:0,id:"",class:"e-diagram-userhandle-path",fill:d.pathColor,stroke:d.backgroundColor,strokeWidth:.5,dashArray:"",data:w,width:d.size-5,height:d.size-5,pivotX:0,pivotY:0,opacity:1,visible:d.visible},this.diagramId,void 0,void 0,{"aria-label":d.name+"user handle"})}else if(d.content){var D=new Cn(d.name,this.diagramId);D.content=d.content,D.offsetX=p.x,D.offsetY=p.y,D.id=d.name+"_shape",D.horizontalAlignment="Center",D.verticalAlignment="Center",D.visible=d.visible,D.setOffsetWithRespectToBounds(p.x,p.y,"Fraction"),D.relativeMode="Object",D.description=d.name||"User handle",D.measure(new me(d.size,d.size)),D.arrange(D.desiredSize),this.svgRenderer.drawNativeContent(D,e,d.size,d.size,this.adornerSvgLayer)}else if(d.source){var C,A=new SI;(C=this.getBaseAttributes(A,i)).width=d.size,C.height=d.size,C.x=p.x-d.size/2,C.y=p.y-d.size/2,C.sourceWidth=d.size,C.sourceHeight=d.size,C.alignment=A.imageAlign,C.source=d.source,C.scale=A.imageScale,C.visible=d.visible,C.description=d.name||"User handle",C.id=d.name+"_",this.renderer.drawImage(e,C,this.adornerSvgLayer,!1)}else{var x=new Jn(d.name,this.diagramId);x.offsetX=p.x,x.offsetY=p.y,x.id=d.name+"_shape",x.visible=d.visible,x.relativeMode="Object",x.template=d.template,x.measure(new me(d.size,d.size)),x.arrange(x.desiredSize),this.svgRenderer.drawHTMLContent(x,r,void 0,!0,void 0)}}},n.prototype.renderRotateThumb=function(t,e,i,r,s){new Ke;var a,l=new me;l.width=18,l.height=16;var d=!!(r&mr.Rotate);s&&(d=!1);var p=t.offsetX-t.actualSize.width*t.pivot.x+t.pivot.x*t.actualSize.width,f=t.offsetY-t.actualSize.height*t.pivot.y;if(a={x:(p=(p+i.tx)*i.scale)-.5*l.width,y:(f=(f+i.ty)*i.scale)-30-.5*l.height},0!==t.rotateAngle||0!==t.parentTransform){var g=Hi();qi(g,t.rotateAngle+t.parentTransform,(i.tx+t.offsetX)*i.scale,(i.ty+t.offsetY)*i.scale),a=Je(g,a)}this.svgRenderer.drawPath(e,{x:a.x,y:a.y,angle:t.rotateAngle+t.parentTransform,fill:"#231f20",stroke:"black",strokeWidth:.5,dashArray:"",data:"M 16.856144362449648 10.238890446662904 L 18.000144362449646 3.437890446662903L 15.811144362449646 4.254890446662903 C 14.837144362449646 2.5608904466629028 13.329144362449647 1.2598904466629026 11.485144362449645 0.5588904466629026 C 9.375144362449646 - 0.24510955333709716 7.071144362449646 - 0.18010955333709716 5.010144362449646 0.7438904466629028 C 2.942144362449646 1.6678904466629028 1.365144362449646 3.341890446662903 0.558144362449646 5.452890446662903 C - 0.244855637550354 7.567890446662903 - 0.17985563755035394 9.866890446662904 0.7431443624496461 11.930890446662904 C 1.6681443624496461 13.994890446662904 3.343144362449646 15.575890446662903 5.457144362449647 16.380890446662903 C 6.426144362449647 16.7518904466629 7.450144362449647 16.9348904466629 8.470144362449647 16.9348904466629 C 9.815144362449647 16.9348904466629 11.155144362449647 16.6178904466629 12.367144362449647 15.986890446662901 L 11.351144362449647 14.024890446662901 C 9.767144362449647 14.8468904466629 7.906144362449647 14.953890446662902 6.237144362449647 14.3178904466629 C 4.677144362449647 13.7218904466629 3.444144362449647 12.5558904466629 2.758144362449647 11.028890446662901 C 2.078144362449646 9.501890446662903 2.031144362449646 7.802890446662903 2.622144362449646 6.243890446662903 C 3.216144362449646 4.6798904466629025 4.387144362449646 3.442890446662903 5.914144362449646 2.760890446662903 C 7.437144362449646 2.078890446662903 9.137144362449646 2.0298904466629026 10.700144362449645 2.6258904466629027 C 11.946144362449646 3.100890446662903 12.971144362449646 3.9538904466629026 13.686144362449646 5.049890446662903 L 11.540144362449645 5.850890446662903 L 16.856144362449648 10.238890446662904 Z",width:20,height:20,pivotX:0,pivotY:0,opacity:1,visible:d,id:"rotateThumb",class:"e-diagram-rotate-handle"},this.diagramId,!0,void 0,{"aria-label":"Thumb to rotate the selected object"})},n.prototype.renderPathElement=function(t,e,i,r,s,o,a){var l=this.getBaseAttributes(t,i,o);if(l.data=t.absolutePath,l.data=t.absolutePath,t.isPathPort&&a){l.x=a[t.id]?a[t.id].cx:l.x,l.y=a[t.id]?a[t.id].cy:l.y,t.bounds.x=l.x,t.bounds.y=l.y;var h=document.getElementById(this.diagramId);h&&"PortDrag"!==h.ej2_instances[0].eventHandler.currentAction&&(t.offsetX=l.x+t.width/2,t.offsetY=l.y+t.height/2)}var u=t.description?t.description:t.id;if(this.isSvgMode||(l.x=t.flipOffset.x?t.flipOffset.x:l.x,l.y=t.flipOffset.y?t.flipOffset.y:l.y),t.isExport){var p=t.absoluteBounds,f=Cd(l.data),g=this.findAndStoreArcValues(f);l.arc=g,l.data=OF(t,p,0,l)}this.renderer.drawPath(e,l,this.diagramId,void 0,r,u)},n.prototype.findAndStoreArcValues=function(t){var e=[];return t.forEach(function(i){"A"===i.command&&e.push({r1:i.r1/2,r2:i.r2/2})}),e},n.prototype.renderSvgGridlines=function(t,e,i,r,s,o){var a=document.createElementNS("http://www.w3.org/2000/svg","pattern"),l=document.createElementNS("http://www.w3.org/2000/svg","defs");l.setAttribute("id",this.diagramId+"_grid_pattern_defn"),(t.constraints&Kt.ShowHorizontalLines||t.constraints&Kt.ShowVerticalLines)&&a.setAttribute("id",this.diagramId+"_pattern");var h=0,c=0,d=0,u=0,p=1,f=!1,g="Lines"===t.gridType,v=g?t.verticalGridlines.lineIntervals:t.verticalGridlines.dotIntervals,y=g?t.horizontalGridlines.lineIntervals:t.horizontalGridlines.dotIntervals;if(r.showRulers&&r.dynamicGrid&&s&&o)d=o.updateSegmentWidth(i.scale),u=s.updateSegmentWidth(i.scale),t.horizontalGridlines.scaledIntervals=[d/s.interval],t.verticalGridlines.scaledIntervals=[u/o.interval],f=!0;else{for(var S=0;S=2)for(;e>=2;)e/=2;else if(e<=.5)for(;e<=.5;)e*=2;var i;if(t.horizontalGridlines.scaledIntervals=t.horizontalGridlines.snapIntervals,t.verticalGridlines.scaledIntervals=t.verticalGridlines.snapIntervals,1!==e){var r=t.horizontalGridlines;for(r.scaledIntervals=[],i=0;ithis.groupElement.actualSize.height&&("Clip"===t.style.textOverflow||"Ellipsis"===t.style.textOverflow)&&(a.y=a.y+(a.height-this.groupElement.actualSize.height)/2),this.renderer.drawRectangle(e,a,this.diagramId,void 0,void 0,r),this.renderer.drawText(e,a,r,l,this.diagramId,t.isExport&&Math.min(t.exportScaleValue.x||t.exportScaleValue.y),this.groupElement),this.isSvgMode&&(t.doWrap=!1)},n.prototype.renderNativeElement=function(t,e,i,r,s){var o,a,l=this.getParentSvg(t,void 0,e)||r,h=this.getParentElement(t,e,l).g||e,c=this.getBaseAttributes(t,i);switch(c.fill="transparent",c.cornerRadius=t.cornerRadius,c.stroke="transparent",this.renderer.drawRectangle(e,c,this.diagramId,void 0,void 0,r),t.scale){case"None":o=t.contentSize.width,a=t.contentSize.height;break;case"Stretch":o=t.actualSize.width,a=t.actualSize.height;break;case"Meet":o=a=t.actualSize.width<=t.actualSize.height?t.actualSize.width:t.actualSize.height;break;case"Slice":o=a=t.actualSize.width>=t.actualSize.height?t.actualSize.width:t.actualSize.height}this.svgRenderer&&this.svgRenderer.drawNativeContent(t,h,a,o,l)},n.prototype.renderHTMLElement=function(t,e,i,r,s,o,a){var l=this.getBaseAttributes(t,r);l.fill="transparent",l.cornerRadius=t.cornerRadius,l.stroke="transparent",this.renderer.drawRectangle(e,l,this.diagramId,void 0,void 0,s),this.svgRenderer&&this.svgRenderer.drawHTMLContent(t,i.children[0],r,function lse(n){var t=n.parentElement;do{if(dm(t,"e-diagram"))return!0;t=t.parentElement}while(t);return!1}(i),a)},n.prototype.renderImageElement=function(t,e,i,r,s){var o=this.getBaseAttributes(t,i);o.cornerRadius=0,this.renderer.drawRectangle(e,o,this.diagramId,void 0,void 0,r);var a,l,h,c,g,d=t.contentSize.width,u=t.contentSize.height,p=o.width/d,f=o.height/u;if("Stretch"===t.stretch)a=d*(g=Math.min(p,f)),l=u*g;else switch(t.stretch){case"Meet":a=d*(g=Math.min(p,f)),l=u*g,o.x+=Math.abs(o.width-a)/2,o.y+=Math.abs(o.height-l)/2;break;case"Slice":g=Math.max(p,f),h=o.width/(a=d*g)*d,c=o.height/(l=u*g)*u;break;case"None":a=d,l=u}o.width=a,o.height=l,o.sourceWidth=h,o.sourceHeight=c,o.source=t.source,o.alignment=t.imageAlign,o.scale=t.imageScale,o.description=t.description?t.description:t.id,this.renderer.drawImage(e,o,r,s)},n.prototype.renderContainer=function(t,e,i,r,s,o,a,l,h,c,d){var g,u={svg:s,g:e},p=document.getElementById(this.diagramId);if(p&&(g=p.ej2_instances[0]),this.diagramId&&(s=this.getParentSvg(t)||s,this.isSvgMode)){var v=this.getParentElement(t,e,s,l).g||e;s=this.getParentSvg(this.hasNativeParent(t.children))||s;var y=this.getParentElement(this.hasNativeParent(t.children),v,s,l);u.svg=y.svg||s,u.g=y.g||v,o&&s&&(s.getElementById(u.g.id)||e.appendChild(u.g)),e=u.g}if(this.renderRect(t,e,r,s),this.groupElement=t,t.hasChildren()){for(var b,S=void 0,M=0,w=t.children;M0&&(D=g.selectedItems.nodes[0]);var L,A=void 0,x=void 0,R=!1;if(g&&g.selectedItems&&(L=g.getObject(t.id)),"None"!==t.flip&&(D=L),"None"===t.flip&&(D=L),D&&D.flipMode&&(R=!0),!(t.elementActions&Xr.ElementIsGroup)&&g instanceof zl&&g.nameTable[t.id]&&"connectors"!==g.nameTable[t.id].propName&&R&&D){if(A=t.children&&t.children[0]instanceof Cn?document.getElementById(D.id+"_content_inner_native_element"):document.getElementById(D.id+"_content_groupElement"),!(t.children[0]instanceof Cn)&&"Text"!==D.shape.type&&"None"!==D.flipMode&&"Label"!==D.flipMode&&"All"!==D.flipMode&&"PortAndLabel"!==D.flipMode&&"LabelText"!==D.flipMode&&"PortAndLabelText"!==D.flipMode&&"LabelAndLabelText"!==D.flipMode||t.children[0]instanceof Cn&&"Port"===D.flipMode)return void this.renderFlipElement(t,A,D.flip);if((t.children[0]instanceof Cn&&("All"===D.flipMode||"Label"===D.flipMode)||"Label"===D.flipMode||"PortAndLabel"===D.flipMode||"LabelText"===D.flipMode||"PortAndLabelText"===D.flipMode||"LabelAndLabelText"===D.flipMode||"Image"===D.shape.type&&"Label"===D.flipMode)&&this.renderFlipElement(t,A,t.flip),"None"!==t.flip&&"None"===D.flipMode)this.renderFlipElement(t,A,t.flip);else if("None"!==t.flip&&("Label"===D.flipMode||"PortAndLabel"===D.flipMode||"LabelText"===D.flipMode||"PortAndLabelText"===D.flipMode||"LabelAndLabelText"===D.flipMode)||t.children[0]instanceof Cn&&"None"!==t.flip&&D&&("None"===D.flipMode||"All"===D.flipMode)){for(var O=0;O0){var i=t[0];if(i instanceof Cn)return i;i.children&&i.children.length&&this.hasNativeParent(i.children,e++||0)}},n.prototype.renderRect=function(t,e,i,r,s){var o=this.getBaseAttributes(t,i,s);o.cornerRadius=t.cornerRadius||0,t.isExport&&(o.cornerRadius*=t.exportScaleValue.x),this.renderer.drawRectangle(e,o,this.diagramId,t.isExport,void 0,r,t.description?t.description:t.id)},n.prototype.drawRect=function(t,e){e.cornerRadius=0,this.svgRenderer.drawRectangle(t,e,this.diagramId)},n.prototype.getBaseAttributes=function(t,e,i){var r={width:t.actualSize.width,height:t.actualSize.height,x:t.offsetX-t.actualSize.width*t.pivot.x,y:t.offsetY-t.actualSize.height*t.pivot.y,fill:t.style.fill,stroke:t.style.strokeColor,angle:t.rotateAngle+t.parentTransform,pivotX:t.pivot.x,pivotY:t.pivot.y,strokeWidth:t.style.strokeWidth,dashArray:t.style.strokeDashArray||"",opacity:t.style.opacity,shadow:t.shadow,gradient:t.style.gradient,visible:t.visible,id:t.id,description:t.description,canApplyStyle:t.canApplyStyle,shapeType:t.shapeType};return"Page"===t.rotationReference&&(r.angle=t.rotateAngle),i&&(r.x=r.x-.5,r.y=r.y-.5),t.isExport&&(r.width*=t.exportScaleValue.x,r.height*=t.exportScaleValue.y,r.x*=t.exportScaleValue.x,r.y*=t.exportScaleValue.y,r.strokeWidth*=t.exportScaleValue.x),t.flip&&(r.flip=t.flip),e&&(r.x+=e.tx,r.y+=e.ty),r},n.renderSvgBackGroundImage=function(t,e,i,r,s,o){if(t.source){var l=mT(e.id).getElementById(e.id+"_image");if(!l){var h=function moe(n){return xt(n).getElementsByClassName("e-background-image-layer")[0]}(e.id);(l=document.createElementNS("http://www.w3.org/2000/svg","image")).setAttribute("id",e.id+"_image"),h.appendChild(l)}var c=new Image;c.src=t.source,l.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",c.src.toString());var d="None"!==t.scale?t.scale:"",u=t.align,p=u.charAt(0).toLowerCase()+u.slice(1);d&&(p+=" "+d.charAt(0).toLowerCase()+d.slice(1)),ai(l,{id:e.id+"_image",x:i,y:r,width:s,height:o,preserveAspectRatio:p})}},n.prototype.transformLayers=function(t,e){var i=t.tx*t.scale,r=t.ty*t.scale,s="domTable";if(i!==this.transform.x||r!==this.transform.y||0===i||0===r){e&&(window[""+s][this.diagramId+"_diagramLayer"]||(window[""+s][this.diagramId+"_diagramLayer"]=this.diagramSvgLayer.getElementById(this.diagramId+"_diagramLayer")),window[""+s][this.diagramId+"_diagramLayer"].setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+"),scale("+t.scale+")"));var a=function yoe(n){var t="domTable",e=null;return window[t][n+"_gridline"]?e=window[t][n+"_gridline"]:(e=Bd(n).getElementById(n+"_gridline"),window[t][n+"_gridline"]=e),e}(this.diagramId);return a.setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+")"),window[""+s][this.diagramId+"_diagramPorts"]||(window[""+s][this.diagramId+"_diagramPorts"]=this.iconSvgLayer.getElementById(this.diagramId+"_diagramPorts")),window[""+s][this.diagramId+"_diagramPorts"].setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+"),scale("+t.scale+")"),window[""+s][this.diagramId+"_diagramExpander"]||(window[""+s][this.diagramId+"_diagramExpander"]=this.iconSvgLayer.getElementById(this.diagramId+"_diagramExpander")),window[""+s][this.diagramId+"_diagramExpander"].setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+"),scale("+t.scale+")"),window[""+s][this.diagramId+"_nativeLayer"]||(window[""+s][this.diagramId+"_nativeLayer"]=this.nativeSvgLayer.getElementById(this.diagramId+"_nativeLayer")),window[""+s][this.diagramId+"_nativeLayer"].setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+"),scale("+t.scale+")"),Io(this.diagramId).children[0].style.transform="translate("+t.tx*t.scale+"px,"+t.ty*t.scale+"px)scale("+t.scale+")",this.transform={x:t.tx*t.scale,y:t.ty*t.scale},!0}return!1},n.prototype.updateNode=function(t,e,i,r,s,o,a){this.renderElement(t,e,i,r,this.getParentSvg(t),void 0,void 0,s,null,o,a)},n}(),tse=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),$I=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},oF=function(n){function t(e,i){var r=n.call(this,e,i)||this;return r.mode="Canvas",r.id="overview",r.actionName="",r.startPoint=null,r.currentPoint=null,r.prevPoint=null,r.scale=null,r.inAction=!1,r.viewPortRatio=1,r.horizontalOffset=0,r.verticalOffset=0,r.model={},r.event=!0,r.overviewid=88123,r.model={width:r.width,height:r.height},r}return tse(t,n),t.prototype.onPropertyChanged=function(e,i){for(var r=0,s=Object.keys(e);r0||e.toString().indexOf("%")>0?e.toString():e.toString()+"px"},t.prototype.renderCanvas=function(e){var i=document.getElementById(this.element.id+"_canvas");i||(i=Tt("div",{}),this.element.appendChild(i)),Ho(i,{id:this.element.id+"_canvas",class:"drawing",style:"position:relative; height:"+this.getSizeValue(this.model.height)+"; width:"+this.getSizeValue(this.model.width)+";style:-ms-touch-action: none;touch-action: none;"}),this.element.setAttribute("tabindex",String(-1)),this.element.style.overflow="hidden",this.element.style.height=String(this.model.height),this.element.style.width=String(this.model.width),this.canvas=i},t.prototype.setParent=function(e){var i=document.getElementById(e);if(this.parent){var s=this.parent;this.parent=null,s.setOverview(null,this.element.id),this.removeDocument(this)}this.parent=this.getDiagram(i,"ej2_instances"),this.parent&&this.parent.setOverview(this)},t.prototype.getDiagram=function(e,i){for(var r,s=e[""+i].length,o=0;o0?p:Math.floor(window.innerWidth)}if(0===h){var f=Math.floor(window.innerHeight-u-Math.floor(c.top));h=f>0?f:Math.floor(window.innerHeight)}l>0&&(s.setAttribute("width",String(l)),this.model.height=h),h>0&&(s.setAttribute("height",String(h)),this.model.width=l),e.diagramLayerDiv||(e.diagramLayerDiv=Tt("div",{}),e.diagramLayer=bo.createCanvas(this.element.id+"_diagramLayer",this.model.width,this.model.height),e.diagramLayer.setAttribute("style","position:absolute; left:0px; top:0px "),e.diagramLayerDiv.appendChild(e.diagramLayer),e.canvas.appendChild(e.diagramLayerDiv)),Ho(e.diagramLayerDiv,{id:this.element.id+"_diagramLayer_div",style:"width:"+this.model.width+"px; height:"+this.model.height+"px;position:absolute;top:0px;left:0px"}),this.renderHtmlLayer(e.canvas),this.renderNativeLayer(e.canvas,e),this.addOverviewRectPanel(e)},t.prototype.removeDocument=function(e){var i=document.getElementById(this.canvas.id+"_svg");this.canvas.removeChild(i);var r=document.getElementById(this.element.id+"_htmlLayer");this.canvas.removeChild(r);var s=document.getElementById(this.element.id+"_diagramLayer_div");this.canvas.removeChild(s),e.diagramLayerDiv=null,e.diagramLayer=null,window.domTable[this.id+"html_layer"]=null},t.prototype.renderHtmlLayer=function(e){var i=Tt("div",{id:this.element.id+"_htmlLayer",class:"e-html-layer",style:"pointer-events:none;position:absolute;top:0px;left:0px;"}),s=Tt("div",{id:this.element.id+"_htmlLayer_div",style:"position:absolute;top:0px;left:0px;"});return i.appendChild(s),e.appendChild(i),i},t.prototype.renderNativeLayer=function(e,i){if(!document.getElementById(this.element.id+"_nativeLayer_svg")){var r=this.parent.createSvg(this.element.id+"_nativeLayer_svg",this.model.width,this.model.height),s=Bi("g",{id:this.element.id+"_nativeLayer"});r.appendChild(s),i.diagramLayerDiv.appendChild(r),ai(r,{class:"e-native-layer"})}},t.prototype.addOverviewRectPanel=function(e){var i=document.getElementById(this.canvas.id+"_overviewsvg");i&&i.parentNode.removeChild(i),i=Bi("svg",{id:this.canvas.id+"_overviewsvg",class:"overviewsvg",version:"1.1",style:"position:absolute;left:0px;top:0px; aria-label:Specifies overview",width:this.model.width,height:this.model.height}),e.canvas.appendChild(i);var s=Bi("g",{id:this.element.id+"_overviewlayer",style:"pointer-events:none"});i.appendChild(s);var o=Bi("rect",{fill:"transparent",width:"100%",height:"100%",class:"overviewbackrect",id:this.canvas.id+"overviewbackrect"});o.setAttribute("style"," pointer-events: none; "),s.appendChild(o);var a=Bi("g",{id:this.canvas.id+"overviewhandle",style:"pointer-events:all"});s.appendChild(a);var l=Bi("rect",{id:this.canvas.id+"overviewrect",fill:"transparent"});a.appendChild(l),this.renderOverviewCorner("left",a),this.renderOverviewCorner("right",a),this.renderOverviewCorner("top",a),this.renderOverviewCorner("bottom",a),this.renderOverviewCorner("topleft",a),this.renderOverviewCorner("topright",a),this.renderOverviewCorner("bottomleft",a),this.renderOverviewCorner("bottomright",a)},t.prototype.renderOverviewCorner=function(e,i){var s,o=Bi(s="top"===e||"bottom"===e||"right"===e||"left"===e?"rect":"circle",{id:this.canvas.id+"visible"+e,class:"overview-resizer"});i.appendChild(o);var a=Bi(s,{id:this.canvas.id+e,class:"overviewresizer",fill:"transparent"});i.appendChild(a)},t.prototype.updateOverviewRectangle=function(){var e=this.currentPoint.x-this.prevPoint.x,i=this.currentPoint.y-this.prevPoint.y,r=new me;r.width=0,r.height=0;var s=0,o=0;switch(this.resizeDirection){case"left":r.width-=e,r.height-=e/this.viewPortRatio,s=e,o=e/this.viewPortRatio,o/=2;break;case"right":r.width+=e,r.height+=e/this.viewPortRatio,o=e/this.viewPortRatio,o/=-2;break;case"top":r.height-=i,r.width-=i*this.viewPortRatio,o=i,s=i*this.viewPortRatio,s/=2;break;case"bottom":r.height+=i,r.width+=i*this.viewPortRatio,s=i*this.viewPortRatio,s/=-2;break;case"topleft":Math.abs(i)>Math.abs(e)?e=i*this.viewPortRatio:i=e/this.viewPortRatio,r.width-=e,r.height-=i,s=e,o=i;break;case"topright":Math.abs(i)>Math.abs(e)?e=-i*this.viewPortRatio:i=-e/this.viewPortRatio,o=i,r.width+=e,r.height-=i;break;case"bottomleft":Math.abs(i)>Math.abs(e)?e=-i*this.viewPortRatio:i=-e/this.viewPortRatio,s=e,r.width-=e,r.height+=i;break;case"bottomright":Math.abs(i)>Math.abs(e)?e=i*this.viewPortRatio:i=e/this.viewPortRatio,r.width+=e,r.height+=i}this.updateHelper(s,o,r,void 0,void 0)},t.prototype.updateHelper=function(e,i,r,s,o){var a,l,h,u,p,d=this.element.getElementsByTagName("svg")[2].getElementById("helper");r?(a=(h=d.getBBox()).x+e,l=h.y+i,s=h.width+r.width,o=h.height+r.height):(u=this.currentPoint.x>this.startPoint.x?this.currentPoint.x-this.prevPoint.x:this.prevPoint.x-this.currentPoint.x,p=this.currentPoint.y>this.startPoint.y?this.currentPoint.y-this.prevPoint.y:this.prevPoint.y-this.currentPoint.y,Math.abs(p)>Math.abs(u)?u=this.viewPortRatio*p:p=u/this.viewPortRatio,h=d.getBBox(),a=this.startPoint.x>this.currentPoint.x?h.x-u:h.x,l=this.startPoint.y>this.currentPoint.y?h.y-p:h.y,s=h.width+u,o=h.height+p),ai(this.helper,{id:this.helper.id,x:a,y:l,width:Math.max(0,s),height:Math.max(0,o)})},t.prototype.updateOverviewrect=function(e,i,r,s){Ho(document.getElementById(this.canvas.id+"overviewrect"),{x:e,y:i,width:Math.max(1,r),height:Math.max(1,s)}),this.updateOverviewCorner("top",e+8,i+1,Math.max(0,r-16),2),this.updateOverviewCorner("bottom",e+8,i+s+3,Math.max(0,r-16),2),this.updateOverviewCorner("left",e-2,i+11,2,Math.max(0,s-16)),this.updateOverviewCorner("right",e+r,i+11,2,Math.max(0,s-16)),this.updateOverviewCorner("topleft",e,i+3,5,5),this.updateOverviewCorner("topright",e+r,i+3,5,5),this.updateOverviewCorner("bottomleft",e,i+s+3,5,5),this.updateOverviewCorner("bottomright",e+r,i+s+3,5,5)},t.prototype.updateOverviewCorner=function(e,i,r,s,o){var a,l;"top"===e||"bottom"===e||"right"===e||"left"===e?(a={x:i,y:r,width:s,height:o,fill:"#ED1C24"},l={x:i-2,y:r-2,width:2===s?4:s,height:2===o?4:o}):(a={cx:i,cy:r,r:4,fill:"#ED1C24"},l={cx:i,cy:r,r:6,fill:"transparent"}),Ho(document.getElementById(this.canvas.id+"visible"+e),a),Ho(document.getElementById(this.canvas.id+e),l)},t.prototype.translateOverviewRectangle=function(){Number(this.model.width),Number(this.model.height);var r=this.currentPoint.x-this.prevPoint.x,s=this.currentPoint.y-this.prevPoint.y,l=this.element.getElementsByClassName("overviewsvg")[0].getElementById(this.canvas.id+"overviewrect").getBBox(),h=l.x+r,c=l.y+s,d=l.width,u=l.height;this.updateOverviewrect(h,c,d,u),this.updateParentView(this.parent.scroller.currentZoom,h,c,d,u,null)},t.prototype.renderOverviewRect=function(e,i,r,s){var o=Number(this.model.width),a=Number(this.model.height),c=Math.max(this.parent.scroller.viewPortWidth/(r/o*this.contentWidth),this.parent.scroller.viewPortHeight/(s/a*this.contentHeight));if(c>=.25&&c<=30){this.updateParentView(c,e,i,r,s,{x:0,y:0});var u=this.scrollOverviewRect(this.parent.scroller.horizontalOffset,this.parent.scroller.verticalOffset,this.parent.scroller.currentZoom,!0);if(this.helper){var f=this.element.getElementsByTagName("rect")[10].getBBox();u.x=f.x,u.y=f.y}"pan"===this.actionName?this.updateOverviewrect(-u.x,-u.y,u.width,u.height):this.updateOverviewrect(u.x,u.y,u.width,u.height)}},t.prototype.scrollOverviewRect=function(e,i,r,s){if(!this.actionName||s){var o=Number(this.model.width),a=Number(this.model.height),l=Math.min(this.contentWidth/o,this.contentHeight/a),h=new Ne,c=h.x=e/r/l,d=h.y=i/r/l,u=0;this.parent.rulerSettings.showRulers&&(u=25);var p=document.getElementById(this.parent.element.id+"content"),f=0,g=0;p&&(f=p.offsetWidth-p.clientWidth,g=p.offsetHeight-p.clientHeight);var v=h.width=(this.parent.scroller.viewPortWidth-u-f)/r/l,y=h.height=(this.parent.scroller.viewPortHeight-u-g)/r/l;if(s){var S=new Ne;return S.x=c,S.y=d,S.width=v,S.height=y,S}this.updateOverviewrect(-c,-d,v,y)}return null},t.prototype.updateParentView=function(e,i,r,s,o,a){var f,g,l=Number(this.model.width),h=Number(this.model.height),u=i*(this.contentWidth/l)*e,p=r*(this.contentHeight/h)*e;this.parent.scroller.getPageBounds(),(1!==e||"pan"===this.actionName)&&(f=-u-this.parent.scroller.horizontalOffset,g=-p-this.parent.scroller.verticalOffset),this.parent.setBlazorDiagramProps(!0),this.parent.realActions|=$i.OverViewAction,"scale"===this.actionName||"draw"===this.actionName?this.parent.scroller.zoom(e/this.parent.scroller.currentZoom,f,g,a):ce()?this.parent.scroller.zoom(1,f,g,a):this.parent.pan(f,g,a,!0)},t.prototype.updateHtmlLayer=function(e){var i=Io(e.element.id),r=this.parent.scroller.getPageBounds(!0),o=r.height,a=Math.max(r.width,this.parent.scroller.viewPortWidth),l=Math.max(o,this.parent.scroller.viewPortHeight/this.parent.scroller.currentZoom),h=Math.min(Number(this.model.width)/a,Number(this.model.height)/l);i.style.transform="scale("+h+") translate("+this.parent.scroller.transform.tx+"px,"+this.parent.scroller.transform.ty+"px)"},t.prototype.updateView=function(e){var i=this.parent.scroller.getPageBounds(),r=i.width,s=i.height,o=Number(this.model.width),a=Number(this.model.height),l=Math.max(r,this.parent.scroller.viewPortWidth),h=Math.max(s,this.parent.scroller.viewPortHeight);this.contentWidth=l=Math.max(l,o/a*h),this.contentHeight=h=Math.max(h,a/o*l);var c=Math.min(o/l,a/h),d=document.getElementById(this.element.id+"_htmlLayer");d.style.webkitTransform="scale("+c+") translate("+-i.x+"px,"+-i.y+"px)",d.style.transform="scale("+c+") translate("+-i.x+"px,"+-i.y+"px)",document.getElementById(this.element.id+"_overviewlayer").setAttribute("transform","translate("+-i.x*c+","+-i.y*c+")"),this.horizontalOffset=i.x*c,this.verticalOffset=i.y*c;var p=document.getElementById(this.element.id+"_diagramLayer"),f=zF(this.element.id),g=p.getContext("2d"),v=Number(this.model.width)/this.contentWidth,y=Number(this.model.height)/this.contentHeight;v=Math.min(v,y);var S=this.parent.scroller.transform;f.setAttribute("transform","translate("+S.tx*v+","+S.ty*y+"),scale("+v+")"),g.setTransform(v,0,0,v,0,0),g.fillStyle="red",this.scrollOverviewRect(this.parent.scroller.horizontalOffset,this.parent.scroller.verticalOffset,this.parent.scroller.currentZoom)},t.prototype.scrolled=function(e){if(this.event){var i=this.scrollOverviewRect(this.parent.scroller.horizontalOffset,this.parent.scroller.verticalOffset,this.parent.scroller.currentZoom,!0);this.updateOverviewrect(-i.x,-i.y,i.width,i.height),this.updateView(this)}},t.prototype.updateCursor=function(e){if(dm(e.target,"overviewresizer"))switch(e.target.id){case this.canvas.id+"left":this.canvas.style.cursor="w-resize";break;case this.canvas.id+"right":this.canvas.style.cursor="e-resize";break;case this.canvas.id+"top":this.canvas.style.cursor="n-resize";break;case this.canvas.id+"bottom":this.canvas.style.cursor="s-resize";break;case this.canvas.id+"topleft":this.canvas.style.cursor="nw-resize";break;case this.canvas.id+"topright":this.canvas.style.cursor="ne-resize";break;case this.canvas.id+"bottomleft":this.canvas.style.cursor="sw-resize";break;case this.canvas.id+"bottomright":this.canvas.style.cursor="se-resize"}else this.canvas.style.cursor="default"},t.prototype.mouseMove=function(e){if(this.event=!1,this.updateCursor(e),this.currentPoint=this.mousePosition(e),this.actionName)switch(this.actionName){case"draw":!this.inAction&&(this.startPoint.x!==this.currentPoint.x||this.startPoint.y!==this.currentPoint.y)&&(this.initHelper(),this.inAction=!0),this.inAction&&this.updateHelper();break;case"scale":this.inAction||(this.initHelper(),this.inAction=!0),this.updateOverviewRectangle();break;case"pan":(this.startPoint.x!==this.currentPoint.x||this.startPoint.y===this.currentPoint.y||this.inAction)&&(this.inAction=!0,this.translateOverviewRectangle())}this.prevPoint=this.currentPoint},t.prototype.documentMouseUp=function(e){this.inAction=!1,this.actionName="",this.helper&&(this.helper.parentNode.removeChild(this.helper),this.helper=null),this.event=!0,document.getElementById(this.canvas.id+"overviewhandle").style.pointerEvents="all"},t.prototype.windowResize=function(e){var i=this;return this.resizeTo&&clearTimeout(this.resizeTo),this.resizeTo=setTimeout(function(){var s=document.getElementById(i.element.id).getBoundingClientRect();i.model.width=s.width>0?s.width:i.model.width,i.model.height=s.height>0?s.height:i.model.height,i.renderCanvas(),i.setParent(i.sourceID)},10),!1},t.prototype.mouseDown=function(e){if(e.target.id===this.canvas.id+"_overviewsvg"&&(this.actionName="draw"),e.target.id===this.canvas.id+"overviewrect"&&(this.actionName="pan"),dm(e.target,"overviewresizer"))switch(this.actionName="scale",e.target.id){case this.canvas.id+"left":this.resizeDirection="left";break;case this.canvas.id+"right":this.resizeDirection="right";break;case this.canvas.id+"top":this.resizeDirection="top";break;case this.canvas.id+"bottom":this.resizeDirection="bottom";break;case this.canvas.id+"topleft":this.resizeDirection="topleft";break;case this.canvas.id+"topright":this.resizeDirection="topright";break;case this.canvas.id+"bottomleft":this.resizeDirection="bottomleft";break;case this.canvas.id+"bottomright":this.resizeDirection="bottomright"}this.startPoint=this.prevPoint=this.mousePosition(e),this.viewPortRatio=this.parent.scroller.viewPortWidth/this.parent.scroller.viewPortHeight,document.getElementById(this.canvas.id+"overviewhandle").style.pointerEvents="none"},t.prototype.mouseUp=function(e){if(this.currentPoint=this.mousePosition(e),this.actionName)if(this.startPoint.x!==this.currentPoint.x||this.startPoint.y!==this.currentPoint.y){if("pan"!==this.actionName&&this.helper){var i=this.element.getElementsByTagName("rect")[10].getBBox();this.resizeDirection=this.resizeDirection||"",this.renderOverviewRect(i.x,i.y,o=i.width,a=i.height)}}else if(e.target.id===this.canvas.id+"_overviewsvg"||"helper"===e.target.id){var o=(i=this.element.getElementsByTagName("svg")[2].getElementById(this.canvas.id+"overviewrect").getBBox()).width,a=i.height;this.inAction=!0,this.actionName="pan",this.renderOverviewRect(this.currentPoint.x-o/2,this.currentPoint.y-a/2,o,a),this.inAction=!1}this.helper&&(this.helper.parentNode.removeChild(this.helper),this.helper=null),this.actionName="",this.startPoint=null,this.currentPoint=null,this.prevPoint=null,this.helper=null,this.viewPortRatio=1,this.resizeDirection="",this.inAction=!1,this.event=!0,document.getElementById(this.canvas.id+"overviewhandle").style.pointerEvents="all"},t.prototype.initHelper=function(){var e=this.element.getElementsByTagName("svg")[2],i=this.startPoint.x,r=this.startPoint.y,s=1,o=1;if("scale"===this.actionName){var l=e.getElementById(this.canvas.id+"overviewrect").getBBox();i=l.x,r=l.y,s=l.width,o=l.height}var h=Bi("rect",{id:"helper",x:i,y:r,width:s,height:o,fill:"transparent",stroke:"gray","stroke-dasharray":"2 2","shape-rendering":"crispEdges"});e.getElementById(this.element.id+"_overviewlayer").appendChild(h),this.helper=h},t.prototype.mousePosition=function(e){var i,r,s;-1!==e.type.indexOf("touch")?(r=(i=e).changedTouches[0].clientX-this.element.offsetLeft,s=i.changedTouches[0].clientY-this.element.offsetTop):(r=e.clientX,s=e.clientY);var l=this.element.getBoundingClientRect();return{x:(r-=l.left)+this.horizontalOffset,y:(s-=l.top)+this.verticalOffset}},t.prototype.destroy=function(){if(this.unWireEvents(),this.notify("destroy",{}),n.prototype.destroy.call(this),document.getElementById(this.element.id)){this.element.classList.remove("e-overview");var e=document.getElementById(this.element.id+"_canvas");e&&this.element.removeChild(e)}this.parent.views.splice(this.parent.views.indexOf(this.element.id),1),this.diagramLayerDiv=null,this.canvas=null,this.parent=null},t.prototype.getModuleName=function(){return"Overview"},$I([I("100%")],t.prototype,"width",void 0),$I([I("100%")],t.prototype,"height",void 0),$I([I("")],t.prototype,"sourceID",void 0),$I([H()],t.prototype,"created",void 0),t}(yi);function rse(n,t){for(var e=0;ez.findLength(e,n)?e:t;var o=z.findAngle(t,e),a=z.findAngle(i,n),l=z.findLength(i,n),h=a+2*(o-a);return{x:i.x+l*Math.cos(h*Math.PI/180),y:i.y+l*Math.sin(h*Math.PI/180)}}function $p(n,t,e){if(n&&n.children&&n.children.length>0)for(var r=void 0,s=0;s0&&"annotations"!==r&&"ports"!==r)if(n[""+l].length>0)for(var h=0;h<=n[""+l].length;h++)Ro(n[""+l],t?t[""+l]:void 0,e[""+l],"annotations"===l||"ports"===l?n:void 0,l);else Ro(n[""+l],t?t[""+l]:void 0,e[""+l],"annotations"===l||"ports"===l?n:void 0,l);else if(s instanceof Object&&t&&"annotations"!==r&&"ports"!==r)Ro(n[""+l],t[""+l],e[""+l]);else if("annotations"!==r&&"ports"!==r&&t&&!t[""+l]||!t&&n&&(n[""+l]||void 0!==n[""+l]))n[""+l]=e[""+l];else{var c=void 0;("annotations"===r||"ports"===r)&&("annotations"===r?(n[""+l]&&Ro(n[""+l],t[""+l],e[""+l]),n[""+l]||(fs(i)===de?(c=new Nr(i,"annotations",e[""+l]),i.annotations.push(c)):(c=new Zn(i,"annotations",e[""+l]),i.annotations.push(c)))):n[""+l]?Ro(n[""+l],t[""+l],e[""+l]):(c=new Es(i,"ports",e[""+l]),i.ports.push(c)))}}}function cse(n,t){for(var e="Bezier"===n.type?function ase(n){var t=[];if("Bezier"===n.type)for(var e=0,i=0;i0||n.ports.length>0){var p=n.wrapper.children;for(i=3;i0)return{enabled:!1,intersectPt:e};var l=o/s,h=a/s;return l>=0&&l<=1&&h>=0&&h<=1?(e.x=i.x1+l*(i.x2-i.x1),e.y=i.y1+l*(i.y2-i.y1),{enabled:!0,intersectPt:e}):{enabled:!1,intersectPt:e}}function JI(n,t,e,i){var a=em(cF(n.x,n.y,t.x,t.y),cF(e.x,e.y,i.x,i.y));return a.enabled?a.intersectPt:{x:0,y:0}}function cF(n,t,e,i){return{x1:Number(n)||0,y1:Number(t)||0,x2:Number(e)||0,y2:Number(i)||0}}function dF(n,t,e){var i=[],s={x:t.topRight.x+(e=e||0),y:t.topRight.y},o={x:t.bottomRight.x,y:t.bottomRight.y-e},a={x:t.bottomLeft.x,y:t.bottomLeft.y+e};return i.push({x:t.topLeft.x-e,y:t.topLeft.y}),i.push(s),i.push(o),i.push(a),i}function zc(n,t,e,i,r,s){var o={},a=e.scroller.transform.scale,h=e.scroller.verticalOffset;return o.x=(i?n.x:t.x)*a+e.scroller.horizontalOffset-r,o.y=(i?n.y:t.y)*a+h-s,o}function uF(n,t){var e=new Ke;return e.data=n.pathData,e.height=n.height>10?n.height-(n.padding.bottom+n.padding.top):n.height,e.width=n.width>10?n.width-(n.padding.left+n.padding.right):n.width,e.visible=n.visibility,e.id=t.id+"_shape",e.inversedAlignment=!1,e.horizontalAlignment="Center",e.verticalAlignment="Center",e.style={fill:n.iconStrokeColor,strokeColor:n.iconStrokeColor,strokeWidth:n.iconStrokeWidth},e.setOffsetWithRespectToBounds(.5,.5,"Fraction"),e.relativeMode="Object",e.description=t.description||"",e}function Xx(n,t,e){var i=qx(n,t),r=z.findAngle(n[i.index],n[i.index+1]),s=function mse(n){var t;t=n instanceof EI?0:void 0===n.content?10:0;var e=0;switch(n.alignment){case"Center":e=0;break;case"Before":e=-(0+t);break;case"After":e=0+t}return e}(t),o=z.transform(i.point,r+45,s);return i.point=o,i.angle=r,i}function qx(n,t){for(var r,s,a,l,e=0,i=t.offset,o=[],h=0;h=c)return s=z.findAngle(n[parseInt(d.toString(),10)],n[d+1]),{point:r=z.transform(n[parseInt(d.toString(),10)],s,c-(a||0)),index:l=d};a=o[parseInt(d.toString(),10)]}return{point:r,index:l}}function pF(n,t,e){t%=360;var a,l,s=225;switch(n.alignment){case"Before":t>=45&&t<=135?(l="right",a=.5===n.offset?"center":"top"):t>=s&&t<=315?(l="left",a=.5===n.offset?"center":"bottom"):t>45&&t=45&&t<=135?(l="left",a=.5===n.offset?"center":"top"):t>=s&&t<=315?(l="right",a=.5===n.offset?"center":"bottom"):t>45&&tMath.abs(t.y-n.y)?n.x0)for(var e=0;e=0;r--)("nodes"===i||"connectors"===i)&&(n[""+i][parseInt(r.toString(),10)].wrapper=null),"dataManager"!==i&&(n[""+i][parseInt(r.toString(),10)]=Jx(n[""+i][parseInt(r.toString(),10)],e[""+i][parseInt(r.toString(),10)],void 0!==t[""+i]?t[""+i][parseInt(r.toString(),10)]:[]),("[]"===JSON.stringify(n[""+i][parseInt(r.toString(),10)])||"{}"===JSON.stringify(n[""+i][parseInt(r.toString(),10)])||void 0===n[""+i][parseInt(r.toString(),10)])&&n[""+i].splice(r,1));n=void 0}function Ph(n,t){var e=t.style,i=t;t.canApplyStyle=!0;for(var r=0,s=Object.keys(n);r=0&&n.splice(e,1)}function Zp(n,t,e){var i;n.intermediatePoints=t,n.updateSegmentElement(n,t,n.wrapper.children[0],e);var r=n.sourceDecorator;if("Bezier"===n.type){var s=n.segments[0],o=n.segments[n.segments.length-1];i=[z.isEmptyPoint(o.point2)?o.bezierPoint2:o.point2,z.isEmptyPoint(s.point1)?s.bezierPoint1:s.point1]}else i=n.intermediatePoints;t=n.clipDecorators(n,t,e);var a=n.wrapper.children[0];a.canMeasurePath=!0,n.updateDecoratorElement(a=n.wrapper.children[1],t[0],i[1],r),n.updateDecoratorElement(a=n.wrapper.children[2],t[t.length-1],i[i.length-2],n.targetDecorator),n.updateShapeElement(n)}function Kx(n,t,e){var l,i=n.wrapper,s=t.offset,o=t.size/e.scale,a=t.margin,h=i.offsetX-i.actualSize.width*i.pivot.x,c=i.offsetY-i.actualSize.height*i.pivot.y;if(l={x:0,y:0},n.nodes.length>0){switch(t.side){case"Top":l.x+=h+s*i.actualSize.width,l.y+=c-o;break;case"Bottom":l.x+=h+s*i.actualSize.width,l.y+=c+i.actualSize.height+o;break;case"Left":l.x+=h-o,l.y+=c+s*i.actualSize.height;break;case"Right":l.x+=h+i.actualSize.width+o,l.y+=c+s*i.actualSize.height}l.x+=(a.left-a.right)/e.scale+o/2*("Center"===t.horizontalAlignment?0:"Right"===t.horizontalAlignment?-1:1),l.y+=(a.top-a.bottom)/e.scale+o/2*("Center"===t.verticalAlignment?0:"Top"===t.verticalAlignment?-1:1)}else if(n.connectors.length>0){var d=n.connectors[0],u={offset:s},p=qx(d.intermediatePoints,u),f=p.index;l=p.point;var y,v=Xx(d.intermediatePoints,u).angle;qi(y=Hi(),-v,d.intermediatePoints[parseInt(f.toString(),10)].x,d.intermediatePoints[parseInt(f.toString(),10)].y),(l=Je(y,l)).x+=a.left-a.right+o/2*("Center"===t.horizontalAlignment?0:"Right"===t.horizontalAlignment?-1:1),l.y+=a.top-a.bottom+o/2*("Center"===t.verticalAlignment?0:"Top"===t.verticalAlignment?-1:1),qi(y=Hi(),v,d.intermediatePoints[parseInt(f.toString(),10)].x,d.intermediatePoints[parseInt(f.toString(),10)].y),l=Je(y,l)}return 0===i.rotateAngle&&0===i.parentTransform||(qi(y=Hi(),i.rotateAngle+i.parentTransform,i.offsetX,i.offsetY),l=Je(y,l)),l}function fa(n,t,e,i){if(i.annotation){if(Ol(i.annotation))return!0}else if(mr[""+t]&n&&bt[""+t]&e)return!0;return!1}function qr(n,t){return!!(mr[""+t]&n)}function Hc(n,t){return!!(bx[""+t]&n)}function ga(n,t){return n.visibility&t}function KI(n,t){var e;if("Text"===n.shape.type)e=n.shape;else{var i=t.split("_");t=i[i.length-1];for(var r=0;rn[""+t]?e.splice(0,0,n):e.push(n);else if(e.length>1){for(var i=0,r=e.length-1,s=Math.floor((i+r)/2);s!==i;)if(e[parseInt(s.toString(),10)][""+t]n[""+t]))break;r=s,s=Math.floor((i+r)/2)}e[parseInt(r.toString(),10)][""+t]n[""+t]?e.splice(i,0,n):e[parseInt(i.toString(),10)][""+t]n[""+t]&&e.splice(r,0,n)}}function zse(n){var t=document.getElementById(n.diagramId),e="ej2_instances",i=t[""+e][0].nodes;void 0===i&&(i=function Rse(n){for(var t=[],e=0;e30?10:o/2;for(var h=0,c=0;c=l){var u=l-h;r=Gt(n[c],n[c+1]),s=z.transform(n[c],r,u);break}h+=d}return s},ib=function(n,t){if(n instanceof te||n instanceof de)for(var e=0;e=0||navigator.platform.indexOf("iPad")>=0||navigator.platform.indexOf("iPhone")>=0||navigator.platform.indexOf("MacIntel")>=0)&&("safari"===X.info.name||"webkit"===X.info.name)}function wF(n,t,e,i){return void 0!==t.previewSize[""+i]?t.previewSize[""+i]:void 0!==n.symbolPreview[""+i]?n.symbolPreview[""+i]:t[""+i]||e.actualSize[""+i]}function sm(n,t,e){return n&&n.parentId&&(e=(n=t.nameTable[n.parentId]).parentId?sm(n,t,e):n.id),e}function om(n,t){return n.selectedItems.connectors.length>1&&0===n.selectedItems.nodes.length&&0!==t.rotateAngle}function _se(n){if(n.arrowType&&""!==n.arrowType.trim())switch(n.arrowType){case"single-line-arrow":default:return{targetDecorator:"Arrow",strokeWidth:1};case"double-line-arrow":return{targetDecorator:"Arrow",strokeWidth:2};case"dotted-arrow":return{targetDecorator:"Arrow",strokeDashArray:"2,2"};case"single-line":return{targetDecorator:"None",strokeWidth:1};case"double-line":return{targetDecorator:"None",strokeWidth:2};case"dotted":return{targetDecorator:"None",strokeDashArray:"2,2"};case"wiggly-arrow":return{targetDecorator:"None",strokeWidth:1,opacity:0}}return{targetDecorator:"Arrow",strokeWidth:1}}var Use=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),io=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},CF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Use(t,n),io([I("None")],t.prototype,"shape",void 0),io([I("white")],t.prototype,"fill",void 0),io([I("Auto")],t.prototype,"horizontalAlignment",void 0),io([I("Auto")],t.prototype,"verticalAlignment",void 0),io([I(10)],t.prototype,"width",void 0),io([I(10)],t.prototype,"height",void 0),io([re({x:.5,y:1},z)],t.prototype,"offset",void 0),io([I("#1a1a1a")],t.prototype,"borderColor",void 0),io([I(1)],t.prototype,"borderWidth",void 0),io([re({},$n)],t.prototype,"margin",void 0),io([I("")],t.prototype,"pathData",void 0),io([I("")],t.prototype,"content",void 0),io([I(0)],t.prototype,"cornerRadius",void 0),io([re({left:2,right:2,top:2,bottom:2},$n)],t.prototype,"padding",void 0),io([I("#1a1a1a")],t.prototype,"iconColor",void 0),t}(Ee),jse=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),rT=function(n){function t(){var e=null!==n&&n.apply(this,arguments)||this;return e.orientation="Vertical",e.measureChildren=void 0,e.considerPadding=!0,e}return jse(t,n),t.prototype.measure=function(e){return this.desiredSize=this.measureStackPanel(e,"Horizontal"===this.orientation?this.updateHorizontalStack:this.updateVerticalStack),this.desiredSize},t.prototype.arrange=function(e){return this.actualSize=this.arrangeStackPanel(e,"Horizontal"===this.orientation?this.arrangeHorizontalStack:this.arrangeVerticalStack),this.updateBounds(),this.actualSize},t.prototype.measureStackPanel=function(e,i){var r=void 0;if(void 0!==this.children&&this.children.length>0)for(var s=0,o=this.children;s0){var r=void 0,s=void 0;r=this.offsetX-e.width*this.pivot.x+this.padding.left,s=this.offsetY-e.height*this.pivot.y+this.padding.top;for(var o=0,a=this.children;o0)for(var i=0,r=this.children;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},$se=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return qse(t,n),zh([I("Horizontal")],t.prototype,"orientation",void 0),zh([I("Center")],t.prototype,"type",void 0),zh([I(void 0)],t.prototype,"offset",void 0),zh([I(!1)],t.prototype,"enableRouting",void 0),zh([I([])],t.prototype,"children",void 0),zh([I("")],t.prototype,"assistants",void 0),zh([I("")],t.prototype,"level",void 0),zh([I("")],t.prototype,"hasSubTree",void 0),zh([I("")],t.prototype,"rows",void 0),t}(Ee),Li=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),q=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Zse=function(n){if(n)switch(n.type){case"Basic":default:return rb;case"Flow":return TF;case"Path":return EF;case"Image":return xF;case"Text":return Pd;case"Bpmn":return hT;case"Native":return am;case"HTML":return DF;case"UmlActivity":return AF;case"UmlClassifier":return LF;case"SwimLane":return Hd}return rb},va=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),q([I("Basic")],t.prototype,"type",void 0),t}(Ee),EF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"Path"},q([I("Path")],t.prototype,"type",void 0),q([I("")],t.prototype,"data",void 0),t}(va),am=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"Native"},q([I("Native")],t.prototype,"type",void 0),q([I("")],t.prototype,"content",void 0),q([I("Stretch")],t.prototype,"scale",void 0),t}(va),DF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"Html"},q([I("HTML")],t.prototype,"type",void 0),q([I("")],t.prototype,"content",void 0),t}(va),xF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"Image"},q([I("Image")],t.prototype,"type",void 0),q([I("")],t.prototype,"source",void 0),q([I("None")],t.prototype,"scale",void 0),q([I("None")],t.prototype,"align",void 0),t}(va),Pd=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"Text"},q([I("Text")],t.prototype,"type",void 0),q([I("")],t.prototype,"content",void 0),q([re({},$n)],t.prototype,"margin",void 0),t}(va),rb=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"BasicShape"},q([I("Basic")],t.prototype,"type",void 0),q([I("Rectangle")],t.prototype,"shape",void 0),q([I(0)],t.prototype,"cornerRadius",void 0),q([Bt([],z)],t.prototype,"points",void 0),t}(va),TF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"FlowShape"},q([I("Flow")],t.prototype,"type",void 0),q([I("Terminator")],t.prototype,"shape",void 0),t}(va),sT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"BpmnGateway"},q([I("None")],t.prototype,"type",void 0),t}(Ee),oT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"BpmnDataObject"},q([I("None")],t.prototype,"type",void 0),q([I(!1)],t.prototype,"collection",void 0),t}(Ee),Jse=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),q([I("None")],t.prototype,"type",void 0),q([I("None")],t.prototype,"loop",void 0),q([I(!1)],t.prototype,"call",void 0),q([I(!1)],t.prototype,"compensation",void 0),t}(Ee),aT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"BpmnEvent"},q([I("Start")],t.prototype,"event",void 0),q([I("None")],t.prototype,"trigger",void 0),t}(Ee),zd=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"BpmnSubEvent"},q([I("None")],t.prototype,"trigger",void 0),q([I("Start")],t.prototype,"event",void 0),q([I("")],t.prototype,"id",void 0),q([re({},z)],t.prototype,"offset",void 0),q([Bt([],Zn)],t.prototype,"annotations",void 0),q([Bt([],Es)],t.prototype,"ports",void 0),q([I()],t.prototype,"width",void 0),q([I()],t.prototype,"height",void 0),q([re({},$n)],t.prototype,"margin",void 0),q([I("Center")],t.prototype,"horizontalAlignment",void 0),q([I("Center")],t.prototype,"verticalAlignment",void 0),q([I(!0)],t.prototype,"visible",void 0),t}(Ee),Kse=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),q([re({id:"success",event:"End",offset:{x:1,y:.5}},zd)],t.prototype,"success",void 0),q([re({id:"failure",event:"Intermediate",trigger:"Error",offset:{x:.25,y:1}},zd)],t.prototype,"failure",void 0),q([re({id:"cancel",event:"Intermediate",trigger:"Cancel",offset:{x:.75,y:1}},zd)],t.prototype,"cancel",void 0),t}(Ee),eoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),q([I("None")],t.prototype,"type",void 0),q([I(!1)],t.prototype,"adhoc",void 0),q([I("Default")],t.prototype,"boundary",void 0),q([I(!1)],t.prototype,"compensation",void 0),q([I("None")],t.prototype,"loop",void 0),q([I(!0)],t.prototype,"collapsed",void 0),q([Bt([],zd)],t.prototype,"events",void 0),q([re({},Kse)],t.prototype,"transaction",void 0),q([I(void 0)],t.prototype,"processes",void 0),t}(Ee),lT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"BpmnActivity"},q([I("Task")],t.prototype,"activity",void 0),q([re({},Jse)],t.prototype,"task",void 0),q([re({},eoe)],t.prototype,"subProcess",void 0),t}(Ee),lm=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return Li(t,n),t.prototype.getClassName=function(){return"BpmnAnnotation"},q([I("")],t.prototype,"text",void 0),q([I("")],t.prototype,"id",void 0),q([I(0)],t.prototype,"angle",void 0),q([I()],t.prototype,"height",void 0),q([I()],t.prototype,"width",void 0),q([I(0)],t.prototype,"length",void 0),t}(Ee),toe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),q([I("")],t.prototype,"textAnnotationTarget",void 0),q([I("Auto")],t.prototype,"textAnnotationDirection",void 0),t}(Ee),hT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"BpmnShape"},q([I("Bpmn")],t.prototype,"type",void 0),q([I("Event")],t.prototype,"shape",void 0),q([re({},aT)],t.prototype,"event",void 0),q([re({},sT)],t.prototype,"gateway",void 0),q([re({},oT)],t.prototype,"dataObject",void 0),q([re({},lT)],t.prototype,"activity",void 0),q([re({},lm)],t.prototype,"annotation",void 0),q([Bt([],lm)],t.prototype,"annotations",void 0),q([re({},toe)],t.prototype,"textAnnotation",void 0),t}(va),AF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"UmlActivityShape"},q([I("UmlActivity")],t.prototype,"type",void 0),q([I("Action")],t.prototype,"shape",void 0),t}(va),cT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"MethodArguments"},q([I("")],t.prototype,"name",void 0),q([I("")],t.prototype,"type",void 0),q([re({},Yp)],t.prototype,"style",void 0),t}(Ee),rf=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"UmlClassAttribute"},q([I("Public")],t.prototype,"scope",void 0),q([I(!1)],t.prototype,"isSeparator",void 0),q([re({fill:"#F9F9F9",strokeColor:"#CCCCCC"},Al)],t.prototype,"separatorStyle",void 0),t}(cT),hm=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"UmlClassMethod"},q([Bt([],cT)],t.prototype,"parameters",void 0),t}(rf),nb=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"UmlClass"},q([I("")],t.prototype,"name",void 0),q([Bt([],rf)],t.prototype,"attributes",void 0),q([Bt([],hm)],t.prototype,"methods",void 0),q([re({},Yp)],t.prototype,"style",void 0),t}(Ee),dT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"UmlInterface"},q([I(!1)],t.prototype,"isSeparator",void 0),q([re({fill:"#F9F9F9",strokeColor:"#CCCCCC"},Al)],t.prototype,"separatorStyle",void 0),t}(nb),sb=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"UmlEnumerationMember"},q([I("")],t.prototype,"name",void 0),q([I("")],t.prototype,"value",void 0),q([I(!1)],t.prototype,"isSeparator",void 0),q([re({fill:"#F9F9F9",strokeColor:"#CCCCCC"},Al)],t.prototype,"separatorStyle",void 0),q([re({},Yp)],t.prototype,"style",void 0),t}(Ee),uT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"UmlEnumeration"},q([I("")],t.prototype,"name",void 0),q([Bt([],sb)],t.prototype,"members",void 0),q([re({},Yp)],t.prototype,"style",void 0),t}(Ee),LF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"UmlClassifierShape"},q([I("UmlClassifier")],t.prototype,"type",void 0),q([re({},nb)],t.prototype,"classShape",void 0),q([re({},dT)],t.prototype,"interfaceShape",void 0),q([re({},uT)],t.prototype,"enumerationShape",void 0),q([I("Class")],t.prototype,"classifier",void 0),t}(va),te=function(n){function t(e,i,r,s){var a,o=n.call(this,e,i,r,s)||this;return o.isCanvasUpdate=!1,o.status="None",o.parentId="",o.processId="",o.umlIndex=-1,o.outEdges=[],o.inEdges=[],o.isHeader=!1,o.isLane=!1,o.isPhase=!1,o.children&&o.children.length>0&&((!(a=r).style||!a.style.fill)&&(o.style.fill="transparent"),(!a.style||!a.style.strokeColor)&&(o.style.strokeColor="transparent")),o.shape&&"UmlActivity"===o.shape.type&&ZI(r,o),o.shape&&"SwimLane"===o.shape.type&&aF(r,o),o.ports&&o.ports.length&&function sse(n){for(var t=0;t>";t=n;break;case"FinalNode":t=fF(e)}return t}(new Ke,i,this);break;case"Bpmn":if(e.bpmnModule){i=e.bpmnModule.initBPMNContent(i,this,e),this.wrapper.elementActions=this.wrapper.elementActions|Xr.ElementIsGroup;var v=this.shape.activity.subProcess;if(v.processes&&v.processes.length)for(var S=0,b=this.shape.activity.subProcess.processes;S>",margin:{left:10,right:10},id:"class",style:{fontSize:i.style.fontSize,color:i.style.color,fill:i.style.fill,textWrapping:r},offset:{x:.5,y:.3},constraints:Lr.ReadOnly}],constraints:(ie.Default|ie.HideThumbs)&~(ie.Rotate|ie.Drag|ie.Resize),verticalAlignment:"Stretch",horizontalAlignment:"Stretch",style:{fill:t.style.fill,strokeColor:"black"===t.style.strokeColor?"#ffffff00":t.style.strokeColor}},!0);return e.initObject(s),e.nodes.push(s),e.UpdateBlazorDiagramModel(s,"Node"),t.children.push(s.id),function Wse(n,t,e,i){if("Enumeration"===n.shape.classifier){var r=e.members;if(r&&r.length){ef(n,t);for(var s="",o=0;o0)for(var o=0;o0&&s.phaseSize&&(i+=s.phaseSize,Gv(n,s.phaseSize)),s.lanes.length>0)for(o=0;o0){var a=0;for(o=0;o0&&"Horizontal"===r.orientation)for(l=0;l0&&(i+=r.phaseSize,o=Xv(r.phaseSize),n.push(o)),a=0;a0&&o.phaseSize){for(var l=0;l0)for(l=0;l0?e.nameTable[this.nodes[0].id].wrapper:e.nameTable[this.connectors[0].id].wrapper,this.annotation.id);i.children.push(s)}else if(this.nodes||this.connectors){for(var o=0;o-1}function HF(n,t,e){n=[];for(var i=0,r=e.length;i0?c.getElementsByTagName("svg")[0].outerHTML:c.getElementsByTagName("g").length>0?c.getElementsByTagName("g")[0].outerHTML:"",s.shape.content=h,n.content=h,c.parentElement.removeChild(c)}l="nodeTemplate"}else a=s,l="annotationTemplate";var f=document.getElementById(n.diagramId).ej2_instances[0];if("string"!=typeof n.content&&"function"!=typeof n.content||n.isTemplate)if(n.isTemplate){if(v=void 0,v=f.isReact?n.getNodeTemplate()($(e),f,l+"_"+("nodeTemplate"===l?e.id:n.nodeId+e.id),void 0,void 0,!1,i):f.isVue||f.isVue3?n.getNodeTemplate()?n.getNodeTemplate()($(e),f,l+"_"+("nodeTemplate"===l?e.id:n.nodeId+e.id),void 0,void 0,!1,i):(v=ii("nodeTemplate"===l?f.nodeTemplate:f.annotationTemplate))($(e),f,l+"_"+("nodeTemplate"===l?e.id:n.nodeId+e.id),void 0,void 0,!1,i):n.getNodeTemplate()($(e),f,l+"_"+("nodeTemplate"===l?e.id:n.nodeId+e.id),void 0,void 0,!1))for(var M=0;M=1&&0===n.x&&("Clip"===i.textOverflow||"Ellipsis"===i.textOverflow)&&("Wrap"===i.textWrapping||"WrapWithOverflow"===i.textWrapping)&&(n.x=t[e-1]?t[e-1].x:-n.width/2),n.x}function _F(n,t,e,i){return e&&!t.template||t.template&&"function"==typeof t.template&&i.isReact?(n.isTemplate=!0,n.template=n.content=Rh(n,!0,t)):n.content=t.template,n}function Qe(){for(var e,t="",i=0;i<5;i++){if(typeof window<"u"&&"crypto"in window&&"getRandomValues"in crypto){var r=new Uint16Array(1);e=(window.msCrypto||window.crypto).getRandomValues(r)[0]%60}else e=Math.floor(61*Math.random());0===i&&e<10?i--:t+="0123456789ABCDEFGHIJKLMNOPQRSTUVWXTZabcdefghiklmnopqrstuvwxyz".substring(e,e+1)}return t}function UF(n){if(n)try{return"function"!=typeof n&&document.querySelectorAll(n).length?ii(document.querySelector(n).innerHTML.trim()):ii(n)}catch{return ii(n)}}function En(n){new Ne;var e=n.offsetY-n.actualSize.height*n.pivot.y,i=n.offsetY+n.actualSize.height*(1-n.pivot.y),r=n.offsetX-n.actualSize.width*n.pivot.x,s=n.offsetX+n.actualSize.width*(1-n.pivot.x);return Ne.toBounds([{x:r,y:e},{x:s,y:e},{x:r,y:i},{x:s,y:i}])}function yr(n){var t=new Ne,e=En(n),i=e.middleLeft,r=e.topCenter,s=e.bottomCenter,o=e.middleRight,a=e.topLeft,l=e.topRight,h=e.bottomLeft,c=e.bottomRight;if(n.corners={topLeft:a,topCenter:r,topRight:l,middleLeft:i,middleRight:o,bottomLeft:h,bottomCenter:s,bottomRight:c},0!==n.rotateAngle||0!==n.parentTransform){var d=Hi();qi(d,n.rotateAngle+n.parentTransform,n.offsetX,n.offsetY),n.corners.topLeft=a=Je(d,a),n.corners.topCenter=r=Je(d,r),n.corners.topRight=l=Je(d,l),n.corners.middleLeft=i=Je(d,i),n.corners.middleRight=o=Je(d,o),n.corners.bottomLeft=h=Je(d,h),n.corners.bottomCenter=s=Je(d,s),n.corners.bottomRight=c=Je(d,c)}return t=Ne.toBounds([a,l,h,c]),n.corners.left=t.left,n.corners.right=t.right,n.corners.top=t.top,n.corners.bottom=t.bottom,n.corners.center=t.center,n.corners.width=t.width,n.corners.height=t.height,t}function $(n,t,e,i){var r={},s="properties";if(n){e=n.propName;var l=[],h=[];if((l=l.concat(Object.keys(n[""+s]||n))).push("version"),e){var c=Zi(t);h=c?c(e):[],l=l.concat(h)}for(var d=function boe(n){switch(n){case"nodes":case"children":return["inEdges","outEdges","parentId","processId","nodeId","umlIndex","isPhase","isLane"];case"connectors":return["parentId"];case"annotation":case"annotations":return["nodeId"];case"shape":return["hasHeader"];case"layers":return["objectZIndex"]}return[]}(e),u=0,p=l=l.concat(d);u0&&(e=r),r=Math.floor(woe(e,i)),s=Bc(o+=n.substr(e,r),t)}while(s<=t.width);for(o=o.substr(0,e),a=e;a=t.width){n=n.substr(0,o.length-1);break}return"Ellipsis"===t.textOverflow?(n=n.substr(0,n.length-3),n+="..."):n=n.substr(0,n.length),n}function ST(n,t){if("NoWrap"===t&&"PreserveAll"===n)return"pre";var e="";switch(n){case"CollapseAll":e="nowrap";break;case"CollapseSpace":e="pre-line";break;case"PreserveAll":e="pre-wrap"}return e}function IT(n,t){var e=Hi();qi(e,t,0,0);var i=Je(e,{x:0,y:0}),r=Je(e,{x:n.width,y:0}),s=Je(e,{x:0,y:n.height}),o=Je(e,{x:n.width,y:n.height}),a=Math.min(i.x,r.x,s.x,o.x),l=Math.min(i.y,r.y,s.y,o.y),h=Math.max(i.x,r.x,s.x,o.x),c=Math.max(i.y,r.y,s.y,o.y);return new me(h-a,c-l)}function xs(n,t,e,i){if(0!==n){var r=Hi();return qi(r,n,t,e),Je(r,i)}return i}function Zi(n){return void 0!==n&&"string"==typeof n&&(n=Y(n,window)),n}var bo=function(){function n(){}return n.getContext=function(t){return t.getContext("2d")},n.setCanvasSize=function(t,e,i){t&&(t.setAttribute("width",e.toString()),t.setAttribute("height",i.toString()))},n.prototype.renderGradient=function(t,e,i,r){var s,o,a;if("None"!==t.gradient.type){for(var l=0;l0?(w=0===S.r1?e.arc[parseInt(r.toString(),10)].r1:S.r1,C=0===S.r2?e.arc[parseInt(r.toString(),10)].r2:S.r2,r++):(w=S.r1,C=S.r2);var D=S.angle*(Math.PI/180),A=S.largeArc,x=S.sweep,R={x:u,y:p},L={x:Math.cos(D)*(M.x-R.x)/2+Math.sin(D)*(M.y-R.y)/2,y:-Math.sin(D)*(M.x-R.x)/2+Math.cos(D)*(M.y-R.y)/2},O=Math.pow(L.x,2)/Math.pow(w,2)+Math.pow(L.y,2)/Math.pow(C,2);O>1&&(w*=Math.sqrt(O),C*=Math.sqrt(O));var N=Math.pow(C,2)*Math.pow(L.x,2),T=(A===x?-1:1)*Math.sqrt((Math.pow(w,2)*Math.pow(C,2)-Math.pow(w,2)*Math.pow(L.y,2)-N)/(Math.pow(w,2)*Math.pow(L.y,2)+Math.pow(C,2)*Math.pow(L.x,2)));isNaN(T)&&(T=0);var P={x:T*w*L.y/C,y:T*-C*L.x/w},_={x:(M.x+R.x)/2+Math.cos(D)*P.x-Math.sin(D)*P.y,y:(M.y+R.y)/2+Math.sin(D)*P.x+Math.cos(D)*P.y},B=this.a([1,0],[(L.x-P.x)/w,(L.y-P.y)/C]),j=[(L.x-P.x)/w,(L.y-P.y)/C],Q=[(-L.x-P.x)/w,(-L.y-P.y)/C],oe=this.a(j,Q);this.r(j,Q)<=-1&&(oe=Math.PI),this.r(j,Q)>=1&&(oe=0);var pe=B+oe/2*(x?1:-1);if(Math.cos(pe),Math.sin(pe),S.centp=_,S.xAxisRotation=D,S.rx=w,S.ry=C,S.a1=B,S.ad=oe,S.sweep=x,null!=s){var De=w>C?w:C,xe=w>C?1:w/C,Ie=w>C?C/w:1;s.save(),s.translate(_.x,_.y),s.rotate(D),s.scale(xe,Ie),s.arc(0,0,De,B,B+oe,!x),s.scale(1/xe,1/Ie),s.rotate(-D),s.translate(-_.x,-_.y),s.restore()}break;case"Z":case"z":s.closePath(),u=o,p=a}o=u,a=p}}},n.prototype.drawText=function(t,e,i,r,s,o,a){if(e.content&&!0===e.visible){var l=n.getContext(t);l.save(),this.setStyle(t,e),o&&(e.fontSize*=o),this.rotateContext(t,e.angle,e.x+e.width*e.pivotX,e.y+e.height*e.pivotY),this.setFontStyle(t,e);var u,d=0;u=e.childNodes;var p=e.wrapBounds;if(l.fillStyle=e.color,p){var f=this.labelAlign(e,p,u);for(d=0;de.width&&"Wrap"!==e.textOverflow&&"NoWrap"===e.textWrapping&&(g.text=VF(g.text,e)),"Clip"!==e.textOverflow&&"Ellipsis"!==e.textOverflow||"Wrap"!==e.textWrapping?l.fillText(g.text,v,y):ya.actualSize.height+a.bounds.y&&(g.text=g.text.slice(0,g.text.length-3),g.text=g.text.concat("...")),l.fillText(g.text,v,y)),"Underline"===e.textDecoration||"Overline"===e.textDecoration||"LineThrough"===e.textDecoration){var M=v,w=void 0,D=v+l.measureText(g.text).width,A=void 0;switch(e.textDecoration){case"Underline":w=y+2,A=y+2;break;case"Overline":w=f.y+g.dy*d,A=f.y+g.dy*d;break;case"LineThrough":w=(y+f.y+g.dy*d)/2+2,A=(y+f.y+g.dy*d)/2+2}l.beginPath(),l.moveTo(M,w),l.lineTo(D,A),l.strokeStyle=e.color,l.lineWidth=.08*e.fontSize,l.globalAlpha=e.opacity,l.stroke()}}}l.restore()}},n.prototype.loadImage=function(t,e,i,r,s){this.rotateContext(i,e.angle,r,s);var o=new Image;o.src=e.source,this.image(t,o,e.x,e.y,e.width,e.height,e)},n.prototype.drawImage=function(t,e,i,r){var s=this;if(e.visible){var o=n.getContext(t);o.save();var a=e.x+e.width*e.pivotX,l=e.y+e.height*e.pivotY,h=new Image;h.src=e.source,o.canvas.id.split("_"),r?h.onload=function(){s.loadImage(o,e,t,a,l)}:this.loadImage(o,e,t,a,l),o.restore()}},n.prototype.image=function(t,e,i,r,s,o,a){t.beginPath();var l=e.width,h=e.height,c=s,d=o,u=0,p=0;if(a&&"None"!==a.alignment){var f=a.alignment.toLowerCase().substr(1,3),g=a.alignment.toLowerCase().substr(5,3);if("Slice"===a.scale){var v=function(){u=c,p=h*c/l},y=function(){u=l*d/h,p=d};c>d?(v(),d>p&&y()):c===d?l>h?y():v():(y(),c>u&&v());var S=this.getSliceOffset(f,u,c,l),b=this.getSliceOffset(g,p,d,h),M=l-S,w=h-b,C=u-S*(u/l),D=p-b*(p/h),A=Tt("canvas",{width:s.toString(),height:o.toString()});A.getContext("2d").drawImage(e,S,b,M,w,0,0,C,D),t.drawImage(A,i,r,s,o)}else if("Meet"===a.scale){var R=h/l,L=d/c;p=L>R?c*R:d,i+=this.getMeetOffset(f,u=L>R?c:d/R,c),r+=this.getMeetOffset(g,p,d),t.drawImage(e,0,0,l,h,i,r,u,p)}else t.drawImage(e,i,r,s,o)}else if("None"!==a.flip){var O=1,N=1;("Horizontal"===a.flip||"Both"===a.flip)&&(i=-i,s=-s,O=-1),("Vertical"===a.flip||"Both"===a.flip)&&(r=-r,o=-o,N=-1),t.scale(O,N),t.drawImage(e,i,r,s,o)}else t.drawImage(e,i,r,s,o);t.closePath()},n.prototype.getSliceOffset=function(t,e,i,r){switch(t){case"min":default:return 0;case"mid":return(e-i)/2*r/e;case"max":return(e-i)*r/e}},n.prototype.getMeetOffset=function(t,e,i){var r=Math.max(e,i),s=Math.min(e,i);switch(t){case"min":default:return 0;case"mid":return(r-s)/2;case"max":return r-s}},n.prototype.m=function(t){return Math.sqrt(Math.pow(t[0],2)+Math.pow(t[1],2))},n.prototype.r=function(t,e){return(t[0]*e[0]+t[1]*e[1])/(this.m(t)*this.m(e))},n.prototype.a=function(t,e){return(t[0]*e[1]t.width&&("Ellipsis"===t.textOverflow||"Clip"===t.textOverflow)&&"NoWrap"===t.textWrapping?0:.5*t.width:"right"===t.textAlign&&(c=1*t.width),s.x=t.x+c+(e?e.x:0),s.y=a+d-r.height/2,s},n}(),cb=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Vi=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Eoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return cb(t,n),Vi([I("")],t.prototype,"source",void 0),Vi([I("transparent")],t.prototype,"color",void 0),Vi([I("None")],t.prototype,"scale",void 0),Vi([I("None")],t.prototype,"align",void 0),t}(Ee),Doe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return cb(t,n),Vi([I("Page")],t.prototype,"mode",void 0),Vi([I("PageSettings")],t.prototype,"region",void 0),Vi([re({top:25,bottom:25,left:25,right:25},$n)],t.prototype,"margin",void 0),Vi([I(!1)],t.prototype,"canZoomIn",void 0),Vi([I(void 0)],t.prototype,"customBounds",void 0),Vi([I(!1)],t.prototype,"canFit",void 0),t}(Ee),xoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return cb(t,n),Vi([I(null)],t.prototype,"width",void 0),Vi([I(null)],t.prototype,"height",void 0),Vi([re({},$n)],t.prototype,"margin",void 0),Vi([I("Landscape")],t.prototype,"orientation",void 0),Vi([I("Infinity")],t.prototype,"boundaryConstraints",void 0),Vi([re({},Eoe)],t.prototype,"background",void 0),Vi([I(!1)],t.prototype,"multiplePage",void 0),Vi([I(!1)],t.prototype,"showPageBreaks",void 0),Vi([re({},Doe)],t.prototype,"fitOptions",void 0),t}(Ee),Toe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return cb(t,n),Vi([I(0)],t.prototype,"horizontalOffset",void 0),Vi([I(0)],t.prototype,"verticalOffset",void 0),Vi([I(1)],t.prototype,"currentZoom",void 0),Vi([I(0)],t.prototype,"viewPortWidth",void 0),Vi([I(0)],t.prototype,"viewPortHeight",void 0),Vi([I(.2)],t.prototype,"minZoom",void 0),Vi([I(30)],t.prototype,"maxZoom",void 0),Vi([I("Diagram")],t.prototype,"scrollLimit",void 0),Vi([I()],t.prototype,"scrollableArea",void 0),Vi([I(!1)],t.prototype,"canAutoScroll",void 0),Vi([I(100)],t.prototype,"autoScrollFrequency",void 0),Vi([re({left:15,right:15,top:15,bottom:15},$n)],t.prototype,"autoScrollBorder",void 0),Vi([re({left:0,right:0,top:0,bottom:0},$n)],t.prototype,"padding",void 0),Vi([I(.2)],t.prototype,"zoomFactor",void 0),t}(Ee),Aoe=function(){function n(){this.services={}}return n.prototype.register=function(t,e){this.services[""+t]=e},n.prototype.getService=function(t){return this.services[""+t]},n}(),WF=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),ma=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},YF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return WF(t,n),ma([I("lightgray")],t.prototype,"lineColor",void 0),ma([I("")],t.prototype,"lineDashArray",void 0),ma([I([1.25,18.75,.25,19.75,.25,19.75,.25,19.75,.25,19.75])],t.prototype,"lineIntervals",void 0),ma([I([1,19,.5,19.5,.5,19.5,.5,19.5,.5,19.5])],t.prototype,"dotIntervals",void 0),ma([I([20])],t.prototype,"snapIntervals",void 0),t}(Ee),Loe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return WF(t,n),ma([re({},YF)],t.prototype,"horizontalGridlines",void 0),ma([re({},YF)],t.prototype,"verticalGridlines",void 0),ma([I(Kt.All)],t.prototype,"constraints",void 0),ma([I(5)],t.prototype,"snapAngle",void 0),ma([I("Lines")],t.prototype,"gridType",void 0),ma([I(5)],t.prototype,"snapObjectDistance",void 0),ma([I("#07EDE1")],t.prototype,"snapLineColor",void 0),t}(Ee),QF=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Ja=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},GF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return QF(t,n),Ja([I(5)],t.prototype,"interval",void 0),Ja([I(100)],t.prototype,"segmentWidth",void 0),Ja([I("Horizontal")],t.prototype,"orientation",void 0),Ja([I("RightOrBottom")],t.prototype,"tickAlignment",void 0),Ja([I("red")],t.prototype,"markerColor",void 0),Ja([I(25)],t.prototype,"thickness",void 0),Ja([I(null)],t.prototype,"arrangeTick",void 0),t}(Ee),Noe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return QF(t,n),Ja([I(!1)],t.prototype,"showRulers",void 0),Ja([I(!0)],t.prototype,"dynamicGrid",void 0),Ja([re({orientation:"Horizontal"},GF)],t.prototype,"horizontalRuler",void 0),Ja([re({orientation:"Vertical"},GF)],t.prototype,"verticalRuler",void 0),t}(Ee),Ooe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),XF=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},koe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ooe(t,n),XF([I("")],t.prototype,"property",void 0),XF([I("")],t.prototype,"field",void 0),t}(Ee),bT=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),ln=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},qF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return bT(t,n),ln([I("")],t.prototype,"read",void 0),ln([I("")],t.prototype,"create",void 0),ln([I("")],t.prototype,"update",void 0),ln([I("")],t.prototype,"destroy",void 0),ln([I()],t.prototype,"customFields",void 0),t}(Ee),Poe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return bT(t,n),ln([I("")],t.prototype,"id",void 0),ln([I("")],t.prototype,"sourceID",void 0),ln([I("")],t.prototype,"targetID",void 0),ln([I(null)],t.prototype,"sourcePointX",void 0),ln([I(null)],t.prototype,"sourcePointY",void 0),ln([I(null)],t.prototype,"targetPointX",void 0),ln([I(null)],t.prototype,"targetPointY",void 0),ln([I(null)],t.prototype,"dataManager",void 0),ln([re({},qF)],t.prototype,"crudAction",void 0),t}(Ee),zoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return bT(t,n),ln([I("")],t.prototype,"id",void 0),ln([I(null)],t.prototype,"dataManager",void 0),ln([I(null)],t.prototype,"dataSource",void 0),ln([I("")],t.prototype,"root",void 0),ln([I("")],t.prototype,"parentId",void 0),ln([I()],t.prototype,"doBinding",void 0),ln([Bt([],koe)],t.prototype,"dataMapSettings",void 0),ln([re({},qF)],t.prototype,"crudAction",void 0),ln([re({},Poe)],t.prototype,"connectionDataSource",void 0),t}(Ee),$F=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Cr=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Roe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return $F(t,n),Cr([I("LeftInFlow")],t.prototype,"yesBranchDirection",void 0),Cr([I("RightInFlow")],t.prototype,"noBranchDirection",void 0),Cr([I(["Yes","True"])],t.prototype,"yesBranchValues",void 0),Cr([I(["No","False"])],t.prototype,"noBranchValues",void 0),t}(Ee),Hoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return $F(t,n),Cr([I("")],t.prototype,"fixedNode",void 0),Cr([I(30)],t.prototype,"horizontalSpacing",void 0),Cr([I("SamePoint")],t.prototype,"connectionPointOrigin",void 0),Cr([I("Nonlinear")],t.prototype,"arrangement",void 0),Cr([I(30)],t.prototype,"verticalSpacing",void 0),Cr([I(30)],t.prototype,"maxIteration",void 0),Cr([I(40)],t.prototype,"springFactor",void 0),Cr([I(50)],t.prototype,"springLength",void 0),Cr([re({left:50,top:50,right:0,bottom:0},$n)],t.prototype,"margin",void 0),Cr([I("Auto")],t.prototype,"horizontalAlignment",void 0),Cr([I("Auto")],t.prototype,"verticalAlignment",void 0),Cr([I("TopToBottom")],t.prototype,"orientation",void 0),Cr([I("Auto")],t.prototype,"connectionDirection",void 0),Cr([I("Default")],t.prototype,"connectorSegments",void 0),Cr([I("None")],t.prototype,"type",void 0),Cr([I()],t.prototype,"getLayoutInfo",void 0),Cr([I()],t.prototype,"layoutInfo",void 0),Cr([I()],t.prototype,"getBranch",void 0),Cr([I()],t.prototype,"bounds",void 0),Cr([I(!0)],t.prototype,"enableAnimation",void 0),Cr([I(!1)],t.prototype,"enableRouting",void 0),Cr([I("")],t.prototype,"root",void 0),Cr([re({},Roe)],t.prototype,"flowchartLayoutSettings",void 0),t}(Ee),Boe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),ZF=function(n){function t(e,i){var r=n.call(this,e,!0)||this;return r.oldValue=null,r.endPoint=i,r}return Boe(t,n),t.prototype.mouseDown=function(e){var i,r=!0;if(e.source&&e.source.connectors&&(i=e.source.connectors[0]),e.info&&e.actualObject&&(r=e.info.ctrlKey&&"Orthogonal"!==e.actualObject.type),i&&r){this.inAction=!0,this.undoElement=$(e.source),n.prototype.mouseDown.call(this,e);for(var s=0;s0)1!==s&&this.removePrevSegment(i,s);else if(a){var l=z.distancePoints(a.points[0],a.points[1]);Math.abs(a.length||0===a.length?a.length:l)<=5&&this.removeNextSegment(i,s)}this.commandHandler.updateEndPoint(i,r),i.selectedSegmentIndex=0}if(this.undoElement){var c=$(e.source);this.commandHandler.addHistoryEntry({type:"SegmentChanged",redoObject:c,undoObject:this.undoElement,category:"Internal"})}if(i.isBezierEditing&&(i.isBezierEditing=!1),this.prevPosition!==this.startPosition){var u={source:i,state:"Completed",oldValue:this.oldValue,newValue:$(this.selectedSegment),cancel:!1,segment:this.selectedSegment};this.commandHandler.triggerEvent(Ce.segmentChange,u)}n.prototype.mouseUp.call(this,e)},t.prototype.removePrevSegment=function(e,i){var r=e.segments[i-2],s=e.segments[i+1];if(s&&!((s.length||0===s.length?s.length:z.distancePoints(s.points[0],s.points[1]))<=5)){var a=e.segments.slice(i-1,i+1),l={element:e,removeSegments:a,type:"Removal",cancel:!1};if(this.commandHandler.triggerEvent(Ce.segmentCollectionChange,l),!l.cancel){var h=e.segments[i+1];e.segments.splice(i-1,2);var c=this.selectedSegment;"Left"===c.direction||"Right"===c.direction?(r.points[r.points.length-1].x=h.points[0].x,h.points[0].y=r.points[r.points.length-1].y):(r.points[r.points.length-1].y=h.points[0].y,h.points[0].x=r.points[r.points.length-1].x),(c.length||0===c.length)&&this.findSegmentDirection(r),this.findSegmentDirection(h)}}},t.prototype.findSegmentDirection=function(e){e.direction&&(e.length||0===e.length)&&(e.length=z.distancePoints(e.points[0],e.points[e.points.length-1]),e.direction=z.direction(e.points[0],e.points[e.points.length-1]))},t.prototype.removeNextSegment=function(e,i){var l,h,r=this.selectedSegment,s=e.segments[i-1],o=e.segments[i+2],a=e.segments[i+1];if(a.length||0===a.length?(l=e.segments.slice(i,2),h={element:e,removeSegments:l,type:"Removal",cancel:!1},this.commandHandler.triggerEvent(Ce.segmentCollectionChange,h={element:e,removeSegments:l,type:"Removal",cancel:!1}),h.cancel||(e.segments.splice(i,2),"Top"===r.direction||"Bottom"===r.direction?(o.points[0].y=r.points[0].y,s.points[s.points.length-1].x=o.points[0].x):(o.points[0].x=r.points[0].x,s.points[s.points.length-1].y=o.points[0].y))):(l=e.segments.slice(i+1,1),this.commandHandler.triggerEvent(Ce.segmentCollectionChange,h={element:e,removeSegments:l,type:"Removal",cancel:!1}),h.cancel||(e.segments.splice(i+1,1),"Top"===r.direction||"Bottom"===r.direction?s.points[s.points.length-1].x=a.points[a.points.length-1].x:s.points[s.points.length-1].y=a.points[a.points.length-1].y,this.findSegmentDirection(s),r.length=r.direction=null)),s&&o&&!h.cancel&&(s.length=z.distancePoints(s.points[0],o.points[0]),s.direction=z.direction(s.points[0],o.points[0]),o.length||0===o.length)){o.length=z.distancePoints(s.points[s.points.length-1],o.points[o.points.length-1]);var c=s.points,d=o.points;o.direction=z.direction(c[c.length-1],d[d.length-1])}},t.prototype.addOrRemoveSegment=function(e,i,r){for(var s,o,a=[],l={segments:e.segments},h=0;h0?"Bottom":"Top":r>0?"Right":"Left",length:i.points[0].x===i.points[1].x?s:r},!0)),l.push(new bi(e,"segments",{type:"Orthogonal",direction:c,length:h/2},!0));var p={element:e,addSegments:l,type:"Addition",cancel:!1};return this.commandHandler.triggerEvent(Ce.segmentCollectionChange,p),p.cancel||(e.segments=l.concat(e.segments),a=o+2),a},t.prototype.insertFirstSegment=function(e,i,r,s,o){var a,l,d,u,h=[];if(e.sourcePortID&&i.length&&e.segments[0].points.length>2)for(var p=void 0,f=0;f0?"Bottom":"Top":r>0?"Right":"Left"),p=u,h.push(u)}else h.push(new bi(e,"segments",{type:"Orthogonal",direction:i.direction,length:i.length/3},!0)),"Bottom"===i.direction||"Top"===i.direction?(l=Math.abs(r),a=r>0?"Right":"Left"):(l=Math.abs(s),a=s>0?"Bottom":"Top"),u=new bi(e,"segments",{type:"Orthogonal",direction:a,length:l},!0),h.push(u);var y={element:e,addSegments:h,type:"Addition",cancel:!1};if(this.commandHandler.triggerEvent(Ce.segmentCollectionChange,y),!y.cancel){if(e.sourcePortID&&i.length&&e.segments[0].points.length>2)e.segments.splice(0,1),d=1;else{var S=e.segments[1];S&&S.length&&(S.length=a!==S.direction?S.length+l:S.length-l),d=2,i.length=2*i.length/3}e.segments=h.concat(e.segments)}return d},t.prototype.updateAdjacentSegments=function(e,i,r,s){var o=e.segments[parseInt(i.toString(),10)],a=o.points[o.points.length-1],h=!0;"Orthogonal"===o.type&&(o.points[0]=o.points[0],o.points[o.points.length-1]=a,e.segments[i-1]&&(h=this.updatePreviousSegment(r,s,e,i)),e.segments.length-1>i&&h&&this.updateNextSegment(e,o,e.segments[i+1],r,s))},t.prototype.addTerminalSegment=function(e,i,r,s,o){var l,h,c,d,a=e.segments.indexOf(i),u=[],p=e.segments.pop(),f=e.segments[e.segments.length-1];l=f&&"Orthogonal"===f.type?f:null;for(var g=0;g0&&"Left"===o.direction?c.middleLeft:c.middleRight,o.length>c.width/2?Math.abs(a.length)0&&"Top"===o.direction?c.topCenter:c.bottomCenter,o.length>c.height/2?Math.abs(a.length)1)for(var a=0,l=this.diagram.views;a0)for(var e=t===Ce.onUserHandleMouseLeave?this.previousAction:this.action,i={element:void 0},r=0;r0)for(var r={element:void 0},s=void 0,o=void 0,a=0;a-1&&(o=s,this.previousTarget=i,this.targetItem=e),o===e.fixedUserHandles[parseInt(a.toString(),10)].id&&(r.element=e.fixedUserHandles[parseInt(a.toString(),10)],this.userHandle(t,a,r,e))},n.prototype.mouseDown=function(t){if(!0!==this.inAction||!(this.tool instanceof VI||this.tool instanceof pa)){this.focus=!0;var e=t.touches,i=!!document.getElementsByClassName("e-dragclone")[0];if(this.isMouseOnScrollBar(t)&&!i)return this.isScrolling=!0,void t.preventDefault();if(this.checkFixedUserHandleEvent(Ce.onFixedUserHandleMouseDown,this.targetItem,this.previousTarget),this.checkUserHandleEvent(Ce.onUserHandleMouseDown),!this.checkEditBoxAsTarget(t)&&jv(this.diagram)||Lc(this.diagram)&&!PI(this.diagram))if(("Select"===this.action||"Drag"===this.action)&&this.diagram.updatePortVisibility(this.hoverElement,ri.Hover,!0),!(this.tool instanceof Oh||this.tool instanceof kh)||2!==t.button&&2!==t.buttons)if(!0===this.inAction&&!0===this.isMouseDown&&(this.tool instanceof Oh||this.tool instanceof kh))this.isMouseDown=!0,this.eventArgs={},this.getMouseEventArgs(this.currentPosition,this.eventArgs),this.eventArgs.position=this.currentPosition,this.tool.mouseDown(this.eventArgs);else{this.isMouseDown=!0,this.currentPosition=this.prevPosition=this.getMousePosition(t),this.eventArgs={},this.diagram.textEditing&&!this.isMouseOnScrollBar(t)&&(this.diagram.endEdit(),this.diagram.textEditing=!1,"Canvas"===this.diagram.mode&&1!==this.diagram.scroller.currentZoom&&this.diagram.refreshDiagramLayer());var s=this.getTargetElement();this.action=this.diagram.findActionToBeDone(s.obj,s.sourceElement,this.currentPosition,s.target);var o=this.isMetaKey(t);o&&t.shiftKey&&this.diagram.connectorEditingToolModule?this.action="SegmentEnd":(o||t.shiftKey)&&(_v(this.diagram)||Uv(this.diagram))&&(this.action="Select"),this.tool=this.diagram.getTool(this.action),this.tool||(this.action="Select",this.tool=this.diagram.getTool(this.action)),this.getMouseEventArgs(this.currentPosition,this.eventArgs),(o||t.shiftKey)&&(this.eventArgs.info=o&&t.shiftKey?{ctrlKey:o,shiftKey:t.shiftKey}:{ctrlKey:!0}),this.eventArgs.position=this.currentPosition;var l=this.diagram.selectedItems.nodes;if(this.tool.mouseDown(this.eventArgs),this.diagram.selectedItems.canToggleSelection&&l&&this.diagram.selectedItems.nodes&&this.tool instanceof ua)for(var h=0;h=2&&(this.touchStartList=HF(this.touchStartList,0,e)),e||t.preventDefault())}else this.inAction=!1,this.tool.mouseUp(this.eventArgs);!this.isForeignObject(t.target)&&!this.isForeignObject(t.target,!0)&&!e&&t.preventDefault()}},n.prototype.mouseMoveExtend=function(t,e){(this.tool instanceof Oh||this.tool instanceof kh)&&this.tool.mouseMove(this.eventArgs),this.diagram.scrollSettings.canAutoScroll?this.checkAutoScroll(t):this.blocked||this.tool.mouseMove(this.eventArgs),this.eventArgs.target&&(this.hoverElement=this.eventArgs.target);var i=!((this.eventArgs.target instanceof te||this.eventArgs.target instanceof de)&&(e instanceof te||e instanceof de));this.tool instanceof Od&&this.diagram.updatePortVisibility(this.hoverElement instanceof te||this.hoverElement instanceof de?this.hoverElement:this.hoverNode,ri.Connect|ri.Hover,i),this.hoverElement instanceof te&&this.hoverNode instanceof te&&this.hoverNode&&this.hoverNode.id!==this.hoverElement.id&&this.diagram.updatePortVisibility(this.hoverNode,ri.Connect|ri.Hover,!0),this.hoverElement instanceof de&&this.hoverElement.ports.length>0&&this.diagram.updatePortVisibility(this.hoverElement,ri.Connect|ri.Hover,!0),this.previousElement instanceof te&&this.hoverElement&&this.previousElement.id!==this.hoverElement.id&&this.diagram.updatePortVisibility(this.previousElement,ri.Connect|ri.Hover,!0),this.previousElement=this.hoverElement,""!==this.diagram.tooltip.content&&(this.hoverElement=null),this.hoverNode=i?null:e},n.prototype.checkAction=function(t){if("LabelSelect"===this.action&&this.eventArgs.sourceWrapper&&(this.eventArgs.sourceWrapper instanceof si||this.eventArgs.sourceWrapper instanceof Jn)){var e=this.commandHandler.findTarget(this.eventArgs.sourceWrapper,this.eventArgs.source);!_r(this.diagram,e,!1,this.eventArgs.sourceWrapper)&&to(e)&&(this.action="LabelDrag",this.tool=this.getTool(this.action),this.tool.mouseDown(this.initialEventArgs))}else to(t)&&Dd(t)&&this.initialEventArgs&&this.initialEventArgs.source&&"Select"===this.action&&(!_r(this.diagram,this.eventArgs.source,!1)&&this.eventArgs.source instanceof oi&&this.getMouseEventArgs(this.currentPosition,this.eventArgs),(!(t instanceof de)||t instanceof de&&!(wr(this.currentPosition,t.sourcePoint,t.hitPadding)||wr(this.currentPosition,t.targetPoint,t.hitPadding)))&&(this.action="Drag"),this.tool=this.getTool(this.action),this.tool.mouseDown(this.initialEventArgs))},n.prototype.isSwimlaneElements=function(t){return!(t&&(t.isLane||t.isPhase||t.isHeader))},n.prototype.mouseMove=function(t,e){if(this.focus=!0,this.isScrolling)t.preventDefault();else if(jv(this.diagram)||Lc(this.diagram)&&!PI(this.diagram)){this.currentPosition=this.getMousePosition(t);var i=this.diagram.findObjectsUnderMouse(this.currentPosition),r=this.diagram.findObjectUnderMouse(i,this.action,this.inAction);!function Gne(n,t){n.rulerSettings.showRulers&&(n.hRuler.drawRulerMarker(n.hRuler.element,t,n.scroller.horizontalOffset),n.vRuler.drawRulerMarker(n.vRuler.element,t,n.scroller.verticalOffset))}(this.diagram,this.currentPosition);var s=!1,o=void 0;if("touchmove"===t.type&&(e=t.touches)&&e.length>1&&(this.touchMoveList=HF(this.touchMoveList,0,e),"PinchZoom"!==this.action&&(s=!0)),!1===z.equals(this.currentPosition,this.prevPosition)||this.inAction){if(!1===this.isMouseDown||s){this.eventArgs={};var a=null,l=void 0;if(null!==r){if((a=this.diagram.findElementUnderMouse(r,this.currentPosition,this.diagram))&&(l=this.commandHandler.findTarget(a,r)),(l instanceof Zn||l instanceof Nr)&&(l.tooltip&&""!==l.tooltip.content||(l=r)),l!==this.hoverElement){var h=this.getContent();this.hoverElement&&"Auto"===this.hoverElement.tooltip.openOn&&""!==h&&this.elementLeave(),this.diagram.updatePortVisibility(this.hoverElement,ri.Hover,!0),r instanceof te&&(this.hoverNode=r);var c=!0;!this.isSwimlaneElements(r)&&this.hoverElement&&this.isSwimlaneElements(this.hoverElement)&&(c=!1),this.hoverElement=c?r:this.hoverElement;var d,u=void 0;(d=this.diagram.findElementUnderMouse(r,this.currentPosition,this.diagram))instanceof Ke&&((u=this.commandHandler.findTarget(d,r))instanceof Es||u instanceof xc)&&this.hoverElement.constraints&ni.ToolTip&&(this.hoverElement=u);var p=void 0;d instanceof si&&((p=this.commandHandler.findTarget(d,r))instanceof Zn||p instanceof Nr)&&p.constraints&Lr.Tooltip&&(this.hoverElement=p),c?this.elementEnter(this.currentPosition,!1):this.hoverElement=r}else this.hoverElement&&this.hoverElement===l&&this.hoverElement.tooltip.content&&void 0!==this.diagram.tooltipObject&&"Mouse"===this.hoverElement.tooltip.relativeMode&&this.setTooltipOffset(this.currentPosition);a&&(o=this.commandHandler.findTarget(a,r))}this.action=this.diagram.findActionToBeDone(r,a,this.currentPosition,o),this.checkFixedUserHandleEvent(Ce.onFixedUserHandleMouseEnter,r,a),this.checkUserHandleEvent(Ce.onUserHandleMouseEnter),this.checkPreviousAction(),this.getMouseEventArgs(this.currentPosition,this.eventArgs),this.tool=this.getTool(this.action),this.mouseEvents(),this.tool instanceof pa||this.tool instanceof kh||this.tool instanceof Oh?this.tool.mouseMove(this.eventArgs):e&&this.tool instanceof Jv&&this.tool.mouseDown(this.eventArgs),this.updateCursor(),this.renderUmlHighLighter(this.eventArgs);var f=!1;this.hoverElement&&!(this.tool instanceof Jv)&&r instanceof te&&this.isSwimlaneElements(r)&&(0===this.diagram.selectedItems.nodes.length||!_r(this.diagram,this.hoverElement))||this.hoverElement instanceof de||(f=!0),this.hoverElement&&!(this.tool instanceof Jv)&&r instanceof de&&(0===this.diagram.selectedItems.connectors.length||!_r(this.diagram,this.hoverElement))||this.hoverElement instanceof te||(f=!0),this.diagram.updatePortVisibility(this.hoverElement,ri.Hover,f);var g=this.getContent();null===r&&this.hoverElement&&"Auto"===this.hoverElement.tooltip.openOn&&g&&(this.hoverElement=null,this.elementLeave()),s=!1}else{this.eventArgs.position=this.currentPosition,"Drag"===this.action&&!_r(this.diagram,this.eventArgs.source,!1)&&this.eventArgs.source instanceof oi&&this.getMouseEventArgs(this.currentPosition,this.eventArgs),this.mouseEvents(),(t.ctrlKey||t.shiftKey)&&(this.eventArgs.info=t.ctrlKey&&t.shiftKey?{ctrlKey:t.ctrlKey,shiftKey:t.shiftKey}:{ctrlKey:!0}),this.checkAction(r);var y=this.getConnectorPadding(this.eventArgs);this.getMouseEventArgs(this.currentPosition,this.eventArgs,this.eventArgs.source,y),this.updateCursor(),this.inAction=!0,this.initialEventArgs=null,("Drag"===this.action||"Rotate"===this.action)&&(this.diagram.diagramActions=this.diagram.diagramActions|ee.Interactions);var S=this.diagram.scroller.getPageBounds();this.mouseMoveExtend(t,r);var b=this.diagram.scroller.getPageBounds();if(r&&(S.width!==b.width||S.height!==b.height||S.x!==b.x||S.y!==b.y)&&this.diagram.views&&this.diagram.views.overview){var M=this.diagram.views.overview;M.updateView(M)}}this.prevPosition=this.currentPosition,this.isForeignObject(t.target,!0)||t.preventDefault()}}},n.prototype.getContent=function(){var i,t=this.hoverElement instanceof te&&this.hoverElement.constraints&ie.Tooltip||this.hoverElement instanceof de&&this.hoverElement.constraints&qe.Tooltip||(this.hoverElement instanceof Es||this.hoverElement instanceof xc)&&this.hoverElement.constraints&ni.ToolTip||(this.hoverElement instanceof Zn||this.hoverElement instanceof Nr)&&this.hoverElement.constraints&Lr.Tooltip,e=this.hoverElement;e instanceof te&&e.children&&e.children.length>0&&(i=this.findIntersectChild(e));var r=t?this.hoverElement.tooltip.content:this.diagram.tooltip.content;return i?i.tooltip.content:r},n.prototype.findIntersectChild=function(t){for(var e,i=new Ne(this.currentPosition.x,this.currentPosition.y,8,8),r=0;r1&&1===t.which&&!function qre(n){return!!(n&ee.PreventClearSelection)}(this.diagram.diagramActions)&&(c=!1,this.commandHandler.clearSelection()),(!_r(this.diagram,h)||!c)&&(this.commandHandler.selectObjects([h],void 0,a),this.diagram.selectedItems.canToggleSelection)){var d=this.diagram.selectedItems.nodes;d?d[0].parentObj instanceof Rd&&(s=!0):this.diagram.selectedItems.connectors.length>0&&(s=!0)}}var u=!1,p=this.updateContainerProperties(),f=void 0;if(this.addUmlNode(),this.inAction=!1,this.isMouseDown=!1,this.diagram.selectedObject.helperObject&&(f=this.updateContainerBounds()),this.tool&&(this.tool.prevPosition||this.tool instanceof X3)){this.eventArgs.position=this.currentPosition;var g=this.getConnectorPadding(this.eventArgs);this.getMouseEventArgs(this.currentPosition,this.eventArgs,this.eventArgs.source,g);var v=this.isMetaKey(t);if((v||t.shiftKey)&&(this.eventArgs.info=v&&t.shiftKey?{ctrlKey:v,shiftKey:t.shiftKey}:{ctrlKey:!0}),this.diagram.diagramActions&ee.Interactions&&(this.diagram.diagramActions=this.diagram.diagramActions&~ee.Interactions),this.eventArgs.clickCount=t.detail,this.diagram.selectedObject.helperObject&&(this.tool instanceof ua||this.tool instanceof kd)){if(this.diagram.selectedObject.actualObject&&""!==this.diagram.selectedObject.actualObject.parentId){var S=this.diagram.getObject(this.diagram.selectedObject.actualObject.parentId);S&&S.isLane&&(this.commandHandler.isContainer=!0)}(u=this.diagram.lineRoutingModule&&this.diagram.nameTable.helper&&this.eventArgs.target&&this.eventArgs.target.isLane&&(this.eventArgs.source instanceof oi&&this.eventArgs.source.nodes.length>0&&""===this.eventArgs.source.nodes[0].parentId||""===this.eventArgs.source.parentId))&&(this.diagram.diagramActions=this.diagram.diagramActions|ee.PreventLaneContainerUpdate),this.tool.mouseUp(this.eventArgs,p.isPreventHistory)}else{if(this.diagram.selectedItems.canToggleSelection){var b=void 0,M=void 0;if(this.diagram.selectedItems.nodes.length>0)for(var w=0;w1&&D[0].id===i[parseInt(w.toString(),10)].id||r.length>0)&&(M=!0);!this.isSwimlaneSelected&&!s&&!M&&this.tool instanceof ua&&"Select"===this.currentAction&&(!b||this.diagram.selectedItems.connectors.length>0)&&this.commandHandler.clearSelection(!0)}this.isSwimlaneSelected=!1,this.tool.mouseUp(this.eventArgs),this.diagram.checkMenu&&(-1!==window.navigator.userAgent.indexOf("Linux")||-1!==window.navigator.userAgent.indexOf("X11"))&&(!t.pageY&&t instanceof TouchEvent&&t.changedTouches?(window.getSelection().removeAllRanges(),this.diagram.contextMenuModule.contextMenu.open(t.changedTouches[0].pageY,t.changedTouches[0].pageX,this.diagram.element),t.preventDefault()):this.diagram.contextMenuModule.contextMenu.open(t.pageY,t.pageX,this.diagram.element),this.diagram.checkMenu=!1)}p.hasStack&&this.diagram.endGroupAction()}if(f&&this.diagram.endGroupAction(),this.updateContainerBounds(!0),2!==this.eventArgs.clickCount&&(this.commandHandler.updateSelectedNodeProperties(this.eventArgs.source),u)){this.diagram.diagramActions=this.diagram.diagramActions&~ee.PreventLaneContainerUpdate;var A=this.eventArgs.source instanceof oi?this.eventArgs.source.nodes:[this.eventArgs.source];if(A)for(w=0;w0&&!N&&this.diagram.renderSelector(!0),!this.inAction&&!this.diagram.currentSymbol&&this.eventArgs){var T=this.getTargetElement();this.diagram.tool!==Ci.ZoomPan&&this.diagram.triggerEvent(Ce.click,{element:T.target instanceof Es?T.target:this.eventArgs.source||this.diagram,position:this.eventArgs.position,count:t.detail,actualObject:this.eventArgs.actualObject,button:0===t.button?"Left":1===t.button?"Middle":"Right"})}this.eventArgs={}}this.diagram.diagramActions=this.diagram.diagramActions&~ee.PreventLaneContainerUpdate,e&&this.updateAnnotation(this.diagram.selectedItems),this.eventArgs={},this.diagram.commandHandler.removeStackHighlighter()},n.prototype.isSwimlaneChild=function(t){if(t.shape&&"SwimLane"!==t.shape.type){var e=this.diagram.nameTable[t.parentId];if(!e)return!1;var i=e.parentId?this.diagram.nameTable[e.parentId]:e;return i&&i.shape&&"SwimLane"===i.shape.type}return!1},n.prototype.updateAnnotation=function(t){var e=t.nodes;if(e.length>0)for(var i=0;i0&&(a+=1),h.isPhase){l="Horizontal"===r.orientation?this.currentPosition.x-e.wrapper.bounds.x:this.currentPosition.y-(e.wrapper.bounds.y+r.header.height);var g={id:Qe(),offset:l,header:{annotation:{content:void 0===h.phases[0].header?"Phase":h.phases[0].header.annotation.content,style:void 0===h.phases[0].header?{}:h.phases[0].header.annotation.style}},style:void 0===h.phases[0]?{}:h.phases[0].style};this.diagram.addPhases(e,[g])}else{var v={id:Qe(),style:h.lanes[0].style,header:{annotation:{content:h.lanes[0].header.annotation.content,style:h.lanes[0].header.annotation.style},style:h.lanes[0].header.style}};if("Horizontal"===h.orientation?v.height=h.lanes[0].height:v.width=h.lanes[0].width,"Horizontal"===r.orientation?(s=i.rowIndex?i.rowIndex:this.diagram.nameTable[i.parentId].rowIndex,i.wrapper.offsetYs)v.header.width=r.lanes[parseInt(s.toString(),10)].header.width,v.header.height=r.lanes[parseInt(s.toString(),10)].header.height;else{var S=void 0;S="Horizontal"===r.orientation?i.rowIndex<3?0:s-a-1:s-1,v.header.width=r.lanes[parseInt(S.toString(),10)].header.width,v.header.height=r.lanes[parseInt(S.toString(),10)].header.height}f&&("height"===f?(v.width=v.height,delete v.height):(v.height=v.width,delete v.width)),this.diagram.addLanes(e,[v],"Horizontal"===r.orientation?s-a:s)}this.commandHandler.select(e)}else if(h.isLane){var b={id:Qe(),width:t.width,height:t.height,addInfo:t.addInfo,shape:{type:"SwimLane",header:{annotation:{content:void 0===h.header?"Header":h.header.annotation.content,style:void 0===h.header?{}:h.header.annotation.style},height:50,style:h.header?h.header.style:h.lanes[0].header.style},phases:[{id:Qe(),header:{annotation:{content:void 0===h.phases||void 0===h.phases[0].header?"Phase":h.phases[0].header.annotation.content,style:void 0===h.phases||void 0===h.phases[0].header?{}:h.phases[0].header.annotation.style},style:void 0===h.phases||void 0===h.phases[0].header?{}:h.phases[0].header.style},style:void 0===h.phases?{}:h.phases[0].style}],lanes:[{id:Qe(),height:t.height,width:t.width,style:h.lanes[0].style,header:{annotation:{content:h.lanes[0].header.annotation.content,style:h.lanes[0].header.annotation.style},style:h.lanes[0].header.style}}],orientation:h.orientation}};"Vertical"===h.orientation&&(b.width+=20),b.offsetX=this.currentPosition.x+b.width/2,b.offsetY=this.currentPosition.y+b.height/2,b.style=t.style,this.diagram.add(b)}},n.prototype.mouseLeave=function(t){this.tool&&this.inAction&&this.tool.mouseLeave(this.eventArgs),this.diagram.selectedObject.helperObject&&(this.updateContainerProperties(),this.updateContainerBounds()&&this.diagram.endGroupAction()),this.eventArgs&&this.eventArgs.source&&(this.diagram.updatePortVisibility(this.eventArgs.source,ri.Hover,!0),this.hoverElement=null),this.eventArgs&&!this.eventArgs.source&&this.hoverElement&&(this.hoverElement=null),this.tool instanceof Od&&this.eventArgs&&this.eventArgs.target&&this.eventArgs.target instanceof te&&(this.diagram.updatePortVisibility(this.eventArgs.target,ri.Hover|ri.Connect,!0),this.hoverElement=null);var i=this.diagram.selectedItems;i&&i.wrapper&&(om(this.diagram,i)||this.diagram.renderSelector(!0)),(this.diagram.diagramActions&ee.Interactions||this.diagram.diagramActions&ee.ToolAction)&&(this.diagram.diagramActions=this.diagram.diagramActions&~ee.ToolAction),this.isMouseDown=!1,this.focus=!1,this.touchStartList=null,this.touchMoveList=null,this.elementLeave(),this.commandHandler.removeSnap(),this.inAction=!1,this.eventArgs={},this.diagram.selectedObject&&this.diagram.selectedObject.helperObject&&(this.diagram.remove(this.diagram.selectedObject.helperObject),this.diagram.selectedObject={helperObject:void 0,actualObject:void 0}),this.tool=null,function Qne(){var t,e,n=document.getElementsByClassName("e-d-ruler-marker");if(n&&n.length>0)for(e=n.length-1;e>=0;e--)(t=n[parseInt(e.toString(),10)])&&t.parentNode.removeChild(t)}(),"Rotate"===this.action&&this.diagram.diagramCanvas.classList.remove("e-diagram-rotate"),t.preventDefault()},n.prototype.mouseWheel=function(t){this.diagram.blazorActions|=on.interaction;var e={event:t,cancel:!1};if(this.diagram.triggerEvent(Ce.mouseWheel,e),!e.cancel){var i=t.wheelDelta>0||-40*t.detail>0,r=this.getMousePosition(t);if(this.diagram.tooltipObject.close(),this.isMetaKey(t)){var o=this.diagram.scrollSettings.zoomFactor;this.diagram.zoomTo(i?{type:"ZoomIn",zoomFactor:o,focusPoint:r}:{type:"ZoomOut",zoomFactor:o,focusPoint:r}),t.preventDefault()}else{var a=this.diagram.scroller.horizontalOffset,l=this.diagram.scroller.verticalOffset,h=i?10:-10;this.tool&&(this.tool instanceof Oh||this.tool instanceof kh)&&(this.eventArgs={},this.getMouseEventArgs(r,this.eventArgs),this.eventArgs.position=r,this.tool.mouseWheel(this.eventArgs)),this.diagram.scrollActions|=ca.Interaction;var c=!0;if(t.isTrusted){var d=!1;(Math.abs(t.deltaY)<100&&-0===Math.abs(t.deltaX)||Math.abs(t.deltaX)<100&&-0===Math.abs(t.deltaY))&&(d=!0);var u=!1;(0!==t.deltaX||0!==t.deltaY)&&(u=navigator.userAgent.includes("Macintosh")),u?Math.abs(t.deltaX)>Math.abs(t.deltaY)?(t.shiftKey||t.deltaX&&-0!==t.deltaX&&(d||!u))&&this.diagram.scroller.zoom(1,h,0,r,c,void 0,d):t.deltaY&&-0!==t.deltaY&&(d||!u)&&this.diagram.scroller.zoom(1,0,h,r,c,void 0,d):t.shiftKey||t.deltaX&&-0!==t.deltaX&&(d||!u)?this.diagram.scroller.zoom(1,h,0,r,c,void 0,d):t.deltaY&&-0!==t.deltaY&&(d||!u)&&this.diagram.scroller.zoom(1,0,h,r,c,void 0,d)}else t.shiftKey||t.deltaX&&-0!==t.deltaX?this.diagram.scroller.zoom(1,h,0,r,c):this.diagram.scroller.zoom(1,0,h,r,c);this.diagram.scrollActions&=~ca.Interaction,(a!==this.diagram.scroller.horizontalOffset||l!==this.diagram.scroller.verticalOffset)&&t.preventDefault()}if(this.diagram.textEditing){if(this.diagram.isTriggerEvent=!0,this.diagram.activeLabel.parentId){var f=this.diagram.getObject(this.diagram.activeLabel.parentId);this.diagram.startTextEdit(f,this.diagram.activeLabel.id)}this.diagram.isTriggerEvent=!1}this.diagram.blazorActions=this.diagram.blazorActions&~on.interaction}},n.prototype.keyDown=function(t){if(t.fromMouseEvents&&(t.ctrlKey&&(this.keyArgs.keyModifiers=1),t.shiftKey&&(this.keyArgs.keyModifiers=4),t.shiftKey&&t.ctrlKey&&(this.keyArgs.keyModifiers=5)),!(this.diagram.diagramActions&ee.TextEdit)&&!this.checkEditBoxAsTarget(t)||"Escape"===t.key||27===t.keyCode){var i=void 0,r=t.keyCode?t.keyCode:t.which,s=t.key;("ArrowDown"===s||"ArrowUp"===s||"ArrowLeft"===s||"ArrowRight"===s)&&(this.isNudgeKey=!0);var o=this.isMetaKey(t);if(this.diagram.commandManager&&this.diagram.commands)for(var l=0,h=Object.keys(this.diagram.commands);l4&&(S({keyDownEventArgs:KeyboardEvent,parameter:i.parameter,type:"KEYDOWN"}),this.keyCount=0)),this.isKeyUp=!1):S({keyDownEventArgs:KeyboardEvent,parameter:i.parameter})}break}}}}this.keyArgs={element:this.diagram.selectedItems,key:t.key,keyCode:t.keyCode?t.keyCode:t.which},this.getKeyModifier(this.keyArgs,t),this.diagram.diagramActions&ee.TextEdit&&this.getlabel(this.keyArgs,t),this.diagram.triggerEvent(Ce.keyDown,this.keyArgs)},n.prototype.getlabel=function(t,e){var i=this.diagram.activeLabel;t.target=this.diagram.element.id+"_editBox";var r=this.diagram.nameTable[i.parentId];if(document.getElementById(this.diagram.element.id+"_editBox")){t.text=document.getElementById(this.diagram.element.id+"_editBox").value;for(var s=0;s=this.diagram.scroller.viewPortWidth-18?r="right":e.x+this.diagram.scroller.horizontalOffsetthis.diagram.scroller.viewPortHeight-18?r="bottom":e.y+this.diagram.scroller.verticalOffset0&&(s=this.findIntersectChild(this.hoverElement)),"Auto"===this.hoverElement.tooltip.openOn&&""!==r&&Mx(this.diagram,s||(i?this.hoverElement:void 0)),this.hoverElement.tooltip.content&&("Mouse"===this.hoverElement.tooltip.relativeMode?this.setTooltipOffset(t):(this.diagram.tooltipObject.offsetX=0,this.diagram.tooltipObject.offsetY=0));var o=this.diagram.findObjectsUnderMouse(this.currentPosition),a=this.diagram.findObjectUnderMouse(o,this.action,this.inAction);if(null!==a){var l=void 0;this.hoverElement.tooltip.isSticky&&(this.diagram.tooltipObject.isSticky=!0),a instanceof te&&a.children&&a.children.length>0&&(a=s||a),l=a.ports&&(this.hoverElement instanceof Es||this.hoverElement instanceof xc)||a.annotations&&(this.hoverElement instanceof Zn||this.hoverElement instanceof Nr)?document.getElementById(a.id+"_"+this.hoverElement.id):document.getElementById(a.id+(a.shape&&a.shape instanceof am?"_content_native_element":"_groupElement")),"Auto"===this.hoverElement.tooltip.openOn&&""!==r&&(this.diagram.tooltipObject.close(),this.diagram.tooltipObject.openOn=this.hoverElement.tooltip.openOn,this.diagram.tooltipObject.dataBind()),function jre(n,t){var e=0;return n instanceof de?n.constraints&qe.Tooltip?e=n.constraints&qe.Tooltip:n.constraints&qe.InheritTooltip&&(e=t.constraints&rt.Tooltip):n instanceof Es||n instanceof xc?n.constraints&ni.ToolTip?e=n.constraints&ni.ToolTip:n.constraints&ni.InheritTooltip&&(e=t.constraints&rt.Tooltip):n instanceof Zn||n instanceof Nr?n.constraints&Lr.Tooltip&&(e=n.constraints&Lr.Tooltip):n.constraints&ie.Tooltip?e=n.constraints&ie.Tooltip:n.constraints&ie.InheritTooltip&&(e=t.constraints&rt.Tooltip),e}(this.hoverElement,this.diagram)&&"Auto"===this.hoverElement.tooltip.openOn&&(this.diagram.tooltipObject.target=this.hoverElement.id,this.diagram.tooltipObject.open("Mouse"===this.hoverElement.tooltip.relativeMode?this.diagram.element:l))}}},n.prototype.elementLeave=function(){this.diagram.tooltipObject&&!this.diagram.tooltipObject.isSticky&&"Custom"!==this.diagram.tooltipObject.openOn&&this.diagram.tooltipObject.close()},n.prototype.setTooltipOffset=function(t){var e=function dse(n,t,e,i){var o="Mouse"===(!(e instanceof te?e.constraints&ie.InheritTooltip:e instanceof de?e.constraints&qe.InheritTooltip:e.constraints&ni.InheritTooltip)&&(e instanceof te?e.constraints&ie.Tooltip:e instanceof de?e.constraints&qe.Tooltip:e.constraints&ni.ToolTip)?e.tooltip.relativeMode:n.tooltip.relativeMode);"Mouse"===i?o=!0:"Object"===i&&(o=!1);var a=function use(n,t,e,i){var o,r={},s=document.getElementById(e.element.id);if(n instanceof te||n instanceof de)o=n.wrapper.bounds;else{var a=e.findObjectsUnderMouse(t),l=e.findObjectUnderMouse(a,"Select",!1);o=e.findElementUnderMouse(l,t,e).bounds}var c=s.getBoundingClientRect();switch(e.tooltipObject.position){case"BottomCenter":r=zc(t,o.bottomCenter,e,i,c.width/2,c.height);break;case"BottomLeft":case"LeftBottom":r=zc(t,o.bottomLeft,e,i,0,c.height);break;case"BottomRight":case"RightBottom":r=zc(t,o.bottomRight,e,i,c.width,c.height);break;case"LeftCenter":r=zc(t,o.middleLeft,e,i,0,c.height/2);break;case"LeftTop":case"TopLeft":r=zc(t,o.topLeft,e,i,0,0);break;case"RightCenter":r=zc(t,o.middleRight,e,i,c.width,c.height/2);break;case"RightTop":case"TopRight":r=zc(t,o.topRight,e,i,c.width,0);break;case"TopCenter":r=zc(t,o.topCenter,e,i,c.width/2,0)}return r}(e,t,n,o),l=qa(n);return{x:a.x+l.width,y:a.y+l.height}}(this.diagram,t,this.hoverElement);this.diagram.tooltipObject.offsetX=e.x,this.diagram.tooltipObject.offsetY=e.y},n.prototype.altKeyPressed=function(t){return!!(t&pt.Alt)},n.prototype.ctrlKeyPressed=function(t){return!!(t&pt.Control)},n.prototype.shiftKeyPressed=function(t){return!!(t&pt.Shift)},n.prototype.scrolled=function(t){this.diagram.updateScrollOffset()},n.prototype.doubleClick=function(t){if(jv(this.diagram)){var e=void 0,i=this.diagram.findObjectsUnderMouse(this.currentPosition),r=this.diagram.findObjectUnderMouse(i,this.action,this.inAction);if(null!==r&&jv(this.diagram))if(e=this.diagram.findElementUnderMouse(r,this.currentPosition,this.diagram),this.tool&&(this.tool instanceof Oh||this.tool instanceof kh))this.tool.mouseUp(this.eventArgs),this.isMouseDown=!1,this.eventArgs={},this.tool=null,t.preventDefault();else{var o=this.diagram.commandHandler.getObjectLayer(r.id);!o||o.lock||!o.visible||this.diagram.diagramActions&ee.TextEdit||this.diagram.startTextEdit(r,e instanceof si?e.id.split(r.id+"_")[1]:void 0)}this.diagram.triggerEvent(Ce.doubleClick,{source:r||this.diagram,position:this.currentPosition,count:t.detail})}},n.prototype.itemClick=function(t,e){var i=t;return cs(this.diagram,i,!0)?i:null},n.prototype.inputChange=function(t){var i,s,o,a,l,h,c,d,u,p=document.getElementById(this.diagram.element.id+"_editBox"),f=document.getElementById(this.diagram.element.id+"_editTextBoxDiv"),g=p.value,v=g.split("\n");(!(a=this.diagram.selectedItems.nodes[0]?this.diagram.selectedItems.nodes[0]:this.diagram.selectedItems.connectors[0])&&this.tool instanceof WI||a&&"SwimLane"===a.shape.type)&&(a=this.diagram.nameTable[this.diagram.activeLabel.parentId]),a&&("Text"!==a.shape.type&&a.annotations.length>0||"Text"===a.shape.type)&&(c=NF((o=this.diagram.getWrapper(a.wrapper,this.diagram.activeLabel.id)).style,g,void 0,void 0,i=(i=a.wrapper.bounds.width90?i:90),s=Number(p.style.fontSize.split("px")[0]),v.length>1&&""===v[v.length-1]&&(c.height=c.height+s),d=this.diagram.scroller.transform,u=T3(this.diagram)?d.scale:1,l=(12>c.height?12:c.height)*u,f.style.left=(o.bounds.center.x+d.tx)*d.scale-(h=(90>(h=c.width)?90:h)*u)/2-2.5+"px",f.style.top=(o.bounds.center.y+d.ty)*d.scale-l/2-3+"px",f.style.width=h+"px",f.style.height=l+"px",p.style.minHeight="12px",p.style.minWidth="90px",p.style.width=h+"px",p.style.height=l+"px")},n.prototype.isAddTextNode=function(t,e){return!(!(this.tool instanceof WI||e)||(this.tool=null,t&&!kI(this.diagram)&&(this.diagram.drawingObject=void 0,this.diagram.currentDrawingObject=void 0),vF(this.diagram.nodes,t.id)||vF(this.diagram.connectors,t.id)))},n.prototype.checkEditBoxAsTarget=function(t){return!(!t.target||t.target.id!==this.diagram.element.id+"_editBox")},n.prototype.getMouseEventArgs=function(t,e,i,r){var s,o,a;if(e.position=t,i?(o=this.diagram.findObjectsUnderMouse(this.currentPosition,i),s=this.diagram.findTargetObjectUnderMouse(o,this.action,this.inAction,e.position,i)):"Drag"===this.action||"ConnectorSourceEnd"===this.action||"SegmentEnd"===this.action||"OrthoThumb"===this.action||"BezierSourceThumb"===this.action||"BezierTargetThumb"===this.action||"ConnectorTargetEnd"===this.action||-1!==this.action.indexOf("Rotate")||-1!==this.action.indexOf("Resize")?(s=this.diagram.selectedItems,!this.diagram.currentSymbol&&"Drag"===this.action&&s&&this.diagram.selectedItems.nodes.length>0&&"SwimLane"===this.diagram.selectedItems.nodes[0].shape.type&&(o=this.diagram.findObjectsUnderMouse(this.currentPosition),s=this.diagram.findObjectUnderMouse(o,this.action,this.inAction))):(o=this.diagram.findObjectsUnderMouse(this.currentPosition),s=this.diagram.findObjectUnderMouse(o,this.action,this.inAction)),s&&s.isHeader&&(this.eventArgs.actualObject=s=this.diagram.nameTable[s.parentId]),s){var l=void 0,h=void 0,c=void 0;if(((a=this.diagram.findElementUnderMouse(s,this.currentPosition,this.diagram,r))&&s.ports&&s.ports.length&&!ib(s,a)||!a||!s)&&o&&o.length&&i instanceof oi)for(l=i.connectors[0],c=o.length-1;c>=0;c--)if(((h=o[parseInt(c.toString(),10)])instanceof te||h instanceof de)&&l&&l.connectionPadding){if(a=this.diagram.findElementUnderMouse(s=h,this.currentPosition,this.diagram,r),l.constraints&qe.ConnectToNearByPort&&s&&s.ports&&s.ports.length&&ib(s,a))break;if((h instanceof te||h instanceof de)&&l&&l.connectionPadding&&h.wrapper.outerBounds.containsPoint(this.currentPosition)&&l.constraints&qe.ConnectToNearByNode&&!(l.constraints&qe.ConnectToNearByPort)){a=this.diagram.findElementUnderMouse(s=h,this.currentPosition,this.diagram,0);break}}}return i?(e.target=s,e.targetWrapper=a):(e.source=s,e.sourceWrapper=a),e.actualObject=this.eventArgs.actualObject,e.source instanceof oi&&void 0===e.actualObject&&(e.source.nodes.length>0||e.source.connectors.length>0)&&(e.actualObject=e.source.nodes.length>0?this.diagram.nameTable[e.source.nodes[0].id]:this.diagram.nameTable[e.source.connectors[0].id]),e.startTouches=this.touchStartList,e.moveTouches=this.touchMoveList,e},n.prototype.resetTool=function(){this.action="Select",this.hoverElement=null,this.hoverNode=null,this.tool=this.diagram.getTool(this.action),this.updateCursor()},n.prototype.updateTool=function(){this.eventArgs&&!this.eventArgs.position&&(this.action="Select")},n.prototype.getTool=function(t){switch(t){case"Select":return new Zv(this.commandHandler,!0);case"Drag":return new ua(this.commandHandler);case"Rotate":return new Yx(this.commandHandler);case"LayoutAnimation":return new Lne(this.commandHandler);case"FixedUserHandle":return new Ane(this.commandHandler,!0);case"Hyperlink":return new X3(this.commandHandler);case"ResizeSouthEast":case"ResizeSouthWest":case"ResizeNorthEast":case"ResizeNorthWest":case"ResizeSouth":case"ResizeNorth":case"ResizeWest":case"ResizeEast":return new kd(this.commandHandler,t);case"ConnectorSourceEnd":case"ConnectorTargetEnd":case"BezierSourceThumb":case"BezierTargetThumb":return new Od(this.commandHandler,t);case"SegmentEnd":case"OrthoThumb":return new ZF(this.commandHandler,t);case"Draw":var e="shape",i=function nse(n){var t;return n&&(n.type?t="Connector":n.shape&&!n.type&&(t="Node")),t}(this.diagram.drawingObject);if("Node"===i&&"Text"===this.diagram.drawingObject.shape.type)return new WI(this.commandHandler);if("Connector"===i&&"Freehand"===this.diagram.drawingObject.type)return new Pne(this.commandHandler);if("Node"===i&&"Polygon"===this.diagram.drawingObject.shape[""+e]&&!this.diagram.drawingObject.shape.points)return new Oh(this.commandHandler);if("Node"===i||"Node"===i&&"Polygon"===this.diagram.drawingObject.shape[""+e]&&this.diagram.drawingObject.shape.points)return new VI(this.commandHandler,this.diagram.drawingObject);if("Connector"===i&&"Polyline"===this.diagram.drawingObject.type)return new kh(this.commandHandler);if("Connector"===i)return new pa(this.commandHandler,"ConnectorSourceEnd",this.diagram.drawingObject);break;case"Pan":return new Jv(this.commandHandler,!1);case"PinchZoom":return new Jv(this.commandHandler,!0);case"PortDrag":return new ua(this.commandHandler,"Port");case"PortDraw":return new pa(this.commandHandler,"ConnectorSourceEnd",this.diagram.drawingObject);case"LabelSelect":return new Zv(this.commandHandler,!0,"LabelSelect");case"LabelDrag":return new Nne(this.commandHandler);case"LabelResizeSouthEast":case"LabelResizeSouthWest":case"LabelResizeNorthEast":case"LabelResizeNorthWest":case"LabelResizeSouth":case"LabelResizeNorth":case"LabelResizeWest":case"LabelResizeEast":return new One(this.commandHandler,t);case"LabelRotate":return new kne(this.commandHandler)}return null},n.prototype.getCursor=function(t){var e=this.diagram.selectedItems.annotation?this.diagram.selectedItems.wrapper.children[0]:this.diagram.selectedItems;return function Tne(n,t){if(t+=360,t%=360,-1===n.indexOf("Resize"))return Wx[""+n];var e=Wx[""+n];return t>=0&&t<25||t>=160&&t<=205||t>=340&&t<=360?e:t>=25&&t<=70||t>=205&&t<=250?"n-resize"===e||"s-resize"===e?"ne-resize":"nw-resize"===e||"se-resize"===e?"n-resize":"e-resize"===e||"w-resize"===e?"nw-resize":"e-resize":t>=70&&t<=115||t>=250&&t<=295?"n-resize"===e||"s-resize"===e?"e-resize":"nw-resize"===e||"se-resize"===e?"ne-resize":"e-resize"===e||"w-resize"===e?"n-resize":"nw-resize":t>=115&&t<=155||t>=295&&t<=340?"n-resize"===e||"s-resize"===e?"nw-resize":"nw-resize"===e||"se-resize"===e?"e-resize":"e-resize"===e||"w-resize"===e?"ne-resize":Wx[""+n]:"n-resize"}(t,this.diagram.selectedItems.annotation?e.rotateAngle+e.parentTransform:e.rotateAngle)},n.prototype.findElementUnderMouse=function(t,e,i,r){return this.objectFinder.findElementUnderSelectedItem(t,e,i,r)},n.prototype.findObjectsUnderMouse=function(t,e){return this.objectFinder.findObjectsUnderMouse(t,this.diagram,this.eventArgs,e)},n.prototype.findObjectUnderMouse=function(t,e,i){return this.objectFinder.findObjectUnderMouse(this.diagram,t,e,i,this.eventArgs,this.currentPosition)},n.prototype.findTargetUnderMouse=function(t,e,i,r,s){return this.objectFinder.findObjectUnderMouse(this.diagram,t,e,i,this.eventArgs,r,s)},n.prototype.findActionToBeDone=function(t,e,i,r){return function Mne(n,t,e,i,r,s,o){if(s&&s.length>1&&r&&r.length>1)return"PinchZoom";if(i.currentSymbol)return"Drag";if("PortDraw"===i.eventHandler.action&&(i.tool&=~Ci.DrawOnce),(x3(i)||kI(i))&&i.drawingObject)return"Draw";if(Xa(i)&&(l=i.selectedItems).wrapper&&qr(l.constraints,"UserHandle"))for(var h=0,c=l.userHandles;h=50&&(l.x=(a.points[parseInt(h.toString(),10)].x+a.points[h+1].x)/2,l.y=(a.points[parseInt(h.toString(),10)].y+a.points[h+1].y)/2,wr(e,l,n.hitPadding?n.hitPadding:10)))return"OrthoThumb"}else AI(n)&&console.warn('[WARNING] :: Module "ConnectorEditing" is not available in Diagram component! You either misspelled the module name or forgot to load it.');return null}(g,l,e,i);if("OrthoThumb"===S)return S;if(qr(l.constraints,"ConnectorSourceThumb")&&xI(g)&&S||qr(l.constraints,"ConnectorTargetThumb")&&TI(g)&&S)return S}}else{var b=i.selectedItems.handleSize/2/i.scroller.currentZoom,M=10/i.scroller.currentZoom,w=Hi();qi(w,p.rotateAngle+p.parentTransform,p.offsetX,p.offsetY);var C=p.offsetX-p.pivot.x*p.actualSize.width,D=p.offsetY-p.pivot.y*p.actualSize.height,A={x:C+(.5===p.pivot.x?2*p.pivot.x:p.pivot.x)*p.actualSize.width/2,y:D-30/i.scroller.currentZoom};A=Je(w,A);var x=!!i.selectedItems.annotation,R=!(!x||!LI(i.selectedItems.annotation));if(qr(l.constraints,"Rotate")&&wr(e,A,M)&&i.selectedItems.thumbsConstraints&bt.Rotate){if(x&&R)return"LabelRotate";if(!x)return"Rotate"}if(u.Inflate(b),u.containsPoint(e)&&(S=function wne(n,t,e,i,r,s){var o;return 1===n.selectedItems.nodes.length&&0===n.selectedItems.connectors.length&&n.selectedItems.nodes[0].container&&(o=function Dne(n,t,e,i,r){var s=10/n.scroller.currentZoom,o=40/n.scroller.currentZoom,a=n.selectedItems,l=t.actualSize.width,h=t.actualSize.height,c=new Ne(i,r,t.style.strokeWidth,h),d=new Ne(i+l,r,t.style.strokeWidth,h),u=new Ne(i,r,l,t.style.strokeWidth),p=new Ne(i,r+h,l,t.style.strokeWidth),f=cs(n,n.selectedItems.nodes[0],!0)?n.nameTable[n.selectedItems.nodes[0].parentId]:n.selectedItems.nodes[0];if(l>=o&&h>=o){if(fa(a.constraints,"ResizeEast",a.thumbsConstraints,a)&&d.containsPoint(e,s))return"ResizeEast";if(fa(a.constraints,"ResizeSouth",a.thumbsConstraints,a)&&p.containsPoint(e,s))return"ResizeSouth";if("Grid"!==f.container.type){if(fa(a.constraints,"ResizeWest",a.thumbsConstraints,a)&&c.containsPoint(e,s))return"ResizeWest";if(fa(a.constraints,"ResizeNorth",a.thumbsConstraints,a)&&u.containsPoint(e,s))return"ResizeNorth"}}return null}(n,t,e,r,s)),!o&&(!n.selectedItems.nodes[0]||!n.selectedItems.nodes[0].isPhase&&!n.selectedItems.nodes[0].isLane&&"SwimLane"!==n.selectedItems.nodes[0].shape.type)&&(o=function xne(n,t,e,i,r,s){var o=40/n.scroller.currentZoom,a=n.selectedItems.handleSize/2/n.scroller.currentZoom,l=n.selectedItems,h=!!l.annotation;if(t.actualSize.width>=o&&t.actualSize.height>=o){if(fa(l.constraints,"ResizeSouthEast",l.thumbsConstraints,l)&&wr(e,Je(i,{x:r+t.actualSize.width,y:s+t.actualSize.height}),a))return h?"LabelResizeSouthEast":"ResizeSouthEast";if(fa(l.constraints,"ResizeSouthWest",l.thumbsConstraints,l)&&wr(e,Je(i,{x:r,y:s+t.actualSize.height}),a))return h?"LabelResizeSouthWest":"ResizeSouthWest";if(fa(l.constraints,"ResizeNorthEast",l.thumbsConstraints,l)&&wr(e,Je(i,{x:r+t.actualSize.width,y:s}),a))return h?"LabelResizeNorthEast":"ResizeNorthEast";if(fa(l.constraints,"ResizeNorthWest",l.thumbsConstraints,l)&&wr(e,Je(i,{x:r,y:s}),a))return h?"LabelResizeNorthWest":"ResizeNorthWest"}return fa(l.constraints,"ResizeEast",l.thumbsConstraints,l)&&wr(e,Je(i,{x:r+t.actualSize.width,y:s+t.actualSize.height/2}),a)?h?"LabelResizeEast":"ResizeEast":fa(l.constraints,"ResizeWest",l.thumbsConstraints,l)&&wr(e,Je(i,{x:r,y:s+t.actualSize.height/2}),a)?h?"LabelResizeWest":"ResizeWest":fa(l.constraints,"ResizeSouth",l.thumbsConstraints,l)&&wr(e,Je(i,{x:r+t.actualSize.width/2,y:s+t.actualSize.height}),a)?h?"LabelResizeSouth":"ResizeSouth":fa(l.constraints,"ResizeNorth",l.thumbsConstraints,l)&&wr(e,Je(i,{x:r+t.actualSize.width/2,y:s}),a)?h?"LabelResizeNorth":"ResizeNorth":null}(n,t,e,i,r,s)),o||null}(i,p,e,w,C,D),S))return S}}if(Lc(i)&&!n)return"Pan";if((o instanceof Es||o instanceof xc)&&(!Lc(i)||_v(i)||Uv(i))&&(S=function Ene(n,t,e,i){if(Hx(t)&&(ga(t,ri.Hover)||ga(t,ri.Visible))){if(t.constraints&ni.Drag)return"PortDrag"}else if(Rx(t)&&(ga(t,ri.Hover)||ga(t,ri.Visible))&&t.constraints&ni.Draw){n.drawingObject={};var r={type:"Orthogonal",sourcePortID:t.id};return n.drawingObject=r,n.tool|=Ci.DrawOnce,n.currentDrawingObject=r,"PortDraw"}return"None"}(i,o),"None"!==S))return S;if((o instanceof Zn||o instanceof Nr)&&!Lc(i)&&Dd(o))return _r(i,o,void 0,t)&&to(o)?"LabelDrag":"LabelSelect";if(null!==n){if(!(n instanceof te||n instanceof de))return"Select";if(t&&t.id){var L=t.id.split(n.id)[1];if(L&&L.match("^_icon"))return"LayoutAnimation"}if(t&&t.id)for(var O=void 0,N=0;N-1)return"FixedUserHandle";if(t instanceof si&&t.hyperlink.link)return"Hyperlink";if(!to(n)||!_r(i,n,!1)||void 0!==i.selectedItems.annotation)return n&&Lc(i)&&!PI(i)?"Pan":i.selectedItems.nodes.length&&i.selectedItems.nodes[0].isLane&&i.selectedItems.wrapper&&i.selectedItems.wrapper.bounds.containsPoint(e)?"Drag":"Select";if(n instanceof de&&!wr(e,n.sourcePoint,n.hitPadding)&&!wr(e,n.targetPoint,n.hitPadding)||!(n instanceof de))return"Drag"}return"Select"}(t,e,this.currentPosition,this.diagram,this.touchStartList,this.touchMoveList,r)},n.prototype.updateContainerBounds=function(t){var e=!1;if(this.diagram.selectedObject.helperObject&&this.diagram.selectedObject.actualObject instanceof te){var i=this.tool instanceof kd,r=this.diagram.selectedObject.actualObject,s=this.diagram.nameTable[r.parentId];t?V3(this.diagram,r,this.currentPosition,i):((!s||s&&"SwimLane"!==s.shape.type)&&this.diagram.updateDiagramObject(r),e=function yne(n,t,e,i){var r,o=!1;if(cs(n,t,!0)){n.protectPropertyChange(!0);var a=(r=n.nameTable[t.parentId]).wrapper;if(r&&"Canvas"===r.container.type){if(i||a.bounds.x<=e.x&&a.bounds.right>=e.x&&a.bounds.y<=e.y&&a.bounds.bottom>=e.y){var l=void 0,h=a.bounds.y,c=a.bounds.x,d=n.nameTable[r.parentId]||r;if("SwimLane"===d.shape.type)o=$v(r,d,t,n,!0);else{var p=n.nameTable[r.parentId]||r,f=p.shape;l=p.wrapper,a.actualSize.widtha.outerBounds.x)&&(void 0!==r.rowIndex?(l.updateColumnWidth(r.columnIndex,a.outerBounds.width,!0),"Horizontal"===f.orientation&&f.phaseSize&&FI(p,n,a,r.columnIndex),Oc(n,p),n.drag(p,c-a.bounds.x,h-a.bounds.y)):n.scale(r,1+(a.outerBounds.width-a.actualSize.width)/a.actualSize.width,1,a.outerBounds.xa.outerBounds.y)&&(void 0!==r.rowIndex?(l.updateRowHeight(r.rowIndex,a.outerBounds.height,!0),n.drag(p,c-a.bounds.x,h-a.bounds.y)):n.scale(r,1,1+(a.outerBounds.height-a.actualSize.height)/a.actualSize.height,a.outerBounds.yi.y&&(h+=u>0?-1:1,u+=u>0?-1:1):i&&e.wrapper.offsetYi.x&&(h+=u>0?-1:1,u+=u>0?-1:1):i&&e.wrapper.offsetX1&&!(this.diagram.lineRoutingModule&&this.diagram.constraints&rt.LineRouting))for(var b=t.offsetX-this.diagram.selectedItems.offsetX,M=t.offsetY-this.diagram.selectedItems.offsetY,w=t.rotateAngle-this.diagram.selectedItems.rotateAngle,C=0;C-1){var x=c.children;x.splice(x.indexOf(o.id),1),this.diagram.nameTable[o.id].parentId="",i=!0,c.wrapper.children.splice(A,1)}}if(function bne(n,t,e,i){var r=n,s=e.nameTable[r.parentId],o=e.nameTable[r.parentId];if(t&&o&&o.container&&"Stack"===o.container.type&&t.container&&"Stack"===t.container.type&&o.id!==t.parentId){var a=o.wrapper.children.indexOf(r.wrapper);a>-1&&(e.nameTable[r.id].parentId=t.id,o.wrapper.children.splice(a,1))}if(t&&t.parentId&&r.parentId&&"Drag"===i&&o.container&&"Stack"===o.container.type){var l=s.wrapper.children.indexOf(t.wrapper),h=s.wrapper.children.indexOf(r.wrapper),c={targetIndex:l,target:t,sourceIndex:h,source:n};s.wrapper.children.splice(h,1),s.wrapper.children.splice(l,0,r.wrapper),e.commandHandler.addHistoryEntry({type:"StackChildPositionChanged",redoObject:{targetIndex:h,target:t,sourceIndex:l,source:n},undoObject:c,category:"Internal"})}}(o,h,this.diagram,this.action),(c=cs(this.diagram,o)?this.diagram.nameTable[o.parentId]:this.diagram.nameTable[o.parentId]||o)&&c.container&&"Canvas"===c.container.type&&(c.wrapper.maxWidth=c.maxWidth=c.wrapper.actualSize.width,c.wrapper.maxHeight=c.maxHeight=c.wrapper.actualSize.height,e=!0),cs(this.diagram,o,!0)&&c&&"Canvas"===c.container.type)if(this.diagram.selectedItems.nodes.length>1)for(C=0;C0)for(var i=0;i0&&e.columnIndex>0||l&&e.isLane)){if("Horizontal"===t.container.orientation&&e.isPhase&&e.wrapper.width>e.maxWidth&&(e.maxWidth=e.wrapper.width,e.wrapper.maxWidth=e.wrapper.width),h.updateColumnWidth(e.columnIndex,r.width,!0,c),_x(this.diagram,e,t),e.isPhase){var f=this.diagram.nameTable[""+t.shape.phases[e.columnIndex].header.id];f.maxWidth0?(r=new rf(t,"",u),t.shape.classShape.attributes.push(r)):i.id.includes("_umlMethods")&&t.shape.classShape.methods.length>0&&(s=new hm(t,"",u),t.shape.classShape.methods.push(s))),"Interface"===t.shape.classifier&&(i.id.includes("_umlProperty")&&t.shape.interfaceShape.attributes.length>0?(r=new rf(t,"",u),t.shape.classShape.attributes.push(r)):i.id.includes("_umlMethods")&&t.shape.interfaceShape.methods.length>0&&(s=new hm(t,"",u),t.shape.interfaceShape.methods.push(s))),"Enumeration"===t.shape.classifier&&i.id.includes("_umlMember")&&t.shape.enumerationShape.members.length>0){var p=new sb(t,"",u);t.shape.enumerationShape.members.push(p)}t.wrapper.children.indexOf(c.wrapper),this.diagram.enableServerDataBinding(!0),this.diagram.add(c),this.diagram.updateConnectorEdges(t),this.diagram.clearSelection(),this.diagram.select([this.diagram.nameTable[c.id]]),this.diagram.endGroupAction(),this.diagram.startTextEdit()}}},n}(),_oe=function(){function n(){}return n.prototype.findObjectsUnderMouse=function(t,e,i,r,s){var o=[];r&&r instanceof oi&&r.nodes.length+r.connectors.length===1&&(r=r.nodes[0]||r.connectors[0]).children&&0===r.children.length&&(i.actualObject=r);for(var a,l,h,c,f,d=r&&r instanceof de&&(r.constraints&qe.ConnectToNearByNode||r.constraints&qe.ConnectToNearByPort)&&r.connectionPadding||0,p={},g=0,v=e.spatialSearch.findObjects(new Ne(t.x-50-d,t.y-50-d,100+d,100+d));g-1&&o.splice(T,1),"UmlClassifier"===y.shape.type&&y.container&&"Stack"===y.container.type&&(T=o.indexOf(e.nameTable[e.nameTable[y.id].wrapper.children[0].id]))>-1&&o.splice(T,1)}for(var P=0;Ps.zIndex&&(t[parseInt(r.toString(),10)]=l),r>0&&i&&a&&(a.isLane||a.isPhase||a.isHeader)&&t[parseInt(r.toString(),10)].zIndex=2)for(var d=t.length-1;d>=0;d--)if(t[parseInt(d.toString(),10)].parentId){var u=sm(t[parseInt(d.toString(),10)],e,""),p=sm(t[d-1],e,""),g=e.nameTable[""+p];g&&u!==p&&e.nameTable[""+u].zIndex=0;f--){d=Jp(e[parseInt(f.toString(),10)],!1),c=Jp(e[parseInt(f.toString(),10)],!0);var g=t[""+l].tool,v=this.findTargetElement(e[parseInt(f.toString(),10)].wrapper,o,t,void 0);if("Draw"===i&&v&&(e[parseInt(f.toString(),10)]instanceof te||e[parseInt(f.toString(),10)]instanceof de)&&!ib(e[parseInt(f.toString(),10)],v)&&(g&&"ConnectorSourceEnd"===g[""+h]&&!Nh(e[parseInt(f.toString(),10)])||g&&"ConnectorTargetEnd"===g[""+h]&&!da(e[parseInt(f.toString(),10)])))return u;if(e[parseInt(f.toString(),10)]instanceof te||e[parseInt(f.toString(),10)]instanceof de&&(Nh(e[parseInt(f.toString(),10)])||xd(d)||da(e[parseInt(f.toString(),10)])||Lh(c)||"PortDraw"===i&&g instanceof Od&&"ConnectorTargetEnd"===g[""+h]&&(da(e[parseInt(f.toString(),10)])||Lh(c))))return u=e[parseInt(f.toString(),10)],p&&(u=this.isTarget(u,t,i)),s.actualObject=u,u}else if("ConnectorTargetEnd"===i&&a){for(f=e.length-1;f>=0;f--)if(c=Jp(e[parseInt(f.toString(),10)],!0),(e[parseInt(f.toString(),10)]instanceof te||e[parseInt(f.toString(),10)]instanceof de)&&(da(e[parseInt(f.toString(),10)])||Lh(c)))return u=e[parseInt(f.toString(),10)],u=this.isTarget(u,t,i),s.actualObject=u,u}else{if(a&&("Drag"===i||t[""+l].tool instanceof ua)){var y=0;for(f=0;f=S.zIndex?u:S,y=Math.max(y,S.zIndex)):y=(u=S).zIndex)}return u&&"Bpmn"===u.shape.type&&(t.selectedItems.nodes.length>0&&"Bpmn"===t.selectedItems.nodes[0].shape.type||(u=null)),u&&(s.actualObject=u),u}if("Select"!==i&&"Pan"!==i||!t[""+l].tool)if("Pan"===i||"LayoutAnimation"===i){for(f=e.length-1;f>=0;f--)if((e[parseInt(f.toString(),10)]instanceof te||e[parseInt(f.toString(),10)]instanceof de)&&(v=this.findTargetElement(e[parseInt(f.toString(),10)].wrapper,o,t,void 0),"Pan"===i||v&&(v.id.match("_icon_content_shape$")||v.id.match("_icon_content_rect$"))))return e[parseInt(f.toString(),10)]}else u=e[e.length-1],s&&u&&(s.actualObject=u);else{for(f=e.length-1;f>=0;f--)if(e[parseInt(f.toString(),10)]instanceof de){var b=e[f-1];if(e[f-1]instanceof te&&b.ports){if((v=this.findTargetElement(b.wrapper,o,t,void 0))&&(v.id.match("_icon_content_shape$")||v.id.match("_icon_content_rect$")))return b;for(var M=0;M=0;s--){var o=t.children[parseInt(s.toString(),10)];if(o&&o.outerBounds.containsPoint(e,r||0))if(o.visible){if(o instanceof Cs){var a=this.findTargetElement(o,e,i);if(a)return a}var l="Clip"===o.style.textOverflow||"Ellipsis"===o.style.textOverflow;if(o.bounds.containsPoint(e,r||0)&&!l)return o;if(t.bounds.containsPoint(e,r||0)&&l)return o}else if(o instanceof Ke&&t&&t.id){var h=void 0;if(t.id.includes("group_container")){var c=t.id.slice(0,-15);h=i.getObject(c)}else h=i.getObject(t.id);if(eb(h,o.id))return o}}return t.bounds.containsPoint(e,r)&&"none"!==t.style.fill?t:null},n}(),Uoe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),sf=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},JF=function(n){function t(e,i,r,s){var o=n.call(this,e,i,r,s)||this;return o.objectZIndex=-1,o.zIndexTable={},o.objects=[],o}return Uoe(t,n),sf([I("")],t.prototype,"id",void 0),sf([I(!0)],t.prototype,"visible",void 0),sf([I(!1)],t.prototype,"lock",void 0),sf([I()],t.prototype,"objects",void 0),sf([I()],t.prototype,"addInfo",void 0),sf([I(-1)],t.prototype,"zIndex",void 0),t}(Ee),MT=function(n,t,e,i){return new(e||(e=Promise))(function(r,s){function o(h){try{l(i.next(h))}catch(c){s(c)}}function a(h){try{l(i.throw(h))}catch(c){s(c)}}function l(h){h.done?r(h.value):new e(function(c){c(h.value)}).then(o,a)}l((i=i.apply(n,t||[])).next())})},wT=function(n,t){var i,r,s,o,e={label:0,sent:function(){if(1&s[0])throw s[1];return s[1]},trys:[],ops:[]};return o={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function a(h){return function(c){return function l(h){if(i)throw new TypeError("Generator is already executing.");for(;e;)try{if(i=1,r&&(s=2&h[0]?r.return:h[0]?r.throw||((s=r.return)&&s.call(r),0):r.next)&&!(s=s.call(r,h[1])).done)return s;switch(r=0,s&&(h=[2&h[0],s.value]),h[0]){case 0:case 1:s=h;break;case 4:return e.label++,{value:h[1],done:!1};case 5:e.label++,r=h[1],h=[0];continue;case 7:h=e.ops.pop(),e.trys.pop();continue;default:if(!(s=(s=e.trys).length>0&&s[s.length-1])&&(6===h[0]||2===h[0])){e=0;continue}if(3===h[0]&&(!s||h[1]>s[0]&&h[1]1)for(var i=0;i-1)return e[parseInt(i.toString(),10)];return this.diagram.activeLayer},n.prototype.getLayer=function(t){for(var e=this.diagram.layers,i=0;i=0;o--)this.diagram.unSelect(this.diagram.nameTable[s[parseInt(o.toString(),10)]]),this.diagram.remove(this.diagram.nameTable[s[parseInt(o.toString(),10)]]),"default_layer"!==i.id&&this.diagram.activeLayer.id===t&&(this.diagram.activeLayer=this.diagram.layers[this.diagram.layers.length-1]);delete this.diagram.layerZIndexTable[i.zIndex],this.diagram.layers.splice(r,1),"SVG"!==this.diagram.mode&&this.diagram.refreshDiagramLayer()}},n.prototype.moveObjects=function(t,e){this.diagram.startGroupAction();for(var i={},r=[],s=0;s-1){if(r=[],(h=this.diagram.nameTable[""+s]).children)for(var f=0,g=h.children;f0){for(var y=void 0,S=0,b=r;S0)for(var r=0;r0)for(r=0;r0){t=t.concat(this.diagram.selectedItems.connectors);for(var i=0;i0)for(t=t.concat(this.diagram.selectedItems.nodes),i=0;i0){for(var i=0,r=t.shape.activity.subProcess.processes;i0&&this.copyProcesses(this.processTable[""+s])}this.clipboardData.processTable=this.processTable}},n.prototype.group=function(){this.oldSelectedObjects=rm(this.diagram);var e=this.diagram.isProtectedOnChange;this.diagram.protectPropertyChange(!0),this.diagram.diagramActions=this.diagram.diagramActions|ee.Group;var r={};r.id="group"+Qe(),(r=new te(this.diagram,"nodes",r,!0)).children=[];for(var s=this.diagram.selectedItems.nodes.concat(this.diagram.selectedItems.connectors).sort(function(h,c){return h.zIndex-c.zIndex}),o=0;o0){var a=this.diagram.add(r);a&&this.select(a),this.addHistoryEntry({type:"Group",undoObject:r,redoObject:r,category:"Internal"}),this.diagram.diagramActions=this.diagram.diagramActions&~ee.Group,this.diagram.protectPropertyChange(e)}},n.prototype.unGroup=function(t){var i=this.diagram.isProtectedOnChange;this.diagram.protectPropertyChange(!0),this.diagram.diagramActions=this.diagram.diagramActions|ee.Group;var r=[];t?r.push(t):r=this.diagram.selectedItems.nodes,this.diagram.startGroupAction();for(var s=0;s0&&this.diagram.removePorts(o,o.ports),o.annotations&&o.annotations.length>0&&!ce()&&this.diagram.removeLabels(o,o.annotations);for(var c=this.diagram.nameTable[o.parentId],d=o.children.length-1;d>=0;d--)this.diagram.nameTable[o.children[parseInt(d.toString(),10)]].parentId="",this.diagram.deleteChild(this.diagram.nameTable[o.children[parseInt(d.toString(),10)]],o),o.parentId&&o.children[parseInt(d.toString(),10)]&&this.diagram.addChild(c,o.children[parseInt(d.toString(),10)]);this.resetDependentConnectors(o.inEdges,!0),this.resetDependentConnectors(o.outEdges,!1),this.diagram.diagramActions&ee.UndoRedo||this.addHistoryEntry({type:"UnGroup",undoObject:a,redoObject:a,category:"Internal"}),o.parentId&&this.diagram.deleteChild(o,c)}this.diagram.removeNode(o,l),this.clearSelection()}this.diagram.endGroupAction(),this.diagram.diagramActions=this.diagram.diagramActions&~ee.Group,this.diagram.protectPropertyChange(i)},n.prototype.resetDependentConnectors=function(t,e){for(var i=0;i0&&(g=!1)}if(g){var y=this.cloneConnector(p,i);c.push(y),o[h.id]=y.id}}else{var S=this.cloneNode(h,i);if(c.push(S),S){o[h.id]=S.id;var b=h.inEdges;if(b)for(var M=0,w=b;M0)for(var u=0;u0)for(r=t.segments,s=0;s0&&this.diagram.drawingObject&&"Bezier"===this.diagram.drawingObject.type&&(t.segments=[]);var e=this.diagram.add(t);"SVG"!==this.diagram.mode&&this.diagram.refreshDiagramLayer(),this.selectObjects([e]),t&&!kI(this.diagram)&&(this.diagram.tool&=~Ci.DrawOnce,this.diagram.currentDrawingObject=void 0)},n.prototype.enableServerDataBinding=function(t){this.diagram.enableServerDataBinding(t)},n.prototype.addText=function(t,e){var i=this.diagram.findElementUnderMouse(t,e,this.diagram);this.diagram.startTextEdit(t,i instanceof si?i.id.split("_")[1]:void 0)},n.prototype.isUserHandle=function(t){var e=this.diagram.selectedItems;if(e.wrapper&&qr(e.constraints,"UserHandle"))for(var i=0,r=e.userHandles;i0&&t[0]&&t[0].isLane)for(s=this.diagram.getObject(t[0].parentId),t[0].shape.header=[],a=0;a1||e&&1===t.length)){if(1!==t.length)return[2];this.clearSelection()}if(!(u||d||1!==t.length||e&&Xa(this.diagram)))return this.clearSelection(),[2]}if(!r.cancel){for(p=0;p0||e)&&f.children&&!f.parentId)for(g=0;g0||e,!0)}else this.select(f,p>0||e,!0);void 0===i&&(i=c),r={oldValue:i||[],newValue:this.getSelectedObject(),cause:this.diagram.diagramActions,state:"Changed",type:"Addition",cancel:!1},this.diagram.renderSelector(e||t&&t.length>1),ce()||this.diagram.triggerEvent(Ce.selectionChange,r),this.diagram.enableServerDataBinding(!0)}return[2]})})},n.prototype.findParent=function(t){return t.parentId&&this.findParent(t=this.diagram.nameTable[t.parentId]),t},n.prototype.selectProcesses=function(t){if(this.hasProcesses(t))for(var e=t.shape.activity.subProcess.processes,i=0;i0)},n.prototype.select=function(t,e,i){var r=this.getObjectLayer(t.id);if(Dd(t)&&!(t instanceof oi)&&!_r(this.diagram,t)&&r&&!r.lock&&r.visible&&t.wrapper.visible){(e=!!Xa(this.diagram)&&e)||this.clearSelection(),this.diagram.enableServerDataBinding(!1);var s=this.diagram.selectedItems;if(t instanceof te?s.nodes.push(t.isHeader?this.diagram.nameTable[t.parentId]:t):s.connectors.push(t),s.selectedObjects.push(t),e)s.wrapper.rotateAngle=s.rotateAngle=0,s.wrapper.children.push(t.wrapper);else if(s.init(this.diagram),1===s.nodes.length&&0===s.connectors.length){var l=Ux(this.diagram,s);l&&(s.wrapper.children[0]=l),s.rotateAngle=s.nodes[0].rotateAngle,s.wrapper.rotateAngle=s.nodes[0].rotateAngle,s.wrapper.pivot=s.nodes[0].pivot}i||this.diagram.renderSelector(e),this.diagram.enableServerDataBinding(!0)}},n.prototype.labelSelect=function(t,e){this.oldSelectedObjects=rm(this.diagram);var i=this.diagram.selectedItems,r=this.diagram.allowServerDataBinding;this.diagram.allowServerDataBinding=!1,i.nodes=i.connectors=[],this.diagram.allowServerDataBinding=r,t instanceof te?i.nodes[0]=t:i.connectors[0]=t,i.annotation=this.findTarget(e,t),i.init(this.diagram),this.diagram.renderSelector(!1)},n.prototype.unSelect=function(t){var e=this.diagram.selectedItems.nodes.concat(this.diagram.selectedItems.connectors),i=e.filter(function(a){return a.id!==t.id}),r={oldValue:e,newValue:i,cause:this.diagram.diagramActions,state:"Changing",type:"Removal",cancel:!1};if(this.diagram.currentSymbol||ce()||this.diagram.triggerEvent(Ce.selectionChange,r),_r(this.diagram,t)){var s=this.diagram.selectedItems,o=void 0;t instanceof te?(o=s.nodes.indexOf(t,0),s.nodes.splice(o,1)):(o=s.connectors.indexOf(t,0),s.connectors.splice(o,1)),o=s.selectedObjects.indexOf(t,0),s.selectedObjects.splice(o,1),(r={oldValue:e,newValue:i,cause:this.diagram.diagramActions,state:"Changed",type:"Removal",cancel:(r={oldValue:e,newValue:i,cause:this.diagram.diagramActions,state:"Changed",type:"Removal",cancel:!1}).cancel}).cancel||(o=s.wrapper.children.indexOf(t.wrapper,0),s.wrapper.children.splice(o,1),this.diagram.updateSelector(),this.diagram.currentSymbol||this.diagram.triggerEvent(Ce.selectionChange,r))}},n.prototype.moveSvgNode=function(t,e){var i=xt(e+"_groupElement",this.diagram.element.id),r=xt(t+"_groupElement",this.diagram.element.id);i.parentNode.insertBefore(r,i)},n.prototype.moveAfterSvgNode=function(t,e){var i=xt(e+"_groupElement",this.diagram.element.id),r=xt(t+"_groupElement",this.diagram.element.id);i.insertAdjacentElement("afterend",r)},n.prototype.sendLayerBackward=function(t){var e=this.getLayer(t);if(e&&0!==e.zIndex){var i=e.zIndex;if("SVG"===this.diagram.mode){var r=e.objects,s=this.getLayer(this.diagram.layerZIndexTable[i-1]).objects[0];if(s)for(var o=0,a=r;od&&"SwimLane"!==f.shape.type){var S=$(f);f.zIndex=d-((-1!==i.indexOf(f)?i.indexOf(f):0)+1),f.children&&(d=this.findLowestZIndex(f,c)||d),this.triggerOrderCommand(S,f,f),f.children&&this.updateGroupZindex(f,"SendToBack",d)}else"SwimLane"===f.shape.type&&(y=this.swapZIndexObjects(a,h,r,g));if("SVG"===this.diagram.mode){for(var M="SwimLane"!==this.diagram.nameTable[""+r].shape.type?d:y,w=h[parseInt(M.toString(),10)];!w&&Md)&&(d=p.zIndex)}for(var f=JSON.parse(JSON.stringify(l)),v=Number(Object.keys(l).sort(function(wo,Hl){return Number(wo)-Number(Hl)}).reverse()[0]),y=this.diagram.nameTable[""+e].zIndex,S=[],M=0;M<=v;M++)S.push(l[parseInt(M.toString(),10)]);if("SwimLane"===this.diagram.nameTable[""+e].shape.type)for(var C=v;C>=y;C--)if(l[parseInt(C.toString(),10)]&&this.diagram.nameTable[l[parseInt(C.toString(),10)]].parentId!==e){v=C;break}var D=this.diagram.nameTable[""+e];if(D.zIndexx&&(x=L.zIndex)}}else x=d;D.zIndex=x+((-1!==r.indexOf(D)?r.indexOf(D):0)+1),this.triggerOrderCommand(A,D,D)}else if("SwimLane"===D.shape.type){for(var O=0,N=-1,T=0,P=0,_=JSON.parse(JSON.stringify(l)),B=0;B<=y;B++)if(l[parseInt(B.toString(),10)]&&this.diagram.nameTable[l[parseInt(B.toString(),10)]].parentId===e&&-1===N){N=B,T=B;break}for(var j=0;j<=v;j++)f[parseInt(j.toString(),10)]&&f[parseInt(j.toString(),10)]!==e&&this.diagram.nameTable[f[parseInt(j.toString(),10)]].parentId!==e&&this.diagram.nameTable[f[parseInt(j.toString(),10)]].zIndex>=this.diagram.nameTable[""+e].zIndex&&O++;for(var ue=N,pe=0;pe<=O;pe++){for(;!l[parseInt(ue.toString(),10)];)ue++;P=this.diagram.nameTable[l[parseInt(ue.toString(),10)]].zIndex,ue++}for(var Me=P;Me<=v;Me++){for(;!_[parseInt(N.toString(),10)];)N++;for(;!l[parseInt(Me.toString(),10)];)Me++;l[parseInt(Me.toString(),10)]=_[parseInt(N.toString(),10)],this.diagram.nameTable[l[parseInt(Me.toString(),10)]].zIndex=Me,N++}l[parseInt(v.toString(),10)]=this.diagram.nameTable[""+e].id,this.diagram.nameTable[""+e].zIndex=v,ue=y+1;for(var De=T,xe=0;xe0&&("Native"===hr[0].shape.type||"HTML"===hr[0].shape.type)){for(Mi.parentNode.removeChild(Mi),De=0;De0?r[0]:null},n.prototype.findLowestZIndex=function(t,e){var r=this.diagram.nodes.filter(function(s){return-1!==e.indexOf(s.id)}).filter(function(s){return""===s.parentId&&s.id!==t.id}).map(function(s){return s.zIndex});return r.sort(function(s,o){return s-o}),r.length>0?r[0]:null},n.prototype.triggerOrderCommand=function(t,e,i){var s={zIndex:$(t).zIndex},o={zIndex:e.zIndex},a={element:i,cause:this.diagram.diagramActions,diagramAction:this.diagram.getDiagramAction(this.diagram.diagramActions),oldValue:s,newValue:o};this.diagram.triggerEvent(Ce.propertyChange,a)},n.prototype.checkGroupNode=function(t,e,i){return i[""+e].parentId===i[""+t].parentId},n.prototype.sortByZIndex=function(t,e,i){if("BringForward"===i){var r=e||"zIndex";t=t.sort(function(o,a){return a[""+r]-o[""+r]})}else{var s=e||"zIndex";t=t.sort(function(o,a){return o[""+s]-a[""+s]})}return t},n.prototype.orderCommands=function(t,e,i){var r=this,s=e.nodes;if(s=s.concat(e.connectors),t)if("SendBackward"===i)for(var o=0;oa}),S=v.filter(function(D){return D0?Math.max.apply(Math,S):a,M=y.length>0?Math.min.apply(Math,y):a;if(a!==M){var w=c.zIndexTable[parseInt(M.toString(),10)],C=c.zIndexTable[parseInt(a.toString(),10)];this.moveSvgNode(C,w)}else"SendToBack"===i&&(w=c.zIndexTable[parseInt(a.toString(),10)],C=c.zIndexTable[parseInt(b.toString(),10)],this.moveAfterSvgNode(w,C))}}else this.diagram.refreshCanvasLayers()}},n.prototype.sendForward=function(t){var e=this;if(this.diagram.protectPropertyChange(!0),Xa(this.diagram)||t){$(t||(this.diagram.selectedItems.nodes.length?this.diagram.selectedItems.nodes[0]:this.diagram.selectedItems.connectors[0]));var s=t&&t.id,o=this.diagram.layers.indexOf(this.getObjectLayer(s=s||(this.diagram.selectedItems.nodes.length?this.diagram.selectedItems.nodes[0].id:this.diagram.selectedItems.connectors[0].id))),a=$(this.diagram.nameTable),h=(parseInt(o.toString(),10),this.diagram.nameTable[""+s]),c=[],d=this.diagram.spatialSearch.findObjects(h.wrapper.bounds);d.length>2&&(d=this.sortByZIndex(d,void 0,"BringForward"));for(var u=0,p=d;u=0;f--)this.diagram.nameTable[c[parseInt(f.toString(),10)].id].parentId===s&&c.splice(f,1);if(c.length>0){var y=this.diagram.nameTable[c[c.length-1].id];if(y.parentId){var b=sm(y,this.diagram,""),M=this.diagram.nameTable[""+b];M.id!==s&&(c[0]=M)}var w={};for(f=0;f0&&(Object.values(O).forEach(function(ue){ue>=T&&N.push(ue)}),0!==N.length&&this.updateZIndexBySendForward(h,N,o))}var P=[];if(Object.keys(this.changedNodeZIndexes).forEach(function(ue){if((a[""+ue]?a[""+ue].zIndex:null)!==e.changedNodeZIndexes[""+ue]){var De=$(a[""+ue]);P.push(De)}}),this.updateLayerZindexTable(o),L.nodes.splice(0,L.nodes.length),P.forEach(function(ue){var pe=$(ue);L.nodes.push(pe)}),"SVG"===this.diagram.mode){var _=c[c.length-1].id,B=c[c.length-1];B&&!("HTML"===B.shape.type||"Native"===B.shape.type)&&this.moveAfterSvgNode(s,_),this.updateNativeNodeIndex(_,s)}else this.diagram.refreshCanvasLayers();var j=[];Object.keys(this.changedNodeZIndexes).forEach(function(ue){if((a[""+ue]?a[""+ue].zIndex:null)!==e.changedNodeZIndexes[""+ue]){var De=$(e.diagram.nameTable[""+ue]);j.push(De)}});var Q=$(this.diagram.selectedItems);Q.nodes.splice(0,Q.nodes.length),j.forEach(function(ue){var pe=$(ue);Q.nodes.push(pe)}),this.diagram.diagramActions&ee.UndoRedo||this.addHistoryEntry({type:"SendForward",category:"Internal",undoObject:L,redoObject:Q}),this.diagram.endGroupAction()}}this.diagram.protectPropertyChange(!1)},n.prototype.updateZIndexBySendForward=function(t,e,i){var r=$(t);t.zIndex=Math.min.apply(Math,e);var a,s=Math.min.apply(Math,e),o=Math.min.apply(Math,e),l=this.diagram.layers[parseInt(i.toString(),10)].objects,h=this.diagram.nodes.filter(function(S){return-1!==l.indexOf(S.id)});t.children&&this.updateGroupZindex(t,"BringForward",t.zIndex);var c=h.filter(function(S){return S.zIndex===Math.min.apply(Math,e)&&S.id!==t.id});if(c&&c.length>0&&c[0].children){for(var d=Math.min.apply(Math,e),u=0;uo&&g!==t&&g.parentId!==t.id&&c&&c.length>0&&g.parentId!==c[0].id){var v=$(g);g.zIndex=a+1,a++,this.triggerOrderCommand(v,g,g)}var y=g.zIndex;this.changedNodeZIndexes[g.id]=(this.changedNodeZIndexes.hasOwnProperty(g.id),y)}},n.prototype.arrangeZIndexForLowerNodes=function(t,e,i){var r=i.filter(function(o){return o.zIndex<=t&&o.parentId!==e.id});r.sort(function(o,a){return a.zIndex-o.zIndex});for(var s=0;se&&(e=r.zIndex)}return e},n.prototype.sendBackward=function(t){var e=this;if(this.diagram.protectPropertyChange(!0),Xa(this.diagram)||t){$(t||(this.diagram.selectedItems.nodes.length?this.diagram.selectedItems.nodes[0]:this.diagram.selectedItems.connectors[0]));var s=t&&t.id,o=this.diagram.layers.indexOf(this.getObjectLayer(s=s||(this.diagram.selectedItems.nodes.length?this.diagram.selectedItems.nodes[0].id:this.diagram.selectedItems.connectors[0].id))),a=$(this.diagram.nameTable),h=(parseInt(o.toString(),10),this.diagram.nameTable[""+s]),c=[],d=this.diagram.spatialSearch.findObjects(h.wrapper.bounds);d.length>2&&(d=this.sortByZIndex(d));for(var u=0,p=d;uNumber(f.zIndex)&&""===f.parentId&&h.wrapper.bounds.intersects(f.wrapper.bounds)&&c.push(f);for(var f=c.length-1;f>=0;f--)(v=this.diagram.nameTable[c[parseInt(f.toString(),10)].id]).parentId===s&&c.splice(f,1);if(c.length>0){var v;if((v=this.diagram.nameTable[c[c.length-1].id]).parentId){var S=sm(v,this.diagram,""),b=this.diagram.nameTable[""+S];s!==b.id&&(c[c.length-1]=b)}var M={};for(f=0;f0&&(Object.values(L).forEach(function(pe){pe<=N&&O.push(pe)}),0!==O.length&&this.updateZIndexBySendBackward(h,O,o))}var T=[];if(Object.keys(this.changedNodeZIndexes).forEach(function(pe){if((a[""+pe]?a[""+pe].zIndex:null)!==e.changedNodeZIndexes[""+pe]){var xe=$(a[""+pe]);T.push(xe)}}),this.updateLayerZindexTable(o),R.nodes.splice(0,R.nodes.length),T.forEach(function(pe){var Me=$(pe);R.nodes.push(Me)}),"SVG"===this.diagram.mode){var P=c[c.length-1].id,_=c[c.length-1];_&&"HTML"!==_.shape.type&&"Native"!==_.shape.type&&this.moveSvgNode(s,P);var B=this.diagram.nameTable[""+P];B.children&&B.children.length>0?this.updateNativeNodeIndex(s):this.updateNativeNodeIndex(s,P)}else this.diagram.refreshCanvasLayers();var j=[];Object.keys(this.changedNodeZIndexes).forEach(function(pe){if((a[""+pe]?a[""+pe].zIndex:null)!==e.changedNodeZIndexes[""+pe]){var xe=$(e.diagram.nameTable[""+pe]);j.push(xe)}});var Q=$(this.diagram.selectedItems);Q.nodes.splice(0,Q.nodes.length),j.forEach(function(pe){var Me=$(pe);Q.nodes.push(Me)}),this.diagram.diagramActions&ee.UndoRedo||this.addHistoryEntry({type:"SendBackward",category:"Internal",undoObject:R,redoObject:Q}),this.diagram.endGroupAction()}}this.diagram.protectPropertyChange(!1)},n.prototype.updateZIndexBySendBackward=function(t,e,i){var r=$(t);t.zIndex=Math.max.apply(Math,e);var p,s=t.zIndex,o=Math.max.apply(Math,e),a=this.diagram.layers[parseInt(i.toString(),10)].objects,l=this.diagram.nodes.filter(function(S){return-1!==a.indexOf(S.id)}),h=l.filter(function(S){return S.zIndex===Math.max.apply(Math,e)&&S.id!==t.id});if(h&&h.length>0&&h[0].children)for(var c=Math.max.apply(Math,e),d=0;d0&&g.parentId!==h[0].id){var v=$(g);g.zIndex=p-1,p--,this.triggerOrderCommand(v,g,g)}var y=g.zIndex;this.changedNodeZIndexes[""+g.id]=(this.changedNodeZIndexes.hasOwnProperty(g.id),y)}},n.prototype.findLowestChildZIndex=function(t){for(var e=t.zIndex,i=0;i0),this.selectObjects([t],!0))},n.prototype.clearSelection=function(t,e){return MT(this,void 0,void 0,function(){var i,r,s,o;return wT(this,function(a){return i=this.diagram.allowServerDataBinding,this.diagram.enableServerDataBinding(!1),Xa(this.diagram)&&(r=this.diagram.selectedItems,s=this.getSelectedObject(),this.diagram.currentSymbol&&(this.diagram.previousSelectedObject=s),o={oldValue:s,newValue:[],cause:this.diagram.diagramActions,state:"Changing",type:"Removal",cancel:!1},t&&(ce()||this.diagram.triggerEvent(Ce.selectionChange,o)),o.cancel||(r.offsetX=0,r.offsetY=0,r.width=0,r.height=0,r.rotateAngle=0,r.nodes=[],r.connectors=[],r.wrapper=null,r.annotation=void 0,r.selectedObjects=[],this.diagram.clearSelectorLayer(),t&&(o={oldValue:s,newValue:[],cause:this.diagram.diagramActions,state:"Changed",type:"Removal",cancel:!1},ce()||this.diagram.triggerEvent(Ce.selectionChange,o))),this.diagram.enableServerDataBinding(i)),[2]})})},n.prototype.clearSelectedItems=function(){this.clearSelection((this.diagram.selectedItems.nodes?this.diagram.selectedItems.nodes.length:0)+(this.diagram.selectedItems.connectors?this.diagram.selectedItems.connectors.length:0)>0)},n.prototype.removeStackHighlighter=function(){var t=Pl(this.diagram.element.id),e=t.getElementById(t.id+"_stack_highlighter");e&&e.parentNode.removeChild(e)},n.prototype.renderStackHighlighter=function(t,e){var r,s,o,i=this.diagram.selectedItems.nodes[0];if(!e){var a=this.diagram.findObjectsUnderMouse(t.position);if((e=this.diagram.findObjectUnderMouse(a,"Drag",!0))&&!(e.isLane||e.isPhase||e.isHeader))for(var l=0;l0)for(var a=0;a1)if(i){var h=l.segments[0],c=l.segments[1],u=Tc(MI(t.wrapper,t.wrapper.corners,t.wrapper.bounds),h.direction),g=Ll({corners:void 0,point:u=Ah(l,0,u,{x:l.sourceWrapper.offsetX,y:l.sourceWrapper.offsetY},!1),margin:void 0,direction:h.direction},{corners:void 0,point:c.points[1],margin:void 0,direction:void 0});h.length=z.distancePoints(g[0],g[1]),c.direction&&c.length&&(c.length=z.distancePoints(g[1],g[2]))}else if(o){switch(l.segments[0].direction){case"Bottom":r=t.wrapper.bounds.bottomCenter.x-e.bottomCenter.x,s=t.wrapper.bounds.bottomCenter.y-e.bottomCenter.y;break;case"Top":r=t.wrapper.bounds.topCenter.x-e.topCenter.x,s=t.wrapper.bounds.topCenter.y-e.topCenter.y;break;case"Left":r=t.wrapper.bounds.middleLeft.x-e.middleLeft.x,s=t.wrapper.bounds.middleLeft.y-e.middleLeft.y;break;case"Right":r=t.wrapper.bounds.middleRight.x-e.middleRight.x,s=t.wrapper.bounds.middleRight.y-e.middleRight.y}this.dragSourceEnd(l,r,s,!0,null,"ConnectorSourceEnd",void 0,void 0,void 0,!(t.parentId&&this.diagram.diagramActions&ee.isGroupDragging))}}},n.prototype.updateEndPoint=function(t,e){var r={sourcePoint:t.sourcePoint,targetPoint:t.targetPoint};t.sourceID&&(r.sourceID=t.sourceID),t.targetID&&(r.targetID=t.targetID),t.sourcePortID&&(r.sourcePortID=t.sourcePortID),t.targetPortID&&(r.targetPortID=t.targetPortID),t.segments&&(r.segments=t.segments),this.diagram.connectorPropertyChange(t,e||{},r),this.diagram.updateSelector()},n.prototype.dragSourceEnd=function(t,e,i,r,s,o,a,l,h,c,d){var u=this.diagram.nameTable[t.id],p={},f=this.checkBoundaryConstraints(e,i,u.wrapper.bounds);if(xI(u)&&f&&"BezierSourceThumb"!==o&&Vv(this.diagram)&&(p=$(p={sourcePoint:u.sourcePoint}),u.sourcePoint.x+=e,u.sourcePoint.y+=i,"ConnectorSourceEnd"===o&&"Orthogonal"===u.type&&this.changeSegmentLength(u,l,h,c),"Bpmn"===u.shape.type&&"Default"===u.shape.sequence&&"Sequence"===u.shape.flow&&this.updatePathElementOffset(u)),"Bezier"===u.type)if(p={sourcePoint:u.sourcePoint},d)this.translateBezierPoints(t,""===o?"ConnectorSourceEnd":o,e,i,d,s,!a);else for(var g=0;g2){var d=z.direction((c=t.segments[2]).points[0],c.points[1]);o.direction===ls(d)?("Right"===o.direction?c.points[0].x=o.points[o.points.length-1].x=l.wrapper.corners.middleRight.x+20:"Left"===o.direction?c.points[0].x=o.points[o.points.length-1].x=l.wrapper.corners.middleLeft.x-20:c.points[0].y=o.points[o.points.length-1].y="Top"===o.direction?l.wrapper.corners.topCenter.y-20:l.wrapper.corners.bottomCenter.y+20,c.direction&&c.length&&(c.length=z.distancePoints(c.points[0],c.points[c.points.length-1])),o.length=z.distancePoints(o.points[0],o.points[o.points.length-1])):o.direction===d&&c.direction&&c.length?("Top"===o.direction||"Bottom"===o.direction?(c.points[0]=o.points[0],c.points[c.points.length-1].x=c.points[0].x):(c.points[0]=o.points[0],c.points[c.points.length-1].y=c.points[0].y),c.length=z.distancePoints(c.points[0],c.points[c.points.length-1]),t.segments.splice(0,2)):o.length=20}else o.length=20;else if(o.length<1)if(""!==t.sourceID){var c;"Right"===a.direction?a.points[a.points.length-1].y=(h=l.wrapper.corners.middleRight).y:"Left"===a.direction?a.points[a.points.length-1].y=(h=l.wrapper.corners.middleLeft).y:a.points[a.points.length-1].x="Top"===a.direction?(h=l.wrapper.corners.topCenter).x:(h=l.wrapper.corners.bottomCenter).x,a.length=z.distancePoints(h,a.points[a.points.length-1]),t.segments.length>2&&(c=t.segments[2]).direction&&c.length&&(c.length=z.distancePoints(a.points[a.points.length-1],c.points[c.points.length-1])),t.segments.splice(0,1)}else t.segments.splice(0,1)}else e&&!i&&t.sourceID!==e.id&&t.segments&&null!==t.segments[0].direction&&e&&e instanceof te&&s&&this.changeSourceEndToNode(t,e),e&&i&&t.sourcePortID!==i&&t.segments&&null!==t.segments[0].direction&&e&&e instanceof te&&s&&this.changeSourceEndToPort(t,e,i)},n.prototype.canConnect=function(t,e){return!(!da(e)||!Nh(e))},n.prototype.changeSourceEndToPort=function(t,e,i){var r=this.diagram.getWrapper(e.wrapper,i),s={x:r.offsetX,y:r.offsetY},o=zo(s,En(e.wrapper),e.wrapper.bounds),a=t.segments[0],l=t.segments[1];if(a.direction!==o){var h=[],c={};if(a.direction===ls(o)){c={};var d=void 0;"Top"===o||"Bottom"===o?(d="Top"===o?{type:"Orthogonal",isTerminal:!0,direction:o,length:Math.abs(a.points[0].y-s.y)}:{type:"Orthogonal",isTerminal:!0,direction:o,length:Math.abs(s.y-a.points[0].y)},c=a.points[0].x>s.x?{type:"Orthogonal",isTerminal:!0,direction:"Right",length:a.points[0].x-s.x}:{type:"Orthogonal",isTerminal:!0,direction:"Left",length:s.x-a.points[0].x}):(d="Right"===o?{type:"Orthogonal",isTerminal:!0,direction:o,length:Math.abs(a.points[0].x-s.x)}:{type:"Orthogonal",isTerminal:!0,direction:o,length:Math.abs(s.x-a.points[0].x)},c=a.points[0].y>s.y?{type:"Orthogonal",direction:"Top",isTerminal:!0,length:a.points[0].y-s.y}:{type:"Orthogonal",direction:"Bottom",isTerminal:!0,length:s.y-a.points[0].y}),h.push(new bi(t,"segments",d,!0)),h.push(new bi(t,"segments",c,!0))}else h.push(new bi(t,"segments",c={type:"Orthogonal",direction:o,length:20,isTerminal:!0},!0));a.direction!==ls(o)&&("Top"===o||"Bottom"===o?(a.points[0].x=s.x,a.points[0].y=a.points[a.points.length-1].y="Top"===o?s.y-20:s.y+20):(a.points[0].y=s.y,a.points[0].x=a.points[a.points.length-1].x="Right"===o?s.x+20:s.x-20),a.length=z.distancePoints(a.points[0],a.points[a.points.length-1]),l.length=z.distancePoints(a.points[a.points.length-1],l.points[l.points.length-1])),t.segments=h.concat(t.segments)}else a.points[0]=s,"Top"===o||"Bottom"===o?a.points[a.points.length-1].x=s.x:a.points[a.points.length-1].y=s.y,a.length=z.distancePoints(a.points[0],a.points[a.points.length-1]),l.length=z.distancePoints(a.points[a.points.length-1],l.points[l.points.length-1])},n.prototype.removeTerminalSegment=function(t,e){for(var i=0;ii.width||"Left"===o.direction&&r.x>=o.points[0].x||"Right"===o.direction&&r.x<=o.points[0].x)o.points[0].y=o.points[o.points.length-1].y=r.y,o.points[0].x=r.x,o.length=z.distancePoints(o.points[0],o.points[o.points.length-1]),a.length=z.distancePoints(o.points[o.points.length-1],a.points[a.points.length-1]);else{var h=void 0;s="Bottom"===(h=a.direction?a.direction:z.direction(a.points[0],a.points[a.points.length-1]))?i.bottomCenter:i.topCenter,a.length&&a.direction&&(a.length="Top"===h?o.points[o.points.length-1].y-(s.y+20):s.y+20-o.points[o.points.length-1].y),o.length=o.points[o.points.length-1].x-s.x,o.direction=o.length>0?"Right":"Left",l.push(new bi(t,"segments",{type:"Orthogonal",direction:h,length:20},!0)),t.segments=l.concat(t.segments)}else r="Bottom"===o.direction?i.bottomCenter:i.topCenter,o.length>i.height||"Top"===o.direction&&r.y>=o.points[0].y||"Bottom"===o.direction&&r.y<=o.points[0].y?(o.points[0].x=o.points[o.points.length-1].x=r.x,o.points[0].y=r.y,o.length=z.distancePoints(o.points[0],o.points[o.points.length-1]),a.length=z.distancePoints(o.points[o.points.length-1],a.points[a.points.length-1])):(s="Left"===a.direction?i.middleLeft:i.middleRight,h=void 0,h=a.direction?a.direction:z.direction(a.points[0],a.points[a.points.length-1]),a.length&&a.direction&&(a.length="Left"===h?o.points[o.points.length-1].x-(s.x+20):s.x+20-o.points[o.points.length-1].x),o.length=o.points[o.points.length-1].y-s.y,o.direction=o.length>0?"Bottom":"Top",l.push(new bi(t,"segments",{type:"Orthogonal",direction:h,length:20},!0)),t.segments=l.concat(t.segments))},n.prototype.translateBezierPoints=function(t,e,i,r,s,o,a){var l=t.segments.indexOf(s),h=t.segments[parseInt(l.toString(),10)],c=l>0?t.segments[l-1]:null,d=null!==c?c.point:t.sourcePoint,u=l===t.segments.length-1?t.targetPoint:h.point;if(h)if("BezierSourceThumb"===e&&(h.vector1.angle||h.vector1.distance)){var p=h.vector1.distance,f=h.vector1.angle;h.vector1={distance:t.distance(d,o),angle:z.findAngle(d,o)},this.translateSubsequentSegment(t,s,!0,h.vector1.distance-p,h.vector1.angle-f)}else"BezierTargetThumb"===e&&(h.vector2.angle||h.vector2.distance)?(p=h.vector2.distance,f=h.vector2.angle,h.vector2={distance:t.distance(u,o),angle:z.findAngle(u,o)},this.translateSubsequentSegment(t,s,!1,h.vector2.distance-p,h.vector2.angle-f)):("ConnectorSourceEnd"===e&&!t.sourceID||"ConnectorTargetEnd"===e&&!t.targetID)&&a&&QI(h.vector1)&&QI(h.vector2)?(z.isEmptyPoint(h.point1)&&(h.bezierPoint1=GI(t.sourcePoint,t.targetPoint)),z.isEmptyPoint(h.point2)&&(h.bezierPoint2=GI(t.targetPoint,t.sourcePoint))):"BezierSourceThumb"===e||"ConnectorSourceEnd"===e&&!a&&QI(h.vector1)?(h.bezierPoint1.x+=i,h.bezierPoint1.y+=r,(!z.isEmptyPoint(h.point1)||a)&&(h.point1={x:h.bezierPoint1.x,y:h.bezierPoint1.y})):("BezierTargetThumb"===e||"ConnectorTargetEnd"===e&&!a&&QI(h.vector2))&&(h.bezierPoint2.x+=i,h.bezierPoint2.y+=r,(!z.isEmptyPoint(h.point2)||a)&&(h.point2={x:h.bezierPoint2.x,y:h.bezierPoint2.y}))},n.prototype.translateSubsequentSegment=function(t,e,i,r,s){var o=t.segments.indexOf(e);parseInt(o.toString(),10),t.bezierSettings.smoothness&mI.SymmetricAngle||(s=null),t.bezierSettings.smoothness&mI.SymmetricDistance||(r=null),(null!=r||null!=s)&&(i?0!==o&&this.updatePreviousBezierSegment(t,o,r,s):o!==t.segments.length-1&&this.updateNextBezierSegment(t,o,r,s))},n.prototype.updatePreviousBezierSegment=function(t,e,i,r){var s=t.segments[e-1],a=(s.vector2.angle+r)%360;a<0&&(a+=360),s.vector2={distance:s.vector2.distance+i,angle:a}},n.prototype.updateNextBezierSegment=function(t,e,i,r){var s=t.segments[e+1],a=(s.vector1.angle+r)%360;a<0&&(a+=360),s.vector1={distance:s.vector1.distance+i,angle:a}},n.prototype.dragTargetEnd=function(t,e,i,r,s,o,a,l){var c,h=this.diagram.nameTable[t.id],d=this.checkBoundaryConstraints(e,i,h.wrapper.bounds);if(TI(h)&&"BezierTargetThumb"!==o&&d&&Vv(this.diagram)){if(c=$(c={targetPoint:h.targetPoint}),h.targetPoint.x+=e,h.targetPoint.y+=i,"ConnectorTargetEnd"===o&&"Orthogonal"===h.type&&h.segments&&h.segments.length>0){var u=h.segments[h.segments.length-2];u&&2===h.segments[h.segments.length-1].points.length&&("Left"===u.direction||"Right"===u.direction?u.points[u.points.length-1].x=h.targetPoint.x:u.points[u.points.length-1].y=h.targetPoint.y,u.length=z.distancePoints(u.points[0],u.points[u.points.length-1]),u.direction=z.direction(u.points[0],u.points[u.points.length-1]))}"Bpmn"===h.shape.type&&"Default"===h.shape.sequence&&"Sequence"===h.shape.flow&&this.updatePathElementOffset(h)}if("Bezier"===h.type)if(c={targetPoint:h.targetPoint},l)this.translateBezierPoints(t,""===o?"ConnectorTargetEnd":o,e,i,l,s,!a);else for(var p=0;p0){if(void 0!==s&&o.segments[parseInt(s.toString(),10)])if("Bezier"===o.type){var a=o.segments[parseInt(s.toString(),10)],l=a.isInternalSegment;l&&null!==o.bezierSettings&&"FreeForm"!==o.bezierSettings.segmentEditOrientation?("Horizontal"===a.orientation?a.point.x+=e:a.point.y+=i,this.updateDirectionalBezierCurve(o)):(a.point.x+=e,a.point.y+=i),l&&(o.isBezierEditing=!0)}else o.segments[parseInt(s.toString(),10)].point.x+=e,o.segments[parseInt(s.toString(),10)].point.y+=i;else for(var h=0;h1){var a=e[1],l=e[2],h={x:.5*(a.x+l.x),y:.5*(a.y+l.y)},c=t.segments[0];c.vector1.angle=Gt(s,a),c.vector1.distance=.5*z.findLength(s,a),c.vector2.angle=Gt(h,a),c.vector2.distance=.5*z.findLength(h,a),c.point=h;var d=t.segments[1];if(d.vector1.angle=Gt(h,l),d.vector1.distance=.5*z.findLength(h,l),t.segments.length>2){var u=e[3],p={x:.5*(l.x+u.x),y:.5*(l.y+u.y)};d.vector2.angle=Gt(p,l),d.vector2.distance=.5*z.findLength(p,l),d.point=p;var f=t.segments[2];if(f.vector1.angle=Gt(p,u),f.vector1.distance=.5*z.findLength(p,u),t.segments.length>3){var g=e[4],v={x:.5*(u.x+g.x),y:.5*(u.y+g.y)};f.vector2.angle=Gt(v,u),f.vector2.distance=.5*z.findLength(v,u),f.point=v;var y=t.segments[3];y.vector1.angle=Gt(v,g),y.vector1.distance=.5*z.findLength(v,g),y.vector2.angle=Gt(o,g),y.vector2.distance=.5*z.findLength(o,g)}else f.vector2.angle=Gt(o,u),f.vector2.distance=.5*z.findLength(o,u)}else d.vector2.angle=Gt(o,l),d.vector2.distance=.5*z.findLength(o,l)}},n.prototype.rotateObjects=function(t,e,i,r,s){r=r||{};var o=Hi();qi(o,i,r.x,r.y);for(var l=0,h=e;l0){this.diagram.protectPropertyChange(!0);var o=t;o.segments=[],this.diagram.connectorPropertyChange(o,{},{segments:o.segments}),this.diagram.protectPropertyChange(!1)}}},n.prototype.updateInnerParentProperties=function(t){var r=this.diagram.isProtectedOnChange;this.diagram.protectPropertyChange(!0);for(var s=this.getAllDescendants(t,[],!1,!0),o=0;o0&&(p=this.diagram.bpmnModule.getChildrenBound(d,d.id,this.diagram),u=d.wrapper.bounds.containsRect(p)),h=d.wrapper.actualSize.width*t,c=d.wrapper.actualSize.height*e,void 0!==d.maxWidth&&0!==d.maxWidth&&(h=Math.min(d.maxWidth,h)),void 0!==d.minWidth&&0!==d.minWidth&&(h=Math.max(d.minWidth,h)),void 0!==d.maxHeight&&0!==d.maxHeight&&(c=Math.min(d.maxHeight,c)),void 0!==d.minHeight&&0!==d.minHeight&&(c=Math.max(d.minHeight,c)),u&&(h=Math.max(h,p.right-d.wrapper.bounds.x),c=Math.max(c,p.bottom-d.wrapper.bounds.y)),t=h/d.actualSize.width,e=c/d.actualSize.height}var f=Hi();o||(o=r);var g=o.wrapper;if(qi(f,-g.rotateAngle,i.x,i.y),Wp(f,t,e,i.x,i.y),qi(f,g.rotateAngle,i.x,i.y),r instanceof te){var d,v=Je(f,{x:(d=r).wrapper.offsetX,y:d.wrapper.offsetY}),y=d.wrapper.offsetX-d.wrapper.actualSize.width*d.pivot.x,S=d.wrapper.offsetY-d.wrapper.actualSize.height*d.pivot.y;if(h>0)if(d.processId){var b=this.diagram.nameTable[d.processId];(!b.maxWidth||d.margin.left+h0)if(d.processId){var M=this.diagram.nameTable[d.processId];(!M.maxHeight||d.margin.top+c0){if(e.dragLimit=e.dragLimit?e.dragLimit:{},e.dragLimit.top||e.dragLimit.bottom||e.dragLimit.left||e.dragLimit.right){var b={minDistance:null};S=this.getRelativeOffset(v,d,b);var M={minDistance:null};g=this.getRelativeOffset(v,y,M),S=null!=b&&M.minDistance0){if(S=y[y.length-1]){var b=void 0;for(b=0;b=e.x-t.dragLimit.left-r.width/2&&i.x<=e.x+t.dragLimit.right+r.width/2&&(s=!0),i.y>=e.y-t.dragLimit.top-r.height/2&&i.y<=e.y+t.dragLimit.bottom+r.height/2&&(o=!0),{x:s,y:o}},n.prototype.updateLabelMargin=function(t,e,i,r,s,o,a){if(i=i||{x:e.offset,y:0},e&&i&&i.x>0&&i.x<1){var l=z.getLengthFromListOfPoints(t.intermediatePoints),h=this.getPointAtLength(l*i.x,t.intermediatePoints,0),c=this.diagram.scrollSettings.currentZoom,d=e.dragLimit?e.dragLimit:{left:0,right:0,top:0,bottom:0};if(d.top||d.bottom||d.left||d.right){this.diagram.getWrapper(t.wrapper,e.id);var p=new Ne(0,0,0,0),f=this.diagram.getWrapper(t.wrapper,e.id);p.x=f.offsetX/c+o,p.y=f.offsetY/c+a,p.width=f.bounds.width/c,p.height=f.bounds.height/c;var g=new Ne(h.x-(d.left||0)-p.width/2,h.y-(d.top||0)-p.height/2,(d.left||0)+(d.right||0)+p.width,(d.top||0)+(d.bottom||0)+p.height);if(g.containsPoint(r));else for(var S=0,b=this.boundsInterSects([h,r],g,!1);S=t){c=t-r,d=z.findAngle(s,a),u=c*Math.cos(d*Math.PI/180),p=c*Math.sin(d*Math.PI/180),o={x:s.x+u,y:s.y+p};break}r+=h,s=a}else s=a;return o},n.prototype.getInterceptWithSegment=function(t,e){for(var o,a,i=[],r=[],s=[],l=z.findLength({x:0,y:0},{x:this.diagram.scroller.viewPortWidth,y:this.diagram.scroller.viewPortHeight}),h=1;h0&&a<=90||a>180&&a<=270?90:-90;r.push(z.transform(t,a+c,l)),r.push(z.transform(t,o+c,l));var p=em({x1:s[0].x,y1:s[0].y,x2:s[1].x,y2:s[1].y},{x1:r[0].x,y1:r[0].y,x2:r[1].x,y2:r[1].y});p.enabled&&i.push(p.intersectPt)}return i},n.prototype.getAnnotationChanges=function(t,e){var r={};return r[tb(t,e.id,!0)]={width:e.width,height:e.height,offset:t instanceof te?{x:e.offset.x,y:e.offset.y}:e.offset,rotateAngle:e.rotateAngle,margin:{left:e.margin.left,right:e.margin.right,top:e.margin.top,bottom:e.margin.bottom},horizontalAlignment:e.horizontalAlignment,verticalAlignment:e.verticalAlignment,alignment:t instanceof de?e.alignment:void 0},{annotations:r}},n.prototype.getConnectorPortChanges=function(t,e){var i=function kse(n,t,e){for(var i=n.ports,r=0;r1&&(v.width=g,v.offset.x=1/S),f>1&&(v.height=f,v.offset.y=1/b)}}e instanceof Nr&&(e.alignment="Center"),l=this.getAnnotationChanges(t,e),t instanceof te?this.diagram.nodePropertyChange(t,a,l):this.diagram.connectorPropertyChange(t,a,l),this.diagram.updateDiagramObject(t)},n.prototype.getSubProcess=function(t){var i,e={nodes:[],connectors:[]};return t instanceof te?i=t.processId:t&&t.nodes&&t.nodes.length&&t.nodes[0].processId&&(i=t.nodes[0].processId),i&&e.nodes.push($(this.diagram.nameTable[i])),e},n.prototype.checkBoundaryConstraints=function(t,e,i,r){var s=this.diagram.pageSettings,o=this.diagram.pageSettings.boundaryConstraints,a=this.diagram.scroller;if("Page"===o||"Diagram"===o){var l=i?void 0:this.diagram.selectedItems.wrapper.bounds;return!!((i?i.right:l.right)+(t||0)<=("Page"===o?s.width:a.viewPortWidth)&&(i?i.left:l.left)+(t||0)>=0&&(i?i.bottom:l.bottom)+(e||0)<=("Page"===o?s.height:a.viewPortHeight)&&(i?i.top:l.top)+(e||0)>=0||"None"!==this.diagram.layout.type&&r)}return!0},n.prototype.dragSelectedObjects=function(t,e){var i=this,r=this.diagram.selectedItems;this.state&&!this.state.backup&&(this.state.backup={},this.state.backup.offsetX=r.offsetX,this.state.backup.offsetY=r.offsetY),r=UI(this.diagram,r)||r;var s=this.diagram.selectedItems.nodes.filter(function(c){return"SwimLane"===c.shape.type});if(s.length>0&&!this.diagram.currentSymbol&&this.diagram.selectedItems.nodes.length>1){var o=this.diagram.selectedItems.nodes.filter(function(c){return""===c.parentId||"SwimLane"!==i.diagram.nameTable[c.parentId].shape.type});if(o.length>0){for(var a=0;a0||l.length>1)&&(o=o.concat(l),this.diagram.selectedItems.nodes.splice(0,this.diagram.selectedItems.nodes.length),o.forEach(function(c){i.diagram.selectedItems.nodes.push(c)}),r=this.diagram.selectedItems,this.diagram.selectedObject.helperObject=void 0)}}if(this.checkBoundaryConstraints(t,e)){this.diagram.diagramActions=this.diagram.diagramActions|ee.PreventZIndexOnDragging|ee.DragUsingMouse;var h=this.diagram.selectedObject.actualObject;return(h&&h instanceof te&&h.isLane&&Vx(h,this.diagram)||!h||!h.isLane)&&this.diagram.drag(r,t,e),this.diagram.diagramActions=this.diagram.diagramActions&~(ee.PreventZIndexOnDragging|ee.DragUsingMouse),this.diagram.refreshCanvasLayers(),this.checkHtmlObjectDrag(r),!0}return!1},n.prototype.checkHtmlObjectDrag=function(t){var e=!1;this.diagram.views&&this.diagram.views.length>1&&(t instanceof oi?e=t.nodes.some(function(i){return i.shape&&"HTML"===i.shape.type}):t.shape&&"HTML"===t.shape.type&&(e=!0),e&&this.resetOverviewCanvas())},n.prototype.resetOverviewCanvas=function(){for(var t=0,e=this.diagram.views;t0&&(this.layoutAnimateModule.stopCurrentAnimation(this.objectStore[0],e,t),this.objectStore=[]),a=this.diagram.doLayout(),this.objectStore.push(a)),this.canUpdateTemplate=!1,this.diagram.blazorActions&=~on.expandNode,this.diagram.preventNodesUpdate=r,this.diagram.layoutAnimateModule&&this.diagram.organizationalChartModule&&!i)this.diagram.allowServerDataBinding=!1,this.layoutAnimateModule.expand(this.diagram.layout.enableAnimation,a,t,this.diagram);else{var l={element:$(t),state:!!t.isExpanded};this.triggerEvent(Ce.expandStateChange,l),this.diagram.lineRoutingModule&&this.diagram.constraints&rt.LineRouting&&"ComplexHierarchicalTree"!==this.diagram.layout.type&&this.diagram.resetSegments()}return this.diagram.layout.fixedNode=""===o?"":this.diagram.layout.fixedNode,a},n.prototype.getparentexpand=function(t,e,i,r){for(var s,o=0;o0&&(this.diagram.selectedItems.wrapper.rotateAngle=this.diagram.selectedItems.rotateAngle=s.rotateAngle),r instanceof te&&"SwimLane"!==r.shape.type&&!r.isLane&&!r.isPhase&&!r.isHeader)(r.offsetX!==r.wrapper.offsetX||r.offsetY!==r.wrapper.offsetY||r.width!==r.wrapper.width||r.height!==r.wrapper.height||r.rotateAngle!==r.wrapper.rotateAngle)&&(r.offsetX+=o,r.offsetY+=a,r.width+=l,r.height+=h,r.rotateAngle+=c,this.diagram.nodePropertyChange(r,{},{offsetX:r.offsetX,offsetY:r.offsetY,width:r.width,height:r.height,rotateAngle:r.rotateAngle})),e=this.diagram.spatialSearch.findObjects(r.wrapper.outerBounds);else if(r instanceof oi)for(var d=0;d30||g.wrapper.outerBounds.topCenter.y-f.wrapper.outerBounds.bottomCenter.y>30)&&this.diagram.lineRoutingModule.refreshConnectorSegments(this.diagram,p,!0)}}this.updateSelector(),this.diagram.protectPropertyChange(!1)}},n.prototype.drawSelectionRectangle=function(t,e,i,r){this.diagram.drawSelectionRectangle(t,e,i,r)},n.prototype.startGroupAction=function(){this.diagram.startGroupAction()},n.prototype.endGroupAction=function(){this.diagram.endGroupAction()},n.prototype.removeChildFromBPmn=function(t,e,i){var r=this.diagram.nameTable[t.id]||t.nodes[0];if(i&&r&&r.processId&&r.processId===i.wrapper.id){var s=$(r);s.processId=r.processId,this.diagram.startGroupAction();var o=this.diagram.nameTable[r.processId].shape.activity.subProcess.processes||[];o.splice(o.indexOf(r.id),1),this.diagram.bpmnModule.removeChildFromBPMN(this.diagram.nameTable[r.processId].wrapper,r.id,this.diagram),this.diagram.nameTable[r.id].processId="",r.offsetX=r.wrapper.offsetX,r.offsetY=r.wrapper.offsetY;var a=$(r);this.addHistoryEntry({type:"PositionChanged",redoObject:{nodes:[a]},undoObject:{nodes:[s]},category:"Internal"}),this.diagram.endGroupAction()}},n.prototype.isDroppable=function(t,e){var i=this.diagram.nameTable[t.id]||t.nodes[0];return i instanceof te&&(!ce()&&"TextAnnotation"===i.shape.shape||("Group"===e.shape.shape&&(e.shape.activity.subProcess.collapsed=!1),!(i&&"Bpmn"===i.shape.type&&(i.processId===e.id||i.id===e.processId||"Bpmn"===e.shape.type&&!(e instanceof de)&&e.shape.activity&&e.shape.activity.subProcess&&e.shape.activity.subProcess.collapsed))))},n.prototype.renderHighlighter=function(t,e,i){if(new Ne,t.target instanceof te||t.target instanceof de||e&&(t.source instanceof te||t.source instanceof de)){var a=this.findTarget(e?t.sourceWrapper:t.targetWrapper,e?t.source:t.target,i,!0),l=void 0;if(a instanceof zd)for(var h=a.id,c=t.target,u=0,p=c.wrapper.children[0].children[0].children[2].children;u0){var r=0;t[0]=this.diagram.nameTable[t[0].id]||t[0];var s="Object"===i?yr(t[0].wrapper):this.diagram.selectedItems.wrapper.bounds,o={nodes:[],connectors:[]},a={nodes:[],connectors:[]};for(r="Object"===i?r+1:r;r0){var i=0,r=0,s=0,o=0,a=0,l=0,h=0,c=0,d={nodes:[],connectors:[]},u={nodes:[],connectors:[]};for(i=0;io.center.y&&(r=n[parseInt(e.toString(),10)],n[parseInt(e.toString(),10)]=n[parseInt(i.toString(),10)],n[parseInt(i.toString(),10)]=r):s.center.x>o.center.x&&(r=n[parseInt(e.toString(),10)],n[parseInt(e.toString(),10)]=n[parseInt(i.toString(),10)],n[parseInt(i.toString(),10)]=r)}}return n}(t,e),i=1;i0){var i=0,r={x:.5,y:.5};t[0]=this.diagram.nameTable[t[0].id]||t[0];var s=yr(t[0].wrapper),o={nodes:[],connectors:[]},a={nodes:[],connectors:[]};for(i=1;ii.zIndex){for(var s=this.diagram.layers.indexOf(this.diagram.getActiveLayer()),o=this.diagram.layers[parseInt(s.toString(),10)].zIndexTable,a=JSON.parse(JSON.stringify(o)),l=i.zIndex,h=r.zIndex,c=h;c>=l;c--)l!==c?o[c-1]?(o[parseInt(c.toString(),10)]=o[c-1],this.diagram.nameTable[o[parseInt(c.toString(),10)]].zIndex=c):(o[c-1]=o[parseInt(c.toString(),10)],this.diagram.nameTable[o[c-1]].zIndex=c,delete o[parseInt(c.toString(),10)]):this.swapZIndexObjects(h,o,r.id,a);"SVG"===this.diagram.mode?(this.moveSvgNode(e.parentId,i.id),this.updateNativeNodeIndex(e.parentId,i.id)):this.diagram.refreshCanvasLayers()}},n.prototype.findLeastIndexConnector=function(t,e,i){for(var r=0;rs.zIndex&&(i=s)}return i},n.prototype.findLeastIndexObject=function(t,e){var i=t;return t instanceof te&&(i=this.findLeastIndexConnector(t.inEdges,e,i),i=this.findLeastIndexConnector(t.outEdges,e,i)),i},n.prototype.checkSelection=function(t,e){var i;if(1===t.nodes.length&&0===t.connectors.length)if(cs(this.diagram,t.nodes[0],!0)){var r=t.nodes[0];if("SwimLane"===(i="SwimLane"===t.nodes[0].shape?t.nodes[0]:this.diagram.nameTable[t.nodes[0].parentId]).shape.type){var s="Horizontal"===i.shape.orientation;(r.isPhase&&(s&&"ResizeSouth"===e||!s&&"ResizeEast"===e)||r.isLane&&(s&&"ResizeEast"===e||!s&&"ResizeSouth"===e))&&B3(this.diagram,i,e)}else if("Grid"===i.container.type)if("Horizontal"===i.container.orientation&&1===r.rowIndex||"Vertical"===i.container.orientation&&r.rowIndex>0&&r.columnIndex>0){if("ResizeSouth"===e)for(var o=0;o1&&(this.diagram.realActions=this.diagram.realActions|$i.hScrollbarMoved,this.scrolled=!0),this.diagram.scrollSettings.horizontalOffset=t},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"verticalOffset",{get:function(){return this.vOffset},set:function(t){this.vOffset=t,Math.abs(this.vOffset-this.diagram.scrollSettings.verticalOffset)>1&&(this.diagram.realActions=this.diagram.realActions|$i.vScrollbarMoved,this.scrolled=!0),this.diagram.scrollSettings.verticalOffset=t},enumerable:!0,configurable:!0}),n.prototype.getBounds=function(){var e=this.diagram.spatialSearch.getPageBounds(0,0);return(e.x<0||e.y<0)&&!this.diagram.pageSettings.multiplePage?this.getPageBounds(void 0,void 0,!0,!0):this.getPageBounds(void 0,void 0,!0)},n.prototype.updateScrollOffsets=function(t,e){var i,r,s=this.getBounds();s.x*=this.currentZoom,s.y*=this.currentZoom,s.width*=this.currentZoom,s.height*=this.currentZoom,i=Math.max(0,t-s.left),r=Math.max(0,e-s.top),void 0!==t&&void 0!==e?(this.horizontalOffset=i,this.verticalOffset=r,this.diagram.setOffset(i,r)):this.diagram.setOffset(-this.horizontalOffset-s.x,-this.verticalOffset-s.y),this.transform={tx:Math.max(this.horizontalOffset,-s.left)/this.currentZoom,ty:Math.max(this.verticalOffset,-s.top)/this.currentZoom,scale:this.currentZoom}},n.prototype.setScrollOffset=function(t,e){this.scrolled=!1;var i=this.getBounds();i.x*=this.currentZoom,i.y*=this.currentZoom,i.width*=this.currentZoom,i.height*=this.currentZoom;var r=-i.left,s=-i.top,o=!1,a=this.viewPortWidth*this.currentZoom,l=this.viewPortHeight*this.currentZoom,h=r-t;if(h!==this.horizontalOffset){rh?this.horizontalOffset-=t:this.horizontalOffset=h,o=!0);var c=Math.max(i.right+this.vScrollSize,a);if(!o&&c<-h+this.viewPortWidth){var d=-h+a-this.vScrollSize,u=-this.horizontalOffset+a-this.vScrollSize;this.horizontalOffset=dd-u?h:-(i.right+this.vScrollSize-a),o=!0}o||(this.horizontalOffset=r-t)}o=!1;var p=s-e;if(p!==this.verticalOffset){sp?this.verticalOffset-=e:this.verticalOffset=p,o=!0);var f=Math.max(i.bottom+this.hScrollSize,l);if(!o&&f<-p+l){var g=-p+l-this.hScrollSize,v=-this.verticalOffset+l-this.hScrollSize;this.verticalOffset=gg-v?p:-(i.bottom+this.hScrollSize-l),o=!0}o||(this.verticalOffset=s-e)}this.transform={tx:Math.max(this.horizontalOffset,-i.left)/this.currentZoom,ty:Math.max(this.verticalOffset,-i.top)/this.currentZoom,scale:this.currentZoom},this.setSize()},n.prototype.getObjects=function(t,e){for(var i=[],r=0;r0){for(var l=0;l0){h.push(i[parseInt(o.toString(),10)].id);for(var d=0;d=e.bottom&&(l=0),-this.horizontalOffset<=e.x&&-this.horizontalOffset+this.viewPortWidth>=e.right&&(a=0),this.hScrollSize=a,this.vScrollSize=l;var h=this.diagramWidth,c=this.diagramHeight;this.diagramWidth=Math.max(e.right,-this.horizontalOffset+this.viewPortWidth-l)-i,this.diagramHeight=Math.max(e.bottom,-this.verticalOffset+this.viewPortHeight-a)-r,(h!==this.diagramWidth||c!==this.diagramHeight)&&"Diagram"!==this.diagram.scrollSettings.scrollLimit&&this.diagram.setSize(this.diagramWidth,this.diagramHeight),"Diagram"===this.diagram.scrollSettings.scrollLimit&&(h===this.diagramWidth&&c===this.diagramHeight&&1===this.currentZoom||this.diagram.diagramActions&&t&&(!this.diagram.diagramActions||!t||0===this.verticalOffset&&this.verticalOffset!==t.y||0===this.horizontalOffset&&this.horizontalOffset!==t.x)?t&&h===this.diagramWidth&&c===this.diagramHeight&&(this.diagram.diagramCanvas.scrollHeight>this.viewPortHeight&&t.y<0&&this.horizontalOffset===t.x&&0===this.verticalOffset||this.diagram.diagramCanvas.scrollWidth>this.viewPortWidth&&t.x<0&&this.verticalOffset===t.y&&0===this.horizontalOffset)&&(this.verticalOffset=t.y,this.horizontalOffset=t.x,this.transform={tx:Math.max(t.x,-e.left)/this.currentZoom,ty:Math.max(t.y,-e.top)/this.currentZoom,scale:this.currentZoom}):(this.diagram.scrollActions&ca.Interaction&&t&&(this.transform={tx:Math.max(t.x,-e.left/this.currentZoom)/this.currentZoom,ty:Math.max(t.y,-e.top/this.currentZoom)/this.currentZoom,scale:this.currentZoom},this.horizontalOffset=t.x,this.verticalOffset=t.y),this.diagram.setSize(this.diagramWidth,this.diagramHeight),!(this.diagram.scrollActions&ca.PropertyChange)&&t&&(this.horizontalOffset=t.x,this.verticalOffset=t.y,this.transform={tx:Math.max(t.x,-e.left)/this.currentZoom,ty:Math.max(t.y,-e.top)/this.currentZoom,scale:this.currentZoom}))),this.diagram.transformLayers(),this.diagram.element.style.overflow="hidden"},n.prototype.setViewPortSize=function(t,e){this.viewPortWidth=t,this.viewPortHeight=e},n.prototype.getPageBounds=function(t,e,i,r){var o,s=new Ne;if("Content"===e||r||null===this.diagram.pageSettings.width||null===this.diagram.pageSettings.height){var u=t?void 0:0;o=this.diagram.spatialSearch.getPageBounds(u,u)}else{var a=this.diagram.pageSettings.width,l=this.diagram.pageSettings.height,h=0,c=0;if(this.diagram.pageSettings.multiplePage){if((s=this.diagram.spatialSearch.getPageBounds(0,0)).right>a&&(a*=d=Math.ceil(s.right/a)),s.bottom>l&&(l*=d=Math.ceil(s.bottom/l)),s.left<0&&Math.abs(s.left)>h){var d=Math.ceil(Math.abs(s.left)/this.diagram.pageSettings.width);h=this.diagram.pageSettings.width*d}s.top<0&&Math.abs(s.top)>c&&(d=Math.ceil(Math.abs(s.top)/this.diagram.pageSettings.height),c=this.diagram.pageSettings.height*d)}o=new Ne(-h,-c,a+h,l+c)}if(i){var p=this.diagram.scrollSettings.padding;o.x-=p.left,o.y-=p.top,o.width+=p.left+p.right,o.height+=p.top+p.bottom}return o},n.prototype.getPageBreak=function(t){for(var e=0,i=0,r=-1,s=[],c=this.diagram.pageSettings.margin.left,d=this.diagram.pageSettings.margin.right,u=this.diagram.pageSettings.margin.top,p=this.diagram.pageSettings.margin.bottom,f=1,g=1;t.width>e;)(e+=this.diagram.pageSettings.width?this.diagram.pageSettings.width:t.width)===this.diagram.pageSettings.width&&(s[++r]={x1:t.left+c,y1:t.top+u,x2:t.left+c,y2:t.bottom-p}),ei;)(i+=this.diagram.pageSettings.height?this.diagram.pageSettings.height:t.height)===this.diagram.pageSettings.height&&(s[++r]={x1:t.left+c,y1:t.top+u,x2:t.right-d,y2:t.top+u}),i=this.diagram.scrollSettings.minZoom||l||t>=1)){this.currentZoom*=t;var c=this.getPageBounds(void 0,void 0,!0);c.x*=this.currentZoom,c.y*=this.currentZoom;var d=Hi();Wp(d,t,t,r.x,r.y),ZB(d,e||0,i||0),yx(h,d);var u=Je(h,{x:0,y:0});if(1===t&&(u=this.applyScrollLimit(u.x,u.y,s,o,a)),a=-c.y>=u.y&&-c.x>=u.x&&a,(this.diagram.scrollActions&ca.PropertyChange||!(this.diagram.scrollActions&ca.Interaction)||"Diagram"!==this.diagram.scrollSettings.scrollLimit||a)&&(this.transform={tx:Math.max(u.x,-c.left)/this.currentZoom,ty:Math.max(u.y,-c.top)/this.currentZoom,scale:this.currentZoom},this.horizontalOffset=u.x,this.verticalOffset=u.y),this.setSize(u),"SVG"!==this.diagram.mode&&Ds(this.diagram)&&this.diagram.scroller.virtualizeElements(),"SVG"!==this.diagram.mode&&!Ds(this.diagram)&&this.diagram.refreshDiagramLayer(),this.diagram.setOffset(-this.horizontalOffset-c.x,-this.verticalOffset-c.y),XI(this.diagram),this.diagram.views&&this.diagram.views.overview){var p=this.diagram.views.overview,f=p.scrollOverviewRect(p.parent.scroller.horizontalOffset,p.parent.scroller.verticalOffset,p.parent.scroller.currentZoom,!0);p.updateOverviewrect(-f.x,-f.y,f.width,f.height),p.updateView(p)}}}},n.prototype.fitToPage=function(t){var e=(t=t||{}).mode,i=t.region,r=t.margin||{},s=t.canZoomIn,o=t.customBounds,a=t.canZoomOut;r.bottom=r.bottom||25,r.top=r.top||25,r.left=r.left||25,r.right=r.right||25;var h,l=o,c=-this.horizontalOffset,d=-this.verticalOffset;if("PageSettings"===(i=i||"PageSettings")&&this.diagram.pageSettings.width&&this.diagram.pageSettings.height||this.diagram.nodes.length>0||this.diagram.connectors.length>0){e=e||"Page","CustomBounds"!==i&&(l=this.getPageBounds(!0,i,!0));var u={x:0,y:0};r.left+r.right>this.viewPortWidth&&(this.viewPortWidth<=100?(r.left=5,r.right=5):(r.left=25,r.right=25)),r.top+r.bottom>this.viewPortHeight&&(this.viewPortHeight<=100?(r.top=5,r.bottom=5):(r.top=25,r.bottom=25)),u.x=(this.viewPortWidth-(r.left+r.right))/l.width,u.y=(this.viewPortHeight-(r.top+r.bottom))/l.height,!s&&l.width-this.horizontalOffset-a+this.viewPortWidth&&(i=o.right-this.viewPortWidth,i+=20),o.x<-a&&(i=o.x),o.bottom>-l+this.viewPortHeight&&(r=o.bottom-this.viewPortHeight,r+=20),o.y<-l&&(r=o.y),this.zoom(1,-this.horizontalOffset-i,-this.verticalOffset-r,null,void 0,e))},n.prototype.bringToCenter=function(t){var e=this.currentZoom,i=new Ne(t.x*e,t.y*e,t.width*e,t.height*e),r=i.x+i.width/2-this.viewPortWidth/2,s=i.y+i.height/2-this.viewPortHeight/2;this.zoom(1,-this.horizontalOffset-(r*=-1),-this.verticalOffset-(s*=-1),null)},n.prototype.applyScrollLimit=function(t,e,i,r,s){if("Infinity"===this.diagram.scrollSettings.scrollLimit&&void 0===i&&!r&&(t=-t,e=-e),"Infinity"!==this.diagram.scrollSettings.scrollLimit){var o=void 0;if("Limited"===this.diagram.scrollSettings.scrollLimit){var a=this.diagram.scrollSettings.scrollableArea;o=new Ne(a.x,a.y,a.width,a.height)}(o=o||(s?this.getPageBounds():this.getPageBounds(!0))).x*=this.currentZoom,o.y*=this.currentZoom,o.width*=this.currentZoom,o.height*=this.currentZoom,void 0!==i&&(t*=-1,e*=-1),r&&(t*=-1,e*=-1);var l=Math.max(o.right,this.viewPortWidth);if(!r&&!(t<=o.x&&(t+this.viewPortWidth>=o.right||t>=o.right-this.viewPortWidth)||t>=o.x&&t+this.viewPortWidth<=l))if(t>=o.x)t=Math.max(o.x,Math.min(t,t-(t+this.viewPortWidth-this.vScrollSize-l)));else{var h=o.right-this.viewPortWidth;t=Math.min(h,o.x)}var c=Math.max(o.bottom,this.viewPortHeight);r||e<=o.y&&e+this.viewPortHeight>=o.bottom||e>=o.y&&e+this.viewPortHeight<=c||(e>=o.y?e=Math.max(o.y,Math.min(e,e-(e+this.viewPortHeight-this.hScrollSize-c))):(h=o.bottom-this.viewPortHeight,e=Math.min(o.y,h))),t*=-1,e*=-1}return{x:t,y:e}},n}(),Woe=function(){function n(t,e,i,r,s){this.objects=[],this.left=t,this.top=e,this.width=i,this.height=r,this.spatialSearch=s}return n.prototype.findQuads=function(t,e){null!=this.first&&this.first.isIntersect(t)&&this.first.findQuads(t,e),null!=this.second&&this.second.isIntersect(t)&&this.second.findQuads(t,e),null!=this.third&&this.third.isIntersect(t)&&this.third.findQuads(t,e),null!=this.fourth&&this.fourth.isIntersect(t)&&this.fourth.findQuads(t,e),this.objects.length>0&&e.push(this)},n.prototype.isIntersect=function(t){return!(this.left+this.widtht.right||this.top>t.bottom)},n.prototype.selectQuad=function(){for(var i,t=null,e=this;null!=e;)i=e.getQuad(t),e=i.source,t=i.target||t;return t},n.prototype.getQuad=function(t){var e=this.width/2,i=this.height/2;if(e>=1e3&&i>=1e3){var r=this.left+e,s=this.top+i;if(this.spatialSearch.childRight<=r){if(this.spatialSearch.childBottom<=s)return this.first||((o=new n(this.left,this.top,e,i,this.spatialSearch)).parent=this,this.first=o),{source:this.first};if(this.spatialSearch.childTop>=s)return this.third||((o=new n(this.left,s,e,i,this.spatialSearch)).parent=this,this.third=o),{source:this.third}}else if(this.spatialSearch.childLeft>=r){if(this.spatialSearch.childBottom<=s)return this.second||((o=new n(r,this.top,e,i,this.spatialSearch)).parent=this,this.second=o),{source:this.second};var o;if(this.spatialSearch.childTop>=s)return this.fourth||((o=new n(r,s,e,i,this.spatialSearch)).parent=this,this.fourth=o),{source:this.fourth}}}return this.objects.push(this.spatialSearch.childNode),{target:this}},n.prototype.isContained=function(){return this.spatialSearch.childLeft>=this.left&&this.spatialSearch.childRight<=this.left+this.width&&this.spatialSearch.childTop>=this.top&&this.spatialSearch.childBottom<=this.top+this.height},n.prototype.addIntoAQuad=function(t){var e={};this.spatialSearch.setCurrentNode(t);for(var i=null;!e.isAdded;)i=(e=this.spatialSearch.parentQuad.add(i)).quad;return i},n.prototype.add=function(t){if(t=null,this.isContained())return{isAdded:!0,quad:t=this.selectQuad()};var e=void 0,i=!(0!==this.objects.length||this.first||this.second||this.third||this.fourth),r=2*this.width,s=2*this.height;return this.spatialSearch.childLeft=this.childLeft?(this.pageLeft=this.childLeft,this.leftElement=t,r=!0):t===this.leftElement&&(this.pageLeft=Number.MAX_VALUE,this.findLeft(this.parentQuad),r=!0)),(this.pageTop!==this.childTop||t!==this.topElement)&&(this.pageTop>=this.childTop?(this.pageTop=this.childTop,this.topElement=t,r=!0):t===this.topElement&&(this.pageTop=Number.MAX_VALUE,this.findTop(this.parentQuad),r=!0)),(this.pageBottom!==this.childBottom||t!==this.bottomElement)&&(this.pageBottom<=this.childBottom?(r=!0,this.pageBottom=this.childBottom,this.bottomElement=t):t===this.bottomElement&&(this.pageBottom=-Number.MAX_VALUE,this.findBottom(this.parentQuad),r=!0)),(this.pageRight!==this.childRight||t!==this.rightElement)&&(this.pageRight<=this.childRight?(this.pageRight=this.childRight,this.rightElement=t,r=!0):t===this.rightElement&&(this.pageRight=-Number.MAX_VALUE,this.findRight(this.parentQuad),r=!0)),r}return this.setCurrentNode(null),!1},n.prototype.isWithinPageBounds=function(t){return t.left>=this.pageLeft&&t.right<=this.pageRight&&t.top>=this.pageTop&&t.bottom<=this.pageBottom},n.prototype.findQuads=function(t){var e=[];return this.parentQuad.findQuads(t,e),e},n.prototype.findObjects=function(t){for(var i=[],r=0,s=this.findQuads(t);r=r.outerBounds.left&&(this.pageLeft=r.outerBounds.left,this.leftElement=r)}},n.prototype.findTop=function(t){t.first||t.second?(t.first&&this.findTop(t.first),t.second&&this.findTop(t.second)):(t.third&&this.findTop(t.third),t.fourth&&this.findTop(t.fourth));for(var e=0,i=t.objects;e=r.outerBounds.top&&(this.pageTop=r.outerBounds.top,this.topElement=r)}},n.prototype.setCurrentNode=function(t){if(this.childNode=t,t){var e=t.outerBounds;this.childLeft=Number(e.left),this.childTop=Number(e.top),this.childRight=Number(e.right),this.childBottom=Number(e.bottom)}else this.childLeft=Number.MAX_VALUE,this.childTop=Number.MAX_VALUE,this.childRight=-Number.MAX_VALUE,this.childBottom=-Number.MAX_VALUE},n.prototype.getPageBounds=function(t,e){if(this.pageLeft===Number.MAX_VALUE)return new Ne(0,0,0,0);var i=void 0!==t?Math.min(this.pageLeft,0):this.pageLeft,r=void 0!==e?Math.min(this.pageTop,0):this.pageTop;return new Ne(Math.round(i),Math.round(r),Math.round(this.pageRight-i),Math.round(this.pageBottom-r))},n.prototype.getQuad=function(t){return this.quadTable[t.id]},n}(),Yoe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Goe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Yoe(t,n),function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);r>3&&s&&Object.defineProperty(t,e,s)}([I(!1)],t.prototype,"preventDefaults",void 0),t}(Ee),Xoe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),e_=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},qoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Xoe(t,n),e_([I("")],t.prototype,"action",void 0),e_([I("")],t.prototype,"cursor",void 0),t}(Ee),t_=function(){function n(){this.size=20,this.intermediatePoints=[],this.gridCollection=[],this.startArray=[],this.targetGridCollection=[],this.sourceGridCollection=[],this.considerWalkable=[]}return n.prototype.lineRouting=function(t){var e=t.connectors.length;if(this.renderVirtualRegion(t),e>0)for(var i=0;i=t.right||e.right<=t.left||e.top>=t.bottom||e.bottom<=t.top)},n.prototype.findEndPoint=function(t,e,i){var r,s;if(e&&""!==t.sourcePortID&&t.sourcePortWrapper||!e&&""!==t.targetPortID&&t.targetPortWrapper){s=zo(r=e?{x:t.sourcePortWrapper.offsetX,y:t.sourcePortWrapper.offsetY}:{x:t.targetPortWrapper.offsetX,y:t.targetPortWrapper.offsetY},void 0,e?t.sourceWrapper.bounds:t.targetWrapper.bounds);var o=e?t.sourcePortWrapper.bounds:t.targetPortWrapper.bounds;r=i?"Top"===s?{x:o.topCenter.x,y:o.topCenter.y}:"Left"===s?{x:o.middleLeft.x,y:o.middleLeft.y}:"Right"===s?{x:o.middleRight.x,y:o.middleRight.y}:{x:o.bottomCenter.x,y:o.bottomCenter.y}:{x:o.center.x,y:o.center.y}}else r=e&&this.startNode||!e&&this.targetNode?e?{x:this.startNode.wrapper.offsetX,y:this.startNode.wrapper.offsetY}:{x:this.targetNode.wrapper.offsetX,y:this.targetNode.wrapper.offsetY}:e?{x:t.sourcePoint.x,y:t.sourcePoint.y}:{x:t.targetPoint.x,y:t.targetPoint.y};return r},n.prototype.refreshConnectorSegments=function(t,e,i,r){var h,c,p,f,g,y,S,b,M,w,C,s=e.sourceID,o=e.targetID,a=e.sourcePortID,l=e.targetPortID;if(function Ure(n,t){var e=0;return n.constraints&qe.LineRouting?e=n.constraints&qe.LineRouting:n.constraints&qe.InheritLineRouting&&(e=t.constraints&rt.LineRouting),e}(e,t)||r){this.startNode=t.nameTable[""+s],this.targetNode=t.nameTable[""+o],this.intermediatePoints=[],this.startArray=[],this.targetGridCollection=[],this.sourceGridCollection=[],this.startGrid=void 0,this.targetGrid=void 0;for(var D=0;D0;){var L=this.startArray.pop();if(L){for(D=0;D1&&(e.segments=[]),this.updateConnectorSegments(t,this.intermediatePoints,this.gridCollection,e,i)){this.considerWalkable=[];break e}this.targetGridCollection.splice(this.targetGridCollection.indexOf(O),1),L=this.startArray.pop()}}L&&this.findPath(L)}}}},n.prototype.checkChildNodes=function(t,e){var i=!1,r=!1;if(t.nodeId.length>=1&&!e)for(var s=0;s1&&this.targetGridCollection[0].nodeId.length>1)for(var c=0;c<=1;c++){for(var d=this.targetGridCollection[parseInt(c.toString(),10)].gridX,u=this.targetGridCollection[parseInt(c.toString(),10)].gridY,p=this.targetGridCollection[parseInt(c.toString(),10)].nodeId,f=void 0,g=0;g=e.right&&t.top<=e.top&&t.bottom>=e.bottom},n.prototype.getEndvalue=function(t,e){return this.gridCollection[t.gridX][t.gridY].walkable?t:"left"===e?this.getEndvalue(this.gridCollection[t.gridX-1][t.gridY],e):"right"===e?this.getEndvalue(this.gridCollection[t.gridX+1][t.gridY],e):"top"===e?this.getEndvalue(this.gridCollection[t.gridX][t.gridY-1],e):"bottom"===e?this.getEndvalue(this.gridCollection[t.gridX][t.gridY+1],e):t},n.prototype.changeValue=function(t,e,i){t.walkable||this.considerWalkable.push(t);for(var r,s=0;s<=e;s++)"left"===i?r=this.gridCollection[t.gridX-s][t.gridY]:"right"===i?r=this.gridCollection[t.gridX+s][t.gridY]:"top"===i?r=this.gridCollection[t.gridX][t.gridY-s]:"bottom"===i&&(r=this.gridCollection[t.gridX][t.gridY+s]),r.walkable||this.considerWalkable.push(r)},n.prototype.getIntermediatePoints=function(t){var e;for(this.intermediatePoints=[];t;)this.intermediatePoints.push({x:t.gridX,y:t.gridY}),t=t.parent;this.intermediatePoints.reverse(),this.intermediatePoints.length>=1&&void 0!==this.intermediatePoints[0]&&void 0!==this.intermediatePoints[1]&&(this.intermediatePoints[0].x===this.intermediatePoints[1].x?this.intermediatePoints[0].y=1&&u.length>1&&(g=u[u.length-2].x!==u[u.length-1].x?u[u.length-2].x>u[u.length-1].x?"Left":"Right":u[u.length-2].y>u[u.length-1].y?"Top":"Bottom"),M>=2&&v===g&&u.length>1&&u.splice(u.length-2,1),v=g);if(u&&u.length>1){for(var w=0;wD.x?S.bounds.middleLeft:S.bounds.middleRight),w===u.length-2&&""===r.targetPortID&&y&&(l=C.x>D.x?y.bounds.middleRight:y.bounds.middleLeft),0===w&&b&&(C.x=b.x,C.y=D.y=b.y),w===u.length-2&&l&&(w>0&&r.targetDecorator&&l.x-D.x<0&&Math.abs(l.x-C.x)0&&r.targetDecorator&&l.x-D.x>0&&Math.abs(l.x-C.x)D.y?S.bounds.topCenter:S.bounds.bottomCenter),w===u.length-2&&""===r.targetPortID&&y&&(l=C.y>D.y?y.bounds.bottomCenter:y.bounds.topCenter),0===w&&b&&(C.y=b.y,C.x=D.x=b.x),w===u.length-2&&l&&(w>0&&r.targetDecorator&&l.y-D.y<0&&Math.abs(l.y-C.y)0&&r.targetDecorator&&l.y-D.y>0&&Math.abs(l.y-C.y)D.x?(p="Left",f=C.x-D.x):(p="Right",f=D.x-C.x):C.y>D.y?(p="Top",f=C.y-D.y):(p="Bottom",f=D.y-C.y),o.push({type:"Orthogonal",length:f,direction:p})}}if(o&&o.length>0){var A=o[o.length-1];if(1===o.length&&(A.length-=20),A.length<10&&2===o.length&&(o.pop(),o.length>0&&(o[0].length-=20,A=o[0])),r.targetDecorator&&("Top"===A.direction||"Bottom"===A.direction)&&A.length>r.targetDecorator.height+1||("Right"===A.direction||"Left"===A.direction)&&A.length>r.targetDecorator.width+1)return r.segments=o,s&&t.connectorPropertyChange(r,{},{type:"Orthogonal",segments:o}),!0}return!1},n.prototype.findPath=function(t){for(var e,i=[],r=this.findNearestNeigbours(t,this.gridCollection,!0),s=0;sl)&&(e.x!==t.gridX||e.y!==t.gridY)&&(i.push(e),o.previousDistance=l,o.afterDistance=o.afterDistance||this.manhattan(Math.abs(e.x-this.targetGrid.gridX),Math.abs(e.y-this.targetGrid.gridY)),o.totalDistance=o.previousDistance+o.afterDistance,o.parent=t)}if(i.length>0)for(s=0;st?i*t+e:i*e+t},n.prototype.manhattan=function(t,e){return t+e},n.prototype.findNearestNeigbours=function(t,e,i){var r=[],s=t.parent;if(s){var o=(t.gridX-s.gridX)/Math.max(Math.abs(t.gridX-s.gridX),1),a=(t.gridY-s.gridY)/Math.max(Math.abs(t.gridY-s.gridY),1);0!==o?(this.isWalkable(t.gridX,t.gridY-1,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX][t.gridY-1])&&r.push(e[t.gridX][t.gridY-1]),this.isWalkable(t.gridX,t.gridY+1,!0)&&this.sourceGridCollection.indexOf(e[t.gridX][t.gridY+1])&&r.push(e[t.gridX][t.gridY+1]),this.isWalkable(t.gridX+o,t.gridY,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX+o][t.gridY])&&r.push(e[t.gridX+o][t.gridY])):0!==a&&(this.isWalkable(t.gridX-1,t.gridY,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX-1][t.gridY])&&r.push(e[t.gridX-1][t.gridY]),this.isWalkable(t.gridX+1,t.gridY,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX+1][t.gridY])&&r.push(e[t.gridX+1][t.gridY]),this.isWalkable(t.gridX,t.gridY+a,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX][t.gridY+a])&&r.push(e[t.gridX][t.gridY+a]))}else this.neigbour(t,"top",r,i),this.neigbour(t,"right",r,i),this.neigbour(t,"bottom",r,i),this.neigbour(t,"left",r,i);return r},n.prototype.neigbour=function(t,e,i,r){for(var o,s=1;s>0;){var a="top"===e||"bottom"===e?t.gridX:"left"===e?t.gridX-s:t.gridX+s,l="right"===e||"left"===e?t.gridY:"top"===e?t.gridY-s:t.gridY+s;if((o=this.gridCollection[parseInt(a.toString(),10)][parseInt(l.toString(),10)])&&(r&&-1===this.sourceGridCollection.indexOf(o)||!r&&-1===this.targetGridCollection.indexOf(o)))return i&&this.isWalkable(a,l)&&i.push(o),s;if(!(a>0&&l>0))break;s++}return null},n.prototype.resetGridColl=function(t,e,i){for(var s,r=1;r>0;){var o="top"===e||"bottom"===e?t.gridX:"left"===e?t.gridX-r:t.gridX+r,a="right"===e||"left"===e?t.gridY:"top"===e?t.gridY-r:t.gridY+r;if((s=this.gridCollection[parseInt(o.toString(),10)][parseInt(a.toString(),10)])&&(i&&-1===this.sourceGridCollection.indexOf(s)||!i&&-1===this.targetGridCollection.indexOf(s))){if(this.isWalkable(o,a))break;var l=this.gridCollection[parseInt(o.toString(),10)][parseInt(a.toString(),10)];this.considerWalkable.push(l)}if(!(o>0&&a>0))break;"top"===e||"left"===e?r--:r++}return null},n.prototype.isWalkable=function(t,e,i){if(t>=0&&t=0&&e0?1:-1,this.isWalkable(h,c-1)&&!this.isWalkable(h-a,c-1)||this.isWalkable(h,c+1)&&!this.isWalkable(h-a,c+1)))return{x:t,y:e};if(0!==l){if(l=l>0?1:-1,this.isWalkable(h-1,c)&&!this.isWalkable(h-1,c-l)||this.isWalkable(h+1,c)&&!this.isWalkable(h+1,c-l))return{x:t,y:e};if(this.findIntermediatePoints(h+1,c,h,c,s,o)||this.findIntermediatePoints(h-1,c,h,c,s,o))return{x:t,y:e}}return this.findIntermediatePoints(h+a,c+l,h,c,s,o)},n.prototype.destroy=function(){},n.prototype.getModuleName=function(){return"LineRouting"},n}(),$oe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Joe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return $oe(t,n),function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);r>3&&s&&Object.defineProperty(t,e,s)}([I(!0)],t.prototype,"inversedAlignment",void 0),t}(Ee),Koe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Oe=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},CT=function(n,t,e,i){return new(e||(e=Promise))(function(r,s){function o(h){try{l(i.next(h))}catch(c){s(c)}}function a(h){try{l(i.throw(h))}catch(c){s(c)}}function l(h){h.done?r(h.value):new e(function(c){c(h.value)}).then(o,a)}l((i=i.apply(n,t||[])).next())})},ET=function(n,t){var i,r,s,o,e={label:0,sent:function(){if(1&s[0])throw s[1];return s[1]},trys:[],ops:[]};return o={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function a(h){return function(c){return function l(h){if(i)throw new TypeError("Generator is already executing.");for(;e;)try{if(i=1,r&&(s=2&h[0]?r.return:h[0]?r.throw||((s=r.return)&&s.call(r),0):r.next)&&!(s=s.call(r,h[1])).done)return s;switch(r=0,s&&(h=[2&h[0],s.value]),h[0]){case 0:case 1:s=h;break;case 4:return e.label++,{value:h[1],done:!1};case 5:e.label++,r=h[1],h=[0];continue;case 7:h=e.ops.pop(),e.trys.pop();continue;default:if(!(s=(s=e.trys).length>0&&s[s.length-1])&&(6===h[0]||2===h[0])){e=0;continue}if(3===h[0]&&(!s||h[1]>s[0]&&h[1]0&&((!s.style||!s.style.fill)&&(o.style.fill="transparent"),(!s.style||!s.style.strokeColor)&&(o.style.strokeColor="transparent")),s.shape&&"UmlActivity"===s.shape.type&&ZI(s,o),s.shape&&"SwimLane"===s.shape.type&&aF(s,o),r.nodeDefaults&&Ro(o,s,r.nodeDefaults),r.updateAnnotationText(o.annotations);if(e&&e.connectors)for(a=0;e&&e.connectors&&a0&&0===i.nodes.length)this.clearCollection(),a=!0;else{for(var g=0,v=Object.keys(e.nodes);g0&&0===i.connectors.length)this.clearCollection(!0),a=!0;else{for(var C=0,D=Object.keys(e.connectors);C0){this.renderSelector(!0);break}if(e.selectedItems.constraints){this.renderSelector(!0);break}break;case"snapSettings":this.updateSnapSettings(e);break;case"commandManager":this.initCommands();break;case"layout":o=!0;break;case"segmentThumbShape":this.updateSelector();break;case"dataSourceSettings":this.clear(),"None"===this.layout.type?a=!0:(this.initObjects(),o=!0);break;case"tooltip":i3(this);break;case"rulerSettings":this.updateRulerSettings(e);break;case"layers":this.updateLayer(e);break;case"scrollSettings":this.scrollActions|=ca.PropertyChange,this.updateScrollSettings(e),this.scrollActions&=~ca.PropertyChange,this.scrollSettings.horizontalOffset=-this.scroller.horizontalOffset||0,this.scrollSettings.verticalOffset=-this.scroller.verticalOffset||0;break;case"locale":e.locale!==i.locale&&(this.realActions|=$i.PreventDataInit,n.prototype.refresh.call(this),this.realActions&=~$i.PreventDataInit);break;case"contextMenuSettings":if(void 0!==e.contextMenuSettings.showCustomMenuOnly&&(this.contextMenuSettings.showCustomMenuOnly=e.contextMenuSettings.showCustomMenuOnly),void 0!==e.contextMenuSettings.show&&(this.contextMenuSettings.show=e.contextMenuSettings.show),e.contextMenuSettings.items){for(var A=e.contextMenuSettings.items,x=0,R=Object.keys(A);x0){for(var N=[],T=O.ports.length-1;T>=0;T--)"LineDistribution"===O.ports[parseInt(T.toString(),10)].id.split("_")[1]&&N.push(O.ports[parseInt(T.toString(),10)]);this.removePorts(O,N)}}for(T=0;T0)for(var ue=0,pe=Object.keys(e.nodes);ue0)for(var De=0,xe=Object.keys(e.connectors);De=0;o--)this.commandHandler.expandNode(r[parseInt(o.toString(),10)],this,0!==o);this.canLayout&&this.doLayout(),this.lineRoutingModule?this.connectors.sourceID!==this.connectors.targetID&&this.lineRoutingModule.lineRouting(this):this.constraints&rt.LineRouting&&console.warn('[WARNING] :: Module "LineRouting" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),this.validatePageSize(),this.renderPageBreaks(),this.diagramRenderer.renderSvgGridlines(this.snapSettings,Bd(this.element.id),this.scroller.transform,this.rulerSettings,this.hRuler,this.vRuler),this.commandHandler.initSelectorWrapper(),this.notify("initial-load",{}),this.trigger("load"),this.scroller.setSize(),this.scroller.updateScrollOffsets(),this.isRefreshed||this.refreshDiagramLayer(),(this.scrollSettings.verticalOffset>0||this.scrollSettings.horizontalOffset>0)&&this.updateScrollOffset(),X.isDevice&&(this.tool=Ci.ZoomPan|Ci.SingleSelect),this.notify("initial-end",{}),this.isProtectedOnChange=!1,this.tooltipObject=i3(this),this.diagramActions=ee.Render,this.initCommands();var a=document.getElementsByClassName(this.element.id+"_hiddenUserHandleTemplate");(function Ioe(n,t,e,i){var r,s,o,a,l,d=document.getElementById(i).ej2_instances[0];if(n&&t){r=UF(n);for(var u=0,p=e.userHandles;u0;)e[0].parentNode.removeChild(e[0]);var i=document.getElementById(this.element.id+"content");i&&this.element.removeChild(i);var r="measureElement";if(window[""+r]){window[""+r].usageCount-=1;var s="measureElementCount";window[""+s]--,0===window[""+s]&&(window[""+r].parentNode.removeChild(window[""+r]),window[""+r]=null)}}window.domTable={};for(var a=0;a1&&(this.callBlazorModel=!1,this.insertBlazorDiagramObjects(this.selectedItems),this.commandHandler.group(),this.callBlazorModel=!0,this.commandHandler.getBlazorOldValues())},t.prototype.unGroup=function(){this.callBlazorModel=!1,this.insertBlazorDiagramObjects(this.selectedItems),this.commandHandler.unGroup(),this.callBlazorModel=!0,this.commandHandler.getBlazorOldValues()},t.prototype.sendToBack=function(){this.commandHandler.sendToBack()},t.prototype.setActiveLayer=function(e){var i=this.commandHandler.getLayer(e);this.activeLayer=i},t.prototype.addLayer=function(e,i){this.commandHandler.addLayer(e,i)},t.prototype.removeLayer=function(e){this.commandHandler.removeLayer(e,ce())},t.prototype.moveObjects=function(e,i){$(this.layers),this.enableServerDataBinding(!1),this.commandHandler.moveObjects(e,i)},t.prototype.layerObjectUpdate=function(){},t.prototype.sendLayerBackward=function(e){this.layerObjectUpdate(),this.commandHandler.sendLayerBackward(e)},t.prototype.bringLayerForward=function(e){this.layerObjectUpdate(),this.commandHandler.bringLayerForward(e)},t.prototype.cloneLayer=function(e){this.commandHandler.cloneLayer(e)},t.prototype.bringToFront=function(){this.commandHandler.bringToFront()},t.prototype.moveForward=function(){this.commandHandler.sendForward()},t.prototype.sendBackward=function(){this.commandHandler.sendBackward()},t.prototype.getObject=function(e){return this.nameTable[""+e]},t.prototype.getNodeObject=function(e){return $(this.nameTable[""+e])},t.prototype.getConnectorObject=function(e){return $(this.nameTable[""+e])},t.prototype.getActiveLayer=function(){return this.activeLayer},t.prototype.nudgeCommand=function(e,i,r){if("object"!=typeof e&&(this.selectedItems.nodes.length||this.selectedItems.connectors.length)>0){var s=void 0;i.type&&"KEYDOWN"===i.type&&(s=i.type),this.nudge(e,void 0,void 0,s)}},t.prototype.nudge=function(e,i,r,s){var o=0,a=0;"Left"===e||"Right"===e?o=("Left"===e?-1:1)*(i||1):a=("Up"===e?-1:1)*(r||1),"KEYDOWN"===s&&(o*=5,a*=5);var h=this.selectedItems,c=this.selectedItems.wrapper.children[0];if(c instanceof si)this.commandHandler.labelDrag(h.nodes[0],c,o,a);else{var d=$(this.selectedItems);this.protectPropertyChange(!0),this.drag(h,o,a),this.protectPropertyChange(!1);var u={type:"PositionChanged",redoObject:$(this.selectedItems),undoObject:d,category:"Internal"};this.addHistoryEntry(u)}this.refreshCanvasLayers()},t.prototype.insertBlazorDiagramObjects=function(e){},t.prototype.drag=function(e,i,r){if(this.insertBlazorDiagramObjects(e),!(this.bpmnModule&&e instanceof te&&this.bpmnModule.updateAnnotationDrag(e,this,i,r))){if(e instanceof oi){if(this.preventConnectorsUpdate=!0,e.nodes&&e.nodes.length){for(var o=0,a=e.nodes;o0&&o.nodes[0].children){this.fromUndo||(this.rotateUsingButton=!0);for(var h=this.commandHandler.getAllDescendants(o.nodes[0],[]),c=0;c0&&o.nodes[0].children){var g={type:"RotationChanged",redoObject:$(e),undoObject:$(o),category:"Internal",childTable:a};this.commandHandler.addHistoryEntry(g),this.commandHandler.updateSelector()}return u},t.prototype.dragSourceEnd=function(e,i,r){this.insertBlazorDiagramObjects(e),this.commandHandler.dragSourceEnd(e,i,r),this.callBlazorModel&&this.commandHandler.getBlazorOldValues()},t.prototype.dragTargetEnd=function(e,i,r){this.insertBlazorDiagramObjects(e),this.commandHandler.dragTargetEnd(e,i,r),this.callBlazorModel&&this.commandHandler.getBlazorOldValues()},t.prototype.findObjectsUnderMouse=function(e,i){return this.eventHandler.findObjectsUnderMouse(e,i)},t.prototype.findObjectUnderMouse=function(e,i,r){return this.eventHandler.findObjectUnderMouse(e,i,r)},t.prototype.findTargetObjectUnderMouse=function(e,i,r,s,o){return this.eventHandler.findTargetUnderMouse(e,i,r,s,o)},t.prototype.findElementUnderMouse=function(e,i,r,s){return this.eventHandler.findElementUnderMouse(e,i,r,s)},t.prototype.findActionToBeDone=function(e,i,r,s){return this.eventHandler.findActionToBeDone(e,i,r,s)},t.prototype.updateConnectorPort=function(e){if(e.ports.length)for(var i=void 0,r=0,s=e.ports;r=0;s--)if(i.push(r[parseInt(s.toString(),10)]),i.length>this.historyManager.stackLimit)return i}else i=r;return i},t.prototype.getEdges=function(e){return e.outEdge?this.nameTable[e.id].outEdges:this.nameTable[e.id].inEdges},t.prototype.getParentId=function(e){return this.nameTable[""+e].parentId},t.prototype.addConnector=function(e){return this.add(e)},t.prototype.UpdateBlazorDiagramModelCollection=function(e,i,r,s){},t.prototype.UpdateBlazorDiagramModel=function(e,i,r,s){},t.prototype.UpdateBlazorLabelOrPortObjects=function(e,i,r,s){},t.prototype.addBlazorDiagramObjects=function(){},t.prototype.removeNodeEdges=function(e,i,r){var s=this.nameTable[""+e],o=r?s.outEdges:s.inEdges;if(o.length>0)for(var a=0;a0)){for(var c=0;c0))}this.removePortEdges(l,a.element.sourcePortID,a.element.id,h)}a.element.targetID&&this.removeNodeEdges(a.element.targetID,a.element.id,!1)}}this.diagramActions=this.diagramActions|ee.PublicMethod,e.id=e.id||Qe();var u=this.activeLayer;if(!a.cancel&&u&&!u.lock){if(u.objects.indexOf(e.id)<0&&!u.lock&&(u.visible||(u.visible=!0,this.dataBind()),u.objects.push(e.id)),fs(e)===de)(r=new de(this,"connectors",e,!0)).status="New",this.nameTable[r.targetID]&&"TextAnnotation"===this.nameTable[r.targetID].shape.shape&&(r.isBpmnAnnotationConnector=!0,r.constraints=r.constraints&~qe.Delete),Ro(r,e,this.connectorDefaults),this.connectors.push(r),this.initObject(r),!1===e.visible&&this.updateElementVisibility(r.wrapper,r,e.visible),this.updateEdges(r),this.insertBlazorConnector(r);else{if(Ro(r=new te(this,"nodes",e,!0),e,this.nodeDefaults),r.parentId=e.parentId?e.parentId:r.parentId,r.umlIndex=e.umlIndex,r.status="New",(o="TextAnnotation"===r.shape.shape)&&!e.isTextAnnotationCopied&&(r.inEdges=e.inEdges?e.inEdges:r.inEdges),this.nodes.push(r),this.initObject(r,u,void 0,i),o&&this.bpmnModule)for(c=0;c-1&&e.parentId&&this.nameTable[e.parentId]&&"UmlClassifier"===this.nameTable[e.parentId].shape.type){var g=this.nameTable[e.parentId];g.children.splice(r.umlIndex,0,r.id),g.wrapper.children.splice(r.umlIndex,0,r.wrapper),g.wrapper.measure(new me),g.wrapper.arrange(g.wrapper.desiredSize),this.updateDiagramObject(g)}}if(a={element:r,cause:this.diagramActions,diagramAction:this.getDiagramAction(this.diagramActions),state:"Changed",type:"Addition",cancel:!1},this.parentObject&&(a.parentId=this.parentObject.id),"helper"!==e.id&&!(this.diagramActions&ee.PreventCollectionChangeOnDragOver)&&this.triggerEvent(Ce.collectionChange,a),!(this.diagramActions&ee.UndoRedo||this.diagramActions&ee.Group||this.diagramActions&ee.PreventHistory)){var v={type:"CollectionChanged",changeType:"Insert",undoObject:$(e),redoObject:$(e),category:"Internal"};this.addHistoryEntry(v)}this.parentObject=void 0,"SVG"===this.mode&&(this.updateSvgNodes(r),this.updateTextElementValue(r),this.updateDiagramObject(r),o&&this.updateDiagramObject(this.nameTable[r.inEdges[0]]),r.shape.activity&&r.shape.activity.subProcess.processes&&r.shape.activity.subProcess.processes.length&&this.updateProcesses(r),this.updateBridging())}}if(this.protectPropertyChange(s),this.resetDiagramActions(ee.PublicMethod),r&&this.layers.length>1&&this.moveNode(r),this.views)for(var S=0,b=this.views;S=0;l--)this.moveSvgNode(a[parseInt(l.toString(),10)])}for(var h=0,c=i;h=0;o--)r[parseInt(o.toString(),10)]===e.id&&r.splice(o,1);for(var a=0;s.ports&&a=0;s--)if(i=this.nameTable[r[parseInt(s.toString(),10)]])if(this.connectorTable[i.id]=$(i),i.isBpmnAnnotationConnector){var o=this.nameTable[i.targetID];this.removeObjectsFromLayer(i);var a=this.connectors.indexOf(i);-1!==a&&this.connectors.splice(a,1),this.removeElements(i),this.removeFromAQuad(i),delete this.nameTable[i.id];var l=this.nameTable[i.sourceID];if(l){var h=l.outEdges.indexOf(i.id);-1!==h&&l.outEdges.splice(h,1)}e.id!==i.targetID&&this.remove(o)}else this.remove(i)},t.prototype.removeObjectsFromLayer=function(e){if(e.children)for(var i=0;i-1&&(_r(this,e)&&this.unSelect(e),this.layers[parseInt(s.toString(),10)].objects.splice(a,1),delete this.layers[parseInt(s.toString(),10)].zIndexTable[this.nameTable[e.id].zIndex])},t.prototype.removeElements=function(e){if("SVG"===this.mode||"Canvas"===this.mode&&"Native"===e.shape.type){var i=xt(e.id+"_groupElement",this.element.id),r=e;if(r.ports&&r.ports.length>0)for(var s=0;s0){l[parseInt(s.toString(),10)].id.indexOf("icon_content")>0&&"SVG"===this.mode&&((h=xt(l[parseInt(s.toString(),10)].id+"_shape_groupElement",this.element.id))&&h.parentNode.removeChild(h),(h=xt(l[parseInt(s.toString(),10)].id+"_rect_groupElement",this.element.id))&&h.parentNode.removeChild(h));for(var c=0,d=this.views;c=0;o--)a.children[parseInt(o.toString(),10)].children&&(l=n.nameTable[a.children[parseInt(o.toString(),10)].id])&&(l.isLane?qv(n,l):(n.removeDependentConnector(l),n.diagramActions|=ee.PreventHistory,l.constraints&ie.Delete?n.remove(l):V3(n,l,{},!1),n.diagramActions&=~ee.PreventHistory));a&&(i=n.nameTable[a.id])&&qv(n,i)}}(this,e),!(this.diagramActions&ee.UndoRedo||this.diagramActions&ee.PreventHistory)&&(e instanceof te||e instanceof de)){var o={type:"CollectionChanged",changeType:"Remove",undoObject:$(e),redoObject:$(e),category:"Internal"};this.diagramActions&ee.Clear||e.children&&!e.isLane&&!e.isPhase&&e.children.length>0&&this.undoRedoModule&&"None"===this.layout.type&&(this.historyManager.startGroupAction(),s=!0),(e instanceof te||e instanceof de)&&this.deleteDependentConnector&&this.removeDependentConnector(e),!e.isLane&&!e.isPhase&&!(this.diagramActions&ee.Clear)&&!this.isStackChild(e)&&this.addHistoryEntry(o)}"TextAnnotation"===e.shape.shape&&this.removeDependentConnector(e),e.children&&!e.isLane&&!e.isPhase&&(!(this.diagramActions&ee.UndoRedo)||!ce())&&this.deleteGroup(e),e.parentId&&(this.deleteChild(e,void 0,!0),this.nameTable[e.parentId]&&"UmlClassifier"===this.nameTable[e.parentId].shape.type&&(this.updateDiagramObject(this.nameTable[e.parentId]),this.updateConnectorEdges(this.nameTable[e.parentId])));var a=void 0;this.diagramActions=this.diagramActions|ee.PublicMethod;var l=this.nameTable[e.id];if(l instanceof te?("Bpmn"===l.shape.type&&this.bpmnModule&&this.bpmnModule.removeBpmnProcesses(l,this),(l.isLane||l.isPhase||"SwimLane"===l.shape.type)&&(h=l.isLane||l.isPhase?this.nameTable[l.parentId]:this.nameTable[l.id],l.isLane?_3(this,l,h):l.isPhase&&U3(this,l,h)),-1!==(a=this.nodes.indexOf(l))&&(this.crudDeleteNodes.push(this.nameTable[l.id]),this.nodes.splice(a,1),this.updateNodeEdges(l))):(-1!==(a=this.connectors.indexOf(l))&&(this.crudDeleteNodes.push(this.nameTable[l.id]),this.connectors.splice(a,1)),this.updateEdges(l),this.spliceConnectorEdges(e,!0),this.spliceConnectorEdges(e,!1)),!this.isServerUpdate&&!(this.blazorActions&on.GroupClipboardInProcess)&&this.commandHandler.getBlazorOldValues(),s&&this.historyManager.endGroupAction(),_r(this,l)&&this.unSelect(l),!l.isPhase){if(this.removeObjectsFromLayer(e),this.currentDrawingObject&&(this.currentDrawingObject.wrapper=void 0),delete this.nameTable[e.id],i.length>0&&i[0].id===l.id&&l.parentId){var h,d=this.nameTable[l.parentId];d&&d.isLane&&"SwimLane"===this.nameTable[d.parentId].shape.type&&F3(this,h=this.nameTable[d.parentId],d,l)}this.removeElements(l),this.updateBridging(),"SVG"!==this.mode&&this.refreshDiagramLayer(),this.diagramActions&ee.Clear||(this.removeFromAQuad(l),r={element:e,cause:this.diagramActions,diagramAction:this.getDiagramAction(this.diagramActions),state:"Changed",type:"Removal",cancel:!1},"helper"!==e.id&&this.triggerEvent(Ce.collectionChange,r),this.resetTool())}}}else if(i.length>0){this.undoRedoModule&&(this.historyManager.startGroupAction(),this.blazorActions|=on.GroupingInProgress,s=!0);for(var u=0;u=f.wrapper.bounds.width&&"Horizontal"===f.shape.orientation||this.selectedItems.wrapper.bounds.y<=f.wrapper.bounds.y+g&&this.selectedItems.wrapper.bounds.height>=f.wrapper.bounds.height-g&&"Vertical"===f.shape.orientation)&&(DI(f)||f.shape.lanes.length>1)&&this.remove(i[parseInt(u.toString(),10)])}}else this.remove(i[parseInt(u.toString(),10)])}s&&(this.blazorActions&=~on.GroupingInProgress,this.isServerUpdate=!0,this.commandHandler.getBlazorOldValues(),this.UpdateBlazorDiagramModelCollection(void 0,void 0,void 0,!0),this.historyManager.endGroupAction(),this.isServerUpdate=!1),this.clearSelection()}e&&(DI(e)||this.diagramActions&ee.Clear)||this.diagramActions&ee.UndoRedo||this.diagramActions&ee.PreventHistory||!(e instanceof te||e instanceof de)||(o={type:"ConnectionChanged",undoObject:$(e),redoObject:$(e),category:"Internal"},!e.isLane&&!e.isPhase&&!(this.diagramActions&ee.Clear)&&!this.isStackChild(e)&&this.addHistoryEntry(o)),this.tooltipObject.close()},t.prototype.isStackChild=function(e){var i,r=this.nameTable[e.parentId];if(e&&e.parentId&&r.container&&"Stack"===r.container.type&&"UmlClassifier"!==this.nameTable[e.parentId].shape.type){i=!0;var s={sourceIndex:r.wrapper.children.indexOf(e.wrapper),source:e,target:void 0,targetIndex:void 0};this.diagramActions&ee.UndoRedo||this.addHistoryEntry({type:"StackChildPositionChanged",redoObject:{sourceIndex:void 0,source:e,target:void 0,targetIndex:void 0},undoObject:s,category:"Internal"})}return i},t.prototype.deleteChild=function(e,i,r){var s;if(s="string"==typeof e?e:e.id,(i=i?this.nameTable[i.id]:this.nameTable[e.parentId])&&i.children){for(var o=0;o=0;i--)this.removeLayer(this.layers[parseInt(i.toString(),10)].id);this.commandHandler.addLayer({id:"default_layer",visible:!0,lock:!1,objects:[],zIndex:0,objectZIndex:-1,zIndexTable:{}},null,!0),this.setActiveLayer(this.layers[this.layers.length-1].id)},t.prototype.clearObjects=function(e){var i=[];i=e||(i=i.concat(this.nodes)).concat(this.connectors),this.diagramActions=this.diagramActions|ee.Clear;for(var r=0,s=i;r0||"Text"===e.shape.type))if("Text"===e.shape.type)i=e.wrapper.children[0].id.split("_")[1];else for(var f=e.annotations.length-1;f>=0;f--)e.annotations[parseInt(f.toString(),10)].visibility&&(i=e.annotations[parseInt(f.toString(),10)].id);i&&(u=this.getWrapper(e.wrapper,i))}if(e&&u&&!(u instanceof Jn)&&(!function Xre(n,t){return"Text"===t.shape.type?t.constraints&ie.ReadOnly:t.constraints&(t instanceof de?qe.ReadOnly:ie.ReadOnly)?n.constraints&Lr.InheritReadOnly?1:0:n.constraints&Lr.ReadOnly?1:0}(u,e)||p)){var g=u.style,v=void 0;v=90>(v=u.bounds.width50?50:e.width,u.style.fontSize)),e.parentId&&"UmlClassifier"===this.nameTable[e.parentId].shape.type?(l.width=e.wrapper.bounds.width-20,c=(e.wrapper.bounds.center.x+r.tx)*r.scale-l.width/2*s-2.5,d=(e.wrapper.bounds.center.y+r.ty)*r.scale-l.height/2*s-3,u.style.textAlign="Left"):(l.width=Math.max(l.width,50),c=(u.bounds.center.x+r.tx)*r.scale-l.width/2*s-2.5,d=(u.bounds.center.y+r.ty)*r.scale-l.height/2*s-3),Ho(y,{id:this.element.id+"_editTextBoxDiv",style:"position: absolute;left:"+c+"px;top:"+d+"px;width:"+(l.width+1)*s+"px;height:"+l.height*s+"px; containerName:"+e.id+";"}),Ho(S,{"aria-label":a,id:this.element.id+"_editBox",style:"width:"+(l.width+1)*s+"px;height:"+l.height*s+"px;resize: none;outline: none;overflow: hidden;;font-family:"+g.fontFamily+";font-size:"+g.fontSize*s+"px;text-align:"+u.style.textAlign.toLocaleLowerCase()+";",class:"e-diagram-text-edit"}),S.style.fontWeight=g.bold?"bold":"",S.style.fontStyle=g.italic?"italic":"",S.style.lineHeight=(1.2*g.fontSize+"px;").toString(),S.style.textDecoration=g.textDecoration?g.textDecoration:"",this.activeLabel.parentId=e.id,this.activeLabel.id=i,u.visible=!1,this.updateDiagramObject(e),this.diagramActions=this.diagramActions|ee.TextEdit,this.isTriggerEvent||(E.add(S,"input",this.eventHandler.inputChange,this.eventHandler),E.add(S,"focusout",this.focusOutEdit,this),S.select())}}}},t.prototype.updateConnectorfixedUserHandles=function(e){if(e.fixedUserHandles.length)for(var i=void 0,r=0,s=e.fixedUserHandles;r0&&this.mindMapChartModule.updateLayout(o,this.nameTable,this.layout,l,this.dataSourceSettings.id,this.dataSourceSettings.root),e=!0;else if(this.radialTreeModule)this.radialTreeModule.updateLayout(o,this.nameTable,this.layout,l),e=!0;else if(this.symmetricalLayoutModule)this.symmetricalLayoutModule.maxIteration=this.layout.maxIteration,this.symmetricalLayoutModule.springLength=this.layout.springLength,this.symmetricalLayoutModule.springFactor=this.layout.springFactor,this.symmetricalLayoutModule.updateLayout(o,this.connectors,this.symmetricalLayoutModule,this.nameTable,this.layout,l),e=!0;else if(this.complexHierarchicalTreeModule){this.canDistribute(a,r)&&(this.lineDistributionModule.diagram=this,this.connectors.forEach(function(R){R.obstaclePointCollection=[]}));var c=this.complexHierarchicalTreeModule.getLayoutNodesCollection(this.nodes);c.length>0&&this.complexHierarchicalTreeModule.doLayout(c,this.nameTable,this.layout,l,this),e=!0,this.canDistribute(a,r)&&this.lineDistributionModule.initLineDistribution(this.layout,this)}else this.flowchartLayoutModule?(this.flowchartLayoutModule.updateLayout(this.nodes,this),e=!0):console.warn("[WARNING] :: Module "+("OrganizationalChart"===this.layout.type?"HierarchicalTree":this.layout.type)+" is not available in Diagram component! You either misspelled the module name or forgot to load it.");if(e){this.preventDiagramUpdate=!0;for(var u={},f=0,g=o;f0)for(var S=0;S0)for(var M=0;M0)for(var s=0,o=r.ports;s0&&function Ese(n){var t,e,i,r=[];for(t=0;t0&&y.connectors[w].bezierSettings&&y.connectors[w].bezierSettings.allowSegmentsReset&&(y.connectors[w].segments=[]);if(t.connectors=y.connectors||[],t.dataSourceSettings=y.dataSourceSettings||{},t.dataSourceSettings.doBinding=i,t.height=y.height||"100%",t.setNodeTemplate=r,t.getConnectorDefaults=v,t.getNodeDefaults=g,t.getCustomProperty=o,t.mode=y.mode||"SVG",y.nodes)for(w=0;w0)){var r=this.nodes.filter(function(a){return 0===a.inEdges.length})[0],s=this.convertMindmapToMermaid(r,0);i.push(s),this.updateTextDataSource(i,r.outEdges,1),e=(i=i.filter(function(a){return""!==a.trim()})).join("\n")}return e},t.prototype.updateTextDataSource=function(e,i,r){for(var s=0;s0&&this.updateTextDataSource(e,h,r+1),s++}},t.prototype.convertMindmapToMermaid=function(e,i){var r=e.id,o=" ".repeat(2*(i+1)),a=e.annotations.length>0?e.annotations[0].content.replace(/\n/g," "):"",l=o+a,h=o+r;if(e.shape&&"Basic"===e.shape.type){var c=e.shape;"Rectangle"===c.shape?l=h+"["+a+"]":"Ellipse"===c.shape?l=h+"(("+a+"))":"Hexagon"===c.shape&&(l=h+"{{"+a+"}}")}else if(e.shape&&"Flow"===e.shape.type)"Terminator"===e.shape.shape&&(l=h+"("+a+")");else if(e.shape&&"Path"===e.shape.type){var u=e.shape;u.data===this.bangShape?l=h+"))"+a+"((":u.data===this.cloudShape&&(l=h+")"+a+"(")}return l},t.prototype.saveFlowDiagramInMermaidFormat=function(){var e=this,i=[],r="graph TD\n",s={nodes:this.nodes,edges:this.connectors};return s.nodes.reduce(function(a,l){return a[l.id]=l.annotations.length?l.annotations[0].content:"",a},{}),s.edges.forEach(function(a){var l=a.sourceID,h=a.targetID,p=e.nameTable[""+h],f=e.getNodeShape(e.nameTable[""+l]),g=e.getNodeShape(p),v=a.annotations[0]&&""!==a.annotations[0].content?"|"+a.annotations[0].content+"|":"";-1===i.indexOf(l)?i.push(l):f="",-1===i.indexOf(h)?i.push(h):g="";var y=e.arrowType(a);r+=" "+l+f+" "+y+v+" "+h+g+"\n"}),s.nodes.forEach(function(a){r+=" style "+a.id+" fill:"+a.style.fill+",stroke:"+a.style.strokeColor+",stroke-width:"+a.style.strokeWidth+"px;\n"}),r},t.prototype.arrowType=function(e){var i=e.targetDecorator.shape;return e.style.opacity<1?"~~~":""!==e.style.strokeDashArray?"-.->":"Arrow"===i?e.style.strokeWidth>1?"==>":"--\x3e":"None"===i?"---":"--\x3e"},t.prototype.getNodeShape=function(e){var i=e.annotations.length>0?e.annotations[0].content:"",r=e.shape.shape;if(!r){var s=e.shape.data;return"M 0 0 A 1 1 0 0 0 7 0 A 1 1 0 0 0 0 0 M -1 0 A 1 1 0 0 0 8 0 A 1 1 0 0 0 -1 0"===s?"((("+i+")))":"M 0 0 L 1 -1 L 5 -1 L 6 0 L 0 0"===s?"[/"+i+"\\]":"M 0 1 L 0 6 C 2 7 4 7 6 6 L 6 1 C 5 0 1 0 0 1 C 1 2 5 2 6 1"===s?"[("+i+")]":"M 0 0 L 12 0 L 14 2 L 2 2 L 0 0"===s?"[\\"+i+"\\]":"M 0 0 L 5 0 L 4 1 L 1 1 L 0 0"===s?"[\\"+i+"/]":"M 0 0 L 2 -2 L 11 -2 L 13 0 L 11 2 L 2 2 L 0 0"===s?"{{"+i+"}}":">"+i+"]"}switch(r){case"Terminator":return"(["+i+"])";case"Process":default:return"["+i+"]";case"Decision":return"{"+i+"}";case"Parallelogram":return"[/"+i+"/]";case"Ellipse":return"(("+i+"))";case"PreDefinedProcess":return"[["+i+"]]"}},t.prototype.loadDiagramFromMermaid=function(e){this.layout&&"Flowchart"===this.layout.type&&this.flowchartLayoutModule?this.convertMermaidToFlowChart(e):this.layout&&"MindMap"===this.layout.type&&this.mindMapChartModule?this.convertMermaidToMindmap(e):console.warn('[WARNING] :: Module "FlowchartLayout" or "MindMap" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.countLeadingSpaces=function(e){for(var i=0,r=e.length;i0});this.clear(),this.mermaidNodeBaseCollection=[];var r=[],s={text:"",children:[],currentLevel:0,branch:"Left"},o=[],l=!1,h=!1,c=!1;if(i.length>0){for(var d=function(M){var w=i[parseInt(M.toString(),10)],C=0,D="",A=u.countLeadingSpaces(w),x=w.includes('"`');if(h=w.includes('`"'),c=(l=!!x||l)||c?c:0===A&&M>0,l&&h&&!x)return s.text+="\n"+w,l=!1,"continue";if(!x&&l)return s.text+="\n"+w,"continue";if(l=!h&&l,w.length>0&&(/\s/.test(w[0])&&M>0||0===A)){if(-1!==o.findIndex(function(B){return B.space===A.toString()}))for(var L=o.length-1;L>=0;L--){var O=o[parseInt(L.toString(),10)];if((N=parseFloat(O.space))>A)o.splice(L,1);else{if(N=0;L--){var N,T=o[parseInt(L.toString(),10)];if(!((N=parseFloat(T.space))>A)){var P=o[o.length-1];o.push({space:A.toString(),level:P.level+1});break}o.splice(L,1)}C=o[o.length-1].level}D=w.trim().replace(/^[+-]/,"")}var _={text:D,branch:void 0,children:[],currentLevel:0===M?0:C-1};if(r.length>0){for(;r.length>=C&&0!==r.length;)r.pop();r.length>0&&r[r.length-1].children.push(_)}r.push(_),s=_},u=this,p=0;p0){var c=h[h.length-1];c.arrowType=a[2],""!==a[3]&&(c.label&&c.label.some(function(d){return d.trim().length>0})?c.label.push(a[3]):(c.label=[],c.label[c.parentId.length-1]=a[3]))}h.filter(function(d){return d.parentId&&0===d.parentId.length}).forEach(function(d){d.parentId=null}),i=i.concat(h)}}this.createFlowChart(i),this.doLayout(),this.clearHistory()},t.prototype.createFlowChart=function(e){for(var i=[],r=0;r1)for(var h=0;h|---|--\s*.*?\s*-->|~~~|==>|===|==\s*.*?\s*==>|\s*-\.\s*->|\s*-\.\s*-|\s*-\.\s*.*?\s*\.\s*->|\s*-\..*?\.\s*->)(.*)$/);if(l){i=l[1].trim();var h=l[2].trim();r=l[3].trim();var d=h.match(/(-\.|\\-\\-|==|--|~~)(.*?)(\1>|\.->|==>|\\->|~~>)/),u=void 0,p="";o=null!==(u=d?{text:d[2].trim()||null,arrowType:d[1]+d[3]}:{text:null,arrowType:h}).text?u.text:"",s=(p=u.arrowType).includes("--\x3e")?"single-line-arrow":p.includes("---")?"single-line":p.includes("==>")?"double-line-arrow":p.includes("==")?"double-line":p.includes("~~~")?"wiggly-arrow":p.includes("-.->")||p.includes(".->")?"dotted-arrow":p.includes("-.-")||p.includes(".-")?"dotted":"single-line-arrow"}return[i,r,s,o]},t.prototype.parseStyle=function(e,i){if(e.startsWith("style")){var s=e.match(/^style\s+(\w+)\s+fill:([^,]+),stroke:([^,]+),stroke-width:(\d+)px;/);if(s){var c={id:s[1],fill:s[2],stroke:s[3],strokeWidth:parseInt(s[4],10)},d=i.filter(function(u){return u.id===c.id});d[0].color=c.fill,d[0].stroke=c.stroke,d[0].strokeWidth=c.strokeWidth}}},t.prototype.getNodeData=function(e,i,r){for(var s=[],o=null,a=null,l=0,h="",c=function(v){var y=e[parseInt(v.toString(),10)],S=d.splitNested(y);if(S[0].includes("|")){var b=S[0].match(/\|([^|]*)\|/);b&&(h=b[1]);var M=S[0].split("|");M.length>=3&&(S[0]=M[2].trim())}var w=S[0].trim();if(0===v?o=w:a=w,i.find(function(L){return L.id===w}))l++;else{var D=S.length>1?S[1]:S[0],A=d.getShape(D),x=D.replace(/[\\[\]\\(\\)\\{\\}\\{\\}\\/>]/g,"");s.push({id:w,name:x,shape:A,color:"white",parentId:[]})}},d=this,u=0;u"===h?0===s?(r.trim().length>0&&i.push(r.trim()),r=h,o=h,s++):(r+=h,s++):"]"===h||"}"===h||")"===h?1===s&&h===o?(i.push((r+=h).trim()),r="",s--):s>1?(r+=h,s--):r+=h:r+=h}return r.trim().length>0&&i.push(r.trim()),i},t.prototype.getShape=function(e){var i={};return e.startsWith("(((")?i={type:"Path",data:"M 0 0 A 1 1 0 0 0 7 0 A 1 1 0 0 0 0 0 M -1 0 A 1 1 0 0 0 8 0 A 1 1 0 0 0 -1 0"}:e.startsWith("((")?i={shape:"Ellipse",type:"Basic"}:e.startsWith("([")?i={type:"Flow",shape:"Terminator"}:e.startsWith("(")?i={type:"Flow",shape:"Process"}:e.startsWith("[[")?i={type:"Flow",shape:"PreDefinedProcess"}:e.startsWith("[/")?i=e.endsWith("/]")?{type:"Basic",shape:"Parallelogram"}:{type:"Path",data:"M 0 0 L 1 -1 L 5 -1 L 6 0 L 0 0"}:e.startsWith("[(")?i={type:"Path",data:"M 0 1 L 0 6 C 2 7 4 7 6 6 L 6 1 C 5 0 1 0 0 1 C 1 2 5 2 6 1"}:e.startsWith("[\\")?i=e.endsWith("\\]")?{type:"Path",data:"M 0 0 L 12 0 L 14 2 L 2 2 L 0 0"}:{type:"Path",data:"M 0 0 L 5 0 L 4 1 L 1 1 L 0 0"}:e.startsWith("[")?i={type:"Basic",shape:"Rectangle"}:e.startsWith("{{")?i={type:"Path",data:"M 0 0 L 2 -2 L 11 -2 L 13 0 L 11 2 L 2 2 L 0 0"}:e.startsWith("{")?i={type:"Flow",shape:"Decision"}:e.startsWith(">")&&(i={type:"Path",data:"M 0 0 L 8 0 L 8 2 L 0 2 L 2 1 L 0 0"}),i},t.prototype.getDiagramContent=function(e){return this.printandExportModule?this.printandExportModule.getDiagramContent(e):(console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),"")},t.prototype.exportImage=function(e,i){this.printandExportModule?this.printandExportModule.exportImages(e,i):console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.printImage=function(e,i){this.printandExportModule?(i.printOptions=!0,this.printandExportModule.exportImages(e,i)):console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.setStackLimit=function(e){this.undoRedoModule&&e&&(this.historyManager.stackLimit=e,this.undoRedoModule.applyLimit(this.historyManager.currentEntry,e,this,!0))},t.prototype.clearHistory=function(){this.undoRedoModule&&this.undoRedoModule.clearHistory(this)},t.prototype.getDiagramBounds=function(){if(this.printandExportModule){var e=this.printandExportModule.getDiagramBounds("",{});return e.width=e.width>this.scrollSettings.viewPortWidth?e.width+(e.x>0?e.x:0):this.scrollSettings.viewPortWidth,e.height=e.height>this.scrollSettings.viewPortHeight?e.height+(e.y>0?e.y:0):this.scrollSettings.viewPortHeight,e.x=e.x>0?0:e.x,e.y=e.y>0?0:e.y,e}return console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),new Ne},t.prototype.exportDiagram=function(e){return this.printandExportModule?this.printandExportModule.exportDiagram(e):(console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),"")},t.prototype.print=function(e){this.printandExportModule?this.printandExportModule.print(e):console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.addPorts=function(e,i){var s;this.protectPropertyChange(!0),e=this.nameTable[e.id]||e,i.length>1&&this.startGroupAction();for(var o=function(h){if(e.ports.some(function(y){return y.id===i[parseInt(h.toString(),10)].id}))return"continue";if(e instanceof te?(s=new Es(e,"ports",i[parseInt(h.toString(),10)],!0),e.ports.push(s)):e instanceof de&&(s=new xc(e,"ports",i[parseInt(h.toString(),10)],!0),e.ports.push(s)),e.children)for(var c=e.wrapper,d=0;d1&&this.endGroupAction(),e.wrapper.measure(new me(e.width,e.height)),e.wrapper.arrange(e.wrapper.desiredSize),this.updateDiagramObject(e),this.protectPropertyChange(!1)},t.prototype.addConstraints=function(e,i){return e|i},t.prototype.removeConstraints=function(e,i){return e&~i},t.prototype.addNodeLabels=function(e,i){this.addLabels(e,i)},t.prototype.addConnectorLabels=function(e,i){this.addLabels(e,i)},t.prototype.addLabels=function(e,i){this.protectPropertyChange(!0);var s,r=(e=this.nameTable[e.id]||e).wrapper;i.length>1&&this.startGroupAction();for(var o=0;o1&&this.endGroupAction(),e.wrapper.measure(new me(r.width,r.height)),e.wrapper.arrange(r.desiredSize),this.updateDiagramObject(e),this.protectPropertyChange(!1),this.refreshCanvasLayers()},t.prototype.addChildToUmlNode=function(e,i,r){var s,o,a,l,h="NoWrap";"Class"===e.shape.classifier||"Interface"===e.shape.classifier?"Method"===r?(o=new hm(e,"",i),"Class"===e.shape.classifier?(e.shape.classShape.methods.push(o),s=e.shape.classShape):"Interface"===e.shape.classifier&&(e.shape.interfaceShape.methods.push(o),s=e.shape.interfaceShape),function Xse(n,t,e,i){if(e.methods&&e.methods.length){var r=e.methods,s="",o="",a=void 0,l=1,h=void 0,c=0,d=0,u=n.shape,g="Class"===u.classifier?u.classShape:u.interfaceShape;1===r.length?g.attributes.length>0?(c=g.attributes.filter(function(w){return w.isSeparator}).length,h=(l=2+g.attributes.length+c)+1,nT(n,t,l)):h=l+1:(c=g.attributes.filter(function(w){return w.isSeparator}).length,d=g.methods.filter(function(w){return w.isSeparator}).length,h=(l=2+g.attributes.length+c+g.methods.length+d)+1);for(var v=0;v1&&this.startGroupAction();for(var r=i.length-1;r>=0;r--)if(e.children&&e.children.length>0){var s=e.wrapper.children.filter(function(o){return o.id===e.id+"group_container"});s&&s.length>0&&this.removelabelExtension(e,i,r,s[0])}else this.removelabelExtension(e,i,r,e.wrapper);i.length>1&&this.endGroupAction(),this.refreshCanvasLayers()},t.prototype.removePortsExtenion=function(e,i,r,s){for(var o=0;o1&&this.startGroupAction();for(var r=i.length-1;r>=0;r--)if(e.children&&e.children.length>0)for(var s=0;s1&&this.endGroupAction()},t.prototype.getSizeValue=function(e,i){var r;return r=e.toString().indexOf("px")>0?e.toString():e.toString().indexOf("%")>0?void 0!==i?"100%":e.toString():e.toString()+"px",i&&(qa(this),r="calc("+r+" - "+i+"px)"),r},t.prototype.renderRulers=function(){this.rulerSettings.showRulers?(function Yne(n){var t=qa(n),i=Tt("div",{id:n.element.id+"_overlapRuler",style:"height:"+t.height+"px;width:"+t.width+"px;position:absolute;left:0;top:0",class:"e-ruler-overlap"});n.element.insertBefore(i,n.element.firstChild)}(this),eF(this,!0),eF(this,!1)):Qx(this)},t.prototype.intOffPageBackground=function(){var e=new me;e=qa(this);var i=document.getElementById(this.element.id+"content"),r=this.getSizeValue(this.width,e.width),s=this.getSizeValue(this.height,e.height),o=this.rulerSettings.showRulers?"width:"+r+"; height:"+s+";top:"+e.height+"px;left:"+e.width+"px;overflow: scroll;position:absolute;overflow:auto;":"width:"+r+"; height:"+s+";position:absolute; left:0px; top:0px;overflow: auto;",a={id:this.element.id+"content",tabindex:"0",style:o};i?(this.diagramCanvas=i,Za(this.diagramCanvas,o)):(this.diagramCanvas=Tt("div",a),this.element.appendChild(this.diagramCanvas)),this.diagramCanvas.style.background=this.backgroundColor},t.prototype.initDiagram=function(){this.intOffPageBackground(),Ho(this.element,{style:"width:"+this.getSizeValue(this.width)+"; height:"+this.getSizeValue(this.height)+";position:relative;overflow:hidden;"})},t.prototype.renderHiddenUserHandleTemplateLayer=function(e){var r=Tt("div",{class:this.element.id+"_hiddenUserHandleTemplate",style:"width:"+e.width+"px; height:"+e.height+"px;visibility:hidden ; overflow: hidden;"});this.element.appendChild(r)},t.prototype.renderBackgroundLayer=function(e,i){var r=this.createSvg(this.element.id+"_backgroundLayer_svg",e.width,e.height);Za(r,i);var s=Bi("g",{id:this.element.id+"_backgroundImageLayer",class:"e-background-image-layer"});r.appendChild(s);var a=Bi("g",{id:this.element.id+"_backgroundLayer",class:"e-background-layer"});r.appendChild(a),this.diagramCanvas.appendChild(r)},t.prototype.renderGridLayer=function(e,i){var r=this.createSvg(this.element.id+"_gridline_svg",e.width,e.height);r.setAttribute("class","e-grid-layer");var s=Bi("g",{id:this.element.id+"_gridline"}),o=Bi("rect",{id:this.element.id+"_grid_rect",x:"0",y:"0",width:"100%",height:"100%"});if(nm()){var a=new URL(window.location.href);o.setAttribute("fill",""!==a.search?"url(#"+this.element.id+"_pattern)":"url("+location.protocol+"//"+location.host+location.pathname+"#"+this.element.id+"_pattern)")}else o.setAttribute("fill","url(#"+this.element.id+"_pattern)");s.appendChild(o),r.appendChild(s),this.diagramCanvas.appendChild(r),ai(r,{style:i})},t.prototype.renderDiagramLayer=function(e,i){if(this.diagramLayerDiv=Tt("div",{id:this.element.id+"_diagramLayer_div",style:"width:"+e.width+"px; height:"+e.height+"px;"+i}),"SVG"===this.mode){var s=this.createSvg(this.element.id+"_diagramLayer_svg",e.width,e.height);s.style["pointer-events"]="none",s.setAttribute("class","e-diagram-layer");var o=Bi("g",{id:this.element.id+"_diagramLayer"}),a=Bi("g",{});this.diagramLayer=o,s.style["pointer-events"]="all",a.appendChild(o),s.appendChild(a),this.diagramLayerDiv.appendChild(s)}else this.diagramLayer=bo.createCanvas(this.element.id+"_diagram",e.width,e.height),Za(this.diagramLayer,"position:absolute;left:0px;top:0px;"),this.diagramLayerDiv.appendChild(this.diagramLayer);this.diagramCanvas.appendChild(this.diagramLayerDiv)},t.prototype.initLayers=function(){var e="position:absolute;top:0px;left:0px;overflow:hidden;pointer-events:none;",r=document.getElementById(this.element.id).getBoundingClientRect(),s=function Soe(){var n=Tt("div",{style:"visibility:hidden; width: 100px"});document.body.appendChild(n);var t=n.getBoundingClientRect().width;n.style.overflow="scroll";var e=Tt("div",{style:"width:100%"});n.appendChild(e);var i=e.getBoundingClientRect().width;return n.parentNode.removeChild(n),t-i}();this.scroller.scrollerWidth=s,this.scroller.setViewPortSize(r.width,r.height),this.renderRulers();var o="measureElement";window[""+o]&&(window[""+o]=null,document.getElementById("measureElement").remove()),function BF(){var n="measureElement";if(window[""+n])window[""+n].usageCount+=1;else{var t=Tt("div",{id:"measureElement",style:"visibility:hidden ; height: 0px ; width: 0px; overflow: hidden;"}),e=Tt("span",{style:"display:inline-block ; line-height: normal"});t.appendChild(e);var i=Tt("img",{alt:"measureElementImage",src:"data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7"});t.appendChild(i);var r=document.createElementNS("http://www.w3.org/2000/svg","svg");r.setAttribute("xmlns:xlink","http://www.w3.org/1999/xlink"),t.appendChild(r);var s=document.createElementNS("http://www.w3.org/2000/svg","path");s.setAttribute("d",""),r.appendChild(s),document.createTextNode("");var a=document.createElementNS("http://www.w3.org/2000/svg","text");a.setAttributeNS("http://www.w3.org/XML/1998/namespace","xml:space","preserve"),r.appendChild(a),window[""+n]=t,window[""+n].usageCount=1,document.body.appendChild(t);var l="measureElementCount";window[""+l]?window[""+l]++:window[""+l]=1}}(),this.renderBackgroundLayer(r,e),this.renderGridLayer(r,e),this.renderDiagramLayer(r,e),this.renderHTMLLayer(r,e),this.renderPortsExpandLayer(r,e),this.renderNativeLayer(r,e),this.renderAdornerLayer(r,e),this.renderHiddenUserHandleTemplateLayer(r)},t.prototype.renderAdornerLayer=function(e,i){var r=Tt("div",{id:this.element.id+"_diagramAdornerLayer",style:"width:"+e.width+"px;height:"+e.height+"px;"+i}),s=Tt("div",{id:this.element.id+"_diagramUserHandleLayer",style:"width:"+e.width+"px;height:"+e.height+"px;"+i});s.setAttribute("class","e-userHandle-layer"),r.appendChild(s);var o=this.createSvg(this.element.id+"_diagramAdorner_svg",e.width,e.height);o.setAttribute("class","e-adorner-layer"),o.style["pointer-events"]="none",this.adornerLayer=Bi("g",{id:this.element.id+"_diagramAdorner"}),this.adornerLayer.style[" pointer-events"]="all",o.appendChild(this.adornerLayer),r.appendChild(o),this.diagramCanvas.appendChild(r);var a=Bi("g",{id:this.element.id+"_SelectorElement"});this.adornerLayer.appendChild(a),ai(o,{style:"pointer-events:none;"})},t.prototype.renderPortsExpandLayer=function(e,i){var r=this.createSvg(this.element.id+"_diagramPorts_svg",e.width,e.height);r.setAttribute("class","e-ports-expand-layer");var s=Bi("g",{id:this.element.id+"_diagramPorts",class:"e-ports-layer",style:"pointer-events: all;"});r.appendChild(s);var o=Bi("g",{id:this.element.id+"_diagramExpander",class:"e-expand-layer",style:"pointer-events: all;"});r.appendChild(o),this.diagramCanvas.appendChild(r),ai(r,{style:i})},t.prototype.renderHTMLLayer=function(e,i){this.htmlLayer=Tt("div",{id:this.element.id+"_htmlLayer",style:"width:"+e.width+"px; height:"+e.height+"px;position:absolute;top:0px;left:0px;overflow:hidden;pointer-events:none;",class:"e-html-layer"});var r=Tt("div",{id:this.element.id+"_htmlLayer_div",style:"position:absolute;top:0px;left:0px;pointer-events:all;"});this.htmlLayer.appendChild(r),this.diagramCanvas.appendChild(this.htmlLayer)},t.prototype.renderNativeLayer=function(e,i){var r=this.createSvg(this.element.id+"_nativeLayer_svg",e.width,e.height),s=Bi("g",{id:this.element.id+"_nativeLayer",style:"pointer-events:all;"});r.appendChild(s),this.diagramLayerDiv.appendChild(r),ai(r,{class:"e-native-layer",style:i})},t.prototype.createSvg=function(e,i,r){var s=document.createElementNS("http://www.w3.org/2000/svg","svg");return ai(s,{id:e,width:i,height:r}),s},t.prototype.updateBazorShape=function(){for(var e=0;e1,i=[],r={},s={},o=[],a=0,l=this.nodes;a0||b&&b.children&&b.children.length>0)&&(M=!1),S&&S.wrapper&&b&&b.wrapper&&M?this.initConnectors(r[""+h],f):i.push(r[""+h])}else b=r[y.targetID],(S=r[y.sourceID])&&S.children&&S.children.length>0||b&&b.children&&b.children.length>0?i.push(r[""+h]):this.initConnectors(r[""+h],f);else r[""+h].children?o.push(h):r[""+h].shape instanceof hT&&r[""+h].shape.activity.subProcess.processes&&r[""+h].shape.activity.subProcess.processes.length>0?s[r[""+h].id]=h:this.initNodes(r[""+h],f);if(this.bpmnModule)for(var w=0,C=this.bpmnModule.bpmnTextAnnotationConnector;w-1&&-1===r.indexOf(c)&&-1===s.indexOf(c)&&r.splice(0,0,c);-1===r.indexOf(o)&&s.push(o)}return r.concat(s)},t.prototype.addToLayer=function(e,i){var r;if(i&&(r=this.commandHandler.getObjectLayer(e.id)),(!i||!r)&&-1===this.activeLayer.objects.indexOf(e.id)&&this.activeLayer.objects.push(e.id),(e instanceof te||e instanceof de)&&("SwimLane"!==e.shape.type||e.children&&e.children.length>0)){if(e.parentId){var s=this.swimlaneZIndexTable[e.parentId],o=this.swimlaneChildTable[e.id];(s&&-1!==s||o&&-1!==o)&&(e.zIndex=this.swimlaneChildTable[e.id])}e instanceof de&&e.sourceID&&e.targetID?-1!==this.activeLayer.objects.indexOf(e.sourceID)&&-1!==this.activeLayer.objects.indexOf(e.targetID)&&this.setZIndex(r||this.activeLayer,e):this.setZIndex(r||this.activeLayer,e)}},t.prototype.updateLayer=function(e){for(var i=0,r=Object.keys(e.layers);i0)for(r=0;rs;l--)r.zIndexTable[parseInt(l.toString(),10)]=r.zIndexTable[l-1],this.nameTable[r.zIndexTable[parseInt(l.toString(),10)]]&&(this.nameTable[r.zIndexTable[parseInt(l.toString(),10)]].zIndex=l);r.zIndexTable[parseInt(a.toString(),10)]=i.id}}},t.prototype.initializeDiagramLayers=function(){for(var e=0;ethis.layers[parseInt(a.toString(),10)].zIndex&&(i=this.layers[parseInt(e.toString(),10)],this.layers[parseInt(e.toString(),10)]=this.layers[parseInt(a.toString(),10)],this.layers[parseInt(a.toString(),10)]=i);0===this.layers.length&&this.commandHandler.addLayer({id:"default_layer",visible:!0,lock:!1,objects:[],zIndex:0,objectZIndex:-1,zIndexTable:{}},null,!0),this.setActiveLayer(this.layers[this.layers.length-1].id)},t.prototype.resetTool=function(){this.eventHandler.resetTool()},t.prototype.initObjectExtend=function(e,i,r){if(r){var s=this.commandHandler.checkBoundaryConstraints(void 0,void 0,e.wrapper.bounds,!0);if("SwimLane"===e.shape.type)for(var o=0,a=Object.keys(i.zIndexTable);o0)&&this.setZIndex(i,e)),e instanceof te){if(r){if("helper"!==e.id&&(o=Zi(this.getNodeDefaults))){if((a=o(e,this))&&a.ports)for(var l=0;l0)for(l=0;l0&&!e.container||e.processId){var r=this.nameTable[e.id];if(!(this.realActions&$i.PreventScale||this.realActions&$i.PreventDrag)){if(r.offsetX&&(this.realActions&$i.EnableGroupAction||!(this.diagramActions&ee.UndoRedo||this.diagramActions&ee.ToolAction||this.diagramActions&ee.PublicMethod))){this.realActions|=$i.PreventScale;var s=r.offsetX-e.wrapper.offsetX;r.offsetX=e.wrapper.offsetX;var o=r.offsetY-e.wrapper.offsetY;r.offsetY=e.wrapper.offsetY,s+o!==0&&this.drag(r,s,o),this.realActions&=~$i.PreventScale}else r.offsetX=e.wrapper.offsetX;r.offsetY&&(this.realActions&$i.EnableGroupAction||!(this.diagramActions&ee.UndoRedo||this.diagramActions&ee.ToolAction||this.diagramActions&ee.PublicMethod))?(this.realActions|=$i.PreventScale,o=r.offsetY-e.wrapper.offsetY,r.offsetY=e.wrapper.offsetY,this.drag(r,0,o),this.realActions&=~$i.PreventScale):r.offsetY=e.wrapper.offsetY,this.diagramActions&&(r.width=e.wrapper.actualSize.width,r.height=e.wrapper.actualSize.height)}}i&&e.children&&e.children.length>0&&(void 0!==this.nameTable[e.id].width?this.scaleObject(e,this.nameTable[e.id].width,!0):this.nameTable[e.id].width=e.wrapper.actualSize.width,void 0!==this.nameTable[e.id].height?this.scaleObject(e,this.nameTable[e.id].height,!1):this.nameTable[e.id].height=e.wrapper.actualSize.height)},t.prototype.initNode=function(e,i,r){var a,p,s=e.initContainer(),o=new Ii;if(this.diagramSettings.inversedAlignment||(s.inversedAlignment=!1),s.children||(s.children=[]),e.children){s.measureChildren=!1,o.id=e.id+"group_container",o.style.fill=e.shape&&"SwimLane"===e.shape.type?e.style.fill:"none",o.style.strokeColor="none",o.horizontalAlignment="Stretch",o.verticalAlignment="Stretch",o.pivot=e.pivot,s.style=e.style,s.padding.left=e.padding.left,s.padding.right=e.padding.right,s.padding.top=e.padding.top,s.padding.bottom=e.padding.bottom,o.children=[],o.preventContainer=!0,e.container&&(o.relativeMode="Object");var l=!!(e.ports&&e.ports.length>0);if(m(e.container)&&!l&&s.children.push(o),e.container&&"Grid"===e.container.type)for(var h=0;h0&&e.wrapper.children[0]instanceof Wv){if(this.setZIndex(this.activeLayer,e),this.connectors.length>0)for(h=0;h0?i.phases.length:0,v="Horizontal"===i.orientation,y=v?i.phases.length||1:s.length+1,S=v?(i.header&&i.hasHeader?1:0)+(i.phases.length>0?1:0)+i.lanes.length:(i.header&&i.hasHeader?1:0)+i.phases.length;if(0===h&&!v&&i.lanes.length&&(S+=1),v?(a=(i.header&&i.hasHeader?1:0)+(h>0?1:0),l=0):(a=i.header&&i.hasHeader?1:0,l=h>0?1:0),s.length>0)for(o+=i.header&&i.hasHeader?i.header.height:0,p=0;pl?d.margin.left=d.margin.left-(u.bounds.left-e.bounds.left):u.children[0].children[1].actualSize.width+r>=d.margin.left&&(d.margin.left=u.children[0].children[1].actualSize.width+r),d.margin.lefta?d.margin.top=d.margin.top-(u.bounds.top-o):u.children[0].children[1].actualSize.height+r>=d.margin.top&&(d.margin.top=u.children[0].children[1].actualSize.height+r),d.margin.left0)for(o=0;o0&&this.updateChildPosition(e)},t.prototype.addBpmnAnnotationConnector=function(e,i){if(e.parentObj instanceof t||e.parentObj instanceof Rd){var r=e.shape,o=""!==r.textAnnotation.textAnnotationTarget&&this.nameTable[r.textAnnotation.textAnnotationTarget],a=o?this.nameTable[r.textAnnotation.textAnnotationTarget]:null,l=null!=a?a.wrapper:null,h=e.ports[0],c={x:0,y:0};switch(r.textAnnotation.textAnnotationDirection){case"Left":h.offset={x:0,y:.5},c.x=i.bounds.left-40,c.y=i.bounds.bottom+30;break;case"Right":h.offset={x:1,y:.5},c.x=i.bounds.right+40,c.y=i.bounds.bottom+30;break;case"Top":h.offset={x:.5,y:0},c.x=i.bounds.right+30,c.y=i.bounds.top-40;break;case"Bottom":h.offset={x:.5,y:1},c.x=i.bounds.right+30,c.y=i.bounds.bottom+40;break;default:h.offset={x:0,y:.5},c.x=i.bounds.left-40,c.y=i.bounds.bottom+30,o&&null!=i&&null!=l&&(i.bounds.left>l.bounds.right?h.offset={x:0,y:.5}:i.bounds.rightl.bounds.top?h.offset={x:.5,y:0}:i.bounds.top0&&this.updateChildPosition(r)}},t.prototype.canExecute=function(){return!0},t.prototype.updateStackProperty=function(e,i,r){e.container&&"Stack"===e.container.type&&(i.width||(i.wrapper.horizontalAlignment="Stretch",i.horizontalAlignment="Stretch"),i.height||(i.verticalAlignment="Stretch",i.wrapper.verticalAlignment="Stretch"),r&&"UmlClassifier"===e.shape.type&&(i.umlIndex=r))},t.prototype.initViews=function(){this.isLoading||(this.views.push(this.element.id),this.views[this.element.id]=this)},t.prototype.initCommands=function(){var e=this.commandManager.commands,i={copy:{execute:this.copyCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.C,keyModifiers:pt.Control}},paste:{execute:this.pasteCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.V,keyModifiers:pt.Control}},cut:{execute:this.cutCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.X,keyModifiers:pt.Control}},delete:{execute:this.removeCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Delete}},selectAll:{execute:this.selectAll.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.A,keyModifiers:pt.Control}},undo:{execute:this.undo.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Z,keyModifiers:pt.Control}},redo:{execute:this.redo.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Y,keyModifiers:pt.Control}},nudgeUp:{execute:this.nudgeCommand.bind(this,"Up"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Up},parameter:"up"},nudgeRight:{execute:this.nudgeCommand.bind(this,"Right"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Right},parameter:"right"},nudgeDown:{execute:this.nudgeCommand.bind(this,"Down"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Down},parameter:"down"},nudgeLeft:{execute:this.nudgeCommand.bind(this,"Left"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Left},parameter:"left"},startEdit:{execute:this.startEditCommad.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.F2}},endEdit:{execute:this.endEditCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Escape}},focusToNextItem:{execute:this.navigateItems.bind(this,!0),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Tab}},focusToPreviousItem:{execute:this.navigateItems.bind(this,!1),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Tab,keyModifiers:pt.Shift}},selectFocusedItem:{execute:this.startEditCommad.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Enter}},bold:{execute:this.fontStyleCommand.bind(this,"bold"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.B,keyModifiers:pt.Control}},italic:{execute:this.fontStyleCommand.bind(this,"italic"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.I,keyModifiers:pt.Control}},underline:{execute:this.fontStyleCommand.bind(this,"underline"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.U,keyModifiers:pt.Control}},duplicate:{execute:this.duplicateCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.D,keyModifiers:pt.Control}},group:{execute:this.groupCommand.bind(this,"group"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.G,keyModifiers:pt.Control}},ungroup:{execute:this.groupCommand.bind(this,"ungroup"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.U,keyModifiers:pt.Control|pt.Shift}},rotateClockwise:{execute:this.rotateCommand.bind(this,"clockwise"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.R,keyModifiers:pt.Control}},rotateAntiClockwise:{execute:this.rotateCommand.bind(this,"antiClockwise"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.L,keyModifiers:pt.Control}},flipHorizontal:{execute:this.flipCommand.bind(this,"horizontal"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.H,keyModifiers:pt.Control}},flipVertical:{execute:this.flipCommand.bind(this,"vertical"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.J,keyModifiers:pt.Control}},pointerTool:{execute:this.toolCommand.bind(this,"pointer"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number1,keyModifiers:pt.Control}},textTool:{execute:this.toolCommand.bind(this,"text"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number2,keyModifiers:pt.Control}},connectTool:{execute:this.toolCommand.bind(this,"connect"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number3,keyModifiers:pt.Control}},freeForm:{execute:this.toolCommand.bind(this,"freeForm"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number5,keyModifiers:pt.Control}},lineTool:{execute:this.toolCommand.bind(this,"line"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number6,keyModifiers:pt.Control}},rectangleTool:{execute:this.toolCommand.bind(this,"rectangle"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number8,keyModifiers:pt.Control}},ellipseTool:{execute:this.toolCommand.bind(this,"ellipse"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number9,keyModifiers:pt.Control}},zoomIn:{execute:this.zoomCommand.bind(this,"zoomIn"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Plus,keyModifiers:pt.Control}},zoomOut:{execute:this.zoomCommand.bind(this,"zoomOut"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Minus,keyModifiers:pt.Control}},shiftUp:{execute:this.shiftCommand.bind(this,"Up"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Up,keyModifiers:pt.Shift}},shiftDown:{execute:this.shiftCommand.bind(this,"Down"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Down,keyModifiers:pt.Shift}},shiftLeft:{execute:this.shiftCommand.bind(this,"Left"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Left,keyModifiers:pt.Shift}},shiftRight:{execute:this.shiftCommand.bind(this,"Right"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Right,keyModifiers:pt.Shift}},alignTextCenter:{execute:this.alignCommand.bind(this,"center"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.C,keyModifiers:pt.Control|pt.Shift}},alignTextLeft:{execute:this.alignCommand.bind(this,"right"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.L,keyModifiers:pt.Control|pt.Shift}},alignTextRight:{execute:this.alignCommand.bind(this,"left"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.R,keyModifiers:pt.Control|pt.Shift}},alignTextTop:{execute:this.alignCommand.bind(this,"top"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.E,keyModifiers:pt.Control|pt.Shift}},alignTextCenterVertical:{execute:this.alignCommand.bind(this,"centerVertical"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.M,keyModifiers:pt.Control|pt.Shift}},alignTextBottom:{execute:this.alignCommand.bind(this,"bottom"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.V,keyModifiers:pt.Control|pt.Shift}},alignJustify:{execute:this.alignCommand.bind(this,"justify"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.J,keyModifiers:pt.Control|pt.Shift}},sendToBack:{execute:this.orderCommand.bind(this,"sendToBack"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.B,keyModifiers:pt.Control|pt.Shift}},bringToFront:{execute:this.orderCommand.bind(this,"bringToFront"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.F,keyModifiers:pt.Control|pt.Shift}},sendBackward:{execute:this.orderCommand.bind(this,"sendBackward"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.BracketLeft,keyModifiers:pt.Control}},bringForward:{execute:this.orderCommand.bind(this,"bringForward"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.BracketRight,keyModifiers:pt.Control}}};this.initCommandManager(e,i)},t.prototype.overrideCommands=function(e,i){for(var r,s=0,o=Object.keys(i);se.zIndex){("HTML"===e.shape.type||"Native"===e.shape.type)&&(o="HTML"===e.shape.type?"html":"native"),s=foe(i,r[parseInt(a.toString(),10)].id,o);break}return s},t.prototype.updateDiagramObject=function(e,i,r){for(var s,o="domTable",a=0,l=this.views;a1&&(d=this.commandHandler.getObjectLayer(e.id)),void 0===d||d&&d.visible||r){var u=Io(this.element.id);window[""+o][s.element.id+"_diagramLayer"]||(window[""+o][s.element.id+"_diagramLayer"]=document.getElementById(s.element.id+"_diagramLayer"));var p=window[""+o][s.element.id+"_diagramLayer"];this.diagramActions&ee.Interactions&&this.updateCanupdateStyle(e.wrapper.children,!0);var f=this.getMidPoint(e);this.diagramRenderer.updateNode(e.wrapper,p,u,void 0,i?void 0:this.getZindexPosition(e,s.element.id),f,this.portCenterPoint),this.updateCanupdateStyle(e.wrapper.children,!0)}}},t.prototype.applyMarginBezier=function(e,i){i.cx=i.cx+e.margin.left,i.cx=i.cx-e.margin.right,i.cy=i.cy+e.margin.top,i.cy=i.cy-e.margin.bottom},t.prototype.getMidPoint=function(e){var i;if(e instanceof de&&"Bezier"===e.type){i=[];for(var r=this.getBezierPoints(e),s=z.getLengthFromListOfPoints(r),o=0;o0&&e.updateView(e));var s=Io(e.element.id);this.renderDiagramElements(e.diagramLayer,e.diagramRenderer,s,void 0,void 0,i);for(var o=0;o0&&this.renderBasicElement(e),!this.diagramActions||!(this.diagramActions&ee.Render)||ee.ToolAction&this.diagramActions||Ds(this)||1!==this.scroller.currentZoom?this.refreshElements(e):this.renderTimer||(this.renderTimer=setTimeout(function(){i.refreshElements(e)},40)))},t.prototype.updatePortVisibility=function(e,i,r){var s;if((e instanceof te||e instanceof de)&&(!this.drawingObject||!this.drawingObject.shape)&&to(e)){for(var a=e.ports,l=!1,h=0;h=0&&this.scroller.removeCollection.splice(l,1);var h=this.nameTable[e[parseInt(a.toString(),10)]];this.updateTextElementValue(h),this.diagramRenderer.renderElement(h.wrapper,s,o,void 0,void 0,void 0,void 0,h.zIndex)}for(var c=0;c0?this.scroller.oldCollectionObjects:void 0,b=Object.keys(S||g.zIndexTable);b.sort(function(N,T){return parseInt(""+N,10)-parseInt(""+T,10)});for(var M=0,w=b;M0?h:0)+"px",y=(this.realActions&$i.vScrollbarMoved?0:-(this.scroller.verticalOffset<0?this.scroller.verticalOffset:0))+"px"):(v="0px",y="0px"),this.realActions&$i.hScrollbarMoved&&(this.realActions=this.realActions&~$i.hScrollbarMoved),this.realActions&$i.vScrollbarMoved&&(this.realActions=this.realActions&~$i.vScrollbarMoved)):(v=(l.x<0?h:-this.scroller.horizontalOffset)+"px",y=(l.y<0?c:-this.scroller.verticalOffset)+"px"),this.diagramLayer.style.left=v,this.diagramLayer.style.top=y,A.tx=-l.x/A.scale,A.ty=-l.y/A.scale);var R=!0;if(o&&(R=!1),this.updateTextElementValue(D),this.refreshing&&D.shape.activity&&D.shape.activity.subProcess&&D.shape.activity.subProcess.processes){for(var L=0;L0){var o=s.children[0],a=o.data;(r.isBezierEditing&&this.selectedItems.connectors[0].id===r.id||"Bezier"!==r.type)&&r.getSegmentElement(r,o,"ComplexHierarchicalTree"===this.layout.type||"HierarchicalTree"===this.layout.type?this.layout.orientation:void 0,void 0,!1),o.data!==a&&(s.measure(new me),s.arrange(s.desiredSize),"SVG"===this.mode&&!e&&this.updateDiagramObject(r))}}else this.constraints&rt.Bridging&&console.warn('[WARNING] :: Module "ConnectorBridging" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.setCursor=function(e){this.diagramRenderer.setCursor(this.diagramCanvas,e)},t.prototype.clearCanvas=function(e){var i=e.contentWidth||e.diagramLayer.width/this.scroller.currentZoom,r=e.contentHeight||e.diagramLayer.height/this.scroller.currentZoom;"SVG"!==e.mode&&bo.getContext(e.diagramLayer).clearRect(0,0,i,r)},t.prototype.updateScrollOffset=function(){this.scroller.setScrollOffset(this.diagramCanvas.scrollLeft,this.diagramCanvas.scrollTop),XI(this),Ds(this)&&this.scroller.virtualizeElements()},t.prototype.setOffset=function(e,i){var r="domTable";window[""+r][this.element.id+"content"]||(window[""+r][this.element.id+"content"]=document.getElementById(this.element.id+"content"));var s=window[""+r][this.element.id+"content"];s&&(s.scrollLeft=e,s.scrollTop=i)},t.prototype.setSize=function(e,i){if(this.diagramLayer&&!this.preventDiagramUpdate){var r=qa(this);e-=r.width,i-=r.height;var s=this.spatialSearch.getPageBounds();s.x*=this.scroller.currentZoom,s.y*=this.scroller.currentZoom,s.width*=this.scroller.currentZoom,s.height*=this.scroller.currentZoom;var o="SVG"===this.mode?1:1.5,a="SVG"===this.mode?fT(this.element.id):this.diagramLayer,h="Canvas"===this.mode&&this.constraints&rt.Virtualization?this.scroller.viewPortHeight:i;a.setAttribute("width",(o*("Canvas"===this.mode&&this.constraints&rt.Virtualization?this.scroller.viewPortWidth:e)).toString()),a.setAttribute("height",(o*h).toString());var c=document.getElementById(this.element.id+"_diagramUserHandleLayer");c&&(c.style.width=e+"px",c.style.height=i+"px");var d={width:e.toString(),height:i.toString()};this.diagramLayerDiv.style.width=e+"px",this.diagramLayerDiv.style.height=i+"px",ai(kF(this.element.id),d),ai(function voe(n){return xt(n).getElementsByClassName("e-ports-expand-layer")[0]}(this.element.id),d);var u=Pl(this.element.id);ai(u,d),u.parentNode.style.width=e+"px",u.parentNode.style.height=i+"px";var p=Bd(this.element.id);ai(p,d),this.diagramRenderer.updateGrid(this.snapSettings,p,this.scroller.transform,this.rulerSettings,this.hRuler,this.vRuler),ai(mT(this.element.id),d),this.htmlLayer.style.width=e+"px",this.htmlLayer.style.height=i+"px","SVG"!==this.mode&&!Ds(this)&&this.refreshDiagramLayer(),"SVG"===this.mode&&Ds(this)&&this.scroller.virtualizeElements()}},t.prototype.transformLayers=function(){var e=this.spatialSearch.getPageBounds();e.x*=this.scroller.currentZoom,e.y*=this.scroller.currentZoom,e.width*=this.scroller.currentZoom,e.height*=this.scroller.currentZoom,this.diagramRenderer.updateGrid(this.snapSettings,Bd(this.element.id),this.scroller.transform,this.rulerSettings,this.hRuler,this.vRuler),this.diagramRenderer.transformLayers(this.scroller.transform,"SVG"===this.mode),this.diagramActions&ee.DragUsingMouse||this.updateSelector(),this.renderPageBreaks(e)},t.prototype.removePageBreaks=function(){if(this.diagramLayer){var e=PF(this.element.id);if(e&&e.childNodes)for(var i=e.childNodes.length,r=0;rthis.pageSettings.height&&(e=this.pageSettings.height,this.pageSettings.height=this.pageSettings.width,this.pageSettings.width=e):this.pageSettings.height>this.pageSettings.width&&(e=this.pageSettings.width,this.pageSettings.width=this.pageSettings.height,this.pageSettings.height=e)},t.prototype.setOverview=function(e,i){if(e)e&&(this.views.push(e.id),this.views[e.id]=e,e.renderDocument(e),e.diagramRenderer.setLayers(),e.updateView(e),this.renderNodes(e));else{for(var r=0;r1&&this.updateSelectionRectangle(),this.isProtectedOnChange=s},t.prototype.updateSelectionRectangle=function(){for(var e=cm(this.element.id),i=!1,r=0;r1&&this.updateSelectionRectangle(),this.enableServerDataBinding(e)},t.prototype.renderSelectorForAnnotation=function(e,i){this.diagramRenderer.renderResizeHandle(e.wrapper.children[0],i,e.thumbsConstraints,this.scroller.currentZoom,e.constraints,this.scroller.transform,void 0,to(e.annotation),void 0,void 0,e.handleSize)},t.prototype.drawSelectionRectangle=function(e,i,r,s){this.clearSelectorLayer(),this.diagramRenderer.drawSelectionRectangle(e,i,r,s,this.adornerLayer,this.scroller.transform)},t.prototype.renderHighlighter=function(e){var i=Pl(this.element.id);this.diagramRenderer.renderHighlighter(e,i,this.scroller.transform)},t.prototype.clearHighlighter=function(){var e=Pl(this.element.id),i=e.getElementById(e.id+"_highlighter");i&&i.parentNode.removeChild(i)},t.prototype.getNodesConnectors=function(e){for(var i=0;i0;l--)(a=o[l-1]).parentNode.removeChild(a);if(!ce()){var h=vT(this.element.id).childNodes;for(r=h.length;r>0;r--)h[r-1].parentNode.removeChild(h[r-1])}}},t.prototype.getWrapper=function(e,i){var r;i=e.id+"_"+i;for(var s=e instanceof Ii?e:this.getPortContainer(this.nameTable[e.id]),o=0;o0&&this.applyStyle(e,a=r.annotations)}for(i=0;i0){var a=this.selectedItems.connectors[parseInt(i.toString(),10)].annotations;this.applyStyle(e,a)}},t.prototype.applyStyle=function(e,i){for(var r=0;r0)for(var i=0;i0?r[0].zIndex+(e?1:-1):e?0:this.nodes.length+this.connectors.length-1)<0?i=this.nodes.length+this.connectors.length-1:i===this.nodes.length+this.connectors.length&&(i=0);for(var s=0;s0)for(var s=void 0,o=r.children.length-1;o>=0;o--){var a=r.children[parseInt(o.toString(),10)];i.length>0&&-1!==i.indexOf(a.id.split("_groupElement")[0])&&(r.parentNode.insertBefore(a,s||r),s=a)}r&&r.parentNode.removeChild(r)},t.prototype.deleteGroup=function(e){var r=[];e.children&&(r=this.commandHandler.getChildren(e,[])),this.UpdateBlazorDiagramModelCollection(e);for(var s=0,o=r;s0)for(var xe=0;xe0)if("Path"===t.shape.type&&void 0!==n.shape.data)t.wrapper.children[0].data=n.shape.data;else if("Text"===t.shape.type&&void 0!==n.shape.content)t.wrapper.children[0].content=n.shape.content;else if("Image"===t.shape.type&&void 0!==n.shape.source)t.wrapper.children[0].source=n.shape.source;else if("Native"===t.shape.type){for(var r=void 0,s=0;s-1)&&(this.diagramActions&ee.PreventZIndexOnDragging?this.updateDiagramObject(e,!0):this.updateDiagramObject(e)),!s&&d&&(this.lineRoutingModule&&this.diagramActions&&this.constraints&rt.LineRouting&&"helper"!==e.id?this.diagramActions&ee.ToolAction||this.lineRoutingModule.renderVirtualRegion(this,!0):this.diagramActions&&this.constraints&rt.LineRouting&&"helper"!==e.id&&console.warn('[WARNING] :: Module "LineRouting" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),this.updateConnectorEdges(e),"helper"!==e.id&&!(this.diagramActions&ee.ToolAction))))for(var ya=this.spatialSearch.findObjects(e.wrapper.outerBounds),Mo=0;Moe?Math.abs(r-e):Math.abs(e-r),d=s>i?Math.abs(s-i):Math.abs(i-s);(0===c&&0===d||Number.isNaN(c)&&Number.isNaN(d))&&o.laneMargin&&(u=o.margin.left-o.laneMargin.left,p=o.margin.top-o.laneMargin.top);var f=o.width,g=o.height,v=new Ne(0,0,0,0);if(0!==f&&0!==g&&(v=new Ne((0!==r?r:o.offsetX)-f/2,(0!==s?s:o.offsetY)-g/2,f,g)),h){var y=l,b=this.selectedItems.nodes?this.selectedItems.nodes[0]:void 0;if(""!==y.textAnnotation.textAnnotationTarget&&this.nameTable[y.textAnnotation.textAnnotationTarget])if(""===o.parentId||b&&b.shape&&"TextAnnotation"===b.shape.shape){if("Auto"===y.textAnnotation.textAnnotationDirection&&a.children[0]instanceof Ii&&a.children[0].children[0]instanceof Ke){var w=a.children[0],C=document.getElementById(w.id+"_groupElement"),D=document.getElementById(w.children[0].id+"_groupElement");C.removeChild(D),w.children.splice(0,1),this.isProtectedOnChange=!0,this.bpmnModule.setAnnotationPath(v,w,o,y,y.textAnnotation.textAnnotationDirection,this),this.isProtectedOnChange=!1}}else this.isPositionUndo=!0,this.updateTextAnnotationInSwimlane(o,o),this.isPositionUndo=!1;else o.inEdges.length>0&&(x=this.nameTable[""+o.inEdges[0]])&&x.isBpmnAnnotationConnector&&(x.sourcePoint={x:r>e?x.sourcePoint.x+c:x.sourcePoint.x-c,y:s>i?x.sourcePoint.y+d:x.sourcePoint.y-d});this.nodePropertyChange(o,{},R={ports:[{offset:o.ports[0].offset}]})}else for(var L=0,O=o.outEdges;Le?T.offsetX+c:T.offsetX-c,T.offsetY=s>i?T.offsetY+d:T.offsetY-d,R={offsetX:T.offsetX,offsetY:T.offsetY}),this.nodePropertyChange(T,P,R)}}}},t.prototype.updatePorts=function(e,i){if(e&&e.ports.length>0)for(var r=0,s=Object.keys(e.ports);r0)for(var i=0;i0)for(var r=0;r0&&void 0===r.segments&&(e.segments=[]),void 0!==r.shape&&void 0!==e.shape&&e.shape&&"Bpmn"===e.shape.type&&this.bpmnModule&&this.bpmnModule.updateBPMNConnector(e,i,r,this),void 0!==e.constraints?(this.updateThumbConstraints(this.selectedItems.connectors,this.selectedItems),s=!0):s},t.prototype.connectorPropertyChange=function(e,i,r,s,o){if(this.canEnableBlazorObject){var a=$(e);this.insertValue(a,!1)}var d,u,p,f,l=e.wrapper.bounds,h=!1,c=[];if(h=this.connectorProprtyChangeExtend(e,i,r,h),void 0!==r.visible&&this.updateElementVisibility(e.wrapper,e,e.visible),void 0!==r.sourcePoint||void 0!==r.targetPoint||void 0!==r.sourceID||void 0!==r.targetID||void 0!==r.targetPadding||void 0!==r.sourcePortID||void 0!==r.targetPortID||void 0!==r.sourcePadding||void 0!==r.type||void 0!==r.segments||void 0!==r.flip){if(void 0!==r.sourceID&&r.sourceID!==i.sourceID||r.sourcePortID){if(u=this.findInOutConnectPorts(g=this.nameTable[e.sourceID],!1),(!g||Nh(g)||""!==e.sourcePortID&&xd(u))&&(e.sourceWrapper=g?this.getEndNodeWrapper(g,e,!0):void 0,e.sourcePortID&&void 0===r.sourcePortID&&(e.sourcePortWrapper=g?this.getWrapper(g.wrapper,e.sourcePortID):void 0),this.removePortEdges(this.nameTable[i.sourceID]||g,i.sourcePortID||e.sourcePortID,e.id,!1)),void 0!==r.sourceID&&void 0!==i.sourceID&&""!==i.sourceID){var v=this.nameTable[i.sourceID];void 0!==v&&v.outEdges&&-1!==v.outEdges.indexOf(e.id)&&tm(v.outEdges,e.id)}this.updateEdges(e)}if(void 0!==r.targetID&&r.targetID!==i.targetID){if(d=this.findInOutConnectPorts(y=this.nameTable[r.targetID],!0),(!y||da(y)||""!==e.targetPortID&&Lh(d))&&(e.targetWrapper=y?this.getEndNodeWrapper(y,e,!1):void 0,e.targetPortID&&void 0===r.targetPortID&&(e.targetPortWrapper=y?this.getWrapper(y.wrapper,e.targetPortID):void 0),this.removePortEdges(this.nameTable[i.targetID]||y,i.targetPortID||e.targetPortID,e.id,!0)),void 0!==i&&void 0!==i.targetID&&""!==i.targetID){var S=this.nameTable[i.targetID];void 0!==S&&S.inEdges&&-1!==S.inEdges.indexOf(e.id)&&tm(S.inEdges,e.id)}this.updateEdges(e)}var g,y;void 0!==r.sourcePortID&&r.sourcePortID!==i.sourcePortID&&(e.sourceID&&this.nameTable[e.sourceID]&&(p=this.nameTable[e.sourceID].wrapper),!(g=this.nameTable[e.sourceID])||Nh(g)||""!==e.sourcePortID&&xd(u)?e.sourcePortWrapper=p?this.getWrapper(p,r.sourcePortID):void 0:""===e.sourcePortID&&!Nh(g)&&(e.sourcePortWrapper=void 0)),void 0!==r.targetPortID&&r.targetPortID!==i.targetPortID&&(e.targetID&&this.nameTable[e.targetID]&&(f=this.nameTable[e.targetID].wrapper),!(y=this.nameTable[e.targetID])||da(y)||""!==e.targetPortID&&Lh(d)?e.targetPortWrapper=f?this.getWrapper(f,r.targetPortID):void 0:""===e.targetPortID&&!da(y)&&(e.targetPortWrapper=void 0)),void 0!==r.flip&&(e.flip=r.flip,SF(e)),"Orthogonal"===e.type&&this.lineRoutingModule&&this.diagramActions&&this.constraints&rt.LineRouting&&!(this.diagramActions&ee.ToolAction)&&"ComplexHierarchicalTree"!==this.layout.type&&(this.lineRoutingModule.renderVirtualRegion(this,!0),e.sourceID!==e.targetID&&e.segments.length>1&&this.lineRoutingModule.refreshConnectorSegments(this,e,!1)),c=this.getPoints(e)}void 0!==r.style&&Ph(r.style,e.wrapper.children[0]),(c.length>0||void 0!==r.sourceDecorator||void 0!==r.targetDecorator&&function Bse(n){return-1!==n.indexOf("shape")||-1!==n.indexOf("pathData")||-1!==n.indexOf("width")||-1!==n.indexOf("height")}(Object.keys(r.targetDecorator))||void 0!==r.cornerRadius)&&(Zp(e,c.length>0?c:e.intermediatePoints,this.diagramActions),void 0!==r.type&&(h=!0),c.length>0&&(e.wrapper.measure(new me(e.wrapper.width,e.wrapper.height)),e.wrapper.arrange(e.wrapper.desiredSize),this.updateConnectorAnnotation(e),this.updateConnectorPort(e),this.updateConnectorfixedUserHandles(e),this.updateObject(e,i,r))),(r.sourcePoint||r.targetPoint||r.segments)&&this.diagramActions===ee.Render&&(h=!0),"Bpmn"===e.shape.type&&"Default"===e.shape.sequence&&"Sequence"===e.shape.flow&&this.commandHandler.updatePathElementOffset(e),s||this.updateBridging(),this.updateAnnotations(r,e),this.updateConnectorPorts(r,e),this.updatefixedUserHandle(r,e),e.wrapper.measure(new me(e.wrapper.width,e.wrapper.height)),e.wrapper.arrange(e.wrapper.desiredSize),!1===l.equals(l,e.wrapper.bounds)&&(this.updateQuad(e),"Drag"!==this.eventHandler.currentAction&&this.updateGroupSize(e)),!0===h&&this.checkSelectedItem(e)&&(!(this.diagramActions&ee.ToolAction)||this.diagramActions&ee.UndoRedo)&&this.updateSelector(),this.preventConnectorsUpdate||(!Ds(this)||Ds(this)&&this.scroller.oldCollectionObjects.indexOf(e.id)>-1)&&(this.diagramActions&ee.PreventZIndexOnDragging?this.updateDiagramObject(e,!0):this.updateDiagramObject(e)),this.updateConnectorEdges(e),this.diagramActions&&"New"!==e.status&&(e.status="Update"),this.triggerPropertyChange(o,e,i,r)},t.prototype.removePortEdges=function(e,i,r,s){if(e)for(var o=0;o0&&e.id===s[s.length-1].id&&(r=!0),r},t.prototype.updateDiagramContainerVisibility=function(e,i){if(e instanceof Cs)for(var r=0;r>"),r instanceof Jn&&this.updateAnnotationWrapper(r,s,o,a)),void 0!==e.template&&(r.content=e.template,this.updateAnnotationWrapper(r,s,o,a))},t.prototype.updateAnnotationWrapper=function(e,i,r,s){for(var o=0,a=this.views;o=0&&this.nodes.splice(s,1),delete this.nameTable[""+r]}var o=this.nodes.indexOf(this.nameTable[this.currentSymbol.id]);o>=0&&this.nodes.splice(o,1)}},t.prototype.selectDragedNode=function(e,i,r){this.currentSymbol=e,"SVG"!==this.mode&&this.refreshDiagramLayer(),this.commandHandler.oldSelectedObjects=rm(this),this.commandHandler.select(e),this.eventHandler.mouseDown(i.event),this.eventHandler.mouseMove(i.event,i),this.preventDiagramUpdate=!1,this.updatePage(),r.style.opacity="0"},t.prototype.initDroppables=function(){var s,o,e=this,i={},r={},a="selectedSymbols";this.droppable=new lR(this.element);var l=5;this.droppable.over=function(h){if(e.rulerSettings.showRulers){var c=document.getElementById(e.element.id+"_vRuler"),d=parseFloat(c.style.width);l=d+1}if(0===e.previousSelectedObjects.length&&!e.currentSymbol&&(e.previousSelectedObjects=e.commandHandler.getSelectedObject()),e.commandHandler.PreventConnectorSplit=!0,e.currentSymbol)h.event.touches&&h.event.touches.length&&e.eventHandler.mouseMove(h.event,h.event.touches);else{var u=null;if(!h.dragData&&"drag"===h.name){var p=document.getElementsByClassName("e-dragclone")[0];p&&(u=p)}if(h.dragData||u){var f=void 0,g=void 0;document.getElementById(e.element.id+"content").focus();var v=e.eventHandler.getMousePosition(h.event),y=void 0,S=u||h.dragData.helper,b=S.getAttribute("paletteId"),M=void 0,w=void 0,C=void 0,D=void 0;if(!b&&h.dragData){e.triggerEvent(Ce.dragEnter,A={source:null,element:f,cancel:!1,diagram:e,dragData:h.dragData.draggedElement.ej2_instances[0].dragData,dragItem:f});var x=void 0,R=void 0;if(A.dragItem){if(A.dragItem.sourcePoint&&A.dragItem.targetPoint?R=new de(e,"connectors",A.dragItem,!0):x=new te(e,"nodes",A.dragItem,!0),e.initObject(f=x||R,void 0,void 0,!0),e.enterObject=f,e.enterTable=r,f instanceof te)x.offsetX=v.x+5+x.width*x.pivot.x,x.offsetY=v.y+x.height*x.pivot.y;else if(f instanceof de){var L=Ne.toBounds([f.sourcePoint,f.targetPoint]),O=v.x-L.left,N=v.y-L.top;f.sourcePoint.x+=O,f.sourcePoint.y+=N,f.targetPoint.x+=O,f.targetPoint.y+=N}e.preventDiagramUpdate=!0,e.currentSymbol=f,"SVG"!==e.mode&&e.refreshDiagramLayer(),e.selectDragedNode(f,h,S),delete e.enterObject,delete e.enterTable,e.droppable[""+a]=S,e.allowServerDataBinding=!0}}if(b){var T=document.getElementById(b).ej2_instances[0];if(e.droppable.sourceElement=T,T){var B=T[""+a];e.allowServerDataBinding=!1,y=$(T[""+a]),i=T.childTable;var j=B.wrapper.children[0].children[0];if(D=function Fse(n,t,e){var i=wF(n,t,e,"width"),r=wF(n,t,e,"height");return new me(i,r)}(T,y,j),T[""+a]instanceof te){"TextAnnotation"===B.shape.shape?(y.offsetX=v.x+11+D.width*y.pivot.x,y.offsetY=v.y+11+D.height*y.pivot.y):(y.offsetX=v.x+5+D.width*y.pivot.x,y.offsetY=v.y+D.height*y.pivot.y),"Bpmn"===(x=new te(e,"nodes",y,!0)).shape.type&&x.shape.activity.subProcess.processes&&x.shape.activity.subProcess.processes.length&&(x.shape.activity.subProcess.processes=[]),w=x.previewSize,C=T.symbolDragSize;var Q=T.symbolPreview;if(x.width=(M=x.dragSize).width||C.width||w.width||Q.width||x.width,x.height=M.height||C.height||w.height||Q.height||x.height,"SwimLane"===x.shape.type){if(e.diagramActions|=ee.PreventHistory,x.shape.isLane){x.children=[],s={id:"header"+Qe()},"Horizontal"===x.shape.orientation?(s.width=x.shape.lanes[0].header.width,s.height=x.shape.lanes[0].height):(s.width=x.shape.lanes[0].width,s.height=x.shape.lanes[0].header.height),s.style=x.shape.lanes[0].header.style,s.offsetX=v.x+l+s.width/2,s.offsetY=v.y+s.height/2,e.diagramActions|=ee.PreventCollectionChangeOnDragOver,s=e.add(s),o={id:"body"+Qe()},"Horizontal"===x.shape.orientation?(o.width=x.shape.lanes[0].width-s.width,o.height=x.shape.lanes[0].height,o.offsetX=v.x+l+(x.shape.lanes[0].header.width+o.width/2),o.offsetY=v.y+o.height/2):(o.width=x.shape.lanes[0].width,o.height=x.shape.lanes[0].height-s.height,o.offsetX=v.x+l+o.width/2,o.offsetY=v.y+(x.shape.lanes[0].header.height+o.height/2)),o.style=x.shape.lanes[0].style,o=e.add(o);var oe={id:"group"+Qe(),children:[s.id,o.id]};oe.shape=x.shape,oe.width=x.shape.lanes[0].width,oe.height=x.shape.lanes[0].height,oe.previewSize=x.previewSize,oe.dragSize=x.dragSize,oe.addInfo=x.addInfo,x=e.add(oe),e.diagramActions&=~ee.PreventCollectionChangeOnDragOver}e.diagramActions&=~ee.PreventHistory}if(x.shape.isPhase&&((g="Horizontal"===x.shape.orientation)?(x.offsetX=v.x+l+(x.width||j.actualSize.width)/2,x.offsetY=v.y,x.shape.data="M20,"+x.height/2+" L"+(x.width-20)+","+x.height/2+"z",x.height=1):(x.offsetX=v.x+5,x.offsetY=v.y+(x.height||j.actualSize.height)/2,x.shape.data="M"+x.width/2+",20 L"+x.width/2+","+(x.height-20)+"z",x.width=1)),"UmlClassifier"===x.shape.type&&(x.children=x.width=x.height=void 0,y.children=void 0,"Class"===x.shape.classifier&&x.shape.classShape.methods.length<=0&&x.shape.classShape.attributes.length<=0&&(x.shape.classShape.attributes=[{name:"Name",type:"Type",style:{}}]),"Enumeration"===x.shape.classifier&&x.shape.enumerationShape.members.length<=0&&(x.shape.enumerationShape.members=[{name:"Name"}]),"Interface"===x.shape.classifier&&x.shape.interfaceShape.methods.length<=0&&x.shape.interfaceShape.attributes.length<=0&&(x.shape.interfaceShape.attributes=[{name:"Name",type:"Type",style:{}}])),f=x,y.children){var ue=y;r=e.getChildren(ue,{},i),eT(ue,-ue.offsetX,-ue.offsetY,r,!0,e)}}else if(T[""+a]instanceof de){f=new de(e,"connectors",y,!0);var Me=Ne.toBounds([f.sourcePoint,f.targetPoint]),De=v.x-Me.left,xe=v.y-Me.top;f.sourcePoint.x+=De,f.sourcePoint.y+=xe,f.targetPoint.x+=De,f.targetPoint.y+=xe}f.shape.isLane||(f.id+=Qe());var A={source:T,element:f,cancel:!1,diagram:e,dragData:null,dragItem:f};if(e.enterObject=f,e.enterTable=r,e.triggerEvent(Ce.dragEnter,A),f instanceof te&&"SwimLane"===f.shape.type&&f.shape.isLane){var Ie=A.element,Ve=Ie.shape.lanes[0];g="Horizontal"===Ie.shape.orientation;var ot=e.nameTable[f.children[0]],$e=e.nameTable[f.children[1]];w=f.previewSize,C=T.symbolDragSize,Ve.width=(M=f.dragSize).width||C.width||w.width||Ve.width,Ve.height=M.height||C.height||w.height||Ve.height,g?(s.width=Ve.header.width,s.height=Ve.height,o.width=Ve.width-s.width,o.height=Ve.height,o.offsetX=v.x+l+(Ve.header.width+$e.width/2),o.offsetY=v.y+$e.height/2):(s.width=Ve.width,s.height=Ve.header.height,o.width=Ve.width,o.height=Ve.height-s.height,o.offsetX=v.x+l+$e.width/2,o.offsetY=v.y+(Ve.header.height+$e.height/2)),s.offsetX=v.x+l+ot.width/2,s.offsetY=v.y+ot.height/2,f.width=Ve.width,f.height=Ve.height}if(f instanceof te&&f.shape.isPhase&&(g?f.height=1:f.width=1),!e.activeLayer.lock&&!A.cancel){if(e.preventDiagramUpdate=!0,f.children&&e.findChild(f,r),e.preventDiagramUpdate=!0,f.zIndex!==Number.MIN_VALUE&&(f.zIndex=Number.MIN_VALUE),e.initObject(f,void 0,void 0,!0),e.bpmnModule)for(var Mi=0;Mi0&&(S.segments=[]),d=this.add(S,!0)),(S||d)&&(_v(this)||Uv(this))&&this.select([this.nameTable[S[""+b]]],!1,this.previousSelectedObjects),y.target&&y.target instanceof de&&!0===this.enableConnectorSplit&&this.nameTable[S[""+b]]instanceof te&&(this.commandHandler.connectorSplit(this.nameTable[S[""+b]],y.target),this.commandHandler.PreventConnectorSplit=!1))),this.protectPropertyChange(!1),v=this.nameTable[S[""+b]],S.hasTarget&&(S.nodeId=S.hasTarget,this.remove(S)),this.bpmnModule&&v instanceof te&&S.processId&&(v.processId=S.processId,this.bpmnModule.dropBPMNchild(this.nameTable[v.processId],v,this)),y.cancel||this.endGroupAction(),"SVG"!==this.mode&&this.refreshDiagramLayer(),delete this.droppable[""+c]):(this.triggerEvent(Ce.drop,y={source:h.droppedElement,element:void 0,target:this.eventHandler.hoverNode||this.eventHandler.lastObjectUnderMouse||this,cancel:!1,position:void 0}),S=void 0,b="id"),this.droppable[M="selectedSymbols"]&&this.droppable[""+M].parentNode)gt(this.droppable[""+M]);else for(w=document.getElementsByClassName("e-dragclone"),C=0;C0)for(var p=0;p1),e.previousSelectedObject=null}}},t.prototype.getDropEventArgs=function(e){if(this.eventHandler.lastObjectUnderMouse||this.eventHandler.hoverNode){var i=this.eventHandler.lastObjectUnderMouse||this.eventHandler.hoverNode;e.target=fs(i)===de?{connector:i}:{node:i}}else e.target.diagramId=this.element.id},t.prototype.removeChildInNodes=function(e){if(e){if(e.children)for(var i=0;i1){var l=2;if(e.children&&e.children.length>0)for(;e.children.indexOf(i.objects[s-l])>-1;)l++;this.commandHandler.moveSvgNode(e.id,i.objects[s-l]),this.commandHandler.moveSvgNode(i.objects[s-l],e.id)}else if(o){var h=this.commandHandler.getLayer(this.layerZIndexTable[o.zIndex]).objects[0];h?(this.commandHandler.moveSvgNode(e.id,h),this.commandHandler.updateNativeNodeIndex(e.id,h)):this.moveObjectsUp(e,i)}else this.moveObjectsUp(e,i)},t.prototype.moveObjectsUp=function(e,i){for(var r,s=this.layers.length-1;s>=0;s--)if(r=this.layers[parseInt(s.toString(),10)],i.id!==r.id){var o=this.commandHandler.getLayer(this.layerZIndexTable[r.zIndex]).objects[r.objects.length-1];if(o){this.commandHandler.moveSvgNode(e.id,o),this.commandHandler.moveSvgNode(o,e.id);break}}},t.prototype.insertData=function(e){return this.crudOperation(e,"create",this.getNewUpdateNodes("New"))},t.prototype.updateData=function(e){return this.crudOperation(e,"update",this.getNewUpdateNodes("Update"))},t.prototype.removeData=function(e){return this.crudOperation(e,"destroy",this.getDeletedNodes())},t.prototype.crudOperation=function(e,i,r){if(e){var s=this.parameterMap(e,!(e instanceof de));if(s){var o=e instanceof de?this.dataSourceSettings.connectionDataSource.crudAction[""+i]:this.dataSourceSettings.crudAction[""+i];this.raiseAjaxPost(JSON.stringify(s),o)}return s}var a=r;return this.processCrudCollection(a,this.dataSourceSettings.crudAction[""+i],this.dataSourceSettings.connectionDataSource.crudAction[""+i]),a},t.prototype.processCrudCollection=function(e,i,r){if(e.nodes){var s=[],o=void 0;for(o=0;o0&&this.raiseAjaxPost(JSON.stringify(s),i)}if(e.connectors){for(s=[],o=void 0,o=0;o0&&this.raiseAjaxPost(JSON.stringify(s),r)}},t.prototype.parameterMap=function(e,i){var s,r={},o=i?this.dataSourceSettings:this.dataSourceSettings.connectionDataSource;if(o.id&&(r[o.id]=e.id),o.sourcePointX&&o.sourcePointY&&(r[o.sourcePointX]=e.sourcePoint.x,r[o.sourcePointY]=e.sourcePoint.y),o.targetPointX&&o.targetPointY&&(r[o.targetPointX]=e.targetPoint.x,r[o.targetPointY]=e.targetPoint.y),o.sourceID&&(r[o.sourceID]=e.sourceID),o.targetID&&(r[o.targetID]=e.targetID),o.crudAction&&o.crudAction.customFields&&o.crudAction.customFields.length>0)for(s=0;s"u"||(y.innerHTML=v.innerHTML?v.innerHTML:"",void 0!==v.className&&(y.className=v.className),void 0!==v.id&&(y.id=v.id),void 0!==v.styles&&y.setAttribute("style",v.styles),void 0!==e.ngAttr&&y.setAttribute(e.ngAttr,""),void 0!==v.attrs&&Fe(y,v.attrs)),y};for(var i=0,r=e.tags;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s}!function DZ(n){CC.compile=n.compile}({compile:function Fae(n,t){if("string"==typeof n||"function"==typeof n&&n.prototype&&n.prototype.CSPTemplate)return Bae(n,t);var e=n.elementRef.nativeElement._viewContainerRef,i=n.elementRef.nativeElement.propName;return function(r,s,o){var l=e||s.viewContainerRef,h=l.createEmbeddedView(n,{$implicit:r});/EJS-MENTION|EJS-DROPDOWNLIST/.test(Y("currentInstance.element.nodeName",l))||/E-TABITEM/.test(Y("element.nativeElement.nodeName",l))?h.detectChanges():h.markForCheck();var c=s&&s.registeredTemplate?s.registeredTemplate:Y("currentInstance.registeredTemplate",l);return typeof c["".concat(o=o&&s.registeredTemplate?o:i)]>"u"&&(c["".concat(o)]=[]),c["".concat(o)].push(h),h.rootNodes}}});const Wae=["annotationTemplate"],Yae=["nodeTemplate"],Qae=["userHandleTemplate"];let Gae=["addInfo","id","lock","objects","visible","zIndex"],Xae=[],qae=(()=>{class n extends Hh{constructor(e){super(),this.viewContainerRef=e,Rl("currentInstance",this,this.viewContainerRef),this.registerEvents(Xae),this.directivePropList=Gae}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-layer"]],inputs:{addInfo:"addInfo",id:"id",lock:"lock",objects:"objects",visible:"visible",zIndex:"zIndex"},features:[yn]}),n})(),$ae=(()=>{class n extends Bh{constructor(){super("layers")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-layers"]],contentQueries:function(e,i,r){if(1&e&&dn(r,qae,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),Zae=["action","cursor"],Jae=[],Kae=(()=>{class n extends Hh{constructor(e){super(),this.viewContainerRef=e,Rl("currentInstance",this,this.viewContainerRef),this.registerEvents(Jae),this.directivePropList=Zae}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-cursormap"]],inputs:{action:"action",cursor:"cursor"},features:[yn]}),n})(),ele=(()=>{class n extends Bh{constructor(){super("customcursor")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-cursormaps"]],contentQueries:function(e,i,r){if(1&e&&dn(r,Kae,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),tle=["alignment","cornerRadius","displacement","fill","handleStrokeColor","handleStrokeWidth","height","iconStrokeColor","iconStrokeWidth","id","offset","padding","pathData","tooltip","visibility","width"],ile=[],rle=(()=>{class n extends Hh{constructor(e){super(),this.viewContainerRef=e,Rl("currentInstance",this,this.viewContainerRef),this.registerEvents(ile),this.directivePropList=tle}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-connector-fixeduserhandle"]],inputs:{alignment:"alignment",cornerRadius:"cornerRadius",displacement:"displacement",fill:"fill",handleStrokeColor:"handleStrokeColor",handleStrokeWidth:"handleStrokeWidth",height:"height",iconStrokeColor:"iconStrokeColor",iconStrokeWidth:"iconStrokeWidth",id:"id",offset:"offset",padding:"padding",pathData:"pathData",tooltip:"tooltip",visibility:"visibility",width:"width"},features:[yn]}),n})(),nle=(()=>{class n extends Bh{constructor(){super("fixeduserhandles")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-connector-fixeduserhandles"]],contentQueries:function(e,i,r){if(1&e&&dn(r,rle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),sle=["addInfo","alignment","annotationType","constraints","content","displacement","dragLimit","height","horizontalAlignment","hyperlink","id","margin","offset","rotateAngle","rotationReference","segmentAngle","style","template","tooltip","type","verticalAlignment","visibility","width"],ole=[],ale=(()=>{class n extends Hh{constructor(e){super(),this.viewContainerRef=e,Rl("currentInstance",this,this.viewContainerRef),this.registerEvents(ole),this.directivePropList=sle}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-connector-annotation"]],inputs:{addInfo:"addInfo",alignment:"alignment",annotationType:"annotationType",constraints:"constraints",content:"content",displacement:"displacement",dragLimit:"dragLimit",height:"height",horizontalAlignment:"horizontalAlignment",hyperlink:"hyperlink",id:"id",margin:"margin",offset:"offset",rotateAngle:"rotateAngle",rotationReference:"rotationReference",segmentAngle:"segmentAngle",style:"style",template:"template",tooltip:"tooltip",type:"type",verticalAlignment:"verticalAlignment",visibility:"visibility",width:"width"},features:[yn]}),n})(),lle=(()=>{class n extends Bh{constructor(){super("annotations")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-connector-annotations"]],contentQueries:function(e,i,r){if(1&e&&dn(r,ale,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),hle=["addInfo","allowNodeOverlap","annotations","bezierSettings","bridgeSpace","connectionPadding","connectorSpacing","constraints","cornerRadius","dragSize","excludeFromLayout","fixedUserHandles","flip","flipMode","hitPadding","id","margin","maxSegmentThumb","ports","previewSize","segmentThumbShape","segmentThumbSize","segments","shape","sourceDecorator","sourceID","sourcePadding","sourcePoint","sourcePortID","style","symbolInfo","targetDecorator","targetID","targetPadding","targetPoint","targetPortID","tooltip","type","visible","wrapper","zIndex"],cle=[],dle=(()=>{class n extends Hh{constructor(e){super(),this.viewContainerRef=e,this.tags=["fixedUserHandles","annotations"],Rl("currentInstance",this,this.viewContainerRef),this.registerEvents(cle),this.directivePropList=hle}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-connector"]],contentQueries:function(e,i,r){if(1&e&&(dn(r,nle,5),dn(r,lle,5)),2&e){let s;Kr(s=en())&&(i.childFixedUserHandles=s.first),Kr(s=en())&&(i.childAnnotations=s.first)}},inputs:{addInfo:"addInfo",allowNodeOverlap:"allowNodeOverlap",annotations:"annotations",bezierSettings:"bezierSettings",bridgeSpace:"bridgeSpace",connectionPadding:"connectionPadding",connectorSpacing:"connectorSpacing",constraints:"constraints",cornerRadius:"cornerRadius",dragSize:"dragSize",excludeFromLayout:"excludeFromLayout",fixedUserHandles:"fixedUserHandles",flip:"flip",flipMode:"flipMode",hitPadding:"hitPadding",id:"id",margin:"margin",maxSegmentThumb:"maxSegmentThumb",ports:"ports",previewSize:"previewSize",segmentThumbShape:"segmentThumbShape",segmentThumbSize:"segmentThumbSize",segments:"segments",shape:"shape",sourceDecorator:"sourceDecorator",sourceID:"sourceID",sourcePadding:"sourcePadding",sourcePoint:"sourcePoint",sourcePortID:"sourcePortID",style:"style",symbolInfo:"symbolInfo",targetDecorator:"targetDecorator",targetID:"targetID",targetPadding:"targetPadding",targetPoint:"targetPoint",targetPortID:"targetPortID",tooltip:"tooltip",type:"type",visible:"visible",wrapper:"wrapper",zIndex:"zIndex"},features:[yn]}),n})(),ule=(()=>{class n extends Bh{constructor(){super("connectors")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-connectors"]],contentQueries:function(e,i,r){if(1&e&&dn(r,dle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),ple=["cornerRadius","fill","handleStrokeColor","handleStrokeWidth","height","iconStrokeColor","iconStrokeWidth","id","margin","offset","padding","pathData","tooltip","visibility","width"],fle=[],gle=(()=>{class n extends Hh{constructor(e){super(),this.viewContainerRef=e,Rl("currentInstance",this,this.viewContainerRef),this.registerEvents(fle),this.directivePropList=ple}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-node-fixeduserhandle"]],inputs:{cornerRadius:"cornerRadius",fill:"fill",handleStrokeColor:"handleStrokeColor",handleStrokeWidth:"handleStrokeWidth",height:"height",iconStrokeColor:"iconStrokeColor",iconStrokeWidth:"iconStrokeWidth",id:"id",margin:"margin",offset:"offset",padding:"padding",pathData:"pathData",tooltip:"tooltip",visibility:"visibility",width:"width"},features:[yn]}),n})(),vle=(()=>{class n extends Bh{constructor(){super("fixeduserhandles")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-node-fixeduserhandles"]],contentQueries:function(e,i,r){if(1&e&&dn(r,gle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),mle=["addInfo","annotationType","constraints","content","dragLimit","height","horizontalAlignment","hyperlink","id","margin","offset","rotateAngle","rotationReference","style","template","tooltip","type","verticalAlignment","visibility","width"],yle=[],Sle=(()=>{class n extends Hh{constructor(e){super(),this.viewContainerRef=e,Rl("currentInstance",this,this.viewContainerRef),this.registerEvents(yle),this.directivePropList=mle}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-node-annotation"]],inputs:{addInfo:"addInfo",annotationType:"annotationType",constraints:"constraints",content:"content",dragLimit:"dragLimit",height:"height",horizontalAlignment:"horizontalAlignment",hyperlink:"hyperlink",id:"id",margin:"margin",offset:"offset",rotateAngle:"rotateAngle",rotationReference:"rotationReference",style:"style",template:"template",tooltip:"tooltip",type:"type",verticalAlignment:"verticalAlignment",visibility:"visibility",width:"width"},features:[yn]}),n})(),Ile=(()=>{class n extends Bh{constructor(){super("annotations")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-node-annotations"]],contentQueries:function(e,i,r){if(1&e&&dn(r,Sle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),ble=["addInfo","connectionDirection","constraints","height","horizontalAlignment","id","inEdges","margin","offset","outEdges","pathData","shape","style","tooltip","verticalAlignment","visibility","width"],Mle=[],wle=(()=>{class n extends Hh{constructor(e){super(),this.viewContainerRef=e,Rl("currentInstance",this,this.viewContainerRef),this.registerEvents(Mle),this.directivePropList=ble}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-node-port"]],inputs:{addInfo:"addInfo",connectionDirection:"connectionDirection",constraints:"constraints",height:"height",horizontalAlignment:"horizontalAlignment",id:"id",inEdges:"inEdges",margin:"margin",offset:"offset",outEdges:"outEdges",pathData:"pathData",shape:"shape",style:"style",tooltip:"tooltip",verticalAlignment:"verticalAlignment",visibility:"visibility",width:"width"},features:[yn]}),n})(),Cle=(()=>{class n extends Bh{constructor(){super("ports")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-node-ports"]],contentQueries:function(e,i,r){if(1&e&&dn(r,wle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),Ele=["addInfo","annotations","backgroundColor","borderColor","borderWidth","branch","children","collapseIcon","columnIndex","columnSpan","columns","constraints","container","data","dragSize","excludeFromLayout","expandIcon","fixedUserHandles","flip","flipMode","height","horizontalAlignment","id","isExpanded","layoutInfo","margin","maxHeight","maxWidth","minHeight","minWidth","offsetX","offsetY","padding","pivot","ports","previewSize","rotateAngle","rowIndex","rowSpan","rows","shadow","shape","style","symbolInfo","tooltip","verticalAlignment","visible","width","wrapper","zIndex"],Dle=[],v_=(()=>{class n extends Hh{constructor(e){super(),this.viewContainerRef=e,this.tags=["fixedUserHandles","annotations","ports"],Rl("currentInstance",this,this.viewContainerRef),this.registerEvents(Dle),this.directivePropList=Ele}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-node"]],contentQueries:function(e,i,r){if(1&e&&(dn(r,vle,5),dn(r,Ile,5),dn(r,Cle,5)),2&e){let s;Kr(s=en())&&(i.childFixedUserHandles=s.first),Kr(s=en())&&(i.childAnnotations=s.first),Kr(s=en())&&(i.childPorts=s.first)}},inputs:{addInfo:"addInfo",annotations:"annotations",backgroundColor:"backgroundColor",borderColor:"borderColor",borderWidth:"borderWidth",branch:"branch",children:"children",collapseIcon:"collapseIcon",columnIndex:"columnIndex",columnSpan:"columnSpan",columns:"columns",constraints:"constraints",container:"container",data:"data",dragSize:"dragSize",excludeFromLayout:"excludeFromLayout",expandIcon:"expandIcon",fixedUserHandles:"fixedUserHandles",flip:"flip",flipMode:"flipMode",height:"height",horizontalAlignment:"horizontalAlignment",id:"id",isExpanded:"isExpanded",layoutInfo:"layoutInfo",margin:"margin",maxHeight:"maxHeight",maxWidth:"maxWidth",minHeight:"minHeight",minWidth:"minWidth",offsetX:"offsetX",offsetY:"offsetY",padding:"padding",pivot:"pivot",ports:"ports",previewSize:"previewSize",rotateAngle:"rotateAngle",rowIndex:"rowIndex",rowSpan:"rowSpan",rows:"rows",shadow:"shadow",shape:"shape",style:"style",symbolInfo:"symbolInfo",tooltip:"tooltip",verticalAlignment:"verticalAlignment",visible:"visible",width:"width",wrapper:"wrapper",zIndex:"zIndex"},features:[yn]}),n})(),m_=(()=>{class n extends Bh{constructor(){super("nodes")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-nodes"]],contentQueries:function(e,i,r){if(1&e&&dn(r,v_,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})();const xle=["animationComplete","click","collectionChange","commandExecute","connectionChange","contextMenuBeforeItemRender","contextMenuClick","contextMenuOpen","created","dataLoaded","doubleClick","dragEnter","dragLeave","dragOver","drop","elementDraw","expandStateChange","fixedUserHandleClick","historyChange","historyStateChange","keyDown","keyUp","load","loaded","mouseEnter","mouseLeave","mouseOver","mouseWheel","onFixedUserHandleMouseDown","onFixedUserHandleMouseEnter","onFixedUserHandleMouseLeave","onFixedUserHandleMouseUp","onImageLoad","onUserHandleMouseDown","onUserHandleMouseEnter","onUserHandleMouseLeave","onUserHandleMouseUp","positionChange","propertyChange","rotateChange","scrollChange","segmentChange","segmentCollectionChange","selectionChange","sizeChange","sourcePointChange","targetPointChange","textEdit"],Tle=[""];let Ale=(()=>{let n=class extends zl{constructor(e,i,r,s){super(),this.ngEle=e,this.srenderer=i,this.viewContainerRef=r,this.injector=s,this.tags=["layers","customCursor","connectors","nodes"],this.element=this.ngEle.nativeElement,this.injectedModules=this.injectedModules||[];try{let o=this.injector.get("DiagramsHierarchicalTree");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsMindMap");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsRadialTree");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsComplexHierarchicalTree");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsDataBinding");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsSnapping");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsPrintAndExport");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsBpmnDiagrams");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsSymmetricLayout");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsConnectorBridging");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsUndoRedo");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsLayoutAnimation");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsDiagramContextMenu");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsLineRouting");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsConnectorEditing");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsLineDistribution");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsEj1Serialization");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsFlowchartLayout");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}this.registerEvents(xle),this.addTwoWay.call(this,Tle),Rl("currentInstance",this,this.viewContainerRef),this.context=new u_}ngOnInit(){this.context.ngOnInit(this)}ngAfterViewInit(){this.context.ngAfterViewInit(this)}ngOnDestroy(){this.context.ngOnDestroy(this)}ngAfterContentChecked(){this.tagObjects[0].instance=this.childLayers,this.childCustomCursor&&(this.tagObjects[1].instance=this.childCustomCursor),this.childConnectors&&(this.tagObjects[2].instance=this.childConnectors),this.childNodes&&(this.tagObjects[3].instance=this.childNodes),this.context.ngAfterContentChecked(this)}};return n.\u0275fac=function(e){return new(e||n)(Ot($c),Ot(oM),Ot(xn),Ot(Wo))},n.\u0275cmp=Rb({type:n,selectors:[["ejs-diagram"]],contentQueries:function(e,i,r){if(1&e&&(dn(r,Wae,5),dn(r,Yae,5),dn(r,Qae,5),dn(r,$ae,5),dn(r,ele,5),dn(r,ule,5),dn(r,m_,5)),2&e){let s;Kr(s=en())&&(i.annotationTemplate=s.first),Kr(s=en())&&(i.nodeTemplate=s.first),Kr(s=en())&&(i.userHandleTemplate=s.first),Kr(s=en())&&(i.childLayers=s.first),Kr(s=en())&&(i.childCustomCursor=s.first),Kr(s=en())&&(i.childConnectors=s.first),Kr(s=en())&&(i.childNodes=s.first)}},inputs:{addInfo:"addInfo",annotationTemplate:"annotationTemplate",backgroundColor:"backgroundColor",bridgeDirection:"bridgeDirection",commandManager:"commandManager",connectorDefaults:"connectorDefaults",connectors:"connectors",constraints:"constraints",contextMenuSettings:"contextMenuSettings",customCursor:"customCursor",dataSourceSettings:"dataSourceSettings",diagramSettings:"diagramSettings",drawingObject:"drawingObject",enableConnectorSplit:"enableConnectorSplit",enablePersistence:"enablePersistence",enableRtl:"enableRtl",fixedUserHandleTemplate:"fixedUserHandleTemplate",getConnectorDefaults:"getConnectorDefaults",getCustomCursor:"getCustomCursor",getCustomProperty:"getCustomProperty",getCustomTool:"getCustomTool",getDescription:"getDescription",getNodeDefaults:"getNodeDefaults",height:"height",historyManager:"historyManager",layers:"layers",layout:"layout",locale:"locale",mode:"mode",nodeDefaults:"nodeDefaults",nodeTemplate:"nodeTemplate",nodes:"nodes",pageSettings:"pageSettings",rulerSettings:"rulerSettings",scrollSettings:"scrollSettings",segmentThumbShape:"segmentThumbShape",segmentThumbSize:"segmentThumbSize",selectedItems:"selectedItems",serializationSettings:"serializationSettings",setNodeTemplate:"setNodeTemplate",snapSettings:"snapSettings",tool:"tool",tooltip:"tooltip",updateSelection:"updateSelection",userHandleTemplate:"userHandleTemplate",width:"width"},outputs:{animationComplete:"animationComplete",click:"click",collectionChange:"collectionChange",commandExecute:"commandExecute",connectionChange:"connectionChange",contextMenuBeforeItemRender:"contextMenuBeforeItemRender",contextMenuClick:"contextMenuClick",contextMenuOpen:"contextMenuOpen",created:"created",dataLoaded:"dataLoaded",doubleClick:"doubleClick",dragEnter:"dragEnter",dragLeave:"dragLeave",dragOver:"dragOver",drop:"drop",elementDraw:"elementDraw",expandStateChange:"expandStateChange",fixedUserHandleClick:"fixedUserHandleClick",historyChange:"historyChange",historyStateChange:"historyStateChange",keyDown:"keyDown",keyUp:"keyUp",load:"load",loaded:"loaded",mouseEnter:"mouseEnter",mouseLeave:"mouseLeave",mouseOver:"mouseOver",mouseWheel:"mouseWheel",onFixedUserHandleMouseDown:"onFixedUserHandleMouseDown",onFixedUserHandleMouseEnter:"onFixedUserHandleMouseEnter",onFixedUserHandleMouseLeave:"onFixedUserHandleMouseLeave",onFixedUserHandleMouseUp:"onFixedUserHandleMouseUp",onImageLoad:"onImageLoad",onUserHandleMouseDown:"onUserHandleMouseDown",onUserHandleMouseEnter:"onUserHandleMouseEnter",onUserHandleMouseLeave:"onUserHandleMouseLeave",onUserHandleMouseUp:"onUserHandleMouseUp",positionChange:"positionChange",propertyChange:"propertyChange",rotateChange:"rotateChange",scrollChange:"scrollChange",segmentChange:"segmentChange",segmentCollectionChange:"segmentCollectionChange",selectionChange:"selectionChange",sizeChange:"sizeChange",sourcePointChange:"sourcePointChange",targetPointChange:"targetPointChange",textEdit:"textEdit"},features:[yn],decls:0,vars:0,template:function(e,i){},encapsulation:2,changeDetection:0}),ub([TT()],n.prototype,"annotationTemplate",void 0),ub([TT()],n.prototype,"nodeTemplate",void 0),ub([TT()],n.prototype,"userHandleTemplate",void 0),n=ub([Rae([u_])],n),n})(),Lle=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Am({type:n}),n.\u0275inj=gf({imports:[[rq]]}),n})();const Nle=["diagram"];let Ole=(()=>{class n{constructor(){this.ports=[{id:"port1",offset:{x:0,y:.5},visibility:ri.Visible}]}updatePorts(){this.diagram.nodes[0].ports[0].offset={x:1,y:1},this.diagram.dataBind()}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275cmp=Rb({type:n,selectors:[["app-container"]],viewQuery:function(i,r){if(1&i&&function uP(n,t,e){const i=xi();i.firstCreatePass&&(cP(i,new aP(n,t,e),-1),2==(2&t)&&(i.staticViewQueries=!0)),hP(i,Se(),t)}(Nle,5),2&i){let s;Kr(s=en())&&(r.diagram=s.first)}},standalone:!0,features:[PP([]),RP],decls:6,vars:5,consts:[["id","diagram","width","100%","height","580px"],["diagram",""],["id","node1",3,"offsetX","offsetY","width","height","ports"],[3,"click"]],template:function(i,r){1&i&&(lg(0,"ejs-diagram",0,1)(2,"e-nodes"),ew(3,"e-node",2),hg()(),lg(4,"button",3),ow("click",function(){return r.updatePorts()}),function MP(n,t=""){const e=Se(),i=xi(),r=n+Ut,s=i.firstCreatePass?xu(i,r,1,t,null):i.data[r],o=wP(i,e,s,t,n);e[r]=o,Rm()&&ly(i,e,o,s),ol(s,!1)}(5,"Update Ports"),hg()),2&i&&(function CN(n=1){EN(xi(),Se(),zs()+n,!1)}(3),GM("offsetX",150)("offsetY",150)("width",100)("height",100)("ports",r.ports))},dependencies:[Lle,Ale,v_,m_],encapsulation:2})}}return n})();Ud(332),function Xq(n,t){return CG({rootComponent:n,...Ez(t)})}(Ole).catch(n=>console.error(n))},332:()=>{!function(Z){const se=Z.performance;function ye(Pi){se&&se.mark&&se.mark(Pi)}function fe(Pi,ht){se&&se.measure&&se.measure(Pi,ht)}ye("Zone");const be=Z.__Zone_symbol_prefix||"__zone_symbol__";function ke(Pi){return be+Pi}const at=!0===Z[ke("forceDuplicateZoneCheck")];if(Z.Zone){if(at||"function"!=typeof Z.Zone.__symbol__)throw new Error("Zone already loaded.");return Z.Zone}let tt=(()=>{class Pi{static{this.__symbol__=ke}static assertZonePatched(){if(Z.Promise!==_o.ZoneAwarePromise)throw new Error("Zone.js has detected that ZoneAwarePromise `(window|global).Promise` has been overwritten.\nMost likely cause is that a Promise polyfill has been loaded after Zone.js (Polyfilling Promise api is not necessary when zone.js is loaded. If you must load one, do so before loading zone.js.)")}static get root(){let F=Pi.current;for(;F.parent;)F=F.parent;return F}static get current(){return Ur.zone}static get currentTask(){return Do}static __load_patch(F,ae,Et=!1){if(_o.hasOwnProperty(F)){if(!Et&&at)throw Error("Already loaded patch: "+F)}else if(!Z["__Zone_disable_"+F]){const Xt="Zone:"+F;ye(Xt),_o[F]=ae(Z,Pi,cn),fe(Xt,Xt)}}get parent(){return this._parent}get name(){return this._name}constructor(F,ae){this._parent=F,this._name=ae?ae.name||"unnamed":"",this._properties=ae&&ae.properties||{},this._zoneDelegate=new Lt(this,this._parent&&this._parent._zoneDelegate,ae)}get(F){const ae=this.getZoneWith(F);if(ae)return ae._properties[F]}getZoneWith(F){let ae=this;for(;ae;){if(ae._properties.hasOwnProperty(F))return ae;ae=ae._parent}return null}fork(F){if(!F)throw new Error("ZoneSpec required!");return this._zoneDelegate.fork(this,F)}wrap(F,ae){if("function"!=typeof F)throw new Error("Expecting function got: "+F);const Et=this._zoneDelegate.intercept(this,F,ae),Xt=this;return function(){return Xt.runGuarded(Et,this,arguments,ae)}}run(F,ae,Et,Xt){Ur={parent:Ur,zone:this};try{return this._zoneDelegate.invoke(this,F,ae,Et,Xt)}finally{Ur=Ur.parent}}runGuarded(F,ae=null,Et,Xt){Ur={parent:Ur,zone:this};try{try{return this._zoneDelegate.invoke(this,F,ae,Et,Xt)}catch(Un){if(this._zoneDelegate.handleError(this,Un))throw Un}}finally{Ur=Ur.parent}}runTask(F,ae,Et){if(F.zone!=this)throw new Error("A task can only be run in the zone of creation! (Creation: "+(F.zone||_n).name+"; Execution: "+this.name+")");if(F.state===sr&&(F.type===ts||F.type===Pt))return;const Xt=F.state!=lt;Xt&&F._transitionTo(lt,ki),F.runCount++;const Un=Do;Do=F,Ur={parent:Ur,zone:this};try{F.type==Pt&&F.data&&!F.data.isPeriodic&&(F.cancelFn=void 0);try{return this._zoneDelegate.invokeTask(this,F,ae,Et)}catch(Ue){if(this._zoneDelegate.handleError(this,Ue))throw Ue}}finally{F.state!==sr&&F.state!==et&&(F.type==ts||F.data&&F.data.isPeriodic?Xt&&F._transitionTo(ki,lt):(F.runCount=0,this._updateTaskCount(F,-1),Xt&&F._transitionTo(sr,lt,sr))),Ur=Ur.parent,Do=Un}}scheduleTask(F){if(F.zone&&F.zone!==this){let Et=this;for(;Et;){if(Et===F.zone)throw Error(`can not reschedule task to ${this.name} which is descendants of the original zone ${F.zone.name}`);Et=Et.parent}}F._transitionTo(Zr,sr);const ae=[];F._zoneDelegates=ae,F._zone=this;try{F=this._zoneDelegate.scheduleTask(this,F)}catch(Et){throw F._transitionTo(et,Zr,sr),this._zoneDelegate.handleError(this,Et),Et}return F._zoneDelegates===ae&&this._updateTaskCount(F,1),F.state==Zr&&F._transitionTo(ki,Zr),F}scheduleMicroTask(F,ae,Et,Xt){return this.scheduleTask(new ft(vi,F,ae,Et,Xt,void 0))}scheduleMacroTask(F,ae,Et,Xt,Un){return this.scheduleTask(new ft(Pt,F,ae,Et,Xt,Un))}scheduleEventTask(F,ae,Et,Xt,Un){return this.scheduleTask(new ft(ts,F,ae,Et,Xt,Un))}cancelTask(F){if(F.zone!=this)throw new Error("A task can only be cancelled in the zone of creation! (Creation: "+(F.zone||_n).name+"; Execution: "+this.name+")");if(F.state===ki||F.state===lt){F._transitionTo(dr,ki,lt);try{this._zoneDelegate.cancelTask(this,F)}catch(ae){throw F._transitionTo(et,dr),this._zoneDelegate.handleError(this,ae),ae}return this._updateTaskCount(F,-1),F._transitionTo(sr,dr),F.runCount=0,F}}_updateTaskCount(F,ae){const Et=F._zoneDelegates;-1==ae&&(F._zoneDelegates=null);for(let Xt=0;XtPi.hasTask(F,ae),onScheduleTask:(Pi,ht,F,ae)=>Pi.scheduleTask(F,ae),onInvokeTask:(Pi,ht,F,ae,Et,Xt)=>Pi.invokeTask(F,ae,Et,Xt),onCancelTask:(Pi,ht,F,ae)=>Pi.cancelTask(F,ae)};class Lt{constructor(ht,F,ae){this._taskCounts={microTask:0,macroTask:0,eventTask:0},this.zone=ht,this._parentDelegate=F,this._forkZS=ae&&(ae&&ae.onFork?ae:F._forkZS),this._forkDlgt=ae&&(ae.onFork?F:F._forkDlgt),this._forkCurrZone=ae&&(ae.onFork?this.zone:F._forkCurrZone),this._interceptZS=ae&&(ae.onIntercept?ae:F._interceptZS),this._interceptDlgt=ae&&(ae.onIntercept?F:F._interceptDlgt),this._interceptCurrZone=ae&&(ae.onIntercept?this.zone:F._interceptCurrZone),this._invokeZS=ae&&(ae.onInvoke?ae:F._invokeZS),this._invokeDlgt=ae&&(ae.onInvoke?F:F._invokeDlgt),this._invokeCurrZone=ae&&(ae.onInvoke?this.zone:F._invokeCurrZone),this._handleErrorZS=ae&&(ae.onHandleError?ae:F._handleErrorZS),this._handleErrorDlgt=ae&&(ae.onHandleError?F:F._handleErrorDlgt),this._handleErrorCurrZone=ae&&(ae.onHandleError?this.zone:F._handleErrorCurrZone),this._scheduleTaskZS=ae&&(ae.onScheduleTask?ae:F._scheduleTaskZS),this._scheduleTaskDlgt=ae&&(ae.onScheduleTask?F:F._scheduleTaskDlgt),this._scheduleTaskCurrZone=ae&&(ae.onScheduleTask?this.zone:F._scheduleTaskCurrZone),this._invokeTaskZS=ae&&(ae.onInvokeTask?ae:F._invokeTaskZS),this._invokeTaskDlgt=ae&&(ae.onInvokeTask?F:F._invokeTaskDlgt),this._invokeTaskCurrZone=ae&&(ae.onInvokeTask?this.zone:F._invokeTaskCurrZone),this._cancelTaskZS=ae&&(ae.onCancelTask?ae:F._cancelTaskZS),this._cancelTaskDlgt=ae&&(ae.onCancelTask?F:F._cancelTaskDlgt),this._cancelTaskCurrZone=ae&&(ae.onCancelTask?this.zone:F._cancelTaskCurrZone),this._hasTaskZS=null,this._hasTaskDlgt=null,this._hasTaskDlgtOwner=null,this._hasTaskCurrZone=null;const Et=ae&&ae.onHasTask;(Et||F&&F._hasTaskZS)&&(this._hasTaskZS=Et?ae:At,this._hasTaskDlgt=F,this._hasTaskDlgtOwner=this,this._hasTaskCurrZone=ht,ae.onScheduleTask||(this._scheduleTaskZS=At,this._scheduleTaskDlgt=F,this._scheduleTaskCurrZone=this.zone),ae.onInvokeTask||(this._invokeTaskZS=At,this._invokeTaskDlgt=F,this._invokeTaskCurrZone=this.zone),ae.onCancelTask||(this._cancelTaskZS=At,this._cancelTaskDlgt=F,this._cancelTaskCurrZone=this.zone))}fork(ht,F){return this._forkZS?this._forkZS.onFork(this._forkDlgt,this.zone,ht,F):new tt(ht,F)}intercept(ht,F,ae){return this._interceptZS?this._interceptZS.onIntercept(this._interceptDlgt,this._interceptCurrZone,ht,F,ae):F}invoke(ht,F,ae,Et,Xt){return this._invokeZS?this._invokeZS.onInvoke(this._invokeDlgt,this._invokeCurrZone,ht,F,ae,Et,Xt):F.apply(ae,Et)}handleError(ht,F){return!this._handleErrorZS||this._handleErrorZS.onHandleError(this._handleErrorDlgt,this._handleErrorCurrZone,ht,F)}scheduleTask(ht,F){let ae=F;if(this._scheduleTaskZS)this._hasTaskZS&&ae._zoneDelegates.push(this._hasTaskDlgtOwner),ae=this._scheduleTaskZS.onScheduleTask(this._scheduleTaskDlgt,this._scheduleTaskCurrZone,ht,F),ae||(ae=F);else if(F.scheduleFn)F.scheduleFn(F);else{if(F.type!=vi)throw new Error("Task is missing scheduleFn.");Wt(F)}return ae}invokeTask(ht,F,ae,Et){return this._invokeTaskZS?this._invokeTaskZS.onInvokeTask(this._invokeTaskDlgt,this._invokeTaskCurrZone,ht,F,ae,Et):F.callback.apply(ae,Et)}cancelTask(ht,F){let ae;if(this._cancelTaskZS)ae=this._cancelTaskZS.onCancelTask(this._cancelTaskDlgt,this._cancelTaskCurrZone,ht,F);else{if(!F.cancelFn)throw Error("Task is not cancelable");ae=F.cancelFn(F)}return ae}hasTask(ht,F){try{this._hasTaskZS&&this._hasTaskZS.onHasTask(this._hasTaskDlgt,this._hasTaskCurrZone,ht,F)}catch(ae){this.handleError(ht,ae)}}_updateTaskCount(ht,F){const ae=this._taskCounts,Et=ae[ht],Xt=ae[ht]=Et+F;if(Xt<0)throw new Error("More tasks executed then were scheduled.");0!=Et&&0!=Xt||this.hasTask(this.zone,{microTask:ae.microTask>0,macroTask:ae.macroTask>0,eventTask:ae.eventTask>0,change:ht})}}class ft{constructor(ht,F,ae,Et,Xt,Un){if(this._zone=null,this.runCount=0,this._zoneDelegates=null,this._state="notScheduled",this.type=ht,this.source=F,this.data=Et,this.scheduleFn=Xt,this.cancelFn=Un,!ae)throw new Error("callback is not defined");this.callback=ae;const Ue=this;this.invoke=ht===ts&&Et&&Et.useG?ft.invokeTask:function(){return ft.invokeTask.call(Z,Ue,this,arguments)}}static invokeTask(ht,F,ae){ht||(ht=this),Ls++;try{return ht.runCount++,ht.zone.runTask(ht,F,ae)}finally{1==Ls&&ct(),Ls--}}get zone(){return this._zone}get state(){return this._state}cancelScheduleRequest(){this._transitionTo(sr,Zr)}_transitionTo(ht,F,ae){if(this._state!==F&&this._state!==ae)throw new Error(`${this.type} '${this.source}': can not transition to '${ht}', expecting state '${F}'${ae?" or '"+ae+"'":""}, was '${this._state}'.`);this._state=ht,ht==sr&&(this._zoneDelegates=null)}toString(){return this.data&&typeof this.data.handleId<"u"?this.data.handleId.toString():Object.prototype.toString.call(this)}toJSON(){return{type:this.type,state:this.state,source:this.source,zone:this.zone.name,runCount:this.runCount}}}const Ei=ke("setTimeout"),ti=ke("Promise"),gi=ke("then");let es,cr=[],Oi=!1;function kr(Pi){if(es||Z[ti]&&(es=Z[ti].resolve(0)),es){let ht=es[gi];ht||(ht=es.then),ht.call(es,Pi)}else Z[Ei](Pi,0)}function Wt(Pi){0===Ls&&0===cr.length&&kr(ct),Pi&&cr.push(Pi)}function ct(){if(!Oi){for(Oi=!0;cr.length;){const Pi=cr;cr=[];for(let ht=0;htUr,onUnhandledError:jr,microtaskDrainDone:jr,scheduleMicroTask:Wt,showUncaughtError:()=>!tt[ke("ignoreConsoleErrorUncaughtError")],patchEventTarget:()=>[],patchOnProperties:jr,patchMethod:()=>jr,bindArguments:()=>[],patchThen:()=>jr,patchMacroTask:()=>jr,patchEventPrototype:()=>jr,isIEOrEdge:()=>!1,getGlobalObjects:()=>{},ObjectDefineProperty:()=>jr,ObjectGetOwnPropertyDescriptor:()=>{},ObjectCreate:()=>{},ArraySlice:()=>[],patchClass:()=>jr,wrapWithCurrentZone:()=>jr,filterProperties:()=>[],attachOriginToPatched:()=>jr,_redefineProperty:()=>jr,patchCallbacks:()=>jr,nativeScheduleMicroTask:kr};let Ur={parent:null,zone:new tt(null,null)},Do=null,Ls=0;function jr(){}fe("Zone","Zone"),Z.Zone=tt}(globalThis);const _l=Object.getOwnPropertyDescriptor,_d=Object.defineProperty,Ud=Object.getPrototypeOf,jd=Object.create,gb=Array.prototype.slice,pm="addEventListener",$r="removeEventListener",Ul=Zone.__symbol__(pm),Fh=Zone.__symbol__($r),Ts="true",Wi="false",Vd=Zone.__symbol__("");function of(Z,se){return Zone.current.wrap(Z,se)}function fm(Z,se,ye,fe,be){return Zone.current.scheduleMacroTask(Z,se,ye,fe,be)}const Ji=Zone.__symbol__,_h=typeof window<"u",Uh=_h?window:void 0,gn=_h&&Uh||globalThis,gm="removeAttribute";function Wd(Z,se){for(let ye=Z.length-1;ye>=0;ye--)"function"==typeof Z[ye]&&(Z[ye]=of(Z[ye],se+"_"+ye));return Z}function af(Z){return!Z||!1!==Z.writable&&!("function"==typeof Z.get&&typeof Z.set>"u")}const lf=typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope,jh=!("nw"in gn)&&typeof gn.process<"u"&&"[object process]"==={}.toString.call(gn.process),Yd=!jh&&!lf&&!(!_h||!Uh.HTMLElement),hf=typeof gn.process<"u"&&"[object process]"==={}.toString.call(gn.process)&&!lf&&!(!_h||!Uh.HTMLElement),jl={},Vh=function(Z){if(!(Z=Z||gn.event))return;let se=jl[Z.type];se||(se=jl[Z.type]=Ji("ON_PROPERTY"+Z.type));const ye=this||Z.target||gn,fe=ye[se];let be;return Yd&&ye===Uh&&"error"===Z.type?(be=fe&&fe.call(this,Z.message,Z.filename,Z.lineno,Z.colno,Z.error),!0===be&&Z.preventDefault()):(be=fe&&fe.apply(this,arguments),null!=be&&!be&&Z.preventDefault()),be};function Vl(Z,se,ye){let fe=_l(Z,se);if(!fe&&ye&&_l(ye,se)&&(fe={enumerable:!0,configurable:!0}),!fe||!fe.configurable)return;const be=Ji("on"+se+"patched");if(Z.hasOwnProperty(be)&&Z[be])return;delete fe.writable,delete fe.value;const ke=fe.get,at=fe.set,tt=se.slice(2);let At=jl[tt];At||(At=jl[tt]=Ji("ON_PROPERTY"+tt)),fe.set=function(Lt){let ft=this;!ft&&Z===gn&&(ft=gn),ft&&("function"==typeof ft[At]&&ft.removeEventListener(tt,Vh),at&&at.call(ft,null),ft[At]=Lt,"function"==typeof Lt&&ft.addEventListener(tt,Vh,!1))},fe.get=function(){let Lt=this;if(!Lt&&Z===gn&&(Lt=gn),!Lt)return null;const ft=Lt[At];if(ft)return ft;if(ke){let Ei=ke.call(this);if(Ei)return fe.set.call(this,Ei),"function"==typeof Lt[gm]&&Lt.removeAttribute(se),Ei}return null},_d(Z,se,fe),Z[be]=!0}function cf(Z,se,ye){if(se)for(let fe=0;fefunction(at,tt){const At=ye(at,tt);return At.cbIdx>=0&&"function"==typeof tt[At.cbIdx]?fm(At.name,tt[At.cbIdx],At,be):ke.apply(at,tt)})}function Sa(Z,se){Z[Ji("OriginalDelegate")]=se}let mb=!1,Gd=!1;function yb(){if(mb)return Gd;mb=!0;try{const Z=Uh.navigator.userAgent;(-1!==Z.indexOf("MSIE ")||-1!==Z.indexOf("Trident/")||-1!==Z.indexOf("Edge/"))&&(Gd=!0)}catch{}return Gd}Zone.__load_patch("ZoneAwarePromise",(Z,se,ye)=>{const fe=Object.getOwnPropertyDescriptor,be=Object.defineProperty,at=ye.symbol,tt=[],At=!1!==Z[at("DISABLE_WRAPPING_UNCAUGHT_PROMISE_REJECTION")],Lt=at("Promise"),ft=at("then"),Ei="__creationTrace__";ye.onUnhandledError=Ue=>{if(ye.showUncaughtError()){const He=Ue&&Ue.rejection;He?console.error("Unhandled Promise rejection:",He instanceof Error?He.message:He,"; Zone:",Ue.zone.name,"; Task:",Ue.task&&Ue.task.source,"; Value:",He,He instanceof Error?He.stack:void 0):console.error(Ue)}},ye.microtaskDrainDone=()=>{for(;tt.length;){const Ue=tt.shift();try{Ue.zone.runGuarded(()=>{throw Ue.throwOriginal?Ue.rejection:Ue})}catch(He){gi(He)}}};const ti=at("unhandledPromiseRejectionHandler");function gi(Ue){ye.onUnhandledError(Ue);try{const He=se[ti];"function"==typeof He&&He.call(this,Ue)}catch{}}function cr(Ue){return Ue&&Ue.then}function Oi(Ue){return Ue}function es(Ue){return F.reject(Ue)}const kr=at("state"),Wt=at("value"),ct=at("finally"),_n=at("parentPromiseValue"),sr=at("parentPromiseState"),Zr="Promise.then",ki=null,lt=!0,dr=!1,et=0;function vi(Ue,He){return ge=>{try{cn(Ue,He,ge)}catch(We){cn(Ue,!1,We)}}}const Pt=function(){let Ue=!1;return function(ge){return function(){Ue||(Ue=!0,ge.apply(null,arguments))}}},ts="Promise resolved with itself",_o=at("currentTaskTrace");function cn(Ue,He,ge){const We=Pt();if(Ue===ge)throw new TypeError(ts);if(Ue[kr]===ki){let wt=null;try{("object"==typeof ge||"function"==typeof ge)&&(wt=ge&&ge.then)}catch(Xe){return We(()=>{cn(Ue,!1,Xe)})(),Ue}if(He!==dr&&ge instanceof F&&ge.hasOwnProperty(kr)&&ge.hasOwnProperty(Wt)&&ge[kr]!==ki)Do(ge),cn(Ue,ge[kr],ge[Wt]);else if(He!==dr&&"function"==typeof wt)try{wt.call(ge,We(vi(Ue,He)),We(vi(Ue,!1)))}catch(Xe){We(()=>{cn(Ue,!1,Xe)})()}else{Ue[kr]=He;const Xe=Ue[Wt];if(Ue[Wt]=ge,Ue[ct]===ct&&He===lt&&(Ue[kr]=Ue[sr],Ue[Wt]=Ue[_n]),He===dr&&ge instanceof Error){const mt=se.currentTask&&se.currentTask.data&&se.currentTask.data[Ei];mt&&be(ge,_o,{configurable:!0,enumerable:!1,writable:!0,value:mt})}for(let mt=0;mt{try{const dt=Ue[Wt],qt=!!ge&&ct===ge[ct];qt&&(ge[_n]=dt,ge[sr]=Xe);const li=He.run(mt,void 0,qt&&mt!==es&&mt!==Oi?[]:[dt]);cn(ge,!0,li)}catch(dt){cn(ge,!1,dt)}},ge)}const Pi=function(){},ht=Z.AggregateError;class F{static toString(){return"function ZoneAwarePromise() { [native code] }"}static resolve(He){return He instanceof F?He:cn(new this(null),lt,He)}static reject(He){return cn(new this(null),dr,He)}static withResolvers(){const He={};return He.promise=new F((ge,We)=>{He.resolve=ge,He.reject=We}),He}static any(He){if(!He||"function"!=typeof He[Symbol.iterator])return Promise.reject(new ht([],"All promises were rejected"));const ge=[];let We=0;try{for(let mt of He)We++,ge.push(F.resolve(mt))}catch{return Promise.reject(new ht([],"All promises were rejected"))}if(0===We)return Promise.reject(new ht([],"All promises were rejected"));let wt=!1;const Xe=[];return new F((mt,dt)=>{for(let qt=0;qt{wt||(wt=!0,mt(li))},li=>{Xe.push(li),We--,0===We&&(wt=!0,dt(new ht(Xe,"All promises were rejected")))})})}static race(He){let ge,We,wt=new this((dt,qt)=>{ge=dt,We=qt});function Xe(dt){ge(dt)}function mt(dt){We(dt)}for(let dt of He)cr(dt)||(dt=this.resolve(dt)),dt.then(Xe,mt);return wt}static all(He){return F.allWithCallback(He)}static allSettled(He){return(this&&this.prototype instanceof F?this:F).allWithCallback(He,{thenCallback:We=>({status:"fulfilled",value:We}),errorCallback:We=>({status:"rejected",reason:We})})}static allWithCallback(He,ge){let We,wt,Xe=new this((li,ur)=>{We=li,wt=ur}),mt=2,dt=0;const qt=[];for(let li of He){cr(li)||(li=this.resolve(li));const ur=dt;try{li.then(ir=>{qt[ur]=ge?ge.thenCallback(ir):ir,mt--,0===mt&&We(qt)},ir=>{ge?(qt[ur]=ge.errorCallback(ir),mt--,0===mt&&We(qt)):wt(ir)})}catch(ir){wt(ir)}mt++,dt++}return mt-=2,0===mt&&We(qt),Xe}constructor(He){const ge=this;if(!(ge instanceof F))throw new Error("Must be an instanceof Promise.");ge[kr]=ki,ge[Wt]=[];try{const We=Pt();He&&He(We(vi(ge,lt)),We(vi(ge,dr)))}catch(We){cn(ge,!1,We)}}get[Symbol.toStringTag](){return"Promise"}get[Symbol.species](){return F}then(He,ge){let We=this.constructor?.[Symbol.species];(!We||"function"!=typeof We)&&(We=this.constructor||F);const wt=new We(Pi),Xe=se.current;return this[kr]==ki?this[Wt].push(Xe,wt,He,ge):Ls(this,Xe,wt,He,ge),wt}catch(He){return this.then(null,He)}finally(He){let ge=this.constructor?.[Symbol.species];(!ge||"function"!=typeof ge)&&(ge=F);const We=new ge(Pi);We[ct]=ct;const wt=se.current;return this[kr]==ki?this[Wt].push(wt,We,He,He):Ls(this,wt,We,He,He),We}}F.resolve=F.resolve,F.reject=F.reject,F.race=F.race,F.all=F.all;const ae=Z[Lt]=Z.Promise;Z.Promise=F;const Et=at("thenPatched");function Xt(Ue){const He=Ue.prototype,ge=fe(He,"then");if(ge&&(!1===ge.writable||!ge.configurable))return;const We=He.then;He[ft]=We,Ue.prototype.then=function(wt,Xe){return new F((dt,qt)=>{We.call(this,dt,qt)}).then(wt,Xe)},Ue[Et]=!0}return ye.patchThen=Xt,ae&&(Xt(ae),Ka(Z,"fetch",Ue=>function Un(Ue){return function(He,ge){let We=Ue.apply(He,ge);if(We instanceof F)return We;let wt=We.constructor;return wt[Et]||Xt(wt),We}}(Ue))),Promise[se.__symbol__("uncaughtPromiseErrors")]=tt,F}),Zone.__load_patch("toString",Z=>{const se=Function.prototype.toString,ye=Ji("OriginalDelegate"),fe=Ji("Promise"),be=Ji("Error"),ke=function(){if("function"==typeof this){const Lt=this[ye];if(Lt)return"function"==typeof Lt?se.call(Lt):Object.prototype.toString.call(Lt);if(this===Promise){const ft=Z[fe];if(ft)return se.call(ft)}if(this===Error){const ft=Z[be];if(ft)return se.call(ft)}}return se.call(this)};ke[ye]=se,Function.prototype.toString=ke;const at=Object.prototype.toString;Object.prototype.toString=function(){return"function"==typeof Promise&&this instanceof Promise?"[object Promise]":at.call(this)}});let el=!1;if(typeof window<"u")try{const Z=Object.defineProperty({},"passive",{get:function(){el=!0}});window.addEventListener("test",Z,Z),window.removeEventListener("test",Z,Z)}catch{el=!1}const kT={useG:!0},Co={},Sb={},ym=new RegExp("^"+Vd+"(\\w+)(true|false)$"),Ib=Ji("propagationStopped");function Sm(Z,se){const ye=(se?se(Z):Z)+Wi,fe=(se?se(Z):Z)+Ts,be=Vd+ye,ke=Vd+fe;Co[Z]={},Co[Z][Wi]=be,Co[Z][Ts]=ke}function bb(Z,se,ye,fe){const be=fe&&fe.add||pm,ke=fe&&fe.rm||$r,at=fe&&fe.listeners||"eventListeners",tt=fe&&fe.rmAll||"removeAllListeners",At=Ji(be),Lt="."+be+":",ft="prependListener",Ei="."+ft+":",ti=function(Wt,ct,_n){if(Wt.isRemoved)return;const sr=Wt.callback;let Zr;"object"==typeof sr&&sr.handleEvent&&(Wt.callback=lt=>sr.handleEvent(lt),Wt.originalDelegate=sr);try{Wt.invoke(Wt,ct,[_n])}catch(lt){Zr=lt}const ki=Wt.options;return ki&&"object"==typeof ki&&ki.once&&ct[ke].call(ct,_n.type,Wt.originalDelegate?Wt.originalDelegate:Wt.callback,ki),Zr};function gi(Wt,ct,_n){if(!(ct=ct||Z.event))return;const sr=Wt||ct.target||Z,Zr=sr[Co[ct.type][_n?Ts:Wi]];if(Zr){const ki=[];if(1===Zr.length){const lt=ti(Zr[0],sr,ct);lt&&ki.push(lt)}else{const lt=Zr.slice();for(let dr=0;dr{throw dr})}}}const cr=function(Wt){return gi(this,Wt,!1)},Oi=function(Wt){return gi(this,Wt,!0)};function es(Wt,ct){if(!Wt)return!1;let _n=!0;ct&&void 0!==ct.useG&&(_n=ct.useG);const sr=ct&&ct.vh;let Zr=!0;ct&&void 0!==ct.chkDup&&(Zr=ct.chkDup);let ki=!1;ct&&void 0!==ct.rt&&(ki=ct.rt);let lt=Wt;for(;lt&&!lt.hasOwnProperty(be);)lt=Ud(lt);if(!lt&&Wt[be]&&(lt=Wt),!lt||lt[At])return!1;const dr=ct&&ct.eventNameToString,et={},vi=lt[At]=lt[be],Pt=lt[Ji(ke)]=lt[ke],ts=lt[Ji(at)]=lt[at],_o=lt[Ji(tt)]=lt[tt];let cn;ct&&ct.prepend&&(cn=lt[Ji(ct.prepend)]=lt[ct.prepend]);const F=_n?function(ge){if(!et.isExisting)return vi.call(et.target,et.eventName,et.capture?Oi:cr,et.options)}:function(ge){return vi.call(et.target,et.eventName,ge.invoke,et.options)},ae=_n?function(ge){if(!ge.isRemoved){const We=Co[ge.eventName];let wt;We&&(wt=We[ge.capture?Ts:Wi]);const Xe=wt&&ge.target[wt];if(Xe)for(let mt=0;mt{Vo.zone.cancelTask(Vo)},{once:!0})),et.target=null,Fc&&(Fc.taskData=null),qd&&(Dn.once=!0),!el&&"boolean"==typeof Vo.options||(Vo.options=Dn),Vo.target=qt,Vo.capture=Gl,Vo.eventName=li,ir&&(Vo.originalDelegate=ur),dt?jo.unshift(Vo):jo.push(Vo),mt?qt:void 0}};return lt[be]=He(vi,Lt,F,ae,ki),cn&&(lt[ft]=He(cn,Ei,function(ge){return cn.call(et.target,et.eventName,ge.invoke,et.options)},ae,ki,!0)),lt[ke]=function(){const ge=this||Z;let We=arguments[0];ct&&ct.transferEventName&&(We=ct.transferEventName(We));const wt=arguments[2],Xe=!!wt&&("boolean"==typeof wt||wt.capture),mt=arguments[1];if(!mt)return Pt.apply(this,arguments);if(sr&&!sr(Pt,mt,ge,arguments))return;const dt=Co[We];let qt;dt&&(qt=dt[Xe?Ts:Wi]);const li=qt&&ge[qt];if(li)for(let ur=0;urfunction(be,ke){be[Ib]=!0,fe&&fe.apply(be,ke)})}function wb(Z,se,ye,fe,be){const ke=Zone.__symbol__(fe);if(se[ke])return;const at=se[ke]=se[fe];se[fe]=function(tt,At,Lt){return At&&At.prototype&&be.forEach(function(ft){const Ei=`${ye}.${fe}::`+ft,ti=At.prototype;try{if(ti.hasOwnProperty(ft)){const gi=Z.ObjectGetOwnPropertyDescriptor(ti,ft);gi&&gi.value?(gi.value=Z.wrapWithCurrentZone(gi.value,Ei),Z._redefineProperty(At.prototype,ft,gi)):ti[ft]&&(ti[ft]=Z.wrapWithCurrentZone(ti[ft],Ei))}else ti[ft]&&(ti[ft]=Z.wrapWithCurrentZone(ti[ft],Ei))}catch{}}),at.call(se,tt,At,Lt)},Z.attachOriginToPatched(se[fe],at)}function Cb(Z,se,ye){if(!ye||0===ye.length)return se;const fe=ye.filter(ke=>ke.target===Z);if(!fe||0===fe.length)return se;const be=fe[0].ignoreProperties;return se.filter(ke=>-1===be.indexOf(ke))}function Eo(Z,se,ye,fe){Z&&cf(Z,Cb(Z,se,ye),fe)}function Xd(Z){return Object.getOwnPropertyNames(Z).filter(se=>se.startsWith("on")&&se.length>2).map(se=>se.substring(2))}Zone.__load_patch("util",(Z,se,ye)=>{const fe=Xd(Z);ye.patchOnProperties=cf,ye.patchMethod=Ka,ye.bindArguments=Wd,ye.patchMacroTask=vb;const be=se.__symbol__("BLACK_LISTED_EVENTS"),ke=se.__symbol__("UNPATCHED_EVENTS");Z[ke]&&(Z[be]=Z[ke]),Z[be]&&(se[be]=se[ke]=Z[be]),ye.patchEventPrototype=Im,ye.patchEventTarget=bb,ye.isIEOrEdge=yb,ye.ObjectDefineProperty=_d,ye.ObjectGetOwnPropertyDescriptor=_l,ye.ObjectCreate=jd,ye.ArraySlice=gb,ye.patchClass=Qd,ye.wrapWithCurrentZone=of,ye.filterProperties=Cb,ye.attachOriginToPatched=Sa,ye._redefineProperty=Object.defineProperty,ye.patchCallbacks=wb,ye.getGlobalObjects=()=>({globalSources:Sb,zoneSymbolEventNames:Co,eventNames:fe,isBrowser:Yd,isMix:hf,isNode:jh,TRUE_STR:Ts,FALSE_STR:Wi,ZONE_SYMBOL_PREFIX:Vd,ADD_EVENT_LISTENER_STR:pm,REMOVE_EVENT_LISTENER_STR:$r})});const As=Ji("zoneTask");function Wl(Z,se,ye,fe){let be=null,ke=null;ye+=fe;const at={};function tt(Lt){const ft=Lt.data;return ft.args[0]=function(){return Lt.invoke.apply(this,arguments)},ft.handleId=be.apply(Z,ft.args),Lt}function At(Lt){return ke.call(Z,Lt.data.handleId)}be=Ka(Z,se+=fe,Lt=>function(ft,Ei){if("function"==typeof Ei[0]){const ti={isPeriodic:"Interval"===fe,delay:"Timeout"===fe||"Interval"===fe?Ei[1]||0:void 0,args:Ei},gi=Ei[0];Ei[0]=function(){try{return gi.apply(this,arguments)}finally{ti.isPeriodic||("number"==typeof ti.handleId?delete at[ti.handleId]:ti.handleId&&(ti.handleId[As]=null))}};const cr=fm(se,Ei[0],ti,tt,At);if(!cr)return cr;const Oi=cr.data.handleId;return"number"==typeof Oi?at[Oi]=cr:Oi&&(Oi[As]=cr),Oi&&Oi.ref&&Oi.unref&&"function"==typeof Oi.ref&&"function"==typeof Oi.unref&&(cr.ref=Oi.ref.bind(Oi),cr.unref=Oi.unref.bind(Oi)),"number"==typeof Oi||Oi?Oi:cr}return Lt.apply(Z,Ei)}),ke=Ka(Z,ye,Lt=>function(ft,Ei){const ti=Ei[0];let gi;"number"==typeof ti?gi=at[ti]:(gi=ti&&ti[As],gi||(gi=ti)),gi&&"string"==typeof gi.type?"notScheduled"!==gi.state&&(gi.cancelFn&&gi.data.isPeriodic||0===gi.runCount)&&("number"==typeof ti?delete at[ti]:ti&&(ti[As]=null),gi.zone.cancelTask(gi)):Lt.apply(Z,Ei)})}Zone.__load_patch("legacy",Z=>{const se=Z[Zone.__symbol__("legacyPatch")];se&&se()}),Zone.__load_patch("timers",Z=>{const ye="clear";Wl(Z,"set",ye,"Timeout"),Wl(Z,"set",ye,"Interval"),Wl(Z,"set",ye,"Immediate")}),Zone.__load_patch("requestAnimationFrame",Z=>{Wl(Z,"request","cancel","AnimationFrame"),Wl(Z,"mozRequest","mozCancel","AnimationFrame"),Wl(Z,"webkitRequest","webkitCancel","AnimationFrame")}),Zone.__load_patch("blocking",(Z,se)=>{const ye=["alert","prompt","confirm"];for(let fe=0;fefunction(At,Lt){return se.current.run(ke,Z,Lt,tt)})}),Zone.__load_patch("EventTarget",(Z,se,ye)=>{(function Yl(Z,se){se.patchEventPrototype(Z,se)})(Z,ye),function Mm(Z,se){if(Zone[se.symbol("patchEventTarget")])return;const{eventNames:ye,zoneSymbolEventNames:fe,TRUE_STR:be,FALSE_STR:ke,ZONE_SYMBOL_PREFIX:at}=se.getGlobalObjects();for(let At=0;At{Qd("MutationObserver"),Qd("WebKitMutationObserver")}),Zone.__load_patch("IntersectionObserver",(Z,se,ye)=>{Qd("IntersectionObserver")}),Zone.__load_patch("FileReader",(Z,se,ye)=>{Qd("FileReader")}),Zone.__load_patch("on_property",(Z,se,ye)=>{!function df(Z,se){if(jh&&!hf||Zone[Z.symbol("patchEvents")])return;const ye=se.__Zone_ignore_on_properties;let fe=[];if(Yd){const be=window;fe=fe.concat(["Document","SVGElement","Element","HTMLElement","HTMLBodyElement","HTMLMediaElement","HTMLFrameSetElement","HTMLFrameElement","HTMLIFrameElement","HTMLMarqueeElement","Worker"]);const ke=function mm(){try{const Z=Uh.navigator.userAgent;if(-1!==Z.indexOf("MSIE ")||-1!==Z.indexOf("Trident/"))return!0}catch{}return!1}()?[{target:be,ignoreProperties:["error"]}]:[];Eo(be,Xd(be),ye&&ye.concat(ke),Ud(be))}fe=fe.concat(["XMLHttpRequest","XMLHttpRequestEventTarget","IDBIndex","IDBRequest","IDBOpenDBRequest","IDBDatabase","IDBTransaction","IDBCursor","WebSocket"]);for(let be=0;be{!function bm(Z,se){const{isBrowser:ye,isMix:fe}=se.getGlobalObjects();(ye||fe)&&Z.customElements&&"customElements"in Z&&se.patchCallbacks(se,Z.customElements,"customElements","define",["connectedCallback","disconnectedCallback","adoptedCallback","attributeChangedCallback"])}(Z,ye)}),Zone.__load_patch("XHR",(Z,se)=>{!function At(Lt){const ft=Lt.XMLHttpRequest;if(!ft)return;const Ei=ft.prototype;let gi=Ei[Ul],cr=Ei[Fh];if(!gi){const et=Lt.XMLHttpRequestEventTarget;if(et){const vi=et.prototype;gi=vi[Ul],cr=vi[Fh]}}const Oi="readystatechange",es="scheduled";function kr(et){const vi=et.data,Pt=vi.target;Pt[ke]=!1,Pt[tt]=!1;const ts=Pt[be];gi||(gi=Pt[Ul],cr=Pt[Fh]),ts&&cr.call(Pt,Oi,ts);const _o=Pt[be]=()=>{if(Pt.readyState===Pt.DONE)if(!vi.aborted&&Pt[ke]&&et.state===es){const Ur=Pt[se.__symbol__("loadfalse")];if(0!==Pt.status&&Ur&&Ur.length>0){const Do=et.invoke;et.invoke=function(){const Ls=Pt[se.__symbol__("loadfalse")];for(let jr=0;jrfunction(et,vi){return et[fe]=0==vi[2],et[at]=vi[1],_n.apply(et,vi)}),Zr=Ji("fetchTaskAborting"),ki=Ji("fetchTaskScheduling"),lt=Ka(Ei,"send",()=>function(et,vi){if(!0===se.current[ki]||et[fe])return lt.apply(et,vi);{const Pt={target:et,url:et[at],isPeriodic:!1,args:vi,aborted:!1},ts=fm("XMLHttpRequest.send",Wt,Pt,kr,ct);et&&!0===et[tt]&&!Pt.aborted&&ts.state===es&&ts.invoke()}}),dr=Ka(Ei,"abort",()=>function(et,vi){const Pt=function ti(et){return et[ye]}(et);if(Pt&&"string"==typeof Pt.type){if(null==Pt.cancelFn||Pt.data&&Pt.data.aborted)return;Pt.zone.cancelTask(Pt)}else if(!0===se.current[Zr])return dr.apply(et,vi)})}(Z);const ye=Ji("xhrTask"),fe=Ji("xhrSync"),be=Ji("xhrListener"),ke=Ji("xhrScheduled"),at=Ji("xhrURL"),tt=Ji("xhrErrorBeforeScheduled")}),Zone.__load_patch("geolocation",Z=>{Z.navigator&&Z.navigator.geolocation&&function vm(Z,se){const ye=Z.constructor.name;for(let fe=0;fe{const At=function(){return tt.apply(this,Wd(arguments,ye+"."+be))};return Sa(At,tt),At})(ke)}}}(Z.navigator.geolocation,["getCurrentPosition","watchPosition"])}),Zone.__load_patch("PromiseRejectionEvent",(Z,se)=>{function ye(fe){return function(be){Mb(Z,fe).forEach(at=>{const tt=Z.PromiseRejectionEvent;if(tt){const At=new tt(fe,{promise:be.promise,reason:be.rejection});at.invoke(At)}})}}Z.PromiseRejectionEvent&&(se[Ji("unhandledPromiseRejectionHandler")]=ye("unhandledrejection"),se[Ji("rejectionHandledHandler")]=ye("rejectionhandled"))}),Zone.__load_patch("queueMicrotask",(Z,se,ye)=>{!function uf(Z,se){se.patchMethod(Z,"queueMicrotask",ye=>function(fe,be){Zone.current.scheduleMicroTask("queueMicrotask",be[0])})}(Z,ye)})}},_l=>{_l(_l.s=51)}]); \ No newline at end of file diff --git a/ej2-angular/samples/diagram/ports/node-cs1/main.7ea7dd8033e7551a.js b/ej2-angular/samples/diagram/ports/node-cs1/main.7ea7dd8033e7551a.js new file mode 100644 index 0000000000..26f0815801 --- /dev/null +++ b/ej2-angular/samples/diagram/ports/node-cs1/main.7ea7dd8033e7551a.js @@ -0,0 +1 @@ +"use strict";(self.webpackChunksyncfusion_component=self.webpackChunksyncfusion_component||[]).push([[179],{51:(Wl,Ud,jd)=>{let $r=null,_h=1;const Ts=Symbol("SIGNAL");function Wi(n){const t=$r;return $r=n,t}function gn(n){if((!Wh(n)||n.dirty)&&(n.dirty||n.lastCleanEpoch!==_h)){if(!n.producerMustRecompute(n)&&!Vh(n))return n.dirty=!1,void(n.lastCleanEpoch=_h);n.producerRecomputeValue(n),n.dirty=!1,n.lastCleanEpoch=_h}}function Vh(n){Gl(n);for(let t=0;t0}function Gl(n){n.producerNode??=[],n.producerIndexOfThis??=[],n.producerLastReadVersion??=[]}let Xd=null;function Eo(n){return"function"==typeof n}function qd(n){const e=n(i=>{Error.call(i),i.stack=(new Error).stack});return e.prototype=Object.create(Error.prototype),e.prototype.constructor=e,e}const dp=qd(n=>function(e){n(this),this.message=e?`${e.length} errors occurred during unsubscription:\n${e.map((i,r)=>`${r+1}) ${i.toString()}`).join("\n ")}`:"",this.name="UnsubscriptionError",this.errors=e});function up(n,t){if(n){const e=n.indexOf(t);0<=e&&n.splice(e,1)}}class As{constructor(t){this.initialTeardown=t,this.closed=!1,this._parentage=null,this._finalizers=null}unsubscribe(){let t;if(!this.closed){this.closed=!0;const{_parentage:e}=this;if(e)if(this._parentage=null,Array.isArray(e))for(const s of e)s.remove(this);else e.remove(this);const{initialTeardown:i}=this;if(Eo(i))try{i()}catch(s){t=s instanceof dp?s.errors:[s]}const{_finalizers:r}=this;if(r){this._finalizers=null;for(const s of r)try{wm(s)}catch(o){t=t??[],o instanceof dp?t=[...t,...o.errors]:t.push(o)}}if(t)throw new dp(t)}}add(t){var e;if(t&&t!==this)if(this.closed)wm(t);else{if(t instanceof As){if(t.closed||t._hasParent(this))return;t._addParent(this)}(this._finalizers=null!==(e=this._finalizers)&&void 0!==e?e:[]).push(t)}}_hasParent(t){const{_parentage:e}=this;return e===t||Array.isArray(e)&&e.includes(t)}_addParent(t){const{_parentage:e}=this;this._parentage=Array.isArray(e)?(e.push(t),e):e?[e,t]:t}_removeParent(t){const{_parentage:e}=this;e===t?this._parentage=null:Array.isArray(e)&&up(e,t)}remove(t){const{_finalizers:e}=this;e&&up(e,t),t instanceof As&&t._removeParent(this)}}As.EMPTY=(()=>{const n=new As;return n.closed=!0,n})();const Xl=As.EMPTY;function Mm(n){return n instanceof As||n&&"closed"in n&&Eo(n.remove)&&Eo(n.add)&&Eo(n.unsubscribe)}function wm(n){Eo(n)?n():n.unsubscribe()}const ql={onUnhandledError:null,onStoppedNotification:null,Promise:void 0,useDeprecatedSynchronousErrorHandling:!1,useDeprecatedNextContext:!1},Z={setTimeout(n,t,...e){const{delegate:i}=Z;return i?.setTimeout?i.setTimeout(n,t,...e):setTimeout(n,t,...e)},clearTimeout(n){const{delegate:t}=Z;return(t?.clearTimeout||clearTimeout)(n)},delegate:void 0};function ye(){}const pe=at("C",void 0,void 0);function at(n,t,e){return{kind:n,value:t,error:e}}let tt=null;function At(n){if(ql.useDeprecatedSynchronousErrorHandling){const t=!tt;if(t&&(tt={errorThrown:!1,error:null}),n(),t){const{errorThrown:e,error:i}=tt;if(tt=null,e)throw i}}else n()}class pt extends As{constructor(t){super(),this.isStopped=!1,t?(this.destination=t,Mm(t)&&t.add(this)):this.destination=Wt}static create(t,e,i){return new cr(t,e,i)}next(t){this.isStopped?Pr(function ke(n){return at("N",n,void 0)}(t),this):this._next(t)}error(t){this.isStopped?Pr(function be(n){return at("E",void 0,n)}(t),this):(this.isStopped=!0,this._error(t))}complete(){this.isStopped?Pr(pe,this):(this.isStopped=!0,this._complete())}unsubscribe(){this.closed||(this.isStopped=!0,super.unsubscribe(),this.destination=null)}_next(t){this.destination.next(t)}_error(t){try{this.destination.error(t)}finally{this.unsubscribe()}}_complete(){try{this.destination.complete()}finally{this.unsubscribe()}}}const Di=Function.prototype.bind;function ni(n,t){return Di.call(n,t)}class mi{constructor(t){this.partialObserver=t}next(t){const{partialObserver:e}=this;if(e.next)try{e.next(t)}catch(i){ki(i)}}error(t){const{partialObserver:e}=this;if(e.error)try{e.error(t)}catch(i){ki(i)}else ki(t)}complete(){const{partialObserver:t}=this;if(t.complete)try{t.complete()}catch(e){ki(e)}}}class cr extends pt{constructor(t,e,i){let r;if(super(),Eo(t)||!t)r={next:t??void 0,error:e??void 0,complete:i??void 0};else{let s;this&&ql.useDeprecatedNextContext?(s=Object.create(t),s.unsubscribe=()=>this.unsubscribe(),r={next:t.next&&ni(t.next,s),error:t.error&&ni(t.error,s),complete:t.complete&&ni(t.complete,s)}):r=t}this.destination=new mi(r)}}function ki(n){ql.useDeprecatedSynchronousErrorHandling?function Lt(n){ql.useDeprecatedSynchronousErrorHandling&&tt&&(tt.errorThrown=!0,tt.error=n)}(n):function se(n){Z.setTimeout(()=>{const{onUnhandledError:t}=ql;if(!t)throw n;t(n)})}(n)}function Pr(n,t){const{onStoppedNotification:e}=ql;e&&Z.setTimeout(()=>e(n,t))}const Wt={closed:!0,next:ye,error:function is(n){throw n},complete:ye},ct="function"==typeof Symbol&&Symbol.observable||"@@observable";function jn(n){return n}let Pi=(()=>{class n{constructor(e){e&&(this._subscribe=e)}lift(e){const i=new n;return i.source=this,i.operator=e,i}subscribe(e,i,r){const s=function et(n){return n&&n instanceof pt||function dr(n){return n&&Eo(n.next)&&Eo(n.error)&&Eo(n.complete)}(n)&&Mm(n)}(e)?e:new cr(e,i,r);return At(()=>{const{operator:o,source:a}=this;s.add(o?o.call(s,a):a?this._subscribe(s):this._trySubscribe(s))}),s}_trySubscribe(e){try{return this._subscribe(e)}catch(i){e.error(i)}}forEach(e,i){return new(i=lt(i))((r,s)=>{const o=new cr({next:a=>{try{e(a)}catch(l){s(l),o.unsubscribe()}},error:s,complete:r});this.subscribe(o)})}_subscribe(e){var i;return null===(i=this.source)||void 0===i?void 0:i.subscribe(e)}[ct](){return this}pipe(...e){return function Zr(n){return 0===n.length?jn:1===n.length?n[0]:function(e){return n.reduce((i,r)=>r(i),e)}}(e)(this)}toPromise(e){return new(e=lt(e))((i,r)=>{let s;this.subscribe(o=>s=o,o=>r(o),()=>i(s))})}}return n.create=t=>new n(t),n})();function lt(n){var t;return null!==(t=n??ql.Promise)&&void 0!==t?t:Promise}const yi=qd(n=>function(){n(this),this.name="ObjectUnsubscribedError",this.message="object unsubscribed"});let Pt=(()=>{class n extends Pi{constructor(){super(),this.closed=!1,this.currentObservers=null,this.observers=[],this.isStopped=!1,this.hasError=!1,this.thrownError=null}lift(e){const i=new rs(this,this);return i.operator=e,i}_throwIfClosed(){if(this.closed)throw new yi}next(e){At(()=>{if(this._throwIfClosed(),!this.isStopped){this.currentObservers||(this.currentObservers=Array.from(this.observers));for(const i of this.currentObservers)i.next(e)}})}error(e){At(()=>{if(this._throwIfClosed(),!this.isStopped){this.hasError=this.isStopped=!0,this.thrownError=e;const{observers:i}=this;for(;i.length;)i.shift().error(e)}})}complete(){At(()=>{if(this._throwIfClosed(),!this.isStopped){this.isStopped=!0;const{observers:e}=this;for(;e.length;)e.shift().complete()}})}unsubscribe(){this.isStopped=this.closed=!0,this.observers=this.currentObservers=null}get observed(){var e;return(null===(e=this.observers)||void 0===e?void 0:e.length)>0}_trySubscribe(e){return this._throwIfClosed(),super._trySubscribe(e)}_subscribe(e){return this._throwIfClosed(),this._checkFinalizedStatuses(e),this._innerSubscribe(e)}_innerSubscribe(e){const{hasError:i,isStopped:r,observers:s}=this;return i||r?Xl:(this.currentObservers=null,s.push(e),new As(()=>{this.currentObservers=null,up(s,e)}))}_checkFinalizedStatuses(e){const{hasError:i,thrownError:r,isStopped:s}=this;i?e.error(r):s&&e.complete()}asObservable(){const e=new Pi;return e.source=this,e}}return n.create=(t,e)=>new rs(t,e),n})();class rs extends Pt{constructor(t,e){super(),this.destination=t,this.source=e}next(t){var e,i;null===(i=null===(e=this.destination)||void 0===e?void 0:e.next)||void 0===i||i.call(e,t)}error(t){var e,i;null===(i=null===(e=this.destination)||void 0===e?void 0:e.error)||void 0===i||i.call(e,t)}complete(){var t,e;null===(e=null===(t=this.destination)||void 0===t?void 0:t.complete)||void 0===e||e.call(t)}_subscribe(t){var e,i;return null!==(i=null===(e=this.source)||void 0===e?void 0:e.subscribe(t))&&void 0!==i?i:Xl}}class _o extends Pt{constructor(t){super(),this._value=t}get value(){return this.getValue()}_subscribe(t){const e=super._subscribe(t);return!e.closed&&t.next(this._value),e}getValue(){const{hasError:t,thrownError:e,_value:i}=this;if(t)throw e;return this._throwIfClosed(),i}next(t){super.next(this._value=t)}}class Ls extends pt{constructor(t,e,i,r,s,o){super(t),this.onFinalize=s,this.shouldUnsubscribe=o,this._next=e?function(a){try{e(a)}catch(l){t.error(l)}}:super._next,this._error=r?function(a){try{r(a)}catch(l){t.error(l)}finally{this.unsubscribe()}}:super._error,this._complete=i?function(){try{i()}catch(a){t.error(a)}finally{this.unsubscribe()}}:super._complete}unsubscribe(){var t;if(!this.shouldUnsubscribe||this.shouldUnsubscribe()){const{closed:e}=this;super.unsubscribe(),!e&&(null===(t=this.onFinalize)||void 0===t||t.call(this))}}}function jr(n,t){return function Ur(n){return t=>{if(function cn(n){return Eo(n?.lift)}(t))return t.lift(function(e){try{return n(e,this)}catch(i){this.error(i)}});throw new TypeError("Unable to lift unknown Observable type")}}((e,i)=>{let r=0;e.subscribe(function Do(n,t,e,i,r){return new Ls(n,t,e,i,r)}(i,s=>{i.next(n.call(t,s,r++))}))})}class F extends Error{constructor(t,e){super(function ae(n,t){return`NG0${Math.abs(n)}${t?": "+t:""}`}(t,e)),this.code=t}}function Xe(n){for(let t in n)if(n[t]===Xe)return t;throw Error("Could not find renamed property on target object.")}function mt(n,t){for(const e in t)t.hasOwnProperty(e)&&!n.hasOwnProperty(e)&&(n[e]=t[e])}function dt(n){if("string"==typeof n)return n;if(Array.isArray(n))return"["+n.map(dt).join(", ")+"]";if(null==n)return""+n;if(n.overriddenName)return`${n.overriddenName}`;if(n.name)return`${n.name}`;const t=n.toString();if(null==t)return""+t;const e=t.indexOf("\n");return-1===e?t:t.substring(0,e)}function qt(n,t){return null==n||""===n?null===t?"":t:null==t||""===t?n:n+" "+t}const ur=Xe({__forward_ref__:Xe});function ir(n){return n.__forward_ref__=ir,n.toString=function(){return dt(this())},n}function vt(n){return function Tn(n){return"function"==typeof n&&n.hasOwnProperty(ur)&&n.__forward_ref__===ir}(n)?n():n}function $l(n){return n&&!!n.\u0275providers}const Zl=Xe({\u0275cmp:Xe}),$d=Xe({\u0275dir:Xe}),fp=Xe({\u0275pipe:Xe}),Uo=Xe({\u0275fac:Xe}),jo=Xe({__NG_ELEMENT_ID__:Xe}),pp=Xe({__NG_ENV_ID__:Xe});function Ri(n){return"function"==typeof n?n.name||n.toString():"object"==typeof n&&null!=n&&"function"==typeof n.type?n.type.name||n.type.toString():function Nt(n){return"string"==typeof n?n:null==n?"":String(n)}(n)}function xb(n,t){throw new F(-201,!1)}function so(n,t){null==n&&function zt(n,t,e,i){throw new Error(`ASSERTION ERROR: ${n}`+(null==i?"":` [Expected=> ${e} ${i} ${t} <=Actual]`))}(t,n,null,"!=")}function Yi(n){return{token:n.token,providedIn:n.providedIn||null,factory:n.factory,value:void 0}}function gp(n){return{providers:n.providers||[],imports:n.imports||[]}}function Cm(n){return PT(n,Dm)||PT(n,zT)}function PT(n,t){return n.hasOwnProperty(t)?n[t]:null}function Em(n){return n&&(n.hasOwnProperty(Tb)||n.hasOwnProperty(E_))?n[Tb]:null}const Dm=Xe({\u0275prov:Xe}),Tb=Xe({\u0275inj:Xe}),zT=Xe({ngInjectableDef:Xe}),E_=Xe({ngInjectorDef:Xe});var xi=function(n){return n[n.Default=0]="Default",n[n.Host=1]="Host",n[n.Self=2]="Self",n[n.SkipSelf=4]="SkipSelf",n[n.Optional=8]="Optional",n}(xi||{});let Ab;function oo(n){const t=Ab;return Ab=n,t}function HT(n,t,e){const i=Cm(n);return i&&"root"==i.providedIn?void 0===i.value?i.value=i.factory():i.value:e&xi.Optional?null:void 0!==t?t:void xb()}const rr=globalThis;class Ht{constructor(t,e){this._desc=t,this.ngMetadataName="InjectionToken",this.\u0275prov=void 0,"number"==typeof e?this.__NG_ELEMENT_ID__=e:void 0!==e&&(this.\u0275prov=Yi({token:this,providedIn:e.providedIn||"root",factory:e.factory}))}get multi(){return this}toString(){return`InjectionToken ${this._desc}`}}const vp={},Pb="__NG_DI_FLAG__",xm="ngTempTokenPath",T_=/\n/gm,FT="__source";let Jd;function Gh(n){const t=Jd;return Jd=n,t}function N_(n,t=xi.Default){if(void 0===Jd)throw new F(-203,!1);return null===Jd?HT(n,void 0,t):Jd.get(n,t&xi.Optional?null:void 0,t)}function _i(n,t=xi.Default){return(function RT(){return Ab}()||N_)(vt(n),t)}function Hi(n,t=xi.Default){return _i(n,Tm(t))}function Tm(n){return typeof n>"u"||"number"==typeof n?n:0|(n.optional&&8)|(n.host&&1)|(n.self&&2)|(n.skipSelf&&4)}function zb(n){const t=[];for(let e=0;et){o=s-1;break}}}for(;ss?"":r[d+1].toLowerCase();const f=8&i?u:null;if(f&&-1!==UT(f,h,0)||2&i&&h!==u){if(Ma(i))return!1;o=!0}}}}else{if(!o&&!Ma(i)&&!Ma(l))return!1;if(o&&Ma(l))continue;o=!1,i=l|1&i}}return Ma(i)||o}function Ma(n){return 0==(1&n)}function B_(n,t,e,i){if(null===t)return-1;let r=0;if(i||!e){let s=!1;for(;r-1)for(e++;e0?'="'+a+'"':"")+"]"}else 8&i?r+="."+o:4&i&&(r+=" "+o);else""!==r&&!Ma(o)&&(t+=XT(s,r),r=""),i=o,s=s||!Ma(i);e++}return""!==r&&(t+=XT(s,r)),t}function Hb(n){return Jl(()=>{const t=$T(n),e={...t,decls:n.decls,vars:n.vars,template:n.template,consts:n.consts||null,ngContentSelectors:n.ngContentSelectors,onPush:n.changeDetection===Am.OnPush,directiveDefs:null,pipeDefs:null,dependencies:t.standalone&&n.dependencies||null,getStandaloneInjector:null,signals:n.signals??!1,data:n.data||{},encapsulation:n.encapsulation||ba.Emulated,styles:n.styles||Qi,_:null,schemas:n.schemas||null,tView:null,id:""};ZT(e);const i=n.dependencies;return e.directiveDefs=Nm(i,!1),e.pipeDefs=Nm(i,!0),e.id=function q_(n){let t=0;const e=[n.selectors,n.ngContentSelectors,n.hostVars,n.hostAttrs,n.consts,n.vars,n.decls,n.encapsulation,n.standalone,n.signals,n.exportAs,JSON.stringify(n.inputs),JSON.stringify(n.outputs),Object.getOwnPropertyNames(n.type.prototype),!!n.contentQueries,!!n.viewQuery].join("|");for(const r of e)t=Math.imul(31,t)+r.charCodeAt(0)<<0;return t+=2147483648,"c"+t}(e),e})}function Q_(n){return di(n)||Wn(n)}function G_(n){return null!==n}function Lm(n){return Jl(()=>({type:n.type,bootstrap:n.bootstrap||Qi,declarations:n.declarations||Qi,imports:n.imports||Qi,exports:n.exports||Qi,transitiveCompileScopes:null,schemas:n.schemas||null,id:n.id||null}))}function qT(n,t){if(null==n)return rl;const e={};for(const i in n)if(n.hasOwnProperty(i)){const r=n[i];let s,o,a=Xh.None;Array.isArray(r)?(a=r[0],s=r[1],o=r[2]??s):(s=r,o=r),t?(e[s]=a!==Xh.None?[i,a]:i,t[s]=o):e[s]=i}return e}function nr(n){return Jl(()=>{const t=$T(n);return ZT(t),t})}function di(n){return n[Zl]||null}function Wn(n){return n[$d]||null}function gs(n){return n[fp]||null}function $T(n){const t={};return{type:n.type,providersResolver:null,factory:null,hostBindings:n.hostBindings||null,hostVars:n.hostVars||0,hostAttrs:n.hostAttrs||null,contentQueries:n.contentQueries||null,declaredInputs:t,inputTransforms:null,inputConfig:n.inputs||rl,exportAs:n.exportAs||null,standalone:!0===n.standalone,signals:!0===n.signals,selectors:n.selectors||Qi,viewQuery:n.viewQuery||null,features:n.features||null,setInput:null,findHostDirectiveDefs:null,hostDirectives:null,inputs:qT(n.inputs,t),outputs:qT(n.outputs),debugInfo:null}}function ZT(n){n.features?.forEach(t=>t(n))}function Nm(n,t){if(!n)return null;const e=t?gs:Q_;return()=>("function"==typeof n?n():n).map(i=>e(i)).filter(G_)}const Vr=0,Be=1,Ct=2,vn=3,wa=4,Os=5,Ca=6,Kd=7,Er=8,Xs=9,Kl=10,Yt=11,Sp=12,JT=13,eu=14,Jr=15,Ip=16,tu=17,nl=18,bp=19,KT=20,qh=21,Om=22,Uc=23,jt=25,Bb=1,sl=7,iu=9,mn=10;var Fb=function(n){return n[n.None=0]="None",n[n.HasTransplantedViews=2]="HasTransplantedViews",n}(Fb||{});function ks(n){return Array.isArray(n)&&"object"==typeof n[Bb]}function Ps(n){return Array.isArray(n)&&!0===n[Bb]}function _b(n){return 0!=(4&n.flags)}function jc(n){return n.componentOffset>-1}function Pm(n){return 1==(1&n.flags)}function Ea(n){return!!n.template}function Ub(n){return 0!=(512&n[Ct])}function Vc(n,t){return n.hasOwnProperty(Uo)?n[Uo]:null}class K_{constructor(t,e,i){this.previousValue=t,this.currentValue=e,this.firstChange=i}isFirstChange(){return this.firstChange}}function rA(n,t,e,i){null!==t?t.applyValueToInputSignal(t,i):n[e]=i}function nA(n){return n.type.prototype.ngOnChanges&&(n.setInput=tU),eU}function eU(){const n=oA(this),t=n?.current;if(t){const e=n.previous;if(e===rl)n.previous=t;else for(let i in t)e[i]=t[i];n.current=null,this.ngOnChanges(t)}}function tU(n,t,e,i,r){const s=this.declaredInputs[i],o=oA(n)||function iU(n,t){return n[sA]=t}(n,{previous:rl,current:null}),a=o.current||(o.current={}),l=o.previous,h=l[s];a[s]=new K_(h&&h.currentValue,e,l===rl),rA(n,t,r,e)}const sA="__ngSimpleChanges__";function oA(n){return n[sA]||null}const ol=function(n,t,e){};let hA=!1;function fr(n){for(;Array.isArray(n);)n=n[Vr];return n}function qs(n,t){return fr(t[n.index])}function Cp(n,t){return n.data[t]}function To(n,t){const e=t[n];return ks(e)?e:e[Vr]}function Qb(n){return 128==(128&n[Ct])}function al(n,t){return null==t?null:n[t]}function cA(n){n[tu]=0}function lU(n){1024&n[Ct]||(n[Ct]|=1024,Qb(n)&&Ep(n))}function uA(n){return 9216&n[Ct]||n[Uc]?.dirty}function Gb(n){uA(n)?Ep(n):64&n[Ct]&&(function nU(){return hA}()?(n[Ct]|=1024,Ep(n)):n[Kl].changeDetectionScheduler?.notify())}function Ep(n){n[Kl].changeDetectionScheduler?.notify();let t=Wc(n);for(;null!==t&&!(8192&t[Ct])&&(t[Ct]|=8192,Qb(t));)t=Wc(t)}function Wc(n){const t=n[vn];return Ps(t)?t[vn]:t}const Rt={lFrame:MA(null),bindingsEnabled:!0,skipHydrationRootTNode:null};function pA(){return Rt.bindingsEnabled}function Se(){return Rt.lFrame.lView}function Ti(){return Rt.lFrame.tView}function pr(){let n=gA();for(;null!==n&&64===n.type;)n=n.parent;return n}function gA(){return Rt.lFrame.currentTNode}function ll(n,t){const e=Rt.lFrame;e.currentTNode=n,e.isParent=t}function qb(){return Rt.lFrame.isParent}function bU(n,t){const e=Rt.lFrame;e.bindingIndex=e.bindingRootIndex=n,Zb(t)}function Zb(n){Rt.lFrame.currentDirectiveIndex=n}function SA(){return Rt.lFrame.currentQueryIndex}function Kb(n){Rt.lFrame.currentQueryIndex=n}function wU(n){const t=n[Be];return 2===t.type?t.declTNode:1===t.type?n[Os]:null}function IA(n,t,e){if(e&xi.SkipSelf){let r=t,s=n;for(;!(r=r.parent,null!==r||e&xi.Host||(r=wU(s),null===r||(s=s[eu],10&r.type))););if(null===r)return!1;t=r,n=s}const i=Rt.lFrame=bA();return i.currentTNode=t,i.lView=n,!0}function e1(n){const t=bA(),e=n[Be];Rt.lFrame=t,t.currentTNode=e.firstChild,t.lView=n,t.tView=e,t.contextLView=n,t.bindingIndex=e.bindingStartIndex,t.inI18n=!1}function bA(){const n=Rt.lFrame,t=null===n?null:n.child;return null===t?MA(n):t}function MA(n){const t={currentTNode:null,isParent:!0,lView:null,tView:null,selectedIndex:-1,contextLView:null,elementDepthCount:0,currentNamespace:null,currentDirectiveIndex:-1,bindingRootIndex:-1,bindingIndex:-1,currentQueryIndex:0,parent:n,child:null,inI18n:!1};return null!==n&&(n.child=t),t}function wA(){const n=Rt.lFrame;return Rt.lFrame=n.parent,n.currentTNode=null,n.lView=null,n}const CA=wA;function t1(){const n=wA();n.isParent=!0,n.tView=null,n.selectedIndex=-1,n.contextLView=null,n.elementDepthCount=0,n.currentDirectiveIndex=-1,n.currentNamespace=null,n.bindingRootIndex=-1,n.bindingIndex=-1,n.currentQueryIndex=0}function zs(){return Rt.lFrame.selectedIndex}function Yc(n){Rt.lFrame.selectedIndex=n}let DA=!0;function Hm(){return DA}function $h(n){DA=n}function Bm(n,t){for(let e=t.directiveStart,i=t.directiveEnd;e=i)break}else t[l]<0&&(n[tu]+=65536),(a>14>16&&(3&n[Ct])===t&&(n[Ct]+=16384,TA(a,s)):TA(a,s)}const su=-1;class xp{constructor(t,e,i){this.factory=t,this.resolving=!1,this.canSeeViewProviders=e,this.injectImpl=i}}function n1(n){return n!==su}function Tp(n){return 32767&n}function Ap(n,t){let e=function zU(n){return n>>16}(n),i=t;for(;e>0;)i=i[eu],e--;return i}let s1=!0;function Um(n){const t=s1;return s1=n,t}const AA=255,LA=5;let RU=0;const cl={};function jm(n,t){const e=NA(n,t);if(-1!==e)return e;const i=t[Be];i.firstCreatePass&&(n.injectorIndex=t.length,o1(i.data,n),o1(t,null),o1(i.blueprint,null));const r=Vm(n,t),s=n.injectorIndex;if(n1(r)){const o=Tp(r),a=Ap(r,t),l=a[Be].data;for(let h=0;h<8;h++)t[s+h]=a[o+h]|l[o+h]}return t[s+8]=r,s}function o1(n,t){n.push(0,0,0,0,0,0,0,0,t)}function NA(n,t){return-1===n.injectorIndex||n.parent&&n.parent.injectorIndex===n.injectorIndex||null===t[n.injectorIndex+8]?-1:n.injectorIndex}function Vm(n,t){if(n.parent&&-1!==n.parent.injectorIndex)return n.parent.injectorIndex;let e=0,i=null,r=t;for(;null!==r;){if(i=BA(r),null===i)return su;if(e++,r=r[eu],-1!==i.injectorIndex)return i.injectorIndex|e<<16}return su}function a1(n,t,e){!function HU(n,t,e){let i;"string"==typeof e?i=e.charCodeAt(0)||0:e.hasOwnProperty(jo)&&(i=e[jo]),null==i&&(i=e[jo]=RU++);const r=i&AA;t.data[n+(r>>LA)]|=1<=0?t&AA:UU:t}(e);if("function"==typeof s){if(!IA(t,n,i))return i&xi.Host?OA(r,0,i):kA(t,e,i,r);try{let o;if(o=s(i),null!=o||i&xi.Optional)return o;xb()}finally{CA()}}else if("number"==typeof s){let o=null,a=NA(n,t),l=su,h=i&xi.Host?t[Jr][Os]:null;for((-1===a||i&xi.SkipSelf)&&(l=-1===a?Vm(n,t):t[a+8],l!==su&&HA(i,!1)?(o=t[Be],a=Tp(l),t=Ap(l,t)):a=-1);-1!==a;){const c=t[Be];if(RA(s,a,c.data)){const d=FU(a,t,e,o,i,h);if(d!==cl)return d}l=t[a+8],l!==su&&HA(i,t[Be].data[a+8]===h)&&RA(s,a,t)?(o=c,a=Tp(l),t=Ap(l,t)):a=-1}}return r}function FU(n,t,e,i,r,s){const o=t[Be],a=o.data[n+8],c=Wm(a,o,e,null==i?jc(a)&&s1:i!=o&&0!=(3&a.type),r&xi.Host&&s===a);return null!==c?Qc(t,o,c,a):cl}function Wm(n,t,e,i,r){const s=n.providerIndexes,o=t.data,a=1048575&s,l=n.directiveStart,c=s>>20,u=r?a+c:n.directiveEnd;for(let f=i?a:a+c;f=l&&p.type===e)return f}if(r){const f=o[l];if(f&&Ea(f)&&f.type===e)return l}return null}function Qc(n,t,e,i){let r=n[e];const s=t.data;if(function NU(n){return n instanceof xp}(r)){const o=r;o.resolving&&function Vo(n,t){const e=t?`. Dependency path: ${t.join(" > ")} > ${n}`:"";throw new F(-200,`Circular dependency in DI detected for ${n}${e}`)}(Ri(s[e]));const a=Um(o.canSeeViewProviders);o.resolving=!0;const h=o.injectImpl?oo(o.injectImpl):null;IA(n,i,xi.Default);try{r=n[e]=o.factory(void 0,s,n,i),t.firstCreatePass&&e>=i.directiveStart&&function AU(n,t,e){const{ngOnChanges:i,ngOnInit:r,ngDoCheck:s}=t.type.prototype;if(i){const o=nA(t);(e.preOrderHooks??=[]).push(n,o),(e.preOrderCheckHooks??=[]).push(n,o)}r&&(e.preOrderHooks??=[]).push(0-n,r),s&&((e.preOrderHooks??=[]).push(n,s),(e.preOrderCheckHooks??=[]).push(n,s))}(e,s[e],t)}finally{null!==h&&oo(h),Um(a),o.resolving=!1,CA()}}return r}function RA(n,t,e){return!!(e[t+(n>>LA)]&1<Array.isArray(e)?fu(e,t):t(e))}function _A(n,t,e){t>=n.length?n.push(e):n.splice(t,0,e)}function Ym(n,t){return t>=n.length-1?n.pop():n.splice(t,1)[0]}const vu=new Ht(""),QA=new Ht("",-1),m1=new Ht("");class qm{get(t,e=vp){if(e===vp){const i=new Error(`NullInjectorError: No provider for ${dt(t)}!`);throw i.name="NullInjectorError",i}return e}}function dj(...n){return{\u0275providers:GA(0,n),\u0275fromNgModule:!0}}function GA(n,...t){const e=[],i=new Set;let r;const s=o=>{e.push(o)};return fu(t,o=>{const a=o;$m(a,s,[],i)&&(r||=[],r.push(a))}),void 0!==r&&XA(r,s),e}function XA(n,t){for(let e=0;e{t(s,i)})}}function $m(n,t,e,i){if(!(n=vt(n)))return!1;let r=null,s=Em(n);const o=!s&&di(n);if(s||o){if(o&&!o.standalone)return!1;r=n}else{const l=n.ngModule;if(s=Em(l),!s)return!1;r=l}const a=i.has(r);if(o){if(a)return!1;if(i.add(r),o.dependencies){const l="function"==typeof o.dependencies?o.dependencies():o.dependencies;for(const h of l)$m(h,t,e,i)}}else{if(!s)return!1;{if(null!=s.imports&&!a){let h;i.add(r);try{fu(s.imports,c=>{$m(c,t,e,i)&&(h||=[],h.push(c))})}finally{}void 0!==h&&XA(h,t)}if(!a){const h=Vc(r)||(()=>new r);t({provide:r,useFactory:h,deps:Qi},r),t({provide:m1,useValue:r,multi:!0},r),t({provide:vu,useValue:()=>_i(r),multi:!0},r)}const l=s.providers;if(null!=l&&!a){const h=n;S1(l,c=>{t(c,h)})}}}return r!==n&&void 0!==n.providers}function S1(n,t){for(let e of n)$l(e)&&(e=e.\u0275providers),Array.isArray(e)?S1(e,t):t(e)}const uj=Xe({provide:String,useValue:Xe});function I1(n){return null!==n&&"object"==typeof n&&uj in n}function Gc(n){return"function"==typeof n}const b1=new Ht(""),Zm={},pj={};let M1;function Jm(){return void 0===M1&&(M1=new qm),M1}class ih{}class mu extends ih{get destroyed(){return this._destroyed}constructor(t,e,i,r){super(),this.parent=e,this.source=i,this.scopes=r,this.records=new Map,this._ngOnDestroyHooks=new Set,this._onDestroyHooks=[],this._destroyed=!1,C1(t,o=>this.processProvider(o)),this.records.set(QA,yu(void 0,this)),r.has("environment")&&this.records.set(ih,yu(void 0,this));const s=this.records.get(b1);null!=s&&"string"==typeof s.value&&this.scopes.add(s.value),this.injectorDefTypes=new Set(this.get(m1,Qi,xi.Self))}destroy(){this.assertNotDestroyed(),this._destroyed=!0;try{for(const e of this._ngOnDestroyHooks)e.ngOnDestroy();const t=this._onDestroyHooks;this._onDestroyHooks=[];for(const e of t)e()}finally{this.records.clear(),this._ngOnDestroyHooks.clear(),this.injectorDefTypes.clear()}}onDestroy(t){return this.assertNotDestroyed(),this._onDestroyHooks.push(t),()=>this.removeOnDestroy(t)}runInContext(t){this.assertNotDestroyed();const e=Gh(this),i=oo(void 0);try{return t()}finally{Gh(e),oo(i)}}get(t,e=vp,i=xi.Default){if(this.assertNotDestroyed(),t.hasOwnProperty(pp))return t[pp](this);i=Tm(i);const s=Gh(this),o=oo(void 0);try{if(!(i&xi.SkipSelf)){let l=this.records.get(t);if(void 0===l){const h=function Sj(n){return"function"==typeof n||"object"==typeof n&&n instanceof Ht}(t)&&Cm(t);l=h&&this.injectableDefInScope(h)?yu(w1(t),Zm):null,this.records.set(t,l)}if(null!=l)return this.hydrate(t,l)}return(i&xi.Self?Jm():this.parent).get(t,e=i&xi.Optional&&e===vp?null:e)}catch(a){if("NullInjectorError"===a.name){if((a[xm]=a[xm]||[]).unshift(dt(t)),s)throw a;return function k_(n,t,e,i){const r=n[xm];throw t[FT]&&r.unshift(t[FT]),n.message=function P_(n,t,e,i=null){n=n&&"\n"===n.charAt(0)&&"\u0275"==n.charAt(1)?n.slice(2):n;let r=dt(t);if(Array.isArray(t))r=t.map(dt).join(" -> ");else if("object"==typeof t){let s=[];for(let o in t)if(t.hasOwnProperty(o)){let a=t[o];s.push(o+":"+("string"==typeof a?JSON.stringify(a):dt(a)))}r=`{${s.join(", ")}}`}return`${e}${i?"("+i+")":""}[${r}]: ${n.replace(T_,"\n ")}`}("\n"+n.message,r,e,i),n.ngTokenPath=r,n[xm]=null,n}(a,t,"R3InjectorError",this.source)}throw a}finally{oo(o),Gh(s)}}resolveInjectorInitializers(){const t=Gh(this),e=oo(void 0);try{const r=this.get(vu,Qi,xi.Self);for(const s of r)s()}finally{Gh(t),oo(e)}}toString(){const t=[],e=this.records;for(const i of e.keys())t.push(dt(i));return`R3Injector[${t.join(", ")}]`}assertNotDestroyed(){if(this._destroyed)throw new F(205,!1)}processProvider(t){let e=Gc(t=vt(t))?t:vt(t&&t.provide);const i=function vj(n){return I1(n)?yu(void 0,n.useValue):yu(ZA(n),Zm)}(t);if(!Gc(t)&&!0===t.multi){let r=this.records.get(e);r||(r=yu(void 0,Zm,!0),r.factory=()=>zb(r.multi),this.records.set(e,r)),e=t,r.multi.push(t)}this.records.set(e,i)}hydrate(t,e){return e.value===Zm&&(e.value=pj,e.value=e.factory()),"object"==typeof e.value&&e.value&&function yj(n){return null!==n&&"object"==typeof n&&"function"==typeof n.ngOnDestroy}(e.value)&&this._ngOnDestroyHooks.add(e.value),e.value}injectableDefInScope(t){if(!t.providedIn)return!1;const e=vt(t.providedIn);return"string"==typeof e?"any"===e||this.scopes.has(e):this.injectorDefTypes.has(e)}removeOnDestroy(t){const e=this._onDestroyHooks.indexOf(t);-1!==e&&this._onDestroyHooks.splice(e,1)}}function w1(n){const t=Cm(n),e=null!==t?t.factory:Vc(n);if(null!==e)return e;if(n instanceof Ht)throw new F(204,!1);if(n instanceof Function)return function gj(n){if(n.length>0)throw new F(204,!1);const e=function C_(n){return n&&(n[Dm]||n[zT])||null}(n);return null!==e?()=>e.factory(n):()=>new n}(n);throw new F(204,!1)}function ZA(n,t,e){let i;if(Gc(n)){const r=vt(n);return Vc(r)||w1(r)}if(I1(n))i=()=>vt(n.useValue);else if(function $A(n){return!(!n||!n.useFactory)}(n))i=()=>n.useFactory(...zb(n.deps||[]));else if(function qA(n){return!(!n||!n.useExisting)}(n))i=()=>_i(vt(n.useExisting));else{const r=vt(n&&(n.useClass||n.provide));if(!function mj(n){return!!n.deps}(n))return Vc(r)||w1(r);i=()=>new r(...zb(n.deps))}return i}function yu(n,t,e=!1){return{factory:n,value:t,multi:e?[]:void 0}}function C1(n,t){for(const e of n)Array.isArray(e)?C1(e,t):e&&$l(e)?C1(e.\u0275providers,t):t(e)}function tL(n,t=null,e=null,i){const r=function iL(n,t=null,e=null,i,r=new Set){const s=[e||Qi,dj(n)];return i=i||("object"==typeof n?void 0:dt(n)),new mu(s,t||Jm(),i||null,r)}(n,t,e,i);return r.resolveInjectorInitializers(),r}let x1,Wo=(()=>{class n{static{this.THROW_IF_NOT_FOUND=vp}static{this.NULL=new qm}static create(e,i){if(Array.isArray(e))return tL({name:""},i,e,"");{const r=e.name??"";return tL({name:r},e.parent,e.providers,r)}}static{this.\u0275prov=Yi({token:n,providedIn:"any",factory:()=>_i(QA)})}static{this.__NG_ELEMENT_ID__=-1}}return n})();const T1=new Ht("",{providedIn:"root",factory:()=>Tj}),Tj="ng",nL=new Ht(""),Su=new Ht("",{providedIn:"platform",factory:()=>"unknown"}),sL=new Ht("",{providedIn:"root",factory:()=>function Zh(){if(void 0!==x1)return x1;if(typeof document<"u")return document;throw new F(210,!1)}().body?.querySelector("[ngCspNonce]")?.getAttribute("ngCspNonce")||null});function ry(n){return 128==(128&n.flags)}var ec=function(n){return n[n.Important=1]="Important",n[n.DashCase=2]="DashCase",n}(ec||{});const k1=new Map;let Uj=0;const z1="__ngContext__";function Rs(n,t){ks(t)?(n[z1]=t[bp],function Vj(n){k1.set(n[bp],n)}(t)):n[z1]=t}let R1;function H1(n,t){return R1(n,t)}function bu(n,t,e,i,r){if(null!=i){let s,o=!1;Ps(i)?s=i:ks(i)&&(o=!0,i=i[Vr]);const a=fr(i);0===n&&null!==e?null==r?xL(t,e,a):qc(t,e,a,r||null,!0):1===n&&null!==e?qc(t,e,a,r||null,!0):2===n?function cy(n,t,e){const i=ly(n,t);i&&function s6(n,t,e,i){n.removeChild(t,e,i)}(n,i,t,e)}(t,a,o):3===n&&t.destroyNode(a),null!=s&&function l6(n,t,e,i,r){const s=e[sl];s!==fr(e)&&bu(t,n,i,s,r);for(let a=mn;a0&&(n[e-1][wa]=i[wa]);const s=Ym(n,mn+t);!function Jj(n,t){CL(n,t),t[Vr]=null,t[Os]=null}(i[Be],i);const o=s[nl];null!==o&&o.detachView(s[Be]),i[vn]=null,i[wa]=null,i[Ct]&=-129}return i}function ay(n,t){if(!(256&t[Ct])){const e=t[Yt];e.destroyNode&&dy(n,t,e,3,null,null),function e6(n){let t=n[Sp];if(!t)return F1(n[Be],n);for(;t;){let e=null;if(ks(t))e=t[Sp];else{const i=t[mn];i&&(e=i)}if(!e){for(;t&&!t[wa]&&t!==n;)ks(t)&&F1(t[Be],t),t=t[vn];null===t&&(t=n),ks(t)&&F1(t[Be],t),e=t&&t[wa]}t=e}}(t)}}function F1(n,t){if(!(256&t[Ct])){t[Ct]&=-129,t[Ct]|=256,t[Uc]&&function Qd(n){if(Gl(n),Wh(n))for(let t=0;t=0?i[o]():i[-o].unsubscribe(),s+=2}else e[s].call(i[e[s+1]]);null!==i&&(t[Kd]=null);const r=t[qh];if(null!==r){t[qh]=null;for(let s=0;s-1){const{encapsulation:s}=n.data[i.directiveStart+r];if(s===ba.None||s===ba.Emulated)return null}return qs(i,e)}}(n,t.parent,e)}function qc(n,t,e,i,r){n.insertBefore(t,e,i,r)}function xL(n,t,e){n.appendChild(t,e)}function TL(n,t,e,i,r){null!==i?qc(n,t,e,i,r):xL(n,t,e)}function ly(n,t){return n.parentNode(t)}let U1,NL=function LL(n,t,e){return 40&n.type?qs(n,e):null};function hy(n,t,e,i){const r=_1(n,i,t),s=t[Yt],a=function AL(n,t,e){return NL(n,t,e)}(i.parent||t[Os],i,t);if(null!=r)if(Array.isArray(e))for(let l=0;lnull;function rM(n,t,e=!1){return ZL(n,t,e)}class Y6{}class iN{}class G6{resolveComponentFactory(t){throw function Q6(n){const t=Error(`No component factory found for ${dt(n)}.`);return t.ngComponent=n,t}(t)}}let Iy=(()=>{class n{static{this.NULL=new G6}}return n})();function X6(){return xu(pr(),Se())}function xu(n,t){return new $c(qs(n,t))}let $c=(()=>{class n{constructor(e){this.nativeElement=e}static{this.__NG_ELEMENT_ID__=X6}}return n})();function q6(n){return n instanceof $c?n.nativeElement:n}class nN{}let aM=(()=>{class n{constructor(){this.destroyNode=null}static{this.__NG_ELEMENT_ID__=()=>function $6(){const n=Se(),e=To(pr().index,n);return(ks(e)?e:n)[Yt]}()}}return n})(),Z6=(()=>{class n{static{this.\u0275prov=Yi({token:n,providedIn:"root",factory:()=>null})}}return n})();const lM={};function Wp(n,t,e,i,r=!1){for(;null!==e;){const s=t[e.index];null!==s&&i.push(fr(s)),Ps(s)&&uN(s,i);const o=e.type;if(8&o)Wp(n,t,e.child,i);else if(32&o){const a=H1(e,t);let l;for(;l=a();)i.push(l)}else if(16&o){const a=kL(t,e);if(Array.isArray(a))i.push(...a);else{const l=Wc(t[Jr]);Wp(l[Be],l,a,i,!0)}}e=r?e.projectionNext:e.next}return i}function uN(n,t){for(let e=mn;e!1,producerRecomputeValue:()=>{},consumerMarkedDirty:()=>{},consumerOnSignalRead:()=>{},consumerIsAlwaysLive:!0,consumerMarkedDirty:n=>{Ep(n.lView)},consumerOnSignalRead(){this.lView[Uc]=this}};function pN(n){return vN(n[Sp])}function gN(n){return vN(n[wa])}function vN(n){for(;null!==n&&!Ps(n);)n=n[wa];return n}function dM(n){return n.ngOriginalError}class nh{constructor(){this._console=console}handleError(t){const e=this._findOriginalError(t);this._console.error("ERROR",t),e&&this._console.error("ORIGINAL ERROR",e)}_findOriginalError(t){let e=t&&dM(t);for(;e&&dM(e);)e=dM(e);return e||null}}const yN=new Ht("",{providedIn:"root",factory:()=>Hi(nh).handleError.bind(void 0)}),IN=new Ht("",{providedIn:"root",factory:()=>!1}),Qt={};function EN(n,t,e,i){if(!i)if(3==(3&t[Ct])){const s=n.preOrderCheckHooks;null!==s&&Fm(t,s,e)}else{const s=n.preOrderHooks;null!==s&&_m(t,s,0,e)}Yc(e)}function Ot(n,t=xi.Default){const e=Se();return null===e?_i(n,t):PA(pr(),e,vt(n),t)}function DN(n,t,e,i,r,s){const o=Wi(null);try{let a=null;r&Xh.SignalBased&&(a=t[i][Ts]),null!==a&&void 0!==a.transformFn&&(s=a.transformFn(s)),r&Xh.HasDecoratorInputTransform&&(s=n.inputTransforms[i].call(t,s)),null!==n.setInput?n.setInput(t,a,s,e,i):rA(t,a,i,s)}finally{Wi(o)}}function Cy(n,t,e,i,r,s,o,a,l,h,c){const d=t.blueprint.slice();return d[Vr]=r,d[Ct]=204|i,(null!==h||n&&2048&n[Ct])&&(d[Ct]|=2048),cA(d),d[vn]=d[eu]=n,d[Er]=e,d[Kl]=o||n&&n[Kl],d[Yt]=a||n&&n[Yt],d[Xs]=l||n&&n[Xs]||null,d[Os]=s,d[bp]=function jj(){return Uj++}(),d[Ca]=c,d[KT]=h,d[Jr]=2==t.type?n[Jr]:d,d}function Tu(n,t,e,i,r){let s=n.data[t];if(null===s)s=function uM(n,t,e,i,r){const s=gA(),o=qb(),l=n.data[t]=function TV(n,t,e,i,r,s){let o=t?t.injectorIndex:-1,a=0;return function nu(){return null!==Rt.skipHydrationRootTNode}()&&(a|=128),{type:e,index:i,insertBeforeIndex:null,injectorIndex:o,directiveStart:-1,directiveEnd:-1,directiveStylingLast:-1,componentOffset:-1,propertyBindings:null,flags:a,providerIndexes:0,value:r,attrs:s,mergedAttrs:null,localNames:null,initialInputs:void 0,inputs:null,outputs:null,tView:null,next:null,prev:null,projectionNext:null,child:null,parent:t,projection:null,styles:null,stylesWithoutHost:null,residualStyles:void 0,classes:null,classesWithoutHost:null,residualClasses:void 0,classBindings:0,styleBindings:0}}(0,o?s:s&&s.parent,e,t,i,r);return null===n.firstChild&&(n.firstChild=l),null!==s&&(o?null==s.child&&null!==l.parent&&(s.child=l):null===s.next&&(s.next=l,l.prev=s)),l}(n,t,e,i,r),function IU(){return Rt.lFrame.inI18n}()&&(s.flags|=32);else if(64&s.type){s.type=e,s.value=i,s.attrs=r;const o=function Dp(){const n=Rt.lFrame,t=n.currentTNode;return n.isParent?t:t.parent}();s.injectorIndex=null===o?-1:o.injectorIndex}return ll(s,!0),s}function Yp(n,t,e,i){if(0===e)return-1;const r=t.length;for(let s=0;sjt&&EN(n,t,jt,!1),ol(o?2:0,r),e(i,r)}finally{Yc(s),ol(o?3:1,r)}}function fM(n,t,e){if(_b(t)){const i=Wi(null);try{const s=t.directiveEnd;for(let o=t.directiveStart;onull;function LN(n,t,e,i,r){for(let s in t){if(!t.hasOwnProperty(s))continue;const o=t[s];if(void 0===o)continue;i??={};let a,l=Xh.None;Array.isArray(o)?(a=o[0],l=o[1]):a=o;let h=s;if(null!==r){if(!r.hasOwnProperty(s))continue;h=r[s]}0===n?NN(i,e,h,a,l):NN(i,e,h,a)}return i}function NN(n,t,e,i,r){let s;n.hasOwnProperty(e)?(s=n[e]).push(t,i):s=n[e]=[t,i],void 0!==r&&s.push(r)}function ON(n,t,e,i,r,s){for(let h=0;h0;){const e=n[--t];if("number"==typeof e&&e<0)return e}return 0})(o)!=a&&o.push(a),o.push(e,i,s)}}(n,t,i,Yp(n,e,r.hostVars,Qt),r)}function VV(n,t,e,i,r,s){const o=s[t];if(null!==o)for(let a=0;an.nextProducerIndex;)n.producerNode.pop(),n.producerLastReadVersion.pop(),n.producerIndexOfThis.pop()}}(a,o),function dV(n){n.lView[Uc]!==n&&(n.lView=null,fN.push(n))}(a)),t1()}}function FN(n,t){for(let e=pN(n);null!==e;e=gN(e))for(let i=mn;i-1&&(Rp(t,i),Ym(e,i))}this._attachedToViewContainer=!1}ay(this._lView[Be],this._lView)}onDestroy(t){!function Rm(n,t){if(256==(256&n[Ct]))throw new F(911,!1);null===n[qh]&&(n[qh]=[]),n[qh].push(t)}(this._lView,t)}markForCheck(){Qp(this._cdRefInjectingView||this._lView)}detach(){this._lView[Ct]&=-129}reattach(){Gb(this._lView),this._lView[Ct]|=128}detectChanges(){this._lView[Ct]|=1024,function MM(n,t=!0){const e=n[Kl],i=e.rendererFactory;i.begin?.();try{!function QV(n){wM(n,0);let t=0;for(;uA(n);){if(100===t)throw new F(103,!1);t++,wM(n,1)}}(n)}catch(s){throw t&&Dy(n,s),s}finally{i.end?.(),e.inlineEffectRunner?.flush()}}(this._lView,this.notifyErrorHandler)}checkNoChanges(){}attachToViewContainerRef(){if(this._appRef)throw new F(902,!1);this._attachedToViewContainer=!0}detachFromAppRef(){this._appRef=null,CL(this._lView[Be],this._lView)}attachToAppRef(t){if(this._attachedToViewContainer)throw new F(902,!1);this._appRef=t,Gb(this._lView)}}const VN=new Set;function EM(n){return t=>{setTimeout(n,void 0,t)}}const Yo=class a7 extends Pt{constructor(t=!1){super(),this.__isAsync=t}emit(t){super.next(t)}subscribe(t,e,i){let r=t,s=e||(()=>null),o=i;if(t&&"object"==typeof t){const l=t;r=l.next?.bind(l),s=l.error?.bind(l),o=l.complete?.bind(l)}this.__isAsync&&(s=EM(s),r&&(r=EM(r)),o&&(o=EM(o)));const a=super.subscribe({next:r,error:s,complete:o});return t instanceof As&&t.add(a),a}};function WN(...n){}class Rr{constructor({enableLongStackTrace:t=!1,shouldCoalesceEventChangeDetection:e=!1,shouldCoalesceRunChangeDetection:i=!1}){if(this.hasPendingMacrotasks=!1,this.hasPendingMicrotasks=!1,this.isStable=!0,this.onUnstable=new Yo(!1),this.onMicrotaskEmpty=new Yo(!1),this.onStable=new Yo(!1),this.onError=new Yo(!1),typeof Zone>"u")throw new F(908,!1);Zone.assertZonePatched();const r=this;r._nesting=0,r._outer=r._inner=Zone.current,Zone.TaskTrackingZoneSpec&&(r._inner=r._inner.fork(new Zone.TaskTrackingZoneSpec)),t&&Zone.longStackTraceZoneSpec&&(r._inner=r._inner.fork(Zone.longStackTraceZoneSpec)),r.shouldCoalesceEventChangeDetection=!i&&e,r.shouldCoalesceRunChangeDetection=i,r.lastRequestAnimationFrameId=-1,r.nativeRequestAnimationFrame=function l7(){const n="function"==typeof rr.requestAnimationFrame;let t=rr[n?"requestAnimationFrame":"setTimeout"],e=rr[n?"cancelAnimationFrame":"clearTimeout"];if(typeof Zone<"u"&&t&&e){const i=t[Zone.__symbol__("OriginalDelegate")];i&&(t=i);const r=e[Zone.__symbol__("OriginalDelegate")];r&&(e=r)}return{nativeRequestAnimationFrame:t,nativeCancelAnimationFrame:e}}().nativeRequestAnimationFrame,function d7(n){const t=()=>{!function c7(n){n.isCheckStableRunning||-1!==n.lastRequestAnimationFrameId||(n.lastRequestAnimationFrameId=n.nativeRequestAnimationFrame.call(rr,()=>{n.fakeTopEventTask||(n.fakeTopEventTask=Zone.root.scheduleEventTask("fakeTopEventTask",()=>{n.lastRequestAnimationFrameId=-1,xM(n),n.isCheckStableRunning=!0,DM(n),n.isCheckStableRunning=!1},void 0,()=>{},()=>{})),n.fakeTopEventTask.invoke()}),xM(n))}(n)};n._inner=n._inner.fork({name:"angular",properties:{isAngularZone:!0},onInvokeTask:(e,i,r,s,o,a)=>{if(function u7(n){return!(!Array.isArray(n)||1!==n.length)&&!0===n[0].data?.__ignore_ng_zone__}(a))return e.invokeTask(r,s,o,a);try{return YN(n),e.invokeTask(r,s,o,a)}finally{(n.shouldCoalesceEventChangeDetection&&"eventTask"===s.type||n.shouldCoalesceRunChangeDetection)&&t(),QN(n)}},onInvoke:(e,i,r,s,o,a,l)=>{try{return YN(n),e.invoke(r,s,o,a,l)}finally{n.shouldCoalesceRunChangeDetection&&t(),QN(n)}},onHasTask:(e,i,r,s)=>{e.hasTask(r,s),i===r&&("microTask"==s.change?(n._hasPendingMicrotasks=s.microTask,xM(n),DM(n)):"macroTask"==s.change&&(n.hasPendingMacrotasks=s.macroTask))},onHandleError:(e,i,r,s)=>(e.handleError(r,s),n.runOutsideAngular(()=>n.onError.emit(s)),!1)})}(r)}static isInAngularZone(){return typeof Zone<"u"&&!0===Zone.current.get("isAngularZone")}static assertInAngularZone(){if(!Rr.isInAngularZone())throw new F(909,!1)}static assertNotInAngularZone(){if(Rr.isInAngularZone())throw new F(909,!1)}run(t,e,i){return this._inner.run(t,e,i)}runTask(t,e,i,r){const s=this._inner,o=s.scheduleEventTask("NgZoneEvent: "+r,t,h7,WN,WN);try{return s.runTask(o,e,i)}finally{s.cancelTask(o)}}runGuarded(t,e,i){return this._inner.runGuarded(t,e,i)}runOutsideAngular(t){return this._outer.run(t)}}const h7={};function DM(n){if(0==n._nesting&&!n.hasPendingMicrotasks&&!n.isStable)try{n._nesting++,n.onMicrotaskEmpty.emit(null)}finally{if(n._nesting--,!n.hasPendingMicrotasks)try{n.runOutsideAngular(()=>n.onStable.emit(null))}finally{n.isStable=!0}}}function xM(n){n.hasPendingMicrotasks=!!(n._hasPendingMicrotasks||(n.shouldCoalesceEventChangeDetection||n.shouldCoalesceRunChangeDetection)&&-1!==n.lastRequestAnimationFrameId)}function YN(n){n._nesting++,n.isStable&&(n.isStable=!1,n.onUnstable.emit(null))}function QN(n){n._nesting--,DM(n)}let Xp=(()=>{class n{constructor(){this.handler=null,this.internalCallbacks=[]}execute(){const e=[...this.internalCallbacks];this.internalCallbacks.length=0;for(const r of e)r();return!!this.handler?.execute()||e.length>0}ngOnDestroy(){this.handler?.destroy(),this.handler=null,this.internalCallbacks.length=0}static{this.\u0275prov=Yi({token:n,providedIn:"root",factory:()=>new n})}}return n})();function v7(n,t){const e=To(t,n),i=e[Be];!function m7(n,t){for(let e=t.length;e0&&RL(n,e,s.join(" "))}}(u,w,p,i),void 0!==e&&function x7(n,t,e){const i=n.projection=[];for(let r=0;r=0;i--){const r=n[i];r.hostVars=t+=r.hostVars,r.hostAttrs=yp(r.hostAttrs,e=yp(e,r.hostAttrs))}}(i)}function A7(n,t){for(const e in t.inputs){if(!t.inputs.hasOwnProperty(e)||n.inputs.hasOwnProperty(e))continue;const i=t.inputs[e];if(void 0!==i&&(n.inputs[e]=i,n.declaredInputs[e]=t.declaredInputs[e],null!==t.inputTransforms)){const r=Array.isArray(i)?i[0]:i;if(!t.inputTransforms.hasOwnProperty(r))continue;n.inputTransforms??={},n.inputTransforms[r]=t.inputTransforms[r]}}}function Ty(n){return n===rl?{}:n===Qi?[]:n}function N7(n,t){const e=n.viewQuery;n.viewQuery=e?(i,r)=>{t(i,r),e(i,r)}:t}function O7(n,t){const e=n.contentQueries;n.contentQueries=e?(i,r,s)=>{t(i,r,s),e(i,r,s)}:t}function k7(n,t){const e=n.hostBindings;n.hostBindings=e?(i,r)=>{t(i,r),e(i,r)}:t}function Lu(n,t){return!t||null===t.firstChild||ry(n)}function tg(n,t,e,i=!0){const r=t[Be];if(function t6(n,t,e,i){const r=mn+i,s=e.length;i>0&&(e[r-1][wa]=t),i{class n{static{this.__NG_ELEMENT_ID__=a9}}return n})();function a9(){return fO(pr(),Se())}const l9=An,dO=class extends l9{constructor(t,e,i){super(),this._lContainer=t,this._hostTNode=e,this._hostLView=i}get element(){return xu(this._hostTNode,this._hostLView)}get injector(){return new Yn(this._hostTNode,this._hostLView)}get parentInjector(){const t=Vm(this._hostTNode,this._hostLView);if(n1(t)){const e=Ap(t,this._hostLView),i=Tp(t);return new Yn(e[Be].data[i+8],e)}return new Yn(null,this._hostLView)}clear(){for(;this.length>0;)this.remove(this.length-1)}get(t){const e=uO(this._lContainer);return null!==e&&e[t]||null}get length(){return this._lContainer.length-mn}createEmbeddedView(t,e,i){let r,s;"number"==typeof i?r=i:null!=i&&(r=i.index,s=i.injector);const a=t.createEmbeddedViewImpl(e||{},s,null);return this.insertImpl(a,r,Lu(this._hostTNode,null)),a}createComponent(t,e,i,r,s){const o=t&&!function Lp(n){return"function"==typeof n}(t);let a;if(o)a=e;else{const p=e||{};a=p.index,i=p.injector,r=p.projectableNodes,s=p.environmentInjector||p.ngModuleRef}const l=o?t:new qp(di(t)),h=i||this.parentInjector;if(!s&&null==l.ngModule){const g=(o?h:this.parentInjector).get(ih,null);g&&(s=g)}di(l.componentType??{});const f=l.create(h,r,null,s);return this.insertImpl(f.hostView,a,Lu(this._hostTNode,null)),f}insert(t,e){return this.insertImpl(t,e,!0)}insertImpl(t,e,i){const r=t._lView;if(function aU(n){return Ps(n[vn])}(r)){const a=this.indexOf(t);if(-1!==a)this.detach(a);else{const l=r[vn],h=new dO(l,l[Os],l[vn]);h.detach(h.indexOf(t))}}const s=this._adjustIndex(e),o=this._lContainer;return tg(o,r,s,i),t.attachToViewContainerRef(),_A(zM(o),s,t),t}move(t,e){return this.insert(t,e)}indexOf(t){const e=uO(this._lContainer);return null!==e?e.indexOf(t):-1}remove(t){const e=this._adjustIndex(t,-1),i=Rp(this._lContainer,e);i&&(Ym(zM(this._lContainer),e),ay(i[Be],i))}detach(t){const e=this._adjustIndex(t,-1),i=Rp(this._lContainer,e);return i&&null!=Ym(zM(this._lContainer),e)?new Gp(i):null}_adjustIndex(t,e=0){return t??this.length+e}};function uO(n){return n[8]}function zM(n){return n[8]||(n[8]=[])}function fO(n,t){let e;const i=t[n.index];return Ps(i)?e=i:(e=function PN(n,t,e,i){return[n,!0,0,t,null,i,null,e,null,null]}(i,t,null,n),t[n.index]=e,Ey(t,e)),pO(e,t,n,i),new dO(e,n,t)}let pO=function vO(n,t,e,i){if(n[sl])return;let r;r=8&e.type?fr(i):function h9(n,t){const e=n[Yt],i=e.createComment(""),r=qs(t,n);return qc(e,ly(e,r),i,function o6(n,t){return n.nextSibling(t)}(e,r),!1),i}(t,e),n[sl]=r};function XM(n,t,e){const i=Se();return function Ln(n,t,e){return!Object.is(n[t],e)&&(n[t]=e,!0)}(i,function hl(){return Rt.lFrame.bindingIndex++}(),t)&&function No(n,t,e,i,r,s,o,a){const l=qs(t,e);let c,h=t.inputs;!a&&null!=h&&(c=h[i])?(bM(n,e,c,i,r),jc(t)&&function NV(n,t){const e=To(t,n);16&e[Ct]||(e[Ct]|=64)}(e,t.index)):3&t.type&&(i=function LV(n){return"class"===n?"className":"for"===n?"htmlFor":"formaction"===n?"formAction":"innerHtml"===n?"innerHTML":"readonly"===n?"readOnly":"tabindex"===n?"tabIndex":n}(i),r=null!=o?o(r,t.value||"",i):r,s.setProperty(l,i,r))}(Ti(),function zr(){const n=Rt.lFrame;return Cp(n.tView,n.selectedIndex)}(),i,n,t,i[Yt],e,!1),XM}function qM(n,t,e,i,r){const o=r?"class":"style";bM(n,e,t.inputs[o],o,i)}function lg(n,t,e,i){const r=Se(),s=Ti(),o=jt+n,a=r[Yt],l=s.firstCreatePass?function R8(n,t,e,i,r,s){const o=t.consts,l=Tu(t,n,2,i,al(o,r));return function mM(n,t,e,i){if(pA()){const r=null===i?null:{"":-1},s=function HV(n,t){const e=n.directiveRegistry;let i=null,r=null;if(e)for(let s=0;s($h(!0),oy(i,r,function EA(){return Rt.lFrame.currentNamespace}()));const Xu="en-US";let Mk=Xu;function ow(n){return!!n&&"function"==typeof n.then}function Gk(n){return!!n&&"function"==typeof n.subscribe}function aw(n,t,e,i){const r=Se(),s=Ti(),o=pr();return function qk(n,t,e,i,r,s,o){const a=Pm(i),h=n.firstCreatePass&&HN(n),c=t[Er],d=RN(t);let u=!0;if(3&i.type||o){const g=qs(i,t),v=o?o(g):g,y=d.length,S=o?M=>o(fr(M[i.index])):i.index;let b=null;if(!o&&a&&(b=function FW(n,t,e,i){const r=n.cleanup;if(null!=r)for(let s=0;sl?a[l]:null}"string"==typeof o&&(s+=2)}return null}(n,t,r,i.index)),null!==b)(b.__ngLastListenerFn__||b).__ngNextListenerFn__=s,b.__ngLastListenerFn__=s,u=!1;else{s=Zk(i,t,c,s,!1);const M=e.listen(v,r,s);d.push(s,M),h&&h.push(r,S,y,y+1)}}else s=Zk(i,t,c,s,!1);const f=i.outputs;let p;if(u&&null!==f&&(p=f[r])){const g=p.length;if(g)for(let v=0;v-1?To(n.index,t):t);let l=$k(t,e,i,o),h=s.__ngNextListenerFn__;for(;h;)l=$k(t,e,h,o)&&l,h=h.__ngNextListenerFn__;return r&&!1===l&&o.preventDefault(),l}}function WW(){return this._results[Symbol.iterator]()}class hw{get changes(){return this._changes??=new Yo}constructor(t=!1){this._emitDistinctChangesOnly=t,this.dirty=!0,this._results=[],this._changesDetected=!1,this._changes=void 0,this.length=0,this.first=void 0,this.last=void 0;const e=hw.prototype;e[Symbol.iterator]||(e[Symbol.iterator]=WW)}get(t){return this._results[t]}map(t){return this._results.map(t)}filter(t){return this._results.filter(t)}find(t){return this._results.find(t)}reduce(t,e){return this._results.reduce(t,e)}forEach(t){this._results.forEach(t)}some(t){return this._results.some(t)}toArray(){return this._results.slice()}toString(){return this._results.toString()}reset(t,e){this.dirty=!1;const i=function lo(n){return n.flat(Number.POSITIVE_INFINITY)}(t);(this._changesDetected=!function XU(n,t,e){if(n.length!==t.length)return!1;for(let i=0;i{class n{static{this.__NG_ELEMENT_ID__=GW}}return n})();const YW=oh,QW=class extends YW{constructor(t,e,i){super(),this._declarationLView=t,this._declarationTContainer=e,this.elementRef=i}get ssrId(){return this._declarationTContainer.tView?.ssrId||null}createEmbeddedView(t,e){return this.createEmbeddedViewImpl(t,e)}createEmbeddedViewImpl(t,e,i){const r=function eg(n,t,e,i){const r=t.tView,a=Cy(n,r,e,4096&n[Ct]?4096:16,null,t,null,null,null,i?.injector??null,i?.dehydratedView??null);a[Ip]=n[t.index];const h=n[nl];return null!==h&&(a[nl]=h.createEmbeddedView(r)),TM(r,a,e),a}(this._declarationLView,this._declarationTContainer,t,{injector:e,dehydratedView:i});return new Gp(r)}};function GW(){return Yy(pr(),Se())}function Yy(n,t){return 4&n.type?new QW(t,n,xu(n,t)):null}class cw{constructor(t){this.queryList=t,this.matches=null}clone(){return new cw(this.queryList)}setDirty(){this.queryList.setDirty()}}class dw{constructor(t=[]){this.queries=t}createEmbeddedView(t){const e=t.queries;if(null!==e){const i=null!==t.contentQueries?t.contentQueries[0]:e.length,r=[];for(let s=0;s0)i.push(o[a/2]);else{const h=s[a+1],c=t[-l];for(let d=mn;d($h(!0),function sy(n,t){return n.createText(t)}(t[Yt],i));function vw(n,t,e,i,r){if(n=vt(n),Array.isArray(n))for(let s=0;s>20;if(Gc(n)||!n.multi){const f=new xp(h,r,Ot),p=yw(l,t,r?c:c+u,d);-1===p?(a1(jm(a,o),s,l),mw(s,n,t.length),t.push(l),a.directiveStart++,a.directiveEnd++,r&&(a.providerIndexes+=1048576),e.push(f),o.push(f)):(e[p]=f,o[p]=f)}else{const f=yw(l,t,c+u,d),p=yw(l,t,c,c+u),v=p>=0&&e[p];if(r&&!v||!r&&!(f>=0&&e[f])){a1(jm(a,o),s,l);const y=function vY(n,t,e,i,r){const s=new xp(n,e,Ot);return s.multi=[],s.index=t,s.componentProviders=0,kP(s,r,i&&!e),s}(r?gY:pY,e.length,r,i,h);!r&&v&&(e[p].providerFactory=y),mw(s,n,t.length,0),t.push(l),a.directiveStart++,a.directiveEnd++,r&&(a.providerIndexes+=1048576),e.push(y),o.push(y)}else mw(s,n,f>-1?f:p,kP(e[r?p:f],h,!r&&i));!r&&i&&v&&e[p].componentProviders++}}}function mw(n,t,e,i){const r=Gc(t),s=function fj(n){return!!n.useClass}(t);if(r||s){const l=(s?vt(t.useClass):t).prototype.ngOnDestroy;if(l){const h=n.destroyHooks||(n.destroyHooks=[]);if(!r&&t.multi){const c=h.indexOf(e);-1===c?h.push(e,[i,l]):h[c+1].push(i,l)}else h.push(e,l)}}}function kP(n,t,e){return e&&n.componentProviders++,n.multi.push(t)-1}function yw(n,t,e,i){for(let r=e;r{e.providersResolver=(i,r)=>function fY(n,t,e){const i=Ti();if(i.firstCreatePass){const r=Ea(n);vw(e,i.data,i.blueprint,r,!0),vw(t,i.data,i.blueprint,r,!1)}}(i,r?r(n):n,t)}}class rd{}class zP extends rd{constructor(t){super(),this.componentFactoryResolver=new JN(this),this.instance=null;const e=new mu([...t.providers,{provide:rd,useValue:this},{provide:Iy,useValue:this.componentFactoryResolver}],t.parent||Jm(),t.debugName,new Set(["environment"]));this.injector=e,t.runEnvironmentInitializers&&e.resolveInjectorInitializers()}destroy(){this.injector.destroy()}onDestroy(t){this.injector.onDestroy(t)}}let bY=(()=>{class n{constructor(e){this._injector=e,this.cachedInjectors=new Map}getOrCreateStandaloneInjector(e){if(!e.standalone)return null;if(!this.cachedInjectors.has(e)){const i=GA(0,e.type),r=i.length>0?function IY(n,t,e=null){return new zP({providers:n,parent:t,debugName:e,runEnvironmentInitializers:!0}).injector}([i],this._injector,`Standalone[${e.type.name}]`):null;this.cachedInjectors.set(e,r)}return this.cachedInjectors.get(e)}ngOnDestroy(){try{for(const e of this.cachedInjectors.values())null!==e&&e.destroy()}finally{this.cachedInjectors.clear()}}static{this.\u0275prov=Yi({token:n,providedIn:"environment",factory:()=>new n(_i(ih))})}}return n})();function RP(n){(function Zc(n){VN.has(n)||(VN.add(n),performance?.mark?.("mark_feature_usage",{detail:{feature:n}}))})("NgStandalone"),n.getStandaloneInjector=t=>t.get(bY).getOrCreateStandaloneInjector(n)}let Tw=(()=>{class n{constructor(){this.taskId=0,this.pendingTasks=new Set,this.hasPendingTasks=new _o(!1)}get _hasPendingTasks(){return this.hasPendingTasks.value}add(){this._hasPendingTasks||this.hasPendingTasks.next(!0);const e=this.taskId++;return this.pendingTasks.add(e),e}remove(e){this.pendingTasks.delete(e),0===this.pendingTasks.size&&this._hasPendingTasks&&this.hasPendingTasks.next(!1)}ngOnDestroy(){this.pendingTasks.clear(),this._hasPendingTasks&&this.hasPendingTasks.next(!1)}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();const g2=new Ht(""),QQ=new Ht("");let kw=(()=>{class n{constructor(){this.initialized=!1,this.done=!1,this.donePromise=new Promise((e,i)=>{this.resolve=e,this.reject=i}),this.appInits=Hi(QQ,{optional:!0})??[]}runInitializers(){if(this.initialized)return;const e=[];for(const r of this.appInits){const s=r();if(ow(s))e.push(s);else if(Gk(s)){const o=new Promise((a,l)=>{s.subscribe({complete:a,error:l})});e.push(o)}}const i=()=>{this.done=!0,this.resolve()};Promise.all(e).then(()=>{i()}).catch(r=>{this.reject(r)}),0===e.length&&i(),this.initialized=!0}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();const v2=new Ht("");let Zu=(()=>{class n{constructor(){this._bootstrapListeners=[],this._runningTick=!1,this._destroyed=!1,this._destroyListeners=[],this._views=[],this.internalErrorHandler=Hi(yN),this.afterRenderEffectManager=Hi(Xp),this.componentTypes=[],this.components=[],this.isStable=Hi(Tw).hasPendingTasks.pipe(jr(e=>!e)),this._injector=Hi(ih)}get destroyed(){return this._destroyed}get injector(){return this._injector}bootstrap(e,i){const r=e instanceof iN;if(!this._injector.get(kw).done)throw!r&&function _c(n){const t=di(n)||Wn(n)||gs(n);return null!==t&&t.standalone}(e),new F(405,!1);let o;o=r?e:this._injector.get(Iy).resolveComponentFactory(e),this.componentTypes.push(o.componentType);const a=function XQ(n){return n.isBoundToModule}(o)?void 0:this._injector.get(rd),h=o.create(Wo.NULL,[],i||o.selector,a),c=h.location.nativeElement,d=h.injector.get(g2,null);return d?.registerApplication(c),h.onDestroy(()=>{this.detachView(h.hostView),Zy(this.components,h),d?.unregisterApplication(c)}),this._loadComponent(h),h}tick(){if(this._runningTick)throw new F(101,!1);try{this._runningTick=!0;for(let e of this._views)e.detectChanges()}catch(e){this.internalErrorHandler(e)}finally{try{this.afterRenderEffectManager.execute()}catch(e){this.internalErrorHandler(e)}this._runningTick=!1}}attachView(e){const i=e;this._views.push(i),i.attachToAppRef(this)}detachView(e){const i=e;Zy(this._views,i),i.detachFromAppRef()}_loadComponent(e){this.attachView(e.hostView),this.tick(),this.components.push(e);const i=this._injector.get(v2,[]);[...this._bootstrapListeners,...i].forEach(r=>r(e))}ngOnDestroy(){if(!this._destroyed)try{this._destroyListeners.forEach(e=>e()),this._views.slice().forEach(e=>e.destroy())}finally{this._destroyed=!0,this._views=[],this._bootstrapListeners=[],this._destroyListeners=[]}}onDestroy(e){return this._destroyListeners.push(e),()=>Zy(this._destroyListeners,e)}destroy(){if(this._destroyed)throw new F(406,!1);const e=this._injector;e.destroy&&!e.destroyed&&e.destroy()}get viewCount(){return this._views.length}warnIfDestroyed(){}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();function Zy(n,t){const e=n.indexOf(t);e>-1&&n.splice(e,1)}let $Q=(()=>{class n{constructor(){this.zone=Hi(Rr),this.applicationRef=Hi(Zu)}initialize(){this._onMicrotaskEmptySubscription||(this._onMicrotaskEmptySubscription=this.zone.onMicrotaskEmpty.subscribe({next:()=>{this.zone.run(()=>{this.applicationRef.tick()})}}))}ngOnDestroy(){this._onMicrotaskEmptySubscription?.unsubscribe()}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();function b2(n){return[{provide:Rr,useFactory:n},{provide:vu,multi:!0,useFactory:()=>{const t=Hi($Q,{optional:!0});return()=>t.initialize()}},{provide:vu,multi:!0,useFactory:()=>{const t=Hi(KQ);return()=>{t.initialize()}}},{provide:yN,useFactory:ZQ}]}function ZQ(){const n=Hi(Rr),t=Hi(nh);return e=>n.runOutsideAngular(()=>t.handleError(e))}function JQ(n){return function y1(n){return{\u0275providers:n}}([[],b2(()=>new Rr(function M2(n){return{enableLongStackTrace:!1,shouldCoalesceEventChangeDetection:n?.eventCoalescing??!1,shouldCoalesceRunChangeDetection:n?.runCoalescing??!1}}(n)))])}let KQ=(()=>{class n{constructor(){this.subscription=new As,this.initialized=!1,this.zone=Hi(Rr),this.pendingTasks=Hi(Tw)}initialize(){if(this.initialized)return;this.initialized=!0;let e=null;!this.zone.isStable&&!this.zone.hasPendingMacrotasks&&!this.zone.hasPendingMicrotasks&&(e=this.pendingTasks.add()),this.zone.runOutsideAngular(()=>{this.subscription.add(this.zone.onStable.subscribe(()=>{Rr.assertNotInAngularZone(),queueMicrotask(()=>{null!==e&&!this.zone.hasPendingMacrotasks&&!this.zone.hasPendingMicrotasks&&(this.pendingTasks.remove(e),e=null)})}))}),this.subscription.add(this.zone.onUnstable.subscribe(()=>{Rr.assertInAngularZone(),e??=this.pendingTasks.add()}))}ngOnDestroy(){this.subscription.unsubscribe()}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();const ah=new Ht("",{providedIn:"root",factory:()=>Hi(ah,xi.Optional|xi.SkipSelf)||function eG(){return typeof $localize<"u"&&$localize.locale||Xu}()}),Pw=new Ht("");let nc=null;function CG(n){try{const{rootComponent:t,appProviders:e,platformProviders:i}=n,r=function sG(n=[]){if(nc)return nc;const t=function E2(n=[],t){return Wo.create({name:t,providers:[{provide:b1,useValue:"platform"},{provide:Pw,useValue:new Set([()=>nc=null])},...n]})}(n);return nc=t,function m2(){!function Sb(n){Xd=n}(()=>{throw new F(600,!1)})}(),function D2(n){n.get(nL,null)?.forEach(e=>e())}(t),t}(i),s=[JQ(),...e||[]],a=new zP({providers:s,parent:r,debugName:"",runEnvironmentInitializers:!1}).injector,l=a.get(Rr);return l.run(()=>{a.resolveInjectorInitializers();const h=a.get(nh,null);let c;l.runOutsideAngular(()=>{c=l.onError.subscribe({next:f=>{h.handleError(f)}})});const d=()=>a.destroy(),u=r.get(Pw);return u.add(d),a.onDestroy(()=>{c.unsubscribe(),u.delete(d)}),function y2(n,t,e){try{const i=e();return ow(i)?i.catch(r=>{throw t.runOutsideAngular(()=>n.handleError(r)),r}):i}catch(i){throw t.runOutsideAngular(()=>n.handleError(i)),i}}(h,l,()=>{const f=a.get(kw);return f.runInitializers(),f.donePromise.then(()=>{!function wk(n){so(n,"Expected localeId to be defined"),"string"==typeof n&&(Mk=n.toLowerCase().replace(/_/g,"-"))}(a.get(ah,Xu)||Xu);const g=a.get(Zu);return void 0!==t&&g.bootstrap(t),g})})})}catch(t){return Promise.reject(t)}}let $2=null;function jw(){return $2}class FG{}const sd=new Ht("");let rq=(()=>{class n{static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275mod=Lm({type:n})}static{this.\u0275inj=gp({})}}return n})();function uz(n){return"server"===n}class Nq extends FG{constructor(){super(...arguments),this.supportsDOMEvents=!0}}class sC extends Nq{static makeCurrent(){!function BG(n){$2??=n}(new sC)}onAndCancel(t,e,i){return t.addEventListener(e,i),()=>{t.removeEventListener(e,i)}}dispatchEvent(t,e){t.dispatchEvent(e)}remove(t){t.parentNode&&t.parentNode.removeChild(t)}createElement(t,e){return(e=e||this.getDefaultDocument()).createElement(t)}createHtmlDocument(){return document.implementation.createHTMLDocument("fakeTitle")}getDefaultDocument(){return document}isElementNode(t){return t.nodeType===Node.ELEMENT_NODE}isShadowRoot(t){return t instanceof DocumentFragment}getGlobalEventTarget(t,e){return"window"===e?window:"document"===e?t:"body"===e?t.body:null}getBaseHref(t){const e=function Oq(){return wg=wg||document.querySelector("base"),wg?wg.getAttribute("href"):null}();return null==e?null:function kq(n){return new URL(n,document.baseURI).pathname}(e)}resetBaseElement(){wg=null}getUserAgent(){return window.navigator.userAgent}getCookie(t){return function EX(n,t){t=encodeURIComponent(t);for(const e of n.split(";")){const i=e.indexOf("="),[r,s]=-1==i?[e,""]:[e.slice(0,i),e.slice(i+1)];if(r.trim()===t)return decodeURIComponent(s)}return null}(document.cookie,t)}}let wg=null,zq=(()=>{class n{build(){return new XMLHttpRequest}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();const oC=new Ht("");let vz=(()=>{class n{constructor(e,i){this._zone=i,this._eventNameToPlugin=new Map,e.forEach(r=>{r.manager=this}),this._plugins=e.slice().reverse()}addEventListener(e,i,r){return this._findPluginFor(i).addEventListener(e,i,r)}getZone(){return this._zone}_findPluginFor(e){let i=this._eventNameToPlugin.get(e);if(i)return i;if(i=this._plugins.find(s=>s.supports(e)),!i)throw new F(5101,!1);return this._eventNameToPlugin.set(e,i),i}static{this.\u0275fac=function(i){return new(i||n)(_i(oC),_i(Rr))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();class mz{constructor(t){this._doc=t}}const aC="ng-app-id";let yz=(()=>{class n{constructor(e,i,r,s={}){this.doc=e,this.appId=i,this.nonce=r,this.platformId=s,this.styleRef=new Map,this.hostNodes=new Set,this.styleNodesInDOM=this.collectServerRenderedStyles(),this.platformIsServer=uz(s),this.resetHostNodes()}addStyles(e){for(const i of e)1===this.changeUsageCount(i,1)&&this.onStyleAdded(i)}removeStyles(e){for(const i of e)this.changeUsageCount(i,-1)<=0&&this.onStyleRemoved(i)}ngOnDestroy(){const e=this.styleNodesInDOM;e&&(e.forEach(i=>i.remove()),e.clear());for(const i of this.getAllStyles())this.onStyleRemoved(i);this.resetHostNodes()}addHost(e){this.hostNodes.add(e);for(const i of this.getAllStyles())this.addStyleToHost(e,i)}removeHost(e){this.hostNodes.delete(e)}getAllStyles(){return this.styleRef.keys()}onStyleAdded(e){for(const i of this.hostNodes)this.addStyleToHost(i,e)}onStyleRemoved(e){const i=this.styleRef;i.get(e)?.elements?.forEach(r=>r.remove()),i.delete(e)}collectServerRenderedStyles(){const e=this.doc.head?.querySelectorAll(`style[${aC}="${this.appId}"]`);if(e?.length){const i=new Map;return e.forEach(r=>{null!=r.textContent&&i.set(r.textContent,r)}),i}return null}changeUsageCount(e,i){const r=this.styleRef;if(r.has(e)){const s=r.get(e);return s.usage+=i,s.usage}return r.set(e,{usage:i,elements:[]}),i}getStyleElement(e,i){const r=this.styleNodesInDOM,s=r?.get(i);if(s?.parentNode===e)return r.delete(i),s.removeAttribute(aC),s;{const o=this.doc.createElement("style");return this.nonce&&o.setAttribute("nonce",this.nonce),o.textContent=i,this.platformIsServer&&o.setAttribute(aC,this.appId),e.appendChild(o),o}}addStyleToHost(e,i){const r=this.getStyleElement(e,i),s=this.styleRef,o=s.get(i)?.elements;o?o.push(r):s.set(i,{elements:[r],usage:1})}resetHostNodes(){const e=this.hostNodes;e.clear(),e.add(this.doc.head)}static{this.\u0275fac=function(i){return new(i||n)(_i(sd),_i(T1),_i(sL,8),_i(Su))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();const lC={svg:"http://www.w3.org/2000/svg",xhtml:"http://www.w3.org/1999/xhtml",xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/",math:"http://www.w3.org/1998/MathML/"},hC=/%COMP%/g,Fq=new Ht("",{providedIn:"root",factory:()=>!0});function Iz(n,t){return t.map(e=>e.replace(hC,n))}let bz=(()=>{class n{constructor(e,i,r,s,o,a,l,h=null){this.eventManager=e,this.sharedStylesHost=i,this.appId=r,this.removeStylesOnCompDestroy=s,this.doc=o,this.platformId=a,this.ngZone=l,this.nonce=h,this.rendererByCompId=new Map,this.platformIsServer=uz(a),this.defaultRenderer=new cC(e,o,l,this.platformIsServer)}createRenderer(e,i){if(!e||!i)return this.defaultRenderer;this.platformIsServer&&i.encapsulation===ba.ShadowDom&&(i={...i,encapsulation:ba.Emulated});const r=this.getOrCreateRenderer(e,i);return r instanceof wz?r.applyToHost(e):r instanceof dC&&r.applyStyles(),r}getOrCreateRenderer(e,i){const r=this.rendererByCompId;let s=r.get(i.id);if(!s){const o=this.doc,a=this.ngZone,l=this.eventManager,h=this.sharedStylesHost,c=this.removeStylesOnCompDestroy,d=this.platformIsServer;switch(i.encapsulation){case ba.Emulated:s=new wz(l,h,i,this.appId,c,o,a,d);break;case ba.ShadowDom:return new Vq(l,h,e,i,o,a,this.nonce,d);default:s=new dC(l,h,i,c,o,a,d)}r.set(i.id,s)}return s}ngOnDestroy(){this.rendererByCompId.clear()}static{this.\u0275fac=function(i){return new(i||n)(_i(vz),_i(yz),_i(T1),_i(Fq),_i(sd),_i(Su),_i(Rr),_i(sL))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();class cC{constructor(t,e,i,r){this.eventManager=t,this.doc=e,this.ngZone=i,this.platformIsServer=r,this.data=Object.create(null),this.throwOnSyntheticProps=!0,this.destroyNode=null}destroy(){}createElement(t,e){return e?this.doc.createElementNS(lC[e]||e,t):this.doc.createElement(t)}createComment(t){return this.doc.createComment(t)}createText(t){return this.doc.createTextNode(t)}appendChild(t,e){(Mz(t)?t.content:t).appendChild(e)}insertBefore(t,e,i){t&&(Mz(t)?t.content:t).insertBefore(e,i)}removeChild(t,e){t&&t.removeChild(e)}selectRootElement(t,e){let i="string"==typeof t?this.doc.querySelector(t):t;if(!i)throw new F(-5104,!1);return e||(i.textContent=""),i}parentNode(t){return t.parentNode}nextSibling(t){return t.nextSibling}setAttribute(t,e,i,r){if(r){e=r+":"+e;const s=lC[r];s?t.setAttributeNS(s,e,i):t.setAttribute(e,i)}else t.setAttribute(e,i)}removeAttribute(t,e,i){if(i){const r=lC[i];r?t.removeAttributeNS(r,e):t.removeAttribute(`${i}:${e}`)}else t.removeAttribute(e)}addClass(t,e){t.classList.add(e)}removeClass(t,e){t.classList.remove(e)}setStyle(t,e,i,r){r&(ec.DashCase|ec.Important)?t.style.setProperty(e,i,r&ec.Important?"important":""):t.style[e]=i}removeStyle(t,e,i){i&ec.DashCase?t.style.removeProperty(e):t.style[e]=""}setProperty(t,e,i){null!=t&&(t[e]=i)}setValue(t,e){t.nodeValue=e}listen(t,e,i){if("string"==typeof t&&!(t=jw().getGlobalEventTarget(this.doc,t)))throw new Error(`Unsupported event target ${t} for event ${e}`);return this.eventManager.addEventListener(t,e,this.decoratePreventDefault(i))}decoratePreventDefault(t){return e=>{if("__ngUnwrap__"===e)return t;!1===(this.platformIsServer?this.ngZone.runGuarded(()=>t(e)):t(e))&&e.preventDefault()}}}function Mz(n){return"TEMPLATE"===n.tagName&&void 0!==n.content}class Vq extends cC{constructor(t,e,i,r,s,o,a,l){super(t,s,o,l),this.sharedStylesHost=e,this.hostEl=i,this.shadowRoot=i.attachShadow({mode:"open"}),this.sharedStylesHost.addHost(this.shadowRoot);const h=Iz(r.id,r.styles);for(const c of h){const d=document.createElement("style");a&&d.setAttribute("nonce",a),d.textContent=c,this.shadowRoot.appendChild(d)}}nodeOrShadowRoot(t){return t===this.hostEl?this.shadowRoot:t}appendChild(t,e){return super.appendChild(this.nodeOrShadowRoot(t),e)}insertBefore(t,e,i){return super.insertBefore(this.nodeOrShadowRoot(t),e,i)}removeChild(t,e){return super.removeChild(this.nodeOrShadowRoot(t),e)}parentNode(t){return this.nodeOrShadowRoot(super.parentNode(this.nodeOrShadowRoot(t)))}destroy(){this.sharedStylesHost.removeHost(this.shadowRoot)}}class dC extends cC{constructor(t,e,i,r,s,o,a,l){super(t,s,o,a),this.sharedStylesHost=e,this.removeStylesOnCompDestroy=r,this.styles=l?Iz(l,i.styles):i.styles}applyStyles(){this.sharedStylesHost.addStyles(this.styles)}destroy(){this.removeStylesOnCompDestroy&&this.sharedStylesHost.removeStyles(this.styles)}}class wz extends dC{constructor(t,e,i,r,s,o,a,l){const h=r+"-"+i.id;super(t,e,i,s,o,a,l,h),this.contentAttr=function _q(n){return"_ngcontent-%COMP%".replace(hC,n)}(h),this.hostAttr=function Uq(n){return"_nghost-%COMP%".replace(hC,n)}(h)}applyToHost(t){this.applyStyles(),this.setAttribute(t,this.hostAttr,"")}createElement(t,e){const i=super.createElement(t,e);return super.setAttribute(i,this.contentAttr,""),i}}let Wq=(()=>{class n extends mz{constructor(e){super(e)}supports(e){return!0}addEventListener(e,i,r){return e.addEventListener(i,r,!1),()=>this.removeEventListener(e,i,r)}removeEventListener(e,i,r){return e.removeEventListener(i,r)}static{this.\u0275fac=function(i){return new(i||n)(_i(sd))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();const Cz=["alt","control","meta","shift"],Yq={"\b":"Backspace","\t":"Tab","\x7f":"Delete","\x1b":"Escape",Del:"Delete",Esc:"Escape",Left:"ArrowLeft",Right:"ArrowRight",Up:"ArrowUp",Down:"ArrowDown",Menu:"ContextMenu",Scroll:"ScrollLock",Win:"OS"},Qq={alt:n=>n.altKey,control:n=>n.ctrlKey,meta:n=>n.metaKey,shift:n=>n.shiftKey};let Gq=(()=>{class n extends mz{constructor(e){super(e)}supports(e){return null!=n.parseEventName(e)}addEventListener(e,i,r){const s=n.parseEventName(i),o=n.eventCallback(s.fullKey,r,this.manager.getZone());return this.manager.getZone().runOutsideAngular(()=>jw().onAndCancel(e,s.domEventName,o))}static parseEventName(e){const i=e.toLowerCase().split("."),r=i.shift();if(0===i.length||"keydown"!==r&&"keyup"!==r)return null;const s=n._normalizeKey(i.pop());let o="",a=i.indexOf("code");if(a>-1&&(i.splice(a,1),o="code."),Cz.forEach(h=>{const c=i.indexOf(h);c>-1&&(i.splice(c,1),o+=h+".")}),o+=s,0!=i.length||0===s.length)return null;const l={};return l.domEventName=r,l.fullKey=o,l}static matchEventFullKeyCode(e,i){let r=Yq[e.key]||e.key,s="";return i.indexOf("code.")>-1&&(r=e.code,s="code."),!(null==r||!r)&&(r=r.toLowerCase()," "===r?r="space":"."===r&&(r="dot"),Cz.forEach(o=>{o!==r&&(0,Qq[o])(e)&&(s+=o+".")}),s+=r,s===i)}static eventCallback(e,i,r){return s=>{n.matchEventFullKeyCode(s,e)&&r.runGuarded(()=>i(s))}}static _normalizeKey(e){return"esc"===e?"escape":e}static{this.\u0275fac=function(i){return new(i||n)(_i(sd))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();function Ez(n){return{appProviders:[...e$,...n?.providers??[]],platformProviders:Jq}}const Jq=[{provide:Su,useValue:"browser"},{provide:nL,useValue:function qq(){sC.makeCurrent()},multi:!0},{provide:sd,useFactory:function Zq(){return function xj(n){x1=n}(document),document},deps:[]}],e$=[{provide:b1,useValue:"root"},{provide:nh,useFactory:function $q(){return new nh},deps:[]},{provide:oC,useClass:Wq,multi:!0,deps:[sd,Rr,Su]},{provide:oC,useClass:Gq,multi:!0,deps:[sd]},bz,yz,vz,{provide:nN,useExisting:bz},{provide:class lq{},useClass:zq,deps:[]},[]];var n$=0,uC=!1;function I0(n,t){var e=t;return e.unshift(void 0),new(Function.prototype.bind.apply(n,e))}function Y(n,t){for(var e=t,i=n.replace(/\[/g,".").replace(/\]/g,"").split("."),r=0;r"u"}function Ei(n){return n+"_"+n$++}function M0(n,t){return n===t||!(n===document||!n)&&M0(n.parentNode,t)}function Dg(n){try{throw new Error(n)}catch(t){throw new Error(t.message+"\n"+t.stack)}}function Re(n){var t=n+"";return t.match(/auto|cm|mm|in|px|pt|pc|%|em|ex|ch|rem|vw|vh|vmin|vmax/)?t:t+"px"}function ce(){return uC}var xg,n,t,h$={latn:{_digits:"0123456789",_type:"numeric"}},Lz={decimal:".",group:",",percentSign:"%",plusSign:"+",minusSign:"-",infinity:"\u221e",nan:"NaN",exponential:"E"},Nz=[0,1,2,3,4,5,6,7,8,9],Hr=function(){function n(){}return n.getMainObject=function(t,e){return Y(ce()?e:"main."+e,t)},n.getNumberingSystem=function(t){return Y("supplemental.numberingSystems",t)||this.numberingSystems},n.reverseObject=function(t,e){for(var r={},s=0,o=e||Object.keys(t);s13&&(p+=1,o-=12),o-=1,a=p-4716;var y=u-24e5,S=10631/30,b=u-1948084,M=Math.floor(b/10631);b-=10631*M;var w=Math.floor((b-.1335)/S),C=30*M+w;b-=Math.floor(w*S+.1335);var D=Math.floor((b+28.5001)/29.5);13===D&&(D=12);for(var A=b-Math.floor(29.5001*D-29),x=0;xy);x++);var P=x+16260,L=Math.floor((P-1)/12),O=L+1,N=P-12*L,T=y-t[x-1]+1;return(T+"").length>2&&(T=A,N=D,O=C),{year:O,month:N,date:T}},n.toGregorian=function i(r,s,o){var g=Math.floor(o+t[12*(r-1)+1+(s-1)-16260-1]-1+24e5+.5),v=Math.floor((g-1867216.25)/36524.25),y=1524+(v=g+1+v-Math.floor(v/4)),S=Math.floor((y-122.1)/365.25),b=Math.floor(365.25*S),M=Math.floor((y-b)/30.6001),w=y-b-Math.floor(30.6001*M),C=M-(M>13.5?13:1),D=S-(C>2.5?4716:4715);return D<=0&&C--,new Date(D+"/"+C+"/"+w)};var ut,u$=/\/MMMMM|MMMM|MMM|a|LLLL|LLL|EEEEE|EEEE|E|K|cccc|ccc|WW|W|G+|z+/gi,Oz="stand-alone",f$=["sun","mon","tue","wed","thu","fri","sat"],kz={m:"getMinutes",h:"getHours",H:"getHours",s:"getSeconds",d:"getDate",f:"getMilliseconds"},Pz=function(){function n(){}return n.dateFormat=function(t,e,i){var r=this,s=ut.getDependables(i,t,e.calendar),o=Y("parserObject.numbers",s),a=s.dateObject,l={isIslamic:ut.islamicRegex.test(e.calendar)};ce()&&e.isServerRendered&&(e=ut.compareBlazorDateFormats(e,t));var h=e.format||ut.getResultantPattern(e.skeleton,s.dateObject,e.type,!1,ce()?t:"");if(l.dateSeperator=ce()?Y("dateSeperator",a):ut.getDateSeparator(s.dateObject),st(h))Dg("Format options or type given must be invalid");else{h=ut.ConvertDateToWeekFormat(h),ce()&&(h=h.replace(/tt/,"a")),l.pattern=h,l.numMapper=ce()?ze({},o):Hr.getNumberMapper(s.parserObject,Hr.getNumberingSystem(i));for(var d=0,u=h.match(u$)||[];d2?r+=e.month[""+u]:p=!0;break;case"E":case"c":r+=e.weekday[""+f$[t.getDay()]];break;case"H":case"h":case"m":case"s":case"d":case"f":if(p=!0,"d"===d)u=o.date;else if("f"===d){p=!1,g=!0;var y=(f=(f=t[""+kz[""+d]]().toString()).substring(0,c)).length;if(c!==y){if(c>3)continue;for(var S=0;S0?1:0],o=Math.abs(t);return s.replace(/HH?|mm/g,function(a){var l=a.length,h=-1!==a.indexOf("H");return i.checkTwodigitNumber(Math.floor(h?o/60:o%60),l)})},n}(),zz={ms:"minimumSignificantDigits",ls:"maximumSignificantDigits",mf:"minimumFractionDigits",lf:"maximumFractionDigits"},tf=["infinity","nan","group","decimal","exponential"],Rz=function(){function n(){}return n.numberFormatter=function(t,e,i){var l,r=this,s=ze({},e),o={},a={},h=ut.getDependables(i,t,"",!0),c=h.numericObject;a.numberMapper=ce()?ze({},c):Hr.getNumberMapper(h.parserObject,Hr.getNumberingSystem(i),!0),a.currencySymbol=ce()?Y("currencySymbol",c):ut.getCurrencySymbol(h.numericObject,s.currency||Lg,e.altSymbol,e.ignoreCurrency),a.percentSymbol=ce()?Y("numberSymbols.percentSign",c):a.numberMapper.numberSymbols.percentSign,a.minusSymbol=ce()?Y("numberSymbols.minusSign",c):a.numberMapper.numberSymbols.minusSign;var d=a.numberMapper.numberSymbols;if(e.format&&!ut.formatRegex.test(e.format))o=ut.customFormat(e.format,a,h.numericObject),!st(s.useGrouping)&&s.useGrouping&&(s.useGrouping=o.pData.useGrouping);else{if(ze(s,ut.getProperNumericSkeleton(e.format||"N")),s.isCurrency="currency"===s.type,s.isPercent="percent"===s.type,ce()||(l=ut.getSymbolPattern(s.type,a.numberMapper.numberSystem,h.numericObject,s.isAccount)),s.groupOne=this.checkValueRange(s.maximumSignificantDigits,s.minimumSignificantDigits,!0),this.checkValueRange(s.maximumFractionDigits,s.minimumFractionDigits,!1,!0),st(s.fractionDigits)||(s.minimumFractionDigits=s.maximumFractionDigits=s.fractionDigits),st(s.useGrouping)&&(s.useGrouping=!0),s.isCurrency&&!ce()&&(l=l.replace(/\u00A4/g,ut.defaultCurrency)),ce())o.nData=ze({},{},Y(s.type+"nData",c)),o.pData=ze({},{},Y(s.type+"pData",c)),"currency"===s.type&&e.currency&&ut.replaceBlazorCurrency([o.pData,o.nData],a.currencySymbol,e.currency);else{var u=l.split(";");o.nData=ut.getFormatData(u[1]||"-"+u[0],!0,a.currencySymbol),o.pData=ut.getFormatData(u[0],!1,a.currencySymbol),s.useGrouping&&(s.groupSeparator=d[tf[2]],s.groupData=this.getGroupingDetails(u[0]))}if(st(s.minimumFractionDigits)&&(s.minimumFractionDigits=o.nData.minimumFraction),st(s.maximumFractionDigits)){var p=o.nData.maximumFraction;s.maximumFractionDigits=st(p)&&s.isPercent?0:p}var g=s.minimumFractionDigits,v=s.maximumFractionDigits;!st(g)&&!st(v)&&g>v&&(s.maximumFractionDigits=g)}return ze(o.nData,s),ze(o.pData,s),function(y){return isNaN(y)?d[tf[1]]:isFinite(y)?r.intNumberFormatter(y,o,a,e):d[tf[0]]}},n.getGroupingDetails=function(t){var e={},i=t.match(ut.negativeDataRegex);if(i&&i[4]){var r=i[4],s=r.lastIndexOf(",");if(-1!==s){var o=r.split(".")[0];e.primary=o.length-s-1;var a=r.lastIndexOf(",",s-1);-1!==a&&(e.secondary=s-1-a)}}return e},n.checkValueRange=function(t,e,i,r){var s=r?"f":"s",o=0,a=zz["l"+s],l=zz["m"+s];if(st(t)||(this.checkRange(t,a,r),o++),st(e)||(this.checkRange(e,l,r),o++),2===o){if(!(tr[1])&&Dg(e+"value must be within the range"+r[0]+"to"+r[1])},n.intNumberFormatter=function(t,e,i,r){var s;if(!st(e.nData.type)){t<0?(t*=-1,s=e.nData):s=0===t&&e.zeroData||e.pData;var o="";if(s.isPercent&&(t*=100),s.groupOne)o=this.processSignificantDigits(t,s.minimumSignificantDigits,s.maximumSignificantDigits);else if(o=this.processFraction(t,s.minimumFractionDigits,s.maximumFractionDigits,r),s.minimumIntegerDigits&&(o=this.processMinimumIntegers(o,s.minimumIntegerDigits)),i.isCustomFormat&&s.minimumFractionDigits=0&&"0"===l[parseInt(c.toString(),10)]&&c>=s.minimumFractionDigits;c--)l=l.slice(0,c);o=a[0]+"."+l}return"scientific"===s.type&&(o=(o=t.toExponential(s.maximumFractionDigits)).replace("e",i.numberMapper.numberSymbols[tf[4]])),o=o.replace(".",i.numberMapper.numberSymbols[tf[3]]),o="#,###,,;(#,###,,)"===s.format?this.customPivotFormat(parseInt(o,10)):o,s.useGrouping&&(o=this.groupNumbers(o,s.groupData.primary,s.groupSeparator||",",i.numberMapper.numberSymbols[tf[3]]||".",s.groupData.secondary)),o=Hr.convertValueParts(o,ut.latnParseRegex,i.numberMapper.mapper),"N/A"===s.nlead?s.nlead:"0"===o&&r&&"0"===r.format?o+s.nend:s.nlead+o+s.nend}},n.processSignificantDigits=function(t,e,i){var r=t+"";return r.lengthe;)c=l.slice(h-e,h)+(c.length?i+c:""),h-=e,o&&(e=s,o=!1);return a[0]=l.slice(0,h)+(c.length?i:"")+c,a.join(r)},n.processFraction=function(t,e,i,r){var s=(t+"").split(".")[1],o=s?s.length:0;if(e&&oi||0===i))return t.toFixed(i);var h=t+"";return"0"===h[0]&&r&&"###.00"===r.format&&(h=h.slice(1)),h},n.processMinimumIntegers=function(t,e){var i=t.split("."),r=i[0],s=r.length;if(s=5e5){var r=(t/=1e6).toString().split(".")[1];return r&&+r.substring(0,1)>=5?Math.ceil(t).toString():Math.floor(t).toString()}return""},n}(),Tg=(new RegExp("^([^0-9]*)(([0-9,]*[0-9]+)(.[0-9]+)?)([Ee][+-]?[0-9]+)?([^0-9]*)$"),function(){function n(t){this.ranArray=[],this.boundedEvents={},!m(t)&&(this.context=t)}return n.prototype.on=function(t,e,i,r){if(!m(e)){var s=i||this.context;if(this.notExist(t))return void(this.boundedEvents[""+t]=[{handler:e,context:s,id:r}]);m(r)?this.isHandlerPresent(this.boundedEvents[""+t],e)||this.boundedEvents[""+t].push({handler:e,context:s}):-1===this.ranArray.indexOf(r)&&(this.ranArray.push(r),this.boundedEvents[""+t].push({handler:e,context:s,id:r}))}},n.prototype.off=function(t,e,i){if(!this.notExist(t)){var r=Y(t,this.boundedEvents);if(e){for(var s=0;s1&&(U.fractionDigits=parseInt(z[2],10)),U}function p(T,z,U,B){var j=B?{}:{nlead:"",nend:""},Q=T.match(n.customRegex);if(Q){B||(j.nlead=g(Q[1],U),j.nend=g(Q[10],U),j.groupPattern=Q[4]);var oe=Q[7];if(oe&&z){var ue=oe.match(t);j.minimumFraction=m(ue)?0:ue.length,j.maximumFraction=oe.length-1}}return j}function g(T,z){return T?(T=T.replace(n.defaultCurrency,z),""===z?T.trim():T):""}function v(T,z,U,B){return B?"$":Y("currencies."+z+(U?"."+U:".symbol"),T)||Y("currencies."+z+".symbol-alt-narrow",T)||"$"}function S(T,z,U){var B={type:"decimal",minimumFractionDigits:0,maximumFractionDigits:0},j=T.match(n.customRegex);if(m(j)||""===j[5]&&"N/A"!==T)return B.type=void 0,B;B.nlead=j[1],B.nend=j[10];var Q=j[6],oe=!!Q.match(/ $/g),ue=-1!==Q.replace(/ $/g,"").indexOf(" ");B.useGrouping=-1!==Q.indexOf(",")||ue,Q=Q.replace(/,/g,"");var fe=j[7];if(-1!==Q.indexOf("0")&&(B.minimumIntegerDigits=Q.length-Q.indexOf("0")),m(fe)||(B.minimumFractionDigits=fe.lastIndexOf("0"),B.maximumFractionDigits=fe.lastIndexOf("#"),-1===B.minimumFractionDigits&&(B.minimumFractionDigits=0),(-1===B.maximumFractionDigits||B.maximumFractionDigitsQ.lastIndexOf("'"))){B[""+a[parseInt(j.toString(),10)]]=Q.substr(0,oe)+U+Q.substr(oe+1),B[""+a[""+z]]=!0,B.type=B.isCurrency?"currency":"percent";break}}return B}function C(T,z){if(-1!==T.indexOf(",")){var U=T.split(",");T=U[0]+Y("numberMapper.numberSymbols.group",z)+U[1].replace(".",Y("numberMapper.numberSymbols.decimal",z))}else T=T.replace(".",Y("numberMapper.numberSymbols.decimal",z));return T}function A(T,z,U){T+=".";for(var B=0;B0;Q-=3)T=","+U[Q-2]+U[Q-1]+U[parseInt(Q.toString(),10)]+T;return T=T.slice(1),z[1]?T+"."+z[1]:T}n.dateParseRegex=/([a-z])\1*|'([^']|'')+'|''|./gi,n.basicPatterns=["short","medium","long","full"],n.defaultObject={dates:{calendars:{gregorian:{months:{"stand-alone":{abbreviated:{1:"Jan",2:"Feb",3:"Mar",4:"Apr",5:"May",6:"Jun",7:"Jul",8:"Aug",9:"Sep",10:"Oct",11:"Nov",12:"Dec"},narrow:{1:"J",2:"F",3:"M",4:"A",5:"M",6:"J",7:"J",8:"A",9:"S",10:"O",11:"N",12:"D"},wide:{1:"January",2:"February",3:"March",4:"April",5:"May",6:"June",7:"July",8:"August",9:"September",10:"October",11:"November",12:"December"}}},days:{"stand-alone":{abbreviated:{sun:"Sun",mon:"Mon",tue:"Tue",wed:"Wed",thu:"Thu",fri:"Fri",sat:"Sat"},narrow:{sun:"S",mon:"M",tue:"T",wed:"W",thu:"T",fri:"F",sat:"S"},short:{sun:"Su",mon:"Mo",tue:"Tu",wed:"We",thu:"Th",fri:"Fr",sat:"Sa"},wide:{sun:"Sunday",mon:"Monday",tue:"Tuesday",wed:"Wednesday",thu:"Thursday",fri:"Friday",sat:"Saturday"}}},dayPeriods:{format:{wide:{am:"AM",pm:"PM"}}},eras:{eraNames:{0:"Before Christ","0-alt-variant":"Before Common Era",1:"Anno Domini","1-alt-variant":"Common Era"},eraAbbr:{0:"BC","0-alt-variant":"BCE",1:"AD","1-alt-variant":"CE"},eraNarrow:{0:"B","0-alt-variant":"BCE",1:"A","1-alt-variant":"CE"}},dateFormats:{full:"EEEE, MMMM d, y",long:"MMMM d, y",medium:"MMM d, y",short:"M/d/yy"},timeFormats:{full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},dateTimeFormats:{full:"{1} 'at' {0}",long:"{1} 'at' {0}",medium:"{1}, {0}",short:"{1}, {0}",availableFormats:{d:"d",E:"ccc",Ed:"d E",Ehm:"E h:mm a",EHm:"E HH:mm",Ehms:"E h:mm:ss a",EHms:"E HH:mm:ss",Gy:"y G",GyMMM:"MMM y G",GyMMMd:"MMM d, y G",GyMMMEd:"E, MMM d, y G",h:"h a",H:"HH",hm:"h:mm a",Hm:"HH:mm",hms:"h:mm:ss a",Hms:"HH:mm:ss",hmsv:"h:mm:ss a v",Hmsv:"HH:mm:ss v",hmv:"h:mm a v",Hmv:"HH:mm v",M:"L",Md:"M/d",MEd:"E, M/d",MMM:"LLL",MMMd:"MMM d",MMMEd:"E, MMM d",MMMMd:"MMMM d",ms:"mm:ss",y:"y",yM:"M/y",yMd:"M/d/y",yMEd:"E, M/d/y",yMMM:"MMM y",yMMMd:"MMM d, y",yMMMEd:"E, MMM d, y",yMMMM:"MMMM y"}}},islamic:{months:{"stand-alone":{abbreviated:{1:"Muh.",2:"Saf.",3:"Rab. I",4:"Rab. II",5:"Jum. I",6:"Jum. II",7:"Raj.",8:"Sha.",9:"Ram.",10:"Shaw.",11:"Dhu\u02bbl-Q.",12:"Dhu\u02bbl-H."},narrow:{1:"1",2:"2",3:"3",4:"4",5:"5",6:"6",7:"7",8:"8",9:"9",10:"10",11:"11",12:"12"},wide:{1:"Muharram",2:"Safar",3:"Rabi\u02bb I",4:"Rabi\u02bb II",5:"Jumada I",6:"Jumada II",7:"Rajab",8:"Sha\u02bbban",9:"Ramadan",10:"Shawwal",11:"Dhu\u02bbl-Qi\u02bbdah",12:"Dhu\u02bbl-Hijjah"}}},days:{"stand-alone":{abbreviated:{sun:"Sun",mon:"Mon",tue:"Tue",wed:"Wed",thu:"Thu",fri:"Fri",sat:"Sat"},narrow:{sun:"S",mon:"M",tue:"T",wed:"W",thu:"T",fri:"F",sat:"S"},short:{sun:"Su",mon:"Mo",tue:"Tu",wed:"We",thu:"Th",fri:"Fr",sat:"Sa"},wide:{sun:"Sunday",mon:"Monday",tue:"Tuesday",wed:"Wednesday",thu:"Thursday",fri:"Friday",sat:"Saturday"}}},dayPeriods:{format:{wide:{am:"AM",pm:"PM"}}},eras:{eraNames:{0:"AH"},eraAbbr:{0:"AH"},eraNarrow:{0:"AH"}},dateFormats:{full:"EEEE, MMMM d, y G",long:"MMMM d, y G",medium:"MMM d, y G",short:"M/d/y GGGGG"},timeFormats:{full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},dateTimeFormats:{full:"{1} 'at' {0}",long:"{1} 'at' {0}",medium:"{1}, {0}",short:"{1}, {0}",availableFormats:{d:"d",E:"ccc",Ed:"d E",Ehm:"E h:mm a",EHm:"E HH:mm",Ehms:"E h:mm:ss a",EHms:"E HH:mm:ss",Gy:"y G",GyMMM:"MMM y G",GyMMMd:"MMM d, y G",GyMMMEd:"E, MMM d, y G",h:"h a",H:"HH",hm:"h:mm a",Hm:"HH:mm",hms:"h:mm:ss a",Hms:"HH:mm:ss",M:"L",Md:"M/d",MEd:"E, M/d",MMM:"LLL",MMMd:"MMM d",MMMEd:"E, MMM d",MMMMd:"MMMM d",ms:"mm:ss",y:"y G",yyyy:"y G",yyyyM:"M/y GGGGG",yyyyMd:"M/d/y GGGGG",yyyyMEd:"E, M/d/y GGGGG",yyyyMMM:"MMM y G",yyyyMMMd:"MMM d, y G",yyyyMMMEd:"E, MMM d, y G",yyyyMMMM:"MMMM y G",yyyyQQQ:"QQQ y G",yyyyQQQQ:"QQQQ y G"}}}},timeZoneNames:{hourFormat:"+HH:mm;-HH:mm",gmtFormat:"GMT{0}",gmtZeroFormat:"GMT"}},numbers:{currencies:{USD:{displayName:"US Dollar",symbol:"$","symbol-alt-narrow":"$"},EUR:{displayName:"Euro",symbol:"\u20ac","symbol-alt-narrow":"\u20ac"},GBP:{displayName:"British Pound","symbol-alt-narrow":"\xa3"}},defaultNumberingSystem:"latn",minimumGroupingDigits:"1","symbols-numberSystem-latn":{decimal:".",group:",",list:";",percentSign:"%",plusSign:"+",minusSign:"-",exponential:"E",superscriptingExponent:"\xd7",perMille:"\u2030",infinity:"\u221e",nan:"NaN",timeSeparator:":"},"decimalFormats-numberSystem-latn":{standard:"#,##0.###"},"percentFormats-numberSystem-latn":{standard:"#,##0%"},"currencyFormats-numberSystem-latn":{standard:"\xa4#,##0.00",accounting:"\xa4#,##0.00;(\xa4#,##0.00)"},"scientificFormats-numberSystem-latn":{standard:"#E0"}}},n.blazorDefaultObject={numbers:{mapper:{0:"0",1:"1",2:"2",3:"3",4:"4",5:"5",6:"6",7:"7",8:"8",9:"9"},mapperDigits:"0123456789",numberSymbols:{decimal:".",group:",",plusSign:"+",minusSign:"-",percentSign:"%",nan:"NaN",timeSeparator:":",infinity:"\u221e"},timeSeparator:":",currencySymbol:"$",currencypData:{nlead:"$",nend:"",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},percentpData:{nlead:"",nend:"%",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},percentnData:{nlead:"-",nend:"%",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},currencynData:{nlead:"($",nend:")",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},decimalnData:{nlead:"-",nend:"",groupData:{primary:3},maximumFraction:2,minimumFraction:2},decimalpData:{nlead:"",nend:"",groupData:{primary:3},maximumFraction:2,minimumFraction:2}},dates:{dayPeriods:{am:"AM",pm:"PM"},dateSeperator:"/",days:{abbreviated:{sun:"Sun",mon:"Mon",tue:"Tue",wed:"Wed",thu:"Thu",fri:"Fri",sat:"Sat"},short:{sun:"Su",mon:"Mo",tue:"Tu",wed:"We",thu:"Th",fri:"Fr",sat:"Sa"},wide:{sun:"Sunday",mon:"Monday",tue:"Tuesday",wed:"Wednesday",thu:"Thursday",fri:"Friday",sat:"Saturday"}},months:{abbreviated:{1:"Jan",2:"Feb",3:"Mar",4:"Apr",5:"May",6:"Jun",7:"Jul",8:"Aug",9:"Sep",10:"Oct",11:"Nov",12:"Dec"},wide:{1:"January",2:"February",3:"March",4:"April",5:"May",6:"June",7:"July",8:"August",9:"September",10:"October",11:"November",12:"December"}},eras:{1:"AD"}}},n.monthIndex={3:"abbreviated",4:"wide",5:"narrow",1:"abbreviated"},n.month="months",n.days="days",n.patternMatcher={C:"currency",P:"percent",N:"decimal",A:"currency",E:"scientific"},n.getResultantPattern=l,n.getDependables=h,n.getSymbolPattern=c,n.ConvertDateToWeekFormat=d,n.compareBlazorDateFormats=u,n.getProperNumericSkeleton=f,n.getFormatData=p,n.changeCurrencySymbol=g,n.getCurrencySymbol=v,n.customFormat=function y(T,z,U){for(var B={},j=T.split(";"),Q=["pData","nData","zeroData"],oe=0;oe1,fe.nData=ce()?Y(De.type+"nData",oe):p(ot[1]||"-"+ot[0],!0,Ie),fe.pData=ce()?Y(De.type+"pData",oe):p(ot[0],!1,Ie),!Me[2]&&!z.minimumFractionDigits&&!z.maximumFractionDigits&&(ue=p(Ve.split(";")[0],!0,"",!0).minimumFraction)}if(n.formatRegex.test(z.format)||!z.format){if(ze(Q,f(z.format||"N")),Q.custom=!1,$e="###0",(Q.fractionDigits||z.minimumFractionDigits||z.maximumFractionDigits||ue)&&(Q.fractionDigits&&(z.minimumFractionDigits=z.maximumFractionDigits=Q.fractionDigits),$e=A($e,ue||Q.fractionDigits||z.minimumFractionDigits||0,z.maximumFractionDigits||0)),z.minimumIntegerDigits&&($e=x($e,z.minimumIntegerDigits)),z.useGrouping&&($e=P($e)),"currency"===Q.type||Q.type&&ce()){ce()&&"currency"!==Q.type&&(fe.pData=Y(Q.type+"pData",oe),fe.nData=Y(Q.type+"nData",oe));var hr=$e;$e=fe.pData.nlead+hr+fe.pData.nend,(fe.hasNegativePattern||ce())&&($e+=";"+fe.nData.nlead+hr+fe.nData.nend)}"percent"===Q.type&&!ce()&&($e+=" %")}else $e=z.format.replace(/'/g,'"');return Object.keys(xe).length>0&&($e=B?$e:C($e,xe)),$e},n.fractionDigitsPattern=A,n.minimumIntegerPattern=x,n.groupingPattern=P,n.getWeekData=function L(T,z){var U="sun",B=Y("supplemental.weekData.firstDay",z),j=T;return/en-/.test(j)&&(j=j.slice(3)),j=j.slice(0,2).toUpperCase()+j.substr(2),B&&(U=B[""+j]||B[j.slice(0,2)]||"sun"),o[""+U]},n.replaceBlazorCurrency=function O(T,z,U){var B=function d$(n){return Y(n||"",c$)}(U);if(z!==B)for(var j=0,Q=T;j=0?U:U+7;var j=Math.floor((T.getTime()-z.getTime()-6e4*(T.getTimezoneOffset()-z.getTimezoneOffset()))/864e5)+1;if(U<4){if((B=Math.floor((j+U-1)/7)+1)>52){var oe=new Date(T.getFullYear()+1,0,1).getDay();B=(oe=oe>=0?oe:oe+7)<4?1:53}}else B=Math.floor((j+U-1)/7);return B}}(ut||(ut={}));var rf=function(){function n(t,e,i){this.type="GET",this.emitError=!0,"string"==typeof t?(this.url=t,this.type=m(e)?this.type:e.toUpperCase(),this.contentType=i):La(t)&&Object.keys(t).length>0&&kn(this,t),this.contentType=m(this.contentType)?"application/json; charset=utf-8":this.contentType}return n.prototype.send=function(t){var e=this,i={"application/json":"json","multipart/form-data":"formData","application/octet-stream":"blob","application/x-www-form-urlencoded":"formData"};try{m(this.fetchRequest)&&"GET"===this.type?this.fetchRequest=new Request(this.url,{method:this.type}):m(this.fetchRequest)&&(this.data=m(t)?this.data:t,this.fetchRequest=new Request(this.url,{method:this.type,headers:{"Content-Type":this.contentType},body:this.data}));var r={cancel:!1,fetchRequest:this.fetchRequest};return this.triggerEvent(this.beforeSend,r),r.cancel?null:(this.fetchResponse=fetch(this.fetchRequest),this.fetchResponse.then(function(s){if(e.triggerEvent(e.onLoad,s),!s.ok)throw s;for(var o="text",a=0,l=Object.keys(i);a-1},n.getValue=function(t,e){var i=typeof window<"u"?window.browserDetails:{};return typeof navigator<"u"&&"MacIntel"===navigator.platform&&navigator.maxTouchPoints>1&&!0===n.isTouch&&!gC.CHROME.test(navigator.userAgent)&&(i.isIos=!0,i.isDevice=!0,i.isTouch=!0,i.isPointer=!0,i.isPointer="pointerEnabled"in window.navigator),typeof window<"u"&&window.Capacitor&&"ios"===window.Capacitor.getPlatform()&&(i.isPointer=!1),typeof i[""+t]>"u"?i[""+t]=e.test(n.userAgent):i[""+t]},Object.defineProperty(n,"userAgent",{get:function(){return n.uA},set:function(t){n.uA=t,window.browserDetails={}},enumerable:!0,configurable:!0}),Object.defineProperty(n,"info",{get:function(){return st(window.browserDetails.info)?window.browserDetails.info=n.extractBrowserDetail():window.browserDetails.info},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isIE",{get:function(){return n.getValue("isIE",x$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isTouch",{get:function(){return st(window.browserDetails.isTouch)?window.browserDetails.isTouch="ontouchstart"in window.navigator||window&&window.navigator&&window.navigator.maxTouchPoints>0||"ontouchstart"in window:window.browserDetails.isTouch},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isPointer",{get:function(){return st(window.browserDetails.isPointer)?window.browserDetails.isPointer="pointerEnabled"in window.navigator:window.browserDetails.isPointer},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isMSPointer",{get:function(){return st(window.browserDetails.isMSPointer)?window.browserDetails.isMSPointer="msPointerEnabled"in window.navigator:window.browserDetails.isMSPointer},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isDevice",{get:function(){return n.getValue("isDevice",D$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isIos",{get:function(){return n.getValue("isIos",A$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isIos7",{get:function(){return n.getValue("isIos7",L$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isAndroid",{get:function(){return n.getValue("isAndroid",N$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isWebView",{get:function(){return st(window.browserDetails.isWebView)&&(window.browserDetails.isWebView=!(st(window.cordova)&&st(window.PhoneGap)&&st(window.phonegap)&&"object"!==window.forge)),window.browserDetails.isWebView},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isWindows",{get:function(){return n.getValue("isWindows",O$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"touchStartEvent",{get:function(){return st(window.browserDetails.touchStartEvent)?window.browserDetails.touchStartEvent=n.getTouchStartEvent():window.browserDetails.touchStartEvent},enumerable:!0,configurable:!0}),Object.defineProperty(n,"touchMoveEvent",{get:function(){return st(window.browserDetails.touchMoveEvent)?window.browserDetails.touchMoveEvent=n.getTouchMoveEvent():window.browserDetails.touchMoveEvent},enumerable:!0,configurable:!0}),Object.defineProperty(n,"touchEndEvent",{get:function(){return st(window.browserDetails.touchEndEvent)?window.browserDetails.touchEndEvent=n.getTouchEndEvent():window.browserDetails.touchEndEvent},enumerable:!0,configurable:!0}),Object.defineProperty(n,"touchCancelEvent",{get:function(){return st(window.browserDetails.touchCancelEvent)?window.browserDetails.touchCancelEvent=n.getTouchCancelEvent():window.browserDetails.touchCancelEvent},enumerable:!0,configurable:!0}),n.uA=typeof navigator<"u"?navigator.userAgent:"",n}(),E=function(){function n(){}return n.addOrGetEventData=function(t){return"__eventList"in t?t.__eventList.events:(t.__eventList={},t.__eventList.events=[])},n.add=function(t,e,i,r,s){var a,o=n.addOrGetEventData(t);a=s?function o$(n,t){var e;return function(){for(var i=this,r=[],s=0;s"u"||(e.innerHTML=t.innerHTML?t.innerHTML:"",void 0!==t.className&&(e.className=t.className),void 0!==t.id&&(e.id=t.id),void 0!==t.styles&&e.setAttribute("style",t.styles),void 0!==t.attrs&&Fe(e,t.attrs)),e}function V(n,t){for(var e=Vz(t),i=RegExp,r=0,s=n;r0}function gl(n,t,e){for(var i=document.createDocumentFragment(),r=0,s=n;r0;)i.appendChild(n[0]);else for(var r=0,s=n;r-1&&!r[parseInt(s.toString(),10)].match(/\[.*\]/)){var o=r[parseInt(s.toString(),10)].split("#");if(o[1].match(/^\d/)||o[1].match(t)){var a=r[parseInt(s.toString(),10)].split(".");a[0]=a[0].replace(/#/,"[id='")+"']",r[parseInt(s.toString(),10)]=a.join(".")}}e[parseInt(i.toString(),10)]=r.join(" ")}return e.join(",")}return n}function J(n,t){var e=n;if("function"==typeof e.closest)return e.closest(t);for(;e&&1===e.nodeType;){if(vC(e,t))return e;e=e.parentNode}return null}function je(n,t){void 0!==t&&Object.keys(t).forEach(function(e){n.style[""+e]=t[""+e]})}function vC(n,t){var e=n.matches||n.msMatchesSelector||n.webkitMatchesSelector;return e?e.call(n,t):-1!==[].indexOf.call(document.querySelectorAll(t),n)}var z$=new RegExp("]"),dh=function(){function n(t,e){this.isRendered=!1,this.isComplexArraySetter=!1,this.isServerRendered=!1,this.allowServerDataBinding=!0,this.isProtectedOnChange=!0,this.properties={},this.changedProperties={},this.oldProperties={},this.bulkChanges={},this.refreshing=!1,this.ignoreCollectionWatch=!1,this.finalUpdate=function(){},this.childChangedProperties={},this.modelObserver=new Tg(this),st(e)||(this.element="string"==typeof e?document.querySelector(e):e,m(this.element)||(this.isProtectedOnChange=!1,this.addInstance())),st(t)||this.setProperties(t,!0),this.isDestroyed=!1}return n.prototype.setProperties=function(t,e){var i=this.isProtectedOnChange;this.isProtectedOnChange=!!e,kn(this,t),!0!==e?(kn(this.changedProperties,t),this.dataBind()):ce()&&this.isRendered&&this.serverDataBind(t),this.finalUpdate(),this.changedProperties={},this.oldProperties={},this.isProtectedOnChange=i},n.callChildDataBind=function(t,e){for(var r=0,s=Object.keys(t);r=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Hs=function(n){function t(i){var r=n.call(this,i,void 0)||this;return r.easing={ease:"cubic-bezier(0.250, 0.100, 0.250, 1.000)",linear:"cubic-bezier(0.250, 0.250, 0.750, 0.750)",easeIn:"cubic-bezier(0.420, 0.000, 1.000, 1.000)",easeOut:"cubic-bezier(0.000, 0.000, 0.580, 1.000)",easeInOut:"cubic-bezier(0.420, 0.000, 0.580, 1.000)",elasticInOut:"cubic-bezier(0.5,-0.58,0.38,1.81)",elasticIn:"cubic-bezier(0.17,0.67,0.59,1.81)",elasticOut:"cubic-bezier(0.7,-0.75,0.99,1.01)"},r}var e;return Q$(t,n),e=t,t.prototype.animate=function(i,r){var s=this.getModel(r=r||{});if("string"==typeof i)for(var a=0,l=Array.prototype.slice.call(we(i,document));a0?r-1:0,i+=e=-1!==e?"-"+e:"-"+r}return this.controlParent!==this.parentObj&&(i=this.parentObj.getParentKey()+"."+this.propName+e),i},n}(),$$=["grid","pivotview","treegrid","spreadsheet","rangeNavigator","DocumentEditor","listbox","inplaceeditor","PdfViewer","richtexteditor","DashboardLayout","chart","stockChart","circulargauge","diagram","heatmap","lineargauge","maps","slider","smithchart","barcode","sparkline","treemap","bulletChart","kanban","daterangepicker","schedule","gantt","signature","query-builder","drop-down-tree","carousel","filemanager","uploader","accordion","tab","treeview"],tR=[115,121,110,99,102,117,115,105,111,110,46,105,115,76,105,99,86,97,108,105,100,97,116,101,100],iR=function(){function n(t){this.isValidated=!1,this.isLicensed=!0,this.version="27",this.platform=/JavaScript|ASPNET|ASPNETCORE|ASPNETMVC|FileFormats|essentialstudio/i,this.errors={noLicense:"This application was built using a trial version of Syncfusion Essential Studio. To remove the license validation message permanently, a valid license key must be included.",trailExpired:"This application was built using a trial version of Syncfusion Essential Studio. To remove the license validation message permanently, a valid license key must be included.",versionMismatched:"The included Syncfusion license key is invalid.",platformMismatched:"The included Syncfusion license key is invalid.",invalidKey:"The included Syncfusion license key is invalid."},this.manager=function(){var e=null;return{setKey:function i(s){e=s},getKey:function r(){return e}}}(),this.npxManager=function(){return{getKey:function i(){return"npxKeyReplace"}}}(),this.manager.setKey(t)}return n.prototype.validate=function(){if(!this.isValidated&&ef&&!Y(D0(tR),ef)&&!Y("Blazor",ef)){var i=void 0,r=void 0;if(this.manager&&this.manager.getKey()||this.npxManager&&"npxKeyReplace"!==this.npxManager.getKey()){var s=this.getInfoFromKey();if(s&&s.length)for(var o=0,a=s;o"+i+' Claim your FREE account\n
have a Syncfusion account? Sign In
\n
\n ';if(typeof document<"u"&&!m(document)){var t=Si("div",{innerHTML:n});document.body.appendChild(t)}}(),oR=!0),this.render(),this.mount?this.accessMount():this.trigger("created")}},t.prototype.renderComplete=function(e){ce()&&window.sfBlazor.renderComplete(this.element,e),this.isRendered=!0},t.prototype.dataBind=function(){this.injectModules(),n.prototype.dataBind.call(this)},t.prototype.on=function(e,i,r){if("string"==typeof e)this.localObserver.on(e,i,r);else for(var s=0,o=e;s=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},tZ={left:0,top:0,bottom:0,right:0},bC={isDragged:!1},iZ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return aR(t,n),gr([I(0)],t.prototype,"left",void 0),gr([I(0)],t.prototype,"top",void 0),t}(Ee),of=function(n){function t(i,r){var s=n.call(this,r,i)||this;return s.dragLimit=e.getDefaultPosition(),s.borderWidth=e.getDefaultPosition(),s.padding=e.getDefaultPosition(),s.diffX=0,s.prevLeft=0,s.prevTop=0,s.dragProcessStarted=!1,s.eleTop=0,s.tapHoldTimer=0,s.externalInitialize=!1,s.diffY=0,s.parentScrollX=0,s.parentScrollY=0,s.droppables={},s.bind(),s}var e;return aR(t,n),e=t,t.prototype.bind=function(){this.toggleEvents(),X.isIE&&V([this.element],"e-block-touch"),this.droppables[this.scope]={}},t.getDefaultPosition=function(){return ze({},tZ)},t.prototype.toggleEvents=function(i){var r;st(this.handle)||(r=_(this.handle,this.element));var s=this.enableTapHold&&X.isDevice&&X.isTouch?this.mobileInitialize:this.initialize;i?E.remove(r||this.element,X.isSafari()?"touchstart":X.touchStartEvent,s):E.add(r||this.element,X.isSafari()?"touchstart":X.touchStartEvent,s,this)},t.prototype.mobileInitialize=function(i){var r=this,s=i.currentTarget;this.tapHoldTimer=setTimeout(function(){r.externalInitialize=!0,r.removeTapholdTimer(),r.initialize(i,s)},this.tapHoldThreshold),E.add(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.removeTapholdTimer,this),E.add(document,X.isSafari()?"touchend":X.touchEndEvent,this.removeTapholdTimer,this)},t.prototype.removeTapholdTimer=function(){clearTimeout(this.tapHoldTimer),E.remove(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.removeTapholdTimer),E.remove(document,X.isSafari()?"touchend":X.touchEndEvent,this.removeTapholdTimer)},t.prototype.getScrollableParent=function(i,r){return m(i)?null:i[{vertical:"scrollHeight",horizontal:"scrollWidth"}[""+r]]>i[{vertical:"clientHeight",horizontal:"clientWidth"}[""+r]]&&("vertical"===r?i.scrollTop>0:i.scrollLeft>0)?("vertical"===r?(this.parentScrollY=this.parentScrollY+(0===this.parentScrollY?i.scrollTop:i.scrollTop-this.parentScrollY),this.tempScrollHeight=i.scrollHeight):(this.parentScrollX=this.parentScrollX+(0===this.parentScrollX?i.scrollLeft:i.scrollLeft-this.parentScrollX),this.tempScrollWidth=i.scrollWidth),m(i)?i:this.getScrollableParent(i.parentNode,r)):this.getScrollableParent(i.parentNode,r)},t.prototype.getScrollableValues=function(){this.parentScrollX=0,this.parentScrollY=0,this.element.classList.contains("e-dialog")&&this.element.classList.contains("e-dlg-modal"),this.getScrollableParent(this.element.parentNode,"vertical"),this.getScrollableParent(this.element.parentNode,"horizontal")},t.prototype.initialize=function(i,r){if(this.currentStateTarget=i.target,!this.isDragStarted()){if(this.isDragStarted(!0),this.externalInitialize=!1,this.target=i.currentTarget||r,this.dragProcessStarted=!1,this.abort){var s=this.abort;"string"==typeof s&&(s=[s]);for(var o=0;o=this.distance||this.externalInitialize){var f=this.getHelperElement(i);if(!f||m(f))return;r&&i.preventDefault();var p=this.helperElement=f;if(this.parentClientRect=this.calculateParentPosition(p.offsetParent),this.dragStart){var v={event:i,element:l,target:this.getProperTargetElement(i),bindEvents:ce()?this.bindDragEvents.bind(this):null,dragElement:p};this.trigger("dragStart",v)}this.dragArea?this.setDragArea():(this.dragLimit={left:0,right:0,bottom:0,top:0},this.borderWidth={top:0,left:0}),o={left:this.position.left-this.parentClientRect.left,top:this.position.top-this.parentClientRect.top},this.clone&&!this.enableTailMode&&(this.diffX=this.position.left-this.offset.left,this.diffY=this.position.top-this.offset.top),this.getScrollableValues();var y=getComputedStyle(l),S=parseFloat(y.marginTop);this.clone&&0!==S&&(o.top+=S),this.eleTop=isNaN(parseFloat(y.top))?0:parseFloat(y.top)-this.offset.top,this.enableScrollHandler&&!this.clone&&(o.top-=this.parentScrollY,o.left-=this.parentScrollX);var b=this.getProcessedPositionValue({top:o.top-this.diffY+"px",left:o.left-this.diffX+"px"});this.dragArea&&"string"!=typeof this.dragArea&&this.dragArea.classList.contains("e-kanban-content")&&"relative"===this.dragArea.style.position&&(o.top+=this.dragArea.scrollTop),this.dragElePosition={top:o.top,left:o.left},je(p,this.getDragPosition({position:"absolute",left:b.left,top:b.top})),E.remove(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.intDragStart),E.remove(document,X.isSafari()?"touchend":X.touchEndEvent,this.intDestroy),ce()||this.bindDragEvents(p)}}},t.prototype.bindDragEvents=function(i){Tr(i)?(E.add(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.intDrag,this),E.add(document,X.isSafari()?"touchend":X.touchEndEvent,this.intDragStop,this),this.setGlobalDroppables(!1,this.element,i)):(this.toggleEvents(),document.body.classList.remove("e-prevent-select"))},t.prototype.elementInViewport=function(i){for(this.top=i.offsetTop,this.left=i.offsetLeft,this.width=i.offsetWidth,this.height=i.offsetHeight;i.offsetParent;)this.top+=(i=i.offsetParent).offsetTop,this.left+=i.offsetLeft;return this.top>=window.pageYOffset&&this.left>=window.pageXOffset&&this.top+this.height<=window.pageYOffset+window.innerHeight&&this.left+this.width<=window.pageXOffset+window.innerWidth},t.prototype.getProcessedPositionValue=function(i){return this.queryPositionInfo?this.queryPositionInfo(i):i},t.prototype.calculateParentPosition=function(i){if(m(i))return{left:0,top:0};var r=i.getBoundingClientRect(),s=getComputedStyle(i);return{left:r.left+window.pageXOffset-parseInt(s.marginLeft,10),top:r.top+window.pageYOffset-parseInt(s.marginTop,10)}},t.prototype.intDrag=function(i){if(st(i.changedTouches)||1===i.changedTouches.length){var r,s;this.clone&&i.changedTouches&&X.isDevice&&X.isTouch&&i.preventDefault(),this.position=this.getMousePosition(i,this.isDragScroll);var o=this.getDocumentWidthHeight("Height");oy&&y>0?this.dragLimit.left:this.dragLimit.right+window.pageXOffset0?y-(y-this.dragLimit.right)+window.pageXOffset-M:y<0?this.dragLimit.left:y}if(this.pageY!==v||this.skipDistanceCheck){var w=d.offsetHeight+(parseFloat(b.marginTop)+parseFloat(b.marginBottom));s=this.dragLimit.top>S&&S>0?this.dragLimit.top:this.dragLimit.bottom+window.pageYOffset0?S-(S-this.dragLimit.bottom)+window.pageYOffset-w:S<0?this.dragLimit.top:S}}else r=y,s=S;var A,x,C=f+this.borderWidth.top,D=u+this.borderWidth.left;if(this.dragProcessStarted&&(m(s)&&(s=this.prevTop),m(r)&&(r=this.prevLeft)),this.helperElement.classList.contains("e-treeview"))this.dragArea?(this.dragLimit.top=this.clone?this.dragLimit.top:0,A=s-C<0?this.dragLimit.top:s-this.borderWidth.top,x=r-D<0?this.dragLimit.left:r-this.borderWidth.left):(A=s-this.borderWidth.top,x=r-this.borderWidth.left);else if(this.dragArea){var P=this.helperElement.classList.contains("e-dialog");this.dragLimit.top=this.clone?this.dragLimit.top:0,A=s-C<0?this.dragLimit.top:s-C,x=r-D<0?P?r-(D-this.borderWidth.left):this.dragElePosition.left:r-D}else A=s-C,x=r-D;var L=parseFloat(getComputedStyle(this.element).marginTop);if(L>0&&(this.clone&&(A+=L,S<0&&(L+S>=0?A=L+S:A-=L),this.dragArea&&(A=this.dragLimit.bottom=0){var O=this.dragLimit.top+S-C;O+L+C<0?A-=L+C:A=O}else A-=L+C;this.dragArea&&this.helperElement.classList.contains("e-treeview")&&(A=A+(w=d.offsetHeight+(parseFloat(b.marginTop)+parseFloat(b.marginBottom)))>this.dragLimit.bottom?this.dragLimit.bottom-w:A),this.enableScrollHandler&&!this.clone&&(A-=this.parentScrollY,x-=this.parentScrollX),this.dragArea&&"string"!=typeof this.dragArea&&this.dragArea.classList.contains("e-kanban-content")&&"relative"===this.dragArea.style.position&&(A+=this.dragArea.scrollTop);var N=this.getProcessedPositionValue({top:A+"px",left:x+"px"});this.isPreventScroll&&(N=this.getProcessedPositionValue({top:this.position.top-this.parentClientRect.top-2+"px",left:this.position.left-this.parentClientRect.left-2+"px"})),je(d,this.getDragPosition(N)),!this.elementInViewport(d)&&this.enableAutoScroll&&!this.helperElement.classList.contains("e-treeview")&&this.helperElement.scrollIntoView();var T=document.querySelectorAll(":hover");if(this.enableAutoScroll&&this.helperElement.classList.contains("e-treeview")){0===T.length&&(T=this.getPathElements(i));var z=this.getScrollParent(T,!1);this.elementInViewport(this.helperElement)?this.getScrollPosition(z,A):this.elementInViewport(this.helperElement)||(0===(T=[].slice.call(document.querySelectorAll(":hover"))).length&&(T=this.getPathElements(i)),z=this.getScrollParent(T,!0),this.getScrollPosition(z,A))}this.dragProcessStarted=!0,this.prevLeft=r,this.prevTop=s,this.position.left=r,this.position.top=s,this.pageX=g,this.pageY=v}},t.prototype.getScrollParent=function(i,r){for(var o,s=r?i.reverse():i,a=s.length-1;a>=0;a--)if(("auto"===(o=window.getComputedStyle(s[parseInt(a.toString(),10)])["overflow-y"])||"scroll"===o)&&s[parseInt(a.toString(),10)].scrollHeight>s[parseInt(a.toString(),10)].clientHeight)return s[parseInt(a.toString(),10)];if("visible"===(o=window.getComputedStyle(document.scrollingElement)["overflow-y"]))return document.scrollingElement.style.overflow="auto",document.scrollingElement},t.prototype.getScrollPosition=function(i,r){if(i&&i===document.scrollingElement)i.clientHeight+document.scrollingElement.scrollTop-this.helperElement.clientHeightr?i.scrollTop+=this.helperElement.clientHeight:i.scrollTop>r-this.helperElement.clientHeight&&(i.scrollTop-=this.helperElement.clientHeight);else if(i&&i!==document.scrollingElement){var s=document.scrollingElement.scrollTop,o=this.helperElement.clientHeight;i.clientHeight+i.getBoundingClientRect().top-o+sr-o-s&&(i.scrollTop-=this.helperElement.clientHeight)}},t.prototype.getPathElements=function(i){return document.elementsFromPoint(i.clientX>0?i.clientX:0,i.clientY>0?i.clientY:0)},t.prototype.triggerOutFunction=function(i,r){this.hoverObject.instance.intOut(i,r.target),this.hoverObject.instance.dragData[this.scope]=null,this.hoverObject=null},t.prototype.getDragPosition=function(i){var r=ze({},i);return this.axis&&("x"===this.axis?delete r.top:"y"===this.axis&&delete r.left),r},t.prototype.getDocumentWidthHeight=function(i){var r=document.body,s=document.documentElement;return Math.max(r["scroll"+i],s["scroll"+i],r["offset"+i],s["offset"+i],s["client"+i])},t.prototype.intDragStop=function(i){if(this.dragProcessStarted=!1,st(i.changedTouches)||1===i.changedTouches.length){if(-1!==["touchend","pointerup","mouseup"].indexOf(i.type)){if(this.dragStop){var s=this.getProperTargetElement(i);this.trigger("dragStop",{event:i,element:this.element,target:s,helper:this.helperElement})}this.intDestroy(i)}else this.element.setAttribute("aria-grabbed","false");var o=this.checkTargetElement(i);o.target&&o.instance&&(o.instance.dragStopCalled=!0,o.instance.dragData[this.scope]=this.droppables[this.scope],o.instance.intDrop(i,o.target)),this.setGlobalDroppables(!0),document.body.classList.remove("e-prevent-select")}},t.prototype.intDestroy=function(i){this.dragProcessStarted=!1,this.toggleEvents(),document.body.classList.remove("e-prevent-select"),this.element.setAttribute("aria-grabbed","false"),E.remove(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.intDragStart),E.remove(document,X.isSafari()?"touchend":X.touchEndEvent,this.intDragStop),E.remove(document,X.isSafari()?"touchend":X.touchEndEvent,this.intDestroy),E.remove(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.intDrag),this.isDragStarted()&&this.isDragStarted(!0)},t.prototype.onPropertyChanged=function(i,r){},t.prototype.getModuleName=function(){return"draggable"},t.prototype.isDragStarted=function(i){return i&&(bC.isDragged=!bC.isDragged),bC.isDragged},t.prototype.setDragArea=function(){var i,r,a,s=0,o=0;if(a="string"==typeof this.dragArea?_(this.dragArea):this.dragArea){var h=a.getBoundingClientRect();i=a.scrollWidth?a.scrollWidth:h.right-h.left,r=a.scrollHeight?this.dragArea&&!m(this.helperElement)&&this.helperElement.classList.contains("e-treeview")?a.clientHeight:a.scrollHeight:h.bottom-h.top;for(var c=["Top","Left","Bottom","Right"],d=getComputedStyle(a),u=0;u12;return M0(i.target,this.helperElement)||-1!==i.type.indexOf("touch")||a?(this.helperElement.style.pointerEvents="none",s=document.elementFromPoint(r.clientX,r.clientY),this.helperElement.style.pointerEvents=o):s=i.target,s},t.prototype.currentStateCheck=function(i,r){return m(this.currentStateTarget)||this.currentStateTarget===i?m(r)?i:r:this.currentStateTarget},t.prototype.getMousePosition=function(i,r){var a,l,s=void 0!==i.srcElement?i.srcElement:i.target,o=this.getCoordinates(i),h=m(s.offsetParent);if(r?(a=this.clone?o.pageX:o.pageX+(h?0:s.offsetParent.scrollLeft)-this.relativeXPosition,l=this.clone?o.pageY:o.pageY+(h?0:s.offsetParent.scrollTop)-this.relativeYPosition):(a=this.clone?o.pageX:o.pageX+window.pageXOffset-this.relativeXPosition,l=this.clone?o.pageY:o.pageY+window.pageYOffset-this.relativeYPosition),document.scrollingElement&&!r&&!this.clone){var c=document.scrollingElement;a=c.scrollWidth>0&&c.scrollWidth>c.clientWidth&&c.scrollLeft>0?a-c.scrollLeft:a,l=c.scrollHeight>0&&c.scrollHeight>c.clientHeight&&c.scrollTop>0?l-c.scrollTop:l}return{left:a-(this.margin.left+this.cursorAt.left),top:l-(this.margin.top+this.cursorAt.top)}},t.prototype.getCoordinates=function(i){return i.type.indexOf("touch")>-1?i.changedTouches[0]:i},t.prototype.getHelperElement=function(i){var r;return this.clone?this.helper?r=this.helper({sender:i,element:this.target}):(r=Si("div",{className:"e-drag-helper e-block-touch",innerHTML:"Draggable"}),document.body.appendChild(r)):r=this.element,r},t.prototype.setGlobalDroppables=function(i,r,s){this.droppables[this.scope]=i?null:{draggable:r,helper:s,draggedElement:this.element}},t.prototype.checkTargetElement=function(i){var r=this.getProperTargetElement(i),s=this.getDropInstance(r);if(!s&&r&&!m(r.parentNode)){var o=J(r.parentNode,".e-droppable")||r.parentElement;o&&(s=this.getDropInstance(o))}return{target:r,instance:s}},t.prototype.getDropInstance=function(i){var s,o=i&&i.ej2_instances;if(o)for(var a=0,l=o;a=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},lR=function(n){function t(e,i){var r=n.call(this,i,e)||this;return r.mouseOver=!1,r.dragData={},r.dragStopCalled=!1,r.bind(),r}return rZ(t,n),t.prototype.bind=function(){this.wireEvents()},t.prototype.wireEvents=function(){E.add(this.element,X.isSafari()?"touchend":X.touchEndEvent,this.intDrop,this)},t.prototype.onPropertyChanged=function(e,i){},t.prototype.getModuleName=function(){return"droppable"},t.prototype.intOver=function(e,i){this.mouseOver||(this.trigger("over",{event:e,target:i,dragData:this.dragData[this.scope]}),this.mouseOver=!0)},t.prototype.intOut=function(e,i){this.mouseOver&&(this.trigger("out",{evt:e,target:i}),this.mouseOver=!1)},t.prototype.intDrop=function(e,i){if(this.dragStopCalled){this.dragStopCalled=!1;var a,r=!0,s=this.dragData[this.scope],o=!!s&&s.helper&&Tr(s.helper);o&&(a=this.isDropArea(e,s.helper,i),this.accept&&(r=vC(s.helper,this.accept))),o&&this.drop&&a.canDrop&&r&&this.trigger("drop",{event:e,target:a.target,droppedElement:s.helper,dragData:s}),this.mouseOver=!1}},t.prototype.isDropArea=function(e,i,r){var s={canDrop:!0,target:r||e.target},o="touchend"===e.type;if(o||s.target===i){i.style.display="none";var a=o?e.changedTouches[0]:e,l=document.elementFromPoint(a.clientX,a.clientY);s.canDrop=!1,s.canDrop=M0(l,this.element),s.canDrop&&(s.target=l),i.style.display=""}return s},t.prototype.destroy=function(){E.remove(this.element,X.isSafari()?"touchend":X.touchEndEvent,this.intDrop),n.prototype.destroy.call(this)},af([I()],t.prototype,"accept",void 0),af([I("default")],t.prototype,"scope",void 0),af([H()],t.prototype,"drop",void 0),af([H()],t.prototype,"over",void 0),af([H()],t.prototype,"out",void 0),af([Ft],t)}(dh),uo=function(){function n(t,e,i){this.controlName=t,this.localeStrings=e,this.setLocale(i||"en-US")}return n.prototype.setLocale=function(t){var e=this.intGetControlConstant(n.locale,t);this.currentLocale=e||this.localeStrings},n.load=function(t){this.locale=ze(this.locale,t,{},!0)},n.prototype.getConstant=function(t){return m(this.currentLocale[""+t])?this.localeStrings[""+t]||"":this.currentLocale[""+t]},n.prototype.intGetControlConstant=function(t,e){return t[""+e]?t[""+e][this.controlName]:null},n.locale={},n}(),hR=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),fh=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},oZ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return hR(t,n),fh([I(50)],t.prototype,"swipeThresholdDistance",void 0),t}(Ee),aZ=/(Up|Down)/,Fs=function(n){function t(e,i){var r=n.call(this,i,e)||this;return r.touchAction=!0,r.tapCount=0,r.startEvent=function(s){if(!0===r.touchAction){var o=r.updateChangeTouches(s);void 0!==s.changedTouches&&(r.touchAction=!1),r.isTouchMoved=!1,r.movedDirection="",r.startPoint=r.lastMovedPoint={clientX:o.clientX,clientY:o.clientY},r.startEventData=o,r.hScrollLocked=r.vScrollLocked=!1,r.tStampStart=Date.now(),r.timeOutTapHold=setTimeout(function(){r.tapHoldEvent(s)},r.tapHoldThreshold),E.add(r.element,X.touchMoveEvent,r.moveEvent,r),E.add(r.element,X.touchEndEvent,r.endEvent,r),E.add(r.element,X.touchCancelEvent,r.cancelEvent,r)}},r.moveEvent=function(s){var o=r.updateChangeTouches(s);r.movedPoint=o,r.isTouchMoved=!(o.clientX===r.startPoint.clientX&&o.clientY===r.startPoint.clientY);var a={};r.isTouchMoved&&(clearTimeout(r.timeOutTapHold),r.calcScrollPoints(s),a=ze(a,{},{startEvents:r.startEventData,originalEvent:s,startX:r.startPoint.clientX,startY:r.startPoint.clientY,distanceX:r.distanceX,distanceY:r.distanceY,scrollDirection:r.scrollDirection,velocity:r.getVelocity(o)}),r.trigger("scroll",a),r.lastMovedPoint={clientX:o.clientX,clientY:o.clientY})},r.cancelEvent=function(s){clearTimeout(r.timeOutTapHold),clearTimeout(r.timeOutTap),r.tapCount=0,r.swipeFn(s),E.remove(r.element,X.touchCancelEvent,r.cancelEvent)},r.endEvent=function(s){r.swipeFn(s),r.isTouchMoved||"function"==typeof r.tap&&(r.trigger("tap",{originalEvent:s,tapCount:++r.tapCount}),r.timeOutTap=setTimeout(function(){r.tapCount=0},r.tapThreshold)),r.modeclear()},r.swipeFn=function(s){clearTimeout(r.timeOutTapHold),clearTimeout(r.timeOutTap);var o=r.updateChangeTouches(s),a=o.clientX-r.startPoint.clientX,l=o.clientY-r.startPoint.clientY;a=Math.floor(a<0?-1*a:a),l=Math.floor(l<0?-1*l:a),r.isTouchMoved=a>1||l>1,/Firefox/.test(X.userAgent)&&0===o.clientX&&0===o.clientY&&"mouseup"===s.type&&(r.isTouchMoved=!1),r.endPoint=o,r.calcPoints(s);var c={originalEvent:s,startEvents:r.startEventData,startX:r.startPoint.clientX,startY:r.startPoint.clientY,distanceX:r.distanceX,distanceY:r.distanceY,swipeDirection:r.movedDirection,velocity:r.getVelocity(o)};if(r.isTouchMoved){var d=r.swipeSettings.swipeThresholdDistance,u=ze(void 0,r.defaultArgs,c),f=!1,p=r.element,g=r.isScrollable(p),v=aZ.test(r.movedDirection);(dthis.distanceY?i.clientX>this.startPoint.clientX?"Right":"Left":i.clientYthis.distanceY||!0===this.hScrollLocked)&&!1===this.vScrollLocked?(this.scrollDirection=i.clientX>this.lastMovedPoint.clientX?"Right":"Left",this.hScrollLocked=!0):(this.scrollDirection=i.clientY=e[r[0]+s[0]]},t.prototype.updateChangeTouches=function(e){return e.changedTouches&&0!==e.changedTouches.length?e.changedTouches[0]:e},fh([H()],t.prototype,"tap",void 0),fh([H()],t.prototype,"tapHold",void 0),fh([H()],t.prototype,"swipe",void 0),fh([H()],t.prototype,"scroll",void 0),fh([I(350)],t.prototype,"tapThreshold",void 0),fh([I(750)],t.prototype,"tapHoldThreshold",void 0),fh([re({},oZ)],t.prototype,"swipeSettings",void 0),fh([Ft],t)}(dh),lZ=new RegExp("\\n|\\r|\\s\\s+","g"),hZ=new RegExp(/'|"/g),cZ=new RegExp("if ?\\("),dZ=new RegExp("else if ?\\("),cR=new RegExp("else"),uZ=new RegExp("for ?\\("),dR=new RegExp("(/if|/for)"),fZ=new RegExp("\\((.*)\\)",""),MC=new RegExp("^[0-9]+$","g"),pZ=new RegExp("[\\w\"'.\\s+]+","g"),gZ=new RegExp('"(.*?)"',"g"),vZ=new RegExp("[\\w\"'@#$.\\s-+]+","g"),uR=new RegExp("\\${([^}]*)}","g"),mZ=/^\..*/gm,wC=/\\/gi,yZ=/\\\\/gi,SZ=new RegExp("[\\w\"'@#$.\\s+]+","g"),IZ=/\window\./gm;function lf(n,t,e,i,r){return!t||MC.test(n)||-1!==i.indexOf(n.split(".")[0])||r||"true"===n||"false"===n?n:e+"."+n}function CC(n,t,e,i){return t&&!MC.test(n)&&-1===i.indexOf(n.split(".")[0])?e+'["'+n:n}function fR(n){return n.match(yZ)?n:n.replace(wC,"\\\\")}function pR(n,t,e,i){if(n=n.trim(),/\window\./gm.test(n))return n;var s=/'|"/gm;return/@|\$|#/gm.test(n)&&(n=CC(n,-1===e.indexOf(n),t,e)+'"]'),mZ.test(n)?function wZ(n,t,e,i){return!t||MC.test(n)||-1!==i.indexOf(n.split(".")[0])||/^\..*/gm.test(n)?n:e+"."+n}(n,!s.test(n)&&-1===e.indexOf(n),t,e):lf(n,!s.test(n)&&-1===e.indexOf(n),t,e,i)}var CZ=/^[\n\r.]+0&&t.forEach(function(e){he(e)})},n.removeJsEvents=function(){var t=this.wrapElement.querySelectorAll("["+vR.join("],[")+"]");t.length>0&&t.forEach(function(e){vR.forEach(function(i){e.hasAttribute(i)&&e.removeAttribute(i)})})},n.removeXssAttrs=function(){var t=this;this.removeAttrs.forEach(function(e,i){var r=t.wrapElement.querySelectorAll(e.selector);r.length>0&&r.forEach("a[href]"===e.selector?function(s){-1!==s.getAttribute(e.attribute).replace(/\t|\s|&/,"").indexOf("javascript:alert")&&s.removeAttribute(e.attribute)}:function(s){s.removeAttribute(e.attribute)})})},n}();function NZ(n){for(var t,e=n.childNodes,i=0;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Jo_RTL=(new Tg,"e-rtl"),ys=function(n){function t(e,i){return n.call(this,e,i)||this}return PZ(t,n),t.prototype.preRender=function(){},t.prototype.render=function(){this.initialize(),this.removeRippleEffect=function ms(n,t,e){var i=function G$(n){return{selector:n&&n.selector?n.selector:null,ignore:n&&n.ignore?n.ignore:null,rippleFlag:n&&n.rippleFlag,isCenterRipple:n&&n.isCenterRipple,duration:n&&n.duration?n.duration:350}}(t);return!1===i.rippleFlag||void 0===i.rippleFlag&&!Zo?function(){}:(n.setAttribute("data-ripple","true"),E.add(n,"mousedown",Zz,{parent:n,rippleOptions:i}),E.add(n,"mouseup",Jz,{parent:n,rippleOptions:i,done:e}),E.add(n,"mouseleave",sf,{parent:n,rippleOptions:i}),X.isPointer&&E.add(n,"transitionend",sf,{parent:n,rippleOptions:i}),function(){n.removeAttribute("data-ripple"),E.remove(n,"mousedown",Zz),E.remove(n,"mouseup",Jz),E.remove(n,"mouseleave",sf),E.remove(n,"transitionend",sf)})}(this.element,{selector:".e-btn"}),this.renderComplete()},t.prototype.initialize=function(){if(this.cssClass&&V([this.element],this.cssClass.replace(/\s+/g," ").trim().split(" ")),this.isPrimary&&this.element.classList.add("e-primary"),!ce()||ce()&&"progress-btn"!==this.getModuleName()){if(this.content){var e=this.enableHtmlSanitizer?Ai.sanitize(this.content):this.content;this.element.innerHTML=e}this.setIconCss()}this.enableRtl&&this.element.classList.add(Jo_RTL),this.disabled?this.controlStatus(this.disabled):this.wireEvents()},t.prototype.controlStatus=function(e){this.element.disabled=e},t.prototype.setIconCss=function(){if(this.iconCss){var e=this.createElement("span",{className:"e-btn-icon "+this.iconCss});this.element.textContent.trim()?(e.classList.add("e-icon-"+this.iconPosition.toLowerCase()),("Top"===this.iconPosition||"Bottom"===this.iconPosition)&&this.element.classList.add("e-"+this.iconPosition.toLowerCase()+"-icon-btn")):this.element.classList.add("e-icon-btn");var i=this.element.childNodes[0];!i||"Left"!==this.iconPosition&&"Top"!==this.iconPosition?this.element.appendChild(e):this.element.insertBefore(e,i)}},t.prototype.wireEvents=function(){this.isToggle&&E.add(this.element,"click",this.btnClickHandler,this)},t.prototype.unWireEvents=function(){this.isToggle&&E.remove(this.element,"click",this.btnClickHandler)},t.prototype.btnClickHandler=function(){this.element.classList.contains("e-active")?this.element.classList.remove("e-active"):this.element.classList.add("e-active")},t.prototype.destroy=function(){var e=["e-primary",Jo_RTL,"e-icon-btn","e-success","e-info","e-danger","e-warning","e-flat","e-outline","e-small","e-bigger","e-active","e-round","e-top-icon-btn","e-bottom-icon-btn"];this.cssClass&&(e=e.concat(this.cssClass.split(" "))),n.prototype.destroy.call(this),K([this.element],e),this.element.getAttribute("class")||this.element.removeAttribute("class"),this.disabled&&this.element.removeAttribute("disabled"),this.content&&(this.element.innerHTML=this.element.innerHTML.replace(this.content,""));var i=this.element.querySelector("span.e-btn-icon");i&&he(i),this.unWireEvents(),Zo&&this.removeRippleEffect()},t.prototype.getModuleName=function(){return"btn"},t.prototype.getPersistData=function(){return this.addOnPersist([])},t.Inject=function(){},t.prototype.onPropertyChanged=function(e,i){for(var r=this.element.querySelector("span.e-btn-icon"),s=0,o=Object.keys(e);s=ad.width?ad.width:0;return yl.right+QR()-n}function hE(){return H0()+yl.width/2}function cE(n,t,e,i){if(void 0===t&&(t=null),void 0===e&&(e={X:!1,Y:!1}),!e.Y&&!e.X)return{left:0,top:0};var r=n.getBoundingClientRect();if(po=t,oc=n.ownerDocument,i||(i=ns(n,"left","top")),e.X){var s=po?ZR():i4(),o=gE(),a=vE(),l=o-i.left,h=i.left+r.width-a;r.width>s?i.left=l>0&&h<=0?a-r.width:h>0&&l<=0?o:l>h?a-r.width:o:l>0?i.left+=l:h>0&&(i.left-=h)}if(e.Y){var c=po?JR():t4(),d=pE(),u=mE(),f=d-i.top,p=i.top+r.height-u;r.height>c?i.top=f>0&&p<=0?u-r.height:p>0&&f<=0?d:f>p?u-r.height:d:f>0?i.top+=f:p>0&&(i.top-=p)}return i}function ac(n,t,e,i){void 0===t&&(t=null);var r=ns(n,"left","top");e&&(r.left=e),i&&(r.top=i);var s=[];po=t,oc=n.ownerDocument;var o=n.getBoundingClientRect(),l=r.left,h=r.left+o.width,d=fE(r.top,r.top+o.height),u=XR(l,h);return d.topSide&&s.push("top"),u.rightSide&&s.push("right"),u.leftSide&&s.push("left"),d.bottomSide&&s.push("bottom"),s}function cJ(n,t,e,i,r,s,o,a,l){if(void 0===o&&(o=null),void 0===a&&(a={X:!0,Y:!0}),t&&n&&r&&s&&(a.X||a.Y)){var d,h={TL:null,TR:null,BL:null,BR:null},c={TL:null,TR:null,BL:null,BR:null};if("none"===window.getComputedStyle(n).display){var u=n.style.visibility;n.style.visibility="hidden",n.style.display="block",d=n.getBoundingClientRect(),n.style.removeProperty("display"),n.style.visibility=u}else d=n.getBoundingClientRect();var f={posX:r,posY:s,offsetX:e,offsetY:i,position:{left:0,top:0}};po=o,oc=t.ownerDocument,function uJ(n,t,e,i,r){e.position=ns(n,e.posX,e.posY,i,r),t.TL=ns(n,"left","top",i,r),t.TR=ns(n,"right","top",i,r),t.BR=ns(n,"left","bottom",i,r),t.BL=ns(n,"right","bottom",i,r)}(t,h,f,l,d),uE(c,f,d),a.X&&qR(t,c,h,f,d,!0),a.Y&&h.TL.top>-1&&$R(t,c,h,f,d,!0),function dJ(n,t,e){var i=0,r=0;if(null!=n.offsetParent&&("absolute"===getComputedStyle(n.offsetParent).position||"relative"===getComputedStyle(n.offsetParent).position)){var s=ns(n.offsetParent,"left","top",!1,e);i=s.left,r=s.top}var o=1,a=1,l=GR(n);if(l){var h=getComputedStyle(l).transform;if("none"!==h){var c=new DOMMatrix(h);o=c.a,a=c.d}if("none"!==getComputedStyle(l).zoom){var u=dE(document.body);o*=u,a*=u}}n.style.top=t.position.top/a+t.offsetY-r/a+"px",n.style.left=t.position.left/o+t.offsetX-i/o+"px"}(n,f,d)}}function dE(n){var t=getComputedStyle(n).zoom;return parseFloat(t)||1}function GR(n){for(;n;){var t=window.getComputedStyle(n).transform,e=dE(document.body);if(t&&"none"!==t||e&&1!==e)return n;if(n===document.body)return null;n=n.offsetParent||n.parentElement}return null}function uE(n,t,e){n.TL={top:t.position.top+t.offsetY,left:t.position.left+t.offsetX},n.TR={top:n.TL.top,left:n.TL.left+e.width},n.BL={top:n.TL.top+e.height,left:n.TL.left},n.BR={top:n.TL.top+e.height,left:n.TL.left+e.width}}function XR(n,t){var e=!1,i=!1;return n-F0()vE()&&(i=!0),{leftSide:e,rightSide:i}}function qR(n,t,e,i,r,s){var o=XR(t.TL.left,t.TR.left),a=fE(t.TL.top,t.BL.top);e.TL.left-F0()<=gE()&&(o.leftSide=!1),e.TR.left>vE()&&(o.rightSide=!1),(o.leftSide&&!o.rightSide||!o.leftSide&&o.rightSide)&&(i.posX="right"===i.posX?"left":"right",i.offsetX=i.offsetX+r.width,i.offsetX=-1*i.offsetX,i.position=ns(n,i.posX,i.posY,!1),uE(t,i,r),s&&qR(n,t,e,i,r,!1),!o.leftSide&&o.rightSide&&a.bottomSide&&(i.offsetX=0))}function $R(n,t,e,i,r,s){var o=fE(t.TL.top,t.BL.top);e.TL.top-B0()<=pE()&&(o.topSide=!1),e.BL.top>=mE()&&n.getBoundingClientRect().bottommE()&&(i=!0),{topSide:e,bottomSide:i}}function ZR(){return po.getBoundingClientRect().width}function JR(){return po.getBoundingClientRect().height}function KR(){return po.getBoundingClientRect().left}function e4(){return po.getBoundingClientRect().top}function pE(){return po?e4():0}function gE(){return po?KR():0}function vE(){return po?F0()+KR()+ZR():F0()+i4()}function mE(){return po?B0()+e4()+JR():B0()+t4()}function B0(){return oc.documentElement.scrollTop||oc.body.scrollTop}function F0(){return oc.documentElement.scrollLeft||oc.body.scrollLeft}function t4(){return window.innerHeight}function i4(){var n=window.innerWidth,t=document.documentElement.getBoundingClientRect();return n-(n-(m(document.documentElement)?0:t.width))}function r4(){po=null,oc=null}var n4=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),bn=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},s4=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return n4(t,n),bn([I("left")],t.prototype,"X",void 0),bn([I("top")],t.prototype,"Y",void 0),t}(Ee),qn_OPEN="e-popup-open",qn_CLOSE="e-popup-close",lc=function(n){function t(e,i){return n.call(this,i,e)||this}return n4(t,n),t.prototype.onPropertyChanged=function(e,i){for(var r=0,s=Object.keys(e);r0&&c.left>0&&c.right>0&&c.bottom>0}var s=i.getBoundingClientRect();return!(r.bottoms.bottom||r.right>s.right||r.leftr.top?this.element.style.top="0px":s.bottomr.left&&(this.element.style.left=parseInt(this.element.style.left,10)+(s.left-r.left)+"px"))}},t.prototype.checkCollision=function(){var e=this.collision.X,i=this.collision.Y;"none"===e&&"none"===i||("flip"===e&&"flip"===i?this.callFlip({X:!0,Y:!0}):"fit"===e&&"fit"===i?this.callFit({X:!0,Y:!0}):("flip"===e?this.callFlip({X:!0,Y:!1}):"flip"===i&&this.callFlip({Y:!0,X:!1}),"fit"===e?this.callFit({X:!0,Y:!1}):"fit"===i&&this.callFit({X:!1,Y:!0})))},t.prototype.show=function(e,i){var r=this;if(this.getRelateToElement().classList.contains("e-filemanager")&&(this.fmDialogContainer=this.element.getElementsByClassName("e-file-select-wrap")[0]),this.wireEvents(),!m(this.fmDialogContainer)&&X.isIos&&(this.fmDialogContainer.style.display="block"),1e3===this.zIndex||!m(i)){var o=m(i)?this.element:i;this.zIndex=hc(o),je(this.element,{zIndex:this.zIndex})}e=m(e)||"object"!=typeof e?this.showAnimation:e,("none"!==this.collision.X||"none"!==this.collision.Y)&&(K([this.element],qn_CLOSE),V([this.element],qn_OPEN),this.checkCollision(),K([this.element],qn_OPEN),V([this.element],qn_CLOSE)),m(e)?(K([this.element],qn_CLOSE),V([this.element],qn_OPEN),this.trigger("open")):(e.begin=function(){r.isDestroyed||(K([r.element],qn_CLOSE),V([r.element],qn_OPEN))},e.end=function(){r.isDestroyed||r.trigger("open")},new Hs(e).animate(this.element))},t.prototype.hide=function(e){var i=this;e=m(e)||"object"!=typeof e?this.hideAnimation:e,m(e)?(K([this.element],qn_OPEN),V([this.element],qn_CLOSE),this.trigger("close")):(e.end=function(){i.isDestroyed||(K([i.element],qn_OPEN),V([i.element],qn_CLOSE),i.trigger("close"))},new Hs(e).animate(this.element)),this.unwireEvents()},t.prototype.getScrollableParent=function(e){return this.checkFixedParent(e),function yE(n,t){for(var e=getComputedStyle(n),i=[],r=/(auto|scroll)/,s=n.parentElement;s&&"HTML"!==s.tagName;){var o=getComputedStyle(s);!("absolute"===e.position&&"static"===o.position)&&r.test(o.overflow+o.overflowY+o.overflowX)&&i.push(s),s=s.parentElement}return t||i.push(document),i}(e,this.fixedParent)},t.prototype.checkFixedParent=function(e){for(var i=e.parentElement;i&&"HTML"!==i.tagName;){var r=getComputedStyle(i);("fixed"===r.position||"sticky"===r.position)&&!m(this.element)&&this.element.offsetParent&&"BODY"===this.element.offsetParent.tagName&&"hidden"!==getComputedStyle(this.element.offsetParent).overflow&&(this.element.style.top=window.scrollY>parseInt(this.element.style.top,10)?Re(window.scrollY-parseInt(this.element.style.top,10)):Re(parseInt(this.element.style.top,10)-window.scrollY),this.element.style.position="fixed",this.fixedParent=!0),i=i.parentElement,!m(this.element)&&m(this.element.offsetParent)&&"fixed"===r.position&&"fixed"===this.element.style.position&&(this.fixedParent=!0)}},bn([I("auto")],t.prototype,"height",void 0),bn([I("auto")],t.prototype,"width",void 0),bn([I(null)],t.prototype,"content",void 0),bn([I("container")],t.prototype,"targetType",void 0),bn([I(null)],t.prototype,"viewPortElement",void 0),bn([I({X:"none",Y:"none"})],t.prototype,"collision",void 0),bn([I("")],t.prototype,"relateTo",void 0),bn([re({},s4)],t.prototype,"position",void 0),bn([I(0)],t.prototype,"offsetX",void 0),bn([I(0)],t.prototype,"offsetY",void 0),bn([I(1e3)],t.prototype,"zIndex",void 0),bn([I(!1)],t.prototype,"enableRtl",void 0),bn([I("reposition")],t.prototype,"actionOnScroll",void 0),bn([I(null)],t.prototype,"showAnimation",void 0),bn([I(null)],t.prototype,"hideAnimation",void 0),bn([H()],t.prototype,"open",void 0),bn([H()],t.prototype,"close",void 0),bn([H()],t.prototype,"targetExitViewport",void 0),bn([Ft],t)}(Ii);function hc(n){for(var t=n.parentElement,e=[];t&&"BODY"!==t.tagName;){var i=document.defaultView.getComputedStyle(t,null).getPropertyValue("z-index"),r=document.defaultView.getComputedStyle(t,null).getPropertyValue("position");"auto"!==i&&"static"!==r&&e.push(i),t=t.parentElement}for(var s=[],o=0;o2147483647?2147483647:c}var Ui,ka,hf,yh,ME,Sh,$t,Ih,SE=["north-west","north","north-east","west","east","south-west","south","south-east"],jg="e-resize-handle",cc="e-focused-handle",fJ="e-dlg-resizable",o4=["e-restrict-left"],a4="e-resize-viewport",pJ=["north","west","east","south"],IE=0,bE=0,l4=0,h4=0,Vg=0,Wg=0,Yg=null,wE=null,CE=null,_0=!0,c4=0,EE=!0;function vJ(n){DE();var t=Si("span",{attrs:{unselectable:"on",contenteditable:"false"}});t.setAttribute("class","e-dialog-border-resize e-"+n),"south"===n&&(t.style.height="2px",t.style.width="100%",t.style.bottom="0px",t.style.left="0px"),"north"===n&&(t.style.height="2px",t.style.width="100%",t.style.top="0px",t.style.left="0px"),"east"===n&&(t.style.height="100%",t.style.width="2px",t.style.right="0px",t.style.top="0px"),"west"===n&&(t.style.height="100%",t.style.width="2px",t.style.left="0px",t.style.top="0px"),Ui.appendChild(t)}function d4(n){var t;return m(n)||(t="string"==typeof n?document.querySelector(n):n),t}function u4(n){for(var t=n||this,e=Ui.querySelectorAll("."+jg),i=0;i-1?"mouse":"touch"}function p4(n){if(n.preventDefault(),Ui=n.target.parentElement,DE(),Vg=n.pageX,Wg=n.pageY,n.target.classList.add(cc),m(Yg)||!0!==Yg(n,this)){this.targetEle&&Ui&&Ui.querySelector("."+fJ)&&($t="body"===this.target?null:this.targetEle,Sh=this.targetEle.clientWidth,yh=this.targetEle.clientHeight);var e=m($t)?document:$t;E.add(e,"mousemove",Qg,this),E.add(document,"mouseup",U0,this);for(var i=0;i=0||s.top<0)&&(e=!0):e=!0;var a=bE+(r-Wg);a=a>hf?a:hf;var l=0;m($t)||(l=o.top);var h=m($t)?0:$t.offsetHeight-$t.clientHeight,c=s.top-l-h/2;if(c=c<0?0:c,s.top>0&&c+a>yh){if(e=!1,Ui.classList.contains(a4))return;Ui.style.height=yh-parseInt(c.toString(),10)+"px"}else{var d=0;if(e){s.top<0&&t+(s.height+s.top)>0&&a+(d=s.top)<=30&&(a=s.height-(s.height+s.top)+30),a+s.top>=yh&&(Ui.style.height=s.height+(t-(s.height+s.top))+"px");var u=m($t)?d:c;a>=hf&&a+u<=yh&&(Ui.style.height=a+"px")}}}function TE(n){var e,t=!1,i="mouse"===f4(n.type)?n.pageY:n.touches[0].pageY,r=dc(Ui),s=m($t)?0:$t.offsetHeight-$t.clientHeight;m($t)||(e=dc($t)),(!m($t)&&r.top-e.top>0||m($t)&&i>0||!m($t)&&Math.floor(r.top-e.top+r.height+(e.bottom-r.bottom))-s<=yh)&&(t=!0);var o=bE-(i-Wg);if(t&&o>=hf&&o<=yh){var a=0;m($t)||(a=e.top);var l=h4-a+(i-Wg);l=l>0?l:1,Ui.style.height=o+"px",Ui.style.top=l+"px"}}function AE(n){var i,t=document.documentElement.clientWidth,e=!1;m($t)||(i=dc($t));var r="mouse"===f4(n.type)?n.pageX:n.touches[0].pageX,s=dc(Ui),o=m($t)?0:$t.offsetWidth-$t.clientWidth,a=m($t)?0:i.left,l=m($t)?0:i.width;m(Ih)&&(m($t)?Ih=t:(Ih=s.left-a-o/2+s.width,Ih+=l-o-Ih)),(!m($t)&&Math.floor(s.left-i.left+s.width+(i.right-s.right))-o<=Sh||m($t)&&r>=0)&&(e=!0);var h=IE-(r-Vg);if(_0&&(h=h>Ih?Ih:h),e&&h>=ME&&h<=Sh){var c=0;m($t)||(c=i.left);var d=l4-c+(r-Vg);d=d>0?d:1,h!==c4&&EE&&(Ui.style.width=h+"px"),_0&&(Ui.style.left=d+"px",EE=1!==d)}c4=h}function LE(n){var i,t=document.documentElement.clientWidth,e=!1;m($t)||(i=dc($t));var s=(n.touches?n.changedTouches[0]:n).pageX,o=dc(Ui);(!m($t)&&(o.left-i.left+o.width<=Sh||o.right-i.left>=o.width)||m($t)&&t-s>0)&&(e=!0);var a=IE+(s-Vg),l=0;if(m($t)||(l=i.left),o.left-l+a>Sh){if(e=!1,Ui.classList.contains(a4))return;Ui.style.width=Sh-(o.left-l)+"px"}e&&a>=ME&&a<=Sh&&(Ui.style.width=a+"px")}function v4(){for(var n=Ui.querySelectorAll("."+jg),t=0;t=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},bJ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return NE(t,n),Zt([I(!0)],t.prototype,"isFlat",void 0),Zt([I()],t.prototype,"buttonModel",void 0),Zt([I("Button")],t.prototype,"type",void 0),Zt([H()],t.prototype,"click",void 0),t}(Ee),MJ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return NE(t,n),Zt([I("Fade")],t.prototype,"effect",void 0),Zt([I(400)],t.prototype,"duration",void 0),Zt([I(0)],t.prototype,"delay",void 0),t}(Ee),j0="e-dialog",OE="e-rtl",kE="e-dlg-header-content",m4="e-dlg-header",V0="e-footer-content",W0="e-dlg-modal",y4="e-icon-dlg-close",Pa="e-dlg-target",ea="e-scroll-disabled",S4="e-device",Y0="e-dlg-fullscreen",I4="e-dlg-closeicon-btn",b4="e-popup-open",M4="Information",w4="e-scroll-disabled",C4="e-alert-dialog",E4="e-confirm-dialog",PE="e-dlg-resizable",cf="e-restrict-left",D4="e-resize-viewport",zE="user action",zJ=function(n){function t(e,i){var r=n.call(this,e,i)||this;return r.needsID=!0,r}return NE(t,n),t.prototype.render=function(){this.initialize(),this.initRender(),this.wireEvents(),"100%"===this.width&&(this.element.style.width=""),""!==this.minHeight&&(this.element.style.minHeight=Re(this.minHeight)),this.enableResize&&(this.setResize(),this.isModal&&(this.isModelResize=!0),"None"===this.animationSettings.effect&&this.getMinHeight()),this.renderComplete()},t.prototype.initializeValue=function(){this.dlgClosedBy=zE},t.prototype.preRender=function(){var e=this;if(this.initializeValue(),this.headerContent=null,this.allowMaxHeight=!0,this.preventVisibility=!0,this.clonedEle=this.element.cloneNode(!0),this.closeIconClickEventHandler=function(s){e.dlgClosedBy="close icon",e.hide(s)},this.dlgOverlayClickEventHandler=function(s){e.dlgClosedBy="overlayClick",s.preventFocus=!1,e.trigger("overlayClick",s,function(o){o.preventFocus||e.focusContent(),e.dlgClosedBy=zE})},this.l10n=new uo("dialog",{close:"Close"},this.locale),this.checkPositionData(),m(this.target)){var r=this.isProtectedOnChange;this.isProtectedOnChange=!0,this.target=document.body,this.isProtectedOnChange=r}},t.prototype.updatePersistData=function(){this.enablePersistence&&this.setProperties({width:parseFloat(this.element.style.width),height:parseFloat(this.element.style.height),position:{X:parseFloat(this.dragObj.element.style.left),Y:parseFloat(this.dragObj.element.style.top)}},!0)},t.prototype.isNumberValue=function(e){return/^[-+]?\d*\.?\d+$/.test(e)},t.prototype.checkPositionData=function(){if(!m(this.position)){if(!m(this.position.X)&&"number"!=typeof this.position.X&&this.isNumberValue(this.position.X)){var i=this.isProtectedOnChange;this.isProtectedOnChange=!0,this.position.X=parseFloat(this.position.X),this.isProtectedOnChange=i}m(this.position.Y)||"number"==typeof this.position.Y||this.isNumberValue(this.position.Y)&&(i=this.isProtectedOnChange,this.isProtectedOnChange=!0,this.position.Y=parseFloat(this.position.Y),this.isProtectedOnChange=i)}},t.prototype.getEle=function(e,i){for(var r=void 0,s=0;s=0&&t[e])vJ(t[e]);else if(""!==t[e].trim()){var i=Si("div",{className:"e-icons "+jg+" e-"+t[e]});Ui.appendChild(i)}hf=n.minHeight,ME=n.minWidth,Sh=n.maxWidth,yh=n.maxHeight,n.proxy&&n.proxy.element&&n.proxy.element.classList.contains("e-dialog")?u4(n.proxy):u4()}({element:this.element,direction:r,minHeight:parseInt(e.slice(0,i.indexOf("p")),10),maxHeight:this.targetEle.clientHeight,minWidth:parseInt(i.slice(0,i.indexOf("p")),10),maxWidth:this.targetEle.clientWidth,boundary:this.target===document.body?null:this.targetEle,resizeBegin:this.onResizeStart.bind(this),resizeComplete:this.onResizeComplete.bind(this),resizing:this.onResizing.bind(this),proxy:this}),this.wireWindowResizeEvent()}else v4(),this.unWireWindowResizeEvent(),this.element.classList.remove(this.isModal?cf:D4),this.element.classList.remove(PE)},t.prototype.getFocusElement=function(e){var r=e.querySelectorAll('input,select,textarea,button:enabled,a,[contenteditable="true"],[tabindex]');return{element:r[r.length-1]}},t.prototype.keyDown=function(e){var i=this;if(9===e.keyCode&&this.isModal){var r=void 0;m(this.btnObj)||(r=this.btnObj[this.btnObj.length-1]),m(this.btnObj)&&!m(this.ftrTemplateContent)&&(r=this.getFocusElement(this.ftrTemplateContent)),m(this.btnObj)&&m(this.ftrTemplateContent)&&!m(this.contentEle)&&(r=this.getFocusElement(this.contentEle)),!m(r)&&document.activeElement===r.element&&!e.shiftKey&&(e.preventDefault(),this.focusableElements(this.element).focus()),document.activeElement===this.focusableElements(this.element)&&e.shiftKey&&(e.preventDefault(),m(r)||r.element.focus())}var h,s=document.activeElement,o=["input","textarea"].indexOf(s.tagName.toLowerCase())>-1,a=!1;if(o||(a=s.hasAttribute("contenteditable")&&"true"===s.getAttribute("contenteditable")),27===e.keyCode&&this.closeOnEscape){this.dlgClosedBy="escape";var l=document.querySelector(".e-popup-open:not(.e-dialog)");!m(l)&&!l.classList.contains("e-toolbar-pop")&&!l.classList.contains("e-slider-tooltip")||this.hide(e)}(13===e.keyCode&&!e.ctrlKey&&"textarea"!==s.tagName.toLowerCase()&&o&&!m(this.primaryButtonEle)||13===e.keyCode&&e.ctrlKey&&("textarea"===s.tagName.toLowerCase()||a)&&!m(this.primaryButtonEle))&&this.buttons.some(function(d,u){h=u;var f=d.buttonModel;return!m(f)&&!0===f.isPrimary})&&"function"==typeof this.buttons[h].click&&setTimeout(function(){i.buttons[h].click.call(i,e)})},t.prototype.initialize=function(){m(this.target)||(this.targetEle="string"==typeof this.target?document.querySelector(this.target):this.target),this.isBlazorServerRender()||V([this.element],j0),X.isDevice&&V([this.element],S4),this.isBlazorServerRender()||this.setCSSClass(),this.setMaxHeight()},t.prototype.initRender=function(){var e=this;if(this.initialRender=!0,this.isBlazorServerRender()||Fe(this.element,{role:"dialog"}),1e3===this.zIndex?(this.setzIndex(this.element,!1),this.calculatezIndex=!0):this.calculatezIndex=!1,this.setTargetContent(),""!==this.header&&!m(this.header)&&this.setHeader(),this.renderCloseIcon(),this.setContent(),""===this.footerTemplate||m(this.footerTemplate)?!m(this.buttons[0])&&!m(this.buttons[0].buttonModel)&&this.setButton():this.setFooterTemplate(),this.allowDragging&&!m(this.headerContent)&&this.setAllowDragging(),Fe(this.element,{"aria-modal":this.isModal?"true":"false"}),this.isModal&&this.setIsModal(),!0!==this.element.classList.contains(C4)&&!0!==this.element.classList.contains(E4)&&!m(this.element.parentElement)){var i=this.isModal?this.dlgContainer.parentElement:this.element.parentElement;this.refElement=this.createElement("div",{className:"e-dlg-ref-element"}),i.insertBefore(this.refElement,this.isModal?this.dlgContainer:this.element)}if(m(this.targetEle)||this.targetEle.appendChild(this.isModal?this.dlgContainer:this.element),this.popupObj=new lc(this.element,{height:this.height,width:this.width,zIndex:this.zIndex,relateTo:this.target,actionOnScroll:"none",enableRtl:this.enableRtl,open:function(o){var a={container:e.isModal?e.dlgContainer:e.element,element:e.element,target:e.target,preventFocus:!1};e.enableResize&&e.resetResizeIcon(),e.trigger("open",a,function(l){l.preventFocus||e.focusContent()})},close:function(o){e.isModal&&V([e.dlgOverlay],"e-fade"),e.unBindEvent(e.element),e.isModal&&(e.dlgContainer.style.display="none"),e.trigger("close",e.closeArgs);var a=document.activeElement;!m(a)&&!m(a.blur)&&a.blur(),!m(e.storeActiveElement)&&!m(e.storeActiveElement.focus)&&e.storeActiveElement.focus()}}),this.positionChange(),this.setEnableRTL(),this.isBlazorServerRender()||(V([this.element],"e-popup-close"),this.isModal&&this.setOverlayZindex()),this.visible){if(this.show(),this.isModal){var r=this.getTargetContainer(this.target);r instanceof Element&&"rtl"===window.getComputedStyle(r).getPropertyValue("direction")&&this.setPopupPosition()}}else this.isModal&&(this.dlgOverlay.style.display="none");this.initialRender=!1},t.prototype.getTargetContainer=function(e){var i=null;if("string"==typeof e)if(e.startsWith("#"))i=document.getElementById(e.substring(1));else if(e.startsWith(".")){var r=document.getElementsByClassName(e.substring(1));i=r.length>0?r[0]:null}else!(e instanceof HTMLElement)&&e!==document.body&&(i=document.querySelector(e));else e instanceof HTMLElement&&(i=e);return i},t.prototype.resetResizeIcon=function(){var e=this.getMinHeight();if(this.targetEle.offsetHeight0&&("function"==typeof this.buttons[e].click&&E.add(s[e],"click",this.buttons[e].click,this),"object"==typeof this.buttons[e].click&&E.add(s[e],"click",this.buttonClickHandler.bind(this,e),this)),!this.isBlazorServerRender()&&!m(this.ftrTemplateContent)&&(this.btnObj[e].appendTo(this.ftrTemplateContent.children[e]),this.buttons[e].isFlat&&this.btnObj[e].element.classList.add("e-flat"),this.primaryButtonEle=this.element.getElementsByClassName("e-primary")[0]))},t.prototype.buttonClickHandler=function(e){this.trigger("buttons["+e+"].click",{})},t.prototype.setContent=function(){this.contentEle=this.createElement("div",{className:"e-dlg-content",id:this.element.id+"_dialog-content"}),Fe(this.element,this.headerEle?{"aria-describedby":this.element.id+"_title "+this.element.id+"_dialog-content"}:{"aria-describedby":this.element.id+"_dialog-content"}),this.innerContentElement?this.contentEle.appendChild(this.innerContentElement):(!m(this.content)&&""!==this.content||!this.initialRender)&&(("string"!=typeof this.content||ce())&&this.content instanceof HTMLElement?this.contentEle.appendChild(this.content):this.setTemplate(this.content,this.contentEle,"content")),m(this.headerContent)?this.element.insertBefore(this.contentEle,this.element.children[0]):this.element.insertBefore(this.contentEle,this.element.children[1]),"auto"===this.height&&(!this.isBlazorServerRender()&&X.isIE&&""===this.element.style.width&&!m(this.width)&&(this.element.style.width=Re(this.width)),this.setMaxHeight())},t.prototype.setTemplate=function(e,i,r){var s,o,a;o=i.classList.contains(m4)?this.element.id+"header":i.classList.contains(V0)?this.element.id+"footerTemplate":this.element.id+"content",m(e.outerHTML)?("string"==typeof e||"string"!=typeof e||ce()&&!this.isStringTemplate)&&("string"==typeof e&&(e=this.sanitizeHelper(e)),this.isVue||"string"!=typeof e?(s=si(e),a=e):i.innerHTML=e):i.appendChild(e);var l=[];if(!m(s)){for(var c=0,d=s({},this,r,o,!(ce()&&!this.isStringTemplate&&0===a.indexOf("
Blazor"))||this.isStringTemplate);c/g,"");(this.element.children.length>0||i)&&(this.innerContentElement=document.createDocumentFragment(),[].slice.call(this.element.childNodes).forEach(function(r){8!==r.nodeType&&e.innerContentElement.appendChild(r)}))}},t.prototype.setHeader=function(){this.headerEle?this.headerEle.innerHTML="":this.headerEle=this.createElement("div",{id:this.element.id+"_title",className:m4}),this.createHeaderContent(),this.headerContent.appendChild(this.headerEle),this.setTemplate(this.header,this.headerEle,"header"),Fe(this.element,{"aria-describedby":this.element.id+"_title"}),Fe(this.element,{"aria-labelledby":this.element.id+"_dialog-header"}),this.element.insertBefore(this.headerContent,this.element.children[0]),this.allowDragging&&!m(this.headerContent)&&this.setAllowDragging()},t.prototype.setFooterTemplate=function(){this.ftrTemplateContent?this.ftrTemplateContent.innerHTML="":this.ftrTemplateContent=this.createElement("div",{className:V0}),""===this.footerTemplate||m(this.footerTemplate)?this.ftrTemplateContent.innerHTML=this.buttonContent.join(""):this.setTemplate(this.footerTemplate,this.ftrTemplateContent,"footerTemplate"),this.element.appendChild(this.ftrTemplateContent)},t.prototype.createHeaderContent=function(){m(this.headerContent)&&(this.headerContent=this.createElement("div",{id:this.element.id+"_dialog-header",className:kE}))},t.prototype.renderCloseIcon=function(){this.showCloseIcon&&(this.closeIcon=this.createElement("button",{className:I4,attrs:{type:"button"}}),this.closeIconBtnObj=new ys({cssClass:"e-flat",iconCss:y4+" e-icons"}),this.closeIconTitle(),m(this.headerContent)?(this.createHeaderContent(),gl([this.closeIcon],this.headerContent),this.element.insertBefore(this.headerContent,this.element.children[0])):gl([this.closeIcon],this.headerContent),this.closeIconBtnObj.appendTo(this.closeIcon))},t.prototype.closeIconTitle=function(){this.l10n.setLocale(this.locale);var e=this.l10n.getConstant("close");this.closeIcon.setAttribute("title",e),this.closeIcon.setAttribute("aria-label",e)},t.prototype.setCSSClass=function(e){e&&(K([this.element],e.split(" ")),this.isModal&&!m(this.dlgContainer)&&K([this.dlgContainer],e.split(" "))),this.cssClass&&(V([this.element],this.cssClass.split(" ")),this.isModal&&!m(this.dlgContainer)&&V([this.dlgContainer],this.cssClass.split(" ")))},t.prototype.setIsModal=function(){this.dlgContainer=this.createElement("div",{className:"e-dlg-container"}),this.setCSSClass(),this.element.classList.remove(b4),this.element.parentNode.insertBefore(this.dlgContainer,this.element),this.dlgContainer.appendChild(this.element),V([this.element],W0),this.dlgOverlay=this.createElement("div",{className:"e-dlg-overlay"}),this.dlgOverlay.style.zIndex=(this.zIndex-1).toString(),this.dlgContainer.appendChild(this.dlgOverlay)},t.prototype.getValidFocusNode=function(e){for(var i,r=0;r0||"a"===i.tagName.toLowerCase()&&i.hasAttribute("href"))&&i.tabIndex>-1&&!i.disabled&&!this.disableElement(i,'[disabled],[aria-disabled="true"],[type="hidden"]'))return i;i=null}return i},t.prototype.focusableElements=function(e){if(!m(e)){var r=e.querySelectorAll('input,select,textarea,button,a,[contenteditable="true"],[tabindex]');return this.getValidFocusNode(r)}return null},t.prototype.getAutoFocusNode=function(e){var i=e.querySelector("."+I4),s=e.querySelectorAll("[autofocus]"),o=this.getValidFocusNode(s);if(ce()&&(this.primaryButtonEle=this.element.getElementsByClassName("e-primary")[0]),m(o)){if(!m(o=this.focusableElements(this.contentEle)))return o;if(!m(this.primaryButtonEle))return this.element.querySelector(".e-primary")}else i=o;return i},t.prototype.disableElement=function(e,i){var r=e?e.matches||e.webkitMatchesSelector||e.msGetRegionContent:null;if(r)for(;e;e=e.parentNode)if(e instanceof Element&&r.call(e,i))return e;return null},t.prototype.focusContent=function(){var e=this.getAutoFocusNode(this.element),i=m(e)?this.element:e,r=X.userAgent;(r.indexOf("MSIE ")>0||r.indexOf("Trident/")>0)&&this.element.focus(),i.focus(),this.unBindEvent(this.element),this.bindEvent(this.element)},t.prototype.bindEvent=function(e){E.add(e,"keydown",this.keyDown,this)},t.prototype.unBindEvent=function(e){E.remove(e,"keydown",this.keyDown)},t.prototype.updateSanitizeContent=function(){this.isBlazorServerRender()||(this.contentEle.innerHTML=this.sanitizeHelper(this.content))},t.prototype.isBlazorServerRender=function(){return ce()&&this.isServerRendered},t.prototype.getModuleName=function(){return"dialog"},t.prototype.onPropertyChanged=function(e,i){if(this.element.classList.contains(j0))for(var r=0,s=Object.keys(e);r0?this.showCloseIcon||""!==this.header&&!m(this.header)?this.showCloseIcon||he(this.closeIcon):(he(this.headerContent),this.headerContent=null):(this.renderCloseIcon(),this.wireEvents());break;case"locale":this.showCloseIcon&&this.closeIconTitle();break;case"visible":this.visible?this.show():this.hide();break;case"isModal":this.updateIsModal();break;case"height":je(this.element,{height:Re(e.height)}),this.updatePersistData();break;case"width":je(this.element,{width:Re(e.width)}),this.updatePersistData();break;case"zIndex":this.popupObj.zIndex=this.zIndex,this.isModal&&this.setOverlayZindex(this.zIndex),this.element.style.zIndex!==this.zIndex.toString()&&(this.calculatezIndex=!1);break;case"cssClass":this.setCSSClass(i.cssClass);break;case"buttons":this.unWireButtonEvents(),this.destroyButtons(),m(this.ftrTemplateContent)||(he(this.ftrTemplateContent),this.ftrTemplateContent=null),this.footerTemplate="",this.setButton();break;case"allowDragging":this.allowDragging&&!m(this.headerContent)?this.setAllowDragging():this.dragObj.destroy();break;case"target":this.setTarget(e.target);break;case"position":if(this.checkPositionData(),this.isModal){var a=this.position.X,l=this.position.Y;m(i.position)||(m(i.position.X)||(a=i.position.X),m(i.position.Y)||(l=i.position.Y)),this.dlgContainer.classList.contains("e-dlg-"+a+"-"+l)&&this.dlgContainer.classList.remove("e-dlg-"+a+"-"+l)}this.positionChange(),this.updatePersistData();break;case"enableRtl":this.setEnableRTL();break;case"enableResize":this.setResize(),this.isModelResize=this.enableResize&&this.isModal,this.enableResize&&this.dialogOpen&&this.resetResizeIcon();break;case"minHeight":""!==this.minHeight&&(this.element.style.minHeight=Re(this.minHeight))}},t.prototype.setTarget=function(e){this.popupObj.relateTo=e,this.target=e,this.targetEle="string"==typeof this.target?document.querySelector(this.target):this.target,this.dragObj&&(this.dragObj.dragArea=this.targetEle),this.setMaxHeight(),this.isModal&&this.updateIsModal(),this.enableResize&&this.setResize(),m(this.targetEle)||(this.isModal&&!m(this.dlgContainer)?this.targetEle.appendChild(this.dlgContainer):m(this.element)||this.targetEle.appendChild(this.element))},t.prototype.updateIsModal=function(){if(this.element.setAttribute("aria-modal",this.isModal?"true":"false"),this.isModal)m(this.dlgOverlay)&&(this.setIsModal(),this.element.style.top="0px",this.element.style.left="0px",m(this.targetEle)||this.targetEle.appendChild(this.dlgContainer));else{for(K([this.element],W0),K([document.body],[Pa,ea]),he(this.dlgOverlay);this.dlgContainer.firstChild;)this.dlgContainer.parentElement.insertBefore(this.dlgContainer.firstChild,this.dlgContainer);this.dlgContainer.parentElement.removeChild(this.dlgContainer)}this.visible&&this.show(),this.positionChange(),this.isModal&&this.dlgOverlay&&E.add(this.dlgOverlay,"click",this.dlgOverlayClickEventHandler,this)},t.prototype.setzIndex=function(e,i){var r=this.isProtectedOnChange;this.isProtectedOnChange=!0;var s=hc(e);this.zIndex=s>this.zIndex?s:this.zIndex,this.isProtectedOnChange=r,i&&(this.popupObj.zIndex=this.zIndex)},t.prototype.windowResizeHandler=function(){(function yJ(n){Sh=n})(this.targetEle.clientWidth),function SJ(n){yh=n}(this.targetEle.clientHeight),this.setMaxHeight()},t.prototype.getPersistData=function(){return this.addOnPersist(["width","height","position"])},t.prototype.removeAllChildren=function(e){for(;e.children[0];)this.removeAllChildren(e.children[0]),e.removeChild(e.children[0])},t.prototype.destroy=function(){if(!this.isDestroyed){var e=[OE,W0,PE,cf,Y0,S4],i=["role","aria-modal","aria-labelledby","aria-describedby","aria-grabbed","tabindex","style"];K([this.targetEle],[Pa,ea]),!m(this.element)&&this.element.classList.contains(Y0)&&K([document.body],[Pa,ea]),this.isModal&&K([m(this.targetEle)?document.body:this.targetEle],ea),this.unWireEvents(),this.unWireButtonEvents(),this.destroyButtons(),m(this.closeIconBtnObj)||this.closeIconBtnObj.destroy(),m(this.dragObj)||this.dragObj.destroy(),!m(this.popupObj.element)&&this.popupObj.element.classList.contains("e-popup")&&this.popupObj.destroy(),K([this.element],e),!m(this.cssClass)&&""!==this.cssClass&&K([this.element],this.cssClass.split(" ")),!m(this.refElement)&&!m(this.refElement.parentElement)&&(this.refElement.parentElement.insertBefore(this.isModal?this.dlgContainer:this.element,this.refElement),he(this.refElement),this.refElement=void 0),this.isModal&&(he(this.dlgOverlay),this.dlgContainer.parentNode.insertBefore(this.element,this.dlgContainer),he(this.dlgContainer)),this.element.innerHTML=this.clonedEle.innerHTML;for(var r=0;r0&&""===this.footerTemplate&&this.ftrTemplateContent)for(var e=0;e=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},RE="e-tooltip",O4="e-icons",k4="e-tooltip-close",HE="e-tooltip-wrap",P4="e-tip-content",df="e-arrow-tip",z4="e-arrow-tip-outer",Q0="e-arrow-tip-inner",Gg="e-tip-bottom",BE="e-tip-top",R4="e-tip-left",FE="e-tip-right",_E="e-popup",Xg="e-popup-open",UE="e-popup-close",G0="e-lib",H4="e-tooltip-popup-container",UJ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return T4(t,n),Gi([I({effect:"FadeIn",duration:150,delay:0})],t.prototype,"open",void 0),Gi([I({effect:"FadeOut",duration:150,delay:0})],t.prototype,"close",void 0),t}(Ee),bh=function(n){function t(e,i){var r=n.call(this,e,i)||this;return r.mouseMoveEvent=null,r.mouseMoveTarget=null,r.containerElement=null,r.isBodyContainer=!0,r}return T4(t,n),t.prototype.initialize=function(){this.formatPosition(),V([this.element],RE)},t.prototype.formatPosition=function(){var e,i;this.position&&(0===this.position.indexOf("Top")||0===this.position.indexOf("Bottom")?(e=this.position.split(/(?=[A-Z])/),this.tooltipPositionY=e[0],this.tooltipPositionX=e[1]):(i=this.position.split(/(?=[A-Z])/),this.tooltipPositionX=i[0],this.tooltipPositionY=i[1]))},t.prototype.renderArrow=function(){this.setTipClass(this.position);var e=this.createElement("div",{className:df+" "+this.tipClass});e.appendChild(this.createElement("div",{className:z4+" "+this.tipClass})),e.appendChild(this.createElement("div",{className:Q0+" "+this.tipClass})),this.tooltipEle.appendChild(e)},t.prototype.setTipClass=function(e){this.tipClass=0===e.indexOf("Right")?R4:0===e.indexOf("Bottom")?BE:0===e.indexOf("Left")?FE:Gg},t.prototype.renderPopup=function(e){var i=this.mouseTrail?{top:0,left:0}:this.getTooltipPosition(e);this.tooltipEle.classList.remove(G0),this.popupObj=new lc(this.tooltipEle,{height:this.height,width:this.width,position:{X:i.left,Y:i.top},enableRtl:this.enableRtl,open:this.openPopupHandler.bind(this),close:this.closePopupHandler.bind(this)})},t.prototype.getScalingFactor=function(e){if(!e)return{x:1,y:1};var i={x:1,y:1},r=e.closest('[style*="transform: scale"]');if(r&&r!==this.tooltipEle&&r.contains(this.tooltipEle)){var a=window.getComputedStyle(r).getPropertyValue("transform").match(/matrix\(([^)]+)\)/)[1].split(",").map(parseFloat);i.x=a[0],i.y=a[3]}return i},t.prototype.getTooltipPosition=function(e){this.tooltipEle.style.display="block";var i=this.element.closest('[style*="zoom"]');i&&(i.contains(this.tooltipEle)||(this.tooltipEle.style.zoom=getComputedStyle(i).zoom));var r=ns(e,this.tooltipPositionX,this.tooltipPositionY,!this.isBodyContainer,this.isBodyContainer?null:this.containerElement.getBoundingClientRect()),s=this.getScalingFactor(e),o=this.calculateTooltipOffset(this.position,s.x,s.y),a=this.calculateElementPosition(r,o),c=this.collisionFlipFit(e,a[0],a[1]);return c.left=c.left/s.x,c.top=c.top/s.y,this.tooltipEle.style.display="",c},t.prototype.windowResize=function(){this.reposition(this.findTarget())},t.prototype.reposition=function(e){if(this.popupObj&&e){var i=this.getTooltipPosition(e);this.popupObj.position={X:i.left,Y:i.top},this.popupObj.dataBind()}},t.prototype.openPopupHandler=function(){!this.mouseTrail&&this.needTemplateReposition()&&this.reposition(this.findTarget()),this.trigger("afterOpen",this.tooltipEventArgs),this.tooltipEventArgs=null},t.prototype.closePopupHandler=function(){this.isReact&&!("Click"===this.opensOn||"function"==typeof this.content)&&this.clearTemplate(["content"]),this.clear();var e={type:this.tooltipEventArgs.event?this.tooltipEventArgs.event.type:null,cancel:!1,target:this.tooltipEventArgs.target,event:this.tooltipEventArgs.event?this.tooltipEventArgs.event:null,element:this.tooltipEle,isInteracted:!m(this.tooltipEventArgs.event)};this.trigger("afterClose",e),e=null},t.prototype.calculateTooltipOffset=function(e,i,r){void 0===i&&(i=1),void 0===r&&(r=1);var o,a,l,h,c,d,u,f,s={top:0,left:0};if(1!==i||1!==r){var p=this.tooltipEle.getBoundingClientRect(),g=void 0;l=Math.round(p.width),h=Math.round(p.height),(c=_("."+df,this.tooltipEle))&&(g=c.getBoundingClientRect()),o=c?Math.round(g.width):0,a=c?Math.round(g.height):0,d=this.showTipPointer?0:8,u=a/2+2+(h-this.tooltipEle.clientHeight*r),f=o/2+2+(l-this.tooltipEle.clientWidth*i)}else l=this.tooltipEle.offsetWidth,h=this.tooltipEle.offsetHeight,c=_("."+df,this.tooltipEle),d=this.showTipPointer?0:8,u=(a=c?c.offsetHeight:0)/2+2+(this.tooltipEle.offsetHeight-this.tooltipEle.clientHeight),f=(o=c?c.offsetWidth:0)/2+2+(this.tooltipEle.offsetWidth-this.tooltipEle.clientWidth);switch(this.mouseTrail&&(d+=2),e){case"RightTop":s.left+=o+d,s.top-=h-u;break;case"RightCenter":s.left+=o+d,s.top-=h/2;break;case"RightBottom":s.left+=o+d,s.top-=u;break;case"BottomRight":s.top+=a+d,s.left-=f;break;case"BottomCenter":s.top+=a+d,s.left-=l/2;break;case"BottomLeft":s.top+=a+d,s.left-=l-f;break;case"LeftBottom":s.left-=o+l+d,s.top-=u;break;case"LeftCenter":s.left-=o+l+d,s.top-=h/2;break;case"LeftTop":s.left-=o+l+d,s.top-=h-u;break;case"TopLeft":s.top-=h+a+d,s.left-=l-f;break;case"TopRight":s.top-=h+a+d,s.left-=f;break;default:s.top-=h+a+d,s.left-=l/2}return s.left+=this.offsetX,s.top+=this.offsetY,s},t.prototype.updateTipPosition=function(e){var i=we("."+df+",."+z4+",."+Q0,this.tooltipEle);K(i,[Gg,BE,R4,FE]),this.setTipClass(e),V(i,this.tipClass)},t.prototype.adjustArrow=function(e,i,r,s){var o=_("."+df,this.tooltipEle);if(!1!==this.showTipPointer&&null!==o){var a,l;this.updateTipPosition(i),this.tooltipEle.style.display="block";var p,h=this.tooltipEle.clientWidth,c=this.tooltipEle.clientHeight,d=_("."+Q0,this.tooltipEle),u=o.offsetWidth,f=o.offsetHeight;this.tooltipEle.style.display="",this.tipClass===Gg||this.tipClass===BE?(this.tipClass===Gg?(l="99.9%",d.style.top="-"+(f-2)+"px"):(l=-(f-1)+"px",d.style.top="-"+(f-6)+"px"),e&&(a=(p="Center"!==r||h>e.offsetWidth||this.mouseTrail)&&"Left"===r||!p&&"End"===this.tipPointerPosition?h-u-2+"px":p&&"Right"===r||!p&&"Start"===this.tipPointerPosition?"2px":!p||"End"!==this.tipPointerPosition&&"Start"!==this.tipPointerPosition?h/2-u/2+"px":"End"===this.tipPointerPosition?e.offsetWidth+(this.tooltipEle.offsetWidth-e.offsetWidth)/2-u/2-2+"px":(this.tooltipEle.offsetWidth-e.offsetWidth)/2-u/2+2+"px")):(this.tipClass===FE?(a="99.9%",d.style.left="-"+(u-2)+"px"):(a=-(u-1)+"px",d.style.left=u-2-u+"px"),l=(p="Center"!==s||c>e.offsetHeight||this.mouseTrail)&&"Top"===s||!p&&"End"===this.tipPointerPosition?c-f-2+"px":p&&"Bottom"===s||!p&&"Start"===this.tipPointerPosition?"2px":c/2-f/2+"px"),o.style.top=l,o.style.left=a}},t.prototype.renderContent=function(e){var i=this,r=_("."+P4,this.tooltipEle);if(this.cssClass&&V([this.tooltipEle],this.cssClass.split(" ")),e&&!m(e.getAttribute("title"))&&(e.setAttribute("data-content",e.getAttribute("title")),e.removeAttribute("title")),m(this.content))e&&!m(e.getAttribute("data-content"))&&(r.innerHTML=e.getAttribute("data-content"));else if(r.innerHTML="",this.content instanceof HTMLElement)r.appendChild(this.content);else if("string"==typeof this.content)this.isAngular?this.setProperties({content:Ai.sanitize(this.content)},!0):this.content=this.enableHtmlSanitizer?Ai.sanitize(this.content):this.content,this.enableHtmlParse?(o=si(this.content)({},this,"content",this.element.id+"content",void 0,void 0,r,this.root))&&Dt(o,r):r.textContent=this.content;else{var o;(o=si(this.content)({},this,"content",this.element.id+"content",void 0,void 0,r))&&(this.isAngular&&setTimeout(function(){i.reposition(e)},1),Dt(o,r)),this.renderReactTemplates()}},t.prototype.renderCloseIcon=function(){if(this.isSticky){var i=this.createElement("div",{className:O4+" "+k4});this.tooltipEle.appendChild(i),E.add(i,X.touchStartEvent,this.onStickyClose,this)}else{var e=this.tooltipEle.querySelector("."+O4+"."+k4);e&>(e)}},t.prototype.addDescribedBy=function(e,i){var r=(e.getAttribute("aria-describedby")||"").split(/\s+/);r.indexOf(i)<0&&r.push(i),Fe(e,{"aria-describedby":r.join(" ").trim(),"data-tooltip-id":i})},t.prototype.removeDescribedBy=function(e){var i=e.getAttribute("data-tooltip-id"),r=(e.getAttribute("aria-describedby")||"").split(/\s+/),s=r.indexOf(i);-1!==s&&r.splice(s,1),e.removeAttribute("data-tooltip-id");var o=r.join(" ").trim();o?e.setAttribute("aria-describedby",o):e.removeAttribute("aria-describedby")},t.prototype.tapHoldHandler=function(e){clearTimeout(this.autoCloseTimer),this.targetHover(e.originalEvent)},t.prototype.touchEndHandler=function(){var e=this;this.isSticky||(this.autoCloseTimer=setTimeout(function(){e.close()},1500))},t.prototype.targetClick=function(e){var i;!m(i=this.target?J(e.target,this.target):this.element)&&(null===i.getAttribute("data-tooltip-id")?this.targetHover(e):this.isSticky||this.hideTooltip(this.animation.close,e,i))},t.prototype.targetHover=function(e){var i;if(!(m(i=this.target?J(e.target,this.target):this.element)||null!==i.getAttribute("data-tooltip-id")&&0===this.closeDelay)){for(var s=0,o=[].slice.call(we('[data-tooltip-id= "'+this.ctrlId+'_content"]',document));s0?this.showTimer=setTimeout(function(){o.mouseTrail&&E.add(i,"mousemove touchstart mouseenter",o.onMouseMove,o),o.popupObj&&(o.popupObj.show(a,i),o.mouseMoveEvent&&o.mouseTrail&&o.onMouseMove(o.mouseMoveEvent))},this.openDelay):this.popupObj&&this.popupObj.show(a,i)}s&&this.wireMouseEvents(s,i)},t.prototype.needTemplateReposition=function(){return!m(this.viewContainerRef)&&"string"!=typeof this.viewContainerRef||this.isReact},t.prototype.checkCollision=function(e,i,r){var s={left:i,top:r,position:this.position,horizontal:this.tooltipPositionX,vertical:this.tooltipPositionY},o=ac(this.tooltipEle,this.checkCollideTarget(),i,r);return o.length>0&&(s.horizontal=o.indexOf("left")>=0?"Right":o.indexOf("right")>=0?"Left":this.tooltipPositionX,s.vertical=o.indexOf("top")>=0?"Bottom":o.indexOf("bottom")>=0?"Top":this.tooltipPositionY),s},t.prototype.calculateElementPosition=function(e,i){return[this.isBodyContainer?e.left+i.left:e.left-this.containerElement.getBoundingClientRect().left+i.left+window.pageXOffset+this.containerElement.scrollLeft,this.isBodyContainer?e.top+i.top:e.top-this.containerElement.getBoundingClientRect().top+i.top+window.pageYOffset+this.containerElement.scrollTop]},t.prototype.collisionFlipFit=function(e,i,r){var s=this.checkCollision(e,i,r),o=s.position;if(this.tooltipPositionY!==s.vertical&&(o=0===this.position.indexOf("Bottom")||0===this.position.indexOf("Top")?s.vertical+this.tooltipPositionX:this.tooltipPositionX+s.vertical),this.tooltipPositionX!==s.horizontal&&(0===o.indexOf("Left")&&(s.vertical="LeftTop"===o||"LeftCenter"===o?"Top":"Bottom",o=s.vertical+"Left"),0===o.indexOf("Right")&&(s.vertical="RightTop"===o||"RightCenter"===o?"Top":"Bottom",o=s.vertical+"Right"),s.horizontal=this.tooltipPositionX),this.tooltipEventArgs={type:null,cancel:!1,target:e,event:null,element:this.tooltipEle,collidedPosition:o},this.trigger("beforeCollision",this.tooltipEventArgs),this.tooltipEventArgs.cancel)o=this.position;else{var a=s.vertical,l=s.horizontal;if(s.position!==o){var h=ns(e,l,a,!this.isBodyContainer,this.isBodyContainer?null:this.containerElement.getBoundingClientRect());this.adjustArrow(e,o,l,a);var c=this.getScalingFactor(e),d=this.calculateTooltipOffset(o,c.x,c.y);d.top-=this.getOffSetPosition("TopBottom",o,this.offsetY),d.left-=this.getOffSetPosition("RightLeft",o,this.offsetX),s.position=o;var u=this.calculateElementPosition(h,d);s.left=u[0],s.top=u[1]}else this.adjustArrow(e,o,l,a)}var f={left:s.left,top:s.top},p=this.isBodyContainer?cE(this.tooltipEle,this.checkCollideTarget(),{X:!0,Y:this.windowCollision},f):f;this.tooltipEle.style.display="block";var g=_("."+df,this.tooltipEle);if(this.showTipPointer&&null!=g&&(0===o.indexOf("Bottom")||0===o.indexOf("Top"))){var v=parseInt(g.style.left,10)-(p.left-s.left);v<0?v=0:v+g.offsetWidth>this.tooltipEle.clientWidth&&(v=this.tooltipEle.clientWidth-g.offsetWidth),g.style.left=v.toString()+"px"}return this.tooltipEle.style.display="",f.left=p.left,f.top=p.top,f},t.prototype.getOffSetPosition=function(e,i,r){return-1!==e.indexOf(this.position.split(/(?=[A-Z])/)[0])&&-1!==e.indexOf(i.split(/(?=[A-Z])/)[0])?2*r:0},t.prototype.checkCollideTarget=function(){return!this.windowCollision&&this.target?this.element:null},t.prototype.hideTooltip=function(e,i,r){var s=this;this.closeDelay>0?(clearTimeout(this.hideTimer),clearTimeout(this.showTimer),this.hideTimer=setTimeout(function(){s.closeDelay&&s.tooltipEle&&s.isTooltipOpen||s.tooltipHide(e,i,r)},this.closeDelay)):this.tooltipHide(e,i,r)},t.prototype.tooltipHide=function(e,i,r){var o,s=this;o=i?this.target?r||i.target:this.element:_('[data-tooltip-id= "'+this.ctrlId+'_content"]',document),this.tooltipEventArgs={type:i?i.type:null,cancel:!1,target:o,event:i||null,element:this.tooltipEle,isInteracted:!m(i)},this.trigger("beforeClose",this.tooltipEventArgs,function(a){a.cancel?s.isHidden=!1:(s.mouseMoveBeforeRemove(),s.popupHide(e,o,i))})},t.prototype.popupHide=function(e,i,r){i&&r&&this.restoreElement(i),this.isHidden=!0;var s={name:this.animation.close.effect,duration:e.duration,delay:e.delay,timingFunction:"easeIn"};"None"===e.effect&&(s=void 0),this.popupObj&&this.popupObj.hide(s)},t.prototype.restoreElement=function(e){this.unwireMouseEvents(e),m(e.getAttribute("data-content"))||(e.setAttribute("title",e.getAttribute("data-content")),e.removeAttribute("data-content")),this.removeDescribedBy(e)},t.prototype.clear=function(){var e=this.findTarget();e&&this.restoreElement(e),this.tooltipEle&&(K([this.tooltipEle],UE),V([this.tooltipEle],Xg)),this.isHidden&&(this.popupObj&&this.popupObj.destroy(),this.tooltipEle&>(this.tooltipEle),this.tooltipEle=null,this.popupObj=null)},t.prototype.tooltipHover=function(){this.tooltipEle&&(this.isTooltipOpen=!0)},t.prototype.tooltipMouseOut=function(e){this.isTooltipOpen=!1,this.hideTooltip(this.animation.close,e,this.findTarget())},t.prototype.onMouseOut=function(e){var i=e.relatedTarget;if(i&&!this.mouseTrail){var r=J(i,"."+HE+"."+G0+"."+_E);r?E.add(r,"mouseleave",this.tooltipElementMouseOut,this):(this.hideTooltip(this.animation.close,e,this.findTarget()),0===this.closeDelay&&("None"===this.animation.close.effect||this.isReact&&"string"!=typeof this.content)&&this.clear())}else this.hideTooltip(this.animation.close,e,this.findTarget()),this.clear();this.popupObj&&!this.popupObj.element.classList.contains(Xg)&&this.clear()},t.prototype.tooltipElementMouseOut=function(e){this.hideTooltip(this.animation.close,e,this.findTarget()),E.remove(this.element,"mouseleave",this.tooltipElementMouseOut),this.clear()},t.prototype.onStickyClose=function(){this.close()},t.prototype.onMouseMove=function(e){var i=0,r=0;e.type.indexOf("touch")>-1?(e.preventDefault(),i=e.touches[0].pageX,r=e.touches[0].pageY):(i=e.pageX,r=e.pageY),Hs.stop(this.tooltipEle),K([this.tooltipEle],UE),V([this.tooltipEle],Xg),this.adjustArrow(e.target,this.position,this.tooltipPositionX,this.tooltipPositionY);var s=this.getScalingFactor(e.target),o=this.calculateTooltipOffset(this.position,s.x,s.y),h=this.checkCollision(e.target,i+o.left+this.offsetX,r+o.top+this.offsetY);if(this.tooltipPositionX!==h.horizontal||this.tooltipPositionY!==h.vertical){var c=0===this.position.indexOf("Bottom")||0===this.position.indexOf("Top")?h.vertical+h.horizontal:h.horizontal+h.vertical;h.position=c,this.adjustArrow(e.target,h.position,h.horizontal,h.vertical);var d=this.calculateTooltipOffset(h.position,s.x,s.y);h.left=i+d.left-this.offsetX,h.top=r+d.top-this.offsetY}this.tooltipEle.style.left=h.left+"px",this.tooltipEle.style.top=h.top+"px"},t.prototype.keyDown=function(e){this.tooltipEle&&27===e.keyCode&&this.close()},t.prototype.touchEnd=function(e){this.tooltipEle&&null===J(e.target,"."+RE)&&!this.isSticky&&this.close()},t.prototype.scrollHandler=function(e){this.tooltipEle&&!this.isSticky&&!J(e.target,"."+HE+"."+G0+"."+_E)&&!this.isSticky&&this.close()},t.prototype.render=function(){this.initialize(),this.wireEvents(this.opensOn),this.renderComplete()},t.prototype.preRender=function(){this.tipClass=Gg,this.tooltipPositionX="Center",this.tooltipPositionY="Top",this.isHidden=!0},t.prototype.wireEvents=function(e){for(var r=0,s=this.getTriggerList(e);r0)for(var i=0,r=e;i0)for(var i=0,r=e;i0&&this.condition&&-1!==this.condition.indexOf("not")&&(e[s].condition=e[s].condition?e[s].condition+"not":"not"),i=e[s].validate(t),r){if(!i)return!1}else if(i)return!0;return r},n.prototype.toJson=function(){var t,e;if(this.isComplex){t=[],e=this.predicates;for(var i=0;ie.length-3?(e=e.substring(0,e.length-1),n.endsWith(n.toLowerCase(t),n.toLowerCase(e))):(e.lastIndexOf("%")!==e.indexOf("%")&&e.lastIndexOf("%")>e.indexOf("%")+1&&(e=e.substring(e.indexOf("%")+1,e.lastIndexOf("%"))),-1!==t.indexOf(e)))},n.fnSort=function(t){return"ascending"===(t=t?n.toLowerCase(t):"ascending")?this.fnAscending:this.fnDescending},n.fnAscending=function(t,e){return m(t)&&m(e)||null==e?-1:"string"==typeof t?t.localeCompare(e):null==t?1:t-e},n.fnDescending=function(t,e){return m(t)&&m(e)?-1:null==e?1:"string"==typeof t?-1*t.localeCompare(e):null==t?-1:e-t},n.extractFields=function(t,e){for(var i={},r=0;r0||e.length>0;)o=t.length>0&&e.length>0?r?r(this.getVal(t,0,i),this.getVal(e,0,i),t[0],e[0])<=0?t:e:t[0][i]0?t:e,s.push(o.shift());return s},n.getVal=function(t,e,i){return i?this.getObject(i,t[e]):t[e]},n.toLowerCase=function(t){return t?"string"==typeof t?t.toLowerCase():t.toString():0===t||!1===t?t.toString():""},n.callAdaptorFunction=function(t,e,i,r){if(e in t){var s=t[e](i,r);m(s)||(i=s)}return i},n.getAddParams=function(t,e,i){var r={};return n.callAdaptorFunction(t,"addParams",{dm:e,query:i,params:i?i.params:[],reqParams:r}),r},n.isPlainObject=function(t){return!!t&&t.constructor===Object},n.isCors=function(){var t=null;try{t=new window.XMLHttpRequest}catch{}return!!t&&"withCredentials"in t},n.getGuid=function(t){var i;return(t||"")+"00000000-0000-4000-0000-000000000000".replace(/0/g,function(r,s){if("crypto"in window&&"getRandomValues"in crypto){var o=new Uint8Array(1);window.crypto.getRandomValues(o),i=o[0]%16|0}else i=16*Math.random()|0;return"0123456789abcdef"[19===s?3&i|8:i]})},n.isNull=function(t){return null==t},n.getItemFromComparer=function(t,e,i){var r,s,o,a=0,l="string"==typeof n.getVal(t,0,e);if(t.length)for(;m(r)&&a0&&(r=s,o=t[a]));return o},n.distinct=function(t,e,i){i=!m(i)&&i;var s,r=[],o={};return t.forEach(function(a,l){(s="object"==typeof t[l]?n.getVal(t,l,e):t[l])in o||(r.push(i?t[l]:s),o[s]=1)}),r},n.processData=function(t,e){var i=this.prepareQuery(t),r=new it(e);t.requiresCounts&&i.requiresCount();var s=r.executeLocal(i),o={result:t.requiresCounts?s.result:s,count:s.count,aggregates:JSON.stringify(s.aggregates)};return t.requiresCounts?o:s},n.prepareQuery=function(t){var e=this,i=new _t;return t.select&&i.select(t.select),t.where&&n.parse.parseJson(t.where).filter(function(o){if(m(o.condition))i.where(o.field,o.operator,o.value,o.ignoreCase,o.ignoreAccent);else{var a=[];o.field?a.push(new Ss(o.field,o.operator,o.value,o.ignoreCase,o.ignoreAccent)):a=a.concat(e.getPredicate(o.predicates)),"or"===o.condition?i.where(Ss.or(a)):"and"===o.condition&&i.where(Ss.and(a))}}),t.search&&n.parse.parseJson(t.search).filter(function(o){return i.search(o.key,o.fields,o.operator,o.ignoreCase,o.ignoreAccent)}),t.aggregates&&t.aggregates.filter(function(o){return i.aggregate(o.type,o.field)}),t.sorted&&t.sorted.filter(function(o){return i.sortBy(o.name,o.direction)}),t.skip&&i.skip(t.skip),t.take&&i.take(t.take),t.group&&t.group.filter(function(o){return i.group(o)}),i},n.getPredicate=function(t){for(var e=[],i=0;i":"greaterthan","<=":"lessthanorequal",">=":"greaterthanorequal","==":"equal","!=":"notequal","*=":"contains","$=":"endswith","^=":"startswith"},n.odBiOperator={"<":" lt ",">":" gt ","<=":" le ",">=":" ge ","==":" eq ","!=":" ne ",lessthan:" lt ",lessthanorequal:" le ",greaterthan:" gt ",greaterthanorequal:" ge ",equal:" eq ",notequal:" ne "},n.odUniOperator={"$=":"endswith","^=":"startswith","*=":"substringof",endswith:"endswith",startswith:"startswith",contains:"substringof",doesnotendwith:"not endswith",doesnotstartwith:"not startswith",doesnotcontain:"not substringof",wildcard:"wildcard",like:"like"},n.odv4UniOperator={"$=":"endswith","^=":"startswith","*=":"contains",endswith:"endswith",startswith:"startswith",contains:"contains",doesnotendwith:"not endswith",doesnotstartwith:"not startswith",doesnotcontain:"not contains",wildcard:"wildcard",like:"like"},n.diacritics={"\u24b6":"A",\uff21:"A",\u00c0:"A",\u00c1:"A",\u00c2:"A",\u1ea6:"A",\u1ea4:"A",\u1eaa:"A",\u1ea8:"A",\u00c3:"A",\u0100:"A",\u0102:"A",\u1eb0:"A",\u1eae:"A",\u1eb4:"A",\u1eb2:"A",\u0226:"A",\u01e0:"A",\u00c4:"A",\u01de:"A",\u1ea2:"A",\u00c5:"A",\u01fa:"A",\u01cd:"A",\u0200:"A",\u0202:"A",\u1ea0:"A",\u1eac:"A",\u1eb6:"A",\u1e00:"A",\u0104:"A",\u023a:"A",\u2c6f:"A",\ua732:"AA",\u00c6:"AE",\u01fc:"AE",\u01e2:"AE",\ua734:"AO",\ua736:"AU",\ua738:"AV",\ua73a:"AV",\ua73c:"AY","\u24b7":"B",\uff22:"B",\u1e02:"B",\u1e04:"B",\u1e06:"B",\u0243:"B",\u0182:"B",\u0181:"B","\u24b8":"C",\uff23:"C",\u0106:"C",\u0108:"C",\u010a:"C",\u010c:"C",\u00c7:"C",\u1e08:"C",\u0187:"C",\u023b:"C",\ua73e:"C","\u24b9":"D",\uff24:"D",\u1e0a:"D",\u010e:"D",\u1e0c:"D",\u1e10:"D",\u1e12:"D",\u1e0e:"D",\u0110:"D",\u018b:"D",\u018a:"D",\u0189:"D",\ua779:"D",\u01f1:"DZ",\u01c4:"DZ",\u01f2:"Dz",\u01c5:"Dz","\u24ba":"E",\uff25:"E",\u00c8:"E",\u00c9:"E",\u00ca:"E",\u1ec0:"E",\u1ebe:"E",\u1ec4:"E",\u1ec2:"E",\u1ebc:"E",\u0112:"E",\u1e14:"E",\u1e16:"E",\u0114:"E",\u0116:"E",\u00cb:"E",\u1eba:"E",\u011a:"E",\u0204:"E",\u0206:"E",\u1eb8:"E",\u1ec6:"E",\u0228:"E",\u1e1c:"E",\u0118:"E",\u1e18:"E",\u1e1a:"E",\u0190:"E",\u018e:"E","\u24bb":"F",\uff26:"F",\u1e1e:"F",\u0191:"F",\ua77b:"F","\u24bc":"G",\uff27:"G",\u01f4:"G",\u011c:"G",\u1e20:"G",\u011e:"G",\u0120:"G",\u01e6:"G",\u0122:"G",\u01e4:"G",\u0193:"G",\ua7a0:"G",\ua77d:"G",\ua77e:"G","\u24bd":"H",\uff28:"H",\u0124:"H",\u1e22:"H",\u1e26:"H",\u021e:"H",\u1e24:"H",\u1e28:"H",\u1e2a:"H",\u0126:"H",\u2c67:"H",\u2c75:"H",\ua78d:"H","\u24be":"I",\uff29:"I",\u00cc:"I",\u00cd:"I",\u00ce:"I",\u0128:"I",\u012a:"I",\u012c:"I",\u0130:"I",\u00cf:"I",\u1e2e:"I",\u1ec8:"I",\u01cf:"I",\u0208:"I",\u020a:"I",\u1eca:"I",\u012e:"I",\u1e2c:"I",\u0197:"I","\u24bf":"J",\uff2a:"J",\u0134:"J",\u0248:"J","\u24c0":"K",\uff2b:"K",\u1e30:"K",\u01e8:"K",\u1e32:"K",\u0136:"K",\u1e34:"K",\u0198:"K",\u2c69:"K",\ua740:"K",\ua742:"K",\ua744:"K",\ua7a2:"K","\u24c1":"L",\uff2c:"L",\u013f:"L",\u0139:"L",\u013d:"L",\u1e36:"L",\u1e38:"L",\u013b:"L",\u1e3c:"L",\u1e3a:"L",\u0141:"L",\u023d:"L",\u2c62:"L",\u2c60:"L",\ua748:"L",\ua746:"L",\ua780:"L",\u01c7:"LJ",\u01c8:"Lj","\u24c2":"M",\uff2d:"M",\u1e3e:"M",\u1e40:"M",\u1e42:"M",\u2c6e:"M",\u019c:"M","\u24c3":"N",\uff2e:"N",\u01f8:"N",\u0143:"N",\u00d1:"N",\u1e44:"N",\u0147:"N",\u1e46:"N",\u0145:"N",\u1e4a:"N",\u1e48:"N",\u0220:"N",\u019d:"N",\ua790:"N",\ua7a4:"N",\u01ca:"NJ",\u01cb:"Nj","\u24c4":"O",\uff2f:"O",\u00d2:"O",\u00d3:"O",\u00d4:"O",\u1ed2:"O",\u1ed0:"O",\u1ed6:"O",\u1ed4:"O",\u00d5:"O",\u1e4c:"O",\u022c:"O",\u1e4e:"O",\u014c:"O",\u1e50:"O",\u1e52:"O",\u014e:"O",\u022e:"O",\u0230:"O",\u00d6:"O",\u022a:"O",\u1ece:"O",\u0150:"O",\u01d1:"O",\u020c:"O",\u020e:"O",\u01a0:"O",\u1edc:"O",\u1eda:"O",\u1ee0:"O",\u1ede:"O",\u1ee2:"O",\u1ecc:"O",\u1ed8:"O",\u01ea:"O",\u01ec:"O",\u00d8:"O",\u01fe:"O",\u0186:"O",\u019f:"O",\ua74a:"O",\ua74c:"O",\u01a2:"OI",\ua74e:"OO",\u0222:"OU","\u24c5":"P",\uff30:"P",\u1e54:"P",\u1e56:"P",\u01a4:"P",\u2c63:"P",\ua750:"P",\ua752:"P",\ua754:"P","\u24c6":"Q",\uff31:"Q",\ua756:"Q",\ua758:"Q",\u024a:"Q","\u24c7":"R",\uff32:"R",\u0154:"R",\u1e58:"R",\u0158:"R",\u0210:"R",\u0212:"R",\u1e5a:"R",\u1e5c:"R",\u0156:"R",\u1e5e:"R",\u024c:"R",\u2c64:"R",\ua75a:"R",\ua7a6:"R",\ua782:"R","\u24c8":"S",\uff33:"S",\u1e9e:"S",\u015a:"S",\u1e64:"S",\u015c:"S",\u1e60:"S",\u0160:"S",\u1e66:"S",\u1e62:"S",\u1e68:"S",\u0218:"S",\u015e:"S",\u2c7e:"S",\ua7a8:"S",\ua784:"S","\u24c9":"T",\uff34:"T",\u1e6a:"T",\u0164:"T",\u1e6c:"T",\u021a:"T",\u0162:"T",\u1e70:"T",\u1e6e:"T",\u0166:"T",\u01ac:"T",\u01ae:"T",\u023e:"T",\ua786:"T",\ua728:"TZ","\u24ca":"U",\uff35:"U",\u00d9:"U",\u00da:"U",\u00db:"U",\u0168:"U",\u1e78:"U",\u016a:"U",\u1e7a:"U",\u016c:"U",\u00dc:"U",\u01db:"U",\u01d7:"U",\u01d5:"U",\u01d9:"U",\u1ee6:"U",\u016e:"U",\u0170:"U",\u01d3:"U",\u0214:"U",\u0216:"U",\u01af:"U",\u1eea:"U",\u1ee8:"U",\u1eee:"U",\u1eec:"U",\u1ef0:"U",\u1ee4:"U",\u1e72:"U",\u0172:"U",\u1e76:"U",\u1e74:"U",\u0244:"U","\u24cb":"V",\uff36:"V",\u1e7c:"V",\u1e7e:"V",\u01b2:"V",\ua75e:"V",\u0245:"V",\ua760:"VY","\u24cc":"W",\uff37:"W",\u1e80:"W",\u1e82:"W",\u0174:"W",\u1e86:"W",\u1e84:"W",\u1e88:"W",\u2c72:"W","\u24cd":"X",\uff38:"X",\u1e8a:"X",\u1e8c:"X","\u24ce":"Y",\uff39:"Y",\u1ef2:"Y",\u00dd:"Y",\u0176:"Y",\u1ef8:"Y",\u0232:"Y",\u1e8e:"Y",\u0178:"Y",\u1ef6:"Y",\u1ef4:"Y",\u01b3:"Y",\u024e:"Y",\u1efe:"Y","\u24cf":"Z",\uff3a:"Z",\u0179:"Z",\u1e90:"Z",\u017b:"Z",\u017d:"Z",\u1e92:"Z",\u1e94:"Z",\u01b5:"Z",\u0224:"Z",\u2c7f:"Z",\u2c6b:"Z",\ua762:"Z","\u24d0":"a",\uff41:"a",\u1e9a:"a",\u00e0:"a",\u00e1:"a",\u00e2:"a",\u1ea7:"a",\u1ea5:"a",\u1eab:"a",\u1ea9:"a",\u00e3:"a",\u0101:"a",\u0103:"a",\u1eb1:"a",\u1eaf:"a",\u1eb5:"a",\u1eb3:"a",\u0227:"a",\u01e1:"a",\u00e4:"a",\u01df:"a",\u1ea3:"a",\u00e5:"a",\u01fb:"a",\u01ce:"a",\u0201:"a",\u0203:"a",\u1ea1:"a",\u1ead:"a",\u1eb7:"a",\u1e01:"a",\u0105:"a",\u2c65:"a",\u0250:"a",\ua733:"aa",\u00e6:"ae",\u01fd:"ae",\u01e3:"ae",\ua735:"ao",\ua737:"au",\ua739:"av",\ua73b:"av",\ua73d:"ay","\u24d1":"b",\uff42:"b",\u1e03:"b",\u1e05:"b",\u1e07:"b",\u0180:"b",\u0183:"b",\u0253:"b","\u24d2":"c",\uff43:"c",\u0107:"c",\u0109:"c",\u010b:"c",\u010d:"c",\u00e7:"c",\u1e09:"c",\u0188:"c",\u023c:"c",\ua73f:"c",\u2184:"c","\u24d3":"d",\uff44:"d",\u1e0b:"d",\u010f:"d",\u1e0d:"d",\u1e11:"d",\u1e13:"d",\u1e0f:"d",\u0111:"d",\u018c:"d",\u0256:"d",\u0257:"d",\ua77a:"d",\u01f3:"dz",\u01c6:"dz","\u24d4":"e",\uff45:"e",\u00e8:"e",\u00e9:"e",\u00ea:"e",\u1ec1:"e",\u1ebf:"e",\u1ec5:"e",\u1ec3:"e",\u1ebd:"e",\u0113:"e",\u1e15:"e",\u1e17:"e",\u0115:"e",\u0117:"e",\u00eb:"e",\u1ebb:"e",\u011b:"e",\u0205:"e",\u0207:"e",\u1eb9:"e",\u1ec7:"e",\u0229:"e",\u1e1d:"e",\u0119:"e",\u1e19:"e",\u1e1b:"e",\u0247:"e",\u025b:"e",\u01dd:"e","\u24d5":"f",\uff46:"f",\u1e1f:"f",\u0192:"f",\ua77c:"f","\u24d6":"g",\uff47:"g",\u01f5:"g",\u011d:"g",\u1e21:"g",\u011f:"g",\u0121:"g",\u01e7:"g",\u0123:"g",\u01e5:"g",\u0260:"g",\ua7a1:"g",\u1d79:"g",\ua77f:"g","\u24d7":"h",\uff48:"h",\u0125:"h",\u1e23:"h",\u1e27:"h",\u021f:"h",\u1e25:"h",\u1e29:"h",\u1e2b:"h",\u1e96:"h",\u0127:"h",\u2c68:"h",\u2c76:"h",\u0265:"h",\u0195:"hv","\u24d8":"i",\uff49:"i",\u00ec:"i",\u00ed:"i",\u00ee:"i",\u0129:"i",\u012b:"i",\u012d:"i",\u00ef:"i",\u1e2f:"i",\u1ec9:"i",\u01d0:"i",\u0209:"i",\u020b:"i",\u1ecb:"i",\u012f:"i",\u1e2d:"i",\u0268:"i",\u0131:"i","\u24d9":"j",\uff4a:"j",\u0135:"j",\u01f0:"j",\u0249:"j","\u24da":"k",\uff4b:"k",\u1e31:"k",\u01e9:"k",\u1e33:"k",\u0137:"k",\u1e35:"k",\u0199:"k",\u2c6a:"k",\ua741:"k",\ua743:"k",\ua745:"k",\ua7a3:"k","\u24db":"l",\uff4c:"l",\u0140:"l",\u013a:"l",\u013e:"l",\u1e37:"l",\u1e39:"l",\u013c:"l",\u1e3d:"l",\u1e3b:"l",\u017f:"l",\u0142:"l",\u019a:"l",\u026b:"l",\u2c61:"l",\ua749:"l",\ua781:"l",\ua747:"l",\u01c9:"lj","\u24dc":"m",\uff4d:"m",\u1e3f:"m",\u1e41:"m",\u1e43:"m",\u0271:"m",\u026f:"m","\u24dd":"n",\uff4e:"n",\u01f9:"n",\u0144:"n",\u00f1:"n",\u1e45:"n",\u0148:"n",\u1e47:"n",\u0146:"n",\u1e4b:"n",\u1e49:"n",\u019e:"n",\u0272:"n",\u0149:"n",\ua791:"n",\ua7a5:"n",\u01cc:"nj","\u24de":"o",\uff4f:"o",\u00f2:"o",\u00f3:"o",\u00f4:"o",\u1ed3:"o",\u1ed1:"o",\u1ed7:"o",\u1ed5:"o",\u00f5:"o",\u1e4d:"o",\u022d:"o",\u1e4f:"o",\u014d:"o",\u1e51:"o",\u1e53:"o",\u014f:"o",\u022f:"o",\u0231:"o",\u00f6:"o",\u022b:"o",\u1ecf:"o",\u0151:"o",\u01d2:"o",\u020d:"o",\u020f:"o",\u01a1:"o",\u1edd:"o",\u1edb:"o",\u1ee1:"o",\u1edf:"o",\u1ee3:"o",\u1ecd:"o",\u1ed9:"o",\u01eb:"o",\u01ed:"o",\u00f8:"o",\u01ff:"o",\u0254:"o",\ua74b:"o",\ua74d:"o",\u0275:"o",\u01a3:"oi",\u0223:"ou",\ua74f:"oo","\u24df":"p",\uff50:"p",\u1e55:"p",\u1e57:"p",\u01a5:"p",\u1d7d:"p",\ua751:"p",\ua753:"p",\ua755:"p","\u24e0":"q",\uff51:"q",\u024b:"q",\ua757:"q",\ua759:"q","\u24e1":"r",\uff52:"r",\u0155:"r",\u1e59:"r",\u0159:"r",\u0211:"r",\u0213:"r",\u1e5b:"r",\u1e5d:"r",\u0157:"r",\u1e5f:"r",\u024d:"r",\u027d:"r",\ua75b:"r",\ua7a7:"r",\ua783:"r","\u24e2":"s",\uff53:"s",\u00df:"s",\u015b:"s",\u1e65:"s",\u015d:"s",\u1e61:"s",\u0161:"s",\u1e67:"s",\u1e63:"s",\u1e69:"s",\u0219:"s",\u015f:"s",\u023f:"s",\ua7a9:"s",\ua785:"s",\u1e9b:"s","\u24e3":"t",\uff54:"t",\u1e6b:"t",\u1e97:"t",\u0165:"t",\u1e6d:"t",\u021b:"t",\u0163:"t",\u1e71:"t",\u1e6f:"t",\u0167:"t",\u01ad:"t",\u0288:"t",\u2c66:"t",\ua787:"t",\ua729:"tz","\u24e4":"u",\uff55:"u",\u00f9:"u",\u00fa:"u",\u00fb:"u",\u0169:"u",\u1e79:"u",\u016b:"u",\u1e7b:"u",\u016d:"u",\u00fc:"u",\u01dc:"u",\u01d8:"u",\u01d6:"u",\u01da:"u",\u1ee7:"u",\u016f:"u",\u0171:"u",\u01d4:"u",\u0215:"u",\u0217:"u",\u01b0:"u",\u1eeb:"u",\u1ee9:"u",\u1eef:"u",\u1eed:"u",\u1ef1:"u",\u1ee5:"u",\u1e73:"u",\u0173:"u",\u1e77:"u",\u1e75:"u",\u0289:"u","\u24e5":"v",\uff56:"v",\u1e7d:"v",\u1e7f:"v",\u028b:"v",\ua75f:"v",\u028c:"v",\ua761:"vy","\u24e6":"w",\uff57:"w",\u1e81:"w",\u1e83:"w",\u0175:"w",\u1e87:"w",\u1e85:"w",\u1e98:"w",\u1e89:"w",\u2c73:"w","\u24e7":"x",\uff58:"x",\u1e8b:"x",\u1e8d:"x","\u24e8":"y",\uff59:"y",\u1ef3:"y",\u00fd:"y",\u0177:"y",\u1ef9:"y",\u0233:"y",\u1e8f:"y",\u00ff:"y",\u1ef7:"y",\u1e99:"y",\u1ef5:"y",\u01b4:"y",\u024f:"y",\u1eff:"y","\u24e9":"z",\uff5a:"z",\u017a:"z",\u1e91:"z",\u017c:"z",\u017e:"z",\u1e93:"z",\u1e95:"z",\u01b6:"z",\u0225:"z",\u0240:"z",\u2c6c:"z",\ua763:"z",\u0386:"\u0391",\u0388:"\u0395",\u0389:"\u0397",\u038a:"\u0399",\u03aa:"\u0399",\u038c:"\u039f",\u038e:"\u03a5",\u03ab:"\u03a5",\u038f:"\u03a9",\u03ac:"\u03b1",\u03ad:"\u03b5",\u03ae:"\u03b7",\u03af:"\u03b9",\u03ca:"\u03b9",\u0390:"\u03b9",\u03cc:"\u03bf",\u03cd:"\u03c5",\u03cb:"\u03c5",\u03b0:"\u03c5",\u03c9:"\u03c9",\u03c2:"\u03c3"},n.fnOperators={equal:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?n.toLowerCase(t)===n.toLowerCase(e):t===e},notequal:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),!n.fnOperators.equal(t,e,i)},lessthan:function(t,e,i){return i?n.toLowerCase(t)n.toLowerCase(e):t>e},lessthanorequal:function(t,e,i){return i?n.toLowerCase(t)<=n.toLowerCase(e):(m(t)&&(t=void 0),t<=e)},greaterthanorequal:function(t,e,i){return i?n.toLowerCase(t)>=n.toLowerCase(e):t>=e},contains:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?!m(t)&&!m(e)&&-1!==n.toLowerCase(t).indexOf(n.toLowerCase(e)):!m(t)&&!m(e)&&-1!==t.toString().indexOf(e)},doesnotcontain:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?!m(t)&&!m(e)&&-1===n.toLowerCase(t).indexOf(n.toLowerCase(e)):!m(t)&&!m(e)&&-1===t.toString().indexOf(e)},isnotnull:function(t){return null!=t},isnull:function(t){return null==t},startswith:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.startsWith(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.startsWith(t,e)},doesnotstartwith:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.notStartsWith(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.notStartsWith(t,e)},like:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.like(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.like(t,e)},isempty:function(t){return void 0===t||""===t},isnotempty:function(t){return void 0!==t&&""!==t},wildcard:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?(t||"boolean"==typeof t)&&e&&"object"!=typeof t&&n.wildCard(n.toLowerCase(t),n.toLowerCase(e)):(t||"boolean"==typeof t)&&e&&n.wildCard(t,e)},endswith:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.endsWith(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.endsWith(t,e)},doesnotendwith:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.notEndsWith(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.notEndsWith(t,e)},processSymbols:function(t){var e=n.operatorSymbols[t];return e?n.fnOperators[e]:n.throwError("Query - Process Operator : Invalid operator")},processOperator:function(t){return n.fnOperators[t]||n.fnOperators.processSymbols(t)}},n.parse={parseJson:function(t){return"string"!=typeof t||!/^[\s]*\[|^[\s]*\{(.)+:/g.test(t)&&-1!==t.indexOf('"')?t instanceof Array?n.parse.iterateAndReviveArray(t):"object"==typeof t&&null!==t&&n.parse.iterateAndReviveJson(t):t=JSON.parse(t,n.parse.jsonReviver),t},iterateAndReviveArray:function(t){for(var e=0;e-1||e.indexOf("z")>-1,o=e.split(/[^0-9.]/);if(s){if(o[5].indexOf(".")>-1){var a=o[5].split(".");o[5]=a[0],o[6]=new Date(e).getUTCMilliseconds().toString()}else o[6]="00";e=n.dateParse.toTimeZone(new Date(parseInt(o[0],10),parseInt(o[1],10)-1,parseInt(o[2],10),parseInt(o[3],10),parseInt(o[4],10),parseInt(o[5]?o[5]:"00",10),parseInt(o[6],10)),n.serverTimezoneOffset,!1)}else{var l=new Date(parseInt(o[0],10),parseInt(o[1],10)-1,parseInt(o[2],10),parseInt(o[3],10),parseInt(o[4],10),parseInt(o[5]?o[5]:"00",10)),h=parseInt(o[6],10),c=parseInt(o[7],10);if(isNaN(h)&&isNaN(c))return l;e.indexOf("+")>-1?l.setHours(l.getHours()-h,l.getMinutes()-c):l.setHours(l.getHours()+h,l.getMinutes()+c),e=n.dateParse.toTimeZone(l,n.serverTimezoneOffset,!1)}null==n.serverTimezoneOffset&&(e=n.dateParse.addSelfOffset(e))}}return e},isJson:function(t){return"string"==typeof t[0]?t:n.parse.parseJson(t)},isGuid:function(t){return null!=/[A-Fa-f0-9]{8}(?:-[A-Fa-f0-9]{4}){3}-[A-Fa-f0-9]{12}/i.exec(t)},replacer:function(t,e){return n.isPlainObject(t)?n.parse.jsonReplacer(t,e):t instanceof Array?n.parse.arrayReplacer(t):t instanceof Date?n.parse.jsonReplacer({val:t},e).val:t},jsonReplacer:function(t,e){for(var i,s=0,o=Object.keys(t);s=0?"+":"-",s=function(a){var l=Math.floor(Math.abs(a));return(l<10?"0":"")+l};return e.getFullYear()+"-"+s(e.getMonth()+1)+"-"+s(e.getDate())+"T"+s(e.getHours())+":"+s(e.getMinutes())+":"+s(e.getSeconds())+r+s(i/60)+":"+s(i%60)}},n}(),Ml=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),xK={GroupGuid:"{271bbba0-1ee7}"},t5=function(){function n(t){this.options={from:"table",requestType:"json",sortBy:"sorted",select:"select",skip:"skip",group:"group",take:"take",search:"search",count:"requiresCounts",where:"where",aggregates:"aggregates",expand:"expand"},this.type=n,this.dataSource=t,this.pvt={}}return n.prototype.processResponse=function(t,e,i,r){return t},n}(),WE=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ml(t,n),t.prototype.processQuery=function(e,i){for(var a,l,f,r=e.dataSource.json.slice(0),s=r.length,o=!0,h={},c=0,d=[],u=[],p=0;p1?e.sort.filter(function(f){return f.fieldName===c})[0]:e.sort[0];s=this.onSortBy(s,d,e.query,!0)}e.page&&(s=this.onPage(s,e.page,e.query)),this.formGroupResult(s,h)}else{for(var o=e.lazyLoad.onDemandGroupInfo,a=o.where.length-1;a>=0;a--)s=this.onWhere(s,o.where[a]);if(e.group.length!==o.level)s=le.group(s,e.group[o.level].fieldName,r,null,null,e.group[o.level].comparer,!0),e.sort.length&&(s=this.onSortBy(s,e.sort[parseInt(o.level.toString(),10)],e.query,!0));else for(a=e.sort.length-1;a>=o.level;a--)s=this.onSortBy(s,e.sort[parseInt(a.toString(),10)],e.query,!1);i=s.length,h=s,s=(s=s.slice(o.skip)).slice(0,o.take),e.group.length!==o.level&&this.formGroupResult(s,h)}return{result:s,count:i}},t.prototype.formGroupResult=function(e,i){if(e.length&&i.length){var r="GroupGuid",s="childLevels",o="level",a="records";e[r]=i[r],e[s]=i[s],e[o]=i[o],e[a]=i[a]}return e},t.prototype.getAggregate=function(e){var i=_t.filterQueries(e.queries,"onAggregates"),r=[];if(i.length)for(var s=void 0,o=0;o=0;l--)a[l]&&(o=i.comparer,le.endsWith(a[l]," desc")&&(o=le.fnSort("descending"),a[l]=a[l].replace(" desc","")),e=le.sort(e,a[l],o));return e}return le.sort(e,s?"key":a,i.comparer)},t.prototype.onGroup=function(e,i,r){if(!e||!e.length)return e;var s=this.getAggregate(r);return le.group(e,le.getValue(i.fieldName,r),s,null,null,i.comparer)},t.prototype.onPage=function(e,i,r){var s=le.getValue(i.pageSize,r),o=(le.getValue(i.pageIndex,r)-1)*s;return e&&e.length?e.slice(o,o+s):e},t.prototype.onRange=function(e,i){return e&&e.length?e.slice(le.getValue(i.start),le.getValue(i.end)):e},t.prototype.onTake=function(e,i){return e&&e.length?e.slice(0,le.getValue(i.nos)):e},t.prototype.onSkip=function(e,i){return e&&e.length?e.slice(le.getValue(i.nos)):e},t.prototype.onSelect=function(e,i){return e&&e.length?le.select(e,le.getValue(i.fieldNames)):e},t.prototype.insert=function(e,i,r,s,o){return m(o)?e.dataSource.json.push(i):e.dataSource.json.splice(o,0,i)},t.prototype.remove=function(e,i,r,s){var a,o=e.dataSource.json;for("object"==typeof r&&!(r instanceof Date)&&(r=le.getObject(i,r)),a=0;a1&&(g="("+g+")"),f.filters.push(g);for(var y=0,S="object"==typeof f.filters[p]?Object.keys(f.filters[p]):[];y-1&&this.formRemoteGroupedData(e[s].items,i+1,r-1);var o="GroupGuid",h="records";return e[o]=xK[o],e.level=i,e.childLevels=r,e[h]=e[0].items.length?this.getGroupedRecords(e,!m(e[0].items[h])):[],e},t.prototype.getGroupedRecords=function(e,i){for(var r=[],o=0;ol.length-3?(l=l.substring(0,l.length-1),o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.endswith:le.odv4UniOperator.endswith):l.lastIndexOf("%")!==l.indexOf("%")&&l.lastIndexOf("%")>l.indexOf("%")+1?(l=l.substring(l.indexOf("%")+1,l.lastIndexOf("%")),o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains):o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains),l="'"+(l=encodeURIComponent(l))+"'";else if("wildcard"===o)if(-1!==l.indexOf("*")){var d=l.split("*"),u=void 0,f=0;if(0!==l.indexOf("*")&&-1===d[0].indexOf("%3f")&&-1===d[0].indexOf("?")&&(u="'"+(u=d[0])+"'",s+=(o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.startswith:le.odv4UniOperator.startswith)+"(",s+=c+",",a&&(s+=a),s+=u+")",f++),l.lastIndexOf("*")!==l.length-1&&-1===d[d.length-1].indexOf("%3f")&&-1===d[d.length-1].indexOf("?")&&(u="'"+(u=d[d.length-1])+"'",f>0&&(s+=" and "),s+=(o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.endswith:le.odv4UniOperator.endswith)+"(",s+=c+",",a&&(s+=a),s+=u+")",f++),d.length>2)for(var p=1;p0&&(s+=" and "),"substringof"===(o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains)||"not substringof"===o){var g=u;u=c,c=g}s+=o+"(",s+=c+",",a&&(s+=a),s+=u+")",f++}0===f?(o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains,(-1!==l.indexOf("?")||-1!==l.indexOf("%3f"))&&(l=-1!==l.indexOf("?")?l.split("?").join(""):l.split("%3f").join("")),l="'"+l+"'"):o="wildcard"}else o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains,(-1!==l.indexOf("?")||-1!==l.indexOf("%3f"))&&(l=-1!==l.indexOf("?")?l.split("?").join(""):l.split("%3f").join("")),l="'"+l+"'";return"substringof"!==o&&"not substringof"!==o||(g=l,l=c,c=g),"wildcard"!==o&&(s+=o+"(",s+=c+",",a&&(s+=a),s+=l+")"),s},t.prototype.addParams=function(e){n.prototype.addParams.call(this,e),delete e.reqParams.params},t.prototype.onComplexPredicate=function(e,i,r){for(var s=[],o=0;o-1;f--)!/\bContent-ID:/i.test(c[f])||!/\bHTTP.+201/.test(c[f])||(l=parseInt(/\bContent-ID: (\d+)/i.exec(c[f])[1],10),o.addedRecords[l]&&(h=le.parse.parseJson(/^\{.+\}/m.exec(c[f])[0]),ze({},o.addedRecords[l],this.processResponse(h))));return o}return null},t.prototype.compareAndRemove=function(e,i,r){var s=this;return m(i)||Object.keys(e).forEach(function(o){o!==r&&"@odata.etag"!==o&&(le.isPlainObject(e[o])?(s.compareAndRemove(e[o],i[o]),0===Object.keys(e[o]).filter(function(l){return"@odata.etag"!==l}).length&&delete e[o]):(e[o]===i[o]||e[o]&&i[o]&&e[o].valueOf()===i[o].valueOf())&&delete e[o])}),e},t}(fc),TK=function(n){function t(){var e=n.call(this)||this;return yt("beforeSend",fc.prototype.beforeSend,e),e}return Ml(t,n),t.prototype.insert=function(e,i,r,s,o){return this.pvt.position=o,this.updateType="add",{url:e.dataSource.insertUrl||e.dataSource.crudUrl||e.dataSource.url,data:JSON.stringify(ze({},{value:i,table:r,action:"insert"},le.getAddParams(this,e,s)))}},t.prototype.remove=function(e,i,r,s,o){return n.prototype.remove.call(this,e,i,r),{type:"POST",url:e.dataSource.removeUrl||e.dataSource.crudUrl||e.dataSource.url,data:JSON.stringify(ze({},{key:r,keyColumn:i,table:s,action:"remove"},le.getAddParams(this,e,o)))}},t.prototype.update=function(e,i,r,s,o){return this.updateType="update",this.updateKey=i,{type:"POST",url:e.dataSource.updateUrl||e.dataSource.crudUrl||e.dataSource.url,data:JSON.stringify(ze({},{value:r,action:"update",keyColumn:i,key:r[i],table:s},le.getAddParams(this,e,o)))}},t.prototype.processResponse=function(e,i,r,s,o,a,l){var h;if(e="batch"===(o?JSON.parse(o.data):e).action?le.parse.parseJson(e):e,"add"===this.updateType&&n.prototype.insert.call(this,i,e,null,null,this.pvt.position),"update"===this.updateType&&n.prototype.update.call(this,i,this.updateKey,e),this.updateType=void 0,e.added)for(h=0;hi&&h.push(c)}for(c=0;cthis.pageSize;)h.results.splice(0,1),h.keys.splice(0,1);return window.localStorage.setItem(this.guidId,JSON.stringify(h)),e},t.prototype.beforeSend=function(e,i,r){!m(this.cacheAdaptor.options.batch)&&le.endsWith(r.url,this.cacheAdaptor.options.batch)&&"post"===r.type.toLowerCase()&&i.headers.set("Accept",this.cacheAdaptor.options.multipartAccept),e.dataSource.crossDomain||i.headers.set("Accept",this.cacheAdaptor.options.accept)},t.prototype.update=function(e,i,r,s){return this.isCrudAction=!0,this.cacheAdaptor.update(e,i,r,s)},t.prototype.insert=function(e,i,r){return this.isInsertAction=!0,this.cacheAdaptor.insert(e,i,r)},t.prototype.remove=function(e,i,r,s){return this.isCrudAction=!0,this.cacheAdaptor.remove(e,i,r,s)},t.prototype.batchRequest=function(e,i,r){return this.cacheAdaptor.batchRequest(e,i,r)},t}(fc),it=function(){function n(t,e,i){var s,r=this;return this.dateParse=!0,this.timeZoneHandling=!0,this.persistQuery={},this.isInitialLoad=!1,this.requests=[],this.isInitialLoad=!0,!t&&!this.dataSource&&(t=[]),i=i||t.adaptor,t&&!1===t.timeZoneHandling&&(this.timeZoneHandling=t.timeZoneHandling),t instanceof Array?s={json:t,offline:!0}:"object"==typeof t?(t.json||(t.json=[]),t.enablePersistence||(t.enablePersistence=!1),t.id||(t.id=""),t.ignoreOnPersist||(t.ignoreOnPersist=[]),s={url:t.url,insertUrl:t.insertUrl,removeUrl:t.removeUrl,updateUrl:t.updateUrl,crudUrl:t.crudUrl,batchUrl:t.batchUrl,json:t.json,headers:t.headers,accept:t.accept,data:t.data,timeTillExpiration:t.timeTillExpiration,cachingPageSize:t.cachingPageSize,enableCaching:t.enableCaching,requestType:t.requestType,key:t.key,crossDomain:t.crossDomain,jsonp:t.jsonp,dataType:t.dataType,offline:void 0!==t.offline?t.offline:!(t.adaptor instanceof TK||t.adaptor instanceof AK||t.url),requiresFormat:t.requiresFormat,enablePersistence:t.enablePersistence,id:t.id,ignoreOnPersist:t.ignoreOnPersist}):le.throwError("DataManager: Invalid arguments"),void 0===s.requiresFormat&&!le.isCors()&&(s.requiresFormat=!!m(s.crossDomain)||s.crossDomain),void 0===s.dataType&&(s.dataType="json"),this.dataSource=s,this.defaultQuery=e,this.dataSource.enablePersistence&&this.dataSource.id&&window.addEventListener("unload",this.setPersistData.bind(this)),s.url&&s.offline&&!s.json.length?(this.isDataAvailable=!1,this.adaptor=i||new pf,this.dataSource.offline=!1,this.ready=this.executeQuery(e||new _t),this.ready.then(function(o){r.dataSource.offline=!0,r.isDataAvailable=!0,s.json=o.result,r.adaptor=new WE})):this.adaptor=s.offline?new WE:new pf,!s.jsonp&&this.adaptor instanceof pf&&(s.jsonp="callback"),this.adaptor=i||this.adaptor,s.enableCaching&&(this.adaptor=new LK(this.adaptor,s.timeTillExpiration,s.cachingPageSize)),this}return Object.defineProperty(n.prototype,"moduleName",{get:function(){return"datamanager"},enumerable:!0,configurable:!0}),n.prototype.getPersistedData=function(t){var e=localStorage.getItem(t||this.dataSource.id);return JSON.parse(e)},n.prototype.setPersistData=function(t,e,i){localStorage.setItem(e||this.dataSource.id,JSON.stringify(i||this.persistQuery))},n.prototype.setPersistQuery=function(t){var e=this,i=this.getPersistedData();if(this.isInitialLoad&&i&&Object.keys(i).length){this.persistQuery=i,this.persistQuery.queries=this.persistQuery.queries.filter(function(s){if(e.dataSource.ignoreOnPersist&&e.dataSource.ignoreOnPersist.length&&s.fn&&e.dataSource.ignoreOnPersist.some(function(l){return s.fn===l}))return!1;if("onWhere"===s.fn){var o=s.e;if(o&&o.isComplex&&o.predicates instanceof Array){var a=o.predicates.map(function(l){if(l.predicates&&l.predicates instanceof Array){var h=l.predicates.map(function(v){return new Ss(v.field,v.operator,v.value,v.ignoreCase,v.ignoreAccent,v.matchCase)});return"and"===l.condition?Ss.and(h):Ss.or(h)}return new Ss(l.field,l.operator,l.value,l.ignoreCase,l.ignoreAccent,l.matchCase)});s.e=new Ss(a[0],o.condition,a.slice(1))}}return!0});var r=ze(new _t,this.persistQuery);return this.isInitialLoad=!1,r}return this.persistQuery=t,this.isInitialLoad=!1,t},n.prototype.setDefaultQuery=function(t){return this.defaultQuery=t,this},n.prototype.executeLocal=function(t){!this.defaultQuery&&!(t instanceof _t)&&le.throwError("DataManager - executeLocal() : A query is required to execute"),this.dataSource.json||le.throwError("DataManager - executeLocal() : Json data is required to execute"),this.dataSource.enablePersistence&&this.dataSource.id&&(t=this.setPersistQuery(t));var e=this.adaptor.processQuery(this,t=t||this.defaultQuery);if(t.subQuery){var i=t.subQuery.fromTable,r=t.subQuery.lookups,s=t.isCountRequired?e.result:e;r&&r instanceof Array&&le.buildHierarchy(t.subQuery.fKey,i,s,r,t.subQuery.key);for(var o=0;oli");z.classList.remove("json-parent");for(var j=0;j',W=ve.children[0].placeholder}return W}function Q(k,W,ve){!m(ve)&&""!==ve&&K(W,ve.split(" ")),!m(k)&&""!==k&&V(W,k.split(" "))}function oe(k,W,ve){if("multiselect"===ve||function Mo(k){if(!k)return!1;for(var W=k;W&&W!==document.body;){if("none"===window.getComputedStyle(W).display)return!1;W=W.parentElement}return!0}(k)){var Te="multiselect"===ve?k:k.clientWidth-parseInt(getComputedStyle(k,null).getPropertyValue("padding-left"),10);!m(W)&&!m(W.getElementsByClassName("e-float-text-content")[0])&&(W.getElementsByClassName("e-float-text-content")[0].classList.contains("e-float-text-overflow")&&W.getElementsByClassName("e-float-text-content")[0].classList.remove("e-float-text-overflow"),(Te0)for(var Ye=0;Ye<_e.length;Ye++)_e[parseInt(Ye.toString(),10)].addEventListener("mousedown",wo,!1),_e[parseInt(Ye.toString(),10)].addEventListener("mouseup",Ul,!1);else if(_e.length>0)for(Ye=0;Ye<_e.length;Ye++)_e[parseInt(Ye.toString(),10)].removeEventListener("mousedown",wo,this),_e[parseInt(Ye.toString(),10)].removeEventListener("mouseup",Ul,this)}function wo(){for(var W=this.parentElement;!W.classList.contains("e-input-group");)W=W.parentElement;!function Sa(k,W){!k.classList.contains("e-disabled")&&!k.querySelector("input").readOnly&&W.classList.add("e-input-btn-ripple")}(W,this)}function Ul(){var k=this;setTimeout(function(){k.classList.remove("e-input-btn-ripple")},500)}function gb(k,W){var ve=W("span",{className:k});return ve.classList.add("e-input-group-icon"),ve}function y_(k,W,ve,Te){var _e=m(Te)?Si:Te,Ye=gb(k,_e);W.classList.add("e-float-icon-left");var vi=W.querySelector(".e-input-in-wrap");if(m(vi)){vi=_e("span",{className:"e-input-in-wrap"}),ve.parentNode.insertBefore(vi,ve);var Gs=W.querySelectorAll(ve.tagName+" ~ *");vi.appendChild(ve);for(var ts=0;ts-1)if("class"===_e){var Ye=this.getInputValidClassList(k[""+_e]);""!==Ye&&V([W],Ye.split(" "))}else if("style"===_e){var vi=W.getAttribute(_e);vi=m(vi)?k[""+_e]:vi+k[""+_e],W.setAttribute(_e,vi)}else W.setAttribute(_e,k[""+_e])}},n.isBlank=function Hle(k){return!k||/^\s*$/.test(k)}}(Le||(Le={})),new RegExp("^(-)?(\\d*)$"),new RegExp("^[A-Za-z0-9._%+-]{1,}@[A-Za-z0-9._%+-]{1,}([.]{1}[a-zA-Z0-9]{2,}|[.]{1}[a-zA-Z0-9]{2,4}[.]{1}[a-zA-Z0-9]{2,4})$"),new RegExp("^([0-9]{4})-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])$"),new RegExp("^[0-9]*$"),new RegExp("^[+]?[0-9]{9,13}$"),new RegExp("^\\d{13,16}$");var me=function(){function n(t,e){this.width=t,this.height=e}return n.prototype.isEmpty=function(){return 0===this.height&&0===this.width},n.prototype.clone=function(){return new n(this.width,this.height)},n}(),Eie=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),GB=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},R=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Eie(t,n),t.equals=function(e,i){return e===i||!(!e||!i)&&(!e||!i||e.x===i.x&&e.y===i.y)},t.isEmptyPoint=function(e){return!(e.x&&e.y)},t.transform=function(e,i,r){var s={x:0,y:0};return s.x=Math.round(100*(e.x+r*Math.cos(i*Math.PI/180)))/100,s.y=Math.round(100*(e.y+r*Math.sin(i*Math.PI/180)))/100,s},t.findLength=function(e,i){return Math.sqrt(Math.pow(e.x-i.x,2)+Math.pow(e.y-i.y,2))},t.findAngle=function(e,i){var r=Math.atan2(i.y-e.y,i.x-e.x);return r=180*r/Math.PI,(r%=360)<0&&(r+=360),r},t.distancePoints=function(e,i){return Math.sqrt(Math.pow(i.x-e.x,2)+Math.pow(i.y-e.y,2))},t.getLengthFromListOfPoints=function(e){for(var i=0,r=0;ri.y&&!r?o.y+=s:o.y-=s:e.y===i.y?e.xi.x&&!r?o.x+=s:o.x-=s:r?(a=this.findAngle(e,i),o=this.transform(e,a,s)):(a=this.findAngle(i,e),o=this.transform(i,a,s)),o},t.direction=function(e,i){return Math.abs(i.x-e.x)>Math.abs(i.y-e.y)?e.x0)for(var r=0;rt.right||this.top>t.bottom||this.bottom=t.right&&this.top<=t.top&&this.bottom>=t.bottom},n.prototype.containsPoint=function(t,e){return void 0===e&&(e=0),this.left-e<=t.x&&this.right+e>=t.x&&this.top-e<=t.y&&this.bottom+e>=t.y},n.toBounds=function(t){for(var e=new n,i=0,r=t;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},KB=function(n){if(n)switch(n.type){case"Linear":default:return yI;case"Radial":return Rie}return yI},Pie=function(){return function n(t,e,i,r){this.left=t,this.right=e,this.top=i,this.bottom=r}}(),Jn=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),rt([I(0)],t.prototype,"left",void 0),rt([I(0)],t.prototype,"right",void 0),rt([I(0)],t.prototype,"top",void 0),rt([I(0)],t.prototype,"bottom",void 0),t}(Ee),zie=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),rt([I(45)],t.prototype,"angle",void 0),rt([I(5)],t.prototype,"distance",void 0),rt([I(.7)],t.prototype,"opacity",void 0),rt([I("lightgrey")],t.prototype,"color",void 0),t}(Ee),e3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),t.prototype.getClassName=function(){return"Stop"},rt([I("")],t.prototype,"color",void 0),rt([I(0)],t.prototype,"offset",void 0),rt([I(1)],t.prototype,"opacity",void 0),t}(Ee),Ix=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),rt([Bt([],e3)],t.prototype,"stops",void 0),rt([I("None")],t.prototype,"type",void 0),rt([I("")],t.prototype,"id",void 0),t}(Ee),yI=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),rt([I(0)],t.prototype,"x1",void 0),rt([I(0)],t.prototype,"x2",void 0),rt([I(0)],t.prototype,"y1",void 0),rt([I(0)],t.prototype,"y2",void 0),t}(Ix),Rie=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),rt([I(0)],t.prototype,"cx",void 0),rt([I(0)],t.prototype,"cy",void 0),rt([I(0)],t.prototype,"fx",void 0),rt([I(0)],t.prototype,"fy",void 0),rt([I(50)],t.prototype,"r",void 0),t}(Ix),Ll=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),rt([I("white")],t.prototype,"fill",void 0),rt([I("black")],t.prototype,"strokeColor",void 0),rt([I("")],t.prototype,"strokeDashArray",void 0),rt([I(1)],t.prototype,"strokeWidth",void 0),rt([I(1)],t.prototype,"opacity",void 0),rt([E0(KB)],t.prototype,"gradient",void 0),t}(Ee),t3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),rt([I("transparent")],t.prototype,"fill",void 0),t}(Ll),Qf=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),rt([I("black")],t.prototype,"color",void 0),rt([I("Arial")],t.prototype,"fontFamily",void 0),rt([I(12)],t.prototype,"fontSize",void 0),rt([I(!1)],t.prototype,"italic",void 0),rt([I(!1)],t.prototype,"bold",void 0),rt([I("CollapseSpace")],t.prototype,"whiteSpace",void 0),rt([I("WrapWithOverflow")],t.prototype,"textWrapping",void 0),rt([I("Center")],t.prototype,"textAlign",void 0),rt([I("None")],t.prototype,"textDecoration",void 0),rt([I("Wrap")],t.prototype,"textOverflow",void 0),rt([I("transparent")],t.prototype,"fill",void 0),t}(Ll),on=function(n){return n[n.Default=0]="Default",n[n.expandNode=2]="expandNode",n[n.interaction=4]="interaction",n[n.GroupingInProgress=8]="GroupingInProgress",n[n.GroupClipboardInProcess=16]="GroupClipboardInProcess",n[n.ClearObject=32]="ClearObject",n}(on||{}),oi=function(n){return n[n.Visible=1]="Visible",n[n.Hidden=2]="Hidden",n[n.Hover=4]="Hover",n[n.Connect=8]="Connect",n}(oi||{}),Kt=function(n){return n[n.None=0]="None",n[n.ShowHorizontalLines=1]="ShowHorizontalLines",n[n.ShowVerticalLines=2]="ShowVerticalLines",n[n.ShowLines=3]="ShowLines",n[n.SnapToHorizontalLines=4]="SnapToHorizontalLines",n[n.SnapToVerticalLines=8]="SnapToVerticalLines",n[n.SnapToLines=12]="SnapToLines",n[n.SnapToObject=16]="SnapToObject",n[n.All=31]="All",n}(Kt||{}),mr=function(n){return n[n.None=1]="None",n[n.ConnectorSourceThumb=2]="ConnectorSourceThumb",n[n.ConnectorTargetThumb=4]="ConnectorTargetThumb",n[n.ResizeSouthEast=8]="ResizeSouthEast",n[n.ResizeSouthWest=16]="ResizeSouthWest",n[n.ResizeNorthEast=32]="ResizeNorthEast",n[n.ResizeNorthWest=64]="ResizeNorthWest",n[n.ResizeEast=128]="ResizeEast",n[n.ResizeWest=256]="ResizeWest",n[n.ResizeSouth=512]="ResizeSouth",n[n.ResizeNorth=1024]="ResizeNorth",n[n.Rotate=2048]="Rotate",n[n.UserHandle=4096]="UserHandle",n[n.ToolTip=8192]="ToolTip",n[n.ResizeAll=2046]="ResizeAll",n[n.All=16382]="All",n}(mr||{}),qe=function(n){return n[n.None=1]="None",n[n.Select=2]="Select",n[n.Delete=4]="Delete",n[n.Drag=8]="Drag",n[n.DragSourceEnd=16]="DragSourceEnd",n[n.DragTargetEnd=32]="DragTargetEnd",n[n.DragSegmentThumb=64]="DragSegmentThumb",n[n.AllowDrop=128]="AllowDrop",n[n.Bridging=256]="Bridging",n[n.BridgeObstacle=512]="BridgeObstacle",n[n.InheritBridging=1024]="InheritBridging",n[n.PointerEvents=2048]="PointerEvents",n[n.Tooltip=4096]="Tooltip",n[n.InheritTooltip=8192]="InheritTooltip",n[n.Interaction=4218]="Interaction",n[n.ReadOnly=16384]="ReadOnly",n[n.LineRouting=32768]="LineRouting",n[n.InheritLineRouting=65536]="InheritLineRouting",n[n.ConnectToNearByNode=131072]="ConnectToNearByNode",n[n.ConnectToNearByPort=262144]="ConnectToNearByPort",n[n.ConnectToNearByElement=393216]="ConnectToNearByElement",n[n.InheritSegmentThumbShape=524288]="InheritSegmentThumbShape",n[n.InheritSegmentThumbSize=1048576]="InheritSegmentThumbSize",n[n.Default=2043454]="Default",n}(qe||{}),Nr=function(n){return n[n.ReadOnly=2]="ReadOnly",n[n.InheritReadOnly=4]="InheritReadOnly",n[n.Select=8]="Select",n[n.Drag=16]="Drag",n[n.Resize=32]="Resize",n[n.Rotate=64]="Rotate",n[n.Tooltip=128]="Tooltip",n[n.Interaction=120]="Interaction",n[n.None=0]="None",n}(Nr||{}),ie=function(n){return n[n.None=0]="None",n[n.Select=2]="Select",n[n.Drag=4]="Drag",n[n.Rotate=8]="Rotate",n[n.Shadow=16]="Shadow",n[n.PointerEvents=32]="PointerEvents",n[n.Delete=64]="Delete",n[n.InConnect=128]="InConnect",n[n.OutConnect=256]="OutConnect",n[n.Individual=512]="Individual",n[n.Expandable=1024]="Expandable",n[n.AllowDrop=2048]="AllowDrop",n[n.Inherit=78]="Inherit",n[n.ResizeNorthEast=4096]="ResizeNorthEast",n[n.ResizeEast=8192]="ResizeEast",n[n.ResizeSouthEast=16384]="ResizeSouthEast",n[n.ResizeSouth=32768]="ResizeSouth",n[n.ResizeSouthWest=65536]="ResizeSouthWest",n[n.ResizeWest=131072]="ResizeWest",n[n.ResizeNorthWest=262144]="ResizeNorthWest",n[n.ResizeNorth=524288]="ResizeNorth",n[n.Resize=1044480]="Resize",n[n.AspectRatio=1048576]="AspectRatio",n[n.Tooltip=2097152]="Tooltip",n[n.InheritTooltip=4194304]="InheritTooltip",n[n.ReadOnly=8388608]="ReadOnly",n[n.HideThumbs=16777216]="HideThumbs",n[n.AllowMovingOutsideLane=33554432]="AllowMovingOutsideLane",n[n.Default=5240814]="Default",n}(ie||{}),Xr=function(n){return n[n.None=0]="None",n[n.ElementIsPort=2]="ElementIsPort",n[n.ElementIsGroup=4]="ElementIsGroup",n[n.HorizontalLaneHeader=8]="HorizontalLaneHeader",n}(Xr||{}),bt=function(n){return n[n.Rotate=2]="Rotate",n[n.ConnectorSource=4]="ConnectorSource",n[n.ConnectorTarget=8]="ConnectorTarget",n[n.ResizeNorthEast=16]="ResizeNorthEast",n[n.ResizeEast=32]="ResizeEast",n[n.ResizeSouthEast=64]="ResizeSouthEast",n[n.ResizeSouth=128]="ResizeSouth",n[n.ResizeSouthWest=256]="ResizeSouthWest",n[n.ResizeWest=512]="ResizeWest",n[n.ResizeNorthWest=1024]="ResizeNorthWest",n[n.ResizeNorth=2048]="ResizeNorth",n[n.Default=4094]="Default",n}(bt||{}),nt=function(n){return n[n.None=1]="None",n[n.Bridging=2]="Bridging",n[n.UndoRedo=4]="UndoRedo",n[n.Tooltip=8]="Tooltip",n[n.UserInteraction=16]="UserInteraction",n[n.ApiUpdate=32]="ApiUpdate",n[n.PageEditable=48]="PageEditable",n[n.Zoom=64]="Zoom",n[n.PanX=128]="PanX",n[n.PanY=256]="PanY",n[n.Pan=384]="Pan",n[n.ZoomTextEdit=512]="ZoomTextEdit",n[n.Virtualization=1024]="Virtualization",n[n.LineRouting=2048]="LineRouting",n[n.Default=500]="Default",n}(nt||{}),ri=function(n){return n[n.None=0]="None",n[n.SingleSelect=1]="SingleSelect",n[n.MultipleSelect=2]="MultipleSelect",n[n.ZoomPan=4]="ZoomPan",n[n.DrawOnce=8]="DrawOnce",n[n.ContinuousDraw=16]="ContinuousDraw",n[n.Default=3]="Default",n}(ri||{}),Qa=function(n){return n[n.Self=1]="Self",n[n.Parent=2]="Parent",n}(Qa||{}),ft=function(n){return n[n.None=0]="None",n[n.Control=1]="Control",n[n.Meta=1]="Meta",n[n.Alt=2]="Alt",n[n.Shift=4]="Shift",n}(ft||{}),Mt=function(n){return n[n.None=null]="None",n[n.Number0=0]="Number0",n[n.Number1=1]="Number1",n[n.Number2=2]="Number2",n[n.Number3=3]="Number3",n[n.Number4=4]="Number4",n[n.Number5=5]="Number5",n[n.Number6=6]="Number6",n[n.Number7=7]="Number7",n[n.Number8=8]="Number8",n[n.Number9=9]="Number9",n[n.A=65]="A",n[n.B=66]="B",n[n.C=67]="C",n[n.D=68]="D",n[n.E=69]="E",n[n.F=70]="F",n[n.G=71]="G",n[n.H=72]="H",n[n.I=73]="I",n[n.J=74]="J",n[n.K=75]="K",n[n.L=76]="L",n[n.M=77]="M",n[n.N=78]="N",n[n.O=79]="O",n[n.P=80]="P",n[n.Q=81]="Q",n[n.R=82]="R",n[n.S=83]="S",n[n.T=84]="T",n[n.U=85]="U",n[n.V=86]="V",n[n.W=87]="W",n[n.X=88]="X",n[n.Y=89]="Y",n[n.Z=90]="Z",n[n.Left=37]="Left",n[n.Up=38]="Up",n[n.Right=39]="Right",n[n.Down=40]="Down",n[n.Escape=27]="Escape",n[n.Space=32]="Space",n[n.PageUp=33]="PageUp",n[n.PageDown=34]="PageDown",n[n.End=35]="End",n[n.Home=36]="Home",n[n.Delete=46]="Delete",n[n.Tab=9]="Tab",n[n.Enter=13]="Enter",n[n.BackSpace=8]="BackSpace",n[n.F1=112]="F1",n[n.F2=113]="F2",n[n.F3=114]="F3",n[n.F4=115]="F4",n[n.F5=116]="F5",n[n.F6=117]="F6",n[n.F7=118]="F7",n[n.F8=119]="F8",n[n.F9=120]="F9",n[n.F10=121]="F10",n[n.F11=122]="F11",n[n.F12=123]="F12",n[n.Star=56]="Star",n[n.Plus=187]="Plus",n[n.Minus=189]="Minus",n[n.BracketLeft=219]="BracketLeft",n[n.BracketRight=221]="BracketRight",n}(Mt||{}),ee=function(n){return n[n.Render=2]="Render",n[n.PublicMethod=4]="PublicMethod",n[n.ToolAction=8]="ToolAction",n[n.UndoRedo=16]="UndoRedo",n[n.TextEdit=32]="TextEdit",n[n.Group=64]="Group",n[n.Clear=128]="Clear",n[n.PreventClearSelection=256]="PreventClearSelection",n[n.Interactions=512]="Interactions",n[n.PreventHistory=1024]="PreventHistory",n[n.PreventIconsUpdate=2048]="PreventIconsUpdate",n[n.PreventCollectionChangeOnDragOver=4096]="PreventCollectionChangeOnDragOver",n[n.PreventZIndexOnDragging=8192]="PreventZIndexOnDragging",n[n.isGroupDragging=16384]="isGroupDragging",n[n.DragUsingMouse=32768]="DragUsingMouse",n[n.DecoratorPropertyChange=65536]="DecoratorPropertyChange",n[n.PreventLaneContainerUpdate=131072]="PreventLaneContainerUpdate",n}(ee||{}),Ga=function(n){return n[n.None=2]="None",n[n.DrawSelectorBorder=4]="DrawSelectorBorder",n[n.PreventRenderSelector=8]="PreventRenderSelector",n}(Ga||{}),$i=function(n){return n[n.None=0]="None",n[n.PreventDrag=2]="PreventDrag",n[n.PreventScale=4]="PreventScale",n[n.PreventDataInit=8]="PreventDataInit",n[n.hScrollbarMoved=16]="hScrollbarMoved",n[n.vScrollbarMoved=32]="vScrollbarMoved",n[n.AnimationClick=64]="AnimationClick",n[n.EnableGroupAction=128]="EnableGroupAction",n[n.PanInProgress=256]="PanInProgress",n[n.OverViewAction=512]="OverViewAction",n}($i||{}),da=function(n){return n[n.None=0]="None",n[n.PropertyChange=1024]="PropertyChange",n[n.Interaction=2048]="Interaction",n}(da||{}),Ae=function(n){return n[n.Zero=0]="Zero",n[n.One=1]="One",n[n.Two=2]="Two",n[n.Three=3]="Three",n[n.Four=4]="Four",n[n.Five=5]="Five",n}(Ae||{}),Ce=function(n){return n[n.collectionChange=0]="collectionChange",n[n.rotateChange=1]="rotateChange",n[n.positionChange=2]="positionChange",n[n.propertyChange=3]="propertyChange",n[n.selectionChange=4]="selectionChange",n[n.sizeChange=5]="sizeChange",n[n.drop=6]="drop",n[n.sourcePointChange=7]="sourcePointChange",n[n.targetPointChange=8]="targetPointChange",n[n.connectionChange=9]="connectionChange",n[n.animationComplete=10]="animationComplete",n[n.click=11]="click",n[n.doubleClick=12]="doubleClick",n[n.scrollChange=13]="scrollChange",n[n.dragEnter=14]="dragEnter",n[n.dragLeave=15]="dragLeave",n[n.dragOver=16]="dragOver",n[n.textEdit=17]="textEdit",n[n.paletteSelectionChange=18]="paletteSelectionChange",n[n.historyChange=19]="historyChange",n[n.mouseEnter=20]="mouseEnter",n[n.mouseLeave=21]="mouseLeave",n[n.mouseOver=22]="mouseOver",n[n.expandStateChange=23]="expandStateChange",n[n.segmentCollectionChange=24]="segmentCollectionChange",n[n.commandExecute=25]="commandExecute",n[n.historyStateChange=26]="historyStateChange",n[n.onUserHandleMouseDown=27]="onUserHandleMouseDown",n[n.onUserHandleMouseUp=28]="onUserHandleMouseUp",n[n.onUserHandleMouseEnter=29]="onUserHandleMouseEnter",n[n.onUserHandleMouseLeave=30]="onUserHandleMouseLeave",n[n.onImageLoad=31]="onImageLoad",n[n.onDoBindingInit=32]="onDoBindingInit",n[n.keyUp=33]="keyUp",n[n.keyDown=34]="keyDown",n[n.fixedUserHandleClick=35]="fixedUserHandleClick",n[n.elementDraw=36]="elementDraw",n[n.mouseWheel=37]="mouseWheel",n[n.segmentChange=38]="segmentChange",n[n.onFixedUserHandleMouseDown=39]="onFixedUserHandleMouseDown",n[n.onFixedUserHandleMouseUp=40]="onFixedUserHandleMouseUp",n[n.onFixedUserHandleMouseEnter=41]="onFixedUserHandleMouseEnter",n[n.onFixedUserHandleMouseLeave=42]="onFixedUserHandleMouseLeave",n[n.loaded=43]="loaded",n}(Ce||{}),ai=function(n){return n[n.None=1]="None",n[n.Drag=2]="Drag",n[n.Draw=4]="Draw",n[n.InConnect=8]="InConnect",n[n.OutConnect=16]="OutConnect",n[n.ToolTip=32]="ToolTip",n[n.InheritTooltip=64]="InheritTooltip",n[n.Default=24]="Default",n}(ai||{}),bx=function(n){return n[n.None=1]="None",n[n.Source=2]="Source",n[n.Target=4]="Target",n[n.Intermediate=8]="Intermediate",n[n.All=14]="All",n}(bx||{}),SI=function(n){return n[n.None=0]="None",n[n.SymmetricAngle=2]="SymmetricAngle",n[n.SymmetricDistance=4]="SymmetricDistance",n[n.Default=6]="Default",n}(SI||{}),hs=function(){function n(){this.pivot={x:.5,y:.5},this.isDirt=!0,this.isExport=!1,this.exportScaleValue={x:0,y:0},this.exportScaleOffset={x:0,y:0},this.canApplyStyle=!0,this.visible=!0,this.offsetX=0,this.offsetY=0,this.cornerRadius=0,this.minHeight=void 0,this.minWidth=void 0,this.maxWidth=void 0,this.maxHeight=void 0,this.width=void 0,this.height=void 0,this.rotateAngle=0,this.margin={left:0,right:0,top:0,bottom:0},this.connectionDirection="Auto",this.horizontalAlignment="Auto",this.verticalAlignment="Auto",this.flip="None",this.flipMode="All",this.relativeMode="Point",this.transform=Qa.Self|Qa.Parent,this.style={fill:"white",strokeColor:"black",opacity:1,strokeWidth:1},this.desiredSize=new me,this.actualSize=new me,this.parentTransform=0,this.preventContainer=!1,this.isSvgRender=!1,this.bounds=new Ne(0,0,0,0),this.shadow=null,this.description="",this.staticSize=!1,this.shapeType="",this.isRectElement=!1,this.isCalculateDesiredSize=!0,this.flipOffset={x:0,y:0},this.elementActions=Xr.None,this.inversedAlignment=!0,this.position=void 0,this.unitMode=void 0,this.float=!1,this.floatingBounds=void 0}return n.prototype.setOffsetWithRespectToBounds=function(t,e,i){this.unitMode=i,this.position={x:t,y:e}},n.prototype.getAbsolutePosition=function(t){if(void 0!==this.position)return"Absolute"===this.unitMode?this.position:{x:this.position.x*t.width,y:this.position.y*t.height}},Object.defineProperty(n.prototype,"outerBounds",{get:function(){return this.floatingBounds||this.bounds},set:function(t){this.floatingBounds=t},enumerable:!0,configurable:!0}),n.prototype.measure=function(t,e,i){var s=void 0!==this.height?this.height:(t.height||0)-this.margin.top-this.margin.bottom;return this.id&&0===s&&this.elementActions&Xr.HorizontalLaneHeader&&(s=this.actualSize.height),this.desiredSize=new me(void 0!==this.width?this.width:(t.width||0)-this.margin.left-this.margin.right,s),this.isCalculateDesiredSize&&(this.desiredSize=this.validateDesiredSize(this.desiredSize,t)),this.desiredSize},n.prototype.arrange=function(t){return this.actualSize=t,this.updateBounds(),this.actualSize},n.prototype.updateBounds=function(){this.bounds=yr(this)},n.prototype.validateDesiredSize=function(t,e){return this.isRectElement&&!this.width&&!this.minWidth&&!this.maxWidth&&(t.width=50),this.isRectElement&&!this.height&&!this.minHeight&&!this.maxHeight&&(t.height=50),(void 0===t||void 0!==this.width&&void 0!==this.height)&&((t=t||new me).width=void 0===this.width?(e.width||0)-this.margin.left-this.margin.right:this.width,t.height=void 0===this.height?(e.height||0)-this.margin.top-this.margin.bottom:this.height),void 0!==this.minWidth&&(t.width=Math.max(t.width,this.minWidth)),void 0!==this.minHeight&&(t.height=Math.max(t.height,this.minHeight)),void 0!==this.maxWidth&&0!==this.maxWidth&&(t.width=Math.min(t.width,this.maxWidth)),void 0!==this.maxHeight&&0!==this.maxHeight&&(t.height=Math.min(t.height,this.maxHeight)),t},n}(),Vie=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Cs=function(n){function t(){var e=null!==n&&n.apply(this,arguments)||this;return e.padding=new Pie(0,0,0,0),e.desiredBounds=void 0,e.measureChildren=!0,e.prevRotateAngle=0,e}return Vie(t,n),t.prototype.hasChildren=function(){return void 0!==this.children&&this.children.length>0},t.prototype.measure=function(e,i,r){this.desiredBounds=void 0;var o,a,s=void 0;if(this.hasChildren()){for(var l=0;l=n.width&&s.length>0)i[i.length]={text:s,x:0,dy:0,width:o},s="";else{(s+=a[r+1]||"").indexOf("\n")>-1&&(i[i.length]={text:s,x:0,dy:0,width:Bc(s,n)},s="");var l=Bc(s,n);Math.ceil(l)+2>=n.width&&s.length>0&&(i[i.length]={text:s,x:0,dy:0,width:l},s=""),r===a.length-1&&s.length>0&&(i[i.length]={text:s,x:0,dy:0,width:l},s="")}else i=function loe(n,t,e){var c,d,u,f,i=[],r="",s=0,o=0,a="nowrap"!==n.whiteSpace,h=(t||n.content).split("\n");for(s=0;s0?" ":"")+c[parseInt(o.toString(),10)];var p=Bc(d=c[o+1]?r+" "+c[o+1]:r,n);Math.floor(p)>(e||n.width)-2&&r.length>0?(i[i.length]={text:r,x:0,dy:0,width:d===r?p:r===f?u:Bc(r,n)},r=""):o===c.length-1&&(i[i.length]={text:r,x:0,dy:0,width:p},r=""),f=d,u=p}return i}(n,t,e);else i[i.length]={text:a,x:0,dy:0,width:Bc(a,n)};return i}(l,r,n.isLaneOrientation?i:void 0),n.wrapBounds=a=function hoe(n,t){var r,s,e={x:0,width:0},i=0;for(i=0;in.width&&("Ellipsis"===n.textOverflow||"Clip"===n.textOverflow)?0:-r/2:"right"===n.textAlign?-r:t.length>1?0:-r/2,t[parseInt(i.toString(),10)].dy=1.2*n.fontSize,t[parseInt(i.toString(),10)].x=r,e.x=Math.min(e.x,r),e.width=Math.max(e.width,s);return e}(l,o),s.width=a.width,n.wrapBounds.width>=i&&"Wrap"!==l.textOverflow&&(s.width=i),s.height=o.length*n.style.fontSize*1.2,s}(this,0,0,this.isLaneOrientation?e.height:this.width||e.width):this.desiredSize,this.desiredSize=void 0===this.width||void 0===this.height?new me(i.width,i.height):new me(this.width,this.height),this.desiredSize=this.validateDesiredSize(this.desiredSize,e),this.desiredSize},t.prototype.arrange=function(e){return(e.width!==this.actualSize.width||e.height!==this.actualSize.height||this.isDirt)&&(this.doWrap=!0),this.actualSize=e,this.updateBounds(),this.isDirt=!1,this.actualSize},t}(hs),Yie=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Mi=function(n){function t(){var e=null!==n&&n.apply(this,arguments)||this;return e.measureChildren=void 0,e}return Yie(t,n),t.prototype.measure=function(e,i,r){var s=void 0,o=void 0;if(this.hasChildren()){for(var a=0,l=this.children;a=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Dd=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return $ie(t,n),Oh([I("")],t.prototype,"content",void 0),Oh([I("TopLeft")],t.prototype,"position",void 0),Oh([I("Mouse")],t.prototype,"relativeMode",void 0),Oh([I(!0)],t.prototype,"showTipPointer",void 0),Oh([I("auto")],t.prototype,"width",void 0),Oh([I("auto")],t.prototype,"height",void 0),Oh([I("Auto")],t.prototype,"openOn",void 0),Oh([I()],t.prototype,"animation",void 0),Oh([I(!1)],t.prototype,"isSticky",void 0),t}(Ee);function i3(n){var t=new bh;t=r3(n.tooltip,t);var e=new bh(t);return e.beforeCollision=Jie,e.beforeOpen=Zie,e.cssClass="e-diagram-tooltip",e.opensOn="custom",e.appendTo("#"+n.element.id),e.close(),e}function Zie(n){(""===this.content||void 0===this.content)&&(n.element.style.display="none")}function Jie(n){n.collidedPosition&&n.collidedPosition!==this.position&&(n.element.style.display="none")}function Mx(n,t){var e=n.tooltipObject;return r3(t?t.tooltip:n.tooltip,e),e}function r3(n,t){return n.content?(t.content=n.content,"string"==typeof n.content&&(t.content=ko(function(){return n.content})),t.position=n.position,t.showTipPointer=n.showTipPointer,t.width=n.width,t.height=n.height,t.animation=n.animation?n.animation:{close:{effect:"None"}}):t.close(),t}var wx=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Bn=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Cx=function(n){function t(e,i,r,s){var o=n.call(this,e,i,r,s)||this;return o.inEdges=[],o.outEdges=[],o}return wx(t,n),Bn([I("")],t.prototype,"id",void 0),Bn([I("Center")],t.prototype,"horizontalAlignment",void 0),Bn([I("Center")],t.prototype,"verticalAlignment",void 0),Bn([re({},Jn)],t.prototype,"margin",void 0),Bn([I(12)],t.prototype,"width",void 0),Bn([I(12)],t.prototype,"height",void 0),Bn([re({},Ll)],t.prototype,"style",void 0),Bn([I("Square")],t.prototype,"shape",void 0),Bn([I("Auto")],t.prototype,"connectionDirection",void 0),Bn([I(oi.Connect)],t.prototype,"visibility",void 0),Bn([I("")],t.prototype,"pathData",void 0),Bn([I(ai.Default)],t.prototype,"constraints",void 0),Bn([I()],t.prototype,"addInfo",void 0),Bn([I()],t.prototype,"outEdges",void 0),Bn([I()],t.prototype,"inEdges",void 0),Bn([re({},Dd)],t.prototype,"tooltip",void 0),t}(Ee),Es=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return wx(t,n),t.prototype.getClassName=function(){return"PointPort"},Bn([re({x:.5,y:.5},R)],t.prototype,"offset",void 0),t}(Cx),Tc=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return wx(t,n),t.prototype.getClassName=function(){return"PathPort"},Bn([I(.5)],t.prototype,"offset",void 0),Bn([re({x:0,y:0},R)],t.prototype,"displacement",void 0),Bn([I("Center")],t.prototype,"alignment",void 0),t}(Cx),MI=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),lr=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Kie=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return MI(t,n),lr([I("blue")],t.prototype,"color",void 0),lr([I("")],t.prototype,"content",void 0),lr([I("")],t.prototype,"link",void 0),lr([I("None")],t.prototype,"textDecoration",void 0),lr([I("NewTab")],t.prototype,"hyperlinkOpenState",void 0),t}(Ee),Ex=function(n){function t(e,i,r,s){var o=n.call(this,e,i,r,s)||this;return r.id||(o.id=e.parentObj&&e.parentObj.propName&&"phases"===e.parentObj.propName?e.parentObj.id:Qe()),o}return MI(t,n),lr([I("")],t.prototype,"content",void 0),lr([I(void 0)],t.prototype,"template",void 0),lr([I("String")],t.prototype,"annotationType",void 0),lr([I(!0)],t.prototype,"visibility",void 0),lr([I(Nr.InheritReadOnly)],t.prototype,"constraints",void 0),lr([re(void 0,Kie)],t.prototype,"hyperlink",void 0),lr([I("")],t.prototype,"id",void 0),lr([I()],t.prototype,"width",void 0),lr([I()],t.prototype,"height",void 0),lr([I(0)],t.prototype,"rotateAngle",void 0),lr([I("Parent")],t.prototype,"rotationReference",void 0),lr([re({strokeWidth:0,strokeColor:"transparent",fill:"transparent"},Qf)],t.prototype,"style",void 0),lr([I("Center")],t.prototype,"horizontalAlignment",void 0),lr([I("Center")],t.prototype,"verticalAlignment",void 0),lr([re({},Jn)],t.prototype,"margin",void 0),lr([re({top:void 0,bottom:void 0,left:void 0,right:void 0},Jn)],t.prototype,"dragLimit",void 0),lr([I("Shape")],t.prototype,"type",void 0),lr([re({},Dd)],t.prototype,"tooltip",void 0),lr([I()],t.prototype,"addInfo",void 0),t}(Ee),Kn=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return MI(t,n),t.prototype.getClassName=function(){return"ShapeAnnotation"},lr([re({x:.5,y:.5},R)],t.prototype,"offset",void 0),t}(Ex),Or=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return MI(t,n),t.prototype.getClassName=function(){return"PathAnnotation"},lr([I(.5)],t.prototype,"offset",void 0),lr([re({x:0,y:0},R)],t.prototype,"displacement",void 0),lr([I("Center")],t.prototype,"alignment",void 0),lr([I(!1)],t.prototype,"segmentAngle",void 0),t}(Ex);function Dx(n){return rre[n.toString()]}function n3(n){return ore[""+n]}var rre={X:"M14,14 L106,106 M106,14 L14,106",Circle:"M0,50 A50,50,0 1 1 100,50 A50,50,0 1 1 0,50 Z",Square:"M0,0 L10,0 L10,10 L0,10 z"},nre={OpenArrow:"M15.9,23 L5,16 L15.9,9 L17,10.7 L8.7,16 L17,21.3Z",Square:"M0,0 L10,0 L10,10 L0,10 z",Fletch:"M14.8,10c0,0-3.5,6,0.2,12c0,0-2.5-6-10.9-6C4.1,16,11.3,16,14.8,10z",OpenFetch:"M6,17c-0.6,0-1-0.4-1-1s0.4-1,1-1c10.9,0,11-5,11-5c0-0.6,0.4-1,1-1s1,0.4,1,1C19,10.3,18.9,17,6,17C6,17,6,17,6,17z M18,23c-0.5,0-1-0.4-1-1c0-0.2-0.3-5-11-5c-0.6,0-1-0.5-1-1s0.4-1,1-1c0,0,0,0,0,0c12.9,0,13,6.7,13,7 C19,22.6,18.6,23,18,23z",IndentedArrow:"M17,10c0,0-4.5,5.5,0,12L5,16L17,10z",OutdentedArrow:"M14.6,10c0,0,5.4,6,0,12L5,16L14.6,10z",DoubleArrow:"M19,10 L19,22 L13,16Z M12,10 L12,22 L6,16Z",Arrow:"M15,10 L15,22 L5,16Z",Diamond:"M12,23l-7-7l7-7l6.9,7L12,23z",Circle:"M0,50 A50,50,0 1 1 100,50 A50,50,0 1 1 0,50 Z"},sre={Square:"M0,0 L10,0 L10,10 L0,10 z",Rhombus:"M10,5 L5,10 L0,5 L5,0 L10,5 Z ",Rectangle:"M0,0 L15,0 L15,10 L0,10 z ",OpenArrow:"M15.9,23 L5,16 L15.9,9 L17,10.7 L8.7,16 L17,21.3Z",Fletch:"M9.82,0 C9.82,0,6.61,5,10,10 C10,10,7.71,5,0,5 C0,5,6.61,5,9.82,0 Z ",OpenFetch:"M0.71,5.71 C0.29,5.71,0,5.43,0,5 C0,4.57,0.29,4.29,0.71,4.29 C8.5,4.29,8.57,0.71,8.57,0.71 C8.57,0.29,8.86,0,9.29,0 C9.719999999999999,0,10,0.29,10,0.71 C10,0.93,9.93,5.71,0.71,5.71 C0.71,5.71,0.71,5.71,0.71,5.71 Z M9.29,10 C8.93,10,8.57,9.71,8.57,9.29 C8.57,9.14,8.36,5.71,0.71,5.71 C0.29,5.71,0,5.36,0,5 C0,4.64,0.29,4.29,0.71,4.29 C0.71,4.29,0.71,4.29,0.71,4.29 C9.93,4.29,10,9.07,10,9.29 C10,9.71,9.71,10,9.29,10 Z ",IndentedArrow:"M10,0 C10,0,6.25,4.58,10,10 L0,5 L10,0 Z ",OutdentedArrow:"M8,0 C8,0,12.5,5,8,10 L0,5 L8,0 Z ",DoubleArrow:"M19,10 L19,22 L13,16Z M12,10 L12,22 L6,16Z",Arrow:"M15,10 L15,22 L5,16Z",Diamond:"M10,5 L5,10 L0,5 L5,0 L10,5 Z ",Circle:"M10,5 C10,7.76,7.76,10,5,10 C2.24,10,0,7.76,0,5 C0,2.24,2.24,0,5,0 C7.76,0,10,2.24,10,5 Z ",Ellipse:"M15,5 C15,7.76,11.64,10,7.5,10 C3.36,10,0,7.76,0,5 C0,2.24,3.36,0,7.5,0 C11.64,0,15,2.24,15,5 Z "},ore={Square:"M0,0 L10,0 L10,10 L0,10 z",Rhombus:"M10,5 L5,10 L0,5 L5,0 L10,5 Z ",Rectangle:"M0,0 L15,0 L15,10 L0,10 z",OpenArrow:"M23,15.9 L16,5 L9,15.9 L10.7,17 L16,8.7 L21,17.3Z",Fletch:"M9.82,0 C9.82,0,6.61,5,10,10 C10,10,7.71,5,0,5 C0,5,6.61,5,9.82,0 Z ",OpenFetch:"M0.71,5.71 C0.29,5.71,0,5.43,0,5 C0,4.57,0.29,4.29,0.71,4.29 C8.5,4.29,8.57,0.71,8.57,0.71 C8.57,0.29,8.86,0,9.29,0 C9.719999999999999,0,10,0.29,10,0.71 C10,0.93,9.93,5.71,0.71,5.71 C0.71,5.71,0.71,5.71,0.71,5.71 Z M9.29,10 C8.93,10,8.57,9.71,8.57,9.29 C8.57,9.14,8.36,5.71,0.71,5.71 C0.29,5.71,0,5.36,0,5 C0,4.64,0.29,4.29,0.71,4.29 C0.71,4.29,0.71,4.29,0.71,4.29 C9.93,4.29,10,9.07,10,9.29 C10,9.71,9.71,10,9.29,10 Z ",IndentedArrow:"M10,0 C10,0,6.25,4.58,10,10 L0,5 L10,0 Z ",OutdentedArrow:"M8,0 C8,0,12.5,5,8,10 L0,5 L8,0 Z ",DoubleArrow:"M10,19 L22,19 L16,13Z M10,12 L22,12 L16,6Z",Arrow:"M10,15 L22,15 L16,5Z",Diamond:"M10,5 L5,10 L0,5 L5,0 L10,5 Z ",Circle:"M10,5 C10,7.76,7.76,10,5,10 C2.24,10,0,7.76,0,5 C0,2.24,2.24,0,5,0 C7.76,0,10,2.24,10,5 Z ",Ellipse:"M15,5 C15,7.76,11.64,10,7.5,10 C3.36,10,0,7.76,0,5 C0,2.24,3.36,0,7.5,0 C11.64,0,15,2.24,15,5 Z "};function xx(n){return are[n.toString()]}var are={Process:"M419.511,76.687L359.511,76.687L359.511,43.086L419.511,43.086z",Decision:"M 253.005,115.687L 200.567,146.071L 148.097,115.687L 200.534,85.304L 253.005,115.687 Z",Document:"M 60 31.9 c 0 0 -11 -7.7 -30 0 s -30 0 -30 0 V 0 h 60 V 31.9 Z",PreDefinedProcess:"M 0,0 L 50,0 L 50,50 L 0,50 Z M 8.334,0 L 8.334,50 M 41.667,0 L 41.667,50",Terminator:"M 269.711,29.33C 269.71,44.061 257.77,56 243.04,56L 158.058,56C 143.33,56 131.39,44.061 131.39,29.33L 131.39,29.33C 131.391,14.6057 143.33,2.669 158.058,2.669L 243.044,2.669C 257.772,2.669 269.711,14.6057 269.711,29.333 Z",PaperTap:"M0.0009,17.2042 L0.0009,47.165 C0.001,47.165 14.403,53.5455 25.00,47.165 C35.599,40.7852 44.403,43.5087 50.00,47.165L50.001,17.2042 M50.001,32.7987 L50.001,2.8405 C50.001,2.8405 35.599,-3.5427 25.001,2.8405C14.403,9.2237 5.599,6.494 0.0009,2.8405 L0.0009,32.7987",DirectData:"M 132.62 0 L 17.38 0 C 7.78 0 0 13.43 0 30 C 0 46.57 7.78 60 17.38 60 L 132.62 60 M 132.62 0C 123.02 0 115.24 13.43 115.24 30 C 115.24 46.57 123.02 60 132.62 60 C 142.22 60 150 46.57 150 30 C 150 13.43 142.22 0 132.62 0 z ",SequentialData:"M0.0029,24.999 C0.0029,11.1922 10.433,0.0021 23.295,0.0021 C36.159,0.00216 46.585,11.1922 46.585,24.999C46.585,38.8057 36.159,49.9979 23.295,49.9979 C10.433,49.9979 0.0029,38.8057 0.0029,24.999 z M23.294,49.999 L50.002,49.999",Sort:"M50.001,24.9971 L25.001,49.9971 L0.00097,24.9971 L25.001,-0.00286865 L50.001,24.9971 z M0.000976562,24.9971 L50.001,24.9971",MultiDocument:"M43.6826,40 C44.8746,40.6183 45.8586,41.3502 46.8366,42.1122 L46.8366,4.74487 L3.09857,4.74487 L3.09857,10.9544 M46.837,35.143 C48.027,35.765 49.025,36.604 50.003,37.369 L50.003,0.002 L6.264,0.002 L6.264,4.744 M43.682,47.113 L43.682,10.765 L0.0025,10.7652 L0.0025,47.1132 C0.0025,47.1132 12.5846,53.6101 21.8426,47.1132 C31.1006,40.6163 38.792,43.393 43.6826,47.1132 z",Collate:"M50.001,0.0028 L25.001,25.0029 L0.00097,0.0028 L50.001,0.002 z M0.0009,50.002 L25.001,25.002L50.001,50.002 L0.0009,50.0029 z",SummingJunction:"M7.3252,42.6768 L42.6772,7.3247 M42.6768,42.6768 L7.3248,7.3247 M0.0009,25.001 C0.0009,11.193 11.197,0.0009 25.001,0.0009 C38.809,0.0009 50.001,11.193 50.001,25.001 C50.001,38.809 38.809,50.001 25.001,50.001 C11.197,50.00 0.0009,38.809 0.0009,25.00 z",Or:"M 0 50 L 100 50 M 50 100 L 50 0.0 M 0 50 C 0 22.384 22.392 0 50 0 C 77.616 0 100 22.384 100 50 C 100 77.616 77.616 100 50 100 C 22.392 100 0 77.616 0 50 Z",InternalStorage:"M 0 3.81946A 2.5,3.81946 0 0,1 2.5,0L 47.5 0A 2.5,3.81946 0 0,1 50,3.81946L 50 45.836A 2.5,3.819446 0 0,1 47.5,49.652778L 2.5 49.652778A 2.5,3.819446 0 0,1 0,45.8336L 0 3.819446ZM 0 11.45834L 50 11.4583334M 12.5 0L 12.5 49.652778",Extract:"M0,35 L30,0 L60,35 Z",ManualOperation:"M46.4,28.8 L14.8,28.8 L0,0 L60,0 Z",Merge:"M60,0 L30,35 L0,0 Z",OffPageReference:"M60,33.3 L30.1,39 L0,33.3 L0,0 L60,0 Z",SequentialAccessStorage:"M 60 30 C 60 13.4 46.6 0 30 0 S 0 13.4 0 30 s 13.4 30 30 30 h 28.6 v -6.5 h -9.9C 55.5 48 60 39.5 60 30 Z",Annotation:"M49.9984,50.0029 L-0.00271199,50.0029 L-0.00271199,0.00286865 L49.9984,0.00286865",Annotation2:"M49.9977,50.0029 L25.416,50.0029 L25.416,0.00286865 L49.9977,0.00286865 M25.4166,25.0029 L-0.00227869,25.0029",Data:"M 10 0 L 40 0 L 30 40 L 0 40 Z",Card:"M275,60 L400,60 L400,110 L260,110 L260,75 Z",Delay:"M0,0 L12.029,0 C14.212999,0 16,1.7869979 16,3.9709952 C16,6.1549926 14.212999,7.9409904 12.029,7.9409904 L0,7.9409904 z",Preparation:"M 1048.17 572 C 1051.06 568.86 1055.17 567.05 1059.5 567 L 1094.51 567 C 1098.84 567.05 1102.95 568.86 1105.84 572 L 1126.43 595 C 1127.01 596.28 1127.01 597.72 1126.43 599 L 1105.84 622 C 1102.95 625.14 1098.84 626.95 1094.51 627 L 1059.5 627 C 1055.17 626.95 1051.06 625.14 1048.17 622 L 1027.58 599 C 1027 597.72 1027 596.28 1027.58 595 L 1048.17 572 Z",Display:"M47.8809,19.2914 L32.7968,-0.00594145 L11.3902,-0.00594145 C7.93166,-0.00594145 0.00124586,11.187 0.00124586,24.9968C0.00124586,38.8032 7.93166,49.9962 11.3902,49.9962 L32.7968,49.99 L47.615,31.038 C47.615,31.0388 52.798,24.9968 47.880,19.2914 z",ManualInput:"M 912 732 L 1006.85 707 C 1008.2 707 1009.5 707.53 1010.46 708.46 C 1011.41 709.4 1011.95 710.67 1011.95 712 L 1011.95 762C 1012 764.41 1010.28 766.52 1007.87 767 L 917.1 767 C 915.75 767 914.45 766.47 913.49 765.54 C 912.54 764.6 912 763.33 912 762 L 912 732 Z",LoopLimit:"M 8 9 L 27 9 L 33 15 L 33 26 C 33 27 33 27 32 27 L 4 27 C 3 27 2 27 2 26 L 2 15 L 8 9 Z",StoredData:"M 5.55 0L 50 0A 1.5,30 0 0,1 50,0A 5.555,25 0 0,0 50,50A 1.5,30 0 0,1 50,50L 5.555 50A 5.55,25 0 0,1 5.555,0Z"};function s3(n,t,e){var i;i="Straight"!==n.type&&n.sourceWrapper?n.sourceWrapper.corners.center:function lre(n){var t;if(n.sourcePortWrapper){var e=n.sourcePortWrapper;t={x:e.offsetX,y:e.offsetY}}else t=n.sourceID&&n.sourceWrapper&&n.targetWrapper?qa(n,0,n.sourceWrapper.corners.center,n.targetWrapper.corners.center,!1):n.sourcePoint;return t}(n);var r=function cre(n,t,e,i,r){var b,M,s=n.sourceWrapper,o=n.targetWrapper,a=n.sourcePortWrapper,l=n.targetPortWrapper,d=[],p=Xa(n),y={corners:undefined,point:t,direction:undefined,margin:{left:5,right:5,bottom:5,top:5}},S={corners:undefined,point:e,direction:undefined,margin:{left:5,right:5,bottom:5,top:5}};if(void 0!==s&&void 0!==o&&(b=xn(s),M=xn(o),y.corners=s.corners,S.corners=o.corners),void 0!==a&&(y.direction="Left"===a.connectionDirection||"Top"===a.connectionDirection||"Bottom"===a.connectionDirection||"Right"===a.connectionDirection?a.connectionDirection:zo({x:a.offsetX,y:a.offsetY},b,s.bounds)),void 0!==l&&(S.direction="Left"===l.connectionDirection||"Right"===l.connectionDirection||"Bottom"===l.connectionDirection||"Top"===l.connectionDirection?l.connectionDirection:zo({x:l.offsetX,y:l.offsetY},M,o.bounds)),"Bezier"===n.type&&!n.isBezierEditing&&n.segments.length>0)for(var D=n.segments.length-1;D>=0;)n.segments[parseInt(D.toString(),10)].isInternalSegment&&n.segments.pop(),D--;if(void 0!==s&&void 0!==o)return(void 0===y.direction||void 0===S.direction)&&(i?function hre(n,t,e){"LeftToRight"===e?(n.direction=n.direction?n.direction:"Right",t.direction=t.direction?t.direction:"Left"):"RightToLeft"===e?(n.direction=n.direction?n.direction:"Left",t.direction=t.direction?t.direction:"Right"):"TopToBottom"===e?(n.direction=n.direction?n.direction:"Bottom",t.direction=t.direction?t.direction:"Top"):"BottomToTop"===e&&(n.direction=n.direction?n.direction:"Top",t.direction=t.direction?t.direction:"Bottom")}(y,S,i):y.corners.top>S.corners.bottom&&Math.abs(y.corners.top-S.corners.bottom)>p?(y.direction=y.direction?y.direction:"Top",S.direction=S.direction?S.direction:"Bottom"):y.corners.bottomp?(y.direction=y.direction?y.direction:"Bottom",S.direction=S.direction?S.direction:"Top"):y.corners.rightp||y.corners.right+p=y.corners.left-p&&y.corners.left>S.corners.left?(y.direction=y.direction?y.direction:"Right",S.direction=S.direction?S.direction:"Left"):y.corners.left>S.corners.right&&Math.abs(y.corners.left-S.corners.right)>y.margin.left+y.margin.right||S.corners.right+p=S.corners.left-p&&y.corners.left0&&n.segments[0].direction&&(y.direction=n.segments[0].direction),y.point=Nl(b,y.direction),d=Nl(b,_n(y.direction)),y.point=qa(n,0,y.point,d,!1)):y.point=o.corners.center;if(void 0!==h){switch(S.point={x:h.offsetX,y:h.offsetY},S.direction){case"Bottom":case"Top":S.point.y=S.point.y;break;case"Left":case"Right":S.point.x=S.point.x}n.targetPadding&&!w&&(S.point=wI(n,y,S,!0))}else"Orthogonal"===n.type||"Bezier"===n.type?(S.point=Nl(M,S.direction),d=Nl(M,_n(S.direction)),S.point=qa(n,0,S.point,d,!0)):S.point=a.corners.center;if("Orthogonal"!==n.type){var C=void 0,D=void 0;if("Bezier"===n.type){if(n.bezierSettings.allowSegmentsReset||0===n.segments.length||!R.isEmptyPoint(n.segments[n.segments.length-1].point))return c=g3(n,y,S,void 0,s),Tx(n,y,S);Bv(n)}else Bv(n);if(void 0===n.sourcePortWrapper){y.point=y.corners.center,n.segments&&n.segments.length>0&&(C=R.isEmptyPoint((D=n.segments[0]).point)?void 0:D);var A=void 0!==C?C.point:S.point;if("Bezier"===n.type&&n.segments.length>0&&n.segments[0].vector1.angle&&n.segments[0].vector1.distance){var x=Math.max(y.corners.width,y.corners.height);A=R.transform(y.point,n.segments[0].vector1.angle,x/2)}y.point=w?n.sourceWrapper.bounds.center:qa(n,0,y.point,A,!1)}if(void 0===n.targetPortWrapper){S.point=S.corners.center,n.segments&&n.segments.length>1&&(C=R.isEmptyPoint((D=n.segments[n.segments.length-2]).point)?void 0:D);var P=C?C.point:y.point;"Bezier"===n.type&&n.segments.length>0&&n.segments[n.segments.length-1].vector2.angle&&n.segments[n.segments.length-1].vector2.distance&&(x=Math.max(y.corners.width,y.corners.height),P=R.transform(S.point,n.segments[0].vector2.angle,x/2)),S.point=w?n.targetWrapper.bounds.center:qa(n,0,P,S.point,!0)}c=Tx(n,y,S)}else"Orthogonal"===n.type&&n.segments&&n.segments.length>0&&null!==n.segments[0].direction?c=function Ire(n,t,e,i,r,s,o){var a,h,c,d;Bv(n);for(var u=0;u0&&n.segments[u-1].direction===h.direction?u=u3(n,u,t):h.direction?t.point=o3(t,n.segments[parseInt(u.toString(),10)]):(f=n.segments[u-1])&&f.points&&f.points.length>0&&(t.point=f.points[f.points.length-1]),u===n.segments.length-1)if(f3(n,t),c3(a=void 0===r?Sre(n,t,e):l3(n,t,e),n),h.points=[],a.length>=2)for(c=0;c2&&n.segments.length>2){var p={x:a[parseInt(c.toString(),10)].x,y:t.point.y};h.points=[],h.points.push(p),h.points.push(a[parseInt(c.toString(),10)]);var f=n.segments[u-1];n.segments.length<4&&f.points.pop(),f.points=f.points.concat(h.points)}else h.points.push(a[parseInt(c.toString(),10)]);else h.points.push(a[parseInt(c.toString(),10)]);else d=u;if(void 0!==d&&!n.selectedSegmentIndex&&(d===n.segments.length-1&&(n.segments[d-1].direction=null,n.segments[d-1].length=null),n.segments.splice(d,1)),i&&0===u){var g=h3(n,i,s);g&&(t.point=g)}}return p3(n,[])}(n,y,S,l,h,o):(n.segments[0]||(C=new wi(n,"segments",{type:"Orthogonal"},!0),n.segments.push(C)),n.segments[0].points=c=g3(n,y,S,void 0,s));return c}(n,y.direction,S.direction,y.point,S.point,r);if(Bv(n),(n.sourceWrapper||n.targetWrapper)&&function gre(n,t,e){var i=n.sourcePortWrapper,r=n.targetPortWrapper,s=n.sourceWrapper,o=t.point,a={left:0,right:0,top:0,bottom:0},l={x:0,y:0},c="Top";if(s?(o=e.point,a=t.margin):(s=n.targetWrapper,a=e.margin),"Orthogonal"===n.type)if(n.segments&&n.segments.length>0&&n.sourceWrapper&&n.segments[0].direction)t.direction=n.segments[0].direction,l=qa(n,0,l=Nl(s.corners,t.direction),Nl(s.corners,_n(t.direction)),!1);else{var u={corners:null,direction:null,point:null,margin:null};Fv(s,{corners:null,direction:null,point:o,margin:a},u,n),l=u.point,c=u.direction}else{var f=void 0;n.segments&&n.segments.length>1&&(f=s===n.sourceWrapper?n.segments[0].point:n.segments[n.segments.length-2].point),l=qa(n,0,s.bounds.center,n.segments&&n.segments.length>1?f:o,s===n.targetWrapper)}s===n.sourceWrapper?(t.direction=t.direction||c,t.point=l,n.sourcePortWrapper&&(t.point={x:i.offsetX,y:i.offsetY},n.sourcePadding&&(t.point=wI(n,t,e,!1)))):(e.direction=e.direction||c,e.point=l,n.targetPortWrapper&&(e.point={x:r.offsetX,y:r.offsetY},n.targetPadding&&(e.point=wI(n,t,e,!0))))}(n,y,S),"Straight"===n.type||"Bezier"===n.type)d=Tx(n,y,S);else if("Orthogonal"===n.type&&n.segments&&n.segments.length>0&&null!==n.segments[0].length&&null!==n.segments[0].direction)d=function pre(n,t,e,i,r,s,o){var a,l,c,u,h=[];if(Bv(n),n.segments.length>0){for(var f=0;f0&&n.segments[f-1].direction===p.direction)f=u3(n,f,t);else{var g=n.segments[f-1];t.point=p.direction?o3(t,p):g.points[g.points.length-1]}if(f===n.segments.length-1&&(o||r?n.targetWrapper&&void 0===n.targetPortWrapper?(f3(n,t),l=ure(n,t,e)):l=l3(n,t,e):l=dre(n,t,e),l))if(c3(l,n),p.points=[],l.length>=2)for(a=0;at.corners.top&&e.point.ye.point.x?"Left":"Right"):e.point.x>t.corners.left&&e.point.xe.point.y?"Top":"Bottom")),n.sourcePortWrapper&&s===_n(r)?(("Left"===s||"Right"===s)&&t.point.y>=t.corners.top&&t.point.y<=t.corners.center.y&&e.point.y>=t.corners.top&&e.point.y<=t.corners.center.y?(t.direction="Top",a=t.point.y-t.corners.top+20):("Left"===s||"Right"===s)&&t.point.y>t.corners.center.y&&t.point.y<=t.corners.bottom&&e.point.y>t.corners.center.y&&e.point.y<=t.corners.bottom?(t.direction="Bottom",a=t.corners.bottom-t.point.y+20):("Top"===s||"Bottom"===s)&&t.point.x>=t.corners.left&&t.point.x<=t.corners.center.x&&e.point.x>=t.corners.left&&e.point.x<=t.corners.center.x?(t.direction="Left",a=t.point.x-t.corners.left+20):("Top"===s||"Bottom"===s)&&t.point.x<=t.corners.right&&t.point.x>t.corners.center.x&&e.point.x<=t.corners.right&&e.point.xt.point.y&&t.point.y>=e.corners.top?(i="Top",r=t.point.y-e.corners.top+20):e.corners.center.y===t.point.y&&"Top"===n.segments[n.segments.length-2].direction||e.corners.center.ye.point.y?t.point.y-t.corners.top+20:t.corners.bottom-t.point.y+20):(i="Top",r=e.corners.height/2+20):e.corners.center.x!==t.point.x||e.corners.topt.point.x&&t.point.x>=e.corners.left?(i="Left",r=t.point.x-e.corners.left+20):e.corners.center.x===t.point.x&&"Left"===n.segments[n.segments.length-2].direction||e.corners.center.x<=t.point.x&&t.point.x<=e.corners.right?(i="Right",r=e.corners.right-t.point.x+20):void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&t.corners.left<=t.point.x&&t.point.x<=t.corners.right&&(i=t.direction,r=t.point.x>e.point.x?t.point.x-t.corners.left+20:t.corners.right-t.point.x+20):(i="Left",r=e.corners.width/2+20);var a=t.point;t.point=Fn(t.point,"Left"===i||"Top"===i?-r:r,"Left"===i||"Right"===i?0:90),t.direction=R.direction(t.point,e.point),void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&(t.corners.center.x===e.corners.center.x||t.corners.center.y===e.corners.center.y)&&(t.direction=e.direction);var l=Ys(n,t,e);return l.splice(0,0,a),l}function l3(n,t,e){var i,r;e.corners=n.targetWrapper.corners,void 0!==n.sourcePortWrapper&&(r=zo({x:n.sourcePortWrapper.offsetX,y:n.sourcePortWrapper.offsetY},xn(n.sourceWrapper),n.sourceWrapper.bounds));var a=function fre(n,t,e,i){var r=!1;switch(e.direction){case"Left":void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&"Right"===i&&t.point.x>e.point.x&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom||("Bottom"===i&&t.point.y>e.point.y||"Top"===i&&t.point.y=t.corners.left&&t.point.x<=t.corners.right?(t.direction="Right"===i?t.point.y>e.point.y?"Top":"Bottom":t.point.xe.point.x&&(t.point.y>e.point.y||t.point.yt.point.y&&e.corners.bottome.point.y||t.point.x>e.point.x&&t.point.y<=e.point.y&&e.corners.top=t.point.y?t.direction="Top":t.point.xe.point.x&&t.point.y>e.point.y&&e.corners.bottomt.point.y?t.direction="Bottom":t.point.y===e.point.y&&t.point.xe.point.y||"Top"===i&&t.point.ye.point.x&&t.point.x>=t.corners.left&&t.point.x<=t.corners.right?(t.direction=t.point.x>e.point.x?"Left":"Right",r=!0):void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&"Left"===i&&t.point.x=t.corners.top&&t.point.y<=t.corners.bottom?(t.direction=t.point.y>e.point.y?"Top":"Bottom",r=!0):t.point.x=t.point.y&&t.point.y===e.point.y||t.point.y>e.point.y&&t.point.x>e.point.x?t.direction="Top":t.point.ye.point.x?t.direction="Bottom":t.point.xe.point.y||t.point.ye.point.x&&(t.direction="Left");break;case"Top":void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&"Bottom"===i&&t.point.y>e.point.y&&t.point.x>=t.corners.left&&t.point.x<=t.corners.right||("Right"===i&&t.point.x>e.point.x||"Left"===i&&e.point.y>t.point.y&&e.point.x>t.point.x)&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom?(t.direction="Bottom"===i?t.point.x>e.point.x?"Left":"Right":t.point.ye.point.y&&t.point.x>e.corners.left&&t.point.x=e.point.y?t.direction="Top":t.point.ye.point.x?t.direction="Left":t.point.yt.point.x)&&t.point.y>e.point.y&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom||"Top"===i&&t.point.y=t.corners.left&&t.point.x<=t.corners.right)?(t.direction="Right"===i||"Left"===i?t.point.y>e.point.y?"Top":"Bottom":t.point.x>e.point.x?"Left":"Right",r=!0):t.point.ye.corners.left&&e.corners.right>t.point.x?t.point.ye.corners.left&&e.corners.center.x>=t.point.x?t.direction="Left":t.point.ye.point.y&&t.point.x>e.point.x?t.direction="Left":t.point.y>e.point.y&&t.point.xe.point.x||e.point.x>t.point.x)&&(t.direction="Bottom")}return r}(n,t,e,r);return!n.selectedSegmentIndex&&void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&e.direction===_n(r)&&(("Left"===e.direction&&t.point.x>e.point.x||"Right"===e.direction&&t.point.x=t.corners.top&&t.point.y<=t.corners.bottom||"Bottom"===e.direction&&t.point.y=t.corners.left&&t.point.x<=t.corners.right)?i=a3(n,t,e):n.selectedSegmentIndex||t.direction!==e.direction?!n.selectedSegmentIndex&&("Left"===e.direction&&t.point.x>e.point.x||"Right"===e.direction&&t.point.x=t.point.y||"Top"===e.direction&&t.point.y>e.point.y||"Bottom"===e.direction&&t.point.y=t.point.x?i=n.selectedSegmentIndex?Ol(t,e):a3(n,t,e):!n.selectedSegmentIndex&&void 0!==n.sourceWrapper&&void 0!==n.targetWrapper&&void 0!==n.targetPortWrapper&&("Left"===t.direction||"Right"===t.direction)&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom&&("Top"===e.direction||"Bottom"===e.direction)&&e.corners.center.x===t.corners.center.x?(t.direction="Top"===e.direction?"Bottom":"Top",i=Ys(n,t,e,"Top"===e.direction?t.corners.bottom-t.point.y+20:t.point.y-t.corners.top+20)):!n.selectedSegmentIndex&&void 0!==n.sourceWrapper&&void 0!==n.targetWrapper&&void 0!==n.targetPortWrapper&&("Top"===t.direction||"Bottom"===t.direction)&&t.point.x>=t.corners.left&&t.point.x<=t.corners.right&&("Left"===e.direction||"Right"===e.direction)&&e.corners.center.y===t.corners.center.y?(t.direction="Left"===e.direction?"Right":"Left",i=Ys(n,t,e,"Left"===e.direction?t.corners.right-t.point.x+20:t.point.x-t.corners.left+20)):i=a?Ys(n,t,e,"Left"===t.direction||"Right"===t.direction?"Left"===t.direction?t.point.x-t.corners.left+20:t.corners.right-t.point.x+20:"Top"===t.direction?t.point.y-t.corners.top+20:t.corners.bottom-t.point.y+20):Ol(t,e):i=Ys(n,t,e),i}function h3(n,t,e){var r,i={x:t.offsetX,y:t.offsetY},s=xn(e),o=zo(i,s,e.bounds),a=n.segments[0];return a.direction!==o&&(function bre(n,t,e,i,r,s){var a,h,o=13,l=[];l.push(i),i.y===r.y&&("Left"===t&&r.xi.x)||i.x===r.x&&("Top"===t&&r.yi.y)||("Top"===t||"Bottom"===t?"Top"===t&&r.yi.y-o||"Bottom"===t&&r.y>i.y&&r.yo&&("Top"===t&&r.yi.y)?l.push({x:i.x,y:r.y}):(a=r.xi.x-o||"right"===t&&r.x>i.x&&r.xo&&("Left"===t&&r.xi.x)?l.push({x:r.x,y:i.y}):(l.push({x:a="Left"===t?e.left-o:e.right+o,y:i.y}),l.push({x:a,y:r.y})),s&&(l.push(n.points[0]),l.reverse()),n.points=l)}(a,o,s,a.points[0],a.points[a.points.length-1],!1),r=a.points[a.points.length-1],a.direction=R.direction(a.points[a.points.length-2],a.points[a.points.length-1])),r}function c3(n,t,e){var s,i=t.segments[t.segments.length-2],r=i.points[i.points.length-1];(("Top"===i.direction||"Bottom"===i.direction)&&r.x===n[1].x||("Left"===i.direction||"Right"===i.direction)&&r.y===n[1].y)&&(i.points[i.points.length-1]=n[1],s=R.direction(i.points[0],i.points[i.points.length-1]),void 0!==t.sourceWrapper&&void 0===t.sourcePortWrapper&&s===_n(i.direction)&&("Left"===i.direction||"Right"===i.direction?i.points[0].x="Right"===i.direction?i.points[0].x-t.sourceWrapper.corners.width:i.points[0].x+t.sourceWrapper.corners.width:i.points[0].y="Bottom"===i.direction?i.points[0].y-t.sourceWrapper.corners.height:i.points[0].y+t.sourceWrapper.corners.height),i.direction=s,i.length=R.distancePoints(i.points[0],i.points[i.points.length-1]),n.splice(0,1))}function wI(n,t,e,i){var o=i?n.targetPadding:n.sourcePadding,a=i?n.targetPortWrapper:n.sourcePortWrapper,l=new Ne(a.bounds.x-o,a.bounds.y-o,a.actualSize.width+2*o,a.actualSize.height+2*o),h=[l.topLeft,l.topRight,l.bottomRight,l.bottomLeft];h[h.length]=h[0];var d=i?e.point:t.point;return Lx({x1:t.point.x,y1:t.point.y,x2:e.point.x,y2:e.point.y},h,0,d)||d}function d3(n,t){var e=[],i=dF(0,n.corners,t);i.push(i[0]);for(var r=0;r0){var r=void 0,s=[],o=t.point;for(r=0;r1&&R.equals(a.points[0],a.points[1])&&n.segments.splice(r,1),a)for(var l=0;l0||0===r)&&i.push(a.points[parseInt(l.toString(),10)])}}return i}function Ax(n,t,e){return"Top"===n||"Bottom"===n?e.x>t.x?"Right":"Left":e.y>t.y?"Bottom":"Top"}function Bv(n){if("Straight"===n.type||"Bezier"===n.type){if(0===n.segments.length||n.segments.length>0&&!R.isEmptyPoint(n.segments[n.segments.length-1].point))if("Bezier"===n.type){var t=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0},!0);n.segments.push(t)}else t=new Hl(n,"segments",{type:"Straight"},!0),n.segments.push(t)}else{if(n.segments.length>0)for(var e=!1,i=0;i=t.corners.left&&e.point.x<=t.corners.right&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom)t.direction=e.point.y>t.point.y?"Bottom":"Top",i=Ys(n,t,e,"Top"===t.direction?t.point.y-t.corners.top+20:t.corners.bottom-t.point.y+20);else if(n.sourcePortWrapper&&r===_n(o)){var h;("Left"===r||"Right"===r)&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom?(t.direction=e.point.y>t.point.y?"Bottom":"Top",h=t.corners.height/2+20):("Top"===r||"Bottom"===r)&&t.point.x>=t.corners.left&&t.point.x<=t.corners.right&&(t.direction=e.point.x>t.point.x?"Right":"Left",h=t.corners.width/2+20),t.direction&&h?i=Ys(n,t,e,h,!0):(t.direction=o,i=Ol(t,e))}else if(!n.sourcePortWrapper||r!==e.direction||"Top"!==r&&"Bottom"!==r||t.corners.center.x!==e.corners.center.x)if(t.direction===e.direction)if(("Left"===t.direction||"Right"===t.direction)&&e.point.y>t.corners.top-20&&e.point.yt.corners.left-20&&e.point.xt.point.y?"Bottom":"Top",i=Ys(n,t,e,"Bottom"===t.direction?t.corners.bottom-t.point.y+20:t.point.y-t.corners.top+20);else t.direction=o,i=Ys(n,t,e,"Top"===o||"Bottom"===o?n.sourceWrapper.height/2+20:n.sourceWrapper.width/2+20),t.point=i[1],"Left"===o||"Right"===o?(e.direction=o,e.point="Left"===o?e.corners.middleLeft:e.corners.middleRight):Fv(n.targetWrapper,t,e,n),i=Ys(n,t,e);return i}function f3(n,t){if(void 0!==n.targetWrapper&&void 0===n.targetPortWrapper&&xn(n.targetWrapper).containsPoint(t.point,1)){var i=n.targetWrapper,r=n.segments[n.segments.length-2],s=r.points[r.points.length-1],o=_n(r.direction);"Bottom"===o?s.yi.corners.top-1&&(r.points[r.points.length-1].y=i.corners.top-20,r.length=R.distancePoints(r.points[0],r.points[r.points.length-1])):"Left"===o?s.x>i.corners.left-1&&(r.points[r.points.length-1].x=i.corners.left-20,r.length=R.distancePoints(r.points[0],r.points[r.points.length-1])):"Right"===o&&s.x0||0===e)&&t.push(i.points[parseInt(r.toString(),10)]);return t}function Fv(n,t,e,i){var r,s={x:0,y:0},o=CI(n,n.corners,n.bounds),a=t.margin,l=t.point;if(o.bottomCenter.y+a.bottoml.y)r="Top",s=o.topCenter;else if(o.middleLeft.x-a.left>l.x)r="Left",s=o.middleLeft;else if(o.middleRight.x+a.rightc&&(f=c,r="Right",s=o.middleRight),f>d&&(f=d,r="Bottom",s=o.bottomCenter),f>u&&(r="Left",s=o.middleLeft)}e.point=s,e.direction=r;var p=Nl(o,_n(e.direction));e.point=qa(i,0,e.point,p,n===i.targetWrapper)}function g3(n,t,e,i,r){var s,o,a;if(s=function zre(n,t){var e=!1;switch(n){case"Left":switch(t){case"Right":case"Bottom":e=!0}break;case"Top":switch(t){case"Left":case"Right":case"Bottom":e=!0}break;case"Bottom":"Right"===t&&(e=!0)}return e}(t.direction,e.direction),s&&b3(t,e),"Right"===t.direction&&"Left"===e.direction)a=function Mre(n,t,e,i){var o=Math.round(Math.abs(t.point.y-e.point.y)),a={x:Math.max(t.point.x,t.corners.right),y:t.point.y},l={x:Math.min(e.point.x,e.corners.left),y:e.point.y},h=Xa(n);if(i){var c=l;l=a,a=c}return t.corners.bottom+he.corners.bottom+h||("Bezier"!==n.type||e.corners.left-t.corners.right<=2*h&&e.corners.left-t.corners.right>=5)&&(h=0),t.margin={left:h,right:h,top:h,bottom:h},e.margin={left:h,right:h,top:h,bottom:h},0===o&&(t.corners.right=e.corners.right?void 0!==i&&(i.offsetYe.corners.bottom+e.margin.bottom)||void 0===i&&t.corners.middleRight.ye.corners.bottom+e.margin.bottom&&t.corners.top>e.corners.bottom||void 0===i&&t.corners.middleRight.y>e.corners.bottom||void 0!==i&&i.offsetYe.corners.top||void 0===i&&t.corners.middleRight.y>e.corners.bottom?Ae.Three:t.corners.rightr.offsetY+e.margin.right||void 0===r&&t.corners.top>e.corners.middleRight.y||void 0!==r&&(void 0!==i&&i.offsetXr.offsetX||void 0===r&&t.corners.left>e.corners.topCenter.x?Ae.Four:Ae.Two:void 0!==s&&Math.abs(t.corners.right-e.corners.left)<=5&&Math.abs(s.offsetY-e.corners.top)<=5||void 0!==r&&t.corners.right=25&&t.corners.middleRight.y+t.margin.righte.corners.bottom+e.margin.bottom||void 0===o&&t.corners.middleRight.y>e.corners.bottom+e.margin.bottom?t.corners.top>e.corners.bottom?void 0!==a&&t.corners.right+t.margin.righta.offsetX||void 0===a&&t.corners.left>e.corners.bottomCenter.x?Ae.Four:Ae.Two:void 0!==o&&Math.abs(t.corners.right-e.corners.left)<=25&&Math.abs(o.offsetY-e.corners.bottom)<=25?Ae.Two:Ae.Four}(n,t,e,s);else if("Bottom"===t.direction&&"Top"===e.direction)a=function Dre(n,t,e){var r=t.point.x-e.point.x,s=Xa(n);return t.corners.right+se.corners.right+s||("Bezier"!==n.type||e.corners.top-t.corners.bottom<=2*s&&e.corners.top-t.corners.bottom>=5)&&(s=0),t.margin={left:s,right:s,top:s,bottom:s},e.margin={left:s,right:s,top:s,bottom:s},0===r&&t.corners.bottome.corners.right+e.margin.right||void 0===i&&t.corners.bottomCenter.x>e.corners.right+e.margin.right?Ae.Three:t.corners.bottomr.offsetX||void 0===r&&t.corners.left>e.corners.left||void 0!==r&&t.corners.right+t.margin.righte.corners.bottom?Ae.Five:0===s||0===o?Ae.One:Ae.Three}(n,t,e)}else"Bottom"===t.direction&&"Left"===e.direction?a=function xre(n,t,e,i){var r=n.sourcePortWrapper,s=n.targetPortWrapper,o=Xa(n);if(e.margin={left:o,right:o,top:o,bottom:o},t.margin={top:o,bottom:o,left:o,right:o},i){var l=r;r=s,s=l}return void 0!==r&&r.offsetXs.offsetY||void 0===s&&t.corners.top>e.corners.middleLeft.y?Ae.Four:Ae.Two:void 0!==s&&Math.abs(t.corners.right-e.corners.left)<=25&&Math.abs(s.offsetY-t.corners.bottom)<=25?Ae.Two:Ae.Four}(n,t,e,s):"Left"===t.direction&&"Left"===e.direction?a=function Lre(n,t,e){var i=n.sourcePortWrapper,r=n.targetPortWrapper,s=Xa(n);t.margin={left:s,right:s,top:s,bottom:s},e.margin={left:s,right:s,top:s,bottom:s};var o=Math.round(Math.abs(t.point.x-e.point.x)),a=Math.round(Math.abs(t.point.y-e.point.y));return t.corners.leftr.offsetY||void 0===r&&t.corners.top-t.margin.top>e.corners.middleLeft.y?Ae.Three:t.corners.righte.corners.bottom+e.margin.bottom||void 0===i&&t.corners.middleLeft.y>e.corners.bottom+e.margin.bottom?Ae.Three:t.corners.left>e.corners.right?Ae.Five:0===o||0===a?Ae.One:Ae.Three}(n,t,e):"Left"===t.direction&&"Top"===e.direction?a=function Are(n,t,e,i){var s=n.sourcePortWrapper,o=Xa(n);e.margin={left:o,right:o,top:o,bottom:o},t.margin={top:o,bottom:o,left:o,right:o};var a=n.targetPortWrapper,l={x:Math.min(t.point.x,t.corners.left),y:t.point.y},h={x:e.point.x,y:Math.min(e.point.y,e.corners.top)};if(i){var c=s;s=a,a=c;var d=l;l=h,h=d}return void 0!==s&&s.offsetYa.offsetX||void 0===a&&t.corners.left-t.margin.left>e.corners.topCenter.x?Ae.Two:Ae.Four:void 0!==a&&t.corners.rightr.offsetX||void 0===r&&t.corners.left>e.corners.left||void 0!==r&&t.corners.right+t.margin.righte.corners.right+e.margin.right||void 0===i&&t.corners.left>e.corners.right||void 0!==i&&i.offsetXe.corners.bottom?Ae.Five:0===s||0===o?Ae.One:Ae.Three}(n,t,e));return s&&b3(t,e),o=function Ore(n,t,e,i,r,s){var l,d,h=n.sourceWrapper.corners,c=n.targetWrapper.corners,u=20,f={corners:e.corners,point:e.point,direction:e.direction,margin:e.margin},p={corners:i.corners,point:i.point,direction:i.direction,margin:i.margin};if(!(f.direction===p.direction&&t!==Ae.Five||f.direction!==_n(p.direction)&&t!==Ae.Three))switch(f.direction){case"Left":h.middleLeft.x>c.middleRight.x&&(d=(h.middleLeft.x-c.middleRight.x)/2,u=s?d:Math.min(u,d));break;case"Right":h.middleRight.xc.bottomCenter.y&&(d=(h.topCenter.y-c.bottomCenter.y)/2,u=s?d:Math.min(u,d));break;case"Bottom":h.bottomCenter.yf&&hf)&&o>c&&o<=d&&e>=20&&(s=n.point.x-t.corners.left+s),i&&n.direction===t.direction&&n.corners.left>t.corners.left&&n.corners.left-t.corners.right>=20&&(s=(n.corners.left-t.corners.right)/2),p=Fn(n.point,s,180);break;case"Top":(o>c&&oc)&&h>f&&h<=u&&e>=20&&(s=n.point.y-t.corners.top+s),i&&n.direction===t.direction&&n.corners.top>t.corners.top&&n.corners.top-t.corners.bottom>=20&&(s=(n.corners.top-t.corners.bottom)/2),p=Fn(n.point,s,270);break;case"Right":(h>f&&hf)&&a=c&&e>=20&&(s=t.corners.right-n.point.x+s),i&&n.direction===t.direction&&n.corners.right=20&&(s=(t.corners.left-n.corners.right)/2),p=Fn(n.point,s,0);break;case"Bottom":(o>c&&oc)&&l=f&&e>=20&&(s=t.corners.bottom-n.point.y+s),i&&n.direction===t.direction&&n.corners.bottom=20&&(s=(t.corners.top-n.corners.bottom)/2),p=Fn(n.point,s,90)}r=[n.point,p];var g=void 0;if("Top"===n.direction||"Bottom"===n.direction){var v=n.direction;n.direction=p.x>t.point.x?"Left":"Right",n.point=p,r=EI(n,t,v,r,g=i?.5*Math.abs(p.x-t.point.x):g,i)}else v=n.direction,n.direction=p.y>t.point.y?"Top":"Bottom",n.point=p,r=EI(n,t,v,r,g=i?.5*Math.abs(p.y-t.point.y):g,i);return r}(f,p,u,g)),l}(n,a,t,e,i,r),"Bezier"===n.type&&function Pre(n,t,e){if("Bezier"===n.type)if(0===n.segments.length){var i=e[0],r=e[e.length-1];if(t===Ae.One){var s=Math.min(20,.5*R.findLength(i,r)),o={angle:Gt(i,r),distance:s},a={angle:Gt(r,i),distance:s},l=R.direction(i,r),c=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,orientation:"Left"===l||"Right"===l?"Horizontal":"Vertical"},!0);n.segments.push(c)}else if(t===Ae.Two)o={angle:Gt(i,d=e[1]),distance:.5*R.findLength(i,d)},a={angle:Gt(r,d),distance:.5*R.findLength(r,d)},l=R.direction(i,d),c=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,orientation:"Left"===l||"Right"===l?"Horizontal":"Vertical"},!0),n.segments.push(c);else if(t===Ae.Three){var d={x:.5*((u=e[1]).x+(f=e[e.length-2]).x),y:.5*(u.y+f.y)},p=(o={angle:Gt(i,u),distance:.5*R.findLength(i,u)},a={angle:Gt(d,u),distance:.5*R.findLength(d,u)},R.direction(i,u)),v=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,point:d,orientation:"Left"===p||"Right"===p?"Horizontal":"Vertical"},!0);n.segments.push(v);var y={angle:Gt(d,f),distance:.5*R.findLength(d,f)},S={angle:Gt(r,f),distance:.5*R.findLength(r,f)},b=R.direction(d,f),w=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:y,vector2:S,orientation:"Left"===b||"Right"===b?"Horizontal":"Vertical"},!0);n.segments.push(w)}else if(t===Ae.Four){var D={x:.5*((u=e[1]).x+(f=e[2]).x),y:.5*(u.y+f.y)},A={x:.5*(f.x+(C=e[3]).x),y:.5*(f.y+C.y)};o={angle:Gt(i,u),distance:.5*R.findLength(i,u)},a={angle:Gt(D,u),distance:.5*R.findLength(D,u)},p=R.direction(i,u),v=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,point:D,orientation:"Left"===p||"Right"===p?"Horizontal":"Vertical"},!0),n.segments.push(v),y={angle:Gt(D,f),distance:.5*R.findLength(D,f)},S={angle:Gt(A,f),distance:.5*R.findLength(A,f)},b=R.direction(D,f),w=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:y,vector2:S,point:A,orientation:"Left"===b||"Right"===b?"Horizontal":"Vertical"},!0),n.segments.push(w);var x={angle:Gt(A,C),distance:.5*R.findLength(A,C)},P={angle:Gt(r,C),distance:.5*R.findLength(r,C)},L=R.direction(A,C),N=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:x,vector2:P,orientation:"Left"===L||"Right"===L?"Horizontal":"Vertical"},!0);n.segments.push(N)}else if(t===Ae.Five){var u,f,C,T=e[4],z=(D={x:.5*((u=e[1]).x+(f=e[2]).x),y:.5*(u.y+f.y)},A={x:.5*(f.x+(C=e[3]).x),y:.5*(f.y+C.y)},{x:.5*(C.x+T.x),y:.5*(C.y+T.y)});o={angle:Gt(i,u),distance:.5*R.findLength(i,u)},a={angle:Gt(D,u),distance:.5*R.findLength(D,u)},p=R.direction(i,u),v=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,point:D,orientation:"Left"===p||"Right"===p?"Horizontal":"Vertical"},!0),n.segments.push(v),y={angle:Gt(D,f),distance:.5*R.findLength(D,f)},S={angle:Gt(A,f),distance:.5*R.findLength(A,f)},b=R.direction(D,f),w=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:y,vector2:S,point:A,orientation:"Left"===b||"Right"===b?"Horizontal":"Vertical"},!0),n.segments.push(w),x={angle:Gt(A,C),distance:.5*R.findLength(A,C)},P={angle:Gt(z,C),distance:.5*R.findLength(z,C)},L=R.direction(A,C),N=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:x,vector2:P,point:z,orientation:"Left"===L||"Right"===L?"Horizontal":"Vertical"},!0),n.segments.push(N);var U={angle:Gt(z,T),distance:.5*R.findLength(z,T)},B={angle:Gt(r,T),distance:.5*R.findLength(r,T)},j=R.direction(z,T),oe=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:U,vector2:B,orientation:"Left"===j||"Right"===j?"Horizontal":"Vertical"},!0);n.segments.push(oe)}else c=new fs(n,"segments",{type:"Bezier"},!0),n.segments.push(c)}else for(var ue=0;ue=13?13:n.connectorSpacing<=1?1:n.connectorSpacing}function Gt(n,t){var i=R.findLength({x:t.x,y:n.y},t),r=R.findLength(t,n),s=Math.asin(i/r);return s=180*s/Math.PI,n.xt.y&&(s=360-s):s=n.y0)for(var l=1;lc)&&(s=c,a=h),s>=0&&s<=1)break}}return a}function m3(n,t){var c,d,u,f,p,g,S,b,M,w,D,e=n.x1,i=n.y1,r=n.x2,s=n.y2,o=t.x1,a=t.y1,l=t.x2,h=t.y2;if(w=(c=s-i)*l+(u=e-r)*h+(p=r*i-e*s),0!==(M=c*o+u*a+p)&&0!==w&&y3(M,w)||(b=(d=h-a)*r+(f=o-l)*s+(g=l*a-o*h),0!==(S=d*e+f*i+g)&&0!==b&&y3(S,b)))return null;var A=c*f-d*u;return 0===A?null:(A<0?-A/2:A/2,0,{x:(D=u*g-f*p)<0?(D-0)/A:(D+0)/A,y:(D=d*p-c*g)<0?(D-0)/A:(D+0)/A})}function y3(n,t){return n*t>=0}function S3(n,t,e){switch(t.direction){case"Left":t.point.x>n.left&&(e=t.point.x-n.left>e?t.point.x-n.left+e:e);break;case"Right":t.point.xe?n.right-t.point.x+e:e);break;case"Top":t.point.y>n.top&&(e=t.point.y-n.top>e?t.point.y-n.top+e:e);break;case"Bottom":t.point.ye?n.bottom-t.point.y+e:e)}return e}function Ol(n,t){var e;switch(n.direction){case"Left":case"Right":var i={x:t.point.x,y:n.point.y};e=R.equals(n.point,i)||R.equals(t.point,i)?[n.point,t.point]:[n.point,i,t.point];break;case"Top":case"Bottom":var r={x:n.point.x,y:t.point.y};e=R.equals(n.point,r)||R.equals(t.point,r)?[n.point,t.point]:[n.point,r,t.point]}return e}function Ys(n,t,e,i,r,s){void 0===s&&(s=!1),i||(i=20),s&&t.direction!==e.direction&&(i="Left"===t.direction||"Right"===t.direction?Math.floor(.5*Math.abs(t.point.x-e.point.x)):Math.floor(.5*Math.abs(t.point.y-e.point.y)));var l,h,u,o=n.sourcePortWrapper,c=e.point.x-t.point.x,d=e.point.y-t.point.y;if(!r&&(Math.abs(c)<.001||Math.abs(d)<.001)&&void 0===e.direction)return[t.point,e.point];if(void 0===n.targetWrapper&&Math.abs(c)<=31&&Math.abs(d)<=31){if("Left"===t.direction||"Right"===t.direction?Math.abs(d)<12&&(t.direction=t.point.y>e.point.y?"Top":"Bottom"):Math.abs(c)<12&&(t.direction=t.point.x>e.point.x?"Left":"Right"),Math.abs(c)>12||Math.abs(d)>12)return Ol(t,e);i+=5}return"Left"===t.direction||"Right"===t.direction?("Right"===t.direction?(void 0!==e.direction&&"Right"===e.direction&&(i=Math.max(t.point.x,e.point.x)-t.point.x+i),t.point.x>e.point.x&&void 0===o&&(i=-i)):(void 0!==e.direction&&"Left"===e.direction&&(i=t.point.x-Math.min(t.point.x,e.point.x)+i),(t.point.x>e.point.x||void 0!==o||"Left"===t.direction)&&(i=-i)),u=e.point.y-t.point.y,l=Fn(t.point,i,0),0!=(u=e.point.y-l.y)&&(h=Fn(l,e.point.y-l.y,90))):("Top"===t.direction||"Bottom"===t.direction)&&("Bottom"===t.direction?void 0!==e.direction&&"Bottom"===e.direction&&(i=Math.max(t.point.y,e.point.y)-t.point.y+i):(void 0!==e.direction&&"Top"===e.direction&&(i=t.point.y-Math.min(t.point.y,e.point.y)+i),(t.point.y>e.point.y||void 0!==o||"Top"===t.direction)&&(i=-i)),u=e.point.x-t.point.x,l=Fn(t.point,i,90),0!=(u=e.point.x-l.x)&&(h=Fn(l,e.point.x-l.x,0))),0===u?[t.point,e.point]:[t.point,l,h,e.point]}function EI(n,t,e,i,r,s){var o;switch(void 0===r&&(r=20),void 0===s&&(s=!1),void 0===e?(n.margin={left:2,right:2,top:2,bottom:2},t.margin={left:0,right:5,top:0,bottom:5},s&&(n.margin={left:10,right:10,top:10,bottom:10},t.margin={left:10,right:10,top:10,bottom:10},"Left"===n.direction?(r=Ox(n,t,e,r),n.corners.left-t.corners.right>=5&&(r=Math.abs(n.point.x-n.corners.left)+.5*Math.floor(n.corners.left-t.corners.right))):"Right"===n.direction?(r=kx(n,t,r,e),t.corners.left-n.corners.right>=5&&(r=Math.abs(n.point.x-n.corners.right)+.5*Math.floor(t.corners.left-n.corners.right))):"Top"===n.direction?(r=Nx(n,t,e,r),n.corners.top-t.corners.bottom>=5&&(r=Math.abs(n.point.y-n.corners.top)+.5*Math.floor(n.corners.top-t.corners.bottom))):"Bottom"===n.direction&&(r=Px(n,t,r,e),t.corners.top-n.corners.bottom>=5&&(r=Math.abs(n.point.y-n.corners.bottom)+.5*Math.floor(t.corners.top-n.corners.bottom))))):("Bottom"===n.direction?s?t.corners.top-n.corners.bottom<20&&(r=t.corners.bottom-n.point.y+25):t.corners.top>n.corners.bottom&&t.corners.top-n.corners.bottom<20&&(r=(t.corners.top-n.corners.bottom)/2):"Top"===n.direction?s?n.corners.top-t.corners.bottom<20&&(r=n.point.y-t.corners.top+25):t.corners.bottomn.corners.right&&t.corners.left-n.corners.right<20&&(r=(t.corners.left-n.corners.right)/2):"Left"===n.direction&&(s?n.corners.left-t.corners.right<20&&(r=n.point.x-t.corners.left+25):t.corners.rightt.point.y||"Top"===t.direction&&n.point.yt.point.x||"Left"===t.direction&&n.point.xh||e.corners.top-e.margin.top<=i.point.y&&e.corners.bottom+e.margin.bottom>=i.point.y))if(!s||"Top"!==e.direction&&"Bottom"!==e.direction)c=Math.min(Math.abs(i.corners.left-e.corners.right)/2,20),h=e.corners.right-n.x+c;else{var c=Math.abs(i.corners.left-e.corners.right)/2;h=e.corners.right-n.x+c}else h="Top"===e.direction&&n.y>i.point.y||"Bottom"===e.direction&&n.y=e.corners.left-e.margin.left&&n.x<=e.corners.right+e.margin.right?Math.min(i.corners.left,e.corners.left)-n.x-20:i.corners.left-n.x-20;break;case"Right":if(e.corners.left-e.margin.left>i.corners.right+i.margin.right&&(e.corners.left-e.margin.right-i.corners.right>h||e.corners.top-e.margin.top<=i.point.y&&e.corners.bottom+e.margin.bottom>=i.point.y))if(!s||"Top"!==e.direction&&"Bottom"!==e.direction)c=Math.min(Math.abs(e.corners.left-i.corners.right)/2,20),h=e.corners.left-n.x-c;else{c=Math.abs(e.corners.left-i.corners.right)/2;h=e.corners.left-n.x-c}else h="Top"===e.direction&&n.y>i.point.y||"Bottom"===e.direction&&n.y=e.corners.left-e.margin.left&&n.x<=e.corners.right+e.margin.right?Math.max(i.corners.right,e.corners.right)-n.x+20:i.corners.right-n.x+20}o=Fn(n,h,0),a=Fn(o,i.point.y-n.y,90),l=i.point}else if("vertical"===t){switch(i.direction){case"Top":e.corners.bottom+e.margin.bottomh||e.corners.left-e.margin.left<=i.point.x&&e.corners.right+e.margin.right>=i.point.x)?!s||"Right"!==e.direction&&"Left"!==e.direction?(c=Math.min(Math.abs(i.corners.top-e.corners.bottom)/2,20),h=e.corners.bottom-n.y+c):(c=Math.abs(i.corners.top-e.corners.bottom)/2,h=e.corners.bottom-n.y+c):h="Left"===e.direction&&n.x>i.point.x||"Right"===e.direction&&n.x=e.corners.top-e.margin.top&&n.y<=e.corners.bottom+e.margin.bottom?Math.min(i.corners.top,e.corners.top)-n.y-20:i.corners.top-n.y-20;break;case"Bottom":e.corners.top-e.margin.top>i.corners.bottom+i.margin.bottom&&(e.corners.top-e.margin.top-i.corners.bottom>h||e.corners.left-e.margin.left<=i.point.x&&e.corners.right+e.margin.right>=i.point.x)?!s||"Right"!==e.direction&&"Left"!==e.direction?(c=Math.min(Math.abs(e.corners.top-i.corners.bottom)/2,20),h=e.corners.top-n.y-c):(c=Math.abs(e.corners.top-i.corners.bottom)/2,h=e.corners.top-n.y-c):h="Left"===e.direction&&n.x>i.point.x||"Right"===e.direction&&n.x=e.corners.top-e.margin.top&&n.y<=e.corners.bottom+e.margin.bottom?Math.max(i.corners.bottom,e.corners.bottom)-n.y+20:i.corners.bottom-n.y+20}o=Fn(n,h,90),a=Fn(o,i.point.x-n.x,0),l=i.point}r.push(o),r.push(a),r.push(l)}function Nx(n,t,e,i){return n.corners.top-n.margin.top>t.corners.top+t.margin.top&&n.corners.top-n.margin.top<=t.corners.bottom+t.margin.bottom?(("Right"===t.direction&&n.point.xt.point.x)&&(i+=n.corners.top-t.corners.top),i+=n.point.y-n.corners.top):i+=void 0!==e&&"Left"!==e&&"Right"===t.direction&&n.point.xt.corners.left-t.margin.left&&n.corners.left-n.margin.left<=t.corners.right+t.margin.right?(("Bottom"===t.direction&&n.point.yt.point.y)&&(i+=n.corners.left-t.corners.left),i+=n.point.x-n.corners.left):i+=void 0!==e&&"Top"!==e&&"Bottom"===t.direction&&n.point.y=t.corners.left-t.margin.left?(("Bottom"===t.direction&&n.point.yt.point.y)&&(e+=t.corners.right-n.corners.right),e+=n.corners.right-n.point.x):e+=void 0!==i&&"Top"!==i&&"Bottom"===t.direction&&n.point.y=t.corners.top-t.margin.top?(("Right"===t.direction&&n.point.xt.point.x)&&(e+=t.corners.bottom-n.corners.bottom),e+=n.corners.bottom-n.point.y):e+=void 0!==i&&"Left"!==i&&"Right"===t.direction&&n.point.xp&&d=u&&d=f&&d<=p?"Left":"Right"}function _n(n){switch(n){case"Top":return"Bottom";case"Bottom":return"Top";case"Left":return"Right";case"Right":return"Left"}return"auto"}var w3=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Ac=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},DI=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return w3(t,n),Ac([I()],t.prototype,"width",void 0),Ac([I()],t.prototype,"height",void 0),t}(Ee),Rre=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return w3(t,n),Ac([I()],t.prototype,"width",void 0),Ac([I()],t.prototype,"height",void 0),Ac([I()],t.prototype,"fit",void 0),Ac([I()],t.prototype,"description",void 0),Ac([I()],t.prototype,"template",void 0),Ac([I()],t.prototype,"tooltip",void 0),t}(Ee),Hre=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),kl=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},C3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Hre(t,n),kl([I("")],t.prototype,"id",void 0),kl([I(Number.MIN_VALUE)],t.prototype,"zIndex",void 0),kl([re({},Jn)],t.prototype,"margin",void 0),kl([I(!0)],t.prototype,"visible",void 0),kl([re({},Dd)],t.prototype,"tooltip",void 0),kl([I(!1)],t.prototype,"excludeFromLayout",void 0),kl([I()],t.prototype,"addInfo",void 0),kl([I("None")],t.prototype,"flip",void 0),kl([I("All")],t.prototype,"flipMode",void 0),kl([re({},Rre)],t.prototype,"symbolInfo",void 0),t}(Ee),Bre=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),es=function(n){function t(e,i,r,s){var o=n.call(this)||this;return o.data="",o.nodeId="",o.annotationId="",o.diagramId="",o.diagramId=i,o.nodeId=e,o.annotationId=r,o.templateFn=UF(s),o}return Bre(t,n),t.prototype.getNodeTemplate=function(){return this.templateFn},Object.defineProperty(t.prototype,"content",{get:function(){return this.data},set:function(e){this.data=e,this.canReset||(this.canReset=!0,this.isTemplate||(this.template=Hh(this,!0)),this.canReset=!1,this.isDirt=!0)},enumerable:!0,configurable:!0}),t}(hs),zx=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),cs=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},E3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return zx(t,n),cs([I("")],t.prototype,"id",void 0),cs([I("transparent")],t.prototype,"fill",void 0),cs([I("black")],t.prototype,"iconStrokeColor",void 0),cs([I(0)],t.prototype,"iconStrokeWidth",void 0),cs([I(!0)],t.prototype,"visibility",void 0),cs([I(10)],t.prototype,"width",void 0),cs([I(10)],t.prototype,"height",void 0),cs([I("transparent")],t.prototype,"handleStrokeColor",void 0),cs([I(1)],t.prototype,"handleStrokeWidth",void 0),cs([I("")],t.prototype,"pathData",void 0),cs([I(0)],t.prototype,"cornerRadius",void 0),cs([re({left:0,right:0,top:0,bottom:0},Jn)],t.prototype,"padding",void 0),cs([re({},Dd)],t.prototype,"tooltip",void 0),t}(Ee),D3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return zx(t,n),cs([re({x:0,y:0},R)],t.prototype,"offset",void 0),cs([re({},Jn)],t.prototype,"margin",void 0),t}(E3),xI=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return zx(t,n),cs([I(.5)],t.prototype,"offset",void 0),cs([I("Center")],t.prototype,"alignment",void 0),cs([re({x:0,y:0},R)],t.prototype,"displacement",void 0),t}(E3);function xd(n){return n?n instanceof Kn||n instanceof Or?n.constraints&Nr.Select:n instanceof de?n.constraints&qe.Select:n.constraints&ie.Select:1}function ro(n){return n?n instanceof Kn||n instanceof Or?n.constraints&Nr.Drag:n instanceof de?n.constraints&qe.Drag:n instanceof ei?1:n.constraints&ie.Drag:1}function Fre(n,t){return n instanceof de?n.constraints&qe.PointerEvents:n.constraints&ie.PointerEvents}function TI(n){return n instanceof de?n.constraints&qe.Delete:n.constraints&ie.Delete}function AI(n){return n.constraints&qe.DragSourceEnd}function LI(n){return n.constraints&qe.DragTargetEnd}function NI(n){return n.constraints&qe.DragSegmentThumb}function OI(n){return n instanceof Kn||n instanceof Or?n.constraints&Nr.Rotate:n.constraints&ie.Rotate}function kI(n){return n.constraints&ie.Shadow}function ua(n){return n instanceof te&&n.constraints&ie.InConnect?n.constraints&ie.InConnect:0}function kh(n){return n&&n.constraints&&!(n.constraints&ai.None)&&n.constraints&ai.InConnect?n.constraints&ai.InConnect:0}function Ph(n){return n instanceof te&&n.constraints&ie.OutConnect?n.constraints&ie.OutConnect:0}function Td(n){return n&&n.constraints&&!(n.constraints&ai.None)&&n.constraints&ai.OutConnect?n.constraints&ai.OutConnect:0}function Pl(n,t){var e=0;return n instanceof Kn||n instanceof Or?e=n.constraints&Nr.Resize:n&&("SouthEast"===t?e=n.constraints&ie.ResizeSouthEast:"East"===t?e=n.constraints&ie.ResizeEast:"NorthEast"===t?e=n.constraints&ie.ResizeNorthEast:"South"===t?e=n.constraints&ie.ResizeSouth:"North"===t?e=n.constraints&ie.ResizeNorth:"SouthWest"===t?e=n.constraints&ie.ResizeSouthWest:"West"===t?e=n.constraints&ie.ResizeWest:"NorthWest"===t&&(e=n.constraints&ie.ResizeNorthWest)),e}function PI(n){return n instanceof de?n.constraints&qe.AllowDrop:n.constraints&ie.AllowDrop}function Ds(n){return n.constraints&nt.Virtualization}function _v(n){return n.tool&ri.SingleSelect}function Uv(n){return n.tool&ri.MultipleSelect}function Lc(n){return n.tool&ri.ZoomPan}function zI(n){return n.tool&ri.ContinuousDraw}function x3(n){return n.tool&ri.DrawOnce}function RI(n){return n.tool&ri.SingleSelect||n.tool&ri.MultipleSelect}function jv(n){return n.constraints&nt.UserInteraction}function T3(n){return n.constraints&nt.ZoomTextEdit}function Vv(n){return function Yre(n){return n.constraints&nt.ApiUpdate}(n)||n.diagramActions&ee.ToolAction}function Rx(n,t){return n.constraints&ai.Draw}function Hx(n,t){return n.constraints&ai.Drag}function HI(n){return!(n&Ga.DrawSelectorBorder)}function A3(n){return!!(n&Ga.PreventRenderSelector)}var Bx=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Wv=function(n){function t(){var e=null!==n&&n.apply(this,arguments)||this;return e.childTable=[],e.cellStyle={},e.desiredRowHeight=[],e.desiredCellWidth=[],e}return Bx(t,n),t.prototype.rowDefinitions=function(){return this.rowDefns},t.prototype.columnDefinitions=function(){return this.colDefns},t.prototype.addObject=function(e,i,r,s,o){if(this.rows.length>=i){var a=this.rows[parseInt(i.toString(),10)];if(a.cells.length>r){o=o||1,s=s||1;var l=a.cells[parseInt(r.toString(),10)];l.columnSpan=Math.max(o,l.columnSpan),l.rowSpan=Math.max(s,l.rowSpan);var h=new $re;(h=e).rowId=i,h.columnId=r,h.columnSpan=o,this.childTable[h.id]=h,this.addObjectToCell(h,l)}}},t.prototype.addObjectToCell=function(e,i){i.children||(i.children=[]),e.style.strokeColor="black",e.style.strokeWidth=1,i.children.push(e)},t.prototype.updateProperties=function(e,i,r,s){this.offsetX=e,this.offsetY=i,this.width=r,this.height=s},t.prototype.setDefinitions=function(e,i){this.rowDefns=e,this.colDefns=i,this.children=[],this.rows=this.rows||[];for(var r=0;r0){for(var h=0;hi&&this.updateRowHeight(e,l,!1)}},t.prototype.setTextRefresh=function(e){if(e.children&&e.children.length)for(var i=e.children,r=0;ri&&this.updateColumnWidth(e,a,!1)}},t.prototype.calculateCellWidth=function(e){for(var i,r,s,o=0;os.bounds.width&&(0===s.children.length||void 0===s.children[0].maxWidth)?s.outerBounds.width:s.bounds.width,i=i?is.bounds.height?s.outerBounds.height:s.bounds.height,i=i?i0?e.children[0]:void 0;if(a&&1===e.columnSpan){o="Width"===i?a.bounds.right:a.bounds.bottom,s||(s="Width"===i?a.bounds.width:a.bounds.height);for(var l=0;lo){var d=c-o+("Width"===i?a.bounds.width:a.bounds.height);s&&(s=s0?this.rowDefns.splice(e,0,i):this.rowDefns.push(i);var s=new L3;s.cells=[],(new Ad).width=this.width,this.addCellInRow(this.colDefns,i,s),e>this.rows.length-1?this.rows.push(s):this.rows.splice(e,0,s),r&&(this.measure(new me(this.width,this.height)),this.arrange(this.desiredSize))},t.prototype.addColumn=function(e,i,r){var s,o,a,l,h=this.rows;this.colDefns.length>0?this.colDefns.splice(e,0,i):this.colDefns.push(i),void 0!==this.width&&(this.width+=i.width);for(var c=0;cs.cells.length-1?s.cells.push(l):s.cells.splice(e,0,l),this.children.push(l);r&&(this.measure(new me(this.width,this.height)),this.arrange(this.desiredSize))},t.prototype.removeRow=function(e){var i,r,o=this.rows[parseInt(e.toString(),10)];this.height-=this.rowDefns[parseInt(e.toString(),10)].height;for(var a=0;a0){var r=0,s=0;i=new me(0,0),this.calculateSize();for(var o=0,a=this.rows;o0){for(var o=this.offsetX-e.width*this.pivot.x,a=this.offsetY-e.height*this.pivot.y,l=o,h=0,c=this.rows;h1&&this.children.splice(this.children.indexOf(p)+1,p.columnSpan-1),p.rowSpan>1)for(y=s,S=0;y+p.rowSpan-10){for(var c=0;c0?1:0,v=0;v0||a.outEdges.length>0))for(f=a.inEdges.concat(a.outEdges),s=0;s0)for(o=0;o1)for(a=1;a0))if(h=n.wrapper.children[0],"Horizontal"===e.orientation)for(o=e.header&&e.hasHeader?h.rows[1]:h.rows[0],r=0;r0){var e=void 0;t.lineRoutingModule&&t.constraints&nt.LineRouting&&t.lineRoutingModule.renderVirtualRegion(t,!0);for(var i=0;i0?o+1:o)].height=t.wrapper.height;else if(t.isPhase)for(l[t.rowIndex-o].offset=t.wrapper.height,p=0;p0?1:0)].width=t.wrapper.width}function FI(n,t){var i=n.shape,r=i.header&&i.hasHeader?1:0;return"Horizontal"===i.orientation?t.rowIndex-(r+=i.phases.length>0?1:0):t.columnIndex-(i.phaseSize&&i.phases.length>0?1:0)}function _I(n){var t=0,e=n.shape;return"Horizontal"===e.orientation&&(t=e.header&&e.hasHeader?1:0),e.phases.length>0&&e.phaseSize&&(t+=1),t}function UI(n,t,e,i){var r=n.shape;if(r.phases.length>0){var s=t.nameTable[r.phases[parseInt(i.toString(),10)].header.id];s&&s.maxWidth0?u+1:u);var w=Nc(n,o),C=void 0!==i?i:l.lanes.length;if(u+=C,r={element:M,cause:n.diagramActions,diagramAction:n.getDiagramAction(n.diagramActions),state:"Changing",type:"Addition",cancel:!1,laneIndex:C},n.triggerEvent(Ce.collectionChange,r),!r.cancel){if(c){var D=new Yv;D.height=e.height,o.addRow(u,D,!1),s.height=void 0!==s.height?s.height+e.height:s.height,s.wrapper.height=o.height=s.height}else{var A=new Ad;A.width=e.width,o.addColumn(C+1,A,!1),s.width&&(s.width+=e.width,s.wrapper.width=o.width=s.width),n.diagramActions&ee.UndoRedo||(o.rows[0].cells[0].columnSpan+=1)}n.diagramActions&ee.UndoRedo||(M.id=""===M.id?Qe():M.id),void 0!==i?l.lanes.splice(i,0,M):l.lanes.push(M),r={element:M,cause:n.diagramActions,diagramAction:n.getDiagramAction(n.diagramActions),state:"Changed",type:"Addition",cancel:!1,laneIndex:C},n.triggerEvent(Ce.collectionChange,r),O3(o,n,s,u,C,c),h="Horizontal"===l.orientation?n.nameTable[o.rows[parseInt(u.toString(),10)].cells[0].children[0].id]:l.header&&l.hasHeader?n.nameTable[o.rows[1].cells[parseInt(u.toString(),10)].children[0].id]:n.nameTable[o.rows[0].cells[parseInt(u.toString(),10)].children[0].id],n.diagramActions&ee.UndoRedo||(d={type:"LaneCollectionChanged",changeType:"Insert",undoObject:$(M),redoObject:$(h),category:"Internal"},n.addHistoryEntry(d)),Xf(n,s,"Horizontal"===l.orientation?u:l.header&&l.hasHeader?1:0),Gf(s),Oc(n,s);var P=!1;if((f=e.children)&&f.length>0)for(p=0;p0){var o=t.children[0],a=n.nameTable[o.id];(function sne(n,t,e){return n.left-(e.left||0)<=t.x&&n.right+(e.right||0)>=t.x&&n.top-(e.top||0)<=t.y&&n.bottom+(e.bottom||0)>=t.y})(o.bounds,e,r)&&(n.addChild(a,i),s=!0)}return s}function one(n,t,e){if("SwimLane"===t.shape.type){var i=void 0,r=void 0,s=void 0,a=void 0,l=void 0,h=void 0,c=t.wrapper.bounds.x,d=t.wrapper.bounds.y,u=t.shape,f=u.padding,p=u.phases,g=void 0,v=t.wrapper.children[0],y="Horizontal"===u.orientation;if(i=u.header&&u.hasHeader?0:-1,u.phases.length>0&&(i+=1),e.offset>(y?u.lanes[0].header.width:u.lanes[0].header.height)){for(h=0;he.offset){if(g=h>0?e.offset-(h>0?p[h-1]:s).offset:e.offset,y){var b=v.columnDefinitions()[parseInt(h.toString(),10)];b.width-=g,(a=n.nameTable[u.phases[parseInt(h.toString(),10)].header.id]).maxWidth=a.wrapper.maxWidth=b.width,v.updateColumnWidth(h,b.width,!1);var M=new Ad;M.width=g,l=h,v.addColumn(h,M,!1);break}var w=v.rowDefinitions()[h+i];w.height-=g,a=n.nameTable[u.phases[parseInt(h.toString(),10)].header.id],v.updateRowHeight(h+i,w.height,!1);var C=new Yv;C.height=g,l=h,v.addRow(h+i,C,!1);break}if(n.diagramActions&ee.UndoRedo&&void 0===l&&(D=n.historyManager.currentEntry.next).isLastPhase&&function ane(n,t,e,i,r,s){var a=t.shape.phases[n-2],l=e.previousPhase.offset;if(r){var h=i.columnDefinitions()[n-1],c=new Ad;n>1?(c.width=h.width-(l-a.offset),h.width=l-a.offset):(c.width=h.width-l,h.width=l),i.updateColumnWidth(n-1,h.width,!1),i.addColumn(n,c,!1)}else{h=i.rowDefinitions()[parseInt(n.toString(),10)];var d=new Yv;n>1?(d.height=e.undoObject.offset-l,h.height=l-a.offset):(d.height=h.height-l,h.height=l),i.updateRowHeight(n,h.height,!1),i.addRow(1+n,d,!1)}}(l=p.length,t,D,v,y),l>=0){var A=new lb(t.shape,"phases",e,!0);if(n.diagramActions&ee.UndoRedo||(A.id+=Qe()),u.phases.splice(l,0,A),Fx(v,n,t,i,y,l),y){if(r=n.nameTable[v.rows[parseInt(i.toString(),10)].cells[parseInt(l.toString(),10)].children[0].id],0===l&&u.header&&u.hasHeader){v.rows[0].cells[0].children=v.rows[0].cells[1].children,v.rows[0].cells[1].children=[];for(var x=v.rows[0],P=0;Pl+1){var O=n.nameTable[v.rows[parseInt(i.toString(),10)].cells[l+1].children[0].id];v.updateColumnWidth(l+1,L[l+1].width,!0,f),O.maxWidth=O.wrapper.maxWidth=L[l+1].width}t.width=t.wrapper.width=t.wrapper.children[0].width=v.width}else{r=n.nameTable[v.rows[i+l].cells[0].children[0].id];var N=v.rowDefinitions(),T=N[i+l].height;(function hne(n,t,e,i,r){for(var o,a,l=e.rows[parseInt(i.toString(),10)],h=e.rows[i+1],c=e.rows[i-1],d=1;di+l+1&&v.updateRowHeight(i+l+1,T=N[i+l+1].height,!0,f),t.height=t.wrapper.height=t.wrapper.children[0].height=v.actualSize.height}if(Gf(t),t.width=t.wrapper.actualSize.width,Oc(n,t),n.drag(t,c-t.wrapper.bounds.x,d-t.wrapper.bounds.y),BI(t,n),n.commandHandler.select(r),!(n.diagramActions&ee.UndoRedo)){var D={type:"PhaseCollectionChanged",changeType:"Insert",undoObject:$(A),redoObject:$(r),category:"Internal"};n.addHistoryEntry(D)}n.updateDiagramObject(t)}}}}function H3(n,t,e,i,r,s,o){var a,l,p,h=t.shape,c="Horizontal"===h.orientation,d=t.wrapper.children[0],g=c?s:o;e?(a=c?e.bounds.x+e.bounds.width:e.bounds.x,l=c?e.bounds.y:e.bounds.y+e.bounds.height):(a=d.bounds.x,l=r.bounds.y);var v=new Ne(a,l,i.desiredCellWidth,i.desiredCellHeight),S=Qv(n,0,t,{id:t.id+(c?h.lanes[g-2]:h.lanes[g-1]).id+Qe()[0],rowIndex:s,columnIndex:o,width:i.minWidth,height:i.minHeight,style:(c?h.lanes[g-2]:h.lanes[g-1]).style,constraints:ie.Default|ie.AllowDrop,container:{type:"Canvas",orientation:c?"Horizontal":"Vertical"}},!1,!1,!0);if(S.children[0].isCalculateDesiredSize=!1,d.addObject(S,s,o),r&&r.children&&r.children.length)for(p=0;p1)for(var p=1;ph.margin.left&&(h.margin.left=f)):(h.margin.top-=e.desiredCellHeight,f>h.margin.top&&(h.margin.top=f)))}(n,r,i,v,S,c,e)}function B3(n,t,e){if("SwimLane"===t.shape.type&&("ResizeSouth"===e||"ResizeEast"===e)){var i=t.shape,r=t.wrapper.children[0],s=void 0,o=void 0;"ResizeSouth"===e?"Vertical"===i.orientation?s=r.rows[r.rows.length-1].cells[0]:(o=r.rows.length-1,s=r.rows[parseInt(o.toString(),10)].cells[r.rows[parseInt(o.toString(),10)].cells.length-1]):(o=i.header&&i.hasHeader?1:0,s=r.rows[parseInt(o.toString(),10)].cells[r.rows[parseInt(o.toString(),10)].cells.length-1]),n.commandHandler.select(n.nameTable[s.children[0].id])}}function jI(n,t,e,i,r,s){var o,a,l,c,u,f,p,d=Qe(),g=n.shape,v=g.phases,y=n.offsetX-n.wrapper.actualSize.width/2,S=n.offsetY-n.wrapper.actualSize.height/2;if("Vertical"===g.orientation&&(S+=g.header&&g.hasHeader?g.header.height:0),!s)for(r||(n.id+=d,g&&g.header&&g.hasHeader?g.header.id+=d:g.header=void 0),o=0;v&&o0&&s.columnIndex>0||s.isLane)?(a=function Sne(n,t,e){for(var i=new Ne,r="SwimLane"===n.shape.type?n.wrapper.children[0].rows:n.wrapper.rows,s=e?1:0;s=0;a--)i?i.id===o.children[parseInt(a.toString(),10)].id&&o.children.splice(a,1):(n.removeDependentConnector(o.children[parseInt(a.toString(),10)]),n.diagramActions&ee.UndoRedo||(n.diagramActions=n.diagramActions|ee.UndoRedo,s=!0),n.remove(o.children[parseInt(a.toString(),10)]),o.children.splice(a,1),s&&(n.diagramActions=n.diagramActions&~ee.UndoRedo))}function dne(n){return n.children[0]}function qv(n,t){t&&(n.nodes.splice(n.nodes.indexOf(t),1),n.removeFromAQuad(t),n.removeObjectsFromLayer(t),delete n.nameTable[t.id],n.removeElements(t))}function _3(n,t,e,i){var r;if("SwimLane"===e.shape.type){var s=e.shape,o=void 0;if(1===s.lanes.length)n.remove(e);else{var a=e.wrapper.bounds.x,l=e.wrapper.bounds.y,h=void 0,c=void 0,d=void 0,u=void 0,p=e.wrapper.children[0];if(o=i?s.lanes.indexOf(i):FI(e,t),r={element:t,cause:n.diagramActions,diagramAction:n.getDiagramAction(n.diagramActions),state:"Changing",type:"Removal",cancel:!1,laneIndex:o},n.triggerEvent(Ce.collectionChange,r),!r.cancel){var g=s.lanes[parseInt(o.toString(),10)],v=g.children;g.children=[];for(var y=0;y0)for(u=0;u0)for(u=0;u0)for(e=0;e1){c===l.phases.length-1&&(o=!0,a=$(l.phases[c-1]));var u=$(l.phases[parseInt(c.toString(),10)]);if(l.phases.splice(c,1),!(n.diagramActions&ee.UndoRedo)){var f={type:"PhaseCollectionChanged",changeType:"Remove",undoObject:u,previousPhase:a,redoObject:$(t),category:"Internal",isLastPhase:o};n.addHistoryEntry(f)}"Horizontal"===l.orientation?function fne(n,t,e,i){var r,s,o,a,l,h,c,d,u,f,p,g;for(i=void 0!==i?i:e.columnIndex,c=0;c1&&(s=r.cells[parseInt(i.toString(),10)],l=(o=r.cells.length-1===i?r.cells[i-1]:r.cells[i+1]).children[0],s.children.length>0))if(p=n.nameTable[(a=s.children[0]).id],0===o.children.length&&s.children.length>0)o.children=s.children,o.columnSpan=s.columnSpan-1;else{for(d=0;d0){var M=s.children[0],w=n.nameTable[M.id];if(i=e.x&&a.bounds.y<=e.y&&a.bounds.bottom>=e.y){var l=void 0,h=a.bounds.y,c=a.bounds.x,d=n.nameTable[r.parentId]||r;if("SwimLane"===d.shape.type)o=Zv(r,d,t,n,!0);else{var f=n.nameTable[r.parentId]||r,p=f.shape;l=f.wrapper,a.actualSize.widtha.outerBounds.x)&&(void 0!==r.rowIndex?(l.updateColumnWidth(r.columnIndex,a.outerBounds.width,!0),"Horizontal"===p.orientation&&p.phaseSize&&UI(f,n,a,r.columnIndex),Oc(n,f),n.drag(f,c-a.bounds.x,h-a.bounds.y)):n.scale(r,1+(a.outerBounds.width-a.actualSize.width)/a.actualSize.width,1,a.outerBounds.xa.outerBounds.y)&&(void 0!==r.rowIndex?(l.updateRowHeight(r.rowIndex,a.outerBounds.height,!0),n.drag(f,c-a.bounds.x,h-a.bounds.y)):n.scale(r,1,1+(a.outerBounds.height-a.actualSize.height)/a.actualSize.height,a.outerBounds.y=e.x&&a.bounds.y<=e.y&&a.bounds.bottom>=e.y)&&!(t.constraints&ie.AllowMovingOutsideLane)){var l=$(t);n.clearSelection(),W3(n,t),t.parentId="",t.parentObj=n,t.propName="nodes";var h={type:"ChildCollectionChanged",category:"Internal",undoObject:l,redoObject:$(t)};n.addHistoryEntry(h),n.commandHandler.isContainer&&(n.commandHandler.isContainer=!1,n.endGroupAction()),Y3(t,n)}n.protectPropertyChange(o)}}function VI(n,t){var e,i,r;return n.enableServerDataBinding(!1),ce()||(n.selectedObject.helperObject?r=n.selectedObject.helperObject:(n.selectedItems.nodes.length>0||n.selectedItems.connectors.length>0)&&(t instanceof ei&&t.nodes.length+t.connectors.length===1?(e=t.nodes.length>0?t.nodes[0]:t.connectors[0],i=n.selectedItems.wrapper.children[0]):(e=t,i=n.selectedItems.wrapper),n.selectedObject.actualObject=e,!n.currentSymbol&&(e.isLane&&Vx(e,n)&&Dn(n,e)||!e.isLane&&Dn(n,e)||n.constraints&nt.LineRouting&&n.selectedItems.nodes.length>0))&&(r=function Ine(n,t){for(var e,i={},r=0,s=Object.keys(t);r=t.x-e&&n.x<=t.x+e&&n.y>=t.y-e&&n.y<=t.y+e}function $a(n){return n.selectedItems.nodes.length>0||n.selectedItems.connectors.length>0}function G3(n){return 1===n.selectedItems.connectors.length&&!n.selectedItems.nodes.length}function _r(n,t,e,i){if(void 0===e&&(e=!0),t instanceof ei)return!0;if(t instanceof te)for(;t;){if(-1!==n.selectedItems.nodes.indexOf(t)&&void 0===n.selectedItems.annotation)return!0;if(e)break;t=n.nameTable[t.parentId]}else if(t instanceof de){if(-1!==n.selectedItems.connectors.indexOf(t)&&void 0===n.selectedItems.annotation)return!0}else if((t instanceof Kn||t instanceof Or)&&n.selectedItems.annotation&&n.selectedItems.wrapper.children[0].id===i.id)return!0;return!1}var Wx={None:"default",Rotate:"crosshair",Select:"default",Drag:"move",ResizeWest:"w-resize",ResizeEast:"e-resize",ResizeSouth:"s-resize",ResizeNorth:"n-resize",Draw:"crosshair",PortDraw:"crosshair",ResizeNorthEast:"ne-resize",ResizeNorthWest:"nw-resize",ResizeSouthEast:"se-resize",ResizeSouthWest:"sw-resize",ConnectorSourceEnd:"move",ConnectorTargetEnd:"move",BezierSourceThumb:"move",BezierTargetThumb:"move",OrthoThumb:"move",SegmentEnd:"move",Pan:"grab",Hyperlink:"pointer",PortDrag:"pointer",LabelSelect:"pointer",LabelDrag:"move",LabelRotate:"crosshair",LabelResizeWest:"w-resize",LabelResizeEast:"e-resize",LabelResizeSouth:"s-resize",LabelResizeNorth:"n-resize",LabelResizeNorthEast:"ne-resize",LabelResizeNorthWest:"nw-resize",LabelResizeSouthEast:"se-resize",LabelResizeSouthWest:"sw-resize"},ds=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Nd=function(n,t,e,i){return new(e||(e=Promise))(function(r,s){function o(h){try{l(i.next(h))}catch(c){s(c)}}function a(h){try{l(i.throw(h))}catch(c){s(c)}}function l(h){h.done?r(h.value):new e(function(c){c(h.value)}).then(o,a)}l((i=i.apply(n,t||[])).next())})},Od=function(n,t){var i,r,s,o,e={label:0,sent:function(){if(1&s[0])throw s[1];return s[1]},trys:[],ops:[]};return o={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function a(h){return function(c){return function l(h){if(i)throw new TypeError("Generator is already executing.");for(;e;)try{if(i=1,r&&(s=2&h[0]?r.return:h[0]?r.throw||((s=r.return)&&s.call(r),0):r.next)&&!(s=s.call(r,h[1])).done)return s;switch(r=0,s&&(h=[2&h[0],s.value]),h[0]){case 0:case 1:s=h;break;case 4:return e.label++,{value:h[1],done:!1};case 5:e.label++,r=h[1],h=[0];continue;case 7:h=e.ops.pop(),e.trys.pop();continue;default:if(!(s=(s=e.trys).length>0&&s[s.length-1])&&(6===h[0]||2===h[0])){e=0;continue}if(3===h[0]&&(!s||h[1]>s[0]&&h[1]-1&&(r=i.fixedUserHandles[parseInt(o.toString(),10)]);this.commandHandler.triggerEvent(Ce.fixedUserHandleClick,{fixedUserHandle:r,element:e.source}),n.prototype.mouseUp.call(this,e)},t}(us),kd=function(n){function t(e,i){var r=n.call(this,e,!0)||this;return r.isConnected=!1,r.endPoint=i,r}return ds(t,n),t.prototype.mouseDown=function(e){return Nd(this,void 0,void 0,function(){var r,s,o,a,l;return Od(this,function(h){if(this.inAction=!0,this.undoElement=void 0,this instanceof pa||(this.undoElement=$(e.source)),n.prototype.mouseDown.call(this,e),e.source&&e.source.connectors&&(this.oldConnector=$(r=e.source.connectors[0])),"BezierSourceThumb"===this.endPoint||"BezierTargetThumb"===this.endPoint)for(s=0;s0))},t.prototype.endAction=function(){n.prototype.endAction.call(this),this.prevPosition=null,this.endPoint=null},t}(us),fa=function(n){function t(e,i){var r=n.call(this,e,!0)||this;return r.currentTarget=null,r.isStartAction=!1,r.canCancel=!1,r.canTrigger=!1,r.objectType=i,r}return ds(t,n),t.prototype.mouseDown=function(e){if(e.source instanceof te||e.source instanceof de){var i=this.commandHandler.getSelectedObject();this.commandHandler.selectObjects([e.source],e.info&&e.info.ctrlKey,i);var r={nodes:[],connectors:[]};e.source instanceof te?r.nodes.push($(e.source)):r.connectors.push($(e.source)),this.undoElement=$(r)}else this.undoElement=$(e.source);this.undoParentElement=this.commandHandler.getSubProcess(e.source),"Port"===this.objectType&&(this.portId=e.sourceWrapper.id),this.commandHandler.insertBlazorConnector(e.source),n.prototype.mouseDown.call(this,e),this.initialOffset={x:0,y:0}},t.prototype.mouseUp=function(e,i){return Nd(this,void 0,void 0,function(){var s,o,a,l,h,c,d,u,p,g,v,y,S,b,M;return Od(this,function(w){if(this.checkPropertyValue(),a=!1,h={nodes:[],connectors:[]},"Port"!==this.objectType){if(e.source instanceof te||e.source instanceof de?(e.source instanceof te?h.nodes.push($(e.source)):h.connectors.push($(e.source)),(o=$(h)).offsetX=(c=e.source.wrapper).offsetX,o.offsetY=c.offsetY):o=$(e.source),("helper"===(l=this.commandHandler.renderContainerHelper(e.source)||e.source||this.commandHandler.renderContainerHelper(e.source)).id||"helper"!==l.id)&&((l instanceof ei&&(Math.round(l.width)===Math.round(this.undoElement.width)&&Math.round(l.height)===Math.round(this.undoElement.height)||l.selectedObjects&&1===l.selectedObjects.length)||!(l instanceof ei))&&(l.offsetX!==this.undoElement.offsetX||l.offsetY!==this.undoElement.offsetY||l.sourcePoint!==this.undoElement.sourcePoint||l.targetPoint!==this.undoElement.targetPoint)||this.isSelectionHasConnector(l))&&(e.source&&(s={offsetX:e.source.wrapper.offsetX,offsetY:e.source.wrapper.offsetY}),g={source:e.source,state:"Completed",oldValue:this.intialValue,newValue:s,target:this.currentTarget,targetPosition:this.currentPosition,allowDrop:(g={source:e.source,state:"Completed",oldValue:this.intialValue,newValue:s,target:this.currentTarget,targetPosition:this.currentPosition,allowDrop:!0,cancel:!1}).allowDrop,cancel:g.cancel},d=!0,"helper"===l.id?this.canTrigger?(this.commandHandler.triggerEvent(Ce.positionChange,g),this.connectorEndPointChangeEvent(g),d=!0):d=!1:(this.commandHandler.triggerEvent(Ce.positionChange,g),this.connectorEndPointChangeEvent(g)),!i&&d&&(this.commandHandler.startGroupAction(),a=!0,M={type:"PositionChanged",redoObject:$(o),undoObject:$(this.undoElement),category:"Internal"},o.nodes[0]&&o.nodes[0].processId&&(u={type:"SizeChanged",category:"Internal",undoObject:this.undoParentElement,redoObject:this.commandHandler.getSubProcess(e.source)},this.commandHandler.addHistoryEntry(u)),this.commandHandler.addHistoryEntry(M))),this.commandHandler.snapPoint(this.prevPosition,this.currentPosition,0,0),this.commandHandler.removeSnap(),this.commandHandler.removeHighlighter(),e.source&&this.currentTarget&&PI(this.currentTarget)&&this.commandHandler.isDroppable(e.source,this.currentTarget)){if(p=!0,this.commandHandler.drop(this.currentElement,this.currentTarget,this.currentPosition),this.currentTarget&&this.currentTarget instanceof de&&!0===this.commandHandler.diagram.enableConnectorSplit)if(this.currentElement&&this.currentElement instanceof te){if(void 0!==this.currentElement.children)for(b=0;b0)for(var s=0;s0)for(var a=0;a0)for(a=0;a0&&e.connectors.length>0)||e.width===this.undoElement.width&&e.height===this.undoElement.height)},t.prototype.mouseMove=function(e){n.prototype.mouseMove.call(this,e);var r,s,i=!1;(r=this.commandHandler.renderContainerHelper(e.source)||e.source)instanceof te||r instanceof de?r instanceof te?r.offsetX===this.undoElement.nodes[0].offsetX&&r.offsetY===this.undoElement.nodes[0].offsetY&&(i=!0):R.equals(r.sourcePoint,this.undoElement.connectors[0].sourcePoint)&&R.equals(r.targetPoint,this.undoElement.connectors[0].targetPoint)&&(i=!0):r.wrapper.offsetX===this.undoElement.wrapper.offsetX&&r.wrapper.offsetY===this.undoElement.wrapper.offsetY&&(i=!0),r&&(s={offsetX:r.wrapper.offsetX,offsetY:r.wrapper.offsetY});var o={source:r,state:"Start",oldValue:s,newValue:s,target:e.target,targetPosition:e.position,allowDrop:!0,cancel:!1};if(o={source:r,state:"Start",oldValue:s,newValue:s,target:e.target,targetPosition:e.position,allowDrop:o.allowDrop,cancel:o.cancel},this.isStartAction||(this.intialValue={offsetX:r.wrapper.offsetX,offsetY:r.wrapper.offsetY}),i&&!ce()&&(this.commandHandler.triggerEvent(Ce.positionChange,o),this.connectorEndPointChangeEvent(o),this.isStartAction=!0),this.currentPosition=e.position,"Port"!==this.objectType){var h=this.initialOffset.x+(this.currentPosition.x-this.prevPosition.x),c=this.initialOffset.y+(this.currentPosition.y-this.prevPosition.y);this.commandHandler.dragOverElement(e,this.currentPosition),this.commandHandler.disConnect(e.source),this.commandHandler.removeSnap();var d,u=void 0,f=this.commandHandler.snapPoint(this.prevPosition,this.currentPosition,h,c);this.initialOffset.x=h-f.x,this.initialOffset.y=c-f.y,r&&(d={offsetX:r.wrapper.offsetX,offsetY:r.wrapper.offsetY},u={offsetX:r.wrapper.offsetX+f.x,offsetY:r.wrapper.offsetY+f.y}),this.currentTarget&&e.target!==this.currentTarget&&this.commandHandler.removeChildFromBPmn(e.source,e.target,this.currentTarget),this.currentTarget=e.target;var p={source:r,state:"Progress",oldValue:d,newValue:u,target:e.target,targetPosition:e.position,allowDrop:!0,cancel:!1};if(this.commandHandler.triggerEvent(Ce.positionChange,p),this.canTrigger=!0,this.connectorEndPointChangeEvent(p,f),!p.cancel&&!this.canCancel){this.blocked=!this.commandHandler.dragSelectedObjects(f.x,f.y);var g=!this.commandHandler.mouseOver(this.currentElement,this.currentTarget,this.currentPosition);this.blocked=this.blocked||g}if(this.commandHandler.removeStackHighlighter(),this.commandHandler.renderStackHighlighter(e),this.currentTarget&&e.source!==this.currentTarget&&this.commandHandler.isDroppable(e.source,this.currentTarget)&&"helper"!==e.source.id){var v=e.source instanceof ei?e.source.nodes[0]:e.source;!this.commandHandler.isParentAsContainer(v,!0)&&"SwimLane"!==v.shape.type&&!v.shape.isPhase&&(this.currentTarget.isLane?this.commandHandler.renderStackHighlighter(e,this.currentTarget):this.commandHandler.drawHighlighter(this.currentTarget))}else this.commandHandler.removeHighlighter();if(this.commandHandler.canEnableDefaultTooltip()){var y=this.getTooltipContent(e.source);this.commandHandler.showTooltip(e.source,e.position,ko(function(){return y}),"MoveTool",this.isTooltipVisible),this.isTooltipVisible=!1}}else{var b=Bi(),M=e.source;qi(b,-M.rotateAngle||-M.wrapper.rotateAngle,M.offsetX||M.wrapper.offsetX,M.offsetY||M.wrapper.offsetY);var w=Ke(b,{x:this.prevPosition.x,y:this.prevPosition.y}),C=Ke(b,{x:e.position.x,y:e.position.y});this.commandHandler.portDrag(e.source,e.sourceWrapper,C.x-w.x,C.y-w.y)}return this.prevPosition=this.currentPosition,!this.blocked},t.prototype.getTooltipContent=function(e){return"X:"+Math.round(e.wrapper.bounds.x)+" Y:"+Math.round(e.wrapper.bounds.y)},t.prototype.mouseLeave=function(e){this.mouseUp(e)},t.prototype.endAction=function(){n.prototype.endAction.call(this),this.currentTarget=null,this.prevPosition=null},t}(us),Yx=function(n){function t(e){var i=n.call(this,e,!0)||this;return i.rotateStart=!1,i}return ds(t,n),t.prototype.mouseDown=function(e){if(this.undoElement=$(e.source),this.undoElement.nodes[0]&&this.undoElement.nodes[0].children)for(var r=this.commandHandler.getAllDescendants(this.undoElement.nodes[0],[]),s=0;s=2){var s=e.startTouches[0],o=e.startTouches[1],a=e.moveTouches[0],l=e.moveTouches[1],h=this.getDistance(a,l)/this.getDistance(s,o);this.commandHandler.zoom(h,0,0,e.position),this.updateTouch(s,a),this.updateTouch(o,l)}}else this.commandHandler.scroll(this.currentPosition.x-this.prevPosition.x,this.currentPosition.y-this.prevPosition.y,this.currentPosition);return this.commandHandler.dataBinding(),!this.blocked},t.prototype.mouseUp=function(e){this.commandHandler.setBlazorDiagramProps(!1),this.checkPropertyValue(),this.commandHandler.updatePanState(!1),n.prototype.mouseUp.call(this,e),this.inAction=!1},t.prototype.endAction=function(){n.prototype.endAction.call(this)},t.prototype.getDistance=function(e,i){var r=i.pageX-e.pageX,s=i.pageY-e.pageY;return Math.sqrt(r*r+s*s)},t.prototype.updateTouch=function(e,i){e.pageX=i.pageX,e.pageY=i.pageY},t}(us),Lne=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseUp=function(e){this.checkPropertyValue(),this.commandHandler.initExpand(e),n.prototype.mouseUp.call(this,e)},t}(us),X3=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseUp=function(e){this.checkPropertyValue();var i="_blank",r="",s=window.innerHeight,o=window.innerWidth,a=window.screenTop,l=window.screenLeft;"CurrentTab"===e.sourceWrapper.hyperlink.hyperlinkOpenState?i="_self":"NewWindow"===e.sourceWrapper.hyperlink.hyperlinkOpenState&&(r="height="+s+",width="+o+",top="+a+",left="+l),window.open(e.sourceWrapper.hyperlink.link,i,r).focus(),n.prototype.mouseUp.call(this,e)},t}(us),zl=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseDown=function(e){if(n.prototype.mouseDown.call(this,e),this.inAction=!0,this.drawingObject){var r=void 0,s=this.drawingObject.shape;this.drawingObject.shape.points.push(r={x:(r=s.points[s.points.length-1]).x,y:r.y})}else{this.startPoint={x:this.startPosition.x,y:this.startPosition.y};var i={offsetX:this.currentPosition.x,offsetY:this.currentPosition.y,width:5,height:5,shape:{type:"Basic",shape:"Polygon",points:[{x:this.startPoint.x,y:this.startPoint.y},{x:this.currentPosition.x,y:this.currentPosition.y}]}};this.triggerElementDrawEvent(e.source,"Start","Node",this.getShapeType(),!0),this.drawingObject=this.commandHandler.drawObject(i)}},t.prototype.mouseMove=function(e){if(n.prototype.mouseMove.call(this,e),this.inAction){var i=this.drawingObject.shape;if(i.points[i.points.length-1].x=this.currentPosition.x,i.points[i.points.length-1].y=this.currentPosition.y,this.drawingObject.wrapper.children[0].data=vx(this.drawingObject.shape.points),this.triggerElementDrawEvent(this.drawingObject,"Progress","Node",this.getShapeType(),!1),this.inAction&&!1===R.equals(this.currentPosition,this.prevPosition)){var r=Ne.toBounds(this.drawingObject.shape.points);this.commandHandler.updateNodeDimension(this.drawingObject,r)}}return!0},t.prototype.mouseUp=function(e,i){this.checkPropertyValue(),n.prototype.mouseMove.call(this,e),this.inAction&&(this.inAction=!1,this.commandHandler.addObjectToDiagram(this.drawingObject),this.triggerElementDrawEvent(this.drawingObject,"Completed","Node",this.getShapeType(),!1)),this.endAction()},t.prototype.mouseWheel=function(e){n.prototype.mouseWheel.call(this,e),this.mouseMove(e)},t.prototype.endAction=function(){this.inAction=!1,this.drawingObject=null},t}(us),Rl=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseMove=function(e){if(n.prototype.mouseMove.call(this,e),this.inAction){var i=this.drawingObject;i.targetPoint=this.currentPosition,this.triggerElementDrawEvent(this.drawingObject,"Progress","Connector",this.drawingObject.type,!1),this.commandHandler.updateConnectorPoints(i)}return!0},t.prototype.mouseDown=function(e){if(n.prototype.mouseDown.call(this,e),this.inAction=!0,this.drawingObject){var r=this.drawingObject,s=void 0;(s=new Hl(r,"segments",{type:"Straight"},!0)).point=this.currentPosition,r.segments[r.segments.length-1]=s}else{var i={id:"Connector",type:"Straight",sourcePoint:this.currentPosition,targetPoint:this.currentPosition};this.triggerElementDrawEvent(e.source,"Start","Connector",this.commandHandler.diagram.drawingObject.type,!0),this.inAction&&(this.drawingObject=this.commandHandler.drawObject(i))}},t.prototype.mouseWheel=function(e){n.prototype.mouseWheel.call(this,e),this.mouseMove(e)},t.prototype.mouseUp=function(e){if(this.checkPropertyValue(),n.prototype.mouseMove.call(this,e),this.inAction&&this.drawingObject){var i=this.drawingObject;i.segments[i.segments.length-1].point={x:0,y:0},this.commandHandler.addObjectToDiagram(this.drawingObject),this.triggerElementDrawEvent(this.drawingObject,"Completed","Connector",this.drawingObject.type,!1)}this.endAction()},t.prototype.endAction=function(){this.drawingObject=null,this.inAction=!1},t}(us),Nne=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseDown=function(e){this.inAction=!0,this.undoElement=$(e.source),this.annotationId=e.sourceWrapper.id,n.prototype.mouseDown.call(this,e)},t.prototype.mouseMove=function(e){n.prototype.mouseMove.call(this,e);var i=this.currentPosition.x-this.prevPosition.x,r=this.currentPosition.y-this.prevPosition.y,s=e.source;if(s instanceof te){var o=Bi();qi(o,-s.rotateAngle,0,0);var a=Ke(o,{x:i,y:r});i=a.x,r=a.y}return this.inAction&&(this.commandHandler.labelDrag(e.source,e.sourceWrapper,i,r),this.commandHandler.updateSelector()),this.prevPosition=this.currentPosition,!this.blocked},t.prototype.mouseUp=function(e){this.checkPropertyValue();var i=e.source;this.inAction=!1;var r={type:"AnnotationPropertyChanged",objectId:this.annotationId,undoObject:$(this.undoElement),category:"Internal",redoObject:$(i)};this.commandHandler.addHistoryEntry(r),n.prototype.mouseUp.call(this,e)},t.prototype.mouseLeave=function(e){this.mouseUp(e)},t}(us),One=function(n){function t(e,i){var r=n.call(this,e,!0)||this;return r.corner=i,r}return ds(t,n),t.prototype.mouseDown=function(e){this.inAction=!0;var i=e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0];this.annotationId=e.source.wrapper.children[0].id,this.undoElement=$(i);var r=e.source.wrapper.children[0];this.initialBounds={x:r.offsetX,y:r.offsetY,width:r.actualSize.width,height:r.actualSize.height},n.prototype.mouseDown.call(this,e)},t.prototype.mouseMove=function(e){return n.prototype.mouseMove.call(this,e),this.inAction&&this.resizeObject(e),!this.blocked},t.prototype.mouseUp=function(e){this.checkPropertyValue();var i=e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0];this.inAction=!1;var r={type:"AnnotationPropertyChanged",objectId:this.annotationId,redoObject:$(i),undoObject:$(this.undoElement),category:"Internal"};this.commandHandler.addHistoryEntry(r),n.prototype.mouseUp.call(this,e)},t.prototype.mouseLeave=function(e){this.mouseUp(e)},t.prototype.resizeObject=function(e){var i,s,o,r=e.source.wrapper.children[0],a={x:r.offsetX,y:r.offsetY},l=r.rotateAngle;l=((l+=(i=e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0])instanceof te?i.rotateAngle:0)+360)%360;var h=Bi();qi(h,l,a.x,a.y);var c=this.corner.slice(5),d=this.updateSize(r,this.startPosition,this.currentPosition,c,this.initialBounds,l),u=r.offsetX-r.actualSize.width*r.pivot.x,f=r.offsetY-r.actualSize.height*r.pivot.y,p=this.getPivot(c),g=Ke(h,p={x:u+r.actualSize.width*p.x,y:f+r.actualSize.height*p.y});d.x=g.x,d.y=g.y,this.commandHandler.labelResize(i,e.source.annotation,s=(s=d.width)<0?1:s,o=(o=d.height)<0?1:o,d,e.source),this.commandHandler.updateSelector()},t}(us),kne=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseDown=function(e){this.inAction=!0,this.annotationId=e.source.wrapper.children[0].id,this.undoElement=$(e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0]),n.prototype.mouseDown.call(this,e)},t.prototype.mouseMove=function(e){return n.prototype.mouseMove.call(this,e),e.source&&this.inAction&&(this.commandHandler.labelRotate(e.source.nodes[0]?e.source.nodes[0]:e.source.connectors[0],e.source.annotation,this.currentPosition,e.source),this.commandHandler.updateSelector()),this.prevPosition=this.currentPosition,!this.blocked},t.prototype.mouseUp=function(e){this.checkPropertyValue(),this.inAction=!1;var r={type:"AnnotationPropertyChanged",objectId:this.annotationId,redoObject:$(e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0]),undoObject:$(this.undoElement),category:"Internal"};this.commandHandler.addHistoryEntry(r),n.prototype.mouseUp.call(this,e)},t.prototype.mouseLeave=function(e){this.mouseUp(e)},t}(us),Pne=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseMove=function(e){if(n.prototype.mouseMove.call(this,e),this.inAction){var i=this.drawingObject.shape;if(i.points.push(this.currentPosition),this.drawingObject.wrapper.children[0].data=mx(this.drawingObject.shape.points),i.data=mx(i.points),this.triggerElementDrawEvent(e.source,"Progress","Connector",this.drawingObject.type,!1),this.inAction&&!1===R.equals(this.currentPosition,this.prevPosition)){var s=Ne.toBounds(this.drawingObject.shape.points);this.commandHandler.updateNodeDimension(this.drawingObject,s)}}return!0},t.prototype.mouseDown=function(e){n.prototype.mouseDown.call(this,e),this.inAction=!0,this.startPoint={x:this.startPosition.x,y:this.startPosition.y};var i={offsetX:this.currentPosition.x,offsetY:this.currentPosition.y,width:5,height:5,style:{strokeColor:"black",strokeWidth:1,fill:"transparent"},shape:{type:"Path",points:[{x:this.startPoint.x,y:this.startPoint.y},{x:this.currentPosition.x,y:this.currentPosition.y}]}};this.triggerElementDrawEvent(e.source,"Start","Connector",this.commandHandler.diagram.drawingObject.type,!0),this.drawingObject=this.commandHandler.drawObject(i)},t.prototype.mouseUp=function(e){if(this.checkPropertyValue(),this.inAction){this.inAction=!1;var s=this.drawingObject.shape,o=s.points;this.commandHandler.addObjectToDiagram(this.drawingObject),this.commandHandler.diagram.remove(this.commandHandler.diagram.nameTable[""+this.drawingObject.id]),o=this.pointReduction(o,10);var h={id:"newConnector"+Qe(),type:"Bezier",sourcePoint:{x:o[0].x,y:o[0].y},targetPoint:{x:o[o.length-1].x,y:o[o.length-1].y},segments:[],bezierSettings:{allowSegmentsReset:!1}};this.drawingObject=this.commandHandler.drawObject(h),this.drawingObject=this.bezierCurveSmoothness(o,.5,this.drawingObject,s),this.commandHandler.updateConnectorPoints(this.drawingObject),this.commandHandler.addObjectToDiagram(this.drawingObject),this.triggerElementDrawEvent(this.drawingObject,"Completed","Connector",this.drawingObject.type,!1),n.prototype.mouseUp.call(this,e)}},t.prototype.pointReduction=function(e,i){if(null===e||e.length<3)return e;var s=e.length-1,o=[];for(o.push(0),o.push(s);e[parseInt((0).toString(),10)]===e[parseInt(s.toString(),10)];)s--;this.reduction(e,0,s,i,o);var a=[];return o.sort(function(l,h){return l-h}),o.forEach(function(l){a.push(e[parseInt(l.toString(),10)])}),a},t.prototype.reduction=function(e,i,r,s,o){for(var a=0,l=0,h=i;ha&&(a=c,l=h)}a>s&&0!==l&&(o.push(l),this.reduction(e,i,l,s,o),this.reduction(e,l,r,s,o))},t.prototype.perpendicularDistance=function(e,i,r){return Math.abs(.5*(e.x*i.y-i.x*e.y+(i.x*r.y-r.x*i.y)+(r.x*e.y-e.x*r.y)))/Math.sqrt(Math.pow(e.x-i.x,2)+Math.pow(e.y-i.y,2))*2},t.prototype.bezierCurveSmoothness=function(e,i,r,s){if(e.length<3)return r;for(var o=0;o=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},zne=function(n){if(n)switch(n.type){case"Bpmn":return Fne;case"UmlActivity":return Bne;case"UmlClassifier":return jne;default:return em}return em},Rne=function(n){if(n)switch(n.type){case"Straight":default:return Hl;case"Bezier":return fs;case"Orthogonal":return wi}},q3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I(10)],t.prototype,"width",void 0),Pe([I(10)],t.prototype,"height",void 0),Pe([I("Arrow")],t.prototype,"shape",void 0),Pe([re({fill:"black",strokeColor:"black",strokeWidth:1},Ll)],t.prototype,"style",void 0),Pe([re({x:0,y:.5},R)],t.prototype,"pivot",void 0),Pe([I("")],t.prototype,"pathData",void 0),t}(Ee),QI=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I(0)],t.prototype,"angle",void 0),Pe([I(0)],t.prototype,"distance",void 0),t}(Ee),Hne=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I(bx.All)],t.prototype,"controlPointsVisibility",void 0),Pe([I("FreeForm")],t.prototype,"segmentEditOrientation",void 0),Pe([I(SI.Default)],t.prototype,"smoothness",void 0),Pe([I(!0)],t.prototype,"allowSegmentsReset",void 0),t}(Ee),em=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I("None")],t.prototype,"type",void 0),t}(Ee),Bne=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I("Object")],t.prototype,"flow",void 0),Pe([I(30)],t.prototype,"exceptionFlowHeight",void 0),t}(em),Fne=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I("Sequence")],t.prototype,"flow",void 0),Pe([I("Normal")],t.prototype,"sequence",void 0),Pe([I("Default")],t.prototype,"message",void 0),Pe([I("Default")],t.prototype,"association",void 0),t}(em),$3=function(n){function t(e,i,r,s){var o=n.call(this,e,i,r,s)||this;return o.points=[],o}return Qs(t,n),Pe([I("Straight")],t.prototype,"type",void 0),Pe([I(!0)],t.prototype,"allowDrag",void 0),t}(Ee),Hl=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),t.prototype.getClassName=function(){return"StraightSegment"},Pe([re({x:0,y:0},R)],t.prototype,"point",void 0),t}($3),fs=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),t.prototype.getClassName=function(){return"BezierSegment"},t.prototype.getPoints=function(e,i){var r=[];if(r.length>0||null!=i){var o=this.bezireToPoly(r.length>0?r[r.length-1]:i,e);r.push.apply(r,o)}return r},t.prototype.bezireToPoly=function(e,i){var r=[];return i&&this.flattenCubicBezier(r,e,i.bezierPoint1,i.bezierPoint2,{x:i.points[1].x,y:i.points[1].y},10),r},t.prototype.flattenCubicBezier=function(e,i,r,s,o,a){var h,l=(R.findLength(i,r)+R.findLength(r,s)+R.findLength(s,o))/a;for(h=0;h<=l;h++){var c=h/l;e.push({x:(1-c)*(1-c)*(1-c)*i.x+3*c*(1-c)*(1-c)*r.x+3*c*c*(1-c)*s.x+c*c*c*o.x,y:(1-c)*(1-c)*(1-c)*i.y+3*c*(1-c)*(1-c)*r.y+3*c*c*(1-c)*s.y+c*c*c*o.y})}},Pe([I("Horizontal")],t.prototype,"orientation",void 0),Pe([re({x:0,y:0},R)],t.prototype,"point1",void 0),Pe([re({x:0,y:0},R)],t.prototype,"point2",void 0),Pe([re({angle:0,distance:0},QI)],t.prototype,"vector1",void 0),Pe([re({angle:0,distance:0},QI)],t.prototype,"vector2",void 0),t}(Hl),wi=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),t.prototype.getClassName=function(){return"OrthogonalSegment"},Pe([I(null)],t.prototype,"length",void 0),Pe([I(null)],t.prototype,"direction",void 0),t}($3);function Z3(n,t,e){var s=e?45:180/(2+2/(n.height/n.width)),o=s,a=180-s,l=a+2*s,h=360-s,c=Gt(t,n.center);return c>o&&ca&&cl&&cMath.abs(t.y-n.y)?n.x=c)return s=R.findAngle(n[parseInt(d.toString(),10)],n[d+1]),{point:r=R.transform(n[parseInt(d.toString(),10)],s,c-(a||0)),index:l=d};a=o[parseInt(d.toString(),10)]}return{point:r,index:l}}(n,t),r=R.findAngle(n[i.index],n[i.index+1]),s=function vse(n){var e=0;switch(n.alignment){case"Center":case"After":e=0;break;case"Before":e=-0}return e}(t),o=R.transform(i.point,r+45,s);return i.point=o,i.angle=r,i}(i,e),h=l.point;s.id=this.id+"_"+e.id;var c=e.style;s.style={fill:c.fill,strokeColor:c.strokeColor,gradient:null,opacity:c.opacity,strokeDashArray:c.strokeDashArray,strokeWidth:c.strokeWidth},0===r.width&&(r.width=this.style.strokeWidth),0===r.height&&(r.height=this.style.strokeWidth);var d_y=(h.y-r.y)/r.height;a.x=r.width*((h.x-r.x)/r.width),a.y=r.height*d_y;var g,v,u=fF(e,l.angle,i),f=u.hAlign,p=u.vAlign;return"left"===f?(g="Left",a.x+=e.displacement.x):"right"===f?(g="Right",a.x-=e.displacement.x):"center"===f&&(g="Center"),"top"===p?(v="Top",a.y+=e.displacement.y):"bottom"===p?(v="Bottom",a.y-=e.displacement.y):"center"===p&&(v="Center"),s.horizontalAlignment=g,s.verticalAlignment=v,(s=rm(s,o&&"Label"!==o.flipMode&&"None"!==o.flipMode?this.flip:"None",e)).float=!0,s.connectionDirection=e.connectionDirection,s.setOffsetWithRespectToBounds(a.x,a.y,"Absolute"),s.relativeMode="Point",s.visible=!(!va(e,oi.Visible)||va(e,oi.Hover)||va(e,oi.Connect)),s.elementActions=s.elementActions|Xr.ElementIsPort,s},t.prototype.getConnectorRelation=function(){var e=this.shape;"Association"===e.relationship?(this.segments[0].type="Straight",this.sourceDecorator.shape="None",this.targetDecorator.shape="Arrow"):"Inheritance"===e.relationship?(this.segments[0].type="Orthogonal",this.sourceDecorator.shape="None",this.targetDecorator.shape="Arrow"):"Composition"===e.relationship||"Aggregation"===e.relationship?(this.segments[0].type="Orthogonal",this.sourceDecorator.shape="Diamond",this.targetDecorator.shape="None"):"Dependency"===e.relationship?(this.segments[0].type="Orthogonal",this.sourceDecorator.shape="None",this.targetDecorator.shape="OpenArrow"):"Realization"===e.relationship&&(this.segments[0].type="Orthogonal",this.sourceDecorator.shape="None",this.targetDecorator.shape="Arrow"),"BiDirectional"===e.associationType&&(this.sourceDecorator.shape="None",this.targetDecorator.shape="None");var i,o,r="",s="";e.multiplicity.source&&(e.multiplicity.source.lowerBounds=e.multiplicity.source.lowerBounds,e.multiplicity.source.upperBounds=e.multiplicity.source.upperBounds),e.multiplicity.target&&(e.multiplicity.target.lowerBounds=e.multiplicity.target.lowerBounds,e.multiplicity.target.upperBounds=e.multiplicity.target.upperBounds);var a=e.multiplicity.source,l=e.multiplicity.target;o=a.upperBounds?a.lowerBounds+"..."+a.upperBounds:a.lowerBounds,i=l.upperBounds?l.lowerBounds+"..."+l.upperBounds:l.lowerBounds,"ManyToOne"===e.multiplicity.type&&(e.multiplicity.target.optional=!1,r=o||"*",s="1"),"OneToMany"===e.multiplicity.type&&(e.multiplicity.source.optional=!1,s=i||"*",r="1"),"ManyToMany"===e.multiplicity.type&&(r=o||"*",s=i||"*"),"OneToOne"===e.multiplicity.type&&(e.multiplicity.target.optional=!1,e.multiplicity.source.optional=!1,r="1",s="1"),this.annotations=[{id:this.id+"sourcelabel",content:r,offset:0,alignment:"Before",margin:{right:5,bottom:5}},{id:this.id+"targetlabel",content:s,offset:1,alignment:"Before",margin:{right:5,bottom:5}}]},t.prototype.getBpmnSequenceFlow=function(){var e=new Ze,i=new Ze;return"Normal"===this.shape.sequence&&"Bezier"!==this.type&&(this.targetDecorator.shape="Arrow"),"Default"===this.shape.sequence&&(e=this.getSegmentElement(this,e),i=IF(this.intermediatePoints,this),this.targetDecorator.shape="Arrow"),"Conditional"===this.shape.sequence&&(this.targetDecorator.shape="Arrow",this.sourceDecorator.shape="Diamond",i.id=this.id+this.shape.type),i},t.prototype.getUMLObjectFlow=function(){if(this.annotations)for(var e=0;e0&&(this.sourcePoint=o[0],this.targetPoint=o[o.length-1]),o},t.prototype.clipDecorator=function(e,i,r,s){var a,l,o={x:0,y:0},h=i.length,c=R.distancePoints(a=r?i[0]:i[h-1],l=r?i[1]:i[h-2]);c=0===c?1:c;var d=1,u=r?e.sourceWrapper:e.targetWrapper;u&&(d=u.style.strokeWidth,s&&s&ee.DecoratorPropertyChange&&(d=1));var f=d-1;return o.x=Math.round(a.x+f*(l.x-a.x)/c),o.y=Math.round(a.y+f*(l.y-a.y)/c),(r&&"None"!==e.sourceDecorator.shape||!r&&"None"!==e.targetDecorator.shape)&&(o=R.adjustPoint(o,l,!0,s&ee.DecoratorPropertyChange?0:d/2)),o},t.prototype.clipDecorators=function(e,i,r){return"None"!==e.sourceDecorator.shape&&(i[0]=this.clipDecorator(e,i,!0,r)),"None"!==e.targetDecorator.shape&&(i[i.length-1]=this.clipDecorator(e,i,!1,r)),i},t.prototype.updateSegmentElement=function(e,i,r,s){var o=new Ne,a=this.getSegmentPath(e,i,s);if("Bezier"===e.type){if(this.segments.length>0)for(var l=0;l0)if("Straight"===e.type&&e.segments.length<2)for(var o=0;o1)for(o=0;o0&&"Bezier"!==this.type)for(var f=0;f0&&(a=f0&&(p<2*this.cornerRadius?(l=R.adjustPoint(h[parseInt(f.toString(),10)],h[f+1],!0,p/2),f0&&(s=this.bridgePath(e,s,f),"Orthogonal"===e.type&&(s=this.bridgePath(e,s,f+1))),s+=" L"+a.x+" "+a.y))}else if("Bezier"===this.type){var g=void 0,v=void 0;if(this.parentObj.element){var y=this.parentObj.element.ej2_instances[0].eventHandler.action;g=this.parentObj.element.ej2_instances[0].eventHandler.tool instanceof Pd,v=y.includes("PortDraw")||y.includes("Drag")}for(var S=void 0,b=this.segments,M=0;M2&&(b[parseInt(M.toString(),10)].bezierPoint1={x:0,y:0},b[parseInt(M.toString(),10)].bezierPoint2={x:0,y:0}),!R.isEmptyPoint(b[parseInt(M.toString(),10)].point1)||b[parseInt(M.toString(),10)].vector1.angle||b[parseInt(M.toString(),10)].vector1.distance?b[parseInt(M.toString(),10)].vector1.angle||b[parseInt(M.toString(),10)].vector1.distance?b[parseInt(M.toString(),10)].bezierPoint1=R.transform(h[parseInt(M.toString(),10)],b[parseInt(M.toString(),10)].vector1.angle,b[parseInt(M.toString(),10)].vector1.distance):b[parseInt(M.toString(),10)].bezierPoint1={x:b[parseInt(M.toString(),10)].point1.x||b[parseInt(M.toString(),10)].bezierPoint1.x,y:b[parseInt(M.toString(),10)].point1.y||b[parseInt(M.toString(),10)].bezierPoint1.y}:((e.sourceID||this.sourcePortID)&&this.sourceWrapper&&!v&&!g&&(S=Z3(this.sourceWrapper.bounds,h[parseInt(M.toString(),10)],!0)),b[parseInt(M.toString(),10)].bezierPoint1=XI(h[parseInt(M.toString(),10)],h[M+1],S)),!R.isEmptyPoint(b[parseInt(M.toString(),10)].point2)||b[parseInt(M.toString(),10)].vector2.angle||b[parseInt(M.toString(),10)].vector2.distance?b[parseInt(M.toString(),10)].vector2.angle||b[parseInt(M.toString(),10)].vector2.distance?b[parseInt(M.toString(),10)].bezierPoint2=R.transform(h[M+1],b[parseInt(M.toString(),10)].vector2.angle,b[parseInt(M.toString(),10)].vector2.distance):b[parseInt(M.toString(),10)].bezierPoint2={x:b[parseInt(M.toString(),10)].point2.x||b[parseInt(M.toString(),10)].bezierPoint2.x,y:b[parseInt(M.toString(),10)].point2.y||b[parseInt(M.toString(),10)].bezierPoint2.y}:((e.targetID||this.targetPortID)&&this.targetWrapper&&!v&&!g&&(S=Z3(this.targetWrapper.bounds,h[M+1],!0)),b[parseInt(M.toString(),10)].bezierPoint2=XI(h[M+1],h[parseInt(M.toString(),10)],S));h.splice(1,0,{x:b[0].bezierPoint1.x,y:b[0].bezierPoint1.y}),h.splice(h.length-1,0,{x:b[b.length-1].bezierPoint2.x,y:b[b.length-1].bezierPoint2.y}),h=this.clipDecorators(e,h,r);for(var w=0;w0&&(s=this.bridgePath(e,s,D),s+=" L"+o.x+" "+o.y);return s},t.prototype.updateShapeElement=function(e){var i;switch(e.shape.type){case"Bpmn":e.wrapper.children[3]instanceof Ze&&(i=e.wrapper.children[3]),"Message"===e.shape.flow&&this.updateShapePosition(e,i);break;case"UmlActivity":"Exception"===e.shape.flow&&this.getUMLExceptionFlow(e.wrapper.children[0])}},t.prototype.updateShapePosition=function(e,i){var o=bF(this.intermediatePoints,i,.5);i.offsetX=o.x,i.offsetY=o.y},t.prototype.scale=function(e,i,r,s,o){var a=0,l=0;if(this.wrapper&&this.wrapper.outerBounds){var h=function M3(n){var t=n.wrapper.children[0].bounds;return"None"!==n.sourceDecorator.shape&&t.uniteRect(n.wrapper.children[1].bounds),"None"!==n.targetDecorator.shape&&t.uniteRect(n.wrapper.children[2].bounds),t}(this),c=Math.abs((this.wrapper.bounds.width||this.style.strokeWidth||1)-2),d=Math.abs((this.wrapper.bounds.height||this.style.strokeWidth||1)-2);a=h.width-c,l=h.height-d,e=Math.abs((r-Math.max(a,l))/c),i=Math.abs((s-Math.max(a,l))/d),a=l=Math.min(a,l)}e=i=Math.min(e,i);var u=Bi();qi(u,-(o=o||this.wrapper).rotateAngle,o.offsetX,o.offsetY),Yf(u,e,i,o.offsetX,o.offsetY),qi(u,o.rotateAngle,o.offsetX,o.offsetY);var f=function Lie(n,t){for(var e=[],i=0,r=t;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Wne=function(n){function t(e,i){var r=n.call(this,e,i)||this;return r.offset=0,r.scale=1,r}return Vne(t,n),t.prototype.preRender=function(){this.unWireEvents(),this.wireEvents()},t.prototype.render=function(){this.updateRulerGeometry(),this.renderComplete()},t.prototype.getModuleName=function(){return"Ruler"},t.prototype.destroy=function(){this.unWireEvents(),this.notify("destroy",{}),n.prototype.destroy.call(this),this.element.classList.remove("e-ruler")},t.prototype.getPersistData=function(){return this.addOnPersist(["loaded"])},t.prototype.onPropertyChanged=function(e,i){for(var r=0,s=Object.keys(e);r100;)r/=10,s/=10;for(;s<25;)r*=10,s*=10;return s>=25&&s%25!=0&&(s=25*Math.round(s/25)),s*e/r},t.prototype.createMarkerLine=function(e,i,r){var s;return i&&((s=e.getElementById(i.id+"_marker"))&&s.parentNode.removeChild(s),s=Fi("line",r)),s},t.prototype.drawRulerMarker=function(e,i,r){var s,o,h,d,u="Horizontal"===this.orientation,f=e.getElementsByTagName("svg");for(h=0;h0)for(var a=i.childNodes.length-1;a>=0;a--)i.childNodes[parseInt(a.toString(),10)].parentNode.removeChild(i.childNodes[parseInt(a.toString(),10)]);i.appendChild(s)}return s},t.prototype.wireEvents=function(){},t.prototype.unWireEvents=function(){},kc([I(5)],t.prototype,"interval",void 0),kc([I(100)],t.prototype,"segmentWidth",void 0),kc([I("Horizontal")],t.prototype,"orientation",void 0),kc([I("RightOrBottom")],t.prototype,"tickAlignment",void 0),kc([I("red")],t.prototype,"markerColor",void 0),kc([I(25)],t.prototype,"thickness",void 0),kc([I(null)],t.prototype,"arrangeTick",void 0),kc([I(400)],t.prototype,"length",void 0),t}(Ii);function eF(n,t){var e=document.getElementById(n.element.id+(t?"_hRuler":"_vRuler")),i=Za(n),r=tF(n);e||(e=Tt("div",{id:n.element.id+(t?"_hRuler":"_vRuler"),style:"height:"+(t?i.height:r.height+100)+"px;overflow:hidden;width:"+(t?r.width+100:i.width)+"px;position:absolute;font-size:11px;"+(t?"margin-left:"+i.width+"px;":"margin-top:"+i.height+"px;")})),n.element.insertBefore(e,n.element.firstChild);var l=t?n.rulerSettings.horizontalRuler:n.rulerSettings.verticalRuler,h=new Wne(l);h.orientation=t?"Horizontal":"Vertical",h.length=(t?r.width:r.height)+l.segmentWidth,h.appendTo("#"+n.element.id+(t?"_hRuler":"_vRuler")),t?n.hRuler=h:n.vRuler=h;var c=document.getElementById(n.element.id+(t?"_hRuler":"_vRuler"));t?n.hRuler.element=c:n.vRuler.element=c}function qI(n){var t=-n.scroller.horizontalOffset,e=-n.scroller.verticalOffset;n&&n.rulerSettings.showRulers?(n.hRuler.length=0,n.vRuler.length=0,void 0!==t&&n.hRuler.element&&iF(n,n.hRuler,t,!0),void 0!==e&&n.vRuler.element&&iF(n,n.vRuler,e,!1)):Qx(n)}function Qx(n){an(n.element.id+"_hRuler"),an(n.element.id+"_vRuler"),an(n.element.id+"_overlapRuler")}function Za(n){var t=0,e=0;return n.rulerSettings.showRulers&&(t=n.rulerSettings.horizontalRuler.thickness,e=n.rulerSettings.verticalRuler.thickness),new me(e,t)}function tF(n){var t=Za(n),e=n.scroller.viewPortHeight,i=n.scroller.viewPortWidth;return i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},rF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return $ne(t,n),t.prototype.getClassName=function(){return"UserHandle"},Un([I("")],t.prototype,"name",void 0),Un([I("")],t.prototype,"pathData",void 0),Un([I("")],t.prototype,"content",void 0),Un([I("")],t.prototype,"source",void 0),Un([I("#000000")],t.prototype,"backgroundColor",void 0),Un([I("Top")],t.prototype,"side",void 0),Un([I("")],t.prototype,"borderColor",void 0),Un([I(.5)],t.prototype,"borderWidth",void 0),Un([I(25)],t.prototype,"size",void 0),Un([I("white")],t.prototype,"pathColor",void 0),Un([I(10)],t.prototype,"displacement",void 0),Un([I(!0)],t.prototype,"visible",void 0),Un([I(0)],t.prototype,"offset",void 0),Un([re({},Jn)],t.prototype,"margin",void 0),Un([I("Center")],t.prototype,"horizontalAlignment",void 0),Un([I("Center")],t.prototype,"verticalAlignment",void 0),Un([I(!1)],t.prototype,"disableNodes",void 0),Un([I(!1)],t.prototype,"disableConnectors",void 0),Un([re({},Dd)],t.prototype,"tooltip",void 0),Un([I("")],t.prototype,"template",void 0),t}(Ee);function nF(n){return Zne[n.toString()]}var Zne={Action:"M 90 82.895 C 90 86.819 86.776 90 82.8 90 H 7.2 C 3.224 90 0 86.819 0 82.895 V 7.105 C 0 3.181 3.224 0 7.2 0 h 75.6 C 86.776 0 90 3.181 90 7.105 V 82.895 Z",Decision:"M10,19.707L0.293,10L10,0.293L19.707,10L10,19.707z",MergeNode:"M10,19.707L0.293,10L10,0.293L19.707,10L10,19.707z",InitialNode:"M10,19.5c-5.238,0-9.5-4.262-9.5-9.5S4.762,0.5,10,0.5s9.5,4.262,9.5,9.5S15.238,19.5,10,19.5z",ForkNode:"m0.75,0.75l636.00002,0l0,290l-636.00002,0l0,-290z",JoinNode:"m0.75,0.75l636.00002,0l0,290l-636.00002,0l0,-290z",TimeEvent:"M50.001,0.00286865 L25.001,25.0029 L0.000976562,0.00286865 L50.001,0.00286865 z M0.000976562,50.0029 L25.001,25.0029 L50.001,50.0029 L0.000976562,50.0029 z",AcceptingEvent:"M17.8336 32.164 L29.64 24 L17.32 16 L48.1664 16 L48.5 32 Z",SendSignal:"M48.164 31.8336 L56 23.832 L47.836 16 L16.168 16 L16.1668 31.8336 Z",ReceiveSignal:"M48.1664 31.8336 L39.836 24 L47.836 16 L16.168 16 L16.168 31.836 Z",StructuredNode:"M0,0 L50,0 L50,50 L0,50 z",Note:"M20 12 L4 12 L4 22 L22 22 L22 14 L20 14 L20 12 L22 14 Z"},$I=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Ja=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Jne=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return $I(t,n),Ja([I()],t.prototype,"key",void 0),Ja([I()],t.prototype,"keyModifiers",void 0),t}(Ee),sF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return $I(t,n),t.prototype.getClassName=function(){return"Command"},Ja([I("")],t.prototype,"name",void 0),Ja([I()],t.prototype,"canExecute",void 0),Ja([I()],t.prototype,"execute",void 0),Ja([re({},Jne)],t.prototype,"gesture",void 0),Ja([I("")],t.prototype,"parameter",void 0),t}(Ee),Kne=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return $I(t,n),Ja([Bt([],sF)],t.prototype,"commands",void 0),t}(Ee),ese=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return $I(t,n),Ja([I()],t.prototype,"show",void 0),Ja([I()],t.prototype,"showCustomMenuOnly",void 0),Ja([I()],t.prototype,"items",void 0),t}(Ee),$f=function(){function n(){}return n.prototype.renderShadow=function(t,e,i,r){void 0===i&&(i=null);var l,o=R.transform({x:0,y:0},t.shadow.angle,t.shadow.distance);r&&(l=r.getElementById(e.id+"_shadow")),l||(l=document.createElementNS("http://www.w3.org/2000/svg",i?"path":"rect"),e.appendChild(l));var h={id:e.id+"_shadow",fill:t.shadow.color,stroke:t.shadow.color,opacity:t.shadow.opacity.toString(),transform:"rotate("+t.angle+","+(t.x+t.width*t.pivotX)+","+(t.y+t.height*t.pivotY)+")translate("+(t.x+o.x)+","+(t.y+o.y)+")"};if(r){var c=r.getElementById(e.id);c&&c.insertBefore(l,c.firstChild)}ti(l,h),i?i&&this.renderPath(l,t,i):ti(l,{width:t.width,height:t.height})},n.prototype.parseDashArray=function(t){return[]},n.prototype.drawRectangle=function(t,e,i,r,s,o,a,l,h){var c,d,u,f;e.shadow&&!r&&this.renderShadow(e,t,void 0,o),c=e.id===t.id?e.id+"_container":e.id,o&&(d=o.getElementById(c)),(!d||s)&&(d=document.createElementNS("http://www.w3.org/2000/svg","rect"),t.appendChild(d)),o&&!e.shadow&&(u=o.getElementById(e.id+"_groupElement_shadow"))&&u.parentNode.removeChild(u),f=l?{id:c,x:e.x.toString(),y:e.y.toString(),width:e.width.toString(),height:e.height.toString(),visibility:e.visible?"visible":"hidden",transform:"rotate("+e.angle+","+(e.x+e.width/2)+","+(e.y+e.height/2)+")",rx:e.cornerRadius||0,ry:e.cornerRadius||0,opacity:e.opacity}:{id:c,x:e.x.toString(),y:e.y.toString(),width:e.width.toString(),height:e.height.toString(),visibility:e.visible?"visible":"hidden",transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")",rx:e.cornerRadius||0,ry:e.cornerRadius||0,opacity:e.opacity},a&&(f.role="img",f["aria-label"]=a);var p=e.class||"";h||(p.includes("e-diagram-resize-handle")||p.includes("e-diagram-endpoint-handle")||p.includes("e-diagram-bezier-control-handle"))&&(p+=" e-disabled"),e.class&&(f.class=p),a||(f["pointer-events"]="none"),ti(d,f),this.setSvgStyle(d,e,i)},n.prototype.updateSelectionRegion=function(t,e){var i;i=t.parentNode.getElementById(e.id);var r={id:e.id,x:e.x.toString(),y:e.y.toString(),width:e.width.toString(),height:e.height.toString(),transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")",class:"e-diagram-selected-region"};i||(i=document.createElementNS("http://www.w3.org/2000/svg","rect"),t.appendChild(i)),this.setSvgStyle(i,e),ti(i,r)},n.prototype.createGElement=function(t,e){return Fi(t,e)},n.prototype.drawLine=function(t,e){var i=document.createElementNS("http://www.w3.org/2000/svg","line");this.setSvgStyle(i,e);var r=e.x+e.width*e.pivotX,s=e.y+e.height*e.pivotY,o={id:e.id,x1:e.startPoint.x+e.x,y1:e.startPoint.y+e.y,x2:e.endPoint.x+e.x,y2:e.endPoint.y+e.y,stroke:e.stroke,"stroke-width":e.strokeWidth.toString(),opacity:e.opacity.toString(),transform:"rotate("+e.angle+" "+r+" "+s+")",visibility:e.visible?"visible":"hidden"};e.class&&(o.class=e.class),ti(i,o),t.appendChild(i)},n.prototype.drawCircle=function(t,e,i,r){var s=document.createElementNS("http://www.w3.org/2000/svg","circle");this.setSvgStyle(s,e);var o=e.class||"";i||(o+=" e-disabled");var a={id:e.id,cx:e.centerX,cy:e.centerY,r:e.radius,visibility:e.visible?"visible":"hidden",class:o};r&&(a.role="img",a["aria-label"]=r),s.style.display=e.visible?"block":"none",ti(s,a),t.appendChild(s)},n.prototype.drawPath=function(t,e,i,r,s,o,a){var h,c,l=[];l=XB(l=Ed(e.data)),e.shadow&&this.renderShadow(e,t,l,s),s&&!e.shadow&&(h=s.getElementById(e.id+"_groupElement_shadow"))&&h.parentNode.removeChild(h),s&&(c=s.getElementById(e.id)),(!c||r)&&(c=document.createElementNS("http://www.w3.org/2000/svg","path"),t.appendChild(c)),this.renderPath(c,e,l);var d={};d=a?{id:e.id,transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")translate("+e.x+","+e.y+"),scale("+a+")",visibility:e.visible?"visible":"hidden",opacity:e.opacity}:{id:e.id,transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")translate("+e.x+","+e.y+")",visibility:e.visible?"visible":"hidden",opacity:e.opacity},o&&(d.role="img",d["aria-label"]=o),e.class&&(d.class=e.class),ti(c,d),this.setSvgStyle(c,e,i)},n.prototype.renderPath=function(t,e,i){var r,s,o,a,l,h,c,d,u=i,f="";for(l=0,h=0,d=0,c=u.length;de.width&&"Wrap"!==e.textOverflow&&"NoWrap"===e.textWrapping&&(h[0].text=VF(e.content,e)),v=0;vD&&(u.text=u.text.slice(0,u.text.length-3),u.text=u.text.concat("..."),l.data=u.text),this.alignText(y,f,u,l,p,g,v,e,h),C+=u.dy}}C&&e.isHorizontalLane&&(M=e.parentOffsetX+e.pivotX,w=e.parentOffsetY+e.pivotY,e.y=e.parentOffsetY-C*e.pivotY+.5),e.textDecoration&&"LineThrough"===e.textDecoration&&(e.textDecoration=cb(e.textDecoration));var P={id:e.id+"_text",fill:e.color,visibility:e.visible?"visible":"hidden","text-decoration":e.textDecoration,transform:"rotate("+e.angle+","+M+","+w+")translate("+e.x+","+e.y+")",opacity:e.opacity};r&&(P.role="img",P["aria-label"]=r),ti(y,P)}},n.prototype.alignText=function(t,e,i,r,s,o,a,l,h){"justify"!==l.textAlign?this.setText(t,e,i,r,s,o,l):a!==h.length-1?this.setText(t,e,i,r,s,o,l,l.width,"spacing"):this.setText(t,e,i,r,s,o,l)},n.prototype.setText=function(t,e,i,r,s,o,a,l,h){ti(e,"justify"!==a.textAlign?{x:s.toString(),y:o.toString()}:{x:s.toString(),y:o.toString(),textLength:l||0,lengthAdjust:h||"spacing"}),t.setAttribute("fill",i.text),e.appendChild(r),t.appendChild(e)},n.prototype.drawImage=function(t,e,i,r){var s;i&&(s=i.getElementById(e.id+"image")),s||(s=document.createElementNS("http://www.w3.org/2000/svg","image"),t.appendChild(s));var o=new Image;o.src=e.source;var a="None"!==e.scale?e.scale:"",l=e.alignment,h=l.charAt(0).toLowerCase()+l.slice(1);"Stretch"!==a&&(h+=" "+a.charAt(0).toLowerCase()+a.slice(1)),ti(s,{id:e.id+"image",x:e.x.toString(),y:e.y.toString(),transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")",width:e.width.toString(),visibility:e.visible?"visible":"hidden",height:e.height.toString(),preserveAspectRatio:h,opacity:e.opacity.toString()}),s.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",o.src.toString())},n.prototype.drawHTMLContent=function(t,e,i,r,s){var o,a;if(e&&(o=e.querySelector("#"+t.id+"_html_element")),!o){(a=e.querySelector("#"+t.id+"_html_element")||e.querySelector("#"+t.nodeId+"_html_element"))||(a=Tt("div",{id:t.nodeId+"_html_element",class:"foreign-object"})),o=Tt("div",{id:t.id+"_html_element",class:"foreign-object"});var c=document.getElementById(t.diagramId).ej2_instances[0],d=!1;if(e.parentNode&&e.parentNode.parentNode&&e.parentNode.parentNode.parentNode&&e.parentNode.parentNode.parentNode.classList.contains("e-overview")&&(d=!0),d)c.isReact?c.renderReactTemplates(function(){o.appendChild(t.template.cloneNode(!0))}):o.appendChild(t.template.cloneNode(!0));else{if("string"==typeof t.template){var u=document.createElement("div");u.innerHTML=t.template,t.template=u,c.selectedItems.userHandles.filter(function(g){return g.name===t.id.split("_shape")[0]&&""!==g.template})[0].template=t.template}t.isTemplate&&t.template?o.appendChild(t.template):t.template&&o.appendChild(t.template.cloneNode(!0))}void 0!==s&&e.childNodes.length>s&&e.insertBefore(o,e.childNodes[parseInt(s.toString(),10)]),a.appendChild(o),e.appendChild(a)}var p=xn(t).topLeft;o.setAttribute("style","height:"+t.actualSize.height+"px; width:"+t.actualSize.width+"px;left:"+p.x+"px; top:"+p.y+"px;position:absolute;transform:rotate("+(t.rotateAngle+t.parentTransform)+"deg);pointer-events:"+(r?"all":"none")+";visibility:"+(t.visible?"visible":"hidden")+";opacity:"+t.style.opacity+";")},n.prototype.drawNativeContent=function(t,e,i,r,s){var o,a;if(s&&(o=s.getElementById(t.id+"_native_element"),a=s.getElementById(t.id+"_clip")),!o){(o=document.createElementNS("http://www.w3.org/2000/svg","g")).setAttribute("id",t.id+"_native_element"),o.appendChild(t.template.cloneNode(!0));var l=this.createGElement("g",{id:t.id+"_inner_native_element"});l.appendChild(o),e.appendChild(l)}a&&o.removeChild(a),o.setAttribute("style","visibility:"+(t.visible?"visible":"hidden")+";opacity:"+t.style.opacity+";"),this.setNativTransform(t,o,i,r),"Slice"===t.scale&&this.drawClipPath(t,o,i,r,s),ti(o,t.description?{role:"img","aria-label":t.description}:{})},n.prototype.setNativTransform=function(t,e,i,r){var s=0!==t.contentSize.width?t.contentSize.width:1,o=0!==t.contentSize.height?t.contentSize.height:1;e.setAttribute("transform","rotate("+t.parentTransform+","+t.offsetX+","+t.offsetY+") translate("+(t.offsetX-t.templatePosition.x*r/s-r*t.pivot.x)+","+(t.offsetY-t.templatePosition.y*i/o-i*t.pivot.y)+") scale("+r/s+","+i/o+")")},n.prototype.drawClipPath=function(t,e,i,r,s){var o=t.contentSize.width,a=t.contentSize.height,l=t.width/(r/o),h=t.height/(i/a),c=t.templatePosition.x+(t.width>=t.height?0:(o-l)/2),d=t.templatePosition.y+(t.height>=t.width?0:(a-h)/2),u=s.getElementById(t.id+"_clip");(u=document.createElementNS("http://www.w3.org/2000/svg","clipPath")).setAttribute("id",t.id+"_clip"),e.appendChild(u);var f=s.getElementById(t.id+"_clip_rect");return f=document.createElementNS("http://www.w3.org/2000/svg","rect"),u.appendChild(f),ti(f,{id:t.id+"_clip_rect",width:l.toString(),height:h.toString(),x:c.toString(),y:d.toString()}),sm()?e.setAttribute("clip-path","url("+location.protocol+"//"+location.host+location.pathname+"#"+t.id+"_clip)"):e.setAttribute("clip-path","url(#"+t.id+"_clip)"),e},n.prototype.renderGradient=function(t,e,i){var r,s,o,h,c,a=mT(i),l=a.getElementById(i+"gradient_pattern");if(l||(l=Fi("defs",{id:i+"gradient_pattern"}),a.insertBefore(l,a.firstChild)),gF(e.id),"None"!==t.gradient.type){for(var d=0;dt.width&&("Ellipsis"===t.textOverflow||"Clip"===t.textOverflow)&&"NoWrap"===t.textWrapping?0:.5*t.width:"right"===t.textAlign&&(c=1*t.width),s.x=0+c+(e?e.x:0),s.y=1.2+d-r.height/2,s},n}(),Pc=function(){function n(t,e,i){this.renderer=null,this.isSvgMode=!0,this.touchMove=void 0,this.transform={x:0,y:0},this.diagramId=t,this.element=xt(this.diagramId),this.svgRenderer=e,this.isSvgMode=i,this.renderer=i?new $f:new bo}return n.prototype.setCursor=function(t,e){t.style.cursor=e},n.prototype.setLayers=function(){this.iconSvgLayer=this.element.getElementsByClassName("e-ports-expand-layer")[0],this.adornerSvgLayer=this.element.getElementsByClassName("e-adorner-layer")[0],this.nativeSvgLayer=this.element.getElementsByClassName("e-native-layer")[0],this.diagramSvgLayer=this.element.getElementsByClassName("e-diagram-layer")[0]},n.prototype.getAdornerLayer=function(){return gT(this.diagramId)},n.prototype.getParentSvg=function(t,e,i){return this.diagramId&&t&&t.id?t.id.split("_icon_content").length>1||t.id.split("_nodeport").length>1||t.elementActions&Xr.ElementIsPort?this.iconSvgLayer:e&&"selector"===e?this.adornerSvgLayer:t instanceof En?this.nativeSvgLayer:this.diagramSvgLayer:i},n.prototype.getParentElement=function(t,e,i,r){var s=e;if(i&&this.diagramId&&t&&t.id){t.id.split("_icon_content").length>1?(s=i.getElementById(this.diagramId+"_diagramExpander"),e=null):t.id.split("_nodeport").length>1?s=i.getElementById(this.diagramId+"_diagramPorts"):t instanceof En?(s=i.getElementById(this.diagramId+"_nativeLayer"),e=null):t.elementActions&Xr.ElementIsPort?(s=i.getElementById(this.diagramId+"_diagramPorts"),e=null):s=i.getElementById(this.diagramId+"_diagramLayer");var o=this.getGroupElement(t,e||s,r);s=o.g,o.svg&&(i=o.svg)}return{g:s,svg:i}},n.prototype.getGroupElement=function(t,e,i){var r,o,s=this.getParentSvg(t);if(e&&s){if(s&&!(r=s.getElementById(t.id+"_groupElement"))&&s!==this.nativeSvgLayer){var a=this.nativeSvgLayer;r=a.getElementById(t.id+"_groupElement"),o=a}r||(r=this.svgRenderer.createGElement("g",{id:t.id+"_groupElement"}),void 0!==i&&e.childNodes.length>i?e.insertBefore(r,e.childNodes[parseInt(i.toString(),10)]):e.appendChild(r))}return{g:r,svg:o}},n.prototype.renderElement=function(t,e,i,r,s,o,a,l,h,c,d){t instanceof Cs?(t.id=t.id?t.id:Qe(),this.renderContainer(t,e,i,r,s,o,a,l,h,c,d)):t instanceof bI?this.renderImageElement(t,e,r,s,a):t instanceof Ze?this.renderPathElement(t,e,r,s,a,h,d):t instanceof li?this.renderTextElement(t,e,r,s,a,c):t instanceof En?this.renderNativeElement(t,e,r,s,a):t instanceof es?this.renderHTMLElement(t,e,i,r,s,a,l):this.renderRect(t,e,r,s,h)},n.prototype.drawSelectionRectangle=function(t,e,i,r,s,o){var a={width:i*o.scale,height:r*o.scale,x:.5+(t=(t+o.tx)*o.scale),y:.5+(e=(e+o.ty)*o.scale),fill:"transparent",stroke:"gray",angle:0,pivotX:.5,pivotY:.5,strokeWidth:1,dashArray:"6 3",opacity:1,visible:!0,id:s.id+"_selected_region"},l=this.getAdornerLayer();this.svgRenderer.updateSelectionRegion(l,a)},n.prototype.renderHighlighter=function(t,e,i){var r=t.actualSize.width||2,s=t.actualSize.height||2,o=t.offsetX-r*t.pivot.x,a=t.offsetY-s*t.pivot.y;this.svgRenderer.drawRectangle(e,{width:r*i.scale,height:s*i.scale,x:o=(o+i.tx)*i.scale,y:a=(a+i.ty)*i.scale,fill:"transparent",stroke:"#8CC63F",angle:t.rotateAngle,pivotX:t.pivot.x,pivotY:t.pivot.y,strokeWidth:4,dashArray:"",opacity:1,cornerRadius:0,visible:!0,id:e.id+"_highlighter",class:"e-diagram-highlighter"},this.diagramId,void 0,void 0,e)},n.prototype.renderSelectionRectangle=function(t,e,i,r){var s=t.actualSize.width||2,o=t.actualSize.height||2,a=t.offsetX-s*t.pivot.x,l=t.offsetY-o*t.pivot.y,h={width:s*i.scale,height:o*i.scale,x:a=(a+i.tx)*i.scale,y:l=(l+i.ty)*i.scale,fill:"transparent",stroke:"#00cc00",angle:t.rotateAngle,pivotX:t.pivot.x,pivotY:t.pivot.y,strokeWidth:r?2:1,dashArray:"",opacity:1,cornerRadius:0,visible:!0,id:t.id+"_highlighter",class:r?"e-diagram-first-selection-indicator e-diagram-selection-indicator":"e-diagram-selection-indicator"},c=this.getParentSvg(t,"selector");this.svgRenderer.drawRectangle(e,h,this.diagramId,void 0,void 0,c)},n.prototype.renderSelectionLine=function(t,e,i,r){var s=this.getBaseAttributes(t,i);s.data=t.absolutePath,s.id=s.id+"_highlighter";var o=t.description?t.description:t.id;this.isSvgMode||(s.x=t.flipOffset.x?t.flipOffset.x:s.x,s.y=t.flipOffset.y?t.flipOffset.y:s.y),i&&(s.x=s.x*i.scale,s.y=s.y*i.scale),s.stroke="#00cc00",s.strokeWidth=r?2:1,s.class=r?"e-diagram-first-selection-indicator e-diagram-selection-indicator":"e-diagram-selection-indicator";var a=this.getParentSvg(t,"selector");this.svgRenderer.drawPath(e,s,this.diagramId,void 0,a,o,i.scale)},n.prototype.renderStackHighlighter=function(t,e,i,r,s,o,a){var l=t.actualSize.width||2,h=t.offsetX-l*t.pivot.x,c=t.actualSize.height||2,d=t.offsetY-c*t.pivot.y;h=(h+i.tx)*i.scale;var u,f=t.bounds,p="";if(d=(d+i.ty)*i.scale,r)if(o){var v,y;u="M 0 0 L "+(2+(g=l*i.scale))+" 0 Z",v=t.actualSize.width/Number(f.width?f.width:1)*i.scale,y=t.actualSize.height/Number(f.height?f.height:1)*i.scale,p=vI(mI(Ed("M7,4 L8,4 8,7 11,7 11,8 8,8 8,11 7,11 7,8 4,8 4,7 7,7 z M7.5,0.99999994C3.9160004,1 1,3.9160004 0.99999994,7.5 1,11.084 3.9160004,14 7.5,14 11.084,14 14,11.084 14,7.5 14,3.9160004 11.084,1 7.5,0.99999994 z M7.5,0 C11.636002,0 15,3.3639984 15,7.5 15,11.636002 11.636002,15 7.5,15 3.3640003,15 0,11.636002 0,7.5 0,3.3639984 3.3640003,0 7.5,0 z")),v+g+2,y-8,!1,f.x,f.y,0,0),s.y>=t.offsetY&&(d+=c)}else{var g;a&&s.y>=t.offsetY&&(d+=c*i.scale),u="M -10 -10 L 0 0 Z M -10 10 L 0 0 Z M 0 0 L "+(g=l*i.scale)+" 0 Z M "+g+" 0 L "+(g+10)+" 10 Z L "+(g+10)+" -10 Z"}else u="M 10 -10 L 0 0 Z M -10 -10 L 0 0 Z M 0 0 L 0 "+(g=c*i.scale)+" Z M 0 "+g+" L -10 "+(g+10)+" Z L 10 "+(g+10)+" Z",s.x>=t.offsetX&&(h+=l*i.scale);this.svgRenderer.drawPath(e,{data:u+p,width:l*i.scale,height:c*i.scale,x:h,y:d,fill:"transparent",stroke:"#8CC63F",angle:t.rotateAngle,pivotX:t.pivot.x,pivotY:t.pivot.y,strokeWidth:1,dashArray:"",opacity:1,visible:!0,id:e.id+"_stack_highlighter",class:"e-diagram-highlighter"},this.diagramId)},n.prototype.drawLine=function(t,e){this.svgRenderer.drawLine(t,e)},n.prototype.drawPath=function(t,e){this.svgRenderer.drawPath(t,e,this.diagramId)},n.prototype.renderResizeHandle=function(t,e,i,r,s,o,a,l,h,c,d){var u=t.offsetX-t.actualSize.width*t.pivot.x,f=t.offsetY-t.actualSize.height*t.pivot.y,p=t.actualSize.height,g=t.actualSize.width;if(!c&&i&bt.Rotate&&HI(this.rendererActions)&&!A3(this.rendererActions))this.renderPivotLine(t,e,o,s,a),this.renderRotateThumb(t,e,o,s,a);else if(this.touchMove){var v=document.getElementById("rotateThumb");v&&v.setAttribute("visibility","hidden")}this.renderBorder(t,e,o,l,h,c);var y=t.actualSize.width*r,S=t.actualSize.height*r;!h&&HI(this.rendererActions)&&!A3(this.rendererActions)&&(t.isTextAnnotation||(y>=40&&S>=40&&(s&mr.ResizeNorthWest&&this.renderCircularHandle("resizeNorthWest",t,u,f,e,qr(s,"ResizeNorthWest"),i&bt.ResizeNorthWest,o,void 0,a,{"aria-label":"Thumb to resize the selected object on top left side direction"},void 0,"e-diagram-resize-handle e-northwest",d),s&mr.ResizeNorthEast&&this.renderCircularHandle("resizeNorthEast",t,u+g,f,e,qr(s,"ResizeNorthEast"),i&bt.ResizeNorthEast,o,void 0,a,{"aria-label":"Thumb to resize the selected object on top right side direction"},void 0,"e-diagram-resize-handle e-northeast",d),s&mr.ResizeSouthWest&&this.renderCircularHandle("resizeSouthWest",t,u,f+p,e,qr(s,"ResizeSouthWest"),i&bt.ResizeSouthWest,o,void 0,a,{"aria-label":"Thumb to resize the selected object on bottom left side direction"},void 0,"e-diagram-resize-handle e-southwest",d),s&mr.ResizeSouthEast&&this.renderCircularHandle("resizeSouthEast",t,u+g,f+p,e,qr(s,"ResizeSouthEast"),i&bt.ResizeSouthEast,o,void 0,a,{"aria-label":"Thumb to resize the selected object on bottom right side direction"},void 0,"e-diagram-resize-handle e-southeast",d)),s&mr.ResizeNorth&&this.renderCircularHandle("resizeNorth",t,u+g/2,f,e,qr(s,"ResizeNorth"),i&bt.ResizeNorth,o,void 0,a,{"aria-label":"Thumb to resize the selected object on top side direction"},void 0,"e-diagram-resize-handle e-north",d),s&mr.ResizeSouth&&this.renderCircularHandle("resizeSouth",t,u+g/2,f+p,e,qr(s,"ResizeSouth"),i&bt.ResizeSouth,o,void 0,a,{"aria-label":"Thumb to resize the selected object on bottom side direction"},void 0,"e-diagram-resize-handle e-south",d),s&mr.ResizeWest&&this.renderCircularHandle("resizeWest",t,u,f+p/2,e,qr(s,"ResizeWest"),i&bt.ResizeWest,o,void 0,a,{"aria-label":"Thumb to resize the selected object on left side direction"},void 0,"e-diagram-resize-handle e-west",d),s&mr.ResizeEast&&this.renderCircularHandle("resizeEast",t,u+g,f+p/2,e,qr(s,"ResizeEast"),i&bt.ResizeEast,o,void 0,a,{"aria-label":"Thumb to resize the selected object on right side direction"},void 0,"e-diagram-resize-handle e-east",d)))},n.prototype.renderEndPointHandle=function(t,e,i,r,s,o,a,l,h,c){var p,g,d=t.sourcePoint,u=t.targetPoint,f=t.wrapper;if(this.renderCircularHandle("connectorSourceThumb",f,d.x,d.y,e,qr(r,"ConnectorSourceThumb"),i&bt.ConnectorSource,s,o,void 0,{"aria-label":"Thumb to move the source point of the connector"},void 0,"e-diagram-endpoint-handle e-sourceend",c),this.renderCircularHandle("connectorTargetThumb",f,u.x,u.y,e,qr(r,"ConnectorTargetThumb"),i&bt.ConnectorTarget,s,a,void 0,{"aria-label":"Thumb to move the target point of the connector"},void 0,"e-diagram-endpoint-handle e-targetend",c),l)if("Straight"===t.type&&t.segments.length>0)for(p=0;p0)for(p=0;p=3&&3===t.segments.length&&(S=1,b=t.segments.length-1),S=t.segments.length>t.maxSegmentThumb+2?2:S,b=t.segments.length>t.maxSegmentThumb+2?t.segments.length-2:b,1===t.segments.length&&t.segments[0].points.length<=2&&(S=1,b=t.segments.length),p=S;p=50&&i.allowDrag),this.renderOrthogonalThumb(t+"_"+(d+1),e,(i.points[parseInt(d.toString(),10)].x+i.points[d+1].x)/2,(i.points[parseInt(d.toString(),10)].y+i.points[d+1].y)/2,r,h,l,o,a,u)}else for(d=0;d=50&&i.allowDrag),this.renderOrthogonalThumb(t+"_"+(d+1),e,(i.points[parseInt(d.toString(),10)].x+i.points[d+1].x)/2,(i.points[parseInt(d.toString(),10)].y+i.points[d+1].y)/2,r,h,l,o,a,u)},n.prototype.renderOrthogonalThumb=function(t,e,i,r,s,o,a,l,h,c){var d,g,u=0,f=document.getElementById(this.diagramId);f&&(g=f.ej2_instances[0]);var y=h.constraints&qe.InheritSegmentThumbShape?g.segmentThumbShape:h.segmentThumbShape,b=h.constraints&qe.InheritSegmentThumbSize?g.segmentThumbSize:h.segmentThumbSize;if(d="horizontal"===a?function tre(n){return sre[""+n]}(y):n3(y),"Arrow"===y||"DoubleArrow"===y||"OpenArrow"===y)switch(c){case"Bottom":case"Right":u=180;break;default:u=0}else if("Fletch"===y||"OpenFetch"===y||"IndentedArrow"===y||"OutdentedArrow"===y)switch(c){case"Bottom":u=-90;break;case"Top":u=90;break;case"Right":u=180;break;default:u=0}var M={x:(i+l.tx)*l.scale-b/2,y:(r+l.ty)*l.scale-b/2,angle:u,fill:"#e2e2e2",stroke:"black",strokeWidth:1,dashArray:"",data:d,width:b,height:b,pivotX:.5,pivotY:.5,opacity:1,visible:o,id:t,class:"e-diagram-ortho-segment-handle"},w=np(M.data),C=new me(M.width,M.height),D=new Ze;if(M.data=D.updatePath(M.data,w,C),this.touchMove){var A=document.getElementById(t);A?this.updateSegmentPosition(A,M):this.svgRenderer.drawPath(s,M,this.diagramId)}else this.svgRenderer.drawPath(s,M,this.diagramId)},n.prototype.renderPivotLine=function(t,e,i,r,s){var o=t,l=!!(r&mr.Rotate);s&&(l=!1);var h=this.getBaseAttributes(o,i);h.fill="None",h.stroke="black",h.strokeWidth=1,h.dashArray="2,3",h.visible=l;var c=i.scale;h.x*=c,h.y*=c,h.width*=c,h.height*=c,h.id="pivotLine",h.class="e-diagram-pivot-line";var u={x:o.actualSize.width*o.pivot.x*c,y:0};h.startPoint={x:o.actualSize.width*o.pivot.x*c,y:-20},h.endPoint=u,this.svgRenderer.drawLine(e,h)},n.prototype.renderBezierLine=function(t,e,i,r,s,o){var l=this.getBaseAttributes(e,o);l.id=t,l.stroke="black",l.strokeWidth=1,l.dashArray="3,3",l.fill="None",l.class="e-diagram-bezier-control-line",l.x=0,l.y=0;var h=o.scale,g={x:(s.x+o.tx)*h,y:(s.y+o.ty)*h};l.startPoint={x:(r.x+o.tx)*h,y:(r.y+o.ty)*h},l.endPoint=g,this.svgRenderer.drawLine(i,l)},n.prototype.renderCircularHandle=function(t,e,i,r,s,o,a,l,h,c,d,u,f,p){var g=e,v={x:i,y:r};if(0!==g.rotateAngle||0!==g.parentTransform){var y=Bi();qi(y,g.rotateAngle+g.parentTransform,g.offsetX,g.offsetY),v=Ke(y,v)}var S=this.getBaseAttributes(g);if(S.stroke="black",S.strokeWidth=1,void 0!==u?(S.id="segmentEnd_"+u,S.fill="#e2e2e2"):S.fill=h?"#8CC63F":"white",S.cornerRadius=p/2,S.angle=e.rotateAngle,S.id=t,S.visible=o,S.class=f,S.width=p,S.height=p,S.x=(v.x+l.tx)*l.scale,S.y=(v.y+l.ty)*l.scale,S.x=S.x-S.width/2,S.y=S.y-S.height/2,h&&(S.class+=" e-connected"),c&&(S.visible=!1),this.touchMove){var b=document.getElementById(t);if(b)this.updateResizeHandle(b,S);else{var M=this.getParentSvg(e,"selector");this.svgRenderer.drawRectangle(s,S,this.diagramId,!0,!0,M,d,!0,a)}}else M=this.getParentSvg(e,"selector"),this.svgRenderer.drawRectangle(s,S,this.diagramId,!0,!0,M,d,!0,a)},n.prototype.updateResizeHandle=function(t,e){ti(t,{id:e.id,x:e.x.toString(),y:e.y.toString(),width:e.width.toString(),height:e.height.toString(),visibility:e.visible?"visible":"hidden",transform:"rotate("+e.angle+","+(e.x+e.width/2)+","+(e.y+e.height/2)+")",rx:e.cornerRadius||0,ry:e.cornerRadius||0,opacity:e.opacity})},n.prototype.renderBezierHandle=function(t,e,i,r,s,o,a,l,h,c,d,u,f){var v,p=document.getElementById(this.diagramId);p&&(v=p.ej2_instances[0]);var y=e,S={x:i,y:r};if(0!==y.rotateAngle||0!==y.parentTransform){var b=Bi();qi(b,y.rotateAngle+y.parentTransform,y.offsetX,y.offsetY),S=Ke(b,S)}var D=a.constraints&qe.InheritSegmentThumbSize?v.segmentThumbSize:a.segmentThumbSize,A=n3(a.constraints&qe.InheritSegmentThumbShape?v.segmentThumbShape:a.segmentThumbShape),x=this.getBaseAttributes(y);x.stroke="black",x.strokeWidth=1,void 0!==d?(x.id="segmentEnd_"+d,x.fill="#e2e2e2"):x.fill=h?"#8CC63F":"white",x.angle=e.rotateAngle,x.id=t,x.visible=o,x.class=u,x.width=D,x.height=D,x.data=A,x.x=(S.x+l.tx)*l.scale,x.y=(S.y+l.ty)*l.scale,x.x=x.x-x.width/2,x.y=x.y-x.height/2,h&&(x.class+=" e-connected"),c&&(x.visible=!1);var P=np(x.data),L=new me(x.width,x.height),O=new Ze;if(x.data=O.updatePath(x.data,P,L),this.touchMove){var N=document.getElementById(t);if(N)this.updateSegmentPosition(N,x);else{var T=this.getParentSvg(e,"selector");this.svgRenderer.drawPath(s,x,this.diagramId,!0,T)}}else T=this.getParentSvg(e,"selector"),this.svgRenderer.drawPath(s,x,this.diagramId,!0,T)},n.prototype.updateSegmentPosition=function(t,e){ti(t,{id:e.id,transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")translate("+e.x+","+e.y+")",visibility:e.visible?"visible":"hidden",opacity:e.opacity})},n.prototype.renderBorder=function(t,e,i,r,s,o){var l=this.getBaseAttributes(t,i);l.x*=i.scale,l.y*=i.scale,l.width*=i.scale,l.height*=i.scale,l.fill="transparent",l.stroke="#097F7F",l.strokeWidth=1.2,l.gradient=null,l.dashArray="6,3",l.class="e-diagram-selector",o&&(l.class+=" e-diagram-lane"),l.id="borderRect",l.id=this.rendererActions&Ga.DrawSelectorBorder?"borderRect_symbol":"borderRect",r||(l.class+=" e-disabled"),s&&(l.class+=" e-thick-border"),l.cornerRadius=0;var h=this.getParentSvg(t,"selector");this.svgRenderer.drawRectangle(e,l,this.diagramId,void 0,!0,h)},n.prototype.renderUserHandler=function(t,e,i,r,s,o){for(var l,a=t.wrapper,h=0,c=t.userHandles;h0||d.disableNodes&&t.nodes.length>0||"Drag"===s&&o)&&(l=!1);var u=document.getElementById(d.name+"_template_hiddenUserHandle");u&&(d.template=u.childNodes[0].cloneNode(!0));var f=Kx(t,d,i);if(f.x=(f.x+i.tx)*i.scale,f.y=(f.y+i.ty)*i.scale,d.visible&&(d.visible=!!(t.constraints&mr.UserHandle)),l)if(d.pathData){var p=d.pathData?d.pathData:d.content,g=this.getBaseAttributes(a);g.id=d.name+"_userhandle",g.fill=d.backgroundColor,g.stroke=d.borderColor,g.strokeWidth=d.borderWidth,g.centerX=f.x,g.centerY=f.y,g.radius=.5*d.size,g.class="e-diagram-userhandle-circle",g.angle=0,g.visible=d.visible,g.opacity=1,this.svgRenderer.drawCircle(e,g,1,{"aria-label":d.name+"user handle"});var y=[];y=mI(y=Ed(p));var S=np(p),w=vI(y,(d.size-.45*d.size)/S.width,(d.size-.45*d.size)/S.height,!0,S.x,S.y,0,0);S=np(w),this.svgRenderer.drawPath(e,C={x:f.x-S.width/2,y:f.y-S.height/2,angle:0,id:"",class:"e-diagram-userhandle-path",fill:d.pathColor,stroke:d.backgroundColor,strokeWidth:.5,dashArray:"",data:w,width:d.size-5,height:d.size-5,pivotX:0,pivotY:0,opacity:1,visible:d.visible},this.diagramId,void 0,void 0,{"aria-label":d.name+"user handle"})}else if(d.content){var D=new En(d.name,this.diagramId);D.content=d.content,D.offsetX=f.x,D.offsetY=f.y,D.id=d.name+"_shape",D.horizontalAlignment="Center",D.verticalAlignment="Center",D.visible=d.visible,D.setOffsetWithRespectToBounds(f.x,f.y,"Fraction"),D.relativeMode="Object",D.description=d.name||"User handle",D.measure(new me(d.size,d.size)),D.arrange(D.desiredSize),this.svgRenderer.drawNativeContent(D,e,d.size,d.size,this.adornerSvgLayer)}else if(d.source){var C,A=new bI;(C=this.getBaseAttributes(A,i)).width=d.size,C.height=d.size,C.x=f.x-d.size/2,C.y=f.y-d.size/2,C.sourceWidth=d.size,C.sourceHeight=d.size,C.alignment=A.imageAlign,C.source=d.source,C.scale=A.imageScale,C.visible=d.visible,C.description=d.name||"User handle",C.id=d.name+"_",this.renderer.drawImage(e,C,this.adornerSvgLayer,!1)}else{var x=new es(d.name,this.diagramId);x.offsetX=f.x,x.offsetY=f.y,x.id=d.name+"_shape",x.visible=d.visible,x.relativeMode="Object",x.template=d.template,x.measure(new me(d.size,d.size)),x.arrange(x.desiredSize),this.svgRenderer.drawHTMLContent(x,r,void 0,!0,void 0)}}},n.prototype.renderRotateThumb=function(t,e,i,r,s){new Ze;var a,l=new me;l.width=18,l.height=16;var d=!!(r&mr.Rotate);s&&(d=!1);var f=t.offsetX-t.actualSize.width*t.pivot.x+t.pivot.x*t.actualSize.width,p=t.offsetY-t.actualSize.height*t.pivot.y;if(a={x:(f=(f+i.tx)*i.scale)-.5*l.width,y:(p=(p+i.ty)*i.scale)-30-.5*l.height},0!==t.rotateAngle||0!==t.parentTransform){var g=Bi();qi(g,t.rotateAngle+t.parentTransform,(i.tx+t.offsetX)*i.scale,(i.ty+t.offsetY)*i.scale),a=Ke(g,a)}var v={x:a.x,y:a.y,angle:t.rotateAngle+t.parentTransform,fill:"#231f20",stroke:"black",strokeWidth:.5,dashArray:"",data:"M 16.856144362449648 10.238890446662904 L 18.000144362449646 3.437890446662903L 15.811144362449646 4.254890446662903 C 14.837144362449646 2.5608904466629028 13.329144362449647 1.2598904466629026 11.485144362449645 0.5588904466629026 C 9.375144362449646 - 0.24510955333709716 7.071144362449646 - 0.18010955333709716 5.010144362449646 0.7438904466629028 C 2.942144362449646 1.6678904466629028 1.365144362449646 3.341890446662903 0.558144362449646 5.452890446662903 C - 0.244855637550354 7.567890446662903 - 0.17985563755035394 9.866890446662904 0.7431443624496461 11.930890446662904 C 1.6681443624496461 13.994890446662904 3.343144362449646 15.575890446662903 5.457144362449647 16.380890446662903 C 6.426144362449647 16.7518904466629 7.450144362449647 16.9348904466629 8.470144362449647 16.9348904466629 C 9.815144362449647 16.9348904466629 11.155144362449647 16.6178904466629 12.367144362449647 15.986890446662901 L 11.351144362449647 14.024890446662901 C 9.767144362449647 14.8468904466629 7.906144362449647 14.953890446662902 6.237144362449647 14.3178904466629 C 4.677144362449647 13.7218904466629 3.444144362449647 12.5558904466629 2.758144362449647 11.028890446662901 C 2.078144362449646 9.501890446662903 2.031144362449646 7.802890446662903 2.622144362449646 6.243890446662903 C 3.216144362449646 4.6798904466629025 4.387144362449646 3.442890446662903 5.914144362449646 2.760890446662903 C 7.437144362449646 2.078890446662903 9.137144362449646 2.0298904466629026 10.700144362449645 2.6258904466629027 C 11.946144362449646 3.100890446662903 12.971144362449646 3.9538904466629026 13.686144362449646 5.049890446662903 L 11.540144362449645 5.850890446662903 L 16.856144362449648 10.238890446662904 Z",width:20,height:20,pivotX:0,pivotY:0,opacity:1,visible:d,id:"rotateThumb",class:"e-diagram-rotate-handle"};if(this.touchMove){var y=document.getElementById("rotateThumb");y?this.updateSegmentPosition(y,v):this.svgRenderer.drawPath(e,v,this.diagramId,!0,void 0,{"aria-label":"Thumb to rotate the selected object"})}else this.svgRenderer.drawPath(e,v,this.diagramId,!0,void 0,{"aria-label":"Thumb to rotate the selected object"})},n.prototype.renderPathElement=function(t,e,i,r,s,o,a){var l=this.getBaseAttributes(t,i,o);if(l.data=t.absolutePath,l.data=t.absolutePath,t.isPathPort&&a){l.x=a[t.id]?a[t.id].cx:l.x,l.y=a[t.id]?a[t.id].cy:l.y,t.bounds.x=l.x,t.bounds.y=l.y;var h=document.getElementById(this.diagramId);h&&"PortDrag"!==h.ej2_instances[0].eventHandler.currentAction&&(t.offsetX=l.x+t.width/2,t.offsetY=l.y+t.height/2)}var u=t.description?t.description:t.id;if(this.isSvgMode||(l.x=t.flipOffset.x?t.flipOffset.x:l.x,l.y=t.flipOffset.y?t.flipOffset.y:l.y),t.isExport){var f=t.absoluteBounds,p=Ed(l.data),g=this.findAndStoreArcValues(p);l.arc=g,l.data=OF(t,f,0,l)}this.renderer.drawPath(e,l,this.diagramId,void 0,r,u)},n.prototype.findAndStoreArcValues=function(t){var e=[];return t.forEach(function(i){"A"===i.command&&e.push({r1:i.r1/2,r2:i.r2/2})}),e},n.prototype.renderSvgGridlines=function(t,e,i,r,s,o){var a=document.createElementNS("http://www.w3.org/2000/svg","pattern"),l=document.createElementNS("http://www.w3.org/2000/svg","defs");l.setAttribute("id",this.diagramId+"_grid_pattern_defn"),(t.constraints&Kt.ShowHorizontalLines||t.constraints&Kt.ShowVerticalLines)&&a.setAttribute("id",this.diagramId+"_pattern");var h=0,c=0,d=0,u=0,f=1,p=!1,g="Lines"===t.gridType,v=g?t.verticalGridlines.lineIntervals:t.verticalGridlines.dotIntervals,y=g?t.horizontalGridlines.lineIntervals:t.horizontalGridlines.dotIntervals;if(r.showRulers&&r.dynamicGrid&&s&&o)d=o.updateSegmentWidth(i.scale),u=s.updateSegmentWidth(i.scale),t.horizontalGridlines.scaledIntervals=[d/s.interval],t.verticalGridlines.scaledIntervals=[u/o.interval],p=!0;else{for(var S=0;S=2)for(;e>=2;)e/=2;else if(e<=.5)for(;e<=.5;)e*=2;var i;if(t.horizontalGridlines.scaledIntervals=t.horizontalGridlines.snapIntervals,t.verticalGridlines.scaledIntervals=t.verticalGridlines.snapIntervals,1!==e){var r=t.horizontalGridlines;for(r.scaledIntervals=[],i=0;ithis.groupElement.actualSize.height&&("Clip"===t.style.textOverflow||"Ellipsis"===t.style.textOverflow)&&(a.y=a.y+(a.height-this.groupElement.actualSize.height)/2),this.renderer.drawRectangle(e,a,this.diagramId,void 0,void 0,r),this.renderer.drawText(e,a,r,l,this.diagramId,t.isExport&&Math.min(t.exportScaleValue.x||t.exportScaleValue.y),this.groupElement),this.isSvgMode&&(t.doWrap=!1)},n.prototype.renderNativeElement=function(t,e,i,r,s){var o,a,l=this.getParentSvg(t,void 0,e)||r,h=this.getParentElement(t,e,l).g||e,c=this.getBaseAttributes(t,i);switch(c.fill="transparent",c.cornerRadius=t.cornerRadius,c.stroke="transparent",this.renderer.drawRectangle(e,c,this.diagramId,void 0,void 0,r),t.scale){case"None":o=t.contentSize.width,a=t.contentSize.height;break;case"Stretch":o=t.actualSize.width,a=t.actualSize.height;break;case"Meet":o=a=t.actualSize.width<=t.actualSize.height?t.actualSize.width:t.actualSize.height;break;case"Slice":o=a=t.actualSize.width>=t.actualSize.height?t.actualSize.width:t.actualSize.height}this.svgRenderer&&this.svgRenderer.drawNativeContent(t,h,a,o,l)},n.prototype.renderHTMLElement=function(t,e,i,r,s,o,a){var l=this.getBaseAttributes(t,r);l.fill="transparent",l.cornerRadius=t.cornerRadius,l.stroke="transparent",this.renderer.drawRectangle(e,l,this.diagramId,void 0,void 0,s),this.svgRenderer&&this.svgRenderer.drawHTMLContent(t,i.children[0],r,function lse(n){var t=n.parentElement;do{if(um(t,"e-diagram"))return!0;t=t.parentElement}while(t);return!1}(i),a)},n.prototype.renderImageElement=function(t,e,i,r,s){var o=this.getBaseAttributes(t,i);o.cornerRadius=0,this.renderer.drawRectangle(e,o,this.diagramId,void 0,void 0,r);var a,l,h,c,g,d=t.contentSize.width,u=t.contentSize.height,f=o.width/d,p=o.height/u;if("Stretch"===t.stretch)a=d*(g=Math.min(f,p)),l=u*g;else switch(t.stretch){case"Meet":a=d*(g=Math.min(f,p)),l=u*g,o.x+=Math.abs(o.width-a)/2,o.y+=Math.abs(o.height-l)/2;break;case"Slice":g=Math.max(f,p),h=o.width/(a=d*g)*d,c=o.height/(l=u*g)*u;break;case"None":a=d,l=u}o.width=a,o.height=l,o.sourceWidth=h,o.sourceHeight=c,o.source=t.source,o.alignment=t.imageAlign,o.scale=t.imageScale,o.description=t.description?t.description:t.id,this.renderer.drawImage(e,o,r,s)},n.prototype.renderContainer=function(t,e,i,r,s,o,a,l,h,c,d){var g,u={svg:s,g:e},f=document.getElementById(this.diagramId);if(f&&(g=f.ej2_instances[0]),this.diagramId&&(s=this.getParentSvg(t)||s,this.isSvgMode)){var v=this.getParentElement(t,e,s,l).g||e;s=this.getParentSvg(this.hasNativeParent(t.children))||s;var y=this.getParentElement(this.hasNativeParent(t.children),v,s,l);u.svg=y.svg||s,u.g=y.g||v,o&&s&&(s.getElementById(u.g.id)||e.appendChild(u.g)),e=u.g}if(this.renderRect(t,e,r,s),this.groupElement=t,t.hasChildren()){for(var b,S=void 0,M=0,w=t.children;M0&&(D=g.selectedItems.nodes[0]);var L,A=void 0,x=void 0,P=!1;if(g&&g.selectedItems&&(L=g.getObject(t.id)),"None"!==t.flip&&(D=L),"None"===t.flip&&(D=L),D&&D.flipMode&&(P=!0),!(t.elementActions&Xr.ElementIsGroup)&&g instanceof Fl&&g.nameTable[t.id]&&"connectors"!==g.nameTable[t.id].propName&&P&&D){if(A=t.children&&t.children[0]instanceof En?document.getElementById(D.id+"_content_inner_native_element"):document.getElementById(D.id+"_content_groupElement"),!(t.children[0]instanceof En)&&"Text"!==D.shape.type&&"None"!==D.flipMode&&"Label"!==D.flipMode&&"All"!==D.flipMode&&"PortAndLabel"!==D.flipMode&&"LabelText"!==D.flipMode&&"PortAndLabelText"!==D.flipMode&&"LabelAndLabelText"!==D.flipMode||t.children[0]instanceof En&&"Port"===D.flipMode)return void this.renderFlipElement(t,A,D.flip);if((t.children[0]instanceof En&&("All"===D.flipMode||"Label"===D.flipMode)||"Label"===D.flipMode||"PortAndLabel"===D.flipMode||"LabelText"===D.flipMode||"PortAndLabelText"===D.flipMode||"LabelAndLabelText"===D.flipMode||"Image"===D.shape.type&&"Label"===D.flipMode)&&this.renderFlipElement(t,A,t.flip),"None"!==t.flip&&"None"===D.flipMode)this.renderFlipElement(t,A,t.flip);else if("None"!==t.flip&&("Label"===D.flipMode||"PortAndLabel"===D.flipMode||"LabelText"===D.flipMode||"PortAndLabelText"===D.flipMode||"LabelAndLabelText"===D.flipMode)||t.children[0]instanceof En&&"None"!==t.flip&&D&&("None"===D.flipMode||"All"===D.flipMode)){for(var O=0;O0){var i=t[0];if(i instanceof En)return i;i.children&&i.children.length&&this.hasNativeParent(i.children,e++||0)}},n.prototype.renderRect=function(t,e,i,r,s){var o=this.getBaseAttributes(t,i,s);o.cornerRadius=t.cornerRadius||0,t.isExport&&(o.cornerRadius*=t.exportScaleValue.x),this.renderer.drawRectangle(e,o,this.diagramId,t.isExport,void 0,r,t.description?t.description:t.id)},n.prototype.drawRect=function(t,e){e.cornerRadius=0,this.svgRenderer.drawRectangle(t,e,this.diagramId)},n.prototype.getBaseAttributes=function(t,e,i){var r={width:t.actualSize.width,height:t.actualSize.height,x:t.offsetX-t.actualSize.width*t.pivot.x,y:t.offsetY-t.actualSize.height*t.pivot.y,fill:t.style.fill,stroke:t.style.strokeColor,angle:t.rotateAngle+t.parentTransform,pivotX:t.pivot.x,pivotY:t.pivot.y,strokeWidth:t.style.strokeWidth,dashArray:t.style.strokeDashArray||"",opacity:t.style.opacity,shadow:t.shadow,gradient:t.style.gradient,visible:t.visible,id:t.id,description:t.description,canApplyStyle:t.canApplyStyle,shapeType:t.shapeType};return"Page"===t.rotationReference&&(r.angle=t.rotateAngle),i&&(r.x=r.x-.5,r.y=r.y-.5),t.isExport&&(r.width*=t.exportScaleValue.x,r.height*=t.exportScaleValue.y,r.x*=t.exportScaleValue.x,r.y*=t.exportScaleValue.y,r.strokeWidth*=t.exportScaleValue.x),t.flip&&(r.flip=t.flip),e&&(r.x+=e.tx,r.y+=e.ty),r},n.renderSvgBackGroundImage=function(t,e,i,r,s,o){if(t.source){var l=mT(e.id).getElementById(e.id+"_image");if(!l){var h=function moe(n){return xt(n).getElementsByClassName("e-background-image-layer")[0]}(e.id);(l=document.createElementNS("http://www.w3.org/2000/svg","image")).setAttribute("id",e.id+"_image"),h.appendChild(l)}var c=new Image;c.src=t.source,l.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",c.src.toString());var d="None"!==t.scale?t.scale:"",u=t.align,f=u.charAt(0).toLowerCase()+u.slice(1);d&&(f+=" "+d.charAt(0).toLowerCase()+d.slice(1)),ti(l,{id:e.id+"_image",x:i,y:r,width:s,height:o,preserveAspectRatio:f})}},n.prototype.transformLayers=function(t,e){var i=t.tx*t.scale,r=t.ty*t.scale,s="domTable";if(i!==this.transform.x||r!==this.transform.y||0===i||0===r){e&&(window[""+s][this.diagramId+"_diagramLayer"]||(window[""+s][this.diagramId+"_diagramLayer"]=this.diagramSvgLayer.getElementById(this.diagramId+"_diagramLayer")),window[""+s][this.diagramId+"_diagramLayer"].setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+"),scale("+t.scale+")"));var a=function yoe(n){var t="domTable",e=null;return window[t][n+"_gridline"]?e=window[t][n+"_gridline"]:(e=Fd(n).getElementById(n+"_gridline"),window[t][n+"_gridline"]=e),e}(this.diagramId);return a.setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+")"),window[""+s][this.diagramId+"_diagramPorts"]||(window[""+s][this.diagramId+"_diagramPorts"]=this.iconSvgLayer.getElementById(this.diagramId+"_diagramPorts")),window[""+s][this.diagramId+"_diagramPorts"].setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+"),scale("+t.scale+")"),window[""+s][this.diagramId+"_diagramExpander"]||(window[""+s][this.diagramId+"_diagramExpander"]=this.iconSvgLayer.getElementById(this.diagramId+"_diagramExpander")),window[""+s][this.diagramId+"_diagramExpander"].setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+"),scale("+t.scale+")"),window[""+s][this.diagramId+"_nativeLayer"]||(window[""+s][this.diagramId+"_nativeLayer"]=this.nativeSvgLayer.getElementById(this.diagramId+"_nativeLayer")),window[""+s][this.diagramId+"_nativeLayer"].setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+"),scale("+t.scale+")"),Io(this.diagramId).children[0].style.transform="translate("+t.tx*t.scale+"px,"+t.ty*t.scale+"px)scale("+t.scale+")",this.transform={x:t.tx*t.scale,y:t.ty*t.scale},!0}return!1},n.prototype.updateNode=function(t,e,i,r,s,o,a){this.renderElement(t,e,i,r,this.getParentSvg(t),void 0,void 0,s,null,o,a)},n}(),tse=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),ZI=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},oF=function(n){function t(e,i){var r=n.call(this,e,i)||this;return r.mode="Canvas",r.id="overview",r.actionName="",r.startPoint=null,r.currentPoint=null,r.prevPoint=null,r.scale=null,r.inAction=!1,r.viewPortRatio=1,r.horizontalOffset=0,r.verticalOffset=0,r.model={},r.event=!0,r.overviewid=88123,r.model={width:r.width,height:r.height},r}return tse(t,n),t.prototype.onPropertyChanged=function(e,i){for(var r=0,s=Object.keys(e);r0||e.toString().indexOf("%")>0?e.toString():e.toString()+"px"},t.prototype.renderCanvas=function(e){var i=document.getElementById(this.element.id+"_canvas");i||(i=Tt("div",{}),this.element.appendChild(i)),Ho(i,{id:this.element.id+"_canvas",class:"drawing",style:"position:relative; height:"+this.getSizeValue(this.model.height)+"; width:"+this.getSizeValue(this.model.width)+";style:-ms-touch-action: none;touch-action: none;"}),this.element.setAttribute("tabindex",String(-1)),this.element.style.overflow="hidden",this.element.style.height=String(this.model.height),this.element.style.width=String(this.model.width),this.canvas=i},t.prototype.setParent=function(e){var i=document.getElementById(e);if(this.parent){var s=this.parent;this.parent=null,s.setOverview(null,this.element.id),this.removeDocument(this)}this.parent=this.getDiagram(i,"ej2_instances"),this.parent&&this.parent.setOverview(this)},t.prototype.getDiagram=function(e,i){for(var r,s=e[""+i].length,o=0;o0?f:Math.floor(window.innerWidth)}if(0===h){var p=Math.floor(window.innerHeight-u-Math.floor(c.top));h=p>0?p:Math.floor(window.innerHeight)}l>0&&(s.setAttribute("width",String(l)),this.model.height=h),h>0&&(s.setAttribute("height",String(h)),this.model.width=l),e.diagramLayerDiv||(e.diagramLayerDiv=Tt("div",{}),e.diagramLayer=bo.createCanvas(this.element.id+"_diagramLayer",this.model.width,this.model.height),e.diagramLayer.setAttribute("style","position:absolute; left:0px; top:0px "),e.diagramLayerDiv.appendChild(e.diagramLayer),e.canvas.appendChild(e.diagramLayerDiv)),Ho(e.diagramLayerDiv,{id:this.element.id+"_diagramLayer_div",style:"width:"+this.model.width+"px; height:"+this.model.height+"px;position:absolute;top:0px;left:0px"}),this.renderHtmlLayer(e.canvas),this.renderNativeLayer(e.canvas,e),this.addOverviewRectPanel(e)},t.prototype.removeDocument=function(e){var i=document.getElementById(this.canvas.id+"_svg");this.canvas.removeChild(i);var r=document.getElementById(this.element.id+"_htmlLayer");this.canvas.removeChild(r);var s=document.getElementById(this.element.id+"_diagramLayer_div");this.canvas.removeChild(s),e.diagramLayerDiv=null,e.diagramLayer=null,window.domTable[this.id+"html_layer"]=null},t.prototype.renderHtmlLayer=function(e){var i=Tt("div",{id:this.element.id+"_htmlLayer",class:"e-html-layer",style:"pointer-events:none;position:absolute;top:0px;left:0px;"}),s=Tt("div",{id:this.element.id+"_htmlLayer_div",style:"position:absolute;top:0px;left:0px;"});return i.appendChild(s),e.appendChild(i),i},t.prototype.renderNativeLayer=function(e,i){if(!document.getElementById(this.element.id+"_nativeLayer_svg")){var r=this.parent.createSvg(this.element.id+"_nativeLayer_svg",this.model.width,this.model.height),s=Fi("g",{id:this.element.id+"_nativeLayer"});r.appendChild(s),i.diagramLayerDiv.appendChild(r),ti(r,{class:"e-native-layer"})}},t.prototype.addOverviewRectPanel=function(e){var i=document.getElementById(this.canvas.id+"_overviewsvg");i&&i.parentNode.removeChild(i),i=Fi("svg",{id:this.canvas.id+"_overviewsvg",class:"overviewsvg",version:"1.1",style:"position:absolute;left:0px;top:0px; aria-label:Specifies overview",width:this.model.width,height:this.model.height}),e.canvas.appendChild(i);var s=Fi("g",{id:this.element.id+"_overviewlayer",style:"pointer-events:none"});i.appendChild(s);var o=Fi("rect",{fill:"transparent",width:"100%",height:"100%",class:"overviewbackrect",id:this.canvas.id+"overviewbackrect"});o.setAttribute("style"," pointer-events: none; "),s.appendChild(o);var a=Fi("g",{id:this.canvas.id+"overviewhandle",style:"pointer-events:all"});s.appendChild(a);var l=Fi("rect",{id:this.canvas.id+"overviewrect",fill:"transparent"});a.appendChild(l),this.renderOverviewCorner("left",a),this.renderOverviewCorner("right",a),this.renderOverviewCorner("top",a),this.renderOverviewCorner("bottom",a),this.renderOverviewCorner("topleft",a),this.renderOverviewCorner("topright",a),this.renderOverviewCorner("bottomleft",a),this.renderOverviewCorner("bottomright",a)},t.prototype.renderOverviewCorner=function(e,i){var s,o=Fi(s="top"===e||"bottom"===e||"right"===e||"left"===e?"rect":"circle",{id:this.canvas.id+"visible"+e,class:"overview-resizer"});i.appendChild(o);var a=Fi(s,{id:this.canvas.id+e,class:"overviewresizer",fill:"transparent"});i.appendChild(a)},t.prototype.updateOverviewRectangle=function(){var e=this.currentPoint.x-this.prevPoint.x,i=this.currentPoint.y-this.prevPoint.y,r=new me;r.width=0,r.height=0;var s=0,o=0;switch(this.resizeDirection){case"left":r.width-=e,r.height-=e/this.viewPortRatio,s=e,o=e/this.viewPortRatio,o/=2;break;case"right":r.width+=e,r.height+=e/this.viewPortRatio,o=e/this.viewPortRatio,o/=-2;break;case"top":r.height-=i,r.width-=i*this.viewPortRatio,o=i,s=i*this.viewPortRatio,s/=2;break;case"bottom":r.height+=i,r.width+=i*this.viewPortRatio,s=i*this.viewPortRatio,s/=-2;break;case"topleft":Math.abs(i)>Math.abs(e)?e=i*this.viewPortRatio:i=e/this.viewPortRatio,r.width-=e,r.height-=i,s=e,o=i;break;case"topright":Math.abs(i)>Math.abs(e)?e=-i*this.viewPortRatio:i=-e/this.viewPortRatio,o=i,r.width+=e,r.height-=i;break;case"bottomleft":Math.abs(i)>Math.abs(e)?e=-i*this.viewPortRatio:i=-e/this.viewPortRatio,s=e,r.width-=e,r.height+=i;break;case"bottomright":Math.abs(i)>Math.abs(e)?e=i*this.viewPortRatio:i=e/this.viewPortRatio,r.width+=e,r.height+=i}this.updateHelper(s,o,r,void 0,void 0)},t.prototype.updateHelper=function(e,i,r,s,o){var a,l,h,u,f,d=this.element.getElementsByTagName("svg")[2].getElementById("helper");r?(a=(h=d.getBBox()).x+e,l=h.y+i,s=h.width+r.width,o=h.height+r.height):(u=this.currentPoint.x>this.startPoint.x?this.currentPoint.x-this.prevPoint.x:this.prevPoint.x-this.currentPoint.x,f=this.currentPoint.y>this.startPoint.y?this.currentPoint.y-this.prevPoint.y:this.prevPoint.y-this.currentPoint.y,Math.abs(f)>Math.abs(u)?u=this.viewPortRatio*f:f=u/this.viewPortRatio,h=d.getBBox(),a=this.startPoint.x>this.currentPoint.x?h.x-u:h.x,l=this.startPoint.y>this.currentPoint.y?h.y-f:h.y,s=h.width+u,o=h.height+f),ti(this.helper,{id:this.helper.id,x:a,y:l,width:Math.max(0,s),height:Math.max(0,o)})},t.prototype.updateOverviewrect=function(e,i,r,s){Ho(document.getElementById(this.canvas.id+"overviewrect"),{x:e,y:i,width:Math.max(1,r),height:Math.max(1,s)}),this.updateOverviewCorner("top",e+8,i+1,Math.max(0,r-16),2),this.updateOverviewCorner("bottom",e+8,i+s+3,Math.max(0,r-16),2),this.updateOverviewCorner("left",e-2,i+11,2,Math.max(0,s-16)),this.updateOverviewCorner("right",e+r,i+11,2,Math.max(0,s-16)),this.updateOverviewCorner("topleft",e,i+3,5,5),this.updateOverviewCorner("topright",e+r,i+3,5,5),this.updateOverviewCorner("bottomleft",e,i+s+3,5,5),this.updateOverviewCorner("bottomright",e+r,i+s+3,5,5)},t.prototype.updateOverviewCorner=function(e,i,r,s,o){var a,l;"top"===e||"bottom"===e||"right"===e||"left"===e?(a={x:i,y:r,width:s,height:o,fill:"#ED1C24"},l={x:i-2,y:r-2,width:2===s?4:s,height:2===o?4:o}):(a={cx:i,cy:r,r:4,fill:"#ED1C24"},l={cx:i,cy:r,r:6,fill:"transparent"}),Ho(document.getElementById(this.canvas.id+"visible"+e),a),Ho(document.getElementById(this.canvas.id+e),l)},t.prototype.translateOverviewRectangle=function(){Number(this.model.width),Number(this.model.height);var r=this.currentPoint.x-this.prevPoint.x,s=this.currentPoint.y-this.prevPoint.y,l=this.element.getElementsByClassName("overviewsvg")[0].getElementById(this.canvas.id+"overviewrect").getBBox(),h=l.x+r,c=l.y+s,d=l.width,u=l.height;this.updateOverviewrect(h,c,d,u),this.updateParentView(this.parent.scroller.currentZoom,h,c,d,u,null)},t.prototype.renderOverviewRect=function(e,i,r,s){var o=Number(this.model.width),a=Number(this.model.height),c=Math.max(this.parent.scroller.viewPortWidth/(r/o*this.contentWidth),this.parent.scroller.viewPortHeight/(s/a*this.contentHeight));if(c>=.25&&c<=30){this.updateParentView(c,e,i,r,s,{x:0,y:0});var u=this.scrollOverviewRect(this.parent.scroller.horizontalOffset,this.parent.scroller.verticalOffset,this.parent.scroller.currentZoom,!0);if(this.helper){var p=this.element.getElementsByTagName("rect")[10].getBBox();u.x=p.x,u.y=p.y}"pan"===this.actionName?this.updateOverviewrect(-u.x,-u.y,u.width,u.height):this.updateOverviewrect(u.x,u.y,u.width,u.height)}},t.prototype.scrollOverviewRect=function(e,i,r,s){if(!this.actionName||s){var o=Number(this.model.width),a=Number(this.model.height),l=Math.min(this.contentWidth/o,this.contentHeight/a),h=new Ne,c=h.x=e/r/l,d=h.y=i/r/l,u=0;this.parent.rulerSettings.showRulers&&(u=25);var f=document.getElementById(this.parent.element.id+"content"),p=0,g=0;f&&(p=f.offsetWidth-f.clientWidth,g=f.offsetHeight-f.clientHeight);var v=h.width=(this.parent.scroller.viewPortWidth-u-p)/r/l,y=h.height=(this.parent.scroller.viewPortHeight-u-g)/r/l;if(s){var S=new Ne;return S.x=c,S.y=d,S.width=v,S.height=y,S}this.updateOverviewrect(-c,-d,v,y)}return null},t.prototype.updateParentView=function(e,i,r,s,o,a){var p,g,l=Number(this.model.width),h=Number(this.model.height),u=i*(this.contentWidth/l)*e,f=r*(this.contentHeight/h)*e;this.parent.scroller.getPageBounds(),(1!==e||"pan"===this.actionName)&&(p=-u-this.parent.scroller.horizontalOffset,g=-f-this.parent.scroller.verticalOffset),this.parent.setBlazorDiagramProps(!0),this.parent.realActions|=$i.OverViewAction,"scale"===this.actionName||"draw"===this.actionName?this.parent.scroller.zoom(e/this.parent.scroller.currentZoom,p,g,a):ce()?this.parent.scroller.zoom(1,p,g,a):this.parent.pan(p,g,a,!0)},t.prototype.updateHtmlLayer=function(e){var i=Io(e.element.id),r=this.parent.scroller.getPageBounds(!0),o=r.height,a=Math.max(r.width,this.parent.scroller.viewPortWidth),l=Math.max(o,this.parent.scroller.viewPortHeight/this.parent.scroller.currentZoom),h=Math.min(Number(this.model.width)/a,Number(this.model.height)/l);i.style.transform="scale("+h+") translate("+this.parent.scroller.transform.tx+"px,"+this.parent.scroller.transform.ty+"px)"},t.prototype.updateView=function(e){var i=this.parent.scroller.getPageBounds(),r=i.width,s=i.height,o=Number(this.model.width),a=Number(this.model.height),l=Math.max(r,this.parent.scroller.viewPortWidth),h=Math.max(s,this.parent.scroller.viewPortHeight);this.contentWidth=l=Math.max(l,o/a*h),this.contentHeight=h=Math.max(h,a/o*l);var c=Math.min(o/l,a/h),d=document.getElementById(this.element.id+"_htmlLayer");d.style.webkitTransform="scale("+c+") translate("+-i.x+"px,"+-i.y+"px)",d.style.transform="scale("+c+") translate("+-i.x+"px,"+-i.y+"px)",document.getElementById(this.element.id+"_overviewlayer").setAttribute("transform","translate("+-i.x*c+","+-i.y*c+")"),this.horizontalOffset=i.x*c,this.verticalOffset=i.y*c;var f=document.getElementById(this.element.id+"_diagramLayer"),p=zF(this.element.id),g=f.getContext("2d"),v=Number(this.model.width)/this.contentWidth,y=Number(this.model.height)/this.contentHeight;v=Math.min(v,y);var S=this.parent.scroller.transform;p.setAttribute("transform","translate("+S.tx*v+","+S.ty*y+"),scale("+v+")"),g.setTransform(v,0,0,v,0,0),g.fillStyle="red",this.scrollOverviewRect(this.parent.scroller.horizontalOffset,this.parent.scroller.verticalOffset,this.parent.scroller.currentZoom)},t.prototype.scrolled=function(e){if(this.event){var i=this.scrollOverviewRect(this.parent.scroller.horizontalOffset,this.parent.scroller.verticalOffset,this.parent.scroller.currentZoom,!0);this.updateOverviewrect(-i.x,-i.y,i.width,i.height),this.updateView(this)}},t.prototype.updateCursor=function(e){if(um(e.target,"overviewresizer"))switch(e.target.id){case this.canvas.id+"left":this.canvas.style.cursor="w-resize";break;case this.canvas.id+"right":this.canvas.style.cursor="e-resize";break;case this.canvas.id+"top":this.canvas.style.cursor="n-resize";break;case this.canvas.id+"bottom":this.canvas.style.cursor="s-resize";break;case this.canvas.id+"topleft":this.canvas.style.cursor="nw-resize";break;case this.canvas.id+"topright":this.canvas.style.cursor="ne-resize";break;case this.canvas.id+"bottomleft":this.canvas.style.cursor="sw-resize";break;case this.canvas.id+"bottomright":this.canvas.style.cursor="se-resize"}else this.canvas.style.cursor="default"},t.prototype.mouseMove=function(e){if(this.event=!1,this.updateCursor(e),this.currentPoint=this.mousePosition(e),this.actionName)switch(this.actionName){case"draw":!this.inAction&&(this.startPoint.x!==this.currentPoint.x||this.startPoint.y!==this.currentPoint.y)&&(this.initHelper(),this.inAction=!0),this.inAction&&this.updateHelper();break;case"scale":this.inAction||(this.initHelper(),this.inAction=!0),this.updateOverviewRectangle();break;case"pan":(this.startPoint.x!==this.currentPoint.x||this.startPoint.y===this.currentPoint.y||this.inAction)&&(this.inAction=!0,this.translateOverviewRectangle())}this.prevPoint=this.currentPoint},t.prototype.documentMouseUp=function(e){this.inAction=!1,this.actionName="",this.helper&&(this.helper.parentNode.removeChild(this.helper),this.helper=null),this.event=!0,document.getElementById(this.canvas.id+"overviewhandle").style.pointerEvents="all"},t.prototype.windowResize=function(e){var i=this;return this.resizeTo&&clearTimeout(this.resizeTo),this.resizeTo=setTimeout(function(){var s=document.getElementById(i.element.id).getBoundingClientRect();i.model.width=s.width>0?s.width:i.model.width,i.model.height=s.height>0?s.height:i.model.height,i.renderCanvas(),i.setParent(i.sourceID)},10),!1},t.prototype.mouseDown=function(e){if(e.target.id===this.canvas.id+"_overviewsvg"&&(this.actionName="draw"),e.target.id===this.canvas.id+"overviewrect"&&(this.actionName="pan"),um(e.target,"overviewresizer"))switch(this.actionName="scale",e.target.id){case this.canvas.id+"left":this.resizeDirection="left";break;case this.canvas.id+"right":this.resizeDirection="right";break;case this.canvas.id+"top":this.resizeDirection="top";break;case this.canvas.id+"bottom":this.resizeDirection="bottom";break;case this.canvas.id+"topleft":this.resizeDirection="topleft";break;case this.canvas.id+"topright":this.resizeDirection="topright";break;case this.canvas.id+"bottomleft":this.resizeDirection="bottomleft";break;case this.canvas.id+"bottomright":this.resizeDirection="bottomright"}this.startPoint=this.prevPoint=this.mousePosition(e),this.viewPortRatio=this.parent.scroller.viewPortWidth/this.parent.scroller.viewPortHeight,document.getElementById(this.canvas.id+"overviewhandle").style.pointerEvents="none"},t.prototype.mouseUp=function(e){if(this.currentPoint=this.mousePosition(e),this.actionName)if(this.startPoint.x!==this.currentPoint.x||this.startPoint.y!==this.currentPoint.y){if("pan"!==this.actionName&&this.helper){var i=this.element.getElementsByTagName("rect")[10].getBBox();this.resizeDirection=this.resizeDirection||"",this.renderOverviewRect(i.x,i.y,o=i.width,a=i.height)}}else if(e.target.id===this.canvas.id+"_overviewsvg"||"helper"===e.target.id){var o=(i=this.element.getElementsByTagName("svg")[2].getElementById(this.canvas.id+"overviewrect").getBBox()).width,a=i.height;this.inAction=!0,this.actionName="pan",this.renderOverviewRect(this.currentPoint.x-o/2,this.currentPoint.y-a/2,o,a),this.inAction=!1}this.helper&&(this.helper.parentNode.removeChild(this.helper),this.helper=null),this.actionName="",this.startPoint=null,this.currentPoint=null,this.prevPoint=null,this.helper=null,this.viewPortRatio=1,this.resizeDirection="",this.inAction=!1,this.event=!0,document.getElementById(this.canvas.id+"overviewhandle").style.pointerEvents="all"},t.prototype.initHelper=function(){var e=this.element.getElementsByTagName("svg")[2],i=this.startPoint.x,r=this.startPoint.y,s=1,o=1;if("scale"===this.actionName){var l=e.getElementById(this.canvas.id+"overviewrect").getBBox();i=l.x,r=l.y,s=l.width,o=l.height}var h=Fi("rect",{id:"helper",x:i,y:r,width:s,height:o,fill:"transparent",stroke:"gray","stroke-dasharray":"2 2","shape-rendering":"crispEdges"});e.getElementById(this.element.id+"_overviewlayer").appendChild(h),this.helper=h},t.prototype.mousePosition=function(e){var i,r,s;-1!==e.type.indexOf("touch")?(r=(i=e).changedTouches[0].clientX-this.element.offsetLeft,s=i.changedTouches[0].clientY-this.element.offsetTop):(r=e.clientX,s=e.clientY);var l=this.element.getBoundingClientRect();return{x:(r-=l.left)+this.horizontalOffset,y:(s-=l.top)+this.verticalOffset}},t.prototype.destroy=function(){if(this.unWireEvents(),this.notify("destroy",{}),n.prototype.destroy.call(this),document.getElementById(this.element.id)){this.element.classList.remove("e-overview");var e=document.getElementById(this.element.id+"_canvas");e&&this.element.removeChild(e)}this.parent.views.splice(this.parent.views.indexOf(this.element.id),1),this.diagramLayerDiv=null,this.canvas=null,this.parent=null},t.prototype.getModuleName=function(){return"Overview"},ZI([I("100%")],t.prototype,"width",void 0),ZI([I("100%")],t.prototype,"height",void 0),ZI([I("")],t.prototype,"sourceID",void 0),ZI([H()],t.prototype,"created",void 0),t}(Ii);function rse(n,t){for(var e=0;eR.findLength(e,n)?e:t;var o=R.findAngle(t,e),a=R.findAngle(i,n),l=R.findLength(i,n),h=a+2*(o-a);return{x:i.x+l*Math.cos(h*Math.PI/180),y:i.y+l*Math.sin(h*Math.PI/180)}}function Zf(n,t,e){if(n&&n.children&&n.children.length>0)for(var r=void 0,s=0;s0&&"annotations"!==r&&"ports"!==r)if(n[""+l].length>0)for(var h=0;h<=n[""+l].length;h++)Ro(n[""+l],t?t[""+l]:void 0,e[""+l],"annotations"===l||"ports"===l?n:void 0,l);else Ro(n[""+l],t?t[""+l]:void 0,e[""+l],"annotations"===l||"ports"===l?n:void 0,l);else if(s instanceof Object&&t&&"annotations"!==r&&"ports"!==r)Ro(n[""+l],t[""+l],e[""+l]);else if("annotations"!==r&&"ports"!==r&&t&&!t[""+l]||!t&&n&&(n[""+l]||void 0!==n[""+l]))n[""+l]=e[""+l];else{var c=void 0;("annotations"===r||"ports"===r)&&("annotations"===r?(n[""+l]&&Ro(n[""+l],t[""+l],e[""+l]),n[""+l]||(ps(i)===de?(c=new Or(i,"annotations",e[""+l]),i.annotations.push(c)):(c=new Kn(i,"annotations",e[""+l]),i.annotations.push(c)))):n[""+l]?Ro(n[""+l],t[""+l],e[""+l]):(c=new Es(i,"ports",e[""+l]),i.ports.push(c)))}}}function cse(n,t){for(var e="Bezier"===n.type?function ase(n){var t=[];if("Bezier"===n.type)for(var e=0,i=0;i0||n.ports.length>0){var f=n.wrapper.children;for(i=3;i0)return{enabled:!1,intersectPt:e};var l=o/s,h=a/s;return l>=0&&l<=1&&h>=0&&h<=1?(e.x=i.x1+l*(i.x2-i.x1),e.y=i.y1+l*(i.y2-i.y1),{enabled:!0,intersectPt:e}):{enabled:!1,intersectPt:e}}function KI(n,t,e,i){var a=tm(cF(n.x,n.y,t.x,t.y),cF(e.x,e.y,i.x,i.y));return a.enabled?a.intersectPt:{x:0,y:0}}function cF(n,t,e,i){return{x1:Number(n)||0,y1:Number(t)||0,x2:Number(e)||0,y2:Number(i)||0}}function dF(n,t,e){var i=[],s={x:t.topRight.x+(e=e||0),y:t.topRight.y},o={x:t.bottomRight.x,y:t.bottomRight.y-e},a={x:t.bottomLeft.x,y:t.bottomLeft.y+e};return i.push({x:t.topLeft.x-e,y:t.topLeft.y}),i.push(s),i.push(o),i.push(a),i}function zc(n,t,e,i,r,s){var o={},a=e.scroller.transform.scale,h=e.scroller.verticalOffset;return o.x=(i?n.x:t.x)*a+e.scroller.horizontalOffset-r,o.y=(i?n.y:t.y)*a+h-s,o}function uF(n,t){var e=new Ze;return e.data=n.pathData,e.height=n.height>10?n.height-(n.padding.bottom+n.padding.top):n.height,e.width=n.width>10?n.width-(n.padding.left+n.padding.right):n.width,e.visible=n.visibility,e.id=t.id+"_shape",e.inversedAlignment=!1,e.horizontalAlignment="Center",e.verticalAlignment="Center",e.style={fill:n.iconStrokeColor,strokeColor:n.iconStrokeColor,strokeWidth:n.iconStrokeWidth},e.setOffsetWithRespectToBounds(.5,.5,"Fraction"),e.relativeMode="Object",e.description=t.description||"",e}function Xx(n,t,e){var i=qx(n,t),r=R.findAngle(n[i.index],n[i.index+1]),s=function mse(n){var t;t=n instanceof xI?0:void 0===n.content?10:0;var e=0;switch(n.alignment){case"Center":e=0;break;case"Before":e=-(0+t);break;case"After":e=0+t}return e}(t),o=R.transform(i.point,r+45,s);return i.point=o,i.angle=r,i}function qx(n,t){for(var r,s,a,l,e=0,i=t.offset,o=[],h=0;h=c)return s=R.findAngle(n[parseInt(d.toString(),10)],n[d+1]),{point:r=R.transform(n[parseInt(d.toString(),10)],s,c-(a||0)),index:l=d};a=o[parseInt(d.toString(),10)]}return{point:r,index:l}}function fF(n,t,e){t%=360;var a,l,s=225;switch(n.alignment){case"Before":t>=45&&t<=135?(l="right",a=.5===n.offset?"center":"top"):t>=s&&t<=315?(l="left",a=.5===n.offset?"center":"bottom"):t>45&&t=45&&t<=135?(l="left",a=.5===n.offset?"center":"top"):t>=s&&t<=315?(l="right",a=.5===n.offset?"center":"bottom"):t>45&&tMath.abs(t.y-n.y)?n.x0)for(var e=0;e=0;r--)("nodes"===i||"connectors"===i)&&(n[""+i][parseInt(r.toString(),10)].wrapper=null),"dataManager"!==i&&(n[""+i][parseInt(r.toString(),10)]=Jx(n[""+i][parseInt(r.toString(),10)],e[""+i][parseInt(r.toString(),10)],void 0!==t[""+i]?t[""+i][parseInt(r.toString(),10)]:[]),("[]"===JSON.stringify(n[""+i][parseInt(r.toString(),10)])||"{}"===JSON.stringify(n[""+i][parseInt(r.toString(),10)])||void 0===n[""+i][parseInt(r.toString(),10)])&&n[""+i].splice(r,1));n=void 0}function zh(n,t){var e=t.style,i=t;t.canApplyStyle=!0;for(var r=0,s=Object.keys(n);r=0&&n.splice(e,1)}function Jf(n,t,e){var i;n.intermediatePoints=t,n.updateSegmentElement(n,t,n.wrapper.children[0],e);var r=n.sourceDecorator;if("Bezier"===n.type){var s=n.segments[0],o=n.segments[n.segments.length-1];i=[R.isEmptyPoint(o.point2)?o.bezierPoint2:o.point2,R.isEmptyPoint(s.point1)?s.bezierPoint1:s.point1]}else i=n.intermediatePoints;t=n.clipDecorators(n,t,e);var a=n.wrapper.children[0];a.canMeasurePath=!0,n.updateDecoratorElement(a=n.wrapper.children[1],t[0],i[1],r),n.updateDecoratorElement(a=n.wrapper.children[2],t[t.length-1],i[i.length-2],n.targetDecorator),n.updateShapeElement(n)}function Kx(n,t,e){var l,i=n.wrapper,s=t.offset,o=t.size/e.scale,a=t.margin,h=i.offsetX-i.actualSize.width*i.pivot.x,c=i.offsetY-i.actualSize.height*i.pivot.y;if(l={x:0,y:0},n.nodes.length>0){switch(t.side){case"Top":l.x+=h+s*i.actualSize.width,l.y+=c-o;break;case"Bottom":l.x+=h+s*i.actualSize.width,l.y+=c+i.actualSize.height+o;break;case"Left":l.x+=h-o,l.y+=c+s*i.actualSize.height;break;case"Right":l.x+=h+i.actualSize.width+o,l.y+=c+s*i.actualSize.height}l.x+=(a.left-a.right)/e.scale+o/2*("Center"===t.horizontalAlignment?0:"Right"===t.horizontalAlignment?-1:1),l.y+=(a.top-a.bottom)/e.scale+o/2*("Center"===t.verticalAlignment?0:"Top"===t.verticalAlignment?-1:1)}else if(n.connectors.length>0){var d=n.connectors[0],u={offset:s},f=qx(d.intermediatePoints,u),p=f.index;l=f.point;var y,v=Xx(d.intermediatePoints,u).angle;qi(y=Bi(),-v,d.intermediatePoints[parseInt(p.toString(),10)].x,d.intermediatePoints[parseInt(p.toString(),10)].y),(l=Ke(y,l)).x+=a.left-a.right+o/2*("Center"===t.horizontalAlignment?0:"Right"===t.horizontalAlignment?-1:1),l.y+=a.top-a.bottom+o/2*("Center"===t.verticalAlignment?0:"Top"===t.verticalAlignment?-1:1),qi(y=Bi(),v,d.intermediatePoints[parseInt(p.toString(),10)].x,d.intermediatePoints[parseInt(p.toString(),10)].y),l=Ke(y,l)}return 0===i.rotateAngle&&0===i.parentTransform||(qi(y=Bi(),i.rotateAngle+i.parentTransform,i.offsetX,i.offsetY),l=Ke(y,l)),l}function ga(n,t,e,i){if(i.annotation){if(Pl(i.annotation))return!0}else if(mr[""+t]&n&&bt[""+t]&e)return!0;return!1}function qr(n,t){return!!(mr[""+t]&n)}function Hc(n,t){return!!(bx[""+t]&n)}function va(n,t){return n.visibility&t}function eb(n,t){var e;if("Text"===n.shape.type)e=n.shape;else{var i=t.split("_");t=i[i.length-1];for(var r=0;rn[""+t]?e.splice(0,0,n):e.push(n);else if(e.length>1){for(var i=0,r=e.length-1,s=Math.floor((i+r)/2);s!==i;)if(e[parseInt(s.toString(),10)][""+t]n[""+t]))break;r=s,s=Math.floor((i+r)/2)}e[parseInt(r.toString(),10)][""+t]n[""+t]?e.splice(i,0,n):e[parseInt(i.toString(),10)][""+t]n[""+t]&&e.splice(r,0,n)}}function zse(n){var t=document.getElementById(n.diagramId),e="ej2_instances",i=t[""+e][0].nodes;void 0===i&&(i=function Rse(n){for(var t=[],e=0;e30?10:o/2;for(var h=0,c=0;c=l){var u=l-h;r=Gt(n[c],n[c+1]),s=R.transform(n[c],r,u);break}h+=d}return s},rb=function(n,t){if(n instanceof te||n instanceof de)for(var e=0;e=0||navigator.platform.indexOf("iPad")>=0||navigator.platform.indexOf("iPhone")>=0||navigator.platform.indexOf("MacIntel")>=0)&&("safari"===X.info.name||"webkit"===X.info.name)}function wF(n,t,e,i){return void 0!==t.previewSize[""+i]?t.previewSize[""+i]:void 0!==n.symbolPreview[""+i]?n.symbolPreview[""+i]:t[""+i]||e.actualSize[""+i]}function om(n,t,e){return n&&n.parentId&&(e=(n=t.nameTable[n.parentId]).parentId?om(n,t,e):n.id),e}function am(n,t){return n.selectedItems.connectors.length>1&&0===n.selectedItems.nodes.length&&0!==t.rotateAngle}function _se(n){if(n.arrowType&&""!==n.arrowType.trim())switch(n.arrowType){case"single-line-arrow":default:return{targetDecorator:"Arrow",strokeWidth:1};case"double-line-arrow":return{targetDecorator:"Arrow",strokeWidth:2};case"dotted-arrow":return{targetDecorator:"Arrow",strokeDashArray:"2,2"};case"single-line":return{targetDecorator:"None",strokeWidth:1};case"double-line":return{targetDecorator:"None",strokeWidth:2};case"dotted":return{targetDecorator:"None",strokeDashArray:"2,2"};case"wiggly-arrow":return{targetDecorator:"None",strokeWidth:1,opacity:0}}return{targetDecorator:"Arrow",strokeWidth:1}}var Use=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),no=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},CF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Use(t,n),no([I("None")],t.prototype,"shape",void 0),no([I("white")],t.prototype,"fill",void 0),no([I("Auto")],t.prototype,"horizontalAlignment",void 0),no([I("Auto")],t.prototype,"verticalAlignment",void 0),no([I(10)],t.prototype,"width",void 0),no([I(10)],t.prototype,"height",void 0),no([re({x:.5,y:1},R)],t.prototype,"offset",void 0),no([I("#1a1a1a")],t.prototype,"borderColor",void 0),no([I(1)],t.prototype,"borderWidth",void 0),no([re({},Jn)],t.prototype,"margin",void 0),no([I("")],t.prototype,"pathData",void 0),no([I("")],t.prototype,"content",void 0),no([I(0)],t.prototype,"cornerRadius",void 0),no([re({left:2,right:2,top:2,bottom:2},Jn)],t.prototype,"padding",void 0),no([I("#1a1a1a")],t.prototype,"iconColor",void 0),t}(Ee),jse=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),rT=function(n){function t(){var e=null!==n&&n.apply(this,arguments)||this;return e.orientation="Vertical",e.measureChildren=void 0,e.considerPadding=!0,e}return jse(t,n),t.prototype.measure=function(e){return this.desiredSize=this.measureStackPanel(e,"Horizontal"===this.orientation?this.updateHorizontalStack:this.updateVerticalStack),this.desiredSize},t.prototype.arrange=function(e){return this.actualSize=this.arrangeStackPanel(e,"Horizontal"===this.orientation?this.arrangeHorizontalStack:this.arrangeVerticalStack),this.updateBounds(),this.actualSize},t.prototype.measureStackPanel=function(e,i){var r=void 0;if(void 0!==this.children&&this.children.length>0)for(var s=0,o=this.children;s0){var r=void 0,s=void 0;r=this.offsetX-e.width*this.pivot.x+this.padding.left,s=this.offsetY-e.height*this.pivot.y+this.padding.top;for(var o=0,a=this.children;o0)for(var i=0,r=this.children;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},$se=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return qse(t,n),Rh([I("Horizontal")],t.prototype,"orientation",void 0),Rh([I("Center")],t.prototype,"type",void 0),Rh([I(void 0)],t.prototype,"offset",void 0),Rh([I(!1)],t.prototype,"enableRouting",void 0),Rh([I([])],t.prototype,"children",void 0),Rh([I("")],t.prototype,"assistants",void 0),Rh([I("")],t.prototype,"level",void 0),Rh([I("")],t.prototype,"hasSubTree",void 0),Rh([I("")],t.prototype,"rows",void 0),t}(Ee),Ni=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),q=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Zse=function(n){if(n)switch(n.type){case"Basic":default:return nb;case"Flow":return TF;case"Path":return EF;case"Image":return xF;case"Text":return zd;case"Bpmn":return hT;case"Native":return lm;case"HTML":return DF;case"UmlActivity":return AF;case"UmlClassifier":return LF;case"SwimLane":return Bd}return nb},ma=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),q([I("Basic")],t.prototype,"type",void 0),t}(Ee),EF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"Path"},q([I("Path")],t.prototype,"type",void 0),q([I("")],t.prototype,"data",void 0),t}(ma),lm=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"Native"},q([I("Native")],t.prototype,"type",void 0),q([I("")],t.prototype,"content",void 0),q([I("Stretch")],t.prototype,"scale",void 0),t}(ma),DF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"Html"},q([I("HTML")],t.prototype,"type",void 0),q([I("")],t.prototype,"content",void 0),t}(ma),xF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"Image"},q([I("Image")],t.prototype,"type",void 0),q([I("")],t.prototype,"source",void 0),q([I("None")],t.prototype,"scale",void 0),q([I("None")],t.prototype,"align",void 0),t}(ma),zd=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"Text"},q([I("Text")],t.prototype,"type",void 0),q([I("")],t.prototype,"content",void 0),q([re({},Jn)],t.prototype,"margin",void 0),t}(ma),nb=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"BasicShape"},q([I("Basic")],t.prototype,"type",void 0),q([I("Rectangle")],t.prototype,"shape",void 0),q([I(0)],t.prototype,"cornerRadius",void 0),q([Bt([],R)],t.prototype,"points",void 0),t}(ma),TF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"FlowShape"},q([I("Flow")],t.prototype,"type",void 0),q([I("Terminator")],t.prototype,"shape",void 0),t}(ma),sT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"BpmnGateway"},q([I("None")],t.prototype,"type",void 0),t}(Ee),oT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"BpmnDataObject"},q([I("None")],t.prototype,"type",void 0),q([I(!1)],t.prototype,"collection",void 0),t}(Ee),Jse=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),q([I("None")],t.prototype,"type",void 0),q([I("None")],t.prototype,"loop",void 0),q([I(!1)],t.prototype,"call",void 0),q([I(!1)],t.prototype,"compensation",void 0),t}(Ee),aT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"BpmnEvent"},q([I("Start")],t.prototype,"event",void 0),q([I("None")],t.prototype,"trigger",void 0),t}(Ee),Rd=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"BpmnSubEvent"},q([I("None")],t.prototype,"trigger",void 0),q([I("Start")],t.prototype,"event",void 0),q([I("")],t.prototype,"id",void 0),q([re({},R)],t.prototype,"offset",void 0),q([Bt([],Kn)],t.prototype,"annotations",void 0),q([Bt([],Es)],t.prototype,"ports",void 0),q([I()],t.prototype,"width",void 0),q([I()],t.prototype,"height",void 0),q([re({},Jn)],t.prototype,"margin",void 0),q([I("Center")],t.prototype,"horizontalAlignment",void 0),q([I("Center")],t.prototype,"verticalAlignment",void 0),q([I(!0)],t.prototype,"visible",void 0),t}(Ee),Kse=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),q([re({id:"success",event:"End",offset:{x:1,y:.5}},Rd)],t.prototype,"success",void 0),q([re({id:"failure",event:"Intermediate",trigger:"Error",offset:{x:.25,y:1}},Rd)],t.prototype,"failure",void 0),q([re({id:"cancel",event:"Intermediate",trigger:"Cancel",offset:{x:.75,y:1}},Rd)],t.prototype,"cancel",void 0),t}(Ee),eoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),q([I("None")],t.prototype,"type",void 0),q([I(!1)],t.prototype,"adhoc",void 0),q([I("Default")],t.prototype,"boundary",void 0),q([I(!1)],t.prototype,"compensation",void 0),q([I("None")],t.prototype,"loop",void 0),q([I(!0)],t.prototype,"collapsed",void 0),q([Bt([],Rd)],t.prototype,"events",void 0),q([re({},Kse)],t.prototype,"transaction",void 0),q([I(void 0)],t.prototype,"processes",void 0),t}(Ee),lT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"BpmnActivity"},q([I("Task")],t.prototype,"activity",void 0),q([re({},Jse)],t.prototype,"task",void 0),q([re({},eoe)],t.prototype,"subProcess",void 0),t}(Ee),hm=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return Ni(t,n),t.prototype.getClassName=function(){return"BpmnAnnotation"},q([I("")],t.prototype,"text",void 0),q([I("")],t.prototype,"id",void 0),q([I(0)],t.prototype,"angle",void 0),q([I()],t.prototype,"height",void 0),q([I()],t.prototype,"width",void 0),q([I(0)],t.prototype,"length",void 0),t}(Ee),toe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),q([I("")],t.prototype,"textAnnotationTarget",void 0),q([I("Auto")],t.prototype,"textAnnotationDirection",void 0),t}(Ee),hT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"BpmnShape"},q([I("Bpmn")],t.prototype,"type",void 0),q([I("Event")],t.prototype,"shape",void 0),q([re({},aT)],t.prototype,"event",void 0),q([re({},sT)],t.prototype,"gateway",void 0),q([re({},oT)],t.prototype,"dataObject",void 0),q([re({},lT)],t.prototype,"activity",void 0),q([re({},hm)],t.prototype,"annotation",void 0),q([Bt([],hm)],t.prototype,"annotations",void 0),q([re({},toe)],t.prototype,"textAnnotation",void 0),t}(ma),AF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"UmlActivityShape"},q([I("UmlActivity")],t.prototype,"type",void 0),q([I("Action")],t.prototype,"shape",void 0),t}(ma),cT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"MethodArguments"},q([I("")],t.prototype,"name",void 0),q([I("")],t.prototype,"type",void 0),q([re({},Qf)],t.prototype,"style",void 0),t}(Ee),rp=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"UmlClassAttribute"},q([I("Public")],t.prototype,"scope",void 0),q([I(!1)],t.prototype,"isSeparator",void 0),q([re({fill:"#F9F9F9",strokeColor:"#CCCCCC"},Ll)],t.prototype,"separatorStyle",void 0),t}(cT),cm=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"UmlClassMethod"},q([Bt([],cT)],t.prototype,"parameters",void 0),t}(rp),sb=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"UmlClass"},q([I("")],t.prototype,"name",void 0),q([Bt([],rp)],t.prototype,"attributes",void 0),q([Bt([],cm)],t.prototype,"methods",void 0),q([re({},Qf)],t.prototype,"style",void 0),t}(Ee),dT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"UmlInterface"},q([I(!1)],t.prototype,"isSeparator",void 0),q([re({fill:"#F9F9F9",strokeColor:"#CCCCCC"},Ll)],t.prototype,"separatorStyle",void 0),t}(sb),ob=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"UmlEnumerationMember"},q([I("")],t.prototype,"name",void 0),q([I("")],t.prototype,"value",void 0),q([I(!1)],t.prototype,"isSeparator",void 0),q([re({fill:"#F9F9F9",strokeColor:"#CCCCCC"},Ll)],t.prototype,"separatorStyle",void 0),q([re({},Qf)],t.prototype,"style",void 0),t}(Ee),uT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"UmlEnumeration"},q([I("")],t.prototype,"name",void 0),q([Bt([],ob)],t.prototype,"members",void 0),q([re({},Qf)],t.prototype,"style",void 0),t}(Ee),LF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"UmlClassifierShape"},q([I("UmlClassifier")],t.prototype,"type",void 0),q([re({},sb)],t.prototype,"classShape",void 0),q([re({},dT)],t.prototype,"interfaceShape",void 0),q([re({},uT)],t.prototype,"enumerationShape",void 0),q([I("Class")],t.prototype,"classifier",void 0),t}(ma),te=function(n){function t(e,i,r,s){var a,o=n.call(this,e,i,r,s)||this;return o.isCanvasUpdate=!1,o.status="None",o.parentId="",o.processId="",o.umlIndex=-1,o.outEdges=[],o.inEdges=[],o.isHeader=!1,o.isLane=!1,o.isPhase=!1,o.children&&o.children.length>0&&((!(a=r).style||!a.style.fill)&&(o.style.fill="transparent"),(!a.style||!a.style.strokeColor)&&(o.style.strokeColor="transparent")),o.shape&&"UmlActivity"===o.shape.type&&JI(r,o),o.shape&&"SwimLane"===o.shape.type&&aF(r,o),o.ports&&o.ports.length&&function sse(n){for(var t=0;t>";t=n;break;case"FinalNode":t=pF(e)}return t}(new Ze,i,this);break;case"Bpmn":if(e.bpmnModule){i=e.bpmnModule.initBPMNContent(i,this,e),this.wrapper.elementActions=this.wrapper.elementActions|Xr.ElementIsGroup;var v=this.shape.activity.subProcess;if(v.processes&&v.processes.length)for(var S=0,b=this.shape.activity.subProcess.processes;S>",margin:{left:10,right:10},id:"class",style:{fontSize:i.style.fontSize,color:i.style.color,fill:i.style.fill,textWrapping:r},offset:{x:.5,y:.3},constraints:Nr.ReadOnly}],constraints:(ie.Default|ie.HideThumbs)&~(ie.Rotate|ie.Drag|ie.Resize),verticalAlignment:"Stretch",horizontalAlignment:"Stretch",style:{fill:t.style.fill,strokeColor:"black"===t.style.strokeColor?"#ffffff00":t.style.strokeColor}},!0);return e.initObject(s),e.nodes.push(s),e.UpdateBlazorDiagramModel(s,"Node"),t.children.push(s.id),function Wse(n,t,e,i){if("Enumeration"===n.shape.classifier){var r=e.members;if(r&&r.length){tp(n,t);for(var s="",o=0;o0)for(var o=0;o0&&s.phaseSize&&(i+=s.phaseSize,Gv(n,s.phaseSize)),s.lanes.length>0)for(o=0;o0){var a=0;for(o=0;o0&&"Horizontal"===r.orientation)for(l=0;l0&&(i+=r.phaseSize,o=Xv(r.phaseSize),n.push(o)),a=0;a0&&o.phaseSize){for(var l=0;l0)for(l=0;l0?e.nameTable[this.nodes[0].id].wrapper:e.nameTable[this.connectors[0].id].wrapper,this.annotation.id);i.children.push(s)}else if(this.nodes||this.connectors){for(var o=0;o-1}function HF(n,t,e){n=[];for(var i=0,r=e.length;i0?c.getElementsByTagName("svg")[0].outerHTML:c.getElementsByTagName("g").length>0?c.getElementsByTagName("g")[0].outerHTML:"",s.shape.content=h,n.content=h,c.parentElement.removeChild(c)}l="nodeTemplate"}else a=s,l="annotationTemplate";var p=document.getElementById(n.diagramId).ej2_instances[0];if("string"!=typeof n.content&&"function"!=typeof n.content||n.isTemplate)if(n.isTemplate){if(v=void 0,v=p.isReact?n.getNodeTemplate()($(e),p,l+"_"+("nodeTemplate"===l?e.id:n.nodeId+e.id),void 0,void 0,!1,i):p.isVue||p.isVue3?n.getNodeTemplate()?n.getNodeTemplate()($(e),p,l+"_"+("nodeTemplate"===l?e.id:n.nodeId+e.id),void 0,void 0,!1,i):(v=si("nodeTemplate"===l?p.nodeTemplate:p.annotationTemplate))($(e),p,l+"_"+("nodeTemplate"===l?e.id:n.nodeId+e.id),void 0,void 0,!1,i):n.getNodeTemplate()($(e),p,l+"_"+("nodeTemplate"===l?e.id:n.nodeId+e.id),void 0,void 0,!1))for(var M=0;M=1&&0===n.x&&("Clip"===i.textOverflow||"Ellipsis"===i.textOverflow)&&("Wrap"===i.textWrapping||"WrapWithOverflow"===i.textWrapping)&&(n.x=t[e-1]?t[e-1].x:-n.width/2),n.x}function _F(n,t,e,i){return e&&!t.template||t.template&&"function"==typeof t.template&&i.isReact?(n.isTemplate=!0,n.template=n.content=Hh(n,!0,t)):n.content=t.template,n}function Qe(){for(var e,t="",i=0;i<5;i++){if(typeof window<"u"&&"crypto"in window&&"getRandomValues"in crypto){var r=new Uint16Array(1);e=(window.msCrypto||window.crypto).getRandomValues(r)[0]%60}else e=Math.floor(61*Math.random());0===i&&e<10?i--:t+="0123456789ABCDEFGHIJKLMNOPQRSTUVWXTZabcdefghiklmnopqrstuvwxyz".substring(e,e+1)}return t}function UF(n){if(n)try{return"function"!=typeof n&&document.querySelectorAll(n).length?si(document.querySelector(n).innerHTML.trim()):si(n)}catch{return si(n)}}function xn(n){new Ne;var e=n.offsetY-n.actualSize.height*n.pivot.y,i=n.offsetY+n.actualSize.height*(1-n.pivot.y),r=n.offsetX-n.actualSize.width*n.pivot.x,s=n.offsetX+n.actualSize.width*(1-n.pivot.x);return Ne.toBounds([{x:r,y:e},{x:s,y:e},{x:r,y:i},{x:s,y:i}])}function yr(n){var t=new Ne,e=xn(n),i=e.middleLeft,r=e.topCenter,s=e.bottomCenter,o=e.middleRight,a=e.topLeft,l=e.topRight,h=e.bottomLeft,c=e.bottomRight;if(n.corners={topLeft:a,topCenter:r,topRight:l,middleLeft:i,middleRight:o,bottomLeft:h,bottomCenter:s,bottomRight:c},0!==n.rotateAngle||0!==n.parentTransform){var d=Bi();qi(d,n.rotateAngle+n.parentTransform,n.offsetX,n.offsetY),n.corners.topLeft=a=Ke(d,a),n.corners.topCenter=r=Ke(d,r),n.corners.topRight=l=Ke(d,l),n.corners.middleLeft=i=Ke(d,i),n.corners.middleRight=o=Ke(d,o),n.corners.bottomLeft=h=Ke(d,h),n.corners.bottomCenter=s=Ke(d,s),n.corners.bottomRight=c=Ke(d,c)}return t=Ne.toBounds([a,l,h,c]),n.corners.left=t.left,n.corners.right=t.right,n.corners.top=t.top,n.corners.bottom=t.bottom,n.corners.center=t.center,n.corners.width=t.width,n.corners.height=t.height,t}function $(n,t,e,i){var r={},s="properties";if(n){e=n.propName;var l=[],h=[];if((l=l.concat(Object.keys(n[""+s]||n))).push("version"),e){var c=Zi(t);h=c?c(e):[],l=l.concat(h)}for(var d=function boe(n){switch(n){case"nodes":case"children":return["inEdges","outEdges","parentId","processId","nodeId","umlIndex","isPhase","isLane"];case"connectors":return["parentId"];case"annotation":case"annotations":return["nodeId"];case"shape":return["hasHeader"];case"layers":return["objectZIndex"]}return[]}(e),u=0,f=l=l.concat(d);u0&&(e=r),r=Math.floor(woe(e,i)),s=Bc(o+=n.substr(e,r),t)}while(s<=t.width);for(o=o.substr(0,e),a=e;a=t.width){n=n.substr(0,o.length-1);break}return"Ellipsis"===t.textOverflow?(n=n.substr(0,n.length-3),n+="..."):n=n.substr(0,n.length),n}function ST(n,t){if("NoWrap"===t&&"PreserveAll"===n)return"pre";var e="";switch(n){case"CollapseAll":e="nowrap";break;case"CollapseSpace":e="pre-line";break;case"PreserveAll":e="pre-wrap"}return e}function IT(n,t){var e=Bi();qi(e,t,0,0);var i=Ke(e,{x:0,y:0}),r=Ke(e,{x:n.width,y:0}),s=Ke(e,{x:0,y:n.height}),o=Ke(e,{x:n.width,y:n.height}),a=Math.min(i.x,r.x,s.x,o.x),l=Math.min(i.y,r.y,s.y,o.y),h=Math.max(i.x,r.x,s.x,o.x),c=Math.max(i.y,r.y,s.y,o.y);return new me(h-a,c-l)}function xs(n,t,e,i){if(0!==n){var r=Bi();return qi(r,n,t,e),Ke(r,i)}return i}function Zi(n){return void 0!==n&&"string"==typeof n&&(n=Y(n,window)),n}var bo=function(){function n(){}return n.getContext=function(t){return t.getContext("2d")},n.setCanvasSize=function(t,e,i){t&&(t.setAttribute("width",e.toString()),t.setAttribute("height",i.toString()))},n.prototype.renderGradient=function(t,e,i,r){var s,o,a;if("None"!==t.gradient.type){for(var l=0;l0?(w=0===S.r1?e.arc[parseInt(r.toString(),10)].r1:S.r1,C=0===S.r2?e.arc[parseInt(r.toString(),10)].r2:S.r2,r++):(w=S.r1,C=S.r2);var D=S.angle*(Math.PI/180),A=S.largeArc,x=S.sweep,P={x:u,y:f},L={x:Math.cos(D)*(M.x-P.x)/2+Math.sin(D)*(M.y-P.y)/2,y:-Math.sin(D)*(M.x-P.x)/2+Math.cos(D)*(M.y-P.y)/2},O=Math.pow(L.x,2)/Math.pow(w,2)+Math.pow(L.y,2)/Math.pow(C,2);O>1&&(w*=Math.sqrt(O),C*=Math.sqrt(O));var N=Math.pow(C,2)*Math.pow(L.x,2),T=(A===x?-1:1)*Math.sqrt((Math.pow(w,2)*Math.pow(C,2)-Math.pow(w,2)*Math.pow(L.y,2)-N)/(Math.pow(w,2)*Math.pow(L.y,2)+Math.pow(C,2)*Math.pow(L.x,2)));isNaN(T)&&(T=0);var z={x:T*w*L.y/C,y:T*-C*L.x/w},U={x:(M.x+P.x)/2+Math.cos(D)*z.x-Math.sin(D)*z.y,y:(M.y+P.y)/2+Math.sin(D)*z.x+Math.cos(D)*z.y},B=this.a([1,0],[(L.x-z.x)/w,(L.y-z.y)/C]),j=[(L.x-z.x)/w,(L.y-z.y)/C],Q=[(-L.x-z.x)/w,(-L.y-z.y)/C],oe=this.a(j,Q);this.r(j,Q)<=-1&&(oe=Math.PI),this.r(j,Q)>=1&&(oe=0);var fe=B+oe/2*(x?1:-1);if(Math.cos(fe),Math.sin(fe),S.centp=U,S.xAxisRotation=D,S.rx=w,S.ry=C,S.a1=B,S.ad=oe,S.sweep=x,null!=s){var De=w>C?w:C,xe=w>C?1:w/C,Ie=w>C?C/w:1;s.save(),s.translate(U.x,U.y),s.rotate(D),s.scale(xe,Ie),s.arc(0,0,De,B,B+oe,!x),s.scale(1/xe,1/Ie),s.rotate(-D),s.translate(-U.x,-U.y),s.restore()}break;case"Z":case"z":s.closePath(),u=o,f=a}o=u,a=f}}},n.prototype.drawText=function(t,e,i,r,s,o,a){if(e.content&&!0===e.visible){var l=n.getContext(t);l.save(),this.setStyle(t,e),o&&(e.fontSize*=o),this.applyFlipAndRotate(l,e,t,e.x+e.width*e.pivotX,e.y+e.height*e.pivotY),this.setFontStyle(t,e);var u,d=0;u=e.childNodes;var f=e.wrapBounds;if(l.fillStyle=e.color,f){var p=this.labelAlign(e,f,u);for(d=0;de.width&&"Wrap"!==e.textOverflow&&"NoWrap"===e.textWrapping&&(g.text=VF(g.text,e)),"Clip"!==e.textOverflow&&"Ellipsis"!==e.textOverflow||"Wrap"!==e.textWrapping?l.fillText(g.text,v,y):ya.actualSize.height+a.bounds.y&&(g.text=g.text.slice(0,g.text.length-3),g.text=g.text.concat("...")),l.fillText(g.text,v,y)),"Underline"===e.textDecoration||"Overline"===e.textDecoration||"LineThrough"===e.textDecoration){var M=v,w=void 0,D=v+l.measureText(g.text).width,A=void 0;switch(e.textDecoration){case"Underline":w=y+2,A=y+2;break;case"Overline":w=p.y+g.dy*d,A=p.y+g.dy*d;break;case"LineThrough":w=(y+p.y+g.dy*d)/2+2,A=(y+p.y+g.dy*d)/2+2}l.beginPath(),l.moveTo(M,w),l.lineTo(D,A),l.strokeStyle=e.color,l.lineWidth=.08*e.fontSize,l.globalAlpha=e.opacity,l.stroke()}}}l.restore()}},n.prototype.applyFlipAndRotate=function(t,e,i,r,s){"Horizontal"===e.flip||"Vertical"===e.flip?(t.translate(e.x+e.width/2,e.y+e.height/2),t.rotate(-e.angle*Math.PI/180),t.translate(-e.x-e.width/2,-e.y-e.height/2)):this.rotateContext(i,e.angle,r,s),t.translate(e.x,e.y),"Horizontal"===e.flip?(t.scale(-1,1),t.translate(-1*e.width,0)):"Vertical"===e.flip?(t.scale(1,-1),t.translate(0,-1*e.height)):"Both"===e.flip&&(t.scale(-1,-1),t.translate(-1*e.width,-1*e.height)),t.translate(-e.x,-e.y)},n.prototype.loadImage=function(t,e,i,r,s){var o=new Image;o.src=e.source,this.image(t,o,e.x,e.y,e.width,e.height,e)},n.prototype.drawImage=function(t,e,i,r){var s=this;if(e.visible){var o=n.getContext(t);o.save();var a=e.x+e.width*e.pivotX,l=e.y+e.height*e.pivotY,h=new Image;h.src=e.source,this.setStyle(t,e),o.canvas.id.split("_"),this.applyFlipAndRotate(o,e,t,a,l),r?h.onload=function(){s.loadImage(o,e,t,a,l)}:this.loadImage(o,e,t,a,l),o.restore()}},n.prototype.image=function(t,e,i,r,s,o,a){t.beginPath();var l=e.width,h=e.height,c=s,d=o,u=0,f=0;if(a&&"None"!==a.alignment){var p=a.alignment.toLowerCase().substr(1,3),g=a.alignment.toLowerCase().substr(5,3);if("Slice"===a.scale){var v=function(){u=c,f=h*c/l},y=function(){u=l*d/h,f=d};c>d?(v(),d>f&&y()):c===d?l>h?y():v():(y(),c>u&&v());var S=this.getSliceOffset(p,u,c,l),b=this.getSliceOffset(g,f,d,h),M=l-S,w=h-b,C=u-S*(u/l),D=f-b*(f/h),A=Tt("canvas",{width:s.toString(),height:o.toString()});A.getContext("2d").drawImage(e,S,b,M,w,0,0,C,D),t.drawImage(A,i,r,s,o)}else if("Meet"===a.scale){var P=h/l,L=d/c;f=L>P?c*P:d,i+=this.getMeetOffset(p,u=L>P?c:d/P,c),r+=this.getMeetOffset(g,f,d),t.drawImage(e,0,0,l,h,i,r,u,f)}else t.drawImage(e,i,r,s,o)}else if("None"!==a.flip){var O=1,N=1;("Horizontal"===a.flip||"Both"===a.flip)&&(i=-i,s=-s,O=-1),("Vertical"===a.flip||"Both"===a.flip)&&(r=-r,o=-o,N=-1),t.scale(O,N),t.drawImage(e,i,r,s,o)}else t.drawImage(e,i,r,s,o);t.closePath()},n.prototype.getSliceOffset=function(t,e,i,r){switch(t){case"min":default:return 0;case"mid":return(e-i)/2*r/e;case"max":return(e-i)*r/e}},n.prototype.getMeetOffset=function(t,e,i){var r=Math.max(e,i),s=Math.min(e,i);switch(t){case"min":default:return 0;case"mid":return(r-s)/2;case"max":return r-s}},n.prototype.m=function(t){return Math.sqrt(Math.pow(t[0],2)+Math.pow(t[1],2))},n.prototype.r=function(t,e){return(t[0]*e[0]+t[1]*e[1])/(this.m(t)*this.m(e))},n.prototype.a=function(t,e){return(t[0]*e[1]t.width&&("Ellipsis"===t.textOverflow||"Clip"===t.textOverflow)&&"NoWrap"===t.textWrapping?0:.5*t.width:"right"===t.textAlign&&(c=1*t.width),s.x=t.x+c+(e?e.x:0),s.y=a+d-r.height/2,s},n}(),db=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Vi=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Eoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return db(t,n),Vi([I("")],t.prototype,"source",void 0),Vi([I("transparent")],t.prototype,"color",void 0),Vi([I("None")],t.prototype,"scale",void 0),Vi([I("None")],t.prototype,"align",void 0),t}(Ee),Doe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return db(t,n),Vi([I("Page")],t.prototype,"mode",void 0),Vi([I("PageSettings")],t.prototype,"region",void 0),Vi([re({top:25,bottom:25,left:25,right:25},Jn)],t.prototype,"margin",void 0),Vi([I(!1)],t.prototype,"canZoomIn",void 0),Vi([I(void 0)],t.prototype,"customBounds",void 0),Vi([I(!1)],t.prototype,"canFit",void 0),t}(Ee),xoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return db(t,n),Vi([I(null)],t.prototype,"width",void 0),Vi([I(null)],t.prototype,"height",void 0),Vi([re({},Jn)],t.prototype,"margin",void 0),Vi([I("Landscape")],t.prototype,"orientation",void 0),Vi([I("Infinity")],t.prototype,"boundaryConstraints",void 0),Vi([re({},Eoe)],t.prototype,"background",void 0),Vi([I(!1)],t.prototype,"multiplePage",void 0),Vi([I(!1)],t.prototype,"showPageBreaks",void 0),Vi([re({},Doe)],t.prototype,"fitOptions",void 0),t}(Ee),Toe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return db(t,n),Vi([I(0)],t.prototype,"horizontalOffset",void 0),Vi([I(0)],t.prototype,"verticalOffset",void 0),Vi([I(1)],t.prototype,"currentZoom",void 0),Vi([I(0)],t.prototype,"viewPortWidth",void 0),Vi([I(0)],t.prototype,"viewPortHeight",void 0),Vi([I(.2)],t.prototype,"minZoom",void 0),Vi([I(30)],t.prototype,"maxZoom",void 0),Vi([I("Diagram")],t.prototype,"scrollLimit",void 0),Vi([I()],t.prototype,"scrollableArea",void 0),Vi([I(!1)],t.prototype,"canAutoScroll",void 0),Vi([I(100)],t.prototype,"autoScrollFrequency",void 0),Vi([re({left:15,right:15,top:15,bottom:15},Jn)],t.prototype,"autoScrollBorder",void 0),Vi([re({left:0,right:0,top:0,bottom:0},Jn)],t.prototype,"padding",void 0),Vi([I(.2)],t.prototype,"zoomFactor",void 0),t}(Ee),Aoe=function(){function n(){this.services={}}return n.prototype.register=function(t,e){this.services[""+t]=e},n.prototype.getService=function(t){return this.services[""+t]},n}(),WF=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),ya=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},YF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return WF(t,n),ya([I("lightgray")],t.prototype,"lineColor",void 0),ya([I("")],t.prototype,"lineDashArray",void 0),ya([I([1.25,18.75,.25,19.75,.25,19.75,.25,19.75,.25,19.75])],t.prototype,"lineIntervals",void 0),ya([I([1,19,.5,19.5,.5,19.5,.5,19.5,.5,19.5])],t.prototype,"dotIntervals",void 0),ya([I([20])],t.prototype,"snapIntervals",void 0),t}(Ee),Loe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return WF(t,n),ya([re({},YF)],t.prototype,"horizontalGridlines",void 0),ya([re({},YF)],t.prototype,"verticalGridlines",void 0),ya([I(Kt.All)],t.prototype,"constraints",void 0),ya([I(5)],t.prototype,"snapAngle",void 0),ya([I("Lines")],t.prototype,"gridType",void 0),ya([I(5)],t.prototype,"snapObjectDistance",void 0),ya([I("#07EDE1")],t.prototype,"snapLineColor",void 0),t}(Ee),QF=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),el=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},GF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return QF(t,n),el([I(5)],t.prototype,"interval",void 0),el([I(100)],t.prototype,"segmentWidth",void 0),el([I("Horizontal")],t.prototype,"orientation",void 0),el([I("RightOrBottom")],t.prototype,"tickAlignment",void 0),el([I("red")],t.prototype,"markerColor",void 0),el([I(25)],t.prototype,"thickness",void 0),el([I(null)],t.prototype,"arrangeTick",void 0),t}(Ee),Noe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return QF(t,n),el([I(!1)],t.prototype,"showRulers",void 0),el([I(!0)],t.prototype,"dynamicGrid",void 0),el([re({orientation:"Horizontal"},GF)],t.prototype,"horizontalRuler",void 0),el([re({orientation:"Vertical"},GF)],t.prototype,"verticalRuler",void 0),t}(Ee),Ooe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),XF=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},koe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ooe(t,n),XF([I("")],t.prototype,"property",void 0),XF([I("")],t.prototype,"field",void 0),t}(Ee),bT=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),ln=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},qF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return bT(t,n),ln([I("")],t.prototype,"read",void 0),ln([I("")],t.prototype,"create",void 0),ln([I("")],t.prototype,"update",void 0),ln([I("")],t.prototype,"destroy",void 0),ln([I()],t.prototype,"customFields",void 0),t}(Ee),Poe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return bT(t,n),ln([I("")],t.prototype,"id",void 0),ln([I("")],t.prototype,"sourceID",void 0),ln([I("")],t.prototype,"targetID",void 0),ln([I(null)],t.prototype,"sourcePointX",void 0),ln([I(null)],t.prototype,"sourcePointY",void 0),ln([I(null)],t.prototype,"targetPointX",void 0),ln([I(null)],t.prototype,"targetPointY",void 0),ln([I(null)],t.prototype,"dataManager",void 0),ln([re({},qF)],t.prototype,"crudAction",void 0),t}(Ee),zoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return bT(t,n),ln([I("")],t.prototype,"id",void 0),ln([I(null)],t.prototype,"dataManager",void 0),ln([I(null)],t.prototype,"dataSource",void 0),ln([I("")],t.prototype,"root",void 0),ln([I("")],t.prototype,"parentId",void 0),ln([I()],t.prototype,"doBinding",void 0),ln([Bt([],koe)],t.prototype,"dataMapSettings",void 0),ln([re({},qF)],t.prototype,"crudAction",void 0),ln([re({},Poe)],t.prototype,"connectionDataSource",void 0),t}(Ee),$F=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Cr=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Roe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return $F(t,n),Cr([I("LeftInFlow")],t.prototype,"yesBranchDirection",void 0),Cr([I("RightInFlow")],t.prototype,"noBranchDirection",void 0),Cr([I(["Yes","True"])],t.prototype,"yesBranchValues",void 0),Cr([I(["No","False"])],t.prototype,"noBranchValues",void 0),t}(Ee),Hoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return $F(t,n),Cr([I("")],t.prototype,"fixedNode",void 0),Cr([I(30)],t.prototype,"horizontalSpacing",void 0),Cr([I("SamePoint")],t.prototype,"connectionPointOrigin",void 0),Cr([I("Nonlinear")],t.prototype,"arrangement",void 0),Cr([I(30)],t.prototype,"verticalSpacing",void 0),Cr([I(30)],t.prototype,"maxIteration",void 0),Cr([I(40)],t.prototype,"springFactor",void 0),Cr([I(50)],t.prototype,"springLength",void 0),Cr([re({left:50,top:50,right:0,bottom:0},Jn)],t.prototype,"margin",void 0),Cr([I("Auto")],t.prototype,"horizontalAlignment",void 0),Cr([I("Auto")],t.prototype,"verticalAlignment",void 0),Cr([I("TopToBottom")],t.prototype,"orientation",void 0),Cr([I("Auto")],t.prototype,"connectionDirection",void 0),Cr([I("Default")],t.prototype,"connectorSegments",void 0),Cr([I("None")],t.prototype,"type",void 0),Cr([I()],t.prototype,"getLayoutInfo",void 0),Cr([I()],t.prototype,"layoutInfo",void 0),Cr([I()],t.prototype,"getBranch",void 0),Cr([I()],t.prototype,"bounds",void 0),Cr([I(!0)],t.prototype,"enableAnimation",void 0),Cr([I(!1)],t.prototype,"enableRouting",void 0),Cr([I("")],t.prototype,"root",void 0),Cr([re({},Roe)],t.prototype,"flowchartLayoutSettings",void 0),t}(Ee),Boe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),ZF=function(n){function t(e,i){var r=n.call(this,e,!0)||this;return r.oldValue=null,r.endPoint=i,r}return Boe(t,n),t.prototype.mouseDown=function(e){var i,r=!0;if(e.source&&e.source.connectors&&(i=e.source.connectors[0]),e.info&&e.actualObject&&(r=e.info.ctrlKey&&"Orthogonal"!==e.actualObject.type),i&&r){this.inAction=!0,this.undoElement=$(e.source),n.prototype.mouseDown.call(this,e);for(var s=0;s0)1!==s&&this.removePrevSegment(i,s);else if(a){var l=R.distancePoints(a.points[0],a.points[1]);Math.abs(a.length||0===a.length?a.length:l)<=5&&this.removeNextSegment(i,s)}this.commandHandler.updateEndPoint(i,r),i.selectedSegmentIndex=0}if(this.undoElement){var c=$(e.source);this.commandHandler.addHistoryEntry({type:"SegmentChanged",redoObject:c,undoObject:this.undoElement,category:"Internal"})}if(i.isBezierEditing&&(i.isBezierEditing=!1),this.prevPosition!==this.startPosition){var u={source:i,state:"Completed",oldValue:this.oldValue,newValue:$(this.selectedSegment),cancel:!1,segment:this.selectedSegment};this.commandHandler.triggerEvent(Ce.segmentChange,u)}n.prototype.mouseUp.call(this,e)},t.prototype.removePrevSegment=function(e,i){var r=e.segments[i-2],s=e.segments[i+1];if(s&&!((s.length||0===s.length?s.length:R.distancePoints(s.points[0],s.points[1]))<=5)){var a=e.segments.slice(i-1,i+1),l={element:e,removeSegments:a,type:"Removal",cancel:!1};if(this.commandHandler.triggerEvent(Ce.segmentCollectionChange,l),!l.cancel){var h=e.segments[i+1];e.segments.splice(i-1,2);var c=this.selectedSegment;"Left"===c.direction||"Right"===c.direction?(r.points[r.points.length-1].x=h.points[0].x,h.points[0].y=r.points[r.points.length-1].y):(r.points[r.points.length-1].y=h.points[0].y,h.points[0].x=r.points[r.points.length-1].x),(c.length||0===c.length)&&this.findSegmentDirection(r),this.findSegmentDirection(h)}}},t.prototype.findSegmentDirection=function(e){e.direction&&(e.length||0===e.length)&&(e.length=R.distancePoints(e.points[0],e.points[e.points.length-1]),e.direction=R.direction(e.points[0],e.points[e.points.length-1]))},t.prototype.removeNextSegment=function(e,i){var l,h,r=this.selectedSegment,s=e.segments[i-1],o=e.segments[i+2],a=e.segments[i+1];if(a.length||0===a.length?(l=e.segments.slice(i,2),h={element:e,removeSegments:l,type:"Removal",cancel:!1},this.commandHandler.triggerEvent(Ce.segmentCollectionChange,h={element:e,removeSegments:l,type:"Removal",cancel:!1}),h.cancel||(e.segments.splice(i,2),"Top"===r.direction||"Bottom"===r.direction?(o.points[0].y=r.points[0].y,s.points[s.points.length-1].x=o.points[0].x):(o.points[0].x=r.points[0].x,s.points[s.points.length-1].y=o.points[0].y))):(l=e.segments.slice(i+1,1),this.commandHandler.triggerEvent(Ce.segmentCollectionChange,h={element:e,removeSegments:l,type:"Removal",cancel:!1}),h.cancel||(e.segments.splice(i+1,1),"Top"===r.direction||"Bottom"===r.direction?s.points[s.points.length-1].x=a.points[a.points.length-1].x:s.points[s.points.length-1].y=a.points[a.points.length-1].y,this.findSegmentDirection(s),r.length=r.direction=null)),s&&o&&!h.cancel&&(s.length=R.distancePoints(s.points[0],o.points[0]),s.direction=R.direction(s.points[0],o.points[0]),o.length||0===o.length)){o.length=R.distancePoints(s.points[s.points.length-1],o.points[o.points.length-1]);var c=s.points,d=o.points;o.direction=R.direction(c[c.length-1],d[d.length-1])}},t.prototype.addOrRemoveSegment=function(e,i,r){for(var s,o,a=[],l={segments:e.segments},h=0;h0?"Bottom":"Top":r>0?"Right":"Left",length:i.points[0].x===i.points[1].x?s:r},!0)),l.push(new wi(e,"segments",{type:"Orthogonal",direction:c,length:h/2},!0));var f={element:e,addSegments:l,type:"Addition",cancel:!1};return this.commandHandler.triggerEvent(Ce.segmentCollectionChange,f),f.cancel||(e.segments=l.concat(e.segments),a=o+2),a},t.prototype.insertFirstSegment=function(e,i,r,s,o){var a,l,d,u,h=[];if(e.sourcePortID&&i.length&&e.segments[0].points.length>2)for(var f=void 0,p=0;p0?"Bottom":"Top":r>0?"Right":"Left"),f=u,h.push(u)}else h.push(new wi(e,"segments",{type:"Orthogonal",direction:i.direction,length:i.length/3},!0)),"Bottom"===i.direction||"Top"===i.direction?(l=Math.abs(r),a=r>0?"Right":"Left"):(l=Math.abs(s),a=s>0?"Bottom":"Top"),u=new wi(e,"segments",{type:"Orthogonal",direction:a,length:l},!0),h.push(u);var y={element:e,addSegments:h,type:"Addition",cancel:!1};if(this.commandHandler.triggerEvent(Ce.segmentCollectionChange,y),!y.cancel){if(e.sourcePortID&&i.length&&e.segments[0].points.length>2)e.segments.splice(0,1),d=1;else{var S=e.segments[1];S&&S.length&&(S.length=a!==S.direction?S.length+l:S.length-l),d=2,i.length=2*i.length/3}e.segments=h.concat(e.segments)}return d},t.prototype.updateAdjacentSegments=function(e,i,r,s){var o=e.segments[parseInt(i.toString(),10)],a=o.points[o.points.length-1],h=!0;"Orthogonal"===o.type&&(o.points[0]=o.points[0],o.points[o.points.length-1]=a,e.segments[i-1]&&(h=this.updatePreviousSegment(r,s,e,i)),e.segments.length-1>i&&h&&this.updateNextSegment(e,o,e.segments[i+1],r,s))},t.prototype.addTerminalSegment=function(e,i,r,s,o){var l,h,c,d,a=e.segments.indexOf(i),u=[],f=e.segments.pop(),p=e.segments[e.segments.length-1];l=p&&"Orthogonal"===p.type?p:null;for(var g=0;g0&&"Left"===o.direction?c.middleLeft:c.middleRight,o.length>c.width/2?Math.abs(a.length)0&&"Top"===o.direction?c.topCenter:c.bottomCenter,o.length>c.height/2?Math.abs(a.length)1)for(var a=0,l=this.diagram.views;a0)for(var e=t===Ce.onUserHandleMouseLeave?this.previousAction:this.action,i={element:void 0},r=0;r0)for(var r={element:void 0},s=void 0,o=void 0,a=0;a-1&&(o=s,this.previousTarget=i,this.targetItem=e),o===e.fixedUserHandles[parseInt(a.toString(),10)].id&&(r.element=e.fixedUserHandles[parseInt(a.toString(),10)],this.userHandle(t,a,r,e))},n.prototype.mouseDown=function(t){var e=this;if("touchstart"===t.type&&(this.timeOutTapHold=setTimeout(function(){("Select"===e.action||"Drag"===e.action)&&e.mouseMove(t,void 0)},500)),!0!==this.inAction||!(this.tool instanceof WI||this.tool instanceof pa)){this.focus=!0;var i=t.touches,r=!!document.getElementsByClassName("e-dragclone")[0];if(this.isMouseOnScrollBar(t)&&!r)return this.isScrolling=!0,void t.preventDefault();if(this.checkFixedUserHandleEvent(Ce.onFixedUserHandleMouseDown,this.targetItem,this.previousTarget),this.checkUserHandleEvent(Ce.onUserHandleMouseDown),!this.checkEditBoxAsTarget(t)&&jv(this.diagram)||Lc(this.diagram)&&!RI(this.diagram))if(("Select"===this.action||"Drag"===this.action)&&this.diagram.updatePortVisibility(this.hoverElement,oi.Hover,!0),!(this.tool instanceof zl||this.tool instanceof Rl)||2!==t.button&&2!==t.buttons)if(!0===this.inAction&&!0===this.isMouseDown&&(this.tool instanceof zl||this.tool instanceof Rl))this.isMouseDown=!0,this.eventArgs={},this.getMouseEventArgs(this.currentPosition,this.eventArgs),this.eventArgs.position=this.currentPosition,this.tool.mouseDown(this.eventArgs);else{this.isMouseDown=!0,this.currentPosition=this.prevPosition=this.getMousePosition(t),this.eventArgs={},this.diagram.textEditing&&!this.isMouseOnScrollBar(t)&&(this.diagram.endEdit(),this.diagram.textEditing=!1,"Canvas"===this.diagram.mode&&1!==this.diagram.scroller.currentZoom&&this.diagram.refreshDiagramLayer());var o=this.getTargetElement();this.action=this.diagram.findActionToBeDone(o.obj,o.sourceElement,this.currentPosition,o.target);var a=this.isMetaKey(t);a&&t.shiftKey&&this.diagram.connectorEditingToolModule?this.action="SegmentEnd":(a||t.shiftKey)&&(_v(this.diagram)||Uv(this.diagram))&&(this.action="Select"),this.tool=this.diagram.getTool(this.action),this.tool||(this.action="Select",this.tool=this.diagram.getTool(this.action)),this.getMouseEventArgs(this.currentPosition,this.eventArgs),(a||t.shiftKey)&&(this.eventArgs.info=a&&t.shiftKey?{ctrlKey:a,shiftKey:t.shiftKey}:{ctrlKey:!0}),this.eventArgs.position=this.currentPosition;var h=this.diagram.selectedItems.nodes;if(this.tool.mouseDown(this.eventArgs),this.diagram.selectedItems.canToggleSelection&&h&&this.diagram.selectedItems.nodes&&this.tool instanceof fa)for(var c=0;c=2&&(this.touchStartList=HF(this.touchStartList,0,i)),i||t.preventDefault())}else this.inAction=!1,this.tool.mouseUp(this.eventArgs);!this.isForeignObject(t.target)&&!this.isForeignObject(t.target,!0)&&!i&&t.preventDefault()}},n.prototype.mouseMoveExtend=function(t,e){(this.tool instanceof zl||this.tool instanceof Rl)&&this.tool.mouseMove(this.eventArgs),this.diagram.scrollSettings.canAutoScroll?this.checkAutoScroll(t):this.blocked||this.tool.mouseMove(this.eventArgs),this.eventArgs.target&&(this.hoverElement=this.eventArgs.target);var i=!((this.eventArgs.target instanceof te||this.eventArgs.target instanceof de)&&(e instanceof te||e instanceof de));this.tool instanceof kd&&this.diagram.updatePortVisibility(this.hoverElement instanceof te||this.hoverElement instanceof de?this.hoverElement:this.hoverNode,oi.Connect|oi.Hover,i),this.hoverElement instanceof te&&this.hoverNode instanceof te&&this.hoverNode&&this.hoverNode.id!==this.hoverElement.id&&this.diagram.updatePortVisibility(this.hoverNode,oi.Connect|oi.Hover,!0),this.hoverElement instanceof de&&this.hoverElement.ports.length>0&&this.diagram.updatePortVisibility(this.hoverElement,oi.Connect|oi.Hover,!0),this.previousElement instanceof te&&this.hoverElement&&this.previousElement.id!==this.hoverElement.id&&this.diagram.updatePortVisibility(this.previousElement,oi.Connect|oi.Hover,!0),this.previousElement=this.hoverElement,""!==this.diagram.tooltip.content&&(this.hoverElement=null),this.hoverNode=i?null:e},n.prototype.checkAction=function(t){if("LabelSelect"===this.action&&this.eventArgs.sourceWrapper&&(this.eventArgs.sourceWrapper instanceof li||this.eventArgs.sourceWrapper instanceof es)){var e=this.commandHandler.findTarget(this.eventArgs.sourceWrapper,this.eventArgs.source);!_r(this.diagram,e,!1,this.eventArgs.sourceWrapper)&&ro(e)&&(this.action="LabelDrag",this.tool=this.getTool(this.action),this.tool.mouseDown(this.initialEventArgs))}else ro(t)&&xd(t)&&this.initialEventArgs&&this.initialEventArgs.source&&"Select"===this.action&&(!_r(this.diagram,this.eventArgs.source,!1)&&this.eventArgs.source instanceof ei&&this.getMouseEventArgs(this.currentPosition,this.eventArgs),(!(t instanceof de)||t instanceof de&&!(wr(this.currentPosition,t.sourcePoint,t.hitPadding)||wr(this.currentPosition,t.targetPoint,t.hitPadding)))&&(this.action="Drag"),this.tool=this.getTool(this.action),this.tool.mouseDown(this.initialEventArgs))},n.prototype.isSwimlaneElements=function(t){return!(t&&(t.isLane||t.isPhase||t.isHeader))},n.prototype.canShowTouchTooltip=function(t){return!!("touchstart"===t.type&&this.diagram.tool&ri.SingleSelect&&this.diagram.tool&ri.ZoomPan)&&(this.isMouseDown=!1,!0)},n.prototype.mouseMove=function(t,e){if(this.focus=!0,"touchmove"===t.type&&(this.touchArgs={target:t.target,type:"touchmove"}),this.isScrolling)t.preventDefault();else if(jv(this.diagram)||Lc(this.diagram)&&!RI(this.diagram)){this.currentPosition=this.getMousePosition(t);var i=this.diagram.findObjectsUnderMouse(this.currentPosition),r=this.diagram.findObjectUnderMouse(i,this.action,this.inAction);!function Gne(n,t){n.rulerSettings.showRulers&&(n.hRuler.drawRulerMarker(n.hRuler.element,t,n.scroller.horizontalOffset),n.vRuler.drawRulerMarker(n.vRuler.element,t,n.scroller.verticalOffset))}(this.diagram,this.currentPosition);var s=!1,o=void 0;if("touchmove"===t.type&&(e=t.touches)&&e.length>1&&(this.touchMoveList=HF(this.touchMoveList,0,e),"PinchZoom"!==this.action&&(s=!0)),!1===R.equals(this.currentPosition,this.prevPosition)||this.inAction||this.canShowTouchTooltip(t)){if(!1===this.isMouseDown||s){this.eventArgs={};var a=null,l=void 0;if(null!==r){if((a=this.diagram.findElementUnderMouse(r,this.currentPosition,this.diagram))&&(l=this.commandHandler.findTarget(a,r)),(l instanceof Kn||l instanceof Or)&&(l.tooltip&&""!==l.tooltip.content||(l=r)),l!==this.hoverElement){var h=this.getContent();this.hoverElement&&"Auto"===this.hoverElement.tooltip.openOn&&""!==h&&this.elementLeave(),this.diagram.updatePortVisibility(this.hoverElement,oi.Hover,!0),r instanceof te&&(this.hoverNode=r);var c=!0;!this.isSwimlaneElements(r)&&this.hoverElement&&this.isSwimlaneElements(this.hoverElement)&&(c=!1),this.hoverElement=c?r:this.hoverElement;var d,u=void 0;(d=this.diagram.findElementUnderMouse(r,this.currentPosition,this.diagram))instanceof Ze&&((u=this.commandHandler.findTarget(d,r))instanceof Es||u instanceof Tc)&&this.hoverElement.constraints&ai.ToolTip&&(this.hoverElement=u);var f=void 0;d instanceof li&&((f=this.commandHandler.findTarget(d,r))instanceof Kn||f instanceof Or)&&f.constraints&Nr.Tooltip&&(this.hoverElement=f),c?this.elementEnter(this.currentPosition,!1):this.hoverElement=r}else this.hoverElement&&this.hoverElement===l&&this.hoverElement.tooltip.content&&void 0!==this.diagram.tooltipObject&&"Mouse"===this.hoverElement.tooltip.relativeMode&&this.setTooltipOffset(this.currentPosition);a&&(o=this.commandHandler.findTarget(a,r))}this.action=this.diagram.findActionToBeDone(r,a,this.currentPosition,o),this.checkFixedUserHandleEvent(Ce.onFixedUserHandleMouseEnter,r,a),this.checkUserHandleEvent(Ce.onUserHandleMouseEnter),this.checkPreviousAction(),this.getMouseEventArgs(this.currentPosition,this.eventArgs),this.tool=this.getTool(this.action),this.mouseEvents(),this.tool instanceof pa||this.tool instanceof Rl||this.tool instanceof zl?this.tool.mouseMove(this.eventArgs):e&&this.tool instanceof Kv&&this.tool.mouseDown(this.eventArgs),this.updateCursor(),this.renderUmlHighLighter(this.eventArgs);var p=!1;this.hoverElement&&!(this.tool instanceof Kv)&&r instanceof te&&this.isSwimlaneElements(r)&&(0===this.diagram.selectedItems.nodes.length||!_r(this.diagram,this.hoverElement))||this.hoverElement instanceof de||(p=!0),this.hoverElement&&!(this.tool instanceof Kv)&&r instanceof de&&(0===this.diagram.selectedItems.connectors.length||!_r(this.diagram,this.hoverElement))||this.hoverElement instanceof te||(p=!0),this.diagram.updatePortVisibility(this.hoverElement,oi.Hover,p);var g=this.getContent();null===r&&this.hoverElement&&"Auto"===this.hoverElement.tooltip.openOn&&g&&(this.hoverElement=null,this.elementLeave()),s=!1}else{this.eventArgs.position=this.currentPosition,"Drag"===this.action&&!_r(this.diagram,this.eventArgs.source,!1)&&this.eventArgs.source instanceof ei&&this.getMouseEventArgs(this.currentPosition,this.eventArgs),this.mouseEvents(),(t.ctrlKey||t.shiftKey)&&(this.eventArgs.info=t.ctrlKey&&t.shiftKey?{ctrlKey:t.ctrlKey,shiftKey:t.shiftKey}:{ctrlKey:!0}),this.checkAction(r);var y=this.getConnectorPadding(this.eventArgs);this.getMouseEventArgs(this.currentPosition,this.eventArgs,this.eventArgs.source,y),this.updateCursor(),this.inAction=!0,this.initialEventArgs=null,("Drag"===this.action||"Rotate"===this.action)&&(this.diagram.diagramActions=this.diagram.diagramActions|ee.Interactions);var S=this.diagram.scroller.getPageBounds();this.mouseMoveExtend(t,r);var b=this.diagram.scroller.getPageBounds();if(r&&(S.width!==b.width||S.height!==b.height||S.x!==b.x||S.y!==b.y)&&this.diagram.views&&this.diagram.views.overview){var M=this.diagram.views.overview;M.updateView(M)}}this.prevPosition=this.currentPosition,this.isForeignObject(t.target,!0)||t.preventDefault()}}},n.prototype.getContent=function(){var i,t=this.hoverElement instanceof te&&this.hoverElement.constraints&ie.Tooltip||this.hoverElement instanceof de&&this.hoverElement.constraints&qe.Tooltip||(this.hoverElement instanceof Es||this.hoverElement instanceof Tc)&&this.hoverElement.constraints&ai.ToolTip||(this.hoverElement instanceof Kn||this.hoverElement instanceof Or)&&this.hoverElement.constraints&Nr.Tooltip,e=this.hoverElement;e instanceof te&&e.children&&e.children.length>0&&(i=this.findIntersectChild(e));var r=t?this.hoverElement.tooltip.content:this.diagram.tooltip.content;return i?i.tooltip.content:r},n.prototype.findIntersectChild=function(t){for(var e,i=new Ne(this.currentPosition.x,this.currentPosition.y,8,8),r=0;r1&&1===t.which&&!function qre(n){return!!(n&ee.PreventClearSelection)}(this.diagram.diagramActions)&&(c=!1,this.commandHandler.clearSelection()),(!_r(this.diagram,h)||!c)&&(this.commandHandler.selectObjects([h],void 0,a),this.diagram.selectedItems.canToggleSelection)){var d=this.diagram.selectedItems.nodes;d?d[0].parentObj instanceof Hd&&(s=!0):this.diagram.selectedItems.connectors.length>0&&(s=!0)}}var u=!1,f=this.updateContainerProperties(),p=void 0;if(this.addUmlNode(),this.inAction=!1,this.isMouseDown=!1,this.diagram.selectedObject.helperObject&&(p=this.updateContainerBounds()),this.tool&&(this.tool.prevPosition||this.tool instanceof X3)){this.eventArgs.position=this.currentPosition;var g=this.getConnectorPadding(this.eventArgs);this.getMouseEventArgs(this.currentPosition,this.eventArgs,this.eventArgs.source,g);var v=this.isMetaKey(t);if((v||t.shiftKey)&&(this.eventArgs.info=v&&t.shiftKey?{ctrlKey:v,shiftKey:t.shiftKey}:{ctrlKey:!0}),this.diagram.diagramActions&ee.Interactions&&(this.diagram.diagramActions=this.diagram.diagramActions&~ee.Interactions),this.eventArgs.clickCount=t.detail,this.diagram.selectedObject.helperObject&&(this.tool instanceof fa||this.tool instanceof Pd)){if(this.diagram.selectedObject.actualObject&&""!==this.diagram.selectedObject.actualObject.parentId){var S=this.diagram.getObject(this.diagram.selectedObject.actualObject.parentId);S&&S.isLane&&(this.commandHandler.isContainer=!0)}(u=this.diagram.lineRoutingModule&&this.diagram.nameTable.helper&&this.eventArgs.target&&this.eventArgs.target.isLane&&(this.eventArgs.source instanceof ei&&this.eventArgs.source.nodes.length>0&&""===this.eventArgs.source.nodes[0].parentId||""===this.eventArgs.source.parentId))&&(this.diagram.diagramActions=this.diagram.diagramActions|ee.PreventLaneContainerUpdate),this.tool.mouseUp(this.eventArgs,f.isPreventHistory)}else{if(this.diagram.selectedItems.canToggleSelection){var b=void 0,M=void 0;if(this.diagram.selectedItems.nodes.length>0)for(var w=0;w1&&D[0].id===i[parseInt(w.toString(),10)].id||r.length>0)&&(M=!0);!this.isSwimlaneSelected&&!s&&!M&&this.tool instanceof fa&&"Select"===this.currentAction&&(!b||this.diagram.selectedItems.connectors.length>0)&&this.commandHandler.clearSelection(!0)}this.isSwimlaneSelected=!1,this.tool.mouseUp(this.eventArgs),this.diagram.checkMenu&&(-1!==window.navigator.userAgent.indexOf("Linux")||-1!==window.navigator.userAgent.indexOf("X11"))&&(!t.pageY&&t instanceof TouchEvent&&t.changedTouches?(window.getSelection().removeAllRanges(),this.diagram.contextMenuModule.contextMenu.open(t.changedTouches[0].pageY,t.changedTouches[0].pageX,this.diagram.element),t.preventDefault()):this.diagram.contextMenuModule.contextMenu.open(t.pageY,t.pageX,this.diagram.element),this.diagram.checkMenu=!1)}f.hasStack&&this.diagram.endGroupAction()}if(p&&this.diagram.endGroupAction(),this.updateContainerBounds(!0),2!==this.eventArgs.clickCount&&(this.commandHandler.updateSelectedNodeProperties(this.eventArgs.source),u)){this.diagram.diagramActions=this.diagram.diagramActions&~ee.PreventLaneContainerUpdate;var A=this.eventArgs.source instanceof ei?this.eventArgs.source.nodes:[this.eventArgs.source];if(A)for(w=0;w0&&!N&&this.diagram.renderSelector(!0),!this.inAction&&!this.diagram.currentSymbol&&this.eventArgs){var T=this.getTargetElement();this.diagram.tool!==ri.ZoomPan&&this.diagram.triggerEvent(Ce.click,{element:T.target instanceof Es?T.target:this.eventArgs.source||this.diagram,position:this.eventArgs.position,count:t.detail,actualObject:this.eventArgs.actualObject,button:0===t.button?"Left":1===t.button?"Middle":"Right"})}this.eventArgs={}}this.diagram.diagramActions=this.diagram.diagramActions&~ee.PreventLaneContainerUpdate,e&&this.updateAnnotation(this.diagram.selectedItems),this.previousElement=null,this.eventArgs={},this.diagram.commandHandler.removeStackHighlighter()},n.prototype.isSwimlaneChild=function(t){if(t.shape&&"SwimLane"!==t.shape.type){var e=this.diagram.nameTable[t.parentId];if(!e)return!1;var i=e.parentId?this.diagram.nameTable[e.parentId]:e;return i&&i.shape&&"SwimLane"===i.shape.type}return!1},n.prototype.updateAnnotation=function(t){var e=t.nodes;if(e.length>0)for(var i=0;i0&&(a+=1),h.isPhase){l="Horizontal"===r.orientation?this.currentPosition.x-e.wrapper.bounds.x:this.currentPosition.y-(e.wrapper.bounds.y+r.header.height);var g={id:Qe(),offset:l,header:{annotation:{content:void 0===h.phases[0].header?"Phase":h.phases[0].header.annotation.content,style:void 0===h.phases[0].header?{}:h.phases[0].header.annotation.style}},style:void 0===h.phases[0]?{}:h.phases[0].style};this.diagram.addPhases(e,[g])}else{var v={id:Qe(),style:h.lanes[0].style,header:{annotation:{content:h.lanes[0].header.annotation.content,style:h.lanes[0].header.annotation.style},style:h.lanes[0].header.style}};if("Horizontal"===h.orientation?v.height=h.lanes[0].height:v.width=h.lanes[0].width,"Horizontal"===r.orientation?(s=i.rowIndex?i.rowIndex:this.diagram.nameTable[i.parentId].rowIndex,i.wrapper.offsetYs)v.header.width=r.lanes[parseInt(s.toString(),10)].header.width,v.header.height=r.lanes[parseInt(s.toString(),10)].header.height;else{var S=void 0;S="Horizontal"===r.orientation?i.rowIndex<3?0:s-a-1:s-1,v.header.width=r.lanes[parseInt(S.toString(),10)].header.width,v.header.height=r.lanes[parseInt(S.toString(),10)].header.height}p&&("height"===p?(v.width=v.height,delete v.height):(v.height=v.width,delete v.width)),this.diagram.addLanes(e,[v],"Horizontal"===r.orientation?s-a:s)}this.commandHandler.select(e)}else if(h.isLane){var b={id:Qe(),width:t.width,height:t.height,addInfo:t.addInfo,shape:{type:"SwimLane",header:{annotation:{content:void 0===h.header?"Header":h.header.annotation.content,style:void 0===h.header?{}:h.header.annotation.style},height:50,style:h.header?h.header.style:h.lanes[0].header.style},phases:[{id:Qe(),header:{annotation:{content:void 0===h.phases||void 0===h.phases[0].header?"Phase":h.phases[0].header.annotation.content,style:void 0===h.phases||void 0===h.phases[0].header?{}:h.phases[0].header.annotation.style},style:void 0===h.phases||void 0===h.phases[0].header?{}:h.phases[0].header.style},style:void 0===h.phases?{}:h.phases[0].style}],lanes:[{id:Qe(),height:t.height,width:t.width,style:h.lanes[0].style,header:{annotation:{content:h.lanes[0].header.annotation.content,style:h.lanes[0].header.annotation.style},style:h.lanes[0].header.style}}],orientation:h.orientation}};"Vertical"===h.orientation&&(b.width+=20),b.offsetX=this.currentPosition.x+b.width/2,b.offsetY=this.currentPosition.y+b.height/2,b.style=t.style,this.diagram.add(b)}},n.prototype.mouseLeave=function(t){this.tool&&this.inAction&&this.tool.mouseLeave(this.eventArgs),this.diagram.selectedObject.helperObject&&(this.updateContainerProperties(),this.updateContainerBounds()&&this.diagram.endGroupAction()),this.eventArgs&&this.eventArgs.source&&(this.diagram.updatePortVisibility(this.eventArgs.source,oi.Hover,!0),this.hoverElement=null),this.eventArgs&&!this.eventArgs.source&&this.hoverElement&&(this.hoverElement=null),this.tool instanceof kd&&this.eventArgs&&this.eventArgs.target&&this.eventArgs.target instanceof te&&(this.diagram.updatePortVisibility(this.eventArgs.target,oi.Hover|oi.Connect,!0),this.hoverElement=null);var i=this.diagram.selectedItems;i&&i.wrapper&&(am(this.diagram,i)||this.diagram.renderSelector(!0)),(this.diagram.diagramActions&ee.Interactions||this.diagram.diagramActions&ee.ToolAction)&&(this.diagram.diagramActions=this.diagram.diagramActions&~ee.ToolAction),this.isMouseDown=!1,this.focus=!1,this.touchStartList=null,this.touchMoveList=null,this.elementLeave(),this.commandHandler.removeSnap(),this.inAction=!1,this.eventArgs={},this.diagram.selectedObject&&this.diagram.selectedObject.helperObject&&(this.diagram.remove(this.diagram.selectedObject.helperObject),this.diagram.selectedObject={helperObject:void 0,actualObject:void 0}),this.tool=null,function Qne(){var t,e,n=document.getElementsByClassName("e-d-ruler-marker");if(n&&n.length>0)for(e=n.length-1;e>=0;e--)(t=n[parseInt(e.toString(),10)])&&t.parentNode.removeChild(t)}(),"Rotate"===this.action&&this.diagram.diagramCanvas.classList.remove("e-diagram-rotate"),t.preventDefault()},n.prototype.mouseWheel=function(t){this.diagram.blazorActions|=on.interaction;var e={event:t,cancel:!1};if(this.diagram.triggerEvent(Ce.mouseWheel,e),!e.cancel){var i=t.wheelDelta>0||-40*t.detail>0,r=this.getMousePosition(t);if(this.diagram.tooltipObject.close(),this.isMetaKey(t)){var o=this.diagram.scrollSettings.zoomFactor;this.diagram.zoomTo(i?{type:"ZoomIn",zoomFactor:o,focusPoint:r}:{type:"ZoomOut",zoomFactor:o,focusPoint:r}),t.preventDefault()}else{var a=this.diagram.scroller.horizontalOffset,l=this.diagram.scroller.verticalOffset,h=i?10:-10;this.tool&&(this.tool instanceof zl||this.tool instanceof Rl)&&(this.eventArgs={},this.getMouseEventArgs(r,this.eventArgs),this.eventArgs.position=r,this.tool.mouseWheel(this.eventArgs)),this.diagram.scrollActions|=da.Interaction;var c=!0;if(t.isTrusted){var d=!1;(Math.abs(t.deltaY)<100&&-0===Math.abs(t.deltaX)||Math.abs(t.deltaX)<100&&-0===Math.abs(t.deltaY))&&(d=!0);var u=!1;(0!==t.deltaX||0!==t.deltaY)&&(u=navigator.userAgent.includes("Macintosh")),u?Math.abs(t.deltaX)>Math.abs(t.deltaY)?(t.shiftKey||t.deltaX&&-0!==t.deltaX&&(d||!u))&&this.diagram.scroller.zoom(1,h,0,r,c,void 0,d):t.deltaY&&-0!==t.deltaY&&(d||!u)&&this.diagram.scroller.zoom(1,0,h,r,c,void 0,d):t.shiftKey||t.deltaX&&-0!==t.deltaX&&(d||!u)?this.diagram.scroller.zoom(1,h,0,r,c,void 0,d):t.deltaY&&-0!==t.deltaY&&(d||!u)&&this.diagram.scroller.zoom(1,0,h,r,c,void 0,d)}else t.shiftKey||t.deltaX&&-0!==t.deltaX?this.diagram.scroller.zoom(1,h,0,r,c):this.diagram.scroller.zoom(1,0,h,r,c);this.diagram.scrollActions&=~da.Interaction,(a!==this.diagram.scroller.horizontalOffset||l!==this.diagram.scroller.verticalOffset)&&t.preventDefault()}if(this.diagram.textEditing){if(this.diagram.isTriggerEvent=!0,this.diagram.activeLabel.parentId){var p=this.diagram.getObject(this.diagram.activeLabel.parentId);this.diagram.startTextEdit(p,this.diagram.activeLabel.id)}this.diagram.isTriggerEvent=!1}this.diagram.blazorActions=this.diagram.blazorActions&~on.interaction}},n.prototype.keyDown=function(t){if(t.fromMouseEvents&&(t.ctrlKey&&(this.keyArgs.keyModifiers=1),t.shiftKey&&(this.keyArgs.keyModifiers=4),t.shiftKey&&t.ctrlKey&&(this.keyArgs.keyModifiers=5)),!(this.diagram.diagramActions&ee.TextEdit)&&!this.checkEditBoxAsTarget(t)||"Escape"===t.key||27===t.keyCode){var i=void 0,r=t.keyCode?t.keyCode:t.which,s=t.key;("ArrowDown"===s||"ArrowUp"===s||"ArrowLeft"===s||"ArrowRight"===s)&&(this.isNudgeKey=!0);var o=this.isMetaKey(t);if(this.diagram.commandManager&&this.diagram.commands)for(var l=0,h=Object.keys(this.diagram.commands);l4&&(S({keyDownEventArgs:KeyboardEvent,parameter:i.parameter,type:"KEYDOWN"}),this.keyCount=0,this.keyArgs.newValue={offsetX:this.diagram.selectedItems.offsetX,offsetY:this.diagram.selectedItems.offsetY},this.diagram.triggerEvent(Ce.positionChange,this.keyArgs))),this.isKeyUp=!1):S({keyDownEventArgs:KeyboardEvent,parameter:i.parameter})}break}}}}this.keyArgs={element:this.diagram.selectedItems,key:t.key,keyCode:t.keyCode?t.keyCode:t.which},this.getKeyModifier(this.keyArgs,t),this.diagram.diagramActions&ee.TextEdit&&this.getlabel(this.keyArgs,t),this.diagram.triggerEvent(Ce.keyDown,this.keyArgs)},n.prototype.getlabel=function(t,e){var i=this.diagram.activeLabel;t.target=this.diagram.element.id+"_editBox";var r=this.diagram.nameTable[i.parentId];if(document.getElementById(this.diagram.element.id+"_editBox")){t.text=document.getElementById(this.diagram.element.id+"_editBox").value;for(var s=0;s=this.diagram.scroller.viewPortWidth-18?r="right":e.x+this.diagram.scroller.horizontalOffsetthis.diagram.scroller.viewPortHeight-18?r="bottom":e.y+this.diagram.scroller.verticalOffset0&&(s=this.findIntersectChild(this.hoverElement)),"Auto"===this.hoverElement.tooltip.openOn&&""!==r&&Mx(this.diagram,s||(i?this.hoverElement:void 0)),this.hoverElement.tooltip.content&&("Mouse"===this.hoverElement.tooltip.relativeMode?this.setTooltipOffset(t):(this.diagram.tooltipObject.offsetX=0,this.diagram.tooltipObject.offsetY=0));var o=this.diagram.findObjectsUnderMouse(this.currentPosition),a=this.diagram.findObjectUnderMouse(o,this.action,this.inAction);if(null!==a){var l=void 0;this.hoverElement.tooltip.isSticky&&(this.diagram.tooltipObject.isSticky=!0),a instanceof te&&a.children&&a.children.length>0&&(a=s||a),l=a.ports&&(this.hoverElement instanceof Es||this.hoverElement instanceof Tc)||a.annotations&&(this.hoverElement instanceof Kn||this.hoverElement instanceof Or)?document.getElementById(a.id+"_"+this.hoverElement.id):document.getElementById(a.id+(a.shape&&a.shape instanceof lm?"_content_native_element":"_groupElement")),"Auto"===this.hoverElement.tooltip.openOn&&""!==r&&(this.diagram.tooltipObject.close(),this.diagram.tooltipObject.openOn=this.hoverElement.tooltip.openOn,this.diagram.tooltipObject.dataBind()),function jre(n,t){var e=0;return n instanceof de?n.constraints&qe.Tooltip?e=n.constraints&qe.Tooltip:n.constraints&qe.InheritTooltip&&(e=t.constraints&nt.Tooltip):n instanceof Es||n instanceof Tc?n.constraints&ai.ToolTip?e=n.constraints&ai.ToolTip:n.constraints&ai.InheritTooltip&&(e=t.constraints&nt.Tooltip):n instanceof Kn||n instanceof Or?n.constraints&Nr.Tooltip&&(e=n.constraints&Nr.Tooltip):n.constraints&ie.Tooltip?e=n.constraints&ie.Tooltip:n.constraints&ie.InheritTooltip&&(e=t.constraints&nt.Tooltip),e}(this.hoverElement,this.diagram)&&"Auto"===this.hoverElement.tooltip.openOn&&(this.diagram.tooltipObject.target=this.hoverElement.id,this.diagram.tooltipObject.open("Mouse"===this.hoverElement.tooltip.relativeMode?this.diagram.element:l))}}},n.prototype.elementLeave=function(){this.diagram.tooltipObject&&!this.diagram.tooltipObject.isSticky&&"Custom"!==this.diagram.tooltipObject.openOn&&this.diagram.tooltipObject.close()},n.prototype.setTooltipOffset=function(t){var e=function dse(n,t,e,i){var o="Mouse"===(!(e instanceof te?e.constraints&ie.InheritTooltip:e instanceof de?e.constraints&qe.InheritTooltip:e.constraints&ai.InheritTooltip)&&(e instanceof te?e.constraints&ie.Tooltip:e instanceof de?e.constraints&qe.Tooltip:e.constraints&ai.ToolTip)?e.tooltip.relativeMode:n.tooltip.relativeMode);"Mouse"===i?o=!0:"Object"===i&&(o=!1);var a=function use(n,t,e,i){var o,r={},s=document.getElementById(e.element.id);if(n instanceof te||n instanceof de)o=n.wrapper.bounds;else{var a=e.findObjectsUnderMouse(t),l=e.findObjectUnderMouse(a,"Select",!1);o=e.findElementUnderMouse(l,t,e).bounds}var c=s.getBoundingClientRect();switch(e.tooltipObject.position){case"BottomCenter":r=zc(t,o.bottomCenter,e,i,c.width/2,c.height);break;case"BottomLeft":case"LeftBottom":r=zc(t,o.bottomLeft,e,i,0,c.height);break;case"BottomRight":case"RightBottom":r=zc(t,o.bottomRight,e,i,c.width,c.height);break;case"LeftCenter":r=zc(t,o.middleLeft,e,i,0,c.height/2);break;case"LeftTop":case"TopLeft":r=zc(t,o.topLeft,e,i,0,0);break;case"RightCenter":r=zc(t,o.middleRight,e,i,c.width,c.height/2);break;case"RightTop":case"TopRight":r=zc(t,o.topRight,e,i,c.width,0);break;case"TopCenter":r=zc(t,o.topCenter,e,i,c.width/2,0)}return r}(e,t,n,o),l=Za(n);return{x:a.x+l.width,y:a.y+l.height}}(this.diagram,t,this.hoverElement);this.diagram.tooltipObject.offsetX=e.x,this.diagram.tooltipObject.offsetY=e.y},n.prototype.altKeyPressed=function(t){return!!(t&ft.Alt)},n.prototype.ctrlKeyPressed=function(t){return!!(t&ft.Control)},n.prototype.shiftKeyPressed=function(t){return!!(t&ft.Shift)},n.prototype.scrolled=function(t){this.diagram.updateScrollOffset()},n.prototype.isMobileOrIPadDevice=function(){var t=navigator.userAgent||navigator.vendor||window.opera;return/iPhone|iPad|iPod/.test(t)&&!window.MSStream?"iOS":/android/i.test(t)?"Android":/Mobile|Tablet/.test(t)?"Mobile":"Desktop"},n.prototype.doubleClick=function(t){if(jv(this.diagram)){var e=this.isMobileOrIPadDevice(),i=this.diagram.tool;"Desktop"!==e&&this.tool&&(this.tool instanceof zl||this.tool instanceof Rl)&&(this.diagram.tool=0);var r=void 0,s=this.diagram.findObjectsUnderMouse(this.currentPosition),o=this.diagram.findObjectUnderMouse(s,this.action,this.inAction);if(null!==o&&jv(this.diagram))if(r=this.diagram.findElementUnderMouse(o,this.currentPosition,this.diagram),this.tool&&(this.tool instanceof zl||this.tool instanceof Rl))this.diagram.tool=i,this.tool.mouseUp(this.eventArgs),this.isMouseDown=!1,this.eventArgs={},this.tool=null,t.preventDefault();else{var l=this.diagram.commandHandler.getObjectLayer(o.id);!l||l.lock||!l.visible||this.diagram.diagramActions&ee.TextEdit||this.diagram.startTextEdit(o,r instanceof li?r.id.split(o.id+"_")[1]:void 0)}this.diagram.triggerEvent(Ce.doubleClick,{source:o||this.diagram,position:this.currentPosition,count:t.detail})}},n.prototype.itemClick=function(t,e){var i=t;return Dn(this.diagram,i,!0)?i:null},n.prototype.inputChange=function(t){var i,s,o,a,l,h,c,d,u,f=document.getElementById(this.diagram.element.id+"_editBox"),p=document.getElementById(this.diagram.element.id+"_editTextBoxDiv"),g=f.value,v=g.split("\n");(!(a=this.diagram.selectedItems.nodes[0]?this.diagram.selectedItems.nodes[0]:this.diagram.selectedItems.connectors[0])&&this.tool instanceof YI||a&&"SwimLane"===a.shape.type)&&(a=this.diagram.nameTable[this.diagram.activeLabel.parentId]),a&&("Text"!==a.shape.type&&a.annotations.length>0||"Text"===a.shape.type)&&(c=NF((o=this.diagram.getWrapper(a.wrapper,this.diagram.activeLabel.id)).style,g,void 0,void 0,i=(i=a.wrapper.bounds.width90?i:90),s=Number(f.style.fontSize.split("px")[0]),v.length>1&&""===v[v.length-1]&&(c.height=c.height+s),d=this.diagram.scroller.transform,u=T3(this.diagram)?d.scale:1,l=(12>c.height?12:c.height)*u,p.style.left=(o.bounds.center.x+d.tx)*d.scale-(h=(90>(h=c.width)?90:h)*u)/2-2.5+"px",p.style.top=(o.bounds.center.y+d.ty)*d.scale-l/2-3+"px",p.style.width=h+"px",p.style.height=l+"px",f.style.minHeight="12px",f.style.minWidth="90px",f.style.width=h+"px",f.style.height=l+"px")},n.prototype.isAddTextNode=function(t,e){return!(!(this.tool instanceof YI||e)||(this.tool=null,t&&!zI(this.diagram)&&(this.diagram.drawingObject=void 0,this.diagram.currentDrawingObject=void 0),vF(this.diagram.nodes,t.id)||vF(this.diagram.connectors,t.id)))},n.prototype.checkEditBoxAsTarget=function(t){return!(!t.target||t.target.id!==this.diagram.element.id+"_editBox")},n.prototype.getMouseEventArgs=function(t,e,i,r){var s,o,a;if(e.position=t,i?(o=this.diagram.findObjectsUnderMouse(this.currentPosition,i),s=this.diagram.findTargetObjectUnderMouse(o,this.action,this.inAction,e.position,i)):"Drag"===this.action||"ConnectorSourceEnd"===this.action||"SegmentEnd"===this.action||"OrthoThumb"===this.action||"BezierSourceThumb"===this.action||"BezierTargetThumb"===this.action||"ConnectorTargetEnd"===this.action||-1!==this.action.indexOf("Rotate")||-1!==this.action.indexOf("Resize")?(s=this.diagram.selectedItems,!this.diagram.currentSymbol&&"Drag"===this.action&&s&&this.diagram.selectedItems.nodes.length>0&&"SwimLane"===this.diagram.selectedItems.nodes[0].shape.type&&(o=this.diagram.findObjectsUnderMouse(this.currentPosition),s=this.diagram.findObjectUnderMouse(o,this.action,this.inAction))):(o=this.diagram.findObjectsUnderMouse(this.currentPosition),s=this.diagram.findObjectUnderMouse(o,this.action,this.inAction)),s&&s.isHeader&&(this.eventArgs.actualObject=s=this.diagram.nameTable[s.parentId]),s){var l=void 0,h=void 0,c=void 0;if(((a=this.diagram.findElementUnderMouse(s,this.currentPosition,this.diagram,r))&&s.ports&&s.ports.length&&!rb(s,a)||!a||!s)&&o&&o.length&&i instanceof ei)for(l=i.connectors[0],c=o.length-1;c>=0;c--)if(((h=o[parseInt(c.toString(),10)])instanceof te||h instanceof de)&&l&&l.connectionPadding){if(a=this.diagram.findElementUnderMouse(s=h,this.currentPosition,this.diagram,r),l.constraints&qe.ConnectToNearByPort&&s&&s.ports&&s.ports.length&&rb(s,a))break;if((h instanceof te||h instanceof de)&&l&&l.connectionPadding&&h.wrapper.outerBounds.containsPoint(this.currentPosition)&&l.constraints&qe.ConnectToNearByNode&&!(l.constraints&qe.ConnectToNearByPort)){a=this.diagram.findElementUnderMouse(s=h,this.currentPosition,this.diagram,0);break}}}return i?(e.target=s,e.targetWrapper=a):(e.source=s,e.sourceWrapper=a),e.actualObject=this.eventArgs.actualObject,e.source instanceof ei&&void 0===e.actualObject&&(e.source.nodes.length>0||e.source.connectors.length>0)&&(e.actualObject=e.source.nodes.length>0?this.diagram.nameTable[e.source.nodes[0].id]:this.diagram.nameTable[e.source.connectors[0].id]),e.startTouches=this.touchStartList,e.moveTouches=this.touchMoveList,e},n.prototype.resetTool=function(){this.action="Select",this.hoverElement=null,this.hoverNode=null,this.tool=this.diagram.getTool(this.action),this.updateCursor()},n.prototype.updateTool=function(){this.action=this.currentPosition&&"Pan"!==this.action?"Pan":"Select"},n.prototype.getTool=function(t){switch(t){case"Select":return new Jv(this.commandHandler,!0);case"Drag":return new fa(this.commandHandler);case"Rotate":return new Yx(this.commandHandler);case"LayoutAnimation":return new Lne(this.commandHandler);case"FixedUserHandle":return new Ane(this.commandHandler,!0);case"Hyperlink":return new X3(this.commandHandler);case"ResizeSouthEast":case"ResizeSouthWest":case"ResizeNorthEast":case"ResizeNorthWest":case"ResizeSouth":case"ResizeNorth":case"ResizeWest":case"ResizeEast":return new Pd(this.commandHandler,t);case"ConnectorSourceEnd":case"ConnectorTargetEnd":case"BezierSourceThumb":case"BezierTargetThumb":return new kd(this.commandHandler,t);case"SegmentEnd":case"OrthoThumb":return new ZF(this.commandHandler,t);case"Draw":var e="shape",i=function nse(n){var t;return n&&(n.type?t="Connector":n.shape&&!n.type&&(t="Node")),t}(this.diagram.drawingObject);if("Node"===i&&"Text"===this.diagram.drawingObject.shape.type)return new YI(this.commandHandler);if("Connector"===i&&"Freehand"===this.diagram.drawingObject.type)return new Pne(this.commandHandler);if("Node"===i&&"Polygon"===this.diagram.drawingObject.shape[""+e]&&!this.diagram.drawingObject.shape.points)return new zl(this.commandHandler);if("Node"===i||"Node"===i&&"Polygon"===this.diagram.drawingObject.shape[""+e]&&this.diagram.drawingObject.shape.points)return new WI(this.commandHandler,this.diagram.drawingObject);if("Connector"===i&&"Polyline"===this.diagram.drawingObject.type)return new Rl(this.commandHandler);if("Connector"===i)return new pa(this.commandHandler,"ConnectorSourceEnd",this.diagram.drawingObject);break;case"Pan":return new Kv(this.commandHandler,!1);case"PinchZoom":return new Kv(this.commandHandler,!0);case"PortDrag":return new fa(this.commandHandler,"Port");case"PortDraw":return new pa(this.commandHandler,"ConnectorSourceEnd",this.diagram.drawingObject);case"LabelSelect":return new Jv(this.commandHandler,!0,"LabelSelect");case"LabelDrag":return new Nne(this.commandHandler);case"LabelResizeSouthEast":case"LabelResizeSouthWest":case"LabelResizeNorthEast":case"LabelResizeNorthWest":case"LabelResizeSouth":case"LabelResizeNorth":case"LabelResizeWest":case"LabelResizeEast":return new One(this.commandHandler,t);case"LabelRotate":return new kne(this.commandHandler)}return null},n.prototype.getCursor=function(t){var e=this.diagram.selectedItems.annotation?this.diagram.selectedItems.wrapper.children[0]:this.diagram.selectedItems;return function Tne(n,t){if(t+=360,t%=360,-1===n.indexOf("Resize"))return Wx[""+n];var e=Wx[""+n];return t>=0&&t<25||t>=160&&t<=205||t>=340&&t<=360?e:t>=25&&t<=70||t>=205&&t<=250?"n-resize"===e||"s-resize"===e?"ne-resize":"nw-resize"===e||"se-resize"===e?"n-resize":"e-resize"===e||"w-resize"===e?"nw-resize":"e-resize":t>=70&&t<=115||t>=250&&t<=295?"n-resize"===e||"s-resize"===e?"e-resize":"nw-resize"===e||"se-resize"===e?"ne-resize":"e-resize"===e||"w-resize"===e?"n-resize":"nw-resize":t>=115&&t<=155||t>=295&&t<=340?"n-resize"===e||"s-resize"===e?"nw-resize":"nw-resize"===e||"se-resize"===e?"e-resize":"e-resize"===e||"w-resize"===e?"ne-resize":Wx[""+n]:"n-resize"}(t,this.diagram.selectedItems.annotation?e.rotateAngle+e.parentTransform:e.rotateAngle)},n.prototype.findElementUnderMouse=function(t,e,i,r){return this.objectFinder.findElementUnderSelectedItem(t,e,i,r)},n.prototype.findObjectsUnderMouse=function(t,e){return this.objectFinder.findObjectsUnderMouse(t,this.diagram,this.eventArgs,e)},n.prototype.findObjectUnderMouse=function(t,e,i){return this.objectFinder.findObjectUnderMouse(this.diagram,t,e,i,this.eventArgs,this.currentPosition)},n.prototype.findTargetUnderMouse=function(t,e,i,r,s){return this.objectFinder.findObjectUnderMouse(this.diagram,t,e,i,this.eventArgs,r,s)},n.prototype.findActionToBeDone=function(t,e,i,r){return function Mne(n,t,e,i,r,s,o){if(s&&s.length>1&&r&&r.length>1)return"PinchZoom";if(i.currentSymbol)return"Drag";if("PortDraw"===i.eventHandler.action&&(i.tool&=~ri.DrawOnce),(x3(i)||zI(i))&&i.drawingObject)return"Draw";if($a(i)&&(l=i.selectedItems).wrapper&&qr(l.constraints,"UserHandle"))for(var h=0,c=l.userHandles;h=50&&(l.x=(a.points[parseInt(h.toString(),10)].x+a.points[h+1].x)/2,l.y=(a.points[parseInt(h.toString(),10)].y+a.points[h+1].y)/2,wr(e,l,n.hitPadding?n.hitPadding:10)))return"OrthoThumb"}else NI(n)&&console.warn('[WARNING] :: Module "ConnectorEditing" is not available in Diagram component! You either misspelled the module name or forgot to load it.');return null}(g,l,e,i);if("OrthoThumb"===S)return S;if(qr(l.constraints,"ConnectorSourceThumb")&&AI(g)&&S||qr(l.constraints,"ConnectorTargetThumb")&&LI(g)&&S)return S}}else{var b=i.selectedItems.handleSize/2/i.scroller.currentZoom,M=10/i.scroller.currentZoom,w=Bi();qi(w,f.rotateAngle+f.parentTransform,f.offsetX,f.offsetY);var C=f.offsetX-f.pivot.x*f.actualSize.width,D=f.offsetY-f.pivot.y*f.actualSize.height,A={x:C+(.5===f.pivot.x?2*f.pivot.x:f.pivot.x)*f.actualSize.width/2,y:D-30/i.scroller.currentZoom};A=Ke(w,A);var x=!!i.selectedItems.annotation,P=!(!x||!OI(i.selectedItems.annotation));if(qr(l.constraints,"Rotate")&&wr(e,A,M)&&i.selectedItems.thumbsConstraints&bt.Rotate){if(x&&P)return"LabelRotate";if(!x)return"Rotate"}if(u.Inflate(b),u.containsPoint(e)&&(S=function wne(n,t,e,i,r,s){var o;return 1===n.selectedItems.nodes.length&&0===n.selectedItems.connectors.length&&n.selectedItems.nodes[0].container&&(o=function Dne(n,t,e,i,r){var s=10/n.scroller.currentZoom,o=n.selectedItems,a=t.actualSize.width,l=t.actualSize.height,h=new Ne(i,r,t.style.strokeWidth,l),c=new Ne(i+a,r,t.style.strokeWidth,l),d=new Ne(i,r,a,t.style.strokeWidth),u=new Ne(i,r+l,a,t.style.strokeWidth),f=Dn(n,n.selectedItems.nodes[0],!0)?n.nameTable[n.selectedItems.nodes[0].parentId]:n.selectedItems.nodes[0];if(ga(o.constraints,"ResizeEast",o.thumbsConstraints,o)&&c.containsPoint(e,s))return"ResizeEast";if(ga(o.constraints,"ResizeSouth",o.thumbsConstraints,o)&&u.containsPoint(e,s))return"ResizeSouth";if("Grid"!==f.container.type){if(ga(o.constraints,"ResizeWest",o.thumbsConstraints,o)&&h.containsPoint(e,s))return"ResizeWest";if(ga(o.constraints,"ResizeNorth",o.thumbsConstraints,o)&&d.containsPoint(e,s))return"ResizeNorth"}return null}(n,t,e,r,s)),!o&&(!n.selectedItems.nodes[0]||!n.selectedItems.nodes[0].isPhase&&!n.selectedItems.nodes[0].isLane&&"SwimLane"!==n.selectedItems.nodes[0].shape.type)&&(o=function xne(n,t,e,i,r,s){var o=40/n.scroller.currentZoom,a=n.selectedItems.handleSize/2/n.scroller.currentZoom,l=n.selectedItems,h=!!l.annotation;if(t.actualSize.width>=o&&t.actualSize.height>=o){if(ga(l.constraints,"ResizeSouthEast",l.thumbsConstraints,l)&&wr(e,Ke(i,{x:r+t.actualSize.width,y:s+t.actualSize.height}),a))return h?"LabelResizeSouthEast":"ResizeSouthEast";if(ga(l.constraints,"ResizeSouthWest",l.thumbsConstraints,l)&&wr(e,Ke(i,{x:r,y:s+t.actualSize.height}),a))return h?"LabelResizeSouthWest":"ResizeSouthWest";if(ga(l.constraints,"ResizeNorthEast",l.thumbsConstraints,l)&&wr(e,Ke(i,{x:r+t.actualSize.width,y:s}),a))return h?"LabelResizeNorthEast":"ResizeNorthEast";if(ga(l.constraints,"ResizeNorthWest",l.thumbsConstraints,l)&&wr(e,Ke(i,{x:r,y:s}),a))return h?"LabelResizeNorthWest":"ResizeNorthWest"}return ga(l.constraints,"ResizeEast",l.thumbsConstraints,l)&&wr(e,Ke(i,{x:r+t.actualSize.width,y:s+t.actualSize.height/2}),a)?h?"LabelResizeEast":"ResizeEast":ga(l.constraints,"ResizeWest",l.thumbsConstraints,l)&&wr(e,Ke(i,{x:r,y:s+t.actualSize.height/2}),a)?h?"LabelResizeWest":"ResizeWest":ga(l.constraints,"ResizeSouth",l.thumbsConstraints,l)&&wr(e,Ke(i,{x:r+t.actualSize.width/2,y:s+t.actualSize.height}),a)?h?"LabelResizeSouth":"ResizeSouth":ga(l.constraints,"ResizeNorth",l.thumbsConstraints,l)&&wr(e,Ke(i,{x:r+t.actualSize.width/2,y:s}),a)?h?"LabelResizeNorth":"ResizeNorth":null}(n,t,e,i,r,s)),o||null}(i,f,e,w,C,D),S))return S}}if(Lc(i)&&!n)return"Pan";if((o instanceof Es||o instanceof Tc)&&(!Lc(i)||_v(i)||Uv(i))&&(S=function Ene(n,t,e,i){if(Hx(t)&&(va(t,oi.Hover)||va(t,oi.Visible))){if(t.constraints&ai.Drag)return"PortDrag"}else if(Rx(t)&&(va(t,oi.Hover)||va(t,oi.Visible))&&t.constraints&ai.Draw){n.drawingObject={};var r={type:"Orthogonal",sourcePortID:t.id};return n.drawingObject=r,n.tool|=ri.DrawOnce,n.currentDrawingObject=r,"PortDraw"}return"None"}(i,o),"None"!==S))return S;if((o instanceof Kn||o instanceof Or)&&!Lc(i)&&xd(o))return _r(i,o,void 0,t)&&ro(o)?"LabelDrag":"LabelSelect";if(null!==n){if(!(n instanceof te||n instanceof de))return"Select";if(t&&t.id){var L=t.id.split(n.id)[1];if(L&&L.match("^_icon"))return"LayoutAnimation"}if(t&&t.id)for(var O=void 0,N=0;N-1)return"FixedUserHandle";if(t instanceof li&&t.hyperlink.link)return"Hyperlink";if(!ro(n)||!_r(i,n,!1)||void 0!==i.selectedItems.annotation)return n&&Lc(i)&&!RI(i)?"Pan":i.selectedItems.nodes.length&&i.selectedItems.nodes[0].isLane&&i.selectedItems.wrapper&&i.selectedItems.wrapper.bounds.containsPoint(e)?"Drag":"Select";if(n instanceof de&&!wr(e,n.sourcePoint,n.hitPadding)&&!wr(e,n.targetPoint,n.hitPadding)||!(n instanceof de))return"Drag"}return"Select"}(t,e,this.currentPosition,this.diagram,this.touchStartList,this.touchMoveList,r)},n.prototype.updateContainerBounds=function(t){var e=!1;if(this.diagram.selectedObject.helperObject&&this.diagram.selectedObject.actualObject)for(var i=this.diagram.selectedObject.actualObject,r=this.diagram.selectedObject.actualObject instanceof ei?i.nodes:[i],s=0;si.y&&(h+=u>0?-1:1,u+=u>0?-1:1):i&&e.wrapper.offsetYi.x&&(h+=u>0?-1:1,u+=u>0?-1:1):i&&e.wrapper.offsetX1)for(var S=t.offsetX-this.diagram.selectedItems.offsetX,b=t.offsetY-this.diagram.selectedItems.offsetY,M=t.rotateAngle-this.diagram.selectedItems.rotateAngle,w=0;w-1){var A=c.children;A.splice(A.indexOf(o.id),1),this.diagram.nameTable[o.id].parentId="",i=!0,c.wrapper.children.splice(D,1)}}if(function bne(n,t,e,i){var r=n,s=e.nameTable[r.parentId],o=e.nameTable[r.parentId];if(t&&o&&o.container&&"Stack"===o.container.type&&t.container&&"Stack"===t.container.type&&o.id!==t.parentId){var a=o.wrapper.children.indexOf(r.wrapper);a>-1&&(e.nameTable[r.id].parentId=t.id,o.wrapper.children.splice(a,1))}if(t&&t.parentId&&r.parentId&&"Drag"===i&&o.container&&"Stack"===o.container.type){var l=s.wrapper.children.indexOf(t.wrapper),h=s.wrapper.children.indexOf(r.wrapper),c={targetIndex:l,target:t,sourceIndex:h,source:n};s.wrapper.children.splice(h,1),s.wrapper.children.splice(l,0,r.wrapper),e.commandHandler.addHistoryEntry({type:"StackChildPositionChanged",redoObject:{targetIndex:h,target:t,sourceIndex:l,source:n},undoObject:c,category:"Internal"})}}(o,h,this.diagram,this.action),(c=Dn(this.diagram,o)?this.diagram.nameTable[o.parentId]:this.diagram.nameTable[o.parentId]||o)&&c.container&&"Canvas"===c.container.type&&(c.wrapper.maxWidth=c.maxWidth=c.wrapper.actualSize.width,c.wrapper.maxHeight=c.maxHeight=c.wrapper.actualSize.height,e=!0),Dn(this.diagram,o,!0)&&c&&"Canvas"===c.container.type)if(this.diagram.selectedItems.nodes.length>1)for(w=0;w0)for(var i=0;i0&&e.columnIndex>0||l&&e.isLane)){if("Horizontal"===t.container.orientation&&e.isPhase&&e.wrapper.width>e.maxWidth&&(e.maxWidth=e.wrapper.width,e.wrapper.maxWidth=e.wrapper.width),h.updateColumnWidth(e.columnIndex,r.width,!0,c),_x(this.diagram,e,t),e.isPhase){var p=this.diagram.nameTable[""+t.shape.phases[e.columnIndex].header.id];p.maxWidth0?(r=new rp(t,"",u),t.shape.classShape.attributes.push(r)):i.id.includes("_umlMethods")&&t.shape.classShape.methods.length>0&&(s=new cm(t,"",u),t.shape.classShape.methods.push(s))),"Interface"===t.shape.classifier&&(i.id.includes("_umlProperty")&&t.shape.interfaceShape.attributes.length>0?(r=new rp(t,"",u),t.shape.classShape.attributes.push(r)):i.id.includes("_umlMethods")&&t.shape.interfaceShape.methods.length>0&&(s=new cm(t,"",u),t.shape.interfaceShape.methods.push(s))),"Enumeration"===t.shape.classifier&&i.id.includes("_umlMember")&&t.shape.enumerationShape.members.length>0){var f=new ob(t,"",u);t.shape.enumerationShape.members.push(f)}t.wrapper.children.indexOf(c.wrapper),this.diagram.enableServerDataBinding(!0),this.diagram.add(c),this.diagram.updateConnectorEdges(t),this.diagram.clearSelection(),this.diagram.select([this.diagram.nameTable[c.id]]),this.diagram.endGroupAction(),this.diagram.startTextEdit()}}},n}(),_oe=function(){function n(){}return n.prototype.findObjectsUnderMouse=function(t,e,i,r,s){var o=[];r&&r instanceof ei&&r.nodes.length+r.connectors.length===1&&(r=r.nodes[0]||r.connectors[0]).children&&0===r.children.length&&(i.actualObject=r);for(var a,l,h,c,p,d=r&&r instanceof de&&(r.constraints&qe.ConnectToNearByNode||r.constraints&qe.ConnectToNearByPort)&&r.connectionPadding||0,f={},g=0,v=e.spatialSearch.findObjects(new Ne(t.x-50-d,t.y-50-d,100+d,100+d));g-1&&o.splice(T,1),"UmlClassifier"===y.shape.type&&y.container&&"Stack"===y.container.type&&(T=o.indexOf(e.nameTable[e.nameTable[y.id].wrapper.children[0].id]))>-1&&o.splice(T,1)}for(var z=0;zs.zIndex&&(t[parseInt(r.toString(),10)]=l),r>0&&i&&a&&(a.isLane||a.isPhase||a.isHeader)&&t[parseInt(r.toString(),10)].zIndex=2)for(var d=t.length-1;d>=0;d--)if(t[parseInt(d.toString(),10)].parentId){var u=om(t[parseInt(d.toString(),10)],e,""),f=om(t[d-1],e,""),g=e.nameTable[""+f];g&&u!==f&&e.nameTable[""+u].zIndex=0;p--){d=Kf(e[parseInt(p.toString(),10)],!1),c=Kf(e[parseInt(p.toString(),10)],!0);var g=t[""+l].tool,v=this.findTargetElement(e[parseInt(p.toString(),10)].wrapper,o,t,void 0);if("Draw"===i&&v&&(e[parseInt(p.toString(),10)]instanceof te||e[parseInt(p.toString(),10)]instanceof de)&&!rb(e[parseInt(p.toString(),10)],v)&&(g&&"ConnectorSourceEnd"===g[""+h]&&!Ph(e[parseInt(p.toString(),10)])||g&&"ConnectorTargetEnd"===g[""+h]&&!ua(e[parseInt(p.toString(),10)])))return u;if(e[parseInt(p.toString(),10)]instanceof te||e[parseInt(p.toString(),10)]instanceof de&&(Ph(e[parseInt(p.toString(),10)])||Td(d)||ua(e[parseInt(p.toString(),10)])||kh(c)||"PortDraw"===i&&g instanceof kd&&"ConnectorTargetEnd"===g[""+h]&&(ua(e[parseInt(p.toString(),10)])||kh(c))))return u=e[parseInt(p.toString(),10)],f&&(u=this.isTarget(u,t,i)),s.actualObject=u,u}else if("ConnectorTargetEnd"===i&&a){for(p=e.length-1;p>=0;p--)if(c=Kf(e[parseInt(p.toString(),10)],!0),(e[parseInt(p.toString(),10)]instanceof te||e[parseInt(p.toString(),10)]instanceof de)&&(ua(e[parseInt(p.toString(),10)])||kh(c)))return u=e[parseInt(p.toString(),10)],u=this.isTarget(u,t,i),s.actualObject=u,u}else{if(a&&("Drag"===i||t[""+l].tool instanceof fa)){var y=0;for(p=0;p=S.zIndex?u:S,y=Math.max(y,S.zIndex)):y=(u=S).zIndex)}return u&&"Bpmn"===u.shape.type&&(t.selectedItems.nodes.length>0&&"Bpmn"===t.selectedItems.nodes[0].shape.type||(u=null)),u&&(s.actualObject=u),u}if("Select"!==i&&"Pan"!==i||!t[""+l].tool)if("Pan"===i||"LayoutAnimation"===i){for(p=e.length-1;p>=0;p--)if((e[parseInt(p.toString(),10)]instanceof te||e[parseInt(p.toString(),10)]instanceof de)&&(v=this.findTargetElement(e[parseInt(p.toString(),10)].wrapper,o,t,void 0),"Pan"===i||v&&(v.id.match("_icon_content_shape$")||v.id.match("_icon_content_rect$"))))return e[parseInt(p.toString(),10)]}else u=e[e.length-1],s&&u&&(s.actualObject=u);else{for(p=e.length-1;p>=0;p--)if(e[parseInt(p.toString(),10)]instanceof de){var b=e[p-1];if(e[p-1]instanceof te&&b.ports){if((v=this.findTargetElement(b.wrapper,o,t,void 0))&&(v.id.match("_icon_content_shape$")||v.id.match("_icon_content_rect$")))return b;for(var M=0;M=0;s--){var o=t.children[parseInt(s.toString(),10)];if(o&&o.outerBounds.containsPoint(e,r||0))if(o.visible){if(o instanceof Cs){var a=this.findTargetElement(o,e,i);if(a)return a}var l="Clip"===o.style.textOverflow||"Ellipsis"===o.style.textOverflow;if(o.bounds.containsPoint(e,r||0)&&!l)return o;if(t.bounds.containsPoint(e,r||0)&&l)return o}else if(o instanceof Ze&&t&&t.id){var h=void 0;if(t.id.includes("group_container")){var c=t.id.slice(0,-15);h=i.getObject(c)}else h=i.getObject(t.id);if(tb(h,o.id))return o}}return t.bounds.containsPoint(e,r)&&"none"!==t.style.fill?t:null},n}(),Uoe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),sp=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},JF=function(n){function t(e,i,r,s){var o=n.call(this,e,i,r,s)||this;return o.objectZIndex=-1,o.zIndexTable={},o.objects=[],o}return Uoe(t,n),sp([I("")],t.prototype,"id",void 0),sp([I(!0)],t.prototype,"visible",void 0),sp([I(!1)],t.prototype,"lock",void 0),sp([I()],t.prototype,"objects",void 0),sp([I()],t.prototype,"addInfo",void 0),sp([I(-1)],t.prototype,"zIndex",void 0),t}(Ee),MT=function(n,t,e,i){return new(e||(e=Promise))(function(r,s){function o(h){try{l(i.next(h))}catch(c){s(c)}}function a(h){try{l(i.throw(h))}catch(c){s(c)}}function l(h){h.done?r(h.value):new e(function(c){c(h.value)}).then(o,a)}l((i=i.apply(n,t||[])).next())})},wT=function(n,t){var i,r,s,o,e={label:0,sent:function(){if(1&s[0])throw s[1];return s[1]},trys:[],ops:[]};return o={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function a(h){return function(c){return function l(h){if(i)throw new TypeError("Generator is already executing.");for(;e;)try{if(i=1,r&&(s=2&h[0]?r.return:h[0]?r.throw||((s=r.return)&&s.call(r),0):r.next)&&!(s=s.call(r,h[1])).done)return s;switch(r=0,s&&(h=[2&h[0],s.value]),h[0]){case 0:case 1:s=h;break;case 4:return e.label++,{value:h[1],done:!1};case 5:e.label++,r=h[1],h=[0];continue;case 7:h=e.ops.pop(),e.trys.pop();continue;default:if(!(s=(s=e.trys).length>0&&s[s.length-1])&&(6===h[0]||2===h[0])){e=0;continue}if(3===h[0]&&(!s||h[1]>s[0]&&h[1]1)for(var i=0;i-1)return e[parseInt(i.toString(),10)];return this.diagram.activeLayer},n.prototype.getLayer=function(t){for(var e=this.diagram.layers,i=0;i=0;o--)this.diagram.unSelect(this.diagram.nameTable[s[parseInt(o.toString(),10)]]),this.diagram.remove(this.diagram.nameTable[s[parseInt(o.toString(),10)]]),"default_layer"!==i.id&&this.diagram.activeLayer.id===t&&(this.diagram.activeLayer=this.diagram.layers[this.diagram.layers.length-1]);delete this.diagram.layerZIndexTable[i.zIndex],this.diagram.layers.splice(r,1),"SVG"!==this.diagram.mode&&this.diagram.refreshDiagramLayer()}},n.prototype.moveObjects=function(t,e){this.diagram.startGroupAction();for(var i={},r=[],s=0;s-1){if(r=[],(h=this.diagram.nameTable[""+s]).children)for(var p=0,g=h.children;p0){for(var y=void 0,S=0,b=r;S0)for(var r=0;r0)for(r=0;r0){t=t.concat(this.diagram.selectedItems.connectors);for(var i=0;i0)for(t=t.concat(this.diagram.selectedItems.nodes),i=0;i0){for(var i=0,r=t.shape.activity.subProcess.processes;i0&&this.copyProcesses(this.processTable[""+s])}this.clipboardData.processTable=this.processTable}},n.prototype.group=function(){this.oldSelectedObjects=nm(this.diagram);var e=this.diagram.isProtectedOnChange;this.diagram.protectPropertyChange(!0),this.diagram.diagramActions=this.diagram.diagramActions|ee.Group;var r={};r.id="group"+Qe(),(r=new te(this.diagram,"nodes",r,!0)).children=[];for(var s=this.diagram.selectedItems.nodes.concat(this.diagram.selectedItems.connectors).sort(function(h,c){return h.zIndex-c.zIndex}),o=0;o0){var a=this.diagram.add(r);a&&this.select(a),this.addHistoryEntry({type:"Group",undoObject:r,redoObject:r,category:"Internal"}),this.diagram.diagramActions=this.diagram.diagramActions&~ee.Group,this.diagram.protectPropertyChange(e)}},n.prototype.unGroup=function(t){var i=this.diagram.isProtectedOnChange;this.diagram.protectPropertyChange(!0),this.diagram.diagramActions=this.diagram.diagramActions|ee.Group;var r=[];t?r.push(t):r=this.diagram.selectedItems.nodes,this.diagram.startGroupAction();for(var s=0;s0&&this.diagram.removePorts(o,o.ports),o.annotations&&o.annotations.length>0&&!ce()&&this.diagram.removeLabels(o,o.annotations);for(var c=this.diagram.nameTable[o.parentId],d=o.children.length-1;d>=0;d--)this.diagram.nameTable[o.children[parseInt(d.toString(),10)]].parentId="",this.diagram.deleteChild(this.diagram.nameTable[o.children[parseInt(d.toString(),10)]],o),o.parentId&&o.children[parseInt(d.toString(),10)]&&this.diagram.addChild(c,o.children[parseInt(d.toString(),10)]);this.resetDependentConnectors(o.inEdges,!0),this.resetDependentConnectors(o.outEdges,!1),this.diagram.diagramActions&ee.UndoRedo||this.addHistoryEntry({type:"UnGroup",undoObject:a,redoObject:a,category:"Internal"}),o.parentId&&this.diagram.deleteChild(o,c)}this.diagram.removeNode(o,l),this.clearSelection()}this.diagram.endGroupAction(),this.diagram.diagramActions=this.diagram.diagramActions&~ee.Group,this.diagram.protectPropertyChange(i)},n.prototype.resetDependentConnectors=function(t,e){for(var i=0;i0&&(g=!1)}if(g){var y=this.cloneConnector(f,i);c.push(y),o[h.id]=y.id}}else{var S=this.cloneNode(h,i);if(c.push(S),S){o[h.id]=S.id;var b=h.inEdges;if(b)for(var M=0,w=b;M0)for(var u=0;u0)for(r=t.segments,s=0;s0&&this.diagram.drawingObject&&"Bezier"===this.diagram.drawingObject.type&&(t.segments=[]);var e=this.diagram.add(t);"SVG"!==this.diagram.mode&&this.diagram.refreshDiagramLayer(),this.selectObjects([e]),t&&!zI(this.diagram)&&(this.diagram.tool&=~ri.DrawOnce,this.diagram.currentDrawingObject=void 0)},n.prototype.enableServerDataBinding=function(t){this.diagram.enableServerDataBinding(t)},n.prototype.addText=function(t,e){var i=this.diagram.findElementUnderMouse(t,e,this.diagram);this.diagram.startTextEdit(t,i instanceof li?i.id.split("_")[1]:void 0)},n.prototype.isUserHandle=function(t){var e=this.diagram.selectedItems;if(e.wrapper&&qr(e.constraints,"UserHandle"))for(var i=0,r=e.userHandles;i0&&t[0]&&t[0].isLane)for(s=this.diagram.getObject(t[0].parentId),t[0].shape.header=[],a=0;a1||e&&1===t.length)){if(1!==t.length)return[2];this.clearSelection()}if(!(u||d||1!==t.length||e&&$a(this.diagram)))return this.clearSelection(),[2]}if(!r.cancel){for(f=0;f0||e)&&p.children&&!p.parentId)for(g=0;g0||e,!0)}else this.select(p,f>0||e,!0);void 0===i&&(i=c),r={oldValue:i||[],newValue:this.getSelectedObject(),cause:this.diagram.diagramActions,state:"Changed",type:"Addition",cancel:!1},this.diagram.renderSelector(e||t&&t.length>1),ce()||this.diagram.triggerEvent(Ce.selectionChange,r),this.diagram.enableServerDataBinding(!0)}return[2]})})},n.prototype.findParent=function(t){return t.parentId&&this.findParent(t=this.diagram.nameTable[t.parentId]),t},n.prototype.selectProcesses=function(t){if(this.hasProcesses(t))for(var e=t.shape.activity.subProcess.processes,i=0;i0)},n.prototype.select=function(t,e,i){var r=this.getObjectLayer(t.id);if(xd(t)&&!(t instanceof ei)&&!_r(this.diagram,t)&&r&&!r.lock&&r.visible&&t.wrapper.visible){(e=!!$a(this.diagram)&&e)||this.clearSelection(),this.diagram.enableServerDataBinding(!1);var s=this.diagram.selectedItems;if(t instanceof te?s.nodes.push(t.isHeader?this.diagram.nameTable[t.parentId]:t):s.connectors.push(t),s.selectedObjects.push(t),e)s.wrapper.rotateAngle=s.rotateAngle=0,s.wrapper.children.push(t.wrapper);else if(s.init(this.diagram),1===s.nodes.length&&0===s.connectors.length){var l=Ux(this.diagram,s);l&&(s.wrapper.children[0]=l),s.rotateAngle=s.nodes[0].rotateAngle,s.wrapper.rotateAngle=s.nodes[0].rotateAngle,s.wrapper.pivot=s.nodes[0].pivot}i||this.diagram.renderSelector(e),this.diagram.enableServerDataBinding(!0)}},n.prototype.labelSelect=function(t,e){this.oldSelectedObjects=nm(this.diagram);var i=this.diagram.selectedItems,r=this.diagram.allowServerDataBinding;this.diagram.allowServerDataBinding=!1,i.nodes=i.connectors=[],this.diagram.allowServerDataBinding=r,t instanceof te?i.nodes[0]=t:i.connectors[0]=t,i.annotation=this.findTarget(e,t),i.init(this.diagram),this.diagram.renderSelector(!1)},n.prototype.unSelect=function(t){var e=this.diagram.selectedItems.nodes.concat(this.diagram.selectedItems.connectors),i=e.filter(function(a){return a.id!==t.id}),r={oldValue:e,newValue:i,cause:this.diagram.diagramActions,state:"Changing",type:"Removal",cancel:!1};if(this.diagram.currentSymbol||ce()||this.diagram.triggerEvent(Ce.selectionChange,r),_r(this.diagram,t)){var s=this.diagram.selectedItems,o=void 0;t instanceof te?(o=s.nodes.indexOf(t,0),s.nodes.splice(o,1)):(o=s.connectors.indexOf(t,0),s.connectors.splice(o,1)),o=s.selectedObjects.indexOf(t,0),s.selectedObjects.splice(o,1),(r={oldValue:e,newValue:i,cause:this.diagram.diagramActions,state:"Changed",type:"Removal",cancel:(r={oldValue:e,newValue:i,cause:this.diagram.diagramActions,state:"Changed",type:"Removal",cancel:!1}).cancel}).cancel||(o=s.wrapper.children.indexOf(t.wrapper,0),s.wrapper.children.splice(o,1),this.diagram.updateSelector(),this.diagram.currentSymbol||this.diagram.triggerEvent(Ce.selectionChange,r))}},n.prototype.moveSvgNode=function(t,e){var i=this.diagram.nameTable[""+e];if("Native"===i.shape.type||"HTML"===i.shape.type)this.updateNativeNodeIndex(t,e);else{var r=xt(e+"_groupElement",this.diagram.element.id),s=xt(t+"_groupElement",this.diagram.element.id);r.parentNode.insertBefore(s,r)}},n.prototype.moveAfterSvgNode=function(t,e){var i=this.diagram.nameTable[""+e];if(!i||"HTML"!==i.shape.type&&"Native"!==i.shape.type)a=xt(e+"_groupElement",this.diagram.element.id),o=xt(t+"_groupElement",this.diagram.element.id),a.insertAdjacentElement("afterend",o);else for(var r=0;rd&&"SwimLane"!==p.shape.type){var S=$(p);p.zIndex=d-((-1!==i.indexOf(p)?i.indexOf(p):0)+1),p.children&&(d=this.findLowestZIndex(p,c)||d),this.triggerOrderCommand(S,p,p),p.children&&this.updateGroupZindex(p,"SendToBack",d)}else"SwimLane"===p.shape.type&&(y=this.swapZIndexObjects(a,h,r,g));if("SVG"===this.diagram.mode){for(var M="SwimLane"!==this.diagram.nameTable[""+r].shape.type?d:y,w=h[parseInt(M.toString(),10)];!w&&Md)&&(d=f.zIndex)}for(var p=JSON.parse(JSON.stringify(l)),v=Number(Object.keys(l).sort(function(wo,Ul){return Number(wo)-Number(Ul)}).reverse()[0]),y=this.diagram.nameTable[""+e].zIndex,S=[],M=0;M<=v;M++)S.push(l[parseInt(M.toString(),10)]);if("SwimLane"===this.diagram.nameTable[""+e].shape.type)for(var C=v;C>=y;C--)if(l[parseInt(C.toString(),10)]&&this.diagram.nameTable[l[parseInt(C.toString(),10)]].parentId!==e){v=C;break}var D=this.diagram.nameTable[""+e];if(D.zIndexx&&(x=L.zIndex)}}else x=d;D.zIndex=x+((-1!==r.indexOf(D)?r.indexOf(D):0)+1),this.triggerOrderCommand(A,D,D)}else if("SwimLane"===D.shape.type){for(var O=0,N=-1,T=0,z=0,U=JSON.parse(JSON.stringify(l)),B=0;B<=y;B++)if(l[parseInt(B.toString(),10)]&&this.diagram.nameTable[l[parseInt(B.toString(),10)]].parentId===e&&-1===N){N=B,T=B;break}for(var j=0;j<=v;j++)p[parseInt(j.toString(),10)]&&p[parseInt(j.toString(),10)]!==e&&this.diagram.nameTable[p[parseInt(j.toString(),10)]].parentId!==e&&this.diagram.nameTable[p[parseInt(j.toString(),10)]].zIndex>=this.diagram.nameTable[""+e].zIndex&&O++;for(var ue=N,fe=0;fe<=O;fe++){for(;!l[parseInt(ue.toString(),10)];)ue++;z=this.diagram.nameTable[l[parseInt(ue.toString(),10)]].zIndex,ue++}for(var Me=z;Me<=v;Me++){for(;!U[parseInt(N.toString(),10)];)N++;for(;!l[parseInt(Me.toString(),10)];)Me++;l[parseInt(Me.toString(),10)]=U[parseInt(N.toString(),10)],this.diagram.nameTable[l[parseInt(Me.toString(),10)]].zIndex=Me,N++}l[parseInt(v.toString(),10)]=this.diagram.nameTable[""+e].id,this.diagram.nameTable[""+e].zIndex=v,ue=y+1;for(var De=T,xe=0;xe0&&("Native"===hr[0].shape.type||"HTML"===hr[0].shape.type)){for(Ci.parentNode.removeChild(Ci),De=0;De0?r[0]:null},n.prototype.findLowestZIndex=function(t,e){var r=this.diagram.nodes.filter(function(s){return-1!==e.indexOf(s.id)}).filter(function(s){return""===s.parentId&&s.id!==t.id}).map(function(s){return s.zIndex});return r.sort(function(s,o){return s-o}),r.length>0?r[0]:null},n.prototype.triggerOrderCommand=function(t,e,i){var s={zIndex:$(t).zIndex},o={zIndex:e.zIndex},a={element:i,cause:this.diagram.diagramActions,diagramAction:this.diagram.getDiagramAction(this.diagram.diagramActions),oldValue:s,newValue:o};this.diagram.triggerEvent(Ce.propertyChange,a)},n.prototype.checkGroupNode=function(t,e,i){return i[""+e].parentId===i[""+t].parentId},n.prototype.sortByZIndex=function(t,e,i){if("BringForward"===i){var r=e||"zIndex";t=t.sort(function(o,a){return a[""+r]-o[""+r]})}else{var s=e||"zIndex";t=t.sort(function(o,a){return o[""+s]-a[""+s]})}return t},n.prototype.orderCommands=function(t,e,i){var r=this,s=e.nodes;if(s=s.concat(e.connectors),t)if("SendBackward"===i)for(var o=0;oa}),S=v.filter(function(D){return D0?Math.max.apply(Math,S):a,M=y.length>0?Math.min.apply(Math,y):a;if(a!==M){var w=c.zIndexTable[parseInt(M.toString(),10)],C=c.zIndexTable[parseInt(a.toString(),10)];this.moveSvgNode(C,w)}else"SendToBack"===i&&(w=c.zIndexTable[parseInt(a.toString(),10)],C=c.zIndexTable[parseInt(b.toString(),10)],this.moveAfterSvgNode(w,C))}}else this.diagram.refreshCanvasLayers()}},n.prototype.swapDomOrder=function(t,e){if(t){var i=this.diagram.getObject(e);if("Native"===i.shape.type||"HTML"===i.shape.type)this.updateNativeNodeIndex(e,t),this.updateNativeNodeIndex(t,e);else{var r=xt(e+"_groupElement",this.diagram.element.id),s=xt(t+"_groupElement",this.diagram.element.id);r.parentNode.insertBefore(r,s),r.parentNode.insertBefore(s,r)}}},n.prototype.sendForward=function(t){var e=this;if(this.diagram.protectPropertyChange(!0),$a(this.diagram)||t){$(t||(this.diagram.selectedItems.nodes.length?this.diagram.selectedItems.nodes[0]:this.diagram.selectedItems.connectors[0]));var s=t&&t.id,o=this.diagram.layers.indexOf(this.getObjectLayer(s=s||(this.diagram.selectedItems.nodes.length?this.diagram.selectedItems.nodes[0].id:this.diagram.selectedItems.connectors[0].id))),a=$(this.diagram.nameTable),h=(parseInt(o.toString(),10),this.diagram.nameTable[""+s]),c=[],d=this.diagram.spatialSearch.findObjects(h.wrapper.bounds);d.length>2&&(d=this.sortByZIndex(d,void 0,"BringForward"));for(var u=0,f=d;u=0;p--)this.diagram.nameTable[c[parseInt(p.toString(),10)].id].parentId===s&&c.splice(p,1);if(c.length>0){var y=this.diagram.nameTable[c[c.length-1].id];if(y.parentId){var b=om(y,this.diagram,""),M=this.diagram.nameTable[""+b];M.id!==s&&(c[0]=M)}var w={};for(p=0;p0&&(Object.values(O).forEach(function(ue){ue>=T&&N.push(ue)}),0!==N.length&&this.updateZIndexBySendForward(h,N,o))}var z=[];if(Object.keys(this.changedNodeZIndexes).forEach(function(ue){if((a[""+ue]?a[""+ue].zIndex:null)!==e.changedNodeZIndexes[""+ue]){var De=$(a[""+ue]);z.push(De)}}),this.updateLayerZindexTable(o),L.nodes.splice(0,L.nodes.length),z.forEach(function(ue){var fe=$(ue);L.nodes.push(fe)}),"SVG"===this.diagram.mode){var U=c[c.length-1].id,B=c[c.length-1];B&&!("HTML"===B.shape.type||"Native"===B.shape.type)&&this.moveAfterSvgNode(s,U),this.updateNativeNodeIndex(U,s)}else this.diagram.refreshCanvasLayers();var j=[];Object.keys(this.changedNodeZIndexes).forEach(function(ue){if((a[""+ue]?a[""+ue].zIndex:null)!==e.changedNodeZIndexes[""+ue]){var De=$(e.diagram.nameTable[""+ue]);j.push(De)}});var Q=$(this.diagram.selectedItems);Q.nodes.splice(0,Q.nodes.length),j.forEach(function(ue){var fe=$(ue);Q.nodes.push(fe)}),this.diagram.diagramActions&ee.UndoRedo||this.addHistoryEntry({type:"SendForward",category:"Internal",undoObject:L,redoObject:Q}),this.diagram.endGroupAction()}}this.diagram.protectPropertyChange(!1)},n.prototype.updateZIndexBySendForward=function(t,e,i){var r=$(t);t.zIndex=Math.min.apply(Math,e);var a,s=Math.min.apply(Math,e),o=Math.min.apply(Math,e),l=this.diagram.layers[parseInt(i.toString(),10)].objects,h=this.diagram.nodes.filter(function(S){return-1!==l.indexOf(S.id)});t.children&&this.updateGroupZindex(t,"BringForward",t.zIndex);var c=h.filter(function(S){return S.zIndex===Math.min.apply(Math,e)&&S.id!==t.id});if(c&&c.length>0&&c[0].children){for(var d=Math.min.apply(Math,e),u=0;uo&&g!==t&&g.parentId!==t.id&&c&&c.length>0&&g.parentId!==c[0].id){var v=$(g);g.zIndex=a+1,a++,this.triggerOrderCommand(v,g,g)}var y=g.zIndex;this.changedNodeZIndexes[g.id]=(this.changedNodeZIndexes.hasOwnProperty(g.id),y)}},n.prototype.arrangeZIndexForLowerNodes=function(t,e,i){var r=i.filter(function(o){return o.zIndex<=t&&o.parentId!==e.id});r.sort(function(o,a){return a.zIndex-o.zIndex});for(var s=0;se&&(e=r.zIndex)}return e},n.prototype.sendBackward=function(t){var e=this;if(this.diagram.protectPropertyChange(!0),$a(this.diagram)||t){$(t||(this.diagram.selectedItems.nodes.length?this.diagram.selectedItems.nodes[0]:this.diagram.selectedItems.connectors[0]));var s=t&&t.id,o=this.diagram.layers.indexOf(this.getObjectLayer(s=s||(this.diagram.selectedItems.nodes.length?this.diagram.selectedItems.nodes[0].id:this.diagram.selectedItems.connectors[0].id))),a=$(this.diagram.nameTable),h=(parseInt(o.toString(),10),this.diagram.nameTable[""+s]),c=[],d=this.diagram.spatialSearch.findObjects(h.wrapper.bounds);d.length>2&&(d=this.sortByZIndex(d));for(var u=0,f=d;uNumber(p.zIndex)&&""===p.parentId&&h.wrapper.bounds.intersects(p.wrapper.bounds)&&c.push(p);for(var p=c.length-1;p>=0;p--)(v=this.diagram.nameTable[c[parseInt(p.toString(),10)].id]).parentId===s&&c.splice(p,1);if(c.length>0){var v;if((v=this.diagram.nameTable[c[c.length-1].id]).parentId){var S=om(v,this.diagram,""),b=this.diagram.nameTable[""+S];s!==b.id&&(c[c.length-1]=b)}var M={};for(p=0;p0&&(Object.values(L).forEach(function(fe){fe<=N&&O.push(fe)}),0!==O.length&&this.updateZIndexBySendBackward(h,O,o))}var T=[];if(Object.keys(this.changedNodeZIndexes).forEach(function(fe){if((a[""+fe]?a[""+fe].zIndex:null)!==e.changedNodeZIndexes[""+fe]){var xe=$(a[""+fe]);T.push(xe)}}),this.updateLayerZindexTable(o),P.nodes.splice(0,P.nodes.length),T.forEach(function(fe){var Me=$(fe);P.nodes.push(Me)}),"SVG"===this.diagram.mode){var z=c[c.length-1].id,U=c[c.length-1];U&&"HTML"!==U.shape.type&&"Native"!==U.shape.type&&this.moveSvgNode(s,z);var B=this.diagram.nameTable[""+z];B.children&&B.children.length>0?this.updateNativeNodeIndex(s):this.updateNativeNodeIndex(s,z)}else this.diagram.refreshCanvasLayers();var j=[];Object.keys(this.changedNodeZIndexes).forEach(function(fe){if((a[""+fe]?a[""+fe].zIndex:null)!==e.changedNodeZIndexes[""+fe]){var xe=$(e.diagram.nameTable[""+fe]);j.push(xe)}});var Q=$(this.diagram.selectedItems);Q.nodes.splice(0,Q.nodes.length),j.forEach(function(fe){var Me=$(fe);Q.nodes.push(Me)}),this.diagram.diagramActions&ee.UndoRedo||this.addHistoryEntry({type:"SendBackward",category:"Internal",undoObject:P,redoObject:Q}),this.diagram.endGroupAction()}}this.diagram.protectPropertyChange(!1)},n.prototype.updateZIndexBySendBackward=function(t,e,i){var r=$(t);t.zIndex=Math.max.apply(Math,e);var f,s=t.zIndex,o=Math.max.apply(Math,e),a=this.diagram.layers[parseInt(i.toString(),10)].objects,l=this.diagram.nodes.filter(function(S){return-1!==a.indexOf(S.id)}),h=l.filter(function(S){return S.zIndex===Math.max.apply(Math,e)&&S.id!==t.id});if(h&&h.length>0&&h[0].children)for(var c=Math.max.apply(Math,e),d=0;d0&&g.parentId!==h[0].id){var v=$(g);g.zIndex=f-1,f--,this.triggerOrderCommand(v,g,g)}var y=g.zIndex;this.changedNodeZIndexes[""+g.id]=(this.changedNodeZIndexes.hasOwnProperty(g.id),y)}},n.prototype.findLowestChildZIndex=function(t){for(var e=t.zIndex,i=0;i0),this.selectObjects([t],!0))},n.prototype.clearSelection=function(t,e){return MT(this,void 0,void 0,function(){var i,r,s,o;return wT(this,function(a){return i=this.diagram.allowServerDataBinding,this.diagram.enableServerDataBinding(!1),$a(this.diagram)&&(r=this.diagram.selectedItems,s=this.getSelectedObject(),this.diagram.currentSymbol&&(this.diagram.previousSelectedObject=s),o={oldValue:s,newValue:[],cause:this.diagram.diagramActions,state:"Changing",type:"Removal",cancel:!1},t&&(ce()||this.diagram.triggerEvent(Ce.selectionChange,o)),o.cancel||(r.offsetX=0,r.offsetY=0,r.width=0,r.height=0,r.rotateAngle=0,r.nodes=[],r.connectors=[],r.wrapper=null,r.annotation=void 0,r.selectedObjects=[],this.diagram.clearSelectorLayer(),t&&(o={oldValue:s,newValue:[],cause:this.diagram.diagramActions,state:"Changed",type:"Removal",cancel:!1},ce()||this.diagram.triggerEvent(Ce.selectionChange,o))),this.diagram.enableServerDataBinding(i)),[2]})})},n.prototype.clearSelectedItems=function(){this.clearSelection((this.diagram.selectedItems.nodes?this.diagram.selectedItems.nodes.length:0)+(this.diagram.selectedItems.connectors?this.diagram.selectedItems.connectors.length:0)>0)},n.prototype.removeStackHighlighter=function(){var t=Bl(this.diagram.element.id),e=t.getElementById(t.id+"_stack_highlighter");e&&e.parentNode.removeChild(e)},n.prototype.renderStackHighlighter=function(t,e){var r,s,o,i=this.diagram.selectedItems.nodes[0];if(!e){var a=this.diagram.findObjectsUnderMouse(t.position);if((e=this.diagram.findObjectUnderMouse(a,"Drag",!0))&&!(e.isLane||e.isPhase||e.isHeader))for(var l=0;l0)for(var a=0;a1)if(i){var h=l.segments[0],c=l.segments[1],u=Nl(CI(t.wrapper,t.wrapper.corners,t.wrapper.bounds),h.direction),g=Ol({corners:void 0,point:u=qa(l,0,u,{x:l.sourceWrapper.offsetX,y:l.sourceWrapper.offsetY},!1),margin:void 0,direction:h.direction},{corners:void 0,point:c.points[1],margin:void 0,direction:void 0});h.length=R.distancePoints(g[0],g[1]),c.direction&&c.length&&(c.length=R.distancePoints(g[1],g[2]))}else if(o){switch(l.segments[0].direction){case"Bottom":r=t.wrapper.bounds.bottomCenter.x-e.bottomCenter.x,s=t.wrapper.bounds.bottomCenter.y-e.bottomCenter.y;break;case"Top":r=t.wrapper.bounds.topCenter.x-e.topCenter.x,s=t.wrapper.bounds.topCenter.y-e.topCenter.y;break;case"Left":r=t.wrapper.bounds.middleLeft.x-e.middleLeft.x,s=t.wrapper.bounds.middleLeft.y-e.middleLeft.y;break;case"Right":r=t.wrapper.bounds.middleRight.x-e.middleRight.x,s=t.wrapper.bounds.middleRight.y-e.middleRight.y}this.dragSourceEnd(l,r,s,!0,null,"ConnectorSourceEnd",void 0,void 0,void 0,!(t.parentId&&this.diagram.diagramActions&ee.isGroupDragging))}}},n.prototype.updateEndPoint=function(t,e){var r={sourcePoint:t.sourcePoint,targetPoint:t.targetPoint};t.sourceID&&(r.sourceID=t.sourceID),t.targetID&&(r.targetID=t.targetID),t.sourcePortID&&(r.sourcePortID=t.sourcePortID),t.targetPortID&&(r.targetPortID=t.targetPortID),t.segments&&(r.segments=t.segments),this.diagram.connectorPropertyChange(t,e||{},r),this.diagram.updateSelector()},n.prototype.dragSourceEnd=function(t,e,i,r,s,o,a,l,h,c,d){var u=this.diagram.nameTable[t.id],f={},p=this.checkBoundaryConstraints(e,i,u.wrapper.bounds);if(AI(u)&&p&&"BezierSourceThumb"!==o&&Vv(this.diagram)&&(f=$(f={sourcePoint:u.sourcePoint}),u.sourcePoint.x+=e,u.sourcePoint.y+=i,"ConnectorSourceEnd"===o&&"Orthogonal"===u.type&&this.changeSegmentLength(u,l,h,c),"Bpmn"===u.shape.type&&"Default"===u.shape.sequence&&"Sequence"===u.shape.flow&&this.updatePathElementOffset(u)),"Bezier"===u.type)if(f={sourcePoint:u.sourcePoint},d)this.translateBezierPoints(t,""===o?"ConnectorSourceEnd":o,e,i,d,s,!a);else for(var g=0;g2){var d=R.direction((c=t.segments[2]).points[0],c.points[1]);o.direction===_n(d)?("Right"===o.direction?c.points[0].x=o.points[o.points.length-1].x=l.wrapper.corners.middleRight.x+20:"Left"===o.direction?c.points[0].x=o.points[o.points.length-1].x=l.wrapper.corners.middleLeft.x-20:c.points[0].y=o.points[o.points.length-1].y="Top"===o.direction?l.wrapper.corners.topCenter.y-20:l.wrapper.corners.bottomCenter.y+20,c.direction&&c.length&&(c.length=R.distancePoints(c.points[0],c.points[c.points.length-1])),o.length=R.distancePoints(o.points[0],o.points[o.points.length-1])):o.direction===d&&c.direction&&c.length?("Top"===o.direction||"Bottom"===o.direction?(c.points[0]=o.points[0],c.points[c.points.length-1].x=c.points[0].x):(c.points[0]=o.points[0],c.points[c.points.length-1].y=c.points[0].y),c.length=R.distancePoints(c.points[0],c.points[c.points.length-1]),t.segments.splice(0,2)):o.length=20}else o.length=20;else if(o.length<1)if(""!==t.sourceID){var c;"Right"===a.direction?a.points[a.points.length-1].y=(h=l.wrapper.corners.middleRight).y:"Left"===a.direction?a.points[a.points.length-1].y=(h=l.wrapper.corners.middleLeft).y:a.points[a.points.length-1].x="Top"===a.direction?(h=l.wrapper.corners.topCenter).x:(h=l.wrapper.corners.bottomCenter).x,a.length=R.distancePoints(h,a.points[a.points.length-1]),t.segments.length>2&&(c=t.segments[2]).direction&&c.length&&(c.length=R.distancePoints(a.points[a.points.length-1],c.points[c.points.length-1])),t.segments.splice(0,1)}else t.segments.splice(0,1)}else e&&!i&&t.sourceID!==e.id&&t.segments&&null!==t.segments[0].direction&&e&&e instanceof te&&s&&this.changeSourceEndToNode(t,e),e&&i&&t.sourcePortID!==i&&t.segments&&null!==t.segments[0].direction&&e&&e instanceof te&&s&&this.changeSourceEndToPort(t,e,i)},n.prototype.canConnect=function(t,e){return!(!ua(e)||!Ph(e))},n.prototype.changeSourceEndToPort=function(t,e,i){var r=this.diagram.getWrapper(e.wrapper,i),s={x:r.offsetX,y:r.offsetY},o=zo(s,xn(e.wrapper),e.wrapper.bounds),a=t.segments[0],l=t.segments[1];if(a.direction!==o){var h=[],c={};if(a.direction===_n(o)){c={};var d=void 0;"Top"===o||"Bottom"===o?(d="Top"===o?{type:"Orthogonal",isTerminal:!0,direction:o,length:Math.abs(a.points[0].y-s.y)}:{type:"Orthogonal",isTerminal:!0,direction:o,length:Math.abs(s.y-a.points[0].y)},c=a.points[0].x>s.x?{type:"Orthogonal",isTerminal:!0,direction:"Right",length:a.points[0].x-s.x}:{type:"Orthogonal",isTerminal:!0,direction:"Left",length:s.x-a.points[0].x}):(d="Right"===o?{type:"Orthogonal",isTerminal:!0,direction:o,length:Math.abs(a.points[0].x-s.x)}:{type:"Orthogonal",isTerminal:!0,direction:o,length:Math.abs(s.x-a.points[0].x)},c=a.points[0].y>s.y?{type:"Orthogonal",direction:"Top",isTerminal:!0,length:a.points[0].y-s.y}:{type:"Orthogonal",direction:"Bottom",isTerminal:!0,length:s.y-a.points[0].y}),h.push(new wi(t,"segments",d,!0)),h.push(new wi(t,"segments",c,!0))}else h.push(new wi(t,"segments",c={type:"Orthogonal",direction:o,length:20,isTerminal:!0},!0));a.direction!==_n(o)&&("Top"===o||"Bottom"===o?(a.points[0].x=s.x,a.points[0].y=a.points[a.points.length-1].y="Top"===o?s.y-20:s.y+20):(a.points[0].y=s.y,a.points[0].x=a.points[a.points.length-1].x="Right"===o?s.x+20:s.x-20),a.length=R.distancePoints(a.points[0],a.points[a.points.length-1]),l.length=R.distancePoints(a.points[a.points.length-1],l.points[l.points.length-1])),t.segments=h.concat(t.segments)}else a.points[0]=s,"Top"===o||"Bottom"===o?a.points[a.points.length-1].x=s.x:a.points[a.points.length-1].y=s.y,a.length=R.distancePoints(a.points[0],a.points[a.points.length-1]),l.length=R.distancePoints(a.points[a.points.length-1],l.points[l.points.length-1])},n.prototype.removeTerminalSegment=function(t,e){for(var i=0;ii.width||"Left"===o.direction&&r.x>=o.points[0].x||"Right"===o.direction&&r.x<=o.points[0].x)o.points[0].y=o.points[o.points.length-1].y=r.y,o.points[0].x=r.x,o.length=R.distancePoints(o.points[0],o.points[o.points.length-1]),a.length=R.distancePoints(o.points[o.points.length-1],a.points[a.points.length-1]);else{var h=void 0;s="Bottom"===(h=a.direction?a.direction:R.direction(a.points[0],a.points[a.points.length-1]))?i.bottomCenter:i.topCenter,a.length&&a.direction&&(a.length="Top"===h?o.points[o.points.length-1].y-(s.y+20):s.y+20-o.points[o.points.length-1].y),o.length=o.points[o.points.length-1].x-s.x,o.direction=o.length>0?"Right":"Left",l.push(new wi(t,"segments",{type:"Orthogonal",direction:h,length:20},!0)),t.segments=l.concat(t.segments)}else r="Bottom"===o.direction?i.bottomCenter:i.topCenter,o.length>i.height||"Top"===o.direction&&r.y>=o.points[0].y||"Bottom"===o.direction&&r.y<=o.points[0].y?(o.points[0].x=o.points[o.points.length-1].x=r.x,o.points[0].y=r.y,o.length=R.distancePoints(o.points[0],o.points[o.points.length-1]),a.length=R.distancePoints(o.points[o.points.length-1],a.points[a.points.length-1])):(s="Left"===a.direction?i.middleLeft:i.middleRight,h=void 0,h=a.direction?a.direction:R.direction(a.points[0],a.points[a.points.length-1]),a.length&&a.direction&&(a.length="Left"===h?o.points[o.points.length-1].x-(s.x+20):s.x+20-o.points[o.points.length-1].x),o.length=o.points[o.points.length-1].y-s.y,o.direction=o.length>0?"Bottom":"Top",l.push(new wi(t,"segments",{type:"Orthogonal",direction:h,length:20},!0)),t.segments=l.concat(t.segments))},n.prototype.translateBezierPoints=function(t,e,i,r,s,o,a){var l=t.segments.indexOf(s),h=t.segments[parseInt(l.toString(),10)],c=l>0?t.segments[l-1]:null,d=null!==c?c.point:t.sourcePoint,u=l===t.segments.length-1?t.targetPoint:h.point;if(h)if("BezierSourceThumb"===e&&(h.vector1.angle||h.vector1.distance)){var f=h.vector1.distance,p=h.vector1.angle;h.vector1={distance:t.distance(d,o),angle:R.findAngle(d,o)},this.translateSubsequentSegment(t,s,!0,h.vector1.distance-f,h.vector1.angle-p)}else"BezierTargetThumb"===e&&(h.vector2.angle||h.vector2.distance)?(f=h.vector2.distance,p=h.vector2.angle,h.vector2={distance:t.distance(u,o),angle:R.findAngle(u,o)},this.translateSubsequentSegment(t,s,!1,h.vector2.distance-f,h.vector2.angle-p)):("ConnectorSourceEnd"===e&&!t.sourceID||"ConnectorTargetEnd"===e&&!t.targetID)&&a&&GI(h.vector1)&&GI(h.vector2)?(R.isEmptyPoint(h.point1)&&(h.bezierPoint1=XI(t.sourcePoint,t.targetPoint)),R.isEmptyPoint(h.point2)&&(h.bezierPoint2=XI(t.targetPoint,t.sourcePoint))):"BezierSourceThumb"===e||"ConnectorSourceEnd"===e&&!a&&GI(h.vector1)?(h.bezierPoint1.x+=i,h.bezierPoint1.y+=r,(!R.isEmptyPoint(h.point1)||a)&&(h.point1={x:h.bezierPoint1.x,y:h.bezierPoint1.y})):("BezierTargetThumb"===e||"ConnectorTargetEnd"===e&&!a&&GI(h.vector2))&&(h.bezierPoint2.x+=i,h.bezierPoint2.y+=r,(!R.isEmptyPoint(h.point2)||a)&&(h.point2={x:h.bezierPoint2.x,y:h.bezierPoint2.y}))},n.prototype.translateSubsequentSegment=function(t,e,i,r,s){var o=t.segments.indexOf(e);parseInt(o.toString(),10),t.bezierSettings.smoothness&SI.SymmetricAngle||(s=null),t.bezierSettings.smoothness&SI.SymmetricDistance||(r=null),(null!=r||null!=s)&&(i?0!==o&&this.updatePreviousBezierSegment(t,o,r,s):o!==t.segments.length-1&&this.updateNextBezierSegment(t,o,r,s))},n.prototype.updatePreviousBezierSegment=function(t,e,i,r){var s=t.segments[e-1],a=(s.vector2.angle+r)%360;a<0&&(a+=360),s.vector2={distance:s.vector2.distance+i,angle:a}},n.prototype.updateNextBezierSegment=function(t,e,i,r){var s=t.segments[e+1],a=(s.vector1.angle+r)%360;a<0&&(a+=360),s.vector1={distance:s.vector1.distance+i,angle:a}},n.prototype.dragTargetEnd=function(t,e,i,r,s,o,a,l){var c,h=this.diagram.nameTable[t.id],d=this.checkBoundaryConstraints(e,i,h.wrapper.bounds);if(LI(h)&&"BezierTargetThumb"!==o&&d&&Vv(this.diagram)){if(c=$(c={targetPoint:h.targetPoint}),h.targetPoint.x+=e,h.targetPoint.y+=i,"ConnectorTargetEnd"===o&&"Orthogonal"===h.type&&h.segments&&h.segments.length>0){var u=h.segments[h.segments.length-2];u&&2===h.segments[h.segments.length-1].points.length&&("Left"===u.direction||"Right"===u.direction?u.points[u.points.length-1].x=h.targetPoint.x:u.points[u.points.length-1].y=h.targetPoint.y,u.length=R.distancePoints(u.points[0],u.points[u.points.length-1]),u.direction=R.direction(u.points[0],u.points[u.points.length-1]))}"Bpmn"===h.shape.type&&"Default"===h.shape.sequence&&"Sequence"===h.shape.flow&&this.updatePathElementOffset(h)}if("Bezier"===h.type)if(c={targetPoint:h.targetPoint},l)this.translateBezierPoints(t,""===o?"ConnectorTargetEnd":o,e,i,l,s,!a);else for(var f=0;f0){if(void 0!==s&&o.segments[parseInt(s.toString(),10)])if("Bezier"===o.type){var a=o.segments[parseInt(s.toString(),10)],l=a.isInternalSegment;l&&null!==o.bezierSettings&&"FreeForm"!==o.bezierSettings.segmentEditOrientation?("Horizontal"===a.orientation?a.point.x+=e:a.point.y+=i,this.updateDirectionalBezierCurve(o)):(a.point.x+=e,a.point.y+=i),l&&(o.isBezierEditing=!0)}else o.segments[parseInt(s.toString(),10)].point.x+=e,o.segments[parseInt(s.toString(),10)].point.y+=i;else for(var h=0;h1){var a=e[1],l=e[2],h={x:.5*(a.x+l.x),y:.5*(a.y+l.y)},c=t.segments[0];c.vector1.angle=Gt(s,a),c.vector1.distance=.5*R.findLength(s,a),c.vector2.angle=Gt(h,a),c.vector2.distance=.5*R.findLength(h,a),c.point=h;var d=t.segments[1];if(d.vector1.angle=Gt(h,l),d.vector1.distance=.5*R.findLength(h,l),t.segments.length>2){var u=e[3],f={x:.5*(l.x+u.x),y:.5*(l.y+u.y)};d.vector2.angle=Gt(f,l),d.vector2.distance=.5*R.findLength(f,l),d.point=f;var p=t.segments[2];if(p.vector1.angle=Gt(f,u),p.vector1.distance=.5*R.findLength(f,u),t.segments.length>3){var g=e[4],v={x:.5*(u.x+g.x),y:.5*(u.y+g.y)};p.vector2.angle=Gt(v,u),p.vector2.distance=.5*R.findLength(v,u),p.point=v;var y=t.segments[3];y.vector1.angle=Gt(v,g),y.vector1.distance=.5*R.findLength(v,g),y.vector2.angle=Gt(o,g),y.vector2.distance=.5*R.findLength(o,g)}else p.vector2.angle=Gt(o,u),p.vector2.distance=.5*R.findLength(o,u)}else d.vector2.angle=Gt(o,l),d.vector2.distance=.5*R.findLength(o,l)}},n.prototype.rotateObjects=function(t,e,i,r,s){r=r||{};var o=Bi();qi(o,i,r.x,r.y);for(var l=0,h=e;l0){this.diagram.protectPropertyChange(!0);var o=t;o.segments=[],this.diagram.connectorPropertyChange(o,{},{segments:o.segments}),this.diagram.protectPropertyChange(!1)}}},n.prototype.updateInnerParentProperties=function(t){var r=this.diagram.isProtectedOnChange;this.diagram.protectPropertyChange(!0);for(var s=this.getAllDescendants(t,[],!1,!0),o=0;o0&&(f=this.diagram.bpmnModule.getChildrenBound(d,d.id,this.diagram),u=d.wrapper.bounds.containsRect(f)),h=d.wrapper.actualSize.width*t,c=d.wrapper.actualSize.height*e,void 0!==d.maxWidth&&0!==d.maxWidth&&(h=Math.min(d.maxWidth,h)),void 0!==d.minWidth&&0!==d.minWidth&&(h=Math.max(d.minWidth,h)),void 0!==d.maxHeight&&0!==d.maxHeight&&(c=Math.min(d.maxHeight,c)),void 0!==d.minHeight&&0!==d.minHeight&&(c=Math.max(d.minHeight,c)),u&&(h=Math.max(h,f.right-d.wrapper.bounds.x),c=Math.max(c,f.bottom-d.wrapper.bounds.y)),t=h/d.actualSize.width,e=c/d.actualSize.height}var p=Bi();o||(o=r);var g=o.wrapper;if(qi(p,-g.rotateAngle,i.x,i.y),Yf(p,t,e,i.x,i.y),qi(p,g.rotateAngle,i.x,i.y),r instanceof te){var d,v=Ke(p,{x:(d=r).wrapper.offsetX,y:d.wrapper.offsetY}),y=d.wrapper.offsetX-d.wrapper.actualSize.width*d.pivot.x,S=d.wrapper.offsetY-d.wrapper.actualSize.height*d.pivot.y;if(h>0)if(d.processId){var b=this.diagram.nameTable[d.processId];(!b.maxWidth||d.margin.left+h0)if(d.processId){var M=this.diagram.nameTable[d.processId];(!M.maxHeight||d.margin.top+c0){if(e.dragLimit=e.dragLimit?e.dragLimit:{},e.dragLimit.top||e.dragLimit.bottom||e.dragLimit.left||e.dragLimit.right){var b={minDistance:null};S=this.getRelativeOffset(v,d,b);var M={minDistance:null};g=this.getRelativeOffset(v,y,M),S=null!=b&&M.minDistance0){if(S=y[y.length-1]){var b=void 0;for(b=0;b=e.x-t.dragLimit.left-r.width/2&&i.x<=e.x+t.dragLimit.right+r.width/2&&(s=!0),i.y>=e.y-t.dragLimit.top-r.height/2&&i.y<=e.y+t.dragLimit.bottom+r.height/2&&(o=!0),{x:s,y:o}},n.prototype.updateLabelMargin=function(t,e,i,r,s,o,a){if(i=i||{x:e.offset,y:0},e&&i&&i.x>0&&i.x<1){var l=R.getLengthFromListOfPoints(t.intermediatePoints),h=this.getPointAtLength(l*i.x,t.intermediatePoints,0),c=this.diagram.scrollSettings.currentZoom,d=e.dragLimit?e.dragLimit:{left:0,right:0,top:0,bottom:0};if(d.top||d.bottom||d.left||d.right){this.diagram.getWrapper(t.wrapper,e.id);var f=new Ne(0,0,0,0),p=this.diagram.getWrapper(t.wrapper,e.id);f.x=p.offsetX/c+o,f.y=p.offsetY/c+a,f.width=p.bounds.width/c,f.height=p.bounds.height/c;var g=new Ne(h.x-(d.left||0)-f.width/2,h.y-(d.top||0)-f.height/2,(d.left||0)+(d.right||0)+f.width,(d.top||0)+(d.bottom||0)+f.height);if(g.containsPoint(r));else for(var S=0,b=this.boundsInterSects([h,r],g,!1);S=t){c=t-r,d=R.findAngle(s,a),u=c*Math.cos(d*Math.PI/180),f=c*Math.sin(d*Math.PI/180),o={x:s.x+u,y:s.y+f};break}r+=h,s=a}else s=a;return o},n.prototype.getInterceptWithSegment=function(t,e){for(var o,a,i=[],r=[],s=[],l=R.findLength({x:0,y:0},{x:this.diagram.scroller.viewPortWidth,y:this.diagram.scroller.viewPortHeight}),h=1;h0&&a<=90||a>180&&a<=270?90:-90;r.push(R.transform(t,a+c,l)),r.push(R.transform(t,o+c,l));var f=tm({x1:s[0].x,y1:s[0].y,x2:s[1].x,y2:s[1].y},{x1:r[0].x,y1:r[0].y,x2:r[1].x,y2:r[1].y});f.enabled&&i.push(f.intersectPt)}return i},n.prototype.getAnnotationChanges=function(t,e){var r={};return r[ib(t,e.id,!0)]={width:e.width,height:e.height,offset:t instanceof te?{x:e.offset.x,y:e.offset.y}:e.offset,rotateAngle:e.rotateAngle,margin:{left:e.margin.left,right:e.margin.right,top:e.margin.top,bottom:e.margin.bottom},horizontalAlignment:e.horizontalAlignment,verticalAlignment:e.verticalAlignment,alignment:t instanceof de?e.alignment:void 0},{annotations:r}},n.prototype.getConnectorPortChanges=function(t,e){var i=function kse(n,t,e){for(var i=n.ports,r=0;r1&&(v.width=g,v.offset.x=1/S),p>1&&(v.height=p,v.offset.y=1/b)}}e instanceof Or&&(e.alignment="Center"),l=this.getAnnotationChanges(t,e),t instanceof te?this.diagram.nodePropertyChange(t,a,l):this.diagram.connectorPropertyChange(t,a,l),this.diagram.updateDiagramObject(t)},n.prototype.getSubProcess=function(t){var i,e={nodes:[],connectors:[]};return t instanceof te?i=t.processId:t&&t.nodes&&t.nodes.length&&t.nodes[0].processId&&(i=t.nodes[0].processId),i&&e.nodes.push($(this.diagram.nameTable[i])),e},n.prototype.checkBoundaryConstraints=function(t,e,i,r){var s=this.diagram.pageSettings,o=this.diagram.pageSettings.boundaryConstraints,a=this.diagram.scroller;if("Page"===o||"Diagram"===o){var l=i?void 0:this.diagram.selectedItems.wrapper.bounds;return!!((i?i.right:l.right)+(t||0)<=("Page"===o?s.width:a.viewPortWidth)&&(i?i.left:l.left)+(t||0)>=0&&(i?i.bottom:l.bottom)+(e||0)<=("Page"===o?s.height:a.viewPortHeight)&&(i?i.top:l.top)+(e||0)>=0||"None"!==this.diagram.layout.type&&r)}return!0},n.prototype.dragSelectedObjects=function(t,e){var i=this,r=this.diagram.selectedItems;this.state&&!this.state.backup&&(this.state.backup={},this.state.backup.offsetX=r.offsetX,this.state.backup.offsetY=r.offsetY),r=VI(this.diagram,r)||r;var s=this.diagram.selectedItems.nodes.filter(function(c){return"SwimLane"===c.shape.type});if(s.length>0&&!this.diagram.currentSymbol&&this.diagram.selectedItems.nodes.length>1){var o=this.diagram.selectedItems.nodes.filter(function(c){return""===c.parentId||"SwimLane"!==i.diagram.nameTable[c.parentId].shape.type});if(o.length>0){for(var a=0;a0||l.length>1)&&(o=o.concat(l),this.diagram.selectedItems.nodes.splice(0,this.diagram.selectedItems.nodes.length),o.forEach(function(c){i.diagram.selectedItems.nodes.push(c)}),r=this.diagram.selectedItems,this.diagram.selectedObject.helperObject=void 0)}}if(this.checkBoundaryConstraints(t,e)){this.diagram.diagramActions=this.diagram.diagramActions|ee.PreventZIndexOnDragging|ee.DragUsingMouse;var h=this.diagram.selectedObject.actualObject;return(h&&h instanceof te&&h.isLane&&Vx(h,this.diagram)||!h||!h.isLane)&&this.diagram.drag(r,t,e),this.diagram.diagramActions=this.diagram.diagramActions&~(ee.PreventZIndexOnDragging|ee.DragUsingMouse),this.diagram.refreshCanvasLayers(),this.checkHtmlObjectDrag(r),!0}return!1},n.prototype.checkHtmlObjectDrag=function(t){var e=!1;this.diagram.views&&this.diagram.views.length>1&&(t instanceof ei?e=t.nodes.some(function(i){return i.shape&&"HTML"===i.shape.type}):t.shape&&"HTML"===t.shape.type&&(e=!0),e&&this.resetOverviewCanvas())},n.prototype.resetOverviewCanvas=function(){for(var t=0,e=this.diagram.views;t0&&(this.layoutAnimateModule.stopCurrentAnimation(this.objectStore[0],e,t),this.objectStore=[]),a=this.diagram.doLayout(),this.objectStore.push(a)),this.canUpdateTemplate=!1,this.diagram.blazorActions&=~on.expandNode,this.diagram.preventNodesUpdate=r,this.diagram.layoutAnimateModule&&this.diagram.organizationalChartModule&&!i)this.diagram.allowServerDataBinding=!1,this.layoutAnimateModule.expand(this.diagram.layout.enableAnimation,a,t,this.diagram);else{var l={element:$(t),state:!!t.isExpanded};this.triggerEvent(Ce.expandStateChange,l),this.diagram.lineRoutingModule&&this.diagram.constraints&nt.LineRouting&&"ComplexHierarchicalTree"!==this.diagram.layout.type&&this.diagram.resetSegments()}return this.diagram.layout.fixedNode=""===o?"":this.diagram.layout.fixedNode,a},n.prototype.getparentexpand=function(t,e,i,r){for(var s,o=0;o0&&(this.diagram.selectedItems.wrapper.rotateAngle=this.diagram.selectedItems.rotateAngle=s.rotateAngle),!(r instanceof te&&"SwimLane"!==r.shape.type)||r.isLane||r.isPhase||r.isHeader||Dn(this.diagram,r)){if(r instanceof ei)for(var d=0;d30||g.wrapper.outerBounds.topCenter.y-p.wrapper.outerBounds.bottomCenter.y>30)&&this.diagram.lineRoutingModule.refreshConnectorSegments(this.diagram,f,!0)}}this.updateSelector(),this.diagram.protectPropertyChange(!1)}},n.prototype.drawSelectionRectangle=function(t,e,i,r){this.diagram.drawSelectionRectangle(t,e,i,r)},n.prototype.startGroupAction=function(){this.diagram.startGroupAction()},n.prototype.endGroupAction=function(){this.diagram.endGroupAction()},n.prototype.removeChildFromBPmn=function(t,e,i){var r=this.diagram.nameTable[t.id]||t.nodes[0];if(i&&r&&r.processId&&r.processId===i.wrapper.id){var s=$(r);s.processId=r.processId,this.diagram.startGroupAction();var o=this.diagram.nameTable[r.processId].shape.activity.subProcess.processes||[];o.splice(o.indexOf(r.id),1),this.diagram.bpmnModule.removeChildFromBPMN(this.diagram.nameTable[r.processId].wrapper,r.id,this.diagram),this.diagram.nameTable[r.id].processId="",r.offsetX=r.wrapper.offsetX,r.offsetY=r.wrapper.offsetY;var a=$(r);this.addHistoryEntry({type:"PositionChanged",redoObject:{nodes:[a]},undoObject:{nodes:[s]},category:"Internal"}),this.diagram.endGroupAction()}},n.prototype.isDroppable=function(t,e){var i=this.diagram.nameTable[t.id]||t.nodes[0];return i instanceof te&&(!ce()&&"TextAnnotation"===i.shape.shape||("Group"===e.shape.shape&&(e.shape.activity.subProcess.collapsed=!1),!(i&&"Bpmn"===i.shape.type&&(i.processId===e.id||i.id===e.processId||"Bpmn"===e.shape.type&&!(e instanceof de)&&e.shape.activity&&e.shape.activity.subProcess&&e.shape.activity.subProcess.collapsed))))},n.prototype.renderHighlighter=function(t,e,i){if(new Ne,t.target instanceof te||t.target instanceof de||e&&(t.source instanceof te||t.source instanceof de)){var a=this.findTarget(e?t.sourceWrapper:t.targetWrapper,e?t.source:t.target,i,!0),l=void 0;if(a instanceof Rd)for(var h=a.id,c=t.target,u=0,f=c.wrapper.children[0].children[0].children[2].children;u0){var r=0;t[0]=this.diagram.nameTable[t[0].id]||t[0];var s="Object"===i?yr(t[0].wrapper):this.diagram.selectedItems.wrapper.bounds,o={nodes:[],connectors:[]},a={nodes:[],connectors:[]};for(r="Object"===i?r+1:r;r0){var i=0,r=0,s=0,o=0,a=0,l=0,h=0,c=0,d={nodes:[],connectors:[]},u={nodes:[],connectors:[]};for(i=0;io.center.y&&(r=n[parseInt(e.toString(),10)],n[parseInt(e.toString(),10)]=n[parseInt(i.toString(),10)],n[parseInt(i.toString(),10)]=r):s.center.x>o.center.x&&(r=n[parseInt(e.toString(),10)],n[parseInt(e.toString(),10)]=n[parseInt(i.toString(),10)],n[parseInt(i.toString(),10)]=r)}}return n}(t,e),i=1;i0){var i=0,r={x:.5,y:.5};t[0]=this.diagram.nameTable[t[0].id]||t[0];var s=yr(t[0].wrapper),o={nodes:[],connectors:[]},a={nodes:[],connectors:[]};for(i=1;ii.zIndex){for(var s=this.diagram.layers.indexOf(this.diagram.getActiveLayer()),o=this.diagram.layers[parseInt(s.toString(),10)].zIndexTable,a=JSON.parse(JSON.stringify(o)),l=i.zIndex,h=r.zIndex,c=h;c>=l;c--)l!==c?o[c-1]?(o[parseInt(c.toString(),10)]=o[c-1],this.diagram.nameTable[o[parseInt(c.toString(),10)]].zIndex=c):(o[c-1]=o[parseInt(c.toString(),10)],this.diagram.nameTable[o[c-1]].zIndex=c,delete o[parseInt(c.toString(),10)]):this.swapZIndexObjects(h,o,r.id,a);"SVG"===this.diagram.mode?(this.moveSvgNode(e.parentId,i.id),this.updateNativeNodeIndex(e.parentId,i.id)):this.diagram.refreshCanvasLayers()}},n.prototype.findLeastIndexConnector=function(t,e,i){for(var r=0;rs.zIndex&&(i=s)}return i},n.prototype.findLeastIndexObject=function(t,e){var i=t;return t instanceof te&&(i=this.findLeastIndexConnector(t.inEdges,e,i),i=this.findLeastIndexConnector(t.outEdges,e,i)),i},n.prototype.checkSelection=function(t,e){var i;if(1===t.nodes.length&&0===t.connectors.length)if(Dn(this.diagram,t.nodes[0],!0)){var r=t.nodes[0];if("SwimLane"===(i="SwimLane"===t.nodes[0].shape?t.nodes[0]:this.diagram.nameTable[t.nodes[0].parentId]).shape.type){var s="Horizontal"===i.shape.orientation;(r.isPhase&&(s&&"ResizeSouth"===e||!s&&"ResizeEast"===e)||r.isLane&&(s&&"ResizeEast"===e||!s&&"ResizeSouth"===e))&&B3(this.diagram,i,e)}else if("Grid"===i.container.type)if("Horizontal"===i.container.orientation&&1===r.rowIndex||"Vertical"===i.container.orientation&&r.rowIndex>0&&r.columnIndex>0){if("ResizeSouth"===e)for(var o=0;o1&&(this.diagram.realActions=this.diagram.realActions|$i.hScrollbarMoved,this.scrolled=!0),this.diagram.scrollSettings.horizontalOffset=t},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"verticalOffset",{get:function(){return this.vOffset},set:function(t){this.vOffset=t,Math.abs(this.vOffset-this.diagram.scrollSettings.verticalOffset)>1&&(this.diagram.realActions=this.diagram.realActions|$i.vScrollbarMoved,this.scrolled=!0),this.diagram.scrollSettings.verticalOffset=t},enumerable:!0,configurable:!0}),n.prototype.getBounds=function(){var e=this.diagram.spatialSearch.getPageBounds(0,0);return(e.x<0||e.y<0)&&!this.diagram.pageSettings.multiplePage?this.getPageBounds(void 0,void 0,!0,!0):this.getPageBounds(void 0,void 0,!0)},n.prototype.updateScrollOffsets=function(t,e){var i,r,s=this.getBounds();s.x*=this.currentZoom,s.y*=this.currentZoom,s.width*=this.currentZoom,s.height*=this.currentZoom,i=Math.max(0,t-s.left),r=Math.max(0,e-s.top),void 0!==t&&void 0!==e?(this.horizontalOffset=i,this.verticalOffset=r,this.diagram.setOffset(i,r)):this.diagram.setOffset(-this.horizontalOffset-s.x,-this.verticalOffset-s.y),this.transform={tx:Math.max(this.horizontalOffset,-s.left)/this.currentZoom,ty:Math.max(this.verticalOffset,-s.top)/this.currentZoom,scale:this.currentZoom}},n.prototype.setScrollOffset=function(t,e){this.scrolled=!1;var i=this.getBounds();i.x*=this.currentZoom,i.y*=this.currentZoom,i.width*=this.currentZoom,i.height*=this.currentZoom;var r=-i.left,s=-i.top,o=!1,a=this.viewPortWidth*this.currentZoom,l=this.viewPortHeight*this.currentZoom,h=r-t;if(h!==this.horizontalOffset){rh?this.horizontalOffset-=t:this.horizontalOffset=h,o=!0);var c=Math.max(i.right+this.vScrollSize,a);if(!o&&c<-h+this.viewPortWidth){var d=-h+a-this.vScrollSize,u=-this.horizontalOffset+a-this.vScrollSize;this.horizontalOffset=dd-u?h:-(i.right+this.vScrollSize-a),o=!0}o||(this.horizontalOffset=r-t)}o=!1;var f=s-e;if(f!==this.verticalOffset){sf?this.verticalOffset-=e:this.verticalOffset=f,o=!0);var p=Math.max(i.bottom+this.hScrollSize,l);if(!o&&p<-f+l){var g=-f+l-this.hScrollSize,v=-this.verticalOffset+l-this.hScrollSize;this.verticalOffset=gg-v?f:-(i.bottom+this.hScrollSize-l),o=!0}o||(this.verticalOffset=s-e)}this.transform={tx:Math.max(this.horizontalOffset,-i.left)/this.currentZoom,ty:Math.max(this.verticalOffset,-i.top)/this.currentZoom,scale:this.currentZoom},this.setSize()},n.prototype.getObjects=function(t,e){for(var i=[],r=0;r0){for(var l=0;l0){h.push(i[parseInt(o.toString(),10)].id);for(var d=0;d=e.bottom&&(l=0),-this.horizontalOffset<=e.x&&-this.horizontalOffset+this.viewPortWidth>=e.right&&(a=0),this.hScrollSize=a,this.vScrollSize=l;var h=this.diagramWidth,c=this.diagramHeight;this.diagramWidth=Math.max(e.right,-this.horizontalOffset+this.viewPortWidth-l)-i,this.diagramHeight=Math.max(e.bottom,-this.verticalOffset+this.viewPortHeight-a)-r,(h!==this.diagramWidth||c!==this.diagramHeight)&&"Diagram"!==this.diagram.scrollSettings.scrollLimit&&this.diagram.setSize(this.diagramWidth,this.diagramHeight),"Diagram"===this.diagram.scrollSettings.scrollLimit&&(h===this.diagramWidth&&c===this.diagramHeight&&1===this.currentZoom||this.diagram.diagramActions&&t&&(!this.diagram.diagramActions||!t||0===this.verticalOffset&&this.verticalOffset!==t.y||0===this.horizontalOffset&&this.horizontalOffset!==t.x)?t&&h===this.diagramWidth&&c===this.diagramHeight&&(this.diagram.diagramCanvas.scrollHeight>this.viewPortHeight&&t.y<0&&this.horizontalOffset===t.x&&0===this.verticalOffset||this.diagram.diagramCanvas.scrollWidth>this.viewPortWidth&&t.x<0&&this.verticalOffset===t.y&&0===this.horizontalOffset)&&(this.verticalOffset=t.y,this.horizontalOffset=t.x,this.transform={tx:Math.max(t.x,-e.left)/this.currentZoom,ty:Math.max(t.y,-e.top)/this.currentZoom,scale:this.currentZoom}):(this.diagram.scrollActions&da.Interaction&&t&&(this.transform={tx:Math.max(t.x,-e.left/this.currentZoom)/this.currentZoom,ty:Math.max(t.y,-e.top/this.currentZoom)/this.currentZoom,scale:this.currentZoom},this.horizontalOffset=t.x,this.verticalOffset=t.y),this.diagram.setSize(this.diagramWidth,this.diagramHeight),!(this.diagram.scrollActions&da.PropertyChange)&&t&&(this.horizontalOffset=t.x,this.verticalOffset=t.y,this.transform={tx:Math.max(t.x,-e.left)/this.currentZoom,ty:Math.max(t.y,-e.top)/this.currentZoom,scale:this.currentZoom}))),this.diagram.transformLayers(),this.diagram.element.style.overflow="hidden"},n.prototype.setViewPortSize=function(t,e){this.viewPortWidth=t,this.viewPortHeight=e},n.prototype.getPageBounds=function(t,e,i,r){var o,s=new Ne;if("Content"===e||r||null===this.diagram.pageSettings.width||null===this.diagram.pageSettings.height){var u=t?void 0:0;o=this.diagram.spatialSearch.getPageBounds(u,u)}else{var a=this.diagram.pageSettings.width,l=this.diagram.pageSettings.height,h=0,c=0;if(this.diagram.pageSettings.multiplePage){if((s=this.diagram.spatialSearch.getPageBounds(0,0)).right>a&&(a*=d=Math.ceil(s.right/a)),s.bottom>l&&(l*=d=Math.ceil(s.bottom/l)),s.left<0&&Math.abs(s.left)>h){var d=Math.ceil(Math.abs(s.left)/this.diagram.pageSettings.width);h=this.diagram.pageSettings.width*d}s.top<0&&Math.abs(s.top)>c&&(d=Math.ceil(Math.abs(s.top)/this.diagram.pageSettings.height),c=this.diagram.pageSettings.height*d)}o=new Ne(-h,-c,a+h,l+c)}if(i){var f=this.diagram.scrollSettings.padding;o.x-=f.left,o.y-=f.top,o.width+=f.left+f.right,o.height+=f.top+f.bottom}return o},n.prototype.getPageBreak=function(t){for(var e=0,i=0,r=-1,s=[],c=this.diagram.pageSettings.margin.left,d=this.diagram.pageSettings.margin.right,u=this.diagram.pageSettings.margin.top,f=this.diagram.pageSettings.margin.bottom,p=1,g=1;t.width>e;)(e+=this.diagram.pageSettings.width?this.diagram.pageSettings.width:t.width)===this.diagram.pageSettings.width&&(s[++r]={x1:t.left+c,y1:t.top+u,x2:t.left+c,y2:t.bottom-f}),ei;)(i+=this.diagram.pageSettings.height?this.diagram.pageSettings.height:t.height)===this.diagram.pageSettings.height&&(s[++r]={x1:t.left+c,y1:t.top+u,x2:t.right-d,y2:t.top+u}),i=this.diagram.scrollSettings.minZoom||l||t>=1)){this.currentZoom*=t;var c=this.getPageBounds(void 0,void 0,!0);c.x*=this.currentZoom,c.y*=this.currentZoom;var d=Bi();Yf(d,t,t,r.x,r.y),ZB(d,e||0,i||0),yx(h,d);var u=Ke(h,{x:0,y:0});if(1===t&&(u=this.applyScrollLimit(u.x,u.y,s,o,a)),a=-c.y>=u.y&&-c.x>=u.x&&a,(this.diagram.scrollActions&da.PropertyChange||!(this.diagram.scrollActions&da.Interaction)||"Diagram"!==this.diagram.scrollSettings.scrollLimit||a)&&(this.transform={tx:Math.max(u.x,-c.left)/this.currentZoom,ty:Math.max(u.y,-c.top)/this.currentZoom,scale:this.currentZoom},this.horizontalOffset=u.x,this.verticalOffset=u.y),this.setSize(u),"SVG"!==this.diagram.mode&&Ds(this.diagram)&&this.diagram.scroller.virtualizeElements(),"SVG"!==this.diagram.mode&&!Ds(this.diagram)&&this.diagram.refreshDiagramLayer(),this.diagram.setOffset(-this.horizontalOffset-c.x,-this.verticalOffset-c.y),qI(this.diagram),this.diagram.views&&this.diagram.views.overview){var f=this.diagram.views.overview,p=f.scrollOverviewRect(f.parent.scroller.horizontalOffset,f.parent.scroller.verticalOffset,f.parent.scroller.currentZoom,!0);f.updateOverviewrect(-p.x,-p.y,p.width,p.height),f.updateView(f)}}}},n.prototype.fitToPage=function(t){var e=(t=t||{}).mode,i=t.region,r=t.margin||{},s=t.canZoomIn,o=t.customBounds,a=t.canZoomOut;r.bottom=r.bottom||25,r.top=r.top||25,r.left=r.left||25,r.right=r.right||25;var h,l=o,c=-this.horizontalOffset,d=-this.verticalOffset;if("PageSettings"===(i=i||"PageSettings")&&this.diagram.pageSettings.width&&this.diagram.pageSettings.height||this.diagram.nodes.length>0||this.diagram.connectors.length>0){e=e||"Page","CustomBounds"!==i&&(l=this.getPageBounds(!0,i,!0));var u={x:0,y:0};r.left+r.right>this.viewPortWidth&&(this.viewPortWidth<=100?(r.left=5,r.right=5):(r.left=25,r.right=25)),r.top+r.bottom>this.viewPortHeight&&(this.viewPortHeight<=100?(r.top=5,r.bottom=5):(r.top=25,r.bottom=25)),u.x=(this.viewPortWidth-(r.left+r.right))/l.width,u.y=(this.viewPortHeight-(r.top+r.bottom))/l.height,!s&&l.width-this.horizontalOffset-a+this.viewPortWidth&&(i=o.right-this.viewPortWidth,i+=20),o.x<-a&&(i=o.x),o.bottom>-l+this.viewPortHeight&&(r=o.bottom-this.viewPortHeight,r+=20),o.y<-l&&(r=o.y),this.zoom(1,-this.horizontalOffset-i,-this.verticalOffset-r,null,void 0,e))},n.prototype.bringToCenter=function(t){var e=this.currentZoom,i=new Ne(t.x*e,t.y*e,t.width*e,t.height*e),r=i.x+i.width/2-this.viewPortWidth/2,s=i.y+i.height/2-this.viewPortHeight/2;this.zoom(1,-this.horizontalOffset-(r*=-1),-this.verticalOffset-(s*=-1),null)},n.prototype.applyScrollLimit=function(t,e,i,r,s){if("Infinity"===this.diagram.scrollSettings.scrollLimit&&void 0===i&&!r&&(t=-t,e=-e),"Infinity"!==this.diagram.scrollSettings.scrollLimit){var o=void 0;if("Limited"===this.diagram.scrollSettings.scrollLimit){var a=this.diagram.scrollSettings.scrollableArea;o=new Ne(a.x,a.y,a.width,a.height)}(o=o||(s?this.getPageBounds():this.getPageBounds(!0))).x*=this.currentZoom,o.y*=this.currentZoom,o.width*=this.currentZoom,o.height*=this.currentZoom,void 0!==i&&(t*=-1,e*=-1),r&&(t*=-1,e*=-1);var l=Math.max(o.right,this.viewPortWidth);if(!r&&!(t<=o.x&&(t+this.viewPortWidth>=o.right||t>=o.right-this.viewPortWidth)||t>=o.x&&t+this.viewPortWidth<=l))if(t>=o.x)t=Math.max(o.x,Math.min(t,t-(t+this.viewPortWidth-this.vScrollSize-l)));else{var h=o.right-this.viewPortWidth;t=Math.min(h,o.x)}var c=Math.max(o.bottom,this.viewPortHeight);r||e<=o.y&&e+this.viewPortHeight>=o.bottom||e>=o.y&&e+this.viewPortHeight<=c||(e>=o.y?e=Math.max(o.y,Math.min(e,e-(e+this.viewPortHeight-this.hScrollSize-c))):(h=o.bottom-this.viewPortHeight,e=Math.min(o.y,h))),t*=-1,e*=-1}return{x:t,y:e}},n}(),Woe=function(){function n(t,e,i,r,s){this.objects=[],this.left=t,this.top=e,this.width=i,this.height=r,this.spatialSearch=s}return n.prototype.findQuads=function(t,e){null!=this.first&&this.first.isIntersect(t)&&this.first.findQuads(t,e),null!=this.second&&this.second.isIntersect(t)&&this.second.findQuads(t,e),null!=this.third&&this.third.isIntersect(t)&&this.third.findQuads(t,e),null!=this.fourth&&this.fourth.isIntersect(t)&&this.fourth.findQuads(t,e),this.objects.length>0&&e.push(this)},n.prototype.isIntersect=function(t){return!(this.left+this.widtht.right||this.top>t.bottom)},n.prototype.selectQuad=function(){for(var i,t=null,e=this;null!=e;)i=e.getQuad(t),e=i.source,t=i.target||t;return t},n.prototype.getQuad=function(t){var e=this.width/2,i=this.height/2;if(e>=1e3&&i>=1e3){var r=this.left+e,s=this.top+i;if(this.spatialSearch.childRight<=r){if(this.spatialSearch.childBottom<=s)return this.first||((o=new n(this.left,this.top,e,i,this.spatialSearch)).parent=this,this.first=o),{source:this.first};if(this.spatialSearch.childTop>=s)return this.third||((o=new n(this.left,s,e,i,this.spatialSearch)).parent=this,this.third=o),{source:this.third}}else if(this.spatialSearch.childLeft>=r){if(this.spatialSearch.childBottom<=s)return this.second||((o=new n(r,this.top,e,i,this.spatialSearch)).parent=this,this.second=o),{source:this.second};var o;if(this.spatialSearch.childTop>=s)return this.fourth||((o=new n(r,s,e,i,this.spatialSearch)).parent=this,this.fourth=o),{source:this.fourth}}}return this.objects.push(this.spatialSearch.childNode),{target:this}},n.prototype.isContained=function(){return this.spatialSearch.childLeft>=this.left&&this.spatialSearch.childRight<=this.left+this.width&&this.spatialSearch.childTop>=this.top&&this.spatialSearch.childBottom<=this.top+this.height},n.prototype.addIntoAQuad=function(t){var e={};this.spatialSearch.setCurrentNode(t);for(var i=null;!e.isAdded;)i=(e=this.spatialSearch.parentQuad.add(i)).quad;return i},n.prototype.add=function(t){if(t=null,this.isContained())return{isAdded:!0,quad:t=this.selectQuad()};var e=void 0,i=!(0!==this.objects.length||this.first||this.second||this.third||this.fourth),r=2*this.width,s=2*this.height;return this.spatialSearch.childLeft=this.childLeft?(this.pageLeft=this.childLeft,this.leftElement=t,r=!0):t===this.leftElement&&(this.pageLeft=Number.MAX_VALUE,this.findLeft(this.parentQuad),r=!0)),(this.pageTop!==this.childTop||t!==this.topElement)&&(this.pageTop>=this.childTop?(this.pageTop=this.childTop,this.topElement=t,r=!0):t===this.topElement&&(this.pageTop=Number.MAX_VALUE,this.findTop(this.parentQuad),r=!0)),(this.pageBottom!==this.childBottom||t!==this.bottomElement)&&(this.pageBottom<=this.childBottom?(r=!0,this.pageBottom=this.childBottom,this.bottomElement=t):t===this.bottomElement&&(this.pageBottom=-Number.MAX_VALUE,this.findBottom(this.parentQuad),r=!0)),(this.pageRight!==this.childRight||t!==this.rightElement)&&(this.pageRight<=this.childRight?(this.pageRight=this.childRight,this.rightElement=t,r=!0):t===this.rightElement&&(this.pageRight=-Number.MAX_VALUE,this.findRight(this.parentQuad),r=!0)),r}return this.setCurrentNode(null),!1},n.prototype.isWithinPageBounds=function(t){return t.left>=this.pageLeft&&t.right<=this.pageRight&&t.top>=this.pageTop&&t.bottom<=this.pageBottom},n.prototype.findQuads=function(t){var e=[];return this.parentQuad.findQuads(t,e),e},n.prototype.findObjects=function(t){for(var i=[],r=0,s=this.findQuads(t);r=r.outerBounds.left&&(this.pageLeft=r.outerBounds.left,this.leftElement=r)}},n.prototype.findTop=function(t){t.first||t.second?(t.first&&this.findTop(t.first),t.second&&this.findTop(t.second)):(t.third&&this.findTop(t.third),t.fourth&&this.findTop(t.fourth));for(var e=0,i=t.objects;e=r.outerBounds.top&&(this.pageTop=r.outerBounds.top,this.topElement=r)}},n.prototype.setCurrentNode=function(t){if(this.childNode=t,t){var e=t.outerBounds;this.childLeft=Number(e.left),this.childTop=Number(e.top),this.childRight=Number(e.right),this.childBottom=Number(e.bottom)}else this.childLeft=Number.MAX_VALUE,this.childTop=Number.MAX_VALUE,this.childRight=-Number.MAX_VALUE,this.childBottom=-Number.MAX_VALUE},n.prototype.getPageBounds=function(t,e){if(this.pageLeft===Number.MAX_VALUE)return new Ne(0,0,0,0);var i=void 0!==t?Math.min(this.pageLeft,0):this.pageLeft,r=void 0!==e?Math.min(this.pageTop,0):this.pageTop;return new Ne(Math.round(i),Math.round(r),Math.round(this.pageRight-i),Math.round(this.pageBottom-r))},n.prototype.getQuad=function(t){return this.quadTable[t.id]},n}(),Yoe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Goe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Yoe(t,n),function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);r>3&&s&&Object.defineProperty(t,e,s)}([I(!1)],t.prototype,"preventDefaults",void 0),t}(Ee),Xoe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),e_=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},qoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Xoe(t,n),e_([I("")],t.prototype,"action",void 0),e_([I("")],t.prototype,"cursor",void 0),t}(Ee),t_=function(){function n(){this.size=20,this.intermediatePoints=[],this.gridCollection=[],this.startArray=[],this.targetGridCollection=[],this.sourceGridCollection=[],this.considerWalkable=[]}return n.prototype.lineRouting=function(t){var e=t.connectors.length;if(this.renderVirtualRegion(t),e>0)for(var i=0;i=t.right||e.right<=t.left||e.top>=t.bottom||e.bottom<=t.top)},n.prototype.findEndPoint=function(t,e,i){var r,s;if(e&&""!==t.sourcePortID&&t.sourcePortWrapper||!e&&""!==t.targetPortID&&t.targetPortWrapper){s=zo(r=e?{x:t.sourcePortWrapper.offsetX,y:t.sourcePortWrapper.offsetY}:{x:t.targetPortWrapper.offsetX,y:t.targetPortWrapper.offsetY},void 0,e?t.sourceWrapper.bounds:t.targetWrapper.bounds);var o=e?t.sourcePortWrapper.bounds:t.targetPortWrapper.bounds;r=i?"Top"===s?{x:o.topCenter.x,y:o.topCenter.y}:"Left"===s?{x:o.middleLeft.x,y:o.middleLeft.y}:"Right"===s?{x:o.middleRight.x,y:o.middleRight.y}:{x:o.bottomCenter.x,y:o.bottomCenter.y}:{x:o.center.x,y:o.center.y}}else r=e&&this.startNode||!e&&this.targetNode?e?{x:this.startNode.wrapper.offsetX,y:this.startNode.wrapper.offsetY}:{x:this.targetNode.wrapper.offsetX,y:this.targetNode.wrapper.offsetY}:e?{x:t.sourcePoint.x,y:t.sourcePoint.y}:{x:t.targetPoint.x,y:t.targetPoint.y};return r},n.prototype.refreshConnectorSegments=function(t,e,i,r){var h,c,f,p,g,y,S,b,M,w,C,s=e.sourceID,o=e.targetID,a=e.sourcePortID,l=e.targetPortID;if(function Ure(n,t){var e=0;return n.constraints&qe.LineRouting?e=n.constraints&qe.LineRouting:n.constraints&qe.InheritLineRouting&&(e=t.constraints&nt.LineRouting),e}(e,t)||r){this.startNode=t.nameTable[""+s],this.targetNode=t.nameTable[""+o],this.intermediatePoints=[],this.startArray=[],this.targetGridCollection=[],this.sourceGridCollection=[],this.startGrid=void 0,this.targetGrid=void 0;for(var D=0;D0;){var L=this.startArray.pop();if(L){for(D=0;D1&&(e.segments=[]),this.updateConnectorSegments(t,this.intermediatePoints,this.gridCollection,e,i)){this.considerWalkable=[];break e}this.targetGridCollection.splice(this.targetGridCollection.indexOf(O),1),L=this.startArray.pop()}}L&&this.findPath(L)}}}},n.prototype.checkChildNodes=function(t,e){var i=!1,r=!1;if(t.nodeId.length>=1&&!e)for(var s=0;s1&&this.targetGridCollection[0].nodeId.length>1)for(var c=0;c<=1;c++){for(var d=this.targetGridCollection[parseInt(c.toString(),10)].gridX,u=this.targetGridCollection[parseInt(c.toString(),10)].gridY,f=this.targetGridCollection[parseInt(c.toString(),10)].nodeId,p=void 0,g=0;g=e.right&&t.top<=e.top&&t.bottom>=e.bottom},n.prototype.getEndvalue=function(t,e){return this.gridCollection[t.gridX][t.gridY].walkable?t:"left"===e?this.getEndvalue(this.gridCollection[t.gridX-1][t.gridY],e):"right"===e?this.getEndvalue(this.gridCollection[t.gridX+1][t.gridY],e):"top"===e?this.getEndvalue(this.gridCollection[t.gridX][t.gridY-1],e):"bottom"===e?this.getEndvalue(this.gridCollection[t.gridX][t.gridY+1],e):t},n.prototype.changeValue=function(t,e,i){t.walkable||this.considerWalkable.push(t);for(var r,s=0;s<=e;s++)"left"===i?r=this.gridCollection[t.gridX-s][t.gridY]:"right"===i?r=this.gridCollection[t.gridX+s][t.gridY]:"top"===i?r=this.gridCollection[t.gridX][t.gridY-s]:"bottom"===i&&(r=this.gridCollection[t.gridX][t.gridY+s]),r.walkable||this.considerWalkable.push(r)},n.prototype.getIntermediatePoints=function(t){var e;for(this.intermediatePoints=[];t;)this.intermediatePoints.push({x:t.gridX,y:t.gridY}),t=t.parent;this.intermediatePoints.reverse(),this.intermediatePoints.length>=1&&void 0!==this.intermediatePoints[0]&&void 0!==this.intermediatePoints[1]&&(this.intermediatePoints[0].x===this.intermediatePoints[1].x?this.intermediatePoints[0].yi.y&&o.y>s.y){for(var a=i.xi.x&&o.x>s.x)){for(var u=i.y=1&&u.length>1&&(g=u[u.length-2].x!==u[u.length-1].x?u[u.length-2].x>u[u.length-1].x?"Left":"Right":u[u.length-2].y>u[u.length-1].y?"Top":"Bottom"),M>=2&&v===g&&u.length>1&&u.splice(u.length-2,1),v=g);if(u&&u.length>1){for(var w=0;wD.x?S.bounds.middleLeft:S.bounds.middleRight),w===u.length-2&&""===r.targetPortID&&y&&(l=C.x>D.x?y.bounds.middleRight:y.bounds.middleLeft),0===w&&b&&(C.x=b.x,C.y=D.y=b.y,b=qa(r,0,b,Nl(S.bounds,_n(C.x>D.x?"Left":"Right")),!1),C.x=b.x),w===u.length-2&&l&&(w>0&&r.targetDecorator&&l.x-D.x<0&&Math.abs(l.x-C.x)0&&r.targetDecorator&&l.x-D.x>0&&Math.abs(l.x-C.x)D.y?S.bounds.topCenter:S.bounds.bottomCenter),w===u.length-2&&""===r.targetPortID&&y&&(l=C.y>D.y?y.bounds.bottomCenter:y.bounds.topCenter),0===w&&b&&(C.y=b.y,C.x=D.x=b.x,b=qa(r,0,b,Nl(S.bounds,_n(C.y>D.y?"Top":"Bottom")),!1),C.y=b.y),w===u.length-2&&l&&(w>0&&r.targetDecorator&&l.y-D.y<0&&Math.abs(l.y-C.y)0&&r.targetDecorator&&l.y-D.y>0&&Math.abs(l.y-C.y)D.x?(f="Left",p=C.x-D.x):(f="Right",p=D.x-C.x):C.y>D.y?(f="Top",p=C.y-D.y):(f="Bottom",p=D.y-C.y),o.push({type:"Orthogonal",length:p,direction:f})}}if(o&&o.length>0){var L=o[o.length-1];if(1===o.length&&(L.length-=20),L.length<10&&2===o.length&&(o.pop(),o.length>0&&(o[0].length-=20,L=o[0])),r.targetDecorator&&("Top"===L.direction||"Bottom"===L.direction)&&L.length>r.targetDecorator.height+1||("Right"===L.direction||"Left"===L.direction)&&L.length>r.targetDecorator.width+1)return r.segments=o,s&&t.connectorPropertyChange(r,{},{type:"Orthogonal",segments:o}),!0}return!1},n.prototype.findPath=function(t){for(var e,i=[],r=this.findNearestNeigbours(t,this.gridCollection,!0),s=0;sl)&&(e.x!==t.gridX||e.y!==t.gridY)&&(i.push(e),o.previousDistance=l,o.afterDistance=o.afterDistance||this.manhattan(Math.abs(e.x-this.targetGrid.gridX),Math.abs(e.y-this.targetGrid.gridY)),o.totalDistance=o.previousDistance+o.afterDistance,o.parent=t)}if(i.length>0)for(s=0;st?i*t+e:i*e+t},n.prototype.manhattan=function(t,e){return t+e},n.prototype.findNearestNeigbours=function(t,e,i){var r=[],s=t.parent;if(s){var o=(t.gridX-s.gridX)/Math.max(Math.abs(t.gridX-s.gridX),1),a=(t.gridY-s.gridY)/Math.max(Math.abs(t.gridY-s.gridY),1);0!==o?(this.isWalkable(t.gridX,t.gridY-1,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX][t.gridY-1])&&r.push(e[t.gridX][t.gridY-1]),this.isWalkable(t.gridX,t.gridY+1,!0)&&this.sourceGridCollection.indexOf(e[t.gridX][t.gridY+1])&&r.push(e[t.gridX][t.gridY+1]),this.isWalkable(t.gridX+o,t.gridY,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX+o][t.gridY])&&r.push(e[t.gridX+o][t.gridY])):0!==a&&(this.isWalkable(t.gridX-1,t.gridY,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX-1][t.gridY])&&r.push(e[t.gridX-1][t.gridY]),this.isWalkable(t.gridX+1,t.gridY,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX+1][t.gridY])&&r.push(e[t.gridX+1][t.gridY]),this.isWalkable(t.gridX,t.gridY+a,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX][t.gridY+a])&&r.push(e[t.gridX][t.gridY+a]))}else this.neigbour(t,"top",r,i),this.neigbour(t,"right",r,i),this.neigbour(t,"bottom",r,i),this.neigbour(t,"left",r,i);return r},n.prototype.neigbour=function(t,e,i,r){for(var o,s=1;s>0;){var a="top"===e||"bottom"===e?t.gridX:"left"===e?t.gridX-s:t.gridX+s,l="right"===e||"left"===e?t.gridY:"top"===e?t.gridY-s:t.gridY+s;if((o=this.gridCollection[parseInt(a.toString(),10)][parseInt(l.toString(),10)])&&(r&&-1===this.sourceGridCollection.indexOf(o)||!r&&-1===this.targetGridCollection.indexOf(o)))return i&&this.isWalkable(a,l)&&i.push(o),s;if(!(a>0&&l>0))break;s++}return null},n.prototype.resetGridColl=function(t,e,i){for(var s,r=1;r>0;){var o="top"===e||"bottom"===e?t.gridX:"left"===e?t.gridX-r:t.gridX+r,a="right"===e||"left"===e?t.gridY:"top"===e?t.gridY-r:t.gridY+r;if((s=this.gridCollection[parseInt(o.toString(),10)][parseInt(a.toString(),10)])&&(i&&-1===this.sourceGridCollection.indexOf(s)||!i&&-1===this.targetGridCollection.indexOf(s))){if(this.isWalkable(o,a))break;var l=this.gridCollection[parseInt(o.toString(),10)][parseInt(a.toString(),10)];this.considerWalkable.push(l)}if(!(o>0&&a>0))break;"top"===e||"left"===e?r--:r++}return null},n.prototype.isWalkable=function(t,e,i){if(t>=0&&t=0&&e0?1:-1,this.isWalkable(h,c-1)&&!this.isWalkable(h-a,c-1)||this.isWalkable(h,c+1)&&!this.isWalkable(h-a,c+1)))return{x:t,y:e};if(0!==l){if(l=l>0?1:-1,this.isWalkable(h-1,c)&&!this.isWalkable(h-1,c-l)||this.isWalkable(h+1,c)&&!this.isWalkable(h+1,c-l))return{x:t,y:e};if(this.findIntermediatePoints(h+1,c,h,c,s,o)||this.findIntermediatePoints(h-1,c,h,c,s,o))return{x:t,y:e}}return this.findIntermediatePoints(h+a,c+l,h,c,s,o)},n.prototype.destroy=function(){},n.prototype.getModuleName=function(){return"LineRouting"},n}(),$oe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Joe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return $oe(t,n),function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);r>3&&s&&Object.defineProperty(t,e,s)}([I(!0)],t.prototype,"inversedAlignment",void 0),t}(Ee),Koe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Oe=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},CT=function(n,t,e,i){return new(e||(e=Promise))(function(r,s){function o(h){try{l(i.next(h))}catch(c){s(c)}}function a(h){try{l(i.throw(h))}catch(c){s(c)}}function l(h){h.done?r(h.value):new e(function(c){c(h.value)}).then(o,a)}l((i=i.apply(n,t||[])).next())})},ET=function(n,t){var i,r,s,o,e={label:0,sent:function(){if(1&s[0])throw s[1];return s[1]},trys:[],ops:[]};return o={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function a(h){return function(c){return function l(h){if(i)throw new TypeError("Generator is already executing.");for(;e;)try{if(i=1,r&&(s=2&h[0]?r.return:h[0]?r.throw||((s=r.return)&&s.call(r),0):r.next)&&!(s=s.call(r,h[1])).done)return s;switch(r=0,s&&(h=[2&h[0],s.value]),h[0]){case 0:case 1:s=h;break;case 4:return e.label++,{value:h[1],done:!1};case 5:e.label++,r=h[1],h=[0];continue;case 7:h=e.ops.pop(),e.trys.pop();continue;default:if(!(s=(s=e.trys).length>0&&s[s.length-1])&&(6===h[0]||2===h[0])){e=0;continue}if(3===h[0]&&(!s||h[1]>s[0]&&h[1]0&&((!s.style||!s.style.fill)&&(o.style.fill="transparent"),(!s.style||!s.style.strokeColor)&&(o.style.strokeColor="transparent")),s.shape&&"UmlActivity"===s.shape.type&&JI(s,o),s.shape&&"SwimLane"===s.shape.type&&aF(s,o),r.nodeDefaults&&Ro(o,s,r.nodeDefaults),r.updateAnnotationText(o.annotations);if(e&&e.connectors)for(a=0;e&&e.connectors&&a0&&0===i.nodes.length)this.clearCollection(),a=!0;else{for(var g=0,v=Object.keys(e.nodes);g0&&0===i.connectors.length)this.clearCollection(!0),a=!0;else{for(var C=0,D=Object.keys(e.connectors);C0){this.renderSelector(!0);break}if(e.selectedItems.constraints){this.renderSelector(!0);break}break;case"snapSettings":this.updateSnapSettings(e);break;case"commandManager":this.initCommands();break;case"layout":o=!0;break;case"segmentThumbShape":this.updateSelector();break;case"dataSourceSettings":this.clear(),"None"===this.layout.type?a=!0:(this.initObjects(),o=!0);break;case"tooltip":i3(this);break;case"rulerSettings":this.updateRulerSettings(e);break;case"layers":this.updateLayer(e);break;case"scrollSettings":this.scrollActions|=da.PropertyChange,this.updateScrollSettings(e),this.scrollActions&=~da.PropertyChange,this.scrollSettings.horizontalOffset=-this.scroller.horizontalOffset||0,this.scrollSettings.verticalOffset=-this.scroller.verticalOffset||0;break;case"locale":e.locale!==i.locale&&(this.realActions|=$i.PreventDataInit,n.prototype.refresh.call(this),this.realActions&=~$i.PreventDataInit);break;case"contextMenuSettings":if(void 0!==e.contextMenuSettings.showCustomMenuOnly&&(this.contextMenuSettings.showCustomMenuOnly=e.contextMenuSettings.showCustomMenuOnly),void 0!==e.contextMenuSettings.show&&(this.contextMenuSettings.show=e.contextMenuSettings.show),e.contextMenuSettings.items){for(var A=e.contextMenuSettings.items,x=0,P=Object.keys(A);x0){for(var N=[],T=O.ports.length-1;T>=0;T--)"LineDistribution"===O.ports[parseInt(T.toString(),10)].id.split("_")[1]&&N.push(O.ports[parseInt(T.toString(),10)]);this.removePorts(O,N)}}for(T=0;T0)for(var ue=0,fe=Object.keys(e.nodes);ue0)for(var De=0,xe=Object.keys(e.connectors);De=0;o--)this.commandHandler.expandNode(r[parseInt(o.toString(),10)],this,0!==o);this.canLayout&&this.doLayout(),this.lineRoutingModule?this.connectors.sourceID!==this.connectors.targetID&&this.lineRoutingModule.lineRouting(this):this.constraints&nt.LineRouting&&console.warn('[WARNING] :: Module "LineRouting" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),this.validatePageSize(),this.renderPageBreaks(),this.diagramRenderer.renderSvgGridlines(this.snapSettings,Fd(this.element.id),this.scroller.transform,this.rulerSettings,this.hRuler,this.vRuler),this.commandHandler.initSelectorWrapper(),this.notify("initial-load",{}),this.trigger("load"),this.scroller.setSize(),this.scroller.updateScrollOffsets(),this.isRefreshed||this.refreshDiagramLayer(),(this.scrollSettings.verticalOffset>0||this.scrollSettings.horizontalOffset>0)&&this.updateScrollOffset(),X.isDevice&&(this.tool=ri.ZoomPan|ri.SingleSelect),this.notify("initial-end",{}),this.isProtectedOnChange=!1,this.tooltipObject=i3(this),this.diagramActions=ee.Render,this.initCommands();var a=document.getElementsByClassName(this.element.id+"_hiddenUserHandleTemplate");(function Ioe(n,t,e,i){var r,s,o,a,l,d=document.getElementById(i).ej2_instances[0];if(n&&t){r=UF(n);for(var u=0,f=e.userHandles;u0;)e[0].parentNode.removeChild(e[0]);var i=document.getElementById(this.element.id+"content");i&&this.element.removeChild(i);var r="measureElement";if(window[""+r]){window[""+r].usageCount-=1;var s="measureElementCount";window[""+s]--,0===window[""+s]&&(window[""+r].parentNode.removeChild(window[""+r]),window[""+r]=null)}}window.domTable={};for(var a=0;a1&&(this.callBlazorModel=!1,this.insertBlazorDiagramObjects(this.selectedItems),this.commandHandler.group(),this.callBlazorModel=!0,this.commandHandler.getBlazorOldValues())},t.prototype.unGroup=function(){this.callBlazorModel=!1,this.insertBlazorDiagramObjects(this.selectedItems),this.commandHandler.unGroup(),this.callBlazorModel=!0,this.commandHandler.getBlazorOldValues()},t.prototype.sendToBack=function(){this.commandHandler.sendToBack()},t.prototype.setActiveLayer=function(e){var i=this.commandHandler.getLayer(e);this.activeLayer=i},t.prototype.addLayer=function(e,i){this.commandHandler.addLayer(e,i)},t.prototype.removeLayer=function(e){this.commandHandler.removeLayer(e,ce())},t.prototype.moveObjects=function(e,i){$(this.layers),this.enableServerDataBinding(!1),this.commandHandler.moveObjects(e,i)},t.prototype.layerObjectUpdate=function(){},t.prototype.sendLayerBackward=function(e){this.layerObjectUpdate(),this.commandHandler.sendLayerBackward(e)},t.prototype.bringLayerForward=function(e){this.layerObjectUpdate(),this.commandHandler.bringLayerForward(e)},t.prototype.cloneLayer=function(e){this.commandHandler.cloneLayer(e)},t.prototype.bringToFront=function(){this.commandHandler.bringToFront()},t.prototype.moveForward=function(){this.commandHandler.sendForward()},t.prototype.sendBackward=function(){this.commandHandler.sendBackward()},t.prototype.getObject=function(e){return this.nameTable[""+e]},t.prototype.getNodeObject=function(e){return $(this.nameTable[""+e])},t.prototype.getConnectorObject=function(e){return $(this.nameTable[""+e])},t.prototype.getActiveLayer=function(){return this.activeLayer},t.prototype.nudgeCommand=function(e,i,r){if("object"!=typeof e&&(this.selectedItems.nodes.length||this.selectedItems.connectors.length)>0){var s=void 0;i.type&&"KEYDOWN"===i.type&&(s=i.type),this.nudge(e,void 0,void 0,s)}},t.prototype.nudge=function(e,i,r,s){var o=0,a=0;"Left"===e||"Right"===e?o=("Left"===e?-1:1)*(i||1):a=("Up"===e?-1:1)*(r||1),"KEYDOWN"===s&&(o*=5,a*=5);var h=this.selectedItems,c=this.selectedItems.wrapper.children[0];if(c instanceof li)this.commandHandler.labelDrag(h.nodes[0],c,o,a);else{var d=$(this.selectedItems);this.protectPropertyChange(!0),this.drag(h,o,a),this.protectPropertyChange(!1);var u={type:"PositionChanged",redoObject:$(this.selectedItems),undoObject:d,category:"Internal"};this.addHistoryEntry(u)}this.refreshCanvasLayers()},t.prototype.insertBlazorDiagramObjects=function(e){},t.prototype.drag=function(e,i,r){if(this.insertBlazorDiagramObjects(e),!(this.bpmnModule&&e instanceof te&&this.bpmnModule.updateAnnotationDrag(e,this,i,r))){if(e instanceof ei){if(this.preventConnectorsUpdate=!0,e.nodes&&e.nodes.length){for(var o=0,a=e.nodes;o0&&o.nodes[0].children){this.fromUndo||(this.rotateUsingButton=!0);for(var h=this.commandHandler.getAllDescendants(o.nodes[0],[]),c=0;c0&&o.nodes[0].children){var g={type:"RotationChanged",redoObject:$(e),undoObject:$(o),category:"Internal",childTable:a};this.commandHandler.addHistoryEntry(g),this.commandHandler.updateSelector()}return u},t.prototype.dragSourceEnd=function(e,i,r){this.insertBlazorDiagramObjects(e),this.commandHandler.dragSourceEnd(e,i,r),this.callBlazorModel&&this.commandHandler.getBlazorOldValues()},t.prototype.dragTargetEnd=function(e,i,r){this.insertBlazorDiagramObjects(e),this.commandHandler.dragTargetEnd(e,i,r),this.callBlazorModel&&this.commandHandler.getBlazorOldValues()},t.prototype.findObjectsUnderMouse=function(e,i){return this.eventHandler.findObjectsUnderMouse(e,i)},t.prototype.findObjectUnderMouse=function(e,i,r){return this.eventHandler.findObjectUnderMouse(e,i,r)},t.prototype.findTargetObjectUnderMouse=function(e,i,r,s,o){return this.eventHandler.findTargetUnderMouse(e,i,r,s,o)},t.prototype.findElementUnderMouse=function(e,i,r,s){return this.eventHandler.findElementUnderMouse(e,i,r,s)},t.prototype.findActionToBeDone=function(e,i,r,s){return this.eventHandler.findActionToBeDone(e,i,r,s)},t.prototype.updateConnectorPort=function(e){if(e.ports.length)for(var i=void 0,r=0,s=e.ports;r=0;s--)if(i.push(r[parseInt(s.toString(),10)]),i.length>this.historyManager.stackLimit)return i}else i=r;return i},t.prototype.getEdges=function(e){return e.outEdge?this.nameTable[e.id].outEdges:this.nameTable[e.id].inEdges},t.prototype.getParentId=function(e){return this.nameTable[""+e].parentId},t.prototype.addConnector=function(e){return this.add(e)},t.prototype.UpdateBlazorDiagramModelCollection=function(e,i,r,s){},t.prototype.UpdateBlazorDiagramModel=function(e,i,r,s){},t.prototype.UpdateBlazorLabelOrPortObjects=function(e,i,r,s){},t.prototype.addBlazorDiagramObjects=function(){},t.prototype.removeNodeEdges=function(e,i,r){var s=this.nameTable[""+e],o=r?s.outEdges:s.inEdges;if(o.length>0)for(var a=0;a0)){for(var c=0;c0))}this.removePortEdges(l,a.element.sourcePortID,a.element.id,h)}a.element.targetID&&this.removeNodeEdges(a.element.targetID,a.element.id,!1)}}this.diagramActions=this.diagramActions|ee.PublicMethod,e.id=e.id||Qe();var u=this.activeLayer;if(!a.cancel&&u&&!u.lock){if(u.objects.indexOf(e.id)<0&&!u.lock&&(u.visible||(u.visible=!0,this.dataBind()),u.objects.push(e.id)),ps(e)===de)(r=new de(this,"connectors",e,!0)).status="New",this.nameTable[r.targetID]&&"TextAnnotation"===this.nameTable[r.targetID].shape.shape&&(r.isBpmnAnnotationConnector=!0,r.constraints=r.constraints&~qe.Delete),Ro(r,e,this.connectorDefaults),this.connectors.push(r),this.initObject(r),!1===e.visible&&this.updateElementVisibility(r.wrapper,r,e.visible),this.updateEdges(r),this.insertBlazorConnector(r);else{if(Ro(r=new te(this,"nodes",e,!0),e,this.nodeDefaults),r.parentId=e.parentId?e.parentId:r.parentId,r.umlIndex=e.umlIndex,r.status="New",(o="TextAnnotation"===r.shape.shape)&&!e.isTextAnnotationCopied&&(r.inEdges=e.inEdges?e.inEdges:r.inEdges),this.nodes.push(r),this.initObject(r,u,void 0,i),o&&this.bpmnModule)for(c=0;c-1&&e.parentId&&this.nameTable[e.parentId]&&"UmlClassifier"===this.nameTable[e.parentId].shape.type){var g=this.nameTable[e.parentId];g.children.splice(r.umlIndex,0,r.id),g.wrapper.children.splice(r.umlIndex,0,r.wrapper),g.wrapper.measure(new me),g.wrapper.arrange(g.wrapper.desiredSize),this.updateDiagramObject(g)}}if(a={element:r,cause:this.diagramActions,diagramAction:this.getDiagramAction(this.diagramActions),state:"Changed",type:"Addition",cancel:!1},this.parentObject&&(a.parentId=this.parentObject.id),"helper"!==e.id&&!(this.diagramActions&ee.PreventCollectionChangeOnDragOver)&&this.triggerEvent(Ce.collectionChange,a),!(this.diagramActions&ee.UndoRedo||this.diagramActions&ee.Group||this.diagramActions&ee.PreventHistory)){var v={type:"CollectionChanged",changeType:"Insert",undoObject:$(e),redoObject:$(e),category:"Internal"};this.addHistoryEntry(v)}this.parentObject=void 0,"SVG"===this.mode&&(this.updateSvgNodes(r),this.updateTextElementValue(r),this.updateDiagramObject(r),o&&this.updateDiagramObject(this.nameTable[r.inEdges[0]]),r.shape.activity&&r.shape.activity.subProcess.processes&&r.shape.activity.subProcess.processes.length&&this.updateProcesses(r),this.updateBridging())}}if(this.protectPropertyChange(s),this.resetDiagramActions(ee.PublicMethod),r&&this.layers.length>1&&this.moveNode(r),this.views)for(var S=0,b=this.views;S=0;l--)this.moveSvgNode(a[parseInt(l.toString(),10)])}for(var h=0,c=i;h=0;o--)r[parseInt(o.toString(),10)]===e.id&&r.splice(o,1);for(var a=0;s.ports&&a=0;s--)if(i=this.nameTable[r[parseInt(s.toString(),10)]])if(this.connectorTable[i.id]=$(i),i.isBpmnAnnotationConnector){var o=this.nameTable[i.targetID];this.removeObjectsFromLayer(i);var a=this.connectors.indexOf(i);-1!==a&&this.connectors.splice(a,1),this.removeElements(i),this.removeFromAQuad(i),delete this.nameTable[i.id];var l=this.nameTable[i.sourceID];if(l){var h=l.outEdges.indexOf(i.id);-1!==h&&l.outEdges.splice(h,1)}e.id!==i.targetID&&this.remove(o)}else this.remove(i)},t.prototype.removeObjectsFromLayer=function(e){if(e.children)for(var i=0;i-1&&(_r(this,e)&&this.unSelect(e),this.layers[parseInt(s.toString(),10)].objects.splice(a,1),delete this.layers[parseInt(s.toString(),10)].zIndexTable[this.nameTable[e.id].zIndex])},t.prototype.removeElements=function(e){if("SVG"===this.mode||"Canvas"===this.mode&&"Native"===e.shape.type){var i=xt(e.id+"_groupElement",this.element.id),r=e;if(r.ports&&r.ports.length>0)for(var s=0;s0){l[parseInt(s.toString(),10)].id.indexOf("icon_content")>0&&"SVG"===this.mode&&((h=xt(l[parseInt(s.toString(),10)].id+"_shape_groupElement",this.element.id))&&h.parentNode.removeChild(h),(h=xt(l[parseInt(s.toString(),10)].id+"_rect_groupElement",this.element.id))&&h.parentNode.removeChild(h));for(var c=0,d=this.views;c=0;o--)a.children[parseInt(o.toString(),10)].children&&(l=n.nameTable[a.children[parseInt(o.toString(),10)].id])&&(l.isLane?qv(n,l):(n.removeDependentConnector(l),n.diagramActions|=ee.PreventHistory,l.constraints&ie.Delete?n.remove(l):V3(n,l,{},!1),n.diagramActions&=~ee.PreventHistory));a&&(i=n.nameTable[a.id])&&qv(n,i)}}(this,e),!(this.diagramActions&ee.UndoRedo||this.diagramActions&ee.PreventHistory)&&(e instanceof te||e instanceof de)){var o={type:"CollectionChanged",changeType:"Remove",undoObject:$(e),redoObject:$(e),category:"Internal"};this.diagramActions&ee.Clear||e.children&&!e.isLane&&!e.isPhase&&e.children.length>0&&this.undoRedoModule&&"None"===this.layout.type&&(this.historyManager.startGroupAction(),s=!0),(e instanceof te||e instanceof de)&&this.deleteDependentConnector&&this.removeDependentConnector(e),!e.isLane&&!e.isPhase&&!(this.diagramActions&ee.Clear)&&!this.isStackChild(e)&&this.addHistoryEntry(o)}"TextAnnotation"===e.shape.shape&&this.removeDependentConnector(e),e.children&&!e.isLane&&!e.isPhase&&(!(this.diagramActions&ee.UndoRedo)||!ce())&&this.deleteGroup(e),e.parentId&&(this.deleteChild(e,void 0,!0),this.nameTable[e.parentId]&&"UmlClassifier"===this.nameTable[e.parentId].shape.type&&(this.updateDiagramObject(this.nameTable[e.parentId]),this.updateConnectorEdges(this.nameTable[e.parentId])));var a=void 0;this.diagramActions=this.diagramActions|ee.PublicMethod;var l=this.nameTable[e.id];if(l instanceof te?("Bpmn"===l.shape.type&&this.bpmnModule&&this.bpmnModule.removeBpmnProcesses(l,this),(l.isLane||l.isPhase||"SwimLane"===l.shape.type)&&(h=l.isLane||l.isPhase?this.nameTable[l.parentId]:this.nameTable[l.id],l.isLane?_3(this,l,h):l.isPhase&&U3(this,l,h)),-1!==(a=this.nodes.indexOf(l))&&(this.crudDeleteNodes.push(this.nameTable[l.id]),this.nodes.splice(a,1),this.updateNodeEdges(l))):(-1!==(a=this.connectors.indexOf(l))&&(this.crudDeleteNodes.push(this.nameTable[l.id]),this.connectors.splice(a,1)),this.updateEdges(l),this.spliceConnectorEdges(e,!0),this.spliceConnectorEdges(e,!1)),!this.isServerUpdate&&!(this.blazorActions&on.GroupClipboardInProcess)&&this.commandHandler.getBlazorOldValues(),s&&this.historyManager.endGroupAction(),_r(this,l)&&this.unSelect(l),!l.isPhase){if(this.removeObjectsFromLayer(e),this.currentDrawingObject&&(this.currentDrawingObject.wrapper=void 0),delete this.nameTable[e.id],i.length>0&&i[0].id===l.id&&l.parentId){var h,d=this.nameTable[l.parentId];d&&d.isLane&&"SwimLane"===this.nameTable[d.parentId].shape.type&&F3(this,h=this.nameTable[d.parentId],d,l)}this.removeElements(l),this.updateBridging(),"SVG"!==this.mode&&this.refreshDiagramLayer(),this.diagramActions&ee.Clear||(this.removeFromAQuad(l),r={element:e,cause:this.diagramActions,diagramAction:this.getDiagramAction(this.diagramActions),state:"Changed",type:"Removal",cancel:!1},"helper"!==e.id&&this.triggerEvent(Ce.collectionChange,r),this.resetTool())}}}else if(i.length>0){this.undoRedoModule&&(this.historyManager.startGroupAction(),this.blazorActions|=on.GroupingInProgress,s=!0);for(var u=0;u=p.wrapper.bounds.width&&"Horizontal"===p.shape.orientation||this.selectedItems.wrapper.bounds.y<=p.wrapper.bounds.y+g&&this.selectedItems.wrapper.bounds.height>=p.wrapper.bounds.height-g&&"Vertical"===p.shape.orientation)&&(TI(p)||p.shape.lanes.length>1)&&this.remove(i[parseInt(u.toString(),10)])}}else this.remove(i[parseInt(u.toString(),10)])}s&&(this.blazorActions&=~on.GroupingInProgress,this.isServerUpdate=!0,this.commandHandler.getBlazorOldValues(),this.UpdateBlazorDiagramModelCollection(void 0,void 0,void 0,!0),this.historyManager.endGroupAction(),this.isServerUpdate=!1),this.clearSelection()}e&&(TI(e)||this.diagramActions&ee.Clear)||this.diagramActions&ee.UndoRedo||this.diagramActions&ee.PreventHistory||!(e instanceof te||e instanceof de)||(o={type:"ConnectionChanged",undoObject:$(e),redoObject:$(e),category:"Internal"},!e.isLane&&!e.isPhase&&!(this.diagramActions&ee.Clear)&&!this.isStackChild(e)&&this.addHistoryEntry(o)),this.tooltipObject.close()},t.prototype.isStackChild=function(e){var i,r=this.nameTable[e.parentId];if(e&&e.parentId&&r.container&&"Stack"===r.container.type&&"UmlClassifier"!==this.nameTable[e.parentId].shape.type){i=!0;var s={sourceIndex:r.wrapper.children.indexOf(e.wrapper),source:e,target:void 0,targetIndex:void 0};this.diagramActions&ee.UndoRedo||this.addHistoryEntry({type:"StackChildPositionChanged",redoObject:{sourceIndex:void 0,source:e,target:void 0,targetIndex:void 0},undoObject:s,category:"Internal"})}return i},t.prototype.deleteChild=function(e,i,r){var s;if(s="string"==typeof e?e:e.id,(i=i?this.nameTable[i.id]:this.nameTable[e.parentId])&&i.children){for(var o=0;o=0;i--)this.removeLayer(this.layers[parseInt(i.toString(),10)].id);this.commandHandler.addLayer({id:"default_layer",visible:!0,lock:!1,objects:[],zIndex:0,objectZIndex:-1,zIndexTable:{}},null,!0),this.setActiveLayer(this.layers[this.layers.length-1].id)},t.prototype.clearObjects=function(e){var i=[];i=e||(i=i.concat(this.nodes)).concat(this.connectors),this.diagramActions=this.diagramActions|ee.Clear;for(var r=0,s=i;r0||"Text"===e.shape.type))if("Text"===e.shape.type)i=e.wrapper.children[0].id.split("_")[1];else for(var p=e.annotations.length-1;p>=0;p--)e.annotations[parseInt(p.toString(),10)].visibility&&(i=e.annotations[parseInt(p.toString(),10)].id);i&&(u=this.getWrapper(e.wrapper,i))}if(e&&u&&!(u instanceof es)&&(!function Xre(n,t){return"Text"===t.shape.type?t.constraints&ie.ReadOnly:t.constraints&(t instanceof de?qe.ReadOnly:ie.ReadOnly)?n.constraints&Nr.InheritReadOnly?1:0:n.constraints&Nr.ReadOnly?1:0}(u,e)||f)){var g=u.style,v=void 0;v=90>(v=u.bounds.width50?50:e.width,u.style.fontSize)),e.parentId&&"UmlClassifier"===this.nameTable[e.parentId].shape.type?(l.width=e.wrapper.bounds.width-20,c=(e.wrapper.bounds.center.x+r.tx)*r.scale-l.width/2*s-2.5,d=(e.wrapper.bounds.center.y+r.ty)*r.scale-l.height/2*s-3,u.style.textAlign="Left"):(l.width=Math.max(l.width,50),c=(u.bounds.center.x+r.tx)*r.scale-l.width/2*s-2.5,d=(u.bounds.center.y+r.ty)*r.scale-l.height/2*s-3),Ho(y,{id:this.element.id+"_editTextBoxDiv",style:"position: absolute;left:"+c+"px;top:"+d+"px;width:"+(l.width+1)*s+"px;height:"+l.height*s+"px; containerName:"+e.id+";"}),Ho(S,{"aria-label":a,id:this.element.id+"_editBox",style:"width:"+(l.width+1)*s+"px;height:"+l.height*s+"px;resize: none;outline: none;overflow: hidden;;font-family:"+g.fontFamily+";font-size:"+g.fontSize*s+"px;text-align:"+u.style.textAlign.toLocaleLowerCase()+";",class:"e-diagram-text-edit"}),S.style.fontWeight=g.bold?"bold":"",S.style.fontStyle=g.italic?"italic":"",S.style.lineHeight=(1.2*g.fontSize+"px;").toString(),S.style.textDecoration=g.textDecoration?g.textDecoration:"",this.activeLabel.parentId=e.id,this.activeLabel.id=i,u.visible=!1,this.updateDiagramObject(e),this.diagramActions=this.diagramActions|ee.TextEdit,this.isTriggerEvent||(E.add(S,"input",this.eventHandler.inputChange,this.eventHandler),E.add(S,"focusout",this.focusOutEdit,this),S.select())}}}},t.prototype.updateConnectorfixedUserHandles=function(e){if(e.fixedUserHandles.length)for(var i=void 0,r=0,s=e.fixedUserHandles;r0&&this.mindMapChartModule.updateLayout(o,this.nameTable,this.layout,l,this.dataSourceSettings.id,this.dataSourceSettings.root),e=!0;else if(this.radialTreeModule)this.radialTreeModule.updateLayout(o,this.nameTable,this.layout,l),e=!0;else if(this.symmetricalLayoutModule)this.symmetricalLayoutModule.maxIteration=this.layout.maxIteration,this.symmetricalLayoutModule.springLength=this.layout.springLength,this.symmetricalLayoutModule.springFactor=this.layout.springFactor,this.symmetricalLayoutModule.updateLayout(o,this.connectors,this.symmetricalLayoutModule,this.nameTable,this.layout,l),e=!0;else if(this.complexHierarchicalTreeModule){this.canDistribute(a,r)&&(this.lineDistributionModule.diagram=this,this.connectors.forEach(function(P){P.obstaclePointCollection=[]}));var c=this.complexHierarchicalTreeModule.getLayoutNodesCollection(this.nodes);c.length>0&&this.complexHierarchicalTreeModule.doLayout(c,this.nameTable,this.layout,l,this),e=!0,this.canDistribute(a,r)&&this.lineDistributionModule.initLineDistribution(this.layout,this)}else this.flowchartLayoutModule?(this.flowchartLayoutModule.updateLayout(this.nodes,this),e=!0):console.warn("[WARNING] :: Module "+("OrganizationalChart"===this.layout.type?"HierarchicalTree":this.layout.type)+" is not available in Diagram component! You either misspelled the module name or forgot to load it.");if(e){this.preventDiagramUpdate=!0;for(var u={},p=0,g=o;p0)for(var S=0;S0)for(var M=0;M0)for(var s=0,o=r.ports;s0&&function Ese(n){var t,e,i,r=[];for(t=0;t0&&y.connectors[w].bezierSettings&&y.connectors[w].bezierSettings.allowSegmentsReset&&(y.connectors[w].segments=[]);if(t.connectors=y.connectors||[],t.dataSourceSettings=y.dataSourceSettings||{},t.dataSourceSettings.doBinding=i,t.height=y.height||"100%",t.setNodeTemplate=r,t.getConnectorDefaults=v,t.getNodeDefaults=g,t.getCustomProperty=o,t.mode=y.mode||"SVG",y.nodes)for(w=0;w0)){var r=this.nodes.filter(function(a){return 0===a.inEdges.length})[0],s=this.convertMindmapToMermaid(r,0);i.push(s),this.updateTextDataSource(i,r.outEdges,1),e=(i=i.filter(function(a){return""!==a.trim()})).join("\n")}return e},t.prototype.updateTextDataSource=function(e,i,r){for(var s=0;s0&&this.updateTextDataSource(e,h,r+1),s++}},t.prototype.convertMindmapToMermaid=function(e,i){var r=e.id,o=" ".repeat(2*(i+1)),a=e.annotations.length>0?e.annotations[0].content.replace(/\n/g," "):"",l=o+a,h=o+r;if(e.shape&&"Basic"===e.shape.type){var c=e.shape;"Rectangle"===c.shape?l=h+"["+a+"]":"Ellipse"===c.shape?l=h+"(("+a+"))":"Hexagon"===c.shape&&(l=h+"{{"+a+"}}")}else if(e.shape&&"Flow"===e.shape.type)"Terminator"===e.shape.shape&&(l=h+"("+a+")");else if(e.shape&&"Path"===e.shape.type){var u=e.shape;u.data===this.bangShape?l=h+"))"+a+"((":u.data===this.cloudShape&&(l=h+")"+a+"(")}return l},t.prototype.saveFlowDiagramInMermaidFormat=function(){var e=this,i=[],r="graph TD\n",s={nodes:this.nodes,edges:this.connectors};return s.nodes.reduce(function(a,l){return a[l.id]=l.annotations.length?l.annotations[0].content:"",a},{}),s.edges.forEach(function(a){var l=a.sourceID,h=a.targetID,f=e.nameTable[""+h],p=e.getNodeShape(e.nameTable[""+l]),g=e.getNodeShape(f),v=a.annotations[0]&&""!==a.annotations[0].content?"|"+a.annotations[0].content+"|":"";-1===i.indexOf(l)?i.push(l):p="",-1===i.indexOf(h)?i.push(h):g="";var y=e.arrowType(a);r+=" "+l+p+" "+y+v+" "+h+g+"\n"}),s.nodes.forEach(function(a){r+=" style "+a.id+" fill:"+a.style.fill+",stroke:"+a.style.strokeColor+",stroke-width:"+a.style.strokeWidth+"px;\n"}),r},t.prototype.arrowType=function(e){var i=e.targetDecorator.shape;return e.style.opacity<1?"~~~":""!==e.style.strokeDashArray?"-.->":"Arrow"===i?e.style.strokeWidth>1?"==>":"--\x3e":"None"===i?"---":"--\x3e"},t.prototype.getNodeShape=function(e){var i=e.annotations.length>0?e.annotations[0].content:"",r=e.shape.shape;if(!r){var s=e.shape.data;return"M 0 0 A 1 1 0 0 0 7 0 A 1 1 0 0 0 0 0 M -1 0 A 1 1 0 0 0 8 0 A 1 1 0 0 0 -1 0"===s?"((("+i+")))":"M 0 0 L 1 -1 L 5 -1 L 6 0 L 0 0"===s?"[/"+i+"\\]":"M 0 1 L 0 6 C 2 7 4 7 6 6 L 6 1 C 5 0 1 0 0 1 C 1 2 5 2 6 1"===s?"[("+i+")]":"M 0 0 L 12 0 L 14 2 L 2 2 L 0 0"===s?"[\\"+i+"\\]":"M 0 0 L 5 0 L 4 1 L 1 1 L 0 0"===s?"[\\"+i+"/]":"M 0 0 L 2 -2 L 11 -2 L 13 0 L 11 2 L 2 2 L 0 0"===s?"{{"+i+"}}":">"+i+"]"}switch(r){case"Terminator":return"(["+i+"])";case"Process":default:return"["+i+"]";case"Decision":return"{"+i+"}";case"Parallelogram":return"[/"+i+"/]";case"Ellipse":return"(("+i+"))";case"PreDefinedProcess":return"[["+i+"]]"}},t.prototype.loadDiagramFromMermaid=function(e){this.layout&&"Flowchart"===this.layout.type&&this.flowchartLayoutModule?this.convertMermaidToFlowChart(e):this.layout&&"MindMap"===this.layout.type&&this.mindMapChartModule?this.convertMermaidToMindmap(e):console.warn('[WARNING] :: Module "FlowchartLayout" or "MindMap" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.countLeadingSpaces=function(e){for(var i=0,r=e.length;i0});this.clear(),this.mermaidNodeBaseCollection=[];var r=[],s={text:"",children:[],currentLevel:0,branch:"Left"},o=[],l=!1,h=!1,c=!1;if(i.length>0){for(var d=function(M){var w=i[parseInt(M.toString(),10)],C=0,D="",A=u.countLeadingSpaces(w),x=w.includes('"`');if(h=w.includes('`"'),c=(l=!!x||l)||c?c:0===A&&M>0,l&&h&&!x)return s.text+="\n"+w,l=!1,"continue";if(!x&&l)return s.text+="\n"+w,"continue";if(l=!h&&l,w.length>0&&(/\s/.test(w[0])&&M>0||0===A)){if(-1!==o.findIndex(function(B){return B.space===A.toString()}))for(var L=o.length-1;L>=0;L--){var O=o[parseInt(L.toString(),10)];if((N=parseFloat(O.space))>A)o.splice(L,1);else{if(N=0;L--){var N,T=o[parseInt(L.toString(),10)];if(!((N=parseFloat(T.space))>A)){var z=o[o.length-1];o.push({space:A.toString(),level:z.level+1});break}o.splice(L,1)}C=o[o.length-1].level}D=w.trim().replace(/^[+-]/,"")}var U={text:D,branch:void 0,children:[],currentLevel:0===M?0:C-1};if(r.length>0){for(;r.length>=C&&0!==r.length;)r.pop();r.length>0&&r[r.length-1].children.push(U)}r.push(U),s=U},u=this,f=0;f0){var c=h[h.length-1];c.arrowType=a[2],""!==a[3]&&(c.label&&c.label.some(function(d){return d.trim().length>0})?c.label.push(a[3]):(c.label=[],c.label[c.parentId.length-1]=a[3]))}h.filter(function(d){return d.parentId&&0===d.parentId.length}).forEach(function(d){d.parentId=null}),i=i.concat(h)}}this.createFlowChart(i),this.doLayout(),this.clearHistory()},t.prototype.createFlowChart=function(e){for(var i=[],r=0;r1)for(var h=0;h|---|--\s*.*?\s*-->|~~~|==>|===|==\s*.*?\s*==>|\s*-\.\s*->|\s*-\.\s*-|\s*-\.\s*.*?\s*\.\s*->|\s*-\..*?\.\s*->)(.*)$/);if(l){i=l[1].trim();var h=l[2].trim();r=l[3].trim();var d=h.match(/(-\.|\\-\\-|==|--|~~)(.*?)(\1>|\.->|==>|\\->|~~>)/),u=void 0,f="";o=null!==(u=d?{text:d[2].trim()||null,arrowType:d[1]+d[3]}:{text:null,arrowType:h}).text?u.text:"",s=(f=u.arrowType).includes("--\x3e")?"single-line-arrow":f.includes("---")?"single-line":f.includes("==>")?"double-line-arrow":f.includes("==")?"double-line":f.includes("~~~")?"wiggly-arrow":f.includes("-.->")||f.includes(".->")?"dotted-arrow":f.includes("-.-")||f.includes(".-")?"dotted":"single-line-arrow"}return[i,r,s,o]},t.prototype.parseStyle=function(e,i){if(e.startsWith("style")){var s=e.match(/^style\s+(\w+)\s+fill:([^,]+),stroke:([^,]+),stroke-width:(\d+)px;/);if(s){var c={id:s[1],fill:s[2],stroke:s[3],strokeWidth:parseInt(s[4],10)},d=i.filter(function(u){return u.id===c.id});d[0].color=c.fill,d[0].stroke=c.stroke,d[0].strokeWidth=c.strokeWidth}}},t.prototype.getNodeData=function(e,i,r){for(var s=[],o=null,a=null,l=0,h="",c=function(v){var y=e[parseInt(v.toString(),10)],S=d.splitNested(y);if(S[0].includes("|")){var b=S[0].match(/\|([^|]*)\|/);b&&(h=b[1]);var M=S[0].split("|");M.length>=3&&(S[0]=M[2].trim())}var w=S[0].trim();if(0===v?o=w:a=w,i.find(function(L){return L.id===w}))l++;else{var D=S.length>1?S[1]:S[0],A=d.getShape(D),x=D.replace(/[\\[\]\\(\\)\\{\\}\\{\\}\\/>]/g,"");s.push({id:w,name:x,shape:A,color:"white",parentId:[]})}},d=this,u=0;u"===h?0===s?(r.trim().length>0&&i.push(r.trim()),r=h,o=h,s++):(r+=h,s++):"]"===h||"}"===h||")"===h?1===s&&h===o?(i.push((r+=h).trim()),r="",s--):s>1?(r+=h,s--):r+=h:r+=h}return r.trim().length>0&&i.push(r.trim()),i},t.prototype.getShape=function(e){var i={};return e.startsWith("(((")?i={type:"Path",data:"M 0 0 A 1 1 0 0 0 7 0 A 1 1 0 0 0 0 0 M -1 0 A 1 1 0 0 0 8 0 A 1 1 0 0 0 -1 0"}:e.startsWith("((")?i={shape:"Ellipse",type:"Basic"}:e.startsWith("([")?i={type:"Flow",shape:"Terminator"}:e.startsWith("(")?i={type:"Flow",shape:"Process"}:e.startsWith("[[")?i={type:"Flow",shape:"PreDefinedProcess"}:e.startsWith("[/")?i=e.endsWith("/]")?{type:"Basic",shape:"Parallelogram"}:{type:"Path",data:"M 0 0 L 1 -1 L 5 -1 L 6 0 L 0 0"}:e.startsWith("[(")?i={type:"Path",data:"M 0 1 L 0 6 C 2 7 4 7 6 6 L 6 1 C 5 0 1 0 0 1 C 1 2 5 2 6 1"}:e.startsWith("[\\")?i=e.endsWith("\\]")?{type:"Path",data:"M 0 0 L 12 0 L 14 2 L 2 2 L 0 0"}:{type:"Path",data:"M 0 0 L 5 0 L 4 1 L 1 1 L 0 0"}:e.startsWith("[")?i={type:"Basic",shape:"Rectangle"}:e.startsWith("{{")?i={type:"Path",data:"M 0 0 L 2 -2 L 11 -2 L 13 0 L 11 2 L 2 2 L 0 0"}:e.startsWith("{")?i={type:"Flow",shape:"Decision"}:e.startsWith(">")&&(i={type:"Path",data:"M 0 0 L 8 0 L 8 2 L 0 2 L 2 1 L 0 0"}),i},t.prototype.getDiagramContent=function(e){return this.printandExportModule?this.printandExportModule.getDiagramContent(e):(console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),"")},t.prototype.exportImage=function(e,i){this.printandExportModule?this.printandExportModule.exportImages(e,i):console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.printImage=function(e,i){this.printandExportModule?(i.printOptions=!0,this.printandExportModule.exportImages(e,i)):console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.setStackLimit=function(e){this.undoRedoModule&&e&&(this.historyManager.stackLimit=e,this.undoRedoModule.applyLimit(this.historyManager.currentEntry,e,this,!0))},t.prototype.clearHistory=function(){this.undoRedoModule&&this.undoRedoModule.clearHistory(this)},t.prototype.getDiagramBounds=function(){if(this.printandExportModule){var e=this.printandExportModule.getDiagramBounds("",{});return e.width=e.width>this.scrollSettings.viewPortWidth?e.width+(e.x>0?e.x:0):this.scrollSettings.viewPortWidth,e.height=e.height>this.scrollSettings.viewPortHeight?e.height+(e.y>0?e.y:0):this.scrollSettings.viewPortHeight,e.x=e.x>0?0:e.x,e.y=e.y>0?0:e.y,e}return console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),new Ne},t.prototype.exportDiagram=function(e){return this.printandExportModule?this.printandExportModule.exportDiagram(e):(console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),"")},t.prototype.print=function(e){this.printandExportModule?this.printandExportModule.print(e):console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.addPorts=function(e,i){var s;this.protectPropertyChange(!0),e=this.nameTable[e.id]||e,i.length>1&&this.startGroupAction();for(var o=function(h){if(e.ports.some(function(y){return y.id===i[parseInt(h.toString(),10)].id}))return"continue";if(e instanceof te?(s=new Es(e,"ports",i[parseInt(h.toString(),10)],!0),e.ports.push(s)):e instanceof de&&(s=new Tc(e,"ports",i[parseInt(h.toString(),10)],!0),e.ports.push(s)),e.children)for(var c=e.wrapper,d=0;d1&&this.endGroupAction(),e.wrapper.measure(new me(e.width,e.height)),e.wrapper.arrange(e.wrapper.desiredSize),this.updateDiagramObject(e),this.protectPropertyChange(!1)},t.prototype.addConstraints=function(e,i){return e|i},t.prototype.removeConstraints=function(e,i){return e&~i},t.prototype.addNodeLabels=function(e,i){this.addLabels(e,i)},t.prototype.addConnectorLabels=function(e,i){this.addLabels(e,i)},t.prototype.addLabels=function(e,i){this.protectPropertyChange(!0);var s,r=(e=this.nameTable[e.id]||e).wrapper;i.length>1&&this.startGroupAction();for(var o=0;o1&&this.endGroupAction(),e.wrapper.measure(new me(r.width,r.height)),e.wrapper.arrange(r.desiredSize),this.updateDiagramObject(e),this.protectPropertyChange(!1),this.refreshCanvasLayers()},t.prototype.addChildToUmlNode=function(e,i,r){var s,o,a,l,h="NoWrap";"Class"===e.shape.classifier||"Interface"===e.shape.classifier?"Method"===r?(o=new cm(e,"",i),"Class"===e.shape.classifier?(e.shape.classShape.methods.push(o),s=e.shape.classShape):"Interface"===e.shape.classifier&&(e.shape.interfaceShape.methods.push(o),s=e.shape.interfaceShape),function Xse(n,t,e,i){if(e.methods&&e.methods.length){var r=e.methods,s="",o="",a=void 0,l=1,h=void 0,c=0,d=0,u=n.shape,g="Class"===u.classifier?u.classShape:u.interfaceShape;1===r.length?g.attributes.length>0?(c=g.attributes.filter(function(w){return w.isSeparator}).length,h=(l=2+g.attributes.length+c)+1,nT(n,t,l)):h=l+1:(c=g.attributes.filter(function(w){return w.isSeparator}).length,d=g.methods.filter(function(w){return w.isSeparator}).length,h=(l=2+g.attributes.length+c+g.methods.length+d)+1);for(var v=0;v1&&this.startGroupAction();for(var r=i.length-1;r>=0;r--)if(e.children&&e.children.length>0){var s=e.wrapper.children.filter(function(o){return o.id===e.id+"group_container"});s&&s.length>0&&this.removelabelExtension(e,i,r,s[0])}else this.removelabelExtension(e,i,r,e.wrapper);i.length>1&&this.endGroupAction(),this.refreshCanvasLayers()},t.prototype.removePortsExtenion=function(e,i,r,s){for(var o=0;o1&&this.startGroupAction();for(var r=i.length-1;r>=0;r--)if(e.children&&e.children.length>0)for(var s=0;s1&&this.endGroupAction()},t.prototype.getSizeValue=function(e,i){var r;return r=e.toString().indexOf("px")>0?e.toString():e.toString().indexOf("%")>0?void 0!==i?"100%":e.toString():e.toString()+"px",i&&(Za(this),r="calc("+r+" - "+i+"px)"),r},t.prototype.renderRulers=function(){this.rulerSettings.showRulers?(function Yne(n){var t=Za(n),i=Tt("div",{id:n.element.id+"_overlapRuler",style:"height:"+t.height+"px;width:"+t.width+"px;position:absolute;left:0;top:0",class:"e-ruler-overlap"});n.element.insertBefore(i,n.element.firstChild)}(this),eF(this,!0),eF(this,!1)):Qx(this)},t.prototype.intOffPageBackground=function(){var e=new me;e=Za(this);var i=document.getElementById(this.element.id+"content"),r=this.getSizeValue(this.width,e.width),s=this.getSizeValue(this.height,e.height),o=this.rulerSettings.showRulers?"width:"+r+"; height:"+s+";top:"+e.height+"px;left:"+e.width+"px;overflow: scroll;position:absolute;overflow:auto;":"width:"+r+"; height:"+s+";position:absolute; left:0px; top:0px;overflow: auto;",a={id:this.element.id+"content",tabindex:"0",style:o};i?(this.diagramCanvas=i,Ka(this.diagramCanvas,o)):(this.diagramCanvas=Tt("div",a),this.element.appendChild(this.diagramCanvas)),this.diagramCanvas.style.background=this.backgroundColor},t.prototype.initDiagram=function(){this.intOffPageBackground(),Ho(this.element,{style:"width:"+this.getSizeValue(this.width)+"; height:"+this.getSizeValue(this.height)+";position:relative;overflow:hidden;"})},t.prototype.renderHiddenUserHandleTemplateLayer=function(e){var r=Tt("div",{class:this.element.id+"_hiddenUserHandleTemplate",style:"width:"+e.width+"px; height:"+e.height+"px;visibility:hidden ; overflow: hidden;"});this.element.appendChild(r)},t.prototype.renderBackgroundLayer=function(e,i){var r=this.createSvg(this.element.id+"_backgroundLayer_svg",e.width,e.height);Ka(r,i);var s=Fi("g",{id:this.element.id+"_backgroundImageLayer",class:"e-background-image-layer"});r.appendChild(s);var a=Fi("g",{id:this.element.id+"_backgroundLayer",class:"e-background-layer"});r.appendChild(a),this.diagramCanvas.appendChild(r)},t.prototype.renderGridLayer=function(e,i){var r=this.createSvg(this.element.id+"_gridline_svg",e.width,e.height);r.setAttribute("class","e-grid-layer");var s=Fi("g",{id:this.element.id+"_gridline"}),o=Fi("rect",{id:this.element.id+"_grid_rect",x:"0",y:"0",width:"100%",height:"100%"});if(sm()){var a=new URL(window.location.href);o.setAttribute("fill",""!==a.search?"url(#"+this.element.id+"_pattern)":"url("+location.protocol+"//"+location.host+location.pathname+"#"+this.element.id+"_pattern)")}else o.setAttribute("fill","url(#"+this.element.id+"_pattern)");s.appendChild(o),r.appendChild(s),this.diagramCanvas.appendChild(r),ti(r,{style:i})},t.prototype.renderDiagramLayer=function(e,i){if(this.diagramLayerDiv=Tt("div",{id:this.element.id+"_diagramLayer_div",style:"width:"+e.width+"px; height:"+e.height+"px;"+i}),"SVG"===this.mode){var s=this.createSvg(this.element.id+"_diagramLayer_svg",e.width,e.height);s.style["pointer-events"]="none",s.setAttribute("class","e-diagram-layer");var o=Fi("g",{id:this.element.id+"_diagramLayer"}),a=Fi("g",{});this.diagramLayer=o,s.style["pointer-events"]="all",a.appendChild(o),s.appendChild(a),this.diagramLayerDiv.appendChild(s)}else this.diagramLayer=bo.createCanvas(this.element.id+"_diagram",e.width,e.height),Ka(this.diagramLayer,"position:absolute;left:0px;top:0px;"),this.diagramLayerDiv.appendChild(this.diagramLayer);this.diagramCanvas.appendChild(this.diagramLayerDiv)},t.prototype.initLayers=function(){var e="position:absolute;top:0px;left:0px;overflow:hidden;pointer-events:none;",r=document.getElementById(this.element.id).getBoundingClientRect(),s=function Soe(){var n=Tt("div",{style:"visibility:hidden; width: 100px"});document.body.appendChild(n);var t=n.getBoundingClientRect().width;n.style.overflow="scroll";var e=Tt("div",{style:"width:100%"});n.appendChild(e);var i=e.getBoundingClientRect().width;return n.parentNode.removeChild(n),t-i}();this.scroller.scrollerWidth=s,this.scroller.setViewPortSize(r.width,r.height),this.renderRulers();var o="measureElement";window[""+o]&&(window[""+o]=null,document.getElementById("measureElement").remove()),function BF(){var n="measureElement";if(window[""+n])window[""+n].usageCount+=1;else{var t=Tt("div",{id:"measureElement",style:"visibility:hidden ; height: 0px ; width: 0px; overflow: hidden;"}),e=Tt("span",{style:"display:inline-block ; line-height: normal"});t.appendChild(e);var i=Tt("img",{alt:"measureElementImage",src:"data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7"});t.appendChild(i);var r=document.createElementNS("http://www.w3.org/2000/svg","svg");r.setAttribute("xmlns:xlink","http://www.w3.org/1999/xlink"),t.appendChild(r);var s=document.createElementNS("http://www.w3.org/2000/svg","path");s.setAttribute("d",""),r.appendChild(s),document.createTextNode("");var a=document.createElementNS("http://www.w3.org/2000/svg","text");a.setAttributeNS("http://www.w3.org/XML/1998/namespace","xml:space","preserve"),r.appendChild(a),window[""+n]=t,window[""+n].usageCount=1,document.body.appendChild(t);var l="measureElementCount";window[""+l]?window[""+l]++:window[""+l]=1}}(),this.renderBackgroundLayer(r,e),this.renderGridLayer(r,e),this.renderDiagramLayer(r,e),this.renderHTMLLayer(r,e),this.renderPortsExpandLayer(r,e),this.renderNativeLayer(r,e),this.renderAdornerLayer(r,e),this.renderHiddenUserHandleTemplateLayer(r)},t.prototype.renderAdornerLayer=function(e,i){var r=Tt("div",{id:this.element.id+"_diagramAdornerLayer",style:"width:"+e.width+"px;height:"+e.height+"px;"+i}),s=Tt("div",{id:this.element.id+"_diagramUserHandleLayer",style:"width:"+e.width+"px;height:"+e.height+"px;"+i});s.setAttribute("class","e-userHandle-layer"),r.appendChild(s);var o=this.createSvg(this.element.id+"_diagramAdorner_svg",e.width,e.height);o.setAttribute("class","e-adorner-layer"),o.style["pointer-events"]="none",this.adornerLayer=Fi("g",{id:this.element.id+"_diagramAdorner"}),this.adornerLayer.style[" pointer-events"]="all",o.appendChild(this.adornerLayer),r.appendChild(o),this.diagramCanvas.appendChild(r);var a=Fi("g",{id:this.element.id+"_SelectorElement"});this.adornerLayer.appendChild(a),ti(o,{style:"pointer-events:none;"})},t.prototype.renderPortsExpandLayer=function(e,i){var r=this.createSvg(this.element.id+"_diagramPorts_svg",e.width,e.height);r.setAttribute("class","e-ports-expand-layer");var s=Fi("g",{id:this.element.id+"_diagramPorts",class:"e-ports-layer",style:"pointer-events: all;"});r.appendChild(s);var o=Fi("g",{id:this.element.id+"_diagramExpander",class:"e-expand-layer",style:"pointer-events: all;"});r.appendChild(o),this.diagramCanvas.appendChild(r),ti(r,{style:i})},t.prototype.renderHTMLLayer=function(e,i){this.htmlLayer=Tt("div",{id:this.element.id+"_htmlLayer",style:"width:"+e.width+"px; height:"+e.height+"px;position:absolute;top:0px;left:0px;overflow:hidden;pointer-events:none;",class:"e-html-layer"});var r=Tt("div",{id:this.element.id+"_htmlLayer_div",style:"position:absolute;top:0px;left:0px;pointer-events:all;"});this.htmlLayer.appendChild(r),this.diagramCanvas.appendChild(this.htmlLayer)},t.prototype.renderNativeLayer=function(e,i){var r=this.createSvg(this.element.id+"_nativeLayer_svg",e.width,e.height),s=Fi("g",{id:this.element.id+"_nativeLayer",style:"pointer-events:all;"});r.appendChild(s),this.diagramLayerDiv.appendChild(r),ti(r,{class:"e-native-layer",style:i})},t.prototype.createSvg=function(e,i,r){var s=document.createElementNS("http://www.w3.org/2000/svg","svg");return ti(s,{id:e,width:i,height:r}),s},t.prototype.updateBazorShape=function(){for(var e=0;e1,i=[],r={},s={},o=[],a=0,l=this.nodes;a0||b&&b.children&&b.children.length>0)&&(M=!1),S&&S.wrapper&&b&&b.wrapper&&M?this.initConnectors(r[""+h],p):i.push(r[""+h])}else b=r[y.targetID],(S=r[y.sourceID])&&S.children&&S.children.length>0||b&&b.children&&b.children.length>0?i.push(r[""+h]):this.initConnectors(r[""+h],p);else r[""+h].children?o.push(h):r[""+h].shape instanceof hT&&r[""+h].shape.activity.subProcess.processes&&r[""+h].shape.activity.subProcess.processes.length>0?s[r[""+h].id]=h:this.initNodes(r[""+h],p);if(this.bpmnModule)for(var w=0,C=this.bpmnModule.bpmnTextAnnotationConnector;w-1&&-1===r.indexOf(c)&&-1===s.indexOf(c)&&r.splice(0,0,c);-1===r.indexOf(o)&&s.push(o)}return r.concat(s)},t.prototype.addToLayer=function(e,i){var r;if(i&&(r=this.commandHandler.getObjectLayer(e.id)),(!i||!r)&&-1===this.activeLayer.objects.indexOf(e.id)&&this.activeLayer.objects.push(e.id),(e instanceof te||e instanceof de)&&("SwimLane"!==e.shape.type||e.children&&e.children.length>0)){if(e.parentId){var s=this.swimlaneZIndexTable[e.parentId],o=this.swimlaneChildTable[e.id];(s&&-1!==s||o&&-1!==o)&&(e.zIndex=this.swimlaneChildTable[e.id])}e instanceof de&&e.sourceID&&e.targetID?-1!==this.activeLayer.objects.indexOf(e.sourceID)&&-1!==this.activeLayer.objects.indexOf(e.targetID)&&this.setZIndex(r||this.activeLayer,e):this.setZIndex(r||this.activeLayer,e)}},t.prototype.updateLayer=function(e){for(var i=0,r=Object.keys(e.layers);i0)for(r=0;rs;l--)r.zIndexTable[parseInt(l.toString(),10)]=r.zIndexTable[l-1],this.nameTable[r.zIndexTable[parseInt(l.toString(),10)]]&&(this.nameTable[r.zIndexTable[parseInt(l.toString(),10)]].zIndex=l);r.zIndexTable[parseInt(a.toString(),10)]=i.id}}},t.prototype.initializeDiagramLayers=function(){for(var e=0;ethis.layers[parseInt(a.toString(),10)].zIndex&&(i=this.layers[parseInt(e.toString(),10)],this.layers[parseInt(e.toString(),10)]=this.layers[parseInt(a.toString(),10)],this.layers[parseInt(a.toString(),10)]=i);0===this.layers.length&&this.commandHandler.addLayer({id:"default_layer",visible:!0,lock:!1,objects:[],zIndex:0,objectZIndex:-1,zIndexTable:{}},null,!0),this.setActiveLayer(this.layers[this.layers.length-1].id)},t.prototype.resetTool=function(){this.eventHandler.resetTool()},t.prototype.initObjectExtend=function(e,i,r){if(r){var s=this.commandHandler.checkBoundaryConstraints(void 0,void 0,e.wrapper.bounds,!0);if("SwimLane"===e.shape.type)for(var o=0,a=Object.keys(i.zIndexTable);o0)&&this.setZIndex(i,e)),e instanceof te){if(r){if("helper"!==e.id&&(o=Zi(this.getNodeDefaults))){if((a=o(e,this))&&a.ports)for(var l=0;l0)for(l=0;l0&&!e.container||e.processId){var r=this.nameTable[e.id];if(!(this.realActions&$i.PreventScale||this.realActions&$i.PreventDrag)){if(r.offsetX&&(this.realActions&$i.EnableGroupAction||!(this.diagramActions&ee.UndoRedo||this.diagramActions&ee.ToolAction||this.diagramActions&ee.PublicMethod))){this.realActions|=$i.PreventScale;var s=r.offsetX-e.wrapper.offsetX;r.offsetX=e.wrapper.offsetX;var o=r.offsetY-e.wrapper.offsetY;r.offsetY=e.wrapper.offsetY,s+o!==0&&this.drag(r,s,o),this.realActions&=~$i.PreventScale}else r.offsetX=e.wrapper.offsetX;r.offsetY&&(this.realActions&$i.EnableGroupAction||!(this.diagramActions&ee.UndoRedo||this.diagramActions&ee.ToolAction||this.diagramActions&ee.PublicMethod))?(this.realActions|=$i.PreventScale,o=r.offsetY-e.wrapper.offsetY,r.offsetY=e.wrapper.offsetY,this.drag(r,0,o),this.realActions&=~$i.PreventScale):r.offsetY=e.wrapper.offsetY,this.diagramActions&&(r.width=e.wrapper.actualSize.width,r.height=e.wrapper.actualSize.height)}}i&&e.children&&e.children.length>0&&(void 0!==this.nameTable[e.id].width?this.scaleObject(e,this.nameTable[e.id].width,!0):this.nameTable[e.id].width=e.wrapper.actualSize.width,void 0!==this.nameTable[e.id].height?this.scaleObject(e,this.nameTable[e.id].height,!1):this.nameTable[e.id].height=e.wrapper.actualSize.height)},t.prototype.initNode=function(e,i,r){var a,f,s=e.initContainer(),o=new Mi;if(this.diagramSettings.inversedAlignment||(s.inversedAlignment=!1),s.children||(s.children=[]),e.children){s.measureChildren=!1,o.id=e.id+"group_container",o.style.fill=e.shape&&"SwimLane"===e.shape.type?e.style.fill:"none",o.style.strokeColor="none",o.horizontalAlignment="Stretch",o.verticalAlignment="Stretch",o.pivot=e.pivot,s.style=e.style,s.padding.left=e.padding.left,s.padding.right=e.padding.right,s.padding.top=e.padding.top,s.padding.bottom=e.padding.bottom,o.children=[],o.preventContainer=!0,e.container&&(o.relativeMode="Object");var l=!!(e.ports&&e.ports.length>0);if(m(e.container)&&!l&&s.children.push(o),e.container&&"Grid"===e.container.type)for(var h=0;h0&&e.wrapper.children[0]instanceof Wv){if(this.setZIndex(this.activeLayer,e),this.connectors.length>0)for(h=0;h0?i.phases.length:0,v="Horizontal"===i.orientation,y=v?i.phases.length||1:s.length+1,S=v?(i.header&&i.hasHeader?1:0)+(i.phases.length>0?1:0)+i.lanes.length:(i.header&&i.hasHeader?1:0)+i.phases.length;if(0===h&&!v&&i.lanes.length&&(S+=1),v?(a=(i.header&&i.hasHeader?1:0)+(h>0?1:0),l=0):(a=i.header&&i.hasHeader?1:0,l=h>0?1:0),s.length>0)for(o+=i.header&&i.hasHeader?i.header.height:0,f=0;fl?d.margin.left=d.margin.left-(u.bounds.left-e.bounds.left):u.children[0].children[1].actualSize.width+r>=d.margin.left&&(d.margin.left=u.children[0].children[1].actualSize.width+r),d.margin.lefta?d.margin.top=d.margin.top-(u.bounds.top-o):u.children[0].children[1].actualSize.height+r>=d.margin.top&&(d.margin.top=u.children[0].children[1].actualSize.height+r),d.margin.left0)for(o=0;o0&&this.updateChildPosition(e)},t.prototype.addBpmnAnnotationConnector=function(e,i){if(e.parentObj instanceof t||e.parentObj instanceof Hd){var r=e.shape,o=""!==r.textAnnotation.textAnnotationTarget&&this.nameTable[r.textAnnotation.textAnnotationTarget],a=o?this.nameTable[r.textAnnotation.textAnnotationTarget]:null,l=null!=a?a.wrapper:null,h=e.ports[0],c={x:0,y:0};switch(r.textAnnotation.textAnnotationDirection){case"Left":h.offset={x:0,y:.5},c.x=i.bounds.left-40,c.y=i.bounds.bottom+30;break;case"Right":h.offset={x:1,y:.5},c.x=i.bounds.right+40,c.y=i.bounds.bottom+30;break;case"Top":h.offset={x:.5,y:0},c.x=i.bounds.right+30,c.y=i.bounds.top-40;break;case"Bottom":h.offset={x:.5,y:1},c.x=i.bounds.right+30,c.y=i.bounds.bottom+40;break;default:h.offset={x:0,y:.5},c.x=i.bounds.left-40,c.y=i.bounds.bottom+30,o&&null!=i&&null!=l&&(i.bounds.left>l.bounds.right?h.offset={x:0,y:.5}:i.bounds.rightl.bounds.top?h.offset={x:.5,y:0}:i.bounds.top0&&this.updateChildPosition(r)}},t.prototype.canExecute=function(){return!0},t.prototype.updateStackProperty=function(e,i,r){e.container&&"Stack"===e.container.type&&(i.width||(i.wrapper.horizontalAlignment="Stretch",i.horizontalAlignment="Stretch"),i.height||(i.verticalAlignment="Stretch",i.wrapper.verticalAlignment="Stretch"),r&&"UmlClassifier"===e.shape.type&&(i.umlIndex=r))},t.prototype.initViews=function(){this.isLoading||(this.views.push(this.element.id),this.views[this.element.id]=this)},t.prototype.initCommands=function(){var e=this.commandManager.commands,i={copy:{execute:this.copyCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.C,keyModifiers:ft.Control}},paste:{execute:this.pasteCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.V,keyModifiers:ft.Control}},cut:{execute:this.cutCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.X,keyModifiers:ft.Control}},delete:{execute:this.removeCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Delete}},selectAll:{execute:this.selectAll.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.A,keyModifiers:ft.Control}},undo:{execute:this.undo.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Z,keyModifiers:ft.Control}},redo:{execute:this.redo.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Y,keyModifiers:ft.Control}},nudgeUp:{execute:this.nudgeCommand.bind(this,"Up"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Up},parameter:"up"},nudgeRight:{execute:this.nudgeCommand.bind(this,"Right"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Right},parameter:"right"},nudgeDown:{execute:this.nudgeCommand.bind(this,"Down"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Down},parameter:"down"},nudgeLeft:{execute:this.nudgeCommand.bind(this,"Left"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Left},parameter:"left"},startEdit:{execute:this.startEditCommad.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.F2}},endEdit:{execute:this.endEditCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Escape}},focusToNextItem:{execute:this.navigateItems.bind(this,!0),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Tab}},focusToPreviousItem:{execute:this.navigateItems.bind(this,!1),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Tab,keyModifiers:ft.Shift}},selectFocusedItem:{execute:this.startEditCommad.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Enter}},bold:{execute:this.fontStyleCommand.bind(this,"bold"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.B,keyModifiers:ft.Control}},italic:{execute:this.fontStyleCommand.bind(this,"italic"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.I,keyModifiers:ft.Control}},underline:{execute:this.fontStyleCommand.bind(this,"underline"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.U,keyModifiers:ft.Control}},duplicate:{execute:this.duplicateCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.D,keyModifiers:ft.Control}},group:{execute:this.groupCommand.bind(this,"group"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.G,keyModifiers:ft.Control}},ungroup:{execute:this.groupCommand.bind(this,"ungroup"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.U,keyModifiers:ft.Control|ft.Shift}},rotateClockwise:{execute:this.rotateCommand.bind(this,"clockwise"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.R,keyModifiers:ft.Control}},rotateAntiClockwise:{execute:this.rotateCommand.bind(this,"antiClockwise"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.L,keyModifiers:ft.Control}},flipHorizontal:{execute:this.flipCommand.bind(this,"horizontal"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.H,keyModifiers:ft.Control}},flipVertical:{execute:this.flipCommand.bind(this,"vertical"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.J,keyModifiers:ft.Control}},pointerTool:{execute:this.toolCommand.bind(this,"pointer"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number1,keyModifiers:ft.Control}},textTool:{execute:this.toolCommand.bind(this,"text"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number2,keyModifiers:ft.Control}},connectTool:{execute:this.toolCommand.bind(this,"connect"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number3,keyModifiers:ft.Control}},freeForm:{execute:this.toolCommand.bind(this,"freeForm"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number5,keyModifiers:ft.Control}},lineTool:{execute:this.toolCommand.bind(this,"line"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number6,keyModifiers:ft.Control}},rectangleTool:{execute:this.toolCommand.bind(this,"rectangle"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number8,keyModifiers:ft.Control}},ellipseTool:{execute:this.toolCommand.bind(this,"ellipse"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number9,keyModifiers:ft.Control}},zoomIn:{execute:this.zoomCommand.bind(this,"zoomIn"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Plus,keyModifiers:ft.Control}},zoomOut:{execute:this.zoomCommand.bind(this,"zoomOut"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Minus,keyModifiers:ft.Control}},shiftUp:{execute:this.shiftCommand.bind(this,"Up"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Up,keyModifiers:ft.Shift}},shiftDown:{execute:this.shiftCommand.bind(this,"Down"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Down,keyModifiers:ft.Shift}},shiftLeft:{execute:this.shiftCommand.bind(this,"Left"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Left,keyModifiers:ft.Shift}},shiftRight:{execute:this.shiftCommand.bind(this,"Right"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Right,keyModifiers:ft.Shift}},alignTextCenter:{execute:this.alignCommand.bind(this,"center"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.C,keyModifiers:ft.Control|ft.Shift}},alignTextLeft:{execute:this.alignCommand.bind(this,"right"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.L,keyModifiers:ft.Control|ft.Shift}},alignTextRight:{execute:this.alignCommand.bind(this,"left"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.R,keyModifiers:ft.Control|ft.Shift}},alignTextTop:{execute:this.alignCommand.bind(this,"top"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.E,keyModifiers:ft.Control|ft.Shift}},alignTextCenterVertical:{execute:this.alignCommand.bind(this,"centerVertical"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.M,keyModifiers:ft.Control|ft.Shift}},alignTextBottom:{execute:this.alignCommand.bind(this,"bottom"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.V,keyModifiers:ft.Control|ft.Shift}},alignJustify:{execute:this.alignCommand.bind(this,"justify"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.J,keyModifiers:ft.Control|ft.Shift}},sendToBack:{execute:this.orderCommand.bind(this,"sendToBack"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.B,keyModifiers:ft.Control|ft.Shift}},bringToFront:{execute:this.orderCommand.bind(this,"bringToFront"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.F,keyModifiers:ft.Control|ft.Shift}},sendBackward:{execute:this.orderCommand.bind(this,"sendBackward"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.BracketLeft,keyModifiers:ft.Control}},bringForward:{execute:this.orderCommand.bind(this,"bringForward"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.BracketRight,keyModifiers:ft.Control}}};this.initCommandManager(e,i)},t.prototype.overrideCommands=function(e,i){for(var r,s=0,o=Object.keys(i);se.zIndex){("HTML"===e.shape.type||"Native"===e.shape.type)&&(o="HTML"===e.shape.type?"html":"native"),s=poe(i,r[parseInt(a.toString(),10)].id,o);break}return s},t.prototype.updateDiagramObject=function(e,i,r){for(var s,o="domTable",a=0,l=this.views;a1&&(d=this.commandHandler.getObjectLayer(e.id)),void 0===d||d&&d.visible||r){var u=Io(this.element.id);window[""+o][s.element.id+"_diagramLayer"]||(window[""+o][s.element.id+"_diagramLayer"]=document.getElementById(s.element.id+"_diagramLayer"));var f=window[""+o][s.element.id+"_diagramLayer"];this.diagramActions&ee.Interactions&&this.updateCanupdateStyle(e.wrapper.children,!0);var p=this.getMidPoint(e);this.diagramRenderer.updateNode(e.wrapper,f,u,void 0,i?void 0:this.getZindexPosition(e,s.element.id),p,this.portCenterPoint),this.updateCanupdateStyle(e.wrapper.children,!0)}}},t.prototype.applyMarginBezier=function(e,i){i.cx=i.cx+e.margin.left,i.cx=i.cx-e.margin.right,i.cy=i.cy+e.margin.top,i.cy=i.cy-e.margin.bottom},t.prototype.getMidPoint=function(e){var i;if(e instanceof de&&"Bezier"===e.type){i=[];for(var r=this.getBezierPoints(e),s=R.getLengthFromListOfPoints(r),o=0;o0&&e.updateView(e));var s=Io(e.element.id);this.renderDiagramElements(e.diagramLayer,e.diagramRenderer,s,void 0,void 0,i);for(var o=0;o0&&this.renderBasicElement(e),!this.diagramActions||!(this.diagramActions&ee.Render)||ee.ToolAction&this.diagramActions||Ds(this)||1!==this.scroller.currentZoom?this.refreshElements(e):this.renderTimer||(this.renderTimer=setTimeout(function(){i.refreshElements(e)},40)))},t.prototype.updatePortVisibility=function(e,i,r){var s;if((e instanceof te||e instanceof de)&&(!this.drawingObject||!this.drawingObject.shape)&&ro(e)){for(var a=e.ports,l=!1,h=0;h=0&&this.scroller.removeCollection.splice(l,1);var h=this.nameTable[e[parseInt(a.toString(),10)]];this.updateTextElementValue(h),this.diagramRenderer.renderElement(h.wrapper,s,o,void 0,void 0,void 0,void 0,h.zIndex)}for(var c=0;c0?this.scroller.oldCollectionObjects:void 0,b=Object.keys(S||g.zIndexTable);b.sort(function(N,T){return parseInt(""+N,10)-parseInt(""+T,10)});for(var M=0,w=b;M0?h:0)+"px",y=(this.realActions&$i.vScrollbarMoved?0:-(this.scroller.verticalOffset<0?this.scroller.verticalOffset:0))+"px"):(v="0px",y="0px"),this.realActions&$i.hScrollbarMoved&&(this.realActions=this.realActions&~$i.hScrollbarMoved),this.realActions&$i.vScrollbarMoved&&(this.realActions=this.realActions&~$i.vScrollbarMoved)):(v=(l.x<0?h:-this.scroller.horizontalOffset)+"px",y=(l.y<0?c:-this.scroller.verticalOffset)+"px"),this.diagramLayer.style.left=v,this.diagramLayer.style.top=y,A.tx=-l.x/A.scale,A.ty=-l.y/A.scale);var P=!0;if(o&&(P=!1),this.updateTextElementValue(D),this.refreshing&&D.shape.activity&&D.shape.activity.subProcess&&D.shape.activity.subProcess.processes){for(var L=0;L0){var o=s.children[0],a=o.data;(r.isBezierEditing&&this.selectedItems.connectors[0].id===r.id||"Bezier"!==r.type)&&r.getSegmentElement(r,o,"ComplexHierarchicalTree"===this.layout.type||"HierarchicalTree"===this.layout.type?this.layout.orientation:void 0,void 0,!1),o.data!==a&&(s.measure(new me),s.arrange(s.desiredSize),"SVG"===this.mode&&!e&&this.updateDiagramObject(r))}}else this.constraints&nt.Bridging&&console.warn('[WARNING] :: Module "ConnectorBridging" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.setCursor=function(e){this.diagramRenderer.setCursor(this.diagramCanvas,e)},t.prototype.clearCanvas=function(e){var i=e.contentWidth||e.diagramLayer.width/this.scroller.currentZoom,r=e.contentHeight||e.diagramLayer.height/this.scroller.currentZoom;"SVG"!==e.mode&&bo.getContext(e.diagramLayer).clearRect(0,0,i,r)},t.prototype.updateScrollOffset=function(){this.scroller.setScrollOffset(this.diagramCanvas.scrollLeft,this.diagramCanvas.scrollTop),qI(this),Ds(this)&&this.scroller.virtualizeElements()},t.prototype.setOffset=function(e,i){var r="domTable";window[""+r][this.element.id+"content"]||(window[""+r][this.element.id+"content"]=document.getElementById(this.element.id+"content"));var s=window[""+r][this.element.id+"content"];s&&(s.scrollLeft=e,s.scrollTop=i)},t.prototype.setSize=function(e,i){if(this.diagramLayer&&!this.preventDiagramUpdate){var r=Za(this);e-=r.width,i-=r.height;var s=this.spatialSearch.getPageBounds();s.x*=this.scroller.currentZoom,s.y*=this.scroller.currentZoom,s.width*=this.scroller.currentZoom,s.height*=this.scroller.currentZoom;var o="SVG"===this.mode?1:1.5,a="SVG"===this.mode?pT(this.element.id):this.diagramLayer,h="Canvas"===this.mode&&this.constraints&nt.Virtualization?this.scroller.viewPortHeight:i;a.setAttribute("width",(o*("Canvas"===this.mode&&this.constraints&nt.Virtualization?this.scroller.viewPortWidth:e)).toString()),a.setAttribute("height",(o*h).toString());var c=document.getElementById(this.element.id+"_diagramUserHandleLayer");c&&(c.style.width=e+"px",c.style.height=i+"px");var d={width:e.toString(),height:i.toString()};this.diagramLayerDiv.style.width=e+"px",this.diagramLayerDiv.style.height=i+"px",ti(kF(this.element.id),d),ti(function voe(n){return xt(n).getElementsByClassName("e-ports-expand-layer")[0]}(this.element.id),d);var u=Bl(this.element.id);ti(u,d),u.parentNode.style.width=e+"px",u.parentNode.style.height=i+"px";var f=Fd(this.element.id);ti(f,d),this.diagramRenderer.updateGrid(this.snapSettings,f,this.scroller.transform,this.rulerSettings,this.hRuler,this.vRuler),ti(mT(this.element.id),d),this.htmlLayer.style.width=e+"px",this.htmlLayer.style.height=i+"px","SVG"!==this.mode&&!Ds(this)&&this.refreshDiagramLayer(),"SVG"===this.mode&&Ds(this)&&this.scroller.virtualizeElements()}},t.prototype.transformLayers=function(){var e=this.spatialSearch.getPageBounds();e.x*=this.scroller.currentZoom,e.y*=this.scroller.currentZoom,e.width*=this.scroller.currentZoom,e.height*=this.scroller.currentZoom,this.diagramRenderer.updateGrid(this.snapSettings,Fd(this.element.id),this.scroller.transform,this.rulerSettings,this.hRuler,this.vRuler),this.diagramRenderer.transformLayers(this.scroller.transform,"SVG"===this.mode),this.diagramActions&ee.DragUsingMouse||this.updateSelector(),this.renderPageBreaks(e)},t.prototype.removePageBreaks=function(){if(this.diagramLayer){var e=PF(this.element.id);if(e&&e.childNodes)for(var i=e.childNodes.length,r=0;rthis.pageSettings.height&&(e=this.pageSettings.height,this.pageSettings.height=this.pageSettings.width,this.pageSettings.width=e):this.pageSettings.height>this.pageSettings.width&&(e=this.pageSettings.width,this.pageSettings.width=this.pageSettings.height,this.pageSettings.height=e)},t.prototype.setOverview=function(e,i){if(e)e&&(this.views.push(e.id),this.views[e.id]=e,e.renderDocument(e),e.diagramRenderer.setLayers(),e.updateView(e),this.renderNodes(e));else{for(var r=0;r1&&this.updateSelectionRectangle(),this.isProtectedOnChange=s},t.prototype.updateSelectionRectangle=function(){for(var e=dm(this.element.id),i=!1,r=0;r1&&this.updateSelectionRectangle(),this.enableServerDataBinding(e)},t.prototype.renderSelectorForAnnotation=function(e,i){this.diagramRenderer.renderResizeHandle(e.wrapper.children[0],i,e.thumbsConstraints,this.scroller.currentZoom,e.constraints,this.scroller.transform,void 0,ro(e.annotation),void 0,void 0,e.handleSize)},t.prototype.drawSelectionRectangle=function(e,i,r,s){this.clearSelectorLayer(),this.diagramRenderer.drawSelectionRectangle(e,i,r,s,this.adornerLayer,this.scroller.transform)},t.prototype.renderHighlighter=function(e){var i=Bl(this.element.id);this.diagramRenderer.renderHighlighter(e,i,this.scroller.transform)},t.prototype.clearHighlighter=function(){var e=Bl(this.element.id),i=e.getElementById(e.id+"_highlighter");i&&i.parentNode.removeChild(i)},t.prototype.getNodesConnectors=function(e){for(var i=0;i0;h--)this.eventHandler&&this.eventHandler.touchArgs&&"touchmove"===this.eventHandler.touchArgs.type?(this.diagramRenderer.touchMove=!0,l&&l===o[h-1].id||(a=o[h-1]).parentNode.removeChild(a)):(a=o[h-1]).parentNode.removeChild(a);if(!ce()){var c=vT(this.element.id).childNodes;for(r=c.length;r>0;r--)c[r-1].parentNode.removeChild(c[r-1])}}},t.prototype.getWrapper=function(e,i){var r;i=e.id+"_"+i;for(var s=e instanceof Mi?e:this.getPortContainer(this.nameTable[e.id]),o=0;o0&&this.applyStyle(e,a=r.annotations)}for(i=0;i0){var a=this.selectedItems.connectors[parseInt(i.toString(),10)].annotations;this.applyStyle(e,a)}},t.prototype.applyStyle=function(e,i){for(var r=0;r0)for(var i=0;i0?r[0].zIndex+(e?1:-1):e?0:this.nodes.length+this.connectors.length-1)<0?i=this.nodes.length+this.connectors.length-1:i===this.nodes.length+this.connectors.length&&(i=0);for(var s=0;s0)for(var s=void 0,o=r.children.length-1;o>=0;o--){var a=r.children[parseInt(o.toString(),10)];i.length>0&&-1!==i.indexOf(a.id.split("_groupElement")[0])&&(r.parentNode.insertBefore(a,s||r),s=a)}r&&r.parentNode.removeChild(r)},t.prototype.deleteGroup=function(e){var r=[];e.children&&(r=this.commandHandler.getChildren(e,[])),this.UpdateBlazorDiagramModelCollection(e);for(var s=0,o=r;s0)for(var xe=0;xe0)if("Path"===t.shape.type&&void 0!==n.shape.data)t.wrapper.children[0].data=n.shape.data;else if("Text"===t.shape.type&&void 0!==n.shape.content)t.wrapper.children[0].content=n.shape.content;else if("Image"===t.shape.type&&void 0!==n.shape.source)t.wrapper.children[0].source=n.shape.source;else if("Native"===t.shape.type){for(var r=void 0,s=0;s-1)&&(this.diagramActions&ee.PreventZIndexOnDragging?this.updateDiagramObject(e,!0):this.updateDiagramObject(e)),!s&&d&&(this.lineRoutingModule&&this.diagramActions&&this.constraints&nt.LineRouting&&"helper"!==e.id?this.diagramActions&ee.ToolAction||this.lineRoutingModule.renderVirtualRegion(this,!0):this.diagramActions&&this.constraints&nt.LineRouting&&"helper"!==e.id&&console.warn('[WARNING] :: Module "LineRouting" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),this.updateConnectorEdges(e),"helper"!==e.id&&!(this.diagramActions&ee.ToolAction))))for(var Sa=this.spatialSearch.findObjects(e.wrapper.outerBounds),Mo=0;Moe?Math.abs(r-e):Math.abs(e-r),d=s>i?Math.abs(s-i):Math.abs(i-s);(0===c&&0===d||Number.isNaN(c)&&Number.isNaN(d))&&o.laneMargin&&(u=o.margin.left-o.laneMargin.left,f=o.margin.top-o.laneMargin.top);var p=o.width,g=o.height,v=new Ne(0,0,0,0);if(0!==p&&0!==g&&(v=new Ne((0!==r?r:o.offsetX)-p/2,(0!==s?s:o.offsetY)-g/2,p,g)),h){var y=l,b=this.selectedItems.nodes?this.selectedItems.nodes[0]:void 0;if(""!==y.textAnnotation.textAnnotationTarget&&this.nameTable[y.textAnnotation.textAnnotationTarget])if(""===o.parentId||b&&b.shape&&"TextAnnotation"===b.shape.shape){if("Auto"===y.textAnnotation.textAnnotationDirection&&a.children[0]instanceof Mi&&a.children[0].children[0]instanceof Ze){var w=a.children[0],C=document.getElementById(w.id+"_groupElement"),D=document.getElementById(w.children[0].id+"_groupElement");C.removeChild(D),w.children.splice(0,1),this.isProtectedOnChange=!0,this.bpmnModule.setAnnotationPath(v,w,o,y,y.textAnnotation.textAnnotationDirection,this),this.isProtectedOnChange=!1}}else this.isPositionUndo=!0,this.updateTextAnnotationInSwimlane(o,o),this.isPositionUndo=!1;else o.inEdges.length>0&&(x=this.nameTable[""+o.inEdges[0]])&&x.isBpmnAnnotationConnector&&(x.sourcePoint={x:r>e?x.sourcePoint.x+c:x.sourcePoint.x-c,y:s>i?x.sourcePoint.y+d:x.sourcePoint.y-d});this.nodePropertyChange(o,{},P={ports:[{offset:o.ports[0].offset}]})}else for(var L=0,O=o.outEdges;Le?T.offsetX+c:T.offsetX-c,T.offsetY=s>i?T.offsetY+d:T.offsetY-d,P={offsetX:T.offsetX,offsetY:T.offsetY}),this.nodePropertyChange(T,z,P)}}}},t.prototype.updatePorts=function(e,i){if(e&&e.ports.length>0)for(var r=0,s=Object.keys(e.ports);r0)for(var i=0;i0)for(var r=0;r0&&void 0===r.segments&&(e.segments=[]),void 0!==r.shape&&void 0!==e.shape&&e.shape&&"Bpmn"===e.shape.type&&this.bpmnModule&&this.bpmnModule.updateBPMNConnector(e,i,r,this),void 0!==e.constraints?(this.updateThumbConstraints(this.selectedItems.connectors,this.selectedItems),s=!0):s},t.prototype.connectorPropertyChange=function(e,i,r,s,o){if(this.canEnableBlazorObject){var a=$(e);this.insertValue(a,!1)}var d,u,f,p,l=e.wrapper.bounds,h=!1,c=[];if(h=this.connectorProprtyChangeExtend(e,i,r,h),void 0!==r.visible&&this.updateElementVisibility(e.wrapper,e,e.visible),void 0!==r.sourcePoint||void 0!==r.targetPoint||void 0!==r.sourceID||void 0!==r.targetID||void 0!==r.targetPadding||void 0!==r.sourcePortID||void 0!==r.targetPortID||void 0!==r.sourcePadding||void 0!==r.type||void 0!==r.segments||void 0!==r.flip){if(void 0!==r.sourceID&&r.sourceID!==i.sourceID||r.sourcePortID){if(u=this.findInOutConnectPorts(g=this.nameTable[e.sourceID],!1),(!g||Ph(g)||""!==e.sourcePortID&&Td(u))&&(e.sourceWrapper=g?this.getEndNodeWrapper(g,e,!0):void 0,e.sourcePortID&&void 0===r.sourcePortID&&(e.sourcePortWrapper=g?this.getWrapper(g.wrapper,e.sourcePortID):void 0),this.removePortEdges(this.nameTable[i.sourceID]||g,i.sourcePortID||e.sourcePortID,e.id,!1)),void 0!==r.sourceID&&void 0!==i.sourceID&&""!==i.sourceID){var v=this.nameTable[i.sourceID];void 0!==v&&v.outEdges&&-1!==v.outEdges.indexOf(e.id)&&im(v.outEdges,e.id)}this.updateEdges(e)}if(void 0!==r.targetID&&r.targetID!==i.targetID){if(d=this.findInOutConnectPorts(y=this.nameTable[r.targetID],!0),(!y||ua(y)||""!==e.targetPortID&&kh(d))&&(e.targetWrapper=y?this.getEndNodeWrapper(y,e,!1):void 0,e.targetPortID&&void 0===r.targetPortID&&(e.targetPortWrapper=y?this.getWrapper(y.wrapper,e.targetPortID):void 0),this.removePortEdges(this.nameTable[i.targetID]||y,i.targetPortID||e.targetPortID,e.id,!0)),void 0!==i&&void 0!==i.targetID&&""!==i.targetID){var S=this.nameTable[i.targetID];void 0!==S&&S.inEdges&&-1!==S.inEdges.indexOf(e.id)&&im(S.inEdges,e.id)}this.updateEdges(e)}var g,y;void 0!==r.sourcePortID&&r.sourcePortID!==i.sourcePortID&&(e.sourceID&&this.nameTable[e.sourceID]&&(f=this.nameTable[e.sourceID].wrapper),!(g=this.nameTable[e.sourceID])||Ph(g)||""!==e.sourcePortID&&Td(u)?e.sourcePortWrapper=f?this.getWrapper(f,r.sourcePortID):void 0:""===e.sourcePortID&&!Ph(g)&&(e.sourcePortWrapper=void 0)),void 0!==r.targetPortID&&r.targetPortID!==i.targetPortID&&(e.targetID&&this.nameTable[e.targetID]&&(p=this.nameTable[e.targetID].wrapper),!(y=this.nameTable[e.targetID])||ua(y)||""!==e.targetPortID&&kh(d)?e.targetPortWrapper=p?this.getWrapper(p,r.targetPortID):void 0:""===e.targetPortID&&!ua(y)&&(e.targetPortWrapper=void 0)),void 0!==r.flip&&(e.flip=r.flip,SF(e)),"Orthogonal"===e.type&&this.lineRoutingModule&&this.diagramActions&&this.constraints&nt.LineRouting&&!(this.diagramActions&ee.ToolAction)&&"ComplexHierarchicalTree"!==this.layout.type&&(this.lineRoutingModule.renderVirtualRegion(this,!0),e.sourceID!==e.targetID&&e.segments.length>1&&this.lineRoutingModule.refreshConnectorSegments(this,e,!1)),c=this.getPoints(e)}void 0!==r.style&&zh(r.style,e.wrapper.children[0]),(c.length>0||void 0!==r.sourceDecorator||void 0!==r.targetDecorator&&function Bse(n){return-1!==n.indexOf("shape")||-1!==n.indexOf("pathData")||-1!==n.indexOf("width")||-1!==n.indexOf("height")}(Object.keys(r.targetDecorator))||void 0!==r.cornerRadius)&&(Jf(e,c.length>0?c:e.intermediatePoints,this.diagramActions),void 0!==r.type&&(h=!0),c.length>0&&(e.wrapper.measure(new me(e.wrapper.width,e.wrapper.height)),e.wrapper.arrange(e.wrapper.desiredSize),this.updateConnectorAnnotation(e),this.updateConnectorPort(e),this.updateConnectorfixedUserHandles(e),this.updateObject(e,i,r))),(r.sourcePoint||r.targetPoint||r.segments)&&this.diagramActions===ee.Render&&(h=!0),"Bpmn"===e.shape.type&&"Default"===e.shape.sequence&&"Sequence"===e.shape.flow&&this.commandHandler.updatePathElementOffset(e),s||this.updateBridging(),this.updateAnnotations(r,e),this.updateConnectorPorts(r,e),this.updatefixedUserHandle(r,e),e.wrapper.measure(new me(e.wrapper.width,e.wrapper.height)),e.wrapper.arrange(e.wrapper.desiredSize),!1===l.equals(l,e.wrapper.bounds)&&(this.updateQuad(e),"Drag"!==this.eventHandler.currentAction&&this.updateGroupSize(e)),!0===h&&this.checkSelectedItem(e)&&(!(this.diagramActions&ee.ToolAction)||this.diagramActions&ee.UndoRedo)&&this.updateSelector(),this.preventConnectorsUpdate||(!Ds(this)||Ds(this)&&this.scroller.oldCollectionObjects.indexOf(e.id)>-1)&&(this.diagramActions&ee.PreventZIndexOnDragging?this.updateDiagramObject(e,!0):this.updateDiagramObject(e)),this.updateConnectorEdges(e),this.diagramActions&&"New"!==e.status&&(e.status="Update"),this.triggerPropertyChange(o,e,i,r)},t.prototype.removePortEdges=function(e,i,r,s){if(e)for(var o=0;o0&&e.id===s[s.length-1].id&&(r=!0),r},t.prototype.updateDiagramContainerVisibility=function(e,i){if(e instanceof Cs)for(var r=0;r>"),r instanceof es&&this.updateAnnotationWrapper(r,s,o,a)),void 0!==e.template&&(r.content=e.template,this.updateAnnotationWrapper(r,s,o,a))},t.prototype.updateAnnotationWrapper=function(e,i,r,s){for(var o=0,a=this.views;o=0&&this.nodes.splice(s,1),delete this.nameTable[""+r]}var o=this.nodes.indexOf(this.nameTable[this.currentSymbol.id]);o>=0&&this.nodes.splice(o,1)}},t.prototype.selectDragedNode=function(e,i,r){this.currentSymbol=e,"SVG"!==this.mode&&this.refreshDiagramLayer(),this.commandHandler.oldSelectedObjects=nm(this),this.commandHandler.select(e),this.eventHandler.mouseDown(i.event),this.eventHandler.mouseMove(i.event,i),this.preventDiagramUpdate=!1,this.updatePage(),r.style.opacity="0"},t.prototype.initDroppables=function(){var s,o,e=this,i={},r={},a="selectedSymbols";this.droppable=new lR(this.element);var l=5;this.droppable.over=function(h){if(e.rulerSettings.showRulers){var c=document.getElementById(e.element.id+"_vRuler"),d=parseFloat(c.style.width);l=d+1}if(0===e.previousSelectedObjects.length&&!e.currentSymbol&&(e.previousSelectedObjects=e.commandHandler.getSelectedObject()),e.commandHandler.PreventConnectorSplit=!0,e.currentSymbol)h.event.touches&&h.event.touches.length&&e.eventHandler.mouseMove(h.event,h.event.touches);else{var u=null;if(!h.dragData&&"drag"===h.name){var f=document.getElementsByClassName("e-dragclone")[0];f&&(u=f)}if(h.dragData||u){var p=void 0,g=void 0;document.getElementById(e.element.id+"content").focus();var v=e.eventHandler.getMousePosition(h.event),y=void 0,S=u||h.dragData.helper,b=S.getAttribute("paletteId"),M=void 0,w=void 0,C=void 0,D=void 0;if(!b&&h.dragData){e.triggerEvent(Ce.dragEnter,A={source:null,element:p,cancel:!1,diagram:e,dragData:h.dragData.draggedElement.ej2_instances[0].dragData,dragItem:p});var x=void 0,P=void 0;if(A.dragItem){if(A.dragItem.sourcePoint&&A.dragItem.targetPoint?P=new de(e,"connectors",A.dragItem,!0):x=new te(e,"nodes",A.dragItem,!0),e.initObject(p=x||P,void 0,void 0,!0),e.enterObject=p,e.enterTable=r,p instanceof te)x.offsetX=v.x+5+x.width*x.pivot.x,x.offsetY=v.y+x.height*x.pivot.y;else if(p instanceof de){var L=Ne.toBounds([p.sourcePoint,p.targetPoint]),O=v.x-L.left,N=v.y-L.top;p.sourcePoint.x+=O,p.sourcePoint.y+=N,p.targetPoint.x+=O,p.targetPoint.y+=N}e.preventDiagramUpdate=!0,e.currentSymbol=p,"SVG"!==e.mode&&e.refreshDiagramLayer(),e.selectDragedNode(p,h,S),delete e.enterObject,delete e.enterTable,e.droppable[""+a]=S,e.allowServerDataBinding=!0}}if(b){var T=document.getElementById(b).ej2_instances[0];if(e.droppable.sourceElement=T,T){var B=T[""+a];e.allowServerDataBinding=!1,y=$(T[""+a]),i=T.childTable;var j=B.wrapper.children[0].children[0];if(D=function Fse(n,t,e){var i=wF(n,t,e,"width"),r=wF(n,t,e,"height");return new me(i,r)}(T,y,j),T[""+a]instanceof te){"TextAnnotation"===B.shape.shape?(y.offsetX=v.x+11+D.width*y.pivot.x,y.offsetY=v.y+11+D.height*y.pivot.y):(y.offsetX=v.x+5+D.width*y.pivot.x,y.offsetY=v.y+D.height*y.pivot.y),"Bpmn"===(x=new te(e,"nodes",y,!0)).shape.type&&x.shape.activity.subProcess.processes&&x.shape.activity.subProcess.processes.length&&(x.shape.activity.subProcess.processes=[]),w=x.previewSize,C=T.symbolDragSize;var Q=T.symbolPreview;if(x.width=(M=x.dragSize).width||C.width||w.width||Q.width||x.width,x.height=M.height||C.height||w.height||Q.height||x.height,"SwimLane"===x.shape.type){if(e.diagramActions|=ee.PreventHistory,x.shape.isLane){x.children=[],s={id:"header"+Qe()},"Horizontal"===x.shape.orientation?(s.width=x.shape.lanes[0].header.width,s.height=x.shape.lanes[0].height):(s.width=x.shape.lanes[0].width,s.height=x.shape.lanes[0].header.height),s.style=x.shape.lanes[0].header.style,s.offsetX=v.x+l+s.width/2,s.offsetY=v.y+s.height/2,e.diagramActions|=ee.PreventCollectionChangeOnDragOver,s=e.add(s),o={id:"body"+Qe()},"Horizontal"===x.shape.orientation?(o.width=x.shape.lanes[0].width-s.width,o.height=x.shape.lanes[0].height,o.offsetX=v.x+l+(x.shape.lanes[0].header.width+o.width/2),o.offsetY=v.y+o.height/2):(o.width=x.shape.lanes[0].width,o.height=x.shape.lanes[0].height-s.height,o.offsetX=v.x+l+o.width/2,o.offsetY=v.y+(x.shape.lanes[0].header.height+o.height/2)),o.style=x.shape.lanes[0].style,o=e.add(o);var oe={id:"group"+Qe(),children:[s.id,o.id]};oe.shape=x.shape,oe.width=x.shape.lanes[0].width,oe.height=x.shape.lanes[0].height,oe.previewSize=x.previewSize,oe.dragSize=x.dragSize,oe.addInfo=x.addInfo,x=e.add(oe),e.diagramActions&=~ee.PreventCollectionChangeOnDragOver}e.diagramActions&=~ee.PreventHistory}if(x.shape.isPhase&&((g="Horizontal"===x.shape.orientation)?(x.offsetX=v.x+l+(x.width||j.actualSize.width)/2,x.offsetY=v.y,x.shape.data="M20,"+x.height/2+" L"+(x.width-20)+","+x.height/2+"z",x.height=1):(x.offsetX=v.x+5,x.offsetY=v.y+(x.height||j.actualSize.height)/2,x.shape.data="M"+x.width/2+",20 L"+x.width/2+","+(x.height-20)+"z",x.width=1)),"UmlClassifier"===x.shape.type&&(x.children=x.width=x.height=void 0,y.children=void 0,"Class"===x.shape.classifier&&x.shape.classShape.methods.length<=0&&x.shape.classShape.attributes.length<=0&&(x.shape.classShape.attributes=[{name:"Name",type:"Type",style:{}}]),"Enumeration"===x.shape.classifier&&x.shape.enumerationShape.members.length<=0&&(x.shape.enumerationShape.members=[{name:"Name"}]),"Interface"===x.shape.classifier&&x.shape.interfaceShape.methods.length<=0&&x.shape.interfaceShape.attributes.length<=0&&(x.shape.interfaceShape.attributes=[{name:"Name",type:"Type",style:{}}])),p=x,y.children){var ue=y;r=e.getChildren(ue,{},i),eT(ue,-ue.offsetX,-ue.offsetY,r,!0,e)}}else if(T[""+a]instanceof de){p=new de(e,"connectors",y,!0);var Me=Ne.toBounds([p.sourcePoint,p.targetPoint]),De=v.x-Me.left,xe=v.y-Me.top;p.sourcePoint.x+=De,p.sourcePoint.y+=xe,p.targetPoint.x+=De,p.targetPoint.y+=xe}p.shape.isLane||(p.id+=Qe());var A={source:T,element:p,cancel:!1,diagram:e,dragData:null,dragItem:p};if(e.enterObject=p,e.enterTable=r,e.triggerEvent(Ce.dragEnter,A),p instanceof te&&"SwimLane"===p.shape.type&&p.shape.isLane){var Ie=A.element,Ve=Ie.shape.lanes[0];g="Horizontal"===Ie.shape.orientation;var ot=e.nameTable[p.children[0]],$e=e.nameTable[p.children[1]];w=p.previewSize,C=T.symbolDragSize,Ve.width=(M=p.dragSize).width||C.width||w.width||Ve.width,Ve.height=M.height||C.height||w.height||Ve.height,g?(s.width=Ve.header.width,s.height=Ve.height,o.width=Ve.width-s.width,o.height=Ve.height,o.offsetX=v.x+l+(Ve.header.width+$e.width/2),o.offsetY=v.y+$e.height/2):(s.width=Ve.width,s.height=Ve.header.height,o.width=Ve.width,o.height=Ve.height-s.height,o.offsetX=v.x+l+$e.width/2,o.offsetY=v.y+(Ve.header.height+$e.height/2)),s.offsetX=v.x+l+ot.width/2,s.offsetY=v.y+ot.height/2,p.width=Ve.width,p.height=Ve.height}if(p instanceof te&&p.shape.isPhase&&(g?p.height=1:p.width=1),!e.activeLayer.lock&&!A.cancel){if(e.preventDiagramUpdate=!0,p.children&&e.findChild(p,r),e.preventDiagramUpdate=!0,p.zIndex!==Number.MIN_VALUE&&(p.zIndex=Number.MIN_VALUE),e.initObject(p,void 0,void 0,!0),e.bpmnModule)for(var Ci=0;Ci0&&(S.segments=[]),d=this.add(S,!0)),(S||d)&&(_v(this)||Uv(this))&&this.select([this.nameTable[S[""+b]]],!1,this.previousSelectedObjects),y.target&&y.target instanceof de&&!0===this.enableConnectorSplit&&this.nameTable[S[""+b]]instanceof te&&(this.commandHandler.connectorSplit(this.nameTable[S[""+b]],y.target),this.commandHandler.PreventConnectorSplit=!1))),this.protectPropertyChange(!1),v=this.nameTable[S[""+b]],S.hasTarget&&(S.nodeId=S.hasTarget,this.remove(S)),this.bpmnModule&&v instanceof te&&S.processId&&(v.processId=S.processId,this.bpmnModule.dropBPMNchild(this.nameTable[v.processId],v,this)),y.cancel||this.endGroupAction(),"SVG"!==this.mode&&this.refreshDiagramLayer(),delete this.droppable[""+c]):(this.triggerEvent(Ce.drop,y={source:h.droppedElement,element:void 0,target:this.eventHandler.hoverNode||this.eventHandler.lastObjectUnderMouse||this,cancel:!1,position:void 0}),S=void 0,b="id"),this.droppable[M="selectedSymbols"]&&this.droppable[""+M].parentNode)gt(this.droppable[""+M]);else for(w=document.getElementsByClassName("e-dragclone"),C=0;C0)for(var f=0;f1),e.previousSelectedObject=null}}},t.prototype.getDropEventArgs=function(e){if(this.eventHandler.lastObjectUnderMouse||this.eventHandler.hoverNode){var i=this.eventHandler.lastObjectUnderMouse||this.eventHandler.hoverNode;e.target=ps(i)===de?{connector:i}:{node:i}}else e.target.diagramId=this.element.id},t.prototype.removeChildInNodes=function(e){if(e){if(e.children)for(var i=0;i1){var l=2;if(e.children&&e.children.length>0)for(;e.children.indexOf(i.objects[s-l])>-1;)l++;this.commandHandler.moveSvgNode(e.id,i.objects[s-l]),this.commandHandler.moveSvgNode(i.objects[s-l],e.id)}else if(o){var h=this.commandHandler.getLayer(this.layerZIndexTable[o.zIndex]).objects[0];h?(this.commandHandler.moveSvgNode(e.id,h),this.commandHandler.updateNativeNodeIndex(e.id,h)):this.moveObjectsUp(e,i)}else this.moveObjectsUp(e,i)},t.prototype.moveObjectsUp=function(e,i){for(var r,s=this.layers.length-1;s>=0;s--)if(r=this.layers[parseInt(s.toString(),10)],i.id!==r.id){var o=this.commandHandler.getLayer(this.layerZIndexTable[r.zIndex]).objects[r.objects.length-1];if(o){this.commandHandler.moveSvgNode(e.id,o),this.commandHandler.moveSvgNode(o,e.id);break}}},t.prototype.insertData=function(e){return this.crudOperation(e,"create",this.getNewUpdateNodes("New"))},t.prototype.updateData=function(e){return this.crudOperation(e,"update",this.getNewUpdateNodes("Update"))},t.prototype.removeData=function(e){return this.crudOperation(e,"destroy",this.getDeletedNodes())},t.prototype.crudOperation=function(e,i,r){if(e){var s=this.parameterMap(e,!(e instanceof de));if(s){var o=e instanceof de?this.dataSourceSettings.connectionDataSource.crudAction[""+i]:this.dataSourceSettings.crudAction[""+i];this.raiseAjaxPost(JSON.stringify(s),o)}return s}var a=r;return this.processCrudCollection(a,this.dataSourceSettings.crudAction[""+i],this.dataSourceSettings.connectionDataSource.crudAction[""+i]),a},t.prototype.processCrudCollection=function(e,i,r){if(e.nodes){var s=[],o=void 0;for(o=0;o0&&this.raiseAjaxPost(JSON.stringify(s),i)}if(e.connectors){for(s=[],o=void 0,o=0;o0&&this.raiseAjaxPost(JSON.stringify(s),r)}},t.prototype.parameterMap=function(e,i){var s,r={},o=i?this.dataSourceSettings:this.dataSourceSettings.connectionDataSource;if(o.id&&(r[o.id]=e.id),o.sourcePointX&&o.sourcePointY&&(r[o.sourcePointX]=e.sourcePoint.x,r[o.sourcePointY]=e.sourcePoint.y),o.targetPointX&&o.targetPointY&&(r[o.targetPointX]=e.targetPoint.x,r[o.targetPointY]=e.targetPoint.y),o.sourceID&&(r[o.sourceID]=e.sourceID),o.targetID&&(r[o.targetID]=e.targetID),o.crudAction&&o.crudAction.customFields&&o.crudAction.customFields.length>0)for(s=0;s"u"||(y.innerHTML=v.innerHTML?v.innerHTML:"",void 0!==v.className&&(y.className=v.className),void 0!==v.id&&(y.id=v.id),void 0!==v.styles&&y.setAttribute("style",v.styles),void 0!==e.ngAttr&&y.setAttribute(e.ngAttr,""),void 0!==v.attrs&&Fe(y,v.attrs)),y};for(var i=0,r=e.tags;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s}!function DZ(n){EC.compile=n.compile}({compile:function Fae(n,t){if("string"==typeof n||"function"==typeof n&&n.prototype&&n.prototype.CSPTemplate)return Bae(n,t);var e=n.elementRef.nativeElement._viewContainerRef,i=n.elementRef.nativeElement.propName;return function(r,s,o){var l=e||s.viewContainerRef,h=l.createEmbeddedView(n,{$implicit:r});/EJS-MENTION|EJS-DROPDOWNLIST/.test(Y("currentInstance.element.nodeName",l))||/E-TABITEM/.test(Y("element.nativeElement.nodeName",l))?h.detectChanges():h.markForCheck();var c=s&&s.registeredTemplate?s.registeredTemplate:Y("currentInstance.registeredTemplate",l);return typeof c["".concat(o=o&&s.registeredTemplate?o:i)]>"u"&&(c["".concat(o)]=[]),c["".concat(o)].push(h),h.rootNodes}}});const Wae=["annotationTemplate"],Yae=["nodeTemplate"],Qae=["userHandleTemplate"];let Gae=["addInfo","id","lock","objects","visible","zIndex"],Xae=[],qae=(()=>{class n extends Bh{constructor(e){super(),this.viewContainerRef=e,_l("currentInstance",this,this.viewContainerRef),this.registerEvents(Xae),this.directivePropList=Gae}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-layer"]],inputs:{addInfo:"addInfo",id:"id",lock:"lock",objects:"objects",visible:"visible",zIndex:"zIndex"},features:[yn]}),n})(),$ae=(()=>{class n extends Fh{constructor(){super("layers")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-layers"]],contentQueries:function(e,i,r){if(1&e&&dn(r,qae,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),Zae=["action","cursor"],Jae=[],Kae=(()=>{class n extends Bh{constructor(e){super(),this.viewContainerRef=e,_l("currentInstance",this,this.viewContainerRef),this.registerEvents(Jae),this.directivePropList=Zae}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-cursormap"]],inputs:{action:"action",cursor:"cursor"},features:[yn]}),n})(),ele=(()=>{class n extends Fh{constructor(){super("customcursor")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-cursormaps"]],contentQueries:function(e,i,r){if(1&e&&dn(r,Kae,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),tle=["alignment","cornerRadius","displacement","fill","handleStrokeColor","handleStrokeWidth","height","iconStrokeColor","iconStrokeWidth","id","offset","padding","pathData","tooltip","visibility","width"],ile=[],rle=(()=>{class n extends Bh{constructor(e){super(),this.viewContainerRef=e,_l("currentInstance",this,this.viewContainerRef),this.registerEvents(ile),this.directivePropList=tle}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-connector-fixeduserhandle"]],inputs:{alignment:"alignment",cornerRadius:"cornerRadius",displacement:"displacement",fill:"fill",handleStrokeColor:"handleStrokeColor",handleStrokeWidth:"handleStrokeWidth",height:"height",iconStrokeColor:"iconStrokeColor",iconStrokeWidth:"iconStrokeWidth",id:"id",offset:"offset",padding:"padding",pathData:"pathData",tooltip:"tooltip",visibility:"visibility",width:"width"},features:[yn]}),n})(),nle=(()=>{class n extends Fh{constructor(){super("fixeduserhandles")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-connector-fixeduserhandles"]],contentQueries:function(e,i,r){if(1&e&&dn(r,rle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),sle=["addInfo","alignment","annotationType","constraints","content","displacement","dragLimit","height","horizontalAlignment","hyperlink","id","margin","offset","rotateAngle","rotationReference","segmentAngle","style","template","tooltip","type","verticalAlignment","visibility","width"],ole=[],ale=(()=>{class n extends Bh{constructor(e){super(),this.viewContainerRef=e,_l("currentInstance",this,this.viewContainerRef),this.registerEvents(ole),this.directivePropList=sle}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-connector-annotation"]],inputs:{addInfo:"addInfo",alignment:"alignment",annotationType:"annotationType",constraints:"constraints",content:"content",displacement:"displacement",dragLimit:"dragLimit",height:"height",horizontalAlignment:"horizontalAlignment",hyperlink:"hyperlink",id:"id",margin:"margin",offset:"offset",rotateAngle:"rotateAngle",rotationReference:"rotationReference",segmentAngle:"segmentAngle",style:"style",template:"template",tooltip:"tooltip",type:"type",verticalAlignment:"verticalAlignment",visibility:"visibility",width:"width"},features:[yn]}),n})(),lle=(()=>{class n extends Fh{constructor(){super("annotations")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-connector-annotations"]],contentQueries:function(e,i,r){if(1&e&&dn(r,ale,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),hle=["addInfo","allowNodeOverlap","annotations","bezierSettings","bridgeSpace","connectionPadding","connectorSpacing","constraints","cornerRadius","dragSize","excludeFromLayout","fixedUserHandles","flip","flipMode","hitPadding","id","margin","maxSegmentThumb","ports","previewSize","segmentThumbShape","segmentThumbSize","segments","shape","sourceDecorator","sourceID","sourcePadding","sourcePoint","sourcePortID","style","symbolInfo","targetDecorator","targetID","targetPadding","targetPoint","targetPortID","tooltip","type","visible","wrapper","zIndex"],cle=[],dle=(()=>{class n extends Bh{constructor(e){super(),this.viewContainerRef=e,this.tags=["fixedUserHandles","annotations"],_l("currentInstance",this,this.viewContainerRef),this.registerEvents(cle),this.directivePropList=hle}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-connector"]],contentQueries:function(e,i,r){if(1&e&&(dn(r,nle,5),dn(r,lle,5)),2&e){let s;Kr(s=en())&&(i.childFixedUserHandles=s.first),Kr(s=en())&&(i.childAnnotations=s.first)}},inputs:{addInfo:"addInfo",allowNodeOverlap:"allowNodeOverlap",annotations:"annotations",bezierSettings:"bezierSettings",bridgeSpace:"bridgeSpace",connectionPadding:"connectionPadding",connectorSpacing:"connectorSpacing",constraints:"constraints",cornerRadius:"cornerRadius",dragSize:"dragSize",excludeFromLayout:"excludeFromLayout",fixedUserHandles:"fixedUserHandles",flip:"flip",flipMode:"flipMode",hitPadding:"hitPadding",id:"id",margin:"margin",maxSegmentThumb:"maxSegmentThumb",ports:"ports",previewSize:"previewSize",segmentThumbShape:"segmentThumbShape",segmentThumbSize:"segmentThumbSize",segments:"segments",shape:"shape",sourceDecorator:"sourceDecorator",sourceID:"sourceID",sourcePadding:"sourcePadding",sourcePoint:"sourcePoint",sourcePortID:"sourcePortID",style:"style",symbolInfo:"symbolInfo",targetDecorator:"targetDecorator",targetID:"targetID",targetPadding:"targetPadding",targetPoint:"targetPoint",targetPortID:"targetPortID",tooltip:"tooltip",type:"type",visible:"visible",wrapper:"wrapper",zIndex:"zIndex"},features:[yn]}),n})(),ule=(()=>{class n extends Fh{constructor(){super("connectors")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-connectors"]],contentQueries:function(e,i,r){if(1&e&&dn(r,dle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),fle=["cornerRadius","fill","handleStrokeColor","handleStrokeWidth","height","iconStrokeColor","iconStrokeWidth","id","margin","offset","padding","pathData","tooltip","visibility","width"],ple=[],gle=(()=>{class n extends Bh{constructor(e){super(),this.viewContainerRef=e,_l("currentInstance",this,this.viewContainerRef),this.registerEvents(ple),this.directivePropList=fle}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-node-fixeduserhandle"]],inputs:{cornerRadius:"cornerRadius",fill:"fill",handleStrokeColor:"handleStrokeColor",handleStrokeWidth:"handleStrokeWidth",height:"height",iconStrokeColor:"iconStrokeColor",iconStrokeWidth:"iconStrokeWidth",id:"id",margin:"margin",offset:"offset",padding:"padding",pathData:"pathData",tooltip:"tooltip",visibility:"visibility",width:"width"},features:[yn]}),n})(),vle=(()=>{class n extends Fh{constructor(){super("fixeduserhandles")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-node-fixeduserhandles"]],contentQueries:function(e,i,r){if(1&e&&dn(r,gle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),mle=["addInfo","annotationType","constraints","content","dragLimit","height","horizontalAlignment","hyperlink","id","margin","offset","rotateAngle","rotationReference","style","template","tooltip","type","verticalAlignment","visibility","width"],yle=[],Sle=(()=>{class n extends Bh{constructor(e){super(),this.viewContainerRef=e,_l("currentInstance",this,this.viewContainerRef),this.registerEvents(yle),this.directivePropList=mle}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-node-annotation"]],inputs:{addInfo:"addInfo",annotationType:"annotationType",constraints:"constraints",content:"content",dragLimit:"dragLimit",height:"height",horizontalAlignment:"horizontalAlignment",hyperlink:"hyperlink",id:"id",margin:"margin",offset:"offset",rotateAngle:"rotateAngle",rotationReference:"rotationReference",style:"style",template:"template",tooltip:"tooltip",type:"type",verticalAlignment:"verticalAlignment",visibility:"visibility",width:"width"},features:[yn]}),n})(),Ile=(()=>{class n extends Fh{constructor(){super("annotations")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-node-annotations"]],contentQueries:function(e,i,r){if(1&e&&dn(r,Sle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),ble=["addInfo","connectionDirection","constraints","height","horizontalAlignment","id","inEdges","margin","offset","outEdges","pathData","shape","style","tooltip","verticalAlignment","visibility","width"],Mle=[],wle=(()=>{class n extends Bh{constructor(e){super(),this.viewContainerRef=e,_l("currentInstance",this,this.viewContainerRef),this.registerEvents(Mle),this.directivePropList=ble}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-node-port"]],inputs:{addInfo:"addInfo",connectionDirection:"connectionDirection",constraints:"constraints",height:"height",horizontalAlignment:"horizontalAlignment",id:"id",inEdges:"inEdges",margin:"margin",offset:"offset",outEdges:"outEdges",pathData:"pathData",shape:"shape",style:"style",tooltip:"tooltip",verticalAlignment:"verticalAlignment",visibility:"visibility",width:"width"},features:[yn]}),n})(),Cle=(()=>{class n extends Fh{constructor(){super("ports")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-node-ports"]],contentQueries:function(e,i,r){if(1&e&&dn(r,wle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),Ele=["addInfo","annotations","backgroundColor","borderColor","borderWidth","branch","children","collapseIcon","columnIndex","columnSpan","columns","constraints","container","data","dragSize","excludeFromLayout","expandIcon","fixedUserHandles","flip","flipMode","height","horizontalAlignment","id","isExpanded","layoutInfo","margin","maxHeight","maxWidth","minHeight","minWidth","offsetX","offsetY","padding","pivot","ports","previewSize","rotateAngle","rowIndex","rowSpan","rows","shadow","shape","style","symbolInfo","tooltip","verticalAlignment","visible","width","wrapper","zIndex"],Dle=[],v_=(()=>{class n extends Bh{constructor(e){super(),this.viewContainerRef=e,this.tags=["fixedUserHandles","annotations","ports"],_l("currentInstance",this,this.viewContainerRef),this.registerEvents(Dle),this.directivePropList=Ele}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-node"]],contentQueries:function(e,i,r){if(1&e&&(dn(r,vle,5),dn(r,Ile,5),dn(r,Cle,5)),2&e){let s;Kr(s=en())&&(i.childFixedUserHandles=s.first),Kr(s=en())&&(i.childAnnotations=s.first),Kr(s=en())&&(i.childPorts=s.first)}},inputs:{addInfo:"addInfo",annotations:"annotations",backgroundColor:"backgroundColor",borderColor:"borderColor",borderWidth:"borderWidth",branch:"branch",children:"children",collapseIcon:"collapseIcon",columnIndex:"columnIndex",columnSpan:"columnSpan",columns:"columns",constraints:"constraints",container:"container",data:"data",dragSize:"dragSize",excludeFromLayout:"excludeFromLayout",expandIcon:"expandIcon",fixedUserHandles:"fixedUserHandles",flip:"flip",flipMode:"flipMode",height:"height",horizontalAlignment:"horizontalAlignment",id:"id",isExpanded:"isExpanded",layoutInfo:"layoutInfo",margin:"margin",maxHeight:"maxHeight",maxWidth:"maxWidth",minHeight:"minHeight",minWidth:"minWidth",offsetX:"offsetX",offsetY:"offsetY",padding:"padding",pivot:"pivot",ports:"ports",previewSize:"previewSize",rotateAngle:"rotateAngle",rowIndex:"rowIndex",rowSpan:"rowSpan",rows:"rows",shadow:"shadow",shape:"shape",style:"style",symbolInfo:"symbolInfo",tooltip:"tooltip",verticalAlignment:"verticalAlignment",visible:"visible",width:"width",wrapper:"wrapper",zIndex:"zIndex"},features:[yn]}),n})(),m_=(()=>{class n extends Fh{constructor(){super("nodes")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-nodes"]],contentQueries:function(e,i,r){if(1&e&&dn(r,v_,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})();const xle=["animationComplete","click","collectionChange","commandExecute","connectionChange","contextMenuBeforeItemRender","contextMenuClick","contextMenuOpen","created","dataLoaded","doubleClick","dragEnter","dragLeave","dragOver","drop","elementDraw","expandStateChange","fixedUserHandleClick","historyChange","historyStateChange","keyDown","keyUp","load","loaded","mouseEnter","mouseLeave","mouseOver","mouseWheel","onFixedUserHandleMouseDown","onFixedUserHandleMouseEnter","onFixedUserHandleMouseLeave","onFixedUserHandleMouseUp","onImageLoad","onUserHandleMouseDown","onUserHandleMouseEnter","onUserHandleMouseLeave","onUserHandleMouseUp","positionChange","propertyChange","rotateChange","scrollChange","segmentChange","segmentCollectionChange","selectionChange","sizeChange","sourcePointChange","targetPointChange","textEdit"],Tle=[""];let Ale=(()=>{let n=class extends Fl{constructor(e,i,r,s){super(),this.ngEle=e,this.srenderer=i,this.viewContainerRef=r,this.injector=s,this.tags=["layers","customCursor","connectors","nodes"],this.element=this.ngEle.nativeElement,this.injectedModules=this.injectedModules||[];try{let o=this.injector.get("DiagramsHierarchicalTree");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsMindMap");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsRadialTree");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsComplexHierarchicalTree");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsDataBinding");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsSnapping");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsPrintAndExport");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsBpmnDiagrams");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsSymmetricLayout");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsConnectorBridging");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsUndoRedo");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsLayoutAnimation");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsDiagramContextMenu");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsLineRouting");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsConnectorEditing");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsLineDistribution");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsEj1Serialization");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsFlowchartLayout");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}this.registerEvents(xle),this.addTwoWay.call(this,Tle),_l("currentInstance",this,this.viewContainerRef),this.context=new u_}ngOnInit(){this.context.ngOnInit(this)}ngAfterViewInit(){this.context.ngAfterViewInit(this)}ngOnDestroy(){this.context.ngOnDestroy(this)}ngAfterContentChecked(){this.tagObjects[0].instance=this.childLayers,this.childCustomCursor&&(this.tagObjects[1].instance=this.childCustomCursor),this.childConnectors&&(this.tagObjects[2].instance=this.childConnectors),this.childNodes&&(this.tagObjects[3].instance=this.childNodes),this.context.ngAfterContentChecked(this)}};return n.\u0275fac=function(e){return new(e||n)(Ot($c),Ot(aM),Ot(An),Ot(Wo))},n.\u0275cmp=Hb({type:n,selectors:[["ejs-diagram"]],contentQueries:function(e,i,r){if(1&e&&(dn(r,Wae,5),dn(r,Yae,5),dn(r,Qae,5),dn(r,$ae,5),dn(r,ele,5),dn(r,ule,5),dn(r,m_,5)),2&e){let s;Kr(s=en())&&(i.annotationTemplate=s.first),Kr(s=en())&&(i.nodeTemplate=s.first),Kr(s=en())&&(i.userHandleTemplate=s.first),Kr(s=en())&&(i.childLayers=s.first),Kr(s=en())&&(i.childCustomCursor=s.first),Kr(s=en())&&(i.childConnectors=s.first),Kr(s=en())&&(i.childNodes=s.first)}},inputs:{addInfo:"addInfo",annotationTemplate:"annotationTemplate",backgroundColor:"backgroundColor",bridgeDirection:"bridgeDirection",commandManager:"commandManager",connectorDefaults:"connectorDefaults",connectors:"connectors",constraints:"constraints",contextMenuSettings:"contextMenuSettings",customCursor:"customCursor",dataSourceSettings:"dataSourceSettings",diagramSettings:"diagramSettings",drawingObject:"drawingObject",enableConnectorSplit:"enableConnectorSplit",enablePersistence:"enablePersistence",enableRtl:"enableRtl",fixedUserHandleTemplate:"fixedUserHandleTemplate",getConnectorDefaults:"getConnectorDefaults",getCustomCursor:"getCustomCursor",getCustomProperty:"getCustomProperty",getCustomTool:"getCustomTool",getDescription:"getDescription",getNodeDefaults:"getNodeDefaults",height:"height",historyManager:"historyManager",layers:"layers",layout:"layout",locale:"locale",mode:"mode",nodeDefaults:"nodeDefaults",nodeTemplate:"nodeTemplate",nodes:"nodes",pageSettings:"pageSettings",rulerSettings:"rulerSettings",scrollSettings:"scrollSettings",segmentThumbShape:"segmentThumbShape",segmentThumbSize:"segmentThumbSize",selectedItems:"selectedItems",serializationSettings:"serializationSettings",setNodeTemplate:"setNodeTemplate",snapSettings:"snapSettings",tool:"tool",tooltip:"tooltip",updateSelection:"updateSelection",userHandleTemplate:"userHandleTemplate",width:"width"},outputs:{animationComplete:"animationComplete",click:"click",collectionChange:"collectionChange",commandExecute:"commandExecute",connectionChange:"connectionChange",contextMenuBeforeItemRender:"contextMenuBeforeItemRender",contextMenuClick:"contextMenuClick",contextMenuOpen:"contextMenuOpen",created:"created",dataLoaded:"dataLoaded",doubleClick:"doubleClick",dragEnter:"dragEnter",dragLeave:"dragLeave",dragOver:"dragOver",drop:"drop",elementDraw:"elementDraw",expandStateChange:"expandStateChange",fixedUserHandleClick:"fixedUserHandleClick",historyChange:"historyChange",historyStateChange:"historyStateChange",keyDown:"keyDown",keyUp:"keyUp",load:"load",loaded:"loaded",mouseEnter:"mouseEnter",mouseLeave:"mouseLeave",mouseOver:"mouseOver",mouseWheel:"mouseWheel",onFixedUserHandleMouseDown:"onFixedUserHandleMouseDown",onFixedUserHandleMouseEnter:"onFixedUserHandleMouseEnter",onFixedUserHandleMouseLeave:"onFixedUserHandleMouseLeave",onFixedUserHandleMouseUp:"onFixedUserHandleMouseUp",onImageLoad:"onImageLoad",onUserHandleMouseDown:"onUserHandleMouseDown",onUserHandleMouseEnter:"onUserHandleMouseEnter",onUserHandleMouseLeave:"onUserHandleMouseLeave",onUserHandleMouseUp:"onUserHandleMouseUp",positionChange:"positionChange",propertyChange:"propertyChange",rotateChange:"rotateChange",scrollChange:"scrollChange",segmentChange:"segmentChange",segmentCollectionChange:"segmentCollectionChange",selectionChange:"selectionChange",sizeChange:"sizeChange",sourcePointChange:"sourcePointChange",targetPointChange:"targetPointChange",textEdit:"textEdit"},features:[yn],decls:0,vars:0,template:function(e,i){},encapsulation:2,changeDetection:0}),fb([TT()],n.prototype,"annotationTemplate",void 0),fb([TT()],n.prototype,"nodeTemplate",void 0),fb([TT()],n.prototype,"userHandleTemplate",void 0),n=fb([Rae([u_])],n),n})(),Lle=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Lm({type:n}),n.\u0275inj=gp({imports:[[rq]]}),n})();const Nle=["diagram"];let Ole=(()=>{class n{constructor(){this.ports=[{id:"port1",offset:{x:0,y:.5},visibility:oi.Visible}]}updatePorts(){this.diagram.nodes[0].ports[0].offset={x:1,y:1},this.diagram.dataBind()}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275cmp=Hb({type:n,selectors:[["app-container"]],viewQuery:function(i,r){if(1&i&&function uP(n,t,e){const i=Ti();i.firstCreatePass&&(cP(i,new aP(n,t,e),-1),2==(2&t)&&(i.staticViewQueries=!0)),hP(i,Se(),t)}(Nle,5),2&i){let s;Kr(s=en())&&(r.diagram=s.first)}},standalone:!0,features:[PP([]),RP],decls:6,vars:5,consts:[[3,"click"],["id","diagram","width","100%","height","580px"],["diagram",""],["id","node1",3,"offsetX","offsetY","width","height","ports"]],template:function(i,r){1&i&&(lg(0,"button",0),aw("click",function(){return r.updatePorts()}),function MP(n,t=""){const e=Se(),i=Ti(),r=n+jt,s=i.firstCreatePass?Tu(i,r,1,t,null):i.data[r],o=wP(i,e,s,t,n);e[r]=o,Hm()&&hy(i,e,o,s),ll(s,!1)}(1,"Update Ports"),hg(),lg(2,"ejs-diagram",1,2)(4,"e-nodes"),tw(5,"e-node",3),hg()()),2&i&&(function CN(n=1){EN(Ti(),Se(),zs()+n,!1)}(5),XM("offsetX",150)("offsetY",150)("width",100)("height",100)("ports",r.ports))},dependencies:[Lle,Ale,v_,m_],encapsulation:2})}}return n})();jd(332),function Xq(n,t){return CG({rootComponent:n,...Ez(t)})}(Ole).catch(n=>console.error(n))},332:()=>{!function(Z){const se=Z.performance;function ye(zi){se&&se.mark&&se.mark(zi)}function pe(zi,ht){se&&se.measure&&se.measure(zi,ht)}ye("Zone");const be=Z.__Zone_symbol_prefix||"__zone_symbol__";function ke(zi){return be+zi}const at=!0===Z[ke("forceDuplicateZoneCheck")];if(Z.Zone){if(at||"function"!=typeof Z.Zone.__symbol__)throw new Error("Zone already loaded.");return Z.Zone}let tt=(()=>{class zi{static{this.__symbol__=ke}static assertZonePatched(){if(Z.Promise!==_o.ZoneAwarePromise)throw new Error("Zone.js has detected that ZoneAwarePromise `(window|global).Promise` has been overwritten.\nMost likely cause is that a Promise polyfill has been loaded after Zone.js (Polyfilling Promise api is not necessary when zone.js is loaded. If you must load one, do so before loading zone.js.)")}static get root(){let F=zi.current;for(;F.parent;)F=F.parent;return F}static get current(){return Ur.zone}static get currentTask(){return Do}static __load_patch(F,ae,Et=!1){if(_o.hasOwnProperty(F)){if(!Et&&at)throw Error("Already loaded patch: "+F)}else if(!Z["__Zone_disable_"+F]){const Xt="Zone:"+F;ye(Xt),_o[F]=ae(Z,zi,cn),pe(Xt,Xt)}}get parent(){return this._parent}get name(){return this._name}constructor(F,ae){this._parent=F,this._name=ae?ae.name||"unnamed":"",this._properties=ae&&ae.properties||{},this._zoneDelegate=new Lt(this,this._parent&&this._parent._zoneDelegate,ae)}get(F){const ae=this.getZoneWith(F);if(ae)return ae._properties[F]}getZoneWith(F){let ae=this;for(;ae;){if(ae._properties.hasOwnProperty(F))return ae;ae=ae._parent}return null}fork(F){if(!F)throw new Error("ZoneSpec required!");return this._zoneDelegate.fork(this,F)}wrap(F,ae){if("function"!=typeof F)throw new Error("Expecting function got: "+F);const Et=this._zoneDelegate.intercept(this,F,ae),Xt=this;return function(){return Xt.runGuarded(Et,this,arguments,ae)}}run(F,ae,Et,Xt){Ur={parent:Ur,zone:this};try{return this._zoneDelegate.invoke(this,F,ae,Et,Xt)}finally{Ur=Ur.parent}}runGuarded(F,ae=null,Et,Xt){Ur={parent:Ur,zone:this};try{try{return this._zoneDelegate.invoke(this,F,ae,Et,Xt)}catch(Vn){if(this._zoneDelegate.handleError(this,Vn))throw Vn}}finally{Ur=Ur.parent}}runTask(F,ae,Et){if(F.zone!=this)throw new Error("A task can only be run in the zone of creation! (Creation: "+(F.zone||jn).name+"; Execution: "+this.name+")");if(F.state===sr&&(F.type===rs||F.type===Pt))return;const Xt=F.state!=lt;Xt&&F._transitionTo(lt,Pi),F.runCount++;const Vn=Do;Do=F,Ur={parent:Ur,zone:this};try{F.type==Pt&&F.data&&!F.data.isPeriodic&&(F.cancelFn=void 0);try{return this._zoneDelegate.invokeTask(this,F,ae,Et)}catch(Ue){if(this._zoneDelegate.handleError(this,Ue))throw Ue}}finally{F.state!==sr&&F.state!==et&&(F.type==rs||F.data&&F.data.isPeriodic?Xt&&F._transitionTo(Pi,lt):(F.runCount=0,this._updateTaskCount(F,-1),Xt&&F._transitionTo(sr,lt,sr))),Ur=Ur.parent,Do=Vn}}scheduleTask(F){if(F.zone&&F.zone!==this){let Et=this;for(;Et;){if(Et===F.zone)throw Error(`can not reschedule task to ${this.name} which is descendants of the original zone ${F.zone.name}`);Et=Et.parent}}F._transitionTo(Zr,sr);const ae=[];F._zoneDelegates=ae,F._zone=this;try{F=this._zoneDelegate.scheduleTask(this,F)}catch(Et){throw F._transitionTo(et,Zr,sr),this._zoneDelegate.handleError(this,Et),Et}return F._zoneDelegates===ae&&this._updateTaskCount(F,1),F.state==Zr&&F._transitionTo(Pi,Zr),F}scheduleMicroTask(F,ae,Et,Xt){return this.scheduleTask(new pt(yi,F,ae,Et,Xt,void 0))}scheduleMacroTask(F,ae,Et,Xt,Vn){return this.scheduleTask(new pt(Pt,F,ae,Et,Xt,Vn))}scheduleEventTask(F,ae,Et,Xt,Vn){return this.scheduleTask(new pt(rs,F,ae,Et,Xt,Vn))}cancelTask(F){if(F.zone!=this)throw new Error("A task can only be cancelled in the zone of creation! (Creation: "+(F.zone||jn).name+"; Execution: "+this.name+")");if(F.state===Pi||F.state===lt){F._transitionTo(dr,Pi,lt);try{this._zoneDelegate.cancelTask(this,F)}catch(ae){throw F._transitionTo(et,dr),this._zoneDelegate.handleError(this,ae),ae}return this._updateTaskCount(F,-1),F._transitionTo(sr,dr),F.runCount=0,F}}_updateTaskCount(F,ae){const Et=F._zoneDelegates;-1==ae&&(F._zoneDelegates=null);for(let Xt=0;Xtzi.hasTask(F,ae),onScheduleTask:(zi,ht,F,ae)=>zi.scheduleTask(F,ae),onInvokeTask:(zi,ht,F,ae,Et,Xt)=>zi.invokeTask(F,ae,Et,Xt),onCancelTask:(zi,ht,F,ae)=>zi.cancelTask(F,ae)};class Lt{constructor(ht,F,ae){this._taskCounts={microTask:0,macroTask:0,eventTask:0},this.zone=ht,this._parentDelegate=F,this._forkZS=ae&&(ae&&ae.onFork?ae:F._forkZS),this._forkDlgt=ae&&(ae.onFork?F:F._forkDlgt),this._forkCurrZone=ae&&(ae.onFork?this.zone:F._forkCurrZone),this._interceptZS=ae&&(ae.onIntercept?ae:F._interceptZS),this._interceptDlgt=ae&&(ae.onIntercept?F:F._interceptDlgt),this._interceptCurrZone=ae&&(ae.onIntercept?this.zone:F._interceptCurrZone),this._invokeZS=ae&&(ae.onInvoke?ae:F._invokeZS),this._invokeDlgt=ae&&(ae.onInvoke?F:F._invokeDlgt),this._invokeCurrZone=ae&&(ae.onInvoke?this.zone:F._invokeCurrZone),this._handleErrorZS=ae&&(ae.onHandleError?ae:F._handleErrorZS),this._handleErrorDlgt=ae&&(ae.onHandleError?F:F._handleErrorDlgt),this._handleErrorCurrZone=ae&&(ae.onHandleError?this.zone:F._handleErrorCurrZone),this._scheduleTaskZS=ae&&(ae.onScheduleTask?ae:F._scheduleTaskZS),this._scheduleTaskDlgt=ae&&(ae.onScheduleTask?F:F._scheduleTaskDlgt),this._scheduleTaskCurrZone=ae&&(ae.onScheduleTask?this.zone:F._scheduleTaskCurrZone),this._invokeTaskZS=ae&&(ae.onInvokeTask?ae:F._invokeTaskZS),this._invokeTaskDlgt=ae&&(ae.onInvokeTask?F:F._invokeTaskDlgt),this._invokeTaskCurrZone=ae&&(ae.onInvokeTask?this.zone:F._invokeTaskCurrZone),this._cancelTaskZS=ae&&(ae.onCancelTask?ae:F._cancelTaskZS),this._cancelTaskDlgt=ae&&(ae.onCancelTask?F:F._cancelTaskDlgt),this._cancelTaskCurrZone=ae&&(ae.onCancelTask?this.zone:F._cancelTaskCurrZone),this._hasTaskZS=null,this._hasTaskDlgt=null,this._hasTaskDlgtOwner=null,this._hasTaskCurrZone=null;const Et=ae&&ae.onHasTask;(Et||F&&F._hasTaskZS)&&(this._hasTaskZS=Et?ae:At,this._hasTaskDlgt=F,this._hasTaskDlgtOwner=this,this._hasTaskCurrZone=ht,ae.onScheduleTask||(this._scheduleTaskZS=At,this._scheduleTaskDlgt=F,this._scheduleTaskCurrZone=this.zone),ae.onInvokeTask||(this._invokeTaskZS=At,this._invokeTaskDlgt=F,this._invokeTaskCurrZone=this.zone),ae.onCancelTask||(this._cancelTaskZS=At,this._cancelTaskDlgt=F,this._cancelTaskCurrZone=this.zone))}fork(ht,F){return this._forkZS?this._forkZS.onFork(this._forkDlgt,this.zone,ht,F):new tt(ht,F)}intercept(ht,F,ae){return this._interceptZS?this._interceptZS.onIntercept(this._interceptDlgt,this._interceptCurrZone,ht,F,ae):F}invoke(ht,F,ae,Et,Xt){return this._invokeZS?this._invokeZS.onInvoke(this._invokeDlgt,this._invokeCurrZone,ht,F,ae,Et,Xt):F.apply(ae,Et)}handleError(ht,F){return!this._handleErrorZS||this._handleErrorZS.onHandleError(this._handleErrorDlgt,this._handleErrorCurrZone,ht,F)}scheduleTask(ht,F){let ae=F;if(this._scheduleTaskZS)this._hasTaskZS&&ae._zoneDelegates.push(this._hasTaskDlgtOwner),ae=this._scheduleTaskZS.onScheduleTask(this._scheduleTaskDlgt,this._scheduleTaskCurrZone,ht,F),ae||(ae=F);else if(F.scheduleFn)F.scheduleFn(F);else{if(F.type!=yi)throw new Error("Task is missing scheduleFn.");Wt(F)}return ae}invokeTask(ht,F,ae,Et){return this._invokeTaskZS?this._invokeTaskZS.onInvokeTask(this._invokeTaskDlgt,this._invokeTaskCurrZone,ht,F,ae,Et):F.callback.apply(ae,Et)}cancelTask(ht,F){let ae;if(this._cancelTaskZS)ae=this._cancelTaskZS.onCancelTask(this._cancelTaskDlgt,this._cancelTaskCurrZone,ht,F);else{if(!F.cancelFn)throw Error("Task is not cancelable");ae=F.cancelFn(F)}return ae}hasTask(ht,F){try{this._hasTaskZS&&this._hasTaskZS.onHasTask(this._hasTaskDlgt,this._hasTaskCurrZone,ht,F)}catch(ae){this.handleError(ht,ae)}}_updateTaskCount(ht,F){const ae=this._taskCounts,Et=ae[ht],Xt=ae[ht]=Et+F;if(Xt<0)throw new Error("More tasks executed then were scheduled.");0!=Et&&0!=Xt||this.hasTask(this.zone,{microTask:ae.microTask>0,macroTask:ae.macroTask>0,eventTask:ae.eventTask>0,change:ht})}}class pt{constructor(ht,F,ae,Et,Xt,Vn){if(this._zone=null,this.runCount=0,this._zoneDelegates=null,this._state="notScheduled",this.type=ht,this.source=F,this.data=Et,this.scheduleFn=Xt,this.cancelFn=Vn,!ae)throw new Error("callback is not defined");this.callback=ae;const Ue=this;this.invoke=ht===rs&&Et&&Et.useG?pt.invokeTask:function(){return pt.invokeTask.call(Z,Ue,this,arguments)}}static invokeTask(ht,F,ae){ht||(ht=this),Ls++;try{return ht.runCount++,ht.zone.runTask(ht,F,ae)}finally{1==Ls&&ct(),Ls--}}get zone(){return this._zone}get state(){return this._state}cancelScheduleRequest(){this._transitionTo(sr,Zr)}_transitionTo(ht,F,ae){if(this._state!==F&&this._state!==ae)throw new Error(`${this.type} '${this.source}': can not transition to '${ht}', expecting state '${F}'${ae?" or '"+ae+"'":""}, was '${this._state}'.`);this._state=ht,ht==sr&&(this._zoneDelegates=null)}toString(){return this.data&&typeof this.data.handleId<"u"?this.data.handleId.toString():Object.prototype.toString.call(this)}toJSON(){return{type:this.type,state:this.state,source:this.source,zone:this.zone.name,runCount:this.runCount}}}const Di=ke("setTimeout"),ni=ke("Promise"),mi=ke("then");let is,cr=[],ki=!1;function Pr(zi){if(is||Z[ni]&&(is=Z[ni].resolve(0)),is){let ht=is[mi];ht||(ht=is.then),ht.call(is,zi)}else Z[Di](zi,0)}function Wt(zi){0===Ls&&0===cr.length&&Pr(ct),zi&&cr.push(zi)}function ct(){if(!ki){for(ki=!0;cr.length;){const zi=cr;cr=[];for(let ht=0;htUr,onUnhandledError:jr,microtaskDrainDone:jr,scheduleMicroTask:Wt,showUncaughtError:()=>!tt[ke("ignoreConsoleErrorUncaughtError")],patchEventTarget:()=>[],patchOnProperties:jr,patchMethod:()=>jr,bindArguments:()=>[],patchThen:()=>jr,patchMacroTask:()=>jr,patchEventPrototype:()=>jr,isIEOrEdge:()=>!1,getGlobalObjects:()=>{},ObjectDefineProperty:()=>jr,ObjectGetOwnPropertyDescriptor:()=>{},ObjectCreate:()=>{},ArraySlice:()=>[],patchClass:()=>jr,wrapWithCurrentZone:()=>jr,filterProperties:()=>[],attachOriginToPatched:()=>jr,_redefineProperty:()=>jr,patchCallbacks:()=>jr,nativeScheduleMicroTask:Pr};let Ur={parent:null,zone:new tt(null,null)},Do=null,Ls=0;function jr(){}pe("Zone","Zone"),Z.Zone=tt}(globalThis);const Wl=Object.getOwnPropertyDescriptor,Ud=Object.defineProperty,jd=Object.getPrototypeOf,Vd=Object.create,vb=Array.prototype.slice,pm="addEventListener",$r="removeEventListener",Yl=Zone.__symbol__(pm),_h=Zone.__symbol__($r),Ts="true",Wi="false",Wd=Zone.__symbol__("");function op(Z,se){return Zone.current.wrap(Z,se)}function gm(Z,se,ye,pe,be){return Zone.current.scheduleMacroTask(Z,se,ye,pe,be)}const Ji=Zone.__symbol__,Uh=typeof window<"u",jh=Uh?window:void 0,gn=Uh&&jh||globalThis,vm="removeAttribute";function Yd(Z,se){for(let ye=Z.length-1;ye>=0;ye--)"function"==typeof Z[ye]&&(Z[ye]=op(Z[ye],se+"_"+ye));return Z}function ap(Z){return!Z||!1!==Z.writable&&!("function"==typeof Z.get&&typeof Z.set>"u")}const lp=typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope,Vh=!("nw"in gn)&&typeof gn.process<"u"&&"[object process]"==={}.toString.call(gn.process),Qd=!Vh&&!lp&&!(!Uh||!jh.HTMLElement),hp=typeof gn.process<"u"&&"[object process]"==={}.toString.call(gn.process)&&!lp&&!(!Uh||!jh.HTMLElement),Ql={},Wh=function(Z){if(!(Z=Z||gn.event))return;let se=Ql[Z.type];se||(se=Ql[Z.type]=Ji("ON_PROPERTY"+Z.type));const ye=this||Z.target||gn,pe=ye[se];let be;return Qd&&ye===jh&&"error"===Z.type?(be=pe&&pe.call(this,Z.message,Z.filename,Z.lineno,Z.colno,Z.error),!0===be&&Z.preventDefault()):(be=pe&&pe.apply(this,arguments),null!=be&&!be&&Z.preventDefault()),be};function Gl(Z,se,ye){let pe=Wl(Z,se);if(!pe&&ye&&Wl(ye,se)&&(pe={enumerable:!0,configurable:!0}),!pe||!pe.configurable)return;const be=Ji("on"+se+"patched");if(Z.hasOwnProperty(be)&&Z[be])return;delete pe.writable,delete pe.value;const ke=pe.get,at=pe.set,tt=se.slice(2);let At=Ql[tt];At||(At=Ql[tt]=Ji("ON_PROPERTY"+tt)),pe.set=function(Lt){let pt=this;!pt&&Z===gn&&(pt=gn),pt&&("function"==typeof pt[At]&&pt.removeEventListener(tt,Wh),at&&at.call(pt,null),pt[At]=Lt,"function"==typeof Lt&&pt.addEventListener(tt,Wh,!1))},pe.get=function(){let Lt=this;if(!Lt&&Z===gn&&(Lt=gn),!Lt)return null;const pt=Lt[At];if(pt)return pt;if(ke){let Di=ke.call(this);if(Di)return pe.set.call(this,Di),"function"==typeof Lt[vm]&&Lt.removeAttribute(se),Di}return null},Ud(Z,se,pe),Z[be]=!0}function cp(Z,se,ye){if(se)for(let pe=0;pefunction(at,tt){const At=ye(at,tt);return At.cbIdx>=0&&"function"==typeof tt[At.cbIdx]?gm(At.name,tt[At.cbIdx],At,be):ke.apply(at,tt)})}function Ia(Z,se){Z[Ji("OriginalDelegate")]=se}let yb=!1,Xd=!1;function Sb(){if(yb)return Xd;yb=!0;try{const Z=jh.navigator.userAgent;(-1!==Z.indexOf("MSIE ")||-1!==Z.indexOf("Trident/")||-1!==Z.indexOf("Edge/"))&&(Xd=!0)}catch{}return Xd}Zone.__load_patch("ZoneAwarePromise",(Z,se,ye)=>{const pe=Object.getOwnPropertyDescriptor,be=Object.defineProperty,at=ye.symbol,tt=[],At=!1!==Z[at("DISABLE_WRAPPING_UNCAUGHT_PROMISE_REJECTION")],Lt=at("Promise"),pt=at("then"),Di="__creationTrace__";ye.onUnhandledError=Ue=>{if(ye.showUncaughtError()){const He=Ue&&Ue.rejection;He?console.error("Unhandled Promise rejection:",He instanceof Error?He.message:He,"; Zone:",Ue.zone.name,"; Task:",Ue.task&&Ue.task.source,"; Value:",He,He instanceof Error?He.stack:void 0):console.error(Ue)}},ye.microtaskDrainDone=()=>{for(;tt.length;){const Ue=tt.shift();try{Ue.zone.runGuarded(()=>{throw Ue.throwOriginal?Ue.rejection:Ue})}catch(He){mi(He)}}};const ni=at("unhandledPromiseRejectionHandler");function mi(Ue){ye.onUnhandledError(Ue);try{const He=se[ni];"function"==typeof He&&He.call(this,Ue)}catch{}}function cr(Ue){return Ue&&Ue.then}function ki(Ue){return Ue}function is(Ue){return F.reject(Ue)}const Pr=at("state"),Wt=at("value"),ct=at("finally"),jn=at("parentPromiseValue"),sr=at("parentPromiseState"),Zr="Promise.then",Pi=null,lt=!0,dr=!1,et=0;function yi(Ue,He){return ge=>{try{cn(Ue,He,ge)}catch(We){cn(Ue,!1,We)}}}const Pt=function(){let Ue=!1;return function(ge){return function(){Ue||(Ue=!0,ge.apply(null,arguments))}}},rs="Promise resolved with itself",_o=at("currentTaskTrace");function cn(Ue,He,ge){const We=Pt();if(Ue===ge)throw new TypeError(rs);if(Ue[Pr]===Pi){let wt=null;try{("object"==typeof ge||"function"==typeof ge)&&(wt=ge&&ge.then)}catch(Xe){return We(()=>{cn(Ue,!1,Xe)})(),Ue}if(He!==dr&&ge instanceof F&&ge.hasOwnProperty(Pr)&&ge.hasOwnProperty(Wt)&&ge[Pr]!==Pi)Do(ge),cn(Ue,ge[Pr],ge[Wt]);else if(He!==dr&&"function"==typeof wt)try{wt.call(ge,We(yi(Ue,He)),We(yi(Ue,!1)))}catch(Xe){We(()=>{cn(Ue,!1,Xe)})()}else{Ue[Pr]=He;const Xe=Ue[Wt];if(Ue[Wt]=ge,Ue[ct]===ct&&He===lt&&(Ue[Pr]=Ue[sr],Ue[Wt]=Ue[jn]),He===dr&&ge instanceof Error){const mt=se.currentTask&&se.currentTask.data&&se.currentTask.data[Di];mt&&be(ge,_o,{configurable:!0,enumerable:!1,writable:!0,value:mt})}for(let mt=0;mt{try{const dt=Ue[Wt],qt=!!ge&&ct===ge[ct];qt&&(ge[jn]=dt,ge[sr]=Xe);const hi=He.run(mt,void 0,qt&&mt!==is&&mt!==ki?[]:[dt]);cn(ge,!0,hi)}catch(dt){cn(ge,!1,dt)}},ge)}const zi=function(){},ht=Z.AggregateError;class F{static toString(){return"function ZoneAwarePromise() { [native code] }"}static resolve(He){return He instanceof F?He:cn(new this(null),lt,He)}static reject(He){return cn(new this(null),dr,He)}static withResolvers(){const He={};return He.promise=new F((ge,We)=>{He.resolve=ge,He.reject=We}),He}static any(He){if(!He||"function"!=typeof He[Symbol.iterator])return Promise.reject(new ht([],"All promises were rejected"));const ge=[];let We=0;try{for(let mt of He)We++,ge.push(F.resolve(mt))}catch{return Promise.reject(new ht([],"All promises were rejected"))}if(0===We)return Promise.reject(new ht([],"All promises were rejected"));let wt=!1;const Xe=[];return new F((mt,dt)=>{for(let qt=0;qt{wt||(wt=!0,mt(hi))},hi=>{Xe.push(hi),We--,0===We&&(wt=!0,dt(new ht(Xe,"All promises were rejected")))})})}static race(He){let ge,We,wt=new this((dt,qt)=>{ge=dt,We=qt});function Xe(dt){ge(dt)}function mt(dt){We(dt)}for(let dt of He)cr(dt)||(dt=this.resolve(dt)),dt.then(Xe,mt);return wt}static all(He){return F.allWithCallback(He)}static allSettled(He){return(this&&this.prototype instanceof F?this:F).allWithCallback(He,{thenCallback:We=>({status:"fulfilled",value:We}),errorCallback:We=>({status:"rejected",reason:We})})}static allWithCallback(He,ge){let We,wt,Xe=new this((hi,ur)=>{We=hi,wt=ur}),mt=2,dt=0;const qt=[];for(let hi of He){cr(hi)||(hi=this.resolve(hi));const ur=dt;try{hi.then(ir=>{qt[ur]=ge?ge.thenCallback(ir):ir,mt--,0===mt&&We(qt)},ir=>{ge?(qt[ur]=ge.errorCallback(ir),mt--,0===mt&&We(qt)):wt(ir)})}catch(ir){wt(ir)}mt++,dt++}return mt-=2,0===mt&&We(qt),Xe}constructor(He){const ge=this;if(!(ge instanceof F))throw new Error("Must be an instanceof Promise.");ge[Pr]=Pi,ge[Wt]=[];try{const We=Pt();He&&He(We(yi(ge,lt)),We(yi(ge,dr)))}catch(We){cn(ge,!1,We)}}get[Symbol.toStringTag](){return"Promise"}get[Symbol.species](){return F}then(He,ge){let We=this.constructor?.[Symbol.species];(!We||"function"!=typeof We)&&(We=this.constructor||F);const wt=new We(zi),Xe=se.current;return this[Pr]==Pi?this[Wt].push(Xe,wt,He,ge):Ls(this,Xe,wt,He,ge),wt}catch(He){return this.then(null,He)}finally(He){let ge=this.constructor?.[Symbol.species];(!ge||"function"!=typeof ge)&&(ge=F);const We=new ge(zi);We[ct]=ct;const wt=se.current;return this[Pr]==Pi?this[Wt].push(wt,We,He,He):Ls(this,wt,We,He,He),We}}F.resolve=F.resolve,F.reject=F.reject,F.race=F.race,F.all=F.all;const ae=Z[Lt]=Z.Promise;Z.Promise=F;const Et=at("thenPatched");function Xt(Ue){const He=Ue.prototype,ge=pe(He,"then");if(ge&&(!1===ge.writable||!ge.configurable))return;const We=He.then;He[pt]=We,Ue.prototype.then=function(wt,Xe){return new F((dt,qt)=>{We.call(this,dt,qt)}).then(wt,Xe)},Ue[Et]=!0}return ye.patchThen=Xt,ae&&(Xt(ae),tl(Z,"fetch",Ue=>function Vn(Ue){return function(He,ge){let We=Ue.apply(He,ge);if(We instanceof F)return We;let wt=We.constructor;return wt[Et]||Xt(wt),We}}(Ue))),Promise[se.__symbol__("uncaughtPromiseErrors")]=tt,F}),Zone.__load_patch("toString",Z=>{const se=Function.prototype.toString,ye=Ji("OriginalDelegate"),pe=Ji("Promise"),be=Ji("Error"),ke=function(){if("function"==typeof this){const Lt=this[ye];if(Lt)return"function"==typeof Lt?se.call(Lt):Object.prototype.toString.call(Lt);if(this===Promise){const pt=Z[pe];if(pt)return se.call(pt)}if(this===Error){const pt=Z[be];if(pt)return se.call(pt)}}return se.call(this)};ke[ye]=se,Function.prototype.toString=ke;const at=Object.prototype.toString;Object.prototype.toString=function(){return"function"==typeof Promise&&this instanceof Promise?"[object Promise]":at.call(this)}});let il=!1;if(typeof window<"u")try{const Z=Object.defineProperty({},"passive",{get:function(){il=!0}});window.addEventListener("test",Z,Z),window.removeEventListener("test",Z,Z)}catch{il=!1}const kT={useG:!0},Co={},Ib={},Sm=new RegExp("^"+Wd+"(\\w+)(true|false)$"),bb=Ji("propagationStopped");function Im(Z,se){const ye=(se?se(Z):Z)+Wi,pe=(se?se(Z):Z)+Ts,be=Wd+ye,ke=Wd+pe;Co[Z]={},Co[Z][Wi]=be,Co[Z][Ts]=ke}function Mb(Z,se,ye,pe){const be=pe&&pe.add||pm,ke=pe&&pe.rm||$r,at=pe&&pe.listeners||"eventListeners",tt=pe&&pe.rmAll||"removeAllListeners",At=Ji(be),Lt="."+be+":",pt="prependListener",Di="."+pt+":",ni=function(Wt,ct,jn){if(Wt.isRemoved)return;const sr=Wt.callback;let Zr;"object"==typeof sr&&sr.handleEvent&&(Wt.callback=lt=>sr.handleEvent(lt),Wt.originalDelegate=sr);try{Wt.invoke(Wt,ct,[jn])}catch(lt){Zr=lt}const Pi=Wt.options;return Pi&&"object"==typeof Pi&&Pi.once&&ct[ke].call(ct,jn.type,Wt.originalDelegate?Wt.originalDelegate:Wt.callback,Pi),Zr};function mi(Wt,ct,jn){if(!(ct=ct||Z.event))return;const sr=Wt||ct.target||Z,Zr=sr[Co[ct.type][jn?Ts:Wi]];if(Zr){const Pi=[];if(1===Zr.length){const lt=ni(Zr[0],sr,ct);lt&&Pi.push(lt)}else{const lt=Zr.slice();for(let dr=0;dr{throw dr})}}}const cr=function(Wt){return mi(this,Wt,!1)},ki=function(Wt){return mi(this,Wt,!0)};function is(Wt,ct){if(!Wt)return!1;let jn=!0;ct&&void 0!==ct.useG&&(jn=ct.useG);const sr=ct&&ct.vh;let Zr=!0;ct&&void 0!==ct.chkDup&&(Zr=ct.chkDup);let Pi=!1;ct&&void 0!==ct.rt&&(Pi=ct.rt);let lt=Wt;for(;lt&&!lt.hasOwnProperty(be);)lt=jd(lt);if(!lt&&Wt[be]&&(lt=Wt),!lt||lt[At])return!1;const dr=ct&&ct.eventNameToString,et={},yi=lt[At]=lt[be],Pt=lt[Ji(ke)]=lt[ke],rs=lt[Ji(at)]=lt[at],_o=lt[Ji(tt)]=lt[tt];let cn;ct&&ct.prepend&&(cn=lt[Ji(ct.prepend)]=lt[ct.prepend]);const F=jn?function(ge){if(!et.isExisting)return yi.call(et.target,et.eventName,et.capture?ki:cr,et.options)}:function(ge){return yi.call(et.target,et.eventName,ge.invoke,et.options)},ae=jn?function(ge){if(!ge.isRemoved){const We=Co[ge.eventName];let wt;We&&(wt=We[ge.capture?Ts:Wi]);const Xe=wt&&ge.target[wt];if(Xe)for(let mt=0;mt{Vo.zone.cancelTask(Vo)},{once:!0})),et.target=null,Fc&&(Fc.taskData=null),$d&&(Tn.once=!0),!il&&"boolean"==typeof Vo.options||(Vo.options=Tn),Vo.target=qt,Vo.capture=Zl,Vo.eventName=hi,ir&&(Vo.originalDelegate=ur),dt?jo.unshift(Vo):jo.push(Vo),mt?qt:void 0}};return lt[be]=He(yi,Lt,F,ae,Pi),cn&&(lt[pt]=He(cn,Di,function(ge){return cn.call(et.target,et.eventName,ge.invoke,et.options)},ae,Pi,!0)),lt[ke]=function(){const ge=this||Z;let We=arguments[0];ct&&ct.transferEventName&&(We=ct.transferEventName(We));const wt=arguments[2],Xe=!!wt&&("boolean"==typeof wt||wt.capture),mt=arguments[1];if(!mt)return Pt.apply(this,arguments);if(sr&&!sr(Pt,mt,ge,arguments))return;const dt=Co[We];let qt;dt&&(qt=dt[Xe?Ts:Wi]);const hi=qt&&ge[qt];if(hi)for(let ur=0;urfunction(be,ke){be[bb]=!0,pe&&pe.apply(be,ke)})}function Cb(Z,se,ye,pe,be){const ke=Zone.__symbol__(pe);if(se[ke])return;const at=se[ke]=se[pe];se[pe]=function(tt,At,Lt){return At&&At.prototype&&be.forEach(function(pt){const Di=`${ye}.${pe}::`+pt,ni=At.prototype;try{if(ni.hasOwnProperty(pt)){const mi=Z.ObjectGetOwnPropertyDescriptor(ni,pt);mi&&mi.value?(mi.value=Z.wrapWithCurrentZone(mi.value,Di),Z._redefineProperty(At.prototype,pt,mi)):ni[pt]&&(ni[pt]=Z.wrapWithCurrentZone(ni[pt],Di))}else ni[pt]&&(ni[pt]=Z.wrapWithCurrentZone(ni[pt],Di))}catch{}}),at.call(se,tt,At,Lt)},Z.attachOriginToPatched(se[pe],at)}function Eb(Z,se,ye){if(!ye||0===ye.length)return se;const pe=ye.filter(ke=>ke.target===Z);if(!pe||0===pe.length)return se;const be=pe[0].ignoreProperties;return se.filter(ke=>-1===be.indexOf(ke))}function Eo(Z,se,ye,pe){Z&&cp(Z,Eb(Z,se,ye),pe)}function qd(Z){return Object.getOwnPropertyNames(Z).filter(se=>se.startsWith("on")&&se.length>2).map(se=>se.substring(2))}Zone.__load_patch("util",(Z,se,ye)=>{const pe=qd(Z);ye.patchOnProperties=cp,ye.patchMethod=tl,ye.bindArguments=Yd,ye.patchMacroTask=mb;const be=se.__symbol__("BLACK_LISTED_EVENTS"),ke=se.__symbol__("UNPATCHED_EVENTS");Z[ke]&&(Z[be]=Z[ke]),Z[be]&&(se[be]=se[ke]=Z[be]),ye.patchEventPrototype=bm,ye.patchEventTarget=Mb,ye.isIEOrEdge=Sb,ye.ObjectDefineProperty=Ud,ye.ObjectGetOwnPropertyDescriptor=Wl,ye.ObjectCreate=Vd,ye.ArraySlice=vb,ye.patchClass=Gd,ye.wrapWithCurrentZone=op,ye.filterProperties=Eb,ye.attachOriginToPatched=Ia,ye._redefineProperty=Object.defineProperty,ye.patchCallbacks=Cb,ye.getGlobalObjects=()=>({globalSources:Ib,zoneSymbolEventNames:Co,eventNames:pe,isBrowser:Qd,isMix:hp,isNode:Vh,TRUE_STR:Ts,FALSE_STR:Wi,ZONE_SYMBOL_PREFIX:Wd,ADD_EVENT_LISTENER_STR:pm,REMOVE_EVENT_LISTENER_STR:$r})});const As=Ji("zoneTask");function Xl(Z,se,ye,pe){let be=null,ke=null;ye+=pe;const at={};function tt(Lt){const pt=Lt.data;return pt.args[0]=function(){return Lt.invoke.apply(this,arguments)},pt.handleId=be.apply(Z,pt.args),Lt}function At(Lt){return ke.call(Z,Lt.data.handleId)}be=tl(Z,se+=pe,Lt=>function(pt,Di){if("function"==typeof Di[0]){const ni={isPeriodic:"Interval"===pe,delay:"Timeout"===pe||"Interval"===pe?Di[1]||0:void 0,args:Di},mi=Di[0];Di[0]=function(){try{return mi.apply(this,arguments)}finally{ni.isPeriodic||("number"==typeof ni.handleId?delete at[ni.handleId]:ni.handleId&&(ni.handleId[As]=null))}};const cr=gm(se,Di[0],ni,tt,At);if(!cr)return cr;const ki=cr.data.handleId;return"number"==typeof ki?at[ki]=cr:ki&&(ki[As]=cr),ki&&ki.ref&&ki.unref&&"function"==typeof ki.ref&&"function"==typeof ki.unref&&(cr.ref=ki.ref.bind(ki),cr.unref=ki.unref.bind(ki)),"number"==typeof ki||ki?ki:cr}return Lt.apply(Z,Di)}),ke=tl(Z,ye,Lt=>function(pt,Di){const ni=Di[0];let mi;"number"==typeof ni?mi=at[ni]:(mi=ni&&ni[As],mi||(mi=ni)),mi&&"string"==typeof mi.type?"notScheduled"!==mi.state&&(mi.cancelFn&&mi.data.isPeriodic||0===mi.runCount)&&("number"==typeof ni?delete at[ni]:ni&&(ni[As]=null),mi.zone.cancelTask(mi)):Lt.apply(Z,Di)})}Zone.__load_patch("legacy",Z=>{const se=Z[Zone.__symbol__("legacyPatch")];se&&se()}),Zone.__load_patch("timers",Z=>{const ye="clear";Xl(Z,"set",ye,"Timeout"),Xl(Z,"set",ye,"Interval"),Xl(Z,"set",ye,"Immediate")}),Zone.__load_patch("requestAnimationFrame",Z=>{Xl(Z,"request","cancel","AnimationFrame"),Xl(Z,"mozRequest","mozCancel","AnimationFrame"),Xl(Z,"webkitRequest","webkitCancel","AnimationFrame")}),Zone.__load_patch("blocking",(Z,se)=>{const ye=["alert","prompt","confirm"];for(let pe=0;pefunction(At,Lt){return se.current.run(ke,Z,Lt,tt)})}),Zone.__load_patch("EventTarget",(Z,se,ye)=>{(function ql(Z,se){se.patchEventPrototype(Z,se)})(Z,ye),function wm(Z,se){if(Zone[se.symbol("patchEventTarget")])return;const{eventNames:ye,zoneSymbolEventNames:pe,TRUE_STR:be,FALSE_STR:ke,ZONE_SYMBOL_PREFIX:at}=se.getGlobalObjects();for(let At=0;At{Gd("MutationObserver"),Gd("WebKitMutationObserver")}),Zone.__load_patch("IntersectionObserver",(Z,se,ye)=>{Gd("IntersectionObserver")}),Zone.__load_patch("FileReader",(Z,se,ye)=>{Gd("FileReader")}),Zone.__load_patch("on_property",(Z,se,ye)=>{!function dp(Z,se){if(Vh&&!hp||Zone[Z.symbol("patchEvents")])return;const ye=se.__Zone_ignore_on_properties;let pe=[];if(Qd){const be=window;pe=pe.concat(["Document","SVGElement","Element","HTMLElement","HTMLBodyElement","HTMLMediaElement","HTMLFrameSetElement","HTMLFrameElement","HTMLIFrameElement","HTMLMarqueeElement","Worker"]);const ke=function ym(){try{const Z=jh.navigator.userAgent;if(-1!==Z.indexOf("MSIE ")||-1!==Z.indexOf("Trident/"))return!0}catch{}return!1}()?[{target:be,ignoreProperties:["error"]}]:[];Eo(be,qd(be),ye&&ye.concat(ke),jd(be))}pe=pe.concat(["XMLHttpRequest","XMLHttpRequestEventTarget","IDBIndex","IDBRequest","IDBOpenDBRequest","IDBDatabase","IDBTransaction","IDBCursor","WebSocket"]);for(let be=0;be{!function Mm(Z,se){const{isBrowser:ye,isMix:pe}=se.getGlobalObjects();(ye||pe)&&Z.customElements&&"customElements"in Z&&se.patchCallbacks(se,Z.customElements,"customElements","define",["connectedCallback","disconnectedCallback","adoptedCallback","attributeChangedCallback"])}(Z,ye)}),Zone.__load_patch("XHR",(Z,se)=>{!function At(Lt){const pt=Lt.XMLHttpRequest;if(!pt)return;const Di=pt.prototype;let mi=Di[Yl],cr=Di[_h];if(!mi){const et=Lt.XMLHttpRequestEventTarget;if(et){const yi=et.prototype;mi=yi[Yl],cr=yi[_h]}}const ki="readystatechange",is="scheduled";function Pr(et){const yi=et.data,Pt=yi.target;Pt[ke]=!1,Pt[tt]=!1;const rs=Pt[be];mi||(mi=Pt[Yl],cr=Pt[_h]),rs&&cr.call(Pt,ki,rs);const _o=Pt[be]=()=>{if(Pt.readyState===Pt.DONE)if(!yi.aborted&&Pt[ke]&&et.state===is){const Ur=Pt[se.__symbol__("loadfalse")];if(0!==Pt.status&&Ur&&Ur.length>0){const Do=et.invoke;et.invoke=function(){const Ls=Pt[se.__symbol__("loadfalse")];for(let jr=0;jrfunction(et,yi){return et[pe]=0==yi[2],et[at]=yi[1],jn.apply(et,yi)}),Zr=Ji("fetchTaskAborting"),Pi=Ji("fetchTaskScheduling"),lt=tl(Di,"send",()=>function(et,yi){if(!0===se.current[Pi]||et[pe])return lt.apply(et,yi);{const Pt={target:et,url:et[at],isPeriodic:!1,args:yi,aborted:!1},rs=gm("XMLHttpRequest.send",Wt,Pt,Pr,ct);et&&!0===et[tt]&&!Pt.aborted&&rs.state===is&&rs.invoke()}}),dr=tl(Di,"abort",()=>function(et,yi){const Pt=function ni(et){return et[ye]}(et);if(Pt&&"string"==typeof Pt.type){if(null==Pt.cancelFn||Pt.data&&Pt.data.aborted)return;Pt.zone.cancelTask(Pt)}else if(!0===se.current[Zr])return dr.apply(et,yi)})}(Z);const ye=Ji("xhrTask"),pe=Ji("xhrSync"),be=Ji("xhrListener"),ke=Ji("xhrScheduled"),at=Ji("xhrURL"),tt=Ji("xhrErrorBeforeScheduled")}),Zone.__load_patch("geolocation",Z=>{Z.navigator&&Z.navigator.geolocation&&function mm(Z,se){const ye=Z.constructor.name;for(let pe=0;pe{const At=function(){return tt.apply(this,Yd(arguments,ye+"."+be))};return Ia(At,tt),At})(ke)}}}(Z.navigator.geolocation,["getCurrentPosition","watchPosition"])}),Zone.__load_patch("PromiseRejectionEvent",(Z,se)=>{function ye(pe){return function(be){wb(Z,pe).forEach(at=>{const tt=Z.PromiseRejectionEvent;if(tt){const At=new tt(pe,{promise:be.promise,reason:be.rejection});at.invoke(At)}})}}Z.PromiseRejectionEvent&&(se[Ji("unhandledPromiseRejectionHandler")]=ye("unhandledrejection"),se[Ji("rejectionHandledHandler")]=ye("rejectionhandled"))}),Zone.__load_patch("queueMicrotask",(Z,se,ye)=>{!function up(Z,se){se.patchMethod(Z,"queueMicrotask",ye=>function(pe,be){Zone.current.scheduleMicroTask("queueMicrotask",be[0])})}(Z,ye)})}},Wl=>{Wl(Wl.s=51)}]); \ No newline at end of file diff --git a/ej2-angular/samples/diagram/ports/remove-cs1/index.html b/ej2-angular/samples/diagram/ports/remove-cs1/index.html index a59ee9ff0b..d301c06ff3 100644 --- a/ej2-angular/samples/diagram/ports/remove-cs1/index.html +++ b/ej2-angular/samples/diagram/ports/remove-cs1/index.html @@ -19,5 +19,5 @@
Loading....
- + \ No newline at end of file diff --git a/ej2-angular/samples/diagram/ports/remove-cs1/main.057b645816e1cd30.js b/ej2-angular/samples/diagram/ports/remove-cs1/main.057b645816e1cd30.js deleted file mode 100644 index 46c1fa3792..0000000000 --- a/ej2-angular/samples/diagram/ports/remove-cs1/main.057b645816e1cd30.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";(self.webpackChunksyncfusion_component=self.webpackChunksyncfusion_component||[]).push([[179],{51:(_l,_d,Ud)=>{let $r=null,Fh=1;const Ts=Symbol("SIGNAL");function Wi(n){const t=$r;return $r=n,t}function gn(n){if((!Vh(n)||n.dirty)&&(n.dirty||n.lastCleanEpoch!==Fh)){if(!n.producerMustRecompute(n)&&!jh(n))return n.dirty=!1,void(n.lastCleanEpoch=Fh);n.producerRecomputeValue(n),n.dirty=!1,n.lastCleanEpoch=Fh}}function jh(n){Vl(n);for(let t=0;t0}function Vl(n){n.producerNode??=[],n.producerIndexOfThis??=[],n.producerLastReadVersion??=[]}let Gd=null;function Eo(n){return"function"==typeof n}function Xd(n){const e=n(i=>{Error.call(i),i.stack=(new Error).stack});return e.prototype=Object.create(Error.prototype),e.prototype.constructor=e,e}const df=Xd(n=>function(e){n(this),this.message=e?`${e.length} errors occurred during unsubscription:\n${e.map((i,r)=>`${r+1}) ${i.toString()}`).join("\n ")}`:"",this.name="UnsubscriptionError",this.errors=e});function uf(n,t){if(n){const e=n.indexOf(t);0<=e&&n.splice(e,1)}}class As{constructor(t){this.initialTeardown=t,this.closed=!1,this._parentage=null,this._finalizers=null}unsubscribe(){let t;if(!this.closed){this.closed=!0;const{_parentage:e}=this;if(e)if(this._parentage=null,Array.isArray(e))for(const s of e)s.remove(this);else e.remove(this);const{initialTeardown:i}=this;if(Eo(i))try{i()}catch(s){t=s instanceof df?s.errors:[s]}const{_finalizers:r}=this;if(r){this._finalizers=null;for(const s of r)try{Mm(s)}catch(o){t=t??[],o instanceof df?t=[...t,...o.errors]:t.push(o)}}if(t)throw new df(t)}}add(t){var e;if(t&&t!==this)if(this.closed)Mm(t);else{if(t instanceof As){if(t.closed||t._hasParent(this))return;t._addParent(this)}(this._finalizers=null!==(e=this._finalizers)&&void 0!==e?e:[]).push(t)}}_hasParent(t){const{_parentage:e}=this;return e===t||Array.isArray(e)&&e.includes(t)}_addParent(t){const{_parentage:e}=this;this._parentage=Array.isArray(e)?(e.push(t),e):e?[e,t]:t}_removeParent(t){const{_parentage:e}=this;e===t?this._parentage=null:Array.isArray(e)&&uf(e,t)}remove(t){const{_finalizers:e}=this;e&&uf(e,t),t instanceof As&&t._removeParent(this)}}As.EMPTY=(()=>{const n=new As;return n.closed=!0,n})();const Wl=As.EMPTY;function bm(n){return n instanceof As||n&&"closed"in n&&Eo(n.remove)&&Eo(n.add)&&Eo(n.unsubscribe)}function Mm(n){Eo(n)?n():n.unsubscribe()}const Yl={onUnhandledError:null,onStoppedNotification:null,Promise:void 0,useDeprecatedSynchronousErrorHandling:!1,useDeprecatedNextContext:!1},Z={setTimeout(n,t,...e){const{delegate:i}=Z;return i?.setTimeout?i.setTimeout(n,t,...e):setTimeout(n,t,...e)},clearTimeout(n){const{delegate:t}=Z;return(t?.clearTimeout||clearTimeout)(n)},delegate:void 0};function ye(){}const fe=at("C",void 0,void 0);function at(n,t,e){return{kind:n,value:t,error:e}}let tt=null;function At(n){if(Yl.useDeprecatedSynchronousErrorHandling){const t=!tt;if(t&&(tt={errorThrown:!1,error:null}),n(),t){const{errorThrown:e,error:i}=tt;if(tt=null,e)throw i}}else n()}class ft extends As{constructor(t){super(),this.isStopped=!1,t?(this.destination=t,bm(t)&&t.add(this)):this.destination=Wt}static create(t,e,i){return new cr(t,e,i)}next(t){this.isStopped?kr(function ke(n){return at("N",n,void 0)}(t),this):this._next(t)}error(t){this.isStopped?kr(function be(n){return at("E",void 0,n)}(t),this):(this.isStopped=!0,this._error(t))}complete(){this.isStopped?kr(fe,this):(this.isStopped=!0,this._complete())}unsubscribe(){this.closed||(this.isStopped=!0,super.unsubscribe(),this.destination=null)}_next(t){this.destination.next(t)}_error(t){try{this.destination.error(t)}finally{this.unsubscribe()}}_complete(){try{this.destination.complete()}finally{this.unsubscribe()}}}const Ei=Function.prototype.bind;function ii(n,t){return Ei.call(n,t)}class gi{constructor(t){this.partialObserver=t}next(t){const{partialObserver:e}=this;if(e.next)try{e.next(t)}catch(i){Oi(i)}}error(t){const{partialObserver:e}=this;if(e.error)try{e.error(t)}catch(i){Oi(i)}else Oi(t)}complete(){const{partialObserver:t}=this;if(t.complete)try{t.complete()}catch(e){Oi(e)}}}class cr extends ft{constructor(t,e,i){let r;if(super(),Eo(t)||!t)r={next:t??void 0,error:e??void 0,complete:i??void 0};else{let s;this&&Yl.useDeprecatedNextContext?(s=Object.create(t),s.unsubscribe=()=>this.unsubscribe(),r={next:t.next&&ii(t.next,s),error:t.error&&ii(t.error,s),complete:t.complete&&ii(t.complete,s)}):r=t}this.destination=new gi(r)}}function Oi(n){Yl.useDeprecatedSynchronousErrorHandling?function Lt(n){Yl.useDeprecatedSynchronousErrorHandling&&tt&&(tt.errorThrown=!0,tt.error=n)}(n):function se(n){Z.setTimeout(()=>{const{onUnhandledError:t}=Yl;if(!t)throw n;t(n)})}(n)}function kr(n,t){const{onStoppedNotification:e}=Yl;e&&Z.setTimeout(()=>e(n,t))}const Wt={closed:!0,next:ye,error:function es(n){throw n},complete:ye},ct="function"==typeof Symbol&&Symbol.observable||"@@observable";function _n(n){return n}let ki=(()=>{class n{constructor(e){e&&(this._subscribe=e)}lift(e){const i=new n;return i.source=this,i.operator=e,i}subscribe(e,i,r){const s=function et(n){return n&&n instanceof ft||function dr(n){return n&&Eo(n.next)&&Eo(n.error)&&Eo(n.complete)}(n)&&bm(n)}(e)?e:new cr(e,i,r);return At(()=>{const{operator:o,source:a}=this;s.add(o?o.call(s,a):a?this._subscribe(s):this._trySubscribe(s))}),s}_trySubscribe(e){try{return this._subscribe(e)}catch(i){e.error(i)}}forEach(e,i){return new(i=lt(i))((r,s)=>{const o=new cr({next:a=>{try{e(a)}catch(l){s(l),o.unsubscribe()}},error:s,complete:r});this.subscribe(o)})}_subscribe(e){var i;return null===(i=this.source)||void 0===i?void 0:i.subscribe(e)}[ct](){return this}pipe(...e){return function Zr(n){return 0===n.length?_n:1===n.length?n[0]:function(e){return n.reduce((i,r)=>r(i),e)}}(e)(this)}toPromise(e){return new(e=lt(e))((i,r)=>{let s;this.subscribe(o=>s=o,o=>r(o),()=>i(s))})}}return n.create=t=>new n(t),n})();function lt(n){var t;return null!==(t=n??Yl.Promise)&&void 0!==t?t:Promise}const vi=Xd(n=>function(){n(this),this.name="ObjectUnsubscribedError",this.message="object unsubscribed"});let Pt=(()=>{class n extends ki{constructor(){super(),this.closed=!1,this.currentObservers=null,this.observers=[],this.isStopped=!1,this.hasError=!1,this.thrownError=null}lift(e){const i=new ts(this,this);return i.operator=e,i}_throwIfClosed(){if(this.closed)throw new vi}next(e){At(()=>{if(this._throwIfClosed(),!this.isStopped){this.currentObservers||(this.currentObservers=Array.from(this.observers));for(const i of this.currentObservers)i.next(e)}})}error(e){At(()=>{if(this._throwIfClosed(),!this.isStopped){this.hasError=this.isStopped=!0,this.thrownError=e;const{observers:i}=this;for(;i.length;)i.shift().error(e)}})}complete(){At(()=>{if(this._throwIfClosed(),!this.isStopped){this.isStopped=!0;const{observers:e}=this;for(;e.length;)e.shift().complete()}})}unsubscribe(){this.isStopped=this.closed=!0,this.observers=this.currentObservers=null}get observed(){var e;return(null===(e=this.observers)||void 0===e?void 0:e.length)>0}_trySubscribe(e){return this._throwIfClosed(),super._trySubscribe(e)}_subscribe(e){return this._throwIfClosed(),this._checkFinalizedStatuses(e),this._innerSubscribe(e)}_innerSubscribe(e){const{hasError:i,isStopped:r,observers:s}=this;return i||r?Wl:(this.currentObservers=null,s.push(e),new As(()=>{this.currentObservers=null,uf(s,e)}))}_checkFinalizedStatuses(e){const{hasError:i,thrownError:r,isStopped:s}=this;i?e.error(r):s&&e.complete()}asObservable(){const e=new ki;return e.source=this,e}}return n.create=(t,e)=>new ts(t,e),n})();class ts extends Pt{constructor(t,e){super(),this.destination=t,this.source=e}next(t){var e,i;null===(i=null===(e=this.destination)||void 0===e?void 0:e.next)||void 0===i||i.call(e,t)}error(t){var e,i;null===(i=null===(e=this.destination)||void 0===e?void 0:e.error)||void 0===i||i.call(e,t)}complete(){var t,e;null===(e=null===(t=this.destination)||void 0===t?void 0:t.complete)||void 0===e||e.call(t)}_subscribe(t){var e,i;return null!==(i=null===(e=this.source)||void 0===e?void 0:e.subscribe(t))&&void 0!==i?i:Wl}}class _o extends Pt{constructor(t){super(),this._value=t}get value(){return this.getValue()}_subscribe(t){const e=super._subscribe(t);return!e.closed&&t.next(this._value),e}getValue(){const{hasError:t,thrownError:e,_value:i}=this;if(t)throw e;return this._throwIfClosed(),i}next(t){super.next(this._value=t)}}class Ls extends ft{constructor(t,e,i,r,s,o){super(t),this.onFinalize=s,this.shouldUnsubscribe=o,this._next=e?function(a){try{e(a)}catch(l){t.error(l)}}:super._next,this._error=r?function(a){try{r(a)}catch(l){t.error(l)}finally{this.unsubscribe()}}:super._error,this._complete=i?function(){try{i()}catch(a){t.error(a)}finally{this.unsubscribe()}}:super._complete}unsubscribe(){var t;if(!this.shouldUnsubscribe||this.shouldUnsubscribe()){const{closed:e}=this;super.unsubscribe(),!e&&(null===(t=this.onFinalize)||void 0===t||t.call(this))}}}function jr(n,t){return function Ur(n){return t=>{if(function cn(n){return Eo(n?.lift)}(t))return t.lift(function(e){try{return n(e,this)}catch(i){this.error(i)}});throw new TypeError("Unable to lift unknown Observable type")}}((e,i)=>{let r=0;e.subscribe(function Do(n,t,e,i,r){return new Ls(n,t,e,i,r)}(i,s=>{i.next(n.call(t,s,r++))}))})}class F extends Error{constructor(t,e){super(function ae(n,t){return`NG0${Math.abs(n)}${t?": "+t:""}`}(t,e)),this.code=t}}function Xe(n){for(let t in n)if(n[t]===Xe)return t;throw Error("Could not find renamed property on target object.")}function mt(n,t){for(const e in t)t.hasOwnProperty(e)&&!n.hasOwnProperty(e)&&(n[e]=t[e])}function dt(n){if("string"==typeof n)return n;if(Array.isArray(n))return"["+n.map(dt).join(", ")+"]";if(null==n)return""+n;if(n.overriddenName)return`${n.overriddenName}`;if(n.name)return`${n.name}`;const t=n.toString();if(null==t)return""+t;const e=t.indexOf("\n");return-1===e?t:t.substring(0,e)}function $t(n,t){return null==n||""===n?null===t?"":t:null==t||""===t?n:n+" "+t}const ur=Xe({__forward_ref__:Xe});function ir(n){return n.__forward_ref__=ir,n.toString=function(){return dt(this())},n}function vt(n){return function Dn(n){return"function"==typeof n&&n.hasOwnProperty(ur)&&n.__forward_ref__===ir}(n)?n():n}function Ql(n){return n&&!!n.\u0275providers}const Gl=Xe({\u0275cmp:Xe}),qd=Xe({\u0275dir:Xe}),pf=Xe({\u0275pipe:Xe}),Uo=Xe({\u0275fac:Xe}),jo=Xe({__NG_ELEMENT_ID__:Xe}),ff=Xe({__NG_ENV_ID__:Xe});function zi(n){return"function"==typeof n?n.name||n.toString():"object"==typeof n&&null!=n&&"function"==typeof n.type?n.type.name||n.type.toString():function Nt(n){return"string"==typeof n?n:null==n?"":String(n)}(n)}function Db(n,t){throw new F(-201,!1)}function ro(n,t){null==n&&function zt(n,t,e,i){throw new Error(`ASSERTION ERROR: ${n}`+(null==i?"":` [Expected=> ${e} ${i} ${t} <=Actual]`))}(t,n,null,"!=")}function Yi(n){return{token:n.token,providedIn:n.providedIn||null,factory:n.factory,value:void 0}}function gf(n){return{providers:n.providers||[],imports:n.imports||[]}}function wm(n){return PT(n,Em)||PT(n,zT)}function PT(n,t){return n.hasOwnProperty(t)?n[t]:null}function Cm(n){return n&&(n.hasOwnProperty(xb)||n.hasOwnProperty(E_))?n[xb]:null}const Em=Xe({\u0275prov:Xe}),xb=Xe({\u0275inj:Xe}),zT=Xe({ngInjectableDef:Xe}),E_=Xe({ngInjectorDef:Xe});var Di=function(n){return n[n.Default=0]="Default",n[n.Host=1]="Host",n[n.Self=2]="Self",n[n.SkipSelf=4]="SkipSelf",n[n.Optional=8]="Optional",n}(Di||{});let Tb;function no(n){const t=Tb;return Tb=n,t}function HT(n,t,e){const i=wm(n);return i&&"root"==i.providedIn?void 0===i.value?i.value=i.factory():i.value:e&Di.Optional?null:void 0!==t?t:void Db()}const rr=globalThis;class Ht{constructor(t,e){this._desc=t,this.ngMetadataName="InjectionToken",this.\u0275prov=void 0,"number"==typeof e?this.__NG_ELEMENT_ID__=e:void 0!==e&&(this.\u0275prov=Yi({token:this,providedIn:e.providedIn||"root",factory:e.factory}))}get multi(){return this}toString(){return`InjectionToken ${this._desc}`}}const vf={},kb="__NG_DI_FLAG__",Dm="ngTempTokenPath",T_=/\n/gm,FT="__source";let Zd;function Qh(n){const t=Zd;return Zd=n,t}function N_(n,t=Di.Default){if(void 0===Zd)throw new F(-203,!1);return null===Zd?HT(n,void 0,t):Zd.get(n,t&Di.Optional?null:void 0,t)}function Fi(n,t=Di.Default){return(function RT(){return Tb}()||N_)(vt(n),t)}function Ri(n,t=Di.Default){return Fi(n,xm(t))}function xm(n){return typeof n>"u"||"number"==typeof n?n:0|(n.optional&&8)|(n.host&&1)|(n.self&&2)|(n.skipSelf&&4)}function Pb(n){const t=[];for(let e=0;et){o=s-1;break}}}for(;ss?"":r[d+1].toLowerCase();const p=8&i?u:null;if(p&&-1!==UT(p,h,0)||2&i&&h!==u){if(ba(i))return!1;o=!0}}}}else{if(!o&&!ba(i)&&!ba(l))return!1;if(o&&ba(l))continue;o=!1,i=l|1&i}}return ba(i)||o}function ba(n){return 0==(1&n)}function B_(n,t,e,i){if(null===t)return-1;let r=0;if(i||!e){let s=!1;for(;r-1)for(e++;e0?'="'+a+'"':"")+"]"}else 8&i?r+="."+o:4&i&&(r+=" "+o);else""!==r&&!ba(o)&&(t+=XT(s,r),r=""),i=o,s=s||!ba(i);e++}return""!==r&&(t+=XT(s,r)),t}function Rb(n){return Xl(()=>{const t=$T(n),e={...t,decls:n.decls,vars:n.vars,template:n.template,consts:n.consts||null,ngContentSelectors:n.ngContentSelectors,onPush:n.changeDetection===Tm.OnPush,directiveDefs:null,pipeDefs:null,dependencies:t.standalone&&n.dependencies||null,getStandaloneInjector:null,signals:n.signals??!1,data:n.data||{},encapsulation:n.encapsulation||Ia.Emulated,styles:n.styles||Qi,_:null,schemas:n.schemas||null,tView:null,id:""};ZT(e);const i=n.dependencies;return e.directiveDefs=Lm(i,!1),e.pipeDefs=Lm(i,!0),e.id=function q_(n){let t=0;const e=[n.selectors,n.ngContentSelectors,n.hostVars,n.hostAttrs,n.consts,n.vars,n.decls,n.encapsulation,n.standalone,n.signals,n.exportAs,JSON.stringify(n.inputs),JSON.stringify(n.outputs),Object.getOwnPropertyNames(n.type.prototype),!!n.contentQueries,!!n.viewQuery].join("|");for(const r of e)t=Math.imul(31,t)+r.charCodeAt(0)<<0;return t+=2147483648,"c"+t}(e),e})}function Q_(n){return ci(n)||jn(n)}function G_(n){return null!==n}function Am(n){return Xl(()=>({type:n.type,bootstrap:n.bootstrap||Qi,declarations:n.declarations||Qi,imports:n.imports||Qi,exports:n.exports||Qi,transitiveCompileScopes:null,schemas:n.schemas||null,id:n.id||null}))}function qT(n,t){if(null==n)return tl;const e={};for(const i in n)if(n.hasOwnProperty(i)){const r=n[i];let s,o,a=Gh.None;Array.isArray(r)?(a=r[0],s=r[1],o=r[2]??s):(s=r,o=r),t?(e[s]=a!==Gh.None?[i,a]:i,t[s]=o):e[s]=i}return e}function nr(n){return Xl(()=>{const t=$T(n);return ZT(t),t})}function ci(n){return n[Gl]||null}function jn(n){return n[qd]||null}function gs(n){return n[pf]||null}function $T(n){const t={};return{type:n.type,providersResolver:null,factory:null,hostBindings:n.hostBindings||null,hostVars:n.hostVars||0,hostAttrs:n.hostAttrs||null,contentQueries:n.contentQueries||null,declaredInputs:t,inputTransforms:null,inputConfig:n.inputs||tl,exportAs:n.exportAs||null,standalone:!0===n.standalone,signals:!0===n.signals,selectors:n.selectors||Qi,viewQuery:n.viewQuery||null,features:n.features||null,setInput:null,findHostDirectiveDefs:null,hostDirectives:null,inputs:qT(n.inputs,t),outputs:qT(n.outputs),debugInfo:null}}function ZT(n){n.features?.forEach(t=>t(n))}function Lm(n,t){if(!n)return null;const e=t?gs:Q_;return()=>("function"==typeof n?n():n).map(i=>e(i)).filter(G_)}const Vr=0,Be=1,Ct=2,vn=3,Ma=4,Os=5,wa=6,Jd=7,Er=8,Xs=9,ql=10,Yt=11,Sf=12,JT=13,Kd=14,Jr=15,If=16,eu=17,il=18,bf=19,KT=20,Xh=21,Nm=22,Uc=23,Ut=25,Hb=1,rl=7,tu=9,mn=10;var Bb=function(n){return n[n.None=0]="None",n[n.HasTransplantedViews=2]="HasTransplantedViews",n}(Bb||{});function ks(n){return Array.isArray(n)&&"object"==typeof n[Hb]}function Ps(n){return Array.isArray(n)&&!0===n[Hb]}function Fb(n){return 0!=(4&n.flags)}function jc(n){return n.componentOffset>-1}function km(n){return 1==(1&n.flags)}function Ca(n){return!!n.template}function _b(n){return 0!=(512&n[Ct])}function Vc(n,t){return n.hasOwnProperty(Uo)?n[Uo]:null}class K_{constructor(t,e,i){this.previousValue=t,this.currentValue=e,this.firstChange=i}isFirstChange(){return this.firstChange}}function rA(n,t,e,i){null!==t?t.applyValueToInputSignal(t,i):n[e]=i}function nA(n){return n.type.prototype.ngOnChanges&&(n.setInput=tU),eU}function eU(){const n=oA(this),t=n?.current;if(t){const e=n.previous;if(e===tl)n.previous=t;else for(let i in t)e[i]=t[i];n.current=null,this.ngOnChanges(t)}}function tU(n,t,e,i,r){const s=this.declaredInputs[i],o=oA(n)||function iU(n,t){return n[sA]=t}(n,{previous:tl,current:null}),a=o.current||(o.current={}),l=o.previous,h=l[s];a[s]=new K_(h&&h.currentValue,e,l===tl),rA(n,t,r,e)}const sA="__ngSimpleChanges__";function oA(n){return n[sA]||null}const nl=function(n,t,e){};let hA=!1;function pr(n){for(;Array.isArray(n);)n=n[Vr];return n}function qs(n,t){return pr(t[n.index])}function Cf(n,t){return n.data[t]}function To(n,t){const e=t[n];return ks(e)?e:e[Vr]}function Yb(n){return 128==(128&n[Ct])}function sl(n,t){return null==t?null:n[t]}function cA(n){n[eu]=0}function lU(n){1024&n[Ct]||(n[Ct]|=1024,Yb(n)&&Ef(n))}function uA(n){return 9216&n[Ct]||n[Uc]?.dirty}function Qb(n){uA(n)?Ef(n):64&n[Ct]&&(function nU(){return hA}()?(n[Ct]|=1024,Ef(n)):n[ql].changeDetectionScheduler?.notify())}function Ef(n){n[ql].changeDetectionScheduler?.notify();let t=Wc(n);for(;null!==t&&!(8192&t[Ct])&&(t[Ct]|=8192,Yb(t));)t=Wc(t)}function Wc(n){const t=n[vn];return Ps(t)?t[vn]:t}const Rt={lFrame:MA(null),bindingsEnabled:!0,skipHydrationRootTNode:null};function fA(){return Rt.bindingsEnabled}function Se(){return Rt.lFrame.lView}function xi(){return Rt.lFrame.tView}function fr(){let n=gA();for(;null!==n&&64===n.type;)n=n.parent;return n}function gA(){return Rt.lFrame.currentTNode}function ol(n,t){const e=Rt.lFrame;e.currentTNode=n,e.isParent=t}function Xb(){return Rt.lFrame.isParent}function bU(n,t){const e=Rt.lFrame;e.bindingIndex=e.bindingRootIndex=n,$b(t)}function $b(n){Rt.lFrame.currentDirectiveIndex=n}function SA(){return Rt.lFrame.currentQueryIndex}function Jb(n){Rt.lFrame.currentQueryIndex=n}function wU(n){const t=n[Be];return 2===t.type?t.declTNode:1===t.type?n[Os]:null}function IA(n,t,e){if(e&Di.SkipSelf){let r=t,s=n;for(;!(r=r.parent,null!==r||e&Di.Host||(r=wU(s),null===r||(s=s[Kd],10&r.type))););if(null===r)return!1;t=r,n=s}const i=Rt.lFrame=bA();return i.currentTNode=t,i.lView=n,!0}function Kb(n){const t=bA(),e=n[Be];Rt.lFrame=t,t.currentTNode=e.firstChild,t.lView=n,t.tView=e,t.contextLView=n,t.bindingIndex=e.bindingStartIndex,t.inI18n=!1}function bA(){const n=Rt.lFrame,t=null===n?null:n.child;return null===t?MA(n):t}function MA(n){const t={currentTNode:null,isParent:!0,lView:null,tView:null,selectedIndex:-1,contextLView:null,elementDepthCount:0,currentNamespace:null,currentDirectiveIndex:-1,bindingRootIndex:-1,bindingIndex:-1,currentQueryIndex:0,parent:n,child:null,inI18n:!1};return null!==n&&(n.child=t),t}function wA(){const n=Rt.lFrame;return Rt.lFrame=n.parent,n.currentTNode=null,n.lView=null,n}const CA=wA;function e1(){const n=wA();n.isParent=!0,n.tView=null,n.selectedIndex=-1,n.contextLView=null,n.elementDepthCount=0,n.currentDirectiveIndex=-1,n.currentNamespace=null,n.bindingRootIndex=-1,n.bindingIndex=-1,n.currentQueryIndex=0}function zs(){return Rt.lFrame.selectedIndex}function Yc(n){Rt.lFrame.selectedIndex=n}let DA=!0;function Rm(){return DA}function qh(n){DA=n}function Hm(n,t){for(let e=t.directiveStart,i=t.directiveEnd;e=i)break}else t[l]<0&&(n[eu]+=65536),(a>14>16&&(3&n[Ct])===t&&(n[Ct]+=16384,TA(a,s)):TA(a,s)}const nu=-1;class xf{constructor(t,e,i){this.factory=t,this.resolving=!1,this.canSeeViewProviders=e,this.injectImpl=i}}function r1(n){return n!==nu}function Tf(n){return 32767&n}function Af(n,t){let e=function zU(n){return n>>16}(n),i=t;for(;e>0;)i=i[Kd],e--;return i}let n1=!0;function _m(n){const t=n1;return n1=n,t}const AA=255,LA=5;let RU=0;const ll={};function Um(n,t){const e=NA(n,t);if(-1!==e)return e;const i=t[Be];i.firstCreatePass&&(n.injectorIndex=t.length,s1(i.data,n),s1(t,null),s1(i.blueprint,null));const r=jm(n,t),s=n.injectorIndex;if(r1(r)){const o=Tf(r),a=Af(r,t),l=a[Be].data;for(let h=0;h<8;h++)t[s+h]=a[o+h]|l[o+h]}return t[s+8]=r,s}function s1(n,t){n.push(0,0,0,0,0,0,0,0,t)}function NA(n,t){return-1===n.injectorIndex||n.parent&&n.parent.injectorIndex===n.injectorIndex||null===t[n.injectorIndex+8]?-1:n.injectorIndex}function jm(n,t){if(n.parent&&-1!==n.parent.injectorIndex)return n.parent.injectorIndex;let e=0,i=null,r=t;for(;null!==r;){if(i=BA(r),null===i)return nu;if(e++,r=r[Kd],-1!==i.injectorIndex)return i.injectorIndex|e<<16}return nu}function o1(n,t,e){!function HU(n,t,e){let i;"string"==typeof e?i=e.charCodeAt(0)||0:e.hasOwnProperty(jo)&&(i=e[jo]),null==i&&(i=e[jo]=RU++);const r=i&AA;t.data[n+(r>>LA)]|=1<=0?t&AA:UU:t}(e);if("function"==typeof s){if(!IA(t,n,i))return i&Di.Host?OA(r,0,i):kA(t,e,i,r);try{let o;if(o=s(i),null!=o||i&Di.Optional)return o;Db()}finally{CA()}}else if("number"==typeof s){let o=null,a=NA(n,t),l=nu,h=i&Di.Host?t[Jr][Os]:null;for((-1===a||i&Di.SkipSelf)&&(l=-1===a?jm(n,t):t[a+8],l!==nu&&HA(i,!1)?(o=t[Be],a=Tf(l),t=Af(l,t)):a=-1);-1!==a;){const c=t[Be];if(RA(s,a,c.data)){const d=FU(a,t,e,o,i,h);if(d!==ll)return d}l=t[a+8],l!==nu&&HA(i,t[Be].data[a+8]===h)&&RA(s,a,t)?(o=c,a=Tf(l),t=Af(l,t)):a=-1}}return r}function FU(n,t,e,i,r,s){const o=t[Be],a=o.data[n+8],c=Vm(a,o,e,null==i?jc(a)&&n1:i!=o&&0!=(3&a.type),r&Di.Host&&s===a);return null!==c?Qc(t,o,c,a):ll}function Vm(n,t,e,i,r){const s=n.providerIndexes,o=t.data,a=1048575&s,l=n.directiveStart,c=s>>20,u=r?a+c:n.directiveEnd;for(let p=i?a:a+c;p=l&&f.type===e)return p}if(r){const p=o[l];if(p&&Ca(p)&&p.type===e)return l}return null}function Qc(n,t,e,i){let r=n[e];const s=t.data;if(function NU(n){return n instanceof xf}(r)){const o=r;o.resolving&&function Vo(n,t){const e=t?`. Dependency path: ${t.join(" > ")} > ${n}`:"";throw new F(-200,`Circular dependency in DI detected for ${n}${e}`)}(zi(s[e]));const a=_m(o.canSeeViewProviders);o.resolving=!0;const h=o.injectImpl?no(o.injectImpl):null;IA(n,i,Di.Default);try{r=n[e]=o.factory(void 0,s,n,i),t.firstCreatePass&&e>=i.directiveStart&&function AU(n,t,e){const{ngOnChanges:i,ngOnInit:r,ngDoCheck:s}=t.type.prototype;if(i){const o=nA(t);(e.preOrderHooks??=[]).push(n,o),(e.preOrderCheckHooks??=[]).push(n,o)}r&&(e.preOrderHooks??=[]).push(0-n,r),s&&((e.preOrderHooks??=[]).push(n,s),(e.preOrderCheckHooks??=[]).push(n,s))}(e,s[e],t)}finally{null!==h&&no(h),_m(a),o.resolving=!1,CA()}}return r}function RA(n,t,e){return!!(e[t+(n>>LA)]&1<Array.isArray(e)?uu(e,t):t(e))}function _A(n,t,e){t>=n.length?n.push(e):n.splice(t,0,e)}function Wm(n,t){return t>=n.length-1?n.pop():n.splice(t,1)[0]}const gu=new Ht(""),QA=new Ht("",-1),v1=new Ht("");class Xm{get(t,e=vf){if(e===vf){const i=new Error(`NullInjectorError: No provider for ${dt(t)}!`);throw i.name="NullInjectorError",i}return e}}function dj(...n){return{\u0275providers:GA(0,n),\u0275fromNgModule:!0}}function GA(n,...t){const e=[],i=new Set;let r;const s=o=>{e.push(o)};return uu(t,o=>{const a=o;qm(a,s,[],i)&&(r||=[],r.push(a))}),void 0!==r&&XA(r,s),e}function XA(n,t){for(let e=0;e{t(s,i)})}}function qm(n,t,e,i){if(!(n=vt(n)))return!1;let r=null,s=Cm(n);const o=!s&&ci(n);if(s||o){if(o&&!o.standalone)return!1;r=n}else{const l=n.ngModule;if(s=Cm(l),!s)return!1;r=l}const a=i.has(r);if(o){if(a)return!1;if(i.add(r),o.dependencies){const l="function"==typeof o.dependencies?o.dependencies():o.dependencies;for(const h of l)qm(h,t,e,i)}}else{if(!s)return!1;{if(null!=s.imports&&!a){let h;i.add(r);try{uu(s.imports,c=>{qm(c,t,e,i)&&(h||=[],h.push(c))})}finally{}void 0!==h&&XA(h,t)}if(!a){const h=Vc(r)||(()=>new r);t({provide:r,useFactory:h,deps:Qi},r),t({provide:v1,useValue:r,multi:!0},r),t({provide:gu,useValue:()=>Fi(r),multi:!0},r)}const l=s.providers;if(null!=l&&!a){const h=n;y1(l,c=>{t(c,h)})}}}return r!==n&&void 0!==n.providers}function y1(n,t){for(let e of n)Ql(e)&&(e=e.\u0275providers),Array.isArray(e)?y1(e,t):t(e)}const uj=Xe({provide:String,useValue:Xe});function S1(n){return null!==n&&"object"==typeof n&&uj in n}function Gc(n){return"function"==typeof n}const I1=new Ht(""),$m={},fj={};let b1;function Zm(){return void 0===b1&&(b1=new Xm),b1}class Jl{}class vu extends Jl{get destroyed(){return this._destroyed}constructor(t,e,i,r){super(),this.parent=e,this.source=i,this.scopes=r,this.records=new Map,this._ngOnDestroyHooks=new Set,this._onDestroyHooks=[],this._destroyed=!1,w1(t,o=>this.processProvider(o)),this.records.set(QA,mu(void 0,this)),r.has("environment")&&this.records.set(Jl,mu(void 0,this));const s=this.records.get(I1);null!=s&&"string"==typeof s.value&&this.scopes.add(s.value),this.injectorDefTypes=new Set(this.get(v1,Qi,Di.Self))}destroy(){this.assertNotDestroyed(),this._destroyed=!0;try{for(const e of this._ngOnDestroyHooks)e.ngOnDestroy();const t=this._onDestroyHooks;this._onDestroyHooks=[];for(const e of t)e()}finally{this.records.clear(),this._ngOnDestroyHooks.clear(),this.injectorDefTypes.clear()}}onDestroy(t){return this.assertNotDestroyed(),this._onDestroyHooks.push(t),()=>this.removeOnDestroy(t)}runInContext(t){this.assertNotDestroyed();const e=Qh(this),i=no(void 0);try{return t()}finally{Qh(e),no(i)}}get(t,e=vf,i=Di.Default){if(this.assertNotDestroyed(),t.hasOwnProperty(ff))return t[ff](this);i=xm(i);const s=Qh(this),o=no(void 0);try{if(!(i&Di.SkipSelf)){let l=this.records.get(t);if(void 0===l){const h=function Sj(n){return"function"==typeof n||"object"==typeof n&&n instanceof Ht}(t)&&wm(t);l=h&&this.injectableDefInScope(h)?mu(M1(t),$m):null,this.records.set(t,l)}if(null!=l)return this.hydrate(t,l)}return(i&Di.Self?Zm():this.parent).get(t,e=i&Di.Optional&&e===vf?null:e)}catch(a){if("NullInjectorError"===a.name){if((a[Dm]=a[Dm]||[]).unshift(dt(t)),s)throw a;return function k_(n,t,e,i){const r=n[Dm];throw t[FT]&&r.unshift(t[FT]),n.message=function P_(n,t,e,i=null){n=n&&"\n"===n.charAt(0)&&"\u0275"==n.charAt(1)?n.slice(2):n;let r=dt(t);if(Array.isArray(t))r=t.map(dt).join(" -> ");else if("object"==typeof t){let s=[];for(let o in t)if(t.hasOwnProperty(o)){let a=t[o];s.push(o+":"+("string"==typeof a?JSON.stringify(a):dt(a)))}r=`{${s.join(", ")}}`}return`${e}${i?"("+i+")":""}[${r}]: ${n.replace(T_,"\n ")}`}("\n"+n.message,r,e,i),n.ngTokenPath=r,n[Dm]=null,n}(a,t,"R3InjectorError",this.source)}throw a}finally{no(o),Qh(s)}}resolveInjectorInitializers(){const t=Qh(this),e=no(void 0);try{const r=this.get(gu,Qi,Di.Self);for(const s of r)s()}finally{Qh(t),no(e)}}toString(){const t=[],e=this.records;for(const i of e.keys())t.push(dt(i));return`R3Injector[${t.join(", ")}]`}assertNotDestroyed(){if(this._destroyed)throw new F(205,!1)}processProvider(t){let e=Gc(t=vt(t))?t:vt(t&&t.provide);const i=function vj(n){return S1(n)?mu(void 0,n.useValue):mu(ZA(n),$m)}(t);if(!Gc(t)&&!0===t.multi){let r=this.records.get(e);r||(r=mu(void 0,$m,!0),r.factory=()=>Pb(r.multi),this.records.set(e,r)),e=t,r.multi.push(t)}this.records.set(e,i)}hydrate(t,e){return e.value===$m&&(e.value=fj,e.value=e.factory()),"object"==typeof e.value&&e.value&&function yj(n){return null!==n&&"object"==typeof n&&"function"==typeof n.ngOnDestroy}(e.value)&&this._ngOnDestroyHooks.add(e.value),e.value}injectableDefInScope(t){if(!t.providedIn)return!1;const e=vt(t.providedIn);return"string"==typeof e?"any"===e||this.scopes.has(e):this.injectorDefTypes.has(e)}removeOnDestroy(t){const e=this._onDestroyHooks.indexOf(t);-1!==e&&this._onDestroyHooks.splice(e,1)}}function M1(n){const t=wm(n),e=null!==t?t.factory:Vc(n);if(null!==e)return e;if(n instanceof Ht)throw new F(204,!1);if(n instanceof Function)return function gj(n){if(n.length>0)throw new F(204,!1);const e=function C_(n){return n&&(n[Em]||n[zT])||null}(n);return null!==e?()=>e.factory(n):()=>new n}(n);throw new F(204,!1)}function ZA(n,t,e){let i;if(Gc(n)){const r=vt(n);return Vc(r)||M1(r)}if(S1(n))i=()=>vt(n.useValue);else if(function $A(n){return!(!n||!n.useFactory)}(n))i=()=>n.useFactory(...Pb(n.deps||[]));else if(function qA(n){return!(!n||!n.useExisting)}(n))i=()=>Fi(vt(n.useExisting));else{const r=vt(n&&(n.useClass||n.provide));if(!function mj(n){return!!n.deps}(n))return Vc(r)||M1(r);i=()=>new r(...Pb(n.deps))}return i}function mu(n,t,e=!1){return{factory:n,value:t,multi:e?[]:void 0}}function w1(n,t){for(const e of n)Array.isArray(e)?w1(e,t):e&&Ql(e)?w1(e.\u0275providers,t):t(e)}function tL(n,t=null,e=null,i){const r=function iL(n,t=null,e=null,i,r=new Set){const s=[e||Qi,dj(n)];return i=i||("object"==typeof n?void 0:dt(n)),new vu(s,t||Zm(),i||null,r)}(n,t,e,i);return r.resolveInjectorInitializers(),r}let D1,Wo=(()=>{class n{static{this.THROW_IF_NOT_FOUND=vf}static{this.NULL=new Xm}static create(e,i){if(Array.isArray(e))return tL({name:""},i,e,"");{const r=e.name??"";return tL({name:r},e.parent,e.providers,r)}}static{this.\u0275prov=Yi({token:n,providedIn:"any",factory:()=>Fi(QA)})}static{this.__NG_ELEMENT_ID__=-1}}return n})();const x1=new Ht("",{providedIn:"root",factory:()=>Tj}),Tj="ng",nL=new Ht(""),yu=new Ht("",{providedIn:"platform",factory:()=>"unknown"}),sL=new Ht("",{providedIn:"root",factory:()=>function $h(){if(void 0!==D1)return D1;if(typeof document<"u")return document;throw new F(210,!1)}().body?.querySelector("[ngCspNonce]")?.getAttribute("ngCspNonce")||null});function iy(n){return 128==(128&n.flags)}var Kh=function(n){return n[n.Important=1]="Important",n[n.DashCase=2]="DashCase",n}(Kh||{});const O1=new Map;let Uj=0;const P1="__ngContext__";function Rs(n,t){ks(t)?(n[P1]=t[bf],function Vj(n){O1.set(n[bf],n)}(t)):n[P1]=t}let z1;function R1(n,t){return z1(n,t)}function Iu(n,t,e,i,r){if(null!=i){let s,o=!1;Ps(i)?s=i:ks(i)&&(o=!0,i=i[Vr]);const a=pr(i);0===n&&null!==e?null==r?xL(t,e,a):qc(t,e,a,r||null,!0):1===n&&null!==e?qc(t,e,a,r||null,!0):2===n?function hy(n,t,e){const i=ay(n,t);i&&function s6(n,t,e,i){n.removeChild(t,e,i)}(n,i,t,e)}(t,a,o):3===n&&t.destroyNode(a),null!=s&&function l6(n,t,e,i,r){const s=e[rl];s!==pr(e)&&Iu(t,n,i,s,r);for(let a=mn;a0&&(n[e-1][Ma]=i[Ma]);const s=Wm(n,mn+t);!function Jj(n,t){CL(n,t),t[Vr]=null,t[Os]=null}(i[Be],i);const o=s[il];null!==o&&o.detachView(s[Be]),i[vn]=null,i[Ma]=null,i[Ct]&=-129}return i}function oy(n,t){if(!(256&t[Ct])){const e=t[Yt];e.destroyNode&&cy(n,t,e,3,null,null),function e6(n){let t=n[Sf];if(!t)return B1(n[Be],n);for(;t;){let e=null;if(ks(t))e=t[Sf];else{const i=t[mn];i&&(e=i)}if(!e){for(;t&&!t[Ma]&&t!==n;)ks(t)&&B1(t[Be],t),t=t[vn];null===t&&(t=n),ks(t)&&B1(t[Be],t),e=t&&t[Ma]}t=e}}(t)}}function B1(n,t){if(!(256&t[Ct])){t[Ct]&=-129,t[Ct]|=256,t[Uc]&&function Yd(n){if(Vl(n),Vh(n))for(let t=0;t=0?i[o]():i[-o].unsubscribe(),s+=2}else e[s].call(i[e[s+1]]);null!==i&&(t[Jd]=null);const r=t[Xh];if(null!==r){t[Xh]=null;for(let s=0;s-1){const{encapsulation:s}=n.data[i.directiveStart+r];if(s===Ia.None||s===Ia.Emulated)return null}return qs(i,e)}}(n,t.parent,e)}function qc(n,t,e,i,r){n.insertBefore(t,e,i,r)}function xL(n,t,e){n.appendChild(t,e)}function TL(n,t,e,i,r){null!==i?qc(n,t,e,i,r):xL(n,t,e)}function ay(n,t){return n.parentNode(t)}let _1,NL=function LL(n,t,e){return 40&n.type?qs(n,e):null};function ly(n,t,e,i){const r=F1(n,i,t),s=t[Yt],a=function AL(n,t,e){return NL(n,t,e)}(i.parent||t[Os],i,t);if(null!=r)if(Array.isArray(e))for(let l=0;lnull;function iM(n,t,e=!1){return ZL(n,t,e)}class Y6{}class iN{}class G6{resolveComponentFactory(t){throw function Q6(n){const t=Error(`No component factory found for ${dt(n)}.`);return t.ngComponent=n,t}(t)}}let Sy=(()=>{class n{static{this.NULL=new G6}}return n})();function X6(){return Du(fr(),Se())}function Du(n,t){return new $c(qs(n,t))}let $c=(()=>{class n{constructor(e){this.nativeElement=e}static{this.__NG_ELEMENT_ID__=X6}}return n})();function q6(n){return n instanceof $c?n.nativeElement:n}class nN{}let oM=(()=>{class n{constructor(){this.destroyNode=null}static{this.__NG_ELEMENT_ID__=()=>function $6(){const n=Se(),e=To(fr().index,n);return(ks(e)?e:n)[Yt]}()}}return n})(),Z6=(()=>{class n{static{this.\u0275prov=Yi({token:n,providedIn:"root",factory:()=>null})}}return n})();const aM={};function Wf(n,t,e,i,r=!1){for(;null!==e;){const s=t[e.index];null!==s&&i.push(pr(s)),Ps(s)&&uN(s,i);const o=e.type;if(8&o)Wf(n,t,e.child,i);else if(32&o){const a=R1(e,t);let l;for(;l=a();)i.push(l)}else if(16&o){const a=kL(t,e);if(Array.isArray(a))i.push(...a);else{const l=Wc(t[Jr]);Wf(l[Be],l,a,i,!0)}}e=r?e.projectionNext:e.next}return i}function uN(n,t){for(let e=mn;e!1,producerRecomputeValue:()=>{},consumerMarkedDirty:()=>{},consumerOnSignalRead:()=>{},consumerIsAlwaysLive:!0,consumerMarkedDirty:n=>{Ef(n.lView)},consumerOnSignalRead(){this.lView[Uc]=this}};function fN(n){return vN(n[Sf])}function gN(n){return vN(n[Ma])}function vN(n){for(;null!==n&&!Ps(n);)n=n[Ma];return n}function cM(n){return n.ngOriginalError}class eh{constructor(){this._console=console}handleError(t){const e=this._findOriginalError(t);this._console.error("ERROR",t),e&&this._console.error("ORIGINAL ERROR",e)}_findOriginalError(t){let e=t&&cM(t);for(;e&&cM(e);)e=cM(e);return e||null}}const yN=new Ht("",{providedIn:"root",factory:()=>Ri(eh).handleError.bind(void 0)}),IN=new Ht("",{providedIn:"root",factory:()=>!1}),Qt={};function EN(n,t,e,i){if(!i)if(3==(3&t[Ct])){const s=n.preOrderCheckHooks;null!==s&&Bm(t,s,e)}else{const s=n.preOrderHooks;null!==s&&Fm(t,s,0,e)}Yc(e)}function Ot(n,t=Di.Default){const e=Se();return null===e?Fi(n,t):PA(fr(),e,vt(n),t)}function DN(n,t,e,i,r,s){const o=Wi(null);try{let a=null;r&Gh.SignalBased&&(a=t[i][Ts]),null!==a&&void 0!==a.transformFn&&(s=a.transformFn(s)),r&Gh.HasDecoratorInputTransform&&(s=n.inputTransforms[i].call(t,s)),null!==n.setInput?n.setInput(t,a,s,e,i):rA(t,a,i,s)}finally{Wi(o)}}function wy(n,t,e,i,r,s,o,a,l,h,c){const d=t.blueprint.slice();return d[Vr]=r,d[Ct]=204|i,(null!==h||n&&2048&n[Ct])&&(d[Ct]|=2048),cA(d),d[vn]=d[Kd]=n,d[Er]=e,d[ql]=o||n&&n[ql],d[Yt]=a||n&&n[Yt],d[Xs]=l||n&&n[Xs]||null,d[Os]=s,d[bf]=function jj(){return Uj++}(),d[wa]=c,d[KT]=h,d[Jr]=2==t.type?n[Jr]:d,d}function xu(n,t,e,i,r){let s=n.data[t];if(null===s)s=function dM(n,t,e,i,r){const s=gA(),o=Xb(),l=n.data[t]=function TV(n,t,e,i,r,s){let o=t?t.injectorIndex:-1,a=0;return function ru(){return null!==Rt.skipHydrationRootTNode}()&&(a|=128),{type:e,index:i,insertBeforeIndex:null,injectorIndex:o,directiveStart:-1,directiveEnd:-1,directiveStylingLast:-1,componentOffset:-1,propertyBindings:null,flags:a,providerIndexes:0,value:r,attrs:s,mergedAttrs:null,localNames:null,initialInputs:void 0,inputs:null,outputs:null,tView:null,next:null,prev:null,projectionNext:null,child:null,parent:t,projection:null,styles:null,stylesWithoutHost:null,residualStyles:void 0,classes:null,classesWithoutHost:null,residualClasses:void 0,classBindings:0,styleBindings:0}}(0,o?s:s&&s.parent,e,t,i,r);return null===n.firstChild&&(n.firstChild=l),null!==s&&(o?null==s.child&&null!==l.parent&&(s.child=l):null===s.next&&(s.next=l,l.prev=s)),l}(n,t,e,i,r),function IU(){return Rt.lFrame.inI18n}()&&(s.flags|=32);else if(64&s.type){s.type=e,s.value=i,s.attrs=r;const o=function Df(){const n=Rt.lFrame,t=n.currentTNode;return n.isParent?t:t.parent}();s.injectorIndex=null===o?-1:o.injectorIndex}return ol(s,!0),s}function Yf(n,t,e,i){if(0===e)return-1;const r=t.length;for(let s=0;sUt&&EN(n,t,Ut,!1),nl(o?2:0,r),e(i,r)}finally{Yc(s),nl(o?3:1,r)}}function uM(n,t,e){if(Fb(t)){const i=Wi(null);try{const s=t.directiveEnd;for(let o=t.directiveStart;onull;function LN(n,t,e,i,r){for(let s in t){if(!t.hasOwnProperty(s))continue;const o=t[s];if(void 0===o)continue;i??={};let a,l=Gh.None;Array.isArray(o)?(a=o[0],l=o[1]):a=o;let h=s;if(null!==r){if(!r.hasOwnProperty(s))continue;h=r[s]}0===n?NN(i,e,h,a,l):NN(i,e,h,a)}return i}function NN(n,t,e,i,r){let s;n.hasOwnProperty(e)?(s=n[e]).push(t,i):s=n[e]=[t,i],void 0!==r&&s.push(r)}function ON(n,t,e,i,r,s){for(let h=0;h0;){const e=n[--t];if("number"==typeof e&&e<0)return e}return 0})(o)!=a&&o.push(a),o.push(e,i,s)}}(n,t,i,Yf(n,e,r.hostVars,Qt),r)}function VV(n,t,e,i,r,s){const o=s[t];if(null!==o)for(let a=0;an.nextProducerIndex;)n.producerNode.pop(),n.producerLastReadVersion.pop(),n.producerIndexOfThis.pop()}}(a,o),function dV(n){n.lView[Uc]!==n&&(n.lView=null,pN.push(n))}(a)),e1()}}function FN(n,t){for(let e=fN(n);null!==e;e=gN(e))for(let i=mn;i-1&&(Rf(t,i),Wm(e,i))}this._attachedToViewContainer=!1}oy(this._lView[Be],this._lView)}onDestroy(t){!function zm(n,t){if(256==(256&n[Ct]))throw new F(911,!1);null===n[Xh]&&(n[Xh]=[]),n[Xh].push(t)}(this._lView,t)}markForCheck(){Qf(this._cdRefInjectingView||this._lView)}detach(){this._lView[Ct]&=-129}reattach(){Qb(this._lView),this._lView[Ct]|=128}detectChanges(){this._lView[Ct]|=1024,function bM(n,t=!0){const e=n[ql],i=e.rendererFactory;i.begin?.();try{!function QV(n){MM(n,0);let t=0;for(;uA(n);){if(100===t)throw new F(103,!1);t++,MM(n,1)}}(n)}catch(s){throw t&&Ey(n,s),s}finally{i.end?.(),e.inlineEffectRunner?.flush()}}(this._lView,this.notifyErrorHandler)}checkNoChanges(){}attachToViewContainerRef(){if(this._appRef)throw new F(902,!1);this._attachedToViewContainer=!0}detachFromAppRef(){this._appRef=null,CL(this._lView[Be],this._lView)}attachToAppRef(t){if(this._attachedToViewContainer)throw new F(902,!1);this._appRef=t,Qb(this._lView)}}const VN=new Set;function CM(n){return t=>{setTimeout(n,void 0,t)}}const Yo=class a7 extends Pt{constructor(t=!1){super(),this.__isAsync=t}emit(t){super.next(t)}subscribe(t,e,i){let r=t,s=e||(()=>null),o=i;if(t&&"object"==typeof t){const l=t;r=l.next?.bind(l),s=l.error?.bind(l),o=l.complete?.bind(l)}this.__isAsync&&(s=CM(s),r&&(r=CM(r)),o&&(o=CM(o)));const a=super.subscribe({next:r,error:s,complete:o});return t instanceof As&&t.add(a),a}};function WN(...n){}class zr{constructor({enableLongStackTrace:t=!1,shouldCoalesceEventChangeDetection:e=!1,shouldCoalesceRunChangeDetection:i=!1}){if(this.hasPendingMacrotasks=!1,this.hasPendingMicrotasks=!1,this.isStable=!0,this.onUnstable=new Yo(!1),this.onMicrotaskEmpty=new Yo(!1),this.onStable=new Yo(!1),this.onError=new Yo(!1),typeof Zone>"u")throw new F(908,!1);Zone.assertZonePatched();const r=this;r._nesting=0,r._outer=r._inner=Zone.current,Zone.TaskTrackingZoneSpec&&(r._inner=r._inner.fork(new Zone.TaskTrackingZoneSpec)),t&&Zone.longStackTraceZoneSpec&&(r._inner=r._inner.fork(Zone.longStackTraceZoneSpec)),r.shouldCoalesceEventChangeDetection=!i&&e,r.shouldCoalesceRunChangeDetection=i,r.lastRequestAnimationFrameId=-1,r.nativeRequestAnimationFrame=function l7(){const n="function"==typeof rr.requestAnimationFrame;let t=rr[n?"requestAnimationFrame":"setTimeout"],e=rr[n?"cancelAnimationFrame":"clearTimeout"];if(typeof Zone<"u"&&t&&e){const i=t[Zone.__symbol__("OriginalDelegate")];i&&(t=i);const r=e[Zone.__symbol__("OriginalDelegate")];r&&(e=r)}return{nativeRequestAnimationFrame:t,nativeCancelAnimationFrame:e}}().nativeRequestAnimationFrame,function d7(n){const t=()=>{!function c7(n){n.isCheckStableRunning||-1!==n.lastRequestAnimationFrameId||(n.lastRequestAnimationFrameId=n.nativeRequestAnimationFrame.call(rr,()=>{n.fakeTopEventTask||(n.fakeTopEventTask=Zone.root.scheduleEventTask("fakeTopEventTask",()=>{n.lastRequestAnimationFrameId=-1,DM(n),n.isCheckStableRunning=!0,EM(n),n.isCheckStableRunning=!1},void 0,()=>{},()=>{})),n.fakeTopEventTask.invoke()}),DM(n))}(n)};n._inner=n._inner.fork({name:"angular",properties:{isAngularZone:!0},onInvokeTask:(e,i,r,s,o,a)=>{if(function u7(n){return!(!Array.isArray(n)||1!==n.length)&&!0===n[0].data?.__ignore_ng_zone__}(a))return e.invokeTask(r,s,o,a);try{return YN(n),e.invokeTask(r,s,o,a)}finally{(n.shouldCoalesceEventChangeDetection&&"eventTask"===s.type||n.shouldCoalesceRunChangeDetection)&&t(),QN(n)}},onInvoke:(e,i,r,s,o,a,l)=>{try{return YN(n),e.invoke(r,s,o,a,l)}finally{n.shouldCoalesceRunChangeDetection&&t(),QN(n)}},onHasTask:(e,i,r,s)=>{e.hasTask(r,s),i===r&&("microTask"==s.change?(n._hasPendingMicrotasks=s.microTask,DM(n),EM(n)):"macroTask"==s.change&&(n.hasPendingMacrotasks=s.macroTask))},onHandleError:(e,i,r,s)=>(e.handleError(r,s),n.runOutsideAngular(()=>n.onError.emit(s)),!1)})}(r)}static isInAngularZone(){return typeof Zone<"u"&&!0===Zone.current.get("isAngularZone")}static assertInAngularZone(){if(!zr.isInAngularZone())throw new F(909,!1)}static assertNotInAngularZone(){if(zr.isInAngularZone())throw new F(909,!1)}run(t,e,i){return this._inner.run(t,e,i)}runTask(t,e,i,r){const s=this._inner,o=s.scheduleEventTask("NgZoneEvent: "+r,t,h7,WN,WN);try{return s.runTask(o,e,i)}finally{s.cancelTask(o)}}runGuarded(t,e,i){return this._inner.runGuarded(t,e,i)}runOutsideAngular(t){return this._outer.run(t)}}const h7={};function EM(n){if(0==n._nesting&&!n.hasPendingMicrotasks&&!n.isStable)try{n._nesting++,n.onMicrotaskEmpty.emit(null)}finally{if(n._nesting--,!n.hasPendingMicrotasks)try{n.runOutsideAngular(()=>n.onStable.emit(null))}finally{n.isStable=!0}}}function DM(n){n.hasPendingMicrotasks=!!(n._hasPendingMicrotasks||(n.shouldCoalesceEventChangeDetection||n.shouldCoalesceRunChangeDetection)&&-1!==n.lastRequestAnimationFrameId)}function YN(n){n._nesting++,n.isStable&&(n.isStable=!1,n.onUnstable.emit(null))}function QN(n){n._nesting--,EM(n)}let Xf=(()=>{class n{constructor(){this.handler=null,this.internalCallbacks=[]}execute(){const e=[...this.internalCallbacks];this.internalCallbacks.length=0;for(const r of e)r();return!!this.handler?.execute()||e.length>0}ngOnDestroy(){this.handler?.destroy(),this.handler=null,this.internalCallbacks.length=0}static{this.\u0275prov=Yi({token:n,providedIn:"root",factory:()=>new n})}}return n})();function v7(n,t){const e=To(t,n),i=e[Be];!function m7(n,t){for(let e=t.length;e0&&RL(n,e,s.join(" "))}}(u,w,f,i),void 0!==e&&function x7(n,t,e){const i=n.projection=[];for(let r=0;r=0;i--){const r=n[i];r.hostVars=t+=r.hostVars,r.hostAttrs=yf(r.hostAttrs,e=yf(e,r.hostAttrs))}}(i)}function A7(n,t){for(const e in t.inputs){if(!t.inputs.hasOwnProperty(e)||n.inputs.hasOwnProperty(e))continue;const i=t.inputs[e];if(void 0!==i&&(n.inputs[e]=i,n.declaredInputs[e]=t.declaredInputs[e],null!==t.inputTransforms)){const r=Array.isArray(i)?i[0]:i;if(!t.inputTransforms.hasOwnProperty(r))continue;n.inputTransforms??={},n.inputTransforms[r]=t.inputTransforms[r]}}}function xy(n){return n===tl?{}:n===Qi?[]:n}function N7(n,t){const e=n.viewQuery;n.viewQuery=e?(i,r)=>{t(i,r),e(i,r)}:t}function O7(n,t){const e=n.contentQueries;n.contentQueries=e?(i,r,s)=>{t(i,r,s),e(i,r,s)}:t}function k7(n,t){const e=n.hostBindings;n.hostBindings=e?(i,r)=>{t(i,r),e(i,r)}:t}function Au(n,t){return!t||null===t.firstChild||iy(n)}function tg(n,t,e,i=!0){const r=t[Be];if(function t6(n,t,e,i){const r=mn+i,s=e.length;i>0&&(e[r-1][Ma]=t),i{class n{static{this.__NG_ELEMENT_ID__=a9}}return n})();function a9(){return pO(fr(),Se())}const l9=xn,dO=class extends l9{constructor(t,e,i){super(),this._lContainer=t,this._hostTNode=e,this._hostLView=i}get element(){return Du(this._hostTNode,this._hostLView)}get injector(){return new Vn(this._hostTNode,this._hostLView)}get parentInjector(){const t=jm(this._hostTNode,this._hostLView);if(r1(t)){const e=Af(t,this._hostLView),i=Tf(t);return new Vn(e[Be].data[i+8],e)}return new Vn(null,this._hostLView)}clear(){for(;this.length>0;)this.remove(this.length-1)}get(t){const e=uO(this._lContainer);return null!==e&&e[t]||null}get length(){return this._lContainer.length-mn}createEmbeddedView(t,e,i){let r,s;"number"==typeof i?r=i:null!=i&&(r=i.index,s=i.injector);const a=t.createEmbeddedViewImpl(e||{},s,null);return this.insertImpl(a,r,Au(this._hostTNode,null)),a}createComponent(t,e,i,r,s){const o=t&&!function Lf(n){return"function"==typeof n}(t);let a;if(o)a=e;else{const f=e||{};a=f.index,i=f.injector,r=f.projectableNodes,s=f.environmentInjector||f.ngModuleRef}const l=o?t:new qf(ci(t)),h=i||this.parentInjector;if(!s&&null==l.ngModule){const g=(o?h:this.parentInjector).get(Jl,null);g&&(s=g)}ci(l.componentType??{});const p=l.create(h,r,null,s);return this.insertImpl(p.hostView,a,Au(this._hostTNode,null)),p}insert(t,e){return this.insertImpl(t,e,!0)}insertImpl(t,e,i){const r=t._lView;if(function aU(n){return Ps(n[vn])}(r)){const a=this.indexOf(t);if(-1!==a)this.detach(a);else{const l=r[vn],h=new dO(l,l[Os],l[vn]);h.detach(h.indexOf(t))}}const s=this._adjustIndex(e),o=this._lContainer;return tg(o,r,s,i),t.attachToViewContainerRef(),_A(PM(o),s,t),t}move(t,e){return this.insert(t,e)}indexOf(t){const e=uO(this._lContainer);return null!==e?e.indexOf(t):-1}remove(t){const e=this._adjustIndex(t,-1),i=Rf(this._lContainer,e);i&&(Wm(PM(this._lContainer),e),oy(i[Be],i))}detach(t){const e=this._adjustIndex(t,-1),i=Rf(this._lContainer,e);return i&&null!=Wm(PM(this._lContainer),e)?new Gf(i):null}_adjustIndex(t,e=0){return t??this.length+e}};function uO(n){return n[8]}function PM(n){return n[8]||(n[8]=[])}function pO(n,t){let e;const i=t[n.index];return Ps(i)?e=i:(e=function PN(n,t,e,i){return[n,!0,0,t,null,i,null,e,null,null]}(i,t,null,n),t[n.index]=e,Cy(t,e)),fO(e,t,n,i),new dO(e,n,t)}let fO=function vO(n,t,e,i){if(n[rl])return;let r;r=8&e.type?pr(i):function h9(n,t){const e=n[Yt],i=e.createComment(""),r=qs(t,n);return qc(e,ay(e,r),i,function o6(n,t){return n.nextSibling(t)}(e,r),!1),i}(t,e),n[rl]=r};function GM(n,t,e){const i=Se();return function Tn(n,t,e){return!Object.is(n[t],e)&&(n[t]=e,!0)}(i,function al(){return Rt.lFrame.bindingIndex++}(),t)&&function No(n,t,e,i,r,s,o,a){const l=qs(t,e);let c,h=t.inputs;!a&&null!=h&&(c=h[i])?(IM(n,e,c,i,r),jc(t)&&function NV(n,t){const e=To(t,n);16&e[Ct]||(e[Ct]|=64)}(e,t.index)):3&t.type&&(i=function LV(n){return"class"===n?"className":"for"===n?"htmlFor":"formaction"===n?"formAction":"innerHtml"===n?"innerHTML":"readonly"===n?"readOnly":"tabindex"===n?"tabIndex":n}(i),r=null!=o?o(r,t.value||"",i):r,s.setProperty(l,i,r))}(xi(),function Pr(){const n=Rt.lFrame;return Cf(n.tView,n.selectedIndex)}(),i,n,t,i[Yt],e,!1),GM}function XM(n,t,e,i,r){const o=r?"class":"style";IM(n,e,t.inputs[o],o,i)}function lg(n,t,e,i){const r=Se(),s=xi(),o=Ut+n,a=r[Yt],l=s.firstCreatePass?function R8(n,t,e,i,r,s){const o=t.consts,l=xu(t,n,2,i,sl(o,r));return function vM(n,t,e,i){if(fA()){const r=null===i?null:{"":-1},s=function HV(n,t){const e=n.directiveRegistry;let i=null,r=null;if(e)for(let s=0;s(qh(!0),sy(i,r,function EA(){return Rt.lFrame.currentNamespace}()));const Gu="en-US";let Mk=Gu;function sw(n){return!!n&&"function"==typeof n.then}function Gk(n){return!!n&&"function"==typeof n.subscribe}function ow(n,t,e,i){const r=Se(),s=xi(),o=fr();return function qk(n,t,e,i,r,s,o){const a=km(i),h=n.firstCreatePass&&HN(n),c=t[Er],d=RN(t);let u=!0;if(3&i.type||o){const g=qs(i,t),v=o?o(g):g,y=d.length,S=o?M=>o(pr(M[i.index])):i.index;let b=null;if(!o&&a&&(b=function FW(n,t,e,i){const r=n.cleanup;if(null!=r)for(let s=0;sl?a[l]:null}"string"==typeof o&&(s+=2)}return null}(n,t,r,i.index)),null!==b)(b.__ngLastListenerFn__||b).__ngNextListenerFn__=s,b.__ngLastListenerFn__=s,u=!1;else{s=Zk(i,t,c,s,!1);const M=e.listen(v,r,s);d.push(s,M),h&&h.push(r,S,y,y+1)}}else s=Zk(i,t,c,s,!1);const p=i.outputs;let f;if(u&&null!==p&&(f=p[r])){const g=f.length;if(g)for(let v=0;v-1?To(n.index,t):t);let l=$k(t,e,i,o),h=s.__ngNextListenerFn__;for(;h;)l=$k(t,e,h,o)&&l,h=h.__ngNextListenerFn__;return r&&!1===l&&o.preventDefault(),l}}function WW(){return this._results[Symbol.iterator]()}class lw{get changes(){return this._changes??=new Yo}constructor(t=!1){this._emitDistinctChangesOnly=t,this.dirty=!0,this._results=[],this._changesDetected=!1,this._changes=void 0,this.length=0,this.first=void 0,this.last=void 0;const e=lw.prototype;e[Symbol.iterator]||(e[Symbol.iterator]=WW)}get(t){return this._results[t]}map(t){return this._results.map(t)}filter(t){return this._results.filter(t)}find(t){return this._results.find(t)}reduce(t,e){return this._results.reduce(t,e)}forEach(t){this._results.forEach(t)}some(t){return this._results.some(t)}toArray(){return this._results.slice()}toString(){return this._results.toString()}reset(t,e){this.dirty=!1;const i=function oo(n){return n.flat(Number.POSITIVE_INFINITY)}(t);(this._changesDetected=!function XU(n,t,e){if(n.length!==t.length)return!1;for(let i=0;i{class n{static{this.__NG_ELEMENT_ID__=GW}}return n})();const YW=ih,QW=class extends YW{constructor(t,e,i){super(),this._declarationLView=t,this._declarationTContainer=e,this.elementRef=i}get ssrId(){return this._declarationTContainer.tView?.ssrId||null}createEmbeddedView(t,e){return this.createEmbeddedViewImpl(t,e)}createEmbeddedViewImpl(t,e,i){const r=function eg(n,t,e,i){const r=t.tView,a=wy(n,r,e,4096&n[Ct]?4096:16,null,t,null,null,null,i?.injector??null,i?.dehydratedView??null);a[If]=n[t.index];const h=n[il];return null!==h&&(a[il]=h.createEmbeddedView(r)),xM(r,a,e),a}(this._declarationLView,this._declarationTContainer,t,{injector:e,dehydratedView:i});return new Gf(r)}};function GW(){return Wy(fr(),Se())}function Wy(n,t){return 4&n.type?new QW(t,n,Du(n,t)):null}class hw{constructor(t){this.queryList=t,this.matches=null}clone(){return new hw(this.queryList)}setDirty(){this.queryList.setDirty()}}class cw{constructor(t=[]){this.queries=t}createEmbeddedView(t){const e=t.queries;if(null!==e){const i=null!==t.contentQueries?t.contentQueries[0]:e.length,r=[];for(let s=0;s0)i.push(o[a/2]);else{const h=s[a+1],c=t[-l];for(let d=mn;d(qh(!0),function ny(n,t){return n.createText(t)}(t[Yt],i));function gw(n,t,e,i,r){if(n=vt(n),Array.isArray(n))for(let s=0;s>20;if(Gc(n)||!n.multi){const p=new xf(h,r,Ot),f=mw(l,t,r?c:c+u,d);-1===f?(o1(Um(a,o),s,l),vw(s,n,t.length),t.push(l),a.directiveStart++,a.directiveEnd++,r&&(a.providerIndexes+=1048576),e.push(p),o.push(p)):(e[f]=p,o[f]=p)}else{const p=mw(l,t,c+u,d),f=mw(l,t,c,c+u),v=f>=0&&e[f];if(r&&!v||!r&&!(p>=0&&e[p])){o1(Um(a,o),s,l);const y=function vY(n,t,e,i,r){const s=new xf(n,e,Ot);return s.multi=[],s.index=t,s.componentProviders=0,kP(s,r,i&&!e),s}(r?gY:fY,e.length,r,i,h);!r&&v&&(e[f].providerFactory=y),vw(s,n,t.length,0),t.push(l),a.directiveStart++,a.directiveEnd++,r&&(a.providerIndexes+=1048576),e.push(y),o.push(y)}else vw(s,n,p>-1?p:f,kP(e[r?f:p],h,!r&&i));!r&&i&&v&&e[f].componentProviders++}}}function vw(n,t,e,i){const r=Gc(t),s=function pj(n){return!!n.useClass}(t);if(r||s){const l=(s?vt(t.useClass):t).prototype.ngOnDestroy;if(l){const h=n.destroyHooks||(n.destroyHooks=[]);if(!r&&t.multi){const c=h.indexOf(e);-1===c?h.push(e,[i,l]):h[c+1].push(i,l)}else h.push(e,l)}}}function kP(n,t,e){return e&&n.componentProviders++,n.multi.push(t)-1}function mw(n,t,e,i){for(let r=e;r{e.providersResolver=(i,r)=>function pY(n,t,e){const i=xi();if(i.firstCreatePass){const r=Ca(n);gw(e,i.data,i.blueprint,r,!0),gw(t,i.data,i.blueprint,r,!1)}}(i,r?r(n):n,t)}}class rd{}class zP extends rd{constructor(t){super(),this.componentFactoryResolver=new JN(this),this.instance=null;const e=new vu([...t.providers,{provide:rd,useValue:this},{provide:Sy,useValue:this.componentFactoryResolver}],t.parent||Zm(),t.debugName,new Set(["environment"]));this.injector=e,t.runEnvironmentInitializers&&e.resolveInjectorInitializers()}destroy(){this.injector.destroy()}onDestroy(t){this.injector.onDestroy(t)}}let bY=(()=>{class n{constructor(e){this._injector=e,this.cachedInjectors=new Map}getOrCreateStandaloneInjector(e){if(!e.standalone)return null;if(!this.cachedInjectors.has(e)){const i=GA(0,e.type),r=i.length>0?function IY(n,t,e=null){return new zP({providers:n,parent:t,debugName:e,runEnvironmentInitializers:!0}).injector}([i],this._injector,`Standalone[${e.type.name}]`):null;this.cachedInjectors.set(e,r)}return this.cachedInjectors.get(e)}ngOnDestroy(){try{for(const e of this.cachedInjectors.values())null!==e&&e.destroy()}finally{this.cachedInjectors.clear()}}static{this.\u0275prov=Yi({token:n,providedIn:"environment",factory:()=>new n(Fi(Jl))})}}return n})();function RP(n){(function Zc(n){VN.has(n)||(VN.add(n),performance?.mark?.("mark_feature_usage",{detail:{feature:n}}))})("NgStandalone"),n.getStandaloneInjector=t=>t.get(bY).getOrCreateStandaloneInjector(n)}let xw=(()=>{class n{constructor(){this.taskId=0,this.pendingTasks=new Set,this.hasPendingTasks=new _o(!1)}get _hasPendingTasks(){return this.hasPendingTasks.value}add(){this._hasPendingTasks||this.hasPendingTasks.next(!0);const e=this.taskId++;return this.pendingTasks.add(e),e}remove(e){this.pendingTasks.delete(e),0===this.pendingTasks.size&&this._hasPendingTasks&&this.hasPendingTasks.next(!1)}ngOnDestroy(){this.pendingTasks.clear(),this._hasPendingTasks&&this.hasPendingTasks.next(!1)}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();const g2=new Ht(""),QQ=new Ht("");let Ow=(()=>{class n{constructor(){this.initialized=!1,this.done=!1,this.donePromise=new Promise((e,i)=>{this.resolve=e,this.reject=i}),this.appInits=Ri(QQ,{optional:!0})??[]}runInitializers(){if(this.initialized)return;const e=[];for(const r of this.appInits){const s=r();if(sw(s))e.push(s);else if(Gk(s)){const o=new Promise((a,l)=>{s.subscribe({complete:a,error:l})});e.push(o)}}const i=()=>{this.done=!0,this.resolve()};Promise.all(e).then(()=>{i()}).catch(r=>{this.reject(r)}),0===e.length&&i(),this.initialized=!0}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();const v2=new Ht("");let $u=(()=>{class n{constructor(){this._bootstrapListeners=[],this._runningTick=!1,this._destroyed=!1,this._destroyListeners=[],this._views=[],this.internalErrorHandler=Ri(yN),this.afterRenderEffectManager=Ri(Xf),this.componentTypes=[],this.components=[],this.isStable=Ri(xw).hasPendingTasks.pipe(jr(e=>!e)),this._injector=Ri(Jl)}get destroyed(){return this._destroyed}get injector(){return this._injector}bootstrap(e,i){const r=e instanceof iN;if(!this._injector.get(Ow).done)throw!r&&function _c(n){const t=ci(n)||jn(n)||gs(n);return null!==t&&t.standalone}(e),new F(405,!1);let o;o=r?e:this._injector.get(Sy).resolveComponentFactory(e),this.componentTypes.push(o.componentType);const a=function XQ(n){return n.isBoundToModule}(o)?void 0:this._injector.get(rd),h=o.create(Wo.NULL,[],i||o.selector,a),c=h.location.nativeElement,d=h.injector.get(g2,null);return d?.registerApplication(c),h.onDestroy(()=>{this.detachView(h.hostView),$y(this.components,h),d?.unregisterApplication(c)}),this._loadComponent(h),h}tick(){if(this._runningTick)throw new F(101,!1);try{this._runningTick=!0;for(let e of this._views)e.detectChanges()}catch(e){this.internalErrorHandler(e)}finally{try{this.afterRenderEffectManager.execute()}catch(e){this.internalErrorHandler(e)}this._runningTick=!1}}attachView(e){const i=e;this._views.push(i),i.attachToAppRef(this)}detachView(e){const i=e;$y(this._views,i),i.detachFromAppRef()}_loadComponent(e){this.attachView(e.hostView),this.tick(),this.components.push(e);const i=this._injector.get(v2,[]);[...this._bootstrapListeners,...i].forEach(r=>r(e))}ngOnDestroy(){if(!this._destroyed)try{this._destroyListeners.forEach(e=>e()),this._views.slice().forEach(e=>e.destroy())}finally{this._destroyed=!0,this._views=[],this._bootstrapListeners=[],this._destroyListeners=[]}}onDestroy(e){return this._destroyListeners.push(e),()=>$y(this._destroyListeners,e)}destroy(){if(this._destroyed)throw new F(406,!1);const e=this._injector;e.destroy&&!e.destroyed&&e.destroy()}get viewCount(){return this._views.length}warnIfDestroyed(){}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();function $y(n,t){const e=n.indexOf(t);e>-1&&n.splice(e,1)}let $Q=(()=>{class n{constructor(){this.zone=Ri(zr),this.applicationRef=Ri($u)}initialize(){this._onMicrotaskEmptySubscription||(this._onMicrotaskEmptySubscription=this.zone.onMicrotaskEmpty.subscribe({next:()=>{this.zone.run(()=>{this.applicationRef.tick()})}}))}ngOnDestroy(){this._onMicrotaskEmptySubscription?.unsubscribe()}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();function b2(n){return[{provide:zr,useFactory:n},{provide:gu,multi:!0,useFactory:()=>{const t=Ri($Q,{optional:!0});return()=>t.initialize()}},{provide:gu,multi:!0,useFactory:()=>{const t=Ri(KQ);return()=>{t.initialize()}}},{provide:yN,useFactory:ZQ}]}function ZQ(){const n=Ri(zr),t=Ri(eh);return e=>n.runOutsideAngular(()=>t.handleError(e))}function JQ(n){return function m1(n){return{\u0275providers:n}}([[],b2(()=>new zr(function M2(n){return{enableLongStackTrace:!1,shouldCoalesceEventChangeDetection:n?.eventCoalescing??!1,shouldCoalesceRunChangeDetection:n?.runCoalescing??!1}}(n)))])}let KQ=(()=>{class n{constructor(){this.subscription=new As,this.initialized=!1,this.zone=Ri(zr),this.pendingTasks=Ri(xw)}initialize(){if(this.initialized)return;this.initialized=!0;let e=null;!this.zone.isStable&&!this.zone.hasPendingMacrotasks&&!this.zone.hasPendingMicrotasks&&(e=this.pendingTasks.add()),this.zone.runOutsideAngular(()=>{this.subscription.add(this.zone.onStable.subscribe(()=>{zr.assertNotInAngularZone(),queueMicrotask(()=>{null!==e&&!this.zone.hasPendingMacrotasks&&!this.zone.hasPendingMicrotasks&&(this.pendingTasks.remove(e),e=null)})}))}),this.subscription.add(this.zone.onUnstable.subscribe(()=>{zr.assertInAngularZone(),e??=this.pendingTasks.add()}))}ngOnDestroy(){this.subscription.unsubscribe()}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();const rh=new Ht("",{providedIn:"root",factory:()=>Ri(rh,Di.Optional|Di.SkipSelf)||function eG(){return typeof $localize<"u"&&$localize.locale||Gu}()}),kw=new Ht("");let rc=null;function CG(n){try{const{rootComponent:t,appProviders:e,platformProviders:i}=n,r=function sG(n=[]){if(rc)return rc;const t=function E2(n=[],t){return Wo.create({name:t,providers:[{provide:I1,useValue:"platform"},{provide:kw,useValue:new Set([()=>rc=null])},...n]})}(n);return rc=t,function m2(){!function yb(n){Gd=n}(()=>{throw new F(600,!1)})}(),function D2(n){n.get(nL,null)?.forEach(e=>e())}(t),t}(i),s=[JQ(),...e||[]],a=new zP({providers:s,parent:r,debugName:"",runEnvironmentInitializers:!1}).injector,l=a.get(zr);return l.run(()=>{a.resolveInjectorInitializers();const h=a.get(eh,null);let c;l.runOutsideAngular(()=>{c=l.onError.subscribe({next:p=>{h.handleError(p)}})});const d=()=>a.destroy(),u=r.get(kw);return u.add(d),a.onDestroy(()=>{c.unsubscribe(),u.delete(d)}),function y2(n,t,e){try{const i=e();return sw(i)?i.catch(r=>{throw t.runOutsideAngular(()=>n.handleError(r)),r}):i}catch(i){throw t.runOutsideAngular(()=>n.handleError(i)),i}}(h,l,()=>{const p=a.get(Ow);return p.runInitializers(),p.donePromise.then(()=>{!function wk(n){ro(n,"Expected localeId to be defined"),"string"==typeof n&&(Mk=n.toLowerCase().replace(/_/g,"-"))}(a.get(rh,Gu)||Gu);const g=a.get($u);return void 0!==t&&g.bootstrap(t),g})})})}catch(t){return Promise.reject(t)}}let $2=null;function Uw(){return $2}class FG{}const sd=new Ht("");let rq=(()=>{class n{static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275mod=Am({type:n})}static{this.\u0275inj=gf({})}}return n})();function uz(n){return"server"===n}class Nq extends FG{constructor(){super(...arguments),this.supportsDOMEvents=!0}}class nC extends Nq{static makeCurrent(){!function BG(n){$2??=n}(new nC)}onAndCancel(t,e,i){return t.addEventListener(e,i),()=>{t.removeEventListener(e,i)}}dispatchEvent(t,e){t.dispatchEvent(e)}remove(t){t.parentNode&&t.parentNode.removeChild(t)}createElement(t,e){return(e=e||this.getDefaultDocument()).createElement(t)}createHtmlDocument(){return document.implementation.createHTMLDocument("fakeTitle")}getDefaultDocument(){return document}isElementNode(t){return t.nodeType===Node.ELEMENT_NODE}isShadowRoot(t){return t instanceof DocumentFragment}getGlobalEventTarget(t,e){return"window"===e?window:"document"===e?t:"body"===e?t.body:null}getBaseHref(t){const e=function Oq(){return wg=wg||document.querySelector("base"),wg?wg.getAttribute("href"):null}();return null==e?null:function kq(n){return new URL(n,document.baseURI).pathname}(e)}resetBaseElement(){wg=null}getUserAgent(){return window.navigator.userAgent}getCookie(t){return function EX(n,t){t=encodeURIComponent(t);for(const e of n.split(";")){const i=e.indexOf("="),[r,s]=-1==i?[e,""]:[e.slice(0,i),e.slice(i+1)];if(r.trim()===t)return decodeURIComponent(s)}return null}(document.cookie,t)}}let wg=null,zq=(()=>{class n{build(){return new XMLHttpRequest}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();const sC=new Ht("");let vz=(()=>{class n{constructor(e,i){this._zone=i,this._eventNameToPlugin=new Map,e.forEach(r=>{r.manager=this}),this._plugins=e.slice().reverse()}addEventListener(e,i,r){return this._findPluginFor(i).addEventListener(e,i,r)}getZone(){return this._zone}_findPluginFor(e){let i=this._eventNameToPlugin.get(e);if(i)return i;if(i=this._plugins.find(s=>s.supports(e)),!i)throw new F(5101,!1);return this._eventNameToPlugin.set(e,i),i}static{this.\u0275fac=function(i){return new(i||n)(Fi(sC),Fi(zr))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();class mz{constructor(t){this._doc=t}}const oC="ng-app-id";let yz=(()=>{class n{constructor(e,i,r,s={}){this.doc=e,this.appId=i,this.nonce=r,this.platformId=s,this.styleRef=new Map,this.hostNodes=new Set,this.styleNodesInDOM=this.collectServerRenderedStyles(),this.platformIsServer=uz(s),this.resetHostNodes()}addStyles(e){for(const i of e)1===this.changeUsageCount(i,1)&&this.onStyleAdded(i)}removeStyles(e){for(const i of e)this.changeUsageCount(i,-1)<=0&&this.onStyleRemoved(i)}ngOnDestroy(){const e=this.styleNodesInDOM;e&&(e.forEach(i=>i.remove()),e.clear());for(const i of this.getAllStyles())this.onStyleRemoved(i);this.resetHostNodes()}addHost(e){this.hostNodes.add(e);for(const i of this.getAllStyles())this.addStyleToHost(e,i)}removeHost(e){this.hostNodes.delete(e)}getAllStyles(){return this.styleRef.keys()}onStyleAdded(e){for(const i of this.hostNodes)this.addStyleToHost(i,e)}onStyleRemoved(e){const i=this.styleRef;i.get(e)?.elements?.forEach(r=>r.remove()),i.delete(e)}collectServerRenderedStyles(){const e=this.doc.head?.querySelectorAll(`style[${oC}="${this.appId}"]`);if(e?.length){const i=new Map;return e.forEach(r=>{null!=r.textContent&&i.set(r.textContent,r)}),i}return null}changeUsageCount(e,i){const r=this.styleRef;if(r.has(e)){const s=r.get(e);return s.usage+=i,s.usage}return r.set(e,{usage:i,elements:[]}),i}getStyleElement(e,i){const r=this.styleNodesInDOM,s=r?.get(i);if(s?.parentNode===e)return r.delete(i),s.removeAttribute(oC),s;{const o=this.doc.createElement("style");return this.nonce&&o.setAttribute("nonce",this.nonce),o.textContent=i,this.platformIsServer&&o.setAttribute(oC,this.appId),e.appendChild(o),o}}addStyleToHost(e,i){const r=this.getStyleElement(e,i),s=this.styleRef,o=s.get(i)?.elements;o?o.push(r):s.set(i,{elements:[r],usage:1})}resetHostNodes(){const e=this.hostNodes;e.clear(),e.add(this.doc.head)}static{this.\u0275fac=function(i){return new(i||n)(Fi(sd),Fi(x1),Fi(sL,8),Fi(yu))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();const aC={svg:"http://www.w3.org/2000/svg",xhtml:"http://www.w3.org/1999/xhtml",xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/",math:"http://www.w3.org/1998/MathML/"},lC=/%COMP%/g,Fq=new Ht("",{providedIn:"root",factory:()=>!0});function Iz(n,t){return t.map(e=>e.replace(lC,n))}let bz=(()=>{class n{constructor(e,i,r,s,o,a,l,h=null){this.eventManager=e,this.sharedStylesHost=i,this.appId=r,this.removeStylesOnCompDestroy=s,this.doc=o,this.platformId=a,this.ngZone=l,this.nonce=h,this.rendererByCompId=new Map,this.platformIsServer=uz(a),this.defaultRenderer=new hC(e,o,l,this.platformIsServer)}createRenderer(e,i){if(!e||!i)return this.defaultRenderer;this.platformIsServer&&i.encapsulation===Ia.ShadowDom&&(i={...i,encapsulation:Ia.Emulated});const r=this.getOrCreateRenderer(e,i);return r instanceof wz?r.applyToHost(e):r instanceof cC&&r.applyStyles(),r}getOrCreateRenderer(e,i){const r=this.rendererByCompId;let s=r.get(i.id);if(!s){const o=this.doc,a=this.ngZone,l=this.eventManager,h=this.sharedStylesHost,c=this.removeStylesOnCompDestroy,d=this.platformIsServer;switch(i.encapsulation){case Ia.Emulated:s=new wz(l,h,i,this.appId,c,o,a,d);break;case Ia.ShadowDom:return new Vq(l,h,e,i,o,a,this.nonce,d);default:s=new cC(l,h,i,c,o,a,d)}r.set(i.id,s)}return s}ngOnDestroy(){this.rendererByCompId.clear()}static{this.\u0275fac=function(i){return new(i||n)(Fi(vz),Fi(yz),Fi(x1),Fi(Fq),Fi(sd),Fi(yu),Fi(zr),Fi(sL))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();class hC{constructor(t,e,i,r){this.eventManager=t,this.doc=e,this.ngZone=i,this.platformIsServer=r,this.data=Object.create(null),this.throwOnSyntheticProps=!0,this.destroyNode=null}destroy(){}createElement(t,e){return e?this.doc.createElementNS(aC[e]||e,t):this.doc.createElement(t)}createComment(t){return this.doc.createComment(t)}createText(t){return this.doc.createTextNode(t)}appendChild(t,e){(Mz(t)?t.content:t).appendChild(e)}insertBefore(t,e,i){t&&(Mz(t)?t.content:t).insertBefore(e,i)}removeChild(t,e){t&&t.removeChild(e)}selectRootElement(t,e){let i="string"==typeof t?this.doc.querySelector(t):t;if(!i)throw new F(-5104,!1);return e||(i.textContent=""),i}parentNode(t){return t.parentNode}nextSibling(t){return t.nextSibling}setAttribute(t,e,i,r){if(r){e=r+":"+e;const s=aC[r];s?t.setAttributeNS(s,e,i):t.setAttribute(e,i)}else t.setAttribute(e,i)}removeAttribute(t,e,i){if(i){const r=aC[i];r?t.removeAttributeNS(r,e):t.removeAttribute(`${i}:${e}`)}else t.removeAttribute(e)}addClass(t,e){t.classList.add(e)}removeClass(t,e){t.classList.remove(e)}setStyle(t,e,i,r){r&(Kh.DashCase|Kh.Important)?t.style.setProperty(e,i,r&Kh.Important?"important":""):t.style[e]=i}removeStyle(t,e,i){i&Kh.DashCase?t.style.removeProperty(e):t.style[e]=""}setProperty(t,e,i){null!=t&&(t[e]=i)}setValue(t,e){t.nodeValue=e}listen(t,e,i){if("string"==typeof t&&!(t=Uw().getGlobalEventTarget(this.doc,t)))throw new Error(`Unsupported event target ${t} for event ${e}`);return this.eventManager.addEventListener(t,e,this.decoratePreventDefault(i))}decoratePreventDefault(t){return e=>{if("__ngUnwrap__"===e)return t;!1===(this.platformIsServer?this.ngZone.runGuarded(()=>t(e)):t(e))&&e.preventDefault()}}}function Mz(n){return"TEMPLATE"===n.tagName&&void 0!==n.content}class Vq extends hC{constructor(t,e,i,r,s,o,a,l){super(t,s,o,l),this.sharedStylesHost=e,this.hostEl=i,this.shadowRoot=i.attachShadow({mode:"open"}),this.sharedStylesHost.addHost(this.shadowRoot);const h=Iz(r.id,r.styles);for(const c of h){const d=document.createElement("style");a&&d.setAttribute("nonce",a),d.textContent=c,this.shadowRoot.appendChild(d)}}nodeOrShadowRoot(t){return t===this.hostEl?this.shadowRoot:t}appendChild(t,e){return super.appendChild(this.nodeOrShadowRoot(t),e)}insertBefore(t,e,i){return super.insertBefore(this.nodeOrShadowRoot(t),e,i)}removeChild(t,e){return super.removeChild(this.nodeOrShadowRoot(t),e)}parentNode(t){return this.nodeOrShadowRoot(super.parentNode(this.nodeOrShadowRoot(t)))}destroy(){this.sharedStylesHost.removeHost(this.shadowRoot)}}class cC extends hC{constructor(t,e,i,r,s,o,a,l){super(t,s,o,a),this.sharedStylesHost=e,this.removeStylesOnCompDestroy=r,this.styles=l?Iz(l,i.styles):i.styles}applyStyles(){this.sharedStylesHost.addStyles(this.styles)}destroy(){this.removeStylesOnCompDestroy&&this.sharedStylesHost.removeStyles(this.styles)}}class wz extends cC{constructor(t,e,i,r,s,o,a,l){const h=r+"-"+i.id;super(t,e,i,s,o,a,l,h),this.contentAttr=function _q(n){return"_ngcontent-%COMP%".replace(lC,n)}(h),this.hostAttr=function Uq(n){return"_nghost-%COMP%".replace(lC,n)}(h)}applyToHost(t){this.applyStyles(),this.setAttribute(t,this.hostAttr,"")}createElement(t,e){const i=super.createElement(t,e);return super.setAttribute(i,this.contentAttr,""),i}}let Wq=(()=>{class n extends mz{constructor(e){super(e)}supports(e){return!0}addEventListener(e,i,r){return e.addEventListener(i,r,!1),()=>this.removeEventListener(e,i,r)}removeEventListener(e,i,r){return e.removeEventListener(i,r)}static{this.\u0275fac=function(i){return new(i||n)(Fi(sd))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();const Cz=["alt","control","meta","shift"],Yq={"\b":"Backspace","\t":"Tab","\x7f":"Delete","\x1b":"Escape",Del:"Delete",Esc:"Escape",Left:"ArrowLeft",Right:"ArrowRight",Up:"ArrowUp",Down:"ArrowDown",Menu:"ContextMenu",Scroll:"ScrollLock",Win:"OS"},Qq={alt:n=>n.altKey,control:n=>n.ctrlKey,meta:n=>n.metaKey,shift:n=>n.shiftKey};let Gq=(()=>{class n extends mz{constructor(e){super(e)}supports(e){return null!=n.parseEventName(e)}addEventListener(e,i,r){const s=n.parseEventName(i),o=n.eventCallback(s.fullKey,r,this.manager.getZone());return this.manager.getZone().runOutsideAngular(()=>Uw().onAndCancel(e,s.domEventName,o))}static parseEventName(e){const i=e.toLowerCase().split("."),r=i.shift();if(0===i.length||"keydown"!==r&&"keyup"!==r)return null;const s=n._normalizeKey(i.pop());let o="",a=i.indexOf("code");if(a>-1&&(i.splice(a,1),o="code."),Cz.forEach(h=>{const c=i.indexOf(h);c>-1&&(i.splice(c,1),o+=h+".")}),o+=s,0!=i.length||0===s.length)return null;const l={};return l.domEventName=r,l.fullKey=o,l}static matchEventFullKeyCode(e,i){let r=Yq[e.key]||e.key,s="";return i.indexOf("code.")>-1&&(r=e.code,s="code."),!(null==r||!r)&&(r=r.toLowerCase()," "===r?r="space":"."===r&&(r="dot"),Cz.forEach(o=>{o!==r&&(0,Qq[o])(e)&&(s+=o+".")}),s+=r,s===i)}static eventCallback(e,i,r){return s=>{n.matchEventFullKeyCode(s,e)&&r.runGuarded(()=>i(s))}}static _normalizeKey(e){return"esc"===e?"escape":e}static{this.\u0275fac=function(i){return new(i||n)(Fi(sd))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();function Ez(n){return{appProviders:[...e$,...n?.providers??[]],platformProviders:Jq}}const Jq=[{provide:yu,useValue:"browser"},{provide:nL,useValue:function qq(){nC.makeCurrent()},multi:!0},{provide:sd,useFactory:function Zq(){return function xj(n){D1=n}(document),document},deps:[]}],e$=[{provide:I1,useValue:"root"},{provide:eh,useFactory:function $q(){return new eh},deps:[]},{provide:sC,useClass:Wq,multi:!0,deps:[sd,zr,yu]},{provide:sC,useClass:Gq,multi:!0,deps:[sd]},bz,yz,vz,{provide:nN,useExisting:bz},{provide:class lq{},useClass:zq,deps:[]},[]];var n$=0,dC=!1;function S0(n,t){var e=t;return e.unshift(void 0),new(Function.prototype.bind.apply(n,e))}function Y(n,t){for(var e=t,i=n.replace(/\[/g,".").replace(/\]/g,"").split("."),r=0;r"u"}function wi(n){return n+"_"+n$++}function b0(n,t){return n===t||!(n===document||!n)&&b0(n.parentNode,t)}function Dg(n){try{throw new Error(n)}catch(t){throw new Error(t.message+"\n"+t.stack)}}function Re(n){var t=n+"";return t.match(/auto|cm|mm|in|px|pt|pc|%|em|ex|ch|rem|vw|vh|vmin|vmax/)?t:t+"px"}function ce(){return dC}var xg,n,t,h$={latn:{_digits:"0123456789",_type:"numeric"}},Lz={decimal:".",group:",",percentSign:"%",plusSign:"+",minusSign:"-",infinity:"\u221e",nan:"NaN",exponential:"E"},Nz=[0,1,2,3,4,5,6,7,8,9],Rr=function(){function n(){}return n.getMainObject=function(t,e){return Y(ce()?e:"main."+e,t)},n.getNumberingSystem=function(t){return Y("supplemental.numberingSystems",t)||this.numberingSystems},n.reverseObject=function(t,e){for(var r={},s=0,o=e||Object.keys(t);s13&&(f+=1,o-=12),o-=1,a=f-4716;var y=u-24e5,S=10631/30,b=u-1948084,M=Math.floor(b/10631);b-=10631*M;var w=Math.floor((b-.1335)/S),C=30*M+w;b-=Math.floor(w*S+.1335);var D=Math.floor((b+28.5001)/29.5);13===D&&(D=12);for(var A=b-Math.floor(29.5001*D-29),x=0;xy);x++);var R=x+16260,L=Math.floor((R-1)/12),O=L+1,N=R-12*L,T=y-t[x-1]+1;return(T+"").length>2&&(T=A,N=D,O=C),{year:O,month:N,date:T}},n.toGregorian=function i(r,s,o){var g=Math.floor(o+t[12*(r-1)+1+(s-1)-16260-1]-1+24e5+.5),v=Math.floor((g-1867216.25)/36524.25),y=1524+(v=g+1+v-Math.floor(v/4)),S=Math.floor((y-122.1)/365.25),b=Math.floor(365.25*S),M=Math.floor((y-b)/30.6001),w=y-b-Math.floor(30.6001*M),C=M-(M>13.5?13:1),D=S-(C>2.5?4716:4715);return D<=0&&C--,new Date(D+"/"+C+"/"+w)};var ut,u$=/\/MMMMM|MMMM|MMM|a|LLLL|LLL|EEEEE|EEEE|E|K|cccc|ccc|WW|W|G+|z+/gi,Oz="stand-alone",p$=["sun","mon","tue","wed","thu","fri","sat"],kz={m:"getMinutes",h:"getHours",H:"getHours",s:"getSeconds",d:"getDate",f:"getMilliseconds"},Pz=function(){function n(){}return n.dateFormat=function(t,e,i){var r=this,s=ut.getDependables(i,t,e.calendar),o=Y("parserObject.numbers",s),a=s.dateObject,l={isIslamic:ut.islamicRegex.test(e.calendar)};ce()&&e.isServerRendered&&(e=ut.compareBlazorDateFormats(e,t));var h=e.format||ut.getResultantPattern(e.skeleton,s.dateObject,e.type,!1,ce()?t:"");if(l.dateSeperator=ce()?Y("dateSeperator",a):ut.getDateSeparator(s.dateObject),st(h))Dg("Format options or type given must be invalid");else{h=ut.ConvertDateToWeekFormat(h),ce()&&(h=h.replace(/tt/,"a")),l.pattern=h,l.numMapper=ce()?ze({},o):Rr.getNumberMapper(s.parserObject,Rr.getNumberingSystem(i));for(var d=0,u=h.match(u$)||[];d2?r+=e.month[""+u]:f=!0;break;case"E":case"c":r+=e.weekday[""+p$[t.getDay()]];break;case"H":case"h":case"m":case"s":case"d":case"f":if(f=!0,"d"===d)u=o.date;else if("f"===d){f=!1,g=!0;var y=(p=(p=t[""+kz[""+d]]().toString()).substring(0,c)).length;if(c!==y){if(c>3)continue;for(var S=0;S0?1:0],o=Math.abs(t);return s.replace(/HH?|mm/g,function(a){var l=a.length,h=-1!==a.indexOf("H");return i.checkTwodigitNumber(Math.floor(h?o/60:o%60),l)})},n}(),zz={ms:"minimumSignificantDigits",ls:"maximumSignificantDigits",mf:"minimumFractionDigits",lf:"maximumFractionDigits"},ep=["infinity","nan","group","decimal","exponential"],Rz=function(){function n(){}return n.numberFormatter=function(t,e,i){var l,r=this,s=ze({},e),o={},a={},h=ut.getDependables(i,t,"",!0),c=h.numericObject;a.numberMapper=ce()?ze({},c):Rr.getNumberMapper(h.parserObject,Rr.getNumberingSystem(i),!0),a.currencySymbol=ce()?Y("currencySymbol",c):ut.getCurrencySymbol(h.numericObject,s.currency||Lg,e.altSymbol,e.ignoreCurrency),a.percentSymbol=ce()?Y("numberSymbols.percentSign",c):a.numberMapper.numberSymbols.percentSign,a.minusSymbol=ce()?Y("numberSymbols.minusSign",c):a.numberMapper.numberSymbols.minusSign;var d=a.numberMapper.numberSymbols;if(e.format&&!ut.formatRegex.test(e.format))o=ut.customFormat(e.format,a,h.numericObject),!st(s.useGrouping)&&s.useGrouping&&(s.useGrouping=o.pData.useGrouping);else{if(ze(s,ut.getProperNumericSkeleton(e.format||"N")),s.isCurrency="currency"===s.type,s.isPercent="percent"===s.type,ce()||(l=ut.getSymbolPattern(s.type,a.numberMapper.numberSystem,h.numericObject,s.isAccount)),s.groupOne=this.checkValueRange(s.maximumSignificantDigits,s.minimumSignificantDigits,!0),this.checkValueRange(s.maximumFractionDigits,s.minimumFractionDigits,!1,!0),st(s.fractionDigits)||(s.minimumFractionDigits=s.maximumFractionDigits=s.fractionDigits),st(s.useGrouping)&&(s.useGrouping=!0),s.isCurrency&&!ce()&&(l=l.replace(/\u00A4/g,ut.defaultCurrency)),ce())o.nData=ze({},{},Y(s.type+"nData",c)),o.pData=ze({},{},Y(s.type+"pData",c)),"currency"===s.type&&e.currency&&ut.replaceBlazorCurrency([o.pData,o.nData],a.currencySymbol,e.currency);else{var u=l.split(";");o.nData=ut.getFormatData(u[1]||"-"+u[0],!0,a.currencySymbol),o.pData=ut.getFormatData(u[0],!1,a.currencySymbol),s.useGrouping&&(s.groupSeparator=d[ep[2]],s.groupData=this.getGroupingDetails(u[0]))}if(st(s.minimumFractionDigits)&&(s.minimumFractionDigits=o.nData.minimumFraction),st(s.maximumFractionDigits)){var f=o.nData.maximumFraction;s.maximumFractionDigits=st(f)&&s.isPercent?0:f}var g=s.minimumFractionDigits,v=s.maximumFractionDigits;!st(g)&&!st(v)&&g>v&&(s.maximumFractionDigits=g)}return ze(o.nData,s),ze(o.pData,s),function(y){return isNaN(y)?d[ep[1]]:isFinite(y)?r.intNumberFormatter(y,o,a,e):d[ep[0]]}},n.getGroupingDetails=function(t){var e={},i=t.match(ut.negativeDataRegex);if(i&&i[4]){var r=i[4],s=r.lastIndexOf(",");if(-1!==s){var o=r.split(".")[0];e.primary=o.length-s-1;var a=r.lastIndexOf(",",s-1);-1!==a&&(e.secondary=s-1-a)}}return e},n.checkValueRange=function(t,e,i,r){var s=r?"f":"s",o=0,a=zz["l"+s],l=zz["m"+s];if(st(t)||(this.checkRange(t,a,r),o++),st(e)||(this.checkRange(e,l,r),o++),2===o){if(!(tr[1])&&Dg(e+"value must be within the range"+r[0]+"to"+r[1])},n.intNumberFormatter=function(t,e,i,r){var s;if(!st(e.nData.type)){t<0?(t*=-1,s=e.nData):s=0===t&&e.zeroData||e.pData;var o="";if(s.isPercent&&(t*=100),s.groupOne)o=this.processSignificantDigits(t,s.minimumSignificantDigits,s.maximumSignificantDigits);else if(o=this.processFraction(t,s.minimumFractionDigits,s.maximumFractionDigits,r),s.minimumIntegerDigits&&(o=this.processMinimumIntegers(o,s.minimumIntegerDigits)),i.isCustomFormat&&s.minimumFractionDigits=0&&"0"===l[parseInt(c.toString(),10)]&&c>=s.minimumFractionDigits;c--)l=l.slice(0,c);o=a[0]+"."+l}return"scientific"===s.type&&(o=(o=t.toExponential(s.maximumFractionDigits)).replace("e",i.numberMapper.numberSymbols[ep[4]])),o=o.replace(".",i.numberMapper.numberSymbols[ep[3]]),o="#,###,,;(#,###,,)"===s.format?this.customPivotFormat(parseInt(o,10)):o,s.useGrouping&&(o=this.groupNumbers(o,s.groupData.primary,s.groupSeparator||",",i.numberMapper.numberSymbols[ep[3]]||".",s.groupData.secondary)),o=Rr.convertValueParts(o,ut.latnParseRegex,i.numberMapper.mapper),"N/A"===s.nlead?s.nlead:"0"===o&&r&&"0"===r.format?o+s.nend:s.nlead+o+s.nend}},n.processSignificantDigits=function(t,e,i){var r=t+"";return r.lengthe;)c=l.slice(h-e,h)+(c.length?i+c:""),h-=e,o&&(e=s,o=!1);return a[0]=l.slice(0,h)+(c.length?i:"")+c,a.join(r)},n.processFraction=function(t,e,i,r){var s=(t+"").split(".")[1],o=s?s.length:0;if(e&&oi||0===i))return t.toFixed(i);var h=t+"";return"0"===h[0]&&r&&"###.00"===r.format&&(h=h.slice(1)),h},n.processMinimumIntegers=function(t,e){var i=t.split("."),r=i[0],s=r.length;if(s=5e5){var r=(t/=1e6).toString().split(".")[1];return r&&+r.substring(0,1)>=5?Math.ceil(t).toString():Math.floor(t).toString()}return""},n}(),Tg=(new RegExp("^([^0-9]*)(([0-9,]*[0-9]+)(.[0-9]+)?)([Ee][+-]?[0-9]+)?([^0-9]*)$"),function(){function n(t){this.ranArray=[],this.boundedEvents={},!m(t)&&(this.context=t)}return n.prototype.on=function(t,e,i,r){if(!m(e)){var s=i||this.context;if(this.notExist(t))return void(this.boundedEvents[""+t]=[{handler:e,context:s,id:r}]);m(r)?this.isHandlerPresent(this.boundedEvents[""+t],e)||this.boundedEvents[""+t].push({handler:e,context:s}):-1===this.ranArray.indexOf(r)&&(this.ranArray.push(r),this.boundedEvents[""+t].push({handler:e,context:s,id:r}))}},n.prototype.off=function(t,e,i){if(!this.notExist(t)){var r=Y(t,this.boundedEvents);if(e){for(var s=0;s1&&(_.fractionDigits=parseInt(P[2],10)),_}function f(T,P,_,B){var j=B?{}:{nlead:"",nend:""},Q=T.match(n.customRegex);if(Q){B||(j.nlead=g(Q[1],_),j.nend=g(Q[10],_),j.groupPattern=Q[4]);var oe=Q[7];if(oe&&P){var ue=oe.match(t);j.minimumFraction=m(ue)?0:ue.length,j.maximumFraction=oe.length-1}}return j}function g(T,P){return T?(T=T.replace(n.defaultCurrency,P),""===P?T.trim():T):""}function v(T,P,_,B){return B?"$":Y("currencies."+P+(_?"."+_:".symbol"),T)||Y("currencies."+P+".symbol-alt-narrow",T)||"$"}function S(T,P,_){var B={type:"decimal",minimumFractionDigits:0,maximumFractionDigits:0},j=T.match(n.customRegex);if(m(j)||""===j[5]&&"N/A"!==T)return B.type=void 0,B;B.nlead=j[1],B.nend=j[10];var Q=j[6],oe=!!Q.match(/ $/g),ue=-1!==Q.replace(/ $/g,"").indexOf(" ");B.useGrouping=-1!==Q.indexOf(",")||ue,Q=Q.replace(/,/g,"");var pe=j[7];if(-1!==Q.indexOf("0")&&(B.minimumIntegerDigits=Q.length-Q.indexOf("0")),m(pe)||(B.minimumFractionDigits=pe.lastIndexOf("0"),B.maximumFractionDigits=pe.lastIndexOf("#"),-1===B.minimumFractionDigits&&(B.minimumFractionDigits=0),(-1===B.maximumFractionDigits||B.maximumFractionDigitsQ.lastIndexOf("'"))){B[""+a[parseInt(j.toString(),10)]]=Q.substr(0,oe)+_+Q.substr(oe+1),B[""+a[""+P]]=!0,B.type=B.isCurrency?"currency":"percent";break}}return B}function C(T,P){if(-1!==T.indexOf(",")){var _=T.split(",");T=_[0]+Y("numberMapper.numberSymbols.group",P)+_[1].replace(".",Y("numberMapper.numberSymbols.decimal",P))}else T=T.replace(".",Y("numberMapper.numberSymbols.decimal",P));return T}function A(T,P,_){T+=".";for(var B=0;B0;Q-=3)T=","+_[Q-2]+_[Q-1]+_[parseInt(Q.toString(),10)]+T;return T=T.slice(1),P[1]?T+"."+P[1]:T}n.dateParseRegex=/([a-z])\1*|'([^']|'')+'|''|./gi,n.basicPatterns=["short","medium","long","full"],n.defaultObject={dates:{calendars:{gregorian:{months:{"stand-alone":{abbreviated:{1:"Jan",2:"Feb",3:"Mar",4:"Apr",5:"May",6:"Jun",7:"Jul",8:"Aug",9:"Sep",10:"Oct",11:"Nov",12:"Dec"},narrow:{1:"J",2:"F",3:"M",4:"A",5:"M",6:"J",7:"J",8:"A",9:"S",10:"O",11:"N",12:"D"},wide:{1:"January",2:"February",3:"March",4:"April",5:"May",6:"June",7:"July",8:"August",9:"September",10:"October",11:"November",12:"December"}}},days:{"stand-alone":{abbreviated:{sun:"Sun",mon:"Mon",tue:"Tue",wed:"Wed",thu:"Thu",fri:"Fri",sat:"Sat"},narrow:{sun:"S",mon:"M",tue:"T",wed:"W",thu:"T",fri:"F",sat:"S"},short:{sun:"Su",mon:"Mo",tue:"Tu",wed:"We",thu:"Th",fri:"Fr",sat:"Sa"},wide:{sun:"Sunday",mon:"Monday",tue:"Tuesday",wed:"Wednesday",thu:"Thursday",fri:"Friday",sat:"Saturday"}}},dayPeriods:{format:{wide:{am:"AM",pm:"PM"}}},eras:{eraNames:{0:"Before Christ","0-alt-variant":"Before Common Era",1:"Anno Domini","1-alt-variant":"Common Era"},eraAbbr:{0:"BC","0-alt-variant":"BCE",1:"AD","1-alt-variant":"CE"},eraNarrow:{0:"B","0-alt-variant":"BCE",1:"A","1-alt-variant":"CE"}},dateFormats:{full:"EEEE, MMMM d, y",long:"MMMM d, y",medium:"MMM d, y",short:"M/d/yy"},timeFormats:{full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},dateTimeFormats:{full:"{1} 'at' {0}",long:"{1} 'at' {0}",medium:"{1}, {0}",short:"{1}, {0}",availableFormats:{d:"d",E:"ccc",Ed:"d E",Ehm:"E h:mm a",EHm:"E HH:mm",Ehms:"E h:mm:ss a",EHms:"E HH:mm:ss",Gy:"y G",GyMMM:"MMM y G",GyMMMd:"MMM d, y G",GyMMMEd:"E, MMM d, y G",h:"h a",H:"HH",hm:"h:mm a",Hm:"HH:mm",hms:"h:mm:ss a",Hms:"HH:mm:ss",hmsv:"h:mm:ss a v",Hmsv:"HH:mm:ss v",hmv:"h:mm a v",Hmv:"HH:mm v",M:"L",Md:"M/d",MEd:"E, M/d",MMM:"LLL",MMMd:"MMM d",MMMEd:"E, MMM d",MMMMd:"MMMM d",ms:"mm:ss",y:"y",yM:"M/y",yMd:"M/d/y",yMEd:"E, M/d/y",yMMM:"MMM y",yMMMd:"MMM d, y",yMMMEd:"E, MMM d, y",yMMMM:"MMMM y"}}},islamic:{months:{"stand-alone":{abbreviated:{1:"Muh.",2:"Saf.",3:"Rab. I",4:"Rab. II",5:"Jum. I",6:"Jum. II",7:"Raj.",8:"Sha.",9:"Ram.",10:"Shaw.",11:"Dhu\u02bbl-Q.",12:"Dhu\u02bbl-H."},narrow:{1:"1",2:"2",3:"3",4:"4",5:"5",6:"6",7:"7",8:"8",9:"9",10:"10",11:"11",12:"12"},wide:{1:"Muharram",2:"Safar",3:"Rabi\u02bb I",4:"Rabi\u02bb II",5:"Jumada I",6:"Jumada II",7:"Rajab",8:"Sha\u02bbban",9:"Ramadan",10:"Shawwal",11:"Dhu\u02bbl-Qi\u02bbdah",12:"Dhu\u02bbl-Hijjah"}}},days:{"stand-alone":{abbreviated:{sun:"Sun",mon:"Mon",tue:"Tue",wed:"Wed",thu:"Thu",fri:"Fri",sat:"Sat"},narrow:{sun:"S",mon:"M",tue:"T",wed:"W",thu:"T",fri:"F",sat:"S"},short:{sun:"Su",mon:"Mo",tue:"Tu",wed:"We",thu:"Th",fri:"Fr",sat:"Sa"},wide:{sun:"Sunday",mon:"Monday",tue:"Tuesday",wed:"Wednesday",thu:"Thursday",fri:"Friday",sat:"Saturday"}}},dayPeriods:{format:{wide:{am:"AM",pm:"PM"}}},eras:{eraNames:{0:"AH"},eraAbbr:{0:"AH"},eraNarrow:{0:"AH"}},dateFormats:{full:"EEEE, MMMM d, y G",long:"MMMM d, y G",medium:"MMM d, y G",short:"M/d/y GGGGG"},timeFormats:{full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},dateTimeFormats:{full:"{1} 'at' {0}",long:"{1} 'at' {0}",medium:"{1}, {0}",short:"{1}, {0}",availableFormats:{d:"d",E:"ccc",Ed:"d E",Ehm:"E h:mm a",EHm:"E HH:mm",Ehms:"E h:mm:ss a",EHms:"E HH:mm:ss",Gy:"y G",GyMMM:"MMM y G",GyMMMd:"MMM d, y G",GyMMMEd:"E, MMM d, y G",h:"h a",H:"HH",hm:"h:mm a",Hm:"HH:mm",hms:"h:mm:ss a",Hms:"HH:mm:ss",M:"L",Md:"M/d",MEd:"E, M/d",MMM:"LLL",MMMd:"MMM d",MMMEd:"E, MMM d",MMMMd:"MMMM d",ms:"mm:ss",y:"y G",yyyy:"y G",yyyyM:"M/y GGGGG",yyyyMd:"M/d/y GGGGG",yyyyMEd:"E, M/d/y GGGGG",yyyyMMM:"MMM y G",yyyyMMMd:"MMM d, y G",yyyyMMMEd:"E, MMM d, y G",yyyyMMMM:"MMMM y G",yyyyQQQ:"QQQ y G",yyyyQQQQ:"QQQQ y G"}}}},timeZoneNames:{hourFormat:"+HH:mm;-HH:mm",gmtFormat:"GMT{0}",gmtZeroFormat:"GMT"}},numbers:{currencies:{USD:{displayName:"US Dollar",symbol:"$","symbol-alt-narrow":"$"},EUR:{displayName:"Euro",symbol:"\u20ac","symbol-alt-narrow":"\u20ac"},GBP:{displayName:"British Pound","symbol-alt-narrow":"\xa3"}},defaultNumberingSystem:"latn",minimumGroupingDigits:"1","symbols-numberSystem-latn":{decimal:".",group:",",list:";",percentSign:"%",plusSign:"+",minusSign:"-",exponential:"E",superscriptingExponent:"\xd7",perMille:"\u2030",infinity:"\u221e",nan:"NaN",timeSeparator:":"},"decimalFormats-numberSystem-latn":{standard:"#,##0.###"},"percentFormats-numberSystem-latn":{standard:"#,##0%"},"currencyFormats-numberSystem-latn":{standard:"\xa4#,##0.00",accounting:"\xa4#,##0.00;(\xa4#,##0.00)"},"scientificFormats-numberSystem-latn":{standard:"#E0"}}},n.blazorDefaultObject={numbers:{mapper:{0:"0",1:"1",2:"2",3:"3",4:"4",5:"5",6:"6",7:"7",8:"8",9:"9"},mapperDigits:"0123456789",numberSymbols:{decimal:".",group:",",plusSign:"+",minusSign:"-",percentSign:"%",nan:"NaN",timeSeparator:":",infinity:"\u221e"},timeSeparator:":",currencySymbol:"$",currencypData:{nlead:"$",nend:"",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},percentpData:{nlead:"",nend:"%",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},percentnData:{nlead:"-",nend:"%",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},currencynData:{nlead:"($",nend:")",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},decimalnData:{nlead:"-",nend:"",groupData:{primary:3},maximumFraction:2,minimumFraction:2},decimalpData:{nlead:"",nend:"",groupData:{primary:3},maximumFraction:2,minimumFraction:2}},dates:{dayPeriods:{am:"AM",pm:"PM"},dateSeperator:"/",days:{abbreviated:{sun:"Sun",mon:"Mon",tue:"Tue",wed:"Wed",thu:"Thu",fri:"Fri",sat:"Sat"},short:{sun:"Su",mon:"Mo",tue:"Tu",wed:"We",thu:"Th",fri:"Fr",sat:"Sa"},wide:{sun:"Sunday",mon:"Monday",tue:"Tuesday",wed:"Wednesday",thu:"Thursday",fri:"Friday",sat:"Saturday"}},months:{abbreviated:{1:"Jan",2:"Feb",3:"Mar",4:"Apr",5:"May",6:"Jun",7:"Jul",8:"Aug",9:"Sep",10:"Oct",11:"Nov",12:"Dec"},wide:{1:"January",2:"February",3:"March",4:"April",5:"May",6:"June",7:"July",8:"August",9:"September",10:"October",11:"November",12:"December"}},eras:{1:"AD"}}},n.monthIndex={3:"abbreviated",4:"wide",5:"narrow",1:"abbreviated"},n.month="months",n.days="days",n.patternMatcher={C:"currency",P:"percent",N:"decimal",A:"currency",E:"scientific"},n.getResultantPattern=l,n.getDependables=h,n.getSymbolPattern=c,n.ConvertDateToWeekFormat=d,n.compareBlazorDateFormats=u,n.getProperNumericSkeleton=p,n.getFormatData=f,n.changeCurrencySymbol=g,n.getCurrencySymbol=v,n.customFormat=function y(T,P,_){for(var B={},j=T.split(";"),Q=["pData","nData","zeroData"],oe=0;oe1,pe.nData=ce()?Y(De.type+"nData",oe):f(ot[1]||"-"+ot[0],!0,Ie),pe.pData=ce()?Y(De.type+"pData",oe):f(ot[0],!1,Ie),!Me[2]&&!P.minimumFractionDigits&&!P.maximumFractionDigits&&(ue=f(Ve.split(";")[0],!0,"",!0).minimumFraction)}if(n.formatRegex.test(P.format)||!P.format){if(ze(Q,p(P.format||"N")),Q.custom=!1,$e="###0",(Q.fractionDigits||P.minimumFractionDigits||P.maximumFractionDigits||ue)&&(Q.fractionDigits&&(P.minimumFractionDigits=P.maximumFractionDigits=Q.fractionDigits),$e=A($e,ue||Q.fractionDigits||P.minimumFractionDigits||0,P.maximumFractionDigits||0)),P.minimumIntegerDigits&&($e=x($e,P.minimumIntegerDigits)),P.useGrouping&&($e=R($e)),"currency"===Q.type||Q.type&&ce()){ce()&&"currency"!==Q.type&&(pe.pData=Y(Q.type+"pData",oe),pe.nData=Y(Q.type+"nData",oe));var hr=$e;$e=pe.pData.nlead+hr+pe.pData.nend,(pe.hasNegativePattern||ce())&&($e+=";"+pe.nData.nlead+hr+pe.nData.nend)}"percent"===Q.type&&!ce()&&($e+=" %")}else $e=P.format.replace(/'/g,'"');return Object.keys(xe).length>0&&($e=B?$e:C($e,xe)),$e},n.fractionDigitsPattern=A,n.minimumIntegerPattern=x,n.groupingPattern=R,n.getWeekData=function L(T,P){var _="sun",B=Y("supplemental.weekData.firstDay",P),j=T;return/en-/.test(j)&&(j=j.slice(3)),j=j.slice(0,2).toUpperCase()+j.substr(2),B&&(_=B[""+j]||B[j.slice(0,2)]||"sun"),o[""+_]},n.replaceBlazorCurrency=function O(T,P,_){var B=function d$(n){return Y(n||"",c$)}(_);if(P!==B)for(var j=0,Q=T;j=0?_:_+7;var j=Math.floor((T.getTime()-P.getTime()-6e4*(T.getTimezoneOffset()-P.getTimezoneOffset()))/864e5)+1;if(_<4){if((B=Math.floor((j+_-1)/7)+1)>52){var oe=new Date(T.getFullYear()+1,0,1).getDay();B=(oe=oe>=0?oe:oe+7)<4?1:53}}else B=Math.floor((j+_-1)/7);return B}}(ut||(ut={}));var tp=function(){function n(t,e,i){this.type="GET",this.emitError=!0,"string"==typeof t?(this.url=t,this.type=m(e)?this.type:e.toUpperCase(),this.contentType=i):Aa(t)&&Object.keys(t).length>0&&Nn(this,t),this.contentType=m(this.contentType)?"application/json; charset=utf-8":this.contentType}return n.prototype.send=function(t){var e=this,i={"application/json":"json","multipart/form-data":"formData","application/octet-stream":"blob","application/x-www-form-urlencoded":"formData"};try{m(this.fetchRequest)&&"GET"===this.type?this.fetchRequest=new Request(this.url,{method:this.type}):m(this.fetchRequest)&&(this.data=m(t)?this.data:t,this.fetchRequest=new Request(this.url,{method:this.type,headers:{"Content-Type":this.contentType},body:this.data}));var r={cancel:!1,fetchRequest:this.fetchRequest};return this.triggerEvent(this.beforeSend,r),r.cancel?null:(this.fetchResponse=fetch(this.fetchRequest),this.fetchResponse.then(function(s){if(e.triggerEvent(e.onLoad,s),!s.ok)throw s;for(var o="text",a=0,l=Object.keys(i);a-1},n.getValue=function(t,e){var i=typeof window<"u"?window.browserDetails:{};return typeof navigator<"u"&&"MacIntel"===navigator.platform&&navigator.maxTouchPoints>1&&!0===n.isTouch&&!fC.CHROME.test(navigator.userAgent)&&(i.isIos=!0,i.isDevice=!0,i.isTouch=!0,i.isPointer=!0),typeof window<"u"&&window.Capacitor&&"ios"===window.Capacitor.getPlatform()&&(i.isPointer=!1),typeof i[""+t]>"u"?i[""+t]=e.test(n.userAgent):i[""+t]},Object.defineProperty(n,"userAgent",{get:function(){return n.uA},set:function(t){n.uA=t,window.browserDetails={}},enumerable:!0,configurable:!0}),Object.defineProperty(n,"info",{get:function(){return st(window.browserDetails.info)?window.browserDetails.info=n.extractBrowserDetail():window.browserDetails.info},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isIE",{get:function(){return n.getValue("isIE",x$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isTouch",{get:function(){return st(window.browserDetails.isTouch)?window.browserDetails.isTouch="ontouchstart"in window.navigator||window&&window.navigator&&window.navigator.maxTouchPoints>0||"ontouchstart"in window:window.browserDetails.isTouch},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isPointer",{get:function(){return st(window.browserDetails.isPointer)?window.browserDetails.isPointer="pointerEnabled"in window.navigator:window.browserDetails.isPointer},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isMSPointer",{get:function(){return st(window.browserDetails.isMSPointer)?window.browserDetails.isMSPointer="msPointerEnabled"in window.navigator:window.browserDetails.isMSPointer},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isDevice",{get:function(){return n.getValue("isDevice",D$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isIos",{get:function(){return n.getValue("isIos",A$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isIos7",{get:function(){return n.getValue("isIos7",L$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isAndroid",{get:function(){return n.getValue("isAndroid",N$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isWebView",{get:function(){return st(window.browserDetails.isWebView)&&(window.browserDetails.isWebView=!(st(window.cordova)&&st(window.PhoneGap)&&st(window.phonegap)&&"object"!==window.forge)),window.browserDetails.isWebView},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isWindows",{get:function(){return n.getValue("isWindows",O$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"touchStartEvent",{get:function(){return st(window.browserDetails.touchStartEvent)?window.browserDetails.touchStartEvent=n.getTouchStartEvent():window.browserDetails.touchStartEvent},enumerable:!0,configurable:!0}),Object.defineProperty(n,"touchMoveEvent",{get:function(){return st(window.browserDetails.touchMoveEvent)?window.browserDetails.touchMoveEvent=n.getTouchMoveEvent():window.browserDetails.touchMoveEvent},enumerable:!0,configurable:!0}),Object.defineProperty(n,"touchEndEvent",{get:function(){return st(window.browserDetails.touchEndEvent)?window.browserDetails.touchEndEvent=n.getTouchEndEvent():window.browserDetails.touchEndEvent},enumerable:!0,configurable:!0}),Object.defineProperty(n,"touchCancelEvent",{get:function(){return st(window.browserDetails.touchCancelEvent)?window.browserDetails.touchCancelEvent=n.getTouchCancelEvent():window.browserDetails.touchCancelEvent},enumerable:!0,configurable:!0}),n.uA=typeof navigator<"u"?navigator.userAgent:"",n}(),E=function(){function n(){}return n.addOrGetEventData=function(t){return"__eventList"in t?t.__eventList.events:(t.__eventList={},t.__eventList.events=[])},n.add=function(t,e,i,r,s){var a,o=n.addOrGetEventData(t);a=s?function o$(n,t){var e;return function(){for(var i=this,r=[],s=0;s"u"||(e.innerHTML=t.innerHTML?t.innerHTML:"",void 0!==t.className&&(e.className=t.className),void 0!==t.id&&(e.id=t.id),void 0!==t.styles&&e.setAttribute("style",t.styles),void 0!==t.attrs&&Fe(e,t.attrs)),e}function V(n,t){for(var e=Vz(t),i=RegExp,r=0,s=n;r0}function pl(n,t,e){for(var i=document.createDocumentFragment(),r=0,s=n;r0;)i.appendChild(n[0]);else for(var r=0,s=n;r-1&&!r[parseInt(s.toString(),10)].match(/\[.*\]/)){var o=r[parseInt(s.toString(),10)].split("#");if(o[1].match(/^\d/)||o[1].match(t)){var a=r[parseInt(s.toString(),10)].split(".");a[0]=a[0].replace(/#/,"[id='")+"']",r[parseInt(s.toString(),10)]=a.join(".")}}e[parseInt(i.toString(),10)]=r.join(" ")}return e.join(",")}return n}function J(n,t){var e=n;if("function"==typeof e.closest)return e.closest(t);for(;e&&1===e.nodeType;){if(gC(e,t))return e;e=e.parentNode}return null}function je(n,t){void 0!==t&&Object.keys(t).forEach(function(e){n.style[""+e]=t[""+e]})}function gC(n,t){var e=n.matches||n.msMatchesSelector||n.webkitMatchesSelector;return e?e.call(n,t):-1!==[].indexOf.call(document.querySelectorAll(t),n)}var z$=new RegExp("]"),ah=function(){function n(t,e){this.isRendered=!1,this.isComplexArraySetter=!1,this.isServerRendered=!1,this.allowServerDataBinding=!0,this.isProtectedOnChange=!0,this.properties={},this.changedProperties={},this.oldProperties={},this.bulkChanges={},this.refreshing=!1,this.ignoreCollectionWatch=!1,this.finalUpdate=function(){},this.childChangedProperties={},this.modelObserver=new Tg(this),st(e)||(this.element="string"==typeof e?document.querySelector(e):e,m(this.element)||(this.isProtectedOnChange=!1,this.addInstance())),st(t)||this.setProperties(t,!0),this.isDestroyed=!1}return n.prototype.setProperties=function(t,e){var i=this.isProtectedOnChange;this.isProtectedOnChange=!!e,Nn(this,t),!0!==e?(Nn(this.changedProperties,t),this.dataBind()):ce()&&this.isRendered&&this.serverDataBind(t),this.finalUpdate(),this.changedProperties={},this.oldProperties={},this.isProtectedOnChange=i},n.callChildDataBind=function(t,e){for(var r=0,s=Object.keys(t);r=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Hs=function(n){function t(i){var r=n.call(this,i,void 0)||this;return r.easing={ease:"cubic-bezier(0.250, 0.100, 0.250, 1.000)",linear:"cubic-bezier(0.250, 0.250, 0.750, 0.750)",easeIn:"cubic-bezier(0.420, 0.000, 1.000, 1.000)",easeOut:"cubic-bezier(0.000, 0.000, 0.580, 1.000)",easeInOut:"cubic-bezier(0.420, 0.000, 0.580, 1.000)",elasticInOut:"cubic-bezier(0.5,-0.58,0.38,1.81)",elasticIn:"cubic-bezier(0.17,0.67,0.59,1.81)",elasticOut:"cubic-bezier(0.7,-0.75,0.99,1.01)"},r}var e;return Q$(t,n),e=t,t.prototype.animate=function(i,r){var s=this.getModel(r=r||{});if("string"==typeof i)for(var a=0,l=Array.prototype.slice.call(we(i,document));a0?r-1:0,i+=e=-1!==e?"-"+e:"-"+r}return this.controlParent!==this.parentObj&&(i=this.parentObj.getParentKey()+"."+this.propName+e),i},n}(),$$=["grid","pivotview","treegrid","spreadsheet","rangeNavigator","DocumentEditor","listbox","inplaceeditor","PdfViewer","richtexteditor","DashboardLayout","chart","stockChart","circulargauge","diagram","heatmap","lineargauge","maps","slider","smithchart","barcode","sparkline","treemap","bulletChart","kanban","daterangepicker","schedule","gantt","signature","query-builder","drop-down-tree","carousel","filemanager","uploader","accordion","tab","treeview"],tR=[115,121,110,99,102,117,115,105,111,110,46,105,115,76,105,99,86,97,108,105,100,97,116,101,100],iR=function(){function n(t){this.isValidated=!1,this.isLicensed=!0,this.version="27",this.platform=/JavaScript|ASPNET|ASPNETCORE|ASPNETMVC|FileFormats|essentialstudio/i,this.errors={noLicense:"This application was built using a trial version of Syncfusion Essential Studio. To remove the license validation message permanently, a valid license key must be included.",trailExpired:"This application was built using a trial version of Syncfusion Essential Studio. To remove the license validation message permanently, a valid license key must be included.",versionMismatched:"The included Syncfusion license key is invalid.",platformMismatched:"The included Syncfusion license key is invalid.",invalidKey:"The included Syncfusion license key is invalid."},this.manager=function(){var e=null;return{setKey:function i(s){e=s},getKey:function r(){return e}}}(),this.npxManager=function(){return{getKey:function i(){return"npxKeyReplace"}}}(),this.manager.setKey(t)}return n.prototype.validate=function(){if(!this.isValidated&&Ku&&!Y(E0(tR),Ku)&&!Y("Blazor",Ku)){var i=void 0,r=void 0;if(this.manager&&this.manager.getKey()||this.npxManager&&"npxKeyReplace"!==this.npxManager.getKey()){var s=this.getInfoFromKey();if(s&&s.length)for(var o=0,a=s;o"+i+' Claim your FREE account\n
have a Syncfusion account? Sign In
\n
\n ';if(typeof document<"u"&&!m(document)){var t=mi("div",{innerHTML:n});document.body.appendChild(t)}}(),oR=!0),this.render(),this.mount?this.accessMount():this.trigger("created")}},t.prototype.renderComplete=function(e){ce()&&window.sfBlazor.renderComplete(this.element,e),this.isRendered=!0},t.prototype.dataBind=function(){this.injectModules(),n.prototype.dataBind.call(this)},t.prototype.on=function(e,i,r){if("string"==typeof e)this.localObserver.on(e,i,r);else for(var s=0,o=e;s=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},tZ={left:0,top:0,bottom:0,right:0},IC={isDragged:!1},iZ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return aR(t,n),gr([I(0)],t.prototype,"left",void 0),gr([I(0)],t.prototype,"top",void 0),t}(Ee),np=function(n){function t(i,r){var s=n.call(this,r,i)||this;return s.dragLimit=e.getDefaultPosition(),s.borderWidth=e.getDefaultPosition(),s.padding=e.getDefaultPosition(),s.diffX=0,s.prevLeft=0,s.prevTop=0,s.dragProcessStarted=!1,s.eleTop=0,s.tapHoldTimer=0,s.externalInitialize=!1,s.diffY=0,s.parentScrollX=0,s.parentScrollY=0,s.droppables={},s.bind(),s}var e;return aR(t,n),e=t,t.prototype.bind=function(){this.toggleEvents(),X.isIE&&V([this.element],"e-block-touch"),this.droppables[this.scope]={}},t.getDefaultPosition=function(){return ze({},tZ)},t.prototype.toggleEvents=function(i){var r;st(this.handle)||(r=U(this.handle,this.element));var s=this.enableTapHold&&X.isDevice&&X.isTouch?this.mobileInitialize:this.initialize;i?E.remove(r||this.element,X.isSafari()?"touchstart":X.touchStartEvent,s):E.add(r||this.element,X.isSafari()?"touchstart":X.touchStartEvent,s,this)},t.prototype.mobileInitialize=function(i){var r=this,s=i.currentTarget;this.tapHoldTimer=setTimeout(function(){r.externalInitialize=!0,r.removeTapholdTimer(),r.initialize(i,s)},this.tapHoldThreshold),E.add(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.removeTapholdTimer,this),E.add(document,X.isSafari()?"touchend":X.touchEndEvent,this.removeTapholdTimer,this)},t.prototype.removeTapholdTimer=function(){clearTimeout(this.tapHoldTimer),E.remove(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.removeTapholdTimer),E.remove(document,X.isSafari()?"touchend":X.touchEndEvent,this.removeTapholdTimer)},t.prototype.getScrollableParent=function(i,r){return m(i)?null:i[{vertical:"scrollHeight",horizontal:"scrollWidth"}[""+r]]>i[{vertical:"clientHeight",horizontal:"clientWidth"}[""+r]]&&("vertical"===r?i.scrollTop>0:i.scrollLeft>0)?("vertical"===r?(this.parentScrollY=this.parentScrollY+(0===this.parentScrollY?i.scrollTop:i.scrollTop-this.parentScrollY),this.tempScrollHeight=i.scrollHeight):(this.parentScrollX=this.parentScrollX+(0===this.parentScrollX?i.scrollLeft:i.scrollLeft-this.parentScrollX),this.tempScrollWidth=i.scrollWidth),m(i)?i:this.getScrollableParent(i.parentNode,r)):this.getScrollableParent(i.parentNode,r)},t.prototype.getScrollableValues=function(){this.parentScrollX=0,this.parentScrollY=0,this.element.classList.contains("e-dialog")&&this.element.classList.contains("e-dlg-modal"),this.getScrollableParent(this.element.parentNode,"vertical"),this.getScrollableParent(this.element.parentNode,"horizontal")},t.prototype.initialize=function(i,r){if(this.currentStateTarget=i.target,!this.isDragStarted()){if(this.isDragStarted(!0),this.externalInitialize=!1,this.target=i.currentTarget||r,this.dragProcessStarted=!1,this.abort){var s=this.abort;"string"==typeof s&&(s=[s]);for(var o=0;o=this.distance||this.externalInitialize){var p=this.getHelperElement(i);if(!p||m(p))return;r&&i.preventDefault();var f=this.helperElement=p;if(this.parentClientRect=this.calculateParentPosition(f.offsetParent),this.dragStart){var v={event:i,element:l,target:this.getProperTargetElement(i),bindEvents:ce()?this.bindDragEvents.bind(this):null,dragElement:f};this.trigger("dragStart",v)}this.dragArea?this.setDragArea():(this.dragLimit={left:0,right:0,bottom:0,top:0},this.borderWidth={top:0,left:0}),o={left:this.position.left-this.parentClientRect.left,top:this.position.top-this.parentClientRect.top},this.clone&&!this.enableTailMode&&(this.diffX=this.position.left-this.offset.left,this.diffY=this.position.top-this.offset.top),this.getScrollableValues();var y=getComputedStyle(l),S=parseFloat(y.marginTop);this.clone&&0!==S&&(o.top+=S),this.eleTop=isNaN(parseFloat(y.top))?0:parseFloat(y.top)-this.offset.top,this.enableScrollHandler&&!this.clone&&(o.top-=this.parentScrollY,o.left-=this.parentScrollX);var b=this.getProcessedPositionValue({top:o.top-this.diffY+"px",left:o.left-this.diffX+"px"});this.dragArea&&"string"!=typeof this.dragArea&&this.dragArea.classList.contains("e-kanban-content")&&"relative"===this.dragArea.style.position&&(o.top+=this.dragArea.scrollTop),this.dragElePosition={top:o.top,left:o.left},je(f,this.getDragPosition({position:"absolute",left:b.left,top:b.top})),E.remove(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.intDragStart),E.remove(document,X.isSafari()?"touchend":X.touchEndEvent,this.intDestroy),ce()||this.bindDragEvents(f)}}},t.prototype.bindDragEvents=function(i){Tr(i)?(E.add(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.intDrag,this),E.add(document,X.isSafari()?"touchend":X.touchEndEvent,this.intDragStop,this),this.setGlobalDroppables(!1,this.element,i)):(this.toggleEvents(),document.body.classList.remove("e-prevent-select"))},t.prototype.elementInViewport=function(i){for(this.top=i.offsetTop,this.left=i.offsetLeft,this.width=i.offsetWidth,this.height=i.offsetHeight;i.offsetParent;)this.top+=(i=i.offsetParent).offsetTop,this.left+=i.offsetLeft;return this.top>=window.pageYOffset&&this.left>=window.pageXOffset&&this.top+this.height<=window.pageYOffset+window.innerHeight&&this.left+this.width<=window.pageXOffset+window.innerWidth},t.prototype.getProcessedPositionValue=function(i){return this.queryPositionInfo?this.queryPositionInfo(i):i},t.prototype.calculateParentPosition=function(i){if(m(i))return{left:0,top:0};var r=i.getBoundingClientRect(),s=getComputedStyle(i);return{left:r.left+window.pageXOffset-parseInt(s.marginLeft,10),top:r.top+window.pageYOffset-parseInt(s.marginTop,10)}},t.prototype.intDrag=function(i){if(st(i.changedTouches)||1===i.changedTouches.length){var r,s;this.clone&&i.changedTouches&&X.isDevice&&X.isTouch&&i.preventDefault(),this.position=this.getMousePosition(i,this.isDragScroll);var o=this.getDocumentWidthHeight("Height");oy&&y>0?this.dragLimit.left:this.dragLimit.right+window.pageXOffset0?y-(y-this.dragLimit.right)+window.pageXOffset-M:y<0?this.dragLimit.left:y}if(this.pageY!==v||this.skipDistanceCheck){var w=d.offsetHeight+(parseFloat(b.marginTop)+parseFloat(b.marginBottom));s=this.dragLimit.top>S&&S>0?this.dragLimit.top:this.dragLimit.bottom+window.pageYOffset0?S-(S-this.dragLimit.bottom)+window.pageYOffset-w:S<0?this.dragLimit.top:S}}else r=y,s=S;var A,x,C=p+this.borderWidth.top,D=u+this.borderWidth.left;if(this.dragProcessStarted&&(m(s)&&(s=this.prevTop),m(r)&&(r=this.prevLeft)),this.helperElement.classList.contains("e-treeview"))this.dragArea?(this.dragLimit.top=this.clone?this.dragLimit.top:0,A=s-C<0?this.dragLimit.top:s-this.borderWidth.top,x=r-D<0?this.dragLimit.left:r-this.borderWidth.left):(A=s-this.borderWidth.top,x=r-this.borderWidth.left);else if(this.dragArea){var R=this.helperElement.classList.contains("e-dialog");this.dragLimit.top=this.clone?this.dragLimit.top:0,A=s-C<0?this.dragLimit.top:s-C,x=r-D<0?R?r-(D-this.borderWidth.left):this.dragElePosition.left:r-D}else A=s-C,x=r-D;var L=parseFloat(getComputedStyle(this.element).marginTop);if(L>0&&(this.clone&&(A+=L,S<0&&(L+S>=0?A=L+S:A-=L),this.dragArea&&(A=this.dragLimit.bottom=0){var O=this.dragLimit.top+S-C;O+L+C<0?A-=L+C:A=O}else A-=L+C;this.dragArea&&this.helperElement.classList.contains("e-treeview")&&(A=A+(w=d.offsetHeight+(parseFloat(b.marginTop)+parseFloat(b.marginBottom)))>this.dragLimit.bottom?this.dragLimit.bottom-w:A),this.enableScrollHandler&&!this.clone&&(A-=this.parentScrollY,x-=this.parentScrollX),this.dragArea&&"string"!=typeof this.dragArea&&this.dragArea.classList.contains("e-kanban-content")&&"relative"===this.dragArea.style.position&&(A+=this.dragArea.scrollTop);var N=this.getProcessedPositionValue({top:A+"px",left:x+"px"});this.isPreventScroll&&(N=this.getProcessedPositionValue({top:this.position.top-this.parentClientRect.top-2+"px",left:this.position.left-this.parentClientRect.left-2+"px"})),je(d,this.getDragPosition(N)),!this.elementInViewport(d)&&this.enableAutoScroll&&!this.helperElement.classList.contains("e-treeview")&&this.helperElement.scrollIntoView();var T=document.querySelectorAll(":hover");if(this.enableAutoScroll&&this.helperElement.classList.contains("e-treeview")){0===T.length&&(T=this.getPathElements(i));var P=this.getScrollParent(T,!1);this.elementInViewport(this.helperElement)?this.getScrollPosition(P,A):this.elementInViewport(this.helperElement)||(0===(T=[].slice.call(document.querySelectorAll(":hover"))).length&&(T=this.getPathElements(i)),P=this.getScrollParent(T,!0),this.getScrollPosition(P,A))}this.dragProcessStarted=!0,this.prevLeft=r,this.prevTop=s,this.position.left=r,this.position.top=s,this.pageX=g,this.pageY=v}},t.prototype.getScrollParent=function(i,r){for(var o,s=r?i.reverse():i,a=s.length-1;a>=0;a--)if(("auto"===(o=window.getComputedStyle(s[parseInt(a.toString(),10)])["overflow-y"])||"scroll"===o)&&s[parseInt(a.toString(),10)].scrollHeight>s[parseInt(a.toString(),10)].clientHeight)return s[parseInt(a.toString(),10)];if("visible"===(o=window.getComputedStyle(document.scrollingElement)["overflow-y"]))return document.scrollingElement.style.overflow="auto",document.scrollingElement},t.prototype.getScrollPosition=function(i,r){if(i&&i===document.scrollingElement)i.clientHeight+document.scrollingElement.scrollTop-this.helperElement.clientHeightr?i.scrollTop+=this.helperElement.clientHeight:i.scrollTop>r-this.helperElement.clientHeight&&(i.scrollTop-=this.helperElement.clientHeight);else if(i&&i!==document.scrollingElement){var s=document.scrollingElement.scrollTop,o=this.helperElement.clientHeight;i.clientHeight+i.getBoundingClientRect().top-o+sr-o-s&&(i.scrollTop-=this.helperElement.clientHeight)}},t.prototype.getPathElements=function(i){return document.elementsFromPoint(i.clientX>0?i.clientX:0,i.clientY>0?i.clientY:0)},t.prototype.triggerOutFunction=function(i,r){this.hoverObject.instance.intOut(i,r.target),this.hoverObject.instance.dragData[this.scope]=null,this.hoverObject=null},t.prototype.getDragPosition=function(i){var r=ze({},i);return this.axis&&("x"===this.axis?delete r.top:"y"===this.axis&&delete r.left),r},t.prototype.getDocumentWidthHeight=function(i){var r=document.body,s=document.documentElement;return Math.max(r["scroll"+i],s["scroll"+i],r["offset"+i],s["offset"+i],s["client"+i])},t.prototype.intDragStop=function(i){if(this.dragProcessStarted=!1,st(i.changedTouches)||1===i.changedTouches.length){if(-1!==["touchend","pointerup","mouseup"].indexOf(i.type)){if(this.dragStop){var s=this.getProperTargetElement(i);this.trigger("dragStop",{event:i,element:this.element,target:s,helper:this.helperElement})}this.intDestroy(i)}else this.element.setAttribute("aria-grabbed","false");var o=this.checkTargetElement(i);o.target&&o.instance&&(o.instance.dragStopCalled=!0,o.instance.dragData[this.scope]=this.droppables[this.scope],o.instance.intDrop(i,o.target)),this.setGlobalDroppables(!0),document.body.classList.remove("e-prevent-select")}},t.prototype.intDestroy=function(i){this.dragProcessStarted=!1,this.toggleEvents(),document.body.classList.remove("e-prevent-select"),this.element.setAttribute("aria-grabbed","false"),E.remove(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.intDragStart),E.remove(document,X.isSafari()?"touchend":X.touchEndEvent,this.intDragStop),E.remove(document,X.isSafari()?"touchend":X.touchEndEvent,this.intDestroy),E.remove(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.intDrag),this.isDragStarted()&&this.isDragStarted(!0)},t.prototype.onPropertyChanged=function(i,r){},t.prototype.getModuleName=function(){return"draggable"},t.prototype.isDragStarted=function(i){return i&&(IC.isDragged=!IC.isDragged),IC.isDragged},t.prototype.setDragArea=function(){var i,r,a,s=0,o=0;if(a="string"==typeof this.dragArea?U(this.dragArea):this.dragArea){var h=a.getBoundingClientRect();i=a.scrollWidth?a.scrollWidth:h.right-h.left,r=a.scrollHeight?this.dragArea&&!m(this.helperElement)&&this.helperElement.classList.contains("e-treeview")?a.clientHeight:a.scrollHeight:h.bottom-h.top;for(var c=["Top","Left","Bottom","Right"],d=getComputedStyle(a),u=0;u12;return b0(i.target,this.helperElement)||-1!==i.type.indexOf("touch")||a?(this.helperElement.style.pointerEvents="none",s=document.elementFromPoint(r.clientX,r.clientY),this.helperElement.style.pointerEvents=o):s=i.target,s},t.prototype.currentStateCheck=function(i,r){return m(this.currentStateTarget)||this.currentStateTarget===i?m(r)?i:r:this.currentStateTarget},t.prototype.getMousePosition=function(i,r){var a,l,s=void 0!==i.srcElement?i.srcElement:i.target,o=this.getCoordinates(i),h=m(s.offsetParent);if(r?(a=this.clone?o.pageX:o.pageX+(h?0:s.offsetParent.scrollLeft)-this.relativeXPosition,l=this.clone?o.pageY:o.pageY+(h?0:s.offsetParent.scrollTop)-this.relativeYPosition):(a=this.clone?o.pageX:o.pageX+window.pageXOffset-this.relativeXPosition,l=this.clone?o.pageY:o.pageY+window.pageYOffset-this.relativeYPosition),document.scrollingElement&&!r&&!this.clone){var c=document.scrollingElement;a=c.scrollWidth>0&&c.scrollWidth>c.clientWidth&&c.scrollLeft>0?a-c.scrollLeft:a,l=c.scrollHeight>0&&c.scrollHeight>c.clientHeight&&c.scrollTop>0?l-c.scrollTop:l}return{left:a-(this.margin.left+this.cursorAt.left),top:l-(this.margin.top+this.cursorAt.top)}},t.prototype.getCoordinates=function(i){return i.type.indexOf("touch")>-1?i.changedTouches[0]:i},t.prototype.getHelperElement=function(i){var r;return this.clone?this.helper?r=this.helper({sender:i,element:this.target}):(r=mi("div",{className:"e-drag-helper e-block-touch",innerHTML:"Draggable"}),document.body.appendChild(r)):r=this.element,r},t.prototype.setGlobalDroppables=function(i,r,s){this.droppables[this.scope]=i?null:{draggable:r,helper:s,draggedElement:this.element}},t.prototype.checkTargetElement=function(i){var r=this.getProperTargetElement(i),s=this.getDropInstance(r);if(!s&&r&&!m(r.parentNode)){var o=J(r.parentNode,".e-droppable")||r.parentElement;o&&(s=this.getDropInstance(o))}return{target:r,instance:s}},t.prototype.getDropInstance=function(i){var s,o=i&&i.ej2_instances;if(o)for(var a=0,l=o;a=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},lR=function(n){function t(e,i){var r=n.call(this,i,e)||this;return r.mouseOver=!1,r.dragData={},r.dragStopCalled=!1,r.bind(),r}return rZ(t,n),t.prototype.bind=function(){this.wireEvents()},t.prototype.wireEvents=function(){E.add(this.element,X.isSafari()?"touchend":X.touchEndEvent,this.intDrop,this)},t.prototype.onPropertyChanged=function(e,i){},t.prototype.getModuleName=function(){return"droppable"},t.prototype.intOver=function(e,i){this.mouseOver||(this.trigger("over",{event:e,target:i,dragData:this.dragData[this.scope]}),this.mouseOver=!0)},t.prototype.intOut=function(e,i){this.mouseOver&&(this.trigger("out",{evt:e,target:i}),this.mouseOver=!1)},t.prototype.intDrop=function(e,i){if(this.dragStopCalled){this.dragStopCalled=!1;var a,r=!0,s=this.dragData[this.scope],o=!!s&&s.helper&&Tr(s.helper);o&&(a=this.isDropArea(e,s.helper,i),this.accept&&(r=gC(s.helper,this.accept))),o&&this.drop&&a.canDrop&&r&&this.trigger("drop",{event:e,target:a.target,droppedElement:s.helper,dragData:s}),this.mouseOver=!1}},t.prototype.isDropArea=function(e,i,r){var s={canDrop:!0,target:r||e.target},o="touchend"===e.type;if(o||s.target===i){i.style.display="none";var a=o?e.changedTouches[0]:e,l=document.elementFromPoint(a.clientX,a.clientY);s.canDrop=!1,s.canDrop=b0(l,this.element),s.canDrop&&(s.target=l),i.style.display=""}return s},t.prototype.destroy=function(){E.remove(this.element,X.isSafari()?"touchend":X.touchEndEvent,this.intDrop),n.prototype.destroy.call(this)},sp([I()],t.prototype,"accept",void 0),sp([I("default")],t.prototype,"scope",void 0),sp([H()],t.prototype,"drop",void 0),sp([H()],t.prototype,"over",void 0),sp([H()],t.prototype,"out",void 0),sp([Ft],t)}(ah),ho=function(){function n(t,e,i){this.controlName=t,this.localeStrings=e,this.setLocale(i||"en-US")}return n.prototype.setLocale=function(t){var e=this.intGetControlConstant(n.locale,t);this.currentLocale=e||this.localeStrings},n.load=function(t){this.locale=ze(this.locale,t,{},!0)},n.prototype.getConstant=function(t){return m(this.currentLocale[""+t])?this.localeStrings[""+t]||"":this.currentLocale[""+t]},n.prototype.intGetControlConstant=function(t,e){return t[""+e]?t[""+e][this.controlName]:null},n.locale={},n}(),hR=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),hh=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},oZ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return hR(t,n),hh([I(50)],t.prototype,"swipeThresholdDistance",void 0),t}(Ee),aZ=/(Up|Down)/,Fs=function(n){function t(e,i){var r=n.call(this,i,e)||this;return r.touchAction=!0,r.tapCount=0,r.startEvent=function(s){if(!0===r.touchAction){var o=r.updateChangeTouches(s);void 0!==s.changedTouches&&(r.touchAction=!1),r.isTouchMoved=!1,r.movedDirection="",r.startPoint=r.lastMovedPoint={clientX:o.clientX,clientY:o.clientY},r.startEventData=o,r.hScrollLocked=r.vScrollLocked=!1,r.tStampStart=Date.now(),r.timeOutTapHold=setTimeout(function(){r.tapHoldEvent(s)},r.tapHoldThreshold),E.add(r.element,X.touchMoveEvent,r.moveEvent,r),E.add(r.element,X.touchEndEvent,r.endEvent,r),E.add(r.element,X.touchCancelEvent,r.cancelEvent,r)}},r.moveEvent=function(s){var o=r.updateChangeTouches(s);r.movedPoint=o,r.isTouchMoved=!(o.clientX===r.startPoint.clientX&&o.clientY===r.startPoint.clientY);var a={};r.isTouchMoved&&(clearTimeout(r.timeOutTapHold),r.calcScrollPoints(s),a=ze(a,{},{startEvents:r.startEventData,originalEvent:s,startX:r.startPoint.clientX,startY:r.startPoint.clientY,distanceX:r.distanceX,distanceY:r.distanceY,scrollDirection:r.scrollDirection,velocity:r.getVelocity(o)}),r.trigger("scroll",a),r.lastMovedPoint={clientX:o.clientX,clientY:o.clientY})},r.cancelEvent=function(s){clearTimeout(r.timeOutTapHold),clearTimeout(r.timeOutTap),r.tapCount=0,r.swipeFn(s),E.remove(r.element,X.touchCancelEvent,r.cancelEvent)},r.endEvent=function(s){r.swipeFn(s),r.isTouchMoved||"function"==typeof r.tap&&(r.trigger("tap",{originalEvent:s,tapCount:++r.tapCount}),r.timeOutTap=setTimeout(function(){r.tapCount=0},r.tapThreshold)),r.modeclear()},r.swipeFn=function(s){clearTimeout(r.timeOutTapHold),clearTimeout(r.timeOutTap);var o=r.updateChangeTouches(s),a=o.clientX-r.startPoint.clientX,l=o.clientY-r.startPoint.clientY;a=Math.floor(a<0?-1*a:a),l=Math.floor(l<0?-1*l:a),r.isTouchMoved=a>1||l>1,/Firefox/.test(X.userAgent)&&0===o.clientX&&0===o.clientY&&"mouseup"===s.type&&(r.isTouchMoved=!1),r.endPoint=o,r.calcPoints(s);var c={originalEvent:s,startEvents:r.startEventData,startX:r.startPoint.clientX,startY:r.startPoint.clientY,distanceX:r.distanceX,distanceY:r.distanceY,swipeDirection:r.movedDirection,velocity:r.getVelocity(o)};if(r.isTouchMoved){var d=r.swipeSettings.swipeThresholdDistance,u=ze(void 0,r.defaultArgs,c),p=!1,f=r.element,g=r.isScrollable(f),v=aZ.test(r.movedDirection);(dthis.distanceY?i.clientX>this.startPoint.clientX?"Right":"Left":i.clientYthis.distanceY||!0===this.hScrollLocked)&&!1===this.vScrollLocked?(this.scrollDirection=i.clientX>this.lastMovedPoint.clientX?"Right":"Left",this.hScrollLocked=!0):(this.scrollDirection=i.clientY=e[r[0]+s[0]]},t.prototype.updateChangeTouches=function(e){return e.changedTouches&&0!==e.changedTouches.length?e.changedTouches[0]:e},hh([H()],t.prototype,"tap",void 0),hh([H()],t.prototype,"tapHold",void 0),hh([H()],t.prototype,"swipe",void 0),hh([H()],t.prototype,"scroll",void 0),hh([I(350)],t.prototype,"tapThreshold",void 0),hh([I(750)],t.prototype,"tapHoldThreshold",void 0),hh([re({},oZ)],t.prototype,"swipeSettings",void 0),hh([Ft],t)}(ah),lZ=new RegExp("\\n|\\r|\\s\\s+","g"),hZ=new RegExp(/'|"/g),cZ=new RegExp("if ?\\("),dZ=new RegExp("else if ?\\("),cR=new RegExp("else"),uZ=new RegExp("for ?\\("),dR=new RegExp("(/if|/for)"),pZ=new RegExp("\\((.*)\\)",""),bC=new RegExp("^[0-9]+$","g"),fZ=new RegExp("[\\w\"'.\\s+]+","g"),gZ=new RegExp('"(.*?)"',"g"),vZ=new RegExp("[\\w\"'@#$.\\s-+]+","g"),uR=new RegExp("\\${([^}]*)}","g"),mZ=/^\..*/gm,MC=/\\/gi,yZ=/\\\\/gi,SZ=new RegExp("[\\w\"'@#$.\\s+]+","g"),IZ=/\window\./gm;function op(n,t,e,i,r){return!t||bC.test(n)||-1!==i.indexOf(n.split(".")[0])||r||"true"===n||"false"===n?n:e+"."+n}function wC(n,t,e,i){return t&&!bC.test(n)&&-1===i.indexOf(n.split(".")[0])?e+'["'+n:n}function pR(n){return n.match(yZ)?n:n.replace(MC,"\\\\")}function fR(n,t,e,i){if(n=n.trim(),/\window\./gm.test(n))return n;var s=/'|"/gm;return/@|\$|#/gm.test(n)&&(n=wC(n,-1===e.indexOf(n),t,e)+'"]'),mZ.test(n)?function wZ(n,t,e,i){return!t||bC.test(n)||-1!==i.indexOf(n.split(".")[0])||/^\..*/gm.test(n)?n:e+"."+n}(n,!s.test(n)&&-1===e.indexOf(n),t,e):op(n,!s.test(n)&&-1===e.indexOf(n),t,e,i)}var CZ=/^[\n\r.]+0&&t.forEach(function(e){he(e)})},n.removeJsEvents=function(){var t=this.wrapElement.querySelectorAll("["+vR.join("],[")+"]");t.length>0&&t.forEach(function(e){vR.forEach(function(i){e.hasAttribute(i)&&e.removeAttribute(i)})})},n.removeXssAttrs=function(){var t=this;this.removeAttrs.forEach(function(e,i){var r=t.wrapElement.querySelectorAll(e.selector);r.length>0&&r.forEach("a[href]"===e.selector?function(s){-1!==s.getAttribute(e.attribute).replace(/\t|\s|&/,"").indexOf("javascript:alert")&&s.removeAttribute(e.attribute)}:function(s){s.removeAttribute(e.attribute)})})},n}();function NZ(n){for(var t,e=n.childNodes,i=0;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Jo_RTL=(new Tg,"e-rtl"),ys=function(n){function t(e,i){return n.call(this,e,i)||this}return PZ(t,n),t.prototype.preRender=function(){},t.prototype.render=function(){this.initialize(),this.removeRippleEffect=function ms(n,t,e){var i=function G$(n){return{selector:n&&n.selector?n.selector:null,ignore:n&&n.ignore?n.ignore:null,rippleFlag:n&&n.rippleFlag,isCenterRipple:n&&n.isCenterRipple,duration:n&&n.duration?n.duration:350}}(t);return!1===i.rippleFlag||void 0===i.rippleFlag&&!Zo?function(){}:(n.setAttribute("data-ripple","true"),E.add(n,"mousedown",Zz,{parent:n,rippleOptions:i}),E.add(n,"mouseup",Jz,{parent:n,rippleOptions:i,done:e}),E.add(n,"mouseleave",rp,{parent:n,rippleOptions:i}),X.isPointer&&E.add(n,"transitionend",rp,{parent:n,rippleOptions:i}),function(){n.removeAttribute("data-ripple"),E.remove(n,"mousedown",Zz),E.remove(n,"mouseup",Jz),E.remove(n,"mouseleave",rp),E.remove(n,"transitionend",rp)})}(this.element,{selector:".e-btn"}),this.renderComplete()},t.prototype.initialize=function(){if(this.cssClass&&V([this.element],this.cssClass.replace(/\s+/g," ").trim().split(" ")),this.isPrimary&&this.element.classList.add("e-primary"),!ce()||ce()&&"progress-btn"!==this.getModuleName()){if(this.content){var e=this.enableHtmlSanitizer?Ti.sanitize(this.content):this.content;this.element.innerHTML=e}this.setIconCss()}this.enableRtl&&this.element.classList.add(Jo_RTL),this.disabled?this.controlStatus(this.disabled):this.wireEvents()},t.prototype.controlStatus=function(e){this.element.disabled=e},t.prototype.setIconCss=function(){if(this.iconCss){var e=this.createElement("span",{className:"e-btn-icon "+this.iconCss});this.element.textContent.trim()?(e.classList.add("e-icon-"+this.iconPosition.toLowerCase()),("Top"===this.iconPosition||"Bottom"===this.iconPosition)&&this.element.classList.add("e-"+this.iconPosition.toLowerCase()+"-icon-btn")):this.element.classList.add("e-icon-btn");var i=this.element.childNodes[0];!i||"Left"!==this.iconPosition&&"Top"!==this.iconPosition?this.element.appendChild(e):this.element.insertBefore(e,i)}},t.prototype.wireEvents=function(){this.isToggle&&E.add(this.element,"click",this.btnClickHandler,this)},t.prototype.unWireEvents=function(){this.isToggle&&E.remove(this.element,"click",this.btnClickHandler)},t.prototype.btnClickHandler=function(){this.element.classList.contains("e-active")?this.element.classList.remove("e-active"):this.element.classList.add("e-active")},t.prototype.destroy=function(){var e=["e-primary",Jo_RTL,"e-icon-btn","e-success","e-info","e-danger","e-warning","e-flat","e-outline","e-small","e-bigger","e-active","e-round","e-top-icon-btn","e-bottom-icon-btn"];this.cssClass&&(e=e.concat(this.cssClass.split(" "))),n.prototype.destroy.call(this),K([this.element],e),this.element.getAttribute("class")||this.element.removeAttribute("class"),this.disabled&&this.element.removeAttribute("disabled"),this.content&&(this.element.innerHTML=this.element.innerHTML.replace(this.content,""));var i=this.element.querySelector("span.e-btn-icon");i&&he(i),this.unWireEvents(),Zo&&this.removeRippleEffect()},t.prototype.getModuleName=function(){return"btn"},t.prototype.getPersistData=function(){return this.addOnPersist([])},t.Inject=function(){},t.prototype.onPropertyChanged=function(e,i){for(var r=this.element.querySelector("span.e-btn-icon"),s=0,o=Object.keys(e);s=ad.width?ad.width:0;return vl.right+QR()-n}function lE(){return R0()+vl.width/2}function hE(n,t,e,i){if(void 0===t&&(t=null),void 0===e&&(e={X:!1,Y:!1}),!e.Y&&!e.X)return{left:0,top:0};var r=n.getBoundingClientRect();if(uo=t,sc=n.ownerDocument,i||(i=is(n,"left","top")),e.X){var s=uo?ZR():i4(),o=fE(),a=gE(),l=o-i.left,h=i.left+r.width-a;r.width>s?i.left=l>0&&h<=0?a-r.width:h>0&&l<=0?o:l>h?a-r.width:o:l>0?i.left+=l:h>0&&(i.left-=h)}if(e.Y){var c=uo?JR():t4(),d=pE(),u=vE(),p=d-i.top,f=i.top+r.height-u;r.height>c?i.top=p>0&&f<=0?u-r.height:f>0&&p<=0?d:p>f?u-r.height:d:p>0?i.top+=p:f>0&&(i.top-=f)}return i}function oc(n,t,e,i){void 0===t&&(t=null);var r=is(n,"left","top");e&&(r.left=e),i&&(r.top=i);var s=[];uo=t,sc=n.ownerDocument;var o=n.getBoundingClientRect(),l=r.left,h=r.left+o.width,d=uE(r.top,r.top+o.height),u=XR(l,h);return d.topSide&&s.push("top"),u.rightSide&&s.push("right"),u.leftSide&&s.push("left"),d.bottomSide&&s.push("bottom"),s}function cJ(n,t,e,i,r,s,o,a,l){if(void 0===o&&(o=null),void 0===a&&(a={X:!0,Y:!0}),t&&n&&r&&s&&(a.X||a.Y)){var d,h={TL:null,TR:null,BL:null,BR:null},c={TL:null,TR:null,BL:null,BR:null};if("none"===window.getComputedStyle(n).display){var u=n.style.visibility;n.style.visibility="hidden",n.style.display="block",d=n.getBoundingClientRect(),n.style.removeProperty("display"),n.style.visibility=u}else d=n.getBoundingClientRect();var p={posX:r,posY:s,offsetX:e,offsetY:i,position:{left:0,top:0}};uo=o,sc=t.ownerDocument,function uJ(n,t,e,i,r){e.position=is(n,e.posX,e.posY,i,r),t.TL=is(n,"left","top",i,r),t.TR=is(n,"right","top",i,r),t.BR=is(n,"left","bottom",i,r),t.BL=is(n,"right","bottom",i,r)}(t,h,p,l,d),dE(c,p,d),a.X&&qR(t,c,h,p,d,!0),a.Y&&h.TL.top>-1&&$R(t,c,h,p,d,!0),function dJ(n,t,e){var i=0,r=0;if(null!=n.offsetParent&&("absolute"===getComputedStyle(n.offsetParent).position||"relative"===getComputedStyle(n.offsetParent).position)){var s=is(n.offsetParent,"left","top",!1,e);i=s.left,r=s.top}var o=1,a=1,l=GR(n);if(l){var h=getComputedStyle(l).transform;if("none"!==h){var c=new DOMMatrix(h);o=c.a,a=c.d}if("none"!==getComputedStyle(l).zoom){var u=cE(document.body);o*=u,a*=u}}n.style.top=t.position.top/a+t.offsetY-r/a+"px",n.style.left=t.position.left/o+t.offsetX-i/o+"px"}(n,p,d)}}function cE(n){var t=getComputedStyle(n).zoom;return parseFloat(t)||1}function GR(n){for(;n;){var t=window.getComputedStyle(n).transform,e=cE(document.body);if(t&&"none"!==t||e&&1!==e)return n;if(n===document.body)return null;n=n.offsetParent||n.parentElement}return null}function dE(n,t,e){n.TL={top:t.position.top+t.offsetY,left:t.position.left+t.offsetX},n.TR={top:n.TL.top,left:n.TL.left+e.width},n.BL={top:n.TL.top+e.height,left:n.TL.left},n.BR={top:n.TL.top+e.height,left:n.TL.left+e.width}}function XR(n,t){var e=!1,i=!1;return n-B0()gE()&&(i=!0),{leftSide:e,rightSide:i}}function qR(n,t,e,i,r,s){var o=XR(t.TL.left,t.TR.left),a=uE(t.TL.top,t.BL.top);e.TL.left-B0()<=fE()&&(o.leftSide=!1),e.TR.left>gE()&&(o.rightSide=!1),(o.leftSide&&!o.rightSide||!o.leftSide&&o.rightSide)&&(i.posX="right"===i.posX?"left":"right",i.offsetX=i.offsetX+r.width,i.offsetX=-1*i.offsetX,i.position=is(n,i.posX,i.posY,!1),dE(t,i,r),s&&qR(n,t,e,i,r,!1),!o.leftSide&&o.rightSide&&a.bottomSide&&(i.offsetX=0))}function $R(n,t,e,i,r,s){var o=uE(t.TL.top,t.BL.top);e.TL.top-H0()<=pE()&&(o.topSide=!1),e.BL.top>=vE()&&n.getBoundingClientRect().bottomvE()&&(i=!0),{topSide:e,bottomSide:i}}function ZR(){return uo.getBoundingClientRect().width}function JR(){return uo.getBoundingClientRect().height}function KR(){return uo.getBoundingClientRect().left}function e4(){return uo.getBoundingClientRect().top}function pE(){return uo?e4():0}function fE(){return uo?KR():0}function gE(){return uo?B0()+KR()+ZR():B0()+i4()}function vE(){return uo?H0()+e4()+JR():H0()+t4()}function H0(){return sc.documentElement.scrollTop||sc.body.scrollTop}function B0(){return sc.documentElement.scrollLeft||sc.body.scrollLeft}function t4(){return window.innerHeight}function i4(){var n=window.innerWidth,t=document.documentElement.getBoundingClientRect();return n-(n-(m(document.documentElement)?0:t.width))}function r4(){uo=null,sc=null}var n4=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),bn=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},s4=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return n4(t,n),bn([I("left")],t.prototype,"X",void 0),bn([I("top")],t.prototype,"Y",void 0),t}(Ee),Gn_OPEN="e-popup-open",Gn_CLOSE="e-popup-close",ac=function(n){function t(e,i){return n.call(this,i,e)||this}return n4(t,n),t.prototype.onPropertyChanged=function(e,i){for(var r=0,s=Object.keys(e);r0&&c.left>0&&c.right>0&&c.bottom>0}var s=i.getBoundingClientRect();return!(r.bottoms.bottom||r.right>s.right||r.leftr.top?this.element.style.top="0px":s.bottomr.left&&(this.element.style.left=parseInt(this.element.style.left,10)+(s.left-r.left)+"px"))}},t.prototype.checkCollision=function(){var e=this.collision.X,i=this.collision.Y;"none"===e&&"none"===i||("flip"===e&&"flip"===i?this.callFlip({X:!0,Y:!0}):"fit"===e&&"fit"===i?this.callFit({X:!0,Y:!0}):("flip"===e?this.callFlip({X:!0,Y:!1}):"flip"===i&&this.callFlip({Y:!0,X:!1}),"fit"===e?this.callFit({X:!0,Y:!1}):"fit"===i&&this.callFit({X:!1,Y:!0})))},t.prototype.show=function(e,i){var r=this;if(this.getRelateToElement().classList.contains("e-filemanager")&&(this.fmDialogContainer=this.element.getElementsByClassName("e-file-select-wrap")[0]),this.wireEvents(),!m(this.fmDialogContainer)&&X.isIos&&(this.fmDialogContainer.style.display="block"),1e3===this.zIndex||!m(i)){var o=m(i)?this.element:i;this.zIndex=lc(o),je(this.element,{zIndex:this.zIndex})}e=m(e)||"object"!=typeof e?this.showAnimation:e,("none"!==this.collision.X||"none"!==this.collision.Y)&&(K([this.element],Gn_CLOSE),V([this.element],Gn_OPEN),this.checkCollision(),K([this.element],Gn_OPEN),V([this.element],Gn_CLOSE)),m(e)?(K([this.element],Gn_CLOSE),V([this.element],Gn_OPEN),this.trigger("open")):(e.begin=function(){r.isDestroyed||(K([r.element],Gn_CLOSE),V([r.element],Gn_OPEN))},e.end=function(){r.isDestroyed||r.trigger("open")},new Hs(e).animate(this.element))},t.prototype.hide=function(e){var i=this;e=m(e)||"object"!=typeof e?this.hideAnimation:e,m(e)?(K([this.element],Gn_OPEN),V([this.element],Gn_CLOSE),this.trigger("close")):(e.end=function(){i.isDestroyed||(K([i.element],Gn_OPEN),V([i.element],Gn_CLOSE),i.trigger("close"))},new Hs(e).animate(this.element)),this.unwireEvents()},t.prototype.getScrollableParent=function(e){return this.checkFixedParent(e),function mE(n,t){for(var e=getComputedStyle(n),i=[],r=/(auto|scroll)/,s=n.parentElement;s&&"HTML"!==s.tagName;){var o=getComputedStyle(s);!("absolute"===e.position&&"static"===o.position)&&r.test(o.overflow+o.overflowY+o.overflowX)&&i.push(s),s=s.parentElement}return t||i.push(document),i}(e,this.fixedParent)},t.prototype.checkFixedParent=function(e){for(var i=e.parentElement;i&&"HTML"!==i.tagName;){var r=getComputedStyle(i);("fixed"===r.position||"sticky"===r.position)&&!m(this.element)&&this.element.offsetParent&&"BODY"===this.element.offsetParent.tagName&&"hidden"!==getComputedStyle(this.element.offsetParent).overflow&&(this.element.style.top=window.scrollY>parseInt(this.element.style.top,10)?Re(window.scrollY-parseInt(this.element.style.top,10)):Re(parseInt(this.element.style.top,10)-window.scrollY),this.element.style.position="fixed",this.fixedParent=!0),i=i.parentElement,!m(this.element)&&m(this.element.offsetParent)&&"fixed"===r.position&&"fixed"===this.element.style.position&&(this.fixedParent=!0)}},bn([I("auto")],t.prototype,"height",void 0),bn([I("auto")],t.prototype,"width",void 0),bn([I(null)],t.prototype,"content",void 0),bn([I("container")],t.prototype,"targetType",void 0),bn([I(null)],t.prototype,"viewPortElement",void 0),bn([I({X:"none",Y:"none"})],t.prototype,"collision",void 0),bn([I("")],t.prototype,"relateTo",void 0),bn([re({},s4)],t.prototype,"position",void 0),bn([I(0)],t.prototype,"offsetX",void 0),bn([I(0)],t.prototype,"offsetY",void 0),bn([I(1e3)],t.prototype,"zIndex",void 0),bn([I(!1)],t.prototype,"enableRtl",void 0),bn([I("reposition")],t.prototype,"actionOnScroll",void 0),bn([I(null)],t.prototype,"showAnimation",void 0),bn([I(null)],t.prototype,"hideAnimation",void 0),bn([H()],t.prototype,"open",void 0),bn([H()],t.prototype,"close",void 0),bn([H()],t.prototype,"targetExitViewport",void 0),bn([Ft],t)}(yi);function lc(n){for(var t=n.parentElement,e=[];t&&"BODY"!==t.tagName;){var i=document.defaultView.getComputedStyle(t,null).getPropertyValue("z-index"),r=document.defaultView.getComputedStyle(t,null).getPropertyValue("position");"auto"!==i&&"static"!==r&&e.push(i),t=t.parentElement}for(var s=[],o=0;o2147483647?2147483647:c}var _i,Oa,ap,fh,bE,gh,Zt,vh,yE=["north-west","north","north-east","west","east","south-west","south","south-east"],jg="e-resize-handle",hc="e-focused-handle",pJ="e-dlg-resizable",o4=["e-restrict-left"],a4="e-resize-viewport",fJ=["north","west","east","south"],SE=0,IE=0,l4=0,h4=0,Vg=0,Wg=0,Yg=null,ME=null,wE=null,F0=!0,c4=0,CE=!0;function vJ(n){EE();var t=mi("span",{attrs:{unselectable:"on",contenteditable:"false"}});t.setAttribute("class","e-dialog-border-resize e-"+n),"south"===n&&(t.style.height="2px",t.style.width="100%",t.style.bottom="0px",t.style.left="0px"),"north"===n&&(t.style.height="2px",t.style.width="100%",t.style.top="0px",t.style.left="0px"),"east"===n&&(t.style.height="100%",t.style.width="2px",t.style.right="0px",t.style.top="0px"),"west"===n&&(t.style.height="100%",t.style.width="2px",t.style.left="0px",t.style.top="0px"),_i.appendChild(t)}function d4(n){var t;return m(n)||(t="string"==typeof n?document.querySelector(n):n),t}function u4(n){for(var t=n||this,e=_i.querySelectorAll("."+jg),i=0;i-1?"mouse":"touch"}function f4(n){if(n.preventDefault(),_i=n.target.parentElement,EE(),Vg=n.pageX,Wg=n.pageY,n.target.classList.add(hc),m(Yg)||!0!==Yg(n,this)){this.targetEle&&_i&&_i.querySelector("."+pJ)&&(Zt="body"===this.target?null:this.targetEle,gh=this.targetEle.clientWidth,fh=this.targetEle.clientHeight);var e=m(Zt)?document:Zt;E.add(e,"mousemove",Qg,this),E.add(document,"mouseup",_0,this);for(var i=0;i=0||s.top<0)&&(e=!0):e=!0;var a=IE+(r-Wg);a=a>ap?a:ap;var l=0;m(Zt)||(l=o.top);var h=m(Zt)?0:Zt.offsetHeight-Zt.clientHeight,c=s.top-l-h/2;if(c=c<0?0:c,s.top>0&&c+a>fh){if(e=!1,_i.classList.contains(a4))return;_i.style.height=fh-parseInt(c.toString(),10)+"px"}else{var d=0;if(e){s.top<0&&t+(s.height+s.top)>0&&a+(d=s.top)<=30&&(a=s.height-(s.height+s.top)+30),a+s.top>=fh&&(_i.style.height=s.height+(t-(s.height+s.top))+"px");var u=m(Zt)?d:c;a>=ap&&a+u<=fh&&(_i.style.height=a+"px")}}}function xE(n){var e,t=!1,i="mouse"===p4(n.type)?n.pageY:n.touches[0].pageY,r=cc(_i),s=m(Zt)?0:Zt.offsetHeight-Zt.clientHeight;m(Zt)||(e=cc(Zt)),(!m(Zt)&&r.top-e.top>0||m(Zt)&&i>0||!m(Zt)&&Math.floor(r.top-e.top+r.height+(e.bottom-r.bottom))-s<=fh)&&(t=!0);var o=IE-(i-Wg);if(t&&o>=ap&&o<=fh){var a=0;m(Zt)||(a=e.top);var l=h4-a+(i-Wg);l=l>0?l:1,_i.style.height=o+"px",_i.style.top=l+"px"}}function TE(n){var i,t=document.documentElement.clientWidth,e=!1;m(Zt)||(i=cc(Zt));var r="mouse"===p4(n.type)?n.pageX:n.touches[0].pageX,s=cc(_i),o=m(Zt)?0:Zt.offsetWidth-Zt.clientWidth,a=m(Zt)?0:i.left,l=m(Zt)?0:i.width;m(vh)&&(m(Zt)?vh=t:(vh=s.left-a-o/2+s.width,vh+=l-o-vh)),(!m(Zt)&&Math.floor(s.left-i.left+s.width+(i.right-s.right))-o<=gh||m(Zt)&&r>=0)&&(e=!0);var h=SE-(r-Vg);if(F0&&(h=h>vh?vh:h),e&&h>=bE&&h<=gh){var c=0;m(Zt)||(c=i.left);var d=l4-c+(r-Vg);d=d>0?d:1,h!==c4&&CE&&(_i.style.width=h+"px"),F0&&(_i.style.left=d+"px",CE=1!==d)}c4=h}function AE(n){var i,t=document.documentElement.clientWidth,e=!1;m(Zt)||(i=cc(Zt));var s=(n.touches?n.changedTouches[0]:n).pageX,o=cc(_i);(!m(Zt)&&(o.left-i.left+o.width<=gh||o.right-i.left>=o.width)||m(Zt)&&t-s>0)&&(e=!0);var a=SE+(s-Vg),l=0;if(m(Zt)||(l=i.left),o.left-l+a>gh){if(e=!1,_i.classList.contains(a4))return;_i.style.width=gh-(o.left-l)+"px"}e&&a>=bE&&a<=gh&&(_i.style.width=a+"px")}function v4(){for(var n=_i.querySelectorAll("."+jg),t=0;t=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},bJ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return LE(t,n),Jt([I(!0)],t.prototype,"isFlat",void 0),Jt([I()],t.prototype,"buttonModel",void 0),Jt([I("Button")],t.prototype,"type",void 0),Jt([H()],t.prototype,"click",void 0),t}(Ee),MJ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return LE(t,n),Jt([I("Fade")],t.prototype,"effect",void 0),Jt([I(400)],t.prototype,"duration",void 0),Jt([I(0)],t.prototype,"delay",void 0),t}(Ee),U0="e-dialog",NE="e-rtl",OE="e-dlg-header-content",m4="e-dlg-header",j0="e-footer-content",V0="e-dlg-modal",y4="e-icon-dlg-close",ml="e-dlg-target",ka="e-scroll-disabled",S4="e-device",W0="e-dlg-fullscreen",I4="e-dlg-closeicon-btn",b4="e-popup-open",M4="Information",w4="e-scroll-disabled",C4="e-alert-dialog",E4="e-confirm-dialog",kE="e-dlg-resizable",lp="e-restrict-left",D4="e-resize-viewport",PE="user action",zJ=function(n){function t(e,i){var r=n.call(this,e,i)||this;return r.needsID=!0,r}return LE(t,n),t.prototype.render=function(){this.initialize(),this.initRender(),this.wireEvents(),"100%"===this.width&&(this.element.style.width=""),""!==this.minHeight&&(this.element.style.minHeight=Re(this.minHeight)),this.enableResize&&(this.setResize(),this.isModal&&(this.isModelResize=!0),"None"===this.animationSettings.effect&&this.getMinHeight()),this.renderComplete()},t.prototype.initializeValue=function(){this.dlgClosedBy=PE},t.prototype.preRender=function(){var e=this;if(this.initializeValue(),this.headerContent=null,this.allowMaxHeight=!0,this.preventVisibility=!0,this.clonedEle=this.element.cloneNode(!0),this.closeIconClickEventHandler=function(s){e.dlgClosedBy="close icon",e.hide(s)},this.dlgOverlayClickEventHandler=function(s){e.dlgClosedBy="overlayClick",s.preventFocus=!1,e.trigger("overlayClick",s,function(o){o.preventFocus||e.focusContent(),e.dlgClosedBy=PE})},this.l10n=new ho("dialog",{close:"Close"},this.locale),this.checkPositionData(),m(this.target)){var r=this.isProtectedOnChange;this.isProtectedOnChange=!0,this.target=document.body,this.isProtectedOnChange=r}},t.prototype.updatePersistData=function(){this.enablePersistence&&this.setProperties({width:parseFloat(this.element.style.width),height:parseFloat(this.element.style.height),position:{X:parseFloat(this.dragObj.element.style.left),Y:parseFloat(this.dragObj.element.style.top)}},!0)},t.prototype.isNumberValue=function(e){return/^[-+]?\d*\.?\d+$/.test(e)},t.prototype.checkPositionData=function(){if(!m(this.position)){if(!m(this.position.X)&&"number"!=typeof this.position.X&&this.isNumberValue(this.position.X)){var i=this.isProtectedOnChange;this.isProtectedOnChange=!0,this.position.X=parseFloat(this.position.X),this.isProtectedOnChange=i}m(this.position.Y)||"number"==typeof this.position.Y||this.isNumberValue(this.position.Y)&&(i=this.isProtectedOnChange,this.isProtectedOnChange=!0,this.position.Y=parseFloat(this.position.Y),this.isProtectedOnChange=i)}},t.prototype.getEle=function(e,i){for(var r=void 0,s=0;s=0&&t[e])vJ(t[e]);else if(""!==t[e].trim()){var i=mi("div",{className:"e-icons "+jg+" e-"+t[e]});_i.appendChild(i)}ap=n.minHeight,bE=n.minWidth,gh=n.maxWidth,fh=n.maxHeight,n.proxy&&n.proxy.element&&n.proxy.element.classList.contains("e-dialog")?u4(n.proxy):u4()}({element:this.element,direction:r,minHeight:parseInt(e.slice(0,i.indexOf("p")),10),maxHeight:this.targetEle.clientHeight,minWidth:parseInt(i.slice(0,i.indexOf("p")),10),maxWidth:this.targetEle.clientWidth,boundary:this.target===document.body?null:this.targetEle,resizeBegin:this.onResizeStart.bind(this),resizeComplete:this.onResizeComplete.bind(this),resizing:this.onResizing.bind(this),proxy:this}),this.wireWindowResizeEvent()}else v4(),this.unWireWindowResizeEvent(),this.element.classList.remove(this.isModal?lp:D4),this.element.classList.remove(kE)},t.prototype.getFocusElement=function(e){var r=e.querySelectorAll('input,select,textarea,button:enabled,a,[contenteditable="true"],[tabindex]');return{element:r[r.length-1]}},t.prototype.keyDown=function(e){var i=this;if(9===e.keyCode&&this.isModal){var r=void 0;m(this.btnObj)||(r=this.btnObj[this.btnObj.length-1]),m(this.btnObj)&&!m(this.ftrTemplateContent)&&(r=this.getFocusElement(this.ftrTemplateContent)),m(this.btnObj)&&m(this.ftrTemplateContent)&&!m(this.contentEle)&&(r=this.getFocusElement(this.contentEle)),!m(r)&&document.activeElement===r.element&&!e.shiftKey&&(e.preventDefault(),this.focusableElements(this.element).focus()),document.activeElement===this.focusableElements(this.element)&&e.shiftKey&&(e.preventDefault(),m(r)||r.element.focus())}var h,s=document.activeElement,o=["input","textarea"].indexOf(s.tagName.toLowerCase())>-1,a=!1;if(o||(a=s.hasAttribute("contenteditable")&&"true"===s.getAttribute("contenteditable")),27===e.keyCode&&this.closeOnEscape){this.dlgClosedBy="escape";var l=document.querySelector(".e-popup-open:not(.e-dialog)");!m(l)&&!l.classList.contains("e-toolbar-pop")||this.hide(e)}(13===e.keyCode&&!e.ctrlKey&&"textarea"!==s.tagName.toLowerCase()&&o&&!m(this.primaryButtonEle)||13===e.keyCode&&e.ctrlKey&&("textarea"===s.tagName.toLowerCase()||a)&&!m(this.primaryButtonEle))&&this.buttons.some(function(d,u){h=u;var p=d.buttonModel;return!m(p)&&!0===p.isPrimary})&&"function"==typeof this.buttons[h].click&&setTimeout(function(){i.buttons[h].click.call(i,e)})},t.prototype.initialize=function(){m(this.target)||(this.targetEle="string"==typeof this.target?document.querySelector(this.target):this.target),this.isBlazorServerRender()||V([this.element],U0),X.isDevice&&V([this.element],S4),this.isBlazorServerRender()||this.setCSSClass(),this.setMaxHeight()},t.prototype.initRender=function(){var e=this;if(this.initialRender=!0,this.isBlazorServerRender()||Fe(this.element,{role:"dialog"}),1e3===this.zIndex?(this.setzIndex(this.element,!1),this.calculatezIndex=!0):this.calculatezIndex=!1,this.setTargetContent(),""!==this.header&&!m(this.header)&&this.setHeader(),this.renderCloseIcon(),this.setContent(),""===this.footerTemplate||m(this.footerTemplate)?!m(this.buttons[0])&&!m(this.buttons[0].buttonModel)&&this.setButton():this.setFooterTemplate(),this.allowDragging&&!m(this.headerContent)&&this.setAllowDragging(),Fe(this.element,{"aria-modal":this.isModal?"true":"false"}),this.isModal&&this.setIsModal(),!0!==this.element.classList.contains(C4)&&!0!==this.element.classList.contains(E4)&&!m(this.element.parentElement)){var i=this.isModal?this.dlgContainer.parentElement:this.element.parentElement;this.refElement=this.createElement("div",{className:"e-dlg-ref-element"}),i.insertBefore(this.refElement,this.isModal?this.dlgContainer:this.element)}if(m(this.targetEle)||this.targetEle.appendChild(this.isModal?this.dlgContainer:this.element),this.popupObj=new ac(this.element,{height:this.height,width:this.width,zIndex:this.zIndex,relateTo:this.target,actionOnScroll:"none",enableRtl:this.enableRtl,open:function(o){var a={container:e.isModal?e.dlgContainer:e.element,element:e.element,target:e.target,preventFocus:!1};e.enableResize&&e.resetResizeIcon(),e.trigger("open",a,function(l){l.preventFocus||e.focusContent()})},close:function(o){e.isModal&&V([e.dlgOverlay],"e-fade"),e.unBindEvent(e.element),e.isModal&&(e.dlgContainer.style.display="none"),e.trigger("close",e.closeArgs);var a=document.activeElement;!m(a)&&!m(a.blur)&&a.blur(),!m(e.storeActiveElement)&&!m(e.storeActiveElement.focus)&&e.storeActiveElement.focus()}}),this.positionChange(),this.setEnableRTL(),this.isBlazorServerRender()||(V([this.element],"e-popup-close"),this.isModal&&this.setOverlayZindex()),this.visible){if(this.show(),this.isModal){var r=this.getTargetContainer(this.target);r instanceof Element&&"rtl"===window.getComputedStyle(r).getPropertyValue("direction")&&this.setPopupPosition()}}else this.isModal&&(this.dlgOverlay.style.display="none");this.initialRender=!1},t.prototype.getTargetContainer=function(e){var i=null;if("string"==typeof e)if(e.startsWith("#"))i=document.getElementById(e.substring(1));else if(e.startsWith(".")){var r=document.getElementsByClassName(e.substring(1));i=r.length>0?r[0]:null}else!(e instanceof HTMLElement)&&e!==document.body&&(i=document.querySelector(e));else e instanceof HTMLElement&&(i=e);return i},t.prototype.resetResizeIcon=function(){var e=this.getMinHeight();if(this.targetEle.offsetHeight0&&("function"==typeof this.buttons[e].click&&E.add(s[e],"click",this.buttons[e].click,this),"object"==typeof this.buttons[e].click&&E.add(s[e],"click",this.buttonClickHandler.bind(this,e),this)),!this.isBlazorServerRender()&&!m(this.ftrTemplateContent)&&(this.btnObj[e].appendTo(this.ftrTemplateContent.children[e]),this.buttons[e].isFlat&&this.btnObj[e].element.classList.add("e-flat"),this.primaryButtonEle=this.element.getElementsByClassName("e-primary")[0]))},t.prototype.buttonClickHandler=function(e){this.trigger("buttons["+e+"].click",{})},t.prototype.setContent=function(){this.contentEle=this.createElement("div",{className:"e-dlg-content",id:this.element.id+"_dialog-content"}),Fe(this.element,this.headerEle?{"aria-describedby":this.element.id+"_title "+this.element.id+"_dialog-content"}:{"aria-describedby":this.element.id+"_dialog-content"}),this.innerContentElement?this.contentEle.appendChild(this.innerContentElement):(!m(this.content)&&""!==this.content||!this.initialRender)&&(("string"!=typeof this.content||ce())&&this.content instanceof HTMLElement?this.contentEle.appendChild(this.content):this.setTemplate(this.content,this.contentEle,"content")),m(this.headerContent)?this.element.insertBefore(this.contentEle,this.element.children[0]):this.element.insertBefore(this.contentEle,this.element.children[1]),"auto"===this.height&&(!this.isBlazorServerRender()&&X.isIE&&""===this.element.style.width&&!m(this.width)&&(this.element.style.width=Re(this.width)),this.setMaxHeight())},t.prototype.setTemplate=function(e,i,r){var s,o,a;o=i.classList.contains(m4)?this.element.id+"header":i.classList.contains(j0)?this.element.id+"footerTemplate":this.element.id+"content",m(e.outerHTML)?("string"==typeof e||"string"!=typeof e||ce()&&!this.isStringTemplate)&&("string"==typeof e&&(e=this.sanitizeHelper(e)),this.isVue||"string"!=typeof e?(s=ri(e),a=e):i.innerHTML=e):i.appendChild(e);var l=[];if(!m(s)){for(var c=0,d=s({},this,r,o,!(ce()&&!this.isStringTemplate&&0===a.indexOf("
Blazor"))||this.isStringTemplate);c/g,"");(this.element.children.length>0||i)&&(this.innerContentElement=document.createDocumentFragment(),[].slice.call(this.element.childNodes).forEach(function(r){8!==r.nodeType&&e.innerContentElement.appendChild(r)}))}},t.prototype.setHeader=function(){this.headerEle?this.headerEle.innerHTML="":this.headerEle=this.createElement("div",{id:this.element.id+"_title",className:m4}),this.createHeaderContent(),this.headerContent.appendChild(this.headerEle),this.setTemplate(this.header,this.headerEle,"header"),Fe(this.element,{"aria-describedby":this.element.id+"_title"}),Fe(this.element,{"aria-labelledby":this.element.id+"_dialog-header"}),this.element.insertBefore(this.headerContent,this.element.children[0]),this.allowDragging&&!m(this.headerContent)&&this.setAllowDragging()},t.prototype.setFooterTemplate=function(){this.ftrTemplateContent?this.ftrTemplateContent.innerHTML="":this.ftrTemplateContent=this.createElement("div",{className:j0}),""===this.footerTemplate||m(this.footerTemplate)?this.ftrTemplateContent.innerHTML=this.buttonContent.join(""):this.setTemplate(this.footerTemplate,this.ftrTemplateContent,"footerTemplate"),this.element.appendChild(this.ftrTemplateContent)},t.prototype.createHeaderContent=function(){m(this.headerContent)&&(this.headerContent=this.createElement("div",{id:this.element.id+"_dialog-header",className:OE}))},t.prototype.renderCloseIcon=function(){this.showCloseIcon&&(this.closeIcon=this.createElement("button",{className:I4,attrs:{type:"button"}}),this.closeIconBtnObj=new ys({cssClass:"e-flat",iconCss:y4+" e-icons"}),this.closeIconTitle(),m(this.headerContent)?(this.createHeaderContent(),pl([this.closeIcon],this.headerContent),this.element.insertBefore(this.headerContent,this.element.children[0])):pl([this.closeIcon],this.headerContent),this.closeIconBtnObj.appendTo(this.closeIcon))},t.prototype.closeIconTitle=function(){this.l10n.setLocale(this.locale);var e=this.l10n.getConstant("close");this.closeIcon.setAttribute("title",e),this.closeIcon.setAttribute("aria-label",e)},t.prototype.setCSSClass=function(e){e&&(K([this.element],e.split(" ")),this.isModal&&!m(this.dlgContainer)&&K([this.dlgContainer],e.split(" "))),this.cssClass&&(V([this.element],this.cssClass.split(" ")),this.isModal&&!m(this.dlgContainer)&&V([this.dlgContainer],this.cssClass.split(" ")))},t.prototype.setIsModal=function(){this.dlgContainer=this.createElement("div",{className:"e-dlg-container"}),this.setCSSClass(),this.element.classList.remove(b4),this.element.parentNode.insertBefore(this.dlgContainer,this.element),this.dlgContainer.appendChild(this.element),V([this.element],V0),this.dlgOverlay=this.createElement("div",{className:"e-dlg-overlay"}),this.dlgOverlay.style.zIndex=(this.zIndex-1).toString(),this.dlgContainer.appendChild(this.dlgOverlay)},t.prototype.getValidFocusNode=function(e){for(var i,r=0;r0||"a"===i.tagName.toLowerCase()&&i.hasAttribute("href"))&&i.tabIndex>-1&&!i.disabled&&!this.disableElement(i,'[disabled],[aria-disabled="true"],[type="hidden"]'))return i;i=null}return i},t.prototype.focusableElements=function(e){if(!m(e)){var r=e.querySelectorAll('input,select,textarea,button,a,[contenteditable="true"],[tabindex]');return this.getValidFocusNode(r)}return null},t.prototype.getAutoFocusNode=function(e){var i=e.querySelector("."+I4),s=e.querySelectorAll("[autofocus]"),o=this.getValidFocusNode(s);if(ce()&&(this.primaryButtonEle=this.element.getElementsByClassName("e-primary")[0]),m(o)){if(!m(o=this.focusableElements(this.contentEle)))return o;if(!m(this.primaryButtonEle))return this.element.querySelector(".e-primary")}else i=o;return i},t.prototype.disableElement=function(e,i){var r=e?e.matches||e.webkitMatchesSelector||e.msGetRegionContent:null;if(r)for(;e;e=e.parentNode)if(e instanceof Element&&r.call(e,i))return e;return null},t.prototype.focusContent=function(){var e=this.getAutoFocusNode(this.element),i=m(e)?this.element:e,r=X.userAgent;(r.indexOf("MSIE ")>0||r.indexOf("Trident/")>0)&&this.element.focus(),i.focus(),this.unBindEvent(this.element),this.bindEvent(this.element)},t.prototype.bindEvent=function(e){E.add(e,"keydown",this.keyDown,this)},t.prototype.unBindEvent=function(e){E.remove(e,"keydown",this.keyDown)},t.prototype.updateSanitizeContent=function(){this.isBlazorServerRender()||(this.contentEle.innerHTML=this.sanitizeHelper(this.content))},t.prototype.isBlazorServerRender=function(){return ce()&&this.isServerRendered},t.prototype.getModuleName=function(){return"dialog"},t.prototype.onPropertyChanged=function(e,i){if(this.element.classList.contains(U0))for(var r=0,s=Object.keys(e);r0?this.showCloseIcon||""!==this.header&&!m(this.header)?this.showCloseIcon||he(this.closeIcon):(he(this.headerContent),this.headerContent=null):(this.renderCloseIcon(),this.wireEvents());break;case"locale":this.showCloseIcon&&this.closeIconTitle();break;case"visible":this.visible?this.show():this.hide();break;case"isModal":this.updateIsModal();break;case"height":je(this.element,{height:Re(e.height)}),this.updatePersistData();break;case"width":je(this.element,{width:Re(e.width)}),this.updatePersistData();break;case"zIndex":this.popupObj.zIndex=this.zIndex,this.isModal&&this.setOverlayZindex(this.zIndex),this.element.style.zIndex!==this.zIndex.toString()&&(this.calculatezIndex=!1);break;case"cssClass":this.setCSSClass(i.cssClass);break;case"buttons":this.unWireButtonEvents(),this.destroyButtons(),m(this.ftrTemplateContent)||(he(this.ftrTemplateContent),this.ftrTemplateContent=null),this.footerTemplate="",this.setButton();break;case"allowDragging":this.allowDragging&&!m(this.headerContent)?this.setAllowDragging():this.dragObj.destroy();break;case"target":this.setTarget(e.target);break;case"position":if(this.checkPositionData(),this.isModal){var a=this.position.X,l=this.position.Y;m(i.position)||(m(i.position.X)||(a=i.position.X),m(i.position.Y)||(l=i.position.Y)),this.dlgContainer.classList.contains("e-dlg-"+a+"-"+l)&&this.dlgContainer.classList.remove("e-dlg-"+a+"-"+l)}this.positionChange(),this.updatePersistData();break;case"enableRtl":this.setEnableRTL();break;case"enableResize":this.setResize();break;case"minHeight":""!==this.minHeight&&(this.element.style.minHeight=Re(this.minHeight))}},t.prototype.setTarget=function(e){this.popupObj.relateTo=e,this.target=e,this.targetEle="string"==typeof this.target?document.querySelector(this.target):this.target,this.dragObj&&(this.dragObj.dragArea=this.targetEle),this.setMaxHeight(),this.isModal&&this.updateIsModal(),this.enableResize&&this.setResize()},t.prototype.updateIsModal=function(){if(this.element.setAttribute("aria-modal",this.isModal?"true":"false"),this.isModal)m(this.dlgOverlay)&&(this.setIsModal(),this.element.style.top="0px",this.element.style.left="0px",m(this.targetEle)||this.targetEle.appendChild(this.dlgContainer));else{for(K([this.element],V0),K([document.body],[ml,ka]),he(this.dlgOverlay);this.dlgContainer.firstChild;)this.dlgContainer.parentElement.insertBefore(this.dlgContainer.firstChild,this.dlgContainer);this.dlgContainer.parentElement.removeChild(this.dlgContainer)}this.visible&&this.show(),this.positionChange(),this.isModal&&this.dlgOverlay&&E.add(this.dlgOverlay,"click",this.dlgOverlayClickEventHandler,this)},t.prototype.setzIndex=function(e,i){var r=this.isProtectedOnChange;this.isProtectedOnChange=!0;var s=lc(e);this.zIndex=s>this.zIndex?s:this.zIndex,this.isProtectedOnChange=r,i&&(this.popupObj.zIndex=this.zIndex)},t.prototype.windowResizeHandler=function(){(function yJ(n){gh=n})(this.targetEle.clientWidth),function SJ(n){fh=n}(this.targetEle.clientHeight),this.setMaxHeight()},t.prototype.getPersistData=function(){return this.addOnPersist(["width","height","position"])},t.prototype.removeAllChildren=function(e){for(;e.children[0];)this.removeAllChildren(e.children[0]),e.removeChild(e.children[0])},t.prototype.destroy=function(){if(!this.isDestroyed){var e=[NE,V0,kE,lp,W0,S4],i=["role","aria-modal","aria-labelledby","aria-describedby","aria-grabbed","tabindex","style"];K([this.targetEle],[ml,ka]),!m(this.element)&&this.element.classList.contains(W0)&&K([document.body],[ml,ka]),this.isModal&&K([m(this.targetEle)?document.body:this.targetEle],ka),this.unWireEvents(),this.unWireButtonEvents(),this.destroyButtons(),m(this.closeIconBtnObj)||this.closeIconBtnObj.destroy(),m(this.dragObj)||this.dragObj.destroy(),!m(this.popupObj.element)&&this.popupObj.element.classList.contains("e-popup")&&this.popupObj.destroy(),K([this.element],e),!m(this.cssClass)&&""!==this.cssClass&&K([this.element],this.cssClass.split(" ")),!m(this.refElement)&&!m(this.refElement.parentElement)&&(this.refElement.parentElement.insertBefore(this.isModal?this.dlgContainer:this.element,this.refElement),he(this.refElement),this.refElement=void 0),this.isModal&&(he(this.dlgOverlay),this.dlgContainer.parentNode.insertBefore(this.element,this.dlgContainer),he(this.dlgContainer)),this.element.innerHTML=this.clonedEle.innerHTML;for(var r=0;r0&&""===this.footerTemplate&&this.ftrTemplateContent)for(var e=0;e=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},zE="e-tooltip",O4="e-icons",k4="e-tooltip-close",RE="e-tooltip-wrap",P4="e-tip-content",hp="e-arrow-tip",z4="e-arrow-tip-outer",Y0="e-arrow-tip-inner",Gg="e-tip-bottom",HE="e-tip-top",R4="e-tip-left",BE="e-tip-right",FE="e-popup",Xg="e-popup-open",_E="e-popup-close",Q0="e-lib",H4="e-tooltip-popup-container",UJ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return T4(t,n),Gi([I({effect:"FadeIn",duration:150,delay:0})],t.prototype,"open",void 0),Gi([I({effect:"FadeOut",duration:150,delay:0})],t.prototype,"close",void 0),t}(Ee),mh=function(n){function t(e,i){var r=n.call(this,e,i)||this;return r.mouseMoveEvent=null,r.mouseMoveTarget=null,r.containerElement=null,r.isBodyContainer=!0,r}return T4(t,n),t.prototype.initialize=function(){this.formatPosition(),V([this.element],zE)},t.prototype.formatPosition=function(){var e,i;this.position&&(0===this.position.indexOf("Top")||0===this.position.indexOf("Bottom")?(e=this.position.split(/(?=[A-Z])/),this.tooltipPositionY=e[0],this.tooltipPositionX=e[1]):(i=this.position.split(/(?=[A-Z])/),this.tooltipPositionX=i[0],this.tooltipPositionY=i[1]))},t.prototype.renderArrow=function(){this.setTipClass(this.position);var e=this.createElement("div",{className:hp+" "+this.tipClass});e.appendChild(this.createElement("div",{className:z4+" "+this.tipClass})),e.appendChild(this.createElement("div",{className:Y0+" "+this.tipClass})),this.tooltipEle.appendChild(e)},t.prototype.setTipClass=function(e){this.tipClass=0===e.indexOf("Right")?R4:0===e.indexOf("Bottom")?HE:0===e.indexOf("Left")?BE:Gg},t.prototype.renderPopup=function(e){var i=this.mouseTrail?{top:0,left:0}:this.getTooltipPosition(e);this.tooltipEle.classList.remove(Q0),this.popupObj=new ac(this.tooltipEle,{height:this.height,width:this.width,position:{X:i.left,Y:i.top},enableRtl:this.enableRtl,open:this.openPopupHandler.bind(this),close:this.closePopupHandler.bind(this)})},t.prototype.getScalingFactor=function(e){if(!e)return{x:1,y:1};var i={x:1,y:1},r=e.closest('[style*="transform: scale"]');if(r&&r!==this.tooltipEle&&r.contains(this.tooltipEle)){var a=window.getComputedStyle(r).getPropertyValue("transform").match(/matrix\(([^)]+)\)/)[1].split(",").map(parseFloat);i.x=a[0],i.y=a[3]}return i},t.prototype.getTooltipPosition=function(e){this.tooltipEle.style.display="block";var i=this.element.closest('[style*="zoom"]');i&&(i.contains(this.tooltipEle)||(this.tooltipEle.style.zoom=getComputedStyle(i).zoom));var r=is(e,this.tooltipPositionX,this.tooltipPositionY,!this.isBodyContainer,this.isBodyContainer?null:this.containerElement.getBoundingClientRect()),s=this.getScalingFactor(e),o=this.calculateTooltipOffset(this.position,s.x,s.y),a=this.calculateElementPosition(r,o),c=this.collisionFlipFit(e,a[0],a[1]);return c.left=c.left/s.x,c.top=c.top/s.y,this.tooltipEle.style.display="",c},t.prototype.windowResize=function(){this.reposition(this.findTarget())},t.prototype.reposition=function(e){if(this.popupObj&&e){var i=this.getTooltipPosition(e);this.popupObj.position={X:i.left,Y:i.top},this.popupObj.dataBind()}},t.prototype.openPopupHandler=function(){!this.mouseTrail&&this.needTemplateReposition()&&this.reposition(this.findTarget()),this.trigger("afterOpen",this.tooltipEventArgs),this.tooltipEventArgs=null},t.prototype.closePopupHandler=function(){this.isReact&&!("Click"===this.opensOn||"function"==typeof this.content)&&this.clearTemplate(["content"]),this.clear();var e={type:this.tooltipEventArgs.event?this.tooltipEventArgs.event.type:null,cancel:!1,target:this.tooltipEventArgs.target,event:this.tooltipEventArgs.event?this.tooltipEventArgs.event:null,element:this.tooltipEle,isInteracted:!m(this.tooltipEventArgs.event)};this.trigger("afterClose",e),e=null},t.prototype.calculateTooltipOffset=function(e,i,r){void 0===i&&(i=1),void 0===r&&(r=1);var o,a,l,h,c,d,u,p,s={top:0,left:0};if(1!==i||1!==r){var f=this.tooltipEle.getBoundingClientRect(),g=void 0;l=Math.round(f.width),h=Math.round(f.height),(c=U("."+hp,this.tooltipEle))&&(g=c.getBoundingClientRect()),o=c?Math.round(g.width):0,a=c?Math.round(g.height):0,d=this.showTipPointer?0:8,u=a/2+2+(h-this.tooltipEle.clientHeight*r),p=o/2+2+(l-this.tooltipEle.clientWidth*i)}else l=this.tooltipEle.offsetWidth,h=this.tooltipEle.offsetHeight,c=U("."+hp,this.tooltipEle),d=this.showTipPointer?0:8,u=(a=c?c.offsetHeight:0)/2+2+(this.tooltipEle.offsetHeight-this.tooltipEle.clientHeight),p=(o=c?c.offsetWidth:0)/2+2+(this.tooltipEle.offsetWidth-this.tooltipEle.clientWidth);switch(this.mouseTrail&&(d+=2),e){case"RightTop":s.left+=o+d,s.top-=h-u;break;case"RightCenter":s.left+=o+d,s.top-=h/2;break;case"RightBottom":s.left+=o+d,s.top-=u;break;case"BottomRight":s.top+=a+d,s.left-=p;break;case"BottomCenter":s.top+=a+d,s.left-=l/2;break;case"BottomLeft":s.top+=a+d,s.left-=l-p;break;case"LeftBottom":s.left-=o+l+d,s.top-=u;break;case"LeftCenter":s.left-=o+l+d,s.top-=h/2;break;case"LeftTop":s.left-=o+l+d,s.top-=h-u;break;case"TopLeft":s.top-=h+a+d,s.left-=l-p;break;case"TopRight":s.top-=h+a+d,s.left-=p;break;default:s.top-=h+a+d,s.left-=l/2}return s.left+=this.offsetX,s.top+=this.offsetY,s},t.prototype.updateTipPosition=function(e){var i=we("."+hp+",."+z4+",."+Y0,this.tooltipEle);K(i,[Gg,HE,R4,BE]),this.setTipClass(e),V(i,this.tipClass)},t.prototype.adjustArrow=function(e,i,r,s){var o=U("."+hp,this.tooltipEle);if(!1!==this.showTipPointer&&null!==o){var a,l;this.updateTipPosition(i),this.tooltipEle.style.display="block";var f,h=this.tooltipEle.clientWidth,c=this.tooltipEle.clientHeight,d=U("."+Y0,this.tooltipEle),u=o.offsetWidth,p=o.offsetHeight;this.tooltipEle.style.display="",this.tipClass===Gg||this.tipClass===HE?(this.tipClass===Gg?(l="99.9%",d.style.top="-"+(p-2)+"px"):(l=-(p-1)+"px",d.style.top="-"+(p-6)+"px"),e&&(a=(f="Center"!==r||h>e.offsetWidth||this.mouseTrail)&&"Left"===r||!f&&"End"===this.tipPointerPosition?h-u-2+"px":f&&"Right"===r||!f&&"Start"===this.tipPointerPosition?"2px":!f||"End"!==this.tipPointerPosition&&"Start"!==this.tipPointerPosition?h/2-u/2+"px":"End"===this.tipPointerPosition?e.offsetWidth+(this.tooltipEle.offsetWidth-e.offsetWidth)/2-u/2-2+"px":(this.tooltipEle.offsetWidth-e.offsetWidth)/2-u/2+2+"px")):(this.tipClass===BE?(a="99.9%",d.style.left="-"+(u-2)+"px"):(a=-(u-1)+"px",d.style.left=u-2-u+"px"),l=(f="Center"!==s||c>e.offsetHeight||this.mouseTrail)&&"Top"===s||!f&&"End"===this.tipPointerPosition?c-p-2+"px":f&&"Bottom"===s||!f&&"Start"===this.tipPointerPosition?"2px":c/2-p/2+"px"),o.style.top=l,o.style.left=a}},t.prototype.renderContent=function(e){var i=this,r=U("."+P4,this.tooltipEle);if(this.cssClass&&V([this.tooltipEle],this.cssClass.split(" ")),e&&!m(e.getAttribute("title"))&&(e.setAttribute("data-content",e.getAttribute("title")),e.removeAttribute("title")),m(this.content))e&&!m(e.getAttribute("data-content"))&&(r.innerHTML=e.getAttribute("data-content"));else if(r.innerHTML="",this.content instanceof HTMLElement)r.appendChild(this.content);else if("string"==typeof this.content)this.isAngular?this.setProperties({content:Ti.sanitize(this.content)},!0):this.content=this.enableHtmlSanitizer?Ti.sanitize(this.content):this.content,this.enableHtmlParse?(o=ri(this.content)({},this,"content",this.element.id+"content",void 0,void 0,r,this.root))&&Dt(o,r):r.textContent=this.content;else{var o;(o=ri(this.content)({},this,"content",this.element.id+"content",void 0,void 0,r))&&(this.isAngular&&setTimeout(function(){i.reposition(e)},1),Dt(o,r)),this.renderReactTemplates()}},t.prototype.renderCloseIcon=function(){if(this.isSticky){var i=this.createElement("div",{className:O4+" "+k4});this.tooltipEle.appendChild(i),E.add(i,X.touchStartEvent,this.onStickyClose,this)}else{var e=this.tooltipEle.querySelector("."+O4+"."+k4);e&>(e)}},t.prototype.addDescribedBy=function(e,i){var r=(e.getAttribute("aria-describedby")||"").split(/\s+/);r.indexOf(i)<0&&r.push(i),Fe(e,{"aria-describedby":r.join(" ").trim(),"data-tooltip-id":i})},t.prototype.removeDescribedBy=function(e){var i=e.getAttribute("data-tooltip-id"),r=(e.getAttribute("aria-describedby")||"").split(/\s+/),s=r.indexOf(i);-1!==s&&r.splice(s,1),e.removeAttribute("data-tooltip-id");var o=r.join(" ").trim();o?e.setAttribute("aria-describedby",o):e.removeAttribute("aria-describedby")},t.prototype.tapHoldHandler=function(e){clearTimeout(this.autoCloseTimer),this.targetHover(e.originalEvent)},t.prototype.touchEndHandler=function(){var e=this;this.isSticky||(this.autoCloseTimer=setTimeout(function(){e.close()},1500))},t.prototype.targetClick=function(e){var i;!m(i=this.target?J(e.target,this.target):this.element)&&(null===i.getAttribute("data-tooltip-id")?this.targetHover(e):this.isSticky||this.hideTooltip(this.animation.close,e,i))},t.prototype.targetHover=function(e){var i;if(!(m(i=this.target?J(e.target,this.target):this.element)||null!==i.getAttribute("data-tooltip-id")&&0===this.closeDelay)){for(var s=0,o=[].slice.call(we('[data-tooltip-id= "'+this.ctrlId+'_content"]',document));s0?this.showTimer=setTimeout(function(){o.mouseTrail&&E.add(i,"mousemove touchstart mouseenter",o.onMouseMove,o),o.popupObj&&(o.popupObj.show(a,i),o.mouseMoveEvent&&o.mouseTrail&&o.onMouseMove(o.mouseMoveEvent))},this.openDelay):this.popupObj&&this.popupObj.show(a,i)}s&&this.wireMouseEvents(s,i)},t.prototype.needTemplateReposition=function(){return!m(this.viewContainerRef)&&"string"!=typeof this.viewContainerRef||this.isReact},t.prototype.checkCollision=function(e,i,r){var s={left:i,top:r,position:this.position,horizontal:this.tooltipPositionX,vertical:this.tooltipPositionY},o=oc(this.tooltipEle,this.checkCollideTarget(),i,r);return o.length>0&&(s.horizontal=o.indexOf("left")>=0?"Right":o.indexOf("right")>=0?"Left":this.tooltipPositionX,s.vertical=o.indexOf("top")>=0?"Bottom":o.indexOf("bottom")>=0?"Top":this.tooltipPositionY),s},t.prototype.calculateElementPosition=function(e,i){return[this.isBodyContainer?e.left+i.left:e.left-this.containerElement.getBoundingClientRect().left+i.left+window.pageXOffset+this.containerElement.scrollLeft,this.isBodyContainer?e.top+i.top:e.top-this.containerElement.getBoundingClientRect().top+i.top+window.pageYOffset+this.containerElement.scrollTop]},t.prototype.collisionFlipFit=function(e,i,r){var s=this.checkCollision(e,i,r),o=s.position;if(this.tooltipPositionY!==s.vertical&&(o=0===this.position.indexOf("Bottom")||0===this.position.indexOf("Top")?s.vertical+this.tooltipPositionX:this.tooltipPositionX+s.vertical),this.tooltipPositionX!==s.horizontal&&(0===o.indexOf("Left")&&(s.vertical="LeftTop"===o||"LeftCenter"===o?"Top":"Bottom",o=s.vertical+"Left"),0===o.indexOf("Right")&&(s.vertical="RightTop"===o||"RightCenter"===o?"Top":"Bottom",o=s.vertical+"Right"),s.horizontal=this.tooltipPositionX),this.tooltipEventArgs={type:null,cancel:!1,target:e,event:null,element:this.tooltipEle,collidedPosition:o},this.trigger("beforeCollision",this.tooltipEventArgs),this.tooltipEventArgs.cancel)o=this.position;else{var a=s.vertical,l=s.horizontal;if(s.position!==o){var h=is(e,l,a,!this.isBodyContainer,this.isBodyContainer?null:this.containerElement.getBoundingClientRect());this.adjustArrow(e,o,l,a);var c=this.getScalingFactor(e),d=this.calculateTooltipOffset(o,c.x,c.y);d.top-=this.getOffSetPosition("TopBottom",o,this.offsetY),d.left-=this.getOffSetPosition("RightLeft",o,this.offsetX),s.position=o;var u=this.calculateElementPosition(h,d);s.left=u[0],s.top=u[1]}else this.adjustArrow(e,o,l,a)}var p={left:s.left,top:s.top},f=this.isBodyContainer?hE(this.tooltipEle,this.checkCollideTarget(),{X:!0,Y:this.windowCollision},p):p;this.tooltipEle.style.display="block";var g=U("."+hp,this.tooltipEle);if(this.showTipPointer&&null!=g&&(0===o.indexOf("Bottom")||0===o.indexOf("Top"))){var v=parseInt(g.style.left,10)-(f.left-s.left);v<0?v=0:v+g.offsetWidth>this.tooltipEle.clientWidth&&(v=this.tooltipEle.clientWidth-g.offsetWidth),g.style.left=v.toString()+"px"}return this.tooltipEle.style.display="",p.left=f.left,p.top=f.top,p},t.prototype.getOffSetPosition=function(e,i,r){return-1!==e.indexOf(this.position.split(/(?=[A-Z])/)[0])&&-1!==e.indexOf(i.split(/(?=[A-Z])/)[0])?2*r:0},t.prototype.checkCollideTarget=function(){return!this.windowCollision&&this.target?this.element:null},t.prototype.hideTooltip=function(e,i,r){var s=this;this.closeDelay>0?(clearTimeout(this.hideTimer),clearTimeout(this.showTimer),this.hideTimer=setTimeout(function(){s.closeDelay&&s.tooltipEle&&s.isTooltipOpen||s.tooltipHide(e,i,r)},this.closeDelay)):this.tooltipHide(e,i,r)},t.prototype.tooltipHide=function(e,i,r){var o,s=this;o=i?this.target?r||i.target:this.element:U('[data-tooltip-id= "'+this.ctrlId+'_content"]',document),this.tooltipEventArgs={type:i?i.type:null,cancel:!1,target:o,event:i||null,element:this.tooltipEle,isInteracted:!m(i)},this.trigger("beforeClose",this.tooltipEventArgs,function(a){a.cancel?s.isHidden=!1:(s.mouseMoveBeforeRemove(),s.popupHide(e,o,i))})},t.prototype.popupHide=function(e,i,r){i&&r&&this.restoreElement(i),this.isHidden=!0;var s={name:this.animation.close.effect,duration:e.duration,delay:e.delay,timingFunction:"easeIn"};"None"===e.effect&&(s=void 0),this.popupObj&&this.popupObj.hide(s)},t.prototype.restoreElement=function(e){this.unwireMouseEvents(e),m(e.getAttribute("data-content"))||(e.setAttribute("title",e.getAttribute("data-content")),e.removeAttribute("data-content")),this.removeDescribedBy(e)},t.prototype.clear=function(){var e=this.findTarget();e&&this.restoreElement(e),this.tooltipEle&&(K([this.tooltipEle],_E),V([this.tooltipEle],Xg)),this.isHidden&&(this.popupObj&&this.popupObj.destroy(),this.tooltipEle&>(this.tooltipEle),this.tooltipEle=null,this.popupObj=null)},t.prototype.tooltipHover=function(){this.tooltipEle&&(this.isTooltipOpen=!0)},t.prototype.tooltipMouseOut=function(e){this.isTooltipOpen=!1,this.hideTooltip(this.animation.close,e,this.findTarget())},t.prototype.onMouseOut=function(e){var i=e.relatedTarget;if(i&&!this.mouseTrail){var r=J(i,"."+RE+"."+Q0+"."+FE);r?E.add(r,"mouseleave",this.tooltipElementMouseOut,this):(this.hideTooltip(this.animation.close,e,this.findTarget()),0===this.closeDelay&&("None"===this.animation.close.effect||this.isReact&&"string"!=typeof this.content)&&this.clear())}else this.hideTooltip(this.animation.close,e,this.findTarget()),this.clear();this.popupObj&&!this.popupObj.element.classList.contains(Xg)&&this.clear()},t.prototype.tooltipElementMouseOut=function(e){this.hideTooltip(this.animation.close,e,this.findTarget()),E.remove(this.element,"mouseleave",this.tooltipElementMouseOut),this.clear()},t.prototype.onStickyClose=function(){this.close()},t.prototype.onMouseMove=function(e){var i=0,r=0;e.type.indexOf("touch")>-1?(e.preventDefault(),i=e.touches[0].pageX,r=e.touches[0].pageY):(i=e.pageX,r=e.pageY),Hs.stop(this.tooltipEle),K([this.tooltipEle],_E),V([this.tooltipEle],Xg),this.adjustArrow(e.target,this.position,this.tooltipPositionX,this.tooltipPositionY);var s=this.getScalingFactor(e.target),o=this.calculateTooltipOffset(this.position,s.x,s.y),h=this.checkCollision(e.target,i+o.left+this.offsetX,r+o.top+this.offsetY);if(this.tooltipPositionX!==h.horizontal||this.tooltipPositionY!==h.vertical){var c=0===this.position.indexOf("Bottom")||0===this.position.indexOf("Top")?h.vertical+h.horizontal:h.horizontal+h.vertical;h.position=c,this.adjustArrow(e.target,h.position,h.horizontal,h.vertical);var d=this.calculateTooltipOffset(h.position,s.x,s.y);h.left=i+d.left-this.offsetX,h.top=r+d.top-this.offsetY}this.tooltipEle.style.left=h.left+"px",this.tooltipEle.style.top=h.top+"px"},t.prototype.keyDown=function(e){this.tooltipEle&&27===e.keyCode&&this.close()},t.prototype.touchEnd=function(e){this.tooltipEle&&null===J(e.target,"."+zE)&&!this.isSticky&&this.close()},t.prototype.scrollHandler=function(e){this.tooltipEle&&!this.isSticky&&!J(e.target,"."+RE+"."+Q0+"."+FE)&&!this.isSticky&&this.close()},t.prototype.render=function(){this.initialize(),this.wireEvents(this.opensOn),this.renderComplete()},t.prototype.preRender=function(){this.tipClass=Gg,this.tooltipPositionX="Center",this.tooltipPositionY="Top",this.isHidden=!0},t.prototype.wireEvents=function(e){for(var r=0,s=this.getTriggerList(e);r0)for(var i=0,r=e;i0)for(var i=0,r=e;i0&&this.condition&&-1!==this.condition.indexOf("not")&&(e[s].condition=e[s].condition?e[s].condition+"not":"not"),i=e[s].validate(t),r){if(!i)return!1}else if(i)return!0;return r},n.prototype.toJson=function(){var t,e;if(this.isComplex){t=[],e=this.predicates;for(var i=0;ie.length-3?(e=e.substring(0,e.length-1),n.endsWith(n.toLowerCase(t),n.toLowerCase(e))):(e.lastIndexOf("%")!==e.indexOf("%")&&e.lastIndexOf("%")>e.indexOf("%")+1&&(e=e.substring(e.indexOf("%")+1,e.lastIndexOf("%"))),-1!==t.indexOf(e)))},n.fnSort=function(t){return"ascending"===(t=t?n.toLowerCase(t):"ascending")?this.fnAscending:this.fnDescending},n.fnAscending=function(t,e){return m(t)&&m(e)||null==e?-1:"string"==typeof t?t.localeCompare(e):null==t?1:t-e},n.fnDescending=function(t,e){return m(t)&&m(e)?-1:null==e?1:"string"==typeof t?-1*t.localeCompare(e):null==t?-1:e-t},n.extractFields=function(t,e){for(var i={},r=0;r0||e.length>0;)o=t.length>0&&e.length>0?r?r(this.getVal(t,0,i),this.getVal(e,0,i),t[0],e[0])<=0?t:e:t[0][i]0?t:e,s.push(o.shift());return s},n.getVal=function(t,e,i){return i?this.getObject(i,t[e]):t[e]},n.toLowerCase=function(t){return t?"string"==typeof t?t.toLowerCase():t.toString():0===t||!1===t?t.toString():""},n.callAdaptorFunction=function(t,e,i,r){if(e in t){var s=t[e](i,r);m(s)||(i=s)}return i},n.getAddParams=function(t,e,i){var r={};return n.callAdaptorFunction(t,"addParams",{dm:e,query:i,params:i?i.params:[],reqParams:r}),r},n.isPlainObject=function(t){return!!t&&t.constructor===Object},n.isCors=function(){var t=null;try{t=new window.XMLHttpRequest}catch{}return!!t&&"withCredentials"in t},n.getGuid=function(t){var i;return(t||"")+"00000000-0000-4000-0000-000000000000".replace(/0/g,function(r,s){if("crypto"in window&&"getRandomValues"in crypto){var o=new Uint8Array(1);window.crypto.getRandomValues(o),i=o[0]%16|0}else i=16*Math.random()|0;return"0123456789abcdef"[19===s?3&i|8:i]})},n.isNull=function(t){return null==t},n.getItemFromComparer=function(t,e,i){var r,s,o,a=0,l="string"==typeof n.getVal(t,0,e);if(t.length)for(;m(r)&&a0&&(r=s,o=t[a]));return o},n.distinct=function(t,e,i){i=!m(i)&&i;var s,r=[],o={};return t.forEach(function(a,l){(s="object"==typeof t[l]?n.getVal(t,l,e):t[l])in o||(r.push(i?t[l]:s),o[s]=1)}),r},n.processData=function(t,e){var i=this.prepareQuery(t),r=new nt(e);t.requiresCounts&&i.requiresCount();var s=r.executeLocal(i),o={result:t.requiresCounts?s.result:s,count:s.count,aggregates:JSON.stringify(s.aggregates)};return t.requiresCounts?o:s},n.prepareQuery=function(t){var e=this,i=new jt;return t.select&&i.select(t.select),t.where&&n.parse.parseJson(t.where).filter(function(o){if(m(o.condition))i.where(o.field,o.operator,o.value,o.ignoreCase,o.ignoreAccent);else{var a=[];o.field?a.push(new Ss(o.field,o.operator,o.value,o.ignoreCase,o.ignoreAccent)):a=a.concat(e.getPredicate(o.predicates)),"or"===o.condition?i.where(Ss.or(a)):"and"===o.condition&&i.where(Ss.and(a))}}),t.search&&n.parse.parseJson(t.search).filter(function(o){return i.search(o.key,o.fields,o.operator,o.ignoreCase,o.ignoreAccent)}),t.aggregates&&t.aggregates.filter(function(o){return i.aggregate(o.type,o.field)}),t.sorted&&t.sorted.filter(function(o){return i.sortBy(o.name,o.direction)}),t.skip&&i.skip(t.skip),t.take&&i.take(t.take),t.group&&t.group.filter(function(o){return i.group(o)}),i},n.getPredicate=function(t){for(var e=[],i=0;i":"greaterthan","<=":"lessthanorequal",">=":"greaterthanorequal","==":"equal","!=":"notequal","*=":"contains","$=":"endswith","^=":"startswith"},n.odBiOperator={"<":" lt ",">":" gt ","<=":" le ",">=":" ge ","==":" eq ","!=":" ne ",lessthan:" lt ",lessthanorequal:" le ",greaterthan:" gt ",greaterthanorequal:" ge ",equal:" eq ",notequal:" ne "},n.odUniOperator={"$=":"endswith","^=":"startswith","*=":"substringof",endswith:"endswith",startswith:"startswith",contains:"substringof",doesnotendwith:"not endswith",doesnotstartwith:"not startswith",doesnotcontain:"not substringof",wildcard:"wildcard",like:"like"},n.odv4UniOperator={"$=":"endswith","^=":"startswith","*=":"contains",endswith:"endswith",startswith:"startswith",contains:"contains",doesnotendwith:"not endswith",doesnotstartwith:"not startswith",doesnotcontain:"not contains",wildcard:"wildcard",like:"like"},n.diacritics={"\u24b6":"A",\uff21:"A",\u00c0:"A",\u00c1:"A",\u00c2:"A",\u1ea6:"A",\u1ea4:"A",\u1eaa:"A",\u1ea8:"A",\u00c3:"A",\u0100:"A",\u0102:"A",\u1eb0:"A",\u1eae:"A",\u1eb4:"A",\u1eb2:"A",\u0226:"A",\u01e0:"A",\u00c4:"A",\u01de:"A",\u1ea2:"A",\u00c5:"A",\u01fa:"A",\u01cd:"A",\u0200:"A",\u0202:"A",\u1ea0:"A",\u1eac:"A",\u1eb6:"A",\u1e00:"A",\u0104:"A",\u023a:"A",\u2c6f:"A",\ua732:"AA",\u00c6:"AE",\u01fc:"AE",\u01e2:"AE",\ua734:"AO",\ua736:"AU",\ua738:"AV",\ua73a:"AV",\ua73c:"AY","\u24b7":"B",\uff22:"B",\u1e02:"B",\u1e04:"B",\u1e06:"B",\u0243:"B",\u0182:"B",\u0181:"B","\u24b8":"C",\uff23:"C",\u0106:"C",\u0108:"C",\u010a:"C",\u010c:"C",\u00c7:"C",\u1e08:"C",\u0187:"C",\u023b:"C",\ua73e:"C","\u24b9":"D",\uff24:"D",\u1e0a:"D",\u010e:"D",\u1e0c:"D",\u1e10:"D",\u1e12:"D",\u1e0e:"D",\u0110:"D",\u018b:"D",\u018a:"D",\u0189:"D",\ua779:"D",\u01f1:"DZ",\u01c4:"DZ",\u01f2:"Dz",\u01c5:"Dz","\u24ba":"E",\uff25:"E",\u00c8:"E",\u00c9:"E",\u00ca:"E",\u1ec0:"E",\u1ebe:"E",\u1ec4:"E",\u1ec2:"E",\u1ebc:"E",\u0112:"E",\u1e14:"E",\u1e16:"E",\u0114:"E",\u0116:"E",\u00cb:"E",\u1eba:"E",\u011a:"E",\u0204:"E",\u0206:"E",\u1eb8:"E",\u1ec6:"E",\u0228:"E",\u1e1c:"E",\u0118:"E",\u1e18:"E",\u1e1a:"E",\u0190:"E",\u018e:"E","\u24bb":"F",\uff26:"F",\u1e1e:"F",\u0191:"F",\ua77b:"F","\u24bc":"G",\uff27:"G",\u01f4:"G",\u011c:"G",\u1e20:"G",\u011e:"G",\u0120:"G",\u01e6:"G",\u0122:"G",\u01e4:"G",\u0193:"G",\ua7a0:"G",\ua77d:"G",\ua77e:"G","\u24bd":"H",\uff28:"H",\u0124:"H",\u1e22:"H",\u1e26:"H",\u021e:"H",\u1e24:"H",\u1e28:"H",\u1e2a:"H",\u0126:"H",\u2c67:"H",\u2c75:"H",\ua78d:"H","\u24be":"I",\uff29:"I",\u00cc:"I",\u00cd:"I",\u00ce:"I",\u0128:"I",\u012a:"I",\u012c:"I",\u0130:"I",\u00cf:"I",\u1e2e:"I",\u1ec8:"I",\u01cf:"I",\u0208:"I",\u020a:"I",\u1eca:"I",\u012e:"I",\u1e2c:"I",\u0197:"I","\u24bf":"J",\uff2a:"J",\u0134:"J",\u0248:"J","\u24c0":"K",\uff2b:"K",\u1e30:"K",\u01e8:"K",\u1e32:"K",\u0136:"K",\u1e34:"K",\u0198:"K",\u2c69:"K",\ua740:"K",\ua742:"K",\ua744:"K",\ua7a2:"K","\u24c1":"L",\uff2c:"L",\u013f:"L",\u0139:"L",\u013d:"L",\u1e36:"L",\u1e38:"L",\u013b:"L",\u1e3c:"L",\u1e3a:"L",\u0141:"L",\u023d:"L",\u2c62:"L",\u2c60:"L",\ua748:"L",\ua746:"L",\ua780:"L",\u01c7:"LJ",\u01c8:"Lj","\u24c2":"M",\uff2d:"M",\u1e3e:"M",\u1e40:"M",\u1e42:"M",\u2c6e:"M",\u019c:"M","\u24c3":"N",\uff2e:"N",\u01f8:"N",\u0143:"N",\u00d1:"N",\u1e44:"N",\u0147:"N",\u1e46:"N",\u0145:"N",\u1e4a:"N",\u1e48:"N",\u0220:"N",\u019d:"N",\ua790:"N",\ua7a4:"N",\u01ca:"NJ",\u01cb:"Nj","\u24c4":"O",\uff2f:"O",\u00d2:"O",\u00d3:"O",\u00d4:"O",\u1ed2:"O",\u1ed0:"O",\u1ed6:"O",\u1ed4:"O",\u00d5:"O",\u1e4c:"O",\u022c:"O",\u1e4e:"O",\u014c:"O",\u1e50:"O",\u1e52:"O",\u014e:"O",\u022e:"O",\u0230:"O",\u00d6:"O",\u022a:"O",\u1ece:"O",\u0150:"O",\u01d1:"O",\u020c:"O",\u020e:"O",\u01a0:"O",\u1edc:"O",\u1eda:"O",\u1ee0:"O",\u1ede:"O",\u1ee2:"O",\u1ecc:"O",\u1ed8:"O",\u01ea:"O",\u01ec:"O",\u00d8:"O",\u01fe:"O",\u0186:"O",\u019f:"O",\ua74a:"O",\ua74c:"O",\u01a2:"OI",\ua74e:"OO",\u0222:"OU","\u24c5":"P",\uff30:"P",\u1e54:"P",\u1e56:"P",\u01a4:"P",\u2c63:"P",\ua750:"P",\ua752:"P",\ua754:"P","\u24c6":"Q",\uff31:"Q",\ua756:"Q",\ua758:"Q",\u024a:"Q","\u24c7":"R",\uff32:"R",\u0154:"R",\u1e58:"R",\u0158:"R",\u0210:"R",\u0212:"R",\u1e5a:"R",\u1e5c:"R",\u0156:"R",\u1e5e:"R",\u024c:"R",\u2c64:"R",\ua75a:"R",\ua7a6:"R",\ua782:"R","\u24c8":"S",\uff33:"S",\u1e9e:"S",\u015a:"S",\u1e64:"S",\u015c:"S",\u1e60:"S",\u0160:"S",\u1e66:"S",\u1e62:"S",\u1e68:"S",\u0218:"S",\u015e:"S",\u2c7e:"S",\ua7a8:"S",\ua784:"S","\u24c9":"T",\uff34:"T",\u1e6a:"T",\u0164:"T",\u1e6c:"T",\u021a:"T",\u0162:"T",\u1e70:"T",\u1e6e:"T",\u0166:"T",\u01ac:"T",\u01ae:"T",\u023e:"T",\ua786:"T",\ua728:"TZ","\u24ca":"U",\uff35:"U",\u00d9:"U",\u00da:"U",\u00db:"U",\u0168:"U",\u1e78:"U",\u016a:"U",\u1e7a:"U",\u016c:"U",\u00dc:"U",\u01db:"U",\u01d7:"U",\u01d5:"U",\u01d9:"U",\u1ee6:"U",\u016e:"U",\u0170:"U",\u01d3:"U",\u0214:"U",\u0216:"U",\u01af:"U",\u1eea:"U",\u1ee8:"U",\u1eee:"U",\u1eec:"U",\u1ef0:"U",\u1ee4:"U",\u1e72:"U",\u0172:"U",\u1e76:"U",\u1e74:"U",\u0244:"U","\u24cb":"V",\uff36:"V",\u1e7c:"V",\u1e7e:"V",\u01b2:"V",\ua75e:"V",\u0245:"V",\ua760:"VY","\u24cc":"W",\uff37:"W",\u1e80:"W",\u1e82:"W",\u0174:"W",\u1e86:"W",\u1e84:"W",\u1e88:"W",\u2c72:"W","\u24cd":"X",\uff38:"X",\u1e8a:"X",\u1e8c:"X","\u24ce":"Y",\uff39:"Y",\u1ef2:"Y",\u00dd:"Y",\u0176:"Y",\u1ef8:"Y",\u0232:"Y",\u1e8e:"Y",\u0178:"Y",\u1ef6:"Y",\u1ef4:"Y",\u01b3:"Y",\u024e:"Y",\u1efe:"Y","\u24cf":"Z",\uff3a:"Z",\u0179:"Z",\u1e90:"Z",\u017b:"Z",\u017d:"Z",\u1e92:"Z",\u1e94:"Z",\u01b5:"Z",\u0224:"Z",\u2c7f:"Z",\u2c6b:"Z",\ua762:"Z","\u24d0":"a",\uff41:"a",\u1e9a:"a",\u00e0:"a",\u00e1:"a",\u00e2:"a",\u1ea7:"a",\u1ea5:"a",\u1eab:"a",\u1ea9:"a",\u00e3:"a",\u0101:"a",\u0103:"a",\u1eb1:"a",\u1eaf:"a",\u1eb5:"a",\u1eb3:"a",\u0227:"a",\u01e1:"a",\u00e4:"a",\u01df:"a",\u1ea3:"a",\u00e5:"a",\u01fb:"a",\u01ce:"a",\u0201:"a",\u0203:"a",\u1ea1:"a",\u1ead:"a",\u1eb7:"a",\u1e01:"a",\u0105:"a",\u2c65:"a",\u0250:"a",\ua733:"aa",\u00e6:"ae",\u01fd:"ae",\u01e3:"ae",\ua735:"ao",\ua737:"au",\ua739:"av",\ua73b:"av",\ua73d:"ay","\u24d1":"b",\uff42:"b",\u1e03:"b",\u1e05:"b",\u1e07:"b",\u0180:"b",\u0183:"b",\u0253:"b","\u24d2":"c",\uff43:"c",\u0107:"c",\u0109:"c",\u010b:"c",\u010d:"c",\u00e7:"c",\u1e09:"c",\u0188:"c",\u023c:"c",\ua73f:"c",\u2184:"c","\u24d3":"d",\uff44:"d",\u1e0b:"d",\u010f:"d",\u1e0d:"d",\u1e11:"d",\u1e13:"d",\u1e0f:"d",\u0111:"d",\u018c:"d",\u0256:"d",\u0257:"d",\ua77a:"d",\u01f3:"dz",\u01c6:"dz","\u24d4":"e",\uff45:"e",\u00e8:"e",\u00e9:"e",\u00ea:"e",\u1ec1:"e",\u1ebf:"e",\u1ec5:"e",\u1ec3:"e",\u1ebd:"e",\u0113:"e",\u1e15:"e",\u1e17:"e",\u0115:"e",\u0117:"e",\u00eb:"e",\u1ebb:"e",\u011b:"e",\u0205:"e",\u0207:"e",\u1eb9:"e",\u1ec7:"e",\u0229:"e",\u1e1d:"e",\u0119:"e",\u1e19:"e",\u1e1b:"e",\u0247:"e",\u025b:"e",\u01dd:"e","\u24d5":"f",\uff46:"f",\u1e1f:"f",\u0192:"f",\ua77c:"f","\u24d6":"g",\uff47:"g",\u01f5:"g",\u011d:"g",\u1e21:"g",\u011f:"g",\u0121:"g",\u01e7:"g",\u0123:"g",\u01e5:"g",\u0260:"g",\ua7a1:"g",\u1d79:"g",\ua77f:"g","\u24d7":"h",\uff48:"h",\u0125:"h",\u1e23:"h",\u1e27:"h",\u021f:"h",\u1e25:"h",\u1e29:"h",\u1e2b:"h",\u1e96:"h",\u0127:"h",\u2c68:"h",\u2c76:"h",\u0265:"h",\u0195:"hv","\u24d8":"i",\uff49:"i",\u00ec:"i",\u00ed:"i",\u00ee:"i",\u0129:"i",\u012b:"i",\u012d:"i",\u00ef:"i",\u1e2f:"i",\u1ec9:"i",\u01d0:"i",\u0209:"i",\u020b:"i",\u1ecb:"i",\u012f:"i",\u1e2d:"i",\u0268:"i",\u0131:"i","\u24d9":"j",\uff4a:"j",\u0135:"j",\u01f0:"j",\u0249:"j","\u24da":"k",\uff4b:"k",\u1e31:"k",\u01e9:"k",\u1e33:"k",\u0137:"k",\u1e35:"k",\u0199:"k",\u2c6a:"k",\ua741:"k",\ua743:"k",\ua745:"k",\ua7a3:"k","\u24db":"l",\uff4c:"l",\u0140:"l",\u013a:"l",\u013e:"l",\u1e37:"l",\u1e39:"l",\u013c:"l",\u1e3d:"l",\u1e3b:"l",\u017f:"l",\u0142:"l",\u019a:"l",\u026b:"l",\u2c61:"l",\ua749:"l",\ua781:"l",\ua747:"l",\u01c9:"lj","\u24dc":"m",\uff4d:"m",\u1e3f:"m",\u1e41:"m",\u1e43:"m",\u0271:"m",\u026f:"m","\u24dd":"n",\uff4e:"n",\u01f9:"n",\u0144:"n",\u00f1:"n",\u1e45:"n",\u0148:"n",\u1e47:"n",\u0146:"n",\u1e4b:"n",\u1e49:"n",\u019e:"n",\u0272:"n",\u0149:"n",\ua791:"n",\ua7a5:"n",\u01cc:"nj","\u24de":"o",\uff4f:"o",\u00f2:"o",\u00f3:"o",\u00f4:"o",\u1ed3:"o",\u1ed1:"o",\u1ed7:"o",\u1ed5:"o",\u00f5:"o",\u1e4d:"o",\u022d:"o",\u1e4f:"o",\u014d:"o",\u1e51:"o",\u1e53:"o",\u014f:"o",\u022f:"o",\u0231:"o",\u00f6:"o",\u022b:"o",\u1ecf:"o",\u0151:"o",\u01d2:"o",\u020d:"o",\u020f:"o",\u01a1:"o",\u1edd:"o",\u1edb:"o",\u1ee1:"o",\u1edf:"o",\u1ee3:"o",\u1ecd:"o",\u1ed9:"o",\u01eb:"o",\u01ed:"o",\u00f8:"o",\u01ff:"o",\u0254:"o",\ua74b:"o",\ua74d:"o",\u0275:"o",\u01a3:"oi",\u0223:"ou",\ua74f:"oo","\u24df":"p",\uff50:"p",\u1e55:"p",\u1e57:"p",\u01a5:"p",\u1d7d:"p",\ua751:"p",\ua753:"p",\ua755:"p","\u24e0":"q",\uff51:"q",\u024b:"q",\ua757:"q",\ua759:"q","\u24e1":"r",\uff52:"r",\u0155:"r",\u1e59:"r",\u0159:"r",\u0211:"r",\u0213:"r",\u1e5b:"r",\u1e5d:"r",\u0157:"r",\u1e5f:"r",\u024d:"r",\u027d:"r",\ua75b:"r",\ua7a7:"r",\ua783:"r","\u24e2":"s",\uff53:"s",\u00df:"s",\u015b:"s",\u1e65:"s",\u015d:"s",\u1e61:"s",\u0161:"s",\u1e67:"s",\u1e63:"s",\u1e69:"s",\u0219:"s",\u015f:"s",\u023f:"s",\ua7a9:"s",\ua785:"s",\u1e9b:"s","\u24e3":"t",\uff54:"t",\u1e6b:"t",\u1e97:"t",\u0165:"t",\u1e6d:"t",\u021b:"t",\u0163:"t",\u1e71:"t",\u1e6f:"t",\u0167:"t",\u01ad:"t",\u0288:"t",\u2c66:"t",\ua787:"t",\ua729:"tz","\u24e4":"u",\uff55:"u",\u00f9:"u",\u00fa:"u",\u00fb:"u",\u0169:"u",\u1e79:"u",\u016b:"u",\u1e7b:"u",\u016d:"u",\u00fc:"u",\u01dc:"u",\u01d8:"u",\u01d6:"u",\u01da:"u",\u1ee7:"u",\u016f:"u",\u0171:"u",\u01d4:"u",\u0215:"u",\u0217:"u",\u01b0:"u",\u1eeb:"u",\u1ee9:"u",\u1eef:"u",\u1eed:"u",\u1ef1:"u",\u1ee5:"u",\u1e73:"u",\u0173:"u",\u1e77:"u",\u1e75:"u",\u0289:"u","\u24e5":"v",\uff56:"v",\u1e7d:"v",\u1e7f:"v",\u028b:"v",\ua75f:"v",\u028c:"v",\ua761:"vy","\u24e6":"w",\uff57:"w",\u1e81:"w",\u1e83:"w",\u0175:"w",\u1e87:"w",\u1e85:"w",\u1e98:"w",\u1e89:"w",\u2c73:"w","\u24e7":"x",\uff58:"x",\u1e8b:"x",\u1e8d:"x","\u24e8":"y",\uff59:"y",\u1ef3:"y",\u00fd:"y",\u0177:"y",\u1ef9:"y",\u0233:"y",\u1e8f:"y",\u00ff:"y",\u1ef7:"y",\u1e99:"y",\u1ef5:"y",\u01b4:"y",\u024f:"y",\u1eff:"y","\u24e9":"z",\uff5a:"z",\u017a:"z",\u1e91:"z",\u017c:"z",\u017e:"z",\u1e93:"z",\u1e95:"z",\u01b6:"z",\u0225:"z",\u0240:"z",\u2c6c:"z",\ua763:"z",\u0386:"\u0391",\u0388:"\u0395",\u0389:"\u0397",\u038a:"\u0399",\u03aa:"\u0399",\u038c:"\u039f",\u038e:"\u03a5",\u03ab:"\u03a5",\u038f:"\u03a9",\u03ac:"\u03b1",\u03ad:"\u03b5",\u03ae:"\u03b7",\u03af:"\u03b9",\u03ca:"\u03b9",\u0390:"\u03b9",\u03cc:"\u03bf",\u03cd:"\u03c5",\u03cb:"\u03c5",\u03b0:"\u03c5",\u03c9:"\u03c9",\u03c2:"\u03c3"},n.fnOperators={equal:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?n.toLowerCase(t)===n.toLowerCase(e):t===e},notequal:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),!n.fnOperators.equal(t,e,i)},lessthan:function(t,e,i){return i?n.toLowerCase(t)n.toLowerCase(e):t>e},lessthanorequal:function(t,e,i){return i?n.toLowerCase(t)<=n.toLowerCase(e):(m(t)&&(t=void 0),t<=e)},greaterthanorequal:function(t,e,i){return i?n.toLowerCase(t)>=n.toLowerCase(e):t>=e},contains:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?!m(t)&&!m(e)&&-1!==n.toLowerCase(t).indexOf(n.toLowerCase(e)):!m(t)&&!m(e)&&-1!==t.toString().indexOf(e)},doesnotcontain:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?!m(t)&&!m(e)&&-1===n.toLowerCase(t).indexOf(n.toLowerCase(e)):!m(t)&&!m(e)&&-1===t.toString().indexOf(e)},isnotnull:function(t){return null!=t},isnull:function(t){return null==t},startswith:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.startsWith(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.startsWith(t,e)},doesnotstartwith:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.notStartsWith(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.notStartsWith(t,e)},like:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.like(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.like(t,e)},isempty:function(t){return void 0===t||""===t},isnotempty:function(t){return void 0!==t&&""!==t},wildcard:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?(t||"boolean"==typeof t)&&e&&"object"!=typeof t&&n.wildCard(n.toLowerCase(t),n.toLowerCase(e)):(t||"boolean"==typeof t)&&e&&n.wildCard(t,e)},endswith:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.endsWith(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.endsWith(t,e)},doesnotendwith:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.notEndsWith(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.notEndsWith(t,e)},processSymbols:function(t){var e=n.operatorSymbols[t];return e?n.fnOperators[e]:n.throwError("Query - Process Operator : Invalid operator")},processOperator:function(t){return n.fnOperators[t]||n.fnOperators.processSymbols(t)}},n.parse={parseJson:function(t){return"string"!=typeof t||!/^[\s]*\[|^[\s]*\{(.)+:/g.test(t)&&-1!==t.indexOf('"')?t instanceof Array?n.parse.iterateAndReviveArray(t):"object"==typeof t&&null!==t&&n.parse.iterateAndReviveJson(t):t=JSON.parse(t,n.parse.jsonReviver),t},iterateAndReviveArray:function(t){for(var e=0;e-1||e.indexOf("z")>-1,o=e.split(/[^0-9.]/);if(s){if(o[5].indexOf(".")>-1){var a=o[5].split(".");o[5]=a[0],o[6]=new Date(e).getUTCMilliseconds().toString()}else o[6]="00";e=n.dateParse.toTimeZone(new Date(parseInt(o[0],10),parseInt(o[1],10)-1,parseInt(o[2],10),parseInt(o[3],10),parseInt(o[4],10),parseInt(o[5]?o[5]:"00",10),parseInt(o[6],10)),n.serverTimezoneOffset,!1)}else{var l=new Date(parseInt(o[0],10),parseInt(o[1],10)-1,parseInt(o[2],10),parseInt(o[3],10),parseInt(o[4],10),parseInt(o[5]?o[5]:"00",10)),h=parseInt(o[6],10),c=parseInt(o[7],10);if(isNaN(h)&&isNaN(c))return l;e.indexOf("+")>-1?l.setHours(l.getHours()-h,l.getMinutes()-c):l.setHours(l.getHours()+h,l.getMinutes()+c),e=n.dateParse.toTimeZone(l,n.serverTimezoneOffset,!1)}null==n.serverTimezoneOffset&&(e=n.dateParse.addSelfOffset(e))}}return e},isJson:function(t){return"string"==typeof t[0]?t:n.parse.parseJson(t)},isGuid:function(t){return null!=/[A-Fa-f0-9]{8}(?:-[A-Fa-f0-9]{4}){3}-[A-Fa-f0-9]{12}/i.exec(t)},replacer:function(t,e){return n.isPlainObject(t)?n.parse.jsonReplacer(t,e):t instanceof Array?n.parse.arrayReplacer(t):t instanceof Date?n.parse.jsonReplacer({val:t},e).val:t},jsonReplacer:function(t,e){for(var i,s=0,o=Object.keys(t);s=0?"+":"-",s=function(a){var l=Math.floor(Math.abs(a));return(l<10?"0":"")+l};return e.getFullYear()+"-"+s(e.getMonth()+1)+"-"+s(e.getDate())+"T"+s(e.getHours())+":"+s(e.getMinutes())+":"+s(e.getSeconds())+r+s(i/60)+":"+s(i%60)}},n}(),bl=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),xK={GroupGuid:"{271bbba0-1ee7}"},t5=function(){function n(t){this.options={from:"table",requestType:"json",sortBy:"sorted",select:"select",skip:"skip",group:"group",take:"take",search:"search",count:"requiresCounts",where:"where",aggregates:"aggregates",expand:"expand"},this.type=n,this.dataSource=t,this.pvt={}}return n.prototype.processResponse=function(t,e,i,r){return t},n}(),VE=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return bl(t,n),t.prototype.processQuery=function(e,i){for(var a,l,p,r=e.dataSource.json.slice(0),s=r.length,o=!0,h={},c=0,d=[],u=[],f=0;f1?e.sort.filter(function(p){return p.fieldName===c})[0]:e.sort[0];s=this.onSortBy(s,d,e.query,!0)}e.page&&(s=this.onPage(s,e.page,e.query)),this.formGroupResult(s,h)}else{for(var o=e.lazyLoad.onDemandGroupInfo,a=o.where.length-1;a>=0;a--)s=this.onWhere(s,o.where[a]);if(e.group.length!==o.level)s=le.group(s,e.group[o.level].fieldName,r,null,null,e.group[o.level].comparer,!0),e.sort.length&&(s=this.onSortBy(s,e.sort[parseInt(o.level.toString(),10)],e.query,!0));else for(a=e.sort.length-1;a>=o.level;a--)s=this.onSortBy(s,e.sort[parseInt(a.toString(),10)],e.query,!1);i=s.length,h=s,s=(s=s.slice(o.skip)).slice(0,o.take),e.group.length!==o.level&&this.formGroupResult(s,h)}return{result:s,count:i}},t.prototype.formGroupResult=function(e,i){if(e.length&&i.length){var r="GroupGuid",s="childLevels",o="level",a="records";e[r]=i[r],e[s]=i[s],e[o]=i[o],e[a]=i[a]}return e},t.prototype.getAggregate=function(e){var i=jt.filterQueries(e.queries,"onAggregates"),r=[];if(i.length)for(var s=void 0,o=0;o=0;l--)a[l]&&(o=i.comparer,le.endsWith(a[l]," desc")&&(o=le.fnSort("descending"),a[l]=a[l].replace(" desc","")),e=le.sort(e,a[l],o));return e}return le.sort(e,s?"key":a,i.comparer)},t.prototype.onGroup=function(e,i,r){if(!e||!e.length)return e;var s=this.getAggregate(r);return le.group(e,le.getValue(i.fieldName,r),s,null,null,i.comparer)},t.prototype.onPage=function(e,i,r){var s=le.getValue(i.pageSize,r),o=(le.getValue(i.pageIndex,r)-1)*s;return e&&e.length?e.slice(o,o+s):e},t.prototype.onRange=function(e,i){return e&&e.length?e.slice(le.getValue(i.start),le.getValue(i.end)):e},t.prototype.onTake=function(e,i){return e&&e.length?e.slice(0,le.getValue(i.nos)):e},t.prototype.onSkip=function(e,i){return e&&e.length?e.slice(le.getValue(i.nos)):e},t.prototype.onSelect=function(e,i){return e&&e.length?le.select(e,le.getValue(i.fieldNames)):e},t.prototype.insert=function(e,i,r,s,o){return m(o)?e.dataSource.json.push(i):e.dataSource.json.splice(o,0,i)},t.prototype.remove=function(e,i,r,s){var a,o=e.dataSource.json;for("object"==typeof r&&!(r instanceof Date)&&(r=le.getObject(i,r)),a=0;a1&&(g="("+g+")"),p.filters.push(g);for(var y=0,S="object"==typeof p.filters[f]?Object.keys(p.filters[f]):[];y-1&&this.formRemoteGroupedData(e[s].items,i+1,r-1);var o="GroupGuid",h="records";return e[o]=xK[o],e.level=i,e.childLevels=r,e[h]=e[0].items.length?this.getGroupedRecords(e,!m(e[0].items[h])):[],e},t.prototype.getGroupedRecords=function(e,i){for(var r=[],o=0;ol.length-3?(l=l.substring(0,l.length-1),o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.endswith:le.odv4UniOperator.endswith):l.lastIndexOf("%")!==l.indexOf("%")&&l.lastIndexOf("%")>l.indexOf("%")+1?(l=l.substring(l.indexOf("%")+1,l.lastIndexOf("%")),o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains):o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains),l="'"+(l=encodeURIComponent(l))+"'";else if("wildcard"===o)if(-1!==l.indexOf("*")){var d=l.split("*"),u=void 0,p=0;if(0!==l.indexOf("*")&&-1===d[0].indexOf("%3f")&&-1===d[0].indexOf("?")&&(u="'"+(u=d[0])+"'",s+=(o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.startswith:le.odv4UniOperator.startswith)+"(",s+=c+",",a&&(s+=a),s+=u+")",p++),l.lastIndexOf("*")!==l.length-1&&-1===d[d.length-1].indexOf("%3f")&&-1===d[d.length-1].indexOf("?")&&(u="'"+(u=d[d.length-1])+"'",p>0&&(s+=" and "),s+=(o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.endswith:le.odv4UniOperator.endswith)+"(",s+=c+",",a&&(s+=a),s+=u+")",p++),d.length>2)for(var f=1;f0&&(s+=" and "),"substringof"===(o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains)||"not substringof"===o){var g=u;u=c,c=g}s+=o+"(",s+=c+",",a&&(s+=a),s+=u+")",p++}0===p?(o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains,(-1!==l.indexOf("?")||-1!==l.indexOf("%3f"))&&(l=-1!==l.indexOf("?")?l.split("?").join(""):l.split("%3f").join("")),l="'"+l+"'"):o="wildcard"}else o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains,(-1!==l.indexOf("?")||-1!==l.indexOf("%3f"))&&(l=-1!==l.indexOf("?")?l.split("?").join(""):l.split("%3f").join("")),l="'"+l+"'";return"substringof"!==o&&"not substringof"!==o||(g=l,l=c,c=g),"wildcard"!==o&&(s+=o+"(",s+=c+",",a&&(s+=a),s+=l+")"),s},t.prototype.addParams=function(e){n.prototype.addParams.call(this,e),delete e.reqParams.params},t.prototype.onComplexPredicate=function(e,i,r){for(var s=[],o=0;o-1;p--)!/\bContent-ID:/i.test(c[p])||!/\bHTTP.+201/.test(c[p])||(l=parseInt(/\bContent-ID: (\d+)/i.exec(c[p])[1],10),o.addedRecords[l]&&(h=le.parse.parseJson(/^\{.+\}/m.exec(c[p])[0]),ze({},o.addedRecords[l],this.processResponse(h))));return o}return null},t.prototype.compareAndRemove=function(e,i,r){var s=this;return m(i)||Object.keys(e).forEach(function(o){o!==r&&"@odata.etag"!==o&&(le.isPlainObject(e[o])?(s.compareAndRemove(e[o],i[o]),0===Object.keys(e[o]).filter(function(l){return"@odata.etag"!==l}).length&&delete e[o]):(e[o]===i[o]||e[o]&&i[o]&&e[o].valueOf()===i[o].valueOf())&&delete e[o])}),e},t}(uc),TK=function(n){function t(){var e=n.call(this)||this;return yt("beforeSend",uc.prototype.beforeSend,e),e}return bl(t,n),t.prototype.insert=function(e,i,r,s,o){return this.pvt.position=o,this.updateType="add",{url:e.dataSource.insertUrl||e.dataSource.crudUrl||e.dataSource.url,data:JSON.stringify(ze({},{value:i,table:r,action:"insert"},le.getAddParams(this,e,s)))}},t.prototype.remove=function(e,i,r,s,o){return n.prototype.remove.call(this,e,i,r),{type:"POST",url:e.dataSource.removeUrl||e.dataSource.crudUrl||e.dataSource.url,data:JSON.stringify(ze({},{key:r,keyColumn:i,table:s,action:"remove"},le.getAddParams(this,e,o)))}},t.prototype.update=function(e,i,r,s,o){return this.updateType="update",this.updateKey=i,{type:"POST",url:e.dataSource.updateUrl||e.dataSource.crudUrl||e.dataSource.url,data:JSON.stringify(ze({},{value:r,action:"update",keyColumn:i,key:r[i],table:s},le.getAddParams(this,e,o)))}},t.prototype.processResponse=function(e,i,r,s,o,a,l){var h;if(e="batch"===(o?JSON.parse(o.data):e).action?le.parse.parseJson(e):e,"add"===this.updateType&&n.prototype.insert.call(this,i,e,null,null,this.pvt.position),"update"===this.updateType&&n.prototype.update.call(this,i,this.updateKey,e),this.updateType=void 0,e.added)for(h=0;hi&&h.push(c)}for(c=0;cthis.pageSize;)h.results.splice(0,1),h.keys.splice(0,1);return window.localStorage.setItem(this.guidId,JSON.stringify(h)),e},t.prototype.beforeSend=function(e,i,r){!m(this.cacheAdaptor.options.batch)&&le.endsWith(r.url,this.cacheAdaptor.options.batch)&&"post"===r.type.toLowerCase()&&i.headers.set("Accept",this.cacheAdaptor.options.multipartAccept),e.dataSource.crossDomain||i.headers.set("Accept",this.cacheAdaptor.options.accept)},t.prototype.update=function(e,i,r,s){return this.isCrudAction=!0,this.cacheAdaptor.update(e,i,r,s)},t.prototype.insert=function(e,i,r){return this.isInsertAction=!0,this.cacheAdaptor.insert(e,i,r)},t.prototype.remove=function(e,i,r,s){return this.isCrudAction=!0,this.cacheAdaptor.remove(e,i,r,s)},t.prototype.batchRequest=function(e,i,r){return this.cacheAdaptor.batchRequest(e,i,r)},t}(uc),nt=function(){function n(t,e,i){var s,r=this;return this.dateParse=!0,this.timeZoneHandling=!0,this.persistQuery={},this.isInitialLoad=!1,this.requests=[],this.isInitialLoad=!0,!t&&!this.dataSource&&(t=[]),i=i||t.adaptor,t&&!1===t.timeZoneHandling&&(this.timeZoneHandling=t.timeZoneHandling),t instanceof Array?s={json:t,offline:!0}:"object"==typeof t?(t.json||(t.json=[]),t.enablePersistence||(t.enablePersistence=!1),t.id||(t.id=""),t.ignoreOnPersist||(t.ignoreOnPersist=[]),s={url:t.url,insertUrl:t.insertUrl,removeUrl:t.removeUrl,updateUrl:t.updateUrl,crudUrl:t.crudUrl,batchUrl:t.batchUrl,json:t.json,headers:t.headers,accept:t.accept,data:t.data,timeTillExpiration:t.timeTillExpiration,cachingPageSize:t.cachingPageSize,enableCaching:t.enableCaching,requestType:t.requestType,key:t.key,crossDomain:t.crossDomain,jsonp:t.jsonp,dataType:t.dataType,offline:void 0!==t.offline?t.offline:!(t.adaptor instanceof TK||t.adaptor instanceof AK||t.url),requiresFormat:t.requiresFormat,enablePersistence:t.enablePersistence,id:t.id,ignoreOnPersist:t.ignoreOnPersist}):le.throwError("DataManager: Invalid arguments"),void 0===s.requiresFormat&&!le.isCors()&&(s.requiresFormat=!!m(s.crossDomain)||s.crossDomain),void 0===s.dataType&&(s.dataType="json"),this.dataSource=s,this.defaultQuery=e,this.dataSource.enablePersistence&&this.dataSource.id&&window.addEventListener("unload",this.setPersistData.bind(this)),s.url&&s.offline&&!s.json.length?(this.isDataAvailable=!1,this.adaptor=i||new up,this.dataSource.offline=!1,this.ready=this.executeQuery(e||new jt),this.ready.then(function(o){r.dataSource.offline=!0,r.isDataAvailable=!0,s.json=o.result,r.adaptor=new VE})):this.adaptor=s.offline?new VE:new up,!s.jsonp&&this.adaptor instanceof up&&(s.jsonp="callback"),this.adaptor=i||this.adaptor,s.enableCaching&&(this.adaptor=new LK(this.adaptor,s.timeTillExpiration,s.cachingPageSize)),this}return Object.defineProperty(n.prototype,"moduleName",{get:function(){return"datamanager"},enumerable:!0,configurable:!0}),n.prototype.getPersistedData=function(t){var e=localStorage.getItem(t||this.dataSource.id);return JSON.parse(e)},n.prototype.setPersistData=function(t,e,i){localStorage.setItem(e||this.dataSource.id,JSON.stringify(i||this.persistQuery))},n.prototype.setPersistQuery=function(t){var e=this,i=this.getPersistedData();if(this.isInitialLoad&&i&&Object.keys(i).length){this.persistQuery=i,this.persistQuery.queries=this.persistQuery.queries.filter(function(s){if(e.dataSource.ignoreOnPersist&&e.dataSource.ignoreOnPersist.length&&s.fn&&e.dataSource.ignoreOnPersist.some(function(l){return s.fn===l}))return!1;if("onWhere"===s.fn){var o=s.e;if(o&&o.isComplex&&o.predicates instanceof Array){var a=o.predicates.map(function(l){if(l.predicates&&l.predicates instanceof Array){var h=l.predicates.map(function(v){return new Ss(v.field,v.operator,v.value,v.ignoreCase,v.ignoreAccent,v.matchCase)});return"and"===l.condition?Ss.and(h):Ss.or(h)}return new Ss(l.field,l.operator,l.value,l.ignoreCase,l.ignoreAccent,l.matchCase)});s.e=new Ss(a[0],o.condition,a.slice(1))}}return!0});var r=ze(new jt,this.persistQuery);return this.isInitialLoad=!1,r}return this.persistQuery=t,this.isInitialLoad=!1,t},n.prototype.setDefaultQuery=function(t){return this.defaultQuery=t,this},n.prototype.executeLocal=function(t){!this.defaultQuery&&!(t instanceof jt)&&le.throwError("DataManager - executeLocal() : A query is required to execute"),this.dataSource.json||le.throwError("DataManager - executeLocal() : Json data is required to execute"),this.dataSource.enablePersistence&&this.dataSource.id&&(t=this.setPersistQuery(t));var e=this.adaptor.processQuery(this,t=t||this.defaultQuery);if(t.subQuery){var i=t.subQuery.fromTable,r=t.subQuery.lookups,s=t.isCountRequired?e.result:e;r&&r instanceof Array&&le.buildHierarchy(t.subQuery.fKey,i,s,r,t.subQuery.key);for(var o=0;oli");P.classList.remove("json-parent");for(var j=0;j',W=ve.children[0].placeholder}return W}function Q(k,W,ve){!m(ve)&&""!==ve&&K(W,ve.split(" ")),!m(k)&&""!==k&&V(W,k.split(" "))}function oe(k,W,ve){if("multiselect"===ve||function Mo(k){if(!k)return!1;for(var W=k;W&&W!==document.body;){if("none"===window.getComputedStyle(W).display)return!1;W=W.parentElement}return!0}(k)){var Te="multiselect"===ve?k:k.clientWidth-parseInt(getComputedStyle(k,null).getPropertyValue("padding-left"),10);!m(W)&&!m(W.getElementsByClassName("e-float-text-content")[0])&&(W.getElementsByClassName("e-float-text-content")[0].classList.contains("e-float-text-overflow")&&W.getElementsByClassName("e-float-text-content")[0].classList.remove("e-float-text-overflow"),(Te0)for(var Ye=0;Ye<_e.length;Ye++)_e[parseInt(Ye.toString(),10)].addEventListener("mousedown",wo,!1),_e[parseInt(Ye.toString(),10)].addEventListener("mouseup",Hl,!1);else if(_e.length>0)for(Ye=0;Ye<_e.length;Ye++)_e[parseInt(Ye.toString(),10)].removeEventListener("mousedown",wo,this),_e[parseInt(Ye.toString(),10)].removeEventListener("mouseup",Hl,this)}function wo(){for(var W=this.parentElement;!W.classList.contains("e-input-group");)W=W.parentElement;!function ya(k,W){!k.classList.contains("e-disabled")&&!k.querySelector("input").readOnly&&W.classList.add("e-input-btn-ripple")}(W,this)}function Hl(){var k=this;setTimeout(function(){k.classList.remove("e-input-btn-ripple")},500)}function fb(k,W){var ve=W("span",{className:k});return ve.classList.add("e-input-group-icon"),ve}function y_(k,W,ve,Te){var _e=m(Te)?mi:Te,Ye=fb(k,_e);W.classList.add("e-float-icon-left");var fi=W.querySelector(".e-input-in-wrap");if(m(fi)){fi=_e("span",{className:"e-input-in-wrap"}),ve.parentNode.insertBefore(fi,ve);var Gs=W.querySelectorAll(ve.tagName+" ~ *");fi.appendChild(ve);for(var Kn=0;Kn-1)if("class"===_e){var Ye=this.getInputValidClassList(k[""+_e]);""!==Ye&&V([W],Ye.split(" "))}else if("style"===_e){var fi=W.getAttribute(_e);fi=m(fi)?k[""+_e]:fi+k[""+_e],W.setAttribute(_e,fi)}else W.setAttribute(_e,k[""+_e])}},n.isBlank=function Hle(k){return!k||/^\s*$/.test(k)}}(Le||(Le={})),new RegExp("^(-)?(\\d*)$"),new RegExp("^[A-Za-z0-9._%+-]{1,}@[A-Za-z0-9._%+-]{1,}([.]{1}[a-zA-Z0-9]{2,}|[.]{1}[a-zA-Z0-9]{2,4}[.]{1}[a-zA-Z0-9]{2,4})$"),new RegExp("^([0-9]{4})-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])$"),new RegExp("^[0-9]*$"),new RegExp("^[+]?[0-9]{9,13}$"),new RegExp("^\\d{13,16}$");var me=function(){function n(t,e){this.width=t,this.height=e}return n.prototype.isEmpty=function(){return 0===this.height&&0===this.width},n.prototype.clone=function(){return new n(this.width,this.height)},n}(),Eie=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),GB=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},z=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Eie(t,n),t.equals=function(e,i){return e===i||!(!e||!i)&&(!e||!i||e.x===i.x&&e.y===i.y)},t.isEmptyPoint=function(e){return!(e.x&&e.y)},t.transform=function(e,i,r){var s={x:0,y:0};return s.x=Math.round(100*(e.x+r*Math.cos(i*Math.PI/180)))/100,s.y=Math.round(100*(e.y+r*Math.sin(i*Math.PI/180)))/100,s},t.findLength=function(e,i){return Math.sqrt(Math.pow(e.x-i.x,2)+Math.pow(e.y-i.y,2))},t.findAngle=function(e,i){var r=Math.atan2(i.y-e.y,i.x-e.x);return r=180*r/Math.PI,(r%=360)<0&&(r+=360),r},t.distancePoints=function(e,i){return Math.sqrt(Math.pow(i.x-e.x,2)+Math.pow(i.y-e.y,2))},t.getLengthFromListOfPoints=function(e){for(var i=0,r=0;ri.y&&!r?o.y+=s:o.y-=s:e.y===i.y?e.xi.x&&!r?o.x+=s:o.x-=s:r?(a=this.findAngle(e,i),o=this.transform(e,a,s)):(a=this.findAngle(i,e),o=this.transform(i,a,s)),o},t.direction=function(e,i){return Math.abs(i.x-e.x)>Math.abs(i.y-e.y)?e.x0)for(var r=0;rt.right||this.top>t.bottom||this.bottom=t.right&&this.top<=t.top&&this.bottom>=t.bottom},n.prototype.containsPoint=function(t,e){return void 0===e&&(e=0),this.left-e<=t.x&&this.right+e>=t.x&&this.top-e<=t.y&&this.bottom+e>=t.y},n.toBounds=function(t){for(var e=new n,i=0,r=t;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},KB=function(n){if(n)switch(n.type){case"Linear":default:return vI;case"Radial":return Rie}return vI},Pie=function(){return function n(t,e,i,r){this.left=t,this.right=e,this.top=i,this.bottom=r}}(),$n=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),it([I(0)],t.prototype,"left",void 0),it([I(0)],t.prototype,"right",void 0),it([I(0)],t.prototype,"top",void 0),it([I(0)],t.prototype,"bottom",void 0),t}(Ee),zie=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),it([I(45)],t.prototype,"angle",void 0),it([I(5)],t.prototype,"distance",void 0),it([I(.7)],t.prototype,"opacity",void 0),it([I("lightgrey")],t.prototype,"color",void 0),t}(Ee),e3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),t.prototype.getClassName=function(){return"Stop"},it([I("")],t.prototype,"color",void 0),it([I(0)],t.prototype,"offset",void 0),it([I(1)],t.prototype,"opacity",void 0),t}(Ee),Ix=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),it([Bt([],e3)],t.prototype,"stops",void 0),it([I("None")],t.prototype,"type",void 0),it([I("")],t.prototype,"id",void 0),t}(Ee),vI=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),it([I(0)],t.prototype,"x1",void 0),it([I(0)],t.prototype,"x2",void 0),it([I(0)],t.prototype,"y1",void 0),it([I(0)],t.prototype,"y2",void 0),t}(Ix),Rie=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),it([I(0)],t.prototype,"cx",void 0),it([I(0)],t.prototype,"cy",void 0),it([I(0)],t.prototype,"fx",void 0),it([I(0)],t.prototype,"fy",void 0),it([I(50)],t.prototype,"r",void 0),t}(Ix),Al=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),it([I("white")],t.prototype,"fill",void 0),it([I("black")],t.prototype,"strokeColor",void 0),it([I("")],t.prototype,"strokeDashArray",void 0),it([I(1)],t.prototype,"strokeWidth",void 0),it([I(1)],t.prototype,"opacity",void 0),it([C0(KB)],t.prototype,"gradient",void 0),t}(Ee),t3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),it([I("transparent")],t.prototype,"fill",void 0),t}(Al),Yp=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Wa(t,n),it([I("black")],t.prototype,"color",void 0),it([I("Arial")],t.prototype,"fontFamily",void 0),it([I(12)],t.prototype,"fontSize",void 0),it([I(!1)],t.prototype,"italic",void 0),it([I(!1)],t.prototype,"bold",void 0),it([I("CollapseSpace")],t.prototype,"whiteSpace",void 0),it([I("WrapWithOverflow")],t.prototype,"textWrapping",void 0),it([I("Center")],t.prototype,"textAlign",void 0),it([I("None")],t.prototype,"textDecoration",void 0),it([I("Wrap")],t.prototype,"textOverflow",void 0),it([I("transparent")],t.prototype,"fill",void 0),t}(Al),on=function(n){return n[n.Default=0]="Default",n[n.expandNode=2]="expandNode",n[n.interaction=4]="interaction",n[n.GroupingInProgress=8]="GroupingInProgress",n[n.GroupClipboardInProcess=16]="GroupClipboardInProcess",n[n.ClearObject=32]="ClearObject",n}(on||{}),Gt=function(n){return n[n.Visible=1]="Visible",n[n.Hidden=2]="Hidden",n[n.Hover=4]="Hover",n[n.Connect=8]="Connect",n}(Gt||{}),ei=function(n){return n[n.None=0]="None",n[n.ShowHorizontalLines=1]="ShowHorizontalLines",n[n.ShowVerticalLines=2]="ShowVerticalLines",n[n.ShowLines=3]="ShowLines",n[n.SnapToHorizontalLines=4]="SnapToHorizontalLines",n[n.SnapToVerticalLines=8]="SnapToVerticalLines",n[n.SnapToLines=12]="SnapToLines",n[n.SnapToObject=16]="SnapToObject",n[n.All=31]="All",n}(ei||{}),mr=function(n){return n[n.None=1]="None",n[n.ConnectorSourceThumb=2]="ConnectorSourceThumb",n[n.ConnectorTargetThumb=4]="ConnectorTargetThumb",n[n.ResizeSouthEast=8]="ResizeSouthEast",n[n.ResizeSouthWest=16]="ResizeSouthWest",n[n.ResizeNorthEast=32]="ResizeNorthEast",n[n.ResizeNorthWest=64]="ResizeNorthWest",n[n.ResizeEast=128]="ResizeEast",n[n.ResizeWest=256]="ResizeWest",n[n.ResizeSouth=512]="ResizeSouth",n[n.ResizeNorth=1024]="ResizeNorth",n[n.Rotate=2048]="Rotate",n[n.UserHandle=4096]="UserHandle",n[n.ToolTip=8192]="ToolTip",n[n.ResizeAll=2046]="ResizeAll",n[n.All=16382]="All",n}(mr||{}),qe=function(n){return n[n.None=1]="None",n[n.Select=2]="Select",n[n.Delete=4]="Delete",n[n.Drag=8]="Drag",n[n.DragSourceEnd=16]="DragSourceEnd",n[n.DragTargetEnd=32]="DragTargetEnd",n[n.DragSegmentThumb=64]="DragSegmentThumb",n[n.AllowDrop=128]="AllowDrop",n[n.Bridging=256]="Bridging",n[n.BridgeObstacle=512]="BridgeObstacle",n[n.InheritBridging=1024]="InheritBridging",n[n.PointerEvents=2048]="PointerEvents",n[n.Tooltip=4096]="Tooltip",n[n.InheritTooltip=8192]="InheritTooltip",n[n.Interaction=4218]="Interaction",n[n.ReadOnly=16384]="ReadOnly",n[n.LineRouting=32768]="LineRouting",n[n.InheritLineRouting=65536]="InheritLineRouting",n[n.ConnectToNearByNode=131072]="ConnectToNearByNode",n[n.ConnectToNearByPort=262144]="ConnectToNearByPort",n[n.ConnectToNearByElement=393216]="ConnectToNearByElement",n[n.InheritSegmentThumbShape=524288]="InheritSegmentThumbShape",n[n.InheritSegmentThumbSize=1048576]="InheritSegmentThumbSize",n[n.Default=2043454]="Default",n}(qe||{}),Lr=function(n){return n[n.ReadOnly=2]="ReadOnly",n[n.InheritReadOnly=4]="InheritReadOnly",n[n.Select=8]="Select",n[n.Drag=16]="Drag",n[n.Resize=32]="Resize",n[n.Rotate=64]="Rotate",n[n.Tooltip=128]="Tooltip",n[n.Interaction=120]="Interaction",n[n.None=0]="None",n}(Lr||{}),ie=function(n){return n[n.None=0]="None",n[n.Select=2]="Select",n[n.Drag=4]="Drag",n[n.Rotate=8]="Rotate",n[n.Shadow=16]="Shadow",n[n.PointerEvents=32]="PointerEvents",n[n.Delete=64]="Delete",n[n.InConnect=128]="InConnect",n[n.OutConnect=256]="OutConnect",n[n.Individual=512]="Individual",n[n.Expandable=1024]="Expandable",n[n.AllowDrop=2048]="AllowDrop",n[n.Inherit=78]="Inherit",n[n.ResizeNorthEast=4096]="ResizeNorthEast",n[n.ResizeEast=8192]="ResizeEast",n[n.ResizeSouthEast=16384]="ResizeSouthEast",n[n.ResizeSouth=32768]="ResizeSouth",n[n.ResizeSouthWest=65536]="ResizeSouthWest",n[n.ResizeWest=131072]="ResizeWest",n[n.ResizeNorthWest=262144]="ResizeNorthWest",n[n.ResizeNorth=524288]="ResizeNorth",n[n.Resize=1044480]="Resize",n[n.AspectRatio=1048576]="AspectRatio",n[n.Tooltip=2097152]="Tooltip",n[n.InheritTooltip=4194304]="InheritTooltip",n[n.ReadOnly=8388608]="ReadOnly",n[n.HideThumbs=16777216]="HideThumbs",n[n.AllowMovingOutsideLane=33554432]="AllowMovingOutsideLane",n[n.Default=5240814]="Default",n}(ie||{}),Xr=function(n){return n[n.None=0]="None",n[n.ElementIsPort=2]="ElementIsPort",n[n.ElementIsGroup=4]="ElementIsGroup",n[n.HorizontalLaneHeader=8]="HorizontalLaneHeader",n}(Xr||{}),bt=function(n){return n[n.Rotate=2]="Rotate",n[n.ConnectorSource=4]="ConnectorSource",n[n.ConnectorTarget=8]="ConnectorTarget",n[n.ResizeNorthEast=16]="ResizeNorthEast",n[n.ResizeEast=32]="ResizeEast",n[n.ResizeSouthEast=64]="ResizeSouthEast",n[n.ResizeSouth=128]="ResizeSouth",n[n.ResizeSouthWest=256]="ResizeSouthWest",n[n.ResizeWest=512]="ResizeWest",n[n.ResizeNorthWest=1024]="ResizeNorthWest",n[n.ResizeNorth=2048]="ResizeNorth",n[n.Default=4094]="Default",n}(bt||{}),rt=function(n){return n[n.None=1]="None",n[n.Bridging=2]="Bridging",n[n.UndoRedo=4]="UndoRedo",n[n.Tooltip=8]="Tooltip",n[n.UserInteraction=16]="UserInteraction",n[n.ApiUpdate=32]="ApiUpdate",n[n.PageEditable=48]="PageEditable",n[n.Zoom=64]="Zoom",n[n.PanX=128]="PanX",n[n.PanY=256]="PanY",n[n.Pan=384]="Pan",n[n.ZoomTextEdit=512]="ZoomTextEdit",n[n.Virtualization=1024]="Virtualization",n[n.LineRouting=2048]="LineRouting",n[n.Default=500]="Default",n}(rt||{}),Ci=function(n){return n[n.None=0]="None",n[n.SingleSelect=1]="SingleSelect",n[n.MultipleSelect=2]="MultipleSelect",n[n.ZoomPan=4]="ZoomPan",n[n.DrawOnce=8]="DrawOnce",n[n.ContinuousDraw=16]="ContinuousDraw",n[n.Default=3]="Default",n}(Ci||{}),Ya=function(n){return n[n.Self=1]="Self",n[n.Parent=2]="Parent",n}(Ya||{}),pt=function(n){return n[n.None=0]="None",n[n.Control=1]="Control",n[n.Meta=1]="Meta",n[n.Alt=2]="Alt",n[n.Shift=4]="Shift",n}(pt||{}),Mt=function(n){return n[n.None=null]="None",n[n.Number0=0]="Number0",n[n.Number1=1]="Number1",n[n.Number2=2]="Number2",n[n.Number3=3]="Number3",n[n.Number4=4]="Number4",n[n.Number5=5]="Number5",n[n.Number6=6]="Number6",n[n.Number7=7]="Number7",n[n.Number8=8]="Number8",n[n.Number9=9]="Number9",n[n.A=65]="A",n[n.B=66]="B",n[n.C=67]="C",n[n.D=68]="D",n[n.E=69]="E",n[n.F=70]="F",n[n.G=71]="G",n[n.H=72]="H",n[n.I=73]="I",n[n.J=74]="J",n[n.K=75]="K",n[n.L=76]="L",n[n.M=77]="M",n[n.N=78]="N",n[n.O=79]="O",n[n.P=80]="P",n[n.Q=81]="Q",n[n.R=82]="R",n[n.S=83]="S",n[n.T=84]="T",n[n.U=85]="U",n[n.V=86]="V",n[n.W=87]="W",n[n.X=88]="X",n[n.Y=89]="Y",n[n.Z=90]="Z",n[n.Left=37]="Left",n[n.Up=38]="Up",n[n.Right=39]="Right",n[n.Down=40]="Down",n[n.Escape=27]="Escape",n[n.Space=32]="Space",n[n.PageUp=33]="PageUp",n[n.PageDown=34]="PageDown",n[n.End=35]="End",n[n.Home=36]="Home",n[n.Delete=46]="Delete",n[n.Tab=9]="Tab",n[n.Enter=13]="Enter",n[n.BackSpace=8]="BackSpace",n[n.F1=112]="F1",n[n.F2=113]="F2",n[n.F3=114]="F3",n[n.F4=115]="F4",n[n.F5=116]="F5",n[n.F6=117]="F6",n[n.F7=118]="F7",n[n.F8=119]="F8",n[n.F9=120]="F9",n[n.F10=121]="F10",n[n.F11=122]="F11",n[n.F12=123]="F12",n[n.Star=56]="Star",n[n.Plus=187]="Plus",n[n.Minus=189]="Minus",n[n.BracketLeft=219]="BracketLeft",n[n.BracketRight=221]="BracketRight",n}(Mt||{}),ee=function(n){return n[n.Render=2]="Render",n[n.PublicMethod=4]="PublicMethod",n[n.ToolAction=8]="ToolAction",n[n.UndoRedo=16]="UndoRedo",n[n.TextEdit=32]="TextEdit",n[n.Group=64]="Group",n[n.Clear=128]="Clear",n[n.PreventClearSelection=256]="PreventClearSelection",n[n.Interactions=512]="Interactions",n[n.PreventHistory=1024]="PreventHistory",n[n.PreventIconsUpdate=2048]="PreventIconsUpdate",n[n.PreventCollectionChangeOnDragOver=4096]="PreventCollectionChangeOnDragOver",n[n.PreventZIndexOnDragging=8192]="PreventZIndexOnDragging",n[n.isGroupDragging=16384]="isGroupDragging",n[n.DragUsingMouse=32768]="DragUsingMouse",n[n.DecoratorPropertyChange=65536]="DecoratorPropertyChange",n[n.PreventLaneContainerUpdate=131072]="PreventLaneContainerUpdate",n}(ee||{}),Qa=function(n){return n[n.None=2]="None",n[n.DrawSelectorBorder=4]="DrawSelectorBorder",n[n.PreventRenderSelector=8]="PreventRenderSelector",n}(Qa||{}),$i=function(n){return n[n.None=0]="None",n[n.PreventDrag=2]="PreventDrag",n[n.PreventScale=4]="PreventScale",n[n.PreventDataInit=8]="PreventDataInit",n[n.hScrollbarMoved=16]="hScrollbarMoved",n[n.vScrollbarMoved=32]="vScrollbarMoved",n[n.AnimationClick=64]="AnimationClick",n[n.EnableGroupAction=128]="EnableGroupAction",n[n.PanInProgress=256]="PanInProgress",n[n.OverViewAction=512]="OverViewAction",n}($i||{}),ca=function(n){return n[n.None=0]="None",n[n.PropertyChange=1024]="PropertyChange",n[n.Interaction=2048]="Interaction",n}(ca||{}),Ae=function(n){return n[n.Zero=0]="Zero",n[n.One=1]="One",n[n.Two=2]="Two",n[n.Three=3]="Three",n[n.Four=4]="Four",n[n.Five=5]="Five",n}(Ae||{}),Ce=function(n){return n[n.collectionChange=0]="collectionChange",n[n.rotateChange=1]="rotateChange",n[n.positionChange=2]="positionChange",n[n.propertyChange=3]="propertyChange",n[n.selectionChange=4]="selectionChange",n[n.sizeChange=5]="sizeChange",n[n.drop=6]="drop",n[n.sourcePointChange=7]="sourcePointChange",n[n.targetPointChange=8]="targetPointChange",n[n.connectionChange=9]="connectionChange",n[n.animationComplete=10]="animationComplete",n[n.click=11]="click",n[n.doubleClick=12]="doubleClick",n[n.scrollChange=13]="scrollChange",n[n.dragEnter=14]="dragEnter",n[n.dragLeave=15]="dragLeave",n[n.dragOver=16]="dragOver",n[n.textEdit=17]="textEdit",n[n.paletteSelectionChange=18]="paletteSelectionChange",n[n.historyChange=19]="historyChange",n[n.mouseEnter=20]="mouseEnter",n[n.mouseLeave=21]="mouseLeave",n[n.mouseOver=22]="mouseOver",n[n.expandStateChange=23]="expandStateChange",n[n.segmentCollectionChange=24]="segmentCollectionChange",n[n.commandExecute=25]="commandExecute",n[n.historyStateChange=26]="historyStateChange",n[n.onUserHandleMouseDown=27]="onUserHandleMouseDown",n[n.onUserHandleMouseUp=28]="onUserHandleMouseUp",n[n.onUserHandleMouseEnter=29]="onUserHandleMouseEnter",n[n.onUserHandleMouseLeave=30]="onUserHandleMouseLeave",n[n.onImageLoad=31]="onImageLoad",n[n.onDoBindingInit=32]="onDoBindingInit",n[n.keyUp=33]="keyUp",n[n.keyDown=34]="keyDown",n[n.fixedUserHandleClick=35]="fixedUserHandleClick",n[n.elementDraw=36]="elementDraw",n[n.mouseWheel=37]="mouseWheel",n[n.segmentChange=38]="segmentChange",n[n.onFixedUserHandleMouseDown=39]="onFixedUserHandleMouseDown",n[n.onFixedUserHandleMouseUp=40]="onFixedUserHandleMouseUp",n[n.onFixedUserHandleMouseEnter=41]="onFixedUserHandleMouseEnter",n[n.onFixedUserHandleMouseLeave=42]="onFixedUserHandleMouseLeave",n[n.loaded=43]="loaded",n}(Ce||{}),ni=function(n){return n[n.None=1]="None",n[n.Drag=2]="Drag",n[n.Draw=4]="Draw",n[n.InConnect=8]="InConnect",n[n.OutConnect=16]="OutConnect",n[n.ToolTip=32]="ToolTip",n[n.InheritTooltip=64]="InheritTooltip",n[n.Default=24]="Default",n}(ni||{}),bx=function(n){return n[n.None=1]="None",n[n.Source=2]="Source",n[n.Target=4]="Target",n[n.Intermediate=8]="Intermediate",n[n.All=14]="All",n}(bx||{}),mI=function(n){return n[n.None=0]="None",n[n.SymmetricAngle=2]="SymmetricAngle",n[n.SymmetricDistance=4]="SymmetricDistance",n[n.Default=6]="Default",n}(mI||{}),as=function(){function n(){this.pivot={x:.5,y:.5},this.isDirt=!0,this.isExport=!1,this.exportScaleValue={x:0,y:0},this.exportScaleOffset={x:0,y:0},this.canApplyStyle=!0,this.visible=!0,this.offsetX=0,this.offsetY=0,this.cornerRadius=0,this.minHeight=void 0,this.minWidth=void 0,this.maxWidth=void 0,this.maxHeight=void 0,this.width=void 0,this.height=void 0,this.rotateAngle=0,this.margin={left:0,right:0,top:0,bottom:0},this.connectionDirection="Auto",this.horizontalAlignment="Auto",this.verticalAlignment="Auto",this.flip="None",this.flipMode="All",this.relativeMode="Point",this.transform=Ya.Self|Ya.Parent,this.style={fill:"white",strokeColor:"black",opacity:1,strokeWidth:1},this.desiredSize=new me,this.actualSize=new me,this.parentTransform=0,this.preventContainer=!1,this.isSvgRender=!1,this.bounds=new Ne(0,0,0,0),this.shadow=null,this.description="",this.staticSize=!1,this.shapeType="",this.isRectElement=!1,this.isCalculateDesiredSize=!0,this.flipOffset={x:0,y:0},this.elementActions=Xr.None,this.inversedAlignment=!0,this.position=void 0,this.unitMode=void 0,this.float=!1,this.floatingBounds=void 0}return n.prototype.setOffsetWithRespectToBounds=function(t,e,i){this.unitMode=i,this.position={x:t,y:e}},n.prototype.getAbsolutePosition=function(t){if(void 0!==this.position)return"Absolute"===this.unitMode?this.position:{x:this.position.x*t.width,y:this.position.y*t.height}},Object.defineProperty(n.prototype,"outerBounds",{get:function(){return this.floatingBounds||this.bounds},set:function(t){this.floatingBounds=t},enumerable:!0,configurable:!0}),n.prototype.measure=function(t,e,i){var s=void 0!==this.height?this.height:(t.height||0)-this.margin.top-this.margin.bottom;return this.id&&0===s&&this.elementActions&Xr.HorizontalLaneHeader&&(s=this.actualSize.height),this.desiredSize=new me(void 0!==this.width?this.width:(t.width||0)-this.margin.left-this.margin.right,s),this.isCalculateDesiredSize&&(this.desiredSize=this.validateDesiredSize(this.desiredSize,t)),this.desiredSize},n.prototype.arrange=function(t){return this.actualSize=t,this.updateBounds(),this.actualSize},n.prototype.updateBounds=function(){this.bounds=yr(this)},n.prototype.validateDesiredSize=function(t,e){return this.isRectElement&&!this.width&&!this.minWidth&&!this.maxWidth&&(t.width=50),this.isRectElement&&!this.height&&!this.minHeight&&!this.maxHeight&&(t.height=50),(void 0===t||void 0!==this.width&&void 0!==this.height)&&((t=t||new me).width=void 0===this.width?(e.width||0)-this.margin.left-this.margin.right:this.width,t.height=void 0===this.height?(e.height||0)-this.margin.top-this.margin.bottom:this.height),void 0!==this.minWidth&&(t.width=Math.max(t.width,this.minWidth)),void 0!==this.minHeight&&(t.height=Math.max(t.height,this.minHeight)),void 0!==this.maxWidth&&0!==this.maxWidth&&(t.width=Math.min(t.width,this.maxWidth)),void 0!==this.maxHeight&&0!==this.maxHeight&&(t.height=Math.min(t.height,this.maxHeight)),t},n}(),Vie=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Cs=function(n){function t(){var e=null!==n&&n.apply(this,arguments)||this;return e.padding=new Pie(0,0,0,0),e.desiredBounds=void 0,e.measureChildren=!0,e.prevRotateAngle=0,e}return Vie(t,n),t.prototype.hasChildren=function(){return void 0!==this.children&&this.children.length>0},t.prototype.measure=function(e,i,r){this.desiredBounds=void 0;var o,a,s=void 0;if(this.hasChildren()){for(var l=0;l=n.width&&s.length>0)i[i.length]={text:s,x:0,dy:0,width:o},s="";else{(s+=a[r+1]||"").indexOf("\n")>-1&&(i[i.length]={text:s,x:0,dy:0,width:Bc(s,n)},s="");var l=Bc(s,n);Math.ceil(l)+2>=n.width&&s.length>0&&(i[i.length]={text:s,x:0,dy:0,width:l},s=""),r===a.length-1&&s.length>0&&(i[i.length]={text:s,x:0,dy:0,width:l},s="")}else i=function loe(n,t,e){var c,d,u,p,i=[],r="",s=0,o=0,a="nowrap"!==n.whiteSpace,h=(t||n.content).split("\n");for(s=0;s0?" ":"")+c[parseInt(o.toString(),10)];var f=Bc(d=c[o+1]?r+" "+c[o+1]:r,n);Math.floor(f)>(e||n.width)-2&&r.length>0?(i[i.length]={text:r,x:0,dy:0,width:d===r?f:r===p?u:Bc(r,n)},r=""):o===c.length-1&&(i[i.length]={text:r,x:0,dy:0,width:f},r=""),p=d,u=f}return i}(n,t,e);else i[i.length]={text:a,x:0,dy:0,width:Bc(a,n)};return i}(l,r,n.isLaneOrientation?i:void 0),n.wrapBounds=a=function hoe(n,t){var r,s,e={x:0,width:0},i=0;for(i=0;in.width&&("Ellipsis"===n.textOverflow||"Clip"===n.textOverflow)?0:-r/2:"right"===n.textAlign?-r:t.length>1?0:-r/2,t[parseInt(i.toString(),10)].dy=1.2*n.fontSize,t[parseInt(i.toString(),10)].x=r,e.x=Math.min(e.x,r),e.width=Math.max(e.width,s);return e}(l,o),s.width=a.width,n.wrapBounds.width>=i&&"Wrap"!==l.textOverflow&&(s.width=i),s.height=o.length*n.style.fontSize*1.2,s}(this,0,0,this.isLaneOrientation?e.height:this.width||e.width):this.desiredSize,this.desiredSize=void 0===this.width||void 0===this.height?new me(i.width,i.height):new me(this.width,this.height),this.desiredSize=this.validateDesiredSize(this.desiredSize,e),this.desiredSize},t.prototype.arrange=function(e){return(e.width!==this.actualSize.width||e.height!==this.actualSize.height||this.isDirt)&&(this.doWrap=!0),this.actualSize=e,this.updateBounds(),this.isDirt=!1,this.actualSize},t}(as),Yie=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Ii=function(n){function t(){var e=null!==n&&n.apply(this,arguments)||this;return e.measureChildren=void 0,e}return Yie(t,n),t.prototype.measure=function(e,i,r){var s=void 0,o=void 0;if(this.hasChildren()){for(var a=0,l=this.children;a=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Ed=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return $ie(t,n),Th([I("")],t.prototype,"content",void 0),Th([I("TopLeft")],t.prototype,"position",void 0),Th([I("Mouse")],t.prototype,"relativeMode",void 0),Th([I(!0)],t.prototype,"showTipPointer",void 0),Th([I("auto")],t.prototype,"width",void 0),Th([I("auto")],t.prototype,"height",void 0),Th([I("Auto")],t.prototype,"openOn",void 0),Th([I()],t.prototype,"animation",void 0),Th([I(!1)],t.prototype,"isSticky",void 0),t}(Ee);function i3(n){var t=new mh;t=r3(n.tooltip,t);var e=new mh(t);return e.beforeCollision=Jie,e.beforeOpen=Zie,e.cssClass="e-diagram-tooltip",e.opensOn="custom",e.appendTo("#"+n.element.id),e.close(),e}function Zie(n){(""===this.content||void 0===this.content)&&(n.element.style.display="none")}function Jie(n){n.collidedPosition&&n.collidedPosition!==this.position&&(n.element.style.display="none")}function Mx(n,t){var e=n.tooltipObject;return r3(t?t.tooltip:n.tooltip,e),e}function r3(n,t){return n.content?(t.content=n.content,"string"==typeof n.content&&(t.content=ko(function(){return n.content})),t.position=n.position,t.showTipPointer=n.showTipPointer,t.width=n.width,t.height=n.height,t.animation=n.animation?n.animation:{close:{effect:"None"}}):t.close(),t}var wx=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Hn=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Cx=function(n){function t(e,i,r,s){var o=n.call(this,e,i,r,s)||this;return o.inEdges=[],o.outEdges=[],o}return wx(t,n),Hn([I("")],t.prototype,"id",void 0),Hn([I("Center")],t.prototype,"horizontalAlignment",void 0),Hn([I("Center")],t.prototype,"verticalAlignment",void 0),Hn([re({},$n)],t.prototype,"margin",void 0),Hn([I(12)],t.prototype,"width",void 0),Hn([I(12)],t.prototype,"height",void 0),Hn([re({},Al)],t.prototype,"style",void 0),Hn([I("Square")],t.prototype,"shape",void 0),Hn([I("Auto")],t.prototype,"connectionDirection",void 0),Hn([I(Gt.Connect)],t.prototype,"visibility",void 0),Hn([I("")],t.prototype,"pathData",void 0),Hn([I(ni.Default)],t.prototype,"constraints",void 0),Hn([I()],t.prototype,"addInfo",void 0),Hn([I()],t.prototype,"outEdges",void 0),Hn([I()],t.prototype,"inEdges",void 0),Hn([re({},Ed)],t.prototype,"tooltip",void 0),t}(Ee),Es=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return wx(t,n),t.prototype.getClassName=function(){return"PointPort"},Hn([re({x:.5,y:.5},z)],t.prototype,"offset",void 0),t}(Cx),xc=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return wx(t,n),t.prototype.getClassName=function(){return"PathPort"},Hn([I(.5)],t.prototype,"offset",void 0),Hn([re({x:0,y:0},z)],t.prototype,"displacement",void 0),Hn([I("Center")],t.prototype,"alignment",void 0),t}(Cx),II=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),lr=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Kie=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return II(t,n),lr([I("blue")],t.prototype,"color",void 0),lr([I("")],t.prototype,"content",void 0),lr([I("")],t.prototype,"link",void 0),lr([I("None")],t.prototype,"textDecoration",void 0),lr([I("NewTab")],t.prototype,"hyperlinkOpenState",void 0),t}(Ee),Ex=function(n){function t(e,i,r,s){var o=n.call(this,e,i,r,s)||this;return r.id||(o.id=e.parentObj&&e.parentObj.propName&&"phases"===e.parentObj.propName?e.parentObj.id:Qe()),o}return II(t,n),lr([I("")],t.prototype,"content",void 0),lr([I(void 0)],t.prototype,"template",void 0),lr([I("String")],t.prototype,"annotationType",void 0),lr([I(!0)],t.prototype,"visibility",void 0),lr([I(Lr.InheritReadOnly)],t.prototype,"constraints",void 0),lr([re(void 0,Kie)],t.prototype,"hyperlink",void 0),lr([I("")],t.prototype,"id",void 0),lr([I()],t.prototype,"width",void 0),lr([I()],t.prototype,"height",void 0),lr([I(0)],t.prototype,"rotateAngle",void 0),lr([I("Parent")],t.prototype,"rotationReference",void 0),lr([re({strokeWidth:0,strokeColor:"transparent",fill:"transparent"},Yp)],t.prototype,"style",void 0),lr([I("Center")],t.prototype,"horizontalAlignment",void 0),lr([I("Center")],t.prototype,"verticalAlignment",void 0),lr([re({},$n)],t.prototype,"margin",void 0),lr([re({top:void 0,bottom:void 0,left:void 0,right:void 0},$n)],t.prototype,"dragLimit",void 0),lr([I("Shape")],t.prototype,"type",void 0),lr([re({},Ed)],t.prototype,"tooltip",void 0),lr([I()],t.prototype,"addInfo",void 0),t}(Ee),Zn=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return II(t,n),t.prototype.getClassName=function(){return"ShapeAnnotation"},lr([re({x:.5,y:.5},z)],t.prototype,"offset",void 0),t}(Ex),Nr=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return II(t,n),t.prototype.getClassName=function(){return"PathAnnotation"},lr([I(.5)],t.prototype,"offset",void 0),lr([re({x:0,y:0},z)],t.prototype,"displacement",void 0),lr([I("Center")],t.prototype,"alignment",void 0),lr([I(!1)],t.prototype,"segmentAngle",void 0),t}(Ex);function Dx(n){return rre[n.toString()]}function n3(n){return ore[""+n]}var rre={X:"M14,14 L106,106 M106,14 L14,106",Circle:"M0,50 A50,50,0 1 1 100,50 A50,50,0 1 1 0,50 Z",Square:"M0,0 L10,0 L10,10 L0,10 z"},nre={OpenArrow:"M15.9,23 L5,16 L15.9,9 L17,10.7 L8.7,16 L17,21.3Z",Square:"M0,0 L10,0 L10,10 L0,10 z",Fletch:"M14.8,10c0,0-3.5,6,0.2,12c0,0-2.5-6-10.9-6C4.1,16,11.3,16,14.8,10z",OpenFetch:"M6,17c-0.6,0-1-0.4-1-1s0.4-1,1-1c10.9,0,11-5,11-5c0-0.6,0.4-1,1-1s1,0.4,1,1C19,10.3,18.9,17,6,17C6,17,6,17,6,17z M18,23c-0.5,0-1-0.4-1-1c0-0.2-0.3-5-11-5c-0.6,0-1-0.5-1-1s0.4-1,1-1c0,0,0,0,0,0c12.9,0,13,6.7,13,7 C19,22.6,18.6,23,18,23z",IndentedArrow:"M17,10c0,0-4.5,5.5,0,12L5,16L17,10z",OutdentedArrow:"M14.6,10c0,0,5.4,6,0,12L5,16L14.6,10z",DoubleArrow:"M19,10 L19,22 L13,16Z M12,10 L12,22 L6,16Z",Arrow:"M15,10 L15,22 L5,16Z",Diamond:"M12,23l-7-7l7-7l6.9,7L12,23z",Circle:"M0,50 A50,50,0 1 1 100,50 A50,50,0 1 1 0,50 Z"},sre={Square:"M0,0 L10,0 L10,10 L0,10 z",Rhombus:"M10,5 L5,10 L0,5 L5,0 L10,5 Z ",Rectangle:"M0,0 L15,0 L15,10 L0,10 z ",OpenArrow:"M15.9,23 L5,16 L15.9,9 L17,10.7 L8.7,16 L17,21.3Z",Fletch:"M9.82,0 C9.82,0,6.61,5,10,10 C10,10,7.71,5,0,5 C0,5,6.61,5,9.82,0 Z ",OpenFetch:"M0.71,5.71 C0.29,5.71,0,5.43,0,5 C0,4.57,0.29,4.29,0.71,4.29 C8.5,4.29,8.57,0.71,8.57,0.71 C8.57,0.29,8.86,0,9.29,0 C9.719999999999999,0,10,0.29,10,0.71 C10,0.93,9.93,5.71,0.71,5.71 C0.71,5.71,0.71,5.71,0.71,5.71 Z M9.29,10 C8.93,10,8.57,9.71,8.57,9.29 C8.57,9.14,8.36,5.71,0.71,5.71 C0.29,5.71,0,5.36,0,5 C0,4.64,0.29,4.29,0.71,4.29 C0.71,4.29,0.71,4.29,0.71,4.29 C9.93,4.29,10,9.07,10,9.29 C10,9.71,9.71,10,9.29,10 Z ",IndentedArrow:"M10,0 C10,0,6.25,4.58,10,10 L0,5 L10,0 Z ",OutdentedArrow:"M8,0 C8,0,12.5,5,8,10 L0,5 L8,0 Z ",DoubleArrow:"M19,10 L19,22 L13,16Z M12,10 L12,22 L6,16Z",Arrow:"M15,10 L15,22 L5,16Z",Diamond:"M10,5 L5,10 L0,5 L5,0 L10,5 Z ",Circle:"M10,5 C10,7.76,7.76,10,5,10 C2.24,10,0,7.76,0,5 C0,2.24,2.24,0,5,0 C7.76,0,10,2.24,10,5 Z ",Ellipse:"M15,5 C15,7.76,11.64,10,7.5,10 C3.36,10,0,7.76,0,5 C0,2.24,3.36,0,7.5,0 C11.64,0,15,2.24,15,5 Z "},ore={Square:"M0,0 L10,0 L10,10 L0,10 z",Rhombus:"M10,5 L5,10 L0,5 L5,0 L10,5 Z ",Rectangle:"M0,0 L15,0 L15,10 L0,10 z",OpenArrow:"M23,15.9 L16,5 L9,15.9 L10.7,17 L16,8.7 L21,17.3Z",Fletch:"M9.82,0 C9.82,0,6.61,5,10,10 C10,10,7.71,5,0,5 C0,5,6.61,5,9.82,0 Z ",OpenFetch:"M0.71,5.71 C0.29,5.71,0,5.43,0,5 C0,4.57,0.29,4.29,0.71,4.29 C8.5,4.29,8.57,0.71,8.57,0.71 C8.57,0.29,8.86,0,9.29,0 C9.719999999999999,0,10,0.29,10,0.71 C10,0.93,9.93,5.71,0.71,5.71 C0.71,5.71,0.71,5.71,0.71,5.71 Z M9.29,10 C8.93,10,8.57,9.71,8.57,9.29 C8.57,9.14,8.36,5.71,0.71,5.71 C0.29,5.71,0,5.36,0,5 C0,4.64,0.29,4.29,0.71,4.29 C0.71,4.29,0.71,4.29,0.71,4.29 C9.93,4.29,10,9.07,10,9.29 C10,9.71,9.71,10,9.29,10 Z ",IndentedArrow:"M10,0 C10,0,6.25,4.58,10,10 L0,5 L10,0 Z ",OutdentedArrow:"M8,0 C8,0,12.5,5,8,10 L0,5 L8,0 Z ",DoubleArrow:"M10,19 L22,19 L16,13Z M10,12 L22,12 L16,6Z",Arrow:"M10,15 L22,15 L16,5Z",Diamond:"M10,5 L5,10 L0,5 L5,0 L10,5 Z ",Circle:"M10,5 C10,7.76,7.76,10,5,10 C2.24,10,0,7.76,0,5 C0,2.24,2.24,0,5,0 C7.76,0,10,2.24,10,5 Z ",Ellipse:"M15,5 C15,7.76,11.64,10,7.5,10 C3.36,10,0,7.76,0,5 C0,2.24,3.36,0,7.5,0 C11.64,0,15,2.24,15,5 Z "};function xx(n){return are[n.toString()]}var are={Process:"M419.511,76.687L359.511,76.687L359.511,43.086L419.511,43.086z",Decision:"M 253.005,115.687L 200.567,146.071L 148.097,115.687L 200.534,85.304L 253.005,115.687 Z",Document:"M 60 31.9 c 0 0 -11 -7.7 -30 0 s -30 0 -30 0 V 0 h 60 V 31.9 Z",PreDefinedProcess:"M 0,0 L 50,0 L 50,50 L 0,50 Z M 8.334,0 L 8.334,50 M 41.667,0 L 41.667,50",Terminator:"M 269.711,29.33C 269.71,44.061 257.77,56 243.04,56L 158.058,56C 143.33,56 131.39,44.061 131.39,29.33L 131.39,29.33C 131.391,14.6057 143.33,2.669 158.058,2.669L 243.044,2.669C 257.772,2.669 269.711,14.6057 269.711,29.333 Z",PaperTap:"M0.0009,17.2042 L0.0009,47.165 C0.001,47.165 14.403,53.5455 25.00,47.165 C35.599,40.7852 44.403,43.5087 50.00,47.165L50.001,17.2042 M50.001,32.7987 L50.001,2.8405 C50.001,2.8405 35.599,-3.5427 25.001,2.8405C14.403,9.2237 5.599,6.494 0.0009,2.8405 L0.0009,32.7987",DirectData:"M 132.62 0 L 17.38 0 C 7.78 0 0 13.43 0 30 C 0 46.57 7.78 60 17.38 60 L 132.62 60 M 132.62 0C 123.02 0 115.24 13.43 115.24 30 C 115.24 46.57 123.02 60 132.62 60 C 142.22 60 150 46.57 150 30 C 150 13.43 142.22 0 132.62 0 z ",SequentialData:"M0.0029,24.999 C0.0029,11.1922 10.433,0.0021 23.295,0.0021 C36.159,0.00216 46.585,11.1922 46.585,24.999C46.585,38.8057 36.159,49.9979 23.295,49.9979 C10.433,49.9979 0.0029,38.8057 0.0029,24.999 z M23.294,49.999 L50.002,49.999",Sort:"M50.001,24.9971 L25.001,49.9971 L0.00097,24.9971 L25.001,-0.00286865 L50.001,24.9971 z M0.000976562,24.9971 L50.001,24.9971",MultiDocument:"M43.6826,40 C44.8746,40.6183 45.8586,41.3502 46.8366,42.1122 L46.8366,4.74487 L3.09857,4.74487 L3.09857,10.9544 M46.837,35.143 C48.027,35.765 49.025,36.604 50.003,37.369 L50.003,0.002 L6.264,0.002 L6.264,4.744 M43.682,47.113 L43.682,10.765 L0.0025,10.7652 L0.0025,47.1132 C0.0025,47.1132 12.5846,53.6101 21.8426,47.1132 C31.1006,40.6163 38.792,43.393 43.6826,47.1132 z",Collate:"M50.001,0.0028 L25.001,25.0029 L0.00097,0.0028 L50.001,0.002 z M0.0009,50.002 L25.001,25.002L50.001,50.002 L0.0009,50.0029 z",SummingJunction:"M7.3252,42.6768 L42.6772,7.3247 M42.6768,42.6768 L7.3248,7.3247 M0.0009,25.001 C0.0009,11.193 11.197,0.0009 25.001,0.0009 C38.809,0.0009 50.001,11.193 50.001,25.001 C50.001,38.809 38.809,50.001 25.001,50.001 C11.197,50.00 0.0009,38.809 0.0009,25.00 z",Or:"M 0 50 L 100 50 M 50 100 L 50 0.0 M 0 50 C 0 22.384 22.392 0 50 0 C 77.616 0 100 22.384 100 50 C 100 77.616 77.616 100 50 100 C 22.392 100 0 77.616 0 50 Z",InternalStorage:"M 0 3.81946A 2.5,3.81946 0 0,1 2.5,0L 47.5 0A 2.5,3.81946 0 0,1 50,3.81946L 50 45.836A 2.5,3.819446 0 0,1 47.5,49.652778L 2.5 49.652778A 2.5,3.819446 0 0,1 0,45.8336L 0 3.819446ZM 0 11.45834L 50 11.4583334M 12.5 0L 12.5 49.652778",Extract:"M0,35 L30,0 L60,35 Z",ManualOperation:"M46.4,28.8 L14.8,28.8 L0,0 L60,0 Z",Merge:"M60,0 L30,35 L0,0 Z",OffPageReference:"M60,33.3 L30.1,39 L0,33.3 L0,0 L60,0 Z",SequentialAccessStorage:"M 60 30 C 60 13.4 46.6 0 30 0 S 0 13.4 0 30 s 13.4 30 30 30 h 28.6 v -6.5 h -9.9C 55.5 48 60 39.5 60 30 Z",Annotation:"M49.9984,50.0029 L-0.00271199,50.0029 L-0.00271199,0.00286865 L49.9984,0.00286865",Annotation2:"M49.9977,50.0029 L25.416,50.0029 L25.416,0.00286865 L49.9977,0.00286865 M25.4166,25.0029 L-0.00227869,25.0029",Data:"M 10 0 L 40 0 L 30 40 L 0 40 Z",Card:"M275,60 L400,60 L400,110 L260,110 L260,75 Z",Delay:"M0,0 L12.029,0 C14.212999,0 16,1.7869979 16,3.9709952 C16,6.1549926 14.212999,7.9409904 12.029,7.9409904 L0,7.9409904 z",Preparation:"M 1048.17 572 C 1051.06 568.86 1055.17 567.05 1059.5 567 L 1094.51 567 C 1098.84 567.05 1102.95 568.86 1105.84 572 L 1126.43 595 C 1127.01 596.28 1127.01 597.72 1126.43 599 L 1105.84 622 C 1102.95 625.14 1098.84 626.95 1094.51 627 L 1059.5 627 C 1055.17 626.95 1051.06 625.14 1048.17 622 L 1027.58 599 C 1027 597.72 1027 596.28 1027.58 595 L 1048.17 572 Z",Display:"M47.8809,19.2914 L32.7968,-0.00594145 L11.3902,-0.00594145 C7.93166,-0.00594145 0.00124586,11.187 0.00124586,24.9968C0.00124586,38.8032 7.93166,49.9962 11.3902,49.9962 L32.7968,49.99 L47.615,31.038 C47.615,31.0388 52.798,24.9968 47.880,19.2914 z",ManualInput:"M 912 732 L 1006.85 707 C 1008.2 707 1009.5 707.53 1010.46 708.46 C 1011.41 709.4 1011.95 710.67 1011.95 712 L 1011.95 762C 1012 764.41 1010.28 766.52 1007.87 767 L 917.1 767 C 915.75 767 914.45 766.47 913.49 765.54 C 912.54 764.6 912 763.33 912 762 L 912 732 Z",LoopLimit:"M 8 9 L 27 9 L 33 15 L 33 26 C 33 27 33 27 32 27 L 4 27 C 3 27 2 27 2 26 L 2 15 L 8 9 Z",StoredData:"M 5.55 0L 50 0A 1.5,30 0 0,1 50,0A 5.555,25 0 0,0 50,50A 1.5,30 0 0,1 50,50L 5.555 50A 5.55,25 0 0,1 5.555,0Z"};function s3(n,t,e){var i;i="Straight"!==n.type&&n.sourceWrapper?n.sourceWrapper.corners.center:function lre(n){var t;if(n.sourcePortWrapper){var e=n.sourcePortWrapper;t={x:e.offsetX,y:e.offsetY}}else t=n.sourceID&&n.sourceWrapper&&n.targetWrapper?Ah(n,0,n.sourceWrapper.corners.center,n.targetWrapper.corners.center,!1):n.sourcePoint;return t}(n);var r=function cre(n,t,e,i,r){var b,M,s=n.sourceWrapper,o=n.targetWrapper,a=n.sourcePortWrapper,l=n.targetPortWrapper,d=[],f=Ga(n),y={corners:undefined,point:t,direction:undefined,margin:{left:5,right:5,bottom:5,top:5}},S={corners:undefined,point:e,direction:undefined,margin:{left:5,right:5,bottom:5,top:5}};if(void 0!==s&&void 0!==o&&(b=En(s),M=En(o),y.corners=s.corners,S.corners=o.corners),void 0!==a&&(y.direction="Left"===a.connectionDirection||"Top"===a.connectionDirection||"Bottom"===a.connectionDirection||"Right"===a.connectionDirection?a.connectionDirection:zo({x:a.offsetX,y:a.offsetY},b,s.bounds)),void 0!==l&&(S.direction="Left"===l.connectionDirection||"Right"===l.connectionDirection||"Bottom"===l.connectionDirection||"Top"===l.connectionDirection?l.connectionDirection:zo({x:l.offsetX,y:l.offsetY},M,o.bounds)),"Bezier"===n.type&&!n.isBezierEditing&&n.segments.length>0)for(var D=n.segments.length-1;D>=0;)n.segments[parseInt(D.toString(),10)].isInternalSegment&&n.segments.pop(),D--;if(void 0!==s&&void 0!==o)return(void 0===y.direction||void 0===S.direction)&&(i?function hre(n,t,e){"LeftToRight"===e?(n.direction=n.direction?n.direction:"Right",t.direction=t.direction?t.direction:"Left"):"RightToLeft"===e?(n.direction=n.direction?n.direction:"Left",t.direction=t.direction?t.direction:"Right"):"TopToBottom"===e?(n.direction=n.direction?n.direction:"Bottom",t.direction=t.direction?t.direction:"Top"):"BottomToTop"===e&&(n.direction=n.direction?n.direction:"Top",t.direction=t.direction?t.direction:"Bottom")}(y,S,i):y.corners.top>S.corners.bottom&&Math.abs(y.corners.top-S.corners.bottom)>f?(y.direction=y.direction?y.direction:"Top",S.direction=S.direction?S.direction:"Bottom"):y.corners.bottomf?(y.direction=y.direction?y.direction:"Bottom",S.direction=S.direction?S.direction:"Top"):y.corners.rightf||y.corners.right+f=y.corners.left-f&&y.corners.left>S.corners.left?(y.direction=y.direction?y.direction:"Right",S.direction=S.direction?S.direction:"Left"):y.corners.left>S.corners.right&&Math.abs(y.corners.left-S.corners.right)>y.margin.left+y.margin.right||S.corners.right+f=S.corners.left-f&&y.corners.left0&&n.segments[0].direction&&(y.direction=n.segments[0].direction),y.point=Tc(b,y.direction),d=Tc(b,ls(y.direction)),y.point=Ah(n,0,y.point,d,!1)):y.point=o.corners.center;if(void 0!==h){switch(S.point={x:h.offsetX,y:h.offsetY},S.direction){case"Bottom":case"Top":S.point.y=S.point.y;break;case"Left":case"Right":S.point.x=S.point.x}n.targetPadding&&!w&&(S.point=bI(n,y,S,!0))}else"Orthogonal"===n.type||"Bezier"===n.type?(S.point=Tc(M,S.direction),d=Tc(M,ls(S.direction)),S.point=Ah(n,0,S.point,d,!0)):S.point=a.corners.center;if("Orthogonal"!==n.type){var C=void 0,D=void 0;if("Bezier"===n.type){if(n.bezierSettings.allowSegmentsReset||0===n.segments.length||!z.isEmptyPoint(n.segments[n.segments.length-1].point))return c=g3(n,y,S,void 0,s),Tx(n,y,S);Bv(n)}else Bv(n);if(void 0===n.sourcePortWrapper){y.point=y.corners.center,n.segments&&n.segments.length>0&&(C=z.isEmptyPoint((D=n.segments[0]).point)?void 0:D);var A=void 0!==C?C.point:S.point;if("Bezier"===n.type&&n.segments.length>0&&n.segments[0].vector1.angle&&n.segments[0].vector1.distance){var x=Math.max(y.corners.width,y.corners.height);A=z.transform(y.point,n.segments[0].vector1.angle,x/2)}y.point=w?n.sourceWrapper.bounds.center:Ah(n,0,y.point,A,!1)}if(void 0===n.targetPortWrapper){S.point=S.corners.center,n.segments&&n.segments.length>1&&(C=z.isEmptyPoint((D=n.segments[n.segments.length-2]).point)?void 0:D);var R=C?C.point:y.point;"Bezier"===n.type&&n.segments.length>0&&n.segments[n.segments.length-1].vector2.angle&&n.segments[n.segments.length-1].vector2.distance&&(x=Math.max(y.corners.width,y.corners.height),R=z.transform(S.point,n.segments[0].vector2.angle,x/2)),S.point=w?n.targetWrapper.bounds.center:Ah(n,0,R,S.point,!0)}c=Tx(n,y,S)}else"Orthogonal"===n.type&&n.segments&&n.segments.length>0&&null!==n.segments[0].direction?c=function Ire(n,t,e,i,r,s,o){var a,h,c,d;Bv(n);for(var u=0;u0&&n.segments[u-1].direction===h.direction?u=u3(n,u,t):h.direction?t.point=o3(t,n.segments[parseInt(u.toString(),10)]):(p=n.segments[u-1])&&p.points&&(t.point=p.points[p.points.length-1]),u===n.segments.length-1)if(p3(n,t),c3(a=void 0===r?Sre(n,t,e):l3(n,t,e),n),h.points=[],a.length>=2)for(c=0;c2&&n.segments.length>2){var f={x:a[parseInt(c.toString(),10)].x,y:t.point.y};h.points=[],h.points.push(f),h.points.push(a[parseInt(c.toString(),10)]);var p=n.segments[u-1];n.segments.length<4&&p.points.pop(),p.points=p.points.concat(h.points)}else h.points.push(a[parseInt(c.toString(),10)]);else h.points.push(a[parseInt(c.toString(),10)]);else d=u;if(void 0!==d&&!n.selectedSegmentIndex&&(d===n.segments.length-1&&(n.segments[d-1].direction=null,n.segments[d-1].length=null),n.segments.splice(d,1)),i&&0===u){var g=h3(n,i,s);g&&(t.point=g)}}return f3(n,[])}(n,y,S,l,h,o):(n.segments[0]||(C=new bi(n,"segments",{type:"Orthogonal"},!0),n.segments.push(C)),n.segments[0].points=c=g3(n,y,S,void 0,s));return c}(n,y.direction,S.direction,y.point,S.point,r);if(Bv(n),(n.sourceWrapper||n.targetWrapper)&&function gre(n,t,e){var i=n.sourcePortWrapper,r=n.targetPortWrapper,s=n.sourceWrapper,o=t.point,a={left:0,right:0,top:0,bottom:0},l={x:0,y:0},c="Top";if(s?(o=e.point,a=t.margin):(s=n.targetWrapper,a=e.margin),"Orthogonal"===n.type)if(n.segments&&n.segments.length>0&&n.sourceWrapper&&n.segments[0].direction)t.direction=n.segments[0].direction,l=Ah(n,0,l=Tc(s.corners,t.direction),Tc(s.corners,ls(t.direction)),!1);else{var u={corners:null,direction:null,point:null,margin:null};Fv(s,{corners:null,direction:null,point:o,margin:a},u,n),l=u.point,c=u.direction}else{var p=void 0;n.segments&&n.segments.length>1&&(p=s===n.sourceWrapper?n.segments[0].point:n.segments[n.segments.length-2].point),l=Ah(n,0,s.bounds.center,n.segments&&n.segments.length>1?p:o,s===n.targetWrapper)}s===n.sourceWrapper?(t.direction=t.direction||c,t.point=l,n.sourcePortWrapper&&(t.point={x:i.offsetX,y:i.offsetY},n.sourcePadding&&(t.point=bI(n,t,e,!1)))):(e.direction=e.direction||c,e.point=l,n.targetPortWrapper&&(e.point={x:r.offsetX,y:r.offsetY},n.targetPadding&&(e.point=bI(n,t,e,!0))))}(n,y,S),"Straight"===n.type||"Bezier"===n.type)d=Tx(n,y,S);else if("Orthogonal"===n.type&&n.segments&&n.segments.length>0&&null!==n.segments[0].length&&null!==n.segments[0].direction)d=function fre(n,t,e,i,r,s,o){var a,l,c,u,h=[];if(Bv(n),n.segments.length>0){for(var p=0;p0&&n.segments[p-1].direction===f.direction)p=u3(n,p,t);else{var g=n.segments[p-1];t.point=f.direction?o3(t,f):g.points[g.points.length-1]}if(p===n.segments.length-1&&(o||r?n.targetWrapper&&void 0===n.targetPortWrapper?(p3(n,t),l=ure(n,t,e)):l=l3(n,t,e):l=dre(n,t,e),l))if(c3(l,n),f.points=[],l.length>=2)for(a=0;at.corners.top&&e.point.ye.point.x?"Left":"Right"):e.point.x>t.corners.left&&e.point.xe.point.y?"Top":"Bottom")),n.sourcePortWrapper&&s===ls(r)?(("Left"===s||"Right"===s)&&t.point.y>=t.corners.top&&t.point.y<=t.corners.center.y&&e.point.y>=t.corners.top&&e.point.y<=t.corners.center.y?(t.direction="Top",a=t.point.y-t.corners.top+20):("Left"===s||"Right"===s)&&t.point.y>t.corners.center.y&&t.point.y<=t.corners.bottom&&e.point.y>t.corners.center.y&&e.point.y<=t.corners.bottom?(t.direction="Bottom",a=t.corners.bottom-t.point.y+20):("Top"===s||"Bottom"===s)&&t.point.x>=t.corners.left&&t.point.x<=t.corners.center.x&&e.point.x>=t.corners.left&&e.point.x<=t.corners.center.x?(t.direction="Left",a=t.point.x-t.corners.left+20):("Top"===s||"Bottom"===s)&&t.point.x<=t.corners.right&&t.point.x>t.corners.center.x&&e.point.x<=t.corners.right&&e.point.xt.point.y&&t.point.y>=e.corners.top?(i="Top",r=t.point.y-e.corners.top+20):e.corners.center.y===t.point.y&&"Top"===n.segments[n.segments.length-2].direction||e.corners.center.ye.point.y?t.point.y-t.corners.top+20:t.corners.bottom-t.point.y+20):(i="Top",r=e.corners.height/2+20):e.corners.center.x!==t.point.x||e.corners.topt.point.x&&t.point.x>=e.corners.left?(i="Left",r=t.point.x-e.corners.left+20):e.corners.center.x===t.point.x&&"Left"===n.segments[n.segments.length-2].direction||e.corners.center.x<=t.point.x&&t.point.x<=e.corners.right?(i="Right",r=e.corners.right-t.point.x+20):void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&t.corners.left<=t.point.x&&t.point.x<=t.corners.right&&(i=t.direction,r=t.point.x>e.point.x?t.point.x-t.corners.left+20:t.corners.right-t.point.x+20):(i="Left",r=e.corners.width/2+20);var a=t.point;t.point=Bn(t.point,"Left"===i||"Top"===i?-r:r,"Left"===i||"Right"===i?0:90),t.direction=z.direction(t.point,e.point),void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&(t.corners.center.x===e.corners.center.x||t.corners.center.y===e.corners.center.y)&&(t.direction=e.direction);var l=Ys(n,t,e);return l.splice(0,0,a),l}function l3(n,t,e){var i,r;e.corners=n.targetWrapper.corners,void 0!==n.sourcePortWrapper&&(r=zo({x:n.sourcePortWrapper.offsetX,y:n.sourcePortWrapper.offsetY},En(n.sourceWrapper),n.sourceWrapper.bounds));var a=function pre(n,t,e,i){var r=!1;switch(e.direction){case"Left":void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&"Right"===i&&t.point.x>e.point.x&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom||("Bottom"===i&&t.point.y>e.point.y||"Top"===i&&t.point.y=t.corners.left&&t.point.x<=t.corners.right?(t.direction="Right"===i?t.point.y>e.point.y?"Top":"Bottom":t.point.xe.point.x&&(t.point.y>e.point.y||t.point.yt.point.y&&e.corners.bottome.point.y||t.point.x>e.point.x&&t.point.y<=e.point.y&&e.corners.top=t.point.y?t.direction="Top":t.point.xe.point.x&&t.point.y>e.point.y&&e.corners.bottomt.point.y?t.direction="Bottom":t.point.y===e.point.y&&t.point.xe.point.y||"Top"===i&&t.point.ye.point.x&&t.point.x>=t.corners.left&&t.point.x<=t.corners.right?(t.direction=t.point.x>e.point.x?"Left":"Right",r=!0):void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&"Left"===i&&t.point.x=t.corners.top&&t.point.y<=t.corners.bottom?(t.direction=t.point.y>e.point.y?"Top":"Bottom",r=!0):t.point.x=t.point.y&&t.point.y===e.point.y||t.point.y>e.point.y&&t.point.x>e.point.x?t.direction="Top":t.point.ye.point.x?t.direction="Bottom":t.point.xe.point.y||t.point.ye.point.x&&(t.direction="Left");break;case"Top":void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&"Bottom"===i&&t.point.y>e.point.y&&t.point.x>=t.corners.left&&t.point.x<=t.corners.right||("Right"===i&&t.point.x>e.point.x||"Left"===i&&e.point.y>t.point.y&&e.point.x>t.point.x)&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom?(t.direction="Bottom"===i?t.point.x>e.point.x?"Left":"Right":t.point.ye.point.y&&t.point.x>e.corners.left&&t.point.x=e.point.y?t.direction="Top":t.point.ye.point.x?t.direction="Left":t.point.yt.point.x)&&t.point.y>e.point.y&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom||"Top"===i&&t.point.y=t.corners.left&&t.point.x<=t.corners.right)?(t.direction="Right"===i||"Left"===i?t.point.y>e.point.y?"Top":"Bottom":t.point.x>e.point.x?"Left":"Right",r=!0):t.point.ye.corners.left&&e.corners.right>t.point.x?t.point.ye.corners.left&&e.corners.center.x>=t.point.x?t.direction="Left":t.point.ye.point.y&&t.point.x>e.point.x?t.direction="Left":t.point.y>e.point.y&&t.point.xe.point.x||e.point.x>t.point.x)&&(t.direction="Bottom")}return r}(n,t,e,r);return!n.selectedSegmentIndex&&void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&e.direction===ls(r)&&(("Left"===e.direction&&t.point.x>e.point.x||"Right"===e.direction&&t.point.x=t.corners.top&&t.point.y<=t.corners.bottom||"Bottom"===e.direction&&t.point.y=t.corners.left&&t.point.x<=t.corners.right)?i=a3(n,t,e):n.selectedSegmentIndex||t.direction!==e.direction?!n.selectedSegmentIndex&&("Left"===e.direction&&t.point.x>e.point.x||"Right"===e.direction&&t.point.x=t.point.y||"Top"===e.direction&&t.point.y>e.point.y||"Bottom"===e.direction&&t.point.y=t.point.x?i=n.selectedSegmentIndex?Ll(t,e):a3(n,t,e):!n.selectedSegmentIndex&&void 0!==n.sourceWrapper&&void 0!==n.targetWrapper&&void 0!==n.targetPortWrapper&&("Left"===t.direction||"Right"===t.direction)&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom&&("Top"===e.direction||"Bottom"===e.direction)&&e.corners.center.x===t.corners.center.x?(t.direction="Top"===e.direction?"Bottom":"Top",i=Ys(n,t,e,"Top"===e.direction?t.corners.bottom-t.point.y+20:t.point.y-t.corners.top+20)):!n.selectedSegmentIndex&&void 0!==n.sourceWrapper&&void 0!==n.targetWrapper&&void 0!==n.targetPortWrapper&&("Top"===t.direction||"Bottom"===t.direction)&&t.point.x>=t.corners.left&&t.point.x<=t.corners.right&&("Left"===e.direction||"Right"===e.direction)&&e.corners.center.y===t.corners.center.y?(t.direction="Left"===e.direction?"Right":"Left",i=Ys(n,t,e,"Left"===e.direction?t.corners.right-t.point.x+20:t.point.x-t.corners.left+20)):i=a?Ys(n,t,e,"Left"===t.direction||"Right"===t.direction?"Left"===t.direction?t.point.x-t.corners.left+20:t.corners.right-t.point.x+20:"Top"===t.direction?t.point.y-t.corners.top+20:t.corners.bottom-t.point.y+20):Ll(t,e):i=Ys(n,t,e),i}function h3(n,t,e){var r,i={x:t.offsetX,y:t.offsetY},s=En(e),o=zo(i,s,e.bounds),a=n.segments[0];return a.direction!==o&&(function bre(n,t,e,i,r,s){var a,h,o=13,l=[];l.push(i),i.y===r.y&&("Left"===t&&r.xi.x)||i.x===r.x&&("Top"===t&&r.yi.y)||("Top"===t||"Bottom"===t?"Top"===t&&r.yi.y-o||"Bottom"===t&&r.y>i.y&&r.yo&&("Top"===t&&r.yi.y)?l.push({x:i.x,y:r.y}):(a=r.xi.x-o||"right"===t&&r.x>i.x&&r.xo&&("Left"===t&&r.xi.x)?l.push({x:r.x,y:i.y}):(l.push({x:a="Left"===t?e.left-o:e.right+o,y:i.y}),l.push({x:a,y:r.y})),s&&(l.push(n.points[0]),l.reverse()),n.points=l)}(a,o,s,a.points[0],a.points[a.points.length-1],!1),r=a.points[a.points.length-1],a.direction=z.direction(a.points[a.points.length-2],a.points[a.points.length-1])),r}function c3(n,t,e){var s,i=t.segments[t.segments.length-2],r=i.points[i.points.length-1];(("Top"===i.direction||"Bottom"===i.direction)&&r.x===n[1].x||("Left"===i.direction||"Right"===i.direction)&&r.y===n[1].y)&&(i.points[i.points.length-1]=n[1],s=z.direction(i.points[0],i.points[i.points.length-1]),void 0!==t.sourceWrapper&&void 0===t.sourcePortWrapper&&s===ls(i.direction)&&("Left"===i.direction||"Right"===i.direction?i.points[0].x="Right"===i.direction?i.points[0].x-t.sourceWrapper.corners.width:i.points[0].x+t.sourceWrapper.corners.width:i.points[0].y="Bottom"===i.direction?i.points[0].y-t.sourceWrapper.corners.height:i.points[0].y+t.sourceWrapper.corners.height),i.direction=s,i.length=z.distancePoints(i.points[0],i.points[i.points.length-1]),n.splice(0,1))}function bI(n,t,e,i){var o=i?n.targetPadding:n.sourcePadding,a=i?n.targetPortWrapper:n.sourcePortWrapper,l=new Ne(a.bounds.x-o,a.bounds.y-o,a.actualSize.width+2*o,a.actualSize.height+2*o),h=[l.topLeft,l.topRight,l.bottomRight,l.bottomLeft];h[h.length]=h[0];var d=i?e.point:t.point;return Lx({x1:t.point.x,y1:t.point.y,x2:e.point.x,y2:e.point.y},h,0,d)||d}function d3(n,t){var e=[],i=dF(0,n.corners,t);i.push(i[0]);for(var r=0;r0){var r=void 0,s=[],o=t.point;for(r=0;r1&&z.equals(a.points[0],a.points[1])&&n.segments.splice(r,1),a)for(var l=0;l0||0===r)&&i.push(a.points[parseInt(l.toString(),10)])}}return i}function Ax(n,t,e){return"Top"===n||"Bottom"===n?e.x>t.x?"Right":"Left":e.y>t.y?"Bottom":"Top"}function Bv(n){if("Straight"===n.type||"Bezier"===n.type){if(0===n.segments.length||n.segments.length>0&&!z.isEmptyPoint(n.segments[n.segments.length-1].point))if("Bezier"===n.type){var t=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0},!0);n.segments.push(t)}else t=new kl(n,"segments",{type:"Straight"},!0),n.segments.push(t)}else{if(n.segments.length>0)for(var e=!1,i=0;i=t.corners.left&&e.point.x<=t.corners.right&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom)t.direction=e.point.y>t.point.y?"Bottom":"Top",i=Ys(n,t,e,"Top"===t.direction?t.point.y-t.corners.top+20:t.corners.bottom-t.point.y+20);else if(n.sourcePortWrapper&&r===ls(o)){var h;("Left"===r||"Right"===r)&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom?(t.direction=e.point.y>t.point.y?"Bottom":"Top",h=t.corners.height/2+20):("Top"===r||"Bottom"===r)&&t.point.x>=t.corners.left&&t.point.x<=t.corners.right&&(t.direction=e.point.x>t.point.x?"Right":"Left",h=t.corners.width/2+20),t.direction&&h?i=Ys(n,t,e,h,!0):(t.direction=o,i=Ll(t,e))}else if(!n.sourcePortWrapper||r!==e.direction||"Top"!==r&&"Bottom"!==r||t.corners.center.x!==e.corners.center.x)if(t.direction===e.direction)if(("Left"===t.direction||"Right"===t.direction)&&e.point.y>t.corners.top-20&&e.point.yt.corners.left-20&&e.point.xt.point.y?"Bottom":"Top",i=Ys(n,t,e,"Bottom"===t.direction?t.corners.bottom-t.point.y+20:t.point.y-t.corners.top+20);else t.direction=o,i=Ys(n,t,e,"Top"===o||"Bottom"===o?n.sourceWrapper.height/2+20:n.sourceWrapper.width/2+20),t.point=i[1],"Left"===o||"Right"===o?(e.direction=o,e.point="Left"===o?e.corners.middleLeft:e.corners.middleRight):Fv(n.targetWrapper,t,e,n),i=Ys(n,t,e);return i}function p3(n,t){if(void 0!==n.targetWrapper&&void 0===n.targetPortWrapper&&En(n.targetWrapper).containsPoint(t.point,1)){var i=n.targetWrapper,r=n.segments[n.segments.length-2],s=r.points[r.points.length-1],o=ls(r.direction);"Bottom"===o?s.yi.corners.top-1&&(r.points[r.points.length-1].y=i.corners.top-20,r.length=z.distancePoints(r.points[0],r.points[r.points.length-1])):"Left"===o?s.x>i.corners.left-1&&(r.points[r.points.length-1].x=i.corners.left-20,r.length=z.distancePoints(r.points[0],r.points[r.points.length-1])):"Right"===o&&s.x0||0===e)&&t.push(i.points[parseInt(r.toString(),10)]);return t}function Fv(n,t,e,i){var r,s={x:0,y:0},o=MI(n,n.corners,n.bounds),a=t.margin,l=t.point;if(o.bottomCenter.y+a.bottoml.y)r="Top",s=o.topCenter;else if(o.middleLeft.x-a.left>l.x)r="Left",s=o.middleLeft;else if(o.middleRight.x+a.rightc&&(p=c,r="Right",s=o.middleRight),p>d&&(p=d,r="Bottom",s=o.bottomCenter),p>u&&(r="Left",s=o.middleLeft)}e.point=s,e.direction=r;var f=Tc(o,ls(e.direction));e.point=Ah(i,0,e.point,f,n===i.targetWrapper)}function g3(n,t,e,i,r){var s,o,a;if(s=function zre(n,t){var e=!1;switch(n){case"Left":switch(t){case"Right":case"Bottom":e=!0}break;case"Top":switch(t){case"Left":case"Right":case"Bottom":e=!0}break;case"Bottom":"Right"===t&&(e=!0)}return e}(t.direction,e.direction),s&&b3(t,e),"Right"===t.direction&&"Left"===e.direction)a=function Mre(n,t,e,i){var o=Math.round(Math.abs(t.point.y-e.point.y)),a={x:Math.max(t.point.x,t.corners.right),y:t.point.y},l={x:Math.min(e.point.x,e.corners.left),y:e.point.y},h=Ga(n);if(i){var c=l;l=a,a=c}return t.corners.bottom+he.corners.bottom+h||("Bezier"!==n.type||e.corners.left-t.corners.right<=2*h&&e.corners.left-t.corners.right>=5)&&(h=0),t.margin={left:h,right:h,top:h,bottom:h},e.margin={left:h,right:h,top:h,bottom:h},0===o&&(t.corners.right=e.corners.right?void 0!==i&&(i.offsetYe.corners.bottom+e.margin.bottom)||void 0===i&&t.corners.middleRight.ye.corners.bottom+e.margin.bottom&&t.corners.top>e.corners.bottom||void 0===i&&t.corners.middleRight.y>e.corners.bottom||void 0!==i&&i.offsetYe.corners.top||void 0===i&&t.corners.middleRight.y>e.corners.bottom?Ae.Three:t.corners.rightr.offsetY+e.margin.right||void 0===r&&t.corners.top>e.corners.middleRight.y||void 0!==r&&(void 0!==i&&i.offsetXr.offsetX||void 0===r&&t.corners.left>e.corners.topCenter.x?Ae.Four:Ae.Two:void 0!==s&&Math.abs(t.corners.right-e.corners.left)<=5&&Math.abs(s.offsetY-e.corners.top)<=5||void 0!==r&&t.corners.right=25&&t.corners.middleRight.y+t.margin.righte.corners.bottom+e.margin.bottom||void 0===o&&t.corners.middleRight.y>e.corners.bottom+e.margin.bottom?t.corners.top>e.corners.bottom?void 0!==a&&t.corners.right+t.margin.righta.offsetX||void 0===a&&t.corners.left>e.corners.bottomCenter.x?Ae.Four:Ae.Two:void 0!==o&&Math.abs(t.corners.right-e.corners.left)<=25&&Math.abs(o.offsetY-e.corners.bottom)<=25?Ae.Two:Ae.Four}(n,t,e,s);else if("Bottom"===t.direction&&"Top"===e.direction)a=function Dre(n,t,e){var r=t.point.x-e.point.x,s=Ga(n);return t.corners.right+se.corners.right+s||("Bezier"!==n.type||e.corners.top-t.corners.bottom<=2*s&&e.corners.top-t.corners.bottom>=5)&&(s=0),t.margin={left:s,right:s,top:s,bottom:s},e.margin={left:s,right:s,top:s,bottom:s},0===r&&t.corners.bottome.corners.right+e.margin.right||void 0===i&&t.corners.bottomCenter.x>e.corners.right+e.margin.right?Ae.Three:t.corners.bottomr.offsetX||void 0===r&&t.corners.left>e.corners.left||void 0!==r&&t.corners.right+t.margin.righte.corners.bottom?Ae.Five:0===s||0===o?Ae.One:Ae.Three}(n,t,e)}else"Bottom"===t.direction&&"Left"===e.direction?a=function xre(n,t,e,i){var r=n.sourcePortWrapper,s=n.targetPortWrapper,o=Ga(n);if(e.margin={left:o,right:o,top:o,bottom:o},t.margin={top:o,bottom:o,left:o,right:o},i){var l=r;r=s,s=l}return void 0!==r&&r.offsetXs.offsetY||void 0===s&&t.corners.top>e.corners.middleLeft.y?Ae.Four:Ae.Two:void 0!==s&&Math.abs(t.corners.right-e.corners.left)<=25&&Math.abs(s.offsetY-t.corners.bottom)<=25?Ae.Two:Ae.Four}(n,t,e,s):"Left"===t.direction&&"Left"===e.direction?a=function Lre(n,t,e){var i=n.sourcePortWrapper,r=n.targetPortWrapper,s=Ga(n);t.margin={left:s,right:s,top:s,bottom:s},e.margin={left:s,right:s,top:s,bottom:s};var o=Math.round(Math.abs(t.point.x-e.point.x)),a=Math.round(Math.abs(t.point.y-e.point.y));return t.corners.leftr.offsetY||void 0===r&&t.corners.top-t.margin.top>e.corners.middleLeft.y?Ae.Three:t.corners.righte.corners.bottom+e.margin.bottom||void 0===i&&t.corners.middleLeft.y>e.corners.bottom+e.margin.bottom?Ae.Three:t.corners.left>e.corners.right?Ae.Five:0===o||0===a?Ae.One:Ae.Three}(n,t,e):"Left"===t.direction&&"Top"===e.direction?a=function Are(n,t,e,i){var s=n.sourcePortWrapper,o=Ga(n);e.margin={left:o,right:o,top:o,bottom:o},t.margin={top:o,bottom:o,left:o,right:o};var a=n.targetPortWrapper,l={x:Math.min(t.point.x,t.corners.left),y:t.point.y},h={x:e.point.x,y:Math.min(e.point.y,e.corners.top)};if(i){var c=s;s=a,a=c;var d=l;l=h,h=d}return void 0!==s&&s.offsetYa.offsetX||void 0===a&&t.corners.left-t.margin.left>e.corners.topCenter.x?Ae.Two:Ae.Four:void 0!==a&&t.corners.rightr.offsetX||void 0===r&&t.corners.left>e.corners.left||void 0!==r&&t.corners.right+t.margin.righte.corners.right+e.margin.right||void 0===i&&t.corners.left>e.corners.right||void 0!==i&&i.offsetXe.corners.bottom?Ae.Five:0===s||0===o?Ae.One:Ae.Three}(n,t,e));return s&&b3(t,e),o=function Ore(n,t,e,i,r,s){var l,d,h=n.sourceWrapper.corners,c=n.targetWrapper.corners,u=20,p={corners:e.corners,point:e.point,direction:e.direction,margin:e.margin},f={corners:i.corners,point:i.point,direction:i.direction,margin:i.margin};if(!(p.direction===f.direction&&t!==Ae.Five||p.direction!==ls(f.direction)&&t!==Ae.Three))switch(p.direction){case"Left":h.middleLeft.x>c.middleRight.x&&(d=(h.middleLeft.x-c.middleRight.x)/2,u=s?d:Math.min(u,d));break;case"Right":h.middleRight.xc.bottomCenter.y&&(d=(h.topCenter.y-c.bottomCenter.y)/2,u=s?d:Math.min(u,d));break;case"Bottom":h.bottomCenter.yp&&hp)&&o>c&&o<=d&&e>=20&&(s=n.point.x-t.corners.left+s),i&&n.direction===t.direction&&n.corners.left>t.corners.left&&n.corners.left-t.corners.right>=20&&(s=(n.corners.left-t.corners.right)/2),f=Bn(n.point,s,180);break;case"Top":(o>c&&oc)&&h>p&&h<=u&&e>=20&&(s=n.point.y-t.corners.top+s),i&&n.direction===t.direction&&n.corners.top>t.corners.top&&n.corners.top-t.corners.bottom>=20&&(s=(n.corners.top-t.corners.bottom)/2),f=Bn(n.point,s,270);break;case"Right":(h>p&&hp)&&a=c&&e>=20&&(s=t.corners.right-n.point.x+s),i&&n.direction===t.direction&&n.corners.right=20&&(s=(t.corners.left-n.corners.right)/2),f=Bn(n.point,s,0);break;case"Bottom":(o>c&&oc)&&l=p&&e>=20&&(s=t.corners.bottom-n.point.y+s),i&&n.direction===t.direction&&n.corners.bottom=20&&(s=(t.corners.top-n.corners.bottom)/2),f=Bn(n.point,s,90)}r=[n.point,f];var g=void 0;if("Top"===n.direction||"Bottom"===n.direction){var v=n.direction;n.direction=f.x>t.point.x?"Left":"Right",n.point=f,r=wI(n,t,v,r,g=i?.5*Math.abs(f.x-t.point.x):g,i)}else v=n.direction,n.direction=f.y>t.point.y?"Top":"Bottom",n.point=f,r=wI(n,t,v,r,g=i?.5*Math.abs(f.y-t.point.y):g,i);return r}(p,f,u,g)),l}(n,a,t,e,i,r),"Bezier"===n.type&&function Pre(n,t,e){if("Bezier"===n.type)if(0===n.segments.length){var i=e[0],r=e[e.length-1];if(t===Ae.One){var s=Math.min(20,.5*z.findLength(i,r)),o={angle:Xt(i,r),distance:s},a={angle:Xt(r,i),distance:s},l=z.direction(i,r),c=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,orientation:"Left"===l||"Right"===l?"Horizontal":"Vertical"},!0);n.segments.push(c)}else if(t===Ae.Two)o={angle:Xt(i,d=e[1]),distance:.5*z.findLength(i,d)},a={angle:Xt(r,d),distance:.5*z.findLength(r,d)},l=z.direction(i,d),c=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,orientation:"Left"===l||"Right"===l?"Horizontal":"Vertical"},!0),n.segments.push(c);else if(t===Ae.Three){var d={x:.5*((u=e[1]).x+(p=e[e.length-2]).x),y:.5*(u.y+p.y)},f=(o={angle:Xt(i,u),distance:.5*z.findLength(i,u)},a={angle:Xt(d,u),distance:.5*z.findLength(d,u)},z.direction(i,u)),v=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,point:d,orientation:"Left"===f||"Right"===f?"Horizontal":"Vertical"},!0);n.segments.push(v);var y={angle:Xt(d,p),distance:.5*z.findLength(d,p)},S={angle:Xt(r,p),distance:.5*z.findLength(r,p)},b=z.direction(d,p),w=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:y,vector2:S,orientation:"Left"===b||"Right"===b?"Horizontal":"Vertical"},!0);n.segments.push(w)}else if(t===Ae.Four){var D={x:.5*((u=e[1]).x+(p=e[2]).x),y:.5*(u.y+p.y)},A={x:.5*(p.x+(C=e[3]).x),y:.5*(p.y+C.y)};o={angle:Xt(i,u),distance:.5*z.findLength(i,u)},a={angle:Xt(D,u),distance:.5*z.findLength(D,u)},f=z.direction(i,u),v=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,point:D,orientation:"Left"===f||"Right"===f?"Horizontal":"Vertical"},!0),n.segments.push(v),y={angle:Xt(D,p),distance:.5*z.findLength(D,p)},S={angle:Xt(A,p),distance:.5*z.findLength(A,p)},b=z.direction(D,p),w=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:y,vector2:S,point:A,orientation:"Left"===b||"Right"===b?"Horizontal":"Vertical"},!0),n.segments.push(w);var x={angle:Xt(A,C),distance:.5*z.findLength(A,C)},R={angle:Xt(r,C),distance:.5*z.findLength(r,C)},L=z.direction(A,C),N=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:x,vector2:R,orientation:"Left"===L||"Right"===L?"Horizontal":"Vertical"},!0);n.segments.push(N)}else if(t===Ae.Five){var u,p,C,T=e[4],P=(D={x:.5*((u=e[1]).x+(p=e[2]).x),y:.5*(u.y+p.y)},A={x:.5*(p.x+(C=e[3]).x),y:.5*(p.y+C.y)},{x:.5*(C.x+T.x),y:.5*(C.y+T.y)});o={angle:Xt(i,u),distance:.5*z.findLength(i,u)},a={angle:Xt(D,u),distance:.5*z.findLength(D,u)},f=z.direction(i,u),v=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,point:D,orientation:"Left"===f||"Right"===f?"Horizontal":"Vertical"},!0),n.segments.push(v),y={angle:Xt(D,p),distance:.5*z.findLength(D,p)},S={angle:Xt(A,p),distance:.5*z.findLength(A,p)},b=z.direction(D,p),w=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:y,vector2:S,point:A,orientation:"Left"===b||"Right"===b?"Horizontal":"Vertical"},!0),n.segments.push(w),x={angle:Xt(A,C),distance:.5*z.findLength(A,C)},R={angle:Xt(P,C),distance:.5*z.findLength(P,C)},L=z.direction(A,C),N=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:x,vector2:R,point:P,orientation:"Left"===L||"Right"===L?"Horizontal":"Vertical"},!0),n.segments.push(N);var _={angle:Xt(P,T),distance:.5*z.findLength(P,T)},B={angle:Xt(r,T),distance:.5*z.findLength(r,T)},j=z.direction(P,T),oe=new ps(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:_,vector2:B,orientation:"Left"===j||"Right"===j?"Horizontal":"Vertical"},!0);n.segments.push(oe)}else c=new ps(n,"segments",{type:"Bezier"},!0),n.segments.push(c)}else for(var ue=0;ue=13?13:n.connectorSpacing<=1?1:n.connectorSpacing}function Xt(n,t){var i=z.findLength({x:t.x,y:n.y},t),r=z.findLength(t,n),s=Math.asin(i/r);return s=180*s/Math.PI,n.xt.y&&(s=360-s):s=n.y0)for(var l=1;lc)&&(s=c,a=h),s>=0&&s<=1)break}}return a}function m3(n,t){var c,d,u,p,f,g,S,b,M,w,D,e=n.x1,i=n.y1,r=n.x2,s=n.y2,o=t.x1,a=t.y1,l=t.x2,h=t.y2;if(w=(c=s-i)*l+(u=e-r)*h+(f=r*i-e*s),0!==(M=c*o+u*a+f)&&0!==w&&y3(M,w)||(b=(d=h-a)*r+(p=o-l)*s+(g=l*a-o*h),0!==(S=d*e+p*i+g)&&0!==b&&y3(S,b)))return null;var A=c*p-d*u;return 0===A?null:(A<0?-A/2:A/2,0,{x:(D=u*g-p*f)<0?(D-0)/A:(D+0)/A,y:(D=d*f-c*g)<0?(D-0)/A:(D+0)/A})}function y3(n,t){return n*t>=0}function S3(n,t,e){switch(t.direction){case"Left":t.point.x>n.left&&(e=t.point.x-n.left>e?t.point.x-n.left+e:e);break;case"Right":t.point.xe?n.right-t.point.x+e:e);break;case"Top":t.point.y>n.top&&(e=t.point.y-n.top>e?t.point.y-n.top+e:e);break;case"Bottom":t.point.ye?n.bottom-t.point.y+e:e)}return e}function Ll(n,t){var e;switch(n.direction){case"Left":case"Right":var i={x:t.point.x,y:n.point.y};e=z.equals(n.point,i)||z.equals(t.point,i)?[n.point,t.point]:[n.point,i,t.point];break;case"Top":case"Bottom":var r={x:n.point.x,y:t.point.y};e=z.equals(n.point,r)||z.equals(t.point,r)?[n.point,t.point]:[n.point,r,t.point]}return e}function Ys(n,t,e,i,r,s){void 0===s&&(s=!1),i||(i=20),s&&t.direction!==e.direction&&(i="Left"===t.direction||"Right"===t.direction?Math.floor(.5*Math.abs(t.point.x-e.point.x)):Math.floor(.5*Math.abs(t.point.y-e.point.y)));var l,h,u,o=n.sourcePortWrapper,c=e.point.x-t.point.x,d=e.point.y-t.point.y;if(!r&&(Math.abs(c)<.001||Math.abs(d)<.001)&&void 0===e.direction)return[t.point,e.point];if(void 0===n.targetWrapper&&Math.abs(c)<=31&&Math.abs(d)<=31){if("Left"===t.direction||"Right"===t.direction?Math.abs(d)<12&&(t.direction=t.point.y>e.point.y?"Top":"Bottom"):Math.abs(c)<12&&(t.direction=t.point.x>e.point.x?"Left":"Right"),Math.abs(c)>12||Math.abs(d)>12)return Ll(t,e);i+=5}return"Left"===t.direction||"Right"===t.direction?("Right"===t.direction?(void 0!==e.direction&&"Right"===e.direction&&(i=Math.max(t.point.x,e.point.x)-t.point.x+i),t.point.x>e.point.x&&void 0===o&&(i=-i)):(void 0!==e.direction&&"Left"===e.direction&&(i=t.point.x-Math.min(t.point.x,e.point.x)+i),(t.point.x>e.point.x||void 0!==o||"Left"===t.direction)&&(i=-i)),u=e.point.y-t.point.y,l=Bn(t.point,i,0),0!=(u=e.point.y-l.y)&&(h=Bn(l,e.point.y-l.y,90))):("Top"===t.direction||"Bottom"===t.direction)&&("Bottom"===t.direction?void 0!==e.direction&&"Bottom"===e.direction&&(i=Math.max(t.point.y,e.point.y)-t.point.y+i):(void 0!==e.direction&&"Top"===e.direction&&(i=t.point.y-Math.min(t.point.y,e.point.y)+i),(t.point.y>e.point.y||void 0!==o||"Top"===t.direction)&&(i=-i)),u=e.point.x-t.point.x,l=Bn(t.point,i,90),0!=(u=e.point.x-l.x)&&(h=Bn(l,e.point.x-l.x,0))),0===u?[t.point,e.point]:[t.point,l,h,e.point]}function wI(n,t,e,i,r,s){var o;switch(void 0===r&&(r=20),void 0===s&&(s=!1),void 0===e?(n.margin={left:2,right:2,top:2,bottom:2},t.margin={left:0,right:5,top:0,bottom:5},s&&(n.margin={left:10,right:10,top:10,bottom:10},t.margin={left:10,right:10,top:10,bottom:10},"Left"===n.direction?(r=Ox(n,t,e,r),n.corners.left-t.corners.right>=5&&(r=Math.abs(n.point.x-n.corners.left)+.5*Math.floor(n.corners.left-t.corners.right))):"Right"===n.direction?(r=kx(n,t,r,e),t.corners.left-n.corners.right>=5&&(r=Math.abs(n.point.x-n.corners.right)+.5*Math.floor(t.corners.left-n.corners.right))):"Top"===n.direction?(r=Nx(n,t,e,r),n.corners.top-t.corners.bottom>=5&&(r=Math.abs(n.point.y-n.corners.top)+.5*Math.floor(n.corners.top-t.corners.bottom))):"Bottom"===n.direction&&(r=Px(n,t,r,e),t.corners.top-n.corners.bottom>=5&&(r=Math.abs(n.point.y-n.corners.bottom)+.5*Math.floor(t.corners.top-n.corners.bottom))))):("Bottom"===n.direction?s?t.corners.top-n.corners.bottom<20&&(r=t.corners.bottom-n.point.y+25):t.corners.top>n.corners.bottom&&t.corners.top-n.corners.bottom<20&&(r=(t.corners.top-n.corners.bottom)/2):"Top"===n.direction?s?n.corners.top-t.corners.bottom<20&&(r=n.point.y-t.corners.top+25):t.corners.bottomn.corners.right&&t.corners.left-n.corners.right<20&&(r=(t.corners.left-n.corners.right)/2):"Left"===n.direction&&(s?n.corners.left-t.corners.right<20&&(r=n.point.x-t.corners.left+25):t.corners.rightt.point.y||"Top"===t.direction&&n.point.yt.point.x||"Left"===t.direction&&n.point.xh||e.corners.top-e.margin.top<=i.point.y&&e.corners.bottom+e.margin.bottom>=i.point.y))if(!s||"Top"!==e.direction&&"Bottom"!==e.direction)c=Math.min(Math.abs(i.corners.left-e.corners.right)/2,20),h=e.corners.right-n.x+c;else{var c=Math.abs(i.corners.left-e.corners.right)/2;h=e.corners.right-n.x+c}else h="Top"===e.direction&&n.y>i.point.y||"Bottom"===e.direction&&n.y=e.corners.left-e.margin.left&&n.x<=e.corners.right+e.margin.right?Math.min(i.corners.left,e.corners.left)-n.x-20:i.corners.left-n.x-20;break;case"Right":if(e.corners.left-e.margin.left>i.corners.right+i.margin.right&&(e.corners.left-e.margin.right-i.corners.right>h||e.corners.top-e.margin.top<=i.point.y&&e.corners.bottom+e.margin.bottom>=i.point.y))if(!s||"Top"!==e.direction&&"Bottom"!==e.direction)c=Math.min(Math.abs(e.corners.left-i.corners.right)/2,20),h=e.corners.left-n.x-c;else{c=Math.abs(e.corners.left-i.corners.right)/2;h=e.corners.left-n.x-c}else h="Top"===e.direction&&n.y>i.point.y||"Bottom"===e.direction&&n.y=e.corners.left-e.margin.left&&n.x<=e.corners.right+e.margin.right?Math.max(i.corners.right,e.corners.right)-n.x+20:i.corners.right-n.x+20}o=Bn(n,h,0),a=Bn(o,i.point.y-n.y,90),l=i.point}else if("vertical"===t){switch(i.direction){case"Top":e.corners.bottom+e.margin.bottomh||e.corners.left-e.margin.left<=i.point.x&&e.corners.right+e.margin.right>=i.point.x)?!s||"Right"!==e.direction&&"Left"!==e.direction?(c=Math.min(Math.abs(i.corners.top-e.corners.bottom)/2,20),h=e.corners.bottom-n.y+c):(c=Math.abs(i.corners.top-e.corners.bottom)/2,h=e.corners.bottom-n.y+c):h="Left"===e.direction&&n.x>i.point.x||"Right"===e.direction&&n.x=e.corners.top-e.margin.top&&n.y<=e.corners.bottom+e.margin.bottom?Math.min(i.corners.top,e.corners.top)-n.y-20:i.corners.top-n.y-20;break;case"Bottom":e.corners.top-e.margin.top>i.corners.bottom+i.margin.bottom&&(e.corners.top-e.margin.top-i.corners.bottom>h||e.corners.left-e.margin.left<=i.point.x&&e.corners.right+e.margin.right>=i.point.x)?!s||"Right"!==e.direction&&"Left"!==e.direction?(c=Math.min(Math.abs(e.corners.top-i.corners.bottom)/2,20),h=e.corners.top-n.y-c):(c=Math.abs(e.corners.top-i.corners.bottom)/2,h=e.corners.top-n.y-c):h="Left"===e.direction&&n.x>i.point.x||"Right"===e.direction&&n.x=e.corners.top-e.margin.top&&n.y<=e.corners.bottom+e.margin.bottom?Math.max(i.corners.bottom,e.corners.bottom)-n.y+20:i.corners.bottom-n.y+20}o=Bn(n,h,90),a=Bn(o,i.point.x-n.x,0),l=i.point}r.push(o),r.push(a),r.push(l)}function Nx(n,t,e,i){return n.corners.top-n.margin.top>t.corners.top+t.margin.top&&n.corners.top-n.margin.top<=t.corners.bottom+t.margin.bottom?(("Right"===t.direction&&n.point.xt.point.x)&&(i+=n.corners.top-t.corners.top),i+=n.point.y-n.corners.top):i+=void 0!==e&&"Left"!==e&&"Right"===t.direction&&n.point.xt.corners.left-t.margin.left&&n.corners.left-n.margin.left<=t.corners.right+t.margin.right?(("Bottom"===t.direction&&n.point.yt.point.y)&&(i+=n.corners.left-t.corners.left),i+=n.point.x-n.corners.left):i+=void 0!==e&&"Top"!==e&&"Bottom"===t.direction&&n.point.y=t.corners.left-t.margin.left?(("Bottom"===t.direction&&n.point.yt.point.y)&&(e+=t.corners.right-n.corners.right),e+=n.corners.right-n.point.x):e+=void 0!==i&&"Top"!==i&&"Bottom"===t.direction&&n.point.y=t.corners.top-t.margin.top?(("Right"===t.direction&&n.point.xt.point.x)&&(e+=t.corners.bottom-n.corners.bottom),e+=n.corners.bottom-n.point.y):e+=void 0!==i&&"Left"!==i&&"Right"===t.direction&&n.point.xf&&d=u&&d=p&&d<=f?"Left":"Right"}function ls(n){switch(n){case"Top":return"Bottom";case"Bottom":return"Top";case"Left":return"Right";case"Right":return"Left"}return"auto"}var w3=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Ac=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},CI=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return w3(t,n),Ac([I()],t.prototype,"width",void 0),Ac([I()],t.prototype,"height",void 0),t}(Ee),Rre=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return w3(t,n),Ac([I()],t.prototype,"width",void 0),Ac([I()],t.prototype,"height",void 0),Ac([I()],t.prototype,"fit",void 0),Ac([I()],t.prototype,"description",void 0),Ac([I()],t.prototype,"template",void 0),Ac([I()],t.prototype,"tooltip",void 0),t}(Ee),Hre=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Nl=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},C3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Hre(t,n),Nl([I("")],t.prototype,"id",void 0),Nl([I(Number.MIN_VALUE)],t.prototype,"zIndex",void 0),Nl([re({},$n)],t.prototype,"margin",void 0),Nl([I(!0)],t.prototype,"visible",void 0),Nl([re({},Ed)],t.prototype,"tooltip",void 0),Nl([I(!1)],t.prototype,"excludeFromLayout",void 0),Nl([I()],t.prototype,"addInfo",void 0),Nl([I("None")],t.prototype,"flip",void 0),Nl([I("All")],t.prototype,"flipMode",void 0),Nl([re({},Rre)],t.prototype,"symbolInfo",void 0),t}(Ee),Bre=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Jn=function(n){function t(e,i,r,s){var o=n.call(this)||this;return o.data="",o.nodeId="",o.annotationId="",o.diagramId="",o.diagramId=i,o.nodeId=e,o.annotationId=r,o.templateFn=UF(s),o}return Bre(t,n),t.prototype.getNodeTemplate=function(){return this.templateFn},Object.defineProperty(t.prototype,"content",{get:function(){return this.data},set:function(e){this.data=e,this.canReset||(this.canReset=!0,this.isTemplate||(this.template=Rh(this,!0)),this.canReset=!1,this.isDirt=!0)},enumerable:!0,configurable:!0}),t}(as),zx=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),hs=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},E3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return zx(t,n),hs([I("")],t.prototype,"id",void 0),hs([I("transparent")],t.prototype,"fill",void 0),hs([I("black")],t.prototype,"iconStrokeColor",void 0),hs([I(0)],t.prototype,"iconStrokeWidth",void 0),hs([I(!0)],t.prototype,"visibility",void 0),hs([I(10)],t.prototype,"width",void 0),hs([I(10)],t.prototype,"height",void 0),hs([I("transparent")],t.prototype,"handleStrokeColor",void 0),hs([I(1)],t.prototype,"handleStrokeWidth",void 0),hs([I("")],t.prototype,"pathData",void 0),hs([I(0)],t.prototype,"cornerRadius",void 0),hs([re({left:0,right:0,top:0,bottom:0},$n)],t.prototype,"padding",void 0),hs([re({},Ed)],t.prototype,"tooltip",void 0),t}(Ee),D3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return zx(t,n),hs([re({x:0,y:0},z)],t.prototype,"offset",void 0),hs([re({},$n)],t.prototype,"margin",void 0),t}(E3),EI=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return zx(t,n),hs([I(.5)],t.prototype,"offset",void 0),hs([I("Center")],t.prototype,"alignment",void 0),hs([re({x:0,y:0},z)],t.prototype,"displacement",void 0),t}(E3);function Dd(n){return n?n instanceof Zn||n instanceof Nr?n.constraints&Lr.Select:n instanceof de?n.constraints&qe.Select:n.constraints&ie.Select:1}function to(n){return n?n instanceof Zn||n instanceof Nr?n.constraints&Lr.Drag:n instanceof de?n.constraints&qe.Drag:n instanceof oi?1:n.constraints&ie.Drag:1}function Fre(n,t){return n instanceof de?n.constraints&qe.PointerEvents:n.constraints&ie.PointerEvents}function DI(n){return n instanceof de?n.constraints&qe.Delete:n.constraints&ie.Delete}function xI(n){return n.constraints&qe.DragSourceEnd}function TI(n){return n.constraints&qe.DragTargetEnd}function AI(n){return n.constraints&qe.DragSegmentThumb}function LI(n){return n instanceof Zn||n instanceof Nr?n.constraints&Lr.Rotate:n.constraints&ie.Rotate}function NI(n){return n.constraints&ie.Shadow}function da(n){return n instanceof te&&n.constraints&ie.InConnect?n.constraints&ie.InConnect:0}function Lh(n){return n&&n.constraints&&!(n.constraints&ni.None)&&n.constraints&ni.InConnect?n.constraints&ni.InConnect:0}function Nh(n){return n instanceof te&&n.constraints&ie.OutConnect?n.constraints&ie.OutConnect:0}function xd(n){return n&&n.constraints&&!(n.constraints&ni.None)&&n.constraints&ni.OutConnect?n.constraints&ni.OutConnect:0}function Ol(n,t){var e=0;return n instanceof Zn||n instanceof Nr?e=n.constraints&Lr.Resize:n&&("SouthEast"===t?e=n.constraints&ie.ResizeSouthEast:"East"===t?e=n.constraints&ie.ResizeEast:"NorthEast"===t?e=n.constraints&ie.ResizeNorthEast:"South"===t?e=n.constraints&ie.ResizeSouth:"North"===t?e=n.constraints&ie.ResizeNorth:"SouthWest"===t?e=n.constraints&ie.ResizeSouthWest:"West"===t?e=n.constraints&ie.ResizeWest:"NorthWest"===t&&(e=n.constraints&ie.ResizeNorthWest)),e}function OI(n){return n instanceof de?n.constraints&qe.AllowDrop:n.constraints&ie.AllowDrop}function Ds(n){return n.constraints&rt.Virtualization}function _v(n){return n.tool&Ci.SingleSelect}function Uv(n){return n.tool&Ci.MultipleSelect}function Lc(n){return n.tool&Ci.ZoomPan}function kI(n){return n.tool&Ci.ContinuousDraw}function x3(n){return n.tool&Ci.DrawOnce}function PI(n){return n.tool&Ci.SingleSelect||n.tool&Ci.MultipleSelect}function jv(n){return n.constraints&rt.UserInteraction}function T3(n){return n.constraints&rt.ZoomTextEdit}function Vv(n){return function Yre(n){return n.constraints&rt.ApiUpdate}(n)||n.diagramActions&ee.ToolAction}function Rx(n,t){return n.constraints&ni.Draw}function Hx(n,t){return n.constraints&ni.Drag}function zI(n){return!(n&Qa.DrawSelectorBorder)}function A3(n){return!!(n&Qa.PreventRenderSelector)}var Bx=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Wv=function(n){function t(){var e=null!==n&&n.apply(this,arguments)||this;return e.childTable=[],e.cellStyle={},e.desiredRowHeight=[],e.desiredCellWidth=[],e}return Bx(t,n),t.prototype.rowDefinitions=function(){return this.rowDefns},t.prototype.columnDefinitions=function(){return this.colDefns},t.prototype.addObject=function(e,i,r,s,o){if(this.rows.length>=i){var a=this.rows[parseInt(i.toString(),10)];if(a.cells.length>r){o=o||1,s=s||1;var l=a.cells[parseInt(r.toString(),10)];l.columnSpan=Math.max(o,l.columnSpan),l.rowSpan=Math.max(s,l.rowSpan);var h=new $re;(h=e).rowId=i,h.columnId=r,h.columnSpan=o,this.childTable[h.id]=h,this.addObjectToCell(h,l)}}},t.prototype.addObjectToCell=function(e,i){i.children||(i.children=[]),e.style.strokeColor="black",e.style.strokeWidth=1,i.children.push(e)},t.prototype.updateProperties=function(e,i,r,s){this.offsetX=e,this.offsetY=i,this.width=r,this.height=s},t.prototype.setDefinitions=function(e,i){this.rowDefns=e,this.colDefns=i,this.children=[],this.rows=this.rows||[];for(var r=0;r0){for(var h=0;hi&&this.updateRowHeight(e,l,!1)}},t.prototype.setTextRefresh=function(e){if(e.children&&e.children.length)for(var i=e.children,r=0;ri&&this.updateColumnWidth(e,a,!1)}},t.prototype.calculateCellWidth=function(e){for(var i,r,s,o=0;os.bounds.width&&(0===s.children.length||void 0===s.children[0].maxWidth)?s.outerBounds.width:s.bounds.width,i=i?is.bounds.height?s.outerBounds.height:s.bounds.height,i=i?i0?e.children[0]:void 0;if(a&&1===e.columnSpan){o="Width"===i?a.bounds.right:a.bounds.bottom,s||(s="Width"===i?a.bounds.width:a.bounds.height);for(var l=0;lo){var d=c-o+("Width"===i?a.bounds.width:a.bounds.height);s&&(s=s0?this.rowDefns.splice(e,0,i):this.rowDefns.push(i);var s=new L3;s.cells=[],(new Td).width=this.width,this.addCellInRow(this.colDefns,i,s),e>this.rows.length-1?this.rows.push(s):this.rows.splice(e,0,s),r&&(this.measure(new me(this.width,this.height)),this.arrange(this.desiredSize))},t.prototype.addColumn=function(e,i,r){var s,o,a,l,h=this.rows;this.colDefns.length>0?this.colDefns.splice(e,0,i):this.colDefns.push(i),void 0!==this.width&&(this.width+=i.width);for(var c=0;cs.cells.length-1?s.cells.push(l):s.cells.splice(e,0,l),this.children.push(l);r&&(this.measure(new me(this.width,this.height)),this.arrange(this.desiredSize))},t.prototype.removeRow=function(e){var i,r,o=this.rows[parseInt(e.toString(),10)];this.height-=this.rowDefns[parseInt(e.toString(),10)].height;for(var a=0;a0){var r=0,s=0;i=new me(0,0),this.calculateSize();for(var o=0,a=this.rows;o0){for(var o=this.offsetX-e.width*this.pivot.x,a=this.offsetY-e.height*this.pivot.y,l=o,h=0,c=this.rows;h1&&this.children.splice(this.children.indexOf(f)+1,f.columnSpan-1),f.rowSpan>1)for(y=s,S=0;y+f.rowSpan-10){for(var c=0;c0?1:0,v=0;v0||a.outEdges.length>0))for(p=a.inEdges.concat(a.outEdges),s=0;s0)for(o=0;o1)for(a=1;a0))if(h=n.wrapper.children[0],"Horizontal"===e.orientation)for(o=e.header&&e.hasHeader?h.rows[1]:h.rows[0],r=0;r0){var e=void 0;t.lineRoutingModule&&t.constraints&rt.LineRouting&&t.lineRoutingModule.renderVirtualRegion(t,!0);for(var i=0;i0?o+1:o)].height=t.wrapper.height;else if(t.isPhase)for(l[t.rowIndex-o].offset=t.wrapper.height,f=0;f0?1:0)].width=t.wrapper.width}function HI(n,t){var i=n.shape,r=i.header&&i.hasHeader?1:0;return"Horizontal"===i.orientation?t.rowIndex-(r+=i.phases.length>0?1:0):t.columnIndex-(i.phaseSize&&i.phases.length>0?1:0)}function BI(n){var t=0,e=n.shape;return"Horizontal"===e.orientation&&(t=e.header&&e.hasHeader?1:0),e.phases.length>0&&e.phaseSize&&(t+=1),t}function FI(n,t,e,i){var r=n.shape;if(r.phases.length>0){var s=t.nameTable[r.phases[parseInt(i.toString(),10)].header.id];s&&s.maxWidth0?u+1:u);var w=Nc(n,o),C=void 0!==i?i:l.lanes.length;if(u+=C,r={element:M,cause:n.diagramActions,diagramAction:n.getDiagramAction(n.diagramActions),state:"Changing",type:"Addition",cancel:!1,laneIndex:C},n.triggerEvent(Ce.collectionChange,r),!r.cancel){if(c){var D=new Yv;D.height=e.height,o.addRow(u,D,!1),s.height=void 0!==s.height?s.height+e.height:s.height,s.wrapper.height=o.height=s.height}else{var A=new Td;A.width=e.width,o.addColumn(C+1,A,!1),s.width&&(s.width+=e.width,s.wrapper.width=o.width=s.width),n.diagramActions&ee.UndoRedo||(o.rows[0].cells[0].columnSpan+=1)}n.diagramActions&ee.UndoRedo||(M.id=""===M.id?Qe():M.id),void 0!==i?l.lanes.splice(i,0,M):l.lanes.push(M),r={element:M,cause:n.diagramActions,diagramAction:n.getDiagramAction(n.diagramActions),state:"Changed",type:"Addition",cancel:!1,laneIndex:C},n.triggerEvent(Ce.collectionChange,r),O3(o,n,s,u,C,c),h="Horizontal"===l.orientation?n.nameTable[o.rows[parseInt(u.toString(),10)].cells[0].children[0].id]:l.header&&l.hasHeader?n.nameTable[o.rows[1].cells[parseInt(u.toString(),10)].children[0].id]:n.nameTable[o.rows[0].cells[parseInt(u.toString(),10)].children[0].id],n.diagramActions&ee.UndoRedo||(d={type:"LaneCollectionChanged",changeType:"Insert",undoObject:$(M),redoObject:$(h),category:"Internal"},n.addHistoryEntry(d)),Gp(n,s,"Horizontal"===l.orientation?u:l.header&&l.hasHeader?1:0),Qp(s),Oc(n,s);var R=!1;if((p=e.children)&&p.length>0)for(f=0;f0){var o=t.children[0],a=n.nameTable[o.id];(function sne(n,t,e){return n.left-(e.left||0)<=t.x&&n.right+(e.right||0)>=t.x&&n.top-(e.top||0)<=t.y&&n.bottom+(e.bottom||0)>=t.y})(o.bounds,e,r)&&(n.addChild(a,i),s=!0)}return s}function one(n,t,e){if("SwimLane"===t.shape.type){var i=void 0,r=void 0,s=void 0,a=void 0,l=void 0,h=void 0,c=t.wrapper.bounds.x,d=t.wrapper.bounds.y,u=t.shape,p=u.padding,f=u.phases,g=void 0,v=t.wrapper.children[0],y="Horizontal"===u.orientation;if(i=u.header&&u.hasHeader?0:-1,u.phases.length>0&&(i+=1),e.offset>(y?u.lanes[0].header.width:u.lanes[0].header.height)){for(h=0;he.offset){if(g=h>0?e.offset-(h>0?f[h-1]:s).offset:e.offset,y){var b=v.columnDefinitions()[parseInt(h.toString(),10)];b.width-=g,(a=n.nameTable[u.phases[parseInt(h.toString(),10)].header.id]).maxWidth=a.wrapper.maxWidth=b.width,v.updateColumnWidth(h,b.width,!1);var M=new Td;M.width=g,l=h,v.addColumn(h,M,!1);break}var w=v.rowDefinitions()[h+i];w.height-=g,a=n.nameTable[u.phases[parseInt(h.toString(),10)].header.id],v.updateRowHeight(h+i,w.height,!1);var C=new Yv;C.height=g,l=h,v.addRow(h+i,C,!1);break}if(n.diagramActions&ee.UndoRedo&&void 0===l&&(D=n.historyManager.currentEntry.next).isLastPhase&&function ane(n,t,e,i,r,s){var a=t.shape.phases[n-2],l=e.previousPhase.offset;if(r){var h=i.columnDefinitions()[n-1],c=new Td;n>1?(c.width=h.width-(l-a.offset),h.width=l-a.offset):(c.width=h.width-l,h.width=l),i.updateColumnWidth(n-1,h.width,!1),i.addColumn(n,c,!1)}else{h=i.rowDefinitions()[parseInt(n.toString(),10)];var d=new Yv;n>1?(d.height=e.undoObject.offset-l,h.height=l-a.offset):(d.height=h.height-l,h.height=l),i.updateRowHeight(n,h.height,!1),i.addRow(1+n,d,!1)}}(l=f.length,t,D,v,y),l>=0){var A=new ab(t.shape,"phases",e,!0);if(n.diagramActions&ee.UndoRedo||(A.id+=Qe()),u.phases.splice(l,0,A),Fx(v,n,t,i,y,l),y){if(r=n.nameTable[v.rows[parseInt(i.toString(),10)].cells[parseInt(l.toString(),10)].children[0].id],0===l&&u.header&&u.hasHeader){v.rows[0].cells[0].children=v.rows[0].cells[1].children,v.rows[0].cells[1].children=[];for(var x=v.rows[0],R=0;Rl+1){var O=n.nameTable[v.rows[parseInt(i.toString(),10)].cells[l+1].children[0].id];v.updateColumnWidth(l+1,L[l+1].width,!0,p),O.maxWidth=O.wrapper.maxWidth=L[l+1].width}t.width=t.wrapper.width=t.wrapper.children[0].width=v.width}else{r=n.nameTable[v.rows[i+l].cells[0].children[0].id];var N=v.rowDefinitions(),T=N[i+l].height;(function hne(n,t,e,i,r){for(var o,a,l=e.rows[parseInt(i.toString(),10)],h=e.rows[i+1],c=e.rows[i-1],d=1;di+l+1&&v.updateRowHeight(i+l+1,T=N[i+l+1].height,!0,p),t.height=t.wrapper.height=t.wrapper.children[0].height=v.actualSize.height}if(Qp(t),t.width=t.wrapper.actualSize.width,Oc(n,t),n.drag(t,c-t.wrapper.bounds.x,d-t.wrapper.bounds.y),RI(t,n),n.commandHandler.select(r),!(n.diagramActions&ee.UndoRedo)){var D={type:"PhaseCollectionChanged",changeType:"Insert",undoObject:$(A),redoObject:$(r),category:"Internal"};n.addHistoryEntry(D)}n.updateDiagramObject(t)}}}}function H3(n,t,e,i,r,s,o){var a,l,f,h=t.shape,c="Horizontal"===h.orientation,d=t.wrapper.children[0],g=c?s:o;e?(a=c?e.bounds.x+e.bounds.width:e.bounds.x,l=c?e.bounds.y:e.bounds.y+e.bounds.height):(a=d.bounds.x,l=r.bounds.y);var v=new Ne(a,l,i.desiredCellWidth,i.desiredCellHeight),S=Qv(n,0,t,{id:t.id+(c?h.lanes[g-2]:h.lanes[g-1]).id+Qe()[0],rowIndex:s,columnIndex:o,width:i.minWidth,height:i.minHeight,style:(c?h.lanes[g-2]:h.lanes[g-1]).style,constraints:ie.Default|ie.AllowDrop,container:{type:"Canvas",orientation:c?"Horizontal":"Vertical"}},!1,!1,!0);if(S.children[0].isCalculateDesiredSize=!1,d.addObject(S,s,o),r&&r.children&&r.children.length)for(f=0;f1)for(var f=1;fh.margin.left&&(h.margin.left=p)):(h.margin.top-=e.desiredCellHeight,p>h.margin.top&&(h.margin.top=p)))}(n,r,i,v,S,c,e)}function B3(n,t,e){if("SwimLane"===t.shape.type&&("ResizeSouth"===e||"ResizeEast"===e)){var i=t.shape,r=t.wrapper.children[0],s=void 0,o=void 0;"ResizeSouth"===e?"Vertical"===i.orientation?s=r.rows[r.rows.length-1].cells[0]:(o=r.rows.length-1,s=r.rows[parseInt(o.toString(),10)].cells[r.rows[parseInt(o.toString(),10)].cells.length-1]):(o=i.header&&i.hasHeader?1:0,s=r.rows[parseInt(o.toString(),10)].cells[r.rows[parseInt(o.toString(),10)].cells.length-1]),n.commandHandler.select(n.nameTable[s.children[0].id])}}function _I(n,t,e,i,r,s){var o,a,l,c,u,p,f,d=Qe(),g=n.shape,v=g.phases,y=n.offsetX-n.wrapper.actualSize.width/2,S=n.offsetY-n.wrapper.actualSize.height/2;if("Vertical"===g.orientation&&(S+=g.header&&g.hasHeader?g.header.height:0),!s)for(r||(n.id+=d,g&&g.header&&g.hasHeader?g.header.id+=d:g.header=void 0),o=0;v&&o0&&s.columnIndex>0||s.isLane)?(a=function Sne(n,t,e){for(var i=new Ne,r="SwimLane"===n.shape.type?n.wrapper.children[0].rows:n.wrapper.rows,s=e?1:0;s=0;a--)i?i.id===o.children[parseInt(a.toString(),10)].id&&o.children.splice(a,1):(n.removeDependentConnector(o.children[parseInt(a.toString(),10)]),n.diagramActions&ee.UndoRedo||(n.diagramActions=n.diagramActions|ee.UndoRedo,s=!0),n.remove(o.children[parseInt(a.toString(),10)]),o.children.splice(a,1),s&&(n.diagramActions=n.diagramActions&~ee.UndoRedo))}function dne(n){return n.children[0]}function qv(n,t){t&&(n.nodes.splice(n.nodes.indexOf(t),1),n.removeFromAQuad(t),n.removeObjectsFromLayer(t),delete n.nameTable[t.id],n.removeElements(t))}function _3(n,t,e,i){var r;if("SwimLane"===e.shape.type){var s=e.shape,o=void 0;if(1===s.lanes.length)n.remove(e);else{var a=e.wrapper.bounds.x,l=e.wrapper.bounds.y,h=void 0,c=void 0,d=void 0,u=void 0,f=e.wrapper.children[0];if(o=i?s.lanes.indexOf(i):HI(e,t),r={element:t,cause:n.diagramActions,diagramAction:n.getDiagramAction(n.diagramActions),state:"Changing",type:"Removal",cancel:!1,laneIndex:o},n.triggerEvent(Ce.collectionChange,r),!r.cancel){var g=s.lanes[parseInt(o.toString(),10)],v=g.children;g.children=[];for(var y=0;y0)for(u=0;u0)for(u=0;u0)for(e=0;e1){c===l.phases.length-1&&(o=!0,a=$(l.phases[c-1]));var u=$(l.phases[parseInt(c.toString(),10)]);if(l.phases.splice(c,1),!(n.diagramActions&ee.UndoRedo)){var p={type:"PhaseCollectionChanged",changeType:"Remove",undoObject:u,previousPhase:a,redoObject:$(t),category:"Internal",isLastPhase:o};n.addHistoryEntry(p)}"Horizontal"===l.orientation?function pne(n,t,e,i){var r,s,o,a,l,h,c,d,u,p,f,g;for(i=void 0!==i?i:e.columnIndex,c=0;c1&&(s=r.cells[parseInt(i.toString(),10)],l=(o=r.cells.length-1===i?r.cells[i-1]:r.cells[i+1]).children[0],s.children.length>0))if(f=n.nameTable[(a=s.children[0]).id],0===o.children.length&&s.children.length>0)o.children=s.children,o.columnSpan=s.columnSpan-1;else{for(d=0;d0){var M=s.children[0],w=n.nameTable[M.id];if(i=e.x&&a.bounds.y<=e.y&&a.bounds.bottom>=e.y)&&!(t.constraints&ie.AllowMovingOutsideLane)){var l=$(t);n.clearSelection(),W3(n,t),t.parentId="",t.parentObj=n,t.propName="nodes";var h={type:"ChildCollectionChanged",category:"Internal",undoObject:l,redoObject:$(t)};n.addHistoryEntry(h),n.commandHandler.isContainer&&(n.commandHandler.isContainer=!1,n.endGroupAction()),Y3(t,n)}n.protectPropertyChange(o)}}function UI(n,t){var e,i,r;return n.enableServerDataBinding(!1),ce()||(n.selectedObject.helperObject?r=n.selectedObject.helperObject:(n.selectedItems.nodes.length>0||n.selectedItems.connectors.length>0)&&(t instanceof oi&&t.nodes.length+t.connectors.length===1?(e=t.nodes.length>0?t.nodes[0]:t.connectors[0],i=n.selectedItems.wrapper.children[0]):(e=t,i=n.selectedItems.wrapper),n.selectedObject.actualObject=e,!n.currentSymbol&&(e.isLane&&Vx(e,n)&&cs(n,e)||!e.isLane&&cs(n,e)||n.constraints&rt.LineRouting&&n.selectedItems.nodes.length>0))&&(r=function Ine(n,t){for(var e,i={},r=0,s=Object.keys(t);r=t.x-e&&n.x<=t.x+e&&n.y>=t.y-e&&n.y<=t.y+e}function Xa(n){return n.selectedItems.nodes.length>0||n.selectedItems.connectors.length>0}function G3(n){return 1===n.selectedItems.connectors.length&&!n.selectedItems.nodes.length}function _r(n,t,e,i){if(void 0===e&&(e=!0),t instanceof oi)return!0;if(t instanceof te)for(;t;){if(-1!==n.selectedItems.nodes.indexOf(t)&&void 0===n.selectedItems.annotation)return!0;if(e)break;t=n.nameTable[t.parentId]}else if(t instanceof de){if(-1!==n.selectedItems.connectors.indexOf(t)&&void 0===n.selectedItems.annotation)return!0}else if((t instanceof Zn||t instanceof Nr)&&n.selectedItems.annotation&&n.selectedItems.wrapper.children[0].id===i.id)return!0;return!1}var Wx={None:"default",Rotate:"crosshair",Select:"default",Drag:"move",ResizeWest:"w-resize",ResizeEast:"e-resize",ResizeSouth:"s-resize",ResizeNorth:"n-resize",Draw:"crosshair",PortDraw:"crosshair",ResizeNorthEast:"ne-resize",ResizeNorthWest:"nw-resize",ResizeSouthEast:"se-resize",ResizeSouthWest:"sw-resize",ConnectorSourceEnd:"move",ConnectorTargetEnd:"move",BezierSourceThumb:"move",BezierTargetThumb:"move",OrthoThumb:"move",SegmentEnd:"move",Pan:"grab",Hyperlink:"pointer",PortDrag:"pointer",LabelSelect:"pointer",LabelDrag:"move",LabelRotate:"crosshair",LabelResizeWest:"w-resize",LabelResizeEast:"e-resize",LabelResizeSouth:"s-resize",LabelResizeNorth:"n-resize",LabelResizeNorthEast:"ne-resize",LabelResizeNorthWest:"nw-resize",LabelResizeSouthEast:"se-resize",LabelResizeSouthWest:"sw-resize"},ds=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Ld=function(n,t,e,i){return new(e||(e=Promise))(function(r,s){function o(h){try{l(i.next(h))}catch(c){s(c)}}function a(h){try{l(i.throw(h))}catch(c){s(c)}}function l(h){h.done?r(h.value):new e(function(c){c(h.value)}).then(o,a)}l((i=i.apply(n,t||[])).next())})},Nd=function(n,t){var i,r,s,o,e={label:0,sent:function(){if(1&s[0])throw s[1];return s[1]},trys:[],ops:[]};return o={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function a(h){return function(c){return function l(h){if(i)throw new TypeError("Generator is already executing.");for(;e;)try{if(i=1,r&&(s=2&h[0]?r.return:h[0]?r.throw||((s=r.return)&&s.call(r),0):r.next)&&!(s=s.call(r,h[1])).done)return s;switch(r=0,s&&(h=[2&h[0],s.value]),h[0]){case 0:case 1:s=h;break;case 4:return e.label++,{value:h[1],done:!1};case 5:e.label++,r=h[1],h=[0];continue;case 7:h=e.ops.pop(),e.trys.pop();continue;default:if(!(s=(s=e.trys).length>0&&s[s.length-1])&&(6===h[0]||2===h[0])){e=0;continue}if(3===h[0]&&(!s||h[1]>s[0]&&h[1]-1&&(r=i.fixedUserHandles[parseInt(o.toString(),10)]);this.commandHandler.triggerEvent(Ce.fixedUserHandleClick,{fixedUserHandle:r,element:e.source}),n.prototype.mouseUp.call(this,e)},t}(us),Od=function(n){function t(e,i){var r=n.call(this,e,!0)||this;return r.isConnected=!1,r.endPoint=i,r}return ds(t,n),t.prototype.mouseDown=function(e){return Ld(this,void 0,void 0,function(){var r,s,o,a,l;return Nd(this,function(h){if(this.inAction=!0,this.undoElement=void 0,this instanceof pa||(this.undoElement=$(e.source)),n.prototype.mouseDown.call(this,e),e.source&&e.source.connectors&&(this.oldConnector=$(r=e.source.connectors[0])),"BezierSourceThumb"===this.endPoint||"BezierTargetThumb"===this.endPoint)for(s=0;s0))},t.prototype.endAction=function(){n.prototype.endAction.call(this),this.prevPosition=null,this.endPoint=null},t}(us),ua=function(n){function t(e,i){var r=n.call(this,e,!0)||this;return r.currentTarget=null,r.isStartAction=!1,r.canCancel=!1,r.canTrigger=!1,r.objectType=i,r}return ds(t,n),t.prototype.mouseDown=function(e){if(e.source instanceof te||e.source instanceof de){var i=this.commandHandler.getSelectedObject();this.commandHandler.selectObjects([e.source],e.info&&e.info.ctrlKey,i);var r={nodes:[],connectors:[]};e.source instanceof te?r.nodes.push($(e.source)):r.connectors.push($(e.source)),this.undoElement=$(r)}else this.undoElement=$(e.source);this.undoParentElement=this.commandHandler.getSubProcess(e.source),"Port"===this.objectType&&(this.portId=e.sourceWrapper.id),this.commandHandler.insertBlazorConnector(e.source),n.prototype.mouseDown.call(this,e),this.initialOffset={x:0,y:0}},t.prototype.mouseUp=function(e,i){return Ld(this,void 0,void 0,function(){var s,o,a,l,h,c,d,u,f,g,v,y,S,b,M;return Nd(this,function(w){if(this.checkPropertyValue(),a=!1,h={nodes:[],connectors:[]},"Port"!==this.objectType){if(e.source instanceof te||e.source instanceof de?(e.source instanceof te?h.nodes.push($(e.source)):h.connectors.push($(e.source)),(o=$(h)).offsetX=(c=e.source.wrapper).offsetX,o.offsetY=c.offsetY):o=$(e.source),("helper"===(l=this.commandHandler.renderContainerHelper(e.source)||e.source||this.commandHandler.renderContainerHelper(e.source)).id||"helper"!==l.id)&&((l instanceof oi&&(Math.round(l.width)===Math.round(this.undoElement.width)&&Math.round(l.height)===Math.round(this.undoElement.height)||l.selectedObjects&&1===l.selectedObjects.length)||!(l instanceof oi))&&(l.offsetX!==this.undoElement.offsetX||l.offsetY!==this.undoElement.offsetY||l.sourcePoint!==this.undoElement.sourcePoint||l.targetPoint!==this.undoElement.targetPoint)||this.isSelectionHasConnector(l))&&(e.source&&(s={offsetX:e.source.wrapper.offsetX,offsetY:e.source.wrapper.offsetY}),g={source:e.source,state:"Completed",oldValue:this.intialValue,newValue:s,target:this.currentTarget,targetPosition:this.currentPosition,allowDrop:(g={source:e.source,state:"Completed",oldValue:this.intialValue,newValue:s,target:this.currentTarget,targetPosition:this.currentPosition,allowDrop:!0,cancel:!1}).allowDrop,cancel:g.cancel},d=!0,"helper"===l.id?this.canTrigger?(this.commandHandler.triggerEvent(Ce.positionChange,g),this.connectorEndPointChangeEvent(g),d=!0):d=!1:(this.commandHandler.triggerEvent(Ce.positionChange,g),this.connectorEndPointChangeEvent(g)),!i&&d&&(this.commandHandler.startGroupAction(),a=!0,M={type:"PositionChanged",redoObject:$(o),undoObject:$(this.undoElement),category:"Internal"},o.nodes[0]&&o.nodes[0].processId&&(u={type:"SizeChanged",category:"Internal",undoObject:this.undoParentElement,redoObject:this.commandHandler.getSubProcess(e.source)},this.commandHandler.addHistoryEntry(u)),this.commandHandler.addHistoryEntry(M))),this.commandHandler.snapPoint(this.prevPosition,this.currentPosition,0,0),this.commandHandler.removeSnap(),this.commandHandler.removeHighlighter(),e.source&&this.currentTarget&&OI(this.currentTarget)&&this.commandHandler.isDroppable(e.source,this.currentTarget)){if(f=!0,this.commandHandler.drop(this.currentElement,this.currentTarget,this.currentPosition),this.currentTarget&&this.currentTarget instanceof de&&!0===this.commandHandler.diagram.enableConnectorSplit)if(this.currentElement&&this.currentElement instanceof te){if(void 0!==this.currentElement.children)for(b=0;b0)for(var s=0;s0)for(var a=0;a0)for(a=0;a0&&e.connectors.length>0)||e.width===this.undoElement.width&&e.height===this.undoElement.height)},t.prototype.mouseMove=function(e){n.prototype.mouseMove.call(this,e);var r,s,i=!1;(r=this.commandHandler.renderContainerHelper(e.source)||e.source)instanceof te||r instanceof de?r instanceof te?r.offsetX===this.undoElement.nodes[0].offsetX&&r.offsetY===this.undoElement.nodes[0].offsetY&&(i=!0):z.equals(r.sourcePoint,this.undoElement.connectors[0].sourcePoint)&&z.equals(r.targetPoint,this.undoElement.connectors[0].targetPoint)&&(i=!0):r.wrapper.offsetX===this.undoElement.wrapper.offsetX&&r.wrapper.offsetY===this.undoElement.wrapper.offsetY&&(i=!0),r&&(s={offsetX:r.wrapper.offsetX,offsetY:r.wrapper.offsetY});var o={source:r,state:"Start",oldValue:s,newValue:s,target:e.target,targetPosition:e.position,allowDrop:!0,cancel:!1};if(o={source:r,state:"Start",oldValue:s,newValue:s,target:e.target,targetPosition:e.position,allowDrop:o.allowDrop,cancel:o.cancel},this.isStartAction||(this.intialValue={offsetX:r.wrapper.offsetX,offsetY:r.wrapper.offsetY}),i&&!ce()&&(this.commandHandler.triggerEvent(Ce.positionChange,o),this.connectorEndPointChangeEvent(o),this.isStartAction=!0),this.currentPosition=e.position,"Port"!==this.objectType){var h=this.initialOffset.x+(this.currentPosition.x-this.prevPosition.x),c=this.initialOffset.y+(this.currentPosition.y-this.prevPosition.y);this.commandHandler.dragOverElement(e,this.currentPosition),this.commandHandler.disConnect(e.source),this.commandHandler.removeSnap();var d,u=void 0,p=this.commandHandler.snapPoint(this.prevPosition,this.currentPosition,h,c);this.initialOffset.x=h-p.x,this.initialOffset.y=c-p.y,r&&(d={offsetX:r.wrapper.offsetX,offsetY:r.wrapper.offsetY},u={offsetX:r.wrapper.offsetX+p.x,offsetY:r.wrapper.offsetY+p.y}),this.currentTarget&&e.target!==this.currentTarget&&this.commandHandler.removeChildFromBPmn(e.source,e.target,this.currentTarget),this.currentTarget=e.target;var f={source:r,state:"Progress",oldValue:d,newValue:u,target:e.target,targetPosition:e.position,allowDrop:!0,cancel:!1};if(this.commandHandler.triggerEvent(Ce.positionChange,f),this.canTrigger=!0,this.connectorEndPointChangeEvent(f,p),!f.cancel&&!this.canCancel){this.blocked=!this.commandHandler.dragSelectedObjects(p.x,p.y);var g=!this.commandHandler.mouseOver(this.currentElement,this.currentTarget,this.currentPosition);this.blocked=this.blocked||g}if(this.commandHandler.removeStackHighlighter(),this.commandHandler.renderStackHighlighter(e),this.currentTarget&&e.source!==this.currentTarget&&this.commandHandler.isDroppable(e.source,this.currentTarget)&&"helper"!==e.source.id){var v=e.source instanceof oi?e.source.nodes[0]:e.source;!this.commandHandler.isParentAsContainer(v,!0)&&"SwimLane"!==v.shape.type&&!v.shape.isPhase&&(this.currentTarget.isLane?this.commandHandler.renderStackHighlighter(e,this.currentTarget):this.commandHandler.drawHighlighter(this.currentTarget))}else this.commandHandler.removeHighlighter();if(this.commandHandler.canEnableDefaultTooltip()){var y=this.getTooltipContent(e.source);this.commandHandler.showTooltip(e.source,e.position,ko(function(){return y}),"MoveTool",this.isTooltipVisible),this.isTooltipVisible=!1}}else{var b=Hi(),M=e.source;qi(b,-M.rotateAngle||-M.wrapper.rotateAngle,M.offsetX||M.wrapper.offsetX,M.offsetY||M.wrapper.offsetY);var w=Je(b,{x:this.prevPosition.x,y:this.prevPosition.y}),C=Je(b,{x:e.position.x,y:e.position.y});this.commandHandler.portDrag(e.source,e.sourceWrapper,C.x-w.x,C.y-w.y)}return this.prevPosition=this.currentPosition,!this.blocked},t.prototype.getTooltipContent=function(e){return"X:"+Math.round(e.wrapper.bounds.x)+" Y:"+Math.round(e.wrapper.bounds.y)},t.prototype.mouseLeave=function(e){this.mouseUp(e)},t.prototype.endAction=function(){n.prototype.endAction.call(this),this.currentTarget=null,this.prevPosition=null},t}(us),Yx=function(n){function t(e){var i=n.call(this,e,!0)||this;return i.rotateStart=!1,i}return ds(t,n),t.prototype.mouseDown=function(e){if(this.undoElement=$(e.source),this.undoElement.nodes[0]&&this.undoElement.nodes[0].children)for(var r=this.commandHandler.getAllDescendants(this.undoElement.nodes[0],[]),s=0;s=2){var s=e.startTouches[0],o=e.startTouches[1],a=e.moveTouches[0],l=e.moveTouches[1],h=this.getDistance(a,l)/this.getDistance(s,o);this.commandHandler.zoom(h,0,0,e.position),this.updateTouch(s,a),this.updateTouch(o,l)}}else this.commandHandler.scroll(this.currentPosition.x-this.prevPosition.x,this.currentPosition.y-this.prevPosition.y,this.currentPosition);return this.commandHandler.dataBinding(),!this.blocked},t.prototype.mouseUp=function(e){this.commandHandler.setBlazorDiagramProps(!1),this.checkPropertyValue(),this.commandHandler.updatePanState(!1),n.prototype.mouseUp.call(this,e),this.inAction=!1},t.prototype.endAction=function(){n.prototype.endAction.call(this)},t.prototype.getDistance=function(e,i){var r=i.pageX-e.pageX,s=i.pageY-e.pageY;return Math.sqrt(r*r+s*s)},t.prototype.updateTouch=function(e,i){e.pageX=i.pageX,e.pageY=i.pageY},t}(us),Lne=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseUp=function(e){this.checkPropertyValue(),this.commandHandler.initExpand(e),n.prototype.mouseUp.call(this,e)},t}(us),X3=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseUp=function(e){this.checkPropertyValue();var i="_blank",r="",s=window.innerHeight,o=window.innerWidth,a=window.screenTop,l=window.screenLeft;"CurrentTab"===e.sourceWrapper.hyperlink.hyperlinkOpenState?i="_self":"NewWindow"===e.sourceWrapper.hyperlink.hyperlinkOpenState&&(r="height="+s+",width="+o+",top="+a+",left="+l),window.open(e.sourceWrapper.hyperlink.link,i,r).focus(),n.prototype.mouseUp.call(this,e)},t}(us),Oh=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseDown=function(e){if(n.prototype.mouseDown.call(this,e),this.inAction=!0,this.drawingObject){var r=void 0,s=this.drawingObject.shape;this.drawingObject.shape.points.push(r={x:(r=s.points[s.points.length-1]).x,y:r.y})}else this.startPoint={x:this.startPosition.x,y:this.startPosition.y},this.drawingObject=this.commandHandler.drawObject({offsetX:this.currentPosition.x,offsetY:this.currentPosition.y,width:5,height:5,style:{strokeColor:"black",strokeWidth:1},shape:{type:"Basic",shape:"Polygon",points:[{x:this.startPoint.x,y:this.startPoint.y},{x:this.currentPosition.x,y:this.currentPosition.y}]}})},t.prototype.mouseMove=function(e){if(n.prototype.mouseMove.call(this,e),this.inAction){var i=this.drawingObject.shape;if(i.points[i.points.length-1].x=this.currentPosition.x,i.points[i.points.length-1].y=this.currentPosition.y,this.drawingObject.wrapper.children[0].data=vx(this.drawingObject.shape.points),this.inAction&&!1===z.equals(this.currentPosition,this.prevPosition)){var r=Ne.toBounds(this.drawingObject.shape.points);this.commandHandler.updateNodeDimension(this.drawingObject,r)}}return!0},t.prototype.mouseUp=function(e,i){this.checkPropertyValue(),n.prototype.mouseMove.call(this,e),this.inAction&&(this.inAction=!1,this.commandHandler.addObjectToDiagram(this.drawingObject)),this.endAction()},t.prototype.mouseWheel=function(e){n.prototype.mouseWheel.call(this,e),this.mouseMove(e)},t.prototype.endAction=function(){this.inAction=!1,this.drawingObject=null},t}(us),kh=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseMove=function(e){if(n.prototype.mouseMove.call(this,e),this.inAction){var i=this.drawingObject;i.targetPoint=this.currentPosition,this.commandHandler.updateConnectorPoints(i)}return!0},t.prototype.mouseDown=function(e){if(n.prototype.mouseDown.call(this,e),this.inAction=!0,this.drawingObject){var r=this.drawingObject,s=void 0;(s=new kl(r,"segments",{type:"Straight"},!0)).point=this.currentPosition,r.segments[r.segments.length-1]=s}else this.drawingObject=this.commandHandler.drawObject({id:"Connector",type:"Straight",sourcePoint:this.currentPosition,targetPoint:this.currentPosition})},t.prototype.mouseWheel=function(e){n.prototype.mouseWheel.call(this,e),this.mouseMove(e)},t.prototype.mouseUp=function(e){if(this.checkPropertyValue(),n.prototype.mouseMove.call(this,e),this.inAction&&this.drawingObject){var i=this.drawingObject;i.segments[i.segments.length-1].point={x:0,y:0},this.commandHandler.addObjectToDiagram(this.drawingObject)}this.endAction()},t.prototype.endAction=function(){this.drawingObject=null,this.inAction=!1},t}(us),Nne=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseDown=function(e){this.inAction=!0,this.undoElement=$(e.source),this.annotationId=e.sourceWrapper.id,n.prototype.mouseDown.call(this,e)},t.prototype.mouseMove=function(e){n.prototype.mouseMove.call(this,e);var i=this.currentPosition.x-this.prevPosition.x,r=this.currentPosition.y-this.prevPosition.y,s=e.source;if(s instanceof te){var o=Hi();qi(o,-s.rotateAngle,0,0);var a=Je(o,{x:i,y:r});i=a.x,r=a.y}return this.inAction&&(this.commandHandler.labelDrag(e.source,e.sourceWrapper,i,r),this.commandHandler.updateSelector()),this.prevPosition=this.currentPosition,!this.blocked},t.prototype.mouseUp=function(e){this.checkPropertyValue();var i=e.source;this.inAction=!1;var r={type:"AnnotationPropertyChanged",objectId:this.annotationId,undoObject:$(this.undoElement),category:"Internal",redoObject:$(i)};this.commandHandler.addHistoryEntry(r),n.prototype.mouseUp.call(this,e)},t.prototype.mouseLeave=function(e){this.mouseUp(e)},t}(us),One=function(n){function t(e,i){var r=n.call(this,e,!0)||this;return r.corner=i,r}return ds(t,n),t.prototype.mouseDown=function(e){this.inAction=!0;var i=e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0];this.annotationId=e.source.wrapper.children[0].id,this.undoElement=$(i);var r=e.source.wrapper.children[0];this.initialBounds={x:r.offsetX,y:r.offsetY,width:r.actualSize.width,height:r.actualSize.height},n.prototype.mouseDown.call(this,e)},t.prototype.mouseMove=function(e){return n.prototype.mouseMove.call(this,e),this.inAction&&this.resizeObject(e),!this.blocked},t.prototype.mouseUp=function(e){this.checkPropertyValue();var i=e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0];this.inAction=!1;var r={type:"AnnotationPropertyChanged",objectId:this.annotationId,redoObject:$(i),undoObject:$(this.undoElement),category:"Internal"};this.commandHandler.addHistoryEntry(r),n.prototype.mouseUp.call(this,e)},t.prototype.mouseLeave=function(e){this.mouseUp(e)},t.prototype.resizeObject=function(e){var i,s,o,r=e.source.wrapper.children[0],a={x:r.offsetX,y:r.offsetY},l=r.rotateAngle;l=((l+=(i=e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0])instanceof te?i.rotateAngle:0)+360)%360;var h=Hi();qi(h,l,a.x,a.y);var c=this.corner.slice(5),d=this.updateSize(r,this.startPosition,this.currentPosition,c,this.initialBounds,l),u=r.offsetX-r.actualSize.width*r.pivot.x,p=r.offsetY-r.actualSize.height*r.pivot.y,f=this.getPivot(c),g=Je(h,f={x:u+r.actualSize.width*f.x,y:p+r.actualSize.height*f.y});d.x=g.x,d.y=g.y,this.commandHandler.labelResize(i,e.source.annotation,s=(s=d.width)<0?1:s,o=(o=d.height)<0?1:o,d,e.source),this.commandHandler.updateSelector()},t}(us),kne=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseDown=function(e){this.inAction=!0,this.annotationId=e.source.wrapper.children[0].id,this.undoElement=$(e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0]),n.prototype.mouseDown.call(this,e)},t.prototype.mouseMove=function(e){return n.prototype.mouseMove.call(this,e),e.source&&this.inAction&&(this.commandHandler.labelRotate(e.source.nodes[0]?e.source.nodes[0]:e.source.connectors[0],e.source.annotation,this.currentPosition,e.source),this.commandHandler.updateSelector()),this.prevPosition=this.currentPosition,!this.blocked},t.prototype.mouseUp=function(e){this.checkPropertyValue(),this.inAction=!1;var r={type:"AnnotationPropertyChanged",objectId:this.annotationId,redoObject:$(e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0]),undoObject:$(this.undoElement),category:"Internal"};this.commandHandler.addHistoryEntry(r),n.prototype.mouseUp.call(this,e)},t.prototype.mouseLeave=function(e){this.mouseUp(e)},t}(us),Pne=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseMove=function(e){if(n.prototype.mouseMove.call(this,e),this.inAction){var i=this.drawingObject.shape;if(i.points.push(this.currentPosition),this.drawingObject.wrapper.children[0].data=mx(this.drawingObject.shape.points),i.data=mx(i.points),this.inAction&&!1===z.equals(this.currentPosition,this.prevPosition)){var s=Ne.toBounds(this.drawingObject.shape.points);this.commandHandler.updateNodeDimension(this.drawingObject,s)}}return!0},t.prototype.mouseDown=function(e){n.prototype.mouseDown.call(this,e),this.inAction=!0,this.startPoint={x:this.startPosition.x,y:this.startPosition.y},this.drawingObject=this.commandHandler.drawObject({offsetX:this.currentPosition.x,offsetY:this.currentPosition.y,width:5,height:5,style:{strokeColor:"black",strokeWidth:1,fill:"transparent"},shape:{type:"Path",points:[{x:this.startPoint.x,y:this.startPoint.y},{x:this.currentPosition.x,y:this.currentPosition.y}]}})},t.prototype.mouseUp=function(e){if(this.checkPropertyValue(),this.inAction){this.inAction=!1;var s=this.drawingObject.shape,o=s.points;this.commandHandler.addObjectToDiagram(this.drawingObject),this.commandHandler.diagram.remove(this.commandHandler.diagram.nameTable[""+this.drawingObject.id]),o=this.pointReduction(o,10);var h={id:"newConnector"+Qe(),type:"Bezier",sourcePoint:{x:o[0].x,y:o[0].y},targetPoint:{x:o[o.length-1].x,y:o[o.length-1].y},segments:[],bezierSettings:{allowSegmentsReset:!1}};this.drawingObject=this.commandHandler.drawObject(h),this.drawingObject=this.bezierCurveSmoothness(o,.5,this.drawingObject,s),this.commandHandler.updateConnectorPoints(this.drawingObject),this.commandHandler.addObjectToDiagram(this.drawingObject),n.prototype.mouseUp.call(this,e)}},t.prototype.pointReduction=function(e,i){if(null===e||e.length<3)return e;var s=e.length-1,o=[];for(o.push(0),o.push(s);e[parseInt((0).toString(),10)]===e[parseInt(s.toString(),10)];)s--;this.reduction(e,0,s,i,o);var a=[];return o.sort(function(l,h){return l-h}),o.forEach(function(l){a.push(e[parseInt(l.toString(),10)])}),a},t.prototype.reduction=function(e,i,r,s,o){for(var a=0,l=0,h=i;ha&&(a=c,l=h)}a>s&&0!==l&&(o.push(l),this.reduction(e,i,l,s,o),this.reduction(e,l,r,s,o))},t.prototype.perpendicularDistance=function(e,i,r){return Math.abs(.5*(e.x*i.y-i.x*e.y+(i.x*r.y-r.x*i.y)+(r.x*e.y-e.x*r.y)))/Math.sqrt(Math.pow(e.x-i.x,2)+Math.pow(e.y-i.y,2))*2},t.prototype.bezierCurveSmoothness=function(e,i,r,s){if(e.length<3)return r;for(var o=0;o=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},zne=function(n){if(n)switch(n.type){case"Bpmn":return Fne;case"UmlActivity":return Bne;case"UmlClassifier":return jne;default:return Kv}return Kv},Rne=function(n){if(n)switch(n.type){case"Straight":default:return kl;case"Bezier":return ps;case"Orthogonal":return bi}},q3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I(10)],t.prototype,"width",void 0),Pe([I(10)],t.prototype,"height",void 0),Pe([I("Arrow")],t.prototype,"shape",void 0),Pe([re({fill:"black",strokeColor:"black",strokeWidth:1},Al)],t.prototype,"style",void 0),Pe([re({x:0,y:.5},z)],t.prototype,"pivot",void 0),Pe([I("")],t.prototype,"pathData",void 0),t}(Ee),YI=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I(0)],t.prototype,"angle",void 0),Pe([I(0)],t.prototype,"distance",void 0),t}(Ee),Hne=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I(bx.All)],t.prototype,"controlPointsVisibility",void 0),Pe([I("FreeForm")],t.prototype,"segmentEditOrientation",void 0),Pe([I(mI.Default)],t.prototype,"smoothness",void 0),Pe([I(!0)],t.prototype,"allowSegmentsReset",void 0),t}(Ee),Kv=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I("None")],t.prototype,"type",void 0),t}(Ee),Bne=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I("Object")],t.prototype,"flow",void 0),Pe([I(30)],t.prototype,"exceptionFlowHeight",void 0),t}(Kv),Fne=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I("Sequence")],t.prototype,"flow",void 0),Pe([I("Normal")],t.prototype,"sequence",void 0),Pe([I("Default")],t.prototype,"message",void 0),Pe([I("Default")],t.prototype,"association",void 0),t}(Kv),$3=function(n){function t(e,i,r,s){var o=n.call(this,e,i,r,s)||this;return o.points=[],o}return Qs(t,n),Pe([I("Straight")],t.prototype,"type",void 0),Pe([I(!0)],t.prototype,"allowDrag",void 0),t}(Ee),kl=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),t.prototype.getClassName=function(){return"StraightSegment"},Pe([re({x:0,y:0},z)],t.prototype,"point",void 0),t}($3),ps=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),t.prototype.getClassName=function(){return"BezierSegment"},t.prototype.getPoints=function(e,i){var r=[];if(r.length>0||null!=i){var o=this.bezireToPoly(r.length>0?r[r.length-1]:i,e);r.push.apply(r,o)}return r},t.prototype.bezireToPoly=function(e,i){var r=[];return i&&this.flattenCubicBezier(r,e,i.bezierPoint1,i.bezierPoint2,{x:i.points[1].x,y:i.points[1].y},10),r},t.prototype.flattenCubicBezier=function(e,i,r,s,o,a){var h,l=(z.findLength(i,r)+z.findLength(r,s)+z.findLength(s,o))/a;for(h=0;h<=l;h++){var c=h/l;e.push({x:(1-c)*(1-c)*(1-c)*i.x+3*c*(1-c)*(1-c)*r.x+3*c*c*(1-c)*s.x+c*c*c*o.x,y:(1-c)*(1-c)*(1-c)*i.y+3*c*(1-c)*(1-c)*r.y+3*c*c*(1-c)*s.y+c*c*c*o.y})}},Pe([I("Horizontal")],t.prototype,"orientation",void 0),Pe([re({x:0,y:0},z)],t.prototype,"point1",void 0),Pe([re({x:0,y:0},z)],t.prototype,"point2",void 0),Pe([re({angle:0,distance:0},YI)],t.prototype,"vector1",void 0),Pe([re({angle:0,distance:0},YI)],t.prototype,"vector2",void 0),t}(kl),bi=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),t.prototype.getClassName=function(){return"OrthogonalSegment"},Pe([I(null)],t.prototype,"length",void 0),Pe([I(null)],t.prototype,"direction",void 0),t}($3);function Z3(n,t,e){var s=e?45:180/(2+2/(n.height/n.width)),o=s,a=180-s,l=a+2*s,h=360-s,c=Xt(t,n.center);return c>o&&ca&&cl&&cMath.abs(t.y-n.y)?n.x=c)return s=z.findAngle(n[parseInt(d.toString(),10)],n[d+1]),{point:r=z.transform(n[parseInt(d.toString(),10)],s,c-(a||0)),index:l=d};a=o[parseInt(d.toString(),10)]}return{point:r,index:l}}(n,t),r=z.findAngle(n[i.index],n[i.index+1]),s=function vse(n){var e=0;switch(n.alignment){case"Center":case"After":e=0;break;case"Before":e=-0}return e}(t),o=z.transform(i.point,r+45,s);return i.point=o,i.angle=r,i}(i,e),h=l.point;s.id=this.id+"_"+e.id;var c=e.style;s.style={fill:c.fill,strokeColor:c.strokeColor,gradient:null,opacity:c.opacity,strokeDashArray:c.strokeDashArray,strokeWidth:c.strokeWidth},0===r.width&&(r.width=this.style.strokeWidth),0===r.height&&(r.height=this.style.strokeWidth);var d_y=(h.y-r.y)/r.height;a.x=r.width*((h.x-r.x)/r.width),a.y=r.height*d_y;var g,v,u=pF(e,l.angle,i),p=u.hAlign,f=u.vAlign;return"left"===p?(g="Left",a.x+=e.displacement.x):"right"===p?(g="Right",a.x-=e.displacement.x):"center"===p&&(g="Center"),"top"===f?(v="Top",a.y+=e.displacement.y):"bottom"===f?(v="Bottom",a.y-=e.displacement.y):"center"===f&&(v="Center"),s.horizontalAlignment=g,s.verticalAlignment=v,(s=im(s,o&&"Label"!==o.flipMode&&"None"!==o.flipMode?this.flip:"None",e)).float=!0,s.connectionDirection=e.connectionDirection,s.setOffsetWithRespectToBounds(a.x,a.y,"Absolute"),s.relativeMode="Point",s.visible=!(!ga(e,Gt.Visible)||ga(e,Gt.Hover)||ga(e,Gt.Connect)),s.elementActions=s.elementActions|Xr.ElementIsPort,s},t.prototype.getConnectorRelation=function(){var e=this.shape;"Association"===e.relationship?(this.segments[0].type="Straight",this.sourceDecorator.shape="None",this.targetDecorator.shape="Arrow"):"Inheritance"===e.relationship?(this.segments[0].type="Orthogonal",this.sourceDecorator.shape="None",this.targetDecorator.shape="Arrow"):"Composition"===e.relationship||"Aggregation"===e.relationship?(this.segments[0].type="Orthogonal",this.sourceDecorator.shape="Diamond",this.targetDecorator.shape="None"):"Dependency"===e.relationship?(this.segments[0].type="Orthogonal",this.sourceDecorator.shape="None",this.targetDecorator.shape="OpenArrow"):"Realization"===e.relationship&&(this.segments[0].type="Orthogonal",this.sourceDecorator.shape="None",this.targetDecorator.shape="Arrow"),"BiDirectional"===e.associationType&&(this.sourceDecorator.shape="None",this.targetDecorator.shape="None");var i,o,r="",s="";e.multiplicity.source&&(e.multiplicity.source.lowerBounds=e.multiplicity.source.lowerBounds,e.multiplicity.source.upperBounds=e.multiplicity.source.upperBounds),e.multiplicity.target&&(e.multiplicity.target.lowerBounds=e.multiplicity.target.lowerBounds,e.multiplicity.target.upperBounds=e.multiplicity.target.upperBounds);var a=e.multiplicity.source,l=e.multiplicity.target;o=a.upperBounds?a.lowerBounds+"..."+a.upperBounds:a.lowerBounds,i=l.upperBounds?l.lowerBounds+"..."+l.upperBounds:l.lowerBounds,"ManyToOne"===e.multiplicity.type&&(e.multiplicity.target.optional=!1,r=o||"*",s="1"),"OneToMany"===e.multiplicity.type&&(e.multiplicity.source.optional=!1,s=i||"*",r="1"),"ManyToMany"===e.multiplicity.type&&(r=o||"*",s=i||"*"),"OneToOne"===e.multiplicity.type&&(e.multiplicity.target.optional=!1,e.multiplicity.source.optional=!1,r="1",s="1"),this.annotations=[{id:this.id+"sourcelabel",content:r,offset:0,alignment:"Before",margin:{right:5,bottom:5}},{id:this.id+"targetlabel",content:s,offset:1,alignment:"Before",margin:{right:5,bottom:5}}]},t.prototype.getBpmnSequenceFlow=function(){var e=new Ke,i=new Ke;return"Normal"===this.shape.sequence&&"Bezier"!==this.type&&(this.targetDecorator.shape="Arrow"),"Default"===this.shape.sequence&&(e=this.getSegmentElement(this,e),i=IF(this.intermediatePoints,this),this.targetDecorator.shape="Arrow"),"Conditional"===this.shape.sequence&&(this.targetDecorator.shape="Arrow",this.sourceDecorator.shape="Diamond",i.id=this.id+this.shape.type),i},t.prototype.getUMLObjectFlow=function(){if(this.annotations)for(var e=0;e0&&(this.sourcePoint=o[0],this.targetPoint=o[o.length-1]),o},t.prototype.clipDecorator=function(e,i,r,s){var a,l,o={x:0,y:0},h=i.length,c=z.distancePoints(a=r?i[0]:i[h-1],l=r?i[1]:i[h-2]);c=0===c?1:c;var d=1,u=r?e.sourceWrapper:e.targetWrapper;u&&(d=u.style.strokeWidth,s&&s&ee.DecoratorPropertyChange&&(d=1));var p=d-1;return o.x=Math.round(a.x+p*(l.x-a.x)/c),o.y=Math.round(a.y+p*(l.y-a.y)/c),(r&&"None"!==e.sourceDecorator.shape||!r&&"None"!==e.targetDecorator.shape)&&(o=z.adjustPoint(o,l,!0,s&ee.DecoratorPropertyChange?0:d/2)),o},t.prototype.clipDecorators=function(e,i,r){return"None"!==e.sourceDecorator.shape&&(i[0]=this.clipDecorator(e,i,!0,r)),"None"!==e.targetDecorator.shape&&(i[i.length-1]=this.clipDecorator(e,i,!1,r)),i},t.prototype.updateSegmentElement=function(e,i,r,s){var o=new Ne,a=this.getSegmentPath(e,i,s);if("Bezier"===e.type){if(this.segments.length>0)for(var l=0;l0)if("Straight"===e.type&&e.segments.length<2)for(var o=0;o1)for(o=0;o0&&"Bezier"!==this.type)for(var p=0;p0&&(a=p0&&(f<2*this.cornerRadius?(l=z.adjustPoint(h[parseInt(p.toString(),10)],h[p+1],!0,f/2),p0&&(s=this.bridgePath(e,s,p),"Orthogonal"===e.type&&(s=this.bridgePath(e,s,p+1))),s+=" L"+a.x+" "+a.y))}else if("Bezier"===this.type){var g=void 0,v=void 0;if(this.parentObj.element){var y=this.parentObj.element.ej2_instances[0].eventHandler.action;g=this.parentObj.element.ej2_instances[0].eventHandler.tool instanceof kd,v=y.includes("PortDraw")||y.includes("Drag")}for(var S=void 0,b=this.segments,M=0;M2&&(b[parseInt(M.toString(),10)].bezierPoint1={x:0,y:0},b[parseInt(M.toString(),10)].bezierPoint2={x:0,y:0}),!z.isEmptyPoint(b[parseInt(M.toString(),10)].point1)||b[parseInt(M.toString(),10)].vector1.angle||b[parseInt(M.toString(),10)].vector1.distance?b[parseInt(M.toString(),10)].vector1.angle||b[parseInt(M.toString(),10)].vector1.distance?b[parseInt(M.toString(),10)].bezierPoint1=z.transform(h[parseInt(M.toString(),10)],b[parseInt(M.toString(),10)].vector1.angle,b[parseInt(M.toString(),10)].vector1.distance):b[parseInt(M.toString(),10)].bezierPoint1={x:b[parseInt(M.toString(),10)].point1.x||b[parseInt(M.toString(),10)].bezierPoint1.x,y:b[parseInt(M.toString(),10)].point1.y||b[parseInt(M.toString(),10)].bezierPoint1.y}:((e.sourceID||this.sourcePortID)&&this.sourceWrapper&&!v&&!g&&(S=Z3(this.sourceWrapper.bounds,h[parseInt(M.toString(),10)],!0)),b[parseInt(M.toString(),10)].bezierPoint1=GI(h[parseInt(M.toString(),10)],h[M+1],S)),!z.isEmptyPoint(b[parseInt(M.toString(),10)].point2)||b[parseInt(M.toString(),10)].vector2.angle||b[parseInt(M.toString(),10)].vector2.distance?b[parseInt(M.toString(),10)].vector2.angle||b[parseInt(M.toString(),10)].vector2.distance?b[parseInt(M.toString(),10)].bezierPoint2=z.transform(h[M+1],b[parseInt(M.toString(),10)].vector2.angle,b[parseInt(M.toString(),10)].vector2.distance):b[parseInt(M.toString(),10)].bezierPoint2={x:b[parseInt(M.toString(),10)].point2.x||b[parseInt(M.toString(),10)].bezierPoint2.x,y:b[parseInt(M.toString(),10)].point2.y||b[parseInt(M.toString(),10)].bezierPoint2.y}:((e.targetID||this.targetPortID)&&this.targetWrapper&&!v&&!g&&(S=Z3(this.targetWrapper.bounds,h[M+1],!0)),b[parseInt(M.toString(),10)].bezierPoint2=GI(h[M+1],h[parseInt(M.toString(),10)],S));h.splice(1,0,{x:b[0].bezierPoint1.x,y:b[0].bezierPoint1.y}),h.splice(h.length-1,0,{x:b[b.length-1].bezierPoint2.x,y:b[b.length-1].bezierPoint2.y}),h=this.clipDecorators(e,h,r);for(var w=0;w0&&(s=this.bridgePath(e,s,D),s+=" L"+o.x+" "+o.y);return s},t.prototype.updateShapeElement=function(e){var i;switch(e.shape.type){case"Bpmn":e.wrapper.children[3]instanceof Ke&&(i=e.wrapper.children[3]),"Message"===e.shape.flow&&this.updateShapePosition(e,i);break;case"UmlActivity":"Exception"===e.shape.flow&&this.getUMLExceptionFlow(e.wrapper.children[0])}},t.prototype.updateShapePosition=function(e,i){var o=bF(this.intermediatePoints,i,.5);i.offsetX=o.x,i.offsetY=o.y},t.prototype.scale=function(e,i,r,s,o){var a=0,l=0;if(this.wrapper&&this.wrapper.outerBounds){var h=function M3(n){var t=n.wrapper.children[0].bounds;return"None"!==n.sourceDecorator.shape&&t.uniteRect(n.wrapper.children[1].bounds),"None"!==n.targetDecorator.shape&&t.uniteRect(n.wrapper.children[2].bounds),t}(this),c=Math.abs((this.wrapper.bounds.width||this.style.strokeWidth||1)-2),d=Math.abs((this.wrapper.bounds.height||this.style.strokeWidth||1)-2);a=h.width-c,l=h.height-d,e=Math.abs((r-Math.max(a,l))/c),i=Math.abs((s-Math.max(a,l))/d),a=l=Math.min(a,l)}e=i=Math.min(e,i);var u=Hi();qi(u,-(o=o||this.wrapper).rotateAngle,o.offsetX,o.offsetY),Wp(u,e,i,o.offsetX,o.offsetY),qi(u,o.rotateAngle,o.offsetX,o.offsetY);var p=function Lie(n,t){for(var e=[],i=0,r=t;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Wne=function(n){function t(e,i){var r=n.call(this,e,i)||this;return r.offset=0,r.scale=1,r}return Vne(t,n),t.prototype.preRender=function(){this.unWireEvents(),this.wireEvents()},t.prototype.render=function(){this.updateRulerGeometry(),this.renderComplete()},t.prototype.getModuleName=function(){return"Ruler"},t.prototype.destroy=function(){this.unWireEvents(),this.notify("destroy",{}),n.prototype.destroy.call(this),this.element.classList.remove("e-ruler")},t.prototype.getPersistData=function(){return this.addOnPersist(["loaded"])},t.prototype.onPropertyChanged=function(e,i){for(var r=0,s=Object.keys(e);r100;)r/=10,s/=10;for(;s<25;)r*=10,s*=10;return s>=25&&s%25!=0&&(s=25*Math.round(s/25)),s*e/r},t.prototype.createMarkerLine=function(e,i,r){var s;return i&&((s=e.getElementById(i.id+"_marker"))&&s.parentNode.removeChild(s),s=Bi("line",r)),s},t.prototype.drawRulerMarker=function(e,i,r){var s,o,h,d,u="Horizontal"===this.orientation,p=e.getElementsByTagName("svg");for(h=0;h0)for(var a=i.childNodes.length-1;a>=0;a--)i.childNodes[parseInt(a.toString(),10)].parentNode.removeChild(i.childNodes[parseInt(a.toString(),10)]);i.appendChild(s)}return s},t.prototype.wireEvents=function(){},t.prototype.unWireEvents=function(){},kc([I(5)],t.prototype,"interval",void 0),kc([I(100)],t.prototype,"segmentWidth",void 0),kc([I("Horizontal")],t.prototype,"orientation",void 0),kc([I("RightOrBottom")],t.prototype,"tickAlignment",void 0),kc([I("red")],t.prototype,"markerColor",void 0),kc([I(25)],t.prototype,"thickness",void 0),kc([I(null)],t.prototype,"arrangeTick",void 0),kc([I(400)],t.prototype,"length",void 0),t}(yi);function eF(n,t){var e=document.getElementById(n.element.id+(t?"_hRuler":"_vRuler")),i=qa(n),r=tF(n);e||(e=Tt("div",{id:n.element.id+(t?"_hRuler":"_vRuler"),style:"height:"+(t?i.height:r.height+100)+"px;overflow:hidden;width:"+(t?r.width+100:i.width)+"px;position:absolute;font-size:11px;"+(t?"margin-left:"+i.width+"px;":"margin-top:"+i.height+"px;")})),n.element.insertBefore(e,n.element.firstChild);var l=t?n.rulerSettings.horizontalRuler:n.rulerSettings.verticalRuler,h=new Wne(l);h.orientation=t?"Horizontal":"Vertical",h.length=(t?r.width:r.height)+l.segmentWidth,h.appendTo("#"+n.element.id+(t?"_hRuler":"_vRuler")),t?n.hRuler=h:n.vRuler=h;var c=document.getElementById(n.element.id+(t?"_hRuler":"_vRuler"));t?n.hRuler.element=c:n.vRuler.element=c}function XI(n){var t=-n.scroller.horizontalOffset,e=-n.scroller.verticalOffset;n&&n.rulerSettings.showRulers?(n.hRuler.length=0,n.vRuler.length=0,void 0!==t&&n.hRuler.element&&iF(n,n.hRuler,t,!0),void 0!==e&&n.vRuler.element&&iF(n,n.vRuler,e,!1)):Qx(n)}function Qx(n){an(n.element.id+"_hRuler"),an(n.element.id+"_vRuler"),an(n.element.id+"_overlapRuler")}function qa(n){var t=0,e=0;return n.rulerSettings.showRulers&&(t=n.rulerSettings.horizontalRuler.thickness,e=n.rulerSettings.verticalRuler.thickness),new me(e,t)}function tF(n){var t=qa(n),e=n.scroller.viewPortHeight,i=n.scroller.viewPortWidth;return i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},rF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return $ne(t,n),t.prototype.getClassName=function(){return"UserHandle"},Fn([I("")],t.prototype,"name",void 0),Fn([I("")],t.prototype,"pathData",void 0),Fn([I("")],t.prototype,"content",void 0),Fn([I("")],t.prototype,"source",void 0),Fn([I("#000000")],t.prototype,"backgroundColor",void 0),Fn([I("Top")],t.prototype,"side",void 0),Fn([I("")],t.prototype,"borderColor",void 0),Fn([I(.5)],t.prototype,"borderWidth",void 0),Fn([I(25)],t.prototype,"size",void 0),Fn([I("white")],t.prototype,"pathColor",void 0),Fn([I(10)],t.prototype,"displacement",void 0),Fn([I(!0)],t.prototype,"visible",void 0),Fn([I(0)],t.prototype,"offset",void 0),Fn([re({},$n)],t.prototype,"margin",void 0),Fn([I("Center")],t.prototype,"horizontalAlignment",void 0),Fn([I("Center")],t.prototype,"verticalAlignment",void 0),Fn([I(!1)],t.prototype,"disableNodes",void 0),Fn([I(!1)],t.prototype,"disableConnectors",void 0),Fn([re({},Ed)],t.prototype,"tooltip",void 0),Fn([I("")],t.prototype,"template",void 0),t}(Ee);function nF(n){return Zne[n.toString()]}var Zne={Action:"M 90 82.895 C 90 86.819 86.776 90 82.8 90 H 7.2 C 3.224 90 0 86.819 0 82.895 V 7.105 C 0 3.181 3.224 0 7.2 0 h 75.6 C 86.776 0 90 3.181 90 7.105 V 82.895 Z",Decision:"M10,19.707L0.293,10L10,0.293L19.707,10L10,19.707z",MergeNode:"M10,19.707L0.293,10L10,0.293L19.707,10L10,19.707z",InitialNode:"M10,19.5c-5.238,0-9.5-4.262-9.5-9.5S4.762,0.5,10,0.5s9.5,4.262,9.5,9.5S15.238,19.5,10,19.5z",ForkNode:"m0.75,0.75l636.00002,0l0,290l-636.00002,0l0,-290z",JoinNode:"m0.75,0.75l636.00002,0l0,290l-636.00002,0l0,-290z",TimeEvent:"M50.001,0.00286865 L25.001,25.0029 L0.000976562,0.00286865 L50.001,0.00286865 z M0.000976562,50.0029 L25.001,25.0029 L50.001,50.0029 L0.000976562,50.0029 z",AcceptingEvent:"M17.8336 32.164 L29.64 24 L17.32 16 L48.1664 16 L48.5 32 Z",SendSignal:"M48.164 31.8336 L56 23.832 L47.836 16 L16.168 16 L16.1668 31.8336 Z",ReceiveSignal:"M48.1664 31.8336 L39.836 24 L47.836 16 L16.168 16 L16.168 31.836 Z",StructuredNode:"M0,0 L50,0 L50,50 L0,50 z",Note:"M20 12 L4 12 L4 22 L22 22 L22 14 L20 14 L20 12 L22 14 Z"},qI=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),$a=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Jne=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return qI(t,n),$a([I()],t.prototype,"key",void 0),$a([I()],t.prototype,"keyModifiers",void 0),t}(Ee),sF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return qI(t,n),t.prototype.getClassName=function(){return"Command"},$a([I("")],t.prototype,"name",void 0),$a([I()],t.prototype,"canExecute",void 0),$a([I()],t.prototype,"execute",void 0),$a([re({},Jne)],t.prototype,"gesture",void 0),$a([I("")],t.prototype,"parameter",void 0),t}(Ee),Kne=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return qI(t,n),$a([Bt([],sF)],t.prototype,"commands",void 0),t}(Ee),ese=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return qI(t,n),$a([I()],t.prototype,"show",void 0),$a([I()],t.prototype,"showCustomMenuOnly",void 0),$a([I()],t.prototype,"items",void 0),t}(Ee),qp=function(){function n(){}return n.prototype.renderShadow=function(t,e,i,r){void 0===i&&(i=null);var l,o=z.transform({x:0,y:0},t.shadow.angle,t.shadow.distance);r&&(l=r.getElementById(e.id+"_shadow")),l||(l=document.createElementNS("http://www.w3.org/2000/svg",i?"path":"rect"),e.appendChild(l));var h={id:e.id+"_shadow",fill:t.shadow.color,stroke:t.shadow.color,opacity:t.shadow.opacity.toString(),transform:"rotate("+t.angle+","+(t.x+t.width*t.pivotX)+","+(t.y+t.height*t.pivotY)+")translate("+(t.x+o.x)+","+(t.y+o.y)+")"};if(r){var c=r.getElementById(e.id);c&&c.insertBefore(l,c.firstChild)}ai(l,h),i?i&&this.renderPath(l,t,i):ai(l,{width:t.width,height:t.height})},n.prototype.parseDashArray=function(t){return[]},n.prototype.drawRectangle=function(t,e,i,r,s,o,a,l,h){var c,d,u,p;e.shadow&&!r&&this.renderShadow(e,t,void 0,o),c=e.id===t.id?e.id+"_container":e.id,o&&(d=o.getElementById(c)),(!d||s)&&(d=document.createElementNS("http://www.w3.org/2000/svg","rect"),t.appendChild(d)),o&&!e.shadow&&(u=o.getElementById(e.id+"_groupElement_shadow"))&&u.parentNode.removeChild(u),p=l?{id:c,x:e.x.toString(),y:e.y.toString(),width:e.width.toString(),height:e.height.toString(),visibility:e.visible?"visible":"hidden",transform:"rotate("+e.angle+","+(e.x+e.width/2)+","+(e.y+e.height/2)+")",rx:e.cornerRadius||0,ry:e.cornerRadius||0,opacity:e.opacity}:{id:c,x:e.x.toString(),y:e.y.toString(),width:e.width.toString(),height:e.height.toString(),visibility:e.visible?"visible":"hidden",transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")",rx:e.cornerRadius||0,ry:e.cornerRadius||0,opacity:e.opacity},a&&(p.role="img",p["aria-label"]=a);var f=e.class||"";h||(f.includes("e-diagram-resize-handle")||f.includes("e-diagram-endpoint-handle")||f.includes("e-diagram-bezier-control-handle"))&&(f+=" e-disabled"),e.class&&(p.class=f),a||(p["pointer-events"]="none"),ai(d,p),this.setSvgStyle(d,e,i)},n.prototype.updateSelectionRegion=function(t,e){var i;i=t.parentNode.getElementById(e.id);var r={id:e.id,x:e.x.toString(),y:e.y.toString(),width:e.width.toString(),height:e.height.toString(),transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")",class:"e-diagram-selected-region"};i||(i=document.createElementNS("http://www.w3.org/2000/svg","rect"),t.appendChild(i)),this.setSvgStyle(i,e),ai(i,r)},n.prototype.createGElement=function(t,e){return Bi(t,e)},n.prototype.drawLine=function(t,e){var i=document.createElementNS("http://www.w3.org/2000/svg","line");this.setSvgStyle(i,e);var r=e.x+e.width*e.pivotX,s=e.y+e.height*e.pivotY,o={id:e.id,x1:e.startPoint.x+e.x,y1:e.startPoint.y+e.y,x2:e.endPoint.x+e.x,y2:e.endPoint.y+e.y,stroke:e.stroke,"stroke-width":e.strokeWidth.toString(),opacity:e.opacity.toString(),transform:"rotate("+e.angle+" "+r+" "+s+")",visibility:e.visible?"visible":"hidden"};e.class&&(o.class=e.class),ai(i,o),t.appendChild(i)},n.prototype.drawCircle=function(t,e,i,r){var s=document.createElementNS("http://www.w3.org/2000/svg","circle");this.setSvgStyle(s,e);var o=e.class||"";i||(o+=" e-disabled");var a={id:e.id,cx:e.centerX,cy:e.centerY,r:e.radius,visibility:e.visible?"visible":"hidden",class:o};r&&(a.role="img",a["aria-label"]=r),s.style.display=e.visible?"block":"none",ai(s,a),t.appendChild(s)},n.prototype.drawPath=function(t,e,i,r,s,o,a){var h,c,l=[];l=XB(l=Cd(e.data)),e.shadow&&this.renderShadow(e,t,l,s),s&&!e.shadow&&(h=s.getElementById(e.id+"_groupElement_shadow"))&&h.parentNode.removeChild(h),s&&(c=s.getElementById(e.id)),(!c||r)&&(c=document.createElementNS("http://www.w3.org/2000/svg","path"),t.appendChild(c)),this.renderPath(c,e,l);var d={};d=a?{id:e.id,transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")translate("+e.x+","+e.y+"),scale("+a+")",visibility:e.visible?"visible":"hidden",opacity:e.opacity}:{id:e.id,transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")translate("+e.x+","+e.y+")",visibility:e.visible?"visible":"hidden",opacity:e.opacity},o&&(d.role="img",d["aria-label"]=o),e.class&&(d.class=e.class),ai(c,d),this.setSvgStyle(c,e,i)},n.prototype.renderPath=function(t,e,i){var r,s,o,a,l,h,c,d,u=i,p="";for(l=0,h=0,d=0,c=u.length;de.width&&"Wrap"!==e.textOverflow&&"NoWrap"===e.textWrapping&&(h[0].text=VF(e.content,e)),v=0;vD&&(u.text=u.text.slice(0,u.text.length-3),u.text=u.text.concat("..."),l.data=u.text),this.alignText(y,p,u,l,f,g,v,e,h),C+=u.dy}}C&&e.isHorizontalLane&&(M=e.parentOffsetX+e.pivotX,w=e.parentOffsetY+e.pivotY,e.y=e.parentOffsetY-C*e.pivotY+.5),e.textDecoration&&"LineThrough"===e.textDecoration&&(e.textDecoration=hb(e.textDecoration));var R={id:e.id+"_text",fill:e.color,visibility:e.visible?"visible":"hidden","text-decoration":e.textDecoration,transform:"rotate("+e.angle+","+M+","+w+")translate("+e.x+","+e.y+")",opacity:e.opacity};r&&(R.role="img",R["aria-label"]=r),ai(y,R)}},n.prototype.alignText=function(t,e,i,r,s,o,a,l,h){"justify"!==l.textAlign?this.setText(t,e,i,r,s,o,l):a!==h.length-1?this.setText(t,e,i,r,s,o,l,l.width,"spacing"):this.setText(t,e,i,r,s,o,l)},n.prototype.setText=function(t,e,i,r,s,o,a,l,h){ai(e,"justify"!==a.textAlign?{x:s.toString(),y:o.toString()}:{x:s.toString(),y:o.toString(),textLength:l||0,lengthAdjust:h||"spacing"}),t.setAttribute("fill",i.text),e.appendChild(r),t.appendChild(e)},n.prototype.drawImage=function(t,e,i,r){var s;i&&(s=i.getElementById(e.id+"image")),s||(s=document.createElementNS("http://www.w3.org/2000/svg","image"),t.appendChild(s));var o=new Image;o.src=e.source;var a="None"!==e.scale?e.scale:"",l=e.alignment,h=l.charAt(0).toLowerCase()+l.slice(1);"Stretch"!==a&&(h+=" "+a.charAt(0).toLowerCase()+a.slice(1)),ai(s,{id:e.id+"image",x:e.x.toString(),y:e.y.toString(),transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")",width:e.width.toString(),visibility:e.visible?"visible":"hidden",height:e.height.toString(),preserveAspectRatio:h,opacity:e.opacity.toString()}),s.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",o.src.toString())},n.prototype.drawHTMLContent=function(t,e,i,r,s){var o,a;if(e&&(o=e.querySelector("#"+t.id+"_html_element")),!o){(a=e.querySelector("#"+t.id+"_html_element")||e.querySelector("#"+t.nodeId+"_html_element"))||(a=Tt("div",{id:t.nodeId+"_html_element",class:"foreign-object"})),o=Tt("div",{id:t.id+"_html_element",class:"foreign-object"});var c=document.getElementById(t.diagramId).ej2_instances[0],d=!1;if(e.parentNode&&e.parentNode.parentNode&&e.parentNode.parentNode.parentNode&&e.parentNode.parentNode.parentNode.classList.contains("e-overview")&&(d=!0),d)c.isReact?c.renderReactTemplates(function(){o.appendChild(t.template.cloneNode(!0))}):o.appendChild(t.template.cloneNode(!0));else{if("string"==typeof t.template){var u=document.createElement("div");u.innerHTML=t.template,t.template=u,c.selectedItems.userHandles.filter(function(g){return g.name===t.id.split("_shape")[0]&&""!==g.template})[0].template=t.template}t.isTemplate&&t.template?o.appendChild(t.template):t.template&&o.appendChild(t.template.cloneNode(!0))}void 0!==s&&e.childNodes.length>s&&e.insertBefore(o,e.childNodes[parseInt(s.toString(),10)]),a.appendChild(o),e.appendChild(a)}var f=En(t).topLeft;o.setAttribute("style","height:"+t.actualSize.height+"px; width:"+t.actualSize.width+"px;left:"+f.x+"px; top:"+f.y+"px;position:absolute;transform:rotate("+(t.rotateAngle+t.parentTransform)+"deg);pointer-events:"+(r?"all":"none")+";visibility:"+(t.visible?"visible":"hidden")+";opacity:"+t.style.opacity+";")},n.prototype.drawNativeContent=function(t,e,i,r,s){var o,a;if(s&&(o=s.getElementById(t.id+"_native_element"),a=s.getElementById(t.id+"_clip")),!o){(o=document.createElementNS("http://www.w3.org/2000/svg","g")).setAttribute("id",t.id+"_native_element"),o.appendChild(t.template.cloneNode(!0));var l=this.createGElement("g",{id:t.id+"_inner_native_element"});l.appendChild(o),e.appendChild(l)}a&&o.removeChild(a),o.setAttribute("style","visibility:"+(t.visible?"visible":"hidden")+";opacity:"+t.style.opacity+";"),this.setNativTransform(t,o,i,r),"Slice"===t.scale&&this.drawClipPath(t,o,i,r,s),ai(o,t.description?{role:"img","aria-label":t.description}:{})},n.prototype.setNativTransform=function(t,e,i,r){var s=0!==t.contentSize.width?t.contentSize.width:1,o=0!==t.contentSize.height?t.contentSize.height:1;e.setAttribute("transform","rotate("+t.parentTransform+","+t.offsetX+","+t.offsetY+") translate("+(t.offsetX-t.templatePosition.x*r/s-r*t.pivot.x)+","+(t.offsetY-t.templatePosition.y*i/o-i*t.pivot.y)+") scale("+r/s+","+i/o+")")},n.prototype.drawClipPath=function(t,e,i,r,s){var o=t.contentSize.width,a=t.contentSize.height,l=t.width/(r/o),h=t.height/(i/a),c=t.templatePosition.x+(t.width>=t.height?0:(o-l)/2),d=t.templatePosition.y+(t.height>=t.width?0:(a-h)/2),u=s.getElementById(t.id+"_clip");(u=document.createElementNS("http://www.w3.org/2000/svg","clipPath")).setAttribute("id",t.id+"_clip"),e.appendChild(u);var p=s.getElementById(t.id+"_clip_rect");return p=document.createElementNS("http://www.w3.org/2000/svg","rect"),u.appendChild(p),ai(p,{id:t.id+"_clip_rect",width:l.toString(),height:h.toString(),x:c.toString(),y:d.toString()}),nm()?e.setAttribute("clip-path","url("+location.protocol+"//"+location.host+location.pathname+"#"+t.id+"_clip)"):e.setAttribute("clip-path","url(#"+t.id+"_clip)"),e},n.prototype.renderGradient=function(t,e,i){var r,s,o,h,c,a=mT(i),l=a.getElementById(i+"gradient_pattern");if(l||(l=Bi("defs",{id:i+"gradient_pattern"}),a.insertBefore(l,a.firstChild)),gF(e.id),"None"!==t.gradient.type){for(var d=0;dt.width&&("Ellipsis"===t.textOverflow||"Clip"===t.textOverflow)&&"NoWrap"===t.textWrapping?0:.5*t.width:"right"===t.textAlign&&(c=1*t.width),s.x=0+c+(e?e.x:0),s.y=1.2+d-r.height/2,s},n}(),Pc=function(){function n(t,e,i){this.renderer=null,this.isSvgMode=!0,this.transform={x:0,y:0},this.diagramId=t,this.element=xt(this.diagramId),this.svgRenderer=e,this.isSvgMode=i,this.renderer=i?new qp:new bo}return n.prototype.setCursor=function(t,e){t.style.cursor=e},n.prototype.setLayers=function(){this.iconSvgLayer=this.element.getElementsByClassName("e-ports-expand-layer")[0],this.adornerSvgLayer=this.element.getElementsByClassName("e-adorner-layer")[0],this.nativeSvgLayer=this.element.getElementsByClassName("e-native-layer")[0],this.diagramSvgLayer=this.element.getElementsByClassName("e-diagram-layer")[0]},n.prototype.getAdornerLayer=function(){return gT(this.diagramId)},n.prototype.getParentSvg=function(t,e,i){return this.diagramId&&t&&t.id?t.id.split("_icon_content").length>1||t.id.split("_nodeport").length>1||t.elementActions&Xr.ElementIsPort?this.iconSvgLayer:e&&"selector"===e?this.adornerSvgLayer:t instanceof Cn?this.nativeSvgLayer:this.diagramSvgLayer:i},n.prototype.getParentElement=function(t,e,i,r){var s=e;if(i&&this.diagramId&&t&&t.id){t.id.split("_icon_content").length>1?(s=i.getElementById(this.diagramId+"_diagramExpander"),e=null):t.id.split("_nodeport").length>1?s=i.getElementById(this.diagramId+"_diagramPorts"):t instanceof Cn?(s=i.getElementById(this.diagramId+"_nativeLayer"),e=null):t.elementActions&Xr.ElementIsPort?(s=i.getElementById(this.diagramId+"_diagramPorts"),e=null):s=i.getElementById(this.diagramId+"_diagramLayer");var o=this.getGroupElement(t,e||s,r);s=o.g,o.svg&&(i=o.svg)}return{g:s,svg:i}},n.prototype.getGroupElement=function(t,e,i){var r,o,s=this.getParentSvg(t);if(e&&s){if(s&&!(r=s.getElementById(t.id+"_groupElement"))&&s!==this.nativeSvgLayer){var a=this.nativeSvgLayer;r=a.getElementById(t.id+"_groupElement"),o=a}r||(r=this.svgRenderer.createGElement("g",{id:t.id+"_groupElement"}),void 0!==i&&e.childNodes.length>i?e.insertBefore(r,e.childNodes[parseInt(i.toString(),10)]):e.appendChild(r))}return{g:r,svg:o}},n.prototype.renderElement=function(t,e,i,r,s,o,a,l,h,c,d){t instanceof Cs?(t.id=t.id?t.id:Qe(),this.renderContainer(t,e,i,r,s,o,a,l,h,c,d)):t instanceof SI?this.renderImageElement(t,e,r,s,a):t instanceof Ke?this.renderPathElement(t,e,r,s,a,h,d):t instanceof si?this.renderTextElement(t,e,r,s,a,c):t instanceof Cn?this.renderNativeElement(t,e,r,s,a):t instanceof Jn?this.renderHTMLElement(t,e,i,r,s,a,l):this.renderRect(t,e,r,s,h)},n.prototype.drawSelectionRectangle=function(t,e,i,r,s,o){var a={width:i*o.scale,height:r*o.scale,x:.5+(t=(t+o.tx)*o.scale),y:.5+(e=(e+o.ty)*o.scale),fill:"transparent",stroke:"gray",angle:0,pivotX:.5,pivotY:.5,strokeWidth:1,dashArray:"6 3",opacity:1,visible:!0,id:s.id+"_selected_region"},l=this.getAdornerLayer();this.svgRenderer.updateSelectionRegion(l,a)},n.prototype.renderHighlighter=function(t,e,i){var r=t.actualSize.width||2,s=t.actualSize.height||2,o=t.offsetX-r*t.pivot.x,a=t.offsetY-s*t.pivot.y;this.svgRenderer.drawRectangle(e,{width:r*i.scale,height:s*i.scale,x:o=(o+i.tx)*i.scale,y:a=(a+i.ty)*i.scale,fill:"transparent",stroke:"#8CC63F",angle:t.rotateAngle,pivotX:t.pivot.x,pivotY:t.pivot.y,strokeWidth:4,dashArray:"",opacity:1,cornerRadius:0,visible:!0,id:e.id+"_highlighter",class:"e-diagram-highlighter"},this.diagramId,void 0,void 0,e)},n.prototype.renderSelectionRectangle=function(t,e,i,r){var s=t.actualSize.width||2,o=t.actualSize.height||2,a=t.offsetX-s*t.pivot.x,l=t.offsetY-o*t.pivot.y,h={width:s*i.scale,height:o*i.scale,x:a=(a+i.tx)*i.scale,y:l=(l+i.ty)*i.scale,fill:"transparent",stroke:"#00cc00",angle:t.rotateAngle,pivotX:t.pivot.x,pivotY:t.pivot.y,strokeWidth:r?2:1,dashArray:"",opacity:1,cornerRadius:0,visible:!0,id:t.id+"_highlighter",class:r?"e-diagram-first-selection-indicator e-diagram-selection-indicator":"e-diagram-selection-indicator"},c=this.getParentSvg(t,"selector");this.svgRenderer.drawRectangle(e,h,this.diagramId,void 0,void 0,c)},n.prototype.renderSelectionLine=function(t,e,i,r){var s=this.getBaseAttributes(t,i);s.data=t.absolutePath,s.id=s.id+"_highlighter";var o=t.description?t.description:t.id;this.isSvgMode||(s.x=t.flipOffset.x?t.flipOffset.x:s.x,s.y=t.flipOffset.y?t.flipOffset.y:s.y),i&&(s.x=s.x*i.scale,s.y=s.y*i.scale),s.stroke="#00cc00",s.strokeWidth=r?2:1,s.class=r?"e-diagram-first-selection-indicator e-diagram-selection-indicator":"e-diagram-selection-indicator";var a=this.getParentSvg(t,"selector");this.svgRenderer.drawPath(e,s,this.diagramId,void 0,a,o,i.scale)},n.prototype.renderStackHighlighter=function(t,e,i,r,s,o,a){var l=t.actualSize.width||2,h=t.offsetX-l*t.pivot.x,c=t.actualSize.height||2,d=t.offsetY-c*t.pivot.y;h=(h+i.tx)*i.scale;var u,p=t.bounds,f="";if(d=(d+i.ty)*i.scale,r)if(o){var v,y;u="M 0 0 L "+(2+(g=l*i.scale))+" 0 Z",v=t.actualSize.width/Number(p.width?p.width:1)*i.scale,y=t.actualSize.height/Number(p.height?p.height:1)*i.scale,f=fI(gI(Cd("M7,4 L8,4 8,7 11,7 11,8 8,8 8,11 7,11 7,8 4,8 4,7 7,7 z M7.5,0.99999994C3.9160004,1 1,3.9160004 0.99999994,7.5 1,11.084 3.9160004,14 7.5,14 11.084,14 14,11.084 14,7.5 14,3.9160004 11.084,1 7.5,0.99999994 z M7.5,0 C11.636002,0 15,3.3639984 15,7.5 15,11.636002 11.636002,15 7.5,15 3.3640003,15 0,11.636002 0,7.5 0,3.3639984 3.3640003,0 7.5,0 z")),v+g+2,y-8,!1,p.x,p.y,0,0),s.y>=t.offsetY&&(d+=c)}else{var g;a&&s.y>=t.offsetY&&(d+=c*i.scale),u="M -10 -10 L 0 0 Z M -10 10 L 0 0 Z M 0 0 L "+(g=l*i.scale)+" 0 Z M "+g+" 0 L "+(g+10)+" 10 Z L "+(g+10)+" -10 Z"}else u="M 10 -10 L 0 0 Z M -10 -10 L 0 0 Z M 0 0 L 0 "+(g=c*i.scale)+" Z M 0 "+g+" L -10 "+(g+10)+" Z L 10 "+(g+10)+" Z",s.x>=t.offsetX&&(h+=l*i.scale);this.svgRenderer.drawPath(e,{data:u+f,width:l*i.scale,height:c*i.scale,x:h,y:d,fill:"transparent",stroke:"#8CC63F",angle:t.rotateAngle,pivotX:t.pivot.x,pivotY:t.pivot.y,strokeWidth:1,dashArray:"",opacity:1,visible:!0,id:e.id+"_stack_highlighter",class:"e-diagram-highlighter"},this.diagramId)},n.prototype.drawLine=function(t,e){this.svgRenderer.drawLine(t,e)},n.prototype.drawPath=function(t,e){this.svgRenderer.drawPath(t,e,this.diagramId)},n.prototype.renderResizeHandle=function(t,e,i,r,s,o,a,l,h,c,d){var u=t.offsetX-t.actualSize.width*t.pivot.x,p=t.offsetY-t.actualSize.height*t.pivot.y,f=t.actualSize.height,g=t.actualSize.width;!c&&i&bt.Rotate&&zI(this.rendererActions)&&!A3(this.rendererActions)&&(this.renderPivotLine(t,e,o,s,a),this.renderRotateThumb(t,e,o,s,a)),this.renderBorder(t,e,o,l,h,c);var v=t.actualSize.width*r,y=t.actualSize.height*r;!h&&zI(this.rendererActions)&&!A3(this.rendererActions)&&(t.isTextAnnotation||(v>=40&&y>=40&&(s&mr.ResizeNorthWest&&this.renderCircularHandle("resizeNorthWest",t,u,p,e,qr(s,"ResizeNorthWest"),i&bt.ResizeNorthWest,o,void 0,a,{"aria-label":"Thumb to resize the selected object on top left side direction"},void 0,"e-diagram-resize-handle e-northwest",d),s&mr.ResizeNorthEast&&this.renderCircularHandle("resizeNorthEast",t,u+g,p,e,qr(s,"ResizeNorthEast"),i&bt.ResizeNorthEast,o,void 0,a,{"aria-label":"Thumb to resize the selected object on top right side direction"},void 0,"e-diagram-resize-handle e-northeast",d),s&mr.ResizeSouthWest&&this.renderCircularHandle("resizeSouthWest",t,u,p+f,e,qr(s,"ResizeSouthWest"),i&bt.ResizeSouthWest,o,void 0,a,{"aria-label":"Thumb to resize the selected object on bottom left side direction"},void 0,"e-diagram-resize-handle e-southwest",d),s&mr.ResizeSouthEast&&this.renderCircularHandle("resizeSouthEast",t,u+g,p+f,e,qr(s,"ResizeSouthEast"),i&bt.ResizeSouthEast,o,void 0,a,{"aria-label":"Thumb to resize the selected object on bottom right side direction"},void 0,"e-diagram-resize-handle e-southeast",d)),s&mr.ResizeNorth&&this.renderCircularHandle("resizeNorth",t,u+g/2,p,e,qr(s,"ResizeNorth"),i&bt.ResizeNorth,o,void 0,a,{"aria-label":"Thumb to resize the selected object on top side direction"},void 0,"e-diagram-resize-handle e-north",d),s&mr.ResizeSouth&&this.renderCircularHandle("resizeSouth",t,u+g/2,p+f,e,qr(s,"ResizeSouth"),i&bt.ResizeSouth,o,void 0,a,{"aria-label":"Thumb to resize the selected object on bottom side direction"},void 0,"e-diagram-resize-handle e-south",d),s&mr.ResizeWest&&this.renderCircularHandle("resizeWest",t,u,p+f/2,e,qr(s,"ResizeWest"),i&bt.ResizeWest,o,void 0,a,{"aria-label":"Thumb to resize the selected object on left side direction"},void 0,"e-diagram-resize-handle e-west",d),s&mr.ResizeEast&&this.renderCircularHandle("resizeEast",t,u+g,p+f/2,e,qr(s,"ResizeEast"),i&bt.ResizeEast,o,void 0,a,{"aria-label":"Thumb to resize the selected object on right side direction"},void 0,"e-diagram-resize-handle e-east",d)))},n.prototype.renderEndPointHandle=function(t,e,i,r,s,o,a,l,h,c){var f,g,d=t.sourcePoint,u=t.targetPoint,p=t.wrapper;if(this.renderCircularHandle("connectorSourceThumb",p,d.x,d.y,e,qr(r,"ConnectorSourceThumb"),i&bt.ConnectorSource,s,o,void 0,{"aria-label":"Thumb to move the source point of the connector"},void 0,"e-diagram-endpoint-handle e-sourceend",c),this.renderCircularHandle("connectorTargetThumb",p,u.x,u.y,e,qr(r,"ConnectorTargetThumb"),i&bt.ConnectorTarget,s,a,void 0,{"aria-label":"Thumb to move the target point of the connector"},void 0,"e-diagram-endpoint-handle e-targetend",c),l)if("Straight"===t.type&&t.segments.length>0)for(f=0;f0)for(f=0;f=3&&3===t.segments.length&&(S=1,b=t.segments.length-1),S=t.segments.length>t.maxSegmentThumb+2?2:S,b=t.segments.length>t.maxSegmentThumb+2?t.segments.length-2:b,1===t.segments.length&&t.segments[0].points.length<=2&&(S=1,b=t.segments.length),f=S;f=50&&i.allowDrag),this.renderOrthogonalThumb(t+"_"+(d+1),e,(i.points[parseInt(d.toString(),10)].x+i.points[d+1].x)/2,(i.points[parseInt(d.toString(),10)].y+i.points[d+1].y)/2,r,h,l,o,a,u)}else for(d=0;d=50&&i.allowDrag),this.renderOrthogonalThumb(t+"_"+(d+1),e,(i.points[parseInt(d.toString(),10)].x+i.points[d+1].x)/2,(i.points[parseInt(d.toString(),10)].y+i.points[d+1].y)/2,r,h,l,o,a,u)},n.prototype.renderOrthogonalThumb=function(t,e,i,r,s,o,a,l,h,c){var d,g,u=0,p=document.getElementById(this.diagramId);p&&(g=p.ej2_instances[0]);var y=h.constraints&qe.InheritSegmentThumbShape?g.segmentThumbShape:h.segmentThumbShape,b=h.constraints&qe.InheritSegmentThumbSize?g.segmentThumbSize:h.segmentThumbSize;if(d="horizontal"===a?function tre(n){return sre[""+n]}(y):n3(y),"Arrow"===y||"DoubleArrow"===y||"OpenArrow"===y)switch(c){case"Bottom":case"Right":u=180;break;default:u=0}else if("Fletch"===y||"OpenFetch"===y||"IndentedArrow"===y||"OutdentedArrow"===y)switch(c){case"Bottom":u=-90;break;case"Top":u=90;break;case"Right":u=180;break;default:u=0}var M={x:(i+l.tx)*l.scale-b/2,y:(r+l.ty)*l.scale-b/2,angle:u,fill:"#e2e2e2",stroke:"black",strokeWidth:1,dashArray:"",data:d,width:b,height:b,pivotX:.5,pivotY:.5,opacity:1,visible:o,id:t,class:"e-diagram-ortho-segment-handle"},w=nf(M.data),C=new me(M.width,M.height),D=new Ke;M.data=D.updatePath(M.data,w,C),this.svgRenderer.drawPath(s,M,this.diagramId)},n.prototype.renderPivotLine=function(t,e,i,r,s){var o=t,l=!!(r&mr.Rotate);s&&(l=!1);var h=this.getBaseAttributes(o,i);h.fill="None",h.stroke="black",h.strokeWidth=1,h.dashArray="2,3",h.visible=l;var c=i.scale;h.x*=c,h.y*=c,h.width*=c,h.height*=c,h.id="pivotLine",h.class="e-diagram-pivot-line";var u={x:o.actualSize.width*o.pivot.x*c,y:0};h.startPoint={x:o.actualSize.width*o.pivot.x*c,y:-20},h.endPoint=u,this.svgRenderer.drawLine(e,h)},n.prototype.renderBezierLine=function(t,e,i,r,s,o){var l=this.getBaseAttributes(e,o);l.id=t,l.stroke="black",l.strokeWidth=1,l.dashArray="3,3",l.fill="None",l.class="e-diagram-bezier-control-line",l.x=0,l.y=0;var h=o.scale,g={x:(s.x+o.tx)*h,y:(s.y+o.ty)*h};l.startPoint={x:(r.x+o.tx)*h,y:(r.y+o.ty)*h},l.endPoint=g,this.svgRenderer.drawLine(i,l)},n.prototype.renderCircularHandle=function(t,e,i,r,s,o,a,l,h,c,d,u,p,f){var g=e,v={x:i,y:r};if(0!==g.rotateAngle||0!==g.parentTransform){var y=Hi();qi(y,g.rotateAngle+g.parentTransform,g.offsetX,g.offsetY),v=Je(y,v)}var S=this.getBaseAttributes(g);S.stroke="black",S.strokeWidth=1,void 0!==u?(S.id="segmentEnd_"+u,S.fill="#e2e2e2"):S.fill=h?"#8CC63F":"white",S.cornerRadius=f/2,S.angle=e.rotateAngle,S.id=t,S.visible=o,S.class=p,S.width=f,S.height=f,S.x=(v.x+l.tx)*l.scale,S.y=(v.y+l.ty)*l.scale,S.x=S.x-S.width/2,S.y=S.y-S.height/2,h&&(S.class+=" e-connected"),c&&(S.visible=!1);var b=this.getParentSvg(e,"selector");this.svgRenderer.drawRectangle(s,S,this.diagramId,!0,!0,b,d,!0,a)},n.prototype.renderBezierHandle=function(t,e,i,r,s,o,a,l,h,c,d,u,p){var v,f=document.getElementById(this.diagramId);f&&(v=f.ej2_instances[0]);var y=e,S={x:i,y:r};if(0!==y.rotateAngle||0!==y.parentTransform){var b=Hi();qi(b,y.rotateAngle+y.parentTransform,y.offsetX,y.offsetY),S=Je(b,S)}var D=a.constraints&qe.InheritSegmentThumbSize?v.segmentThumbSize:a.segmentThumbSize,A=n3(a.constraints&qe.InheritSegmentThumbShape?v.segmentThumbShape:a.segmentThumbShape),x=this.getBaseAttributes(y);x.stroke="black",x.strokeWidth=1,void 0!==d?(x.id="segmentEnd_"+d,x.fill="#e2e2e2"):x.fill=h?"#8CC63F":"white",x.angle=e.rotateAngle,x.id=t,x.visible=o,x.class=u,x.width=D,x.height=D,x.data=A,x.x=(S.x+l.tx)*l.scale,x.y=(S.y+l.ty)*l.scale,x.x=x.x-x.width/2,x.y=x.y-x.height/2,h&&(x.class+=" e-connected"),c&&(x.visible=!1);var R=nf(x.data),L=new me(x.width,x.height),O=new Ke;x.data=O.updatePath(x.data,R,L);var N=this.getParentSvg(e,"selector");this.svgRenderer.drawPath(s,x,this.diagramId,!0,N)},n.prototype.renderBorder=function(t,e,i,r,s,o){var l=this.getBaseAttributes(t,i);l.x*=i.scale,l.y*=i.scale,l.width*=i.scale,l.height*=i.scale,l.fill="transparent",l.stroke="#097F7F",l.strokeWidth=1.2,l.gradient=null,l.dashArray="6,3",l.class="e-diagram-selector",o&&(l.class+=" e-diagram-lane"),l.id="borderRect",l.id=this.rendererActions&Qa.DrawSelectorBorder?"borderRect_symbol":"borderRect",r||(l.class+=" e-disabled"),s&&(l.class+=" e-thick-border"),l.cornerRadius=0;var h=this.getParentSvg(t,"selector");this.svgRenderer.drawRectangle(e,l,this.diagramId,void 0,!0,h)},n.prototype.renderUserHandler=function(t,e,i,r,s,o){for(var l,a=t.wrapper,h=0,c=t.userHandles;h0||d.disableNodes&&t.nodes.length>0||"Drag"===s&&o)&&(l=!1);var u=document.getElementById(d.name+"_template_hiddenUserHandle");u&&(d.template=u.childNodes[0].cloneNode(!0));var p=Kx(t,d,i);if(p.x=(p.x+i.tx)*i.scale,p.y=(p.y+i.ty)*i.scale,d.visible&&(d.visible=!!(t.constraints&mr.UserHandle)),l)if(d.pathData){var f=d.pathData?d.pathData:d.content,g=this.getBaseAttributes(a);g.id=d.name+"_userhandle",g.fill=d.backgroundColor,g.stroke=d.borderColor,g.strokeWidth=d.borderWidth,g.centerX=p.x,g.centerY=p.y,g.radius=.5*d.size,g.class="e-diagram-userhandle-circle",g.angle=0,g.visible=d.visible,g.opacity=1,this.svgRenderer.drawCircle(e,g,1,{"aria-label":d.name+"user handle"});var y=[];y=gI(y=Cd(f));var S=nf(f),w=fI(y,(d.size-.45*d.size)/S.width,(d.size-.45*d.size)/S.height,!0,S.x,S.y,0,0);S=nf(w),this.svgRenderer.drawPath(e,C={x:p.x-S.width/2,y:p.y-S.height/2,angle:0,id:"",class:"e-diagram-userhandle-path",fill:d.pathColor,stroke:d.backgroundColor,strokeWidth:.5,dashArray:"",data:w,width:d.size-5,height:d.size-5,pivotX:0,pivotY:0,opacity:1,visible:d.visible},this.diagramId,void 0,void 0,{"aria-label":d.name+"user handle"})}else if(d.content){var D=new Cn(d.name,this.diagramId);D.content=d.content,D.offsetX=p.x,D.offsetY=p.y,D.id=d.name+"_shape",D.horizontalAlignment="Center",D.verticalAlignment="Center",D.visible=d.visible,D.setOffsetWithRespectToBounds(p.x,p.y,"Fraction"),D.relativeMode="Object",D.description=d.name||"User handle",D.measure(new me(d.size,d.size)),D.arrange(D.desiredSize),this.svgRenderer.drawNativeContent(D,e,d.size,d.size,this.adornerSvgLayer)}else if(d.source){var C,A=new SI;(C=this.getBaseAttributes(A,i)).width=d.size,C.height=d.size,C.x=p.x-d.size/2,C.y=p.y-d.size/2,C.sourceWidth=d.size,C.sourceHeight=d.size,C.alignment=A.imageAlign,C.source=d.source,C.scale=A.imageScale,C.visible=d.visible,C.description=d.name||"User handle",C.id=d.name+"_",this.renderer.drawImage(e,C,this.adornerSvgLayer,!1)}else{var x=new Jn(d.name,this.diagramId);x.offsetX=p.x,x.offsetY=p.y,x.id=d.name+"_shape",x.visible=d.visible,x.relativeMode="Object",x.template=d.template,x.measure(new me(d.size,d.size)),x.arrange(x.desiredSize),this.svgRenderer.drawHTMLContent(x,r,void 0,!0,void 0)}}},n.prototype.renderRotateThumb=function(t,e,i,r,s){new Ke;var a,l=new me;l.width=18,l.height=16;var d=!!(r&mr.Rotate);s&&(d=!1);var p=t.offsetX-t.actualSize.width*t.pivot.x+t.pivot.x*t.actualSize.width,f=t.offsetY-t.actualSize.height*t.pivot.y;if(a={x:(p=(p+i.tx)*i.scale)-.5*l.width,y:(f=(f+i.ty)*i.scale)-30-.5*l.height},0!==t.rotateAngle||0!==t.parentTransform){var g=Hi();qi(g,t.rotateAngle+t.parentTransform,(i.tx+t.offsetX)*i.scale,(i.ty+t.offsetY)*i.scale),a=Je(g,a)}this.svgRenderer.drawPath(e,{x:a.x,y:a.y,angle:t.rotateAngle+t.parentTransform,fill:"#231f20",stroke:"black",strokeWidth:.5,dashArray:"",data:"M 16.856144362449648 10.238890446662904 L 18.000144362449646 3.437890446662903L 15.811144362449646 4.254890446662903 C 14.837144362449646 2.5608904466629028 13.329144362449647 1.2598904466629026 11.485144362449645 0.5588904466629026 C 9.375144362449646 - 0.24510955333709716 7.071144362449646 - 0.18010955333709716 5.010144362449646 0.7438904466629028 C 2.942144362449646 1.6678904466629028 1.365144362449646 3.341890446662903 0.558144362449646 5.452890446662903 C - 0.244855637550354 7.567890446662903 - 0.17985563755035394 9.866890446662904 0.7431443624496461 11.930890446662904 C 1.6681443624496461 13.994890446662904 3.343144362449646 15.575890446662903 5.457144362449647 16.380890446662903 C 6.426144362449647 16.7518904466629 7.450144362449647 16.9348904466629 8.470144362449647 16.9348904466629 C 9.815144362449647 16.9348904466629 11.155144362449647 16.6178904466629 12.367144362449647 15.986890446662901 L 11.351144362449647 14.024890446662901 C 9.767144362449647 14.8468904466629 7.906144362449647 14.953890446662902 6.237144362449647 14.3178904466629 C 4.677144362449647 13.7218904466629 3.444144362449647 12.5558904466629 2.758144362449647 11.028890446662901 C 2.078144362449646 9.501890446662903 2.031144362449646 7.802890446662903 2.622144362449646 6.243890446662903 C 3.216144362449646 4.6798904466629025 4.387144362449646 3.442890446662903 5.914144362449646 2.760890446662903 C 7.437144362449646 2.078890446662903 9.137144362449646 2.0298904466629026 10.700144362449645 2.6258904466629027 C 11.946144362449646 3.100890446662903 12.971144362449646 3.9538904466629026 13.686144362449646 5.049890446662903 L 11.540144362449645 5.850890446662903 L 16.856144362449648 10.238890446662904 Z",width:20,height:20,pivotX:0,pivotY:0,opacity:1,visible:d,id:"rotateThumb",class:"e-diagram-rotate-handle"},this.diagramId,!0,void 0,{"aria-label":"Thumb to rotate the selected object"})},n.prototype.renderPathElement=function(t,e,i,r,s,o,a){var l=this.getBaseAttributes(t,i,o);if(l.data=t.absolutePath,l.data=t.absolutePath,t.isPathPort&&a){l.x=a[t.id]?a[t.id].cx:l.x,l.y=a[t.id]?a[t.id].cy:l.y,t.bounds.x=l.x,t.bounds.y=l.y;var h=document.getElementById(this.diagramId);h&&"PortDrag"!==h.ej2_instances[0].eventHandler.currentAction&&(t.offsetX=l.x+t.width/2,t.offsetY=l.y+t.height/2)}var u=t.description?t.description:t.id;if(this.isSvgMode||(l.x=t.flipOffset.x?t.flipOffset.x:l.x,l.y=t.flipOffset.y?t.flipOffset.y:l.y),t.isExport){var p=t.absoluteBounds,f=Cd(l.data),g=this.findAndStoreArcValues(f);l.arc=g,l.data=OF(t,p,0,l)}this.renderer.drawPath(e,l,this.diagramId,void 0,r,u)},n.prototype.findAndStoreArcValues=function(t){var e=[];return t.forEach(function(i){"A"===i.command&&e.push({r1:i.r1/2,r2:i.r2/2})}),e},n.prototype.renderSvgGridlines=function(t,e,i,r,s,o){var a=document.createElementNS("http://www.w3.org/2000/svg","pattern"),l=document.createElementNS("http://www.w3.org/2000/svg","defs");l.setAttribute("id",this.diagramId+"_grid_pattern_defn"),(t.constraints&ei.ShowHorizontalLines||t.constraints&ei.ShowVerticalLines)&&a.setAttribute("id",this.diagramId+"_pattern");var h=0,c=0,d=0,u=0,p=1,f=!1,g="Lines"===t.gridType,v=g?t.verticalGridlines.lineIntervals:t.verticalGridlines.dotIntervals,y=g?t.horizontalGridlines.lineIntervals:t.horizontalGridlines.dotIntervals;if(r.showRulers&&r.dynamicGrid&&s&&o)d=o.updateSegmentWidth(i.scale),u=s.updateSegmentWidth(i.scale),t.horizontalGridlines.scaledIntervals=[d/s.interval],t.verticalGridlines.scaledIntervals=[u/o.interval],f=!0;else{for(var S=0;S=2)for(;e>=2;)e/=2;else if(e<=.5)for(;e<=.5;)e*=2;var i;if(t.horizontalGridlines.scaledIntervals=t.horizontalGridlines.snapIntervals,t.verticalGridlines.scaledIntervals=t.verticalGridlines.snapIntervals,1!==e){var r=t.horizontalGridlines;for(r.scaledIntervals=[],i=0;ithis.groupElement.actualSize.height&&("Clip"===t.style.textOverflow||"Ellipsis"===t.style.textOverflow)&&(a.y=a.y+(a.height-this.groupElement.actualSize.height)/2),this.renderer.drawRectangle(e,a,this.diagramId,void 0,void 0,r),this.renderer.drawText(e,a,r,l,this.diagramId,t.isExport&&Math.min(t.exportScaleValue.x||t.exportScaleValue.y),this.groupElement),this.isSvgMode&&(t.doWrap=!1)},n.prototype.renderNativeElement=function(t,e,i,r,s){var o,a,l=this.getParentSvg(t,void 0,e)||r,h=this.getParentElement(t,e,l).g||e,c=this.getBaseAttributes(t,i);switch(c.fill="transparent",c.cornerRadius=t.cornerRadius,c.stroke="transparent",this.renderer.drawRectangle(e,c,this.diagramId,void 0,void 0,r),t.scale){case"None":o=t.contentSize.width,a=t.contentSize.height;break;case"Stretch":o=t.actualSize.width,a=t.actualSize.height;break;case"Meet":o=a=t.actualSize.width<=t.actualSize.height?t.actualSize.width:t.actualSize.height;break;case"Slice":o=a=t.actualSize.width>=t.actualSize.height?t.actualSize.width:t.actualSize.height}this.svgRenderer&&this.svgRenderer.drawNativeContent(t,h,a,o,l)},n.prototype.renderHTMLElement=function(t,e,i,r,s,o,a){var l=this.getBaseAttributes(t,r);l.fill="transparent",l.cornerRadius=t.cornerRadius,l.stroke="transparent",this.renderer.drawRectangle(e,l,this.diagramId,void 0,void 0,s),this.svgRenderer&&this.svgRenderer.drawHTMLContent(t,i.children[0],r,function lse(n){var t=n.parentElement;do{if(dm(t,"e-diagram"))return!0;t=t.parentElement}while(t);return!1}(i),a)},n.prototype.renderImageElement=function(t,e,i,r,s){var o=this.getBaseAttributes(t,i);o.cornerRadius=0,this.renderer.drawRectangle(e,o,this.diagramId,void 0,void 0,r);var a,l,h,c,g,d=t.contentSize.width,u=t.contentSize.height,p=o.width/d,f=o.height/u;if("Stretch"===t.stretch)a=d*(g=Math.min(p,f)),l=u*g;else switch(t.stretch){case"Meet":a=d*(g=Math.min(p,f)),l=u*g,o.x+=Math.abs(o.width-a)/2,o.y+=Math.abs(o.height-l)/2;break;case"Slice":g=Math.max(p,f),h=o.width/(a=d*g)*d,c=o.height/(l=u*g)*u;break;case"None":a=d,l=u}o.width=a,o.height=l,o.sourceWidth=h,o.sourceHeight=c,o.source=t.source,o.alignment=t.imageAlign,o.scale=t.imageScale,o.description=t.description?t.description:t.id,this.renderer.drawImage(e,o,r,s)},n.prototype.renderContainer=function(t,e,i,r,s,o,a,l,h,c,d){var g,u={svg:s,g:e},p=document.getElementById(this.diagramId);if(p&&(g=p.ej2_instances[0]),this.diagramId&&(s=this.getParentSvg(t)||s,this.isSvgMode)){var v=this.getParentElement(t,e,s,l).g||e;s=this.getParentSvg(this.hasNativeParent(t.children))||s;var y=this.getParentElement(this.hasNativeParent(t.children),v,s,l);u.svg=y.svg||s,u.g=y.g||v,o&&s&&(s.getElementById(u.g.id)||e.appendChild(u.g)),e=u.g}if(this.renderRect(t,e,r,s),this.groupElement=t,t.hasChildren()){for(var b,S=void 0,M=0,w=t.children;M0&&(D=g.selectedItems.nodes[0]);var L,A=void 0,x=void 0,R=!1;if(g&&g.selectedItems&&(L=g.getObject(t.id)),"None"!==t.flip&&(D=L),"None"===t.flip&&(D=L),D&&D.flipMode&&(R=!0),!(t.elementActions&Xr.ElementIsGroup)&&g instanceof zl&&g.nameTable[t.id]&&"connectors"!==g.nameTable[t.id].propName&&R&&D){if(A=t.children&&t.children[0]instanceof Cn?document.getElementById(D.id+"_content_inner_native_element"):document.getElementById(D.id+"_content_groupElement"),!(t.children[0]instanceof Cn)&&"Text"!==D.shape.type&&"None"!==D.flipMode&&"Label"!==D.flipMode&&"All"!==D.flipMode&&"PortAndLabel"!==D.flipMode&&"LabelText"!==D.flipMode&&"PortAndLabelText"!==D.flipMode&&"LabelAndLabelText"!==D.flipMode||t.children[0]instanceof Cn&&"Port"===D.flipMode)return void this.renderFlipElement(t,A,D.flip);if((t.children[0]instanceof Cn&&("All"===D.flipMode||"Label"===D.flipMode)||"Label"===D.flipMode||"PortAndLabel"===D.flipMode||"LabelText"===D.flipMode||"PortAndLabelText"===D.flipMode||"LabelAndLabelText"===D.flipMode||"Image"===D.shape.type&&"Label"===D.flipMode)&&this.renderFlipElement(t,A,t.flip),"None"!==t.flip&&"None"===D.flipMode)this.renderFlipElement(t,A,t.flip);else if("None"!==t.flip&&("Label"===D.flipMode||"PortAndLabel"===D.flipMode||"LabelText"===D.flipMode||"PortAndLabelText"===D.flipMode||"LabelAndLabelText"===D.flipMode)||t.children[0]instanceof Cn&&"None"!==t.flip&&D&&("None"===D.flipMode||"All"===D.flipMode)){for(var O=0;O0){var i=t[0];if(i instanceof Cn)return i;i.children&&i.children.length&&this.hasNativeParent(i.children,e++||0)}},n.prototype.renderRect=function(t,e,i,r,s){var o=this.getBaseAttributes(t,i,s);o.cornerRadius=t.cornerRadius||0,t.isExport&&(o.cornerRadius*=t.exportScaleValue.x),this.renderer.drawRectangle(e,o,this.diagramId,t.isExport,void 0,r,t.description?t.description:t.id)},n.prototype.drawRect=function(t,e){e.cornerRadius=0,this.svgRenderer.drawRectangle(t,e,this.diagramId)},n.prototype.getBaseAttributes=function(t,e,i){var r={width:t.actualSize.width,height:t.actualSize.height,x:t.offsetX-t.actualSize.width*t.pivot.x,y:t.offsetY-t.actualSize.height*t.pivot.y,fill:t.style.fill,stroke:t.style.strokeColor,angle:t.rotateAngle+t.parentTransform,pivotX:t.pivot.x,pivotY:t.pivot.y,strokeWidth:t.style.strokeWidth,dashArray:t.style.strokeDashArray||"",opacity:t.style.opacity,shadow:t.shadow,gradient:t.style.gradient,visible:t.visible,id:t.id,description:t.description,canApplyStyle:t.canApplyStyle,shapeType:t.shapeType};return"Page"===t.rotationReference&&(r.angle=t.rotateAngle),i&&(r.x=r.x-.5,r.y=r.y-.5),t.isExport&&(r.width*=t.exportScaleValue.x,r.height*=t.exportScaleValue.y,r.x*=t.exportScaleValue.x,r.y*=t.exportScaleValue.y,r.strokeWidth*=t.exportScaleValue.x),t.flip&&(r.flip=t.flip),e&&(r.x+=e.tx,r.y+=e.ty),r},n.renderSvgBackGroundImage=function(t,e,i,r,s,o){if(t.source){var l=mT(e.id).getElementById(e.id+"_image");if(!l){var h=function moe(n){return xt(n).getElementsByClassName("e-background-image-layer")[0]}(e.id);(l=document.createElementNS("http://www.w3.org/2000/svg","image")).setAttribute("id",e.id+"_image"),h.appendChild(l)}var c=new Image;c.src=t.source,l.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",c.src.toString());var d="None"!==t.scale?t.scale:"",u=t.align,p=u.charAt(0).toLowerCase()+u.slice(1);d&&(p+=" "+d.charAt(0).toLowerCase()+d.slice(1)),ai(l,{id:e.id+"_image",x:i,y:r,width:s,height:o,preserveAspectRatio:p})}},n.prototype.transformLayers=function(t,e){var i=t.tx*t.scale,r=t.ty*t.scale,s="domTable";if(i!==this.transform.x||r!==this.transform.y||0===i||0===r){e&&(window[""+s][this.diagramId+"_diagramLayer"]||(window[""+s][this.diagramId+"_diagramLayer"]=this.diagramSvgLayer.getElementById(this.diagramId+"_diagramLayer")),window[""+s][this.diagramId+"_diagramLayer"].setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+"),scale("+t.scale+")"));var a=function yoe(n){var t="domTable",e=null;return window[t][n+"_gridline"]?e=window[t][n+"_gridline"]:(e=Bd(n).getElementById(n+"_gridline"),window[t][n+"_gridline"]=e),e}(this.diagramId);return a.setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+")"),window[""+s][this.diagramId+"_diagramPorts"]||(window[""+s][this.diagramId+"_diagramPorts"]=this.iconSvgLayer.getElementById(this.diagramId+"_diagramPorts")),window[""+s][this.diagramId+"_diagramPorts"].setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+"),scale("+t.scale+")"),window[""+s][this.diagramId+"_diagramExpander"]||(window[""+s][this.diagramId+"_diagramExpander"]=this.iconSvgLayer.getElementById(this.diagramId+"_diagramExpander")),window[""+s][this.diagramId+"_diagramExpander"].setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+"),scale("+t.scale+")"),window[""+s][this.diagramId+"_nativeLayer"]||(window[""+s][this.diagramId+"_nativeLayer"]=this.nativeSvgLayer.getElementById(this.diagramId+"_nativeLayer")),window[""+s][this.diagramId+"_nativeLayer"].setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+"),scale("+t.scale+")"),Io(this.diagramId).children[0].style.transform="translate("+t.tx*t.scale+"px,"+t.ty*t.scale+"px)scale("+t.scale+")",this.transform={x:t.tx*t.scale,y:t.ty*t.scale},!0}return!1},n.prototype.updateNode=function(t,e,i,r,s,o,a){this.renderElement(t,e,i,r,this.getParentSvg(t),void 0,void 0,s,null,o,a)},n}(),tse=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),$I=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},oF=function(n){function t(e,i){var r=n.call(this,e,i)||this;return r.mode="Canvas",r.id="overview",r.actionName="",r.startPoint=null,r.currentPoint=null,r.prevPoint=null,r.scale=null,r.inAction=!1,r.viewPortRatio=1,r.horizontalOffset=0,r.verticalOffset=0,r.model={},r.event=!0,r.overviewid=88123,r.model={width:r.width,height:r.height},r}return tse(t,n),t.prototype.onPropertyChanged=function(e,i){for(var r=0,s=Object.keys(e);r0||e.toString().indexOf("%")>0?e.toString():e.toString()+"px"},t.prototype.renderCanvas=function(e){var i=document.getElementById(this.element.id+"_canvas");i||(i=Tt("div",{}),this.element.appendChild(i)),Ho(i,{id:this.element.id+"_canvas",class:"drawing",style:"position:relative; height:"+this.getSizeValue(this.model.height)+"; width:"+this.getSizeValue(this.model.width)+";style:-ms-touch-action: none;touch-action: none;"}),this.element.setAttribute("tabindex",String(-1)),this.element.style.overflow="hidden",this.element.style.height=String(this.model.height),this.element.style.width=String(this.model.width),this.canvas=i},t.prototype.setParent=function(e){var i=document.getElementById(e);if(this.parent){var s=this.parent;this.parent=null,s.setOverview(null,this.element.id),this.removeDocument(this)}this.parent=this.getDiagram(i,"ej2_instances"),this.parent&&this.parent.setOverview(this)},t.prototype.getDiagram=function(e,i){for(var r,s=e[""+i].length,o=0;o0?p:Math.floor(window.innerWidth)}if(0===h){var f=Math.floor(window.innerHeight-u-Math.floor(c.top));h=f>0?f:Math.floor(window.innerHeight)}l>0&&(s.setAttribute("width",String(l)),this.model.height=h),h>0&&(s.setAttribute("height",String(h)),this.model.width=l),e.diagramLayerDiv||(e.diagramLayerDiv=Tt("div",{}),e.diagramLayer=bo.createCanvas(this.element.id+"_diagramLayer",this.model.width,this.model.height),e.diagramLayer.setAttribute("style","position:absolute; left:0px; top:0px "),e.diagramLayerDiv.appendChild(e.diagramLayer),e.canvas.appendChild(e.diagramLayerDiv)),Ho(e.diagramLayerDiv,{id:this.element.id+"_diagramLayer_div",style:"width:"+this.model.width+"px; height:"+this.model.height+"px;position:absolute;top:0px;left:0px"}),this.renderHtmlLayer(e.canvas),this.renderNativeLayer(e.canvas,e),this.addOverviewRectPanel(e)},t.prototype.removeDocument=function(e){var i=document.getElementById(this.canvas.id+"_svg");this.canvas.removeChild(i);var r=document.getElementById(this.element.id+"_htmlLayer");this.canvas.removeChild(r);var s=document.getElementById(this.element.id+"_diagramLayer_div");this.canvas.removeChild(s),e.diagramLayerDiv=null,e.diagramLayer=null,window.domTable[this.id+"html_layer"]=null},t.prototype.renderHtmlLayer=function(e){var i=Tt("div",{id:this.element.id+"_htmlLayer",class:"e-html-layer",style:"pointer-events:none;position:absolute;top:0px;left:0px;"}),s=Tt("div",{id:this.element.id+"_htmlLayer_div",style:"position:absolute;top:0px;left:0px;"});return i.appendChild(s),e.appendChild(i),i},t.prototype.renderNativeLayer=function(e,i){if(!document.getElementById(this.element.id+"_nativeLayer_svg")){var r=this.parent.createSvg(this.element.id+"_nativeLayer_svg",this.model.width,this.model.height),s=Bi("g",{id:this.element.id+"_nativeLayer"});r.appendChild(s),i.diagramLayerDiv.appendChild(r),ai(r,{class:"e-native-layer"})}},t.prototype.addOverviewRectPanel=function(e){var i=document.getElementById(this.canvas.id+"_overviewsvg");i&&i.parentNode.removeChild(i),i=Bi("svg",{id:this.canvas.id+"_overviewsvg",class:"overviewsvg",version:"1.1",style:"position:absolute;left:0px;top:0px; aria-label:Specifies overview",width:this.model.width,height:this.model.height}),e.canvas.appendChild(i);var s=Bi("g",{id:this.element.id+"_overviewlayer",style:"pointer-events:none"});i.appendChild(s);var o=Bi("rect",{fill:"transparent",width:"100%",height:"100%",class:"overviewbackrect",id:this.canvas.id+"overviewbackrect"});o.setAttribute("style"," pointer-events: none; "),s.appendChild(o);var a=Bi("g",{id:this.canvas.id+"overviewhandle",style:"pointer-events:all"});s.appendChild(a);var l=Bi("rect",{id:this.canvas.id+"overviewrect",fill:"transparent"});a.appendChild(l),this.renderOverviewCorner("left",a),this.renderOverviewCorner("right",a),this.renderOverviewCorner("top",a),this.renderOverviewCorner("bottom",a),this.renderOverviewCorner("topleft",a),this.renderOverviewCorner("topright",a),this.renderOverviewCorner("bottomleft",a),this.renderOverviewCorner("bottomright",a)},t.prototype.renderOverviewCorner=function(e,i){var s,o=Bi(s="top"===e||"bottom"===e||"right"===e||"left"===e?"rect":"circle",{id:this.canvas.id+"visible"+e,class:"overview-resizer"});i.appendChild(o);var a=Bi(s,{id:this.canvas.id+e,class:"overviewresizer",fill:"transparent"});i.appendChild(a)},t.prototype.updateOverviewRectangle=function(){var e=this.currentPoint.x-this.prevPoint.x,i=this.currentPoint.y-this.prevPoint.y,r=new me;r.width=0,r.height=0;var s=0,o=0;switch(this.resizeDirection){case"left":r.width-=e,r.height-=e/this.viewPortRatio,s=e,o=e/this.viewPortRatio,o/=2;break;case"right":r.width+=e,r.height+=e/this.viewPortRatio,o=e/this.viewPortRatio,o/=-2;break;case"top":r.height-=i,r.width-=i*this.viewPortRatio,o=i,s=i*this.viewPortRatio,s/=2;break;case"bottom":r.height+=i,r.width+=i*this.viewPortRatio,s=i*this.viewPortRatio,s/=-2;break;case"topleft":Math.abs(i)>Math.abs(e)?e=i*this.viewPortRatio:i=e/this.viewPortRatio,r.width-=e,r.height-=i,s=e,o=i;break;case"topright":Math.abs(i)>Math.abs(e)?e=-i*this.viewPortRatio:i=-e/this.viewPortRatio,o=i,r.width+=e,r.height-=i;break;case"bottomleft":Math.abs(i)>Math.abs(e)?e=-i*this.viewPortRatio:i=-e/this.viewPortRatio,s=e,r.width-=e,r.height+=i;break;case"bottomright":Math.abs(i)>Math.abs(e)?e=i*this.viewPortRatio:i=e/this.viewPortRatio,r.width+=e,r.height+=i}this.updateHelper(s,o,r,void 0,void 0)},t.prototype.updateHelper=function(e,i,r,s,o){var a,l,h,u,p,d=this.element.getElementsByTagName("svg")[2].getElementById("helper");r?(a=(h=d.getBBox()).x+e,l=h.y+i,s=h.width+r.width,o=h.height+r.height):(u=this.currentPoint.x>this.startPoint.x?this.currentPoint.x-this.prevPoint.x:this.prevPoint.x-this.currentPoint.x,p=this.currentPoint.y>this.startPoint.y?this.currentPoint.y-this.prevPoint.y:this.prevPoint.y-this.currentPoint.y,Math.abs(p)>Math.abs(u)?u=this.viewPortRatio*p:p=u/this.viewPortRatio,h=d.getBBox(),a=this.startPoint.x>this.currentPoint.x?h.x-u:h.x,l=this.startPoint.y>this.currentPoint.y?h.y-p:h.y,s=h.width+u,o=h.height+p),ai(this.helper,{id:this.helper.id,x:a,y:l,width:Math.max(0,s),height:Math.max(0,o)})},t.prototype.updateOverviewrect=function(e,i,r,s){Ho(document.getElementById(this.canvas.id+"overviewrect"),{x:e,y:i,width:Math.max(1,r),height:Math.max(1,s)}),this.updateOverviewCorner("top",e+8,i+1,Math.max(0,r-16),2),this.updateOverviewCorner("bottom",e+8,i+s+3,Math.max(0,r-16),2),this.updateOverviewCorner("left",e-2,i+11,2,Math.max(0,s-16)),this.updateOverviewCorner("right",e+r,i+11,2,Math.max(0,s-16)),this.updateOverviewCorner("topleft",e,i+3,5,5),this.updateOverviewCorner("topright",e+r,i+3,5,5),this.updateOverviewCorner("bottomleft",e,i+s+3,5,5),this.updateOverviewCorner("bottomright",e+r,i+s+3,5,5)},t.prototype.updateOverviewCorner=function(e,i,r,s,o){var a,l;"top"===e||"bottom"===e||"right"===e||"left"===e?(a={x:i,y:r,width:s,height:o,fill:"#ED1C24"},l={x:i-2,y:r-2,width:2===s?4:s,height:2===o?4:o}):(a={cx:i,cy:r,r:4,fill:"#ED1C24"},l={cx:i,cy:r,r:6,fill:"transparent"}),Ho(document.getElementById(this.canvas.id+"visible"+e),a),Ho(document.getElementById(this.canvas.id+e),l)},t.prototype.translateOverviewRectangle=function(){Number(this.model.width),Number(this.model.height);var r=this.currentPoint.x-this.prevPoint.x,s=this.currentPoint.y-this.prevPoint.y,l=this.element.getElementsByClassName("overviewsvg")[0].getElementById(this.canvas.id+"overviewrect").getBBox(),h=l.x+r,c=l.y+s,d=l.width,u=l.height;this.updateOverviewrect(h,c,d,u),this.updateParentView(this.parent.scroller.currentZoom,h,c,d,u,null)},t.prototype.renderOverviewRect=function(e,i,r,s){var o=Number(this.model.width),a=Number(this.model.height),c=Math.max(this.parent.scroller.viewPortWidth/(r/o*this.contentWidth),this.parent.scroller.viewPortHeight/(s/a*this.contentHeight));if(c>=.25&&c<=30){this.updateParentView(c,e,i,r,s,{x:0,y:0});var u=this.scrollOverviewRect(this.parent.scroller.horizontalOffset,this.parent.scroller.verticalOffset,this.parent.scroller.currentZoom,!0);if(this.helper){var f=this.element.getElementsByTagName("rect")[10].getBBox();u.x=f.x,u.y=f.y}"pan"===this.actionName?this.updateOverviewrect(-u.x,-u.y,u.width,u.height):this.updateOverviewrect(u.x,u.y,u.width,u.height)}},t.prototype.scrollOverviewRect=function(e,i,r,s){if(!this.actionName||s){var o=Number(this.model.width),a=Number(this.model.height),l=Math.min(this.contentWidth/o,this.contentHeight/a),h=new Ne,c=h.x=e/r/l,d=h.y=i/r/l,u=0;this.parent.rulerSettings.showRulers&&(u=25);var p=document.getElementById(this.parent.element.id+"content"),f=0,g=0;p&&(f=p.offsetWidth-p.clientWidth,g=p.offsetHeight-p.clientHeight);var v=h.width=(this.parent.scroller.viewPortWidth-u-f)/r/l,y=h.height=(this.parent.scroller.viewPortHeight-u-g)/r/l;if(s){var S=new Ne;return S.x=c,S.y=d,S.width=v,S.height=y,S}this.updateOverviewrect(-c,-d,v,y)}return null},t.prototype.updateParentView=function(e,i,r,s,o,a){var f,g,l=Number(this.model.width),h=Number(this.model.height),u=i*(this.contentWidth/l)*e,p=r*(this.contentHeight/h)*e;this.parent.scroller.getPageBounds(),(1!==e||"pan"===this.actionName)&&(f=-u-this.parent.scroller.horizontalOffset,g=-p-this.parent.scroller.verticalOffset),this.parent.setBlazorDiagramProps(!0),this.parent.realActions|=$i.OverViewAction,"scale"===this.actionName||"draw"===this.actionName?this.parent.scroller.zoom(e/this.parent.scroller.currentZoom,f,g,a):ce()?this.parent.scroller.zoom(1,f,g,a):this.parent.pan(f,g,a,!0)},t.prototype.updateHtmlLayer=function(e){var i=Io(e.element.id),r=this.parent.scroller.getPageBounds(!0),o=r.height,a=Math.max(r.width,this.parent.scroller.viewPortWidth),l=Math.max(o,this.parent.scroller.viewPortHeight/this.parent.scroller.currentZoom),h=Math.min(Number(this.model.width)/a,Number(this.model.height)/l);i.style.transform="scale("+h+") translate("+this.parent.scroller.transform.tx+"px,"+this.parent.scroller.transform.ty+"px)"},t.prototype.updateView=function(e){var i=this.parent.scroller.getPageBounds(),r=i.width,s=i.height,o=Number(this.model.width),a=Number(this.model.height),l=Math.max(r,this.parent.scroller.viewPortWidth),h=Math.max(s,this.parent.scroller.viewPortHeight);this.contentWidth=l=Math.max(l,o/a*h),this.contentHeight=h=Math.max(h,a/o*l);var c=Math.min(o/l,a/h),d=document.getElementById(this.element.id+"_htmlLayer");d.style.webkitTransform="scale("+c+") translate("+-i.x+"px,"+-i.y+"px)",d.style.transform="scale("+c+") translate("+-i.x+"px,"+-i.y+"px)",document.getElementById(this.element.id+"_overviewlayer").setAttribute("transform","translate("+-i.x*c+","+-i.y*c+")"),this.horizontalOffset=i.x*c,this.verticalOffset=i.y*c;var p=document.getElementById(this.element.id+"_diagramLayer"),f=zF(this.element.id),g=p.getContext("2d"),v=Number(this.model.width)/this.contentWidth,y=Number(this.model.height)/this.contentHeight;v=Math.min(v,y);var S=this.parent.scroller.transform;f.setAttribute("transform","translate("+S.tx*v+","+S.ty*y+"),scale("+v+")"),g.setTransform(v,0,0,v,0,0),g.fillStyle="red",this.scrollOverviewRect(this.parent.scroller.horizontalOffset,this.parent.scroller.verticalOffset,this.parent.scroller.currentZoom)},t.prototype.scrolled=function(e){if(this.event){var i=this.scrollOverviewRect(this.parent.scroller.horizontalOffset,this.parent.scroller.verticalOffset,this.parent.scroller.currentZoom,!0);this.updateOverviewrect(-i.x,-i.y,i.width,i.height),this.updateView(this)}},t.prototype.updateCursor=function(e){if(dm(e.target,"overviewresizer"))switch(e.target.id){case this.canvas.id+"left":this.canvas.style.cursor="w-resize";break;case this.canvas.id+"right":this.canvas.style.cursor="e-resize";break;case this.canvas.id+"top":this.canvas.style.cursor="n-resize";break;case this.canvas.id+"bottom":this.canvas.style.cursor="s-resize";break;case this.canvas.id+"topleft":this.canvas.style.cursor="nw-resize";break;case this.canvas.id+"topright":this.canvas.style.cursor="ne-resize";break;case this.canvas.id+"bottomleft":this.canvas.style.cursor="sw-resize";break;case this.canvas.id+"bottomright":this.canvas.style.cursor="se-resize"}else this.canvas.style.cursor="default"},t.prototype.mouseMove=function(e){if(this.event=!1,this.updateCursor(e),this.currentPoint=this.mousePosition(e),this.actionName)switch(this.actionName){case"draw":!this.inAction&&(this.startPoint.x!==this.currentPoint.x||this.startPoint.y!==this.currentPoint.y)&&(this.initHelper(),this.inAction=!0),this.inAction&&this.updateHelper();break;case"scale":this.inAction||(this.initHelper(),this.inAction=!0),this.updateOverviewRectangle();break;case"pan":(this.startPoint.x!==this.currentPoint.x||this.startPoint.y===this.currentPoint.y||this.inAction)&&(this.inAction=!0,this.translateOverviewRectangle())}this.prevPoint=this.currentPoint},t.prototype.documentMouseUp=function(e){this.inAction=!1,this.actionName="",this.helper&&(this.helper.parentNode.removeChild(this.helper),this.helper=null),this.event=!0,document.getElementById(this.canvas.id+"overviewhandle").style.pointerEvents="all"},t.prototype.windowResize=function(e){var i=this;return this.resizeTo&&clearTimeout(this.resizeTo),this.resizeTo=setTimeout(function(){var s=document.getElementById(i.element.id).getBoundingClientRect();i.model.width=s.width>0?s.width:i.model.width,i.model.height=s.height>0?s.height:i.model.height,i.renderCanvas(),i.setParent(i.sourceID)},10),!1},t.prototype.mouseDown=function(e){if(e.target.id===this.canvas.id+"_overviewsvg"&&(this.actionName="draw"),e.target.id===this.canvas.id+"overviewrect"&&(this.actionName="pan"),dm(e.target,"overviewresizer"))switch(this.actionName="scale",e.target.id){case this.canvas.id+"left":this.resizeDirection="left";break;case this.canvas.id+"right":this.resizeDirection="right";break;case this.canvas.id+"top":this.resizeDirection="top";break;case this.canvas.id+"bottom":this.resizeDirection="bottom";break;case this.canvas.id+"topleft":this.resizeDirection="topleft";break;case this.canvas.id+"topright":this.resizeDirection="topright";break;case this.canvas.id+"bottomleft":this.resizeDirection="bottomleft";break;case this.canvas.id+"bottomright":this.resizeDirection="bottomright"}this.startPoint=this.prevPoint=this.mousePosition(e),this.viewPortRatio=this.parent.scroller.viewPortWidth/this.parent.scroller.viewPortHeight,document.getElementById(this.canvas.id+"overviewhandle").style.pointerEvents="none"},t.prototype.mouseUp=function(e){if(this.currentPoint=this.mousePosition(e),this.actionName)if(this.startPoint.x!==this.currentPoint.x||this.startPoint.y!==this.currentPoint.y){if("pan"!==this.actionName&&this.helper){var i=this.element.getElementsByTagName("rect")[10].getBBox();this.resizeDirection=this.resizeDirection||"",this.renderOverviewRect(i.x,i.y,o=i.width,a=i.height)}}else if(e.target.id===this.canvas.id+"_overviewsvg"||"helper"===e.target.id){var o=(i=this.element.getElementsByTagName("svg")[2].getElementById(this.canvas.id+"overviewrect").getBBox()).width,a=i.height;this.inAction=!0,this.actionName="pan",this.renderOverviewRect(this.currentPoint.x-o/2,this.currentPoint.y-a/2,o,a),this.inAction=!1}this.helper&&(this.helper.parentNode.removeChild(this.helper),this.helper=null),this.actionName="",this.startPoint=null,this.currentPoint=null,this.prevPoint=null,this.helper=null,this.viewPortRatio=1,this.resizeDirection="",this.inAction=!1,this.event=!0,document.getElementById(this.canvas.id+"overviewhandle").style.pointerEvents="all"},t.prototype.initHelper=function(){var e=this.element.getElementsByTagName("svg")[2],i=this.startPoint.x,r=this.startPoint.y,s=1,o=1;if("scale"===this.actionName){var l=e.getElementById(this.canvas.id+"overviewrect").getBBox();i=l.x,r=l.y,s=l.width,o=l.height}var h=Bi("rect",{id:"helper",x:i,y:r,width:s,height:o,fill:"transparent",stroke:"gray","stroke-dasharray":"2 2","shape-rendering":"crispEdges"});e.getElementById(this.element.id+"_overviewlayer").appendChild(h),this.helper=h},t.prototype.mousePosition=function(e){var i,r,s;-1!==e.type.indexOf("touch")?(r=(i=e).changedTouches[0].clientX-this.element.offsetLeft,s=i.changedTouches[0].clientY-this.element.offsetTop):(r=e.clientX,s=e.clientY);var l=this.element.getBoundingClientRect();return{x:(r-=l.left)+this.horizontalOffset,y:(s-=l.top)+this.verticalOffset}},t.prototype.destroy=function(){if(this.unWireEvents(),this.notify("destroy",{}),n.prototype.destroy.call(this),document.getElementById(this.element.id)){this.element.classList.remove("e-overview");var e=document.getElementById(this.element.id+"_canvas");e&&this.element.removeChild(e)}this.parent.views.splice(this.parent.views.indexOf(this.element.id),1),this.diagramLayerDiv=null,this.canvas=null,this.parent=null},t.prototype.getModuleName=function(){return"Overview"},$I([I("100%")],t.prototype,"width",void 0),$I([I("100%")],t.prototype,"height",void 0),$I([I("")],t.prototype,"sourceID",void 0),$I([H()],t.prototype,"created",void 0),t}(yi);function rse(n,t){for(var e=0;ez.findLength(e,n)?e:t;var o=z.findAngle(t,e),a=z.findAngle(i,n),l=z.findLength(i,n),h=a+2*(o-a);return{x:i.x+l*Math.cos(h*Math.PI/180),y:i.y+l*Math.sin(h*Math.PI/180)}}function $p(n,t,e){if(n&&n.children&&n.children.length>0)for(var r=void 0,s=0;s0&&"annotations"!==r&&"ports"!==r)if(n[""+l].length>0)for(var h=0;h<=n[""+l].length;h++)Ro(n[""+l],t?t[""+l]:void 0,e[""+l],"annotations"===l||"ports"===l?n:void 0,l);else Ro(n[""+l],t?t[""+l]:void 0,e[""+l],"annotations"===l||"ports"===l?n:void 0,l);else if(s instanceof Object&&t&&"annotations"!==r&&"ports"!==r)Ro(n[""+l],t[""+l],e[""+l]);else if("annotations"!==r&&"ports"!==r&&t&&!t[""+l]||!t&&n&&(n[""+l]||void 0!==n[""+l]))n[""+l]=e[""+l];else{var c=void 0;("annotations"===r||"ports"===r)&&("annotations"===r?(n[""+l]&&Ro(n[""+l],t[""+l],e[""+l]),n[""+l]||(fs(i)===de?(c=new Nr(i,"annotations",e[""+l]),i.annotations.push(c)):(c=new Zn(i,"annotations",e[""+l]),i.annotations.push(c)))):n[""+l]?Ro(n[""+l],t[""+l],e[""+l]):(c=new Es(i,"ports",e[""+l]),i.ports.push(c)))}}}function cse(n,t){for(var e="Bezier"===n.type?function ase(n){var t=[];if("Bezier"===n.type)for(var e=0,i=0;i0||n.ports.length>0){var p=n.wrapper.children;for(i=3;i0)return{enabled:!1,intersectPt:e};var l=o/s,h=a/s;return l>=0&&l<=1&&h>=0&&h<=1?(e.x=i.x1+l*(i.x2-i.x1),e.y=i.y1+l*(i.y2-i.y1),{enabled:!0,intersectPt:e}):{enabled:!1,intersectPt:e}}function JI(n,t,e,i){var a=em(cF(n.x,n.y,t.x,t.y),cF(e.x,e.y,i.x,i.y));return a.enabled?a.intersectPt:{x:0,y:0}}function cF(n,t,e,i){return{x1:Number(n)||0,y1:Number(t)||0,x2:Number(e)||0,y2:Number(i)||0}}function dF(n,t,e){var i=[],s={x:t.topRight.x+(e=e||0),y:t.topRight.y},o={x:t.bottomRight.x,y:t.bottomRight.y-e},a={x:t.bottomLeft.x,y:t.bottomLeft.y+e};return i.push({x:t.topLeft.x-e,y:t.topLeft.y}),i.push(s),i.push(o),i.push(a),i}function zc(n,t,e,i,r,s){var o={},a=e.scroller.transform.scale,h=e.scroller.verticalOffset;return o.x=(i?n.x:t.x)*a+e.scroller.horizontalOffset-r,o.y=(i?n.y:t.y)*a+h-s,o}function uF(n,t){var e=new Ke;return e.data=n.pathData,e.height=n.height>10?n.height-(n.padding.bottom+n.padding.top):n.height,e.width=n.width>10?n.width-(n.padding.left+n.padding.right):n.width,e.visible=n.visibility,e.id=t.id+"_shape",e.inversedAlignment=!1,e.horizontalAlignment="Center",e.verticalAlignment="Center",e.style={fill:n.iconStrokeColor,strokeColor:n.iconStrokeColor,strokeWidth:n.iconStrokeWidth},e.setOffsetWithRespectToBounds(.5,.5,"Fraction"),e.relativeMode="Object",e.description=t.description||"",e}function Xx(n,t,e){var i=qx(n,t),r=z.findAngle(n[i.index],n[i.index+1]),s=function mse(n){var t;t=n instanceof EI?0:void 0===n.content?10:0;var e=0;switch(n.alignment){case"Center":e=0;break;case"Before":e=-(0+t);break;case"After":e=0+t}return e}(t),o=z.transform(i.point,r+45,s);return i.point=o,i.angle=r,i}function qx(n,t){for(var r,s,a,l,e=0,i=t.offset,o=[],h=0;h=c)return s=z.findAngle(n[parseInt(d.toString(),10)],n[d+1]),{point:r=z.transform(n[parseInt(d.toString(),10)],s,c-(a||0)),index:l=d};a=o[parseInt(d.toString(),10)]}return{point:r,index:l}}function pF(n,t,e){t%=360;var a,l,s=225;switch(n.alignment){case"Before":t>=45&&t<=135?(l="right",a=.5===n.offset?"center":"top"):t>=s&&t<=315?(l="left",a=.5===n.offset?"center":"bottom"):t>45&&t=45&&t<=135?(l="left",a=.5===n.offset?"center":"top"):t>=s&&t<=315?(l="right",a=.5===n.offset?"center":"bottom"):t>45&&tMath.abs(t.y-n.y)?n.x0)for(var e=0;e=0;r--)("nodes"===i||"connectors"===i)&&(n[""+i][parseInt(r.toString(),10)].wrapper=null),"dataManager"!==i&&(n[""+i][parseInt(r.toString(),10)]=Jx(n[""+i][parseInt(r.toString(),10)],e[""+i][parseInt(r.toString(),10)],void 0!==t[""+i]?t[""+i][parseInt(r.toString(),10)]:[]),("[]"===JSON.stringify(n[""+i][parseInt(r.toString(),10)])||"{}"===JSON.stringify(n[""+i][parseInt(r.toString(),10)])||void 0===n[""+i][parseInt(r.toString(),10)])&&n[""+i].splice(r,1));n=void 0}function Ph(n,t){var e=t.style,i=t;t.canApplyStyle=!0;for(var r=0,s=Object.keys(n);r=0&&n.splice(e,1)}function Zp(n,t,e){var i;n.intermediatePoints=t,n.updateSegmentElement(n,t,n.wrapper.children[0],e);var r=n.sourceDecorator;if("Bezier"===n.type){var s=n.segments[0],o=n.segments[n.segments.length-1];i=[z.isEmptyPoint(o.point2)?o.bezierPoint2:o.point2,z.isEmptyPoint(s.point1)?s.bezierPoint1:s.point1]}else i=n.intermediatePoints;t=n.clipDecorators(n,t,e);var a=n.wrapper.children[0];a.canMeasurePath=!0,n.updateDecoratorElement(a=n.wrapper.children[1],t[0],i[1],r),n.updateDecoratorElement(a=n.wrapper.children[2],t[t.length-1],i[i.length-2],n.targetDecorator),n.updateShapeElement(n)}function Kx(n,t,e){var l,i=n.wrapper,s=t.offset,o=t.size/e.scale,a=t.margin,h=i.offsetX-i.actualSize.width*i.pivot.x,c=i.offsetY-i.actualSize.height*i.pivot.y;if(l={x:0,y:0},n.nodes.length>0){switch(t.side){case"Top":l.x+=h+s*i.actualSize.width,l.y+=c-o;break;case"Bottom":l.x+=h+s*i.actualSize.width,l.y+=c+i.actualSize.height+o;break;case"Left":l.x+=h-o,l.y+=c+s*i.actualSize.height;break;case"Right":l.x+=h+i.actualSize.width+o,l.y+=c+s*i.actualSize.height}l.x+=(a.left-a.right)/e.scale+o/2*("Center"===t.horizontalAlignment?0:"Right"===t.horizontalAlignment?-1:1),l.y+=(a.top-a.bottom)/e.scale+o/2*("Center"===t.verticalAlignment?0:"Top"===t.verticalAlignment?-1:1)}else if(n.connectors.length>0){var d=n.connectors[0],u={offset:s},p=qx(d.intermediatePoints,u),f=p.index;l=p.point;var y,v=Xx(d.intermediatePoints,u).angle;qi(y=Hi(),-v,d.intermediatePoints[parseInt(f.toString(),10)].x,d.intermediatePoints[parseInt(f.toString(),10)].y),(l=Je(y,l)).x+=a.left-a.right+o/2*("Center"===t.horizontalAlignment?0:"Right"===t.horizontalAlignment?-1:1),l.y+=a.top-a.bottom+o/2*("Center"===t.verticalAlignment?0:"Top"===t.verticalAlignment?-1:1),qi(y=Hi(),v,d.intermediatePoints[parseInt(f.toString(),10)].x,d.intermediatePoints[parseInt(f.toString(),10)].y),l=Je(y,l)}return 0===i.rotateAngle&&0===i.parentTransform||(qi(y=Hi(),i.rotateAngle+i.parentTransform,i.offsetX,i.offsetY),l=Je(y,l)),l}function fa(n,t,e,i){if(i.annotation){if(Ol(i.annotation))return!0}else if(mr[""+t]&n&&bt[""+t]&e)return!0;return!1}function qr(n,t){return!!(mr[""+t]&n)}function Hc(n,t){return!!(bx[""+t]&n)}function ga(n,t){return n.visibility&t}function KI(n,t){var e;if("Text"===n.shape.type)e=n.shape;else{var i=t.split("_");t=i[i.length-1];for(var r=0;rn[""+t]?e.splice(0,0,n):e.push(n);else if(e.length>1){for(var i=0,r=e.length-1,s=Math.floor((i+r)/2);s!==i;)if(e[parseInt(s.toString(),10)][""+t]n[""+t]))break;r=s,s=Math.floor((i+r)/2)}e[parseInt(r.toString(),10)][""+t]n[""+t]?e.splice(i,0,n):e[parseInt(i.toString(),10)][""+t]n[""+t]&&e.splice(r,0,n)}}function zse(n){var t=document.getElementById(n.diagramId),e="ej2_instances",i=t[""+e][0].nodes;void 0===i&&(i=function Rse(n){for(var t=[],e=0;e30?10:o/2;for(var h=0,c=0;c=l){var u=l-h;r=Xt(n[c],n[c+1]),s=z.transform(n[c],r,u);break}h+=d}return s},ib=function(n,t){if(n instanceof te||n instanceof de)for(var e=0;e=0||navigator.platform.indexOf("iPad")>=0||navigator.platform.indexOf("iPhone")>=0||navigator.platform.indexOf("MacIntel")>=0)&&("safari"===X.info.name||"webkit"===X.info.name)}function wF(n,t,e,i){return void 0!==t.previewSize[""+i]?t.previewSize[""+i]:void 0!==n.symbolPreview[""+i]?n.symbolPreview[""+i]:t[""+i]||e.actualSize[""+i]}function sm(n,t,e){return n&&n.parentId&&(e=(n=t.nameTable[n.parentId]).parentId?sm(n,t,e):n.id),e}function om(n,t){return n.selectedItems.connectors.length>1&&0===n.selectedItems.nodes.length&&0!==t.rotateAngle}function _se(n){if(n.arrowType&&""!==n.arrowType.trim())switch(n.arrowType){case"single-line-arrow":default:return{targetDecorator:"Arrow",strokeWidth:1};case"double-line-arrow":return{targetDecorator:"Arrow",strokeWidth:2};case"dotted-arrow":return{targetDecorator:"Arrow",strokeDashArray:"2,2"};case"single-line":return{targetDecorator:"None",strokeWidth:1};case"double-line":return{targetDecorator:"None",strokeWidth:2};case"dotted":return{targetDecorator:"None",strokeDashArray:"2,2"};case"wiggly-arrow":return{targetDecorator:"None",strokeWidth:1,opacity:0}}return{targetDecorator:"Arrow",strokeWidth:1}}var Use=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),io=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},CF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Use(t,n),io([I("None")],t.prototype,"shape",void 0),io([I("white")],t.prototype,"fill",void 0),io([I("Auto")],t.prototype,"horizontalAlignment",void 0),io([I("Auto")],t.prototype,"verticalAlignment",void 0),io([I(10)],t.prototype,"width",void 0),io([I(10)],t.prototype,"height",void 0),io([re({x:.5,y:1},z)],t.prototype,"offset",void 0),io([I("#1a1a1a")],t.prototype,"borderColor",void 0),io([I(1)],t.prototype,"borderWidth",void 0),io([re({},$n)],t.prototype,"margin",void 0),io([I("")],t.prototype,"pathData",void 0),io([I("")],t.prototype,"content",void 0),io([I(0)],t.prototype,"cornerRadius",void 0),io([re({left:2,right:2,top:2,bottom:2},$n)],t.prototype,"padding",void 0),io([I("#1a1a1a")],t.prototype,"iconColor",void 0),t}(Ee),jse=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),rT=function(n){function t(){var e=null!==n&&n.apply(this,arguments)||this;return e.orientation="Vertical",e.measureChildren=void 0,e.considerPadding=!0,e}return jse(t,n),t.prototype.measure=function(e){return this.desiredSize=this.measureStackPanel(e,"Horizontal"===this.orientation?this.updateHorizontalStack:this.updateVerticalStack),this.desiredSize},t.prototype.arrange=function(e){return this.actualSize=this.arrangeStackPanel(e,"Horizontal"===this.orientation?this.arrangeHorizontalStack:this.arrangeVerticalStack),this.updateBounds(),this.actualSize},t.prototype.measureStackPanel=function(e,i){var r=void 0;if(void 0!==this.children&&this.children.length>0)for(var s=0,o=this.children;s0){var r=void 0,s=void 0;r=this.offsetX-e.width*this.pivot.x+this.padding.left,s=this.offsetY-e.height*this.pivot.y+this.padding.top;for(var o=0,a=this.children;o0)for(var i=0,r=this.children;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},$se=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return qse(t,n),zh([I("Horizontal")],t.prototype,"orientation",void 0),zh([I("Center")],t.prototype,"type",void 0),zh([I(void 0)],t.prototype,"offset",void 0),zh([I(!1)],t.prototype,"enableRouting",void 0),zh([I([])],t.prototype,"children",void 0),zh([I("")],t.prototype,"assistants",void 0),zh([I("")],t.prototype,"level",void 0),zh([I("")],t.prototype,"hasSubTree",void 0),zh([I("")],t.prototype,"rows",void 0),t}(Ee),Li=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),q=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Zse=function(n){if(n)switch(n.type){case"Basic":default:return rb;case"Flow":return TF;case"Path":return EF;case"Image":return xF;case"Text":return Pd;case"Bpmn":return hT;case"Native":return am;case"HTML":return DF;case"UmlActivity":return AF;case"UmlClassifier":return LF;case"SwimLane":return Hd}return rb},va=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),q([I("Basic")],t.prototype,"type",void 0),t}(Ee),EF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"Path"},q([I("Path")],t.prototype,"type",void 0),q([I("")],t.prototype,"data",void 0),t}(va),am=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"Native"},q([I("Native")],t.prototype,"type",void 0),q([I("")],t.prototype,"content",void 0),q([I("Stretch")],t.prototype,"scale",void 0),t}(va),DF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"Html"},q([I("HTML")],t.prototype,"type",void 0),q([I("")],t.prototype,"content",void 0),t}(va),xF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"Image"},q([I("Image")],t.prototype,"type",void 0),q([I("")],t.prototype,"source",void 0),q([I("None")],t.prototype,"scale",void 0),q([I("None")],t.prototype,"align",void 0),t}(va),Pd=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"Text"},q([I("Text")],t.prototype,"type",void 0),q([I("")],t.prototype,"content",void 0),q([re({},$n)],t.prototype,"margin",void 0),t}(va),rb=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"BasicShape"},q([I("Basic")],t.prototype,"type",void 0),q([I("Rectangle")],t.prototype,"shape",void 0),q([I(0)],t.prototype,"cornerRadius",void 0),q([Bt([],z)],t.prototype,"points",void 0),t}(va),TF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"FlowShape"},q([I("Flow")],t.prototype,"type",void 0),q([I("Terminator")],t.prototype,"shape",void 0),t}(va),sT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"BpmnGateway"},q([I("None")],t.prototype,"type",void 0),t}(Ee),oT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"BpmnDataObject"},q([I("None")],t.prototype,"type",void 0),q([I(!1)],t.prototype,"collection",void 0),t}(Ee),Jse=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),q([I("None")],t.prototype,"type",void 0),q([I("None")],t.prototype,"loop",void 0),q([I(!1)],t.prototype,"call",void 0),q([I(!1)],t.prototype,"compensation",void 0),t}(Ee),aT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"BpmnEvent"},q([I("Start")],t.prototype,"event",void 0),q([I("None")],t.prototype,"trigger",void 0),t}(Ee),zd=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"BpmnSubEvent"},q([I("None")],t.prototype,"trigger",void 0),q([I("Start")],t.prototype,"event",void 0),q([I("")],t.prototype,"id",void 0),q([re({},z)],t.prototype,"offset",void 0),q([Bt([],Zn)],t.prototype,"annotations",void 0),q([Bt([],Es)],t.prototype,"ports",void 0),q([I()],t.prototype,"width",void 0),q([I()],t.prototype,"height",void 0),q([re({},$n)],t.prototype,"margin",void 0),q([I("Center")],t.prototype,"horizontalAlignment",void 0),q([I("Center")],t.prototype,"verticalAlignment",void 0),q([I(!0)],t.prototype,"visible",void 0),t}(Ee),Kse=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),q([re({id:"success",event:"End",offset:{x:1,y:.5}},zd)],t.prototype,"success",void 0),q([re({id:"failure",event:"Intermediate",trigger:"Error",offset:{x:.25,y:1}},zd)],t.prototype,"failure",void 0),q([re({id:"cancel",event:"Intermediate",trigger:"Cancel",offset:{x:.75,y:1}},zd)],t.prototype,"cancel",void 0),t}(Ee),eoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),q([I("None")],t.prototype,"type",void 0),q([I(!1)],t.prototype,"adhoc",void 0),q([I("Default")],t.prototype,"boundary",void 0),q([I(!1)],t.prototype,"compensation",void 0),q([I("None")],t.prototype,"loop",void 0),q([I(!0)],t.prototype,"collapsed",void 0),q([Bt([],zd)],t.prototype,"events",void 0),q([re({},Kse)],t.prototype,"transaction",void 0),q([I(void 0)],t.prototype,"processes",void 0),t}(Ee),lT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"BpmnActivity"},q([I("Task")],t.prototype,"activity",void 0),q([re({},Jse)],t.prototype,"task",void 0),q([re({},eoe)],t.prototype,"subProcess",void 0),t}(Ee),lm=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return Li(t,n),t.prototype.getClassName=function(){return"BpmnAnnotation"},q([I("")],t.prototype,"text",void 0),q([I("")],t.prototype,"id",void 0),q([I(0)],t.prototype,"angle",void 0),q([I()],t.prototype,"height",void 0),q([I()],t.prototype,"width",void 0),q([I(0)],t.prototype,"length",void 0),t}(Ee),toe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),q([I("")],t.prototype,"textAnnotationTarget",void 0),q([I("Auto")],t.prototype,"textAnnotationDirection",void 0),t}(Ee),hT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"BpmnShape"},q([I("Bpmn")],t.prototype,"type",void 0),q([I("Event")],t.prototype,"shape",void 0),q([re({},aT)],t.prototype,"event",void 0),q([re({},sT)],t.prototype,"gateway",void 0),q([re({},oT)],t.prototype,"dataObject",void 0),q([re({},lT)],t.prototype,"activity",void 0),q([re({},lm)],t.prototype,"annotation",void 0),q([Bt([],lm)],t.prototype,"annotations",void 0),q([re({},toe)],t.prototype,"textAnnotation",void 0),t}(va),AF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"UmlActivityShape"},q([I("UmlActivity")],t.prototype,"type",void 0),q([I("Action")],t.prototype,"shape",void 0),t}(va),cT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"MethodArguments"},q([I("")],t.prototype,"name",void 0),q([I("")],t.prototype,"type",void 0),q([re({},Yp)],t.prototype,"style",void 0),t}(Ee),rf=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"UmlClassAttribute"},q([I("Public")],t.prototype,"scope",void 0),q([I(!1)],t.prototype,"isSeparator",void 0),q([re({fill:"#F9F9F9",strokeColor:"#CCCCCC"},Al)],t.prototype,"separatorStyle",void 0),t}(cT),hm=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"UmlClassMethod"},q([Bt([],cT)],t.prototype,"parameters",void 0),t}(rf),nb=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"UmlClass"},q([I("")],t.prototype,"name",void 0),q([Bt([],rf)],t.prototype,"attributes",void 0),q([Bt([],hm)],t.prototype,"methods",void 0),q([re({},Yp)],t.prototype,"style",void 0),t}(Ee),dT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"UmlInterface"},q([I(!1)],t.prototype,"isSeparator",void 0),q([re({fill:"#F9F9F9",strokeColor:"#CCCCCC"},Al)],t.prototype,"separatorStyle",void 0),t}(nb),sb=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"UmlEnumerationMember"},q([I("")],t.prototype,"name",void 0),q([I("")],t.prototype,"value",void 0),q([I(!1)],t.prototype,"isSeparator",void 0),q([re({fill:"#F9F9F9",strokeColor:"#CCCCCC"},Al)],t.prototype,"separatorStyle",void 0),q([re({},Yp)],t.prototype,"style",void 0),t}(Ee),uT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"UmlEnumeration"},q([I("")],t.prototype,"name",void 0),q([Bt([],sb)],t.prototype,"members",void 0),q([re({},Yp)],t.prototype,"style",void 0),t}(Ee),LF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Li(t,n),t.prototype.getClassName=function(){return"UmlClassifierShape"},q([I("UmlClassifier")],t.prototype,"type",void 0),q([re({},nb)],t.prototype,"classShape",void 0),q([re({},dT)],t.prototype,"interfaceShape",void 0),q([re({},uT)],t.prototype,"enumerationShape",void 0),q([I("Class")],t.prototype,"classifier",void 0),t}(va),te=function(n){function t(e,i,r,s){var a,o=n.call(this,e,i,r,s)||this;return o.isCanvasUpdate=!1,o.status="None",o.parentId="",o.processId="",o.umlIndex=-1,o.outEdges=[],o.inEdges=[],o.isHeader=!1,o.isLane=!1,o.isPhase=!1,o.children&&o.children.length>0&&((!(a=r).style||!a.style.fill)&&(o.style.fill="transparent"),(!a.style||!a.style.strokeColor)&&(o.style.strokeColor="transparent")),o.shape&&"UmlActivity"===o.shape.type&&ZI(r,o),o.shape&&"SwimLane"===o.shape.type&&aF(r,o),o.ports&&o.ports.length&&function sse(n){for(var t=0;t>";t=n;break;case"FinalNode":t=fF(e)}return t}(new Ke,i,this);break;case"Bpmn":if(e.bpmnModule){i=e.bpmnModule.initBPMNContent(i,this,e),this.wrapper.elementActions=this.wrapper.elementActions|Xr.ElementIsGroup;var v=this.shape.activity.subProcess;if(v.processes&&v.processes.length)for(var S=0,b=this.shape.activity.subProcess.processes;S>",margin:{left:10,right:10},id:"class",style:{fontSize:i.style.fontSize,color:i.style.color,fill:i.style.fill,textWrapping:r},offset:{x:.5,y:.3},constraints:Lr.ReadOnly}],constraints:(ie.Default|ie.HideThumbs)&~(ie.Rotate|ie.Drag|ie.Resize),verticalAlignment:"Stretch",horizontalAlignment:"Stretch",style:{fill:t.style.fill,strokeColor:"black"===t.style.strokeColor?"#ffffff00":t.style.strokeColor}},!0);return e.initObject(s),e.nodes.push(s),e.UpdateBlazorDiagramModel(s,"Node"),t.children.push(s.id),function Wse(n,t,e,i){if("Enumeration"===n.shape.classifier){var r=e.members;if(r&&r.length){ef(n,t);for(var s="",o=0;o0)for(var o=0;o0&&s.phaseSize&&(i+=s.phaseSize,Gv(n,s.phaseSize)),s.lanes.length>0)for(o=0;o0){var a=0;for(o=0;o0&&"Horizontal"===r.orientation)for(l=0;l0&&(i+=r.phaseSize,o=Xv(r.phaseSize),n.push(o)),a=0;a0&&o.phaseSize){for(var l=0;l0)for(l=0;l0?e.nameTable[this.nodes[0].id].wrapper:e.nameTable[this.connectors[0].id].wrapper,this.annotation.id);i.children.push(s)}else if(this.nodes||this.connectors){for(var o=0;o-1}function HF(n,t,e){n=[];for(var i=0,r=e.length;i0?c.getElementsByTagName("svg")[0].outerHTML:c.getElementsByTagName("g").length>0?c.getElementsByTagName("g")[0].outerHTML:"",s.shape.content=h,n.content=h,c.parentElement.removeChild(c)}l="nodeTemplate"}else a=s,l="annotationTemplate";var f=document.getElementById(n.diagramId).ej2_instances[0];if("string"!=typeof n.content&&"function"!=typeof n.content||n.isTemplate)if(n.isTemplate){if(v=void 0,v=f.isReact?n.getNodeTemplate()($(e),f,l+"_"+("nodeTemplate"===l?e.id:n.nodeId+e.id),void 0,void 0,!1,i):f.isVue||f.isVue3?n.getNodeTemplate()?n.getNodeTemplate()($(e),f,l+"_"+("nodeTemplate"===l?e.id:n.nodeId+e.id),void 0,void 0,!1,i):(v=ri("nodeTemplate"===l?f.nodeTemplate:f.annotationTemplate))($(e),f,l+"_"+("nodeTemplate"===l?e.id:n.nodeId+e.id),void 0,void 0,!1,i):n.getNodeTemplate()($(e),f,l+"_"+("nodeTemplate"===l?e.id:n.nodeId+e.id),void 0,void 0,!1))for(var M=0;M=1&&0===n.x&&("Clip"===i.textOverflow||"Ellipsis"===i.textOverflow)&&("Wrap"===i.textWrapping||"WrapWithOverflow"===i.textWrapping)&&(n.x=t[e-1]?t[e-1].x:-n.width/2),n.x}function _F(n,t,e,i){return e&&!t.template||t.template&&"function"==typeof t.template&&i.isReact?(n.isTemplate=!0,n.template=n.content=Rh(n,!0,t)):n.content=t.template,n}function Qe(){for(var e,t="",i=0;i<5;i++){if(typeof window<"u"&&"crypto"in window&&"getRandomValues"in crypto){var r=new Uint16Array(1);e=(window.msCrypto||window.crypto).getRandomValues(r)[0]%60}else e=Math.floor(61*Math.random());0===i&&e<10?i--:t+="0123456789ABCDEFGHIJKLMNOPQRSTUVWXTZabcdefghiklmnopqrstuvwxyz".substring(e,e+1)}return t}function UF(n){if(n)try{return"function"!=typeof n&&document.querySelectorAll(n).length?ri(document.querySelector(n).innerHTML.trim()):ri(n)}catch{return ri(n)}}function En(n){new Ne;var e=n.offsetY-n.actualSize.height*n.pivot.y,i=n.offsetY+n.actualSize.height*(1-n.pivot.y),r=n.offsetX-n.actualSize.width*n.pivot.x,s=n.offsetX+n.actualSize.width*(1-n.pivot.x);return Ne.toBounds([{x:r,y:e},{x:s,y:e},{x:r,y:i},{x:s,y:i}])}function yr(n){var t=new Ne,e=En(n),i=e.middleLeft,r=e.topCenter,s=e.bottomCenter,o=e.middleRight,a=e.topLeft,l=e.topRight,h=e.bottomLeft,c=e.bottomRight;if(n.corners={topLeft:a,topCenter:r,topRight:l,middleLeft:i,middleRight:o,bottomLeft:h,bottomCenter:s,bottomRight:c},0!==n.rotateAngle||0!==n.parentTransform){var d=Hi();qi(d,n.rotateAngle+n.parentTransform,n.offsetX,n.offsetY),n.corners.topLeft=a=Je(d,a),n.corners.topCenter=r=Je(d,r),n.corners.topRight=l=Je(d,l),n.corners.middleLeft=i=Je(d,i),n.corners.middleRight=o=Je(d,o),n.corners.bottomLeft=h=Je(d,h),n.corners.bottomCenter=s=Je(d,s),n.corners.bottomRight=c=Je(d,c)}return t=Ne.toBounds([a,l,h,c]),n.corners.left=t.left,n.corners.right=t.right,n.corners.top=t.top,n.corners.bottom=t.bottom,n.corners.center=t.center,n.corners.width=t.width,n.corners.height=t.height,t}function $(n,t,e,i){var r={},s="properties";if(n){e=n.propName;var l=[],h=[];if((l=l.concat(Object.keys(n[""+s]||n))).push("version"),e){var c=Zi(t);h=c?c(e):[],l=l.concat(h)}for(var d=function boe(n){switch(n){case"nodes":case"children":return["inEdges","outEdges","parentId","processId","nodeId","umlIndex","isPhase","isLane"];case"connectors":return["parentId"];case"annotation":case"annotations":return["nodeId"];case"shape":return["hasHeader"];case"layers":return["objectZIndex"]}return[]}(e),u=0,p=l=l.concat(d);u0&&(e=r),r=Math.floor(woe(e,i)),s=Bc(o+=n.substr(e,r),t)}while(s<=t.width);for(o=o.substr(0,e),a=e;a=t.width){n=n.substr(0,o.length-1);break}return"Ellipsis"===t.textOverflow?(n=n.substr(0,n.length-3),n+="..."):n=n.substr(0,n.length),n}function ST(n,t){if("NoWrap"===t&&"PreserveAll"===n)return"pre";var e="";switch(n){case"CollapseAll":e="nowrap";break;case"CollapseSpace":e="pre-line";break;case"PreserveAll":e="pre-wrap"}return e}function IT(n,t){var e=Hi();qi(e,t,0,0);var i=Je(e,{x:0,y:0}),r=Je(e,{x:n.width,y:0}),s=Je(e,{x:0,y:n.height}),o=Je(e,{x:n.width,y:n.height}),a=Math.min(i.x,r.x,s.x,o.x),l=Math.min(i.y,r.y,s.y,o.y),h=Math.max(i.x,r.x,s.x,o.x),c=Math.max(i.y,r.y,s.y,o.y);return new me(h-a,c-l)}function xs(n,t,e,i){if(0!==n){var r=Hi();return qi(r,n,t,e),Je(r,i)}return i}function Zi(n){return void 0!==n&&"string"==typeof n&&(n=Y(n,window)),n}var bo=function(){function n(){}return n.getContext=function(t){return t.getContext("2d")},n.setCanvasSize=function(t,e,i){t&&(t.setAttribute("width",e.toString()),t.setAttribute("height",i.toString()))},n.prototype.renderGradient=function(t,e,i,r){var s,o,a;if("None"!==t.gradient.type){for(var l=0;l0?(w=0===S.r1?e.arc[parseInt(r.toString(),10)].r1:S.r1,C=0===S.r2?e.arc[parseInt(r.toString(),10)].r2:S.r2,r++):(w=S.r1,C=S.r2);var D=S.angle*(Math.PI/180),A=S.largeArc,x=S.sweep,R={x:u,y:p},L={x:Math.cos(D)*(M.x-R.x)/2+Math.sin(D)*(M.y-R.y)/2,y:-Math.sin(D)*(M.x-R.x)/2+Math.cos(D)*(M.y-R.y)/2},O=Math.pow(L.x,2)/Math.pow(w,2)+Math.pow(L.y,2)/Math.pow(C,2);O>1&&(w*=Math.sqrt(O),C*=Math.sqrt(O));var N=Math.pow(C,2)*Math.pow(L.x,2),T=(A===x?-1:1)*Math.sqrt((Math.pow(w,2)*Math.pow(C,2)-Math.pow(w,2)*Math.pow(L.y,2)-N)/(Math.pow(w,2)*Math.pow(L.y,2)+Math.pow(C,2)*Math.pow(L.x,2)));isNaN(T)&&(T=0);var P={x:T*w*L.y/C,y:T*-C*L.x/w},_={x:(M.x+R.x)/2+Math.cos(D)*P.x-Math.sin(D)*P.y,y:(M.y+R.y)/2+Math.sin(D)*P.x+Math.cos(D)*P.y},B=this.a([1,0],[(L.x-P.x)/w,(L.y-P.y)/C]),j=[(L.x-P.x)/w,(L.y-P.y)/C],Q=[(-L.x-P.x)/w,(-L.y-P.y)/C],oe=this.a(j,Q);this.r(j,Q)<=-1&&(oe=Math.PI),this.r(j,Q)>=1&&(oe=0);var pe=B+oe/2*(x?1:-1);if(Math.cos(pe),Math.sin(pe),S.centp=_,S.xAxisRotation=D,S.rx=w,S.ry=C,S.a1=B,S.ad=oe,S.sweep=x,null!=s){var De=w>C?w:C,xe=w>C?1:w/C,Ie=w>C?C/w:1;s.save(),s.translate(_.x,_.y),s.rotate(D),s.scale(xe,Ie),s.arc(0,0,De,B,B+oe,!x),s.scale(1/xe,1/Ie),s.rotate(-D),s.translate(-_.x,-_.y),s.restore()}break;case"Z":case"z":s.closePath(),u=o,p=a}o=u,a=p}}},n.prototype.drawText=function(t,e,i,r,s,o,a){if(e.content&&!0===e.visible){var l=n.getContext(t);l.save(),this.setStyle(t,e),o&&(e.fontSize*=o),this.rotateContext(t,e.angle,e.x+e.width*e.pivotX,e.y+e.height*e.pivotY),this.setFontStyle(t,e);var u,d=0;u=e.childNodes;var p=e.wrapBounds;if(l.fillStyle=e.color,p){var f=this.labelAlign(e,p,u);for(d=0;de.width&&"Wrap"!==e.textOverflow&&"NoWrap"===e.textWrapping&&(g.text=VF(g.text,e)),"Clip"!==e.textOverflow&&"Ellipsis"!==e.textOverflow||"Wrap"!==e.textWrapping?l.fillText(g.text,v,y):ya.actualSize.height+a.bounds.y&&(g.text=g.text.slice(0,g.text.length-3),g.text=g.text.concat("...")),l.fillText(g.text,v,y)),"Underline"===e.textDecoration||"Overline"===e.textDecoration||"LineThrough"===e.textDecoration){var M=v,w=void 0,D=v+l.measureText(g.text).width,A=void 0;switch(e.textDecoration){case"Underline":w=y+2,A=y+2;break;case"Overline":w=f.y+g.dy*d,A=f.y+g.dy*d;break;case"LineThrough":w=(y+f.y+g.dy*d)/2+2,A=(y+f.y+g.dy*d)/2+2}l.beginPath(),l.moveTo(M,w),l.lineTo(D,A),l.strokeStyle=e.color,l.lineWidth=.08*e.fontSize,l.globalAlpha=e.opacity,l.stroke()}}}l.restore()}},n.prototype.loadImage=function(t,e,i,r,s){this.rotateContext(i,e.angle,r,s);var o=new Image;o.src=e.source,this.image(t,o,e.x,e.y,e.width,e.height,e)},n.prototype.drawImage=function(t,e,i,r){var s=this;if(e.visible){var o=n.getContext(t);o.save();var a=e.x+e.width*e.pivotX,l=e.y+e.height*e.pivotY,h=new Image;h.src=e.source,o.canvas.id.split("_"),r?h.onload=function(){s.loadImage(o,e,t,a,l)}:this.loadImage(o,e,t,a,l),o.restore()}},n.prototype.image=function(t,e,i,r,s,o,a){t.beginPath();var l=e.width,h=e.height,c=s,d=o,u=0,p=0;if(a&&"None"!==a.alignment){var f=a.alignment.toLowerCase().substr(1,3),g=a.alignment.toLowerCase().substr(5,3);if("Slice"===a.scale){var v=function(){u=c,p=h*c/l},y=function(){u=l*d/h,p=d};c>d?(v(),d>p&&y()):c===d?l>h?y():v():(y(),c>u&&v());var S=this.getSliceOffset(f,u,c,l),b=this.getSliceOffset(g,p,d,h),M=l-S,w=h-b,C=u-S*(u/l),D=p-b*(p/h),A=Tt("canvas",{width:s.toString(),height:o.toString()});A.getContext("2d").drawImage(e,S,b,M,w,0,0,C,D),t.drawImage(A,i,r,s,o)}else if("Meet"===a.scale){var R=h/l,L=d/c;p=L>R?c*R:d,i+=this.getMeetOffset(f,u=L>R?c:d/R,c),r+=this.getMeetOffset(g,p,d),t.drawImage(e,0,0,l,h,i,r,u,p)}else t.drawImage(e,i,r,s,o)}else if("None"!==a.flip){var O=1,N=1;("Horizontal"===a.flip||"Both"===a.flip)&&(i=-i,s=-s,O=-1),("Vertical"===a.flip||"Both"===a.flip)&&(r=-r,o=-o,N=-1),t.scale(O,N),t.drawImage(e,i,r,s,o)}else t.drawImage(e,i,r,s,o);t.closePath()},n.prototype.getSliceOffset=function(t,e,i,r){switch(t){case"min":default:return 0;case"mid":return(e-i)/2*r/e;case"max":return(e-i)*r/e}},n.prototype.getMeetOffset=function(t,e,i){var r=Math.max(e,i),s=Math.min(e,i);switch(t){case"min":default:return 0;case"mid":return(r-s)/2;case"max":return r-s}},n.prototype.m=function(t){return Math.sqrt(Math.pow(t[0],2)+Math.pow(t[1],2))},n.prototype.r=function(t,e){return(t[0]*e[0]+t[1]*e[1])/(this.m(t)*this.m(e))},n.prototype.a=function(t,e){return(t[0]*e[1]t.width&&("Ellipsis"===t.textOverflow||"Clip"===t.textOverflow)&&"NoWrap"===t.textWrapping?0:.5*t.width:"right"===t.textAlign&&(c=1*t.width),s.x=t.x+c+(e?e.x:0),s.y=a+d-r.height/2,s},n}(),cb=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Vi=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Eoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return cb(t,n),Vi([I("")],t.prototype,"source",void 0),Vi([I("transparent")],t.prototype,"color",void 0),Vi([I("None")],t.prototype,"scale",void 0),Vi([I("None")],t.prototype,"align",void 0),t}(Ee),Doe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return cb(t,n),Vi([I("Page")],t.prototype,"mode",void 0),Vi([I("PageSettings")],t.prototype,"region",void 0),Vi([re({top:25,bottom:25,left:25,right:25},$n)],t.prototype,"margin",void 0),Vi([I(!1)],t.prototype,"canZoomIn",void 0),Vi([I(void 0)],t.prototype,"customBounds",void 0),Vi([I(!1)],t.prototype,"canFit",void 0),t}(Ee),xoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return cb(t,n),Vi([I(null)],t.prototype,"width",void 0),Vi([I(null)],t.prototype,"height",void 0),Vi([re({},$n)],t.prototype,"margin",void 0),Vi([I("Landscape")],t.prototype,"orientation",void 0),Vi([I("Infinity")],t.prototype,"boundaryConstraints",void 0),Vi([re({},Eoe)],t.prototype,"background",void 0),Vi([I(!1)],t.prototype,"multiplePage",void 0),Vi([I(!1)],t.prototype,"showPageBreaks",void 0),Vi([re({},Doe)],t.prototype,"fitOptions",void 0),t}(Ee),Toe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return cb(t,n),Vi([I(0)],t.prototype,"horizontalOffset",void 0),Vi([I(0)],t.prototype,"verticalOffset",void 0),Vi([I(1)],t.prototype,"currentZoom",void 0),Vi([I(0)],t.prototype,"viewPortWidth",void 0),Vi([I(0)],t.prototype,"viewPortHeight",void 0),Vi([I(.2)],t.prototype,"minZoom",void 0),Vi([I(30)],t.prototype,"maxZoom",void 0),Vi([I("Diagram")],t.prototype,"scrollLimit",void 0),Vi([I()],t.prototype,"scrollableArea",void 0),Vi([I(!1)],t.prototype,"canAutoScroll",void 0),Vi([I(100)],t.prototype,"autoScrollFrequency",void 0),Vi([re({left:15,right:15,top:15,bottom:15},$n)],t.prototype,"autoScrollBorder",void 0),Vi([re({left:0,right:0,top:0,bottom:0},$n)],t.prototype,"padding",void 0),Vi([I(.2)],t.prototype,"zoomFactor",void 0),t}(Ee),Aoe=function(){function n(){this.services={}}return n.prototype.register=function(t,e){this.services[""+t]=e},n.prototype.getService=function(t){return this.services[""+t]},n}(),WF=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),ma=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},YF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return WF(t,n),ma([I("lightgray")],t.prototype,"lineColor",void 0),ma([I("")],t.prototype,"lineDashArray",void 0),ma([I([1.25,18.75,.25,19.75,.25,19.75,.25,19.75,.25,19.75])],t.prototype,"lineIntervals",void 0),ma([I([1,19,.5,19.5,.5,19.5,.5,19.5,.5,19.5])],t.prototype,"dotIntervals",void 0),ma([I([20])],t.prototype,"snapIntervals",void 0),t}(Ee),Loe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return WF(t,n),ma([re({},YF)],t.prototype,"horizontalGridlines",void 0),ma([re({},YF)],t.prototype,"verticalGridlines",void 0),ma([I(ei.All)],t.prototype,"constraints",void 0),ma([I(5)],t.prototype,"snapAngle",void 0),ma([I("Lines")],t.prototype,"gridType",void 0),ma([I(5)],t.prototype,"snapObjectDistance",void 0),ma([I("#07EDE1")],t.prototype,"snapLineColor",void 0),t}(Ee),QF=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Ja=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},GF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return QF(t,n),Ja([I(5)],t.prototype,"interval",void 0),Ja([I(100)],t.prototype,"segmentWidth",void 0),Ja([I("Horizontal")],t.prototype,"orientation",void 0),Ja([I("RightOrBottom")],t.prototype,"tickAlignment",void 0),Ja([I("red")],t.prototype,"markerColor",void 0),Ja([I(25)],t.prototype,"thickness",void 0),Ja([I(null)],t.prototype,"arrangeTick",void 0),t}(Ee),Noe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return QF(t,n),Ja([I(!1)],t.prototype,"showRulers",void 0),Ja([I(!0)],t.prototype,"dynamicGrid",void 0),Ja([re({orientation:"Horizontal"},GF)],t.prototype,"horizontalRuler",void 0),Ja([re({orientation:"Vertical"},GF)],t.prototype,"verticalRuler",void 0),t}(Ee),Ooe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),XF=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},koe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ooe(t,n),XF([I("")],t.prototype,"property",void 0),XF([I("")],t.prototype,"field",void 0),t}(Ee),bT=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),ln=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},qF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return bT(t,n),ln([I("")],t.prototype,"read",void 0),ln([I("")],t.prototype,"create",void 0),ln([I("")],t.prototype,"update",void 0),ln([I("")],t.prototype,"destroy",void 0),ln([I()],t.prototype,"customFields",void 0),t}(Ee),Poe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return bT(t,n),ln([I("")],t.prototype,"id",void 0),ln([I("")],t.prototype,"sourceID",void 0),ln([I("")],t.prototype,"targetID",void 0),ln([I(null)],t.prototype,"sourcePointX",void 0),ln([I(null)],t.prototype,"sourcePointY",void 0),ln([I(null)],t.prototype,"targetPointX",void 0),ln([I(null)],t.prototype,"targetPointY",void 0),ln([I(null)],t.prototype,"dataManager",void 0),ln([re({},qF)],t.prototype,"crudAction",void 0),t}(Ee),zoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return bT(t,n),ln([I("")],t.prototype,"id",void 0),ln([I(null)],t.prototype,"dataManager",void 0),ln([I(null)],t.prototype,"dataSource",void 0),ln([I("")],t.prototype,"root",void 0),ln([I("")],t.prototype,"parentId",void 0),ln([I()],t.prototype,"doBinding",void 0),ln([Bt([],koe)],t.prototype,"dataMapSettings",void 0),ln([re({},qF)],t.prototype,"crudAction",void 0),ln([re({},Poe)],t.prototype,"connectionDataSource",void 0),t}(Ee),$F=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Cr=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Roe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return $F(t,n),Cr([I("LeftInFlow")],t.prototype,"yesBranchDirection",void 0),Cr([I("RightInFlow")],t.prototype,"noBranchDirection",void 0),Cr([I(["Yes","True"])],t.prototype,"yesBranchValues",void 0),Cr([I(["No","False"])],t.prototype,"noBranchValues",void 0),t}(Ee),Hoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return $F(t,n),Cr([I("")],t.prototype,"fixedNode",void 0),Cr([I(30)],t.prototype,"horizontalSpacing",void 0),Cr([I("SamePoint")],t.prototype,"connectionPointOrigin",void 0),Cr([I("Nonlinear")],t.prototype,"arrangement",void 0),Cr([I(30)],t.prototype,"verticalSpacing",void 0),Cr([I(30)],t.prototype,"maxIteration",void 0),Cr([I(40)],t.prototype,"springFactor",void 0),Cr([I(50)],t.prototype,"springLength",void 0),Cr([re({left:50,top:50,right:0,bottom:0},$n)],t.prototype,"margin",void 0),Cr([I("Auto")],t.prototype,"horizontalAlignment",void 0),Cr([I("Auto")],t.prototype,"verticalAlignment",void 0),Cr([I("TopToBottom")],t.prototype,"orientation",void 0),Cr([I("Auto")],t.prototype,"connectionDirection",void 0),Cr([I("Default")],t.prototype,"connectorSegments",void 0),Cr([I("None")],t.prototype,"type",void 0),Cr([I()],t.prototype,"getLayoutInfo",void 0),Cr([I()],t.prototype,"layoutInfo",void 0),Cr([I()],t.prototype,"getBranch",void 0),Cr([I()],t.prototype,"bounds",void 0),Cr([I(!0)],t.prototype,"enableAnimation",void 0),Cr([I(!1)],t.prototype,"enableRouting",void 0),Cr([I("")],t.prototype,"root",void 0),Cr([re({},Roe)],t.prototype,"flowchartLayoutSettings",void 0),t}(Ee),Boe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),ZF=function(n){function t(e,i){var r=n.call(this,e,!0)||this;return r.oldValue=null,r.endPoint=i,r}return Boe(t,n),t.prototype.mouseDown=function(e){var i,r=!0;if(e.source&&e.source.connectors&&(i=e.source.connectors[0]),e.info&&e.actualObject&&(r=e.info.ctrlKey&&"Orthogonal"!==e.actualObject.type),i&&r){this.inAction=!0,this.undoElement=$(e.source),n.prototype.mouseDown.call(this,e);for(var s=0;s0)1!==s&&this.removePrevSegment(i,s);else if(a){var l=z.distancePoints(a.points[0],a.points[1]);Math.abs(a.length||0===a.length?a.length:l)<=5&&this.removeNextSegment(i,s)}this.commandHandler.updateEndPoint(i,r),i.selectedSegmentIndex=0}if(this.undoElement){var c=$(e.source);this.commandHandler.addHistoryEntry({type:"SegmentChanged",redoObject:c,undoObject:this.undoElement,category:"Internal"})}if(i.isBezierEditing&&(i.isBezierEditing=!1),this.prevPosition!==this.startPosition){var u={source:i,state:"Completed",oldValue:this.oldValue,newValue:$(this.selectedSegment),cancel:!1,segment:this.selectedSegment};this.commandHandler.triggerEvent(Ce.segmentChange,u)}n.prototype.mouseUp.call(this,e)},t.prototype.removePrevSegment=function(e,i){var r=e.segments[i-2],s=e.segments[i+1];if(s&&!((s.length||0===s.length?s.length:z.distancePoints(s.points[0],s.points[1]))<=5)){var a=e.segments.slice(i-1,i+1),l={element:e,removeSegments:a,type:"Removal",cancel:!1};if(this.commandHandler.triggerEvent(Ce.segmentCollectionChange,l),!l.cancel){var h=e.segments[i+1];e.segments.splice(i-1,2);var c=this.selectedSegment;"Left"===c.direction||"Right"===c.direction?(r.points[r.points.length-1].x=h.points[0].x,h.points[0].y=r.points[r.points.length-1].y):(r.points[r.points.length-1].y=h.points[0].y,h.points[0].x=r.points[r.points.length-1].x),(c.length||0===c.length)&&this.findSegmentDirection(r),this.findSegmentDirection(h)}}},t.prototype.findSegmentDirection=function(e){e.direction&&(e.length||0===e.length)&&(e.length=z.distancePoints(e.points[0],e.points[e.points.length-1]),e.direction=z.direction(e.points[0],e.points[e.points.length-1]))},t.prototype.removeNextSegment=function(e,i){var l,h,r=this.selectedSegment,s=e.segments[i-1],o=e.segments[i+2],a=e.segments[i+1];if(a.length||0===a.length?(l=e.segments.slice(i,2),h={element:e,removeSegments:l,type:"Removal",cancel:!1},this.commandHandler.triggerEvent(Ce.segmentCollectionChange,h={element:e,removeSegments:l,type:"Removal",cancel:!1}),h.cancel||(e.segments.splice(i,2),"Top"===r.direction||"Bottom"===r.direction?(o.points[0].y=r.points[0].y,s.points[s.points.length-1].x=o.points[0].x):(o.points[0].x=r.points[0].x,s.points[s.points.length-1].y=o.points[0].y))):(l=e.segments.slice(i+1,1),this.commandHandler.triggerEvent(Ce.segmentCollectionChange,h={element:e,removeSegments:l,type:"Removal",cancel:!1}),h.cancel||(e.segments.splice(i+1,1),"Top"===r.direction||"Bottom"===r.direction?s.points[s.points.length-1].x=a.points[a.points.length-1].x:s.points[s.points.length-1].y=a.points[a.points.length-1].y,this.findSegmentDirection(s),r.length=r.direction=null)),s&&o&&!h.cancel&&(s.length=z.distancePoints(s.points[0],o.points[0]),s.direction=z.direction(s.points[0],o.points[0]),o.length||0===o.length)){o.length=z.distancePoints(s.points[s.points.length-1],o.points[o.points.length-1]);var c=s.points,d=o.points;o.direction=z.direction(c[c.length-1],d[d.length-1])}},t.prototype.addOrRemoveSegment=function(e,i,r){for(var s,o,a=[],l={segments:e.segments},h=0;h0?"Bottom":"Top":r>0?"Right":"Left",length:i.points[0].x===i.points[1].x?s:r},!0)),l.push(new bi(e,"segments",{type:"Orthogonal",direction:c,length:h/2},!0));var p={element:e,addSegments:l,type:"Addition",cancel:!1};return this.commandHandler.triggerEvent(Ce.segmentCollectionChange,p),p.cancel||(e.segments=l.concat(e.segments),a=o+2),a},t.prototype.insertFirstSegment=function(e,i,r,s,o){var a,l,d,u,h=[];if(e.sourcePortID&&i.length&&e.segments[0].points.length>2)for(var p=void 0,f=0;f0?"Bottom":"Top":r>0?"Right":"Left"),p=u,h.push(u)}else h.push(new bi(e,"segments",{type:"Orthogonal",direction:i.direction,length:i.length/3},!0)),"Bottom"===i.direction||"Top"===i.direction?(l=Math.abs(r),a=r>0?"Right":"Left"):(l=Math.abs(s),a=s>0?"Bottom":"Top"),u=new bi(e,"segments",{type:"Orthogonal",direction:a,length:l},!0),h.push(u);var y={element:e,addSegments:h,type:"Addition",cancel:!1};if(this.commandHandler.triggerEvent(Ce.segmentCollectionChange,y),!y.cancel){if(e.sourcePortID&&i.length&&e.segments[0].points.length>2)e.segments.splice(0,1),d=1;else{var S=e.segments[1];S&&S.length&&(S.length=a!==S.direction?S.length+l:S.length-l),d=2,i.length=2*i.length/3}e.segments=h.concat(e.segments)}return d},t.prototype.updateAdjacentSegments=function(e,i,r,s){var o=e.segments[parseInt(i.toString(),10)],a=o.points[o.points.length-1],h=!0;"Orthogonal"===o.type&&(o.points[0]=o.points[0],o.points[o.points.length-1]=a,e.segments[i-1]&&(h=this.updatePreviousSegment(r,s,e,i)),e.segments.length-1>i&&h&&this.updateNextSegment(e,o,e.segments[i+1],r,s))},t.prototype.addTerminalSegment=function(e,i,r,s,o){var l,h,c,d,a=e.segments.indexOf(i),u=[],p=e.segments.pop(),f=e.segments[e.segments.length-1];l=f&&"Orthogonal"===f.type?f:null;for(var g=0;g0&&"Left"===o.direction?c.middleLeft:c.middleRight,o.length>c.width/2?Math.abs(a.length)0&&"Top"===o.direction?c.topCenter:c.bottomCenter,o.length>c.height/2?Math.abs(a.length)1)for(var a=0,l=this.diagram.views;a0)for(var e=t===Ce.onUserHandleMouseLeave?this.previousAction:this.action,i={element:void 0},r=0;r0)for(var r={element:void 0},s=void 0,o=void 0,a=0;a-1&&(o=s,this.previousTarget=i,this.targetItem=e),o===e.fixedUserHandles[parseInt(a.toString(),10)].id&&(r.element=e.fixedUserHandles[parseInt(a.toString(),10)],this.userHandle(t,a,r,e))},n.prototype.mouseDown=function(t){if(!0!==this.inAction||!(this.tool instanceof VI||this.tool instanceof pa)){this.focus=!0;var e=t.touches,i=!!document.getElementsByClassName("e-dragclone")[0];if(this.isMouseOnScrollBar(t)&&!i)return this.isScrolling=!0,void t.preventDefault();if(this.checkFixedUserHandleEvent(Ce.onFixedUserHandleMouseDown,this.targetItem,this.previousTarget),this.checkUserHandleEvent(Ce.onUserHandleMouseDown),!this.checkEditBoxAsTarget(t)&&jv(this.diagram)||Lc(this.diagram)&&!PI(this.diagram))if(("Select"===this.action||"Drag"===this.action)&&this.diagram.updatePortVisibility(this.hoverElement,Gt.Hover,!0),!(this.tool instanceof Oh||this.tool instanceof kh)||2!==t.button&&2!==t.buttons)if(!0===this.inAction&&!0===this.isMouseDown&&(this.tool instanceof Oh||this.tool instanceof kh))this.isMouseDown=!0,this.eventArgs={},this.getMouseEventArgs(this.currentPosition,this.eventArgs),this.eventArgs.position=this.currentPosition,this.tool.mouseDown(this.eventArgs);else{this.isMouseDown=!0,this.currentPosition=this.prevPosition=this.getMousePosition(t),this.eventArgs={},this.diagram.textEditing&&!this.isMouseOnScrollBar(t)&&(this.diagram.endEdit(),this.diagram.textEditing=!1,"Canvas"===this.diagram.mode&&1!==this.diagram.scroller.currentZoom&&this.diagram.refreshDiagramLayer());var s=this.getTargetElement();this.action=this.diagram.findActionToBeDone(s.obj,s.sourceElement,this.currentPosition,s.target);var o=this.isMetaKey(t);o&&t.shiftKey&&this.diagram.connectorEditingToolModule?this.action="SegmentEnd":(o||t.shiftKey)&&(_v(this.diagram)||Uv(this.diagram))&&(this.action="Select"),this.tool=this.diagram.getTool(this.action),this.tool||(this.action="Select",this.tool=this.diagram.getTool(this.action)),this.getMouseEventArgs(this.currentPosition,this.eventArgs),(o||t.shiftKey)&&(this.eventArgs.info=o&&t.shiftKey?{ctrlKey:o,shiftKey:t.shiftKey}:{ctrlKey:!0}),this.eventArgs.position=this.currentPosition;var l=this.diagram.selectedItems.nodes;if(this.tool.mouseDown(this.eventArgs),this.diagram.selectedItems.canToggleSelection&&l&&this.diagram.selectedItems.nodes&&this.tool instanceof ua)for(var h=0;h=2&&(this.touchStartList=HF(this.touchStartList,0,e)),e||t.preventDefault())}else this.inAction=!1,this.tool.mouseUp(this.eventArgs);!this.isForeignObject(t.target)&&!this.isForeignObject(t.target,!0)&&!e&&t.preventDefault()}},n.prototype.mouseMoveExtend=function(t,e){(this.tool instanceof Oh||this.tool instanceof kh)&&this.tool.mouseMove(this.eventArgs),this.diagram.scrollSettings.canAutoScroll?this.checkAutoScroll(t):this.blocked||this.tool.mouseMove(this.eventArgs),this.eventArgs.target&&(this.hoverElement=this.eventArgs.target);var i=!((this.eventArgs.target instanceof te||this.eventArgs.target instanceof de)&&(e instanceof te||e instanceof de));this.tool instanceof Od&&this.diagram.updatePortVisibility(this.hoverElement instanceof te||this.hoverElement instanceof de?this.hoverElement:this.hoverNode,Gt.Connect|Gt.Hover,i),this.hoverElement instanceof te&&this.hoverNode instanceof te&&this.hoverNode&&this.hoverNode.id!==this.hoverElement.id&&this.diagram.updatePortVisibility(this.hoverNode,Gt.Connect|Gt.Hover,!0),this.hoverElement instanceof de&&this.hoverElement.ports.length>0&&this.diagram.updatePortVisibility(this.hoverElement,Gt.Connect|Gt.Hover,!0),this.previousElement instanceof te&&this.hoverElement&&this.previousElement.id!==this.hoverElement.id&&this.diagram.updatePortVisibility(this.previousElement,Gt.Connect|Gt.Hover,!0),this.previousElement=this.hoverElement,""!==this.diagram.tooltip.content&&(this.hoverElement=null),this.hoverNode=i?null:e},n.prototype.checkAction=function(t){if("LabelSelect"===this.action&&this.eventArgs.sourceWrapper&&(this.eventArgs.sourceWrapper instanceof si||this.eventArgs.sourceWrapper instanceof Jn)){var e=this.commandHandler.findTarget(this.eventArgs.sourceWrapper,this.eventArgs.source);!_r(this.diagram,e,!1,this.eventArgs.sourceWrapper)&&to(e)&&(this.action="LabelDrag",this.tool=this.getTool(this.action),this.tool.mouseDown(this.initialEventArgs))}else to(t)&&Dd(t)&&this.initialEventArgs&&this.initialEventArgs.source&&"Select"===this.action&&(!_r(this.diagram,this.eventArgs.source,!1)&&this.eventArgs.source instanceof oi&&this.getMouseEventArgs(this.currentPosition,this.eventArgs),(!(t instanceof de)||t instanceof de&&!(wr(this.currentPosition,t.sourcePoint,t.hitPadding)||wr(this.currentPosition,t.targetPoint,t.hitPadding)))&&(this.action="Drag"),this.tool=this.getTool(this.action),this.tool.mouseDown(this.initialEventArgs))},n.prototype.isSwimlaneElements=function(t){return!(t&&(t.isLane||t.isPhase||t.isHeader))},n.prototype.mouseMove=function(t,e){if(this.focus=!0,this.isScrolling)t.preventDefault();else if(jv(this.diagram)||Lc(this.diagram)&&!PI(this.diagram)){this.currentPosition=this.getMousePosition(t);var i=this.diagram.findObjectsUnderMouse(this.currentPosition),r=this.diagram.findObjectUnderMouse(i,this.action,this.inAction);!function Gne(n,t){n.rulerSettings.showRulers&&(n.hRuler.drawRulerMarker(n.hRuler.element,t,n.scroller.horizontalOffset),n.vRuler.drawRulerMarker(n.vRuler.element,t,n.scroller.verticalOffset))}(this.diagram,this.currentPosition);var s=!1,o=void 0;if("touchmove"===t.type&&(e=t.touches)&&e.length>1&&(this.touchMoveList=HF(this.touchMoveList,0,e),"PinchZoom"!==this.action&&(s=!0)),!1===z.equals(this.currentPosition,this.prevPosition)||this.inAction){if(!1===this.isMouseDown||s){this.eventArgs={};var a=null,l=void 0;if(null!==r){if((a=this.diagram.findElementUnderMouse(r,this.currentPosition,this.diagram))&&(l=this.commandHandler.findTarget(a,r)),(l instanceof Zn||l instanceof Nr)&&(l.tooltip&&""!==l.tooltip.content||(l=r)),l!==this.hoverElement){var h=this.getContent();this.hoverElement&&"Auto"===this.hoverElement.tooltip.openOn&&""!==h&&this.elementLeave(),this.diagram.updatePortVisibility(this.hoverElement,Gt.Hover,!0),r instanceof te&&(this.hoverNode=r);var c=!0;!this.isSwimlaneElements(r)&&this.hoverElement&&this.isSwimlaneElements(this.hoverElement)&&(c=!1),this.hoverElement=c?r:this.hoverElement;var d,u=void 0;(d=this.diagram.findElementUnderMouse(r,this.currentPosition,this.diagram))instanceof Ke&&((u=this.commandHandler.findTarget(d,r))instanceof Es||u instanceof xc)&&this.hoverElement.constraints&ni.ToolTip&&(this.hoverElement=u);var p=void 0;d instanceof si&&((p=this.commandHandler.findTarget(d,r))instanceof Zn||p instanceof Nr)&&p.constraints&Lr.Tooltip&&(this.hoverElement=p),c?this.elementEnter(this.currentPosition,!1):this.hoverElement=r}else this.hoverElement&&this.hoverElement===l&&this.hoverElement.tooltip.content&&void 0!==this.diagram.tooltipObject&&"Mouse"===this.hoverElement.tooltip.relativeMode&&this.setTooltipOffset(this.currentPosition);a&&(o=this.commandHandler.findTarget(a,r))}this.action=this.diagram.findActionToBeDone(r,a,this.currentPosition,o),this.checkFixedUserHandleEvent(Ce.onFixedUserHandleMouseEnter,r,a),this.checkUserHandleEvent(Ce.onUserHandleMouseEnter),this.checkPreviousAction(),this.getMouseEventArgs(this.currentPosition,this.eventArgs),this.tool=this.getTool(this.action),this.mouseEvents(),this.tool instanceof pa||this.tool instanceof kh||this.tool instanceof Oh?this.tool.mouseMove(this.eventArgs):e&&this.tool instanceof Jv&&this.tool.mouseDown(this.eventArgs),this.updateCursor(),this.renderUmlHighLighter(this.eventArgs);var f=!1;this.hoverElement&&!(this.tool instanceof Jv)&&r instanceof te&&this.isSwimlaneElements(r)&&(0===this.diagram.selectedItems.nodes.length||!_r(this.diagram,this.hoverElement))||this.hoverElement instanceof de||(f=!0),this.hoverElement&&!(this.tool instanceof Jv)&&r instanceof de&&(0===this.diagram.selectedItems.connectors.length||!_r(this.diagram,this.hoverElement))||this.hoverElement instanceof te||(f=!0),this.diagram.updatePortVisibility(this.hoverElement,Gt.Hover,f);var g=this.getContent();null===r&&this.hoverElement&&"Auto"===this.hoverElement.tooltip.openOn&&g&&(this.hoverElement=null,this.elementLeave()),s=!1}else{this.eventArgs.position=this.currentPosition,"Drag"===this.action&&!_r(this.diagram,this.eventArgs.source,!1)&&this.eventArgs.source instanceof oi&&this.getMouseEventArgs(this.currentPosition,this.eventArgs),this.mouseEvents(),(t.ctrlKey||t.shiftKey)&&(this.eventArgs.info=t.ctrlKey&&t.shiftKey?{ctrlKey:t.ctrlKey,shiftKey:t.shiftKey}:{ctrlKey:!0}),this.checkAction(r);var y=this.getConnectorPadding(this.eventArgs);this.getMouseEventArgs(this.currentPosition,this.eventArgs,this.eventArgs.source,y),this.updateCursor(),this.inAction=!0,this.initialEventArgs=null,("Drag"===this.action||"Rotate"===this.action)&&(this.diagram.diagramActions=this.diagram.diagramActions|ee.Interactions);var S=this.diagram.scroller.getPageBounds();this.mouseMoveExtend(t,r);var b=this.diagram.scroller.getPageBounds();if(r&&(S.width!==b.width||S.height!==b.height||S.x!==b.x||S.y!==b.y)&&this.diagram.views&&this.diagram.views.overview){var M=this.diagram.views.overview;M.updateView(M)}}this.prevPosition=this.currentPosition,this.isForeignObject(t.target,!0)||t.preventDefault()}}},n.prototype.getContent=function(){var i,t=this.hoverElement instanceof te&&this.hoverElement.constraints&ie.Tooltip||this.hoverElement instanceof de&&this.hoverElement.constraints&qe.Tooltip||(this.hoverElement instanceof Es||this.hoverElement instanceof xc)&&this.hoverElement.constraints&ni.ToolTip||(this.hoverElement instanceof Zn||this.hoverElement instanceof Nr)&&this.hoverElement.constraints&Lr.Tooltip,e=this.hoverElement;e instanceof te&&e.children&&e.children.length>0&&(i=this.findIntersectChild(e));var r=t?this.hoverElement.tooltip.content:this.diagram.tooltip.content;return i?i.tooltip.content:r},n.prototype.findIntersectChild=function(t){for(var e,i=new Ne(this.currentPosition.x,this.currentPosition.y,8,8),r=0;r1&&1===t.which&&!function qre(n){return!!(n&ee.PreventClearSelection)}(this.diagram.diagramActions)&&(c=!1,this.commandHandler.clearSelection()),(!_r(this.diagram,h)||!c)&&(this.commandHandler.selectObjects([h],void 0,a),this.diagram.selectedItems.canToggleSelection)){var d=this.diagram.selectedItems.nodes;d?d[0].parentObj instanceof Rd&&(s=!0):this.diagram.selectedItems.connectors.length>0&&(s=!0)}}var u=!1,p=this.updateContainerProperties(),f=void 0;if(this.addUmlNode(),this.inAction=!1,this.isMouseDown=!1,this.diagram.selectedObject.helperObject&&(f=this.updateContainerBounds()),this.tool&&(this.tool.prevPosition||this.tool instanceof X3)){this.eventArgs.position=this.currentPosition;var g=this.getConnectorPadding(this.eventArgs);this.getMouseEventArgs(this.currentPosition,this.eventArgs,this.eventArgs.source,g);var v=this.isMetaKey(t);if((v||t.shiftKey)&&(this.eventArgs.info=v&&t.shiftKey?{ctrlKey:v,shiftKey:t.shiftKey}:{ctrlKey:!0}),this.diagram.diagramActions&ee.Interactions&&(this.diagram.diagramActions=this.diagram.diagramActions&~ee.Interactions),this.eventArgs.clickCount=t.detail,this.diagram.selectedObject.helperObject&&(this.tool instanceof ua||this.tool instanceof kd)){if(this.diagram.selectedObject.actualObject&&""!==this.diagram.selectedObject.actualObject.parentId){var S=this.diagram.getObject(this.diagram.selectedObject.actualObject.parentId);S&&S.isLane&&(this.commandHandler.isContainer=!0)}(u=this.diagram.lineRoutingModule&&this.diagram.nameTable.helper&&this.eventArgs.target&&this.eventArgs.target.isLane&&(this.eventArgs.source instanceof oi&&this.eventArgs.source.nodes.length>0&&""===this.eventArgs.source.nodes[0].parentId||""===this.eventArgs.source.parentId))&&(this.diagram.diagramActions=this.diagram.diagramActions|ee.PreventLaneContainerUpdate),this.tool.mouseUp(this.eventArgs,p.isPreventHistory)}else{if(this.diagram.selectedItems.canToggleSelection){var b=void 0,M=void 0;if(this.diagram.selectedItems.nodes.length>0)for(var w=0;w1&&D[0].id===i[parseInt(w.toString(),10)].id||r.length>0)&&(M=!0);!this.isSwimlaneSelected&&!s&&!M&&this.tool instanceof ua&&"Select"===this.currentAction&&(!b||this.diagram.selectedItems.connectors.length>0)&&this.commandHandler.clearSelection(!0)}this.isSwimlaneSelected=!1,this.tool.mouseUp(this.eventArgs),this.diagram.checkMenu&&(-1!==window.navigator.userAgent.indexOf("Linux")||-1!==window.navigator.userAgent.indexOf("X11"))&&(!t.pageY&&t instanceof TouchEvent&&t.changedTouches?(window.getSelection().removeAllRanges(),this.diagram.contextMenuModule.contextMenu.open(t.changedTouches[0].pageY,t.changedTouches[0].pageX,this.diagram.element),t.preventDefault()):this.diagram.contextMenuModule.contextMenu.open(t.pageY,t.pageX,this.diagram.element),this.diagram.checkMenu=!1)}p.hasStack&&this.diagram.endGroupAction()}if(f&&this.diagram.endGroupAction(),this.updateContainerBounds(!0),2!==this.eventArgs.clickCount&&(this.commandHandler.updateSelectedNodeProperties(this.eventArgs.source),u)){this.diagram.diagramActions=this.diagram.diagramActions&~ee.PreventLaneContainerUpdate;var A=this.eventArgs.source instanceof oi?this.eventArgs.source.nodes:[this.eventArgs.source];if(A)for(w=0;w0&&!N&&this.diagram.renderSelector(!0),!this.inAction&&!this.diagram.currentSymbol&&this.eventArgs){var T=this.getTargetElement();this.diagram.tool!==Ci.ZoomPan&&this.diagram.triggerEvent(Ce.click,{element:T.target instanceof Es?T.target:this.eventArgs.source||this.diagram,position:this.eventArgs.position,count:t.detail,actualObject:this.eventArgs.actualObject,button:0===t.button?"Left":1===t.button?"Middle":"Right"})}this.eventArgs={}}this.diagram.diagramActions=this.diagram.diagramActions&~ee.PreventLaneContainerUpdate,e&&this.updateAnnotation(this.diagram.selectedItems),this.eventArgs={},this.diagram.commandHandler.removeStackHighlighter()},n.prototype.isSwimlaneChild=function(t){if(t.shape&&"SwimLane"!==t.shape.type){var e=this.diagram.nameTable[t.parentId];if(!e)return!1;var i=e.parentId?this.diagram.nameTable[e.parentId]:e;return i&&i.shape&&"SwimLane"===i.shape.type}return!1},n.prototype.updateAnnotation=function(t){var e=t.nodes;if(e.length>0)for(var i=0;i0&&(a+=1),h.isPhase){l="Horizontal"===r.orientation?this.currentPosition.x-e.wrapper.bounds.x:this.currentPosition.y-(e.wrapper.bounds.y+r.header.height);var g={id:Qe(),offset:l,header:{annotation:{content:void 0===h.phases[0].header?"Phase":h.phases[0].header.annotation.content,style:void 0===h.phases[0].header?{}:h.phases[0].header.annotation.style}},style:void 0===h.phases[0]?{}:h.phases[0].style};this.diagram.addPhases(e,[g])}else{var v={id:Qe(),style:h.lanes[0].style,header:{annotation:{content:h.lanes[0].header.annotation.content,style:h.lanes[0].header.annotation.style},style:h.lanes[0].header.style}};if("Horizontal"===h.orientation?v.height=h.lanes[0].height:v.width=h.lanes[0].width,"Horizontal"===r.orientation?(s=i.rowIndex?i.rowIndex:this.diagram.nameTable[i.parentId].rowIndex,i.wrapper.offsetYs)v.header.width=r.lanes[parseInt(s.toString(),10)].header.width,v.header.height=r.lanes[parseInt(s.toString(),10)].header.height;else{var S=void 0;S="Horizontal"===r.orientation?i.rowIndex<3?0:s-a-1:s-1,v.header.width=r.lanes[parseInt(S.toString(),10)].header.width,v.header.height=r.lanes[parseInt(S.toString(),10)].header.height}f&&("height"===f?(v.width=v.height,delete v.height):(v.height=v.width,delete v.width)),this.diagram.addLanes(e,[v],"Horizontal"===r.orientation?s-a:s)}this.commandHandler.select(e)}else if(h.isLane){var b={id:Qe(),width:t.width,height:t.height,addInfo:t.addInfo,shape:{type:"SwimLane",header:{annotation:{content:void 0===h.header?"Header":h.header.annotation.content,style:void 0===h.header?{}:h.header.annotation.style},height:50,style:h.header?h.header.style:h.lanes[0].header.style},phases:[{id:Qe(),header:{annotation:{content:void 0===h.phases||void 0===h.phases[0].header?"Phase":h.phases[0].header.annotation.content,style:void 0===h.phases||void 0===h.phases[0].header?{}:h.phases[0].header.annotation.style},style:void 0===h.phases||void 0===h.phases[0].header?{}:h.phases[0].header.style},style:void 0===h.phases?{}:h.phases[0].style}],lanes:[{id:Qe(),height:t.height,width:t.width,style:h.lanes[0].style,header:{annotation:{content:h.lanes[0].header.annotation.content,style:h.lanes[0].header.annotation.style},style:h.lanes[0].header.style}}],orientation:h.orientation}};"Vertical"===h.orientation&&(b.width+=20),b.offsetX=this.currentPosition.x+b.width/2,b.offsetY=this.currentPosition.y+b.height/2,b.style=t.style,this.diagram.add(b)}},n.prototype.mouseLeave=function(t){this.tool&&this.inAction&&this.tool.mouseLeave(this.eventArgs),this.diagram.selectedObject.helperObject&&(this.updateContainerProperties(),this.updateContainerBounds()&&this.diagram.endGroupAction()),this.eventArgs&&this.eventArgs.source&&(this.diagram.updatePortVisibility(this.eventArgs.source,Gt.Hover,!0),this.hoverElement=null),this.eventArgs&&!this.eventArgs.source&&this.hoverElement&&(this.hoverElement=null),this.tool instanceof Od&&this.eventArgs&&this.eventArgs.target&&this.eventArgs.target instanceof te&&(this.diagram.updatePortVisibility(this.eventArgs.target,Gt.Hover|Gt.Connect,!0),this.hoverElement=null);var i=this.diagram.selectedItems;i&&i.wrapper&&(om(this.diagram,i)||this.diagram.renderSelector(!0)),(this.diagram.diagramActions&ee.Interactions||this.diagram.diagramActions&ee.ToolAction)&&(this.diagram.diagramActions=this.diagram.diagramActions&~ee.ToolAction),this.isMouseDown=!1,this.focus=!1,this.touchStartList=null,this.touchMoveList=null,this.elementLeave(),this.commandHandler.removeSnap(),this.inAction=!1,this.eventArgs={},this.diagram.selectedObject&&this.diagram.selectedObject.helperObject&&(this.diagram.remove(this.diagram.selectedObject.helperObject),this.diagram.selectedObject={helperObject:void 0,actualObject:void 0}),this.tool=null,function Qne(){var t,e,n=document.getElementsByClassName("e-d-ruler-marker");if(n&&n.length>0)for(e=n.length-1;e>=0;e--)(t=n[parseInt(e.toString(),10)])&&t.parentNode.removeChild(t)}(),"Rotate"===this.action&&this.diagram.diagramCanvas.classList.remove("e-diagram-rotate"),t.preventDefault()},n.prototype.mouseWheel=function(t){this.diagram.blazorActions|=on.interaction;var e={event:t,cancel:!1};if(this.diagram.triggerEvent(Ce.mouseWheel,e),!e.cancel){var i=t.wheelDelta>0||-40*t.detail>0,r=this.getMousePosition(t);if(this.diagram.tooltipObject.close(),this.isMetaKey(t)){var o=this.diagram.scrollSettings.zoomFactor;this.diagram.zoomTo(i?{type:"ZoomIn",zoomFactor:o,focusPoint:r}:{type:"ZoomOut",zoomFactor:o,focusPoint:r}),t.preventDefault()}else{var a=this.diagram.scroller.horizontalOffset,l=this.diagram.scroller.verticalOffset,h=i?10:-10;this.tool&&(this.tool instanceof Oh||this.tool instanceof kh)&&(this.eventArgs={},this.getMouseEventArgs(r,this.eventArgs),this.eventArgs.position=r,this.tool.mouseWheel(this.eventArgs)),this.diagram.scrollActions|=ca.Interaction;var c=!0;if(t.isTrusted){var d=!1;(Math.abs(t.deltaY)<100&&-0===Math.abs(t.deltaX)||Math.abs(t.deltaX)<100&&-0===Math.abs(t.deltaY))&&(d=!0);var u=!1;(0!==t.deltaX||0!==t.deltaY)&&(u=navigator.userAgent.includes("Macintosh")),u?Math.abs(t.deltaX)>Math.abs(t.deltaY)?(t.shiftKey||t.deltaX&&-0!==t.deltaX&&(d||!u))&&this.diagram.scroller.zoom(1,h,0,r,c,void 0,d):t.deltaY&&-0!==t.deltaY&&(d||!u)&&this.diagram.scroller.zoom(1,0,h,r,c,void 0,d):t.shiftKey||t.deltaX&&-0!==t.deltaX&&(d||!u)?this.diagram.scroller.zoom(1,h,0,r,c,void 0,d):t.deltaY&&-0!==t.deltaY&&(d||!u)&&this.diagram.scroller.zoom(1,0,h,r,c,void 0,d)}else t.shiftKey||t.deltaX&&-0!==t.deltaX?this.diagram.scroller.zoom(1,h,0,r,c):this.diagram.scroller.zoom(1,0,h,r,c);this.diagram.scrollActions&=~ca.Interaction,(a!==this.diagram.scroller.horizontalOffset||l!==this.diagram.scroller.verticalOffset)&&t.preventDefault()}if(this.diagram.textEditing){if(this.diagram.isTriggerEvent=!0,this.diagram.activeLabel.parentId){var f=this.diagram.getObject(this.diagram.activeLabel.parentId);this.diagram.startTextEdit(f,this.diagram.activeLabel.id)}this.diagram.isTriggerEvent=!1}this.diagram.blazorActions=this.diagram.blazorActions&~on.interaction}},n.prototype.keyDown=function(t){if(t.fromMouseEvents&&(t.ctrlKey&&(this.keyArgs.keyModifiers=1),t.shiftKey&&(this.keyArgs.keyModifiers=4),t.shiftKey&&t.ctrlKey&&(this.keyArgs.keyModifiers=5)),!(this.diagram.diagramActions&ee.TextEdit)&&!this.checkEditBoxAsTarget(t)||"Escape"===t.key||27===t.keyCode){var i=void 0,r=t.keyCode?t.keyCode:t.which,s=t.key;("ArrowDown"===s||"ArrowUp"===s||"ArrowLeft"===s||"ArrowRight"===s)&&(this.isNudgeKey=!0);var o=this.isMetaKey(t);if(this.diagram.commandManager&&this.diagram.commands)for(var l=0,h=Object.keys(this.diagram.commands);l4&&(S({keyDownEventArgs:KeyboardEvent,parameter:i.parameter,type:"KEYDOWN"}),this.keyCount=0)),this.isKeyUp=!1):S({keyDownEventArgs:KeyboardEvent,parameter:i.parameter})}break}}}}this.keyArgs={element:this.diagram.selectedItems,key:t.key,keyCode:t.keyCode?t.keyCode:t.which},this.getKeyModifier(this.keyArgs,t),this.diagram.diagramActions&ee.TextEdit&&this.getlabel(this.keyArgs,t),this.diagram.triggerEvent(Ce.keyDown,this.keyArgs)},n.prototype.getlabel=function(t,e){var i=this.diagram.activeLabel;t.target=this.diagram.element.id+"_editBox";var r=this.diagram.nameTable[i.parentId];if(document.getElementById(this.diagram.element.id+"_editBox")){t.text=document.getElementById(this.diagram.element.id+"_editBox").value;for(var s=0;s=this.diagram.scroller.viewPortWidth-18?r="right":e.x+this.diagram.scroller.horizontalOffsetthis.diagram.scroller.viewPortHeight-18?r="bottom":e.y+this.diagram.scroller.verticalOffset0&&(s=this.findIntersectChild(this.hoverElement)),"Auto"===this.hoverElement.tooltip.openOn&&""!==r&&Mx(this.diagram,s||(i?this.hoverElement:void 0)),this.hoverElement.tooltip.content&&("Mouse"===this.hoverElement.tooltip.relativeMode?this.setTooltipOffset(t):(this.diagram.tooltipObject.offsetX=0,this.diagram.tooltipObject.offsetY=0));var o=this.diagram.findObjectsUnderMouse(this.currentPosition),a=this.diagram.findObjectUnderMouse(o,this.action,this.inAction);if(null!==a){var l=void 0;this.hoverElement.tooltip.isSticky&&(this.diagram.tooltipObject.isSticky=!0),a instanceof te&&a.children&&a.children.length>0&&(a=s||a),l=a.ports&&(this.hoverElement instanceof Es||this.hoverElement instanceof xc)||a.annotations&&(this.hoverElement instanceof Zn||this.hoverElement instanceof Nr)?document.getElementById(a.id+"_"+this.hoverElement.id):document.getElementById(a.id+(a.shape&&a.shape instanceof am?"_content_native_element":"_groupElement")),"Auto"===this.hoverElement.tooltip.openOn&&""!==r&&(this.diagram.tooltipObject.close(),this.diagram.tooltipObject.openOn=this.hoverElement.tooltip.openOn,this.diagram.tooltipObject.dataBind()),function jre(n,t){var e=0;return n instanceof de?n.constraints&qe.Tooltip?e=n.constraints&qe.Tooltip:n.constraints&qe.InheritTooltip&&(e=t.constraints&rt.Tooltip):n instanceof Es||n instanceof xc?n.constraints&ni.ToolTip?e=n.constraints&ni.ToolTip:n.constraints&ni.InheritTooltip&&(e=t.constraints&rt.Tooltip):n instanceof Zn||n instanceof Nr?n.constraints&Lr.Tooltip&&(e=n.constraints&Lr.Tooltip):n.constraints&ie.Tooltip?e=n.constraints&ie.Tooltip:n.constraints&ie.InheritTooltip&&(e=t.constraints&rt.Tooltip),e}(this.hoverElement,this.diagram)&&"Auto"===this.hoverElement.tooltip.openOn&&(this.diagram.tooltipObject.target=this.hoverElement.id,this.diagram.tooltipObject.open("Mouse"===this.hoverElement.tooltip.relativeMode?this.diagram.element:l))}}},n.prototype.elementLeave=function(){this.diagram.tooltipObject&&!this.diagram.tooltipObject.isSticky&&"Custom"!==this.diagram.tooltipObject.openOn&&this.diagram.tooltipObject.close()},n.prototype.setTooltipOffset=function(t){var e=function dse(n,t,e,i){var o="Mouse"===(!(e instanceof te?e.constraints&ie.InheritTooltip:e instanceof de?e.constraints&qe.InheritTooltip:e.constraints&ni.InheritTooltip)&&(e instanceof te?e.constraints&ie.Tooltip:e instanceof de?e.constraints&qe.Tooltip:e.constraints&ni.ToolTip)?e.tooltip.relativeMode:n.tooltip.relativeMode);"Mouse"===i?o=!0:"Object"===i&&(o=!1);var a=function use(n,t,e,i){var o,r={},s=document.getElementById(e.element.id);if(n instanceof te||n instanceof de)o=n.wrapper.bounds;else{var a=e.findObjectsUnderMouse(t),l=e.findObjectUnderMouse(a,"Select",!1);o=e.findElementUnderMouse(l,t,e).bounds}var c=s.getBoundingClientRect();switch(e.tooltipObject.position){case"BottomCenter":r=zc(t,o.bottomCenter,e,i,c.width/2,c.height);break;case"BottomLeft":case"LeftBottom":r=zc(t,o.bottomLeft,e,i,0,c.height);break;case"BottomRight":case"RightBottom":r=zc(t,o.bottomRight,e,i,c.width,c.height);break;case"LeftCenter":r=zc(t,o.middleLeft,e,i,0,c.height/2);break;case"LeftTop":case"TopLeft":r=zc(t,o.topLeft,e,i,0,0);break;case"RightCenter":r=zc(t,o.middleRight,e,i,c.width,c.height/2);break;case"RightTop":case"TopRight":r=zc(t,o.topRight,e,i,c.width,0);break;case"TopCenter":r=zc(t,o.topCenter,e,i,c.width/2,0)}return r}(e,t,n,o),l=qa(n);return{x:a.x+l.width,y:a.y+l.height}}(this.diagram,t,this.hoverElement);this.diagram.tooltipObject.offsetX=e.x,this.diagram.tooltipObject.offsetY=e.y},n.prototype.altKeyPressed=function(t){return!!(t&pt.Alt)},n.prototype.ctrlKeyPressed=function(t){return!!(t&pt.Control)},n.prototype.shiftKeyPressed=function(t){return!!(t&pt.Shift)},n.prototype.scrolled=function(t){this.diagram.updateScrollOffset()},n.prototype.doubleClick=function(t){if(jv(this.diagram)){var e=void 0,i=this.diagram.findObjectsUnderMouse(this.currentPosition),r=this.diagram.findObjectUnderMouse(i,this.action,this.inAction);if(null!==r&&jv(this.diagram))if(e=this.diagram.findElementUnderMouse(r,this.currentPosition,this.diagram),this.tool&&(this.tool instanceof Oh||this.tool instanceof kh))this.tool.mouseUp(this.eventArgs),this.isMouseDown=!1,this.eventArgs={},this.tool=null,t.preventDefault();else{var o=this.diagram.commandHandler.getObjectLayer(r.id);!o||o.lock||!o.visible||this.diagram.diagramActions&ee.TextEdit||this.diagram.startTextEdit(r,e instanceof si?e.id.split(r.id+"_")[1]:void 0)}this.diagram.triggerEvent(Ce.doubleClick,{source:r||this.diagram,position:this.currentPosition,count:t.detail})}},n.prototype.itemClick=function(t,e){var i=t;return cs(this.diagram,i,!0)?i:null},n.prototype.inputChange=function(t){var i,s,o,a,l,h,c,d,u,p=document.getElementById(this.diagram.element.id+"_editBox"),f=document.getElementById(this.diagram.element.id+"_editTextBoxDiv"),g=p.value,v=g.split("\n");(!(a=this.diagram.selectedItems.nodes[0]?this.diagram.selectedItems.nodes[0]:this.diagram.selectedItems.connectors[0])&&this.tool instanceof WI||a&&"SwimLane"===a.shape.type)&&(a=this.diagram.nameTable[this.diagram.activeLabel.parentId]),a&&("Text"!==a.shape.type&&a.annotations.length>0||"Text"===a.shape.type)&&(c=NF((o=this.diagram.getWrapper(a.wrapper,this.diagram.activeLabel.id)).style,g,void 0,void 0,i=(i=a.wrapper.bounds.width90?i:90),s=Number(p.style.fontSize.split("px")[0]),v.length>1&&""===v[v.length-1]&&(c.height=c.height+s),d=this.diagram.scroller.transform,u=T3(this.diagram)?d.scale:1,l=(12>c.height?12:c.height)*u,f.style.left=(o.bounds.center.x+d.tx)*d.scale-(h=(90>(h=c.width)?90:h)*u)/2-2.5+"px",f.style.top=(o.bounds.center.y+d.ty)*d.scale-l/2-3+"px",f.style.width=h+"px",f.style.height=l+"px",p.style.minHeight="12px",p.style.minWidth="90px",p.style.width=h+"px",p.style.height=l+"px")},n.prototype.isAddTextNode=function(t,e){return!(!(this.tool instanceof WI||e)||(this.tool=null,t&&!kI(this.diagram)&&(this.diagram.drawingObject=void 0,this.diagram.currentDrawingObject=void 0),vF(this.diagram.nodes,t.id)||vF(this.diagram.connectors,t.id)))},n.prototype.checkEditBoxAsTarget=function(t){return!(!t.target||t.target.id!==this.diagram.element.id+"_editBox")},n.prototype.getMouseEventArgs=function(t,e,i,r){var s,o,a;if(e.position=t,i?(o=this.diagram.findObjectsUnderMouse(this.currentPosition,i),s=this.diagram.findTargetObjectUnderMouse(o,this.action,this.inAction,e.position,i)):"Drag"===this.action||"ConnectorSourceEnd"===this.action||"SegmentEnd"===this.action||"OrthoThumb"===this.action||"BezierSourceThumb"===this.action||"BezierTargetThumb"===this.action||"ConnectorTargetEnd"===this.action||-1!==this.action.indexOf("Rotate")||-1!==this.action.indexOf("Resize")?(s=this.diagram.selectedItems,!this.diagram.currentSymbol&&"Drag"===this.action&&s&&this.diagram.selectedItems.nodes.length>0&&"SwimLane"===this.diagram.selectedItems.nodes[0].shape.type&&(o=this.diagram.findObjectsUnderMouse(this.currentPosition),s=this.diagram.findObjectUnderMouse(o,this.action,this.inAction))):(o=this.diagram.findObjectsUnderMouse(this.currentPosition),s=this.diagram.findObjectUnderMouse(o,this.action,this.inAction)),s&&s.isHeader&&(this.eventArgs.actualObject=s=this.diagram.nameTable[s.parentId]),s){var l=void 0,h=void 0,c=void 0;if(((a=this.diagram.findElementUnderMouse(s,this.currentPosition,this.diagram,r))&&s.ports&&s.ports.length&&!ib(s,a)||!a||!s)&&o&&o.length&&i instanceof oi)for(l=i.connectors[0],c=o.length-1;c>=0;c--)if(((h=o[parseInt(c.toString(),10)])instanceof te||h instanceof de)&&l&&l.connectionPadding){if(a=this.diagram.findElementUnderMouse(s=h,this.currentPosition,this.diagram,r),l.constraints&qe.ConnectToNearByPort&&s&&s.ports&&s.ports.length&&ib(s,a))break;if((h instanceof te||h instanceof de)&&l&&l.connectionPadding&&h.wrapper.outerBounds.containsPoint(this.currentPosition)&&l.constraints&qe.ConnectToNearByNode&&!(l.constraints&qe.ConnectToNearByPort)){a=this.diagram.findElementUnderMouse(s=h,this.currentPosition,this.diagram,0);break}}}return i?(e.target=s,e.targetWrapper=a):(e.source=s,e.sourceWrapper=a),e.actualObject=this.eventArgs.actualObject,e.source instanceof oi&&void 0===e.actualObject&&(e.source.nodes.length>0||e.source.connectors.length>0)&&(e.actualObject=e.source.nodes.length>0?this.diagram.nameTable[e.source.nodes[0].id]:this.diagram.nameTable[e.source.connectors[0].id]),e.startTouches=this.touchStartList,e.moveTouches=this.touchMoveList,e},n.prototype.resetTool=function(){this.action="Select",this.hoverElement=null,this.hoverNode=null,this.tool=this.diagram.getTool(this.action),this.updateCursor()},n.prototype.updateTool=function(){this.eventArgs&&!this.eventArgs.position&&(this.action="Select")},n.prototype.getTool=function(t){switch(t){case"Select":return new Zv(this.commandHandler,!0);case"Drag":return new ua(this.commandHandler);case"Rotate":return new Yx(this.commandHandler);case"LayoutAnimation":return new Lne(this.commandHandler);case"FixedUserHandle":return new Ane(this.commandHandler,!0);case"Hyperlink":return new X3(this.commandHandler);case"ResizeSouthEast":case"ResizeSouthWest":case"ResizeNorthEast":case"ResizeNorthWest":case"ResizeSouth":case"ResizeNorth":case"ResizeWest":case"ResizeEast":return new kd(this.commandHandler,t);case"ConnectorSourceEnd":case"ConnectorTargetEnd":case"BezierSourceThumb":case"BezierTargetThumb":return new Od(this.commandHandler,t);case"SegmentEnd":case"OrthoThumb":return new ZF(this.commandHandler,t);case"Draw":var e="shape",i=function nse(n){var t;return n&&(n.type?t="Connector":n.shape&&!n.type&&(t="Node")),t}(this.diagram.drawingObject);if("Node"===i&&"Text"===this.diagram.drawingObject.shape.type)return new WI(this.commandHandler);if("Connector"===i&&"Freehand"===this.diagram.drawingObject.type)return new Pne(this.commandHandler);if("Node"===i&&"Polygon"===this.diagram.drawingObject.shape[""+e]&&!this.diagram.drawingObject.shape.points)return new Oh(this.commandHandler);if("Node"===i||"Node"===i&&"Polygon"===this.diagram.drawingObject.shape[""+e]&&this.diagram.drawingObject.shape.points)return new VI(this.commandHandler,this.diagram.drawingObject);if("Connector"===i&&"Polyline"===this.diagram.drawingObject.type)return new kh(this.commandHandler);if("Connector"===i)return new pa(this.commandHandler,"ConnectorSourceEnd",this.diagram.drawingObject);break;case"Pan":return new Jv(this.commandHandler,!1);case"PinchZoom":return new Jv(this.commandHandler,!0);case"PortDrag":return new ua(this.commandHandler,"Port");case"PortDraw":return new pa(this.commandHandler,"ConnectorSourceEnd",this.diagram.drawingObject);case"LabelSelect":return new Zv(this.commandHandler,!0,"LabelSelect");case"LabelDrag":return new Nne(this.commandHandler);case"LabelResizeSouthEast":case"LabelResizeSouthWest":case"LabelResizeNorthEast":case"LabelResizeNorthWest":case"LabelResizeSouth":case"LabelResizeNorth":case"LabelResizeWest":case"LabelResizeEast":return new One(this.commandHandler,t);case"LabelRotate":return new kne(this.commandHandler)}return null},n.prototype.getCursor=function(t){var e=this.diagram.selectedItems.annotation?this.diagram.selectedItems.wrapper.children[0]:this.diagram.selectedItems;return function Tne(n,t){if(t+=360,t%=360,-1===n.indexOf("Resize"))return Wx[""+n];var e=Wx[""+n];return t>=0&&t<25||t>=160&&t<=205||t>=340&&t<=360?e:t>=25&&t<=70||t>=205&&t<=250?"n-resize"===e||"s-resize"===e?"ne-resize":"nw-resize"===e||"se-resize"===e?"n-resize":"e-resize"===e||"w-resize"===e?"nw-resize":"e-resize":t>=70&&t<=115||t>=250&&t<=295?"n-resize"===e||"s-resize"===e?"e-resize":"nw-resize"===e||"se-resize"===e?"ne-resize":"e-resize"===e||"w-resize"===e?"n-resize":"nw-resize":t>=115&&t<=155||t>=295&&t<=340?"n-resize"===e||"s-resize"===e?"nw-resize":"nw-resize"===e||"se-resize"===e?"e-resize":"e-resize"===e||"w-resize"===e?"ne-resize":Wx[""+n]:"n-resize"}(t,this.diagram.selectedItems.annotation?e.rotateAngle+e.parentTransform:e.rotateAngle)},n.prototype.findElementUnderMouse=function(t,e,i,r){return this.objectFinder.findElementUnderSelectedItem(t,e,i,r)},n.prototype.findObjectsUnderMouse=function(t,e){return this.objectFinder.findObjectsUnderMouse(t,this.diagram,this.eventArgs,e)},n.prototype.findObjectUnderMouse=function(t,e,i){return this.objectFinder.findObjectUnderMouse(this.diagram,t,e,i,this.eventArgs,this.currentPosition)},n.prototype.findTargetUnderMouse=function(t,e,i,r,s){return this.objectFinder.findObjectUnderMouse(this.diagram,t,e,i,this.eventArgs,r,s)},n.prototype.findActionToBeDone=function(t,e,i,r){return function Mne(n,t,e,i,r,s,o){if(s&&s.length>1&&r&&r.length>1)return"PinchZoom";if(i.currentSymbol)return"Drag";if("PortDraw"===i.eventHandler.action&&(i.tool&=~Ci.DrawOnce),(x3(i)||kI(i))&&i.drawingObject)return"Draw";if(Xa(i)&&(l=i.selectedItems).wrapper&&qr(l.constraints,"UserHandle"))for(var h=0,c=l.userHandles;h=50&&(l.x=(a.points[parseInt(h.toString(),10)].x+a.points[h+1].x)/2,l.y=(a.points[parseInt(h.toString(),10)].y+a.points[h+1].y)/2,wr(e,l,n.hitPadding?n.hitPadding:10)))return"OrthoThumb"}else AI(n)&&console.warn('[WARNING] :: Module "ConnectorEditing" is not available in Diagram component! You either misspelled the module name or forgot to load it.');return null}(g,l,e,i);if("OrthoThumb"===S)return S;if(qr(l.constraints,"ConnectorSourceThumb")&&xI(g)&&S||qr(l.constraints,"ConnectorTargetThumb")&&TI(g)&&S)return S}}else{var b=i.selectedItems.handleSize/2/i.scroller.currentZoom,M=10/i.scroller.currentZoom,w=Hi();qi(w,p.rotateAngle+p.parentTransform,p.offsetX,p.offsetY);var C=p.offsetX-p.pivot.x*p.actualSize.width,D=p.offsetY-p.pivot.y*p.actualSize.height,A={x:C+(.5===p.pivot.x?2*p.pivot.x:p.pivot.x)*p.actualSize.width/2,y:D-30/i.scroller.currentZoom};A=Je(w,A);var x=!!i.selectedItems.annotation,R=!(!x||!LI(i.selectedItems.annotation));if(qr(l.constraints,"Rotate")&&wr(e,A,M)&&i.selectedItems.thumbsConstraints&bt.Rotate){if(x&&R)return"LabelRotate";if(!x)return"Rotate"}if(u.Inflate(b),u.containsPoint(e)&&(S=function wne(n,t,e,i,r,s){var o;return 1===n.selectedItems.nodes.length&&0===n.selectedItems.connectors.length&&n.selectedItems.nodes[0].container&&(o=function Dne(n,t,e,i,r){var s=10/n.scroller.currentZoom,o=40/n.scroller.currentZoom,a=n.selectedItems,l=t.actualSize.width,h=t.actualSize.height,c=new Ne(i,r,t.style.strokeWidth,h),d=new Ne(i+l,r,t.style.strokeWidth,h),u=new Ne(i,r,l,t.style.strokeWidth),p=new Ne(i,r+h,l,t.style.strokeWidth),f=cs(n,n.selectedItems.nodes[0],!0)?n.nameTable[n.selectedItems.nodes[0].parentId]:n.selectedItems.nodes[0];if(l>=o&&h>=o){if(fa(a.constraints,"ResizeEast",a.thumbsConstraints,a)&&d.containsPoint(e,s))return"ResizeEast";if(fa(a.constraints,"ResizeSouth",a.thumbsConstraints,a)&&p.containsPoint(e,s))return"ResizeSouth";if("Grid"!==f.container.type){if(fa(a.constraints,"ResizeWest",a.thumbsConstraints,a)&&c.containsPoint(e,s))return"ResizeWest";if(fa(a.constraints,"ResizeNorth",a.thumbsConstraints,a)&&u.containsPoint(e,s))return"ResizeNorth"}}return null}(n,t,e,r,s)),!o&&(!n.selectedItems.nodes[0]||!n.selectedItems.nodes[0].isPhase&&!n.selectedItems.nodes[0].isLane&&"SwimLane"!==n.selectedItems.nodes[0].shape.type)&&(o=function xne(n,t,e,i,r,s){var o=40/n.scroller.currentZoom,a=n.selectedItems.handleSize/2/n.scroller.currentZoom,l=n.selectedItems,h=!!l.annotation;if(t.actualSize.width>=o&&t.actualSize.height>=o){if(fa(l.constraints,"ResizeSouthEast",l.thumbsConstraints,l)&&wr(e,Je(i,{x:r+t.actualSize.width,y:s+t.actualSize.height}),a))return h?"LabelResizeSouthEast":"ResizeSouthEast";if(fa(l.constraints,"ResizeSouthWest",l.thumbsConstraints,l)&&wr(e,Je(i,{x:r,y:s+t.actualSize.height}),a))return h?"LabelResizeSouthWest":"ResizeSouthWest";if(fa(l.constraints,"ResizeNorthEast",l.thumbsConstraints,l)&&wr(e,Je(i,{x:r+t.actualSize.width,y:s}),a))return h?"LabelResizeNorthEast":"ResizeNorthEast";if(fa(l.constraints,"ResizeNorthWest",l.thumbsConstraints,l)&&wr(e,Je(i,{x:r,y:s}),a))return h?"LabelResizeNorthWest":"ResizeNorthWest"}return fa(l.constraints,"ResizeEast",l.thumbsConstraints,l)&&wr(e,Je(i,{x:r+t.actualSize.width,y:s+t.actualSize.height/2}),a)?h?"LabelResizeEast":"ResizeEast":fa(l.constraints,"ResizeWest",l.thumbsConstraints,l)&&wr(e,Je(i,{x:r,y:s+t.actualSize.height/2}),a)?h?"LabelResizeWest":"ResizeWest":fa(l.constraints,"ResizeSouth",l.thumbsConstraints,l)&&wr(e,Je(i,{x:r+t.actualSize.width/2,y:s+t.actualSize.height}),a)?h?"LabelResizeSouth":"ResizeSouth":fa(l.constraints,"ResizeNorth",l.thumbsConstraints,l)&&wr(e,Je(i,{x:r+t.actualSize.width/2,y:s}),a)?h?"LabelResizeNorth":"ResizeNorth":null}(n,t,e,i,r,s)),o||null}(i,p,e,w,C,D),S))return S}}if(Lc(i)&&!n)return"Pan";if((o instanceof Es||o instanceof xc)&&(!Lc(i)||_v(i)||Uv(i))&&(S=function Ene(n,t,e,i){if(Hx(t)&&(ga(t,Gt.Hover)||ga(t,Gt.Visible))){if(t.constraints&ni.Drag)return"PortDrag"}else if(Rx(t)&&(ga(t,Gt.Hover)||ga(t,Gt.Visible))&&t.constraints&ni.Draw){n.drawingObject={};var r={type:"Orthogonal",sourcePortID:t.id};return n.drawingObject=r,n.tool|=Ci.DrawOnce,n.currentDrawingObject=r,"PortDraw"}return"None"}(i,o),"None"!==S))return S;if((o instanceof Zn||o instanceof Nr)&&!Lc(i)&&Dd(o))return _r(i,o,void 0,t)&&to(o)?"LabelDrag":"LabelSelect";if(null!==n){if(!(n instanceof te||n instanceof de))return"Select";if(t&&t.id){var L=t.id.split(n.id)[1];if(L&&L.match("^_icon"))return"LayoutAnimation"}if(t&&t.id)for(var O=void 0,N=0;N-1)return"FixedUserHandle";if(t instanceof si&&t.hyperlink.link)return"Hyperlink";if(!to(n)||!_r(i,n,!1)||void 0!==i.selectedItems.annotation)return n&&Lc(i)&&!PI(i)?"Pan":i.selectedItems.nodes.length&&i.selectedItems.nodes[0].isLane&&i.selectedItems.wrapper&&i.selectedItems.wrapper.bounds.containsPoint(e)?"Drag":"Select";if(n instanceof de&&!wr(e,n.sourcePoint,n.hitPadding)&&!wr(e,n.targetPoint,n.hitPadding)||!(n instanceof de))return"Drag"}return"Select"}(t,e,this.currentPosition,this.diagram,this.touchStartList,this.touchMoveList,r)},n.prototype.updateContainerBounds=function(t){var e=!1;if(this.diagram.selectedObject.helperObject&&this.diagram.selectedObject.actualObject instanceof te){var i=this.tool instanceof kd,r=this.diagram.selectedObject.actualObject,s=this.diagram.nameTable[r.parentId];t?V3(this.diagram,r,this.currentPosition,i):((!s||s&&"SwimLane"!==s.shape.type)&&this.diagram.updateDiagramObject(r),e=function yne(n,t,e,i){var r,o=!1;if(cs(n,t,!0)){n.protectPropertyChange(!0);var a=(r=n.nameTable[t.parentId]).wrapper;if(r&&"Canvas"===r.container.type){if(i||a.bounds.x<=e.x&&a.bounds.right>=e.x&&a.bounds.y<=e.y&&a.bounds.bottom>=e.y){var l=void 0,h=a.bounds.y,c=a.bounds.x,d=n.nameTable[r.parentId]||r;if("SwimLane"===d.shape.type)o=$v(r,d,t,n,!0);else{var p=n.nameTable[r.parentId]||r,f=p.shape;l=p.wrapper,a.actualSize.widtha.outerBounds.x)&&(void 0!==r.rowIndex?(l.updateColumnWidth(r.columnIndex,a.outerBounds.width,!0),"Horizontal"===f.orientation&&f.phaseSize&&FI(p,n,a,r.columnIndex),Oc(n,p),n.drag(p,c-a.bounds.x,h-a.bounds.y)):n.scale(r,1+(a.outerBounds.width-a.actualSize.width)/a.actualSize.width,1,a.outerBounds.xa.outerBounds.y)&&(void 0!==r.rowIndex?(l.updateRowHeight(r.rowIndex,a.outerBounds.height,!0),n.drag(p,c-a.bounds.x,h-a.bounds.y)):n.scale(r,1,1+(a.outerBounds.height-a.actualSize.height)/a.actualSize.height,a.outerBounds.yi.y&&(h+=u>0?-1:1,u+=u>0?-1:1):i&&e.wrapper.offsetYi.x&&(h+=u>0?-1:1,u+=u>0?-1:1):i&&e.wrapper.offsetX1&&!(this.diagram.lineRoutingModule&&this.diagram.constraints&rt.LineRouting))for(var b=t.offsetX-this.diagram.selectedItems.offsetX,M=t.offsetY-this.diagram.selectedItems.offsetY,w=t.rotateAngle-this.diagram.selectedItems.rotateAngle,C=0;C-1){var x=c.children;x.splice(x.indexOf(o.id),1),this.diagram.nameTable[o.id].parentId="",i=!0,c.wrapper.children.splice(A,1)}}if(function bne(n,t,e,i){var r=n,s=e.nameTable[r.parentId],o=e.nameTable[r.parentId];if(t&&o&&o.container&&"Stack"===o.container.type&&t.container&&"Stack"===t.container.type&&o.id!==t.parentId){var a=o.wrapper.children.indexOf(r.wrapper);a>-1&&(e.nameTable[r.id].parentId=t.id,o.wrapper.children.splice(a,1))}if(t&&t.parentId&&r.parentId&&"Drag"===i&&o.container&&"Stack"===o.container.type){var l=s.wrapper.children.indexOf(t.wrapper),h=s.wrapper.children.indexOf(r.wrapper),c={targetIndex:l,target:t,sourceIndex:h,source:n};s.wrapper.children.splice(h,1),s.wrapper.children.splice(l,0,r.wrapper),e.commandHandler.addHistoryEntry({type:"StackChildPositionChanged",redoObject:{targetIndex:h,target:t,sourceIndex:l,source:n},undoObject:c,category:"Internal"})}}(o,h,this.diagram,this.action),(c=cs(this.diagram,o)?this.diagram.nameTable[o.parentId]:this.diagram.nameTable[o.parentId]||o)&&c.container&&"Canvas"===c.container.type&&(c.wrapper.maxWidth=c.maxWidth=c.wrapper.actualSize.width,c.wrapper.maxHeight=c.maxHeight=c.wrapper.actualSize.height,e=!0),cs(this.diagram,o,!0)&&c&&"Canvas"===c.container.type)if(this.diagram.selectedItems.nodes.length>1)for(C=0;C0)for(var i=0;i0&&e.columnIndex>0||l&&e.isLane)){if("Horizontal"===t.container.orientation&&e.isPhase&&e.wrapper.width>e.maxWidth&&(e.maxWidth=e.wrapper.width,e.wrapper.maxWidth=e.wrapper.width),h.updateColumnWidth(e.columnIndex,r.width,!0,c),_x(this.diagram,e,t),e.isPhase){var f=this.diagram.nameTable[""+t.shape.phases[e.columnIndex].header.id];f.maxWidth0?(r=new rf(t,"",u),t.shape.classShape.attributes.push(r)):i.id.includes("_umlMethods")&&t.shape.classShape.methods.length>0&&(s=new hm(t,"",u),t.shape.classShape.methods.push(s))),"Interface"===t.shape.classifier&&(i.id.includes("_umlProperty")&&t.shape.interfaceShape.attributes.length>0?(r=new rf(t,"",u),t.shape.classShape.attributes.push(r)):i.id.includes("_umlMethods")&&t.shape.interfaceShape.methods.length>0&&(s=new hm(t,"",u),t.shape.interfaceShape.methods.push(s))),"Enumeration"===t.shape.classifier&&i.id.includes("_umlMember")&&t.shape.enumerationShape.members.length>0){var p=new sb(t,"",u);t.shape.enumerationShape.members.push(p)}t.wrapper.children.indexOf(c.wrapper),this.diagram.enableServerDataBinding(!0),this.diagram.add(c),this.diagram.updateConnectorEdges(t),this.diagram.clearSelection(),this.diagram.select([this.diagram.nameTable[c.id]]),this.diagram.endGroupAction(),this.diagram.startTextEdit()}}},n}(),_oe=function(){function n(){}return n.prototype.findObjectsUnderMouse=function(t,e,i,r,s){var o=[];r&&r instanceof oi&&r.nodes.length+r.connectors.length===1&&(r=r.nodes[0]||r.connectors[0]).children&&0===r.children.length&&(i.actualObject=r);for(var a,l,h,c,f,d=r&&r instanceof de&&(r.constraints&qe.ConnectToNearByNode||r.constraints&qe.ConnectToNearByPort)&&r.connectionPadding||0,p={},g=0,v=e.spatialSearch.findObjects(new Ne(t.x-50-d,t.y-50-d,100+d,100+d));g-1&&o.splice(T,1),"UmlClassifier"===y.shape.type&&y.container&&"Stack"===y.container.type&&(T=o.indexOf(e.nameTable[e.nameTable[y.id].wrapper.children[0].id]))>-1&&o.splice(T,1)}for(var P=0;Ps.zIndex&&(t[parseInt(r.toString(),10)]=l),r>0&&i&&a&&(a.isLane||a.isPhase||a.isHeader)&&t[parseInt(r.toString(),10)].zIndex=2)for(var d=t.length-1;d>=0;d--)if(t[parseInt(d.toString(),10)].parentId){var u=sm(t[parseInt(d.toString(),10)],e,""),p=sm(t[d-1],e,""),g=e.nameTable[""+p];g&&u!==p&&e.nameTable[""+u].zIndex=0;f--){d=Jp(e[parseInt(f.toString(),10)],!1),c=Jp(e[parseInt(f.toString(),10)],!0);var g=t[""+l].tool,v=this.findTargetElement(e[parseInt(f.toString(),10)].wrapper,o,t,void 0);if("Draw"===i&&v&&(e[parseInt(f.toString(),10)]instanceof te||e[parseInt(f.toString(),10)]instanceof de)&&!ib(e[parseInt(f.toString(),10)],v)&&(g&&"ConnectorSourceEnd"===g[""+h]&&!Nh(e[parseInt(f.toString(),10)])||g&&"ConnectorTargetEnd"===g[""+h]&&!da(e[parseInt(f.toString(),10)])))return u;if(e[parseInt(f.toString(),10)]instanceof te||e[parseInt(f.toString(),10)]instanceof de&&(Nh(e[parseInt(f.toString(),10)])||xd(d)||da(e[parseInt(f.toString(),10)])||Lh(c)||"PortDraw"===i&&g instanceof Od&&"ConnectorTargetEnd"===g[""+h]&&(da(e[parseInt(f.toString(),10)])||Lh(c))))return u=e[parseInt(f.toString(),10)],p&&(u=this.isTarget(u,t,i)),s.actualObject=u,u}else if("ConnectorTargetEnd"===i&&a){for(f=e.length-1;f>=0;f--)if(c=Jp(e[parseInt(f.toString(),10)],!0),(e[parseInt(f.toString(),10)]instanceof te||e[parseInt(f.toString(),10)]instanceof de)&&(da(e[parseInt(f.toString(),10)])||Lh(c)))return u=e[parseInt(f.toString(),10)],u=this.isTarget(u,t,i),s.actualObject=u,u}else{if(a&&("Drag"===i||t[""+l].tool instanceof ua)){var y=0;for(f=0;f=S.zIndex?u:S,y=Math.max(y,S.zIndex)):y=(u=S).zIndex)}return u&&"Bpmn"===u.shape.type&&(t.selectedItems.nodes.length>0&&"Bpmn"===t.selectedItems.nodes[0].shape.type||(u=null)),u&&(s.actualObject=u),u}if("Select"!==i&&"Pan"!==i||!t[""+l].tool)if("Pan"===i||"LayoutAnimation"===i){for(f=e.length-1;f>=0;f--)if((e[parseInt(f.toString(),10)]instanceof te||e[parseInt(f.toString(),10)]instanceof de)&&(v=this.findTargetElement(e[parseInt(f.toString(),10)].wrapper,o,t,void 0),"Pan"===i||v&&(v.id.match("_icon_content_shape$")||v.id.match("_icon_content_rect$"))))return e[parseInt(f.toString(),10)]}else u=e[e.length-1],s&&u&&(s.actualObject=u);else{for(f=e.length-1;f>=0;f--)if(e[parseInt(f.toString(),10)]instanceof de){var b=e[f-1];if(e[f-1]instanceof te&&b.ports){if((v=this.findTargetElement(b.wrapper,o,t,void 0))&&(v.id.match("_icon_content_shape$")||v.id.match("_icon_content_rect$")))return b;for(var M=0;M=0;s--){var o=t.children[parseInt(s.toString(),10)];if(o&&o.outerBounds.containsPoint(e,r||0))if(o.visible){if(o instanceof Cs){var a=this.findTargetElement(o,e,i);if(a)return a}var l="Clip"===o.style.textOverflow||"Ellipsis"===o.style.textOverflow;if(o.bounds.containsPoint(e,r||0)&&!l)return o;if(t.bounds.containsPoint(e,r||0)&&l)return o}else if(o instanceof Ke&&t&&t.id){var h=void 0;if(t.id.includes("group_container")){var c=t.id.slice(0,-15);h=i.getObject(c)}else h=i.getObject(t.id);if(eb(h,o.id))return o}}return t.bounds.containsPoint(e,r)&&"none"!==t.style.fill?t:null},n}(),Uoe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),sf=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},JF=function(n){function t(e,i,r,s){var o=n.call(this,e,i,r,s)||this;return o.objectZIndex=-1,o.zIndexTable={},o.objects=[],o}return Uoe(t,n),sf([I("")],t.prototype,"id",void 0),sf([I(!0)],t.prototype,"visible",void 0),sf([I(!1)],t.prototype,"lock",void 0),sf([I()],t.prototype,"objects",void 0),sf([I()],t.prototype,"addInfo",void 0),sf([I(-1)],t.prototype,"zIndex",void 0),t}(Ee),MT=function(n,t,e,i){return new(e||(e=Promise))(function(r,s){function o(h){try{l(i.next(h))}catch(c){s(c)}}function a(h){try{l(i.throw(h))}catch(c){s(c)}}function l(h){h.done?r(h.value):new e(function(c){c(h.value)}).then(o,a)}l((i=i.apply(n,t||[])).next())})},wT=function(n,t){var i,r,s,o,e={label:0,sent:function(){if(1&s[0])throw s[1];return s[1]},trys:[],ops:[]};return o={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function a(h){return function(c){return function l(h){if(i)throw new TypeError("Generator is already executing.");for(;e;)try{if(i=1,r&&(s=2&h[0]?r.return:h[0]?r.throw||((s=r.return)&&s.call(r),0):r.next)&&!(s=s.call(r,h[1])).done)return s;switch(r=0,s&&(h=[2&h[0],s.value]),h[0]){case 0:case 1:s=h;break;case 4:return e.label++,{value:h[1],done:!1};case 5:e.label++,r=h[1],h=[0];continue;case 7:h=e.ops.pop(),e.trys.pop();continue;default:if(!(s=(s=e.trys).length>0&&s[s.length-1])&&(6===h[0]||2===h[0])){e=0;continue}if(3===h[0]&&(!s||h[1]>s[0]&&h[1]1)for(var i=0;i-1)return e[parseInt(i.toString(),10)];return this.diagram.activeLayer},n.prototype.getLayer=function(t){for(var e=this.diagram.layers,i=0;i=0;o--)this.diagram.unSelect(this.diagram.nameTable[s[parseInt(o.toString(),10)]]),this.diagram.remove(this.diagram.nameTable[s[parseInt(o.toString(),10)]]),"default_layer"!==i.id&&this.diagram.activeLayer.id===t&&(this.diagram.activeLayer=this.diagram.layers[this.diagram.layers.length-1]);delete this.diagram.layerZIndexTable[i.zIndex],this.diagram.layers.splice(r,1),"SVG"!==this.diagram.mode&&this.diagram.refreshDiagramLayer()}},n.prototype.moveObjects=function(t,e){this.diagram.startGroupAction();for(var i={},r=[],s=0;s-1){if(r=[],(h=this.diagram.nameTable[""+s]).children)for(var f=0,g=h.children;f0){for(var y=void 0,S=0,b=r;S0)for(var r=0;r0)for(r=0;r0){t=t.concat(this.diagram.selectedItems.connectors);for(var i=0;i0)for(t=t.concat(this.diagram.selectedItems.nodes),i=0;i0){for(var i=0,r=t.shape.activity.subProcess.processes;i0&&this.copyProcesses(this.processTable[""+s])}this.clipboardData.processTable=this.processTable}},n.prototype.group=function(){this.oldSelectedObjects=rm(this.diagram);var e=this.diagram.isProtectedOnChange;this.diagram.protectPropertyChange(!0),this.diagram.diagramActions=this.diagram.diagramActions|ee.Group;var r={};r.id="group"+Qe(),(r=new te(this.diagram,"nodes",r,!0)).children=[];for(var s=this.diagram.selectedItems.nodes.concat(this.diagram.selectedItems.connectors).sort(function(h,c){return h.zIndex-c.zIndex}),o=0;o0){var a=this.diagram.add(r);a&&this.select(a),this.addHistoryEntry({type:"Group",undoObject:r,redoObject:r,category:"Internal"}),this.diagram.diagramActions=this.diagram.diagramActions&~ee.Group,this.diagram.protectPropertyChange(e)}},n.prototype.unGroup=function(t){var i=this.diagram.isProtectedOnChange;this.diagram.protectPropertyChange(!0),this.diagram.diagramActions=this.diagram.diagramActions|ee.Group;var r=[];t?r.push(t):r=this.diagram.selectedItems.nodes,this.diagram.startGroupAction();for(var s=0;s0&&this.diagram.removePorts(o,o.ports),o.annotations&&o.annotations.length>0&&!ce()&&this.diagram.removeLabels(o,o.annotations);for(var c=this.diagram.nameTable[o.parentId],d=o.children.length-1;d>=0;d--)this.diagram.nameTable[o.children[parseInt(d.toString(),10)]].parentId="",this.diagram.deleteChild(this.diagram.nameTable[o.children[parseInt(d.toString(),10)]],o),o.parentId&&o.children[parseInt(d.toString(),10)]&&this.diagram.addChild(c,o.children[parseInt(d.toString(),10)]);this.resetDependentConnectors(o.inEdges,!0),this.resetDependentConnectors(o.outEdges,!1),this.diagram.diagramActions&ee.UndoRedo||this.addHistoryEntry({type:"UnGroup",undoObject:a,redoObject:a,category:"Internal"}),o.parentId&&this.diagram.deleteChild(o,c)}this.diagram.removeNode(o,l),this.clearSelection()}this.diagram.endGroupAction(),this.diagram.diagramActions=this.diagram.diagramActions&~ee.Group,this.diagram.protectPropertyChange(i)},n.prototype.resetDependentConnectors=function(t,e){for(var i=0;i0&&(g=!1)}if(g){var y=this.cloneConnector(p,i);c.push(y),o[h.id]=y.id}}else{var S=this.cloneNode(h,i);if(c.push(S),S){o[h.id]=S.id;var b=h.inEdges;if(b)for(var M=0,w=b;M0)for(var u=0;u0)for(r=t.segments,s=0;s0&&this.diagram.drawingObject&&"Bezier"===this.diagram.drawingObject.type&&(t.segments=[]);var e=this.diagram.add(t);"SVG"!==this.diagram.mode&&this.diagram.refreshDiagramLayer(),this.selectObjects([e]),t&&!kI(this.diagram)&&(this.diagram.tool&=~Ci.DrawOnce,this.diagram.currentDrawingObject=void 0)},n.prototype.enableServerDataBinding=function(t){this.diagram.enableServerDataBinding(t)},n.prototype.addText=function(t,e){var i=this.diagram.findElementUnderMouse(t,e,this.diagram);this.diagram.startTextEdit(t,i instanceof si?i.id.split("_")[1]:void 0)},n.prototype.isUserHandle=function(t){var e=this.diagram.selectedItems;if(e.wrapper&&qr(e.constraints,"UserHandle"))for(var i=0,r=e.userHandles;i0&&t[0]&&t[0].isLane)for(s=this.diagram.getObject(t[0].parentId),t[0].shape.header=[],a=0;a1||e&&1===t.length)){if(1!==t.length)return[2];this.clearSelection()}if(!(u||d||1!==t.length||e&&Xa(this.diagram)))return this.clearSelection(),[2]}if(!r.cancel){for(p=0;p0||e)&&f.children&&!f.parentId)for(g=0;g0||e,!0)}else this.select(f,p>0||e,!0);void 0===i&&(i=c),r={oldValue:i||[],newValue:this.getSelectedObject(),cause:this.diagram.diagramActions,state:"Changed",type:"Addition",cancel:!1},this.diagram.renderSelector(e||t&&t.length>1),ce()||this.diagram.triggerEvent(Ce.selectionChange,r),this.diagram.enableServerDataBinding(!0)}return[2]})})},n.prototype.findParent=function(t){return t.parentId&&this.findParent(t=this.diagram.nameTable[t.parentId]),t},n.prototype.selectProcesses=function(t){if(this.hasProcesses(t))for(var e=t.shape.activity.subProcess.processes,i=0;i0)},n.prototype.select=function(t,e,i){var r=this.getObjectLayer(t.id);if(Dd(t)&&!(t instanceof oi)&&!_r(this.diagram,t)&&r&&!r.lock&&r.visible&&t.wrapper.visible){(e=!!Xa(this.diagram)&&e)||this.clearSelection(),this.diagram.enableServerDataBinding(!1);var s=this.diagram.selectedItems;if(t instanceof te?s.nodes.push(t.isHeader?this.diagram.nameTable[t.parentId]:t):s.connectors.push(t),s.selectedObjects.push(t),e)s.wrapper.rotateAngle=s.rotateAngle=0,s.wrapper.children.push(t.wrapper);else if(s.init(this.diagram),1===s.nodes.length&&0===s.connectors.length){var l=Ux(this.diagram,s);l&&(s.wrapper.children[0]=l),s.rotateAngle=s.nodes[0].rotateAngle,s.wrapper.rotateAngle=s.nodes[0].rotateAngle,s.wrapper.pivot=s.nodes[0].pivot}i||this.diagram.renderSelector(e),this.diagram.enableServerDataBinding(!0)}},n.prototype.labelSelect=function(t,e){this.oldSelectedObjects=rm(this.diagram);var i=this.diagram.selectedItems,r=this.diagram.allowServerDataBinding;this.diagram.allowServerDataBinding=!1,i.nodes=i.connectors=[],this.diagram.allowServerDataBinding=r,t instanceof te?i.nodes[0]=t:i.connectors[0]=t,i.annotation=this.findTarget(e,t),i.init(this.diagram),this.diagram.renderSelector(!1)},n.prototype.unSelect=function(t){var e=this.diagram.selectedItems.nodes.concat(this.diagram.selectedItems.connectors),i=e.filter(function(a){return a.id!==t.id}),r={oldValue:e,newValue:i,cause:this.diagram.diagramActions,state:"Changing",type:"Removal",cancel:!1};if(this.diagram.currentSymbol||ce()||this.diagram.triggerEvent(Ce.selectionChange,r),_r(this.diagram,t)){var s=this.diagram.selectedItems,o=void 0;t instanceof te?(o=s.nodes.indexOf(t,0),s.nodes.splice(o,1)):(o=s.connectors.indexOf(t,0),s.connectors.splice(o,1)),o=s.selectedObjects.indexOf(t,0),s.selectedObjects.splice(o,1),(r={oldValue:e,newValue:i,cause:this.diagram.diagramActions,state:"Changed",type:"Removal",cancel:(r={oldValue:e,newValue:i,cause:this.diagram.diagramActions,state:"Changed",type:"Removal",cancel:!1}).cancel}).cancel||(o=s.wrapper.children.indexOf(t.wrapper,0),s.wrapper.children.splice(o,1),this.diagram.updateSelector(),this.diagram.currentSymbol||this.diagram.triggerEvent(Ce.selectionChange,r))}},n.prototype.moveSvgNode=function(t,e){var i=xt(e+"_groupElement",this.diagram.element.id),r=xt(t+"_groupElement",this.diagram.element.id);i.parentNode.insertBefore(r,i)},n.prototype.moveAfterSvgNode=function(t,e){var i=xt(e+"_groupElement",this.diagram.element.id),r=xt(t+"_groupElement",this.diagram.element.id);i.insertAdjacentElement("afterend",r)},n.prototype.sendLayerBackward=function(t){var e=this.getLayer(t);if(e&&0!==e.zIndex){var i=e.zIndex;if("SVG"===this.diagram.mode){var r=e.objects,s=this.getLayer(this.diagram.layerZIndexTable[i-1]).objects[0];if(s)for(var o=0,a=r;od&&"SwimLane"!==f.shape.type){var S=$(f);f.zIndex=d-((-1!==i.indexOf(f)?i.indexOf(f):0)+1),f.children&&(d=this.findLowestZIndex(f,c)||d),this.triggerOrderCommand(S,f,f),f.children&&this.updateGroupZindex(f,"SendToBack",d)}else"SwimLane"===f.shape.type&&(y=this.swapZIndexObjects(a,h,r,g));if("SVG"===this.diagram.mode){for(var M="SwimLane"!==this.diagram.nameTable[""+r].shape.type?d:y,w=h[parseInt(M.toString(),10)];!w&&Md)&&(d=p.zIndex)}for(var f=JSON.parse(JSON.stringify(l)),v=Number(Object.keys(l).sort(function(wo,Hl){return Number(wo)-Number(Hl)}).reverse()[0]),y=this.diagram.nameTable[""+e].zIndex,S=[],M=0;M<=v;M++)S.push(l[parseInt(M.toString(),10)]);if("SwimLane"===this.diagram.nameTable[""+e].shape.type)for(var C=v;C>=y;C--)if(l[parseInt(C.toString(),10)]&&this.diagram.nameTable[l[parseInt(C.toString(),10)]].parentId!==e){v=C;break}var D=this.diagram.nameTable[""+e];if(D.zIndexx&&(x=L.zIndex)}}else x=d;D.zIndex=x+((-1!==r.indexOf(D)?r.indexOf(D):0)+1),this.triggerOrderCommand(A,D,D)}else if("SwimLane"===D.shape.type){for(var O=0,N=-1,T=0,P=0,_=JSON.parse(JSON.stringify(l)),B=0;B<=y;B++)if(l[parseInt(B.toString(),10)]&&this.diagram.nameTable[l[parseInt(B.toString(),10)]].parentId===e&&-1===N){N=B,T=B;break}for(var j=0;j<=v;j++)f[parseInt(j.toString(),10)]&&f[parseInt(j.toString(),10)]!==e&&this.diagram.nameTable[f[parseInt(j.toString(),10)]].parentId!==e&&this.diagram.nameTable[f[parseInt(j.toString(),10)]].zIndex>=this.diagram.nameTable[""+e].zIndex&&O++;for(var ue=N,pe=0;pe<=O;pe++){for(;!l[parseInt(ue.toString(),10)];)ue++;P=this.diagram.nameTable[l[parseInt(ue.toString(),10)]].zIndex,ue++}for(var Me=P;Me<=v;Me++){for(;!_[parseInt(N.toString(),10)];)N++;for(;!l[parseInt(Me.toString(),10)];)Me++;l[parseInt(Me.toString(),10)]=_[parseInt(N.toString(),10)],this.diagram.nameTable[l[parseInt(Me.toString(),10)]].zIndex=Me,N++}l[parseInt(v.toString(),10)]=this.diagram.nameTable[""+e].id,this.diagram.nameTable[""+e].zIndex=v,ue=y+1;for(var De=T,xe=0;xe0&&("Native"===hr[0].shape.type||"HTML"===hr[0].shape.type)){for(Mi.parentNode.removeChild(Mi),De=0;De0?r[0]:null},n.prototype.findLowestZIndex=function(t,e){var r=this.diagram.nodes.filter(function(s){return-1!==e.indexOf(s.id)}).filter(function(s){return""===s.parentId&&s.id!==t.id}).map(function(s){return s.zIndex});return r.sort(function(s,o){return s-o}),r.length>0?r[0]:null},n.prototype.triggerOrderCommand=function(t,e,i){var s={zIndex:$(t).zIndex},o={zIndex:e.zIndex},a={element:i,cause:this.diagram.diagramActions,diagramAction:this.diagram.getDiagramAction(this.diagram.diagramActions),oldValue:s,newValue:o};this.diagram.triggerEvent(Ce.propertyChange,a)},n.prototype.checkGroupNode=function(t,e,i){return i[""+e].parentId===i[""+t].parentId},n.prototype.sortByZIndex=function(t,e,i){if("BringForward"===i){var r=e||"zIndex";t=t.sort(function(o,a){return a[""+r]-o[""+r]})}else{var s=e||"zIndex";t=t.sort(function(o,a){return o[""+s]-a[""+s]})}return t},n.prototype.orderCommands=function(t,e,i){var r=this,s=e.nodes;if(s=s.concat(e.connectors),t)if("SendBackward"===i)for(var o=0;oa}),S=v.filter(function(D){return D0?Math.max.apply(Math,S):a,M=y.length>0?Math.min.apply(Math,y):a;if(a!==M){var w=c.zIndexTable[parseInt(M.toString(),10)],C=c.zIndexTable[parseInt(a.toString(),10)];this.moveSvgNode(C,w)}else"SendToBack"===i&&(w=c.zIndexTable[parseInt(a.toString(),10)],C=c.zIndexTable[parseInt(b.toString(),10)],this.moveAfterSvgNode(w,C))}}else this.diagram.refreshCanvasLayers()}},n.prototype.sendForward=function(t){var e=this;if(this.diagram.protectPropertyChange(!0),Xa(this.diagram)||t){$(t||(this.diagram.selectedItems.nodes.length?this.diagram.selectedItems.nodes[0]:this.diagram.selectedItems.connectors[0]));var s=t&&t.id,o=this.diagram.layers.indexOf(this.getObjectLayer(s=s||(this.diagram.selectedItems.nodes.length?this.diagram.selectedItems.nodes[0].id:this.diagram.selectedItems.connectors[0].id))),a=$(this.diagram.nameTable),h=(parseInt(o.toString(),10),this.diagram.nameTable[""+s]),c=[],d=this.diagram.spatialSearch.findObjects(h.wrapper.bounds);d.length>2&&(d=this.sortByZIndex(d,void 0,"BringForward"));for(var u=0,p=d;u=0;f--)this.diagram.nameTable[c[parseInt(f.toString(),10)].id].parentId===s&&c.splice(f,1);if(c.length>0){var y=this.diagram.nameTable[c[c.length-1].id];if(y.parentId){var b=sm(y,this.diagram,""),M=this.diagram.nameTable[""+b];M.id!==s&&(c[0]=M)}var w={};for(f=0;f0&&(Object.values(O).forEach(function(ue){ue>=T&&N.push(ue)}),0!==N.length&&this.updateZIndexBySendForward(h,N,o))}var P=[];if(Object.keys(this.changedNodeZIndexes).forEach(function(ue){if((a[""+ue]?a[""+ue].zIndex:null)!==e.changedNodeZIndexes[""+ue]){var De=$(a[""+ue]);P.push(De)}}),this.updateLayerZindexTable(o),L.nodes.splice(0,L.nodes.length),P.forEach(function(ue){var pe=$(ue);L.nodes.push(pe)}),"SVG"===this.diagram.mode){var _=c[c.length-1].id,B=c[c.length-1];B&&!("HTML"===B.shape.type||"Native"===B.shape.type)&&this.moveAfterSvgNode(s,_),this.updateNativeNodeIndex(_,s)}else this.diagram.refreshCanvasLayers();var j=[];Object.keys(this.changedNodeZIndexes).forEach(function(ue){if((a[""+ue]?a[""+ue].zIndex:null)!==e.changedNodeZIndexes[""+ue]){var De=$(e.diagram.nameTable[""+ue]);j.push(De)}});var Q=$(this.diagram.selectedItems);Q.nodes.splice(0,Q.nodes.length),j.forEach(function(ue){var pe=$(ue);Q.nodes.push(pe)}),this.diagram.diagramActions&ee.UndoRedo||this.addHistoryEntry({type:"SendForward",category:"Internal",undoObject:L,redoObject:Q}),this.diagram.endGroupAction()}}this.diagram.protectPropertyChange(!1)},n.prototype.updateZIndexBySendForward=function(t,e,i){var r=$(t);t.zIndex=Math.min.apply(Math,e);var a,s=Math.min.apply(Math,e),o=Math.min.apply(Math,e),l=this.diagram.layers[parseInt(i.toString(),10)].objects,h=this.diagram.nodes.filter(function(S){return-1!==l.indexOf(S.id)});t.children&&this.updateGroupZindex(t,"BringForward",t.zIndex);var c=h.filter(function(S){return S.zIndex===Math.min.apply(Math,e)&&S.id!==t.id});if(c&&c.length>0&&c[0].children){for(var d=Math.min.apply(Math,e),u=0;uo&&g!==t&&g.parentId!==t.id&&c&&c.length>0&&g.parentId!==c[0].id){var v=$(g);g.zIndex=a+1,a++,this.triggerOrderCommand(v,g,g)}var y=g.zIndex;this.changedNodeZIndexes[g.id]=(this.changedNodeZIndexes.hasOwnProperty(g.id),y)}},n.prototype.arrangeZIndexForLowerNodes=function(t,e,i){var r=i.filter(function(o){return o.zIndex<=t&&o.parentId!==e.id});r.sort(function(o,a){return a.zIndex-o.zIndex});for(var s=0;se&&(e=r.zIndex)}return e},n.prototype.sendBackward=function(t){var e=this;if(this.diagram.protectPropertyChange(!0),Xa(this.diagram)||t){$(t||(this.diagram.selectedItems.nodes.length?this.diagram.selectedItems.nodes[0]:this.diagram.selectedItems.connectors[0]));var s=t&&t.id,o=this.diagram.layers.indexOf(this.getObjectLayer(s=s||(this.diagram.selectedItems.nodes.length?this.diagram.selectedItems.nodes[0].id:this.diagram.selectedItems.connectors[0].id))),a=$(this.diagram.nameTable),h=(parseInt(o.toString(),10),this.diagram.nameTable[""+s]),c=[],d=this.diagram.spatialSearch.findObjects(h.wrapper.bounds);d.length>2&&(d=this.sortByZIndex(d));for(var u=0,p=d;uNumber(f.zIndex)&&""===f.parentId&&h.wrapper.bounds.intersects(f.wrapper.bounds)&&c.push(f);for(var f=c.length-1;f>=0;f--)(v=this.diagram.nameTable[c[parseInt(f.toString(),10)].id]).parentId===s&&c.splice(f,1);if(c.length>0){var v;if((v=this.diagram.nameTable[c[c.length-1].id]).parentId){var S=sm(v,this.diagram,""),b=this.diagram.nameTable[""+S];s!==b.id&&(c[c.length-1]=b)}var M={};for(f=0;f0&&(Object.values(L).forEach(function(pe){pe<=N&&O.push(pe)}),0!==O.length&&this.updateZIndexBySendBackward(h,O,o))}var T=[];if(Object.keys(this.changedNodeZIndexes).forEach(function(pe){if((a[""+pe]?a[""+pe].zIndex:null)!==e.changedNodeZIndexes[""+pe]){var xe=$(a[""+pe]);T.push(xe)}}),this.updateLayerZindexTable(o),R.nodes.splice(0,R.nodes.length),T.forEach(function(pe){var Me=$(pe);R.nodes.push(Me)}),"SVG"===this.diagram.mode){var P=c[c.length-1].id,_=c[c.length-1];_&&"HTML"!==_.shape.type&&"Native"!==_.shape.type&&this.moveSvgNode(s,P);var B=this.diagram.nameTable[""+P];B.children&&B.children.length>0?this.updateNativeNodeIndex(s):this.updateNativeNodeIndex(s,P)}else this.diagram.refreshCanvasLayers();var j=[];Object.keys(this.changedNodeZIndexes).forEach(function(pe){if((a[""+pe]?a[""+pe].zIndex:null)!==e.changedNodeZIndexes[""+pe]){var xe=$(e.diagram.nameTable[""+pe]);j.push(xe)}});var Q=$(this.diagram.selectedItems);Q.nodes.splice(0,Q.nodes.length),j.forEach(function(pe){var Me=$(pe);Q.nodes.push(Me)}),this.diagram.diagramActions&ee.UndoRedo||this.addHistoryEntry({type:"SendBackward",category:"Internal",undoObject:R,redoObject:Q}),this.diagram.endGroupAction()}}this.diagram.protectPropertyChange(!1)},n.prototype.updateZIndexBySendBackward=function(t,e,i){var r=$(t);t.zIndex=Math.max.apply(Math,e);var p,s=t.zIndex,o=Math.max.apply(Math,e),a=this.diagram.layers[parseInt(i.toString(),10)].objects,l=this.diagram.nodes.filter(function(S){return-1!==a.indexOf(S.id)}),h=l.filter(function(S){return S.zIndex===Math.max.apply(Math,e)&&S.id!==t.id});if(h&&h.length>0&&h[0].children)for(var c=Math.max.apply(Math,e),d=0;d0&&g.parentId!==h[0].id){var v=$(g);g.zIndex=p-1,p--,this.triggerOrderCommand(v,g,g)}var y=g.zIndex;this.changedNodeZIndexes[""+g.id]=(this.changedNodeZIndexes.hasOwnProperty(g.id),y)}},n.prototype.findLowestChildZIndex=function(t){for(var e=t.zIndex,i=0;i0),this.selectObjects([t],!0))},n.prototype.clearSelection=function(t,e){return MT(this,void 0,void 0,function(){var i,r,s,o;return wT(this,function(a){return i=this.diagram.allowServerDataBinding,this.diagram.enableServerDataBinding(!1),Xa(this.diagram)&&(r=this.diagram.selectedItems,s=this.getSelectedObject(),this.diagram.currentSymbol&&(this.diagram.previousSelectedObject=s),o={oldValue:s,newValue:[],cause:this.diagram.diagramActions,state:"Changing",type:"Removal",cancel:!1},t&&(ce()||this.diagram.triggerEvent(Ce.selectionChange,o)),o.cancel||(r.offsetX=0,r.offsetY=0,r.width=0,r.height=0,r.rotateAngle=0,r.nodes=[],r.connectors=[],r.wrapper=null,r.annotation=void 0,r.selectedObjects=[],this.diagram.clearSelectorLayer(),t&&(o={oldValue:s,newValue:[],cause:this.diagram.diagramActions,state:"Changed",type:"Removal",cancel:!1},ce()||this.diagram.triggerEvent(Ce.selectionChange,o))),this.diagram.enableServerDataBinding(i)),[2]})})},n.prototype.clearSelectedItems=function(){this.clearSelection((this.diagram.selectedItems.nodes?this.diagram.selectedItems.nodes.length:0)+(this.diagram.selectedItems.connectors?this.diagram.selectedItems.connectors.length:0)>0)},n.prototype.removeStackHighlighter=function(){var t=Pl(this.diagram.element.id),e=t.getElementById(t.id+"_stack_highlighter");e&&e.parentNode.removeChild(e)},n.prototype.renderStackHighlighter=function(t,e){var r,s,o,i=this.diagram.selectedItems.nodes[0];if(!e){var a=this.diagram.findObjectsUnderMouse(t.position);if((e=this.diagram.findObjectUnderMouse(a,"Drag",!0))&&!(e.isLane||e.isPhase||e.isHeader))for(var l=0;l0)for(var a=0;a1)if(i){var h=l.segments[0],c=l.segments[1],u=Tc(MI(t.wrapper,t.wrapper.corners,t.wrapper.bounds),h.direction),g=Ll({corners:void 0,point:u=Ah(l,0,u,{x:l.sourceWrapper.offsetX,y:l.sourceWrapper.offsetY},!1),margin:void 0,direction:h.direction},{corners:void 0,point:c.points[1],margin:void 0,direction:void 0});h.length=z.distancePoints(g[0],g[1]),c.direction&&c.length&&(c.length=z.distancePoints(g[1],g[2]))}else if(o){switch(l.segments[0].direction){case"Bottom":r=t.wrapper.bounds.bottomCenter.x-e.bottomCenter.x,s=t.wrapper.bounds.bottomCenter.y-e.bottomCenter.y;break;case"Top":r=t.wrapper.bounds.topCenter.x-e.topCenter.x,s=t.wrapper.bounds.topCenter.y-e.topCenter.y;break;case"Left":r=t.wrapper.bounds.middleLeft.x-e.middleLeft.x,s=t.wrapper.bounds.middleLeft.y-e.middleLeft.y;break;case"Right":r=t.wrapper.bounds.middleRight.x-e.middleRight.x,s=t.wrapper.bounds.middleRight.y-e.middleRight.y}this.dragSourceEnd(l,r,s,!0,null,"ConnectorSourceEnd",void 0,void 0,void 0,!(t.parentId&&this.diagram.diagramActions&ee.isGroupDragging))}}},n.prototype.updateEndPoint=function(t,e){var r={sourcePoint:t.sourcePoint,targetPoint:t.targetPoint};t.sourceID&&(r.sourceID=t.sourceID),t.targetID&&(r.targetID=t.targetID),t.sourcePortID&&(r.sourcePortID=t.sourcePortID),t.targetPortID&&(r.targetPortID=t.targetPortID),t.segments&&(r.segments=t.segments),this.diagram.connectorPropertyChange(t,e||{},r),this.diagram.updateSelector()},n.prototype.dragSourceEnd=function(t,e,i,r,s,o,a,l,h,c,d){var u=this.diagram.nameTable[t.id],p={},f=this.checkBoundaryConstraints(e,i,u.wrapper.bounds);if(xI(u)&&f&&"BezierSourceThumb"!==o&&Vv(this.diagram)&&(p=$(p={sourcePoint:u.sourcePoint}),u.sourcePoint.x+=e,u.sourcePoint.y+=i,"ConnectorSourceEnd"===o&&"Orthogonal"===u.type&&this.changeSegmentLength(u,l,h,c),"Bpmn"===u.shape.type&&"Default"===u.shape.sequence&&"Sequence"===u.shape.flow&&this.updatePathElementOffset(u)),"Bezier"===u.type)if(p={sourcePoint:u.sourcePoint},d)this.translateBezierPoints(t,""===o?"ConnectorSourceEnd":o,e,i,d,s,!a);else for(var g=0;g2){var d=z.direction((c=t.segments[2]).points[0],c.points[1]);o.direction===ls(d)?("Right"===o.direction?c.points[0].x=o.points[o.points.length-1].x=l.wrapper.corners.middleRight.x+20:"Left"===o.direction?c.points[0].x=o.points[o.points.length-1].x=l.wrapper.corners.middleLeft.x-20:c.points[0].y=o.points[o.points.length-1].y="Top"===o.direction?l.wrapper.corners.topCenter.y-20:l.wrapper.corners.bottomCenter.y+20,c.direction&&c.length&&(c.length=z.distancePoints(c.points[0],c.points[c.points.length-1])),o.length=z.distancePoints(o.points[0],o.points[o.points.length-1])):o.direction===d&&c.direction&&c.length?("Top"===o.direction||"Bottom"===o.direction?(c.points[0]=o.points[0],c.points[c.points.length-1].x=c.points[0].x):(c.points[0]=o.points[0],c.points[c.points.length-1].y=c.points[0].y),c.length=z.distancePoints(c.points[0],c.points[c.points.length-1]),t.segments.splice(0,2)):o.length=20}else o.length=20;else if(o.length<1)if(""!==t.sourceID){var c;"Right"===a.direction?a.points[a.points.length-1].y=(h=l.wrapper.corners.middleRight).y:"Left"===a.direction?a.points[a.points.length-1].y=(h=l.wrapper.corners.middleLeft).y:a.points[a.points.length-1].x="Top"===a.direction?(h=l.wrapper.corners.topCenter).x:(h=l.wrapper.corners.bottomCenter).x,a.length=z.distancePoints(h,a.points[a.points.length-1]),t.segments.length>2&&(c=t.segments[2]).direction&&c.length&&(c.length=z.distancePoints(a.points[a.points.length-1],c.points[c.points.length-1])),t.segments.splice(0,1)}else t.segments.splice(0,1)}else e&&!i&&t.sourceID!==e.id&&t.segments&&null!==t.segments[0].direction&&e&&e instanceof te&&s&&this.changeSourceEndToNode(t,e),e&&i&&t.sourcePortID!==i&&t.segments&&null!==t.segments[0].direction&&e&&e instanceof te&&s&&this.changeSourceEndToPort(t,e,i)},n.prototype.canConnect=function(t,e){return!(!da(e)||!Nh(e))},n.prototype.changeSourceEndToPort=function(t,e,i){var r=this.diagram.getWrapper(e.wrapper,i),s={x:r.offsetX,y:r.offsetY},o=zo(s,En(e.wrapper),e.wrapper.bounds),a=t.segments[0],l=t.segments[1];if(a.direction!==o){var h=[],c={};if(a.direction===ls(o)){c={};var d=void 0;"Top"===o||"Bottom"===o?(d="Top"===o?{type:"Orthogonal",isTerminal:!0,direction:o,length:Math.abs(a.points[0].y-s.y)}:{type:"Orthogonal",isTerminal:!0,direction:o,length:Math.abs(s.y-a.points[0].y)},c=a.points[0].x>s.x?{type:"Orthogonal",isTerminal:!0,direction:"Right",length:a.points[0].x-s.x}:{type:"Orthogonal",isTerminal:!0,direction:"Left",length:s.x-a.points[0].x}):(d="Right"===o?{type:"Orthogonal",isTerminal:!0,direction:o,length:Math.abs(a.points[0].x-s.x)}:{type:"Orthogonal",isTerminal:!0,direction:o,length:Math.abs(s.x-a.points[0].x)},c=a.points[0].y>s.y?{type:"Orthogonal",direction:"Top",isTerminal:!0,length:a.points[0].y-s.y}:{type:"Orthogonal",direction:"Bottom",isTerminal:!0,length:s.y-a.points[0].y}),h.push(new bi(t,"segments",d,!0)),h.push(new bi(t,"segments",c,!0))}else h.push(new bi(t,"segments",c={type:"Orthogonal",direction:o,length:20,isTerminal:!0},!0));a.direction!==ls(o)&&("Top"===o||"Bottom"===o?(a.points[0].x=s.x,a.points[0].y=a.points[a.points.length-1].y="Top"===o?s.y-20:s.y+20):(a.points[0].y=s.y,a.points[0].x=a.points[a.points.length-1].x="Right"===o?s.x+20:s.x-20),a.length=z.distancePoints(a.points[0],a.points[a.points.length-1]),l.length=z.distancePoints(a.points[a.points.length-1],l.points[l.points.length-1])),t.segments=h.concat(t.segments)}else a.points[0]=s,"Top"===o||"Bottom"===o?a.points[a.points.length-1].x=s.x:a.points[a.points.length-1].y=s.y,a.length=z.distancePoints(a.points[0],a.points[a.points.length-1]),l.length=z.distancePoints(a.points[a.points.length-1],l.points[l.points.length-1])},n.prototype.removeTerminalSegment=function(t,e){for(var i=0;ii.width||"Left"===o.direction&&r.x>=o.points[0].x||"Right"===o.direction&&r.x<=o.points[0].x)o.points[0].y=o.points[o.points.length-1].y=r.y,o.points[0].x=r.x,o.length=z.distancePoints(o.points[0],o.points[o.points.length-1]),a.length=z.distancePoints(o.points[o.points.length-1],a.points[a.points.length-1]);else{var h=void 0;s="Bottom"===(h=a.direction?a.direction:z.direction(a.points[0],a.points[a.points.length-1]))?i.bottomCenter:i.topCenter,a.length&&a.direction&&(a.length="Top"===h?o.points[o.points.length-1].y-(s.y+20):s.y+20-o.points[o.points.length-1].y),o.length=o.points[o.points.length-1].x-s.x,o.direction=o.length>0?"Right":"Left",l.push(new bi(t,"segments",{type:"Orthogonal",direction:h,length:20},!0)),t.segments=l.concat(t.segments)}else r="Bottom"===o.direction?i.bottomCenter:i.topCenter,o.length>i.height||"Top"===o.direction&&r.y>=o.points[0].y||"Bottom"===o.direction&&r.y<=o.points[0].y?(o.points[0].x=o.points[o.points.length-1].x=r.x,o.points[0].y=r.y,o.length=z.distancePoints(o.points[0],o.points[o.points.length-1]),a.length=z.distancePoints(o.points[o.points.length-1],a.points[a.points.length-1])):(s="Left"===a.direction?i.middleLeft:i.middleRight,h=void 0,h=a.direction?a.direction:z.direction(a.points[0],a.points[a.points.length-1]),a.length&&a.direction&&(a.length="Left"===h?o.points[o.points.length-1].x-(s.x+20):s.x+20-o.points[o.points.length-1].x),o.length=o.points[o.points.length-1].y-s.y,o.direction=o.length>0?"Bottom":"Top",l.push(new bi(t,"segments",{type:"Orthogonal",direction:h,length:20},!0)),t.segments=l.concat(t.segments))},n.prototype.translateBezierPoints=function(t,e,i,r,s,o,a){var l=t.segments.indexOf(s),h=t.segments[parseInt(l.toString(),10)],c=l>0?t.segments[l-1]:null,d=null!==c?c.point:t.sourcePoint,u=l===t.segments.length-1?t.targetPoint:h.point;if(h)if("BezierSourceThumb"===e&&(h.vector1.angle||h.vector1.distance)){var p=h.vector1.distance,f=h.vector1.angle;h.vector1={distance:t.distance(d,o),angle:z.findAngle(d,o)},this.translateSubsequentSegment(t,s,!0,h.vector1.distance-p,h.vector1.angle-f)}else"BezierTargetThumb"===e&&(h.vector2.angle||h.vector2.distance)?(p=h.vector2.distance,f=h.vector2.angle,h.vector2={distance:t.distance(u,o),angle:z.findAngle(u,o)},this.translateSubsequentSegment(t,s,!1,h.vector2.distance-p,h.vector2.angle-f)):("ConnectorSourceEnd"===e&&!t.sourceID||"ConnectorTargetEnd"===e&&!t.targetID)&&a&&QI(h.vector1)&&QI(h.vector2)?(z.isEmptyPoint(h.point1)&&(h.bezierPoint1=GI(t.sourcePoint,t.targetPoint)),z.isEmptyPoint(h.point2)&&(h.bezierPoint2=GI(t.targetPoint,t.sourcePoint))):"BezierSourceThumb"===e||"ConnectorSourceEnd"===e&&!a&&QI(h.vector1)?(h.bezierPoint1.x+=i,h.bezierPoint1.y+=r,(!z.isEmptyPoint(h.point1)||a)&&(h.point1={x:h.bezierPoint1.x,y:h.bezierPoint1.y})):("BezierTargetThumb"===e||"ConnectorTargetEnd"===e&&!a&&QI(h.vector2))&&(h.bezierPoint2.x+=i,h.bezierPoint2.y+=r,(!z.isEmptyPoint(h.point2)||a)&&(h.point2={x:h.bezierPoint2.x,y:h.bezierPoint2.y}))},n.prototype.translateSubsequentSegment=function(t,e,i,r,s){var o=t.segments.indexOf(e);parseInt(o.toString(),10),t.bezierSettings.smoothness&mI.SymmetricAngle||(s=null),t.bezierSettings.smoothness&mI.SymmetricDistance||(r=null),(null!=r||null!=s)&&(i?0!==o&&this.updatePreviousBezierSegment(t,o,r,s):o!==t.segments.length-1&&this.updateNextBezierSegment(t,o,r,s))},n.prototype.updatePreviousBezierSegment=function(t,e,i,r){var s=t.segments[e-1],a=(s.vector2.angle+r)%360;a<0&&(a+=360),s.vector2={distance:s.vector2.distance+i,angle:a}},n.prototype.updateNextBezierSegment=function(t,e,i,r){var s=t.segments[e+1],a=(s.vector1.angle+r)%360;a<0&&(a+=360),s.vector1={distance:s.vector1.distance+i,angle:a}},n.prototype.dragTargetEnd=function(t,e,i,r,s,o,a,l){var c,h=this.diagram.nameTable[t.id],d=this.checkBoundaryConstraints(e,i,h.wrapper.bounds);if(TI(h)&&"BezierTargetThumb"!==o&&d&&Vv(this.diagram)){if(c=$(c={targetPoint:h.targetPoint}),h.targetPoint.x+=e,h.targetPoint.y+=i,"ConnectorTargetEnd"===o&&"Orthogonal"===h.type&&h.segments&&h.segments.length>0){var u=h.segments[h.segments.length-2];u&&2===h.segments[h.segments.length-1].points.length&&("Left"===u.direction||"Right"===u.direction?u.points[u.points.length-1].x=h.targetPoint.x:u.points[u.points.length-1].y=h.targetPoint.y,u.length=z.distancePoints(u.points[0],u.points[u.points.length-1]),u.direction=z.direction(u.points[0],u.points[u.points.length-1]))}"Bpmn"===h.shape.type&&"Default"===h.shape.sequence&&"Sequence"===h.shape.flow&&this.updatePathElementOffset(h)}if("Bezier"===h.type)if(c={targetPoint:h.targetPoint},l)this.translateBezierPoints(t,""===o?"ConnectorTargetEnd":o,e,i,l,s,!a);else for(var p=0;p0){if(void 0!==s&&o.segments[parseInt(s.toString(),10)])if("Bezier"===o.type){var a=o.segments[parseInt(s.toString(),10)],l=a.isInternalSegment;l&&null!==o.bezierSettings&&"FreeForm"!==o.bezierSettings.segmentEditOrientation?("Horizontal"===a.orientation?a.point.x+=e:a.point.y+=i,this.updateDirectionalBezierCurve(o)):(a.point.x+=e,a.point.y+=i),l&&(o.isBezierEditing=!0)}else o.segments[parseInt(s.toString(),10)].point.x+=e,o.segments[parseInt(s.toString(),10)].point.y+=i;else for(var h=0;h1){var a=e[1],l=e[2],h={x:.5*(a.x+l.x),y:.5*(a.y+l.y)},c=t.segments[0];c.vector1.angle=Xt(s,a),c.vector1.distance=.5*z.findLength(s,a),c.vector2.angle=Xt(h,a),c.vector2.distance=.5*z.findLength(h,a),c.point=h;var d=t.segments[1];if(d.vector1.angle=Xt(h,l),d.vector1.distance=.5*z.findLength(h,l),t.segments.length>2){var u=e[3],p={x:.5*(l.x+u.x),y:.5*(l.y+u.y)};d.vector2.angle=Xt(p,l),d.vector2.distance=.5*z.findLength(p,l),d.point=p;var f=t.segments[2];if(f.vector1.angle=Xt(p,u),f.vector1.distance=.5*z.findLength(p,u),t.segments.length>3){var g=e[4],v={x:.5*(u.x+g.x),y:.5*(u.y+g.y)};f.vector2.angle=Xt(v,u),f.vector2.distance=.5*z.findLength(v,u),f.point=v;var y=t.segments[3];y.vector1.angle=Xt(v,g),y.vector1.distance=.5*z.findLength(v,g),y.vector2.angle=Xt(o,g),y.vector2.distance=.5*z.findLength(o,g)}else f.vector2.angle=Xt(o,u),f.vector2.distance=.5*z.findLength(o,u)}else d.vector2.angle=Xt(o,l),d.vector2.distance=.5*z.findLength(o,l)}},n.prototype.rotateObjects=function(t,e,i,r,s){r=r||{};var o=Hi();qi(o,i,r.x,r.y);for(var l=0,h=e;l0){this.diagram.protectPropertyChange(!0);var o=t;o.segments=[],this.diagram.connectorPropertyChange(o,{},{segments:o.segments}),this.diagram.protectPropertyChange(!1)}}},n.prototype.updateInnerParentProperties=function(t){var r=this.diagram.isProtectedOnChange;this.diagram.protectPropertyChange(!0);for(var s=this.getAllDescendants(t,[],!1,!0),o=0;o0&&(p=this.diagram.bpmnModule.getChildrenBound(d,d.id,this.diagram),u=d.wrapper.bounds.containsRect(p)),h=d.wrapper.actualSize.width*t,c=d.wrapper.actualSize.height*e,void 0!==d.maxWidth&&0!==d.maxWidth&&(h=Math.min(d.maxWidth,h)),void 0!==d.minWidth&&0!==d.minWidth&&(h=Math.max(d.minWidth,h)),void 0!==d.maxHeight&&0!==d.maxHeight&&(c=Math.min(d.maxHeight,c)),void 0!==d.minHeight&&0!==d.minHeight&&(c=Math.max(d.minHeight,c)),u&&(h=Math.max(h,p.right-d.wrapper.bounds.x),c=Math.max(c,p.bottom-d.wrapper.bounds.y)),t=h/d.actualSize.width,e=c/d.actualSize.height}var f=Hi();o||(o=r);var g=o.wrapper;if(qi(f,-g.rotateAngle,i.x,i.y),Wp(f,t,e,i.x,i.y),qi(f,g.rotateAngle,i.x,i.y),r instanceof te){var d,v=Je(f,{x:(d=r).wrapper.offsetX,y:d.wrapper.offsetY}),y=d.wrapper.offsetX-d.wrapper.actualSize.width*d.pivot.x,S=d.wrapper.offsetY-d.wrapper.actualSize.height*d.pivot.y;if(h>0)if(d.processId){var b=this.diagram.nameTable[d.processId];(!b.maxWidth||d.margin.left+h0)if(d.processId){var M=this.diagram.nameTable[d.processId];(!M.maxHeight||d.margin.top+c0){if(e.dragLimit=e.dragLimit?e.dragLimit:{},e.dragLimit.top||e.dragLimit.bottom||e.dragLimit.left||e.dragLimit.right){var b={minDistance:null};S=this.getRelativeOffset(v,d,b);var M={minDistance:null};g=this.getRelativeOffset(v,y,M),S=null!=b&&M.minDistance0){if(S=y[y.length-1]){var b=void 0;for(b=0;b=e.x-t.dragLimit.left-r.width/2&&i.x<=e.x+t.dragLimit.right+r.width/2&&(s=!0),i.y>=e.y-t.dragLimit.top-r.height/2&&i.y<=e.y+t.dragLimit.bottom+r.height/2&&(o=!0),{x:s,y:o}},n.prototype.updateLabelMargin=function(t,e,i,r,s,o,a){if(i=i||{x:e.offset,y:0},e&&i&&i.x>0&&i.x<1){var l=z.getLengthFromListOfPoints(t.intermediatePoints),h=this.getPointAtLength(l*i.x,t.intermediatePoints,0),c=this.diagram.scrollSettings.currentZoom,d=e.dragLimit?e.dragLimit:{left:0,right:0,top:0,bottom:0};if(d.top||d.bottom||d.left||d.right){this.diagram.getWrapper(t.wrapper,e.id);var p=new Ne(0,0,0,0),f=this.diagram.getWrapper(t.wrapper,e.id);p.x=f.offsetX/c+o,p.y=f.offsetY/c+a,p.width=f.bounds.width/c,p.height=f.bounds.height/c;var g=new Ne(h.x-(d.left||0)-p.width/2,h.y-(d.top||0)-p.height/2,(d.left||0)+(d.right||0)+p.width,(d.top||0)+(d.bottom||0)+p.height);if(g.containsPoint(r));else for(var S=0,b=this.boundsInterSects([h,r],g,!1);S=t){c=t-r,d=z.findAngle(s,a),u=c*Math.cos(d*Math.PI/180),p=c*Math.sin(d*Math.PI/180),o={x:s.x+u,y:s.y+p};break}r+=h,s=a}else s=a;return o},n.prototype.getInterceptWithSegment=function(t,e){for(var o,a,i=[],r=[],s=[],l=z.findLength({x:0,y:0},{x:this.diagram.scroller.viewPortWidth,y:this.diagram.scroller.viewPortHeight}),h=1;h0&&a<=90||a>180&&a<=270?90:-90;r.push(z.transform(t,a+c,l)),r.push(z.transform(t,o+c,l));var p=em({x1:s[0].x,y1:s[0].y,x2:s[1].x,y2:s[1].y},{x1:r[0].x,y1:r[0].y,x2:r[1].x,y2:r[1].y});p.enabled&&i.push(p.intersectPt)}return i},n.prototype.getAnnotationChanges=function(t,e){var r={};return r[tb(t,e.id,!0)]={width:e.width,height:e.height,offset:t instanceof te?{x:e.offset.x,y:e.offset.y}:e.offset,rotateAngle:e.rotateAngle,margin:{left:e.margin.left,right:e.margin.right,top:e.margin.top,bottom:e.margin.bottom},horizontalAlignment:e.horizontalAlignment,verticalAlignment:e.verticalAlignment,alignment:t instanceof de?e.alignment:void 0},{annotations:r}},n.prototype.getConnectorPortChanges=function(t,e){var i=function kse(n,t,e){for(var i=n.ports,r=0;r1&&(v.width=g,v.offset.x=1/S),f>1&&(v.height=f,v.offset.y=1/b)}}e instanceof Nr&&(e.alignment="Center"),l=this.getAnnotationChanges(t,e),t instanceof te?this.diagram.nodePropertyChange(t,a,l):this.diagram.connectorPropertyChange(t,a,l),this.diagram.updateDiagramObject(t)},n.prototype.getSubProcess=function(t){var i,e={nodes:[],connectors:[]};return t instanceof te?i=t.processId:t&&t.nodes&&t.nodes.length&&t.nodes[0].processId&&(i=t.nodes[0].processId),i&&e.nodes.push($(this.diagram.nameTable[i])),e},n.prototype.checkBoundaryConstraints=function(t,e,i,r){var s=this.diagram.pageSettings,o=this.diagram.pageSettings.boundaryConstraints,a=this.diagram.scroller;if("Page"===o||"Diagram"===o){var l=i?void 0:this.diagram.selectedItems.wrapper.bounds;return!!((i?i.right:l.right)+(t||0)<=("Page"===o?s.width:a.viewPortWidth)&&(i?i.left:l.left)+(t||0)>=0&&(i?i.bottom:l.bottom)+(e||0)<=("Page"===o?s.height:a.viewPortHeight)&&(i?i.top:l.top)+(e||0)>=0||"None"!==this.diagram.layout.type&&r)}return!0},n.prototype.dragSelectedObjects=function(t,e){var i=this,r=this.diagram.selectedItems;this.state&&!this.state.backup&&(this.state.backup={},this.state.backup.offsetX=r.offsetX,this.state.backup.offsetY=r.offsetY),r=UI(this.diagram,r)||r;var s=this.diagram.selectedItems.nodes.filter(function(c){return"SwimLane"===c.shape.type});if(s.length>0&&!this.diagram.currentSymbol&&this.diagram.selectedItems.nodes.length>1){var o=this.diagram.selectedItems.nodes.filter(function(c){return""===c.parentId||"SwimLane"!==i.diagram.nameTable[c.parentId].shape.type});if(o.length>0){for(var a=0;a0||l.length>1)&&(o=o.concat(l),this.diagram.selectedItems.nodes.splice(0,this.diagram.selectedItems.nodes.length),o.forEach(function(c){i.diagram.selectedItems.nodes.push(c)}),r=this.diagram.selectedItems,this.diagram.selectedObject.helperObject=void 0)}}if(this.checkBoundaryConstraints(t,e)){this.diagram.diagramActions=this.diagram.diagramActions|ee.PreventZIndexOnDragging|ee.DragUsingMouse;var h=this.diagram.selectedObject.actualObject;return(h&&h instanceof te&&h.isLane&&Vx(h,this.diagram)||!h||!h.isLane)&&this.diagram.drag(r,t,e),this.diagram.diagramActions=this.diagram.diagramActions&~(ee.PreventZIndexOnDragging|ee.DragUsingMouse),this.diagram.refreshCanvasLayers(),this.checkHtmlObjectDrag(r),!0}return!1},n.prototype.checkHtmlObjectDrag=function(t){var e=!1;this.diagram.views&&this.diagram.views.length>1&&(t instanceof oi?e=t.nodes.some(function(i){return i.shape&&"HTML"===i.shape.type}):t.shape&&"HTML"===t.shape.type&&(e=!0),e&&this.resetOverviewCanvas())},n.prototype.resetOverviewCanvas=function(){for(var t=0,e=this.diagram.views;t0&&(this.layoutAnimateModule.stopCurrentAnimation(this.objectStore[0],e,t),this.objectStore=[]),a=this.diagram.doLayout(),this.objectStore.push(a)),this.canUpdateTemplate=!1,this.diagram.blazorActions&=~on.expandNode,this.diagram.preventNodesUpdate=r,this.diagram.layoutAnimateModule&&this.diagram.organizationalChartModule&&!i)this.diagram.allowServerDataBinding=!1,this.layoutAnimateModule.expand(this.diagram.layout.enableAnimation,a,t,this.diagram);else{var l={element:$(t),state:!!t.isExpanded};this.triggerEvent(Ce.expandStateChange,l),this.diagram.lineRoutingModule&&this.diagram.constraints&rt.LineRouting&&"ComplexHierarchicalTree"!==this.diagram.layout.type&&this.diagram.resetSegments()}return this.diagram.layout.fixedNode=""===o?"":this.diagram.layout.fixedNode,a},n.prototype.getparentexpand=function(t,e,i,r){for(var s,o=0;o0&&(this.diagram.selectedItems.wrapper.rotateAngle=this.diagram.selectedItems.rotateAngle=s.rotateAngle),r instanceof te&&"SwimLane"!==r.shape.type&&!r.isLane&&!r.isPhase&&!r.isHeader)(r.offsetX!==r.wrapper.offsetX||r.offsetY!==r.wrapper.offsetY||r.width!==r.wrapper.width||r.height!==r.wrapper.height||r.rotateAngle!==r.wrapper.rotateAngle)&&(r.offsetX+=o,r.offsetY+=a,r.width+=l,r.height+=h,r.rotateAngle+=c,this.diagram.nodePropertyChange(r,{},{offsetX:r.offsetX,offsetY:r.offsetY,width:r.width,height:r.height,rotateAngle:r.rotateAngle})),e=this.diagram.spatialSearch.findObjects(r.wrapper.outerBounds);else if(r instanceof oi)for(var d=0;d30||g.wrapper.outerBounds.topCenter.y-f.wrapper.outerBounds.bottomCenter.y>30)&&this.diagram.lineRoutingModule.refreshConnectorSegments(this.diagram,p,!0)}}this.updateSelector(),this.diagram.protectPropertyChange(!1)}},n.prototype.drawSelectionRectangle=function(t,e,i,r){this.diagram.drawSelectionRectangle(t,e,i,r)},n.prototype.startGroupAction=function(){this.diagram.startGroupAction()},n.prototype.endGroupAction=function(){this.diagram.endGroupAction()},n.prototype.removeChildFromBPmn=function(t,e,i){var r=this.diagram.nameTable[t.id]||t.nodes[0];if(i&&r&&r.processId&&r.processId===i.wrapper.id){var s=$(r);s.processId=r.processId,this.diagram.startGroupAction();var o=this.diagram.nameTable[r.processId].shape.activity.subProcess.processes||[];o.splice(o.indexOf(r.id),1),this.diagram.bpmnModule.removeChildFromBPMN(this.diagram.nameTable[r.processId].wrapper,r.id,this.diagram),this.diagram.nameTable[r.id].processId="",r.offsetX=r.wrapper.offsetX,r.offsetY=r.wrapper.offsetY;var a=$(r);this.addHistoryEntry({type:"PositionChanged",redoObject:{nodes:[a]},undoObject:{nodes:[s]},category:"Internal"}),this.diagram.endGroupAction()}},n.prototype.isDroppable=function(t,e){var i=this.diagram.nameTable[t.id]||t.nodes[0];return i instanceof te&&(!ce()&&"TextAnnotation"===i.shape.shape||("Group"===e.shape.shape&&(e.shape.activity.subProcess.collapsed=!1),!(i&&"Bpmn"===i.shape.type&&(i.processId===e.id||i.id===e.processId||"Bpmn"===e.shape.type&&!(e instanceof de)&&e.shape.activity&&e.shape.activity.subProcess&&e.shape.activity.subProcess.collapsed))))},n.prototype.renderHighlighter=function(t,e,i){if(new Ne,t.target instanceof te||t.target instanceof de||e&&(t.source instanceof te||t.source instanceof de)){var a=this.findTarget(e?t.sourceWrapper:t.targetWrapper,e?t.source:t.target,i,!0),l=void 0;if(a instanceof zd)for(var h=a.id,c=t.target,u=0,p=c.wrapper.children[0].children[0].children[2].children;u0){var r=0;t[0]=this.diagram.nameTable[t[0].id]||t[0];var s="Object"===i?yr(t[0].wrapper):this.diagram.selectedItems.wrapper.bounds,o={nodes:[],connectors:[]},a={nodes:[],connectors:[]};for(r="Object"===i?r+1:r;r0){var i=0,r=0,s=0,o=0,a=0,l=0,h=0,c=0,d={nodes:[],connectors:[]},u={nodes:[],connectors:[]};for(i=0;io.center.y&&(r=n[parseInt(e.toString(),10)],n[parseInt(e.toString(),10)]=n[parseInt(i.toString(),10)],n[parseInt(i.toString(),10)]=r):s.center.x>o.center.x&&(r=n[parseInt(e.toString(),10)],n[parseInt(e.toString(),10)]=n[parseInt(i.toString(),10)],n[parseInt(i.toString(),10)]=r)}}return n}(t,e),i=1;i0){var i=0,r={x:.5,y:.5};t[0]=this.diagram.nameTable[t[0].id]||t[0];var s=yr(t[0].wrapper),o={nodes:[],connectors:[]},a={nodes:[],connectors:[]};for(i=1;ii.zIndex){for(var s=this.diagram.layers.indexOf(this.diagram.getActiveLayer()),o=this.diagram.layers[parseInt(s.toString(),10)].zIndexTable,a=JSON.parse(JSON.stringify(o)),l=i.zIndex,h=r.zIndex,c=h;c>=l;c--)l!==c?o[c-1]?(o[parseInt(c.toString(),10)]=o[c-1],this.diagram.nameTable[o[parseInt(c.toString(),10)]].zIndex=c):(o[c-1]=o[parseInt(c.toString(),10)],this.diagram.nameTable[o[c-1]].zIndex=c,delete o[parseInt(c.toString(),10)]):this.swapZIndexObjects(h,o,r.id,a);"SVG"===this.diagram.mode?(this.moveSvgNode(e.parentId,i.id),this.updateNativeNodeIndex(e.parentId,i.id)):this.diagram.refreshCanvasLayers()}},n.prototype.findLeastIndexConnector=function(t,e,i){for(var r=0;rs.zIndex&&(i=s)}return i},n.prototype.findLeastIndexObject=function(t,e){var i=t;return t instanceof te&&(i=this.findLeastIndexConnector(t.inEdges,e,i),i=this.findLeastIndexConnector(t.outEdges,e,i)),i},n.prototype.checkSelection=function(t,e){var i;if(1===t.nodes.length&&0===t.connectors.length)if(cs(this.diagram,t.nodes[0],!0)){var r=t.nodes[0];if("SwimLane"===(i="SwimLane"===t.nodes[0].shape?t.nodes[0]:this.diagram.nameTable[t.nodes[0].parentId]).shape.type){var s="Horizontal"===i.shape.orientation;(r.isPhase&&(s&&"ResizeSouth"===e||!s&&"ResizeEast"===e)||r.isLane&&(s&&"ResizeEast"===e||!s&&"ResizeSouth"===e))&&B3(this.diagram,i,e)}else if("Grid"===i.container.type)if("Horizontal"===i.container.orientation&&1===r.rowIndex||"Vertical"===i.container.orientation&&r.rowIndex>0&&r.columnIndex>0){if("ResizeSouth"===e)for(var o=0;o1&&(this.diagram.realActions=this.diagram.realActions|$i.hScrollbarMoved,this.scrolled=!0),this.diagram.scrollSettings.horizontalOffset=t},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"verticalOffset",{get:function(){return this.vOffset},set:function(t){this.vOffset=t,Math.abs(this.vOffset-this.diagram.scrollSettings.verticalOffset)>1&&(this.diagram.realActions=this.diagram.realActions|$i.vScrollbarMoved,this.scrolled=!0),this.diagram.scrollSettings.verticalOffset=t},enumerable:!0,configurable:!0}),n.prototype.getBounds=function(){var e=this.diagram.spatialSearch.getPageBounds(0,0);return(e.x<0||e.y<0)&&!this.diagram.pageSettings.multiplePage?this.getPageBounds(void 0,void 0,!0,!0):this.getPageBounds(void 0,void 0,!0)},n.prototype.updateScrollOffsets=function(t,e){var i,r,s=this.getBounds();s.x*=this.currentZoom,s.y*=this.currentZoom,s.width*=this.currentZoom,s.height*=this.currentZoom,i=Math.max(0,t-s.left),r=Math.max(0,e-s.top),void 0!==t&&void 0!==e?(this.horizontalOffset=i,this.verticalOffset=r,this.diagram.setOffset(i,r)):this.diagram.setOffset(-this.horizontalOffset-s.x,-this.verticalOffset-s.y),this.transform={tx:Math.max(this.horizontalOffset,-s.left)/this.currentZoom,ty:Math.max(this.verticalOffset,-s.top)/this.currentZoom,scale:this.currentZoom}},n.prototype.setScrollOffset=function(t,e){this.scrolled=!1;var i=this.getBounds();i.x*=this.currentZoom,i.y*=this.currentZoom,i.width*=this.currentZoom,i.height*=this.currentZoom;var r=-i.left,s=-i.top,o=!1,a=this.viewPortWidth*this.currentZoom,l=this.viewPortHeight*this.currentZoom,h=r-t;if(h!==this.horizontalOffset){rh?this.horizontalOffset-=t:this.horizontalOffset=h,o=!0);var c=Math.max(i.right+this.vScrollSize,a);if(!o&&c<-h+this.viewPortWidth){var d=-h+a-this.vScrollSize,u=-this.horizontalOffset+a-this.vScrollSize;this.horizontalOffset=dd-u?h:-(i.right+this.vScrollSize-a),o=!0}o||(this.horizontalOffset=r-t)}o=!1;var p=s-e;if(p!==this.verticalOffset){sp?this.verticalOffset-=e:this.verticalOffset=p,o=!0);var f=Math.max(i.bottom+this.hScrollSize,l);if(!o&&f<-p+l){var g=-p+l-this.hScrollSize,v=-this.verticalOffset+l-this.hScrollSize;this.verticalOffset=gg-v?p:-(i.bottom+this.hScrollSize-l),o=!0}o||(this.verticalOffset=s-e)}this.transform={tx:Math.max(this.horizontalOffset,-i.left)/this.currentZoom,ty:Math.max(this.verticalOffset,-i.top)/this.currentZoom,scale:this.currentZoom},this.setSize()},n.prototype.getObjects=function(t,e){for(var i=[],r=0;r0){for(var l=0;l0){h.push(i[parseInt(o.toString(),10)].id);for(var d=0;d=e.bottom&&(l=0),-this.horizontalOffset<=e.x&&-this.horizontalOffset+this.viewPortWidth>=e.right&&(a=0),this.hScrollSize=a,this.vScrollSize=l;var h=this.diagramWidth,c=this.diagramHeight;this.diagramWidth=Math.max(e.right,-this.horizontalOffset+this.viewPortWidth-l)-i,this.diagramHeight=Math.max(e.bottom,-this.verticalOffset+this.viewPortHeight-a)-r,(h!==this.diagramWidth||c!==this.diagramHeight)&&"Diagram"!==this.diagram.scrollSettings.scrollLimit&&this.diagram.setSize(this.diagramWidth,this.diagramHeight),"Diagram"===this.diagram.scrollSettings.scrollLimit&&(h===this.diagramWidth&&c===this.diagramHeight&&1===this.currentZoom||this.diagram.diagramActions&&t&&(!this.diagram.diagramActions||!t||0===this.verticalOffset&&this.verticalOffset!==t.y||0===this.horizontalOffset&&this.horizontalOffset!==t.x)?t&&h===this.diagramWidth&&c===this.diagramHeight&&(this.diagram.diagramCanvas.scrollHeight>this.viewPortHeight&&t.y<0&&this.horizontalOffset===t.x&&0===this.verticalOffset||this.diagram.diagramCanvas.scrollWidth>this.viewPortWidth&&t.x<0&&this.verticalOffset===t.y&&0===this.horizontalOffset)&&(this.verticalOffset=t.y,this.horizontalOffset=t.x,this.transform={tx:Math.max(t.x,-e.left)/this.currentZoom,ty:Math.max(t.y,-e.top)/this.currentZoom,scale:this.currentZoom}):(this.diagram.scrollActions&ca.Interaction&&t&&(this.transform={tx:Math.max(t.x,-e.left/this.currentZoom)/this.currentZoom,ty:Math.max(t.y,-e.top/this.currentZoom)/this.currentZoom,scale:this.currentZoom},this.horizontalOffset=t.x,this.verticalOffset=t.y),this.diagram.setSize(this.diagramWidth,this.diagramHeight),!(this.diagram.scrollActions&ca.PropertyChange)&&t&&(this.horizontalOffset=t.x,this.verticalOffset=t.y,this.transform={tx:Math.max(t.x,-e.left)/this.currentZoom,ty:Math.max(t.y,-e.top)/this.currentZoom,scale:this.currentZoom}))),this.diagram.transformLayers(),this.diagram.element.style.overflow="hidden"},n.prototype.setViewPortSize=function(t,e){this.viewPortWidth=t,this.viewPortHeight=e},n.prototype.getPageBounds=function(t,e,i,r){var o,s=new Ne;if("Content"===e||r||null===this.diagram.pageSettings.width||null===this.diagram.pageSettings.height){var u=t?void 0:0;o=this.diagram.spatialSearch.getPageBounds(u,u)}else{var a=this.diagram.pageSettings.width,l=this.diagram.pageSettings.height,h=0,c=0;if(this.diagram.pageSettings.multiplePage){if((s=this.diagram.spatialSearch.getPageBounds(0,0)).right>a&&(a*=d=Math.ceil(s.right/a)),s.bottom>l&&(l*=d=Math.ceil(s.bottom/l)),s.left<0&&Math.abs(s.left)>h){var d=Math.ceil(Math.abs(s.left)/this.diagram.pageSettings.width);h=this.diagram.pageSettings.width*d}s.top<0&&Math.abs(s.top)>c&&(d=Math.ceil(Math.abs(s.top)/this.diagram.pageSettings.height),c=this.diagram.pageSettings.height*d)}o=new Ne(-h,-c,a+h,l+c)}if(i){var p=this.diagram.scrollSettings.padding;o.x-=p.left,o.y-=p.top,o.width+=p.left+p.right,o.height+=p.top+p.bottom}return o},n.prototype.getPageBreak=function(t){for(var e=0,i=0,r=-1,s=[],c=this.diagram.pageSettings.margin.left,d=this.diagram.pageSettings.margin.right,u=this.diagram.pageSettings.margin.top,p=this.diagram.pageSettings.margin.bottom,f=1,g=1;t.width>e;)(e+=this.diagram.pageSettings.width?this.diagram.pageSettings.width:t.width)===this.diagram.pageSettings.width&&(s[++r]={x1:t.left+c,y1:t.top+u,x2:t.left+c,y2:t.bottom-p}),ei;)(i+=this.diagram.pageSettings.height?this.diagram.pageSettings.height:t.height)===this.diagram.pageSettings.height&&(s[++r]={x1:t.left+c,y1:t.top+u,x2:t.right-d,y2:t.top+u}),i=this.diagram.scrollSettings.minZoom||l||t>=1)){this.currentZoom*=t;var c=this.getPageBounds(void 0,void 0,!0);c.x*=this.currentZoom,c.y*=this.currentZoom;var d=Hi();Wp(d,t,t,r.x,r.y),ZB(d,e||0,i||0),yx(h,d);var u=Je(h,{x:0,y:0});if(1===t&&(u=this.applyScrollLimit(u.x,u.y,s,o,a)),a=-c.y>=u.y&&-c.x>=u.x&&a,(this.diagram.scrollActions&ca.PropertyChange||!(this.diagram.scrollActions&ca.Interaction)||"Diagram"!==this.diagram.scrollSettings.scrollLimit||a)&&(this.transform={tx:Math.max(u.x,-c.left)/this.currentZoom,ty:Math.max(u.y,-c.top)/this.currentZoom,scale:this.currentZoom},this.horizontalOffset=u.x,this.verticalOffset=u.y),this.setSize(u),"SVG"!==this.diagram.mode&&Ds(this.diagram)&&this.diagram.scroller.virtualizeElements(),"SVG"!==this.diagram.mode&&!Ds(this.diagram)&&this.diagram.refreshDiagramLayer(),this.diagram.setOffset(-this.horizontalOffset-c.x,-this.verticalOffset-c.y),XI(this.diagram),this.diagram.views&&this.diagram.views.overview){var p=this.diagram.views.overview,f=p.scrollOverviewRect(p.parent.scroller.horizontalOffset,p.parent.scroller.verticalOffset,p.parent.scroller.currentZoom,!0);p.updateOverviewrect(-f.x,-f.y,f.width,f.height),p.updateView(p)}}}},n.prototype.fitToPage=function(t){var e=(t=t||{}).mode,i=t.region,r=t.margin||{},s=t.canZoomIn,o=t.customBounds,a=t.canZoomOut;r.bottom=r.bottom||25,r.top=r.top||25,r.left=r.left||25,r.right=r.right||25;var h,l=o,c=-this.horizontalOffset,d=-this.verticalOffset;if("PageSettings"===(i=i||"PageSettings")&&this.diagram.pageSettings.width&&this.diagram.pageSettings.height||this.diagram.nodes.length>0||this.diagram.connectors.length>0){e=e||"Page","CustomBounds"!==i&&(l=this.getPageBounds(!0,i,!0));var u={x:0,y:0};r.left+r.right>this.viewPortWidth&&(this.viewPortWidth<=100?(r.left=5,r.right=5):(r.left=25,r.right=25)),r.top+r.bottom>this.viewPortHeight&&(this.viewPortHeight<=100?(r.top=5,r.bottom=5):(r.top=25,r.bottom=25)),u.x=(this.viewPortWidth-(r.left+r.right))/l.width,u.y=(this.viewPortHeight-(r.top+r.bottom))/l.height,!s&&l.width-this.horizontalOffset-a+this.viewPortWidth&&(i=o.right-this.viewPortWidth,i+=20),o.x<-a&&(i=o.x),o.bottom>-l+this.viewPortHeight&&(r=o.bottom-this.viewPortHeight,r+=20),o.y<-l&&(r=o.y),this.zoom(1,-this.horizontalOffset-i,-this.verticalOffset-r,null,void 0,e))},n.prototype.bringToCenter=function(t){var e=this.currentZoom,i=new Ne(t.x*e,t.y*e,t.width*e,t.height*e),r=i.x+i.width/2-this.viewPortWidth/2,s=i.y+i.height/2-this.viewPortHeight/2;this.zoom(1,-this.horizontalOffset-(r*=-1),-this.verticalOffset-(s*=-1),null)},n.prototype.applyScrollLimit=function(t,e,i,r,s){if("Infinity"===this.diagram.scrollSettings.scrollLimit&&void 0===i&&!r&&(t=-t,e=-e),"Infinity"!==this.diagram.scrollSettings.scrollLimit){var o=void 0;if("Limited"===this.diagram.scrollSettings.scrollLimit){var a=this.diagram.scrollSettings.scrollableArea;o=new Ne(a.x,a.y,a.width,a.height)}(o=o||(s?this.getPageBounds():this.getPageBounds(!0))).x*=this.currentZoom,o.y*=this.currentZoom,o.width*=this.currentZoom,o.height*=this.currentZoom,void 0!==i&&(t*=-1,e*=-1),r&&(t*=-1,e*=-1);var l=Math.max(o.right,this.viewPortWidth);if(!r&&!(t<=o.x&&(t+this.viewPortWidth>=o.right||t>=o.right-this.viewPortWidth)||t>=o.x&&t+this.viewPortWidth<=l))if(t>=o.x)t=Math.max(o.x,Math.min(t,t-(t+this.viewPortWidth-this.vScrollSize-l)));else{var h=o.right-this.viewPortWidth;t=Math.min(h,o.x)}var c=Math.max(o.bottom,this.viewPortHeight);r||e<=o.y&&e+this.viewPortHeight>=o.bottom||e>=o.y&&e+this.viewPortHeight<=c||(e>=o.y?e=Math.max(o.y,Math.min(e,e-(e+this.viewPortHeight-this.hScrollSize-c))):(h=o.bottom-this.viewPortHeight,e=Math.min(o.y,h))),t*=-1,e*=-1}return{x:t,y:e}},n}(),Woe=function(){function n(t,e,i,r,s){this.objects=[],this.left=t,this.top=e,this.width=i,this.height=r,this.spatialSearch=s}return n.prototype.findQuads=function(t,e){null!=this.first&&this.first.isIntersect(t)&&this.first.findQuads(t,e),null!=this.second&&this.second.isIntersect(t)&&this.second.findQuads(t,e),null!=this.third&&this.third.isIntersect(t)&&this.third.findQuads(t,e),null!=this.fourth&&this.fourth.isIntersect(t)&&this.fourth.findQuads(t,e),this.objects.length>0&&e.push(this)},n.prototype.isIntersect=function(t){return!(this.left+this.widtht.right||this.top>t.bottom)},n.prototype.selectQuad=function(){for(var i,t=null,e=this;null!=e;)i=e.getQuad(t),e=i.source,t=i.target||t;return t},n.prototype.getQuad=function(t){var e=this.width/2,i=this.height/2;if(e>=1e3&&i>=1e3){var r=this.left+e,s=this.top+i;if(this.spatialSearch.childRight<=r){if(this.spatialSearch.childBottom<=s)return this.first||((o=new n(this.left,this.top,e,i,this.spatialSearch)).parent=this,this.first=o),{source:this.first};if(this.spatialSearch.childTop>=s)return this.third||((o=new n(this.left,s,e,i,this.spatialSearch)).parent=this,this.third=o),{source:this.third}}else if(this.spatialSearch.childLeft>=r){if(this.spatialSearch.childBottom<=s)return this.second||((o=new n(r,this.top,e,i,this.spatialSearch)).parent=this,this.second=o),{source:this.second};var o;if(this.spatialSearch.childTop>=s)return this.fourth||((o=new n(r,s,e,i,this.spatialSearch)).parent=this,this.fourth=o),{source:this.fourth}}}return this.objects.push(this.spatialSearch.childNode),{target:this}},n.prototype.isContained=function(){return this.spatialSearch.childLeft>=this.left&&this.spatialSearch.childRight<=this.left+this.width&&this.spatialSearch.childTop>=this.top&&this.spatialSearch.childBottom<=this.top+this.height},n.prototype.addIntoAQuad=function(t){var e={};this.spatialSearch.setCurrentNode(t);for(var i=null;!e.isAdded;)i=(e=this.spatialSearch.parentQuad.add(i)).quad;return i},n.prototype.add=function(t){if(t=null,this.isContained())return{isAdded:!0,quad:t=this.selectQuad()};var e=void 0,i=!(0!==this.objects.length||this.first||this.second||this.third||this.fourth),r=2*this.width,s=2*this.height;return this.spatialSearch.childLeft=this.childLeft?(this.pageLeft=this.childLeft,this.leftElement=t,r=!0):t===this.leftElement&&(this.pageLeft=Number.MAX_VALUE,this.findLeft(this.parentQuad),r=!0)),(this.pageTop!==this.childTop||t!==this.topElement)&&(this.pageTop>=this.childTop?(this.pageTop=this.childTop,this.topElement=t,r=!0):t===this.topElement&&(this.pageTop=Number.MAX_VALUE,this.findTop(this.parentQuad),r=!0)),(this.pageBottom!==this.childBottom||t!==this.bottomElement)&&(this.pageBottom<=this.childBottom?(r=!0,this.pageBottom=this.childBottom,this.bottomElement=t):t===this.bottomElement&&(this.pageBottom=-Number.MAX_VALUE,this.findBottom(this.parentQuad),r=!0)),(this.pageRight!==this.childRight||t!==this.rightElement)&&(this.pageRight<=this.childRight?(this.pageRight=this.childRight,this.rightElement=t,r=!0):t===this.rightElement&&(this.pageRight=-Number.MAX_VALUE,this.findRight(this.parentQuad),r=!0)),r}return this.setCurrentNode(null),!1},n.prototype.isWithinPageBounds=function(t){return t.left>=this.pageLeft&&t.right<=this.pageRight&&t.top>=this.pageTop&&t.bottom<=this.pageBottom},n.prototype.findQuads=function(t){var e=[];return this.parentQuad.findQuads(t,e),e},n.prototype.findObjects=function(t){for(var i=[],r=0,s=this.findQuads(t);r=r.outerBounds.left&&(this.pageLeft=r.outerBounds.left,this.leftElement=r)}},n.prototype.findTop=function(t){t.first||t.second?(t.first&&this.findTop(t.first),t.second&&this.findTop(t.second)):(t.third&&this.findTop(t.third),t.fourth&&this.findTop(t.fourth));for(var e=0,i=t.objects;e=r.outerBounds.top&&(this.pageTop=r.outerBounds.top,this.topElement=r)}},n.prototype.setCurrentNode=function(t){if(this.childNode=t,t){var e=t.outerBounds;this.childLeft=Number(e.left),this.childTop=Number(e.top),this.childRight=Number(e.right),this.childBottom=Number(e.bottom)}else this.childLeft=Number.MAX_VALUE,this.childTop=Number.MAX_VALUE,this.childRight=-Number.MAX_VALUE,this.childBottom=-Number.MAX_VALUE},n.prototype.getPageBounds=function(t,e){if(this.pageLeft===Number.MAX_VALUE)return new Ne(0,0,0,0);var i=void 0!==t?Math.min(this.pageLeft,0):this.pageLeft,r=void 0!==e?Math.min(this.pageTop,0):this.pageTop;return new Ne(Math.round(i),Math.round(r),Math.round(this.pageRight-i),Math.round(this.pageBottom-r))},n.prototype.getQuad=function(t){return this.quadTable[t.id]},n}(),Yoe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Goe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Yoe(t,n),function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);r>3&&s&&Object.defineProperty(t,e,s)}([I(!1)],t.prototype,"preventDefaults",void 0),t}(Ee),Xoe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),e_=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},qoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Xoe(t,n),e_([I("")],t.prototype,"action",void 0),e_([I("")],t.prototype,"cursor",void 0),t}(Ee),t_=function(){function n(){this.size=20,this.intermediatePoints=[],this.gridCollection=[],this.startArray=[],this.targetGridCollection=[],this.sourceGridCollection=[],this.considerWalkable=[]}return n.prototype.lineRouting=function(t){var e=t.connectors.length;if(this.renderVirtualRegion(t),e>0)for(var i=0;i=t.right||e.right<=t.left||e.top>=t.bottom||e.bottom<=t.top)},n.prototype.findEndPoint=function(t,e,i){var r,s;if(e&&""!==t.sourcePortID&&t.sourcePortWrapper||!e&&""!==t.targetPortID&&t.targetPortWrapper){s=zo(r=e?{x:t.sourcePortWrapper.offsetX,y:t.sourcePortWrapper.offsetY}:{x:t.targetPortWrapper.offsetX,y:t.targetPortWrapper.offsetY},void 0,e?t.sourceWrapper.bounds:t.targetWrapper.bounds);var o=e?t.sourcePortWrapper.bounds:t.targetPortWrapper.bounds;r=i?"Top"===s?{x:o.topCenter.x,y:o.topCenter.y}:"Left"===s?{x:o.middleLeft.x,y:o.middleLeft.y}:"Right"===s?{x:o.middleRight.x,y:o.middleRight.y}:{x:o.bottomCenter.x,y:o.bottomCenter.y}:{x:o.center.x,y:o.center.y}}else r=e&&this.startNode||!e&&this.targetNode?e?{x:this.startNode.wrapper.offsetX,y:this.startNode.wrapper.offsetY}:{x:this.targetNode.wrapper.offsetX,y:this.targetNode.wrapper.offsetY}:e?{x:t.sourcePoint.x,y:t.sourcePoint.y}:{x:t.targetPoint.x,y:t.targetPoint.y};return r},n.prototype.refreshConnectorSegments=function(t,e,i,r){var h,c,p,f,g,y,S,b,M,w,C,s=e.sourceID,o=e.targetID,a=e.sourcePortID,l=e.targetPortID;if(function Ure(n,t){var e=0;return n.constraints&qe.LineRouting?e=n.constraints&qe.LineRouting:n.constraints&qe.InheritLineRouting&&(e=t.constraints&rt.LineRouting),e}(e,t)||r){this.startNode=t.nameTable[""+s],this.targetNode=t.nameTable[""+o],this.intermediatePoints=[],this.startArray=[],this.targetGridCollection=[],this.sourceGridCollection=[],this.startGrid=void 0,this.targetGrid=void 0;for(var D=0;D0;){var L=this.startArray.pop();if(L){for(D=0;D1&&(e.segments=[]),this.updateConnectorSegments(t,this.intermediatePoints,this.gridCollection,e,i)){this.considerWalkable=[];break e}this.targetGridCollection.splice(this.targetGridCollection.indexOf(O),1),L=this.startArray.pop()}}L&&this.findPath(L)}}}},n.prototype.checkChildNodes=function(t,e){var i=!1,r=!1;if(t.nodeId.length>=1&&!e)for(var s=0;s1&&this.targetGridCollection[0].nodeId.length>1)for(var c=0;c<=1;c++){for(var d=this.targetGridCollection[parseInt(c.toString(),10)].gridX,u=this.targetGridCollection[parseInt(c.toString(),10)].gridY,p=this.targetGridCollection[parseInt(c.toString(),10)].nodeId,f=void 0,g=0;g=e.right&&t.top<=e.top&&t.bottom>=e.bottom},n.prototype.getEndvalue=function(t,e){return this.gridCollection[t.gridX][t.gridY].walkable?t:"left"===e?this.getEndvalue(this.gridCollection[t.gridX-1][t.gridY],e):"right"===e?this.getEndvalue(this.gridCollection[t.gridX+1][t.gridY],e):"top"===e?this.getEndvalue(this.gridCollection[t.gridX][t.gridY-1],e):"bottom"===e?this.getEndvalue(this.gridCollection[t.gridX][t.gridY+1],e):t},n.prototype.changeValue=function(t,e,i){t.walkable||this.considerWalkable.push(t);for(var r,s=0;s<=e;s++)"left"===i?r=this.gridCollection[t.gridX-s][t.gridY]:"right"===i?r=this.gridCollection[t.gridX+s][t.gridY]:"top"===i?r=this.gridCollection[t.gridX][t.gridY-s]:"bottom"===i&&(r=this.gridCollection[t.gridX][t.gridY+s]),r.walkable||this.considerWalkable.push(r)},n.prototype.getIntermediatePoints=function(t){var e;for(this.intermediatePoints=[];t;)this.intermediatePoints.push({x:t.gridX,y:t.gridY}),t=t.parent;this.intermediatePoints.reverse(),this.intermediatePoints.length>=1&&void 0!==this.intermediatePoints[0]&&void 0!==this.intermediatePoints[1]&&(this.intermediatePoints[0].x===this.intermediatePoints[1].x?this.intermediatePoints[0].y=1&&u.length>1&&(g=u[u.length-2].x!==u[u.length-1].x?u[u.length-2].x>u[u.length-1].x?"Left":"Right":u[u.length-2].y>u[u.length-1].y?"Top":"Bottom"),M>=2&&v===g&&u.length>1&&u.splice(u.length-2,1),v=g);if(u&&u.length>1){for(var w=0;wD.x?S.bounds.middleLeft:S.bounds.middleRight),w===u.length-2&&""===r.targetPortID&&y&&(l=C.x>D.x?y.bounds.middleRight:y.bounds.middleLeft),0===w&&b&&(C.x=b.x,C.y=D.y=b.y),w===u.length-2&&l&&(w>0&&r.targetDecorator&&l.x-D.x<0&&Math.abs(l.x-C.x)0&&r.targetDecorator&&l.x-D.x>0&&Math.abs(l.x-C.x)D.y?S.bounds.topCenter:S.bounds.bottomCenter),w===u.length-2&&""===r.targetPortID&&y&&(l=C.y>D.y?y.bounds.bottomCenter:y.bounds.topCenter),0===w&&b&&(C.y=b.y,C.x=D.x=b.x),w===u.length-2&&l&&(w>0&&r.targetDecorator&&l.y-D.y<0&&Math.abs(l.y-C.y)0&&r.targetDecorator&&l.y-D.y>0&&Math.abs(l.y-C.y)D.x?(p="Left",f=C.x-D.x):(p="Right",f=D.x-C.x):C.y>D.y?(p="Top",f=C.y-D.y):(p="Bottom",f=D.y-C.y),o.push({type:"Orthogonal",length:f,direction:p})}}if(o&&o.length>0){var A=o[o.length-1];if(1===o.length&&(A.length-=20),A.length<10&&2===o.length&&(o.pop(),o.length>0&&(o[0].length-=20,A=o[0])),r.targetDecorator&&("Top"===A.direction||"Bottom"===A.direction)&&A.length>r.targetDecorator.height+1||("Right"===A.direction||"Left"===A.direction)&&A.length>r.targetDecorator.width+1)return r.segments=o,s&&t.connectorPropertyChange(r,{},{type:"Orthogonal",segments:o}),!0}return!1},n.prototype.findPath=function(t){for(var e,i=[],r=this.findNearestNeigbours(t,this.gridCollection,!0),s=0;sl)&&(e.x!==t.gridX||e.y!==t.gridY)&&(i.push(e),o.previousDistance=l,o.afterDistance=o.afterDistance||this.manhattan(Math.abs(e.x-this.targetGrid.gridX),Math.abs(e.y-this.targetGrid.gridY)),o.totalDistance=o.previousDistance+o.afterDistance,o.parent=t)}if(i.length>0)for(s=0;st?i*t+e:i*e+t},n.prototype.manhattan=function(t,e){return t+e},n.prototype.findNearestNeigbours=function(t,e,i){var r=[],s=t.parent;if(s){var o=(t.gridX-s.gridX)/Math.max(Math.abs(t.gridX-s.gridX),1),a=(t.gridY-s.gridY)/Math.max(Math.abs(t.gridY-s.gridY),1);0!==o?(this.isWalkable(t.gridX,t.gridY-1,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX][t.gridY-1])&&r.push(e[t.gridX][t.gridY-1]),this.isWalkable(t.gridX,t.gridY+1,!0)&&this.sourceGridCollection.indexOf(e[t.gridX][t.gridY+1])&&r.push(e[t.gridX][t.gridY+1]),this.isWalkable(t.gridX+o,t.gridY,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX+o][t.gridY])&&r.push(e[t.gridX+o][t.gridY])):0!==a&&(this.isWalkable(t.gridX-1,t.gridY,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX-1][t.gridY])&&r.push(e[t.gridX-1][t.gridY]),this.isWalkable(t.gridX+1,t.gridY,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX+1][t.gridY])&&r.push(e[t.gridX+1][t.gridY]),this.isWalkable(t.gridX,t.gridY+a,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX][t.gridY+a])&&r.push(e[t.gridX][t.gridY+a]))}else this.neigbour(t,"top",r,i),this.neigbour(t,"right",r,i),this.neigbour(t,"bottom",r,i),this.neigbour(t,"left",r,i);return r},n.prototype.neigbour=function(t,e,i,r){for(var o,s=1;s>0;){var a="top"===e||"bottom"===e?t.gridX:"left"===e?t.gridX-s:t.gridX+s,l="right"===e||"left"===e?t.gridY:"top"===e?t.gridY-s:t.gridY+s;if((o=this.gridCollection[parseInt(a.toString(),10)][parseInt(l.toString(),10)])&&(r&&-1===this.sourceGridCollection.indexOf(o)||!r&&-1===this.targetGridCollection.indexOf(o)))return i&&this.isWalkable(a,l)&&i.push(o),s;if(!(a>0&&l>0))break;s++}return null},n.prototype.resetGridColl=function(t,e,i){for(var s,r=1;r>0;){var o="top"===e||"bottom"===e?t.gridX:"left"===e?t.gridX-r:t.gridX+r,a="right"===e||"left"===e?t.gridY:"top"===e?t.gridY-r:t.gridY+r;if((s=this.gridCollection[parseInt(o.toString(),10)][parseInt(a.toString(),10)])&&(i&&-1===this.sourceGridCollection.indexOf(s)||!i&&-1===this.targetGridCollection.indexOf(s))){if(this.isWalkable(o,a))break;var l=this.gridCollection[parseInt(o.toString(),10)][parseInt(a.toString(),10)];this.considerWalkable.push(l)}if(!(o>0&&a>0))break;"top"===e||"left"===e?r--:r++}return null},n.prototype.isWalkable=function(t,e,i){if(t>=0&&t=0&&e0?1:-1,this.isWalkable(h,c-1)&&!this.isWalkable(h-a,c-1)||this.isWalkable(h,c+1)&&!this.isWalkable(h-a,c+1)))return{x:t,y:e};if(0!==l){if(l=l>0?1:-1,this.isWalkable(h-1,c)&&!this.isWalkable(h-1,c-l)||this.isWalkable(h+1,c)&&!this.isWalkable(h+1,c-l))return{x:t,y:e};if(this.findIntermediatePoints(h+1,c,h,c,s,o)||this.findIntermediatePoints(h-1,c,h,c,s,o))return{x:t,y:e}}return this.findIntermediatePoints(h+a,c+l,h,c,s,o)},n.prototype.destroy=function(){},n.prototype.getModuleName=function(){return"LineRouting"},n}(),$oe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Joe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return $oe(t,n),function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);r>3&&s&&Object.defineProperty(t,e,s)}([I(!0)],t.prototype,"inversedAlignment",void 0),t}(Ee),Koe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Oe=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},CT=function(n,t,e,i){return new(e||(e=Promise))(function(r,s){function o(h){try{l(i.next(h))}catch(c){s(c)}}function a(h){try{l(i.throw(h))}catch(c){s(c)}}function l(h){h.done?r(h.value):new e(function(c){c(h.value)}).then(o,a)}l((i=i.apply(n,t||[])).next())})},ET=function(n,t){var i,r,s,o,e={label:0,sent:function(){if(1&s[0])throw s[1];return s[1]},trys:[],ops:[]};return o={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function a(h){return function(c){return function l(h){if(i)throw new TypeError("Generator is already executing.");for(;e;)try{if(i=1,r&&(s=2&h[0]?r.return:h[0]?r.throw||((s=r.return)&&s.call(r),0):r.next)&&!(s=s.call(r,h[1])).done)return s;switch(r=0,s&&(h=[2&h[0],s.value]),h[0]){case 0:case 1:s=h;break;case 4:return e.label++,{value:h[1],done:!1};case 5:e.label++,r=h[1],h=[0];continue;case 7:h=e.ops.pop(),e.trys.pop();continue;default:if(!(s=(s=e.trys).length>0&&s[s.length-1])&&(6===h[0]||2===h[0])){e=0;continue}if(3===h[0]&&(!s||h[1]>s[0]&&h[1]0&&((!s.style||!s.style.fill)&&(o.style.fill="transparent"),(!s.style||!s.style.strokeColor)&&(o.style.strokeColor="transparent")),s.shape&&"UmlActivity"===s.shape.type&&ZI(s,o),s.shape&&"SwimLane"===s.shape.type&&aF(s,o),r.nodeDefaults&&Ro(o,s,r.nodeDefaults),r.updateAnnotationText(o.annotations);if(e&&e.connectors)for(a=0;e&&e.connectors&&a0&&0===i.nodes.length)this.clearCollection(),a=!0;else{for(var g=0,v=Object.keys(e.nodes);g0&&0===i.connectors.length)this.clearCollection(!0),a=!0;else{for(var C=0,D=Object.keys(e.connectors);C0){this.renderSelector(!0);break}if(e.selectedItems.constraints){this.renderSelector(!0);break}break;case"snapSettings":this.updateSnapSettings(e);break;case"commandManager":this.initCommands();break;case"layout":o=!0;break;case"segmentThumbShape":this.updateSelector();break;case"dataSourceSettings":this.clear(),"None"===this.layout.type?a=!0:(this.initObjects(),o=!0);break;case"tooltip":i3(this);break;case"rulerSettings":this.updateRulerSettings(e);break;case"layers":this.updateLayer(e);break;case"scrollSettings":this.scrollActions|=ca.PropertyChange,this.updateScrollSettings(e),this.scrollActions&=~ca.PropertyChange,this.scrollSettings.horizontalOffset=-this.scroller.horizontalOffset||0,this.scrollSettings.verticalOffset=-this.scroller.verticalOffset||0;break;case"locale":e.locale!==i.locale&&(this.realActions|=$i.PreventDataInit,n.prototype.refresh.call(this),this.realActions&=~$i.PreventDataInit);break;case"contextMenuSettings":if(void 0!==e.contextMenuSettings.showCustomMenuOnly&&(this.contextMenuSettings.showCustomMenuOnly=e.contextMenuSettings.showCustomMenuOnly),void 0!==e.contextMenuSettings.show&&(this.contextMenuSettings.show=e.contextMenuSettings.show),e.contextMenuSettings.items){for(var A=e.contextMenuSettings.items,x=0,R=Object.keys(A);x0){for(var N=[],T=O.ports.length-1;T>=0;T--)"LineDistribution"===O.ports[parseInt(T.toString(),10)].id.split("_")[1]&&N.push(O.ports[parseInt(T.toString(),10)]);this.removePorts(O,N)}}for(T=0;T0)for(var ue=0,pe=Object.keys(e.nodes);ue0)for(var De=0,xe=Object.keys(e.connectors);De=0;o--)this.commandHandler.expandNode(r[parseInt(o.toString(),10)],this,0!==o);this.canLayout&&this.doLayout(),this.lineRoutingModule?this.connectors.sourceID!==this.connectors.targetID&&this.lineRoutingModule.lineRouting(this):this.constraints&rt.LineRouting&&console.warn('[WARNING] :: Module "LineRouting" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),this.validatePageSize(),this.renderPageBreaks(),this.diagramRenderer.renderSvgGridlines(this.snapSettings,Bd(this.element.id),this.scroller.transform,this.rulerSettings,this.hRuler,this.vRuler),this.commandHandler.initSelectorWrapper(),this.notify("initial-load",{}),this.trigger("load"),this.scroller.setSize(),this.scroller.updateScrollOffsets(),this.isRefreshed||this.refreshDiagramLayer(),(this.scrollSettings.verticalOffset>0||this.scrollSettings.horizontalOffset>0)&&this.updateScrollOffset(),X.isDevice&&(this.tool=Ci.ZoomPan|Ci.SingleSelect),this.notify("initial-end",{}),this.isProtectedOnChange=!1,this.tooltipObject=i3(this),this.diagramActions=ee.Render,this.initCommands();var a=document.getElementsByClassName(this.element.id+"_hiddenUserHandleTemplate");(function Ioe(n,t,e,i){var r,s,o,a,l,d=document.getElementById(i).ej2_instances[0];if(n&&t){r=UF(n);for(var u=0,p=e.userHandles;u0;)e[0].parentNode.removeChild(e[0]);var i=document.getElementById(this.element.id+"content");i&&this.element.removeChild(i);var r="measureElement";if(window[""+r]){window[""+r].usageCount-=1;var s="measureElementCount";window[""+s]--,0===window[""+s]&&(window[""+r].parentNode.removeChild(window[""+r]),window[""+r]=null)}}window.domTable={};for(var a=0;a1&&(this.callBlazorModel=!1,this.insertBlazorDiagramObjects(this.selectedItems),this.commandHandler.group(),this.callBlazorModel=!0,this.commandHandler.getBlazorOldValues())},t.prototype.unGroup=function(){this.callBlazorModel=!1,this.insertBlazorDiagramObjects(this.selectedItems),this.commandHandler.unGroup(),this.callBlazorModel=!0,this.commandHandler.getBlazorOldValues()},t.prototype.sendToBack=function(){this.commandHandler.sendToBack()},t.prototype.setActiveLayer=function(e){var i=this.commandHandler.getLayer(e);this.activeLayer=i},t.prototype.addLayer=function(e,i){this.commandHandler.addLayer(e,i)},t.prototype.removeLayer=function(e){this.commandHandler.removeLayer(e,ce())},t.prototype.moveObjects=function(e,i){$(this.layers),this.enableServerDataBinding(!1),this.commandHandler.moveObjects(e,i)},t.prototype.layerObjectUpdate=function(){},t.prototype.sendLayerBackward=function(e){this.layerObjectUpdate(),this.commandHandler.sendLayerBackward(e)},t.prototype.bringLayerForward=function(e){this.layerObjectUpdate(),this.commandHandler.bringLayerForward(e)},t.prototype.cloneLayer=function(e){this.commandHandler.cloneLayer(e)},t.prototype.bringToFront=function(){this.commandHandler.bringToFront()},t.prototype.moveForward=function(){this.commandHandler.sendForward()},t.prototype.sendBackward=function(){this.commandHandler.sendBackward()},t.prototype.getObject=function(e){return this.nameTable[""+e]},t.prototype.getNodeObject=function(e){return $(this.nameTable[""+e])},t.prototype.getConnectorObject=function(e){return $(this.nameTable[""+e])},t.prototype.getActiveLayer=function(){return this.activeLayer},t.prototype.nudgeCommand=function(e,i,r){if("object"!=typeof e&&(this.selectedItems.nodes.length||this.selectedItems.connectors.length)>0){var s=void 0;i.type&&"KEYDOWN"===i.type&&(s=i.type),this.nudge(e,void 0,void 0,s)}},t.prototype.nudge=function(e,i,r,s){var o=0,a=0;"Left"===e||"Right"===e?o=("Left"===e?-1:1)*(i||1):a=("Up"===e?-1:1)*(r||1),"KEYDOWN"===s&&(o*=5,a*=5);var h=this.selectedItems,c=this.selectedItems.wrapper.children[0];if(c instanceof si)this.commandHandler.labelDrag(h.nodes[0],c,o,a);else{var d=$(this.selectedItems);this.protectPropertyChange(!0),this.drag(h,o,a),this.protectPropertyChange(!1);var u={type:"PositionChanged",redoObject:$(this.selectedItems),undoObject:d,category:"Internal"};this.addHistoryEntry(u)}this.refreshCanvasLayers()},t.prototype.insertBlazorDiagramObjects=function(e){},t.prototype.drag=function(e,i,r){if(this.insertBlazorDiagramObjects(e),!(this.bpmnModule&&e instanceof te&&this.bpmnModule.updateAnnotationDrag(e,this,i,r))){if(e instanceof oi){if(this.preventConnectorsUpdate=!0,e.nodes&&e.nodes.length){for(var o=0,a=e.nodes;o0&&o.nodes[0].children){this.fromUndo||(this.rotateUsingButton=!0);for(var h=this.commandHandler.getAllDescendants(o.nodes[0],[]),c=0;c0&&o.nodes[0].children){var g={type:"RotationChanged",redoObject:$(e),undoObject:$(o),category:"Internal",childTable:a};this.commandHandler.addHistoryEntry(g),this.commandHandler.updateSelector()}return u},t.prototype.dragSourceEnd=function(e,i,r){this.insertBlazorDiagramObjects(e),this.commandHandler.dragSourceEnd(e,i,r),this.callBlazorModel&&this.commandHandler.getBlazorOldValues()},t.prototype.dragTargetEnd=function(e,i,r){this.insertBlazorDiagramObjects(e),this.commandHandler.dragTargetEnd(e,i,r),this.callBlazorModel&&this.commandHandler.getBlazorOldValues()},t.prototype.findObjectsUnderMouse=function(e,i){return this.eventHandler.findObjectsUnderMouse(e,i)},t.prototype.findObjectUnderMouse=function(e,i,r){return this.eventHandler.findObjectUnderMouse(e,i,r)},t.prototype.findTargetObjectUnderMouse=function(e,i,r,s,o){return this.eventHandler.findTargetUnderMouse(e,i,r,s,o)},t.prototype.findElementUnderMouse=function(e,i,r,s){return this.eventHandler.findElementUnderMouse(e,i,r,s)},t.prototype.findActionToBeDone=function(e,i,r,s){return this.eventHandler.findActionToBeDone(e,i,r,s)},t.prototype.updateConnectorPort=function(e){if(e.ports.length)for(var i=void 0,r=0,s=e.ports;r=0;s--)if(i.push(r[parseInt(s.toString(),10)]),i.length>this.historyManager.stackLimit)return i}else i=r;return i},t.prototype.getEdges=function(e){return e.outEdge?this.nameTable[e.id].outEdges:this.nameTable[e.id].inEdges},t.prototype.getParentId=function(e){return this.nameTable[""+e].parentId},t.prototype.addConnector=function(e){return this.add(e)},t.prototype.UpdateBlazorDiagramModelCollection=function(e,i,r,s){},t.prototype.UpdateBlazorDiagramModel=function(e,i,r,s){},t.prototype.UpdateBlazorLabelOrPortObjects=function(e,i,r,s){},t.prototype.addBlazorDiagramObjects=function(){},t.prototype.removeNodeEdges=function(e,i,r){var s=this.nameTable[""+e],o=r?s.outEdges:s.inEdges;if(o.length>0)for(var a=0;a0)){for(var c=0;c0))}this.removePortEdges(l,a.element.sourcePortID,a.element.id,h)}a.element.targetID&&this.removeNodeEdges(a.element.targetID,a.element.id,!1)}}this.diagramActions=this.diagramActions|ee.PublicMethod,e.id=e.id||Qe();var u=this.activeLayer;if(!a.cancel&&u&&!u.lock){if(u.objects.indexOf(e.id)<0&&!u.lock&&(u.visible||(u.visible=!0,this.dataBind()),u.objects.push(e.id)),fs(e)===de)(r=new de(this,"connectors",e,!0)).status="New",this.nameTable[r.targetID]&&"TextAnnotation"===this.nameTable[r.targetID].shape.shape&&(r.isBpmnAnnotationConnector=!0,r.constraints=r.constraints&~qe.Delete),Ro(r,e,this.connectorDefaults),this.connectors.push(r),this.initObject(r),!1===e.visible&&this.updateElementVisibility(r.wrapper,r,e.visible),this.updateEdges(r),this.insertBlazorConnector(r);else{if(Ro(r=new te(this,"nodes",e,!0),e,this.nodeDefaults),r.parentId=e.parentId?e.parentId:r.parentId,r.umlIndex=e.umlIndex,r.status="New",(o="TextAnnotation"===r.shape.shape)&&!e.isTextAnnotationCopied&&(r.inEdges=e.inEdges?e.inEdges:r.inEdges),this.nodes.push(r),this.initObject(r,u,void 0,i),o&&this.bpmnModule)for(c=0;c-1&&e.parentId&&this.nameTable[e.parentId]&&"UmlClassifier"===this.nameTable[e.parentId].shape.type){var g=this.nameTable[e.parentId];g.children.splice(r.umlIndex,0,r.id),g.wrapper.children.splice(r.umlIndex,0,r.wrapper),g.wrapper.measure(new me),g.wrapper.arrange(g.wrapper.desiredSize),this.updateDiagramObject(g)}}if(a={element:r,cause:this.diagramActions,diagramAction:this.getDiagramAction(this.diagramActions),state:"Changed",type:"Addition",cancel:!1},this.parentObject&&(a.parentId=this.parentObject.id),"helper"!==e.id&&!(this.diagramActions&ee.PreventCollectionChangeOnDragOver)&&this.triggerEvent(Ce.collectionChange,a),!(this.diagramActions&ee.UndoRedo||this.diagramActions&ee.Group||this.diagramActions&ee.PreventHistory)){var v={type:"CollectionChanged",changeType:"Insert",undoObject:$(e),redoObject:$(e),category:"Internal"};this.addHistoryEntry(v)}this.parentObject=void 0,"SVG"===this.mode&&(this.updateSvgNodes(r),this.updateTextElementValue(r),this.updateDiagramObject(r),o&&this.updateDiagramObject(this.nameTable[r.inEdges[0]]),r.shape.activity&&r.shape.activity.subProcess.processes&&r.shape.activity.subProcess.processes.length&&this.updateProcesses(r),this.updateBridging())}}if(this.protectPropertyChange(s),this.resetDiagramActions(ee.PublicMethod),r&&this.layers.length>1&&this.moveNode(r),this.views)for(var S=0,b=this.views;S=0;l--)this.moveSvgNode(a[parseInt(l.toString(),10)])}for(var h=0,c=i;h=0;o--)r[parseInt(o.toString(),10)]===e.id&&r.splice(o,1);for(var a=0;s.ports&&a=0;s--)if(i=this.nameTable[r[parseInt(s.toString(),10)]])if(this.connectorTable[i.id]=$(i),i.isBpmnAnnotationConnector){var o=this.nameTable[i.targetID];this.removeObjectsFromLayer(i);var a=this.connectors.indexOf(i);-1!==a&&this.connectors.splice(a,1),this.removeElements(i),this.removeFromAQuad(i),delete this.nameTable[i.id];var l=this.nameTable[i.sourceID];if(l){var h=l.outEdges.indexOf(i.id);-1!==h&&l.outEdges.splice(h,1)}e.id!==i.targetID&&this.remove(o)}else this.remove(i)},t.prototype.removeObjectsFromLayer=function(e){if(e.children)for(var i=0;i-1&&(_r(this,e)&&this.unSelect(e),this.layers[parseInt(s.toString(),10)].objects.splice(a,1),delete this.layers[parseInt(s.toString(),10)].zIndexTable[this.nameTable[e.id].zIndex])},t.prototype.removeElements=function(e){if("SVG"===this.mode||"Canvas"===this.mode&&"Native"===e.shape.type){var i=xt(e.id+"_groupElement",this.element.id),r=e;if(r.ports&&r.ports.length>0)for(var s=0;s0){l[parseInt(s.toString(),10)].id.indexOf("icon_content")>0&&"SVG"===this.mode&&((h=xt(l[parseInt(s.toString(),10)].id+"_shape_groupElement",this.element.id))&&h.parentNode.removeChild(h),(h=xt(l[parseInt(s.toString(),10)].id+"_rect_groupElement",this.element.id))&&h.parentNode.removeChild(h));for(var c=0,d=this.views;c=0;o--)a.children[parseInt(o.toString(),10)].children&&(l=n.nameTable[a.children[parseInt(o.toString(),10)].id])&&(l.isLane?qv(n,l):(n.removeDependentConnector(l),n.diagramActions|=ee.PreventHistory,l.constraints&ie.Delete?n.remove(l):V3(n,l,{},!1),n.diagramActions&=~ee.PreventHistory));a&&(i=n.nameTable[a.id])&&qv(n,i)}}(this,e),!(this.diagramActions&ee.UndoRedo||this.diagramActions&ee.PreventHistory)&&(e instanceof te||e instanceof de)){var o={type:"CollectionChanged",changeType:"Remove",undoObject:$(e),redoObject:$(e),category:"Internal"};this.diagramActions&ee.Clear||e.children&&!e.isLane&&!e.isPhase&&e.children.length>0&&this.undoRedoModule&&"None"===this.layout.type&&(this.historyManager.startGroupAction(),s=!0),(e instanceof te||e instanceof de)&&this.deleteDependentConnector&&this.removeDependentConnector(e),!e.isLane&&!e.isPhase&&!(this.diagramActions&ee.Clear)&&!this.isStackChild(e)&&this.addHistoryEntry(o)}"TextAnnotation"===e.shape.shape&&this.removeDependentConnector(e),e.children&&!e.isLane&&!e.isPhase&&(!(this.diagramActions&ee.UndoRedo)||!ce())&&this.deleteGroup(e),e.parentId&&(this.deleteChild(e,void 0,!0),this.nameTable[e.parentId]&&"UmlClassifier"===this.nameTable[e.parentId].shape.type&&(this.updateDiagramObject(this.nameTable[e.parentId]),this.updateConnectorEdges(this.nameTable[e.parentId])));var a=void 0;this.diagramActions=this.diagramActions|ee.PublicMethod;var l=this.nameTable[e.id];if(l instanceof te?("Bpmn"===l.shape.type&&this.bpmnModule&&this.bpmnModule.removeBpmnProcesses(l,this),(l.isLane||l.isPhase||"SwimLane"===l.shape.type)&&(h=l.isLane||l.isPhase?this.nameTable[l.parentId]:this.nameTable[l.id],l.isLane?_3(this,l,h):l.isPhase&&U3(this,l,h)),-1!==(a=this.nodes.indexOf(l))&&(this.crudDeleteNodes.push(this.nameTable[l.id]),this.nodes.splice(a,1),this.updateNodeEdges(l))):(-1!==(a=this.connectors.indexOf(l))&&(this.crudDeleteNodes.push(this.nameTable[l.id]),this.connectors.splice(a,1)),this.updateEdges(l),this.spliceConnectorEdges(e,!0),this.spliceConnectorEdges(e,!1)),!this.isServerUpdate&&!(this.blazorActions&on.GroupClipboardInProcess)&&this.commandHandler.getBlazorOldValues(),s&&this.historyManager.endGroupAction(),_r(this,l)&&this.unSelect(l),!l.isPhase){if(this.removeObjectsFromLayer(e),this.currentDrawingObject&&(this.currentDrawingObject.wrapper=void 0),delete this.nameTable[e.id],i.length>0&&i[0].id===l.id&&l.parentId){var h,d=this.nameTable[l.parentId];d&&d.isLane&&"SwimLane"===this.nameTable[d.parentId].shape.type&&F3(this,h=this.nameTable[d.parentId],d,l)}this.removeElements(l),this.updateBridging(),"SVG"!==this.mode&&this.refreshDiagramLayer(),this.diagramActions&ee.Clear||(this.removeFromAQuad(l),r={element:e,cause:this.diagramActions,diagramAction:this.getDiagramAction(this.diagramActions),state:"Changed",type:"Removal",cancel:!1},"helper"!==e.id&&this.triggerEvent(Ce.collectionChange,r),this.resetTool())}}}else if(i.length>0){this.undoRedoModule&&(this.historyManager.startGroupAction(),this.blazorActions|=on.GroupingInProgress,s=!0);for(var u=0;u=f.wrapper.bounds.width&&"Horizontal"===f.shape.orientation||this.selectedItems.wrapper.bounds.y<=f.wrapper.bounds.y+g&&this.selectedItems.wrapper.bounds.height>=f.wrapper.bounds.height-g&&"Vertical"===f.shape.orientation)&&(DI(f)||f.shape.lanes.length>1)&&this.remove(i[parseInt(u.toString(),10)])}}else this.remove(i[parseInt(u.toString(),10)])}s&&(this.blazorActions&=~on.GroupingInProgress,this.isServerUpdate=!0,this.commandHandler.getBlazorOldValues(),this.UpdateBlazorDiagramModelCollection(void 0,void 0,void 0,!0),this.historyManager.endGroupAction(),this.isServerUpdate=!1),this.clearSelection()}e&&(DI(e)||this.diagramActions&ee.Clear)||this.diagramActions&ee.UndoRedo||this.diagramActions&ee.PreventHistory||!(e instanceof te||e instanceof de)||(o={type:"ConnectionChanged",undoObject:$(e),redoObject:$(e),category:"Internal"},!e.isLane&&!e.isPhase&&!(this.diagramActions&ee.Clear)&&!this.isStackChild(e)&&this.addHistoryEntry(o)),this.tooltipObject.close()},t.prototype.isStackChild=function(e){var i,r=this.nameTable[e.parentId];if(e&&e.parentId&&r.container&&"Stack"===r.container.type&&"UmlClassifier"!==this.nameTable[e.parentId].shape.type){i=!0;var s={sourceIndex:r.wrapper.children.indexOf(e.wrapper),source:e,target:void 0,targetIndex:void 0};this.diagramActions&ee.UndoRedo||this.addHistoryEntry({type:"StackChildPositionChanged",redoObject:{sourceIndex:void 0,source:e,target:void 0,targetIndex:void 0},undoObject:s,category:"Internal"})}return i},t.prototype.deleteChild=function(e,i,r){var s;if(s="string"==typeof e?e:e.id,(i=i?this.nameTable[i.id]:this.nameTable[e.parentId])&&i.children){for(var o=0;o=0;i--)this.removeLayer(this.layers[parseInt(i.toString(),10)].id);this.commandHandler.addLayer({id:"default_layer",visible:!0,lock:!1,objects:[],zIndex:0,objectZIndex:-1,zIndexTable:{}},null,!0),this.setActiveLayer(this.layers[this.layers.length-1].id)},t.prototype.clearObjects=function(e){var i=[];i=e||(i=i.concat(this.nodes)).concat(this.connectors),this.diagramActions=this.diagramActions|ee.Clear;for(var r=0,s=i;r0||"Text"===e.shape.type))if("Text"===e.shape.type)i=e.wrapper.children[0].id.split("_")[1];else for(var f=e.annotations.length-1;f>=0;f--)e.annotations[parseInt(f.toString(),10)].visibility&&(i=e.annotations[parseInt(f.toString(),10)].id);i&&(u=this.getWrapper(e.wrapper,i))}if(e&&u&&!(u instanceof Jn)&&(!function Xre(n,t){return"Text"===t.shape.type?t.constraints&ie.ReadOnly:t.constraints&(t instanceof de?qe.ReadOnly:ie.ReadOnly)?n.constraints&Lr.InheritReadOnly?1:0:n.constraints&Lr.ReadOnly?1:0}(u,e)||p)){var g=u.style,v=void 0;v=90>(v=u.bounds.width50?50:e.width,u.style.fontSize)),e.parentId&&"UmlClassifier"===this.nameTable[e.parentId].shape.type?(l.width=e.wrapper.bounds.width-20,c=(e.wrapper.bounds.center.x+r.tx)*r.scale-l.width/2*s-2.5,d=(e.wrapper.bounds.center.y+r.ty)*r.scale-l.height/2*s-3,u.style.textAlign="Left"):(l.width=Math.max(l.width,50),c=(u.bounds.center.x+r.tx)*r.scale-l.width/2*s-2.5,d=(u.bounds.center.y+r.ty)*r.scale-l.height/2*s-3),Ho(y,{id:this.element.id+"_editTextBoxDiv",style:"position: absolute;left:"+c+"px;top:"+d+"px;width:"+(l.width+1)*s+"px;height:"+l.height*s+"px; containerName:"+e.id+";"}),Ho(S,{"aria-label":a,id:this.element.id+"_editBox",style:"width:"+(l.width+1)*s+"px;height:"+l.height*s+"px;resize: none;outline: none;overflow: hidden;;font-family:"+g.fontFamily+";font-size:"+g.fontSize*s+"px;text-align:"+u.style.textAlign.toLocaleLowerCase()+";",class:"e-diagram-text-edit"}),S.style.fontWeight=g.bold?"bold":"",S.style.fontStyle=g.italic?"italic":"",S.style.lineHeight=(1.2*g.fontSize+"px;").toString(),S.style.textDecoration=g.textDecoration?g.textDecoration:"",this.activeLabel.parentId=e.id,this.activeLabel.id=i,u.visible=!1,this.updateDiagramObject(e),this.diagramActions=this.diagramActions|ee.TextEdit,this.isTriggerEvent||(E.add(S,"input",this.eventHandler.inputChange,this.eventHandler),E.add(S,"focusout",this.focusOutEdit,this),S.select())}}}},t.prototype.updateConnectorfixedUserHandles=function(e){if(e.fixedUserHandles.length)for(var i=void 0,r=0,s=e.fixedUserHandles;r0&&this.mindMapChartModule.updateLayout(o,this.nameTable,this.layout,l,this.dataSourceSettings.id,this.dataSourceSettings.root),e=!0;else if(this.radialTreeModule)this.radialTreeModule.updateLayout(o,this.nameTable,this.layout,l),e=!0;else if(this.symmetricalLayoutModule)this.symmetricalLayoutModule.maxIteration=this.layout.maxIteration,this.symmetricalLayoutModule.springLength=this.layout.springLength,this.symmetricalLayoutModule.springFactor=this.layout.springFactor,this.symmetricalLayoutModule.updateLayout(o,this.connectors,this.symmetricalLayoutModule,this.nameTable,this.layout,l),e=!0;else if(this.complexHierarchicalTreeModule){this.canDistribute(a,r)&&(this.lineDistributionModule.diagram=this,this.connectors.forEach(function(R){R.obstaclePointCollection=[]}));var c=this.complexHierarchicalTreeModule.getLayoutNodesCollection(this.nodes);c.length>0&&this.complexHierarchicalTreeModule.doLayout(c,this.nameTable,this.layout,l,this),e=!0,this.canDistribute(a,r)&&this.lineDistributionModule.initLineDistribution(this.layout,this)}else this.flowchartLayoutModule?(this.flowchartLayoutModule.updateLayout(this.nodes,this),e=!0):console.warn("[WARNING] :: Module "+("OrganizationalChart"===this.layout.type?"HierarchicalTree":this.layout.type)+" is not available in Diagram component! You either misspelled the module name or forgot to load it.");if(e){this.preventDiagramUpdate=!0;for(var u={},f=0,g=o;f0)for(var S=0;S0)for(var M=0;M0)for(var s=0,o=r.ports;s0&&function Ese(n){var t,e,i,r=[];for(t=0;t0&&y.connectors[w].bezierSettings&&y.connectors[w].bezierSettings.allowSegmentsReset&&(y.connectors[w].segments=[]);if(t.connectors=y.connectors||[],t.dataSourceSettings=y.dataSourceSettings||{},t.dataSourceSettings.doBinding=i,t.height=y.height||"100%",t.setNodeTemplate=r,t.getConnectorDefaults=v,t.getNodeDefaults=g,t.getCustomProperty=o,t.mode=y.mode||"SVG",y.nodes)for(w=0;w0)){var r=this.nodes.filter(function(a){return 0===a.inEdges.length})[0],s=this.convertMindmapToMermaid(r,0);i.push(s),this.updateTextDataSource(i,r.outEdges,1),e=(i=i.filter(function(a){return""!==a.trim()})).join("\n")}return e},t.prototype.updateTextDataSource=function(e,i,r){for(var s=0;s0&&this.updateTextDataSource(e,h,r+1),s++}},t.prototype.convertMindmapToMermaid=function(e,i){var r=e.id,o=" ".repeat(2*(i+1)),a=e.annotations.length>0?e.annotations[0].content.replace(/\n/g," "):"",l=o+a,h=o+r;if(e.shape&&"Basic"===e.shape.type){var c=e.shape;"Rectangle"===c.shape?l=h+"["+a+"]":"Ellipse"===c.shape?l=h+"(("+a+"))":"Hexagon"===c.shape&&(l=h+"{{"+a+"}}")}else if(e.shape&&"Flow"===e.shape.type)"Terminator"===e.shape.shape&&(l=h+"("+a+")");else if(e.shape&&"Path"===e.shape.type){var u=e.shape;u.data===this.bangShape?l=h+"))"+a+"((":u.data===this.cloudShape&&(l=h+")"+a+"(")}return l},t.prototype.saveFlowDiagramInMermaidFormat=function(){var e=this,i=[],r="graph TD\n",s={nodes:this.nodes,edges:this.connectors};return s.nodes.reduce(function(a,l){return a[l.id]=l.annotations.length?l.annotations[0].content:"",a},{}),s.edges.forEach(function(a){var l=a.sourceID,h=a.targetID,p=e.nameTable[""+h],f=e.getNodeShape(e.nameTable[""+l]),g=e.getNodeShape(p),v=a.annotations[0]&&""!==a.annotations[0].content?"|"+a.annotations[0].content+"|":"";-1===i.indexOf(l)?i.push(l):f="",-1===i.indexOf(h)?i.push(h):g="";var y=e.arrowType(a);r+=" "+l+f+" "+y+v+" "+h+g+"\n"}),s.nodes.forEach(function(a){r+=" style "+a.id+" fill:"+a.style.fill+",stroke:"+a.style.strokeColor+",stroke-width:"+a.style.strokeWidth+"px;\n"}),r},t.prototype.arrowType=function(e){var i=e.targetDecorator.shape;return e.style.opacity<1?"~~~":""!==e.style.strokeDashArray?"-.->":"Arrow"===i?e.style.strokeWidth>1?"==>":"--\x3e":"None"===i?"---":"--\x3e"},t.prototype.getNodeShape=function(e){var i=e.annotations.length>0?e.annotations[0].content:"",r=e.shape.shape;if(!r){var s=e.shape.data;return"M 0 0 A 1 1 0 0 0 7 0 A 1 1 0 0 0 0 0 M -1 0 A 1 1 0 0 0 8 0 A 1 1 0 0 0 -1 0"===s?"((("+i+")))":"M 0 0 L 1 -1 L 5 -1 L 6 0 L 0 0"===s?"[/"+i+"\\]":"M 0 1 L 0 6 C 2 7 4 7 6 6 L 6 1 C 5 0 1 0 0 1 C 1 2 5 2 6 1"===s?"[("+i+")]":"M 0 0 L 12 0 L 14 2 L 2 2 L 0 0"===s?"[\\"+i+"\\]":"M 0 0 L 5 0 L 4 1 L 1 1 L 0 0"===s?"[\\"+i+"/]":"M 0 0 L 2 -2 L 11 -2 L 13 0 L 11 2 L 2 2 L 0 0"===s?"{{"+i+"}}":">"+i+"]"}switch(r){case"Terminator":return"(["+i+"])";case"Process":default:return"["+i+"]";case"Decision":return"{"+i+"}";case"Parallelogram":return"[/"+i+"/]";case"Ellipse":return"(("+i+"))";case"PreDefinedProcess":return"[["+i+"]]"}},t.prototype.loadDiagramFromMermaid=function(e){this.layout&&"Flowchart"===this.layout.type&&this.flowchartLayoutModule?this.convertMermaidToFlowChart(e):this.layout&&"MindMap"===this.layout.type&&this.mindMapChartModule?this.convertMermaidToMindmap(e):console.warn('[WARNING] :: Module "FlowchartLayout" or "MindMap" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.countLeadingSpaces=function(e){for(var i=0,r=e.length;i0});this.clear(),this.mermaidNodeBaseCollection=[];var r=[],s={text:"",children:[],currentLevel:0,branch:"Left"},o=[],l=!1,h=!1,c=!1;if(i.length>0){for(var d=function(M){var w=i[parseInt(M.toString(),10)],C=0,D="",A=u.countLeadingSpaces(w),x=w.includes('"`');if(h=w.includes('`"'),c=(l=!!x||l)||c?c:0===A&&M>0,l&&h&&!x)return s.text+="\n"+w,l=!1,"continue";if(!x&&l)return s.text+="\n"+w,"continue";if(l=!h&&l,w.length>0&&(/\s/.test(w[0])&&M>0||0===A)){if(-1!==o.findIndex(function(B){return B.space===A.toString()}))for(var L=o.length-1;L>=0;L--){var O=o[parseInt(L.toString(),10)];if((N=parseFloat(O.space))>A)o.splice(L,1);else{if(N=0;L--){var N,T=o[parseInt(L.toString(),10)];if(!((N=parseFloat(T.space))>A)){var P=o[o.length-1];o.push({space:A.toString(),level:P.level+1});break}o.splice(L,1)}C=o[o.length-1].level}D=w.trim().replace(/^[+-]/,"")}var _={text:D,branch:void 0,children:[],currentLevel:0===M?0:C-1};if(r.length>0){for(;r.length>=C&&0!==r.length;)r.pop();r.length>0&&r[r.length-1].children.push(_)}r.push(_),s=_},u=this,p=0;p0){var c=h[h.length-1];c.arrowType=a[2],""!==a[3]&&(c.label&&c.label.some(function(d){return d.trim().length>0})?c.label.push(a[3]):(c.label=[],c.label[c.parentId.length-1]=a[3]))}h.filter(function(d){return d.parentId&&0===d.parentId.length}).forEach(function(d){d.parentId=null}),i=i.concat(h)}}this.createFlowChart(i),this.doLayout(),this.clearHistory()},t.prototype.createFlowChart=function(e){for(var i=[],r=0;r1)for(var h=0;h|---|--\s*.*?\s*-->|~~~|==>|===|==\s*.*?\s*==>|\s*-\.\s*->|\s*-\.\s*-|\s*-\.\s*.*?\s*\.\s*->|\s*-\..*?\.\s*->)(.*)$/);if(l){i=l[1].trim();var h=l[2].trim();r=l[3].trim();var d=h.match(/(-\.|\\-\\-|==|--|~~)(.*?)(\1>|\.->|==>|\\->|~~>)/),u=void 0,p="";o=null!==(u=d?{text:d[2].trim()||null,arrowType:d[1]+d[3]}:{text:null,arrowType:h}).text?u.text:"",s=(p=u.arrowType).includes("--\x3e")?"single-line-arrow":p.includes("---")?"single-line":p.includes("==>")?"double-line-arrow":p.includes("==")?"double-line":p.includes("~~~")?"wiggly-arrow":p.includes("-.->")||p.includes(".->")?"dotted-arrow":p.includes("-.-")||p.includes(".-")?"dotted":"single-line-arrow"}return[i,r,s,o]},t.prototype.parseStyle=function(e,i){if(e.startsWith("style")){var s=e.match(/^style\s+(\w+)\s+fill:([^,]+),stroke:([^,]+),stroke-width:(\d+)px;/);if(s){var c={id:s[1],fill:s[2],stroke:s[3],strokeWidth:parseInt(s[4],10)},d=i.filter(function(u){return u.id===c.id});d[0].color=c.fill,d[0].stroke=c.stroke,d[0].strokeWidth=c.strokeWidth}}},t.prototype.getNodeData=function(e,i,r){for(var s=[],o=null,a=null,l=0,h="",c=function(v){var y=e[parseInt(v.toString(),10)],S=d.splitNested(y);if(S[0].includes("|")){var b=S[0].match(/\|([^|]*)\|/);b&&(h=b[1]);var M=S[0].split("|");M.length>=3&&(S[0]=M[2].trim())}var w=S[0].trim();if(0===v?o=w:a=w,i.find(function(L){return L.id===w}))l++;else{var D=S.length>1?S[1]:S[0],A=d.getShape(D),x=D.replace(/[\\[\]\\(\\)\\{\\}\\{\\}\\/>]/g,"");s.push({id:w,name:x,shape:A,color:"white",parentId:[]})}},d=this,u=0;u"===h?0===s?(r.trim().length>0&&i.push(r.trim()),r=h,o=h,s++):(r+=h,s++):"]"===h||"}"===h||")"===h?1===s&&h===o?(i.push((r+=h).trim()),r="",s--):s>1?(r+=h,s--):r+=h:r+=h}return r.trim().length>0&&i.push(r.trim()),i},t.prototype.getShape=function(e){var i={};return e.startsWith("(((")?i={type:"Path",data:"M 0 0 A 1 1 0 0 0 7 0 A 1 1 0 0 0 0 0 M -1 0 A 1 1 0 0 0 8 0 A 1 1 0 0 0 -1 0"}:e.startsWith("((")?i={shape:"Ellipse",type:"Basic"}:e.startsWith("([")?i={type:"Flow",shape:"Terminator"}:e.startsWith("(")?i={type:"Flow",shape:"Process"}:e.startsWith("[[")?i={type:"Flow",shape:"PreDefinedProcess"}:e.startsWith("[/")?i=e.endsWith("/]")?{type:"Basic",shape:"Parallelogram"}:{type:"Path",data:"M 0 0 L 1 -1 L 5 -1 L 6 0 L 0 0"}:e.startsWith("[(")?i={type:"Path",data:"M 0 1 L 0 6 C 2 7 4 7 6 6 L 6 1 C 5 0 1 0 0 1 C 1 2 5 2 6 1"}:e.startsWith("[\\")?i=e.endsWith("\\]")?{type:"Path",data:"M 0 0 L 12 0 L 14 2 L 2 2 L 0 0"}:{type:"Path",data:"M 0 0 L 5 0 L 4 1 L 1 1 L 0 0"}:e.startsWith("[")?i={type:"Basic",shape:"Rectangle"}:e.startsWith("{{")?i={type:"Path",data:"M 0 0 L 2 -2 L 11 -2 L 13 0 L 11 2 L 2 2 L 0 0"}:e.startsWith("{")?i={type:"Flow",shape:"Decision"}:e.startsWith(">")&&(i={type:"Path",data:"M 0 0 L 8 0 L 8 2 L 0 2 L 2 1 L 0 0"}),i},t.prototype.getDiagramContent=function(e){return this.printandExportModule?this.printandExportModule.getDiagramContent(e):(console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),"")},t.prototype.exportImage=function(e,i){this.printandExportModule?this.printandExportModule.exportImages(e,i):console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.printImage=function(e,i){this.printandExportModule?(i.printOptions=!0,this.printandExportModule.exportImages(e,i)):console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.setStackLimit=function(e){this.undoRedoModule&&e&&(this.historyManager.stackLimit=e,this.undoRedoModule.applyLimit(this.historyManager.currentEntry,e,this,!0))},t.prototype.clearHistory=function(){this.undoRedoModule&&this.undoRedoModule.clearHistory(this)},t.prototype.getDiagramBounds=function(){if(this.printandExportModule){var e=this.printandExportModule.getDiagramBounds("",{});return e.width=e.width>this.scrollSettings.viewPortWidth?e.width+(e.x>0?e.x:0):this.scrollSettings.viewPortWidth,e.height=e.height>this.scrollSettings.viewPortHeight?e.height+(e.y>0?e.y:0):this.scrollSettings.viewPortHeight,e.x=e.x>0?0:e.x,e.y=e.y>0?0:e.y,e}return console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),new Ne},t.prototype.exportDiagram=function(e){return this.printandExportModule?this.printandExportModule.exportDiagram(e):(console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),"")},t.prototype.print=function(e){this.printandExportModule?this.printandExportModule.print(e):console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.addPorts=function(e,i){var s;this.protectPropertyChange(!0),e=this.nameTable[e.id]||e,i.length>1&&this.startGroupAction();for(var o=function(h){if(e.ports.some(function(y){return y.id===i[parseInt(h.toString(),10)].id}))return"continue";if(e instanceof te?(s=new Es(e,"ports",i[parseInt(h.toString(),10)],!0),e.ports.push(s)):e instanceof de&&(s=new xc(e,"ports",i[parseInt(h.toString(),10)],!0),e.ports.push(s)),e.children)for(var c=e.wrapper,d=0;d1&&this.endGroupAction(),e.wrapper.measure(new me(e.width,e.height)),e.wrapper.arrange(e.wrapper.desiredSize),this.updateDiagramObject(e),this.protectPropertyChange(!1)},t.prototype.addConstraints=function(e,i){return e|i},t.prototype.removeConstraints=function(e,i){return e&~i},t.prototype.addNodeLabels=function(e,i){this.addLabels(e,i)},t.prototype.addConnectorLabels=function(e,i){this.addLabels(e,i)},t.prototype.addLabels=function(e,i){this.protectPropertyChange(!0);var s,r=(e=this.nameTable[e.id]||e).wrapper;i.length>1&&this.startGroupAction();for(var o=0;o1&&this.endGroupAction(),e.wrapper.measure(new me(r.width,r.height)),e.wrapper.arrange(r.desiredSize),this.updateDiagramObject(e),this.protectPropertyChange(!1),this.refreshCanvasLayers()},t.prototype.addChildToUmlNode=function(e,i,r){var s,o,a,l,h="NoWrap";"Class"===e.shape.classifier||"Interface"===e.shape.classifier?"Method"===r?(o=new hm(e,"",i),"Class"===e.shape.classifier?(e.shape.classShape.methods.push(o),s=e.shape.classShape):"Interface"===e.shape.classifier&&(e.shape.interfaceShape.methods.push(o),s=e.shape.interfaceShape),function Xse(n,t,e,i){if(e.methods&&e.methods.length){var r=e.methods,s="",o="",a=void 0,l=1,h=void 0,c=0,d=0,u=n.shape,g="Class"===u.classifier?u.classShape:u.interfaceShape;1===r.length?g.attributes.length>0?(c=g.attributes.filter(function(w){return w.isSeparator}).length,h=(l=2+g.attributes.length+c)+1,nT(n,t,l)):h=l+1:(c=g.attributes.filter(function(w){return w.isSeparator}).length,d=g.methods.filter(function(w){return w.isSeparator}).length,h=(l=2+g.attributes.length+c+g.methods.length+d)+1);for(var v=0;v1&&this.startGroupAction();for(var r=i.length-1;r>=0;r--)if(e.children&&e.children.length>0){var s=e.wrapper.children.filter(function(o){return o.id===e.id+"group_container"});s&&s.length>0&&this.removelabelExtension(e,i,r,s[0])}else this.removelabelExtension(e,i,r,e.wrapper);i.length>1&&this.endGroupAction(),this.refreshCanvasLayers()},t.prototype.removePortsExtenion=function(e,i,r,s){for(var o=0;o1&&this.startGroupAction();for(var r=i.length-1;r>=0;r--)if(e.children&&e.children.length>0)for(var s=0;s1&&this.endGroupAction()},t.prototype.getSizeValue=function(e,i){var r;return r=e.toString().indexOf("px")>0?e.toString():e.toString().indexOf("%")>0?void 0!==i?"100%":e.toString():e.toString()+"px",i&&(qa(this),r="calc("+r+" - "+i+"px)"),r},t.prototype.renderRulers=function(){this.rulerSettings.showRulers?(function Yne(n){var t=qa(n),i=Tt("div",{id:n.element.id+"_overlapRuler",style:"height:"+t.height+"px;width:"+t.width+"px;position:absolute;left:0;top:0",class:"e-ruler-overlap"});n.element.insertBefore(i,n.element.firstChild)}(this),eF(this,!0),eF(this,!1)):Qx(this)},t.prototype.intOffPageBackground=function(){var e=new me;e=qa(this);var i=document.getElementById(this.element.id+"content"),r=this.getSizeValue(this.width,e.width),s=this.getSizeValue(this.height,e.height),o=this.rulerSettings.showRulers?"width:"+r+"; height:"+s+";top:"+e.height+"px;left:"+e.width+"px;overflow: scroll;position:absolute;overflow:auto;":"width:"+r+"; height:"+s+";position:absolute; left:0px; top:0px;overflow: auto;",a={id:this.element.id+"content",tabindex:"0",style:o};i?(this.diagramCanvas=i,Za(this.diagramCanvas,o)):(this.diagramCanvas=Tt("div",a),this.element.appendChild(this.diagramCanvas)),this.diagramCanvas.style.background=this.backgroundColor},t.prototype.initDiagram=function(){this.intOffPageBackground(),Ho(this.element,{style:"width:"+this.getSizeValue(this.width)+"; height:"+this.getSizeValue(this.height)+";position:relative;overflow:hidden;"})},t.prototype.renderHiddenUserHandleTemplateLayer=function(e){var r=Tt("div",{class:this.element.id+"_hiddenUserHandleTemplate",style:"width:"+e.width+"px; height:"+e.height+"px;visibility:hidden ; overflow: hidden;"});this.element.appendChild(r)},t.prototype.renderBackgroundLayer=function(e,i){var r=this.createSvg(this.element.id+"_backgroundLayer_svg",e.width,e.height);Za(r,i);var s=Bi("g",{id:this.element.id+"_backgroundImageLayer",class:"e-background-image-layer"});r.appendChild(s);var a=Bi("g",{id:this.element.id+"_backgroundLayer",class:"e-background-layer"});r.appendChild(a),this.diagramCanvas.appendChild(r)},t.prototype.renderGridLayer=function(e,i){var r=this.createSvg(this.element.id+"_gridline_svg",e.width,e.height);r.setAttribute("class","e-grid-layer");var s=Bi("g",{id:this.element.id+"_gridline"}),o=Bi("rect",{id:this.element.id+"_grid_rect",x:"0",y:"0",width:"100%",height:"100%"});if(nm()){var a=new URL(window.location.href);o.setAttribute("fill",""!==a.search?"url(#"+this.element.id+"_pattern)":"url("+location.protocol+"//"+location.host+location.pathname+"#"+this.element.id+"_pattern)")}else o.setAttribute("fill","url(#"+this.element.id+"_pattern)");s.appendChild(o),r.appendChild(s),this.diagramCanvas.appendChild(r),ai(r,{style:i})},t.prototype.renderDiagramLayer=function(e,i){if(this.diagramLayerDiv=Tt("div",{id:this.element.id+"_diagramLayer_div",style:"width:"+e.width+"px; height:"+e.height+"px;"+i}),"SVG"===this.mode){var s=this.createSvg(this.element.id+"_diagramLayer_svg",e.width,e.height);s.style["pointer-events"]="none",s.setAttribute("class","e-diagram-layer");var o=Bi("g",{id:this.element.id+"_diagramLayer"}),a=Bi("g",{});this.diagramLayer=o,s.style["pointer-events"]="all",a.appendChild(o),s.appendChild(a),this.diagramLayerDiv.appendChild(s)}else this.diagramLayer=bo.createCanvas(this.element.id+"_diagram",e.width,e.height),Za(this.diagramLayer,"position:absolute;left:0px;top:0px;"),this.diagramLayerDiv.appendChild(this.diagramLayer);this.diagramCanvas.appendChild(this.diagramLayerDiv)},t.prototype.initLayers=function(){var e="position:absolute;top:0px;left:0px;overflow:hidden;pointer-events:none;",r=document.getElementById(this.element.id).getBoundingClientRect(),s=function Soe(){var n=Tt("div",{style:"visibility:hidden; width: 100px"});document.body.appendChild(n);var t=n.getBoundingClientRect().width;n.style.overflow="scroll";var e=Tt("div",{style:"width:100%"});n.appendChild(e);var i=e.getBoundingClientRect().width;return n.parentNode.removeChild(n),t-i}();this.scroller.scrollerWidth=s,this.scroller.setViewPortSize(r.width,r.height),this.renderRulers();var o="measureElement";window[""+o]&&(window[""+o]=null,document.getElementById("measureElement").remove()),function BF(){var n="measureElement";if(window[""+n])window[""+n].usageCount+=1;else{var t=Tt("div",{id:"measureElement",style:"visibility:hidden ; height: 0px ; width: 0px; overflow: hidden;"}),e=Tt("span",{style:"display:inline-block ; line-height: normal"});t.appendChild(e);var i=Tt("img",{alt:"measureElementImage",src:"data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7"});t.appendChild(i);var r=document.createElementNS("http://www.w3.org/2000/svg","svg");r.setAttribute("xmlns:xlink","http://www.w3.org/1999/xlink"),t.appendChild(r);var s=document.createElementNS("http://www.w3.org/2000/svg","path");s.setAttribute("d",""),r.appendChild(s),document.createTextNode("");var a=document.createElementNS("http://www.w3.org/2000/svg","text");a.setAttributeNS("http://www.w3.org/XML/1998/namespace","xml:space","preserve"),r.appendChild(a),window[""+n]=t,window[""+n].usageCount=1,document.body.appendChild(t);var l="measureElementCount";window[""+l]?window[""+l]++:window[""+l]=1}}(),this.renderBackgroundLayer(r,e),this.renderGridLayer(r,e),this.renderDiagramLayer(r,e),this.renderHTMLLayer(r,e),this.renderPortsExpandLayer(r,e),this.renderNativeLayer(r,e),this.renderAdornerLayer(r,e),this.renderHiddenUserHandleTemplateLayer(r)},t.prototype.renderAdornerLayer=function(e,i){var r=Tt("div",{id:this.element.id+"_diagramAdornerLayer",style:"width:"+e.width+"px;height:"+e.height+"px;"+i}),s=Tt("div",{id:this.element.id+"_diagramUserHandleLayer",style:"width:"+e.width+"px;height:"+e.height+"px;"+i});s.setAttribute("class","e-userHandle-layer"),r.appendChild(s);var o=this.createSvg(this.element.id+"_diagramAdorner_svg",e.width,e.height);o.setAttribute("class","e-adorner-layer"),o.style["pointer-events"]="none",this.adornerLayer=Bi("g",{id:this.element.id+"_diagramAdorner"}),this.adornerLayer.style[" pointer-events"]="all",o.appendChild(this.adornerLayer),r.appendChild(o),this.diagramCanvas.appendChild(r);var a=Bi("g",{id:this.element.id+"_SelectorElement"});this.adornerLayer.appendChild(a),ai(o,{style:"pointer-events:none;"})},t.prototype.renderPortsExpandLayer=function(e,i){var r=this.createSvg(this.element.id+"_diagramPorts_svg",e.width,e.height);r.setAttribute("class","e-ports-expand-layer");var s=Bi("g",{id:this.element.id+"_diagramPorts",class:"e-ports-layer",style:"pointer-events: all;"});r.appendChild(s);var o=Bi("g",{id:this.element.id+"_diagramExpander",class:"e-expand-layer",style:"pointer-events: all;"});r.appendChild(o),this.diagramCanvas.appendChild(r),ai(r,{style:i})},t.prototype.renderHTMLLayer=function(e,i){this.htmlLayer=Tt("div",{id:this.element.id+"_htmlLayer",style:"width:"+e.width+"px; height:"+e.height+"px;position:absolute;top:0px;left:0px;overflow:hidden;pointer-events:none;",class:"e-html-layer"});var r=Tt("div",{id:this.element.id+"_htmlLayer_div",style:"position:absolute;top:0px;left:0px;pointer-events:all;"});this.htmlLayer.appendChild(r),this.diagramCanvas.appendChild(this.htmlLayer)},t.prototype.renderNativeLayer=function(e,i){var r=this.createSvg(this.element.id+"_nativeLayer_svg",e.width,e.height),s=Bi("g",{id:this.element.id+"_nativeLayer",style:"pointer-events:all;"});r.appendChild(s),this.diagramLayerDiv.appendChild(r),ai(r,{class:"e-native-layer",style:i})},t.prototype.createSvg=function(e,i,r){var s=document.createElementNS("http://www.w3.org/2000/svg","svg");return ai(s,{id:e,width:i,height:r}),s},t.prototype.updateBazorShape=function(){for(var e=0;e1,i=[],r={},s={},o=[],a=0,l=this.nodes;a0||b&&b.children&&b.children.length>0)&&(M=!1),S&&S.wrapper&&b&&b.wrapper&&M?this.initConnectors(r[""+h],f):i.push(r[""+h])}else b=r[y.targetID],(S=r[y.sourceID])&&S.children&&S.children.length>0||b&&b.children&&b.children.length>0?i.push(r[""+h]):this.initConnectors(r[""+h],f);else r[""+h].children?o.push(h):r[""+h].shape instanceof hT&&r[""+h].shape.activity.subProcess.processes&&r[""+h].shape.activity.subProcess.processes.length>0?s[r[""+h].id]=h:this.initNodes(r[""+h],f);if(this.bpmnModule)for(var w=0,C=this.bpmnModule.bpmnTextAnnotationConnector;w-1&&-1===r.indexOf(c)&&-1===s.indexOf(c)&&r.splice(0,0,c);-1===r.indexOf(o)&&s.push(o)}return r.concat(s)},t.prototype.addToLayer=function(e,i){var r;if(i&&(r=this.commandHandler.getObjectLayer(e.id)),(!i||!r)&&-1===this.activeLayer.objects.indexOf(e.id)&&this.activeLayer.objects.push(e.id),(e instanceof te||e instanceof de)&&("SwimLane"!==e.shape.type||e.children&&e.children.length>0)){if(e.parentId){var s=this.swimlaneZIndexTable[e.parentId],o=this.swimlaneChildTable[e.id];(s&&-1!==s||o&&-1!==o)&&(e.zIndex=this.swimlaneChildTable[e.id])}e instanceof de&&e.sourceID&&e.targetID?-1!==this.activeLayer.objects.indexOf(e.sourceID)&&-1!==this.activeLayer.objects.indexOf(e.targetID)&&this.setZIndex(r||this.activeLayer,e):this.setZIndex(r||this.activeLayer,e)}},t.prototype.updateLayer=function(e){for(var i=0,r=Object.keys(e.layers);i0)for(r=0;rs;l--)r.zIndexTable[parseInt(l.toString(),10)]=r.zIndexTable[l-1],this.nameTable[r.zIndexTable[parseInt(l.toString(),10)]]&&(this.nameTable[r.zIndexTable[parseInt(l.toString(),10)]].zIndex=l);r.zIndexTable[parseInt(a.toString(),10)]=i.id}}},t.prototype.initializeDiagramLayers=function(){for(var e=0;ethis.layers[parseInt(a.toString(),10)].zIndex&&(i=this.layers[parseInt(e.toString(),10)],this.layers[parseInt(e.toString(),10)]=this.layers[parseInt(a.toString(),10)],this.layers[parseInt(a.toString(),10)]=i);0===this.layers.length&&this.commandHandler.addLayer({id:"default_layer",visible:!0,lock:!1,objects:[],zIndex:0,objectZIndex:-1,zIndexTable:{}},null,!0),this.setActiveLayer(this.layers[this.layers.length-1].id)},t.prototype.resetTool=function(){this.eventHandler.resetTool()},t.prototype.initObjectExtend=function(e,i,r){if(r){var s=this.commandHandler.checkBoundaryConstraints(void 0,void 0,e.wrapper.bounds,!0);if("SwimLane"===e.shape.type)for(var o=0,a=Object.keys(i.zIndexTable);o0)&&this.setZIndex(i,e)),e instanceof te){if(r){if("helper"!==e.id&&(o=Zi(this.getNodeDefaults))){if((a=o(e,this))&&a.ports)for(var l=0;l0)for(l=0;l0&&!e.container||e.processId){var r=this.nameTable[e.id];if(!(this.realActions&$i.PreventScale||this.realActions&$i.PreventDrag)){if(r.offsetX&&(this.realActions&$i.EnableGroupAction||!(this.diagramActions&ee.UndoRedo||this.diagramActions&ee.ToolAction||this.diagramActions&ee.PublicMethod))){this.realActions|=$i.PreventScale;var s=r.offsetX-e.wrapper.offsetX;r.offsetX=e.wrapper.offsetX;var o=r.offsetY-e.wrapper.offsetY;r.offsetY=e.wrapper.offsetY,s+o!==0&&this.drag(r,s,o),this.realActions&=~$i.PreventScale}else r.offsetX=e.wrapper.offsetX;r.offsetY&&(this.realActions&$i.EnableGroupAction||!(this.diagramActions&ee.UndoRedo||this.diagramActions&ee.ToolAction||this.diagramActions&ee.PublicMethod))?(this.realActions|=$i.PreventScale,o=r.offsetY-e.wrapper.offsetY,r.offsetY=e.wrapper.offsetY,this.drag(r,0,o),this.realActions&=~$i.PreventScale):r.offsetY=e.wrapper.offsetY,this.diagramActions&&(r.width=e.wrapper.actualSize.width,r.height=e.wrapper.actualSize.height)}}i&&e.children&&e.children.length>0&&(void 0!==this.nameTable[e.id].width?this.scaleObject(e,this.nameTable[e.id].width,!0):this.nameTable[e.id].width=e.wrapper.actualSize.width,void 0!==this.nameTable[e.id].height?this.scaleObject(e,this.nameTable[e.id].height,!1):this.nameTable[e.id].height=e.wrapper.actualSize.height)},t.prototype.initNode=function(e,i,r){var a,p,s=e.initContainer(),o=new Ii;if(this.diagramSettings.inversedAlignment||(s.inversedAlignment=!1),s.children||(s.children=[]),e.children){s.measureChildren=!1,o.id=e.id+"group_container",o.style.fill=e.shape&&"SwimLane"===e.shape.type?e.style.fill:"none",o.style.strokeColor="none",o.horizontalAlignment="Stretch",o.verticalAlignment="Stretch",o.pivot=e.pivot,s.style=e.style,s.padding.left=e.padding.left,s.padding.right=e.padding.right,s.padding.top=e.padding.top,s.padding.bottom=e.padding.bottom,o.children=[],o.preventContainer=!0,e.container&&(o.relativeMode="Object");var l=!!(e.ports&&e.ports.length>0);if(m(e.container)&&!l&&s.children.push(o),e.container&&"Grid"===e.container.type)for(var h=0;h0&&e.wrapper.children[0]instanceof Wv){if(this.setZIndex(this.activeLayer,e),this.connectors.length>0)for(h=0;h0?i.phases.length:0,v="Horizontal"===i.orientation,y=v?i.phases.length||1:s.length+1,S=v?(i.header&&i.hasHeader?1:0)+(i.phases.length>0?1:0)+i.lanes.length:(i.header&&i.hasHeader?1:0)+i.phases.length;if(0===h&&!v&&i.lanes.length&&(S+=1),v?(a=(i.header&&i.hasHeader?1:0)+(h>0?1:0),l=0):(a=i.header&&i.hasHeader?1:0,l=h>0?1:0),s.length>0)for(o+=i.header&&i.hasHeader?i.header.height:0,p=0;pl?d.margin.left=d.margin.left-(u.bounds.left-e.bounds.left):u.children[0].children[1].actualSize.width+r>=d.margin.left&&(d.margin.left=u.children[0].children[1].actualSize.width+r),d.margin.lefta?d.margin.top=d.margin.top-(u.bounds.top-o):u.children[0].children[1].actualSize.height+r>=d.margin.top&&(d.margin.top=u.children[0].children[1].actualSize.height+r),d.margin.left0)for(o=0;o0&&this.updateChildPosition(e)},t.prototype.addBpmnAnnotationConnector=function(e,i){if(e.parentObj instanceof t||e.parentObj instanceof Rd){var r=e.shape,o=""!==r.textAnnotation.textAnnotationTarget&&this.nameTable[r.textAnnotation.textAnnotationTarget],a=o?this.nameTable[r.textAnnotation.textAnnotationTarget]:null,l=null!=a?a.wrapper:null,h=e.ports[0],c={x:0,y:0};switch(r.textAnnotation.textAnnotationDirection){case"Left":h.offset={x:0,y:.5},c.x=i.bounds.left-40,c.y=i.bounds.bottom+30;break;case"Right":h.offset={x:1,y:.5},c.x=i.bounds.right+40,c.y=i.bounds.bottom+30;break;case"Top":h.offset={x:.5,y:0},c.x=i.bounds.right+30,c.y=i.bounds.top-40;break;case"Bottom":h.offset={x:.5,y:1},c.x=i.bounds.right+30,c.y=i.bounds.bottom+40;break;default:h.offset={x:0,y:.5},c.x=i.bounds.left-40,c.y=i.bounds.bottom+30,o&&null!=i&&null!=l&&(i.bounds.left>l.bounds.right?h.offset={x:0,y:.5}:i.bounds.rightl.bounds.top?h.offset={x:.5,y:0}:i.bounds.top0&&this.updateChildPosition(r)}},t.prototype.canExecute=function(){return!0},t.prototype.updateStackProperty=function(e,i,r){e.container&&"Stack"===e.container.type&&(i.width||(i.wrapper.horizontalAlignment="Stretch",i.horizontalAlignment="Stretch"),i.height||(i.verticalAlignment="Stretch",i.wrapper.verticalAlignment="Stretch"),r&&"UmlClassifier"===e.shape.type&&(i.umlIndex=r))},t.prototype.initViews=function(){this.isLoading||(this.views.push(this.element.id),this.views[this.element.id]=this)},t.prototype.initCommands=function(){var e=this.commandManager.commands,i={copy:{execute:this.copyCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.C,keyModifiers:pt.Control}},paste:{execute:this.pasteCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.V,keyModifiers:pt.Control}},cut:{execute:this.cutCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.X,keyModifiers:pt.Control}},delete:{execute:this.removeCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Delete}},selectAll:{execute:this.selectAll.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.A,keyModifiers:pt.Control}},undo:{execute:this.undo.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Z,keyModifiers:pt.Control}},redo:{execute:this.redo.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Y,keyModifiers:pt.Control}},nudgeUp:{execute:this.nudgeCommand.bind(this,"Up"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Up},parameter:"up"},nudgeRight:{execute:this.nudgeCommand.bind(this,"Right"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Right},parameter:"right"},nudgeDown:{execute:this.nudgeCommand.bind(this,"Down"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Down},parameter:"down"},nudgeLeft:{execute:this.nudgeCommand.bind(this,"Left"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Left},parameter:"left"},startEdit:{execute:this.startEditCommad.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.F2}},endEdit:{execute:this.endEditCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Escape}},focusToNextItem:{execute:this.navigateItems.bind(this,!0),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Tab}},focusToPreviousItem:{execute:this.navigateItems.bind(this,!1),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Tab,keyModifiers:pt.Shift}},selectFocusedItem:{execute:this.startEditCommad.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Enter}},bold:{execute:this.fontStyleCommand.bind(this,"bold"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.B,keyModifiers:pt.Control}},italic:{execute:this.fontStyleCommand.bind(this,"italic"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.I,keyModifiers:pt.Control}},underline:{execute:this.fontStyleCommand.bind(this,"underline"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.U,keyModifiers:pt.Control}},duplicate:{execute:this.duplicateCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.D,keyModifiers:pt.Control}},group:{execute:this.groupCommand.bind(this,"group"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.G,keyModifiers:pt.Control}},ungroup:{execute:this.groupCommand.bind(this,"ungroup"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.U,keyModifiers:pt.Control|pt.Shift}},rotateClockwise:{execute:this.rotateCommand.bind(this,"clockwise"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.R,keyModifiers:pt.Control}},rotateAntiClockwise:{execute:this.rotateCommand.bind(this,"antiClockwise"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.L,keyModifiers:pt.Control}},flipHorizontal:{execute:this.flipCommand.bind(this,"horizontal"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.H,keyModifiers:pt.Control}},flipVertical:{execute:this.flipCommand.bind(this,"vertical"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.J,keyModifiers:pt.Control}},pointerTool:{execute:this.toolCommand.bind(this,"pointer"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number1,keyModifiers:pt.Control}},textTool:{execute:this.toolCommand.bind(this,"text"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number2,keyModifiers:pt.Control}},connectTool:{execute:this.toolCommand.bind(this,"connect"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number3,keyModifiers:pt.Control}},freeForm:{execute:this.toolCommand.bind(this,"freeForm"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number5,keyModifiers:pt.Control}},lineTool:{execute:this.toolCommand.bind(this,"line"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number6,keyModifiers:pt.Control}},rectangleTool:{execute:this.toolCommand.bind(this,"rectangle"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number8,keyModifiers:pt.Control}},ellipseTool:{execute:this.toolCommand.bind(this,"ellipse"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number9,keyModifiers:pt.Control}},zoomIn:{execute:this.zoomCommand.bind(this,"zoomIn"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Plus,keyModifiers:pt.Control}},zoomOut:{execute:this.zoomCommand.bind(this,"zoomOut"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Minus,keyModifiers:pt.Control}},shiftUp:{execute:this.shiftCommand.bind(this,"Up"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Up,keyModifiers:pt.Shift}},shiftDown:{execute:this.shiftCommand.bind(this,"Down"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Down,keyModifiers:pt.Shift}},shiftLeft:{execute:this.shiftCommand.bind(this,"Left"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Left,keyModifiers:pt.Shift}},shiftRight:{execute:this.shiftCommand.bind(this,"Right"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Right,keyModifiers:pt.Shift}},alignTextCenter:{execute:this.alignCommand.bind(this,"center"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.C,keyModifiers:pt.Control|pt.Shift}},alignTextLeft:{execute:this.alignCommand.bind(this,"right"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.L,keyModifiers:pt.Control|pt.Shift}},alignTextRight:{execute:this.alignCommand.bind(this,"left"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.R,keyModifiers:pt.Control|pt.Shift}},alignTextTop:{execute:this.alignCommand.bind(this,"top"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.E,keyModifiers:pt.Control|pt.Shift}},alignTextCenterVertical:{execute:this.alignCommand.bind(this,"centerVertical"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.M,keyModifiers:pt.Control|pt.Shift}},alignTextBottom:{execute:this.alignCommand.bind(this,"bottom"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.V,keyModifiers:pt.Control|pt.Shift}},alignJustify:{execute:this.alignCommand.bind(this,"justify"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.J,keyModifiers:pt.Control|pt.Shift}},sendToBack:{execute:this.orderCommand.bind(this,"sendToBack"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.B,keyModifiers:pt.Control|pt.Shift}},bringToFront:{execute:this.orderCommand.bind(this,"bringToFront"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.F,keyModifiers:pt.Control|pt.Shift}},sendBackward:{execute:this.orderCommand.bind(this,"sendBackward"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.BracketLeft,keyModifiers:pt.Control}},bringForward:{execute:this.orderCommand.bind(this,"bringForward"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.BracketRight,keyModifiers:pt.Control}}};this.initCommandManager(e,i)},t.prototype.overrideCommands=function(e,i){for(var r,s=0,o=Object.keys(i);se.zIndex){("HTML"===e.shape.type||"Native"===e.shape.type)&&(o="HTML"===e.shape.type?"html":"native"),s=foe(i,r[parseInt(a.toString(),10)].id,o);break}return s},t.prototype.updateDiagramObject=function(e,i,r){for(var s,o="domTable",a=0,l=this.views;a1&&(d=this.commandHandler.getObjectLayer(e.id)),void 0===d||d&&d.visible||r){var u=Io(this.element.id);window[""+o][s.element.id+"_diagramLayer"]||(window[""+o][s.element.id+"_diagramLayer"]=document.getElementById(s.element.id+"_diagramLayer"));var p=window[""+o][s.element.id+"_diagramLayer"];this.diagramActions&ee.Interactions&&this.updateCanupdateStyle(e.wrapper.children,!0);var f=this.getMidPoint(e);this.diagramRenderer.updateNode(e.wrapper,p,u,void 0,i?void 0:this.getZindexPosition(e,s.element.id),f,this.portCenterPoint),this.updateCanupdateStyle(e.wrapper.children,!0)}}},t.prototype.applyMarginBezier=function(e,i){i.cx=i.cx+e.margin.left,i.cx=i.cx-e.margin.right,i.cy=i.cy+e.margin.top,i.cy=i.cy-e.margin.bottom},t.prototype.getMidPoint=function(e){var i;if(e instanceof de&&"Bezier"===e.type){i=[];for(var r=this.getBezierPoints(e),s=z.getLengthFromListOfPoints(r),o=0;o0&&e.updateView(e));var s=Io(e.element.id);this.renderDiagramElements(e.diagramLayer,e.diagramRenderer,s,void 0,void 0,i);for(var o=0;o0&&this.renderBasicElement(e),!this.diagramActions||!(this.diagramActions&ee.Render)||ee.ToolAction&this.diagramActions||Ds(this)||1!==this.scroller.currentZoom?this.refreshElements(e):this.renderTimer||(this.renderTimer=setTimeout(function(){i.refreshElements(e)},40)))},t.prototype.updatePortVisibility=function(e,i,r){var s;if((e instanceof te||e instanceof de)&&(!this.drawingObject||!this.drawingObject.shape)&&to(e)){for(var a=e.ports,l=!1,h=0;h=0&&this.scroller.removeCollection.splice(l,1);var h=this.nameTable[e[parseInt(a.toString(),10)]];this.updateTextElementValue(h),this.diagramRenderer.renderElement(h.wrapper,s,o,void 0,void 0,void 0,void 0,h.zIndex)}for(var c=0;c0?this.scroller.oldCollectionObjects:void 0,b=Object.keys(S||g.zIndexTable);b.sort(function(N,T){return parseInt(""+N,10)-parseInt(""+T,10)});for(var M=0,w=b;M0?h:0)+"px",y=(this.realActions&$i.vScrollbarMoved?0:-(this.scroller.verticalOffset<0?this.scroller.verticalOffset:0))+"px"):(v="0px",y="0px"),this.realActions&$i.hScrollbarMoved&&(this.realActions=this.realActions&~$i.hScrollbarMoved),this.realActions&$i.vScrollbarMoved&&(this.realActions=this.realActions&~$i.vScrollbarMoved)):(v=(l.x<0?h:-this.scroller.horizontalOffset)+"px",y=(l.y<0?c:-this.scroller.verticalOffset)+"px"),this.diagramLayer.style.left=v,this.diagramLayer.style.top=y,A.tx=-l.x/A.scale,A.ty=-l.y/A.scale);var R=!0;if(o&&(R=!1),this.updateTextElementValue(D),this.refreshing&&D.shape.activity&&D.shape.activity.subProcess&&D.shape.activity.subProcess.processes){for(var L=0;L0){var o=s.children[0],a=o.data;(r.isBezierEditing&&this.selectedItems.connectors[0].id===r.id||"Bezier"!==r.type)&&r.getSegmentElement(r,o,"ComplexHierarchicalTree"===this.layout.type||"HierarchicalTree"===this.layout.type?this.layout.orientation:void 0,void 0,!1),o.data!==a&&(s.measure(new me),s.arrange(s.desiredSize),"SVG"===this.mode&&!e&&this.updateDiagramObject(r))}}else this.constraints&rt.Bridging&&console.warn('[WARNING] :: Module "ConnectorBridging" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.setCursor=function(e){this.diagramRenderer.setCursor(this.diagramCanvas,e)},t.prototype.clearCanvas=function(e){var i=e.contentWidth||e.diagramLayer.width/this.scroller.currentZoom,r=e.contentHeight||e.diagramLayer.height/this.scroller.currentZoom;"SVG"!==e.mode&&bo.getContext(e.diagramLayer).clearRect(0,0,i,r)},t.prototype.updateScrollOffset=function(){this.scroller.setScrollOffset(this.diagramCanvas.scrollLeft,this.diagramCanvas.scrollTop),XI(this),Ds(this)&&this.scroller.virtualizeElements()},t.prototype.setOffset=function(e,i){var r="domTable";window[""+r][this.element.id+"content"]||(window[""+r][this.element.id+"content"]=document.getElementById(this.element.id+"content"));var s=window[""+r][this.element.id+"content"];s&&(s.scrollLeft=e,s.scrollTop=i)},t.prototype.setSize=function(e,i){if(this.diagramLayer&&!this.preventDiagramUpdate){var r=qa(this);e-=r.width,i-=r.height;var s=this.spatialSearch.getPageBounds();s.x*=this.scroller.currentZoom,s.y*=this.scroller.currentZoom,s.width*=this.scroller.currentZoom,s.height*=this.scroller.currentZoom;var o="SVG"===this.mode?1:1.5,a="SVG"===this.mode?fT(this.element.id):this.diagramLayer,h="Canvas"===this.mode&&this.constraints&rt.Virtualization?this.scroller.viewPortHeight:i;a.setAttribute("width",(o*("Canvas"===this.mode&&this.constraints&rt.Virtualization?this.scroller.viewPortWidth:e)).toString()),a.setAttribute("height",(o*h).toString());var c=document.getElementById(this.element.id+"_diagramUserHandleLayer");c&&(c.style.width=e+"px",c.style.height=i+"px");var d={width:e.toString(),height:i.toString()};this.diagramLayerDiv.style.width=e+"px",this.diagramLayerDiv.style.height=i+"px",ai(kF(this.element.id),d),ai(function voe(n){return xt(n).getElementsByClassName("e-ports-expand-layer")[0]}(this.element.id),d);var u=Pl(this.element.id);ai(u,d),u.parentNode.style.width=e+"px",u.parentNode.style.height=i+"px";var p=Bd(this.element.id);ai(p,d),this.diagramRenderer.updateGrid(this.snapSettings,p,this.scroller.transform,this.rulerSettings,this.hRuler,this.vRuler),ai(mT(this.element.id),d),this.htmlLayer.style.width=e+"px",this.htmlLayer.style.height=i+"px","SVG"!==this.mode&&!Ds(this)&&this.refreshDiagramLayer(),"SVG"===this.mode&&Ds(this)&&this.scroller.virtualizeElements()}},t.prototype.transformLayers=function(){var e=this.spatialSearch.getPageBounds();e.x*=this.scroller.currentZoom,e.y*=this.scroller.currentZoom,e.width*=this.scroller.currentZoom,e.height*=this.scroller.currentZoom,this.diagramRenderer.updateGrid(this.snapSettings,Bd(this.element.id),this.scroller.transform,this.rulerSettings,this.hRuler,this.vRuler),this.diagramRenderer.transformLayers(this.scroller.transform,"SVG"===this.mode),this.diagramActions&ee.DragUsingMouse||this.updateSelector(),this.renderPageBreaks(e)},t.prototype.removePageBreaks=function(){if(this.diagramLayer){var e=PF(this.element.id);if(e&&e.childNodes)for(var i=e.childNodes.length,r=0;rthis.pageSettings.height&&(e=this.pageSettings.height,this.pageSettings.height=this.pageSettings.width,this.pageSettings.width=e):this.pageSettings.height>this.pageSettings.width&&(e=this.pageSettings.width,this.pageSettings.width=this.pageSettings.height,this.pageSettings.height=e)},t.prototype.setOverview=function(e,i){if(e)e&&(this.views.push(e.id),this.views[e.id]=e,e.renderDocument(e),e.diagramRenderer.setLayers(),e.updateView(e),this.renderNodes(e));else{for(var r=0;r1&&this.updateSelectionRectangle(),this.isProtectedOnChange=s},t.prototype.updateSelectionRectangle=function(){for(var e=cm(this.element.id),i=!1,r=0;r1&&this.updateSelectionRectangle(),this.enableServerDataBinding(e)},t.prototype.renderSelectorForAnnotation=function(e,i){this.diagramRenderer.renderResizeHandle(e.wrapper.children[0],i,e.thumbsConstraints,this.scroller.currentZoom,e.constraints,this.scroller.transform,void 0,to(e.annotation),void 0,void 0,e.handleSize)},t.prototype.drawSelectionRectangle=function(e,i,r,s){this.clearSelectorLayer(),this.diagramRenderer.drawSelectionRectangle(e,i,r,s,this.adornerLayer,this.scroller.transform)},t.prototype.renderHighlighter=function(e){var i=Pl(this.element.id);this.diagramRenderer.renderHighlighter(e,i,this.scroller.transform)},t.prototype.clearHighlighter=function(){var e=Pl(this.element.id),i=e.getElementById(e.id+"_highlighter");i&&i.parentNode.removeChild(i)},t.prototype.getNodesConnectors=function(e){for(var i=0;i0;l--)(a=o[l-1]).parentNode.removeChild(a);if(!ce()){var h=vT(this.element.id).childNodes;for(r=h.length;r>0;r--)h[r-1].parentNode.removeChild(h[r-1])}}},t.prototype.getWrapper=function(e,i){var r;i=e.id+"_"+i;for(var s=e instanceof Ii?e:this.getPortContainer(this.nameTable[e.id]),o=0;o0&&this.applyStyle(e,a=r.annotations)}for(i=0;i0){var a=this.selectedItems.connectors[parseInt(i.toString(),10)].annotations;this.applyStyle(e,a)}},t.prototype.applyStyle=function(e,i){for(var r=0;r0)for(var i=0;i0?r[0].zIndex+(e?1:-1):e?0:this.nodes.length+this.connectors.length-1)<0?i=this.nodes.length+this.connectors.length-1:i===this.nodes.length+this.connectors.length&&(i=0);for(var s=0;s0)for(var s=void 0,o=r.children.length-1;o>=0;o--){var a=r.children[parseInt(o.toString(),10)];i.length>0&&-1!==i.indexOf(a.id.split("_groupElement")[0])&&(r.parentNode.insertBefore(a,s||r),s=a)}r&&r.parentNode.removeChild(r)},t.prototype.deleteGroup=function(e){var r=[];e.children&&(r=this.commandHandler.getChildren(e,[])),this.UpdateBlazorDiagramModelCollection(e);for(var s=0,o=r;s0)for(var xe=0;xe0)if("Path"===t.shape.type&&void 0!==n.shape.data)t.wrapper.children[0].data=n.shape.data;else if("Text"===t.shape.type&&void 0!==n.shape.content)t.wrapper.children[0].content=n.shape.content;else if("Image"===t.shape.type&&void 0!==n.shape.source)t.wrapper.children[0].source=n.shape.source;else if("Native"===t.shape.type){for(var r=void 0,s=0;s-1)&&(this.diagramActions&ee.PreventZIndexOnDragging?this.updateDiagramObject(e,!0):this.updateDiagramObject(e)),!s&&d&&(this.lineRoutingModule&&this.diagramActions&&this.constraints&rt.LineRouting&&"helper"!==e.id?this.diagramActions&ee.ToolAction||this.lineRoutingModule.renderVirtualRegion(this,!0):this.diagramActions&&this.constraints&rt.LineRouting&&"helper"!==e.id&&console.warn('[WARNING] :: Module "LineRouting" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),this.updateConnectorEdges(e),"helper"!==e.id&&!(this.diagramActions&ee.ToolAction))))for(var ya=this.spatialSearch.findObjects(e.wrapper.outerBounds),Mo=0;Moe?Math.abs(r-e):Math.abs(e-r),d=s>i?Math.abs(s-i):Math.abs(i-s);(0===c&&0===d||Number.isNaN(c)&&Number.isNaN(d))&&o.laneMargin&&(u=o.margin.left-o.laneMargin.left,p=o.margin.top-o.laneMargin.top);var f=o.width,g=o.height,v=new Ne(0,0,0,0);if(0!==f&&0!==g&&(v=new Ne((0!==r?r:o.offsetX)-f/2,(0!==s?s:o.offsetY)-g/2,f,g)),h){var y=l,b=this.selectedItems.nodes?this.selectedItems.nodes[0]:void 0;if(""!==y.textAnnotation.textAnnotationTarget&&this.nameTable[y.textAnnotation.textAnnotationTarget])if(""===o.parentId||b&&b.shape&&"TextAnnotation"===b.shape.shape){if("Auto"===y.textAnnotation.textAnnotationDirection&&a.children[0]instanceof Ii&&a.children[0].children[0]instanceof Ke){var w=a.children[0],C=document.getElementById(w.id+"_groupElement"),D=document.getElementById(w.children[0].id+"_groupElement");C.removeChild(D),w.children.splice(0,1),this.isProtectedOnChange=!0,this.bpmnModule.setAnnotationPath(v,w,o,y,y.textAnnotation.textAnnotationDirection,this),this.isProtectedOnChange=!1}}else this.isPositionUndo=!0,this.updateTextAnnotationInSwimlane(o,o),this.isPositionUndo=!1;else o.inEdges.length>0&&(x=this.nameTable[""+o.inEdges[0]])&&x.isBpmnAnnotationConnector&&(x.sourcePoint={x:r>e?x.sourcePoint.x+c:x.sourcePoint.x-c,y:s>i?x.sourcePoint.y+d:x.sourcePoint.y-d});this.nodePropertyChange(o,{},R={ports:[{offset:o.ports[0].offset}]})}else for(var L=0,O=o.outEdges;Le?T.offsetX+c:T.offsetX-c,T.offsetY=s>i?T.offsetY+d:T.offsetY-d,R={offsetX:T.offsetX,offsetY:T.offsetY}),this.nodePropertyChange(T,P,R)}}}},t.prototype.updatePorts=function(e,i){if(e&&e.ports.length>0)for(var r=0,s=Object.keys(e.ports);r0)for(var i=0;i0)for(var r=0;r0&&void 0===r.segments&&(e.segments=[]),void 0!==r.shape&&void 0!==e.shape&&e.shape&&"Bpmn"===e.shape.type&&this.bpmnModule&&this.bpmnModule.updateBPMNConnector(e,i,r,this),void 0!==e.constraints?(this.updateThumbConstraints(this.selectedItems.connectors,this.selectedItems),s=!0):s},t.prototype.connectorPropertyChange=function(e,i,r,s,o){if(this.canEnableBlazorObject){var a=$(e);this.insertValue(a,!1)}var d,u,p,f,l=e.wrapper.bounds,h=!1,c=[];if(h=this.connectorProprtyChangeExtend(e,i,r,h),void 0!==r.visible&&this.updateElementVisibility(e.wrapper,e,e.visible),void 0!==r.sourcePoint||void 0!==r.targetPoint||void 0!==r.sourceID||void 0!==r.targetID||void 0!==r.targetPadding||void 0!==r.sourcePortID||void 0!==r.targetPortID||void 0!==r.sourcePadding||void 0!==r.type||void 0!==r.segments||void 0!==r.flip){if(void 0!==r.sourceID&&r.sourceID!==i.sourceID||r.sourcePortID){if(u=this.findInOutConnectPorts(g=this.nameTable[e.sourceID],!1),(!g||Nh(g)||""!==e.sourcePortID&&xd(u))&&(e.sourceWrapper=g?this.getEndNodeWrapper(g,e,!0):void 0,e.sourcePortID&&void 0===r.sourcePortID&&(e.sourcePortWrapper=g?this.getWrapper(g.wrapper,e.sourcePortID):void 0),this.removePortEdges(this.nameTable[i.sourceID]||g,i.sourcePortID||e.sourcePortID,e.id,!1)),void 0!==r.sourceID&&void 0!==i.sourceID&&""!==i.sourceID){var v=this.nameTable[i.sourceID];void 0!==v&&v.outEdges&&-1!==v.outEdges.indexOf(e.id)&&tm(v.outEdges,e.id)}this.updateEdges(e)}if(void 0!==r.targetID&&r.targetID!==i.targetID){if(d=this.findInOutConnectPorts(y=this.nameTable[r.targetID],!0),(!y||da(y)||""!==e.targetPortID&&Lh(d))&&(e.targetWrapper=y?this.getEndNodeWrapper(y,e,!1):void 0,e.targetPortID&&void 0===r.targetPortID&&(e.targetPortWrapper=y?this.getWrapper(y.wrapper,e.targetPortID):void 0),this.removePortEdges(this.nameTable[i.targetID]||y,i.targetPortID||e.targetPortID,e.id,!0)),void 0!==i&&void 0!==i.targetID&&""!==i.targetID){var S=this.nameTable[i.targetID];void 0!==S&&S.inEdges&&-1!==S.inEdges.indexOf(e.id)&&tm(S.inEdges,e.id)}this.updateEdges(e)}var g,y;void 0!==r.sourcePortID&&r.sourcePortID!==i.sourcePortID&&(e.sourceID&&this.nameTable[e.sourceID]&&(p=this.nameTable[e.sourceID].wrapper),!(g=this.nameTable[e.sourceID])||Nh(g)||""!==e.sourcePortID&&xd(u)?e.sourcePortWrapper=p?this.getWrapper(p,r.sourcePortID):void 0:""===e.sourcePortID&&!Nh(g)&&(e.sourcePortWrapper=void 0)),void 0!==r.targetPortID&&r.targetPortID!==i.targetPortID&&(e.targetID&&this.nameTable[e.targetID]&&(f=this.nameTable[e.targetID].wrapper),!(y=this.nameTable[e.targetID])||da(y)||""!==e.targetPortID&&Lh(d)?e.targetPortWrapper=f?this.getWrapper(f,r.targetPortID):void 0:""===e.targetPortID&&!da(y)&&(e.targetPortWrapper=void 0)),void 0!==r.flip&&(e.flip=r.flip,SF(e)),"Orthogonal"===e.type&&this.lineRoutingModule&&this.diagramActions&&this.constraints&rt.LineRouting&&!(this.diagramActions&ee.ToolAction)&&"ComplexHierarchicalTree"!==this.layout.type&&(this.lineRoutingModule.renderVirtualRegion(this,!0),e.sourceID!==e.targetID&&e.segments.length>1&&this.lineRoutingModule.refreshConnectorSegments(this,e,!1)),c=this.getPoints(e)}void 0!==r.style&&Ph(r.style,e.wrapper.children[0]),(c.length>0||void 0!==r.sourceDecorator||void 0!==r.targetDecorator&&function Bse(n){return-1!==n.indexOf("shape")||-1!==n.indexOf("pathData")||-1!==n.indexOf("width")||-1!==n.indexOf("height")}(Object.keys(r.targetDecorator))||void 0!==r.cornerRadius)&&(Zp(e,c.length>0?c:e.intermediatePoints,this.diagramActions),void 0!==r.type&&(h=!0),c.length>0&&(e.wrapper.measure(new me(e.wrapper.width,e.wrapper.height)),e.wrapper.arrange(e.wrapper.desiredSize),this.updateConnectorAnnotation(e),this.updateConnectorPort(e),this.updateConnectorfixedUserHandles(e),this.updateObject(e,i,r))),(r.sourcePoint||r.targetPoint||r.segments)&&this.diagramActions===ee.Render&&(h=!0),"Bpmn"===e.shape.type&&"Default"===e.shape.sequence&&"Sequence"===e.shape.flow&&this.commandHandler.updatePathElementOffset(e),s||this.updateBridging(),this.updateAnnotations(r,e),this.updateConnectorPorts(r,e),this.updatefixedUserHandle(r,e),e.wrapper.measure(new me(e.wrapper.width,e.wrapper.height)),e.wrapper.arrange(e.wrapper.desiredSize),!1===l.equals(l,e.wrapper.bounds)&&(this.updateQuad(e),"Drag"!==this.eventHandler.currentAction&&this.updateGroupSize(e)),!0===h&&this.checkSelectedItem(e)&&(!(this.diagramActions&ee.ToolAction)||this.diagramActions&ee.UndoRedo)&&this.updateSelector(),this.preventConnectorsUpdate||(!Ds(this)||Ds(this)&&this.scroller.oldCollectionObjects.indexOf(e.id)>-1)&&(this.diagramActions&ee.PreventZIndexOnDragging?this.updateDiagramObject(e,!0):this.updateDiagramObject(e)),this.updateConnectorEdges(e),this.diagramActions&&"New"!==e.status&&(e.status="Update"),this.triggerPropertyChange(o,e,i,r)},t.prototype.removePortEdges=function(e,i,r,s){if(e)for(var o=0;o0&&e.id===s[s.length-1].id&&(r=!0),r},t.prototype.updateDiagramContainerVisibility=function(e,i){if(e instanceof Cs)for(var r=0;r>"),r instanceof Jn&&this.updateAnnotationWrapper(r,s,o,a)),void 0!==e.template&&(r.content=e.template,this.updateAnnotationWrapper(r,s,o,a))},t.prototype.updateAnnotationWrapper=function(e,i,r,s){for(var o=0,a=this.views;o=0&&this.nodes.splice(s,1),delete this.nameTable[""+r]}var o=this.nodes.indexOf(this.nameTable[this.currentSymbol.id]);o>=0&&this.nodes.splice(o,1)}},t.prototype.selectDragedNode=function(e,i,r){this.currentSymbol=e,"SVG"!==this.mode&&this.refreshDiagramLayer(),this.commandHandler.oldSelectedObjects=rm(this),this.commandHandler.select(e),this.eventHandler.mouseDown(i.event),this.eventHandler.mouseMove(i.event,i),this.preventDiagramUpdate=!1,this.updatePage(),r.style.opacity="0"},t.prototype.initDroppables=function(){var s,o,e=this,i={},r={},a="selectedSymbols";this.droppable=new lR(this.element);var l=5;this.droppable.over=function(h){if(e.rulerSettings.showRulers){var c=document.getElementById(e.element.id+"_vRuler"),d=parseFloat(c.style.width);l=d+1}if(0===e.previousSelectedObjects.length&&!e.currentSymbol&&(e.previousSelectedObjects=e.commandHandler.getSelectedObject()),e.commandHandler.PreventConnectorSplit=!0,e.currentSymbol)h.event.touches&&h.event.touches.length&&e.eventHandler.mouseMove(h.event,h.event.touches);else{var u=null;if(!h.dragData&&"drag"===h.name){var p=document.getElementsByClassName("e-dragclone")[0];p&&(u=p)}if(h.dragData||u){var f=void 0,g=void 0;document.getElementById(e.element.id+"content").focus();var v=e.eventHandler.getMousePosition(h.event),y=void 0,S=u||h.dragData.helper,b=S.getAttribute("paletteId"),M=void 0,w=void 0,C=void 0,D=void 0;if(!b&&h.dragData){e.triggerEvent(Ce.dragEnter,A={source:null,element:f,cancel:!1,diagram:e,dragData:h.dragData.draggedElement.ej2_instances[0].dragData,dragItem:f});var x=void 0,R=void 0;if(A.dragItem){if(A.dragItem.sourcePoint&&A.dragItem.targetPoint?R=new de(e,"connectors",A.dragItem,!0):x=new te(e,"nodes",A.dragItem,!0),e.initObject(f=x||R,void 0,void 0,!0),e.enterObject=f,e.enterTable=r,f instanceof te)x.offsetX=v.x+5+x.width*x.pivot.x,x.offsetY=v.y+x.height*x.pivot.y;else if(f instanceof de){var L=Ne.toBounds([f.sourcePoint,f.targetPoint]),O=v.x-L.left,N=v.y-L.top;f.sourcePoint.x+=O,f.sourcePoint.y+=N,f.targetPoint.x+=O,f.targetPoint.y+=N}e.preventDiagramUpdate=!0,e.currentSymbol=f,"SVG"!==e.mode&&e.refreshDiagramLayer(),e.selectDragedNode(f,h,S),delete e.enterObject,delete e.enterTable,e.droppable[""+a]=S,e.allowServerDataBinding=!0}}if(b){var T=document.getElementById(b).ej2_instances[0];if(e.droppable.sourceElement=T,T){var B=T[""+a];e.allowServerDataBinding=!1,y=$(T[""+a]),i=T.childTable;var j=B.wrapper.children[0].children[0];if(D=function Fse(n,t,e){var i=wF(n,t,e,"width"),r=wF(n,t,e,"height");return new me(i,r)}(T,y,j),T[""+a]instanceof te){"TextAnnotation"===B.shape.shape?(y.offsetX=v.x+11+D.width*y.pivot.x,y.offsetY=v.y+11+D.height*y.pivot.y):(y.offsetX=v.x+5+D.width*y.pivot.x,y.offsetY=v.y+D.height*y.pivot.y),"Bpmn"===(x=new te(e,"nodes",y,!0)).shape.type&&x.shape.activity.subProcess.processes&&x.shape.activity.subProcess.processes.length&&(x.shape.activity.subProcess.processes=[]),w=x.previewSize,C=T.symbolDragSize;var Q=T.symbolPreview;if(x.width=(M=x.dragSize).width||C.width||w.width||Q.width||x.width,x.height=M.height||C.height||w.height||Q.height||x.height,"SwimLane"===x.shape.type){if(e.diagramActions|=ee.PreventHistory,x.shape.isLane){x.children=[],s={id:"header"+Qe()},"Horizontal"===x.shape.orientation?(s.width=x.shape.lanes[0].header.width,s.height=x.shape.lanes[0].height):(s.width=x.shape.lanes[0].width,s.height=x.shape.lanes[0].header.height),s.style=x.shape.lanes[0].header.style,s.offsetX=v.x+l+s.width/2,s.offsetY=v.y+s.height/2,e.diagramActions|=ee.PreventCollectionChangeOnDragOver,s=e.add(s),o={id:"body"+Qe()},"Horizontal"===x.shape.orientation?(o.width=x.shape.lanes[0].width-s.width,o.height=x.shape.lanes[0].height,o.offsetX=v.x+l+(x.shape.lanes[0].header.width+o.width/2),o.offsetY=v.y+o.height/2):(o.width=x.shape.lanes[0].width,o.height=x.shape.lanes[0].height-s.height,o.offsetX=v.x+l+o.width/2,o.offsetY=v.y+(x.shape.lanes[0].header.height+o.height/2)),o.style=x.shape.lanes[0].style,o=e.add(o);var oe={id:"group"+Qe(),children:[s.id,o.id]};oe.shape=x.shape,oe.width=x.shape.lanes[0].width,oe.height=x.shape.lanes[0].height,oe.previewSize=x.previewSize,oe.dragSize=x.dragSize,oe.addInfo=x.addInfo,x=e.add(oe),e.diagramActions&=~ee.PreventCollectionChangeOnDragOver}e.diagramActions&=~ee.PreventHistory}if(x.shape.isPhase&&((g="Horizontal"===x.shape.orientation)?(x.offsetX=v.x+l+(x.width||j.actualSize.width)/2,x.offsetY=v.y,x.shape.data="M20,"+x.height/2+" L"+(x.width-20)+","+x.height/2+"z",x.height=1):(x.offsetX=v.x+5,x.offsetY=v.y+(x.height||j.actualSize.height)/2,x.shape.data="M"+x.width/2+",20 L"+x.width/2+","+(x.height-20)+"z",x.width=1)),"UmlClassifier"===x.shape.type&&(x.children=x.width=x.height=void 0,y.children=void 0,"Class"===x.shape.classifier&&x.shape.classShape.methods.length<=0&&x.shape.classShape.attributes.length<=0&&(x.shape.classShape.attributes=[{name:"Name",type:"Type",style:{}}]),"Enumeration"===x.shape.classifier&&x.shape.enumerationShape.members.length<=0&&(x.shape.enumerationShape.members=[{name:"Name"}]),"Interface"===x.shape.classifier&&x.shape.interfaceShape.methods.length<=0&&x.shape.interfaceShape.attributes.length<=0&&(x.shape.interfaceShape.attributes=[{name:"Name",type:"Type",style:{}}])),f=x,y.children){var ue=y;r=e.getChildren(ue,{},i),eT(ue,-ue.offsetX,-ue.offsetY,r,!0,e)}}else if(T[""+a]instanceof de){f=new de(e,"connectors",y,!0);var Me=Ne.toBounds([f.sourcePoint,f.targetPoint]),De=v.x-Me.left,xe=v.y-Me.top;f.sourcePoint.x+=De,f.sourcePoint.y+=xe,f.targetPoint.x+=De,f.targetPoint.y+=xe}f.shape.isLane||(f.id+=Qe());var A={source:T,element:f,cancel:!1,diagram:e,dragData:null,dragItem:f};if(e.enterObject=f,e.enterTable=r,e.triggerEvent(Ce.dragEnter,A),f instanceof te&&"SwimLane"===f.shape.type&&f.shape.isLane){var Ie=A.element,Ve=Ie.shape.lanes[0];g="Horizontal"===Ie.shape.orientation;var ot=e.nameTable[f.children[0]],$e=e.nameTable[f.children[1]];w=f.previewSize,C=T.symbolDragSize,Ve.width=(M=f.dragSize).width||C.width||w.width||Ve.width,Ve.height=M.height||C.height||w.height||Ve.height,g?(s.width=Ve.header.width,s.height=Ve.height,o.width=Ve.width-s.width,o.height=Ve.height,o.offsetX=v.x+l+(Ve.header.width+$e.width/2),o.offsetY=v.y+$e.height/2):(s.width=Ve.width,s.height=Ve.header.height,o.width=Ve.width,o.height=Ve.height-s.height,o.offsetX=v.x+l+$e.width/2,o.offsetY=v.y+(Ve.header.height+$e.height/2)),s.offsetX=v.x+l+ot.width/2,s.offsetY=v.y+ot.height/2,f.width=Ve.width,f.height=Ve.height}if(f instanceof te&&f.shape.isPhase&&(g?f.height=1:f.width=1),!e.activeLayer.lock&&!A.cancel){if(e.preventDiagramUpdate=!0,f.children&&e.findChild(f,r),e.preventDiagramUpdate=!0,f.zIndex!==Number.MIN_VALUE&&(f.zIndex=Number.MIN_VALUE),e.initObject(f,void 0,void 0,!0),e.bpmnModule)for(var Mi=0;Mi0&&(S.segments=[]),d=this.add(S,!0)),(S||d)&&(_v(this)||Uv(this))&&this.select([this.nameTable[S[""+b]]],!1,this.previousSelectedObjects),y.target&&y.target instanceof de&&!0===this.enableConnectorSplit&&this.nameTable[S[""+b]]instanceof te&&(this.commandHandler.connectorSplit(this.nameTable[S[""+b]],y.target),this.commandHandler.PreventConnectorSplit=!1))),this.protectPropertyChange(!1),v=this.nameTable[S[""+b]],S.hasTarget&&(S.nodeId=S.hasTarget,this.remove(S)),this.bpmnModule&&v instanceof te&&S.processId&&(v.processId=S.processId,this.bpmnModule.dropBPMNchild(this.nameTable[v.processId],v,this)),y.cancel||this.endGroupAction(),"SVG"!==this.mode&&this.refreshDiagramLayer(),delete this.droppable[""+c]):(this.triggerEvent(Ce.drop,y={source:h.droppedElement,element:void 0,target:this.eventHandler.hoverNode||this.eventHandler.lastObjectUnderMouse||this,cancel:!1,position:void 0}),S=void 0,b="id"),this.droppable[M="selectedSymbols"]&&this.droppable[""+M].parentNode)gt(this.droppable[""+M]);else for(w=document.getElementsByClassName("e-dragclone"),C=0;C0)for(var p=0;p1),e.previousSelectedObject=null}}},t.prototype.getDropEventArgs=function(e){if(this.eventHandler.lastObjectUnderMouse||this.eventHandler.hoverNode){var i=this.eventHandler.lastObjectUnderMouse||this.eventHandler.hoverNode;e.target=fs(i)===de?{connector:i}:{node:i}}else e.target.diagramId=this.element.id},t.prototype.removeChildInNodes=function(e){if(e){if(e.children)for(var i=0;i1){var l=2;if(e.children&&e.children.length>0)for(;e.children.indexOf(i.objects[s-l])>-1;)l++;this.commandHandler.moveSvgNode(e.id,i.objects[s-l]),this.commandHandler.moveSvgNode(i.objects[s-l],e.id)}else if(o){var h=this.commandHandler.getLayer(this.layerZIndexTable[o.zIndex]).objects[0];h?(this.commandHandler.moveSvgNode(e.id,h),this.commandHandler.updateNativeNodeIndex(e.id,h)):this.moveObjectsUp(e,i)}else this.moveObjectsUp(e,i)},t.prototype.moveObjectsUp=function(e,i){for(var r,s=this.layers.length-1;s>=0;s--)if(r=this.layers[parseInt(s.toString(),10)],i.id!==r.id){var o=this.commandHandler.getLayer(this.layerZIndexTable[r.zIndex]).objects[r.objects.length-1];if(o){this.commandHandler.moveSvgNode(e.id,o),this.commandHandler.moveSvgNode(o,e.id);break}}},t.prototype.insertData=function(e){return this.crudOperation(e,"create",this.getNewUpdateNodes("New"))},t.prototype.updateData=function(e){return this.crudOperation(e,"update",this.getNewUpdateNodes("Update"))},t.prototype.removeData=function(e){return this.crudOperation(e,"destroy",this.getDeletedNodes())},t.prototype.crudOperation=function(e,i,r){if(e){var s=this.parameterMap(e,!(e instanceof de));if(s){var o=e instanceof de?this.dataSourceSettings.connectionDataSource.crudAction[""+i]:this.dataSourceSettings.crudAction[""+i];this.raiseAjaxPost(JSON.stringify(s),o)}return s}var a=r;return this.processCrudCollection(a,this.dataSourceSettings.crudAction[""+i],this.dataSourceSettings.connectionDataSource.crudAction[""+i]),a},t.prototype.processCrudCollection=function(e,i,r){if(e.nodes){var s=[],o=void 0;for(o=0;o0&&this.raiseAjaxPost(JSON.stringify(s),i)}if(e.connectors){for(s=[],o=void 0,o=0;o0&&this.raiseAjaxPost(JSON.stringify(s),r)}},t.prototype.parameterMap=function(e,i){var s,r={},o=i?this.dataSourceSettings:this.dataSourceSettings.connectionDataSource;if(o.id&&(r[o.id]=e.id),o.sourcePointX&&o.sourcePointY&&(r[o.sourcePointX]=e.sourcePoint.x,r[o.sourcePointY]=e.sourcePoint.y),o.targetPointX&&o.targetPointY&&(r[o.targetPointX]=e.targetPoint.x,r[o.targetPointY]=e.targetPoint.y),o.sourceID&&(r[o.sourceID]=e.sourceID),o.targetID&&(r[o.targetID]=e.targetID),o.crudAction&&o.crudAction.customFields&&o.crudAction.customFields.length>0)for(s=0;s"u"||(y.innerHTML=v.innerHTML?v.innerHTML:"",void 0!==v.className&&(y.className=v.className),void 0!==v.id&&(y.id=v.id),void 0!==v.styles&&y.setAttribute("style",v.styles),void 0!==e.ngAttr&&y.setAttribute(e.ngAttr,""),void 0!==v.attrs&&Fe(y,v.attrs)),y};for(var i=0,r=e.tags;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s}!function DZ(n){CC.compile=n.compile}({compile:function Fae(n,t){if("string"==typeof n||"function"==typeof n&&n.prototype&&n.prototype.CSPTemplate)return Bae(n,t);var e=n.elementRef.nativeElement._viewContainerRef,i=n.elementRef.nativeElement.propName;return function(r,s,o){var l=e||s.viewContainerRef,h=l.createEmbeddedView(n,{$implicit:r});/EJS-MENTION|EJS-DROPDOWNLIST/.test(Y("currentInstance.element.nodeName",l))||/E-TABITEM/.test(Y("element.nativeElement.nodeName",l))?h.detectChanges():h.markForCheck();var c=s&&s.registeredTemplate?s.registeredTemplate:Y("currentInstance.registeredTemplate",l);return typeof c["".concat(o=o&&s.registeredTemplate?o:i)]>"u"&&(c["".concat(o)]=[]),c["".concat(o)].push(h),h.rootNodes}}});const Wae=["annotationTemplate"],Yae=["nodeTemplate"],Qae=["userHandleTemplate"];let Gae=["addInfo","id","lock","objects","visible","zIndex"],Xae=[],qae=(()=>{class n extends Hh{constructor(e){super(),this.viewContainerRef=e,Rl("currentInstance",this,this.viewContainerRef),this.registerEvents(Xae),this.directivePropList=Gae}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-layer"]],inputs:{addInfo:"addInfo",id:"id",lock:"lock",objects:"objects",visible:"visible",zIndex:"zIndex"},features:[yn]}),n})(),$ae=(()=>{class n extends Bh{constructor(){super("layers")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-layers"]],contentQueries:function(e,i,r){if(1&e&&dn(r,qae,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),Zae=["action","cursor"],Jae=[],Kae=(()=>{class n extends Hh{constructor(e){super(),this.viewContainerRef=e,Rl("currentInstance",this,this.viewContainerRef),this.registerEvents(Jae),this.directivePropList=Zae}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-cursormap"]],inputs:{action:"action",cursor:"cursor"},features:[yn]}),n})(),ele=(()=>{class n extends Bh{constructor(){super("customcursor")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-cursormaps"]],contentQueries:function(e,i,r){if(1&e&&dn(r,Kae,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),tle=["alignment","cornerRadius","displacement","fill","handleStrokeColor","handleStrokeWidth","height","iconStrokeColor","iconStrokeWidth","id","offset","padding","pathData","tooltip","visibility","width"],ile=[],rle=(()=>{class n extends Hh{constructor(e){super(),this.viewContainerRef=e,Rl("currentInstance",this,this.viewContainerRef),this.registerEvents(ile),this.directivePropList=tle}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-connector-fixeduserhandle"]],inputs:{alignment:"alignment",cornerRadius:"cornerRadius",displacement:"displacement",fill:"fill",handleStrokeColor:"handleStrokeColor",handleStrokeWidth:"handleStrokeWidth",height:"height",iconStrokeColor:"iconStrokeColor",iconStrokeWidth:"iconStrokeWidth",id:"id",offset:"offset",padding:"padding",pathData:"pathData",tooltip:"tooltip",visibility:"visibility",width:"width"},features:[yn]}),n})(),nle=(()=>{class n extends Bh{constructor(){super("fixeduserhandles")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-connector-fixeduserhandles"]],contentQueries:function(e,i,r){if(1&e&&dn(r,rle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),sle=["addInfo","alignment","annotationType","constraints","content","displacement","dragLimit","height","horizontalAlignment","hyperlink","id","margin","offset","rotateAngle","rotationReference","segmentAngle","style","template","tooltip","type","verticalAlignment","visibility","width"],ole=[],ale=(()=>{class n extends Hh{constructor(e){super(),this.viewContainerRef=e,Rl("currentInstance",this,this.viewContainerRef),this.registerEvents(ole),this.directivePropList=sle}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-connector-annotation"]],inputs:{addInfo:"addInfo",alignment:"alignment",annotationType:"annotationType",constraints:"constraints",content:"content",displacement:"displacement",dragLimit:"dragLimit",height:"height",horizontalAlignment:"horizontalAlignment",hyperlink:"hyperlink",id:"id",margin:"margin",offset:"offset",rotateAngle:"rotateAngle",rotationReference:"rotationReference",segmentAngle:"segmentAngle",style:"style",template:"template",tooltip:"tooltip",type:"type",verticalAlignment:"verticalAlignment",visibility:"visibility",width:"width"},features:[yn]}),n})(),lle=(()=>{class n extends Bh{constructor(){super("annotations")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-connector-annotations"]],contentQueries:function(e,i,r){if(1&e&&dn(r,ale,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),hle=["addInfo","allowNodeOverlap","annotations","bezierSettings","bridgeSpace","connectionPadding","connectorSpacing","constraints","cornerRadius","dragSize","excludeFromLayout","fixedUserHandles","flip","flipMode","hitPadding","id","margin","maxSegmentThumb","ports","previewSize","segmentThumbShape","segmentThumbSize","segments","shape","sourceDecorator","sourceID","sourcePadding","sourcePoint","sourcePortID","style","symbolInfo","targetDecorator","targetID","targetPadding","targetPoint","targetPortID","tooltip","type","visible","wrapper","zIndex"],cle=[],dle=(()=>{class n extends Hh{constructor(e){super(),this.viewContainerRef=e,this.tags=["fixedUserHandles","annotations"],Rl("currentInstance",this,this.viewContainerRef),this.registerEvents(cle),this.directivePropList=hle}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-connector"]],contentQueries:function(e,i,r){if(1&e&&(dn(r,nle,5),dn(r,lle,5)),2&e){let s;Kr(s=en())&&(i.childFixedUserHandles=s.first),Kr(s=en())&&(i.childAnnotations=s.first)}},inputs:{addInfo:"addInfo",allowNodeOverlap:"allowNodeOverlap",annotations:"annotations",bezierSettings:"bezierSettings",bridgeSpace:"bridgeSpace",connectionPadding:"connectionPadding",connectorSpacing:"connectorSpacing",constraints:"constraints",cornerRadius:"cornerRadius",dragSize:"dragSize",excludeFromLayout:"excludeFromLayout",fixedUserHandles:"fixedUserHandles",flip:"flip",flipMode:"flipMode",hitPadding:"hitPadding",id:"id",margin:"margin",maxSegmentThumb:"maxSegmentThumb",ports:"ports",previewSize:"previewSize",segmentThumbShape:"segmentThumbShape",segmentThumbSize:"segmentThumbSize",segments:"segments",shape:"shape",sourceDecorator:"sourceDecorator",sourceID:"sourceID",sourcePadding:"sourcePadding",sourcePoint:"sourcePoint",sourcePortID:"sourcePortID",style:"style",symbolInfo:"symbolInfo",targetDecorator:"targetDecorator",targetID:"targetID",targetPadding:"targetPadding",targetPoint:"targetPoint",targetPortID:"targetPortID",tooltip:"tooltip",type:"type",visible:"visible",wrapper:"wrapper",zIndex:"zIndex"},features:[yn]}),n})(),ule=(()=>{class n extends Bh{constructor(){super("connectors")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-connectors"]],contentQueries:function(e,i,r){if(1&e&&dn(r,dle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),ple=["cornerRadius","fill","handleStrokeColor","handleStrokeWidth","height","iconStrokeColor","iconStrokeWidth","id","margin","offset","padding","pathData","tooltip","visibility","width"],fle=[],gle=(()=>{class n extends Hh{constructor(e){super(),this.viewContainerRef=e,Rl("currentInstance",this,this.viewContainerRef),this.registerEvents(fle),this.directivePropList=ple}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-node-fixeduserhandle"]],inputs:{cornerRadius:"cornerRadius",fill:"fill",handleStrokeColor:"handleStrokeColor",handleStrokeWidth:"handleStrokeWidth",height:"height",iconStrokeColor:"iconStrokeColor",iconStrokeWidth:"iconStrokeWidth",id:"id",margin:"margin",offset:"offset",padding:"padding",pathData:"pathData",tooltip:"tooltip",visibility:"visibility",width:"width"},features:[yn]}),n})(),vle=(()=>{class n extends Bh{constructor(){super("fixeduserhandles")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-node-fixeduserhandles"]],contentQueries:function(e,i,r){if(1&e&&dn(r,gle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),mle=["addInfo","annotationType","constraints","content","dragLimit","height","horizontalAlignment","hyperlink","id","margin","offset","rotateAngle","rotationReference","style","template","tooltip","type","verticalAlignment","visibility","width"],yle=[],Sle=(()=>{class n extends Hh{constructor(e){super(),this.viewContainerRef=e,Rl("currentInstance",this,this.viewContainerRef),this.registerEvents(yle),this.directivePropList=mle}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-node-annotation"]],inputs:{addInfo:"addInfo",annotationType:"annotationType",constraints:"constraints",content:"content",dragLimit:"dragLimit",height:"height",horizontalAlignment:"horizontalAlignment",hyperlink:"hyperlink",id:"id",margin:"margin",offset:"offset",rotateAngle:"rotateAngle",rotationReference:"rotationReference",style:"style",template:"template",tooltip:"tooltip",type:"type",verticalAlignment:"verticalAlignment",visibility:"visibility",width:"width"},features:[yn]}),n})(),Ile=(()=>{class n extends Bh{constructor(){super("annotations")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-node-annotations"]],contentQueries:function(e,i,r){if(1&e&&dn(r,Sle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),ble=["addInfo","connectionDirection","constraints","height","horizontalAlignment","id","inEdges","margin","offset","outEdges","pathData","shape","style","tooltip","verticalAlignment","visibility","width"],Mle=[],wle=(()=>{class n extends Hh{constructor(e){super(),this.viewContainerRef=e,Rl("currentInstance",this,this.viewContainerRef),this.registerEvents(Mle),this.directivePropList=ble}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-node-port"]],inputs:{addInfo:"addInfo",connectionDirection:"connectionDirection",constraints:"constraints",height:"height",horizontalAlignment:"horizontalAlignment",id:"id",inEdges:"inEdges",margin:"margin",offset:"offset",outEdges:"outEdges",pathData:"pathData",shape:"shape",style:"style",tooltip:"tooltip",verticalAlignment:"verticalAlignment",visibility:"visibility",width:"width"},features:[yn]}),n})(),Cle=(()=>{class n extends Bh{constructor(){super("ports")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-node-ports"]],contentQueries:function(e,i,r){if(1&e&&dn(r,wle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),Ele=["addInfo","annotations","backgroundColor","borderColor","borderWidth","branch","children","collapseIcon","columnIndex","columnSpan","columns","constraints","container","data","dragSize","excludeFromLayout","expandIcon","fixedUserHandles","flip","flipMode","height","horizontalAlignment","id","isExpanded","layoutInfo","margin","maxHeight","maxWidth","minHeight","minWidth","offsetX","offsetY","padding","pivot","ports","previewSize","rotateAngle","rowIndex","rowSpan","rows","shadow","shape","style","symbolInfo","tooltip","verticalAlignment","visible","width","wrapper","zIndex"],Dle=[],v_=(()=>{class n extends Hh{constructor(e){super(),this.viewContainerRef=e,this.tags=["fixedUserHandles","annotations","ports"],Rl("currentInstance",this,this.viewContainerRef),this.registerEvents(Dle),this.directivePropList=Ele}}return n.\u0275fac=function(e){return new(e||n)(Ot(xn))},n.\u0275dir=nr({type:n,selectors:[["e-node"]],contentQueries:function(e,i,r){if(1&e&&(dn(r,vle,5),dn(r,Ile,5),dn(r,Cle,5)),2&e){let s;Kr(s=en())&&(i.childFixedUserHandles=s.first),Kr(s=en())&&(i.childAnnotations=s.first),Kr(s=en())&&(i.childPorts=s.first)}},inputs:{addInfo:"addInfo",annotations:"annotations",backgroundColor:"backgroundColor",borderColor:"borderColor",borderWidth:"borderWidth",branch:"branch",children:"children",collapseIcon:"collapseIcon",columnIndex:"columnIndex",columnSpan:"columnSpan",columns:"columns",constraints:"constraints",container:"container",data:"data",dragSize:"dragSize",excludeFromLayout:"excludeFromLayout",expandIcon:"expandIcon",fixedUserHandles:"fixedUserHandles",flip:"flip",flipMode:"flipMode",height:"height",horizontalAlignment:"horizontalAlignment",id:"id",isExpanded:"isExpanded",layoutInfo:"layoutInfo",margin:"margin",maxHeight:"maxHeight",maxWidth:"maxWidth",minHeight:"minHeight",minWidth:"minWidth",offsetX:"offsetX",offsetY:"offsetY",padding:"padding",pivot:"pivot",ports:"ports",previewSize:"previewSize",rotateAngle:"rotateAngle",rowIndex:"rowIndex",rowSpan:"rowSpan",rows:"rows",shadow:"shadow",shape:"shape",style:"style",symbolInfo:"symbolInfo",tooltip:"tooltip",verticalAlignment:"verticalAlignment",visible:"visible",width:"width",wrapper:"wrapper",zIndex:"zIndex"},features:[yn]}),n})(),m_=(()=>{class n extends Bh{constructor(){super("nodes")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-nodes"]],contentQueries:function(e,i,r){if(1&e&&dn(r,v_,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})();const xle=["animationComplete","click","collectionChange","commandExecute","connectionChange","contextMenuBeforeItemRender","contextMenuClick","contextMenuOpen","created","dataLoaded","doubleClick","dragEnter","dragLeave","dragOver","drop","elementDraw","expandStateChange","fixedUserHandleClick","historyChange","historyStateChange","keyDown","keyUp","load","loaded","mouseEnter","mouseLeave","mouseOver","mouseWheel","onFixedUserHandleMouseDown","onFixedUserHandleMouseEnter","onFixedUserHandleMouseLeave","onFixedUserHandleMouseUp","onImageLoad","onUserHandleMouseDown","onUserHandleMouseEnter","onUserHandleMouseLeave","onUserHandleMouseUp","positionChange","propertyChange","rotateChange","scrollChange","segmentChange","segmentCollectionChange","selectionChange","sizeChange","sourcePointChange","targetPointChange","textEdit"],Tle=[""];let Ale=(()=>{let n=class extends zl{constructor(e,i,r,s){super(),this.ngEle=e,this.srenderer=i,this.viewContainerRef=r,this.injector=s,this.tags=["layers","customCursor","connectors","nodes"],this.element=this.ngEle.nativeElement,this.injectedModules=this.injectedModules||[];try{let o=this.injector.get("DiagramsHierarchicalTree");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsMindMap");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsRadialTree");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsComplexHierarchicalTree");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsDataBinding");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsSnapping");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsPrintAndExport");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsBpmnDiagrams");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsSymmetricLayout");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsConnectorBridging");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsUndoRedo");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsLayoutAnimation");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsDiagramContextMenu");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsLineRouting");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsConnectorEditing");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsLineDistribution");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsEj1Serialization");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsFlowchartLayout");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}this.registerEvents(xle),this.addTwoWay.call(this,Tle),Rl("currentInstance",this,this.viewContainerRef),this.context=new u_}ngOnInit(){this.context.ngOnInit(this)}ngAfterViewInit(){this.context.ngAfterViewInit(this)}ngOnDestroy(){this.context.ngOnDestroy(this)}ngAfterContentChecked(){this.tagObjects[0].instance=this.childLayers,this.childCustomCursor&&(this.tagObjects[1].instance=this.childCustomCursor),this.childConnectors&&(this.tagObjects[2].instance=this.childConnectors),this.childNodes&&(this.tagObjects[3].instance=this.childNodes),this.context.ngAfterContentChecked(this)}};return n.\u0275fac=function(e){return new(e||n)(Ot($c),Ot(oM),Ot(xn),Ot(Wo))},n.\u0275cmp=Rb({type:n,selectors:[["ejs-diagram"]],contentQueries:function(e,i,r){if(1&e&&(dn(r,Wae,5),dn(r,Yae,5),dn(r,Qae,5),dn(r,$ae,5),dn(r,ele,5),dn(r,ule,5),dn(r,m_,5)),2&e){let s;Kr(s=en())&&(i.annotationTemplate=s.first),Kr(s=en())&&(i.nodeTemplate=s.first),Kr(s=en())&&(i.userHandleTemplate=s.first),Kr(s=en())&&(i.childLayers=s.first),Kr(s=en())&&(i.childCustomCursor=s.first),Kr(s=en())&&(i.childConnectors=s.first),Kr(s=en())&&(i.childNodes=s.first)}},inputs:{addInfo:"addInfo",annotationTemplate:"annotationTemplate",backgroundColor:"backgroundColor",bridgeDirection:"bridgeDirection",commandManager:"commandManager",connectorDefaults:"connectorDefaults",connectors:"connectors",constraints:"constraints",contextMenuSettings:"contextMenuSettings",customCursor:"customCursor",dataSourceSettings:"dataSourceSettings",diagramSettings:"diagramSettings",drawingObject:"drawingObject",enableConnectorSplit:"enableConnectorSplit",enablePersistence:"enablePersistence",enableRtl:"enableRtl",fixedUserHandleTemplate:"fixedUserHandleTemplate",getConnectorDefaults:"getConnectorDefaults",getCustomCursor:"getCustomCursor",getCustomProperty:"getCustomProperty",getCustomTool:"getCustomTool",getDescription:"getDescription",getNodeDefaults:"getNodeDefaults",height:"height",historyManager:"historyManager",layers:"layers",layout:"layout",locale:"locale",mode:"mode",nodeDefaults:"nodeDefaults",nodeTemplate:"nodeTemplate",nodes:"nodes",pageSettings:"pageSettings",rulerSettings:"rulerSettings",scrollSettings:"scrollSettings",segmentThumbShape:"segmentThumbShape",segmentThumbSize:"segmentThumbSize",selectedItems:"selectedItems",serializationSettings:"serializationSettings",setNodeTemplate:"setNodeTemplate",snapSettings:"snapSettings",tool:"tool",tooltip:"tooltip",updateSelection:"updateSelection",userHandleTemplate:"userHandleTemplate",width:"width"},outputs:{animationComplete:"animationComplete",click:"click",collectionChange:"collectionChange",commandExecute:"commandExecute",connectionChange:"connectionChange",contextMenuBeforeItemRender:"contextMenuBeforeItemRender",contextMenuClick:"contextMenuClick",contextMenuOpen:"contextMenuOpen",created:"created",dataLoaded:"dataLoaded",doubleClick:"doubleClick",dragEnter:"dragEnter",dragLeave:"dragLeave",dragOver:"dragOver",drop:"drop",elementDraw:"elementDraw",expandStateChange:"expandStateChange",fixedUserHandleClick:"fixedUserHandleClick",historyChange:"historyChange",historyStateChange:"historyStateChange",keyDown:"keyDown",keyUp:"keyUp",load:"load",loaded:"loaded",mouseEnter:"mouseEnter",mouseLeave:"mouseLeave",mouseOver:"mouseOver",mouseWheel:"mouseWheel",onFixedUserHandleMouseDown:"onFixedUserHandleMouseDown",onFixedUserHandleMouseEnter:"onFixedUserHandleMouseEnter",onFixedUserHandleMouseLeave:"onFixedUserHandleMouseLeave",onFixedUserHandleMouseUp:"onFixedUserHandleMouseUp",onImageLoad:"onImageLoad",onUserHandleMouseDown:"onUserHandleMouseDown",onUserHandleMouseEnter:"onUserHandleMouseEnter",onUserHandleMouseLeave:"onUserHandleMouseLeave",onUserHandleMouseUp:"onUserHandleMouseUp",positionChange:"positionChange",propertyChange:"propertyChange",rotateChange:"rotateChange",scrollChange:"scrollChange",segmentChange:"segmentChange",segmentCollectionChange:"segmentCollectionChange",selectionChange:"selectionChange",sizeChange:"sizeChange",sourcePointChange:"sourcePointChange",targetPointChange:"targetPointChange",textEdit:"textEdit"},features:[yn],decls:0,vars:0,template:function(e,i){},encapsulation:2,changeDetection:0}),ub([TT()],n.prototype,"annotationTemplate",void 0),ub([TT()],n.prototype,"nodeTemplate",void 0),ub([TT()],n.prototype,"userHandleTemplate",void 0),n=ub([Rae([u_])],n),n})(),Lle=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Am({type:n}),n.\u0275inj=gf({imports:[[rq]]}),n})();const Nle=["diagram"];let Ole=(()=>{class n{constructor(){this.ports=[{id:"port1",offset:{x:0,y:.5},visibility:Gt.Visible},{id:"port2",offset:{x:1,y:.5},visibility:Gt.Visible},{id:"port3",offset:{x:.5,y:0},visibility:Gt.Visible},{id:"port4",offset:{x:.5,y:1},visibility:Gt.Visible}]}removePorts(){this.diagram.removePorts(this.diagram.nodes[0],this.ports)}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275cmp=Rb({type:n,selectors:[["app-container"]],viewQuery:function(i,r){if(1&i&&function uP(n,t,e){const i=xi();i.firstCreatePass&&(cP(i,new aP(n,t,e),-1),2==(2&t)&&(i.staticViewQueries=!0)),hP(i,Se(),t)}(Nle,5),2&i){let s;Kr(s=en())&&(r.diagram=s.first)}},standalone:!0,features:[PP([]),RP],decls:6,vars:5,consts:[["id","diagram","width","100%","height","580px"],["diagram",""],["id","node1",3,"offsetX","offsetY","width","height","ports"],[3,"click"]],template:function(i,r){1&i&&(lg(0,"ejs-diagram",0,1)(2,"e-nodes"),ew(3,"e-node",2),hg()(),lg(4,"button",3),ow("click",function(){return r.removePorts()}),function MP(n,t=""){const e=Se(),i=xi(),r=n+Ut,s=i.firstCreatePass?xu(i,r,1,t,null):i.data[r],o=wP(i,e,s,t,n);e[r]=o,Rm()&&ly(i,e,o,s),ol(s,!1)}(5,"Remove Ports"),hg()),2&i&&(function CN(n=1){EN(xi(),Se(),zs()+n,!1)}(3),GM("offsetX",250)("offsetY",250)("width",100)("height",100)("ports",r.ports))},dependencies:[Lle,Ale,v_,m_],encapsulation:2})}}return n})();Ud(332),function Xq(n,t){return CG({rootComponent:n,...Ez(t)})}(Ole).catch(n=>console.error(n))},332:()=>{!function(Z){const se=Z.performance;function ye(Pi){se&&se.mark&&se.mark(Pi)}function fe(Pi,ht){se&&se.measure&&se.measure(Pi,ht)}ye("Zone");const be=Z.__Zone_symbol_prefix||"__zone_symbol__";function ke(Pi){return be+Pi}const at=!0===Z[ke("forceDuplicateZoneCheck")];if(Z.Zone){if(at||"function"!=typeof Z.Zone.__symbol__)throw new Error("Zone already loaded.");return Z.Zone}let tt=(()=>{class Pi{static{this.__symbol__=ke}static assertZonePatched(){if(Z.Promise!==_o.ZoneAwarePromise)throw new Error("Zone.js has detected that ZoneAwarePromise `(window|global).Promise` has been overwritten.\nMost likely cause is that a Promise polyfill has been loaded after Zone.js (Polyfilling Promise api is not necessary when zone.js is loaded. If you must load one, do so before loading zone.js.)")}static get root(){let F=Pi.current;for(;F.parent;)F=F.parent;return F}static get current(){return Ur.zone}static get currentTask(){return Do}static __load_patch(F,ae,Et=!1){if(_o.hasOwnProperty(F)){if(!Et&&at)throw Error("Already loaded patch: "+F)}else if(!Z["__Zone_disable_"+F]){const qt="Zone:"+F;ye(qt),_o[F]=ae(Z,Pi,cn),fe(qt,qt)}}get parent(){return this._parent}get name(){return this._name}constructor(F,ae){this._parent=F,this._name=ae?ae.name||"unnamed":"",this._properties=ae&&ae.properties||{},this._zoneDelegate=new Lt(this,this._parent&&this._parent._zoneDelegate,ae)}get(F){const ae=this.getZoneWith(F);if(ae)return ae._properties[F]}getZoneWith(F){let ae=this;for(;ae;){if(ae._properties.hasOwnProperty(F))return ae;ae=ae._parent}return null}fork(F){if(!F)throw new Error("ZoneSpec required!");return this._zoneDelegate.fork(this,F)}wrap(F,ae){if("function"!=typeof F)throw new Error("Expecting function got: "+F);const Et=this._zoneDelegate.intercept(this,F,ae),qt=this;return function(){return qt.runGuarded(Et,this,arguments,ae)}}run(F,ae,Et,qt){Ur={parent:Ur,zone:this};try{return this._zoneDelegate.invoke(this,F,ae,Et,qt)}finally{Ur=Ur.parent}}runGuarded(F,ae=null,Et,qt){Ur={parent:Ur,zone:this};try{try{return this._zoneDelegate.invoke(this,F,ae,Et,qt)}catch(Un){if(this._zoneDelegate.handleError(this,Un))throw Un}}finally{Ur=Ur.parent}}runTask(F,ae,Et){if(F.zone!=this)throw new Error("A task can only be run in the zone of creation! (Creation: "+(F.zone||_n).name+"; Execution: "+this.name+")");if(F.state===sr&&(F.type===ts||F.type===Pt))return;const qt=F.state!=lt;qt&&F._transitionTo(lt,ki),F.runCount++;const Un=Do;Do=F,Ur={parent:Ur,zone:this};try{F.type==Pt&&F.data&&!F.data.isPeriodic&&(F.cancelFn=void 0);try{return this._zoneDelegate.invokeTask(this,F,ae,Et)}catch(Ue){if(this._zoneDelegate.handleError(this,Ue))throw Ue}}finally{F.state!==sr&&F.state!==et&&(F.type==ts||F.data&&F.data.isPeriodic?qt&&F._transitionTo(ki,lt):(F.runCount=0,this._updateTaskCount(F,-1),qt&&F._transitionTo(sr,lt,sr))),Ur=Ur.parent,Do=Un}}scheduleTask(F){if(F.zone&&F.zone!==this){let Et=this;for(;Et;){if(Et===F.zone)throw Error(`can not reschedule task to ${this.name} which is descendants of the original zone ${F.zone.name}`);Et=Et.parent}}F._transitionTo(Zr,sr);const ae=[];F._zoneDelegates=ae,F._zone=this;try{F=this._zoneDelegate.scheduleTask(this,F)}catch(Et){throw F._transitionTo(et,Zr,sr),this._zoneDelegate.handleError(this,Et),Et}return F._zoneDelegates===ae&&this._updateTaskCount(F,1),F.state==Zr&&F._transitionTo(ki,Zr),F}scheduleMicroTask(F,ae,Et,qt){return this.scheduleTask(new ft(vi,F,ae,Et,qt,void 0))}scheduleMacroTask(F,ae,Et,qt,Un){return this.scheduleTask(new ft(Pt,F,ae,Et,qt,Un))}scheduleEventTask(F,ae,Et,qt,Un){return this.scheduleTask(new ft(ts,F,ae,Et,qt,Un))}cancelTask(F){if(F.zone!=this)throw new Error("A task can only be cancelled in the zone of creation! (Creation: "+(F.zone||_n).name+"; Execution: "+this.name+")");if(F.state===ki||F.state===lt){F._transitionTo(dr,ki,lt);try{this._zoneDelegate.cancelTask(this,F)}catch(ae){throw F._transitionTo(et,dr),this._zoneDelegate.handleError(this,ae),ae}return this._updateTaskCount(F,-1),F._transitionTo(sr,dr),F.runCount=0,F}}_updateTaskCount(F,ae){const Et=F._zoneDelegates;-1==ae&&(F._zoneDelegates=null);for(let qt=0;qtPi.hasTask(F,ae),onScheduleTask:(Pi,ht,F,ae)=>Pi.scheduleTask(F,ae),onInvokeTask:(Pi,ht,F,ae,Et,qt)=>Pi.invokeTask(F,ae,Et,qt),onCancelTask:(Pi,ht,F,ae)=>Pi.cancelTask(F,ae)};class Lt{constructor(ht,F,ae){this._taskCounts={microTask:0,macroTask:0,eventTask:0},this.zone=ht,this._parentDelegate=F,this._forkZS=ae&&(ae&&ae.onFork?ae:F._forkZS),this._forkDlgt=ae&&(ae.onFork?F:F._forkDlgt),this._forkCurrZone=ae&&(ae.onFork?this.zone:F._forkCurrZone),this._interceptZS=ae&&(ae.onIntercept?ae:F._interceptZS),this._interceptDlgt=ae&&(ae.onIntercept?F:F._interceptDlgt),this._interceptCurrZone=ae&&(ae.onIntercept?this.zone:F._interceptCurrZone),this._invokeZS=ae&&(ae.onInvoke?ae:F._invokeZS),this._invokeDlgt=ae&&(ae.onInvoke?F:F._invokeDlgt),this._invokeCurrZone=ae&&(ae.onInvoke?this.zone:F._invokeCurrZone),this._handleErrorZS=ae&&(ae.onHandleError?ae:F._handleErrorZS),this._handleErrorDlgt=ae&&(ae.onHandleError?F:F._handleErrorDlgt),this._handleErrorCurrZone=ae&&(ae.onHandleError?this.zone:F._handleErrorCurrZone),this._scheduleTaskZS=ae&&(ae.onScheduleTask?ae:F._scheduleTaskZS),this._scheduleTaskDlgt=ae&&(ae.onScheduleTask?F:F._scheduleTaskDlgt),this._scheduleTaskCurrZone=ae&&(ae.onScheduleTask?this.zone:F._scheduleTaskCurrZone),this._invokeTaskZS=ae&&(ae.onInvokeTask?ae:F._invokeTaskZS),this._invokeTaskDlgt=ae&&(ae.onInvokeTask?F:F._invokeTaskDlgt),this._invokeTaskCurrZone=ae&&(ae.onInvokeTask?this.zone:F._invokeTaskCurrZone),this._cancelTaskZS=ae&&(ae.onCancelTask?ae:F._cancelTaskZS),this._cancelTaskDlgt=ae&&(ae.onCancelTask?F:F._cancelTaskDlgt),this._cancelTaskCurrZone=ae&&(ae.onCancelTask?this.zone:F._cancelTaskCurrZone),this._hasTaskZS=null,this._hasTaskDlgt=null,this._hasTaskDlgtOwner=null,this._hasTaskCurrZone=null;const Et=ae&&ae.onHasTask;(Et||F&&F._hasTaskZS)&&(this._hasTaskZS=Et?ae:At,this._hasTaskDlgt=F,this._hasTaskDlgtOwner=this,this._hasTaskCurrZone=ht,ae.onScheduleTask||(this._scheduleTaskZS=At,this._scheduleTaskDlgt=F,this._scheduleTaskCurrZone=this.zone),ae.onInvokeTask||(this._invokeTaskZS=At,this._invokeTaskDlgt=F,this._invokeTaskCurrZone=this.zone),ae.onCancelTask||(this._cancelTaskZS=At,this._cancelTaskDlgt=F,this._cancelTaskCurrZone=this.zone))}fork(ht,F){return this._forkZS?this._forkZS.onFork(this._forkDlgt,this.zone,ht,F):new tt(ht,F)}intercept(ht,F,ae){return this._interceptZS?this._interceptZS.onIntercept(this._interceptDlgt,this._interceptCurrZone,ht,F,ae):F}invoke(ht,F,ae,Et,qt){return this._invokeZS?this._invokeZS.onInvoke(this._invokeDlgt,this._invokeCurrZone,ht,F,ae,Et,qt):F.apply(ae,Et)}handleError(ht,F){return!this._handleErrorZS||this._handleErrorZS.onHandleError(this._handleErrorDlgt,this._handleErrorCurrZone,ht,F)}scheduleTask(ht,F){let ae=F;if(this._scheduleTaskZS)this._hasTaskZS&&ae._zoneDelegates.push(this._hasTaskDlgtOwner),ae=this._scheduleTaskZS.onScheduleTask(this._scheduleTaskDlgt,this._scheduleTaskCurrZone,ht,F),ae||(ae=F);else if(F.scheduleFn)F.scheduleFn(F);else{if(F.type!=vi)throw new Error("Task is missing scheduleFn.");Wt(F)}return ae}invokeTask(ht,F,ae,Et){return this._invokeTaskZS?this._invokeTaskZS.onInvokeTask(this._invokeTaskDlgt,this._invokeTaskCurrZone,ht,F,ae,Et):F.callback.apply(ae,Et)}cancelTask(ht,F){let ae;if(this._cancelTaskZS)ae=this._cancelTaskZS.onCancelTask(this._cancelTaskDlgt,this._cancelTaskCurrZone,ht,F);else{if(!F.cancelFn)throw Error("Task is not cancelable");ae=F.cancelFn(F)}return ae}hasTask(ht,F){try{this._hasTaskZS&&this._hasTaskZS.onHasTask(this._hasTaskDlgt,this._hasTaskCurrZone,ht,F)}catch(ae){this.handleError(ht,ae)}}_updateTaskCount(ht,F){const ae=this._taskCounts,Et=ae[ht],qt=ae[ht]=Et+F;if(qt<0)throw new Error("More tasks executed then were scheduled.");0!=Et&&0!=qt||this.hasTask(this.zone,{microTask:ae.microTask>0,macroTask:ae.macroTask>0,eventTask:ae.eventTask>0,change:ht})}}class ft{constructor(ht,F,ae,Et,qt,Un){if(this._zone=null,this.runCount=0,this._zoneDelegates=null,this._state="notScheduled",this.type=ht,this.source=F,this.data=Et,this.scheduleFn=qt,this.cancelFn=Un,!ae)throw new Error("callback is not defined");this.callback=ae;const Ue=this;this.invoke=ht===ts&&Et&&Et.useG?ft.invokeTask:function(){return ft.invokeTask.call(Z,Ue,this,arguments)}}static invokeTask(ht,F,ae){ht||(ht=this),Ls++;try{return ht.runCount++,ht.zone.runTask(ht,F,ae)}finally{1==Ls&&ct(),Ls--}}get zone(){return this._zone}get state(){return this._state}cancelScheduleRequest(){this._transitionTo(sr,Zr)}_transitionTo(ht,F,ae){if(this._state!==F&&this._state!==ae)throw new Error(`${this.type} '${this.source}': can not transition to '${ht}', expecting state '${F}'${ae?" or '"+ae+"'":""}, was '${this._state}'.`);this._state=ht,ht==sr&&(this._zoneDelegates=null)}toString(){return this.data&&typeof this.data.handleId<"u"?this.data.handleId.toString():Object.prototype.toString.call(this)}toJSON(){return{type:this.type,state:this.state,source:this.source,zone:this.zone.name,runCount:this.runCount}}}const Ei=ke("setTimeout"),ii=ke("Promise"),gi=ke("then");let es,cr=[],Oi=!1;function kr(Pi){if(es||Z[ii]&&(es=Z[ii].resolve(0)),es){let ht=es[gi];ht||(ht=es.then),ht.call(es,Pi)}else Z[Ei](Pi,0)}function Wt(Pi){0===Ls&&0===cr.length&&kr(ct),Pi&&cr.push(Pi)}function ct(){if(!Oi){for(Oi=!0;cr.length;){const Pi=cr;cr=[];for(let ht=0;htUr,onUnhandledError:jr,microtaskDrainDone:jr,scheduleMicroTask:Wt,showUncaughtError:()=>!tt[ke("ignoreConsoleErrorUncaughtError")],patchEventTarget:()=>[],patchOnProperties:jr,patchMethod:()=>jr,bindArguments:()=>[],patchThen:()=>jr,patchMacroTask:()=>jr,patchEventPrototype:()=>jr,isIEOrEdge:()=>!1,getGlobalObjects:()=>{},ObjectDefineProperty:()=>jr,ObjectGetOwnPropertyDescriptor:()=>{},ObjectCreate:()=>{},ArraySlice:()=>[],patchClass:()=>jr,wrapWithCurrentZone:()=>jr,filterProperties:()=>[],attachOriginToPatched:()=>jr,_redefineProperty:()=>jr,patchCallbacks:()=>jr,nativeScheduleMicroTask:kr};let Ur={parent:null,zone:new tt(null,null)},Do=null,Ls=0;function jr(){}fe("Zone","Zone"),Z.Zone=tt}(globalThis);const _l=Object.getOwnPropertyDescriptor,_d=Object.defineProperty,Ud=Object.getPrototypeOf,jd=Object.create,gb=Array.prototype.slice,pm="addEventListener",$r="removeEventListener",Ul=Zone.__symbol__(pm),Fh=Zone.__symbol__($r),Ts="true",Wi="false",Vd=Zone.__symbol__("");function of(Z,se){return Zone.current.wrap(Z,se)}function fm(Z,se,ye,fe,be){return Zone.current.scheduleMacroTask(Z,se,ye,fe,be)}const Ji=Zone.__symbol__,_h=typeof window<"u",Uh=_h?window:void 0,gn=_h&&Uh||globalThis,gm="removeAttribute";function Wd(Z,se){for(let ye=Z.length-1;ye>=0;ye--)"function"==typeof Z[ye]&&(Z[ye]=of(Z[ye],se+"_"+ye));return Z}function af(Z){return!Z||!1!==Z.writable&&!("function"==typeof Z.get&&typeof Z.set>"u")}const lf=typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope,jh=!("nw"in gn)&&typeof gn.process<"u"&&"[object process]"==={}.toString.call(gn.process),Yd=!jh&&!lf&&!(!_h||!Uh.HTMLElement),hf=typeof gn.process<"u"&&"[object process]"==={}.toString.call(gn.process)&&!lf&&!(!_h||!Uh.HTMLElement),jl={},Vh=function(Z){if(!(Z=Z||gn.event))return;let se=jl[Z.type];se||(se=jl[Z.type]=Ji("ON_PROPERTY"+Z.type));const ye=this||Z.target||gn,fe=ye[se];let be;return Yd&&ye===Uh&&"error"===Z.type?(be=fe&&fe.call(this,Z.message,Z.filename,Z.lineno,Z.colno,Z.error),!0===be&&Z.preventDefault()):(be=fe&&fe.apply(this,arguments),null!=be&&!be&&Z.preventDefault()),be};function Vl(Z,se,ye){let fe=_l(Z,se);if(!fe&&ye&&_l(ye,se)&&(fe={enumerable:!0,configurable:!0}),!fe||!fe.configurable)return;const be=Ji("on"+se+"patched");if(Z.hasOwnProperty(be)&&Z[be])return;delete fe.writable,delete fe.value;const ke=fe.get,at=fe.set,tt=se.slice(2);let At=jl[tt];At||(At=jl[tt]=Ji("ON_PROPERTY"+tt)),fe.set=function(Lt){let ft=this;!ft&&Z===gn&&(ft=gn),ft&&("function"==typeof ft[At]&&ft.removeEventListener(tt,Vh),at&&at.call(ft,null),ft[At]=Lt,"function"==typeof Lt&&ft.addEventListener(tt,Vh,!1))},fe.get=function(){let Lt=this;if(!Lt&&Z===gn&&(Lt=gn),!Lt)return null;const ft=Lt[At];if(ft)return ft;if(ke){let Ei=ke.call(this);if(Ei)return fe.set.call(this,Ei),"function"==typeof Lt[gm]&&Lt.removeAttribute(se),Ei}return null},_d(Z,se,fe),Z[be]=!0}function cf(Z,se,ye){if(se)for(let fe=0;fefunction(at,tt){const At=ye(at,tt);return At.cbIdx>=0&&"function"==typeof tt[At.cbIdx]?fm(At.name,tt[At.cbIdx],At,be):ke.apply(at,tt)})}function Sa(Z,se){Z[Ji("OriginalDelegate")]=se}let mb=!1,Gd=!1;function yb(){if(mb)return Gd;mb=!0;try{const Z=Uh.navigator.userAgent;(-1!==Z.indexOf("MSIE ")||-1!==Z.indexOf("Trident/")||-1!==Z.indexOf("Edge/"))&&(Gd=!0)}catch{}return Gd}Zone.__load_patch("ZoneAwarePromise",(Z,se,ye)=>{const fe=Object.getOwnPropertyDescriptor,be=Object.defineProperty,at=ye.symbol,tt=[],At=!1!==Z[at("DISABLE_WRAPPING_UNCAUGHT_PROMISE_REJECTION")],Lt=at("Promise"),ft=at("then"),Ei="__creationTrace__";ye.onUnhandledError=Ue=>{if(ye.showUncaughtError()){const He=Ue&&Ue.rejection;He?console.error("Unhandled Promise rejection:",He instanceof Error?He.message:He,"; Zone:",Ue.zone.name,"; Task:",Ue.task&&Ue.task.source,"; Value:",He,He instanceof Error?He.stack:void 0):console.error(Ue)}},ye.microtaskDrainDone=()=>{for(;tt.length;){const Ue=tt.shift();try{Ue.zone.runGuarded(()=>{throw Ue.throwOriginal?Ue.rejection:Ue})}catch(He){gi(He)}}};const ii=at("unhandledPromiseRejectionHandler");function gi(Ue){ye.onUnhandledError(Ue);try{const He=se[ii];"function"==typeof He&&He.call(this,Ue)}catch{}}function cr(Ue){return Ue&&Ue.then}function Oi(Ue){return Ue}function es(Ue){return F.reject(Ue)}const kr=at("state"),Wt=at("value"),ct=at("finally"),_n=at("parentPromiseValue"),sr=at("parentPromiseState"),Zr="Promise.then",ki=null,lt=!0,dr=!1,et=0;function vi(Ue,He){return ge=>{try{cn(Ue,He,ge)}catch(We){cn(Ue,!1,We)}}}const Pt=function(){let Ue=!1;return function(ge){return function(){Ue||(Ue=!0,ge.apply(null,arguments))}}},ts="Promise resolved with itself",_o=at("currentTaskTrace");function cn(Ue,He,ge){const We=Pt();if(Ue===ge)throw new TypeError(ts);if(Ue[kr]===ki){let wt=null;try{("object"==typeof ge||"function"==typeof ge)&&(wt=ge&&ge.then)}catch(Xe){return We(()=>{cn(Ue,!1,Xe)})(),Ue}if(He!==dr&&ge instanceof F&&ge.hasOwnProperty(kr)&&ge.hasOwnProperty(Wt)&&ge[kr]!==ki)Do(ge),cn(Ue,ge[kr],ge[Wt]);else if(He!==dr&&"function"==typeof wt)try{wt.call(ge,We(vi(Ue,He)),We(vi(Ue,!1)))}catch(Xe){We(()=>{cn(Ue,!1,Xe)})()}else{Ue[kr]=He;const Xe=Ue[Wt];if(Ue[Wt]=ge,Ue[ct]===ct&&He===lt&&(Ue[kr]=Ue[sr],Ue[Wt]=Ue[_n]),He===dr&&ge instanceof Error){const mt=se.currentTask&&se.currentTask.data&&se.currentTask.data[Ei];mt&&be(ge,_o,{configurable:!0,enumerable:!1,writable:!0,value:mt})}for(let mt=0;mt{try{const dt=Ue[Wt],$t=!!ge&&ct===ge[ct];$t&&(ge[_n]=dt,ge[sr]=Xe);const li=He.run(mt,void 0,$t&&mt!==es&&mt!==Oi?[]:[dt]);cn(ge,!0,li)}catch(dt){cn(ge,!1,dt)}},ge)}const Pi=function(){},ht=Z.AggregateError;class F{static toString(){return"function ZoneAwarePromise() { [native code] }"}static resolve(He){return He instanceof F?He:cn(new this(null),lt,He)}static reject(He){return cn(new this(null),dr,He)}static withResolvers(){const He={};return He.promise=new F((ge,We)=>{He.resolve=ge,He.reject=We}),He}static any(He){if(!He||"function"!=typeof He[Symbol.iterator])return Promise.reject(new ht([],"All promises were rejected"));const ge=[];let We=0;try{for(let mt of He)We++,ge.push(F.resolve(mt))}catch{return Promise.reject(new ht([],"All promises were rejected"))}if(0===We)return Promise.reject(new ht([],"All promises were rejected"));let wt=!1;const Xe=[];return new F((mt,dt)=>{for(let $t=0;$t{wt||(wt=!0,mt(li))},li=>{Xe.push(li),We--,0===We&&(wt=!0,dt(new ht(Xe,"All promises were rejected")))})})}static race(He){let ge,We,wt=new this((dt,$t)=>{ge=dt,We=$t});function Xe(dt){ge(dt)}function mt(dt){We(dt)}for(let dt of He)cr(dt)||(dt=this.resolve(dt)),dt.then(Xe,mt);return wt}static all(He){return F.allWithCallback(He)}static allSettled(He){return(this&&this.prototype instanceof F?this:F).allWithCallback(He,{thenCallback:We=>({status:"fulfilled",value:We}),errorCallback:We=>({status:"rejected",reason:We})})}static allWithCallback(He,ge){let We,wt,Xe=new this((li,ur)=>{We=li,wt=ur}),mt=2,dt=0;const $t=[];for(let li of He){cr(li)||(li=this.resolve(li));const ur=dt;try{li.then(ir=>{$t[ur]=ge?ge.thenCallback(ir):ir,mt--,0===mt&&We($t)},ir=>{ge?($t[ur]=ge.errorCallback(ir),mt--,0===mt&&We($t)):wt(ir)})}catch(ir){wt(ir)}mt++,dt++}return mt-=2,0===mt&&We($t),Xe}constructor(He){const ge=this;if(!(ge instanceof F))throw new Error("Must be an instanceof Promise.");ge[kr]=ki,ge[Wt]=[];try{const We=Pt();He&&He(We(vi(ge,lt)),We(vi(ge,dr)))}catch(We){cn(ge,!1,We)}}get[Symbol.toStringTag](){return"Promise"}get[Symbol.species](){return F}then(He,ge){let We=this.constructor?.[Symbol.species];(!We||"function"!=typeof We)&&(We=this.constructor||F);const wt=new We(Pi),Xe=se.current;return this[kr]==ki?this[Wt].push(Xe,wt,He,ge):Ls(this,Xe,wt,He,ge),wt}catch(He){return this.then(null,He)}finally(He){let ge=this.constructor?.[Symbol.species];(!ge||"function"!=typeof ge)&&(ge=F);const We=new ge(Pi);We[ct]=ct;const wt=se.current;return this[kr]==ki?this[Wt].push(wt,We,He,He):Ls(this,wt,We,He,He),We}}F.resolve=F.resolve,F.reject=F.reject,F.race=F.race,F.all=F.all;const ae=Z[Lt]=Z.Promise;Z.Promise=F;const Et=at("thenPatched");function qt(Ue){const He=Ue.prototype,ge=fe(He,"then");if(ge&&(!1===ge.writable||!ge.configurable))return;const We=He.then;He[ft]=We,Ue.prototype.then=function(wt,Xe){return new F((dt,$t)=>{We.call(this,dt,$t)}).then(wt,Xe)},Ue[Et]=!0}return ye.patchThen=qt,ae&&(qt(ae),Ka(Z,"fetch",Ue=>function Un(Ue){return function(He,ge){let We=Ue.apply(He,ge);if(We instanceof F)return We;let wt=We.constructor;return wt[Et]||qt(wt),We}}(Ue))),Promise[se.__symbol__("uncaughtPromiseErrors")]=tt,F}),Zone.__load_patch("toString",Z=>{const se=Function.prototype.toString,ye=Ji("OriginalDelegate"),fe=Ji("Promise"),be=Ji("Error"),ke=function(){if("function"==typeof this){const Lt=this[ye];if(Lt)return"function"==typeof Lt?se.call(Lt):Object.prototype.toString.call(Lt);if(this===Promise){const ft=Z[fe];if(ft)return se.call(ft)}if(this===Error){const ft=Z[be];if(ft)return se.call(ft)}}return se.call(this)};ke[ye]=se,Function.prototype.toString=ke;const at=Object.prototype.toString;Object.prototype.toString=function(){return"function"==typeof Promise&&this instanceof Promise?"[object Promise]":at.call(this)}});let el=!1;if(typeof window<"u")try{const Z=Object.defineProperty({},"passive",{get:function(){el=!0}});window.addEventListener("test",Z,Z),window.removeEventListener("test",Z,Z)}catch{el=!1}const kT={useG:!0},Co={},Sb={},ym=new RegExp("^"+Vd+"(\\w+)(true|false)$"),Ib=Ji("propagationStopped");function Sm(Z,se){const ye=(se?se(Z):Z)+Wi,fe=(se?se(Z):Z)+Ts,be=Vd+ye,ke=Vd+fe;Co[Z]={},Co[Z][Wi]=be,Co[Z][Ts]=ke}function bb(Z,se,ye,fe){const be=fe&&fe.add||pm,ke=fe&&fe.rm||$r,at=fe&&fe.listeners||"eventListeners",tt=fe&&fe.rmAll||"removeAllListeners",At=Ji(be),Lt="."+be+":",ft="prependListener",Ei="."+ft+":",ii=function(Wt,ct,_n){if(Wt.isRemoved)return;const sr=Wt.callback;let Zr;"object"==typeof sr&&sr.handleEvent&&(Wt.callback=lt=>sr.handleEvent(lt),Wt.originalDelegate=sr);try{Wt.invoke(Wt,ct,[_n])}catch(lt){Zr=lt}const ki=Wt.options;return ki&&"object"==typeof ki&&ki.once&&ct[ke].call(ct,_n.type,Wt.originalDelegate?Wt.originalDelegate:Wt.callback,ki),Zr};function gi(Wt,ct,_n){if(!(ct=ct||Z.event))return;const sr=Wt||ct.target||Z,Zr=sr[Co[ct.type][_n?Ts:Wi]];if(Zr){const ki=[];if(1===Zr.length){const lt=ii(Zr[0],sr,ct);lt&&ki.push(lt)}else{const lt=Zr.slice();for(let dr=0;dr{throw dr})}}}const cr=function(Wt){return gi(this,Wt,!1)},Oi=function(Wt){return gi(this,Wt,!0)};function es(Wt,ct){if(!Wt)return!1;let _n=!0;ct&&void 0!==ct.useG&&(_n=ct.useG);const sr=ct&&ct.vh;let Zr=!0;ct&&void 0!==ct.chkDup&&(Zr=ct.chkDup);let ki=!1;ct&&void 0!==ct.rt&&(ki=ct.rt);let lt=Wt;for(;lt&&!lt.hasOwnProperty(be);)lt=Ud(lt);if(!lt&&Wt[be]&&(lt=Wt),!lt||lt[At])return!1;const dr=ct&&ct.eventNameToString,et={},vi=lt[At]=lt[be],Pt=lt[Ji(ke)]=lt[ke],ts=lt[Ji(at)]=lt[at],_o=lt[Ji(tt)]=lt[tt];let cn;ct&&ct.prepend&&(cn=lt[Ji(ct.prepend)]=lt[ct.prepend]);const F=_n?function(ge){if(!et.isExisting)return vi.call(et.target,et.eventName,et.capture?Oi:cr,et.options)}:function(ge){return vi.call(et.target,et.eventName,ge.invoke,et.options)},ae=_n?function(ge){if(!ge.isRemoved){const We=Co[ge.eventName];let wt;We&&(wt=We[ge.capture?Ts:Wi]);const Xe=wt&&ge.target[wt];if(Xe)for(let mt=0;mt{Vo.zone.cancelTask(Vo)},{once:!0})),et.target=null,Fc&&(Fc.taskData=null),qd&&(Dn.once=!0),!el&&"boolean"==typeof Vo.options||(Vo.options=Dn),Vo.target=$t,Vo.capture=Gl,Vo.eventName=li,ir&&(Vo.originalDelegate=ur),dt?jo.unshift(Vo):jo.push(Vo),mt?$t:void 0}};return lt[be]=He(vi,Lt,F,ae,ki),cn&&(lt[ft]=He(cn,Ei,function(ge){return cn.call(et.target,et.eventName,ge.invoke,et.options)},ae,ki,!0)),lt[ke]=function(){const ge=this||Z;let We=arguments[0];ct&&ct.transferEventName&&(We=ct.transferEventName(We));const wt=arguments[2],Xe=!!wt&&("boolean"==typeof wt||wt.capture),mt=arguments[1];if(!mt)return Pt.apply(this,arguments);if(sr&&!sr(Pt,mt,ge,arguments))return;const dt=Co[We];let $t;dt&&($t=dt[Xe?Ts:Wi]);const li=$t&&ge[$t];if(li)for(let ur=0;urfunction(be,ke){be[Ib]=!0,fe&&fe.apply(be,ke)})}function wb(Z,se,ye,fe,be){const ke=Zone.__symbol__(fe);if(se[ke])return;const at=se[ke]=se[fe];se[fe]=function(tt,At,Lt){return At&&At.prototype&&be.forEach(function(ft){const Ei=`${ye}.${fe}::`+ft,ii=At.prototype;try{if(ii.hasOwnProperty(ft)){const gi=Z.ObjectGetOwnPropertyDescriptor(ii,ft);gi&&gi.value?(gi.value=Z.wrapWithCurrentZone(gi.value,Ei),Z._redefineProperty(At.prototype,ft,gi)):ii[ft]&&(ii[ft]=Z.wrapWithCurrentZone(ii[ft],Ei))}else ii[ft]&&(ii[ft]=Z.wrapWithCurrentZone(ii[ft],Ei))}catch{}}),at.call(se,tt,At,Lt)},Z.attachOriginToPatched(se[fe],at)}function Cb(Z,se,ye){if(!ye||0===ye.length)return se;const fe=ye.filter(ke=>ke.target===Z);if(!fe||0===fe.length)return se;const be=fe[0].ignoreProperties;return se.filter(ke=>-1===be.indexOf(ke))}function Eo(Z,se,ye,fe){Z&&cf(Z,Cb(Z,se,ye),fe)}function Xd(Z){return Object.getOwnPropertyNames(Z).filter(se=>se.startsWith("on")&&se.length>2).map(se=>se.substring(2))}Zone.__load_patch("util",(Z,se,ye)=>{const fe=Xd(Z);ye.patchOnProperties=cf,ye.patchMethod=Ka,ye.bindArguments=Wd,ye.patchMacroTask=vb;const be=se.__symbol__("BLACK_LISTED_EVENTS"),ke=se.__symbol__("UNPATCHED_EVENTS");Z[ke]&&(Z[be]=Z[ke]),Z[be]&&(se[be]=se[ke]=Z[be]),ye.patchEventPrototype=Im,ye.patchEventTarget=bb,ye.isIEOrEdge=yb,ye.ObjectDefineProperty=_d,ye.ObjectGetOwnPropertyDescriptor=_l,ye.ObjectCreate=jd,ye.ArraySlice=gb,ye.patchClass=Qd,ye.wrapWithCurrentZone=of,ye.filterProperties=Cb,ye.attachOriginToPatched=Sa,ye._redefineProperty=Object.defineProperty,ye.patchCallbacks=wb,ye.getGlobalObjects=()=>({globalSources:Sb,zoneSymbolEventNames:Co,eventNames:fe,isBrowser:Yd,isMix:hf,isNode:jh,TRUE_STR:Ts,FALSE_STR:Wi,ZONE_SYMBOL_PREFIX:Vd,ADD_EVENT_LISTENER_STR:pm,REMOVE_EVENT_LISTENER_STR:$r})});const As=Ji("zoneTask");function Wl(Z,se,ye,fe){let be=null,ke=null;ye+=fe;const at={};function tt(Lt){const ft=Lt.data;return ft.args[0]=function(){return Lt.invoke.apply(this,arguments)},ft.handleId=be.apply(Z,ft.args),Lt}function At(Lt){return ke.call(Z,Lt.data.handleId)}be=Ka(Z,se+=fe,Lt=>function(ft,Ei){if("function"==typeof Ei[0]){const ii={isPeriodic:"Interval"===fe,delay:"Timeout"===fe||"Interval"===fe?Ei[1]||0:void 0,args:Ei},gi=Ei[0];Ei[0]=function(){try{return gi.apply(this,arguments)}finally{ii.isPeriodic||("number"==typeof ii.handleId?delete at[ii.handleId]:ii.handleId&&(ii.handleId[As]=null))}};const cr=fm(se,Ei[0],ii,tt,At);if(!cr)return cr;const Oi=cr.data.handleId;return"number"==typeof Oi?at[Oi]=cr:Oi&&(Oi[As]=cr),Oi&&Oi.ref&&Oi.unref&&"function"==typeof Oi.ref&&"function"==typeof Oi.unref&&(cr.ref=Oi.ref.bind(Oi),cr.unref=Oi.unref.bind(Oi)),"number"==typeof Oi||Oi?Oi:cr}return Lt.apply(Z,Ei)}),ke=Ka(Z,ye,Lt=>function(ft,Ei){const ii=Ei[0];let gi;"number"==typeof ii?gi=at[ii]:(gi=ii&&ii[As],gi||(gi=ii)),gi&&"string"==typeof gi.type?"notScheduled"!==gi.state&&(gi.cancelFn&&gi.data.isPeriodic||0===gi.runCount)&&("number"==typeof ii?delete at[ii]:ii&&(ii[As]=null),gi.zone.cancelTask(gi)):Lt.apply(Z,Ei)})}Zone.__load_patch("legacy",Z=>{const se=Z[Zone.__symbol__("legacyPatch")];se&&se()}),Zone.__load_patch("timers",Z=>{const ye="clear";Wl(Z,"set",ye,"Timeout"),Wl(Z,"set",ye,"Interval"),Wl(Z,"set",ye,"Immediate")}),Zone.__load_patch("requestAnimationFrame",Z=>{Wl(Z,"request","cancel","AnimationFrame"),Wl(Z,"mozRequest","mozCancel","AnimationFrame"),Wl(Z,"webkitRequest","webkitCancel","AnimationFrame")}),Zone.__load_patch("blocking",(Z,se)=>{const ye=["alert","prompt","confirm"];for(let fe=0;fefunction(At,Lt){return se.current.run(ke,Z,Lt,tt)})}),Zone.__load_patch("EventTarget",(Z,se,ye)=>{(function Yl(Z,se){se.patchEventPrototype(Z,se)})(Z,ye),function Mm(Z,se){if(Zone[se.symbol("patchEventTarget")])return;const{eventNames:ye,zoneSymbolEventNames:fe,TRUE_STR:be,FALSE_STR:ke,ZONE_SYMBOL_PREFIX:at}=se.getGlobalObjects();for(let At=0;At{Qd("MutationObserver"),Qd("WebKitMutationObserver")}),Zone.__load_patch("IntersectionObserver",(Z,se,ye)=>{Qd("IntersectionObserver")}),Zone.__load_patch("FileReader",(Z,se,ye)=>{Qd("FileReader")}),Zone.__load_patch("on_property",(Z,se,ye)=>{!function df(Z,se){if(jh&&!hf||Zone[Z.symbol("patchEvents")])return;const ye=se.__Zone_ignore_on_properties;let fe=[];if(Yd){const be=window;fe=fe.concat(["Document","SVGElement","Element","HTMLElement","HTMLBodyElement","HTMLMediaElement","HTMLFrameSetElement","HTMLFrameElement","HTMLIFrameElement","HTMLMarqueeElement","Worker"]);const ke=function mm(){try{const Z=Uh.navigator.userAgent;if(-1!==Z.indexOf("MSIE ")||-1!==Z.indexOf("Trident/"))return!0}catch{}return!1}()?[{target:be,ignoreProperties:["error"]}]:[];Eo(be,Xd(be),ye&&ye.concat(ke),Ud(be))}fe=fe.concat(["XMLHttpRequest","XMLHttpRequestEventTarget","IDBIndex","IDBRequest","IDBOpenDBRequest","IDBDatabase","IDBTransaction","IDBCursor","WebSocket"]);for(let be=0;be{!function bm(Z,se){const{isBrowser:ye,isMix:fe}=se.getGlobalObjects();(ye||fe)&&Z.customElements&&"customElements"in Z&&se.patchCallbacks(se,Z.customElements,"customElements","define",["connectedCallback","disconnectedCallback","adoptedCallback","attributeChangedCallback"])}(Z,ye)}),Zone.__load_patch("XHR",(Z,se)=>{!function At(Lt){const ft=Lt.XMLHttpRequest;if(!ft)return;const Ei=ft.prototype;let gi=Ei[Ul],cr=Ei[Fh];if(!gi){const et=Lt.XMLHttpRequestEventTarget;if(et){const vi=et.prototype;gi=vi[Ul],cr=vi[Fh]}}const Oi="readystatechange",es="scheduled";function kr(et){const vi=et.data,Pt=vi.target;Pt[ke]=!1,Pt[tt]=!1;const ts=Pt[be];gi||(gi=Pt[Ul],cr=Pt[Fh]),ts&&cr.call(Pt,Oi,ts);const _o=Pt[be]=()=>{if(Pt.readyState===Pt.DONE)if(!vi.aborted&&Pt[ke]&&et.state===es){const Ur=Pt[se.__symbol__("loadfalse")];if(0!==Pt.status&&Ur&&Ur.length>0){const Do=et.invoke;et.invoke=function(){const Ls=Pt[se.__symbol__("loadfalse")];for(let jr=0;jrfunction(et,vi){return et[fe]=0==vi[2],et[at]=vi[1],_n.apply(et,vi)}),Zr=Ji("fetchTaskAborting"),ki=Ji("fetchTaskScheduling"),lt=Ka(Ei,"send",()=>function(et,vi){if(!0===se.current[ki]||et[fe])return lt.apply(et,vi);{const Pt={target:et,url:et[at],isPeriodic:!1,args:vi,aborted:!1},ts=fm("XMLHttpRequest.send",Wt,Pt,kr,ct);et&&!0===et[tt]&&!Pt.aborted&&ts.state===es&&ts.invoke()}}),dr=Ka(Ei,"abort",()=>function(et,vi){const Pt=function ii(et){return et[ye]}(et);if(Pt&&"string"==typeof Pt.type){if(null==Pt.cancelFn||Pt.data&&Pt.data.aborted)return;Pt.zone.cancelTask(Pt)}else if(!0===se.current[Zr])return dr.apply(et,vi)})}(Z);const ye=Ji("xhrTask"),fe=Ji("xhrSync"),be=Ji("xhrListener"),ke=Ji("xhrScheduled"),at=Ji("xhrURL"),tt=Ji("xhrErrorBeforeScheduled")}),Zone.__load_patch("geolocation",Z=>{Z.navigator&&Z.navigator.geolocation&&function vm(Z,se){const ye=Z.constructor.name;for(let fe=0;fe{const At=function(){return tt.apply(this,Wd(arguments,ye+"."+be))};return Sa(At,tt),At})(ke)}}}(Z.navigator.geolocation,["getCurrentPosition","watchPosition"])}),Zone.__load_patch("PromiseRejectionEvent",(Z,se)=>{function ye(fe){return function(be){Mb(Z,fe).forEach(at=>{const tt=Z.PromiseRejectionEvent;if(tt){const At=new tt(fe,{promise:be.promise,reason:be.rejection});at.invoke(At)}})}}Z.PromiseRejectionEvent&&(se[Ji("unhandledPromiseRejectionHandler")]=ye("unhandledrejection"),se[Ji("rejectionHandledHandler")]=ye("rejectionhandled"))}),Zone.__load_patch("queueMicrotask",(Z,se,ye)=>{!function uf(Z,se){se.patchMethod(Z,"queueMicrotask",ye=>function(fe,be){Zone.current.scheduleMicroTask("queueMicrotask",be[0])})}(Z,ye)})}},_l=>{_l(_l.s=51)}]); \ No newline at end of file diff --git a/ej2-angular/samples/diagram/ports/remove-cs1/main.89a4eb77ff6e4ae0.js b/ej2-angular/samples/diagram/ports/remove-cs1/main.89a4eb77ff6e4ae0.js new file mode 100644 index 0000000000..f64c98a3d5 --- /dev/null +++ b/ej2-angular/samples/diagram/ports/remove-cs1/main.89a4eb77ff6e4ae0.js @@ -0,0 +1 @@ +"use strict";(self.webpackChunksyncfusion_component=self.webpackChunksyncfusion_component||[]).push([[179],{51:(Wl,Ud,jd)=>{let $r=null,_h=1;const Ts=Symbol("SIGNAL");function Wi(n){const t=$r;return $r=n,t}function gn(n){if((!Wh(n)||n.dirty)&&(n.dirty||n.lastCleanEpoch!==_h)){if(!n.producerMustRecompute(n)&&!Vh(n))return n.dirty=!1,void(n.lastCleanEpoch=_h);n.producerRecomputeValue(n),n.dirty=!1,n.lastCleanEpoch=_h}}function Vh(n){Gl(n);for(let t=0;t0}function Gl(n){n.producerNode??=[],n.producerIndexOfThis??=[],n.producerLastReadVersion??=[]}let Xd=null;function Eo(n){return"function"==typeof n}function qd(n){const e=n(i=>{Error.call(i),i.stack=(new Error).stack});return e.prototype=Object.create(Error.prototype),e.prototype.constructor=e,e}const dp=qd(n=>function(e){n(this),this.message=e?`${e.length} errors occurred during unsubscription:\n${e.map((i,r)=>`${r+1}) ${i.toString()}`).join("\n ")}`:"",this.name="UnsubscriptionError",this.errors=e});function up(n,t){if(n){const e=n.indexOf(t);0<=e&&n.splice(e,1)}}class As{constructor(t){this.initialTeardown=t,this.closed=!1,this._parentage=null,this._finalizers=null}unsubscribe(){let t;if(!this.closed){this.closed=!0;const{_parentage:e}=this;if(e)if(this._parentage=null,Array.isArray(e))for(const s of e)s.remove(this);else e.remove(this);const{initialTeardown:i}=this;if(Eo(i))try{i()}catch(s){t=s instanceof dp?s.errors:[s]}const{_finalizers:r}=this;if(r){this._finalizers=null;for(const s of r)try{wm(s)}catch(o){t=t??[],o instanceof dp?t=[...t,...o.errors]:t.push(o)}}if(t)throw new dp(t)}}add(t){var e;if(t&&t!==this)if(this.closed)wm(t);else{if(t instanceof As){if(t.closed||t._hasParent(this))return;t._addParent(this)}(this._finalizers=null!==(e=this._finalizers)&&void 0!==e?e:[]).push(t)}}_hasParent(t){const{_parentage:e}=this;return e===t||Array.isArray(e)&&e.includes(t)}_addParent(t){const{_parentage:e}=this;this._parentage=Array.isArray(e)?(e.push(t),e):e?[e,t]:t}_removeParent(t){const{_parentage:e}=this;e===t?this._parentage=null:Array.isArray(e)&&up(e,t)}remove(t){const{_finalizers:e}=this;e&&up(e,t),t instanceof As&&t._removeParent(this)}}As.EMPTY=(()=>{const n=new As;return n.closed=!0,n})();const Xl=As.EMPTY;function Mm(n){return n instanceof As||n&&"closed"in n&&Eo(n.remove)&&Eo(n.add)&&Eo(n.unsubscribe)}function wm(n){Eo(n)?n():n.unsubscribe()}const ql={onUnhandledError:null,onStoppedNotification:null,Promise:void 0,useDeprecatedSynchronousErrorHandling:!1,useDeprecatedNextContext:!1},Z={setTimeout(n,t,...e){const{delegate:i}=Z;return i?.setTimeout?i.setTimeout(n,t,...e):setTimeout(n,t,...e)},clearTimeout(n){const{delegate:t}=Z;return(t?.clearTimeout||clearTimeout)(n)},delegate:void 0};function ye(){}const pe=at("C",void 0,void 0);function at(n,t,e){return{kind:n,value:t,error:e}}let tt=null;function At(n){if(ql.useDeprecatedSynchronousErrorHandling){const t=!tt;if(t&&(tt={errorThrown:!1,error:null}),n(),t){const{errorThrown:e,error:i}=tt;if(tt=null,e)throw i}}else n()}class pt extends As{constructor(t){super(),this.isStopped=!1,t?(this.destination=t,Mm(t)&&t.add(this)):this.destination=Wt}static create(t,e,i){return new cr(t,e,i)}next(t){this.isStopped?Pr(function ke(n){return at("N",n,void 0)}(t),this):this._next(t)}error(t){this.isStopped?Pr(function be(n){return at("E",void 0,n)}(t),this):(this.isStopped=!0,this._error(t))}complete(){this.isStopped?Pr(pe,this):(this.isStopped=!0,this._complete())}unsubscribe(){this.closed||(this.isStopped=!0,super.unsubscribe(),this.destination=null)}_next(t){this.destination.next(t)}_error(t){try{this.destination.error(t)}finally{this.unsubscribe()}}_complete(){try{this.destination.complete()}finally{this.unsubscribe()}}}const Di=Function.prototype.bind;function si(n,t){return Di.call(n,t)}class mi{constructor(t){this.partialObserver=t}next(t){const{partialObserver:e}=this;if(e.next)try{e.next(t)}catch(i){ki(i)}}error(t){const{partialObserver:e}=this;if(e.error)try{e.error(t)}catch(i){ki(i)}else ki(t)}complete(){const{partialObserver:t}=this;if(t.complete)try{t.complete()}catch(e){ki(e)}}}class cr extends pt{constructor(t,e,i){let r;if(super(),Eo(t)||!t)r={next:t??void 0,error:e??void 0,complete:i??void 0};else{let s;this&&ql.useDeprecatedNextContext?(s=Object.create(t),s.unsubscribe=()=>this.unsubscribe(),r={next:t.next&&si(t.next,s),error:t.error&&si(t.error,s),complete:t.complete&&si(t.complete,s)}):r=t}this.destination=new mi(r)}}function ki(n){ql.useDeprecatedSynchronousErrorHandling?function Lt(n){ql.useDeprecatedSynchronousErrorHandling&&tt&&(tt.errorThrown=!0,tt.error=n)}(n):function se(n){Z.setTimeout(()=>{const{onUnhandledError:t}=ql;if(!t)throw n;t(n)})}(n)}function Pr(n,t){const{onStoppedNotification:e}=ql;e&&Z.setTimeout(()=>e(n,t))}const Wt={closed:!0,next:ye,error:function is(n){throw n},complete:ye},ct="function"==typeof Symbol&&Symbol.observable||"@@observable";function jn(n){return n}let Pi=(()=>{class n{constructor(e){e&&(this._subscribe=e)}lift(e){const i=new n;return i.source=this,i.operator=e,i}subscribe(e,i,r){const s=function et(n){return n&&n instanceof pt||function dr(n){return n&&Eo(n.next)&&Eo(n.error)&&Eo(n.complete)}(n)&&Mm(n)}(e)?e:new cr(e,i,r);return At(()=>{const{operator:o,source:a}=this;s.add(o?o.call(s,a):a?this._subscribe(s):this._trySubscribe(s))}),s}_trySubscribe(e){try{return this._subscribe(e)}catch(i){e.error(i)}}forEach(e,i){return new(i=lt(i))((r,s)=>{const o=new cr({next:a=>{try{e(a)}catch(l){s(l),o.unsubscribe()}},error:s,complete:r});this.subscribe(o)})}_subscribe(e){var i;return null===(i=this.source)||void 0===i?void 0:i.subscribe(e)}[ct](){return this}pipe(...e){return function Zr(n){return 0===n.length?jn:1===n.length?n[0]:function(e){return n.reduce((i,r)=>r(i),e)}}(e)(this)}toPromise(e){return new(e=lt(e))((i,r)=>{let s;this.subscribe(o=>s=o,o=>r(o),()=>i(s))})}}return n.create=t=>new n(t),n})();function lt(n){var t;return null!==(t=n??ql.Promise)&&void 0!==t?t:Promise}const yi=qd(n=>function(){n(this),this.name="ObjectUnsubscribedError",this.message="object unsubscribed"});let Pt=(()=>{class n extends Pi{constructor(){super(),this.closed=!1,this.currentObservers=null,this.observers=[],this.isStopped=!1,this.hasError=!1,this.thrownError=null}lift(e){const i=new rs(this,this);return i.operator=e,i}_throwIfClosed(){if(this.closed)throw new yi}next(e){At(()=>{if(this._throwIfClosed(),!this.isStopped){this.currentObservers||(this.currentObservers=Array.from(this.observers));for(const i of this.currentObservers)i.next(e)}})}error(e){At(()=>{if(this._throwIfClosed(),!this.isStopped){this.hasError=this.isStopped=!0,this.thrownError=e;const{observers:i}=this;for(;i.length;)i.shift().error(e)}})}complete(){At(()=>{if(this._throwIfClosed(),!this.isStopped){this.isStopped=!0;const{observers:e}=this;for(;e.length;)e.shift().complete()}})}unsubscribe(){this.isStopped=this.closed=!0,this.observers=this.currentObservers=null}get observed(){var e;return(null===(e=this.observers)||void 0===e?void 0:e.length)>0}_trySubscribe(e){return this._throwIfClosed(),super._trySubscribe(e)}_subscribe(e){return this._throwIfClosed(),this._checkFinalizedStatuses(e),this._innerSubscribe(e)}_innerSubscribe(e){const{hasError:i,isStopped:r,observers:s}=this;return i||r?Xl:(this.currentObservers=null,s.push(e),new As(()=>{this.currentObservers=null,up(s,e)}))}_checkFinalizedStatuses(e){const{hasError:i,thrownError:r,isStopped:s}=this;i?e.error(r):s&&e.complete()}asObservable(){const e=new Pi;return e.source=this,e}}return n.create=(t,e)=>new rs(t,e),n})();class rs extends Pt{constructor(t,e){super(),this.destination=t,this.source=e}next(t){var e,i;null===(i=null===(e=this.destination)||void 0===e?void 0:e.next)||void 0===i||i.call(e,t)}error(t){var e,i;null===(i=null===(e=this.destination)||void 0===e?void 0:e.error)||void 0===i||i.call(e,t)}complete(){var t,e;null===(e=null===(t=this.destination)||void 0===t?void 0:t.complete)||void 0===e||e.call(t)}_subscribe(t){var e,i;return null!==(i=null===(e=this.source)||void 0===e?void 0:e.subscribe(t))&&void 0!==i?i:Xl}}class _o extends Pt{constructor(t){super(),this._value=t}get value(){return this.getValue()}_subscribe(t){const e=super._subscribe(t);return!e.closed&&t.next(this._value),e}getValue(){const{hasError:t,thrownError:e,_value:i}=this;if(t)throw e;return this._throwIfClosed(),i}next(t){super.next(this._value=t)}}class Ls extends pt{constructor(t,e,i,r,s,o){super(t),this.onFinalize=s,this.shouldUnsubscribe=o,this._next=e?function(a){try{e(a)}catch(l){t.error(l)}}:super._next,this._error=r?function(a){try{r(a)}catch(l){t.error(l)}finally{this.unsubscribe()}}:super._error,this._complete=i?function(){try{i()}catch(a){t.error(a)}finally{this.unsubscribe()}}:super._complete}unsubscribe(){var t;if(!this.shouldUnsubscribe||this.shouldUnsubscribe()){const{closed:e}=this;super.unsubscribe(),!e&&(null===(t=this.onFinalize)||void 0===t||t.call(this))}}}function jr(n,t){return function Ur(n){return t=>{if(function cn(n){return Eo(n?.lift)}(t))return t.lift(function(e){try{return n(e,this)}catch(i){this.error(i)}});throw new TypeError("Unable to lift unknown Observable type")}}((e,i)=>{let r=0;e.subscribe(function Do(n,t,e,i,r){return new Ls(n,t,e,i,r)}(i,s=>{i.next(n.call(t,s,r++))}))})}class F extends Error{constructor(t,e){super(function ae(n,t){return`NG0${Math.abs(n)}${t?": "+t:""}`}(t,e)),this.code=t}}function Xe(n){for(let t in n)if(n[t]===Xe)return t;throw Error("Could not find renamed property on target object.")}function mt(n,t){for(const e in t)t.hasOwnProperty(e)&&!n.hasOwnProperty(e)&&(n[e]=t[e])}function dt(n){if("string"==typeof n)return n;if(Array.isArray(n))return"["+n.map(dt).join(", ")+"]";if(null==n)return""+n;if(n.overriddenName)return`${n.overriddenName}`;if(n.name)return`${n.name}`;const t=n.toString();if(null==t)return""+t;const e=t.indexOf("\n");return-1===e?t:t.substring(0,e)}function $t(n,t){return null==n||""===n?null===t?"":t:null==t||""===t?n:n+" "+t}const ur=Xe({__forward_ref__:Xe});function ir(n){return n.__forward_ref__=ir,n.toString=function(){return dt(this())},n}function vt(n){return function Tn(n){return"function"==typeof n&&n.hasOwnProperty(ur)&&n.__forward_ref__===ir}(n)?n():n}function $l(n){return n&&!!n.\u0275providers}const Zl=Xe({\u0275cmp:Xe}),$d=Xe({\u0275dir:Xe}),fp=Xe({\u0275pipe:Xe}),Uo=Xe({\u0275fac:Xe}),jo=Xe({__NG_ELEMENT_ID__:Xe}),pp=Xe({__NG_ENV_ID__:Xe});function Ri(n){return"function"==typeof n?n.name||n.toString():"object"==typeof n&&null!=n&&"function"==typeof n.type?n.type.name||n.type.toString():function Nt(n){return"string"==typeof n?n:null==n?"":String(n)}(n)}function xb(n,t){throw new F(-201,!1)}function so(n,t){null==n&&function zt(n,t,e,i){throw new Error(`ASSERTION ERROR: ${n}`+(null==i?"":` [Expected=> ${e} ${i} ${t} <=Actual]`))}(t,n,null,"!=")}function Yi(n){return{token:n.token,providedIn:n.providedIn||null,factory:n.factory,value:void 0}}function gp(n){return{providers:n.providers||[],imports:n.imports||[]}}function Cm(n){return PT(n,Dm)||PT(n,zT)}function PT(n,t){return n.hasOwnProperty(t)?n[t]:null}function Em(n){return n&&(n.hasOwnProperty(Tb)||n.hasOwnProperty(E_))?n[Tb]:null}const Dm=Xe({\u0275prov:Xe}),Tb=Xe({\u0275inj:Xe}),zT=Xe({ngInjectableDef:Xe}),E_=Xe({ngInjectorDef:Xe});var xi=function(n){return n[n.Default=0]="Default",n[n.Host=1]="Host",n[n.Self=2]="Self",n[n.SkipSelf=4]="SkipSelf",n[n.Optional=8]="Optional",n}(xi||{});let Ab;function oo(n){const t=Ab;return Ab=n,t}function HT(n,t,e){const i=Cm(n);return i&&"root"==i.providedIn?void 0===i.value?i.value=i.factory():i.value:e&xi.Optional?null:void 0!==t?t:void xb()}const rr=globalThis;class Ht{constructor(t,e){this._desc=t,this.ngMetadataName="InjectionToken",this.\u0275prov=void 0,"number"==typeof e?this.__NG_ELEMENT_ID__=e:void 0!==e&&(this.\u0275prov=Yi({token:this,providedIn:e.providedIn||"root",factory:e.factory}))}get multi(){return this}toString(){return`InjectionToken ${this._desc}`}}const vp={},Pb="__NG_DI_FLAG__",xm="ngTempTokenPath",T_=/\n/gm,FT="__source";let Jd;function Gh(n){const t=Jd;return Jd=n,t}function N_(n,t=xi.Default){if(void 0===Jd)throw new F(-203,!1);return null===Jd?HT(n,void 0,t):Jd.get(n,t&xi.Optional?null:void 0,t)}function _i(n,t=xi.Default){return(function RT(){return Ab}()||N_)(vt(n),t)}function Hi(n,t=xi.Default){return _i(n,Tm(t))}function Tm(n){return typeof n>"u"||"number"==typeof n?n:0|(n.optional&&8)|(n.host&&1)|(n.self&&2)|(n.skipSelf&&4)}function zb(n){const t=[];for(let e=0;et){o=s-1;break}}}for(;ss?"":r[d+1].toLowerCase();const f=8&i?u:null;if(f&&-1!==UT(f,h,0)||2&i&&h!==u){if(Ma(i))return!1;o=!0}}}}else{if(!o&&!Ma(i)&&!Ma(l))return!1;if(o&&Ma(l))continue;o=!1,i=l|1&i}}return Ma(i)||o}function Ma(n){return 0==(1&n)}function B_(n,t,e,i){if(null===t)return-1;let r=0;if(i||!e){let s=!1;for(;r-1)for(e++;e0?'="'+a+'"':"")+"]"}else 8&i?r+="."+o:4&i&&(r+=" "+o);else""!==r&&!Ma(o)&&(t+=XT(s,r),r=""),i=o,s=s||!Ma(i);e++}return""!==r&&(t+=XT(s,r)),t}function Hb(n){return Jl(()=>{const t=$T(n),e={...t,decls:n.decls,vars:n.vars,template:n.template,consts:n.consts||null,ngContentSelectors:n.ngContentSelectors,onPush:n.changeDetection===Am.OnPush,directiveDefs:null,pipeDefs:null,dependencies:t.standalone&&n.dependencies||null,getStandaloneInjector:null,signals:n.signals??!1,data:n.data||{},encapsulation:n.encapsulation||ba.Emulated,styles:n.styles||Qi,_:null,schemas:n.schemas||null,tView:null,id:""};ZT(e);const i=n.dependencies;return e.directiveDefs=Nm(i,!1),e.pipeDefs=Nm(i,!0),e.id=function q_(n){let t=0;const e=[n.selectors,n.ngContentSelectors,n.hostVars,n.hostAttrs,n.consts,n.vars,n.decls,n.encapsulation,n.standalone,n.signals,n.exportAs,JSON.stringify(n.inputs),JSON.stringify(n.outputs),Object.getOwnPropertyNames(n.type.prototype),!!n.contentQueries,!!n.viewQuery].join("|");for(const r of e)t=Math.imul(31,t)+r.charCodeAt(0)<<0;return t+=2147483648,"c"+t}(e),e})}function Q_(n){return di(n)||Wn(n)}function G_(n){return null!==n}function Lm(n){return Jl(()=>({type:n.type,bootstrap:n.bootstrap||Qi,declarations:n.declarations||Qi,imports:n.imports||Qi,exports:n.exports||Qi,transitiveCompileScopes:null,schemas:n.schemas||null,id:n.id||null}))}function qT(n,t){if(null==n)return rl;const e={};for(const i in n)if(n.hasOwnProperty(i)){const r=n[i];let s,o,a=Xh.None;Array.isArray(r)?(a=r[0],s=r[1],o=r[2]??s):(s=r,o=r),t?(e[s]=a!==Xh.None?[i,a]:i,t[s]=o):e[s]=i}return e}function nr(n){return Jl(()=>{const t=$T(n);return ZT(t),t})}function di(n){return n[Zl]||null}function Wn(n){return n[$d]||null}function gs(n){return n[fp]||null}function $T(n){const t={};return{type:n.type,providersResolver:null,factory:null,hostBindings:n.hostBindings||null,hostVars:n.hostVars||0,hostAttrs:n.hostAttrs||null,contentQueries:n.contentQueries||null,declaredInputs:t,inputTransforms:null,inputConfig:n.inputs||rl,exportAs:n.exportAs||null,standalone:!0===n.standalone,signals:!0===n.signals,selectors:n.selectors||Qi,viewQuery:n.viewQuery||null,features:n.features||null,setInput:null,findHostDirectiveDefs:null,hostDirectives:null,inputs:qT(n.inputs,t),outputs:qT(n.outputs),debugInfo:null}}function ZT(n){n.features?.forEach(t=>t(n))}function Nm(n,t){if(!n)return null;const e=t?gs:Q_;return()=>("function"==typeof n?n():n).map(i=>e(i)).filter(G_)}const Vr=0,Be=1,Ct=2,vn=3,wa=4,Os=5,Ca=6,Kd=7,Er=8,Xs=9,Kl=10,Yt=11,Sp=12,JT=13,eu=14,Jr=15,Ip=16,tu=17,nl=18,bp=19,KT=20,qh=21,Om=22,Uc=23,jt=25,Bb=1,sl=7,iu=9,mn=10;var Fb=function(n){return n[n.None=0]="None",n[n.HasTransplantedViews=2]="HasTransplantedViews",n}(Fb||{});function ks(n){return Array.isArray(n)&&"object"==typeof n[Bb]}function Ps(n){return Array.isArray(n)&&!0===n[Bb]}function _b(n){return 0!=(4&n.flags)}function jc(n){return n.componentOffset>-1}function Pm(n){return 1==(1&n.flags)}function Ea(n){return!!n.template}function Ub(n){return 0!=(512&n[Ct])}function Vc(n,t){return n.hasOwnProperty(Uo)?n[Uo]:null}class K_{constructor(t,e,i){this.previousValue=t,this.currentValue=e,this.firstChange=i}isFirstChange(){return this.firstChange}}function rA(n,t,e,i){null!==t?t.applyValueToInputSignal(t,i):n[e]=i}function nA(n){return n.type.prototype.ngOnChanges&&(n.setInput=tU),eU}function eU(){const n=oA(this),t=n?.current;if(t){const e=n.previous;if(e===rl)n.previous=t;else for(let i in t)e[i]=t[i];n.current=null,this.ngOnChanges(t)}}function tU(n,t,e,i,r){const s=this.declaredInputs[i],o=oA(n)||function iU(n,t){return n[sA]=t}(n,{previous:rl,current:null}),a=o.current||(o.current={}),l=o.previous,h=l[s];a[s]=new K_(h&&h.currentValue,e,l===rl),rA(n,t,r,e)}const sA="__ngSimpleChanges__";function oA(n){return n[sA]||null}const ol=function(n,t,e){};let hA=!1;function fr(n){for(;Array.isArray(n);)n=n[Vr];return n}function qs(n,t){return fr(t[n.index])}function Cp(n,t){return n.data[t]}function To(n,t){const e=t[n];return ks(e)?e:e[Vr]}function Qb(n){return 128==(128&n[Ct])}function al(n,t){return null==t?null:n[t]}function cA(n){n[tu]=0}function lU(n){1024&n[Ct]||(n[Ct]|=1024,Qb(n)&&Ep(n))}function uA(n){return 9216&n[Ct]||n[Uc]?.dirty}function Gb(n){uA(n)?Ep(n):64&n[Ct]&&(function nU(){return hA}()?(n[Ct]|=1024,Ep(n)):n[Kl].changeDetectionScheduler?.notify())}function Ep(n){n[Kl].changeDetectionScheduler?.notify();let t=Wc(n);for(;null!==t&&!(8192&t[Ct])&&(t[Ct]|=8192,Qb(t));)t=Wc(t)}function Wc(n){const t=n[vn];return Ps(t)?t[vn]:t}const Rt={lFrame:MA(null),bindingsEnabled:!0,skipHydrationRootTNode:null};function pA(){return Rt.bindingsEnabled}function Se(){return Rt.lFrame.lView}function Ti(){return Rt.lFrame.tView}function pr(){let n=gA();for(;null!==n&&64===n.type;)n=n.parent;return n}function gA(){return Rt.lFrame.currentTNode}function ll(n,t){const e=Rt.lFrame;e.currentTNode=n,e.isParent=t}function qb(){return Rt.lFrame.isParent}function bU(n,t){const e=Rt.lFrame;e.bindingIndex=e.bindingRootIndex=n,Zb(t)}function Zb(n){Rt.lFrame.currentDirectiveIndex=n}function SA(){return Rt.lFrame.currentQueryIndex}function Kb(n){Rt.lFrame.currentQueryIndex=n}function wU(n){const t=n[Be];return 2===t.type?t.declTNode:1===t.type?n[Os]:null}function IA(n,t,e){if(e&xi.SkipSelf){let r=t,s=n;for(;!(r=r.parent,null!==r||e&xi.Host||(r=wU(s),null===r||(s=s[eu],10&r.type))););if(null===r)return!1;t=r,n=s}const i=Rt.lFrame=bA();return i.currentTNode=t,i.lView=n,!0}function e1(n){const t=bA(),e=n[Be];Rt.lFrame=t,t.currentTNode=e.firstChild,t.lView=n,t.tView=e,t.contextLView=n,t.bindingIndex=e.bindingStartIndex,t.inI18n=!1}function bA(){const n=Rt.lFrame,t=null===n?null:n.child;return null===t?MA(n):t}function MA(n){const t={currentTNode:null,isParent:!0,lView:null,tView:null,selectedIndex:-1,contextLView:null,elementDepthCount:0,currentNamespace:null,currentDirectiveIndex:-1,bindingRootIndex:-1,bindingIndex:-1,currentQueryIndex:0,parent:n,child:null,inI18n:!1};return null!==n&&(n.child=t),t}function wA(){const n=Rt.lFrame;return Rt.lFrame=n.parent,n.currentTNode=null,n.lView=null,n}const CA=wA;function t1(){const n=wA();n.isParent=!0,n.tView=null,n.selectedIndex=-1,n.contextLView=null,n.elementDepthCount=0,n.currentDirectiveIndex=-1,n.currentNamespace=null,n.bindingRootIndex=-1,n.bindingIndex=-1,n.currentQueryIndex=0}function zs(){return Rt.lFrame.selectedIndex}function Yc(n){Rt.lFrame.selectedIndex=n}let DA=!0;function Hm(){return DA}function $h(n){DA=n}function Bm(n,t){for(let e=t.directiveStart,i=t.directiveEnd;e=i)break}else t[l]<0&&(n[tu]+=65536),(a>14>16&&(3&n[Ct])===t&&(n[Ct]+=16384,TA(a,s)):TA(a,s)}const su=-1;class xp{constructor(t,e,i){this.factory=t,this.resolving=!1,this.canSeeViewProviders=e,this.injectImpl=i}}function n1(n){return n!==su}function Tp(n){return 32767&n}function Ap(n,t){let e=function zU(n){return n>>16}(n),i=t;for(;e>0;)i=i[eu],e--;return i}let s1=!0;function Um(n){const t=s1;return s1=n,t}const AA=255,LA=5;let RU=0;const cl={};function jm(n,t){const e=NA(n,t);if(-1!==e)return e;const i=t[Be];i.firstCreatePass&&(n.injectorIndex=t.length,o1(i.data,n),o1(t,null),o1(i.blueprint,null));const r=Vm(n,t),s=n.injectorIndex;if(n1(r)){const o=Tp(r),a=Ap(r,t),l=a[Be].data;for(let h=0;h<8;h++)t[s+h]=a[o+h]|l[o+h]}return t[s+8]=r,s}function o1(n,t){n.push(0,0,0,0,0,0,0,0,t)}function NA(n,t){return-1===n.injectorIndex||n.parent&&n.parent.injectorIndex===n.injectorIndex||null===t[n.injectorIndex+8]?-1:n.injectorIndex}function Vm(n,t){if(n.parent&&-1!==n.parent.injectorIndex)return n.parent.injectorIndex;let e=0,i=null,r=t;for(;null!==r;){if(i=BA(r),null===i)return su;if(e++,r=r[eu],-1!==i.injectorIndex)return i.injectorIndex|e<<16}return su}function a1(n,t,e){!function HU(n,t,e){let i;"string"==typeof e?i=e.charCodeAt(0)||0:e.hasOwnProperty(jo)&&(i=e[jo]),null==i&&(i=e[jo]=RU++);const r=i&AA;t.data[n+(r>>LA)]|=1<=0?t&AA:UU:t}(e);if("function"==typeof s){if(!IA(t,n,i))return i&xi.Host?OA(r,0,i):kA(t,e,i,r);try{let o;if(o=s(i),null!=o||i&xi.Optional)return o;xb()}finally{CA()}}else if("number"==typeof s){let o=null,a=NA(n,t),l=su,h=i&xi.Host?t[Jr][Os]:null;for((-1===a||i&xi.SkipSelf)&&(l=-1===a?Vm(n,t):t[a+8],l!==su&&HA(i,!1)?(o=t[Be],a=Tp(l),t=Ap(l,t)):a=-1);-1!==a;){const c=t[Be];if(RA(s,a,c.data)){const d=FU(a,t,e,o,i,h);if(d!==cl)return d}l=t[a+8],l!==su&&HA(i,t[Be].data[a+8]===h)&&RA(s,a,t)?(o=c,a=Tp(l),t=Ap(l,t)):a=-1}}return r}function FU(n,t,e,i,r,s){const o=t[Be],a=o.data[n+8],c=Wm(a,o,e,null==i?jc(a)&&s1:i!=o&&0!=(3&a.type),r&xi.Host&&s===a);return null!==c?Qc(t,o,c,a):cl}function Wm(n,t,e,i,r){const s=n.providerIndexes,o=t.data,a=1048575&s,l=n.directiveStart,c=s>>20,u=r?a+c:n.directiveEnd;for(let f=i?a:a+c;f=l&&p.type===e)return f}if(r){const f=o[l];if(f&&Ea(f)&&f.type===e)return l}return null}function Qc(n,t,e,i){let r=n[e];const s=t.data;if(function NU(n){return n instanceof xp}(r)){const o=r;o.resolving&&function Vo(n,t){const e=t?`. Dependency path: ${t.join(" > ")} > ${n}`:"";throw new F(-200,`Circular dependency in DI detected for ${n}${e}`)}(Ri(s[e]));const a=Um(o.canSeeViewProviders);o.resolving=!0;const h=o.injectImpl?oo(o.injectImpl):null;IA(n,i,xi.Default);try{r=n[e]=o.factory(void 0,s,n,i),t.firstCreatePass&&e>=i.directiveStart&&function AU(n,t,e){const{ngOnChanges:i,ngOnInit:r,ngDoCheck:s}=t.type.prototype;if(i){const o=nA(t);(e.preOrderHooks??=[]).push(n,o),(e.preOrderCheckHooks??=[]).push(n,o)}r&&(e.preOrderHooks??=[]).push(0-n,r),s&&((e.preOrderHooks??=[]).push(n,s),(e.preOrderCheckHooks??=[]).push(n,s))}(e,s[e],t)}finally{null!==h&&oo(h),Um(a),o.resolving=!1,CA()}}return r}function RA(n,t,e){return!!(e[t+(n>>LA)]&1<Array.isArray(e)?fu(e,t):t(e))}function _A(n,t,e){t>=n.length?n.push(e):n.splice(t,0,e)}function Ym(n,t){return t>=n.length-1?n.pop():n.splice(t,1)[0]}const vu=new Ht(""),QA=new Ht("",-1),m1=new Ht("");class qm{get(t,e=vp){if(e===vp){const i=new Error(`NullInjectorError: No provider for ${dt(t)}!`);throw i.name="NullInjectorError",i}return e}}function dj(...n){return{\u0275providers:GA(0,n),\u0275fromNgModule:!0}}function GA(n,...t){const e=[],i=new Set;let r;const s=o=>{e.push(o)};return fu(t,o=>{const a=o;$m(a,s,[],i)&&(r||=[],r.push(a))}),void 0!==r&&XA(r,s),e}function XA(n,t){for(let e=0;e{t(s,i)})}}function $m(n,t,e,i){if(!(n=vt(n)))return!1;let r=null,s=Em(n);const o=!s&&di(n);if(s||o){if(o&&!o.standalone)return!1;r=n}else{const l=n.ngModule;if(s=Em(l),!s)return!1;r=l}const a=i.has(r);if(o){if(a)return!1;if(i.add(r),o.dependencies){const l="function"==typeof o.dependencies?o.dependencies():o.dependencies;for(const h of l)$m(h,t,e,i)}}else{if(!s)return!1;{if(null!=s.imports&&!a){let h;i.add(r);try{fu(s.imports,c=>{$m(c,t,e,i)&&(h||=[],h.push(c))})}finally{}void 0!==h&&XA(h,t)}if(!a){const h=Vc(r)||(()=>new r);t({provide:r,useFactory:h,deps:Qi},r),t({provide:m1,useValue:r,multi:!0},r),t({provide:vu,useValue:()=>_i(r),multi:!0},r)}const l=s.providers;if(null!=l&&!a){const h=n;S1(l,c=>{t(c,h)})}}}return r!==n&&void 0!==n.providers}function S1(n,t){for(let e of n)$l(e)&&(e=e.\u0275providers),Array.isArray(e)?S1(e,t):t(e)}const uj=Xe({provide:String,useValue:Xe});function I1(n){return null!==n&&"object"==typeof n&&uj in n}function Gc(n){return"function"==typeof n}const b1=new Ht(""),Zm={},pj={};let M1;function Jm(){return void 0===M1&&(M1=new qm),M1}class ih{}class mu extends ih{get destroyed(){return this._destroyed}constructor(t,e,i,r){super(),this.parent=e,this.source=i,this.scopes=r,this.records=new Map,this._ngOnDestroyHooks=new Set,this._onDestroyHooks=[],this._destroyed=!1,C1(t,o=>this.processProvider(o)),this.records.set(QA,yu(void 0,this)),r.has("environment")&&this.records.set(ih,yu(void 0,this));const s=this.records.get(b1);null!=s&&"string"==typeof s.value&&this.scopes.add(s.value),this.injectorDefTypes=new Set(this.get(m1,Qi,xi.Self))}destroy(){this.assertNotDestroyed(),this._destroyed=!0;try{for(const e of this._ngOnDestroyHooks)e.ngOnDestroy();const t=this._onDestroyHooks;this._onDestroyHooks=[];for(const e of t)e()}finally{this.records.clear(),this._ngOnDestroyHooks.clear(),this.injectorDefTypes.clear()}}onDestroy(t){return this.assertNotDestroyed(),this._onDestroyHooks.push(t),()=>this.removeOnDestroy(t)}runInContext(t){this.assertNotDestroyed();const e=Gh(this),i=oo(void 0);try{return t()}finally{Gh(e),oo(i)}}get(t,e=vp,i=xi.Default){if(this.assertNotDestroyed(),t.hasOwnProperty(pp))return t[pp](this);i=Tm(i);const s=Gh(this),o=oo(void 0);try{if(!(i&xi.SkipSelf)){let l=this.records.get(t);if(void 0===l){const h=function Sj(n){return"function"==typeof n||"object"==typeof n&&n instanceof Ht}(t)&&Cm(t);l=h&&this.injectableDefInScope(h)?yu(w1(t),Zm):null,this.records.set(t,l)}if(null!=l)return this.hydrate(t,l)}return(i&xi.Self?Jm():this.parent).get(t,e=i&xi.Optional&&e===vp?null:e)}catch(a){if("NullInjectorError"===a.name){if((a[xm]=a[xm]||[]).unshift(dt(t)),s)throw a;return function k_(n,t,e,i){const r=n[xm];throw t[FT]&&r.unshift(t[FT]),n.message=function P_(n,t,e,i=null){n=n&&"\n"===n.charAt(0)&&"\u0275"==n.charAt(1)?n.slice(2):n;let r=dt(t);if(Array.isArray(t))r=t.map(dt).join(" -> ");else if("object"==typeof t){let s=[];for(let o in t)if(t.hasOwnProperty(o)){let a=t[o];s.push(o+":"+("string"==typeof a?JSON.stringify(a):dt(a)))}r=`{${s.join(", ")}}`}return`${e}${i?"("+i+")":""}[${r}]: ${n.replace(T_,"\n ")}`}("\n"+n.message,r,e,i),n.ngTokenPath=r,n[xm]=null,n}(a,t,"R3InjectorError",this.source)}throw a}finally{oo(o),Gh(s)}}resolveInjectorInitializers(){const t=Gh(this),e=oo(void 0);try{const r=this.get(vu,Qi,xi.Self);for(const s of r)s()}finally{Gh(t),oo(e)}}toString(){const t=[],e=this.records;for(const i of e.keys())t.push(dt(i));return`R3Injector[${t.join(", ")}]`}assertNotDestroyed(){if(this._destroyed)throw new F(205,!1)}processProvider(t){let e=Gc(t=vt(t))?t:vt(t&&t.provide);const i=function vj(n){return I1(n)?yu(void 0,n.useValue):yu(ZA(n),Zm)}(t);if(!Gc(t)&&!0===t.multi){let r=this.records.get(e);r||(r=yu(void 0,Zm,!0),r.factory=()=>zb(r.multi),this.records.set(e,r)),e=t,r.multi.push(t)}this.records.set(e,i)}hydrate(t,e){return e.value===Zm&&(e.value=pj,e.value=e.factory()),"object"==typeof e.value&&e.value&&function yj(n){return null!==n&&"object"==typeof n&&"function"==typeof n.ngOnDestroy}(e.value)&&this._ngOnDestroyHooks.add(e.value),e.value}injectableDefInScope(t){if(!t.providedIn)return!1;const e=vt(t.providedIn);return"string"==typeof e?"any"===e||this.scopes.has(e):this.injectorDefTypes.has(e)}removeOnDestroy(t){const e=this._onDestroyHooks.indexOf(t);-1!==e&&this._onDestroyHooks.splice(e,1)}}function w1(n){const t=Cm(n),e=null!==t?t.factory:Vc(n);if(null!==e)return e;if(n instanceof Ht)throw new F(204,!1);if(n instanceof Function)return function gj(n){if(n.length>0)throw new F(204,!1);const e=function C_(n){return n&&(n[Dm]||n[zT])||null}(n);return null!==e?()=>e.factory(n):()=>new n}(n);throw new F(204,!1)}function ZA(n,t,e){let i;if(Gc(n)){const r=vt(n);return Vc(r)||w1(r)}if(I1(n))i=()=>vt(n.useValue);else if(function $A(n){return!(!n||!n.useFactory)}(n))i=()=>n.useFactory(...zb(n.deps||[]));else if(function qA(n){return!(!n||!n.useExisting)}(n))i=()=>_i(vt(n.useExisting));else{const r=vt(n&&(n.useClass||n.provide));if(!function mj(n){return!!n.deps}(n))return Vc(r)||w1(r);i=()=>new r(...zb(n.deps))}return i}function yu(n,t,e=!1){return{factory:n,value:t,multi:e?[]:void 0}}function C1(n,t){for(const e of n)Array.isArray(e)?C1(e,t):e&&$l(e)?C1(e.\u0275providers,t):t(e)}function tL(n,t=null,e=null,i){const r=function iL(n,t=null,e=null,i,r=new Set){const s=[e||Qi,dj(n)];return i=i||("object"==typeof n?void 0:dt(n)),new mu(s,t||Jm(),i||null,r)}(n,t,e,i);return r.resolveInjectorInitializers(),r}let x1,Wo=(()=>{class n{static{this.THROW_IF_NOT_FOUND=vp}static{this.NULL=new qm}static create(e,i){if(Array.isArray(e))return tL({name:""},i,e,"");{const r=e.name??"";return tL({name:r},e.parent,e.providers,r)}}static{this.\u0275prov=Yi({token:n,providedIn:"any",factory:()=>_i(QA)})}static{this.__NG_ELEMENT_ID__=-1}}return n})();const T1=new Ht("",{providedIn:"root",factory:()=>Tj}),Tj="ng",nL=new Ht(""),Su=new Ht("",{providedIn:"platform",factory:()=>"unknown"}),sL=new Ht("",{providedIn:"root",factory:()=>function Zh(){if(void 0!==x1)return x1;if(typeof document<"u")return document;throw new F(210,!1)}().body?.querySelector("[ngCspNonce]")?.getAttribute("ngCspNonce")||null});function ry(n){return 128==(128&n.flags)}var ec=function(n){return n[n.Important=1]="Important",n[n.DashCase=2]="DashCase",n}(ec||{});const k1=new Map;let Uj=0;const z1="__ngContext__";function Rs(n,t){ks(t)?(n[z1]=t[bp],function Vj(n){k1.set(n[bp],n)}(t)):n[z1]=t}let R1;function H1(n,t){return R1(n,t)}function bu(n,t,e,i,r){if(null!=i){let s,o=!1;Ps(i)?s=i:ks(i)&&(o=!0,i=i[Vr]);const a=fr(i);0===n&&null!==e?null==r?xL(t,e,a):qc(t,e,a,r||null,!0):1===n&&null!==e?qc(t,e,a,r||null,!0):2===n?function cy(n,t,e){const i=ly(n,t);i&&function s6(n,t,e,i){n.removeChild(t,e,i)}(n,i,t,e)}(t,a,o):3===n&&t.destroyNode(a),null!=s&&function l6(n,t,e,i,r){const s=e[sl];s!==fr(e)&&bu(t,n,i,s,r);for(let a=mn;a0&&(n[e-1][wa]=i[wa]);const s=Ym(n,mn+t);!function Jj(n,t){CL(n,t),t[Vr]=null,t[Os]=null}(i[Be],i);const o=s[nl];null!==o&&o.detachView(s[Be]),i[vn]=null,i[wa]=null,i[Ct]&=-129}return i}function ay(n,t){if(!(256&t[Ct])){const e=t[Yt];e.destroyNode&&dy(n,t,e,3,null,null),function e6(n){let t=n[Sp];if(!t)return F1(n[Be],n);for(;t;){let e=null;if(ks(t))e=t[Sp];else{const i=t[mn];i&&(e=i)}if(!e){for(;t&&!t[wa]&&t!==n;)ks(t)&&F1(t[Be],t),t=t[vn];null===t&&(t=n),ks(t)&&F1(t[Be],t),e=t&&t[wa]}t=e}}(t)}}function F1(n,t){if(!(256&t[Ct])){t[Ct]&=-129,t[Ct]|=256,t[Uc]&&function Qd(n){if(Gl(n),Wh(n))for(let t=0;t=0?i[o]():i[-o].unsubscribe(),s+=2}else e[s].call(i[e[s+1]]);null!==i&&(t[Kd]=null);const r=t[qh];if(null!==r){t[qh]=null;for(let s=0;s-1){const{encapsulation:s}=n.data[i.directiveStart+r];if(s===ba.None||s===ba.Emulated)return null}return qs(i,e)}}(n,t.parent,e)}function qc(n,t,e,i,r){n.insertBefore(t,e,i,r)}function xL(n,t,e){n.appendChild(t,e)}function TL(n,t,e,i,r){null!==i?qc(n,t,e,i,r):xL(n,t,e)}function ly(n,t){return n.parentNode(t)}let U1,NL=function LL(n,t,e){return 40&n.type?qs(n,e):null};function hy(n,t,e,i){const r=_1(n,i,t),s=t[Yt],a=function AL(n,t,e){return NL(n,t,e)}(i.parent||t[Os],i,t);if(null!=r)if(Array.isArray(e))for(let l=0;lnull;function rM(n,t,e=!1){return ZL(n,t,e)}class Y6{}class iN{}class G6{resolveComponentFactory(t){throw function Q6(n){const t=Error(`No component factory found for ${dt(n)}.`);return t.ngComponent=n,t}(t)}}let Iy=(()=>{class n{static{this.NULL=new G6}}return n})();function X6(){return xu(pr(),Se())}function xu(n,t){return new $c(qs(n,t))}let $c=(()=>{class n{constructor(e){this.nativeElement=e}static{this.__NG_ELEMENT_ID__=X6}}return n})();function q6(n){return n instanceof $c?n.nativeElement:n}class nN{}let aM=(()=>{class n{constructor(){this.destroyNode=null}static{this.__NG_ELEMENT_ID__=()=>function $6(){const n=Se(),e=To(pr().index,n);return(ks(e)?e:n)[Yt]}()}}return n})(),Z6=(()=>{class n{static{this.\u0275prov=Yi({token:n,providedIn:"root",factory:()=>null})}}return n})();const lM={};function Wp(n,t,e,i,r=!1){for(;null!==e;){const s=t[e.index];null!==s&&i.push(fr(s)),Ps(s)&&uN(s,i);const o=e.type;if(8&o)Wp(n,t,e.child,i);else if(32&o){const a=H1(e,t);let l;for(;l=a();)i.push(l)}else if(16&o){const a=kL(t,e);if(Array.isArray(a))i.push(...a);else{const l=Wc(t[Jr]);Wp(l[Be],l,a,i,!0)}}e=r?e.projectionNext:e.next}return i}function uN(n,t){for(let e=mn;e!1,producerRecomputeValue:()=>{},consumerMarkedDirty:()=>{},consumerOnSignalRead:()=>{},consumerIsAlwaysLive:!0,consumerMarkedDirty:n=>{Ep(n.lView)},consumerOnSignalRead(){this.lView[Uc]=this}};function pN(n){return vN(n[Sp])}function gN(n){return vN(n[wa])}function vN(n){for(;null!==n&&!Ps(n);)n=n[wa];return n}function dM(n){return n.ngOriginalError}class nh{constructor(){this._console=console}handleError(t){const e=this._findOriginalError(t);this._console.error("ERROR",t),e&&this._console.error("ORIGINAL ERROR",e)}_findOriginalError(t){let e=t&&dM(t);for(;e&&dM(e);)e=dM(e);return e||null}}const yN=new Ht("",{providedIn:"root",factory:()=>Hi(nh).handleError.bind(void 0)}),IN=new Ht("",{providedIn:"root",factory:()=>!1}),Qt={};function EN(n,t,e,i){if(!i)if(3==(3&t[Ct])){const s=n.preOrderCheckHooks;null!==s&&Fm(t,s,e)}else{const s=n.preOrderHooks;null!==s&&_m(t,s,0,e)}Yc(e)}function Ot(n,t=xi.Default){const e=Se();return null===e?_i(n,t):PA(pr(),e,vt(n),t)}function DN(n,t,e,i,r,s){const o=Wi(null);try{let a=null;r&Xh.SignalBased&&(a=t[i][Ts]),null!==a&&void 0!==a.transformFn&&(s=a.transformFn(s)),r&Xh.HasDecoratorInputTransform&&(s=n.inputTransforms[i].call(t,s)),null!==n.setInput?n.setInput(t,a,s,e,i):rA(t,a,i,s)}finally{Wi(o)}}function Cy(n,t,e,i,r,s,o,a,l,h,c){const d=t.blueprint.slice();return d[Vr]=r,d[Ct]=204|i,(null!==h||n&&2048&n[Ct])&&(d[Ct]|=2048),cA(d),d[vn]=d[eu]=n,d[Er]=e,d[Kl]=o||n&&n[Kl],d[Yt]=a||n&&n[Yt],d[Xs]=l||n&&n[Xs]||null,d[Os]=s,d[bp]=function jj(){return Uj++}(),d[Ca]=c,d[KT]=h,d[Jr]=2==t.type?n[Jr]:d,d}function Tu(n,t,e,i,r){let s=n.data[t];if(null===s)s=function uM(n,t,e,i,r){const s=gA(),o=qb(),l=n.data[t]=function TV(n,t,e,i,r,s){let o=t?t.injectorIndex:-1,a=0;return function nu(){return null!==Rt.skipHydrationRootTNode}()&&(a|=128),{type:e,index:i,insertBeforeIndex:null,injectorIndex:o,directiveStart:-1,directiveEnd:-1,directiveStylingLast:-1,componentOffset:-1,propertyBindings:null,flags:a,providerIndexes:0,value:r,attrs:s,mergedAttrs:null,localNames:null,initialInputs:void 0,inputs:null,outputs:null,tView:null,next:null,prev:null,projectionNext:null,child:null,parent:t,projection:null,styles:null,stylesWithoutHost:null,residualStyles:void 0,classes:null,classesWithoutHost:null,residualClasses:void 0,classBindings:0,styleBindings:0}}(0,o?s:s&&s.parent,e,t,i,r);return null===n.firstChild&&(n.firstChild=l),null!==s&&(o?null==s.child&&null!==l.parent&&(s.child=l):null===s.next&&(s.next=l,l.prev=s)),l}(n,t,e,i,r),function IU(){return Rt.lFrame.inI18n}()&&(s.flags|=32);else if(64&s.type){s.type=e,s.value=i,s.attrs=r;const o=function Dp(){const n=Rt.lFrame,t=n.currentTNode;return n.isParent?t:t.parent}();s.injectorIndex=null===o?-1:o.injectorIndex}return ll(s,!0),s}function Yp(n,t,e,i){if(0===e)return-1;const r=t.length;for(let s=0;sjt&&EN(n,t,jt,!1),ol(o?2:0,r),e(i,r)}finally{Yc(s),ol(o?3:1,r)}}function fM(n,t,e){if(_b(t)){const i=Wi(null);try{const s=t.directiveEnd;for(let o=t.directiveStart;onull;function LN(n,t,e,i,r){for(let s in t){if(!t.hasOwnProperty(s))continue;const o=t[s];if(void 0===o)continue;i??={};let a,l=Xh.None;Array.isArray(o)?(a=o[0],l=o[1]):a=o;let h=s;if(null!==r){if(!r.hasOwnProperty(s))continue;h=r[s]}0===n?NN(i,e,h,a,l):NN(i,e,h,a)}return i}function NN(n,t,e,i,r){let s;n.hasOwnProperty(e)?(s=n[e]).push(t,i):s=n[e]=[t,i],void 0!==r&&s.push(r)}function ON(n,t,e,i,r,s){for(let h=0;h0;){const e=n[--t];if("number"==typeof e&&e<0)return e}return 0})(o)!=a&&o.push(a),o.push(e,i,s)}}(n,t,i,Yp(n,e,r.hostVars,Qt),r)}function VV(n,t,e,i,r,s){const o=s[t];if(null!==o)for(let a=0;an.nextProducerIndex;)n.producerNode.pop(),n.producerLastReadVersion.pop(),n.producerIndexOfThis.pop()}}(a,o),function dV(n){n.lView[Uc]!==n&&(n.lView=null,fN.push(n))}(a)),t1()}}function FN(n,t){for(let e=pN(n);null!==e;e=gN(e))for(let i=mn;i-1&&(Rp(t,i),Ym(e,i))}this._attachedToViewContainer=!1}ay(this._lView[Be],this._lView)}onDestroy(t){!function Rm(n,t){if(256==(256&n[Ct]))throw new F(911,!1);null===n[qh]&&(n[qh]=[]),n[qh].push(t)}(this._lView,t)}markForCheck(){Qp(this._cdRefInjectingView||this._lView)}detach(){this._lView[Ct]&=-129}reattach(){Gb(this._lView),this._lView[Ct]|=128}detectChanges(){this._lView[Ct]|=1024,function MM(n,t=!0){const e=n[Kl],i=e.rendererFactory;i.begin?.();try{!function QV(n){wM(n,0);let t=0;for(;uA(n);){if(100===t)throw new F(103,!1);t++,wM(n,1)}}(n)}catch(s){throw t&&Dy(n,s),s}finally{i.end?.(),e.inlineEffectRunner?.flush()}}(this._lView,this.notifyErrorHandler)}checkNoChanges(){}attachToViewContainerRef(){if(this._appRef)throw new F(902,!1);this._attachedToViewContainer=!0}detachFromAppRef(){this._appRef=null,CL(this._lView[Be],this._lView)}attachToAppRef(t){if(this._attachedToViewContainer)throw new F(902,!1);this._appRef=t,Gb(this._lView)}}const VN=new Set;function EM(n){return t=>{setTimeout(n,void 0,t)}}const Yo=class a7 extends Pt{constructor(t=!1){super(),this.__isAsync=t}emit(t){super.next(t)}subscribe(t,e,i){let r=t,s=e||(()=>null),o=i;if(t&&"object"==typeof t){const l=t;r=l.next?.bind(l),s=l.error?.bind(l),o=l.complete?.bind(l)}this.__isAsync&&(s=EM(s),r&&(r=EM(r)),o&&(o=EM(o)));const a=super.subscribe({next:r,error:s,complete:o});return t instanceof As&&t.add(a),a}};function WN(...n){}class Rr{constructor({enableLongStackTrace:t=!1,shouldCoalesceEventChangeDetection:e=!1,shouldCoalesceRunChangeDetection:i=!1}){if(this.hasPendingMacrotasks=!1,this.hasPendingMicrotasks=!1,this.isStable=!0,this.onUnstable=new Yo(!1),this.onMicrotaskEmpty=new Yo(!1),this.onStable=new Yo(!1),this.onError=new Yo(!1),typeof Zone>"u")throw new F(908,!1);Zone.assertZonePatched();const r=this;r._nesting=0,r._outer=r._inner=Zone.current,Zone.TaskTrackingZoneSpec&&(r._inner=r._inner.fork(new Zone.TaskTrackingZoneSpec)),t&&Zone.longStackTraceZoneSpec&&(r._inner=r._inner.fork(Zone.longStackTraceZoneSpec)),r.shouldCoalesceEventChangeDetection=!i&&e,r.shouldCoalesceRunChangeDetection=i,r.lastRequestAnimationFrameId=-1,r.nativeRequestAnimationFrame=function l7(){const n="function"==typeof rr.requestAnimationFrame;let t=rr[n?"requestAnimationFrame":"setTimeout"],e=rr[n?"cancelAnimationFrame":"clearTimeout"];if(typeof Zone<"u"&&t&&e){const i=t[Zone.__symbol__("OriginalDelegate")];i&&(t=i);const r=e[Zone.__symbol__("OriginalDelegate")];r&&(e=r)}return{nativeRequestAnimationFrame:t,nativeCancelAnimationFrame:e}}().nativeRequestAnimationFrame,function d7(n){const t=()=>{!function c7(n){n.isCheckStableRunning||-1!==n.lastRequestAnimationFrameId||(n.lastRequestAnimationFrameId=n.nativeRequestAnimationFrame.call(rr,()=>{n.fakeTopEventTask||(n.fakeTopEventTask=Zone.root.scheduleEventTask("fakeTopEventTask",()=>{n.lastRequestAnimationFrameId=-1,xM(n),n.isCheckStableRunning=!0,DM(n),n.isCheckStableRunning=!1},void 0,()=>{},()=>{})),n.fakeTopEventTask.invoke()}),xM(n))}(n)};n._inner=n._inner.fork({name:"angular",properties:{isAngularZone:!0},onInvokeTask:(e,i,r,s,o,a)=>{if(function u7(n){return!(!Array.isArray(n)||1!==n.length)&&!0===n[0].data?.__ignore_ng_zone__}(a))return e.invokeTask(r,s,o,a);try{return YN(n),e.invokeTask(r,s,o,a)}finally{(n.shouldCoalesceEventChangeDetection&&"eventTask"===s.type||n.shouldCoalesceRunChangeDetection)&&t(),QN(n)}},onInvoke:(e,i,r,s,o,a,l)=>{try{return YN(n),e.invoke(r,s,o,a,l)}finally{n.shouldCoalesceRunChangeDetection&&t(),QN(n)}},onHasTask:(e,i,r,s)=>{e.hasTask(r,s),i===r&&("microTask"==s.change?(n._hasPendingMicrotasks=s.microTask,xM(n),DM(n)):"macroTask"==s.change&&(n.hasPendingMacrotasks=s.macroTask))},onHandleError:(e,i,r,s)=>(e.handleError(r,s),n.runOutsideAngular(()=>n.onError.emit(s)),!1)})}(r)}static isInAngularZone(){return typeof Zone<"u"&&!0===Zone.current.get("isAngularZone")}static assertInAngularZone(){if(!Rr.isInAngularZone())throw new F(909,!1)}static assertNotInAngularZone(){if(Rr.isInAngularZone())throw new F(909,!1)}run(t,e,i){return this._inner.run(t,e,i)}runTask(t,e,i,r){const s=this._inner,o=s.scheduleEventTask("NgZoneEvent: "+r,t,h7,WN,WN);try{return s.runTask(o,e,i)}finally{s.cancelTask(o)}}runGuarded(t,e,i){return this._inner.runGuarded(t,e,i)}runOutsideAngular(t){return this._outer.run(t)}}const h7={};function DM(n){if(0==n._nesting&&!n.hasPendingMicrotasks&&!n.isStable)try{n._nesting++,n.onMicrotaskEmpty.emit(null)}finally{if(n._nesting--,!n.hasPendingMicrotasks)try{n.runOutsideAngular(()=>n.onStable.emit(null))}finally{n.isStable=!0}}}function xM(n){n.hasPendingMicrotasks=!!(n._hasPendingMicrotasks||(n.shouldCoalesceEventChangeDetection||n.shouldCoalesceRunChangeDetection)&&-1!==n.lastRequestAnimationFrameId)}function YN(n){n._nesting++,n.isStable&&(n.isStable=!1,n.onUnstable.emit(null))}function QN(n){n._nesting--,DM(n)}let Xp=(()=>{class n{constructor(){this.handler=null,this.internalCallbacks=[]}execute(){const e=[...this.internalCallbacks];this.internalCallbacks.length=0;for(const r of e)r();return!!this.handler?.execute()||e.length>0}ngOnDestroy(){this.handler?.destroy(),this.handler=null,this.internalCallbacks.length=0}static{this.\u0275prov=Yi({token:n,providedIn:"root",factory:()=>new n})}}return n})();function v7(n,t){const e=To(t,n),i=e[Be];!function m7(n,t){for(let e=t.length;e0&&RL(n,e,s.join(" "))}}(u,w,p,i),void 0!==e&&function x7(n,t,e){const i=n.projection=[];for(let r=0;r=0;i--){const r=n[i];r.hostVars=t+=r.hostVars,r.hostAttrs=yp(r.hostAttrs,e=yp(e,r.hostAttrs))}}(i)}function A7(n,t){for(const e in t.inputs){if(!t.inputs.hasOwnProperty(e)||n.inputs.hasOwnProperty(e))continue;const i=t.inputs[e];if(void 0!==i&&(n.inputs[e]=i,n.declaredInputs[e]=t.declaredInputs[e],null!==t.inputTransforms)){const r=Array.isArray(i)?i[0]:i;if(!t.inputTransforms.hasOwnProperty(r))continue;n.inputTransforms??={},n.inputTransforms[r]=t.inputTransforms[r]}}}function Ty(n){return n===rl?{}:n===Qi?[]:n}function N7(n,t){const e=n.viewQuery;n.viewQuery=e?(i,r)=>{t(i,r),e(i,r)}:t}function O7(n,t){const e=n.contentQueries;n.contentQueries=e?(i,r,s)=>{t(i,r,s),e(i,r,s)}:t}function k7(n,t){const e=n.hostBindings;n.hostBindings=e?(i,r)=>{t(i,r),e(i,r)}:t}function Lu(n,t){return!t||null===t.firstChild||ry(n)}function tg(n,t,e,i=!0){const r=t[Be];if(function t6(n,t,e,i){const r=mn+i,s=e.length;i>0&&(e[r-1][wa]=t),i{class n{static{this.__NG_ELEMENT_ID__=a9}}return n})();function a9(){return fO(pr(),Se())}const l9=An,dO=class extends l9{constructor(t,e,i){super(),this._lContainer=t,this._hostTNode=e,this._hostLView=i}get element(){return xu(this._hostTNode,this._hostLView)}get injector(){return new Yn(this._hostTNode,this._hostLView)}get parentInjector(){const t=Vm(this._hostTNode,this._hostLView);if(n1(t)){const e=Ap(t,this._hostLView),i=Tp(t);return new Yn(e[Be].data[i+8],e)}return new Yn(null,this._hostLView)}clear(){for(;this.length>0;)this.remove(this.length-1)}get(t){const e=uO(this._lContainer);return null!==e&&e[t]||null}get length(){return this._lContainer.length-mn}createEmbeddedView(t,e,i){let r,s;"number"==typeof i?r=i:null!=i&&(r=i.index,s=i.injector);const a=t.createEmbeddedViewImpl(e||{},s,null);return this.insertImpl(a,r,Lu(this._hostTNode,null)),a}createComponent(t,e,i,r,s){const o=t&&!function Lp(n){return"function"==typeof n}(t);let a;if(o)a=e;else{const p=e||{};a=p.index,i=p.injector,r=p.projectableNodes,s=p.environmentInjector||p.ngModuleRef}const l=o?t:new qp(di(t)),h=i||this.parentInjector;if(!s&&null==l.ngModule){const g=(o?h:this.parentInjector).get(ih,null);g&&(s=g)}di(l.componentType??{});const f=l.create(h,r,null,s);return this.insertImpl(f.hostView,a,Lu(this._hostTNode,null)),f}insert(t,e){return this.insertImpl(t,e,!0)}insertImpl(t,e,i){const r=t._lView;if(function aU(n){return Ps(n[vn])}(r)){const a=this.indexOf(t);if(-1!==a)this.detach(a);else{const l=r[vn],h=new dO(l,l[Os],l[vn]);h.detach(h.indexOf(t))}}const s=this._adjustIndex(e),o=this._lContainer;return tg(o,r,s,i),t.attachToViewContainerRef(),_A(zM(o),s,t),t}move(t,e){return this.insert(t,e)}indexOf(t){const e=uO(this._lContainer);return null!==e?e.indexOf(t):-1}remove(t){const e=this._adjustIndex(t,-1),i=Rp(this._lContainer,e);i&&(Ym(zM(this._lContainer),e),ay(i[Be],i))}detach(t){const e=this._adjustIndex(t,-1),i=Rp(this._lContainer,e);return i&&null!=Ym(zM(this._lContainer),e)?new Gp(i):null}_adjustIndex(t,e=0){return t??this.length+e}};function uO(n){return n[8]}function zM(n){return n[8]||(n[8]=[])}function fO(n,t){let e;const i=t[n.index];return Ps(i)?e=i:(e=function PN(n,t,e,i){return[n,!0,0,t,null,i,null,e,null,null]}(i,t,null,n),t[n.index]=e,Ey(t,e)),pO(e,t,n,i),new dO(e,n,t)}let pO=function vO(n,t,e,i){if(n[sl])return;let r;r=8&e.type?fr(i):function h9(n,t){const e=n[Yt],i=e.createComment(""),r=qs(t,n);return qc(e,ly(e,r),i,function o6(n,t){return n.nextSibling(t)}(e,r),!1),i}(t,e),n[sl]=r};function XM(n,t,e){const i=Se();return function Ln(n,t,e){return!Object.is(n[t],e)&&(n[t]=e,!0)}(i,function hl(){return Rt.lFrame.bindingIndex++}(),t)&&function No(n,t,e,i,r,s,o,a){const l=qs(t,e);let c,h=t.inputs;!a&&null!=h&&(c=h[i])?(bM(n,e,c,i,r),jc(t)&&function NV(n,t){const e=To(t,n);16&e[Ct]||(e[Ct]|=64)}(e,t.index)):3&t.type&&(i=function LV(n){return"class"===n?"className":"for"===n?"htmlFor":"formaction"===n?"formAction":"innerHtml"===n?"innerHTML":"readonly"===n?"readOnly":"tabindex"===n?"tabIndex":n}(i),r=null!=o?o(r,t.value||"",i):r,s.setProperty(l,i,r))}(Ti(),function zr(){const n=Rt.lFrame;return Cp(n.tView,n.selectedIndex)}(),i,n,t,i[Yt],e,!1),XM}function qM(n,t,e,i,r){const o=r?"class":"style";bM(n,e,t.inputs[o],o,i)}function lg(n,t,e,i){const r=Se(),s=Ti(),o=jt+n,a=r[Yt],l=s.firstCreatePass?function R8(n,t,e,i,r,s){const o=t.consts,l=Tu(t,n,2,i,al(o,r));return function mM(n,t,e,i){if(pA()){const r=null===i?null:{"":-1},s=function HV(n,t){const e=n.directiveRegistry;let i=null,r=null;if(e)for(let s=0;s($h(!0),oy(i,r,function EA(){return Rt.lFrame.currentNamespace}()));const Xu="en-US";let Mk=Xu;function ow(n){return!!n&&"function"==typeof n.then}function Gk(n){return!!n&&"function"==typeof n.subscribe}function aw(n,t,e,i){const r=Se(),s=Ti(),o=pr();return function qk(n,t,e,i,r,s,o){const a=Pm(i),h=n.firstCreatePass&&HN(n),c=t[Er],d=RN(t);let u=!0;if(3&i.type||o){const g=qs(i,t),v=o?o(g):g,y=d.length,S=o?M=>o(fr(M[i.index])):i.index;let b=null;if(!o&&a&&(b=function FW(n,t,e,i){const r=n.cleanup;if(null!=r)for(let s=0;sl?a[l]:null}"string"==typeof o&&(s+=2)}return null}(n,t,r,i.index)),null!==b)(b.__ngLastListenerFn__||b).__ngNextListenerFn__=s,b.__ngLastListenerFn__=s,u=!1;else{s=Zk(i,t,c,s,!1);const M=e.listen(v,r,s);d.push(s,M),h&&h.push(r,S,y,y+1)}}else s=Zk(i,t,c,s,!1);const f=i.outputs;let p;if(u&&null!==f&&(p=f[r])){const g=p.length;if(g)for(let v=0;v-1?To(n.index,t):t);let l=$k(t,e,i,o),h=s.__ngNextListenerFn__;for(;h;)l=$k(t,e,h,o)&&l,h=h.__ngNextListenerFn__;return r&&!1===l&&o.preventDefault(),l}}function WW(){return this._results[Symbol.iterator]()}class hw{get changes(){return this._changes??=new Yo}constructor(t=!1){this._emitDistinctChangesOnly=t,this.dirty=!0,this._results=[],this._changesDetected=!1,this._changes=void 0,this.length=0,this.first=void 0,this.last=void 0;const e=hw.prototype;e[Symbol.iterator]||(e[Symbol.iterator]=WW)}get(t){return this._results[t]}map(t){return this._results.map(t)}filter(t){return this._results.filter(t)}find(t){return this._results.find(t)}reduce(t,e){return this._results.reduce(t,e)}forEach(t){this._results.forEach(t)}some(t){return this._results.some(t)}toArray(){return this._results.slice()}toString(){return this._results.toString()}reset(t,e){this.dirty=!1;const i=function lo(n){return n.flat(Number.POSITIVE_INFINITY)}(t);(this._changesDetected=!function XU(n,t,e){if(n.length!==t.length)return!1;for(let i=0;i{class n{static{this.__NG_ELEMENT_ID__=GW}}return n})();const YW=oh,QW=class extends YW{constructor(t,e,i){super(),this._declarationLView=t,this._declarationTContainer=e,this.elementRef=i}get ssrId(){return this._declarationTContainer.tView?.ssrId||null}createEmbeddedView(t,e){return this.createEmbeddedViewImpl(t,e)}createEmbeddedViewImpl(t,e,i){const r=function eg(n,t,e,i){const r=t.tView,a=Cy(n,r,e,4096&n[Ct]?4096:16,null,t,null,null,null,i?.injector??null,i?.dehydratedView??null);a[Ip]=n[t.index];const h=n[nl];return null!==h&&(a[nl]=h.createEmbeddedView(r)),TM(r,a,e),a}(this._declarationLView,this._declarationTContainer,t,{injector:e,dehydratedView:i});return new Gp(r)}};function GW(){return Yy(pr(),Se())}function Yy(n,t){return 4&n.type?new QW(t,n,xu(n,t)):null}class cw{constructor(t){this.queryList=t,this.matches=null}clone(){return new cw(this.queryList)}setDirty(){this.queryList.setDirty()}}class dw{constructor(t=[]){this.queries=t}createEmbeddedView(t){const e=t.queries;if(null!==e){const i=null!==t.contentQueries?t.contentQueries[0]:e.length,r=[];for(let s=0;s0)i.push(o[a/2]);else{const h=s[a+1],c=t[-l];for(let d=mn;d($h(!0),function sy(n,t){return n.createText(t)}(t[Yt],i));function vw(n,t,e,i,r){if(n=vt(n),Array.isArray(n))for(let s=0;s>20;if(Gc(n)||!n.multi){const f=new xp(h,r,Ot),p=yw(l,t,r?c:c+u,d);-1===p?(a1(jm(a,o),s,l),mw(s,n,t.length),t.push(l),a.directiveStart++,a.directiveEnd++,r&&(a.providerIndexes+=1048576),e.push(f),o.push(f)):(e[p]=f,o[p]=f)}else{const f=yw(l,t,c+u,d),p=yw(l,t,c,c+u),v=p>=0&&e[p];if(r&&!v||!r&&!(f>=0&&e[f])){a1(jm(a,o),s,l);const y=function vY(n,t,e,i,r){const s=new xp(n,e,Ot);return s.multi=[],s.index=t,s.componentProviders=0,kP(s,r,i&&!e),s}(r?gY:pY,e.length,r,i,h);!r&&v&&(e[p].providerFactory=y),mw(s,n,t.length,0),t.push(l),a.directiveStart++,a.directiveEnd++,r&&(a.providerIndexes+=1048576),e.push(y),o.push(y)}else mw(s,n,f>-1?f:p,kP(e[r?p:f],h,!r&&i));!r&&i&&v&&e[p].componentProviders++}}}function mw(n,t,e,i){const r=Gc(t),s=function fj(n){return!!n.useClass}(t);if(r||s){const l=(s?vt(t.useClass):t).prototype.ngOnDestroy;if(l){const h=n.destroyHooks||(n.destroyHooks=[]);if(!r&&t.multi){const c=h.indexOf(e);-1===c?h.push(e,[i,l]):h[c+1].push(i,l)}else h.push(e,l)}}}function kP(n,t,e){return e&&n.componentProviders++,n.multi.push(t)-1}function yw(n,t,e,i){for(let r=e;r{e.providersResolver=(i,r)=>function fY(n,t,e){const i=Ti();if(i.firstCreatePass){const r=Ea(n);vw(e,i.data,i.blueprint,r,!0),vw(t,i.data,i.blueprint,r,!1)}}(i,r?r(n):n,t)}}class rd{}class zP extends rd{constructor(t){super(),this.componentFactoryResolver=new JN(this),this.instance=null;const e=new mu([...t.providers,{provide:rd,useValue:this},{provide:Iy,useValue:this.componentFactoryResolver}],t.parent||Jm(),t.debugName,new Set(["environment"]));this.injector=e,t.runEnvironmentInitializers&&e.resolveInjectorInitializers()}destroy(){this.injector.destroy()}onDestroy(t){this.injector.onDestroy(t)}}let bY=(()=>{class n{constructor(e){this._injector=e,this.cachedInjectors=new Map}getOrCreateStandaloneInjector(e){if(!e.standalone)return null;if(!this.cachedInjectors.has(e)){const i=GA(0,e.type),r=i.length>0?function IY(n,t,e=null){return new zP({providers:n,parent:t,debugName:e,runEnvironmentInitializers:!0}).injector}([i],this._injector,`Standalone[${e.type.name}]`):null;this.cachedInjectors.set(e,r)}return this.cachedInjectors.get(e)}ngOnDestroy(){try{for(const e of this.cachedInjectors.values())null!==e&&e.destroy()}finally{this.cachedInjectors.clear()}}static{this.\u0275prov=Yi({token:n,providedIn:"environment",factory:()=>new n(_i(ih))})}}return n})();function RP(n){(function Zc(n){VN.has(n)||(VN.add(n),performance?.mark?.("mark_feature_usage",{detail:{feature:n}}))})("NgStandalone"),n.getStandaloneInjector=t=>t.get(bY).getOrCreateStandaloneInjector(n)}let Tw=(()=>{class n{constructor(){this.taskId=0,this.pendingTasks=new Set,this.hasPendingTasks=new _o(!1)}get _hasPendingTasks(){return this.hasPendingTasks.value}add(){this._hasPendingTasks||this.hasPendingTasks.next(!0);const e=this.taskId++;return this.pendingTasks.add(e),e}remove(e){this.pendingTasks.delete(e),0===this.pendingTasks.size&&this._hasPendingTasks&&this.hasPendingTasks.next(!1)}ngOnDestroy(){this.pendingTasks.clear(),this._hasPendingTasks&&this.hasPendingTasks.next(!1)}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();const g2=new Ht(""),QQ=new Ht("");let kw=(()=>{class n{constructor(){this.initialized=!1,this.done=!1,this.donePromise=new Promise((e,i)=>{this.resolve=e,this.reject=i}),this.appInits=Hi(QQ,{optional:!0})??[]}runInitializers(){if(this.initialized)return;const e=[];for(const r of this.appInits){const s=r();if(ow(s))e.push(s);else if(Gk(s)){const o=new Promise((a,l)=>{s.subscribe({complete:a,error:l})});e.push(o)}}const i=()=>{this.done=!0,this.resolve()};Promise.all(e).then(()=>{i()}).catch(r=>{this.reject(r)}),0===e.length&&i(),this.initialized=!0}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();const v2=new Ht("");let Zu=(()=>{class n{constructor(){this._bootstrapListeners=[],this._runningTick=!1,this._destroyed=!1,this._destroyListeners=[],this._views=[],this.internalErrorHandler=Hi(yN),this.afterRenderEffectManager=Hi(Xp),this.componentTypes=[],this.components=[],this.isStable=Hi(Tw).hasPendingTasks.pipe(jr(e=>!e)),this._injector=Hi(ih)}get destroyed(){return this._destroyed}get injector(){return this._injector}bootstrap(e,i){const r=e instanceof iN;if(!this._injector.get(kw).done)throw!r&&function _c(n){const t=di(n)||Wn(n)||gs(n);return null!==t&&t.standalone}(e),new F(405,!1);let o;o=r?e:this._injector.get(Iy).resolveComponentFactory(e),this.componentTypes.push(o.componentType);const a=function XQ(n){return n.isBoundToModule}(o)?void 0:this._injector.get(rd),h=o.create(Wo.NULL,[],i||o.selector,a),c=h.location.nativeElement,d=h.injector.get(g2,null);return d?.registerApplication(c),h.onDestroy(()=>{this.detachView(h.hostView),Zy(this.components,h),d?.unregisterApplication(c)}),this._loadComponent(h),h}tick(){if(this._runningTick)throw new F(101,!1);try{this._runningTick=!0;for(let e of this._views)e.detectChanges()}catch(e){this.internalErrorHandler(e)}finally{try{this.afterRenderEffectManager.execute()}catch(e){this.internalErrorHandler(e)}this._runningTick=!1}}attachView(e){const i=e;this._views.push(i),i.attachToAppRef(this)}detachView(e){const i=e;Zy(this._views,i),i.detachFromAppRef()}_loadComponent(e){this.attachView(e.hostView),this.tick(),this.components.push(e);const i=this._injector.get(v2,[]);[...this._bootstrapListeners,...i].forEach(r=>r(e))}ngOnDestroy(){if(!this._destroyed)try{this._destroyListeners.forEach(e=>e()),this._views.slice().forEach(e=>e.destroy())}finally{this._destroyed=!0,this._views=[],this._bootstrapListeners=[],this._destroyListeners=[]}}onDestroy(e){return this._destroyListeners.push(e),()=>Zy(this._destroyListeners,e)}destroy(){if(this._destroyed)throw new F(406,!1);const e=this._injector;e.destroy&&!e.destroyed&&e.destroy()}get viewCount(){return this._views.length}warnIfDestroyed(){}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();function Zy(n,t){const e=n.indexOf(t);e>-1&&n.splice(e,1)}let $Q=(()=>{class n{constructor(){this.zone=Hi(Rr),this.applicationRef=Hi(Zu)}initialize(){this._onMicrotaskEmptySubscription||(this._onMicrotaskEmptySubscription=this.zone.onMicrotaskEmpty.subscribe({next:()=>{this.zone.run(()=>{this.applicationRef.tick()})}}))}ngOnDestroy(){this._onMicrotaskEmptySubscription?.unsubscribe()}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();function b2(n){return[{provide:Rr,useFactory:n},{provide:vu,multi:!0,useFactory:()=>{const t=Hi($Q,{optional:!0});return()=>t.initialize()}},{provide:vu,multi:!0,useFactory:()=>{const t=Hi(KQ);return()=>{t.initialize()}}},{provide:yN,useFactory:ZQ}]}function ZQ(){const n=Hi(Rr),t=Hi(nh);return e=>n.runOutsideAngular(()=>t.handleError(e))}function JQ(n){return function y1(n){return{\u0275providers:n}}([[],b2(()=>new Rr(function M2(n){return{enableLongStackTrace:!1,shouldCoalesceEventChangeDetection:n?.eventCoalescing??!1,shouldCoalesceRunChangeDetection:n?.runCoalescing??!1}}(n)))])}let KQ=(()=>{class n{constructor(){this.subscription=new As,this.initialized=!1,this.zone=Hi(Rr),this.pendingTasks=Hi(Tw)}initialize(){if(this.initialized)return;this.initialized=!0;let e=null;!this.zone.isStable&&!this.zone.hasPendingMacrotasks&&!this.zone.hasPendingMicrotasks&&(e=this.pendingTasks.add()),this.zone.runOutsideAngular(()=>{this.subscription.add(this.zone.onStable.subscribe(()=>{Rr.assertNotInAngularZone(),queueMicrotask(()=>{null!==e&&!this.zone.hasPendingMacrotasks&&!this.zone.hasPendingMicrotasks&&(this.pendingTasks.remove(e),e=null)})}))}),this.subscription.add(this.zone.onUnstable.subscribe(()=>{Rr.assertInAngularZone(),e??=this.pendingTasks.add()}))}ngOnDestroy(){this.subscription.unsubscribe()}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();const ah=new Ht("",{providedIn:"root",factory:()=>Hi(ah,xi.Optional|xi.SkipSelf)||function eG(){return typeof $localize<"u"&&$localize.locale||Xu}()}),Pw=new Ht("");let nc=null;function CG(n){try{const{rootComponent:t,appProviders:e,platformProviders:i}=n,r=function sG(n=[]){if(nc)return nc;const t=function E2(n=[],t){return Wo.create({name:t,providers:[{provide:b1,useValue:"platform"},{provide:Pw,useValue:new Set([()=>nc=null])},...n]})}(n);return nc=t,function m2(){!function Sb(n){Xd=n}(()=>{throw new F(600,!1)})}(),function D2(n){n.get(nL,null)?.forEach(e=>e())}(t),t}(i),s=[JQ(),...e||[]],a=new zP({providers:s,parent:r,debugName:"",runEnvironmentInitializers:!1}).injector,l=a.get(Rr);return l.run(()=>{a.resolveInjectorInitializers();const h=a.get(nh,null);let c;l.runOutsideAngular(()=>{c=l.onError.subscribe({next:f=>{h.handleError(f)}})});const d=()=>a.destroy(),u=r.get(Pw);return u.add(d),a.onDestroy(()=>{c.unsubscribe(),u.delete(d)}),function y2(n,t,e){try{const i=e();return ow(i)?i.catch(r=>{throw t.runOutsideAngular(()=>n.handleError(r)),r}):i}catch(i){throw t.runOutsideAngular(()=>n.handleError(i)),i}}(h,l,()=>{const f=a.get(kw);return f.runInitializers(),f.donePromise.then(()=>{!function wk(n){so(n,"Expected localeId to be defined"),"string"==typeof n&&(Mk=n.toLowerCase().replace(/_/g,"-"))}(a.get(ah,Xu)||Xu);const g=a.get(Zu);return void 0!==t&&g.bootstrap(t),g})})})}catch(t){return Promise.reject(t)}}let $2=null;function jw(){return $2}class FG{}const sd=new Ht("");let rq=(()=>{class n{static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275mod=Lm({type:n})}static{this.\u0275inj=gp({})}}return n})();function uz(n){return"server"===n}class Nq extends FG{constructor(){super(...arguments),this.supportsDOMEvents=!0}}class sC extends Nq{static makeCurrent(){!function BG(n){$2??=n}(new sC)}onAndCancel(t,e,i){return t.addEventListener(e,i),()=>{t.removeEventListener(e,i)}}dispatchEvent(t,e){t.dispatchEvent(e)}remove(t){t.parentNode&&t.parentNode.removeChild(t)}createElement(t,e){return(e=e||this.getDefaultDocument()).createElement(t)}createHtmlDocument(){return document.implementation.createHTMLDocument("fakeTitle")}getDefaultDocument(){return document}isElementNode(t){return t.nodeType===Node.ELEMENT_NODE}isShadowRoot(t){return t instanceof DocumentFragment}getGlobalEventTarget(t,e){return"window"===e?window:"document"===e?t:"body"===e?t.body:null}getBaseHref(t){const e=function Oq(){return wg=wg||document.querySelector("base"),wg?wg.getAttribute("href"):null}();return null==e?null:function kq(n){return new URL(n,document.baseURI).pathname}(e)}resetBaseElement(){wg=null}getUserAgent(){return window.navigator.userAgent}getCookie(t){return function EX(n,t){t=encodeURIComponent(t);for(const e of n.split(";")){const i=e.indexOf("="),[r,s]=-1==i?[e,""]:[e.slice(0,i),e.slice(i+1)];if(r.trim()===t)return decodeURIComponent(s)}return null}(document.cookie,t)}}let wg=null,zq=(()=>{class n{build(){return new XMLHttpRequest}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();const oC=new Ht("");let vz=(()=>{class n{constructor(e,i){this._zone=i,this._eventNameToPlugin=new Map,e.forEach(r=>{r.manager=this}),this._plugins=e.slice().reverse()}addEventListener(e,i,r){return this._findPluginFor(i).addEventListener(e,i,r)}getZone(){return this._zone}_findPluginFor(e){let i=this._eventNameToPlugin.get(e);if(i)return i;if(i=this._plugins.find(s=>s.supports(e)),!i)throw new F(5101,!1);return this._eventNameToPlugin.set(e,i),i}static{this.\u0275fac=function(i){return new(i||n)(_i(oC),_i(Rr))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();class mz{constructor(t){this._doc=t}}const aC="ng-app-id";let yz=(()=>{class n{constructor(e,i,r,s={}){this.doc=e,this.appId=i,this.nonce=r,this.platformId=s,this.styleRef=new Map,this.hostNodes=new Set,this.styleNodesInDOM=this.collectServerRenderedStyles(),this.platformIsServer=uz(s),this.resetHostNodes()}addStyles(e){for(const i of e)1===this.changeUsageCount(i,1)&&this.onStyleAdded(i)}removeStyles(e){for(const i of e)this.changeUsageCount(i,-1)<=0&&this.onStyleRemoved(i)}ngOnDestroy(){const e=this.styleNodesInDOM;e&&(e.forEach(i=>i.remove()),e.clear());for(const i of this.getAllStyles())this.onStyleRemoved(i);this.resetHostNodes()}addHost(e){this.hostNodes.add(e);for(const i of this.getAllStyles())this.addStyleToHost(e,i)}removeHost(e){this.hostNodes.delete(e)}getAllStyles(){return this.styleRef.keys()}onStyleAdded(e){for(const i of this.hostNodes)this.addStyleToHost(i,e)}onStyleRemoved(e){const i=this.styleRef;i.get(e)?.elements?.forEach(r=>r.remove()),i.delete(e)}collectServerRenderedStyles(){const e=this.doc.head?.querySelectorAll(`style[${aC}="${this.appId}"]`);if(e?.length){const i=new Map;return e.forEach(r=>{null!=r.textContent&&i.set(r.textContent,r)}),i}return null}changeUsageCount(e,i){const r=this.styleRef;if(r.has(e)){const s=r.get(e);return s.usage+=i,s.usage}return r.set(e,{usage:i,elements:[]}),i}getStyleElement(e,i){const r=this.styleNodesInDOM,s=r?.get(i);if(s?.parentNode===e)return r.delete(i),s.removeAttribute(aC),s;{const o=this.doc.createElement("style");return this.nonce&&o.setAttribute("nonce",this.nonce),o.textContent=i,this.platformIsServer&&o.setAttribute(aC,this.appId),e.appendChild(o),o}}addStyleToHost(e,i){const r=this.getStyleElement(e,i),s=this.styleRef,o=s.get(i)?.elements;o?o.push(r):s.set(i,{elements:[r],usage:1})}resetHostNodes(){const e=this.hostNodes;e.clear(),e.add(this.doc.head)}static{this.\u0275fac=function(i){return new(i||n)(_i(sd),_i(T1),_i(sL,8),_i(Su))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();const lC={svg:"http://www.w3.org/2000/svg",xhtml:"http://www.w3.org/1999/xhtml",xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/",math:"http://www.w3.org/1998/MathML/"},hC=/%COMP%/g,Fq=new Ht("",{providedIn:"root",factory:()=>!0});function Iz(n,t){return t.map(e=>e.replace(hC,n))}let bz=(()=>{class n{constructor(e,i,r,s,o,a,l,h=null){this.eventManager=e,this.sharedStylesHost=i,this.appId=r,this.removeStylesOnCompDestroy=s,this.doc=o,this.platformId=a,this.ngZone=l,this.nonce=h,this.rendererByCompId=new Map,this.platformIsServer=uz(a),this.defaultRenderer=new cC(e,o,l,this.platformIsServer)}createRenderer(e,i){if(!e||!i)return this.defaultRenderer;this.platformIsServer&&i.encapsulation===ba.ShadowDom&&(i={...i,encapsulation:ba.Emulated});const r=this.getOrCreateRenderer(e,i);return r instanceof wz?r.applyToHost(e):r instanceof dC&&r.applyStyles(),r}getOrCreateRenderer(e,i){const r=this.rendererByCompId;let s=r.get(i.id);if(!s){const o=this.doc,a=this.ngZone,l=this.eventManager,h=this.sharedStylesHost,c=this.removeStylesOnCompDestroy,d=this.platformIsServer;switch(i.encapsulation){case ba.Emulated:s=new wz(l,h,i,this.appId,c,o,a,d);break;case ba.ShadowDom:return new Vq(l,h,e,i,o,a,this.nonce,d);default:s=new dC(l,h,i,c,o,a,d)}r.set(i.id,s)}return s}ngOnDestroy(){this.rendererByCompId.clear()}static{this.\u0275fac=function(i){return new(i||n)(_i(vz),_i(yz),_i(T1),_i(Fq),_i(sd),_i(Su),_i(Rr),_i(sL))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();class cC{constructor(t,e,i,r){this.eventManager=t,this.doc=e,this.ngZone=i,this.platformIsServer=r,this.data=Object.create(null),this.throwOnSyntheticProps=!0,this.destroyNode=null}destroy(){}createElement(t,e){return e?this.doc.createElementNS(lC[e]||e,t):this.doc.createElement(t)}createComment(t){return this.doc.createComment(t)}createText(t){return this.doc.createTextNode(t)}appendChild(t,e){(Mz(t)?t.content:t).appendChild(e)}insertBefore(t,e,i){t&&(Mz(t)?t.content:t).insertBefore(e,i)}removeChild(t,e){t&&t.removeChild(e)}selectRootElement(t,e){let i="string"==typeof t?this.doc.querySelector(t):t;if(!i)throw new F(-5104,!1);return e||(i.textContent=""),i}parentNode(t){return t.parentNode}nextSibling(t){return t.nextSibling}setAttribute(t,e,i,r){if(r){e=r+":"+e;const s=lC[r];s?t.setAttributeNS(s,e,i):t.setAttribute(e,i)}else t.setAttribute(e,i)}removeAttribute(t,e,i){if(i){const r=lC[i];r?t.removeAttributeNS(r,e):t.removeAttribute(`${i}:${e}`)}else t.removeAttribute(e)}addClass(t,e){t.classList.add(e)}removeClass(t,e){t.classList.remove(e)}setStyle(t,e,i,r){r&(ec.DashCase|ec.Important)?t.style.setProperty(e,i,r&ec.Important?"important":""):t.style[e]=i}removeStyle(t,e,i){i&ec.DashCase?t.style.removeProperty(e):t.style[e]=""}setProperty(t,e,i){null!=t&&(t[e]=i)}setValue(t,e){t.nodeValue=e}listen(t,e,i){if("string"==typeof t&&!(t=jw().getGlobalEventTarget(this.doc,t)))throw new Error(`Unsupported event target ${t} for event ${e}`);return this.eventManager.addEventListener(t,e,this.decoratePreventDefault(i))}decoratePreventDefault(t){return e=>{if("__ngUnwrap__"===e)return t;!1===(this.platformIsServer?this.ngZone.runGuarded(()=>t(e)):t(e))&&e.preventDefault()}}}function Mz(n){return"TEMPLATE"===n.tagName&&void 0!==n.content}class Vq extends cC{constructor(t,e,i,r,s,o,a,l){super(t,s,o,l),this.sharedStylesHost=e,this.hostEl=i,this.shadowRoot=i.attachShadow({mode:"open"}),this.sharedStylesHost.addHost(this.shadowRoot);const h=Iz(r.id,r.styles);for(const c of h){const d=document.createElement("style");a&&d.setAttribute("nonce",a),d.textContent=c,this.shadowRoot.appendChild(d)}}nodeOrShadowRoot(t){return t===this.hostEl?this.shadowRoot:t}appendChild(t,e){return super.appendChild(this.nodeOrShadowRoot(t),e)}insertBefore(t,e,i){return super.insertBefore(this.nodeOrShadowRoot(t),e,i)}removeChild(t,e){return super.removeChild(this.nodeOrShadowRoot(t),e)}parentNode(t){return this.nodeOrShadowRoot(super.parentNode(this.nodeOrShadowRoot(t)))}destroy(){this.sharedStylesHost.removeHost(this.shadowRoot)}}class dC extends cC{constructor(t,e,i,r,s,o,a,l){super(t,s,o,a),this.sharedStylesHost=e,this.removeStylesOnCompDestroy=r,this.styles=l?Iz(l,i.styles):i.styles}applyStyles(){this.sharedStylesHost.addStyles(this.styles)}destroy(){this.removeStylesOnCompDestroy&&this.sharedStylesHost.removeStyles(this.styles)}}class wz extends dC{constructor(t,e,i,r,s,o,a,l){const h=r+"-"+i.id;super(t,e,i,s,o,a,l,h),this.contentAttr=function _q(n){return"_ngcontent-%COMP%".replace(hC,n)}(h),this.hostAttr=function Uq(n){return"_nghost-%COMP%".replace(hC,n)}(h)}applyToHost(t){this.applyStyles(),this.setAttribute(t,this.hostAttr,"")}createElement(t,e){const i=super.createElement(t,e);return super.setAttribute(i,this.contentAttr,""),i}}let Wq=(()=>{class n extends mz{constructor(e){super(e)}supports(e){return!0}addEventListener(e,i,r){return e.addEventListener(i,r,!1),()=>this.removeEventListener(e,i,r)}removeEventListener(e,i,r){return e.removeEventListener(i,r)}static{this.\u0275fac=function(i){return new(i||n)(_i(sd))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();const Cz=["alt","control","meta","shift"],Yq={"\b":"Backspace","\t":"Tab","\x7f":"Delete","\x1b":"Escape",Del:"Delete",Esc:"Escape",Left:"ArrowLeft",Right:"ArrowRight",Up:"ArrowUp",Down:"ArrowDown",Menu:"ContextMenu",Scroll:"ScrollLock",Win:"OS"},Qq={alt:n=>n.altKey,control:n=>n.ctrlKey,meta:n=>n.metaKey,shift:n=>n.shiftKey};let Gq=(()=>{class n extends mz{constructor(e){super(e)}supports(e){return null!=n.parseEventName(e)}addEventListener(e,i,r){const s=n.parseEventName(i),o=n.eventCallback(s.fullKey,r,this.manager.getZone());return this.manager.getZone().runOutsideAngular(()=>jw().onAndCancel(e,s.domEventName,o))}static parseEventName(e){const i=e.toLowerCase().split("."),r=i.shift();if(0===i.length||"keydown"!==r&&"keyup"!==r)return null;const s=n._normalizeKey(i.pop());let o="",a=i.indexOf("code");if(a>-1&&(i.splice(a,1),o="code."),Cz.forEach(h=>{const c=i.indexOf(h);c>-1&&(i.splice(c,1),o+=h+".")}),o+=s,0!=i.length||0===s.length)return null;const l={};return l.domEventName=r,l.fullKey=o,l}static matchEventFullKeyCode(e,i){let r=Yq[e.key]||e.key,s="";return i.indexOf("code.")>-1&&(r=e.code,s="code."),!(null==r||!r)&&(r=r.toLowerCase()," "===r?r="space":"."===r&&(r="dot"),Cz.forEach(o=>{o!==r&&(0,Qq[o])(e)&&(s+=o+".")}),s+=r,s===i)}static eventCallback(e,i,r){return s=>{n.matchEventFullKeyCode(s,e)&&r.runGuarded(()=>i(s))}}static _normalizeKey(e){return"esc"===e?"escape":e}static{this.\u0275fac=function(i){return new(i||n)(_i(sd))}}static{this.\u0275prov=Yi({token:n,factory:n.\u0275fac})}}return n})();function Ez(n){return{appProviders:[...e$,...n?.providers??[]],platformProviders:Jq}}const Jq=[{provide:Su,useValue:"browser"},{provide:nL,useValue:function qq(){sC.makeCurrent()},multi:!0},{provide:sd,useFactory:function Zq(){return function xj(n){x1=n}(document),document},deps:[]}],e$=[{provide:b1,useValue:"root"},{provide:nh,useFactory:function $q(){return new nh},deps:[]},{provide:oC,useClass:Wq,multi:!0,deps:[sd,Rr,Su]},{provide:oC,useClass:Gq,multi:!0,deps:[sd]},bz,yz,vz,{provide:nN,useExisting:bz},{provide:class lq{},useClass:zq,deps:[]},[]];var n$=0,uC=!1;function I0(n,t){var e=t;return e.unshift(void 0),new(Function.prototype.bind.apply(n,e))}function Y(n,t){for(var e=t,i=n.replace(/\[/g,".").replace(/\]/g,"").split("."),r=0;r"u"}function Ei(n){return n+"_"+n$++}function M0(n,t){return n===t||!(n===document||!n)&&M0(n.parentNode,t)}function Dg(n){try{throw new Error(n)}catch(t){throw new Error(t.message+"\n"+t.stack)}}function Re(n){var t=n+"";return t.match(/auto|cm|mm|in|px|pt|pc|%|em|ex|ch|rem|vw|vh|vmin|vmax/)?t:t+"px"}function ce(){return uC}var xg,n,t,h$={latn:{_digits:"0123456789",_type:"numeric"}},Lz={decimal:".",group:",",percentSign:"%",plusSign:"+",minusSign:"-",infinity:"\u221e",nan:"NaN",exponential:"E"},Nz=[0,1,2,3,4,5,6,7,8,9],Hr=function(){function n(){}return n.getMainObject=function(t,e){return Y(ce()?e:"main."+e,t)},n.getNumberingSystem=function(t){return Y("supplemental.numberingSystems",t)||this.numberingSystems},n.reverseObject=function(t,e){for(var r={},s=0,o=e||Object.keys(t);s13&&(p+=1,o-=12),o-=1,a=p-4716;var y=u-24e5,S=10631/30,b=u-1948084,M=Math.floor(b/10631);b-=10631*M;var w=Math.floor((b-.1335)/S),C=30*M+w;b-=Math.floor(w*S+.1335);var D=Math.floor((b+28.5001)/29.5);13===D&&(D=12);for(var A=b-Math.floor(29.5001*D-29),x=0;xy);x++);var P=x+16260,L=Math.floor((P-1)/12),O=L+1,N=P-12*L,T=y-t[x-1]+1;return(T+"").length>2&&(T=A,N=D,O=C),{year:O,month:N,date:T}},n.toGregorian=function i(r,s,o){var g=Math.floor(o+t[12*(r-1)+1+(s-1)-16260-1]-1+24e5+.5),v=Math.floor((g-1867216.25)/36524.25),y=1524+(v=g+1+v-Math.floor(v/4)),S=Math.floor((y-122.1)/365.25),b=Math.floor(365.25*S),M=Math.floor((y-b)/30.6001),w=y-b-Math.floor(30.6001*M),C=M-(M>13.5?13:1),D=S-(C>2.5?4716:4715);return D<=0&&C--,new Date(D+"/"+C+"/"+w)};var ut,u$=/\/MMMMM|MMMM|MMM|a|LLLL|LLL|EEEEE|EEEE|E|K|cccc|ccc|WW|W|G+|z+/gi,Oz="stand-alone",f$=["sun","mon","tue","wed","thu","fri","sat"],kz={m:"getMinutes",h:"getHours",H:"getHours",s:"getSeconds",d:"getDate",f:"getMilliseconds"},Pz=function(){function n(){}return n.dateFormat=function(t,e,i){var r=this,s=ut.getDependables(i,t,e.calendar),o=Y("parserObject.numbers",s),a=s.dateObject,l={isIslamic:ut.islamicRegex.test(e.calendar)};ce()&&e.isServerRendered&&(e=ut.compareBlazorDateFormats(e,t));var h=e.format||ut.getResultantPattern(e.skeleton,s.dateObject,e.type,!1,ce()?t:"");if(l.dateSeperator=ce()?Y("dateSeperator",a):ut.getDateSeparator(s.dateObject),st(h))Dg("Format options or type given must be invalid");else{h=ut.ConvertDateToWeekFormat(h),ce()&&(h=h.replace(/tt/,"a")),l.pattern=h,l.numMapper=ce()?ze({},o):Hr.getNumberMapper(s.parserObject,Hr.getNumberingSystem(i));for(var d=0,u=h.match(u$)||[];d2?r+=e.month[""+u]:p=!0;break;case"E":case"c":r+=e.weekday[""+f$[t.getDay()]];break;case"H":case"h":case"m":case"s":case"d":case"f":if(p=!0,"d"===d)u=o.date;else if("f"===d){p=!1,g=!0;var y=(f=(f=t[""+kz[""+d]]().toString()).substring(0,c)).length;if(c!==y){if(c>3)continue;for(var S=0;S0?1:0],o=Math.abs(t);return s.replace(/HH?|mm/g,function(a){var l=a.length,h=-1!==a.indexOf("H");return i.checkTwodigitNumber(Math.floor(h?o/60:o%60),l)})},n}(),zz={ms:"minimumSignificantDigits",ls:"maximumSignificantDigits",mf:"minimumFractionDigits",lf:"maximumFractionDigits"},tf=["infinity","nan","group","decimal","exponential"],Rz=function(){function n(){}return n.numberFormatter=function(t,e,i){var l,r=this,s=ze({},e),o={},a={},h=ut.getDependables(i,t,"",!0),c=h.numericObject;a.numberMapper=ce()?ze({},c):Hr.getNumberMapper(h.parserObject,Hr.getNumberingSystem(i),!0),a.currencySymbol=ce()?Y("currencySymbol",c):ut.getCurrencySymbol(h.numericObject,s.currency||Lg,e.altSymbol,e.ignoreCurrency),a.percentSymbol=ce()?Y("numberSymbols.percentSign",c):a.numberMapper.numberSymbols.percentSign,a.minusSymbol=ce()?Y("numberSymbols.minusSign",c):a.numberMapper.numberSymbols.minusSign;var d=a.numberMapper.numberSymbols;if(e.format&&!ut.formatRegex.test(e.format))o=ut.customFormat(e.format,a,h.numericObject),!st(s.useGrouping)&&s.useGrouping&&(s.useGrouping=o.pData.useGrouping);else{if(ze(s,ut.getProperNumericSkeleton(e.format||"N")),s.isCurrency="currency"===s.type,s.isPercent="percent"===s.type,ce()||(l=ut.getSymbolPattern(s.type,a.numberMapper.numberSystem,h.numericObject,s.isAccount)),s.groupOne=this.checkValueRange(s.maximumSignificantDigits,s.minimumSignificantDigits,!0),this.checkValueRange(s.maximumFractionDigits,s.minimumFractionDigits,!1,!0),st(s.fractionDigits)||(s.minimumFractionDigits=s.maximumFractionDigits=s.fractionDigits),st(s.useGrouping)&&(s.useGrouping=!0),s.isCurrency&&!ce()&&(l=l.replace(/\u00A4/g,ut.defaultCurrency)),ce())o.nData=ze({},{},Y(s.type+"nData",c)),o.pData=ze({},{},Y(s.type+"pData",c)),"currency"===s.type&&e.currency&&ut.replaceBlazorCurrency([o.pData,o.nData],a.currencySymbol,e.currency);else{var u=l.split(";");o.nData=ut.getFormatData(u[1]||"-"+u[0],!0,a.currencySymbol),o.pData=ut.getFormatData(u[0],!1,a.currencySymbol),s.useGrouping&&(s.groupSeparator=d[tf[2]],s.groupData=this.getGroupingDetails(u[0]))}if(st(s.minimumFractionDigits)&&(s.minimumFractionDigits=o.nData.minimumFraction),st(s.maximumFractionDigits)){var p=o.nData.maximumFraction;s.maximumFractionDigits=st(p)&&s.isPercent?0:p}var g=s.minimumFractionDigits,v=s.maximumFractionDigits;!st(g)&&!st(v)&&g>v&&(s.maximumFractionDigits=g)}return ze(o.nData,s),ze(o.pData,s),function(y){return isNaN(y)?d[tf[1]]:isFinite(y)?r.intNumberFormatter(y,o,a,e):d[tf[0]]}},n.getGroupingDetails=function(t){var e={},i=t.match(ut.negativeDataRegex);if(i&&i[4]){var r=i[4],s=r.lastIndexOf(",");if(-1!==s){var o=r.split(".")[0];e.primary=o.length-s-1;var a=r.lastIndexOf(",",s-1);-1!==a&&(e.secondary=s-1-a)}}return e},n.checkValueRange=function(t,e,i,r){var s=r?"f":"s",o=0,a=zz["l"+s],l=zz["m"+s];if(st(t)||(this.checkRange(t,a,r),o++),st(e)||(this.checkRange(e,l,r),o++),2===o){if(!(tr[1])&&Dg(e+"value must be within the range"+r[0]+"to"+r[1])},n.intNumberFormatter=function(t,e,i,r){var s;if(!st(e.nData.type)){t<0?(t*=-1,s=e.nData):s=0===t&&e.zeroData||e.pData;var o="";if(s.isPercent&&(t*=100),s.groupOne)o=this.processSignificantDigits(t,s.minimumSignificantDigits,s.maximumSignificantDigits);else if(o=this.processFraction(t,s.minimumFractionDigits,s.maximumFractionDigits,r),s.minimumIntegerDigits&&(o=this.processMinimumIntegers(o,s.minimumIntegerDigits)),i.isCustomFormat&&s.minimumFractionDigits=0&&"0"===l[parseInt(c.toString(),10)]&&c>=s.minimumFractionDigits;c--)l=l.slice(0,c);o=a[0]+"."+l}return"scientific"===s.type&&(o=(o=t.toExponential(s.maximumFractionDigits)).replace("e",i.numberMapper.numberSymbols[tf[4]])),o=o.replace(".",i.numberMapper.numberSymbols[tf[3]]),o="#,###,,;(#,###,,)"===s.format?this.customPivotFormat(parseInt(o,10)):o,s.useGrouping&&(o=this.groupNumbers(o,s.groupData.primary,s.groupSeparator||",",i.numberMapper.numberSymbols[tf[3]]||".",s.groupData.secondary)),o=Hr.convertValueParts(o,ut.latnParseRegex,i.numberMapper.mapper),"N/A"===s.nlead?s.nlead:"0"===o&&r&&"0"===r.format?o+s.nend:s.nlead+o+s.nend}},n.processSignificantDigits=function(t,e,i){var r=t+"";return r.lengthe;)c=l.slice(h-e,h)+(c.length?i+c:""),h-=e,o&&(e=s,o=!1);return a[0]=l.slice(0,h)+(c.length?i:"")+c,a.join(r)},n.processFraction=function(t,e,i,r){var s=(t+"").split(".")[1],o=s?s.length:0;if(e&&oi||0===i))return t.toFixed(i);var h=t+"";return"0"===h[0]&&r&&"###.00"===r.format&&(h=h.slice(1)),h},n.processMinimumIntegers=function(t,e){var i=t.split("."),r=i[0],s=r.length;if(s=5e5){var r=(t/=1e6).toString().split(".")[1];return r&&+r.substring(0,1)>=5?Math.ceil(t).toString():Math.floor(t).toString()}return""},n}(),Tg=(new RegExp("^([^0-9]*)(([0-9,]*[0-9]+)(.[0-9]+)?)([Ee][+-]?[0-9]+)?([^0-9]*)$"),function(){function n(t){this.ranArray=[],this.boundedEvents={},!m(t)&&(this.context=t)}return n.prototype.on=function(t,e,i,r){if(!m(e)){var s=i||this.context;if(this.notExist(t))return void(this.boundedEvents[""+t]=[{handler:e,context:s,id:r}]);m(r)?this.isHandlerPresent(this.boundedEvents[""+t],e)||this.boundedEvents[""+t].push({handler:e,context:s}):-1===this.ranArray.indexOf(r)&&(this.ranArray.push(r),this.boundedEvents[""+t].push({handler:e,context:s,id:r}))}},n.prototype.off=function(t,e,i){if(!this.notExist(t)){var r=Y(t,this.boundedEvents);if(e){for(var s=0;s1&&(U.fractionDigits=parseInt(z[2],10)),U}function p(T,z,U,B){var j=B?{}:{nlead:"",nend:""},Q=T.match(n.customRegex);if(Q){B||(j.nlead=g(Q[1],U),j.nend=g(Q[10],U),j.groupPattern=Q[4]);var oe=Q[7];if(oe&&z){var ue=oe.match(t);j.minimumFraction=m(ue)?0:ue.length,j.maximumFraction=oe.length-1}}return j}function g(T,z){return T?(T=T.replace(n.defaultCurrency,z),""===z?T.trim():T):""}function v(T,z,U,B){return B?"$":Y("currencies."+z+(U?"."+U:".symbol"),T)||Y("currencies."+z+".symbol-alt-narrow",T)||"$"}function S(T,z,U){var B={type:"decimal",minimumFractionDigits:0,maximumFractionDigits:0},j=T.match(n.customRegex);if(m(j)||""===j[5]&&"N/A"!==T)return B.type=void 0,B;B.nlead=j[1],B.nend=j[10];var Q=j[6],oe=!!Q.match(/ $/g),ue=-1!==Q.replace(/ $/g,"").indexOf(" ");B.useGrouping=-1!==Q.indexOf(",")||ue,Q=Q.replace(/,/g,"");var fe=j[7];if(-1!==Q.indexOf("0")&&(B.minimumIntegerDigits=Q.length-Q.indexOf("0")),m(fe)||(B.minimumFractionDigits=fe.lastIndexOf("0"),B.maximumFractionDigits=fe.lastIndexOf("#"),-1===B.minimumFractionDigits&&(B.minimumFractionDigits=0),(-1===B.maximumFractionDigits||B.maximumFractionDigitsQ.lastIndexOf("'"))){B[""+a[parseInt(j.toString(),10)]]=Q.substr(0,oe)+U+Q.substr(oe+1),B[""+a[""+z]]=!0,B.type=B.isCurrency?"currency":"percent";break}}return B}function C(T,z){if(-1!==T.indexOf(",")){var U=T.split(",");T=U[0]+Y("numberMapper.numberSymbols.group",z)+U[1].replace(".",Y("numberMapper.numberSymbols.decimal",z))}else T=T.replace(".",Y("numberMapper.numberSymbols.decimal",z));return T}function A(T,z,U){T+=".";for(var B=0;B0;Q-=3)T=","+U[Q-2]+U[Q-1]+U[parseInt(Q.toString(),10)]+T;return T=T.slice(1),z[1]?T+"."+z[1]:T}n.dateParseRegex=/([a-z])\1*|'([^']|'')+'|''|./gi,n.basicPatterns=["short","medium","long","full"],n.defaultObject={dates:{calendars:{gregorian:{months:{"stand-alone":{abbreviated:{1:"Jan",2:"Feb",3:"Mar",4:"Apr",5:"May",6:"Jun",7:"Jul",8:"Aug",9:"Sep",10:"Oct",11:"Nov",12:"Dec"},narrow:{1:"J",2:"F",3:"M",4:"A",5:"M",6:"J",7:"J",8:"A",9:"S",10:"O",11:"N",12:"D"},wide:{1:"January",2:"February",3:"March",4:"April",5:"May",6:"June",7:"July",8:"August",9:"September",10:"October",11:"November",12:"December"}}},days:{"stand-alone":{abbreviated:{sun:"Sun",mon:"Mon",tue:"Tue",wed:"Wed",thu:"Thu",fri:"Fri",sat:"Sat"},narrow:{sun:"S",mon:"M",tue:"T",wed:"W",thu:"T",fri:"F",sat:"S"},short:{sun:"Su",mon:"Mo",tue:"Tu",wed:"We",thu:"Th",fri:"Fr",sat:"Sa"},wide:{sun:"Sunday",mon:"Monday",tue:"Tuesday",wed:"Wednesday",thu:"Thursday",fri:"Friday",sat:"Saturday"}}},dayPeriods:{format:{wide:{am:"AM",pm:"PM"}}},eras:{eraNames:{0:"Before Christ","0-alt-variant":"Before Common Era",1:"Anno Domini","1-alt-variant":"Common Era"},eraAbbr:{0:"BC","0-alt-variant":"BCE",1:"AD","1-alt-variant":"CE"},eraNarrow:{0:"B","0-alt-variant":"BCE",1:"A","1-alt-variant":"CE"}},dateFormats:{full:"EEEE, MMMM d, y",long:"MMMM d, y",medium:"MMM d, y",short:"M/d/yy"},timeFormats:{full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},dateTimeFormats:{full:"{1} 'at' {0}",long:"{1} 'at' {0}",medium:"{1}, {0}",short:"{1}, {0}",availableFormats:{d:"d",E:"ccc",Ed:"d E",Ehm:"E h:mm a",EHm:"E HH:mm",Ehms:"E h:mm:ss a",EHms:"E HH:mm:ss",Gy:"y G",GyMMM:"MMM y G",GyMMMd:"MMM d, y G",GyMMMEd:"E, MMM d, y G",h:"h a",H:"HH",hm:"h:mm a",Hm:"HH:mm",hms:"h:mm:ss a",Hms:"HH:mm:ss",hmsv:"h:mm:ss a v",Hmsv:"HH:mm:ss v",hmv:"h:mm a v",Hmv:"HH:mm v",M:"L",Md:"M/d",MEd:"E, M/d",MMM:"LLL",MMMd:"MMM d",MMMEd:"E, MMM d",MMMMd:"MMMM d",ms:"mm:ss",y:"y",yM:"M/y",yMd:"M/d/y",yMEd:"E, M/d/y",yMMM:"MMM y",yMMMd:"MMM d, y",yMMMEd:"E, MMM d, y",yMMMM:"MMMM y"}}},islamic:{months:{"stand-alone":{abbreviated:{1:"Muh.",2:"Saf.",3:"Rab. I",4:"Rab. II",5:"Jum. I",6:"Jum. II",7:"Raj.",8:"Sha.",9:"Ram.",10:"Shaw.",11:"Dhu\u02bbl-Q.",12:"Dhu\u02bbl-H."},narrow:{1:"1",2:"2",3:"3",4:"4",5:"5",6:"6",7:"7",8:"8",9:"9",10:"10",11:"11",12:"12"},wide:{1:"Muharram",2:"Safar",3:"Rabi\u02bb I",4:"Rabi\u02bb II",5:"Jumada I",6:"Jumada II",7:"Rajab",8:"Sha\u02bbban",9:"Ramadan",10:"Shawwal",11:"Dhu\u02bbl-Qi\u02bbdah",12:"Dhu\u02bbl-Hijjah"}}},days:{"stand-alone":{abbreviated:{sun:"Sun",mon:"Mon",tue:"Tue",wed:"Wed",thu:"Thu",fri:"Fri",sat:"Sat"},narrow:{sun:"S",mon:"M",tue:"T",wed:"W",thu:"T",fri:"F",sat:"S"},short:{sun:"Su",mon:"Mo",tue:"Tu",wed:"We",thu:"Th",fri:"Fr",sat:"Sa"},wide:{sun:"Sunday",mon:"Monday",tue:"Tuesday",wed:"Wednesday",thu:"Thursday",fri:"Friday",sat:"Saturday"}}},dayPeriods:{format:{wide:{am:"AM",pm:"PM"}}},eras:{eraNames:{0:"AH"},eraAbbr:{0:"AH"},eraNarrow:{0:"AH"}},dateFormats:{full:"EEEE, MMMM d, y G",long:"MMMM d, y G",medium:"MMM d, y G",short:"M/d/y GGGGG"},timeFormats:{full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},dateTimeFormats:{full:"{1} 'at' {0}",long:"{1} 'at' {0}",medium:"{1}, {0}",short:"{1}, {0}",availableFormats:{d:"d",E:"ccc",Ed:"d E",Ehm:"E h:mm a",EHm:"E HH:mm",Ehms:"E h:mm:ss a",EHms:"E HH:mm:ss",Gy:"y G",GyMMM:"MMM y G",GyMMMd:"MMM d, y G",GyMMMEd:"E, MMM d, y G",h:"h a",H:"HH",hm:"h:mm a",Hm:"HH:mm",hms:"h:mm:ss a",Hms:"HH:mm:ss",M:"L",Md:"M/d",MEd:"E, M/d",MMM:"LLL",MMMd:"MMM d",MMMEd:"E, MMM d",MMMMd:"MMMM d",ms:"mm:ss",y:"y G",yyyy:"y G",yyyyM:"M/y GGGGG",yyyyMd:"M/d/y GGGGG",yyyyMEd:"E, M/d/y GGGGG",yyyyMMM:"MMM y G",yyyyMMMd:"MMM d, y G",yyyyMMMEd:"E, MMM d, y G",yyyyMMMM:"MMMM y G",yyyyQQQ:"QQQ y G",yyyyQQQQ:"QQQQ y G"}}}},timeZoneNames:{hourFormat:"+HH:mm;-HH:mm",gmtFormat:"GMT{0}",gmtZeroFormat:"GMT"}},numbers:{currencies:{USD:{displayName:"US Dollar",symbol:"$","symbol-alt-narrow":"$"},EUR:{displayName:"Euro",symbol:"\u20ac","symbol-alt-narrow":"\u20ac"},GBP:{displayName:"British Pound","symbol-alt-narrow":"\xa3"}},defaultNumberingSystem:"latn",minimumGroupingDigits:"1","symbols-numberSystem-latn":{decimal:".",group:",",list:";",percentSign:"%",plusSign:"+",minusSign:"-",exponential:"E",superscriptingExponent:"\xd7",perMille:"\u2030",infinity:"\u221e",nan:"NaN",timeSeparator:":"},"decimalFormats-numberSystem-latn":{standard:"#,##0.###"},"percentFormats-numberSystem-latn":{standard:"#,##0%"},"currencyFormats-numberSystem-latn":{standard:"\xa4#,##0.00",accounting:"\xa4#,##0.00;(\xa4#,##0.00)"},"scientificFormats-numberSystem-latn":{standard:"#E0"}}},n.blazorDefaultObject={numbers:{mapper:{0:"0",1:"1",2:"2",3:"3",4:"4",5:"5",6:"6",7:"7",8:"8",9:"9"},mapperDigits:"0123456789",numberSymbols:{decimal:".",group:",",plusSign:"+",minusSign:"-",percentSign:"%",nan:"NaN",timeSeparator:":",infinity:"\u221e"},timeSeparator:":",currencySymbol:"$",currencypData:{nlead:"$",nend:"",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},percentpData:{nlead:"",nend:"%",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},percentnData:{nlead:"-",nend:"%",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},currencynData:{nlead:"($",nend:")",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},decimalnData:{nlead:"-",nend:"",groupData:{primary:3},maximumFraction:2,minimumFraction:2},decimalpData:{nlead:"",nend:"",groupData:{primary:3},maximumFraction:2,minimumFraction:2}},dates:{dayPeriods:{am:"AM",pm:"PM"},dateSeperator:"/",days:{abbreviated:{sun:"Sun",mon:"Mon",tue:"Tue",wed:"Wed",thu:"Thu",fri:"Fri",sat:"Sat"},short:{sun:"Su",mon:"Mo",tue:"Tu",wed:"We",thu:"Th",fri:"Fr",sat:"Sa"},wide:{sun:"Sunday",mon:"Monday",tue:"Tuesday",wed:"Wednesday",thu:"Thursday",fri:"Friday",sat:"Saturday"}},months:{abbreviated:{1:"Jan",2:"Feb",3:"Mar",4:"Apr",5:"May",6:"Jun",7:"Jul",8:"Aug",9:"Sep",10:"Oct",11:"Nov",12:"Dec"},wide:{1:"January",2:"February",3:"March",4:"April",5:"May",6:"June",7:"July",8:"August",9:"September",10:"October",11:"November",12:"December"}},eras:{1:"AD"}}},n.monthIndex={3:"abbreviated",4:"wide",5:"narrow",1:"abbreviated"},n.month="months",n.days="days",n.patternMatcher={C:"currency",P:"percent",N:"decimal",A:"currency",E:"scientific"},n.getResultantPattern=l,n.getDependables=h,n.getSymbolPattern=c,n.ConvertDateToWeekFormat=d,n.compareBlazorDateFormats=u,n.getProperNumericSkeleton=f,n.getFormatData=p,n.changeCurrencySymbol=g,n.getCurrencySymbol=v,n.customFormat=function y(T,z,U){for(var B={},j=T.split(";"),Q=["pData","nData","zeroData"],oe=0;oe1,fe.nData=ce()?Y(De.type+"nData",oe):p(ot[1]||"-"+ot[0],!0,Ie),fe.pData=ce()?Y(De.type+"pData",oe):p(ot[0],!1,Ie),!Me[2]&&!z.minimumFractionDigits&&!z.maximumFractionDigits&&(ue=p(Ve.split(";")[0],!0,"",!0).minimumFraction)}if(n.formatRegex.test(z.format)||!z.format){if(ze(Q,f(z.format||"N")),Q.custom=!1,$e="###0",(Q.fractionDigits||z.minimumFractionDigits||z.maximumFractionDigits||ue)&&(Q.fractionDigits&&(z.minimumFractionDigits=z.maximumFractionDigits=Q.fractionDigits),$e=A($e,ue||Q.fractionDigits||z.minimumFractionDigits||0,z.maximumFractionDigits||0)),z.minimumIntegerDigits&&($e=x($e,z.minimumIntegerDigits)),z.useGrouping&&($e=P($e)),"currency"===Q.type||Q.type&&ce()){ce()&&"currency"!==Q.type&&(fe.pData=Y(Q.type+"pData",oe),fe.nData=Y(Q.type+"nData",oe));var hr=$e;$e=fe.pData.nlead+hr+fe.pData.nend,(fe.hasNegativePattern||ce())&&($e+=";"+fe.nData.nlead+hr+fe.nData.nend)}"percent"===Q.type&&!ce()&&($e+=" %")}else $e=z.format.replace(/'/g,'"');return Object.keys(xe).length>0&&($e=B?$e:C($e,xe)),$e},n.fractionDigitsPattern=A,n.minimumIntegerPattern=x,n.groupingPattern=P,n.getWeekData=function L(T,z){var U="sun",B=Y("supplemental.weekData.firstDay",z),j=T;return/en-/.test(j)&&(j=j.slice(3)),j=j.slice(0,2).toUpperCase()+j.substr(2),B&&(U=B[""+j]||B[j.slice(0,2)]||"sun"),o[""+U]},n.replaceBlazorCurrency=function O(T,z,U){var B=function d$(n){return Y(n||"",c$)}(U);if(z!==B)for(var j=0,Q=T;j=0?U:U+7;var j=Math.floor((T.getTime()-z.getTime()-6e4*(T.getTimezoneOffset()-z.getTimezoneOffset()))/864e5)+1;if(U<4){if((B=Math.floor((j+U-1)/7)+1)>52){var oe=new Date(T.getFullYear()+1,0,1).getDay();B=(oe=oe>=0?oe:oe+7)<4?1:53}}else B=Math.floor((j+U-1)/7);return B}}(ut||(ut={}));var rf=function(){function n(t,e,i){this.type="GET",this.emitError=!0,"string"==typeof t?(this.url=t,this.type=m(e)?this.type:e.toUpperCase(),this.contentType=i):La(t)&&Object.keys(t).length>0&&kn(this,t),this.contentType=m(this.contentType)?"application/json; charset=utf-8":this.contentType}return n.prototype.send=function(t){var e=this,i={"application/json":"json","multipart/form-data":"formData","application/octet-stream":"blob","application/x-www-form-urlencoded":"formData"};try{m(this.fetchRequest)&&"GET"===this.type?this.fetchRequest=new Request(this.url,{method:this.type}):m(this.fetchRequest)&&(this.data=m(t)?this.data:t,this.fetchRequest=new Request(this.url,{method:this.type,headers:{"Content-Type":this.contentType},body:this.data}));var r={cancel:!1,fetchRequest:this.fetchRequest};return this.triggerEvent(this.beforeSend,r),r.cancel?null:(this.fetchResponse=fetch(this.fetchRequest),this.fetchResponse.then(function(s){if(e.triggerEvent(e.onLoad,s),!s.ok)throw s;for(var o="text",a=0,l=Object.keys(i);a-1},n.getValue=function(t,e){var i=typeof window<"u"?window.browserDetails:{};return typeof navigator<"u"&&"MacIntel"===navigator.platform&&navigator.maxTouchPoints>1&&!0===n.isTouch&&!gC.CHROME.test(navigator.userAgent)&&(i.isIos=!0,i.isDevice=!0,i.isTouch=!0,i.isPointer=!0,i.isPointer="pointerEnabled"in window.navigator),typeof window<"u"&&window.Capacitor&&"ios"===window.Capacitor.getPlatform()&&(i.isPointer=!1),typeof i[""+t]>"u"?i[""+t]=e.test(n.userAgent):i[""+t]},Object.defineProperty(n,"userAgent",{get:function(){return n.uA},set:function(t){n.uA=t,window.browserDetails={}},enumerable:!0,configurable:!0}),Object.defineProperty(n,"info",{get:function(){return st(window.browserDetails.info)?window.browserDetails.info=n.extractBrowserDetail():window.browserDetails.info},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isIE",{get:function(){return n.getValue("isIE",x$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isTouch",{get:function(){return st(window.browserDetails.isTouch)?window.browserDetails.isTouch="ontouchstart"in window.navigator||window&&window.navigator&&window.navigator.maxTouchPoints>0||"ontouchstart"in window:window.browserDetails.isTouch},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isPointer",{get:function(){return st(window.browserDetails.isPointer)?window.browserDetails.isPointer="pointerEnabled"in window.navigator:window.browserDetails.isPointer},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isMSPointer",{get:function(){return st(window.browserDetails.isMSPointer)?window.browserDetails.isMSPointer="msPointerEnabled"in window.navigator:window.browserDetails.isMSPointer},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isDevice",{get:function(){return n.getValue("isDevice",D$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isIos",{get:function(){return n.getValue("isIos",A$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isIos7",{get:function(){return n.getValue("isIos7",L$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isAndroid",{get:function(){return n.getValue("isAndroid",N$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isWebView",{get:function(){return st(window.browserDetails.isWebView)&&(window.browserDetails.isWebView=!(st(window.cordova)&&st(window.PhoneGap)&&st(window.phonegap)&&"object"!==window.forge)),window.browserDetails.isWebView},enumerable:!0,configurable:!0}),Object.defineProperty(n,"isWindows",{get:function(){return n.getValue("isWindows",O$)},enumerable:!0,configurable:!0}),Object.defineProperty(n,"touchStartEvent",{get:function(){return st(window.browserDetails.touchStartEvent)?window.browserDetails.touchStartEvent=n.getTouchStartEvent():window.browserDetails.touchStartEvent},enumerable:!0,configurable:!0}),Object.defineProperty(n,"touchMoveEvent",{get:function(){return st(window.browserDetails.touchMoveEvent)?window.browserDetails.touchMoveEvent=n.getTouchMoveEvent():window.browserDetails.touchMoveEvent},enumerable:!0,configurable:!0}),Object.defineProperty(n,"touchEndEvent",{get:function(){return st(window.browserDetails.touchEndEvent)?window.browserDetails.touchEndEvent=n.getTouchEndEvent():window.browserDetails.touchEndEvent},enumerable:!0,configurable:!0}),Object.defineProperty(n,"touchCancelEvent",{get:function(){return st(window.browserDetails.touchCancelEvent)?window.browserDetails.touchCancelEvent=n.getTouchCancelEvent():window.browserDetails.touchCancelEvent},enumerable:!0,configurable:!0}),n.uA=typeof navigator<"u"?navigator.userAgent:"",n}(),E=function(){function n(){}return n.addOrGetEventData=function(t){return"__eventList"in t?t.__eventList.events:(t.__eventList={},t.__eventList.events=[])},n.add=function(t,e,i,r,s){var a,o=n.addOrGetEventData(t);a=s?function o$(n,t){var e;return function(){for(var i=this,r=[],s=0;s"u"||(e.innerHTML=t.innerHTML?t.innerHTML:"",void 0!==t.className&&(e.className=t.className),void 0!==t.id&&(e.id=t.id),void 0!==t.styles&&e.setAttribute("style",t.styles),void 0!==t.attrs&&Fe(e,t.attrs)),e}function V(n,t){for(var e=Vz(t),i=RegExp,r=0,s=n;r0}function gl(n,t,e){for(var i=document.createDocumentFragment(),r=0,s=n;r0;)i.appendChild(n[0]);else for(var r=0,s=n;r-1&&!r[parseInt(s.toString(),10)].match(/\[.*\]/)){var o=r[parseInt(s.toString(),10)].split("#");if(o[1].match(/^\d/)||o[1].match(t)){var a=r[parseInt(s.toString(),10)].split(".");a[0]=a[0].replace(/#/,"[id='")+"']",r[parseInt(s.toString(),10)]=a.join(".")}}e[parseInt(i.toString(),10)]=r.join(" ")}return e.join(",")}return n}function J(n,t){var e=n;if("function"==typeof e.closest)return e.closest(t);for(;e&&1===e.nodeType;){if(vC(e,t))return e;e=e.parentNode}return null}function je(n,t){void 0!==t&&Object.keys(t).forEach(function(e){n.style[""+e]=t[""+e]})}function vC(n,t){var e=n.matches||n.msMatchesSelector||n.webkitMatchesSelector;return e?e.call(n,t):-1!==[].indexOf.call(document.querySelectorAll(t),n)}var z$=new RegExp("]"),dh=function(){function n(t,e){this.isRendered=!1,this.isComplexArraySetter=!1,this.isServerRendered=!1,this.allowServerDataBinding=!0,this.isProtectedOnChange=!0,this.properties={},this.changedProperties={},this.oldProperties={},this.bulkChanges={},this.refreshing=!1,this.ignoreCollectionWatch=!1,this.finalUpdate=function(){},this.childChangedProperties={},this.modelObserver=new Tg(this),st(e)||(this.element="string"==typeof e?document.querySelector(e):e,m(this.element)||(this.isProtectedOnChange=!1,this.addInstance())),st(t)||this.setProperties(t,!0),this.isDestroyed=!1}return n.prototype.setProperties=function(t,e){var i=this.isProtectedOnChange;this.isProtectedOnChange=!!e,kn(this,t),!0!==e?(kn(this.changedProperties,t),this.dataBind()):ce()&&this.isRendered&&this.serverDataBind(t),this.finalUpdate(),this.changedProperties={},this.oldProperties={},this.isProtectedOnChange=i},n.callChildDataBind=function(t,e){for(var r=0,s=Object.keys(t);r=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Hs=function(n){function t(i){var r=n.call(this,i,void 0)||this;return r.easing={ease:"cubic-bezier(0.250, 0.100, 0.250, 1.000)",linear:"cubic-bezier(0.250, 0.250, 0.750, 0.750)",easeIn:"cubic-bezier(0.420, 0.000, 1.000, 1.000)",easeOut:"cubic-bezier(0.000, 0.000, 0.580, 1.000)",easeInOut:"cubic-bezier(0.420, 0.000, 0.580, 1.000)",elasticInOut:"cubic-bezier(0.5,-0.58,0.38,1.81)",elasticIn:"cubic-bezier(0.17,0.67,0.59,1.81)",elasticOut:"cubic-bezier(0.7,-0.75,0.99,1.01)"},r}var e;return Q$(t,n),e=t,t.prototype.animate=function(i,r){var s=this.getModel(r=r||{});if("string"==typeof i)for(var a=0,l=Array.prototype.slice.call(we(i,document));a0?r-1:0,i+=e=-1!==e?"-"+e:"-"+r}return this.controlParent!==this.parentObj&&(i=this.parentObj.getParentKey()+"."+this.propName+e),i},n}(),$$=["grid","pivotview","treegrid","spreadsheet","rangeNavigator","DocumentEditor","listbox","inplaceeditor","PdfViewer","richtexteditor","DashboardLayout","chart","stockChart","circulargauge","diagram","heatmap","lineargauge","maps","slider","smithchart","barcode","sparkline","treemap","bulletChart","kanban","daterangepicker","schedule","gantt","signature","query-builder","drop-down-tree","carousel","filemanager","uploader","accordion","tab","treeview"],tR=[115,121,110,99,102,117,115,105,111,110,46,105,115,76,105,99,86,97,108,105,100,97,116,101,100],iR=function(){function n(t){this.isValidated=!1,this.isLicensed=!0,this.version="27",this.platform=/JavaScript|ASPNET|ASPNETCORE|ASPNETMVC|FileFormats|essentialstudio/i,this.errors={noLicense:"This application was built using a trial version of Syncfusion Essential Studio. To remove the license validation message permanently, a valid license key must be included.",trailExpired:"This application was built using a trial version of Syncfusion Essential Studio. To remove the license validation message permanently, a valid license key must be included.",versionMismatched:"The included Syncfusion license key is invalid.",platformMismatched:"The included Syncfusion license key is invalid.",invalidKey:"The included Syncfusion license key is invalid."},this.manager=function(){var e=null;return{setKey:function i(s){e=s},getKey:function r(){return e}}}(),this.npxManager=function(){return{getKey:function i(){return"npxKeyReplace"}}}(),this.manager.setKey(t)}return n.prototype.validate=function(){if(!this.isValidated&&ef&&!Y(D0(tR),ef)&&!Y("Blazor",ef)){var i=void 0,r=void 0;if(this.manager&&this.manager.getKey()||this.npxManager&&"npxKeyReplace"!==this.npxManager.getKey()){var s=this.getInfoFromKey();if(s&&s.length)for(var o=0,a=s;o"+i+' Claim your FREE account\n
have a Syncfusion account? Sign In
\n
\n ';if(typeof document<"u"&&!m(document)){var t=Si("div",{innerHTML:n});document.body.appendChild(t)}}(),oR=!0),this.render(),this.mount?this.accessMount():this.trigger("created")}},t.prototype.renderComplete=function(e){ce()&&window.sfBlazor.renderComplete(this.element,e),this.isRendered=!0},t.prototype.dataBind=function(){this.injectModules(),n.prototype.dataBind.call(this)},t.prototype.on=function(e,i,r){if("string"==typeof e)this.localObserver.on(e,i,r);else for(var s=0,o=e;s=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},tZ={left:0,top:0,bottom:0,right:0},bC={isDragged:!1},iZ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return aR(t,n),gr([I(0)],t.prototype,"left",void 0),gr([I(0)],t.prototype,"top",void 0),t}(Ee),of=function(n){function t(i,r){var s=n.call(this,r,i)||this;return s.dragLimit=e.getDefaultPosition(),s.borderWidth=e.getDefaultPosition(),s.padding=e.getDefaultPosition(),s.diffX=0,s.prevLeft=0,s.prevTop=0,s.dragProcessStarted=!1,s.eleTop=0,s.tapHoldTimer=0,s.externalInitialize=!1,s.diffY=0,s.parentScrollX=0,s.parentScrollY=0,s.droppables={},s.bind(),s}var e;return aR(t,n),e=t,t.prototype.bind=function(){this.toggleEvents(),X.isIE&&V([this.element],"e-block-touch"),this.droppables[this.scope]={}},t.getDefaultPosition=function(){return ze({},tZ)},t.prototype.toggleEvents=function(i){var r;st(this.handle)||(r=_(this.handle,this.element));var s=this.enableTapHold&&X.isDevice&&X.isTouch?this.mobileInitialize:this.initialize;i?E.remove(r||this.element,X.isSafari()?"touchstart":X.touchStartEvent,s):E.add(r||this.element,X.isSafari()?"touchstart":X.touchStartEvent,s,this)},t.prototype.mobileInitialize=function(i){var r=this,s=i.currentTarget;this.tapHoldTimer=setTimeout(function(){r.externalInitialize=!0,r.removeTapholdTimer(),r.initialize(i,s)},this.tapHoldThreshold),E.add(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.removeTapholdTimer,this),E.add(document,X.isSafari()?"touchend":X.touchEndEvent,this.removeTapholdTimer,this)},t.prototype.removeTapholdTimer=function(){clearTimeout(this.tapHoldTimer),E.remove(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.removeTapholdTimer),E.remove(document,X.isSafari()?"touchend":X.touchEndEvent,this.removeTapholdTimer)},t.prototype.getScrollableParent=function(i,r){return m(i)?null:i[{vertical:"scrollHeight",horizontal:"scrollWidth"}[""+r]]>i[{vertical:"clientHeight",horizontal:"clientWidth"}[""+r]]&&("vertical"===r?i.scrollTop>0:i.scrollLeft>0)?("vertical"===r?(this.parentScrollY=this.parentScrollY+(0===this.parentScrollY?i.scrollTop:i.scrollTop-this.parentScrollY),this.tempScrollHeight=i.scrollHeight):(this.parentScrollX=this.parentScrollX+(0===this.parentScrollX?i.scrollLeft:i.scrollLeft-this.parentScrollX),this.tempScrollWidth=i.scrollWidth),m(i)?i:this.getScrollableParent(i.parentNode,r)):this.getScrollableParent(i.parentNode,r)},t.prototype.getScrollableValues=function(){this.parentScrollX=0,this.parentScrollY=0,this.element.classList.contains("e-dialog")&&this.element.classList.contains("e-dlg-modal"),this.getScrollableParent(this.element.parentNode,"vertical"),this.getScrollableParent(this.element.parentNode,"horizontal")},t.prototype.initialize=function(i,r){if(this.currentStateTarget=i.target,!this.isDragStarted()){if(this.isDragStarted(!0),this.externalInitialize=!1,this.target=i.currentTarget||r,this.dragProcessStarted=!1,this.abort){var s=this.abort;"string"==typeof s&&(s=[s]);for(var o=0;o=this.distance||this.externalInitialize){var f=this.getHelperElement(i);if(!f||m(f))return;r&&i.preventDefault();var p=this.helperElement=f;if(this.parentClientRect=this.calculateParentPosition(p.offsetParent),this.dragStart){var v={event:i,element:l,target:this.getProperTargetElement(i),bindEvents:ce()?this.bindDragEvents.bind(this):null,dragElement:p};this.trigger("dragStart",v)}this.dragArea?this.setDragArea():(this.dragLimit={left:0,right:0,bottom:0,top:0},this.borderWidth={top:0,left:0}),o={left:this.position.left-this.parentClientRect.left,top:this.position.top-this.parentClientRect.top},this.clone&&!this.enableTailMode&&(this.diffX=this.position.left-this.offset.left,this.diffY=this.position.top-this.offset.top),this.getScrollableValues();var y=getComputedStyle(l),S=parseFloat(y.marginTop);this.clone&&0!==S&&(o.top+=S),this.eleTop=isNaN(parseFloat(y.top))?0:parseFloat(y.top)-this.offset.top,this.enableScrollHandler&&!this.clone&&(o.top-=this.parentScrollY,o.left-=this.parentScrollX);var b=this.getProcessedPositionValue({top:o.top-this.diffY+"px",left:o.left-this.diffX+"px"});this.dragArea&&"string"!=typeof this.dragArea&&this.dragArea.classList.contains("e-kanban-content")&&"relative"===this.dragArea.style.position&&(o.top+=this.dragArea.scrollTop),this.dragElePosition={top:o.top,left:o.left},je(p,this.getDragPosition({position:"absolute",left:b.left,top:b.top})),E.remove(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.intDragStart),E.remove(document,X.isSafari()?"touchend":X.touchEndEvent,this.intDestroy),ce()||this.bindDragEvents(p)}}},t.prototype.bindDragEvents=function(i){Tr(i)?(E.add(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.intDrag,this),E.add(document,X.isSafari()?"touchend":X.touchEndEvent,this.intDragStop,this),this.setGlobalDroppables(!1,this.element,i)):(this.toggleEvents(),document.body.classList.remove("e-prevent-select"))},t.prototype.elementInViewport=function(i){for(this.top=i.offsetTop,this.left=i.offsetLeft,this.width=i.offsetWidth,this.height=i.offsetHeight;i.offsetParent;)this.top+=(i=i.offsetParent).offsetTop,this.left+=i.offsetLeft;return this.top>=window.pageYOffset&&this.left>=window.pageXOffset&&this.top+this.height<=window.pageYOffset+window.innerHeight&&this.left+this.width<=window.pageXOffset+window.innerWidth},t.prototype.getProcessedPositionValue=function(i){return this.queryPositionInfo?this.queryPositionInfo(i):i},t.prototype.calculateParentPosition=function(i){if(m(i))return{left:0,top:0};var r=i.getBoundingClientRect(),s=getComputedStyle(i);return{left:r.left+window.pageXOffset-parseInt(s.marginLeft,10),top:r.top+window.pageYOffset-parseInt(s.marginTop,10)}},t.prototype.intDrag=function(i){if(st(i.changedTouches)||1===i.changedTouches.length){var r,s;this.clone&&i.changedTouches&&X.isDevice&&X.isTouch&&i.preventDefault(),this.position=this.getMousePosition(i,this.isDragScroll);var o=this.getDocumentWidthHeight("Height");oy&&y>0?this.dragLimit.left:this.dragLimit.right+window.pageXOffset0?y-(y-this.dragLimit.right)+window.pageXOffset-M:y<0?this.dragLimit.left:y}if(this.pageY!==v||this.skipDistanceCheck){var w=d.offsetHeight+(parseFloat(b.marginTop)+parseFloat(b.marginBottom));s=this.dragLimit.top>S&&S>0?this.dragLimit.top:this.dragLimit.bottom+window.pageYOffset0?S-(S-this.dragLimit.bottom)+window.pageYOffset-w:S<0?this.dragLimit.top:S}}else r=y,s=S;var A,x,C=f+this.borderWidth.top,D=u+this.borderWidth.left;if(this.dragProcessStarted&&(m(s)&&(s=this.prevTop),m(r)&&(r=this.prevLeft)),this.helperElement.classList.contains("e-treeview"))this.dragArea?(this.dragLimit.top=this.clone?this.dragLimit.top:0,A=s-C<0?this.dragLimit.top:s-this.borderWidth.top,x=r-D<0?this.dragLimit.left:r-this.borderWidth.left):(A=s-this.borderWidth.top,x=r-this.borderWidth.left);else if(this.dragArea){var P=this.helperElement.classList.contains("e-dialog");this.dragLimit.top=this.clone?this.dragLimit.top:0,A=s-C<0?this.dragLimit.top:s-C,x=r-D<0?P?r-(D-this.borderWidth.left):this.dragElePosition.left:r-D}else A=s-C,x=r-D;var L=parseFloat(getComputedStyle(this.element).marginTop);if(L>0&&(this.clone&&(A+=L,S<0&&(L+S>=0?A=L+S:A-=L),this.dragArea&&(A=this.dragLimit.bottom=0){var O=this.dragLimit.top+S-C;O+L+C<0?A-=L+C:A=O}else A-=L+C;this.dragArea&&this.helperElement.classList.contains("e-treeview")&&(A=A+(w=d.offsetHeight+(parseFloat(b.marginTop)+parseFloat(b.marginBottom)))>this.dragLimit.bottom?this.dragLimit.bottom-w:A),this.enableScrollHandler&&!this.clone&&(A-=this.parentScrollY,x-=this.parentScrollX),this.dragArea&&"string"!=typeof this.dragArea&&this.dragArea.classList.contains("e-kanban-content")&&"relative"===this.dragArea.style.position&&(A+=this.dragArea.scrollTop);var N=this.getProcessedPositionValue({top:A+"px",left:x+"px"});this.isPreventScroll&&(N=this.getProcessedPositionValue({top:this.position.top-this.parentClientRect.top-2+"px",left:this.position.left-this.parentClientRect.left-2+"px"})),je(d,this.getDragPosition(N)),!this.elementInViewport(d)&&this.enableAutoScroll&&!this.helperElement.classList.contains("e-treeview")&&this.helperElement.scrollIntoView();var T=document.querySelectorAll(":hover");if(this.enableAutoScroll&&this.helperElement.classList.contains("e-treeview")){0===T.length&&(T=this.getPathElements(i));var z=this.getScrollParent(T,!1);this.elementInViewport(this.helperElement)?this.getScrollPosition(z,A):this.elementInViewport(this.helperElement)||(0===(T=[].slice.call(document.querySelectorAll(":hover"))).length&&(T=this.getPathElements(i)),z=this.getScrollParent(T,!0),this.getScrollPosition(z,A))}this.dragProcessStarted=!0,this.prevLeft=r,this.prevTop=s,this.position.left=r,this.position.top=s,this.pageX=g,this.pageY=v}},t.prototype.getScrollParent=function(i,r){for(var o,s=r?i.reverse():i,a=s.length-1;a>=0;a--)if(("auto"===(o=window.getComputedStyle(s[parseInt(a.toString(),10)])["overflow-y"])||"scroll"===o)&&s[parseInt(a.toString(),10)].scrollHeight>s[parseInt(a.toString(),10)].clientHeight)return s[parseInt(a.toString(),10)];if("visible"===(o=window.getComputedStyle(document.scrollingElement)["overflow-y"]))return document.scrollingElement.style.overflow="auto",document.scrollingElement},t.prototype.getScrollPosition=function(i,r){if(i&&i===document.scrollingElement)i.clientHeight+document.scrollingElement.scrollTop-this.helperElement.clientHeightr?i.scrollTop+=this.helperElement.clientHeight:i.scrollTop>r-this.helperElement.clientHeight&&(i.scrollTop-=this.helperElement.clientHeight);else if(i&&i!==document.scrollingElement){var s=document.scrollingElement.scrollTop,o=this.helperElement.clientHeight;i.clientHeight+i.getBoundingClientRect().top-o+sr-o-s&&(i.scrollTop-=this.helperElement.clientHeight)}},t.prototype.getPathElements=function(i){return document.elementsFromPoint(i.clientX>0?i.clientX:0,i.clientY>0?i.clientY:0)},t.prototype.triggerOutFunction=function(i,r){this.hoverObject.instance.intOut(i,r.target),this.hoverObject.instance.dragData[this.scope]=null,this.hoverObject=null},t.prototype.getDragPosition=function(i){var r=ze({},i);return this.axis&&("x"===this.axis?delete r.top:"y"===this.axis&&delete r.left),r},t.prototype.getDocumentWidthHeight=function(i){var r=document.body,s=document.documentElement;return Math.max(r["scroll"+i],s["scroll"+i],r["offset"+i],s["offset"+i],s["client"+i])},t.prototype.intDragStop=function(i){if(this.dragProcessStarted=!1,st(i.changedTouches)||1===i.changedTouches.length){if(-1!==["touchend","pointerup","mouseup"].indexOf(i.type)){if(this.dragStop){var s=this.getProperTargetElement(i);this.trigger("dragStop",{event:i,element:this.element,target:s,helper:this.helperElement})}this.intDestroy(i)}else this.element.setAttribute("aria-grabbed","false");var o=this.checkTargetElement(i);o.target&&o.instance&&(o.instance.dragStopCalled=!0,o.instance.dragData[this.scope]=this.droppables[this.scope],o.instance.intDrop(i,o.target)),this.setGlobalDroppables(!0),document.body.classList.remove("e-prevent-select")}},t.prototype.intDestroy=function(i){this.dragProcessStarted=!1,this.toggleEvents(),document.body.classList.remove("e-prevent-select"),this.element.setAttribute("aria-grabbed","false"),E.remove(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.intDragStart),E.remove(document,X.isSafari()?"touchend":X.touchEndEvent,this.intDragStop),E.remove(document,X.isSafari()?"touchend":X.touchEndEvent,this.intDestroy),E.remove(document,X.isSafari()?"touchmove":X.touchMoveEvent,this.intDrag),this.isDragStarted()&&this.isDragStarted(!0)},t.prototype.onPropertyChanged=function(i,r){},t.prototype.getModuleName=function(){return"draggable"},t.prototype.isDragStarted=function(i){return i&&(bC.isDragged=!bC.isDragged),bC.isDragged},t.prototype.setDragArea=function(){var i,r,a,s=0,o=0;if(a="string"==typeof this.dragArea?_(this.dragArea):this.dragArea){var h=a.getBoundingClientRect();i=a.scrollWidth?a.scrollWidth:h.right-h.left,r=a.scrollHeight?this.dragArea&&!m(this.helperElement)&&this.helperElement.classList.contains("e-treeview")?a.clientHeight:a.scrollHeight:h.bottom-h.top;for(var c=["Top","Left","Bottom","Right"],d=getComputedStyle(a),u=0;u12;return M0(i.target,this.helperElement)||-1!==i.type.indexOf("touch")||a?(this.helperElement.style.pointerEvents="none",s=document.elementFromPoint(r.clientX,r.clientY),this.helperElement.style.pointerEvents=o):s=i.target,s},t.prototype.currentStateCheck=function(i,r){return m(this.currentStateTarget)||this.currentStateTarget===i?m(r)?i:r:this.currentStateTarget},t.prototype.getMousePosition=function(i,r){var a,l,s=void 0!==i.srcElement?i.srcElement:i.target,o=this.getCoordinates(i),h=m(s.offsetParent);if(r?(a=this.clone?o.pageX:o.pageX+(h?0:s.offsetParent.scrollLeft)-this.relativeXPosition,l=this.clone?o.pageY:o.pageY+(h?0:s.offsetParent.scrollTop)-this.relativeYPosition):(a=this.clone?o.pageX:o.pageX+window.pageXOffset-this.relativeXPosition,l=this.clone?o.pageY:o.pageY+window.pageYOffset-this.relativeYPosition),document.scrollingElement&&!r&&!this.clone){var c=document.scrollingElement;a=c.scrollWidth>0&&c.scrollWidth>c.clientWidth&&c.scrollLeft>0?a-c.scrollLeft:a,l=c.scrollHeight>0&&c.scrollHeight>c.clientHeight&&c.scrollTop>0?l-c.scrollTop:l}return{left:a-(this.margin.left+this.cursorAt.left),top:l-(this.margin.top+this.cursorAt.top)}},t.prototype.getCoordinates=function(i){return i.type.indexOf("touch")>-1?i.changedTouches[0]:i},t.prototype.getHelperElement=function(i){var r;return this.clone?this.helper?r=this.helper({sender:i,element:this.target}):(r=Si("div",{className:"e-drag-helper e-block-touch",innerHTML:"Draggable"}),document.body.appendChild(r)):r=this.element,r},t.prototype.setGlobalDroppables=function(i,r,s){this.droppables[this.scope]=i?null:{draggable:r,helper:s,draggedElement:this.element}},t.prototype.checkTargetElement=function(i){var r=this.getProperTargetElement(i),s=this.getDropInstance(r);if(!s&&r&&!m(r.parentNode)){var o=J(r.parentNode,".e-droppable")||r.parentElement;o&&(s=this.getDropInstance(o))}return{target:r,instance:s}},t.prototype.getDropInstance=function(i){var s,o=i&&i.ej2_instances;if(o)for(var a=0,l=o;a=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},lR=function(n){function t(e,i){var r=n.call(this,i,e)||this;return r.mouseOver=!1,r.dragData={},r.dragStopCalled=!1,r.bind(),r}return rZ(t,n),t.prototype.bind=function(){this.wireEvents()},t.prototype.wireEvents=function(){E.add(this.element,X.isSafari()?"touchend":X.touchEndEvent,this.intDrop,this)},t.prototype.onPropertyChanged=function(e,i){},t.prototype.getModuleName=function(){return"droppable"},t.prototype.intOver=function(e,i){this.mouseOver||(this.trigger("over",{event:e,target:i,dragData:this.dragData[this.scope]}),this.mouseOver=!0)},t.prototype.intOut=function(e,i){this.mouseOver&&(this.trigger("out",{evt:e,target:i}),this.mouseOver=!1)},t.prototype.intDrop=function(e,i){if(this.dragStopCalled){this.dragStopCalled=!1;var a,r=!0,s=this.dragData[this.scope],o=!!s&&s.helper&&Tr(s.helper);o&&(a=this.isDropArea(e,s.helper,i),this.accept&&(r=vC(s.helper,this.accept))),o&&this.drop&&a.canDrop&&r&&this.trigger("drop",{event:e,target:a.target,droppedElement:s.helper,dragData:s}),this.mouseOver=!1}},t.prototype.isDropArea=function(e,i,r){var s={canDrop:!0,target:r||e.target},o="touchend"===e.type;if(o||s.target===i){i.style.display="none";var a=o?e.changedTouches[0]:e,l=document.elementFromPoint(a.clientX,a.clientY);s.canDrop=!1,s.canDrop=M0(l,this.element),s.canDrop&&(s.target=l),i.style.display=""}return s},t.prototype.destroy=function(){E.remove(this.element,X.isSafari()?"touchend":X.touchEndEvent,this.intDrop),n.prototype.destroy.call(this)},af([I()],t.prototype,"accept",void 0),af([I("default")],t.prototype,"scope",void 0),af([H()],t.prototype,"drop",void 0),af([H()],t.prototype,"over",void 0),af([H()],t.prototype,"out",void 0),af([Ft],t)}(dh),uo=function(){function n(t,e,i){this.controlName=t,this.localeStrings=e,this.setLocale(i||"en-US")}return n.prototype.setLocale=function(t){var e=this.intGetControlConstant(n.locale,t);this.currentLocale=e||this.localeStrings},n.load=function(t){this.locale=ze(this.locale,t,{},!0)},n.prototype.getConstant=function(t){return m(this.currentLocale[""+t])?this.localeStrings[""+t]||"":this.currentLocale[""+t]},n.prototype.intGetControlConstant=function(t,e){return t[""+e]?t[""+e][this.controlName]:null},n.locale={},n}(),hR=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),fh=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},oZ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return hR(t,n),fh([I(50)],t.prototype,"swipeThresholdDistance",void 0),t}(Ee),aZ=/(Up|Down)/,Fs=function(n){function t(e,i){var r=n.call(this,i,e)||this;return r.touchAction=!0,r.tapCount=0,r.startEvent=function(s){if(!0===r.touchAction){var o=r.updateChangeTouches(s);void 0!==s.changedTouches&&(r.touchAction=!1),r.isTouchMoved=!1,r.movedDirection="",r.startPoint=r.lastMovedPoint={clientX:o.clientX,clientY:o.clientY},r.startEventData=o,r.hScrollLocked=r.vScrollLocked=!1,r.tStampStart=Date.now(),r.timeOutTapHold=setTimeout(function(){r.tapHoldEvent(s)},r.tapHoldThreshold),E.add(r.element,X.touchMoveEvent,r.moveEvent,r),E.add(r.element,X.touchEndEvent,r.endEvent,r),E.add(r.element,X.touchCancelEvent,r.cancelEvent,r)}},r.moveEvent=function(s){var o=r.updateChangeTouches(s);r.movedPoint=o,r.isTouchMoved=!(o.clientX===r.startPoint.clientX&&o.clientY===r.startPoint.clientY);var a={};r.isTouchMoved&&(clearTimeout(r.timeOutTapHold),r.calcScrollPoints(s),a=ze(a,{},{startEvents:r.startEventData,originalEvent:s,startX:r.startPoint.clientX,startY:r.startPoint.clientY,distanceX:r.distanceX,distanceY:r.distanceY,scrollDirection:r.scrollDirection,velocity:r.getVelocity(o)}),r.trigger("scroll",a),r.lastMovedPoint={clientX:o.clientX,clientY:o.clientY})},r.cancelEvent=function(s){clearTimeout(r.timeOutTapHold),clearTimeout(r.timeOutTap),r.tapCount=0,r.swipeFn(s),E.remove(r.element,X.touchCancelEvent,r.cancelEvent)},r.endEvent=function(s){r.swipeFn(s),r.isTouchMoved||"function"==typeof r.tap&&(r.trigger("tap",{originalEvent:s,tapCount:++r.tapCount}),r.timeOutTap=setTimeout(function(){r.tapCount=0},r.tapThreshold)),r.modeclear()},r.swipeFn=function(s){clearTimeout(r.timeOutTapHold),clearTimeout(r.timeOutTap);var o=r.updateChangeTouches(s),a=o.clientX-r.startPoint.clientX,l=o.clientY-r.startPoint.clientY;a=Math.floor(a<0?-1*a:a),l=Math.floor(l<0?-1*l:a),r.isTouchMoved=a>1||l>1,/Firefox/.test(X.userAgent)&&0===o.clientX&&0===o.clientY&&"mouseup"===s.type&&(r.isTouchMoved=!1),r.endPoint=o,r.calcPoints(s);var c={originalEvent:s,startEvents:r.startEventData,startX:r.startPoint.clientX,startY:r.startPoint.clientY,distanceX:r.distanceX,distanceY:r.distanceY,swipeDirection:r.movedDirection,velocity:r.getVelocity(o)};if(r.isTouchMoved){var d=r.swipeSettings.swipeThresholdDistance,u=ze(void 0,r.defaultArgs,c),f=!1,p=r.element,g=r.isScrollable(p),v=aZ.test(r.movedDirection);(dthis.distanceY?i.clientX>this.startPoint.clientX?"Right":"Left":i.clientYthis.distanceY||!0===this.hScrollLocked)&&!1===this.vScrollLocked?(this.scrollDirection=i.clientX>this.lastMovedPoint.clientX?"Right":"Left",this.hScrollLocked=!0):(this.scrollDirection=i.clientY=e[r[0]+s[0]]},t.prototype.updateChangeTouches=function(e){return e.changedTouches&&0!==e.changedTouches.length?e.changedTouches[0]:e},fh([H()],t.prototype,"tap",void 0),fh([H()],t.prototype,"tapHold",void 0),fh([H()],t.prototype,"swipe",void 0),fh([H()],t.prototype,"scroll",void 0),fh([I(350)],t.prototype,"tapThreshold",void 0),fh([I(750)],t.prototype,"tapHoldThreshold",void 0),fh([re({},oZ)],t.prototype,"swipeSettings",void 0),fh([Ft],t)}(dh),lZ=new RegExp("\\n|\\r|\\s\\s+","g"),hZ=new RegExp(/'|"/g),cZ=new RegExp("if ?\\("),dZ=new RegExp("else if ?\\("),cR=new RegExp("else"),uZ=new RegExp("for ?\\("),dR=new RegExp("(/if|/for)"),fZ=new RegExp("\\((.*)\\)",""),MC=new RegExp("^[0-9]+$","g"),pZ=new RegExp("[\\w\"'.\\s+]+","g"),gZ=new RegExp('"(.*?)"',"g"),vZ=new RegExp("[\\w\"'@#$.\\s-+]+","g"),uR=new RegExp("\\${([^}]*)}","g"),mZ=/^\..*/gm,wC=/\\/gi,yZ=/\\\\/gi,SZ=new RegExp("[\\w\"'@#$.\\s+]+","g"),IZ=/\window\./gm;function lf(n,t,e,i,r){return!t||MC.test(n)||-1!==i.indexOf(n.split(".")[0])||r||"true"===n||"false"===n?n:e+"."+n}function CC(n,t,e,i){return t&&!MC.test(n)&&-1===i.indexOf(n.split(".")[0])?e+'["'+n:n}function fR(n){return n.match(yZ)?n:n.replace(wC,"\\\\")}function pR(n,t,e,i){if(n=n.trim(),/\window\./gm.test(n))return n;var s=/'|"/gm;return/@|\$|#/gm.test(n)&&(n=CC(n,-1===e.indexOf(n),t,e)+'"]'),mZ.test(n)?function wZ(n,t,e,i){return!t||MC.test(n)||-1!==i.indexOf(n.split(".")[0])||/^\..*/gm.test(n)?n:e+"."+n}(n,!s.test(n)&&-1===e.indexOf(n),t,e):lf(n,!s.test(n)&&-1===e.indexOf(n),t,e,i)}var CZ=/^[\n\r.]+0&&t.forEach(function(e){he(e)})},n.removeJsEvents=function(){var t=this.wrapElement.querySelectorAll("["+vR.join("],[")+"]");t.length>0&&t.forEach(function(e){vR.forEach(function(i){e.hasAttribute(i)&&e.removeAttribute(i)})})},n.removeXssAttrs=function(){var t=this;this.removeAttrs.forEach(function(e,i){var r=t.wrapElement.querySelectorAll(e.selector);r.length>0&&r.forEach("a[href]"===e.selector?function(s){-1!==s.getAttribute(e.attribute).replace(/\t|\s|&/,"").indexOf("javascript:alert")&&s.removeAttribute(e.attribute)}:function(s){s.removeAttribute(e.attribute)})})},n}();function NZ(n){for(var t,e=n.childNodes,i=0;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Jo_RTL=(new Tg,"e-rtl"),ys=function(n){function t(e,i){return n.call(this,e,i)||this}return PZ(t,n),t.prototype.preRender=function(){},t.prototype.render=function(){this.initialize(),this.removeRippleEffect=function ms(n,t,e){var i=function G$(n){return{selector:n&&n.selector?n.selector:null,ignore:n&&n.ignore?n.ignore:null,rippleFlag:n&&n.rippleFlag,isCenterRipple:n&&n.isCenterRipple,duration:n&&n.duration?n.duration:350}}(t);return!1===i.rippleFlag||void 0===i.rippleFlag&&!Zo?function(){}:(n.setAttribute("data-ripple","true"),E.add(n,"mousedown",Zz,{parent:n,rippleOptions:i}),E.add(n,"mouseup",Jz,{parent:n,rippleOptions:i,done:e}),E.add(n,"mouseleave",sf,{parent:n,rippleOptions:i}),X.isPointer&&E.add(n,"transitionend",sf,{parent:n,rippleOptions:i}),function(){n.removeAttribute("data-ripple"),E.remove(n,"mousedown",Zz),E.remove(n,"mouseup",Jz),E.remove(n,"mouseleave",sf),E.remove(n,"transitionend",sf)})}(this.element,{selector:".e-btn"}),this.renderComplete()},t.prototype.initialize=function(){if(this.cssClass&&V([this.element],this.cssClass.replace(/\s+/g," ").trim().split(" ")),this.isPrimary&&this.element.classList.add("e-primary"),!ce()||ce()&&"progress-btn"!==this.getModuleName()){if(this.content){var e=this.enableHtmlSanitizer?Ai.sanitize(this.content):this.content;this.element.innerHTML=e}this.setIconCss()}this.enableRtl&&this.element.classList.add(Jo_RTL),this.disabled?this.controlStatus(this.disabled):this.wireEvents()},t.prototype.controlStatus=function(e){this.element.disabled=e},t.prototype.setIconCss=function(){if(this.iconCss){var e=this.createElement("span",{className:"e-btn-icon "+this.iconCss});this.element.textContent.trim()?(e.classList.add("e-icon-"+this.iconPosition.toLowerCase()),("Top"===this.iconPosition||"Bottom"===this.iconPosition)&&this.element.classList.add("e-"+this.iconPosition.toLowerCase()+"-icon-btn")):this.element.classList.add("e-icon-btn");var i=this.element.childNodes[0];!i||"Left"!==this.iconPosition&&"Top"!==this.iconPosition?this.element.appendChild(e):this.element.insertBefore(e,i)}},t.prototype.wireEvents=function(){this.isToggle&&E.add(this.element,"click",this.btnClickHandler,this)},t.prototype.unWireEvents=function(){this.isToggle&&E.remove(this.element,"click",this.btnClickHandler)},t.prototype.btnClickHandler=function(){this.element.classList.contains("e-active")?this.element.classList.remove("e-active"):this.element.classList.add("e-active")},t.prototype.destroy=function(){var e=["e-primary",Jo_RTL,"e-icon-btn","e-success","e-info","e-danger","e-warning","e-flat","e-outline","e-small","e-bigger","e-active","e-round","e-top-icon-btn","e-bottom-icon-btn"];this.cssClass&&(e=e.concat(this.cssClass.split(" "))),n.prototype.destroy.call(this),K([this.element],e),this.element.getAttribute("class")||this.element.removeAttribute("class"),this.disabled&&this.element.removeAttribute("disabled"),this.content&&(this.element.innerHTML=this.element.innerHTML.replace(this.content,""));var i=this.element.querySelector("span.e-btn-icon");i&&he(i),this.unWireEvents(),Zo&&this.removeRippleEffect()},t.prototype.getModuleName=function(){return"btn"},t.prototype.getPersistData=function(){return this.addOnPersist([])},t.Inject=function(){},t.prototype.onPropertyChanged=function(e,i){for(var r=this.element.querySelector("span.e-btn-icon"),s=0,o=Object.keys(e);s=ad.width?ad.width:0;return yl.right+QR()-n}function hE(){return H0()+yl.width/2}function cE(n,t,e,i){if(void 0===t&&(t=null),void 0===e&&(e={X:!1,Y:!1}),!e.Y&&!e.X)return{left:0,top:0};var r=n.getBoundingClientRect();if(po=t,oc=n.ownerDocument,i||(i=ns(n,"left","top")),e.X){var s=po?ZR():i4(),o=gE(),a=vE(),l=o-i.left,h=i.left+r.width-a;r.width>s?i.left=l>0&&h<=0?a-r.width:h>0&&l<=0?o:l>h?a-r.width:o:l>0?i.left+=l:h>0&&(i.left-=h)}if(e.Y){var c=po?JR():t4(),d=pE(),u=mE(),f=d-i.top,p=i.top+r.height-u;r.height>c?i.top=f>0&&p<=0?u-r.height:p>0&&f<=0?d:f>p?u-r.height:d:f>0?i.top+=f:p>0&&(i.top-=p)}return i}function ac(n,t,e,i){void 0===t&&(t=null);var r=ns(n,"left","top");e&&(r.left=e),i&&(r.top=i);var s=[];po=t,oc=n.ownerDocument;var o=n.getBoundingClientRect(),l=r.left,h=r.left+o.width,d=fE(r.top,r.top+o.height),u=XR(l,h);return d.topSide&&s.push("top"),u.rightSide&&s.push("right"),u.leftSide&&s.push("left"),d.bottomSide&&s.push("bottom"),s}function cJ(n,t,e,i,r,s,o,a,l){if(void 0===o&&(o=null),void 0===a&&(a={X:!0,Y:!0}),t&&n&&r&&s&&(a.X||a.Y)){var d,h={TL:null,TR:null,BL:null,BR:null},c={TL:null,TR:null,BL:null,BR:null};if("none"===window.getComputedStyle(n).display){var u=n.style.visibility;n.style.visibility="hidden",n.style.display="block",d=n.getBoundingClientRect(),n.style.removeProperty("display"),n.style.visibility=u}else d=n.getBoundingClientRect();var f={posX:r,posY:s,offsetX:e,offsetY:i,position:{left:0,top:0}};po=o,oc=t.ownerDocument,function uJ(n,t,e,i,r){e.position=ns(n,e.posX,e.posY,i,r),t.TL=ns(n,"left","top",i,r),t.TR=ns(n,"right","top",i,r),t.BR=ns(n,"left","bottom",i,r),t.BL=ns(n,"right","bottom",i,r)}(t,h,f,l,d),uE(c,f,d),a.X&&qR(t,c,h,f,d,!0),a.Y&&h.TL.top>-1&&$R(t,c,h,f,d,!0),function dJ(n,t,e){var i=0,r=0;if(null!=n.offsetParent&&("absolute"===getComputedStyle(n.offsetParent).position||"relative"===getComputedStyle(n.offsetParent).position)){var s=ns(n.offsetParent,"left","top",!1,e);i=s.left,r=s.top}var o=1,a=1,l=GR(n);if(l){var h=getComputedStyle(l).transform;if("none"!==h){var c=new DOMMatrix(h);o=c.a,a=c.d}if("none"!==getComputedStyle(l).zoom){var u=dE(document.body);o*=u,a*=u}}n.style.top=t.position.top/a+t.offsetY-r/a+"px",n.style.left=t.position.left/o+t.offsetX-i/o+"px"}(n,f,d)}}function dE(n){var t=getComputedStyle(n).zoom;return parseFloat(t)||1}function GR(n){for(;n;){var t=window.getComputedStyle(n).transform,e=dE(document.body);if(t&&"none"!==t||e&&1!==e)return n;if(n===document.body)return null;n=n.offsetParent||n.parentElement}return null}function uE(n,t,e){n.TL={top:t.position.top+t.offsetY,left:t.position.left+t.offsetX},n.TR={top:n.TL.top,left:n.TL.left+e.width},n.BL={top:n.TL.top+e.height,left:n.TL.left},n.BR={top:n.TL.top+e.height,left:n.TL.left+e.width}}function XR(n,t){var e=!1,i=!1;return n-F0()vE()&&(i=!0),{leftSide:e,rightSide:i}}function qR(n,t,e,i,r,s){var o=XR(t.TL.left,t.TR.left),a=fE(t.TL.top,t.BL.top);e.TL.left-F0()<=gE()&&(o.leftSide=!1),e.TR.left>vE()&&(o.rightSide=!1),(o.leftSide&&!o.rightSide||!o.leftSide&&o.rightSide)&&(i.posX="right"===i.posX?"left":"right",i.offsetX=i.offsetX+r.width,i.offsetX=-1*i.offsetX,i.position=ns(n,i.posX,i.posY,!1),uE(t,i,r),s&&qR(n,t,e,i,r,!1),!o.leftSide&&o.rightSide&&a.bottomSide&&(i.offsetX=0))}function $R(n,t,e,i,r,s){var o=fE(t.TL.top,t.BL.top);e.TL.top-B0()<=pE()&&(o.topSide=!1),e.BL.top>=mE()&&n.getBoundingClientRect().bottommE()&&(i=!0),{topSide:e,bottomSide:i}}function ZR(){return po.getBoundingClientRect().width}function JR(){return po.getBoundingClientRect().height}function KR(){return po.getBoundingClientRect().left}function e4(){return po.getBoundingClientRect().top}function pE(){return po?e4():0}function gE(){return po?KR():0}function vE(){return po?F0()+KR()+ZR():F0()+i4()}function mE(){return po?B0()+e4()+JR():B0()+t4()}function B0(){return oc.documentElement.scrollTop||oc.body.scrollTop}function F0(){return oc.documentElement.scrollLeft||oc.body.scrollLeft}function t4(){return window.innerHeight}function i4(){var n=window.innerWidth,t=document.documentElement.getBoundingClientRect();return n-(n-(m(document.documentElement)?0:t.width))}function r4(){po=null,oc=null}var n4=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),bn=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},s4=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return n4(t,n),bn([I("left")],t.prototype,"X",void 0),bn([I("top")],t.prototype,"Y",void 0),t}(Ee),qn_OPEN="e-popup-open",qn_CLOSE="e-popup-close",lc=function(n){function t(e,i){return n.call(this,i,e)||this}return n4(t,n),t.prototype.onPropertyChanged=function(e,i){for(var r=0,s=Object.keys(e);r0&&c.left>0&&c.right>0&&c.bottom>0}var s=i.getBoundingClientRect();return!(r.bottoms.bottom||r.right>s.right||r.leftr.top?this.element.style.top="0px":s.bottomr.left&&(this.element.style.left=parseInt(this.element.style.left,10)+(s.left-r.left)+"px"))}},t.prototype.checkCollision=function(){var e=this.collision.X,i=this.collision.Y;"none"===e&&"none"===i||("flip"===e&&"flip"===i?this.callFlip({X:!0,Y:!0}):"fit"===e&&"fit"===i?this.callFit({X:!0,Y:!0}):("flip"===e?this.callFlip({X:!0,Y:!1}):"flip"===i&&this.callFlip({Y:!0,X:!1}),"fit"===e?this.callFit({X:!0,Y:!1}):"fit"===i&&this.callFit({X:!1,Y:!0})))},t.prototype.show=function(e,i){var r=this;if(this.getRelateToElement().classList.contains("e-filemanager")&&(this.fmDialogContainer=this.element.getElementsByClassName("e-file-select-wrap")[0]),this.wireEvents(),!m(this.fmDialogContainer)&&X.isIos&&(this.fmDialogContainer.style.display="block"),1e3===this.zIndex||!m(i)){var o=m(i)?this.element:i;this.zIndex=hc(o),je(this.element,{zIndex:this.zIndex})}e=m(e)||"object"!=typeof e?this.showAnimation:e,("none"!==this.collision.X||"none"!==this.collision.Y)&&(K([this.element],qn_CLOSE),V([this.element],qn_OPEN),this.checkCollision(),K([this.element],qn_OPEN),V([this.element],qn_CLOSE)),m(e)?(K([this.element],qn_CLOSE),V([this.element],qn_OPEN),this.trigger("open")):(e.begin=function(){r.isDestroyed||(K([r.element],qn_CLOSE),V([r.element],qn_OPEN))},e.end=function(){r.isDestroyed||r.trigger("open")},new Hs(e).animate(this.element))},t.prototype.hide=function(e){var i=this;e=m(e)||"object"!=typeof e?this.hideAnimation:e,m(e)?(K([this.element],qn_OPEN),V([this.element],qn_CLOSE),this.trigger("close")):(e.end=function(){i.isDestroyed||(K([i.element],qn_OPEN),V([i.element],qn_CLOSE),i.trigger("close"))},new Hs(e).animate(this.element)),this.unwireEvents()},t.prototype.getScrollableParent=function(e){return this.checkFixedParent(e),function yE(n,t){for(var e=getComputedStyle(n),i=[],r=/(auto|scroll)/,s=n.parentElement;s&&"HTML"!==s.tagName;){var o=getComputedStyle(s);!("absolute"===e.position&&"static"===o.position)&&r.test(o.overflow+o.overflowY+o.overflowX)&&i.push(s),s=s.parentElement}return t||i.push(document),i}(e,this.fixedParent)},t.prototype.checkFixedParent=function(e){for(var i=e.parentElement;i&&"HTML"!==i.tagName;){var r=getComputedStyle(i);("fixed"===r.position||"sticky"===r.position)&&!m(this.element)&&this.element.offsetParent&&"BODY"===this.element.offsetParent.tagName&&"hidden"!==getComputedStyle(this.element.offsetParent).overflow&&(this.element.style.top=window.scrollY>parseInt(this.element.style.top,10)?Re(window.scrollY-parseInt(this.element.style.top,10)):Re(parseInt(this.element.style.top,10)-window.scrollY),this.element.style.position="fixed",this.fixedParent=!0),i=i.parentElement,!m(this.element)&&m(this.element.offsetParent)&&"fixed"===r.position&&"fixed"===this.element.style.position&&(this.fixedParent=!0)}},bn([I("auto")],t.prototype,"height",void 0),bn([I("auto")],t.prototype,"width",void 0),bn([I(null)],t.prototype,"content",void 0),bn([I("container")],t.prototype,"targetType",void 0),bn([I(null)],t.prototype,"viewPortElement",void 0),bn([I({X:"none",Y:"none"})],t.prototype,"collision",void 0),bn([I("")],t.prototype,"relateTo",void 0),bn([re({},s4)],t.prototype,"position",void 0),bn([I(0)],t.prototype,"offsetX",void 0),bn([I(0)],t.prototype,"offsetY",void 0),bn([I(1e3)],t.prototype,"zIndex",void 0),bn([I(!1)],t.prototype,"enableRtl",void 0),bn([I("reposition")],t.prototype,"actionOnScroll",void 0),bn([I(null)],t.prototype,"showAnimation",void 0),bn([I(null)],t.prototype,"hideAnimation",void 0),bn([H()],t.prototype,"open",void 0),bn([H()],t.prototype,"close",void 0),bn([H()],t.prototype,"targetExitViewport",void 0),bn([Ft],t)}(Ii);function hc(n){for(var t=n.parentElement,e=[];t&&"BODY"!==t.tagName;){var i=document.defaultView.getComputedStyle(t,null).getPropertyValue("z-index"),r=document.defaultView.getComputedStyle(t,null).getPropertyValue("position");"auto"!==i&&"static"!==r&&e.push(i),t=t.parentElement}for(var s=[],o=0;o2147483647?2147483647:c}var Ui,ka,hf,yh,ME,Sh,Zt,Ih,SE=["north-west","north","north-east","west","east","south-west","south","south-east"],jg="e-resize-handle",cc="e-focused-handle",fJ="e-dlg-resizable",o4=["e-restrict-left"],a4="e-resize-viewport",pJ=["north","west","east","south"],IE=0,bE=0,l4=0,h4=0,Vg=0,Wg=0,Yg=null,wE=null,CE=null,_0=!0,c4=0,EE=!0;function vJ(n){DE();var t=Si("span",{attrs:{unselectable:"on",contenteditable:"false"}});t.setAttribute("class","e-dialog-border-resize e-"+n),"south"===n&&(t.style.height="2px",t.style.width="100%",t.style.bottom="0px",t.style.left="0px"),"north"===n&&(t.style.height="2px",t.style.width="100%",t.style.top="0px",t.style.left="0px"),"east"===n&&(t.style.height="100%",t.style.width="2px",t.style.right="0px",t.style.top="0px"),"west"===n&&(t.style.height="100%",t.style.width="2px",t.style.left="0px",t.style.top="0px"),Ui.appendChild(t)}function d4(n){var t;return m(n)||(t="string"==typeof n?document.querySelector(n):n),t}function u4(n){for(var t=n||this,e=Ui.querySelectorAll("."+jg),i=0;i-1?"mouse":"touch"}function p4(n){if(n.preventDefault(),Ui=n.target.parentElement,DE(),Vg=n.pageX,Wg=n.pageY,n.target.classList.add(cc),m(Yg)||!0!==Yg(n,this)){this.targetEle&&Ui&&Ui.querySelector("."+fJ)&&(Zt="body"===this.target?null:this.targetEle,Sh=this.targetEle.clientWidth,yh=this.targetEle.clientHeight);var e=m(Zt)?document:Zt;E.add(e,"mousemove",Qg,this),E.add(document,"mouseup",U0,this);for(var i=0;i=0||s.top<0)&&(e=!0):e=!0;var a=bE+(r-Wg);a=a>hf?a:hf;var l=0;m(Zt)||(l=o.top);var h=m(Zt)?0:Zt.offsetHeight-Zt.clientHeight,c=s.top-l-h/2;if(c=c<0?0:c,s.top>0&&c+a>yh){if(e=!1,Ui.classList.contains(a4))return;Ui.style.height=yh-parseInt(c.toString(),10)+"px"}else{var d=0;if(e){s.top<0&&t+(s.height+s.top)>0&&a+(d=s.top)<=30&&(a=s.height-(s.height+s.top)+30),a+s.top>=yh&&(Ui.style.height=s.height+(t-(s.height+s.top))+"px");var u=m(Zt)?d:c;a>=hf&&a+u<=yh&&(Ui.style.height=a+"px")}}}function TE(n){var e,t=!1,i="mouse"===f4(n.type)?n.pageY:n.touches[0].pageY,r=dc(Ui),s=m(Zt)?0:Zt.offsetHeight-Zt.clientHeight;m(Zt)||(e=dc(Zt)),(!m(Zt)&&r.top-e.top>0||m(Zt)&&i>0||!m(Zt)&&Math.floor(r.top-e.top+r.height+(e.bottom-r.bottom))-s<=yh)&&(t=!0);var o=bE-(i-Wg);if(t&&o>=hf&&o<=yh){var a=0;m(Zt)||(a=e.top);var l=h4-a+(i-Wg);l=l>0?l:1,Ui.style.height=o+"px",Ui.style.top=l+"px"}}function AE(n){var i,t=document.documentElement.clientWidth,e=!1;m(Zt)||(i=dc(Zt));var r="mouse"===f4(n.type)?n.pageX:n.touches[0].pageX,s=dc(Ui),o=m(Zt)?0:Zt.offsetWidth-Zt.clientWidth,a=m(Zt)?0:i.left,l=m(Zt)?0:i.width;m(Ih)&&(m(Zt)?Ih=t:(Ih=s.left-a-o/2+s.width,Ih+=l-o-Ih)),(!m(Zt)&&Math.floor(s.left-i.left+s.width+(i.right-s.right))-o<=Sh||m(Zt)&&r>=0)&&(e=!0);var h=IE-(r-Vg);if(_0&&(h=h>Ih?Ih:h),e&&h>=ME&&h<=Sh){var c=0;m(Zt)||(c=i.left);var d=l4-c+(r-Vg);d=d>0?d:1,h!==c4&&EE&&(Ui.style.width=h+"px"),_0&&(Ui.style.left=d+"px",EE=1!==d)}c4=h}function LE(n){var i,t=document.documentElement.clientWidth,e=!1;m(Zt)||(i=dc(Zt));var s=(n.touches?n.changedTouches[0]:n).pageX,o=dc(Ui);(!m(Zt)&&(o.left-i.left+o.width<=Sh||o.right-i.left>=o.width)||m(Zt)&&t-s>0)&&(e=!0);var a=IE+(s-Vg),l=0;if(m(Zt)||(l=i.left),o.left-l+a>Sh){if(e=!1,Ui.classList.contains(a4))return;Ui.style.width=Sh-(o.left-l)+"px"}e&&a>=ME&&a<=Sh&&(Ui.style.width=a+"px")}function v4(){for(var n=Ui.querySelectorAll("."+jg),t=0;t=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},bJ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return NE(t,n),Jt([I(!0)],t.prototype,"isFlat",void 0),Jt([I()],t.prototype,"buttonModel",void 0),Jt([I("Button")],t.prototype,"type",void 0),Jt([H()],t.prototype,"click",void 0),t}(Ee),MJ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return NE(t,n),Jt([I("Fade")],t.prototype,"effect",void 0),Jt([I(400)],t.prototype,"duration",void 0),Jt([I(0)],t.prototype,"delay",void 0),t}(Ee),j0="e-dialog",OE="e-rtl",kE="e-dlg-header-content",m4="e-dlg-header",V0="e-footer-content",W0="e-dlg-modal",y4="e-icon-dlg-close",Pa="e-dlg-target",ea="e-scroll-disabled",S4="e-device",Y0="e-dlg-fullscreen",I4="e-dlg-closeicon-btn",b4="e-popup-open",M4="Information",w4="e-scroll-disabled",C4="e-alert-dialog",E4="e-confirm-dialog",PE="e-dlg-resizable",cf="e-restrict-left",D4="e-resize-viewport",zE="user action",zJ=function(n){function t(e,i){var r=n.call(this,e,i)||this;return r.needsID=!0,r}return NE(t,n),t.prototype.render=function(){this.initialize(),this.initRender(),this.wireEvents(),"100%"===this.width&&(this.element.style.width=""),""!==this.minHeight&&(this.element.style.minHeight=Re(this.minHeight)),this.enableResize&&(this.setResize(),this.isModal&&(this.isModelResize=!0),"None"===this.animationSettings.effect&&this.getMinHeight()),this.renderComplete()},t.prototype.initializeValue=function(){this.dlgClosedBy=zE},t.prototype.preRender=function(){var e=this;if(this.initializeValue(),this.headerContent=null,this.allowMaxHeight=!0,this.preventVisibility=!0,this.clonedEle=this.element.cloneNode(!0),this.closeIconClickEventHandler=function(s){e.dlgClosedBy="close icon",e.hide(s)},this.dlgOverlayClickEventHandler=function(s){e.dlgClosedBy="overlayClick",s.preventFocus=!1,e.trigger("overlayClick",s,function(o){o.preventFocus||e.focusContent(),e.dlgClosedBy=zE})},this.l10n=new uo("dialog",{close:"Close"},this.locale),this.checkPositionData(),m(this.target)){var r=this.isProtectedOnChange;this.isProtectedOnChange=!0,this.target=document.body,this.isProtectedOnChange=r}},t.prototype.updatePersistData=function(){this.enablePersistence&&this.setProperties({width:parseFloat(this.element.style.width),height:parseFloat(this.element.style.height),position:{X:parseFloat(this.dragObj.element.style.left),Y:parseFloat(this.dragObj.element.style.top)}},!0)},t.prototype.isNumberValue=function(e){return/^[-+]?\d*\.?\d+$/.test(e)},t.prototype.checkPositionData=function(){if(!m(this.position)){if(!m(this.position.X)&&"number"!=typeof this.position.X&&this.isNumberValue(this.position.X)){var i=this.isProtectedOnChange;this.isProtectedOnChange=!0,this.position.X=parseFloat(this.position.X),this.isProtectedOnChange=i}m(this.position.Y)||"number"==typeof this.position.Y||this.isNumberValue(this.position.Y)&&(i=this.isProtectedOnChange,this.isProtectedOnChange=!0,this.position.Y=parseFloat(this.position.Y),this.isProtectedOnChange=i)}},t.prototype.getEle=function(e,i){for(var r=void 0,s=0;s=0&&t[e])vJ(t[e]);else if(""!==t[e].trim()){var i=Si("div",{className:"e-icons "+jg+" e-"+t[e]});Ui.appendChild(i)}hf=n.minHeight,ME=n.minWidth,Sh=n.maxWidth,yh=n.maxHeight,n.proxy&&n.proxy.element&&n.proxy.element.classList.contains("e-dialog")?u4(n.proxy):u4()}({element:this.element,direction:r,minHeight:parseInt(e.slice(0,i.indexOf("p")),10),maxHeight:this.targetEle.clientHeight,minWidth:parseInt(i.slice(0,i.indexOf("p")),10),maxWidth:this.targetEle.clientWidth,boundary:this.target===document.body?null:this.targetEle,resizeBegin:this.onResizeStart.bind(this),resizeComplete:this.onResizeComplete.bind(this),resizing:this.onResizing.bind(this),proxy:this}),this.wireWindowResizeEvent()}else v4(),this.unWireWindowResizeEvent(),this.element.classList.remove(this.isModal?cf:D4),this.element.classList.remove(PE)},t.prototype.getFocusElement=function(e){var r=e.querySelectorAll('input,select,textarea,button:enabled,a,[contenteditable="true"],[tabindex]');return{element:r[r.length-1]}},t.prototype.keyDown=function(e){var i=this;if(9===e.keyCode&&this.isModal){var r=void 0;m(this.btnObj)||(r=this.btnObj[this.btnObj.length-1]),m(this.btnObj)&&!m(this.ftrTemplateContent)&&(r=this.getFocusElement(this.ftrTemplateContent)),m(this.btnObj)&&m(this.ftrTemplateContent)&&!m(this.contentEle)&&(r=this.getFocusElement(this.contentEle)),!m(r)&&document.activeElement===r.element&&!e.shiftKey&&(e.preventDefault(),this.focusableElements(this.element).focus()),document.activeElement===this.focusableElements(this.element)&&e.shiftKey&&(e.preventDefault(),m(r)||r.element.focus())}var h,s=document.activeElement,o=["input","textarea"].indexOf(s.tagName.toLowerCase())>-1,a=!1;if(o||(a=s.hasAttribute("contenteditable")&&"true"===s.getAttribute("contenteditable")),27===e.keyCode&&this.closeOnEscape){this.dlgClosedBy="escape";var l=document.querySelector(".e-popup-open:not(.e-dialog)");!m(l)&&!l.classList.contains("e-toolbar-pop")&&!l.classList.contains("e-slider-tooltip")||this.hide(e)}(13===e.keyCode&&!e.ctrlKey&&"textarea"!==s.tagName.toLowerCase()&&o&&!m(this.primaryButtonEle)||13===e.keyCode&&e.ctrlKey&&("textarea"===s.tagName.toLowerCase()||a)&&!m(this.primaryButtonEle))&&this.buttons.some(function(d,u){h=u;var f=d.buttonModel;return!m(f)&&!0===f.isPrimary})&&"function"==typeof this.buttons[h].click&&setTimeout(function(){i.buttons[h].click.call(i,e)})},t.prototype.initialize=function(){m(this.target)||(this.targetEle="string"==typeof this.target?document.querySelector(this.target):this.target),this.isBlazorServerRender()||V([this.element],j0),X.isDevice&&V([this.element],S4),this.isBlazorServerRender()||this.setCSSClass(),this.setMaxHeight()},t.prototype.initRender=function(){var e=this;if(this.initialRender=!0,this.isBlazorServerRender()||Fe(this.element,{role:"dialog"}),1e3===this.zIndex?(this.setzIndex(this.element,!1),this.calculatezIndex=!0):this.calculatezIndex=!1,this.setTargetContent(),""!==this.header&&!m(this.header)&&this.setHeader(),this.renderCloseIcon(),this.setContent(),""===this.footerTemplate||m(this.footerTemplate)?!m(this.buttons[0])&&!m(this.buttons[0].buttonModel)&&this.setButton():this.setFooterTemplate(),this.allowDragging&&!m(this.headerContent)&&this.setAllowDragging(),Fe(this.element,{"aria-modal":this.isModal?"true":"false"}),this.isModal&&this.setIsModal(),!0!==this.element.classList.contains(C4)&&!0!==this.element.classList.contains(E4)&&!m(this.element.parentElement)){var i=this.isModal?this.dlgContainer.parentElement:this.element.parentElement;this.refElement=this.createElement("div",{className:"e-dlg-ref-element"}),i.insertBefore(this.refElement,this.isModal?this.dlgContainer:this.element)}if(m(this.targetEle)||this.targetEle.appendChild(this.isModal?this.dlgContainer:this.element),this.popupObj=new lc(this.element,{height:this.height,width:this.width,zIndex:this.zIndex,relateTo:this.target,actionOnScroll:"none",enableRtl:this.enableRtl,open:function(o){var a={container:e.isModal?e.dlgContainer:e.element,element:e.element,target:e.target,preventFocus:!1};e.enableResize&&e.resetResizeIcon(),e.trigger("open",a,function(l){l.preventFocus||e.focusContent()})},close:function(o){e.isModal&&V([e.dlgOverlay],"e-fade"),e.unBindEvent(e.element),e.isModal&&(e.dlgContainer.style.display="none"),e.trigger("close",e.closeArgs);var a=document.activeElement;!m(a)&&!m(a.blur)&&a.blur(),!m(e.storeActiveElement)&&!m(e.storeActiveElement.focus)&&e.storeActiveElement.focus()}}),this.positionChange(),this.setEnableRTL(),this.isBlazorServerRender()||(V([this.element],"e-popup-close"),this.isModal&&this.setOverlayZindex()),this.visible){if(this.show(),this.isModal){var r=this.getTargetContainer(this.target);r instanceof Element&&"rtl"===window.getComputedStyle(r).getPropertyValue("direction")&&this.setPopupPosition()}}else this.isModal&&(this.dlgOverlay.style.display="none");this.initialRender=!1},t.prototype.getTargetContainer=function(e){var i=null;if("string"==typeof e)if(e.startsWith("#"))i=document.getElementById(e.substring(1));else if(e.startsWith(".")){var r=document.getElementsByClassName(e.substring(1));i=r.length>0?r[0]:null}else!(e instanceof HTMLElement)&&e!==document.body&&(i=document.querySelector(e));else e instanceof HTMLElement&&(i=e);return i},t.prototype.resetResizeIcon=function(){var e=this.getMinHeight();if(this.targetEle.offsetHeight0&&("function"==typeof this.buttons[e].click&&E.add(s[e],"click",this.buttons[e].click,this),"object"==typeof this.buttons[e].click&&E.add(s[e],"click",this.buttonClickHandler.bind(this,e),this)),!this.isBlazorServerRender()&&!m(this.ftrTemplateContent)&&(this.btnObj[e].appendTo(this.ftrTemplateContent.children[e]),this.buttons[e].isFlat&&this.btnObj[e].element.classList.add("e-flat"),this.primaryButtonEle=this.element.getElementsByClassName("e-primary")[0]))},t.prototype.buttonClickHandler=function(e){this.trigger("buttons["+e+"].click",{})},t.prototype.setContent=function(){this.contentEle=this.createElement("div",{className:"e-dlg-content",id:this.element.id+"_dialog-content"}),Fe(this.element,this.headerEle?{"aria-describedby":this.element.id+"_title "+this.element.id+"_dialog-content"}:{"aria-describedby":this.element.id+"_dialog-content"}),this.innerContentElement?this.contentEle.appendChild(this.innerContentElement):(!m(this.content)&&""!==this.content||!this.initialRender)&&(("string"!=typeof this.content||ce())&&this.content instanceof HTMLElement?this.contentEle.appendChild(this.content):this.setTemplate(this.content,this.contentEle,"content")),m(this.headerContent)?this.element.insertBefore(this.contentEle,this.element.children[0]):this.element.insertBefore(this.contentEle,this.element.children[1]),"auto"===this.height&&(!this.isBlazorServerRender()&&X.isIE&&""===this.element.style.width&&!m(this.width)&&(this.element.style.width=Re(this.width)),this.setMaxHeight())},t.prototype.setTemplate=function(e,i,r){var s,o,a;o=i.classList.contains(m4)?this.element.id+"header":i.classList.contains(V0)?this.element.id+"footerTemplate":this.element.id+"content",m(e.outerHTML)?("string"==typeof e||"string"!=typeof e||ce()&&!this.isStringTemplate)&&("string"==typeof e&&(e=this.sanitizeHelper(e)),this.isVue||"string"!=typeof e?(s=oi(e),a=e):i.innerHTML=e):i.appendChild(e);var l=[];if(!m(s)){for(var c=0,d=s({},this,r,o,!(ce()&&!this.isStringTemplate&&0===a.indexOf("
Blazor"))||this.isStringTemplate);c/g,"");(this.element.children.length>0||i)&&(this.innerContentElement=document.createDocumentFragment(),[].slice.call(this.element.childNodes).forEach(function(r){8!==r.nodeType&&e.innerContentElement.appendChild(r)}))}},t.prototype.setHeader=function(){this.headerEle?this.headerEle.innerHTML="":this.headerEle=this.createElement("div",{id:this.element.id+"_title",className:m4}),this.createHeaderContent(),this.headerContent.appendChild(this.headerEle),this.setTemplate(this.header,this.headerEle,"header"),Fe(this.element,{"aria-describedby":this.element.id+"_title"}),Fe(this.element,{"aria-labelledby":this.element.id+"_dialog-header"}),this.element.insertBefore(this.headerContent,this.element.children[0]),this.allowDragging&&!m(this.headerContent)&&this.setAllowDragging()},t.prototype.setFooterTemplate=function(){this.ftrTemplateContent?this.ftrTemplateContent.innerHTML="":this.ftrTemplateContent=this.createElement("div",{className:V0}),""===this.footerTemplate||m(this.footerTemplate)?this.ftrTemplateContent.innerHTML=this.buttonContent.join(""):this.setTemplate(this.footerTemplate,this.ftrTemplateContent,"footerTemplate"),this.element.appendChild(this.ftrTemplateContent)},t.prototype.createHeaderContent=function(){m(this.headerContent)&&(this.headerContent=this.createElement("div",{id:this.element.id+"_dialog-header",className:kE}))},t.prototype.renderCloseIcon=function(){this.showCloseIcon&&(this.closeIcon=this.createElement("button",{className:I4,attrs:{type:"button"}}),this.closeIconBtnObj=new ys({cssClass:"e-flat",iconCss:y4+" e-icons"}),this.closeIconTitle(),m(this.headerContent)?(this.createHeaderContent(),gl([this.closeIcon],this.headerContent),this.element.insertBefore(this.headerContent,this.element.children[0])):gl([this.closeIcon],this.headerContent),this.closeIconBtnObj.appendTo(this.closeIcon))},t.prototype.closeIconTitle=function(){this.l10n.setLocale(this.locale);var e=this.l10n.getConstant("close");this.closeIcon.setAttribute("title",e),this.closeIcon.setAttribute("aria-label",e)},t.prototype.setCSSClass=function(e){e&&(K([this.element],e.split(" ")),this.isModal&&!m(this.dlgContainer)&&K([this.dlgContainer],e.split(" "))),this.cssClass&&(V([this.element],this.cssClass.split(" ")),this.isModal&&!m(this.dlgContainer)&&V([this.dlgContainer],this.cssClass.split(" ")))},t.prototype.setIsModal=function(){this.dlgContainer=this.createElement("div",{className:"e-dlg-container"}),this.setCSSClass(),this.element.classList.remove(b4),this.element.parentNode.insertBefore(this.dlgContainer,this.element),this.dlgContainer.appendChild(this.element),V([this.element],W0),this.dlgOverlay=this.createElement("div",{className:"e-dlg-overlay"}),this.dlgOverlay.style.zIndex=(this.zIndex-1).toString(),this.dlgContainer.appendChild(this.dlgOverlay)},t.prototype.getValidFocusNode=function(e){for(var i,r=0;r0||"a"===i.tagName.toLowerCase()&&i.hasAttribute("href"))&&i.tabIndex>-1&&!i.disabled&&!this.disableElement(i,'[disabled],[aria-disabled="true"],[type="hidden"]'))return i;i=null}return i},t.prototype.focusableElements=function(e){if(!m(e)){var r=e.querySelectorAll('input,select,textarea,button,a,[contenteditable="true"],[tabindex]');return this.getValidFocusNode(r)}return null},t.prototype.getAutoFocusNode=function(e){var i=e.querySelector("."+I4),s=e.querySelectorAll("[autofocus]"),o=this.getValidFocusNode(s);if(ce()&&(this.primaryButtonEle=this.element.getElementsByClassName("e-primary")[0]),m(o)){if(!m(o=this.focusableElements(this.contentEle)))return o;if(!m(this.primaryButtonEle))return this.element.querySelector(".e-primary")}else i=o;return i},t.prototype.disableElement=function(e,i){var r=e?e.matches||e.webkitMatchesSelector||e.msGetRegionContent:null;if(r)for(;e;e=e.parentNode)if(e instanceof Element&&r.call(e,i))return e;return null},t.prototype.focusContent=function(){var e=this.getAutoFocusNode(this.element),i=m(e)?this.element:e,r=X.userAgent;(r.indexOf("MSIE ")>0||r.indexOf("Trident/")>0)&&this.element.focus(),i.focus(),this.unBindEvent(this.element),this.bindEvent(this.element)},t.prototype.bindEvent=function(e){E.add(e,"keydown",this.keyDown,this)},t.prototype.unBindEvent=function(e){E.remove(e,"keydown",this.keyDown)},t.prototype.updateSanitizeContent=function(){this.isBlazorServerRender()||(this.contentEle.innerHTML=this.sanitizeHelper(this.content))},t.prototype.isBlazorServerRender=function(){return ce()&&this.isServerRendered},t.prototype.getModuleName=function(){return"dialog"},t.prototype.onPropertyChanged=function(e,i){if(this.element.classList.contains(j0))for(var r=0,s=Object.keys(e);r0?this.showCloseIcon||""!==this.header&&!m(this.header)?this.showCloseIcon||he(this.closeIcon):(he(this.headerContent),this.headerContent=null):(this.renderCloseIcon(),this.wireEvents());break;case"locale":this.showCloseIcon&&this.closeIconTitle();break;case"visible":this.visible?this.show():this.hide();break;case"isModal":this.updateIsModal();break;case"height":je(this.element,{height:Re(e.height)}),this.updatePersistData();break;case"width":je(this.element,{width:Re(e.width)}),this.updatePersistData();break;case"zIndex":this.popupObj.zIndex=this.zIndex,this.isModal&&this.setOverlayZindex(this.zIndex),this.element.style.zIndex!==this.zIndex.toString()&&(this.calculatezIndex=!1);break;case"cssClass":this.setCSSClass(i.cssClass);break;case"buttons":this.unWireButtonEvents(),this.destroyButtons(),m(this.ftrTemplateContent)||(he(this.ftrTemplateContent),this.ftrTemplateContent=null),this.footerTemplate="",this.setButton();break;case"allowDragging":this.allowDragging&&!m(this.headerContent)?this.setAllowDragging():this.dragObj.destroy();break;case"target":this.setTarget(e.target);break;case"position":if(this.checkPositionData(),this.isModal){var a=this.position.X,l=this.position.Y;m(i.position)||(m(i.position.X)||(a=i.position.X),m(i.position.Y)||(l=i.position.Y)),this.dlgContainer.classList.contains("e-dlg-"+a+"-"+l)&&this.dlgContainer.classList.remove("e-dlg-"+a+"-"+l)}this.positionChange(),this.updatePersistData();break;case"enableRtl":this.setEnableRTL();break;case"enableResize":this.setResize(),this.isModelResize=this.enableResize&&this.isModal,this.enableResize&&this.dialogOpen&&this.resetResizeIcon();break;case"minHeight":""!==this.minHeight&&(this.element.style.minHeight=Re(this.minHeight))}},t.prototype.setTarget=function(e){this.popupObj.relateTo=e,this.target=e,this.targetEle="string"==typeof this.target?document.querySelector(this.target):this.target,this.dragObj&&(this.dragObj.dragArea=this.targetEle),this.setMaxHeight(),this.isModal&&this.updateIsModal(),this.enableResize&&this.setResize(),m(this.targetEle)||(this.isModal&&!m(this.dlgContainer)?this.targetEle.appendChild(this.dlgContainer):m(this.element)||this.targetEle.appendChild(this.element))},t.prototype.updateIsModal=function(){if(this.element.setAttribute("aria-modal",this.isModal?"true":"false"),this.isModal)m(this.dlgOverlay)&&(this.setIsModal(),this.element.style.top="0px",this.element.style.left="0px",m(this.targetEle)||this.targetEle.appendChild(this.dlgContainer));else{for(K([this.element],W0),K([document.body],[Pa,ea]),he(this.dlgOverlay);this.dlgContainer.firstChild;)this.dlgContainer.parentElement.insertBefore(this.dlgContainer.firstChild,this.dlgContainer);this.dlgContainer.parentElement.removeChild(this.dlgContainer)}this.visible&&this.show(),this.positionChange(),this.isModal&&this.dlgOverlay&&E.add(this.dlgOverlay,"click",this.dlgOverlayClickEventHandler,this)},t.prototype.setzIndex=function(e,i){var r=this.isProtectedOnChange;this.isProtectedOnChange=!0;var s=hc(e);this.zIndex=s>this.zIndex?s:this.zIndex,this.isProtectedOnChange=r,i&&(this.popupObj.zIndex=this.zIndex)},t.prototype.windowResizeHandler=function(){(function yJ(n){Sh=n})(this.targetEle.clientWidth),function SJ(n){yh=n}(this.targetEle.clientHeight),this.setMaxHeight()},t.prototype.getPersistData=function(){return this.addOnPersist(["width","height","position"])},t.prototype.removeAllChildren=function(e){for(;e.children[0];)this.removeAllChildren(e.children[0]),e.removeChild(e.children[0])},t.prototype.destroy=function(){if(!this.isDestroyed){var e=[OE,W0,PE,cf,Y0,S4],i=["role","aria-modal","aria-labelledby","aria-describedby","aria-grabbed","tabindex","style"];K([this.targetEle],[Pa,ea]),!m(this.element)&&this.element.classList.contains(Y0)&&K([document.body],[Pa,ea]),this.isModal&&K([m(this.targetEle)?document.body:this.targetEle],ea),this.unWireEvents(),this.unWireButtonEvents(),this.destroyButtons(),m(this.closeIconBtnObj)||this.closeIconBtnObj.destroy(),m(this.dragObj)||this.dragObj.destroy(),!m(this.popupObj.element)&&this.popupObj.element.classList.contains("e-popup")&&this.popupObj.destroy(),K([this.element],e),!m(this.cssClass)&&""!==this.cssClass&&K([this.element],this.cssClass.split(" ")),!m(this.refElement)&&!m(this.refElement.parentElement)&&(this.refElement.parentElement.insertBefore(this.isModal?this.dlgContainer:this.element,this.refElement),he(this.refElement),this.refElement=void 0),this.isModal&&(he(this.dlgOverlay),this.dlgContainer.parentNode.insertBefore(this.element,this.dlgContainer),he(this.dlgContainer)),this.element.innerHTML=this.clonedEle.innerHTML;for(var r=0;r0&&""===this.footerTemplate&&this.ftrTemplateContent)for(var e=0;e=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},RE="e-tooltip",O4="e-icons",k4="e-tooltip-close",HE="e-tooltip-wrap",P4="e-tip-content",df="e-arrow-tip",z4="e-arrow-tip-outer",Q0="e-arrow-tip-inner",Gg="e-tip-bottom",BE="e-tip-top",R4="e-tip-left",FE="e-tip-right",_E="e-popup",Xg="e-popup-open",UE="e-popup-close",G0="e-lib",H4="e-tooltip-popup-container",UJ=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return T4(t,n),Gi([I({effect:"FadeIn",duration:150,delay:0})],t.prototype,"open",void 0),Gi([I({effect:"FadeOut",duration:150,delay:0})],t.prototype,"close",void 0),t}(Ee),bh=function(n){function t(e,i){var r=n.call(this,e,i)||this;return r.mouseMoveEvent=null,r.mouseMoveTarget=null,r.containerElement=null,r.isBodyContainer=!0,r}return T4(t,n),t.prototype.initialize=function(){this.formatPosition(),V([this.element],RE)},t.prototype.formatPosition=function(){var e,i;this.position&&(0===this.position.indexOf("Top")||0===this.position.indexOf("Bottom")?(e=this.position.split(/(?=[A-Z])/),this.tooltipPositionY=e[0],this.tooltipPositionX=e[1]):(i=this.position.split(/(?=[A-Z])/),this.tooltipPositionX=i[0],this.tooltipPositionY=i[1]))},t.prototype.renderArrow=function(){this.setTipClass(this.position);var e=this.createElement("div",{className:df+" "+this.tipClass});e.appendChild(this.createElement("div",{className:z4+" "+this.tipClass})),e.appendChild(this.createElement("div",{className:Q0+" "+this.tipClass})),this.tooltipEle.appendChild(e)},t.prototype.setTipClass=function(e){this.tipClass=0===e.indexOf("Right")?R4:0===e.indexOf("Bottom")?BE:0===e.indexOf("Left")?FE:Gg},t.prototype.renderPopup=function(e){var i=this.mouseTrail?{top:0,left:0}:this.getTooltipPosition(e);this.tooltipEle.classList.remove(G0),this.popupObj=new lc(this.tooltipEle,{height:this.height,width:this.width,position:{X:i.left,Y:i.top},enableRtl:this.enableRtl,open:this.openPopupHandler.bind(this),close:this.closePopupHandler.bind(this)})},t.prototype.getScalingFactor=function(e){if(!e)return{x:1,y:1};var i={x:1,y:1},r=e.closest('[style*="transform: scale"]');if(r&&r!==this.tooltipEle&&r.contains(this.tooltipEle)){var a=window.getComputedStyle(r).getPropertyValue("transform").match(/matrix\(([^)]+)\)/)[1].split(",").map(parseFloat);i.x=a[0],i.y=a[3]}return i},t.prototype.getTooltipPosition=function(e){this.tooltipEle.style.display="block";var i=this.element.closest('[style*="zoom"]');i&&(i.contains(this.tooltipEle)||(this.tooltipEle.style.zoom=getComputedStyle(i).zoom));var r=ns(e,this.tooltipPositionX,this.tooltipPositionY,!this.isBodyContainer,this.isBodyContainer?null:this.containerElement.getBoundingClientRect()),s=this.getScalingFactor(e),o=this.calculateTooltipOffset(this.position,s.x,s.y),a=this.calculateElementPosition(r,o),c=this.collisionFlipFit(e,a[0],a[1]);return c.left=c.left/s.x,c.top=c.top/s.y,this.tooltipEle.style.display="",c},t.prototype.windowResize=function(){this.reposition(this.findTarget())},t.prototype.reposition=function(e){if(this.popupObj&&e){var i=this.getTooltipPosition(e);this.popupObj.position={X:i.left,Y:i.top},this.popupObj.dataBind()}},t.prototype.openPopupHandler=function(){!this.mouseTrail&&this.needTemplateReposition()&&this.reposition(this.findTarget()),this.trigger("afterOpen",this.tooltipEventArgs),this.tooltipEventArgs=null},t.prototype.closePopupHandler=function(){this.isReact&&!("Click"===this.opensOn||"function"==typeof this.content)&&this.clearTemplate(["content"]),this.clear();var e={type:this.tooltipEventArgs.event?this.tooltipEventArgs.event.type:null,cancel:!1,target:this.tooltipEventArgs.target,event:this.tooltipEventArgs.event?this.tooltipEventArgs.event:null,element:this.tooltipEle,isInteracted:!m(this.tooltipEventArgs.event)};this.trigger("afterClose",e),e=null},t.prototype.calculateTooltipOffset=function(e,i,r){void 0===i&&(i=1),void 0===r&&(r=1);var o,a,l,h,c,d,u,f,s={top:0,left:0};if(1!==i||1!==r){var p=this.tooltipEle.getBoundingClientRect(),g=void 0;l=Math.round(p.width),h=Math.round(p.height),(c=_("."+df,this.tooltipEle))&&(g=c.getBoundingClientRect()),o=c?Math.round(g.width):0,a=c?Math.round(g.height):0,d=this.showTipPointer?0:8,u=a/2+2+(h-this.tooltipEle.clientHeight*r),f=o/2+2+(l-this.tooltipEle.clientWidth*i)}else l=this.tooltipEle.offsetWidth,h=this.tooltipEle.offsetHeight,c=_("."+df,this.tooltipEle),d=this.showTipPointer?0:8,u=(a=c?c.offsetHeight:0)/2+2+(this.tooltipEle.offsetHeight-this.tooltipEle.clientHeight),f=(o=c?c.offsetWidth:0)/2+2+(this.tooltipEle.offsetWidth-this.tooltipEle.clientWidth);switch(this.mouseTrail&&(d+=2),e){case"RightTop":s.left+=o+d,s.top-=h-u;break;case"RightCenter":s.left+=o+d,s.top-=h/2;break;case"RightBottom":s.left+=o+d,s.top-=u;break;case"BottomRight":s.top+=a+d,s.left-=f;break;case"BottomCenter":s.top+=a+d,s.left-=l/2;break;case"BottomLeft":s.top+=a+d,s.left-=l-f;break;case"LeftBottom":s.left-=o+l+d,s.top-=u;break;case"LeftCenter":s.left-=o+l+d,s.top-=h/2;break;case"LeftTop":s.left-=o+l+d,s.top-=h-u;break;case"TopLeft":s.top-=h+a+d,s.left-=l-f;break;case"TopRight":s.top-=h+a+d,s.left-=f;break;default:s.top-=h+a+d,s.left-=l/2}return s.left+=this.offsetX,s.top+=this.offsetY,s},t.prototype.updateTipPosition=function(e){var i=we("."+df+",."+z4+",."+Q0,this.tooltipEle);K(i,[Gg,BE,R4,FE]),this.setTipClass(e),V(i,this.tipClass)},t.prototype.adjustArrow=function(e,i,r,s){var o=_("."+df,this.tooltipEle);if(!1!==this.showTipPointer&&null!==o){var a,l;this.updateTipPosition(i),this.tooltipEle.style.display="block";var p,h=this.tooltipEle.clientWidth,c=this.tooltipEle.clientHeight,d=_("."+Q0,this.tooltipEle),u=o.offsetWidth,f=o.offsetHeight;this.tooltipEle.style.display="",this.tipClass===Gg||this.tipClass===BE?(this.tipClass===Gg?(l="99.9%",d.style.top="-"+(f-2)+"px"):(l=-(f-1)+"px",d.style.top="-"+(f-6)+"px"),e&&(a=(p="Center"!==r||h>e.offsetWidth||this.mouseTrail)&&"Left"===r||!p&&"End"===this.tipPointerPosition?h-u-2+"px":p&&"Right"===r||!p&&"Start"===this.tipPointerPosition?"2px":!p||"End"!==this.tipPointerPosition&&"Start"!==this.tipPointerPosition?h/2-u/2+"px":"End"===this.tipPointerPosition?e.offsetWidth+(this.tooltipEle.offsetWidth-e.offsetWidth)/2-u/2-2+"px":(this.tooltipEle.offsetWidth-e.offsetWidth)/2-u/2+2+"px")):(this.tipClass===FE?(a="99.9%",d.style.left="-"+(u-2)+"px"):(a=-(u-1)+"px",d.style.left=u-2-u+"px"),l=(p="Center"!==s||c>e.offsetHeight||this.mouseTrail)&&"Top"===s||!p&&"End"===this.tipPointerPosition?c-f-2+"px":p&&"Bottom"===s||!p&&"Start"===this.tipPointerPosition?"2px":c/2-f/2+"px"),o.style.top=l,o.style.left=a}},t.prototype.renderContent=function(e){var i=this,r=_("."+P4,this.tooltipEle);if(this.cssClass&&V([this.tooltipEle],this.cssClass.split(" ")),e&&!m(e.getAttribute("title"))&&(e.setAttribute("data-content",e.getAttribute("title")),e.removeAttribute("title")),m(this.content))e&&!m(e.getAttribute("data-content"))&&(r.innerHTML=e.getAttribute("data-content"));else if(r.innerHTML="",this.content instanceof HTMLElement)r.appendChild(this.content);else if("string"==typeof this.content)this.isAngular?this.setProperties({content:Ai.sanitize(this.content)},!0):this.content=this.enableHtmlSanitizer?Ai.sanitize(this.content):this.content,this.enableHtmlParse?(o=oi(this.content)({},this,"content",this.element.id+"content",void 0,void 0,r,this.root))&&Dt(o,r):r.textContent=this.content;else{var o;(o=oi(this.content)({},this,"content",this.element.id+"content",void 0,void 0,r))&&(this.isAngular&&setTimeout(function(){i.reposition(e)},1),Dt(o,r)),this.renderReactTemplates()}},t.prototype.renderCloseIcon=function(){if(this.isSticky){var i=this.createElement("div",{className:O4+" "+k4});this.tooltipEle.appendChild(i),E.add(i,X.touchStartEvent,this.onStickyClose,this)}else{var e=this.tooltipEle.querySelector("."+O4+"."+k4);e&>(e)}},t.prototype.addDescribedBy=function(e,i){var r=(e.getAttribute("aria-describedby")||"").split(/\s+/);r.indexOf(i)<0&&r.push(i),Fe(e,{"aria-describedby":r.join(" ").trim(),"data-tooltip-id":i})},t.prototype.removeDescribedBy=function(e){var i=e.getAttribute("data-tooltip-id"),r=(e.getAttribute("aria-describedby")||"").split(/\s+/),s=r.indexOf(i);-1!==s&&r.splice(s,1),e.removeAttribute("data-tooltip-id");var o=r.join(" ").trim();o?e.setAttribute("aria-describedby",o):e.removeAttribute("aria-describedby")},t.prototype.tapHoldHandler=function(e){clearTimeout(this.autoCloseTimer),this.targetHover(e.originalEvent)},t.prototype.touchEndHandler=function(){var e=this;this.isSticky||(this.autoCloseTimer=setTimeout(function(){e.close()},1500))},t.prototype.targetClick=function(e){var i;!m(i=this.target?J(e.target,this.target):this.element)&&(null===i.getAttribute("data-tooltip-id")?this.targetHover(e):this.isSticky||this.hideTooltip(this.animation.close,e,i))},t.prototype.targetHover=function(e){var i;if(!(m(i=this.target?J(e.target,this.target):this.element)||null!==i.getAttribute("data-tooltip-id")&&0===this.closeDelay)){for(var s=0,o=[].slice.call(we('[data-tooltip-id= "'+this.ctrlId+'_content"]',document));s0?this.showTimer=setTimeout(function(){o.mouseTrail&&E.add(i,"mousemove touchstart mouseenter",o.onMouseMove,o),o.popupObj&&(o.popupObj.show(a,i),o.mouseMoveEvent&&o.mouseTrail&&o.onMouseMove(o.mouseMoveEvent))},this.openDelay):this.popupObj&&this.popupObj.show(a,i)}s&&this.wireMouseEvents(s,i)},t.prototype.needTemplateReposition=function(){return!m(this.viewContainerRef)&&"string"!=typeof this.viewContainerRef||this.isReact},t.prototype.checkCollision=function(e,i,r){var s={left:i,top:r,position:this.position,horizontal:this.tooltipPositionX,vertical:this.tooltipPositionY},o=ac(this.tooltipEle,this.checkCollideTarget(),i,r);return o.length>0&&(s.horizontal=o.indexOf("left")>=0?"Right":o.indexOf("right")>=0?"Left":this.tooltipPositionX,s.vertical=o.indexOf("top")>=0?"Bottom":o.indexOf("bottom")>=0?"Top":this.tooltipPositionY),s},t.prototype.calculateElementPosition=function(e,i){return[this.isBodyContainer?e.left+i.left:e.left-this.containerElement.getBoundingClientRect().left+i.left+window.pageXOffset+this.containerElement.scrollLeft,this.isBodyContainer?e.top+i.top:e.top-this.containerElement.getBoundingClientRect().top+i.top+window.pageYOffset+this.containerElement.scrollTop]},t.prototype.collisionFlipFit=function(e,i,r){var s=this.checkCollision(e,i,r),o=s.position;if(this.tooltipPositionY!==s.vertical&&(o=0===this.position.indexOf("Bottom")||0===this.position.indexOf("Top")?s.vertical+this.tooltipPositionX:this.tooltipPositionX+s.vertical),this.tooltipPositionX!==s.horizontal&&(0===o.indexOf("Left")&&(s.vertical="LeftTop"===o||"LeftCenter"===o?"Top":"Bottom",o=s.vertical+"Left"),0===o.indexOf("Right")&&(s.vertical="RightTop"===o||"RightCenter"===o?"Top":"Bottom",o=s.vertical+"Right"),s.horizontal=this.tooltipPositionX),this.tooltipEventArgs={type:null,cancel:!1,target:e,event:null,element:this.tooltipEle,collidedPosition:o},this.trigger("beforeCollision",this.tooltipEventArgs),this.tooltipEventArgs.cancel)o=this.position;else{var a=s.vertical,l=s.horizontal;if(s.position!==o){var h=ns(e,l,a,!this.isBodyContainer,this.isBodyContainer?null:this.containerElement.getBoundingClientRect());this.adjustArrow(e,o,l,a);var c=this.getScalingFactor(e),d=this.calculateTooltipOffset(o,c.x,c.y);d.top-=this.getOffSetPosition("TopBottom",o,this.offsetY),d.left-=this.getOffSetPosition("RightLeft",o,this.offsetX),s.position=o;var u=this.calculateElementPosition(h,d);s.left=u[0],s.top=u[1]}else this.adjustArrow(e,o,l,a)}var f={left:s.left,top:s.top},p=this.isBodyContainer?cE(this.tooltipEle,this.checkCollideTarget(),{X:!0,Y:this.windowCollision},f):f;this.tooltipEle.style.display="block";var g=_("."+df,this.tooltipEle);if(this.showTipPointer&&null!=g&&(0===o.indexOf("Bottom")||0===o.indexOf("Top"))){var v=parseInt(g.style.left,10)-(p.left-s.left);v<0?v=0:v+g.offsetWidth>this.tooltipEle.clientWidth&&(v=this.tooltipEle.clientWidth-g.offsetWidth),g.style.left=v.toString()+"px"}return this.tooltipEle.style.display="",f.left=p.left,f.top=p.top,f},t.prototype.getOffSetPosition=function(e,i,r){return-1!==e.indexOf(this.position.split(/(?=[A-Z])/)[0])&&-1!==e.indexOf(i.split(/(?=[A-Z])/)[0])?2*r:0},t.prototype.checkCollideTarget=function(){return!this.windowCollision&&this.target?this.element:null},t.prototype.hideTooltip=function(e,i,r){var s=this;this.closeDelay>0?(clearTimeout(this.hideTimer),clearTimeout(this.showTimer),this.hideTimer=setTimeout(function(){s.closeDelay&&s.tooltipEle&&s.isTooltipOpen||s.tooltipHide(e,i,r)},this.closeDelay)):this.tooltipHide(e,i,r)},t.prototype.tooltipHide=function(e,i,r){var o,s=this;o=i?this.target?r||i.target:this.element:_('[data-tooltip-id= "'+this.ctrlId+'_content"]',document),this.tooltipEventArgs={type:i?i.type:null,cancel:!1,target:o,event:i||null,element:this.tooltipEle,isInteracted:!m(i)},this.trigger("beforeClose",this.tooltipEventArgs,function(a){a.cancel?s.isHidden=!1:(s.mouseMoveBeforeRemove(),s.popupHide(e,o,i))})},t.prototype.popupHide=function(e,i,r){i&&r&&this.restoreElement(i),this.isHidden=!0;var s={name:this.animation.close.effect,duration:e.duration,delay:e.delay,timingFunction:"easeIn"};"None"===e.effect&&(s=void 0),this.popupObj&&this.popupObj.hide(s)},t.prototype.restoreElement=function(e){this.unwireMouseEvents(e),m(e.getAttribute("data-content"))||(e.setAttribute("title",e.getAttribute("data-content")),e.removeAttribute("data-content")),this.removeDescribedBy(e)},t.prototype.clear=function(){var e=this.findTarget();e&&this.restoreElement(e),this.tooltipEle&&(K([this.tooltipEle],UE),V([this.tooltipEle],Xg)),this.isHidden&&(this.popupObj&&this.popupObj.destroy(),this.tooltipEle&>(this.tooltipEle),this.tooltipEle=null,this.popupObj=null)},t.prototype.tooltipHover=function(){this.tooltipEle&&(this.isTooltipOpen=!0)},t.prototype.tooltipMouseOut=function(e){this.isTooltipOpen=!1,this.hideTooltip(this.animation.close,e,this.findTarget())},t.prototype.onMouseOut=function(e){var i=e.relatedTarget;if(i&&!this.mouseTrail){var r=J(i,"."+HE+"."+G0+"."+_E);r?E.add(r,"mouseleave",this.tooltipElementMouseOut,this):(this.hideTooltip(this.animation.close,e,this.findTarget()),0===this.closeDelay&&("None"===this.animation.close.effect||this.isReact&&"string"!=typeof this.content)&&this.clear())}else this.hideTooltip(this.animation.close,e,this.findTarget()),this.clear();this.popupObj&&!this.popupObj.element.classList.contains(Xg)&&this.clear()},t.prototype.tooltipElementMouseOut=function(e){this.hideTooltip(this.animation.close,e,this.findTarget()),E.remove(this.element,"mouseleave",this.tooltipElementMouseOut),this.clear()},t.prototype.onStickyClose=function(){this.close()},t.prototype.onMouseMove=function(e){var i=0,r=0;e.type.indexOf("touch")>-1?(e.preventDefault(),i=e.touches[0].pageX,r=e.touches[0].pageY):(i=e.pageX,r=e.pageY),Hs.stop(this.tooltipEle),K([this.tooltipEle],UE),V([this.tooltipEle],Xg),this.adjustArrow(e.target,this.position,this.tooltipPositionX,this.tooltipPositionY);var s=this.getScalingFactor(e.target),o=this.calculateTooltipOffset(this.position,s.x,s.y),h=this.checkCollision(e.target,i+o.left+this.offsetX,r+o.top+this.offsetY);if(this.tooltipPositionX!==h.horizontal||this.tooltipPositionY!==h.vertical){var c=0===this.position.indexOf("Bottom")||0===this.position.indexOf("Top")?h.vertical+h.horizontal:h.horizontal+h.vertical;h.position=c,this.adjustArrow(e.target,h.position,h.horizontal,h.vertical);var d=this.calculateTooltipOffset(h.position,s.x,s.y);h.left=i+d.left-this.offsetX,h.top=r+d.top-this.offsetY}this.tooltipEle.style.left=h.left+"px",this.tooltipEle.style.top=h.top+"px"},t.prototype.keyDown=function(e){this.tooltipEle&&27===e.keyCode&&this.close()},t.prototype.touchEnd=function(e){this.tooltipEle&&null===J(e.target,"."+RE)&&!this.isSticky&&this.close()},t.prototype.scrollHandler=function(e){this.tooltipEle&&!this.isSticky&&!J(e.target,"."+HE+"."+G0+"."+_E)&&!this.isSticky&&this.close()},t.prototype.render=function(){this.initialize(),this.wireEvents(this.opensOn),this.renderComplete()},t.prototype.preRender=function(){this.tipClass=Gg,this.tooltipPositionX="Center",this.tooltipPositionY="Top",this.isHidden=!0},t.prototype.wireEvents=function(e){for(var r=0,s=this.getTriggerList(e);r0)for(var i=0,r=e;i0)for(var i=0,r=e;i0&&this.condition&&-1!==this.condition.indexOf("not")&&(e[s].condition=e[s].condition?e[s].condition+"not":"not"),i=e[s].validate(t),r){if(!i)return!1}else if(i)return!0;return r},n.prototype.toJson=function(){var t,e;if(this.isComplex){t=[],e=this.predicates;for(var i=0;ie.length-3?(e=e.substring(0,e.length-1),n.endsWith(n.toLowerCase(t),n.toLowerCase(e))):(e.lastIndexOf("%")!==e.indexOf("%")&&e.lastIndexOf("%")>e.indexOf("%")+1&&(e=e.substring(e.indexOf("%")+1,e.lastIndexOf("%"))),-1!==t.indexOf(e)))},n.fnSort=function(t){return"ascending"===(t=t?n.toLowerCase(t):"ascending")?this.fnAscending:this.fnDescending},n.fnAscending=function(t,e){return m(t)&&m(e)||null==e?-1:"string"==typeof t?t.localeCompare(e):null==t?1:t-e},n.fnDescending=function(t,e){return m(t)&&m(e)?-1:null==e?1:"string"==typeof t?-1*t.localeCompare(e):null==t?-1:e-t},n.extractFields=function(t,e){for(var i={},r=0;r0||e.length>0;)o=t.length>0&&e.length>0?r?r(this.getVal(t,0,i),this.getVal(e,0,i),t[0],e[0])<=0?t:e:t[0][i]0?t:e,s.push(o.shift());return s},n.getVal=function(t,e,i){return i?this.getObject(i,t[e]):t[e]},n.toLowerCase=function(t){return t?"string"==typeof t?t.toLowerCase():t.toString():0===t||!1===t?t.toString():""},n.callAdaptorFunction=function(t,e,i,r){if(e in t){var s=t[e](i,r);m(s)||(i=s)}return i},n.getAddParams=function(t,e,i){var r={};return n.callAdaptorFunction(t,"addParams",{dm:e,query:i,params:i?i.params:[],reqParams:r}),r},n.isPlainObject=function(t){return!!t&&t.constructor===Object},n.isCors=function(){var t=null;try{t=new window.XMLHttpRequest}catch{}return!!t&&"withCredentials"in t},n.getGuid=function(t){var i;return(t||"")+"00000000-0000-4000-0000-000000000000".replace(/0/g,function(r,s){if("crypto"in window&&"getRandomValues"in crypto){var o=new Uint8Array(1);window.crypto.getRandomValues(o),i=o[0]%16|0}else i=16*Math.random()|0;return"0123456789abcdef"[19===s?3&i|8:i]})},n.isNull=function(t){return null==t},n.getItemFromComparer=function(t,e,i){var r,s,o,a=0,l="string"==typeof n.getVal(t,0,e);if(t.length)for(;m(r)&&a0&&(r=s,o=t[a]));return o},n.distinct=function(t,e,i){i=!m(i)&&i;var s,r=[],o={};return t.forEach(function(a,l){(s="object"==typeof t[l]?n.getVal(t,l,e):t[l])in o||(r.push(i?t[l]:s),o[s]=1)}),r},n.processData=function(t,e){var i=this.prepareQuery(t),r=new it(e);t.requiresCounts&&i.requiresCount();var s=r.executeLocal(i),o={result:t.requiresCounts?s.result:s,count:s.count,aggregates:JSON.stringify(s.aggregates)};return t.requiresCounts?o:s},n.prepareQuery=function(t){var e=this,i=new _t;return t.select&&i.select(t.select),t.where&&n.parse.parseJson(t.where).filter(function(o){if(m(o.condition))i.where(o.field,o.operator,o.value,o.ignoreCase,o.ignoreAccent);else{var a=[];o.field?a.push(new Ss(o.field,o.operator,o.value,o.ignoreCase,o.ignoreAccent)):a=a.concat(e.getPredicate(o.predicates)),"or"===o.condition?i.where(Ss.or(a)):"and"===o.condition&&i.where(Ss.and(a))}}),t.search&&n.parse.parseJson(t.search).filter(function(o){return i.search(o.key,o.fields,o.operator,o.ignoreCase,o.ignoreAccent)}),t.aggregates&&t.aggregates.filter(function(o){return i.aggregate(o.type,o.field)}),t.sorted&&t.sorted.filter(function(o){return i.sortBy(o.name,o.direction)}),t.skip&&i.skip(t.skip),t.take&&i.take(t.take),t.group&&t.group.filter(function(o){return i.group(o)}),i},n.getPredicate=function(t){for(var e=[],i=0;i":"greaterthan","<=":"lessthanorequal",">=":"greaterthanorequal","==":"equal","!=":"notequal","*=":"contains","$=":"endswith","^=":"startswith"},n.odBiOperator={"<":" lt ",">":" gt ","<=":" le ",">=":" ge ","==":" eq ","!=":" ne ",lessthan:" lt ",lessthanorequal:" le ",greaterthan:" gt ",greaterthanorequal:" ge ",equal:" eq ",notequal:" ne "},n.odUniOperator={"$=":"endswith","^=":"startswith","*=":"substringof",endswith:"endswith",startswith:"startswith",contains:"substringof",doesnotendwith:"not endswith",doesnotstartwith:"not startswith",doesnotcontain:"not substringof",wildcard:"wildcard",like:"like"},n.odv4UniOperator={"$=":"endswith","^=":"startswith","*=":"contains",endswith:"endswith",startswith:"startswith",contains:"contains",doesnotendwith:"not endswith",doesnotstartwith:"not startswith",doesnotcontain:"not contains",wildcard:"wildcard",like:"like"},n.diacritics={"\u24b6":"A",\uff21:"A",\u00c0:"A",\u00c1:"A",\u00c2:"A",\u1ea6:"A",\u1ea4:"A",\u1eaa:"A",\u1ea8:"A",\u00c3:"A",\u0100:"A",\u0102:"A",\u1eb0:"A",\u1eae:"A",\u1eb4:"A",\u1eb2:"A",\u0226:"A",\u01e0:"A",\u00c4:"A",\u01de:"A",\u1ea2:"A",\u00c5:"A",\u01fa:"A",\u01cd:"A",\u0200:"A",\u0202:"A",\u1ea0:"A",\u1eac:"A",\u1eb6:"A",\u1e00:"A",\u0104:"A",\u023a:"A",\u2c6f:"A",\ua732:"AA",\u00c6:"AE",\u01fc:"AE",\u01e2:"AE",\ua734:"AO",\ua736:"AU",\ua738:"AV",\ua73a:"AV",\ua73c:"AY","\u24b7":"B",\uff22:"B",\u1e02:"B",\u1e04:"B",\u1e06:"B",\u0243:"B",\u0182:"B",\u0181:"B","\u24b8":"C",\uff23:"C",\u0106:"C",\u0108:"C",\u010a:"C",\u010c:"C",\u00c7:"C",\u1e08:"C",\u0187:"C",\u023b:"C",\ua73e:"C","\u24b9":"D",\uff24:"D",\u1e0a:"D",\u010e:"D",\u1e0c:"D",\u1e10:"D",\u1e12:"D",\u1e0e:"D",\u0110:"D",\u018b:"D",\u018a:"D",\u0189:"D",\ua779:"D",\u01f1:"DZ",\u01c4:"DZ",\u01f2:"Dz",\u01c5:"Dz","\u24ba":"E",\uff25:"E",\u00c8:"E",\u00c9:"E",\u00ca:"E",\u1ec0:"E",\u1ebe:"E",\u1ec4:"E",\u1ec2:"E",\u1ebc:"E",\u0112:"E",\u1e14:"E",\u1e16:"E",\u0114:"E",\u0116:"E",\u00cb:"E",\u1eba:"E",\u011a:"E",\u0204:"E",\u0206:"E",\u1eb8:"E",\u1ec6:"E",\u0228:"E",\u1e1c:"E",\u0118:"E",\u1e18:"E",\u1e1a:"E",\u0190:"E",\u018e:"E","\u24bb":"F",\uff26:"F",\u1e1e:"F",\u0191:"F",\ua77b:"F","\u24bc":"G",\uff27:"G",\u01f4:"G",\u011c:"G",\u1e20:"G",\u011e:"G",\u0120:"G",\u01e6:"G",\u0122:"G",\u01e4:"G",\u0193:"G",\ua7a0:"G",\ua77d:"G",\ua77e:"G","\u24bd":"H",\uff28:"H",\u0124:"H",\u1e22:"H",\u1e26:"H",\u021e:"H",\u1e24:"H",\u1e28:"H",\u1e2a:"H",\u0126:"H",\u2c67:"H",\u2c75:"H",\ua78d:"H","\u24be":"I",\uff29:"I",\u00cc:"I",\u00cd:"I",\u00ce:"I",\u0128:"I",\u012a:"I",\u012c:"I",\u0130:"I",\u00cf:"I",\u1e2e:"I",\u1ec8:"I",\u01cf:"I",\u0208:"I",\u020a:"I",\u1eca:"I",\u012e:"I",\u1e2c:"I",\u0197:"I","\u24bf":"J",\uff2a:"J",\u0134:"J",\u0248:"J","\u24c0":"K",\uff2b:"K",\u1e30:"K",\u01e8:"K",\u1e32:"K",\u0136:"K",\u1e34:"K",\u0198:"K",\u2c69:"K",\ua740:"K",\ua742:"K",\ua744:"K",\ua7a2:"K","\u24c1":"L",\uff2c:"L",\u013f:"L",\u0139:"L",\u013d:"L",\u1e36:"L",\u1e38:"L",\u013b:"L",\u1e3c:"L",\u1e3a:"L",\u0141:"L",\u023d:"L",\u2c62:"L",\u2c60:"L",\ua748:"L",\ua746:"L",\ua780:"L",\u01c7:"LJ",\u01c8:"Lj","\u24c2":"M",\uff2d:"M",\u1e3e:"M",\u1e40:"M",\u1e42:"M",\u2c6e:"M",\u019c:"M","\u24c3":"N",\uff2e:"N",\u01f8:"N",\u0143:"N",\u00d1:"N",\u1e44:"N",\u0147:"N",\u1e46:"N",\u0145:"N",\u1e4a:"N",\u1e48:"N",\u0220:"N",\u019d:"N",\ua790:"N",\ua7a4:"N",\u01ca:"NJ",\u01cb:"Nj","\u24c4":"O",\uff2f:"O",\u00d2:"O",\u00d3:"O",\u00d4:"O",\u1ed2:"O",\u1ed0:"O",\u1ed6:"O",\u1ed4:"O",\u00d5:"O",\u1e4c:"O",\u022c:"O",\u1e4e:"O",\u014c:"O",\u1e50:"O",\u1e52:"O",\u014e:"O",\u022e:"O",\u0230:"O",\u00d6:"O",\u022a:"O",\u1ece:"O",\u0150:"O",\u01d1:"O",\u020c:"O",\u020e:"O",\u01a0:"O",\u1edc:"O",\u1eda:"O",\u1ee0:"O",\u1ede:"O",\u1ee2:"O",\u1ecc:"O",\u1ed8:"O",\u01ea:"O",\u01ec:"O",\u00d8:"O",\u01fe:"O",\u0186:"O",\u019f:"O",\ua74a:"O",\ua74c:"O",\u01a2:"OI",\ua74e:"OO",\u0222:"OU","\u24c5":"P",\uff30:"P",\u1e54:"P",\u1e56:"P",\u01a4:"P",\u2c63:"P",\ua750:"P",\ua752:"P",\ua754:"P","\u24c6":"Q",\uff31:"Q",\ua756:"Q",\ua758:"Q",\u024a:"Q","\u24c7":"R",\uff32:"R",\u0154:"R",\u1e58:"R",\u0158:"R",\u0210:"R",\u0212:"R",\u1e5a:"R",\u1e5c:"R",\u0156:"R",\u1e5e:"R",\u024c:"R",\u2c64:"R",\ua75a:"R",\ua7a6:"R",\ua782:"R","\u24c8":"S",\uff33:"S",\u1e9e:"S",\u015a:"S",\u1e64:"S",\u015c:"S",\u1e60:"S",\u0160:"S",\u1e66:"S",\u1e62:"S",\u1e68:"S",\u0218:"S",\u015e:"S",\u2c7e:"S",\ua7a8:"S",\ua784:"S","\u24c9":"T",\uff34:"T",\u1e6a:"T",\u0164:"T",\u1e6c:"T",\u021a:"T",\u0162:"T",\u1e70:"T",\u1e6e:"T",\u0166:"T",\u01ac:"T",\u01ae:"T",\u023e:"T",\ua786:"T",\ua728:"TZ","\u24ca":"U",\uff35:"U",\u00d9:"U",\u00da:"U",\u00db:"U",\u0168:"U",\u1e78:"U",\u016a:"U",\u1e7a:"U",\u016c:"U",\u00dc:"U",\u01db:"U",\u01d7:"U",\u01d5:"U",\u01d9:"U",\u1ee6:"U",\u016e:"U",\u0170:"U",\u01d3:"U",\u0214:"U",\u0216:"U",\u01af:"U",\u1eea:"U",\u1ee8:"U",\u1eee:"U",\u1eec:"U",\u1ef0:"U",\u1ee4:"U",\u1e72:"U",\u0172:"U",\u1e76:"U",\u1e74:"U",\u0244:"U","\u24cb":"V",\uff36:"V",\u1e7c:"V",\u1e7e:"V",\u01b2:"V",\ua75e:"V",\u0245:"V",\ua760:"VY","\u24cc":"W",\uff37:"W",\u1e80:"W",\u1e82:"W",\u0174:"W",\u1e86:"W",\u1e84:"W",\u1e88:"W",\u2c72:"W","\u24cd":"X",\uff38:"X",\u1e8a:"X",\u1e8c:"X","\u24ce":"Y",\uff39:"Y",\u1ef2:"Y",\u00dd:"Y",\u0176:"Y",\u1ef8:"Y",\u0232:"Y",\u1e8e:"Y",\u0178:"Y",\u1ef6:"Y",\u1ef4:"Y",\u01b3:"Y",\u024e:"Y",\u1efe:"Y","\u24cf":"Z",\uff3a:"Z",\u0179:"Z",\u1e90:"Z",\u017b:"Z",\u017d:"Z",\u1e92:"Z",\u1e94:"Z",\u01b5:"Z",\u0224:"Z",\u2c7f:"Z",\u2c6b:"Z",\ua762:"Z","\u24d0":"a",\uff41:"a",\u1e9a:"a",\u00e0:"a",\u00e1:"a",\u00e2:"a",\u1ea7:"a",\u1ea5:"a",\u1eab:"a",\u1ea9:"a",\u00e3:"a",\u0101:"a",\u0103:"a",\u1eb1:"a",\u1eaf:"a",\u1eb5:"a",\u1eb3:"a",\u0227:"a",\u01e1:"a",\u00e4:"a",\u01df:"a",\u1ea3:"a",\u00e5:"a",\u01fb:"a",\u01ce:"a",\u0201:"a",\u0203:"a",\u1ea1:"a",\u1ead:"a",\u1eb7:"a",\u1e01:"a",\u0105:"a",\u2c65:"a",\u0250:"a",\ua733:"aa",\u00e6:"ae",\u01fd:"ae",\u01e3:"ae",\ua735:"ao",\ua737:"au",\ua739:"av",\ua73b:"av",\ua73d:"ay","\u24d1":"b",\uff42:"b",\u1e03:"b",\u1e05:"b",\u1e07:"b",\u0180:"b",\u0183:"b",\u0253:"b","\u24d2":"c",\uff43:"c",\u0107:"c",\u0109:"c",\u010b:"c",\u010d:"c",\u00e7:"c",\u1e09:"c",\u0188:"c",\u023c:"c",\ua73f:"c",\u2184:"c","\u24d3":"d",\uff44:"d",\u1e0b:"d",\u010f:"d",\u1e0d:"d",\u1e11:"d",\u1e13:"d",\u1e0f:"d",\u0111:"d",\u018c:"d",\u0256:"d",\u0257:"d",\ua77a:"d",\u01f3:"dz",\u01c6:"dz","\u24d4":"e",\uff45:"e",\u00e8:"e",\u00e9:"e",\u00ea:"e",\u1ec1:"e",\u1ebf:"e",\u1ec5:"e",\u1ec3:"e",\u1ebd:"e",\u0113:"e",\u1e15:"e",\u1e17:"e",\u0115:"e",\u0117:"e",\u00eb:"e",\u1ebb:"e",\u011b:"e",\u0205:"e",\u0207:"e",\u1eb9:"e",\u1ec7:"e",\u0229:"e",\u1e1d:"e",\u0119:"e",\u1e19:"e",\u1e1b:"e",\u0247:"e",\u025b:"e",\u01dd:"e","\u24d5":"f",\uff46:"f",\u1e1f:"f",\u0192:"f",\ua77c:"f","\u24d6":"g",\uff47:"g",\u01f5:"g",\u011d:"g",\u1e21:"g",\u011f:"g",\u0121:"g",\u01e7:"g",\u0123:"g",\u01e5:"g",\u0260:"g",\ua7a1:"g",\u1d79:"g",\ua77f:"g","\u24d7":"h",\uff48:"h",\u0125:"h",\u1e23:"h",\u1e27:"h",\u021f:"h",\u1e25:"h",\u1e29:"h",\u1e2b:"h",\u1e96:"h",\u0127:"h",\u2c68:"h",\u2c76:"h",\u0265:"h",\u0195:"hv","\u24d8":"i",\uff49:"i",\u00ec:"i",\u00ed:"i",\u00ee:"i",\u0129:"i",\u012b:"i",\u012d:"i",\u00ef:"i",\u1e2f:"i",\u1ec9:"i",\u01d0:"i",\u0209:"i",\u020b:"i",\u1ecb:"i",\u012f:"i",\u1e2d:"i",\u0268:"i",\u0131:"i","\u24d9":"j",\uff4a:"j",\u0135:"j",\u01f0:"j",\u0249:"j","\u24da":"k",\uff4b:"k",\u1e31:"k",\u01e9:"k",\u1e33:"k",\u0137:"k",\u1e35:"k",\u0199:"k",\u2c6a:"k",\ua741:"k",\ua743:"k",\ua745:"k",\ua7a3:"k","\u24db":"l",\uff4c:"l",\u0140:"l",\u013a:"l",\u013e:"l",\u1e37:"l",\u1e39:"l",\u013c:"l",\u1e3d:"l",\u1e3b:"l",\u017f:"l",\u0142:"l",\u019a:"l",\u026b:"l",\u2c61:"l",\ua749:"l",\ua781:"l",\ua747:"l",\u01c9:"lj","\u24dc":"m",\uff4d:"m",\u1e3f:"m",\u1e41:"m",\u1e43:"m",\u0271:"m",\u026f:"m","\u24dd":"n",\uff4e:"n",\u01f9:"n",\u0144:"n",\u00f1:"n",\u1e45:"n",\u0148:"n",\u1e47:"n",\u0146:"n",\u1e4b:"n",\u1e49:"n",\u019e:"n",\u0272:"n",\u0149:"n",\ua791:"n",\ua7a5:"n",\u01cc:"nj","\u24de":"o",\uff4f:"o",\u00f2:"o",\u00f3:"o",\u00f4:"o",\u1ed3:"o",\u1ed1:"o",\u1ed7:"o",\u1ed5:"o",\u00f5:"o",\u1e4d:"o",\u022d:"o",\u1e4f:"o",\u014d:"o",\u1e51:"o",\u1e53:"o",\u014f:"o",\u022f:"o",\u0231:"o",\u00f6:"o",\u022b:"o",\u1ecf:"o",\u0151:"o",\u01d2:"o",\u020d:"o",\u020f:"o",\u01a1:"o",\u1edd:"o",\u1edb:"o",\u1ee1:"o",\u1edf:"o",\u1ee3:"o",\u1ecd:"o",\u1ed9:"o",\u01eb:"o",\u01ed:"o",\u00f8:"o",\u01ff:"o",\u0254:"o",\ua74b:"o",\ua74d:"o",\u0275:"o",\u01a3:"oi",\u0223:"ou",\ua74f:"oo","\u24df":"p",\uff50:"p",\u1e55:"p",\u1e57:"p",\u01a5:"p",\u1d7d:"p",\ua751:"p",\ua753:"p",\ua755:"p","\u24e0":"q",\uff51:"q",\u024b:"q",\ua757:"q",\ua759:"q","\u24e1":"r",\uff52:"r",\u0155:"r",\u1e59:"r",\u0159:"r",\u0211:"r",\u0213:"r",\u1e5b:"r",\u1e5d:"r",\u0157:"r",\u1e5f:"r",\u024d:"r",\u027d:"r",\ua75b:"r",\ua7a7:"r",\ua783:"r","\u24e2":"s",\uff53:"s",\u00df:"s",\u015b:"s",\u1e65:"s",\u015d:"s",\u1e61:"s",\u0161:"s",\u1e67:"s",\u1e63:"s",\u1e69:"s",\u0219:"s",\u015f:"s",\u023f:"s",\ua7a9:"s",\ua785:"s",\u1e9b:"s","\u24e3":"t",\uff54:"t",\u1e6b:"t",\u1e97:"t",\u0165:"t",\u1e6d:"t",\u021b:"t",\u0163:"t",\u1e71:"t",\u1e6f:"t",\u0167:"t",\u01ad:"t",\u0288:"t",\u2c66:"t",\ua787:"t",\ua729:"tz","\u24e4":"u",\uff55:"u",\u00f9:"u",\u00fa:"u",\u00fb:"u",\u0169:"u",\u1e79:"u",\u016b:"u",\u1e7b:"u",\u016d:"u",\u00fc:"u",\u01dc:"u",\u01d8:"u",\u01d6:"u",\u01da:"u",\u1ee7:"u",\u016f:"u",\u0171:"u",\u01d4:"u",\u0215:"u",\u0217:"u",\u01b0:"u",\u1eeb:"u",\u1ee9:"u",\u1eef:"u",\u1eed:"u",\u1ef1:"u",\u1ee5:"u",\u1e73:"u",\u0173:"u",\u1e77:"u",\u1e75:"u",\u0289:"u","\u24e5":"v",\uff56:"v",\u1e7d:"v",\u1e7f:"v",\u028b:"v",\ua75f:"v",\u028c:"v",\ua761:"vy","\u24e6":"w",\uff57:"w",\u1e81:"w",\u1e83:"w",\u0175:"w",\u1e87:"w",\u1e85:"w",\u1e98:"w",\u1e89:"w",\u2c73:"w","\u24e7":"x",\uff58:"x",\u1e8b:"x",\u1e8d:"x","\u24e8":"y",\uff59:"y",\u1ef3:"y",\u00fd:"y",\u0177:"y",\u1ef9:"y",\u0233:"y",\u1e8f:"y",\u00ff:"y",\u1ef7:"y",\u1e99:"y",\u1ef5:"y",\u01b4:"y",\u024f:"y",\u1eff:"y","\u24e9":"z",\uff5a:"z",\u017a:"z",\u1e91:"z",\u017c:"z",\u017e:"z",\u1e93:"z",\u1e95:"z",\u01b6:"z",\u0225:"z",\u0240:"z",\u2c6c:"z",\ua763:"z",\u0386:"\u0391",\u0388:"\u0395",\u0389:"\u0397",\u038a:"\u0399",\u03aa:"\u0399",\u038c:"\u039f",\u038e:"\u03a5",\u03ab:"\u03a5",\u038f:"\u03a9",\u03ac:"\u03b1",\u03ad:"\u03b5",\u03ae:"\u03b7",\u03af:"\u03b9",\u03ca:"\u03b9",\u0390:"\u03b9",\u03cc:"\u03bf",\u03cd:"\u03c5",\u03cb:"\u03c5",\u03b0:"\u03c5",\u03c9:"\u03c9",\u03c2:"\u03c3"},n.fnOperators={equal:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?n.toLowerCase(t)===n.toLowerCase(e):t===e},notequal:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),!n.fnOperators.equal(t,e,i)},lessthan:function(t,e,i){return i?n.toLowerCase(t)n.toLowerCase(e):t>e},lessthanorequal:function(t,e,i){return i?n.toLowerCase(t)<=n.toLowerCase(e):(m(t)&&(t=void 0),t<=e)},greaterthanorequal:function(t,e,i){return i?n.toLowerCase(t)>=n.toLowerCase(e):t>=e},contains:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?!m(t)&&!m(e)&&-1!==n.toLowerCase(t).indexOf(n.toLowerCase(e)):!m(t)&&!m(e)&&-1!==t.toString().indexOf(e)},doesnotcontain:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?!m(t)&&!m(e)&&-1===n.toLowerCase(t).indexOf(n.toLowerCase(e)):!m(t)&&!m(e)&&-1===t.toString().indexOf(e)},isnotnull:function(t){return null!=t},isnull:function(t){return null==t},startswith:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.startsWith(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.startsWith(t,e)},doesnotstartwith:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.notStartsWith(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.notStartsWith(t,e)},like:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.like(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.like(t,e)},isempty:function(t){return void 0===t||""===t},isnotempty:function(t){return void 0!==t&&""!==t},wildcard:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?(t||"boolean"==typeof t)&&e&&"object"!=typeof t&&n.wildCard(n.toLowerCase(t),n.toLowerCase(e)):(t||"boolean"==typeof t)&&e&&n.wildCard(t,e)},endswith:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.endsWith(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.endsWith(t,e)},doesnotendwith:function(t,e,i,r){return r&&(t=n.ignoreDiacritics(t),e=n.ignoreDiacritics(e)),i?t&&e&&n.notEndsWith(n.toLowerCase(t),n.toLowerCase(e)):t&&e&&n.notEndsWith(t,e)},processSymbols:function(t){var e=n.operatorSymbols[t];return e?n.fnOperators[e]:n.throwError("Query - Process Operator : Invalid operator")},processOperator:function(t){return n.fnOperators[t]||n.fnOperators.processSymbols(t)}},n.parse={parseJson:function(t){return"string"!=typeof t||!/^[\s]*\[|^[\s]*\{(.)+:/g.test(t)&&-1!==t.indexOf('"')?t instanceof Array?n.parse.iterateAndReviveArray(t):"object"==typeof t&&null!==t&&n.parse.iterateAndReviveJson(t):t=JSON.parse(t,n.parse.jsonReviver),t},iterateAndReviveArray:function(t){for(var e=0;e-1||e.indexOf("z")>-1,o=e.split(/[^0-9.]/);if(s){if(o[5].indexOf(".")>-1){var a=o[5].split(".");o[5]=a[0],o[6]=new Date(e).getUTCMilliseconds().toString()}else o[6]="00";e=n.dateParse.toTimeZone(new Date(parseInt(o[0],10),parseInt(o[1],10)-1,parseInt(o[2],10),parseInt(o[3],10),parseInt(o[4],10),parseInt(o[5]?o[5]:"00",10),parseInt(o[6],10)),n.serverTimezoneOffset,!1)}else{var l=new Date(parseInt(o[0],10),parseInt(o[1],10)-1,parseInt(o[2],10),parseInt(o[3],10),parseInt(o[4],10),parseInt(o[5]?o[5]:"00",10)),h=parseInt(o[6],10),c=parseInt(o[7],10);if(isNaN(h)&&isNaN(c))return l;e.indexOf("+")>-1?l.setHours(l.getHours()-h,l.getMinutes()-c):l.setHours(l.getHours()+h,l.getMinutes()+c),e=n.dateParse.toTimeZone(l,n.serverTimezoneOffset,!1)}null==n.serverTimezoneOffset&&(e=n.dateParse.addSelfOffset(e))}}return e},isJson:function(t){return"string"==typeof t[0]?t:n.parse.parseJson(t)},isGuid:function(t){return null!=/[A-Fa-f0-9]{8}(?:-[A-Fa-f0-9]{4}){3}-[A-Fa-f0-9]{12}/i.exec(t)},replacer:function(t,e){return n.isPlainObject(t)?n.parse.jsonReplacer(t,e):t instanceof Array?n.parse.arrayReplacer(t):t instanceof Date?n.parse.jsonReplacer({val:t},e).val:t},jsonReplacer:function(t,e){for(var i,s=0,o=Object.keys(t);s=0?"+":"-",s=function(a){var l=Math.floor(Math.abs(a));return(l<10?"0":"")+l};return e.getFullYear()+"-"+s(e.getMonth()+1)+"-"+s(e.getDate())+"T"+s(e.getHours())+":"+s(e.getMinutes())+":"+s(e.getSeconds())+r+s(i/60)+":"+s(i%60)}},n}(),Ml=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),xK={GroupGuid:"{271bbba0-1ee7}"},t5=function(){function n(t){this.options={from:"table",requestType:"json",sortBy:"sorted",select:"select",skip:"skip",group:"group",take:"take",search:"search",count:"requiresCounts",where:"where",aggregates:"aggregates",expand:"expand"},this.type=n,this.dataSource=t,this.pvt={}}return n.prototype.processResponse=function(t,e,i,r){return t},n}(),WE=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ml(t,n),t.prototype.processQuery=function(e,i){for(var a,l,f,r=e.dataSource.json.slice(0),s=r.length,o=!0,h={},c=0,d=[],u=[],p=0;p1?e.sort.filter(function(f){return f.fieldName===c})[0]:e.sort[0];s=this.onSortBy(s,d,e.query,!0)}e.page&&(s=this.onPage(s,e.page,e.query)),this.formGroupResult(s,h)}else{for(var o=e.lazyLoad.onDemandGroupInfo,a=o.where.length-1;a>=0;a--)s=this.onWhere(s,o.where[a]);if(e.group.length!==o.level)s=le.group(s,e.group[o.level].fieldName,r,null,null,e.group[o.level].comparer,!0),e.sort.length&&(s=this.onSortBy(s,e.sort[parseInt(o.level.toString(),10)],e.query,!0));else for(a=e.sort.length-1;a>=o.level;a--)s=this.onSortBy(s,e.sort[parseInt(a.toString(),10)],e.query,!1);i=s.length,h=s,s=(s=s.slice(o.skip)).slice(0,o.take),e.group.length!==o.level&&this.formGroupResult(s,h)}return{result:s,count:i}},t.prototype.formGroupResult=function(e,i){if(e.length&&i.length){var r="GroupGuid",s="childLevels",o="level",a="records";e[r]=i[r],e[s]=i[s],e[o]=i[o],e[a]=i[a]}return e},t.prototype.getAggregate=function(e){var i=_t.filterQueries(e.queries,"onAggregates"),r=[];if(i.length)for(var s=void 0,o=0;o=0;l--)a[l]&&(o=i.comparer,le.endsWith(a[l]," desc")&&(o=le.fnSort("descending"),a[l]=a[l].replace(" desc","")),e=le.sort(e,a[l],o));return e}return le.sort(e,s?"key":a,i.comparer)},t.prototype.onGroup=function(e,i,r){if(!e||!e.length)return e;var s=this.getAggregate(r);return le.group(e,le.getValue(i.fieldName,r),s,null,null,i.comparer)},t.prototype.onPage=function(e,i,r){var s=le.getValue(i.pageSize,r),o=(le.getValue(i.pageIndex,r)-1)*s;return e&&e.length?e.slice(o,o+s):e},t.prototype.onRange=function(e,i){return e&&e.length?e.slice(le.getValue(i.start),le.getValue(i.end)):e},t.prototype.onTake=function(e,i){return e&&e.length?e.slice(0,le.getValue(i.nos)):e},t.prototype.onSkip=function(e,i){return e&&e.length?e.slice(le.getValue(i.nos)):e},t.prototype.onSelect=function(e,i){return e&&e.length?le.select(e,le.getValue(i.fieldNames)):e},t.prototype.insert=function(e,i,r,s,o){return m(o)?e.dataSource.json.push(i):e.dataSource.json.splice(o,0,i)},t.prototype.remove=function(e,i,r,s){var a,o=e.dataSource.json;for("object"==typeof r&&!(r instanceof Date)&&(r=le.getObject(i,r)),a=0;a1&&(g="("+g+")"),f.filters.push(g);for(var y=0,S="object"==typeof f.filters[p]?Object.keys(f.filters[p]):[];y-1&&this.formRemoteGroupedData(e[s].items,i+1,r-1);var o="GroupGuid",h="records";return e[o]=xK[o],e.level=i,e.childLevels=r,e[h]=e[0].items.length?this.getGroupedRecords(e,!m(e[0].items[h])):[],e},t.prototype.getGroupedRecords=function(e,i){for(var r=[],o=0;ol.length-3?(l=l.substring(0,l.length-1),o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.endswith:le.odv4UniOperator.endswith):l.lastIndexOf("%")!==l.indexOf("%")&&l.lastIndexOf("%")>l.indexOf("%")+1?(l=l.substring(l.indexOf("%")+1,l.lastIndexOf("%")),o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains):o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains),l="'"+(l=encodeURIComponent(l))+"'";else if("wildcard"===o)if(-1!==l.indexOf("*")){var d=l.split("*"),u=void 0,f=0;if(0!==l.indexOf("*")&&-1===d[0].indexOf("%3f")&&-1===d[0].indexOf("?")&&(u="'"+(u=d[0])+"'",s+=(o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.startswith:le.odv4UniOperator.startswith)+"(",s+=c+",",a&&(s+=a),s+=u+")",f++),l.lastIndexOf("*")!==l.length-1&&-1===d[d.length-1].indexOf("%3f")&&-1===d[d.length-1].indexOf("?")&&(u="'"+(u=d[d.length-1])+"'",f>0&&(s+=" and "),s+=(o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.endswith:le.odv4UniOperator.endswith)+"(",s+=c+",",a&&(s+=a),s+=u+")",f++),d.length>2)for(var p=1;p0&&(s+=" and "),"substringof"===(o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains)||"not substringof"===o){var g=u;u=c,c=g}s+=o+"(",s+=c+",",a&&(s+=a),s+=u+")",f++}0===f?(o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains,(-1!==l.indexOf("?")||-1!==l.indexOf("%3f"))&&(l=-1!==l.indexOf("?")?l.split("?").join(""):l.split("%3f").join("")),l="'"+l+"'"):o="wildcard"}else o=m(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?le.odUniOperator.contains:le.odv4UniOperator.contains,(-1!==l.indexOf("?")||-1!==l.indexOf("%3f"))&&(l=-1!==l.indexOf("?")?l.split("?").join(""):l.split("%3f").join("")),l="'"+l+"'";return"substringof"!==o&&"not substringof"!==o||(g=l,l=c,c=g),"wildcard"!==o&&(s+=o+"(",s+=c+",",a&&(s+=a),s+=l+")"),s},t.prototype.addParams=function(e){n.prototype.addParams.call(this,e),delete e.reqParams.params},t.prototype.onComplexPredicate=function(e,i,r){for(var s=[],o=0;o-1;f--)!/\bContent-ID:/i.test(c[f])||!/\bHTTP.+201/.test(c[f])||(l=parseInt(/\bContent-ID: (\d+)/i.exec(c[f])[1],10),o.addedRecords[l]&&(h=le.parse.parseJson(/^\{.+\}/m.exec(c[f])[0]),ze({},o.addedRecords[l],this.processResponse(h))));return o}return null},t.prototype.compareAndRemove=function(e,i,r){var s=this;return m(i)||Object.keys(e).forEach(function(o){o!==r&&"@odata.etag"!==o&&(le.isPlainObject(e[o])?(s.compareAndRemove(e[o],i[o]),0===Object.keys(e[o]).filter(function(l){return"@odata.etag"!==l}).length&&delete e[o]):(e[o]===i[o]||e[o]&&i[o]&&e[o].valueOf()===i[o].valueOf())&&delete e[o])}),e},t}(fc),TK=function(n){function t(){var e=n.call(this)||this;return yt("beforeSend",fc.prototype.beforeSend,e),e}return Ml(t,n),t.prototype.insert=function(e,i,r,s,o){return this.pvt.position=o,this.updateType="add",{url:e.dataSource.insertUrl||e.dataSource.crudUrl||e.dataSource.url,data:JSON.stringify(ze({},{value:i,table:r,action:"insert"},le.getAddParams(this,e,s)))}},t.prototype.remove=function(e,i,r,s,o){return n.prototype.remove.call(this,e,i,r),{type:"POST",url:e.dataSource.removeUrl||e.dataSource.crudUrl||e.dataSource.url,data:JSON.stringify(ze({},{key:r,keyColumn:i,table:s,action:"remove"},le.getAddParams(this,e,o)))}},t.prototype.update=function(e,i,r,s,o){return this.updateType="update",this.updateKey=i,{type:"POST",url:e.dataSource.updateUrl||e.dataSource.crudUrl||e.dataSource.url,data:JSON.stringify(ze({},{value:r,action:"update",keyColumn:i,key:r[i],table:s},le.getAddParams(this,e,o)))}},t.prototype.processResponse=function(e,i,r,s,o,a,l){var h;if(e="batch"===(o?JSON.parse(o.data):e).action?le.parse.parseJson(e):e,"add"===this.updateType&&n.prototype.insert.call(this,i,e,null,null,this.pvt.position),"update"===this.updateType&&n.prototype.update.call(this,i,this.updateKey,e),this.updateType=void 0,e.added)for(h=0;hi&&h.push(c)}for(c=0;cthis.pageSize;)h.results.splice(0,1),h.keys.splice(0,1);return window.localStorage.setItem(this.guidId,JSON.stringify(h)),e},t.prototype.beforeSend=function(e,i,r){!m(this.cacheAdaptor.options.batch)&&le.endsWith(r.url,this.cacheAdaptor.options.batch)&&"post"===r.type.toLowerCase()&&i.headers.set("Accept",this.cacheAdaptor.options.multipartAccept),e.dataSource.crossDomain||i.headers.set("Accept",this.cacheAdaptor.options.accept)},t.prototype.update=function(e,i,r,s){return this.isCrudAction=!0,this.cacheAdaptor.update(e,i,r,s)},t.prototype.insert=function(e,i,r){return this.isInsertAction=!0,this.cacheAdaptor.insert(e,i,r)},t.prototype.remove=function(e,i,r,s){return this.isCrudAction=!0,this.cacheAdaptor.remove(e,i,r,s)},t.prototype.batchRequest=function(e,i,r){return this.cacheAdaptor.batchRequest(e,i,r)},t}(fc),it=function(){function n(t,e,i){var s,r=this;return this.dateParse=!0,this.timeZoneHandling=!0,this.persistQuery={},this.isInitialLoad=!1,this.requests=[],this.isInitialLoad=!0,!t&&!this.dataSource&&(t=[]),i=i||t.adaptor,t&&!1===t.timeZoneHandling&&(this.timeZoneHandling=t.timeZoneHandling),t instanceof Array?s={json:t,offline:!0}:"object"==typeof t?(t.json||(t.json=[]),t.enablePersistence||(t.enablePersistence=!1),t.id||(t.id=""),t.ignoreOnPersist||(t.ignoreOnPersist=[]),s={url:t.url,insertUrl:t.insertUrl,removeUrl:t.removeUrl,updateUrl:t.updateUrl,crudUrl:t.crudUrl,batchUrl:t.batchUrl,json:t.json,headers:t.headers,accept:t.accept,data:t.data,timeTillExpiration:t.timeTillExpiration,cachingPageSize:t.cachingPageSize,enableCaching:t.enableCaching,requestType:t.requestType,key:t.key,crossDomain:t.crossDomain,jsonp:t.jsonp,dataType:t.dataType,offline:void 0!==t.offline?t.offline:!(t.adaptor instanceof TK||t.adaptor instanceof AK||t.url),requiresFormat:t.requiresFormat,enablePersistence:t.enablePersistence,id:t.id,ignoreOnPersist:t.ignoreOnPersist}):le.throwError("DataManager: Invalid arguments"),void 0===s.requiresFormat&&!le.isCors()&&(s.requiresFormat=!!m(s.crossDomain)||s.crossDomain),void 0===s.dataType&&(s.dataType="json"),this.dataSource=s,this.defaultQuery=e,this.dataSource.enablePersistence&&this.dataSource.id&&window.addEventListener("unload",this.setPersistData.bind(this)),s.url&&s.offline&&!s.json.length?(this.isDataAvailable=!1,this.adaptor=i||new pf,this.dataSource.offline=!1,this.ready=this.executeQuery(e||new _t),this.ready.then(function(o){r.dataSource.offline=!0,r.isDataAvailable=!0,s.json=o.result,r.adaptor=new WE})):this.adaptor=s.offline?new WE:new pf,!s.jsonp&&this.adaptor instanceof pf&&(s.jsonp="callback"),this.adaptor=i||this.adaptor,s.enableCaching&&(this.adaptor=new LK(this.adaptor,s.timeTillExpiration,s.cachingPageSize)),this}return Object.defineProperty(n.prototype,"moduleName",{get:function(){return"datamanager"},enumerable:!0,configurable:!0}),n.prototype.getPersistedData=function(t){var e=localStorage.getItem(t||this.dataSource.id);return JSON.parse(e)},n.prototype.setPersistData=function(t,e,i){localStorage.setItem(e||this.dataSource.id,JSON.stringify(i||this.persistQuery))},n.prototype.setPersistQuery=function(t){var e=this,i=this.getPersistedData();if(this.isInitialLoad&&i&&Object.keys(i).length){this.persistQuery=i,this.persistQuery.queries=this.persistQuery.queries.filter(function(s){if(e.dataSource.ignoreOnPersist&&e.dataSource.ignoreOnPersist.length&&s.fn&&e.dataSource.ignoreOnPersist.some(function(l){return s.fn===l}))return!1;if("onWhere"===s.fn){var o=s.e;if(o&&o.isComplex&&o.predicates instanceof Array){var a=o.predicates.map(function(l){if(l.predicates&&l.predicates instanceof Array){var h=l.predicates.map(function(v){return new Ss(v.field,v.operator,v.value,v.ignoreCase,v.ignoreAccent,v.matchCase)});return"and"===l.condition?Ss.and(h):Ss.or(h)}return new Ss(l.field,l.operator,l.value,l.ignoreCase,l.ignoreAccent,l.matchCase)});s.e=new Ss(a[0],o.condition,a.slice(1))}}return!0});var r=ze(new _t,this.persistQuery);return this.isInitialLoad=!1,r}return this.persistQuery=t,this.isInitialLoad=!1,t},n.prototype.setDefaultQuery=function(t){return this.defaultQuery=t,this},n.prototype.executeLocal=function(t){!this.defaultQuery&&!(t instanceof _t)&&le.throwError("DataManager - executeLocal() : A query is required to execute"),this.dataSource.json||le.throwError("DataManager - executeLocal() : Json data is required to execute"),this.dataSource.enablePersistence&&this.dataSource.id&&(t=this.setPersistQuery(t));var e=this.adaptor.processQuery(this,t=t||this.defaultQuery);if(t.subQuery){var i=t.subQuery.fromTable,r=t.subQuery.lookups,s=t.isCountRequired?e.result:e;r&&r instanceof Array&&le.buildHierarchy(t.subQuery.fKey,i,s,r,t.subQuery.key);for(var o=0;oli");z.classList.remove("json-parent");for(var j=0;j',W=ve.children[0].placeholder}return W}function Q(k,W,ve){!m(ve)&&""!==ve&&K(W,ve.split(" ")),!m(k)&&""!==k&&V(W,k.split(" "))}function oe(k,W,ve){if("multiselect"===ve||function Mo(k){if(!k)return!1;for(var W=k;W&&W!==document.body;){if("none"===window.getComputedStyle(W).display)return!1;W=W.parentElement}return!0}(k)){var Te="multiselect"===ve?k:k.clientWidth-parseInt(getComputedStyle(k,null).getPropertyValue("padding-left"),10);!m(W)&&!m(W.getElementsByClassName("e-float-text-content")[0])&&(W.getElementsByClassName("e-float-text-content")[0].classList.contains("e-float-text-overflow")&&W.getElementsByClassName("e-float-text-content")[0].classList.remove("e-float-text-overflow"),(Te0)for(var Ye=0;Ye<_e.length;Ye++)_e[parseInt(Ye.toString(),10)].addEventListener("mousedown",wo,!1),_e[parseInt(Ye.toString(),10)].addEventListener("mouseup",Ul,!1);else if(_e.length>0)for(Ye=0;Ye<_e.length;Ye++)_e[parseInt(Ye.toString(),10)].removeEventListener("mousedown",wo,this),_e[parseInt(Ye.toString(),10)].removeEventListener("mouseup",Ul,this)}function wo(){for(var W=this.parentElement;!W.classList.contains("e-input-group");)W=W.parentElement;!function Sa(k,W){!k.classList.contains("e-disabled")&&!k.querySelector("input").readOnly&&W.classList.add("e-input-btn-ripple")}(W,this)}function Ul(){var k=this;setTimeout(function(){k.classList.remove("e-input-btn-ripple")},500)}function gb(k,W){var ve=W("span",{className:k});return ve.classList.add("e-input-group-icon"),ve}function y_(k,W,ve,Te){var _e=m(Te)?Si:Te,Ye=gb(k,_e);W.classList.add("e-float-icon-left");var vi=W.querySelector(".e-input-in-wrap");if(m(vi)){vi=_e("span",{className:"e-input-in-wrap"}),ve.parentNode.insertBefore(vi,ve);var Gs=W.querySelectorAll(ve.tagName+" ~ *");vi.appendChild(ve);for(var ts=0;ts-1)if("class"===_e){var Ye=this.getInputValidClassList(k[""+_e]);""!==Ye&&V([W],Ye.split(" "))}else if("style"===_e){var vi=W.getAttribute(_e);vi=m(vi)?k[""+_e]:vi+k[""+_e],W.setAttribute(_e,vi)}else W.setAttribute(_e,k[""+_e])}},n.isBlank=function Hle(k){return!k||/^\s*$/.test(k)}}(Le||(Le={})),new RegExp("^(-)?(\\d*)$"),new RegExp("^[A-Za-z0-9._%+-]{1,}@[A-Za-z0-9._%+-]{1,}([.]{1}[a-zA-Z0-9]{2,}|[.]{1}[a-zA-Z0-9]{2,4}[.]{1}[a-zA-Z0-9]{2,4})$"),new RegExp("^([0-9]{4})-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])$"),new RegExp("^[0-9]*$"),new RegExp("^[+]?[0-9]{9,13}$"),new RegExp("^\\d{13,16}$");var me=function(){function n(t,e){this.width=t,this.height=e}return n.prototype.isEmpty=function(){return 0===this.height&&0===this.width},n.prototype.clone=function(){return new n(this.width,this.height)},n}(),Eie=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),GB=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},R=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Eie(t,n),t.equals=function(e,i){return e===i||!(!e||!i)&&(!e||!i||e.x===i.x&&e.y===i.y)},t.isEmptyPoint=function(e){return!(e.x&&e.y)},t.transform=function(e,i,r){var s={x:0,y:0};return s.x=Math.round(100*(e.x+r*Math.cos(i*Math.PI/180)))/100,s.y=Math.round(100*(e.y+r*Math.sin(i*Math.PI/180)))/100,s},t.findLength=function(e,i){return Math.sqrt(Math.pow(e.x-i.x,2)+Math.pow(e.y-i.y,2))},t.findAngle=function(e,i){var r=Math.atan2(i.y-e.y,i.x-e.x);return r=180*r/Math.PI,(r%=360)<0&&(r+=360),r},t.distancePoints=function(e,i){return Math.sqrt(Math.pow(i.x-e.x,2)+Math.pow(i.y-e.y,2))},t.getLengthFromListOfPoints=function(e){for(var i=0,r=0;ri.y&&!r?o.y+=s:o.y-=s:e.y===i.y?e.xi.x&&!r?o.x+=s:o.x-=s:r?(a=this.findAngle(e,i),o=this.transform(e,a,s)):(a=this.findAngle(i,e),o=this.transform(i,a,s)),o},t.direction=function(e,i){return Math.abs(i.x-e.x)>Math.abs(i.y-e.y)?e.x0)for(var r=0;rt.right||this.top>t.bottom||this.bottom=t.right&&this.top<=t.top&&this.bottom>=t.bottom},n.prototype.containsPoint=function(t,e){return void 0===e&&(e=0),this.left-e<=t.x&&this.right+e>=t.x&&this.top-e<=t.y&&this.bottom+e>=t.y},n.toBounds=function(t){for(var e=new n,i=0,r=t;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},KB=function(n){if(n)switch(n.type){case"Linear":default:return yI;case"Radial":return Rie}return yI},Pie=function(){return function n(t,e,i,r){this.left=t,this.right=e,this.top=i,this.bottom=r}}(),Jn=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),rt([I(0)],t.prototype,"left",void 0),rt([I(0)],t.prototype,"right",void 0),rt([I(0)],t.prototype,"top",void 0),rt([I(0)],t.prototype,"bottom",void 0),t}(Ee),zie=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),rt([I(45)],t.prototype,"angle",void 0),rt([I(5)],t.prototype,"distance",void 0),rt([I(.7)],t.prototype,"opacity",void 0),rt([I("lightgrey")],t.prototype,"color",void 0),t}(Ee),e3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),t.prototype.getClassName=function(){return"Stop"},rt([I("")],t.prototype,"color",void 0),rt([I(0)],t.prototype,"offset",void 0),rt([I(1)],t.prototype,"opacity",void 0),t}(Ee),Ix=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),rt([Bt([],e3)],t.prototype,"stops",void 0),rt([I("None")],t.prototype,"type",void 0),rt([I("")],t.prototype,"id",void 0),t}(Ee),yI=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),rt([I(0)],t.prototype,"x1",void 0),rt([I(0)],t.prototype,"x2",void 0),rt([I(0)],t.prototype,"y1",void 0),rt([I(0)],t.prototype,"y2",void 0),t}(Ix),Rie=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),rt([I(0)],t.prototype,"cx",void 0),rt([I(0)],t.prototype,"cy",void 0),rt([I(0)],t.prototype,"fx",void 0),rt([I(0)],t.prototype,"fy",void 0),rt([I(50)],t.prototype,"r",void 0),t}(Ix),Ll=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),rt([I("white")],t.prototype,"fill",void 0),rt([I("black")],t.prototype,"strokeColor",void 0),rt([I("")],t.prototype,"strokeDashArray",void 0),rt([I(1)],t.prototype,"strokeWidth",void 0),rt([I(1)],t.prototype,"opacity",void 0),rt([E0(KB)],t.prototype,"gradient",void 0),t}(Ee),t3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),rt([I("transparent")],t.prototype,"fill",void 0),t}(Ll),Qf=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ya(t,n),rt([I("black")],t.prototype,"color",void 0),rt([I("Arial")],t.prototype,"fontFamily",void 0),rt([I(12)],t.prototype,"fontSize",void 0),rt([I(!1)],t.prototype,"italic",void 0),rt([I(!1)],t.prototype,"bold",void 0),rt([I("CollapseSpace")],t.prototype,"whiteSpace",void 0),rt([I("WrapWithOverflow")],t.prototype,"textWrapping",void 0),rt([I("Center")],t.prototype,"textAlign",void 0),rt([I("None")],t.prototype,"textDecoration",void 0),rt([I("Wrap")],t.prototype,"textOverflow",void 0),rt([I("transparent")],t.prototype,"fill",void 0),t}(Ll),on=function(n){return n[n.Default=0]="Default",n[n.expandNode=2]="expandNode",n[n.interaction=4]="interaction",n[n.GroupingInProgress=8]="GroupingInProgress",n[n.GroupClipboardInProcess=16]="GroupClipboardInProcess",n[n.ClearObject=32]="ClearObject",n}(on||{}),Gt=function(n){return n[n.Visible=1]="Visible",n[n.Hidden=2]="Hidden",n[n.Hover=4]="Hover",n[n.Connect=8]="Connect",n}(Gt||{}),ei=function(n){return n[n.None=0]="None",n[n.ShowHorizontalLines=1]="ShowHorizontalLines",n[n.ShowVerticalLines=2]="ShowVerticalLines",n[n.ShowLines=3]="ShowLines",n[n.SnapToHorizontalLines=4]="SnapToHorizontalLines",n[n.SnapToVerticalLines=8]="SnapToVerticalLines",n[n.SnapToLines=12]="SnapToLines",n[n.SnapToObject=16]="SnapToObject",n[n.All=31]="All",n}(ei||{}),mr=function(n){return n[n.None=1]="None",n[n.ConnectorSourceThumb=2]="ConnectorSourceThumb",n[n.ConnectorTargetThumb=4]="ConnectorTargetThumb",n[n.ResizeSouthEast=8]="ResizeSouthEast",n[n.ResizeSouthWest=16]="ResizeSouthWest",n[n.ResizeNorthEast=32]="ResizeNorthEast",n[n.ResizeNorthWest=64]="ResizeNorthWest",n[n.ResizeEast=128]="ResizeEast",n[n.ResizeWest=256]="ResizeWest",n[n.ResizeSouth=512]="ResizeSouth",n[n.ResizeNorth=1024]="ResizeNorth",n[n.Rotate=2048]="Rotate",n[n.UserHandle=4096]="UserHandle",n[n.ToolTip=8192]="ToolTip",n[n.ResizeAll=2046]="ResizeAll",n[n.All=16382]="All",n}(mr||{}),qe=function(n){return n[n.None=1]="None",n[n.Select=2]="Select",n[n.Delete=4]="Delete",n[n.Drag=8]="Drag",n[n.DragSourceEnd=16]="DragSourceEnd",n[n.DragTargetEnd=32]="DragTargetEnd",n[n.DragSegmentThumb=64]="DragSegmentThumb",n[n.AllowDrop=128]="AllowDrop",n[n.Bridging=256]="Bridging",n[n.BridgeObstacle=512]="BridgeObstacle",n[n.InheritBridging=1024]="InheritBridging",n[n.PointerEvents=2048]="PointerEvents",n[n.Tooltip=4096]="Tooltip",n[n.InheritTooltip=8192]="InheritTooltip",n[n.Interaction=4218]="Interaction",n[n.ReadOnly=16384]="ReadOnly",n[n.LineRouting=32768]="LineRouting",n[n.InheritLineRouting=65536]="InheritLineRouting",n[n.ConnectToNearByNode=131072]="ConnectToNearByNode",n[n.ConnectToNearByPort=262144]="ConnectToNearByPort",n[n.ConnectToNearByElement=393216]="ConnectToNearByElement",n[n.InheritSegmentThumbShape=524288]="InheritSegmentThumbShape",n[n.InheritSegmentThumbSize=1048576]="InheritSegmentThumbSize",n[n.Default=2043454]="Default",n}(qe||{}),Nr=function(n){return n[n.ReadOnly=2]="ReadOnly",n[n.InheritReadOnly=4]="InheritReadOnly",n[n.Select=8]="Select",n[n.Drag=16]="Drag",n[n.Resize=32]="Resize",n[n.Rotate=64]="Rotate",n[n.Tooltip=128]="Tooltip",n[n.Interaction=120]="Interaction",n[n.None=0]="None",n}(Nr||{}),ie=function(n){return n[n.None=0]="None",n[n.Select=2]="Select",n[n.Drag=4]="Drag",n[n.Rotate=8]="Rotate",n[n.Shadow=16]="Shadow",n[n.PointerEvents=32]="PointerEvents",n[n.Delete=64]="Delete",n[n.InConnect=128]="InConnect",n[n.OutConnect=256]="OutConnect",n[n.Individual=512]="Individual",n[n.Expandable=1024]="Expandable",n[n.AllowDrop=2048]="AllowDrop",n[n.Inherit=78]="Inherit",n[n.ResizeNorthEast=4096]="ResizeNorthEast",n[n.ResizeEast=8192]="ResizeEast",n[n.ResizeSouthEast=16384]="ResizeSouthEast",n[n.ResizeSouth=32768]="ResizeSouth",n[n.ResizeSouthWest=65536]="ResizeSouthWest",n[n.ResizeWest=131072]="ResizeWest",n[n.ResizeNorthWest=262144]="ResizeNorthWest",n[n.ResizeNorth=524288]="ResizeNorth",n[n.Resize=1044480]="Resize",n[n.AspectRatio=1048576]="AspectRatio",n[n.Tooltip=2097152]="Tooltip",n[n.InheritTooltip=4194304]="InheritTooltip",n[n.ReadOnly=8388608]="ReadOnly",n[n.HideThumbs=16777216]="HideThumbs",n[n.AllowMovingOutsideLane=33554432]="AllowMovingOutsideLane",n[n.Default=5240814]="Default",n}(ie||{}),Xr=function(n){return n[n.None=0]="None",n[n.ElementIsPort=2]="ElementIsPort",n[n.ElementIsGroup=4]="ElementIsGroup",n[n.HorizontalLaneHeader=8]="HorizontalLaneHeader",n}(Xr||{}),bt=function(n){return n[n.Rotate=2]="Rotate",n[n.ConnectorSource=4]="ConnectorSource",n[n.ConnectorTarget=8]="ConnectorTarget",n[n.ResizeNorthEast=16]="ResizeNorthEast",n[n.ResizeEast=32]="ResizeEast",n[n.ResizeSouthEast=64]="ResizeSouthEast",n[n.ResizeSouth=128]="ResizeSouth",n[n.ResizeSouthWest=256]="ResizeSouthWest",n[n.ResizeWest=512]="ResizeWest",n[n.ResizeNorthWest=1024]="ResizeNorthWest",n[n.ResizeNorth=2048]="ResizeNorth",n[n.Default=4094]="Default",n}(bt||{}),nt=function(n){return n[n.None=1]="None",n[n.Bridging=2]="Bridging",n[n.UndoRedo=4]="UndoRedo",n[n.Tooltip=8]="Tooltip",n[n.UserInteraction=16]="UserInteraction",n[n.ApiUpdate=32]="ApiUpdate",n[n.PageEditable=48]="PageEditable",n[n.Zoom=64]="Zoom",n[n.PanX=128]="PanX",n[n.PanY=256]="PanY",n[n.Pan=384]="Pan",n[n.ZoomTextEdit=512]="ZoomTextEdit",n[n.Virtualization=1024]="Virtualization",n[n.LineRouting=2048]="LineRouting",n[n.Default=500]="Default",n}(nt||{}),ni=function(n){return n[n.None=0]="None",n[n.SingleSelect=1]="SingleSelect",n[n.MultipleSelect=2]="MultipleSelect",n[n.ZoomPan=4]="ZoomPan",n[n.DrawOnce=8]="DrawOnce",n[n.ContinuousDraw=16]="ContinuousDraw",n[n.Default=3]="Default",n}(ni||{}),Qa=function(n){return n[n.Self=1]="Self",n[n.Parent=2]="Parent",n}(Qa||{}),ft=function(n){return n[n.None=0]="None",n[n.Control=1]="Control",n[n.Meta=1]="Meta",n[n.Alt=2]="Alt",n[n.Shift=4]="Shift",n}(ft||{}),Mt=function(n){return n[n.None=null]="None",n[n.Number0=0]="Number0",n[n.Number1=1]="Number1",n[n.Number2=2]="Number2",n[n.Number3=3]="Number3",n[n.Number4=4]="Number4",n[n.Number5=5]="Number5",n[n.Number6=6]="Number6",n[n.Number7=7]="Number7",n[n.Number8=8]="Number8",n[n.Number9=9]="Number9",n[n.A=65]="A",n[n.B=66]="B",n[n.C=67]="C",n[n.D=68]="D",n[n.E=69]="E",n[n.F=70]="F",n[n.G=71]="G",n[n.H=72]="H",n[n.I=73]="I",n[n.J=74]="J",n[n.K=75]="K",n[n.L=76]="L",n[n.M=77]="M",n[n.N=78]="N",n[n.O=79]="O",n[n.P=80]="P",n[n.Q=81]="Q",n[n.R=82]="R",n[n.S=83]="S",n[n.T=84]="T",n[n.U=85]="U",n[n.V=86]="V",n[n.W=87]="W",n[n.X=88]="X",n[n.Y=89]="Y",n[n.Z=90]="Z",n[n.Left=37]="Left",n[n.Up=38]="Up",n[n.Right=39]="Right",n[n.Down=40]="Down",n[n.Escape=27]="Escape",n[n.Space=32]="Space",n[n.PageUp=33]="PageUp",n[n.PageDown=34]="PageDown",n[n.End=35]="End",n[n.Home=36]="Home",n[n.Delete=46]="Delete",n[n.Tab=9]="Tab",n[n.Enter=13]="Enter",n[n.BackSpace=8]="BackSpace",n[n.F1=112]="F1",n[n.F2=113]="F2",n[n.F3=114]="F3",n[n.F4=115]="F4",n[n.F5=116]="F5",n[n.F6=117]="F6",n[n.F7=118]="F7",n[n.F8=119]="F8",n[n.F9=120]="F9",n[n.F10=121]="F10",n[n.F11=122]="F11",n[n.F12=123]="F12",n[n.Star=56]="Star",n[n.Plus=187]="Plus",n[n.Minus=189]="Minus",n[n.BracketLeft=219]="BracketLeft",n[n.BracketRight=221]="BracketRight",n}(Mt||{}),ee=function(n){return n[n.Render=2]="Render",n[n.PublicMethod=4]="PublicMethod",n[n.ToolAction=8]="ToolAction",n[n.UndoRedo=16]="UndoRedo",n[n.TextEdit=32]="TextEdit",n[n.Group=64]="Group",n[n.Clear=128]="Clear",n[n.PreventClearSelection=256]="PreventClearSelection",n[n.Interactions=512]="Interactions",n[n.PreventHistory=1024]="PreventHistory",n[n.PreventIconsUpdate=2048]="PreventIconsUpdate",n[n.PreventCollectionChangeOnDragOver=4096]="PreventCollectionChangeOnDragOver",n[n.PreventZIndexOnDragging=8192]="PreventZIndexOnDragging",n[n.isGroupDragging=16384]="isGroupDragging",n[n.DragUsingMouse=32768]="DragUsingMouse",n[n.DecoratorPropertyChange=65536]="DecoratorPropertyChange",n[n.PreventLaneContainerUpdate=131072]="PreventLaneContainerUpdate",n}(ee||{}),Ga=function(n){return n[n.None=2]="None",n[n.DrawSelectorBorder=4]="DrawSelectorBorder",n[n.PreventRenderSelector=8]="PreventRenderSelector",n}(Ga||{}),$i=function(n){return n[n.None=0]="None",n[n.PreventDrag=2]="PreventDrag",n[n.PreventScale=4]="PreventScale",n[n.PreventDataInit=8]="PreventDataInit",n[n.hScrollbarMoved=16]="hScrollbarMoved",n[n.vScrollbarMoved=32]="vScrollbarMoved",n[n.AnimationClick=64]="AnimationClick",n[n.EnableGroupAction=128]="EnableGroupAction",n[n.PanInProgress=256]="PanInProgress",n[n.OverViewAction=512]="OverViewAction",n}($i||{}),da=function(n){return n[n.None=0]="None",n[n.PropertyChange=1024]="PropertyChange",n[n.Interaction=2048]="Interaction",n}(da||{}),Ae=function(n){return n[n.Zero=0]="Zero",n[n.One=1]="One",n[n.Two=2]="Two",n[n.Three=3]="Three",n[n.Four=4]="Four",n[n.Five=5]="Five",n}(Ae||{}),Ce=function(n){return n[n.collectionChange=0]="collectionChange",n[n.rotateChange=1]="rotateChange",n[n.positionChange=2]="positionChange",n[n.propertyChange=3]="propertyChange",n[n.selectionChange=4]="selectionChange",n[n.sizeChange=5]="sizeChange",n[n.drop=6]="drop",n[n.sourcePointChange=7]="sourcePointChange",n[n.targetPointChange=8]="targetPointChange",n[n.connectionChange=9]="connectionChange",n[n.animationComplete=10]="animationComplete",n[n.click=11]="click",n[n.doubleClick=12]="doubleClick",n[n.scrollChange=13]="scrollChange",n[n.dragEnter=14]="dragEnter",n[n.dragLeave=15]="dragLeave",n[n.dragOver=16]="dragOver",n[n.textEdit=17]="textEdit",n[n.paletteSelectionChange=18]="paletteSelectionChange",n[n.historyChange=19]="historyChange",n[n.mouseEnter=20]="mouseEnter",n[n.mouseLeave=21]="mouseLeave",n[n.mouseOver=22]="mouseOver",n[n.expandStateChange=23]="expandStateChange",n[n.segmentCollectionChange=24]="segmentCollectionChange",n[n.commandExecute=25]="commandExecute",n[n.historyStateChange=26]="historyStateChange",n[n.onUserHandleMouseDown=27]="onUserHandleMouseDown",n[n.onUserHandleMouseUp=28]="onUserHandleMouseUp",n[n.onUserHandleMouseEnter=29]="onUserHandleMouseEnter",n[n.onUserHandleMouseLeave=30]="onUserHandleMouseLeave",n[n.onImageLoad=31]="onImageLoad",n[n.onDoBindingInit=32]="onDoBindingInit",n[n.keyUp=33]="keyUp",n[n.keyDown=34]="keyDown",n[n.fixedUserHandleClick=35]="fixedUserHandleClick",n[n.elementDraw=36]="elementDraw",n[n.mouseWheel=37]="mouseWheel",n[n.segmentChange=38]="segmentChange",n[n.onFixedUserHandleMouseDown=39]="onFixedUserHandleMouseDown",n[n.onFixedUserHandleMouseUp=40]="onFixedUserHandleMouseUp",n[n.onFixedUserHandleMouseEnter=41]="onFixedUserHandleMouseEnter",n[n.onFixedUserHandleMouseLeave=42]="onFixedUserHandleMouseLeave",n[n.loaded=43]="loaded",n}(Ce||{}),ai=function(n){return n[n.None=1]="None",n[n.Drag=2]="Drag",n[n.Draw=4]="Draw",n[n.InConnect=8]="InConnect",n[n.OutConnect=16]="OutConnect",n[n.ToolTip=32]="ToolTip",n[n.InheritTooltip=64]="InheritTooltip",n[n.Default=24]="Default",n}(ai||{}),bx=function(n){return n[n.None=1]="None",n[n.Source=2]="Source",n[n.Target=4]="Target",n[n.Intermediate=8]="Intermediate",n[n.All=14]="All",n}(bx||{}),SI=function(n){return n[n.None=0]="None",n[n.SymmetricAngle=2]="SymmetricAngle",n[n.SymmetricDistance=4]="SymmetricDistance",n[n.Default=6]="Default",n}(SI||{}),hs=function(){function n(){this.pivot={x:.5,y:.5},this.isDirt=!0,this.isExport=!1,this.exportScaleValue={x:0,y:0},this.exportScaleOffset={x:0,y:0},this.canApplyStyle=!0,this.visible=!0,this.offsetX=0,this.offsetY=0,this.cornerRadius=0,this.minHeight=void 0,this.minWidth=void 0,this.maxWidth=void 0,this.maxHeight=void 0,this.width=void 0,this.height=void 0,this.rotateAngle=0,this.margin={left:0,right:0,top:0,bottom:0},this.connectionDirection="Auto",this.horizontalAlignment="Auto",this.verticalAlignment="Auto",this.flip="None",this.flipMode="All",this.relativeMode="Point",this.transform=Qa.Self|Qa.Parent,this.style={fill:"white",strokeColor:"black",opacity:1,strokeWidth:1},this.desiredSize=new me,this.actualSize=new me,this.parentTransform=0,this.preventContainer=!1,this.isSvgRender=!1,this.bounds=new Ne(0,0,0,0),this.shadow=null,this.description="",this.staticSize=!1,this.shapeType="",this.isRectElement=!1,this.isCalculateDesiredSize=!0,this.flipOffset={x:0,y:0},this.elementActions=Xr.None,this.inversedAlignment=!0,this.position=void 0,this.unitMode=void 0,this.float=!1,this.floatingBounds=void 0}return n.prototype.setOffsetWithRespectToBounds=function(t,e,i){this.unitMode=i,this.position={x:t,y:e}},n.prototype.getAbsolutePosition=function(t){if(void 0!==this.position)return"Absolute"===this.unitMode?this.position:{x:this.position.x*t.width,y:this.position.y*t.height}},Object.defineProperty(n.prototype,"outerBounds",{get:function(){return this.floatingBounds||this.bounds},set:function(t){this.floatingBounds=t},enumerable:!0,configurable:!0}),n.prototype.measure=function(t,e,i){var s=void 0!==this.height?this.height:(t.height||0)-this.margin.top-this.margin.bottom;return this.id&&0===s&&this.elementActions&Xr.HorizontalLaneHeader&&(s=this.actualSize.height),this.desiredSize=new me(void 0!==this.width?this.width:(t.width||0)-this.margin.left-this.margin.right,s),this.isCalculateDesiredSize&&(this.desiredSize=this.validateDesiredSize(this.desiredSize,t)),this.desiredSize},n.prototype.arrange=function(t){return this.actualSize=t,this.updateBounds(),this.actualSize},n.prototype.updateBounds=function(){this.bounds=yr(this)},n.prototype.validateDesiredSize=function(t,e){return this.isRectElement&&!this.width&&!this.minWidth&&!this.maxWidth&&(t.width=50),this.isRectElement&&!this.height&&!this.minHeight&&!this.maxHeight&&(t.height=50),(void 0===t||void 0!==this.width&&void 0!==this.height)&&((t=t||new me).width=void 0===this.width?(e.width||0)-this.margin.left-this.margin.right:this.width,t.height=void 0===this.height?(e.height||0)-this.margin.top-this.margin.bottom:this.height),void 0!==this.minWidth&&(t.width=Math.max(t.width,this.minWidth)),void 0!==this.minHeight&&(t.height=Math.max(t.height,this.minHeight)),void 0!==this.maxWidth&&0!==this.maxWidth&&(t.width=Math.min(t.width,this.maxWidth)),void 0!==this.maxHeight&&0!==this.maxHeight&&(t.height=Math.min(t.height,this.maxHeight)),t},n}(),Vie=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Cs=function(n){function t(){var e=null!==n&&n.apply(this,arguments)||this;return e.padding=new Pie(0,0,0,0),e.desiredBounds=void 0,e.measureChildren=!0,e.prevRotateAngle=0,e}return Vie(t,n),t.prototype.hasChildren=function(){return void 0!==this.children&&this.children.length>0},t.prototype.measure=function(e,i,r){this.desiredBounds=void 0;var o,a,s=void 0;if(this.hasChildren()){for(var l=0;l=n.width&&s.length>0)i[i.length]={text:s,x:0,dy:0,width:o},s="";else{(s+=a[r+1]||"").indexOf("\n")>-1&&(i[i.length]={text:s,x:0,dy:0,width:Bc(s,n)},s="");var l=Bc(s,n);Math.ceil(l)+2>=n.width&&s.length>0&&(i[i.length]={text:s,x:0,dy:0,width:l},s=""),r===a.length-1&&s.length>0&&(i[i.length]={text:s,x:0,dy:0,width:l},s="")}else i=function loe(n,t,e){var c,d,u,f,i=[],r="",s=0,o=0,a="nowrap"!==n.whiteSpace,h=(t||n.content).split("\n");for(s=0;s0?" ":"")+c[parseInt(o.toString(),10)];var p=Bc(d=c[o+1]?r+" "+c[o+1]:r,n);Math.floor(p)>(e||n.width)-2&&r.length>0?(i[i.length]={text:r,x:0,dy:0,width:d===r?p:r===f?u:Bc(r,n)},r=""):o===c.length-1&&(i[i.length]={text:r,x:0,dy:0,width:p},r=""),f=d,u=p}return i}(n,t,e);else i[i.length]={text:a,x:0,dy:0,width:Bc(a,n)};return i}(l,r,n.isLaneOrientation?i:void 0),n.wrapBounds=a=function hoe(n,t){var r,s,e={x:0,width:0},i=0;for(i=0;in.width&&("Ellipsis"===n.textOverflow||"Clip"===n.textOverflow)?0:-r/2:"right"===n.textAlign?-r:t.length>1?0:-r/2,t[parseInt(i.toString(),10)].dy=1.2*n.fontSize,t[parseInt(i.toString(),10)].x=r,e.x=Math.min(e.x,r),e.width=Math.max(e.width,s);return e}(l,o),s.width=a.width,n.wrapBounds.width>=i&&"Wrap"!==l.textOverflow&&(s.width=i),s.height=o.length*n.style.fontSize*1.2,s}(this,0,0,this.isLaneOrientation?e.height:this.width||e.width):this.desiredSize,this.desiredSize=void 0===this.width||void 0===this.height?new me(i.width,i.height):new me(this.width,this.height),this.desiredSize=this.validateDesiredSize(this.desiredSize,e),this.desiredSize},t.prototype.arrange=function(e){return(e.width!==this.actualSize.width||e.height!==this.actualSize.height||this.isDirt)&&(this.doWrap=!0),this.actualSize=e,this.updateBounds(),this.isDirt=!1,this.actualSize},t}(hs),Yie=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Mi=function(n){function t(){var e=null!==n&&n.apply(this,arguments)||this;return e.measureChildren=void 0,e}return Yie(t,n),t.prototype.measure=function(e,i,r){var s=void 0,o=void 0;if(this.hasChildren()){for(var a=0,l=this.children;a=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Dd=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return $ie(t,n),Oh([I("")],t.prototype,"content",void 0),Oh([I("TopLeft")],t.prototype,"position",void 0),Oh([I("Mouse")],t.prototype,"relativeMode",void 0),Oh([I(!0)],t.prototype,"showTipPointer",void 0),Oh([I("auto")],t.prototype,"width",void 0),Oh([I("auto")],t.prototype,"height",void 0),Oh([I("Auto")],t.prototype,"openOn",void 0),Oh([I()],t.prototype,"animation",void 0),Oh([I(!1)],t.prototype,"isSticky",void 0),t}(Ee);function i3(n){var t=new bh;t=r3(n.tooltip,t);var e=new bh(t);return e.beforeCollision=Jie,e.beforeOpen=Zie,e.cssClass="e-diagram-tooltip",e.opensOn="custom",e.appendTo("#"+n.element.id),e.close(),e}function Zie(n){(""===this.content||void 0===this.content)&&(n.element.style.display="none")}function Jie(n){n.collidedPosition&&n.collidedPosition!==this.position&&(n.element.style.display="none")}function Mx(n,t){var e=n.tooltipObject;return r3(t?t.tooltip:n.tooltip,e),e}function r3(n,t){return n.content?(t.content=n.content,"string"==typeof n.content&&(t.content=ko(function(){return n.content})),t.position=n.position,t.showTipPointer=n.showTipPointer,t.width=n.width,t.height=n.height,t.animation=n.animation?n.animation:{close:{effect:"None"}}):t.close(),t}var wx=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Bn=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Cx=function(n){function t(e,i,r,s){var o=n.call(this,e,i,r,s)||this;return o.inEdges=[],o.outEdges=[],o}return wx(t,n),Bn([I("")],t.prototype,"id",void 0),Bn([I("Center")],t.prototype,"horizontalAlignment",void 0),Bn([I("Center")],t.prototype,"verticalAlignment",void 0),Bn([re({},Jn)],t.prototype,"margin",void 0),Bn([I(12)],t.prototype,"width",void 0),Bn([I(12)],t.prototype,"height",void 0),Bn([re({},Ll)],t.prototype,"style",void 0),Bn([I("Square")],t.prototype,"shape",void 0),Bn([I("Auto")],t.prototype,"connectionDirection",void 0),Bn([I(Gt.Connect)],t.prototype,"visibility",void 0),Bn([I("")],t.prototype,"pathData",void 0),Bn([I(ai.Default)],t.prototype,"constraints",void 0),Bn([I()],t.prototype,"addInfo",void 0),Bn([I()],t.prototype,"outEdges",void 0),Bn([I()],t.prototype,"inEdges",void 0),Bn([re({},Dd)],t.prototype,"tooltip",void 0),t}(Ee),Es=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return wx(t,n),t.prototype.getClassName=function(){return"PointPort"},Bn([re({x:.5,y:.5},R)],t.prototype,"offset",void 0),t}(Cx),Tc=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return wx(t,n),t.prototype.getClassName=function(){return"PathPort"},Bn([I(.5)],t.prototype,"offset",void 0),Bn([re({x:0,y:0},R)],t.prototype,"displacement",void 0),Bn([I("Center")],t.prototype,"alignment",void 0),t}(Cx),MI=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),lr=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Kie=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return MI(t,n),lr([I("blue")],t.prototype,"color",void 0),lr([I("")],t.prototype,"content",void 0),lr([I("")],t.prototype,"link",void 0),lr([I("None")],t.prototype,"textDecoration",void 0),lr([I("NewTab")],t.prototype,"hyperlinkOpenState",void 0),t}(Ee),Ex=function(n){function t(e,i,r,s){var o=n.call(this,e,i,r,s)||this;return r.id||(o.id=e.parentObj&&e.parentObj.propName&&"phases"===e.parentObj.propName?e.parentObj.id:Qe()),o}return MI(t,n),lr([I("")],t.prototype,"content",void 0),lr([I(void 0)],t.prototype,"template",void 0),lr([I("String")],t.prototype,"annotationType",void 0),lr([I(!0)],t.prototype,"visibility",void 0),lr([I(Nr.InheritReadOnly)],t.prototype,"constraints",void 0),lr([re(void 0,Kie)],t.prototype,"hyperlink",void 0),lr([I("")],t.prototype,"id",void 0),lr([I()],t.prototype,"width",void 0),lr([I()],t.prototype,"height",void 0),lr([I(0)],t.prototype,"rotateAngle",void 0),lr([I("Parent")],t.prototype,"rotationReference",void 0),lr([re({strokeWidth:0,strokeColor:"transparent",fill:"transparent"},Qf)],t.prototype,"style",void 0),lr([I("Center")],t.prototype,"horizontalAlignment",void 0),lr([I("Center")],t.prototype,"verticalAlignment",void 0),lr([re({},Jn)],t.prototype,"margin",void 0),lr([re({top:void 0,bottom:void 0,left:void 0,right:void 0},Jn)],t.prototype,"dragLimit",void 0),lr([I("Shape")],t.prototype,"type",void 0),lr([re({},Dd)],t.prototype,"tooltip",void 0),lr([I()],t.prototype,"addInfo",void 0),t}(Ee),Kn=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return MI(t,n),t.prototype.getClassName=function(){return"ShapeAnnotation"},lr([re({x:.5,y:.5},R)],t.prototype,"offset",void 0),t}(Ex),Or=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return MI(t,n),t.prototype.getClassName=function(){return"PathAnnotation"},lr([I(.5)],t.prototype,"offset",void 0),lr([re({x:0,y:0},R)],t.prototype,"displacement",void 0),lr([I("Center")],t.prototype,"alignment",void 0),lr([I(!1)],t.prototype,"segmentAngle",void 0),t}(Ex);function Dx(n){return rre[n.toString()]}function n3(n){return ore[""+n]}var rre={X:"M14,14 L106,106 M106,14 L14,106",Circle:"M0,50 A50,50,0 1 1 100,50 A50,50,0 1 1 0,50 Z",Square:"M0,0 L10,0 L10,10 L0,10 z"},nre={OpenArrow:"M15.9,23 L5,16 L15.9,9 L17,10.7 L8.7,16 L17,21.3Z",Square:"M0,0 L10,0 L10,10 L0,10 z",Fletch:"M14.8,10c0,0-3.5,6,0.2,12c0,0-2.5-6-10.9-6C4.1,16,11.3,16,14.8,10z",OpenFetch:"M6,17c-0.6,0-1-0.4-1-1s0.4-1,1-1c10.9,0,11-5,11-5c0-0.6,0.4-1,1-1s1,0.4,1,1C19,10.3,18.9,17,6,17C6,17,6,17,6,17z M18,23c-0.5,0-1-0.4-1-1c0-0.2-0.3-5-11-5c-0.6,0-1-0.5-1-1s0.4-1,1-1c0,0,0,0,0,0c12.9,0,13,6.7,13,7 C19,22.6,18.6,23,18,23z",IndentedArrow:"M17,10c0,0-4.5,5.5,0,12L5,16L17,10z",OutdentedArrow:"M14.6,10c0,0,5.4,6,0,12L5,16L14.6,10z",DoubleArrow:"M19,10 L19,22 L13,16Z M12,10 L12,22 L6,16Z",Arrow:"M15,10 L15,22 L5,16Z",Diamond:"M12,23l-7-7l7-7l6.9,7L12,23z",Circle:"M0,50 A50,50,0 1 1 100,50 A50,50,0 1 1 0,50 Z"},sre={Square:"M0,0 L10,0 L10,10 L0,10 z",Rhombus:"M10,5 L5,10 L0,5 L5,0 L10,5 Z ",Rectangle:"M0,0 L15,0 L15,10 L0,10 z ",OpenArrow:"M15.9,23 L5,16 L15.9,9 L17,10.7 L8.7,16 L17,21.3Z",Fletch:"M9.82,0 C9.82,0,6.61,5,10,10 C10,10,7.71,5,0,5 C0,5,6.61,5,9.82,0 Z ",OpenFetch:"M0.71,5.71 C0.29,5.71,0,5.43,0,5 C0,4.57,0.29,4.29,0.71,4.29 C8.5,4.29,8.57,0.71,8.57,0.71 C8.57,0.29,8.86,0,9.29,0 C9.719999999999999,0,10,0.29,10,0.71 C10,0.93,9.93,5.71,0.71,5.71 C0.71,5.71,0.71,5.71,0.71,5.71 Z M9.29,10 C8.93,10,8.57,9.71,8.57,9.29 C8.57,9.14,8.36,5.71,0.71,5.71 C0.29,5.71,0,5.36,0,5 C0,4.64,0.29,4.29,0.71,4.29 C0.71,4.29,0.71,4.29,0.71,4.29 C9.93,4.29,10,9.07,10,9.29 C10,9.71,9.71,10,9.29,10 Z ",IndentedArrow:"M10,0 C10,0,6.25,4.58,10,10 L0,5 L10,0 Z ",OutdentedArrow:"M8,0 C8,0,12.5,5,8,10 L0,5 L8,0 Z ",DoubleArrow:"M19,10 L19,22 L13,16Z M12,10 L12,22 L6,16Z",Arrow:"M15,10 L15,22 L5,16Z",Diamond:"M10,5 L5,10 L0,5 L5,0 L10,5 Z ",Circle:"M10,5 C10,7.76,7.76,10,5,10 C2.24,10,0,7.76,0,5 C0,2.24,2.24,0,5,0 C7.76,0,10,2.24,10,5 Z ",Ellipse:"M15,5 C15,7.76,11.64,10,7.5,10 C3.36,10,0,7.76,0,5 C0,2.24,3.36,0,7.5,0 C11.64,0,15,2.24,15,5 Z "},ore={Square:"M0,0 L10,0 L10,10 L0,10 z",Rhombus:"M10,5 L5,10 L0,5 L5,0 L10,5 Z ",Rectangle:"M0,0 L15,0 L15,10 L0,10 z",OpenArrow:"M23,15.9 L16,5 L9,15.9 L10.7,17 L16,8.7 L21,17.3Z",Fletch:"M9.82,0 C9.82,0,6.61,5,10,10 C10,10,7.71,5,0,5 C0,5,6.61,5,9.82,0 Z ",OpenFetch:"M0.71,5.71 C0.29,5.71,0,5.43,0,5 C0,4.57,0.29,4.29,0.71,4.29 C8.5,4.29,8.57,0.71,8.57,0.71 C8.57,0.29,8.86,0,9.29,0 C9.719999999999999,0,10,0.29,10,0.71 C10,0.93,9.93,5.71,0.71,5.71 C0.71,5.71,0.71,5.71,0.71,5.71 Z M9.29,10 C8.93,10,8.57,9.71,8.57,9.29 C8.57,9.14,8.36,5.71,0.71,5.71 C0.29,5.71,0,5.36,0,5 C0,4.64,0.29,4.29,0.71,4.29 C0.71,4.29,0.71,4.29,0.71,4.29 C9.93,4.29,10,9.07,10,9.29 C10,9.71,9.71,10,9.29,10 Z ",IndentedArrow:"M10,0 C10,0,6.25,4.58,10,10 L0,5 L10,0 Z ",OutdentedArrow:"M8,0 C8,0,12.5,5,8,10 L0,5 L8,0 Z ",DoubleArrow:"M10,19 L22,19 L16,13Z M10,12 L22,12 L16,6Z",Arrow:"M10,15 L22,15 L16,5Z",Diamond:"M10,5 L5,10 L0,5 L5,0 L10,5 Z ",Circle:"M10,5 C10,7.76,7.76,10,5,10 C2.24,10,0,7.76,0,5 C0,2.24,2.24,0,5,0 C7.76,0,10,2.24,10,5 Z ",Ellipse:"M15,5 C15,7.76,11.64,10,7.5,10 C3.36,10,0,7.76,0,5 C0,2.24,3.36,0,7.5,0 C11.64,0,15,2.24,15,5 Z "};function xx(n){return are[n.toString()]}var are={Process:"M419.511,76.687L359.511,76.687L359.511,43.086L419.511,43.086z",Decision:"M 253.005,115.687L 200.567,146.071L 148.097,115.687L 200.534,85.304L 253.005,115.687 Z",Document:"M 60 31.9 c 0 0 -11 -7.7 -30 0 s -30 0 -30 0 V 0 h 60 V 31.9 Z",PreDefinedProcess:"M 0,0 L 50,0 L 50,50 L 0,50 Z M 8.334,0 L 8.334,50 M 41.667,0 L 41.667,50",Terminator:"M 269.711,29.33C 269.71,44.061 257.77,56 243.04,56L 158.058,56C 143.33,56 131.39,44.061 131.39,29.33L 131.39,29.33C 131.391,14.6057 143.33,2.669 158.058,2.669L 243.044,2.669C 257.772,2.669 269.711,14.6057 269.711,29.333 Z",PaperTap:"M0.0009,17.2042 L0.0009,47.165 C0.001,47.165 14.403,53.5455 25.00,47.165 C35.599,40.7852 44.403,43.5087 50.00,47.165L50.001,17.2042 M50.001,32.7987 L50.001,2.8405 C50.001,2.8405 35.599,-3.5427 25.001,2.8405C14.403,9.2237 5.599,6.494 0.0009,2.8405 L0.0009,32.7987",DirectData:"M 132.62 0 L 17.38 0 C 7.78 0 0 13.43 0 30 C 0 46.57 7.78 60 17.38 60 L 132.62 60 M 132.62 0C 123.02 0 115.24 13.43 115.24 30 C 115.24 46.57 123.02 60 132.62 60 C 142.22 60 150 46.57 150 30 C 150 13.43 142.22 0 132.62 0 z ",SequentialData:"M0.0029,24.999 C0.0029,11.1922 10.433,0.0021 23.295,0.0021 C36.159,0.00216 46.585,11.1922 46.585,24.999C46.585,38.8057 36.159,49.9979 23.295,49.9979 C10.433,49.9979 0.0029,38.8057 0.0029,24.999 z M23.294,49.999 L50.002,49.999",Sort:"M50.001,24.9971 L25.001,49.9971 L0.00097,24.9971 L25.001,-0.00286865 L50.001,24.9971 z M0.000976562,24.9971 L50.001,24.9971",MultiDocument:"M43.6826,40 C44.8746,40.6183 45.8586,41.3502 46.8366,42.1122 L46.8366,4.74487 L3.09857,4.74487 L3.09857,10.9544 M46.837,35.143 C48.027,35.765 49.025,36.604 50.003,37.369 L50.003,0.002 L6.264,0.002 L6.264,4.744 M43.682,47.113 L43.682,10.765 L0.0025,10.7652 L0.0025,47.1132 C0.0025,47.1132 12.5846,53.6101 21.8426,47.1132 C31.1006,40.6163 38.792,43.393 43.6826,47.1132 z",Collate:"M50.001,0.0028 L25.001,25.0029 L0.00097,0.0028 L50.001,0.002 z M0.0009,50.002 L25.001,25.002L50.001,50.002 L0.0009,50.0029 z",SummingJunction:"M7.3252,42.6768 L42.6772,7.3247 M42.6768,42.6768 L7.3248,7.3247 M0.0009,25.001 C0.0009,11.193 11.197,0.0009 25.001,0.0009 C38.809,0.0009 50.001,11.193 50.001,25.001 C50.001,38.809 38.809,50.001 25.001,50.001 C11.197,50.00 0.0009,38.809 0.0009,25.00 z",Or:"M 0 50 L 100 50 M 50 100 L 50 0.0 M 0 50 C 0 22.384 22.392 0 50 0 C 77.616 0 100 22.384 100 50 C 100 77.616 77.616 100 50 100 C 22.392 100 0 77.616 0 50 Z",InternalStorage:"M 0 3.81946A 2.5,3.81946 0 0,1 2.5,0L 47.5 0A 2.5,3.81946 0 0,1 50,3.81946L 50 45.836A 2.5,3.819446 0 0,1 47.5,49.652778L 2.5 49.652778A 2.5,3.819446 0 0,1 0,45.8336L 0 3.819446ZM 0 11.45834L 50 11.4583334M 12.5 0L 12.5 49.652778",Extract:"M0,35 L30,0 L60,35 Z",ManualOperation:"M46.4,28.8 L14.8,28.8 L0,0 L60,0 Z",Merge:"M60,0 L30,35 L0,0 Z",OffPageReference:"M60,33.3 L30.1,39 L0,33.3 L0,0 L60,0 Z",SequentialAccessStorage:"M 60 30 C 60 13.4 46.6 0 30 0 S 0 13.4 0 30 s 13.4 30 30 30 h 28.6 v -6.5 h -9.9C 55.5 48 60 39.5 60 30 Z",Annotation:"M49.9984,50.0029 L-0.00271199,50.0029 L-0.00271199,0.00286865 L49.9984,0.00286865",Annotation2:"M49.9977,50.0029 L25.416,50.0029 L25.416,0.00286865 L49.9977,0.00286865 M25.4166,25.0029 L-0.00227869,25.0029",Data:"M 10 0 L 40 0 L 30 40 L 0 40 Z",Card:"M275,60 L400,60 L400,110 L260,110 L260,75 Z",Delay:"M0,0 L12.029,0 C14.212999,0 16,1.7869979 16,3.9709952 C16,6.1549926 14.212999,7.9409904 12.029,7.9409904 L0,7.9409904 z",Preparation:"M 1048.17 572 C 1051.06 568.86 1055.17 567.05 1059.5 567 L 1094.51 567 C 1098.84 567.05 1102.95 568.86 1105.84 572 L 1126.43 595 C 1127.01 596.28 1127.01 597.72 1126.43 599 L 1105.84 622 C 1102.95 625.14 1098.84 626.95 1094.51 627 L 1059.5 627 C 1055.17 626.95 1051.06 625.14 1048.17 622 L 1027.58 599 C 1027 597.72 1027 596.28 1027.58 595 L 1048.17 572 Z",Display:"M47.8809,19.2914 L32.7968,-0.00594145 L11.3902,-0.00594145 C7.93166,-0.00594145 0.00124586,11.187 0.00124586,24.9968C0.00124586,38.8032 7.93166,49.9962 11.3902,49.9962 L32.7968,49.99 L47.615,31.038 C47.615,31.0388 52.798,24.9968 47.880,19.2914 z",ManualInput:"M 912 732 L 1006.85 707 C 1008.2 707 1009.5 707.53 1010.46 708.46 C 1011.41 709.4 1011.95 710.67 1011.95 712 L 1011.95 762C 1012 764.41 1010.28 766.52 1007.87 767 L 917.1 767 C 915.75 767 914.45 766.47 913.49 765.54 C 912.54 764.6 912 763.33 912 762 L 912 732 Z",LoopLimit:"M 8 9 L 27 9 L 33 15 L 33 26 C 33 27 33 27 32 27 L 4 27 C 3 27 2 27 2 26 L 2 15 L 8 9 Z",StoredData:"M 5.55 0L 50 0A 1.5,30 0 0,1 50,0A 5.555,25 0 0,0 50,50A 1.5,30 0 0,1 50,50L 5.555 50A 5.55,25 0 0,1 5.555,0Z"};function s3(n,t,e){var i;i="Straight"!==n.type&&n.sourceWrapper?n.sourceWrapper.corners.center:function lre(n){var t;if(n.sourcePortWrapper){var e=n.sourcePortWrapper;t={x:e.offsetX,y:e.offsetY}}else t=n.sourceID&&n.sourceWrapper&&n.targetWrapper?qa(n,0,n.sourceWrapper.corners.center,n.targetWrapper.corners.center,!1):n.sourcePoint;return t}(n);var r=function cre(n,t,e,i,r){var b,M,s=n.sourceWrapper,o=n.targetWrapper,a=n.sourcePortWrapper,l=n.targetPortWrapper,d=[],p=Xa(n),y={corners:undefined,point:t,direction:undefined,margin:{left:5,right:5,bottom:5,top:5}},S={corners:undefined,point:e,direction:undefined,margin:{left:5,right:5,bottom:5,top:5}};if(void 0!==s&&void 0!==o&&(b=xn(s),M=xn(o),y.corners=s.corners,S.corners=o.corners),void 0!==a&&(y.direction="Left"===a.connectionDirection||"Top"===a.connectionDirection||"Bottom"===a.connectionDirection||"Right"===a.connectionDirection?a.connectionDirection:zo({x:a.offsetX,y:a.offsetY},b,s.bounds)),void 0!==l&&(S.direction="Left"===l.connectionDirection||"Right"===l.connectionDirection||"Bottom"===l.connectionDirection||"Top"===l.connectionDirection?l.connectionDirection:zo({x:l.offsetX,y:l.offsetY},M,o.bounds)),"Bezier"===n.type&&!n.isBezierEditing&&n.segments.length>0)for(var D=n.segments.length-1;D>=0;)n.segments[parseInt(D.toString(),10)].isInternalSegment&&n.segments.pop(),D--;if(void 0!==s&&void 0!==o)return(void 0===y.direction||void 0===S.direction)&&(i?function hre(n,t,e){"LeftToRight"===e?(n.direction=n.direction?n.direction:"Right",t.direction=t.direction?t.direction:"Left"):"RightToLeft"===e?(n.direction=n.direction?n.direction:"Left",t.direction=t.direction?t.direction:"Right"):"TopToBottom"===e?(n.direction=n.direction?n.direction:"Bottom",t.direction=t.direction?t.direction:"Top"):"BottomToTop"===e&&(n.direction=n.direction?n.direction:"Top",t.direction=t.direction?t.direction:"Bottom")}(y,S,i):y.corners.top>S.corners.bottom&&Math.abs(y.corners.top-S.corners.bottom)>p?(y.direction=y.direction?y.direction:"Top",S.direction=S.direction?S.direction:"Bottom"):y.corners.bottomp?(y.direction=y.direction?y.direction:"Bottom",S.direction=S.direction?S.direction:"Top"):y.corners.rightp||y.corners.right+p=y.corners.left-p&&y.corners.left>S.corners.left?(y.direction=y.direction?y.direction:"Right",S.direction=S.direction?S.direction:"Left"):y.corners.left>S.corners.right&&Math.abs(y.corners.left-S.corners.right)>y.margin.left+y.margin.right||S.corners.right+p=S.corners.left-p&&y.corners.left0&&n.segments[0].direction&&(y.direction=n.segments[0].direction),y.point=Nl(b,y.direction),d=Nl(b,_n(y.direction)),y.point=qa(n,0,y.point,d,!1)):y.point=o.corners.center;if(void 0!==h){switch(S.point={x:h.offsetX,y:h.offsetY},S.direction){case"Bottom":case"Top":S.point.y=S.point.y;break;case"Left":case"Right":S.point.x=S.point.x}n.targetPadding&&!w&&(S.point=wI(n,y,S,!0))}else"Orthogonal"===n.type||"Bezier"===n.type?(S.point=Nl(M,S.direction),d=Nl(M,_n(S.direction)),S.point=qa(n,0,S.point,d,!0)):S.point=a.corners.center;if("Orthogonal"!==n.type){var C=void 0,D=void 0;if("Bezier"===n.type){if(n.bezierSettings.allowSegmentsReset||0===n.segments.length||!R.isEmptyPoint(n.segments[n.segments.length-1].point))return c=g3(n,y,S,void 0,s),Tx(n,y,S);Bv(n)}else Bv(n);if(void 0===n.sourcePortWrapper){y.point=y.corners.center,n.segments&&n.segments.length>0&&(C=R.isEmptyPoint((D=n.segments[0]).point)?void 0:D);var A=void 0!==C?C.point:S.point;if("Bezier"===n.type&&n.segments.length>0&&n.segments[0].vector1.angle&&n.segments[0].vector1.distance){var x=Math.max(y.corners.width,y.corners.height);A=R.transform(y.point,n.segments[0].vector1.angle,x/2)}y.point=w?n.sourceWrapper.bounds.center:qa(n,0,y.point,A,!1)}if(void 0===n.targetPortWrapper){S.point=S.corners.center,n.segments&&n.segments.length>1&&(C=R.isEmptyPoint((D=n.segments[n.segments.length-2]).point)?void 0:D);var P=C?C.point:y.point;"Bezier"===n.type&&n.segments.length>0&&n.segments[n.segments.length-1].vector2.angle&&n.segments[n.segments.length-1].vector2.distance&&(x=Math.max(y.corners.width,y.corners.height),P=R.transform(S.point,n.segments[0].vector2.angle,x/2)),S.point=w?n.targetWrapper.bounds.center:qa(n,0,P,S.point,!0)}c=Tx(n,y,S)}else"Orthogonal"===n.type&&n.segments&&n.segments.length>0&&null!==n.segments[0].direction?c=function Ire(n,t,e,i,r,s,o){var a,h,c,d;Bv(n);for(var u=0;u0&&n.segments[u-1].direction===h.direction?u=u3(n,u,t):h.direction?t.point=o3(t,n.segments[parseInt(u.toString(),10)]):(f=n.segments[u-1])&&f.points&&f.points.length>0&&(t.point=f.points[f.points.length-1]),u===n.segments.length-1)if(f3(n,t),c3(a=void 0===r?Sre(n,t,e):l3(n,t,e),n),h.points=[],a.length>=2)for(c=0;c2&&n.segments.length>2){var p={x:a[parseInt(c.toString(),10)].x,y:t.point.y};h.points=[],h.points.push(p),h.points.push(a[parseInt(c.toString(),10)]);var f=n.segments[u-1];n.segments.length<4&&f.points.pop(),f.points=f.points.concat(h.points)}else h.points.push(a[parseInt(c.toString(),10)]);else h.points.push(a[parseInt(c.toString(),10)]);else d=u;if(void 0!==d&&!n.selectedSegmentIndex&&(d===n.segments.length-1&&(n.segments[d-1].direction=null,n.segments[d-1].length=null),n.segments.splice(d,1)),i&&0===u){var g=h3(n,i,s);g&&(t.point=g)}}return p3(n,[])}(n,y,S,l,h,o):(n.segments[0]||(C=new wi(n,"segments",{type:"Orthogonal"},!0),n.segments.push(C)),n.segments[0].points=c=g3(n,y,S,void 0,s));return c}(n,y.direction,S.direction,y.point,S.point,r);if(Bv(n),(n.sourceWrapper||n.targetWrapper)&&function gre(n,t,e){var i=n.sourcePortWrapper,r=n.targetPortWrapper,s=n.sourceWrapper,o=t.point,a={left:0,right:0,top:0,bottom:0},l={x:0,y:0},c="Top";if(s?(o=e.point,a=t.margin):(s=n.targetWrapper,a=e.margin),"Orthogonal"===n.type)if(n.segments&&n.segments.length>0&&n.sourceWrapper&&n.segments[0].direction)t.direction=n.segments[0].direction,l=qa(n,0,l=Nl(s.corners,t.direction),Nl(s.corners,_n(t.direction)),!1);else{var u={corners:null,direction:null,point:null,margin:null};Fv(s,{corners:null,direction:null,point:o,margin:a},u,n),l=u.point,c=u.direction}else{var f=void 0;n.segments&&n.segments.length>1&&(f=s===n.sourceWrapper?n.segments[0].point:n.segments[n.segments.length-2].point),l=qa(n,0,s.bounds.center,n.segments&&n.segments.length>1?f:o,s===n.targetWrapper)}s===n.sourceWrapper?(t.direction=t.direction||c,t.point=l,n.sourcePortWrapper&&(t.point={x:i.offsetX,y:i.offsetY},n.sourcePadding&&(t.point=wI(n,t,e,!1)))):(e.direction=e.direction||c,e.point=l,n.targetPortWrapper&&(e.point={x:r.offsetX,y:r.offsetY},n.targetPadding&&(e.point=wI(n,t,e,!0))))}(n,y,S),"Straight"===n.type||"Bezier"===n.type)d=Tx(n,y,S);else if("Orthogonal"===n.type&&n.segments&&n.segments.length>0&&null!==n.segments[0].length&&null!==n.segments[0].direction)d=function pre(n,t,e,i,r,s,o){var a,l,c,u,h=[];if(Bv(n),n.segments.length>0){for(var f=0;f0&&n.segments[f-1].direction===p.direction)f=u3(n,f,t);else{var g=n.segments[f-1];t.point=p.direction?o3(t,p):g.points[g.points.length-1]}if(f===n.segments.length-1&&(o||r?n.targetWrapper&&void 0===n.targetPortWrapper?(f3(n,t),l=ure(n,t,e)):l=l3(n,t,e):l=dre(n,t,e),l))if(c3(l,n),p.points=[],l.length>=2)for(a=0;at.corners.top&&e.point.ye.point.x?"Left":"Right"):e.point.x>t.corners.left&&e.point.xe.point.y?"Top":"Bottom")),n.sourcePortWrapper&&s===_n(r)?(("Left"===s||"Right"===s)&&t.point.y>=t.corners.top&&t.point.y<=t.corners.center.y&&e.point.y>=t.corners.top&&e.point.y<=t.corners.center.y?(t.direction="Top",a=t.point.y-t.corners.top+20):("Left"===s||"Right"===s)&&t.point.y>t.corners.center.y&&t.point.y<=t.corners.bottom&&e.point.y>t.corners.center.y&&e.point.y<=t.corners.bottom?(t.direction="Bottom",a=t.corners.bottom-t.point.y+20):("Top"===s||"Bottom"===s)&&t.point.x>=t.corners.left&&t.point.x<=t.corners.center.x&&e.point.x>=t.corners.left&&e.point.x<=t.corners.center.x?(t.direction="Left",a=t.point.x-t.corners.left+20):("Top"===s||"Bottom"===s)&&t.point.x<=t.corners.right&&t.point.x>t.corners.center.x&&e.point.x<=t.corners.right&&e.point.xt.point.y&&t.point.y>=e.corners.top?(i="Top",r=t.point.y-e.corners.top+20):e.corners.center.y===t.point.y&&"Top"===n.segments[n.segments.length-2].direction||e.corners.center.ye.point.y?t.point.y-t.corners.top+20:t.corners.bottom-t.point.y+20):(i="Top",r=e.corners.height/2+20):e.corners.center.x!==t.point.x||e.corners.topt.point.x&&t.point.x>=e.corners.left?(i="Left",r=t.point.x-e.corners.left+20):e.corners.center.x===t.point.x&&"Left"===n.segments[n.segments.length-2].direction||e.corners.center.x<=t.point.x&&t.point.x<=e.corners.right?(i="Right",r=e.corners.right-t.point.x+20):void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&t.corners.left<=t.point.x&&t.point.x<=t.corners.right&&(i=t.direction,r=t.point.x>e.point.x?t.point.x-t.corners.left+20:t.corners.right-t.point.x+20):(i="Left",r=e.corners.width/2+20);var a=t.point;t.point=Fn(t.point,"Left"===i||"Top"===i?-r:r,"Left"===i||"Right"===i?0:90),t.direction=R.direction(t.point,e.point),void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&(t.corners.center.x===e.corners.center.x||t.corners.center.y===e.corners.center.y)&&(t.direction=e.direction);var l=Ys(n,t,e);return l.splice(0,0,a),l}function l3(n,t,e){var i,r;e.corners=n.targetWrapper.corners,void 0!==n.sourcePortWrapper&&(r=zo({x:n.sourcePortWrapper.offsetX,y:n.sourcePortWrapper.offsetY},xn(n.sourceWrapper),n.sourceWrapper.bounds));var a=function fre(n,t,e,i){var r=!1;switch(e.direction){case"Left":void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&"Right"===i&&t.point.x>e.point.x&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom||("Bottom"===i&&t.point.y>e.point.y||"Top"===i&&t.point.y=t.corners.left&&t.point.x<=t.corners.right?(t.direction="Right"===i?t.point.y>e.point.y?"Top":"Bottom":t.point.xe.point.x&&(t.point.y>e.point.y||t.point.yt.point.y&&e.corners.bottome.point.y||t.point.x>e.point.x&&t.point.y<=e.point.y&&e.corners.top=t.point.y?t.direction="Top":t.point.xe.point.x&&t.point.y>e.point.y&&e.corners.bottomt.point.y?t.direction="Bottom":t.point.y===e.point.y&&t.point.xe.point.y||"Top"===i&&t.point.ye.point.x&&t.point.x>=t.corners.left&&t.point.x<=t.corners.right?(t.direction=t.point.x>e.point.x?"Left":"Right",r=!0):void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&"Left"===i&&t.point.x=t.corners.top&&t.point.y<=t.corners.bottom?(t.direction=t.point.y>e.point.y?"Top":"Bottom",r=!0):t.point.x=t.point.y&&t.point.y===e.point.y||t.point.y>e.point.y&&t.point.x>e.point.x?t.direction="Top":t.point.ye.point.x?t.direction="Bottom":t.point.xe.point.y||t.point.ye.point.x&&(t.direction="Left");break;case"Top":void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&"Bottom"===i&&t.point.y>e.point.y&&t.point.x>=t.corners.left&&t.point.x<=t.corners.right||("Right"===i&&t.point.x>e.point.x||"Left"===i&&e.point.y>t.point.y&&e.point.x>t.point.x)&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom?(t.direction="Bottom"===i?t.point.x>e.point.x?"Left":"Right":t.point.ye.point.y&&t.point.x>e.corners.left&&t.point.x=e.point.y?t.direction="Top":t.point.ye.point.x?t.direction="Left":t.point.yt.point.x)&&t.point.y>e.point.y&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom||"Top"===i&&t.point.y=t.corners.left&&t.point.x<=t.corners.right)?(t.direction="Right"===i||"Left"===i?t.point.y>e.point.y?"Top":"Bottom":t.point.x>e.point.x?"Left":"Right",r=!0):t.point.ye.corners.left&&e.corners.right>t.point.x?t.point.ye.corners.left&&e.corners.center.x>=t.point.x?t.direction="Left":t.point.ye.point.y&&t.point.x>e.point.x?t.direction="Left":t.point.y>e.point.y&&t.point.xe.point.x||e.point.x>t.point.x)&&(t.direction="Bottom")}return r}(n,t,e,r);return!n.selectedSegmentIndex&&void 0!==n.sourcePortWrapper&&void 0!==n.targetPortWrapper&&e.direction===_n(r)&&(("Left"===e.direction&&t.point.x>e.point.x||"Right"===e.direction&&t.point.x=t.corners.top&&t.point.y<=t.corners.bottom||"Bottom"===e.direction&&t.point.y=t.corners.left&&t.point.x<=t.corners.right)?i=a3(n,t,e):n.selectedSegmentIndex||t.direction!==e.direction?!n.selectedSegmentIndex&&("Left"===e.direction&&t.point.x>e.point.x||"Right"===e.direction&&t.point.x=t.point.y||"Top"===e.direction&&t.point.y>e.point.y||"Bottom"===e.direction&&t.point.y=t.point.x?i=n.selectedSegmentIndex?Ol(t,e):a3(n,t,e):!n.selectedSegmentIndex&&void 0!==n.sourceWrapper&&void 0!==n.targetWrapper&&void 0!==n.targetPortWrapper&&("Left"===t.direction||"Right"===t.direction)&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom&&("Top"===e.direction||"Bottom"===e.direction)&&e.corners.center.x===t.corners.center.x?(t.direction="Top"===e.direction?"Bottom":"Top",i=Ys(n,t,e,"Top"===e.direction?t.corners.bottom-t.point.y+20:t.point.y-t.corners.top+20)):!n.selectedSegmentIndex&&void 0!==n.sourceWrapper&&void 0!==n.targetWrapper&&void 0!==n.targetPortWrapper&&("Top"===t.direction||"Bottom"===t.direction)&&t.point.x>=t.corners.left&&t.point.x<=t.corners.right&&("Left"===e.direction||"Right"===e.direction)&&e.corners.center.y===t.corners.center.y?(t.direction="Left"===e.direction?"Right":"Left",i=Ys(n,t,e,"Left"===e.direction?t.corners.right-t.point.x+20:t.point.x-t.corners.left+20)):i=a?Ys(n,t,e,"Left"===t.direction||"Right"===t.direction?"Left"===t.direction?t.point.x-t.corners.left+20:t.corners.right-t.point.x+20:"Top"===t.direction?t.point.y-t.corners.top+20:t.corners.bottom-t.point.y+20):Ol(t,e):i=Ys(n,t,e),i}function h3(n,t,e){var r,i={x:t.offsetX,y:t.offsetY},s=xn(e),o=zo(i,s,e.bounds),a=n.segments[0];return a.direction!==o&&(function bre(n,t,e,i,r,s){var a,h,o=13,l=[];l.push(i),i.y===r.y&&("Left"===t&&r.xi.x)||i.x===r.x&&("Top"===t&&r.yi.y)||("Top"===t||"Bottom"===t?"Top"===t&&r.yi.y-o||"Bottom"===t&&r.y>i.y&&r.yo&&("Top"===t&&r.yi.y)?l.push({x:i.x,y:r.y}):(a=r.xi.x-o||"right"===t&&r.x>i.x&&r.xo&&("Left"===t&&r.xi.x)?l.push({x:r.x,y:i.y}):(l.push({x:a="Left"===t?e.left-o:e.right+o,y:i.y}),l.push({x:a,y:r.y})),s&&(l.push(n.points[0]),l.reverse()),n.points=l)}(a,o,s,a.points[0],a.points[a.points.length-1],!1),r=a.points[a.points.length-1],a.direction=R.direction(a.points[a.points.length-2],a.points[a.points.length-1])),r}function c3(n,t,e){var s,i=t.segments[t.segments.length-2],r=i.points[i.points.length-1];(("Top"===i.direction||"Bottom"===i.direction)&&r.x===n[1].x||("Left"===i.direction||"Right"===i.direction)&&r.y===n[1].y)&&(i.points[i.points.length-1]=n[1],s=R.direction(i.points[0],i.points[i.points.length-1]),void 0!==t.sourceWrapper&&void 0===t.sourcePortWrapper&&s===_n(i.direction)&&("Left"===i.direction||"Right"===i.direction?i.points[0].x="Right"===i.direction?i.points[0].x-t.sourceWrapper.corners.width:i.points[0].x+t.sourceWrapper.corners.width:i.points[0].y="Bottom"===i.direction?i.points[0].y-t.sourceWrapper.corners.height:i.points[0].y+t.sourceWrapper.corners.height),i.direction=s,i.length=R.distancePoints(i.points[0],i.points[i.points.length-1]),n.splice(0,1))}function wI(n,t,e,i){var o=i?n.targetPadding:n.sourcePadding,a=i?n.targetPortWrapper:n.sourcePortWrapper,l=new Ne(a.bounds.x-o,a.bounds.y-o,a.actualSize.width+2*o,a.actualSize.height+2*o),h=[l.topLeft,l.topRight,l.bottomRight,l.bottomLeft];h[h.length]=h[0];var d=i?e.point:t.point;return Lx({x1:t.point.x,y1:t.point.y,x2:e.point.x,y2:e.point.y},h,0,d)||d}function d3(n,t){var e=[],i=dF(0,n.corners,t);i.push(i[0]);for(var r=0;r0){var r=void 0,s=[],o=t.point;for(r=0;r1&&R.equals(a.points[0],a.points[1])&&n.segments.splice(r,1),a)for(var l=0;l0||0===r)&&i.push(a.points[parseInt(l.toString(),10)])}}return i}function Ax(n,t,e){return"Top"===n||"Bottom"===n?e.x>t.x?"Right":"Left":e.y>t.y?"Bottom":"Top"}function Bv(n){if("Straight"===n.type||"Bezier"===n.type){if(0===n.segments.length||n.segments.length>0&&!R.isEmptyPoint(n.segments[n.segments.length-1].point))if("Bezier"===n.type){var t=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0},!0);n.segments.push(t)}else t=new Hl(n,"segments",{type:"Straight"},!0),n.segments.push(t)}else{if(n.segments.length>0)for(var e=!1,i=0;i=t.corners.left&&e.point.x<=t.corners.right&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom)t.direction=e.point.y>t.point.y?"Bottom":"Top",i=Ys(n,t,e,"Top"===t.direction?t.point.y-t.corners.top+20:t.corners.bottom-t.point.y+20);else if(n.sourcePortWrapper&&r===_n(o)){var h;("Left"===r||"Right"===r)&&t.point.y>=t.corners.top&&t.point.y<=t.corners.bottom?(t.direction=e.point.y>t.point.y?"Bottom":"Top",h=t.corners.height/2+20):("Top"===r||"Bottom"===r)&&t.point.x>=t.corners.left&&t.point.x<=t.corners.right&&(t.direction=e.point.x>t.point.x?"Right":"Left",h=t.corners.width/2+20),t.direction&&h?i=Ys(n,t,e,h,!0):(t.direction=o,i=Ol(t,e))}else if(!n.sourcePortWrapper||r!==e.direction||"Top"!==r&&"Bottom"!==r||t.corners.center.x!==e.corners.center.x)if(t.direction===e.direction)if(("Left"===t.direction||"Right"===t.direction)&&e.point.y>t.corners.top-20&&e.point.yt.corners.left-20&&e.point.xt.point.y?"Bottom":"Top",i=Ys(n,t,e,"Bottom"===t.direction?t.corners.bottom-t.point.y+20:t.point.y-t.corners.top+20);else t.direction=o,i=Ys(n,t,e,"Top"===o||"Bottom"===o?n.sourceWrapper.height/2+20:n.sourceWrapper.width/2+20),t.point=i[1],"Left"===o||"Right"===o?(e.direction=o,e.point="Left"===o?e.corners.middleLeft:e.corners.middleRight):Fv(n.targetWrapper,t,e,n),i=Ys(n,t,e);return i}function f3(n,t){if(void 0!==n.targetWrapper&&void 0===n.targetPortWrapper&&xn(n.targetWrapper).containsPoint(t.point,1)){var i=n.targetWrapper,r=n.segments[n.segments.length-2],s=r.points[r.points.length-1],o=_n(r.direction);"Bottom"===o?s.yi.corners.top-1&&(r.points[r.points.length-1].y=i.corners.top-20,r.length=R.distancePoints(r.points[0],r.points[r.points.length-1])):"Left"===o?s.x>i.corners.left-1&&(r.points[r.points.length-1].x=i.corners.left-20,r.length=R.distancePoints(r.points[0],r.points[r.points.length-1])):"Right"===o&&s.x0||0===e)&&t.push(i.points[parseInt(r.toString(),10)]);return t}function Fv(n,t,e,i){var r,s={x:0,y:0},o=CI(n,n.corners,n.bounds),a=t.margin,l=t.point;if(o.bottomCenter.y+a.bottoml.y)r="Top",s=o.topCenter;else if(o.middleLeft.x-a.left>l.x)r="Left",s=o.middleLeft;else if(o.middleRight.x+a.rightc&&(f=c,r="Right",s=o.middleRight),f>d&&(f=d,r="Bottom",s=o.bottomCenter),f>u&&(r="Left",s=o.middleLeft)}e.point=s,e.direction=r;var p=Nl(o,_n(e.direction));e.point=qa(i,0,e.point,p,n===i.targetWrapper)}function g3(n,t,e,i,r){var s,o,a;if(s=function zre(n,t){var e=!1;switch(n){case"Left":switch(t){case"Right":case"Bottom":e=!0}break;case"Top":switch(t){case"Left":case"Right":case"Bottom":e=!0}break;case"Bottom":"Right"===t&&(e=!0)}return e}(t.direction,e.direction),s&&b3(t,e),"Right"===t.direction&&"Left"===e.direction)a=function Mre(n,t,e,i){var o=Math.round(Math.abs(t.point.y-e.point.y)),a={x:Math.max(t.point.x,t.corners.right),y:t.point.y},l={x:Math.min(e.point.x,e.corners.left),y:e.point.y},h=Xa(n);if(i){var c=l;l=a,a=c}return t.corners.bottom+he.corners.bottom+h||("Bezier"!==n.type||e.corners.left-t.corners.right<=2*h&&e.corners.left-t.corners.right>=5)&&(h=0),t.margin={left:h,right:h,top:h,bottom:h},e.margin={left:h,right:h,top:h,bottom:h},0===o&&(t.corners.right=e.corners.right?void 0!==i&&(i.offsetYe.corners.bottom+e.margin.bottom)||void 0===i&&t.corners.middleRight.ye.corners.bottom+e.margin.bottom&&t.corners.top>e.corners.bottom||void 0===i&&t.corners.middleRight.y>e.corners.bottom||void 0!==i&&i.offsetYe.corners.top||void 0===i&&t.corners.middleRight.y>e.corners.bottom?Ae.Three:t.corners.rightr.offsetY+e.margin.right||void 0===r&&t.corners.top>e.corners.middleRight.y||void 0!==r&&(void 0!==i&&i.offsetXr.offsetX||void 0===r&&t.corners.left>e.corners.topCenter.x?Ae.Four:Ae.Two:void 0!==s&&Math.abs(t.corners.right-e.corners.left)<=5&&Math.abs(s.offsetY-e.corners.top)<=5||void 0!==r&&t.corners.right=25&&t.corners.middleRight.y+t.margin.righte.corners.bottom+e.margin.bottom||void 0===o&&t.corners.middleRight.y>e.corners.bottom+e.margin.bottom?t.corners.top>e.corners.bottom?void 0!==a&&t.corners.right+t.margin.righta.offsetX||void 0===a&&t.corners.left>e.corners.bottomCenter.x?Ae.Four:Ae.Two:void 0!==o&&Math.abs(t.corners.right-e.corners.left)<=25&&Math.abs(o.offsetY-e.corners.bottom)<=25?Ae.Two:Ae.Four}(n,t,e,s);else if("Bottom"===t.direction&&"Top"===e.direction)a=function Dre(n,t,e){var r=t.point.x-e.point.x,s=Xa(n);return t.corners.right+se.corners.right+s||("Bezier"!==n.type||e.corners.top-t.corners.bottom<=2*s&&e.corners.top-t.corners.bottom>=5)&&(s=0),t.margin={left:s,right:s,top:s,bottom:s},e.margin={left:s,right:s,top:s,bottom:s},0===r&&t.corners.bottome.corners.right+e.margin.right||void 0===i&&t.corners.bottomCenter.x>e.corners.right+e.margin.right?Ae.Three:t.corners.bottomr.offsetX||void 0===r&&t.corners.left>e.corners.left||void 0!==r&&t.corners.right+t.margin.righte.corners.bottom?Ae.Five:0===s||0===o?Ae.One:Ae.Three}(n,t,e)}else"Bottom"===t.direction&&"Left"===e.direction?a=function xre(n,t,e,i){var r=n.sourcePortWrapper,s=n.targetPortWrapper,o=Xa(n);if(e.margin={left:o,right:o,top:o,bottom:o},t.margin={top:o,bottom:o,left:o,right:o},i){var l=r;r=s,s=l}return void 0!==r&&r.offsetXs.offsetY||void 0===s&&t.corners.top>e.corners.middleLeft.y?Ae.Four:Ae.Two:void 0!==s&&Math.abs(t.corners.right-e.corners.left)<=25&&Math.abs(s.offsetY-t.corners.bottom)<=25?Ae.Two:Ae.Four}(n,t,e,s):"Left"===t.direction&&"Left"===e.direction?a=function Lre(n,t,e){var i=n.sourcePortWrapper,r=n.targetPortWrapper,s=Xa(n);t.margin={left:s,right:s,top:s,bottom:s},e.margin={left:s,right:s,top:s,bottom:s};var o=Math.round(Math.abs(t.point.x-e.point.x)),a=Math.round(Math.abs(t.point.y-e.point.y));return t.corners.leftr.offsetY||void 0===r&&t.corners.top-t.margin.top>e.corners.middleLeft.y?Ae.Three:t.corners.righte.corners.bottom+e.margin.bottom||void 0===i&&t.corners.middleLeft.y>e.corners.bottom+e.margin.bottom?Ae.Three:t.corners.left>e.corners.right?Ae.Five:0===o||0===a?Ae.One:Ae.Three}(n,t,e):"Left"===t.direction&&"Top"===e.direction?a=function Are(n,t,e,i){var s=n.sourcePortWrapper,o=Xa(n);e.margin={left:o,right:o,top:o,bottom:o},t.margin={top:o,bottom:o,left:o,right:o};var a=n.targetPortWrapper,l={x:Math.min(t.point.x,t.corners.left),y:t.point.y},h={x:e.point.x,y:Math.min(e.point.y,e.corners.top)};if(i){var c=s;s=a,a=c;var d=l;l=h,h=d}return void 0!==s&&s.offsetYa.offsetX||void 0===a&&t.corners.left-t.margin.left>e.corners.topCenter.x?Ae.Two:Ae.Four:void 0!==a&&t.corners.rightr.offsetX||void 0===r&&t.corners.left>e.corners.left||void 0!==r&&t.corners.right+t.margin.righte.corners.right+e.margin.right||void 0===i&&t.corners.left>e.corners.right||void 0!==i&&i.offsetXe.corners.bottom?Ae.Five:0===s||0===o?Ae.One:Ae.Three}(n,t,e));return s&&b3(t,e),o=function Ore(n,t,e,i,r,s){var l,d,h=n.sourceWrapper.corners,c=n.targetWrapper.corners,u=20,f={corners:e.corners,point:e.point,direction:e.direction,margin:e.margin},p={corners:i.corners,point:i.point,direction:i.direction,margin:i.margin};if(!(f.direction===p.direction&&t!==Ae.Five||f.direction!==_n(p.direction)&&t!==Ae.Three))switch(f.direction){case"Left":h.middleLeft.x>c.middleRight.x&&(d=(h.middleLeft.x-c.middleRight.x)/2,u=s?d:Math.min(u,d));break;case"Right":h.middleRight.xc.bottomCenter.y&&(d=(h.topCenter.y-c.bottomCenter.y)/2,u=s?d:Math.min(u,d));break;case"Bottom":h.bottomCenter.yf&&hf)&&o>c&&o<=d&&e>=20&&(s=n.point.x-t.corners.left+s),i&&n.direction===t.direction&&n.corners.left>t.corners.left&&n.corners.left-t.corners.right>=20&&(s=(n.corners.left-t.corners.right)/2),p=Fn(n.point,s,180);break;case"Top":(o>c&&oc)&&h>f&&h<=u&&e>=20&&(s=n.point.y-t.corners.top+s),i&&n.direction===t.direction&&n.corners.top>t.corners.top&&n.corners.top-t.corners.bottom>=20&&(s=(n.corners.top-t.corners.bottom)/2),p=Fn(n.point,s,270);break;case"Right":(h>f&&hf)&&a=c&&e>=20&&(s=t.corners.right-n.point.x+s),i&&n.direction===t.direction&&n.corners.right=20&&(s=(t.corners.left-n.corners.right)/2),p=Fn(n.point,s,0);break;case"Bottom":(o>c&&oc)&&l=f&&e>=20&&(s=t.corners.bottom-n.point.y+s),i&&n.direction===t.direction&&n.corners.bottom=20&&(s=(t.corners.top-n.corners.bottom)/2),p=Fn(n.point,s,90)}r=[n.point,p];var g=void 0;if("Top"===n.direction||"Bottom"===n.direction){var v=n.direction;n.direction=p.x>t.point.x?"Left":"Right",n.point=p,r=EI(n,t,v,r,g=i?.5*Math.abs(p.x-t.point.x):g,i)}else v=n.direction,n.direction=p.y>t.point.y?"Top":"Bottom",n.point=p,r=EI(n,t,v,r,g=i?.5*Math.abs(p.y-t.point.y):g,i);return r}(f,p,u,g)),l}(n,a,t,e,i,r),"Bezier"===n.type&&function Pre(n,t,e){if("Bezier"===n.type)if(0===n.segments.length){var i=e[0],r=e[e.length-1];if(t===Ae.One){var s=Math.min(20,.5*R.findLength(i,r)),o={angle:Xt(i,r),distance:s},a={angle:Xt(r,i),distance:s},l=R.direction(i,r),c=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,orientation:"Left"===l||"Right"===l?"Horizontal":"Vertical"},!0);n.segments.push(c)}else if(t===Ae.Two)o={angle:Xt(i,d=e[1]),distance:.5*R.findLength(i,d)},a={angle:Xt(r,d),distance:.5*R.findLength(r,d)},l=R.direction(i,d),c=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,orientation:"Left"===l||"Right"===l?"Horizontal":"Vertical"},!0),n.segments.push(c);else if(t===Ae.Three){var d={x:.5*((u=e[1]).x+(f=e[e.length-2]).x),y:.5*(u.y+f.y)},p=(o={angle:Xt(i,u),distance:.5*R.findLength(i,u)},a={angle:Xt(d,u),distance:.5*R.findLength(d,u)},R.direction(i,u)),v=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,point:d,orientation:"Left"===p||"Right"===p?"Horizontal":"Vertical"},!0);n.segments.push(v);var y={angle:Xt(d,f),distance:.5*R.findLength(d,f)},S={angle:Xt(r,f),distance:.5*R.findLength(r,f)},b=R.direction(d,f),w=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:y,vector2:S,orientation:"Left"===b||"Right"===b?"Horizontal":"Vertical"},!0);n.segments.push(w)}else if(t===Ae.Four){var D={x:.5*((u=e[1]).x+(f=e[2]).x),y:.5*(u.y+f.y)},A={x:.5*(f.x+(C=e[3]).x),y:.5*(f.y+C.y)};o={angle:Xt(i,u),distance:.5*R.findLength(i,u)},a={angle:Xt(D,u),distance:.5*R.findLength(D,u)},p=R.direction(i,u),v=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,point:D,orientation:"Left"===p||"Right"===p?"Horizontal":"Vertical"},!0),n.segments.push(v),y={angle:Xt(D,f),distance:.5*R.findLength(D,f)},S={angle:Xt(A,f),distance:.5*R.findLength(A,f)},b=R.direction(D,f),w=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:y,vector2:S,point:A,orientation:"Left"===b||"Right"===b?"Horizontal":"Vertical"},!0),n.segments.push(w);var x={angle:Xt(A,C),distance:.5*R.findLength(A,C)},P={angle:Xt(r,C),distance:.5*R.findLength(r,C)},L=R.direction(A,C),N=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:x,vector2:P,orientation:"Left"===L||"Right"===L?"Horizontal":"Vertical"},!0);n.segments.push(N)}else if(t===Ae.Five){var u,f,C,T=e[4],z=(D={x:.5*((u=e[1]).x+(f=e[2]).x),y:.5*(u.y+f.y)},A={x:.5*(f.x+(C=e[3]).x),y:.5*(f.y+C.y)},{x:.5*(C.x+T.x),y:.5*(C.y+T.y)});o={angle:Xt(i,u),distance:.5*R.findLength(i,u)},a={angle:Xt(D,u),distance:.5*R.findLength(D,u)},p=R.direction(i,u),v=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:o,vector2:a,point:D,orientation:"Left"===p||"Right"===p?"Horizontal":"Vertical"},!0),n.segments.push(v),y={angle:Xt(D,f),distance:.5*R.findLength(D,f)},S={angle:Xt(A,f),distance:.5*R.findLength(A,f)},b=R.direction(D,f),w=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:y,vector2:S,point:A,orientation:"Left"===b||"Right"===b?"Horizontal":"Vertical"},!0),n.segments.push(w),x={angle:Xt(A,C),distance:.5*R.findLength(A,C)},P={angle:Xt(z,C),distance:.5*R.findLength(z,C)},L=R.direction(A,C),N=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:x,vector2:P,point:z,orientation:"Left"===L||"Right"===L?"Horizontal":"Vertical"},!0),n.segments.push(N);var U={angle:Xt(z,T),distance:.5*R.findLength(z,T)},B={angle:Xt(r,T),distance:.5*R.findLength(r,T)},j=R.direction(z,T),oe=new fs(n,"segments",{type:"Bezier",isInternalSegment:!0,vector1:U,vector2:B,orientation:"Left"===j||"Right"===j?"Horizontal":"Vertical"},!0);n.segments.push(oe)}else c=new fs(n,"segments",{type:"Bezier"},!0),n.segments.push(c)}else for(var ue=0;ue=13?13:n.connectorSpacing<=1?1:n.connectorSpacing}function Xt(n,t){var i=R.findLength({x:t.x,y:n.y},t),r=R.findLength(t,n),s=Math.asin(i/r);return s=180*s/Math.PI,n.xt.y&&(s=360-s):s=n.y0)for(var l=1;lc)&&(s=c,a=h),s>=0&&s<=1)break}}return a}function m3(n,t){var c,d,u,f,p,g,S,b,M,w,D,e=n.x1,i=n.y1,r=n.x2,s=n.y2,o=t.x1,a=t.y1,l=t.x2,h=t.y2;if(w=(c=s-i)*l+(u=e-r)*h+(p=r*i-e*s),0!==(M=c*o+u*a+p)&&0!==w&&y3(M,w)||(b=(d=h-a)*r+(f=o-l)*s+(g=l*a-o*h),0!==(S=d*e+f*i+g)&&0!==b&&y3(S,b)))return null;var A=c*f-d*u;return 0===A?null:(A<0?-A/2:A/2,0,{x:(D=u*g-f*p)<0?(D-0)/A:(D+0)/A,y:(D=d*p-c*g)<0?(D-0)/A:(D+0)/A})}function y3(n,t){return n*t>=0}function S3(n,t,e){switch(t.direction){case"Left":t.point.x>n.left&&(e=t.point.x-n.left>e?t.point.x-n.left+e:e);break;case"Right":t.point.xe?n.right-t.point.x+e:e);break;case"Top":t.point.y>n.top&&(e=t.point.y-n.top>e?t.point.y-n.top+e:e);break;case"Bottom":t.point.ye?n.bottom-t.point.y+e:e)}return e}function Ol(n,t){var e;switch(n.direction){case"Left":case"Right":var i={x:t.point.x,y:n.point.y};e=R.equals(n.point,i)||R.equals(t.point,i)?[n.point,t.point]:[n.point,i,t.point];break;case"Top":case"Bottom":var r={x:n.point.x,y:t.point.y};e=R.equals(n.point,r)||R.equals(t.point,r)?[n.point,t.point]:[n.point,r,t.point]}return e}function Ys(n,t,e,i,r,s){void 0===s&&(s=!1),i||(i=20),s&&t.direction!==e.direction&&(i="Left"===t.direction||"Right"===t.direction?Math.floor(.5*Math.abs(t.point.x-e.point.x)):Math.floor(.5*Math.abs(t.point.y-e.point.y)));var l,h,u,o=n.sourcePortWrapper,c=e.point.x-t.point.x,d=e.point.y-t.point.y;if(!r&&(Math.abs(c)<.001||Math.abs(d)<.001)&&void 0===e.direction)return[t.point,e.point];if(void 0===n.targetWrapper&&Math.abs(c)<=31&&Math.abs(d)<=31){if("Left"===t.direction||"Right"===t.direction?Math.abs(d)<12&&(t.direction=t.point.y>e.point.y?"Top":"Bottom"):Math.abs(c)<12&&(t.direction=t.point.x>e.point.x?"Left":"Right"),Math.abs(c)>12||Math.abs(d)>12)return Ol(t,e);i+=5}return"Left"===t.direction||"Right"===t.direction?("Right"===t.direction?(void 0!==e.direction&&"Right"===e.direction&&(i=Math.max(t.point.x,e.point.x)-t.point.x+i),t.point.x>e.point.x&&void 0===o&&(i=-i)):(void 0!==e.direction&&"Left"===e.direction&&(i=t.point.x-Math.min(t.point.x,e.point.x)+i),(t.point.x>e.point.x||void 0!==o||"Left"===t.direction)&&(i=-i)),u=e.point.y-t.point.y,l=Fn(t.point,i,0),0!=(u=e.point.y-l.y)&&(h=Fn(l,e.point.y-l.y,90))):("Top"===t.direction||"Bottom"===t.direction)&&("Bottom"===t.direction?void 0!==e.direction&&"Bottom"===e.direction&&(i=Math.max(t.point.y,e.point.y)-t.point.y+i):(void 0!==e.direction&&"Top"===e.direction&&(i=t.point.y-Math.min(t.point.y,e.point.y)+i),(t.point.y>e.point.y||void 0!==o||"Top"===t.direction)&&(i=-i)),u=e.point.x-t.point.x,l=Fn(t.point,i,90),0!=(u=e.point.x-l.x)&&(h=Fn(l,e.point.x-l.x,0))),0===u?[t.point,e.point]:[t.point,l,h,e.point]}function EI(n,t,e,i,r,s){var o;switch(void 0===r&&(r=20),void 0===s&&(s=!1),void 0===e?(n.margin={left:2,right:2,top:2,bottom:2},t.margin={left:0,right:5,top:0,bottom:5},s&&(n.margin={left:10,right:10,top:10,bottom:10},t.margin={left:10,right:10,top:10,bottom:10},"Left"===n.direction?(r=Ox(n,t,e,r),n.corners.left-t.corners.right>=5&&(r=Math.abs(n.point.x-n.corners.left)+.5*Math.floor(n.corners.left-t.corners.right))):"Right"===n.direction?(r=kx(n,t,r,e),t.corners.left-n.corners.right>=5&&(r=Math.abs(n.point.x-n.corners.right)+.5*Math.floor(t.corners.left-n.corners.right))):"Top"===n.direction?(r=Nx(n,t,e,r),n.corners.top-t.corners.bottom>=5&&(r=Math.abs(n.point.y-n.corners.top)+.5*Math.floor(n.corners.top-t.corners.bottom))):"Bottom"===n.direction&&(r=Px(n,t,r,e),t.corners.top-n.corners.bottom>=5&&(r=Math.abs(n.point.y-n.corners.bottom)+.5*Math.floor(t.corners.top-n.corners.bottom))))):("Bottom"===n.direction?s?t.corners.top-n.corners.bottom<20&&(r=t.corners.bottom-n.point.y+25):t.corners.top>n.corners.bottom&&t.corners.top-n.corners.bottom<20&&(r=(t.corners.top-n.corners.bottom)/2):"Top"===n.direction?s?n.corners.top-t.corners.bottom<20&&(r=n.point.y-t.corners.top+25):t.corners.bottomn.corners.right&&t.corners.left-n.corners.right<20&&(r=(t.corners.left-n.corners.right)/2):"Left"===n.direction&&(s?n.corners.left-t.corners.right<20&&(r=n.point.x-t.corners.left+25):t.corners.rightt.point.y||"Top"===t.direction&&n.point.yt.point.x||"Left"===t.direction&&n.point.xh||e.corners.top-e.margin.top<=i.point.y&&e.corners.bottom+e.margin.bottom>=i.point.y))if(!s||"Top"!==e.direction&&"Bottom"!==e.direction)c=Math.min(Math.abs(i.corners.left-e.corners.right)/2,20),h=e.corners.right-n.x+c;else{var c=Math.abs(i.corners.left-e.corners.right)/2;h=e.corners.right-n.x+c}else h="Top"===e.direction&&n.y>i.point.y||"Bottom"===e.direction&&n.y=e.corners.left-e.margin.left&&n.x<=e.corners.right+e.margin.right?Math.min(i.corners.left,e.corners.left)-n.x-20:i.corners.left-n.x-20;break;case"Right":if(e.corners.left-e.margin.left>i.corners.right+i.margin.right&&(e.corners.left-e.margin.right-i.corners.right>h||e.corners.top-e.margin.top<=i.point.y&&e.corners.bottom+e.margin.bottom>=i.point.y))if(!s||"Top"!==e.direction&&"Bottom"!==e.direction)c=Math.min(Math.abs(e.corners.left-i.corners.right)/2,20),h=e.corners.left-n.x-c;else{c=Math.abs(e.corners.left-i.corners.right)/2;h=e.corners.left-n.x-c}else h="Top"===e.direction&&n.y>i.point.y||"Bottom"===e.direction&&n.y=e.corners.left-e.margin.left&&n.x<=e.corners.right+e.margin.right?Math.max(i.corners.right,e.corners.right)-n.x+20:i.corners.right-n.x+20}o=Fn(n,h,0),a=Fn(o,i.point.y-n.y,90),l=i.point}else if("vertical"===t){switch(i.direction){case"Top":e.corners.bottom+e.margin.bottomh||e.corners.left-e.margin.left<=i.point.x&&e.corners.right+e.margin.right>=i.point.x)?!s||"Right"!==e.direction&&"Left"!==e.direction?(c=Math.min(Math.abs(i.corners.top-e.corners.bottom)/2,20),h=e.corners.bottom-n.y+c):(c=Math.abs(i.corners.top-e.corners.bottom)/2,h=e.corners.bottom-n.y+c):h="Left"===e.direction&&n.x>i.point.x||"Right"===e.direction&&n.x=e.corners.top-e.margin.top&&n.y<=e.corners.bottom+e.margin.bottom?Math.min(i.corners.top,e.corners.top)-n.y-20:i.corners.top-n.y-20;break;case"Bottom":e.corners.top-e.margin.top>i.corners.bottom+i.margin.bottom&&(e.corners.top-e.margin.top-i.corners.bottom>h||e.corners.left-e.margin.left<=i.point.x&&e.corners.right+e.margin.right>=i.point.x)?!s||"Right"!==e.direction&&"Left"!==e.direction?(c=Math.min(Math.abs(e.corners.top-i.corners.bottom)/2,20),h=e.corners.top-n.y-c):(c=Math.abs(e.corners.top-i.corners.bottom)/2,h=e.corners.top-n.y-c):h="Left"===e.direction&&n.x>i.point.x||"Right"===e.direction&&n.x=e.corners.top-e.margin.top&&n.y<=e.corners.bottom+e.margin.bottom?Math.max(i.corners.bottom,e.corners.bottom)-n.y+20:i.corners.bottom-n.y+20}o=Fn(n,h,90),a=Fn(o,i.point.x-n.x,0),l=i.point}r.push(o),r.push(a),r.push(l)}function Nx(n,t,e,i){return n.corners.top-n.margin.top>t.corners.top+t.margin.top&&n.corners.top-n.margin.top<=t.corners.bottom+t.margin.bottom?(("Right"===t.direction&&n.point.xt.point.x)&&(i+=n.corners.top-t.corners.top),i+=n.point.y-n.corners.top):i+=void 0!==e&&"Left"!==e&&"Right"===t.direction&&n.point.xt.corners.left-t.margin.left&&n.corners.left-n.margin.left<=t.corners.right+t.margin.right?(("Bottom"===t.direction&&n.point.yt.point.y)&&(i+=n.corners.left-t.corners.left),i+=n.point.x-n.corners.left):i+=void 0!==e&&"Top"!==e&&"Bottom"===t.direction&&n.point.y=t.corners.left-t.margin.left?(("Bottom"===t.direction&&n.point.yt.point.y)&&(e+=t.corners.right-n.corners.right),e+=n.corners.right-n.point.x):e+=void 0!==i&&"Top"!==i&&"Bottom"===t.direction&&n.point.y=t.corners.top-t.margin.top?(("Right"===t.direction&&n.point.xt.point.x)&&(e+=t.corners.bottom-n.corners.bottom),e+=n.corners.bottom-n.point.y):e+=void 0!==i&&"Left"!==i&&"Right"===t.direction&&n.point.xp&&d=u&&d=f&&d<=p?"Left":"Right"}function _n(n){switch(n){case"Top":return"Bottom";case"Bottom":return"Top";case"Left":return"Right";case"Right":return"Left"}return"auto"}var w3=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Ac=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},DI=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return w3(t,n),Ac([I()],t.prototype,"width",void 0),Ac([I()],t.prototype,"height",void 0),t}(Ee),Rre=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return w3(t,n),Ac([I()],t.prototype,"width",void 0),Ac([I()],t.prototype,"height",void 0),Ac([I()],t.prototype,"fit",void 0),Ac([I()],t.prototype,"description",void 0),Ac([I()],t.prototype,"template",void 0),Ac([I()],t.prototype,"tooltip",void 0),t}(Ee),Hre=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),kl=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},C3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Hre(t,n),kl([I("")],t.prototype,"id",void 0),kl([I(Number.MIN_VALUE)],t.prototype,"zIndex",void 0),kl([re({},Jn)],t.prototype,"margin",void 0),kl([I(!0)],t.prototype,"visible",void 0),kl([re({},Dd)],t.prototype,"tooltip",void 0),kl([I(!1)],t.prototype,"excludeFromLayout",void 0),kl([I()],t.prototype,"addInfo",void 0),kl([I("None")],t.prototype,"flip",void 0),kl([I("All")],t.prototype,"flipMode",void 0),kl([re({},Rre)],t.prototype,"symbolInfo",void 0),t}(Ee),Bre=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),es=function(n){function t(e,i,r,s){var o=n.call(this)||this;return o.data="",o.nodeId="",o.annotationId="",o.diagramId="",o.diagramId=i,o.nodeId=e,o.annotationId=r,o.templateFn=UF(s),o}return Bre(t,n),t.prototype.getNodeTemplate=function(){return this.templateFn},Object.defineProperty(t.prototype,"content",{get:function(){return this.data},set:function(e){this.data=e,this.canReset||(this.canReset=!0,this.isTemplate||(this.template=Hh(this,!0)),this.canReset=!1,this.isDirt=!0)},enumerable:!0,configurable:!0}),t}(hs),zx=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),cs=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},E3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return zx(t,n),cs([I("")],t.prototype,"id",void 0),cs([I("transparent")],t.prototype,"fill",void 0),cs([I("black")],t.prototype,"iconStrokeColor",void 0),cs([I(0)],t.prototype,"iconStrokeWidth",void 0),cs([I(!0)],t.prototype,"visibility",void 0),cs([I(10)],t.prototype,"width",void 0),cs([I(10)],t.prototype,"height",void 0),cs([I("transparent")],t.prototype,"handleStrokeColor",void 0),cs([I(1)],t.prototype,"handleStrokeWidth",void 0),cs([I("")],t.prototype,"pathData",void 0),cs([I(0)],t.prototype,"cornerRadius",void 0),cs([re({left:0,right:0,top:0,bottom:0},Jn)],t.prototype,"padding",void 0),cs([re({},Dd)],t.prototype,"tooltip",void 0),t}(Ee),D3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return zx(t,n),cs([re({x:0,y:0},R)],t.prototype,"offset",void 0),cs([re({},Jn)],t.prototype,"margin",void 0),t}(E3),xI=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return zx(t,n),cs([I(.5)],t.prototype,"offset",void 0),cs([I("Center")],t.prototype,"alignment",void 0),cs([re({x:0,y:0},R)],t.prototype,"displacement",void 0),t}(E3);function xd(n){return n?n instanceof Kn||n instanceof Or?n.constraints&Nr.Select:n instanceof de?n.constraints&qe.Select:n.constraints&ie.Select:1}function ro(n){return n?n instanceof Kn||n instanceof Or?n.constraints&Nr.Drag:n instanceof de?n.constraints&qe.Drag:n instanceof ti?1:n.constraints&ie.Drag:1}function Fre(n,t){return n instanceof de?n.constraints&qe.PointerEvents:n.constraints&ie.PointerEvents}function TI(n){return n instanceof de?n.constraints&qe.Delete:n.constraints&ie.Delete}function AI(n){return n.constraints&qe.DragSourceEnd}function LI(n){return n.constraints&qe.DragTargetEnd}function NI(n){return n.constraints&qe.DragSegmentThumb}function OI(n){return n instanceof Kn||n instanceof Or?n.constraints&Nr.Rotate:n.constraints&ie.Rotate}function kI(n){return n.constraints&ie.Shadow}function ua(n){return n instanceof te&&n.constraints&ie.InConnect?n.constraints&ie.InConnect:0}function kh(n){return n&&n.constraints&&!(n.constraints&ai.None)&&n.constraints&ai.InConnect?n.constraints&ai.InConnect:0}function Ph(n){return n instanceof te&&n.constraints&ie.OutConnect?n.constraints&ie.OutConnect:0}function Td(n){return n&&n.constraints&&!(n.constraints&ai.None)&&n.constraints&ai.OutConnect?n.constraints&ai.OutConnect:0}function Pl(n,t){var e=0;return n instanceof Kn||n instanceof Or?e=n.constraints&Nr.Resize:n&&("SouthEast"===t?e=n.constraints&ie.ResizeSouthEast:"East"===t?e=n.constraints&ie.ResizeEast:"NorthEast"===t?e=n.constraints&ie.ResizeNorthEast:"South"===t?e=n.constraints&ie.ResizeSouth:"North"===t?e=n.constraints&ie.ResizeNorth:"SouthWest"===t?e=n.constraints&ie.ResizeSouthWest:"West"===t?e=n.constraints&ie.ResizeWest:"NorthWest"===t&&(e=n.constraints&ie.ResizeNorthWest)),e}function PI(n){return n instanceof de?n.constraints&qe.AllowDrop:n.constraints&ie.AllowDrop}function Ds(n){return n.constraints&nt.Virtualization}function _v(n){return n.tool&ni.SingleSelect}function Uv(n){return n.tool&ni.MultipleSelect}function Lc(n){return n.tool&ni.ZoomPan}function zI(n){return n.tool&ni.ContinuousDraw}function x3(n){return n.tool&ni.DrawOnce}function RI(n){return n.tool&ni.SingleSelect||n.tool&ni.MultipleSelect}function jv(n){return n.constraints&nt.UserInteraction}function T3(n){return n.constraints&nt.ZoomTextEdit}function Vv(n){return function Yre(n){return n.constraints&nt.ApiUpdate}(n)||n.diagramActions&ee.ToolAction}function Rx(n,t){return n.constraints&ai.Draw}function Hx(n,t){return n.constraints&ai.Drag}function HI(n){return!(n&Ga.DrawSelectorBorder)}function A3(n){return!!(n&Ga.PreventRenderSelector)}var Bx=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Wv=function(n){function t(){var e=null!==n&&n.apply(this,arguments)||this;return e.childTable=[],e.cellStyle={},e.desiredRowHeight=[],e.desiredCellWidth=[],e}return Bx(t,n),t.prototype.rowDefinitions=function(){return this.rowDefns},t.prototype.columnDefinitions=function(){return this.colDefns},t.prototype.addObject=function(e,i,r,s,o){if(this.rows.length>=i){var a=this.rows[parseInt(i.toString(),10)];if(a.cells.length>r){o=o||1,s=s||1;var l=a.cells[parseInt(r.toString(),10)];l.columnSpan=Math.max(o,l.columnSpan),l.rowSpan=Math.max(s,l.rowSpan);var h=new $re;(h=e).rowId=i,h.columnId=r,h.columnSpan=o,this.childTable[h.id]=h,this.addObjectToCell(h,l)}}},t.prototype.addObjectToCell=function(e,i){i.children||(i.children=[]),e.style.strokeColor="black",e.style.strokeWidth=1,i.children.push(e)},t.prototype.updateProperties=function(e,i,r,s){this.offsetX=e,this.offsetY=i,this.width=r,this.height=s},t.prototype.setDefinitions=function(e,i){this.rowDefns=e,this.colDefns=i,this.children=[],this.rows=this.rows||[];for(var r=0;r0){for(var h=0;hi&&this.updateRowHeight(e,l,!1)}},t.prototype.setTextRefresh=function(e){if(e.children&&e.children.length)for(var i=e.children,r=0;ri&&this.updateColumnWidth(e,a,!1)}},t.prototype.calculateCellWidth=function(e){for(var i,r,s,o=0;os.bounds.width&&(0===s.children.length||void 0===s.children[0].maxWidth)?s.outerBounds.width:s.bounds.width,i=i?is.bounds.height?s.outerBounds.height:s.bounds.height,i=i?i0?e.children[0]:void 0;if(a&&1===e.columnSpan){o="Width"===i?a.bounds.right:a.bounds.bottom,s||(s="Width"===i?a.bounds.width:a.bounds.height);for(var l=0;lo){var d=c-o+("Width"===i?a.bounds.width:a.bounds.height);s&&(s=s0?this.rowDefns.splice(e,0,i):this.rowDefns.push(i);var s=new L3;s.cells=[],(new Ad).width=this.width,this.addCellInRow(this.colDefns,i,s),e>this.rows.length-1?this.rows.push(s):this.rows.splice(e,0,s),r&&(this.measure(new me(this.width,this.height)),this.arrange(this.desiredSize))},t.prototype.addColumn=function(e,i,r){var s,o,a,l,h=this.rows;this.colDefns.length>0?this.colDefns.splice(e,0,i):this.colDefns.push(i),void 0!==this.width&&(this.width+=i.width);for(var c=0;cs.cells.length-1?s.cells.push(l):s.cells.splice(e,0,l),this.children.push(l);r&&(this.measure(new me(this.width,this.height)),this.arrange(this.desiredSize))},t.prototype.removeRow=function(e){var i,r,o=this.rows[parseInt(e.toString(),10)];this.height-=this.rowDefns[parseInt(e.toString(),10)].height;for(var a=0;a0){var r=0,s=0;i=new me(0,0),this.calculateSize();for(var o=0,a=this.rows;o0){for(var o=this.offsetX-e.width*this.pivot.x,a=this.offsetY-e.height*this.pivot.y,l=o,h=0,c=this.rows;h1&&this.children.splice(this.children.indexOf(p)+1,p.columnSpan-1),p.rowSpan>1)for(y=s,S=0;y+p.rowSpan-10){for(var c=0;c0?1:0,v=0;v0||a.outEdges.length>0))for(f=a.inEdges.concat(a.outEdges),s=0;s0)for(o=0;o1)for(a=1;a0))if(h=n.wrapper.children[0],"Horizontal"===e.orientation)for(o=e.header&&e.hasHeader?h.rows[1]:h.rows[0],r=0;r0){var e=void 0;t.lineRoutingModule&&t.constraints&nt.LineRouting&&t.lineRoutingModule.renderVirtualRegion(t,!0);for(var i=0;i0?o+1:o)].height=t.wrapper.height;else if(t.isPhase)for(l[t.rowIndex-o].offset=t.wrapper.height,p=0;p0?1:0)].width=t.wrapper.width}function FI(n,t){var i=n.shape,r=i.header&&i.hasHeader?1:0;return"Horizontal"===i.orientation?t.rowIndex-(r+=i.phases.length>0?1:0):t.columnIndex-(i.phaseSize&&i.phases.length>0?1:0)}function _I(n){var t=0,e=n.shape;return"Horizontal"===e.orientation&&(t=e.header&&e.hasHeader?1:0),e.phases.length>0&&e.phaseSize&&(t+=1),t}function UI(n,t,e,i){var r=n.shape;if(r.phases.length>0){var s=t.nameTable[r.phases[parseInt(i.toString(),10)].header.id];s&&s.maxWidth0?u+1:u);var w=Nc(n,o),C=void 0!==i?i:l.lanes.length;if(u+=C,r={element:M,cause:n.diagramActions,diagramAction:n.getDiagramAction(n.diagramActions),state:"Changing",type:"Addition",cancel:!1,laneIndex:C},n.triggerEvent(Ce.collectionChange,r),!r.cancel){if(c){var D=new Yv;D.height=e.height,o.addRow(u,D,!1),s.height=void 0!==s.height?s.height+e.height:s.height,s.wrapper.height=o.height=s.height}else{var A=new Ad;A.width=e.width,o.addColumn(C+1,A,!1),s.width&&(s.width+=e.width,s.wrapper.width=o.width=s.width),n.diagramActions&ee.UndoRedo||(o.rows[0].cells[0].columnSpan+=1)}n.diagramActions&ee.UndoRedo||(M.id=""===M.id?Qe():M.id),void 0!==i?l.lanes.splice(i,0,M):l.lanes.push(M),r={element:M,cause:n.diagramActions,diagramAction:n.getDiagramAction(n.diagramActions),state:"Changed",type:"Addition",cancel:!1,laneIndex:C},n.triggerEvent(Ce.collectionChange,r),O3(o,n,s,u,C,c),h="Horizontal"===l.orientation?n.nameTable[o.rows[parseInt(u.toString(),10)].cells[0].children[0].id]:l.header&&l.hasHeader?n.nameTable[o.rows[1].cells[parseInt(u.toString(),10)].children[0].id]:n.nameTable[o.rows[0].cells[parseInt(u.toString(),10)].children[0].id],n.diagramActions&ee.UndoRedo||(d={type:"LaneCollectionChanged",changeType:"Insert",undoObject:$(M),redoObject:$(h),category:"Internal"},n.addHistoryEntry(d)),Xf(n,s,"Horizontal"===l.orientation?u:l.header&&l.hasHeader?1:0),Gf(s),Oc(n,s);var P=!1;if((f=e.children)&&f.length>0)for(p=0;p0){var o=t.children[0],a=n.nameTable[o.id];(function sne(n,t,e){return n.left-(e.left||0)<=t.x&&n.right+(e.right||0)>=t.x&&n.top-(e.top||0)<=t.y&&n.bottom+(e.bottom||0)>=t.y})(o.bounds,e,r)&&(n.addChild(a,i),s=!0)}return s}function one(n,t,e){if("SwimLane"===t.shape.type){var i=void 0,r=void 0,s=void 0,a=void 0,l=void 0,h=void 0,c=t.wrapper.bounds.x,d=t.wrapper.bounds.y,u=t.shape,f=u.padding,p=u.phases,g=void 0,v=t.wrapper.children[0],y="Horizontal"===u.orientation;if(i=u.header&&u.hasHeader?0:-1,u.phases.length>0&&(i+=1),e.offset>(y?u.lanes[0].header.width:u.lanes[0].header.height)){for(h=0;he.offset){if(g=h>0?e.offset-(h>0?p[h-1]:s).offset:e.offset,y){var b=v.columnDefinitions()[parseInt(h.toString(),10)];b.width-=g,(a=n.nameTable[u.phases[parseInt(h.toString(),10)].header.id]).maxWidth=a.wrapper.maxWidth=b.width,v.updateColumnWidth(h,b.width,!1);var M=new Ad;M.width=g,l=h,v.addColumn(h,M,!1);break}var w=v.rowDefinitions()[h+i];w.height-=g,a=n.nameTable[u.phases[parseInt(h.toString(),10)].header.id],v.updateRowHeight(h+i,w.height,!1);var C=new Yv;C.height=g,l=h,v.addRow(h+i,C,!1);break}if(n.diagramActions&ee.UndoRedo&&void 0===l&&(D=n.historyManager.currentEntry.next).isLastPhase&&function ane(n,t,e,i,r,s){var a=t.shape.phases[n-2],l=e.previousPhase.offset;if(r){var h=i.columnDefinitions()[n-1],c=new Ad;n>1?(c.width=h.width-(l-a.offset),h.width=l-a.offset):(c.width=h.width-l,h.width=l),i.updateColumnWidth(n-1,h.width,!1),i.addColumn(n,c,!1)}else{h=i.rowDefinitions()[parseInt(n.toString(),10)];var d=new Yv;n>1?(d.height=e.undoObject.offset-l,h.height=l-a.offset):(d.height=h.height-l,h.height=l),i.updateRowHeight(n,h.height,!1),i.addRow(1+n,d,!1)}}(l=p.length,t,D,v,y),l>=0){var A=new lb(t.shape,"phases",e,!0);if(n.diagramActions&ee.UndoRedo||(A.id+=Qe()),u.phases.splice(l,0,A),Fx(v,n,t,i,y,l),y){if(r=n.nameTable[v.rows[parseInt(i.toString(),10)].cells[parseInt(l.toString(),10)].children[0].id],0===l&&u.header&&u.hasHeader){v.rows[0].cells[0].children=v.rows[0].cells[1].children,v.rows[0].cells[1].children=[];for(var x=v.rows[0],P=0;Pl+1){var O=n.nameTable[v.rows[parseInt(i.toString(),10)].cells[l+1].children[0].id];v.updateColumnWidth(l+1,L[l+1].width,!0,f),O.maxWidth=O.wrapper.maxWidth=L[l+1].width}t.width=t.wrapper.width=t.wrapper.children[0].width=v.width}else{r=n.nameTable[v.rows[i+l].cells[0].children[0].id];var N=v.rowDefinitions(),T=N[i+l].height;(function hne(n,t,e,i,r){for(var o,a,l=e.rows[parseInt(i.toString(),10)],h=e.rows[i+1],c=e.rows[i-1],d=1;di+l+1&&v.updateRowHeight(i+l+1,T=N[i+l+1].height,!0,f),t.height=t.wrapper.height=t.wrapper.children[0].height=v.actualSize.height}if(Gf(t),t.width=t.wrapper.actualSize.width,Oc(n,t),n.drag(t,c-t.wrapper.bounds.x,d-t.wrapper.bounds.y),BI(t,n),n.commandHandler.select(r),!(n.diagramActions&ee.UndoRedo)){var D={type:"PhaseCollectionChanged",changeType:"Insert",undoObject:$(A),redoObject:$(r),category:"Internal"};n.addHistoryEntry(D)}n.updateDiagramObject(t)}}}}function H3(n,t,e,i,r,s,o){var a,l,p,h=t.shape,c="Horizontal"===h.orientation,d=t.wrapper.children[0],g=c?s:o;e?(a=c?e.bounds.x+e.bounds.width:e.bounds.x,l=c?e.bounds.y:e.bounds.y+e.bounds.height):(a=d.bounds.x,l=r.bounds.y);var v=new Ne(a,l,i.desiredCellWidth,i.desiredCellHeight),S=Qv(n,0,t,{id:t.id+(c?h.lanes[g-2]:h.lanes[g-1]).id+Qe()[0],rowIndex:s,columnIndex:o,width:i.minWidth,height:i.minHeight,style:(c?h.lanes[g-2]:h.lanes[g-1]).style,constraints:ie.Default|ie.AllowDrop,container:{type:"Canvas",orientation:c?"Horizontal":"Vertical"}},!1,!1,!0);if(S.children[0].isCalculateDesiredSize=!1,d.addObject(S,s,o),r&&r.children&&r.children.length)for(p=0;p1)for(var p=1;ph.margin.left&&(h.margin.left=f)):(h.margin.top-=e.desiredCellHeight,f>h.margin.top&&(h.margin.top=f)))}(n,r,i,v,S,c,e)}function B3(n,t,e){if("SwimLane"===t.shape.type&&("ResizeSouth"===e||"ResizeEast"===e)){var i=t.shape,r=t.wrapper.children[0],s=void 0,o=void 0;"ResizeSouth"===e?"Vertical"===i.orientation?s=r.rows[r.rows.length-1].cells[0]:(o=r.rows.length-1,s=r.rows[parseInt(o.toString(),10)].cells[r.rows[parseInt(o.toString(),10)].cells.length-1]):(o=i.header&&i.hasHeader?1:0,s=r.rows[parseInt(o.toString(),10)].cells[r.rows[parseInt(o.toString(),10)].cells.length-1]),n.commandHandler.select(n.nameTable[s.children[0].id])}}function jI(n,t,e,i,r,s){var o,a,l,c,u,f,p,d=Qe(),g=n.shape,v=g.phases,y=n.offsetX-n.wrapper.actualSize.width/2,S=n.offsetY-n.wrapper.actualSize.height/2;if("Vertical"===g.orientation&&(S+=g.header&&g.hasHeader?g.header.height:0),!s)for(r||(n.id+=d,g&&g.header&&g.hasHeader?g.header.id+=d:g.header=void 0),o=0;v&&o0&&s.columnIndex>0||s.isLane)?(a=function Sne(n,t,e){for(var i=new Ne,r="SwimLane"===n.shape.type?n.wrapper.children[0].rows:n.wrapper.rows,s=e?1:0;s=0;a--)i?i.id===o.children[parseInt(a.toString(),10)].id&&o.children.splice(a,1):(n.removeDependentConnector(o.children[parseInt(a.toString(),10)]),n.diagramActions&ee.UndoRedo||(n.diagramActions=n.diagramActions|ee.UndoRedo,s=!0),n.remove(o.children[parseInt(a.toString(),10)]),o.children.splice(a,1),s&&(n.diagramActions=n.diagramActions&~ee.UndoRedo))}function dne(n){return n.children[0]}function qv(n,t){t&&(n.nodes.splice(n.nodes.indexOf(t),1),n.removeFromAQuad(t),n.removeObjectsFromLayer(t),delete n.nameTable[t.id],n.removeElements(t))}function _3(n,t,e,i){var r;if("SwimLane"===e.shape.type){var s=e.shape,o=void 0;if(1===s.lanes.length)n.remove(e);else{var a=e.wrapper.bounds.x,l=e.wrapper.bounds.y,h=void 0,c=void 0,d=void 0,u=void 0,p=e.wrapper.children[0];if(o=i?s.lanes.indexOf(i):FI(e,t),r={element:t,cause:n.diagramActions,diagramAction:n.getDiagramAction(n.diagramActions),state:"Changing",type:"Removal",cancel:!1,laneIndex:o},n.triggerEvent(Ce.collectionChange,r),!r.cancel){var g=s.lanes[parseInt(o.toString(),10)],v=g.children;g.children=[];for(var y=0;y0)for(u=0;u0)for(u=0;u0)for(e=0;e1){c===l.phases.length-1&&(o=!0,a=$(l.phases[c-1]));var u=$(l.phases[parseInt(c.toString(),10)]);if(l.phases.splice(c,1),!(n.diagramActions&ee.UndoRedo)){var f={type:"PhaseCollectionChanged",changeType:"Remove",undoObject:u,previousPhase:a,redoObject:$(t),category:"Internal",isLastPhase:o};n.addHistoryEntry(f)}"Horizontal"===l.orientation?function fne(n,t,e,i){var r,s,o,a,l,h,c,d,u,f,p,g;for(i=void 0!==i?i:e.columnIndex,c=0;c1&&(s=r.cells[parseInt(i.toString(),10)],l=(o=r.cells.length-1===i?r.cells[i-1]:r.cells[i+1]).children[0],s.children.length>0))if(p=n.nameTable[(a=s.children[0]).id],0===o.children.length&&s.children.length>0)o.children=s.children,o.columnSpan=s.columnSpan-1;else{for(d=0;d0){var M=s.children[0],w=n.nameTable[M.id];if(i=e.x&&a.bounds.y<=e.y&&a.bounds.bottom>=e.y){var l=void 0,h=a.bounds.y,c=a.bounds.x,d=n.nameTable[r.parentId]||r;if("SwimLane"===d.shape.type)o=Zv(r,d,t,n,!0);else{var f=n.nameTable[r.parentId]||r,p=f.shape;l=f.wrapper,a.actualSize.widtha.outerBounds.x)&&(void 0!==r.rowIndex?(l.updateColumnWidth(r.columnIndex,a.outerBounds.width,!0),"Horizontal"===p.orientation&&p.phaseSize&&UI(f,n,a,r.columnIndex),Oc(n,f),n.drag(f,c-a.bounds.x,h-a.bounds.y)):n.scale(r,1+(a.outerBounds.width-a.actualSize.width)/a.actualSize.width,1,a.outerBounds.xa.outerBounds.y)&&(void 0!==r.rowIndex?(l.updateRowHeight(r.rowIndex,a.outerBounds.height,!0),n.drag(f,c-a.bounds.x,h-a.bounds.y)):n.scale(r,1,1+(a.outerBounds.height-a.actualSize.height)/a.actualSize.height,a.outerBounds.y=e.x&&a.bounds.y<=e.y&&a.bounds.bottom>=e.y)&&!(t.constraints&ie.AllowMovingOutsideLane)){var l=$(t);n.clearSelection(),W3(n,t),t.parentId="",t.parentObj=n,t.propName="nodes";var h={type:"ChildCollectionChanged",category:"Internal",undoObject:l,redoObject:$(t)};n.addHistoryEntry(h),n.commandHandler.isContainer&&(n.commandHandler.isContainer=!1,n.endGroupAction()),Y3(t,n)}n.protectPropertyChange(o)}}function VI(n,t){var e,i,r;return n.enableServerDataBinding(!1),ce()||(n.selectedObject.helperObject?r=n.selectedObject.helperObject:(n.selectedItems.nodes.length>0||n.selectedItems.connectors.length>0)&&(t instanceof ti&&t.nodes.length+t.connectors.length===1?(e=t.nodes.length>0?t.nodes[0]:t.connectors[0],i=n.selectedItems.wrapper.children[0]):(e=t,i=n.selectedItems.wrapper),n.selectedObject.actualObject=e,!n.currentSymbol&&(e.isLane&&Vx(e,n)&&Dn(n,e)||!e.isLane&&Dn(n,e)||n.constraints&nt.LineRouting&&n.selectedItems.nodes.length>0))&&(r=function Ine(n,t){for(var e,i={},r=0,s=Object.keys(t);r=t.x-e&&n.x<=t.x+e&&n.y>=t.y-e&&n.y<=t.y+e}function $a(n){return n.selectedItems.nodes.length>0||n.selectedItems.connectors.length>0}function G3(n){return 1===n.selectedItems.connectors.length&&!n.selectedItems.nodes.length}function _r(n,t,e,i){if(void 0===e&&(e=!0),t instanceof ti)return!0;if(t instanceof te)for(;t;){if(-1!==n.selectedItems.nodes.indexOf(t)&&void 0===n.selectedItems.annotation)return!0;if(e)break;t=n.nameTable[t.parentId]}else if(t instanceof de){if(-1!==n.selectedItems.connectors.indexOf(t)&&void 0===n.selectedItems.annotation)return!0}else if((t instanceof Kn||t instanceof Or)&&n.selectedItems.annotation&&n.selectedItems.wrapper.children[0].id===i.id)return!0;return!1}var Wx={None:"default",Rotate:"crosshair",Select:"default",Drag:"move",ResizeWest:"w-resize",ResizeEast:"e-resize",ResizeSouth:"s-resize",ResizeNorth:"n-resize",Draw:"crosshair",PortDraw:"crosshair",ResizeNorthEast:"ne-resize",ResizeNorthWest:"nw-resize",ResizeSouthEast:"se-resize",ResizeSouthWest:"sw-resize",ConnectorSourceEnd:"move",ConnectorTargetEnd:"move",BezierSourceThumb:"move",BezierTargetThumb:"move",OrthoThumb:"move",SegmentEnd:"move",Pan:"grab",Hyperlink:"pointer",PortDrag:"pointer",LabelSelect:"pointer",LabelDrag:"move",LabelRotate:"crosshair",LabelResizeWest:"w-resize",LabelResizeEast:"e-resize",LabelResizeSouth:"s-resize",LabelResizeNorth:"n-resize",LabelResizeNorthEast:"ne-resize",LabelResizeNorthWest:"nw-resize",LabelResizeSouthEast:"se-resize",LabelResizeSouthWest:"sw-resize"},ds=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Nd=function(n,t,e,i){return new(e||(e=Promise))(function(r,s){function o(h){try{l(i.next(h))}catch(c){s(c)}}function a(h){try{l(i.throw(h))}catch(c){s(c)}}function l(h){h.done?r(h.value):new e(function(c){c(h.value)}).then(o,a)}l((i=i.apply(n,t||[])).next())})},Od=function(n,t){var i,r,s,o,e={label:0,sent:function(){if(1&s[0])throw s[1];return s[1]},trys:[],ops:[]};return o={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function a(h){return function(c){return function l(h){if(i)throw new TypeError("Generator is already executing.");for(;e;)try{if(i=1,r&&(s=2&h[0]?r.return:h[0]?r.throw||((s=r.return)&&s.call(r),0):r.next)&&!(s=s.call(r,h[1])).done)return s;switch(r=0,s&&(h=[2&h[0],s.value]),h[0]){case 0:case 1:s=h;break;case 4:return e.label++,{value:h[1],done:!1};case 5:e.label++,r=h[1],h=[0];continue;case 7:h=e.ops.pop(),e.trys.pop();continue;default:if(!(s=(s=e.trys).length>0&&s[s.length-1])&&(6===h[0]||2===h[0])){e=0;continue}if(3===h[0]&&(!s||h[1]>s[0]&&h[1]-1&&(r=i.fixedUserHandles[parseInt(o.toString(),10)]);this.commandHandler.triggerEvent(Ce.fixedUserHandleClick,{fixedUserHandle:r,element:e.source}),n.prototype.mouseUp.call(this,e)},t}(us),kd=function(n){function t(e,i){var r=n.call(this,e,!0)||this;return r.isConnected=!1,r.endPoint=i,r}return ds(t,n),t.prototype.mouseDown=function(e){return Nd(this,void 0,void 0,function(){var r,s,o,a,l;return Od(this,function(h){if(this.inAction=!0,this.undoElement=void 0,this instanceof pa||(this.undoElement=$(e.source)),n.prototype.mouseDown.call(this,e),e.source&&e.source.connectors&&(this.oldConnector=$(r=e.source.connectors[0])),"BezierSourceThumb"===this.endPoint||"BezierTargetThumb"===this.endPoint)for(s=0;s0))},t.prototype.endAction=function(){n.prototype.endAction.call(this),this.prevPosition=null,this.endPoint=null},t}(us),fa=function(n){function t(e,i){var r=n.call(this,e,!0)||this;return r.currentTarget=null,r.isStartAction=!1,r.canCancel=!1,r.canTrigger=!1,r.objectType=i,r}return ds(t,n),t.prototype.mouseDown=function(e){if(e.source instanceof te||e.source instanceof de){var i=this.commandHandler.getSelectedObject();this.commandHandler.selectObjects([e.source],e.info&&e.info.ctrlKey,i);var r={nodes:[],connectors:[]};e.source instanceof te?r.nodes.push($(e.source)):r.connectors.push($(e.source)),this.undoElement=$(r)}else this.undoElement=$(e.source);this.undoParentElement=this.commandHandler.getSubProcess(e.source),"Port"===this.objectType&&(this.portId=e.sourceWrapper.id),this.commandHandler.insertBlazorConnector(e.source),n.prototype.mouseDown.call(this,e),this.initialOffset={x:0,y:0}},t.prototype.mouseUp=function(e,i){return Nd(this,void 0,void 0,function(){var s,o,a,l,h,c,d,u,p,g,v,y,S,b,M;return Od(this,function(w){if(this.checkPropertyValue(),a=!1,h={nodes:[],connectors:[]},"Port"!==this.objectType){if(e.source instanceof te||e.source instanceof de?(e.source instanceof te?h.nodes.push($(e.source)):h.connectors.push($(e.source)),(o=$(h)).offsetX=(c=e.source.wrapper).offsetX,o.offsetY=c.offsetY):o=$(e.source),("helper"===(l=this.commandHandler.renderContainerHelper(e.source)||e.source||this.commandHandler.renderContainerHelper(e.source)).id||"helper"!==l.id)&&((l instanceof ti&&(Math.round(l.width)===Math.round(this.undoElement.width)&&Math.round(l.height)===Math.round(this.undoElement.height)||l.selectedObjects&&1===l.selectedObjects.length)||!(l instanceof ti))&&(l.offsetX!==this.undoElement.offsetX||l.offsetY!==this.undoElement.offsetY||l.sourcePoint!==this.undoElement.sourcePoint||l.targetPoint!==this.undoElement.targetPoint)||this.isSelectionHasConnector(l))&&(e.source&&(s={offsetX:e.source.wrapper.offsetX,offsetY:e.source.wrapper.offsetY}),g={source:e.source,state:"Completed",oldValue:this.intialValue,newValue:s,target:this.currentTarget,targetPosition:this.currentPosition,allowDrop:(g={source:e.source,state:"Completed",oldValue:this.intialValue,newValue:s,target:this.currentTarget,targetPosition:this.currentPosition,allowDrop:!0,cancel:!1}).allowDrop,cancel:g.cancel},d=!0,"helper"===l.id?this.canTrigger?(this.commandHandler.triggerEvent(Ce.positionChange,g),this.connectorEndPointChangeEvent(g),d=!0):d=!1:(this.commandHandler.triggerEvent(Ce.positionChange,g),this.connectorEndPointChangeEvent(g)),!i&&d&&(this.commandHandler.startGroupAction(),a=!0,M={type:"PositionChanged",redoObject:$(o),undoObject:$(this.undoElement),category:"Internal"},o.nodes[0]&&o.nodes[0].processId&&(u={type:"SizeChanged",category:"Internal",undoObject:this.undoParentElement,redoObject:this.commandHandler.getSubProcess(e.source)},this.commandHandler.addHistoryEntry(u)),this.commandHandler.addHistoryEntry(M))),this.commandHandler.snapPoint(this.prevPosition,this.currentPosition,0,0),this.commandHandler.removeSnap(),this.commandHandler.removeHighlighter(),e.source&&this.currentTarget&&PI(this.currentTarget)&&this.commandHandler.isDroppable(e.source,this.currentTarget)){if(p=!0,this.commandHandler.drop(this.currentElement,this.currentTarget,this.currentPosition),this.currentTarget&&this.currentTarget instanceof de&&!0===this.commandHandler.diagram.enableConnectorSplit)if(this.currentElement&&this.currentElement instanceof te){if(void 0!==this.currentElement.children)for(b=0;b0)for(var s=0;s0)for(var a=0;a0)for(a=0;a0&&e.connectors.length>0)||e.width===this.undoElement.width&&e.height===this.undoElement.height)},t.prototype.mouseMove=function(e){n.prototype.mouseMove.call(this,e);var r,s,i=!1;(r=this.commandHandler.renderContainerHelper(e.source)||e.source)instanceof te||r instanceof de?r instanceof te?r.offsetX===this.undoElement.nodes[0].offsetX&&r.offsetY===this.undoElement.nodes[0].offsetY&&(i=!0):R.equals(r.sourcePoint,this.undoElement.connectors[0].sourcePoint)&&R.equals(r.targetPoint,this.undoElement.connectors[0].targetPoint)&&(i=!0):r.wrapper.offsetX===this.undoElement.wrapper.offsetX&&r.wrapper.offsetY===this.undoElement.wrapper.offsetY&&(i=!0),r&&(s={offsetX:r.wrapper.offsetX,offsetY:r.wrapper.offsetY});var o={source:r,state:"Start",oldValue:s,newValue:s,target:e.target,targetPosition:e.position,allowDrop:!0,cancel:!1};if(o={source:r,state:"Start",oldValue:s,newValue:s,target:e.target,targetPosition:e.position,allowDrop:o.allowDrop,cancel:o.cancel},this.isStartAction||(this.intialValue={offsetX:r.wrapper.offsetX,offsetY:r.wrapper.offsetY}),i&&!ce()&&(this.commandHandler.triggerEvent(Ce.positionChange,o),this.connectorEndPointChangeEvent(o),this.isStartAction=!0),this.currentPosition=e.position,"Port"!==this.objectType){var h=this.initialOffset.x+(this.currentPosition.x-this.prevPosition.x),c=this.initialOffset.y+(this.currentPosition.y-this.prevPosition.y);this.commandHandler.dragOverElement(e,this.currentPosition),this.commandHandler.disConnect(e.source),this.commandHandler.removeSnap();var d,u=void 0,f=this.commandHandler.snapPoint(this.prevPosition,this.currentPosition,h,c);this.initialOffset.x=h-f.x,this.initialOffset.y=c-f.y,r&&(d={offsetX:r.wrapper.offsetX,offsetY:r.wrapper.offsetY},u={offsetX:r.wrapper.offsetX+f.x,offsetY:r.wrapper.offsetY+f.y}),this.currentTarget&&e.target!==this.currentTarget&&this.commandHandler.removeChildFromBPmn(e.source,e.target,this.currentTarget),this.currentTarget=e.target;var p={source:r,state:"Progress",oldValue:d,newValue:u,target:e.target,targetPosition:e.position,allowDrop:!0,cancel:!1};if(this.commandHandler.triggerEvent(Ce.positionChange,p),this.canTrigger=!0,this.connectorEndPointChangeEvent(p,f),!p.cancel&&!this.canCancel){this.blocked=!this.commandHandler.dragSelectedObjects(f.x,f.y);var g=!this.commandHandler.mouseOver(this.currentElement,this.currentTarget,this.currentPosition);this.blocked=this.blocked||g}if(this.commandHandler.removeStackHighlighter(),this.commandHandler.renderStackHighlighter(e),this.currentTarget&&e.source!==this.currentTarget&&this.commandHandler.isDroppable(e.source,this.currentTarget)&&"helper"!==e.source.id){var v=e.source instanceof ti?e.source.nodes[0]:e.source;!this.commandHandler.isParentAsContainer(v,!0)&&"SwimLane"!==v.shape.type&&!v.shape.isPhase&&(this.currentTarget.isLane?this.commandHandler.renderStackHighlighter(e,this.currentTarget):this.commandHandler.drawHighlighter(this.currentTarget))}else this.commandHandler.removeHighlighter();if(this.commandHandler.canEnableDefaultTooltip()){var y=this.getTooltipContent(e.source);this.commandHandler.showTooltip(e.source,e.position,ko(function(){return y}),"MoveTool",this.isTooltipVisible),this.isTooltipVisible=!1}}else{var b=Bi(),M=e.source;qi(b,-M.rotateAngle||-M.wrapper.rotateAngle,M.offsetX||M.wrapper.offsetX,M.offsetY||M.wrapper.offsetY);var w=Ke(b,{x:this.prevPosition.x,y:this.prevPosition.y}),C=Ke(b,{x:e.position.x,y:e.position.y});this.commandHandler.portDrag(e.source,e.sourceWrapper,C.x-w.x,C.y-w.y)}return this.prevPosition=this.currentPosition,!this.blocked},t.prototype.getTooltipContent=function(e){return"X:"+Math.round(e.wrapper.bounds.x)+" Y:"+Math.round(e.wrapper.bounds.y)},t.prototype.mouseLeave=function(e){this.mouseUp(e)},t.prototype.endAction=function(){n.prototype.endAction.call(this),this.currentTarget=null,this.prevPosition=null},t}(us),Yx=function(n){function t(e){var i=n.call(this,e,!0)||this;return i.rotateStart=!1,i}return ds(t,n),t.prototype.mouseDown=function(e){if(this.undoElement=$(e.source),this.undoElement.nodes[0]&&this.undoElement.nodes[0].children)for(var r=this.commandHandler.getAllDescendants(this.undoElement.nodes[0],[]),s=0;s=2){var s=e.startTouches[0],o=e.startTouches[1],a=e.moveTouches[0],l=e.moveTouches[1],h=this.getDistance(a,l)/this.getDistance(s,o);this.commandHandler.zoom(h,0,0,e.position),this.updateTouch(s,a),this.updateTouch(o,l)}}else this.commandHandler.scroll(this.currentPosition.x-this.prevPosition.x,this.currentPosition.y-this.prevPosition.y,this.currentPosition);return this.commandHandler.dataBinding(),!this.blocked},t.prototype.mouseUp=function(e){this.commandHandler.setBlazorDiagramProps(!1),this.checkPropertyValue(),this.commandHandler.updatePanState(!1),n.prototype.mouseUp.call(this,e),this.inAction=!1},t.prototype.endAction=function(){n.prototype.endAction.call(this)},t.prototype.getDistance=function(e,i){var r=i.pageX-e.pageX,s=i.pageY-e.pageY;return Math.sqrt(r*r+s*s)},t.prototype.updateTouch=function(e,i){e.pageX=i.pageX,e.pageY=i.pageY},t}(us),Lne=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseUp=function(e){this.checkPropertyValue(),this.commandHandler.initExpand(e),n.prototype.mouseUp.call(this,e)},t}(us),X3=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseUp=function(e){this.checkPropertyValue();var i="_blank",r="",s=window.innerHeight,o=window.innerWidth,a=window.screenTop,l=window.screenLeft;"CurrentTab"===e.sourceWrapper.hyperlink.hyperlinkOpenState?i="_self":"NewWindow"===e.sourceWrapper.hyperlink.hyperlinkOpenState&&(r="height="+s+",width="+o+",top="+a+",left="+l),window.open(e.sourceWrapper.hyperlink.link,i,r).focus(),n.prototype.mouseUp.call(this,e)},t}(us),zl=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseDown=function(e){if(n.prototype.mouseDown.call(this,e),this.inAction=!0,this.drawingObject){var r=void 0,s=this.drawingObject.shape;this.drawingObject.shape.points.push(r={x:(r=s.points[s.points.length-1]).x,y:r.y})}else{this.startPoint={x:this.startPosition.x,y:this.startPosition.y};var i={offsetX:this.currentPosition.x,offsetY:this.currentPosition.y,width:5,height:5,shape:{type:"Basic",shape:"Polygon",points:[{x:this.startPoint.x,y:this.startPoint.y},{x:this.currentPosition.x,y:this.currentPosition.y}]}};this.triggerElementDrawEvent(e.source,"Start","Node",this.getShapeType(),!0),this.drawingObject=this.commandHandler.drawObject(i)}},t.prototype.mouseMove=function(e){if(n.prototype.mouseMove.call(this,e),this.inAction){var i=this.drawingObject.shape;if(i.points[i.points.length-1].x=this.currentPosition.x,i.points[i.points.length-1].y=this.currentPosition.y,this.drawingObject.wrapper.children[0].data=vx(this.drawingObject.shape.points),this.triggerElementDrawEvent(this.drawingObject,"Progress","Node",this.getShapeType(),!1),this.inAction&&!1===R.equals(this.currentPosition,this.prevPosition)){var r=Ne.toBounds(this.drawingObject.shape.points);this.commandHandler.updateNodeDimension(this.drawingObject,r)}}return!0},t.prototype.mouseUp=function(e,i){this.checkPropertyValue(),n.prototype.mouseMove.call(this,e),this.inAction&&(this.inAction=!1,this.commandHandler.addObjectToDiagram(this.drawingObject),this.triggerElementDrawEvent(this.drawingObject,"Completed","Node",this.getShapeType(),!1)),this.endAction()},t.prototype.mouseWheel=function(e){n.prototype.mouseWheel.call(this,e),this.mouseMove(e)},t.prototype.endAction=function(){this.inAction=!1,this.drawingObject=null},t}(us),Rl=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseMove=function(e){if(n.prototype.mouseMove.call(this,e),this.inAction){var i=this.drawingObject;i.targetPoint=this.currentPosition,this.triggerElementDrawEvent(this.drawingObject,"Progress","Connector",this.drawingObject.type,!1),this.commandHandler.updateConnectorPoints(i)}return!0},t.prototype.mouseDown=function(e){if(n.prototype.mouseDown.call(this,e),this.inAction=!0,this.drawingObject){var r=this.drawingObject,s=void 0;(s=new Hl(r,"segments",{type:"Straight"},!0)).point=this.currentPosition,r.segments[r.segments.length-1]=s}else{var i={id:"Connector",type:"Straight",sourcePoint:this.currentPosition,targetPoint:this.currentPosition};this.triggerElementDrawEvent(e.source,"Start","Connector",this.commandHandler.diagram.drawingObject.type,!0),this.inAction&&(this.drawingObject=this.commandHandler.drawObject(i))}},t.prototype.mouseWheel=function(e){n.prototype.mouseWheel.call(this,e),this.mouseMove(e)},t.prototype.mouseUp=function(e){if(this.checkPropertyValue(),n.prototype.mouseMove.call(this,e),this.inAction&&this.drawingObject){var i=this.drawingObject;i.segments[i.segments.length-1].point={x:0,y:0},this.commandHandler.addObjectToDiagram(this.drawingObject),this.triggerElementDrawEvent(this.drawingObject,"Completed","Connector",this.drawingObject.type,!1)}this.endAction()},t.prototype.endAction=function(){this.drawingObject=null,this.inAction=!1},t}(us),Nne=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseDown=function(e){this.inAction=!0,this.undoElement=$(e.source),this.annotationId=e.sourceWrapper.id,n.prototype.mouseDown.call(this,e)},t.prototype.mouseMove=function(e){n.prototype.mouseMove.call(this,e);var i=this.currentPosition.x-this.prevPosition.x,r=this.currentPosition.y-this.prevPosition.y,s=e.source;if(s instanceof te){var o=Bi();qi(o,-s.rotateAngle,0,0);var a=Ke(o,{x:i,y:r});i=a.x,r=a.y}return this.inAction&&(this.commandHandler.labelDrag(e.source,e.sourceWrapper,i,r),this.commandHandler.updateSelector()),this.prevPosition=this.currentPosition,!this.blocked},t.prototype.mouseUp=function(e){this.checkPropertyValue();var i=e.source;this.inAction=!1;var r={type:"AnnotationPropertyChanged",objectId:this.annotationId,undoObject:$(this.undoElement),category:"Internal",redoObject:$(i)};this.commandHandler.addHistoryEntry(r),n.prototype.mouseUp.call(this,e)},t.prototype.mouseLeave=function(e){this.mouseUp(e)},t}(us),One=function(n){function t(e,i){var r=n.call(this,e,!0)||this;return r.corner=i,r}return ds(t,n),t.prototype.mouseDown=function(e){this.inAction=!0;var i=e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0];this.annotationId=e.source.wrapper.children[0].id,this.undoElement=$(i);var r=e.source.wrapper.children[0];this.initialBounds={x:r.offsetX,y:r.offsetY,width:r.actualSize.width,height:r.actualSize.height},n.prototype.mouseDown.call(this,e)},t.prototype.mouseMove=function(e){return n.prototype.mouseMove.call(this,e),this.inAction&&this.resizeObject(e),!this.blocked},t.prototype.mouseUp=function(e){this.checkPropertyValue();var i=e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0];this.inAction=!1;var r={type:"AnnotationPropertyChanged",objectId:this.annotationId,redoObject:$(i),undoObject:$(this.undoElement),category:"Internal"};this.commandHandler.addHistoryEntry(r),n.prototype.mouseUp.call(this,e)},t.prototype.mouseLeave=function(e){this.mouseUp(e)},t.prototype.resizeObject=function(e){var i,s,o,r=e.source.wrapper.children[0],a={x:r.offsetX,y:r.offsetY},l=r.rotateAngle;l=((l+=(i=e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0])instanceof te?i.rotateAngle:0)+360)%360;var h=Bi();qi(h,l,a.x,a.y);var c=this.corner.slice(5),d=this.updateSize(r,this.startPosition,this.currentPosition,c,this.initialBounds,l),u=r.offsetX-r.actualSize.width*r.pivot.x,f=r.offsetY-r.actualSize.height*r.pivot.y,p=this.getPivot(c),g=Ke(h,p={x:u+r.actualSize.width*p.x,y:f+r.actualSize.height*p.y});d.x=g.x,d.y=g.y,this.commandHandler.labelResize(i,e.source.annotation,s=(s=d.width)<0?1:s,o=(o=d.height)<0?1:o,d,e.source),this.commandHandler.updateSelector()},t}(us),kne=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseDown=function(e){this.inAction=!0,this.annotationId=e.source.wrapper.children[0].id,this.undoElement=$(e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0]),n.prototype.mouseDown.call(this,e)},t.prototype.mouseMove=function(e){return n.prototype.mouseMove.call(this,e),e.source&&this.inAction&&(this.commandHandler.labelRotate(e.source.nodes[0]?e.source.nodes[0]:e.source.connectors[0],e.source.annotation,this.currentPosition,e.source),this.commandHandler.updateSelector()),this.prevPosition=this.currentPosition,!this.blocked},t.prototype.mouseUp=function(e){this.checkPropertyValue(),this.inAction=!1;var r={type:"AnnotationPropertyChanged",objectId:this.annotationId,redoObject:$(e.source.nodes.length?e.source.nodes[0]:e.source.connectors[0]),undoObject:$(this.undoElement),category:"Internal"};this.commandHandler.addHistoryEntry(r),n.prototype.mouseUp.call(this,e)},t.prototype.mouseLeave=function(e){this.mouseUp(e)},t}(us),Pne=function(n){function t(e){return n.call(this,e,!0)||this}return ds(t,n),t.prototype.mouseMove=function(e){if(n.prototype.mouseMove.call(this,e),this.inAction){var i=this.drawingObject.shape;if(i.points.push(this.currentPosition),this.drawingObject.wrapper.children[0].data=mx(this.drawingObject.shape.points),i.data=mx(i.points),this.triggerElementDrawEvent(e.source,"Progress","Connector",this.drawingObject.type,!1),this.inAction&&!1===R.equals(this.currentPosition,this.prevPosition)){var s=Ne.toBounds(this.drawingObject.shape.points);this.commandHandler.updateNodeDimension(this.drawingObject,s)}}return!0},t.prototype.mouseDown=function(e){n.prototype.mouseDown.call(this,e),this.inAction=!0,this.startPoint={x:this.startPosition.x,y:this.startPosition.y};var i={offsetX:this.currentPosition.x,offsetY:this.currentPosition.y,width:5,height:5,style:{strokeColor:"black",strokeWidth:1,fill:"transparent"},shape:{type:"Path",points:[{x:this.startPoint.x,y:this.startPoint.y},{x:this.currentPosition.x,y:this.currentPosition.y}]}};this.triggerElementDrawEvent(e.source,"Start","Connector",this.commandHandler.diagram.drawingObject.type,!0),this.drawingObject=this.commandHandler.drawObject(i)},t.prototype.mouseUp=function(e){if(this.checkPropertyValue(),this.inAction){this.inAction=!1;var s=this.drawingObject.shape,o=s.points;this.commandHandler.addObjectToDiagram(this.drawingObject),this.commandHandler.diagram.remove(this.commandHandler.diagram.nameTable[""+this.drawingObject.id]),o=this.pointReduction(o,10);var h={id:"newConnector"+Qe(),type:"Bezier",sourcePoint:{x:o[0].x,y:o[0].y},targetPoint:{x:o[o.length-1].x,y:o[o.length-1].y},segments:[],bezierSettings:{allowSegmentsReset:!1}};this.drawingObject=this.commandHandler.drawObject(h),this.drawingObject=this.bezierCurveSmoothness(o,.5,this.drawingObject,s),this.commandHandler.updateConnectorPoints(this.drawingObject),this.commandHandler.addObjectToDiagram(this.drawingObject),this.triggerElementDrawEvent(this.drawingObject,"Completed","Connector",this.drawingObject.type,!1),n.prototype.mouseUp.call(this,e)}},t.prototype.pointReduction=function(e,i){if(null===e||e.length<3)return e;var s=e.length-1,o=[];for(o.push(0),o.push(s);e[parseInt((0).toString(),10)]===e[parseInt(s.toString(),10)];)s--;this.reduction(e,0,s,i,o);var a=[];return o.sort(function(l,h){return l-h}),o.forEach(function(l){a.push(e[parseInt(l.toString(),10)])}),a},t.prototype.reduction=function(e,i,r,s,o){for(var a=0,l=0,h=i;ha&&(a=c,l=h)}a>s&&0!==l&&(o.push(l),this.reduction(e,i,l,s,o),this.reduction(e,l,r,s,o))},t.prototype.perpendicularDistance=function(e,i,r){return Math.abs(.5*(e.x*i.y-i.x*e.y+(i.x*r.y-r.x*i.y)+(r.x*e.y-e.x*r.y)))/Math.sqrt(Math.pow(e.x-i.x,2)+Math.pow(e.y-i.y,2))*2},t.prototype.bezierCurveSmoothness=function(e,i,r,s){if(e.length<3)return r;for(var o=0;o=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},zne=function(n){if(n)switch(n.type){case"Bpmn":return Fne;case"UmlActivity":return Bne;case"UmlClassifier":return jne;default:return em}return em},Rne=function(n){if(n)switch(n.type){case"Straight":default:return Hl;case"Bezier":return fs;case"Orthogonal":return wi}},q3=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I(10)],t.prototype,"width",void 0),Pe([I(10)],t.prototype,"height",void 0),Pe([I("Arrow")],t.prototype,"shape",void 0),Pe([re({fill:"black",strokeColor:"black",strokeWidth:1},Ll)],t.prototype,"style",void 0),Pe([re({x:0,y:.5},R)],t.prototype,"pivot",void 0),Pe([I("")],t.prototype,"pathData",void 0),t}(Ee),QI=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I(0)],t.prototype,"angle",void 0),Pe([I(0)],t.prototype,"distance",void 0),t}(Ee),Hne=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I(bx.All)],t.prototype,"controlPointsVisibility",void 0),Pe([I("FreeForm")],t.prototype,"segmentEditOrientation",void 0),Pe([I(SI.Default)],t.prototype,"smoothness",void 0),Pe([I(!0)],t.prototype,"allowSegmentsReset",void 0),t}(Ee),em=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I("None")],t.prototype,"type",void 0),t}(Ee),Bne=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I("Object")],t.prototype,"flow",void 0),Pe([I(30)],t.prototype,"exceptionFlowHeight",void 0),t}(em),Fne=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),Pe([I("Sequence")],t.prototype,"flow",void 0),Pe([I("Normal")],t.prototype,"sequence",void 0),Pe([I("Default")],t.prototype,"message",void 0),Pe([I("Default")],t.prototype,"association",void 0),t}(em),$3=function(n){function t(e,i,r,s){var o=n.call(this,e,i,r,s)||this;return o.points=[],o}return Qs(t,n),Pe([I("Straight")],t.prototype,"type",void 0),Pe([I(!0)],t.prototype,"allowDrag",void 0),t}(Ee),Hl=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),t.prototype.getClassName=function(){return"StraightSegment"},Pe([re({x:0,y:0},R)],t.prototype,"point",void 0),t}($3),fs=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),t.prototype.getClassName=function(){return"BezierSegment"},t.prototype.getPoints=function(e,i){var r=[];if(r.length>0||null!=i){var o=this.bezireToPoly(r.length>0?r[r.length-1]:i,e);r.push.apply(r,o)}return r},t.prototype.bezireToPoly=function(e,i){var r=[];return i&&this.flattenCubicBezier(r,e,i.bezierPoint1,i.bezierPoint2,{x:i.points[1].x,y:i.points[1].y},10),r},t.prototype.flattenCubicBezier=function(e,i,r,s,o,a){var h,l=(R.findLength(i,r)+R.findLength(r,s)+R.findLength(s,o))/a;for(h=0;h<=l;h++){var c=h/l;e.push({x:(1-c)*(1-c)*(1-c)*i.x+3*c*(1-c)*(1-c)*r.x+3*c*c*(1-c)*s.x+c*c*c*o.x,y:(1-c)*(1-c)*(1-c)*i.y+3*c*(1-c)*(1-c)*r.y+3*c*c*(1-c)*s.y+c*c*c*o.y})}},Pe([I("Horizontal")],t.prototype,"orientation",void 0),Pe([re({x:0,y:0},R)],t.prototype,"point1",void 0),Pe([re({x:0,y:0},R)],t.prototype,"point2",void 0),Pe([re({angle:0,distance:0},QI)],t.prototype,"vector1",void 0),Pe([re({angle:0,distance:0},QI)],t.prototype,"vector2",void 0),t}(Hl),wi=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Qs(t,n),t.prototype.getClassName=function(){return"OrthogonalSegment"},Pe([I(null)],t.prototype,"length",void 0),Pe([I(null)],t.prototype,"direction",void 0),t}($3);function Z3(n,t,e){var s=e?45:180/(2+2/(n.height/n.width)),o=s,a=180-s,l=a+2*s,h=360-s,c=Xt(t,n.center);return c>o&&ca&&cl&&cMath.abs(t.y-n.y)?n.x=c)return s=R.findAngle(n[parseInt(d.toString(),10)],n[d+1]),{point:r=R.transform(n[parseInt(d.toString(),10)],s,c-(a||0)),index:l=d};a=o[parseInt(d.toString(),10)]}return{point:r,index:l}}(n,t),r=R.findAngle(n[i.index],n[i.index+1]),s=function vse(n){var e=0;switch(n.alignment){case"Center":case"After":e=0;break;case"Before":e=-0}return e}(t),o=R.transform(i.point,r+45,s);return i.point=o,i.angle=r,i}(i,e),h=l.point;s.id=this.id+"_"+e.id;var c=e.style;s.style={fill:c.fill,strokeColor:c.strokeColor,gradient:null,opacity:c.opacity,strokeDashArray:c.strokeDashArray,strokeWidth:c.strokeWidth},0===r.width&&(r.width=this.style.strokeWidth),0===r.height&&(r.height=this.style.strokeWidth);var d_y=(h.y-r.y)/r.height;a.x=r.width*((h.x-r.x)/r.width),a.y=r.height*d_y;var g,v,u=fF(e,l.angle,i),f=u.hAlign,p=u.vAlign;return"left"===f?(g="Left",a.x+=e.displacement.x):"right"===f?(g="Right",a.x-=e.displacement.x):"center"===f&&(g="Center"),"top"===p?(v="Top",a.y+=e.displacement.y):"bottom"===p?(v="Bottom",a.y-=e.displacement.y):"center"===p&&(v="Center"),s.horizontalAlignment=g,s.verticalAlignment=v,(s=rm(s,o&&"Label"!==o.flipMode&&"None"!==o.flipMode?this.flip:"None",e)).float=!0,s.connectionDirection=e.connectionDirection,s.setOffsetWithRespectToBounds(a.x,a.y,"Absolute"),s.relativeMode="Point",s.visible=!(!va(e,Gt.Visible)||va(e,Gt.Hover)||va(e,Gt.Connect)),s.elementActions=s.elementActions|Xr.ElementIsPort,s},t.prototype.getConnectorRelation=function(){var e=this.shape;"Association"===e.relationship?(this.segments[0].type="Straight",this.sourceDecorator.shape="None",this.targetDecorator.shape="Arrow"):"Inheritance"===e.relationship?(this.segments[0].type="Orthogonal",this.sourceDecorator.shape="None",this.targetDecorator.shape="Arrow"):"Composition"===e.relationship||"Aggregation"===e.relationship?(this.segments[0].type="Orthogonal",this.sourceDecorator.shape="Diamond",this.targetDecorator.shape="None"):"Dependency"===e.relationship?(this.segments[0].type="Orthogonal",this.sourceDecorator.shape="None",this.targetDecorator.shape="OpenArrow"):"Realization"===e.relationship&&(this.segments[0].type="Orthogonal",this.sourceDecorator.shape="None",this.targetDecorator.shape="Arrow"),"BiDirectional"===e.associationType&&(this.sourceDecorator.shape="None",this.targetDecorator.shape="None");var i,o,r="",s="";e.multiplicity.source&&(e.multiplicity.source.lowerBounds=e.multiplicity.source.lowerBounds,e.multiplicity.source.upperBounds=e.multiplicity.source.upperBounds),e.multiplicity.target&&(e.multiplicity.target.lowerBounds=e.multiplicity.target.lowerBounds,e.multiplicity.target.upperBounds=e.multiplicity.target.upperBounds);var a=e.multiplicity.source,l=e.multiplicity.target;o=a.upperBounds?a.lowerBounds+"..."+a.upperBounds:a.lowerBounds,i=l.upperBounds?l.lowerBounds+"..."+l.upperBounds:l.lowerBounds,"ManyToOne"===e.multiplicity.type&&(e.multiplicity.target.optional=!1,r=o||"*",s="1"),"OneToMany"===e.multiplicity.type&&(e.multiplicity.source.optional=!1,s=i||"*",r="1"),"ManyToMany"===e.multiplicity.type&&(r=o||"*",s=i||"*"),"OneToOne"===e.multiplicity.type&&(e.multiplicity.target.optional=!1,e.multiplicity.source.optional=!1,r="1",s="1"),this.annotations=[{id:this.id+"sourcelabel",content:r,offset:0,alignment:"Before",margin:{right:5,bottom:5}},{id:this.id+"targetlabel",content:s,offset:1,alignment:"Before",margin:{right:5,bottom:5}}]},t.prototype.getBpmnSequenceFlow=function(){var e=new Ze,i=new Ze;return"Normal"===this.shape.sequence&&"Bezier"!==this.type&&(this.targetDecorator.shape="Arrow"),"Default"===this.shape.sequence&&(e=this.getSegmentElement(this,e),i=IF(this.intermediatePoints,this),this.targetDecorator.shape="Arrow"),"Conditional"===this.shape.sequence&&(this.targetDecorator.shape="Arrow",this.sourceDecorator.shape="Diamond",i.id=this.id+this.shape.type),i},t.prototype.getUMLObjectFlow=function(){if(this.annotations)for(var e=0;e0&&(this.sourcePoint=o[0],this.targetPoint=o[o.length-1]),o},t.prototype.clipDecorator=function(e,i,r,s){var a,l,o={x:0,y:0},h=i.length,c=R.distancePoints(a=r?i[0]:i[h-1],l=r?i[1]:i[h-2]);c=0===c?1:c;var d=1,u=r?e.sourceWrapper:e.targetWrapper;u&&(d=u.style.strokeWidth,s&&s&ee.DecoratorPropertyChange&&(d=1));var f=d-1;return o.x=Math.round(a.x+f*(l.x-a.x)/c),o.y=Math.round(a.y+f*(l.y-a.y)/c),(r&&"None"!==e.sourceDecorator.shape||!r&&"None"!==e.targetDecorator.shape)&&(o=R.adjustPoint(o,l,!0,s&ee.DecoratorPropertyChange?0:d/2)),o},t.prototype.clipDecorators=function(e,i,r){return"None"!==e.sourceDecorator.shape&&(i[0]=this.clipDecorator(e,i,!0,r)),"None"!==e.targetDecorator.shape&&(i[i.length-1]=this.clipDecorator(e,i,!1,r)),i},t.prototype.updateSegmentElement=function(e,i,r,s){var o=new Ne,a=this.getSegmentPath(e,i,s);if("Bezier"===e.type){if(this.segments.length>0)for(var l=0;l0)if("Straight"===e.type&&e.segments.length<2)for(var o=0;o1)for(o=0;o0&&"Bezier"!==this.type)for(var f=0;f0&&(a=f0&&(p<2*this.cornerRadius?(l=R.adjustPoint(h[parseInt(f.toString(),10)],h[f+1],!0,p/2),f0&&(s=this.bridgePath(e,s,f),"Orthogonal"===e.type&&(s=this.bridgePath(e,s,f+1))),s+=" L"+a.x+" "+a.y))}else if("Bezier"===this.type){var g=void 0,v=void 0;if(this.parentObj.element){var y=this.parentObj.element.ej2_instances[0].eventHandler.action;g=this.parentObj.element.ej2_instances[0].eventHandler.tool instanceof Pd,v=y.includes("PortDraw")||y.includes("Drag")}for(var S=void 0,b=this.segments,M=0;M2&&(b[parseInt(M.toString(),10)].bezierPoint1={x:0,y:0},b[parseInt(M.toString(),10)].bezierPoint2={x:0,y:0}),!R.isEmptyPoint(b[parseInt(M.toString(),10)].point1)||b[parseInt(M.toString(),10)].vector1.angle||b[parseInt(M.toString(),10)].vector1.distance?b[parseInt(M.toString(),10)].vector1.angle||b[parseInt(M.toString(),10)].vector1.distance?b[parseInt(M.toString(),10)].bezierPoint1=R.transform(h[parseInt(M.toString(),10)],b[parseInt(M.toString(),10)].vector1.angle,b[parseInt(M.toString(),10)].vector1.distance):b[parseInt(M.toString(),10)].bezierPoint1={x:b[parseInt(M.toString(),10)].point1.x||b[parseInt(M.toString(),10)].bezierPoint1.x,y:b[parseInt(M.toString(),10)].point1.y||b[parseInt(M.toString(),10)].bezierPoint1.y}:((e.sourceID||this.sourcePortID)&&this.sourceWrapper&&!v&&!g&&(S=Z3(this.sourceWrapper.bounds,h[parseInt(M.toString(),10)],!0)),b[parseInt(M.toString(),10)].bezierPoint1=XI(h[parseInt(M.toString(),10)],h[M+1],S)),!R.isEmptyPoint(b[parseInt(M.toString(),10)].point2)||b[parseInt(M.toString(),10)].vector2.angle||b[parseInt(M.toString(),10)].vector2.distance?b[parseInt(M.toString(),10)].vector2.angle||b[parseInt(M.toString(),10)].vector2.distance?b[parseInt(M.toString(),10)].bezierPoint2=R.transform(h[M+1],b[parseInt(M.toString(),10)].vector2.angle,b[parseInt(M.toString(),10)].vector2.distance):b[parseInt(M.toString(),10)].bezierPoint2={x:b[parseInt(M.toString(),10)].point2.x||b[parseInt(M.toString(),10)].bezierPoint2.x,y:b[parseInt(M.toString(),10)].point2.y||b[parseInt(M.toString(),10)].bezierPoint2.y}:((e.targetID||this.targetPortID)&&this.targetWrapper&&!v&&!g&&(S=Z3(this.targetWrapper.bounds,h[M+1],!0)),b[parseInt(M.toString(),10)].bezierPoint2=XI(h[M+1],h[parseInt(M.toString(),10)],S));h.splice(1,0,{x:b[0].bezierPoint1.x,y:b[0].bezierPoint1.y}),h.splice(h.length-1,0,{x:b[b.length-1].bezierPoint2.x,y:b[b.length-1].bezierPoint2.y}),h=this.clipDecorators(e,h,r);for(var w=0;w0&&(s=this.bridgePath(e,s,D),s+=" L"+o.x+" "+o.y);return s},t.prototype.updateShapeElement=function(e){var i;switch(e.shape.type){case"Bpmn":e.wrapper.children[3]instanceof Ze&&(i=e.wrapper.children[3]),"Message"===e.shape.flow&&this.updateShapePosition(e,i);break;case"UmlActivity":"Exception"===e.shape.flow&&this.getUMLExceptionFlow(e.wrapper.children[0])}},t.prototype.updateShapePosition=function(e,i){var o=bF(this.intermediatePoints,i,.5);i.offsetX=o.x,i.offsetY=o.y},t.prototype.scale=function(e,i,r,s,o){var a=0,l=0;if(this.wrapper&&this.wrapper.outerBounds){var h=function M3(n){var t=n.wrapper.children[0].bounds;return"None"!==n.sourceDecorator.shape&&t.uniteRect(n.wrapper.children[1].bounds),"None"!==n.targetDecorator.shape&&t.uniteRect(n.wrapper.children[2].bounds),t}(this),c=Math.abs((this.wrapper.bounds.width||this.style.strokeWidth||1)-2),d=Math.abs((this.wrapper.bounds.height||this.style.strokeWidth||1)-2);a=h.width-c,l=h.height-d,e=Math.abs((r-Math.max(a,l))/c),i=Math.abs((s-Math.max(a,l))/d),a=l=Math.min(a,l)}e=i=Math.min(e,i);var u=Bi();qi(u,-(o=o||this.wrapper).rotateAngle,o.offsetX,o.offsetY),Yf(u,e,i,o.offsetX,o.offsetY),qi(u,o.rotateAngle,o.offsetX,o.offsetY);var f=function Lie(n,t){for(var e=[],i=0,r=t;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Wne=function(n){function t(e,i){var r=n.call(this,e,i)||this;return r.offset=0,r.scale=1,r}return Vne(t,n),t.prototype.preRender=function(){this.unWireEvents(),this.wireEvents()},t.prototype.render=function(){this.updateRulerGeometry(),this.renderComplete()},t.prototype.getModuleName=function(){return"Ruler"},t.prototype.destroy=function(){this.unWireEvents(),this.notify("destroy",{}),n.prototype.destroy.call(this),this.element.classList.remove("e-ruler")},t.prototype.getPersistData=function(){return this.addOnPersist(["loaded"])},t.prototype.onPropertyChanged=function(e,i){for(var r=0,s=Object.keys(e);r100;)r/=10,s/=10;for(;s<25;)r*=10,s*=10;return s>=25&&s%25!=0&&(s=25*Math.round(s/25)),s*e/r},t.prototype.createMarkerLine=function(e,i,r){var s;return i&&((s=e.getElementById(i.id+"_marker"))&&s.parentNode.removeChild(s),s=Fi("line",r)),s},t.prototype.drawRulerMarker=function(e,i,r){var s,o,h,d,u="Horizontal"===this.orientation,f=e.getElementsByTagName("svg");for(h=0;h0)for(var a=i.childNodes.length-1;a>=0;a--)i.childNodes[parseInt(a.toString(),10)].parentNode.removeChild(i.childNodes[parseInt(a.toString(),10)]);i.appendChild(s)}return s},t.prototype.wireEvents=function(){},t.prototype.unWireEvents=function(){},kc([I(5)],t.prototype,"interval",void 0),kc([I(100)],t.prototype,"segmentWidth",void 0),kc([I("Horizontal")],t.prototype,"orientation",void 0),kc([I("RightOrBottom")],t.prototype,"tickAlignment",void 0),kc([I("red")],t.prototype,"markerColor",void 0),kc([I(25)],t.prototype,"thickness",void 0),kc([I(null)],t.prototype,"arrangeTick",void 0),kc([I(400)],t.prototype,"length",void 0),t}(Ii);function eF(n,t){var e=document.getElementById(n.element.id+(t?"_hRuler":"_vRuler")),i=Za(n),r=tF(n);e||(e=Tt("div",{id:n.element.id+(t?"_hRuler":"_vRuler"),style:"height:"+(t?i.height:r.height+100)+"px;overflow:hidden;width:"+(t?r.width+100:i.width)+"px;position:absolute;font-size:11px;"+(t?"margin-left:"+i.width+"px;":"margin-top:"+i.height+"px;")})),n.element.insertBefore(e,n.element.firstChild);var l=t?n.rulerSettings.horizontalRuler:n.rulerSettings.verticalRuler,h=new Wne(l);h.orientation=t?"Horizontal":"Vertical",h.length=(t?r.width:r.height)+l.segmentWidth,h.appendTo("#"+n.element.id+(t?"_hRuler":"_vRuler")),t?n.hRuler=h:n.vRuler=h;var c=document.getElementById(n.element.id+(t?"_hRuler":"_vRuler"));t?n.hRuler.element=c:n.vRuler.element=c}function qI(n){var t=-n.scroller.horizontalOffset,e=-n.scroller.verticalOffset;n&&n.rulerSettings.showRulers?(n.hRuler.length=0,n.vRuler.length=0,void 0!==t&&n.hRuler.element&&iF(n,n.hRuler,t,!0),void 0!==e&&n.vRuler.element&&iF(n,n.vRuler,e,!1)):Qx(n)}function Qx(n){an(n.element.id+"_hRuler"),an(n.element.id+"_vRuler"),an(n.element.id+"_overlapRuler")}function Za(n){var t=0,e=0;return n.rulerSettings.showRulers&&(t=n.rulerSettings.horizontalRuler.thickness,e=n.rulerSettings.verticalRuler.thickness),new me(e,t)}function tF(n){var t=Za(n),e=n.scroller.viewPortHeight,i=n.scroller.viewPortWidth;return i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},rF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return $ne(t,n),t.prototype.getClassName=function(){return"UserHandle"},Un([I("")],t.prototype,"name",void 0),Un([I("")],t.prototype,"pathData",void 0),Un([I("")],t.prototype,"content",void 0),Un([I("")],t.prototype,"source",void 0),Un([I("#000000")],t.prototype,"backgroundColor",void 0),Un([I("Top")],t.prototype,"side",void 0),Un([I("")],t.prototype,"borderColor",void 0),Un([I(.5)],t.prototype,"borderWidth",void 0),Un([I(25)],t.prototype,"size",void 0),Un([I("white")],t.prototype,"pathColor",void 0),Un([I(10)],t.prototype,"displacement",void 0),Un([I(!0)],t.prototype,"visible",void 0),Un([I(0)],t.prototype,"offset",void 0),Un([re({},Jn)],t.prototype,"margin",void 0),Un([I("Center")],t.prototype,"horizontalAlignment",void 0),Un([I("Center")],t.prototype,"verticalAlignment",void 0),Un([I(!1)],t.prototype,"disableNodes",void 0),Un([I(!1)],t.prototype,"disableConnectors",void 0),Un([re({},Dd)],t.prototype,"tooltip",void 0),Un([I("")],t.prototype,"template",void 0),t}(Ee);function nF(n){return Zne[n.toString()]}var Zne={Action:"M 90 82.895 C 90 86.819 86.776 90 82.8 90 H 7.2 C 3.224 90 0 86.819 0 82.895 V 7.105 C 0 3.181 3.224 0 7.2 0 h 75.6 C 86.776 0 90 3.181 90 7.105 V 82.895 Z",Decision:"M10,19.707L0.293,10L10,0.293L19.707,10L10,19.707z",MergeNode:"M10,19.707L0.293,10L10,0.293L19.707,10L10,19.707z",InitialNode:"M10,19.5c-5.238,0-9.5-4.262-9.5-9.5S4.762,0.5,10,0.5s9.5,4.262,9.5,9.5S15.238,19.5,10,19.5z",ForkNode:"m0.75,0.75l636.00002,0l0,290l-636.00002,0l0,-290z",JoinNode:"m0.75,0.75l636.00002,0l0,290l-636.00002,0l0,-290z",TimeEvent:"M50.001,0.00286865 L25.001,25.0029 L0.000976562,0.00286865 L50.001,0.00286865 z M0.000976562,50.0029 L25.001,25.0029 L50.001,50.0029 L0.000976562,50.0029 z",AcceptingEvent:"M17.8336 32.164 L29.64 24 L17.32 16 L48.1664 16 L48.5 32 Z",SendSignal:"M48.164 31.8336 L56 23.832 L47.836 16 L16.168 16 L16.1668 31.8336 Z",ReceiveSignal:"M48.1664 31.8336 L39.836 24 L47.836 16 L16.168 16 L16.168 31.836 Z",StructuredNode:"M0,0 L50,0 L50,50 L0,50 z",Note:"M20 12 L4 12 L4 22 L22 22 L22 14 L20 14 L20 12 L22 14 Z"},$I=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Ja=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Jne=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return $I(t,n),Ja([I()],t.prototype,"key",void 0),Ja([I()],t.prototype,"keyModifiers",void 0),t}(Ee),sF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return $I(t,n),t.prototype.getClassName=function(){return"Command"},Ja([I("")],t.prototype,"name",void 0),Ja([I()],t.prototype,"canExecute",void 0),Ja([I()],t.prototype,"execute",void 0),Ja([re({},Jne)],t.prototype,"gesture",void 0),Ja([I("")],t.prototype,"parameter",void 0),t}(Ee),Kne=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return $I(t,n),Ja([Bt([],sF)],t.prototype,"commands",void 0),t}(Ee),ese=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return $I(t,n),Ja([I()],t.prototype,"show",void 0),Ja([I()],t.prototype,"showCustomMenuOnly",void 0),Ja([I()],t.prototype,"items",void 0),t}(Ee),$f=function(){function n(){}return n.prototype.renderShadow=function(t,e,i,r){void 0===i&&(i=null);var l,o=R.transform({x:0,y:0},t.shadow.angle,t.shadow.distance);r&&(l=r.getElementById(e.id+"_shadow")),l||(l=document.createElementNS("http://www.w3.org/2000/svg",i?"path":"rect"),e.appendChild(l));var h={id:e.id+"_shadow",fill:t.shadow.color,stroke:t.shadow.color,opacity:t.shadow.opacity.toString(),transform:"rotate("+t.angle+","+(t.x+t.width*t.pivotX)+","+(t.y+t.height*t.pivotY)+")translate("+(t.x+o.x)+","+(t.y+o.y)+")"};if(r){var c=r.getElementById(e.id);c&&c.insertBefore(l,c.firstChild)}ii(l,h),i?i&&this.renderPath(l,t,i):ii(l,{width:t.width,height:t.height})},n.prototype.parseDashArray=function(t){return[]},n.prototype.drawRectangle=function(t,e,i,r,s,o,a,l,h){var c,d,u,f;e.shadow&&!r&&this.renderShadow(e,t,void 0,o),c=e.id===t.id?e.id+"_container":e.id,o&&(d=o.getElementById(c)),(!d||s)&&(d=document.createElementNS("http://www.w3.org/2000/svg","rect"),t.appendChild(d)),o&&!e.shadow&&(u=o.getElementById(e.id+"_groupElement_shadow"))&&u.parentNode.removeChild(u),f=l?{id:c,x:e.x.toString(),y:e.y.toString(),width:e.width.toString(),height:e.height.toString(),visibility:e.visible?"visible":"hidden",transform:"rotate("+e.angle+","+(e.x+e.width/2)+","+(e.y+e.height/2)+")",rx:e.cornerRadius||0,ry:e.cornerRadius||0,opacity:e.opacity}:{id:c,x:e.x.toString(),y:e.y.toString(),width:e.width.toString(),height:e.height.toString(),visibility:e.visible?"visible":"hidden",transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")",rx:e.cornerRadius||0,ry:e.cornerRadius||0,opacity:e.opacity},a&&(f.role="img",f["aria-label"]=a);var p=e.class||"";h||(p.includes("e-diagram-resize-handle")||p.includes("e-diagram-endpoint-handle")||p.includes("e-diagram-bezier-control-handle"))&&(p+=" e-disabled"),e.class&&(f.class=p),a||(f["pointer-events"]="none"),ii(d,f),this.setSvgStyle(d,e,i)},n.prototype.updateSelectionRegion=function(t,e){var i;i=t.parentNode.getElementById(e.id);var r={id:e.id,x:e.x.toString(),y:e.y.toString(),width:e.width.toString(),height:e.height.toString(),transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")",class:"e-diagram-selected-region"};i||(i=document.createElementNS("http://www.w3.org/2000/svg","rect"),t.appendChild(i)),this.setSvgStyle(i,e),ii(i,r)},n.prototype.createGElement=function(t,e){return Fi(t,e)},n.prototype.drawLine=function(t,e){var i=document.createElementNS("http://www.w3.org/2000/svg","line");this.setSvgStyle(i,e);var r=e.x+e.width*e.pivotX,s=e.y+e.height*e.pivotY,o={id:e.id,x1:e.startPoint.x+e.x,y1:e.startPoint.y+e.y,x2:e.endPoint.x+e.x,y2:e.endPoint.y+e.y,stroke:e.stroke,"stroke-width":e.strokeWidth.toString(),opacity:e.opacity.toString(),transform:"rotate("+e.angle+" "+r+" "+s+")",visibility:e.visible?"visible":"hidden"};e.class&&(o.class=e.class),ii(i,o),t.appendChild(i)},n.prototype.drawCircle=function(t,e,i,r){var s=document.createElementNS("http://www.w3.org/2000/svg","circle");this.setSvgStyle(s,e);var o=e.class||"";i||(o+=" e-disabled");var a={id:e.id,cx:e.centerX,cy:e.centerY,r:e.radius,visibility:e.visible?"visible":"hidden",class:o};r&&(a.role="img",a["aria-label"]=r),s.style.display=e.visible?"block":"none",ii(s,a),t.appendChild(s)},n.prototype.drawPath=function(t,e,i,r,s,o,a){var h,c,l=[];l=XB(l=Ed(e.data)),e.shadow&&this.renderShadow(e,t,l,s),s&&!e.shadow&&(h=s.getElementById(e.id+"_groupElement_shadow"))&&h.parentNode.removeChild(h),s&&(c=s.getElementById(e.id)),(!c||r)&&(c=document.createElementNS("http://www.w3.org/2000/svg","path"),t.appendChild(c)),this.renderPath(c,e,l);var d={};d=a?{id:e.id,transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")translate("+e.x+","+e.y+"),scale("+a+")",visibility:e.visible?"visible":"hidden",opacity:e.opacity}:{id:e.id,transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")translate("+e.x+","+e.y+")",visibility:e.visible?"visible":"hidden",opacity:e.opacity},o&&(d.role="img",d["aria-label"]=o),e.class&&(d.class=e.class),ii(c,d),this.setSvgStyle(c,e,i)},n.prototype.renderPath=function(t,e,i){var r,s,o,a,l,h,c,d,u=i,f="";for(l=0,h=0,d=0,c=u.length;de.width&&"Wrap"!==e.textOverflow&&"NoWrap"===e.textWrapping&&(h[0].text=VF(e.content,e)),v=0;vD&&(u.text=u.text.slice(0,u.text.length-3),u.text=u.text.concat("..."),l.data=u.text),this.alignText(y,f,u,l,p,g,v,e,h),C+=u.dy}}C&&e.isHorizontalLane&&(M=e.parentOffsetX+e.pivotX,w=e.parentOffsetY+e.pivotY,e.y=e.parentOffsetY-C*e.pivotY+.5),e.textDecoration&&"LineThrough"===e.textDecoration&&(e.textDecoration=cb(e.textDecoration));var P={id:e.id+"_text",fill:e.color,visibility:e.visible?"visible":"hidden","text-decoration":e.textDecoration,transform:"rotate("+e.angle+","+M+","+w+")translate("+e.x+","+e.y+")",opacity:e.opacity};r&&(P.role="img",P["aria-label"]=r),ii(y,P)}},n.prototype.alignText=function(t,e,i,r,s,o,a,l,h){"justify"!==l.textAlign?this.setText(t,e,i,r,s,o,l):a!==h.length-1?this.setText(t,e,i,r,s,o,l,l.width,"spacing"):this.setText(t,e,i,r,s,o,l)},n.prototype.setText=function(t,e,i,r,s,o,a,l,h){ii(e,"justify"!==a.textAlign?{x:s.toString(),y:o.toString()}:{x:s.toString(),y:o.toString(),textLength:l||0,lengthAdjust:h||"spacing"}),t.setAttribute("fill",i.text),e.appendChild(r),t.appendChild(e)},n.prototype.drawImage=function(t,e,i,r){var s;i&&(s=i.getElementById(e.id+"image")),s||(s=document.createElementNS("http://www.w3.org/2000/svg","image"),t.appendChild(s));var o=new Image;o.src=e.source;var a="None"!==e.scale?e.scale:"",l=e.alignment,h=l.charAt(0).toLowerCase()+l.slice(1);"Stretch"!==a&&(h+=" "+a.charAt(0).toLowerCase()+a.slice(1)),ii(s,{id:e.id+"image",x:e.x.toString(),y:e.y.toString(),transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")",width:e.width.toString(),visibility:e.visible?"visible":"hidden",height:e.height.toString(),preserveAspectRatio:h,opacity:e.opacity.toString()}),s.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",o.src.toString())},n.prototype.drawHTMLContent=function(t,e,i,r,s){var o,a;if(e&&(o=e.querySelector("#"+t.id+"_html_element")),!o){(a=e.querySelector("#"+t.id+"_html_element")||e.querySelector("#"+t.nodeId+"_html_element"))||(a=Tt("div",{id:t.nodeId+"_html_element",class:"foreign-object"})),o=Tt("div",{id:t.id+"_html_element",class:"foreign-object"});var c=document.getElementById(t.diagramId).ej2_instances[0],d=!1;if(e.parentNode&&e.parentNode.parentNode&&e.parentNode.parentNode.parentNode&&e.parentNode.parentNode.parentNode.classList.contains("e-overview")&&(d=!0),d)c.isReact?c.renderReactTemplates(function(){o.appendChild(t.template.cloneNode(!0))}):o.appendChild(t.template.cloneNode(!0));else{if("string"==typeof t.template){var u=document.createElement("div");u.innerHTML=t.template,t.template=u,c.selectedItems.userHandles.filter(function(g){return g.name===t.id.split("_shape")[0]&&""!==g.template})[0].template=t.template}t.isTemplate&&t.template?o.appendChild(t.template):t.template&&o.appendChild(t.template.cloneNode(!0))}void 0!==s&&e.childNodes.length>s&&e.insertBefore(o,e.childNodes[parseInt(s.toString(),10)]),a.appendChild(o),e.appendChild(a)}var p=xn(t).topLeft;o.setAttribute("style","height:"+t.actualSize.height+"px; width:"+t.actualSize.width+"px;left:"+p.x+"px; top:"+p.y+"px;position:absolute;transform:rotate("+(t.rotateAngle+t.parentTransform)+"deg);pointer-events:"+(r?"all":"none")+";visibility:"+(t.visible?"visible":"hidden")+";opacity:"+t.style.opacity+";")},n.prototype.drawNativeContent=function(t,e,i,r,s){var o,a;if(s&&(o=s.getElementById(t.id+"_native_element"),a=s.getElementById(t.id+"_clip")),!o){(o=document.createElementNS("http://www.w3.org/2000/svg","g")).setAttribute("id",t.id+"_native_element"),o.appendChild(t.template.cloneNode(!0));var l=this.createGElement("g",{id:t.id+"_inner_native_element"});l.appendChild(o),e.appendChild(l)}a&&o.removeChild(a),o.setAttribute("style","visibility:"+(t.visible?"visible":"hidden")+";opacity:"+t.style.opacity+";"),this.setNativTransform(t,o,i,r),"Slice"===t.scale&&this.drawClipPath(t,o,i,r,s),ii(o,t.description?{role:"img","aria-label":t.description}:{})},n.prototype.setNativTransform=function(t,e,i,r){var s=0!==t.contentSize.width?t.contentSize.width:1,o=0!==t.contentSize.height?t.contentSize.height:1;e.setAttribute("transform","rotate("+t.parentTransform+","+t.offsetX+","+t.offsetY+") translate("+(t.offsetX-t.templatePosition.x*r/s-r*t.pivot.x)+","+(t.offsetY-t.templatePosition.y*i/o-i*t.pivot.y)+") scale("+r/s+","+i/o+")")},n.prototype.drawClipPath=function(t,e,i,r,s){var o=t.contentSize.width,a=t.contentSize.height,l=t.width/(r/o),h=t.height/(i/a),c=t.templatePosition.x+(t.width>=t.height?0:(o-l)/2),d=t.templatePosition.y+(t.height>=t.width?0:(a-h)/2),u=s.getElementById(t.id+"_clip");(u=document.createElementNS("http://www.w3.org/2000/svg","clipPath")).setAttribute("id",t.id+"_clip"),e.appendChild(u);var f=s.getElementById(t.id+"_clip_rect");return f=document.createElementNS("http://www.w3.org/2000/svg","rect"),u.appendChild(f),ii(f,{id:t.id+"_clip_rect",width:l.toString(),height:h.toString(),x:c.toString(),y:d.toString()}),sm()?e.setAttribute("clip-path","url("+location.protocol+"//"+location.host+location.pathname+"#"+t.id+"_clip)"):e.setAttribute("clip-path","url(#"+t.id+"_clip)"),e},n.prototype.renderGradient=function(t,e,i){var r,s,o,h,c,a=mT(i),l=a.getElementById(i+"gradient_pattern");if(l||(l=Fi("defs",{id:i+"gradient_pattern"}),a.insertBefore(l,a.firstChild)),gF(e.id),"None"!==t.gradient.type){for(var d=0;dt.width&&("Ellipsis"===t.textOverflow||"Clip"===t.textOverflow)&&"NoWrap"===t.textWrapping?0:.5*t.width:"right"===t.textAlign&&(c=1*t.width),s.x=0+c+(e?e.x:0),s.y=1.2+d-r.height/2,s},n}(),Pc=function(){function n(t,e,i){this.renderer=null,this.isSvgMode=!0,this.touchMove=void 0,this.transform={x:0,y:0},this.diagramId=t,this.element=xt(this.diagramId),this.svgRenderer=e,this.isSvgMode=i,this.renderer=i?new $f:new bo}return n.prototype.setCursor=function(t,e){t.style.cursor=e},n.prototype.setLayers=function(){this.iconSvgLayer=this.element.getElementsByClassName("e-ports-expand-layer")[0],this.adornerSvgLayer=this.element.getElementsByClassName("e-adorner-layer")[0],this.nativeSvgLayer=this.element.getElementsByClassName("e-native-layer")[0],this.diagramSvgLayer=this.element.getElementsByClassName("e-diagram-layer")[0]},n.prototype.getAdornerLayer=function(){return gT(this.diagramId)},n.prototype.getParentSvg=function(t,e,i){return this.diagramId&&t&&t.id?t.id.split("_icon_content").length>1||t.id.split("_nodeport").length>1||t.elementActions&Xr.ElementIsPort?this.iconSvgLayer:e&&"selector"===e?this.adornerSvgLayer:t instanceof En?this.nativeSvgLayer:this.diagramSvgLayer:i},n.prototype.getParentElement=function(t,e,i,r){var s=e;if(i&&this.diagramId&&t&&t.id){t.id.split("_icon_content").length>1?(s=i.getElementById(this.diagramId+"_diagramExpander"),e=null):t.id.split("_nodeport").length>1?s=i.getElementById(this.diagramId+"_diagramPorts"):t instanceof En?(s=i.getElementById(this.diagramId+"_nativeLayer"),e=null):t.elementActions&Xr.ElementIsPort?(s=i.getElementById(this.diagramId+"_diagramPorts"),e=null):s=i.getElementById(this.diagramId+"_diagramLayer");var o=this.getGroupElement(t,e||s,r);s=o.g,o.svg&&(i=o.svg)}return{g:s,svg:i}},n.prototype.getGroupElement=function(t,e,i){var r,o,s=this.getParentSvg(t);if(e&&s){if(s&&!(r=s.getElementById(t.id+"_groupElement"))&&s!==this.nativeSvgLayer){var a=this.nativeSvgLayer;r=a.getElementById(t.id+"_groupElement"),o=a}r||(r=this.svgRenderer.createGElement("g",{id:t.id+"_groupElement"}),void 0!==i&&e.childNodes.length>i?e.insertBefore(r,e.childNodes[parseInt(i.toString(),10)]):e.appendChild(r))}return{g:r,svg:o}},n.prototype.renderElement=function(t,e,i,r,s,o,a,l,h,c,d){t instanceof Cs?(t.id=t.id?t.id:Qe(),this.renderContainer(t,e,i,r,s,o,a,l,h,c,d)):t instanceof bI?this.renderImageElement(t,e,r,s,a):t instanceof Ze?this.renderPathElement(t,e,r,s,a,h,d):t instanceof li?this.renderTextElement(t,e,r,s,a,c):t instanceof En?this.renderNativeElement(t,e,r,s,a):t instanceof es?this.renderHTMLElement(t,e,i,r,s,a,l):this.renderRect(t,e,r,s,h)},n.prototype.drawSelectionRectangle=function(t,e,i,r,s,o){var a={width:i*o.scale,height:r*o.scale,x:.5+(t=(t+o.tx)*o.scale),y:.5+(e=(e+o.ty)*o.scale),fill:"transparent",stroke:"gray",angle:0,pivotX:.5,pivotY:.5,strokeWidth:1,dashArray:"6 3",opacity:1,visible:!0,id:s.id+"_selected_region"},l=this.getAdornerLayer();this.svgRenderer.updateSelectionRegion(l,a)},n.prototype.renderHighlighter=function(t,e,i){var r=t.actualSize.width||2,s=t.actualSize.height||2,o=t.offsetX-r*t.pivot.x,a=t.offsetY-s*t.pivot.y;this.svgRenderer.drawRectangle(e,{width:r*i.scale,height:s*i.scale,x:o=(o+i.tx)*i.scale,y:a=(a+i.ty)*i.scale,fill:"transparent",stroke:"#8CC63F",angle:t.rotateAngle,pivotX:t.pivot.x,pivotY:t.pivot.y,strokeWidth:4,dashArray:"",opacity:1,cornerRadius:0,visible:!0,id:e.id+"_highlighter",class:"e-diagram-highlighter"},this.diagramId,void 0,void 0,e)},n.prototype.renderSelectionRectangle=function(t,e,i,r){var s=t.actualSize.width||2,o=t.actualSize.height||2,a=t.offsetX-s*t.pivot.x,l=t.offsetY-o*t.pivot.y,h={width:s*i.scale,height:o*i.scale,x:a=(a+i.tx)*i.scale,y:l=(l+i.ty)*i.scale,fill:"transparent",stroke:"#00cc00",angle:t.rotateAngle,pivotX:t.pivot.x,pivotY:t.pivot.y,strokeWidth:r?2:1,dashArray:"",opacity:1,cornerRadius:0,visible:!0,id:t.id+"_highlighter",class:r?"e-diagram-first-selection-indicator e-diagram-selection-indicator":"e-diagram-selection-indicator"},c=this.getParentSvg(t,"selector");this.svgRenderer.drawRectangle(e,h,this.diagramId,void 0,void 0,c)},n.prototype.renderSelectionLine=function(t,e,i,r){var s=this.getBaseAttributes(t,i);s.data=t.absolutePath,s.id=s.id+"_highlighter";var o=t.description?t.description:t.id;this.isSvgMode||(s.x=t.flipOffset.x?t.flipOffset.x:s.x,s.y=t.flipOffset.y?t.flipOffset.y:s.y),i&&(s.x=s.x*i.scale,s.y=s.y*i.scale),s.stroke="#00cc00",s.strokeWidth=r?2:1,s.class=r?"e-diagram-first-selection-indicator e-diagram-selection-indicator":"e-diagram-selection-indicator";var a=this.getParentSvg(t,"selector");this.svgRenderer.drawPath(e,s,this.diagramId,void 0,a,o,i.scale)},n.prototype.renderStackHighlighter=function(t,e,i,r,s,o,a){var l=t.actualSize.width||2,h=t.offsetX-l*t.pivot.x,c=t.actualSize.height||2,d=t.offsetY-c*t.pivot.y;h=(h+i.tx)*i.scale;var u,f=t.bounds,p="";if(d=(d+i.ty)*i.scale,r)if(o){var v,y;u="M 0 0 L "+(2+(g=l*i.scale))+" 0 Z",v=t.actualSize.width/Number(f.width?f.width:1)*i.scale,y=t.actualSize.height/Number(f.height?f.height:1)*i.scale,p=vI(mI(Ed("M7,4 L8,4 8,7 11,7 11,8 8,8 8,11 7,11 7,8 4,8 4,7 7,7 z M7.5,0.99999994C3.9160004,1 1,3.9160004 0.99999994,7.5 1,11.084 3.9160004,14 7.5,14 11.084,14 14,11.084 14,7.5 14,3.9160004 11.084,1 7.5,0.99999994 z M7.5,0 C11.636002,0 15,3.3639984 15,7.5 15,11.636002 11.636002,15 7.5,15 3.3640003,15 0,11.636002 0,7.5 0,3.3639984 3.3640003,0 7.5,0 z")),v+g+2,y-8,!1,f.x,f.y,0,0),s.y>=t.offsetY&&(d+=c)}else{var g;a&&s.y>=t.offsetY&&(d+=c*i.scale),u="M -10 -10 L 0 0 Z M -10 10 L 0 0 Z M 0 0 L "+(g=l*i.scale)+" 0 Z M "+g+" 0 L "+(g+10)+" 10 Z L "+(g+10)+" -10 Z"}else u="M 10 -10 L 0 0 Z M -10 -10 L 0 0 Z M 0 0 L 0 "+(g=c*i.scale)+" Z M 0 "+g+" L -10 "+(g+10)+" Z L 10 "+(g+10)+" Z",s.x>=t.offsetX&&(h+=l*i.scale);this.svgRenderer.drawPath(e,{data:u+p,width:l*i.scale,height:c*i.scale,x:h,y:d,fill:"transparent",stroke:"#8CC63F",angle:t.rotateAngle,pivotX:t.pivot.x,pivotY:t.pivot.y,strokeWidth:1,dashArray:"",opacity:1,visible:!0,id:e.id+"_stack_highlighter",class:"e-diagram-highlighter"},this.diagramId)},n.prototype.drawLine=function(t,e){this.svgRenderer.drawLine(t,e)},n.prototype.drawPath=function(t,e){this.svgRenderer.drawPath(t,e,this.diagramId)},n.prototype.renderResizeHandle=function(t,e,i,r,s,o,a,l,h,c,d){var u=t.offsetX-t.actualSize.width*t.pivot.x,f=t.offsetY-t.actualSize.height*t.pivot.y,p=t.actualSize.height,g=t.actualSize.width;if(!c&&i&bt.Rotate&&HI(this.rendererActions)&&!A3(this.rendererActions))this.renderPivotLine(t,e,o,s,a),this.renderRotateThumb(t,e,o,s,a);else if(this.touchMove){var v=document.getElementById("rotateThumb");v&&v.setAttribute("visibility","hidden")}this.renderBorder(t,e,o,l,h,c);var y=t.actualSize.width*r,S=t.actualSize.height*r;!h&&HI(this.rendererActions)&&!A3(this.rendererActions)&&(t.isTextAnnotation||(y>=40&&S>=40&&(s&mr.ResizeNorthWest&&this.renderCircularHandle("resizeNorthWest",t,u,f,e,qr(s,"ResizeNorthWest"),i&bt.ResizeNorthWest,o,void 0,a,{"aria-label":"Thumb to resize the selected object on top left side direction"},void 0,"e-diagram-resize-handle e-northwest",d),s&mr.ResizeNorthEast&&this.renderCircularHandle("resizeNorthEast",t,u+g,f,e,qr(s,"ResizeNorthEast"),i&bt.ResizeNorthEast,o,void 0,a,{"aria-label":"Thumb to resize the selected object on top right side direction"},void 0,"e-diagram-resize-handle e-northeast",d),s&mr.ResizeSouthWest&&this.renderCircularHandle("resizeSouthWest",t,u,f+p,e,qr(s,"ResizeSouthWest"),i&bt.ResizeSouthWest,o,void 0,a,{"aria-label":"Thumb to resize the selected object on bottom left side direction"},void 0,"e-diagram-resize-handle e-southwest",d),s&mr.ResizeSouthEast&&this.renderCircularHandle("resizeSouthEast",t,u+g,f+p,e,qr(s,"ResizeSouthEast"),i&bt.ResizeSouthEast,o,void 0,a,{"aria-label":"Thumb to resize the selected object on bottom right side direction"},void 0,"e-diagram-resize-handle e-southeast",d)),s&mr.ResizeNorth&&this.renderCircularHandle("resizeNorth",t,u+g/2,f,e,qr(s,"ResizeNorth"),i&bt.ResizeNorth,o,void 0,a,{"aria-label":"Thumb to resize the selected object on top side direction"},void 0,"e-diagram-resize-handle e-north",d),s&mr.ResizeSouth&&this.renderCircularHandle("resizeSouth",t,u+g/2,f+p,e,qr(s,"ResizeSouth"),i&bt.ResizeSouth,o,void 0,a,{"aria-label":"Thumb to resize the selected object on bottom side direction"},void 0,"e-diagram-resize-handle e-south",d),s&mr.ResizeWest&&this.renderCircularHandle("resizeWest",t,u,f+p/2,e,qr(s,"ResizeWest"),i&bt.ResizeWest,o,void 0,a,{"aria-label":"Thumb to resize the selected object on left side direction"},void 0,"e-diagram-resize-handle e-west",d),s&mr.ResizeEast&&this.renderCircularHandle("resizeEast",t,u+g,f+p/2,e,qr(s,"ResizeEast"),i&bt.ResizeEast,o,void 0,a,{"aria-label":"Thumb to resize the selected object on right side direction"},void 0,"e-diagram-resize-handle e-east",d)))},n.prototype.renderEndPointHandle=function(t,e,i,r,s,o,a,l,h,c){var p,g,d=t.sourcePoint,u=t.targetPoint,f=t.wrapper;if(this.renderCircularHandle("connectorSourceThumb",f,d.x,d.y,e,qr(r,"ConnectorSourceThumb"),i&bt.ConnectorSource,s,o,void 0,{"aria-label":"Thumb to move the source point of the connector"},void 0,"e-diagram-endpoint-handle e-sourceend",c),this.renderCircularHandle("connectorTargetThumb",f,u.x,u.y,e,qr(r,"ConnectorTargetThumb"),i&bt.ConnectorTarget,s,a,void 0,{"aria-label":"Thumb to move the target point of the connector"},void 0,"e-diagram-endpoint-handle e-targetend",c),l)if("Straight"===t.type&&t.segments.length>0)for(p=0;p0)for(p=0;p=3&&3===t.segments.length&&(S=1,b=t.segments.length-1),S=t.segments.length>t.maxSegmentThumb+2?2:S,b=t.segments.length>t.maxSegmentThumb+2?t.segments.length-2:b,1===t.segments.length&&t.segments[0].points.length<=2&&(S=1,b=t.segments.length),p=S;p=50&&i.allowDrag),this.renderOrthogonalThumb(t+"_"+(d+1),e,(i.points[parseInt(d.toString(),10)].x+i.points[d+1].x)/2,(i.points[parseInt(d.toString(),10)].y+i.points[d+1].y)/2,r,h,l,o,a,u)}else for(d=0;d=50&&i.allowDrag),this.renderOrthogonalThumb(t+"_"+(d+1),e,(i.points[parseInt(d.toString(),10)].x+i.points[d+1].x)/2,(i.points[parseInt(d.toString(),10)].y+i.points[d+1].y)/2,r,h,l,o,a,u)},n.prototype.renderOrthogonalThumb=function(t,e,i,r,s,o,a,l,h,c){var d,g,u=0,f=document.getElementById(this.diagramId);f&&(g=f.ej2_instances[0]);var y=h.constraints&qe.InheritSegmentThumbShape?g.segmentThumbShape:h.segmentThumbShape,b=h.constraints&qe.InheritSegmentThumbSize?g.segmentThumbSize:h.segmentThumbSize;if(d="horizontal"===a?function tre(n){return sre[""+n]}(y):n3(y),"Arrow"===y||"DoubleArrow"===y||"OpenArrow"===y)switch(c){case"Bottom":case"Right":u=180;break;default:u=0}else if("Fletch"===y||"OpenFetch"===y||"IndentedArrow"===y||"OutdentedArrow"===y)switch(c){case"Bottom":u=-90;break;case"Top":u=90;break;case"Right":u=180;break;default:u=0}var M={x:(i+l.tx)*l.scale-b/2,y:(r+l.ty)*l.scale-b/2,angle:u,fill:"#e2e2e2",stroke:"black",strokeWidth:1,dashArray:"",data:d,width:b,height:b,pivotX:.5,pivotY:.5,opacity:1,visible:o,id:t,class:"e-diagram-ortho-segment-handle"},w=np(M.data),C=new me(M.width,M.height),D=new Ze;if(M.data=D.updatePath(M.data,w,C),this.touchMove){var A=document.getElementById(t);A?this.updateSegmentPosition(A,M):this.svgRenderer.drawPath(s,M,this.diagramId)}else this.svgRenderer.drawPath(s,M,this.diagramId)},n.prototype.renderPivotLine=function(t,e,i,r,s){var o=t,l=!!(r&mr.Rotate);s&&(l=!1);var h=this.getBaseAttributes(o,i);h.fill="None",h.stroke="black",h.strokeWidth=1,h.dashArray="2,3",h.visible=l;var c=i.scale;h.x*=c,h.y*=c,h.width*=c,h.height*=c,h.id="pivotLine",h.class="e-diagram-pivot-line";var u={x:o.actualSize.width*o.pivot.x*c,y:0};h.startPoint={x:o.actualSize.width*o.pivot.x*c,y:-20},h.endPoint=u,this.svgRenderer.drawLine(e,h)},n.prototype.renderBezierLine=function(t,e,i,r,s,o){var l=this.getBaseAttributes(e,o);l.id=t,l.stroke="black",l.strokeWidth=1,l.dashArray="3,3",l.fill="None",l.class="e-diagram-bezier-control-line",l.x=0,l.y=0;var h=o.scale,g={x:(s.x+o.tx)*h,y:(s.y+o.ty)*h};l.startPoint={x:(r.x+o.tx)*h,y:(r.y+o.ty)*h},l.endPoint=g,this.svgRenderer.drawLine(i,l)},n.prototype.renderCircularHandle=function(t,e,i,r,s,o,a,l,h,c,d,u,f,p){var g=e,v={x:i,y:r};if(0!==g.rotateAngle||0!==g.parentTransform){var y=Bi();qi(y,g.rotateAngle+g.parentTransform,g.offsetX,g.offsetY),v=Ke(y,v)}var S=this.getBaseAttributes(g);if(S.stroke="black",S.strokeWidth=1,void 0!==u?(S.id="segmentEnd_"+u,S.fill="#e2e2e2"):S.fill=h?"#8CC63F":"white",S.cornerRadius=p/2,S.angle=e.rotateAngle,S.id=t,S.visible=o,S.class=f,S.width=p,S.height=p,S.x=(v.x+l.tx)*l.scale,S.y=(v.y+l.ty)*l.scale,S.x=S.x-S.width/2,S.y=S.y-S.height/2,h&&(S.class+=" e-connected"),c&&(S.visible=!1),this.touchMove){var b=document.getElementById(t);if(b)this.updateResizeHandle(b,S);else{var M=this.getParentSvg(e,"selector");this.svgRenderer.drawRectangle(s,S,this.diagramId,!0,!0,M,d,!0,a)}}else M=this.getParentSvg(e,"selector"),this.svgRenderer.drawRectangle(s,S,this.diagramId,!0,!0,M,d,!0,a)},n.prototype.updateResizeHandle=function(t,e){ii(t,{id:e.id,x:e.x.toString(),y:e.y.toString(),width:e.width.toString(),height:e.height.toString(),visibility:e.visible?"visible":"hidden",transform:"rotate("+e.angle+","+(e.x+e.width/2)+","+(e.y+e.height/2)+")",rx:e.cornerRadius||0,ry:e.cornerRadius||0,opacity:e.opacity})},n.prototype.renderBezierHandle=function(t,e,i,r,s,o,a,l,h,c,d,u,f){var v,p=document.getElementById(this.diagramId);p&&(v=p.ej2_instances[0]);var y=e,S={x:i,y:r};if(0!==y.rotateAngle||0!==y.parentTransform){var b=Bi();qi(b,y.rotateAngle+y.parentTransform,y.offsetX,y.offsetY),S=Ke(b,S)}var D=a.constraints&qe.InheritSegmentThumbSize?v.segmentThumbSize:a.segmentThumbSize,A=n3(a.constraints&qe.InheritSegmentThumbShape?v.segmentThumbShape:a.segmentThumbShape),x=this.getBaseAttributes(y);x.stroke="black",x.strokeWidth=1,void 0!==d?(x.id="segmentEnd_"+d,x.fill="#e2e2e2"):x.fill=h?"#8CC63F":"white",x.angle=e.rotateAngle,x.id=t,x.visible=o,x.class=u,x.width=D,x.height=D,x.data=A,x.x=(S.x+l.tx)*l.scale,x.y=(S.y+l.ty)*l.scale,x.x=x.x-x.width/2,x.y=x.y-x.height/2,h&&(x.class+=" e-connected"),c&&(x.visible=!1);var P=np(x.data),L=new me(x.width,x.height),O=new Ze;if(x.data=O.updatePath(x.data,P,L),this.touchMove){var N=document.getElementById(t);if(N)this.updateSegmentPosition(N,x);else{var T=this.getParentSvg(e,"selector");this.svgRenderer.drawPath(s,x,this.diagramId,!0,T)}}else T=this.getParentSvg(e,"selector"),this.svgRenderer.drawPath(s,x,this.diagramId,!0,T)},n.prototype.updateSegmentPosition=function(t,e){ii(t,{id:e.id,transform:"rotate("+e.angle+","+(e.x+e.width*e.pivotX)+","+(e.y+e.height*e.pivotY)+")translate("+e.x+","+e.y+")",visibility:e.visible?"visible":"hidden",opacity:e.opacity})},n.prototype.renderBorder=function(t,e,i,r,s,o){var l=this.getBaseAttributes(t,i);l.x*=i.scale,l.y*=i.scale,l.width*=i.scale,l.height*=i.scale,l.fill="transparent",l.stroke="#097F7F",l.strokeWidth=1.2,l.gradient=null,l.dashArray="6,3",l.class="e-diagram-selector",o&&(l.class+=" e-diagram-lane"),l.id="borderRect",l.id=this.rendererActions&Ga.DrawSelectorBorder?"borderRect_symbol":"borderRect",r||(l.class+=" e-disabled"),s&&(l.class+=" e-thick-border"),l.cornerRadius=0;var h=this.getParentSvg(t,"selector");this.svgRenderer.drawRectangle(e,l,this.diagramId,void 0,!0,h)},n.prototype.renderUserHandler=function(t,e,i,r,s,o){for(var l,a=t.wrapper,h=0,c=t.userHandles;h0||d.disableNodes&&t.nodes.length>0||"Drag"===s&&o)&&(l=!1);var u=document.getElementById(d.name+"_template_hiddenUserHandle");u&&(d.template=u.childNodes[0].cloneNode(!0));var f=Kx(t,d,i);if(f.x=(f.x+i.tx)*i.scale,f.y=(f.y+i.ty)*i.scale,d.visible&&(d.visible=!!(t.constraints&mr.UserHandle)),l)if(d.pathData){var p=d.pathData?d.pathData:d.content,g=this.getBaseAttributes(a);g.id=d.name+"_userhandle",g.fill=d.backgroundColor,g.stroke=d.borderColor,g.strokeWidth=d.borderWidth,g.centerX=f.x,g.centerY=f.y,g.radius=.5*d.size,g.class="e-diagram-userhandle-circle",g.angle=0,g.visible=d.visible,g.opacity=1,this.svgRenderer.drawCircle(e,g,1,{"aria-label":d.name+"user handle"});var y=[];y=mI(y=Ed(p));var S=np(p),w=vI(y,(d.size-.45*d.size)/S.width,(d.size-.45*d.size)/S.height,!0,S.x,S.y,0,0);S=np(w),this.svgRenderer.drawPath(e,C={x:f.x-S.width/2,y:f.y-S.height/2,angle:0,id:"",class:"e-diagram-userhandle-path",fill:d.pathColor,stroke:d.backgroundColor,strokeWidth:.5,dashArray:"",data:w,width:d.size-5,height:d.size-5,pivotX:0,pivotY:0,opacity:1,visible:d.visible},this.diagramId,void 0,void 0,{"aria-label":d.name+"user handle"})}else if(d.content){var D=new En(d.name,this.diagramId);D.content=d.content,D.offsetX=f.x,D.offsetY=f.y,D.id=d.name+"_shape",D.horizontalAlignment="Center",D.verticalAlignment="Center",D.visible=d.visible,D.setOffsetWithRespectToBounds(f.x,f.y,"Fraction"),D.relativeMode="Object",D.description=d.name||"User handle",D.measure(new me(d.size,d.size)),D.arrange(D.desiredSize),this.svgRenderer.drawNativeContent(D,e,d.size,d.size,this.adornerSvgLayer)}else if(d.source){var C,A=new bI;(C=this.getBaseAttributes(A,i)).width=d.size,C.height=d.size,C.x=f.x-d.size/2,C.y=f.y-d.size/2,C.sourceWidth=d.size,C.sourceHeight=d.size,C.alignment=A.imageAlign,C.source=d.source,C.scale=A.imageScale,C.visible=d.visible,C.description=d.name||"User handle",C.id=d.name+"_",this.renderer.drawImage(e,C,this.adornerSvgLayer,!1)}else{var x=new es(d.name,this.diagramId);x.offsetX=f.x,x.offsetY=f.y,x.id=d.name+"_shape",x.visible=d.visible,x.relativeMode="Object",x.template=d.template,x.measure(new me(d.size,d.size)),x.arrange(x.desiredSize),this.svgRenderer.drawHTMLContent(x,r,void 0,!0,void 0)}}},n.prototype.renderRotateThumb=function(t,e,i,r,s){new Ze;var a,l=new me;l.width=18,l.height=16;var d=!!(r&mr.Rotate);s&&(d=!1);var f=t.offsetX-t.actualSize.width*t.pivot.x+t.pivot.x*t.actualSize.width,p=t.offsetY-t.actualSize.height*t.pivot.y;if(a={x:(f=(f+i.tx)*i.scale)-.5*l.width,y:(p=(p+i.ty)*i.scale)-30-.5*l.height},0!==t.rotateAngle||0!==t.parentTransform){var g=Bi();qi(g,t.rotateAngle+t.parentTransform,(i.tx+t.offsetX)*i.scale,(i.ty+t.offsetY)*i.scale),a=Ke(g,a)}var v={x:a.x,y:a.y,angle:t.rotateAngle+t.parentTransform,fill:"#231f20",stroke:"black",strokeWidth:.5,dashArray:"",data:"M 16.856144362449648 10.238890446662904 L 18.000144362449646 3.437890446662903L 15.811144362449646 4.254890446662903 C 14.837144362449646 2.5608904466629028 13.329144362449647 1.2598904466629026 11.485144362449645 0.5588904466629026 C 9.375144362449646 - 0.24510955333709716 7.071144362449646 - 0.18010955333709716 5.010144362449646 0.7438904466629028 C 2.942144362449646 1.6678904466629028 1.365144362449646 3.341890446662903 0.558144362449646 5.452890446662903 C - 0.244855637550354 7.567890446662903 - 0.17985563755035394 9.866890446662904 0.7431443624496461 11.930890446662904 C 1.6681443624496461 13.994890446662904 3.343144362449646 15.575890446662903 5.457144362449647 16.380890446662903 C 6.426144362449647 16.7518904466629 7.450144362449647 16.9348904466629 8.470144362449647 16.9348904466629 C 9.815144362449647 16.9348904466629 11.155144362449647 16.6178904466629 12.367144362449647 15.986890446662901 L 11.351144362449647 14.024890446662901 C 9.767144362449647 14.8468904466629 7.906144362449647 14.953890446662902 6.237144362449647 14.3178904466629 C 4.677144362449647 13.7218904466629 3.444144362449647 12.5558904466629 2.758144362449647 11.028890446662901 C 2.078144362449646 9.501890446662903 2.031144362449646 7.802890446662903 2.622144362449646 6.243890446662903 C 3.216144362449646 4.6798904466629025 4.387144362449646 3.442890446662903 5.914144362449646 2.760890446662903 C 7.437144362449646 2.078890446662903 9.137144362449646 2.0298904466629026 10.700144362449645 2.6258904466629027 C 11.946144362449646 3.100890446662903 12.971144362449646 3.9538904466629026 13.686144362449646 5.049890446662903 L 11.540144362449645 5.850890446662903 L 16.856144362449648 10.238890446662904 Z",width:20,height:20,pivotX:0,pivotY:0,opacity:1,visible:d,id:"rotateThumb",class:"e-diagram-rotate-handle"};if(this.touchMove){var y=document.getElementById("rotateThumb");y?this.updateSegmentPosition(y,v):this.svgRenderer.drawPath(e,v,this.diagramId,!0,void 0,{"aria-label":"Thumb to rotate the selected object"})}else this.svgRenderer.drawPath(e,v,this.diagramId,!0,void 0,{"aria-label":"Thumb to rotate the selected object"})},n.prototype.renderPathElement=function(t,e,i,r,s,o,a){var l=this.getBaseAttributes(t,i,o);if(l.data=t.absolutePath,l.data=t.absolutePath,t.isPathPort&&a){l.x=a[t.id]?a[t.id].cx:l.x,l.y=a[t.id]?a[t.id].cy:l.y,t.bounds.x=l.x,t.bounds.y=l.y;var h=document.getElementById(this.diagramId);h&&"PortDrag"!==h.ej2_instances[0].eventHandler.currentAction&&(t.offsetX=l.x+t.width/2,t.offsetY=l.y+t.height/2)}var u=t.description?t.description:t.id;if(this.isSvgMode||(l.x=t.flipOffset.x?t.flipOffset.x:l.x,l.y=t.flipOffset.y?t.flipOffset.y:l.y),t.isExport){var f=t.absoluteBounds,p=Ed(l.data),g=this.findAndStoreArcValues(p);l.arc=g,l.data=OF(t,f,0,l)}this.renderer.drawPath(e,l,this.diagramId,void 0,r,u)},n.prototype.findAndStoreArcValues=function(t){var e=[];return t.forEach(function(i){"A"===i.command&&e.push({r1:i.r1/2,r2:i.r2/2})}),e},n.prototype.renderSvgGridlines=function(t,e,i,r,s,o){var a=document.createElementNS("http://www.w3.org/2000/svg","pattern"),l=document.createElementNS("http://www.w3.org/2000/svg","defs");l.setAttribute("id",this.diagramId+"_grid_pattern_defn"),(t.constraints&ei.ShowHorizontalLines||t.constraints&ei.ShowVerticalLines)&&a.setAttribute("id",this.diagramId+"_pattern");var h=0,c=0,d=0,u=0,f=1,p=!1,g="Lines"===t.gridType,v=g?t.verticalGridlines.lineIntervals:t.verticalGridlines.dotIntervals,y=g?t.horizontalGridlines.lineIntervals:t.horizontalGridlines.dotIntervals;if(r.showRulers&&r.dynamicGrid&&s&&o)d=o.updateSegmentWidth(i.scale),u=s.updateSegmentWidth(i.scale),t.horizontalGridlines.scaledIntervals=[d/s.interval],t.verticalGridlines.scaledIntervals=[u/o.interval],p=!0;else{for(var S=0;S=2)for(;e>=2;)e/=2;else if(e<=.5)for(;e<=.5;)e*=2;var i;if(t.horizontalGridlines.scaledIntervals=t.horizontalGridlines.snapIntervals,t.verticalGridlines.scaledIntervals=t.verticalGridlines.snapIntervals,1!==e){var r=t.horizontalGridlines;for(r.scaledIntervals=[],i=0;ithis.groupElement.actualSize.height&&("Clip"===t.style.textOverflow||"Ellipsis"===t.style.textOverflow)&&(a.y=a.y+(a.height-this.groupElement.actualSize.height)/2),this.renderer.drawRectangle(e,a,this.diagramId,void 0,void 0,r),this.renderer.drawText(e,a,r,l,this.diagramId,t.isExport&&Math.min(t.exportScaleValue.x||t.exportScaleValue.y),this.groupElement),this.isSvgMode&&(t.doWrap=!1)},n.prototype.renderNativeElement=function(t,e,i,r,s){var o,a,l=this.getParentSvg(t,void 0,e)||r,h=this.getParentElement(t,e,l).g||e,c=this.getBaseAttributes(t,i);switch(c.fill="transparent",c.cornerRadius=t.cornerRadius,c.stroke="transparent",this.renderer.drawRectangle(e,c,this.diagramId,void 0,void 0,r),t.scale){case"None":o=t.contentSize.width,a=t.contentSize.height;break;case"Stretch":o=t.actualSize.width,a=t.actualSize.height;break;case"Meet":o=a=t.actualSize.width<=t.actualSize.height?t.actualSize.width:t.actualSize.height;break;case"Slice":o=a=t.actualSize.width>=t.actualSize.height?t.actualSize.width:t.actualSize.height}this.svgRenderer&&this.svgRenderer.drawNativeContent(t,h,a,o,l)},n.prototype.renderHTMLElement=function(t,e,i,r,s,o,a){var l=this.getBaseAttributes(t,r);l.fill="transparent",l.cornerRadius=t.cornerRadius,l.stroke="transparent",this.renderer.drawRectangle(e,l,this.diagramId,void 0,void 0,s),this.svgRenderer&&this.svgRenderer.drawHTMLContent(t,i.children[0],r,function lse(n){var t=n.parentElement;do{if(um(t,"e-diagram"))return!0;t=t.parentElement}while(t);return!1}(i),a)},n.prototype.renderImageElement=function(t,e,i,r,s){var o=this.getBaseAttributes(t,i);o.cornerRadius=0,this.renderer.drawRectangle(e,o,this.diagramId,void 0,void 0,r);var a,l,h,c,g,d=t.contentSize.width,u=t.contentSize.height,f=o.width/d,p=o.height/u;if("Stretch"===t.stretch)a=d*(g=Math.min(f,p)),l=u*g;else switch(t.stretch){case"Meet":a=d*(g=Math.min(f,p)),l=u*g,o.x+=Math.abs(o.width-a)/2,o.y+=Math.abs(o.height-l)/2;break;case"Slice":g=Math.max(f,p),h=o.width/(a=d*g)*d,c=o.height/(l=u*g)*u;break;case"None":a=d,l=u}o.width=a,o.height=l,o.sourceWidth=h,o.sourceHeight=c,o.source=t.source,o.alignment=t.imageAlign,o.scale=t.imageScale,o.description=t.description?t.description:t.id,this.renderer.drawImage(e,o,r,s)},n.prototype.renderContainer=function(t,e,i,r,s,o,a,l,h,c,d){var g,u={svg:s,g:e},f=document.getElementById(this.diagramId);if(f&&(g=f.ej2_instances[0]),this.diagramId&&(s=this.getParentSvg(t)||s,this.isSvgMode)){var v=this.getParentElement(t,e,s,l).g||e;s=this.getParentSvg(this.hasNativeParent(t.children))||s;var y=this.getParentElement(this.hasNativeParent(t.children),v,s,l);u.svg=y.svg||s,u.g=y.g||v,o&&s&&(s.getElementById(u.g.id)||e.appendChild(u.g)),e=u.g}if(this.renderRect(t,e,r,s),this.groupElement=t,t.hasChildren()){for(var b,S=void 0,M=0,w=t.children;M0&&(D=g.selectedItems.nodes[0]);var L,A=void 0,x=void 0,P=!1;if(g&&g.selectedItems&&(L=g.getObject(t.id)),"None"!==t.flip&&(D=L),"None"===t.flip&&(D=L),D&&D.flipMode&&(P=!0),!(t.elementActions&Xr.ElementIsGroup)&&g instanceof Fl&&g.nameTable[t.id]&&"connectors"!==g.nameTable[t.id].propName&&P&&D){if(A=t.children&&t.children[0]instanceof En?document.getElementById(D.id+"_content_inner_native_element"):document.getElementById(D.id+"_content_groupElement"),!(t.children[0]instanceof En)&&"Text"!==D.shape.type&&"None"!==D.flipMode&&"Label"!==D.flipMode&&"All"!==D.flipMode&&"PortAndLabel"!==D.flipMode&&"LabelText"!==D.flipMode&&"PortAndLabelText"!==D.flipMode&&"LabelAndLabelText"!==D.flipMode||t.children[0]instanceof En&&"Port"===D.flipMode)return void this.renderFlipElement(t,A,D.flip);if((t.children[0]instanceof En&&("All"===D.flipMode||"Label"===D.flipMode)||"Label"===D.flipMode||"PortAndLabel"===D.flipMode||"LabelText"===D.flipMode||"PortAndLabelText"===D.flipMode||"LabelAndLabelText"===D.flipMode||"Image"===D.shape.type&&"Label"===D.flipMode)&&this.renderFlipElement(t,A,t.flip),"None"!==t.flip&&"None"===D.flipMode)this.renderFlipElement(t,A,t.flip);else if("None"!==t.flip&&("Label"===D.flipMode||"PortAndLabel"===D.flipMode||"LabelText"===D.flipMode||"PortAndLabelText"===D.flipMode||"LabelAndLabelText"===D.flipMode)||t.children[0]instanceof En&&"None"!==t.flip&&D&&("None"===D.flipMode||"All"===D.flipMode)){for(var O=0;O0){var i=t[0];if(i instanceof En)return i;i.children&&i.children.length&&this.hasNativeParent(i.children,e++||0)}},n.prototype.renderRect=function(t,e,i,r,s){var o=this.getBaseAttributes(t,i,s);o.cornerRadius=t.cornerRadius||0,t.isExport&&(o.cornerRadius*=t.exportScaleValue.x),this.renderer.drawRectangle(e,o,this.diagramId,t.isExport,void 0,r,t.description?t.description:t.id)},n.prototype.drawRect=function(t,e){e.cornerRadius=0,this.svgRenderer.drawRectangle(t,e,this.diagramId)},n.prototype.getBaseAttributes=function(t,e,i){var r={width:t.actualSize.width,height:t.actualSize.height,x:t.offsetX-t.actualSize.width*t.pivot.x,y:t.offsetY-t.actualSize.height*t.pivot.y,fill:t.style.fill,stroke:t.style.strokeColor,angle:t.rotateAngle+t.parentTransform,pivotX:t.pivot.x,pivotY:t.pivot.y,strokeWidth:t.style.strokeWidth,dashArray:t.style.strokeDashArray||"",opacity:t.style.opacity,shadow:t.shadow,gradient:t.style.gradient,visible:t.visible,id:t.id,description:t.description,canApplyStyle:t.canApplyStyle,shapeType:t.shapeType};return"Page"===t.rotationReference&&(r.angle=t.rotateAngle),i&&(r.x=r.x-.5,r.y=r.y-.5),t.isExport&&(r.width*=t.exportScaleValue.x,r.height*=t.exportScaleValue.y,r.x*=t.exportScaleValue.x,r.y*=t.exportScaleValue.y,r.strokeWidth*=t.exportScaleValue.x),t.flip&&(r.flip=t.flip),e&&(r.x+=e.tx,r.y+=e.ty),r},n.renderSvgBackGroundImage=function(t,e,i,r,s,o){if(t.source){var l=mT(e.id).getElementById(e.id+"_image");if(!l){var h=function moe(n){return xt(n).getElementsByClassName("e-background-image-layer")[0]}(e.id);(l=document.createElementNS("http://www.w3.org/2000/svg","image")).setAttribute("id",e.id+"_image"),h.appendChild(l)}var c=new Image;c.src=t.source,l.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",c.src.toString());var d="None"!==t.scale?t.scale:"",u=t.align,f=u.charAt(0).toLowerCase()+u.slice(1);d&&(f+=" "+d.charAt(0).toLowerCase()+d.slice(1)),ii(l,{id:e.id+"_image",x:i,y:r,width:s,height:o,preserveAspectRatio:f})}},n.prototype.transformLayers=function(t,e){var i=t.tx*t.scale,r=t.ty*t.scale,s="domTable";if(i!==this.transform.x||r!==this.transform.y||0===i||0===r){e&&(window[""+s][this.diagramId+"_diagramLayer"]||(window[""+s][this.diagramId+"_diagramLayer"]=this.diagramSvgLayer.getElementById(this.diagramId+"_diagramLayer")),window[""+s][this.diagramId+"_diagramLayer"].setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+"),scale("+t.scale+")"));var a=function yoe(n){var t="domTable",e=null;return window[t][n+"_gridline"]?e=window[t][n+"_gridline"]:(e=Fd(n).getElementById(n+"_gridline"),window[t][n+"_gridline"]=e),e}(this.diagramId);return a.setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+")"),window[""+s][this.diagramId+"_diagramPorts"]||(window[""+s][this.diagramId+"_diagramPorts"]=this.iconSvgLayer.getElementById(this.diagramId+"_diagramPorts")),window[""+s][this.diagramId+"_diagramPorts"].setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+"),scale("+t.scale+")"),window[""+s][this.diagramId+"_diagramExpander"]||(window[""+s][this.diagramId+"_diagramExpander"]=this.iconSvgLayer.getElementById(this.diagramId+"_diagramExpander")),window[""+s][this.diagramId+"_diagramExpander"].setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+"),scale("+t.scale+")"),window[""+s][this.diagramId+"_nativeLayer"]||(window[""+s][this.diagramId+"_nativeLayer"]=this.nativeSvgLayer.getElementById(this.diagramId+"_nativeLayer")),window[""+s][this.diagramId+"_nativeLayer"].setAttribute("transform","translate("+t.tx*t.scale+","+t.ty*t.scale+"),scale("+t.scale+")"),Io(this.diagramId).children[0].style.transform="translate("+t.tx*t.scale+"px,"+t.ty*t.scale+"px)scale("+t.scale+")",this.transform={x:t.tx*t.scale,y:t.ty*t.scale},!0}return!1},n.prototype.updateNode=function(t,e,i,r,s,o,a){this.renderElement(t,e,i,r,this.getParentSvg(t),void 0,void 0,s,null,o,a)},n}(),tse=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),ZI=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},oF=function(n){function t(e,i){var r=n.call(this,e,i)||this;return r.mode="Canvas",r.id="overview",r.actionName="",r.startPoint=null,r.currentPoint=null,r.prevPoint=null,r.scale=null,r.inAction=!1,r.viewPortRatio=1,r.horizontalOffset=0,r.verticalOffset=0,r.model={},r.event=!0,r.overviewid=88123,r.model={width:r.width,height:r.height},r}return tse(t,n),t.prototype.onPropertyChanged=function(e,i){for(var r=0,s=Object.keys(e);r0||e.toString().indexOf("%")>0?e.toString():e.toString()+"px"},t.prototype.renderCanvas=function(e){var i=document.getElementById(this.element.id+"_canvas");i||(i=Tt("div",{}),this.element.appendChild(i)),Ho(i,{id:this.element.id+"_canvas",class:"drawing",style:"position:relative; height:"+this.getSizeValue(this.model.height)+"; width:"+this.getSizeValue(this.model.width)+";style:-ms-touch-action: none;touch-action: none;"}),this.element.setAttribute("tabindex",String(-1)),this.element.style.overflow="hidden",this.element.style.height=String(this.model.height),this.element.style.width=String(this.model.width),this.canvas=i},t.prototype.setParent=function(e){var i=document.getElementById(e);if(this.parent){var s=this.parent;this.parent=null,s.setOverview(null,this.element.id),this.removeDocument(this)}this.parent=this.getDiagram(i,"ej2_instances"),this.parent&&this.parent.setOverview(this)},t.prototype.getDiagram=function(e,i){for(var r,s=e[""+i].length,o=0;o0?f:Math.floor(window.innerWidth)}if(0===h){var p=Math.floor(window.innerHeight-u-Math.floor(c.top));h=p>0?p:Math.floor(window.innerHeight)}l>0&&(s.setAttribute("width",String(l)),this.model.height=h),h>0&&(s.setAttribute("height",String(h)),this.model.width=l),e.diagramLayerDiv||(e.diagramLayerDiv=Tt("div",{}),e.diagramLayer=bo.createCanvas(this.element.id+"_diagramLayer",this.model.width,this.model.height),e.diagramLayer.setAttribute("style","position:absolute; left:0px; top:0px "),e.diagramLayerDiv.appendChild(e.diagramLayer),e.canvas.appendChild(e.diagramLayerDiv)),Ho(e.diagramLayerDiv,{id:this.element.id+"_diagramLayer_div",style:"width:"+this.model.width+"px; height:"+this.model.height+"px;position:absolute;top:0px;left:0px"}),this.renderHtmlLayer(e.canvas),this.renderNativeLayer(e.canvas,e),this.addOverviewRectPanel(e)},t.prototype.removeDocument=function(e){var i=document.getElementById(this.canvas.id+"_svg");this.canvas.removeChild(i);var r=document.getElementById(this.element.id+"_htmlLayer");this.canvas.removeChild(r);var s=document.getElementById(this.element.id+"_diagramLayer_div");this.canvas.removeChild(s),e.diagramLayerDiv=null,e.diagramLayer=null,window.domTable[this.id+"html_layer"]=null},t.prototype.renderHtmlLayer=function(e){var i=Tt("div",{id:this.element.id+"_htmlLayer",class:"e-html-layer",style:"pointer-events:none;position:absolute;top:0px;left:0px;"}),s=Tt("div",{id:this.element.id+"_htmlLayer_div",style:"position:absolute;top:0px;left:0px;"});return i.appendChild(s),e.appendChild(i),i},t.prototype.renderNativeLayer=function(e,i){if(!document.getElementById(this.element.id+"_nativeLayer_svg")){var r=this.parent.createSvg(this.element.id+"_nativeLayer_svg",this.model.width,this.model.height),s=Fi("g",{id:this.element.id+"_nativeLayer"});r.appendChild(s),i.diagramLayerDiv.appendChild(r),ii(r,{class:"e-native-layer"})}},t.prototype.addOverviewRectPanel=function(e){var i=document.getElementById(this.canvas.id+"_overviewsvg");i&&i.parentNode.removeChild(i),i=Fi("svg",{id:this.canvas.id+"_overviewsvg",class:"overviewsvg",version:"1.1",style:"position:absolute;left:0px;top:0px; aria-label:Specifies overview",width:this.model.width,height:this.model.height}),e.canvas.appendChild(i);var s=Fi("g",{id:this.element.id+"_overviewlayer",style:"pointer-events:none"});i.appendChild(s);var o=Fi("rect",{fill:"transparent",width:"100%",height:"100%",class:"overviewbackrect",id:this.canvas.id+"overviewbackrect"});o.setAttribute("style"," pointer-events: none; "),s.appendChild(o);var a=Fi("g",{id:this.canvas.id+"overviewhandle",style:"pointer-events:all"});s.appendChild(a);var l=Fi("rect",{id:this.canvas.id+"overviewrect",fill:"transparent"});a.appendChild(l),this.renderOverviewCorner("left",a),this.renderOverviewCorner("right",a),this.renderOverviewCorner("top",a),this.renderOverviewCorner("bottom",a),this.renderOverviewCorner("topleft",a),this.renderOverviewCorner("topright",a),this.renderOverviewCorner("bottomleft",a),this.renderOverviewCorner("bottomright",a)},t.prototype.renderOverviewCorner=function(e,i){var s,o=Fi(s="top"===e||"bottom"===e||"right"===e||"left"===e?"rect":"circle",{id:this.canvas.id+"visible"+e,class:"overview-resizer"});i.appendChild(o);var a=Fi(s,{id:this.canvas.id+e,class:"overviewresizer",fill:"transparent"});i.appendChild(a)},t.prototype.updateOverviewRectangle=function(){var e=this.currentPoint.x-this.prevPoint.x,i=this.currentPoint.y-this.prevPoint.y,r=new me;r.width=0,r.height=0;var s=0,o=0;switch(this.resizeDirection){case"left":r.width-=e,r.height-=e/this.viewPortRatio,s=e,o=e/this.viewPortRatio,o/=2;break;case"right":r.width+=e,r.height+=e/this.viewPortRatio,o=e/this.viewPortRatio,o/=-2;break;case"top":r.height-=i,r.width-=i*this.viewPortRatio,o=i,s=i*this.viewPortRatio,s/=2;break;case"bottom":r.height+=i,r.width+=i*this.viewPortRatio,s=i*this.viewPortRatio,s/=-2;break;case"topleft":Math.abs(i)>Math.abs(e)?e=i*this.viewPortRatio:i=e/this.viewPortRatio,r.width-=e,r.height-=i,s=e,o=i;break;case"topright":Math.abs(i)>Math.abs(e)?e=-i*this.viewPortRatio:i=-e/this.viewPortRatio,o=i,r.width+=e,r.height-=i;break;case"bottomleft":Math.abs(i)>Math.abs(e)?e=-i*this.viewPortRatio:i=-e/this.viewPortRatio,s=e,r.width-=e,r.height+=i;break;case"bottomright":Math.abs(i)>Math.abs(e)?e=i*this.viewPortRatio:i=e/this.viewPortRatio,r.width+=e,r.height+=i}this.updateHelper(s,o,r,void 0,void 0)},t.prototype.updateHelper=function(e,i,r,s,o){var a,l,h,u,f,d=this.element.getElementsByTagName("svg")[2].getElementById("helper");r?(a=(h=d.getBBox()).x+e,l=h.y+i,s=h.width+r.width,o=h.height+r.height):(u=this.currentPoint.x>this.startPoint.x?this.currentPoint.x-this.prevPoint.x:this.prevPoint.x-this.currentPoint.x,f=this.currentPoint.y>this.startPoint.y?this.currentPoint.y-this.prevPoint.y:this.prevPoint.y-this.currentPoint.y,Math.abs(f)>Math.abs(u)?u=this.viewPortRatio*f:f=u/this.viewPortRatio,h=d.getBBox(),a=this.startPoint.x>this.currentPoint.x?h.x-u:h.x,l=this.startPoint.y>this.currentPoint.y?h.y-f:h.y,s=h.width+u,o=h.height+f),ii(this.helper,{id:this.helper.id,x:a,y:l,width:Math.max(0,s),height:Math.max(0,o)})},t.prototype.updateOverviewrect=function(e,i,r,s){Ho(document.getElementById(this.canvas.id+"overviewrect"),{x:e,y:i,width:Math.max(1,r),height:Math.max(1,s)}),this.updateOverviewCorner("top",e+8,i+1,Math.max(0,r-16),2),this.updateOverviewCorner("bottom",e+8,i+s+3,Math.max(0,r-16),2),this.updateOverviewCorner("left",e-2,i+11,2,Math.max(0,s-16)),this.updateOverviewCorner("right",e+r,i+11,2,Math.max(0,s-16)),this.updateOverviewCorner("topleft",e,i+3,5,5),this.updateOverviewCorner("topright",e+r,i+3,5,5),this.updateOverviewCorner("bottomleft",e,i+s+3,5,5),this.updateOverviewCorner("bottomright",e+r,i+s+3,5,5)},t.prototype.updateOverviewCorner=function(e,i,r,s,o){var a,l;"top"===e||"bottom"===e||"right"===e||"left"===e?(a={x:i,y:r,width:s,height:o,fill:"#ED1C24"},l={x:i-2,y:r-2,width:2===s?4:s,height:2===o?4:o}):(a={cx:i,cy:r,r:4,fill:"#ED1C24"},l={cx:i,cy:r,r:6,fill:"transparent"}),Ho(document.getElementById(this.canvas.id+"visible"+e),a),Ho(document.getElementById(this.canvas.id+e),l)},t.prototype.translateOverviewRectangle=function(){Number(this.model.width),Number(this.model.height);var r=this.currentPoint.x-this.prevPoint.x,s=this.currentPoint.y-this.prevPoint.y,l=this.element.getElementsByClassName("overviewsvg")[0].getElementById(this.canvas.id+"overviewrect").getBBox(),h=l.x+r,c=l.y+s,d=l.width,u=l.height;this.updateOverviewrect(h,c,d,u),this.updateParentView(this.parent.scroller.currentZoom,h,c,d,u,null)},t.prototype.renderOverviewRect=function(e,i,r,s){var o=Number(this.model.width),a=Number(this.model.height),c=Math.max(this.parent.scroller.viewPortWidth/(r/o*this.contentWidth),this.parent.scroller.viewPortHeight/(s/a*this.contentHeight));if(c>=.25&&c<=30){this.updateParentView(c,e,i,r,s,{x:0,y:0});var u=this.scrollOverviewRect(this.parent.scroller.horizontalOffset,this.parent.scroller.verticalOffset,this.parent.scroller.currentZoom,!0);if(this.helper){var p=this.element.getElementsByTagName("rect")[10].getBBox();u.x=p.x,u.y=p.y}"pan"===this.actionName?this.updateOverviewrect(-u.x,-u.y,u.width,u.height):this.updateOverviewrect(u.x,u.y,u.width,u.height)}},t.prototype.scrollOverviewRect=function(e,i,r,s){if(!this.actionName||s){var o=Number(this.model.width),a=Number(this.model.height),l=Math.min(this.contentWidth/o,this.contentHeight/a),h=new Ne,c=h.x=e/r/l,d=h.y=i/r/l,u=0;this.parent.rulerSettings.showRulers&&(u=25);var f=document.getElementById(this.parent.element.id+"content"),p=0,g=0;f&&(p=f.offsetWidth-f.clientWidth,g=f.offsetHeight-f.clientHeight);var v=h.width=(this.parent.scroller.viewPortWidth-u-p)/r/l,y=h.height=(this.parent.scroller.viewPortHeight-u-g)/r/l;if(s){var S=new Ne;return S.x=c,S.y=d,S.width=v,S.height=y,S}this.updateOverviewrect(-c,-d,v,y)}return null},t.prototype.updateParentView=function(e,i,r,s,o,a){var p,g,l=Number(this.model.width),h=Number(this.model.height),u=i*(this.contentWidth/l)*e,f=r*(this.contentHeight/h)*e;this.parent.scroller.getPageBounds(),(1!==e||"pan"===this.actionName)&&(p=-u-this.parent.scroller.horizontalOffset,g=-f-this.parent.scroller.verticalOffset),this.parent.setBlazorDiagramProps(!0),this.parent.realActions|=$i.OverViewAction,"scale"===this.actionName||"draw"===this.actionName?this.parent.scroller.zoom(e/this.parent.scroller.currentZoom,p,g,a):ce()?this.parent.scroller.zoom(1,p,g,a):this.parent.pan(p,g,a,!0)},t.prototype.updateHtmlLayer=function(e){var i=Io(e.element.id),r=this.parent.scroller.getPageBounds(!0),o=r.height,a=Math.max(r.width,this.parent.scroller.viewPortWidth),l=Math.max(o,this.parent.scroller.viewPortHeight/this.parent.scroller.currentZoom),h=Math.min(Number(this.model.width)/a,Number(this.model.height)/l);i.style.transform="scale("+h+") translate("+this.parent.scroller.transform.tx+"px,"+this.parent.scroller.transform.ty+"px)"},t.prototype.updateView=function(e){var i=this.parent.scroller.getPageBounds(),r=i.width,s=i.height,o=Number(this.model.width),a=Number(this.model.height),l=Math.max(r,this.parent.scroller.viewPortWidth),h=Math.max(s,this.parent.scroller.viewPortHeight);this.contentWidth=l=Math.max(l,o/a*h),this.contentHeight=h=Math.max(h,a/o*l);var c=Math.min(o/l,a/h),d=document.getElementById(this.element.id+"_htmlLayer");d.style.webkitTransform="scale("+c+") translate("+-i.x+"px,"+-i.y+"px)",d.style.transform="scale("+c+") translate("+-i.x+"px,"+-i.y+"px)",document.getElementById(this.element.id+"_overviewlayer").setAttribute("transform","translate("+-i.x*c+","+-i.y*c+")"),this.horizontalOffset=i.x*c,this.verticalOffset=i.y*c;var f=document.getElementById(this.element.id+"_diagramLayer"),p=zF(this.element.id),g=f.getContext("2d"),v=Number(this.model.width)/this.contentWidth,y=Number(this.model.height)/this.contentHeight;v=Math.min(v,y);var S=this.parent.scroller.transform;p.setAttribute("transform","translate("+S.tx*v+","+S.ty*y+"),scale("+v+")"),g.setTransform(v,0,0,v,0,0),g.fillStyle="red",this.scrollOverviewRect(this.parent.scroller.horizontalOffset,this.parent.scroller.verticalOffset,this.parent.scroller.currentZoom)},t.prototype.scrolled=function(e){if(this.event){var i=this.scrollOverviewRect(this.parent.scroller.horizontalOffset,this.parent.scroller.verticalOffset,this.parent.scroller.currentZoom,!0);this.updateOverviewrect(-i.x,-i.y,i.width,i.height),this.updateView(this)}},t.prototype.updateCursor=function(e){if(um(e.target,"overviewresizer"))switch(e.target.id){case this.canvas.id+"left":this.canvas.style.cursor="w-resize";break;case this.canvas.id+"right":this.canvas.style.cursor="e-resize";break;case this.canvas.id+"top":this.canvas.style.cursor="n-resize";break;case this.canvas.id+"bottom":this.canvas.style.cursor="s-resize";break;case this.canvas.id+"topleft":this.canvas.style.cursor="nw-resize";break;case this.canvas.id+"topright":this.canvas.style.cursor="ne-resize";break;case this.canvas.id+"bottomleft":this.canvas.style.cursor="sw-resize";break;case this.canvas.id+"bottomright":this.canvas.style.cursor="se-resize"}else this.canvas.style.cursor="default"},t.prototype.mouseMove=function(e){if(this.event=!1,this.updateCursor(e),this.currentPoint=this.mousePosition(e),this.actionName)switch(this.actionName){case"draw":!this.inAction&&(this.startPoint.x!==this.currentPoint.x||this.startPoint.y!==this.currentPoint.y)&&(this.initHelper(),this.inAction=!0),this.inAction&&this.updateHelper();break;case"scale":this.inAction||(this.initHelper(),this.inAction=!0),this.updateOverviewRectangle();break;case"pan":(this.startPoint.x!==this.currentPoint.x||this.startPoint.y===this.currentPoint.y||this.inAction)&&(this.inAction=!0,this.translateOverviewRectangle())}this.prevPoint=this.currentPoint},t.prototype.documentMouseUp=function(e){this.inAction=!1,this.actionName="",this.helper&&(this.helper.parentNode.removeChild(this.helper),this.helper=null),this.event=!0,document.getElementById(this.canvas.id+"overviewhandle").style.pointerEvents="all"},t.prototype.windowResize=function(e){var i=this;return this.resizeTo&&clearTimeout(this.resizeTo),this.resizeTo=setTimeout(function(){var s=document.getElementById(i.element.id).getBoundingClientRect();i.model.width=s.width>0?s.width:i.model.width,i.model.height=s.height>0?s.height:i.model.height,i.renderCanvas(),i.setParent(i.sourceID)},10),!1},t.prototype.mouseDown=function(e){if(e.target.id===this.canvas.id+"_overviewsvg"&&(this.actionName="draw"),e.target.id===this.canvas.id+"overviewrect"&&(this.actionName="pan"),um(e.target,"overviewresizer"))switch(this.actionName="scale",e.target.id){case this.canvas.id+"left":this.resizeDirection="left";break;case this.canvas.id+"right":this.resizeDirection="right";break;case this.canvas.id+"top":this.resizeDirection="top";break;case this.canvas.id+"bottom":this.resizeDirection="bottom";break;case this.canvas.id+"topleft":this.resizeDirection="topleft";break;case this.canvas.id+"topright":this.resizeDirection="topright";break;case this.canvas.id+"bottomleft":this.resizeDirection="bottomleft";break;case this.canvas.id+"bottomright":this.resizeDirection="bottomright"}this.startPoint=this.prevPoint=this.mousePosition(e),this.viewPortRatio=this.parent.scroller.viewPortWidth/this.parent.scroller.viewPortHeight,document.getElementById(this.canvas.id+"overviewhandle").style.pointerEvents="none"},t.prototype.mouseUp=function(e){if(this.currentPoint=this.mousePosition(e),this.actionName)if(this.startPoint.x!==this.currentPoint.x||this.startPoint.y!==this.currentPoint.y){if("pan"!==this.actionName&&this.helper){var i=this.element.getElementsByTagName("rect")[10].getBBox();this.resizeDirection=this.resizeDirection||"",this.renderOverviewRect(i.x,i.y,o=i.width,a=i.height)}}else if(e.target.id===this.canvas.id+"_overviewsvg"||"helper"===e.target.id){var o=(i=this.element.getElementsByTagName("svg")[2].getElementById(this.canvas.id+"overviewrect").getBBox()).width,a=i.height;this.inAction=!0,this.actionName="pan",this.renderOverviewRect(this.currentPoint.x-o/2,this.currentPoint.y-a/2,o,a),this.inAction=!1}this.helper&&(this.helper.parentNode.removeChild(this.helper),this.helper=null),this.actionName="",this.startPoint=null,this.currentPoint=null,this.prevPoint=null,this.helper=null,this.viewPortRatio=1,this.resizeDirection="",this.inAction=!1,this.event=!0,document.getElementById(this.canvas.id+"overviewhandle").style.pointerEvents="all"},t.prototype.initHelper=function(){var e=this.element.getElementsByTagName("svg")[2],i=this.startPoint.x,r=this.startPoint.y,s=1,o=1;if("scale"===this.actionName){var l=e.getElementById(this.canvas.id+"overviewrect").getBBox();i=l.x,r=l.y,s=l.width,o=l.height}var h=Fi("rect",{id:"helper",x:i,y:r,width:s,height:o,fill:"transparent",stroke:"gray","stroke-dasharray":"2 2","shape-rendering":"crispEdges"});e.getElementById(this.element.id+"_overviewlayer").appendChild(h),this.helper=h},t.prototype.mousePosition=function(e){var i,r,s;-1!==e.type.indexOf("touch")?(r=(i=e).changedTouches[0].clientX-this.element.offsetLeft,s=i.changedTouches[0].clientY-this.element.offsetTop):(r=e.clientX,s=e.clientY);var l=this.element.getBoundingClientRect();return{x:(r-=l.left)+this.horizontalOffset,y:(s-=l.top)+this.verticalOffset}},t.prototype.destroy=function(){if(this.unWireEvents(),this.notify("destroy",{}),n.prototype.destroy.call(this),document.getElementById(this.element.id)){this.element.classList.remove("e-overview");var e=document.getElementById(this.element.id+"_canvas");e&&this.element.removeChild(e)}this.parent.views.splice(this.parent.views.indexOf(this.element.id),1),this.diagramLayerDiv=null,this.canvas=null,this.parent=null},t.prototype.getModuleName=function(){return"Overview"},ZI([I("100%")],t.prototype,"width",void 0),ZI([I("100%")],t.prototype,"height",void 0),ZI([I("")],t.prototype,"sourceID",void 0),ZI([H()],t.prototype,"created",void 0),t}(Ii);function rse(n,t){for(var e=0;eR.findLength(e,n)?e:t;var o=R.findAngle(t,e),a=R.findAngle(i,n),l=R.findLength(i,n),h=a+2*(o-a);return{x:i.x+l*Math.cos(h*Math.PI/180),y:i.y+l*Math.sin(h*Math.PI/180)}}function Zf(n,t,e){if(n&&n.children&&n.children.length>0)for(var r=void 0,s=0;s0&&"annotations"!==r&&"ports"!==r)if(n[""+l].length>0)for(var h=0;h<=n[""+l].length;h++)Ro(n[""+l],t?t[""+l]:void 0,e[""+l],"annotations"===l||"ports"===l?n:void 0,l);else Ro(n[""+l],t?t[""+l]:void 0,e[""+l],"annotations"===l||"ports"===l?n:void 0,l);else if(s instanceof Object&&t&&"annotations"!==r&&"ports"!==r)Ro(n[""+l],t[""+l],e[""+l]);else if("annotations"!==r&&"ports"!==r&&t&&!t[""+l]||!t&&n&&(n[""+l]||void 0!==n[""+l]))n[""+l]=e[""+l];else{var c=void 0;("annotations"===r||"ports"===r)&&("annotations"===r?(n[""+l]&&Ro(n[""+l],t[""+l],e[""+l]),n[""+l]||(ps(i)===de?(c=new Or(i,"annotations",e[""+l]),i.annotations.push(c)):(c=new Kn(i,"annotations",e[""+l]),i.annotations.push(c)))):n[""+l]?Ro(n[""+l],t[""+l],e[""+l]):(c=new Es(i,"ports",e[""+l]),i.ports.push(c)))}}}function cse(n,t){for(var e="Bezier"===n.type?function ase(n){var t=[];if("Bezier"===n.type)for(var e=0,i=0;i0||n.ports.length>0){var f=n.wrapper.children;for(i=3;i0)return{enabled:!1,intersectPt:e};var l=o/s,h=a/s;return l>=0&&l<=1&&h>=0&&h<=1?(e.x=i.x1+l*(i.x2-i.x1),e.y=i.y1+l*(i.y2-i.y1),{enabled:!0,intersectPt:e}):{enabled:!1,intersectPt:e}}function KI(n,t,e,i){var a=tm(cF(n.x,n.y,t.x,t.y),cF(e.x,e.y,i.x,i.y));return a.enabled?a.intersectPt:{x:0,y:0}}function cF(n,t,e,i){return{x1:Number(n)||0,y1:Number(t)||0,x2:Number(e)||0,y2:Number(i)||0}}function dF(n,t,e){var i=[],s={x:t.topRight.x+(e=e||0),y:t.topRight.y},o={x:t.bottomRight.x,y:t.bottomRight.y-e},a={x:t.bottomLeft.x,y:t.bottomLeft.y+e};return i.push({x:t.topLeft.x-e,y:t.topLeft.y}),i.push(s),i.push(o),i.push(a),i}function zc(n,t,e,i,r,s){var o={},a=e.scroller.transform.scale,h=e.scroller.verticalOffset;return o.x=(i?n.x:t.x)*a+e.scroller.horizontalOffset-r,o.y=(i?n.y:t.y)*a+h-s,o}function uF(n,t){var e=new Ze;return e.data=n.pathData,e.height=n.height>10?n.height-(n.padding.bottom+n.padding.top):n.height,e.width=n.width>10?n.width-(n.padding.left+n.padding.right):n.width,e.visible=n.visibility,e.id=t.id+"_shape",e.inversedAlignment=!1,e.horizontalAlignment="Center",e.verticalAlignment="Center",e.style={fill:n.iconStrokeColor,strokeColor:n.iconStrokeColor,strokeWidth:n.iconStrokeWidth},e.setOffsetWithRespectToBounds(.5,.5,"Fraction"),e.relativeMode="Object",e.description=t.description||"",e}function Xx(n,t,e){var i=qx(n,t),r=R.findAngle(n[i.index],n[i.index+1]),s=function mse(n){var t;t=n instanceof xI?0:void 0===n.content?10:0;var e=0;switch(n.alignment){case"Center":e=0;break;case"Before":e=-(0+t);break;case"After":e=0+t}return e}(t),o=R.transform(i.point,r+45,s);return i.point=o,i.angle=r,i}function qx(n,t){for(var r,s,a,l,e=0,i=t.offset,o=[],h=0;h=c)return s=R.findAngle(n[parseInt(d.toString(),10)],n[d+1]),{point:r=R.transform(n[parseInt(d.toString(),10)],s,c-(a||0)),index:l=d};a=o[parseInt(d.toString(),10)]}return{point:r,index:l}}function fF(n,t,e){t%=360;var a,l,s=225;switch(n.alignment){case"Before":t>=45&&t<=135?(l="right",a=.5===n.offset?"center":"top"):t>=s&&t<=315?(l="left",a=.5===n.offset?"center":"bottom"):t>45&&t=45&&t<=135?(l="left",a=.5===n.offset?"center":"top"):t>=s&&t<=315?(l="right",a=.5===n.offset?"center":"bottom"):t>45&&tMath.abs(t.y-n.y)?n.x0)for(var e=0;e=0;r--)("nodes"===i||"connectors"===i)&&(n[""+i][parseInt(r.toString(),10)].wrapper=null),"dataManager"!==i&&(n[""+i][parseInt(r.toString(),10)]=Jx(n[""+i][parseInt(r.toString(),10)],e[""+i][parseInt(r.toString(),10)],void 0!==t[""+i]?t[""+i][parseInt(r.toString(),10)]:[]),("[]"===JSON.stringify(n[""+i][parseInt(r.toString(),10)])||"{}"===JSON.stringify(n[""+i][parseInt(r.toString(),10)])||void 0===n[""+i][parseInt(r.toString(),10)])&&n[""+i].splice(r,1));n=void 0}function zh(n,t){var e=t.style,i=t;t.canApplyStyle=!0;for(var r=0,s=Object.keys(n);r=0&&n.splice(e,1)}function Jf(n,t,e){var i;n.intermediatePoints=t,n.updateSegmentElement(n,t,n.wrapper.children[0],e);var r=n.sourceDecorator;if("Bezier"===n.type){var s=n.segments[0],o=n.segments[n.segments.length-1];i=[R.isEmptyPoint(o.point2)?o.bezierPoint2:o.point2,R.isEmptyPoint(s.point1)?s.bezierPoint1:s.point1]}else i=n.intermediatePoints;t=n.clipDecorators(n,t,e);var a=n.wrapper.children[0];a.canMeasurePath=!0,n.updateDecoratorElement(a=n.wrapper.children[1],t[0],i[1],r),n.updateDecoratorElement(a=n.wrapper.children[2],t[t.length-1],i[i.length-2],n.targetDecorator),n.updateShapeElement(n)}function Kx(n,t,e){var l,i=n.wrapper,s=t.offset,o=t.size/e.scale,a=t.margin,h=i.offsetX-i.actualSize.width*i.pivot.x,c=i.offsetY-i.actualSize.height*i.pivot.y;if(l={x:0,y:0},n.nodes.length>0){switch(t.side){case"Top":l.x+=h+s*i.actualSize.width,l.y+=c-o;break;case"Bottom":l.x+=h+s*i.actualSize.width,l.y+=c+i.actualSize.height+o;break;case"Left":l.x+=h-o,l.y+=c+s*i.actualSize.height;break;case"Right":l.x+=h+i.actualSize.width+o,l.y+=c+s*i.actualSize.height}l.x+=(a.left-a.right)/e.scale+o/2*("Center"===t.horizontalAlignment?0:"Right"===t.horizontalAlignment?-1:1),l.y+=(a.top-a.bottom)/e.scale+o/2*("Center"===t.verticalAlignment?0:"Top"===t.verticalAlignment?-1:1)}else if(n.connectors.length>0){var d=n.connectors[0],u={offset:s},f=qx(d.intermediatePoints,u),p=f.index;l=f.point;var y,v=Xx(d.intermediatePoints,u).angle;qi(y=Bi(),-v,d.intermediatePoints[parseInt(p.toString(),10)].x,d.intermediatePoints[parseInt(p.toString(),10)].y),(l=Ke(y,l)).x+=a.left-a.right+o/2*("Center"===t.horizontalAlignment?0:"Right"===t.horizontalAlignment?-1:1),l.y+=a.top-a.bottom+o/2*("Center"===t.verticalAlignment?0:"Top"===t.verticalAlignment?-1:1),qi(y=Bi(),v,d.intermediatePoints[parseInt(p.toString(),10)].x,d.intermediatePoints[parseInt(p.toString(),10)].y),l=Ke(y,l)}return 0===i.rotateAngle&&0===i.parentTransform||(qi(y=Bi(),i.rotateAngle+i.parentTransform,i.offsetX,i.offsetY),l=Ke(y,l)),l}function ga(n,t,e,i){if(i.annotation){if(Pl(i.annotation))return!0}else if(mr[""+t]&n&&bt[""+t]&e)return!0;return!1}function qr(n,t){return!!(mr[""+t]&n)}function Hc(n,t){return!!(bx[""+t]&n)}function va(n,t){return n.visibility&t}function eb(n,t){var e;if("Text"===n.shape.type)e=n.shape;else{var i=t.split("_");t=i[i.length-1];for(var r=0;rn[""+t]?e.splice(0,0,n):e.push(n);else if(e.length>1){for(var i=0,r=e.length-1,s=Math.floor((i+r)/2);s!==i;)if(e[parseInt(s.toString(),10)][""+t]n[""+t]))break;r=s,s=Math.floor((i+r)/2)}e[parseInt(r.toString(),10)][""+t]n[""+t]?e.splice(i,0,n):e[parseInt(i.toString(),10)][""+t]n[""+t]&&e.splice(r,0,n)}}function zse(n){var t=document.getElementById(n.diagramId),e="ej2_instances",i=t[""+e][0].nodes;void 0===i&&(i=function Rse(n){for(var t=[],e=0;e30?10:o/2;for(var h=0,c=0;c=l){var u=l-h;r=Xt(n[c],n[c+1]),s=R.transform(n[c],r,u);break}h+=d}return s},rb=function(n,t){if(n instanceof te||n instanceof de)for(var e=0;e=0||navigator.platform.indexOf("iPad")>=0||navigator.platform.indexOf("iPhone")>=0||navigator.platform.indexOf("MacIntel")>=0)&&("safari"===X.info.name||"webkit"===X.info.name)}function wF(n,t,e,i){return void 0!==t.previewSize[""+i]?t.previewSize[""+i]:void 0!==n.symbolPreview[""+i]?n.symbolPreview[""+i]:t[""+i]||e.actualSize[""+i]}function om(n,t,e){return n&&n.parentId&&(e=(n=t.nameTable[n.parentId]).parentId?om(n,t,e):n.id),e}function am(n,t){return n.selectedItems.connectors.length>1&&0===n.selectedItems.nodes.length&&0!==t.rotateAngle}function _se(n){if(n.arrowType&&""!==n.arrowType.trim())switch(n.arrowType){case"single-line-arrow":default:return{targetDecorator:"Arrow",strokeWidth:1};case"double-line-arrow":return{targetDecorator:"Arrow",strokeWidth:2};case"dotted-arrow":return{targetDecorator:"Arrow",strokeDashArray:"2,2"};case"single-line":return{targetDecorator:"None",strokeWidth:1};case"double-line":return{targetDecorator:"None",strokeWidth:2};case"dotted":return{targetDecorator:"None",strokeDashArray:"2,2"};case"wiggly-arrow":return{targetDecorator:"None",strokeWidth:1,opacity:0}}return{targetDecorator:"Arrow",strokeWidth:1}}var Use=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),no=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},CF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Use(t,n),no([I("None")],t.prototype,"shape",void 0),no([I("white")],t.prototype,"fill",void 0),no([I("Auto")],t.prototype,"horizontalAlignment",void 0),no([I("Auto")],t.prototype,"verticalAlignment",void 0),no([I(10)],t.prototype,"width",void 0),no([I(10)],t.prototype,"height",void 0),no([re({x:.5,y:1},R)],t.prototype,"offset",void 0),no([I("#1a1a1a")],t.prototype,"borderColor",void 0),no([I(1)],t.prototype,"borderWidth",void 0),no([re({},Jn)],t.prototype,"margin",void 0),no([I("")],t.prototype,"pathData",void 0),no([I("")],t.prototype,"content",void 0),no([I(0)],t.prototype,"cornerRadius",void 0),no([re({left:2,right:2,top:2,bottom:2},Jn)],t.prototype,"padding",void 0),no([I("#1a1a1a")],t.prototype,"iconColor",void 0),t}(Ee),jse=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),rT=function(n){function t(){var e=null!==n&&n.apply(this,arguments)||this;return e.orientation="Vertical",e.measureChildren=void 0,e.considerPadding=!0,e}return jse(t,n),t.prototype.measure=function(e){return this.desiredSize=this.measureStackPanel(e,"Horizontal"===this.orientation?this.updateHorizontalStack:this.updateVerticalStack),this.desiredSize},t.prototype.arrange=function(e){return this.actualSize=this.arrangeStackPanel(e,"Horizontal"===this.orientation?this.arrangeHorizontalStack:this.arrangeVerticalStack),this.updateBounds(),this.actualSize},t.prototype.measureStackPanel=function(e,i){var r=void 0;if(void 0!==this.children&&this.children.length>0)for(var s=0,o=this.children;s0){var r=void 0,s=void 0;r=this.offsetX-e.width*this.pivot.x+this.padding.left,s=this.offsetY-e.height*this.pivot.y+this.padding.top;for(var o=0,a=this.children;o0)for(var i=0,r=this.children;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},$se=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return qse(t,n),Rh([I("Horizontal")],t.prototype,"orientation",void 0),Rh([I("Center")],t.prototype,"type",void 0),Rh([I(void 0)],t.prototype,"offset",void 0),Rh([I(!1)],t.prototype,"enableRouting",void 0),Rh([I([])],t.prototype,"children",void 0),Rh([I("")],t.prototype,"assistants",void 0),Rh([I("")],t.prototype,"level",void 0),Rh([I("")],t.prototype,"hasSubTree",void 0),Rh([I("")],t.prototype,"rows",void 0),t}(Ee),Ni=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),q=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Zse=function(n){if(n)switch(n.type){case"Basic":default:return nb;case"Flow":return TF;case"Path":return EF;case"Image":return xF;case"Text":return zd;case"Bpmn":return hT;case"Native":return lm;case"HTML":return DF;case"UmlActivity":return AF;case"UmlClassifier":return LF;case"SwimLane":return Bd}return nb},ma=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),q([I("Basic")],t.prototype,"type",void 0),t}(Ee),EF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"Path"},q([I("Path")],t.prototype,"type",void 0),q([I("")],t.prototype,"data",void 0),t}(ma),lm=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"Native"},q([I("Native")],t.prototype,"type",void 0),q([I("")],t.prototype,"content",void 0),q([I("Stretch")],t.prototype,"scale",void 0),t}(ma),DF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"Html"},q([I("HTML")],t.prototype,"type",void 0),q([I("")],t.prototype,"content",void 0),t}(ma),xF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"Image"},q([I("Image")],t.prototype,"type",void 0),q([I("")],t.prototype,"source",void 0),q([I("None")],t.prototype,"scale",void 0),q([I("None")],t.prototype,"align",void 0),t}(ma),zd=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"Text"},q([I("Text")],t.prototype,"type",void 0),q([I("")],t.prototype,"content",void 0),q([re({},Jn)],t.prototype,"margin",void 0),t}(ma),nb=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"BasicShape"},q([I("Basic")],t.prototype,"type",void 0),q([I("Rectangle")],t.prototype,"shape",void 0),q([I(0)],t.prototype,"cornerRadius",void 0),q([Bt([],R)],t.prototype,"points",void 0),t}(ma),TF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"FlowShape"},q([I("Flow")],t.prototype,"type",void 0),q([I("Terminator")],t.prototype,"shape",void 0),t}(ma),sT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"BpmnGateway"},q([I("None")],t.prototype,"type",void 0),t}(Ee),oT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"BpmnDataObject"},q([I("None")],t.prototype,"type",void 0),q([I(!1)],t.prototype,"collection",void 0),t}(Ee),Jse=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),q([I("None")],t.prototype,"type",void 0),q([I("None")],t.prototype,"loop",void 0),q([I(!1)],t.prototype,"call",void 0),q([I(!1)],t.prototype,"compensation",void 0),t}(Ee),aT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"BpmnEvent"},q([I("Start")],t.prototype,"event",void 0),q([I("None")],t.prototype,"trigger",void 0),t}(Ee),Rd=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"BpmnSubEvent"},q([I("None")],t.prototype,"trigger",void 0),q([I("Start")],t.prototype,"event",void 0),q([I("")],t.prototype,"id",void 0),q([re({},R)],t.prototype,"offset",void 0),q([Bt([],Kn)],t.prototype,"annotations",void 0),q([Bt([],Es)],t.prototype,"ports",void 0),q([I()],t.prototype,"width",void 0),q([I()],t.prototype,"height",void 0),q([re({},Jn)],t.prototype,"margin",void 0),q([I("Center")],t.prototype,"horizontalAlignment",void 0),q([I("Center")],t.prototype,"verticalAlignment",void 0),q([I(!0)],t.prototype,"visible",void 0),t}(Ee),Kse=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),q([re({id:"success",event:"End",offset:{x:1,y:.5}},Rd)],t.prototype,"success",void 0),q([re({id:"failure",event:"Intermediate",trigger:"Error",offset:{x:.25,y:1}},Rd)],t.prototype,"failure",void 0),q([re({id:"cancel",event:"Intermediate",trigger:"Cancel",offset:{x:.75,y:1}},Rd)],t.prototype,"cancel",void 0),t}(Ee),eoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),q([I("None")],t.prototype,"type",void 0),q([I(!1)],t.prototype,"adhoc",void 0),q([I("Default")],t.prototype,"boundary",void 0),q([I(!1)],t.prototype,"compensation",void 0),q([I("None")],t.prototype,"loop",void 0),q([I(!0)],t.prototype,"collapsed",void 0),q([Bt([],Rd)],t.prototype,"events",void 0),q([re({},Kse)],t.prototype,"transaction",void 0),q([I(void 0)],t.prototype,"processes",void 0),t}(Ee),lT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"BpmnActivity"},q([I("Task")],t.prototype,"activity",void 0),q([re({},Jse)],t.prototype,"task",void 0),q([re({},eoe)],t.prototype,"subProcess",void 0),t}(Ee),hm=function(n){function t(e,i,r,s){return n.call(this,e,i,r,s)||this}return Ni(t,n),t.prototype.getClassName=function(){return"BpmnAnnotation"},q([I("")],t.prototype,"text",void 0),q([I("")],t.prototype,"id",void 0),q([I(0)],t.prototype,"angle",void 0),q([I()],t.prototype,"height",void 0),q([I()],t.prototype,"width",void 0),q([I(0)],t.prototype,"length",void 0),t}(Ee),toe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),q([I("")],t.prototype,"textAnnotationTarget",void 0),q([I("Auto")],t.prototype,"textAnnotationDirection",void 0),t}(Ee),hT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"BpmnShape"},q([I("Bpmn")],t.prototype,"type",void 0),q([I("Event")],t.prototype,"shape",void 0),q([re({},aT)],t.prototype,"event",void 0),q([re({},sT)],t.prototype,"gateway",void 0),q([re({},oT)],t.prototype,"dataObject",void 0),q([re({},lT)],t.prototype,"activity",void 0),q([re({},hm)],t.prototype,"annotation",void 0),q([Bt([],hm)],t.prototype,"annotations",void 0),q([re({},toe)],t.prototype,"textAnnotation",void 0),t}(ma),AF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"UmlActivityShape"},q([I("UmlActivity")],t.prototype,"type",void 0),q([I("Action")],t.prototype,"shape",void 0),t}(ma),cT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"MethodArguments"},q([I("")],t.prototype,"name",void 0),q([I("")],t.prototype,"type",void 0),q([re({},Qf)],t.prototype,"style",void 0),t}(Ee),rp=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"UmlClassAttribute"},q([I("Public")],t.prototype,"scope",void 0),q([I(!1)],t.prototype,"isSeparator",void 0),q([re({fill:"#F9F9F9",strokeColor:"#CCCCCC"},Ll)],t.prototype,"separatorStyle",void 0),t}(cT),cm=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"UmlClassMethod"},q([Bt([],cT)],t.prototype,"parameters",void 0),t}(rp),sb=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"UmlClass"},q([I("")],t.prototype,"name",void 0),q([Bt([],rp)],t.prototype,"attributes",void 0),q([Bt([],cm)],t.prototype,"methods",void 0),q([re({},Qf)],t.prototype,"style",void 0),t}(Ee),dT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"UmlInterface"},q([I(!1)],t.prototype,"isSeparator",void 0),q([re({fill:"#F9F9F9",strokeColor:"#CCCCCC"},Ll)],t.prototype,"separatorStyle",void 0),t}(sb),ob=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"UmlEnumerationMember"},q([I("")],t.prototype,"name",void 0),q([I("")],t.prototype,"value",void 0),q([I(!1)],t.prototype,"isSeparator",void 0),q([re({fill:"#F9F9F9",strokeColor:"#CCCCCC"},Ll)],t.prototype,"separatorStyle",void 0),q([re({},Qf)],t.prototype,"style",void 0),t}(Ee),uT=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"UmlEnumeration"},q([I("")],t.prototype,"name",void 0),q([Bt([],ob)],t.prototype,"members",void 0),q([re({},Qf)],t.prototype,"style",void 0),t}(Ee),LF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ni(t,n),t.prototype.getClassName=function(){return"UmlClassifierShape"},q([I("UmlClassifier")],t.prototype,"type",void 0),q([re({},sb)],t.prototype,"classShape",void 0),q([re({},dT)],t.prototype,"interfaceShape",void 0),q([re({},uT)],t.prototype,"enumerationShape",void 0),q([I("Class")],t.prototype,"classifier",void 0),t}(ma),te=function(n){function t(e,i,r,s){var a,o=n.call(this,e,i,r,s)||this;return o.isCanvasUpdate=!1,o.status="None",o.parentId="",o.processId="",o.umlIndex=-1,o.outEdges=[],o.inEdges=[],o.isHeader=!1,o.isLane=!1,o.isPhase=!1,o.children&&o.children.length>0&&((!(a=r).style||!a.style.fill)&&(o.style.fill="transparent"),(!a.style||!a.style.strokeColor)&&(o.style.strokeColor="transparent")),o.shape&&"UmlActivity"===o.shape.type&&JI(r,o),o.shape&&"SwimLane"===o.shape.type&&aF(r,o),o.ports&&o.ports.length&&function sse(n){for(var t=0;t>";t=n;break;case"FinalNode":t=pF(e)}return t}(new Ze,i,this);break;case"Bpmn":if(e.bpmnModule){i=e.bpmnModule.initBPMNContent(i,this,e),this.wrapper.elementActions=this.wrapper.elementActions|Xr.ElementIsGroup;var v=this.shape.activity.subProcess;if(v.processes&&v.processes.length)for(var S=0,b=this.shape.activity.subProcess.processes;S>",margin:{left:10,right:10},id:"class",style:{fontSize:i.style.fontSize,color:i.style.color,fill:i.style.fill,textWrapping:r},offset:{x:.5,y:.3},constraints:Nr.ReadOnly}],constraints:(ie.Default|ie.HideThumbs)&~(ie.Rotate|ie.Drag|ie.Resize),verticalAlignment:"Stretch",horizontalAlignment:"Stretch",style:{fill:t.style.fill,strokeColor:"black"===t.style.strokeColor?"#ffffff00":t.style.strokeColor}},!0);return e.initObject(s),e.nodes.push(s),e.UpdateBlazorDiagramModel(s,"Node"),t.children.push(s.id),function Wse(n,t,e,i){if("Enumeration"===n.shape.classifier){var r=e.members;if(r&&r.length){tp(n,t);for(var s="",o=0;o0)for(var o=0;o0&&s.phaseSize&&(i+=s.phaseSize,Gv(n,s.phaseSize)),s.lanes.length>0)for(o=0;o0){var a=0;for(o=0;o0&&"Horizontal"===r.orientation)for(l=0;l0&&(i+=r.phaseSize,o=Xv(r.phaseSize),n.push(o)),a=0;a0&&o.phaseSize){for(var l=0;l0)for(l=0;l0?e.nameTable[this.nodes[0].id].wrapper:e.nameTable[this.connectors[0].id].wrapper,this.annotation.id);i.children.push(s)}else if(this.nodes||this.connectors){for(var o=0;o-1}function HF(n,t,e){n=[];for(var i=0,r=e.length;i0?c.getElementsByTagName("svg")[0].outerHTML:c.getElementsByTagName("g").length>0?c.getElementsByTagName("g")[0].outerHTML:"",s.shape.content=h,n.content=h,c.parentElement.removeChild(c)}l="nodeTemplate"}else a=s,l="annotationTemplate";var p=document.getElementById(n.diagramId).ej2_instances[0];if("string"!=typeof n.content&&"function"!=typeof n.content||n.isTemplate)if(n.isTemplate){if(v=void 0,v=p.isReact?n.getNodeTemplate()($(e),p,l+"_"+("nodeTemplate"===l?e.id:n.nodeId+e.id),void 0,void 0,!1,i):p.isVue||p.isVue3?n.getNodeTemplate()?n.getNodeTemplate()($(e),p,l+"_"+("nodeTemplate"===l?e.id:n.nodeId+e.id),void 0,void 0,!1,i):(v=oi("nodeTemplate"===l?p.nodeTemplate:p.annotationTemplate))($(e),p,l+"_"+("nodeTemplate"===l?e.id:n.nodeId+e.id),void 0,void 0,!1,i):n.getNodeTemplate()($(e),p,l+"_"+("nodeTemplate"===l?e.id:n.nodeId+e.id),void 0,void 0,!1))for(var M=0;M=1&&0===n.x&&("Clip"===i.textOverflow||"Ellipsis"===i.textOverflow)&&("Wrap"===i.textWrapping||"WrapWithOverflow"===i.textWrapping)&&(n.x=t[e-1]?t[e-1].x:-n.width/2),n.x}function _F(n,t,e,i){return e&&!t.template||t.template&&"function"==typeof t.template&&i.isReact?(n.isTemplate=!0,n.template=n.content=Hh(n,!0,t)):n.content=t.template,n}function Qe(){for(var e,t="",i=0;i<5;i++){if(typeof window<"u"&&"crypto"in window&&"getRandomValues"in crypto){var r=new Uint16Array(1);e=(window.msCrypto||window.crypto).getRandomValues(r)[0]%60}else e=Math.floor(61*Math.random());0===i&&e<10?i--:t+="0123456789ABCDEFGHIJKLMNOPQRSTUVWXTZabcdefghiklmnopqrstuvwxyz".substring(e,e+1)}return t}function UF(n){if(n)try{return"function"!=typeof n&&document.querySelectorAll(n).length?oi(document.querySelector(n).innerHTML.trim()):oi(n)}catch{return oi(n)}}function xn(n){new Ne;var e=n.offsetY-n.actualSize.height*n.pivot.y,i=n.offsetY+n.actualSize.height*(1-n.pivot.y),r=n.offsetX-n.actualSize.width*n.pivot.x,s=n.offsetX+n.actualSize.width*(1-n.pivot.x);return Ne.toBounds([{x:r,y:e},{x:s,y:e},{x:r,y:i},{x:s,y:i}])}function yr(n){var t=new Ne,e=xn(n),i=e.middleLeft,r=e.topCenter,s=e.bottomCenter,o=e.middleRight,a=e.topLeft,l=e.topRight,h=e.bottomLeft,c=e.bottomRight;if(n.corners={topLeft:a,topCenter:r,topRight:l,middleLeft:i,middleRight:o,bottomLeft:h,bottomCenter:s,bottomRight:c},0!==n.rotateAngle||0!==n.parentTransform){var d=Bi();qi(d,n.rotateAngle+n.parentTransform,n.offsetX,n.offsetY),n.corners.topLeft=a=Ke(d,a),n.corners.topCenter=r=Ke(d,r),n.corners.topRight=l=Ke(d,l),n.corners.middleLeft=i=Ke(d,i),n.corners.middleRight=o=Ke(d,o),n.corners.bottomLeft=h=Ke(d,h),n.corners.bottomCenter=s=Ke(d,s),n.corners.bottomRight=c=Ke(d,c)}return t=Ne.toBounds([a,l,h,c]),n.corners.left=t.left,n.corners.right=t.right,n.corners.top=t.top,n.corners.bottom=t.bottom,n.corners.center=t.center,n.corners.width=t.width,n.corners.height=t.height,t}function $(n,t,e,i){var r={},s="properties";if(n){e=n.propName;var l=[],h=[];if((l=l.concat(Object.keys(n[""+s]||n))).push("version"),e){var c=Zi(t);h=c?c(e):[],l=l.concat(h)}for(var d=function boe(n){switch(n){case"nodes":case"children":return["inEdges","outEdges","parentId","processId","nodeId","umlIndex","isPhase","isLane"];case"connectors":return["parentId"];case"annotation":case"annotations":return["nodeId"];case"shape":return["hasHeader"];case"layers":return["objectZIndex"]}return[]}(e),u=0,f=l=l.concat(d);u0&&(e=r),r=Math.floor(woe(e,i)),s=Bc(o+=n.substr(e,r),t)}while(s<=t.width);for(o=o.substr(0,e),a=e;a=t.width){n=n.substr(0,o.length-1);break}return"Ellipsis"===t.textOverflow?(n=n.substr(0,n.length-3),n+="..."):n=n.substr(0,n.length),n}function ST(n,t){if("NoWrap"===t&&"PreserveAll"===n)return"pre";var e="";switch(n){case"CollapseAll":e="nowrap";break;case"CollapseSpace":e="pre-line";break;case"PreserveAll":e="pre-wrap"}return e}function IT(n,t){var e=Bi();qi(e,t,0,0);var i=Ke(e,{x:0,y:0}),r=Ke(e,{x:n.width,y:0}),s=Ke(e,{x:0,y:n.height}),o=Ke(e,{x:n.width,y:n.height}),a=Math.min(i.x,r.x,s.x,o.x),l=Math.min(i.y,r.y,s.y,o.y),h=Math.max(i.x,r.x,s.x,o.x),c=Math.max(i.y,r.y,s.y,o.y);return new me(h-a,c-l)}function xs(n,t,e,i){if(0!==n){var r=Bi();return qi(r,n,t,e),Ke(r,i)}return i}function Zi(n){return void 0!==n&&"string"==typeof n&&(n=Y(n,window)),n}var bo=function(){function n(){}return n.getContext=function(t){return t.getContext("2d")},n.setCanvasSize=function(t,e,i){t&&(t.setAttribute("width",e.toString()),t.setAttribute("height",i.toString()))},n.prototype.renderGradient=function(t,e,i,r){var s,o,a;if("None"!==t.gradient.type){for(var l=0;l0?(w=0===S.r1?e.arc[parseInt(r.toString(),10)].r1:S.r1,C=0===S.r2?e.arc[parseInt(r.toString(),10)].r2:S.r2,r++):(w=S.r1,C=S.r2);var D=S.angle*(Math.PI/180),A=S.largeArc,x=S.sweep,P={x:u,y:f},L={x:Math.cos(D)*(M.x-P.x)/2+Math.sin(D)*(M.y-P.y)/2,y:-Math.sin(D)*(M.x-P.x)/2+Math.cos(D)*(M.y-P.y)/2},O=Math.pow(L.x,2)/Math.pow(w,2)+Math.pow(L.y,2)/Math.pow(C,2);O>1&&(w*=Math.sqrt(O),C*=Math.sqrt(O));var N=Math.pow(C,2)*Math.pow(L.x,2),T=(A===x?-1:1)*Math.sqrt((Math.pow(w,2)*Math.pow(C,2)-Math.pow(w,2)*Math.pow(L.y,2)-N)/(Math.pow(w,2)*Math.pow(L.y,2)+Math.pow(C,2)*Math.pow(L.x,2)));isNaN(T)&&(T=0);var z={x:T*w*L.y/C,y:T*-C*L.x/w},U={x:(M.x+P.x)/2+Math.cos(D)*z.x-Math.sin(D)*z.y,y:(M.y+P.y)/2+Math.sin(D)*z.x+Math.cos(D)*z.y},B=this.a([1,0],[(L.x-z.x)/w,(L.y-z.y)/C]),j=[(L.x-z.x)/w,(L.y-z.y)/C],Q=[(-L.x-z.x)/w,(-L.y-z.y)/C],oe=this.a(j,Q);this.r(j,Q)<=-1&&(oe=Math.PI),this.r(j,Q)>=1&&(oe=0);var fe=B+oe/2*(x?1:-1);if(Math.cos(fe),Math.sin(fe),S.centp=U,S.xAxisRotation=D,S.rx=w,S.ry=C,S.a1=B,S.ad=oe,S.sweep=x,null!=s){var De=w>C?w:C,xe=w>C?1:w/C,Ie=w>C?C/w:1;s.save(),s.translate(U.x,U.y),s.rotate(D),s.scale(xe,Ie),s.arc(0,0,De,B,B+oe,!x),s.scale(1/xe,1/Ie),s.rotate(-D),s.translate(-U.x,-U.y),s.restore()}break;case"Z":case"z":s.closePath(),u=o,f=a}o=u,a=f}}},n.prototype.drawText=function(t,e,i,r,s,o,a){if(e.content&&!0===e.visible){var l=n.getContext(t);l.save(),this.setStyle(t,e),o&&(e.fontSize*=o),this.applyFlipAndRotate(l,e,t,e.x+e.width*e.pivotX,e.y+e.height*e.pivotY),this.setFontStyle(t,e);var u,d=0;u=e.childNodes;var f=e.wrapBounds;if(l.fillStyle=e.color,f){var p=this.labelAlign(e,f,u);for(d=0;de.width&&"Wrap"!==e.textOverflow&&"NoWrap"===e.textWrapping&&(g.text=VF(g.text,e)),"Clip"!==e.textOverflow&&"Ellipsis"!==e.textOverflow||"Wrap"!==e.textWrapping?l.fillText(g.text,v,y):ya.actualSize.height+a.bounds.y&&(g.text=g.text.slice(0,g.text.length-3),g.text=g.text.concat("...")),l.fillText(g.text,v,y)),"Underline"===e.textDecoration||"Overline"===e.textDecoration||"LineThrough"===e.textDecoration){var M=v,w=void 0,D=v+l.measureText(g.text).width,A=void 0;switch(e.textDecoration){case"Underline":w=y+2,A=y+2;break;case"Overline":w=p.y+g.dy*d,A=p.y+g.dy*d;break;case"LineThrough":w=(y+p.y+g.dy*d)/2+2,A=(y+p.y+g.dy*d)/2+2}l.beginPath(),l.moveTo(M,w),l.lineTo(D,A),l.strokeStyle=e.color,l.lineWidth=.08*e.fontSize,l.globalAlpha=e.opacity,l.stroke()}}}l.restore()}},n.prototype.applyFlipAndRotate=function(t,e,i,r,s){"Horizontal"===e.flip||"Vertical"===e.flip?(t.translate(e.x+e.width/2,e.y+e.height/2),t.rotate(-e.angle*Math.PI/180),t.translate(-e.x-e.width/2,-e.y-e.height/2)):this.rotateContext(i,e.angle,r,s),t.translate(e.x,e.y),"Horizontal"===e.flip?(t.scale(-1,1),t.translate(-1*e.width,0)):"Vertical"===e.flip?(t.scale(1,-1),t.translate(0,-1*e.height)):"Both"===e.flip&&(t.scale(-1,-1),t.translate(-1*e.width,-1*e.height)),t.translate(-e.x,-e.y)},n.prototype.loadImage=function(t,e,i,r,s){var o=new Image;o.src=e.source,this.image(t,o,e.x,e.y,e.width,e.height,e)},n.prototype.drawImage=function(t,e,i,r){var s=this;if(e.visible){var o=n.getContext(t);o.save();var a=e.x+e.width*e.pivotX,l=e.y+e.height*e.pivotY,h=new Image;h.src=e.source,this.setStyle(t,e),o.canvas.id.split("_"),this.applyFlipAndRotate(o,e,t,a,l),r?h.onload=function(){s.loadImage(o,e,t,a,l)}:this.loadImage(o,e,t,a,l),o.restore()}},n.prototype.image=function(t,e,i,r,s,o,a){t.beginPath();var l=e.width,h=e.height,c=s,d=o,u=0,f=0;if(a&&"None"!==a.alignment){var p=a.alignment.toLowerCase().substr(1,3),g=a.alignment.toLowerCase().substr(5,3);if("Slice"===a.scale){var v=function(){u=c,f=h*c/l},y=function(){u=l*d/h,f=d};c>d?(v(),d>f&&y()):c===d?l>h?y():v():(y(),c>u&&v());var S=this.getSliceOffset(p,u,c,l),b=this.getSliceOffset(g,f,d,h),M=l-S,w=h-b,C=u-S*(u/l),D=f-b*(f/h),A=Tt("canvas",{width:s.toString(),height:o.toString()});A.getContext("2d").drawImage(e,S,b,M,w,0,0,C,D),t.drawImage(A,i,r,s,o)}else if("Meet"===a.scale){var P=h/l,L=d/c;f=L>P?c*P:d,i+=this.getMeetOffset(p,u=L>P?c:d/P,c),r+=this.getMeetOffset(g,f,d),t.drawImage(e,0,0,l,h,i,r,u,f)}else t.drawImage(e,i,r,s,o)}else if("None"!==a.flip){var O=1,N=1;("Horizontal"===a.flip||"Both"===a.flip)&&(i=-i,s=-s,O=-1),("Vertical"===a.flip||"Both"===a.flip)&&(r=-r,o=-o,N=-1),t.scale(O,N),t.drawImage(e,i,r,s,o)}else t.drawImage(e,i,r,s,o);t.closePath()},n.prototype.getSliceOffset=function(t,e,i,r){switch(t){case"min":default:return 0;case"mid":return(e-i)/2*r/e;case"max":return(e-i)*r/e}},n.prototype.getMeetOffset=function(t,e,i){var r=Math.max(e,i),s=Math.min(e,i);switch(t){case"min":default:return 0;case"mid":return(r-s)/2;case"max":return r-s}},n.prototype.m=function(t){return Math.sqrt(Math.pow(t[0],2)+Math.pow(t[1],2))},n.prototype.r=function(t,e){return(t[0]*e[0]+t[1]*e[1])/(this.m(t)*this.m(e))},n.prototype.a=function(t,e){return(t[0]*e[1]t.width&&("Ellipsis"===t.textOverflow||"Clip"===t.textOverflow)&&"NoWrap"===t.textWrapping?0:.5*t.width:"right"===t.textAlign&&(c=1*t.width),s.x=t.x+c+(e?e.x:0),s.y=a+d-r.height/2,s},n}(),db=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Vi=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Eoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return db(t,n),Vi([I("")],t.prototype,"source",void 0),Vi([I("transparent")],t.prototype,"color",void 0),Vi([I("None")],t.prototype,"scale",void 0),Vi([I("None")],t.prototype,"align",void 0),t}(Ee),Doe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return db(t,n),Vi([I("Page")],t.prototype,"mode",void 0),Vi([I("PageSettings")],t.prototype,"region",void 0),Vi([re({top:25,bottom:25,left:25,right:25},Jn)],t.prototype,"margin",void 0),Vi([I(!1)],t.prototype,"canZoomIn",void 0),Vi([I(void 0)],t.prototype,"customBounds",void 0),Vi([I(!1)],t.prototype,"canFit",void 0),t}(Ee),xoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return db(t,n),Vi([I(null)],t.prototype,"width",void 0),Vi([I(null)],t.prototype,"height",void 0),Vi([re({},Jn)],t.prototype,"margin",void 0),Vi([I("Landscape")],t.prototype,"orientation",void 0),Vi([I("Infinity")],t.prototype,"boundaryConstraints",void 0),Vi([re({},Eoe)],t.prototype,"background",void 0),Vi([I(!1)],t.prototype,"multiplePage",void 0),Vi([I(!1)],t.prototype,"showPageBreaks",void 0),Vi([re({},Doe)],t.prototype,"fitOptions",void 0),t}(Ee),Toe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return db(t,n),Vi([I(0)],t.prototype,"horizontalOffset",void 0),Vi([I(0)],t.prototype,"verticalOffset",void 0),Vi([I(1)],t.prototype,"currentZoom",void 0),Vi([I(0)],t.prototype,"viewPortWidth",void 0),Vi([I(0)],t.prototype,"viewPortHeight",void 0),Vi([I(.2)],t.prototype,"minZoom",void 0),Vi([I(30)],t.prototype,"maxZoom",void 0),Vi([I("Diagram")],t.prototype,"scrollLimit",void 0),Vi([I()],t.prototype,"scrollableArea",void 0),Vi([I(!1)],t.prototype,"canAutoScroll",void 0),Vi([I(100)],t.prototype,"autoScrollFrequency",void 0),Vi([re({left:15,right:15,top:15,bottom:15},Jn)],t.prototype,"autoScrollBorder",void 0),Vi([re({left:0,right:0,top:0,bottom:0},Jn)],t.prototype,"padding",void 0),Vi([I(.2)],t.prototype,"zoomFactor",void 0),t}(Ee),Aoe=function(){function n(){this.services={}}return n.prototype.register=function(t,e){this.services[""+t]=e},n.prototype.getService=function(t){return this.services[""+t]},n}(),WF=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),ya=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},YF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return WF(t,n),ya([I("lightgray")],t.prototype,"lineColor",void 0),ya([I("")],t.prototype,"lineDashArray",void 0),ya([I([1.25,18.75,.25,19.75,.25,19.75,.25,19.75,.25,19.75])],t.prototype,"lineIntervals",void 0),ya([I([1,19,.5,19.5,.5,19.5,.5,19.5,.5,19.5])],t.prototype,"dotIntervals",void 0),ya([I([20])],t.prototype,"snapIntervals",void 0),t}(Ee),Loe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return WF(t,n),ya([re({},YF)],t.prototype,"horizontalGridlines",void 0),ya([re({},YF)],t.prototype,"verticalGridlines",void 0),ya([I(ei.All)],t.prototype,"constraints",void 0),ya([I(5)],t.prototype,"snapAngle",void 0),ya([I("Lines")],t.prototype,"gridType",void 0),ya([I(5)],t.prototype,"snapObjectDistance",void 0),ya([I("#07EDE1")],t.prototype,"snapLineColor",void 0),t}(Ee),QF=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),el=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},GF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return QF(t,n),el([I(5)],t.prototype,"interval",void 0),el([I(100)],t.prototype,"segmentWidth",void 0),el([I("Horizontal")],t.prototype,"orientation",void 0),el([I("RightOrBottom")],t.prototype,"tickAlignment",void 0),el([I("red")],t.prototype,"markerColor",void 0),el([I(25)],t.prototype,"thickness",void 0),el([I(null)],t.prototype,"arrangeTick",void 0),t}(Ee),Noe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return QF(t,n),el([I(!1)],t.prototype,"showRulers",void 0),el([I(!0)],t.prototype,"dynamicGrid",void 0),el([re({orientation:"Horizontal"},GF)],t.prototype,"horizontalRuler",void 0),el([re({orientation:"Vertical"},GF)],t.prototype,"verticalRuler",void 0),t}(Ee),Ooe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),XF=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},koe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Ooe(t,n),XF([I("")],t.prototype,"property",void 0),XF([I("")],t.prototype,"field",void 0),t}(Ee),bT=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),ln=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},qF=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return bT(t,n),ln([I("")],t.prototype,"read",void 0),ln([I("")],t.prototype,"create",void 0),ln([I("")],t.prototype,"update",void 0),ln([I("")],t.prototype,"destroy",void 0),ln([I()],t.prototype,"customFields",void 0),t}(Ee),Poe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return bT(t,n),ln([I("")],t.prototype,"id",void 0),ln([I("")],t.prototype,"sourceID",void 0),ln([I("")],t.prototype,"targetID",void 0),ln([I(null)],t.prototype,"sourcePointX",void 0),ln([I(null)],t.prototype,"sourcePointY",void 0),ln([I(null)],t.prototype,"targetPointX",void 0),ln([I(null)],t.prototype,"targetPointY",void 0),ln([I(null)],t.prototype,"dataManager",void 0),ln([re({},qF)],t.prototype,"crudAction",void 0),t}(Ee),zoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return bT(t,n),ln([I("")],t.prototype,"id",void 0),ln([I(null)],t.prototype,"dataManager",void 0),ln([I(null)],t.prototype,"dataSource",void 0),ln([I("")],t.prototype,"root",void 0),ln([I("")],t.prototype,"parentId",void 0),ln([I()],t.prototype,"doBinding",void 0),ln([Bt([],koe)],t.prototype,"dataMapSettings",void 0),ln([re({},qF)],t.prototype,"crudAction",void 0),ln([re({},Poe)],t.prototype,"connectionDataSource",void 0),t}(Ee),$F=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Cr=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},Roe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return $F(t,n),Cr([I("LeftInFlow")],t.prototype,"yesBranchDirection",void 0),Cr([I("RightInFlow")],t.prototype,"noBranchDirection",void 0),Cr([I(["Yes","True"])],t.prototype,"yesBranchValues",void 0),Cr([I(["No","False"])],t.prototype,"noBranchValues",void 0),t}(Ee),Hoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return $F(t,n),Cr([I("")],t.prototype,"fixedNode",void 0),Cr([I(30)],t.prototype,"horizontalSpacing",void 0),Cr([I("SamePoint")],t.prototype,"connectionPointOrigin",void 0),Cr([I("Nonlinear")],t.prototype,"arrangement",void 0),Cr([I(30)],t.prototype,"verticalSpacing",void 0),Cr([I(30)],t.prototype,"maxIteration",void 0),Cr([I(40)],t.prototype,"springFactor",void 0),Cr([I(50)],t.prototype,"springLength",void 0),Cr([re({left:50,top:50,right:0,bottom:0},Jn)],t.prototype,"margin",void 0),Cr([I("Auto")],t.prototype,"horizontalAlignment",void 0),Cr([I("Auto")],t.prototype,"verticalAlignment",void 0),Cr([I("TopToBottom")],t.prototype,"orientation",void 0),Cr([I("Auto")],t.prototype,"connectionDirection",void 0),Cr([I("Default")],t.prototype,"connectorSegments",void 0),Cr([I("None")],t.prototype,"type",void 0),Cr([I()],t.prototype,"getLayoutInfo",void 0),Cr([I()],t.prototype,"layoutInfo",void 0),Cr([I()],t.prototype,"getBranch",void 0),Cr([I()],t.prototype,"bounds",void 0),Cr([I(!0)],t.prototype,"enableAnimation",void 0),Cr([I(!1)],t.prototype,"enableRouting",void 0),Cr([I("")],t.prototype,"root",void 0),Cr([re({},Roe)],t.prototype,"flowchartLayoutSettings",void 0),t}(Ee),Boe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),ZF=function(n){function t(e,i){var r=n.call(this,e,!0)||this;return r.oldValue=null,r.endPoint=i,r}return Boe(t,n),t.prototype.mouseDown=function(e){var i,r=!0;if(e.source&&e.source.connectors&&(i=e.source.connectors[0]),e.info&&e.actualObject&&(r=e.info.ctrlKey&&"Orthogonal"!==e.actualObject.type),i&&r){this.inAction=!0,this.undoElement=$(e.source),n.prototype.mouseDown.call(this,e);for(var s=0;s0)1!==s&&this.removePrevSegment(i,s);else if(a){var l=R.distancePoints(a.points[0],a.points[1]);Math.abs(a.length||0===a.length?a.length:l)<=5&&this.removeNextSegment(i,s)}this.commandHandler.updateEndPoint(i,r),i.selectedSegmentIndex=0}if(this.undoElement){var c=$(e.source);this.commandHandler.addHistoryEntry({type:"SegmentChanged",redoObject:c,undoObject:this.undoElement,category:"Internal"})}if(i.isBezierEditing&&(i.isBezierEditing=!1),this.prevPosition!==this.startPosition){var u={source:i,state:"Completed",oldValue:this.oldValue,newValue:$(this.selectedSegment),cancel:!1,segment:this.selectedSegment};this.commandHandler.triggerEvent(Ce.segmentChange,u)}n.prototype.mouseUp.call(this,e)},t.prototype.removePrevSegment=function(e,i){var r=e.segments[i-2],s=e.segments[i+1];if(s&&!((s.length||0===s.length?s.length:R.distancePoints(s.points[0],s.points[1]))<=5)){var a=e.segments.slice(i-1,i+1),l={element:e,removeSegments:a,type:"Removal",cancel:!1};if(this.commandHandler.triggerEvent(Ce.segmentCollectionChange,l),!l.cancel){var h=e.segments[i+1];e.segments.splice(i-1,2);var c=this.selectedSegment;"Left"===c.direction||"Right"===c.direction?(r.points[r.points.length-1].x=h.points[0].x,h.points[0].y=r.points[r.points.length-1].y):(r.points[r.points.length-1].y=h.points[0].y,h.points[0].x=r.points[r.points.length-1].x),(c.length||0===c.length)&&this.findSegmentDirection(r),this.findSegmentDirection(h)}}},t.prototype.findSegmentDirection=function(e){e.direction&&(e.length||0===e.length)&&(e.length=R.distancePoints(e.points[0],e.points[e.points.length-1]),e.direction=R.direction(e.points[0],e.points[e.points.length-1]))},t.prototype.removeNextSegment=function(e,i){var l,h,r=this.selectedSegment,s=e.segments[i-1],o=e.segments[i+2],a=e.segments[i+1];if(a.length||0===a.length?(l=e.segments.slice(i,2),h={element:e,removeSegments:l,type:"Removal",cancel:!1},this.commandHandler.triggerEvent(Ce.segmentCollectionChange,h={element:e,removeSegments:l,type:"Removal",cancel:!1}),h.cancel||(e.segments.splice(i,2),"Top"===r.direction||"Bottom"===r.direction?(o.points[0].y=r.points[0].y,s.points[s.points.length-1].x=o.points[0].x):(o.points[0].x=r.points[0].x,s.points[s.points.length-1].y=o.points[0].y))):(l=e.segments.slice(i+1,1),this.commandHandler.triggerEvent(Ce.segmentCollectionChange,h={element:e,removeSegments:l,type:"Removal",cancel:!1}),h.cancel||(e.segments.splice(i+1,1),"Top"===r.direction||"Bottom"===r.direction?s.points[s.points.length-1].x=a.points[a.points.length-1].x:s.points[s.points.length-1].y=a.points[a.points.length-1].y,this.findSegmentDirection(s),r.length=r.direction=null)),s&&o&&!h.cancel&&(s.length=R.distancePoints(s.points[0],o.points[0]),s.direction=R.direction(s.points[0],o.points[0]),o.length||0===o.length)){o.length=R.distancePoints(s.points[s.points.length-1],o.points[o.points.length-1]);var c=s.points,d=o.points;o.direction=R.direction(c[c.length-1],d[d.length-1])}},t.prototype.addOrRemoveSegment=function(e,i,r){for(var s,o,a=[],l={segments:e.segments},h=0;h0?"Bottom":"Top":r>0?"Right":"Left",length:i.points[0].x===i.points[1].x?s:r},!0)),l.push(new wi(e,"segments",{type:"Orthogonal",direction:c,length:h/2},!0));var f={element:e,addSegments:l,type:"Addition",cancel:!1};return this.commandHandler.triggerEvent(Ce.segmentCollectionChange,f),f.cancel||(e.segments=l.concat(e.segments),a=o+2),a},t.prototype.insertFirstSegment=function(e,i,r,s,o){var a,l,d,u,h=[];if(e.sourcePortID&&i.length&&e.segments[0].points.length>2)for(var f=void 0,p=0;p0?"Bottom":"Top":r>0?"Right":"Left"),f=u,h.push(u)}else h.push(new wi(e,"segments",{type:"Orthogonal",direction:i.direction,length:i.length/3},!0)),"Bottom"===i.direction||"Top"===i.direction?(l=Math.abs(r),a=r>0?"Right":"Left"):(l=Math.abs(s),a=s>0?"Bottom":"Top"),u=new wi(e,"segments",{type:"Orthogonal",direction:a,length:l},!0),h.push(u);var y={element:e,addSegments:h,type:"Addition",cancel:!1};if(this.commandHandler.triggerEvent(Ce.segmentCollectionChange,y),!y.cancel){if(e.sourcePortID&&i.length&&e.segments[0].points.length>2)e.segments.splice(0,1),d=1;else{var S=e.segments[1];S&&S.length&&(S.length=a!==S.direction?S.length+l:S.length-l),d=2,i.length=2*i.length/3}e.segments=h.concat(e.segments)}return d},t.prototype.updateAdjacentSegments=function(e,i,r,s){var o=e.segments[parseInt(i.toString(),10)],a=o.points[o.points.length-1],h=!0;"Orthogonal"===o.type&&(o.points[0]=o.points[0],o.points[o.points.length-1]=a,e.segments[i-1]&&(h=this.updatePreviousSegment(r,s,e,i)),e.segments.length-1>i&&h&&this.updateNextSegment(e,o,e.segments[i+1],r,s))},t.prototype.addTerminalSegment=function(e,i,r,s,o){var l,h,c,d,a=e.segments.indexOf(i),u=[],f=e.segments.pop(),p=e.segments[e.segments.length-1];l=p&&"Orthogonal"===p.type?p:null;for(var g=0;g0&&"Left"===o.direction?c.middleLeft:c.middleRight,o.length>c.width/2?Math.abs(a.length)0&&"Top"===o.direction?c.topCenter:c.bottomCenter,o.length>c.height/2?Math.abs(a.length)1)for(var a=0,l=this.diagram.views;a0)for(var e=t===Ce.onUserHandleMouseLeave?this.previousAction:this.action,i={element:void 0},r=0;r0)for(var r={element:void 0},s=void 0,o=void 0,a=0;a-1&&(o=s,this.previousTarget=i,this.targetItem=e),o===e.fixedUserHandles[parseInt(a.toString(),10)].id&&(r.element=e.fixedUserHandles[parseInt(a.toString(),10)],this.userHandle(t,a,r,e))},n.prototype.mouseDown=function(t){var e=this;if("touchstart"===t.type&&(this.timeOutTapHold=setTimeout(function(){("Select"===e.action||"Drag"===e.action)&&e.mouseMove(t,void 0)},500)),!0!==this.inAction||!(this.tool instanceof WI||this.tool instanceof pa)){this.focus=!0;var i=t.touches,r=!!document.getElementsByClassName("e-dragclone")[0];if(this.isMouseOnScrollBar(t)&&!r)return this.isScrolling=!0,void t.preventDefault();if(this.checkFixedUserHandleEvent(Ce.onFixedUserHandleMouseDown,this.targetItem,this.previousTarget),this.checkUserHandleEvent(Ce.onUserHandleMouseDown),!this.checkEditBoxAsTarget(t)&&jv(this.diagram)||Lc(this.diagram)&&!RI(this.diagram))if(("Select"===this.action||"Drag"===this.action)&&this.diagram.updatePortVisibility(this.hoverElement,Gt.Hover,!0),!(this.tool instanceof zl||this.tool instanceof Rl)||2!==t.button&&2!==t.buttons)if(!0===this.inAction&&!0===this.isMouseDown&&(this.tool instanceof zl||this.tool instanceof Rl))this.isMouseDown=!0,this.eventArgs={},this.getMouseEventArgs(this.currentPosition,this.eventArgs),this.eventArgs.position=this.currentPosition,this.tool.mouseDown(this.eventArgs);else{this.isMouseDown=!0,this.currentPosition=this.prevPosition=this.getMousePosition(t),this.eventArgs={},this.diagram.textEditing&&!this.isMouseOnScrollBar(t)&&(this.diagram.endEdit(),this.diagram.textEditing=!1,"Canvas"===this.diagram.mode&&1!==this.diagram.scroller.currentZoom&&this.diagram.refreshDiagramLayer());var o=this.getTargetElement();this.action=this.diagram.findActionToBeDone(o.obj,o.sourceElement,this.currentPosition,o.target);var a=this.isMetaKey(t);a&&t.shiftKey&&this.diagram.connectorEditingToolModule?this.action="SegmentEnd":(a||t.shiftKey)&&(_v(this.diagram)||Uv(this.diagram))&&(this.action="Select"),this.tool=this.diagram.getTool(this.action),this.tool||(this.action="Select",this.tool=this.diagram.getTool(this.action)),this.getMouseEventArgs(this.currentPosition,this.eventArgs),(a||t.shiftKey)&&(this.eventArgs.info=a&&t.shiftKey?{ctrlKey:a,shiftKey:t.shiftKey}:{ctrlKey:!0}),this.eventArgs.position=this.currentPosition;var h=this.diagram.selectedItems.nodes;if(this.tool.mouseDown(this.eventArgs),this.diagram.selectedItems.canToggleSelection&&h&&this.diagram.selectedItems.nodes&&this.tool instanceof fa)for(var c=0;c=2&&(this.touchStartList=HF(this.touchStartList,0,i)),i||t.preventDefault())}else this.inAction=!1,this.tool.mouseUp(this.eventArgs);!this.isForeignObject(t.target)&&!this.isForeignObject(t.target,!0)&&!i&&t.preventDefault()}},n.prototype.mouseMoveExtend=function(t,e){(this.tool instanceof zl||this.tool instanceof Rl)&&this.tool.mouseMove(this.eventArgs),this.diagram.scrollSettings.canAutoScroll?this.checkAutoScroll(t):this.blocked||this.tool.mouseMove(this.eventArgs),this.eventArgs.target&&(this.hoverElement=this.eventArgs.target);var i=!((this.eventArgs.target instanceof te||this.eventArgs.target instanceof de)&&(e instanceof te||e instanceof de));this.tool instanceof kd&&this.diagram.updatePortVisibility(this.hoverElement instanceof te||this.hoverElement instanceof de?this.hoverElement:this.hoverNode,Gt.Connect|Gt.Hover,i),this.hoverElement instanceof te&&this.hoverNode instanceof te&&this.hoverNode&&this.hoverNode.id!==this.hoverElement.id&&this.diagram.updatePortVisibility(this.hoverNode,Gt.Connect|Gt.Hover,!0),this.hoverElement instanceof de&&this.hoverElement.ports.length>0&&this.diagram.updatePortVisibility(this.hoverElement,Gt.Connect|Gt.Hover,!0),this.previousElement instanceof te&&this.hoverElement&&this.previousElement.id!==this.hoverElement.id&&this.diagram.updatePortVisibility(this.previousElement,Gt.Connect|Gt.Hover,!0),this.previousElement=this.hoverElement,""!==this.diagram.tooltip.content&&(this.hoverElement=null),this.hoverNode=i?null:e},n.prototype.checkAction=function(t){if("LabelSelect"===this.action&&this.eventArgs.sourceWrapper&&(this.eventArgs.sourceWrapper instanceof li||this.eventArgs.sourceWrapper instanceof es)){var e=this.commandHandler.findTarget(this.eventArgs.sourceWrapper,this.eventArgs.source);!_r(this.diagram,e,!1,this.eventArgs.sourceWrapper)&&ro(e)&&(this.action="LabelDrag",this.tool=this.getTool(this.action),this.tool.mouseDown(this.initialEventArgs))}else ro(t)&&xd(t)&&this.initialEventArgs&&this.initialEventArgs.source&&"Select"===this.action&&(!_r(this.diagram,this.eventArgs.source,!1)&&this.eventArgs.source instanceof ti&&this.getMouseEventArgs(this.currentPosition,this.eventArgs),(!(t instanceof de)||t instanceof de&&!(wr(this.currentPosition,t.sourcePoint,t.hitPadding)||wr(this.currentPosition,t.targetPoint,t.hitPadding)))&&(this.action="Drag"),this.tool=this.getTool(this.action),this.tool.mouseDown(this.initialEventArgs))},n.prototype.isSwimlaneElements=function(t){return!(t&&(t.isLane||t.isPhase||t.isHeader))},n.prototype.canShowTouchTooltip=function(t){return!!("touchstart"===t.type&&this.diagram.tool&ni.SingleSelect&&this.diagram.tool&ni.ZoomPan)&&(this.isMouseDown=!1,!0)},n.prototype.mouseMove=function(t,e){if(this.focus=!0,"touchmove"===t.type&&(this.touchArgs={target:t.target,type:"touchmove"}),this.isScrolling)t.preventDefault();else if(jv(this.diagram)||Lc(this.diagram)&&!RI(this.diagram)){this.currentPosition=this.getMousePosition(t);var i=this.diagram.findObjectsUnderMouse(this.currentPosition),r=this.diagram.findObjectUnderMouse(i,this.action,this.inAction);!function Gne(n,t){n.rulerSettings.showRulers&&(n.hRuler.drawRulerMarker(n.hRuler.element,t,n.scroller.horizontalOffset),n.vRuler.drawRulerMarker(n.vRuler.element,t,n.scroller.verticalOffset))}(this.diagram,this.currentPosition);var s=!1,o=void 0;if("touchmove"===t.type&&(e=t.touches)&&e.length>1&&(this.touchMoveList=HF(this.touchMoveList,0,e),"PinchZoom"!==this.action&&(s=!0)),!1===R.equals(this.currentPosition,this.prevPosition)||this.inAction||this.canShowTouchTooltip(t)){if(!1===this.isMouseDown||s){this.eventArgs={};var a=null,l=void 0;if(null!==r){if((a=this.diagram.findElementUnderMouse(r,this.currentPosition,this.diagram))&&(l=this.commandHandler.findTarget(a,r)),(l instanceof Kn||l instanceof Or)&&(l.tooltip&&""!==l.tooltip.content||(l=r)),l!==this.hoverElement){var h=this.getContent();this.hoverElement&&"Auto"===this.hoverElement.tooltip.openOn&&""!==h&&this.elementLeave(),this.diagram.updatePortVisibility(this.hoverElement,Gt.Hover,!0),r instanceof te&&(this.hoverNode=r);var c=!0;!this.isSwimlaneElements(r)&&this.hoverElement&&this.isSwimlaneElements(this.hoverElement)&&(c=!1),this.hoverElement=c?r:this.hoverElement;var d,u=void 0;(d=this.diagram.findElementUnderMouse(r,this.currentPosition,this.diagram))instanceof Ze&&((u=this.commandHandler.findTarget(d,r))instanceof Es||u instanceof Tc)&&this.hoverElement.constraints&ai.ToolTip&&(this.hoverElement=u);var f=void 0;d instanceof li&&((f=this.commandHandler.findTarget(d,r))instanceof Kn||f instanceof Or)&&f.constraints&Nr.Tooltip&&(this.hoverElement=f),c?this.elementEnter(this.currentPosition,!1):this.hoverElement=r}else this.hoverElement&&this.hoverElement===l&&this.hoverElement.tooltip.content&&void 0!==this.diagram.tooltipObject&&"Mouse"===this.hoverElement.tooltip.relativeMode&&this.setTooltipOffset(this.currentPosition);a&&(o=this.commandHandler.findTarget(a,r))}this.action=this.diagram.findActionToBeDone(r,a,this.currentPosition,o),this.checkFixedUserHandleEvent(Ce.onFixedUserHandleMouseEnter,r,a),this.checkUserHandleEvent(Ce.onUserHandleMouseEnter),this.checkPreviousAction(),this.getMouseEventArgs(this.currentPosition,this.eventArgs),this.tool=this.getTool(this.action),this.mouseEvents(),this.tool instanceof pa||this.tool instanceof Rl||this.tool instanceof zl?this.tool.mouseMove(this.eventArgs):e&&this.tool instanceof Kv&&this.tool.mouseDown(this.eventArgs),this.updateCursor(),this.renderUmlHighLighter(this.eventArgs);var p=!1;this.hoverElement&&!(this.tool instanceof Kv)&&r instanceof te&&this.isSwimlaneElements(r)&&(0===this.diagram.selectedItems.nodes.length||!_r(this.diagram,this.hoverElement))||this.hoverElement instanceof de||(p=!0),this.hoverElement&&!(this.tool instanceof Kv)&&r instanceof de&&(0===this.diagram.selectedItems.connectors.length||!_r(this.diagram,this.hoverElement))||this.hoverElement instanceof te||(p=!0),this.diagram.updatePortVisibility(this.hoverElement,Gt.Hover,p);var g=this.getContent();null===r&&this.hoverElement&&"Auto"===this.hoverElement.tooltip.openOn&&g&&(this.hoverElement=null,this.elementLeave()),s=!1}else{this.eventArgs.position=this.currentPosition,"Drag"===this.action&&!_r(this.diagram,this.eventArgs.source,!1)&&this.eventArgs.source instanceof ti&&this.getMouseEventArgs(this.currentPosition,this.eventArgs),this.mouseEvents(),(t.ctrlKey||t.shiftKey)&&(this.eventArgs.info=t.ctrlKey&&t.shiftKey?{ctrlKey:t.ctrlKey,shiftKey:t.shiftKey}:{ctrlKey:!0}),this.checkAction(r);var y=this.getConnectorPadding(this.eventArgs);this.getMouseEventArgs(this.currentPosition,this.eventArgs,this.eventArgs.source,y),this.updateCursor(),this.inAction=!0,this.initialEventArgs=null,("Drag"===this.action||"Rotate"===this.action)&&(this.diagram.diagramActions=this.diagram.diagramActions|ee.Interactions);var S=this.diagram.scroller.getPageBounds();this.mouseMoveExtend(t,r);var b=this.diagram.scroller.getPageBounds();if(r&&(S.width!==b.width||S.height!==b.height||S.x!==b.x||S.y!==b.y)&&this.diagram.views&&this.diagram.views.overview){var M=this.diagram.views.overview;M.updateView(M)}}this.prevPosition=this.currentPosition,this.isForeignObject(t.target,!0)||t.preventDefault()}}},n.prototype.getContent=function(){var i,t=this.hoverElement instanceof te&&this.hoverElement.constraints&ie.Tooltip||this.hoverElement instanceof de&&this.hoverElement.constraints&qe.Tooltip||(this.hoverElement instanceof Es||this.hoverElement instanceof Tc)&&this.hoverElement.constraints&ai.ToolTip||(this.hoverElement instanceof Kn||this.hoverElement instanceof Or)&&this.hoverElement.constraints&Nr.Tooltip,e=this.hoverElement;e instanceof te&&e.children&&e.children.length>0&&(i=this.findIntersectChild(e));var r=t?this.hoverElement.tooltip.content:this.diagram.tooltip.content;return i?i.tooltip.content:r},n.prototype.findIntersectChild=function(t){for(var e,i=new Ne(this.currentPosition.x,this.currentPosition.y,8,8),r=0;r1&&1===t.which&&!function qre(n){return!!(n&ee.PreventClearSelection)}(this.diagram.diagramActions)&&(c=!1,this.commandHandler.clearSelection()),(!_r(this.diagram,h)||!c)&&(this.commandHandler.selectObjects([h],void 0,a),this.diagram.selectedItems.canToggleSelection)){var d=this.diagram.selectedItems.nodes;d?d[0].parentObj instanceof Hd&&(s=!0):this.diagram.selectedItems.connectors.length>0&&(s=!0)}}var u=!1,f=this.updateContainerProperties(),p=void 0;if(this.addUmlNode(),this.inAction=!1,this.isMouseDown=!1,this.diagram.selectedObject.helperObject&&(p=this.updateContainerBounds()),this.tool&&(this.tool.prevPosition||this.tool instanceof X3)){this.eventArgs.position=this.currentPosition;var g=this.getConnectorPadding(this.eventArgs);this.getMouseEventArgs(this.currentPosition,this.eventArgs,this.eventArgs.source,g);var v=this.isMetaKey(t);if((v||t.shiftKey)&&(this.eventArgs.info=v&&t.shiftKey?{ctrlKey:v,shiftKey:t.shiftKey}:{ctrlKey:!0}),this.diagram.diagramActions&ee.Interactions&&(this.diagram.diagramActions=this.diagram.diagramActions&~ee.Interactions),this.eventArgs.clickCount=t.detail,this.diagram.selectedObject.helperObject&&(this.tool instanceof fa||this.tool instanceof Pd)){if(this.diagram.selectedObject.actualObject&&""!==this.diagram.selectedObject.actualObject.parentId){var S=this.diagram.getObject(this.diagram.selectedObject.actualObject.parentId);S&&S.isLane&&(this.commandHandler.isContainer=!0)}(u=this.diagram.lineRoutingModule&&this.diagram.nameTable.helper&&this.eventArgs.target&&this.eventArgs.target.isLane&&(this.eventArgs.source instanceof ti&&this.eventArgs.source.nodes.length>0&&""===this.eventArgs.source.nodes[0].parentId||""===this.eventArgs.source.parentId))&&(this.diagram.diagramActions=this.diagram.diagramActions|ee.PreventLaneContainerUpdate),this.tool.mouseUp(this.eventArgs,f.isPreventHistory)}else{if(this.diagram.selectedItems.canToggleSelection){var b=void 0,M=void 0;if(this.diagram.selectedItems.nodes.length>0)for(var w=0;w1&&D[0].id===i[parseInt(w.toString(),10)].id||r.length>0)&&(M=!0);!this.isSwimlaneSelected&&!s&&!M&&this.tool instanceof fa&&"Select"===this.currentAction&&(!b||this.diagram.selectedItems.connectors.length>0)&&this.commandHandler.clearSelection(!0)}this.isSwimlaneSelected=!1,this.tool.mouseUp(this.eventArgs),this.diagram.checkMenu&&(-1!==window.navigator.userAgent.indexOf("Linux")||-1!==window.navigator.userAgent.indexOf("X11"))&&(!t.pageY&&t instanceof TouchEvent&&t.changedTouches?(window.getSelection().removeAllRanges(),this.diagram.contextMenuModule.contextMenu.open(t.changedTouches[0].pageY,t.changedTouches[0].pageX,this.diagram.element),t.preventDefault()):this.diagram.contextMenuModule.contextMenu.open(t.pageY,t.pageX,this.diagram.element),this.diagram.checkMenu=!1)}f.hasStack&&this.diagram.endGroupAction()}if(p&&this.diagram.endGroupAction(),this.updateContainerBounds(!0),2!==this.eventArgs.clickCount&&(this.commandHandler.updateSelectedNodeProperties(this.eventArgs.source),u)){this.diagram.diagramActions=this.diagram.diagramActions&~ee.PreventLaneContainerUpdate;var A=this.eventArgs.source instanceof ti?this.eventArgs.source.nodes:[this.eventArgs.source];if(A)for(w=0;w0&&!N&&this.diagram.renderSelector(!0),!this.inAction&&!this.diagram.currentSymbol&&this.eventArgs){var T=this.getTargetElement();this.diagram.tool!==ni.ZoomPan&&this.diagram.triggerEvent(Ce.click,{element:T.target instanceof Es?T.target:this.eventArgs.source||this.diagram,position:this.eventArgs.position,count:t.detail,actualObject:this.eventArgs.actualObject,button:0===t.button?"Left":1===t.button?"Middle":"Right"})}this.eventArgs={}}this.diagram.diagramActions=this.diagram.diagramActions&~ee.PreventLaneContainerUpdate,e&&this.updateAnnotation(this.diagram.selectedItems),this.previousElement=null,this.eventArgs={},this.diagram.commandHandler.removeStackHighlighter()},n.prototype.isSwimlaneChild=function(t){if(t.shape&&"SwimLane"!==t.shape.type){var e=this.diagram.nameTable[t.parentId];if(!e)return!1;var i=e.parentId?this.diagram.nameTable[e.parentId]:e;return i&&i.shape&&"SwimLane"===i.shape.type}return!1},n.prototype.updateAnnotation=function(t){var e=t.nodes;if(e.length>0)for(var i=0;i0&&(a+=1),h.isPhase){l="Horizontal"===r.orientation?this.currentPosition.x-e.wrapper.bounds.x:this.currentPosition.y-(e.wrapper.bounds.y+r.header.height);var g={id:Qe(),offset:l,header:{annotation:{content:void 0===h.phases[0].header?"Phase":h.phases[0].header.annotation.content,style:void 0===h.phases[0].header?{}:h.phases[0].header.annotation.style}},style:void 0===h.phases[0]?{}:h.phases[0].style};this.diagram.addPhases(e,[g])}else{var v={id:Qe(),style:h.lanes[0].style,header:{annotation:{content:h.lanes[0].header.annotation.content,style:h.lanes[0].header.annotation.style},style:h.lanes[0].header.style}};if("Horizontal"===h.orientation?v.height=h.lanes[0].height:v.width=h.lanes[0].width,"Horizontal"===r.orientation?(s=i.rowIndex?i.rowIndex:this.diagram.nameTable[i.parentId].rowIndex,i.wrapper.offsetYs)v.header.width=r.lanes[parseInt(s.toString(),10)].header.width,v.header.height=r.lanes[parseInt(s.toString(),10)].header.height;else{var S=void 0;S="Horizontal"===r.orientation?i.rowIndex<3?0:s-a-1:s-1,v.header.width=r.lanes[parseInt(S.toString(),10)].header.width,v.header.height=r.lanes[parseInt(S.toString(),10)].header.height}p&&("height"===p?(v.width=v.height,delete v.height):(v.height=v.width,delete v.width)),this.diagram.addLanes(e,[v],"Horizontal"===r.orientation?s-a:s)}this.commandHandler.select(e)}else if(h.isLane){var b={id:Qe(),width:t.width,height:t.height,addInfo:t.addInfo,shape:{type:"SwimLane",header:{annotation:{content:void 0===h.header?"Header":h.header.annotation.content,style:void 0===h.header?{}:h.header.annotation.style},height:50,style:h.header?h.header.style:h.lanes[0].header.style},phases:[{id:Qe(),header:{annotation:{content:void 0===h.phases||void 0===h.phases[0].header?"Phase":h.phases[0].header.annotation.content,style:void 0===h.phases||void 0===h.phases[0].header?{}:h.phases[0].header.annotation.style},style:void 0===h.phases||void 0===h.phases[0].header?{}:h.phases[0].header.style},style:void 0===h.phases?{}:h.phases[0].style}],lanes:[{id:Qe(),height:t.height,width:t.width,style:h.lanes[0].style,header:{annotation:{content:h.lanes[0].header.annotation.content,style:h.lanes[0].header.annotation.style},style:h.lanes[0].header.style}}],orientation:h.orientation}};"Vertical"===h.orientation&&(b.width+=20),b.offsetX=this.currentPosition.x+b.width/2,b.offsetY=this.currentPosition.y+b.height/2,b.style=t.style,this.diagram.add(b)}},n.prototype.mouseLeave=function(t){this.tool&&this.inAction&&this.tool.mouseLeave(this.eventArgs),this.diagram.selectedObject.helperObject&&(this.updateContainerProperties(),this.updateContainerBounds()&&this.diagram.endGroupAction()),this.eventArgs&&this.eventArgs.source&&(this.diagram.updatePortVisibility(this.eventArgs.source,Gt.Hover,!0),this.hoverElement=null),this.eventArgs&&!this.eventArgs.source&&this.hoverElement&&(this.hoverElement=null),this.tool instanceof kd&&this.eventArgs&&this.eventArgs.target&&this.eventArgs.target instanceof te&&(this.diagram.updatePortVisibility(this.eventArgs.target,Gt.Hover|Gt.Connect,!0),this.hoverElement=null);var i=this.diagram.selectedItems;i&&i.wrapper&&(am(this.diagram,i)||this.diagram.renderSelector(!0)),(this.diagram.diagramActions&ee.Interactions||this.diagram.diagramActions&ee.ToolAction)&&(this.diagram.diagramActions=this.diagram.diagramActions&~ee.ToolAction),this.isMouseDown=!1,this.focus=!1,this.touchStartList=null,this.touchMoveList=null,this.elementLeave(),this.commandHandler.removeSnap(),this.inAction=!1,this.eventArgs={},this.diagram.selectedObject&&this.diagram.selectedObject.helperObject&&(this.diagram.remove(this.diagram.selectedObject.helperObject),this.diagram.selectedObject={helperObject:void 0,actualObject:void 0}),this.tool=null,function Qne(){var t,e,n=document.getElementsByClassName("e-d-ruler-marker");if(n&&n.length>0)for(e=n.length-1;e>=0;e--)(t=n[parseInt(e.toString(),10)])&&t.parentNode.removeChild(t)}(),"Rotate"===this.action&&this.diagram.diagramCanvas.classList.remove("e-diagram-rotate"),t.preventDefault()},n.prototype.mouseWheel=function(t){this.diagram.blazorActions|=on.interaction;var e={event:t,cancel:!1};if(this.diagram.triggerEvent(Ce.mouseWheel,e),!e.cancel){var i=t.wheelDelta>0||-40*t.detail>0,r=this.getMousePosition(t);if(this.diagram.tooltipObject.close(),this.isMetaKey(t)){var o=this.diagram.scrollSettings.zoomFactor;this.diagram.zoomTo(i?{type:"ZoomIn",zoomFactor:o,focusPoint:r}:{type:"ZoomOut",zoomFactor:o,focusPoint:r}),t.preventDefault()}else{var a=this.diagram.scroller.horizontalOffset,l=this.diagram.scroller.verticalOffset,h=i?10:-10;this.tool&&(this.tool instanceof zl||this.tool instanceof Rl)&&(this.eventArgs={},this.getMouseEventArgs(r,this.eventArgs),this.eventArgs.position=r,this.tool.mouseWheel(this.eventArgs)),this.diagram.scrollActions|=da.Interaction;var c=!0;if(t.isTrusted){var d=!1;(Math.abs(t.deltaY)<100&&-0===Math.abs(t.deltaX)||Math.abs(t.deltaX)<100&&-0===Math.abs(t.deltaY))&&(d=!0);var u=!1;(0!==t.deltaX||0!==t.deltaY)&&(u=navigator.userAgent.includes("Macintosh")),u?Math.abs(t.deltaX)>Math.abs(t.deltaY)?(t.shiftKey||t.deltaX&&-0!==t.deltaX&&(d||!u))&&this.diagram.scroller.zoom(1,h,0,r,c,void 0,d):t.deltaY&&-0!==t.deltaY&&(d||!u)&&this.diagram.scroller.zoom(1,0,h,r,c,void 0,d):t.shiftKey||t.deltaX&&-0!==t.deltaX&&(d||!u)?this.diagram.scroller.zoom(1,h,0,r,c,void 0,d):t.deltaY&&-0!==t.deltaY&&(d||!u)&&this.diagram.scroller.zoom(1,0,h,r,c,void 0,d)}else t.shiftKey||t.deltaX&&-0!==t.deltaX?this.diagram.scroller.zoom(1,h,0,r,c):this.diagram.scroller.zoom(1,0,h,r,c);this.diagram.scrollActions&=~da.Interaction,(a!==this.diagram.scroller.horizontalOffset||l!==this.diagram.scroller.verticalOffset)&&t.preventDefault()}if(this.diagram.textEditing){if(this.diagram.isTriggerEvent=!0,this.diagram.activeLabel.parentId){var p=this.diagram.getObject(this.diagram.activeLabel.parentId);this.diagram.startTextEdit(p,this.diagram.activeLabel.id)}this.diagram.isTriggerEvent=!1}this.diagram.blazorActions=this.diagram.blazorActions&~on.interaction}},n.prototype.keyDown=function(t){if(t.fromMouseEvents&&(t.ctrlKey&&(this.keyArgs.keyModifiers=1),t.shiftKey&&(this.keyArgs.keyModifiers=4),t.shiftKey&&t.ctrlKey&&(this.keyArgs.keyModifiers=5)),!(this.diagram.diagramActions&ee.TextEdit)&&!this.checkEditBoxAsTarget(t)||"Escape"===t.key||27===t.keyCode){var i=void 0,r=t.keyCode?t.keyCode:t.which,s=t.key;("ArrowDown"===s||"ArrowUp"===s||"ArrowLeft"===s||"ArrowRight"===s)&&(this.isNudgeKey=!0);var o=this.isMetaKey(t);if(this.diagram.commandManager&&this.diagram.commands)for(var l=0,h=Object.keys(this.diagram.commands);l4&&(S({keyDownEventArgs:KeyboardEvent,parameter:i.parameter,type:"KEYDOWN"}),this.keyCount=0,this.keyArgs.newValue={offsetX:this.diagram.selectedItems.offsetX,offsetY:this.diagram.selectedItems.offsetY},this.diagram.triggerEvent(Ce.positionChange,this.keyArgs))),this.isKeyUp=!1):S({keyDownEventArgs:KeyboardEvent,parameter:i.parameter})}break}}}}this.keyArgs={element:this.diagram.selectedItems,key:t.key,keyCode:t.keyCode?t.keyCode:t.which},this.getKeyModifier(this.keyArgs,t),this.diagram.diagramActions&ee.TextEdit&&this.getlabel(this.keyArgs,t),this.diagram.triggerEvent(Ce.keyDown,this.keyArgs)},n.prototype.getlabel=function(t,e){var i=this.diagram.activeLabel;t.target=this.diagram.element.id+"_editBox";var r=this.diagram.nameTable[i.parentId];if(document.getElementById(this.diagram.element.id+"_editBox")){t.text=document.getElementById(this.diagram.element.id+"_editBox").value;for(var s=0;s=this.diagram.scroller.viewPortWidth-18?r="right":e.x+this.diagram.scroller.horizontalOffsetthis.diagram.scroller.viewPortHeight-18?r="bottom":e.y+this.diagram.scroller.verticalOffset0&&(s=this.findIntersectChild(this.hoverElement)),"Auto"===this.hoverElement.tooltip.openOn&&""!==r&&Mx(this.diagram,s||(i?this.hoverElement:void 0)),this.hoverElement.tooltip.content&&("Mouse"===this.hoverElement.tooltip.relativeMode?this.setTooltipOffset(t):(this.diagram.tooltipObject.offsetX=0,this.diagram.tooltipObject.offsetY=0));var o=this.diagram.findObjectsUnderMouse(this.currentPosition),a=this.diagram.findObjectUnderMouse(o,this.action,this.inAction);if(null!==a){var l=void 0;this.hoverElement.tooltip.isSticky&&(this.diagram.tooltipObject.isSticky=!0),a instanceof te&&a.children&&a.children.length>0&&(a=s||a),l=a.ports&&(this.hoverElement instanceof Es||this.hoverElement instanceof Tc)||a.annotations&&(this.hoverElement instanceof Kn||this.hoverElement instanceof Or)?document.getElementById(a.id+"_"+this.hoverElement.id):document.getElementById(a.id+(a.shape&&a.shape instanceof lm?"_content_native_element":"_groupElement")),"Auto"===this.hoverElement.tooltip.openOn&&""!==r&&(this.diagram.tooltipObject.close(),this.diagram.tooltipObject.openOn=this.hoverElement.tooltip.openOn,this.diagram.tooltipObject.dataBind()),function jre(n,t){var e=0;return n instanceof de?n.constraints&qe.Tooltip?e=n.constraints&qe.Tooltip:n.constraints&qe.InheritTooltip&&(e=t.constraints&nt.Tooltip):n instanceof Es||n instanceof Tc?n.constraints&ai.ToolTip?e=n.constraints&ai.ToolTip:n.constraints&ai.InheritTooltip&&(e=t.constraints&nt.Tooltip):n instanceof Kn||n instanceof Or?n.constraints&Nr.Tooltip&&(e=n.constraints&Nr.Tooltip):n.constraints&ie.Tooltip?e=n.constraints&ie.Tooltip:n.constraints&ie.InheritTooltip&&(e=t.constraints&nt.Tooltip),e}(this.hoverElement,this.diagram)&&"Auto"===this.hoverElement.tooltip.openOn&&(this.diagram.tooltipObject.target=this.hoverElement.id,this.diagram.tooltipObject.open("Mouse"===this.hoverElement.tooltip.relativeMode?this.diagram.element:l))}}},n.prototype.elementLeave=function(){this.diagram.tooltipObject&&!this.diagram.tooltipObject.isSticky&&"Custom"!==this.diagram.tooltipObject.openOn&&this.diagram.tooltipObject.close()},n.prototype.setTooltipOffset=function(t){var e=function dse(n,t,e,i){var o="Mouse"===(!(e instanceof te?e.constraints&ie.InheritTooltip:e instanceof de?e.constraints&qe.InheritTooltip:e.constraints&ai.InheritTooltip)&&(e instanceof te?e.constraints&ie.Tooltip:e instanceof de?e.constraints&qe.Tooltip:e.constraints&ai.ToolTip)?e.tooltip.relativeMode:n.tooltip.relativeMode);"Mouse"===i?o=!0:"Object"===i&&(o=!1);var a=function use(n,t,e,i){var o,r={},s=document.getElementById(e.element.id);if(n instanceof te||n instanceof de)o=n.wrapper.bounds;else{var a=e.findObjectsUnderMouse(t),l=e.findObjectUnderMouse(a,"Select",!1);o=e.findElementUnderMouse(l,t,e).bounds}var c=s.getBoundingClientRect();switch(e.tooltipObject.position){case"BottomCenter":r=zc(t,o.bottomCenter,e,i,c.width/2,c.height);break;case"BottomLeft":case"LeftBottom":r=zc(t,o.bottomLeft,e,i,0,c.height);break;case"BottomRight":case"RightBottom":r=zc(t,o.bottomRight,e,i,c.width,c.height);break;case"LeftCenter":r=zc(t,o.middleLeft,e,i,0,c.height/2);break;case"LeftTop":case"TopLeft":r=zc(t,o.topLeft,e,i,0,0);break;case"RightCenter":r=zc(t,o.middleRight,e,i,c.width,c.height/2);break;case"RightTop":case"TopRight":r=zc(t,o.topRight,e,i,c.width,0);break;case"TopCenter":r=zc(t,o.topCenter,e,i,c.width/2,0)}return r}(e,t,n,o),l=Za(n);return{x:a.x+l.width,y:a.y+l.height}}(this.diagram,t,this.hoverElement);this.diagram.tooltipObject.offsetX=e.x,this.diagram.tooltipObject.offsetY=e.y},n.prototype.altKeyPressed=function(t){return!!(t&ft.Alt)},n.prototype.ctrlKeyPressed=function(t){return!!(t&ft.Control)},n.prototype.shiftKeyPressed=function(t){return!!(t&ft.Shift)},n.prototype.scrolled=function(t){this.diagram.updateScrollOffset()},n.prototype.isMobileOrIPadDevice=function(){var t=navigator.userAgent||navigator.vendor||window.opera;return/iPhone|iPad|iPod/.test(t)&&!window.MSStream?"iOS":/android/i.test(t)?"Android":/Mobile|Tablet/.test(t)?"Mobile":"Desktop"},n.prototype.doubleClick=function(t){if(jv(this.diagram)){var e=this.isMobileOrIPadDevice(),i=this.diagram.tool;"Desktop"!==e&&this.tool&&(this.tool instanceof zl||this.tool instanceof Rl)&&(this.diagram.tool=0);var r=void 0,s=this.diagram.findObjectsUnderMouse(this.currentPosition),o=this.diagram.findObjectUnderMouse(s,this.action,this.inAction);if(null!==o&&jv(this.diagram))if(r=this.diagram.findElementUnderMouse(o,this.currentPosition,this.diagram),this.tool&&(this.tool instanceof zl||this.tool instanceof Rl))this.diagram.tool=i,this.tool.mouseUp(this.eventArgs),this.isMouseDown=!1,this.eventArgs={},this.tool=null,t.preventDefault();else{var l=this.diagram.commandHandler.getObjectLayer(o.id);!l||l.lock||!l.visible||this.diagram.diagramActions&ee.TextEdit||this.diagram.startTextEdit(o,r instanceof li?r.id.split(o.id+"_")[1]:void 0)}this.diagram.triggerEvent(Ce.doubleClick,{source:o||this.diagram,position:this.currentPosition,count:t.detail})}},n.prototype.itemClick=function(t,e){var i=t;return Dn(this.diagram,i,!0)?i:null},n.prototype.inputChange=function(t){var i,s,o,a,l,h,c,d,u,f=document.getElementById(this.diagram.element.id+"_editBox"),p=document.getElementById(this.diagram.element.id+"_editTextBoxDiv"),g=f.value,v=g.split("\n");(!(a=this.diagram.selectedItems.nodes[0]?this.diagram.selectedItems.nodes[0]:this.diagram.selectedItems.connectors[0])&&this.tool instanceof YI||a&&"SwimLane"===a.shape.type)&&(a=this.diagram.nameTable[this.diagram.activeLabel.parentId]),a&&("Text"!==a.shape.type&&a.annotations.length>0||"Text"===a.shape.type)&&(c=NF((o=this.diagram.getWrapper(a.wrapper,this.diagram.activeLabel.id)).style,g,void 0,void 0,i=(i=a.wrapper.bounds.width90?i:90),s=Number(f.style.fontSize.split("px")[0]),v.length>1&&""===v[v.length-1]&&(c.height=c.height+s),d=this.diagram.scroller.transform,u=T3(this.diagram)?d.scale:1,l=(12>c.height?12:c.height)*u,p.style.left=(o.bounds.center.x+d.tx)*d.scale-(h=(90>(h=c.width)?90:h)*u)/2-2.5+"px",p.style.top=(o.bounds.center.y+d.ty)*d.scale-l/2-3+"px",p.style.width=h+"px",p.style.height=l+"px",f.style.minHeight="12px",f.style.minWidth="90px",f.style.width=h+"px",f.style.height=l+"px")},n.prototype.isAddTextNode=function(t,e){return!(!(this.tool instanceof YI||e)||(this.tool=null,t&&!zI(this.diagram)&&(this.diagram.drawingObject=void 0,this.diagram.currentDrawingObject=void 0),vF(this.diagram.nodes,t.id)||vF(this.diagram.connectors,t.id)))},n.prototype.checkEditBoxAsTarget=function(t){return!(!t.target||t.target.id!==this.diagram.element.id+"_editBox")},n.prototype.getMouseEventArgs=function(t,e,i,r){var s,o,a;if(e.position=t,i?(o=this.diagram.findObjectsUnderMouse(this.currentPosition,i),s=this.diagram.findTargetObjectUnderMouse(o,this.action,this.inAction,e.position,i)):"Drag"===this.action||"ConnectorSourceEnd"===this.action||"SegmentEnd"===this.action||"OrthoThumb"===this.action||"BezierSourceThumb"===this.action||"BezierTargetThumb"===this.action||"ConnectorTargetEnd"===this.action||-1!==this.action.indexOf("Rotate")||-1!==this.action.indexOf("Resize")?(s=this.diagram.selectedItems,!this.diagram.currentSymbol&&"Drag"===this.action&&s&&this.diagram.selectedItems.nodes.length>0&&"SwimLane"===this.diagram.selectedItems.nodes[0].shape.type&&(o=this.diagram.findObjectsUnderMouse(this.currentPosition),s=this.diagram.findObjectUnderMouse(o,this.action,this.inAction))):(o=this.diagram.findObjectsUnderMouse(this.currentPosition),s=this.diagram.findObjectUnderMouse(o,this.action,this.inAction)),s&&s.isHeader&&(this.eventArgs.actualObject=s=this.diagram.nameTable[s.parentId]),s){var l=void 0,h=void 0,c=void 0;if(((a=this.diagram.findElementUnderMouse(s,this.currentPosition,this.diagram,r))&&s.ports&&s.ports.length&&!rb(s,a)||!a||!s)&&o&&o.length&&i instanceof ti)for(l=i.connectors[0],c=o.length-1;c>=0;c--)if(((h=o[parseInt(c.toString(),10)])instanceof te||h instanceof de)&&l&&l.connectionPadding){if(a=this.diagram.findElementUnderMouse(s=h,this.currentPosition,this.diagram,r),l.constraints&qe.ConnectToNearByPort&&s&&s.ports&&s.ports.length&&rb(s,a))break;if((h instanceof te||h instanceof de)&&l&&l.connectionPadding&&h.wrapper.outerBounds.containsPoint(this.currentPosition)&&l.constraints&qe.ConnectToNearByNode&&!(l.constraints&qe.ConnectToNearByPort)){a=this.diagram.findElementUnderMouse(s=h,this.currentPosition,this.diagram,0);break}}}return i?(e.target=s,e.targetWrapper=a):(e.source=s,e.sourceWrapper=a),e.actualObject=this.eventArgs.actualObject,e.source instanceof ti&&void 0===e.actualObject&&(e.source.nodes.length>0||e.source.connectors.length>0)&&(e.actualObject=e.source.nodes.length>0?this.diagram.nameTable[e.source.nodes[0].id]:this.diagram.nameTable[e.source.connectors[0].id]),e.startTouches=this.touchStartList,e.moveTouches=this.touchMoveList,e},n.prototype.resetTool=function(){this.action="Select",this.hoverElement=null,this.hoverNode=null,this.tool=this.diagram.getTool(this.action),this.updateCursor()},n.prototype.updateTool=function(){this.action=this.currentPosition&&"Pan"!==this.action?"Pan":"Select"},n.prototype.getTool=function(t){switch(t){case"Select":return new Jv(this.commandHandler,!0);case"Drag":return new fa(this.commandHandler);case"Rotate":return new Yx(this.commandHandler);case"LayoutAnimation":return new Lne(this.commandHandler);case"FixedUserHandle":return new Ane(this.commandHandler,!0);case"Hyperlink":return new X3(this.commandHandler);case"ResizeSouthEast":case"ResizeSouthWest":case"ResizeNorthEast":case"ResizeNorthWest":case"ResizeSouth":case"ResizeNorth":case"ResizeWest":case"ResizeEast":return new Pd(this.commandHandler,t);case"ConnectorSourceEnd":case"ConnectorTargetEnd":case"BezierSourceThumb":case"BezierTargetThumb":return new kd(this.commandHandler,t);case"SegmentEnd":case"OrthoThumb":return new ZF(this.commandHandler,t);case"Draw":var e="shape",i=function nse(n){var t;return n&&(n.type?t="Connector":n.shape&&!n.type&&(t="Node")),t}(this.diagram.drawingObject);if("Node"===i&&"Text"===this.diagram.drawingObject.shape.type)return new YI(this.commandHandler);if("Connector"===i&&"Freehand"===this.diagram.drawingObject.type)return new Pne(this.commandHandler);if("Node"===i&&"Polygon"===this.diagram.drawingObject.shape[""+e]&&!this.diagram.drawingObject.shape.points)return new zl(this.commandHandler);if("Node"===i||"Node"===i&&"Polygon"===this.diagram.drawingObject.shape[""+e]&&this.diagram.drawingObject.shape.points)return new WI(this.commandHandler,this.diagram.drawingObject);if("Connector"===i&&"Polyline"===this.diagram.drawingObject.type)return new Rl(this.commandHandler);if("Connector"===i)return new pa(this.commandHandler,"ConnectorSourceEnd",this.diagram.drawingObject);break;case"Pan":return new Kv(this.commandHandler,!1);case"PinchZoom":return new Kv(this.commandHandler,!0);case"PortDrag":return new fa(this.commandHandler,"Port");case"PortDraw":return new pa(this.commandHandler,"ConnectorSourceEnd",this.diagram.drawingObject);case"LabelSelect":return new Jv(this.commandHandler,!0,"LabelSelect");case"LabelDrag":return new Nne(this.commandHandler);case"LabelResizeSouthEast":case"LabelResizeSouthWest":case"LabelResizeNorthEast":case"LabelResizeNorthWest":case"LabelResizeSouth":case"LabelResizeNorth":case"LabelResizeWest":case"LabelResizeEast":return new One(this.commandHandler,t);case"LabelRotate":return new kne(this.commandHandler)}return null},n.prototype.getCursor=function(t){var e=this.diagram.selectedItems.annotation?this.diagram.selectedItems.wrapper.children[0]:this.diagram.selectedItems;return function Tne(n,t){if(t+=360,t%=360,-1===n.indexOf("Resize"))return Wx[""+n];var e=Wx[""+n];return t>=0&&t<25||t>=160&&t<=205||t>=340&&t<=360?e:t>=25&&t<=70||t>=205&&t<=250?"n-resize"===e||"s-resize"===e?"ne-resize":"nw-resize"===e||"se-resize"===e?"n-resize":"e-resize"===e||"w-resize"===e?"nw-resize":"e-resize":t>=70&&t<=115||t>=250&&t<=295?"n-resize"===e||"s-resize"===e?"e-resize":"nw-resize"===e||"se-resize"===e?"ne-resize":"e-resize"===e||"w-resize"===e?"n-resize":"nw-resize":t>=115&&t<=155||t>=295&&t<=340?"n-resize"===e||"s-resize"===e?"nw-resize":"nw-resize"===e||"se-resize"===e?"e-resize":"e-resize"===e||"w-resize"===e?"ne-resize":Wx[""+n]:"n-resize"}(t,this.diagram.selectedItems.annotation?e.rotateAngle+e.parentTransform:e.rotateAngle)},n.prototype.findElementUnderMouse=function(t,e,i,r){return this.objectFinder.findElementUnderSelectedItem(t,e,i,r)},n.prototype.findObjectsUnderMouse=function(t,e){return this.objectFinder.findObjectsUnderMouse(t,this.diagram,this.eventArgs,e)},n.prototype.findObjectUnderMouse=function(t,e,i){return this.objectFinder.findObjectUnderMouse(this.diagram,t,e,i,this.eventArgs,this.currentPosition)},n.prototype.findTargetUnderMouse=function(t,e,i,r,s){return this.objectFinder.findObjectUnderMouse(this.diagram,t,e,i,this.eventArgs,r,s)},n.prototype.findActionToBeDone=function(t,e,i,r){return function Mne(n,t,e,i,r,s,o){if(s&&s.length>1&&r&&r.length>1)return"PinchZoom";if(i.currentSymbol)return"Drag";if("PortDraw"===i.eventHandler.action&&(i.tool&=~ni.DrawOnce),(x3(i)||zI(i))&&i.drawingObject)return"Draw";if($a(i)&&(l=i.selectedItems).wrapper&&qr(l.constraints,"UserHandle"))for(var h=0,c=l.userHandles;h=50&&(l.x=(a.points[parseInt(h.toString(),10)].x+a.points[h+1].x)/2,l.y=(a.points[parseInt(h.toString(),10)].y+a.points[h+1].y)/2,wr(e,l,n.hitPadding?n.hitPadding:10)))return"OrthoThumb"}else NI(n)&&console.warn('[WARNING] :: Module "ConnectorEditing" is not available in Diagram component! You either misspelled the module name or forgot to load it.');return null}(g,l,e,i);if("OrthoThumb"===S)return S;if(qr(l.constraints,"ConnectorSourceThumb")&&AI(g)&&S||qr(l.constraints,"ConnectorTargetThumb")&&LI(g)&&S)return S}}else{var b=i.selectedItems.handleSize/2/i.scroller.currentZoom,M=10/i.scroller.currentZoom,w=Bi();qi(w,f.rotateAngle+f.parentTransform,f.offsetX,f.offsetY);var C=f.offsetX-f.pivot.x*f.actualSize.width,D=f.offsetY-f.pivot.y*f.actualSize.height,A={x:C+(.5===f.pivot.x?2*f.pivot.x:f.pivot.x)*f.actualSize.width/2,y:D-30/i.scroller.currentZoom};A=Ke(w,A);var x=!!i.selectedItems.annotation,P=!(!x||!OI(i.selectedItems.annotation));if(qr(l.constraints,"Rotate")&&wr(e,A,M)&&i.selectedItems.thumbsConstraints&bt.Rotate){if(x&&P)return"LabelRotate";if(!x)return"Rotate"}if(u.Inflate(b),u.containsPoint(e)&&(S=function wne(n,t,e,i,r,s){var o;return 1===n.selectedItems.nodes.length&&0===n.selectedItems.connectors.length&&n.selectedItems.nodes[0].container&&(o=function Dne(n,t,e,i,r){var s=10/n.scroller.currentZoom,o=n.selectedItems,a=t.actualSize.width,l=t.actualSize.height,h=new Ne(i,r,t.style.strokeWidth,l),c=new Ne(i+a,r,t.style.strokeWidth,l),d=new Ne(i,r,a,t.style.strokeWidth),u=new Ne(i,r+l,a,t.style.strokeWidth),f=Dn(n,n.selectedItems.nodes[0],!0)?n.nameTable[n.selectedItems.nodes[0].parentId]:n.selectedItems.nodes[0];if(ga(o.constraints,"ResizeEast",o.thumbsConstraints,o)&&c.containsPoint(e,s))return"ResizeEast";if(ga(o.constraints,"ResizeSouth",o.thumbsConstraints,o)&&u.containsPoint(e,s))return"ResizeSouth";if("Grid"!==f.container.type){if(ga(o.constraints,"ResizeWest",o.thumbsConstraints,o)&&h.containsPoint(e,s))return"ResizeWest";if(ga(o.constraints,"ResizeNorth",o.thumbsConstraints,o)&&d.containsPoint(e,s))return"ResizeNorth"}return null}(n,t,e,r,s)),!o&&(!n.selectedItems.nodes[0]||!n.selectedItems.nodes[0].isPhase&&!n.selectedItems.nodes[0].isLane&&"SwimLane"!==n.selectedItems.nodes[0].shape.type)&&(o=function xne(n,t,e,i,r,s){var o=40/n.scroller.currentZoom,a=n.selectedItems.handleSize/2/n.scroller.currentZoom,l=n.selectedItems,h=!!l.annotation;if(t.actualSize.width>=o&&t.actualSize.height>=o){if(ga(l.constraints,"ResizeSouthEast",l.thumbsConstraints,l)&&wr(e,Ke(i,{x:r+t.actualSize.width,y:s+t.actualSize.height}),a))return h?"LabelResizeSouthEast":"ResizeSouthEast";if(ga(l.constraints,"ResizeSouthWest",l.thumbsConstraints,l)&&wr(e,Ke(i,{x:r,y:s+t.actualSize.height}),a))return h?"LabelResizeSouthWest":"ResizeSouthWest";if(ga(l.constraints,"ResizeNorthEast",l.thumbsConstraints,l)&&wr(e,Ke(i,{x:r+t.actualSize.width,y:s}),a))return h?"LabelResizeNorthEast":"ResizeNorthEast";if(ga(l.constraints,"ResizeNorthWest",l.thumbsConstraints,l)&&wr(e,Ke(i,{x:r,y:s}),a))return h?"LabelResizeNorthWest":"ResizeNorthWest"}return ga(l.constraints,"ResizeEast",l.thumbsConstraints,l)&&wr(e,Ke(i,{x:r+t.actualSize.width,y:s+t.actualSize.height/2}),a)?h?"LabelResizeEast":"ResizeEast":ga(l.constraints,"ResizeWest",l.thumbsConstraints,l)&&wr(e,Ke(i,{x:r,y:s+t.actualSize.height/2}),a)?h?"LabelResizeWest":"ResizeWest":ga(l.constraints,"ResizeSouth",l.thumbsConstraints,l)&&wr(e,Ke(i,{x:r+t.actualSize.width/2,y:s+t.actualSize.height}),a)?h?"LabelResizeSouth":"ResizeSouth":ga(l.constraints,"ResizeNorth",l.thumbsConstraints,l)&&wr(e,Ke(i,{x:r+t.actualSize.width/2,y:s}),a)?h?"LabelResizeNorth":"ResizeNorth":null}(n,t,e,i,r,s)),o||null}(i,f,e,w,C,D),S))return S}}if(Lc(i)&&!n)return"Pan";if((o instanceof Es||o instanceof Tc)&&(!Lc(i)||_v(i)||Uv(i))&&(S=function Ene(n,t,e,i){if(Hx(t)&&(va(t,Gt.Hover)||va(t,Gt.Visible))){if(t.constraints&ai.Drag)return"PortDrag"}else if(Rx(t)&&(va(t,Gt.Hover)||va(t,Gt.Visible))&&t.constraints&ai.Draw){n.drawingObject={};var r={type:"Orthogonal",sourcePortID:t.id};return n.drawingObject=r,n.tool|=ni.DrawOnce,n.currentDrawingObject=r,"PortDraw"}return"None"}(i,o),"None"!==S))return S;if((o instanceof Kn||o instanceof Or)&&!Lc(i)&&xd(o))return _r(i,o,void 0,t)&&ro(o)?"LabelDrag":"LabelSelect";if(null!==n){if(!(n instanceof te||n instanceof de))return"Select";if(t&&t.id){var L=t.id.split(n.id)[1];if(L&&L.match("^_icon"))return"LayoutAnimation"}if(t&&t.id)for(var O=void 0,N=0;N-1)return"FixedUserHandle";if(t instanceof li&&t.hyperlink.link)return"Hyperlink";if(!ro(n)||!_r(i,n,!1)||void 0!==i.selectedItems.annotation)return n&&Lc(i)&&!RI(i)?"Pan":i.selectedItems.nodes.length&&i.selectedItems.nodes[0].isLane&&i.selectedItems.wrapper&&i.selectedItems.wrapper.bounds.containsPoint(e)?"Drag":"Select";if(n instanceof de&&!wr(e,n.sourcePoint,n.hitPadding)&&!wr(e,n.targetPoint,n.hitPadding)||!(n instanceof de))return"Drag"}return"Select"}(t,e,this.currentPosition,this.diagram,this.touchStartList,this.touchMoveList,r)},n.prototype.updateContainerBounds=function(t){var e=!1;if(this.diagram.selectedObject.helperObject&&this.diagram.selectedObject.actualObject)for(var i=this.diagram.selectedObject.actualObject,r=this.diagram.selectedObject.actualObject instanceof ti?i.nodes:[i],s=0;si.y&&(h+=u>0?-1:1,u+=u>0?-1:1):i&&e.wrapper.offsetYi.x&&(h+=u>0?-1:1,u+=u>0?-1:1):i&&e.wrapper.offsetX1)for(var S=t.offsetX-this.diagram.selectedItems.offsetX,b=t.offsetY-this.diagram.selectedItems.offsetY,M=t.rotateAngle-this.diagram.selectedItems.rotateAngle,w=0;w-1){var A=c.children;A.splice(A.indexOf(o.id),1),this.diagram.nameTable[o.id].parentId="",i=!0,c.wrapper.children.splice(D,1)}}if(function bne(n,t,e,i){var r=n,s=e.nameTable[r.parentId],o=e.nameTable[r.parentId];if(t&&o&&o.container&&"Stack"===o.container.type&&t.container&&"Stack"===t.container.type&&o.id!==t.parentId){var a=o.wrapper.children.indexOf(r.wrapper);a>-1&&(e.nameTable[r.id].parentId=t.id,o.wrapper.children.splice(a,1))}if(t&&t.parentId&&r.parentId&&"Drag"===i&&o.container&&"Stack"===o.container.type){var l=s.wrapper.children.indexOf(t.wrapper),h=s.wrapper.children.indexOf(r.wrapper),c={targetIndex:l,target:t,sourceIndex:h,source:n};s.wrapper.children.splice(h,1),s.wrapper.children.splice(l,0,r.wrapper),e.commandHandler.addHistoryEntry({type:"StackChildPositionChanged",redoObject:{targetIndex:h,target:t,sourceIndex:l,source:n},undoObject:c,category:"Internal"})}}(o,h,this.diagram,this.action),(c=Dn(this.diagram,o)?this.diagram.nameTable[o.parentId]:this.diagram.nameTable[o.parentId]||o)&&c.container&&"Canvas"===c.container.type&&(c.wrapper.maxWidth=c.maxWidth=c.wrapper.actualSize.width,c.wrapper.maxHeight=c.maxHeight=c.wrapper.actualSize.height,e=!0),Dn(this.diagram,o,!0)&&c&&"Canvas"===c.container.type)if(this.diagram.selectedItems.nodes.length>1)for(w=0;w0)for(var i=0;i0&&e.columnIndex>0||l&&e.isLane)){if("Horizontal"===t.container.orientation&&e.isPhase&&e.wrapper.width>e.maxWidth&&(e.maxWidth=e.wrapper.width,e.wrapper.maxWidth=e.wrapper.width),h.updateColumnWidth(e.columnIndex,r.width,!0,c),_x(this.diagram,e,t),e.isPhase){var p=this.diagram.nameTable[""+t.shape.phases[e.columnIndex].header.id];p.maxWidth0?(r=new rp(t,"",u),t.shape.classShape.attributes.push(r)):i.id.includes("_umlMethods")&&t.shape.classShape.methods.length>0&&(s=new cm(t,"",u),t.shape.classShape.methods.push(s))),"Interface"===t.shape.classifier&&(i.id.includes("_umlProperty")&&t.shape.interfaceShape.attributes.length>0?(r=new rp(t,"",u),t.shape.classShape.attributes.push(r)):i.id.includes("_umlMethods")&&t.shape.interfaceShape.methods.length>0&&(s=new cm(t,"",u),t.shape.interfaceShape.methods.push(s))),"Enumeration"===t.shape.classifier&&i.id.includes("_umlMember")&&t.shape.enumerationShape.members.length>0){var f=new ob(t,"",u);t.shape.enumerationShape.members.push(f)}t.wrapper.children.indexOf(c.wrapper),this.diagram.enableServerDataBinding(!0),this.diagram.add(c),this.diagram.updateConnectorEdges(t),this.diagram.clearSelection(),this.diagram.select([this.diagram.nameTable[c.id]]),this.diagram.endGroupAction(),this.diagram.startTextEdit()}}},n}(),_oe=function(){function n(){}return n.prototype.findObjectsUnderMouse=function(t,e,i,r,s){var o=[];r&&r instanceof ti&&r.nodes.length+r.connectors.length===1&&(r=r.nodes[0]||r.connectors[0]).children&&0===r.children.length&&(i.actualObject=r);for(var a,l,h,c,p,d=r&&r instanceof de&&(r.constraints&qe.ConnectToNearByNode||r.constraints&qe.ConnectToNearByPort)&&r.connectionPadding||0,f={},g=0,v=e.spatialSearch.findObjects(new Ne(t.x-50-d,t.y-50-d,100+d,100+d));g-1&&o.splice(T,1),"UmlClassifier"===y.shape.type&&y.container&&"Stack"===y.container.type&&(T=o.indexOf(e.nameTable[e.nameTable[y.id].wrapper.children[0].id]))>-1&&o.splice(T,1)}for(var z=0;zs.zIndex&&(t[parseInt(r.toString(),10)]=l),r>0&&i&&a&&(a.isLane||a.isPhase||a.isHeader)&&t[parseInt(r.toString(),10)].zIndex=2)for(var d=t.length-1;d>=0;d--)if(t[parseInt(d.toString(),10)].parentId){var u=om(t[parseInt(d.toString(),10)],e,""),f=om(t[d-1],e,""),g=e.nameTable[""+f];g&&u!==f&&e.nameTable[""+u].zIndex=0;p--){d=Kf(e[parseInt(p.toString(),10)],!1),c=Kf(e[parseInt(p.toString(),10)],!0);var g=t[""+l].tool,v=this.findTargetElement(e[parseInt(p.toString(),10)].wrapper,o,t,void 0);if("Draw"===i&&v&&(e[parseInt(p.toString(),10)]instanceof te||e[parseInt(p.toString(),10)]instanceof de)&&!rb(e[parseInt(p.toString(),10)],v)&&(g&&"ConnectorSourceEnd"===g[""+h]&&!Ph(e[parseInt(p.toString(),10)])||g&&"ConnectorTargetEnd"===g[""+h]&&!ua(e[parseInt(p.toString(),10)])))return u;if(e[parseInt(p.toString(),10)]instanceof te||e[parseInt(p.toString(),10)]instanceof de&&(Ph(e[parseInt(p.toString(),10)])||Td(d)||ua(e[parseInt(p.toString(),10)])||kh(c)||"PortDraw"===i&&g instanceof kd&&"ConnectorTargetEnd"===g[""+h]&&(ua(e[parseInt(p.toString(),10)])||kh(c))))return u=e[parseInt(p.toString(),10)],f&&(u=this.isTarget(u,t,i)),s.actualObject=u,u}else if("ConnectorTargetEnd"===i&&a){for(p=e.length-1;p>=0;p--)if(c=Kf(e[parseInt(p.toString(),10)],!0),(e[parseInt(p.toString(),10)]instanceof te||e[parseInt(p.toString(),10)]instanceof de)&&(ua(e[parseInt(p.toString(),10)])||kh(c)))return u=e[parseInt(p.toString(),10)],u=this.isTarget(u,t,i),s.actualObject=u,u}else{if(a&&("Drag"===i||t[""+l].tool instanceof fa)){var y=0;for(p=0;p=S.zIndex?u:S,y=Math.max(y,S.zIndex)):y=(u=S).zIndex)}return u&&"Bpmn"===u.shape.type&&(t.selectedItems.nodes.length>0&&"Bpmn"===t.selectedItems.nodes[0].shape.type||(u=null)),u&&(s.actualObject=u),u}if("Select"!==i&&"Pan"!==i||!t[""+l].tool)if("Pan"===i||"LayoutAnimation"===i){for(p=e.length-1;p>=0;p--)if((e[parseInt(p.toString(),10)]instanceof te||e[parseInt(p.toString(),10)]instanceof de)&&(v=this.findTargetElement(e[parseInt(p.toString(),10)].wrapper,o,t,void 0),"Pan"===i||v&&(v.id.match("_icon_content_shape$")||v.id.match("_icon_content_rect$"))))return e[parseInt(p.toString(),10)]}else u=e[e.length-1],s&&u&&(s.actualObject=u);else{for(p=e.length-1;p>=0;p--)if(e[parseInt(p.toString(),10)]instanceof de){var b=e[p-1];if(e[p-1]instanceof te&&b.ports){if((v=this.findTargetElement(b.wrapper,o,t,void 0))&&(v.id.match("_icon_content_shape$")||v.id.match("_icon_content_rect$")))return b;for(var M=0;M=0;s--){var o=t.children[parseInt(s.toString(),10)];if(o&&o.outerBounds.containsPoint(e,r||0))if(o.visible){if(o instanceof Cs){var a=this.findTargetElement(o,e,i);if(a)return a}var l="Clip"===o.style.textOverflow||"Ellipsis"===o.style.textOverflow;if(o.bounds.containsPoint(e,r||0)&&!l)return o;if(t.bounds.containsPoint(e,r||0)&&l)return o}else if(o instanceof Ze&&t&&t.id){var h=void 0;if(t.id.includes("group_container")){var c=t.id.slice(0,-15);h=i.getObject(c)}else h=i.getObject(t.id);if(tb(h,o.id))return o}}return t.bounds.containsPoint(e,r)&&"none"!==t.style.fill?t:null},n}(),Uoe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),sp=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},JF=function(n){function t(e,i,r,s){var o=n.call(this,e,i,r,s)||this;return o.objectZIndex=-1,o.zIndexTable={},o.objects=[],o}return Uoe(t,n),sp([I("")],t.prototype,"id",void 0),sp([I(!0)],t.prototype,"visible",void 0),sp([I(!1)],t.prototype,"lock",void 0),sp([I()],t.prototype,"objects",void 0),sp([I()],t.prototype,"addInfo",void 0),sp([I(-1)],t.prototype,"zIndex",void 0),t}(Ee),MT=function(n,t,e,i){return new(e||(e=Promise))(function(r,s){function o(h){try{l(i.next(h))}catch(c){s(c)}}function a(h){try{l(i.throw(h))}catch(c){s(c)}}function l(h){h.done?r(h.value):new e(function(c){c(h.value)}).then(o,a)}l((i=i.apply(n,t||[])).next())})},wT=function(n,t){var i,r,s,o,e={label:0,sent:function(){if(1&s[0])throw s[1];return s[1]},trys:[],ops:[]};return o={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function a(h){return function(c){return function l(h){if(i)throw new TypeError("Generator is already executing.");for(;e;)try{if(i=1,r&&(s=2&h[0]?r.return:h[0]?r.throw||((s=r.return)&&s.call(r),0):r.next)&&!(s=s.call(r,h[1])).done)return s;switch(r=0,s&&(h=[2&h[0],s.value]),h[0]){case 0:case 1:s=h;break;case 4:return e.label++,{value:h[1],done:!1};case 5:e.label++,r=h[1],h=[0];continue;case 7:h=e.ops.pop(),e.trys.pop();continue;default:if(!(s=(s=e.trys).length>0&&s[s.length-1])&&(6===h[0]||2===h[0])){e=0;continue}if(3===h[0]&&(!s||h[1]>s[0]&&h[1]1)for(var i=0;i-1)return e[parseInt(i.toString(),10)];return this.diagram.activeLayer},n.prototype.getLayer=function(t){for(var e=this.diagram.layers,i=0;i=0;o--)this.diagram.unSelect(this.diagram.nameTable[s[parseInt(o.toString(),10)]]),this.diagram.remove(this.diagram.nameTable[s[parseInt(o.toString(),10)]]),"default_layer"!==i.id&&this.diagram.activeLayer.id===t&&(this.diagram.activeLayer=this.diagram.layers[this.diagram.layers.length-1]);delete this.diagram.layerZIndexTable[i.zIndex],this.diagram.layers.splice(r,1),"SVG"!==this.diagram.mode&&this.diagram.refreshDiagramLayer()}},n.prototype.moveObjects=function(t,e){this.diagram.startGroupAction();for(var i={},r=[],s=0;s-1){if(r=[],(h=this.diagram.nameTable[""+s]).children)for(var p=0,g=h.children;p0){for(var y=void 0,S=0,b=r;S0)for(var r=0;r0)for(r=0;r0){t=t.concat(this.diagram.selectedItems.connectors);for(var i=0;i0)for(t=t.concat(this.diagram.selectedItems.nodes),i=0;i0){for(var i=0,r=t.shape.activity.subProcess.processes;i0&&this.copyProcesses(this.processTable[""+s])}this.clipboardData.processTable=this.processTable}},n.prototype.group=function(){this.oldSelectedObjects=nm(this.diagram);var e=this.diagram.isProtectedOnChange;this.diagram.protectPropertyChange(!0),this.diagram.diagramActions=this.diagram.diagramActions|ee.Group;var r={};r.id="group"+Qe(),(r=new te(this.diagram,"nodes",r,!0)).children=[];for(var s=this.diagram.selectedItems.nodes.concat(this.diagram.selectedItems.connectors).sort(function(h,c){return h.zIndex-c.zIndex}),o=0;o0){var a=this.diagram.add(r);a&&this.select(a),this.addHistoryEntry({type:"Group",undoObject:r,redoObject:r,category:"Internal"}),this.diagram.diagramActions=this.diagram.diagramActions&~ee.Group,this.diagram.protectPropertyChange(e)}},n.prototype.unGroup=function(t){var i=this.diagram.isProtectedOnChange;this.diagram.protectPropertyChange(!0),this.diagram.diagramActions=this.diagram.diagramActions|ee.Group;var r=[];t?r.push(t):r=this.diagram.selectedItems.nodes,this.diagram.startGroupAction();for(var s=0;s0&&this.diagram.removePorts(o,o.ports),o.annotations&&o.annotations.length>0&&!ce()&&this.diagram.removeLabels(o,o.annotations);for(var c=this.diagram.nameTable[o.parentId],d=o.children.length-1;d>=0;d--)this.diagram.nameTable[o.children[parseInt(d.toString(),10)]].parentId="",this.diagram.deleteChild(this.diagram.nameTable[o.children[parseInt(d.toString(),10)]],o),o.parentId&&o.children[parseInt(d.toString(),10)]&&this.diagram.addChild(c,o.children[parseInt(d.toString(),10)]);this.resetDependentConnectors(o.inEdges,!0),this.resetDependentConnectors(o.outEdges,!1),this.diagram.diagramActions&ee.UndoRedo||this.addHistoryEntry({type:"UnGroup",undoObject:a,redoObject:a,category:"Internal"}),o.parentId&&this.diagram.deleteChild(o,c)}this.diagram.removeNode(o,l),this.clearSelection()}this.diagram.endGroupAction(),this.diagram.diagramActions=this.diagram.diagramActions&~ee.Group,this.diagram.protectPropertyChange(i)},n.prototype.resetDependentConnectors=function(t,e){for(var i=0;i0&&(g=!1)}if(g){var y=this.cloneConnector(f,i);c.push(y),o[h.id]=y.id}}else{var S=this.cloneNode(h,i);if(c.push(S),S){o[h.id]=S.id;var b=h.inEdges;if(b)for(var M=0,w=b;M0)for(var u=0;u0)for(r=t.segments,s=0;s0&&this.diagram.drawingObject&&"Bezier"===this.diagram.drawingObject.type&&(t.segments=[]);var e=this.diagram.add(t);"SVG"!==this.diagram.mode&&this.diagram.refreshDiagramLayer(),this.selectObjects([e]),t&&!zI(this.diagram)&&(this.diagram.tool&=~ni.DrawOnce,this.diagram.currentDrawingObject=void 0)},n.prototype.enableServerDataBinding=function(t){this.diagram.enableServerDataBinding(t)},n.prototype.addText=function(t,e){var i=this.diagram.findElementUnderMouse(t,e,this.diagram);this.diagram.startTextEdit(t,i instanceof li?i.id.split("_")[1]:void 0)},n.prototype.isUserHandle=function(t){var e=this.diagram.selectedItems;if(e.wrapper&&qr(e.constraints,"UserHandle"))for(var i=0,r=e.userHandles;i0&&t[0]&&t[0].isLane)for(s=this.diagram.getObject(t[0].parentId),t[0].shape.header=[],a=0;a1||e&&1===t.length)){if(1!==t.length)return[2];this.clearSelection()}if(!(u||d||1!==t.length||e&&$a(this.diagram)))return this.clearSelection(),[2]}if(!r.cancel){for(f=0;f0||e)&&p.children&&!p.parentId)for(g=0;g0||e,!0)}else this.select(p,f>0||e,!0);void 0===i&&(i=c),r={oldValue:i||[],newValue:this.getSelectedObject(),cause:this.diagram.diagramActions,state:"Changed",type:"Addition",cancel:!1},this.diagram.renderSelector(e||t&&t.length>1),ce()||this.diagram.triggerEvent(Ce.selectionChange,r),this.diagram.enableServerDataBinding(!0)}return[2]})})},n.prototype.findParent=function(t){return t.parentId&&this.findParent(t=this.diagram.nameTable[t.parentId]),t},n.prototype.selectProcesses=function(t){if(this.hasProcesses(t))for(var e=t.shape.activity.subProcess.processes,i=0;i0)},n.prototype.select=function(t,e,i){var r=this.getObjectLayer(t.id);if(xd(t)&&!(t instanceof ti)&&!_r(this.diagram,t)&&r&&!r.lock&&r.visible&&t.wrapper.visible){(e=!!$a(this.diagram)&&e)||this.clearSelection(),this.diagram.enableServerDataBinding(!1);var s=this.diagram.selectedItems;if(t instanceof te?s.nodes.push(t.isHeader?this.diagram.nameTable[t.parentId]:t):s.connectors.push(t),s.selectedObjects.push(t),e)s.wrapper.rotateAngle=s.rotateAngle=0,s.wrapper.children.push(t.wrapper);else if(s.init(this.diagram),1===s.nodes.length&&0===s.connectors.length){var l=Ux(this.diagram,s);l&&(s.wrapper.children[0]=l),s.rotateAngle=s.nodes[0].rotateAngle,s.wrapper.rotateAngle=s.nodes[0].rotateAngle,s.wrapper.pivot=s.nodes[0].pivot}i||this.diagram.renderSelector(e),this.diagram.enableServerDataBinding(!0)}},n.prototype.labelSelect=function(t,e){this.oldSelectedObjects=nm(this.diagram);var i=this.diagram.selectedItems,r=this.diagram.allowServerDataBinding;this.diagram.allowServerDataBinding=!1,i.nodes=i.connectors=[],this.diagram.allowServerDataBinding=r,t instanceof te?i.nodes[0]=t:i.connectors[0]=t,i.annotation=this.findTarget(e,t),i.init(this.diagram),this.diagram.renderSelector(!1)},n.prototype.unSelect=function(t){var e=this.diagram.selectedItems.nodes.concat(this.diagram.selectedItems.connectors),i=e.filter(function(a){return a.id!==t.id}),r={oldValue:e,newValue:i,cause:this.diagram.diagramActions,state:"Changing",type:"Removal",cancel:!1};if(this.diagram.currentSymbol||ce()||this.diagram.triggerEvent(Ce.selectionChange,r),_r(this.diagram,t)){var s=this.diagram.selectedItems,o=void 0;t instanceof te?(o=s.nodes.indexOf(t,0),s.nodes.splice(o,1)):(o=s.connectors.indexOf(t,0),s.connectors.splice(o,1)),o=s.selectedObjects.indexOf(t,0),s.selectedObjects.splice(o,1),(r={oldValue:e,newValue:i,cause:this.diagram.diagramActions,state:"Changed",type:"Removal",cancel:(r={oldValue:e,newValue:i,cause:this.diagram.diagramActions,state:"Changed",type:"Removal",cancel:!1}).cancel}).cancel||(o=s.wrapper.children.indexOf(t.wrapper,0),s.wrapper.children.splice(o,1),this.diagram.updateSelector(),this.diagram.currentSymbol||this.diagram.triggerEvent(Ce.selectionChange,r))}},n.prototype.moveSvgNode=function(t,e){var i=this.diagram.nameTable[""+e];if("Native"===i.shape.type||"HTML"===i.shape.type)this.updateNativeNodeIndex(t,e);else{var r=xt(e+"_groupElement",this.diagram.element.id),s=xt(t+"_groupElement",this.diagram.element.id);r.parentNode.insertBefore(s,r)}},n.prototype.moveAfterSvgNode=function(t,e){var i=this.diagram.nameTable[""+e];if(!i||"HTML"!==i.shape.type&&"Native"!==i.shape.type)a=xt(e+"_groupElement",this.diagram.element.id),o=xt(t+"_groupElement",this.diagram.element.id),a.insertAdjacentElement("afterend",o);else for(var r=0;rd&&"SwimLane"!==p.shape.type){var S=$(p);p.zIndex=d-((-1!==i.indexOf(p)?i.indexOf(p):0)+1),p.children&&(d=this.findLowestZIndex(p,c)||d),this.triggerOrderCommand(S,p,p),p.children&&this.updateGroupZindex(p,"SendToBack",d)}else"SwimLane"===p.shape.type&&(y=this.swapZIndexObjects(a,h,r,g));if("SVG"===this.diagram.mode){for(var M="SwimLane"!==this.diagram.nameTable[""+r].shape.type?d:y,w=h[parseInt(M.toString(),10)];!w&&Md)&&(d=f.zIndex)}for(var p=JSON.parse(JSON.stringify(l)),v=Number(Object.keys(l).sort(function(wo,Ul){return Number(wo)-Number(Ul)}).reverse()[0]),y=this.diagram.nameTable[""+e].zIndex,S=[],M=0;M<=v;M++)S.push(l[parseInt(M.toString(),10)]);if("SwimLane"===this.diagram.nameTable[""+e].shape.type)for(var C=v;C>=y;C--)if(l[parseInt(C.toString(),10)]&&this.diagram.nameTable[l[parseInt(C.toString(),10)]].parentId!==e){v=C;break}var D=this.diagram.nameTable[""+e];if(D.zIndexx&&(x=L.zIndex)}}else x=d;D.zIndex=x+((-1!==r.indexOf(D)?r.indexOf(D):0)+1),this.triggerOrderCommand(A,D,D)}else if("SwimLane"===D.shape.type){for(var O=0,N=-1,T=0,z=0,U=JSON.parse(JSON.stringify(l)),B=0;B<=y;B++)if(l[parseInt(B.toString(),10)]&&this.diagram.nameTable[l[parseInt(B.toString(),10)]].parentId===e&&-1===N){N=B,T=B;break}for(var j=0;j<=v;j++)p[parseInt(j.toString(),10)]&&p[parseInt(j.toString(),10)]!==e&&this.diagram.nameTable[p[parseInt(j.toString(),10)]].parentId!==e&&this.diagram.nameTable[p[parseInt(j.toString(),10)]].zIndex>=this.diagram.nameTable[""+e].zIndex&&O++;for(var ue=N,fe=0;fe<=O;fe++){for(;!l[parseInt(ue.toString(),10)];)ue++;z=this.diagram.nameTable[l[parseInt(ue.toString(),10)]].zIndex,ue++}for(var Me=z;Me<=v;Me++){for(;!U[parseInt(N.toString(),10)];)N++;for(;!l[parseInt(Me.toString(),10)];)Me++;l[parseInt(Me.toString(),10)]=U[parseInt(N.toString(),10)],this.diagram.nameTable[l[parseInt(Me.toString(),10)]].zIndex=Me,N++}l[parseInt(v.toString(),10)]=this.diagram.nameTable[""+e].id,this.diagram.nameTable[""+e].zIndex=v,ue=y+1;for(var De=T,xe=0;xe0&&("Native"===hr[0].shape.type||"HTML"===hr[0].shape.type)){for(Ci.parentNode.removeChild(Ci),De=0;De0?r[0]:null},n.prototype.findLowestZIndex=function(t,e){var r=this.diagram.nodes.filter(function(s){return-1!==e.indexOf(s.id)}).filter(function(s){return""===s.parentId&&s.id!==t.id}).map(function(s){return s.zIndex});return r.sort(function(s,o){return s-o}),r.length>0?r[0]:null},n.prototype.triggerOrderCommand=function(t,e,i){var s={zIndex:$(t).zIndex},o={zIndex:e.zIndex},a={element:i,cause:this.diagram.diagramActions,diagramAction:this.diagram.getDiagramAction(this.diagram.diagramActions),oldValue:s,newValue:o};this.diagram.triggerEvent(Ce.propertyChange,a)},n.prototype.checkGroupNode=function(t,e,i){return i[""+e].parentId===i[""+t].parentId},n.prototype.sortByZIndex=function(t,e,i){if("BringForward"===i){var r=e||"zIndex";t=t.sort(function(o,a){return a[""+r]-o[""+r]})}else{var s=e||"zIndex";t=t.sort(function(o,a){return o[""+s]-a[""+s]})}return t},n.prototype.orderCommands=function(t,e,i){var r=this,s=e.nodes;if(s=s.concat(e.connectors),t)if("SendBackward"===i)for(var o=0;oa}),S=v.filter(function(D){return D0?Math.max.apply(Math,S):a,M=y.length>0?Math.min.apply(Math,y):a;if(a!==M){var w=c.zIndexTable[parseInt(M.toString(),10)],C=c.zIndexTable[parseInt(a.toString(),10)];this.moveSvgNode(C,w)}else"SendToBack"===i&&(w=c.zIndexTable[parseInt(a.toString(),10)],C=c.zIndexTable[parseInt(b.toString(),10)],this.moveAfterSvgNode(w,C))}}else this.diagram.refreshCanvasLayers()}},n.prototype.swapDomOrder=function(t,e){if(t){var i=this.diagram.getObject(e);if("Native"===i.shape.type||"HTML"===i.shape.type)this.updateNativeNodeIndex(e,t),this.updateNativeNodeIndex(t,e);else{var r=xt(e+"_groupElement",this.diagram.element.id),s=xt(t+"_groupElement",this.diagram.element.id);r.parentNode.insertBefore(r,s),r.parentNode.insertBefore(s,r)}}},n.prototype.sendForward=function(t){var e=this;if(this.diagram.protectPropertyChange(!0),$a(this.diagram)||t){$(t||(this.diagram.selectedItems.nodes.length?this.diagram.selectedItems.nodes[0]:this.diagram.selectedItems.connectors[0]));var s=t&&t.id,o=this.diagram.layers.indexOf(this.getObjectLayer(s=s||(this.diagram.selectedItems.nodes.length?this.diagram.selectedItems.nodes[0].id:this.diagram.selectedItems.connectors[0].id))),a=$(this.diagram.nameTable),h=(parseInt(o.toString(),10),this.diagram.nameTable[""+s]),c=[],d=this.diagram.spatialSearch.findObjects(h.wrapper.bounds);d.length>2&&(d=this.sortByZIndex(d,void 0,"BringForward"));for(var u=0,f=d;u=0;p--)this.diagram.nameTable[c[parseInt(p.toString(),10)].id].parentId===s&&c.splice(p,1);if(c.length>0){var y=this.diagram.nameTable[c[c.length-1].id];if(y.parentId){var b=om(y,this.diagram,""),M=this.diagram.nameTable[""+b];M.id!==s&&(c[0]=M)}var w={};for(p=0;p0&&(Object.values(O).forEach(function(ue){ue>=T&&N.push(ue)}),0!==N.length&&this.updateZIndexBySendForward(h,N,o))}var z=[];if(Object.keys(this.changedNodeZIndexes).forEach(function(ue){if((a[""+ue]?a[""+ue].zIndex:null)!==e.changedNodeZIndexes[""+ue]){var De=$(a[""+ue]);z.push(De)}}),this.updateLayerZindexTable(o),L.nodes.splice(0,L.nodes.length),z.forEach(function(ue){var fe=$(ue);L.nodes.push(fe)}),"SVG"===this.diagram.mode){var U=c[c.length-1].id,B=c[c.length-1];B&&!("HTML"===B.shape.type||"Native"===B.shape.type)&&this.moveAfterSvgNode(s,U),this.updateNativeNodeIndex(U,s)}else this.diagram.refreshCanvasLayers();var j=[];Object.keys(this.changedNodeZIndexes).forEach(function(ue){if((a[""+ue]?a[""+ue].zIndex:null)!==e.changedNodeZIndexes[""+ue]){var De=$(e.diagram.nameTable[""+ue]);j.push(De)}});var Q=$(this.diagram.selectedItems);Q.nodes.splice(0,Q.nodes.length),j.forEach(function(ue){var fe=$(ue);Q.nodes.push(fe)}),this.diagram.diagramActions&ee.UndoRedo||this.addHistoryEntry({type:"SendForward",category:"Internal",undoObject:L,redoObject:Q}),this.diagram.endGroupAction()}}this.diagram.protectPropertyChange(!1)},n.prototype.updateZIndexBySendForward=function(t,e,i){var r=$(t);t.zIndex=Math.min.apply(Math,e);var a,s=Math.min.apply(Math,e),o=Math.min.apply(Math,e),l=this.diagram.layers[parseInt(i.toString(),10)].objects,h=this.diagram.nodes.filter(function(S){return-1!==l.indexOf(S.id)});t.children&&this.updateGroupZindex(t,"BringForward",t.zIndex);var c=h.filter(function(S){return S.zIndex===Math.min.apply(Math,e)&&S.id!==t.id});if(c&&c.length>0&&c[0].children){for(var d=Math.min.apply(Math,e),u=0;uo&&g!==t&&g.parentId!==t.id&&c&&c.length>0&&g.parentId!==c[0].id){var v=$(g);g.zIndex=a+1,a++,this.triggerOrderCommand(v,g,g)}var y=g.zIndex;this.changedNodeZIndexes[g.id]=(this.changedNodeZIndexes.hasOwnProperty(g.id),y)}},n.prototype.arrangeZIndexForLowerNodes=function(t,e,i){var r=i.filter(function(o){return o.zIndex<=t&&o.parentId!==e.id});r.sort(function(o,a){return a.zIndex-o.zIndex});for(var s=0;se&&(e=r.zIndex)}return e},n.prototype.sendBackward=function(t){var e=this;if(this.diagram.protectPropertyChange(!0),$a(this.diagram)||t){$(t||(this.diagram.selectedItems.nodes.length?this.diagram.selectedItems.nodes[0]:this.diagram.selectedItems.connectors[0]));var s=t&&t.id,o=this.diagram.layers.indexOf(this.getObjectLayer(s=s||(this.diagram.selectedItems.nodes.length?this.diagram.selectedItems.nodes[0].id:this.diagram.selectedItems.connectors[0].id))),a=$(this.diagram.nameTable),h=(parseInt(o.toString(),10),this.diagram.nameTable[""+s]),c=[],d=this.diagram.spatialSearch.findObjects(h.wrapper.bounds);d.length>2&&(d=this.sortByZIndex(d));for(var u=0,f=d;uNumber(p.zIndex)&&""===p.parentId&&h.wrapper.bounds.intersects(p.wrapper.bounds)&&c.push(p);for(var p=c.length-1;p>=0;p--)(v=this.diagram.nameTable[c[parseInt(p.toString(),10)].id]).parentId===s&&c.splice(p,1);if(c.length>0){var v;if((v=this.diagram.nameTable[c[c.length-1].id]).parentId){var S=om(v,this.diagram,""),b=this.diagram.nameTable[""+S];s!==b.id&&(c[c.length-1]=b)}var M={};for(p=0;p0&&(Object.values(L).forEach(function(fe){fe<=N&&O.push(fe)}),0!==O.length&&this.updateZIndexBySendBackward(h,O,o))}var T=[];if(Object.keys(this.changedNodeZIndexes).forEach(function(fe){if((a[""+fe]?a[""+fe].zIndex:null)!==e.changedNodeZIndexes[""+fe]){var xe=$(a[""+fe]);T.push(xe)}}),this.updateLayerZindexTable(o),P.nodes.splice(0,P.nodes.length),T.forEach(function(fe){var Me=$(fe);P.nodes.push(Me)}),"SVG"===this.diagram.mode){var z=c[c.length-1].id,U=c[c.length-1];U&&"HTML"!==U.shape.type&&"Native"!==U.shape.type&&this.moveSvgNode(s,z);var B=this.diagram.nameTable[""+z];B.children&&B.children.length>0?this.updateNativeNodeIndex(s):this.updateNativeNodeIndex(s,z)}else this.diagram.refreshCanvasLayers();var j=[];Object.keys(this.changedNodeZIndexes).forEach(function(fe){if((a[""+fe]?a[""+fe].zIndex:null)!==e.changedNodeZIndexes[""+fe]){var xe=$(e.diagram.nameTable[""+fe]);j.push(xe)}});var Q=$(this.diagram.selectedItems);Q.nodes.splice(0,Q.nodes.length),j.forEach(function(fe){var Me=$(fe);Q.nodes.push(Me)}),this.diagram.diagramActions&ee.UndoRedo||this.addHistoryEntry({type:"SendBackward",category:"Internal",undoObject:P,redoObject:Q}),this.diagram.endGroupAction()}}this.diagram.protectPropertyChange(!1)},n.prototype.updateZIndexBySendBackward=function(t,e,i){var r=$(t);t.zIndex=Math.max.apply(Math,e);var f,s=t.zIndex,o=Math.max.apply(Math,e),a=this.diagram.layers[parseInt(i.toString(),10)].objects,l=this.diagram.nodes.filter(function(S){return-1!==a.indexOf(S.id)}),h=l.filter(function(S){return S.zIndex===Math.max.apply(Math,e)&&S.id!==t.id});if(h&&h.length>0&&h[0].children)for(var c=Math.max.apply(Math,e),d=0;d0&&g.parentId!==h[0].id){var v=$(g);g.zIndex=f-1,f--,this.triggerOrderCommand(v,g,g)}var y=g.zIndex;this.changedNodeZIndexes[""+g.id]=(this.changedNodeZIndexes.hasOwnProperty(g.id),y)}},n.prototype.findLowestChildZIndex=function(t){for(var e=t.zIndex,i=0;i0),this.selectObjects([t],!0))},n.prototype.clearSelection=function(t,e){return MT(this,void 0,void 0,function(){var i,r,s,o;return wT(this,function(a){return i=this.diagram.allowServerDataBinding,this.diagram.enableServerDataBinding(!1),$a(this.diagram)&&(r=this.diagram.selectedItems,s=this.getSelectedObject(),this.diagram.currentSymbol&&(this.diagram.previousSelectedObject=s),o={oldValue:s,newValue:[],cause:this.diagram.diagramActions,state:"Changing",type:"Removal",cancel:!1},t&&(ce()||this.diagram.triggerEvent(Ce.selectionChange,o)),o.cancel||(r.offsetX=0,r.offsetY=0,r.width=0,r.height=0,r.rotateAngle=0,r.nodes=[],r.connectors=[],r.wrapper=null,r.annotation=void 0,r.selectedObjects=[],this.diagram.clearSelectorLayer(),t&&(o={oldValue:s,newValue:[],cause:this.diagram.diagramActions,state:"Changed",type:"Removal",cancel:!1},ce()||this.diagram.triggerEvent(Ce.selectionChange,o))),this.diagram.enableServerDataBinding(i)),[2]})})},n.prototype.clearSelectedItems=function(){this.clearSelection((this.diagram.selectedItems.nodes?this.diagram.selectedItems.nodes.length:0)+(this.diagram.selectedItems.connectors?this.diagram.selectedItems.connectors.length:0)>0)},n.prototype.removeStackHighlighter=function(){var t=Bl(this.diagram.element.id),e=t.getElementById(t.id+"_stack_highlighter");e&&e.parentNode.removeChild(e)},n.prototype.renderStackHighlighter=function(t,e){var r,s,o,i=this.diagram.selectedItems.nodes[0];if(!e){var a=this.diagram.findObjectsUnderMouse(t.position);if((e=this.diagram.findObjectUnderMouse(a,"Drag",!0))&&!(e.isLane||e.isPhase||e.isHeader))for(var l=0;l0)for(var a=0;a1)if(i){var h=l.segments[0],c=l.segments[1],u=Nl(CI(t.wrapper,t.wrapper.corners,t.wrapper.bounds),h.direction),g=Ol({corners:void 0,point:u=qa(l,0,u,{x:l.sourceWrapper.offsetX,y:l.sourceWrapper.offsetY},!1),margin:void 0,direction:h.direction},{corners:void 0,point:c.points[1],margin:void 0,direction:void 0});h.length=R.distancePoints(g[0],g[1]),c.direction&&c.length&&(c.length=R.distancePoints(g[1],g[2]))}else if(o){switch(l.segments[0].direction){case"Bottom":r=t.wrapper.bounds.bottomCenter.x-e.bottomCenter.x,s=t.wrapper.bounds.bottomCenter.y-e.bottomCenter.y;break;case"Top":r=t.wrapper.bounds.topCenter.x-e.topCenter.x,s=t.wrapper.bounds.topCenter.y-e.topCenter.y;break;case"Left":r=t.wrapper.bounds.middleLeft.x-e.middleLeft.x,s=t.wrapper.bounds.middleLeft.y-e.middleLeft.y;break;case"Right":r=t.wrapper.bounds.middleRight.x-e.middleRight.x,s=t.wrapper.bounds.middleRight.y-e.middleRight.y}this.dragSourceEnd(l,r,s,!0,null,"ConnectorSourceEnd",void 0,void 0,void 0,!(t.parentId&&this.diagram.diagramActions&ee.isGroupDragging))}}},n.prototype.updateEndPoint=function(t,e){var r={sourcePoint:t.sourcePoint,targetPoint:t.targetPoint};t.sourceID&&(r.sourceID=t.sourceID),t.targetID&&(r.targetID=t.targetID),t.sourcePortID&&(r.sourcePortID=t.sourcePortID),t.targetPortID&&(r.targetPortID=t.targetPortID),t.segments&&(r.segments=t.segments),this.diagram.connectorPropertyChange(t,e||{},r),this.diagram.updateSelector()},n.prototype.dragSourceEnd=function(t,e,i,r,s,o,a,l,h,c,d){var u=this.diagram.nameTable[t.id],f={},p=this.checkBoundaryConstraints(e,i,u.wrapper.bounds);if(AI(u)&&p&&"BezierSourceThumb"!==o&&Vv(this.diagram)&&(f=$(f={sourcePoint:u.sourcePoint}),u.sourcePoint.x+=e,u.sourcePoint.y+=i,"ConnectorSourceEnd"===o&&"Orthogonal"===u.type&&this.changeSegmentLength(u,l,h,c),"Bpmn"===u.shape.type&&"Default"===u.shape.sequence&&"Sequence"===u.shape.flow&&this.updatePathElementOffset(u)),"Bezier"===u.type)if(f={sourcePoint:u.sourcePoint},d)this.translateBezierPoints(t,""===o?"ConnectorSourceEnd":o,e,i,d,s,!a);else for(var g=0;g2){var d=R.direction((c=t.segments[2]).points[0],c.points[1]);o.direction===_n(d)?("Right"===o.direction?c.points[0].x=o.points[o.points.length-1].x=l.wrapper.corners.middleRight.x+20:"Left"===o.direction?c.points[0].x=o.points[o.points.length-1].x=l.wrapper.corners.middleLeft.x-20:c.points[0].y=o.points[o.points.length-1].y="Top"===o.direction?l.wrapper.corners.topCenter.y-20:l.wrapper.corners.bottomCenter.y+20,c.direction&&c.length&&(c.length=R.distancePoints(c.points[0],c.points[c.points.length-1])),o.length=R.distancePoints(o.points[0],o.points[o.points.length-1])):o.direction===d&&c.direction&&c.length?("Top"===o.direction||"Bottom"===o.direction?(c.points[0]=o.points[0],c.points[c.points.length-1].x=c.points[0].x):(c.points[0]=o.points[0],c.points[c.points.length-1].y=c.points[0].y),c.length=R.distancePoints(c.points[0],c.points[c.points.length-1]),t.segments.splice(0,2)):o.length=20}else o.length=20;else if(o.length<1)if(""!==t.sourceID){var c;"Right"===a.direction?a.points[a.points.length-1].y=(h=l.wrapper.corners.middleRight).y:"Left"===a.direction?a.points[a.points.length-1].y=(h=l.wrapper.corners.middleLeft).y:a.points[a.points.length-1].x="Top"===a.direction?(h=l.wrapper.corners.topCenter).x:(h=l.wrapper.corners.bottomCenter).x,a.length=R.distancePoints(h,a.points[a.points.length-1]),t.segments.length>2&&(c=t.segments[2]).direction&&c.length&&(c.length=R.distancePoints(a.points[a.points.length-1],c.points[c.points.length-1])),t.segments.splice(0,1)}else t.segments.splice(0,1)}else e&&!i&&t.sourceID!==e.id&&t.segments&&null!==t.segments[0].direction&&e&&e instanceof te&&s&&this.changeSourceEndToNode(t,e),e&&i&&t.sourcePortID!==i&&t.segments&&null!==t.segments[0].direction&&e&&e instanceof te&&s&&this.changeSourceEndToPort(t,e,i)},n.prototype.canConnect=function(t,e){return!(!ua(e)||!Ph(e))},n.prototype.changeSourceEndToPort=function(t,e,i){var r=this.diagram.getWrapper(e.wrapper,i),s={x:r.offsetX,y:r.offsetY},o=zo(s,xn(e.wrapper),e.wrapper.bounds),a=t.segments[0],l=t.segments[1];if(a.direction!==o){var h=[],c={};if(a.direction===_n(o)){c={};var d=void 0;"Top"===o||"Bottom"===o?(d="Top"===o?{type:"Orthogonal",isTerminal:!0,direction:o,length:Math.abs(a.points[0].y-s.y)}:{type:"Orthogonal",isTerminal:!0,direction:o,length:Math.abs(s.y-a.points[0].y)},c=a.points[0].x>s.x?{type:"Orthogonal",isTerminal:!0,direction:"Right",length:a.points[0].x-s.x}:{type:"Orthogonal",isTerminal:!0,direction:"Left",length:s.x-a.points[0].x}):(d="Right"===o?{type:"Orthogonal",isTerminal:!0,direction:o,length:Math.abs(a.points[0].x-s.x)}:{type:"Orthogonal",isTerminal:!0,direction:o,length:Math.abs(s.x-a.points[0].x)},c=a.points[0].y>s.y?{type:"Orthogonal",direction:"Top",isTerminal:!0,length:a.points[0].y-s.y}:{type:"Orthogonal",direction:"Bottom",isTerminal:!0,length:s.y-a.points[0].y}),h.push(new wi(t,"segments",d,!0)),h.push(new wi(t,"segments",c,!0))}else h.push(new wi(t,"segments",c={type:"Orthogonal",direction:o,length:20,isTerminal:!0},!0));a.direction!==_n(o)&&("Top"===o||"Bottom"===o?(a.points[0].x=s.x,a.points[0].y=a.points[a.points.length-1].y="Top"===o?s.y-20:s.y+20):(a.points[0].y=s.y,a.points[0].x=a.points[a.points.length-1].x="Right"===o?s.x+20:s.x-20),a.length=R.distancePoints(a.points[0],a.points[a.points.length-1]),l.length=R.distancePoints(a.points[a.points.length-1],l.points[l.points.length-1])),t.segments=h.concat(t.segments)}else a.points[0]=s,"Top"===o||"Bottom"===o?a.points[a.points.length-1].x=s.x:a.points[a.points.length-1].y=s.y,a.length=R.distancePoints(a.points[0],a.points[a.points.length-1]),l.length=R.distancePoints(a.points[a.points.length-1],l.points[l.points.length-1])},n.prototype.removeTerminalSegment=function(t,e){for(var i=0;ii.width||"Left"===o.direction&&r.x>=o.points[0].x||"Right"===o.direction&&r.x<=o.points[0].x)o.points[0].y=o.points[o.points.length-1].y=r.y,o.points[0].x=r.x,o.length=R.distancePoints(o.points[0],o.points[o.points.length-1]),a.length=R.distancePoints(o.points[o.points.length-1],a.points[a.points.length-1]);else{var h=void 0;s="Bottom"===(h=a.direction?a.direction:R.direction(a.points[0],a.points[a.points.length-1]))?i.bottomCenter:i.topCenter,a.length&&a.direction&&(a.length="Top"===h?o.points[o.points.length-1].y-(s.y+20):s.y+20-o.points[o.points.length-1].y),o.length=o.points[o.points.length-1].x-s.x,o.direction=o.length>0?"Right":"Left",l.push(new wi(t,"segments",{type:"Orthogonal",direction:h,length:20},!0)),t.segments=l.concat(t.segments)}else r="Bottom"===o.direction?i.bottomCenter:i.topCenter,o.length>i.height||"Top"===o.direction&&r.y>=o.points[0].y||"Bottom"===o.direction&&r.y<=o.points[0].y?(o.points[0].x=o.points[o.points.length-1].x=r.x,o.points[0].y=r.y,o.length=R.distancePoints(o.points[0],o.points[o.points.length-1]),a.length=R.distancePoints(o.points[o.points.length-1],a.points[a.points.length-1])):(s="Left"===a.direction?i.middleLeft:i.middleRight,h=void 0,h=a.direction?a.direction:R.direction(a.points[0],a.points[a.points.length-1]),a.length&&a.direction&&(a.length="Left"===h?o.points[o.points.length-1].x-(s.x+20):s.x+20-o.points[o.points.length-1].x),o.length=o.points[o.points.length-1].y-s.y,o.direction=o.length>0?"Bottom":"Top",l.push(new wi(t,"segments",{type:"Orthogonal",direction:h,length:20},!0)),t.segments=l.concat(t.segments))},n.prototype.translateBezierPoints=function(t,e,i,r,s,o,a){var l=t.segments.indexOf(s),h=t.segments[parseInt(l.toString(),10)],c=l>0?t.segments[l-1]:null,d=null!==c?c.point:t.sourcePoint,u=l===t.segments.length-1?t.targetPoint:h.point;if(h)if("BezierSourceThumb"===e&&(h.vector1.angle||h.vector1.distance)){var f=h.vector1.distance,p=h.vector1.angle;h.vector1={distance:t.distance(d,o),angle:R.findAngle(d,o)},this.translateSubsequentSegment(t,s,!0,h.vector1.distance-f,h.vector1.angle-p)}else"BezierTargetThumb"===e&&(h.vector2.angle||h.vector2.distance)?(f=h.vector2.distance,p=h.vector2.angle,h.vector2={distance:t.distance(u,o),angle:R.findAngle(u,o)},this.translateSubsequentSegment(t,s,!1,h.vector2.distance-f,h.vector2.angle-p)):("ConnectorSourceEnd"===e&&!t.sourceID||"ConnectorTargetEnd"===e&&!t.targetID)&&a&&GI(h.vector1)&&GI(h.vector2)?(R.isEmptyPoint(h.point1)&&(h.bezierPoint1=XI(t.sourcePoint,t.targetPoint)),R.isEmptyPoint(h.point2)&&(h.bezierPoint2=XI(t.targetPoint,t.sourcePoint))):"BezierSourceThumb"===e||"ConnectorSourceEnd"===e&&!a&&GI(h.vector1)?(h.bezierPoint1.x+=i,h.bezierPoint1.y+=r,(!R.isEmptyPoint(h.point1)||a)&&(h.point1={x:h.bezierPoint1.x,y:h.bezierPoint1.y})):("BezierTargetThumb"===e||"ConnectorTargetEnd"===e&&!a&&GI(h.vector2))&&(h.bezierPoint2.x+=i,h.bezierPoint2.y+=r,(!R.isEmptyPoint(h.point2)||a)&&(h.point2={x:h.bezierPoint2.x,y:h.bezierPoint2.y}))},n.prototype.translateSubsequentSegment=function(t,e,i,r,s){var o=t.segments.indexOf(e);parseInt(o.toString(),10),t.bezierSettings.smoothness&SI.SymmetricAngle||(s=null),t.bezierSettings.smoothness&SI.SymmetricDistance||(r=null),(null!=r||null!=s)&&(i?0!==o&&this.updatePreviousBezierSegment(t,o,r,s):o!==t.segments.length-1&&this.updateNextBezierSegment(t,o,r,s))},n.prototype.updatePreviousBezierSegment=function(t,e,i,r){var s=t.segments[e-1],a=(s.vector2.angle+r)%360;a<0&&(a+=360),s.vector2={distance:s.vector2.distance+i,angle:a}},n.prototype.updateNextBezierSegment=function(t,e,i,r){var s=t.segments[e+1],a=(s.vector1.angle+r)%360;a<0&&(a+=360),s.vector1={distance:s.vector1.distance+i,angle:a}},n.prototype.dragTargetEnd=function(t,e,i,r,s,o,a,l){var c,h=this.diagram.nameTable[t.id],d=this.checkBoundaryConstraints(e,i,h.wrapper.bounds);if(LI(h)&&"BezierTargetThumb"!==o&&d&&Vv(this.diagram)){if(c=$(c={targetPoint:h.targetPoint}),h.targetPoint.x+=e,h.targetPoint.y+=i,"ConnectorTargetEnd"===o&&"Orthogonal"===h.type&&h.segments&&h.segments.length>0){var u=h.segments[h.segments.length-2];u&&2===h.segments[h.segments.length-1].points.length&&("Left"===u.direction||"Right"===u.direction?u.points[u.points.length-1].x=h.targetPoint.x:u.points[u.points.length-1].y=h.targetPoint.y,u.length=R.distancePoints(u.points[0],u.points[u.points.length-1]),u.direction=R.direction(u.points[0],u.points[u.points.length-1]))}"Bpmn"===h.shape.type&&"Default"===h.shape.sequence&&"Sequence"===h.shape.flow&&this.updatePathElementOffset(h)}if("Bezier"===h.type)if(c={targetPoint:h.targetPoint},l)this.translateBezierPoints(t,""===o?"ConnectorTargetEnd":o,e,i,l,s,!a);else for(var f=0;f0){if(void 0!==s&&o.segments[parseInt(s.toString(),10)])if("Bezier"===o.type){var a=o.segments[parseInt(s.toString(),10)],l=a.isInternalSegment;l&&null!==o.bezierSettings&&"FreeForm"!==o.bezierSettings.segmentEditOrientation?("Horizontal"===a.orientation?a.point.x+=e:a.point.y+=i,this.updateDirectionalBezierCurve(o)):(a.point.x+=e,a.point.y+=i),l&&(o.isBezierEditing=!0)}else o.segments[parseInt(s.toString(),10)].point.x+=e,o.segments[parseInt(s.toString(),10)].point.y+=i;else for(var h=0;h1){var a=e[1],l=e[2],h={x:.5*(a.x+l.x),y:.5*(a.y+l.y)},c=t.segments[0];c.vector1.angle=Xt(s,a),c.vector1.distance=.5*R.findLength(s,a),c.vector2.angle=Xt(h,a),c.vector2.distance=.5*R.findLength(h,a),c.point=h;var d=t.segments[1];if(d.vector1.angle=Xt(h,l),d.vector1.distance=.5*R.findLength(h,l),t.segments.length>2){var u=e[3],f={x:.5*(l.x+u.x),y:.5*(l.y+u.y)};d.vector2.angle=Xt(f,l),d.vector2.distance=.5*R.findLength(f,l),d.point=f;var p=t.segments[2];if(p.vector1.angle=Xt(f,u),p.vector1.distance=.5*R.findLength(f,u),t.segments.length>3){var g=e[4],v={x:.5*(u.x+g.x),y:.5*(u.y+g.y)};p.vector2.angle=Xt(v,u),p.vector2.distance=.5*R.findLength(v,u),p.point=v;var y=t.segments[3];y.vector1.angle=Xt(v,g),y.vector1.distance=.5*R.findLength(v,g),y.vector2.angle=Xt(o,g),y.vector2.distance=.5*R.findLength(o,g)}else p.vector2.angle=Xt(o,u),p.vector2.distance=.5*R.findLength(o,u)}else d.vector2.angle=Xt(o,l),d.vector2.distance=.5*R.findLength(o,l)}},n.prototype.rotateObjects=function(t,e,i,r,s){r=r||{};var o=Bi();qi(o,i,r.x,r.y);for(var l=0,h=e;l0){this.diagram.protectPropertyChange(!0);var o=t;o.segments=[],this.diagram.connectorPropertyChange(o,{},{segments:o.segments}),this.diagram.protectPropertyChange(!1)}}},n.prototype.updateInnerParentProperties=function(t){var r=this.diagram.isProtectedOnChange;this.diagram.protectPropertyChange(!0);for(var s=this.getAllDescendants(t,[],!1,!0),o=0;o0&&(f=this.diagram.bpmnModule.getChildrenBound(d,d.id,this.diagram),u=d.wrapper.bounds.containsRect(f)),h=d.wrapper.actualSize.width*t,c=d.wrapper.actualSize.height*e,void 0!==d.maxWidth&&0!==d.maxWidth&&(h=Math.min(d.maxWidth,h)),void 0!==d.minWidth&&0!==d.minWidth&&(h=Math.max(d.minWidth,h)),void 0!==d.maxHeight&&0!==d.maxHeight&&(c=Math.min(d.maxHeight,c)),void 0!==d.minHeight&&0!==d.minHeight&&(c=Math.max(d.minHeight,c)),u&&(h=Math.max(h,f.right-d.wrapper.bounds.x),c=Math.max(c,f.bottom-d.wrapper.bounds.y)),t=h/d.actualSize.width,e=c/d.actualSize.height}var p=Bi();o||(o=r);var g=o.wrapper;if(qi(p,-g.rotateAngle,i.x,i.y),Yf(p,t,e,i.x,i.y),qi(p,g.rotateAngle,i.x,i.y),r instanceof te){var d,v=Ke(p,{x:(d=r).wrapper.offsetX,y:d.wrapper.offsetY}),y=d.wrapper.offsetX-d.wrapper.actualSize.width*d.pivot.x,S=d.wrapper.offsetY-d.wrapper.actualSize.height*d.pivot.y;if(h>0)if(d.processId){var b=this.diagram.nameTable[d.processId];(!b.maxWidth||d.margin.left+h0)if(d.processId){var M=this.diagram.nameTable[d.processId];(!M.maxHeight||d.margin.top+c0){if(e.dragLimit=e.dragLimit?e.dragLimit:{},e.dragLimit.top||e.dragLimit.bottom||e.dragLimit.left||e.dragLimit.right){var b={minDistance:null};S=this.getRelativeOffset(v,d,b);var M={minDistance:null};g=this.getRelativeOffset(v,y,M),S=null!=b&&M.minDistance0){if(S=y[y.length-1]){var b=void 0;for(b=0;b=e.x-t.dragLimit.left-r.width/2&&i.x<=e.x+t.dragLimit.right+r.width/2&&(s=!0),i.y>=e.y-t.dragLimit.top-r.height/2&&i.y<=e.y+t.dragLimit.bottom+r.height/2&&(o=!0),{x:s,y:o}},n.prototype.updateLabelMargin=function(t,e,i,r,s,o,a){if(i=i||{x:e.offset,y:0},e&&i&&i.x>0&&i.x<1){var l=R.getLengthFromListOfPoints(t.intermediatePoints),h=this.getPointAtLength(l*i.x,t.intermediatePoints,0),c=this.diagram.scrollSettings.currentZoom,d=e.dragLimit?e.dragLimit:{left:0,right:0,top:0,bottom:0};if(d.top||d.bottom||d.left||d.right){this.diagram.getWrapper(t.wrapper,e.id);var f=new Ne(0,0,0,0),p=this.diagram.getWrapper(t.wrapper,e.id);f.x=p.offsetX/c+o,f.y=p.offsetY/c+a,f.width=p.bounds.width/c,f.height=p.bounds.height/c;var g=new Ne(h.x-(d.left||0)-f.width/2,h.y-(d.top||0)-f.height/2,(d.left||0)+(d.right||0)+f.width,(d.top||0)+(d.bottom||0)+f.height);if(g.containsPoint(r));else for(var S=0,b=this.boundsInterSects([h,r],g,!1);S=t){c=t-r,d=R.findAngle(s,a),u=c*Math.cos(d*Math.PI/180),f=c*Math.sin(d*Math.PI/180),o={x:s.x+u,y:s.y+f};break}r+=h,s=a}else s=a;return o},n.prototype.getInterceptWithSegment=function(t,e){for(var o,a,i=[],r=[],s=[],l=R.findLength({x:0,y:0},{x:this.diagram.scroller.viewPortWidth,y:this.diagram.scroller.viewPortHeight}),h=1;h0&&a<=90||a>180&&a<=270?90:-90;r.push(R.transform(t,a+c,l)),r.push(R.transform(t,o+c,l));var f=tm({x1:s[0].x,y1:s[0].y,x2:s[1].x,y2:s[1].y},{x1:r[0].x,y1:r[0].y,x2:r[1].x,y2:r[1].y});f.enabled&&i.push(f.intersectPt)}return i},n.prototype.getAnnotationChanges=function(t,e){var r={};return r[ib(t,e.id,!0)]={width:e.width,height:e.height,offset:t instanceof te?{x:e.offset.x,y:e.offset.y}:e.offset,rotateAngle:e.rotateAngle,margin:{left:e.margin.left,right:e.margin.right,top:e.margin.top,bottom:e.margin.bottom},horizontalAlignment:e.horizontalAlignment,verticalAlignment:e.verticalAlignment,alignment:t instanceof de?e.alignment:void 0},{annotations:r}},n.prototype.getConnectorPortChanges=function(t,e){var i=function kse(n,t,e){for(var i=n.ports,r=0;r1&&(v.width=g,v.offset.x=1/S),p>1&&(v.height=p,v.offset.y=1/b)}}e instanceof Or&&(e.alignment="Center"),l=this.getAnnotationChanges(t,e),t instanceof te?this.diagram.nodePropertyChange(t,a,l):this.diagram.connectorPropertyChange(t,a,l),this.diagram.updateDiagramObject(t)},n.prototype.getSubProcess=function(t){var i,e={nodes:[],connectors:[]};return t instanceof te?i=t.processId:t&&t.nodes&&t.nodes.length&&t.nodes[0].processId&&(i=t.nodes[0].processId),i&&e.nodes.push($(this.diagram.nameTable[i])),e},n.prototype.checkBoundaryConstraints=function(t,e,i,r){var s=this.diagram.pageSettings,o=this.diagram.pageSettings.boundaryConstraints,a=this.diagram.scroller;if("Page"===o||"Diagram"===o){var l=i?void 0:this.diagram.selectedItems.wrapper.bounds;return!!((i?i.right:l.right)+(t||0)<=("Page"===o?s.width:a.viewPortWidth)&&(i?i.left:l.left)+(t||0)>=0&&(i?i.bottom:l.bottom)+(e||0)<=("Page"===o?s.height:a.viewPortHeight)&&(i?i.top:l.top)+(e||0)>=0||"None"!==this.diagram.layout.type&&r)}return!0},n.prototype.dragSelectedObjects=function(t,e){var i=this,r=this.diagram.selectedItems;this.state&&!this.state.backup&&(this.state.backup={},this.state.backup.offsetX=r.offsetX,this.state.backup.offsetY=r.offsetY),r=VI(this.diagram,r)||r;var s=this.diagram.selectedItems.nodes.filter(function(c){return"SwimLane"===c.shape.type});if(s.length>0&&!this.diagram.currentSymbol&&this.diagram.selectedItems.nodes.length>1){var o=this.diagram.selectedItems.nodes.filter(function(c){return""===c.parentId||"SwimLane"!==i.diagram.nameTable[c.parentId].shape.type});if(o.length>0){for(var a=0;a0||l.length>1)&&(o=o.concat(l),this.diagram.selectedItems.nodes.splice(0,this.diagram.selectedItems.nodes.length),o.forEach(function(c){i.diagram.selectedItems.nodes.push(c)}),r=this.diagram.selectedItems,this.diagram.selectedObject.helperObject=void 0)}}if(this.checkBoundaryConstraints(t,e)){this.diagram.diagramActions=this.diagram.diagramActions|ee.PreventZIndexOnDragging|ee.DragUsingMouse;var h=this.diagram.selectedObject.actualObject;return(h&&h instanceof te&&h.isLane&&Vx(h,this.diagram)||!h||!h.isLane)&&this.diagram.drag(r,t,e),this.diagram.diagramActions=this.diagram.diagramActions&~(ee.PreventZIndexOnDragging|ee.DragUsingMouse),this.diagram.refreshCanvasLayers(),this.checkHtmlObjectDrag(r),!0}return!1},n.prototype.checkHtmlObjectDrag=function(t){var e=!1;this.diagram.views&&this.diagram.views.length>1&&(t instanceof ti?e=t.nodes.some(function(i){return i.shape&&"HTML"===i.shape.type}):t.shape&&"HTML"===t.shape.type&&(e=!0),e&&this.resetOverviewCanvas())},n.prototype.resetOverviewCanvas=function(){for(var t=0,e=this.diagram.views;t0&&(this.layoutAnimateModule.stopCurrentAnimation(this.objectStore[0],e,t),this.objectStore=[]),a=this.diagram.doLayout(),this.objectStore.push(a)),this.canUpdateTemplate=!1,this.diagram.blazorActions&=~on.expandNode,this.diagram.preventNodesUpdate=r,this.diagram.layoutAnimateModule&&this.diagram.organizationalChartModule&&!i)this.diagram.allowServerDataBinding=!1,this.layoutAnimateModule.expand(this.diagram.layout.enableAnimation,a,t,this.diagram);else{var l={element:$(t),state:!!t.isExpanded};this.triggerEvent(Ce.expandStateChange,l),this.diagram.lineRoutingModule&&this.diagram.constraints&nt.LineRouting&&"ComplexHierarchicalTree"!==this.diagram.layout.type&&this.diagram.resetSegments()}return this.diagram.layout.fixedNode=""===o?"":this.diagram.layout.fixedNode,a},n.prototype.getparentexpand=function(t,e,i,r){for(var s,o=0;o0&&(this.diagram.selectedItems.wrapper.rotateAngle=this.diagram.selectedItems.rotateAngle=s.rotateAngle),!(r instanceof te&&"SwimLane"!==r.shape.type)||r.isLane||r.isPhase||r.isHeader||Dn(this.diagram,r)){if(r instanceof ti)for(var d=0;d30||g.wrapper.outerBounds.topCenter.y-p.wrapper.outerBounds.bottomCenter.y>30)&&this.diagram.lineRoutingModule.refreshConnectorSegments(this.diagram,f,!0)}}this.updateSelector(),this.diagram.protectPropertyChange(!1)}},n.prototype.drawSelectionRectangle=function(t,e,i,r){this.diagram.drawSelectionRectangle(t,e,i,r)},n.prototype.startGroupAction=function(){this.diagram.startGroupAction()},n.prototype.endGroupAction=function(){this.diagram.endGroupAction()},n.prototype.removeChildFromBPmn=function(t,e,i){var r=this.diagram.nameTable[t.id]||t.nodes[0];if(i&&r&&r.processId&&r.processId===i.wrapper.id){var s=$(r);s.processId=r.processId,this.diagram.startGroupAction();var o=this.diagram.nameTable[r.processId].shape.activity.subProcess.processes||[];o.splice(o.indexOf(r.id),1),this.diagram.bpmnModule.removeChildFromBPMN(this.diagram.nameTable[r.processId].wrapper,r.id,this.diagram),this.diagram.nameTable[r.id].processId="",r.offsetX=r.wrapper.offsetX,r.offsetY=r.wrapper.offsetY;var a=$(r);this.addHistoryEntry({type:"PositionChanged",redoObject:{nodes:[a]},undoObject:{nodes:[s]},category:"Internal"}),this.diagram.endGroupAction()}},n.prototype.isDroppable=function(t,e){var i=this.diagram.nameTable[t.id]||t.nodes[0];return i instanceof te&&(!ce()&&"TextAnnotation"===i.shape.shape||("Group"===e.shape.shape&&(e.shape.activity.subProcess.collapsed=!1),!(i&&"Bpmn"===i.shape.type&&(i.processId===e.id||i.id===e.processId||"Bpmn"===e.shape.type&&!(e instanceof de)&&e.shape.activity&&e.shape.activity.subProcess&&e.shape.activity.subProcess.collapsed))))},n.prototype.renderHighlighter=function(t,e,i){if(new Ne,t.target instanceof te||t.target instanceof de||e&&(t.source instanceof te||t.source instanceof de)){var a=this.findTarget(e?t.sourceWrapper:t.targetWrapper,e?t.source:t.target,i,!0),l=void 0;if(a instanceof Rd)for(var h=a.id,c=t.target,u=0,f=c.wrapper.children[0].children[0].children[2].children;u0){var r=0;t[0]=this.diagram.nameTable[t[0].id]||t[0];var s="Object"===i?yr(t[0].wrapper):this.diagram.selectedItems.wrapper.bounds,o={nodes:[],connectors:[]},a={nodes:[],connectors:[]};for(r="Object"===i?r+1:r;r0){var i=0,r=0,s=0,o=0,a=0,l=0,h=0,c=0,d={nodes:[],connectors:[]},u={nodes:[],connectors:[]};for(i=0;io.center.y&&(r=n[parseInt(e.toString(),10)],n[parseInt(e.toString(),10)]=n[parseInt(i.toString(),10)],n[parseInt(i.toString(),10)]=r):s.center.x>o.center.x&&(r=n[parseInt(e.toString(),10)],n[parseInt(e.toString(),10)]=n[parseInt(i.toString(),10)],n[parseInt(i.toString(),10)]=r)}}return n}(t,e),i=1;i0){var i=0,r={x:.5,y:.5};t[0]=this.diagram.nameTable[t[0].id]||t[0];var s=yr(t[0].wrapper),o={nodes:[],connectors:[]},a={nodes:[],connectors:[]};for(i=1;ii.zIndex){for(var s=this.diagram.layers.indexOf(this.diagram.getActiveLayer()),o=this.diagram.layers[parseInt(s.toString(),10)].zIndexTable,a=JSON.parse(JSON.stringify(o)),l=i.zIndex,h=r.zIndex,c=h;c>=l;c--)l!==c?o[c-1]?(o[parseInt(c.toString(),10)]=o[c-1],this.diagram.nameTable[o[parseInt(c.toString(),10)]].zIndex=c):(o[c-1]=o[parseInt(c.toString(),10)],this.diagram.nameTable[o[c-1]].zIndex=c,delete o[parseInt(c.toString(),10)]):this.swapZIndexObjects(h,o,r.id,a);"SVG"===this.diagram.mode?(this.moveSvgNode(e.parentId,i.id),this.updateNativeNodeIndex(e.parentId,i.id)):this.diagram.refreshCanvasLayers()}},n.prototype.findLeastIndexConnector=function(t,e,i){for(var r=0;rs.zIndex&&(i=s)}return i},n.prototype.findLeastIndexObject=function(t,e){var i=t;return t instanceof te&&(i=this.findLeastIndexConnector(t.inEdges,e,i),i=this.findLeastIndexConnector(t.outEdges,e,i)),i},n.prototype.checkSelection=function(t,e){var i;if(1===t.nodes.length&&0===t.connectors.length)if(Dn(this.diagram,t.nodes[0],!0)){var r=t.nodes[0];if("SwimLane"===(i="SwimLane"===t.nodes[0].shape?t.nodes[0]:this.diagram.nameTable[t.nodes[0].parentId]).shape.type){var s="Horizontal"===i.shape.orientation;(r.isPhase&&(s&&"ResizeSouth"===e||!s&&"ResizeEast"===e)||r.isLane&&(s&&"ResizeEast"===e||!s&&"ResizeSouth"===e))&&B3(this.diagram,i,e)}else if("Grid"===i.container.type)if("Horizontal"===i.container.orientation&&1===r.rowIndex||"Vertical"===i.container.orientation&&r.rowIndex>0&&r.columnIndex>0){if("ResizeSouth"===e)for(var o=0;o1&&(this.diagram.realActions=this.diagram.realActions|$i.hScrollbarMoved,this.scrolled=!0),this.diagram.scrollSettings.horizontalOffset=t},enumerable:!0,configurable:!0}),Object.defineProperty(n.prototype,"verticalOffset",{get:function(){return this.vOffset},set:function(t){this.vOffset=t,Math.abs(this.vOffset-this.diagram.scrollSettings.verticalOffset)>1&&(this.diagram.realActions=this.diagram.realActions|$i.vScrollbarMoved,this.scrolled=!0),this.diagram.scrollSettings.verticalOffset=t},enumerable:!0,configurable:!0}),n.prototype.getBounds=function(){var e=this.diagram.spatialSearch.getPageBounds(0,0);return(e.x<0||e.y<0)&&!this.diagram.pageSettings.multiplePage?this.getPageBounds(void 0,void 0,!0,!0):this.getPageBounds(void 0,void 0,!0)},n.prototype.updateScrollOffsets=function(t,e){var i,r,s=this.getBounds();s.x*=this.currentZoom,s.y*=this.currentZoom,s.width*=this.currentZoom,s.height*=this.currentZoom,i=Math.max(0,t-s.left),r=Math.max(0,e-s.top),void 0!==t&&void 0!==e?(this.horizontalOffset=i,this.verticalOffset=r,this.diagram.setOffset(i,r)):this.diagram.setOffset(-this.horizontalOffset-s.x,-this.verticalOffset-s.y),this.transform={tx:Math.max(this.horizontalOffset,-s.left)/this.currentZoom,ty:Math.max(this.verticalOffset,-s.top)/this.currentZoom,scale:this.currentZoom}},n.prototype.setScrollOffset=function(t,e){this.scrolled=!1;var i=this.getBounds();i.x*=this.currentZoom,i.y*=this.currentZoom,i.width*=this.currentZoom,i.height*=this.currentZoom;var r=-i.left,s=-i.top,o=!1,a=this.viewPortWidth*this.currentZoom,l=this.viewPortHeight*this.currentZoom,h=r-t;if(h!==this.horizontalOffset){rh?this.horizontalOffset-=t:this.horizontalOffset=h,o=!0);var c=Math.max(i.right+this.vScrollSize,a);if(!o&&c<-h+this.viewPortWidth){var d=-h+a-this.vScrollSize,u=-this.horizontalOffset+a-this.vScrollSize;this.horizontalOffset=dd-u?h:-(i.right+this.vScrollSize-a),o=!0}o||(this.horizontalOffset=r-t)}o=!1;var f=s-e;if(f!==this.verticalOffset){sf?this.verticalOffset-=e:this.verticalOffset=f,o=!0);var p=Math.max(i.bottom+this.hScrollSize,l);if(!o&&p<-f+l){var g=-f+l-this.hScrollSize,v=-this.verticalOffset+l-this.hScrollSize;this.verticalOffset=gg-v?f:-(i.bottom+this.hScrollSize-l),o=!0}o||(this.verticalOffset=s-e)}this.transform={tx:Math.max(this.horizontalOffset,-i.left)/this.currentZoom,ty:Math.max(this.verticalOffset,-i.top)/this.currentZoom,scale:this.currentZoom},this.setSize()},n.prototype.getObjects=function(t,e){for(var i=[],r=0;r0){for(var l=0;l0){h.push(i[parseInt(o.toString(),10)].id);for(var d=0;d=e.bottom&&(l=0),-this.horizontalOffset<=e.x&&-this.horizontalOffset+this.viewPortWidth>=e.right&&(a=0),this.hScrollSize=a,this.vScrollSize=l;var h=this.diagramWidth,c=this.diagramHeight;this.diagramWidth=Math.max(e.right,-this.horizontalOffset+this.viewPortWidth-l)-i,this.diagramHeight=Math.max(e.bottom,-this.verticalOffset+this.viewPortHeight-a)-r,(h!==this.diagramWidth||c!==this.diagramHeight)&&"Diagram"!==this.diagram.scrollSettings.scrollLimit&&this.diagram.setSize(this.diagramWidth,this.diagramHeight),"Diagram"===this.diagram.scrollSettings.scrollLimit&&(h===this.diagramWidth&&c===this.diagramHeight&&1===this.currentZoom||this.diagram.diagramActions&&t&&(!this.diagram.diagramActions||!t||0===this.verticalOffset&&this.verticalOffset!==t.y||0===this.horizontalOffset&&this.horizontalOffset!==t.x)?t&&h===this.diagramWidth&&c===this.diagramHeight&&(this.diagram.diagramCanvas.scrollHeight>this.viewPortHeight&&t.y<0&&this.horizontalOffset===t.x&&0===this.verticalOffset||this.diagram.diagramCanvas.scrollWidth>this.viewPortWidth&&t.x<0&&this.verticalOffset===t.y&&0===this.horizontalOffset)&&(this.verticalOffset=t.y,this.horizontalOffset=t.x,this.transform={tx:Math.max(t.x,-e.left)/this.currentZoom,ty:Math.max(t.y,-e.top)/this.currentZoom,scale:this.currentZoom}):(this.diagram.scrollActions&da.Interaction&&t&&(this.transform={tx:Math.max(t.x,-e.left/this.currentZoom)/this.currentZoom,ty:Math.max(t.y,-e.top/this.currentZoom)/this.currentZoom,scale:this.currentZoom},this.horizontalOffset=t.x,this.verticalOffset=t.y),this.diagram.setSize(this.diagramWidth,this.diagramHeight),!(this.diagram.scrollActions&da.PropertyChange)&&t&&(this.horizontalOffset=t.x,this.verticalOffset=t.y,this.transform={tx:Math.max(t.x,-e.left)/this.currentZoom,ty:Math.max(t.y,-e.top)/this.currentZoom,scale:this.currentZoom}))),this.diagram.transformLayers(),this.diagram.element.style.overflow="hidden"},n.prototype.setViewPortSize=function(t,e){this.viewPortWidth=t,this.viewPortHeight=e},n.prototype.getPageBounds=function(t,e,i,r){var o,s=new Ne;if("Content"===e||r||null===this.diagram.pageSettings.width||null===this.diagram.pageSettings.height){var u=t?void 0:0;o=this.diagram.spatialSearch.getPageBounds(u,u)}else{var a=this.diagram.pageSettings.width,l=this.diagram.pageSettings.height,h=0,c=0;if(this.diagram.pageSettings.multiplePage){if((s=this.diagram.spatialSearch.getPageBounds(0,0)).right>a&&(a*=d=Math.ceil(s.right/a)),s.bottom>l&&(l*=d=Math.ceil(s.bottom/l)),s.left<0&&Math.abs(s.left)>h){var d=Math.ceil(Math.abs(s.left)/this.diagram.pageSettings.width);h=this.diagram.pageSettings.width*d}s.top<0&&Math.abs(s.top)>c&&(d=Math.ceil(Math.abs(s.top)/this.diagram.pageSettings.height),c=this.diagram.pageSettings.height*d)}o=new Ne(-h,-c,a+h,l+c)}if(i){var f=this.diagram.scrollSettings.padding;o.x-=f.left,o.y-=f.top,o.width+=f.left+f.right,o.height+=f.top+f.bottom}return o},n.prototype.getPageBreak=function(t){for(var e=0,i=0,r=-1,s=[],c=this.diagram.pageSettings.margin.left,d=this.diagram.pageSettings.margin.right,u=this.diagram.pageSettings.margin.top,f=this.diagram.pageSettings.margin.bottom,p=1,g=1;t.width>e;)(e+=this.diagram.pageSettings.width?this.diagram.pageSettings.width:t.width)===this.diagram.pageSettings.width&&(s[++r]={x1:t.left+c,y1:t.top+u,x2:t.left+c,y2:t.bottom-f}),ei;)(i+=this.diagram.pageSettings.height?this.diagram.pageSettings.height:t.height)===this.diagram.pageSettings.height&&(s[++r]={x1:t.left+c,y1:t.top+u,x2:t.right-d,y2:t.top+u}),i=this.diagram.scrollSettings.minZoom||l||t>=1)){this.currentZoom*=t;var c=this.getPageBounds(void 0,void 0,!0);c.x*=this.currentZoom,c.y*=this.currentZoom;var d=Bi();Yf(d,t,t,r.x,r.y),ZB(d,e||0,i||0),yx(h,d);var u=Ke(h,{x:0,y:0});if(1===t&&(u=this.applyScrollLimit(u.x,u.y,s,o,a)),a=-c.y>=u.y&&-c.x>=u.x&&a,(this.diagram.scrollActions&da.PropertyChange||!(this.diagram.scrollActions&da.Interaction)||"Diagram"!==this.diagram.scrollSettings.scrollLimit||a)&&(this.transform={tx:Math.max(u.x,-c.left)/this.currentZoom,ty:Math.max(u.y,-c.top)/this.currentZoom,scale:this.currentZoom},this.horizontalOffset=u.x,this.verticalOffset=u.y),this.setSize(u),"SVG"!==this.diagram.mode&&Ds(this.diagram)&&this.diagram.scroller.virtualizeElements(),"SVG"!==this.diagram.mode&&!Ds(this.diagram)&&this.diagram.refreshDiagramLayer(),this.diagram.setOffset(-this.horizontalOffset-c.x,-this.verticalOffset-c.y),qI(this.diagram),this.diagram.views&&this.diagram.views.overview){var f=this.diagram.views.overview,p=f.scrollOverviewRect(f.parent.scroller.horizontalOffset,f.parent.scroller.verticalOffset,f.parent.scroller.currentZoom,!0);f.updateOverviewrect(-p.x,-p.y,p.width,p.height),f.updateView(f)}}}},n.prototype.fitToPage=function(t){var e=(t=t||{}).mode,i=t.region,r=t.margin||{},s=t.canZoomIn,o=t.customBounds,a=t.canZoomOut;r.bottom=r.bottom||25,r.top=r.top||25,r.left=r.left||25,r.right=r.right||25;var h,l=o,c=-this.horizontalOffset,d=-this.verticalOffset;if("PageSettings"===(i=i||"PageSettings")&&this.diagram.pageSettings.width&&this.diagram.pageSettings.height||this.diagram.nodes.length>0||this.diagram.connectors.length>0){e=e||"Page","CustomBounds"!==i&&(l=this.getPageBounds(!0,i,!0));var u={x:0,y:0};r.left+r.right>this.viewPortWidth&&(this.viewPortWidth<=100?(r.left=5,r.right=5):(r.left=25,r.right=25)),r.top+r.bottom>this.viewPortHeight&&(this.viewPortHeight<=100?(r.top=5,r.bottom=5):(r.top=25,r.bottom=25)),u.x=(this.viewPortWidth-(r.left+r.right))/l.width,u.y=(this.viewPortHeight-(r.top+r.bottom))/l.height,!s&&l.width-this.horizontalOffset-a+this.viewPortWidth&&(i=o.right-this.viewPortWidth,i+=20),o.x<-a&&(i=o.x),o.bottom>-l+this.viewPortHeight&&(r=o.bottom-this.viewPortHeight,r+=20),o.y<-l&&(r=o.y),this.zoom(1,-this.horizontalOffset-i,-this.verticalOffset-r,null,void 0,e))},n.prototype.bringToCenter=function(t){var e=this.currentZoom,i=new Ne(t.x*e,t.y*e,t.width*e,t.height*e),r=i.x+i.width/2-this.viewPortWidth/2,s=i.y+i.height/2-this.viewPortHeight/2;this.zoom(1,-this.horizontalOffset-(r*=-1),-this.verticalOffset-(s*=-1),null)},n.prototype.applyScrollLimit=function(t,e,i,r,s){if("Infinity"===this.diagram.scrollSettings.scrollLimit&&void 0===i&&!r&&(t=-t,e=-e),"Infinity"!==this.diagram.scrollSettings.scrollLimit){var o=void 0;if("Limited"===this.diagram.scrollSettings.scrollLimit){var a=this.diagram.scrollSettings.scrollableArea;o=new Ne(a.x,a.y,a.width,a.height)}(o=o||(s?this.getPageBounds():this.getPageBounds(!0))).x*=this.currentZoom,o.y*=this.currentZoom,o.width*=this.currentZoom,o.height*=this.currentZoom,void 0!==i&&(t*=-1,e*=-1),r&&(t*=-1,e*=-1);var l=Math.max(o.right,this.viewPortWidth);if(!r&&!(t<=o.x&&(t+this.viewPortWidth>=o.right||t>=o.right-this.viewPortWidth)||t>=o.x&&t+this.viewPortWidth<=l))if(t>=o.x)t=Math.max(o.x,Math.min(t,t-(t+this.viewPortWidth-this.vScrollSize-l)));else{var h=o.right-this.viewPortWidth;t=Math.min(h,o.x)}var c=Math.max(o.bottom,this.viewPortHeight);r||e<=o.y&&e+this.viewPortHeight>=o.bottom||e>=o.y&&e+this.viewPortHeight<=c||(e>=o.y?e=Math.max(o.y,Math.min(e,e-(e+this.viewPortHeight-this.hScrollSize-c))):(h=o.bottom-this.viewPortHeight,e=Math.min(o.y,h))),t*=-1,e*=-1}return{x:t,y:e}},n}(),Woe=function(){function n(t,e,i,r,s){this.objects=[],this.left=t,this.top=e,this.width=i,this.height=r,this.spatialSearch=s}return n.prototype.findQuads=function(t,e){null!=this.first&&this.first.isIntersect(t)&&this.first.findQuads(t,e),null!=this.second&&this.second.isIntersect(t)&&this.second.findQuads(t,e),null!=this.third&&this.third.isIntersect(t)&&this.third.findQuads(t,e),null!=this.fourth&&this.fourth.isIntersect(t)&&this.fourth.findQuads(t,e),this.objects.length>0&&e.push(this)},n.prototype.isIntersect=function(t){return!(this.left+this.widtht.right||this.top>t.bottom)},n.prototype.selectQuad=function(){for(var i,t=null,e=this;null!=e;)i=e.getQuad(t),e=i.source,t=i.target||t;return t},n.prototype.getQuad=function(t){var e=this.width/2,i=this.height/2;if(e>=1e3&&i>=1e3){var r=this.left+e,s=this.top+i;if(this.spatialSearch.childRight<=r){if(this.spatialSearch.childBottom<=s)return this.first||((o=new n(this.left,this.top,e,i,this.spatialSearch)).parent=this,this.first=o),{source:this.first};if(this.spatialSearch.childTop>=s)return this.third||((o=new n(this.left,s,e,i,this.spatialSearch)).parent=this,this.third=o),{source:this.third}}else if(this.spatialSearch.childLeft>=r){if(this.spatialSearch.childBottom<=s)return this.second||((o=new n(r,this.top,e,i,this.spatialSearch)).parent=this,this.second=o),{source:this.second};var o;if(this.spatialSearch.childTop>=s)return this.fourth||((o=new n(r,s,e,i,this.spatialSearch)).parent=this,this.fourth=o),{source:this.fourth}}}return this.objects.push(this.spatialSearch.childNode),{target:this}},n.prototype.isContained=function(){return this.spatialSearch.childLeft>=this.left&&this.spatialSearch.childRight<=this.left+this.width&&this.spatialSearch.childTop>=this.top&&this.spatialSearch.childBottom<=this.top+this.height},n.prototype.addIntoAQuad=function(t){var e={};this.spatialSearch.setCurrentNode(t);for(var i=null;!e.isAdded;)i=(e=this.spatialSearch.parentQuad.add(i)).quad;return i},n.prototype.add=function(t){if(t=null,this.isContained())return{isAdded:!0,quad:t=this.selectQuad()};var e=void 0,i=!(0!==this.objects.length||this.first||this.second||this.third||this.fourth),r=2*this.width,s=2*this.height;return this.spatialSearch.childLeft=this.childLeft?(this.pageLeft=this.childLeft,this.leftElement=t,r=!0):t===this.leftElement&&(this.pageLeft=Number.MAX_VALUE,this.findLeft(this.parentQuad),r=!0)),(this.pageTop!==this.childTop||t!==this.topElement)&&(this.pageTop>=this.childTop?(this.pageTop=this.childTop,this.topElement=t,r=!0):t===this.topElement&&(this.pageTop=Number.MAX_VALUE,this.findTop(this.parentQuad),r=!0)),(this.pageBottom!==this.childBottom||t!==this.bottomElement)&&(this.pageBottom<=this.childBottom?(r=!0,this.pageBottom=this.childBottom,this.bottomElement=t):t===this.bottomElement&&(this.pageBottom=-Number.MAX_VALUE,this.findBottom(this.parentQuad),r=!0)),(this.pageRight!==this.childRight||t!==this.rightElement)&&(this.pageRight<=this.childRight?(this.pageRight=this.childRight,this.rightElement=t,r=!0):t===this.rightElement&&(this.pageRight=-Number.MAX_VALUE,this.findRight(this.parentQuad),r=!0)),r}return this.setCurrentNode(null),!1},n.prototype.isWithinPageBounds=function(t){return t.left>=this.pageLeft&&t.right<=this.pageRight&&t.top>=this.pageTop&&t.bottom<=this.pageBottom},n.prototype.findQuads=function(t){var e=[];return this.parentQuad.findQuads(t,e),e},n.prototype.findObjects=function(t){for(var i=[],r=0,s=this.findQuads(t);r=r.outerBounds.left&&(this.pageLeft=r.outerBounds.left,this.leftElement=r)}},n.prototype.findTop=function(t){t.first||t.second?(t.first&&this.findTop(t.first),t.second&&this.findTop(t.second)):(t.third&&this.findTop(t.third),t.fourth&&this.findTop(t.fourth));for(var e=0,i=t.objects;e=r.outerBounds.top&&(this.pageTop=r.outerBounds.top,this.topElement=r)}},n.prototype.setCurrentNode=function(t){if(this.childNode=t,t){var e=t.outerBounds;this.childLeft=Number(e.left),this.childTop=Number(e.top),this.childRight=Number(e.right),this.childBottom=Number(e.bottom)}else this.childLeft=Number.MAX_VALUE,this.childTop=Number.MAX_VALUE,this.childRight=-Number.MAX_VALUE,this.childBottom=-Number.MAX_VALUE},n.prototype.getPageBounds=function(t,e){if(this.pageLeft===Number.MAX_VALUE)return new Ne(0,0,0,0);var i=void 0!==t?Math.min(this.pageLeft,0):this.pageLeft,r=void 0!==e?Math.min(this.pageTop,0):this.pageTop;return new Ne(Math.round(i),Math.round(r),Math.round(this.pageRight-i),Math.round(this.pageBottom-r))},n.prototype.getQuad=function(t){return this.quadTable[t.id]},n}(),Yoe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Goe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Yoe(t,n),function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);r>3&&s&&Object.defineProperty(t,e,s)}([I(!1)],t.prototype,"preventDefaults",void 0),t}(Ee),Xoe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),e_=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},qoe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return Xoe(t,n),e_([I("")],t.prototype,"action",void 0),e_([I("")],t.prototype,"cursor",void 0),t}(Ee),t_=function(){function n(){this.size=20,this.intermediatePoints=[],this.gridCollection=[],this.startArray=[],this.targetGridCollection=[],this.sourceGridCollection=[],this.considerWalkable=[]}return n.prototype.lineRouting=function(t){var e=t.connectors.length;if(this.renderVirtualRegion(t),e>0)for(var i=0;i=t.right||e.right<=t.left||e.top>=t.bottom||e.bottom<=t.top)},n.prototype.findEndPoint=function(t,e,i){var r,s;if(e&&""!==t.sourcePortID&&t.sourcePortWrapper||!e&&""!==t.targetPortID&&t.targetPortWrapper){s=zo(r=e?{x:t.sourcePortWrapper.offsetX,y:t.sourcePortWrapper.offsetY}:{x:t.targetPortWrapper.offsetX,y:t.targetPortWrapper.offsetY},void 0,e?t.sourceWrapper.bounds:t.targetWrapper.bounds);var o=e?t.sourcePortWrapper.bounds:t.targetPortWrapper.bounds;r=i?"Top"===s?{x:o.topCenter.x,y:o.topCenter.y}:"Left"===s?{x:o.middleLeft.x,y:o.middleLeft.y}:"Right"===s?{x:o.middleRight.x,y:o.middleRight.y}:{x:o.bottomCenter.x,y:o.bottomCenter.y}:{x:o.center.x,y:o.center.y}}else r=e&&this.startNode||!e&&this.targetNode?e?{x:this.startNode.wrapper.offsetX,y:this.startNode.wrapper.offsetY}:{x:this.targetNode.wrapper.offsetX,y:this.targetNode.wrapper.offsetY}:e?{x:t.sourcePoint.x,y:t.sourcePoint.y}:{x:t.targetPoint.x,y:t.targetPoint.y};return r},n.prototype.refreshConnectorSegments=function(t,e,i,r){var h,c,f,p,g,y,S,b,M,w,C,s=e.sourceID,o=e.targetID,a=e.sourcePortID,l=e.targetPortID;if(function Ure(n,t){var e=0;return n.constraints&qe.LineRouting?e=n.constraints&qe.LineRouting:n.constraints&qe.InheritLineRouting&&(e=t.constraints&nt.LineRouting),e}(e,t)||r){this.startNode=t.nameTable[""+s],this.targetNode=t.nameTable[""+o],this.intermediatePoints=[],this.startArray=[],this.targetGridCollection=[],this.sourceGridCollection=[],this.startGrid=void 0,this.targetGrid=void 0;for(var D=0;D0;){var L=this.startArray.pop();if(L){for(D=0;D1&&(e.segments=[]),this.updateConnectorSegments(t,this.intermediatePoints,this.gridCollection,e,i)){this.considerWalkable=[];break e}this.targetGridCollection.splice(this.targetGridCollection.indexOf(O),1),L=this.startArray.pop()}}L&&this.findPath(L)}}}},n.prototype.checkChildNodes=function(t,e){var i=!1,r=!1;if(t.nodeId.length>=1&&!e)for(var s=0;s1&&this.targetGridCollection[0].nodeId.length>1)for(var c=0;c<=1;c++){for(var d=this.targetGridCollection[parseInt(c.toString(),10)].gridX,u=this.targetGridCollection[parseInt(c.toString(),10)].gridY,f=this.targetGridCollection[parseInt(c.toString(),10)].nodeId,p=void 0,g=0;g=e.right&&t.top<=e.top&&t.bottom>=e.bottom},n.prototype.getEndvalue=function(t,e){return this.gridCollection[t.gridX][t.gridY].walkable?t:"left"===e?this.getEndvalue(this.gridCollection[t.gridX-1][t.gridY],e):"right"===e?this.getEndvalue(this.gridCollection[t.gridX+1][t.gridY],e):"top"===e?this.getEndvalue(this.gridCollection[t.gridX][t.gridY-1],e):"bottom"===e?this.getEndvalue(this.gridCollection[t.gridX][t.gridY+1],e):t},n.prototype.changeValue=function(t,e,i){t.walkable||this.considerWalkable.push(t);for(var r,s=0;s<=e;s++)"left"===i?r=this.gridCollection[t.gridX-s][t.gridY]:"right"===i?r=this.gridCollection[t.gridX+s][t.gridY]:"top"===i?r=this.gridCollection[t.gridX][t.gridY-s]:"bottom"===i&&(r=this.gridCollection[t.gridX][t.gridY+s]),r.walkable||this.considerWalkable.push(r)},n.prototype.getIntermediatePoints=function(t){var e;for(this.intermediatePoints=[];t;)this.intermediatePoints.push({x:t.gridX,y:t.gridY}),t=t.parent;this.intermediatePoints.reverse(),this.intermediatePoints.length>=1&&void 0!==this.intermediatePoints[0]&&void 0!==this.intermediatePoints[1]&&(this.intermediatePoints[0].x===this.intermediatePoints[1].x?this.intermediatePoints[0].yi.y&&o.y>s.y){for(var a=i.xi.x&&o.x>s.x)){for(var u=i.y=1&&u.length>1&&(g=u[u.length-2].x!==u[u.length-1].x?u[u.length-2].x>u[u.length-1].x?"Left":"Right":u[u.length-2].y>u[u.length-1].y?"Top":"Bottom"),M>=2&&v===g&&u.length>1&&u.splice(u.length-2,1),v=g);if(u&&u.length>1){for(var w=0;wD.x?S.bounds.middleLeft:S.bounds.middleRight),w===u.length-2&&""===r.targetPortID&&y&&(l=C.x>D.x?y.bounds.middleRight:y.bounds.middleLeft),0===w&&b&&(C.x=b.x,C.y=D.y=b.y,b=qa(r,0,b,Nl(S.bounds,_n(C.x>D.x?"Left":"Right")),!1),C.x=b.x),w===u.length-2&&l&&(w>0&&r.targetDecorator&&l.x-D.x<0&&Math.abs(l.x-C.x)0&&r.targetDecorator&&l.x-D.x>0&&Math.abs(l.x-C.x)D.y?S.bounds.topCenter:S.bounds.bottomCenter),w===u.length-2&&""===r.targetPortID&&y&&(l=C.y>D.y?y.bounds.bottomCenter:y.bounds.topCenter),0===w&&b&&(C.y=b.y,C.x=D.x=b.x,b=qa(r,0,b,Nl(S.bounds,_n(C.y>D.y?"Top":"Bottom")),!1),C.y=b.y),w===u.length-2&&l&&(w>0&&r.targetDecorator&&l.y-D.y<0&&Math.abs(l.y-C.y)0&&r.targetDecorator&&l.y-D.y>0&&Math.abs(l.y-C.y)D.x?(f="Left",p=C.x-D.x):(f="Right",p=D.x-C.x):C.y>D.y?(f="Top",p=C.y-D.y):(f="Bottom",p=D.y-C.y),o.push({type:"Orthogonal",length:p,direction:f})}}if(o&&o.length>0){var L=o[o.length-1];if(1===o.length&&(L.length-=20),L.length<10&&2===o.length&&(o.pop(),o.length>0&&(o[0].length-=20,L=o[0])),r.targetDecorator&&("Top"===L.direction||"Bottom"===L.direction)&&L.length>r.targetDecorator.height+1||("Right"===L.direction||"Left"===L.direction)&&L.length>r.targetDecorator.width+1)return r.segments=o,s&&t.connectorPropertyChange(r,{},{type:"Orthogonal",segments:o}),!0}return!1},n.prototype.findPath=function(t){for(var e,i=[],r=this.findNearestNeigbours(t,this.gridCollection,!0),s=0;sl)&&(e.x!==t.gridX||e.y!==t.gridY)&&(i.push(e),o.previousDistance=l,o.afterDistance=o.afterDistance||this.manhattan(Math.abs(e.x-this.targetGrid.gridX),Math.abs(e.y-this.targetGrid.gridY)),o.totalDistance=o.previousDistance+o.afterDistance,o.parent=t)}if(i.length>0)for(s=0;st?i*t+e:i*e+t},n.prototype.manhattan=function(t,e){return t+e},n.prototype.findNearestNeigbours=function(t,e,i){var r=[],s=t.parent;if(s){var o=(t.gridX-s.gridX)/Math.max(Math.abs(t.gridX-s.gridX),1),a=(t.gridY-s.gridY)/Math.max(Math.abs(t.gridY-s.gridY),1);0!==o?(this.isWalkable(t.gridX,t.gridY-1,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX][t.gridY-1])&&r.push(e[t.gridX][t.gridY-1]),this.isWalkable(t.gridX,t.gridY+1,!0)&&this.sourceGridCollection.indexOf(e[t.gridX][t.gridY+1])&&r.push(e[t.gridX][t.gridY+1]),this.isWalkable(t.gridX+o,t.gridY,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX+o][t.gridY])&&r.push(e[t.gridX+o][t.gridY])):0!==a&&(this.isWalkable(t.gridX-1,t.gridY,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX-1][t.gridY])&&r.push(e[t.gridX-1][t.gridY]),this.isWalkable(t.gridX+1,t.gridY,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX+1][t.gridY])&&r.push(e[t.gridX+1][t.gridY]),this.isWalkable(t.gridX,t.gridY+a,!0)&&-1===this.sourceGridCollection.indexOf(e[t.gridX][t.gridY+a])&&r.push(e[t.gridX][t.gridY+a]))}else this.neigbour(t,"top",r,i),this.neigbour(t,"right",r,i),this.neigbour(t,"bottom",r,i),this.neigbour(t,"left",r,i);return r},n.prototype.neigbour=function(t,e,i,r){for(var o,s=1;s>0;){var a="top"===e||"bottom"===e?t.gridX:"left"===e?t.gridX-s:t.gridX+s,l="right"===e||"left"===e?t.gridY:"top"===e?t.gridY-s:t.gridY+s;if((o=this.gridCollection[parseInt(a.toString(),10)][parseInt(l.toString(),10)])&&(r&&-1===this.sourceGridCollection.indexOf(o)||!r&&-1===this.targetGridCollection.indexOf(o)))return i&&this.isWalkable(a,l)&&i.push(o),s;if(!(a>0&&l>0))break;s++}return null},n.prototype.resetGridColl=function(t,e,i){for(var s,r=1;r>0;){var o="top"===e||"bottom"===e?t.gridX:"left"===e?t.gridX-r:t.gridX+r,a="right"===e||"left"===e?t.gridY:"top"===e?t.gridY-r:t.gridY+r;if((s=this.gridCollection[parseInt(o.toString(),10)][parseInt(a.toString(),10)])&&(i&&-1===this.sourceGridCollection.indexOf(s)||!i&&-1===this.targetGridCollection.indexOf(s))){if(this.isWalkable(o,a))break;var l=this.gridCollection[parseInt(o.toString(),10)][parseInt(a.toString(),10)];this.considerWalkable.push(l)}if(!(o>0&&a>0))break;"top"===e||"left"===e?r--:r++}return null},n.prototype.isWalkable=function(t,e,i){if(t>=0&&t=0&&e0?1:-1,this.isWalkable(h,c-1)&&!this.isWalkable(h-a,c-1)||this.isWalkable(h,c+1)&&!this.isWalkable(h-a,c+1)))return{x:t,y:e};if(0!==l){if(l=l>0?1:-1,this.isWalkable(h-1,c)&&!this.isWalkable(h-1,c-l)||this.isWalkable(h+1,c)&&!this.isWalkable(h+1,c-l))return{x:t,y:e};if(this.findIntermediatePoints(h+1,c,h,c,s,o)||this.findIntermediatePoints(h-1,c,h,c,s,o))return{x:t,y:e}}return this.findIntermediatePoints(h+a,c+l,h,c,s,o)},n.prototype.destroy=function(){},n.prototype.getModuleName=function(){return"LineRouting"},n}(),$oe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Joe=function(n){function t(){return null!==n&&n.apply(this,arguments)||this}return $oe(t,n),function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);r>3&&s&&Object.defineProperty(t,e,s)}([I(!0)],t.prototype,"inversedAlignment",void 0),t}(Ee),Koe=function(){var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,r){i.__proto__=r}||function(i,r){for(var s in r)r.hasOwnProperty(s)&&(i[s]=r[s])})(t,e)};return function(t,e){function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}}(),Oe=function(n,t,e,i){var o,r=arguments.length,s=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(n,t,e,i);else for(var a=n.length-1;a>=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s},CT=function(n,t,e,i){return new(e||(e=Promise))(function(r,s){function o(h){try{l(i.next(h))}catch(c){s(c)}}function a(h){try{l(i.throw(h))}catch(c){s(c)}}function l(h){h.done?r(h.value):new e(function(c){c(h.value)}).then(o,a)}l((i=i.apply(n,t||[])).next())})},ET=function(n,t){var i,r,s,o,e={label:0,sent:function(){if(1&s[0])throw s[1];return s[1]},trys:[],ops:[]};return o={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function a(h){return function(c){return function l(h){if(i)throw new TypeError("Generator is already executing.");for(;e;)try{if(i=1,r&&(s=2&h[0]?r.return:h[0]?r.throw||((s=r.return)&&s.call(r),0):r.next)&&!(s=s.call(r,h[1])).done)return s;switch(r=0,s&&(h=[2&h[0],s.value]),h[0]){case 0:case 1:s=h;break;case 4:return e.label++,{value:h[1],done:!1};case 5:e.label++,r=h[1],h=[0];continue;case 7:h=e.ops.pop(),e.trys.pop();continue;default:if(!(s=(s=e.trys).length>0&&s[s.length-1])&&(6===h[0]||2===h[0])){e=0;continue}if(3===h[0]&&(!s||h[1]>s[0]&&h[1]0&&((!s.style||!s.style.fill)&&(o.style.fill="transparent"),(!s.style||!s.style.strokeColor)&&(o.style.strokeColor="transparent")),s.shape&&"UmlActivity"===s.shape.type&&JI(s,o),s.shape&&"SwimLane"===s.shape.type&&aF(s,o),r.nodeDefaults&&Ro(o,s,r.nodeDefaults),r.updateAnnotationText(o.annotations);if(e&&e.connectors)for(a=0;e&&e.connectors&&a0&&0===i.nodes.length)this.clearCollection(),a=!0;else{for(var g=0,v=Object.keys(e.nodes);g0&&0===i.connectors.length)this.clearCollection(!0),a=!0;else{for(var C=0,D=Object.keys(e.connectors);C0){this.renderSelector(!0);break}if(e.selectedItems.constraints){this.renderSelector(!0);break}break;case"snapSettings":this.updateSnapSettings(e);break;case"commandManager":this.initCommands();break;case"layout":o=!0;break;case"segmentThumbShape":this.updateSelector();break;case"dataSourceSettings":this.clear(),"None"===this.layout.type?a=!0:(this.initObjects(),o=!0);break;case"tooltip":i3(this);break;case"rulerSettings":this.updateRulerSettings(e);break;case"layers":this.updateLayer(e);break;case"scrollSettings":this.scrollActions|=da.PropertyChange,this.updateScrollSettings(e),this.scrollActions&=~da.PropertyChange,this.scrollSettings.horizontalOffset=-this.scroller.horizontalOffset||0,this.scrollSettings.verticalOffset=-this.scroller.verticalOffset||0;break;case"locale":e.locale!==i.locale&&(this.realActions|=$i.PreventDataInit,n.prototype.refresh.call(this),this.realActions&=~$i.PreventDataInit);break;case"contextMenuSettings":if(void 0!==e.contextMenuSettings.showCustomMenuOnly&&(this.contextMenuSettings.showCustomMenuOnly=e.contextMenuSettings.showCustomMenuOnly),void 0!==e.contextMenuSettings.show&&(this.contextMenuSettings.show=e.contextMenuSettings.show),e.contextMenuSettings.items){for(var A=e.contextMenuSettings.items,x=0,P=Object.keys(A);x0){for(var N=[],T=O.ports.length-1;T>=0;T--)"LineDistribution"===O.ports[parseInt(T.toString(),10)].id.split("_")[1]&&N.push(O.ports[parseInt(T.toString(),10)]);this.removePorts(O,N)}}for(T=0;T0)for(var ue=0,fe=Object.keys(e.nodes);ue0)for(var De=0,xe=Object.keys(e.connectors);De=0;o--)this.commandHandler.expandNode(r[parseInt(o.toString(),10)],this,0!==o);this.canLayout&&this.doLayout(),this.lineRoutingModule?this.connectors.sourceID!==this.connectors.targetID&&this.lineRoutingModule.lineRouting(this):this.constraints&nt.LineRouting&&console.warn('[WARNING] :: Module "LineRouting" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),this.validatePageSize(),this.renderPageBreaks(),this.diagramRenderer.renderSvgGridlines(this.snapSettings,Fd(this.element.id),this.scroller.transform,this.rulerSettings,this.hRuler,this.vRuler),this.commandHandler.initSelectorWrapper(),this.notify("initial-load",{}),this.trigger("load"),this.scroller.setSize(),this.scroller.updateScrollOffsets(),this.isRefreshed||this.refreshDiagramLayer(),(this.scrollSettings.verticalOffset>0||this.scrollSettings.horizontalOffset>0)&&this.updateScrollOffset(),X.isDevice&&(this.tool=ni.ZoomPan|ni.SingleSelect),this.notify("initial-end",{}),this.isProtectedOnChange=!1,this.tooltipObject=i3(this),this.diagramActions=ee.Render,this.initCommands();var a=document.getElementsByClassName(this.element.id+"_hiddenUserHandleTemplate");(function Ioe(n,t,e,i){var r,s,o,a,l,d=document.getElementById(i).ej2_instances[0];if(n&&t){r=UF(n);for(var u=0,f=e.userHandles;u0;)e[0].parentNode.removeChild(e[0]);var i=document.getElementById(this.element.id+"content");i&&this.element.removeChild(i);var r="measureElement";if(window[""+r]){window[""+r].usageCount-=1;var s="measureElementCount";window[""+s]--,0===window[""+s]&&(window[""+r].parentNode.removeChild(window[""+r]),window[""+r]=null)}}window.domTable={};for(var a=0;a1&&(this.callBlazorModel=!1,this.insertBlazorDiagramObjects(this.selectedItems),this.commandHandler.group(),this.callBlazorModel=!0,this.commandHandler.getBlazorOldValues())},t.prototype.unGroup=function(){this.callBlazorModel=!1,this.insertBlazorDiagramObjects(this.selectedItems),this.commandHandler.unGroup(),this.callBlazorModel=!0,this.commandHandler.getBlazorOldValues()},t.prototype.sendToBack=function(){this.commandHandler.sendToBack()},t.prototype.setActiveLayer=function(e){var i=this.commandHandler.getLayer(e);this.activeLayer=i},t.prototype.addLayer=function(e,i){this.commandHandler.addLayer(e,i)},t.prototype.removeLayer=function(e){this.commandHandler.removeLayer(e,ce())},t.prototype.moveObjects=function(e,i){$(this.layers),this.enableServerDataBinding(!1),this.commandHandler.moveObjects(e,i)},t.prototype.layerObjectUpdate=function(){},t.prototype.sendLayerBackward=function(e){this.layerObjectUpdate(),this.commandHandler.sendLayerBackward(e)},t.prototype.bringLayerForward=function(e){this.layerObjectUpdate(),this.commandHandler.bringLayerForward(e)},t.prototype.cloneLayer=function(e){this.commandHandler.cloneLayer(e)},t.prototype.bringToFront=function(){this.commandHandler.bringToFront()},t.prototype.moveForward=function(){this.commandHandler.sendForward()},t.prototype.sendBackward=function(){this.commandHandler.sendBackward()},t.prototype.getObject=function(e){return this.nameTable[""+e]},t.prototype.getNodeObject=function(e){return $(this.nameTable[""+e])},t.prototype.getConnectorObject=function(e){return $(this.nameTable[""+e])},t.prototype.getActiveLayer=function(){return this.activeLayer},t.prototype.nudgeCommand=function(e,i,r){if("object"!=typeof e&&(this.selectedItems.nodes.length||this.selectedItems.connectors.length)>0){var s=void 0;i.type&&"KEYDOWN"===i.type&&(s=i.type),this.nudge(e,void 0,void 0,s)}},t.prototype.nudge=function(e,i,r,s){var o=0,a=0;"Left"===e||"Right"===e?o=("Left"===e?-1:1)*(i||1):a=("Up"===e?-1:1)*(r||1),"KEYDOWN"===s&&(o*=5,a*=5);var h=this.selectedItems,c=this.selectedItems.wrapper.children[0];if(c instanceof li)this.commandHandler.labelDrag(h.nodes[0],c,o,a);else{var d=$(this.selectedItems);this.protectPropertyChange(!0),this.drag(h,o,a),this.protectPropertyChange(!1);var u={type:"PositionChanged",redoObject:$(this.selectedItems),undoObject:d,category:"Internal"};this.addHistoryEntry(u)}this.refreshCanvasLayers()},t.prototype.insertBlazorDiagramObjects=function(e){},t.prototype.drag=function(e,i,r){if(this.insertBlazorDiagramObjects(e),!(this.bpmnModule&&e instanceof te&&this.bpmnModule.updateAnnotationDrag(e,this,i,r))){if(e instanceof ti){if(this.preventConnectorsUpdate=!0,e.nodes&&e.nodes.length){for(var o=0,a=e.nodes;o0&&o.nodes[0].children){this.fromUndo||(this.rotateUsingButton=!0);for(var h=this.commandHandler.getAllDescendants(o.nodes[0],[]),c=0;c0&&o.nodes[0].children){var g={type:"RotationChanged",redoObject:$(e),undoObject:$(o),category:"Internal",childTable:a};this.commandHandler.addHistoryEntry(g),this.commandHandler.updateSelector()}return u},t.prototype.dragSourceEnd=function(e,i,r){this.insertBlazorDiagramObjects(e),this.commandHandler.dragSourceEnd(e,i,r),this.callBlazorModel&&this.commandHandler.getBlazorOldValues()},t.prototype.dragTargetEnd=function(e,i,r){this.insertBlazorDiagramObjects(e),this.commandHandler.dragTargetEnd(e,i,r),this.callBlazorModel&&this.commandHandler.getBlazorOldValues()},t.prototype.findObjectsUnderMouse=function(e,i){return this.eventHandler.findObjectsUnderMouse(e,i)},t.prototype.findObjectUnderMouse=function(e,i,r){return this.eventHandler.findObjectUnderMouse(e,i,r)},t.prototype.findTargetObjectUnderMouse=function(e,i,r,s,o){return this.eventHandler.findTargetUnderMouse(e,i,r,s,o)},t.prototype.findElementUnderMouse=function(e,i,r,s){return this.eventHandler.findElementUnderMouse(e,i,r,s)},t.prototype.findActionToBeDone=function(e,i,r,s){return this.eventHandler.findActionToBeDone(e,i,r,s)},t.prototype.updateConnectorPort=function(e){if(e.ports.length)for(var i=void 0,r=0,s=e.ports;r=0;s--)if(i.push(r[parseInt(s.toString(),10)]),i.length>this.historyManager.stackLimit)return i}else i=r;return i},t.prototype.getEdges=function(e){return e.outEdge?this.nameTable[e.id].outEdges:this.nameTable[e.id].inEdges},t.prototype.getParentId=function(e){return this.nameTable[""+e].parentId},t.prototype.addConnector=function(e){return this.add(e)},t.prototype.UpdateBlazorDiagramModelCollection=function(e,i,r,s){},t.prototype.UpdateBlazorDiagramModel=function(e,i,r,s){},t.prototype.UpdateBlazorLabelOrPortObjects=function(e,i,r,s){},t.prototype.addBlazorDiagramObjects=function(){},t.prototype.removeNodeEdges=function(e,i,r){var s=this.nameTable[""+e],o=r?s.outEdges:s.inEdges;if(o.length>0)for(var a=0;a0)){for(var c=0;c0))}this.removePortEdges(l,a.element.sourcePortID,a.element.id,h)}a.element.targetID&&this.removeNodeEdges(a.element.targetID,a.element.id,!1)}}this.diagramActions=this.diagramActions|ee.PublicMethod,e.id=e.id||Qe();var u=this.activeLayer;if(!a.cancel&&u&&!u.lock){if(u.objects.indexOf(e.id)<0&&!u.lock&&(u.visible||(u.visible=!0,this.dataBind()),u.objects.push(e.id)),ps(e)===de)(r=new de(this,"connectors",e,!0)).status="New",this.nameTable[r.targetID]&&"TextAnnotation"===this.nameTable[r.targetID].shape.shape&&(r.isBpmnAnnotationConnector=!0,r.constraints=r.constraints&~qe.Delete),Ro(r,e,this.connectorDefaults),this.connectors.push(r),this.initObject(r),!1===e.visible&&this.updateElementVisibility(r.wrapper,r,e.visible),this.updateEdges(r),this.insertBlazorConnector(r);else{if(Ro(r=new te(this,"nodes",e,!0),e,this.nodeDefaults),r.parentId=e.parentId?e.parentId:r.parentId,r.umlIndex=e.umlIndex,r.status="New",(o="TextAnnotation"===r.shape.shape)&&!e.isTextAnnotationCopied&&(r.inEdges=e.inEdges?e.inEdges:r.inEdges),this.nodes.push(r),this.initObject(r,u,void 0,i),o&&this.bpmnModule)for(c=0;c-1&&e.parentId&&this.nameTable[e.parentId]&&"UmlClassifier"===this.nameTable[e.parentId].shape.type){var g=this.nameTable[e.parentId];g.children.splice(r.umlIndex,0,r.id),g.wrapper.children.splice(r.umlIndex,0,r.wrapper),g.wrapper.measure(new me),g.wrapper.arrange(g.wrapper.desiredSize),this.updateDiagramObject(g)}}if(a={element:r,cause:this.diagramActions,diagramAction:this.getDiagramAction(this.diagramActions),state:"Changed",type:"Addition",cancel:!1},this.parentObject&&(a.parentId=this.parentObject.id),"helper"!==e.id&&!(this.diagramActions&ee.PreventCollectionChangeOnDragOver)&&this.triggerEvent(Ce.collectionChange,a),!(this.diagramActions&ee.UndoRedo||this.diagramActions&ee.Group||this.diagramActions&ee.PreventHistory)){var v={type:"CollectionChanged",changeType:"Insert",undoObject:$(e),redoObject:$(e),category:"Internal"};this.addHistoryEntry(v)}this.parentObject=void 0,"SVG"===this.mode&&(this.updateSvgNodes(r),this.updateTextElementValue(r),this.updateDiagramObject(r),o&&this.updateDiagramObject(this.nameTable[r.inEdges[0]]),r.shape.activity&&r.shape.activity.subProcess.processes&&r.shape.activity.subProcess.processes.length&&this.updateProcesses(r),this.updateBridging())}}if(this.protectPropertyChange(s),this.resetDiagramActions(ee.PublicMethod),r&&this.layers.length>1&&this.moveNode(r),this.views)for(var S=0,b=this.views;S=0;l--)this.moveSvgNode(a[parseInt(l.toString(),10)])}for(var h=0,c=i;h=0;o--)r[parseInt(o.toString(),10)]===e.id&&r.splice(o,1);for(var a=0;s.ports&&a=0;s--)if(i=this.nameTable[r[parseInt(s.toString(),10)]])if(this.connectorTable[i.id]=$(i),i.isBpmnAnnotationConnector){var o=this.nameTable[i.targetID];this.removeObjectsFromLayer(i);var a=this.connectors.indexOf(i);-1!==a&&this.connectors.splice(a,1),this.removeElements(i),this.removeFromAQuad(i),delete this.nameTable[i.id];var l=this.nameTable[i.sourceID];if(l){var h=l.outEdges.indexOf(i.id);-1!==h&&l.outEdges.splice(h,1)}e.id!==i.targetID&&this.remove(o)}else this.remove(i)},t.prototype.removeObjectsFromLayer=function(e){if(e.children)for(var i=0;i-1&&(_r(this,e)&&this.unSelect(e),this.layers[parseInt(s.toString(),10)].objects.splice(a,1),delete this.layers[parseInt(s.toString(),10)].zIndexTable[this.nameTable[e.id].zIndex])},t.prototype.removeElements=function(e){if("SVG"===this.mode||"Canvas"===this.mode&&"Native"===e.shape.type){var i=xt(e.id+"_groupElement",this.element.id),r=e;if(r.ports&&r.ports.length>0)for(var s=0;s0){l[parseInt(s.toString(),10)].id.indexOf("icon_content")>0&&"SVG"===this.mode&&((h=xt(l[parseInt(s.toString(),10)].id+"_shape_groupElement",this.element.id))&&h.parentNode.removeChild(h),(h=xt(l[parseInt(s.toString(),10)].id+"_rect_groupElement",this.element.id))&&h.parentNode.removeChild(h));for(var c=0,d=this.views;c=0;o--)a.children[parseInt(o.toString(),10)].children&&(l=n.nameTable[a.children[parseInt(o.toString(),10)].id])&&(l.isLane?qv(n,l):(n.removeDependentConnector(l),n.diagramActions|=ee.PreventHistory,l.constraints&ie.Delete?n.remove(l):V3(n,l,{},!1),n.diagramActions&=~ee.PreventHistory));a&&(i=n.nameTable[a.id])&&qv(n,i)}}(this,e),!(this.diagramActions&ee.UndoRedo||this.diagramActions&ee.PreventHistory)&&(e instanceof te||e instanceof de)){var o={type:"CollectionChanged",changeType:"Remove",undoObject:$(e),redoObject:$(e),category:"Internal"};this.diagramActions&ee.Clear||e.children&&!e.isLane&&!e.isPhase&&e.children.length>0&&this.undoRedoModule&&"None"===this.layout.type&&(this.historyManager.startGroupAction(),s=!0),(e instanceof te||e instanceof de)&&this.deleteDependentConnector&&this.removeDependentConnector(e),!e.isLane&&!e.isPhase&&!(this.diagramActions&ee.Clear)&&!this.isStackChild(e)&&this.addHistoryEntry(o)}"TextAnnotation"===e.shape.shape&&this.removeDependentConnector(e),e.children&&!e.isLane&&!e.isPhase&&(!(this.diagramActions&ee.UndoRedo)||!ce())&&this.deleteGroup(e),e.parentId&&(this.deleteChild(e,void 0,!0),this.nameTable[e.parentId]&&"UmlClassifier"===this.nameTable[e.parentId].shape.type&&(this.updateDiagramObject(this.nameTable[e.parentId]),this.updateConnectorEdges(this.nameTable[e.parentId])));var a=void 0;this.diagramActions=this.diagramActions|ee.PublicMethod;var l=this.nameTable[e.id];if(l instanceof te?("Bpmn"===l.shape.type&&this.bpmnModule&&this.bpmnModule.removeBpmnProcesses(l,this),(l.isLane||l.isPhase||"SwimLane"===l.shape.type)&&(h=l.isLane||l.isPhase?this.nameTable[l.parentId]:this.nameTable[l.id],l.isLane?_3(this,l,h):l.isPhase&&U3(this,l,h)),-1!==(a=this.nodes.indexOf(l))&&(this.crudDeleteNodes.push(this.nameTable[l.id]),this.nodes.splice(a,1),this.updateNodeEdges(l))):(-1!==(a=this.connectors.indexOf(l))&&(this.crudDeleteNodes.push(this.nameTable[l.id]),this.connectors.splice(a,1)),this.updateEdges(l),this.spliceConnectorEdges(e,!0),this.spliceConnectorEdges(e,!1)),!this.isServerUpdate&&!(this.blazorActions&on.GroupClipboardInProcess)&&this.commandHandler.getBlazorOldValues(),s&&this.historyManager.endGroupAction(),_r(this,l)&&this.unSelect(l),!l.isPhase){if(this.removeObjectsFromLayer(e),this.currentDrawingObject&&(this.currentDrawingObject.wrapper=void 0),delete this.nameTable[e.id],i.length>0&&i[0].id===l.id&&l.parentId){var h,d=this.nameTable[l.parentId];d&&d.isLane&&"SwimLane"===this.nameTable[d.parentId].shape.type&&F3(this,h=this.nameTable[d.parentId],d,l)}this.removeElements(l),this.updateBridging(),"SVG"!==this.mode&&this.refreshDiagramLayer(),this.diagramActions&ee.Clear||(this.removeFromAQuad(l),r={element:e,cause:this.diagramActions,diagramAction:this.getDiagramAction(this.diagramActions),state:"Changed",type:"Removal",cancel:!1},"helper"!==e.id&&this.triggerEvent(Ce.collectionChange,r),this.resetTool())}}}else if(i.length>0){this.undoRedoModule&&(this.historyManager.startGroupAction(),this.blazorActions|=on.GroupingInProgress,s=!0);for(var u=0;u=p.wrapper.bounds.width&&"Horizontal"===p.shape.orientation||this.selectedItems.wrapper.bounds.y<=p.wrapper.bounds.y+g&&this.selectedItems.wrapper.bounds.height>=p.wrapper.bounds.height-g&&"Vertical"===p.shape.orientation)&&(TI(p)||p.shape.lanes.length>1)&&this.remove(i[parseInt(u.toString(),10)])}}else this.remove(i[parseInt(u.toString(),10)])}s&&(this.blazorActions&=~on.GroupingInProgress,this.isServerUpdate=!0,this.commandHandler.getBlazorOldValues(),this.UpdateBlazorDiagramModelCollection(void 0,void 0,void 0,!0),this.historyManager.endGroupAction(),this.isServerUpdate=!1),this.clearSelection()}e&&(TI(e)||this.diagramActions&ee.Clear)||this.diagramActions&ee.UndoRedo||this.diagramActions&ee.PreventHistory||!(e instanceof te||e instanceof de)||(o={type:"ConnectionChanged",undoObject:$(e),redoObject:$(e),category:"Internal"},!e.isLane&&!e.isPhase&&!(this.diagramActions&ee.Clear)&&!this.isStackChild(e)&&this.addHistoryEntry(o)),this.tooltipObject.close()},t.prototype.isStackChild=function(e){var i,r=this.nameTable[e.parentId];if(e&&e.parentId&&r.container&&"Stack"===r.container.type&&"UmlClassifier"!==this.nameTable[e.parentId].shape.type){i=!0;var s={sourceIndex:r.wrapper.children.indexOf(e.wrapper),source:e,target:void 0,targetIndex:void 0};this.diagramActions&ee.UndoRedo||this.addHistoryEntry({type:"StackChildPositionChanged",redoObject:{sourceIndex:void 0,source:e,target:void 0,targetIndex:void 0},undoObject:s,category:"Internal"})}return i},t.prototype.deleteChild=function(e,i,r){var s;if(s="string"==typeof e?e:e.id,(i=i?this.nameTable[i.id]:this.nameTable[e.parentId])&&i.children){for(var o=0;o=0;i--)this.removeLayer(this.layers[parseInt(i.toString(),10)].id);this.commandHandler.addLayer({id:"default_layer",visible:!0,lock:!1,objects:[],zIndex:0,objectZIndex:-1,zIndexTable:{}},null,!0),this.setActiveLayer(this.layers[this.layers.length-1].id)},t.prototype.clearObjects=function(e){var i=[];i=e||(i=i.concat(this.nodes)).concat(this.connectors),this.diagramActions=this.diagramActions|ee.Clear;for(var r=0,s=i;r0||"Text"===e.shape.type))if("Text"===e.shape.type)i=e.wrapper.children[0].id.split("_")[1];else for(var p=e.annotations.length-1;p>=0;p--)e.annotations[parseInt(p.toString(),10)].visibility&&(i=e.annotations[parseInt(p.toString(),10)].id);i&&(u=this.getWrapper(e.wrapper,i))}if(e&&u&&!(u instanceof es)&&(!function Xre(n,t){return"Text"===t.shape.type?t.constraints&ie.ReadOnly:t.constraints&(t instanceof de?qe.ReadOnly:ie.ReadOnly)?n.constraints&Nr.InheritReadOnly?1:0:n.constraints&Nr.ReadOnly?1:0}(u,e)||f)){var g=u.style,v=void 0;v=90>(v=u.bounds.width50?50:e.width,u.style.fontSize)),e.parentId&&"UmlClassifier"===this.nameTable[e.parentId].shape.type?(l.width=e.wrapper.bounds.width-20,c=(e.wrapper.bounds.center.x+r.tx)*r.scale-l.width/2*s-2.5,d=(e.wrapper.bounds.center.y+r.ty)*r.scale-l.height/2*s-3,u.style.textAlign="Left"):(l.width=Math.max(l.width,50),c=(u.bounds.center.x+r.tx)*r.scale-l.width/2*s-2.5,d=(u.bounds.center.y+r.ty)*r.scale-l.height/2*s-3),Ho(y,{id:this.element.id+"_editTextBoxDiv",style:"position: absolute;left:"+c+"px;top:"+d+"px;width:"+(l.width+1)*s+"px;height:"+l.height*s+"px; containerName:"+e.id+";"}),Ho(S,{"aria-label":a,id:this.element.id+"_editBox",style:"width:"+(l.width+1)*s+"px;height:"+l.height*s+"px;resize: none;outline: none;overflow: hidden;;font-family:"+g.fontFamily+";font-size:"+g.fontSize*s+"px;text-align:"+u.style.textAlign.toLocaleLowerCase()+";",class:"e-diagram-text-edit"}),S.style.fontWeight=g.bold?"bold":"",S.style.fontStyle=g.italic?"italic":"",S.style.lineHeight=(1.2*g.fontSize+"px;").toString(),S.style.textDecoration=g.textDecoration?g.textDecoration:"",this.activeLabel.parentId=e.id,this.activeLabel.id=i,u.visible=!1,this.updateDiagramObject(e),this.diagramActions=this.diagramActions|ee.TextEdit,this.isTriggerEvent||(E.add(S,"input",this.eventHandler.inputChange,this.eventHandler),E.add(S,"focusout",this.focusOutEdit,this),S.select())}}}},t.prototype.updateConnectorfixedUserHandles=function(e){if(e.fixedUserHandles.length)for(var i=void 0,r=0,s=e.fixedUserHandles;r0&&this.mindMapChartModule.updateLayout(o,this.nameTable,this.layout,l,this.dataSourceSettings.id,this.dataSourceSettings.root),e=!0;else if(this.radialTreeModule)this.radialTreeModule.updateLayout(o,this.nameTable,this.layout,l),e=!0;else if(this.symmetricalLayoutModule)this.symmetricalLayoutModule.maxIteration=this.layout.maxIteration,this.symmetricalLayoutModule.springLength=this.layout.springLength,this.symmetricalLayoutModule.springFactor=this.layout.springFactor,this.symmetricalLayoutModule.updateLayout(o,this.connectors,this.symmetricalLayoutModule,this.nameTable,this.layout,l),e=!0;else if(this.complexHierarchicalTreeModule){this.canDistribute(a,r)&&(this.lineDistributionModule.diagram=this,this.connectors.forEach(function(P){P.obstaclePointCollection=[]}));var c=this.complexHierarchicalTreeModule.getLayoutNodesCollection(this.nodes);c.length>0&&this.complexHierarchicalTreeModule.doLayout(c,this.nameTable,this.layout,l,this),e=!0,this.canDistribute(a,r)&&this.lineDistributionModule.initLineDistribution(this.layout,this)}else this.flowchartLayoutModule?(this.flowchartLayoutModule.updateLayout(this.nodes,this),e=!0):console.warn("[WARNING] :: Module "+("OrganizationalChart"===this.layout.type?"HierarchicalTree":this.layout.type)+" is not available in Diagram component! You either misspelled the module name or forgot to load it.");if(e){this.preventDiagramUpdate=!0;for(var u={},p=0,g=o;p0)for(var S=0;S0)for(var M=0;M0)for(var s=0,o=r.ports;s0&&function Ese(n){var t,e,i,r=[];for(t=0;t0&&y.connectors[w].bezierSettings&&y.connectors[w].bezierSettings.allowSegmentsReset&&(y.connectors[w].segments=[]);if(t.connectors=y.connectors||[],t.dataSourceSettings=y.dataSourceSettings||{},t.dataSourceSettings.doBinding=i,t.height=y.height||"100%",t.setNodeTemplate=r,t.getConnectorDefaults=v,t.getNodeDefaults=g,t.getCustomProperty=o,t.mode=y.mode||"SVG",y.nodes)for(w=0;w0)){var r=this.nodes.filter(function(a){return 0===a.inEdges.length})[0],s=this.convertMindmapToMermaid(r,0);i.push(s),this.updateTextDataSource(i,r.outEdges,1),e=(i=i.filter(function(a){return""!==a.trim()})).join("\n")}return e},t.prototype.updateTextDataSource=function(e,i,r){for(var s=0;s0&&this.updateTextDataSource(e,h,r+1),s++}},t.prototype.convertMindmapToMermaid=function(e,i){var r=e.id,o=" ".repeat(2*(i+1)),a=e.annotations.length>0?e.annotations[0].content.replace(/\n/g," "):"",l=o+a,h=o+r;if(e.shape&&"Basic"===e.shape.type){var c=e.shape;"Rectangle"===c.shape?l=h+"["+a+"]":"Ellipse"===c.shape?l=h+"(("+a+"))":"Hexagon"===c.shape&&(l=h+"{{"+a+"}}")}else if(e.shape&&"Flow"===e.shape.type)"Terminator"===e.shape.shape&&(l=h+"("+a+")");else if(e.shape&&"Path"===e.shape.type){var u=e.shape;u.data===this.bangShape?l=h+"))"+a+"((":u.data===this.cloudShape&&(l=h+")"+a+"(")}return l},t.prototype.saveFlowDiagramInMermaidFormat=function(){var e=this,i=[],r="graph TD\n",s={nodes:this.nodes,edges:this.connectors};return s.nodes.reduce(function(a,l){return a[l.id]=l.annotations.length?l.annotations[0].content:"",a},{}),s.edges.forEach(function(a){var l=a.sourceID,h=a.targetID,f=e.nameTable[""+h],p=e.getNodeShape(e.nameTable[""+l]),g=e.getNodeShape(f),v=a.annotations[0]&&""!==a.annotations[0].content?"|"+a.annotations[0].content+"|":"";-1===i.indexOf(l)?i.push(l):p="",-1===i.indexOf(h)?i.push(h):g="";var y=e.arrowType(a);r+=" "+l+p+" "+y+v+" "+h+g+"\n"}),s.nodes.forEach(function(a){r+=" style "+a.id+" fill:"+a.style.fill+",stroke:"+a.style.strokeColor+",stroke-width:"+a.style.strokeWidth+"px;\n"}),r},t.prototype.arrowType=function(e){var i=e.targetDecorator.shape;return e.style.opacity<1?"~~~":""!==e.style.strokeDashArray?"-.->":"Arrow"===i?e.style.strokeWidth>1?"==>":"--\x3e":"None"===i?"---":"--\x3e"},t.prototype.getNodeShape=function(e){var i=e.annotations.length>0?e.annotations[0].content:"",r=e.shape.shape;if(!r){var s=e.shape.data;return"M 0 0 A 1 1 0 0 0 7 0 A 1 1 0 0 0 0 0 M -1 0 A 1 1 0 0 0 8 0 A 1 1 0 0 0 -1 0"===s?"((("+i+")))":"M 0 0 L 1 -1 L 5 -1 L 6 0 L 0 0"===s?"[/"+i+"\\]":"M 0 1 L 0 6 C 2 7 4 7 6 6 L 6 1 C 5 0 1 0 0 1 C 1 2 5 2 6 1"===s?"[("+i+")]":"M 0 0 L 12 0 L 14 2 L 2 2 L 0 0"===s?"[\\"+i+"\\]":"M 0 0 L 5 0 L 4 1 L 1 1 L 0 0"===s?"[\\"+i+"/]":"M 0 0 L 2 -2 L 11 -2 L 13 0 L 11 2 L 2 2 L 0 0"===s?"{{"+i+"}}":">"+i+"]"}switch(r){case"Terminator":return"(["+i+"])";case"Process":default:return"["+i+"]";case"Decision":return"{"+i+"}";case"Parallelogram":return"[/"+i+"/]";case"Ellipse":return"(("+i+"))";case"PreDefinedProcess":return"[["+i+"]]"}},t.prototype.loadDiagramFromMermaid=function(e){this.layout&&"Flowchart"===this.layout.type&&this.flowchartLayoutModule?this.convertMermaidToFlowChart(e):this.layout&&"MindMap"===this.layout.type&&this.mindMapChartModule?this.convertMermaidToMindmap(e):console.warn('[WARNING] :: Module "FlowchartLayout" or "MindMap" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.countLeadingSpaces=function(e){for(var i=0,r=e.length;i0});this.clear(),this.mermaidNodeBaseCollection=[];var r=[],s={text:"",children:[],currentLevel:0,branch:"Left"},o=[],l=!1,h=!1,c=!1;if(i.length>0){for(var d=function(M){var w=i[parseInt(M.toString(),10)],C=0,D="",A=u.countLeadingSpaces(w),x=w.includes('"`');if(h=w.includes('`"'),c=(l=!!x||l)||c?c:0===A&&M>0,l&&h&&!x)return s.text+="\n"+w,l=!1,"continue";if(!x&&l)return s.text+="\n"+w,"continue";if(l=!h&&l,w.length>0&&(/\s/.test(w[0])&&M>0||0===A)){if(-1!==o.findIndex(function(B){return B.space===A.toString()}))for(var L=o.length-1;L>=0;L--){var O=o[parseInt(L.toString(),10)];if((N=parseFloat(O.space))>A)o.splice(L,1);else{if(N=0;L--){var N,T=o[parseInt(L.toString(),10)];if(!((N=parseFloat(T.space))>A)){var z=o[o.length-1];o.push({space:A.toString(),level:z.level+1});break}o.splice(L,1)}C=o[o.length-1].level}D=w.trim().replace(/^[+-]/,"")}var U={text:D,branch:void 0,children:[],currentLevel:0===M?0:C-1};if(r.length>0){for(;r.length>=C&&0!==r.length;)r.pop();r.length>0&&r[r.length-1].children.push(U)}r.push(U),s=U},u=this,f=0;f0){var c=h[h.length-1];c.arrowType=a[2],""!==a[3]&&(c.label&&c.label.some(function(d){return d.trim().length>0})?c.label.push(a[3]):(c.label=[],c.label[c.parentId.length-1]=a[3]))}h.filter(function(d){return d.parentId&&0===d.parentId.length}).forEach(function(d){d.parentId=null}),i=i.concat(h)}}this.createFlowChart(i),this.doLayout(),this.clearHistory()},t.prototype.createFlowChart=function(e){for(var i=[],r=0;r1)for(var h=0;h|---|--\s*.*?\s*-->|~~~|==>|===|==\s*.*?\s*==>|\s*-\.\s*->|\s*-\.\s*-|\s*-\.\s*.*?\s*\.\s*->|\s*-\..*?\.\s*->)(.*)$/);if(l){i=l[1].trim();var h=l[2].trim();r=l[3].trim();var d=h.match(/(-\.|\\-\\-|==|--|~~)(.*?)(\1>|\.->|==>|\\->|~~>)/),u=void 0,f="";o=null!==(u=d?{text:d[2].trim()||null,arrowType:d[1]+d[3]}:{text:null,arrowType:h}).text?u.text:"",s=(f=u.arrowType).includes("--\x3e")?"single-line-arrow":f.includes("---")?"single-line":f.includes("==>")?"double-line-arrow":f.includes("==")?"double-line":f.includes("~~~")?"wiggly-arrow":f.includes("-.->")||f.includes(".->")?"dotted-arrow":f.includes("-.-")||f.includes(".-")?"dotted":"single-line-arrow"}return[i,r,s,o]},t.prototype.parseStyle=function(e,i){if(e.startsWith("style")){var s=e.match(/^style\s+(\w+)\s+fill:([^,]+),stroke:([^,]+),stroke-width:(\d+)px;/);if(s){var c={id:s[1],fill:s[2],stroke:s[3],strokeWidth:parseInt(s[4],10)},d=i.filter(function(u){return u.id===c.id});d[0].color=c.fill,d[0].stroke=c.stroke,d[0].strokeWidth=c.strokeWidth}}},t.prototype.getNodeData=function(e,i,r){for(var s=[],o=null,a=null,l=0,h="",c=function(v){var y=e[parseInt(v.toString(),10)],S=d.splitNested(y);if(S[0].includes("|")){var b=S[0].match(/\|([^|]*)\|/);b&&(h=b[1]);var M=S[0].split("|");M.length>=3&&(S[0]=M[2].trim())}var w=S[0].trim();if(0===v?o=w:a=w,i.find(function(L){return L.id===w}))l++;else{var D=S.length>1?S[1]:S[0],A=d.getShape(D),x=D.replace(/[\\[\]\\(\\)\\{\\}\\{\\}\\/>]/g,"");s.push({id:w,name:x,shape:A,color:"white",parentId:[]})}},d=this,u=0;u"===h?0===s?(r.trim().length>0&&i.push(r.trim()),r=h,o=h,s++):(r+=h,s++):"]"===h||"}"===h||")"===h?1===s&&h===o?(i.push((r+=h).trim()),r="",s--):s>1?(r+=h,s--):r+=h:r+=h}return r.trim().length>0&&i.push(r.trim()),i},t.prototype.getShape=function(e){var i={};return e.startsWith("(((")?i={type:"Path",data:"M 0 0 A 1 1 0 0 0 7 0 A 1 1 0 0 0 0 0 M -1 0 A 1 1 0 0 0 8 0 A 1 1 0 0 0 -1 0"}:e.startsWith("((")?i={shape:"Ellipse",type:"Basic"}:e.startsWith("([")?i={type:"Flow",shape:"Terminator"}:e.startsWith("(")?i={type:"Flow",shape:"Process"}:e.startsWith("[[")?i={type:"Flow",shape:"PreDefinedProcess"}:e.startsWith("[/")?i=e.endsWith("/]")?{type:"Basic",shape:"Parallelogram"}:{type:"Path",data:"M 0 0 L 1 -1 L 5 -1 L 6 0 L 0 0"}:e.startsWith("[(")?i={type:"Path",data:"M 0 1 L 0 6 C 2 7 4 7 6 6 L 6 1 C 5 0 1 0 0 1 C 1 2 5 2 6 1"}:e.startsWith("[\\")?i=e.endsWith("\\]")?{type:"Path",data:"M 0 0 L 12 0 L 14 2 L 2 2 L 0 0"}:{type:"Path",data:"M 0 0 L 5 0 L 4 1 L 1 1 L 0 0"}:e.startsWith("[")?i={type:"Basic",shape:"Rectangle"}:e.startsWith("{{")?i={type:"Path",data:"M 0 0 L 2 -2 L 11 -2 L 13 0 L 11 2 L 2 2 L 0 0"}:e.startsWith("{")?i={type:"Flow",shape:"Decision"}:e.startsWith(">")&&(i={type:"Path",data:"M 0 0 L 8 0 L 8 2 L 0 2 L 2 1 L 0 0"}),i},t.prototype.getDiagramContent=function(e){return this.printandExportModule?this.printandExportModule.getDiagramContent(e):(console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),"")},t.prototype.exportImage=function(e,i){this.printandExportModule?this.printandExportModule.exportImages(e,i):console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.printImage=function(e,i){this.printandExportModule?(i.printOptions=!0,this.printandExportModule.exportImages(e,i)):console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.setStackLimit=function(e){this.undoRedoModule&&e&&(this.historyManager.stackLimit=e,this.undoRedoModule.applyLimit(this.historyManager.currentEntry,e,this,!0))},t.prototype.clearHistory=function(){this.undoRedoModule&&this.undoRedoModule.clearHistory(this)},t.prototype.getDiagramBounds=function(){if(this.printandExportModule){var e=this.printandExportModule.getDiagramBounds("",{});return e.width=e.width>this.scrollSettings.viewPortWidth?e.width+(e.x>0?e.x:0):this.scrollSettings.viewPortWidth,e.height=e.height>this.scrollSettings.viewPortHeight?e.height+(e.y>0?e.y:0):this.scrollSettings.viewPortHeight,e.x=e.x>0?0:e.x,e.y=e.y>0?0:e.y,e}return console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),new Ne},t.prototype.exportDiagram=function(e){return this.printandExportModule?this.printandExportModule.exportDiagram(e):(console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),"")},t.prototype.print=function(e){this.printandExportModule?this.printandExportModule.print(e):console.warn('[WARNING] :: Module "PrintAndExport" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.addPorts=function(e,i){var s;this.protectPropertyChange(!0),e=this.nameTable[e.id]||e,i.length>1&&this.startGroupAction();for(var o=function(h){if(e.ports.some(function(y){return y.id===i[parseInt(h.toString(),10)].id}))return"continue";if(e instanceof te?(s=new Es(e,"ports",i[parseInt(h.toString(),10)],!0),e.ports.push(s)):e instanceof de&&(s=new Tc(e,"ports",i[parseInt(h.toString(),10)],!0),e.ports.push(s)),e.children)for(var c=e.wrapper,d=0;d1&&this.endGroupAction(),e.wrapper.measure(new me(e.width,e.height)),e.wrapper.arrange(e.wrapper.desiredSize),this.updateDiagramObject(e),this.protectPropertyChange(!1)},t.prototype.addConstraints=function(e,i){return e|i},t.prototype.removeConstraints=function(e,i){return e&~i},t.prototype.addNodeLabels=function(e,i){this.addLabels(e,i)},t.prototype.addConnectorLabels=function(e,i){this.addLabels(e,i)},t.prototype.addLabels=function(e,i){this.protectPropertyChange(!0);var s,r=(e=this.nameTable[e.id]||e).wrapper;i.length>1&&this.startGroupAction();for(var o=0;o1&&this.endGroupAction(),e.wrapper.measure(new me(r.width,r.height)),e.wrapper.arrange(r.desiredSize),this.updateDiagramObject(e),this.protectPropertyChange(!1),this.refreshCanvasLayers()},t.prototype.addChildToUmlNode=function(e,i,r){var s,o,a,l,h="NoWrap";"Class"===e.shape.classifier||"Interface"===e.shape.classifier?"Method"===r?(o=new cm(e,"",i),"Class"===e.shape.classifier?(e.shape.classShape.methods.push(o),s=e.shape.classShape):"Interface"===e.shape.classifier&&(e.shape.interfaceShape.methods.push(o),s=e.shape.interfaceShape),function Xse(n,t,e,i){if(e.methods&&e.methods.length){var r=e.methods,s="",o="",a=void 0,l=1,h=void 0,c=0,d=0,u=n.shape,g="Class"===u.classifier?u.classShape:u.interfaceShape;1===r.length?g.attributes.length>0?(c=g.attributes.filter(function(w){return w.isSeparator}).length,h=(l=2+g.attributes.length+c)+1,nT(n,t,l)):h=l+1:(c=g.attributes.filter(function(w){return w.isSeparator}).length,d=g.methods.filter(function(w){return w.isSeparator}).length,h=(l=2+g.attributes.length+c+g.methods.length+d)+1);for(var v=0;v1&&this.startGroupAction();for(var r=i.length-1;r>=0;r--)if(e.children&&e.children.length>0){var s=e.wrapper.children.filter(function(o){return o.id===e.id+"group_container"});s&&s.length>0&&this.removelabelExtension(e,i,r,s[0])}else this.removelabelExtension(e,i,r,e.wrapper);i.length>1&&this.endGroupAction(),this.refreshCanvasLayers()},t.prototype.removePortsExtenion=function(e,i,r,s){for(var o=0;o1&&this.startGroupAction();for(var r=i.length-1;r>=0;r--)if(e.children&&e.children.length>0)for(var s=0;s1&&this.endGroupAction()},t.prototype.getSizeValue=function(e,i){var r;return r=e.toString().indexOf("px")>0?e.toString():e.toString().indexOf("%")>0?void 0!==i?"100%":e.toString():e.toString()+"px",i&&(Za(this),r="calc("+r+" - "+i+"px)"),r},t.prototype.renderRulers=function(){this.rulerSettings.showRulers?(function Yne(n){var t=Za(n),i=Tt("div",{id:n.element.id+"_overlapRuler",style:"height:"+t.height+"px;width:"+t.width+"px;position:absolute;left:0;top:0",class:"e-ruler-overlap"});n.element.insertBefore(i,n.element.firstChild)}(this),eF(this,!0),eF(this,!1)):Qx(this)},t.prototype.intOffPageBackground=function(){var e=new me;e=Za(this);var i=document.getElementById(this.element.id+"content"),r=this.getSizeValue(this.width,e.width),s=this.getSizeValue(this.height,e.height),o=this.rulerSettings.showRulers?"width:"+r+"; height:"+s+";top:"+e.height+"px;left:"+e.width+"px;overflow: scroll;position:absolute;overflow:auto;":"width:"+r+"; height:"+s+";position:absolute; left:0px; top:0px;overflow: auto;",a={id:this.element.id+"content",tabindex:"0",style:o};i?(this.diagramCanvas=i,Ka(this.diagramCanvas,o)):(this.diagramCanvas=Tt("div",a),this.element.appendChild(this.diagramCanvas)),this.diagramCanvas.style.background=this.backgroundColor},t.prototype.initDiagram=function(){this.intOffPageBackground(),Ho(this.element,{style:"width:"+this.getSizeValue(this.width)+"; height:"+this.getSizeValue(this.height)+";position:relative;overflow:hidden;"})},t.prototype.renderHiddenUserHandleTemplateLayer=function(e){var r=Tt("div",{class:this.element.id+"_hiddenUserHandleTemplate",style:"width:"+e.width+"px; height:"+e.height+"px;visibility:hidden ; overflow: hidden;"});this.element.appendChild(r)},t.prototype.renderBackgroundLayer=function(e,i){var r=this.createSvg(this.element.id+"_backgroundLayer_svg",e.width,e.height);Ka(r,i);var s=Fi("g",{id:this.element.id+"_backgroundImageLayer",class:"e-background-image-layer"});r.appendChild(s);var a=Fi("g",{id:this.element.id+"_backgroundLayer",class:"e-background-layer"});r.appendChild(a),this.diagramCanvas.appendChild(r)},t.prototype.renderGridLayer=function(e,i){var r=this.createSvg(this.element.id+"_gridline_svg",e.width,e.height);r.setAttribute("class","e-grid-layer");var s=Fi("g",{id:this.element.id+"_gridline"}),o=Fi("rect",{id:this.element.id+"_grid_rect",x:"0",y:"0",width:"100%",height:"100%"});if(sm()){var a=new URL(window.location.href);o.setAttribute("fill",""!==a.search?"url(#"+this.element.id+"_pattern)":"url("+location.protocol+"//"+location.host+location.pathname+"#"+this.element.id+"_pattern)")}else o.setAttribute("fill","url(#"+this.element.id+"_pattern)");s.appendChild(o),r.appendChild(s),this.diagramCanvas.appendChild(r),ii(r,{style:i})},t.prototype.renderDiagramLayer=function(e,i){if(this.diagramLayerDiv=Tt("div",{id:this.element.id+"_diagramLayer_div",style:"width:"+e.width+"px; height:"+e.height+"px;"+i}),"SVG"===this.mode){var s=this.createSvg(this.element.id+"_diagramLayer_svg",e.width,e.height);s.style["pointer-events"]="none",s.setAttribute("class","e-diagram-layer");var o=Fi("g",{id:this.element.id+"_diagramLayer"}),a=Fi("g",{});this.diagramLayer=o,s.style["pointer-events"]="all",a.appendChild(o),s.appendChild(a),this.diagramLayerDiv.appendChild(s)}else this.diagramLayer=bo.createCanvas(this.element.id+"_diagram",e.width,e.height),Ka(this.diagramLayer,"position:absolute;left:0px;top:0px;"),this.diagramLayerDiv.appendChild(this.diagramLayer);this.diagramCanvas.appendChild(this.diagramLayerDiv)},t.prototype.initLayers=function(){var e="position:absolute;top:0px;left:0px;overflow:hidden;pointer-events:none;",r=document.getElementById(this.element.id).getBoundingClientRect(),s=function Soe(){var n=Tt("div",{style:"visibility:hidden; width: 100px"});document.body.appendChild(n);var t=n.getBoundingClientRect().width;n.style.overflow="scroll";var e=Tt("div",{style:"width:100%"});n.appendChild(e);var i=e.getBoundingClientRect().width;return n.parentNode.removeChild(n),t-i}();this.scroller.scrollerWidth=s,this.scroller.setViewPortSize(r.width,r.height),this.renderRulers();var o="measureElement";window[""+o]&&(window[""+o]=null,document.getElementById("measureElement").remove()),function BF(){var n="measureElement";if(window[""+n])window[""+n].usageCount+=1;else{var t=Tt("div",{id:"measureElement",style:"visibility:hidden ; height: 0px ; width: 0px; overflow: hidden;"}),e=Tt("span",{style:"display:inline-block ; line-height: normal"});t.appendChild(e);var i=Tt("img",{alt:"measureElementImage",src:"data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7"});t.appendChild(i);var r=document.createElementNS("http://www.w3.org/2000/svg","svg");r.setAttribute("xmlns:xlink","http://www.w3.org/1999/xlink"),t.appendChild(r);var s=document.createElementNS("http://www.w3.org/2000/svg","path");s.setAttribute("d",""),r.appendChild(s),document.createTextNode("");var a=document.createElementNS("http://www.w3.org/2000/svg","text");a.setAttributeNS("http://www.w3.org/XML/1998/namespace","xml:space","preserve"),r.appendChild(a),window[""+n]=t,window[""+n].usageCount=1,document.body.appendChild(t);var l="measureElementCount";window[""+l]?window[""+l]++:window[""+l]=1}}(),this.renderBackgroundLayer(r,e),this.renderGridLayer(r,e),this.renderDiagramLayer(r,e),this.renderHTMLLayer(r,e),this.renderPortsExpandLayer(r,e),this.renderNativeLayer(r,e),this.renderAdornerLayer(r,e),this.renderHiddenUserHandleTemplateLayer(r)},t.prototype.renderAdornerLayer=function(e,i){var r=Tt("div",{id:this.element.id+"_diagramAdornerLayer",style:"width:"+e.width+"px;height:"+e.height+"px;"+i}),s=Tt("div",{id:this.element.id+"_diagramUserHandleLayer",style:"width:"+e.width+"px;height:"+e.height+"px;"+i});s.setAttribute("class","e-userHandle-layer"),r.appendChild(s);var o=this.createSvg(this.element.id+"_diagramAdorner_svg",e.width,e.height);o.setAttribute("class","e-adorner-layer"),o.style["pointer-events"]="none",this.adornerLayer=Fi("g",{id:this.element.id+"_diagramAdorner"}),this.adornerLayer.style[" pointer-events"]="all",o.appendChild(this.adornerLayer),r.appendChild(o),this.diagramCanvas.appendChild(r);var a=Fi("g",{id:this.element.id+"_SelectorElement"});this.adornerLayer.appendChild(a),ii(o,{style:"pointer-events:none;"})},t.prototype.renderPortsExpandLayer=function(e,i){var r=this.createSvg(this.element.id+"_diagramPorts_svg",e.width,e.height);r.setAttribute("class","e-ports-expand-layer");var s=Fi("g",{id:this.element.id+"_diagramPorts",class:"e-ports-layer",style:"pointer-events: all;"});r.appendChild(s);var o=Fi("g",{id:this.element.id+"_diagramExpander",class:"e-expand-layer",style:"pointer-events: all;"});r.appendChild(o),this.diagramCanvas.appendChild(r),ii(r,{style:i})},t.prototype.renderHTMLLayer=function(e,i){this.htmlLayer=Tt("div",{id:this.element.id+"_htmlLayer",style:"width:"+e.width+"px; height:"+e.height+"px;position:absolute;top:0px;left:0px;overflow:hidden;pointer-events:none;",class:"e-html-layer"});var r=Tt("div",{id:this.element.id+"_htmlLayer_div",style:"position:absolute;top:0px;left:0px;pointer-events:all;"});this.htmlLayer.appendChild(r),this.diagramCanvas.appendChild(this.htmlLayer)},t.prototype.renderNativeLayer=function(e,i){var r=this.createSvg(this.element.id+"_nativeLayer_svg",e.width,e.height),s=Fi("g",{id:this.element.id+"_nativeLayer",style:"pointer-events:all;"});r.appendChild(s),this.diagramLayerDiv.appendChild(r),ii(r,{class:"e-native-layer",style:i})},t.prototype.createSvg=function(e,i,r){var s=document.createElementNS("http://www.w3.org/2000/svg","svg");return ii(s,{id:e,width:i,height:r}),s},t.prototype.updateBazorShape=function(){for(var e=0;e1,i=[],r={},s={},o=[],a=0,l=this.nodes;a0||b&&b.children&&b.children.length>0)&&(M=!1),S&&S.wrapper&&b&&b.wrapper&&M?this.initConnectors(r[""+h],p):i.push(r[""+h])}else b=r[y.targetID],(S=r[y.sourceID])&&S.children&&S.children.length>0||b&&b.children&&b.children.length>0?i.push(r[""+h]):this.initConnectors(r[""+h],p);else r[""+h].children?o.push(h):r[""+h].shape instanceof hT&&r[""+h].shape.activity.subProcess.processes&&r[""+h].shape.activity.subProcess.processes.length>0?s[r[""+h].id]=h:this.initNodes(r[""+h],p);if(this.bpmnModule)for(var w=0,C=this.bpmnModule.bpmnTextAnnotationConnector;w-1&&-1===r.indexOf(c)&&-1===s.indexOf(c)&&r.splice(0,0,c);-1===r.indexOf(o)&&s.push(o)}return r.concat(s)},t.prototype.addToLayer=function(e,i){var r;if(i&&(r=this.commandHandler.getObjectLayer(e.id)),(!i||!r)&&-1===this.activeLayer.objects.indexOf(e.id)&&this.activeLayer.objects.push(e.id),(e instanceof te||e instanceof de)&&("SwimLane"!==e.shape.type||e.children&&e.children.length>0)){if(e.parentId){var s=this.swimlaneZIndexTable[e.parentId],o=this.swimlaneChildTable[e.id];(s&&-1!==s||o&&-1!==o)&&(e.zIndex=this.swimlaneChildTable[e.id])}e instanceof de&&e.sourceID&&e.targetID?-1!==this.activeLayer.objects.indexOf(e.sourceID)&&-1!==this.activeLayer.objects.indexOf(e.targetID)&&this.setZIndex(r||this.activeLayer,e):this.setZIndex(r||this.activeLayer,e)}},t.prototype.updateLayer=function(e){for(var i=0,r=Object.keys(e.layers);i0)for(r=0;rs;l--)r.zIndexTable[parseInt(l.toString(),10)]=r.zIndexTable[l-1],this.nameTable[r.zIndexTable[parseInt(l.toString(),10)]]&&(this.nameTable[r.zIndexTable[parseInt(l.toString(),10)]].zIndex=l);r.zIndexTable[parseInt(a.toString(),10)]=i.id}}},t.prototype.initializeDiagramLayers=function(){for(var e=0;ethis.layers[parseInt(a.toString(),10)].zIndex&&(i=this.layers[parseInt(e.toString(),10)],this.layers[parseInt(e.toString(),10)]=this.layers[parseInt(a.toString(),10)],this.layers[parseInt(a.toString(),10)]=i);0===this.layers.length&&this.commandHandler.addLayer({id:"default_layer",visible:!0,lock:!1,objects:[],zIndex:0,objectZIndex:-1,zIndexTable:{}},null,!0),this.setActiveLayer(this.layers[this.layers.length-1].id)},t.prototype.resetTool=function(){this.eventHandler.resetTool()},t.prototype.initObjectExtend=function(e,i,r){if(r){var s=this.commandHandler.checkBoundaryConstraints(void 0,void 0,e.wrapper.bounds,!0);if("SwimLane"===e.shape.type)for(var o=0,a=Object.keys(i.zIndexTable);o0)&&this.setZIndex(i,e)),e instanceof te){if(r){if("helper"!==e.id&&(o=Zi(this.getNodeDefaults))){if((a=o(e,this))&&a.ports)for(var l=0;l0)for(l=0;l0&&!e.container||e.processId){var r=this.nameTable[e.id];if(!(this.realActions&$i.PreventScale||this.realActions&$i.PreventDrag)){if(r.offsetX&&(this.realActions&$i.EnableGroupAction||!(this.diagramActions&ee.UndoRedo||this.diagramActions&ee.ToolAction||this.diagramActions&ee.PublicMethod))){this.realActions|=$i.PreventScale;var s=r.offsetX-e.wrapper.offsetX;r.offsetX=e.wrapper.offsetX;var o=r.offsetY-e.wrapper.offsetY;r.offsetY=e.wrapper.offsetY,s+o!==0&&this.drag(r,s,o),this.realActions&=~$i.PreventScale}else r.offsetX=e.wrapper.offsetX;r.offsetY&&(this.realActions&$i.EnableGroupAction||!(this.diagramActions&ee.UndoRedo||this.diagramActions&ee.ToolAction||this.diagramActions&ee.PublicMethod))?(this.realActions|=$i.PreventScale,o=r.offsetY-e.wrapper.offsetY,r.offsetY=e.wrapper.offsetY,this.drag(r,0,o),this.realActions&=~$i.PreventScale):r.offsetY=e.wrapper.offsetY,this.diagramActions&&(r.width=e.wrapper.actualSize.width,r.height=e.wrapper.actualSize.height)}}i&&e.children&&e.children.length>0&&(void 0!==this.nameTable[e.id].width?this.scaleObject(e,this.nameTable[e.id].width,!0):this.nameTable[e.id].width=e.wrapper.actualSize.width,void 0!==this.nameTable[e.id].height?this.scaleObject(e,this.nameTable[e.id].height,!1):this.nameTable[e.id].height=e.wrapper.actualSize.height)},t.prototype.initNode=function(e,i,r){var a,f,s=e.initContainer(),o=new Mi;if(this.diagramSettings.inversedAlignment||(s.inversedAlignment=!1),s.children||(s.children=[]),e.children){s.measureChildren=!1,o.id=e.id+"group_container",o.style.fill=e.shape&&"SwimLane"===e.shape.type?e.style.fill:"none",o.style.strokeColor="none",o.horizontalAlignment="Stretch",o.verticalAlignment="Stretch",o.pivot=e.pivot,s.style=e.style,s.padding.left=e.padding.left,s.padding.right=e.padding.right,s.padding.top=e.padding.top,s.padding.bottom=e.padding.bottom,o.children=[],o.preventContainer=!0,e.container&&(o.relativeMode="Object");var l=!!(e.ports&&e.ports.length>0);if(m(e.container)&&!l&&s.children.push(o),e.container&&"Grid"===e.container.type)for(var h=0;h0&&e.wrapper.children[0]instanceof Wv){if(this.setZIndex(this.activeLayer,e),this.connectors.length>0)for(h=0;h0?i.phases.length:0,v="Horizontal"===i.orientation,y=v?i.phases.length||1:s.length+1,S=v?(i.header&&i.hasHeader?1:0)+(i.phases.length>0?1:0)+i.lanes.length:(i.header&&i.hasHeader?1:0)+i.phases.length;if(0===h&&!v&&i.lanes.length&&(S+=1),v?(a=(i.header&&i.hasHeader?1:0)+(h>0?1:0),l=0):(a=i.header&&i.hasHeader?1:0,l=h>0?1:0),s.length>0)for(o+=i.header&&i.hasHeader?i.header.height:0,f=0;fl?d.margin.left=d.margin.left-(u.bounds.left-e.bounds.left):u.children[0].children[1].actualSize.width+r>=d.margin.left&&(d.margin.left=u.children[0].children[1].actualSize.width+r),d.margin.lefta?d.margin.top=d.margin.top-(u.bounds.top-o):u.children[0].children[1].actualSize.height+r>=d.margin.top&&(d.margin.top=u.children[0].children[1].actualSize.height+r),d.margin.left0)for(o=0;o0&&this.updateChildPosition(e)},t.prototype.addBpmnAnnotationConnector=function(e,i){if(e.parentObj instanceof t||e.parentObj instanceof Hd){var r=e.shape,o=""!==r.textAnnotation.textAnnotationTarget&&this.nameTable[r.textAnnotation.textAnnotationTarget],a=o?this.nameTable[r.textAnnotation.textAnnotationTarget]:null,l=null!=a?a.wrapper:null,h=e.ports[0],c={x:0,y:0};switch(r.textAnnotation.textAnnotationDirection){case"Left":h.offset={x:0,y:.5},c.x=i.bounds.left-40,c.y=i.bounds.bottom+30;break;case"Right":h.offset={x:1,y:.5},c.x=i.bounds.right+40,c.y=i.bounds.bottom+30;break;case"Top":h.offset={x:.5,y:0},c.x=i.bounds.right+30,c.y=i.bounds.top-40;break;case"Bottom":h.offset={x:.5,y:1},c.x=i.bounds.right+30,c.y=i.bounds.bottom+40;break;default:h.offset={x:0,y:.5},c.x=i.bounds.left-40,c.y=i.bounds.bottom+30,o&&null!=i&&null!=l&&(i.bounds.left>l.bounds.right?h.offset={x:0,y:.5}:i.bounds.rightl.bounds.top?h.offset={x:.5,y:0}:i.bounds.top0&&this.updateChildPosition(r)}},t.prototype.canExecute=function(){return!0},t.prototype.updateStackProperty=function(e,i,r){e.container&&"Stack"===e.container.type&&(i.width||(i.wrapper.horizontalAlignment="Stretch",i.horizontalAlignment="Stretch"),i.height||(i.verticalAlignment="Stretch",i.wrapper.verticalAlignment="Stretch"),r&&"UmlClassifier"===e.shape.type&&(i.umlIndex=r))},t.prototype.initViews=function(){this.isLoading||(this.views.push(this.element.id),this.views[this.element.id]=this)},t.prototype.initCommands=function(){var e=this.commandManager.commands,i={copy:{execute:this.copyCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.C,keyModifiers:ft.Control}},paste:{execute:this.pasteCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.V,keyModifiers:ft.Control}},cut:{execute:this.cutCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.X,keyModifiers:ft.Control}},delete:{execute:this.removeCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Delete}},selectAll:{execute:this.selectAll.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.A,keyModifiers:ft.Control}},undo:{execute:this.undo.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Z,keyModifiers:ft.Control}},redo:{execute:this.redo.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Y,keyModifiers:ft.Control}},nudgeUp:{execute:this.nudgeCommand.bind(this,"Up"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Up},parameter:"up"},nudgeRight:{execute:this.nudgeCommand.bind(this,"Right"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Right},parameter:"right"},nudgeDown:{execute:this.nudgeCommand.bind(this,"Down"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Down},parameter:"down"},nudgeLeft:{execute:this.nudgeCommand.bind(this,"Left"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Left},parameter:"left"},startEdit:{execute:this.startEditCommad.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.F2}},endEdit:{execute:this.endEditCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Escape}},focusToNextItem:{execute:this.navigateItems.bind(this,!0),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Tab}},focusToPreviousItem:{execute:this.navigateItems.bind(this,!1),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Tab,keyModifiers:ft.Shift}},selectFocusedItem:{execute:this.startEditCommad.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Enter}},bold:{execute:this.fontStyleCommand.bind(this,"bold"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.B,keyModifiers:ft.Control}},italic:{execute:this.fontStyleCommand.bind(this,"italic"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.I,keyModifiers:ft.Control}},underline:{execute:this.fontStyleCommand.bind(this,"underline"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.U,keyModifiers:ft.Control}},duplicate:{execute:this.duplicateCommand.bind(this),canExecute:this.canExecute.bind(this),gesture:{key:Mt.D,keyModifiers:ft.Control}},group:{execute:this.groupCommand.bind(this,"group"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.G,keyModifiers:ft.Control}},ungroup:{execute:this.groupCommand.bind(this,"ungroup"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.U,keyModifiers:ft.Control|ft.Shift}},rotateClockwise:{execute:this.rotateCommand.bind(this,"clockwise"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.R,keyModifiers:ft.Control}},rotateAntiClockwise:{execute:this.rotateCommand.bind(this,"antiClockwise"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.L,keyModifiers:ft.Control}},flipHorizontal:{execute:this.flipCommand.bind(this,"horizontal"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.H,keyModifiers:ft.Control}},flipVertical:{execute:this.flipCommand.bind(this,"vertical"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.J,keyModifiers:ft.Control}},pointerTool:{execute:this.toolCommand.bind(this,"pointer"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number1,keyModifiers:ft.Control}},textTool:{execute:this.toolCommand.bind(this,"text"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number2,keyModifiers:ft.Control}},connectTool:{execute:this.toolCommand.bind(this,"connect"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number3,keyModifiers:ft.Control}},freeForm:{execute:this.toolCommand.bind(this,"freeForm"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number5,keyModifiers:ft.Control}},lineTool:{execute:this.toolCommand.bind(this,"line"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number6,keyModifiers:ft.Control}},rectangleTool:{execute:this.toolCommand.bind(this,"rectangle"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number8,keyModifiers:ft.Control}},ellipseTool:{execute:this.toolCommand.bind(this,"ellipse"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Number9,keyModifiers:ft.Control}},zoomIn:{execute:this.zoomCommand.bind(this,"zoomIn"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Plus,keyModifiers:ft.Control}},zoomOut:{execute:this.zoomCommand.bind(this,"zoomOut"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Minus,keyModifiers:ft.Control}},shiftUp:{execute:this.shiftCommand.bind(this,"Up"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Up,keyModifiers:ft.Shift}},shiftDown:{execute:this.shiftCommand.bind(this,"Down"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Down,keyModifiers:ft.Shift}},shiftLeft:{execute:this.shiftCommand.bind(this,"Left"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Left,keyModifiers:ft.Shift}},shiftRight:{execute:this.shiftCommand.bind(this,"Right"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.Right,keyModifiers:ft.Shift}},alignTextCenter:{execute:this.alignCommand.bind(this,"center"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.C,keyModifiers:ft.Control|ft.Shift}},alignTextLeft:{execute:this.alignCommand.bind(this,"right"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.L,keyModifiers:ft.Control|ft.Shift}},alignTextRight:{execute:this.alignCommand.bind(this,"left"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.R,keyModifiers:ft.Control|ft.Shift}},alignTextTop:{execute:this.alignCommand.bind(this,"top"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.E,keyModifiers:ft.Control|ft.Shift}},alignTextCenterVertical:{execute:this.alignCommand.bind(this,"centerVertical"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.M,keyModifiers:ft.Control|ft.Shift}},alignTextBottom:{execute:this.alignCommand.bind(this,"bottom"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.V,keyModifiers:ft.Control|ft.Shift}},alignJustify:{execute:this.alignCommand.bind(this,"justify"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.J,keyModifiers:ft.Control|ft.Shift}},sendToBack:{execute:this.orderCommand.bind(this,"sendToBack"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.B,keyModifiers:ft.Control|ft.Shift}},bringToFront:{execute:this.orderCommand.bind(this,"bringToFront"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.F,keyModifiers:ft.Control|ft.Shift}},sendBackward:{execute:this.orderCommand.bind(this,"sendBackward"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.BracketLeft,keyModifiers:ft.Control}},bringForward:{execute:this.orderCommand.bind(this,"bringForward"),canExecute:this.canExecute.bind(this),gesture:{key:Mt.BracketRight,keyModifiers:ft.Control}}};this.initCommandManager(e,i)},t.prototype.overrideCommands=function(e,i){for(var r,s=0,o=Object.keys(i);se.zIndex){("HTML"===e.shape.type||"Native"===e.shape.type)&&(o="HTML"===e.shape.type?"html":"native"),s=poe(i,r[parseInt(a.toString(),10)].id,o);break}return s},t.prototype.updateDiagramObject=function(e,i,r){for(var s,o="domTable",a=0,l=this.views;a1&&(d=this.commandHandler.getObjectLayer(e.id)),void 0===d||d&&d.visible||r){var u=Io(this.element.id);window[""+o][s.element.id+"_diagramLayer"]||(window[""+o][s.element.id+"_diagramLayer"]=document.getElementById(s.element.id+"_diagramLayer"));var f=window[""+o][s.element.id+"_diagramLayer"];this.diagramActions&ee.Interactions&&this.updateCanupdateStyle(e.wrapper.children,!0);var p=this.getMidPoint(e);this.diagramRenderer.updateNode(e.wrapper,f,u,void 0,i?void 0:this.getZindexPosition(e,s.element.id),p,this.portCenterPoint),this.updateCanupdateStyle(e.wrapper.children,!0)}}},t.prototype.applyMarginBezier=function(e,i){i.cx=i.cx+e.margin.left,i.cx=i.cx-e.margin.right,i.cy=i.cy+e.margin.top,i.cy=i.cy-e.margin.bottom},t.prototype.getMidPoint=function(e){var i;if(e instanceof de&&"Bezier"===e.type){i=[];for(var r=this.getBezierPoints(e),s=R.getLengthFromListOfPoints(r),o=0;o0&&e.updateView(e));var s=Io(e.element.id);this.renderDiagramElements(e.diagramLayer,e.diagramRenderer,s,void 0,void 0,i);for(var o=0;o0&&this.renderBasicElement(e),!this.diagramActions||!(this.diagramActions&ee.Render)||ee.ToolAction&this.diagramActions||Ds(this)||1!==this.scroller.currentZoom?this.refreshElements(e):this.renderTimer||(this.renderTimer=setTimeout(function(){i.refreshElements(e)},40)))},t.prototype.updatePortVisibility=function(e,i,r){var s;if((e instanceof te||e instanceof de)&&(!this.drawingObject||!this.drawingObject.shape)&&ro(e)){for(var a=e.ports,l=!1,h=0;h=0&&this.scroller.removeCollection.splice(l,1);var h=this.nameTable[e[parseInt(a.toString(),10)]];this.updateTextElementValue(h),this.diagramRenderer.renderElement(h.wrapper,s,o,void 0,void 0,void 0,void 0,h.zIndex)}for(var c=0;c0?this.scroller.oldCollectionObjects:void 0,b=Object.keys(S||g.zIndexTable);b.sort(function(N,T){return parseInt(""+N,10)-parseInt(""+T,10)});for(var M=0,w=b;M0?h:0)+"px",y=(this.realActions&$i.vScrollbarMoved?0:-(this.scroller.verticalOffset<0?this.scroller.verticalOffset:0))+"px"):(v="0px",y="0px"),this.realActions&$i.hScrollbarMoved&&(this.realActions=this.realActions&~$i.hScrollbarMoved),this.realActions&$i.vScrollbarMoved&&(this.realActions=this.realActions&~$i.vScrollbarMoved)):(v=(l.x<0?h:-this.scroller.horizontalOffset)+"px",y=(l.y<0?c:-this.scroller.verticalOffset)+"px"),this.diagramLayer.style.left=v,this.diagramLayer.style.top=y,A.tx=-l.x/A.scale,A.ty=-l.y/A.scale);var P=!0;if(o&&(P=!1),this.updateTextElementValue(D),this.refreshing&&D.shape.activity&&D.shape.activity.subProcess&&D.shape.activity.subProcess.processes){for(var L=0;L0){var o=s.children[0],a=o.data;(r.isBezierEditing&&this.selectedItems.connectors[0].id===r.id||"Bezier"!==r.type)&&r.getSegmentElement(r,o,"ComplexHierarchicalTree"===this.layout.type||"HierarchicalTree"===this.layout.type?this.layout.orientation:void 0,void 0,!1),o.data!==a&&(s.measure(new me),s.arrange(s.desiredSize),"SVG"===this.mode&&!e&&this.updateDiagramObject(r))}}else this.constraints&nt.Bridging&&console.warn('[WARNING] :: Module "ConnectorBridging" is not available in Diagram component! You either misspelled the module name or forgot to load it.')},t.prototype.setCursor=function(e){this.diagramRenderer.setCursor(this.diagramCanvas,e)},t.prototype.clearCanvas=function(e){var i=e.contentWidth||e.diagramLayer.width/this.scroller.currentZoom,r=e.contentHeight||e.diagramLayer.height/this.scroller.currentZoom;"SVG"!==e.mode&&bo.getContext(e.diagramLayer).clearRect(0,0,i,r)},t.prototype.updateScrollOffset=function(){this.scroller.setScrollOffset(this.diagramCanvas.scrollLeft,this.diagramCanvas.scrollTop),qI(this),Ds(this)&&this.scroller.virtualizeElements()},t.prototype.setOffset=function(e,i){var r="domTable";window[""+r][this.element.id+"content"]||(window[""+r][this.element.id+"content"]=document.getElementById(this.element.id+"content"));var s=window[""+r][this.element.id+"content"];s&&(s.scrollLeft=e,s.scrollTop=i)},t.prototype.setSize=function(e,i){if(this.diagramLayer&&!this.preventDiagramUpdate){var r=Za(this);e-=r.width,i-=r.height;var s=this.spatialSearch.getPageBounds();s.x*=this.scroller.currentZoom,s.y*=this.scroller.currentZoom,s.width*=this.scroller.currentZoom,s.height*=this.scroller.currentZoom;var o="SVG"===this.mode?1:1.5,a="SVG"===this.mode?pT(this.element.id):this.diagramLayer,h="Canvas"===this.mode&&this.constraints&nt.Virtualization?this.scroller.viewPortHeight:i;a.setAttribute("width",(o*("Canvas"===this.mode&&this.constraints&nt.Virtualization?this.scroller.viewPortWidth:e)).toString()),a.setAttribute("height",(o*h).toString());var c=document.getElementById(this.element.id+"_diagramUserHandleLayer");c&&(c.style.width=e+"px",c.style.height=i+"px");var d={width:e.toString(),height:i.toString()};this.diagramLayerDiv.style.width=e+"px",this.diagramLayerDiv.style.height=i+"px",ii(kF(this.element.id),d),ii(function voe(n){return xt(n).getElementsByClassName("e-ports-expand-layer")[0]}(this.element.id),d);var u=Bl(this.element.id);ii(u,d),u.parentNode.style.width=e+"px",u.parentNode.style.height=i+"px";var f=Fd(this.element.id);ii(f,d),this.diagramRenderer.updateGrid(this.snapSettings,f,this.scroller.transform,this.rulerSettings,this.hRuler,this.vRuler),ii(mT(this.element.id),d),this.htmlLayer.style.width=e+"px",this.htmlLayer.style.height=i+"px","SVG"!==this.mode&&!Ds(this)&&this.refreshDiagramLayer(),"SVG"===this.mode&&Ds(this)&&this.scroller.virtualizeElements()}},t.prototype.transformLayers=function(){var e=this.spatialSearch.getPageBounds();e.x*=this.scroller.currentZoom,e.y*=this.scroller.currentZoom,e.width*=this.scroller.currentZoom,e.height*=this.scroller.currentZoom,this.diagramRenderer.updateGrid(this.snapSettings,Fd(this.element.id),this.scroller.transform,this.rulerSettings,this.hRuler,this.vRuler),this.diagramRenderer.transformLayers(this.scroller.transform,"SVG"===this.mode),this.diagramActions&ee.DragUsingMouse||this.updateSelector(),this.renderPageBreaks(e)},t.prototype.removePageBreaks=function(){if(this.diagramLayer){var e=PF(this.element.id);if(e&&e.childNodes)for(var i=e.childNodes.length,r=0;rthis.pageSettings.height&&(e=this.pageSettings.height,this.pageSettings.height=this.pageSettings.width,this.pageSettings.width=e):this.pageSettings.height>this.pageSettings.width&&(e=this.pageSettings.width,this.pageSettings.width=this.pageSettings.height,this.pageSettings.height=e)},t.prototype.setOverview=function(e,i){if(e)e&&(this.views.push(e.id),this.views[e.id]=e,e.renderDocument(e),e.diagramRenderer.setLayers(),e.updateView(e),this.renderNodes(e));else{for(var r=0;r1&&this.updateSelectionRectangle(),this.isProtectedOnChange=s},t.prototype.updateSelectionRectangle=function(){for(var e=dm(this.element.id),i=!1,r=0;r1&&this.updateSelectionRectangle(),this.enableServerDataBinding(e)},t.prototype.renderSelectorForAnnotation=function(e,i){this.diagramRenderer.renderResizeHandle(e.wrapper.children[0],i,e.thumbsConstraints,this.scroller.currentZoom,e.constraints,this.scroller.transform,void 0,ro(e.annotation),void 0,void 0,e.handleSize)},t.prototype.drawSelectionRectangle=function(e,i,r,s){this.clearSelectorLayer(),this.diagramRenderer.drawSelectionRectangle(e,i,r,s,this.adornerLayer,this.scroller.transform)},t.prototype.renderHighlighter=function(e){var i=Bl(this.element.id);this.diagramRenderer.renderHighlighter(e,i,this.scroller.transform)},t.prototype.clearHighlighter=function(){var e=Bl(this.element.id),i=e.getElementById(e.id+"_highlighter");i&&i.parentNode.removeChild(i)},t.prototype.getNodesConnectors=function(e){for(var i=0;i0;h--)this.eventHandler&&this.eventHandler.touchArgs&&"touchmove"===this.eventHandler.touchArgs.type?(this.diagramRenderer.touchMove=!0,l&&l===o[h-1].id||(a=o[h-1]).parentNode.removeChild(a)):(a=o[h-1]).parentNode.removeChild(a);if(!ce()){var c=vT(this.element.id).childNodes;for(r=c.length;r>0;r--)c[r-1].parentNode.removeChild(c[r-1])}}},t.prototype.getWrapper=function(e,i){var r;i=e.id+"_"+i;for(var s=e instanceof Mi?e:this.getPortContainer(this.nameTable[e.id]),o=0;o0&&this.applyStyle(e,a=r.annotations)}for(i=0;i0){var a=this.selectedItems.connectors[parseInt(i.toString(),10)].annotations;this.applyStyle(e,a)}},t.prototype.applyStyle=function(e,i){for(var r=0;r0)for(var i=0;i0?r[0].zIndex+(e?1:-1):e?0:this.nodes.length+this.connectors.length-1)<0?i=this.nodes.length+this.connectors.length-1:i===this.nodes.length+this.connectors.length&&(i=0);for(var s=0;s0)for(var s=void 0,o=r.children.length-1;o>=0;o--){var a=r.children[parseInt(o.toString(),10)];i.length>0&&-1!==i.indexOf(a.id.split("_groupElement")[0])&&(r.parentNode.insertBefore(a,s||r),s=a)}r&&r.parentNode.removeChild(r)},t.prototype.deleteGroup=function(e){var r=[];e.children&&(r=this.commandHandler.getChildren(e,[])),this.UpdateBlazorDiagramModelCollection(e);for(var s=0,o=r;s0)for(var xe=0;xe0)if("Path"===t.shape.type&&void 0!==n.shape.data)t.wrapper.children[0].data=n.shape.data;else if("Text"===t.shape.type&&void 0!==n.shape.content)t.wrapper.children[0].content=n.shape.content;else if("Image"===t.shape.type&&void 0!==n.shape.source)t.wrapper.children[0].source=n.shape.source;else if("Native"===t.shape.type){for(var r=void 0,s=0;s-1)&&(this.diagramActions&ee.PreventZIndexOnDragging?this.updateDiagramObject(e,!0):this.updateDiagramObject(e)),!s&&d&&(this.lineRoutingModule&&this.diagramActions&&this.constraints&nt.LineRouting&&"helper"!==e.id?this.diagramActions&ee.ToolAction||this.lineRoutingModule.renderVirtualRegion(this,!0):this.diagramActions&&this.constraints&nt.LineRouting&&"helper"!==e.id&&console.warn('[WARNING] :: Module "LineRouting" is not available in Diagram component! You either misspelled the module name or forgot to load it.'),this.updateConnectorEdges(e),"helper"!==e.id&&!(this.diagramActions&ee.ToolAction))))for(var Sa=this.spatialSearch.findObjects(e.wrapper.outerBounds),Mo=0;Moe?Math.abs(r-e):Math.abs(e-r),d=s>i?Math.abs(s-i):Math.abs(i-s);(0===c&&0===d||Number.isNaN(c)&&Number.isNaN(d))&&o.laneMargin&&(u=o.margin.left-o.laneMargin.left,f=o.margin.top-o.laneMargin.top);var p=o.width,g=o.height,v=new Ne(0,0,0,0);if(0!==p&&0!==g&&(v=new Ne((0!==r?r:o.offsetX)-p/2,(0!==s?s:o.offsetY)-g/2,p,g)),h){var y=l,b=this.selectedItems.nodes?this.selectedItems.nodes[0]:void 0;if(""!==y.textAnnotation.textAnnotationTarget&&this.nameTable[y.textAnnotation.textAnnotationTarget])if(""===o.parentId||b&&b.shape&&"TextAnnotation"===b.shape.shape){if("Auto"===y.textAnnotation.textAnnotationDirection&&a.children[0]instanceof Mi&&a.children[0].children[0]instanceof Ze){var w=a.children[0],C=document.getElementById(w.id+"_groupElement"),D=document.getElementById(w.children[0].id+"_groupElement");C.removeChild(D),w.children.splice(0,1),this.isProtectedOnChange=!0,this.bpmnModule.setAnnotationPath(v,w,o,y,y.textAnnotation.textAnnotationDirection,this),this.isProtectedOnChange=!1}}else this.isPositionUndo=!0,this.updateTextAnnotationInSwimlane(o,o),this.isPositionUndo=!1;else o.inEdges.length>0&&(x=this.nameTable[""+o.inEdges[0]])&&x.isBpmnAnnotationConnector&&(x.sourcePoint={x:r>e?x.sourcePoint.x+c:x.sourcePoint.x-c,y:s>i?x.sourcePoint.y+d:x.sourcePoint.y-d});this.nodePropertyChange(o,{},P={ports:[{offset:o.ports[0].offset}]})}else for(var L=0,O=o.outEdges;Le?T.offsetX+c:T.offsetX-c,T.offsetY=s>i?T.offsetY+d:T.offsetY-d,P={offsetX:T.offsetX,offsetY:T.offsetY}),this.nodePropertyChange(T,z,P)}}}},t.prototype.updatePorts=function(e,i){if(e&&e.ports.length>0)for(var r=0,s=Object.keys(e.ports);r0)for(var i=0;i0)for(var r=0;r0&&void 0===r.segments&&(e.segments=[]),void 0!==r.shape&&void 0!==e.shape&&e.shape&&"Bpmn"===e.shape.type&&this.bpmnModule&&this.bpmnModule.updateBPMNConnector(e,i,r,this),void 0!==e.constraints?(this.updateThumbConstraints(this.selectedItems.connectors,this.selectedItems),s=!0):s},t.prototype.connectorPropertyChange=function(e,i,r,s,o){if(this.canEnableBlazorObject){var a=$(e);this.insertValue(a,!1)}var d,u,f,p,l=e.wrapper.bounds,h=!1,c=[];if(h=this.connectorProprtyChangeExtend(e,i,r,h),void 0!==r.visible&&this.updateElementVisibility(e.wrapper,e,e.visible),void 0!==r.sourcePoint||void 0!==r.targetPoint||void 0!==r.sourceID||void 0!==r.targetID||void 0!==r.targetPadding||void 0!==r.sourcePortID||void 0!==r.targetPortID||void 0!==r.sourcePadding||void 0!==r.type||void 0!==r.segments||void 0!==r.flip){if(void 0!==r.sourceID&&r.sourceID!==i.sourceID||r.sourcePortID){if(u=this.findInOutConnectPorts(g=this.nameTable[e.sourceID],!1),(!g||Ph(g)||""!==e.sourcePortID&&Td(u))&&(e.sourceWrapper=g?this.getEndNodeWrapper(g,e,!0):void 0,e.sourcePortID&&void 0===r.sourcePortID&&(e.sourcePortWrapper=g?this.getWrapper(g.wrapper,e.sourcePortID):void 0),this.removePortEdges(this.nameTable[i.sourceID]||g,i.sourcePortID||e.sourcePortID,e.id,!1)),void 0!==r.sourceID&&void 0!==i.sourceID&&""!==i.sourceID){var v=this.nameTable[i.sourceID];void 0!==v&&v.outEdges&&-1!==v.outEdges.indexOf(e.id)&&im(v.outEdges,e.id)}this.updateEdges(e)}if(void 0!==r.targetID&&r.targetID!==i.targetID){if(d=this.findInOutConnectPorts(y=this.nameTable[r.targetID],!0),(!y||ua(y)||""!==e.targetPortID&&kh(d))&&(e.targetWrapper=y?this.getEndNodeWrapper(y,e,!1):void 0,e.targetPortID&&void 0===r.targetPortID&&(e.targetPortWrapper=y?this.getWrapper(y.wrapper,e.targetPortID):void 0),this.removePortEdges(this.nameTable[i.targetID]||y,i.targetPortID||e.targetPortID,e.id,!0)),void 0!==i&&void 0!==i.targetID&&""!==i.targetID){var S=this.nameTable[i.targetID];void 0!==S&&S.inEdges&&-1!==S.inEdges.indexOf(e.id)&&im(S.inEdges,e.id)}this.updateEdges(e)}var g,y;void 0!==r.sourcePortID&&r.sourcePortID!==i.sourcePortID&&(e.sourceID&&this.nameTable[e.sourceID]&&(f=this.nameTable[e.sourceID].wrapper),!(g=this.nameTable[e.sourceID])||Ph(g)||""!==e.sourcePortID&&Td(u)?e.sourcePortWrapper=f?this.getWrapper(f,r.sourcePortID):void 0:""===e.sourcePortID&&!Ph(g)&&(e.sourcePortWrapper=void 0)),void 0!==r.targetPortID&&r.targetPortID!==i.targetPortID&&(e.targetID&&this.nameTable[e.targetID]&&(p=this.nameTable[e.targetID].wrapper),!(y=this.nameTable[e.targetID])||ua(y)||""!==e.targetPortID&&kh(d)?e.targetPortWrapper=p?this.getWrapper(p,r.targetPortID):void 0:""===e.targetPortID&&!ua(y)&&(e.targetPortWrapper=void 0)),void 0!==r.flip&&(e.flip=r.flip,SF(e)),"Orthogonal"===e.type&&this.lineRoutingModule&&this.diagramActions&&this.constraints&nt.LineRouting&&!(this.diagramActions&ee.ToolAction)&&"ComplexHierarchicalTree"!==this.layout.type&&(this.lineRoutingModule.renderVirtualRegion(this,!0),e.sourceID!==e.targetID&&e.segments.length>1&&this.lineRoutingModule.refreshConnectorSegments(this,e,!1)),c=this.getPoints(e)}void 0!==r.style&&zh(r.style,e.wrapper.children[0]),(c.length>0||void 0!==r.sourceDecorator||void 0!==r.targetDecorator&&function Bse(n){return-1!==n.indexOf("shape")||-1!==n.indexOf("pathData")||-1!==n.indexOf("width")||-1!==n.indexOf("height")}(Object.keys(r.targetDecorator))||void 0!==r.cornerRadius)&&(Jf(e,c.length>0?c:e.intermediatePoints,this.diagramActions),void 0!==r.type&&(h=!0),c.length>0&&(e.wrapper.measure(new me(e.wrapper.width,e.wrapper.height)),e.wrapper.arrange(e.wrapper.desiredSize),this.updateConnectorAnnotation(e),this.updateConnectorPort(e),this.updateConnectorfixedUserHandles(e),this.updateObject(e,i,r))),(r.sourcePoint||r.targetPoint||r.segments)&&this.diagramActions===ee.Render&&(h=!0),"Bpmn"===e.shape.type&&"Default"===e.shape.sequence&&"Sequence"===e.shape.flow&&this.commandHandler.updatePathElementOffset(e),s||this.updateBridging(),this.updateAnnotations(r,e),this.updateConnectorPorts(r,e),this.updatefixedUserHandle(r,e),e.wrapper.measure(new me(e.wrapper.width,e.wrapper.height)),e.wrapper.arrange(e.wrapper.desiredSize),!1===l.equals(l,e.wrapper.bounds)&&(this.updateQuad(e),"Drag"!==this.eventHandler.currentAction&&this.updateGroupSize(e)),!0===h&&this.checkSelectedItem(e)&&(!(this.diagramActions&ee.ToolAction)||this.diagramActions&ee.UndoRedo)&&this.updateSelector(),this.preventConnectorsUpdate||(!Ds(this)||Ds(this)&&this.scroller.oldCollectionObjects.indexOf(e.id)>-1)&&(this.diagramActions&ee.PreventZIndexOnDragging?this.updateDiagramObject(e,!0):this.updateDiagramObject(e)),this.updateConnectorEdges(e),this.diagramActions&&"New"!==e.status&&(e.status="Update"),this.triggerPropertyChange(o,e,i,r)},t.prototype.removePortEdges=function(e,i,r,s){if(e)for(var o=0;o0&&e.id===s[s.length-1].id&&(r=!0),r},t.prototype.updateDiagramContainerVisibility=function(e,i){if(e instanceof Cs)for(var r=0;r>"),r instanceof es&&this.updateAnnotationWrapper(r,s,o,a)),void 0!==e.template&&(r.content=e.template,this.updateAnnotationWrapper(r,s,o,a))},t.prototype.updateAnnotationWrapper=function(e,i,r,s){for(var o=0,a=this.views;o=0&&this.nodes.splice(s,1),delete this.nameTable[""+r]}var o=this.nodes.indexOf(this.nameTable[this.currentSymbol.id]);o>=0&&this.nodes.splice(o,1)}},t.prototype.selectDragedNode=function(e,i,r){this.currentSymbol=e,"SVG"!==this.mode&&this.refreshDiagramLayer(),this.commandHandler.oldSelectedObjects=nm(this),this.commandHandler.select(e),this.eventHandler.mouseDown(i.event),this.eventHandler.mouseMove(i.event,i),this.preventDiagramUpdate=!1,this.updatePage(),r.style.opacity="0"},t.prototype.initDroppables=function(){var s,o,e=this,i={},r={},a="selectedSymbols";this.droppable=new lR(this.element);var l=5;this.droppable.over=function(h){if(e.rulerSettings.showRulers){var c=document.getElementById(e.element.id+"_vRuler"),d=parseFloat(c.style.width);l=d+1}if(0===e.previousSelectedObjects.length&&!e.currentSymbol&&(e.previousSelectedObjects=e.commandHandler.getSelectedObject()),e.commandHandler.PreventConnectorSplit=!0,e.currentSymbol)h.event.touches&&h.event.touches.length&&e.eventHandler.mouseMove(h.event,h.event.touches);else{var u=null;if(!h.dragData&&"drag"===h.name){var f=document.getElementsByClassName("e-dragclone")[0];f&&(u=f)}if(h.dragData||u){var p=void 0,g=void 0;document.getElementById(e.element.id+"content").focus();var v=e.eventHandler.getMousePosition(h.event),y=void 0,S=u||h.dragData.helper,b=S.getAttribute("paletteId"),M=void 0,w=void 0,C=void 0,D=void 0;if(!b&&h.dragData){e.triggerEvent(Ce.dragEnter,A={source:null,element:p,cancel:!1,diagram:e,dragData:h.dragData.draggedElement.ej2_instances[0].dragData,dragItem:p});var x=void 0,P=void 0;if(A.dragItem){if(A.dragItem.sourcePoint&&A.dragItem.targetPoint?P=new de(e,"connectors",A.dragItem,!0):x=new te(e,"nodes",A.dragItem,!0),e.initObject(p=x||P,void 0,void 0,!0),e.enterObject=p,e.enterTable=r,p instanceof te)x.offsetX=v.x+5+x.width*x.pivot.x,x.offsetY=v.y+x.height*x.pivot.y;else if(p instanceof de){var L=Ne.toBounds([p.sourcePoint,p.targetPoint]),O=v.x-L.left,N=v.y-L.top;p.sourcePoint.x+=O,p.sourcePoint.y+=N,p.targetPoint.x+=O,p.targetPoint.y+=N}e.preventDiagramUpdate=!0,e.currentSymbol=p,"SVG"!==e.mode&&e.refreshDiagramLayer(),e.selectDragedNode(p,h,S),delete e.enterObject,delete e.enterTable,e.droppable[""+a]=S,e.allowServerDataBinding=!0}}if(b){var T=document.getElementById(b).ej2_instances[0];if(e.droppable.sourceElement=T,T){var B=T[""+a];e.allowServerDataBinding=!1,y=$(T[""+a]),i=T.childTable;var j=B.wrapper.children[0].children[0];if(D=function Fse(n,t,e){var i=wF(n,t,e,"width"),r=wF(n,t,e,"height");return new me(i,r)}(T,y,j),T[""+a]instanceof te){"TextAnnotation"===B.shape.shape?(y.offsetX=v.x+11+D.width*y.pivot.x,y.offsetY=v.y+11+D.height*y.pivot.y):(y.offsetX=v.x+5+D.width*y.pivot.x,y.offsetY=v.y+D.height*y.pivot.y),"Bpmn"===(x=new te(e,"nodes",y,!0)).shape.type&&x.shape.activity.subProcess.processes&&x.shape.activity.subProcess.processes.length&&(x.shape.activity.subProcess.processes=[]),w=x.previewSize,C=T.symbolDragSize;var Q=T.symbolPreview;if(x.width=(M=x.dragSize).width||C.width||w.width||Q.width||x.width,x.height=M.height||C.height||w.height||Q.height||x.height,"SwimLane"===x.shape.type){if(e.diagramActions|=ee.PreventHistory,x.shape.isLane){x.children=[],s={id:"header"+Qe()},"Horizontal"===x.shape.orientation?(s.width=x.shape.lanes[0].header.width,s.height=x.shape.lanes[0].height):(s.width=x.shape.lanes[0].width,s.height=x.shape.lanes[0].header.height),s.style=x.shape.lanes[0].header.style,s.offsetX=v.x+l+s.width/2,s.offsetY=v.y+s.height/2,e.diagramActions|=ee.PreventCollectionChangeOnDragOver,s=e.add(s),o={id:"body"+Qe()},"Horizontal"===x.shape.orientation?(o.width=x.shape.lanes[0].width-s.width,o.height=x.shape.lanes[0].height,o.offsetX=v.x+l+(x.shape.lanes[0].header.width+o.width/2),o.offsetY=v.y+o.height/2):(o.width=x.shape.lanes[0].width,o.height=x.shape.lanes[0].height-s.height,o.offsetX=v.x+l+o.width/2,o.offsetY=v.y+(x.shape.lanes[0].header.height+o.height/2)),o.style=x.shape.lanes[0].style,o=e.add(o);var oe={id:"group"+Qe(),children:[s.id,o.id]};oe.shape=x.shape,oe.width=x.shape.lanes[0].width,oe.height=x.shape.lanes[0].height,oe.previewSize=x.previewSize,oe.dragSize=x.dragSize,oe.addInfo=x.addInfo,x=e.add(oe),e.diagramActions&=~ee.PreventCollectionChangeOnDragOver}e.diagramActions&=~ee.PreventHistory}if(x.shape.isPhase&&((g="Horizontal"===x.shape.orientation)?(x.offsetX=v.x+l+(x.width||j.actualSize.width)/2,x.offsetY=v.y,x.shape.data="M20,"+x.height/2+" L"+(x.width-20)+","+x.height/2+"z",x.height=1):(x.offsetX=v.x+5,x.offsetY=v.y+(x.height||j.actualSize.height)/2,x.shape.data="M"+x.width/2+",20 L"+x.width/2+","+(x.height-20)+"z",x.width=1)),"UmlClassifier"===x.shape.type&&(x.children=x.width=x.height=void 0,y.children=void 0,"Class"===x.shape.classifier&&x.shape.classShape.methods.length<=0&&x.shape.classShape.attributes.length<=0&&(x.shape.classShape.attributes=[{name:"Name",type:"Type",style:{}}]),"Enumeration"===x.shape.classifier&&x.shape.enumerationShape.members.length<=0&&(x.shape.enumerationShape.members=[{name:"Name"}]),"Interface"===x.shape.classifier&&x.shape.interfaceShape.methods.length<=0&&x.shape.interfaceShape.attributes.length<=0&&(x.shape.interfaceShape.attributes=[{name:"Name",type:"Type",style:{}}])),p=x,y.children){var ue=y;r=e.getChildren(ue,{},i),eT(ue,-ue.offsetX,-ue.offsetY,r,!0,e)}}else if(T[""+a]instanceof de){p=new de(e,"connectors",y,!0);var Me=Ne.toBounds([p.sourcePoint,p.targetPoint]),De=v.x-Me.left,xe=v.y-Me.top;p.sourcePoint.x+=De,p.sourcePoint.y+=xe,p.targetPoint.x+=De,p.targetPoint.y+=xe}p.shape.isLane||(p.id+=Qe());var A={source:T,element:p,cancel:!1,diagram:e,dragData:null,dragItem:p};if(e.enterObject=p,e.enterTable=r,e.triggerEvent(Ce.dragEnter,A),p instanceof te&&"SwimLane"===p.shape.type&&p.shape.isLane){var Ie=A.element,Ve=Ie.shape.lanes[0];g="Horizontal"===Ie.shape.orientation;var ot=e.nameTable[p.children[0]],$e=e.nameTable[p.children[1]];w=p.previewSize,C=T.symbolDragSize,Ve.width=(M=p.dragSize).width||C.width||w.width||Ve.width,Ve.height=M.height||C.height||w.height||Ve.height,g?(s.width=Ve.header.width,s.height=Ve.height,o.width=Ve.width-s.width,o.height=Ve.height,o.offsetX=v.x+l+(Ve.header.width+$e.width/2),o.offsetY=v.y+$e.height/2):(s.width=Ve.width,s.height=Ve.header.height,o.width=Ve.width,o.height=Ve.height-s.height,o.offsetX=v.x+l+$e.width/2,o.offsetY=v.y+(Ve.header.height+$e.height/2)),s.offsetX=v.x+l+ot.width/2,s.offsetY=v.y+ot.height/2,p.width=Ve.width,p.height=Ve.height}if(p instanceof te&&p.shape.isPhase&&(g?p.height=1:p.width=1),!e.activeLayer.lock&&!A.cancel){if(e.preventDiagramUpdate=!0,p.children&&e.findChild(p,r),e.preventDiagramUpdate=!0,p.zIndex!==Number.MIN_VALUE&&(p.zIndex=Number.MIN_VALUE),e.initObject(p,void 0,void 0,!0),e.bpmnModule)for(var Ci=0;Ci0&&(S.segments=[]),d=this.add(S,!0)),(S||d)&&(_v(this)||Uv(this))&&this.select([this.nameTable[S[""+b]]],!1,this.previousSelectedObjects),y.target&&y.target instanceof de&&!0===this.enableConnectorSplit&&this.nameTable[S[""+b]]instanceof te&&(this.commandHandler.connectorSplit(this.nameTable[S[""+b]],y.target),this.commandHandler.PreventConnectorSplit=!1))),this.protectPropertyChange(!1),v=this.nameTable[S[""+b]],S.hasTarget&&(S.nodeId=S.hasTarget,this.remove(S)),this.bpmnModule&&v instanceof te&&S.processId&&(v.processId=S.processId,this.bpmnModule.dropBPMNchild(this.nameTable[v.processId],v,this)),y.cancel||this.endGroupAction(),"SVG"!==this.mode&&this.refreshDiagramLayer(),delete this.droppable[""+c]):(this.triggerEvent(Ce.drop,y={source:h.droppedElement,element:void 0,target:this.eventHandler.hoverNode||this.eventHandler.lastObjectUnderMouse||this,cancel:!1,position:void 0}),S=void 0,b="id"),this.droppable[M="selectedSymbols"]&&this.droppable[""+M].parentNode)gt(this.droppable[""+M]);else for(w=document.getElementsByClassName("e-dragclone"),C=0;C0)for(var f=0;f1),e.previousSelectedObject=null}}},t.prototype.getDropEventArgs=function(e){if(this.eventHandler.lastObjectUnderMouse||this.eventHandler.hoverNode){var i=this.eventHandler.lastObjectUnderMouse||this.eventHandler.hoverNode;e.target=ps(i)===de?{connector:i}:{node:i}}else e.target.diagramId=this.element.id},t.prototype.removeChildInNodes=function(e){if(e){if(e.children)for(var i=0;i1){var l=2;if(e.children&&e.children.length>0)for(;e.children.indexOf(i.objects[s-l])>-1;)l++;this.commandHandler.moveSvgNode(e.id,i.objects[s-l]),this.commandHandler.moveSvgNode(i.objects[s-l],e.id)}else if(o){var h=this.commandHandler.getLayer(this.layerZIndexTable[o.zIndex]).objects[0];h?(this.commandHandler.moveSvgNode(e.id,h),this.commandHandler.updateNativeNodeIndex(e.id,h)):this.moveObjectsUp(e,i)}else this.moveObjectsUp(e,i)},t.prototype.moveObjectsUp=function(e,i){for(var r,s=this.layers.length-1;s>=0;s--)if(r=this.layers[parseInt(s.toString(),10)],i.id!==r.id){var o=this.commandHandler.getLayer(this.layerZIndexTable[r.zIndex]).objects[r.objects.length-1];if(o){this.commandHandler.moveSvgNode(e.id,o),this.commandHandler.moveSvgNode(o,e.id);break}}},t.prototype.insertData=function(e){return this.crudOperation(e,"create",this.getNewUpdateNodes("New"))},t.prototype.updateData=function(e){return this.crudOperation(e,"update",this.getNewUpdateNodes("Update"))},t.prototype.removeData=function(e){return this.crudOperation(e,"destroy",this.getDeletedNodes())},t.prototype.crudOperation=function(e,i,r){if(e){var s=this.parameterMap(e,!(e instanceof de));if(s){var o=e instanceof de?this.dataSourceSettings.connectionDataSource.crudAction[""+i]:this.dataSourceSettings.crudAction[""+i];this.raiseAjaxPost(JSON.stringify(s),o)}return s}var a=r;return this.processCrudCollection(a,this.dataSourceSettings.crudAction[""+i],this.dataSourceSettings.connectionDataSource.crudAction[""+i]),a},t.prototype.processCrudCollection=function(e,i,r){if(e.nodes){var s=[],o=void 0;for(o=0;o0&&this.raiseAjaxPost(JSON.stringify(s),i)}if(e.connectors){for(s=[],o=void 0,o=0;o0&&this.raiseAjaxPost(JSON.stringify(s),r)}},t.prototype.parameterMap=function(e,i){var s,r={},o=i?this.dataSourceSettings:this.dataSourceSettings.connectionDataSource;if(o.id&&(r[o.id]=e.id),o.sourcePointX&&o.sourcePointY&&(r[o.sourcePointX]=e.sourcePoint.x,r[o.sourcePointY]=e.sourcePoint.y),o.targetPointX&&o.targetPointY&&(r[o.targetPointX]=e.targetPoint.x,r[o.targetPointY]=e.targetPoint.y),o.sourceID&&(r[o.sourceID]=e.sourceID),o.targetID&&(r[o.targetID]=e.targetID),o.crudAction&&o.crudAction.customFields&&o.crudAction.customFields.length>0)for(s=0;s"u"||(y.innerHTML=v.innerHTML?v.innerHTML:"",void 0!==v.className&&(y.className=v.className),void 0!==v.id&&(y.id=v.id),void 0!==v.styles&&y.setAttribute("style",v.styles),void 0!==e.ngAttr&&y.setAttribute(e.ngAttr,""),void 0!==v.attrs&&Fe(y,v.attrs)),y};for(var i=0,r=e.tags;i=0;a--)(o=n[a])&&(s=(r<3?o(s):r>3?o(t,e,s):o(t,e))||s);return r>3&&s&&Object.defineProperty(t,e,s),s}!function DZ(n){EC.compile=n.compile}({compile:function Fae(n,t){if("string"==typeof n||"function"==typeof n&&n.prototype&&n.prototype.CSPTemplate)return Bae(n,t);var e=n.elementRef.nativeElement._viewContainerRef,i=n.elementRef.nativeElement.propName;return function(r,s,o){var l=e||s.viewContainerRef,h=l.createEmbeddedView(n,{$implicit:r});/EJS-MENTION|EJS-DROPDOWNLIST/.test(Y("currentInstance.element.nodeName",l))||/E-TABITEM/.test(Y("element.nativeElement.nodeName",l))?h.detectChanges():h.markForCheck();var c=s&&s.registeredTemplate?s.registeredTemplate:Y("currentInstance.registeredTemplate",l);return typeof c["".concat(o=o&&s.registeredTemplate?o:i)]>"u"&&(c["".concat(o)]=[]),c["".concat(o)].push(h),h.rootNodes}}});const Wae=["annotationTemplate"],Yae=["nodeTemplate"],Qae=["userHandleTemplate"];let Gae=["addInfo","id","lock","objects","visible","zIndex"],Xae=[],qae=(()=>{class n extends Bh{constructor(e){super(),this.viewContainerRef=e,_l("currentInstance",this,this.viewContainerRef),this.registerEvents(Xae),this.directivePropList=Gae}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-layer"]],inputs:{addInfo:"addInfo",id:"id",lock:"lock",objects:"objects",visible:"visible",zIndex:"zIndex"},features:[yn]}),n})(),$ae=(()=>{class n extends Fh{constructor(){super("layers")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-layers"]],contentQueries:function(e,i,r){if(1&e&&dn(r,qae,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),Zae=["action","cursor"],Jae=[],Kae=(()=>{class n extends Bh{constructor(e){super(),this.viewContainerRef=e,_l("currentInstance",this,this.viewContainerRef),this.registerEvents(Jae),this.directivePropList=Zae}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-cursormap"]],inputs:{action:"action",cursor:"cursor"},features:[yn]}),n})(),ele=(()=>{class n extends Fh{constructor(){super("customcursor")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-cursormaps"]],contentQueries:function(e,i,r){if(1&e&&dn(r,Kae,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),tle=["alignment","cornerRadius","displacement","fill","handleStrokeColor","handleStrokeWidth","height","iconStrokeColor","iconStrokeWidth","id","offset","padding","pathData","tooltip","visibility","width"],ile=[],rle=(()=>{class n extends Bh{constructor(e){super(),this.viewContainerRef=e,_l("currentInstance",this,this.viewContainerRef),this.registerEvents(ile),this.directivePropList=tle}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-connector-fixeduserhandle"]],inputs:{alignment:"alignment",cornerRadius:"cornerRadius",displacement:"displacement",fill:"fill",handleStrokeColor:"handleStrokeColor",handleStrokeWidth:"handleStrokeWidth",height:"height",iconStrokeColor:"iconStrokeColor",iconStrokeWidth:"iconStrokeWidth",id:"id",offset:"offset",padding:"padding",pathData:"pathData",tooltip:"tooltip",visibility:"visibility",width:"width"},features:[yn]}),n})(),nle=(()=>{class n extends Fh{constructor(){super("fixeduserhandles")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-connector-fixeduserhandles"]],contentQueries:function(e,i,r){if(1&e&&dn(r,rle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),sle=["addInfo","alignment","annotationType","constraints","content","displacement","dragLimit","height","horizontalAlignment","hyperlink","id","margin","offset","rotateAngle","rotationReference","segmentAngle","style","template","tooltip","type","verticalAlignment","visibility","width"],ole=[],ale=(()=>{class n extends Bh{constructor(e){super(),this.viewContainerRef=e,_l("currentInstance",this,this.viewContainerRef),this.registerEvents(ole),this.directivePropList=sle}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-connector-annotation"]],inputs:{addInfo:"addInfo",alignment:"alignment",annotationType:"annotationType",constraints:"constraints",content:"content",displacement:"displacement",dragLimit:"dragLimit",height:"height",horizontalAlignment:"horizontalAlignment",hyperlink:"hyperlink",id:"id",margin:"margin",offset:"offset",rotateAngle:"rotateAngle",rotationReference:"rotationReference",segmentAngle:"segmentAngle",style:"style",template:"template",tooltip:"tooltip",type:"type",verticalAlignment:"verticalAlignment",visibility:"visibility",width:"width"},features:[yn]}),n})(),lle=(()=>{class n extends Fh{constructor(){super("annotations")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-connector-annotations"]],contentQueries:function(e,i,r){if(1&e&&dn(r,ale,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),hle=["addInfo","allowNodeOverlap","annotations","bezierSettings","bridgeSpace","connectionPadding","connectorSpacing","constraints","cornerRadius","dragSize","excludeFromLayout","fixedUserHandles","flip","flipMode","hitPadding","id","margin","maxSegmentThumb","ports","previewSize","segmentThumbShape","segmentThumbSize","segments","shape","sourceDecorator","sourceID","sourcePadding","sourcePoint","sourcePortID","style","symbolInfo","targetDecorator","targetID","targetPadding","targetPoint","targetPortID","tooltip","type","visible","wrapper","zIndex"],cle=[],dle=(()=>{class n extends Bh{constructor(e){super(),this.viewContainerRef=e,this.tags=["fixedUserHandles","annotations"],_l("currentInstance",this,this.viewContainerRef),this.registerEvents(cle),this.directivePropList=hle}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-connector"]],contentQueries:function(e,i,r){if(1&e&&(dn(r,nle,5),dn(r,lle,5)),2&e){let s;Kr(s=en())&&(i.childFixedUserHandles=s.first),Kr(s=en())&&(i.childAnnotations=s.first)}},inputs:{addInfo:"addInfo",allowNodeOverlap:"allowNodeOverlap",annotations:"annotations",bezierSettings:"bezierSettings",bridgeSpace:"bridgeSpace",connectionPadding:"connectionPadding",connectorSpacing:"connectorSpacing",constraints:"constraints",cornerRadius:"cornerRadius",dragSize:"dragSize",excludeFromLayout:"excludeFromLayout",fixedUserHandles:"fixedUserHandles",flip:"flip",flipMode:"flipMode",hitPadding:"hitPadding",id:"id",margin:"margin",maxSegmentThumb:"maxSegmentThumb",ports:"ports",previewSize:"previewSize",segmentThumbShape:"segmentThumbShape",segmentThumbSize:"segmentThumbSize",segments:"segments",shape:"shape",sourceDecorator:"sourceDecorator",sourceID:"sourceID",sourcePadding:"sourcePadding",sourcePoint:"sourcePoint",sourcePortID:"sourcePortID",style:"style",symbolInfo:"symbolInfo",targetDecorator:"targetDecorator",targetID:"targetID",targetPadding:"targetPadding",targetPoint:"targetPoint",targetPortID:"targetPortID",tooltip:"tooltip",type:"type",visible:"visible",wrapper:"wrapper",zIndex:"zIndex"},features:[yn]}),n})(),ule=(()=>{class n extends Fh{constructor(){super("connectors")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-connectors"]],contentQueries:function(e,i,r){if(1&e&&dn(r,dle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),fle=["cornerRadius","fill","handleStrokeColor","handleStrokeWidth","height","iconStrokeColor","iconStrokeWidth","id","margin","offset","padding","pathData","tooltip","visibility","width"],ple=[],gle=(()=>{class n extends Bh{constructor(e){super(),this.viewContainerRef=e,_l("currentInstance",this,this.viewContainerRef),this.registerEvents(ple),this.directivePropList=fle}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-node-fixeduserhandle"]],inputs:{cornerRadius:"cornerRadius",fill:"fill",handleStrokeColor:"handleStrokeColor",handleStrokeWidth:"handleStrokeWidth",height:"height",iconStrokeColor:"iconStrokeColor",iconStrokeWidth:"iconStrokeWidth",id:"id",margin:"margin",offset:"offset",padding:"padding",pathData:"pathData",tooltip:"tooltip",visibility:"visibility",width:"width"},features:[yn]}),n})(),vle=(()=>{class n extends Fh{constructor(){super("fixeduserhandles")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-node-fixeduserhandles"]],contentQueries:function(e,i,r){if(1&e&&dn(r,gle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),mle=["addInfo","annotationType","constraints","content","dragLimit","height","horizontalAlignment","hyperlink","id","margin","offset","rotateAngle","rotationReference","style","template","tooltip","type","verticalAlignment","visibility","width"],yle=[],Sle=(()=>{class n extends Bh{constructor(e){super(),this.viewContainerRef=e,_l("currentInstance",this,this.viewContainerRef),this.registerEvents(yle),this.directivePropList=mle}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-node-annotation"]],inputs:{addInfo:"addInfo",annotationType:"annotationType",constraints:"constraints",content:"content",dragLimit:"dragLimit",height:"height",horizontalAlignment:"horizontalAlignment",hyperlink:"hyperlink",id:"id",margin:"margin",offset:"offset",rotateAngle:"rotateAngle",rotationReference:"rotationReference",style:"style",template:"template",tooltip:"tooltip",type:"type",verticalAlignment:"verticalAlignment",visibility:"visibility",width:"width"},features:[yn]}),n})(),Ile=(()=>{class n extends Fh{constructor(){super("annotations")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-node-annotations"]],contentQueries:function(e,i,r){if(1&e&&dn(r,Sle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),ble=["addInfo","connectionDirection","constraints","height","horizontalAlignment","id","inEdges","margin","offset","outEdges","pathData","shape","style","tooltip","verticalAlignment","visibility","width"],Mle=[],wle=(()=>{class n extends Bh{constructor(e){super(),this.viewContainerRef=e,_l("currentInstance",this,this.viewContainerRef),this.registerEvents(Mle),this.directivePropList=ble}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-node-port"]],inputs:{addInfo:"addInfo",connectionDirection:"connectionDirection",constraints:"constraints",height:"height",horizontalAlignment:"horizontalAlignment",id:"id",inEdges:"inEdges",margin:"margin",offset:"offset",outEdges:"outEdges",pathData:"pathData",shape:"shape",style:"style",tooltip:"tooltip",verticalAlignment:"verticalAlignment",visibility:"visibility",width:"width"},features:[yn]}),n})(),Cle=(()=>{class n extends Fh{constructor(){super("ports")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-node-ports"]],contentQueries:function(e,i,r){if(1&e&&dn(r,wle,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})(),Ele=["addInfo","annotations","backgroundColor","borderColor","borderWidth","branch","children","collapseIcon","columnIndex","columnSpan","columns","constraints","container","data","dragSize","excludeFromLayout","expandIcon","fixedUserHandles","flip","flipMode","height","horizontalAlignment","id","isExpanded","layoutInfo","margin","maxHeight","maxWidth","minHeight","minWidth","offsetX","offsetY","padding","pivot","ports","previewSize","rotateAngle","rowIndex","rowSpan","rows","shadow","shape","style","symbolInfo","tooltip","verticalAlignment","visible","width","wrapper","zIndex"],Dle=[],v_=(()=>{class n extends Bh{constructor(e){super(),this.viewContainerRef=e,this.tags=["fixedUserHandles","annotations","ports"],_l("currentInstance",this,this.viewContainerRef),this.registerEvents(Dle),this.directivePropList=Ele}}return n.\u0275fac=function(e){return new(e||n)(Ot(An))},n.\u0275dir=nr({type:n,selectors:[["e-node"]],contentQueries:function(e,i,r){if(1&e&&(dn(r,vle,5),dn(r,Ile,5),dn(r,Cle,5)),2&e){let s;Kr(s=en())&&(i.childFixedUserHandles=s.first),Kr(s=en())&&(i.childAnnotations=s.first),Kr(s=en())&&(i.childPorts=s.first)}},inputs:{addInfo:"addInfo",annotations:"annotations",backgroundColor:"backgroundColor",borderColor:"borderColor",borderWidth:"borderWidth",branch:"branch",children:"children",collapseIcon:"collapseIcon",columnIndex:"columnIndex",columnSpan:"columnSpan",columns:"columns",constraints:"constraints",container:"container",data:"data",dragSize:"dragSize",excludeFromLayout:"excludeFromLayout",expandIcon:"expandIcon",fixedUserHandles:"fixedUserHandles",flip:"flip",flipMode:"flipMode",height:"height",horizontalAlignment:"horizontalAlignment",id:"id",isExpanded:"isExpanded",layoutInfo:"layoutInfo",margin:"margin",maxHeight:"maxHeight",maxWidth:"maxWidth",minHeight:"minHeight",minWidth:"minWidth",offsetX:"offsetX",offsetY:"offsetY",padding:"padding",pivot:"pivot",ports:"ports",previewSize:"previewSize",rotateAngle:"rotateAngle",rowIndex:"rowIndex",rowSpan:"rowSpan",rows:"rows",shadow:"shadow",shape:"shape",style:"style",symbolInfo:"symbolInfo",tooltip:"tooltip",verticalAlignment:"verticalAlignment",visible:"visible",width:"width",wrapper:"wrapper",zIndex:"zIndex"},features:[yn]}),n})(),m_=(()=>{class n extends Fh{constructor(){super("nodes")}}return n.\u0275fac=function(e){return new(e||n)},n.\u0275dir=nr({type:n,selectors:[["e-nodes"]],contentQueries:function(e,i,r){if(1&e&&dn(r,v_,4),2&e){let s;Kr(s=en())&&(i.children=s)}},features:[yn]}),n})();const xle=["animationComplete","click","collectionChange","commandExecute","connectionChange","contextMenuBeforeItemRender","contextMenuClick","contextMenuOpen","created","dataLoaded","doubleClick","dragEnter","dragLeave","dragOver","drop","elementDraw","expandStateChange","fixedUserHandleClick","historyChange","historyStateChange","keyDown","keyUp","load","loaded","mouseEnter","mouseLeave","mouseOver","mouseWheel","onFixedUserHandleMouseDown","onFixedUserHandleMouseEnter","onFixedUserHandleMouseLeave","onFixedUserHandleMouseUp","onImageLoad","onUserHandleMouseDown","onUserHandleMouseEnter","onUserHandleMouseLeave","onUserHandleMouseUp","positionChange","propertyChange","rotateChange","scrollChange","segmentChange","segmentCollectionChange","selectionChange","sizeChange","sourcePointChange","targetPointChange","textEdit"],Tle=[""];let Ale=(()=>{let n=class extends Fl{constructor(e,i,r,s){super(),this.ngEle=e,this.srenderer=i,this.viewContainerRef=r,this.injector=s,this.tags=["layers","customCursor","connectors","nodes"],this.element=this.ngEle.nativeElement,this.injectedModules=this.injectedModules||[];try{let o=this.injector.get("DiagramsHierarchicalTree");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsMindMap");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsRadialTree");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsComplexHierarchicalTree");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsDataBinding");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsSnapping");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsPrintAndExport");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsBpmnDiagrams");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsSymmetricLayout");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsConnectorBridging");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsUndoRedo");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsLayoutAnimation");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsDiagramContextMenu");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsLineRouting");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsConnectorEditing");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsLineDistribution");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsEj1Serialization");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}try{let o=this.injector.get("DiagramsFlowchartLayout");-1===this.injectedModules.indexOf(o)&&this.injectedModules.push(o)}catch{}this.registerEvents(xle),this.addTwoWay.call(this,Tle),_l("currentInstance",this,this.viewContainerRef),this.context=new u_}ngOnInit(){this.context.ngOnInit(this)}ngAfterViewInit(){this.context.ngAfterViewInit(this)}ngOnDestroy(){this.context.ngOnDestroy(this)}ngAfterContentChecked(){this.tagObjects[0].instance=this.childLayers,this.childCustomCursor&&(this.tagObjects[1].instance=this.childCustomCursor),this.childConnectors&&(this.tagObjects[2].instance=this.childConnectors),this.childNodes&&(this.tagObjects[3].instance=this.childNodes),this.context.ngAfterContentChecked(this)}};return n.\u0275fac=function(e){return new(e||n)(Ot($c),Ot(aM),Ot(An),Ot(Wo))},n.\u0275cmp=Hb({type:n,selectors:[["ejs-diagram"]],contentQueries:function(e,i,r){if(1&e&&(dn(r,Wae,5),dn(r,Yae,5),dn(r,Qae,5),dn(r,$ae,5),dn(r,ele,5),dn(r,ule,5),dn(r,m_,5)),2&e){let s;Kr(s=en())&&(i.annotationTemplate=s.first),Kr(s=en())&&(i.nodeTemplate=s.first),Kr(s=en())&&(i.userHandleTemplate=s.first),Kr(s=en())&&(i.childLayers=s.first),Kr(s=en())&&(i.childCustomCursor=s.first),Kr(s=en())&&(i.childConnectors=s.first),Kr(s=en())&&(i.childNodes=s.first)}},inputs:{addInfo:"addInfo",annotationTemplate:"annotationTemplate",backgroundColor:"backgroundColor",bridgeDirection:"bridgeDirection",commandManager:"commandManager",connectorDefaults:"connectorDefaults",connectors:"connectors",constraints:"constraints",contextMenuSettings:"contextMenuSettings",customCursor:"customCursor",dataSourceSettings:"dataSourceSettings",diagramSettings:"diagramSettings",drawingObject:"drawingObject",enableConnectorSplit:"enableConnectorSplit",enablePersistence:"enablePersistence",enableRtl:"enableRtl",fixedUserHandleTemplate:"fixedUserHandleTemplate",getConnectorDefaults:"getConnectorDefaults",getCustomCursor:"getCustomCursor",getCustomProperty:"getCustomProperty",getCustomTool:"getCustomTool",getDescription:"getDescription",getNodeDefaults:"getNodeDefaults",height:"height",historyManager:"historyManager",layers:"layers",layout:"layout",locale:"locale",mode:"mode",nodeDefaults:"nodeDefaults",nodeTemplate:"nodeTemplate",nodes:"nodes",pageSettings:"pageSettings",rulerSettings:"rulerSettings",scrollSettings:"scrollSettings",segmentThumbShape:"segmentThumbShape",segmentThumbSize:"segmentThumbSize",selectedItems:"selectedItems",serializationSettings:"serializationSettings",setNodeTemplate:"setNodeTemplate",snapSettings:"snapSettings",tool:"tool",tooltip:"tooltip",updateSelection:"updateSelection",userHandleTemplate:"userHandleTemplate",width:"width"},outputs:{animationComplete:"animationComplete",click:"click",collectionChange:"collectionChange",commandExecute:"commandExecute",connectionChange:"connectionChange",contextMenuBeforeItemRender:"contextMenuBeforeItemRender",contextMenuClick:"contextMenuClick",contextMenuOpen:"contextMenuOpen",created:"created",dataLoaded:"dataLoaded",doubleClick:"doubleClick",dragEnter:"dragEnter",dragLeave:"dragLeave",dragOver:"dragOver",drop:"drop",elementDraw:"elementDraw",expandStateChange:"expandStateChange",fixedUserHandleClick:"fixedUserHandleClick",historyChange:"historyChange",historyStateChange:"historyStateChange",keyDown:"keyDown",keyUp:"keyUp",load:"load",loaded:"loaded",mouseEnter:"mouseEnter",mouseLeave:"mouseLeave",mouseOver:"mouseOver",mouseWheel:"mouseWheel",onFixedUserHandleMouseDown:"onFixedUserHandleMouseDown",onFixedUserHandleMouseEnter:"onFixedUserHandleMouseEnter",onFixedUserHandleMouseLeave:"onFixedUserHandleMouseLeave",onFixedUserHandleMouseUp:"onFixedUserHandleMouseUp",onImageLoad:"onImageLoad",onUserHandleMouseDown:"onUserHandleMouseDown",onUserHandleMouseEnter:"onUserHandleMouseEnter",onUserHandleMouseLeave:"onUserHandleMouseLeave",onUserHandleMouseUp:"onUserHandleMouseUp",positionChange:"positionChange",propertyChange:"propertyChange",rotateChange:"rotateChange",scrollChange:"scrollChange",segmentChange:"segmentChange",segmentCollectionChange:"segmentCollectionChange",selectionChange:"selectionChange",sizeChange:"sizeChange",sourcePointChange:"sourcePointChange",targetPointChange:"targetPointChange",textEdit:"textEdit"},features:[yn],decls:0,vars:0,template:function(e,i){},encapsulation:2,changeDetection:0}),fb([TT()],n.prototype,"annotationTemplate",void 0),fb([TT()],n.prototype,"nodeTemplate",void 0),fb([TT()],n.prototype,"userHandleTemplate",void 0),n=fb([Rae([u_])],n),n})(),Lle=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=Lm({type:n}),n.\u0275inj=gp({imports:[[rq]]}),n})();const Nle=["diagram"];let Ole=(()=>{class n{constructor(){this.ports=[{id:"port1",offset:{x:0,y:.5},visibility:Gt.Visible},{id:"port2",offset:{x:1,y:.5},visibility:Gt.Visible},{id:"port3",offset:{x:.5,y:0},visibility:Gt.Visible},{id:"port4",offset:{x:.5,y:1},visibility:Gt.Visible}]}removePorts(){this.diagram.removePorts(this.diagram.nodes[0],this.ports)}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275cmp=Hb({type:n,selectors:[["app-container"]],viewQuery:function(i,r){if(1&i&&function uP(n,t,e){const i=Ti();i.firstCreatePass&&(cP(i,new aP(n,t,e),-1),2==(2&t)&&(i.staticViewQueries=!0)),hP(i,Se(),t)}(Nle,5),2&i){let s;Kr(s=en())&&(r.diagram=s.first)}},standalone:!0,features:[PP([]),RP],decls:6,vars:5,consts:[[3,"click"],["id","diagram","width","100%","height","580px"],["diagram",""],["id","node1",3,"offsetX","offsetY","width","height","ports"]],template:function(i,r){1&i&&(lg(0,"button",0),aw("click",function(){return r.removePorts()}),function MP(n,t=""){const e=Se(),i=Ti(),r=n+jt,s=i.firstCreatePass?Tu(i,r,1,t,null):i.data[r],o=wP(i,e,s,t,n);e[r]=o,Hm()&&hy(i,e,o,s),ll(s,!1)}(1,"Remove Ports"),hg(),lg(2,"ejs-diagram",1,2)(4,"e-nodes"),tw(5,"e-node",3),hg()()),2&i&&(function CN(n=1){EN(Ti(),Se(),zs()+n,!1)}(5),XM("offsetX",250)("offsetY",250)("width",100)("height",100)("ports",r.ports))},dependencies:[Lle,Ale,v_,m_],encapsulation:2})}}return n})();jd(332),function Xq(n,t){return CG({rootComponent:n,...Ez(t)})}(Ole).catch(n=>console.error(n))},332:()=>{!function(Z){const se=Z.performance;function ye(zi){se&&se.mark&&se.mark(zi)}function pe(zi,ht){se&&se.measure&&se.measure(zi,ht)}ye("Zone");const be=Z.__Zone_symbol_prefix||"__zone_symbol__";function ke(zi){return be+zi}const at=!0===Z[ke("forceDuplicateZoneCheck")];if(Z.Zone){if(at||"function"!=typeof Z.Zone.__symbol__)throw new Error("Zone already loaded.");return Z.Zone}let tt=(()=>{class zi{static{this.__symbol__=ke}static assertZonePatched(){if(Z.Promise!==_o.ZoneAwarePromise)throw new Error("Zone.js has detected that ZoneAwarePromise `(window|global).Promise` has been overwritten.\nMost likely cause is that a Promise polyfill has been loaded after Zone.js (Polyfilling Promise api is not necessary when zone.js is loaded. If you must load one, do so before loading zone.js.)")}static get root(){let F=zi.current;for(;F.parent;)F=F.parent;return F}static get current(){return Ur.zone}static get currentTask(){return Do}static __load_patch(F,ae,Et=!1){if(_o.hasOwnProperty(F)){if(!Et&&at)throw Error("Already loaded patch: "+F)}else if(!Z["__Zone_disable_"+F]){const qt="Zone:"+F;ye(qt),_o[F]=ae(Z,zi,cn),pe(qt,qt)}}get parent(){return this._parent}get name(){return this._name}constructor(F,ae){this._parent=F,this._name=ae?ae.name||"unnamed":"",this._properties=ae&&ae.properties||{},this._zoneDelegate=new Lt(this,this._parent&&this._parent._zoneDelegate,ae)}get(F){const ae=this.getZoneWith(F);if(ae)return ae._properties[F]}getZoneWith(F){let ae=this;for(;ae;){if(ae._properties.hasOwnProperty(F))return ae;ae=ae._parent}return null}fork(F){if(!F)throw new Error("ZoneSpec required!");return this._zoneDelegate.fork(this,F)}wrap(F,ae){if("function"!=typeof F)throw new Error("Expecting function got: "+F);const Et=this._zoneDelegate.intercept(this,F,ae),qt=this;return function(){return qt.runGuarded(Et,this,arguments,ae)}}run(F,ae,Et,qt){Ur={parent:Ur,zone:this};try{return this._zoneDelegate.invoke(this,F,ae,Et,qt)}finally{Ur=Ur.parent}}runGuarded(F,ae=null,Et,qt){Ur={parent:Ur,zone:this};try{try{return this._zoneDelegate.invoke(this,F,ae,Et,qt)}catch(Vn){if(this._zoneDelegate.handleError(this,Vn))throw Vn}}finally{Ur=Ur.parent}}runTask(F,ae,Et){if(F.zone!=this)throw new Error("A task can only be run in the zone of creation! (Creation: "+(F.zone||jn).name+"; Execution: "+this.name+")");if(F.state===sr&&(F.type===rs||F.type===Pt))return;const qt=F.state!=lt;qt&&F._transitionTo(lt,Pi),F.runCount++;const Vn=Do;Do=F,Ur={parent:Ur,zone:this};try{F.type==Pt&&F.data&&!F.data.isPeriodic&&(F.cancelFn=void 0);try{return this._zoneDelegate.invokeTask(this,F,ae,Et)}catch(Ue){if(this._zoneDelegate.handleError(this,Ue))throw Ue}}finally{F.state!==sr&&F.state!==et&&(F.type==rs||F.data&&F.data.isPeriodic?qt&&F._transitionTo(Pi,lt):(F.runCount=0,this._updateTaskCount(F,-1),qt&&F._transitionTo(sr,lt,sr))),Ur=Ur.parent,Do=Vn}}scheduleTask(F){if(F.zone&&F.zone!==this){let Et=this;for(;Et;){if(Et===F.zone)throw Error(`can not reschedule task to ${this.name} which is descendants of the original zone ${F.zone.name}`);Et=Et.parent}}F._transitionTo(Zr,sr);const ae=[];F._zoneDelegates=ae,F._zone=this;try{F=this._zoneDelegate.scheduleTask(this,F)}catch(Et){throw F._transitionTo(et,Zr,sr),this._zoneDelegate.handleError(this,Et),Et}return F._zoneDelegates===ae&&this._updateTaskCount(F,1),F.state==Zr&&F._transitionTo(Pi,Zr),F}scheduleMicroTask(F,ae,Et,qt){return this.scheduleTask(new pt(yi,F,ae,Et,qt,void 0))}scheduleMacroTask(F,ae,Et,qt,Vn){return this.scheduleTask(new pt(Pt,F,ae,Et,qt,Vn))}scheduleEventTask(F,ae,Et,qt,Vn){return this.scheduleTask(new pt(rs,F,ae,Et,qt,Vn))}cancelTask(F){if(F.zone!=this)throw new Error("A task can only be cancelled in the zone of creation! (Creation: "+(F.zone||jn).name+"; Execution: "+this.name+")");if(F.state===Pi||F.state===lt){F._transitionTo(dr,Pi,lt);try{this._zoneDelegate.cancelTask(this,F)}catch(ae){throw F._transitionTo(et,dr),this._zoneDelegate.handleError(this,ae),ae}return this._updateTaskCount(F,-1),F._transitionTo(sr,dr),F.runCount=0,F}}_updateTaskCount(F,ae){const Et=F._zoneDelegates;-1==ae&&(F._zoneDelegates=null);for(let qt=0;qtzi.hasTask(F,ae),onScheduleTask:(zi,ht,F,ae)=>zi.scheduleTask(F,ae),onInvokeTask:(zi,ht,F,ae,Et,qt)=>zi.invokeTask(F,ae,Et,qt),onCancelTask:(zi,ht,F,ae)=>zi.cancelTask(F,ae)};class Lt{constructor(ht,F,ae){this._taskCounts={microTask:0,macroTask:0,eventTask:0},this.zone=ht,this._parentDelegate=F,this._forkZS=ae&&(ae&&ae.onFork?ae:F._forkZS),this._forkDlgt=ae&&(ae.onFork?F:F._forkDlgt),this._forkCurrZone=ae&&(ae.onFork?this.zone:F._forkCurrZone),this._interceptZS=ae&&(ae.onIntercept?ae:F._interceptZS),this._interceptDlgt=ae&&(ae.onIntercept?F:F._interceptDlgt),this._interceptCurrZone=ae&&(ae.onIntercept?this.zone:F._interceptCurrZone),this._invokeZS=ae&&(ae.onInvoke?ae:F._invokeZS),this._invokeDlgt=ae&&(ae.onInvoke?F:F._invokeDlgt),this._invokeCurrZone=ae&&(ae.onInvoke?this.zone:F._invokeCurrZone),this._handleErrorZS=ae&&(ae.onHandleError?ae:F._handleErrorZS),this._handleErrorDlgt=ae&&(ae.onHandleError?F:F._handleErrorDlgt),this._handleErrorCurrZone=ae&&(ae.onHandleError?this.zone:F._handleErrorCurrZone),this._scheduleTaskZS=ae&&(ae.onScheduleTask?ae:F._scheduleTaskZS),this._scheduleTaskDlgt=ae&&(ae.onScheduleTask?F:F._scheduleTaskDlgt),this._scheduleTaskCurrZone=ae&&(ae.onScheduleTask?this.zone:F._scheduleTaskCurrZone),this._invokeTaskZS=ae&&(ae.onInvokeTask?ae:F._invokeTaskZS),this._invokeTaskDlgt=ae&&(ae.onInvokeTask?F:F._invokeTaskDlgt),this._invokeTaskCurrZone=ae&&(ae.onInvokeTask?this.zone:F._invokeTaskCurrZone),this._cancelTaskZS=ae&&(ae.onCancelTask?ae:F._cancelTaskZS),this._cancelTaskDlgt=ae&&(ae.onCancelTask?F:F._cancelTaskDlgt),this._cancelTaskCurrZone=ae&&(ae.onCancelTask?this.zone:F._cancelTaskCurrZone),this._hasTaskZS=null,this._hasTaskDlgt=null,this._hasTaskDlgtOwner=null,this._hasTaskCurrZone=null;const Et=ae&&ae.onHasTask;(Et||F&&F._hasTaskZS)&&(this._hasTaskZS=Et?ae:At,this._hasTaskDlgt=F,this._hasTaskDlgtOwner=this,this._hasTaskCurrZone=ht,ae.onScheduleTask||(this._scheduleTaskZS=At,this._scheduleTaskDlgt=F,this._scheduleTaskCurrZone=this.zone),ae.onInvokeTask||(this._invokeTaskZS=At,this._invokeTaskDlgt=F,this._invokeTaskCurrZone=this.zone),ae.onCancelTask||(this._cancelTaskZS=At,this._cancelTaskDlgt=F,this._cancelTaskCurrZone=this.zone))}fork(ht,F){return this._forkZS?this._forkZS.onFork(this._forkDlgt,this.zone,ht,F):new tt(ht,F)}intercept(ht,F,ae){return this._interceptZS?this._interceptZS.onIntercept(this._interceptDlgt,this._interceptCurrZone,ht,F,ae):F}invoke(ht,F,ae,Et,qt){return this._invokeZS?this._invokeZS.onInvoke(this._invokeDlgt,this._invokeCurrZone,ht,F,ae,Et,qt):F.apply(ae,Et)}handleError(ht,F){return!this._handleErrorZS||this._handleErrorZS.onHandleError(this._handleErrorDlgt,this._handleErrorCurrZone,ht,F)}scheduleTask(ht,F){let ae=F;if(this._scheduleTaskZS)this._hasTaskZS&&ae._zoneDelegates.push(this._hasTaskDlgtOwner),ae=this._scheduleTaskZS.onScheduleTask(this._scheduleTaskDlgt,this._scheduleTaskCurrZone,ht,F),ae||(ae=F);else if(F.scheduleFn)F.scheduleFn(F);else{if(F.type!=yi)throw new Error("Task is missing scheduleFn.");Wt(F)}return ae}invokeTask(ht,F,ae,Et){return this._invokeTaskZS?this._invokeTaskZS.onInvokeTask(this._invokeTaskDlgt,this._invokeTaskCurrZone,ht,F,ae,Et):F.callback.apply(ae,Et)}cancelTask(ht,F){let ae;if(this._cancelTaskZS)ae=this._cancelTaskZS.onCancelTask(this._cancelTaskDlgt,this._cancelTaskCurrZone,ht,F);else{if(!F.cancelFn)throw Error("Task is not cancelable");ae=F.cancelFn(F)}return ae}hasTask(ht,F){try{this._hasTaskZS&&this._hasTaskZS.onHasTask(this._hasTaskDlgt,this._hasTaskCurrZone,ht,F)}catch(ae){this.handleError(ht,ae)}}_updateTaskCount(ht,F){const ae=this._taskCounts,Et=ae[ht],qt=ae[ht]=Et+F;if(qt<0)throw new Error("More tasks executed then were scheduled.");0!=Et&&0!=qt||this.hasTask(this.zone,{microTask:ae.microTask>0,macroTask:ae.macroTask>0,eventTask:ae.eventTask>0,change:ht})}}class pt{constructor(ht,F,ae,Et,qt,Vn){if(this._zone=null,this.runCount=0,this._zoneDelegates=null,this._state="notScheduled",this.type=ht,this.source=F,this.data=Et,this.scheduleFn=qt,this.cancelFn=Vn,!ae)throw new Error("callback is not defined");this.callback=ae;const Ue=this;this.invoke=ht===rs&&Et&&Et.useG?pt.invokeTask:function(){return pt.invokeTask.call(Z,Ue,this,arguments)}}static invokeTask(ht,F,ae){ht||(ht=this),Ls++;try{return ht.runCount++,ht.zone.runTask(ht,F,ae)}finally{1==Ls&&ct(),Ls--}}get zone(){return this._zone}get state(){return this._state}cancelScheduleRequest(){this._transitionTo(sr,Zr)}_transitionTo(ht,F,ae){if(this._state!==F&&this._state!==ae)throw new Error(`${this.type} '${this.source}': can not transition to '${ht}', expecting state '${F}'${ae?" or '"+ae+"'":""}, was '${this._state}'.`);this._state=ht,ht==sr&&(this._zoneDelegates=null)}toString(){return this.data&&typeof this.data.handleId<"u"?this.data.handleId.toString():Object.prototype.toString.call(this)}toJSON(){return{type:this.type,state:this.state,source:this.source,zone:this.zone.name,runCount:this.runCount}}}const Di=ke("setTimeout"),si=ke("Promise"),mi=ke("then");let is,cr=[],ki=!1;function Pr(zi){if(is||Z[si]&&(is=Z[si].resolve(0)),is){let ht=is[mi];ht||(ht=is.then),ht.call(is,zi)}else Z[Di](zi,0)}function Wt(zi){0===Ls&&0===cr.length&&Pr(ct),zi&&cr.push(zi)}function ct(){if(!ki){for(ki=!0;cr.length;){const zi=cr;cr=[];for(let ht=0;htUr,onUnhandledError:jr,microtaskDrainDone:jr,scheduleMicroTask:Wt,showUncaughtError:()=>!tt[ke("ignoreConsoleErrorUncaughtError")],patchEventTarget:()=>[],patchOnProperties:jr,patchMethod:()=>jr,bindArguments:()=>[],patchThen:()=>jr,patchMacroTask:()=>jr,patchEventPrototype:()=>jr,isIEOrEdge:()=>!1,getGlobalObjects:()=>{},ObjectDefineProperty:()=>jr,ObjectGetOwnPropertyDescriptor:()=>{},ObjectCreate:()=>{},ArraySlice:()=>[],patchClass:()=>jr,wrapWithCurrentZone:()=>jr,filterProperties:()=>[],attachOriginToPatched:()=>jr,_redefineProperty:()=>jr,patchCallbacks:()=>jr,nativeScheduleMicroTask:Pr};let Ur={parent:null,zone:new tt(null,null)},Do=null,Ls=0;function jr(){}pe("Zone","Zone"),Z.Zone=tt}(globalThis);const Wl=Object.getOwnPropertyDescriptor,Ud=Object.defineProperty,jd=Object.getPrototypeOf,Vd=Object.create,vb=Array.prototype.slice,pm="addEventListener",$r="removeEventListener",Yl=Zone.__symbol__(pm),_h=Zone.__symbol__($r),Ts="true",Wi="false",Wd=Zone.__symbol__("");function op(Z,se){return Zone.current.wrap(Z,se)}function gm(Z,se,ye,pe,be){return Zone.current.scheduleMacroTask(Z,se,ye,pe,be)}const Ji=Zone.__symbol__,Uh=typeof window<"u",jh=Uh?window:void 0,gn=Uh&&jh||globalThis,vm="removeAttribute";function Yd(Z,se){for(let ye=Z.length-1;ye>=0;ye--)"function"==typeof Z[ye]&&(Z[ye]=op(Z[ye],se+"_"+ye));return Z}function ap(Z){return!Z||!1!==Z.writable&&!("function"==typeof Z.get&&typeof Z.set>"u")}const lp=typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope,Vh=!("nw"in gn)&&typeof gn.process<"u"&&"[object process]"==={}.toString.call(gn.process),Qd=!Vh&&!lp&&!(!Uh||!jh.HTMLElement),hp=typeof gn.process<"u"&&"[object process]"==={}.toString.call(gn.process)&&!lp&&!(!Uh||!jh.HTMLElement),Ql={},Wh=function(Z){if(!(Z=Z||gn.event))return;let se=Ql[Z.type];se||(se=Ql[Z.type]=Ji("ON_PROPERTY"+Z.type));const ye=this||Z.target||gn,pe=ye[se];let be;return Qd&&ye===jh&&"error"===Z.type?(be=pe&&pe.call(this,Z.message,Z.filename,Z.lineno,Z.colno,Z.error),!0===be&&Z.preventDefault()):(be=pe&&pe.apply(this,arguments),null!=be&&!be&&Z.preventDefault()),be};function Gl(Z,se,ye){let pe=Wl(Z,se);if(!pe&&ye&&Wl(ye,se)&&(pe={enumerable:!0,configurable:!0}),!pe||!pe.configurable)return;const be=Ji("on"+se+"patched");if(Z.hasOwnProperty(be)&&Z[be])return;delete pe.writable,delete pe.value;const ke=pe.get,at=pe.set,tt=se.slice(2);let At=Ql[tt];At||(At=Ql[tt]=Ji("ON_PROPERTY"+tt)),pe.set=function(Lt){let pt=this;!pt&&Z===gn&&(pt=gn),pt&&("function"==typeof pt[At]&&pt.removeEventListener(tt,Wh),at&&at.call(pt,null),pt[At]=Lt,"function"==typeof Lt&&pt.addEventListener(tt,Wh,!1))},pe.get=function(){let Lt=this;if(!Lt&&Z===gn&&(Lt=gn),!Lt)return null;const pt=Lt[At];if(pt)return pt;if(ke){let Di=ke.call(this);if(Di)return pe.set.call(this,Di),"function"==typeof Lt[vm]&&Lt.removeAttribute(se),Di}return null},Ud(Z,se,pe),Z[be]=!0}function cp(Z,se,ye){if(se)for(let pe=0;pefunction(at,tt){const At=ye(at,tt);return At.cbIdx>=0&&"function"==typeof tt[At.cbIdx]?gm(At.name,tt[At.cbIdx],At,be):ke.apply(at,tt)})}function Ia(Z,se){Z[Ji("OriginalDelegate")]=se}let yb=!1,Xd=!1;function Sb(){if(yb)return Xd;yb=!0;try{const Z=jh.navigator.userAgent;(-1!==Z.indexOf("MSIE ")||-1!==Z.indexOf("Trident/")||-1!==Z.indexOf("Edge/"))&&(Xd=!0)}catch{}return Xd}Zone.__load_patch("ZoneAwarePromise",(Z,se,ye)=>{const pe=Object.getOwnPropertyDescriptor,be=Object.defineProperty,at=ye.symbol,tt=[],At=!1!==Z[at("DISABLE_WRAPPING_UNCAUGHT_PROMISE_REJECTION")],Lt=at("Promise"),pt=at("then"),Di="__creationTrace__";ye.onUnhandledError=Ue=>{if(ye.showUncaughtError()){const He=Ue&&Ue.rejection;He?console.error("Unhandled Promise rejection:",He instanceof Error?He.message:He,"; Zone:",Ue.zone.name,"; Task:",Ue.task&&Ue.task.source,"; Value:",He,He instanceof Error?He.stack:void 0):console.error(Ue)}},ye.microtaskDrainDone=()=>{for(;tt.length;){const Ue=tt.shift();try{Ue.zone.runGuarded(()=>{throw Ue.throwOriginal?Ue.rejection:Ue})}catch(He){mi(He)}}};const si=at("unhandledPromiseRejectionHandler");function mi(Ue){ye.onUnhandledError(Ue);try{const He=se[si];"function"==typeof He&&He.call(this,Ue)}catch{}}function cr(Ue){return Ue&&Ue.then}function ki(Ue){return Ue}function is(Ue){return F.reject(Ue)}const Pr=at("state"),Wt=at("value"),ct=at("finally"),jn=at("parentPromiseValue"),sr=at("parentPromiseState"),Zr="Promise.then",Pi=null,lt=!0,dr=!1,et=0;function yi(Ue,He){return ge=>{try{cn(Ue,He,ge)}catch(We){cn(Ue,!1,We)}}}const Pt=function(){let Ue=!1;return function(ge){return function(){Ue||(Ue=!0,ge.apply(null,arguments))}}},rs="Promise resolved with itself",_o=at("currentTaskTrace");function cn(Ue,He,ge){const We=Pt();if(Ue===ge)throw new TypeError(rs);if(Ue[Pr]===Pi){let wt=null;try{("object"==typeof ge||"function"==typeof ge)&&(wt=ge&&ge.then)}catch(Xe){return We(()=>{cn(Ue,!1,Xe)})(),Ue}if(He!==dr&&ge instanceof F&&ge.hasOwnProperty(Pr)&&ge.hasOwnProperty(Wt)&&ge[Pr]!==Pi)Do(ge),cn(Ue,ge[Pr],ge[Wt]);else if(He!==dr&&"function"==typeof wt)try{wt.call(ge,We(yi(Ue,He)),We(yi(Ue,!1)))}catch(Xe){We(()=>{cn(Ue,!1,Xe)})()}else{Ue[Pr]=He;const Xe=Ue[Wt];if(Ue[Wt]=ge,Ue[ct]===ct&&He===lt&&(Ue[Pr]=Ue[sr],Ue[Wt]=Ue[jn]),He===dr&&ge instanceof Error){const mt=se.currentTask&&se.currentTask.data&&se.currentTask.data[Di];mt&&be(ge,_o,{configurable:!0,enumerable:!1,writable:!0,value:mt})}for(let mt=0;mt{try{const dt=Ue[Wt],$t=!!ge&&ct===ge[ct];$t&&(ge[jn]=dt,ge[sr]=Xe);const hi=He.run(mt,void 0,$t&&mt!==is&&mt!==ki?[]:[dt]);cn(ge,!0,hi)}catch(dt){cn(ge,!1,dt)}},ge)}const zi=function(){},ht=Z.AggregateError;class F{static toString(){return"function ZoneAwarePromise() { [native code] }"}static resolve(He){return He instanceof F?He:cn(new this(null),lt,He)}static reject(He){return cn(new this(null),dr,He)}static withResolvers(){const He={};return He.promise=new F((ge,We)=>{He.resolve=ge,He.reject=We}),He}static any(He){if(!He||"function"!=typeof He[Symbol.iterator])return Promise.reject(new ht([],"All promises were rejected"));const ge=[];let We=0;try{for(let mt of He)We++,ge.push(F.resolve(mt))}catch{return Promise.reject(new ht([],"All promises were rejected"))}if(0===We)return Promise.reject(new ht([],"All promises were rejected"));let wt=!1;const Xe=[];return new F((mt,dt)=>{for(let $t=0;$t{wt||(wt=!0,mt(hi))},hi=>{Xe.push(hi),We--,0===We&&(wt=!0,dt(new ht(Xe,"All promises were rejected")))})})}static race(He){let ge,We,wt=new this((dt,$t)=>{ge=dt,We=$t});function Xe(dt){ge(dt)}function mt(dt){We(dt)}for(let dt of He)cr(dt)||(dt=this.resolve(dt)),dt.then(Xe,mt);return wt}static all(He){return F.allWithCallback(He)}static allSettled(He){return(this&&this.prototype instanceof F?this:F).allWithCallback(He,{thenCallback:We=>({status:"fulfilled",value:We}),errorCallback:We=>({status:"rejected",reason:We})})}static allWithCallback(He,ge){let We,wt,Xe=new this((hi,ur)=>{We=hi,wt=ur}),mt=2,dt=0;const $t=[];for(let hi of He){cr(hi)||(hi=this.resolve(hi));const ur=dt;try{hi.then(ir=>{$t[ur]=ge?ge.thenCallback(ir):ir,mt--,0===mt&&We($t)},ir=>{ge?($t[ur]=ge.errorCallback(ir),mt--,0===mt&&We($t)):wt(ir)})}catch(ir){wt(ir)}mt++,dt++}return mt-=2,0===mt&&We($t),Xe}constructor(He){const ge=this;if(!(ge instanceof F))throw new Error("Must be an instanceof Promise.");ge[Pr]=Pi,ge[Wt]=[];try{const We=Pt();He&&He(We(yi(ge,lt)),We(yi(ge,dr)))}catch(We){cn(ge,!1,We)}}get[Symbol.toStringTag](){return"Promise"}get[Symbol.species](){return F}then(He,ge){let We=this.constructor?.[Symbol.species];(!We||"function"!=typeof We)&&(We=this.constructor||F);const wt=new We(zi),Xe=se.current;return this[Pr]==Pi?this[Wt].push(Xe,wt,He,ge):Ls(this,Xe,wt,He,ge),wt}catch(He){return this.then(null,He)}finally(He){let ge=this.constructor?.[Symbol.species];(!ge||"function"!=typeof ge)&&(ge=F);const We=new ge(zi);We[ct]=ct;const wt=se.current;return this[Pr]==Pi?this[Wt].push(wt,We,He,He):Ls(this,wt,We,He,He),We}}F.resolve=F.resolve,F.reject=F.reject,F.race=F.race,F.all=F.all;const ae=Z[Lt]=Z.Promise;Z.Promise=F;const Et=at("thenPatched");function qt(Ue){const He=Ue.prototype,ge=pe(He,"then");if(ge&&(!1===ge.writable||!ge.configurable))return;const We=He.then;He[pt]=We,Ue.prototype.then=function(wt,Xe){return new F((dt,$t)=>{We.call(this,dt,$t)}).then(wt,Xe)},Ue[Et]=!0}return ye.patchThen=qt,ae&&(qt(ae),tl(Z,"fetch",Ue=>function Vn(Ue){return function(He,ge){let We=Ue.apply(He,ge);if(We instanceof F)return We;let wt=We.constructor;return wt[Et]||qt(wt),We}}(Ue))),Promise[se.__symbol__("uncaughtPromiseErrors")]=tt,F}),Zone.__load_patch("toString",Z=>{const se=Function.prototype.toString,ye=Ji("OriginalDelegate"),pe=Ji("Promise"),be=Ji("Error"),ke=function(){if("function"==typeof this){const Lt=this[ye];if(Lt)return"function"==typeof Lt?se.call(Lt):Object.prototype.toString.call(Lt);if(this===Promise){const pt=Z[pe];if(pt)return se.call(pt)}if(this===Error){const pt=Z[be];if(pt)return se.call(pt)}}return se.call(this)};ke[ye]=se,Function.prototype.toString=ke;const at=Object.prototype.toString;Object.prototype.toString=function(){return"function"==typeof Promise&&this instanceof Promise?"[object Promise]":at.call(this)}});let il=!1;if(typeof window<"u")try{const Z=Object.defineProperty({},"passive",{get:function(){il=!0}});window.addEventListener("test",Z,Z),window.removeEventListener("test",Z,Z)}catch{il=!1}const kT={useG:!0},Co={},Ib={},Sm=new RegExp("^"+Wd+"(\\w+)(true|false)$"),bb=Ji("propagationStopped");function Im(Z,se){const ye=(se?se(Z):Z)+Wi,pe=(se?se(Z):Z)+Ts,be=Wd+ye,ke=Wd+pe;Co[Z]={},Co[Z][Wi]=be,Co[Z][Ts]=ke}function Mb(Z,se,ye,pe){const be=pe&&pe.add||pm,ke=pe&&pe.rm||$r,at=pe&&pe.listeners||"eventListeners",tt=pe&&pe.rmAll||"removeAllListeners",At=Ji(be),Lt="."+be+":",pt="prependListener",Di="."+pt+":",si=function(Wt,ct,jn){if(Wt.isRemoved)return;const sr=Wt.callback;let Zr;"object"==typeof sr&&sr.handleEvent&&(Wt.callback=lt=>sr.handleEvent(lt),Wt.originalDelegate=sr);try{Wt.invoke(Wt,ct,[jn])}catch(lt){Zr=lt}const Pi=Wt.options;return Pi&&"object"==typeof Pi&&Pi.once&&ct[ke].call(ct,jn.type,Wt.originalDelegate?Wt.originalDelegate:Wt.callback,Pi),Zr};function mi(Wt,ct,jn){if(!(ct=ct||Z.event))return;const sr=Wt||ct.target||Z,Zr=sr[Co[ct.type][jn?Ts:Wi]];if(Zr){const Pi=[];if(1===Zr.length){const lt=si(Zr[0],sr,ct);lt&&Pi.push(lt)}else{const lt=Zr.slice();for(let dr=0;dr{throw dr})}}}const cr=function(Wt){return mi(this,Wt,!1)},ki=function(Wt){return mi(this,Wt,!0)};function is(Wt,ct){if(!Wt)return!1;let jn=!0;ct&&void 0!==ct.useG&&(jn=ct.useG);const sr=ct&&ct.vh;let Zr=!0;ct&&void 0!==ct.chkDup&&(Zr=ct.chkDup);let Pi=!1;ct&&void 0!==ct.rt&&(Pi=ct.rt);let lt=Wt;for(;lt&&!lt.hasOwnProperty(be);)lt=jd(lt);if(!lt&&Wt[be]&&(lt=Wt),!lt||lt[At])return!1;const dr=ct&&ct.eventNameToString,et={},yi=lt[At]=lt[be],Pt=lt[Ji(ke)]=lt[ke],rs=lt[Ji(at)]=lt[at],_o=lt[Ji(tt)]=lt[tt];let cn;ct&&ct.prepend&&(cn=lt[Ji(ct.prepend)]=lt[ct.prepend]);const F=jn?function(ge){if(!et.isExisting)return yi.call(et.target,et.eventName,et.capture?ki:cr,et.options)}:function(ge){return yi.call(et.target,et.eventName,ge.invoke,et.options)},ae=jn?function(ge){if(!ge.isRemoved){const We=Co[ge.eventName];let wt;We&&(wt=We[ge.capture?Ts:Wi]);const Xe=wt&&ge.target[wt];if(Xe)for(let mt=0;mt{Vo.zone.cancelTask(Vo)},{once:!0})),et.target=null,Fc&&(Fc.taskData=null),$d&&(Tn.once=!0),!il&&"boolean"==typeof Vo.options||(Vo.options=Tn),Vo.target=$t,Vo.capture=Zl,Vo.eventName=hi,ir&&(Vo.originalDelegate=ur),dt?jo.unshift(Vo):jo.push(Vo),mt?$t:void 0}};return lt[be]=He(yi,Lt,F,ae,Pi),cn&&(lt[pt]=He(cn,Di,function(ge){return cn.call(et.target,et.eventName,ge.invoke,et.options)},ae,Pi,!0)),lt[ke]=function(){const ge=this||Z;let We=arguments[0];ct&&ct.transferEventName&&(We=ct.transferEventName(We));const wt=arguments[2],Xe=!!wt&&("boolean"==typeof wt||wt.capture),mt=arguments[1];if(!mt)return Pt.apply(this,arguments);if(sr&&!sr(Pt,mt,ge,arguments))return;const dt=Co[We];let $t;dt&&($t=dt[Xe?Ts:Wi]);const hi=$t&&ge[$t];if(hi)for(let ur=0;urfunction(be,ke){be[bb]=!0,pe&&pe.apply(be,ke)})}function Cb(Z,se,ye,pe,be){const ke=Zone.__symbol__(pe);if(se[ke])return;const at=se[ke]=se[pe];se[pe]=function(tt,At,Lt){return At&&At.prototype&&be.forEach(function(pt){const Di=`${ye}.${pe}::`+pt,si=At.prototype;try{if(si.hasOwnProperty(pt)){const mi=Z.ObjectGetOwnPropertyDescriptor(si,pt);mi&&mi.value?(mi.value=Z.wrapWithCurrentZone(mi.value,Di),Z._redefineProperty(At.prototype,pt,mi)):si[pt]&&(si[pt]=Z.wrapWithCurrentZone(si[pt],Di))}else si[pt]&&(si[pt]=Z.wrapWithCurrentZone(si[pt],Di))}catch{}}),at.call(se,tt,At,Lt)},Z.attachOriginToPatched(se[pe],at)}function Eb(Z,se,ye){if(!ye||0===ye.length)return se;const pe=ye.filter(ke=>ke.target===Z);if(!pe||0===pe.length)return se;const be=pe[0].ignoreProperties;return se.filter(ke=>-1===be.indexOf(ke))}function Eo(Z,se,ye,pe){Z&&cp(Z,Eb(Z,se,ye),pe)}function qd(Z){return Object.getOwnPropertyNames(Z).filter(se=>se.startsWith("on")&&se.length>2).map(se=>se.substring(2))}Zone.__load_patch("util",(Z,se,ye)=>{const pe=qd(Z);ye.patchOnProperties=cp,ye.patchMethod=tl,ye.bindArguments=Yd,ye.patchMacroTask=mb;const be=se.__symbol__("BLACK_LISTED_EVENTS"),ke=se.__symbol__("UNPATCHED_EVENTS");Z[ke]&&(Z[be]=Z[ke]),Z[be]&&(se[be]=se[ke]=Z[be]),ye.patchEventPrototype=bm,ye.patchEventTarget=Mb,ye.isIEOrEdge=Sb,ye.ObjectDefineProperty=Ud,ye.ObjectGetOwnPropertyDescriptor=Wl,ye.ObjectCreate=Vd,ye.ArraySlice=vb,ye.patchClass=Gd,ye.wrapWithCurrentZone=op,ye.filterProperties=Eb,ye.attachOriginToPatched=Ia,ye._redefineProperty=Object.defineProperty,ye.patchCallbacks=Cb,ye.getGlobalObjects=()=>({globalSources:Ib,zoneSymbolEventNames:Co,eventNames:pe,isBrowser:Qd,isMix:hp,isNode:Vh,TRUE_STR:Ts,FALSE_STR:Wi,ZONE_SYMBOL_PREFIX:Wd,ADD_EVENT_LISTENER_STR:pm,REMOVE_EVENT_LISTENER_STR:$r})});const As=Ji("zoneTask");function Xl(Z,se,ye,pe){let be=null,ke=null;ye+=pe;const at={};function tt(Lt){const pt=Lt.data;return pt.args[0]=function(){return Lt.invoke.apply(this,arguments)},pt.handleId=be.apply(Z,pt.args),Lt}function At(Lt){return ke.call(Z,Lt.data.handleId)}be=tl(Z,se+=pe,Lt=>function(pt,Di){if("function"==typeof Di[0]){const si={isPeriodic:"Interval"===pe,delay:"Timeout"===pe||"Interval"===pe?Di[1]||0:void 0,args:Di},mi=Di[0];Di[0]=function(){try{return mi.apply(this,arguments)}finally{si.isPeriodic||("number"==typeof si.handleId?delete at[si.handleId]:si.handleId&&(si.handleId[As]=null))}};const cr=gm(se,Di[0],si,tt,At);if(!cr)return cr;const ki=cr.data.handleId;return"number"==typeof ki?at[ki]=cr:ki&&(ki[As]=cr),ki&&ki.ref&&ki.unref&&"function"==typeof ki.ref&&"function"==typeof ki.unref&&(cr.ref=ki.ref.bind(ki),cr.unref=ki.unref.bind(ki)),"number"==typeof ki||ki?ki:cr}return Lt.apply(Z,Di)}),ke=tl(Z,ye,Lt=>function(pt,Di){const si=Di[0];let mi;"number"==typeof si?mi=at[si]:(mi=si&&si[As],mi||(mi=si)),mi&&"string"==typeof mi.type?"notScheduled"!==mi.state&&(mi.cancelFn&&mi.data.isPeriodic||0===mi.runCount)&&("number"==typeof si?delete at[si]:si&&(si[As]=null),mi.zone.cancelTask(mi)):Lt.apply(Z,Di)})}Zone.__load_patch("legacy",Z=>{const se=Z[Zone.__symbol__("legacyPatch")];se&&se()}),Zone.__load_patch("timers",Z=>{const ye="clear";Xl(Z,"set",ye,"Timeout"),Xl(Z,"set",ye,"Interval"),Xl(Z,"set",ye,"Immediate")}),Zone.__load_patch("requestAnimationFrame",Z=>{Xl(Z,"request","cancel","AnimationFrame"),Xl(Z,"mozRequest","mozCancel","AnimationFrame"),Xl(Z,"webkitRequest","webkitCancel","AnimationFrame")}),Zone.__load_patch("blocking",(Z,se)=>{const ye=["alert","prompt","confirm"];for(let pe=0;pefunction(At,Lt){return se.current.run(ke,Z,Lt,tt)})}),Zone.__load_patch("EventTarget",(Z,se,ye)=>{(function ql(Z,se){se.patchEventPrototype(Z,se)})(Z,ye),function wm(Z,se){if(Zone[se.symbol("patchEventTarget")])return;const{eventNames:ye,zoneSymbolEventNames:pe,TRUE_STR:be,FALSE_STR:ke,ZONE_SYMBOL_PREFIX:at}=se.getGlobalObjects();for(let At=0;At{Gd("MutationObserver"),Gd("WebKitMutationObserver")}),Zone.__load_patch("IntersectionObserver",(Z,se,ye)=>{Gd("IntersectionObserver")}),Zone.__load_patch("FileReader",(Z,se,ye)=>{Gd("FileReader")}),Zone.__load_patch("on_property",(Z,se,ye)=>{!function dp(Z,se){if(Vh&&!hp||Zone[Z.symbol("patchEvents")])return;const ye=se.__Zone_ignore_on_properties;let pe=[];if(Qd){const be=window;pe=pe.concat(["Document","SVGElement","Element","HTMLElement","HTMLBodyElement","HTMLMediaElement","HTMLFrameSetElement","HTMLFrameElement","HTMLIFrameElement","HTMLMarqueeElement","Worker"]);const ke=function ym(){try{const Z=jh.navigator.userAgent;if(-1!==Z.indexOf("MSIE ")||-1!==Z.indexOf("Trident/"))return!0}catch{}return!1}()?[{target:be,ignoreProperties:["error"]}]:[];Eo(be,qd(be),ye&&ye.concat(ke),jd(be))}pe=pe.concat(["XMLHttpRequest","XMLHttpRequestEventTarget","IDBIndex","IDBRequest","IDBOpenDBRequest","IDBDatabase","IDBTransaction","IDBCursor","WebSocket"]);for(let be=0;be{!function Mm(Z,se){const{isBrowser:ye,isMix:pe}=se.getGlobalObjects();(ye||pe)&&Z.customElements&&"customElements"in Z&&se.patchCallbacks(se,Z.customElements,"customElements","define",["connectedCallback","disconnectedCallback","adoptedCallback","attributeChangedCallback"])}(Z,ye)}),Zone.__load_patch("XHR",(Z,se)=>{!function At(Lt){const pt=Lt.XMLHttpRequest;if(!pt)return;const Di=pt.prototype;let mi=Di[Yl],cr=Di[_h];if(!mi){const et=Lt.XMLHttpRequestEventTarget;if(et){const yi=et.prototype;mi=yi[Yl],cr=yi[_h]}}const ki="readystatechange",is="scheduled";function Pr(et){const yi=et.data,Pt=yi.target;Pt[ke]=!1,Pt[tt]=!1;const rs=Pt[be];mi||(mi=Pt[Yl],cr=Pt[_h]),rs&&cr.call(Pt,ki,rs);const _o=Pt[be]=()=>{if(Pt.readyState===Pt.DONE)if(!yi.aborted&&Pt[ke]&&et.state===is){const Ur=Pt[se.__symbol__("loadfalse")];if(0!==Pt.status&&Ur&&Ur.length>0){const Do=et.invoke;et.invoke=function(){const Ls=Pt[se.__symbol__("loadfalse")];for(let jr=0;jrfunction(et,yi){return et[pe]=0==yi[2],et[at]=yi[1],jn.apply(et,yi)}),Zr=Ji("fetchTaskAborting"),Pi=Ji("fetchTaskScheduling"),lt=tl(Di,"send",()=>function(et,yi){if(!0===se.current[Pi]||et[pe])return lt.apply(et,yi);{const Pt={target:et,url:et[at],isPeriodic:!1,args:yi,aborted:!1},rs=gm("XMLHttpRequest.send",Wt,Pt,Pr,ct);et&&!0===et[tt]&&!Pt.aborted&&rs.state===is&&rs.invoke()}}),dr=tl(Di,"abort",()=>function(et,yi){const Pt=function si(et){return et[ye]}(et);if(Pt&&"string"==typeof Pt.type){if(null==Pt.cancelFn||Pt.data&&Pt.data.aborted)return;Pt.zone.cancelTask(Pt)}else if(!0===se.current[Zr])return dr.apply(et,yi)})}(Z);const ye=Ji("xhrTask"),pe=Ji("xhrSync"),be=Ji("xhrListener"),ke=Ji("xhrScheduled"),at=Ji("xhrURL"),tt=Ji("xhrErrorBeforeScheduled")}),Zone.__load_patch("geolocation",Z=>{Z.navigator&&Z.navigator.geolocation&&function mm(Z,se){const ye=Z.constructor.name;for(let pe=0;pe{const At=function(){return tt.apply(this,Yd(arguments,ye+"."+be))};return Ia(At,tt),At})(ke)}}}(Z.navigator.geolocation,["getCurrentPosition","watchPosition"])}),Zone.__load_patch("PromiseRejectionEvent",(Z,se)=>{function ye(pe){return function(be){wb(Z,pe).forEach(at=>{const tt=Z.PromiseRejectionEvent;if(tt){const At=new tt(pe,{promise:be.promise,reason:be.rejection});at.invoke(At)}})}}Z.PromiseRejectionEvent&&(se[Ji("unhandledPromiseRejectionHandler")]=ye("unhandledrejection"),se[Ji("rejectionHandledHandler")]=ye("rejectionhandled"))}),Zone.__load_patch("queueMicrotask",(Z,se,ye)=>{!function up(Z,se){se.patchMethod(Z,"queueMicrotask",ye=>function(pe,be){Zone.current.scheduleMicroTask("queueMicrotask",be[0])})}(Z,ye)})}},Wl=>{Wl(Wl.s=51)}]); \ No newline at end of file diff --git a/ej2-angular/samples/tab/dynamic-tab-cs1/3rdpartylicenses.txt b/ej2-angular/samples/tab/dynamic-tab-cs1/3rdpartylicenses.txt new file mode 100644 index 0000000000..7ac784204f --- /dev/null +++ b/ej2-angular/samples/tab/dynamic-tab-cs1/3rdpartylicenses.txt @@ -0,0 +1,313 @@ +@angular/common +MIT + +@angular/core +MIT + +@angular/forms +MIT + +@angular/platform-browser +MIT + +@syncfusion/ej2-angular-base +SEE LICENSE IN license + +@syncfusion/ej2-angular-buttons +SEE LICENSE IN license + +@syncfusion/ej2-angular-calendars +SEE LICENSE IN license + +@syncfusion/ej2-angular-dropdowns +SEE LICENSE IN license + +@syncfusion/ej2-angular-grids +SEE LICENSE IN license + +@syncfusion/ej2-angular-inputs +SEE LICENSE IN license + +@syncfusion/ej2-angular-navigations +SEE LICENSE IN license + +@syncfusion/ej2-angular-popups +SEE LICENSE IN license + +@syncfusion/ej2-base +SEE LICENSE IN license + +@syncfusion/ej2-buttons +SEE LICENSE IN license + +@syncfusion/ej2-calendars +SEE LICENSE IN license + +@syncfusion/ej2-data +SEE LICENSE IN license + +@syncfusion/ej2-dropdowns +SEE LICENSE IN license + +@syncfusion/ej2-grids +SEE LICENSE IN license + +@syncfusion/ej2-inputs +SEE LICENSE IN license + +@syncfusion/ej2-lists +SEE LICENSE IN license + +@syncfusion/ej2-navigations +SEE LICENSE IN license + +@syncfusion/ej2-popups +SEE LICENSE IN license + +@syncfusion/ej2-splitbuttons +SEE LICENSE IN license + +rxjs +Apache-2.0 + Apache License + Version 2.0, January 2004 + http://www.apache.org/licenses/ + + TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION + + 1. Definitions. + + "License" shall mean the terms and conditions for use, reproduction, + and distribution as defined by Sections 1 through 9 of this document. + + "Licensor" shall mean the copyright owner or entity authorized by + the copyright owner that is granting the License. + + "Legal Entity" shall mean the union of the acting entity and all + other entities that control, are controlled by, or are under common + control with that entity. For the purposes of this definition, + "control" means (i) the power, direct or indirect, to cause the + direction or management of such entity, whether by contract or + otherwise, or (ii) ownership of fifty percent (50%) or more of the + outstanding shares, or (iii) beneficial ownership of such entity. + + "You" (or "Your") shall mean an individual or Legal Entity + exercising permissions granted by this License. + + "Source" form shall mean the preferred form for making modifications, + including but not limited to software source code, documentation + source, and configuration files. + + "Object" form shall mean any form resulting from mechanical + transformation or translation of a Source form, including but + not limited to compiled object code, generated documentation, + and conversions to other media types. + + "Work" shall mean the work of authorship, whether in Source or + Object form, made available under the License, as indicated by a + copyright notice that is included in or attached to the work + (an example is provided in the Appendix below). + + "Derivative Works" shall mean any work, whether in Source or Object + form, that is based on (or derived from) the Work and for which the + editorial revisions, annotations, elaborations, or other modifications + represent, as a whole, an original work of authorship. For the purposes + of this License, Derivative Works shall not include works that remain + separable from, or merely link (or bind by name) to the interfaces of, + the Work and Derivative Works thereof. + + "Contribution" shall mean any work of authorship, including + the original version of the Work and any modifications or additions + to that Work or Derivative Works thereof, that is intentionally + submitted to Licensor for inclusion in the Work by the copyright owner + or by an individual or Legal Entity authorized to submit on behalf of + the copyright owner. For the purposes of this definition, "submitted" + means any form of electronic, verbal, or written communication sent + to the Licensor or its representatives, including but not limited to + communication on electronic mailing lists, source code control systems, + and issue tracking systems that are managed by, or on behalf of, the + Licensor for the purpose of discussing and improving the Work, but + excluding communication that is conspicuously marked or otherwise + designated in writing by the copyright owner as "Not a Contribution." + + "Contributor" shall mean Licensor and any individual or Legal Entity + on behalf of whom a Contribution has been received by Licensor and + subsequently incorporated within the Work. + + 2. Grant of Copyright License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + copyright license to reproduce, prepare Derivative Works of, + publicly display, publicly perform, sublicense, and distribute the + Work and such Derivative Works in Source or Object form. + + 3. Grant of Patent License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + (except as stated in this section) patent license to make, have made, + use, offer to sell, sell, import, and otherwise transfer the Work, + where such license applies only to those patent claims licensable + by such Contributor that are necessarily infringed by their + Contribution(s) alone or by combination of their Contribution(s) + with the Work to which such Contribution(s) was submitted. If You + institute patent litigation against any entity (including a + cross-claim or counterclaim in a lawsuit) alleging that the Work + or a Contribution incorporated within the Work constitutes direct + or contributory patent infringement, then any patent licenses + granted to You under this License for that Work shall terminate + as of the date such litigation is filed. + + 4. Redistribution. You may reproduce and distribute copies of the + Work or Derivative Works thereof in any medium, with or without + modifications, and in Source or Object form, provided that You + meet the following conditions: + + (a) You must give any other recipients of the Work or + Derivative Works a copy of this License; and + + (b) You must cause any modified files to carry prominent notices + stating that You changed the files; and + + (c) You must retain, in the Source form of any Derivative Works + that You distribute, all copyright, patent, trademark, and + attribution notices from the Source form of the Work, + excluding those notices that do not pertain to any part of + the Derivative Works; and + + (d) If the Work includes a "NOTICE" text file as part of its + distribution, then any Derivative Works that You distribute must + include a readable copy of the attribution notices contained + within such NOTICE file, excluding those notices that do not + pertain to any part of the Derivative Works, in at least one + of the following places: within a NOTICE text file distributed + as part of the Derivative Works; within the Source form or + documentation, if provided along with the Derivative Works; or, + within a display generated by the Derivative Works, if and + wherever such third-party notices normally appear. The contents + of the NOTICE file are for informational purposes only and + do not modify the License. You may add Your own attribution + notices within Derivative Works that You distribute, alongside + or as an addendum to the NOTICE text from the Work, provided + that such additional attribution notices cannot be construed + as modifying the License. + + You may add Your own copyright statement to Your modifications and + may provide additional or different license terms and conditions + for use, reproduction, or distribution of Your modifications, or + for any such Derivative Works as a whole, provided Your use, + reproduction, and distribution of the Work otherwise complies with + the conditions stated in this License. + + 5. Submission of Contributions. Unless You explicitly state otherwise, + any Contribution intentionally submitted for inclusion in the Work + by You to the Licensor shall be under the terms and conditions of + this License, without any additional terms or conditions. + Notwithstanding the above, nothing herein shall supersede or modify + the terms of any separate license agreement you may have executed + with Licensor regarding such Contributions. + + 6. Trademarks. This License does not grant permission to use the trade + names, trademarks, service marks, or product names of the Licensor, + except as required for reasonable and customary use in describing the + origin of the Work and reproducing the content of the NOTICE file. + + 7. Disclaimer of Warranty. Unless required by applicable law or + agreed to in writing, Licensor provides the Work (and each + Contributor provides its Contributions) on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or + implied, including, without limitation, any warranties or conditions + of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A + PARTICULAR PURPOSE. You are solely responsible for determining the + appropriateness of using or redistributing the Work and assume any + risks associated with Your exercise of permissions under this License. + + 8. Limitation of Liability. In no event and under no legal theory, + whether in tort (including negligence), contract, or otherwise, + unless required by applicable law (such as deliberate and grossly + negligent acts) or agreed to in writing, shall any Contributor be + liable to You for damages, including any direct, indirect, special, + incidental, or consequential damages of any character arising as a + result of this License or out of the use or inability to use the + Work (including but not limited to damages for loss of goodwill, + work stoppage, computer failure or malfunction, or any and all + other commercial damages or losses), even if such Contributor + has been advised of the possibility of such damages. + + 9. Accepting Warranty or Additional Liability. While redistributing + the Work or Derivative Works thereof, You may choose to offer, + and charge a fee for, acceptance of support, warranty, indemnity, + or other liability obligations and/or rights consistent with this + License. However, in accepting such obligations, You may act only + on Your own behalf and on Your sole responsibility, not on behalf + of any other Contributor, and only if You agree to indemnify, + defend, and hold each Contributor harmless for any liability + incurred by, or claims asserted against, such Contributor by reason + of your accepting any such warranty or additional liability. + + END OF TERMS AND CONDITIONS + + APPENDIX: How to apply the Apache License to your work. + + To apply the Apache License to your work, attach the following + boilerplate notice, with the fields enclosed by brackets "[]" + replaced with your own identifying information. (Don't include + the brackets!) The text should be enclosed in the appropriate + comment syntax for the file format. We also recommend that a + file or class name and description of purpose be included on the + same "printed page" as the copyright notice for easier + identification within third-party archives. + + Copyright (c) 2015-2018 Google, Inc., Netflix, Inc., Microsoft Corp. and contributors + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + + + +tslib +0BSD +Copyright (c) Microsoft Corporation. + +Permission to use, copy, modify, and/or distribute this software for any +purpose with or without fee is hereby granted. + +THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH +REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY +AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, +INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM +LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR +OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR +PERFORMANCE OF THIS SOFTWARE. + +zone.js +MIT +The MIT License + +Copyright (c) 2010-2023 Google LLC. https://angular.io/license + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. diff --git a/ej2-angular/samples/tab/dynamic-tab-cs1/index.css b/ej2-angular/samples/tab/dynamic-tab-cs1/index.css new file mode 100644 index 0000000000..b7285115e9 --- /dev/null +++ b/ej2-angular/samples/tab/dynamic-tab-cs1/index.css @@ -0,0 +1,43 @@ + +#loader { + color: #008cff; + height: 40px; + left: 45%; + position: absolute; + top: 45%; + width: 30%; +} + +@font-face { + font-family: 'Socialicons'; + src: url(data:application/x-font-ttf;charset=utf-8;base64,AAEAAAAKAIAAAwAgT1MvMv1tCfsAAAEoAAAAVmNtYXCnKKeOAAABrAAAAEhnbHlml19XagAAAgwAABhQaGVhZA8dCeEAAADQAAAANmhoZWEIUQQMAAAArAAAACRobXR4LAAAAAAAAYAAAAAsbG9jYR3AIwwAAAH0AAAAGG1heHABIAIAAAABCAAAACBuYW1l0X1q/wAAGlwAAAJVcG9zdGX5D00AABy0AAAAkwABAAAEAAAAAFwEAAAAAAAD9AABAAAAAAAAAAAAAAAAAAAACwABAAAAAQAA+iTiP18PPPUACwQAAAAAANYFYngAAAAA1gVieAAAAAAD9AP0AAAACAACAAAAAAAAAAEAAAALAfQACwAAAAAAAgAAAAoACgAAAP8AAAAAAAAAAQQAAZAABQAAAokCzAAAAI8CiQLMAAAB6wAyAQgAAAIABQMAAAAAAAAAAAAAAAAAAAAAAAAAAAAAUGZFZABApwCnCQQAAAAAXAQAAAAAAAABAAAAAAAABAAAAAQAAAAEAAAABAAAAAQAAAAEAAAABAAAAAQAAAAEAAAABAAAAAQAAAAAAAACAAAAAwAAABQAAwABAAAAFAAEADQAAAAEAAQAAQAApwn//wAApwD//wAAAAEABAAAAAEAAgADAAQABQAGAAcACAAJAAoAAAAAAiQCzgOMBU4F/gZYB9QIcAo+DCgABAAAAAAD0gPzAFUA4gF3AfMAAAEzHwYHFQ8EFR8IPwUfBRUPCCMvFj0BPwoXNw8fHQEfDhUPAT8CHwkzPyA9Ai8iDwIFHwcPIysBLwYjDwI/AS8PNT8oHx4BDxAdAR8PHQEHPwE7AR8EMz8dNS8kIw8FAYkFEgQDAyQDAQECAyIBAQMSEgkUCw4vBQQFChsGBQdqAgIBAwMDCAoMDA0NBgYPEA8PFxYVFBQTEhITEREPDgwKCQQEBQICBAQFChMJBQUFBTURDxAPDw8ODg4NDQwMDAsLCgkJCQgHBwcFBQUEAwICAQEDAgQEBgYHBwkJCgsOAgEmiwMEBAQUFRQVFRQVFRQVFRUVFBUVDw4ODg0NDAwLCwoKCQkICAcGBgUEBAQCAgICAgMEBAYGBgcICQkJCgsLCwwNDQ0ODg4PDw8QEBAQEBEREREQEQHcBgUEBAICAQEBAQEDAwQFBQYHCAgICgoLCwwNDQ4ODxAREhISEhMTExMUExQUFRQVGxsaGgcIBwfXNgEBAQ8KCgoIBwcGBQUDAwIBAQECAwMDBQUFBgcHCAgICgkKCwsMDAwNDg0ODw8PEBAQEhISEhISEhIREREREREQERAQDw8PDw8ODQ0NDQwLDAoKCgkJCAcH/aAQEB0cGhgWFBIRDgwLCAcEAwICAwMFBQYHBwgJCgoLAgE9+AYFBSMeHx4fIB8fFhQUFBQSExIRERAQEA8ODhAQDQ0LCQgHBgQCAgICBAQEBgYGCAgJCQoLCwwMDQ4ODg8PEBAREBESEhISExITGBcZGRgZGBgXAu4CAgMEXAkFBAQFBCQCAwMGGhcKFQkMIwIBAwoYAwIBKQECBSgFBgULCgkHBgMBAQEDAwcICgwMDg8PEhITFBUWGBgSEyYJCAgIBwcHDBEGAgEBAagEBAQGBgYHCAgJCgkLCwsMDAwNDQ4ODg8PDw8QEBAQERITEhESEREREBEPEA8QDhMEBASFNgEBAQEJCAcGBQMCAQEDAwUGCAgHCAgJCQoKCwsMDA0NDQ4ODg8ODxAPEA8QEBAREBAQEBIQERAQDw8ODg0NDQwMCwoKCQkICAcGBgUFAwMDAQEBAQEC6RISExISExISEhMSEhESERERERAQEA8QDg8NDg0MDAwLCwoJCQcHBgUEAwICAgIEBggJAwECVNcFBAQVEBEREhESEhITExMTFBMUEhEREBEQEBAPDw8PDg4ODQ0MDAwLCwoKCgkICAcHBwUGBQQDAgIBAQEBAgIDBAQFBQcGCAgICQoKCgsMDA0NDQ4PDw8QEBEBBwgIEhMUFhcYGRscHR8fIiIjFBMTEhMSEhIREhEREBEQEAMEAwT1YQINCAYEAgIEBAUGBggICQoKDAwNDg8PERUVFhcWGBcYGBkZGRkaGxoTEhISEhEREBAQDw8ODg4MDQwLCgoKCQgHBwYFBQMDAwEBAgMFBQgIAAAAAAEAAAAAAzoD9ACWAAATDwYVERUfHTsBPw49AS8OIy8PNSEzPw4vDyE9AS8ODwblCAYFBAQCAgECAwMEBQUGBwgICQoKCwwMDA0NDQ0ODg4PDw8QEBDQCgsKCQkJCAgHBwUEBAICAgIEBAUHBwgICQkJCgsK0QoKCgoJCAgIBwcFBAMDAQEBKQoJCggJCAgHBwUFBAQCAQEBAQIEBAUFBwgHCAkJCQkK/tcCAgMFBQYHCAkICQoJCwoLCwoJCQkIA9AJCgsKDAwMDf4LExMTEhESEREQEBAPDw4PDQ4MDAoKCQgIBgYEBAMCAgEBAwQFBwcJCQoKCwsMDA0NDAsMCwoKCQkHBwUEAwEBAQEDBAUGCAgJCgoLCwwMDVgCAwMFBgcICQkJCgsLCwwLDAsKCgoJCAgHBgUEAgIBtQ0MDAsLCgoJCQcHBQQDAQEBAQMEBQYIAAABAAAAAAP0A90AqAAAAT8DMx8MHQEPDSsBLxoPCBc/Ah8LEx8PMz8dLw8jDw4CSAoTEhIRCAcGBwUFBQQDAwICAgEDBQoPExYWFAsLCgQFBAUFBAUFBQUJCQkJCyQEBQUGBwcICAkKCgsLDQwODQ8RERQfI5IvNRMGBwYGBwYGBgYGDAsMWAcICAgICQkJCQkKCgoLCgsJExITFBQVFRYWFiMkJTEWFRQREQ8NDAsJBwYFAwEBAQEDBAUHBwkJCwwNDhAQEgsYGBYWFBQSEhAQDg4MCwsC2wQGBQIBAgICAwQEBQUHBgcICBMSDxEdIiUoIxsOCgcCAQIEBAYICBUbHyU37xQTERAPDQwKCQgGBQMCAQEDBggLDhofkUInCwIBAgQEBwcJCwscISf+pBYUExIQDg4LCwkIBgUDAgEDBAcJDA0REhQXJysxRiEhIB4eHRwbGhkZFxcVFRoXFhQTERAODQwKCAcGBAMBAQMFBwkMDQ8RExUXGhsdAAUAAAAAA/ED9ABCAKoA6wESAYQAAAEdAQ8NKwEvDjU/EB8OJR0BHw8hPw8TLwMhHwUVDxEvEzU/CSchDwMFFR8PPw8vDw8OAR8HFQ8JIy8GPQI/BjMlHQEPBC8DNS8DDwMVDwIjLwM9Ai8BIw8EFQ8DIy8CNw8KFxUfASUzPwgzHwkhPwI1LxAlDwICkAMDBQcHCQkKDAwMDQ4ODwwMCwsLCgoJDwsJCAYFAgECAwQGBgcICQkKCwsMDA0LCw8ODg4MDAsKCQkHBgQEAv1/AQMFBgkJDAwODwgRERITEwJpExMSEhEQDw4MDAUJBwYEAgEBAgEF/uYOCwkGBAICBAYHCQsMDg8QERETExQTFRQVFBQUFBMTEhAPDg0LCQgGBAMCAgEBAwMEBQYHCAkC/uoFAgEBASwBAwUGCQoLDQ0PERESEhQUFBQTEhEQEA4MDAkJBgUDAQEDBQcICgsNDg8QERISFBQUFBMSERAQDgwMCggHBAMCPAYGBgQEAwEBAQEBAwMEBAQFBmgHBgYEBAMCAwMEBQUFBjX90AECBAUUBQEBAQEBAgIRAgIBAQIFEAkDAwECBAQEBQQDAwICAwUWAwIBAQQQDwwLCQgFAwEBAQEEATEEBBYUFRYWFxcYFxcXFxYVFBgFBQYBJwYCAgICBAYHCQoLDA4ODxAIERIR/d8FAQIB9wcHDg0NDAwLCgkIBwYFBAICAgQEBQYGDQwODg8REBINDQwMCwsKCgkIBwcGBAQCAQEBAgQFBggICgoLDQ0NDg9929sUExISERAPDgwMBQkHBgQCAQMFBgkJDAwODwgQERITEwHBBgMBARYXFxcXFxcWFhUUFBMREQ8ODAsJCAYEAwIBAgQFBwkKDA0PDxERExQPEA8PDw8PDw8ODw4ODg4OAQEBAQKPCgoUEhIREBANDQsKCAcFAwEBAwUHCAoLDQ4PEBESExQUFBMTEhEQDw4NCwoIBwUDAQEDBQcICgsNDg8QEhITEwGSAQICBAUFBgdsBQQFBAQDAgIBAQECAgQFBQYHawcHBgUDAgEBR2h1CAMCAQEBAgIF5wMCAQEBAQED6gUCAQEDAwbbBQICAQIDAwMG0ggEAQICAgTKAQ0OEBASEhQVEiRdAgIBAQITDg0JCAYDAQQFBwoMDhQCAQEBAQNuJBIRERAPDg4NCwoJCAMFBAEBAQIEAAAAAAMAAAAAA/QD3QADAFcAlwAANzMRIwUVIzc1IxEzET8OHw8RMxEvGw8MAR8PPw41Lw8PDhnW1gIjAQHW1gIDBQgKCwcHBwgJCQoKCw4NDAsKCAgHBwUEBAICAQHWAQICAgQDBQUFBgYHBwcJCAkJCgoKCwsLDBgZGhQUEREPDg0MCwoJCQ79xAEBAwMFBgYHCAkKCwsMDA4PDQwLCwoJCQcGBgUDAwIBAQMEBAYGCAgJCgoLDQwODQ0MDAoKCQkHBwYEBAMBIgKFWwICW/17AXcUDA0ODgwGBQUEBAMCAQEBAgMFBQcICgoLDA0NDw8Q/qcBhBIREBAPDw4NDQwMCwoKCQkICAcGBgUFBAMGAwEBAgMEBgYHCAgICQkSARIMCwsKCgkICAgGBQUEAwEBAQEDBAUFBggICAkKCgsLDAsLCwsJCggIBwYGBAQDAQEBAQMEBAYGBwgICgkLCwsAAAABAAAAAAPuA/QARgAAExEVHwYhESM1MzU/DzMVIw8GFTMVIxEhPwYRLwYhDwYSAgQFBwgKCgHPb24BAwMGBggJCgsMDQ0ODwgPlUcLCwkIBgQDe3sBBQoKCAcFBAICBAUHCAoK/IUKCgkHBwQDA7v8igYLCgkIBgQDAZuFUBAQDw4ODQwLCgkIBwUEAgGFAwQHCAkKDDOF/mUDBAYICQoLA4ILCgkIBgQDAQQFBwgKCwAAAAAGAAAAAAP0A/QAOABEAIABBQEqAUwAAAEPCR0BHw07AT8NPQEvCCMPASUVMxUjFSM1IzUzNSUPBRUfDTsBPww1Lw4jDwU3ByMfCA8PHw4dAQ8OLw8/DS8FPwIHIy8NPQE/DwEVHw8hPw8RITchLw8hDw4BCgMTCwsFBAQEAgICAwQGBgcICgoLDAwODg8NDQwLCgkICAYGBQQDAwEBAQIDBAgMDiYRNw0B9nR0TXNz/kAFAwMDAQIBAgMDBAQGBgcICQkKDAsIBwcHBwYFBQYFAwMBAQECAwMEBQYGBwgJCQoLDAcIBwcHBwX+MTAQDggIAwICAQEBAQEDAwMICgsMDAsGAgEBAQECAwYiGQoFCQcDAgIBAwQFCAgLDA0PERITFRYYFRISEA8NDAsKCAcGBAMCAQEBAwUHCQsOERMUFB0xCAcDAwEBAQIFGQ4ODQ0LCgoICAcFBQQCAgMDBgcICgwICBESEhESEBD+pwEDBQYJCgsNDg8IEBISExQCahQTExIREA8ODQsGCQcGBAL8GAED5gIDBgcICgsNDg4QCBIRExP9lhMTExEREA4ODQsKCAcGAwFKAQkHCAYGBggICQkKCgkICAgHBgYFBQMDAgIBAgMDBAUFBgYHBwcICQgHBwYGBgYLCwwcBQPYck9yck5zZwYGBwcHDxELCgwLCwsKCgkJBwUFAwECAwMDBAUHBwcIBw0QCwwLDAsMCgoKCAcGBAMBAgIDAwQFLRkQDwwPCAgJCgoLCQkICAgNDAsKCQwJBQYGBQYEBAcbFQsGDA4HCAgJCQ4NDQwNCwwKCggIBgYDAwEBAgMDBQYGBwgJCAoJCgsKCwUMDAwMDAsKCQYFBQUKDAYHCAgJBw0BAgQEBQcHCAkJCgoKCwsLDQ4NDQ0MDAsGBgkIBQQCAQH+EAoKExMSERAQDQ0LBgkHBgQCAQMFBgkKCw0NEAgQEhITFAJHKxQSEhIQDw8NDAsJBQcFBAIBAwQHCAkLDA0PDxASEhIAAAAAAgAAAAAD7gP0AEAAhAAAARUzFSMRHws/BxUPAy8OESM1Pw8lER8OMyEzPw4RLw4jISMPDQIbysoDBgUICgYHCAgJCgsLDQ4PEBESE0QtICIiEREQDw8ODQwKCgcHBANuGBkVDw4ODgYFBgUEBAMCAv5fAQECAwQEBQUGBwcHCAgJCAM0CAkICAcHBwYFBQQEAwIBAQEBAgMEBAUFBgcHBwgICQj8zAgJCAgHBwcGBQUEBAMCAQON0H/+9BIMCAkHBAMDAgEBAQEBAgMDBQYHeA4GAwEBAgIDBAUFBwgJCwsNDxABVGwKDxANDxEUCwwMDQ0ODxAQEvzCCQgICAcHBwYGBAUDAwICAgIDAwUEBgYHBwcICAgJAz4JCAgIBwcHBgYEBQMDAgICAgMDBQQGBgcHBwgICAAAAgAAAAAD7APzAPgBqAAAAR8LFQ8MIy8QKwEPDh8bHQEPFi8WPQE/DTMfEjM/Di8ePQE/Fh8CBR8HDwMfHjsBPwIfBzM/HTUvBz8CPQEvHiMPAi8HIw8dAnALFhMSDw4LCQgFBAIBAgIDAwgFBgUGBgcGCAwLCQgHChQLCwsHBwkJCgsNDQwMCwsJCggIBwYFBAMDAQEBAgMEBQcHCRMTdxojFhQTEA8OCwUFAwQCAwEBAgIEBQUHCAgKCgwMDg4PEBEREhMTFBUZGBYWFRMSEgsLCwoJCQgIBwYFBQMCAgECAgMDBAUFBQYGBgYHCAsLCgkIBwcMBwcHBwoKDAcPERMZDQ0MDAsKCQgHBgUEAwEBAQICAgMEBAsMDQ8bTSIfGxkMCwsKCQgIBwYFBQMCAgICBAQGBggICQoLDA0NDw8PERERExIUHxwb/bsBAgMEBQcHCQUDAQEBAQMFBQYICAkLCwwNDg8QEBESEhMUFBUWFRcWGBcYGBYWFRUPDxAQEBEREQ4ODg0NDQ0MDAwMCwoLCgkJCQgHBwcGBgQFAwMDAgEBAQIDBAUGBgQEAgIDBAUHBwkJCgwMDQ4PDxERERMTFBQVFRYWFxcYGBgUFRQTEBESEhITFBMODg4NDQ0NDA0LDAsKCwoJCQkIBwcHBgYEBQMDAwIBAzcECAoLDAwNDQ4NDg0NBgYGBQYKBQQDAwICAQECBAUHDSEODQoEBAMCAgIBAQICAwMEBQUFBQYGBgYGCAcHBgYFBQUIBx0GDAgJCgsNDg8JCAkKCgsLCwwPDg0ODQwMDAsLCgoICAgHBgUEBAMCAQEBAgIEBQYICAYIBwkJCQoKCwsLCgsLCgoHBgYGBQUFBQQEAwMCAQEBAgUGCAkLGg0LCgkICAYDBAMCAQIDBAQFBgYGBwcIBwkIDQcFBgUEBQgIBgYHEgkJCgoHBgcICAkJCgoLDAwMDg0NDQ0MDAsLCgoKCQgIBwYGBQQEAwMBAQEBAwRbEhMSEREREBAXFxgYGBgYFxcWFhUVFBQTExEREQ8PDg0MDAoKCAcHBQQDAgICAwcGBgUDAwEBAQIDAwMFBAYGBwcHCAkJCQoLCgsMDAwMDQ0NDQ4ODhAQEA8PDw4OGBoZGhgYFxgWFxUWFRQUExISERAQDw4NDAsLCQkHBgUFAwEBAgIDCggHBgUDAgEBAgMDAwUEBgYGCAcICQkJCgoLCwwLDQwNDQ0NDg4AAAAACwAAAAAD8wOYABEAMwBbAKYAywDTARcBOQFjAZgBoQAAAQ8DMzcvBisBDwEnDwIdAh8FOwE/BjUvBisBDwEnFwcfBDM/Bic1MxUnNw8GIy8HNyclHwsVIxUfBjsBPwY1MxcVDw0vCzU/CycVPwMfCR0CDwgjLwQPAREjFSMVIzUjNTcPCxUfDyE/DzUvDiMhIw8BJR8DFQ8GKwEvBjU/Bx8DFR8KPwUHMzUjFQ8GKwEvBjUjDwcdAR8LOwE/CTUvDg8DFTM1NyMHJyMDIgQDAgJCAgECAwQFBQYGCgUG2QQDAgIDBAUFBQYGBQYEBQICAQECAgUEBgUGBgUF6wEBAwUCAwMEBwgEAgEBAQFFOQEDBAYMDhAQDwgGBgYFAgIEAQECHQoLCgkJCAcFBAMCAXcBAQMDBQQFBhAGBQQEAgIBMwMBAQMCBAQMBwcICAgIDxAPDg8HBgYEAwMBAQECAgQGBggJCQkJC+UQDg4NDQUGBwcFBAQCAgIDAwUGBgcICQoLBQwNFAQ50VJFRyAPDQ0LCwkJBwMFAwIBAgQGBwkJCwsNDQ8PDxARAqAQEQ8PDw0NCwsKCAcDBQMCAQIEBgcICgsLDQ0PDxAQEP1gERAPAYoEAgIBAQICBAUGBQYGBgUFBAICAQECAwQFBQUGBgUGdgEEAgQEBQQGBwgIBwcGBgoKAUw7AQEDAwQEBQUFBQQEAwIBAUC+CggGBgMCAgICBAMECgYHCQsLCwwMCwoSBwcHCAUEAgEBAgIEAwQHBwgJCgsMDg8NDMpKVlAuLVEBbAMEBB8bBQMEAwICAQECCAMDAwOAAwMDAgICAQECAgIDAwOAAwMDAwICAQECF4kgBQUCAQECBAQEAQIDCJrYARsEBAMHBQQCAQICAwQEBRoPmw0BAQIDAwQFBgYMDBgvMgYEAwIDAQEBAQMCAwQEGREGBgUFBQQECQQEAwICAQEBAwYHBQYGBwgJCgpDDwwLCggHBgYDAwMBQFQHBQQBAQICAwUFBQYHBwhwCgkJCAgGBQQDAQEBBAULEgEBIib+/yVJBQUGBwcICQkFCgsK9gsLCgoJCQgHBwYFBQMDAQEBAQMDBQUGBwcICQkFCgoL9woLCgoJCQgHBwYFBQMDAgID9wQEBAV3BAUDBAMCAQECAwQEBAR3BQQEBAMCAQEBAQJ3GAwRBAUEAwMDAQEBAQEBAwcKEuCvAwMDAgMBAQEBAwIDAwOvAgUHCAoKDA0OQxgOBwcGCgQEAgMCAQICBQQFBwsKDxZTCgkHBgYGBQYFBQMDAgEBAQIEPayslG9vAAAAABIA3gABAAAAAAAAAAEAAAABAAAAAAABAAsAAQABAAAAAAACAAcADAABAAAAAAADAAsAEwABAAAAAAAEAAsAHgABAAAAAAAFAAsAKQABAAAAAAAGAAsANAABAAAAAAAKACwAPwABAAAAAAALABIAawADAAEECQAAAAIAfQADAAEECQABABYAfwADAAEECQACAA4AlQADAAEECQADABYAowADAAEECQAEABYAuQADAAEECQAFABYAzwADAAEECQAGABYA5QADAAEECQAKAFgA+wADAAEECQALACQBUyBTb2NpYWxpY29uc1JlZ3VsYXJTb2NpYWxpY29uc1NvY2lhbGljb25zVmVyc2lvbiAxLjBTb2NpYWxpY29uc0ZvbnQgZ2VuZXJhdGVkIHVzaW5nIFN5bmNmdXNpb24gTWV0cm8gU3R1ZGlvd3d3LnN5bmNmdXNpb24uY29tACAAUwBvAGMAaQBhAGwAaQBjAG8AbgBzAFIAZQBnAHUAbABhAHIAUwBvAGMAaQBhAGwAaQBjAG8AbgBzAFMAbwBjAGkAYQBsAGkAYwBvAG4AcwBWAGUAcgBzAGkAbwBuACAAMQAuADAAUwBvAGMAaQBhAGwAaQBjAG8AbgBzAEYAbwBuAHQAIABnAGUAbgBlAHIAYQB0AGUAZAAgAHUAcwBpAG4AZwAgAFMAeQBuAGMAZgB1AHMAaQBvAG4AIABNAGUAdAByAG8AIABTAHQAdQBkAGkAbwB3AHcAdwAuAHMAeQBuAGMAZgB1AHMAaQBvAG4ALgBjAG8AbQAAAAACAAAAAAAAAAoAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAsBAgEDAQQBBQEGAQcBCAEJAQoBCwEMAAh3aGF0c2FwcAd0d2l0dGVyBXZpbWVvCWluc3RhZ3JhbQhsaW5rZWRpbghmYWNlYm9vawtnb29nbGUtcGx1cwZ0dW1ibHIIc2t5cGUtMDEIeW91dHViZTEAAAA=) format('truetype'); + font-weight: normal; + font-style: normal; +} + +.e-content .e-item { + font-size: 12px; + margin: 10px; + text-align: justify; +} + +#form-container { + margin: 0 auto; + max-width: 300px; +} + +.btn-section { + text-align: center; +} + +.add-tab-btn-section td { + padding: 10px; +} + +.info { + font-weight: bold; +} + +.e-add-icon::before { + content: '\e823'; +} \ No newline at end of file diff --git a/ej2-angular/samples/tab/dynamic-tab-cs1/index.html b/ej2-angular/samples/tab/dynamic-tab-cs1/index.html new file mode 100644 index 0000000000..03370ee1bd --- /dev/null +++ b/ej2-angular/samples/tab/dynamic-tab-cs1/index.html @@ -0,0 +1,47 @@ + + + + Angular Tab + + + + + + + + + +
+ + + +
LOADING....
+
+
+ + \ No newline at end of file diff --git a/ej2-angular/samples/tab/dynamic-tab-cs1/main.79c03e32490f7316.js b/ej2-angular/samples/tab/dynamic-tab-cs1/main.79c03e32490f7316.js new file mode 100644 index 0000000000..79d6dd32e8 --- /dev/null +++ b/ej2-angular/samples/tab/dynamic-tab-cs1/main.79c03e32490f7316.js @@ -0,0 +1 @@ +"use strict";(self.webpackChunksyncfusion_component=self.webpackChunksyncfusion_component||[]).push([[179],{145:(Ro,cc,uc)=>{let $i=null,Da=1;const ts=Symbol("SIGNAL");function ni(s){const i=$i;return $i=s,i}function ln(s){if((!wa(s)||s.dirty)&&(s.dirty||s.lastCleanEpoch!==Da)){if(!s.producerMustRecompute(s)&&!Ta(s))return s.dirty=!1,void(s.lastCleanEpoch=Da);s.producerRecomputeValue(s),s.dirty=!1,s.lastCleanEpoch=Da}}function Ta(s){_o(s);for(let i=0;i0}function _o(s){s.producerNode??=[],s.producerIndexOfThis??=[],s.producerLastReadVersion??=[]}let mc=null;function cn(s){return"function"==typeof s}function vc(s){const e=s(t=>{Error.call(t),t.stack=(new Error).stack});return e.prototype=Object.create(Error.prototype),e.prototype.constructor=e,e}const bh=vc(s=>function(e){s(this),this.message=e?`${e.length} errors occurred during unsubscription:\n${e.map((t,n)=>`${n+1}) ${t.toString()}`).join("\n ")}`:"",this.name="UnsubscriptionError",this.errors=e});function Mh(s,i){if(s){const e=s.indexOf(i);0<=e&&s.splice(e,1)}}class is{constructor(i){this.initialTeardown=i,this.closed=!1,this._parentage=null,this._finalizers=null}unsubscribe(){let i;if(!this.closed){this.closed=!0;const{_parentage:e}=this;if(e)if(this._parentage=null,Array.isArray(e))for(const r of e)r.remove(this);else e.remove(this);const{initialTeardown:t}=this;if(cn(t))try{t()}catch(r){i=r instanceof bh?r.errors:[r]}const{_finalizers:n}=this;if(n){this._finalizers=null;for(const r of n)try{af(r)}catch(o){i=i??[],o instanceof bh?i=[...i,...o.errors]:i.push(o)}}if(i)throw new bh(i)}}add(i){var e;if(i&&i!==this)if(this.closed)af(i);else{if(i instanceof is){if(i.closed||i._hasParent(this))return;i._addParent(this)}(this._finalizers=null!==(e=this._finalizers)&&void 0!==e?e:[]).push(i)}}_hasParent(i){const{_parentage:e}=this;return e===i||Array.isArray(e)&&e.includes(i)}_addParent(i){const{_parentage:e}=this;this._parentage=Array.isArray(e)?(e.push(i),e):e?[e,i]:i}_removeParent(i){const{_parentage:e}=this;e===i?this._parentage=null:Array.isArray(e)&&Mh(e,i)}remove(i){const{_finalizers:e}=this;e&&Mh(e,i),i instanceof is&&i._removeParent(this)}}is.EMPTY=(()=>{const s=new is;return s.closed=!0,s})();const Fo=is.EMPTY;function of(s){return s instanceof is||s&&"closed"in s&&cn(s.remove)&&cn(s.add)&&cn(s.unsubscribe)}function af(s){cn(s)?s():s.unsubscribe()}const Ho={onUnhandledError:null,onStoppedNotification:null,Promise:void 0,useDeprecatedSynchronousErrorHandling:!1,useDeprecatedNextContext:!1},x={setTimeout(s,i,...e){const{delegate:t}=x;return t?.setTimeout?t.setTimeout(s,i,...e):setTimeout(s,i,...e)},clearTimeout(s){const{delegate:i}=x;return(i?.clearTimeout||clearTimeout)(s)},delegate:void 0};function ee(){}const X=je("C",void 0,void 0);function je(s,i,e){return{kind:s,value:i,error:e}}let Le=null;function tt(s){if(Ho.useDeprecatedSynchronousErrorHandling){const i=!Le;if(i&&(Le={errorThrown:!1,error:null}),s(),i){const{errorThrown:e,error:t}=Le;if(Le=null,e)throw t}}else s()}class Fe extends is{constructor(i){super(),this.isStopped=!1,i?(this.destination=i,of(i)&&i.add(this)):this.destination=gt}static create(i,e,t){return new yi(i,e,t)}next(i){this.isStopped?zi(function ce(s){return je("N",s,void 0)}(i),this):this._next(i)}error(i){this.isStopped?zi(function ne(s){return je("E",void 0,s)}(i),this):(this.isStopped=!0,this._error(i))}complete(){this.isStopped?zi(X,this):(this.isStopped=!0,this._complete())}unsubscribe(){this.closed||(this.isStopped=!0,super.unsubscribe(),this.destination=null)}_next(i){this.destination.next(i)}_error(i){try{this.destination.error(i)}finally{this.unsubscribe()}}_complete(){try{this.destination.complete()}finally{this.unsubscribe()}}}const Vt=Function.prototype.bind;function St(s,i){return Vt.call(s,i)}class Pt{constructor(i){this.partialObserver=i}next(i){const{partialObserver:e}=this;if(e.next)try{e.next(i)}catch(t){$t(t)}}error(i){const{partialObserver:e}=this;if(e.error)try{e.error(i)}catch(t){$t(t)}else $t(i)}complete(){const{partialObserver:i}=this;if(i.complete)try{i.complete()}catch(e){$t(e)}}}class yi extends Fe{constructor(i,e,t){let n;if(super(),cn(i)||!i)n={next:i??void 0,error:e??void 0,complete:t??void 0};else{let r;this&&Ho.useDeprecatedNextContext?(r=Object.create(i),r.unsubscribe=()=>this.unsubscribe(),n={next:i.next&&St(i.next,r),error:i.error&&St(i.error,r),complete:i.complete&&St(i.complete,r)}):n=i}this.destination=new Pt(n)}}function $t(s){Ho.useDeprecatedSynchronousErrorHandling?function it(s){Ho.useDeprecatedSynchronousErrorHandling&&Le&&(Le.errorThrown=!0,Le.error=s)}(s):function V(s){x.setTimeout(()=>{const{onUnhandledError:i}=Ho;if(!i)throw s;i(s)})}(s)}function zi(s,i){const{onStoppedNotification:e}=Ho;e&&x.setTimeout(()=>e(s,i))}const gt={closed:!0,next:ee,error:function Fn(s){throw s},complete:ee},xe="function"==typeof Symbol&&Symbol.observable||"@@observable";function Tn(s){return s}let mt=(()=>{class s{constructor(e){e&&(this._subscribe=e)}lift(e){const t=new s;return t.source=this,t.operator=e,t}subscribe(e,t,n){const r=function Ae(s){return s&&s instanceof Fe||function bi(s){return s&&cn(s.next)&&cn(s.error)&&cn(s.complete)}(s)&&of(s)}(e)?e:new yi(e,t,n);return tt(()=>{const{operator:o,source:a}=this;r.add(o?o.call(r,a):a?this._subscribe(r):this._trySubscribe(r))}),r}_trySubscribe(e){try{return this._subscribe(e)}catch(t){e.error(t)}}forEach(e,t){return new(t=Re(t))((n,r)=>{const o=new yi({next:a=>{try{e(a)}catch(l){r(l),o.unsubscribe()}},error:r,complete:n});this.subscribe(o)})}_subscribe(e){var t;return null===(t=this.source)||void 0===t?void 0:t.subscribe(e)}[xe](){return this}pipe(...e){return function Gi(s){return 0===s.length?Tn:1===s.length?s[0]:function(e){return s.reduce((t,n)=>n(t),e)}}(e)(this)}toPromise(e){return new(e=Re(e))((t,n)=>{let r;this.subscribe(o=>r=o,o=>n(o),()=>t(r))})}}return s.create=i=>new s(i),s})();function Re(s){var i;return null!==(i=s??Ho.Promise)&&void 0!==i?i:Promise}const zt=vc(s=>function(){s(this),this.name="ObjectUnsubscribedError",this.message="object unsubscribed"});let ot=(()=>{class s extends mt{constructor(){super(),this.closed=!1,this.currentObservers=null,this.observers=[],this.isStopped=!1,this.hasError=!1,this.thrownError=null}lift(e){const t=new Hn(this,this);return t.operator=e,t}_throwIfClosed(){if(this.closed)throw new zt}next(e){tt(()=>{if(this._throwIfClosed(),!this.isStopped){this.currentObservers||(this.currentObservers=Array.from(this.observers));for(const t of this.currentObservers)t.next(e)}})}error(e){tt(()=>{if(this._throwIfClosed(),!this.isStopped){this.hasError=this.isStopped=!0,this.thrownError=e;const{observers:t}=this;for(;t.length;)t.shift().error(e)}})}complete(){tt(()=>{if(this._throwIfClosed(),!this.isStopped){this.isStopped=!0;const{observers:e}=this;for(;e.length;)e.shift().complete()}})}unsubscribe(){this.isStopped=this.closed=!0,this.observers=this.currentObservers=null}get observed(){var e;return(null===(e=this.observers)||void 0===e?void 0:e.length)>0}_trySubscribe(e){return this._throwIfClosed(),super._trySubscribe(e)}_subscribe(e){return this._throwIfClosed(),this._checkFinalizedStatuses(e),this._innerSubscribe(e)}_innerSubscribe(e){const{hasError:t,isStopped:n,observers:r}=this;return t||n?Fo:(this.currentObservers=null,r.push(e),new is(()=>{this.currentObservers=null,Mh(r,e)}))}_checkFinalizedStatuses(e){const{hasError:t,thrownError:n,isStopped:r}=this;t?e.error(n):r&&e.complete()}asObservable(){const e=new mt;return e.source=this,e}}return s.create=(i,e)=>new Hn(i,e),s})();class Hn extends ot{constructor(i,e){super(),this.destination=i,this.source=e}next(i){var e,t;null===(t=null===(e=this.destination)||void 0===e?void 0:e.next)||void 0===t||t.call(e,i)}error(i){var e,t;null===(t=null===(e=this.destination)||void 0===e?void 0:e.error)||void 0===t||t.call(e,i)}complete(){var i,e;null===(e=null===(i=this.destination)||void 0===i?void 0:i.complete)||void 0===e||e.call(i)}_subscribe(i){var e,t;return null!==(t=null===(e=this.source)||void 0===e?void 0:e.subscribe(i))&&void 0!==t?t:Fo}}class sr extends ot{constructor(i){super(),this._value=i}get value(){return this.getValue()}_subscribe(i){const e=super._subscribe(i);return!e.closed&&i.next(this._value),e}getValue(){const{hasError:i,thrownError:e,_value:t}=this;if(i)throw e;return this._throwIfClosed(),t}next(i){super.next(this._value=i)}}class ns extends Fe{constructor(i,e,t,n,r,o){super(i),this.onFinalize=r,this.shouldUnsubscribe=o,this._next=e?function(a){try{e(a)}catch(l){i.error(l)}}:super._next,this._error=n?function(a){try{n(a)}catch(l){i.error(l)}finally{this.unsubscribe()}}:super._error,this._complete=t?function(){try{t()}catch(a){i.error(a)}finally{this.unsubscribe()}}:super._complete}unsubscribe(){var i;if(!this.shouldUnsubscribe||this.shouldUnsubscribe()){const{closed:e}=this;super.unsubscribe(),!e&&(null===(i=this.onFinalize)||void 0===i||i.call(this))}}}function Li(s,i){return function Ai(s){return i=>{if(function nn(s){return cn(s?.lift)}(i))return i.lift(function(e){try{return s(e,this)}catch(t){this.error(t)}});throw new TypeError("Unable to lift unknown Observable type")}}((e,t)=>{let n=0;e.subscribe(function Cs(s,i,e,t,n){return new ns(s,i,e,t,n)}(t,r=>{t.next(s.call(i,r,n++))}))})}class E extends Error{constructor(i,e){super(function W(s,i){return`NG0${Math.abs(s)}${i?": "+i:""}`}(i,e)),this.code=i}}function Ee(s){for(let i in s)if(s[i]===Ee)return i;throw Error("Could not find renamed property on target object.")}function Ve(s,i){for(const e in i)i.hasOwnProperty(e)&&!s.hasOwnProperty(e)&&(s[e]=i[e])}function ze(s){if("string"==typeof s)return s;if(Array.isArray(s))return"["+s.map(ze).join(", ")+"]";if(null==s)return""+s;if(s.overriddenName)return`${s.overriddenName}`;if(s.name)return`${s.name}`;const i=s.toString();if(null==i)return""+i;const e=i.indexOf("\n");return-1===e?i:i.substring(0,e)}function Mt(s,i){return null==s||""===s?null===i?"":i:null==i||""===i?s:s+" "+i}const Mi=Ee({__forward_ref__:Ee});function Ze(s){return s.__forward_ref__=Ze,s.toString=function(){return ze(this())},s}function He(s){return function yn(s){return"function"==typeof s&&s.hasOwnProperty(Mi)&&s.__forward_ref__===Ze}(s)?s():s}function Bo(s){return s&&!!s.\u0275providers}const Vo=Ee({\u0275cmp:Ee}),yc=Ee({\u0275dir:Ee}),Ch=Ee({\u0275pipe:Ee}),rr=Ee({\u0275fac:Ee}),or=Ee({__NG_ELEMENT_ID__:Ee}),Ih=Ee({__NG_ENV_ID__:Ee});function Zt(s){return"function"==typeof s?s.name||s.toString():"object"==typeof s&&null!=s&&"function"==typeof s.type?s.type.name||s.type.toString():function nt(s){return"string"==typeof s?s:null==s?"":String(s)}(s)}function Ny(s,i){throw new E(-201,!1)}function Rs(s,i){null==s&&function at(s,i,e,t){throw new Error(`ASSERTION ERROR: ${s}`+(null==t?"":` [Expected=> ${e} ${t} ${i} <=Actual]`))}(i,s,null,"!=")}function Kt(s){return{token:s.token,providedIn:s.providedIn||null,factory:s.factory,value:void 0}}function ml(s){return{providers:s.providers||[],imports:s.imports||[]}}function lf(s){return BD(s,uf)||BD(s,VD)}function BD(s,i){return s.hasOwnProperty(i)?s[i]:null}function cf(s){return s&&(s.hasOwnProperty(Ty)||s.hasOwnProperty(w_))?s[Ty]:null}const uf=Ee({\u0275prov:Ee}),Ty=Ee({\u0275inj:Ee}),VD=Ee({ngInjectableDef:Ee}),w_=Ee({ngInjectorDef:Ee});var Ut=function(s){return s[s.Default=0]="Default",s[s.Host=1]="Host",s[s.Self=2]="Self",s[s.SkipSelf=4]="SkipSelf",s[s.Optional=8]="Optional",s}(Ut||{});let wy;function Ps(s){const i=wy;return wy=s,i}function WD(s,i,e){const t=lf(s);return t&&"root"==t.providedIn?void 0===t.value?t.value=t.factory():t.value:e&Ut.Optional?null:void 0!==i?i:void Ny()}const fi=globalThis;class Xe{constructor(i,e){this._desc=i,this.ngMetadataName="InjectionToken",this.\u0275prov=void 0,"number"==typeof e?this.__NG_ELEMENT_ID__=e:void 0!==e&&(this.\u0275prov=Kt({token:this,providedIn:e.providedIn||"root",factory:e.factory}))}get multi(){return this}toString(){return`InjectionToken ${this._desc}`}}const Eh={},ky="__NG_DI_FLAG__",hf="ngTempTokenPath",O_=/\n/gm,QD="__source";let Mc;function Oa(s){const i=Mc;return Mc=s,i}function j_(s,i=Ut.Default){if(void 0===Mc)throw new E(-203,!1);return null===Mc?WD(s,void 0,i):Mc.get(s,i&Ut.Optional?null:void 0,i)}function Jt(s,i=Ut.Default){return(function UD(){return wy}()||j_)(He(s),i)}function Wt(s,i=Ut.Default){return Jt(s,df(i))}function df(s){return typeof s>"u"||"number"==typeof s?s:0|(s.optional&&8)|(s.host&&1)|(s.self&&2)|(s.skipSelf&&4)}function jy(s){const i=[];for(let e=0;ei){o=r-1;break}}}for(;rr?"":n[h+1].toLowerCase();const f=8&t?p:null;if(f&&-1!==$D(f,c,0)||2&t&&c!==p){if(xr(t))return!1;o=!0}}}}else{if(!o&&!xr(t)&&!xr(l))return!1;if(o&&xr(l))continue;o=!1,t=l|1&t}}return xr(t)||o}function xr(s){return 0==(1&s)}function B_(s,i,e,t){if(null===i)return-1;let n=0;if(t||!e){let r=!1;for(;n-1)for(e++;e0?'="'+a+'"':"")+"]"}else 8&t?n+="."+o:4&t&&(n+=" "+o);else""!==n&&!xr(o)&&(i+=tS(r,n),n=""),t=o,r=r||!xr(t);e++}return""!==n&&(i+=tS(r,n)),i}function Py(s){return Uo(()=>{const i=nS(s),e={...i,decls:s.decls,vars:s.vars,template:s.template,consts:s.consts||null,ngContentSelectors:s.ngContentSelectors,onPush:s.changeDetection===pf.OnPush,directiveDefs:null,pipeDefs:null,dependencies:i.standalone&&s.dependencies||null,getStandaloneInjector:null,signals:s.signals??!1,data:s.data||{},encapsulation:s.encapsulation||Or.Emulated,styles:s.styles||si,_:null,schemas:s.schemas||null,tView:null,id:""};sS(e);const t=s.dependencies;return e.directiveDefs=ff(t,!1),e.pipeDefs=ff(t,!0),e.id=function K_(s){let i=0;const e=[s.selectors,s.ngContentSelectors,s.hostVars,s.hostAttrs,s.consts,s.vars,s.decls,s.encapsulation,s.standalone,s.signals,s.exportAs,JSON.stringify(s.inputs),JSON.stringify(s.outputs),Object.getOwnPropertyNames(s.type.prototype),!!s.contentQueries,!!s.viewQuery].join("|");for(const n of e)i=Math.imul(31,i)+n.charCodeAt(0)<<0;return i+=2147483648,"c"+i}(e),e})}function G_(s){return At(s)||An(s)}function Z_(s){return null!==s}function Cc(s){return Uo(()=>({type:s.type,bootstrap:s.bootstrap||si,declarations:s.declarations||si,imports:s.imports||si,exports:s.exports||si,transitiveCompileScopes:null,schemas:s.schemas||null,id:s.id||null}))}function iS(s,i){if(null==s)return so;const e={};for(const t in s)if(s.hasOwnProperty(t)){const n=s[t];let r,o,a=sn.None;Array.isArray(n)?(a=n[0],r=n[1],o=n[2]??r):(r=n,o=n),i?(e[r]=a!==sn.None?[t,a]:t,i[r]=o):e[r]=t}return e}function ut(s){return Uo(()=>{const i=nS(s);return sS(i),i})}function At(s){return s[Vo]||null}function An(s){return s[yc]||null}function Qn(s){return s[Ch]||null}function nS(s){const i={};return{type:s.type,providersResolver:null,factory:null,hostBindings:s.hostBindings||null,hostVars:s.hostVars||0,hostAttrs:s.hostAttrs||null,contentQueries:s.contentQueries||null,declaredInputs:i,inputTransforms:null,inputConfig:s.inputs||so,exportAs:s.exportAs||null,standalone:!0===s.standalone,signals:!0===s.signals,selectors:s.selectors||si,viewQuery:s.viewQuery||null,features:s.features||null,setInput:null,findHostDirectiveDefs:null,hostDirectives:null,inputs:iS(s.inputs,i),outputs:iS(s.outputs),debugInfo:null}}function sS(s){s.features?.forEach(i=>i(s))}function ff(s,i){if(!s)return null;const e=i?Qn:G_;return()=>("function"==typeof s?s():s).map(t=>e(t)).filter(Z_)}const Ui=0,fe=1,Ke=2,un=3,kr=4,rs=5,jr=6,Ic=7,Oi=8,Is=9,Wo=10,vt=11,Nh=12,rS=13,Ec=14,Zi=15,Th=16,Dc=17,ro=18,wh=19,oS=20,xa=21,gf=22,yl=23,pt=25,zy=1,oo=7,Sc=9,hn=10;var _y=function(s){return s[s.None=0]="None",s[s.HasTransplantedViews=2]="HasTransplantedViews",s}(_y||{});function os(s){return Array.isArray(s)&&"object"==typeof s[zy]}function as(s){return Array.isArray(s)&&!0===s[zy]}function Fy(s){return 0!=(4&s.flags)}function bl(s){return s.componentOffset>-1}function vf(s){return 1==(1&s.flags)}function Rr(s){return!!s.template}function Hy(s){return 0!=(512&s[Ke])}function Ml(s,i){return s.hasOwnProperty(rr)?s[rr]:null}class i4{constructor(i,e,t){this.previousValue=i,this.currentValue=e,this.firstChange=t}isFirstChange(){return this.firstChange}}function uS(s,i,e,t){null!==i?i.applyValueToInputSignal(i,t):s[e]=t}function hS(s){return s.type.prototype.ngOnChanges&&(s.setInput=s4),n4}function n4(){const s=pS(this),i=s?.current;if(i){const e=s.previous;if(e===so)s.previous=i;else for(let t in i)e[t]=i[t];s.current=null,this.ngOnChanges(i)}}function s4(s,i,e,t,n){const r=this.declaredInputs[t],o=pS(s)||function r4(s,i){return s[dS]=i}(s,{previous:so,current:null}),a=o.current||(o.current={}),l=o.previous,c=l[r];a[r]=new i4(c&&c.currentValue,e,l===so),uS(s,i,n,e)}const dS="__ngSimpleChanges__";function pS(s){return s[dS]||null}const ao=function(s,i,e){};let mS=!1;function Ci(s){for(;Array.isArray(s);)s=s[Ui];return s}function Es(s,i){return Ci(i[s.index])}function Oh(s,i){return s.data[i]}function Zs(s,i){const e=i[s];return os(e)?e:e[Ui]}function Yy(s){return 128==(128&s[Ke])}function lo(s,i){return null==i?null:s[i]}function vS(s){s[Dc]=0}function h4(s){1024&s[Ke]||(s[Ke]|=1024,Yy(s)&&xh(s))}function bS(s){return 9216&s[Ke]||s[yl]?.dirty}function Qy(s){bS(s)?xh(s):64&s[Ke]&&(function a4(){return mS}()?(s[Ke]|=1024,xh(s)):s[Wo].changeDetectionScheduler?.notify())}function xh(s){s[Wo].changeDetectionScheduler?.notify();let i=Cl(s);for(;null!==i&&!(8192&i[Ke])&&(i[Ke]|=8192,Yy(i));)i=Cl(i)}function Cl(s){const i=s[un];return as(i)?i[un]:i}const lt={lFrame:AS(null),bindingsEnabled:!0,skipHydrationRootTNode:null};function CS(){return lt.bindingsEnabled}function Tc(){return null!==lt.skipHydrationRootTNode}function te(){return lt.lFrame.lView}function Yt(){return lt.lFrame.tView}function Ii(){let s=IS();for(;null!==s&&64===s.type;)s=s.parent;return s}function IS(){return lt.lFrame.currentTNode}function co(s,i){const e=lt.lFrame;e.currentTNode=s,e.isParent=i}function $y(){return lt.lFrame.isParent}function Gy(){lt.lFrame.isParent=!1}function D4(s,i){const e=lt.lFrame;e.bindingIndex=e.bindingRootIndex=s,Zy(i)}function Zy(s){lt.lFrame.currentDirectiveIndex=s}function NS(){return lt.lFrame.currentQueryIndex}function Ky(s){lt.lFrame.currentQueryIndex=s}function N4(s){const i=s[fe];return 2===i.type?i.declTNode:1===i.type?s[rs]:null}function TS(s,i,e){if(e&Ut.SkipSelf){let n=i,r=s;for(;!(n=n.parent,null!==n||e&Ut.Host||(n=N4(r),null===n||(r=r[Ec],10&n.type))););if(null===n)return!1;i=n,s=r}const t=lt.lFrame=wS();return t.currentTNode=i,t.lView=s,!0}function Jy(s){const i=wS(),e=s[fe];lt.lFrame=i,i.currentTNode=e.firstChild,i.lView=s,i.tView=e,i.contextLView=s,i.bindingIndex=e.bindingStartIndex,i.inI18n=!1}function wS(){const s=lt.lFrame,i=null===s?null:s.child;return null===i?AS(s):i}function AS(s){const i={currentTNode:null,isParent:!0,lView:null,tView:null,selectedIndex:-1,contextLView:null,elementDepthCount:0,currentNamespace:null,currentDirectiveIndex:-1,bindingRootIndex:-1,bindingIndex:-1,currentQueryIndex:0,parent:s,child:null,inI18n:!1};return null!==s&&(s.child=i),i}function LS(){const s=lt.lFrame;return lt.lFrame=s.parent,s.currentTNode=null,s.lView=null,s}const OS=LS;function eb(){const s=LS();s.isParent=!0,s.tView=null,s.selectedIndex=-1,s.contextLView=null,s.elementDepthCount=0,s.currentDirectiveIndex=-1,s.currentNamespace=null,s.bindingRootIndex=-1,s.bindingIndex=-1,s.currentQueryIndex=0}function ls(){return lt.lFrame.selectedIndex}function Il(s){lt.lFrame.selectedIndex=s}let kS=!0;function Mf(s,i){for(let e=i.directiveStart,t=i.directiveEnd;e=t)break}else i[l]<0&&(s[Dc]+=65536),(a>14>16&&(3&s[Ke])===i&&(s[Ke]+=16384,RS(a,r)):RS(a,r)}const wc=-1;class jh{constructor(i,e,t){this.factory=i,this.resolving=!1,this.canSeeViewProviders=e,this.injectImpl=t}}function nb(s){return s!==wc}function Rh(s){return 32767&s}function Ph(s,i){let e=function _4(s){return s>>16}(s),t=i;for(;e>0;)t=t[Ec],e--;return t}let sb=!0;function Ef(s){const i=sb;return sb=s,i}const PS=255,zS=5;let F4=0;const ho={};function Df(s,i){const e=_S(s,i);if(-1!==e)return e;const t=i[fe];t.firstCreatePass&&(s.injectorIndex=i.length,rb(t.data,s),rb(i,null),rb(t.blueprint,null));const n=Sf(s,i),r=s.injectorIndex;if(nb(n)){const o=Rh(n),a=Ph(n,i),l=a[fe].data;for(let c=0;c<8;c++)i[r+c]=a[o+c]|l[o+c]}return i[r+8]=n,r}function rb(s,i){s.push(0,0,0,0,0,0,0,0,i)}function _S(s,i){return-1===s.injectorIndex||s.parent&&s.parent.injectorIndex===s.injectorIndex||null===i[s.injectorIndex+8]?-1:s.injectorIndex}function Sf(s,i){if(s.parent&&-1!==s.parent.injectorIndex)return s.parent.injectorIndex;let e=0,t=null,n=i;for(;null!==n;){if(t=YS(n),null===t)return wc;if(e++,n=n[Ec],-1!==t.injectorIndex)return t.injectorIndex|e<<16}return wc}function ob(s,i,e){!function H4(s,i,e){let t;"string"==typeof e?t=e.charCodeAt(0)||0:e.hasOwnProperty(or)&&(t=e[or]),null==t&&(t=e[or]=F4++);const n=t&PS;i.data[s+(n>>zS)]|=1<=0?i&PS:W4:i}(e);if("function"==typeof r){if(!TS(i,s,t))return t&Ut.Host?FS(n,0,t):HS(i,e,t,n);try{let o;if(o=r(t),null!=o||t&Ut.Optional)return o;Ny()}finally{OS()}}else if("number"==typeof r){let o=null,a=_S(s,i),l=wc,c=t&Ut.Host?i[Zi][rs]:null;for((-1===a||t&Ut.SkipSelf)&&(l=-1===a?Sf(s,i):i[a+8],l!==wc&&WS(t,!1)?(o=i[fe],a=Rh(l),i=Ph(l,i)):a=-1);-1!==a;){const u=i[fe];if(US(r,a,u.data)){const h=V4(a,i,e,o,t,c);if(h!==ho)return h}l=i[a+8],l!==wc&&WS(t,i[fe].data[a+8]===c)&&US(r,a,i)?(o=u,a=Rh(l),i=Ph(l,i)):a=-1}}return n}function V4(s,i,e,t,n,r){const o=i[fe],a=o.data[s+8],u=Nf(a,o,e,null==t?bl(a)&&sb:t!=o&&0!=(3&a.type),n&Ut.Host&&r===a);return null!==u?El(i,o,u,a):ho}function Nf(s,i,e,t,n){const r=s.providerIndexes,o=i.data,a=1048575&r,l=s.directiveStart,u=r>>20,p=n?a+u:s.directiveEnd;for(let f=t?a:a+u;f=l&&g.type===e)return f}if(n){const f=o[l];if(f&&Rr(f)&&f.type===e)return l}return null}function El(s,i,e,t){let n=s[e];const r=i.data;if(function j4(s){return s instanceof jh}(n)){const o=n;o.resolving&&function ar(s,i){const e=i?`. Dependency path: ${i.join(" > ")} > ${s}`:"";throw new E(-200,`Circular dependency in DI detected for ${s}${e}`)}(Zt(r[e]));const a=Ef(o.canSeeViewProviders);o.resolving=!0;const c=o.injectImpl?Ps(o.injectImpl):null;TS(s,t,Ut.Default);try{n=s[e]=o.factory(void 0,r,s,t),i.firstCreatePass&&e>=t.directiveStart&&function x4(s,i,e){const{ngOnChanges:t,ngOnInit:n,ngDoCheck:r}=i.type.prototype;if(t){const o=hS(i);(e.preOrderHooks??=[]).push(s,o),(e.preOrderCheckHooks??=[]).push(s,o)}n&&(e.preOrderHooks??=[]).push(0-s,n),r&&((e.preOrderHooks??=[]).push(s,r),(e.preOrderCheckHooks??=[]).push(s,r))}(e,r[e],i)}finally{null!==c&&Ps(c),Ef(a),o.resolving=!1,OS()}}return n}function US(s,i,e){return!!(e[i+(s>>zS)]&1<Array.isArray(e)?Pc(e,i):i(e))}function qS(s,i,e){i>=s.length?s.push(e):s.splice(i,0,e)}function Tf(s,i){return i>=s.length-1?s.pop():s.splice(i,1)[0]}const Fc=new Xe(""),JS=new Xe("",-1),mb=new Xe("");class Of{get(i,e=Eh){if(e===Eh){const t=new Error(`NullInjectorError: No provider for ${ze(i)}!`);throw t.name="NullInjectorError",t}return e}}function p2(...s){return{\u0275providers:eN(0,s),\u0275fromNgModule:!0}}function eN(s,...i){const e=[],t=new Set;let n;const r=o=>{e.push(o)};return Pc(i,o=>{const a=o;xf(a,r,[],t)&&(n||=[],n.push(a))}),void 0!==n&&tN(n,r),e}function tN(s,i){for(let e=0;e{i(r,t)})}}function xf(s,i,e,t){if(!(s=He(s)))return!1;let n=null,r=cf(s);const o=!r&&At(s);if(r||o){if(o&&!o.standalone)return!1;n=s}else{const l=s.ngModule;if(r=cf(l),!r)return!1;n=l}const a=t.has(n);if(o){if(a)return!1;if(t.add(n),o.dependencies){const l="function"==typeof o.dependencies?o.dependencies():o.dependencies;for(const c of l)xf(c,i,e,t)}}else{if(!r)return!1;{if(null!=r.imports&&!a){let c;t.add(n);try{Pc(r.imports,u=>{xf(u,i,e,t)&&(c||=[],c.push(u))})}finally{}void 0!==c&&tN(c,i)}if(!a){const c=Ml(n)||(()=>new n);i({provide:n,useFactory:c,deps:si},n),i({provide:mb,useValue:n,multi:!0},n),i({provide:Fc,useValue:()=>Jt(n),multi:!0},n)}const l=r.providers;if(null!=l&&!a){const c=s;yb(l,u=>{i(u,c)})}}}return n!==s&&void 0!==s.providers}function yb(s,i){for(let e of s)Bo(e)&&(e=e.\u0275providers),Array.isArray(e)?yb(e,i):i(e)}const f2=Ee({provide:String,useValue:Ee});function bb(s){return null!==s&&"object"==typeof s&&f2 in s}function Dl(s){return"function"==typeof s}const Mb=new Xe(""),kf={},m2={};let Cb;function jf(){return void 0===Cb&&(Cb=new Of),Cb}class $o{}class Hc extends $o{get destroyed(){return this._destroyed}constructor(i,e,t,n){super(),this.parent=e,this.source=t,this.scopes=n,this.records=new Map,this._ngOnDestroyHooks=new Set,this._onDestroyHooks=[],this._destroyed=!1,Eb(i,o=>this.processProvider(o)),this.records.set(JS,Bc(void 0,this)),n.has("environment")&&this.records.set($o,Bc(void 0,this));const r=this.records.get(Mb);null!=r&&"string"==typeof r.value&&this.scopes.add(r.value),this.injectorDefTypes=new Set(this.get(mb,si,Ut.Self))}destroy(){this.assertNotDestroyed(),this._destroyed=!0;try{for(const e of this._ngOnDestroyHooks)e.ngOnDestroy();const i=this._onDestroyHooks;this._onDestroyHooks=[];for(const e of i)e()}finally{this.records.clear(),this._ngOnDestroyHooks.clear(),this.injectorDefTypes.clear()}}onDestroy(i){return this.assertNotDestroyed(),this._onDestroyHooks.push(i),()=>this.removeOnDestroy(i)}runInContext(i){this.assertNotDestroyed();const e=Oa(this),t=Ps(void 0);try{return i()}finally{Oa(e),Ps(t)}}get(i,e=Eh,t=Ut.Default){if(this.assertNotDestroyed(),i.hasOwnProperty(Ih))return i[Ih](this);t=df(t);const r=Oa(this),o=Ps(void 0);try{if(!(t&Ut.SkipSelf)){let l=this.records.get(i);if(void 0===l){const c=function C2(s){return"function"==typeof s||"object"==typeof s&&s instanceof Xe}(i)&&lf(i);l=c&&this.injectableDefInScope(c)?Bc(Ib(i),kf):null,this.records.set(i,l)}if(null!=l)return this.hydrate(i,l)}return(t&Ut.Self?jf():this.parent).get(i,e=t&Ut.Optional&&e===Eh?null:e)}catch(a){if("NullInjectorError"===a.name){if((a[hf]=a[hf]||[]).unshift(ze(i)),r)throw a;return function P_(s,i,e,t){const n=s[hf];throw i[QD]&&n.unshift(i[QD]),s.message=function z_(s,i,e,t=null){s=s&&"\n"===s.charAt(0)&&"\u0275"==s.charAt(1)?s.slice(2):s;let n=ze(i);if(Array.isArray(i))n=i.map(ze).join(" -> ");else if("object"==typeof i){let r=[];for(let o in i)if(i.hasOwnProperty(o)){let a=i[o];r.push(o+":"+("string"==typeof a?JSON.stringify(a):ze(a)))}n=`{${r.join(", ")}}`}return`${e}${t?"("+t+")":""}[${n}]: ${s.replace(O_,"\n ")}`}("\n"+s.message,n,e,t),s.ngTokenPath=n,s[hf]=null,s}(a,i,"R3InjectorError",this.source)}throw a}finally{Ps(o),Oa(r)}}resolveInjectorInitializers(){const i=Oa(this),e=Ps(void 0);try{const n=this.get(Fc,si,Ut.Self);for(const r of n)r()}finally{Oa(i),Ps(e)}}toString(){const i=[],e=this.records;for(const t of e.keys())i.push(ze(t));return`R3Injector[${i.join(", ")}]`}assertNotDestroyed(){if(this._destroyed)throw new E(205,!1)}processProvider(i){let e=Dl(i=He(i))?i:He(i&&i.provide);const t=function y2(s){return bb(s)?Bc(void 0,s.useValue):Bc(function sN(s,i,e){let t;if(Dl(s)){const n=He(s);return Ml(n)||Ib(n)}if(bb(s))t=()=>He(s.useValue);else if(function nN(s){return!(!s||!s.useFactory)}(s))t=()=>s.useFactory(...jy(s.deps||[]));else if(function iN(s){return!(!s||!s.useExisting)}(s))t=()=>Jt(He(s.useExisting));else{const n=He(s&&(s.useClass||s.provide));if(!function b2(s){return!!s.deps}(s))return Ml(n)||Ib(n);t=()=>new n(...jy(s.deps))}return t}(s),kf)}(i);if(!Dl(i)&&!0===i.multi){let n=this.records.get(e);n||(n=Bc(void 0,kf,!0),n.factory=()=>jy(n.multi),this.records.set(e,n)),e=i,n.multi.push(i)}this.records.set(e,t)}hydrate(i,e){return e.value===kf&&(e.value=m2,e.value=e.factory()),"object"==typeof e.value&&e.value&&function M2(s){return null!==s&&"object"==typeof s&&"function"==typeof s.ngOnDestroy}(e.value)&&this._ngOnDestroyHooks.add(e.value),e.value}injectableDefInScope(i){if(!i.providedIn)return!1;const e=He(i.providedIn);return"string"==typeof e?"any"===e||this.scopes.has(e):this.injectorDefTypes.has(e)}removeOnDestroy(i){const e=this._onDestroyHooks.indexOf(i);-1!==e&&this._onDestroyHooks.splice(e,1)}}function Ib(s){const i=lf(s),e=null!==i?i.factory:Ml(s);if(null!==e)return e;if(s instanceof Xe)throw new E(204,!1);if(s instanceof Function)return function v2(s){if(s.length>0)throw new E(204,!1);const e=function T_(s){return s&&(s[uf]||s[VD])||null}(s);return null!==e?()=>e.factory(s):()=>new s}(s);throw new E(204,!1)}function Bc(s,i,e=!1){return{factory:s,value:i,multi:e?[]:void 0}}function Eb(s,i){for(const e of s)Array.isArray(e)?Eb(e,i):e&&Bo(e)?Eb(e.\u0275providers,i):i(e)}function lN(s,i=null,e=null,t){const n=function cN(s,i=null,e=null,t,n=new Set){const r=[e||si,p2(s)];return t=t||("object"==typeof s?void 0:ze(s)),new Hc(r,i||jf(),t||null,n)}(s,i,e,t);return n.resolveInjectorInitializers(),n}let Nb,Ks=(()=>{class s{static{this.THROW_IF_NOT_FOUND=Eh}static{this.NULL=new Of}static create(e,t){if(Array.isArray(e))return lN({name:""},t,e,"");{const n=e.name??"";return lN({name:n},e.parent,e.providers,n)}}static{this.\u0275prov=Kt({token:s,providedIn:"any",factory:()=>Jt(JS)})}static{this.__NG_ELEMENT_ID__=-1}}return s})();const Tb=new Xe("",{providedIn:"root",factory:()=>L2}),L2="ng",hN=new Xe(""),Vc=new Xe("",{providedIn:"platform",factory:()=>"unknown"}),dN=new Xe("",{providedIn:"root",factory:()=>function ja(){if(void 0!==Nb)return Nb;if(typeof document<"u")return document;throw new E(210,!1)}().body?.querySelector("[ngCspNonce]")?.getAttribute("ngCspNonce")||null});function Ff(s){return 128==(128&s.flags)}var za=function(s){return s[s.Important=1]="Important",s[s.DashCase=2]="DashCase",s}(za||{});const xb=new Map;let U2=0;const jb="__ngContext__";function us(s,i){os(i)?(s[jb]=i[wh],function Y2(s){xb.set(s[wh],s)}(i)):s[jb]=i}let Rb;function Pb(s,i){return Rb(s,i)}function Wc(s,i,e,t,n){if(null!=t){let r,o=!1;as(t)?r=t:os(t)&&(o=!0,t=t[Ui]);const a=Ci(t);0===s&&null!==e?null==n?jN(i,e,a):Nl(i,e,a,n||null,!0):1===s&&null!==e?Nl(i,e,a,n||null,!0):2===s?function Qf(s,i,e){const t=Wf(s,i);t&&function aF(s,i,e,t){s.removeChild(i,e,t)}(s,t,i,e)}(i,a,o):3===s&&i.destroyNode(a),null!=r&&function uF(s,i,e,t,n){const r=e[oo];r!==Ci(e)&&Wc(i,s,t,r,n);for(let a=hn;a0&&(s[e-1][kr]=t[kr]);const r=Tf(s,hn+i);!function eF(s,i){ON(s,i),i[Ui]=null,i[rs]=null}(t[fe],t);const o=r[ro];null!==o&&o.detachView(r[fe]),t[un]=null,t[kr]=null,t[Ke]&=-129}return t}function Uf(s,i){if(!(256&i[Ke])){const e=i[vt];e.destroyNode&&qf(s,i,e,3,null,null),function iF(s){let i=s[Nh];if(!i)return _b(s[fe],s);for(;i;){let e=null;if(os(i))e=i[Nh];else{const t=i[hn];t&&(e=t)}if(!e){for(;i&&!i[kr]&&i!==s;)os(i)&&_b(i[fe],i),i=i[un];null===i&&(i=s),os(i)&&_b(i[fe],i),e=i&&i[kr]}i=e}}(i)}}function _b(s,i){if(!(256&i[Ke])){i[Ke]&=-129,i[Ke]|=256,i[yl]&&function fc(s){if(_o(s),wa(s))for(let i=0;i=0?t[o]():t[-o].unsubscribe(),r+=2}else e[r].call(t[e[r+1]]);null!==t&&(i[Ic]=null);const n=i[xa];if(null!==n){i[xa]=null;for(let r=0;r-1){const{encapsulation:r}=s.data[t.directiveStart+n];if(r===Or.None||r===Or.Emulated)return null}return Es(t,e)}}(s,i.parent,e)}function Nl(s,i,e,t,n){s.insertBefore(i,e,t,n)}function jN(s,i,e){s.appendChild(i,e)}function RN(s,i,e,t,n){null!==t?Nl(s,i,e,t,n):jN(s,i,e)}function Wf(s,i){return s.parentNode(i)}function PN(s,i,e){return _N(s,i,e)}let Hb,_N=function zN(s,i,e){return 40&s.type?Es(s,e):null};function Wh(s,i){if(null!==i){const e=i.type;if(3&e)return Es(i,s);if(4&e)return Bb(-1,s[i.index]);if(8&e){const t=i.child;if(null!==t)return Wh(s,t);{const n=s[i.index];return as(n)?Bb(-1,n):Ci(n)}}if(32&e)return Pb(i,s)()||Ci(s[i.index]);{const t=HN(s,i);return null!==t?Array.isArray(t)?t[0]:Wh(Cl(s[Zi]),t):Wh(s,i.next)}}return null}function HN(s,i){return null!==i?s[Zi][rs].projection[i.projection]:null}function Bb(s,i){const e=hn+s+1;if(enull;function iM(s,i,e=!1){return sT(s,i,e)}class qF{}class cT{}class GF{resolveComponentFactory(i){throw function $F(s){const i=Error(`No component factory found for ${ze(s)}.`);return i.ngComponent=s,i}(i)}}let ig=(()=>{class s{static{this.NULL=new GF}}return s})();function ZF(){return Zc(Ii(),te())}function Zc(s,i){return new lr(Es(s,i))}let lr=(()=>{class s{constructor(e){this.nativeElement=e}static{this.__NG_ELEMENT_ID__=ZF}}return s})();function XF(s){return s instanceof lr?s.nativeElement:s}class hT{}let Fa=(()=>{class s{constructor(){this.destroyNode=null}static{this.__NG_ELEMENT_ID__=()=>function KF(){const s=te(),e=Zs(Ii().index,s);return(os(e)?e:s)[vt]}()}}return s})(),JF=(()=>{class s{static{this.\u0275prov=Kt({token:s,providedIn:"root",factory:()=>null})}}return s})();const oM={};function Xh(s,i,e,t,n=!1){for(;null!==e;){const r=i[e.index];null!==r&&t.push(Ci(r)),as(r)&&bT(r,t);const o=e.type;if(8&o)Xh(s,i,e.child,t);else if(32&o){const a=Pb(e,i);let l;for(;l=a();)t.push(l)}else if(16&o){const a=HN(i,e);if(Array.isArray(a))t.push(...a);else{const l=Cl(i[Zi]);Xh(l[fe],l,a,t,!0)}}e=n?e.projectionNext:e.next}return t}function bT(s,i){for(let e=hn;e!1,producerRecomputeValue:()=>{},consumerMarkedDirty:()=>{},consumerOnSignalRead:()=>{},consumerIsAlwaysLive:!0,consumerMarkedDirty:s=>{xh(s.lView)},consumerOnSignalRead(){this.lView[yl]=this}};function CT(s){return ET(s[Nh])}function IT(s){return ET(s[kr])}function ET(s){for(;null!==s&&!as(s);)s=s[kr];return s}function cM(s){return s.ngOriginalError}class Zo{constructor(){this._console=console}handleError(i){const e=this._findOriginalError(i);this._console.error("ERROR",i),e&&this._console.error("ORIGINAL ERROR",e)}_findOriginalError(i){let e=i&&cM(i);for(;e&&cM(e);)e=cM(e);return e||null}}const ST=new Xe("",{providedIn:"root",factory:()=>Wt(Zo).handleError.bind(void 0)}),TT=new Xe("",{providedIn:"root",factory:()=>!1}),yt={};function uM(s=1){OT(Yt(),te(),ls()+s,!1)}function OT(s,i,e,t){if(!t)if(3==(3&i[Ke])){const r=s.preOrderCheckHooks;null!==r&&Cf(i,r,e)}else{const r=s.preOrderHooks;null!==r&&If(i,r,0,e)}Il(e)}function ue(s,i=Ut.Default){const e=te();return null===e?Jt(s,i):BS(Ii(),e,He(s),i)}function xT(s,i,e,t,n,r){const o=ni(null);try{let a=null;n&sn.SignalBased&&(a=i[t][ts]),null!==a&&void 0!==a.transformFn&&(r=a.transformFn(r)),n&sn.HasDecoratorInputTransform&&(r=s.inputTransforms[t].call(i,r)),null!==s.setInput?s.setInput(i,a,r,e,t):uS(i,a,t,r)}finally{ni(o)}}function og(s,i,e,t,n,r,o,a,l,c,u){const h=i.blueprint.slice();return h[Ui]=n,h[Ke]=204|t,(null!==c||s&&2048&s[Ke])&&(h[Ke]|=2048),vS(h),h[un]=h[Ec]=s,h[Oi]=e,h[Wo]=o||s&&s[Wo],h[vt]=a||s&&s[vt],h[Is]=l||s&&s[Is]||null,h[rs]=r,h[wh]=function W2(){return U2++}(),h[jr]=u,h[oS]=c,h[Zi]=2==i.type?s[Zi]:h,h}function Xc(s,i,e,t,n){let r=s.data[i];if(null===r)r=function hM(s,i,e,t,n){const r=IS(),o=$y(),l=s.data[i]=function LH(s,i,e,t,n,r){let o=i?i.injectorIndex:-1,a=0;return Tc()&&(a|=128),{type:e,index:t,insertBeforeIndex:null,injectorIndex:o,directiveStart:-1,directiveEnd:-1,directiveStylingLast:-1,componentOffset:-1,propertyBindings:null,flags:a,providerIndexes:0,value:n,attrs:r,mergedAttrs:null,localNames:null,initialInputs:void 0,inputs:null,outputs:null,tView:null,next:null,prev:null,projectionNext:null,child:null,parent:i,projection:null,styles:null,stylesWithoutHost:null,residualStyles:void 0,classes:null,classesWithoutHost:null,residualClasses:void 0,classBindings:0,styleBindings:0}}(0,o?r:r&&r.parent,e,i,t,n);return null===s.firstChild&&(s.firstChild=l),null!==r&&(o?null==r.child&&null!==l.parent&&(r.child=l):null===r.next&&(r.next=l,l.prev=r)),l}(s,i,e,t,n),function E4(){return lt.lFrame.inI18n}()&&(r.flags|=32);else if(64&r.type){r.type=e,r.value=t,r.attrs=n;const o=function kh(){const s=lt.lFrame,i=s.currentTNode;return s.isParent?i:i.parent}();r.injectorIndex=null===o?-1:o.injectorIndex}return co(r,!0),r}function Kh(s,i,e,t){if(0===e)return-1;const n=i.length;for(let r=0;rpt&&OT(s,i,pt,!1),ao(o?2:0,n),e(t,n)}finally{Il(r),ao(o?3:1,n)}}function dM(s,i,e){if(Fy(i)){const t=ni(null);try{const r=i.directiveEnd;for(let o=i.directiveStart;onull;function PT(s,i,e,t,n){for(let r in i){if(!i.hasOwnProperty(r))continue;const o=i[r];if(void 0===o)continue;t??={};let a,l=sn.None;Array.isArray(o)?(a=o[0],l=o[1]):a=o;let c=r;if(null!==n){if(!n.hasOwnProperty(r))continue;c=n[r]}0===s?zT(t,e,c,a,l):zT(t,e,c,a)}return t}function zT(s,i,e,t,n){let r;s.hasOwnProperty(e)?(r=s[e]).push(i,t):r=s[e]=[i,t],void 0!==n&&r.push(n)}function _T(s,i,e,t,n,r){for(let c=0;c0;){const e=s[--i];if("number"==typeof e&&e<0)return e}return 0})(o)!=a&&o.push(a),o.push(e,t,r)}}(s,i,t,Kh(s,e,n.hostVars,yt),n)}function YH(s,i,e,t,n,r){const o=r[i];if(null!==o)for(let a=0;as.nextProducerIndex;)s.producerNode.pop(),s.producerLastReadVersion.pop(),s.producerIndexOfThis.pop()}}(a,o),function pH(s){s.lView[yl]!==s&&(s.lView=null,MT.push(s))}(a)),eb()}}function YT(s,i){for(let e=CT(s);null!==e;e=IT(e))for(let t=hn;t-1&&(Uh(i,t),Tf(e,t))}this._attachedToViewContainer=!1}Uf(this._lView[fe],this._lView)}onDestroy(i){!function yf(s,i){if(256==(256&s[Ke]))throw new E(911,!1);null===s[xa]&&(s[xa]=[]),s[xa].push(i)}(this._lView,i)}markForCheck(){Jh(this._cdRefInjectingView||this._lView)}detach(){this._lView[Ke]&=-129}reattach(){Qy(this._lView),this._lView[Ke]|=128}detectChanges(){this._lView[Ke]|=1024,function CM(s,i=!0){const e=s[Wo],t=e.rendererFactory;t.begin?.();try{!function $H(s){IM(s,0);let i=0;for(;bS(s);){if(100===i)throw new E(103,!1);i++,IM(s,1)}}(s)}catch(r){throw i&&lg(s,r),r}finally{t.end?.(),e.inlineEffectRunner?.flush()}}(this._lView,this.notifyErrorHandler)}checkNoChanges(){}attachToViewContainerRef(){if(this._appRef)throw new E(902,!1);this._attachedToViewContainer=!0}detachFromAppRef(){this._appRef=null,ON(this._lView[fe],this._lView)}attachToAppRef(i){if(this._attachedToViewContainer)throw new E(902,!1);this._appRef=i,Qy(this._lView)}}const $T=new Set;function SM(s){return i=>{setTimeout(s,void 0,i)}}const xn=class cB extends ot{constructor(i=!1){super(),this.__isAsync=i}emit(i){super.next(i)}subscribe(i,e,t){let n=i,r=e||(()=>null),o=t;if(i&&"object"==typeof i){const l=i;n=l.next?.bind(l),r=l.error?.bind(l),o=l.complete?.bind(l)}this.__isAsync&&(r=SM(r),n&&(n=SM(n)),o&&(o=SM(o)));const a=super.subscribe({next:n,error:r,complete:o});return i instanceof is&&i.add(a),a}};function GT(...s){}class Fi{constructor({enableLongStackTrace:i=!1,shouldCoalesceEventChangeDetection:e=!1,shouldCoalesceRunChangeDetection:t=!1}){if(this.hasPendingMacrotasks=!1,this.hasPendingMicrotasks=!1,this.isStable=!0,this.onUnstable=new xn(!1),this.onMicrotaskEmpty=new xn(!1),this.onStable=new xn(!1),this.onError=new xn(!1),typeof Zone>"u")throw new E(908,!1);Zone.assertZonePatched();const n=this;n._nesting=0,n._outer=n._inner=Zone.current,Zone.TaskTrackingZoneSpec&&(n._inner=n._inner.fork(new Zone.TaskTrackingZoneSpec)),i&&Zone.longStackTraceZoneSpec&&(n._inner=n._inner.fork(Zone.longStackTraceZoneSpec)),n.shouldCoalesceEventChangeDetection=!t&&e,n.shouldCoalesceRunChangeDetection=t,n.lastRequestAnimationFrameId=-1,n.nativeRequestAnimationFrame=function uB(){const s="function"==typeof fi.requestAnimationFrame;let i=fi[s?"requestAnimationFrame":"setTimeout"],e=fi[s?"cancelAnimationFrame":"clearTimeout"];if(typeof Zone<"u"&&i&&e){const t=i[Zone.__symbol__("OriginalDelegate")];t&&(i=t);const n=e[Zone.__symbol__("OriginalDelegate")];n&&(e=n)}return{nativeRequestAnimationFrame:i,nativeCancelAnimationFrame:e}}().nativeRequestAnimationFrame,function pB(s){const i=()=>{!function dB(s){s.isCheckStableRunning||-1!==s.lastRequestAnimationFrameId||(s.lastRequestAnimationFrameId=s.nativeRequestAnimationFrame.call(fi,()=>{s.fakeTopEventTask||(s.fakeTopEventTask=Zone.root.scheduleEventTask("fakeTopEventTask",()=>{s.lastRequestAnimationFrameId=-1,TM(s),s.isCheckStableRunning=!0,NM(s),s.isCheckStableRunning=!1},void 0,()=>{},()=>{})),s.fakeTopEventTask.invoke()}),TM(s))}(s)};s._inner=s._inner.fork({name:"angular",properties:{isAngularZone:!0},onInvokeTask:(e,t,n,r,o,a)=>{if(function fB(s){return!(!Array.isArray(s)||1!==s.length)&&!0===s[0].data?.__ignore_ng_zone__}(a))return e.invokeTask(n,r,o,a);try{return ZT(s),e.invokeTask(n,r,o,a)}finally{(s.shouldCoalesceEventChangeDetection&&"eventTask"===r.type||s.shouldCoalesceRunChangeDetection)&&i(),XT(s)}},onInvoke:(e,t,n,r,o,a,l)=>{try{return ZT(s),e.invoke(n,r,o,a,l)}finally{s.shouldCoalesceRunChangeDetection&&i(),XT(s)}},onHasTask:(e,t,n,r)=>{e.hasTask(n,r),t===n&&("microTask"==r.change?(s._hasPendingMicrotasks=r.microTask,TM(s),NM(s)):"macroTask"==r.change&&(s.hasPendingMacrotasks=r.macroTask))},onHandleError:(e,t,n,r)=>(e.handleError(n,r),s.runOutsideAngular(()=>s.onError.emit(r)),!1)})}(n)}static isInAngularZone(){return typeof Zone<"u"&&!0===Zone.current.get("isAngularZone")}static assertInAngularZone(){if(!Fi.isInAngularZone())throw new E(909,!1)}static assertNotInAngularZone(){if(Fi.isInAngularZone())throw new E(909,!1)}run(i,e,t){return this._inner.run(i,e,t)}runTask(i,e,t,n){const r=this._inner,o=r.scheduleEventTask("NgZoneEvent: "+n,i,hB,GT,GT);try{return r.runTask(o,e,t)}finally{r.cancelTask(o)}}runGuarded(i,e,t){return this._inner.runGuarded(i,e,t)}runOutsideAngular(i){return this._outer.run(i)}}const hB={};function NM(s){if(0==s._nesting&&!s.hasPendingMicrotasks&&!s.isStable)try{s._nesting++,s.onMicrotaskEmpty.emit(null)}finally{if(s._nesting--,!s.hasPendingMicrotasks)try{s.runOutsideAngular(()=>s.onStable.emit(null))}finally{s.isStable=!0}}}function TM(s){s.hasPendingMicrotasks=!!(s._hasPendingMicrotasks||(s.shouldCoalesceEventChangeDetection||s.shouldCoalesceRunChangeDetection)&&-1!==s.lastRequestAnimationFrameId)}function ZT(s){s._nesting++,s.isStable&&(s.isStable=!1,s.onUnstable.emit(null))}function XT(s){s._nesting--,NM(s)}let td=(()=>{class s{constructor(){this.handler=null,this.internalCallbacks=[]}execute(){const e=[...this.internalCallbacks];this.internalCallbacks.length=0;for(const n of e)n();return!!this.handler?.execute()||e.length>0}ngOnDestroy(){this.handler?.destroy(),this.handler=null,this.internalCallbacks.length=0}static{this.\u0275prov=Kt({token:s,providedIn:"root",factory:()=>new s})}}return s})();function yB(s,i){const e=Zs(i,s),t=e[fe];!function bB(s,i){for(let e=i.length;e0&&UN(s,e,r.join(" "))}}(p,k,g,t),void 0!==e&&function AB(s,i,e){const t=s.projection=[];for(let n=0;n=0;t--){const n=s[t];n.hostVars=i+=n.hostVars,n.hostAttrs=Sh(n.hostAttrs,e=Sh(e,n.hostAttrs))}}(t)}function OB(s,i){for(const e in i.inputs){if(!i.inputs.hasOwnProperty(e)||s.inputs.hasOwnProperty(e))continue;const t=i.inputs[e];if(void 0!==t&&(s.inputs[e]=t,s.declaredInputs[e]=i.declaredInputs[e],null!==i.inputTransforms)){const n=Array.isArray(t)?t[0]:t;if(!i.inputTransforms.hasOwnProperty(n))continue;s.inputTransforms??={},s.inputTransforms[n]=i.inputTransforms[n]}}}function ug(s){return s===so?{}:s===si?[]:s}function kB(s,i){const e=s.viewQuery;s.viewQuery=e?(t,n)=>{i(t,n),e(t,n)}:i}function jB(s,i){const e=s.contentQueries;s.contentQueries=e?(t,n,r)=>{i(t,n,r),e(t,n,r)}:i}function RB(s,i){const e=s.hostBindings;s.hostBindings=e?(t,n)=>{i(t,n),e(t,n)}:i}function Jc(s,i){return!i||null===i.firstChild||Ff(s)}function ld(s,i,e,t=!0){const n=i[fe];if(function nF(s,i,e,t){const n=hn+t,r=e.length;t>0&&(e[n-1][kr]=i),t{class s{static{this.__NG_ELEMENT_ID__=c3}}return s})();function c3(){return yw(Ii(),te())}const u3=cr,mw=class extends u3{constructor(i,e,t){super(),this._lContainer=i,this._hostTNode=e,this._hostLView=t}get element(){return Zc(this._hostTNode,this._hostLView)}get injector(){return new Ln(this._hostTNode,this._hostLView)}get parentInjector(){const i=Sf(this._hostTNode,this._hostLView);if(nb(i)){const e=Ph(i,this._hostLView),t=Rh(i);return new Ln(e[fe].data[t+8],e)}return new Ln(null,this._hostLView)}clear(){for(;this.length>0;)this.remove(this.length-1)}get(i){const e=vw(this._lContainer);return null!==e&&e[i]||null}get length(){return this._lContainer.length-hn}createEmbeddedView(i,e,t){let n,r;"number"==typeof t?n=t:null!=t&&(n=t.index,r=t.injector);const a=i.createEmbeddedViewImpl(e||{},r,null);return this.insertImpl(a,n,Jc(this._hostTNode,null)),a}createComponent(i,e,t,n,r){const o=i&&!function zh(s){return"function"==typeof s}(i);let a;if(o)a=e;else{const g=e||{};a=g.index,t=g.injector,n=g.projectableNodes,r=g.environmentInjector||g.ngModuleRef}const l=o?i:new id(At(i)),c=t||this.parentInjector;if(!r&&null==l.ngModule){const v=(o?c:this.parentInjector).get($o,null);v&&(r=v)}At(l.componentType??{});const f=l.create(c,n,null,r);return this.insertImpl(f.hostView,a,Jc(this._hostTNode,null)),f}insert(i,e){return this.insertImpl(i,e,!0)}insertImpl(i,e,t){const n=i._lView;if(function u4(s){return as(s[un])}(n)){const a=this.indexOf(i);if(-1!==a)this.detach(a);else{const l=n[un],c=new mw(l,l[rs],l[un]);c.detach(c.indexOf(i))}}const r=this._adjustIndex(e),o=this._lContainer;return ld(o,n,r,t),i.attachToViewContainerRef(),qS(RM(o),r,i),i}move(i,e){return this.insert(i,e)}indexOf(i){const e=vw(this._lContainer);return null!==e?e.indexOf(i):-1}remove(i){const e=this._adjustIndex(i,-1),t=Uh(this._lContainer,e);t&&(Tf(RM(this._lContainer),e),Uf(t[fe],t))}detach(i){const e=this._adjustIndex(i,-1),t=Uh(this._lContainer,e);return t&&null!=Tf(RM(this._lContainer),e)?new ed(t):null}_adjustIndex(i,e=0){return i??this.length+e}};function vw(s){return s[8]}function RM(s){return s[8]||(s[8]=[])}function yw(s,i){let e;const t=i[s.index];return as(t)?e=t:(e=function HT(s,i,e,t){return[s,!0,0,i,null,t,null,e,null,null]}(t,i,null,s),i[s.index]=e,ag(i,e)),bw(e,i,s,t),new mw(e,s,i)}let bw=function Cw(s,i,e,t){if(s[oo])return;let n;n=8&e.type?Ci(t):function h3(s,i){const e=s[vt],t=e.createComment(""),n=Es(i,s);return Nl(e,Wf(e,n),t,function lF(s,i){return s.nextSibling(i)}(e,n),!1),t}(i,e),s[oo]=n};function Ig(s,i,e){const t=te();return function bn(s,i,e){return!Object.is(s[i],e)&&(s[i]=e,!0)}(t,function uo(){return lt.lFrame.bindingIndex++}(),i)&&function er(s,i,e,t,n,r,o,a){const l=Es(i,e);let u,c=i.inputs;!a&&null!=c&&(u=c[t])?(MM(s,e,u,t,n),bl(i)&&function kH(s,i){const e=Zs(i,s);16&e[Ke]||(e[Ke]|=64)}(e,i.index)):3&i.type&&(t=function xH(s){return"class"===s?"className":"for"===s?"htmlFor":"formaction"===s?"formAction":"innerHtml"===s?"innerHTML":"readonly"===s?"readOnly":"tabindex"===s?"tabIndex":s}(t),n=null!=o?o(n,i.value||"",t):n,r.setProperty(l,t,n))}(Yt(),function _i(){const s=lt.lFrame;return Oh(s.tView,s.selectedIndex)}(),t,s,i,t[vt],e,!1),Ig}function $M(s,i,e,t,n){const o=n?"class":"style";MM(s,e,i.inputs[o],o,t)}function gd(s,i,e,t){const n=te(),r=Yt(),o=pt+s,a=n[vt],l=r.firstCreatePass?function _V(s,i,e,t,n,r){const o=i.consts,l=Xc(i,s,2,t,lo(o,n));return function mM(s,i,e,t){if(CS()){const n=null===t?null:{"":-1},r=function FH(s,i){const e=s.directiveRegistry;let t=null,n=null;if(e)for(let r=0;r(function ka(s){kS=s}(!0),Vf(t,n,function xS(){return lt.lFrame.currentNamespace}()));const vu="en-US";let SA=vu;function Lg(s){return!!s&&"function"==typeof s.then}function ZA(s){return!!s&&"function"==typeof s.subscribe}function dr(s,i,e,t){const n=te(),r=Yt(),o=Ii();return function KA(s,i,e,t,n,r,o){const a=vf(t),c=s.firstCreatePass&&UT(s),u=i[Oi],h=VT(i);let p=!0;if(3&t.type||o){const v=Es(t,i),b=o?o(v):v,M=h.length,C=o?T=>o(Ci(T[t.index])):t.index;let D=null;if(!o&&a&&(D=function B5(s,i,e,t){const n=s.cleanup;if(null!=n)for(let r=0;rl?a[l]:null}"string"==typeof o&&(r+=2)}return null}(s,i,n,t.index)),null!==D)(D.__ngLastListenerFn__||D).__ngNextListenerFn__=r,D.__ngLastListenerFn__=r,p=!1;else{r=eL(t,i,u,r,!1);const T=e.listen(b,n,r);h.push(r,T),c&&c.push(n,C,M,M+1)}}else r=eL(t,i,u,r,!1);const f=t.outputs;let g;if(p&&null!==f&&(g=f[n])){const v=g.length;if(v)for(let b=0;b-1?Zs(s.index,i):i);let l=JA(i,e,t,o),c=r.__ngNextListenerFn__;for(;c;)l=JA(i,e,c,o)&&l,c=c.__ngNextListenerFn__;return n&&!1===l&&o.preventDefault(),l}}function U5(s,i){let e=null;const t=function V_(s){const i=s.attrs;if(null!=i){const e=i.indexOf(5);if(!(1&e))return i[e+1]}return null}(s);for(let n=0;n{class s{static{this.__NG_ELEMENT_ID__=q5}}return s})();const Y5=Jo,Q5=class extends Y5{constructor(i,e,t){super(),this._declarationLView=i,this._declarationTContainer=e,this.elementRef=t}get ssrId(){return this._declarationTContainer.tView?.ssrId||null}createEmbeddedView(i,e){return this.createEmbeddedViewImpl(i,e)}createEmbeddedViewImpl(i,e,t){const n=function ad(s,i,e,t){const n=i.tView,a=og(s,n,e,4096&s[Ke]?4096:16,null,i,null,null,null,t?.injector??null,t?.dehydratedView??null);a[Th]=s[i.index];const c=s[ro];return null!==c&&(a[ro]=c.createEmbeddedView(n)),wM(n,a,e),a}(this._declarationLView,this._declarationTContainer,i,{injector:e,dehydratedView:t});return new ed(n)}};function q5(){return Og(Ii(),te())}function Og(s,i){return 4&s.type?new Q5(i,s,Zc(s,i)):null}class l0{constructor(i){this.queryList=i,this.matches=null}clone(){return new l0(this.queryList)}setDirty(){this.queryList.setDirty()}}class c0{constructor(i=[]){this.queries=i}createEmbeddedView(i){const e=i.queries;if(null!==e){const t=null!==i.contentQueries?i.contentQueries[0]:e.length,n=[];for(let r=0;r0)t.push(o[a/2]);else{const c=r[a+1],u=i[-l];for(let h=hn;h{class s{constructor(e){this._injector=e,this.cachedInjectors=new Map}getOrCreateStandaloneInjector(e){if(!e.standalone)return null;if(!this.cachedInjectors.has(e)){const t=eN(0,e.type),n=t.length>0?function CU(s,i,e=null){return new _L({providers:s,parent:i,debugName:e,runEnvironmentInitializers:!0}).injector}([t],this._injector,`Standalone[${e.type.name}]`):null;this.cachedInjectors.set(e,n)}return this.cachedInjectors.get(e)}ngOnDestroy(){try{for(const e of this.cachedInjectors.values())null!==e&&e.destroy()}finally{this.cachedInjectors.clear()}}static{this.\u0275prov=Kt({token:s,providedIn:"environment",factory:()=>new s(Jt($o))})}}return s})();function FL(s){(function Tl(s){$T.has(s)||($T.add(s),performance?.mark?.("mark_feature_usage",{detail:{feature:s}}))})("NgStandalone"),s.getStandaloneInjector=i=>i.get(IU).getOrCreateStandaloneInjector(s)}let S0=(()=>{class s{constructor(){this.taskId=0,this.pendingTasks=new Set,this.hasPendingTasks=new sr(!1)}get _hasPendingTasks(){return this.hasPendingTasks.value}add(){this._hasPendingTasks||this.hasPendingTasks.next(!0);const e=this.taskId++;return this.pendingTasks.add(e),e}remove(e){this.pendingTasks.delete(e),0===this.pendingTasks.size&&this._hasPendingTasks&&this.hasPendingTasks.next(!1)}ngOnDestroy(){this.pendingTasks.clear(),this._hasPendingTasks&&this.hasPendingTasks.next(!1)}static{this.\u0275fac=function(t){return new(t||s)}}static{this.\u0275prov=Kt({token:s,factory:s.\u0275fac,providedIn:"root"})}}return s})();const yO=new Xe(""),q6=new Xe("");let L0=(()=>{class s{constructor(){this.initialized=!1,this.done=!1,this.donePromise=new Promise((e,t)=>{this.resolve=e,this.reject=t}),this.appInits=Wt(q6,{optional:!0})??[]}runInitializers(){if(this.initialized)return;const e=[];for(const n of this.appInits){const r=n();if(Lg(r))e.push(r);else if(ZA(r)){const o=new Promise((a,l)=>{r.subscribe({complete:a,error:l})});e.push(o)}}const t=()=>{this.done=!0,this.resolve()};Promise.all(e).then(()=>{t()}).catch(n=>{this.reject(n)}),0===e.length&&t(),this.initialized=!0}static{this.\u0275fac=function(t){return new(t||s)}}static{this.\u0275prov=Kt({token:s,factory:s.\u0275fac,providedIn:"root"})}}return s})();const bO=new Xe("");let Cu=(()=>{class s{constructor(){this._bootstrapListeners=[],this._runningTick=!1,this._destroyed=!1,this._destroyListeners=[],this._views=[],this.internalErrorHandler=Wt(ST),this.afterRenderEffectManager=Wt(td),this.componentTypes=[],this.components=[],this.isStable=Wt(S0).hasPendingTasks.pipe(Li(e=>!e)),this._injector=Wt($o)}get destroyed(){return this._destroyed}get injector(){return this._injector}bootstrap(e,t){const n=e instanceof cT;if(!this._injector.get(L0).done)throw!n&&function vl(s){const i=At(s)||An(s)||Qn(s);return null!==i&&i.standalone}(e),new E(405,!1);let o;o=n?e:this._injector.get(ig).resolveComponentFactory(e),this.componentTypes.push(o.componentType);const a=function G6(s){return s.isBoundToModule}(o)?void 0:this._injector.get(Rl),c=o.create(Ks.NULL,[],t||o.selector,a),u=c.location.nativeElement,h=c.injector.get(yO,null);return h?.registerApplication(u),c.onDestroy(()=>{this.detachView(c.hostView),_g(this.components,c),h?.unregisterApplication(u)}),this._loadComponent(c),c}tick(){if(this._runningTick)throw new E(101,!1);try{this._runningTick=!0;for(let e of this._views)e.detectChanges()}catch(e){this.internalErrorHandler(e)}finally{try{this.afterRenderEffectManager.execute()}catch(e){this.internalErrorHandler(e)}this._runningTick=!1}}attachView(e){const t=e;this._views.push(t),t.attachToAppRef(this)}detachView(e){const t=e;_g(this._views,t),t.detachFromAppRef()}_loadComponent(e){this.attachView(e.hostView),this.tick(),this.components.push(e);const t=this._injector.get(bO,[]);[...this._bootstrapListeners,...t].forEach(n=>n(e))}ngOnDestroy(){if(!this._destroyed)try{this._destroyListeners.forEach(e=>e()),this._views.slice().forEach(e=>e.destroy())}finally{this._destroyed=!0,this._views=[],this._bootstrapListeners=[],this._destroyListeners=[]}}onDestroy(e){return this._destroyListeners.push(e),()=>_g(this._destroyListeners,e)}destroy(){if(this._destroyed)throw new E(406,!1);const e=this._injector;e.destroy&&!e.destroyed&&e.destroy()}get viewCount(){return this._views.length}warnIfDestroyed(){}static{this.\u0275fac=function(t){return new(t||s)}}static{this.\u0275prov=Kt({token:s,factory:s.\u0275fac,providedIn:"root"})}}return s})();function _g(s,i){const e=s.indexOf(i);e>-1&&s.splice(e,1)}let X6=(()=>{class s{constructor(){this.zone=Wt(Fi),this.applicationRef=Wt(Cu)}initialize(){this._onMicrotaskEmptySubscription||(this._onMicrotaskEmptySubscription=this.zone.onMicrotaskEmpty.subscribe({next:()=>{this.zone.run(()=>{this.applicationRef.tick()})}}))}ngOnDestroy(){this._onMicrotaskEmptySubscription?.unsubscribe()}static{this.\u0275fac=function(t){return new(t||s)}}static{this.\u0275prov=Kt({token:s,factory:s.\u0275fac,providedIn:"root"})}}return s})();function DO(s){return[{provide:Fi,useFactory:s},{provide:Fc,multi:!0,useFactory:()=>{const i=Wt(X6,{optional:!0});return()=>i.initialize()}},{provide:Fc,multi:!0,useFactory:()=>{const i=Wt(eW);return()=>{i.initialize()}}},{provide:ST,useFactory:K6}]}function K6(){const s=Wt(Fi),i=Wt(Zo);return e=>s.runOutsideAngular(()=>i.handleError(e))}function J6(s){return function vb(s){return{\u0275providers:s}}([[],DO(()=>new Fi(function SO(s){return{enableLongStackTrace:!1,shouldCoalesceEventChangeDetection:s?.eventCoalescing??!1,shouldCoalesceRunChangeDetection:s?.runCoalescing??!1}}(s)))])}let eW=(()=>{class s{constructor(){this.subscription=new is,this.initialized=!1,this.zone=Wt(Fi),this.pendingTasks=Wt(S0)}initialize(){if(this.initialized)return;this.initialized=!0;let e=null;!this.zone.isStable&&!this.zone.hasPendingMacrotasks&&!this.zone.hasPendingMicrotasks&&(e=this.pendingTasks.add()),this.zone.runOutsideAngular(()=>{this.subscription.add(this.zone.onStable.subscribe(()=>{Fi.assertNotInAngularZone(),queueMicrotask(()=>{null!==e&&!this.zone.hasPendingMacrotasks&&!this.zone.hasPendingMicrotasks&&(this.pendingTasks.remove(e),e=null)})}))}),this.subscription.add(this.zone.onUnstable.subscribe(()=>{Fi.assertInAngularZone(),e??=this.pendingTasks.add()}))}ngOnDestroy(){this.subscription.unsubscribe()}static{this.\u0275fac=function(t){return new(t||s)}}static{this.\u0275prov=Kt({token:s,factory:s.\u0275fac,providedIn:"root"})}}return s})();const ea=new Xe("",{providedIn:"root",factory:()=>Wt(ea,Ut.Optional|Ut.SkipSelf)||function tW(){return typeof $localize<"u"&&$localize.locale||vu}()}),O0=new Xe("");let Va=null;function SW(s){try{const{rootComponent:i,appProviders:e,platformProviders:t}=s,n=function oW(s=[]){if(Va)return Va;const i=function wO(s=[],i){return Ks.create({name:i,providers:[{provide:Mb,useValue:"platform"},{provide:O0,useValue:new Set([()=>Va=null])},...s]})}(s);return Va=i,function MO(){!function yy(s){mc=s}(()=>{throw new E(600,!1)})}(),function AO(s){s.get(hN,null)?.forEach(e=>e())}(i),i}(t),r=[J6(),...e||[]],a=new _L({providers:r,parent:n,debugName:"",runEnvironmentInitializers:!1}).injector,l=a.get(Fi);return l.run(()=>{a.resolveInjectorInitializers();const c=a.get(Zo,null);let u;l.runOutsideAngular(()=>{u=l.onError.subscribe({next:f=>{c.handleError(f)}})});const h=()=>a.destroy(),p=n.get(O0);return p.add(h),a.onDestroy(()=>{u.unsubscribe(),p.delete(h)}),function CO(s,i,e){try{const t=e();return Lg(t)?t.catch(n=>{throw i.runOutsideAngular(()=>s.handleError(n)),n}):t}catch(t){throw i.runOutsideAngular(()=>s.handleError(t)),t}}(c,l,()=>{const f=a.get(L0);return f.runInitializers(),f.donePromise.then(()=>{!function NA(s){Rs(s,"Expected localeId to be defined"),"string"==typeof s&&(SA=s.toLowerCase().replace(/_/g,"-"))}(a.get(ea,vu)||vu);const v=a.get(Cu);return void 0!==i&&v.bootstrap(i),v})})})}catch(i){return Promise.reject(i)}}let JO=null;function Td(){return JO}class HW{}const zl=new Xe("");let sY=(()=>{class s{static{this.\u0275fac=function(t){return new(t||s)}}static{this.\u0275mod=Cc({type:s})}static{this.\u0275inj=ml({})}}return s})();function gx(s){return"server"===s}class xY extends HW{constructor(){super(...arguments),this.supportsDOMEvents=!0}}class iC extends xY{static makeCurrent(){!function FW(s){JO??=s}(new iC)}onAndCancel(i,e,t){return i.addEventListener(e,t),()=>{i.removeEventListener(e,t)}}dispatchEvent(i,e){i.dispatchEvent(e)}remove(i){i.parentNode&&i.parentNode.removeChild(i)}createElement(i,e){return(e=e||this.getDefaultDocument()).createElement(i)}createHtmlDocument(){return document.implementation.createHTMLDocument("fakeTitle")}getDefaultDocument(){return document}isElementNode(i){return i.nodeType===Node.ELEMENT_NODE}isShadowRoot(i){return i instanceof DocumentFragment}getGlobalEventTarget(i,e){return"window"===e?window:"document"===e?i:"body"===e?i.body:null}getBaseHref(i){const e=function kY(){return Ld=Ld||document.querySelector("base"),Ld?Ld.getAttribute("href"):null}();return null==e?null:function jY(s){return new URL(s,document.baseURI).pathname}(e)}resetBaseElement(){Ld=null}getUserAgent(){return window.navigator.userAgent}getCookie(i){return function N7(s,i){i=encodeURIComponent(i);for(const e of s.split(";")){const t=e.indexOf("="),[n,r]=-1==t?[e,""]:[e.slice(0,t),e.slice(t+1)];if(n.trim()===i)return decodeURIComponent(r)}return null}(document.cookie,i)}}let Ld=null,PY=(()=>{class s{build(){return new XMLHttpRequest}static{this.\u0275fac=function(t){return new(t||s)}}static{this.\u0275prov=Kt({token:s,factory:s.\u0275fac})}}return s})();const nC=new Xe("");let bx=(()=>{class s{constructor(e,t){this._zone=t,this._eventNameToPlugin=new Map,e.forEach(n=>{n.manager=this}),this._plugins=e.slice().reverse()}addEventListener(e,t,n){return this._findPluginFor(t).addEventListener(e,t,n)}getZone(){return this._zone}_findPluginFor(e){let t=this._eventNameToPlugin.get(e);if(t)return t;if(t=this._plugins.find(r=>r.supports(e)),!t)throw new E(5101,!1);return this._eventNameToPlugin.set(e,t),t}static{this.\u0275fac=function(t){return new(t||s)(Jt(nC),Jt(Fi))}}static{this.\u0275prov=Kt({token:s,factory:s.\u0275fac})}}return s})();class Mx{constructor(i){this._doc=i}}const sC="ng-app-id";let Cx=(()=>{class s{constructor(e,t,n,r={}){this.doc=e,this.appId=t,this.nonce=n,this.platformId=r,this.styleRef=new Map,this.hostNodes=new Set,this.styleNodesInDOM=this.collectServerRenderedStyles(),this.platformIsServer=gx(r),this.resetHostNodes()}addStyles(e){for(const t of e)1===this.changeUsageCount(t,1)&&this.onStyleAdded(t)}removeStyles(e){for(const t of e)this.changeUsageCount(t,-1)<=0&&this.onStyleRemoved(t)}ngOnDestroy(){const e=this.styleNodesInDOM;e&&(e.forEach(t=>t.remove()),e.clear());for(const t of this.getAllStyles())this.onStyleRemoved(t);this.resetHostNodes()}addHost(e){this.hostNodes.add(e);for(const t of this.getAllStyles())this.addStyleToHost(e,t)}removeHost(e){this.hostNodes.delete(e)}getAllStyles(){return this.styleRef.keys()}onStyleAdded(e){for(const t of this.hostNodes)this.addStyleToHost(t,e)}onStyleRemoved(e){const t=this.styleRef;t.get(e)?.elements?.forEach(n=>n.remove()),t.delete(e)}collectServerRenderedStyles(){const e=this.doc.head?.querySelectorAll(`style[${sC}="${this.appId}"]`);if(e?.length){const t=new Map;return e.forEach(n=>{null!=n.textContent&&t.set(n.textContent,n)}),t}return null}changeUsageCount(e,t){const n=this.styleRef;if(n.has(e)){const r=n.get(e);return r.usage+=t,r.usage}return n.set(e,{usage:t,elements:[]}),t}getStyleElement(e,t){const n=this.styleNodesInDOM,r=n?.get(t);if(r?.parentNode===e)return n.delete(t),r.removeAttribute(sC),r;{const o=this.doc.createElement("style");return this.nonce&&o.setAttribute("nonce",this.nonce),o.textContent=t,this.platformIsServer&&o.setAttribute(sC,this.appId),e.appendChild(o),o}}addStyleToHost(e,t){const n=this.getStyleElement(e,t),r=this.styleRef,o=r.get(t)?.elements;o?o.push(n):r.set(t,{elements:[n],usage:1})}resetHostNodes(){const e=this.hostNodes;e.clear(),e.add(this.doc.head)}static{this.\u0275fac=function(t){return new(t||s)(Jt(zl),Jt(Tb),Jt(dN,8),Jt(Vc))}}static{this.\u0275prov=Kt({token:s,factory:s.\u0275fac})}}return s})();const rC={svg:"http://www.w3.org/2000/svg",xhtml:"http://www.w3.org/1999/xhtml",xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/",math:"http://www.w3.org/1998/MathML/"},oC=/%COMP%/g,HY=new Xe("",{providedIn:"root",factory:()=>!0});function Ex(s,i){return i.map(e=>e.replace(oC,s))}let Dx=(()=>{class s{constructor(e,t,n,r,o,a,l,c=null){this.eventManager=e,this.sharedStylesHost=t,this.appId=n,this.removeStylesOnCompDestroy=r,this.doc=o,this.platformId=a,this.ngZone=l,this.nonce=c,this.rendererByCompId=new Map,this.platformIsServer=gx(a),this.defaultRenderer=new aC(e,o,l,this.platformIsServer)}createRenderer(e,t){if(!e||!t)return this.defaultRenderer;this.platformIsServer&&t.encapsulation===Or.ShadowDom&&(t={...t,encapsulation:Or.Emulated});const n=this.getOrCreateRenderer(e,t);return n instanceof Nx?n.applyToHost(e):n instanceof lC&&n.applyStyles(),n}getOrCreateRenderer(e,t){const n=this.rendererByCompId;let r=n.get(t.id);if(!r){const o=this.doc,a=this.ngZone,l=this.eventManager,c=this.sharedStylesHost,u=this.removeStylesOnCompDestroy,h=this.platformIsServer;switch(t.encapsulation){case Or.Emulated:r=new Nx(l,c,t,this.appId,u,o,a,h);break;case Or.ShadowDom:return new WY(l,c,e,t,o,a,this.nonce,h);default:r=new lC(l,c,t,u,o,a,h)}n.set(t.id,r)}return r}ngOnDestroy(){this.rendererByCompId.clear()}static{this.\u0275fac=function(t){return new(t||s)(Jt(bx),Jt(Cx),Jt(Tb),Jt(HY),Jt(zl),Jt(Vc),Jt(Fi),Jt(dN))}}static{this.\u0275prov=Kt({token:s,factory:s.\u0275fac})}}return s})();class aC{constructor(i,e,t,n){this.eventManager=i,this.doc=e,this.ngZone=t,this.platformIsServer=n,this.data=Object.create(null),this.throwOnSyntheticProps=!0,this.destroyNode=null}destroy(){}createElement(i,e){return e?this.doc.createElementNS(rC[e]||e,i):this.doc.createElement(i)}createComment(i){return this.doc.createComment(i)}createText(i){return this.doc.createTextNode(i)}appendChild(i,e){(Sx(i)?i.content:i).appendChild(e)}insertBefore(i,e,t){i&&(Sx(i)?i.content:i).insertBefore(e,t)}removeChild(i,e){i&&i.removeChild(e)}selectRootElement(i,e){let t="string"==typeof i?this.doc.querySelector(i):i;if(!t)throw new E(-5104,!1);return e||(t.textContent=""),t}parentNode(i){return i.parentNode}nextSibling(i){return i.nextSibling}setAttribute(i,e,t,n){if(n){e=n+":"+e;const r=rC[n];r?i.setAttributeNS(r,e,t):i.setAttribute(e,t)}else i.setAttribute(e,t)}removeAttribute(i,e,t){if(t){const n=rC[t];n?i.removeAttributeNS(n,e):i.removeAttribute(`${t}:${e}`)}else i.removeAttribute(e)}addClass(i,e){i.classList.add(e)}removeClass(i,e){i.classList.remove(e)}setStyle(i,e,t,n){n&(za.DashCase|za.Important)?i.style.setProperty(e,t,n&za.Important?"important":""):i.style[e]=t}removeStyle(i,e,t){t&za.DashCase?i.style.removeProperty(e):i.style[e]=""}setProperty(i,e,t){null!=i&&(i[e]=t)}setValue(i,e){i.nodeValue=e}listen(i,e,t){if("string"==typeof i&&!(i=Td().getGlobalEventTarget(this.doc,i)))throw new Error(`Unsupported event target ${i} for event ${e}`);return this.eventManager.addEventListener(i,e,this.decoratePreventDefault(t))}decoratePreventDefault(i){return e=>{if("__ngUnwrap__"===e)return i;!1===(this.platformIsServer?this.ngZone.runGuarded(()=>i(e)):i(e))&&e.preventDefault()}}}function Sx(s){return"TEMPLATE"===s.tagName&&void 0!==s.content}class WY extends aC{constructor(i,e,t,n,r,o,a,l){super(i,r,o,l),this.sharedStylesHost=e,this.hostEl=t,this.shadowRoot=t.attachShadow({mode:"open"}),this.sharedStylesHost.addHost(this.shadowRoot);const c=Ex(n.id,n.styles);for(const u of c){const h=document.createElement("style");a&&h.setAttribute("nonce",a),h.textContent=u,this.shadowRoot.appendChild(h)}}nodeOrShadowRoot(i){return i===this.hostEl?this.shadowRoot:i}appendChild(i,e){return super.appendChild(this.nodeOrShadowRoot(i),e)}insertBefore(i,e,t){return super.insertBefore(this.nodeOrShadowRoot(i),e,t)}removeChild(i,e){return super.removeChild(this.nodeOrShadowRoot(i),e)}parentNode(i){return this.nodeOrShadowRoot(super.parentNode(this.nodeOrShadowRoot(i)))}destroy(){this.sharedStylesHost.removeHost(this.shadowRoot)}}class lC extends aC{constructor(i,e,t,n,r,o,a,l){super(i,r,o,a),this.sharedStylesHost=e,this.removeStylesOnCompDestroy=n,this.styles=l?Ex(l,t.styles):t.styles}applyStyles(){this.sharedStylesHost.addStyles(this.styles)}destroy(){this.removeStylesOnCompDestroy&&this.sharedStylesHost.removeStyles(this.styles)}}class Nx extends lC{constructor(i,e,t,n,r,o,a,l){const c=n+"-"+t.id;super(i,e,t,r,o,a,l,c),this.contentAttr=function BY(s){return"_ngcontent-%COMP%".replace(oC,s)}(c),this.hostAttr=function VY(s){return"_nghost-%COMP%".replace(oC,s)}(c)}applyToHost(i){this.applyStyles(),this.setAttribute(i,this.hostAttr,"")}createElement(i,e){const t=super.createElement(i,e);return super.setAttribute(t,this.contentAttr,""),t}}let YY=(()=>{class s extends Mx{constructor(e){super(e)}supports(e){return!0}addEventListener(e,t,n){return e.addEventListener(t,n,!1),()=>this.removeEventListener(e,t,n)}removeEventListener(e,t,n){return e.removeEventListener(t,n)}static{this.\u0275fac=function(t){return new(t||s)(Jt(zl))}}static{this.\u0275prov=Kt({token:s,factory:s.\u0275fac})}}return s})();const Tx=["alt","control","meta","shift"],QY={"\b":"Backspace","\t":"Tab","\x7f":"Delete","\x1b":"Escape",Del:"Delete",Esc:"Escape",Left:"ArrowLeft",Right:"ArrowRight",Up:"ArrowUp",Down:"ArrowDown",Menu:"ContextMenu",Scroll:"ScrollLock",Win:"OS"},qY={alt:s=>s.altKey,control:s=>s.ctrlKey,meta:s=>s.metaKey,shift:s=>s.shiftKey};let $Y=(()=>{class s extends Mx{constructor(e){super(e)}supports(e){return null!=s.parseEventName(e)}addEventListener(e,t,n){const r=s.parseEventName(t),o=s.eventCallback(r.fullKey,n,this.manager.getZone());return this.manager.getZone().runOutsideAngular(()=>Td().onAndCancel(e,r.domEventName,o))}static parseEventName(e){const t=e.toLowerCase().split("."),n=t.shift();if(0===t.length||"keydown"!==n&&"keyup"!==n)return null;const r=s._normalizeKey(t.pop());let o="",a=t.indexOf("code");if(a>-1&&(t.splice(a,1),o="code."),Tx.forEach(c=>{const u=t.indexOf(c);u>-1&&(t.splice(u,1),o+=c+".")}),o+=r,0!=t.length||0===r.length)return null;const l={};return l.domEventName=n,l.fullKey=o,l}static matchEventFullKeyCode(e,t){let n=QY[e.key]||e.key,r="";return t.indexOf("code.")>-1&&(n=e.code,r="code."),!(null==n||!n)&&(n=n.toLowerCase()," "===n?n="space":"."===n&&(n="dot"),Tx.forEach(o=>{o!==n&&(0,qY[o])(e)&&(r+=o+".")}),r+=n,r===t)}static eventCallback(e,t,n){return r=>{s.matchEventFullKeyCode(r,e)&&n.runGuarded(()=>t(r))}}static _normalizeKey(e){return"esc"===e?"escape":e}static{this.\u0275fac=function(t){return new(t||s)(Jt(zl))}}static{this.\u0275prov=Kt({token:s,factory:s.\u0275fac})}}return s})();function wx(s){return{appProviders:[...tQ,...s?.providers??[]],platformProviders:JY}}const JY=[{provide:Vc,useValue:"browser"},{provide:hN,useValue:function ZY(){iC.makeCurrent()},multi:!0},{provide:zl,useFactory:function KY(){return function A2(s){Nb=s}(document),document},deps:[]}],tQ=[{provide:Mb,useValue:"root"},{provide:Zo,useFactory:function XY(){return new Zo},deps:[]},{provide:nC,useClass:YY,multi:!0,deps:[zl,Fi,Vc]},{provide:nC,useClass:$Y,multi:!0,deps:[zl]},Dx,Cx,bx,{provide:hT,useExisting:Dx},{provide:class cY{},useClass:PY,deps:[]},[]];function om(s,i,e,t){var o,n=arguments.length,r=n<3?i:null===t?t=Object.getOwnPropertyDescriptor(i,e):t;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)r=Reflect.decorate(s,i,e,t);else for(var a=s.length-1;a>=0;a--)(o=s[a])&&(r=(n<3?o(r):n>3?o(i,e,r):o(i,e))||r);return n>3&&r&&Object.defineProperty(i,e,r),r}!function uQ(){"function"==typeof Symbol&&Symbol.iterator&&Symbol}();const Su=new Xe("CallSetDisabledState",{providedIn:"root",factory:()=>pm}),pm="always";Promise.resolve(),Promise.resolve();let x8=(()=>{class s{static{this.\u0275fac=function(t){return new(t||s)}}static{this.\u0275mod=Cc({type:s})}static{this.\u0275inj=ml({})}}return s})(),j8=(()=>{class s{static withConfig(e){return{ngModule:s,providers:[{provide:Su,useValue:e.callSetDisabledState??pm}]}}static{this.\u0275fac=function(t){return new(t||s)}}static{this.\u0275mod=Cc({type:s})}static{this.\u0275inj=ml({imports:[x8]})}}return s})();var R8=0,OC=!1;function ym(s,i){var e=i;return e.unshift(void 0),new(Function.prototype.bind.apply(s,e))}function L(s,i){for(var e=i,t=s.replace(/\[/g,".").replace(/\]/g,"").split("."),n=0;n"u"}function Bt(s){return s+"_"+R8++}function Mm(s,i){return s===i||!(s===document||!s)&&Mm(s.parentNode,i)}function zd(s){try{throw new Error(s)}catch(i){throw new Error(i.message+"\n"+i.stack)}}function de(s){var i=s+"";return i.match(/auto|cm|mm|in|px|pt|pc|%|em|ex|ch|rem|vw|vh|vmin|vmax/)?i:i+"px"}function Ne(){return OC}var _d,s,i,H8={latn:{_digits:"0123456789",_type:"numeric"}},K1={decimal:".",group:",",percentSign:"%",plusSign:"+",minusSign:"-",infinity:"\u221e",nan:"NaN",exponential:"E"},J1=[0,1,2,3,4,5,6,7,8,9],Hi=function(){function s(){}return s.getMainObject=function(i,e){return L(Ne()?e:"main."+e,i)},s.getNumberingSystem=function(i){return L("supplemental.numberingSystems",i)||this.numberingSystems},s.reverseObject=function(i,e){for(var n={},r=0,o=e||Object.keys(i);r13&&(g+=1,o-=12),o-=1,a=g-4716;var M=p-24e5,C=10631/30,D=p-1948084,T=Math.floor(D/10631);D-=10631*T;var k=Math.floor((D-.1335)/C),B=30*T+k;D-=Math.floor(k*C+.1335);var re=Math.floor((D+28.5001)/29.5);13===re&&(re=12);for(var le=D-Math.floor(29.5001*re-29),Te=0;TeM);Te++);var Ht=Te+16260,G=Math.floor((Ht-1)/12),ie=G+1,Z=Ht-12*G,z=M-i[Te-1]+1;return(z+"").length>2&&(z=le,Z=re,ie=B),{year:ie,month:Z,date:z}},s.toGregorian=function t(n,r,o){var v=Math.floor(o+i[12*(n-1)+1+(r-1)-16260-1]-1+24e5+.5),b=Math.floor((v-1867216.25)/36524.25),M=1524+(b=v+1+b-Math.floor(b/4)),C=Math.floor((M-122.1)/365.25),D=Math.floor(365.25*C),T=Math.floor((M-D)/30.6001),k=M-D-Math.floor(30.6001*T),B=T-(T>13.5?13:1),re=C-(B>2.5?4716:4715);return re<=0&&B--,new Date(re+"/"+B+"/"+k)};var _e,U8=/\/MMMMM|MMMM|MMM|a|LLLL|LLL|EEEEE|EEEE|E|K|cccc|ccc|WW|W|G+|z+/gi,ek="stand-alone",W8=["sun","mon","tue","wed","thu","fri","sat"],tk={m:"getMinutes",h:"getHours",H:"getHours",s:"getSeconds",d:"getDate",f:"getMilliseconds"},ik=function(){function s(){}return s.dateFormat=function(i,e,t){var n=this,r=_e.getDependables(t,i,e.calendar),o=L("parserObject.numbers",r),a=r.dateObject,l={isIslamic:_e.islamicRegex.test(e.calendar)};Ne()&&e.isServerRendered&&(e=_e.compareBlazorDateFormats(e,i));var c=e.format||_e.getResultantPattern(e.skeleton,r.dateObject,e.type,!1,Ne()?i:"");if(l.dateSeperator=Ne()?L("dateSeperator",a):_e.getDateSeparator(r.dateObject),ke(c))zd("Format options or type given must be invalid");else{c=_e.ConvertDateToWeekFormat(c),Ne()&&(c=c.replace(/tt/,"a")),l.pattern=c,l.numMapper=Ne()?he({},o):Hi.getNumberMapper(r.parserObject,Hi.getNumberingSystem(t));for(var h=0,p=c.match(U8)||[];h2?n+=e.month[""+p]:g=!0;break;case"E":case"c":n+=e.weekday[""+W8[i.getDay()]];break;case"H":case"h":case"m":case"s":case"d":case"f":if(g=!0,"d"===h)p=o.date;else if("f"===h){g=!1,v=!0;var M=(f=(f=i[""+tk[""+h]]().toString()).substring(0,u)).length;if(u!==M){if(u>3)continue;for(var C=0;C0?1:0],o=Math.abs(i);return r.replace(/HH?|mm/g,function(a){var l=a.length,c=-1!==a.indexOf("H");return t.checkTwodigitNumber(Math.floor(c?o/60:o%60),l)})},s}(),nk={ms:"minimumSignificantDigits",ls:"maximumSignificantDigits",mf:"minimumFractionDigits",lf:"maximumFractionDigits"},Tu=["infinity","nan","group","decimal","exponential"],sk=function(){function s(){}return s.numberFormatter=function(i,e,t){var l,n=this,r=he({},e),o={},a={},c=_e.getDependables(t,i,"",!0),u=c.numericObject;a.numberMapper=Ne()?he({},u):Hi.getNumberMapper(c.parserObject,Hi.getNumberingSystem(t),!0),a.currencySymbol=Ne()?L("currencySymbol",u):_e.getCurrencySymbol(c.numericObject,r.currency||Bd,e.altSymbol,e.ignoreCurrency),a.percentSymbol=Ne()?L("numberSymbols.percentSign",u):a.numberMapper.numberSymbols.percentSign,a.minusSymbol=Ne()?L("numberSymbols.minusSign",u):a.numberMapper.numberSymbols.minusSign;var h=a.numberMapper.numberSymbols;if(e.format&&!_e.formatRegex.test(e.format))o=_e.customFormat(e.format,a,c.numericObject),!ke(r.useGrouping)&&r.useGrouping&&(r.useGrouping=o.pData.useGrouping);else{if(he(r,_e.getProperNumericSkeleton(e.format||"N")),r.isCurrency="currency"===r.type,r.isPercent="percent"===r.type,Ne()||(l=_e.getSymbolPattern(r.type,a.numberMapper.numberSystem,c.numericObject,r.isAccount)),r.groupOne=this.checkValueRange(r.maximumSignificantDigits,r.minimumSignificantDigits,!0),this.checkValueRange(r.maximumFractionDigits,r.minimumFractionDigits,!1,!0),ke(r.fractionDigits)||(r.minimumFractionDigits=r.maximumFractionDigits=r.fractionDigits),ke(r.useGrouping)&&(r.useGrouping=!0),r.isCurrency&&!Ne()&&(l=l.replace(/\u00A4/g,_e.defaultCurrency)),Ne())o.nData=he({},{},L(r.type+"nData",u)),o.pData=he({},{},L(r.type+"pData",u)),"currency"===r.type&&e.currency&&_e.replaceBlazorCurrency([o.pData,o.nData],a.currencySymbol,e.currency);else{var p=l.split(";");o.nData=_e.getFormatData(p[1]||"-"+p[0],!0,a.currencySymbol),o.pData=_e.getFormatData(p[0],!1,a.currencySymbol),r.useGrouping&&(r.groupSeparator=h[Tu[2]],r.groupData=this.getGroupingDetails(p[0]))}if(ke(r.minimumFractionDigits)&&(r.minimumFractionDigits=o.nData.minimumFraction),ke(r.maximumFractionDigits)){var g=o.nData.maximumFraction;r.maximumFractionDigits=ke(g)&&r.isPercent?0:g}var v=r.minimumFractionDigits,b=r.maximumFractionDigits;!ke(v)&&!ke(b)&&v>b&&(r.maximumFractionDigits=v)}return he(o.nData,r),he(o.pData,r),function(M){return isNaN(M)?h[Tu[1]]:isFinite(M)?n.intNumberFormatter(M,o,a,e):h[Tu[0]]}},s.getGroupingDetails=function(i){var e={},t=i.match(_e.negativeDataRegex);if(t&&t[4]){var n=t[4],r=n.lastIndexOf(",");if(-1!==r){var o=n.split(".")[0];e.primary=o.length-r-1;var a=n.lastIndexOf(",",r-1);-1!==a&&(e.secondary=r-1-a)}}return e},s.checkValueRange=function(i,e,t,n){var r=n?"f":"s",o=0,a=nk["l"+r],l=nk["m"+r];if(ke(i)||(this.checkRange(i,a,n),o++),ke(e)||(this.checkRange(e,l,n),o++),2===o){if(!(in[1])&&zd(e+"value must be within the range"+n[0]+"to"+n[1])},s.intNumberFormatter=function(i,e,t,n){var r;if(!ke(e.nData.type)){i<0?(i*=-1,r=e.nData):r=0===i&&e.zeroData||e.pData;var o="";if(r.isPercent&&(i*=100),r.groupOne)o=this.processSignificantDigits(i,r.minimumSignificantDigits,r.maximumSignificantDigits);else if(o=this.processFraction(i,r.minimumFractionDigits,r.maximumFractionDigits,n),r.minimumIntegerDigits&&(o=this.processMinimumIntegers(o,r.minimumIntegerDigits)),t.isCustomFormat&&r.minimumFractionDigits=0&&"0"===l[parseInt(u.toString(),10)]&&u>=r.minimumFractionDigits;u--)l=l.slice(0,u);o=a[0]+"."+l}return"scientific"===r.type&&(o=(o=i.toExponential(r.maximumFractionDigits)).replace("e",t.numberMapper.numberSymbols[Tu[4]])),o=o.replace(".",t.numberMapper.numberSymbols[Tu[3]]),o="#,###,,;(#,###,,)"===r.format?this.customPivotFormat(parseInt(o,10)):o,r.useGrouping&&(o=this.groupNumbers(o,r.groupData.primary,r.groupSeparator||",",t.numberMapper.numberSymbols[Tu[3]]||".",r.groupData.secondary)),o=Hi.convertValueParts(o,_e.latnParseRegex,t.numberMapper.mapper),"N/A"===r.nlead?r.nlead:"0"===o&&n&&"0"===n.format?o+r.nend:r.nlead+o+r.nend}},s.processSignificantDigits=function(i,e,t){var n=i+"";return n.lengthe;)u=l.slice(c-e,c)+(u.length?t+u:""),c-=e,o&&(e=r,o=!1);return a[0]=l.slice(0,c)+(u.length?t:"")+u,a.join(n)},s.processFraction=function(i,e,t,n){var r=(i+"").split(".")[1],o=r?r.length:0;if(e&&ot||0===t))return i.toFixed(t);var c=i+"";return"0"===c[0]&&n&&"###.00"===n.format&&(c=c.slice(1)),c},s.processMinimumIntegers=function(i,e){var t=i.split("."),n=t[0],r=n.length;if(r=5e5){var n=(i/=1e6).toString().split(".")[1];return n&&+n.substring(0,1)>=5?Math.ceil(i).toString():Math.floor(i).toString()}return""},s}(),Fd=(new RegExp("^([^0-9]*)(([0-9,]*[0-9]+)(.[0-9]+)?)([Ee][+-]?[0-9]+)?([^0-9]*)$"),function(){function s(i){this.ranArray=[],this.boundedEvents={},!d(i)&&(this.context=i)}return s.prototype.on=function(i,e,t,n){if(!d(e)){var r=t||this.context;if(this.notExist(i))return void(this.boundedEvents[""+i]=[{handler:e,context:r,id:n}]);d(n)?this.isHandlerPresent(this.boundedEvents[""+i],e)||this.boundedEvents[""+i].push({handler:e,context:r}):-1===this.ranArray.indexOf(n)&&(this.ranArray.push(n),this.boundedEvents[""+i].push({handler:e,context:r,id:n}))}},s.prototype.off=function(i,e,t){if(!this.notExist(i)){var n=L(i,this.boundedEvents);if(e){for(var r=0;r1&&(Q.fractionDigits=parseInt(F[2],10)),Q}function g(z,F,Q,P){var H=P?{}:{nlead:"",nend:""},q=z.match(s.customRegex);if(q){P||(H.nlead=v(q[1],Q),H.nend=v(q[10],Q),H.groupPattern=q[4]);var ye=q[7];if(ye&&F){var We=ye.match(i);H.minimumFraction=d(We)?0:We.length,H.maximumFraction=ye.length-1}}return H}function v(z,F){return z?(z=z.replace(s.defaultCurrency,F),""===F?z.trim():z):""}function b(z,F,Q,P){return P?"$":L("currencies."+F+(Q?"."+Q:".symbol"),z)||L("currencies."+F+".symbol-alt-narrow",z)||"$"}function C(z,F,Q){var P={type:"decimal",minimumFractionDigits:0,maximumFractionDigits:0},H=z.match(s.customRegex);if(d(H)||""===H[5]&&"N/A"!==z)return P.type=void 0,P;P.nlead=H[1],P.nend=H[10];var q=H[6],ye=!!q.match(/ $/g),We=-1!==q.replace(/ $/g,"").indexOf(" ");P.useGrouping=-1!==q.indexOf(",")||We,q=q.replace(/,/g,"");var De=H[7];if(-1!==q.indexOf("0")&&(P.minimumIntegerDigits=q.length-q.indexOf("0")),d(De)||(P.minimumFractionDigits=De.lastIndexOf("0"),P.maximumFractionDigits=De.lastIndexOf("#"),-1===P.minimumFractionDigits&&(P.minimumFractionDigits=0),(-1===P.maximumFractionDigits||P.maximumFractionDigitsq.lastIndexOf("'"))){P[""+a[parseInt(H.toString(),10)]]=q.substr(0,ye)+Q+q.substr(ye+1),P[""+a[""+F]]=!0,P.type=P.isCurrency?"currency":"percent";break}}return P}function B(z,F){if(-1!==z.indexOf(",")){var Q=z.split(",");z=Q[0]+L("numberMapper.numberSymbols.group",F)+Q[1].replace(".",L("numberMapper.numberSymbols.decimal",F))}else z=z.replace(".",L("numberMapper.numberSymbols.decimal",F));return z}function le(z,F,Q){z+=".";for(var P=0;P0;q-=3)z=","+Q[q-2]+Q[q-1]+Q[parseInt(q.toString(),10)]+z;return z=z.slice(1),F[1]?z+"."+F[1]:z}s.dateParseRegex=/([a-z])\1*|'([^']|'')+'|''|./gi,s.basicPatterns=["short","medium","long","full"],s.defaultObject={dates:{calendars:{gregorian:{months:{"stand-alone":{abbreviated:{1:"Jan",2:"Feb",3:"Mar",4:"Apr",5:"May",6:"Jun",7:"Jul",8:"Aug",9:"Sep",10:"Oct",11:"Nov",12:"Dec"},narrow:{1:"J",2:"F",3:"M",4:"A",5:"M",6:"J",7:"J",8:"A",9:"S",10:"O",11:"N",12:"D"},wide:{1:"January",2:"February",3:"March",4:"April",5:"May",6:"June",7:"July",8:"August",9:"September",10:"October",11:"November",12:"December"}}},days:{"stand-alone":{abbreviated:{sun:"Sun",mon:"Mon",tue:"Tue",wed:"Wed",thu:"Thu",fri:"Fri",sat:"Sat"},narrow:{sun:"S",mon:"M",tue:"T",wed:"W",thu:"T",fri:"F",sat:"S"},short:{sun:"Su",mon:"Mo",tue:"Tu",wed:"We",thu:"Th",fri:"Fr",sat:"Sa"},wide:{sun:"Sunday",mon:"Monday",tue:"Tuesday",wed:"Wednesday",thu:"Thursday",fri:"Friday",sat:"Saturday"}}},dayPeriods:{format:{wide:{am:"AM",pm:"PM"}}},eras:{eraNames:{0:"Before Christ","0-alt-variant":"Before Common Era",1:"Anno Domini","1-alt-variant":"Common Era"},eraAbbr:{0:"BC","0-alt-variant":"BCE",1:"AD","1-alt-variant":"CE"},eraNarrow:{0:"B","0-alt-variant":"BCE",1:"A","1-alt-variant":"CE"}},dateFormats:{full:"EEEE, MMMM d, y",long:"MMMM d, y",medium:"MMM d, y",short:"M/d/yy"},timeFormats:{full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},dateTimeFormats:{full:"{1} 'at' {0}",long:"{1} 'at' {0}",medium:"{1}, {0}",short:"{1}, {0}",availableFormats:{d:"d",E:"ccc",Ed:"d E",Ehm:"E h:mm a",EHm:"E HH:mm",Ehms:"E h:mm:ss a",EHms:"E HH:mm:ss",Gy:"y G",GyMMM:"MMM y G",GyMMMd:"MMM d, y G",GyMMMEd:"E, MMM d, y G",h:"h a",H:"HH",hm:"h:mm a",Hm:"HH:mm",hms:"h:mm:ss a",Hms:"HH:mm:ss",hmsv:"h:mm:ss a v",Hmsv:"HH:mm:ss v",hmv:"h:mm a v",Hmv:"HH:mm v",M:"L",Md:"M/d",MEd:"E, M/d",MMM:"LLL",MMMd:"MMM d",MMMEd:"E, MMM d",MMMMd:"MMMM d",ms:"mm:ss",y:"y",yM:"M/y",yMd:"M/d/y",yMEd:"E, M/d/y",yMMM:"MMM y",yMMMd:"MMM d, y",yMMMEd:"E, MMM d, y",yMMMM:"MMMM y"}}},islamic:{months:{"stand-alone":{abbreviated:{1:"Muh.",2:"Saf.",3:"Rab. I",4:"Rab. II",5:"Jum. I",6:"Jum. II",7:"Raj.",8:"Sha.",9:"Ram.",10:"Shaw.",11:"Dhu\u02bbl-Q.",12:"Dhu\u02bbl-H."},narrow:{1:"1",2:"2",3:"3",4:"4",5:"5",6:"6",7:"7",8:"8",9:"9",10:"10",11:"11",12:"12"},wide:{1:"Muharram",2:"Safar",3:"Rabi\u02bb I",4:"Rabi\u02bb II",5:"Jumada I",6:"Jumada II",7:"Rajab",8:"Sha\u02bbban",9:"Ramadan",10:"Shawwal",11:"Dhu\u02bbl-Qi\u02bbdah",12:"Dhu\u02bbl-Hijjah"}}},days:{"stand-alone":{abbreviated:{sun:"Sun",mon:"Mon",tue:"Tue",wed:"Wed",thu:"Thu",fri:"Fri",sat:"Sat"},narrow:{sun:"S",mon:"M",tue:"T",wed:"W",thu:"T",fri:"F",sat:"S"},short:{sun:"Su",mon:"Mo",tue:"Tu",wed:"We",thu:"Th",fri:"Fr",sat:"Sa"},wide:{sun:"Sunday",mon:"Monday",tue:"Tuesday",wed:"Wednesday",thu:"Thursday",fri:"Friday",sat:"Saturday"}}},dayPeriods:{format:{wide:{am:"AM",pm:"PM"}}},eras:{eraNames:{0:"AH"},eraAbbr:{0:"AH"},eraNarrow:{0:"AH"}},dateFormats:{full:"EEEE, MMMM d, y G",long:"MMMM d, y G",medium:"MMM d, y G",short:"M/d/y GGGGG"},timeFormats:{full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},dateTimeFormats:{full:"{1} 'at' {0}",long:"{1} 'at' {0}",medium:"{1}, {0}",short:"{1}, {0}",availableFormats:{d:"d",E:"ccc",Ed:"d E",Ehm:"E h:mm a",EHm:"E HH:mm",Ehms:"E h:mm:ss a",EHms:"E HH:mm:ss",Gy:"y G",GyMMM:"MMM y G",GyMMMd:"MMM d, y G",GyMMMEd:"E, MMM d, y G",h:"h a",H:"HH",hm:"h:mm a",Hm:"HH:mm",hms:"h:mm:ss a",Hms:"HH:mm:ss",M:"L",Md:"M/d",MEd:"E, M/d",MMM:"LLL",MMMd:"MMM d",MMMEd:"E, MMM d",MMMMd:"MMMM d",ms:"mm:ss",y:"y G",yyyy:"y G",yyyyM:"M/y GGGGG",yyyyMd:"M/d/y GGGGG",yyyyMEd:"E, M/d/y GGGGG",yyyyMMM:"MMM y G",yyyyMMMd:"MMM d, y G",yyyyMMMEd:"E, MMM d, y G",yyyyMMMM:"MMMM y G",yyyyQQQ:"QQQ y G",yyyyQQQQ:"QQQQ y G"}}}},timeZoneNames:{hourFormat:"+HH:mm;-HH:mm",gmtFormat:"GMT{0}",gmtZeroFormat:"GMT"}},numbers:{currencies:{USD:{displayName:"US Dollar",symbol:"$","symbol-alt-narrow":"$"},EUR:{displayName:"Euro",symbol:"\u20ac","symbol-alt-narrow":"\u20ac"},GBP:{displayName:"British Pound","symbol-alt-narrow":"\xa3"}},defaultNumberingSystem:"latn",minimumGroupingDigits:"1","symbols-numberSystem-latn":{decimal:".",group:",",list:";",percentSign:"%",plusSign:"+",minusSign:"-",exponential:"E",superscriptingExponent:"\xd7",perMille:"\u2030",infinity:"\u221e",nan:"NaN",timeSeparator:":"},"decimalFormats-numberSystem-latn":{standard:"#,##0.###"},"percentFormats-numberSystem-latn":{standard:"#,##0%"},"currencyFormats-numberSystem-latn":{standard:"\xa4#,##0.00",accounting:"\xa4#,##0.00;(\xa4#,##0.00)"},"scientificFormats-numberSystem-latn":{standard:"#E0"}}},s.blazorDefaultObject={numbers:{mapper:{0:"0",1:"1",2:"2",3:"3",4:"4",5:"5",6:"6",7:"7",8:"8",9:"9"},mapperDigits:"0123456789",numberSymbols:{decimal:".",group:",",plusSign:"+",minusSign:"-",percentSign:"%",nan:"NaN",timeSeparator:":",infinity:"\u221e"},timeSeparator:":",currencySymbol:"$",currencypData:{nlead:"$",nend:"",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},percentpData:{nlead:"",nend:"%",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},percentnData:{nlead:"-",nend:"%",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},currencynData:{nlead:"($",nend:")",groupSeparator:",",groupData:{primary:3},maximumFraction:2,minimumFraction:2},decimalnData:{nlead:"-",nend:"",groupData:{primary:3},maximumFraction:2,minimumFraction:2},decimalpData:{nlead:"",nend:"",groupData:{primary:3},maximumFraction:2,minimumFraction:2}},dates:{dayPeriods:{am:"AM",pm:"PM"},dateSeperator:"/",days:{abbreviated:{sun:"Sun",mon:"Mon",tue:"Tue",wed:"Wed",thu:"Thu",fri:"Fri",sat:"Sat"},short:{sun:"Su",mon:"Mo",tue:"Tu",wed:"We",thu:"Th",fri:"Fr",sat:"Sa"},wide:{sun:"Sunday",mon:"Monday",tue:"Tuesday",wed:"Wednesday",thu:"Thursday",fri:"Friday",sat:"Saturday"}},months:{abbreviated:{1:"Jan",2:"Feb",3:"Mar",4:"Apr",5:"May",6:"Jun",7:"Jul",8:"Aug",9:"Sep",10:"Oct",11:"Nov",12:"Dec"},wide:{1:"January",2:"February",3:"March",4:"April",5:"May",6:"June",7:"July",8:"August",9:"September",10:"October",11:"November",12:"December"}},eras:{1:"AD"}}},s.monthIndex={3:"abbreviated",4:"wide",5:"narrow",1:"abbreviated"},s.month="months",s.days="days",s.patternMatcher={C:"currency",P:"percent",N:"decimal",A:"currency",E:"scientific"},s.getResultantPattern=l,s.getDependables=c,s.getSymbolPattern=u,s.ConvertDateToWeekFormat=h,s.compareBlazorDateFormats=p,s.getProperNumericSkeleton=f,s.getFormatData=g,s.changeCurrencySymbol=v,s.getCurrencySymbol=b,s.customFormat=function M(z,F,Q){for(var P={},H=z.split(";"),q=["pData","nData","zeroData"],ye=0;ye1,De.nData=Ne()?L(Ye.type+"nData",ye):g(tn[1]||"-"+tn[0],!0,Se),De.pData=Ne()?L(Ye.type+"pData",ye):g(tn[0],!1,Se),!Be[2]&&!F.minimumFractionDigits&&!F.maximumFractionDigits&&(We=g(Xt.split(";")[0],!0,"",!0).minimumFraction)}if(s.formatRegex.test(F.format)||!F.format){if(he(q,f(F.format||"N")),q.custom=!1,Nt="###0",(q.fractionDigits||F.minimumFractionDigits||F.maximumFractionDigits||We)&&(q.fractionDigits&&(F.minimumFractionDigits=F.maximumFractionDigits=q.fractionDigits),Nt=le(Nt,We||q.fractionDigits||F.minimumFractionDigits||0,F.maximumFractionDigits||0)),F.minimumIntegerDigits&&(Nt=Te(Nt,F.minimumIntegerDigits)),F.useGrouping&&(Nt=Ht(Nt)),"currency"===q.type||q.type&&Ne()){Ne()&&"currency"!==q.type&&(De.pData=L(q.type+"pData",ye),De.nData=L(q.type+"nData",ye));var js=Nt;Nt=De.pData.nlead+js+De.pData.nend,(De.hasNegativePattern||Ne())&&(Nt+=";"+De.nData.nlead+js+De.nData.nend)}"percent"===q.type&&!Ne()&&(Nt+=" %")}else Nt=F.format.replace(/'/g,'"');return Object.keys(rt).length>0&&(Nt=P?Nt:B(Nt,rt)),Nt},s.fractionDigitsPattern=le,s.minimumIntegerPattern=Te,s.groupingPattern=Ht,s.getWeekData=function G(z,F){var Q="sun",P=L("supplemental.weekData.firstDay",F),H=z;return/en-/.test(H)&&(H=H.slice(3)),H=H.slice(0,2).toUpperCase()+H.substr(2),P&&(Q=P[""+H]||P[H.slice(0,2)]||"sun"),o[""+Q]},s.replaceBlazorCurrency=function ie(z,F,Q){var P=function V8(s){return L(s||"",B8)}(Q);if(F!==P)for(var H=0,q=z;H=0?Q:Q+7;var H=Math.floor((z.getTime()-F.getTime()-6e4*(z.getTimezoneOffset()-F.getTimezoneOffset()))/864e5)+1;if(Q<4){if((P=Math.floor((H+Q-1)/7)+1)>52){var ye=new Date(z.getFullYear()+1,0,1).getDay();P=(ye=ye>=0?ye:ye+7)<4?1:53}}else P=Math.floor((H+Q-1)/7);return P}}(_e||(_e={}));var jC=function(){function s(i,e,t){this.type="GET",this.emitError=!0,"string"==typeof i?(this.url=i,this.type=d(e)?this.type:e.toUpperCase(),this.contentType=t):Hr(i)&&Object.keys(i).length>0&&In(this,i),this.contentType=d(this.contentType)?"application/json; charset=utf-8":this.contentType}return s.prototype.send=function(i){var e=this,t={"application/json":"json","multipart/form-data":"formData","application/octet-stream":"blob","application/x-www-form-urlencoded":"formData"};try{d(this.fetchRequest)&&"GET"===this.type?this.fetchRequest=new Request(this.url,{method:this.type}):d(this.fetchRequest)&&(this.data=d(i)?this.data:i,this.fetchRequest=new Request(this.url,{method:this.type,headers:{"Content-Type":this.contentType},body:this.data}));var n={cancel:!1,fetchRequest:this.fetchRequest};return this.triggerEvent(this.beforeSend,n),n.cancel?null:(this.fetchResponse=fetch(this.fetchRequest),this.fetchResponse.then(function(r){if(e.triggerEvent(e.onLoad,r),!r.ok)throw r;for(var o="text",a=0,l=Object.keys(t);a-1},s.getValue=function(i,e){var t=typeof window<"u"?window.browserDetails:{};return typeof navigator<"u"&&"MacIntel"===navigator.platform&&navigator.maxTouchPoints>1&&!0===s.isTouch&&!RC.CHROME.test(navigator.userAgent)&&(t.isIos=!0,t.isDevice=!0,t.isTouch=!0,t.isPointer=!0,t.isPointer="pointerEnabled"in window.navigator),typeof window<"u"&&window.Capacitor&&"ios"===window.Capacitor.getPlatform()&&(t.isPointer=!1),typeof t[""+i]>"u"?t[""+i]=e.test(s.userAgent):t[""+i]},Object.defineProperty(s,"userAgent",{get:function(){return s.uA},set:function(i){s.uA=i,window.browserDetails={}},enumerable:!0,configurable:!0}),Object.defineProperty(s,"info",{get:function(){return ke(window.browserDetails.info)?window.browserDetails.info=s.extractBrowserDetail():window.browserDetails.info},enumerable:!0,configurable:!0}),Object.defineProperty(s,"isIE",{get:function(){return s.getValue("isIE",s9)},enumerable:!0,configurable:!0}),Object.defineProperty(s,"isTouch",{get:function(){return ke(window.browserDetails.isTouch)?window.browserDetails.isTouch="ontouchstart"in window.navigator||window&&window.navigator&&window.navigator.maxTouchPoints>0||"ontouchstart"in window:window.browserDetails.isTouch},enumerable:!0,configurable:!0}),Object.defineProperty(s,"isPointer",{get:function(){return ke(window.browserDetails.isPointer)?window.browserDetails.isPointer="pointerEnabled"in window.navigator:window.browserDetails.isPointer},enumerable:!0,configurable:!0}),Object.defineProperty(s,"isMSPointer",{get:function(){return ke(window.browserDetails.isMSPointer)?window.browserDetails.isMSPointer="msPointerEnabled"in window.navigator:window.browserDetails.isMSPointer},enumerable:!0,configurable:!0}),Object.defineProperty(s,"isDevice",{get:function(){return s.getValue("isDevice",n9)},enumerable:!0,configurable:!0}),Object.defineProperty(s,"isIos",{get:function(){return s.getValue("isIos",o9)},enumerable:!0,configurable:!0}),Object.defineProperty(s,"isIos7",{get:function(){return s.getValue("isIos7",a9)},enumerable:!0,configurable:!0}),Object.defineProperty(s,"isAndroid",{get:function(){return s.getValue("isAndroid",l9)},enumerable:!0,configurable:!0}),Object.defineProperty(s,"isWebView",{get:function(){return ke(window.browserDetails.isWebView)&&(window.browserDetails.isWebView=!(ke(window.cordova)&&ke(window.PhoneGap)&&ke(window.phonegap)&&"object"!==window.forge)),window.browserDetails.isWebView},enumerable:!0,configurable:!0}),Object.defineProperty(s,"isWindows",{get:function(){return s.getValue("isWindows",c9)},enumerable:!0,configurable:!0}),Object.defineProperty(s,"touchStartEvent",{get:function(){return ke(window.browserDetails.touchStartEvent)?window.browserDetails.touchStartEvent=s.getTouchStartEvent():window.browserDetails.touchStartEvent},enumerable:!0,configurable:!0}),Object.defineProperty(s,"touchMoveEvent",{get:function(){return ke(window.browserDetails.touchMoveEvent)?window.browserDetails.touchMoveEvent=s.getTouchMoveEvent():window.browserDetails.touchMoveEvent},enumerable:!0,configurable:!0}),Object.defineProperty(s,"touchEndEvent",{get:function(){return ke(window.browserDetails.touchEndEvent)?window.browserDetails.touchEndEvent=s.getTouchEndEvent():window.browserDetails.touchEndEvent},enumerable:!0,configurable:!0}),Object.defineProperty(s,"touchCancelEvent",{get:function(){return ke(window.browserDetails.touchCancelEvent)?window.browserDetails.touchCancelEvent=s.getTouchCancelEvent():window.browserDetails.touchCancelEvent},enumerable:!0,configurable:!0}),s.uA=typeof navigator<"u"?navigator.userAgent:"",s}(),y=function(){function s(){}return s.addOrGetEventData=function(i){return"__eventList"in i?i.__eventList.events:(i.__eventList={},i.__eventList.events=[])},s.add=function(i,e,t,n,r){var a,o=s.addOrGetEventData(i);a=r?function z8(s,i){var e;return function(){for(var t=this,n=[],r=0;r"u"||(e.innerHTML=i.innerHTML?i.innerHTML:"",void 0!==i.className&&(e.className=i.className),void 0!==i.id&&(e.id=i.id),void 0!==i.styles&&e.setAttribute("style",i.styles),void 0!==i.attrs&&ge(e,i.attrs)),e}function N(s,i){for(var e=hk(i),t=RegExp,n=0,r=s;n0}function yo(s,i,e){for(var t=document.createDocumentFragment(),n=0,r=s;n0;)t.appendChild(s[0]);else for(var n=0,r=s;n-1&&!n[parseInt(r.toString(),10)].match(/\[.*\]/)){var o=n[parseInt(r.toString(),10)].split("#");if(o[1].match(/^\d/)||o[1].match(i)){var a=n[parseInt(r.toString(),10)].split(".");a[0]=a[0].replace(/#/,"[id='")+"']",n[parseInt(r.toString(),10)]=a.join(".")}}e[parseInt(t.toString(),10)]=n.join(" ")}return e.join(",")}return s}function j(s,i){var e=s;if("function"==typeof e.closest)return e.closest(i);for(;e&&1===e.nodeType;){if(PC(e,i))return e;e=e.parentNode}return null}function be(s,i){void 0!==i&&Object.keys(i).forEach(function(e){s.style[""+e]=i[""+e]})}function qn(s,i,e){N([s],i),R([s],e)}function PC(s,i){var e=s.matches||s.msMatchesSelector||s.webkitMatchesSelector;return e?e.call(s,i):-1!==[].indexOf.call(document.querySelectorAll(i),s)}var d9=new RegExp("]"),sa=function(){function s(i,e){this.isRendered=!1,this.isComplexArraySetter=!1,this.isServerRendered=!1,this.allowServerDataBinding=!0,this.isProtectedOnChange=!0,this.properties={},this.changedProperties={},this.oldProperties={},this.bulkChanges={},this.refreshing=!1,this.ignoreCollectionWatch=!1,this.finalUpdate=function(){},this.childChangedProperties={},this.modelObserver=new Fd(this),ke(e)||(this.element="string"==typeof e?document.querySelector(e):e,d(this.element)||(this.isProtectedOnChange=!1,this.addInstance())),ke(i)||this.setProperties(i,!0),this.isDestroyed=!1}return s.prototype.setProperties=function(i,e){var t=this.isProtectedOnChange;this.isProtectedOnChange=!!e,In(this,i),!0!==e?(In(this.changedProperties,i),this.dataBind()):Ne()&&this.isRendered&&this.serverDataBind(i),this.finalUpdate(),this.changedProperties={},this.oldProperties={},this.isProtectedOnChange=t},s.callChildDataBind=function(i,e){for(var n=0,r=Object.keys(i);n=0;a--)(o=s[a])&&(r=(n<3?o(r):n>3?o(i,e,r):o(i,e))||r);return n>3&&r&&Object.defineProperty(i,e,r),r},ds=function(s){function i(t){var n=s.call(this,t,void 0)||this;return n.easing={ease:"cubic-bezier(0.250, 0.100, 0.250, 1.000)",linear:"cubic-bezier(0.250, 0.250, 0.750, 0.750)",easeIn:"cubic-bezier(0.420, 0.000, 1.000, 1.000)",easeOut:"cubic-bezier(0.000, 0.000, 0.580, 1.000)",easeInOut:"cubic-bezier(0.420, 0.000, 0.580, 1.000)",elasticInOut:"cubic-bezier(0.5,-0.58,0.38,1.81)",elasticIn:"cubic-bezier(0.17,0.67,0.59,1.81)",elasticOut:"cubic-bezier(0.7,-0.75,0.99,1.01)"},n}var e;return E9(i,s),e=i,i.prototype.animate=function(t,n){var r=this.getModel(n=n||{});if("string"==typeof t)for(var a=0,l=Array.prototype.slice.call(se(t,document));a0?n-1:0,t+=e=-1!==e?"-"+e:"-"+n}return this.controlParent!==this.parentObj&&(t=this.parentObj.getParentKey()+"."+this.propName+e),t},s}(),w9=["grid","pivotview","treegrid","spreadsheet","rangeNavigator","DocumentEditor","listbox","inplaceeditor","PdfViewer","richtexteditor","DashboardLayout","chart","stockChart","circulargauge","diagram","heatmap","lineargauge","maps","slider","smithchart","barcode","sparkline","treemap","bulletChart","kanban","daterangepicker","schedule","gantt","signature","query-builder","drop-down-tree","carousel","filemanager","uploader","accordion","tab","treeview"],Ik=[115,121,110,99,102,117,115,105,111,110,46,105,115,76,105,99,86,97,108,105,100,97,116,101,100],Ek=function(){function s(i){this.isValidated=!1,this.isLicensed=!0,this.version="27",this.platform=/JavaScript|ASPNET|ASPNETCORE|ASPNETMVC|FileFormats|essentialstudio/i,this.errors={noLicense:"This application was built using a trial version of Syncfusion Essential Studio. To remove the license validation message permanently, a valid license key must be included.",trailExpired:"This application was built using a trial version of Syncfusion Essential Studio. To remove the license validation message permanently, a valid license key must be included.",versionMismatched:"The included Syncfusion license key is invalid.",platformMismatched:"The included Syncfusion license key is invalid.",invalidKey:"The included Syncfusion license key is invalid."},this.manager=function(){var e=null;return{setKey:function t(r){e=r},getKey:function n(){return e}}}(),this.npxManager=function(){return{getKey:function t(){return"npxKeyReplace"}}}(),this.manager.setKey(i)}return s.prototype.validate=function(){if(!this.isValidated&&Nu&&!L(Em(Ik),Nu)&&!L("Blazor",Nu)){var t=void 0,n=void 0;if(this.manager&&this.manager.getKey()||this.npxManager&&"npxKeyReplace"!==this.npxManager.getKey()){var r=this.getInfoFromKey();if(r&&r.length)for(var o=0,a=r;o"+t+' Claim your FREE account\n
have a Syncfusion account? Sign In
\n
\n ';if(typeof document<"u"&&!d(document)){var i=_t("div",{innerHTML:s});document.body.appendChild(i)}}(),Tk=!0),this.render(),this.mount?this.accessMount():this.trigger("created")}},i.prototype.renderComplete=function(e){Ne()&&window.sfBlazor.renderComplete(this.element,e),this.isRendered=!0},i.prototype.dataBind=function(){this.injectModules(),s.prototype.dataBind.call(this)},i.prototype.on=function(e,t,n){if("string"==typeof e)this.localObserver.on(e,t,n);else for(var r=0,o=e;r=0;a--)(o=s[a])&&(r=(n<3?o(r):n>3?o(i,e,r):o(i,e))||r);return n>3&&r&&Object.defineProperty(i,e,r),r},k9={left:0,top:0,bottom:0,right:0},BC={isDragged:!1},j9=function(s){function i(){return null!==s&&s.apply(this,arguments)||this}return wk(i,s),Ei([m(0)],i.prototype,"left",void 0),Ei([m(0)],i.prototype,"top",void 0),i}(Lt),Yd=function(s){function i(t,n){var r=s.call(this,n,t)||this;return r.dragLimit=e.getDefaultPosition(),r.borderWidth=e.getDefaultPosition(),r.padding=e.getDefaultPosition(),r.diffX=0,r.prevLeft=0,r.prevTop=0,r.dragProcessStarted=!1,r.eleTop=0,r.tapHoldTimer=0,r.externalInitialize=!1,r.diffY=0,r.parentScrollX=0,r.parentScrollY=0,r.droppables={},r.bind(),r}var e;return wk(i,s),e=i,i.prototype.bind=function(){this.toggleEvents(),_.isIE&&N([this.element],"e-block-touch"),this.droppables[this.scope]={}},i.getDefaultPosition=function(){return he({},k9)},i.prototype.toggleEvents=function(t){var n;ke(this.handle)||(n=S(this.handle,this.element));var r=this.enableTapHold&&_.isDevice&&_.isTouch?this.mobileInitialize:this.initialize;t?y.remove(n||this.element,_.isSafari()?"touchstart":_.touchStartEvent,r):y.add(n||this.element,_.isSafari()?"touchstart":_.touchStartEvent,r,this)},i.prototype.mobileInitialize=function(t){var n=this,r=t.currentTarget;this.tapHoldTimer=setTimeout(function(){n.externalInitialize=!0,n.removeTapholdTimer(),n.initialize(t,r)},this.tapHoldThreshold),y.add(document,_.isSafari()?"touchmove":_.touchMoveEvent,this.removeTapholdTimer,this),y.add(document,_.isSafari()?"touchend":_.touchEndEvent,this.removeTapholdTimer,this)},i.prototype.removeTapholdTimer=function(){clearTimeout(this.tapHoldTimer),y.remove(document,_.isSafari()?"touchmove":_.touchMoveEvent,this.removeTapholdTimer),y.remove(document,_.isSafari()?"touchend":_.touchEndEvent,this.removeTapholdTimer)},i.prototype.getScrollableParent=function(t,n){return d(t)?null:t[{vertical:"scrollHeight",horizontal:"scrollWidth"}[""+n]]>t[{vertical:"clientHeight",horizontal:"clientWidth"}[""+n]]&&("vertical"===n?t.scrollTop>0:t.scrollLeft>0)?("vertical"===n?(this.parentScrollY=this.parentScrollY+(0===this.parentScrollY?t.scrollTop:t.scrollTop-this.parentScrollY),this.tempScrollHeight=t.scrollHeight):(this.parentScrollX=this.parentScrollX+(0===this.parentScrollX?t.scrollLeft:t.scrollLeft-this.parentScrollX),this.tempScrollWidth=t.scrollWidth),d(t)?t:this.getScrollableParent(t.parentNode,n)):this.getScrollableParent(t.parentNode,n)},i.prototype.getScrollableValues=function(){this.parentScrollX=0,this.parentScrollY=0,this.element.classList.contains("e-dialog")&&this.element.classList.contains("e-dlg-modal"),this.getScrollableParent(this.element.parentNode,"vertical"),this.getScrollableParent(this.element.parentNode,"horizontal")},i.prototype.initialize=function(t,n){if(this.currentStateTarget=t.target,!this.isDragStarted()){if(this.isDragStarted(!0),this.externalInitialize=!1,this.target=t.currentTarget||n,this.dragProcessStarted=!1,this.abort){var r=this.abort;"string"==typeof r&&(r=[r]);for(var o=0;o=this.distance||this.externalInitialize){var f=this.getHelperElement(t);if(!f||d(f))return;n&&t.preventDefault();var g=this.helperElement=f;if(this.parentClientRect=this.calculateParentPosition(g.offsetParent),this.dragStart){var b={event:t,element:l,target:this.getProperTargetElement(t),bindEvents:Ne()?this.bindDragEvents.bind(this):null,dragElement:g};this.trigger("dragStart",b)}this.dragArea?this.setDragArea():(this.dragLimit={left:0,right:0,bottom:0,top:0},this.borderWidth={top:0,left:0}),o={left:this.position.left-this.parentClientRect.left,top:this.position.top-this.parentClientRect.top},this.clone&&!this.enableTailMode&&(this.diffX=this.position.left-this.offset.left,this.diffY=this.position.top-this.offset.top),this.getScrollableValues();var M=getComputedStyle(l),C=parseFloat(M.marginTop);this.clone&&0!==C&&(o.top+=C),this.eleTop=isNaN(parseFloat(M.top))?0:parseFloat(M.top)-this.offset.top,this.enableScrollHandler&&!this.clone&&(o.top-=this.parentScrollY,o.left-=this.parentScrollX);var D=this.getProcessedPositionValue({top:o.top-this.diffY+"px",left:o.left-this.diffX+"px"});this.dragArea&&"string"!=typeof this.dragArea&&this.dragArea.classList.contains("e-kanban-content")&&"relative"===this.dragArea.style.position&&(o.top+=this.dragArea.scrollTop),this.dragElePosition={top:o.top,left:o.left},be(g,this.getDragPosition({position:"absolute",left:D.left,top:D.top})),y.remove(document,_.isSafari()?"touchmove":_.touchMoveEvent,this.intDragStart),y.remove(document,_.isSafari()?"touchend":_.touchEndEvent,this.intDestroy),Ne()||this.bindDragEvents(g)}}},i.prototype.bindDragEvents=function(t){ji(t)?(y.add(document,_.isSafari()?"touchmove":_.touchMoveEvent,this.intDrag,this),y.add(document,_.isSafari()?"touchend":_.touchEndEvent,this.intDragStop,this),this.setGlobalDroppables(!1,this.element,t)):(this.toggleEvents(),document.body.classList.remove("e-prevent-select"))},i.prototype.elementInViewport=function(t){for(this.top=t.offsetTop,this.left=t.offsetLeft,this.width=t.offsetWidth,this.height=t.offsetHeight;t.offsetParent;)this.top+=(t=t.offsetParent).offsetTop,this.left+=t.offsetLeft;return this.top>=window.pageYOffset&&this.left>=window.pageXOffset&&this.top+this.height<=window.pageYOffset+window.innerHeight&&this.left+this.width<=window.pageXOffset+window.innerWidth},i.prototype.getProcessedPositionValue=function(t){return this.queryPositionInfo?this.queryPositionInfo(t):t},i.prototype.calculateParentPosition=function(t){if(d(t))return{left:0,top:0};var n=t.getBoundingClientRect(),r=getComputedStyle(t);return{left:n.left+window.pageXOffset-parseInt(r.marginLeft,10),top:n.top+window.pageYOffset-parseInt(r.marginTop,10)}},i.prototype.intDrag=function(t){if(ke(t.changedTouches)||1===t.changedTouches.length){var n,r;this.clone&&t.changedTouches&&_.isDevice&&_.isTouch&&t.preventDefault(),this.position=this.getMousePosition(t,this.isDragScroll);var o=this.getDocumentWidthHeight("Height");oM&&M>0?this.dragLimit.left:this.dragLimit.right+window.pageXOffset0?M-(M-this.dragLimit.right)+window.pageXOffset-T:M<0?this.dragLimit.left:M}if(this.pageY!==b||this.skipDistanceCheck){var k=h.offsetHeight+(parseFloat(D.marginTop)+parseFloat(D.marginBottom));r=this.dragLimit.top>C&&C>0?this.dragLimit.top:this.dragLimit.bottom+window.pageYOffset0?C-(C-this.dragLimit.bottom)+window.pageYOffset-k:C<0?this.dragLimit.top:C}}else n=M,r=C;var le,Te,B=f+this.borderWidth.top,re=p+this.borderWidth.left;if(this.dragProcessStarted&&(d(r)&&(r=this.prevTop),d(n)&&(n=this.prevLeft)),this.helperElement.classList.contains("e-treeview"))this.dragArea?(this.dragLimit.top=this.clone?this.dragLimit.top:0,le=r-B<0?this.dragLimit.top:r-this.borderWidth.top,Te=n-re<0?this.dragLimit.left:n-this.borderWidth.left):(le=r-this.borderWidth.top,Te=n-this.borderWidth.left);else if(this.dragArea){var Ht=this.helperElement.classList.contains("e-dialog");this.dragLimit.top=this.clone?this.dragLimit.top:0,le=r-B<0?this.dragLimit.top:r-B,Te=n-re<0?Ht?n-(re-this.borderWidth.left):this.dragElePosition.left:n-re}else le=r-B,Te=n-re;var G=parseFloat(getComputedStyle(this.element).marginTop);if(G>0&&(this.clone&&(le+=G,C<0&&(G+C>=0?le=G+C:le-=G),this.dragArea&&(le=this.dragLimit.bottom=0){var ie=this.dragLimit.top+C-B;ie+G+B<0?le-=G+B:le=ie}else le-=G+B;this.dragArea&&this.helperElement.classList.contains("e-treeview")&&(le=le+(k=h.offsetHeight+(parseFloat(D.marginTop)+parseFloat(D.marginBottom)))>this.dragLimit.bottom?this.dragLimit.bottom-k:le),this.enableScrollHandler&&!this.clone&&(le-=this.parentScrollY,Te-=this.parentScrollX),this.dragArea&&"string"!=typeof this.dragArea&&this.dragArea.classList.contains("e-kanban-content")&&"relative"===this.dragArea.style.position&&(le+=this.dragArea.scrollTop);var Z=this.getProcessedPositionValue({top:le+"px",left:Te+"px"});this.isPreventScroll&&(Z=this.getProcessedPositionValue({top:this.position.top-this.parentClientRect.top-2+"px",left:this.position.left-this.parentClientRect.left-2+"px"})),be(h,this.getDragPosition(Z)),!this.elementInViewport(h)&&this.enableAutoScroll&&!this.helperElement.classList.contains("e-treeview")&&this.helperElement.scrollIntoView();var z=document.querySelectorAll(":hover");if(this.enableAutoScroll&&this.helperElement.classList.contains("e-treeview")){0===z.length&&(z=this.getPathElements(t));var F=this.getScrollParent(z,!1);this.elementInViewport(this.helperElement)?this.getScrollPosition(F,le):this.elementInViewport(this.helperElement)||(0===(z=[].slice.call(document.querySelectorAll(":hover"))).length&&(z=this.getPathElements(t)),F=this.getScrollParent(z,!0),this.getScrollPosition(F,le))}this.dragProcessStarted=!0,this.prevLeft=n,this.prevTop=r,this.position.left=n,this.position.top=r,this.pageX=v,this.pageY=b}},i.prototype.getScrollParent=function(t,n){for(var o,r=n?t.reverse():t,a=r.length-1;a>=0;a--)if(("auto"===(o=window.getComputedStyle(r[parseInt(a.toString(),10)])["overflow-y"])||"scroll"===o)&&r[parseInt(a.toString(),10)].scrollHeight>r[parseInt(a.toString(),10)].clientHeight)return r[parseInt(a.toString(),10)];if("visible"===(o=window.getComputedStyle(document.scrollingElement)["overflow-y"]))return document.scrollingElement.style.overflow="auto",document.scrollingElement},i.prototype.getScrollPosition=function(t,n){if(t&&t===document.scrollingElement)t.clientHeight+document.scrollingElement.scrollTop-this.helperElement.clientHeightn?t.scrollTop+=this.helperElement.clientHeight:t.scrollTop>n-this.helperElement.clientHeight&&(t.scrollTop-=this.helperElement.clientHeight);else if(t&&t!==document.scrollingElement){var r=document.scrollingElement.scrollTop,o=this.helperElement.clientHeight;t.clientHeight+t.getBoundingClientRect().top-o+rn-o-r&&(t.scrollTop-=this.helperElement.clientHeight)}},i.prototype.getPathElements=function(t){return document.elementsFromPoint(t.clientX>0?t.clientX:0,t.clientY>0?t.clientY:0)},i.prototype.triggerOutFunction=function(t,n){this.hoverObject.instance.intOut(t,n.target),this.hoverObject.instance.dragData[this.scope]=null,this.hoverObject=null},i.prototype.getDragPosition=function(t){var n=he({},t);return this.axis&&("x"===this.axis?delete n.top:"y"===this.axis&&delete n.left),n},i.prototype.getDocumentWidthHeight=function(t){var n=document.body,r=document.documentElement;return Math.max(n["scroll"+t],r["scroll"+t],n["offset"+t],r["offset"+t],r["client"+t])},i.prototype.intDragStop=function(t){if(this.dragProcessStarted=!1,ke(t.changedTouches)||1===t.changedTouches.length){if(-1!==["touchend","pointerup","mouseup"].indexOf(t.type)){if(this.dragStop){var r=this.getProperTargetElement(t);this.trigger("dragStop",{event:t,element:this.element,target:r,helper:this.helperElement})}this.intDestroy(t)}else this.element.setAttribute("aria-grabbed","false");var o=this.checkTargetElement(t);o.target&&o.instance&&(o.instance.dragStopCalled=!0,o.instance.dragData[this.scope]=this.droppables[this.scope],o.instance.intDrop(t,o.target)),this.setGlobalDroppables(!0),document.body.classList.remove("e-prevent-select")}},i.prototype.intDestroy=function(t){this.dragProcessStarted=!1,this.toggleEvents(),document.body.classList.remove("e-prevent-select"),this.element.setAttribute("aria-grabbed","false"),y.remove(document,_.isSafari()?"touchmove":_.touchMoveEvent,this.intDragStart),y.remove(document,_.isSafari()?"touchend":_.touchEndEvent,this.intDragStop),y.remove(document,_.isSafari()?"touchend":_.touchEndEvent,this.intDestroy),y.remove(document,_.isSafari()?"touchmove":_.touchMoveEvent,this.intDrag),this.isDragStarted()&&this.isDragStarted(!0)},i.prototype.onPropertyChanged=function(t,n){},i.prototype.getModuleName=function(){return"draggable"},i.prototype.isDragStarted=function(t){return t&&(BC.isDragged=!BC.isDragged),BC.isDragged},i.prototype.setDragArea=function(){var t,n,a,r=0,o=0;if(a="string"==typeof this.dragArea?S(this.dragArea):this.dragArea){var c=a.getBoundingClientRect();t=a.scrollWidth?a.scrollWidth:c.right-c.left,n=a.scrollHeight?this.dragArea&&!d(this.helperElement)&&this.helperElement.classList.contains("e-treeview")?a.clientHeight:a.scrollHeight:c.bottom-c.top;for(var u=["Top","Left","Bottom","Right"],h=getComputedStyle(a),p=0;p12;return Mm(t.target,this.helperElement)||-1!==t.type.indexOf("touch")||a?(this.helperElement.style.pointerEvents="none",r=document.elementFromPoint(n.clientX,n.clientY),this.helperElement.style.pointerEvents=o):r=t.target,r},i.prototype.currentStateCheck=function(t,n){return d(this.currentStateTarget)||this.currentStateTarget===t?d(n)?t:n:this.currentStateTarget},i.prototype.getMousePosition=function(t,n){var a,l,r=void 0!==t.srcElement?t.srcElement:t.target,o=this.getCoordinates(t),c=d(r.offsetParent);if(n?(a=this.clone?o.pageX:o.pageX+(c?0:r.offsetParent.scrollLeft)-this.relativeXPosition,l=this.clone?o.pageY:o.pageY+(c?0:r.offsetParent.scrollTop)-this.relativeYPosition):(a=this.clone?o.pageX:o.pageX+window.pageXOffset-this.relativeXPosition,l=this.clone?o.pageY:o.pageY+window.pageYOffset-this.relativeYPosition),document.scrollingElement&&!n&&!this.clone){var u=document.scrollingElement;a=u.scrollWidth>0&&u.scrollWidth>u.clientWidth&&u.scrollLeft>0?a-u.scrollLeft:a,l=u.scrollHeight>0&&u.scrollHeight>u.clientHeight&&u.scrollTop>0?l-u.scrollTop:l}return{left:a-(this.margin.left+this.cursorAt.left),top:l-(this.margin.top+this.cursorAt.top)}},i.prototype.getCoordinates=function(t){return t.type.indexOf("touch")>-1?t.changedTouches[0]:t},i.prototype.getHelperElement=function(t){var n;return this.clone?this.helper?n=this.helper({sender:t,element:this.target}):(n=_t("div",{className:"e-drag-helper e-block-touch",innerHTML:"Draggable"}),document.body.appendChild(n)):n=this.element,n},i.prototype.setGlobalDroppables=function(t,n,r){this.droppables[this.scope]=t?null:{draggable:n,helper:r,draggedElement:this.element}},i.prototype.checkTargetElement=function(t){var n=this.getProperTargetElement(t),r=this.getDropInstance(n);if(!r&&n&&!d(n.parentNode)){var o=j(n.parentNode,".e-droppable")||n.parentElement;o&&(r=this.getDropInstance(o))}return{target:n,instance:r}},i.prototype.getDropInstance=function(t){var r,o=t&&t.ej2_instances;if(o)for(var a=0,l=o;a=0;a--)(o=s[a])&&(r=(n<3?o(r):n>3?o(i,e,r):o(i,e))||r);return n>3&&r&&Object.defineProperty(i,e,r),r},_9={backspace:8,tab:9,enter:13,shift:16,control:17,alt:18,pause:19,capslock:20,space:32,escape:27,pageup:33,pagedown:34,end:35,home:36,leftarrow:37,uparrow:38,rightarrow:39,downarrow:40,insert:45,delete:46,f1:112,f2:113,f3:114,f4:115,f5:116,f6:117,f7:118,f8:119,f9:120,f10:121,f11:122,f12:123,semicolon:186,plus:187,comma:188,minus:189,dot:190,forwardslash:191,graveaccent:192,openbracket:219,backslash:220,closebracket:221,singlequote:222},ps=function(s){function i(t,n){var r=s.call(this,n,t)||this;return r.keyPressHandler=function(o){for(var a=o.altKey,l=o.ctrlKey,c=o.shiftKey,u=o.which,p=0,f=Object.keys(r.keyConfigs);p1&&Number(n[n.length-1])?Number(n[n.length-1]):e.getKeyCode(n[n.length-1]),e.configCache[""+t]=r,r},i.getKeyCode=function(t){return _9[""+t]||t.toUpperCase().charCodeAt(0)},i.configCache={},Nm([m({})],i.prototype,"keyConfigs",void 0),Nm([m("keyup")],i.prototype,"eventName",void 0),Nm([w()],i.prototype,"keyAction",void 0),e=Nm([ct],i)}(sa),Br=function(){function s(i,e,t){this.controlName=i,this.localeStrings=e,this.setLocale(t||"en-US")}return s.prototype.setLocale=function(i){var e=this.intGetControlConstant(s.locale,i);this.currentLocale=e||this.localeStrings},s.load=function(i){this.locale=he(this.locale,i,{},!0)},s.prototype.getConstant=function(i){return d(this.currentLocale[""+i])?this.localeStrings[""+i]||"":this.currentLocale[""+i]},s.prototype.intGetControlConstant=function(i,e){return i[""+e]?i[""+e][this.controlName]:null},s.locale={},s}(),Ak=function(){var s=function(i,e){return(s=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,n){t.__proto__=n}||function(t,n){for(var r in n)n.hasOwnProperty(r)&&(t[r]=n[r])})(i,e)};return function(i,e){function t(){this.constructor=i}s(i,e),i.prototype=null===e?Object.create(e):(t.prototype=e.prototype,new t)}}(),oa=function(s,i,e,t){var o,n=arguments.length,r=n<3?i:null===t?t=Object.getOwnPropertyDescriptor(i,e):t;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)r=Reflect.decorate(s,i,e,t);else for(var a=s.length-1;a>=0;a--)(o=s[a])&&(r=(n<3?o(r):n>3?o(i,e,r):o(i,e))||r);return n>3&&r&&Object.defineProperty(i,e,r),r},F9=function(s){function i(){return null!==s&&s.apply(this,arguments)||this}return Ak(i,s),oa([m(50)],i.prototype,"swipeThresholdDistance",void 0),i}(Lt),H9=/(Up|Down)/,fs=function(s){function i(e,t){var n=s.call(this,t,e)||this;return n.touchAction=!0,n.tapCount=0,n.startEvent=function(r){if(!0===n.touchAction){var o=n.updateChangeTouches(r);void 0!==r.changedTouches&&(n.touchAction=!1),n.isTouchMoved=!1,n.movedDirection="",n.startPoint=n.lastMovedPoint={clientX:o.clientX,clientY:o.clientY},n.startEventData=o,n.hScrollLocked=n.vScrollLocked=!1,n.tStampStart=Date.now(),n.timeOutTapHold=setTimeout(function(){n.tapHoldEvent(r)},n.tapHoldThreshold),y.add(n.element,_.touchMoveEvent,n.moveEvent,n),y.add(n.element,_.touchEndEvent,n.endEvent,n),y.add(n.element,_.touchCancelEvent,n.cancelEvent,n)}},n.moveEvent=function(r){var o=n.updateChangeTouches(r);n.movedPoint=o,n.isTouchMoved=!(o.clientX===n.startPoint.clientX&&o.clientY===n.startPoint.clientY);var a={};n.isTouchMoved&&(clearTimeout(n.timeOutTapHold),n.calcScrollPoints(r),a=he(a,{},{startEvents:n.startEventData,originalEvent:r,startX:n.startPoint.clientX,startY:n.startPoint.clientY,distanceX:n.distanceX,distanceY:n.distanceY,scrollDirection:n.scrollDirection,velocity:n.getVelocity(o)}),n.trigger("scroll",a),n.lastMovedPoint={clientX:o.clientX,clientY:o.clientY})},n.cancelEvent=function(r){clearTimeout(n.timeOutTapHold),clearTimeout(n.timeOutTap),n.tapCount=0,n.swipeFn(r),y.remove(n.element,_.touchCancelEvent,n.cancelEvent)},n.endEvent=function(r){n.swipeFn(r),n.isTouchMoved||"function"==typeof n.tap&&(n.trigger("tap",{originalEvent:r,tapCount:++n.tapCount}),n.timeOutTap=setTimeout(function(){n.tapCount=0},n.tapThreshold)),n.modeclear()},n.swipeFn=function(r){clearTimeout(n.timeOutTapHold),clearTimeout(n.timeOutTap);var o=n.updateChangeTouches(r),a=o.clientX-n.startPoint.clientX,l=o.clientY-n.startPoint.clientY;a=Math.floor(a<0?-1*a:a),l=Math.floor(l<0?-1*l:a),n.isTouchMoved=a>1||l>1,/Firefox/.test(_.userAgent)&&0===o.clientX&&0===o.clientY&&"mouseup"===r.type&&(n.isTouchMoved=!1),n.endPoint=o,n.calcPoints(r);var u={originalEvent:r,startEvents:n.startEventData,startX:n.startPoint.clientX,startY:n.startPoint.clientY,distanceX:n.distanceX,distanceY:n.distanceY,swipeDirection:n.movedDirection,velocity:n.getVelocity(o)};if(n.isTouchMoved){var h=n.swipeSettings.swipeThresholdDistance,p=he(void 0,n.defaultArgs,u),f=!1,g=n.element,v=n.isScrollable(g),b=H9.test(n.movedDirection);(hthis.distanceY?t.clientX>this.startPoint.clientX?"Right":"Left":t.clientYthis.distanceY||!0===this.hScrollLocked)&&!1===this.vScrollLocked?(this.scrollDirection=t.clientX>this.lastMovedPoint.clientX?"Right":"Left",this.hScrollLocked=!0):(this.scrollDirection=t.clientY=e[n[0]+r[0]]},i.prototype.updateChangeTouches=function(e){return e.changedTouches&&0!==e.changedTouches.length?e.changedTouches[0]:e},oa([w()],i.prototype,"tap",void 0),oa([w()],i.prototype,"tapHold",void 0),oa([w()],i.prototype,"swipe",void 0),oa([w()],i.prototype,"scroll",void 0),oa([m(350)],i.prototype,"tapThreshold",void 0),oa([m(750)],i.prototype,"tapHoldThreshold",void 0),oa([di({},F9)],i.prototype,"swipeSettings",void 0),oa([ct],i)}(sa),B9=new RegExp("\\n|\\r|\\s\\s+","g"),V9=new RegExp(/'|"/g),U9=new RegExp("if ?\\("),W9=new RegExp("else if ?\\("),Lk=new RegExp("else"),Y9=new RegExp("for ?\\("),Ok=new RegExp("(/if|/for)"),Q9=new RegExp("\\((.*)\\)",""),VC=new RegExp("^[0-9]+$","g"),q9=new RegExp("[\\w\"'.\\s+]+","g"),$9=new RegExp('"(.*?)"',"g"),G9=new RegExp("[\\w\"'@#$.\\s-+]+","g"),xk=new RegExp("\\${([^}]*)}","g"),Z9=/^\..*/gm,UC=/\\/gi,X9=/\\\\/gi,K9=new RegExp("[\\w\"'@#$.\\s+]+","g"),J9=/\window\./gm;function Ou(s,i,e,t,n){return!i||VC.test(s)||-1!==t.indexOf(s.split(".")[0])||n||"true"===s||"false"===s?s:e+"."+s}function WC(s,i,e,t){return i&&!VC.test(s)&&-1===t.indexOf(s.split(".")[0])?e+'["'+s:s}function kk(s){return s.match(X9)?s:s.replace(UC,"\\\\")}function jk(s,i,e,t){if(s=s.trim(),/\window\./gm.test(s))return s;var r=/'|"/gm;return/@|\$|#/gm.test(s)&&(s=WC(s,-1===e.indexOf(s),i,e)+'"]'),Z9.test(s)?function iq(s,i,e,t){return!i||VC.test(s)||-1!==t.indexOf(s.split(".")[0])||/^\..*/gm.test(s)?s:e+"."+s}(s,!r.test(s)&&-1===e.indexOf(s),i,e):Ou(s,!r.test(s)&&-1===e.indexOf(s),i,e,t)}var nq=/^[\n\r.]+0&&i.forEach(function(e){$(e)})},s.removeJsEvents=function(){var i=this.wrapElement.querySelectorAll("["+Pk.join("],[")+"]");i.length>0&&i.forEach(function(e){Pk.forEach(function(t){e.hasAttribute(t)&&e.removeAttribute(t)})})},s.removeXssAttrs=function(){var i=this;this.removeAttrs.forEach(function(e,t){var n=i.wrapElement.querySelectorAll(e.selector);n.length>0&&n.forEach("a[href]"===e.selector?function(r){-1!==r.getAttribute(e.attribute).replace(/\t|\s|&/,"").indexOf("javascript:alert")&&r.removeAttribute(e.attribute)}:function(r){r.removeAttribute(e.attribute)})})},s}();function hq(s){return function(i){!function uq(s,i){i.forEach(function(e){Object.getOwnPropertyNames(e.prototype).forEach(function(t){(!Object.prototype.hasOwnProperty.call(s.prototype,t)||e.isFormBase&&"constructor"!==t)&&(s.prototype["".concat(t)]=e.prototype["".concat(t)])})})}(i,s)}}function zk(s,i,e){var t={};if(s&&s.length){for(var n=0,r=s;n"u"||(M.innerHTML=b.innerHTML?b.innerHTML:"",void 0!==b.className&&(M.className=b.className),void 0!==b.id&&(M.id=b.id),void 0!==b.styles&&M.setAttribute("style",b.styles),void 0!==e.ngAttr&&M.setAttribute(e.ngAttr,""),void 0!==b.attrs&&ge(M,b.attrs)),M};for(var t=0,n=e.tags;t"u"&&(u["".concat(o)]=[]),u["".concat(o)].push(c),c.rootNodes}}});var ht=function(){function s(i){return this.subQuery=null,this.isChild=!1,this.distincts=[],this.queries=[],this.key="",this.fKey="","string"==typeof i?this.fromTable=i:i&&i instanceof Array&&(this.lookups=i),this.expands=[],this.sortedColumns=[],this.groupedColumns=[],this.subQuery=null,this.isChild=!1,this.params=[],this.lazyLoad=[],this}return Object.defineProperty(s.prototype,"moduleName",{get:function(){return"query"},enumerable:!0,configurable:!0}),s.prototype.setKey=function(i){return this.key=i,this},s.prototype.using=function(i){return this.dataManager=i,this},s.prototype.execute=function(i,e,t,n){return(i=i||this.dataManager)?i.executeQuery(this,e,t,n):Y.throwError('Query - execute() : dataManager needs to be is set using "using" function or should be passed as argument')},s.prototype.executeLocal=function(i){return(i=i||this.dataManager)?i.executeLocal(this):Y.throwError('Query - executeLocal() : dataManager needs to be is set using "using" function or should be passed as argument')},s.prototype.clone=function(){var i=new s;return i.queries=this.queries.slice(0),i.key=this.key,i.isChild=this.isChild,i.dataManager=this.dataManager,i.fromTable=this.fromTable,i.params=this.params.slice(0),i.expands=this.expands.slice(0),i.sortedColumns=this.sortedColumns.slice(0),i.groupedColumns=this.groupedColumns.slice(0),i.subQuerySelector=this.subQuerySelector,i.subQuery=this.subQuery,i.fKey=this.fKey,i.isCountRequired=this.isCountRequired,i.distincts=this.distincts.slice(0),i.lazyLoad=this.lazyLoad.slice(0),i},s.prototype.from=function(i){return this.fromTable=i,this},s.prototype.addParams=function(i,e){return this.params.push("function"==typeof e?{key:i,fn:e}:{key:i,value:e}),this},s.prototype.distinct=function(i){return this.distincts="string"==typeof i?[].slice.call([i],0):i.slice(0),this},s.prototype.expand=function(i){return this.expands="string"==typeof i?[].slice.call([i],0):i.slice(0),this},s.prototype.where=function(i,e,t,n,r,o){e=e?e.toLowerCase():null;var a=null;return"string"==typeof i?a=new Gn(i,e,t,n,r,o):i instanceof Gn&&(a=i),this.queries.push({fn:"onWhere",e:a}),this},s.prototype.search=function(i,e,t,n,r){return"string"==typeof e&&(e=[e]),(!t||"none"===t)&&(t="contains"),this.queries.push({fn:"onSearch",e:{fieldNames:e,operator:t,searchKey:i,ignoreCase:n,ignoreAccent:r,comparer:Y.fnOperators[t]}}),this},s.prototype.sortBy=function(i,e,t){return this.sortByForeignKey(i,e,t)},s.prototype.sortByForeignKey=function(i,e,t,n){var o,a,r=d(n)?"ascending":n;if("string"==typeof i&&Y.endsWith(i.toLowerCase()," desc")&&(i=i.replace(/ desc$/i,""),e="descending"),(!e||"string"==typeof e)&&(r=e?e.toLowerCase():"ascending",e=Y.fnSort(e)),t){o=s.filterQueries(this.queries,"onSortBy");for(var l=0;l0&&this.condition&&-1!==this.condition.indexOf("not")&&(e[r].condition=e[r].condition?e[r].condition+"not":"not"),t=e[r].validate(i),n){if(!t)return!1}else if(t)return!0;return n},s.prototype.toJson=function(){var i,e;if(this.isComplex){i=[],e=this.predicates;for(var t=0;te.length-3?(e=e.substring(0,e.length-1),s.endsWith(s.toLowerCase(i),s.toLowerCase(e))):(e.lastIndexOf("%")!==e.indexOf("%")&&e.lastIndexOf("%")>e.indexOf("%")+1&&(e=e.substring(e.indexOf("%")+1,e.lastIndexOf("%"))),-1!==i.indexOf(e)))},s.fnSort=function(i){return"ascending"===(i=i?s.toLowerCase(i):"ascending")?this.fnAscending:this.fnDescending},s.fnAscending=function(i,e){return d(i)&&d(e)||null==e?-1:"string"==typeof i?i.localeCompare(e):null==i?1:i-e},s.fnDescending=function(i,e){return d(i)&&d(e)?-1:null==e?1:"string"==typeof i?-1*i.localeCompare(e):null==i?-1:e-i},s.extractFields=function(i,e){for(var t={},n=0;n0||e.length>0;)o=i.length>0&&e.length>0?n?n(this.getVal(i,0,t),this.getVal(e,0,t),i[0],e[0])<=0?i:e:i[0][t]0?i:e,r.push(o.shift());return r},s.getVal=function(i,e,t){return t?this.getObject(t,i[e]):i[e]},s.toLowerCase=function(i){return i?"string"==typeof i?i.toLowerCase():i.toString():0===i||!1===i?i.toString():""},s.callAdaptorFunction=function(i,e,t,n){if(e in i){var r=i[e](t,n);d(r)||(t=r)}return t},s.getAddParams=function(i,e,t){var n={};return s.callAdaptorFunction(i,"addParams",{dm:e,query:t,params:t?t.params:[],reqParams:n}),n},s.isPlainObject=function(i){return!!i&&i.constructor===Object},s.isCors=function(){var i=null;try{i=new window.XMLHttpRequest}catch{}return!!i&&"withCredentials"in i},s.getGuid=function(i){var t;return(i||"")+"00000000-0000-4000-0000-000000000000".replace(/0/g,function(n,r){if("crypto"in window&&"getRandomValues"in crypto){var o=new Uint8Array(1);window.crypto.getRandomValues(o),t=o[0]%16|0}else t=16*Math.random()|0;return"0123456789abcdef"[19===r?3&t|8:t]})},s.isNull=function(i){return null==i},s.getItemFromComparer=function(i,e,t){var n,r,o,a=0,l="string"==typeof s.getVal(i,0,e);if(i.length)for(;d(n)&&a0&&(n=r,o=i[a]));return o},s.distinct=function(i,e,t){t=!d(t)&&t;var r,n=[],o={};return i.forEach(function(a,l){(r="object"==typeof i[l]?s.getVal(i,l,e):i[l])in o||(n.push(t?i[l]:r),o[r]=1)}),n},s.processData=function(i,e){var t=this.prepareQuery(i),n=new Oe(e);i.requiresCounts&&t.requiresCount();var r=n.executeLocal(t),o={result:i.requiresCounts?r.result:r,count:r.count,aggregates:JSON.stringify(r.aggregates)};return i.requiresCounts?o:r},s.prepareQuery=function(i){var e=this,t=new ht;return i.select&&t.select(i.select),i.where&&s.parse.parseJson(i.where).filter(function(o){if(d(o.condition))t.where(o.field,o.operator,o.value,o.ignoreCase,o.ignoreAccent);else{var a=[];o.field?a.push(new Gn(o.field,o.operator,o.value,o.ignoreCase,o.ignoreAccent)):a=a.concat(e.getPredicate(o.predicates)),"or"===o.condition?t.where(Gn.or(a)):"and"===o.condition&&t.where(Gn.and(a))}}),i.search&&s.parse.parseJson(i.search).filter(function(o){return t.search(o.key,o.fields,o.operator,o.ignoreCase,o.ignoreAccent)}),i.aggregates&&i.aggregates.filter(function(o){return t.aggregate(o.type,o.field)}),i.sorted&&i.sorted.filter(function(o){return t.sortBy(o.name,o.direction)}),i.skip&&t.skip(i.skip),i.take&&t.take(i.take),i.group&&i.group.filter(function(o){return t.group(o)}),t},s.getPredicate=function(i){for(var e=[],t=0;t":"greaterthan","<=":"lessthanorequal",">=":"greaterthanorequal","==":"equal","!=":"notequal","*=":"contains","$=":"endswith","^=":"startswith"},s.odBiOperator={"<":" lt ",">":" gt ","<=":" le ",">=":" ge ","==":" eq ","!=":" ne ",lessthan:" lt ",lessthanorequal:" le ",greaterthan:" gt ",greaterthanorequal:" ge ",equal:" eq ",notequal:" ne "},s.odUniOperator={"$=":"endswith","^=":"startswith","*=":"substringof",endswith:"endswith",startswith:"startswith",contains:"substringof",doesnotendwith:"not endswith",doesnotstartwith:"not startswith",doesnotcontain:"not substringof",wildcard:"wildcard",like:"like"},s.odv4UniOperator={"$=":"endswith","^=":"startswith","*=":"contains",endswith:"endswith",startswith:"startswith",contains:"contains",doesnotendwith:"not endswith",doesnotstartwith:"not startswith",doesnotcontain:"not contains",wildcard:"wildcard",like:"like"},s.diacritics={"\u24b6":"A",\uff21:"A",\u00c0:"A",\u00c1:"A",\u00c2:"A",\u1ea6:"A",\u1ea4:"A",\u1eaa:"A",\u1ea8:"A",\u00c3:"A",\u0100:"A",\u0102:"A",\u1eb0:"A",\u1eae:"A",\u1eb4:"A",\u1eb2:"A",\u0226:"A",\u01e0:"A",\u00c4:"A",\u01de:"A",\u1ea2:"A",\u00c5:"A",\u01fa:"A",\u01cd:"A",\u0200:"A",\u0202:"A",\u1ea0:"A",\u1eac:"A",\u1eb6:"A",\u1e00:"A",\u0104:"A",\u023a:"A",\u2c6f:"A",\ua732:"AA",\u00c6:"AE",\u01fc:"AE",\u01e2:"AE",\ua734:"AO",\ua736:"AU",\ua738:"AV",\ua73a:"AV",\ua73c:"AY","\u24b7":"B",\uff22:"B",\u1e02:"B",\u1e04:"B",\u1e06:"B",\u0243:"B",\u0182:"B",\u0181:"B","\u24b8":"C",\uff23:"C",\u0106:"C",\u0108:"C",\u010a:"C",\u010c:"C",\u00c7:"C",\u1e08:"C",\u0187:"C",\u023b:"C",\ua73e:"C","\u24b9":"D",\uff24:"D",\u1e0a:"D",\u010e:"D",\u1e0c:"D",\u1e10:"D",\u1e12:"D",\u1e0e:"D",\u0110:"D",\u018b:"D",\u018a:"D",\u0189:"D",\ua779:"D",\u01f1:"DZ",\u01c4:"DZ",\u01f2:"Dz",\u01c5:"Dz","\u24ba":"E",\uff25:"E",\u00c8:"E",\u00c9:"E",\u00ca:"E",\u1ec0:"E",\u1ebe:"E",\u1ec4:"E",\u1ec2:"E",\u1ebc:"E",\u0112:"E",\u1e14:"E",\u1e16:"E",\u0114:"E",\u0116:"E",\u00cb:"E",\u1eba:"E",\u011a:"E",\u0204:"E",\u0206:"E",\u1eb8:"E",\u1ec6:"E",\u0228:"E",\u1e1c:"E",\u0118:"E",\u1e18:"E",\u1e1a:"E",\u0190:"E",\u018e:"E","\u24bb":"F",\uff26:"F",\u1e1e:"F",\u0191:"F",\ua77b:"F","\u24bc":"G",\uff27:"G",\u01f4:"G",\u011c:"G",\u1e20:"G",\u011e:"G",\u0120:"G",\u01e6:"G",\u0122:"G",\u01e4:"G",\u0193:"G",\ua7a0:"G",\ua77d:"G",\ua77e:"G","\u24bd":"H",\uff28:"H",\u0124:"H",\u1e22:"H",\u1e26:"H",\u021e:"H",\u1e24:"H",\u1e28:"H",\u1e2a:"H",\u0126:"H",\u2c67:"H",\u2c75:"H",\ua78d:"H","\u24be":"I",\uff29:"I",\u00cc:"I",\u00cd:"I",\u00ce:"I",\u0128:"I",\u012a:"I",\u012c:"I",\u0130:"I",\u00cf:"I",\u1e2e:"I",\u1ec8:"I",\u01cf:"I",\u0208:"I",\u020a:"I",\u1eca:"I",\u012e:"I",\u1e2c:"I",\u0197:"I","\u24bf":"J",\uff2a:"J",\u0134:"J",\u0248:"J","\u24c0":"K",\uff2b:"K",\u1e30:"K",\u01e8:"K",\u1e32:"K",\u0136:"K",\u1e34:"K",\u0198:"K",\u2c69:"K",\ua740:"K",\ua742:"K",\ua744:"K",\ua7a2:"K","\u24c1":"L",\uff2c:"L",\u013f:"L",\u0139:"L",\u013d:"L",\u1e36:"L",\u1e38:"L",\u013b:"L",\u1e3c:"L",\u1e3a:"L",\u0141:"L",\u023d:"L",\u2c62:"L",\u2c60:"L",\ua748:"L",\ua746:"L",\ua780:"L",\u01c7:"LJ",\u01c8:"Lj","\u24c2":"M",\uff2d:"M",\u1e3e:"M",\u1e40:"M",\u1e42:"M",\u2c6e:"M",\u019c:"M","\u24c3":"N",\uff2e:"N",\u01f8:"N",\u0143:"N",\u00d1:"N",\u1e44:"N",\u0147:"N",\u1e46:"N",\u0145:"N",\u1e4a:"N",\u1e48:"N",\u0220:"N",\u019d:"N",\ua790:"N",\ua7a4:"N",\u01ca:"NJ",\u01cb:"Nj","\u24c4":"O",\uff2f:"O",\u00d2:"O",\u00d3:"O",\u00d4:"O",\u1ed2:"O",\u1ed0:"O",\u1ed6:"O",\u1ed4:"O",\u00d5:"O",\u1e4c:"O",\u022c:"O",\u1e4e:"O",\u014c:"O",\u1e50:"O",\u1e52:"O",\u014e:"O",\u022e:"O",\u0230:"O",\u00d6:"O",\u022a:"O",\u1ece:"O",\u0150:"O",\u01d1:"O",\u020c:"O",\u020e:"O",\u01a0:"O",\u1edc:"O",\u1eda:"O",\u1ee0:"O",\u1ede:"O",\u1ee2:"O",\u1ecc:"O",\u1ed8:"O",\u01ea:"O",\u01ec:"O",\u00d8:"O",\u01fe:"O",\u0186:"O",\u019f:"O",\ua74a:"O",\ua74c:"O",\u01a2:"OI",\ua74e:"OO",\u0222:"OU","\u24c5":"P",\uff30:"P",\u1e54:"P",\u1e56:"P",\u01a4:"P",\u2c63:"P",\ua750:"P",\ua752:"P",\ua754:"P","\u24c6":"Q",\uff31:"Q",\ua756:"Q",\ua758:"Q",\u024a:"Q","\u24c7":"R",\uff32:"R",\u0154:"R",\u1e58:"R",\u0158:"R",\u0210:"R",\u0212:"R",\u1e5a:"R",\u1e5c:"R",\u0156:"R",\u1e5e:"R",\u024c:"R",\u2c64:"R",\ua75a:"R",\ua7a6:"R",\ua782:"R","\u24c8":"S",\uff33:"S",\u1e9e:"S",\u015a:"S",\u1e64:"S",\u015c:"S",\u1e60:"S",\u0160:"S",\u1e66:"S",\u1e62:"S",\u1e68:"S",\u0218:"S",\u015e:"S",\u2c7e:"S",\ua7a8:"S",\ua784:"S","\u24c9":"T",\uff34:"T",\u1e6a:"T",\u0164:"T",\u1e6c:"T",\u021a:"T",\u0162:"T",\u1e70:"T",\u1e6e:"T",\u0166:"T",\u01ac:"T",\u01ae:"T",\u023e:"T",\ua786:"T",\ua728:"TZ","\u24ca":"U",\uff35:"U",\u00d9:"U",\u00da:"U",\u00db:"U",\u0168:"U",\u1e78:"U",\u016a:"U",\u1e7a:"U",\u016c:"U",\u00dc:"U",\u01db:"U",\u01d7:"U",\u01d5:"U",\u01d9:"U",\u1ee6:"U",\u016e:"U",\u0170:"U",\u01d3:"U",\u0214:"U",\u0216:"U",\u01af:"U",\u1eea:"U",\u1ee8:"U",\u1eee:"U",\u1eec:"U",\u1ef0:"U",\u1ee4:"U",\u1e72:"U",\u0172:"U",\u1e76:"U",\u1e74:"U",\u0244:"U","\u24cb":"V",\uff36:"V",\u1e7c:"V",\u1e7e:"V",\u01b2:"V",\ua75e:"V",\u0245:"V",\ua760:"VY","\u24cc":"W",\uff37:"W",\u1e80:"W",\u1e82:"W",\u0174:"W",\u1e86:"W",\u1e84:"W",\u1e88:"W",\u2c72:"W","\u24cd":"X",\uff38:"X",\u1e8a:"X",\u1e8c:"X","\u24ce":"Y",\uff39:"Y",\u1ef2:"Y",\u00dd:"Y",\u0176:"Y",\u1ef8:"Y",\u0232:"Y",\u1e8e:"Y",\u0178:"Y",\u1ef6:"Y",\u1ef4:"Y",\u01b3:"Y",\u024e:"Y",\u1efe:"Y","\u24cf":"Z",\uff3a:"Z",\u0179:"Z",\u1e90:"Z",\u017b:"Z",\u017d:"Z",\u1e92:"Z",\u1e94:"Z",\u01b5:"Z",\u0224:"Z",\u2c7f:"Z",\u2c6b:"Z",\ua762:"Z","\u24d0":"a",\uff41:"a",\u1e9a:"a",\u00e0:"a",\u00e1:"a",\u00e2:"a",\u1ea7:"a",\u1ea5:"a",\u1eab:"a",\u1ea9:"a",\u00e3:"a",\u0101:"a",\u0103:"a",\u1eb1:"a",\u1eaf:"a",\u1eb5:"a",\u1eb3:"a",\u0227:"a",\u01e1:"a",\u00e4:"a",\u01df:"a",\u1ea3:"a",\u00e5:"a",\u01fb:"a",\u01ce:"a",\u0201:"a",\u0203:"a",\u1ea1:"a",\u1ead:"a",\u1eb7:"a",\u1e01:"a",\u0105:"a",\u2c65:"a",\u0250:"a",\ua733:"aa",\u00e6:"ae",\u01fd:"ae",\u01e3:"ae",\ua735:"ao",\ua737:"au",\ua739:"av",\ua73b:"av",\ua73d:"ay","\u24d1":"b",\uff42:"b",\u1e03:"b",\u1e05:"b",\u1e07:"b",\u0180:"b",\u0183:"b",\u0253:"b","\u24d2":"c",\uff43:"c",\u0107:"c",\u0109:"c",\u010b:"c",\u010d:"c",\u00e7:"c",\u1e09:"c",\u0188:"c",\u023c:"c",\ua73f:"c",\u2184:"c","\u24d3":"d",\uff44:"d",\u1e0b:"d",\u010f:"d",\u1e0d:"d",\u1e11:"d",\u1e13:"d",\u1e0f:"d",\u0111:"d",\u018c:"d",\u0256:"d",\u0257:"d",\ua77a:"d",\u01f3:"dz",\u01c6:"dz","\u24d4":"e",\uff45:"e",\u00e8:"e",\u00e9:"e",\u00ea:"e",\u1ec1:"e",\u1ebf:"e",\u1ec5:"e",\u1ec3:"e",\u1ebd:"e",\u0113:"e",\u1e15:"e",\u1e17:"e",\u0115:"e",\u0117:"e",\u00eb:"e",\u1ebb:"e",\u011b:"e",\u0205:"e",\u0207:"e",\u1eb9:"e",\u1ec7:"e",\u0229:"e",\u1e1d:"e",\u0119:"e",\u1e19:"e",\u1e1b:"e",\u0247:"e",\u025b:"e",\u01dd:"e","\u24d5":"f",\uff46:"f",\u1e1f:"f",\u0192:"f",\ua77c:"f","\u24d6":"g",\uff47:"g",\u01f5:"g",\u011d:"g",\u1e21:"g",\u011f:"g",\u0121:"g",\u01e7:"g",\u0123:"g",\u01e5:"g",\u0260:"g",\ua7a1:"g",\u1d79:"g",\ua77f:"g","\u24d7":"h",\uff48:"h",\u0125:"h",\u1e23:"h",\u1e27:"h",\u021f:"h",\u1e25:"h",\u1e29:"h",\u1e2b:"h",\u1e96:"h",\u0127:"h",\u2c68:"h",\u2c76:"h",\u0265:"h",\u0195:"hv","\u24d8":"i",\uff49:"i",\u00ec:"i",\u00ed:"i",\u00ee:"i",\u0129:"i",\u012b:"i",\u012d:"i",\u00ef:"i",\u1e2f:"i",\u1ec9:"i",\u01d0:"i",\u0209:"i",\u020b:"i",\u1ecb:"i",\u012f:"i",\u1e2d:"i",\u0268:"i",\u0131:"i","\u24d9":"j",\uff4a:"j",\u0135:"j",\u01f0:"j",\u0249:"j","\u24da":"k",\uff4b:"k",\u1e31:"k",\u01e9:"k",\u1e33:"k",\u0137:"k",\u1e35:"k",\u0199:"k",\u2c6a:"k",\ua741:"k",\ua743:"k",\ua745:"k",\ua7a3:"k","\u24db":"l",\uff4c:"l",\u0140:"l",\u013a:"l",\u013e:"l",\u1e37:"l",\u1e39:"l",\u013c:"l",\u1e3d:"l",\u1e3b:"l",\u017f:"l",\u0142:"l",\u019a:"l",\u026b:"l",\u2c61:"l",\ua749:"l",\ua781:"l",\ua747:"l",\u01c9:"lj","\u24dc":"m",\uff4d:"m",\u1e3f:"m",\u1e41:"m",\u1e43:"m",\u0271:"m",\u026f:"m","\u24dd":"n",\uff4e:"n",\u01f9:"n",\u0144:"n",\u00f1:"n",\u1e45:"n",\u0148:"n",\u1e47:"n",\u0146:"n",\u1e4b:"n",\u1e49:"n",\u019e:"n",\u0272:"n",\u0149:"n",\ua791:"n",\ua7a5:"n",\u01cc:"nj","\u24de":"o",\uff4f:"o",\u00f2:"o",\u00f3:"o",\u00f4:"o",\u1ed3:"o",\u1ed1:"o",\u1ed7:"o",\u1ed5:"o",\u00f5:"o",\u1e4d:"o",\u022d:"o",\u1e4f:"o",\u014d:"o",\u1e51:"o",\u1e53:"o",\u014f:"o",\u022f:"o",\u0231:"o",\u00f6:"o",\u022b:"o",\u1ecf:"o",\u0151:"o",\u01d2:"o",\u020d:"o",\u020f:"o",\u01a1:"o",\u1edd:"o",\u1edb:"o",\u1ee1:"o",\u1edf:"o",\u1ee3:"o",\u1ecd:"o",\u1ed9:"o",\u01eb:"o",\u01ed:"o",\u00f8:"o",\u01ff:"o",\u0254:"o",\ua74b:"o",\ua74d:"o",\u0275:"o",\u01a3:"oi",\u0223:"ou",\ua74f:"oo","\u24df":"p",\uff50:"p",\u1e55:"p",\u1e57:"p",\u01a5:"p",\u1d7d:"p",\ua751:"p",\ua753:"p",\ua755:"p","\u24e0":"q",\uff51:"q",\u024b:"q",\ua757:"q",\ua759:"q","\u24e1":"r",\uff52:"r",\u0155:"r",\u1e59:"r",\u0159:"r",\u0211:"r",\u0213:"r",\u1e5b:"r",\u1e5d:"r",\u0157:"r",\u1e5f:"r",\u024d:"r",\u027d:"r",\ua75b:"r",\ua7a7:"r",\ua783:"r","\u24e2":"s",\uff53:"s",\u00df:"s",\u015b:"s",\u1e65:"s",\u015d:"s",\u1e61:"s",\u0161:"s",\u1e67:"s",\u1e63:"s",\u1e69:"s",\u0219:"s",\u015f:"s",\u023f:"s",\ua7a9:"s",\ua785:"s",\u1e9b:"s","\u24e3":"t",\uff54:"t",\u1e6b:"t",\u1e97:"t",\u0165:"t",\u1e6d:"t",\u021b:"t",\u0163:"t",\u1e71:"t",\u1e6f:"t",\u0167:"t",\u01ad:"t",\u0288:"t",\u2c66:"t",\ua787:"t",\ua729:"tz","\u24e4":"u",\uff55:"u",\u00f9:"u",\u00fa:"u",\u00fb:"u",\u0169:"u",\u1e79:"u",\u016b:"u",\u1e7b:"u",\u016d:"u",\u00fc:"u",\u01dc:"u",\u01d8:"u",\u01d6:"u",\u01da:"u",\u1ee7:"u",\u016f:"u",\u0171:"u",\u01d4:"u",\u0215:"u",\u0217:"u",\u01b0:"u",\u1eeb:"u",\u1ee9:"u",\u1eef:"u",\u1eed:"u",\u1ef1:"u",\u1ee5:"u",\u1e73:"u",\u0173:"u",\u1e77:"u",\u1e75:"u",\u0289:"u","\u24e5":"v",\uff56:"v",\u1e7d:"v",\u1e7f:"v",\u028b:"v",\ua75f:"v",\u028c:"v",\ua761:"vy","\u24e6":"w",\uff57:"w",\u1e81:"w",\u1e83:"w",\u0175:"w",\u1e87:"w",\u1e85:"w",\u1e98:"w",\u1e89:"w",\u2c73:"w","\u24e7":"x",\uff58:"x",\u1e8b:"x",\u1e8d:"x","\u24e8":"y",\uff59:"y",\u1ef3:"y",\u00fd:"y",\u0177:"y",\u1ef9:"y",\u0233:"y",\u1e8f:"y",\u00ff:"y",\u1ef7:"y",\u1e99:"y",\u1ef5:"y",\u01b4:"y",\u024f:"y",\u1eff:"y","\u24e9":"z",\uff5a:"z",\u017a:"z",\u1e91:"z",\u017c:"z",\u017e:"z",\u1e93:"z",\u1e95:"z",\u01b6:"z",\u0225:"z",\u0240:"z",\u2c6c:"z",\ua763:"z",\u0386:"\u0391",\u0388:"\u0395",\u0389:"\u0397",\u038a:"\u0399",\u03aa:"\u0399",\u038c:"\u039f",\u038e:"\u03a5",\u03ab:"\u03a5",\u038f:"\u03a9",\u03ac:"\u03b1",\u03ad:"\u03b5",\u03ae:"\u03b7",\u03af:"\u03b9",\u03ca:"\u03b9",\u0390:"\u03b9",\u03cc:"\u03bf",\u03cd:"\u03c5",\u03cb:"\u03c5",\u03b0:"\u03c5",\u03c9:"\u03c9",\u03c2:"\u03c3"},s.fnOperators={equal:function(i,e,t,n){return n&&(i=s.ignoreDiacritics(i),e=s.ignoreDiacritics(e)),t?s.toLowerCase(i)===s.toLowerCase(e):i===e},notequal:function(i,e,t,n){return n&&(i=s.ignoreDiacritics(i),e=s.ignoreDiacritics(e)),!s.fnOperators.equal(i,e,t)},lessthan:function(i,e,t){return t?s.toLowerCase(i)s.toLowerCase(e):i>e},lessthanorequal:function(i,e,t){return t?s.toLowerCase(i)<=s.toLowerCase(e):(d(i)&&(i=void 0),i<=e)},greaterthanorequal:function(i,e,t){return t?s.toLowerCase(i)>=s.toLowerCase(e):i>=e},contains:function(i,e,t,n){return n&&(i=s.ignoreDiacritics(i),e=s.ignoreDiacritics(e)),t?!d(i)&&!d(e)&&-1!==s.toLowerCase(i).indexOf(s.toLowerCase(e)):!d(i)&&!d(e)&&-1!==i.toString().indexOf(e)},doesnotcontain:function(i,e,t,n){return n&&(i=s.ignoreDiacritics(i),e=s.ignoreDiacritics(e)),t?!d(i)&&!d(e)&&-1===s.toLowerCase(i).indexOf(s.toLowerCase(e)):!d(i)&&!d(e)&&-1===i.toString().indexOf(e)},isnotnull:function(i){return null!=i},isnull:function(i){return null==i},startswith:function(i,e,t,n){return n&&(i=s.ignoreDiacritics(i),e=s.ignoreDiacritics(e)),t?i&&e&&s.startsWith(s.toLowerCase(i),s.toLowerCase(e)):i&&e&&s.startsWith(i,e)},doesnotstartwith:function(i,e,t,n){return n&&(i=s.ignoreDiacritics(i),e=s.ignoreDiacritics(e)),t?i&&e&&s.notStartsWith(s.toLowerCase(i),s.toLowerCase(e)):i&&e&&s.notStartsWith(i,e)},like:function(i,e,t,n){return n&&(i=s.ignoreDiacritics(i),e=s.ignoreDiacritics(e)),t?i&&e&&s.like(s.toLowerCase(i),s.toLowerCase(e)):i&&e&&s.like(i,e)},isempty:function(i){return void 0===i||""===i},isnotempty:function(i){return void 0!==i&&""!==i},wildcard:function(i,e,t,n){return n&&(i=s.ignoreDiacritics(i),e=s.ignoreDiacritics(e)),t?(i||"boolean"==typeof i)&&e&&"object"!=typeof i&&s.wildCard(s.toLowerCase(i),s.toLowerCase(e)):(i||"boolean"==typeof i)&&e&&s.wildCard(i,e)},endswith:function(i,e,t,n){return n&&(i=s.ignoreDiacritics(i),e=s.ignoreDiacritics(e)),t?i&&e&&s.endsWith(s.toLowerCase(i),s.toLowerCase(e)):i&&e&&s.endsWith(i,e)},doesnotendwith:function(i,e,t,n){return n&&(i=s.ignoreDiacritics(i),e=s.ignoreDiacritics(e)),t?i&&e&&s.notEndsWith(s.toLowerCase(i),s.toLowerCase(e)):i&&e&&s.notEndsWith(i,e)},processSymbols:function(i){var e=s.operatorSymbols[i];return e?s.fnOperators[e]:s.throwError("Query - Process Operator : Invalid operator")},processOperator:function(i){return s.fnOperators[i]||s.fnOperators.processSymbols(i)}},s.parse={parseJson:function(i){return"string"!=typeof i||!/^[\s]*\[|^[\s]*\{(.)+:/g.test(i)&&-1!==i.indexOf('"')?i instanceof Array?s.parse.iterateAndReviveArray(i):"object"==typeof i&&null!==i&&s.parse.iterateAndReviveJson(i):i=JSON.parse(i,s.parse.jsonReviver),i},iterateAndReviveArray:function(i){for(var e=0;e-1||e.indexOf("z")>-1,o=e.split(/[^0-9.]/);if(r){if(o[5].indexOf(".")>-1){var a=o[5].split(".");o[5]=a[0],o[6]=new Date(e).getUTCMilliseconds().toString()}else o[6]="00";e=s.dateParse.toTimeZone(new Date(parseInt(o[0],10),parseInt(o[1],10)-1,parseInt(o[2],10),parseInt(o[3],10),parseInt(o[4],10),parseInt(o[5]?o[5]:"00",10),parseInt(o[6],10)),s.serverTimezoneOffset,!1)}else{var l=new Date(parseInt(o[0],10),parseInt(o[1],10)-1,parseInt(o[2],10),parseInt(o[3],10),parseInt(o[4],10),parseInt(o[5]?o[5]:"00",10)),c=parseInt(o[6],10),u=parseInt(o[7],10);if(isNaN(c)&&isNaN(u))return l;e.indexOf("+")>-1?l.setHours(l.getHours()-c,l.getMinutes()-u):l.setHours(l.getHours()+c,l.getMinutes()+u),e=s.dateParse.toTimeZone(l,s.serverTimezoneOffset,!1)}null==s.serverTimezoneOffset&&(e=s.dateParse.addSelfOffset(e))}}return e},isJson:function(i){return"string"==typeof i[0]?i:s.parse.parseJson(i)},isGuid:function(i){return null!=/[A-Fa-f0-9]{8}(?:-[A-Fa-f0-9]{4}){3}-[A-Fa-f0-9]{12}/i.exec(i)},replacer:function(i,e){return s.isPlainObject(i)?s.parse.jsonReplacer(i,e):i instanceof Array?s.parse.arrayReplacer(i):i instanceof Date?s.parse.jsonReplacer({val:i},e).val:i},jsonReplacer:function(i,e){for(var t,r=0,o=Object.keys(i);r=0?"+":"-",r=function(a){var l=Math.floor(Math.abs(a));return(l<10?"0":"")+l};return e.getFullYear()+"-"+r(e.getMonth()+1)+"-"+r(e.getDate())+"T"+r(e.getHours())+":"+r(e.getMinutes())+":"+r(e.getSeconds())+n+r(t/60)+":"+r(t%60)}},s}(),Mo=function(){var s=function(i,e){return(s=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,n){t.__proto__=n}||function(t,n){for(var r in n)n.hasOwnProperty(r)&&(t[r]=n[r])})(i,e)};return function(i,e){function t(){this.constructor=i}s(i,e),i.prototype=null===e?Object.create(e):(t.prototype=e.prototype,new t)}}(),bq={GroupGuid:"{271bbba0-1ee7}"},Vk=function(){function s(i){this.options={from:"table",requestType:"json",sortBy:"sorted",select:"select",skip:"skip",group:"group",take:"take",search:"search",count:"requiresCounts",where:"where",aggregates:"aggregates",expand:"expand"},this.type=s,this.dataSource=i,this.pvt={}}return s.prototype.processResponse=function(i,e,t,n){return i},s}(),qC=function(s){function i(){return null!==s&&s.apply(this,arguments)||this}return Mo(i,s),i.prototype.processQuery=function(e,t){for(var a,l,f,n=e.dataSource.json.slice(0),r=n.length,o=!0,c={},u=0,h=[],p=[],g=0;g1?e.sort.filter(function(f){return f.fieldName===u})[0]:e.sort[0];r=this.onSortBy(r,h,e.query,!0)}e.page&&(r=this.onPage(r,e.page,e.query)),this.formGroupResult(r,c)}else{for(var o=e.lazyLoad.onDemandGroupInfo,a=o.where.length-1;a>=0;a--)r=this.onWhere(r,o.where[a]);if(e.group.length!==o.level)r=Y.group(r,e.group[o.level].fieldName,n,null,null,e.group[o.level].comparer,!0),e.sort.length&&(r=this.onSortBy(r,e.sort[parseInt(o.level.toString(),10)],e.query,!0));else for(a=e.sort.length-1;a>=o.level;a--)r=this.onSortBy(r,e.sort[parseInt(a.toString(),10)],e.query,!1);t=r.length,c=r,r=(r=r.slice(o.skip)).slice(0,o.take),e.group.length!==o.level&&this.formGroupResult(r,c)}return{result:r,count:t}},i.prototype.formGroupResult=function(e,t){if(e.length&&t.length){var n="GroupGuid",r="childLevels",o="level",a="records";e[n]=t[n],e[r]=t[r],e[o]=t[o],e[a]=t[a]}return e},i.prototype.getAggregate=function(e){var t=ht.filterQueries(e.queries,"onAggregates"),n=[];if(t.length)for(var r=void 0,o=0;o=0;l--)a[l]&&(o=t.comparer,Y.endsWith(a[l]," desc")&&(o=Y.fnSort("descending"),a[l]=a[l].replace(" desc","")),e=Y.sort(e,a[l],o));return e}return Y.sort(e,r?"key":a,t.comparer)},i.prototype.onGroup=function(e,t,n){if(!e||!e.length)return e;var r=this.getAggregate(n);return Y.group(e,Y.getValue(t.fieldName,n),r,null,null,t.comparer)},i.prototype.onPage=function(e,t,n){var r=Y.getValue(t.pageSize,n),o=(Y.getValue(t.pageIndex,n)-1)*r;return e&&e.length?e.slice(o,o+r):e},i.prototype.onRange=function(e,t){return e&&e.length?e.slice(Y.getValue(t.start),Y.getValue(t.end)):e},i.prototype.onTake=function(e,t){return e&&e.length?e.slice(0,Y.getValue(t.nos)):e},i.prototype.onSkip=function(e,t){return e&&e.length?e.slice(Y.getValue(t.nos)):e},i.prototype.onSelect=function(e,t){return e&&e.length?Y.select(e,Y.getValue(t.fieldNames)):e},i.prototype.insert=function(e,t,n,r,o){return d(o)?e.dataSource.json.push(t):e.dataSource.json.splice(o,0,t)},i.prototype.remove=function(e,t,n,r){var a,o=e.dataSource.json;for("object"==typeof n&&!(n instanceof Date)&&(n=Y.getObject(t,n)),a=0;a1&&(v="("+v+")"),f.filters.push(v);for(var M=0,C="object"==typeof f.filters[g]?Object.keys(f.filters[g]):[];M-1&&this.formRemoteGroupedData(e[r].items,t+1,n-1);var o="GroupGuid",c="records";return e[o]=bq[o],e.level=t,e.childLevels=n,e[c]=e[0].items.length?this.getGroupedRecords(e,!d(e[0].items[c])):[],e},i.prototype.getGroupedRecords=function(e,t){for(var n=[],o=0;ol.length-3?(l=l.substring(0,l.length-1),o=d(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?Y.odUniOperator.endswith:Y.odv4UniOperator.endswith):l.lastIndexOf("%")!==l.indexOf("%")&&l.lastIndexOf("%")>l.indexOf("%")+1?(l=l.substring(l.indexOf("%")+1,l.lastIndexOf("%")),o=d(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?Y.odUniOperator.contains:Y.odv4UniOperator.contains):o=d(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?Y.odUniOperator.contains:Y.odv4UniOperator.contains),l="'"+(l=encodeURIComponent(l))+"'";else if("wildcard"===o)if(-1!==l.indexOf("*")){var h=l.split("*"),p=void 0,f=0;if(0!==l.indexOf("*")&&-1===h[0].indexOf("%3f")&&-1===h[0].indexOf("?")&&(p="'"+(p=h[0])+"'",r+=(o=d(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?Y.odUniOperator.startswith:Y.odv4UniOperator.startswith)+"(",r+=u+",",a&&(r+=a),r+=p+")",f++),l.lastIndexOf("*")!==l.length-1&&-1===h[h.length-1].indexOf("%3f")&&-1===h[h.length-1].indexOf("?")&&(p="'"+(p=h[h.length-1])+"'",f>0&&(r+=" and "),r+=(o=d(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?Y.odUniOperator.endswith:Y.odv4UniOperator.endswith)+"(",r+=u+",",a&&(r+=a),r+=p+")",f++),h.length>2)for(var g=1;g0&&(r+=" and "),"substringof"===(o=d(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?Y.odUniOperator.contains:Y.odv4UniOperator.contains)||"not substringof"===o){var v=p;p=u,u=v}r+=o+"(",r+=u+",",a&&(r+=a),r+=p+")",f++}0===f?(o=d(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?Y.odUniOperator.contains:Y.odv4UniOperator.contains,(-1!==l.indexOf("?")||-1!==l.indexOf("%3f"))&&(l=-1!==l.indexOf("?")?l.split("?").join(""):l.split("%3f").join("")),l="'"+l+"'"):o="wildcard"}else o=d(this.getModuleName)||"ODataV4Adaptor"!==this.getModuleName()?Y.odUniOperator.contains:Y.odv4UniOperator.contains,(-1!==l.indexOf("?")||-1!==l.indexOf("%3f"))&&(l=-1!==l.indexOf("?")?l.split("?").join(""):l.split("%3f").join("")),l="'"+l+"'";return"substringof"!==o&&"not substringof"!==o||(v=l,l=u,u=v),"wildcard"!==o&&(r+=o+"(",r+=u+",",a&&(r+=a),r+=l+")"),r},i.prototype.addParams=function(e){s.prototype.addParams.call(this,e),delete e.reqParams.params},i.prototype.onComplexPredicate=function(e,t,n){for(var r=[],o=0;o-1;f--)!/\bContent-ID:/i.test(u[f])||!/\bHTTP.+201/.test(u[f])||(l=parseInt(/\bContent-ID: (\d+)/i.exec(u[f])[1],10),o.addedRecords[l]&&(c=Y.parse.parseJson(/^\{.+\}/m.exec(u[f])[0]),he({},o.addedRecords[l],this.processResponse(c))));return o}return null},i.prototype.compareAndRemove=function(e,t,n){var r=this;return d(t)||Object.keys(e).forEach(function(o){o!==n&&"@odata.etag"!==o&&(Y.isPlainObject(e[o])?(r.compareAndRemove(e[o],t[o]),0===Object.keys(e[o]).filter(function(l){return"@odata.etag"!==l}).length&&delete e[o]):(e[o]===t[o]||e[o]&&t[o]&&e[o].valueOf()===t[o].valueOf())&&delete e[o])}),e},i}(qa),Mq=function(s){function i(){var e=s.call(this)||this;return Ue("beforeSend",qa.prototype.beforeSend,e),e}return Mo(i,s),i.prototype.insert=function(e,t,n,r,o){return this.pvt.position=o,this.updateType="add",{url:e.dataSource.insertUrl||e.dataSource.crudUrl||e.dataSource.url,data:JSON.stringify(he({},{value:t,table:n,action:"insert"},Y.getAddParams(this,e,r)))}},i.prototype.remove=function(e,t,n,r,o){return s.prototype.remove.call(this,e,t,n),{type:"POST",url:e.dataSource.removeUrl||e.dataSource.crudUrl||e.dataSource.url,data:JSON.stringify(he({},{key:n,keyColumn:t,table:r,action:"remove"},Y.getAddParams(this,e,o)))}},i.prototype.update=function(e,t,n,r,o){return this.updateType="update",this.updateKey=t,{type:"POST",url:e.dataSource.updateUrl||e.dataSource.crudUrl||e.dataSource.url,data:JSON.stringify(he({},{value:n,action:"update",keyColumn:t,key:n[t],table:r},Y.getAddParams(this,e,o)))}},i.prototype.processResponse=function(e,t,n,r,o,a,l){var c;if(e="batch"===(o?JSON.parse(o.data):e).action?Y.parse.parseJson(e):e,"add"===this.updateType&&s.prototype.insert.call(this,t,e,null,null,this.pvt.position),"update"===this.updateType&&s.prototype.update.call(this,t,this.updateKey,e),this.updateType=void 0,e.added)for(c=0;ct&&c.push(u)}for(u=0;uthis.pageSize;)c.results.splice(0,1),c.keys.splice(0,1);return window.localStorage.setItem(this.guidId,JSON.stringify(c)),e},i.prototype.beforeSend=function(e,t,n){!d(this.cacheAdaptor.options.batch)&&Y.endsWith(n.url,this.cacheAdaptor.options.batch)&&"post"===n.type.toLowerCase()&&t.headers.set("Accept",this.cacheAdaptor.options.multipartAccept),e.dataSource.crossDomain||t.headers.set("Accept",this.cacheAdaptor.options.accept)},i.prototype.update=function(e,t,n,r){return this.isCrudAction=!0,this.cacheAdaptor.update(e,t,n,r)},i.prototype.insert=function(e,t,n){return this.isInsertAction=!0,this.cacheAdaptor.insert(e,t,n)},i.prototype.remove=function(e,t,n,r){return this.isCrudAction=!0,this.cacheAdaptor.remove(e,t,n,r)},i.prototype.batchRequest=function(e,t,n){return this.cacheAdaptor.batchRequest(e,t,n)},i}(qa),Oe=function(){function s(i,e,t){var r,n=this;return this.dateParse=!0,this.timeZoneHandling=!0,this.persistQuery={},this.isInitialLoad=!1,this.requests=[],this.isInitialLoad=!0,!i&&!this.dataSource&&(i=[]),t=t||i.adaptor,i&&!1===i.timeZoneHandling&&(this.timeZoneHandling=i.timeZoneHandling),i instanceof Array?r={json:i,offline:!0}:"object"==typeof i?(i.json||(i.json=[]),i.enablePersistence||(i.enablePersistence=!1),i.id||(i.id=""),i.ignoreOnPersist||(i.ignoreOnPersist=[]),r={url:i.url,insertUrl:i.insertUrl,removeUrl:i.removeUrl,updateUrl:i.updateUrl,crudUrl:i.crudUrl,batchUrl:i.batchUrl,json:i.json,headers:i.headers,accept:i.accept,data:i.data,timeTillExpiration:i.timeTillExpiration,cachingPageSize:i.cachingPageSize,enableCaching:i.enableCaching,requestType:i.requestType,key:i.key,crossDomain:i.crossDomain,jsonp:i.jsonp,dataType:i.dataType,offline:void 0!==i.offline?i.offline:!(i.adaptor instanceof Mq||i.adaptor instanceof Cq||i.url),requiresFormat:i.requiresFormat,enablePersistence:i.enablePersistence,id:i.id,ignoreOnPersist:i.ignoreOnPersist}):Y.throwError("DataManager: Invalid arguments"),void 0===r.requiresFormat&&!Y.isCors()&&(r.requiresFormat=!!d(r.crossDomain)||r.crossDomain),void 0===r.dataType&&(r.dataType="json"),this.dataSource=r,this.defaultQuery=e,this.dataSource.enablePersistence&&this.dataSource.id&&window.addEventListener("unload",this.setPersistData.bind(this)),r.url&&r.offline&&!r.json.length?(this.isDataAvailable=!1,this.adaptor=t||new xu,this.dataSource.offline=!1,this.ready=this.executeQuery(e||new ht),this.ready.then(function(o){n.dataSource.offline=!0,n.isDataAvailable=!0,r.json=o.result,n.adaptor=new qC})):this.adaptor=r.offline?new qC:new xu,!r.jsonp&&this.adaptor instanceof xu&&(r.jsonp="callback"),this.adaptor=t||this.adaptor,r.enableCaching&&(this.adaptor=new Iq(this.adaptor,r.timeTillExpiration,r.cachingPageSize)),this}return Object.defineProperty(s.prototype,"moduleName",{get:function(){return"datamanager"},enumerable:!0,configurable:!0}),s.prototype.getPersistedData=function(i){var e=localStorage.getItem(i||this.dataSource.id);return JSON.parse(e)},s.prototype.setPersistData=function(i,e,t){localStorage.setItem(e||this.dataSource.id,JSON.stringify(t||this.persistQuery))},s.prototype.setPersistQuery=function(i){var e=this,t=this.getPersistedData();if(this.isInitialLoad&&t&&Object.keys(t).length){this.persistQuery=t,this.persistQuery.queries=this.persistQuery.queries.filter(function(r){if(e.dataSource.ignoreOnPersist&&e.dataSource.ignoreOnPersist.length&&r.fn&&e.dataSource.ignoreOnPersist.some(function(l){return r.fn===l}))return!1;if("onWhere"===r.fn){var o=r.e;if(o&&o.isComplex&&o.predicates instanceof Array){var a=o.predicates.map(function(l){if(l.predicates&&l.predicates instanceof Array){var c=l.predicates.map(function(b){return new Gn(b.field,b.operator,b.value,b.ignoreCase,b.ignoreAccent,b.matchCase)});return"and"===l.condition?Gn.and(c):Gn.or(c)}return new Gn(l.field,l.operator,l.value,l.ignoreCase,l.ignoreAccent,l.matchCase)});r.e=new Gn(a[0],o.condition,a.slice(1))}}return!0});var n=he(new ht,this.persistQuery);return this.isInitialLoad=!1,n}return this.persistQuery=i,this.isInitialLoad=!1,i},s.prototype.setDefaultQuery=function(i){return this.defaultQuery=i,this},s.prototype.executeLocal=function(i){!this.defaultQuery&&!(i instanceof ht)&&Y.throwError("DataManager - executeLocal() : A query is required to execute"),this.dataSource.json||Y.throwError("DataManager - executeLocal() : Json data is required to execute"),this.dataSource.enablePersistence&&this.dataSource.id&&(i=this.setPersistQuery(i));var e=this.adaptor.processQuery(this,i=i||this.defaultQuery);if(i.subQuery){var t=i.subQuery.fromTable,n=i.subQuery.lookups,r=i.isCountRequired?e.result:e;n&&n instanceof Array&&Y.buildHierarchy(i.subQuery.fKey,t,r,n,i.subQuery.key);for(var o=0;o=0;a--)(o=s[a])&&(r=(n<3?o(r):n>3?o(i,e,r):o(i,e))||r);return n>3&&r&&Object.defineProperty(i,e,r),r},vr_RTL=(new Fd,"e-rtl"),Zn=function(s){function i(e,t){return s.call(this,e,t)||this}return Nq(i,s),i.prototype.preRender=function(){},i.prototype.render=function(){this.initialize(),this.removeRippleEffect=$n(this.element,{selector:".e-btn"}),this.renderComplete()},i.prototype.initialize=function(){if(this.cssClass&&N([this.element],this.cssClass.replace(/\s+/g," ").trim().split(" ")),this.isPrimary&&this.element.classList.add("e-primary"),!Ne()||Ne()&&"progress-btn"!==this.getModuleName()){if(this.content){var e=this.enableHtmlSanitizer?Qt.sanitize(this.content):this.content;this.element.innerHTML=e}this.setIconCss()}this.enableRtl&&this.element.classList.add(vr_RTL),this.disabled?this.controlStatus(this.disabled):this.wireEvents()},i.prototype.controlStatus=function(e){this.element.disabled=e},i.prototype.setIconCss=function(){if(this.iconCss){var e=this.createElement("span",{className:"e-btn-icon "+this.iconCss});this.element.textContent.trim()?(e.classList.add("e-icon-"+this.iconPosition.toLowerCase()),("Top"===this.iconPosition||"Bottom"===this.iconPosition)&&this.element.classList.add("e-"+this.iconPosition.toLowerCase()+"-icon-btn")):this.element.classList.add("e-icon-btn");var t=this.element.childNodes[0];!t||"Left"!==this.iconPosition&&"Top"!==this.iconPosition?this.element.appendChild(e):this.element.insertBefore(e,t)}},i.prototype.wireEvents=function(){this.isToggle&&y.add(this.element,"click",this.btnClickHandler,this)},i.prototype.unWireEvents=function(){this.isToggle&&y.remove(this.element,"click",this.btnClickHandler)},i.prototype.btnClickHandler=function(){this.element.classList.contains("e-active")?this.element.classList.remove("e-active"):this.element.classList.add("e-active")},i.prototype.destroy=function(){var e=["e-primary",vr_RTL,"e-icon-btn","e-success","e-info","e-danger","e-warning","e-flat","e-outline","e-small","e-bigger","e-active","e-round","e-top-icon-btn","e-bottom-icon-btn"];this.cssClass&&(e=e.concat(this.cssClass.split(" "))),s.prototype.destroy.call(this),R([this.element],e),this.element.getAttribute("class")||this.element.removeAttribute("class"),this.disabled&&this.element.removeAttribute("disabled"),this.content&&(this.element.innerHTML=this.element.innerHTML.replace(this.content,""));var t=this.element.querySelector("span.e-btn-icon");t&&$(t),this.unWireEvents(),mr&&this.removeRippleEffect()},i.prototype.getModuleName=function(){return"btn"},i.prototype.getPersistData=function(){return this.addOnPersist([])},i.Inject=function(){},i.prototype.onPropertyChanged=function(e,t){for(var n=this.element.querySelector("span.e-btn-icon"),r=0,o=Object.keys(e);rli");F.classList.remove("json-parent");for(var H=0;H=Ul.width?Ul.width:0;return Io.right+Ej()-s}function OI(){return Pm()+Io.width/2}function xI(s,i,e,t){if(void 0===i&&(i=null),void 0===e&&(e={X:!1,Y:!1}),!e.Y&&!e.X)return{left:0,top:0};var n=s.getBoundingClientRect();if(Vs=i,$a=s.ownerDocument,t||(t=Vn(s,"left","top")),e.X){var r=Vs?wj():kj(),o=zI(),a=_I(),l=o-t.left,c=t.left+n.width-a;n.width>r?t.left=l>0&&c<=0?a-n.width:c>0&&l<=0?o:l>c?a-n.width:o:l>0?t.left+=l:c>0&&(t.left-=c)}if(e.Y){var u=Vs?Aj():xj(),h=PI(),p=FI(),f=h-t.top,g=t.top+n.height-p;n.height>u?t.top=f>0&&g<=0?p-n.height:g>0&&f<=0?h:f>g?p-n.height:h:f>0?t.top+=f:g>0&&(t.top-=g)}return t}function Ga(s,i,e,t){void 0===i&&(i=null);var n=Vn(s,"left","top");e&&(n.left=e),t&&(n.top=t);var r=[];Vs=i,$a=s.ownerDocument;var o=s.getBoundingClientRect(),l=n.left,c=n.left+o.width,h=RI(n.top,n.top+o.height),p=Sj(l,c);return h.topSide&&r.push("top"),p.rightSide&&r.push("right"),p.leftSide&&r.push("left"),h.bottomSide&&r.push("bottom"),r}function c$(s,i,e,t,n,r,o,a,l){if(void 0===o&&(o=null),void 0===a&&(a={X:!0,Y:!0}),i&&s&&n&&r&&(a.X||a.Y)){var h,c={TL:null,TR:null,BL:null,BR:null},u={TL:null,TR:null,BL:null,BR:null};if("none"===window.getComputedStyle(s).display){var p=s.style.visibility;s.style.visibility="hidden",s.style.display="block",h=s.getBoundingClientRect(),s.style.removeProperty("display"),s.style.visibility=p}else h=s.getBoundingClientRect();var f={posX:n,posY:r,offsetX:e,offsetY:t,position:{left:0,top:0}};Vs=o,$a=i.ownerDocument,function h$(s,i,e,t,n){e.position=Vn(s,e.posX,e.posY,t,n),i.TL=Vn(s,"left","top",t,n),i.TR=Vn(s,"right","top",t,n),i.BR=Vn(s,"left","bottom",t,n),i.BL=Vn(s,"right","bottom",t,n)}(i,c,f,l,h),jI(u,f,h),a.X&&Nj(i,u,c,f,h,!0),a.Y&&c.TL.top>-1&&Tj(i,u,c,f,h,!0),function u$(s,i,e){var t=0,n=0;if(null!=s.offsetParent&&("absolute"===getComputedStyle(s.offsetParent).position||"relative"===getComputedStyle(s.offsetParent).position)){var r=Vn(s.offsetParent,"left","top",!1,e);t=r.left,n=r.top}var o=1,a=1,l=Dj(s);if(l){var c=getComputedStyle(l).transform;if("none"!==c){var u=new DOMMatrix(c);o=u.a,a=u.d}if("none"!==getComputedStyle(l).zoom){var p=kI(document.body);o*=p,a*=p}}s.style.top=i.position.top/a+i.offsetY-n/a+"px",s.style.left=i.position.left/o+i.offsetX-t/o+"px"}(s,f,h)}}function kI(s){var i=getComputedStyle(s).zoom;return parseFloat(i)||1}function Dj(s){for(;s;){var i=window.getComputedStyle(s).transform,e=kI(document.body);if(i&&"none"!==i||e&&1!==e)return s;if(s===document.body)return null;s=s.offsetParent||s.parentElement}return null}function jI(s,i,e){s.TL={top:i.position.top+i.offsetY,left:i.position.left+i.offsetX},s.TR={top:s.TL.top,left:s.TL.left+e.width},s.BL={top:s.TL.top+e.height,left:s.TL.left},s.BR={top:s.TL.top+e.height,left:s.TL.left+e.width}}function Sj(s,i){var e=!1,t=!1;return s-_m()_I()&&(t=!0),{leftSide:e,rightSide:t}}function Nj(s,i,e,t,n,r){var o=Sj(i.TL.left,i.TR.left),a=RI(i.TL.top,i.BL.top);e.TL.left-_m()<=zI()&&(o.leftSide=!1),e.TR.left>_I()&&(o.rightSide=!1),(o.leftSide&&!o.rightSide||!o.leftSide&&o.rightSide)&&(t.posX="right"===t.posX?"left":"right",t.offsetX=t.offsetX+n.width,t.offsetX=-1*t.offsetX,t.position=Vn(s,t.posX,t.posY,!1),jI(i,t,n),r&&Nj(s,i,e,t,n,!1),!o.leftSide&&o.rightSide&&a.bottomSide&&(t.offsetX=0))}function Tj(s,i,e,t,n,r){var o=RI(i.TL.top,i.BL.top);e.TL.top-zm()<=PI()&&(o.topSide=!1),e.BL.top>=FI()&&s.getBoundingClientRect().bottomFI()&&(t=!0),{topSide:e,bottomSide:t}}function wj(){return Vs.getBoundingClientRect().width}function Aj(){return Vs.getBoundingClientRect().height}function Lj(){return Vs.getBoundingClientRect().left}function Oj(){return Vs.getBoundingClientRect().top}function PI(){return Vs?Oj():0}function zI(){return Vs?Lj():0}function _I(){return Vs?_m()+Lj()+wj():_m()+kj()}function FI(){return Vs?zm()+Oj()+Aj():zm()+xj()}function zm(){return $a.documentElement.scrollTop||$a.body.scrollTop}function _m(){return $a.documentElement.scrollLeft||$a.body.scrollLeft}function xj(){return window.innerHeight}function kj(){var s=window.innerWidth,i=document.documentElement.getBoundingClientRect();return s-(s-(d(document.documentElement)?0:i.width))}function jj(){Vs=null,$a=null}var Rj=function(){var s=function(i,e){return(s=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,n){t.__proto__=n}||function(t,n){for(var r in n)n.hasOwnProperty(r)&&(t[r]=n[r])})(i,e)};return function(i,e){function t(){this.constructor=i}s(i,e),i.prototype=null===e?Object.create(e):(t.prototype=e.prototype,new t)}}(),fn=function(s,i,e,t){var o,n=arguments.length,r=n<3?i:null===t?t=Object.getOwnPropertyDescriptor(i,e):t;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)r=Reflect.decorate(s,i,e,t);else for(var a=s.length-1;a>=0;a--)(o=s[a])&&(r=(n<3?o(r):n>3?o(i,e,r):o(i,e))||r);return n>3&&r&&Object.defineProperty(i,e,r),r},Pj=function(s){function i(){return null!==s&&s.apply(this,arguments)||this}return Rj(i,s),fn([m("left")],i.prototype,"X",void 0),fn([m("top")],i.prototype,"Y",void 0),i}(Lt),Rn_OPEN="e-popup-open",Rn_CLOSE="e-popup-close",Za=function(s){function i(e,t){return s.call(this,t,e)||this}return Rj(i,s),i.prototype.onPropertyChanged=function(e,t){for(var n=0,r=Object.keys(e);n0&&u.left>0&&u.right>0&&u.bottom>0}var r=t.getBoundingClientRect();return!(n.bottomr.bottom||n.right>r.right||n.leftn.top?this.element.style.top="0px":r.bottomn.left&&(this.element.style.left=parseInt(this.element.style.left,10)+(r.left-n.left)+"px"))}},i.prototype.checkCollision=function(){var e=this.collision.X,t=this.collision.Y;"none"===e&&"none"===t||("flip"===e&&"flip"===t?this.callFlip({X:!0,Y:!0}):"fit"===e&&"fit"===t?this.callFit({X:!0,Y:!0}):("flip"===e?this.callFlip({X:!0,Y:!1}):"flip"===t&&this.callFlip({Y:!0,X:!1}),"fit"===e?this.callFit({X:!0,Y:!1}):"fit"===t&&this.callFit({X:!1,Y:!0})))},i.prototype.show=function(e,t){var n=this;if(this.getRelateToElement().classList.contains("e-filemanager")&&(this.fmDialogContainer=this.element.getElementsByClassName("e-file-select-wrap")[0]),this.wireEvents(),!d(this.fmDialogContainer)&&_.isIos&&(this.fmDialogContainer.style.display="block"),1e3===this.zIndex||!d(t)){var o=d(t)?this.element:t;this.zIndex=Xa(o),be(this.element,{zIndex:this.zIndex})}e=d(e)||"object"!=typeof e?this.showAnimation:e,("none"!==this.collision.X||"none"!==this.collision.Y)&&(R([this.element],Rn_CLOSE),N([this.element],Rn_OPEN),this.checkCollision(),R([this.element],Rn_OPEN),N([this.element],Rn_CLOSE)),d(e)?(R([this.element],Rn_CLOSE),N([this.element],Rn_OPEN),this.trigger("open")):(e.begin=function(){n.isDestroyed||(R([n.element],Rn_CLOSE),N([n.element],Rn_OPEN))},e.end=function(){n.isDestroyed||n.trigger("open")},new ds(e).animate(this.element))},i.prototype.hide=function(e){var t=this;e=d(e)||"object"!=typeof e?this.hideAnimation:e,d(e)?(R([this.element],Rn_OPEN),N([this.element],Rn_CLOSE),this.trigger("close")):(e.end=function(){t.isDestroyed||(R([t.element],Rn_OPEN),N([t.element],Rn_CLOSE),t.trigger("close"))},new ds(e).animate(this.element)),this.unwireEvents()},i.prototype.getScrollableParent=function(e){return this.checkFixedParent(e),function HI(s,i){for(var e=getComputedStyle(s),t=[],n=/(auto|scroll)/,r=s.parentElement;r&&"HTML"!==r.tagName;){var o=getComputedStyle(r);!("absolute"===e.position&&"static"===o.position)&&n.test(o.overflow+o.overflowY+o.overflowX)&&t.push(r),r=r.parentElement}return i||t.push(document),t}(e,this.fixedParent)},i.prototype.checkFixedParent=function(e){for(var t=e.parentElement;t&&"HTML"!==t.tagName;){var n=getComputedStyle(t);("fixed"===n.position||"sticky"===n.position)&&!d(this.element)&&this.element.offsetParent&&"BODY"===this.element.offsetParent.tagName&&"hidden"!==getComputedStyle(this.element.offsetParent).overflow&&(this.element.style.top=window.scrollY>parseInt(this.element.style.top,10)?de(window.scrollY-parseInt(this.element.style.top,10)):de(parseInt(this.element.style.top,10)-window.scrollY),this.element.style.position="fixed",this.fixedParent=!0),t=t.parentElement,!d(this.element)&&d(this.element.offsetParent)&&"fixed"===n.position&&"fixed"===this.element.style.position&&(this.fixedParent=!0)}},fn([m("auto")],i.prototype,"height",void 0),fn([m("auto")],i.prototype,"width",void 0),fn([m(null)],i.prototype,"content",void 0),fn([m("container")],i.prototype,"targetType",void 0),fn([m(null)],i.prototype,"viewPortElement",void 0),fn([m({X:"none",Y:"none"})],i.prototype,"collision",void 0),fn([m("")],i.prototype,"relateTo",void 0),fn([di({},Pj)],i.prototype,"position",void 0),fn([m(0)],i.prototype,"offsetX",void 0),fn([m(0)],i.prototype,"offsetY",void 0),fn([m(1e3)],i.prototype,"zIndex",void 0),fn([m(!1)],i.prototype,"enableRtl",void 0),fn([m("reposition")],i.prototype,"actionOnScroll",void 0),fn([m(null)],i.prototype,"showAnimation",void 0),fn([m(null)],i.prototype,"hideAnimation",void 0),fn([w()],i.prototype,"open",void 0),fn([w()],i.prototype,"close",void 0),fn([w()],i.prototype,"targetExitViewport",void 0),fn([ct],i)}(ei);function Xa(s){for(var i=s.parentElement,e=[];i&&"BODY"!==i.tagName;){var t=document.defaultView.getComputedStyle(i,null).getPropertyValue("z-index"),n=document.defaultView.getComputedStyle(i,null).getPropertyValue("position");"auto"!==t&&"static"!==n&&e.push(t),i=i.parentElement}for(var r=[],o=0;o2147483647?2147483647:u}var ti,Yr,ku,ha,WI,da,Ct,pa,BI=["north-west","north","north-east","west","east","south-west","south","south-east"],tp="e-resize-handle",Ka="e-focused-handle",d$="e-dlg-resizable",zj=["e-restrict-left"],_j="e-resize-viewport",p$=["north","west","east","south"],VI=0,UI=0,Fj=0,Hj=0,ip=0,np=0,sp=null,YI=null,QI=null,Fm=!0,Bj=0,qI=!0;function g$(s){$I();var i=_t("span",{attrs:{unselectable:"on",contenteditable:"false"}});i.setAttribute("class","e-dialog-border-resize e-"+s),"south"===s&&(i.style.height="2px",i.style.width="100%",i.style.bottom="0px",i.style.left="0px"),"north"===s&&(i.style.height="2px",i.style.width="100%",i.style.top="0px",i.style.left="0px"),"east"===s&&(i.style.height="100%",i.style.width="2px",i.style.right="0px",i.style.top="0px"),"west"===s&&(i.style.height="100%",i.style.width="2px",i.style.left="0px",i.style.top="0px"),ti.appendChild(i)}function Vj(s){var i;return d(s)||(i="string"==typeof s?document.querySelector(s):s),i}function Uj(s){for(var i=s||this,e=ti.querySelectorAll("."+tp),t=0;t-1?"mouse":"touch"}function Yj(s){if(s.preventDefault(),ti=s.target.parentElement,$I(),ip=s.pageX,np=s.pageY,s.target.classList.add(Ka),d(sp)||!0!==sp(s,this)){this.targetEle&&ti&&ti.querySelector("."+d$)&&(Ct="body"===this.target?null:this.targetEle,da=this.targetEle.clientWidth,ha=this.targetEle.clientHeight);var e=d(Ct)?document:Ct;y.add(e,"mousemove",rp,this),y.add(document,"mouseup",Hm,this);for(var t=0;t=0||r.top<0)&&(e=!0):e=!0;var a=UI+(n-np);a=a>ku?a:ku;var l=0;d(Ct)||(l=o.top);var c=d(Ct)?0:Ct.offsetHeight-Ct.clientHeight,u=r.top-l-c/2;if(u=u<0?0:u,r.top>0&&u+a>ha){if(e=!1,ti.classList.contains(_j))return;ti.style.height=ha-parseInt(u.toString(),10)+"px"}else{var h=0;if(e){r.top<0&&i+(r.height+r.top)>0&&a+(h=r.top)<=30&&(a=r.height-(r.height+r.top)+30),a+r.top>=ha&&(ti.style.height=r.height+(i-(r.height+r.top))+"px");var p=d(Ct)?h:u;a>=ku&&a+p<=ha&&(ti.style.height=a+"px")}}}function ZI(s){var e,i=!1,t="mouse"===Wj(s.type)?s.pageY:s.touches[0].pageY,n=Ja(ti),r=d(Ct)?0:Ct.offsetHeight-Ct.clientHeight;d(Ct)||(e=Ja(Ct)),(!d(Ct)&&n.top-e.top>0||d(Ct)&&t>0||!d(Ct)&&Math.floor(n.top-e.top+n.height+(e.bottom-n.bottom))-r<=ha)&&(i=!0);var o=UI-(t-np);if(i&&o>=ku&&o<=ha){var a=0;d(Ct)||(a=e.top);var l=Hj-a+(t-np);l=l>0?l:1,ti.style.height=o+"px",ti.style.top=l+"px"}}function XI(s){var t,i=document.documentElement.clientWidth,e=!1;d(Ct)||(t=Ja(Ct));var n="mouse"===Wj(s.type)?s.pageX:s.touches[0].pageX,r=Ja(ti),o=d(Ct)?0:Ct.offsetWidth-Ct.clientWidth,a=d(Ct)?0:t.left,l=d(Ct)?0:t.width;d(pa)&&(d(Ct)?pa=i:(pa=r.left-a-o/2+r.width,pa+=l-o-pa)),(!d(Ct)&&Math.floor(r.left-t.left+r.width+(t.right-r.right))-o<=da||d(Ct)&&n>=0)&&(e=!0);var c=VI-(n-ip);if(Fm&&(c=c>pa?pa:c),e&&c>=WI&&c<=da){var u=0;d(Ct)||(u=t.left);var h=Fj-u+(n-ip);h=h>0?h:1,c!==Bj&&qI&&(ti.style.width=c+"px"),Fm&&(ti.style.left=h+"px",qI=1!==h)}Bj=c}function KI(s){var t,i=document.documentElement.clientWidth,e=!1;d(Ct)||(t=Ja(Ct));var r=(s.touches?s.changedTouches[0]:s).pageX,o=Ja(ti);(!d(Ct)&&(o.left-t.left+o.width<=da||o.right-t.left>=o.width)||d(Ct)&&i-r>0)&&(e=!0);var a=VI+(r-ip),l=0;if(d(Ct)||(l=t.left),o.left-l+a>da){if(e=!1,ti.classList.contains(_j))return;ti.style.width=da-(o.left-l)+"px"}e&&a>=WI&&a<=da&&(ti.style.width=a+"px")}function qj(){for(var s=ti.querySelectorAll("."+tp),i=0;i=0;a--)(o=s[a])&&(r=(n<3?o(r):n>3?o(i,e,r):o(i,e))||r);return n>3&&r&&Object.defineProperty(i,e,r),r},M$=function(s){function i(){return null!==s&&s.apply(this,arguments)||this}return JI(i,s),It([m(!0)],i.prototype,"isFlat",void 0),It([m()],i.prototype,"buttonModel",void 0),It([m("Button")],i.prototype,"type",void 0),It([w()],i.prototype,"click",void 0),i}(Lt),C$=function(s){function i(){return null!==s&&s.apply(this,arguments)||this}return JI(i,s),It([m("Fade")],i.prototype,"effect",void 0),It([m(400)],i.prototype,"duration",void 0),It([m(0)],i.prototype,"delay",void 0),i}(Lt),Bm="e-dialog",eE="e-rtl",tE="e-dlg-header-content",$j="e-dlg-header",Vm="e-footer-content",Um="e-dlg-modal",Gj="e-icon-dlg-close",Qr="e-dlg-target",br="e-scroll-disabled",Zj="e-device",Wm="e-dlg-fullscreen",Xj="e-dlg-closeicon-btn",Kj="e-popup-open",Jj="Information",eR="e-scroll-disabled",tR="e-alert-dialog",iR="e-confirm-dialog",iE="e-dlg-resizable",ju="e-restrict-left",nR="e-resize-viewport",nE="user action",j$=function(s){function i(e,t){var n=s.call(this,e,t)||this;return n.needsID=!0,n}return JI(i,s),i.prototype.render=function(){this.initialize(),this.initRender(),this.wireEvents(),"100%"===this.width&&(this.element.style.width=""),""!==this.minHeight&&(this.element.style.minHeight=de(this.minHeight)),this.enableResize&&(this.setResize(),this.isModal&&(this.isModelResize=!0),"None"===this.animationSettings.effect&&this.getMinHeight()),this.renderComplete()},i.prototype.initializeValue=function(){this.dlgClosedBy=nE},i.prototype.preRender=function(){var e=this;if(this.initializeValue(),this.headerContent=null,this.allowMaxHeight=!0,this.preventVisibility=!0,this.clonedEle=this.element.cloneNode(!0),this.closeIconClickEventHandler=function(r){e.dlgClosedBy="close icon",e.hide(r)},this.dlgOverlayClickEventHandler=function(r){e.dlgClosedBy="overlayClick",r.preventFocus=!1,e.trigger("overlayClick",r,function(o){o.preventFocus||e.focusContent(),e.dlgClosedBy=nE})},this.l10n=new Br("dialog",{close:"Close"},this.locale),this.checkPositionData(),d(this.target)){var n=this.isProtectedOnChange;this.isProtectedOnChange=!0,this.target=document.body,this.isProtectedOnChange=n}},i.prototype.updatePersistData=function(){this.enablePersistence&&this.setProperties({width:parseFloat(this.element.style.width),height:parseFloat(this.element.style.height),position:{X:parseFloat(this.dragObj.element.style.left),Y:parseFloat(this.dragObj.element.style.top)}},!0)},i.prototype.isNumberValue=function(e){return/^[-+]?\d*\.?\d+$/.test(e)},i.prototype.checkPositionData=function(){if(!d(this.position)){if(!d(this.position.X)&&"number"!=typeof this.position.X&&this.isNumberValue(this.position.X)){var t=this.isProtectedOnChange;this.isProtectedOnChange=!0,this.position.X=parseFloat(this.position.X),this.isProtectedOnChange=t}d(this.position.Y)||"number"==typeof this.position.Y||this.isNumberValue(this.position.Y)&&(t=this.isProtectedOnChange,this.isProtectedOnChange=!0,this.position.Y=parseFloat(this.position.Y),this.isProtectedOnChange=t)}},i.prototype.getEle=function(e,t){for(var n=void 0,r=0;r=0&&i[e])g$(i[e]);else if(""!==i[e].trim()){var t=_t("div",{className:"e-icons "+tp+" e-"+i[e]});ti.appendChild(t)}ku=s.minHeight,WI=s.minWidth,da=s.maxWidth,ha=s.maxHeight,s.proxy&&s.proxy.element&&s.proxy.element.classList.contains("e-dialog")?Uj(s.proxy):Uj()}({element:this.element,direction:n,minHeight:parseInt(e.slice(0,t.indexOf("p")),10),maxHeight:this.targetEle.clientHeight,minWidth:parseInt(t.slice(0,t.indexOf("p")),10),maxWidth:this.targetEle.clientWidth,boundary:this.target===document.body?null:this.targetEle,resizeBegin:this.onResizeStart.bind(this),resizeComplete:this.onResizeComplete.bind(this),resizing:this.onResizing.bind(this),proxy:this}),this.wireWindowResizeEvent()}else qj(),this.unWireWindowResizeEvent(),this.element.classList.remove(this.isModal?ju:nR),this.element.classList.remove(iE)},i.prototype.getFocusElement=function(e){var n=e.querySelectorAll('input,select,textarea,button:enabled,a,[contenteditable="true"],[tabindex]');return{element:n[n.length-1]}},i.prototype.keyDown=function(e){var t=this;if(9===e.keyCode&&this.isModal){var n=void 0;d(this.btnObj)||(n=this.btnObj[this.btnObj.length-1]),d(this.btnObj)&&!d(this.ftrTemplateContent)&&(n=this.getFocusElement(this.ftrTemplateContent)),d(this.btnObj)&&d(this.ftrTemplateContent)&&!d(this.contentEle)&&(n=this.getFocusElement(this.contentEle)),!d(n)&&document.activeElement===n.element&&!e.shiftKey&&(e.preventDefault(),this.focusableElements(this.element).focus()),document.activeElement===this.focusableElements(this.element)&&e.shiftKey&&(e.preventDefault(),d(n)||n.element.focus())}var c,r=document.activeElement,o=["input","textarea"].indexOf(r.tagName.toLowerCase())>-1,a=!1;if(o||(a=r.hasAttribute("contenteditable")&&"true"===r.getAttribute("contenteditable")),27===e.keyCode&&this.closeOnEscape){this.dlgClosedBy="escape";var l=document.querySelector(".e-popup-open:not(.e-dialog)");!d(l)&&!l.classList.contains("e-toolbar-pop")&&!l.classList.contains("e-slider-tooltip")||this.hide(e)}(13===e.keyCode&&!e.ctrlKey&&"textarea"!==r.tagName.toLowerCase()&&o&&!d(this.primaryButtonEle)||13===e.keyCode&&e.ctrlKey&&("textarea"===r.tagName.toLowerCase()||a)&&!d(this.primaryButtonEle))&&this.buttons.some(function(h,p){c=p;var f=h.buttonModel;return!d(f)&&!0===f.isPrimary})&&"function"==typeof this.buttons[c].click&&setTimeout(function(){t.buttons[c].click.call(t,e)})},i.prototype.initialize=function(){d(this.target)||(this.targetEle="string"==typeof this.target?document.querySelector(this.target):this.target),this.isBlazorServerRender()||N([this.element],Bm),_.isDevice&&N([this.element],Zj),this.isBlazorServerRender()||this.setCSSClass(),this.setMaxHeight()},i.prototype.initRender=function(){var e=this;if(this.initialRender=!0,this.isBlazorServerRender()||ge(this.element,{role:"dialog"}),1e3===this.zIndex?(this.setzIndex(this.element,!1),this.calculatezIndex=!0):this.calculatezIndex=!1,this.setTargetContent(),""!==this.header&&!d(this.header)&&this.setHeader(),this.renderCloseIcon(),this.setContent(),""===this.footerTemplate||d(this.footerTemplate)?!d(this.buttons[0])&&!d(this.buttons[0].buttonModel)&&this.setButton():this.setFooterTemplate(),this.allowDragging&&!d(this.headerContent)&&this.setAllowDragging(),ge(this.element,{"aria-modal":this.isModal?"true":"false"}),this.isModal&&this.setIsModal(),!0!==this.element.classList.contains(tR)&&!0!==this.element.classList.contains(iR)&&!d(this.element.parentElement)){var t=this.isModal?this.dlgContainer.parentElement:this.element.parentElement;this.refElement=this.createElement("div",{className:"e-dlg-ref-element"}),t.insertBefore(this.refElement,this.isModal?this.dlgContainer:this.element)}if(d(this.targetEle)||this.targetEle.appendChild(this.isModal?this.dlgContainer:this.element),this.popupObj=new Za(this.element,{height:this.height,width:this.width,zIndex:this.zIndex,relateTo:this.target,actionOnScroll:"none",enableRtl:this.enableRtl,open:function(o){var a={container:e.isModal?e.dlgContainer:e.element,element:e.element,target:e.target,preventFocus:!1};e.enableResize&&e.resetResizeIcon(),e.trigger("open",a,function(l){l.preventFocus||e.focusContent()})},close:function(o){e.isModal&&N([e.dlgOverlay],"e-fade"),e.unBindEvent(e.element),e.isModal&&(e.dlgContainer.style.display="none"),e.trigger("close",e.closeArgs);var a=document.activeElement;!d(a)&&!d(a.blur)&&a.blur(),!d(e.storeActiveElement)&&!d(e.storeActiveElement.focus)&&e.storeActiveElement.focus()}}),this.positionChange(),this.setEnableRTL(),this.isBlazorServerRender()||(N([this.element],"e-popup-close"),this.isModal&&this.setOverlayZindex()),this.visible){if(this.show(),this.isModal){var n=this.getTargetContainer(this.target);n instanceof Element&&"rtl"===window.getComputedStyle(n).getPropertyValue("direction")&&this.setPopupPosition()}}else this.isModal&&(this.dlgOverlay.style.display="none");this.initialRender=!1},i.prototype.getTargetContainer=function(e){var t=null;if("string"==typeof e)if(e.startsWith("#"))t=document.getElementById(e.substring(1));else if(e.startsWith(".")){var n=document.getElementsByClassName(e.substring(1));t=n.length>0?n[0]:null}else!(e instanceof HTMLElement)&&e!==document.body&&(t=document.querySelector(e));else e instanceof HTMLElement&&(t=e);return t},i.prototype.resetResizeIcon=function(){var e=this.getMinHeight();if(this.targetEle.offsetHeight0&&("function"==typeof this.buttons[e].click&&y.add(r[e],"click",this.buttons[e].click,this),"object"==typeof this.buttons[e].click&&y.add(r[e],"click",this.buttonClickHandler.bind(this,e),this)),!this.isBlazorServerRender()&&!d(this.ftrTemplateContent)&&(this.btnObj[e].appendTo(this.ftrTemplateContent.children[e]),this.buttons[e].isFlat&&this.btnObj[e].element.classList.add("e-flat"),this.primaryButtonEle=this.element.getElementsByClassName("e-primary")[0]))},i.prototype.buttonClickHandler=function(e){this.trigger("buttons["+e+"].click",{})},i.prototype.setContent=function(){this.contentEle=this.createElement("div",{className:"e-dlg-content",id:this.element.id+"_dialog-content"}),ge(this.element,this.headerEle?{"aria-describedby":this.element.id+"_title "+this.element.id+"_dialog-content"}:{"aria-describedby":this.element.id+"_dialog-content"}),this.innerContentElement?this.contentEle.appendChild(this.innerContentElement):(!d(this.content)&&""!==this.content||!this.initialRender)&&(("string"!=typeof this.content||Ne())&&this.content instanceof HTMLElement?this.contentEle.appendChild(this.content):this.setTemplate(this.content,this.contentEle,"content")),d(this.headerContent)?this.element.insertBefore(this.contentEle,this.element.children[0]):this.element.insertBefore(this.contentEle,this.element.children[1]),"auto"===this.height&&(!this.isBlazorServerRender()&&_.isIE&&""===this.element.style.width&&!d(this.width)&&(this.element.style.width=de(this.width)),this.setMaxHeight())},i.prototype.setTemplate=function(e,t,n){var r,o,a;o=t.classList.contains($j)?this.element.id+"header":t.classList.contains(Vm)?this.element.id+"footerTemplate":this.element.id+"content",d(e.outerHTML)?("string"==typeof e||"string"!=typeof e||Ne()&&!this.isStringTemplate)&&("string"==typeof e&&(e=this.sanitizeHelper(e)),this.isVue||"string"!=typeof e?(r=oi(e),a=e):t.innerHTML=e):t.appendChild(e);var l=[];if(!d(r)){for(var u=0,h=r({},this,n,o,!(Ne()&&!this.isStringTemplate&&0===a.indexOf("
Blazor"))||this.isStringTemplate);u/g,"");(this.element.children.length>0||t)&&(this.innerContentElement=document.createDocumentFragment(),[].slice.call(this.element.childNodes).forEach(function(n){8!==n.nodeType&&e.innerContentElement.appendChild(n)}))}},i.prototype.setHeader=function(){this.headerEle?this.headerEle.innerHTML="":this.headerEle=this.createElement("div",{id:this.element.id+"_title",className:$j}),this.createHeaderContent(),this.headerContent.appendChild(this.headerEle),this.setTemplate(this.header,this.headerEle,"header"),ge(this.element,{"aria-describedby":this.element.id+"_title"}),ge(this.element,{"aria-labelledby":this.element.id+"_dialog-header"}),this.element.insertBefore(this.headerContent,this.element.children[0]),this.allowDragging&&!d(this.headerContent)&&this.setAllowDragging()},i.prototype.setFooterTemplate=function(){this.ftrTemplateContent?this.ftrTemplateContent.innerHTML="":this.ftrTemplateContent=this.createElement("div",{className:Vm}),""===this.footerTemplate||d(this.footerTemplate)?this.ftrTemplateContent.innerHTML=this.buttonContent.join(""):this.setTemplate(this.footerTemplate,this.ftrTemplateContent,"footerTemplate"),this.element.appendChild(this.ftrTemplateContent)},i.prototype.createHeaderContent=function(){d(this.headerContent)&&(this.headerContent=this.createElement("div",{id:this.element.id+"_dialog-header",className:tE}))},i.prototype.renderCloseIcon=function(){this.showCloseIcon&&(this.closeIcon=this.createElement("button",{className:Xj,attrs:{type:"button"}}),this.closeIconBtnObj=new Zn({cssClass:"e-flat",iconCss:Gj+" e-icons"}),this.closeIconTitle(),d(this.headerContent)?(this.createHeaderContent(),yo([this.closeIcon],this.headerContent),this.element.insertBefore(this.headerContent,this.element.children[0])):yo([this.closeIcon],this.headerContent),this.closeIconBtnObj.appendTo(this.closeIcon))},i.prototype.closeIconTitle=function(){this.l10n.setLocale(this.locale);var e=this.l10n.getConstant("close");this.closeIcon.setAttribute("title",e),this.closeIcon.setAttribute("aria-label",e)},i.prototype.setCSSClass=function(e){e&&(R([this.element],e.split(" ")),this.isModal&&!d(this.dlgContainer)&&R([this.dlgContainer],e.split(" "))),this.cssClass&&(N([this.element],this.cssClass.split(" ")),this.isModal&&!d(this.dlgContainer)&&N([this.dlgContainer],this.cssClass.split(" ")))},i.prototype.setIsModal=function(){this.dlgContainer=this.createElement("div",{className:"e-dlg-container"}),this.setCSSClass(),this.element.classList.remove(Kj),this.element.parentNode.insertBefore(this.dlgContainer,this.element),this.dlgContainer.appendChild(this.element),N([this.element],Um),this.dlgOverlay=this.createElement("div",{className:"e-dlg-overlay"}),this.dlgOverlay.style.zIndex=(this.zIndex-1).toString(),this.dlgContainer.appendChild(this.dlgOverlay)},i.prototype.getValidFocusNode=function(e){for(var t,n=0;n0||"a"===t.tagName.toLowerCase()&&t.hasAttribute("href"))&&t.tabIndex>-1&&!t.disabled&&!this.disableElement(t,'[disabled],[aria-disabled="true"],[type="hidden"]'))return t;t=null}return t},i.prototype.focusableElements=function(e){if(!d(e)){var n=e.querySelectorAll('input,select,textarea,button,a,[contenteditable="true"],[tabindex]');return this.getValidFocusNode(n)}return null},i.prototype.getAutoFocusNode=function(e){var t=e.querySelector("."+Xj),r=e.querySelectorAll("[autofocus]"),o=this.getValidFocusNode(r);if(Ne()&&(this.primaryButtonEle=this.element.getElementsByClassName("e-primary")[0]),d(o)){if(!d(o=this.focusableElements(this.contentEle)))return o;if(!d(this.primaryButtonEle))return this.element.querySelector(".e-primary")}else t=o;return t},i.prototype.disableElement=function(e,t){var n=e?e.matches||e.webkitMatchesSelector||e.msGetRegionContent:null;if(n)for(;e;e=e.parentNode)if(e instanceof Element&&n.call(e,t))return e;return null},i.prototype.focusContent=function(){var e=this.getAutoFocusNode(this.element),t=d(e)?this.element:e,n=_.userAgent;(n.indexOf("MSIE ")>0||n.indexOf("Trident/")>0)&&this.element.focus(),t.focus(),this.unBindEvent(this.element),this.bindEvent(this.element)},i.prototype.bindEvent=function(e){y.add(e,"keydown",this.keyDown,this)},i.prototype.unBindEvent=function(e){y.remove(e,"keydown",this.keyDown)},i.prototype.updateSanitizeContent=function(){this.isBlazorServerRender()||(this.contentEle.innerHTML=this.sanitizeHelper(this.content))},i.prototype.isBlazorServerRender=function(){return Ne()&&this.isServerRendered},i.prototype.getModuleName=function(){return"dialog"},i.prototype.onPropertyChanged=function(e,t){if(this.element.classList.contains(Bm))for(var n=0,r=Object.keys(e);n0?this.showCloseIcon||""!==this.header&&!d(this.header)?this.showCloseIcon||$(this.closeIcon):($(this.headerContent),this.headerContent=null):(this.renderCloseIcon(),this.wireEvents());break;case"locale":this.showCloseIcon&&this.closeIconTitle();break;case"visible":this.visible?this.show():this.hide();break;case"isModal":this.updateIsModal();break;case"height":be(this.element,{height:de(e.height)}),this.updatePersistData();break;case"width":be(this.element,{width:de(e.width)}),this.updatePersistData();break;case"zIndex":this.popupObj.zIndex=this.zIndex,this.isModal&&this.setOverlayZindex(this.zIndex),this.element.style.zIndex!==this.zIndex.toString()&&(this.calculatezIndex=!1);break;case"cssClass":this.setCSSClass(t.cssClass);break;case"buttons":this.unWireButtonEvents(),this.destroyButtons(),d(this.ftrTemplateContent)||($(this.ftrTemplateContent),this.ftrTemplateContent=null),this.footerTemplate="",this.setButton();break;case"allowDragging":this.allowDragging&&!d(this.headerContent)?this.setAllowDragging():this.dragObj.destroy();break;case"target":this.setTarget(e.target);break;case"position":if(this.checkPositionData(),this.isModal){var a=this.position.X,l=this.position.Y;d(t.position)||(d(t.position.X)||(a=t.position.X),d(t.position.Y)||(l=t.position.Y)),this.dlgContainer.classList.contains("e-dlg-"+a+"-"+l)&&this.dlgContainer.classList.remove("e-dlg-"+a+"-"+l)}this.positionChange(),this.updatePersistData();break;case"enableRtl":this.setEnableRTL();break;case"enableResize":this.setResize(),this.isModelResize=this.enableResize&&this.isModal,this.enableResize&&this.dialogOpen&&this.resetResizeIcon();break;case"minHeight":""!==this.minHeight&&(this.element.style.minHeight=de(this.minHeight))}},i.prototype.setTarget=function(e){this.popupObj.relateTo=e,this.target=e,this.targetEle="string"==typeof this.target?document.querySelector(this.target):this.target,this.dragObj&&(this.dragObj.dragArea=this.targetEle),this.setMaxHeight(),this.isModal&&this.updateIsModal(),this.enableResize&&this.setResize(),d(this.targetEle)||(this.isModal&&!d(this.dlgContainer)?this.targetEle.appendChild(this.dlgContainer):d(this.element)||this.targetEle.appendChild(this.element))},i.prototype.updateIsModal=function(){if(this.element.setAttribute("aria-modal",this.isModal?"true":"false"),this.isModal)d(this.dlgOverlay)&&(this.setIsModal(),this.element.style.top="0px",this.element.style.left="0px",d(this.targetEle)||this.targetEle.appendChild(this.dlgContainer));else{for(R([this.element],Um),R([document.body],[Qr,br]),$(this.dlgOverlay);this.dlgContainer.firstChild;)this.dlgContainer.parentElement.insertBefore(this.dlgContainer.firstChild,this.dlgContainer);this.dlgContainer.parentElement.removeChild(this.dlgContainer)}this.visible&&this.show(),this.positionChange(),this.isModal&&this.dlgOverlay&&y.add(this.dlgOverlay,"click",this.dlgOverlayClickEventHandler,this)},i.prototype.setzIndex=function(e,t){var n=this.isProtectedOnChange;this.isProtectedOnChange=!0;var r=Xa(e);this.zIndex=r>this.zIndex?r:this.zIndex,this.isProtectedOnChange=n,t&&(this.popupObj.zIndex=this.zIndex)},i.prototype.windowResizeHandler=function(){(function v$(s){da=s})(this.targetEle.clientWidth),function y$(s){ha=s}(this.targetEle.clientHeight),this.setMaxHeight()},i.prototype.getPersistData=function(){return this.addOnPersist(["width","height","position"])},i.prototype.removeAllChildren=function(e){for(;e.children[0];)this.removeAllChildren(e.children[0]),e.removeChild(e.children[0])},i.prototype.destroy=function(){if(!this.isDestroyed){var e=[eE,Um,iE,ju,Wm,Zj],t=["role","aria-modal","aria-labelledby","aria-describedby","aria-grabbed","tabindex","style"];R([this.targetEle],[Qr,br]),!d(this.element)&&this.element.classList.contains(Wm)&&R([document.body],[Qr,br]),this.isModal&&R([d(this.targetEle)?document.body:this.targetEle],br),this.unWireEvents(),this.unWireButtonEvents(),this.destroyButtons(),d(this.closeIconBtnObj)||this.closeIconBtnObj.destroy(),d(this.dragObj)||this.dragObj.destroy(),!d(this.popupObj.element)&&this.popupObj.element.classList.contains("e-popup")&&this.popupObj.destroy(),R([this.element],e),!d(this.cssClass)&&""!==this.cssClass&&R([this.element],this.cssClass.split(" ")),!d(this.refElement)&&!d(this.refElement.parentElement)&&(this.refElement.parentElement.insertBefore(this.isModal?this.dlgContainer:this.element,this.refElement),$(this.refElement),this.refElement=void 0),this.isModal&&($(this.dlgOverlay),this.dlgContainer.parentNode.insertBefore(this.element,this.dlgContainer),$(this.dlgContainer)),this.element.innerHTML=this.clonedEle.innerHTML;for(var n=0;n0&&""===this.footerTemplate&&this.ftrTemplateContent)for(var e=0;e=0;a--)(o=s[a])&&(r=(n<3?o(r):n>3?o(i,e,r):o(i,e))||r);return n>3&&r&&Object.defineProperty(i,e,r),r},sE="e-tooltip",cR="e-icons",uR="e-tooltip-close",rE="e-tooltip-wrap",hR="e-tip-content",Ru="e-arrow-tip",dR="e-arrow-tip-outer",Ym="e-arrow-tip-inner",op="e-tip-bottom",oE="e-tip-top",pR="e-tip-left",aE="e-tip-right",lE="e-popup",ap="e-popup-open",cE="e-popup-close",Qm="e-lib",fR="e-tooltip-popup-container",H$=function(s){function i(){return null!==s&&s.apply(this,arguments)||this}return rR(i,s),ai([m({effect:"FadeIn",duration:150,delay:0})],i.prototype,"open",void 0),ai([m({effect:"FadeOut",duration:150,delay:0})],i.prototype,"close",void 0),i}(Lt),Pu=function(s){function i(e,t){var n=s.call(this,e,t)||this;return n.mouseMoveEvent=null,n.mouseMoveTarget=null,n.containerElement=null,n.isBodyContainer=!0,n}return rR(i,s),i.prototype.initialize=function(){this.formatPosition(),N([this.element],sE)},i.prototype.formatPosition=function(){var e,t;this.position&&(0===this.position.indexOf("Top")||0===this.position.indexOf("Bottom")?(e=this.position.split(/(?=[A-Z])/),this.tooltipPositionY=e[0],this.tooltipPositionX=e[1]):(t=this.position.split(/(?=[A-Z])/),this.tooltipPositionX=t[0],this.tooltipPositionY=t[1]))},i.prototype.renderArrow=function(){this.setTipClass(this.position);var e=this.createElement("div",{className:Ru+" "+this.tipClass});e.appendChild(this.createElement("div",{className:dR+" "+this.tipClass})),e.appendChild(this.createElement("div",{className:Ym+" "+this.tipClass})),this.tooltipEle.appendChild(e)},i.prototype.setTipClass=function(e){this.tipClass=0===e.indexOf("Right")?pR:0===e.indexOf("Bottom")?oE:0===e.indexOf("Left")?aE:op},i.prototype.renderPopup=function(e){var t=this.mouseTrail?{top:0,left:0}:this.getTooltipPosition(e);this.tooltipEle.classList.remove(Qm),this.popupObj=new Za(this.tooltipEle,{height:this.height,width:this.width,position:{X:t.left,Y:t.top},enableRtl:this.enableRtl,open:this.openPopupHandler.bind(this),close:this.closePopupHandler.bind(this)})},i.prototype.getScalingFactor=function(e){if(!e)return{x:1,y:1};var t={x:1,y:1},n=e.closest('[style*="transform: scale"]');if(n&&n!==this.tooltipEle&&n.contains(this.tooltipEle)){var a=window.getComputedStyle(n).getPropertyValue("transform").match(/matrix\(([^)]+)\)/)[1].split(",").map(parseFloat);t.x=a[0],t.y=a[3]}return t},i.prototype.getTooltipPosition=function(e){this.tooltipEle.style.display="block";var t=this.element.closest('[style*="zoom"]');t&&(t.contains(this.tooltipEle)||(this.tooltipEle.style.zoom=getComputedStyle(t).zoom));var n=Vn(e,this.tooltipPositionX,this.tooltipPositionY,!this.isBodyContainer,this.isBodyContainer?null:this.containerElement.getBoundingClientRect()),r=this.getScalingFactor(e),o=this.calculateTooltipOffset(this.position,r.x,r.y),a=this.calculateElementPosition(n,o),u=this.collisionFlipFit(e,a[0],a[1]);return u.left=u.left/r.x,u.top=u.top/r.y,this.tooltipEle.style.display="",u},i.prototype.windowResize=function(){this.reposition(this.findTarget())},i.prototype.reposition=function(e){if(this.popupObj&&e){var t=this.getTooltipPosition(e);this.popupObj.position={X:t.left,Y:t.top},this.popupObj.dataBind()}},i.prototype.openPopupHandler=function(){!this.mouseTrail&&this.needTemplateReposition()&&this.reposition(this.findTarget()),this.trigger("afterOpen",this.tooltipEventArgs),this.tooltipEventArgs=null},i.prototype.closePopupHandler=function(){this.isReact&&!("Click"===this.opensOn||"function"==typeof this.content)&&this.clearTemplate(["content"]),this.clear();var e={type:this.tooltipEventArgs.event?this.tooltipEventArgs.event.type:null,cancel:!1,target:this.tooltipEventArgs.target,event:this.tooltipEventArgs.event?this.tooltipEventArgs.event:null,element:this.tooltipEle,isInteracted:!d(this.tooltipEventArgs.event)};this.trigger("afterClose",e),e=null},i.prototype.calculateTooltipOffset=function(e,t,n){void 0===t&&(t=1),void 0===n&&(n=1);var o,a,l,c,u,h,p,f,r={top:0,left:0};if(1!==t||1!==n){var g=this.tooltipEle.getBoundingClientRect(),v=void 0;l=Math.round(g.width),c=Math.round(g.height),(u=S("."+Ru,this.tooltipEle))&&(v=u.getBoundingClientRect()),o=u?Math.round(v.width):0,a=u?Math.round(v.height):0,h=this.showTipPointer?0:8,p=a/2+2+(c-this.tooltipEle.clientHeight*n),f=o/2+2+(l-this.tooltipEle.clientWidth*t)}else l=this.tooltipEle.offsetWidth,c=this.tooltipEle.offsetHeight,u=S("."+Ru,this.tooltipEle),h=this.showTipPointer?0:8,p=(a=u?u.offsetHeight:0)/2+2+(this.tooltipEle.offsetHeight-this.tooltipEle.clientHeight),f=(o=u?u.offsetWidth:0)/2+2+(this.tooltipEle.offsetWidth-this.tooltipEle.clientWidth);switch(this.mouseTrail&&(h+=2),e){case"RightTop":r.left+=o+h,r.top-=c-p;break;case"RightCenter":r.left+=o+h,r.top-=c/2;break;case"RightBottom":r.left+=o+h,r.top-=p;break;case"BottomRight":r.top+=a+h,r.left-=f;break;case"BottomCenter":r.top+=a+h,r.left-=l/2;break;case"BottomLeft":r.top+=a+h,r.left-=l-f;break;case"LeftBottom":r.left-=o+l+h,r.top-=p;break;case"LeftCenter":r.left-=o+l+h,r.top-=c/2;break;case"LeftTop":r.left-=o+l+h,r.top-=c-p;break;case"TopLeft":r.top-=c+a+h,r.left-=l-f;break;case"TopRight":r.top-=c+a+h,r.left-=f;break;default:r.top-=c+a+h,r.left-=l/2}return r.left+=this.offsetX,r.top+=this.offsetY,r},i.prototype.updateTipPosition=function(e){var t=se("."+Ru+",."+dR+",."+Ym,this.tooltipEle);R(t,[op,oE,pR,aE]),this.setTipClass(e),N(t,this.tipClass)},i.prototype.adjustArrow=function(e,t,n,r){var o=S("."+Ru,this.tooltipEle);if(!1!==this.showTipPointer&&null!==o){var a,l;this.updateTipPosition(t),this.tooltipEle.style.display="block";var g,c=this.tooltipEle.clientWidth,u=this.tooltipEle.clientHeight,h=S("."+Ym,this.tooltipEle),p=o.offsetWidth,f=o.offsetHeight;this.tooltipEle.style.display="",this.tipClass===op||this.tipClass===oE?(this.tipClass===op?(l="99.9%",h.style.top="-"+(f-2)+"px"):(l=-(f-1)+"px",h.style.top="-"+(f-6)+"px"),e&&(a=(g="Center"!==n||c>e.offsetWidth||this.mouseTrail)&&"Left"===n||!g&&"End"===this.tipPointerPosition?c-p-2+"px":g&&"Right"===n||!g&&"Start"===this.tipPointerPosition?"2px":!g||"End"!==this.tipPointerPosition&&"Start"!==this.tipPointerPosition?c/2-p/2+"px":"End"===this.tipPointerPosition?e.offsetWidth+(this.tooltipEle.offsetWidth-e.offsetWidth)/2-p/2-2+"px":(this.tooltipEle.offsetWidth-e.offsetWidth)/2-p/2+2+"px")):(this.tipClass===aE?(a="99.9%",h.style.left="-"+(p-2)+"px"):(a=-(p-1)+"px",h.style.left=p-2-p+"px"),l=(g="Center"!==r||u>e.offsetHeight||this.mouseTrail)&&"Top"===r||!g&&"End"===this.tipPointerPosition?u-f-2+"px":g&&"Bottom"===r||!g&&"Start"===this.tipPointerPosition?"2px":u/2-f/2+"px"),o.style.top=l,o.style.left=a}},i.prototype.renderContent=function(e){var t=this,n=S("."+hR,this.tooltipEle);if(this.cssClass&&N([this.tooltipEle],this.cssClass.split(" ")),e&&!d(e.getAttribute("title"))&&(e.setAttribute("data-content",e.getAttribute("title")),e.removeAttribute("title")),d(this.content))e&&!d(e.getAttribute("data-content"))&&(n.innerHTML=e.getAttribute("data-content"));else if(n.innerHTML="",this.content instanceof HTMLElement)n.appendChild(this.content);else if("string"==typeof this.content)this.isAngular?this.setProperties({content:Qt.sanitize(this.content)},!0):this.content=this.enableHtmlSanitizer?Qt.sanitize(this.content):this.content,this.enableHtmlParse?(o=oi(this.content)({},this,"content",this.element.id+"content",void 0,void 0,n,this.root))&&et(o,n):n.textContent=this.content;else{var o;(o=oi(this.content)({},this,"content",this.element.id+"content",void 0,void 0,n))&&(this.isAngular&&setTimeout(function(){t.reposition(e)},1),et(o,n)),this.renderReactTemplates()}},i.prototype.renderCloseIcon=function(){if(this.isSticky){var t=this.createElement("div",{className:cR+" "+uR});this.tooltipEle.appendChild(t),y.add(t,_.touchStartEvent,this.onStickyClose,this)}else{var e=this.tooltipEle.querySelector("."+cR+"."+uR);e&&Qe(e)}},i.prototype.addDescribedBy=function(e,t){var n=(e.getAttribute("aria-describedby")||"").split(/\s+/);n.indexOf(t)<0&&n.push(t),ge(e,{"aria-describedby":n.join(" ").trim(),"data-tooltip-id":t})},i.prototype.removeDescribedBy=function(e){var t=e.getAttribute("data-tooltip-id"),n=(e.getAttribute("aria-describedby")||"").split(/\s+/),r=n.indexOf(t);-1!==r&&n.splice(r,1),e.removeAttribute("data-tooltip-id");var o=n.join(" ").trim();o?e.setAttribute("aria-describedby",o):e.removeAttribute("aria-describedby")},i.prototype.tapHoldHandler=function(e){clearTimeout(this.autoCloseTimer),this.targetHover(e.originalEvent)},i.prototype.touchEndHandler=function(){var e=this;this.isSticky||(this.autoCloseTimer=setTimeout(function(){e.close()},1500))},i.prototype.targetClick=function(e){var t;!d(t=this.target?j(e.target,this.target):this.element)&&(null===t.getAttribute("data-tooltip-id")?this.targetHover(e):this.isSticky||this.hideTooltip(this.animation.close,e,t))},i.prototype.targetHover=function(e){var t;if(!(d(t=this.target?j(e.target,this.target):this.element)||null!==t.getAttribute("data-tooltip-id")&&0===this.closeDelay)){for(var r=0,o=[].slice.call(se('[data-tooltip-id= "'+this.ctrlId+'_content"]',document));r0?this.showTimer=setTimeout(function(){o.mouseTrail&&y.add(t,"mousemove touchstart mouseenter",o.onMouseMove,o),o.popupObj&&(o.popupObj.show(a,t),o.mouseMoveEvent&&o.mouseTrail&&o.onMouseMove(o.mouseMoveEvent))},this.openDelay):this.popupObj&&this.popupObj.show(a,t)}r&&this.wireMouseEvents(r,t)},i.prototype.needTemplateReposition=function(){return!d(this.viewContainerRef)&&"string"!=typeof this.viewContainerRef||this.isReact},i.prototype.checkCollision=function(e,t,n){var r={left:t,top:n,position:this.position,horizontal:this.tooltipPositionX,vertical:this.tooltipPositionY},o=Ga(this.tooltipEle,this.checkCollideTarget(),t,n);return o.length>0&&(r.horizontal=o.indexOf("left")>=0?"Right":o.indexOf("right")>=0?"Left":this.tooltipPositionX,r.vertical=o.indexOf("top")>=0?"Bottom":o.indexOf("bottom")>=0?"Top":this.tooltipPositionY),r},i.prototype.calculateElementPosition=function(e,t){return[this.isBodyContainer?e.left+t.left:e.left-this.containerElement.getBoundingClientRect().left+t.left+window.pageXOffset+this.containerElement.scrollLeft,this.isBodyContainer?e.top+t.top:e.top-this.containerElement.getBoundingClientRect().top+t.top+window.pageYOffset+this.containerElement.scrollTop]},i.prototype.collisionFlipFit=function(e,t,n){var r=this.checkCollision(e,t,n),o=r.position;if(this.tooltipPositionY!==r.vertical&&(o=0===this.position.indexOf("Bottom")||0===this.position.indexOf("Top")?r.vertical+this.tooltipPositionX:this.tooltipPositionX+r.vertical),this.tooltipPositionX!==r.horizontal&&(0===o.indexOf("Left")&&(r.vertical="LeftTop"===o||"LeftCenter"===o?"Top":"Bottom",o=r.vertical+"Left"),0===o.indexOf("Right")&&(r.vertical="RightTop"===o||"RightCenter"===o?"Top":"Bottom",o=r.vertical+"Right"),r.horizontal=this.tooltipPositionX),this.tooltipEventArgs={type:null,cancel:!1,target:e,event:null,element:this.tooltipEle,collidedPosition:o},this.trigger("beforeCollision",this.tooltipEventArgs),this.tooltipEventArgs.cancel)o=this.position;else{var a=r.vertical,l=r.horizontal;if(r.position!==o){var c=Vn(e,l,a,!this.isBodyContainer,this.isBodyContainer?null:this.containerElement.getBoundingClientRect());this.adjustArrow(e,o,l,a);var u=this.getScalingFactor(e),h=this.calculateTooltipOffset(o,u.x,u.y);h.top-=this.getOffSetPosition("TopBottom",o,this.offsetY),h.left-=this.getOffSetPosition("RightLeft",o,this.offsetX),r.position=o;var p=this.calculateElementPosition(c,h);r.left=p[0],r.top=p[1]}else this.adjustArrow(e,o,l,a)}var f={left:r.left,top:r.top},g=this.isBodyContainer?xI(this.tooltipEle,this.checkCollideTarget(),{X:!0,Y:this.windowCollision},f):f;this.tooltipEle.style.display="block";var v=S("."+Ru,this.tooltipEle);if(this.showTipPointer&&null!=v&&(0===o.indexOf("Bottom")||0===o.indexOf("Top"))){var b=parseInt(v.style.left,10)-(g.left-r.left);b<0?b=0:b+v.offsetWidth>this.tooltipEle.clientWidth&&(b=this.tooltipEle.clientWidth-v.offsetWidth),v.style.left=b.toString()+"px"}return this.tooltipEle.style.display="",f.left=g.left,f.top=g.top,f},i.prototype.getOffSetPosition=function(e,t,n){return-1!==e.indexOf(this.position.split(/(?=[A-Z])/)[0])&&-1!==e.indexOf(t.split(/(?=[A-Z])/)[0])?2*n:0},i.prototype.checkCollideTarget=function(){return!this.windowCollision&&this.target?this.element:null},i.prototype.hideTooltip=function(e,t,n){var r=this;this.closeDelay>0?(clearTimeout(this.hideTimer),clearTimeout(this.showTimer),this.hideTimer=setTimeout(function(){r.closeDelay&&r.tooltipEle&&r.isTooltipOpen||r.tooltipHide(e,t,n)},this.closeDelay)):this.tooltipHide(e,t,n)},i.prototype.tooltipHide=function(e,t,n){var o,r=this;o=t?this.target?n||t.target:this.element:S('[data-tooltip-id= "'+this.ctrlId+'_content"]',document),this.tooltipEventArgs={type:t?t.type:null,cancel:!1,target:o,event:t||null,element:this.tooltipEle,isInteracted:!d(t)},this.trigger("beforeClose",this.tooltipEventArgs,function(a){a.cancel?r.isHidden=!1:(r.mouseMoveBeforeRemove(),r.popupHide(e,o,t))})},i.prototype.popupHide=function(e,t,n){t&&n&&this.restoreElement(t),this.isHidden=!0;var r={name:this.animation.close.effect,duration:e.duration,delay:e.delay,timingFunction:"easeIn"};"None"===e.effect&&(r=void 0),this.popupObj&&this.popupObj.hide(r)},i.prototype.restoreElement=function(e){this.unwireMouseEvents(e),d(e.getAttribute("data-content"))||(e.setAttribute("title",e.getAttribute("data-content")),e.removeAttribute("data-content")),this.removeDescribedBy(e)},i.prototype.clear=function(){var e=this.findTarget();e&&this.restoreElement(e),this.tooltipEle&&(R([this.tooltipEle],cE),N([this.tooltipEle],ap)),this.isHidden&&(this.popupObj&&this.popupObj.destroy(),this.tooltipEle&&Qe(this.tooltipEle),this.tooltipEle=null,this.popupObj=null)},i.prototype.tooltipHover=function(){this.tooltipEle&&(this.isTooltipOpen=!0)},i.prototype.tooltipMouseOut=function(e){this.isTooltipOpen=!1,this.hideTooltip(this.animation.close,e,this.findTarget())},i.prototype.onMouseOut=function(e){var t=e.relatedTarget;if(t&&!this.mouseTrail){var n=j(t,"."+rE+"."+Qm+"."+lE);n?y.add(n,"mouseleave",this.tooltipElementMouseOut,this):(this.hideTooltip(this.animation.close,e,this.findTarget()),0===this.closeDelay&&("None"===this.animation.close.effect||this.isReact&&"string"!=typeof this.content)&&this.clear())}else this.hideTooltip(this.animation.close,e,this.findTarget()),this.clear();this.popupObj&&!this.popupObj.element.classList.contains(ap)&&this.clear()},i.prototype.tooltipElementMouseOut=function(e){this.hideTooltip(this.animation.close,e,this.findTarget()),y.remove(this.element,"mouseleave",this.tooltipElementMouseOut),this.clear()},i.prototype.onStickyClose=function(){this.close()},i.prototype.onMouseMove=function(e){var t=0,n=0;e.type.indexOf("touch")>-1?(e.preventDefault(),t=e.touches[0].pageX,n=e.touches[0].pageY):(t=e.pageX,n=e.pageY),ds.stop(this.tooltipEle),R([this.tooltipEle],cE),N([this.tooltipEle],ap),this.adjustArrow(e.target,this.position,this.tooltipPositionX,this.tooltipPositionY);var r=this.getScalingFactor(e.target),o=this.calculateTooltipOffset(this.position,r.x,r.y),c=this.checkCollision(e.target,t+o.left+this.offsetX,n+o.top+this.offsetY);if(this.tooltipPositionX!==c.horizontal||this.tooltipPositionY!==c.vertical){var u=0===this.position.indexOf("Bottom")||0===this.position.indexOf("Top")?c.vertical+c.horizontal:c.horizontal+c.vertical;c.position=u,this.adjustArrow(e.target,c.position,c.horizontal,c.vertical);var h=this.calculateTooltipOffset(c.position,r.x,r.y);c.left=t+h.left-this.offsetX,c.top=n+h.top-this.offsetY}this.tooltipEle.style.left=c.left+"px",this.tooltipEle.style.top=c.top+"px"},i.prototype.keyDown=function(e){this.tooltipEle&&27===e.keyCode&&this.close()},i.prototype.touchEnd=function(e){this.tooltipEle&&null===j(e.target,"."+sE)&&!this.isSticky&&this.close()},i.prototype.scrollHandler=function(e){this.tooltipEle&&!this.isSticky&&!j(e.target,"."+rE+"."+Qm+"."+lE)&&!this.isSticky&&this.close()},i.prototype.render=function(){this.initialize(),this.wireEvents(this.opensOn),this.renderComplete()},i.prototype.preRender=function(){this.tipClass=op,this.tooltipPositionX="Center",this.tooltipPositionY="Top",this.isHidden=!0},i.prototype.wireEvents=function(e){for(var n=0,r=this.getTriggerList(e);n0)for(var t=0,n=e;t0)for(var t=0,n=e;t',A=J.children[0].placeholder}return A}function q(I,A,J){!d(J)&&""!==J&&R(A,J.split(" ")),!d(I)&&""!==I&&N(A,I.split(" "))}function ye(I,A,J){if("multiselect"===J||function fy(I){if(!I)return!1;for(var A=I;A&&A!==document.body;){if("none"===window.getComputedStyle(A).display)return!1;A=A.parentElement}return!0}(I)){var oe="multiselect"===J?I:I.clientWidth-parseInt(getComputedStyle(I,null).getPropertyValue("padding-left"),10);!d(A)&&!d(A.getElementsByClassName("e-float-text-content")[0])&&(A.getElementsByClassName("e-float-text-content")[0].classList.contains("e-float-text-overflow")&&A.getElementsByClassName("e-float-text-content")[0].classList.remove("e-float-text-overflow"),(oe0)for(var Ce=0;Ce0)for(Ce=0;Ce-1)if("class"===me){var Ce=this.getInputValidClassList(I[""+me]);""!==Ce&&N([A],Ce.split(" "))}else if("style"===me){var Rt=A.getAttribute(me);Rt=d(Rt)?I[""+me]:Rt+I[""+me],A.setAttribute(me,Rt)}else A.setAttribute(me,I[""+me])}},s.isBlank=function LK(I){return!I||/^\s*$/.test(I)}}(ae||(ae={})),new RegExp("^(-)?(\\d*)$"),new RegExp("^[A-Za-z0-9._%+-]{1,}@[A-Za-z0-9._%+-]{1,}([.]{1}[a-zA-Z0-9]{2,}|[.]{1}[a-zA-Z0-9]{2,4}[.]{1}[a-zA-Z0-9]{2,4})$"),new RegExp("^([0-9]{4})-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])$"),new RegExp("^[0-9]*$"),new RegExp("^[+]?[0-9]{9,13}$"),new RegExp("^\\d{13,16}$");var WZ=function(){var s=function(i,e){return(s=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,n){t.__proto__=n}||function(t,n){for(var r in n)n.hasOwnProperty(r)&&(t[r]=n[r])})(i,e)};return function(i,e){function t(){this.constructor=i}s(i,e),i.prototype=null===e?Object.create(e):(t.prototype=e.prototype,new t)}}(),qP=function(s,i,e,t){var o,n=arguments.length,r=n<3?i:null===t?t=Object.getOwnPropertyDescriptor(i,e):t;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)r=Reflect.decorate(s,i,e,t);else for(var a=s.length-1;a>=0;a--)(o=s[a])&&(r=(n<3?o(r):n>3?o(i,e,r):o(i,e))||r);return n>3&&r&&Object.defineProperty(i,e,r),r},nl="e-rtl",sl="e-overlay",Ip="e-nav-arrow",Ep="e-nav-right-arrow",Mv="e-nav-left-arrow",$l="e-scroll-nav",FE="e-scroll-right-nav",$P="e-scroll-left-nav",GP="e-scroll-device",Cv="e-scroll-overlay",HE="e-scroll-right-overlay",BE="e-scroll-left-overlay",Iv=function(s){function i(e,t){return s.call(this,e,t)||this}return WZ(i,s),i.prototype.preRender=function(){this.browser=_.info.name,this.browserCheck="mozilla"===this.browser,this.isDevice=_.isDevice,this.customStep=!0;var e=this.element;this.ieCheck="edge"===this.browser||"msie"===this.browser,this.initialize(),""===e.id&&(e.id=Bt("hscroll"),this.uniqueId=!0),e.style.display="block",this.enableRtl&&e.classList.add(nl)},i.prototype.render=function(){this.touchModule=new fs(this.element,{scroll:this.touchHandler.bind(this),swipe:this.swipeHandler.bind(this)}),y.add(this.scrollEle,"scroll",this.scrollHandler,this),this.isDevice?(this.element.classList.add(GP),this.createOverlay(this.element)):this.createNavIcon(this.element),this.setScrollState()},i.prototype.setScrollState=function(){d(this.scrollStep)||this.scrollStep<0?(this.scrollStep=this.scrollEle.offsetWidth,this.customStep=!1):this.customStep=!0},i.prototype.initialize=function(){var e=this.createElement("div",{className:"e-hscroll-content"}),t=this.createElement("div",{className:"e-hscroll-bar"});t.setAttribute("tabindex","-1");for(var n=this.element,o=0,a=[].slice.call(n.children);o0&&($(t[0]),d(t[1])||$(t[1])),y.remove(this.scrollEle,"scroll",this.scrollHandler),this.touchModule.destroy(),this.touchModule=null,s.prototype.destroy.call(this)},i.prototype.disable=function(e){var t=se(".e-scroll-nav:not(."+sl+")",this.element);e?this.element.classList.add(sl):this.element.classList.remove(sl),[].slice.call(t).forEach(function(n){n.setAttribute("tabindex",e?"-1":"0")})},i.prototype.createOverlay=function(e){var t=e.id.concat("_nav"),n=this.createElement("div",{className:Cv+" "+HE}),r="e-"+e.id.concat("_nav "+$l+" "+FE),o=this.createElement("div",{id:t.concat("_right"),className:r}),a=this.createElement("div",{className:Ep+" "+Ip+" e-icons"});o.appendChild(a);var l=this.createElement("div",{className:Cv+" "+BE});this.ieCheck&&o.classList.add("e-ie-align"),e.appendChild(n),e.appendChild(o),e.insertBefore(l,e.firstChild),this.eventBinding([o])},i.prototype.createNavIcon=function(e){var t=e.id.concat("_nav"),n="e-"+e.id.concat("_nav "+$l+" "+FE),r={role:"button",id:t.concat("_right"),"aria-label":"Scroll right"},o=this.createElement("div",{className:n,attrs:r});o.setAttribute("aria-disabled","false");var a=this.createElement("div",{className:Ep+" "+Ip+" e-icons"}),l="e-"+e.id.concat("_nav "+$l+" "+$P),c={role:"button",id:t.concat("_left"),"aria-label":"Scroll left"},u=this.createElement("div",{className:l+" "+sl,attrs:c});u.setAttribute("aria-disabled","true");var h=this.createElement("div",{className:Mv+" "+Ip+" e-icons"});u.appendChild(h),o.appendChild(a),e.appendChild(o),e.insertBefore(u,e.firstChild),this.ieCheck&&(o.classList.add("e-ie-align"),u.classList.add("e-ie-align")),this.eventBinding([o,u])},i.prototype.onKeyPress=function(e){var t=this;"Enter"===e.key&&(this.keyTimer=window.setTimeout(function(){t.keyTimeout=!0,t.eleScrolling(10,e.target,!0)},100))},i.prototype.onKeyUp=function(e){"Enter"===e.key&&(this.keyTimeout?this.keyTimeout=!1:e.target.click(),clearTimeout(this.keyTimer))},i.prototype.eventBinding=function(e){var t=this;[].slice.call(e).forEach(function(n){new fs(n,{tapHold:t.tabHoldHandler.bind(t),tapHoldThreshold:500}),n.addEventListener("keydown",t.onKeyPress.bind(t)),n.addEventListener("keyup",t.onKeyUp.bind(t)),n.addEventListener("mouseup",t.repeatScroll.bind(t)),n.addEventListener("touchend",t.repeatScroll.bind(t)),n.addEventListener("contextmenu",function(r){r.preventDefault()}),y.add(n,"click",t.clickEventHandler,t)})},i.prototype.repeatScroll=function(){clearInterval(this.timeout)},i.prototype.tabHoldHandler=function(e){var t=this,n=e.originalEvent.target;n=this.contains(n,$l)?n.firstElementChild:n,this.timeout=window.setInterval(function(){t.eleScrolling(10,n,!0)},50)},i.prototype.contains=function(e,t){return e.classList.contains(t)},i.prototype.eleScrolling=function(e,t,n){var r=this.element,o=t.classList;o.contains($l)&&(o=t.querySelector("."+Ip).classList),this.contains(r,nl)&&this.browserCheck&&(e=-e),!this.contains(r,nl)||this.browserCheck||this.ieCheck?o.contains(Ep)?this.frameScrollRequest(e,"add",n):this.frameScrollRequest(e,"",n):o.contains(Mv)?this.frameScrollRequest(e,"add",n):this.frameScrollRequest(e,"",n)},i.prototype.clickEventHandler=function(e){this.eleScrolling(this.scrollStep,e.target,!1)},i.prototype.swipeHandler=function(e){var n,t=this.scrollEle;n=e.velocity<=1?e.distanceX/(10*e.velocity):e.distanceX/e.velocity;var r=.5,o=function(){var a=Math.sin(r);a<=0?window.cancelAnimationFrame(a):("Left"===e.swipeDirection?t.scrollLeft+=n*a:"Right"===e.swipeDirection&&(t.scrollLeft-=n*a),r-=.5,window.requestAnimationFrame(o))};o()},i.prototype.scrollUpdating=function(e,t){"add"===t?this.scrollEle.scrollLeft+=e:this.scrollEle.scrollLeft-=e,this.enableRtl&&this.scrollEle.scrollLeft>0&&(this.scrollEle.scrollLeft=0)},i.prototype.frameScrollRequest=function(e,t,n){var r=this;if(n)this.scrollUpdating(e,t);else{this.customStep||[].slice.call(se("."+Cv,this.element)).forEach(function(l){e-=l.offsetWidth});var a=function(){var l,c;r.contains(r.element,nl)&&r.browserCheck?(l=-e,c=-10):(l=e,c=10),l<10?window.cancelAnimationFrame(c):(r.scrollUpdating(c,t),e-=c,window.requestAnimationFrame(a))};a()}},i.prototype.touchHandler=function(e){var t=this.scrollEle,n=e.distanceX;this.ieCheck&&this.contains(this.element,nl)&&(n=-n),"Left"===e.scrollDirection?t.scrollLeft=t.scrollLeft+n:"Right"===e.scrollDirection&&(t.scrollLeft=t.scrollLeft-n)},i.prototype.arrowDisabling=function(e,t){if(this.isDevice){var r=(d(e)?t:e).querySelector("."+Ip);d(e)?qn(r,[Ep],[Mv]):qn(r,[Mv],[Ep])}else e&&t&&(e.classList.add(sl),e.setAttribute("aria-disabled","true"),e.removeAttribute("tabindex"),t.classList.remove(sl),t.setAttribute("aria-disabled","false"),t.setAttribute("tabindex","0"));this.repeatScroll()},i.prototype.scrollHandler=function(e){var t=e.target,n=t.offsetWidth,o=this.element.querySelector("."+$P),a=this.element.querySelector("."+FE),l=this.element.querySelector("."+BE),c=this.element.querySelector("."+HE),u=t.scrollLeft;if(u<=0&&(u=-u),this.isDevice&&(this.enableRtl&&!(this.browserCheck||this.ieCheck)&&(l=this.element.querySelector("."+HE),c=this.element.querySelector("."+BE)),l.style.width=u<40?u+"px":"40px",c.style.width=t.scrollWidth-Math.ceil(n+u)<40?t.scrollWidth-Math.ceil(n+u)+"px":"40px"),0===u)this.arrowDisabling(o,a);else if(Math.ceil(n+u+.1)>=t.scrollWidth)this.arrowDisabling(a,o);else{var h=this.element.querySelector("."+$l+"."+sl);h&&(h.classList.remove(sl),h.setAttribute("aria-disabled","false"),h.setAttribute("tabindex","0"))}},i.prototype.onPropertyChanged=function(e,t){for(var n=0,r=Object.keys(e);n=0;a--)(o=s[a])&&(r=(n<3?o(r):n>3?o(i,e,r):o(i,e))||r);return n>3&&r&&Object.defineProperty(i,e,r),r},Ev="e-rtl",rl="e-overlay",Dp="e-nav-arrow",Dv="e-nav-up-arrow",Sp="e-nav-down-arrow",Gl="e-scroll-nav",KP="e-scroll-up-nav",VE="e-scroll-down-nav",JP="e-scroll-device",Sv="e-scroll-overlay",ez="e-scroll-up-overlay",tz="e-scroll-down-overlay",$u=function(s){function i(e,t){return s.call(this,e,t)||this}return $Z(i,s),i.prototype.preRender=function(){this.browser=_.info.name,this.browserCheck="mozilla"===this.browser,this.isDevice=_.isDevice,this.customStep=!0;var e=this.element;this.ieCheck="edge"===this.browser||"msie"===this.browser,this.initialize(),""===e.id&&(e.id=Bt("vscroll"),this.uniqueId=!0),e.style.display="block",this.enableRtl&&e.classList.add(Ev)},i.prototype.render=function(){this.touchModule=new fs(this.element,{scroll:this.touchHandler.bind(this),swipe:this.swipeHandler.bind(this)}),y.add(this.scrollEle,"scroll",this.scrollEventHandler,this),this.isDevice?(this.element.classList.add(JP),this.createOverlayElement(this.element)):this.createNavIcon(this.element),this.setScrollState(),y.add(this.element,"wheel",this.wheelEventHandler,this)},i.prototype.setScrollState=function(){d(this.scrollStep)||this.scrollStep<0?(this.scrollStep=this.scrollEle.offsetHeight,this.customStep=!1):this.customStep=!0},i.prototype.initialize=function(){var e=_t("div",{className:"e-vscroll-content"}),t=_t("div",{className:"e-vscroll-bar"});t.setAttribute("tabindex","-1");for(var n=this.element,o=0,a=[].slice.call(n.children);o0&&($(t[0]),d(t[1])||$(t[1])),y.remove(this.scrollEle,"scroll",this.scrollEventHandler),this.touchModule.destroy(),this.touchModule=null,s.prototype.destroy.call(this)},i.prototype.disable=function(e){var t=se(".e-scroll-nav:not(."+rl+")",this.element);e?this.element.classList.add(rl):this.element.classList.remove(rl),[].slice.call(t).forEach(function(n){n.setAttribute("tabindex",e?"-1":"0")})},i.prototype.createOverlayElement=function(e){var t=e.id.concat("_nav"),n=_t("div",{className:Sv+" "+tz}),r="e-"+e.id.concat("_nav "+Gl+" "+VE),o=_t("div",{id:t.concat("down"),className:r}),a=_t("div",{className:Sp+" "+Dp+" e-icons"});o.appendChild(a);var l=_t("div",{className:Sv+" "+ez});this.ieCheck&&o.classList.add("e-ie-align"),e.appendChild(n),e.appendChild(o),e.insertBefore(l,e.firstChild),this.eventBinding([o])},i.prototype.createNavIcon=function(e){var t=e.id.concat("_nav"),n="e-"+e.id.concat("_nav "+Gl+" "+VE),r=_t("div",{id:t.concat("_down"),className:n});r.setAttribute("aria-disabled","false");var o=_t("div",{className:Sp+" "+Dp+" e-icons"}),a="e-"+e.id.concat("_nav "+Gl+" "+KP),l=_t("div",{id:t.concat("_up"),className:a+" "+rl});l.setAttribute("aria-disabled","true");var c=_t("div",{className:Dv+" "+Dp+" e-icons"});l.appendChild(c),r.appendChild(o),r.setAttribute("tabindex","0"),e.appendChild(r),e.insertBefore(l,e.firstChild),this.ieCheck&&(r.classList.add("e-ie-align"),l.classList.add("e-ie-align")),this.eventBinding([r,l])},i.prototype.onKeyPress=function(e){var t=this;"Enter"===e.key&&(this.keyTimer=window.setTimeout(function(){t.keyTimeout=!0,t.eleScrolling(10,e.target,!0)},100))},i.prototype.onKeyUp=function(e){"Enter"===e.key&&(this.keyTimeout?this.keyTimeout=!1:e.target.click(),clearTimeout(this.keyTimer))},i.prototype.eventBinding=function(e){var t=this;[].slice.call(e).forEach(function(n){new fs(n,{tapHold:t.tabHoldHandler.bind(t),tapHoldThreshold:500}),n.addEventListener("keydown",t.onKeyPress.bind(t)),n.addEventListener("keyup",t.onKeyUp.bind(t)),n.addEventListener("mouseup",t.repeatScroll.bind(t)),n.addEventListener("touchend",t.repeatScroll.bind(t)),n.addEventListener("contextmenu",function(r){r.preventDefault()}),y.add(n,"click",t.clickEventHandler,t)})},i.prototype.repeatScroll=function(){clearInterval(this.timeout)},i.prototype.tabHoldHandler=function(e){var t=this,n=e.originalEvent.target;n=this.contains(n,Gl)?n.firstElementChild:n,this.timeout=window.setInterval(function(){t.eleScrolling(10,n,!0)},50)},i.prototype.contains=function(e,t){return e.classList.contains(t)},i.prototype.eleScrolling=function(e,t,n){var r=t.classList;r.contains(Gl)&&(r=t.querySelector("."+Dp).classList),r.contains(Sp)?this.frameScrollRequest(e,"add",n):r.contains(Dv)&&this.frameScrollRequest(e,"",n)},i.prototype.clickEventHandler=function(e){this.eleScrolling(this.scrollStep,e.target,!1)},i.prototype.wheelEventHandler=function(e){e.preventDefault(),this.frameScrollRequest(this.scrollStep,e.deltaY>0?"add":"",!1)},i.prototype.swipeHandler=function(e){var n,t=this.scrollEle;n=e.velocity<=1?e.distanceY/(10*e.velocity):e.distanceY/e.velocity;var r=.5,o=function(){var a=Math.sin(r);a<=0?window.cancelAnimationFrame(a):("Up"===e.swipeDirection?t.scrollTop+=n*a:"Down"===e.swipeDirection&&(t.scrollTop-=n*a),r-=.02,window.requestAnimationFrame(o))};o()},i.prototype.scrollUpdating=function(e,t){"add"===t?this.scrollEle.scrollTop+=e:this.scrollEle.scrollTop-=e},i.prototype.frameScrollRequest=function(e,t,n){var r=this;if(n)this.scrollUpdating(e,t);else{this.customStep||[].slice.call(se("."+Sv,this.element)).forEach(function(l){e-=l.offsetHeight});var a=function(){e<10?window.cancelAnimationFrame(10):(r.scrollUpdating(10,t),e-=10,window.requestAnimationFrame(a))};a()}},i.prototype.touchHandler=function(e){var t=this.scrollEle,n=e.distanceY;"Up"===e.scrollDirection?t.scrollTop=t.scrollTop+n:"Down"===e.scrollDirection&&(t.scrollTop=t.scrollTop-n)},i.prototype.arrowDisabling=function(e,t){if(this.isDevice){var r=(d(e)?t:e).querySelector("."+Dp);d(e)?qn(r,[Sp],[Dv]):qn(r,[Dv],[Sp])}else e.classList.add(rl),e.setAttribute("aria-disabled","true"),e.removeAttribute("tabindex"),t.classList.remove(rl),t.setAttribute("aria-disabled","false"),t.setAttribute("tabindex","0");this.repeatScroll()},i.prototype.scrollEventHandler=function(e){var t=e.target,n=t.offsetHeight,r=this.element.querySelector("."+KP),o=this.element.querySelector("."+VE),a=this.element.querySelector("."+ez),l=this.element.querySelector("."+tz),c=t.scrollTop;if(c<=0&&(c=-c),this.isDevice&&(a.style.height=c<40?c+"px":"40px",l.style.height=t.scrollHeight-Math.ceil(n+c)<40?t.scrollHeight-Math.ceil(n+c)+"px":"40px"),0===c)this.arrowDisabling(r,o);else if(Math.ceil(n+c+.1)>=t.scrollHeight)this.arrowDisabling(o,r);else{var u=this.element.querySelector("."+Gl+"."+rl);u&&(u.classList.remove(rl),u.setAttribute("aria-disabled","false"),u.setAttribute("tabindex","0"))}},i.prototype.onPropertyChanged=function(e,t){for(var n=0,r=Object.keys(e);n=0;a--)(o=s[a])&&(r=(n<3?o(r):n>3?o(i,e,r):o(i,e))||r);return n>3&&r&&Object.defineProperty(i,e,r),r},QE="e-vertical",Ti="e-toolbar-items",wi="e-toolbar-item",wo="e-rtl",Vi="e-separator",kv="e-popup-up-icon",Tp="e-popup-down-icon",cz="e-popup-open",uz="e-template",vs="e-overlay",hz="e-toolbar-text",qE="e-popup-text",Zr="e-overflow-show",jv="e-overflow-hide",Us="e-hor-nav",dz="e-scroll-nav",pz="e-toolbar-center",Xr="e-tbar-pos",$E="e-hscroll-bar",wp="e-toolbar-pop",ol="e-toolbar-popup",Ap="e-nav-active",Lp="e-ignore",GE="e-popup-alone",Ao="e-hidden",fz="e-toolbar-multirow",gz="e-multirow-pos",ZE="e-multirow-separator",XE="e-extended-separator",mz="e-extended-toolbar",Rv="e-toolbar-extended",KE="e-tbar-extended",lX=function(s){function i(){return null!==s&&s.apply(this,arguments)||this}return lz(i,s),li([m("")],i.prototype,"id",void 0),li([m("")],i.prototype,"text",void 0),li([m("auto")],i.prototype,"width",void 0),li([m("")],i.prototype,"cssClass",void 0),li([m(!1)],i.prototype,"showAlwaysInPopup",void 0),li([m(!1)],i.prototype,"disabled",void 0),li([m("")],i.prototype,"prefixIcon",void 0),li([m("")],i.prototype,"suffixIcon",void 0),li([m(!0)],i.prototype,"visible",void 0),li([m("None")],i.prototype,"overflow",void 0),li([m("")],i.prototype,"template",void 0),li([m("Button")],i.prototype,"type",void 0),li([m("Both")],i.prototype,"showTextOn",void 0),li([m(null)],i.prototype,"htmlAttributes",void 0),li([m("")],i.prototype,"tooltipText",void 0),li([m("Left")],i.prototype,"align",void 0),li([w()],i.prototype,"click",void 0),li([m(-1)],i.prototype,"tabIndex",void 0),i}(Lt),cX=function(s){function i(e,t){var n=s.call(this,e,t)||this;return n.resizeContext=n.resize.bind(n),n.orientationChangeContext=n.orientationChange.bind(n),n.keyConfigs={moveLeft:"leftarrow",moveRight:"rightarrow",moveUp:"uparrow",moveDown:"downarrow",popupOpen:"enter",popupClose:"escape",tab:"tab",home:"home",end:"end"},n}return lz(i,s),i.prototype.destroy=function(){var e=this;(this.isReact||this.isAngular)&&this.clearTemplate();var t=this.element.querySelectorAll(".e-control.e-btn");for([].slice.call(t).forEach(function(n){!d(n)&&!d(n.ej2_instances)&&!d(n.ej2_instances[0])&&!n.ej2_instances[0].isDestroyed&&n.ej2_instances[0].destroy()}),this.unwireEvents(),this.tempId.forEach(function(n){d(e.element.querySelector(n))||(document.body.appendChild(e.element.querySelector(n)).style.display="none")}),this.destroyItems();this.element.lastElementChild;)this.element.removeChild(this.element.lastElementChild);this.trgtEle&&(this.element.appendChild(this.ctrlTem),this.trgtEle=null,this.ctrlTem=null),this.popObj&&(this.popObj.destroy(),$(this.popObj.element)),this.activeEle&&(this.activeEle=null),this.popObj=null,this.tbarAlign=null,this.tbarItemsCol=[],this.remove(this.element,"e-toolpop"),this.cssClass&&R([this.element],this.cssClass.split(" ")),this.element.removeAttribute("style"),["aria-disabled","aria-orientation","role"].forEach(function(n){return e.element.removeAttribute(n)}),s.prototype.destroy.call(this)},i.prototype.preRender=function(){var e={enableCollision:this.enableCollision,scrollStep:this.scrollStep};this.trigger("beforeCreate",e),this.enableCollision=e.enableCollision,this.scrollStep=e.scrollStep,this.scrollModule=null,this.popObj=null,this.tempId=[],this.tbarItemsCol=this.items,this.isVertical=!!this.element.classList.contains(QE),this.isExtendedOpen=!1,this.popupPriCount=0,this.enableRtl&&this.add(this.element,wo)},i.prototype.wireEvents=function(){y.add(this.element,"click",this.clickHandler,this),window.addEventListener("resize",this.resizeContext),window.addEventListener("orientationchange",this.orientationChangeContext),this.allowKeyboard&&this.wireKeyboardEvent()},i.prototype.wireKeyboardEvent=function(){this.keyModule=new ps(this.element,{keyAction:this.keyActionHandler.bind(this),keyConfigs:this.keyConfigs}),y.add(this.element,"keydown",this.docKeyDown,this),this.updateTabIndex("0")},i.prototype.updateTabIndex=function(e){var t=this.element.querySelector("."+wi+":not(."+vs+" ):not(."+Vi+" ):not(."+Ao+" )");if(!d(t)&&!d(t.firstElementChild)){var n=t.firstElementChild.getAttribute("data-tabindex");n&&"-1"===n&&"INPUT"!==t.firstElementChild.tagName&&t.firstElementChild.setAttribute("tabindex",e)}},i.prototype.unwireKeyboardEvent=function(){this.keyModule&&(y.remove(this.element,"keydown",this.docKeyDown),this.keyModule.destroy(),this.keyModule=null)},i.prototype.docKeyDown=function(e){if("INPUT"!==e.target.tagName){var t=!d(this.popObj)&&ji(this.popObj.element)&&"Extended"!==this.overflowMode;9===e.keyCode&&!0===e.target.classList.contains("e-hor-nav")&&t&&this.popObj.hide({name:"FadeOut",duration:100}),(40===e.keyCode||38===e.keyCode||35===e.keyCode||36===e.keyCode)&&e.preventDefault()}},i.prototype.unwireEvents=function(){y.remove(this.element,"click",this.clickHandler),this.destroyScroll(),this.unwireKeyboardEvent(),window.removeEventListener("resize",this.resizeContext),window.removeEventListener("orientationchange",this.orientationChangeContext),document.removeEventListener("scroll",this.clickEvent),document.removeEventListener("click",this.scrollEvent),this.scrollEvent=null,this.clickEvent=null},i.prototype.clearProperty=function(){this.tbarEle=[],this.tbarAlgEle={lefts:[],centers:[],rights:[]}},i.prototype.docEvent=function(e){var t=j(e.target,".e-popup");this.popObj&&ji(this.popObj.element)&&!t&&"Popup"===this.overflowMode&&this.popObj.hide({name:"FadeOut",duration:100})},i.prototype.destroyScroll=function(){this.scrollModule&&(this.tbarAlign&&this.add(this.scrollModule.element,Xr),this.scrollModule.destroy(),this.scrollModule=null)},i.prototype.destroyItems=function(){if(this.element&&[].slice.call(this.element.querySelectorAll("."+wi)).forEach(function(t){$(t)}),this.tbarAlign){var e=this.element.querySelector("."+Ti);[].slice.call(e.children).forEach(function(t){$(t)}),this.tbarAlign=!1,this.remove(e,Xr)}this.clearProperty()},i.prototype.destroyMode=function(){this.scrollModule&&(this.remove(this.scrollModule.element,wo),this.destroyScroll()),this.remove(this.element,KE),this.remove(this.element,mz);var e=this.element.querySelector(".e-toolbar-multirow");e&&this.remove(e,fz),this.popObj&&this.popupRefresh(this.popObj.element,!0)},i.prototype.add=function(e,t){e.classList.add(t)},i.prototype.remove=function(e,t){e.classList.remove(t)},i.prototype.elementFocus=function(e){var t=e.firstElementChild;t?(t.focus(),this.activeEleSwitch(e)):e.focus()},i.prototype.clstElement=function(e,t){return e&&this.popObj&&ji(this.popObj.element)?this.popObj.element.querySelector("."+wi):this.element===t||e?this.element.querySelector("."+wi+":not(."+vs+" ):not(."+Vi+" ):not(."+Ao+" )"):j(t,"."+wi)},i.prototype.keyHandling=function(e,t,n,r,o){var h,p,a=this.popObj,l=this.element,c={name:"FadeOut",duration:100},u="moveUp"===t.action?"previous":"next";switch(t.action){case"moveRight":if(this.isVertical)return;l===n?this.elementFocus(e):r||this.eleFocus(e,"next");break;case"moveLeft":if(this.isVertical)return;r||this.eleFocus(e,"previous");break;case"home":case"end":if(e){var f=j(e,".e-popup"),g=this.element.querySelector("."+Rv);"Extended"===this.overflowMode&&g&&g.classList.contains("e-popup-open")&&(f="end"===t.action?g:null),f?ji(this.popObj.element)&&(p=[].slice.call(f.children),h="home"===t.action?this.focusFirstVisibleEle(p):this.focusLastVisibleEle(p)):(p=this.element.querySelectorAll("."+Ti+" ."+wi+":not(."+Vi+")"),h="home"===t.action?this.focusFirstVisibleEle(p):this.focusLastVisibleEle(p)),h&&this.elementFocus(h)}break;case"moveUp":case"moveDown":if(this.isVertical)this.eleFocus(e,"moveUp"===t.action?"previous":"next");else if(a&&j(n,".e-popup")){var v=a.element,b=v.firstElementChild;"previous"===u&&b===e?v.lastElementChild.firstChild.focus():"next"===u&&v.lastElementChild===e?b.firstChild.focus():this.eleFocus(e,u)}else"moveDown"===t.action&&a&&ji(a.element)&&this.elementFocus(e);break;case"tab":if(!o&&!r){var M=e.firstElementChild;l===n&&(this.activeEle?this.activeEle.focus():(this.activeEleRemove(M),M.focus()))}break;case"popupClose":a&&"Extended"!==this.overflowMode&&a.hide(c);break;case"popupOpen":if(!r)return;a&&!ji(a.element)?(a.element.style.top=l.offsetHeight+"px",a.show({name:"FadeIn",duration:100})):a.hide(c)}},i.prototype.keyActionHandler=function(e){var t=e.target;if("INPUT"!==t.tagName&&"TEXTAREA"!==t.tagName&&!this.element.classList.contains(vs)){e.preventDefault();var n=t.classList.contains(Us),r=t.classList.contains(dz),o=this.clstElement(n,t);(o||r)&&this.keyHandling(o,e,t,n,r)}},i.prototype.disable=function(e){var t=this.element;e?t.classList.add(vs):t.classList.remove(vs),this.activeEle&&this.activeEle.setAttribute("tabindex",this.activeEle.getAttribute("data-tabindex")),this.scrollModule&&this.scrollModule.disable(e),this.popObj&&(ji(this.popObj.element)&&"Extended"!==this.overflowMode&&this.popObj.hide(),t.querySelector("#"+t.id+"_nav").setAttribute("tabindex",e?"-1":"0"))},i.prototype.eleContains=function(e){return e.classList.contains(Vi)||e.classList.contains(vs)||e.getAttribute("disabled")||e.classList.contains(Ao)||!ji(e)||!e.classList.contains(wi)},i.prototype.focusFirstVisibleEle=function(e){for(var n=0;n=0;){var r=e[parseInt(n.toString(),10)];if(!r.classList.contains(Ao)&&!r.classList.contains(vs))return r;n--}},i.prototype.eleFocus=function(e,t){var n=Object(e)[t+"ElementSibling"];if(n){if(this.eleContains(n))return void this.eleFocus(n,t);this.elementFocus(n)}else if(this.tbarAlign){var o=Object(e.parentElement)[t+"ElementSibling"];if(!d(o)&&0===o.children.length&&(o=Object(o)[t+"ElementSibling"]),!d(o)&&o.children.length>0)if("next"===t){var a=o.querySelector("."+wi);this.eleContains(a)?this.eleFocus(a,t):(a.firstElementChild.focus(),this.activeEleSwitch(a))}else this.eleContains(a=o.lastElementChild)?this.eleFocus(a,t):this.elementFocus(a)}else if(!d(e)){var l=this.element.querySelectorAll("."+Ti+" ."+wi+":not(."+Vi+"):not(."+vs+"):not(."+Ao+")");"next"===t&&l?this.elementFocus(l[0]):"previous"===t&&l&&this.elementFocus(l[l.length-1])}},i.prototype.clickHandler=function(e){var t=this,n=e.target,r=this.element,o=!d(j(n,"."+wp)),a=n.classList,l=j(n,"."+Us);l||(l=n),!r.children[0].classList.contains("e-hscroll")&&!r.children[0].classList.contains("e-vscroll")&&a.contains(Us)&&(a=n.querySelector(".e-icons").classList),(a.contains(kv)||a.contains(Tp))&&this.popupClickHandler(r,l,wo);var c,u=j(e.target,"."+wi);if(!d(u)&&!u.classList.contains(vs)||l.classList.contains(Us)){u&&(c=this.items[this.tbarEle.indexOf(u)]);var p={originalEvent:e,item:c};(c&&!d(c.click)&&"object"==typeof c.click?!d(c.click.observers)&&c.click.observers.length>0:!d(c)&&!d(c.click))&&this.trigger("items["+this.tbarEle.indexOf(u)+"].click",p),p.cancel||this.trigger("clicked",p,function(g){!d(t.popObj)&&o&&!g.cancel&&"Popup"===t.overflowMode&&g.item&&"Input"!==g.item.type&&t.popObj.hide({name:"FadeOut",duration:100})})}},i.prototype.popupClickHandler=function(e,t,n){var r=this.popObj;ji(r.element)?(t.classList.remove(Ap),r.hide({name:"FadeOut",duration:100})):(e.classList.contains(n)&&(r.enableRtl=!0,r.position={X:"left",Y:"top"}),0===r.offsetX&&!e.classList.contains(n)&&(r.enableRtl=!1,r.position={X:"right",Y:"top"}),"Extended"===this.overflowMode&&(r.element.style.minHeight="0px",r.width=this.getToolbarPopupWidth(this.element)),r.dataBind(),r.refreshPosition(),r.element.style.top=this.getElementOffsetY()+"px",t.classList.add(Ap),r.show({name:"FadeIn",duration:100}))},i.prototype.getToolbarPopupWidth=function(e){var t=window.getComputedStyle(e);return parseFloat(t.width)+2*parseFloat(t.borderRightWidth)},i.prototype.render=function(){var e=this;this.initialize(),this.renderControl(),this.wireEvents(),this.clickEvent=this.docEvent.bind(this),this.scrollEvent=this.docEvent.bind(this),this.renderComplete(),this.isReact&&this.portals&&this.portals.length>0&&this.renderReactTemplates(function(){e.refreshOverflow()})},i.prototype.initialize=function(){var e=de(this.width),t=de(this.height);("msie"!==_.info.name||"auto"!==this.height||"MultiRow"===this.overflowMode)&&be(this.element,{height:t}),be(this.element,{width:e}),ge(this.element,{role:"toolbar","aria-disabled":"false","aria-orientation":this.isVertical?"vertical":"horizontal"}),this.cssClass&&N([this.element],this.cssClass.split(" "))},i.prototype.renderControl=function(){var e=this.element;this.trgtEle=e.children.length>0?e.querySelector("div"):null,this.tbarAlgEle={lefts:[],centers:[],rights:[]},this.renderItems(),this.renderLayout()},i.prototype.renderLayout=function(){this.renderOverflowMode(),this.tbarAlign&&this.itemPositioning(),this.popObj&&this.popObj.element.childElementCount>1&&this.checkPopupRefresh(this.element,this.popObj.element)&&this.popupRefresh(this.popObj.element,!1),this.separator()},i.prototype.itemsAlign=function(e,t){var n,r;this.tbarEle||(this.tbarEle=[]);for(var o=0;on-l},i.prototype.refreshOverflow=function(){this.resize()},i.prototype.toolbarAlign=function(e){this.tbarAlign&&(this.add(e,Xr),this.itemPositioning())},i.prototype.renderOverflowMode=function(){var e=this.element,t=e.querySelector("."+Ti),n=this.popupPriCount>0;if(e&&e.children.length>0)switch(this.offsetWid=e.offsetWidth,this.remove(this.element,"e-toolpop"),"msie"===_.info.name&&"auto"===this.height&&(e.style.height=""),this.overflowMode){case"Scrollable":d(this.scrollModule)&&this.initScroll(e,[].slice.call(e.getElementsByClassName(Ti)));break;case"Popup":this.add(this.element,"e-toolpop"),this.tbarAlign&&this.removePositioning(),(this.checkOverflow(e,t)||n)&&this.setOverflowAttributes(e),this.toolbarAlign(t);break;case"MultiRow":this.add(t,fz),this.checkOverflow(e,t)&&this.tbarAlign&&(this.removePositioning(),this.add(t,gz)),"hidden"===e.style.overflow&&(e.style.overflow=""),("msie"===_.info.name||"auto"!==e.style.height)&&(e.style.height="auto");break;case"Extended":this.add(this.element,mz),(this.checkOverflow(e,t)||n)&&(this.tbarAlign&&this.removePositioning(),this.setOverflowAttributes(e)),this.toolbarAlign(t)}},i.prototype.setOverflowAttributes=function(e){this.createPopupEle(e,[].slice.call(se("."+Ti+" ."+wi,e))),ge(this.element.querySelector("."+Us),{tabindex:"0",role:"button","aria-haspopup":"true","aria-label":"overflow"})},i.prototype.separator=function(){var e=this.element,t=[].slice.call(e.querySelectorAll("."+Vi)),n=e.querySelector("."+ZE),r=e.querySelector("."+XE),o="MultiRow"===this.overflowMode?n:r;null!==o&&("MultiRow"===this.overflowMode?o.classList.remove(ZE):"Extended"===this.overflowMode&&o.classList.remove(XE));for(var a=0;a<=t.length-1;a++)t[parseInt(a.toString(),10)].offsetLeft<30&&0!==t[parseInt(a.toString(),10)].offsetLeft&&("MultiRow"===this.overflowMode?t[parseInt(a.toString(),10)].classList.add(ZE):"Extended"===this.overflowMode&&t[parseInt(a.toString(),10)].classList.add(XE))},i.prototype.createPopupEle=function(e,t){var n=e.querySelector("."+Us),r=this.isVertical;n||this.createPopupIcon(e),n=e.querySelector("."+Us);var a=(r?e.offsetHeight:e.offsetWidth)-(r?n.offsetHeight:n.offsetWidth);this.element.classList.remove("e-rtl"),be(this.element,{direction:"initial"}),this.checkPriority(e,t,a,!0),this.enableRtl&&this.element.classList.add("e-rtl"),this.element.style.removeProperty("direction"),this.createPopup()},i.prototype.pushingPoppedEle=function(e,t,n,r,o){var a=e.element,l=[].slice.call(se("."+ol,a.querySelector("."+Ti))),c=se("."+Zr,n),u=0,h=0;l.forEach(function(v,b){c=se("."+Zr,n),v.classList.contains(Zr)&&c.length>0?e.tbResize&&c.length>b?(n.insertBefore(v,c[parseInt(b.toString(),10)]),++h):(n.insertBefore(v,n.children[c.length]),++h):v.classList.contains(Zr)||e.tbResize&&v.classList.contains(jv)&&n.children.length>0&&0===c.length?(n.insertBefore(v,n.firstChild),++h):v.classList.contains(jv)?t.push(v):e.tbResize?(n.insertBefore(v,n.childNodes[u+h]),++u):n.appendChild(v),v.classList.contains(Vi)?be(v,{display:"",height:o+"px"}):be(v,{display:"",height:r+"px"})}),t.forEach(function(v){n.appendChild(v)});for(var p=se("."+wi,a.querySelector("."+Ti)),f=p.length-1;f>=0;f--){var g=p[parseInt(f.toString(),10)];if(!g.classList.contains(Vi)||"Extended"===this.overflowMode)break;be(g,{display:"none"})}},i.prototype.createPopup=function(){var t,n,e=this.element;"Extended"===this.overflowMode&&(n=e.querySelector("."+Vi),t="auto"===e.style.height||""===e.style.height?null:n&&n.offsetHeight);var a,r=e.querySelector("."+wi+":not(."+Vi+"):not(."+ol+")"),o="auto"===e.style.height||""===e.style.height?null:r&&r.offsetHeight;if(S("#"+e.id+"_popup."+wp,e))a=S("#"+e.id+"_popup."+wp,e);else{var c=this.createElement("div",{id:e.id+"_popup",className:wp+" "+Rv}),u=this.createElement("div",{id:e.id+"_popup",className:wp});a="Extended"===this.overflowMode?c:u}this.pushingPoppedEle(this,[],a,o,t),this.popupInit(e,a)},i.prototype.getElementOffsetY=function(){return"Extended"===this.overflowMode&&"border-box"===window.getComputedStyle(this.element).getPropertyValue("box-sizing")?this.element.clientHeight:this.element.offsetHeight},i.prototype.popupInit=function(e,t){if(this.popObj){if("Extended"!==this.overflowMode){var o=this.popObj.element;be(o,{maxHeight:"",display:"block"}),be(o,{maxHeight:o.offsetHeight+"px",display:""})}}else{e.appendChild(t),this.cssClass&&N([t],this.cssClass.split(" ")),be(this.element,{overflow:""});var n=new Za(null,{relateTo:this.element,offsetY:this.isVertical?0:this.getElementOffsetY(),enableRtl:this.enableRtl,open:this.popupOpen.bind(this),close:this.popupClose.bind(this),collision:{Y:this.enableCollision?"flip":"none"},position:this.enableRtl?{X:"left",Y:"top"}:{X:"right",Y:"top"}});if("Extended"===this.overflowMode&&(n.width=this.getToolbarPopupWidth(this.element),n.offsetX=0),n.appendTo(t),document.addEventListener("scroll",this.clickEvent),document.addEventListener("click",this.scrollEvent),"Extended"!==this.overflowMode&&(n.element.style.maxHeight=n.element.offsetHeight+"px"),this.isVertical&&(n.element.style.visibility="hidden"),this.isExtendedOpen){var r=this.element.querySelector("."+Us);r.classList.add(Ap),qn(r.firstElementChild,[kv],[Tp]),this.element.querySelector("."+Rv).classList.add(cz)}else n.hide();this.popObj=n}},i.prototype.tbarPopupHandler=function(e){"Extended"===this.overflowMode&&(e?this.add(this.element,KE):this.remove(this.element,KE))},i.prototype.popupOpen=function(e){var t=this.popObj;this.isVertical||(t.offsetY=this.getElementOffsetY(),t.dataBind());var n=this.popObj.element,r=this.popObj.element.parentElement,o=r.querySelector("."+Us);o.setAttribute("aria-expanded","true"),"Extended"===this.overflowMode?t.element.style.minHeight="":(be(t.element,{height:"auto",maxHeight:""}),t.element.style.maxHeight=t.element.offsetHeight+"px");var a=n.offsetTop+n.offsetHeight+Vn(r).top,l=o.firstElementChild;o.classList.add(Ap),qn(l,[kv],[Tp]),this.tbarPopupHandler(!0);var c=d(window.scrollY)?0:window.scrollY;if(!this.isVertical&&window.innerHeight+cu){u=p.offsetTop;break}}"Extended"!==this.overflowMode&&be(t.element,{maxHeight:u+"px"})}else if(this.isVertical&&"Extended"!==this.overflowMode){var f=this.element.getBoundingClientRect();be(t.element,{maxHeight:f.top+this.element.offsetHeight+"px",bottom:0,visibility:""})}if(t){var g=n.getBoundingClientRect();g.right>document.documentElement.clientWidth&&g.width>r.getBoundingClientRect().width&&(t.collision={Y:"none"},t.dataBind()),t.refreshPosition()}},i.prototype.popupClose=function(e){var n=this.element.querySelector("."+Us);n.setAttribute("aria-expanded","false");var r=n.firstElementChild;n.classList.remove(Ap),qn(r,[Tp],[kv]),this.tbarPopupHandler(!1)},i.prototype.checkPriority=function(e,t,n,r){for(var c,o=this.popupPriCount>0,l=n,h=0,p=0,f=0,g=function(B,re){var le=!1;return re.forEach(function(Te){B.classList.contains(Te)&&(le=!0)}),le},v=t.length-1;v>=0;v--){var b=void 0,M=window.getComputedStyle(t[parseInt(v.toString(),10)]);this.isVertical?(b=parseFloat(M.marginTop),b+=parseFloat(M.marginBottom)):(b=parseFloat(M.marginRight),b+=parseFloat(M.marginLeft));var C=t[parseInt(v.toString(),10)]===this.tbarEle[0];C&&(this.tbarEleMrgn=b),c=this.isVertical?t[parseInt(v.toString(),10)].offsetHeight:t[parseInt(v.toString(),10)].offsetWidth;var D=C?c+b:c;if(g(t[parseInt(v.toString(),10)],[GE])&&o&&(t[parseInt(v.toString(),10)].classList.add(ol),be(t[parseInt(v.toString(),10)],this.isVertical?{display:"none",minHeight:D+"px"}:{display:"none",minWidth:D+"px"}),f++),this.isVertical?t[parseInt(v.toString(),10)].offsetTop+t[parseInt(v.toString(),10)].offsetHeight+b>n:t[parseInt(v.toString(),10)].offsetLeft+t[parseInt(v.toString(),10)].offsetWidth+b>n){if(t[parseInt(v.toString(),10)].classList.contains(Vi)){if("Extended"===this.overflowMode)g(T=t[parseInt(v.toString(),10)],[Vi,Lp])&&(t[parseInt(v.toString(),10)].classList.add(ol),f++),p++;else if("Popup"===this.overflowMode){var T;h>0&&p===f&&g(T=t[v+p+(h-1)],[Vi,Lp])&&be(T,{display:"none"}),h++,p=0,f=0}}else p++;t[parseInt(v.toString(),10)].classList.contains(Zr)&&r||g(t[parseInt(v.toString(),10)],[Vi,Lp])?n-=(this.isVertical?t[parseInt(v.toString(),10)].offsetHeight:t[parseInt(v.toString(),10)].offsetWidth)+b:(t[parseInt(v.toString(),10)].classList.add(ol),be(t[parseInt(v.toString(),10)],this.isVertical?{display:"none",minHeight:D+"px"}:{display:"none",minWidth:D+"px"}),f++)}}if(r){var k=se("."+wi+":not(."+ol+")",this.element);this.checkPriority(e,k,l,!1)}},i.prototype.createPopupIcon=function(e){var t=e.id.concat("_nav"),n="e-"+e.id.concat("_nav e-hor-nav"),r=this.createElement("div",{id:t,className:n="Extended"===this.overflowMode?n+" e-expended-nav":n});("msie"===_.info.name||"edge"===_.info.name)&&r.classList.add("e-ie-align");var o=this.createElement("div",{className:Tp+" e-icons"});r.appendChild(o),r.setAttribute("tabindex","0"),r.setAttribute("role","button"),e.appendChild(r)},i.prototype.tbarPriRef=function(e,t,n,r,o,a,l,c,u){var h=c,f="."+wi+":not(."+Vi+"):not(."+Zr+")",g=se("."+ol+":not(."+Zr+")",this.popObj.element).length,v=function(T,k){return T.classList.contains(k)};if(0===se(f,e).length){var b=e.children[t-(t-n)-1],M=!d(b)&&v(b,Lp);if(!d(b)&&v(b,Vi)&&!ji(b)||M){b.style.display="unset";var C=b.offsetWidth+2*parseFloat(window.getComputedStyle(b).marginRight),D=b.previousElementSibling;a+Cu&&0===this.popupPriCount&&(t=!0),this.popupEleRefresh(c,e,t),e.style.display="",0===e.children.length&&l&&this.popObj&&($(l),l=null,this.popObj.destroy(),$(this.popObj.element),this.popObj=null)}},i.prototype.ignoreEleFetch=function(e,t){var n=[].slice.call(t.querySelectorAll("."+Lp)),r=[],o=0;return n.length>0?(n.forEach(function(a){r.push([].slice.call(t.children).indexOf(a))}),r.forEach(function(a){a<=e&&o++}),o):0},i.prototype.checkPopupRefresh=function(e,t){t.style.display="block";var n=this.popupEleWidth(t.firstElementChild);t.firstElementChild.style.removeProperty("Position");var r=e.offsetWidth-e.querySelector("."+Us).offsetWidth,o=e.querySelector("."+Ti).offsetWidth;return t.style.removeProperty("display"),r>n+o},i.prototype.popupEleWidth=function(e){e.style.position="absolute";var t=this.isVertical?e.offsetHeight:e.offsetWidth,n=e.querySelector(".e-tbar-btn-text");if(e.classList.contains("e-tbtn-align")||e.classList.contains(qE)){var r=e.children[0];!d(n)&&e.classList.contains(qE)?n.style.display="none":!d(n)&&e.classList.contains(hz)&&(n.style.display="block"),r.style.minWidth="0%",t=parseFloat(this.isVertical?e.style.minHeight:e.style.minWidth),r.style.minWidth="",r.style.minHeight="",d(n)||(n.style.display="")}return t},i.prototype.popupEleRefresh=function(e,t,n){for(var a,l,r=this.popupPriCount>0,o=this.tbarEle,c=this.element.querySelector("."+Ti),u=0,h=function(C){if(C.classList.contains(GE)&&r&&!n)return"continue";var D=p.popupEleWidth(C);if(C===p.tbarEle[0]&&(D+=p.tbarEleMrgn),C.style.position="",!(D0){var n=void 0;e&&e.children.length>0&&(n=e.querySelector("."+Ti)),n||(n=this.createElement("div",{className:Ti})),this.itemsAlign(t,n),e.appendChild(n)}},i.prototype.setAttr=function(e,t){for(var r,n=Object.keys(e),o=0;o=1){for(var l=0,c=[].slice.call(n);l=t&&n.length>=0){d(this.scrollModule)&&this.destroyMode();var h="L"===u.align[0]?0:"C"===u.align[0]?1:2,p=void 0;this.tbarAlign||"Left"===a?this.tbarAlign?((p=j(n[0],"."+Ti).children[parseInt(h.toString(),10)]).insertBefore(o,p.children[parseInt(t.toString(),10)]),this.tbarAlgEle[(u.align+"s").toLowerCase()].splice(t,0,o),this.refreshPositioning()):0===n.length?(n=se("."+Ti,this.element))[0].appendChild(o):n[0].parentNode.insertBefore(o,n[parseInt(t.toString(),10)]):(this.tbarItemAlign(u,r,1),this.tbarAlign=!0,(p=j(n[0],"."+Ti).children[parseInt(h.toString(),10)]).appendChild(o),this.tbarAlgEle[(u.align+"s").toLowerCase()].push(o),this.refreshPositioning()),this.items.splice(t,0,u),u.template&&this.tbarEle.splice(this.tbarEle.length-1,1),this.tbarEle.splice(t,0,o),t++,this.offsetWid=r.offsetWidth}}r.style.width="",this.renderOverflowMode(),this.isReact&&this.renderReactTemplates()}},i.prototype.removeItems=function(e){var n,t=e,r=[].slice.call(se("."+wi,this.element));if("number"==typeof t)n=parseInt(e.toString(),10),this.removeItemByIndex(n,r);else if(t&&t.length>1)for(var o=0,a=[].slice.call(t);o|br|hr|input|!--|wbr)[a-z]+.*?>|<([a-z]+).*?<\/\1>/i);u="string"==typeof e?e.trim():e;try{if("object"!=typeof e||d(e.tagName))if("string"==typeof e&&h.test(u))t.innerHTML=u;else if(document.querySelectorAll(u).length){var p,f=(p=document.querySelector(u)).outerHTML.trim();t.appendChild(p),p.style.display="",d(f)||this.tempId.push(u)}else c=oi(u);else t.appendChild(e)}catch{c=oi(u)}var g=void 0;d(c)||(g=c({},this,"template",this.element.id+r+"_template",this.isStringTemplate,void 0,void 0,this.root)),!d(g)&&g.length>0&&[].slice.call(g).forEach(function(M){d(M.tagName)||(M.style.display=""),t.appendChild(M)})}this.add(t,uz);var b=t.firstElementChild;d(b)||(b.setAttribute("tabindex",d(b.getAttribute("tabIndex"))?"-1":this.getDataTabindex(b)),b.setAttribute("data-tabindex",d(b.getAttribute("tabIndex"))?"-1":this.getDataTabindex(b))),this.tbarEle.push(t)},i.prototype.buttonRendering=function(e,t){var n=this.createElement("button",{className:"e-tbar-btn"});n.setAttribute("type","button");var o,a,r=e.text;n.id=e.id?e.id:Bt("e-tbr-btn");var l=this.createElement("span",{className:"e-tbar-btn-text"});r?(l.innerHTML=this.enableHtmlSanitizer?Qt.sanitize(r):r,n.appendChild(l),n.classList.add("e-tbtn-txt")):this.add(t,"e-tbtn-align"),(e.prefixIcon||e.suffixIcon)&&(e.prefixIcon&&e.suffixIcon||e.prefixIcon?(o=e.prefixIcon+" e-icons",a="Left"):(o=e.suffixIcon+" e-icons",a="Right"));var c=new Zn({iconCss:o,iconPosition:a});return c.createElement=this.createElement,c.appendTo(n),e.width&&be(n,{width:de(e.width)}),n},i.prototype.renderSubComponent=function(e,t){var n,r=this.createElement("div",{className:wi}),o=this.createElement("div",{innerHTML:this.enableHtmlSanitizer&&!d(e.tooltipText)?Qt.sanitize(e.tooltipText):e.tooltipText});if(this.tbarEle||(this.tbarEle=[]),e.htmlAttributes&&this.setAttr(e.htmlAttributes,r),e.tooltipText&&r.setAttribute("title",o.textContent),e.cssClass&&(r.className=r.className+" "+e.cssClass),e.template)this.templateRender(e.template,r,e,t);else switch(e.type){case"Button":(n=this.buttonRendering(e,r)).setAttribute("tabindex",d(e.tabIndex)?"-1":e.tabIndex.toString()),n.setAttribute("data-tabindex",d(e.tabIndex)?"-1":e.tabIndex.toString()),n.setAttribute("aria-label",e.text||e.tooltipText),n.setAttribute("aria-disabled","false"),r.appendChild(n),r.addEventListener("click",this.itemClick.bind(this));break;case"Separator":this.add(r,Vi)}if(e.showTextOn){var a=e.showTextOn;"Toolbar"===a?(this.add(r,hz),this.add(r,"e-tbtn-align")):"Overflow"===a&&this.add(r,qE)}if(e.overflow){var l=e.overflow;"Show"===l?this.add(r,Zr):"Hide"===l&&(r.classList.contains(Vi)||this.add(r,jv))}return"Show"!==e.overflow&&e.showAlwaysInPopup&&!r.classList.contains(Vi)&&(this.add(r,GE),this.popupPriCount++),e.disabled&&this.add(r,vs),!1===e.visible&&this.add(r,Ao),r},i.prototype.getDataTabindex=function(e){return d(e.getAttribute("data-tabindex"))?"-1":e.getAttribute("data-tabindex")},i.prototype.itemClick=function(e){this.activeEleSwitch(e.currentTarget)},i.prototype.activeEleSwitch=function(e){this.activeEleRemove(e.firstElementChild),this.activeEle.focus()},i.prototype.activeEleRemove=function(e){var t=this.element.querySelector("."+wi+":not(."+vs+" ):not(."+Vi+" ):not(."+Ao+" )");if(d(this.activeEle)||(this.activeEle.setAttribute("tabindex",this.getDataTabindex(this.activeEle)),t&&t.removeAttribute("tabindex"),t=this.activeEle),this.activeEle=e,"-1"===this.getDataTabindex(this.activeEle))if(d(this.trgtEle)&&!e.parentElement.classList.contains(uz)){if(!d(this.element.querySelector(".e-hor-nav"))&&this.element.querySelector(".e-hor-nav").classList.contains("e-nav-active")){this.updateTabIndex("0");var n="-1"===this.getDataTabindex(t)?"0":this.getDataTabindex(t);t.setAttribute("tabindex",n)}else this.updateTabIndex("-1");e.removeAttribute("tabindex")}else{var r=parseInt(this.getDataTabindex(this.activeEle),10)+1;this.activeEle.setAttribute("tabindex",r.toString())}},i.prototype.getPersistData=function(){return this.addOnPersist([])},i.prototype.getModuleName=function(){return"toolbar"},i.prototype.itemsRerender=function(e){this.items=this.tbarItemsCol,(this.isReact||this.isAngular)&&this.clearTemplate(),this.destroyMode(),this.destroyItems(),this.items=e,this.tbarItemsCol=this.items,this.renderItems(),this.renderOverflowMode(),this.isReact&&this.renderReactTemplates()},i.prototype.resize=function(){var e=this.element;this.tbResize=!0,this.tbarAlign&&this.itemPositioning(),this.popObj&&"Popup"===this.overflowMode&&this.popObj.hide();var t=this.checkOverflow(e,e.getElementsByClassName(Ti)[0]);if(!t){this.destroyScroll();var n=e.querySelector("."+Ti);d(n)||(this.remove(n,gz),this.tbarAlign&&this.add(n,Xr))}t&&this.scrollModule&&this.offsetWid===e.offsetWidth||((this.offsetWid>e.offsetWidth||t)&&this.renderOverflowMode(),this.popObj&&("Extended"===this.overflowMode&&(this.popObj.width=this.getToolbarPopupWidth(this.element)),this.tbarAlign&&this.removePositioning(),this.popupRefresh(this.popObj.element,!1),this.tbarAlign&&this.refreshPositioning()),this.element.querySelector("."+$E)&&(this.scrollStep=this.element.querySelector("."+$E).offsetWidth),this.offsetWid=e.offsetWidth,this.tbResize=!1,this.separator())},i.prototype.orientationChange=function(){var e=this;setTimeout(function(){e.resize()},500)},i.prototype.extendedOpen=function(){var e=this.element.querySelector("."+Rv);"Extended"===this.overflowMode&&e&&(this.isExtendedOpen=e.classList.contains(cz))},i.prototype.updateHideEleTabIndex=function(e,t,n,r,o){n&&(r=o.indexOf(e));for(var a=o[++r];a;){if(!this.eleContains(a)){var c=a.firstElementChild.getAttribute("data-tabindex");t&&"-1"===c?a.firstElementChild.setAttribute("tabindex","0"):c!==a.firstElementChild.getAttribute("tabindex")&&a.firstElementChild.setAttribute("tabindex",c);break}a=o[++r]}},i.prototype.clearToolbarTemplate=function(e){if(this.registeredTemplate&&this.registeredTemplate.template){for(var t=this.registeredTemplate,n=0;n0){var a=this.portals;for(n=0;n=0;a--)(o=s[a])&&(r=(n<3?o(r):n>3?o(i,e,r):o(i,e))||r);return n>3&&r&&Object.defineProperty(i,e,r),r},al="e-tab",Jn="e-tab-header",kt="e-content",Hv="e-nested",Ji="e-item",nD="e-template",Bv="e-rtl",ii="e-active",ya="e-disable",Di="e-hidden",sD="e-focused",rD="e-icons",oD="e-icon",Cz="e-icon-tab",aD="e-close-icon",Vv="e-close-show",Pp="e-tab-text",Uv="e-indicator",Sr="e-tab-wrap",Wv="e-text-wrap",Iz="e-tab-icon",Ys="e-toolbar-items",Et="e-toolbar-item",Ez="e-toolbar-pop",ba="e-toolbar-popup",Yv="e-progress",lD="e-overlay",cD="e-vertical-tab",uD="e-vertical",Dz="e-vertical-left",Sz="e-vertical-right",Nz="e-horizontal-bottom",hD="e-fill-mode",Tz="tabitem_",dD="e-reorder-active-item",wz=function(s){function i(){return null!==s&&s.apply(this,arguments)||this}return Rp(i,s),dt([m("SlideLeftIn")],i.prototype,"effect",void 0),dt([m(600)],i.prototype,"duration",void 0),dt([m("ease")],i.prototype,"easing",void 0),i}(Lt),TX=function(s){function i(){return null!==s&&s.apply(this,arguments)||this}return Rp(i,s),dt([di({effect:"SlideLeftIn",duration:600,easing:"ease"},wz)],i.prototype,"previous",void 0),dt([di({effect:"SlideRightIn",duration:600,easing:"ease"},wz)],i.prototype,"next",void 0),i}(Lt),wX=function(s){function i(){return null!==s&&s.apply(this,arguments)||this}return Rp(i,s),dt([m("")],i.prototype,"text",void 0),dt([m("")],i.prototype,"iconCss",void 0),dt([m("left")],i.prototype,"iconPosition",void 0),i}(Lt),AX=function(s){function i(){return null!==s&&s.apply(this,arguments)||this}return Rp(i,s),dt([di({},wX)],i.prototype,"header",void 0),dt([m(null)],i.prototype,"headerTemplate",void 0),dt([m("")],i.prototype,"content",void 0),dt([m("")],i.prototype,"cssClass",void 0),dt([m(!1)],i.prototype,"disabled",void 0),dt([m(!0)],i.prototype,"visible",void 0),dt([m()],i.prototype,"id",void 0),dt([m(-1)],i.prototype,"tabIndex",void 0),i}(Lt),LX=function(s){function i(e,t){var n=s.call(this,e,t)||this;return n.show={},n.hide={},n.maxHeight=0,n.title="Close",n.isInteracted=!1,n.lastIndex=0,n.isAdd=!1,n.isIconAlone=!1,n.draggableItems=[],n.resizeContext=n.refreshActiveTabBorder.bind(n),n.keyConfigs={tab:"tab",home:"home",end:"end",enter:"enter",space:"space",delete:"delete",moveLeft:"leftarrow",moveRight:"rightarrow",moveUp:"uparrow",moveDown:"downarrow"},n}return Rp(i,s),i.prototype.destroy=function(){if((this.isReact||this.isAngular)&&this.clearTemplate(),d(this.tbObj)||(this.tbObj.destroy(),this.tbObj=null),this.unWireEvents(),this.element.removeAttribute("aria-disabled"),this.expTemplateContent(),this.isTemplate){var e=S(".e-tab > ."+kt,this.element);this.element.classList.remove(nD),d(e)||(e.innerHTML=this.cnt)}else for(;this.element.firstElementChild;)Qe(this.element.firstElementChild);if(this.btnCls&&(this.btnCls=null),this.hdrEle=null,this.cntEle=null,this.tbItems=null,this.tbItem=null,this.tbPop=null,this.prevItem=null,this.popEle=null,this.bdrLine=null,this.content=null,this.dragItem=null,this.cloneElement=null,this.draggingItems=[],this.draggableItems&&this.draggableItems.length>0){for(var t=0;t0?"-"+this.element.id:Rk(),this.renderContainer(),this.wireEvents(),this.initRender=!1,this.isReact&&this.portals&&this.portals.length>0&&this.renderReactTemplates(function(){e.refreshOverflow(),e.refreshActiveBorder()})},i.prototype.renderContainer=function(){var e=this.element;if(this.items.forEach(function(r,o){d(r.id)&&!d(r.setProperties)&&r.setProperties({id:Tz+o.toString()},!0)}),this.items.length>0&&0===e.children.length)e.appendChild(this.createElement("div",{className:kt})),this.setOrientation(this.headerPlacement,this.createElement("div",{className:Jn})),this.isTemplate=!1;else if(this.element.children.length>0){this.isTemplate=!0,e.classList.add(nD);var t=e.querySelector("."+Jn);t&&"Bottom"===this.headerPlacement&&this.setOrientation(this.headerPlacement,t)}if(!d(S("."+Jn,this.element))&&!d(S("."+kt,this.element))){if(this.renderHeader(),this.tbItems=S("."+Jn+" ."+Ys,this.element),d(this.tbItems)||$n(this.tbItems,{selector:".e-tab-wrap"}),this.renderContent(),se("."+Et,this.element).length>0){this.tbItems=S("."+Jn+" ."+Ys,this.element),this.bdrLine=this.createElement("div",{className:Uv+" "+Di+" e-ignore"});var n=S("."+this.scrCntClass,this.tbItems);d(n)?this.tbItems.insertBefore(this.bdrLine,this.tbItems.firstChild):n.insertBefore(this.bdrLine,n.firstChild),this.setContentHeight(!0),this.select(this.selectedItem)}this.setRTL(this.enableRtl)}},i.prototype.renderHeader=function(){var e=this,t=this.headerPlacement,n=[];if(this.hdrEle=this.getTabHeader(),this.addVerticalClass(),this.isTemplate){this.element.children.length>1&&this.element.children[1].classList.contains(Jn)&&this.setProperties({headerPlacement:"Bottom"},!0);for(var r=this.hdrEle.children.length,o=[],a=0;a0){var l=this.createElement("div",{className:"e-items"});this.hdrEle.appendChild(l),o.forEach(function(u,h){e.lastIndex=h;var p={className:Ji,id:Ji+e.tabId+"_"+h},f=e.createElement("span",{className:Pp,attrs:{role:"presentation"}}).outerHTML,g=e.createElement("div",{className:Wv,innerHTML:f+e.btnCls.outerHTML}).outerHTML,v=e.createElement("div",{className:Sr,innerHTML:g,attrs:{role:"tab",tabIndex:"-1","aria-selected":"false","aria-controls":kt+e.tabId+"_"+h,"aria-disabled":"false"}});v.querySelector("."+Pp).appendChild(u),l.appendChild(e.createElement("div",p)),se("."+Ji,l)[h].appendChild(v)})}}else n=this.parseObject(this.items,0);this.tbObj=new cX({width:"Left"===t||"Right"===t?"auto":"100%",height:"Left"===t||"Right"===t?"100%":"auto",overflowMode:this.overflowMode,items:0!==n.length?n:[],clicked:this.clickHandler.bind(this),scrollStep:this.scrollStep,enableHtmlSanitizer:this.enableHtmlSanitizer,cssClass:this.cssClass}),this.tbObj.isStringTemplate=!0,this.tbObj.createElement=this.createElement,this.tbObj.appendTo(this.hdrEle),ge(this.hdrEle,{role:"tablist"}),d(this.element.getAttribute("aria-label"))?d(this.element.getAttribute("aria-labelledby"))||(this.hdrEle.setAttribute("aria-labelledby",this.element.getAttribute("aria-labelledby")),this.element.removeAttribute("aria-labelledby")):(this.hdrEle.setAttribute("aria-label",this.element.getAttribute("aria-label")),this.element.removeAttribute("aria-label")),this.setCloseButton(this.showCloseButton);var c=this.tbObj.element.querySelector("."+Ys);d(c)||(d(c.id)||""===c.id)&&(c.id=this.element.id+"_tab_header_items")},i.prototype.renderContent=function(){this.cntEle=S("."+kt,this.element);var e=se("."+Et,this.element);if(this.isTemplate){this.cnt=this.cntEle.children.length>0?this.cntEle.innerHTML:"";for(var t=this.cntEle.children,n=0;n=n&&(N([t.item(n)],Ji),ge(t.item(n),{role:"tabpanel","aria-labelledby":Ji+this.tabId+"_"+n}),t.item(n).id=kt+this.tabId+"_"+n)}},i.prototype.reRenderItems=function(){this.renderContainer(),d(this.cntEle)||(this.touchModule=new fs(this.cntEle,{swipe:this.swipeHandler.bind(this)}))},i.prototype.parseObject=function(e,t){var n=this,r=Array.prototype.slice.call(se(".e-tab-header ."+Et,this.element)),o=this.lastIndex;!this.isReplace&&r.length>0&&(o=this.getMaxIndicesFromItems(r));var l,a=[],c=[];return e.forEach(function(u,h){var p=d(u.header)||d(u.header.iconPosition)?"":u.header.iconPosition,f=d(u.header)||d(u.header.iconCss)?"":u.header.iconCss;if(d(u.headerTemplate)&&(d(u.header)||d(u.header.text)||0===u.header.text.length&&""===f))c.push(h);else{var v,g=u.headerTemplate||u.header.text;"string"==typeof g&&n.enableHtmlSanitizer&&(g=Qt.sanitize(g)),n.isReplace&&!d(n.tbId)&&""!==n.tbId?(v=parseInt(n.tbId.substring(n.tbId.lastIndexOf("_")+1),10),n.tbId=""):v=t+h,n.lastIndex=0===r.length?h:n.isReplace?v:o+1+h;var b=u.disabled?" "+ya+" "+lD:"",M=!1===u.visible?" "+Di:"";l=n.createElement("div",{className:Pp,attrs:{role:"presentation"}});var C=g instanceof Object?g.outerHTML:g,D=!d(C)&&""!==C;d(g.tagName)?n.headerTextCompile(l,g,h):l.appendChild(g);var k=n.createElement("span",{className:rD+" "+Iz+" "+oD+"-"+p+" "+f}),B=n.createElement("div",{className:Wv});B.appendChild(l),""!==g&&void 0!==g&&""!==f?("left"===p||"top"===p?B.insertBefore(k,B.firstElementChild):B.appendChild(k),n.isIconAlone=!1):(""===f?l:k)===k&&($(l),B.appendChild(k),n.isIconAlone=!0);var re=d(u.tabIndex)?"-1":u.tabIndex.toString(),le=u.disabled?{role:"tab","aria-disabled":"true"}:{tabIndex:re,"data-tabindex":re,role:"tab","aria-selected":"false","aria-disabled":"false"};B.appendChild(n.btnCls.cloneNode(!0));var Te=n.createElement("div",{className:Sr,attrs:le});Te.appendChild(B),n.itemIndexArray instanceof Array&&n.itemIndexArray.splice(t+h,0,Ji+n.tabId+"_"+n.lastIndex);var G={htmlAttributes:{id:Ji+n.tabId+"_"+n.lastIndex,"data-id":u.id},template:Te};G.cssClass=(void 0!==u.cssClass?u.cssClass:" ")+" "+b+" "+M+" "+(""!==f?"e-i"+p:"")+" "+(D?"":oD),("top"===p||"bottom"===p)&&n.element.classList.add("e-vertical-icon"),a.push(G),h++}}),this.isAdd||c.forEach(function(u){n.items.splice(u,1)}),this.isIconAlone?this.element.classList.add(Cz):this.element.classList.remove(Cz),a},i.prototype.removeActiveClass=function(){var e=this.getTabHeader();if(e){var t=se("."+Et+"."+ii,e);[].slice.call(t).forEach(function(n){return n.classList.remove(ii)}),[].slice.call(t).forEach(function(n){return n.firstElementChild.setAttribute("aria-selected","false")})}},i.prototype.checkPopupOverflow=function(e){this.tbPop=S("."+Ez,this.element);var t=S(".e-hor-nav",this.element),n=S("."+Ys,this.element),r=n.lastChild,o=!1;return(!this.isVertical()&&(this.enableRtl&&t.offsetLeft+t.offsetWidth>n.offsetLeft||!this.enableRtl&&t.offsetLeftthis.selectedItem&&!this.isPopup){var g=this.animation.previous.effect;f={name:"None"===g?"":"SlideLeftIn"!==g?g:"SlideLeftIn",duration:this.animation.previous.duration,timingFunction:this.animation.previous.easing}}else if(this.isPopup||this.prevIndex0)return e[0];var t=[].slice.call(this.element.children).filter(function(n){return!n.classList.contains("blazor-template")})[0];return t?[].slice.call(t.children).filter(function(n){return n.classList.contains(Jn)})[0]:void 0}},i.prototype.getEleIndex=function(e){return Array.prototype.indexOf.call(se("."+Et,this.getTabHeader()),e)},i.prototype.extIndex=function(e){return e.replace(Ji+this.tabId+"_","")},i.prototype.getMaxIndicesFromItems=function(e){var t=this,n=[];return e.forEach(function(r){n.push(t.getIndexFromEle(r.id))}),Math.max.apply(Math,n)},i.prototype.expTemplateContent=function(){var e=this;this.templateEle.forEach(function(t){d(e.element.querySelector(t))||(document.body.appendChild(e.element.querySelector(t)).style.display="none")})},i.prototype.templateCompile=function(e,t,n){var r=this.createElement("div");this.compileElement(r,t,"content",n),0!==r.childNodes.length&&e.appendChild(r),this.isReact&&this.renderReactTemplates()},i.prototype.compileElement=function(e,t,n,r){var o,a;"string"==typeof t?(t=t.trim(),this.isVue?o=oi(this.enableHtmlSanitizer?Qt.sanitize(t):t):e.innerHTML=this.enableHtmlSanitizer?Qt.sanitize(t):t):o=oi(t),d(o)||(a=o({},this,n)),!d(o)&&a.length>0&&[].slice.call(a).forEach(function(l){e.appendChild(l)})},i.prototype.headerTextCompile=function(e,t,n){this.compileElement(e,t,"headerTemplate",n)},i.prototype.getContent=function(e,t,n,r){var o;if("string"==typeof(t=d(t)?"":t)||d(t.innerHTML))if("string"==typeof t&&this.enableHtmlSanitizer&&(t=Qt.sanitize(t)),"."===t[0]||"#"===t[0])if(document.querySelectorAll(t).length){var a=document.querySelector(t);o=a.outerHTML.trim(),"clone"===n?e.appendChild(a.cloneNode(!0)):(e.appendChild(a),a.style.display="")}else this.templateCompile(e,t,r);else this.templateCompile(e,t,r);else e.appendChild(t);d(o)||-1===this.templateEle.indexOf(t.toString())&&this.templateEle.push(t.toString())},i.prototype.getTrgContent=function(e,t){return this.element.classList.contains(Hv)?S("."+Hv+"> ."+kt+" > #"+kt+this.tabId+"_"+t,this.element):this.findEle(e.children,kt+this.tabId+"_"+t)},i.prototype.findEle=function(e,t){for(var n,r=0;rn?this.element.appendChild(t):(R([t],[Nz]),this.element.insertBefore(t,S("."+kt,this.element)))},i.prototype.setCssClass=function(e,t,n){if(""!==t&&!d(t))for(var r=t.split(" "),o=0;o ."+Ji,this.element),r=0;r=0&&!t&&(this.allowServerDataBinding=!1,this.setProperties({selectedItem:e},!0),this.allowServerDataBinding=!0,this.initRender||this.serverDataBind()),r.classList.contains(ii))return void this.setActiveBorder();this.isTemplate||ge(r.firstElementChild,{"aria-controls":kt+this.tabId+"_"+e});var o=r.id;this.removeActiveClass(),r.classList.add(ii),r.firstElementChild.setAttribute("aria-selected","true");var a=Number(this.extIndex(o));if(d(this.prevActiveEle)&&(this.prevActiveEle=kt+this.tabId+"_"+a),this.isTemplate){if(S("."+kt,this.element).children.length>0){var l=this.findEle(S("."+kt,this.element).children,kt+this.tabId+"_"+a);d(l)||l.classList.add(ii),this.triggerAnimation(o,this.enableAnimation)}}else{this.cntEle=S(".e-tab > ."+kt,this.element);var c=this.getTrgContent(this.cntEle,this.extIndex(o));if(d(c)){this.cntEle.appendChild(this.createElement("div",{id:kt+this.tabId+"_"+this.extIndex(o),className:Ji+" "+ii,attrs:{role:"tabpanel","aria-labelledby":Ji+this.tabId+"_"+this.extIndex(o)}}));var u=this.getTrgContent(this.cntEle,this.extIndex(o)),h=Array.prototype.indexOf.call(this.itemIndexArray,o);this.getContent(u,this.items[h].content,"render",h)}else c.classList.add(ii);this.triggerAnimation(o,this.enableAnimation)}if(this.setActiveBorder(),this.refreshItemVisibility(r),!this.initRender&&!t){var p={previousItem:this.prevItem,previousIndex:this.prevIndex,selectedItem:r,selectedIndex:e,selectedContent:S("#"+kt+this.tabId+"_"+this.selectingID,this.content),isSwiped:this.isSwiped,isInteracted:n,preventFocus:!1};this.trigger("selected",p,function(f){f.preventFocus||r.firstElementChild.focus()})}}},i.prototype.setItems=function(e){this.isReplace=!0,this.tbItems=S("."+Ys,this.getTabHeader()),this.tbObj.items=this.parseObject(e,0),this.tbObj.dataBind(),this.isReplace=!1},i.prototype.setRTL=function(e){this.tbObj.enableRtl=e,this.tbObj.dataBind(),this.setCssClass(this.element,Bv,e),this.refreshActiveBorder()},i.prototype.refreshActiveBorder=function(){d(this.bdrLine)||this.bdrLine.classList.add(Di),this.setActiveBorder()},i.prototype.showPopup=function(e){var t=S(".e-popup.e-toolbar-pop",this.hdrEle);if(t&&t.classList.contains("e-popup-close")){var n=t&&t.ej2_instances[0];n.position.X="Left"===this.headerPlacement||this.element.classList.contains(Bv)?"left":"right",n.dataBind(),n.show(e)}},i.prototype.bindDraggable=function(){var e=this;if(this.allowDragAndDrop){var t=this.element.querySelector("."+Jn);t&&Array.prototype.slice.call(t.querySelectorAll("."+Et)).forEach(function(r){e.initializeDrag(r)})}},i.prototype.wireEvents=function(){this.bindDraggable(),window.addEventListener("resize",this.resizeContext),y.add(this.element,"mouseover",this.hoverHandler,this),y.add(this.element,"keydown",this.spaceKeyDown,this),d(this.cntEle)||(this.touchModule=new fs(this.cntEle,{swipe:this.swipeHandler.bind(this)})),this.keyModule=new ps(this.element,{keyAction:this.keyHandler.bind(this),keyConfigs:this.keyConfigs}),this.tabKeyModule=new ps(this.element,{keyAction:this.keyHandler.bind(this),keyConfigs:{openPopup:"shift+f10",tab:"tab",shiftTab:"shift+tab"},eventName:"keydown"})},i.prototype.unWireEvents=function(){d(this.keyModule)||this.keyModule.destroy(),d(this.tabKeyModule)||this.tabKeyModule.destroy(),!d(this.cntEle)&&!d(this.touchModule)&&(this.touchModule.destroy(),this.touchModule=null),window.removeEventListener("resize",this.resizeContext),y.remove(this.element,"mouseover",this.hoverHandler),y.remove(this.element,"keydown",this.spaceKeyDown),this.element.classList.remove(Bv),this.element.classList.remove(sD)},i.prototype.clickHandler=function(e){this.element.classList.remove(sD);var t=e.originalEvent.target,n=j(t,"."+Et),r=this.getEleIndex(n);t.classList.contains(aD)?this.removeTab(r):this.isVertical()&&j(t,".e-hor-nav")?this.showPopup(this.show):(this.isPopup=!1,!d(n)&&r!==this.selectedItem&&this.selectTab(r,e.originalEvent,!0))},i.prototype.swipeHandler=function(e){if(!(e.velocity<3&&d(e.originalEvent.changedTouches))){this.isNested&&this.element.setAttribute("data-swipe","true");var t=this.element.querySelector('[data-swipe="true"]');if(t)return void t.removeAttribute("data-swipe");if(this.isSwiped=!0,"Right"===e.swipeDirection&&0!==this.selectedItem){for(var n=this.selectedItem-1;n>=0;n--)if(!this.tbItem[n].classList.contains(Di)){this.selectTab(n,null,!0);break}}else if("Left"===e.swipeDirection&&this.selectedItem!==se("."+Et,this.element).length-1)for(var r=this.selectedItem+1;ra&&o>c&&(n.scrollLeft=r-(l-(c-r)))}},i.prototype.getIndexFromEle=function(e){return parseInt(e.substring(e.lastIndexOf("_")+1),10)},i.prototype.hoverHandler=function(e){var t=e.target;!d(t.classList)&&t.classList.contains(aD)&&t.setAttribute("title",new Br("tab",{closeButtonTitle:this.title},this.locale).getConstant("closeButtonTitle"))},i.prototype.evalOnPropertyChangeItems=function(e,t){var n=this;if(e.items instanceof Array&&t.items instanceof Array)if(this.lastIndex=0,d(this.tbObj))this.reRenderItems();else{(this.isReact||this.isAngular)&&this.clearTemplate(),this.setItems(e.items),this.templateEle.length>0&&this.expTemplateContent(),this.templateEle=[];for(var B=S(".e-tab > ."+kt,this.element);B.firstElementChild;)$(B.firstElementChild);this.select(this.selectedItem),this.draggableItems=[],this.bindDraggable()}else{for(var r=Object.keys(e.items),o=0;o0&&this.renderReactTemplates(function(){n.refreshActiveTabBorder()})}},i.prototype.clearTabTemplate=function(e,t,n){if(this.clearTemplates)if(this.registeredTemplate&&this.registeredTemplate[t]){for(var r=this.registeredTemplate,o=0;o0){var c=this.portals;for(o=0;ot.cloneElement.offsetLeft+t.cloneElement.offsetWidth&&(p.scrollLeft-=10),!d(h)&&Math.abs(h.offsetLeft+h.offsetWidth-t.cloneElement.offsetLeft)>h.offsetWidth/2&&(p.scrollLeft+=10)}t.cloneElement.style.pointerEvents="none",l=j(r.target,"."+Et+".e-draggable");var f=0;"Scrollable"===t.overflowMode&&!d(t.element.querySelector(".e-hscroll"))&&(f=t.element.querySelector(".e-hscroll-content").offsetWidth),null!=l&&!l.isSameNode(t.dragItem)&&l.closest("."+al).isSameNode(t.dragItem.closest("."+al))&&((a=t.getEleIndex(l))l.offsetWidth/2&&t.dragAction(l,o,a),a>o&&Math.abs(l.offsetWidth/2)+l.offsetLeft-f0){var r=this.draggingItems[t];this.draggingItems.splice(t,1),this.draggingItems.splice(n,0,r)}if("MultiRow"===this.overflowMode&&e.parentNode.insertBefore(this.dragItem,e.nextElementSibling),t>n)if(this.dragItem.parentElement.isSameNode(e.parentElement))this.dragItem.parentNode.insertBefore(this.dragItem,e);else if("Extended"===this.overflowMode)if(e.isSameNode(e.parentElement.lastChild)){var o=this.dragItem.parentNode;e.parentNode.insertBefore(this.dragItem,e),o.insertBefore(e.parentElement.lastChild,o.childNodes[0])}else this.dragItem.parentNode.insertBefore(e.parentElement.lastChild,this.dragItem.parentElement.childNodes[0]),e.parentNode.insertBefore(this.dragItem,e);else{var a=e.parentElement.lastChild;e.isSameNode(a)?(o=this.dragItem.parentNode,e.parentNode.insertBefore(this.dragItem,e),o.insertBefore(a,o.childNodes[0])):(this.dragItem.parentNode.insertBefore(e.parentElement.lastChild,this.dragItem.parentElement.childNodes[0]),e.parentNode.insertBefore(this.dragItem,e))}t0&&t.draggingItems.length>0?(t.items=t.draggingItems,t.selectedItem=d(t.droppedIndex)?t.getEleIndex(t.dragItem):t.droppedIndex,t.refresh()):(t.dragItem.querySelector("."+Sr).style.visibility="",R([t.tbItems.querySelector("."+Uv)],Di),t.droppedIndex=d(t.droppedIndex)?t.getEleIndex(t.dragItem):t.droppedIndex,t.selectTab(t.droppedIndex,null,!0))}),this.dragItem=null,this.droppedIndex=null},i.prototype.enableTab=function(e,t){var n=se("."+Et,this.element)[e];d(n)||(!0===t?(n.classList.remove(ya,lD),n.firstElementChild.setAttribute("tabindex",n.firstElementChild.getAttribute("data-tabindex"))):(n.classList.add(ya,lD),n.firstElementChild.removeAttribute("tabindex"),n.classList.contains(ii)&&this.select(e+1)),d(this.items[e])||(this.items[e].disabled=!t,this.dataBind()),n.firstElementChild.setAttribute("aria-disabled",!0===t?"false":"true"))},i.prototype.addTab=function(e,t){var n=this,r={addedItems:e,cancel:!1};if(this.isReplace)this.addingTabContent(e,t);else{for(var o=0,a=e;o0&&(t.draggableItems[e].destroy(),t.draggableItems[e]=null,t.draggableItems.splice(e,1)),n.classList.contains(ii)?(e=e>se("."+Et+":not(."+ba+")",t.element).length-1?e-1:e,t.enableAnimation=!1,t.tbItem=se("."+Et,t.getTabHeader()),e=t.getSelectingTabIndex(e),e=!isNaN(e)&&e>=0&&t.tbItem.length>e?e:0,t.selectedItem=e,t.select(e)):e!==t.selectedItem&&(e-1?e:t.selectedItem},!0),t.prevIndex=t.selectedItem),t.tbItem=se("."+Et,t.getTabHeader())),0===se("."+Et,t.element).length&&(t.hdrEle.style.display="none"),t.enableAnimation=!0}})},i.prototype.hideTab=function(e,t){var n,r=se("."+Et,this.element)[e];if(!d(r)){if(d(t)&&(t=!0),this.bdrLine.classList.add(Di),!0===t)if(r.classList.add(Di),0!==(n=se("."+Et+":not(."+Di+")",this.tbItems)).length&&r.classList.contains(ii)){if(0!==e)for(var o=e-1;o>=0;o--){if(!this.tbItem[o].classList.contains(Di)){this.select(o);break}if(0===o)for(var a=e+1;ae&&e>=0&&!isNaN(e))if(this.prevIndex=this.selectedItem,this.prevItem=this.tbItem[this.prevIndex],this.tbItem[e].classList.contains(ba)&&this.reorderActiveTab){if(this.setActive(this.popupHandler(this.tbItem[e]),null,t),!d(this.items)&&this.items.length>0&&this.allowDragAndDrop){this.tbItem=se("."+Ys+" ."+Et,this.hdrEle);var n=this.items[e];this.items.splice(e,1),this.items.splice(this.tbItem.length-1,0,n);var r=this.itemIndexArray[e];this.itemIndexArray.splice(e,1),this.itemIndexArray.splice(this.tbItem.length-1,0,r)}}else this.setActive(e,null,t);else this.setActive(0,null,t);else e instanceof HTMLElement&&this.setActive(this.getEleIndex(e),null,t)},i.prototype.getItemIndex=function(e){for(var t,n=0;n{class s extends pq{constructor(e){super(),this.viewContainerRef=e,Fk("currentInstance",this,this.viewContainerRef),this.registerEvents(bK),this.directivePropList=yK}}return s.\u0275fac=function(e){return new(e||s)(ue(cr))},s.\u0275dir=ut({type:s,selectors:[["e-tabitem"]],contentQueries:function(e,t,n){if(1&e&&(yu(n,pK,5),yu(n,vK,5),yu(n,fK,5)),2&e){let r;kl(r=jl())&&(t.content=r.first),kl(r=jl())&&(t.header_text=r.first),kl(r=jl())&&(t.headerTemplate=r.first)}},inputs:{content:"content",cssClass:"cssClass",disabled:"disabled",header:"header",headerTemplate:"headerTemplate",id:"id",tabIndex:"tabIndex",visible:"visible"},features:[ri]}),om([QC()],s.prototype,"content",void 0),om([QC()],s.prototype,"header_text",void 0),om([QC()],s.prototype,"headerTemplate",void 0),s})(),v_=(()=>{class s extends fq{constructor(){super("items")}}return s.\u0275fac=function(e){return new(e||s)},s.\u0275dir=ut({type:s,selectors:[["e-tabitems"]],contentQueries:function(e,t,n){if(1&e&&yu(n,m_,4),2&e){let r;kl(r=jl())&&(t.children=r)}},features:[ri]}),s})();const MK=["added","adding","created","destroyed","dragged","dragging","onDragStart","removed","removing","selected","selecting"],CK=[""];let IK=(()=>{let s=class extends LX{constructor(e,t,n,r){super(),this.ngEle=e,this.srenderer=t,this.viewContainerRef=n,this.injector=r,this.tags=["items"],this.element=this.ngEle.nativeElement,this.injectedModules=this.injectedModules||[],this.registerEvents(MK),this.addTwoWay.call(this,CK),Fk("currentInstance",this,this.viewContainerRef),this.containerContext=new Hk}ngOnInit(){this.containerContext.ngOnInit(this)}ngAfterViewInit(){this.containerContext.ngAfterViewInit(this)}ngOnDestroy(){this.containerContext.ngOnDestroy(this)}ngAfterContentChecked(){this.tagObjects[0].instance=this.childItems,this.containerContext.ngAfterContentChecked(this)}};return s.\u0275fac=function(e){return new(e||s)(ue(lr),ue(Fa),ue(cr),ue(Ks))},s.\u0275cmp=Py({type:s,selectors:[["ejs-tab"]],contentQueries:function(e,t,n){if(1&e&&yu(n,v_,5),2&e){let r;kl(r=jl())&&(t.childItems=r.first)}},inputs:{allowDragAndDrop:"allowDragAndDrop",animation:"animation",clearTemplates:"clearTemplates",cssClass:"cssClass",dragArea:"dragArea",enableHtmlSanitizer:"enableHtmlSanitizer",enablePersistence:"enablePersistence",enableRtl:"enableRtl",headerPlacement:"headerPlacement",height:"height",heightAdjustMode:"heightAdjustMode",items:"items",loadOn:"loadOn",locale:"locale",overflowMode:"overflowMode",reorderActiveTab:"reorderActiveTab",scrollStep:"scrollStep",selectedItem:"selectedItem",showCloseButton:"showCloseButton",width:"width"},outputs:{added:"added",adding:"adding",created:"created",destroyed:"destroyed",dragged:"dragged",dragging:"dragging",onDragStart:"onDragStart",removed:"removed",removing:"removing",selected:"selected",selecting:"selecting"},features:[ri],ngContentSelectors:mK,decls:1,vars:0,template:function(e,t){1&e&&(function tL(s){const i=te()[Zi][rs];if(!i.projection){const t=i.projection=function wf(s,i){const e=[];for(let t=0;t{class s{}return s.\u0275fac=function(e){return new(e||s)},s.\u0275mod=Cc({type:s}),s.\u0275inj=ml({imports:[[sY]]}),s})();const DK=["element"];!function S9(s){mr=s}(!0);let SK=(()=>{class s{constructor(){this.headerText=[{text:"Tab1"},{iconCss:"e-add-icon"}]}tabCreated(){new Pu({content:"Add Tab"}).appendTo(".e-ileft.e-icon"),document.getElementById("btn-add").onclick=t=>{let o={header:{text:document.getElementById("tab-title").value},content:_t("pre",{innerHTML:document.getElementById("tab-content").value.replace(/\n/g,"
\n")}).outerHTML};this.totalItems=document.querySelectorAll("#element .e-toolbar-item").length,this.tabInstance?.addTab([o],this.totalItems-1)}}tabSelected(e){e.selectedIndex===document.querySelectorAll("#element .e-toolbar-item").length-1&&(document.getElementById("tab-title").value="",document.getElementById("tab-content").value="")}static{this.\u0275fac=function(t){return new(t||s)}}static{this.\u0275cmp=Py({type:s,selectors:[["app-container"]],viewQuery:function(t,n){if(1&t&&function vL(s,i,e){const t=Yt();t.firstCreatePass&&(gL(t,new dL(s,i,e),-1),2==(2&i)&&(t.staticViewQueries=!0)),fL(t,te(),i)}(DK,5),2&t){let r;kl(r=jl())&&(n.tabInstance=r.first)}},standalone:!0,features:[FL],decls:5,vars:2,consts:[["id","element",3,"created","selected"],["element",""],["content","#tab1_content",3,"header"],["content","#form-container",3,"header"]],template:function(t,n){1&t&&(gd(0,"ejs-tab",0,1),dr("created",function(){return n.tabCreated()})("selected",function(o){return n.tabSelected(o)}),gd(2,"e-tabitems"),e0(3,"e-tabitem",2)(4,"e-tabitem",3),Sg()()),2&t&&(uM(3),Ig("header",n.headerText[0]),uM(),Ig("header",n.headerText[1]))},dependencies:[j8,EK,IK,m_,v_],encapsulation:2})}}return s})();uc(332),function GY(s,i){return SW({rootComponent:s,...wx(i)})}(SK).catch(s=>console.error(s))},332:()=>{!function(x){const V=x.performance;function ee(Gt){V&&V.mark&&V.mark(Gt)}function X(Gt,Pe){V&&V.measure&&V.measure(Gt,Pe)}ee("Zone");const ne=x.__Zone_symbol_prefix||"__zone_symbol__";function ce(Gt){return ne+Gt}const je=!0===x[ce("forceDuplicateZoneCheck")];if(x.Zone){if(je||"function"!=typeof x.Zone.__symbol__)throw new Error("Zone already loaded.");return x.Zone}let Le=(()=>{class Gt{static{this.__symbol__=ce}static assertZonePatched(){if(x.Promise!==sr.ZoneAwarePromise)throw new Error("Zone.js has detected that ZoneAwarePromise `(window|global).Promise` has been overwritten.\nMost likely cause is that a Promise polyfill has been loaded after Zone.js (Polyfilling Promise api is not necessary when zone.js is loaded. If you must load one, do so before loading zone.js.)")}static get root(){let E=Gt.current;for(;E.parent;)E=E.parent;return E}static get current(){return Ai.zone}static get currentTask(){return Cs}static __load_patch(E,W,Je=!1){if(sr.hasOwnProperty(E)){if(!Je&&je)throw Error("Already loaded patch: "+E)}else if(!x["__Zone_disable_"+E]){const bt="Zone:"+E;ee(bt),sr[E]=W(x,Gt,nn),X(bt,bt)}}get parent(){return this._parent}get name(){return this._name}constructor(E,W){this._parent=E,this._name=W?W.name||"unnamed":"",this._properties=W&&W.properties||{},this._zoneDelegate=new it(this,this._parent&&this._parent._zoneDelegate,W)}get(E){const W=this.getZoneWith(E);if(W)return W._properties[E]}getZoneWith(E){let W=this;for(;W;){if(W._properties.hasOwnProperty(E))return W;W=W._parent}return null}fork(E){if(!E)throw new Error("ZoneSpec required!");return this._zoneDelegate.fork(this,E)}wrap(E,W){if("function"!=typeof E)throw new Error("Expecting function got: "+E);const Je=this._zoneDelegate.intercept(this,E,W),bt=this;return function(){return bt.runGuarded(Je,this,arguments,W)}}run(E,W,Je,bt){Ai={parent:Ai,zone:this};try{return this._zoneDelegate.invoke(this,E,W,Je,bt)}finally{Ai=Ai.parent}}runGuarded(E,W=null,Je,bt){Ai={parent:Ai,zone:this};try{try{return this._zoneDelegate.invoke(this,E,W,Je,bt)}catch(wn){if(this._zoneDelegate.handleError(this,wn))throw wn}}finally{Ai=Ai.parent}}runTask(E,W,Je){if(E.zone!=this)throw new Error("A task can only be run in the zone of creation! (Creation: "+(E.zone||Tn).name+"; Execution: "+this.name+")");if(E.state===gi&&(E.type===Hn||E.type===ot))return;const bt=E.state!=Re;bt&&E._transitionTo(Re,mt),E.runCount++;const wn=Cs;Cs=E,Ai={parent:Ai,zone:this};try{E.type==ot&&E.data&&!E.data.isPeriodic&&(E.cancelFn=void 0);try{return this._zoneDelegate.invokeTask(this,E,W,Je)}catch(ve){if(this._zoneDelegate.handleError(this,ve))throw ve}}finally{E.state!==gi&&E.state!==Ae&&(E.type==Hn||E.data&&E.data.isPeriodic?bt&&E._transitionTo(mt,Re):(E.runCount=0,this._updateTaskCount(E,-1),bt&&E._transitionTo(gi,Re,gi))),Ai=Ai.parent,Cs=wn}}scheduleTask(E){if(E.zone&&E.zone!==this){let Je=this;for(;Je;){if(Je===E.zone)throw Error(`can not reschedule task to ${this.name} which is descendants of the original zone ${E.zone.name}`);Je=Je.parent}}E._transitionTo(Gi,gi);const W=[];E._zoneDelegates=W,E._zone=this;try{E=this._zoneDelegate.scheduleTask(this,E)}catch(Je){throw E._transitionTo(Ae,Gi,gi),this._zoneDelegate.handleError(this,Je),Je}return E._zoneDelegates===W&&this._updateTaskCount(E,1),E.state==Gi&&E._transitionTo(mt,Gi),E}scheduleMicroTask(E,W,Je,bt){return this.scheduleTask(new Fe(zt,E,W,Je,bt,void 0))}scheduleMacroTask(E,W,Je,bt,wn){return this.scheduleTask(new Fe(ot,E,W,Je,bt,wn))}scheduleEventTask(E,W,Je,bt,wn){return this.scheduleTask(new Fe(Hn,E,W,Je,bt,wn))}cancelTask(E){if(E.zone!=this)throw new Error("A task can only be cancelled in the zone of creation! (Creation: "+(E.zone||Tn).name+"; Execution: "+this.name+")");if(E.state===mt||E.state===Re){E._transitionTo(bi,mt,Re);try{this._zoneDelegate.cancelTask(this,E)}catch(W){throw E._transitionTo(Ae,bi),this._zoneDelegate.handleError(this,W),W}return this._updateTaskCount(E,-1),E._transitionTo(gi,bi),E.runCount=0,E}}_updateTaskCount(E,W){const Je=E._zoneDelegates;-1==W&&(E._zoneDelegates=null);for(let bt=0;btGt.hasTask(E,W),onScheduleTask:(Gt,Pe,E,W)=>Gt.scheduleTask(E,W),onInvokeTask:(Gt,Pe,E,W,Je,bt)=>Gt.invokeTask(E,W,Je,bt),onCancelTask:(Gt,Pe,E,W)=>Gt.cancelTask(E,W)};class it{constructor(Pe,E,W){this._taskCounts={microTask:0,macroTask:0,eventTask:0},this.zone=Pe,this._parentDelegate=E,this._forkZS=W&&(W&&W.onFork?W:E._forkZS),this._forkDlgt=W&&(W.onFork?E:E._forkDlgt),this._forkCurrZone=W&&(W.onFork?this.zone:E._forkCurrZone),this._interceptZS=W&&(W.onIntercept?W:E._interceptZS),this._interceptDlgt=W&&(W.onIntercept?E:E._interceptDlgt),this._interceptCurrZone=W&&(W.onIntercept?this.zone:E._interceptCurrZone),this._invokeZS=W&&(W.onInvoke?W:E._invokeZS),this._invokeDlgt=W&&(W.onInvoke?E:E._invokeDlgt),this._invokeCurrZone=W&&(W.onInvoke?this.zone:E._invokeCurrZone),this._handleErrorZS=W&&(W.onHandleError?W:E._handleErrorZS),this._handleErrorDlgt=W&&(W.onHandleError?E:E._handleErrorDlgt),this._handleErrorCurrZone=W&&(W.onHandleError?this.zone:E._handleErrorCurrZone),this._scheduleTaskZS=W&&(W.onScheduleTask?W:E._scheduleTaskZS),this._scheduleTaskDlgt=W&&(W.onScheduleTask?E:E._scheduleTaskDlgt),this._scheduleTaskCurrZone=W&&(W.onScheduleTask?this.zone:E._scheduleTaskCurrZone),this._invokeTaskZS=W&&(W.onInvokeTask?W:E._invokeTaskZS),this._invokeTaskDlgt=W&&(W.onInvokeTask?E:E._invokeTaskDlgt),this._invokeTaskCurrZone=W&&(W.onInvokeTask?this.zone:E._invokeTaskCurrZone),this._cancelTaskZS=W&&(W.onCancelTask?W:E._cancelTaskZS),this._cancelTaskDlgt=W&&(W.onCancelTask?E:E._cancelTaskDlgt),this._cancelTaskCurrZone=W&&(W.onCancelTask?this.zone:E._cancelTaskCurrZone),this._hasTaskZS=null,this._hasTaskDlgt=null,this._hasTaskDlgtOwner=null,this._hasTaskCurrZone=null;const Je=W&&W.onHasTask;(Je||E&&E._hasTaskZS)&&(this._hasTaskZS=Je?W:tt,this._hasTaskDlgt=E,this._hasTaskDlgtOwner=this,this._hasTaskCurrZone=Pe,W.onScheduleTask||(this._scheduleTaskZS=tt,this._scheduleTaskDlgt=E,this._scheduleTaskCurrZone=this.zone),W.onInvokeTask||(this._invokeTaskZS=tt,this._invokeTaskDlgt=E,this._invokeTaskCurrZone=this.zone),W.onCancelTask||(this._cancelTaskZS=tt,this._cancelTaskDlgt=E,this._cancelTaskCurrZone=this.zone))}fork(Pe,E){return this._forkZS?this._forkZS.onFork(this._forkDlgt,this.zone,Pe,E):new Le(Pe,E)}intercept(Pe,E,W){return this._interceptZS?this._interceptZS.onIntercept(this._interceptDlgt,this._interceptCurrZone,Pe,E,W):E}invoke(Pe,E,W,Je,bt){return this._invokeZS?this._invokeZS.onInvoke(this._invokeDlgt,this._invokeCurrZone,Pe,E,W,Je,bt):E.apply(W,Je)}handleError(Pe,E){return!this._handleErrorZS||this._handleErrorZS.onHandleError(this._handleErrorDlgt,this._handleErrorCurrZone,Pe,E)}scheduleTask(Pe,E){let W=E;if(this._scheduleTaskZS)this._hasTaskZS&&W._zoneDelegates.push(this._hasTaskDlgtOwner),W=this._scheduleTaskZS.onScheduleTask(this._scheduleTaskDlgt,this._scheduleTaskCurrZone,Pe,E),W||(W=E);else if(E.scheduleFn)E.scheduleFn(E);else{if(E.type!=zt)throw new Error("Task is missing scheduleFn.");gt(E)}return W}invokeTask(Pe,E,W,Je){return this._invokeTaskZS?this._invokeTaskZS.onInvokeTask(this._invokeTaskDlgt,this._invokeTaskCurrZone,Pe,E,W,Je):E.callback.apply(W,Je)}cancelTask(Pe,E){let W;if(this._cancelTaskZS)W=this._cancelTaskZS.onCancelTask(this._cancelTaskDlgt,this._cancelTaskCurrZone,Pe,E);else{if(!E.cancelFn)throw Error("Task is not cancelable");W=E.cancelFn(E)}return W}hasTask(Pe,E){try{this._hasTaskZS&&this._hasTaskZS.onHasTask(this._hasTaskDlgt,this._hasTaskCurrZone,Pe,E)}catch(W){this.handleError(Pe,W)}}_updateTaskCount(Pe,E){const W=this._taskCounts,Je=W[Pe],bt=W[Pe]=Je+E;if(bt<0)throw new Error("More tasks executed then were scheduled.");0!=Je&&0!=bt||this.hasTask(this.zone,{microTask:W.microTask>0,macroTask:W.macroTask>0,eventTask:W.eventTask>0,change:Pe})}}class Fe{constructor(Pe,E,W,Je,bt,wn){if(this._zone=null,this.runCount=0,this._zoneDelegates=null,this._state="notScheduled",this.type=Pe,this.source=E,this.data=Je,this.scheduleFn=bt,this.cancelFn=wn,!W)throw new Error("callback is not defined");this.callback=W;const ve=this;this.invoke=Pe===Hn&&Je&&Je.useG?Fe.invokeTask:function(){return Fe.invokeTask.call(x,ve,this,arguments)}}static invokeTask(Pe,E,W){Pe||(Pe=this),ns++;try{return Pe.runCount++,Pe.zone.runTask(Pe,E,W)}finally{1==ns&&xe(),ns--}}get zone(){return this._zone}get state(){return this._state}cancelScheduleRequest(){this._transitionTo(gi,Gi)}_transitionTo(Pe,E,W){if(this._state!==E&&this._state!==W)throw new Error(`${this.type} '${this.source}': can not transition to '${Pe}', expecting state '${E}'${W?" or '"+W+"'":""}, was '${this._state}'.`);this._state=Pe,Pe==gi&&(this._zoneDelegates=null)}toString(){return this.data&&typeof this.data.handleId<"u"?this.data.handleId.toString():Object.prototype.toString.call(this)}toJSON(){return{type:this.type,state:this.state,source:this.source,zone:this.zone.name,runCount:this.runCount}}}const Vt=ce("setTimeout"),St=ce("Promise"),Pt=ce("then");let Fn,yi=[],$t=!1;function zi(Gt){if(Fn||x[St]&&(Fn=x[St].resolve(0)),Fn){let Pe=Fn[Pt];Pe||(Pe=Fn.then),Pe.call(Fn,Gt)}else x[Vt](Gt,0)}function gt(Gt){0===ns&&0===yi.length&&zi(xe),Gt&&yi.push(Gt)}function xe(){if(!$t){for($t=!0;yi.length;){const Gt=yi;yi=[];for(let Pe=0;PeAi,onUnhandledError:Li,microtaskDrainDone:Li,scheduleMicroTask:gt,showUncaughtError:()=>!Le[ce("ignoreConsoleErrorUncaughtError")],patchEventTarget:()=>[],patchOnProperties:Li,patchMethod:()=>Li,bindArguments:()=>[],patchThen:()=>Li,patchMacroTask:()=>Li,patchEventPrototype:()=>Li,isIEOrEdge:()=>!1,getGlobalObjects:()=>{},ObjectDefineProperty:()=>Li,ObjectGetOwnPropertyDescriptor:()=>{},ObjectCreate:()=>{},ArraySlice:()=>[],patchClass:()=>Li,wrapWithCurrentZone:()=>Li,filterProperties:()=>[],attachOriginToPatched:()=>Li,_redefineProperty:()=>Li,patchCallbacks:()=>Li,nativeScheduleMicroTask:zi};let Ai={parent:null,zone:new Le(null,null)},Cs=null,ns=0;function Li(){}X("Zone","Zone"),x.Zone=Le}(globalThis);const Ro=Object.getOwnPropertyDescriptor,cc=Object.defineProperty,uc=Object.getPrototypeOf,hc=Object.create,gy=Array.prototype.slice,Xp="addEventListener",$i="removeEventListener",Po=Zone.__symbol__(Xp),Da=Zone.__symbol__($i),ts="true",ni="false",dc=Zone.__symbol__("");function fh(x,V){return Zone.current.wrap(x,V)}function Kp(x,V,ee,X,ne){return Zone.current.scheduleMacroTask(x,V,ee,X,ne)}const ci=Zone.__symbol__,Sa=typeof window<"u",Na=Sa?window:void 0,ln=Sa&&Na||globalThis,Jp="removeAttribute";function pc(x,V){for(let ee=x.length-1;ee>=0;ee--)"function"==typeof x[ee]&&(x[ee]=fh(x[ee],V+"_"+ee));return x}function gh(x){return!x||!1!==x.writable&&!("function"==typeof x.get&&typeof x.set>"u")}const mh=typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope,Ta=!("nw"in ln)&&typeof ln.process<"u"&&"[object process]"==={}.toString.call(ln.process),fc=!Ta&&!mh&&!(!Sa||!Na.HTMLElement),vh=typeof ln.process<"u"&&"[object process]"==={}.toString.call(ln.process)&&!mh&&!(!Sa||!Na.HTMLElement),zo={},wa=function(x){if(!(x=x||ln.event))return;let V=zo[x.type];V||(V=zo[x.type]=ci("ON_PROPERTY"+x.type));const ee=this||x.target||ln,X=ee[V];let ne;return fc&&ee===Na&&"error"===x.type?(ne=X&&X.call(this,x.message,x.filename,x.lineno,x.colno,x.error),!0===ne&&x.preventDefault()):(ne=X&&X.apply(this,arguments),null!=ne&&!ne&&x.preventDefault()),ne};function _o(x,V,ee){let X=Ro(x,V);if(!X&&ee&&Ro(ee,V)&&(X={enumerable:!0,configurable:!0}),!X||!X.configurable)return;const ne=ci("on"+V+"patched");if(x.hasOwnProperty(ne)&&x[ne])return;delete X.writable,delete X.value;const ce=X.get,je=X.set,Le=V.slice(2);let tt=zo[Le];tt||(tt=zo[Le]=ci("ON_PROPERTY"+Le)),X.set=function(it){let Fe=this;!Fe&&x===ln&&(Fe=ln),Fe&&("function"==typeof Fe[tt]&&Fe.removeEventListener(Le,wa),je&&je.call(Fe,null),Fe[tt]=it,"function"==typeof it&&Fe.addEventListener(Le,wa,!1))},X.get=function(){let it=this;if(!it&&x===ln&&(it=ln),!it)return null;const Fe=it[tt];if(Fe)return Fe;if(ce){let Vt=ce.call(this);if(Vt)return X.set.call(this,Vt),"function"==typeof it[Jp]&&it.removeAttribute(V),Vt}return null},cc(x,V,X),x[ne]=!0}function yh(x,V,ee){if(V)for(let X=0;Xfunction(je,Le){const tt=ee(je,Le);return tt.cbIdx>=0&&"function"==typeof Le[tt.cbIdx]?Kp(tt.name,Le[tt.cbIdx],tt,ne):ce.apply(je,Le)})}function Lr(x,V){x[ci("OriginalDelegate")]=V}let vy=!1,mc=!1;function yy(){if(vy)return mc;vy=!0;try{const x=Na.navigator.userAgent;(-1!==x.indexOf("MSIE ")||-1!==x.indexOf("Trident/")||-1!==x.indexOf("Edge/"))&&(mc=!0)}catch{}return mc}Zone.__load_patch("ZoneAwarePromise",(x,V,ee)=>{const X=Object.getOwnPropertyDescriptor,ne=Object.defineProperty,je=ee.symbol,Le=[],tt=!1!==x[je("DISABLE_WRAPPING_UNCAUGHT_PROMISE_REJECTION")],it=je("Promise"),Fe=je("then"),Vt="__creationTrace__";ee.onUnhandledError=ve=>{if(ee.showUncaughtError()){const pe=ve&&ve.rejection;pe?console.error("Unhandled Promise rejection:",pe instanceof Error?pe.message:pe,"; Zone:",ve.zone.name,"; Task:",ve.task&&ve.task.source,"; Value:",pe,pe instanceof Error?pe.stack:void 0):console.error(ve)}},ee.microtaskDrainDone=()=>{for(;Le.length;){const ve=Le.shift();try{ve.zone.runGuarded(()=>{throw ve.throwOriginal?ve.rejection:ve})}catch(pe){Pt(pe)}}};const St=je("unhandledPromiseRejectionHandler");function Pt(ve){ee.onUnhandledError(ve);try{const pe=V[St];"function"==typeof pe&&pe.call(this,ve)}catch{}}function yi(ve){return ve&&ve.then}function $t(ve){return ve}function Fn(ve){return E.reject(ve)}const zi=je("state"),gt=je("value"),xe=je("finally"),Tn=je("parentPromiseValue"),gi=je("parentPromiseState"),Gi="Promise.then",mt=null,Re=!0,bi=!1,Ae=0;function zt(ve,pe){return K=>{try{nn(ve,pe,K)}catch(Me){nn(ve,!1,Me)}}}const ot=function(){let ve=!1;return function(K){return function(){ve||(ve=!0,K.apply(null,arguments))}}},Hn="Promise resolved with itself",sr=je("currentTaskTrace");function nn(ve,pe,K){const Me=ot();if(ve===K)throw new TypeError(Hn);if(ve[zi]===mt){let Ge=null;try{("object"==typeof K||"function"==typeof K)&&(Ge=K&&K.then)}catch(Ee){return Me(()=>{nn(ve,!1,Ee)})(),ve}if(pe!==bi&&K instanceof E&&K.hasOwnProperty(zi)&&K.hasOwnProperty(gt)&&K[zi]!==mt)Cs(K),nn(ve,K[zi],K[gt]);else if(pe!==bi&&"function"==typeof Ge)try{Ge.call(K,Me(zt(ve,pe)),Me(zt(ve,!1)))}catch(Ee){Me(()=>{nn(ve,!1,Ee)})()}else{ve[zi]=pe;const Ee=ve[gt];if(ve[gt]=K,ve[xe]===xe&&pe===Re&&(ve[zi]=ve[gi],ve[gt]=ve[Tn]),pe===bi&&K instanceof Error){const Ve=V.currentTask&&V.currentTask.data&&V.currentTask.data[Vt];Ve&&ne(K,sr,{configurable:!0,enumerable:!1,writable:!0,value:Ve})}for(let Ve=0;Ve{try{const ze=ve[gt],Mt=!!K&&xe===K[xe];Mt&&(K[Tn]=ze,K[gi]=Ee);const Tt=pe.run(Ve,void 0,Mt&&Ve!==Fn&&Ve!==$t?[]:[ze]);nn(K,!0,Tt)}catch(ze){nn(K,!1,ze)}},K)}const Gt=function(){},Pe=x.AggregateError;class E{static toString(){return"function ZoneAwarePromise() { [native code] }"}static resolve(pe){return pe instanceof E?pe:nn(new this(null),Re,pe)}static reject(pe){return nn(new this(null),bi,pe)}static withResolvers(){const pe={};return pe.promise=new E((K,Me)=>{pe.resolve=K,pe.reject=Me}),pe}static any(pe){if(!pe||"function"!=typeof pe[Symbol.iterator])return Promise.reject(new Pe([],"All promises were rejected"));const K=[];let Me=0;try{for(let Ve of pe)Me++,K.push(E.resolve(Ve))}catch{return Promise.reject(new Pe([],"All promises were rejected"))}if(0===Me)return Promise.reject(new Pe([],"All promises were rejected"));let Ge=!1;const Ee=[];return new E((Ve,ze)=>{for(let Mt=0;Mt{Ge||(Ge=!0,Ve(Tt))},Tt=>{Ee.push(Tt),Me--,0===Me&&(Ge=!0,ze(new Pe(Ee,"All promises were rejected")))})})}static race(pe){let K,Me,Ge=new this((ze,Mt)=>{K=ze,Me=Mt});function Ee(ze){K(ze)}function Ve(ze){Me(ze)}for(let ze of pe)yi(ze)||(ze=this.resolve(ze)),ze.then(Ee,Ve);return Ge}static all(pe){return E.allWithCallback(pe)}static allSettled(pe){return(this&&this.prototype instanceof E?this:E).allWithCallback(pe,{thenCallback:Me=>({status:"fulfilled",value:Me}),errorCallback:Me=>({status:"rejected",reason:Me})})}static allWithCallback(pe,K){let Me,Ge,Ee=new this((Tt,Mi)=>{Me=Tt,Ge=Mi}),Ve=2,ze=0;const Mt=[];for(let Tt of pe){yi(Tt)||(Tt=this.resolve(Tt));const Mi=ze;try{Tt.then(Ze=>{Mt[Mi]=K?K.thenCallback(Ze):Ze,Ve--,0===Ve&&Me(Mt)},Ze=>{K?(Mt[Mi]=K.errorCallback(Ze),Ve--,0===Ve&&Me(Mt)):Ge(Ze)})}catch(Ze){Ge(Ze)}Ve++,ze++}return Ve-=2,0===Ve&&Me(Mt),Ee}constructor(pe){const K=this;if(!(K instanceof E))throw new Error("Must be an instanceof Promise.");K[zi]=mt,K[gt]=[];try{const Me=ot();pe&&pe(Me(zt(K,Re)),Me(zt(K,bi)))}catch(Me){nn(K,!1,Me)}}get[Symbol.toStringTag](){return"Promise"}get[Symbol.species](){return E}then(pe,K){let Me=this.constructor?.[Symbol.species];(!Me||"function"!=typeof Me)&&(Me=this.constructor||E);const Ge=new Me(Gt),Ee=V.current;return this[zi]==mt?this[gt].push(Ee,Ge,pe,K):ns(this,Ee,Ge,pe,K),Ge}catch(pe){return this.then(null,pe)}finally(pe){let K=this.constructor?.[Symbol.species];(!K||"function"!=typeof K)&&(K=E);const Me=new K(Gt);Me[xe]=xe;const Ge=V.current;return this[zi]==mt?this[gt].push(Ge,Me,pe,pe):ns(this,Ge,Me,pe,pe),Me}}E.resolve=E.resolve,E.reject=E.reject,E.race=E.race,E.all=E.all;const W=x[it]=x.Promise;x.Promise=E;const Je=je("thenPatched");function bt(ve){const pe=ve.prototype,K=X(pe,"then");if(K&&(!1===K.writable||!K.configurable))return;const Me=pe.then;pe[Fe]=Me,ve.prototype.then=function(Ge,Ee){return new E((ze,Mt)=>{Me.call(this,ze,Mt)}).then(Ge,Ee)},ve[Je]=!0}return ee.patchThen=bt,W&&(bt(W),io(x,"fetch",ve=>function wn(ve){return function(pe,K){let Me=ve.apply(pe,K);if(Me instanceof E)return Me;let Ge=Me.constructor;return Ge[Je]||bt(Ge),Me}}(ve))),Promise[V.__symbol__("uncaughtPromiseErrors")]=Le,E}),Zone.__load_patch("toString",x=>{const V=Function.prototype.toString,ee=ci("OriginalDelegate"),X=ci("Promise"),ne=ci("Error"),ce=function(){if("function"==typeof this){const it=this[ee];if(it)return"function"==typeof it?V.call(it):Object.prototype.toString.call(it);if(this===Promise){const Fe=x[X];if(Fe)return V.call(Fe)}if(this===Error){const Fe=x[ne];if(Fe)return V.call(Fe)}}return V.call(this)};ce[ee]=V,Function.prototype.toString=ce;const je=Object.prototype.toString;Object.prototype.toString=function(){return"function"==typeof Promise&&this instanceof Promise?"[object Promise]":je.call(this)}});let no=!1;if(typeof window<"u")try{const x=Object.defineProperty({},"passive",{get:function(){no=!0}});window.addEventListener("test",x,x),window.removeEventListener("test",x,x)}catch{no=!1}const HD={useG:!0},$s={},by={},nf=new RegExp("^"+dc+"(\\w+)(true|false)$"),My=ci("propagationStopped");function sf(x,V){const ee=(V?V(x):x)+ni,X=(V?V(x):x)+ts,ne=dc+ee,ce=dc+X;$s[x]={},$s[x][ni]=ne,$s[x][ts]=ce}function Cy(x,V,ee,X){const ne=X&&X.add||Xp,ce=X&&X.rm||$i,je=X&&X.listeners||"eventListeners",Le=X&&X.rmAll||"removeAllListeners",tt=ci(ne),it="."+ne+":",Fe="prependListener",Vt="."+Fe+":",St=function(gt,xe,Tn){if(gt.isRemoved)return;const gi=gt.callback;let Gi;"object"==typeof gi&&gi.handleEvent&&(gt.callback=Re=>gi.handleEvent(Re),gt.originalDelegate=gi);try{gt.invoke(gt,xe,[Tn])}catch(Re){Gi=Re}const mt=gt.options;return mt&&"object"==typeof mt&&mt.once&&xe[ce].call(xe,Tn.type,gt.originalDelegate?gt.originalDelegate:gt.callback,mt),Gi};function Pt(gt,xe,Tn){if(!(xe=xe||x.event))return;const gi=gt||xe.target||x,Gi=gi[$s[xe.type][Tn?ts:ni]];if(Gi){const mt=[];if(1===Gi.length){const Re=St(Gi[0],gi,xe);Re&&mt.push(Re)}else{const Re=Gi.slice();for(let bi=0;bi{throw bi})}}}const yi=function(gt){return Pt(this,gt,!1)},$t=function(gt){return Pt(this,gt,!0)};function Fn(gt,xe){if(!gt)return!1;let Tn=!0;xe&&void 0!==xe.useG&&(Tn=xe.useG);const gi=xe&&xe.vh;let Gi=!0;xe&&void 0!==xe.chkDup&&(Gi=xe.chkDup);let mt=!1;xe&&void 0!==xe.rt&&(mt=xe.rt);let Re=gt;for(;Re&&!Re.hasOwnProperty(ne);)Re=uc(Re);if(!Re&>[ne]&&(Re=gt),!Re||Re[tt])return!1;const bi=xe&&xe.eventNameToString,Ae={},zt=Re[tt]=Re[ne],ot=Re[ci(ce)]=Re[ce],Hn=Re[ci(je)]=Re[je],sr=Re[ci(Le)]=Re[Le];let nn;xe&&xe.prepend&&(nn=Re[ci(xe.prepend)]=Re[xe.prepend]);const E=Tn?function(K){if(!Ae.isExisting)return zt.call(Ae.target,Ae.eventName,Ae.capture?$t:yi,Ae.options)}:function(K){return zt.call(Ae.target,Ae.eventName,K.invoke,Ae.options)},W=Tn?function(K){if(!K.isRemoved){const Me=$s[K.eventName];let Ge;Me&&(Ge=Me[K.capture?ts:ni]);const Ee=Ge&&K.target[Ge];if(Ee)for(let Ve=0;Ve{ar.zone.cancelTask(ar)},{once:!0})),Ae.target=null,gl&&(gl.taskData=null),yc&&(yn.once=!0),!no&&"boolean"==typeof ar.options||(ar.options=yn),ar.target=Mt,ar.capture=Vo,ar.eventName=Tt,Ze&&(ar.originalDelegate=Mi),ze?or.unshift(ar):or.push(ar),Ve?Mt:void 0}};return Re[ne]=pe(zt,it,E,W,mt),nn&&(Re[Fe]=pe(nn,Vt,function(K){return nn.call(Ae.target,Ae.eventName,K.invoke,Ae.options)},W,mt,!0)),Re[ce]=function(){const K=this||x;let Me=arguments[0];xe&&xe.transferEventName&&(Me=xe.transferEventName(Me));const Ge=arguments[2],Ee=!!Ge&&("boolean"==typeof Ge||Ge.capture),Ve=arguments[1];if(!Ve)return ot.apply(this,arguments);if(gi&&!gi(ot,Ve,K,arguments))return;const ze=$s[Me];let Mt;ze&&(Mt=ze[Ee?ts:ni]);const Tt=Mt&&K[Mt];if(Tt)for(let Mi=0;Mifunction(ne,ce){ne[My]=!0,X&&X.apply(ne,ce)})}function Ey(x,V,ee,X,ne){const ce=Zone.__symbol__(X);if(V[ce])return;const je=V[ce]=V[X];V[X]=function(Le,tt,it){return tt&&tt.prototype&&ne.forEach(function(Fe){const Vt=`${ee}.${X}::`+Fe,St=tt.prototype;try{if(St.hasOwnProperty(Fe)){const Pt=x.ObjectGetOwnPropertyDescriptor(St,Fe);Pt&&Pt.value?(Pt.value=x.wrapWithCurrentZone(Pt.value,Vt),x._redefineProperty(tt.prototype,Fe,Pt)):St[Fe]&&(St[Fe]=x.wrapWithCurrentZone(St[Fe],Vt))}else St[Fe]&&(St[Fe]=x.wrapWithCurrentZone(St[Fe],Vt))}catch{}}),je.call(V,Le,tt,it)},x.attachOriginToPatched(V[X],je)}function Dy(x,V,ee){if(!ee||0===ee.length)return V;const X=ee.filter(ce=>ce.target===x);if(!X||0===X.length)return V;const ne=X[0].ignoreProperties;return V.filter(ce=>-1===ne.indexOf(ce))}function cn(x,V,ee,X){x&&yh(x,Dy(x,V,ee),X)}function vc(x){return Object.getOwnPropertyNames(x).filter(V=>V.startsWith("on")&&V.length>2).map(V=>V.substring(2))}Zone.__load_patch("util",(x,V,ee)=>{const X=vc(x);ee.patchOnProperties=yh,ee.patchMethod=io,ee.bindArguments=pc,ee.patchMacroTask=my;const ne=V.__symbol__("BLACK_LISTED_EVENTS"),ce=V.__symbol__("UNPATCHED_EVENTS");x[ce]&&(x[ne]=x[ce]),x[ne]&&(V[ne]=V[ce]=x[ne]),ee.patchEventPrototype=rf,ee.patchEventTarget=Cy,ee.isIEOrEdge=yy,ee.ObjectDefineProperty=cc,ee.ObjectGetOwnPropertyDescriptor=Ro,ee.ObjectCreate=hc,ee.ArraySlice=gy,ee.patchClass=gc,ee.wrapWithCurrentZone=fh,ee.filterProperties=Dy,ee.attachOriginToPatched=Lr,ee._redefineProperty=Object.defineProperty,ee.patchCallbacks=Ey,ee.getGlobalObjects=()=>({globalSources:by,zoneSymbolEventNames:$s,eventNames:X,isBrowser:fc,isMix:vh,isNode:Ta,TRUE_STR:ts,FALSE_STR:ni,ZONE_SYMBOL_PREFIX:dc,ADD_EVENT_LISTENER_STR:Xp,REMOVE_EVENT_LISTENER_STR:$i})});const is=ci("zoneTask");function Fo(x,V,ee,X){let ne=null,ce=null;ee+=X;const je={};function Le(it){const Fe=it.data;return Fe.args[0]=function(){return it.invoke.apply(this,arguments)},Fe.handleId=ne.apply(x,Fe.args),it}function tt(it){return ce.call(x,it.data.handleId)}ne=io(x,V+=X,it=>function(Fe,Vt){if("function"==typeof Vt[0]){const St={isPeriodic:"Interval"===X,delay:"Timeout"===X||"Interval"===X?Vt[1]||0:void 0,args:Vt},Pt=Vt[0];Vt[0]=function(){try{return Pt.apply(this,arguments)}finally{St.isPeriodic||("number"==typeof St.handleId?delete je[St.handleId]:St.handleId&&(St.handleId[is]=null))}};const yi=Kp(V,Vt[0],St,Le,tt);if(!yi)return yi;const $t=yi.data.handleId;return"number"==typeof $t?je[$t]=yi:$t&&($t[is]=yi),$t&&$t.ref&&$t.unref&&"function"==typeof $t.ref&&"function"==typeof $t.unref&&(yi.ref=$t.ref.bind($t),yi.unref=$t.unref.bind($t)),"number"==typeof $t||$t?$t:yi}return it.apply(x,Vt)}),ce=io(x,ee,it=>function(Fe,Vt){const St=Vt[0];let Pt;"number"==typeof St?Pt=je[St]:(Pt=St&&St[is],Pt||(Pt=St)),Pt&&"string"==typeof Pt.type?"notScheduled"!==Pt.state&&(Pt.cancelFn&&Pt.data.isPeriodic||0===Pt.runCount)&&("number"==typeof St?delete je[St]:St&&(St[is]=null),Pt.zone.cancelTask(Pt)):it.apply(x,Vt)})}Zone.__load_patch("legacy",x=>{const V=x[Zone.__symbol__("legacyPatch")];V&&V()}),Zone.__load_patch("timers",x=>{const V="set",ee="clear";Fo(x,V,ee,"Timeout"),Fo(x,V,ee,"Interval"),Fo(x,V,ee,"Immediate")}),Zone.__load_patch("requestAnimationFrame",x=>{Fo(x,"request","cancel","AnimationFrame"),Fo(x,"mozRequest","mozCancel","AnimationFrame"),Fo(x,"webkitRequest","webkitCancel","AnimationFrame")}),Zone.__load_patch("blocking",(x,V)=>{const ee=["alert","prompt","confirm"];for(let X=0;Xfunction(tt,it){return V.current.run(ce,x,it,Le)})}),Zone.__load_patch("EventTarget",(x,V,ee)=>{(function Ho(x,V){V.patchEventPrototype(x,V)})(x,ee),function af(x,V){if(Zone[V.symbol("patchEventTarget")])return;const{eventNames:ee,zoneSymbolEventNames:X,TRUE_STR:ne,FALSE_STR:ce,ZONE_SYMBOL_PREFIX:je}=V.getGlobalObjects();for(let tt=0;tt{gc("MutationObserver"),gc("WebKitMutationObserver")}),Zone.__load_patch("IntersectionObserver",(x,V,ee)=>{gc("IntersectionObserver")}),Zone.__load_patch("FileReader",(x,V,ee)=>{gc("FileReader")}),Zone.__load_patch("on_property",(x,V,ee)=>{!function bh(x,V){if(Ta&&!vh||Zone[x.symbol("patchEvents")])return;const ee=V.__Zone_ignore_on_properties;let X=[];if(fc){const ne=window;X=X.concat(["Document","SVGElement","Element","HTMLElement","HTMLBodyElement","HTMLMediaElement","HTMLFrameSetElement","HTMLFrameElement","HTMLIFrameElement","HTMLMarqueeElement","Worker"]);const ce=function tf(){try{const x=Na.navigator.userAgent;if(-1!==x.indexOf("MSIE ")||-1!==x.indexOf("Trident/"))return!0}catch{}return!1}()?[{target:ne,ignoreProperties:["error"]}]:[];cn(ne,vc(ne),ee&&ee.concat(ce),uc(ne))}X=X.concat(["XMLHttpRequest","XMLHttpRequestEventTarget","IDBIndex","IDBRequest","IDBOpenDBRequest","IDBDatabase","IDBTransaction","IDBCursor","WebSocket"]);for(let ne=0;ne{!function of(x,V){const{isBrowser:ee,isMix:X}=V.getGlobalObjects();(ee||X)&&x.customElements&&"customElements"in x&&V.patchCallbacks(V,x.customElements,"customElements","define",["connectedCallback","disconnectedCallback","adoptedCallback","attributeChangedCallback"])}(x,ee)}),Zone.__load_patch("XHR",(x,V)=>{!function tt(it){const Fe=it.XMLHttpRequest;if(!Fe)return;const Vt=Fe.prototype;let Pt=Vt[Po],yi=Vt[Da];if(!Pt){const Ae=it.XMLHttpRequestEventTarget;if(Ae){const zt=Ae.prototype;Pt=zt[Po],yi=zt[Da]}}const $t="readystatechange",Fn="scheduled";function zi(Ae){const zt=Ae.data,ot=zt.target;ot[ce]=!1,ot[Le]=!1;const Hn=ot[ne];Pt||(Pt=ot[Po],yi=ot[Da]),Hn&&yi.call(ot,$t,Hn);const sr=ot[ne]=()=>{if(ot.readyState===ot.DONE)if(!zt.aborted&&ot[ce]&&Ae.state===Fn){const Ai=ot[V.__symbol__("loadfalse")];if(0!==ot.status&&Ai&&Ai.length>0){const Cs=Ae.invoke;Ae.invoke=function(){const ns=ot[V.__symbol__("loadfalse")];for(let Li=0;Lifunction(Ae,zt){return Ae[X]=0==zt[2],Ae[je]=zt[1],Tn.apply(Ae,zt)}),Gi=ci("fetchTaskAborting"),mt=ci("fetchTaskScheduling"),Re=io(Vt,"send",()=>function(Ae,zt){if(!0===V.current[mt]||Ae[X])return Re.apply(Ae,zt);{const ot={target:Ae,url:Ae[je],isPeriodic:!1,args:zt,aborted:!1},Hn=Kp("XMLHttpRequest.send",gt,ot,zi,xe);Ae&&!0===Ae[Le]&&!ot.aborted&&Hn.state===Fn&&Hn.invoke()}}),bi=io(Vt,"abort",()=>function(Ae,zt){const ot=function St(Ae){return Ae[ee]}(Ae);if(ot&&"string"==typeof ot.type){if(null==ot.cancelFn||ot.data&&ot.data.aborted)return;ot.zone.cancelTask(ot)}else if(!0===V.current[Gi])return bi.apply(Ae,zt)})}(x);const ee=ci("xhrTask"),X=ci("xhrSync"),ne=ci("xhrListener"),ce=ci("xhrScheduled"),je=ci("xhrURL"),Le=ci("xhrErrorBeforeScheduled")}),Zone.__load_patch("geolocation",x=>{x.navigator&&x.navigator.geolocation&&function ef(x,V){const ee=x.constructor.name;for(let X=0;X{const tt=function(){return Le.apply(this,pc(arguments,ee+"."+ne))};return Lr(tt,Le),tt})(ce)}}}(x.navigator.geolocation,["getCurrentPosition","watchPosition"])}),Zone.__load_patch("PromiseRejectionEvent",(x,V)=>{function ee(X){return function(ne){Iy(x,X).forEach(je=>{const Le=x.PromiseRejectionEvent;if(Le){const tt=new Le(X,{promise:ne.promise,reason:ne.rejection});je.invoke(tt)}})}}x.PromiseRejectionEvent&&(V[ci("unhandledPromiseRejectionHandler")]=ee("unhandledrejection"),V[ci("rejectionHandledHandler")]=ee("rejectionhandled"))}),Zone.__load_patch("queueMicrotask",(x,V,ee)=>{!function Mh(x,V){V.patchMethod(x,"queueMicrotask",ee=>function(X,ne){Zone.current.scheduleMicroTask("queueMicrotask",ne[0])})}(x,ee)})}},Ro=>{Ro(Ro.s=145)}]); \ No newline at end of file diff --git a/ej2-angular/samples/tab/dynamic-tab-cs1/runtime.cf3bdadb8fd8abdc.js b/ej2-angular/samples/tab/dynamic-tab-cs1/runtime.cf3bdadb8fd8abdc.js new file mode 100644 index 0000000000..ac71653500 --- /dev/null +++ b/ej2-angular/samples/tab/dynamic-tab-cs1/runtime.cf3bdadb8fd8abdc.js @@ -0,0 +1 @@ +(()=>{"use strict";var e,v={},_={};function a(e){var f=_[e];if(void 0!==f)return f.exports;var r=_[e]={exports:{}};return v[e](r,r.exports,a),r.exports}a.m=v,e=[],a.O=(f,r,c,o)=>{if(!r){var u=1/0;for(n=0;n=o)&&Object.keys(a.O).every(h=>a.O[h](r[s]))?r.splice(s--,1):(t=!1,o0&&e[n-1][2]>o;n--)e[n]=e[n-1];e[n]=[r,c,o]},a.o=(e,f)=>Object.prototype.hasOwnProperty.call(e,f),(()=>{var e={666:0};a.O.j=c=>0===e[c];var f=(c,o)=>{var s,l,[n,u,t]=o,i=0;if(n.some(d=>0!==e[d])){for(s in u)a.o(u,s)&&(a.m[s]=u[s]);if(t)var p=t(a)}for(c&&c(o);i*{pointer-events:none}.e-hscroll>*{height:inherit;line-height:normal}.e-hscroll .e-hscroll-content{display:inline-block;height:inherit;position:relative}.e-hscroll .e-hscroll-content>*{pointer-events:auto}.e-hscroll.e-rtl .e-scroll-nav.e-scroll-right-nav{left:0;right:auto}.e-hscroll.e-rtl .e-scroll-nav.e-scroll-left-nav{left:auto;right:0}.e-hscroll .e-scroll-nav{align-items:center;bottom:0;cursor:pointer;display:flex;min-height:42px;overflow:hidden;position:absolute;top:0;width:40px}.e-hscroll .e-scroll-nav.e-scroll-left-nav{left:0}.e-hscroll .e-scroll-nav.e-scroll-right-nav{right:0}.e-hscroll .e-scroll-nav.e-ie-align{display:table}.e-hscroll .e-nav-arrow{position:relative}.e-hscroll .e-nav-arrow.e-icons{display:table-cell;text-align:center;vertical-align:middle;width:100%;font-size:12px}.e-hscroll .e-hscroll-bar .e-hscroll-content .e-overlay{pointer-events:none}/*! h-scroll theme */.e-hscroll .e-scroll-nav .e-icons{color:#0000008a}.e-hscroll.e-rtl.e-scroll-device .e-scroll-nav.e-scroll-right-nav{border-color:#0000001f;box-shadow:4px 0 8px #0000000f}.e-hscroll.e-scroll-device .e-scroll-nav.e-scroll-right-nav{background-color:#fafafa;border-color:#0000001f;border-width:1px;box-shadow:-4px 0 8px #0000000f}.e-hscroll.e-scroll-device .e-scroll-nav.e-scroll-right-nav .e-nav-arrow{color:#e3165b}.e-hscroll .e-scroll-overlay{background-color:transparent;background-repeat:repeat-x}.e-hscroll .e-scroll-overlay.e-scroll-left-overlay{background-image:linear-gradient(-270deg,#fafafa,#fafafa00)}.e-hscroll .e-scroll-overlay.e-scroll-right-overlay{background-image:linear-gradient(-270deg,#fafafa00,#fafafa)}.e-hscroll.e-rtl .e-scroll-nav{background:#fafafa}.e-hscroll.e-rtl .e-scroll-nav.e-scroll-left-nav{border-left:1px solid rgba(0,0,0,.12);border-right:0}.e-hscroll.e-rtl .e-scroll-nav.e-scroll-right-nav{border-left:0;border-right:1px solid rgba(0,0,0,.12)}.e-hscroll.e-rtl .e-scroll-nav:hover{background:#0000001f;border:0;color:#000}.e-hscroll.e-rtl .e-scroll-nav:hover:active{background:#0000001f}.e-hscroll:not(.e-scroll-device) .e-scroll-nav:hover{background:#0000001f;color:#000}.e-hscroll:not(.e-scroll-device) .e-scroll-nav:hover .e-icons{color:#0000008a}.e-hscroll:not(.e-scroll-device) .e-scroll-nav:focus{background:#0000001f;border:0;color:#000}.e-hscroll:not(.e-scroll-device) .e-scroll-nav:focus .e-icons{color:#0000008a}.e-hscroll:not(.e-scroll-device) .e-scroll-nav:active{background:#bdbdbd;border:0;box-shadow:none;color:#000}.e-hscroll:not(.e-scroll-device) .e-scroll-nav:active .e-icons{color:#0000008a}.e-hscroll .e-scroll-nav{background:#fafafa}.e-hscroll .e-scroll-nav.e-scroll-left-nav{border-right:1px solid rgba(0,0,0,.12)}.e-hscroll .e-scroll-nav.e-scroll-right-nav{border-left:1px solid rgba(0,0,0,.12)}.e-hscroll .e-scroll-nav:after{background-color:transparent;border-radius:50%;border-width:1px;box-sizing:border-box;content:"";height:1px;left:50%;position:absolute;top:50%;visibility:hidden;width:1px}.e-hscroll .e-scroll-nav:active:after{animation:hscroll-popup-shadow .6s ease-out 0ms;visibility:visible}.e-bigger .e-hscroll,.e-hscroll.e-bigger{min-height:56px}.e-bigger .e-hscroll:not(.e-scroll-device),.e-hscroll.e-bigger:not(.e-scroll-device){padding:0 50px}.e-bigger .e-hscroll.e-scroll-device,.e-hscroll.e-bigger.e-scroll-device{padding-right:50px}.e-bigger .e-hscroll.e-rtl.e-scroll-device,.e-hscroll.e-bigger.e-rtl.e-scroll-device{padding-left:50px;padding-right:initial}.e-bigger .e-hscroll .e-nav-arrow.e-icons,.e-hscroll.e-bigger .e-nav-arrow.e-icons{font-size:14px}.e-bigger .e-hscroll.e-rtl .e-scroll-overlay.e-scroll-right-overlay,.e-hscroll.e-bigger.e-rtl .e-scroll-overlay.e-scroll-right-overlay{left:50px}.e-bigger .e-hscroll .e-scroll-overlay.e-scroll-right-overlay,.e-hscroll.e-bigger .e-scroll-overlay.e-scroll-right-overlay{right:50px}.e-bigger .e-hscroll .e-scroll-nav,.e-hscroll.e-bigger .e-scroll-nav{min-height:56px;width:50px}@keyframes vscroll-popup-shadow{0%{border-color:#ffffff80;box-shadow:0 0 #ffffff80}to{box-shadow:0 0 0 200px #ffffff1f}}/*! vscroll icons */.e-vscroll.e-scroll-device .e-nav-up-arrow:before{content:"\e85e"}.e-vscroll.e-scroll-device .e-nav-down-arrow:before{content:"\e84f"}.e-vscroll .e-nav-up-arrow:before{content:"\e910";line-height:normal}.e-vscroll .e-nav-down-arrow:before{content:"\e916";line-height:normal}/*! v-scroll layout */.e-vscroll{display:block;position:relative;width:inherit}.e-vscroll.e-rtl.e-scroll-device .e-scroll-nav{transform:skew(-16deg) translate(-6px)}.e-vscroll.e-rtl.e-scroll-device .e-scroll-overlay.e-scroll-down-overlay{left:56px;right:auto;transform:skew(-16deg) translate(-6px)}.e-vscroll.e-rtl.e-scroll-device .e-scroll-overlay.e-scroll-up-overlay{left:auto;right:0}.e-vscroll:not(.e-scroll-device){padding:0 16px}.e-vscroll.e-scroll-device .e-scroll-nav{transform:skew(-16deg) translate(6px);width:56px;z-index:1001}.e-vscroll.e-scroll-device .e-scroll-nav .e-nav-arrow{font-size:14px;transform:skew(16deg)}.e-vscroll.e-scroll-device .e-scroll-overlay{opacity:.5;pointer-events:none;position:absolute;top:0;z-index:100}.e-vscroll.e-scroll-device .e-scroll-overlay.e-scroll-down-overlay{left:auto;right:56px;transform:skew(-16deg) translate(6px)}.e-vscroll.e-scroll-device .e-scroll-overlay.e-scroll-up-overlay{left:0;right:auto}.e-vscroll>*{height:inherit}.e-vscroll .e-vscroll-content{display:inline-block;height:auto;position:relative;width:100%}.e-vscroll .e-vscroll-content>*{pointer-events:auto}.e-vscroll.e-rtl .e-scroll-nav.e-scroll-up-nav{left:auto;right:0}.e-vscroll.e-rtl .e-scroll-nav.e-scroll-down-nav{left:0;right:auto}.e-vscroll .e-scroll-nav{align-items:center;cursor:pointer;display:flex;height:40px;overflow:hidden;position:absolute;width:100%}.e-vscroll .e-scroll-nav.e-scroll-up-nav{top:0}.e-vscroll .e-scroll-nav.e-scroll-down-nav{bottom:0}.e-vscroll .e-scroll-nav.e-ie-align{display:table}.e-vscroll .e-nav-arrow{position:relative}.e-vscroll .e-nav-arrow.e-icons{display:table-cell;text-align:center;vertical-align:middle;width:100%}/*! v-scroll theme */.e-vscroll .e-icons{color:#0000008a}.e-vscroll.e-rtl.e-scroll-device .e-scroll-nav.e-scroll-right-nav{border-color:#0000001f;box-shadow:4px 0 8px #0000000f}.e-vscroll.e-scroll-device .e-scroll-nav.e-scroll-right-nav{background-color:#fafafa;border-color:#0000001f;border-width:1px;box-shadow:-4px 0 8px #0000000f}.e-vscroll.e-scroll-device .e-scroll-nav.e-scroll-right-nav .e-nav-arrow{color:#e3165b}.e-vscroll .e-scroll-overlay{background-color:transparent;background-repeat:repeat-x}.e-vscroll .e-scroll-overlay.e-scroll-up-overlay{background-image:linear-gradient(-270deg,#fafafa,#fafafa00)}.e-vscroll .e-scroll-overlay.e-scroll-down-overlay{background-image:linear-gradient(-270deg,#fafafa00,#fafafa)}.e-vscroll.e-rtl .e-scroll-nav{background:#fafafa}.e-vscroll.e-rtl .e-scroll-nav:hover{background:#0000001f;border:0;border-color:#0000001f;color:#000}.e-vscroll:not(.e-scroll-device) .e-scroll-nav:hover{background:#0000001f;border:0;color:#000}.e-vscroll:not(.e-scroll-device) .e-scroll-nav:focus{background:#0000001f;border:0;border-color:#0000001f;color:#000}.e-vscroll:not(.e-scroll-device) .e-scroll-nav:active{background:#bdbdbd;border:0;box-shadow:none;color:#000}.e-vscroll .e-scroll-nav{background:#fafafa}.e-vscroll .e-scroll-nav.e-scroll-up-nav{border-bottom:1px solid rgba(0,0,0,.12)}.e-vscroll .e-scroll-nav.e-scroll-down-nav{border-top:1px solid rgba(0,0,0,.12)}.e-vscroll .e-scroll-nav:after{background-color:transparent;border-radius:50%;border-width:1px;box-sizing:border-box;content:"";height:1px;left:50%;position:absolute;top:50%;visibility:hidden;width:1px}.e-vscroll .e-scroll-nav:active:after{animation:vscroll-popup-shadow .6s ease-out 0ms;visibility:visible}.e-bigger .e-vscroll:not(.e-scroll-device),.e-vscroll.e-bigger:not(.e-scroll-device){padding:24px 0}.e-bigger .e-vscroll .e-icons,.e-vscroll.e-bigger .e-icons{font-size:18px}.e-bigger .e-vscroll.e-rtl .e-scroll-overlay.e-scroll-down-overlay,.e-vscroll.e-bigger.e-rtl .e-scroll-overlay.e-scroll-down-overlay{left:24px}.e-bigger .e-vscroll .e-scroll-overlay.e-scroll-down-overlay,.e-vscroll.e-bigger .e-scroll-overlay.e-scroll-down-overlay{right:24px}.e-bigger .e-vscroll .e-scroll-nav,.e-vscroll.e-bigger .e-scroll-nav{height:24px}.e-toolbar .e-popup-down-icon:before{content:"\e916";line-height:normal}.e-toolbar .e-popup-up-icon:before{content:"\e910";line-height:normal}.e-toolbar{border-radius:0;display:block;height:42px;min-height:42px;position:relative;-webkit-user-select:none;user-select:none;white-space:nowrap;overflow:hidden}.e-toolbar.e-spacer-toolbar .e-toolbar-items{display:flex;flex-wrap:nowrap;width:100%}.e-toolbar.e-spacer-toolbar .e-toolbar-items:not(.e-toolbar-multirow){position:absolute}.e-toolbar.e-spacer-toolbar.e-pop-mode .e-toolbar-items{width:calc(100% - 32px)}.e-toolbar .e-blazor-toolbar-items{position:absolute;top:-9999px;visibility:hidden}.e-toolbar.e-control[class*=e-toolbar]{box-sizing:content-box}.e-toolbar.e-corner{border-radius:0}.e-toolbar.e-hidden{display:none}.e-toolbar .e-toolbar-items{border-radius:0;display:inline-flex;height:100%;vertical-align:middle;align-items:center}.e-toolbar .e-toolbar-items.e-toolbar-multirow{margin-bottom:1px;margin-left:18px;margin-right:18px;white-space:normal;flex-wrap:wrap}.e-toolbar .e-toolbar-items.e-toolbar-multirow .e-toolbar-item:not(.e-separator){margin:0}.e-toolbar .e-toolbar-items.e-toolbar-multirow .e-toolbar-item.e-separator.e-multirow-separator,.e-toolbar .e-toolbar-items.e-toolbar-multirow .e-toolbar-item.e-separator.e-hidden{display:none}.e-toolbar .e-toolbar-items.e-multirow-pos .e-toolbar-left,.e-toolbar .e-toolbar-items.e-multirow-pos .e-toolbar-center,.e-toolbar .e-toolbar-items.e-multirow-pos .e-toolbar-right{display:inline}.e-toolbar .e-toolbar-items.e-tbar-pos{display:block}.e-toolbar .e-toolbar-items.e-tbar-pos .e-toolbar-left,.e-toolbar .e-toolbar-items.e-tbar-pos .e-toolbar-center,.e-toolbar .e-toolbar-items.e-tbar-pos .e-toolbar-right{display:table;height:100%;top:0}.e-toolbar .e-toolbar-items.e-tbar-pos .e-toolbar-right,.e-toolbar .e-toolbar-items.e-tbar-pos .e-toolbar-left{position:absolute}.e-toolbar .e-toolbar-items.e-tbar-pos .e-toolbar-right{right:0}.e-toolbar .e-toolbar-items.e-tbar-pos .e-toolbar-left{left:0}.e-toolbar .e-toolbar-items.e-tbar-pos .e-toolbar-center{margin:0 auto}.e-toolbar .e-toolbar-items .e-toolbar-left,.e-toolbar .e-toolbar-items .e-toolbar-center,.e-toolbar .e-toolbar-items .e-toolbar-right{display:inline-block}.e-toolbar .e-toolbar-items .e-toolbar-left .e-toolbar-item:first-child,.e-toolbar .e-toolbar-items:not(.e-tbar-pos):not(.e-toolbar-multirow) .e-toolbar-item:first-child{margin-left:3px}.e-toolbar .e-toolbar-items:first-child:not(.e-toolbar-multirow)>.e-toolbar-item:last-child,.e-toolbar .e-toolbar-items:first-child:not(.e-toolbar-multirow)>.e-toolbar-right .e-toolbar-item:last-child{margin-right:3px}.e-toolbar .e-toolbar-items .e-hscroll-bar .e-hscroll-content{touch-action:pan-y pinch-zoom}.e-toolbar .e-toolbar-items .e-hscroll-bar .e-hscroll-content>.e-toolbar-item:last-child{margin-right:3px}.e-toolbar .e-toolbar-items .e-hscroll-bar .e-hscroll-content .e-toolbar-center .e-toolbar-item,.e-toolbar .e-toolbar-items .e-hscroll-bar .e-hscroll-content .e-toolbar-right .e-toolbar-item{margin:0}.e-toolbar .e-toolbar-items .e-hscroll-bar .e-hscroll-content .e-toolbar-right .e-toolbar-item:last-child{margin-right:3px}.e-toolbar .e-toolbar-item{align-content:center;align-items:center;cursor:pointer;display:inline-flex;min-height:42px;vertical-align:middle;width:auto;flex:0 0 auto}.e-toolbar .e-toolbar-item.e-spacer{flex-grow:1}.e-toolbar .e-toolbar-item .e-tbar-btn{display:flex;align-items:center;vertical-align:middle;justify-content:center;margin:4px 0;min-height:0;min-width:0;padding:0 1.5px;border-radius:2px;line-height:25px;border:none;cursor:pointer;font-size:14px;font-weight:400;overflow:hidden;text-align:center;text-decoration:none;text-transform:none}.e-toolbar .e-toolbar-item .e-tbar-btn.e-tbtn-txt .e-icons.e-btn-icon,.e-toolbar .e-toolbar-item .e-tbar-btn.e-tbtn-txt .e-icons.e-btn-icon.e-icon-right{padding:0}.e-toolbar .e-toolbar-item .e-tbar-btn .e-icons.e-btn-icon{margin:0;min-width:24px;width:auto;font-size:14px;line-height:25px}.e-toolbar .e-toolbar-item .e-tbar-btn:hover,.e-toolbar .e-toolbar-item .e-tbar-btn:focus,.e-toolbar .e-toolbar-item .e-tbar-btn:active{padding:0 1.5px}.e-toolbar .e-toolbar-item .e-tbar-btn:focus{outline:0}.e-toolbar .e-toolbar-item .e-tbar-btn div{vertical-align:middle}.e-toolbar .e-toolbar-item .e-tbar-btn .e-tbar-btn-text{font-size:14px;padding:0 2px}.e-toolbar .e-toolbar-item:not(.e-separator):not(.e-spacer){height:inherit;min-width:34px;padding:3.5px}.e-toolbar .e-toolbar-item.e-separator{margin:7.5px 3px;min-height:27px;min-width:1px;height:calc(100% - 15px)}.e-toolbar .e-toolbar-item.e-separator+.e-separator,.e-toolbar .e-toolbar-item.e-separator:last-of-type,.e-toolbar .e-toolbar-item.e-separator:first-of-type{display:none}.e-toolbar .e-toolbar-item.e-popup-text .e-tbar-btn.e-btn.e-tbtn-txt .e-icons.e-btn-icon{padding:0}.e-toolbar .e-toolbar-item>*{text-overflow:ellipsis}.e-toolbar .e-toolbar-item.e-hidden{display:none}.e-toolbar .e-toolbar-item input[type=checkbox]{height:auto}.e-toolbar.e-vertical{display:flex;flex-direction:column}.e-toolbar.e-vertical .e-toolbar-items .e-vscroll-bar .e-vscroll-content{touch-action:pan-x pinch-zoom}.e-toolbar.e-vertical .e-toolbar-items.e-tbar-pos .e-toolbar-left,.e-toolbar.e-vertical .e-toolbar-items.e-tbar-pos .e-toolbar-center,.e-toolbar.e-vertical .e-toolbar-items.e-tbar-pos .e-toolbar-right{height:auto}.e-toolbar.e-vertical .e-toolbar-items.e-tbar-pos .e-toolbar-left{left:auto;right:auto;top:0}.e-toolbar.e-vertical .e-toolbar-items.e-tbar-pos .e-toolbar-right{bottom:0;left:auto;right:auto}.e-toolbar.e-vertical .e-toolbar-items:not(.e-tbar-pos) .e-toolbar-item:first-child{margin-left:0}.e-toolbar.e-vertical .e-toolbar-items:not(.e-tbar-pos) .e-toolbar-item:last-child{margin-right:0}.e-toolbar.e-vertical .e-toolbar-items .e-toolbar-item{display:flex;height:auto}.e-toolbar.e-vertical .e-toolbar-items .e-toolbar-item:not(.e-separator){min-width:33px}.e-toolbar.e-vertical .e-toolbar-items .e-toolbar-item.e-separator{height:auto;margin:3px 7.5px;min-height:auto}.e-toolbar.e-vertical .e-hor-nav{height:auto;inset:auto auto 0 0;min-height:40px;min-width:50px;width:auto}.e-toolbar.e-vertical.e-rtl.e-tbar-pos .e-toolbar-left{bottom:0;top:auto}.e-toolbar.e-vertical.e-rtl.e-tbar-pos .e-toolbar-right{bottom:auto;top:0}.e-toolbar .e-hor-nav{align-items:center;border-radius:0;cursor:pointer;display:flex;height:100%;min-height:42px;overflow:hidden;position:absolute;right:0;top:0;width:32px}.e-toolbar .e-hor-nav.e-ie-align{display:table}.e-toolbar .e-popup-down-icon.e-icons,.e-toolbar .e-popup-up-icon.e-icons{color:#0000008a;display:flex;text-align:center;vertical-align:middle;align-items:center;justify-content:center;width:100%;font-size:12px}.e-toolbar.e-toolpop{overflow:visible}.e-toolbar.e-toolpop .e-toolbar-items .e-toolbar-item.e-popup-text .e-tbar-btn-text{display:none}.e-toolbar .e-toolbar-pop{border-radius:0;overflow:hidden;padding:0;position:absolute}.e-toolbar .e-toolbar-pop .e-toolbar-item{display:flex;height:36px;justify-content:center;min-height:25px}.e-toolbar .e-toolbar-pop .e-toolbar-item.e-toolbar-popup.e-hidden{display:none}.e-toolbar .e-toolbar-pop .e-toolbar-item .e-tbar-btn.e-btn{min-height:25px;min-width:100%;padding:0 16px;border:none;border-radius:2px;justify-content:flex-start}.e-toolbar .e-toolbar-pop .e-toolbar-item .e-tbar-btn.e-btn .e-icons.e-btn-icon{margin:0;padding:0;width:auto}.e-toolbar .e-toolbar-pop .e-toolbar-item .e-tbar-btn.e-btn .e-tbar-btn-text{padding:0}.e-toolbar .e-toolbar-pop .e-toolbar-item:not(.e-separator){height:36px;min-width:34px;padding:0}.e-toolbar .e-toolbar-pop .e-toolbar-item>*{height:100%;min-width:100%;text-overflow:ellipsis}.e-toolbar .e-toolbar-pop .e-toolbar-item.e-tbtn-align .e-btn.e-control .e-icons.e-btn-icon{min-width:100%}.e-toolbar .e-toolbar-pop .e-toolbar-text .e-tbar-btn-text{display:none}.e-toolbar .e-toolbar-pop .e-toolbar-popup,.e-toolbar .e-toolbar-pop .e-toolpopup{text-align:center}.e-toolbar.e-extended-toolbar{overflow:visible}.e-toolbar.e-extended-toolbar.e-tbar-extended{border-bottom:0;border-bottom-left-radius:0;border-bottom-right-radius:0}.e-toolbar.e-extended-toolbar .e-toolbar-extended{border-top:0;border-top-left-radius:0;border-top-right-radius:0;min-height:42px;padding:0 3px;margin-left:-1px;box-shadow:none;display:inline;white-space:normal}.e-toolbar.e-extended-toolbar .e-toolbar-extended .e-toolbar-item{display:inline-flex;min-height:42px}.e-toolbar.e-extended-toolbar .e-toolbar-extended .e-toolbar-item .e-tbar-btn.e-btn,.e-toolbar.e-extended-toolbar .e-toolbar-extended .e-toolbar-item .e-tbar-btn.e-btn.e-control{min-height:0;min-width:0;padding:0 1.5px}.e-toolbar.e-extended-toolbar .e-toolbar-extended .e-toolbar-item .e-tbar-btn.e-btn .e-tbar-btn-text,.e-toolbar.e-extended-toolbar .e-toolbar-extended .e-toolbar-item .e-tbar-btn.e-btn.e-control .e-tbar-btn-text{padding:0 2px;font-size:14px}.e-toolbar.e-extended-toolbar .e-toolbar-extended .e-toolbar-item .e-tbar-btn.e-btn .e-icons.e-btn-icon:not(.e-toolbar-pop),.e-toolbar.e-extended-toolbar .e-toolbar-extended .e-toolbar-item .e-tbar-btn.e-btn.e-control .e-icons.e-btn-icon:not(.e-toolbar-pop){display:flex;align-items:center;vertical-align:middle;justify-content:center;padding:0;font-size:14px}.e-toolbar.e-extended-toolbar .e-toolbar-extended .e-toolbar-item .e-tbar-btn.e-btn.e-tbtn-txt .e-icons.e-btn-icon:not(.e-toolbar-pop),.e-toolbar.e-extended-toolbar .e-toolbar-extended .e-toolbar-item .e-tbar-btn.e-btn.e-control.e-tbtn-txt .e-icons.e-btn-icon:not(.e-toolbar-pop){padding:0}.e-toolbar.e-extended-toolbar .e-toolbar-extended .e-toolbar-item .e-tbar-btn.e-btn.e-tbtn-txt .e-icons.e-icon-right.e-btn-icon:not(.e-toolbar-pop),.e-toolbar.e-extended-toolbar .e-toolbar-extended .e-toolbar-item .e-tbar-btn.e-btn.e-control.e-tbtn-txt .e-icons.e-icon-right.e-btn-icon:not(.e-toolbar-pop){padding:0}.e-toolbar.e-extended-toolbar .e-toolbar-extended .e-toolbar-item .e-tbar-btn.e-btn:hover,.e-toolbar.e-extended-toolbar .e-toolbar-extended .e-toolbar-item .e-tbar-btn.e-btn:focus,.e-toolbar.e-extended-toolbar .e-toolbar-extended .e-toolbar-item .e-tbar-btn.e-btn:active,.e-toolbar.e-extended-toolbar .e-toolbar-extended .e-toolbar-item .e-tbar-btn.e-btn.e-control:hover,.e-toolbar.e-extended-toolbar .e-toolbar-extended .e-toolbar-item .e-tbar-btn.e-btn.e-control:focus,.e-toolbar.e-extended-toolbar .e-toolbar-extended .e-toolbar-item .e-tbar-btn.e-btn.e-control:active{padding:0 1.5px}.e-toolbar.e-extended-toolbar .e-toolbar-extended .e-toolbar-item:not(.e-separator){min-width:34px;padding:3.5px}.e-toolbar.e-extended-toolbar .e-toolbar-extended .e-toolbar-item.e-separator{min-height:25px}.e-toolbar.e-extended-toolbar .e-toolbar-extended .e-toolbar-item.e-separator.e-extended-separator,.e-toolbar.e-extended-toolbar .e-toolbar-extended .e-toolbar-item.e-toolbar-text .e-tbar-btn-text,.e-toolbar.e-extended-toolbar .e-toolbar-extended.e-popup-close{display:none}.e-toolbar.e-extended-toolbar .e-toolbar-extended.e-popup-open{display:inline}.e-toolbar.e-extended-toolbar .e-toolbar-extended.e-toolbar-pop{width:inherit}.e-toolbar.e-extended-toolbar .e-toolbar-extended.e-toolbar-pop .e-toolbar-item .e-tbar-btn{cursor:pointer;font-size:14px;overflow:hidden;padding:0 1.5px}.e-toolbar.e-extended-toolbar .e-toolbar-extended.e-toolbar-pop .e-toolbar-item .e-tbar-btn .e-icons.e-btn-icon{font-size:14px}.e-toolbar.e-extended-toolbar .e-toolbar-extended.e-toolbar-pop .e-toolbar-item:not(.e-separator){height:auto}.e-toolbar.e-extended-toolbar .e-toolbar-extended.e-toolbar-pop .e-toolbar-item>*{align-self:center;text-overflow:ellipsis}.e-toolbar.e-extended-toolbar .e-toolbar-items .e-toolbar-item.e-popup-text .e-tbar-btn-text{display:none}.e-toolbar.e-extended-toolbar .e-toolbar-items .e-toolbar-item.e-separator:last-of-type{display:inline-flex}.e-toolbar.e-extended-toolbar .e-hor-nav.e-ie-align{display:table}.e-toolbar.e-rtl:not(.e-spacer-toolbar) .e-toolbar-items:not(.e-tbar-pos) .e-toolbar-item:first-child{margin-right:3px}.e-toolbar.e-rtl .e-toolbar-item .e-tbar-btn.e-tbtn-txt .e-icons.e-btn-icon,.e-toolbar.e-rtl .e-toolbar-item .e-tbar-btn.e-tbtn-txt .e-icons.e-btn-icon.e-icon-right{padding:0}.e-toolbar.e-rtl .e-toolbar-item .e-tbar-btn .e-tbar-btn-text{padding:0 2px}.e-toolbar.e-rtl .e-hscroll-bar .e-hscroll-content>.e-toolbar-item:last-child{margin-left:3px;margin-right:initial}.e-toolbar.e-rtl .e-hscroll-bar .e-hscroll-content .e-toolbar-center .e-toolbar-item,.e-toolbar.e-rtl .e-hscroll-bar .e-hscroll-content .e-toolbar-right .e-toolbar-item{margin:0}.e-toolbar.e-rtl .e-hscroll-bar .e-hscroll-content .e-toolbar-right .e-toolbar-item:last-child{margin-right:3px}.e-toolbar.e-rtl .e-toolbar-items.e-tbar-pos .e-toolbar-left{left:auto;right:0}.e-toolbar.e-rtl .e-toolbar-items.e-tbar-pos .e-toolbar-right{left:0;right:auto}.e-toolbar.e-rtl .e-toolbar-items .e-toolbar-left .e-toolbar-item:first-child{margin-left:0}.e-toolbar.e-rtl .e-toolbar-items .e-toolbar-left .e-toolbar-item:last-child{margin-left:3px}.e-toolbar.e-rtl .e-toolbar-items:not(.e-tbar-pos) .e-toolbar-item:first-child{margin-left:0}.e-toolbar.e-rtl .e-toolbar-items:first-child>.e-toolbar-item:last-child:last-child,.e-toolbar.e-rtl .e-toolbar-items:first-child>.e-toolbar-right .e-toolbar-item:last-child{margin-right:0}.e-toolbar.e-rtl .e-toolbar-items:first-child>.e-toolbar-item:last-child:first-child,.e-toolbar.e-rtl .e-toolbar-items:first-child>.e-toolbar-right .e-toolbar-item:first-child{margin-right:3px}.e-toolbar.e-rtl .e-hor-nav{left:0;right:auto;border-radius:0}.e-toolbar.e-toolpop.e-rtl .e-toolbar-items:not(.e-tbar-pos) .e-toolbar-center .e-toolbar-item,.e-toolbar.e-toolpop.e-rtl .e-toolbar-items:not(.e-tbar-pos) .e-toolbar-right .e-toolbar-item{margin:0}.e-toolbar.e-toolpop.e-rtl .e-toolbar-items:not(.e-tbar-pos) .e-toolbar-right .e-toolbar-item:last-child{margin:0 0 0 3px}.e-toolbar.e-extended-toolbar.e-rtl .e-hor-nav{left:0;right:auto}.e-toolbar.e-extended-toolbar.e-rtl .e-toolbar-extended{padding-right:3px;margin-left:0}.e-toolbar.e-extended-toolbar.e-rtl .e-toolbar-extended .e-toolbar-item .e-tbar-btn.e-btn .e-icon-left{padding-left:0}.e-toolbar{-webkit-tap-highlight-color:rgba(0,0,0,0);background:#fafafa;border:1px none rgba(0,0,0,.12);box-shadow:none}.e-toolbar .e-toolbar-items{background:#fafafa}.e-toolbar .e-toolbar-item .e-tbar-btn{background:#fafafa;box-shadow:none;color:#000000de;border:none}.e-toolbar .e-toolbar-item .e-tbar-btn .e-icons{color:#0000008a}.e-toolbar .e-toolbar-item .e-tbar-btn .e-tbar-btn-text{color:#000000de}.e-toolbar .e-toolbar-item .e-tbar-btn.e-flat.e-active{background:#00000035;box-shadow:none}.e-toolbar .e-toolbar-item .e-tbar-btn.e-flat.e-active .e-tbar-btn-text{color:#000000de}.e-toolbar .e-toolbar-item .e-tbar-btn.e-flat.e-active:focus{box-shadow:none}.e-toolbar .e-toolbar-item .e-tbar-btn:focus{background:#0000001f;border-radius:2px;color:#000000de;border-color:#0000001f;border-style:solid;border-width:0;box-shadow:none}.e-toolbar .e-toolbar-item .e-tbar-btn:focus .e-icons{color:#0000008a}.e-toolbar .e-toolbar-item .e-tbar-btn:focus .e-tbar-btn-text{color:#000000de}.e-toolbar .e-toolbar-item .e-tbar-btn:hover{background:#0000001f;border-color:#0000001f;border-style:solid;border-width:0;border-radius:2px;color:#000000de}.e-toolbar .e-toolbar-item .e-tbar-btn:hover .e-icons{color:#0000008a}.e-toolbar .e-toolbar-item .e-tbar-btn:hover .e-tbar-btn-text{color:#000000de}.e-toolbar .e-toolbar-item .e-tbar-btn:hover:active .e-icons{color:#0000008a}.e-toolbar .e-toolbar-item .e-tbar-btn:hover:active .e-tbar-btn-text{color:#000000de}.e-toolbar .e-toolbar-item .e-tbar-btn:active{background:#bdbdbd;border-color:#bdbdbd;border-style:solid;border-width:0;border-radius:2px;box-shadow:none;color:#000000de}.e-toolbar .e-toolbar-item .e-tbar-btn:active .e-icons{color:#0000008a}.e-toolbar .e-toolbar-item .e-tbar-btn:active .e-tbar-btn-text{color:#000000de}.e-toolbar .e-toolbar-item.e-separator{border:solid rgba(0,0,0,.12);border-width:0 .5px 0 0}.e-toolbar .e-toolbar-item.e-overlay{background:#fafafa;opacity:.5;color:#00000042}.e-toolbar .e-toolbar-item.e-overlay .e-tbar-btn-text{color:#00000061}.e-toolbar .e-toolbar-item.e-overlay .e-icons{color:#00000042}.e-toolbar.e-vertical .e-hor-nav{border:solid rgba(0,0,0,.12);border-width:1px 0 0 0}.e-toolbar.e-vertical.e-rtl .e-hor-nav{border:solid rgba(0,0,0,.12);border-width:0 0 1px 0}.e-toolbar.e-vertical .e-toolbar-items .e-toolbar-item.e-separator{border-width:0 0 .5px 0}.e-toolbar .e-hor-nav{background:#fafafa;border:solid rgba(0,0,0,.12);border-width:0 0 0 1px}.e-toolbar .e-hor-nav:after{background-color:transparent;border-radius:50%;border-width:1px;box-sizing:border-box;content:"";height:1px;left:50%;position:absolute;top:50%;visibility:hidden;width:1px}.e-toolbar .e-hor-nav.e-nav-active:active,.e-toolbar .e-hor-nav.e-nav-active:focus,.e-toolbar .e-hor-nav.e-nav-active:hover{border-bottom-right-radius:0}.e-toolbar .e-hor-nav:active{border:0;box-shadow:none;color:#000000de;background:#fafafa}.e-toolbar .e-hor-nav:active .e-icons{color:#0000008a}.e-toolbar .e-hor-nav:active:after{animation:tbar-popup-shadow .6s ease-out 0ms;visibility:visible}.e-toolbar .e-hor-nav:hover{background:#0000001f;border-left:1px solid rgba(0,0,0,.12);color:#000000de}.e-toolbar .e-hor-nav:hover .e-icons{color:#0000008a}.e-toolbar .e-hor-nav:hover:not(.e-nav-active){border-color:#0000001f;border-style:solid;border-width:0 0 0 1px}.e-toolbar .e-hor-nav:hover:active{background:#0000001f;border-color:#0000001f;border-style:solid;border-width:0}.e-toolbar .e-hor-nav:focus{background:#0000001f;color:#000000de;border-color:#0000001f;border-style:solid;border-width:0}.e-toolbar .e-hor-nav:focus .e-icons{color:#0000008a}.e-toolbar.e-toolpop .e-hor-nav.e-nav-active,.e-toolbar.e-toolpop .e-hor-nav.e-nav-active:not(.e-expended-nav){background:#0000001f;box-shadow:none;border-color:#0000001f;border-style:solid;border-width:0}.e-toolbar.e-toolpop .e-hor-nav.e-nav-active:focus,.e-toolbar.e-toolpop .e-hor-nav.e-nav-active:not(.e-expended-nav):focus{border-color:#0000001f;border-style:solid;border-width:0}.e-toolbar.e-toolpop .e-hor-nav.e-nav-active .e-icons,.e-toolbar.e-toolpop .e-hor-nav.e-nav-active:not(.e-expended-nav) .e-icons{color:#000000de}.e-toolbar.e-toolpop .e-hor-nav.e-nav-active .e-icons:active,.e-toolbar.e-toolpop .e-hor-nav.e-nav-active:not(.e-expended-nav) .e-icons:active{color:#000000de}.e-toolbar .e-toolbar-pop{background:#fafafa;border:1px none rgba(0,0,0,.12);box-shadow:0 2px 2px 1px #00000036}.e-toolbar .e-toolbar-pop .e-toolbar-item .e-tbar-btn{background:#fafafa}.e-toolbar .e-toolbar-pop .e-toolbar-item .e-tbar-btn:hover{background:#0000001f;box-shadow:none;border-color:#0000001f;border-style:solid;border-width:0}.e-toolbar .e-toolbar-pop .e-toolbar-item .e-tbar-btn:active{background:#bdbdbd;box-shadow:none;border-color:#bdbdbd;border-style:solid;border-width:0}.e-toolbar .e-toolbar-pop .e-toolbar-item .e-tbar-btn:focus{background:#0000001f;border-color:#0000001f;border-style:solid;border-width:0;box-shadow:none}.e-toolbar .e-toolbar-pop .e-toolbar-item .e-btn:focus{outline:0}.e-toolbar .e-toolbar-pop .e-toolbar-item:not(.e-separator){background:transparent}.e-toolbar.e-extended-toolbar .e-toolbar-extended .e-toolbar-item .e-tbar-btn{background:#fafafa;box-shadow:none;border:none}.e-toolbar.e-extended-toolbar .e-toolbar-extended .e-toolbar-item .e-tbar-btn:focus{background:#0000001f;border-radius:2px;border-color:#0000001f;border-style:solid;border-width:0;box-shadow:none}.e-toolbar.e-extended-toolbar .e-toolbar-extended .e-toolbar-item .e-tbar-btn:hover{background:#0000001f;border-radius:2px;border-color:#0000001f;border-style:solid;border-width:0}.e-toolbar.e-extended-toolbar .e-toolbar-extended .e-toolbar-item .e-tbar-btn:active{background:#bdbdbd;border-radius:2px;box-shadow:none;border-color:#bdbdbd;border-style:solid;border-width:0}.e-toolbar.e-extended-toolbar .e-toolbar-extended .e-toolbar-item.e-separator{border:solid rgba(0,0,0,.12);border-width:0 .5px 0 0}.e-toolbar.e-extended-toolbar .e-toolbar-extended .e-toolbar-item.e-overlay,.e-toolbar.e-extended-toolbar .e-toolbar-pop{background:#fafafa}.e-toolbar.e-rtl .e-hor-nav{background:#fafafa;border:solid rgba(0,0,0,.12);border-width:0 1px 0 0}.e-toolbar.e-rtl .e-hor-nav:not(.e-nav-active):hover{background:#0000001f;color:#000000de;border:solid rgba(0,0,0,.12);border-width:0 1px 0 0}.e-bigger .e-toolbar,.e-toolbar.e-bigger{height:56px;min-height:56px}.e-bigger .e-toolbar .e-toolbar-items:not(.e-tbar-pos):not(.e-toolbar-multirow) .e-toolbar-item:first-child,.e-bigger .e-toolbar .e-toolbar-items .e-toolbar-left .e-toolbar-item:first-child,.e-toolbar.e-bigger .e-toolbar-items:not(.e-tbar-pos):not(.e-toolbar-multirow) .e-toolbar-item:first-child,.e-toolbar.e-bigger .e-toolbar-items .e-toolbar-left .e-toolbar-item:first-child{margin-left:3px}.e-bigger .e-toolbar .e-toolbar-items:first-child:not(.e-toolbar-multirow)>.e-toolbar-item:last-child,.e-bigger .e-toolbar .e-toolbar-items:first-child:not(.e-toolbar-multirow)>.e-toolbar-right .e-toolbar-item:last-child,.e-toolbar.e-bigger .e-toolbar-items:first-child:not(.e-toolbar-multirow)>.e-toolbar-item:last-child,.e-toolbar.e-bigger .e-toolbar-items:first-child:not(.e-toolbar-multirow)>.e-toolbar-right .e-toolbar-item:last-child{margin-right:3px}.e-bigger .e-toolbar .e-toolbar-items .e-hscroll-bar .e-hscroll-content>.e-toolbar-item:last-child,.e-toolbar.e-bigger .e-toolbar-items .e-hscroll-bar .e-hscroll-content>.e-toolbar-item:last-child{margin-right:3px}.e-bigger .e-toolbar .e-toolbar-items .e-hscroll-bar .e-hscroll-content .e-toolbar-right .e-toolbar-item:last-child,.e-toolbar.e-bigger .e-toolbar-items .e-hscroll-bar .e-hscroll-content .e-toolbar-right .e-toolbar-item:last-child{margin-right:3px}.e-bigger .e-toolbar .e-toolbar-items.e-toolbar-multirow,.e-toolbar.e-bigger .e-toolbar-items.e-toolbar-multirow{margin-left:24px;margin-right:24px}.e-bigger .e-toolbar .e-toolbar-items.e-toolbar-multirow .e-toolbar-item:not(.e-separator),.e-toolbar.e-bigger .e-toolbar-items.e-toolbar-multirow .e-toolbar-item:not(.e-separator){margin:0}.e-bigger .e-toolbar .e-toolbar-items .e-toolbar-item .e-tbar-btn.e-btn:focus,.e-bigger .e-toolbar .e-toolbar-items .e-toolbar-item .e-tbar-btn.e-btn:hover,.e-bigger .e-toolbar .e-toolbar-items .e-toolbar-item .e-tbar-btn.e-btn:active,.e-bigger .e-toolbar .e-toolbar-items .e-toolbar-item .e-tbar-btn.e-btn.e-control:focus,.e-bigger .e-toolbar .e-toolbar-items .e-toolbar-item .e-tbar-btn.e-btn.e-control:hover,.e-bigger .e-toolbar .e-toolbar-items .e-toolbar-item .e-tbar-btn.e-btn.e-control:active,.e-toolbar.e-bigger .e-toolbar-items .e-toolbar-item .e-tbar-btn.e-btn:focus,.e-toolbar.e-bigger .e-toolbar-items .e-toolbar-item .e-tbar-btn.e-btn:hover,.e-toolbar.e-bigger .e-toolbar-items .e-toolbar-item .e-tbar-btn.e-btn:active,.e-toolbar.e-bigger .e-toolbar-items .e-toolbar-item .e-tbar-btn.e-btn.e-control:focus,.e-toolbar.e-bigger .e-toolbar-items .e-toolbar-item .e-tbar-btn.e-btn.e-control:hover,.e-toolbar.e-bigger .e-toolbar-items .e-toolbar-item .e-tbar-btn.e-btn.e-control:active{padding:0 6px}.e-bigger .e-toolbar .e-toolbar-item,.e-toolbar.e-bigger .e-toolbar-item{min-height:56px}.e-bigger .e-toolbar .e-toolbar-item .e-tbar-btn.e-btn,.e-bigger .e-toolbar .e-toolbar-item .e-tbar-btn.e-btn.e-control,.e-toolbar.e-bigger .e-toolbar-item .e-tbar-btn.e-btn,.e-toolbar.e-bigger .e-toolbar-item .e-tbar-btn.e-btn.e-control{min-height:0;min-width:0;padding:0 6px;line-height:35px}.e-bigger .e-toolbar .e-toolbar-item .e-tbar-btn.e-btn .e-tbar-btn-text,.e-bigger .e-toolbar .e-toolbar-item .e-tbar-btn.e-btn.e-control .e-tbar-btn-text,.e-toolbar.e-bigger .e-toolbar-item .e-tbar-btn.e-btn .e-tbar-btn-text,.e-toolbar.e-bigger .e-toolbar-item .e-tbar-btn.e-btn.e-control .e-tbar-btn-text{padding:0 2.5px;font-size:14px}.e-bigger .e-toolbar .e-toolbar-item .e-tbar-btn.e-btn .e-icons,.e-bigger .e-toolbar .e-toolbar-item .e-tbar-btn.e-btn.e-control .e-icons,.e-toolbar.e-bigger .e-toolbar-item .e-tbar-btn.e-btn .e-icons,.e-toolbar.e-bigger .e-toolbar-item .e-tbar-btn.e-btn.e-control .e-icons{font-size:14px}.e-bigger .e-toolbar .e-toolbar-item .e-tbar-btn.e-btn .e-icons.e-btn-icon,.e-bigger .e-toolbar .e-toolbar-item .e-tbar-btn.e-btn.e-control .e-icons.e-btn-icon,.e-toolbar.e-bigger .e-toolbar-item .e-tbar-btn.e-btn .e-icons.e-btn-icon,.e-toolbar.e-bigger .e-toolbar-item .e-tbar-btn.e-btn.e-control .e-icons.e-btn-icon{font-size:14px;line-height:34px}.e-bigger .e-toolbar .e-toolbar-item .e-tbar-btn.e-btn.e-tbtn-txt .e-icons.e-btn-icon,.e-bigger .e-toolbar .e-toolbar-item .e-tbar-btn.e-btn.e-control.e-tbtn-txt .e-icons.e-btn-icon,.e-toolbar.e-bigger .e-toolbar-item .e-tbar-btn.e-btn.e-tbtn-txt .e-icons.e-btn-icon,.e-toolbar.e-bigger .e-toolbar-item .e-tbar-btn.e-btn.e-control.e-tbtn-txt .e-icons.e-btn-icon,.e-bigger .e-toolbar .e-toolbar-item .e-tbar-btn.e-btn.e-tbtn-txt .e-icons.e-icon-right.e-btn-icon,.e-bigger .e-toolbar .e-toolbar-item .e-tbar-btn.e-btn.e-control.e-tbtn-txt .e-icons.e-icon-right.e-btn-icon,.e-toolbar.e-bigger .e-toolbar-item .e-tbar-btn.e-btn.e-tbtn-txt .e-icons.e-icon-right.e-btn-icon,.e-toolbar.e-bigger .e-toolbar-item .e-tbar-btn.e-btn.e-control.e-tbtn-txt .e-icons.e-icon-right.e-btn-icon{padding:0}.e-bigger .e-toolbar .e-toolbar-item:not(.e-separator):not(.e-spacer),.e-toolbar.e-bigger .e-toolbar-item:not(.e-separator):not(.e-spacer){min-width:48px;padding:5px}.e-bigger .e-toolbar .e-toolbar-item.e-separator,.e-toolbar.e-bigger .e-toolbar-item.e-separator{height:calc(100% - 20px);margin:10px 5px;min-height:36px}.e-bigger .e-toolbar .e-toolbar-item.e-popup-text .e-tbar-btn.e-btn.e-tbtn-txt .e-icons.e-btn-icon,.e-bigger .e-toolbar .e-toolbar-item.e-popup-text .e-tbar-btn.e-btn.e-control.e-tbtn-txt .e-icons.e-btn-icon,.e-toolbar.e-bigger .e-toolbar-item.e-popup-text .e-tbar-btn.e-btn.e-tbtn-txt .e-icons.e-btn-icon,.e-toolbar.e-bigger .e-toolbar-item.e-popup-text .e-tbar-btn.e-btn.e-control.e-tbtn-txt .e-icons.e-btn-icon{padding:0}.e-bigger .e-toolbar .e-hor-nav,.e-toolbar.e-bigger .e-hor-nav{min-height:56px;min-width:40px}.e-bigger .e-toolbar.e-vertical .e-toolbar-items:not(.e-tbar-pos) .e-toolbar-item:first-child,.e-toolbar.e-bigger.e-vertical .e-toolbar-items:not(.e-tbar-pos) .e-toolbar-item:first-child{margin-left:0}.e-bigger .e-toolbar.e-vertical .e-toolbar-items:not(.e-tbar-pos) .e-toolbar-item:last-child,.e-toolbar.e-bigger.e-vertical .e-toolbar-items:not(.e-tbar-pos) .e-toolbar-item:last-child{margin-right:0}.e-bigger .e-toolbar.e-vertical .e-toolbar-item:not(.e-separator),.e-toolbar.e-bigger.e-vertical .e-toolbar-item:not(.e-separator){min-height:38px}.e-bigger .e-toolbar.e-vertical .e-toolbar-item.e-separator,.e-toolbar.e-bigger.e-vertical .e-toolbar-item.e-separator{height:auto;margin:5px 10px;min-height:auto}.e-bigger .e-toolbar.e-vertical .e-hor-nav,.e-toolbar.e-bigger.e-vertical .e-hor-nav{min-height:40px;min-width:50px}.e-bigger .e-toolbar .e-toolbar-pop .e-toolbar-item,.e-toolbar.e-bigger .e-toolbar-pop .e-toolbar-item{height:48px}.e-bigger .e-toolbar .e-toolbar-pop .e-toolbar-item:not(.e-separator),.e-toolbar.e-bigger .e-toolbar-pop .e-toolbar-item:not(.e-separator){min-width:48px;padding:0;min-height:30px}.e-bigger .e-toolbar .e-toolbar-pop .e-toolbar-item .e-tbar-btn.e-btn,.e-toolbar.e-bigger .e-toolbar-pop .e-toolbar-item .e-tbar-btn.e-btn{min-height:30px;padding:0 16px;min-width:100%}.e-bigger .e-toolbar .e-toolbar-pop .e-toolbar-item .e-tbar-btn.e-btn .e-icons.e-btn-icon,.e-toolbar.e-bigger .e-toolbar-pop .e-toolbar-item .e-tbar-btn.e-btn .e-icons.e-btn-icon{margin-left:0;padding:0;font-size:14px}.e-bigger .e-toolbar .e-toolbar-pop .e-toolbar-item .e-tbar-btn.e-btn .e-tbar-btn-text,.e-toolbar.e-bigger .e-toolbar-pop .e-toolbar-item .e-tbar-btn.e-btn .e-tbar-btn-text{padding:0;font-size:14px}.e-bigger .e-toolbar.e-extended-toolbar .e-toolbar-extended,.e-toolbar.e-bigger.e-extended-toolbar .e-toolbar-extended{min-height:56px;padding:0 3px}.e-bigger .e-toolbar.e-extended-toolbar .e-toolbar-extended .e-toolbar-item,.e-toolbar.e-bigger.e-extended-toolbar .e-toolbar-extended .e-toolbar-item{min-height:56px}.e-bigger .e-toolbar.e-extended-toolbar .e-toolbar-extended .e-toolbar-item .e-tbar-btn.e-btn,.e-bigger .e-toolbar.e-extended-toolbar .e-toolbar-extended .e-toolbar-item .e-tbar-btn.e-btn.e-control,.e-toolbar.e-bigger.e-extended-toolbar .e-toolbar-extended .e-toolbar-item .e-tbar-btn.e-btn,.e-toolbar.e-bigger.e-extended-toolbar .e-toolbar-extended .e-toolbar-item .e-tbar-btn.e-btn.e-control{min-height:0;min-width:0;padding:0 6px}.e-bigger .e-toolbar.e-extended-toolbar .e-toolbar-extended .e-toolbar-item .e-tbar-btn.e-btn .e-tbar-btn-text,.e-bigger .e-toolbar.e-extended-toolbar .e-toolbar-extended .e-toolbar-item .e-tbar-btn.e-btn.e-control .e-tbar-btn-text,.e-toolbar.e-bigger.e-extended-toolbar .e-toolbar-extended .e-toolbar-item .e-tbar-btn.e-btn .e-tbar-btn-text,.e-toolbar.e-bigger.e-extended-toolbar .e-toolbar-extended .e-toolbar-item .e-tbar-btn.e-btn.e-control .e-tbar-btn-text{padding:0 2.5px}.e-bigger .e-toolbar.e-extended-toolbar .e-toolbar-extended .e-toolbar-item .e-tbar-btn.e-btn:hover,.e-bigger .e-toolbar.e-extended-toolbar .e-toolbar-extended .e-toolbar-item .e-tbar-btn.e-btn:focus,.e-bigger .e-toolbar.e-extended-toolbar .e-toolbar-extended .e-toolbar-item .e-tbar-btn.e-btn:active,.e-bigger .e-toolbar.e-extended-toolbar .e-toolbar-extended .e-toolbar-item .e-tbar-btn.e-btn.e-control:hover,.e-bigger .e-toolbar.e-extended-toolbar .e-toolbar-extended .e-toolbar-item .e-tbar-btn.e-btn.e-control:focus,.e-bigger .e-toolbar.e-extended-toolbar .e-toolbar-extended .e-toolbar-item .e-tbar-btn.e-btn.e-control:active,.e-toolbar.e-bigger.e-extended-toolbar .e-toolbar-extended .e-toolbar-item .e-tbar-btn.e-btn:hover,.e-toolbar.e-bigger.e-extended-toolbar .e-toolbar-extended .e-toolbar-item .e-tbar-btn.e-btn:focus,.e-toolbar.e-bigger.e-extended-toolbar .e-toolbar-extended .e-toolbar-item .e-tbar-btn.e-btn:active,.e-toolbar.e-bigger.e-extended-toolbar .e-toolbar-extended .e-toolbar-item .e-tbar-btn.e-btn.e-control:hover,.e-toolbar.e-bigger.e-extended-toolbar .e-toolbar-extended .e-toolbar-item .e-tbar-btn.e-btn.e-control:focus,.e-toolbar.e-bigger.e-extended-toolbar .e-toolbar-extended .e-toolbar-item .e-tbar-btn.e-btn.e-control:active{padding:0 6px}.e-bigger .e-toolbar.e-extended-toolbar .e-toolbar-extended .e-toolbar-item:not(.e-separator),.e-toolbar.e-bigger.e-extended-toolbar .e-toolbar-extended .e-toolbar-item:not(.e-separator){min-width:48px;padding:5px}.e-bigger .e-toolbar.e-extended-toolbar .e-toolbar-extended .e-toolbar-item.e-separator,.e-toolbar.e-bigger.e-extended-toolbar .e-toolbar-extended .e-toolbar-item.e-separator{height:calc(100% - 20px);margin:10px 5px;min-height:36px}.e-bigger .e-toolbar.e-extended-toolbar.e-tbar-extended,.e-toolbar.e-bigger.e-extended-toolbar.e-tbar-extended{border-bottom:0;border-bottom-left-radius:0;border-bottom-right-radius:0}.e-bigger .e-toolbar.e-extended-toolbar.e-tbar-extended .e-toolbar-extended,.e-toolbar.e-bigger.e-extended-toolbar.e-tbar-extended .e-toolbar-extended{border-top:0;border-top-left-radius:0;border-top-right-radius:0}.e-bigger .e-toolbar.e-rtl .e-toolbar-item .e-tbar-btn.e-btn.e-tbtn-txt .e-icons.e-btn-icon,.e-toolbar.e-bigger.e-rtl .e-toolbar-item .e-tbar-btn.e-btn.e-tbtn-txt .e-icons.e-btn-icon,.e-bigger .e-toolbar.e-rtl .e-toolbar-item .e-tbar-btn.e-btn.e-tbtn-txt .e-icons.e-btn-icon.e-icon-right,.e-toolbar.e-bigger.e-rtl .e-toolbar-item .e-tbar-btn.e-btn.e-tbtn-txt .e-icons.e-btn-icon.e-icon-right{padding:0}.e-bigger .e-toolbar.e-rtl .e-toolbar-item .e-tbar-btn.e-btn .e-tbar-btn-text,.e-toolbar.e-bigger.e-rtl .e-toolbar-item .e-tbar-btn.e-btn .e-tbar-btn-text{padding:0 2.5px}.e-bigger .e-toolbar.e-rtl .e-toolbar-items .e-hscroll-bar .e-hscroll-content>.e-toolbar-item:last-child,.e-toolbar.e-bigger.e-rtl .e-toolbar-items .e-hscroll-bar .e-hscroll-content>.e-toolbar-item:last-child{margin-left:3px;margin-right:initial}.e-bigger .e-toolbar.e-rtl .e-toolbar-items .e-hscroll-bar .e-hscroll-content .e-toolbar-center .e-toolbar-item,.e-bigger .e-toolbar.e-rtl .e-toolbar-items .e-hscroll-bar .e-hscroll-content .e-toolbar-right .e-toolbar-item,.e-toolbar.e-bigger.e-rtl .e-toolbar-items .e-hscroll-bar .e-hscroll-content .e-toolbar-center .e-toolbar-item,.e-toolbar.e-bigger.e-rtl .e-toolbar-items .e-hscroll-bar .e-hscroll-content .e-toolbar-right .e-toolbar-item{margin:0}.e-bigger .e-toolbar.e-rtl .e-toolbar-items .e-hscroll-bar .e-hscroll-content .e-toolbar-right .e-toolbar-item:last-child,.e-toolbar.e-bigger.e-rtl .e-toolbar-items .e-hscroll-bar .e-hscroll-content .e-toolbar-right .e-toolbar-item:last-child{margin-left:3px;margin-right:0}.e-bigger .e-toolbar.e-rtl .e-toolbar-items:not(.e-tbar-pos) .e-toolbar-item:first-child,.e-toolbar.e-bigger.e-rtl .e-toolbar-items:not(.e-tbar-pos) .e-toolbar-item:first-child{margin-left:0;margin-right:3px}.e-bigger .e-toolbar.e-extended-toolbar.e-rtl .e-toolbar-extended,.e-toolbar.e-bigger.e-extended-toolbar.e-rtl .e-toolbar-extended{padding-right:3px}.e-accordion .e-tgl-collapse-icon:before{content:"\e916"}.e-accordion .e-tgl-collapse-icon.e-expand-icon{transform:rotate(-180deg)}.e-accordion{display:block;position:relative}.e-accordion .e-acrdn-item{border-radius:0;margin-top:0}.e-accordion .e-acrdn-item.e-select.e-selected:first-child{border-top:0}.e-accordion .e-acrdn-item.e-select.e-selected:last-child{border-bottom:0}.e-accordion .e-acrdn-item:first-child{margin-top:0}.e-accordion .e-acrdn-item:not(.e-select)+.e-acrdn-item:not(.e-select){margin-bottom:0;margin-top:0}.e-accordion .e-acrdn-item .e-acrdn-panel.e-nested .e-acrdn-item.e-select{margin:0}.e-accordion .e-acrdn-item>.e-acrdn-header .e-acrdn-header-content{font-weight:400}.e-accordion .e-acrdn-item.e-selected{padding-top:0}.e-accordion .e-acrdn-item.e-selected>.e-acrdn-header .e-acrdn-header-content{font-weight:400}.e-accordion .e-acrdn-item.e-overlay{height:auto}.e-accordion .e-acrdn-item{overflow:visible;padding-top:0;position:relative}.e-accordion .e-acrdn-item.e-hide{display:none}.e-accordion .e-acrdn-item .e-acrdn-header .e-acrdn-header-content{font-size:15px}.e-accordion .e-acrdn-item.e-select>.e-acrdn-header{cursor:pointer}.e-accordion .e-acrdn-item.e-select>.e-acrdn-header:hover .e-acrdn-header-content,.e-accordion .e-acrdn-item.e-select>.e-acrdn-header:focus .e-acrdn-header-content{text-decoration:none}.e-accordion .e-acrdn-item .e-acrdn-header{border-radius:0;line-height:35px;min-height:36px;overflow:hidden;padding:0 40px 0 16px;text-decoration:none;text-overflow:ellipsis;white-space:nowrap}.e-accordion .e-acrdn-item .e-acrdn-header>*{display:inline-block}.e-accordion .e-acrdn-item .e-acrdn-header .e-acrdn-header-content{line-height:35px}.e-accordion .e-acrdn-item .e-acrdn-header .e-toggle-icon{display:table;font-size:12px;height:36px;min-height:36px;min-width:24px;position:absolute;right:16px;top:0}.e-accordion .e-acrdn-item .e-acrdn-header .e-toggle-icon .e-tgl-collapse-icon.e-icons{display:table-cell;text-align:center;vertical-align:middle}.e-accordion .e-acrdn-item .e-acrdn-header .e-toggle-animation{transition:.5s ease 0s}.e-accordion .e-acrdn-item .e-acrdn-header .e-acrdn-header-icon{display:inline-block;padding:0 8px 0 0}.e-accordion .e-acrdn-item .e-acrdn-header .e-acrdn-header-icon .e-acrdn-icons.e-icons{font-size:12px}.e-accordion .e-acrdn-item .e-acrdn-panel{font-size:13px;overflow-y:hidden;text-decoration:none;width:100%}.e-accordion .e-acrdn-item .e-acrdn-panel.e-nested>.e-acrdn-content>.e-accordion>.e-acrdn-item>.e-acrdn-panel:not(.e-nested)>.e-acrdn-content{padding:16px 16px 16px 32px}.e-accordion .e-acrdn-item .e-acrdn-panel.e-nested>.e-acrdn-content>.e-accordion>.e-acrdn-item>.e-acrdn-header{padding:0 40px 0 32px}.e-accordion .e-acrdn-item .e-acrdn-panel.e-nested>.e-acrdn-content>.e-accordion>.e-acrdn-item>.e-acrdn-header:focus{box-shadow:none}.e-accordion .e-acrdn-item .e-acrdn-panel.e-nested>.e-acrdn-content{padding:0}.e-accordion .e-acrdn-item .e-acrdn-panel.e-nested>.e-acrdn-content .e-acrdn-panel.e-nested>.e-acrdn-content{padding:0}.e-accordion .e-acrdn-item .e-acrdn-panel.e-nested>.e-acrdn-content>.e-accordion{border:0}.e-accordion .e-acrdn-item .e-acrdn-panel.e-nested>.e-acrdn-content .e-accordion .e-acrdn-panel.e-nested .e-acrdn-content .e-acrdn-header{padding:0 40px 0 48px}.e-accordion .e-acrdn-item .e-acrdn-panel.e-nested>.e-acrdn-content .e-accordion .e-acrdn-panel.e-nested .e-acrdn-content .e-acrdn-panel .e-acrdn-content{padding:16px 16px 16px 48px}.e-accordion .e-acrdn-item .e-acrdn-panel.e-nested .e-acrdn-item.e-select.e-selected .e-acrdn-header>.e-acrdn-header-content{font-weight:400}.e-accordion .e-acrdn-item .e-acrdn-panel.e-nested .e-nested .e-accordion .e-acrdn-item .e-acrdn-header .e-acrdn-header-content{font-weight:400}.e-accordion .e-acrdn-item .e-acrdn-panel .e-acrdn-content{line-height:1.5;overflow:hidden;padding:16px;text-overflow:ellipsis}.e-accordion .e-acrdn-item .e-acrdn-panel .e-acrdn-content>*{overflow:hidden;text-overflow:ellipsis}.e-accordion .e-acrdn-item .e-acrdn-panel .e-acrdn-header-content{font-size:14px}.e-accordion .e-acrdn-item .e-content-hide{display:none}.e-accordion.e-rtl .e-acrdn-item .e-acrdn-panel.e-nested>.e-acrdn-content>.e-accordion>.e-acrdn-item>.e-acrdn-panel:not(.e-nested)>.e-acrdn-content{padding:16px 32px 16px 16px}.e-accordion.e-rtl .e-acrdn-item .e-acrdn-panel.e-nested>.e-acrdn-content>.e-accordion>.e-acrdn-item>.e-acrdn-header{padding:0 32px 0 40px}.e-accordion.e-rtl .e-acrdn-item .e-acrdn-panel.e-nested>.e-acrdn-content .e-accordion .e-acrdn-panel.e-nested .e-acrdn-content .e-acrdn-header{padding:0 48px 0 40px}.e-accordion.e-rtl .e-acrdn-item .e-acrdn-panel.e-nested>.e-acrdn-content .e-accordion .e-acrdn-panel.e-nested .e-acrdn-content .e-acrdn-panel .e-acrdn-content{padding:16px 48px 16px 16px}.e-accordion.e-rtl .e-acrdn-item .e-acrdn-header{padding:0 16px 0 40px}.e-accordion.e-rtl .e-acrdn-item .e-acrdn-header .e-toggle-icon{left:16px;right:auto}.e-accordion.e-rtl .e-acrdn-item .e-acrdn-header .e-acrdn-header-icon{padding:0 0 0 8px}.e-accordion{-webkit-tap-highlight-color:rgba(0,0,0,0);background:#fff;border:1px solid rgba(0,0,0,.12);border-radius:0}.e-accordion .e-acrdn-item{border-color:#0000001f;border-style:solid;border-width:0;border-radius:0}.e-accordion .e-acrdn-item.e-active{background:#fff}.e-accordion .e-acrdn-item.e-select:last-child{border-bottom:1px solid transparent;border-radius:0}.e-accordion .e-acrdn-item:first-child .e-acrdn-header:focus{border-radius:0}.e-accordion .e-acrdn-item:last-child{border-bottom:0}.e-accordion .e-acrdn-item:last-child:not(.e-expand-state) .e-acrdn-header:focus{border-radius:0}.e-accordion .e-acrdn-item:last-child.e-selected .e-acrdn-header:focus{border-radius:0}.e-accordion .e-acrdn-item.e-item-focus{border-color:#0000001f;border-style:solid;border-width:0}.e-accordion .e-acrdn-item.e-item-focus.e-select.e-selected.e-expand-state{border-top:1px solid #fff}.e-accordion .e-acrdn-item.e-item-focus.e-select.e-selected.e-expand-state .e-acrdn-header:focus{border-color:#0000001f;border-style:solid;border-width:0}.e-accordion .e-acrdn-item.e-item-focus.e-select.e-selected.e-expand-state .e-acrdn-header:hover:focus{background:#eee}.e-accordion .e-acrdn-item.e-item-focus.e-select.e-selected.e-expand-state .e-acrdn-header:hover:focus .e-acrdn-header-content{color:#e3165b}.e-accordion .e-acrdn-item.e-item-focus.e-select.e-selected.e-expand-state .e-acrdn-header:hover:focus .e-icons{color:#0000008a}.e-accordion .e-acrdn-item.e-item-focus.e-select.e-selected.e-expand-state .e-acrdn-header:hover:focus .e-acrdn-header-icon .e-icons{color:#e3165b}.e-accordion .e-acrdn-item.e-item-focus.e-expand-state.e-select,.e-accordion .e-acrdn-item.e-item-focus.e-select.e-selected.e-expand-state{border-color:#eee}.e-accordion .e-acrdn-item.e-expand-state.e-select{border-color:#fff;border-style:solid;border-width:1px 0 1px 0}.e-accordion .e-acrdn-item .e-acrdn-header{border:0}.e-accordion .e-acrdn-item.e-overlay.e-select.e-expand-state .e-acrdn-header .e-icons,.e-accordion .e-acrdn-item.e-overlay.e-select.e-expand-state .e-acrdn-header .e-acrdn-header-content{color:#e3165b}.e-accordion .e-acrdn-item.e-overlay{background:#fff;opacity:.5}.e-accordion .e-acrdn-item.e-overlay .e-acrdn-header .e-icons,.e-accordion .e-acrdn-item.e-overlay .e-acrdn-header .e-acrdn-header-content{color:#000000de}.e-accordion .e-acrdn-item.e-overlay.e-overlay.e-select.e-expand-state .e-acrdn-header .e-icons,.e-accordion .e-acrdn-item.e-overlay.e-overlay.e-select.e-expand-state .e-acrdn-header .e-acrdn-header-content{color:#e3165b}.e-accordion .e-acrdn-item.e-selected.e-select.e-expand-state>.e-acrdn-header:focus{border-color:#0000001f;border-style:solid;border-width:0;background:#eee}.e-accordion .e-acrdn-item.e-selected.e-select.e-expand-state>.e-acrdn-header:hover{background:#eee}.e-accordion .e-acrdn-item.e-selected.e-select.e-expand-state>.e-acrdn-header:active{background:#fff}.e-accordion .e-acrdn-item .e-acrdn-panel.e-nested .e-acrdn-item.e-select.e-selected.e-expand-state>.e-acrdn-header .e-acrdn-header-content,.e-accordion .e-acrdn-item .e-acrdn-panel.e-nested .e-acrdn-item.e-select.e-expand-state>.e-acrdn-header .e-acrdn-header-content{color:#e3165b}.e-accordion .e-acrdn-item .e-acrdn-panel.e-nested .e-acrdn-content .e-acrdn-item:last-child{border-bottom:1px none rgba(0,0,0,.12)}.e-accordion .e-acrdn-item .e-acrdn-panel.e-nested .e-acrdn-header .e-acrdn-header-content{color:#000000de}.e-accordion .e-acrdn-item.e-select{background:none;border-color:transparent;border-style:solid;border-width:1px 0 1px 0}.e-accordion .e-acrdn-item.e-select .e-acrdn-panel .e-acrdn-content{color:#000000de;background:none;border-top:0;border-bottom:0}.e-accordion .e-acrdn-item .e-acrdn-header .e-acrdn-header-content{color:#000000de}.e-accordion .e-acrdn-item .e-acrdn-header .e-acrdn-header-icon{color:#0000008a}.e-accordion .e-acrdn-item.e-select.e-selected>.e-acrdn-header:focus{border:0}.e-accordion .e-acrdn-item.e-expand-state.e-select:not(.e-selected)>.e-acrdn-header:focus{background:#eee;border:0;border-color:initial}.e-accordion .e-acrdn-item .e-acrdn-header:hover{border:0;background:transparent;border-color:initial}.e-accordion .e-acrdn-item .e-acrdn-header:active{border:0;border-color:initial;background:transparent}.e-accordion .e-acrdn-item .e-acrdn-header:focus{border:0;background:#eee;box-shadow:none}.e-accordion .e-acrdn-item .e-acrdn-header:focus:active .e-icons,.e-accordion .e-acrdn-item .e-acrdn-header:focus:active .e-acrdn-header-content,.e-accordion .e-acrdn-item .e-acrdn-header:focus:active .e-toggle-icon{color:#000000de}.e-accordion .e-acrdn-item.e-select.e-acrdn-item>.e-acrdn-header:hover .e-acrdn-header-content{color:#000000de}.e-accordion .e-acrdn-item.e-select.e-acrdn-item>.e-acrdn-header:hover .e-icons{color:#0000008a}.e-accordion .e-acrdn-item.e-select.e-acrdn-item>.e-acrdn-header:hover .e-toggle-icon .e-icons.e-tgl-collapse-icon{color:#0000008a}.e-accordion .e-acrdn-item.e-select.e-acrdn-item>.e-acrdn-header:hover:focus .e-icons,.e-accordion .e-acrdn-item.e-select.e-acrdn-item>.e-acrdn-header:hover:focus .e-acrdn-header-content{color:#000000de}.e-accordion .e-acrdn-item.e-select.e-selected.e-expand-state>.e-acrdn-header,.e-accordion .e-acrdn-item.e-select.e-expand-state>.e-acrdn-header{border-color:initial;border-style:solid;border-width:0;background:#fff}.e-accordion .e-acrdn-item.e-select.e-selected.e-expand-state>.e-acrdn-header:hover .e-icons,.e-accordion .e-acrdn-item.e-select.e-expand-state>.e-acrdn-header:hover .e-icons{color:#0000008a}.e-accordion .e-acrdn-item.e-select.e-selected.e-expand-state>.e-acrdn-header:hover .e-acrdn-header-icon .e-icons,.e-accordion .e-acrdn-item.e-select.e-expand-state>.e-acrdn-header:hover .e-acrdn-header-icon .e-icons{color:#e3165b}.e-accordion .e-acrdn-item.e-select.e-selected.e-expand-state>.e-acrdn-header:hover .e-acrdn-header-content,.e-accordion .e-acrdn-item.e-select.e-expand-state>.e-acrdn-header:hover .e-acrdn-header-content{color:#e3165b}.e-accordion .e-acrdn-item.e-select.e-selected.e-expand-state>.e-acrdn-header:hover:focus .e-icons,.e-accordion .e-acrdn-item.e-select.e-selected.e-expand-state>.e-acrdn-header:hover:focus .e-acrdn-header-content,.e-accordion .e-acrdn-item.e-select.e-expand-state>.e-acrdn-header:hover:focus .e-icons,.e-accordion .e-acrdn-item.e-select.e-expand-state>.e-acrdn-header:hover:focus .e-acrdn-header-content{color:#e3165b}.e-accordion .e-acrdn-item.e-select.e-selected.e-expand-state>.e-acrdn-header .e-acrdn-header-icon,.e-accordion .e-acrdn-item.e-select.e-expand-state>.e-acrdn-header .e-acrdn-header-icon{color:#e3165b}.e-accordion .e-acrdn-item.e-select.e-selected.e-expand-state>.e-acrdn-header:hover,.e-accordion .e-acrdn-item.e-select.e-expand-state>.e-acrdn-header:hover{border-color:initial}.e-accordion .e-acrdn-item.e-select.e-selected.e-expand-state>.e-acrdn-header>.e-toggle-icon,.e-accordion .e-acrdn-item.e-select.e-expand-state>.e-acrdn-header>.e-toggle-icon{color:#0000008a}.e-accordion .e-acrdn-item.e-select.e-selected.e-expand-state>.e-acrdn-header .e-acrdn-header-icon,.e-accordion .e-acrdn-item.e-select.e-selected.e-expand-state>.e-acrdn-header .e-acrdn-header-content,.e-accordion .e-acrdn-item.e-select.e-expand-state>.e-acrdn-header .e-acrdn-header-icon,.e-accordion .e-acrdn-item.e-select.e-expand-state>.e-acrdn-header .e-acrdn-header-content{color:#e3165b}.e-accordion .e-acrdn-item.e-select.e-item-focus{border-color:#eee}.e-accordion .e-acrdn-item.e-selected{border-color:#0000001f;border-style:solid;border-width:0 0 1px 0}.e-accordion .e-acrdn-item.e-selected.e-select{border-color:#0000001f;border-style:solid;border-width:1px 0 1px 0}.e-accordion .e-acrdn-item.e-selected.e-select.e-active{background:#fff}.e-accordion .e-acrdn-item.e-selected.e-select.e-select:last-child{border-bottom:0}.e-accordion .e-acrdn-item.e-selected>.e-acrdn-header>.e-acrdn-header-content{color:#000000de}.e-accordion .e-acrdn-item.e-selected>.e-acrdn-header>.e-toggle-icon{color:#0000008a}.e-accordion .e-acrdn-item.e-selected>.e-acrdn-header:focus{position:relative;z-index:2;box-shadow:none}.e-accordion .e-acrdn-item.e-selected+.e-selected{border-color:transparent transparent rgba(0,0,0,.12);border-style:solid;border-width:1px 0 1px 0}.e-accordion .e-acrdn-item.e-selected .e-acrdn-item.e-selected.e-expand-state:hover>.e-acrdn-header .e-icons{color:#0000008a}.e-accordion .e-acrdn-item.e-selected .e-acrdn-item.e-selected.e-expand-state:hover>.e-acrdn-header .e-acrdn-header-content{color:#e3165b}.e-accordion .e-acrdn-item.e-selected.e-select>.e-acrdn-header{background:transparent;border-radius:0;border-color:initial;border-style:solid;border-width:0}.e-accordion .e-acrdn-item.e-selected.e-select>.e-acrdn-header:focus{background:#eee}.e-accordion .e-acrdn-item.e-selected.e-select>.e-acrdn-header:hover{border-color:initial}.e-accordion .e-acrdn-item.e-selected>.e-acrdn-panel .e-acrdn-content{color:#000000de}.e-accordion .e-acrdn-item.e-selected>.e-acrdn-panel .e-acrdn-header-content{color:#000000de}.e-accordion .e-acrdn-item .e-toggle-icon{color:#0000008a}.e-accordion .e-acrdn-item .e-acrdn-panel{font-size:13px}.e-bigger .e-accordion .e-acrdn-item .e-acrdn-header .e-acrdn-header-content,.e-accordion.e-bigger .e-acrdn-item .e-acrdn-header .e-acrdn-header-content{font-size:16px;vertical-align:middle}.e-bigger .e-accordion .e-acrdn-item.e-select .e-acrdn-panel,.e-accordion.e-bigger .e-acrdn-item.e-select .e-acrdn-panel{font-size:14px}.e-bigger .e-accordion .e-acrdn-item.e-select .e-acrdn-panel.e-nested>.e-acrdn-content>.e-accordion>.e-acrdn-item>.e-acrdn-panel:not(.e-nested)>.e-acrdn-content,.e-accordion.e-bigger .e-acrdn-item.e-select .e-acrdn-panel.e-nested>.e-acrdn-content>.e-accordion>.e-acrdn-item>.e-acrdn-panel:not(.e-nested)>.e-acrdn-content{padding:16px 16px 16px 32px}.e-bigger .e-accordion .e-acrdn-item.e-select .e-acrdn-panel.e-nested>.e-acrdn-content>.e-accordion>.e-acrdn-item>.e-acrdn-header,.e-accordion.e-bigger .e-acrdn-item.e-select .e-acrdn-panel.e-nested>.e-acrdn-content>.e-accordion>.e-acrdn-item>.e-acrdn-header{box-shadow:none;padding:0 46px 0 32px}.e-bigger .e-accordion .e-acrdn-item.e-select .e-acrdn-panel.e-nested>.e-acrdn-content,.e-accordion.e-bigger .e-acrdn-item.e-select .e-acrdn-panel.e-nested>.e-acrdn-content{padding:0}.e-bigger .e-accordion .e-acrdn-item.e-select .e-acrdn-panel.e-nested>.e-acrdn-content>.e-accordion,.e-accordion.e-bigger .e-acrdn-item.e-select .e-acrdn-panel.e-nested>.e-acrdn-content>.e-accordion{border:0}.e-bigger .e-accordion .e-acrdn-item.e-select .e-acrdn-panel.e-nested>.e-acrdn-content .e-accordion .e-acrdn-panel.e-nested .e-acrdn-content .e-acrdn-header,.e-accordion.e-bigger .e-acrdn-item.e-select .e-acrdn-panel.e-nested>.e-acrdn-content .e-accordion .e-acrdn-panel.e-nested .e-acrdn-content .e-acrdn-header{padding:0 46px 0 48px}.e-bigger .e-accordion .e-acrdn-item.e-select .e-acrdn-panel.e-nested>.e-acrdn-content .e-accordion .e-acrdn-panel.e-nested .e-acrdn-content .e-acrdn-panel .e-acrdn-content,.e-accordion.e-bigger .e-acrdn-item.e-select .e-acrdn-panel.e-nested>.e-acrdn-content .e-accordion .e-acrdn-panel.e-nested .e-acrdn-content .e-acrdn-panel .e-acrdn-content{padding:16px 16px 16px 48px}.e-bigger .e-accordion .e-acrdn-item.e-select .e-acrdn-panel .e-acrdn-header .e-acrdn-header-content,.e-accordion.e-bigger .e-acrdn-item.e-select .e-acrdn-panel .e-acrdn-header .e-acrdn-header-content{font-size:14px}.e-bigger .e-accordion .e-acrdn-item.e-select .e-acrdn-header,.e-accordion.e-bigger .e-acrdn-item.e-select .e-acrdn-header{line-height:47px;min-height:48px;padding:0 46px 0 16px}.e-bigger .e-accordion .e-acrdn-item.e-select .e-acrdn-header .e-toggle-icon,.e-accordion.e-bigger .e-acrdn-item.e-select .e-acrdn-header .e-toggle-icon{height:48px;min-height:48px;min-width:30px;right:16px;font-size:12px}.e-bigger .e-accordion .e-acrdn-item.e-select .e-acrdn-header .e-acrdn-header-icon,.e-accordion.e-bigger .e-acrdn-item.e-select .e-acrdn-header .e-acrdn-header-icon{display:inline-block;padding:0 14px 0 0}.e-bigger .e-accordion .e-acrdn-item.e-select .e-acrdn-header .e-acrdn-header-icon .e-acrdn-icons.e-icons,.e-accordion.e-bigger .e-acrdn-item.e-select .e-acrdn-header .e-acrdn-header-icon .e-acrdn-icons.e-icons{font-size:12px}.e-bigger .e-accordion .e-acrdn-item.e-select .e-acrdn-panel .e-acrdn-content,.e-accordion.e-bigger .e-acrdn-item.e-select .e-acrdn-panel .e-acrdn-content{padding:16px;font-size:14px}.e-bigger .e-accordion.e-rtl .e-acrdn-item.e-select .e-acrdn-panel.e-nested>.e-acrdn-content>.e-accordion>.e-acrdn-item>.e-acrdn-panel:not(.e-nested)>.e-acrdn-content,.e-accordion.e-bigger.e-rtl .e-acrdn-item.e-select .e-acrdn-panel.e-nested>.e-acrdn-content>.e-accordion>.e-acrdn-item>.e-acrdn-panel:not(.e-nested)>.e-acrdn-content{padding:16px 32px 16px 16px}.e-bigger .e-accordion.e-rtl .e-acrdn-item.e-select .e-acrdn-panel.e-nested>.e-acrdn-content>.e-accordion>.e-acrdn-item>.e-acrdn-header,.e-accordion.e-bigger.e-rtl .e-acrdn-item.e-select .e-acrdn-panel.e-nested>.e-acrdn-content>.e-accordion>.e-acrdn-item>.e-acrdn-header{padding:0 32px 0 46px}.e-bigger .e-accordion.e-rtl .e-acrdn-item.e-select .e-acrdn-panel.e-nested>.e-acrdn-content .e-accordion .e-acrdn-panel.e-nested .e-acrdn-content .e-acrdn-header,.e-accordion.e-bigger.e-rtl .e-acrdn-item.e-select .e-acrdn-panel.e-nested>.e-acrdn-content .e-accordion .e-acrdn-panel.e-nested .e-acrdn-content .e-acrdn-header{padding:0 48px 0 46px}.e-bigger .e-accordion.e-rtl .e-acrdn-item.e-select .e-acrdn-panel.e-nested>.e-acrdn-content .e-accordion .e-acrdn-panel.e-nested .e-acrdn-content .e-acrdn-panel .e-acrdn-content,.e-accordion.e-bigger.e-rtl .e-acrdn-item.e-select .e-acrdn-panel.e-nested>.e-acrdn-content .e-accordion .e-acrdn-panel.e-nested .e-acrdn-content .e-acrdn-panel .e-acrdn-content{padding:16px 48px 16px 16px}.e-bigger .e-accordion.e-rtl .e-acrdn-item .e-acrdn-header,.e-accordion.e-bigger.e-rtl .e-acrdn-item .e-acrdn-header{padding:0 16px 0 46px}.e-bigger .e-accordion.e-rtl .e-acrdn-item .e-acrdn-header .e-toggle-icon,.e-accordion.e-bigger.e-rtl .e-acrdn-item .e-acrdn-header .e-toggle-icon{left:16px;right:auto}.e-bigger .e-accordion.e-rtl .e-acrdn-item .e-acrdn-header .e-acrdn-header-icon,.e-accordion.e-bigger.e-rtl .e-acrdn-item .e-acrdn-header .e-acrdn-header-icon{padding:0 0 0 14px}.e-carousel .e-previous-icon:before{content:"\e904"}.e-carousel .e-next-icon:before{content:"\e913"}.e-carousel .e-play-icon:before{content:"\e324"}.e-carousel .e-pause-icon:before{content:"\e326"}.e-carousel.e-rtl .e-previous-icon:before{content:"\e913"}.e-carousel.e-rtl .e-next-icon:before{content:"\e904"}.e-carousel{display:block;margin:0;padding:0;position:relative}.e-carousel .e-carousel-items,.e-carousel .e-carousel-slide-container{height:100%;margin:0;overflow:hidden;padding:0;position:relative;width:100%}.e-carousel .e-carousel-items.e-swipe-start{cursor:pointer}.e-carousel.e-partial .e-carousel-slide-container{padding:0 100px}@media screen and (max-width: 480px){.e-carousel.e-partial .e-carousel-slide-container{padding:0 75px}}@media screen and (max-width: 320px){.e-carousel.e-partial .e-carousel-slide-container{padding:0 50px}}.e-carousel .e-carousel-items{width:calc(var(--carousel-items-count) * 100%);display:flex;flex-direction:row;transition-property:transform;transition-duration:.6s;transition-timing-function:ease-in-out}.e-carousel .e-carousel-items .e-carousel-item{height:100%;overflow:hidden;padding:0;position:relative;width:calc(100% / var(--carousel-items-count))}.e-carousel.e-blazor-carousel .e-carousel-items{transform:translate(calc(-100% / var(--carousel-items-count) * var(--carousel-items-current)));transition:transform}.e-carousel.e-blazor-carousel.e-rtl .e-carousel-items{transform:translate(calc(100% / var(--carousel-items-count) * var(--carousel-items-current)));transition:transform}.e-carousel.e-carousel-fade-animation .e-carousel-items.e-fade-in-out{transition-property:none;animation:fade-in-out .6s ease-in-out}@keyframes fade-in-out{0%{opacity:0}to{opacity:1}}.e-carousel.e-carousel-slide-animation .e-carousel-items.e-slide{transition-duration:.6s}.e-carousel.e-carousel-custom-animation:not(.e-partial) .e-carousel-item{display:block;height:100%;left:0;opacity:0;pointer-events:none;top:0}.e-carousel.e-carousel-custom-animation:not(.e-partial) .e-carousel-item.e-active{opacity:1;pointer-events:visible}.e-carousel .e-carousel-navigators{align-items:center;display:flex;height:100%;justify-content:space-between;pointer-events:none;position:absolute;top:0;width:100%;z-index:1}.e-carousel .e-carousel-navigators .e-play-pause,.e-carousel .e-carousel-navigators .e-previous,.e-carousel .e-carousel-navigators .e-next{padding:.5em;pointer-events:auto}.e-carousel .e-carousel-navigators .e-play-pause .e-btn,.e-carousel .e-carousel-navigators .e-previous .e-btn,.e-carousel .e-carousel-navigators .e-next .e-btn{border:0;box-shadow:none}.e-carousel .e-carousel-navigators .e-play-pause .e-btn:hover,.e-carousel .e-carousel-navigators .e-previous .e-btn:hover,.e-carousel .e-carousel-navigators .e-next .e-btn:hover{border-radius:50%}.e-carousel .e-carousel-navigators .e-play-pause .e-btn.e-rtl,.e-carousel .e-carousel-navigators .e-previous .e-btn.e-rtl,.e-carousel .e-carousel-navigators .e-next .e-btn.e-rtl{transform:rotate(180deg)}.e-carousel .e-carousel-navigators .e-play-pause .e-btn .e-play-icon,.e-carousel .e-carousel-navigators .e-previous .e-btn .e-play-icon,.e-carousel .e-carousel-navigators .e-next .e-btn .e-play-icon{line-height:1;padding-left:3px}.e-carousel .e-carousel-navigators .e-play-pause.e-hover-arrows,.e-carousel .e-carousel-navigators .e-previous.e-hover-arrows,.e-carousel .e-carousel-navigators .e-next.e-hover-arrows{display:none}.e-carousel .e-carousel-indicators{align-items:center;bottom:0;display:flex;justify-content:center;min-height:48px;padding:0;pointer-events:none;position:absolute;width:100%;z-index:1}.e-carousel .e-carousel-indicators.e-default .e-indicator-bars{display:flex;flex-wrap:wrap;justify-content:center;pointer-events:auto}.e-carousel .e-carousel-indicators.e-default .e-indicator-bars .e-indicator-bar{padding:0}.e-carousel .e-carousel-indicators.e-default .e-indicator-bars .e-indicator-bar .e-indicator{align-items:center;display:flex;justify-content:center;padding:6px}.e-carousel .e-carousel-indicators.e-default .e-indicator-bars .e-indicator-bar .e-indicator div{border:1px solid rgba(255,255,255,.4);border-radius:50%;height:12px;transition-duration:.6s;transition-property:background-color,border-color;transition-timing-function:ease-in-out;width:12px}.e-carousel .e-carousel-indicators.e-default .e-indicator-bars .e-indicator-bar .e-indicator .e-ripple-element{display:none}.e-carousel .e-carousel-indicators.e-dynamic{min-height:36px}.e-carousel .e-carousel-indicators.e-dynamic .e-indicator-bars{display:block;overflow:hidden;transition:opacity .6s ease-in-out;white-space:nowrap;width:80px}.e-carousel .e-carousel-indicators.e-dynamic .e-indicator-bars .e-indicator-bar{border-radius:50%;display:inline-block;height:8px;left:calc(32px - 16px * var(--carousel-items-current));margin:0 4px;opacity:1;position:relative;transform:scale(.33);transition-duration:.6s;transition-property:transform,left;transition-timing-function:ease-in-out;white-space:nowrap;width:8px}.e-carousel .e-carousel-indicators.e-dynamic .e-indicator-bars .e-indicator-bar.e-active{transform:scale(1)}.e-carousel .e-carousel-indicators.e-dynamic .e-indicator-bars .e-indicator-bar.e-prev,.e-carousel .e-carousel-indicators.e-dynamic .e-indicator-bars .e-indicator-bar.e-next{transform:scale(.66)}.e-carousel .e-carousel-indicators.e-fraction{min-height:36px}.e-carousel .e-carousel-indicators.e-progress{min-height:4px}.e-carousel .e-carousel-indicators.e-progress .e-indicator-bars{height:4px;width:100%}.e-carousel .e-carousel-indicators.e-progress .e-indicator-bars .e-indicator-bar{height:100%;left:0;position:absolute;top:0;transform:translateZ(0) scaleX(calc(var(--carousel-items-current) / var(--carousel-items-count))) scaleY(1);transition-duration:.6s;transform-origin:left top;width:100%}.e-carousel .e-carousel-navigators .e-previous .e-btn:not(:disabled),.e-carousel .e-carousel-navigators .e-next .e-btn:not(:disabled),.e-carousel .e-carousel-navigators .e-play-pause .e-btn:not(:disabled){background-color:transparent}.e-carousel .e-carousel-navigators .e-previous .e-btn:not(:disabled) .e-btn-icon,.e-carousel .e-carousel-navigators .e-next .e-btn:not(:disabled) .e-btn-icon,.e-carousel .e-carousel-navigators .e-play-pause .e-btn:not(:disabled) .e-btn-icon{color:#fff}.e-carousel .e-carousel-navigators .e-previous .e-btn:not(:disabled):active,.e-carousel .e-carousel-navigators .e-previous .e-btn:not(:disabled):focus,.e-carousel .e-carousel-navigators .e-previous .e-btn:not(:disabled):hover,.e-carousel .e-carousel-navigators .e-next .e-btn:not(:disabled):active,.e-carousel .e-carousel-navigators .e-next .e-btn:not(:disabled):focus,.e-carousel .e-carousel-navigators .e-next .e-btn:not(:disabled):hover,.e-carousel .e-carousel-navigators .e-play-pause .e-btn:not(:disabled):active,.e-carousel .e-carousel-navigators .e-play-pause .e-btn:not(:disabled):focus,.e-carousel .e-carousel-navigators .e-play-pause .e-btn:not(:disabled):hover{background-color:#fff6;outline:none}.e-carousel .e-carousel-indicators.e-default .e-indicator-bar .e-indicator{background-color:transparent;border-color:transparent;box-shadow:none}.e-carousel .e-carousel-indicators.e-default .e-indicator-bar .e-indicator div{background:#fff;border-color:#fff}.e-carousel .e-carousel-indicators.e-default .e-indicator-bar .e-indicator:active,.e-carousel .e-carousel-indicators.e-default .e-indicator-bar .e-indicator:focus,.e-carousel .e-carousel-indicators.e-default .e-indicator-bar .e-indicator:hover{background:transparent;border-color:transparent;box-shadow:none;outline:none}.e-carousel .e-carousel-indicators.e-default .e-indicator-bar .e-indicator:focus-visible{border-color:#000}.e-carousel .e-carousel-indicators.e-default .e-indicator-bar.e-active .e-indicator div{background-color:#e3165b;border-color:#e3165b}.e-carousel .e-carousel-indicators.e-dynamic .e-indicator-bars .e-indicator-bar{background-color:#fff}.e-carousel .e-carousel-indicators.e-dynamic .e-indicator-bars .e-indicator-bar.e-active{background-color:#e3165b}.e-carousel .e-carousel-indicators.e-fraction .e-indicator-bars{color:#fff}.e-carousel .e-carousel-indicators.e-progress .e-indicator-bars{background-color:#e3165b66}.e-carousel .e-carousel-indicators.e-progress .e-indicator-bars .e-indicator-bar{background-color:#e3165b}.e-contextmenu-wrapper ul .e-menu-item .e-previous:before,.e-contextmenu-container ul .e-menu-item .e-previous:before{content:"\e977"}.e-contextmenu-wrapper ul .e-menu-item .e-caret:before,.e-contextmenu-container ul .e-menu-item .e-caret:before{content:"\e956"}.e-rtl.e-contextmenu-wrapper .e-menu-item .e-caret:before,.e-rtl.e-contextmenu-container .e-menu-item .e-caret:before{content:"\e937"}.e-contextmenu-wrapper ul,.e-contextmenu-container ul{font-weight:400;list-style-image:none;list-style-position:outside;list-style-type:none;margin:0;overflow:hidden;-webkit-user-select:none;user-select:none;font-size:14px;padding:0;border:none;border-radius:0;box-shadow:0 5px 5px -3px #0003,0 8px 10px 1px #00000024,0 3px 14px 2px #0000001f;display:none;min-width:120px;position:absolute}.e-contextmenu-wrapper ul.e-ul,.e-contextmenu-wrapper ul.e-ul *,.e-contextmenu-container ul.e-ul,.e-contextmenu-container ul.e-ul *{box-sizing:border-box}.e-contextmenu-wrapper ul.e-ul:focus,.e-contextmenu-wrapper ul.e-ul *:focus,.e-contextmenu-container ul.e-ul:focus,.e-contextmenu-container ul.e-ul *:focus{outline:none}.e-contextmenu-wrapper ul.e-contextmenu,.e-contextmenu-container ul.e-contextmenu{box-shadow:0 5px 5px -3px #0003,0 8px 10px 1px #00000024,0 3px 14px 2px #0000001f}.e-contextmenu-wrapper ul.e-ul,.e-contextmenu-container ul.e-ul{font-family:Roboto,Segoe UI,GeezaPro,"DejaVu Serif","sans-serif",-apple-system,BlinkMacSystemFont}.e-contextmenu-wrapper ul .e-menu-item,.e-contextmenu-container ul .e-menu-item{cursor:pointer;position:relative;height:36px;line-height:36px;padding:0 16px}.e-contextmenu-wrapper ul .e-menu-item.e-menu-hide,.e-contextmenu-container ul .e-menu-item.e-menu-hide{display:none}.e-contextmenu-wrapper ul .e-menu-item.e-menu-header,.e-contextmenu-container ul .e-menu-item.e-menu-header{border-bottom-style:solid;border-bottom-width:1px}.e-contextmenu-wrapper ul .e-menu-item .e-menu-url,.e-contextmenu-container ul .e-menu-item .e-menu-url{text-decoration:none}.e-contextmenu-wrapper ul .e-menu-item .e-menu-icon,.e-contextmenu-container ul .e-menu-item .e-menu-icon{display:inline-block;vertical-align:middle}.e-contextmenu-wrapper ul .e-menu-item.e-separator,.e-contextmenu-container ul .e-menu-item.e-separator{cursor:auto;line-height:normal;pointer-events:none}.e-contextmenu-wrapper ul .e-menu-item .e-menu-url,.e-contextmenu-container ul .e-menu-item .e-menu-url{display:inline-block;min-width:120px}.e-contextmenu-wrapper ul .e-menu-item .e-menu-icon,.e-contextmenu-container ul .e-menu-item .e-menu-icon{font-size:14px;line-height:36px;margin-right:10px;width:1em}.e-contextmenu-wrapper ul .e-menu-item .e-caret,.e-contextmenu-container ul .e-menu-item .e-caret{line-height:36px;margin-left:16px;margin-right:0;position:absolute;right:8px}.e-contextmenu-wrapper ul .e-menu-item.e-menu-caret-icon,.e-contextmenu-container ul .e-menu-item.e-menu-caret-icon{padding-right:36px}.e-contextmenu-wrapper ul .e-menu-item.e-separator,.e-contextmenu-container ul .e-menu-item.e-separator{border-bottom-style:solid;border-bottom-width:1px;height:auto;margin:8px 0}.e-contextmenu-wrapper ul .e-menu-item .e-caret,.e-contextmenu-container ul .e-menu-item .e-caret{font-size:11px}.e-contextmenu-wrapper ul .e-menu-item .e-previous,.e-contextmenu-container ul .e-menu-item .e-previous{margin-right:16px}.e-contextmenu-wrapper ul .e-menu-item.e-disabled,.e-contextmenu-container ul .e-menu-item.e-disabled{cursor:auto;pointer-events:none}.e-contextmenu-wrapper ul .e-menu-item .e-checkbox-wrapper,.e-contextmenu-container ul .e-menu-item .e-checkbox-wrapper{width:max-content}.e-contextmenu-wrapper.e-sfcontextmenu,.e-contextmenu-container.e-sfcontextmenu,.e-contextmenu-wrapper.e-sfcontextmenu .e-menu-vscroll,.e-contextmenu-container.e-sfcontextmenu .e-menu-vscroll{position:absolute}.e-contextmenu-wrapper.e-sfcontextmenu ul,.e-contextmenu-container.e-sfcontextmenu ul{white-space:nowrap}.e-contextmenu-wrapper.e-sfcontextmenu ul.e-transparent,.e-contextmenu-container.e-sfcontextmenu ul.e-transparent{background:transparent;border:0;box-shadow:none;height:1px;left:0;min-width:0;padding:0;top:0;width:0}.e-contextmenu-wrapper.e-sfcontextmenu ul.e-transparent .e-menu-item,.e-contextmenu-container.e-sfcontextmenu ul.e-transparent .e-menu-item{height:0;padding:0}.e-contextmenu-wrapper.e-sfcontextmenu ul.e-transparent .e-menu-item.e-separator,.e-contextmenu-container.e-sfcontextmenu ul.e-transparent .e-menu-item.e-separator{border:0;margin:0}.e-contextmenu-wrapper:not(.e-menu-container) .e-menu-vscroll.e-vscroll,.e-contextmenu-container:not(.e-menu-container) .e-menu-vscroll.e-vscroll{box-shadow:0 5px 5px -3px #0003,0 8px 10px 1px #00000024,0 3px 14px 2px #0000001f}.e-contextmenu-wrapper:not(.e-menu-container) .e-menu-vscroll.e-vscroll .e-vscroll-bar,.e-contextmenu-container:not(.e-menu-container) .e-menu-vscroll.e-vscroll .e-vscroll-bar{height:100%;width:inherit}.e-contextmenu-wrapper:not(.e-menu-container) .e-menu-vscroll.e-vscroll .e-scroll-nav,.e-contextmenu-container:not(.e-menu-container) .e-menu-vscroll.e-vscroll .e-scroll-nav{height:16px}.e-contextmenu-wrapper:not(.e-menu-container) .e-menu-vscroll.e-vscroll:not(.e-scroll-device),.e-contextmenu-container:not(.e-menu-container) .e-menu-vscroll.e-vscroll:not(.e-scroll-device){padding:16px 0}.e-contextmenu-wrapper:not(.e-menu-container) .e-menu-vscroll.e-vscroll ul,.e-contextmenu-container:not(.e-menu-container) .e-menu-vscroll.e-vscroll ul{box-shadow:none;margin-top:-12px;width:inherit}.e-rtl.e-contextmenu-wrapper .e-menu-item .e-menu-icon,.e-rtl.e-contextmenu-container .e-menu-item .e-menu-icon{margin-right:0}.e-rtl.e-contextmenu-wrapper .e-menu-item .e-caret,.e-rtl.e-contextmenu-container .e-menu-item .e-caret{margin-left:0;margin-right:16px;right:auto}.e-rtl.e-contextmenu-wrapper .e-menu-item .e-menu-icon,.e-rtl.e-contextmenu-container .e-menu-item .e-menu-icon{margin-left:10px}.e-rtl.e-contextmenu-wrapper .e-menu-item .e-caret,.e-rtl.e-contextmenu-container .e-menu-item .e-caret{left:8px}.e-rtl.e-contextmenu-wrapper .e-menu-item.e-menu-caret-icon,.e-rtl.e-contextmenu-container .e-menu-item.e-menu-caret-icon{padding-left:36px;padding-right:16px}.e-rtl.e-contextmenu-wrapper .e-menu-item.e-blankicon,.e-rtl.e-contextmenu-container .e-menu-item.e-blankicon{padding-left:16px}.e-rtl.e-contextmenu-wrapper .e-menu-item.e-blankicon.e-menu-caret-icon,.e-rtl.e-contextmenu-container .e-menu-item.e-blankicon.e-menu-caret-icon{padding-left:36px}.e-contextmenu-wrapper .e-menu-item,.e-contextmenu-container .e-menu-item{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.e-contextmenu-wrapper ul,.e-contextmenu-container ul{background-color:#fff;color:#000000de}.e-contextmenu-wrapper ul .e-menu-item.e-menu-header,.e-contextmenu-container ul .e-menu-item.e-menu-header{border-bottom-color:#0000001f}.e-contextmenu-wrapper ul .e-menu-item .e-caret,.e-contextmenu-container ul .e-menu-item .e-caret,.e-contextmenu-wrapper ul .e-menu-item .e-menu-icon,.e-contextmenu-container ul .e-menu-item .e-menu-icon{color:#0000008a}.e-contextmenu-wrapper ul .e-menu-item .e-menu-url,.e-contextmenu-container ul .e-menu-item .e-menu-url{color:#000000de}.e-contextmenu-wrapper ul .e-menu-item.e-focused,.e-contextmenu-container ul .e-menu-item.e-focused{background-color:#eee;color:#000000de;outline:0 solid rgba(0,0,0,.12);outline-offset:0}.e-contextmenu-wrapper ul .e-menu-item.e-focused .e-caret,.e-contextmenu-container ul .e-menu-item.e-focused .e-caret,.e-contextmenu-wrapper ul .e-menu-item.e-focused .e-menu-icon,.e-contextmenu-container ul .e-menu-item.e-focused .e-menu-icon{color:#0000008a}.e-contextmenu-wrapper ul .e-menu-item.e-selected,.e-contextmenu-container ul .e-menu-item.e-selected{background-color:#eee;color:#000000de;outline:0 solid #eee;outline-offset:0}.e-contextmenu-wrapper ul .e-menu-item.e-selected .e-caret,.e-contextmenu-container ul .e-menu-item.e-selected .e-caret,.e-contextmenu-wrapper ul .e-menu-item.e-selected .e-menu-icon,.e-contextmenu-container ul .e-menu-item.e-selected .e-menu-icon{color:#0000008a}.e-contextmenu-wrapper ul .e-disabled,.e-contextmenu-container ul .e-disabled{color:#00000061;opacity:1}.e-contextmenu-wrapper ul .e-disabled .e-menu-icon,.e-contextmenu-container ul .e-disabled .e-menu-icon,.e-contextmenu-wrapper ul .e-disabled .e-caret,.e-contextmenu-container ul .e-disabled .e-caret,.e-contextmenu-wrapper ul .e-disabled .e-menu-url,.e-contextmenu-container ul .e-disabled .e-menu-url{color:#00000061}.e-contextmenu-wrapper ul .e-separator,.e-contextmenu-container ul .e-separator{border-bottom-color:#0000001f}.e-contextmenu-wrapper:not(.e-menu-container) .e-menu-vscroll.e-vscroll,.e-contextmenu-container:not(.e-menu-container) .e-menu-vscroll.e-vscroll{background-color:inherit;border:none}.e-contextmenu-wrapper:not(.e-menu-container) .e-menu-vscroll.e-vscroll .e-scroll-nav,.e-contextmenu-container:not(.e-menu-container) .e-menu-vscroll.e-vscroll .e-scroll-nav{border-color:#0000001f}.e-bigger .e-contextmenu-wrapper ul,.e-bigger.e-contextmenu-wrapper ul,.e-bigger .e-contextmenu-container ul,.e-bigger.e-contextmenu-container ul{font-size:15px;padding:8px 0;white-space:nowrap;box-shadow:0 5px 5px -3px #0003,0 8px 10px 1px #00000024,0 3px 14px 2px #0000001f;max-width:280px;min-width:112px}.e-bigger .e-contextmenu-wrapper ul .e-menu-item,.e-bigger.e-contextmenu-wrapper ul .e-menu-item,.e-bigger .e-contextmenu-container ul .e-menu-item,.e-bigger.e-contextmenu-container ul .e-menu-item{height:48px;line-height:48px}.e-bigger .e-contextmenu-wrapper ul .e-menu-item .e-menu-icon,.e-bigger.e-contextmenu-wrapper ul .e-menu-item .e-menu-icon,.e-bigger .e-contextmenu-container ul .e-menu-item .e-menu-icon,.e-bigger.e-contextmenu-container ul .e-menu-item .e-menu-icon{font-size:16px;line-height:48px}.e-bigger .e-contextmenu-wrapper ul .e-menu-item .e-caret,.e-bigger.e-contextmenu-wrapper ul .e-menu-item .e-caret,.e-bigger .e-contextmenu-container ul .e-menu-item .e-caret,.e-bigger.e-contextmenu-container ul .e-menu-item .e-caret{line-height:48px}.e-bigger .e-contextmenu-wrapper ul .e-menu-item.e-separator,.e-bigger.e-contextmenu-wrapper ul .e-menu-item.e-separator,.e-bigger .e-contextmenu-container ul .e-menu-item.e-separator,.e-bigger.e-contextmenu-container ul .e-menu-item.e-separator{height:auto;line-height:normal}.e-bigger .e-contextmenu-wrapper ul .e-menu-item .e-caret,.e-bigger.e-contextmenu-wrapper ul .e-menu-item .e-caret,.e-bigger .e-contextmenu-container ul .e-menu-item .e-caret,.e-bigger.e-contextmenu-container ul .e-menu-item .e-caret{font-size:12px}.e-bigger .e-contextmenu-wrapper.e-rtl ul .e-blankicon,.e-bigger.e-contextmenu-wrapper.e-rtl ul .e-blankicon,.e-bigger .e-contextmenu-container.e-rtl ul .e-blankicon,.e-bigger.e-contextmenu-container.e-rtl ul .e-blankicon{padding-left:16px}.e-bigger .e-contextmenu-wrapper.e-rtl ul .e-blankicon.e-menu-caret-icon,.e-bigger.e-contextmenu-wrapper.e-rtl ul .e-blankicon.e-menu-caret-icon,.e-bigger .e-contextmenu-container.e-rtl ul .e-blankicon.e-menu-caret-icon,.e-bigger.e-contextmenu-container.e-rtl ul .e-blankicon.e-menu-caret-icon{padding-left:36px}@keyframes tbar-alt-popup-shadow{0%{border-color:#0000001f;box-shadow:0 0 #0000001f}to{box-shadow:0 0 0 200px #0000001f}}@keyframes hscroll-alt-popup-shadow{0%{border-color:#0000001f;box-shadow:0 0 #0000001f}to{box-shadow:0 0 0 200px #0000001f}}.e-tab .e-tab-header .e-close-icon:before{content:"\e7fc";position:relative}@media screen and (max-width: 480px){.e-tab.e-vertical-icon .e-tab-header .e-popup-up-icon:before{content:"\e82a"}.e-tab.e-vertical-icon .e-tab-header .e-popup-down-icon:before{content:"\e83d"}}.e-tab.e-vertical-tab .e-tab-header .e-popup-up-icon:before{content:"More"}.e-tab.e-vertical-tab .e-tab-header .e-popup-up-icon:after{content:"\e919"}.e-tab.e-vertical-tab .e-tab-header .e-popup-down-icon:before{content:"More"}.e-tab.e-vertical-tab .e-tab-header .e-popup-down-icon:after{content:"\e919"}.e-tab.e-vertical-tab.e-icon-tab .e-tab-header .e-popup-up-icon:before{content:""}.e-tab.e-vertical-tab.e-icon-tab .e-tab-header .e-popup-up-icon:after{content:"\ebb9"}.e-tab.e-vertical-tab.e-icon-tab .e-tab-header .e-popup-down-icon:before{content:""}.e-tab.e-vertical-tab.e-icon-tab .e-tab-header .e-popup-down-icon:after{content:"\ebb9"}.e-tab-clone-element .e-close-icon:before{content:"\e7fc";position:relative}.e-tab{display:block;position:relative}.e-tab.e-hidden{display:none}.e-tab.e-fill-mode .e-content,.e-tab.e-fill-mode .e-content .e-item,.e-tab.e-fill-mode .e-content .e-item>div,.e-tab.e-fill-mode .e-content .e-item>div>.e-blazor-template{height:100%}.e-tab .e-tab-header{height:36px;min-height:36px}@media screen and (max-width: 480px){.e-tab .e-tab-header{height:48px;min-height:48px}}.e-tab .e-tab-header:before{content:"";position:absolute;display:unset}.e-tab .e-tab-header:not(.e-vertical):before{bottom:0;top:0;width:100%}.e-tab .e-tab-header .e-toolbar-items{height:auto;margin:0;min-height:36px;position:relative}@media screen and (max-width: 480px){.e-tab .e-tab-header .e-toolbar-items{min-height:48px}}.e-tab .e-tab-header .e-toolbar-items:not(.e-tbar-pos) .e-toolbar-item:first-child,.e-tab .e-tab-header .e-toolbar-items:not(.e-tbar-pos) .e-toolbar-item:last-child{margin:0}.e-tab .e-tab-header .e-toolbar-items:not(.e-tbar-pos) .e-toolbar-item:last-child{margin:0;padding-bottom:0}@media screen and (max-width: 480px){.e-tab .e-tab-header .e-toolbar-items:not(.e-tbar-pos) .e-toolbar-item:last-child{margin:0}}.e-tab .e-tab-header .e-toolbar-items .e-toolbar-item.e-active{position:unset}.e-tab .e-tab-header .e-toolbar-items .e-toolbar-item.e-active:hover:before{left:unset;right:unset}.e-tab .e-tab-header .e-toolbar-items .e-toolbar-item.e-active:before{background-color:unset;bottom:unset;content:unset;height:unset;left:unset;position:unset;right:unset;transition:unset}.e-tab .e-tab-header .e-toolbar-items .e-toolbar-item.e-active:after{color:unset;content:unset;display:unset;font-weight:unset;height:unset;overflow:unset;visibility:unset}.e-tab .e-tab-header .e-toolbar-items.e-hscroll.e-scroll-device{padding:0}.e-tab .e-tab-header .e-toolbar-items.e-hscroll.e-scroll-device .e-scroll-right-nav{display:none}.e-tab .e-tab-header .e-toolbar-items.e-hscroll .e-hscroll-bar{padding:0}.e-tab .e-tab-header .e-toolbar-items.e-hscroll .e-scroll-nav{width:40px;border-radius:0}.e-tab .e-tab-header .e-toolbar-items.e-hscroll:not(.e-tbar-pos) .e-toolbar-item:last-child{margin:0}@media screen and (max-width: 480px){.e-tab .e-tab-header .e-toolbar-items.e-hscroll:not(.e-tbar-pos) .e-toolbar-item:last-child{margin:0}}.e-tab .e-tab-header .e-toolbar-items.e-hscroll:not(.e-tbar-pos) .e-toolbar-item:last-child.e-active{margin:0}.e-tab .e-tab-header .e-hscroll-bar{overflow:hidden}.e-tab .e-tab-header .e-indicator{display:block;position:absolute}.e-tab .e-tab-header .e-indicator.e-hidden{display:none}.e-tab .e-tab-header:not(.e-vertical) .e-indicator{bottom:0;height:2px;left:0;right:0;border-radius:0;transition:left .125s cubic-bezier(.35,0,.25,1),right .25s cubic-bezier(.35,0,.25,1)}.e-tab .e-tab-header .e-toolbar-item.e-hidden{display:none}.e-tab .e-tab-header .e-toolbar-item:not(.e-separator){height:36px;margin:0;min-height:36px;min-width:auto;padding:0}@media screen and (max-width: 480px){.e-tab .e-tab-header .e-toolbar-item:not(.e-separator){height:48px;min-height:48px}}.e-tab .e-tab-header .e-toolbar-item .e-tab-wrap{height:36px;padding:0 18px;width:100%}@media screen and (max-width: 480px){.e-tab .e-tab-header .e-toolbar-item .e-tab-wrap{height:48px;padding:0 12px}}.e-tab .e-tab-header .e-toolbar-item .e-text-wrap{align-content:center;align-items:center;display:inline-flex;height:36px}@media screen and (max-width: 480px){.e-tab .e-tab-header .e-toolbar-item .e-text-wrap{height:48px}}.e-tab .e-tab-header .e-toolbar-item .e-tab-text{display:inherit;font-family:Roboto,Segoe UI,GeezaPro,"DejaVu Serif","sans-serif",-apple-system,BlinkMacSystemFont;font-size:13px;font-weight:500;text-transform:uppercase;align-self:auto;margin-bottom:0}@media screen and (max-width: 480px){.e-tab .e-tab-header .e-toolbar-item .e-tab-text{font-size:14px}}.e-tab .e-tab-header .e-toolbar-item.e-active{margin:0;padding-bottom:0}@media screen and (max-width: 480px){.e-tab .e-tab-header .e-toolbar-item.e-active{margin:0}}.e-tab .e-tab-header .e-toolbar-item.e-active .e-text-wrap{height:36px;margin-top:0}@media screen and (max-width: 480px){.e-tab .e-tab-header .e-toolbar-item.e-active .e-text-wrap{height:48px}}.e-tab .e-tab-header .e-toolbar-item.e-active .e-tab-wrap{margin-bottom:0}.e-tab .e-tab-header .e-toolbar-item.e-active .e-tab-text{font-weight:500}.e-tab .e-tab-header .e-toolbar-item.e-active .e-tab-icon:before{top:1px;left:2px}.e-tab .e-tab-header .e-toolbar-item.e-active .e-icon-top.e-tab-icon:before,.e-tab .e-tab-header .e-toolbar-item.e-active .e-icon-bottom.e-tab-icon:before{left:0}.e-tab .e-tab-header .e-toolbar-item.e-active.e-ileft .e-text-wrap,.e-tab .e-tab-header .e-toolbar-item.e-active.e-iright .e-text-wrap{height:36px;padding:0}@media screen and (max-width: 480px){.e-tab .e-tab-header .e-toolbar-item.e-active.e-ileft .e-text-wrap,.e-tab .e-tab-header .e-toolbar-item.e-active.e-iright .e-text-wrap{height:48px}}.e-tab .e-tab-header .e-toolbar-item .e-icons.e-close-icon{display:none;margin:0 0 0 10px;min-width:10px}@media screen and (max-width: 480px){.e-tab .e-tab-header .e-toolbar-item .e-icons.e-close-icon{margin:0 0 0 14px}}.e-tab .e-tab-header .e-toolbar-item .e-close-icon,.e-tab .e-tab-header .e-toolbar-item .e-close-icon:before{font-size:10px}@media screen and (max-width: 480px){.e-tab .e-tab-header .e-toolbar-item .e-close-icon,.e-tab .e-tab-header .e-toolbar-item .e-close-icon:before{font-size:12px}}.e-tab .e-tab-header .e-toolbar-item .e-close-icon:before{top:1px}.e-tab .e-tab-header .e-toolbar-item .e-icons.e-tab-icon{display:inline-flex;height:20px;min-width:20px;width:20px;line-height:1}@media screen and (max-width: 480px){.e-tab .e-tab-header .e-toolbar-item .e-icons.e-tab-icon{height:20px;width:20px}}.e-tab .e-tab-header .e-toolbar-item .e-tab-icon,.e-tab .e-tab-header .e-toolbar-item .e-tab-icon:before{font-size:18px}@media screen and (max-width: 480px){.e-tab .e-tab-header .e-toolbar-item .e-tab-icon,.e-tab .e-tab-header .e-toolbar-item .e-tab-icon:before{font-size:20px}}.e-tab .e-tab-header .e-toolbar-item .e-tab-icon:before{position:relative;top:1px;left:2px}.e-tab .e-tab-header .e-toolbar-item .e-icon-top.e-tab-icon:before,.e-tab .e-tab-header .e-toolbar-item .e-icon-bottom.e-tab-icon:before{left:0}.e-tab .e-tab-header .e-toolbar-item.e-icon .e-tab-wrap{justify-content:center;padding:0 18px}@media screen and (max-width: 480px){.e-tab .e-tab-header .e-toolbar-item.e-icon .e-tab-wrap{padding:0 24px}}.e-tab .e-tab-header .e-toolbar-item .e-icon-right{margin:0 0 0 8px}@media screen and (max-width: 480px){.e-tab .e-tab-header .e-toolbar-item .e-icon-right{margin:0}}.e-tab .e-tab-header .e-toolbar-item .e-icon-left+.e-tab-text{margin:0 0 0 10px}@media screen and (max-width: 480px){.e-tab .e-tab-header .e-toolbar-item .e-icon-left+.e-tab-text{margin:0 0 0 14px}}.e-tab .e-tab-header .e-toolbar-item.e-itop,.e-tab .e-tab-header .e-toolbar-item.e-ibottom{height:62px}@media screen and (max-width: 480px){.e-tab .e-tab-header .e-toolbar-item.e-itop,.e-tab .e-tab-header .e-toolbar-item.e-ibottom{height:62px}}.e-tab .e-tab-header .e-toolbar-item.e-itop .e-tab-wrap,.e-tab .e-tab-header .e-toolbar-item.e-ibottom .e-tab-wrap{align-items:center;display:flex;height:62px;position:relative}@media screen and (max-width: 480px){.e-tab .e-tab-header .e-toolbar-item.e-itop .e-tab-wrap,.e-tab .e-tab-header .e-toolbar-item.e-ibottom .e-tab-wrap{height:62px}}.e-tab .e-tab-header .e-toolbar-item.e-itop .e-tab-wrap:focus .e-text-wrap,.e-tab .e-tab-header .e-toolbar-item.e-ibottom .e-tab-wrap:focus .e-text-wrap{height:auto}.e-tab .e-tab-header .e-toolbar-item.e-itop .e-text-wrap,.e-tab .e-tab-header .e-toolbar-item.e-ibottom .e-text-wrap{display:block;height:auto}.e-tab .e-tab-header .e-toolbar-item.e-itop.e-active .e-tab-wrap:focus .e-text-wrap,.e-tab .e-tab-header .e-toolbar-item.e-ibottom.e-active .e-tab-wrap:focus .e-text-wrap{height:auto}.e-tab .e-tab-header .e-toolbar-item.e-itop.e-active .e-tab-wrap .e-text-wrap,.e-tab .e-tab-header .e-toolbar-item.e-ibottom.e-active .e-tab-wrap .e-text-wrap{height:auto}.e-tab .e-tab-header .e-toolbar-item.e-itop .e-close-icon,.e-tab .e-tab-header .e-toolbar-item.e-ibottom .e-close-icon{position:absolute;right:18px;top:calc(50% - 6px)}@media screen and (max-width: 480px){.e-tab .e-tab-header .e-toolbar-item.e-itop .e-close-icon,.e-tab .e-tab-header .e-toolbar-item.e-ibottom .e-close-icon{right:12px}}.e-tab .e-tab-header .e-toolbar-item.e-itop .e-tab-text{margin:8px 0 0}@media screen and (max-width: 480px){.e-tab .e-tab-header .e-toolbar-item.e-itop .e-tab-text{margin:10px 0 0}}.e-tab .e-tab-header .e-toolbar-item.e-ibottom .e-tab-text{margin:0 0 8px}@media screen and (max-width: 480px){.e-tab .e-tab-header .e-toolbar-item.e-ibottom .e-tab-text{margin:0 0 10px}}.e-tab .e-tab-header .e-toolbar-item .e-tab-icon.e-icon-top,.e-tab .e-tab-header .e-toolbar-item .e-tab-icon.e-icon-bottom{align-items:center;display:flex;flex-direction:column;justify-content:center;margin:auto}.e-tab .e-tab-header .e-toolbar-pop{overflow-y:auto;padding:0}.e-tab .e-tab-header .e-toolbar-pop .e-toolbar-item{height:36px;min-height:36px;min-width:auto}@media screen and (max-width: 480px){.e-tab .e-tab-header .e-toolbar-pop .e-toolbar-item{height:48px;min-height:48px}}.e-tab .e-tab-header .e-toolbar-pop .e-toolbar-item:not(.e-separator){margin:0;padding:0}.e-tab .e-tab-header .e-toolbar-pop .e-toolbar-item .e-tab-wrap{height:36px;padding:0 16px;text-align:initial}@media screen and (max-width: 480px){.e-tab .e-tab-header .e-toolbar-pop .e-toolbar-item .e-tab-wrap{height:48px;padding:0 16px}}.e-tab .e-tab-header .e-toolbar-pop .e-toolbar-item .e-text-wrap{height:36px;width:100%}.e-tab .e-tab-header .e-toolbar-pop .e-toolbar-item .e-tab-text{display:inline-flex;width:100%}.e-tab .e-tab-header .e-toolbar-pop .e-toolbar-item .e-close-icon{margin:0 0 0 8px}.e-tab .e-tab-header .e-toolbar-pop .e-toolbar-item .e-close-icon:before{top:0}.e-tab .e-tab-header .e-toolbar-pop .e-toolbar-item .e-tab-text+.e-close-icon[style="display:block"]{padding-right:10px}@media screen and (max-width: 480px){.e-tab .e-tab-header .e-toolbar-pop .e-toolbar-item .e-tab-text+.e-close-icon[style="display:block"]{padding-right:0}}.e-tab .e-tab-header .e-toolbar-pop .e-toolbar-item.e-itop,.e-tab .e-tab-header .e-toolbar-pop .e-toolbar-item.e-ibottom{height:36px}@media screen and (max-width: 480px){.e-tab .e-tab-header .e-toolbar-pop .e-toolbar-item.e-itop,.e-tab .e-tab-header .e-toolbar-pop .e-toolbar-item.e-ibottom{height:48px}}.e-tab .e-tab-header .e-toolbar-pop .e-toolbar-item.e-itop:not(.e-separator),.e-tab .e-tab-header .e-toolbar-pop .e-toolbar-item.e-ibottom:not(.e-separator){min-height:36px}@media screen and (max-width: 480px){.e-tab .e-tab-header .e-toolbar-pop .e-toolbar-item.e-itop:not(.e-separator),.e-tab .e-tab-header .e-toolbar-pop .e-toolbar-item.e-ibottom:not(.e-separator){min-height:48px}}.e-tab .e-tab-header .e-toolbar-pop .e-toolbar-item.e-itop .e-tab-wrap,.e-tab .e-tab-header .e-toolbar-pop .e-toolbar-item.e-ibottom .e-tab-wrap{height:36px}@media screen and (max-width: 480px){.e-tab .e-tab-header .e-toolbar-pop .e-toolbar-item.e-itop .e-tab-wrap,.e-tab .e-tab-header .e-toolbar-pop .e-toolbar-item.e-ibottom .e-tab-wrap{height:48px}}.e-tab .e-tab-header .e-toolbar-pop .e-toolbar-item.e-itop .e-text-wrap,.e-tab .e-tab-header .e-toolbar-pop .e-toolbar-item.e-ibottom .e-text-wrap{display:inline-flex;height:auto}.e-tab .e-tab-header .e-toolbar-pop .e-toolbar-item.e-itop .e-tab-text,.e-tab .e-tab-header .e-toolbar-pop .e-toolbar-item.e-ibottom .e-tab-text{display:block;justify-content:center;margin:0 0 0 10px;padding-left:0;padding-right:10px}@media screen and (max-width: 480px){.e-tab .e-tab-header .e-toolbar-pop .e-toolbar-item.e-itop .e-tab-text,.e-tab .e-tab-header .e-toolbar-pop .e-toolbar-item.e-ibottom .e-tab-text{justify-content:center;margin:0 0 0 12px;padding-left:0;padding-right:0}}.e-tab .e-tab-header .e-toolbar-pop .e-toolbar-item.e-itop .e-close-icon,.e-tab .e-tab-header .e-toolbar-pop .e-toolbar-item.e-ibottom .e-close-icon{right:18px;top:initial}.e-tab .e-tab-header .e-toolbar-pop .e-toolbar-item.e-ibottom .e-tab-text{margin:0}.e-tab .e-tab-header .e-toolbar-pop .e-toolbar-item .e-tab-icon.e-icon-top,.e-tab .e-tab-header .e-toolbar-pop .e-toolbar-item .e-tab-icon.e-icon-bottom{display:inline-flex}.e-tab .e-tab-header.e-close-show .e-icons.e-close-icon{align-items:center;align-self:center;display:inline-flex}@media screen and (max-width: 480px){.e-tab .e-tab-header.e-close-show .e-icons.e-close-icon{display:none}}@media screen and (max-width: 480px){.e-tab .e-tab-header.e-close-show .e-toolbar-item.e-active .e-close-icon{display:inline-flex}}.e-tab .e-tab-header.e-close-show .e-toolbar-item.e-itop .e-text-wrap,.e-tab .e-tab-header.e-close-show .e-toolbar-item.e-ibottom .e-text-wrap{margin-right:20px}.e-tab .e-tab-header .e-scroll-nav{height:36px;min-height:36px;min-width:auto;width:auto}@media screen and (max-width: 480px){.e-tab .e-tab-header .e-scroll-nav{height:48px;min-height:48px}}.e-tab .e-tab-header .e-scroll-nav.e-scroll-left-nav,.e-tab .e-tab-header .e-scroll-nav.e-scroll-right-nav{padding:0 9px}@media screen and (max-width: 480px){.e-tab .e-tab-header .e-scroll-nav.e-scroll-right-nav{padding:0 12px}}.e-tab .e-tab-header .e-scroll-nav .e-nav-left-arrow:before,.e-tab .e-tab-header .e-scroll-nav .e-nav-right-arrow:before{font-size:12px;line-height:24px;position:relative;top:0;vertical-align:initial}.e-tab .e-tab-header .e-scroll-nav .e-nav-arrow{font-size:12px;height:24px;line-height:24px;width:24px}@media screen and (max-width: 480px){.e-tab .e-tab-header .e-scroll-nav .e-nav-arrow{font-size:12px;height:24px;line-height:24px;width:24px}}.e-tab .e-tab-header .e-hor-nav{height:36px;min-height:36px;min-width:auto;padding:0 9px;width:auto}@media screen and (max-width: 480px){.e-tab .e-tab-header .e-hor-nav{height:48px;min-height:48px;padding:0 12px}}.e-tab .e-tab-header .e-hor-nav .e-popup-up-icon,.e-tab .e-tab-header .e-hor-nav .e-popup-down-icon{font-size:12px;height:24px;line-height:24px;width:24px}@media screen and (max-width: 480px){.e-tab .e-tab-header .e-hor-nav .e-popup-up-icon,.e-tab .e-tab-header .e-hor-nav .e-popup-down-icon{font-size:12px;height:24px;line-height:24px;width:24px}}.e-tab .e-tab-header .e-hor-nav .e-popup-up-icon:before,.e-tab .e-tab-header .e-hor-nav .e-popup-down-icon:before{font-size:12px;line-height:24px;position:relative;top:0;vertical-align:initial}@media screen and (max-width: 480px){.e-tab .e-tab-header .e-hor-nav .e-popup-up-icon:before,.e-tab .e-tab-header .e-hor-nav .e-popup-down-icon:before{font-size:16px}}.e-tab .e-tab-header .e-hor-nav .e-popup-up-icon:hover,.e-tab .e-tab-header .e-hor-nav .e-popup-down-icon:hover{line-height:24px}.e-tab .e-tab-header .e-hor-nav .e-popup-up-icon:hover:before,.e-tab .e-tab-header .e-hor-nav .e-popup-down-icon:hover:before{line-height:24px;top:0}@media screen and (max-width: 480px){.e-tab .e-tab-header .e-hor-nav .e-popup-up-icon:hover:before,.e-tab .e-tab-header .e-hor-nav .e-popup-down-icon:hover:before{line-height:24px}}.e-tab .e-tab-header .e-hor-nav .e-popup-up-icon{transform:rotate(180deg);transition:transform .1s ease}@media screen and (max-width: 480px){.e-tab .e-tab-header .e-hor-nav .e-popup-up-icon{transform:none;transition:none}}.e-tab .e-tab-header .e-hor-nav .e-popup-down-icon{transform:rotate(0);transition:transform .1s ease}@media screen and (max-width: 480px){.e-tab .e-tab-header .e-hor-nav .e-popup-down-icon{transform:none;transition:none}}.e-tab .e-tab-header .e-hor-nav:focus .e-popup-up-icon,.e-tab .e-tab-header .e-hor-nav:focus .e-popup-down-icon{line-height:24px}.e-tab .e-tab-header .e-hor-nav:focus .e-popup-up-icon:before,.e-tab .e-tab-header .e-hor-nav:focus .e-popup-down-icon:before{line-height:24px;top:0}@media screen and (max-width: 480px){.e-tab .e-tab-header .e-hor-nav:focus .e-popup-up-icon:before,.e-tab .e-tab-header .e-hor-nav:focus .e-popup-down-icon:before{line-height:24px}}.e-tab .e-tab-header .e-hor-nav:focus .e-popup-up-icon:hover,.e-tab .e-tab-header .e-hor-nav:focus .e-popup-down-icon:hover{line-height:24px;top:0}.e-tab .e-tab-header.e-horizontal-bottom .e-toolbar-items .e-toolbar-item.e-active{position:unset}.e-tab .e-tab-header.e-horizontal-bottom .e-toolbar-items .e-toolbar-item.e-active:hover:before{left:unset;right:unset}.e-tab .e-tab-header.e-horizontal-bottom .e-toolbar-items .e-toolbar-item.e-active:before{background-color:unset;content:unset;height:unset;left:unset;position:unset;right:unset;top:unset;transition:unset}.e-tab .e-tab-header.e-horizontal-bottom .e-toolbar-items .e-toolbar-item.e-active:after{color:unset;content:unset;display:unset;font-weight:unset;height:unset;overflow:unset;visibility:unset}.e-tab .e-tab-header.e-horizontal-bottom:before{bottom:auto}.e-tab .e-tab-header.e-horizontal-bottom .e-hscroll-bar{margin-top:0}.e-tab .e-tab-header.e-horizontal-bottom .e-toolbar-items:not(.e-tbar-pos) .e-toolbar-item:last-child{margin:0;padding-bottom:0;padding-top:0}@media screen and (max-width: 480px){.e-tab .e-tab-header.e-horizontal-bottom .e-toolbar-items:not(.e-tbar-pos) .e-toolbar-item:last-child{margin:0}}.e-tab .e-tab-header.e-horizontal-bottom .e-indicator{bottom:auto;top:0}.e-tab .e-tab-header.e-horizontal-bottom .e-toolbar-item.e-active{margin:0;padding-bottom:0;padding-top:0}@media screen and (max-width: 480px){.e-tab .e-tab-header.e-horizontal-bottom .e-toolbar-item.e-active{margin:0}}.e-tab .e-tab-header.e-horizontal-bottom .e-toolbar-item.e-active .e-text-wrap{height:36px;padding:0}@media screen and (max-width: 480px){.e-tab .e-tab-header.e-horizontal-bottom .e-toolbar-item.e-active .e-text-wrap{height:48px}}.e-tab .e-tab-header.e-horizontal-bottom .e-toolbar-item.e-active .e-text-wrap:before,.e-tab .e-tab-header.e-horizontal-bottom .e-toolbar-item.e-active:not(.e-separator):last-child .e-text-wrap:before{top:unset}.e-tab .e-tab-header.e-horizontal-bottom .e-toolbar-item.e-active.e-itop .e-tab-wrap:focus .e-close-icon:before{top:0}.e-tab .e-tab-header.e-horizontal-bottom .e-toolbar-item.e-itop .e-text-wrap,.e-tab .e-tab-header.e-horizontal-bottom .e-toolbar-item.e-ibottom .e-text-wrap{height:initial}.e-tab .e-tab-header.e-horizontal-bottom .e-toolbar-item.e-itop.e-active .e-text-wrap,.e-tab .e-tab-header.e-horizontal-bottom .e-toolbar-item.e-ibottom.e-active .e-text-wrap{height:initial;padding:0}.e-tab .e-tab-header.e-horizontal-bottom .e-toolbar-item.e-itop.e-active .e-text-wrap:before,.e-tab .e-tab-header.e-horizontal-bottom .e-toolbar-item.e-ibottom.e-active .e-text-wrap:before{bottom:auto;top:0}.e-tab .e-tab-header.e-reorder-active-item .e-toolbar-pop .e-toolbar-item.e-active .e-text-wrap:before{display:none}.e-tab .e-tab-header.e-vertical{max-width:150px;z-index:1}.e-tab .e-tab-header.e-vertical:before{bottom:0;height:100%;left:0;top:0}.e-tab .e-tab-header.e-vertical[style*="overflow: hidden"]:before{bottom:15px;height:auto;top:15px}@media screen and (max-width: 480px){.e-tab .e-tab-header.e-vertical[style*="overflow: hidden"]:before{bottom:0;top:0}}.e-tab .e-tab-header.e-vertical .e-indicator{display:block;transition:top .125s cubic-bezier(.35,0,.25,1),bottom .25s cubic-bezier(.35,0,.25,1);width:2px}.e-tab .e-tab-header.e-vertical .e-toolbar-items{height:inherit;flex-direction:column;align-items:normal}.e-tab .e-tab-header.e-vertical .e-toolbar-items.e-vscroll:not(.e-scroll-device){padding:16px 0}.e-tab .e-tab-header.e-vertical .e-toolbar-item:last-child{margin:0}.e-tab .e-tab-header.e-vertical .e-toolbar-item:not(.e-separator){margin:0}.e-tab .e-tab-header.e-vertical .e-toolbar-item .e-tab-wrap{padding:0 18px}.e-tab .e-tab-header.e-vertical .e-toolbar-item .e-text-wrap{position:relative;width:100%}.e-tab .e-tab-header.e-vertical .e-toolbar-item .e-tab-text,.e-tab .e-tab-header.e-vertical .e-toolbar-item .e-tab-icon:before{text-align:center;width:100%}.e-tab .e-tab-header.e-vertical .e-toolbar-item .e-tab-text{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.e-tab .e-tab-header.e-vertical .e-toolbar-item.e-active .e-text-wrap:before{display:none}.e-tab .e-tab-header.e-vertical .e-toolbar-item.e-ileft.e-icon{min-height:36px;min-width:33px}.e-tab .e-tab-header.e-vertical .e-toolbar-item.e-ileft.e-icon .e-tab-icon{margin:0}.e-tab .e-tab-header.e-vertical .e-toolbar-item.e-itop .e-close-icon,.e-tab .e-tab-header.e-vertical .e-toolbar-item.e-ibottom .e-close-icon{right:-18px}.e-tab .e-tab-header.e-vertical .e-toolbar-pop{top:initial!important}.e-tab .e-tab-header.e-vertical.e-vertical-left{float:left}.e-tab .e-tab-header.e-vertical.e-vertical-left:before{right:0}.e-tab .e-tab-header.e-vertical.e-vertical-left .e-indicator{left:auto;right:0}.e-tab .e-tab-header.e-vertical.e-vertical-left .e-toolbar-items .e-toolbar-item.e-active:hover:before{bottom:unset;height:unset}.e-tab .e-tab-header.e-vertical.e-vertical-left .e-toolbar-items .e-toolbar-item.e-active:before{background-color:unset;bottom:unset;content:unset;height:unset;left:unset;position:unset;right:unset;transition:unset;width:unset}.e-tab .e-tab-header.e-vertical.e-vertical-left .e-toolbar-items .e-toolbar-item.e-active:after{color:unset;content:unset;display:unset;font-weight:unset;height:unset;overflow:unset;visibility:unset}.e-tab .e-tab-header.e-vertical.e-vertical-right{float:right}.e-tab .e-tab-header.e-vertical.e-vertical-right:before{right:auto}.e-tab .e-tab-header.e-vertical.e-vertical-right .e-indicator{left:0;right:auto}.e-tab .e-tab-header.e-vertical.e-vertical-right .e-tab-wrap{text-align:right}.e-tab .e-tab-header.e-vertical.e-vertical-right .e-toolbar-pop .e-tab-text{width:auto}.e-tab .e-tab-header.e-vertical.e-vertical-right .e-toolbar-items .e-toolbar-item.e-active:hover:before{bottom:unset;height:unset}.e-tab .e-tab-header.e-vertical.e-vertical-right .e-toolbar-items .e-toolbar-item.e-active:before{background-color:unset;bottom:unset;content:unset;height:unset;left:unset;position:unset;right:unset;transition:unset;width:unset}.e-tab .e-tab-header.e-vertical.e-vertical-right .e-toolbar-items .e-toolbar-item.e-active:after{color:unset;content:unset;display:unset;font-weight:unset;height:unset;overflow:unset;visibility:unset}.e-tab .e-tab-header.e-vertical .e-scroll-nav{height:16px;justify-content:center;min-height:16px;width:100%}.e-tab .e-tab-header.e-vertical .e-scroll-nav .e-nav-arrow{font-size:10px;height:16px;line-height:16px;margin:0 auto;width:16px}.e-tab .e-tab-header.e-vertical .e-hor-nav{padding:0 18px;width:100%}.e-tab .e-tab-header.e-vertical .e-hor-nav .e-popup-up-icon,.e-tab .e-tab-header.e-vertical .e-hor-nav .e-popup-down-icon{height:100%;transform:none;transition:none;width:100%}.e-tab .e-tab-header.e-vertical .e-hor-nav .e-popup-up-icon:before,.e-tab .e-tab-header.e-vertical .e-hor-nav .e-popup-down-icon:before{float:left;font-family:Roboto,Segoe UI,GeezaPro,"DejaVu Serif","sans-serif",-apple-system,BlinkMacSystemFont;font-size:13px;font-weight:500;line-height:35px;text-align:left;text-transform:uppercase;transform:none;transition:none}.e-tab .e-tab-header.e-vertical .e-hor-nav .e-popup-up-icon:after,.e-tab .e-tab-header.e-vertical .e-hor-nav .e-popup-down-icon:after{float:left;font-size:12px;line-height:35px;margin:0 0 0 10px;vertical-align:initial}@media screen and (max-width: 480px){.e-tab .e-tab-header.e-vertical .e-hor-nav .e-popup-up-icon:after,.e-tab .e-tab-header.e-vertical .e-hor-nav .e-popup-down-icon:after{font-size:14px}}.e-tab .e-tab-header.e-vertical .e-scroll-device .e-scroll-nav,.e-tab .e-tab-header.e-vertical .e-scroll-device .e-scroll-overlay{display:none}.e-tab .e-tab-header.e-vertical.e-toolpop .e-toolbar-items{height:auto}.e-tab.e-rtl .e-tab-header.e-vertical .e-toolbar-items:not(.e-tbar-pos) .e-toolbar-item:last-child{margin:0}.e-tab.e-rtl .e-tab-header.e-vertical .e-toolbar-item:not(.e-separator){margin:0}.e-tab.e-rtl .e-tab-header.e-vertical .e-toolbar-item:not(.e-separator).e-itop .e-close-icon,.e-tab.e-rtl .e-tab-header.e-vertical .e-toolbar-item:not(.e-separator).e-ibottom .e-close-icon{left:-18px}.e-tab.e-rtl .e-tab-header.e-vertical .e-hor-nav{padding:0 18px}.e-tab.e-rtl .e-tab-header.e-vertical .e-hor-nav .e-popup-up-icon:before,.e-tab.e-rtl .e-tab-header.e-vertical .e-hor-nav .e-popup-down-icon:before{float:right}.e-tab.e-rtl .e-tab-header.e-vertical .e-hor-nav .e-popup-up-icon:after,.e-tab.e-rtl .e-tab-header.e-vertical .e-hor-nav .e-popup-down-icon:after{float:right;margin:0 10px 0 0}.e-tab .e-content{position:relative}.e-tab .e-content .e-item.e-view{inset:0;overflow:hidden;position:absolute}.e-tab .e-content>.e-item{display:none}.e-tab .e-content>.e-item.e-active{background:inherit;display:block}.e-tab .e-content.e-progress{overflow:hidden}.e-tab.e-vertical-tab .e-content{display:flex}.e-tab.e-vertical-tab .e-content .e-item.e-active{display:flex;flex:none}.e-tab.e-vertical-tab .e-content .e-item,.e-tab.e-vertical-tab .e-content .e-item>:first-child{width:100%}.e-tab.e-vertical-icon>.e-tab-header{height:62px;min-height:62px}.e-tab.e-vertical-icon>.e-tab-header.e-reorder-active-item .e-toolbar-pop .e-toolbar-item.e-active .e-tab-wrap:before,.e-tab.e-vertical-icon>.e-tab-header.e-reorder-active-item .e-toolbar-pop .e-toolbar-item:not(.e-separator):last-child.e-active .e-tab-wrap:before{display:none}.e-tab.e-vertical-icon>.e-tab-header>.e-toolbar-items{height:62px}.e-tab.e-vertical-icon>.e-tab-header .e-toolbar-item.e-active .e-text-wrap,.e-tab.e-vertical-icon>.e-tab-header .e-toolbar-item:not(.e-separator):last-child.e-active .e-text-wrap{position:unset}.e-tab.e-vertical-icon>.e-tab-header .e-toolbar-item.e-active .e-text-wrap:before,.e-tab.e-vertical-icon>.e-tab-header .e-toolbar-item:not(.e-separator):last-child.e-active .e-text-wrap:before{border:unset;content:unset;display:none;position:unset;top:unset;width:unset}.e-tab.e-vertical-icon>.e-tab-header .e-toolbar-item.e-active .e-tab-wrap:before,.e-tab.e-vertical-icon>.e-tab-header .e-toolbar-item:not(.e-separator):last-child.e-active .e-tab-wrap:before{content:unset;display:unset;position:unset;top:unset;width:unset;border:unset}.e-tab.e-vertical-icon>.e-tab-header .e-scroll-nav{height:62px}.e-tab.e-vertical-icon>.e-tab-header .e-hor-nav{height:62px}@media screen and (max-width: 480px){.e-tab.e-vertical-icon>.e-tab-header .e-hor-nav .e-popup-up-icon:before,.e-tab.e-vertical-icon>.e-tab-header .e-hor-nav .e-popup-down-icon:before{font-size:12px}}.e-tab.e-vertical-icon>.e-tab-header.e-vertical .e-indicator{width:2px}.e-tab.e-vertical-icon>.e-tab-header.e-vertical .e-toolbar-item.e-active .e-tab-wrap:before,.e-tab.e-vertical-icon>.e-tab-header.e-vertical .e-toolbar-item:not(.e-separator):last-child.e-active .e-tab-wrap:before{display:none}.e-tab.e-vertical-icon>.e-tab-header.e-vertical .e-toolbar-item.e-active .e-text-wrap,.e-tab.e-vertical-icon>.e-tab-header.e-vertical .e-toolbar-item:not(.e-separator):last-child.e-active .e-text-wrap{position:relative}.e-tab.e-vertical-icon>.e-tab-header.e-vertical .e-scroll-nav{height:16px}.e-tab.e-vertical-icon>.e-tab-header.e-horizontal-bottom .e-toolbar-item.e-active .e-tab-wrap:before,.e-tab.e-vertical-icon>.e-tab-header.e-horizontal-bottom .e-toolbar-item:not(.e-separator):last-child.e-active .e-tab-wrap:before{top:unset}.e-tab.e-vertical-icon.e-rtl .e-tab-header .e-toolbar-item.e-active{margin:0}.e-tab.e-vertical-icon.e-vertical-tab .e-tab-header.e-vertical .e-toolbar-items{height:inherit}.e-tab.e-focused .e-tab-header .e-toolbar-item .e-tab-wrap:focus{height:36px}.e-tab.e-focused .e-tab-header .e-toolbar-item .e-tab-wrap:focus .e-text-wrap{height:36px}.e-tab.e-focused .e-tab-header .e-toolbar-item.e-itop .e-tab-wrap:focus,.e-tab.e-focused .e-tab-header .e-toolbar-item.e-ibottom .e-tab-wrap:focus{height:62px}.e-tab.e-focused .e-tab-header .e-toolbar-item.e-itop .e-tab-wrap:focus .e-text-wrap,.e-tab.e-focused .e-tab-header .e-toolbar-item.e-ibottom .e-tab-wrap:focus .e-text-wrap{height:auto}.e-tab.e-focused .e-tab-header .e-toolbar-item.e-itop.e-active .e-tab-wrap:focus .e-text-wrap,.e-tab.e-focused .e-tab-header .e-toolbar-item.e-ibottom.e-active .e-tab-wrap:focus .e-text-wrap{height:auto}.e-tab.e-focused .e-tab-header .e-toolbar-pop .e-toolbar-item .e-tab-wrap:focus{height:36px}.e-tab.e-focused .e-tab-header .e-toolbar-pop .e-toolbar-item .e-tab-wrap:focus .e-text-wrap{height:36px}.e-tab.e-focused .e-tab-header .e-toolbar-pop .e-toolbar-item.e-itop .e-tab-wrap:focus,.e-tab.e-focused .e-tab-header .e-toolbar-pop .e-toolbar-item.e-ibottom .e-tab-wrap:focus{height:36px}.e-tab.e-focused .e-tab-header .e-horizontal-bottom .e-toolbar-item.e-active .e-tab-wrap:focus .e-text-wrap{height:36px;padding:0}.e-tab.e-focused .e-tab-header .e-horizontal-bottom .e-toolbar-item.e-itop .e-tab-wrap:focus .e-text-wrap,.e-tab.e-focused .e-tab-header .e-horizontal-bottom .e-toolbar-item.e-ibottom .e-tab-wrap:focus .e-text-wrap{height:auto}.e-tab.e-focused .e-tab-header .e-horizontal-bottom .e-toolbar-item.e-itop.e-active .e-tab-wrap:focus .e-text-wrap,.e-tab.e-focused .e-tab-header .e-horizontal-bottom .e-toolbar-item.e-ibottom.e-active .e-tab-wrap:focus .e-text-wrap{height:auto}.e-tab.e-template .e-tab-header .e-toolbar-items .e-toolbar-item .e-tab-wrap .e-text-wrap .e-tab-text>div,.e-tab.e-template .e-tab-header .e-toolbar-pop .e-toolbar-item .e-tab-wrap .e-text-wrap .e-tab-text>div{display:inherit}.e-tab.e-template .e-content>.e-item{display:none}.e-tab.e-template .e-content>.e-item.e-active{background:inherit;display:block}.e-tab.e-ie .e-tab-header .e-hor-nav.e-ie-align,.e-tab.e-ie .e-tab-header .e-scroll-nav.e-ie-align{display:flex}.e-tab.e-ie .e-tab-header .e-hor-nav.e-ie-align .e-popup-up-icon,.e-tab.e-ie .e-tab-header .e-hor-nav.e-ie-align .e-popup-down-icon,.e-tab.e-ie .e-tab-header .e-scroll-nav.e-ie-align .e-popup-up-icon,.e-tab.e-ie .e-tab-header .e-scroll-nav.e-ie-align .e-popup-down-icon{display:block;line-height:15px}.e-tab.e-ie .e-tab-header .e-hor-nav.e-ie-align .e-nav-left-arrow,.e-tab.e-ie .e-tab-header .e-hor-nav.e-ie-align .e-nav-right-arrow,.e-tab.e-ie .e-tab-header .e-scroll-nav.e-ie-align .e-nav-left-arrow,.e-tab.e-ie .e-tab-header .e-scroll-nav.e-ie-align .e-nav-right-arrow{display:block;line-height:14px}.e-tab.e-ie .e-tab-header .e-popup-up-icon,.e-tab.e-ie .e-tab-header .e-popup-down-icon{transform:none;transition:none}.e-tab.e-ie .e-tab-header .e-popup-up-icon:before{transform:rotate(180deg);transition:transform .1s ease}@media screen and (max-width: 480px){.e-tab.e-ie .e-tab-header .e-popup-up-icon:before{transform:none;transition:none}}.e-tab.e-ie .e-tab-header .e-popup-down-icon:before{transform:rotate(0);transition:transform .1s ease}@media screen and (max-width: 480px){.e-tab.e-ie .e-tab-header .e-popup-down-icon:before{transform:none;transition:none}}.e-tab.e-edge .e-tab-header .e-hor-nav.e-ie-align,.e-tab.e-edge .e-tab-header .e-scroll-nav.e-ie-align{display:flex}.e-tab.e-edge .e-tab-header .e-hor-nav.e-ie-align .e-popup-up-icon,.e-tab.e-edge .e-tab-header .e-hor-nav.e-ie-align .e-popup-down-icon,.e-tab.e-edge .e-tab-header .e-scroll-nav.e-ie-align .e-popup-up-icon,.e-tab.e-edge .e-tab-header .e-scroll-nav.e-ie-align .e-popup-down-icon{display:block;line-height:14px;position:relative}.e-tab.e-edge .e-tab-header .e-hor-nav.e-ie-align .e-nav-left-arrow,.e-tab.e-edge .e-tab-header .e-hor-nav.e-ie-align .e-nav-right-arrow,.e-tab.e-edge .e-tab-header .e-scroll-nav.e-ie-align .e-nav-left-arrow,.e-tab.e-edge .e-tab-header .e-scroll-nav.e-ie-align .e-nav-right-arrow{display:block;line-height:11px;position:relative}.e-tab.e-edge .e-tab-header .e-popup-up-icon{transform:rotate(180deg);transition:transform .1s ease}@media screen and (max-width: 480px){.e-tab.e-edge .e-tab-header .e-popup-up-icon{transform:none;transition:none}}.e-tab.e-edge .e-tab-header .e-popup-down-icon{transform:rotate(0);transition:transform .1s ease}@media screen and (max-width: 480px){.e-tab.e-edge .e-tab-header .e-popup-down-icon{transform:none;transition:none}}@media screen and (max-width: 480px) and (max-width: 480px){.e-tab.e-edge .e-tab-header .e-popup-down-icon{transform:none;transition:none}}.e-tab.e-edge .e-tab-header .e-popup-up-icon:before{transform:rotate(180deg);transition:transform .1s ease}@media screen and (max-width: 480px){.e-tab.e-edge .e-tab-header .e-popup-up-icon:before{transform:none;transition:none}}.e-tab.e-edge .e-tab-header .e-popup-down-icon:before{transform:rotate(0);transition:transform .1s ease}@media screen and (max-width: 480px){.e-tab.e-edge .e-tab-header .e-popup-down-icon:before{transform:none;transition:none}}.e-tab.e-safari .e-tab-header .e-close-icon:before{top:-1px}.e-tab.e-safari .e-tab-header .e-hor-nav .e-popup-up-icon:before,.e-tab.e-safari .e-tab-header .e-hor-nav .e-popup-down-icon:before,.e-tab.e-safari .e-tab-header .e-scroll-nav .e-popup-up-icon:before,.e-tab.e-safari .e-tab-header .e-scroll-nav .e-popup-down-icon:before{top:0}.e-tab.e-safari .e-tab-header .e-hor-nav .e-nav-left-arrow:before,.e-tab.e-safari .e-tab-header .e-hor-nav .e-nav-right-arrow:before,.e-tab.e-safari .e-tab-header .e-scroll-nav .e-nav-left-arrow:before,.e-tab.e-safari .e-tab-header .e-scroll-nav .e-nav-right-arrow:before{top:0}.e-tab.e-fill .e-tab-header{height:34px;min-height:34px}@media screen and (max-width: 480px){.e-tab.e-fill .e-tab-header{height:46px;min-height:46px}}.e-tab.e-fill .e-tab-header .e-indicator{display:none}.e-tab.e-fill .e-tab-header .e-toolbar-items{height:auto;min-height:34px}@media screen and (max-width: 480px){.e-tab.e-fill .e-tab-header .e-toolbar-items{min-height:46px}}.e-tab.e-fill .e-tab-header .e-toolbar-items:not(.e-tbar-pos) .e-toolbar-item:first-child,.e-tab.e-fill .e-tab-header .e-toolbar-items:not(.e-tbar-pos) .e-toolbar-item:last-child{margin:0;padding:0}.e-tab.e-fill .e-tab-header .e-toolbar-item:not(.e-separator){height:34px;margin:0;min-height:34px;padding:0}@media screen and (max-width: 480px){.e-tab.e-fill .e-tab-header .e-toolbar-item:not(.e-separator){height:46px;min-height:46px}}.e-tab.e-fill .e-tab-header .e-toolbar-item:not(.e-separator).e-itop,.e-tab.e-fill .e-tab-header .e-toolbar-item:not(.e-separator).e-ibottom{height:60px;min-height:60px}.e-tab.e-fill .e-tab-header .e-toolbar-item .e-tab-wrap{height:34px;padding:0 18px}@media screen and (max-width: 480px){.e-tab.e-fill .e-tab-header .e-toolbar-item .e-tab-wrap{height:46px;padding:0 18px}}.e-tab.e-fill .e-tab-header .e-toolbar-item .e-text-wrap{height:34px}@media screen and (max-width: 480px){.e-tab.e-fill .e-tab-header .e-toolbar-item .e-text-wrap{height:46px}}.e-tab.e-fill .e-tab-header .e-toolbar-item.e-active{padding:0}.e-tab.e-fill .e-tab-header .e-toolbar-item.e-active .e-tab-wrap{margin-bottom:0}.e-tab.e-fill .e-tab-header .e-toolbar-item.e-active .e-text-wrap{height:34px}@media screen and (max-width: 480px){.e-tab.e-fill .e-tab-header .e-toolbar-item.e-active .e-text-wrap{height:46px}}.e-tab.e-fill .e-tab-header .e-toolbar-item.e-active .e-tab-text{font-weight:500}.e-tab.e-fill .e-tab-header .e-toolbar-item.e-active.e-ileft .e-text-wrap,.e-tab.e-fill .e-tab-header .e-toolbar-item.e-active.e-iright .e-text-wrap{height:36px}@media screen and (max-width: 480px){.e-tab.e-fill .e-tab-header .e-toolbar-item.e-active.e-ileft .e-text-wrap,.e-tab.e-fill .e-tab-header .e-toolbar-item.e-active.e-iright .e-text-wrap{height:46px}}.e-tab.e-fill .e-tab-header .e-toolbar-item.e-itop .e-tab-wrap,.e-tab.e-fill .e-tab-header .e-toolbar-item.e-ibottom .e-tab-wrap{height:60px}.e-tab.e-fill .e-tab-header .e-toolbar-item.e-itop .e-text-wrap,.e-tab.e-fill .e-tab-header .e-toolbar-item.e-ibottom .e-text-wrap{height:auto}.e-tab.e-fill .e-tab-header .e-toolbar-pop .e-toolbar-item.e-itop:not(.e-separator),.e-tab.e-fill .e-tab-header .e-toolbar-pop .e-toolbar-item.e-ibottom:not(.e-separator){height:auto}.e-tab.e-fill .e-tab-header.e-horizontal-bottom .e-toolbar-items:not(.e-tbar-pos) .e-toolbar-item:first-child.e-active,.e-tab.e-fill .e-tab-header.e-horizontal-bottom .e-toolbar-items:not(.e-tbar-pos) .e-toolbar-item:last-child.e-active{padding:0}.e-tab.e-fill .e-tab-header.e-horizontal-bottom .e-toolbar-items:not(.e-tbar-pos) .e-toolbar-item.e-itop,.e-tab.e-fill .e-tab-header.e-horizontal-bottom .e-toolbar-items:not(.e-tbar-pos) .e-toolbar-item:first-child.e-itop,.e-tab.e-fill .e-tab-header.e-horizontal-bottom .e-toolbar-items:not(.e-tbar-pos) .e-toolbar-item:last-child.e-itop{padding-top:0}.e-tab.e-fill .e-tab-header.e-horizontal-bottom .e-toolbar-item.e-active{margin-right:0;padding:0}.e-tab.e-fill .e-tab-header.e-horizontal-bottom .e-toolbar-item.e-active .e-text-wrap{height:34px}@media screen and (max-width: 480px){.e-tab.e-fill .e-tab-header.e-horizontal-bottom .e-toolbar-item.e-active .e-text-wrap{height:46px}}.e-tab.e-fill .e-tab-header.e-horizontal-bottom .e-toolbar-item.e-itop .e-tab-wrap:focus .e-text-wrap,.e-tab.e-fill .e-tab-header.e-horizontal-bottom .e-toolbar-item.e-ibottom .e-tab-wrap:focus .e-text-wrap{height:44px}.e-tab.e-fill .e-tab-header.e-horizontal-bottom .e-toolbar-item.e-itop .e-text-wrap,.e-tab.e-fill .e-tab-header.e-horizontal-bottom .e-toolbar-item.e-ibottom .e-text-wrap{height:auto}.e-tab.e-fill .e-tab-header.e-vertical .e-toolbar-items{height:inherit}.e-tab.e-fill .e-tab-header.e-vertical .e-toolbar-items .e-toolbar-item .e-tab-wrap{padding:0 18px}.e-tab.e-fill.e-focused .e-tab-header .e-toolbar-item .e-tab-wrap:focus{height:34px}.e-tab.e-fill.e-focused .e-tab-header .e-toolbar-item .e-tab-wrap:focus .e-text-wrap{height:34px}.e-tab.e-fill.e-focused .e-tab-header .e-toolbar-item.e-active .e-tab-wrap:focus .e-text-wrap{height:34px}.e-tab.e-fill.e-focused .e-tab-header .e-toolbar-item.e-itop .e-tab-wrap:focus,.e-tab.e-fill.e-focused .e-tab-header .e-toolbar-item.e-ibottom .e-tab-wrap:focus{height:60px}.e-tab.e-fill.e-focused .e-tab-header .e-toolbar-item.e-itop .e-tab-wrap:focus .e-text-wrap,.e-tab.e-fill.e-focused .e-tab-header .e-toolbar-item.e-ibottom .e-tab-wrap:focus .e-text-wrap{height:auto}@media screen and (max-width: 480px){.e-tab.e-fill.e-focused .e-tab-header .e-toolbar-item.e-itop .e-tab-wrap:focus .e-text-wrap,.e-tab.e-fill.e-focused .e-tab-header .e-toolbar-item.e-ibottom .e-tab-wrap:focus .e-text-wrap{height:auto}}.e-tab.e-fill.e-rtl .e-tab-header .e-toolbar-item:not(.e-separator){margin:0}.e-tab.e-fill.e-vertical-icon>.e-tab-header{height:60px;min-height:60px}.e-tab.e-background .e-tab-header .e-toolbar-items:not(.e-tbar-pos) .e-toolbar-item:first-child,.e-tab.e-background .e-tab-header .e-toolbar-items:not(.e-tbar-pos) .e-toolbar-item:last-child{margin:0;padding:0}.e-tab.e-background .e-tab-header .e-toolbar-item:not(.e-separator){margin:0;padding:0}.e-tab.e-background .e-tab-header .e-toolbar-item .e-tab-wrap{padding:0 18px}@media screen and (max-width: 480px){.e-tab.e-background .e-tab-header .e-toolbar-item .e-tab-wrap{padding:0 18px}}.e-tab.e-background .e-tab-header .e-toolbar-item.e-active{padding:0}.e-tab.e-background .e-tab-header .e-toolbar-item.e-active .e-tab-wrap{margin-bottom:0}.e-tab.e-background .e-tab-header .e-toolbar-item.e-active .e-tab-text{font-weight:500}.e-tab.e-background .e-tab-header.e-vertical .e-indicator{display:block}.e-tab.e-background .e-tab-header.e-vertical .e-toolbar-items .e-toolbar-item .e-tab-wrap{padding:0 18px}.e-tab.e-background .e-tab-header.e-horizontal-bottom .e-toolbar-items:not(.e-tbar-pos) .e-toolbar-item:first-child.e-active,.e-tab.e-background .e-tab-header.e-horizontal-bottom .e-toolbar-items:not(.e-tbar-pos) .e-toolbar-item:last-child.e-active{padding:0}.e-tab.e-background .e-tab-header.e-horizontal-bottom .e-toolbar-item.e-active{margin:0;padding:0}.e-tab.e-background .e-tab-header .e-toolbar-pop .e-toolbar-item.e-active .e-text-wrap{height:36px}.e-tab.e-background.e-rtl .e-tab-header .e-toolbar-item:not(.e-separator){margin:0}.e-tab.e-rtl .e-tab-header .e-toolbar-items:not(.e-tbar-pos) .e-toolbar-item:first-child,.e-tab.e-rtl .e-tab-header .e-toolbar-items:not(.e-tbar-pos) .e-toolbar-item:last-child{margin:0}.e-tab.e-rtl .e-tab-header .e-toolbar-item:not(.e-separator){margin:0}.e-tab.e-rtl .e-tab-header .e-toolbar-item:not(.e-separator) .e-icon-right{margin:0}.e-tab.e-rtl .e-tab-header .e-toolbar-item:not(.e-separator) .e-icon-left+.e-tab-text{margin:0 10px 0 0}.e-tab.e-rtl .e-tab-header .e-toolbar-item:not(.e-separator) .e-icons.e-close-icon{margin:0 10px 0 0}.e-tab.e-rtl .e-tab-header .e-toolbar-item:not(.e-separator).e-itop .e-close-icon,.e-tab.e-rtl .e-tab-header .e-toolbar-item:not(.e-separator).e-ibottom .e-close-icon{left:18px;right:auto}.e-tab.e-rtl .e-tab-header.e-close-show .e-toolbar-item.e-itop .e-text-wrap,.e-tab.e-rtl .e-tab-header.e-close-show .e-toolbar-item.e-ibottom .e-text-wrap{margin-left:20px;margin-right:0}.e-tab.e-rtl .e-tab-header.e-horizontal-bottom .e-toolbar-items:not(.e-tbar-pos) .e-toolbar-item:not(.e-separator){margin:0}.e-tab.e-rtl .e-tab-header .e-toolbar-pop .e-toolbar-item{margin:0}.e-tab.e-rtl .e-tab-header .e-toolbar-pop .e-toolbar-item .e-tab-text{padding-left:10px;padding-right:0}@media screen and (max-width: 480px){.e-tab.e-rtl .e-tab-header .e-toolbar-pop .e-toolbar-item .e-tab-text{padding-left:0}}.e-tab.e-rtl .e-tab-header .e-toolbar-pop .e-toolbar-item .e-icons.e-close-icon{margin:0}.e-tab.e-rtl .e-tab-header .e-toolbar-pop .e-toolbar-item .e-close-icon{left:16px;right:auto}.e-tab.e-rtl .e-tab-header .e-toolbar-pop .e-toolbar-item.e-itop .e-close-icon,.e-tab.e-rtl .e-tab-header .e-toolbar-pop .e-toolbar-item.e-ibottom .e-close-icon{left:18px;right:auto}.e-tab.e-rtl .e-tab-header .e-toolbar-pop .e-toolbar-item.e-itop .e-tab-text,.e-tab.e-rtl .e-tab-header .e-toolbar-pop .e-toolbar-item.e-ibottom .e-tab-text{margin:0;padding-left:10px;padding-right:0}@media screen and (max-width: 480px){.e-tab.e-rtl .e-tab-header .e-toolbar-pop .e-toolbar-item.e-itop .e-tab-text,.e-tab.e-rtl .e-tab-header .e-toolbar-pop .e-toolbar-item.e-ibottom .e-tab-text{margin:0;padding-left:10px;padding-right:0}}.e-tab.e-rtl .e-tab-header .e-hor-nav,.e-tab.e-rtl .e-tab-header .e-scroll-right-nav,.e-tab.e-rtl .e-tab-header .e-scroll-left-nav{padding:0 9px}.e-tab.e-vertical-tab.e-icon-tab .e-tab-header.e-vertical .e-hor-nav .e-popup-up-icon:before,.e-tab.e-vertical-tab.e-icon-tab .e-tab-header.e-vertical .e-hor-nav .e-popup-down-icon:before{display:none}.e-tab.e-vertical-tab.e-icon-tab .e-tab-header.e-vertical .e-hor-nav .e-popup-up-icon:after,.e-tab.e-vertical-tab.e-icon-tab .e-tab-header.e-vertical .e-hor-nav .e-popup-down-icon:after{margin:0;width:100%}.e-tab-clone-element{overflow:visible;z-index:10000}.e-tab-clone-element:not(.e-separator){height:36px;margin:0;min-height:36px;min-width:auto;padding:0}@media screen and (max-width: 480px){.e-tab-clone-element:not(.e-separator){height:48px;min-height:48px}}.e-tab-clone-element .e-tab-wrap{height:36px;padding:0 18px;width:100%}@media screen and (max-width: 480px){.e-tab-clone-element .e-tab-wrap{height:48px;padding:0 12px}}.e-tab-clone-element .e-text-wrap{align-content:center;align-items:center;display:inline-flex;height:36px}@media screen and (max-width: 480px){.e-tab-clone-element .e-text-wrap{height:48px}}.e-tab-clone-element .e-tab-text{display:inherit;font-family:Roboto,Segoe UI,GeezaPro,"DejaVu Serif","sans-serif",-apple-system,BlinkMacSystemFont;font-size:13px;font-weight:500;text-transform:uppercase;align-self:auto}@media screen and (max-width: 480px){.e-tab-clone-element .e-tab-text{font-size:14px}}.e-tab-clone-element .e-icons.e-close-icon{display:none}.e-tab-clone-element .e-close-icon,.e-tab-clone-element .e-close-icon:before{font-size:10px}@media screen and (max-width: 480px){.e-tab-clone-element .e-close-icon,.e-tab-clone-element .e-close-icon:before{font-size:12px}}.e-tab-clone-element .e-close-icon:before{top:1px}.e-tab-clone-element .e-icons.e-tab-icon{display:inline-flex;height:20px;min-width:20px;width:20px;line-height:1}@media screen and (max-width: 480px){.e-tab-clone-element .e-icons.e-tab-icon{height:20px;width:20px}}.e-tab-clone-element .e-tab-icon,.e-tab-clone-element .e-tab-icon:before{font-size:18px}@media screen and (max-width: 480px){.e-tab-clone-element .e-tab-icon,.e-tab-clone-element .e-tab-icon:before{font-size:20px}}.e-tab-clone-element.e-icon .e-tab-wrap{justify-content:center;padding:0 18px}@media screen and (max-width: 480px){.e-tab-clone-element.e-icon .e-tab-wrap{padding:0 24px}}.e-tab-clone-element .e-icon-right{margin:0 0 0 8px}@media screen and (max-width: 480px){.e-tab-clone-element .e-icon-right{margin:0}}.e-tab-clone-element .e-icon-left+.e-tab-text{margin:0 0 0 10px}@media screen and (max-width: 480px){.e-tab-clone-element .e-icon-left+.e-tab-text{margin:0 0 0 14px}}.e-tab-clone-element.e-itop,.e-tab-clone-element.e-ibottom{height:62px}@media screen and (max-width: 480px){.e-tab-clone-element.e-itop,.e-tab-clone-element.e-ibottom{height:62px}}.e-tab-clone-element.e-itop .e-tab-wrap,.e-tab-clone-element.e-ibottom .e-tab-wrap{align-items:center;display:flex;height:62px;position:relative}@media screen and (max-width: 480px){.e-tab-clone-element.e-itop .e-tab-wrap,.e-tab-clone-element.e-ibottom .e-tab-wrap{height:62px}}.e-tab-clone-element.e-itop .e-tab-wrap:focus .e-text-wrap,.e-tab-clone-element.e-ibottom .e-tab-wrap:focus .e-text-wrap{height:auto}.e-tab-clone-element.e-itop .e-text-wrap,.e-tab-clone-element.e-ibottom .e-text-wrap{display:block;height:auto}.e-tab-clone-element.e-itop .e-close-icon,.e-tab-clone-element.e-ibottom .e-close-icon{position:absolute;right:18px;top:calc(50% - 6px)}@media screen and (max-width: 480px){.e-tab-clone-element.e-itop .e-close-icon,.e-tab-clone-element.e-ibottom .e-close-icon{right:12px}}.e-tab-clone-element.e-itop .e-tab-text{margin:8px 0 0}@media screen and (max-width: 480px){.e-tab-clone-element.e-itop .e-tab-text{margin:10px 0 0}}.e-tab-clone-element.e-ibottom .e-tab-text{margin:0 0 8px}@media screen and (max-width: 480px){.e-tab-clone-element.e-ibottom .e-tab-text{margin:0 0 10px}}.e-tab-clone-element .e-tab-icon.e-icon-top,.e-tab-clone-element .e-tab-icon.e-icon-bottom{align-items:center;display:flex;flex-direction:column;justify-content:center;margin:auto}.e-tab-clone-element.e-close-show .e-icons.e-close-icon{align-items:center;align-self:center;display:inline-flex}@media screen and (max-width: 480px){.e-tab-clone-element.e-close-show .e-icons.e-close-icon{display:none}}.e-tab-clone-element.e-close-show .e-toolbar-item.e-itop .e-text-wrap,.e-tab-clone-element.e-close-show .e-toolbar-item.e-ibottom .e-text-wrap{margin-right:20px}.e-tab{background:transparent;border:none}.e-tab .e-tab-header{background:inherit;border:0;border-radius:0;box-shadow:none;font-weight:400;border-bottom:0}.e-tab .e-tab-header:before{border-color:unset;border-style:solid}.e-tab .e-tab-header:not(.e-vertical):before{border-width:0}.e-tab .e-tab-header:not(.e-vertical) .e-toolbar-item.e-active{border-bottom:initial;margin-bottom:0}.e-tab .e-tab-header .e-toolbar-items{background:inherit}.e-tab .e-tab-header .e-indicator{background:#e3165b}.e-tab .e-tab-header .e-toolbar-item{background:inherit;border:none}.e-tab .e-tab-header .e-toolbar-item:hover,.e-tab .e-tab-header .e-toolbar-item.e-active:hover{background:inherit}.e-tab .e-tab-header .e-toolbar-item .e-ripple-element{background:#e3165b1f}.e-tab .e-tab-header .e-toolbar-item .e-tab-wrap{border-radius:0;color:#0000008a;border:0}.e-tab .e-tab-header .e-toolbar-item .e-tab-wrap .e-tab-icon{color:#0000008a}@media screen and (max-width: 480px){.e-tab .e-tab-header .e-toolbar-item .e-tab-wrap,.e-tab .e-tab-header .e-toolbar-item .e-tab-wrap .e-tab-icon{color:#0000008a}.e-tab .e-tab-header .e-toolbar-item .e-tab-wrap .e-close-icon{color:#000000de}}.e-tab .e-tab-header .e-toolbar-item .e-tab-wrap:hover{background:inherit;border:0;border-radius:0}@media screen and (max-width: 480px){.e-tab .e-tab-header .e-toolbar-item .e-tab-wrap:hover{background:inherit}}.e-tab .e-tab-header .e-toolbar-item .e-tab-wrap:hover .e-tab-text,.e-tab .e-tab-header .e-toolbar-item .e-tab-wrap:hover .e-tab-icon{color:#000000de}.e-tab .e-tab-header .e-toolbar-item.e-active{border:none;border-radius:0}.e-tab .e-tab-header .e-toolbar-item.e-active .e-tab-wrap{border:0}.e-tab .e-tab-header .e-toolbar-item.e-active .e-tab-wrap:hover .e-tab-text,.e-tab .e-tab-header .e-toolbar-item.e-active .e-tab-wrap:hover .e-tab-icon{color:#e3165b}.e-tab .e-tab-header .e-toolbar-item.e-active .e-text-wrap{position:unset}.e-tab .e-tab-header .e-toolbar-item.e-active .e-text-wrap:before{border:unset;content:unset;display:unset;position:unset;width:unset;top:unset}.e-tab .e-tab-header .e-toolbar-item.e-active .e-tab-text,.e-tab .e-tab-header .e-toolbar-item.e-active .e-tab-icon,.e-tab .e-tab-header .e-toolbar-item.e-active.e-ileft .e-tab-icon,.e-tab .e-tab-header .e-toolbar-item.e-active.e-iright .e-tab-icon,.e-tab .e-tab-header .e-toolbar-item.e-active.e-ileft .e-tab-text,.e-tab .e-tab-header .e-toolbar-item.e-active.e-iright .e-tab-text{color:#e3165b}.e-tab .e-tab-header .e-toolbar-item.e-active .e-close-icon,.e-tab .e-tab-header .e-toolbar-item .e-close-icon{color:#0000008a}.e-tab .e-tab-header .e-toolbar-item .e-close-icon:hover,.e-tab .e-tab-header .e-toolbar-item .e-close-icon:active{color:#000000de}.e-tab .e-tab-header .e-toolbar-item.e-disable.e-overlay{background:inherit;opacity:1;pointer-events:none}.e-tab .e-tab-header .e-toolbar-item.e-disable.e-overlay .e-tab-text,.e-tab .e-tab-header .e-toolbar-item.e-disable.e-overlay .e-tab-icon{color:#00000061}.e-tab .e-tab-header.e-reorder-active-item:not(.e-vertical) .e-toolbar-pop .e-toolbar-item.e-active{border:initial}.e-tab .e-tab-header .e-toolbar-pop{background:#fff;border:0;border-radius:0;box-shadow:0 2px 2px 1px #00000036;overflow-y:auto}.e-tab .e-tab-header .e-toolbar-pop[e-animate=true]{overflow-y:hidden}@media screen and (max-width: 480px){.e-tab .e-tab-header .e-toolbar-pop{box-shadow:0 2px 2px 1px #00000036}}.e-tab .e-tab-header .e-toolbar-pop .e-toolbar-item .e-tab-wrap .e-tab-text,.e-tab .e-tab-header .e-toolbar-pop .e-toolbar-item .e-tab-wrap .e-tab-icon{color:#0000008a}.e-tab .e-tab-header .e-toolbar-pop .e-toolbar-item .e-tab-wrap:hover{background:#eee;border:0;border-radius:0}.e-tab .e-tab-header .e-toolbar-pop .e-toolbar-item .e-tab-wrap:hover .e-tab-text,.e-tab .e-tab-header .e-toolbar-pop .e-toolbar-item .e-tab-wrap:hover .e-tab-icon,.e-tab .e-tab-header .e-toolbar-pop .e-toolbar-item .e-tab-wrap:hover .e-close-icon{color:#000000de}.e-tab .e-tab-header .e-toolbar-pop .e-toolbar-item .e-tab-wrap:active{background:#eee;border-color:unset}.e-tab .e-tab-header .e-toolbar-pop .e-toolbar-item .e-tab-wrap:active .e-tab-text,.e-tab .e-tab-header .e-toolbar-pop .e-toolbar-item .e-tab-wrap:active .e-tab-icon{color:#0000008a}.e-tab .e-tab-header .e-toolbar-pop .e-toolbar-item.e-active .e-tab-wrap .e-tab-text,.e-tab .e-tab-header .e-toolbar-pop .e-toolbar-item.e-active .e-tab-wrap .e-tab-icon{color:#e3165b}.e-tab .e-tab-header .e-toolbar-pop .e-toolbar-item.e-disable.e-overlay .e-tab-text,.e-tab .e-tab-header .e-toolbar-pop .e-toolbar-item.e-disable.e-overlay .e-tab-icon{color:#00000061}.e-tab .e-tab-header .e-scroll-nav,.e-tab .e-tab-header .e-hscroll:not(.e-scroll-device) .e-scroll-nav{background:inherit;border:0}.e-tab .e-tab-header .e-scroll-nav .e-nav-arrow,.e-tab .e-tab-header .e-hscroll:not(.e-scroll-device) .e-scroll-nav .e-nav-arrow{color:#0000008a;border:0}.e-tab .e-tab-header .e-scroll-nav .e-nav-arrow:hover,.e-tab .e-tab-header .e-hscroll:not(.e-scroll-device) .e-scroll-nav .e-nav-arrow:hover{background:initial;color:#000000de;border:0}.e-tab .e-tab-header .e-scroll-nav .e-nav-arrow:active,.e-tab .e-tab-header .e-hscroll:not(.e-scroll-device) .e-scroll-nav .e-nav-arrow:active{box-shadow:none;border:0}.e-tab .e-tab-header .e-scroll-nav:focus,.e-tab .e-tab-header .e-hscroll:not(.e-scroll-device) .e-scroll-nav:focus{background:inherit}.e-tab .e-tab-header .e-scroll-nav:focus .e-nav-arrow,.e-tab .e-tab-header .e-hscroll:not(.e-scroll-device) .e-scroll-nav:focus .e-nav-arrow{background:#0000001f;color:#000000de;border:0}.e-tab .e-tab-header .e-scroll-nav:focus .e-nav-arrow:hover,.e-tab .e-tab-header .e-hscroll:not(.e-scroll-device) .e-scroll-nav:focus .e-nav-arrow:hover{background:initial;color:#000000de}.e-tab .e-tab-header .e-scroll-nav:focus .e-nav-arrow:active,.e-tab .e-tab-header .e-hscroll:not(.e-scroll-device) .e-scroll-nav:focus .e-nav-arrow:active{background:#0000001f;border-color:unset;color:#000000de}.e-tab .e-tab-header .e-scroll-nav:active,.e-tab .e-tab-header .e-hscroll:not(.e-scroll-device) .e-scroll-nav:active{box-shadow:none;background:inherit;border:0}.e-tab .e-tab-header .e-scroll-nav.e-overlay .e-nav-arrow,.e-tab .e-tab-header .e-hscroll:not(.e-scroll-device) .e-scroll-nav.e-overlay .e-nav-arrow{color:#0000008a}.e-tab .e-tab-header .e-scroll-nav.e-overlay .e-nav-arrow:hover,.e-tab .e-tab-header .e-hscroll:not(.e-scroll-device) .e-scroll-nav.e-overlay .e-nav-arrow:hover{color:#0000008a;background:initial;border-color:unset}.e-tab .e-tab-header .e-hor-nav,.e-tab .e-tab-header .e-hor-nav:not(.e-expended-nav){background:transparent;border:0}.e-tab .e-tab-header .e-hor-nav .e-popup-up-icon,.e-tab .e-tab-header .e-hor-nav .e-popup-down-icon,.e-tab .e-tab-header .e-hor-nav:not(.e-expended-nav) .e-popup-up-icon,.e-tab .e-tab-header .e-hor-nav:not(.e-expended-nav) .e-popup-down-icon{color:#0000008a;border:0}.e-tab .e-tab-header .e-hor-nav .e-popup-up-icon:hover,.e-tab .e-tab-header .e-hor-nav .e-popup-down-icon:hover,.e-tab .e-tab-header .e-hor-nav:not(.e-expended-nav) .e-popup-up-icon:hover,.e-tab .e-tab-header .e-hor-nav:not(.e-expended-nav) .e-popup-down-icon:hover{background:initial;border:initial;border-radius:0}.e-tab .e-tab-header .e-hor-nav .e-popup-down-icon:hover,.e-tab .e-tab-header .e-hor-nav:not(.e-expended-nav) .e-popup-down-icon:hover{color:#000000de}.e-tab .e-tab-header .e-hor-nav:focus,.e-tab .e-tab-header .e-hor-nav:not(.e-expended-nav):focus{background:transparent}.e-tab .e-tab-header .e-hor-nav:focus .e-popup-up-icon,.e-tab .e-tab-header .e-hor-nav:focus .e-popup-down-icon,.e-tab .e-tab-header .e-hor-nav:not(.e-expended-nav):focus .e-popup-up-icon,.e-tab .e-tab-header .e-hor-nav:not(.e-expended-nav):focus .e-popup-down-icon{background:#0000001f;border:initial;border-radius:0;color:#000000de}.e-tab .e-tab-header .e-hor-nav:focus .e-popup-up-icon:hover,.e-tab .e-tab-header .e-hor-nav:focus .e-popup-down-icon:hover,.e-tab .e-tab-header .e-hor-nav:not(.e-expended-nav):focus .e-popup-up-icon:hover,.e-tab .e-tab-header .e-hor-nav:not(.e-expended-nav):focus .e-popup-down-icon:hover{background:initial;border:initial;border-radius:0}.e-tab .e-tab-header .e-hor-nav:focus .e-popup-up-icon:active,.e-tab .e-tab-header .e-hor-nav:focus .e-popup-down-icon:active,.e-tab .e-tab-header .e-hor-nav:not(.e-expended-nav):focus .e-popup-up-icon:active,.e-tab .e-tab-header .e-hor-nav:not(.e-expended-nav):focus .e-popup-down-icon:active{background:initial;color:#000000de;border:0;border-radius:0;box-shadow:none}.e-tab .e-tab-header .e-hor-nav:hover,.e-tab .e-tab-header .e-hor-nav:not(.e-expended-nav):hover{border:0;background:transparent}.e-tab .e-tab-header .e-hor-nav:hover:active,.e-tab .e-tab-header .e-hor-nav:not(.e-expended-nav):hover:active{background:transparent}.e-tab .e-tab-header .e-hor-nav:active,.e-tab .e-tab-header .e-hor-nav:not(.e-expended-nav):active{box-shadow:none;background:transparent}.e-tab .e-tab-header .e-hor-nav.e-nav-active,.e-tab .e-tab-header .e-hor-nav:not(.e-expended-nav).e-nav-active{background:inherit;border:0;box-shadow:none;border-radius:0}.e-tab .e-tab-header .e-hor-nav.e-nav-active .e-icons,.e-tab .e-tab-header .e-hor-nav:not(.e-expended-nav).e-nav-active .e-icons{color:#000000de}.e-tab .e-tab-header .e-hor-nav.e-nav-active:focus,.e-tab .e-tab-header .e-hor-nav:not(.e-expended-nav).e-nav-active:focus{border:0}.e-tab .e-tab-header.e-horizontal-bottom,.e-tab .e-tab-header.e-horizontal-bottom[style*="overflow: hidden"],.e-tab .e-tab-header.e-horizontal-bottom[style*="overflow: hidden"] .e-toolbar-items{border-color:unset;border-style:solid;border-width:0}.e-tab .e-tab-header.e-horizontal-bottom .e-toolbar-item .e-tab-wrap:hover{border-radius:0}.e-tab .e-tab-header.e-horizontal-bottom .e-toolbar-item.e-active{border-color:inherit unset unset;border-style:solid;border-width:0;margin-top:0;border-radius:0}.e-tab .e-tab-header.e-vertical{border-bottom:0}.e-tab .e-tab-header.e-vertical:before{border-width:0}.e-tab .e-tab-header.e-vertical .e-toolbar-item.e-active{border-bottom:0;border-top:0}.e-tab .e-tab-header.e-vertical.e-vertical-left .e-toolbar-item .e-tab-wrap:hover{border-radius:0}.e-tab .e-tab-header.e-vertical.e-vertical-left .e-toolbar-item.e-active{border-radius:0;border-right:initial}.e-tab .e-tab-header.e-vertical.e-vertical-right .e-toolbar-item .e-tab-wrap:hover{border-radius:0}.e-tab .e-tab-header.e-vertical.e-vertical-right .e-toolbar-item.e-active{border-left:initial;border-radius:0}.e-tab .e-tab-header.e-vertical .e-toolbar-pop{box-shadow:0 3px 1px -2px #0003,0 2px 2px #00000024,0 1px 5px #0000001f}.e-tab .e-tab-header.e-vertical .e-scroll-nav{background:inherit;border:1px solid transparent}.e-tab .e-tab-header.e-vertical .e-scroll-nav.e-scroll-up-nav{border-bottom-color:#0000001f}.e-tab .e-tab-header.e-vertical .e-scroll-nav.e-scroll-down-nav{border-top-color:#0000001f}.e-tab .e-tab-header.e-vertical .e-scroll-nav .e-nav-arrow{border:0}.e-tab .e-tab-header.e-vertical .e-scroll-nav .e-nav-arrow:hover{background:none}.e-tab .e-tab-header.e-vertical .e-scroll-nav:hover{background:#0000001f;border-color:rgba(0,0,0,.12) transparent transparent}.e-tab .e-tab-header.e-vertical .e-scroll-nav:hover:active:focus{background:#0000001f}.e-tab .e-tab-header.e-vertical .e-scroll-nav:hover .e-nav-arrow{color:#000000de}.e-tab .e-tab-header.e-vertical .e-scroll-nav:hover .e-nav-arrow:hover{background:none}.e-tab .e-tab-header.e-vertical .e-scroll-nav:focus{background:#0000001f}.e-tab .e-tab-header.e-vertical .e-scroll-nav:focus:hover:active .e-nav-arrow{color:none}.e-tab .e-tab-header.e-vertical .e-scroll-nav:focus .e-nav-arrow{background:none}.e-tab .e-tab-header.e-vertical .e-scroll-nav:focus .e-nav-arrow:hover{background:none;border:0}.e-tab .e-tab-header.e-vertical .e-hor-nav .e-popup-up-icon,.e-tab .e-tab-header.e-vertical .e-hor-nav .e-popup-down-icon{border:0}.e-tab .e-tab-header.e-vertical .e-hor-nav .e-popup-up-icon:hover,.e-tab .e-tab-header.e-vertical .e-hor-nav .e-popup-down-icon:hover{background:inherit;border:0;color:#000000de}.e-tab .e-tab-header.e-vertical .e-hor-nav:focus .e-popup-up-icon,.e-tab .e-tab-header.e-vertical .e-hor-nav:focus .e-popup-down-icon{background:inherit;border:0}.e-tab .e-tab-header.e-vertical .e-hor-nav:focus .e-popup-up-icon:hover,.e-tab .e-tab-header.e-vertical .e-hor-nav:focus .e-popup-up-icon:active,.e-tab .e-tab-header.e-vertical .e-hor-nav:focus .e-popup-up-icon:active:hover,.e-tab .e-tab-header.e-vertical .e-hor-nav:focus .e-popup-down-icon:hover,.e-tab .e-tab-header.e-vertical .e-hor-nav:focus .e-popup-down-icon:active,.e-tab .e-tab-header.e-vertical .e-hor-nav:focus .e-popup-down-icon:active:hover{background:inherit;border:0;box-shadow:none}.e-tab .e-tab-header.e-vertical .e-hor-nav:focus .e-popup-up-icon:active,.e-tab .e-tab-header.e-vertical .e-hor-nav:focus .e-popup-down-icon:active{color:#000000de}.e-tab .e-tab-header.e-vertical .e-hor-nav:hover .e-popup-up-icon,.e-tab .e-tab-header.e-vertical .e-hor-nav:hover .e-popup-down-icon{border:0}.e-tab.e-focused>.e-tab-header .e-toolbar-item .e-tab-wrap:focus{background:#e3165b1f;border:0}.e-tab.e-focused>.e-tab-header .e-toolbar-item .e-tab-wrap:focus .e-tab-icon,.e-tab.e-focused>.e-tab-header .e-toolbar-item .e-tab-wrap:focus .e-tab-text{color:#e3165b}.e-tab.e-focused>.e-tab-header .e-toolbar-item .e-tab-wrap:focus .e-tab-icon{color:#e3165b}.e-tab.e-focused>.e-tab-header .e-scroll-nav:focus .e-nav-arrow{color:#000000de}.e-tab.e-focused>.e-tab-header .e-hor-nav:focus .e-popup-up-icon,.e-tab.e-focused>.e-tab-header .e-hor-nav:focus .e-popup-down-icon{color:#000000de;background:#0000001f;border:initial}.e-tab.e-focused>.e-tab-header.e-vertical .e-scroll-nav:focus{border-color:rgba(0,0,0,.12) transparent transparent}.e-tab.e-focused>.e-tab-header.e-vertical .e-scroll-nav:focus .e-nav-arrow{border:0}.e-tab.e-focused>.e-tab-header.e-vertical .e-hor-nav .e-popup-up-icon,.e-tab.e-focused>.e-tab-header.e-vertical .e-hor-nav .e-popup-down-icon{border:0}.e-tab.e-focused>.e-tab-header.e-vertical .e-hor-nav:focus{outline:0}.e-tab.e-disable{pointer-events:none}.e-tab.e-disable .e-tab-header .e-indicator{background:#e3165b61}.e-tab.e-disable .e-tab-header .e-toolbar-item .e-tab-wrap{color:#00000061}.e-tab.e-disable .e-tab-header .e-toolbar-item.e-active .e-tab-text,.e-tab.e-disable .e-tab-header .e-toolbar-item.e-active .e-tab-icon{color:#e3165b61}.e-tab.e-disable .e-content{opacity:.38}.e-tab.e-fill .e-tab-header{border-bottom:2px Solid #e3165b}.e-tab.e-fill .e-tab-header .e-toolbar-items.e-hscroll,.e-tab.e-fill .e-tab-header .e-toolbar-item{border:0}.e-tab.e-fill .e-tab-header .e-toolbar-item .e-ripple-element{background:#0000000d}.e-tab.e-fill .e-tab-header .e-toolbar-item .e-tab-wrap{color:#0000008a}.e-tab.e-fill .e-tab-header .e-toolbar-item .e-tab-wrap:hover .e-tab-text,.e-tab.e-fill .e-tab-header .e-toolbar-item .e-tab-wrap:hover .e-tab-icon{color:#000000de}.e-tab.e-fill .e-tab-header .e-toolbar-item .e-text-wrap{margin-top:0}.e-tab.e-fill .e-tab-header .e-toolbar-item.e-active{border:0}.e-tab.e-fill .e-tab-header .e-toolbar-item.e-active.e-disable.e-overlay .e-tab-text,.e-tab.e-fill .e-tab-header .e-toolbar-item.e-active.e-disable.e-overlay .e-tab-icon{color:#00000061}.e-tab.e-fill .e-tab-header .e-toolbar-item.e-active .e-tab-wrap{background:#e3165b;border-radius:0;border-color:unset}.e-tab.e-fill .e-tab-header .e-toolbar-item.e-active .e-tab-wrap:hover .e-tab-text,.e-tab.e-fill .e-tab-header .e-toolbar-item.e-active .e-tab-wrap:hover .e-tab-icon{color:#fff}.e-tab.e-fill .e-tab-header .e-toolbar-item.e-active .e-text-wrap{margin-top:0}.e-tab.e-fill .e-tab-header .e-toolbar-item.e-active .e-text-wrap:before{border:unset}.e-tab.e-fill .e-tab-header .e-toolbar-item.e-active .e-tab-text,.e-tab.e-fill .e-tab-header .e-toolbar-item.e-active .e-tab-icon{color:#fff}.e-tab.e-fill .e-tab-header .e-toolbar-item.e-active .e-close-icon{color:#ffffffb3}.e-tab.e-fill .e-tab-header .e-toolbar-item.e-active .e-close-icon:hover{color:#fff}.e-tab.e-fill .e-tab-header .e-toolbar-pop .e-toolbar-item:active:hover .e-tab-text,.e-tab.e-fill .e-tab-header .e-toolbar-pop .e-toolbar-item:active:hover .e-tab-icon{color:#0000008a}.e-tab.e-fill .e-tab-header .e-toolbar-pop .e-tab-wrap:hover{background:#eee}.e-tab.e-fill .e-tab-header .e-toolbar-pop .e-tab-wrap:hover .e-tab-text,.e-tab.e-fill .e-tab-header .e-toolbar-pop .e-tab-wrap:hover .e-tab-icon,.e-tab.e-fill .e-tab-header .e-toolbar-pop .e-tab-wrap:hover .e-close-icon{color:#000000de}.e-tab.e-fill .e-tab-header.e-horizontal-bottom{border-bottom:0;border-top:2px Solid #e3165b}.e-tab.e-fill .e-tab-header.e-horizontal-bottom .e-toolbar-item.e-active .e-text-wrap{margin-top:0}.e-tab.e-fill .e-tab-header.e-vertical{border-bottom:0}.e-tab.e-fill .e-tab-header.e-vertical.e-vertical-left{border-right:2px Solid #e3165b}.e-tab.e-fill .e-tab-header.e-vertical.e-vertical-right{border-left:2px Solid #e3165b}.e-tab.e-fill.e-corner .e-tab-header .e-toolbar-item.e-active .e-tab-wrap{border-radius:3px 3px 0 0}.e-tab.e-fill.e-corner .e-tab-header.e-horizontal-bottom .e-toolbar-item.e-active .e-tab-wrap{border-radius:0 0 3px 3px}.e-tab.e-fill.e-disable .e-tab-header{border-bottom:2px Solid rgba(227,22,91,.38)}.e-tab.e-fill.e-disable .e-tab-header .e-toolbar-item .e-tab-wrap{color:#00000061}.e-tab.e-fill.e-disable .e-tab-header .e-toolbar-item.e-active{opacity:1}.e-tab.e-fill.e-disable .e-tab-header .e-toolbar-item.e-active .e-tab-wrap,.e-tab.e-fill.e-disable .e-tab-header .e-toolbar-item.e-active .e-tab-wrap:focus{background:#e3165b61}.e-tab.e-fill.e-disable .e-tab-header .e-toolbar-item.e-active .e-tab-wrap .e-tab-text,.e-tab.e-fill.e-disable .e-tab-header .e-toolbar-item.e-active .e-tab-wrap .e-tab-icon,.e-tab.e-fill.e-disable .e-tab-header .e-toolbar-item.e-active .e-tab-wrap:focus .e-tab-text,.e-tab.e-fill.e-disable .e-tab-header .e-toolbar-item.e-active .e-tab-wrap:focus .e-tab-icon{color:#ffffff61}.e-tab.e-fill.e-disable .e-tab-header.e-horizontal-bottom{border-bottom:0;border-top:2px Solid rgba(227,22,91,.38)}.e-tab.e-fill.e-focused .e-tab-header .e-toolbar-item .e-tab-wrap:focus .e-tab-icon,.e-tab.e-fill.e-focused .e-tab-header .e-toolbar-item .e-tab-wrap:focus .e-tab-text,.e-tab.e-fill.e-focused .e-tab-header .e-toolbar-item .e-tab-wrap:focus .e-close-icon{color:#000000de}.e-tab.e-fill.e-focused .e-tab-header .e-toolbar-item.e-active .e-tab-wrap:focus{background:#e3165bcc;border-color:unset}.e-tab.e-fill.e-focused .e-tab-header .e-toolbar-item.e-active .e-tab-wrap:focus .e-tab-text{color:#fff}.e-tab.e-fill.e-focused .e-tab-header .e-toolbar-item.e-active .e-tab-wrap:focus .e-close-icon{color:#000000de}.e-tab.e-fill.e-focused .e-tab-header .e-toolbar-item.e-active .e-tab-wrap:focus .e-tab-text,.e-tab.e-fill.e-focused .e-tab-header .e-toolbar-item.e-active .e-tab-wrap:focus .e-tab-icon{color:#fff}.e-tab.e-background .e-tab-header{background:#3f51b5;border:0}.e-tab.e-background .e-tab-header .e-toolbar-items{background:#3f51b5}.e-tab.e-background .e-tab-header .e-toolbar-items.e-hscroll{border:0}.e-tab.e-background .e-tab-header .e-indicator{background:#fff;bottom:0}.e-tab.e-background .e-tab-header .e-toolbar-item{border:0}.e-tab.e-background .e-tab-header .e-toolbar-item .e-ripple-element{background:#0000001a}.e-tab.e-background .e-tab-header .e-toolbar-item .e-tab-wrap{background:#3f51b5;border-color:unset}.e-tab.e-background .e-tab-header .e-toolbar-item .e-tab-wrap .e-tab-icon,.e-tab.e-background .e-tab-header .e-toolbar-item .e-tab-wrap .e-close-icon,.e-tab.e-background .e-tab-header .e-toolbar-item .e-tab-wrap .e-tab-text{color:#ffffffb3}.e-tab.e-background .e-tab-header .e-toolbar-item .e-tab-wrap .e-close-icon:hover{color:#ffffff8a}.e-tab.e-background .e-tab-header .e-toolbar-item .e-tab-wrap:hover{background:inherit;background-color:inherit;border-color:unset}.e-tab.e-background .e-tab-header .e-toolbar-item .e-tab-wrap:hover .e-tab-text,.e-tab.e-background .e-tab-header .e-toolbar-item .e-tab-wrap:hover .e-tab-icon{color:#fff}.e-tab.e-background .e-tab-header .e-toolbar-item .e-tab-wrap:hover .e-close-icon{color:#ffffffb3}.e-tab.e-background .e-tab-header .e-toolbar-item .e-tab-wrap:hover .e-close-icon:hover,.e-tab.e-background .e-tab-header .e-toolbar-item .e-tab-wrap:hover .e-close-icon:active{color:#fff}.e-tab.e-background .e-tab-header .e-toolbar-item.e-active{border:0;margin:0;background:inherit}.e-tab.e-background .e-tab-header .e-toolbar-item.e-active.e-disable.e-overlay .e-tab-text,.e-tab.e-background .e-tab-header .e-toolbar-item.e-active.e-disable.e-overlay .e-tab-icon{color:#00000061}.e-tab.e-background .e-tab-header .e-toolbar-item.e-active .e-tab-wrap{background:#3f51b5;border-color:unset;border-radius:0;border-style:solid;border-width:0}.e-tab.e-background .e-tab-header .e-toolbar-item.e-active .e-tab-wrap .e-tab-text,.e-tab.e-background .e-tab-header .e-toolbar-item.e-active .e-tab-wrap .e-tab-icon{color:#fff}.e-tab.e-background .e-tab-header .e-toolbar-item.e-active .e-tab-wrap .e-close-icon{color:#ffffffb3}.e-tab.e-background .e-tab-header .e-toolbar-item.e-active .e-tab-wrap:hover{background:#3f51b5;border-color:unset}.e-tab.e-background .e-tab-header .e-toolbar-item.e-active .e-tab-wrap:hover .e-tab-text,.e-tab.e-background .e-tab-header .e-toolbar-item.e-active .e-tab-wrap:hover .e-tab-icon{color:#fff}.e-tab.e-background .e-tab-header .e-toolbar-item.e-active .e-tab-wrap:hover .e-close-icon{color:#ffffffb3}.e-tab.e-background .e-tab-header .e-toolbar-item.e-active .e-tab-wrap:hover .e-close-icon:hover,.e-tab.e-background .e-tab-header .e-toolbar-item.e-active .e-tab-wrap:hover .e-close-icon:active{color:#fff}.e-tab.e-background .e-tab-header .e-toolbar-item.e-active .e-tab-wrap:hover:focus{background:inherit}.e-tab.e-background .e-tab-header .e-toolbar-item.e-active .e-tab-wrap:hover:focus .e-tab-icon,.e-tab.e-background .e-tab-header .e-toolbar-item.e-active .e-tab-wrap:hover:focus .e-tab-text{color:#fff}.e-tab.e-background .e-tab-header .e-toolbar-item.e-active .e-tab-wrap:focus{background:inherit}.e-tab.e-background .e-tab-header .e-toolbar-item.e-active .e-tab-wrap:focus .e-tab-text,.e-tab.e-background .e-tab-header .e-toolbar-item.e-active .e-tab-wrap:focus .e-tab-icon{color:#fff}.e-tab.e-background .e-tab-header .e-toolbar-item.e-active .e-tab-wrap:focus:hover .e-tab-text{color:#fff}.e-tab.e-background .e-tab-header .e-toolbar-item.e-active .e-tab-wrap:focus:hover .e-close-icon{color:#ffffffb3}.e-tab.e-background .e-tab-header .e-toolbar-item.e-active .e-text-wrap:before{border:unset}.e-tab.e-background .e-tab-header .e-toolbar-item.e-active .e-tab-text,.e-tab.e-background .e-tab-header .e-toolbar-item.e-active .e-tab-icon{color:#fff}.e-tab.e-background .e-tab-header .e-toolbar-item.e-active .e-close-icon{color:#ffffffb3}.e-tab.e-background .e-tab-header .e-toolbar-item.e-active .e-close-icon:hover,.e-tab.e-background .e-tab-header .e-toolbar-item.e-active .e-tab-text:hover{color:#fff}.e-tab.e-background .e-tab-header .e-toolbar-item.e-active.e-itop .e-tab-wrap,.e-tab.e-background .e-tab-header .e-toolbar-item.e-active.e-ibottom .e-tab-wrap{background:#3f51b500}.e-tab.e-background .e-tab-header .e-toolbar-item.e-disable .e-tab-text,.e-tab.e-background .e-tab-header .e-toolbar-item.e-disable .e-tab-icon,.e-tab.e-background .e-tab-header .e-toolbar-item.e-disable .e-close-icon{color:#ffffff61}.e-tab.e-background .e-tab-header .e-toolbar-pop .e-toolbar-item{background:#3f51b5}.e-tab.e-background .e-tab-header .e-toolbar-pop .e-toolbar-item .e-tab-wrap .e-tab-text,.e-tab.e-background .e-tab-header .e-toolbar-pop .e-toolbar-item .e-tab-wrap .e-tab-icon,.e-tab.e-background .e-tab-header .e-toolbar-pop .e-toolbar-item .e-tab-wrap .e-close-icon{color:#ffffffb3}.e-tab.e-background .e-tab-header .e-toolbar-pop .e-toolbar-item .e-tab-wrap:hover{background:#ffffff1f}.e-tab.e-background .e-tab-header .e-toolbar-pop .e-toolbar-item .e-tab-wrap:hover .e-tab-text,.e-tab.e-background .e-tab-header .e-toolbar-pop .e-toolbar-item .e-tab-wrap:hover .e-tab-icon,.e-tab.e-background .e-tab-header .e-toolbar-pop .e-toolbar-item .e-tab-wrap:hover .e-close-icon{color:#fff}.e-tab.e-background .e-tab-header .e-toolbar-pop .e-toolbar-item .e-tab-wrap:active .e-tab-text,.e-tab.e-background .e-tab-header .e-toolbar-pop .e-toolbar-item .e-tab-wrap:active .e-tab-icon,.e-tab.e-background .e-tab-header .e-toolbar-pop .e-toolbar-item .e-tab-wrap:active .e-close-icon{color:#ffffffb3}.e-tab.e-background .e-tab-header .e-hscroll:not(.e-scroll-device) .e-scroll-nav,.e-tab.e-background .e-tab-header .e-scroll-nav{background:inherit}.e-tab.e-background .e-tab-header .e-hscroll:not(.e-scroll-device) .e-scroll-nav .e-nav-arrow,.e-tab.e-background .e-tab-header .e-scroll-nav .e-nav-arrow{color:#ffffffb3;border:0}.e-tab.e-background .e-tab-header .e-hscroll:not(.e-scroll-device) .e-scroll-nav .e-nav-arrow:hover,.e-tab.e-background .e-tab-header .e-scroll-nav .e-nav-arrow:hover{background:inherit;color:#fff;border-color:unset}.e-tab.e-background .e-tab-header .e-hscroll:not(.e-scroll-device) .e-scroll-nav .e-nav-arrow:active,.e-tab.e-background .e-tab-header .e-scroll-nav .e-nav-arrow:active{background:unset;color:#ffffffb3}.e-tab.e-background .e-tab-header .e-hscroll:not(.e-scroll-device) .e-scroll-nav:focus .e-nav-arrow,.e-tab.e-background .e-tab-header .e-scroll-nav:focus .e-nav-arrow{color:#fff;border:0;background:#0000001f}.e-tab.e-background .e-tab-header .e-hscroll:not(.e-scroll-device) .e-scroll-nav:focus .e-nav-arrow:hover,.e-tab.e-background .e-tab-header .e-scroll-nav:focus .e-nav-arrow:hover{background:inherit;color:#fff}.e-tab.e-background .e-tab-header .e-hscroll:not(.e-scroll-device) .e-scroll-nav:focus .e-nav-arrow:active,.e-tab.e-background .e-tab-header .e-scroll-nav:focus .e-nav-arrow:active{background:#0000001f;border-color:unset;color:#fff}.e-tab.e-background .e-tab-header .e-hscroll:not(.e-scroll-device) .e-scroll-nav:active:after,.e-tab.e-background .e-tab-header .e-scroll-nav:active:after{animation:hscroll-alt-popup-shadow 1s ease-out 0ms}.e-tab.e-background .e-tab-header .e-hor-nav:not(.e-expended-nav),.e-tab.e-background .e-tab-header .e-hor-nav{background:transparent}.e-tab.e-background .e-tab-header .e-hor-nav:not(.e-expended-nav) .e-popup-up-icon,.e-tab.e-background .e-tab-header .e-hor-nav:not(.e-expended-nav) .e-popup-down-icon,.e-tab.e-background .e-tab-header .e-hor-nav .e-popup-up-icon,.e-tab.e-background .e-tab-header .e-hor-nav .e-popup-down-icon{color:#ffffffb3;border:0}.e-tab.e-background .e-tab-header .e-hor-nav:not(.e-expended-nav) .e-popup-up-icon:hover,.e-tab.e-background .e-tab-header .e-hor-nav:not(.e-expended-nav) .e-popup-down-icon:hover,.e-tab.e-background .e-tab-header .e-hor-nav .e-popup-up-icon:hover,.e-tab.e-background .e-tab-header .e-hor-nav .e-popup-down-icon:hover{background:inherit;border-color:unset;color:#fff}.e-tab.e-background .e-tab-header .e-hor-nav:not(.e-expended-nav) .e-popup-up-icon:active:hover,.e-tab.e-background .e-tab-header .e-hor-nav:not(.e-expended-nav) .e-popup-down-icon:active:hover,.e-tab.e-background .e-tab-header .e-hor-nav .e-popup-up-icon:active:hover,.e-tab.e-background .e-tab-header .e-hor-nav .e-popup-down-icon:active:hover{background:inherit;color:#fff}.e-tab.e-background .e-tab-header .e-hor-nav:not(.e-expended-nav):focus .e-popup-up-icon,.e-tab.e-background .e-tab-header .e-hor-nav:not(.e-expended-nav):focus .e-popup-down-icon,.e-tab.e-background .e-tab-header .e-hor-nav:focus .e-popup-up-icon,.e-tab.e-background .e-tab-header .e-hor-nav:focus .e-popup-down-icon{color:#fff;background:#0000001f;border:initial}.e-tab.e-background .e-tab-header .e-hor-nav:not(.e-expended-nav):focus .e-popup-up-icon:hover,.e-tab.e-background .e-tab-header .e-hor-nav:not(.e-expended-nav):focus .e-popup-down-icon:hover,.e-tab.e-background .e-tab-header .e-hor-nav:focus .e-popup-up-icon:hover,.e-tab.e-background .e-tab-header .e-hor-nav:focus .e-popup-down-icon:hover{background:inherit}.e-tab.e-background .e-tab-header .e-hor-nav:not(.e-expended-nav):focus .e-popup-up-icon:active,.e-tab.e-background .e-tab-header .e-hor-nav:not(.e-expended-nav):focus .e-popup-down-icon:active,.e-tab.e-background .e-tab-header .e-hor-nav:focus .e-popup-up-icon:active,.e-tab.e-background .e-tab-header .e-hor-nav:focus .e-popup-down-icon:active{background:initial;border-color:unset;color:#fff}.e-tab.e-background .e-tab-header .e-hor-nav:not(.e-expended-nav):active:after,.e-tab.e-background .e-tab-header .e-hor-nav:active:after{animation:tbar-alt-popup-shadow 1s ease-out 0ms}.e-tab.e-background .e-tab-header .e-hor-nav:not(.e-expended-nav).e-nav-active .e-popup-up-icon,.e-tab.e-background .e-tab-header .e-hor-nav.e-nav-active .e-popup-up-icon{color:#fff}.e-tab.e-background .e-tab-header.e-horizontal-bottom .e-toolbar-item.e-active{border:0;margin:0}.e-tab.e-background .e-tab-header.e-horizontal-bottom .e-toolbar-item.e-active .e-tab-wrap{border-color:unset;border-radius:0;border-style:solid;border-width:0}.e-tab.e-background .e-tab-header.e-vertical.e-vertical-left .e-toolbar-item.e-active{border-color:unset;border-style:solid;border-width:0;margin:0}.e-tab.e-background .e-tab-header.e-vertical.e-vertical-left .e-toolbar-item.e-active .e-tab-wrap{border-color:unset;border-radius:0;border-style:solid;border-width:0}.e-tab.e-background .e-tab-header.e-vertical.e-vertical-right .e-toolbar-item.e-active{border-color:unset;border-style:solid;border-width:0;margin:0}.e-tab.e-background .e-tab-header.e-vertical.e-vertical-right .e-toolbar-item.e-active .e-tab-wrap{border-color:unset;border-radius:0;border-style:solid;border-width:0}.e-tab.e-background .e-tab-header.e-vertical .e-scroll-nav .e-nav-arrow{border:0}.e-tab.e-background .e-tab-header.e-vertical .e-scroll-nav:focus .e-nav-arrow{border:0}.e-tab.e-background .e-tab-header.e-vertical .e-scroll-nav:focus .e-nav-arrow:hover{background:none}.e-tab.e-background .e-tab-header.e-vertical .e-scroll-nav:hover .e-nav-arrow{color:#fff}.e-tab.e-background .e-tab-header.e-vertical .e-hor-nav:focus .e-popup-up-icon,.e-tab.e-background .e-tab-header.e-vertical .e-hor-nav:focus .e-popup-down-icon{background:inherit;border-color:transparent}.e-tab.e-background .e-tab-header.e-vertical .e-hor-nav:focus .e-popup-up-icon:hover,.e-tab.e-background .e-tab-header.e-vertical .e-hor-nav:focus .e-popup-down-icon:hover{background:inherit;border-color:transparent}.e-tab.e-background .e-tab-header.e-vertical .e-hor-nav .e-popup-up-icon:hover,.e-tab.e-background .e-tab-header.e-vertical .e-hor-nav .e-popup-down-icon:hover{background:inherit;border-color:transparent}.e-tab.e-background.e-disable .e-tab-header .e-indicator{background:#ffffff61}.e-tab.e-background.e-disable .e-tab-header .e-toolbar-item .e-tab-wrap,.e-tab.e-background.e-disable .e-tab-header .e-toolbar-item .e-tab-wrap .e-tab-text,.e-tab.e-background.e-disable .e-tab-header .e-toolbar-item .e-tab-wrap .e-tab-icon{color:#ffffff61}.e-tab.e-background.e-disable .e-tab-header .e-toolbar-item .e-tab-wrap:focus .e-tab-text,.e-tab.e-background.e-disable .e-tab-header .e-toolbar-item .e-tab-wrap:focus .e-tab-icon{color:#ffffff61}.e-tab.e-background.e-disable .e-tab-header .e-toolbar-item.e-active{opacity:1}.e-tab.e-background.e-disable .e-tab-header .e-toolbar-item.e-active .e-tab-wrap,.e-tab.e-background.e-disable .e-tab-header .e-toolbar-item.e-active .e-tab-wrap:focus{background:#3f51b5;color:#ffffff61}.e-tab.e-background.e-disable .e-tab-header .e-toolbar-item.e-active .e-tab-wrap .e-tab-text,.e-tab.e-background.e-disable .e-tab-header .e-toolbar-item.e-active .e-tab-wrap .e-tab-icon,.e-tab.e-background.e-disable .e-tab-header .e-toolbar-item.e-active .e-tab-wrap:focus .e-tab-text,.e-tab.e-background.e-disable .e-tab-header .e-toolbar-item.e-active .e-tab-wrap:focus .e-tab-icon{color:#ffffff61}.e-tab.e-background.e-accent .e-tab-header .e-indicator{background:#e3165b}.e-tab.e-background.e-accent .e-tab-header.e-disable .e-indicator{background:#e3165b61}.e-tab.e-background.e-focused .e-tab-header .e-toolbar-item .e-tab-wrap:focus{background:#ffffff1f;border-color:unset}.e-tab.e-background.e-focused .e-tab-header .e-toolbar-item .e-tab-wrap:focus .e-tab-icon,.e-tab.e-background.e-focused .e-tab-header .e-toolbar-item .e-tab-wrap:focus .e-tab-text,.e-tab.e-background.e-focused .e-tab-header .e-toolbar-item .e-tab-wrap:focus .e-close-icon{color:#ffffffb3}.e-tab.e-background.e-focused .e-tab-header .e-toolbar-item.e-active .e-tab-wrap:focus{background:#ffffff1f;border-color:unset}.e-tab.e-background.e-focused .e-tab-header .e-toolbar-item.e-active .e-tab-wrap:focus .e-tab-text,.e-tab.e-background.e-focused .e-tab-header .e-toolbar-item.e-active .e-tab-wrap:focus .e-tab-icon{color:#fff}.e-tab.e-background.e-focused .e-tab-header .e-toolbar-item.e-active .e-tab-wrap:hover{background:#3f51b5;border:0;border-radius:0}.e-tab.e-background.e-focused .e-tab-header .e-toolbar-item.e-active .e-tab-wrap:focus .e-tab-text{color:#fff}.e-tab.e-background.e-focused .e-tab-header .e-toolbar-item.e-active .e-tab-wrap:focus .e-tab-icon{color:#fff}.e-tab.e-background.e-focused .e-tab-header .e-toolbar-item.e-active .e-tab-wrap:focus .e-close-icon{color:#ffffffb3}.e-tab.e-background.e-focused .e-tab-header .e-toolbar-item.e-active .e-tab-wrap:hover .e-tab-text,.e-tab.e-background.e-focused .e-tab-header .e-toolbar-item.e-active .e-tab-wrap:hover .e-tab-icon{color:#fff}.e-tab.e-background.e-focused .e-tab-header .e-toolbar-item.e-active .e-tab-wrap:hover .e-close-icon{color:#ffffffb3}.e-tab.e-background.e-focused .e-tab-header .e-toolbar-item.e-active .e-tab-wrap:focus:hover .e-tab-text{color:#fff}.e-tab.e-background.e-focused .e-tab-header .e-toolbar-item.e-active .e-tab-wrap:focus:hover .e-close-icon{color:#ffffffb3}.e-tab.e-background.e-focused .e-tab-header .e-toolbar-item.e-active.e-itop .e-tab-wrap,.e-tab.e-background.e-focused .e-tab-header .e-toolbar-item.e-active.e-ibottom .e-tab-wrap{background:#3f51b500}.e-tab.e-background.e-focused .e-tab-header .e-toolbar-item.e-active.e-itop .e-tab-wrap:focus,.e-tab.e-background.e-focused .e-tab-header .e-toolbar-item.e-active.e-ibottom .e-tab-wrap:focus{background:#ffffff1f}.e-tab.e-background.e-focused .e-tab-header .e-scroll-nav:focus .e-nav-arrow{color:#ffffffde}.e-tab.e-background.e-focused .e-tab-header .e-hor-nav:focus .e-popup-up-icon,.e-tab.e-background.e-focused .e-tab-header .e-hor-nav:focus .e-popup-down-icon{color:#ffffffde}.e-tab.e-rtl .e-tab-header .e-hscroll.e-rtl .e-scroll-nav{border:0}.e-tab .e-content{background:inherit}.e-tab .e-content .e-item{background:inherit;color:#000;font-size:14px}.e-tab-clone-element{background:#fff;color:#0000008a}.e-tab-clone-element .e-tab-wrap{border-radius:0;color:#0000008a;border:0}.e-tab-clone-element .e-tab-wrap .e-tab-icon{color:#0000008a}.e-bigger .e-tab .e-tab-header,.e-tab.e-bigger .e-tab-header{height:48px;min-height:48px}.e-bigger .e-tab .e-tab-header .e-toolbar-items,.e-tab.e-bigger .e-tab-header .e-toolbar-items{height:auto;min-height:auto}.e-bigger .e-tab .e-tab-header .e-toolbar-items:not(.e-tbar-pos) .e-toolbar-item:first-child,.e-bigger .e-tab .e-tab-header .e-toolbar-items:not(.e-tbar-pos) .e-toolbar-item:last-child,.e-tab.e-bigger .e-tab-header .e-toolbar-items:not(.e-tbar-pos) .e-toolbar-item:first-child,.e-tab.e-bigger .e-tab-header .e-toolbar-items:not(.e-tbar-pos) .e-toolbar-item:last-child{margin:0}@media screen and (max-width: 480px){.e-bigger .e-tab .e-tab-header .e-toolbar-items:not(.e-tbar-pos) .e-toolbar-item:first-child,.e-bigger .e-tab .e-tab-header .e-toolbar-items:not(.e-tbar-pos) .e-toolbar-item:last-child,.e-tab.e-bigger .e-tab-header .e-toolbar-items:not(.e-tbar-pos) .e-toolbar-item:first-child,.e-tab.e-bigger .e-tab-header .e-toolbar-items:not(.e-tbar-pos) .e-toolbar-item:last-child{margin:0}}.e-bigger .e-tab .e-tab-header .e-toolbar-items:not(.e-tbar-pos) .e-toolbar-item:last-child,.e-tab.e-bigger .e-tab-header .e-toolbar-items:not(.e-tbar-pos) .e-toolbar-item:last-child{padding-bottom:0}@media screen and (max-width: 480px){.e-bigger .e-tab .e-tab-header .e-toolbar-items:not(.e-tbar-pos) .e-toolbar-item:last-child,.e-tab.e-bigger .e-tab-header .e-toolbar-items:not(.e-tbar-pos) .e-toolbar-item:last-child{margin:0}}.e-bigger .e-tab .e-tab-header .e-toolbar-items .e-indicator+.e-toolbar-item:last-child.e-active,.e-tab.e-bigger .e-tab-header .e-toolbar-items .e-indicator+.e-toolbar-item:last-child.e-active{margin:0}.e-bigger .e-tab .e-tab-header .e-toolbar-items.e-hscroll:not(.e-tbar-pos) .e-toolbar-item:last-child,.e-tab.e-bigger .e-tab-header .e-toolbar-items.e-hscroll:not(.e-tbar-pos) .e-toolbar-item:last-child{margin:0}@media screen and (max-width: 480px){.e-bigger .e-tab .e-tab-header .e-toolbar-items.e-hscroll:not(.e-tbar-pos) .e-toolbar-item:last-child,.e-tab.e-bigger .e-tab-header .e-toolbar-items.e-hscroll:not(.e-tbar-pos) .e-toolbar-item:last-child{margin:0}}.e-bigger .e-tab .e-tab-header .e-toolbar-items.e-hscroll:not(.e-tbar-pos) .e-toolbar-item:last-child.e-active,.e-tab.e-bigger .e-tab-header .e-toolbar-items.e-hscroll:not(.e-tbar-pos) .e-toolbar-item:last-child.e-active{margin:0}.e-bigger .e-tab .e-tab-header .e-toolbar-items.e-hscroll .e-scroll-nav,.e-tab.e-bigger .e-tab-header .e-toolbar-items.e-hscroll .e-scroll-nav{width:50px}.e-bigger .e-tab .e-tab-header .e-toolbar-item:not(.e-separator),.e-tab.e-bigger .e-tab-header .e-toolbar-item:not(.e-separator){height:48px;margin:0;min-height:48px;min-width:auto;padding:0}@media screen and (max-width: 480px){.e-bigger .e-tab .e-tab-header .e-toolbar-item:not(.e-separator),.e-tab.e-bigger .e-tab-header .e-toolbar-item:not(.e-separator){margin:0}}.e-bigger .e-tab .e-tab-header .e-toolbar-item:not(.e-separator).e-itop,.e-bigger .e-tab .e-tab-header .e-toolbar-item:not(.e-separator).e-ibottom,.e-tab.e-bigger .e-tab-header .e-toolbar-item:not(.e-separator).e-itop,.e-tab.e-bigger .e-tab-header .e-toolbar-item:not(.e-separator).e-ibottom{height:72px;min-height:72px}.e-bigger .e-tab .e-tab-header .e-toolbar-item .e-tab-wrap,.e-tab.e-bigger .e-tab-header .e-toolbar-item .e-tab-wrap{height:48px;padding:0 24px}@media screen and (max-width: 480px){.e-bigger .e-tab .e-tab-header .e-toolbar-item .e-tab-wrap,.e-tab.e-bigger .e-tab-header .e-toolbar-item .e-tab-wrap{padding:0 12px}}.e-bigger .e-tab .e-tab-header .e-toolbar-item .e-text-wrap,.e-tab.e-bigger .e-tab-header .e-toolbar-item .e-text-wrap{height:48px}.e-bigger .e-tab .e-tab-header .e-toolbar-item .e-tab-text,.e-tab.e-bigger .e-tab-header .e-toolbar-item .e-tab-text{font-size:14px;margin-bottom:0}.e-bigger .e-tab .e-tab-header .e-toolbar-item.e-ileft:not(.e-icon) .e-tab-icon:before,.e-tab.e-bigger .e-tab-header .e-toolbar-item.e-ileft:not(.e-icon) .e-tab-icon:before{position:relative;top:1px}.e-bigger .e-tab .e-tab-header .e-toolbar-item.e-active,.e-tab.e-bigger .e-tab-header .e-toolbar-item.e-active{margin:0;padding-bottom:0}@media screen and (max-width: 480px){.e-bigger .e-tab .e-tab-header .e-toolbar-item.e-active,.e-tab.e-bigger .e-tab-header .e-toolbar-item.e-active{margin:0}}.e-bigger .e-tab .e-tab-header .e-toolbar-item.e-active.e-ileft:not(.e-icon) .e-tab-icon:before,.e-tab.e-bigger .e-tab-header .e-toolbar-item.e-active.e-ileft:not(.e-icon) .e-tab-icon:before{position:relative;top:1px}.e-bigger .e-tab .e-tab-header .e-toolbar-item.e-active .e-text-wrap,.e-tab.e-bigger .e-tab-header .e-toolbar-item.e-active .e-text-wrap{height:48px;margin-top:0}.e-bigger .e-tab .e-tab-header .e-toolbar-item.e-active.e-ileft .e-text-wrap,.e-bigger .e-tab .e-tab-header .e-toolbar-item.e-active.e-iright .e-text-wrap,.e-tab.e-bigger .e-tab-header .e-toolbar-item.e-active.e-ileft .e-text-wrap,.e-tab.e-bigger .e-tab-header .e-toolbar-item.e-active.e-iright .e-text-wrap{height:48px}.e-bigger .e-tab .e-tab-header .e-toolbar-item .e-icons.e-close-icon,.e-tab.e-bigger .e-tab-header .e-toolbar-item .e-icons.e-close-icon{cursor:pointer;margin:0 0 0 12px}@media screen and (max-width: 480px){.e-bigger .e-tab .e-tab-header .e-toolbar-item .e-icons.e-close-icon,.e-tab.e-bigger .e-tab-header .e-toolbar-item .e-icons.e-close-icon{margin:0 0 0 14px}}.e-bigger .e-tab .e-tab-header .e-toolbar-item .e-icons.e-close-icon,.e-bigger .e-tab .e-tab-header .e-toolbar-item .e-close-icon:before,.e-tab.e-bigger .e-tab-header .e-toolbar-item .e-icons.e-close-icon,.e-tab.e-bigger .e-tab-header .e-toolbar-item .e-close-icon:before{font-size:10px}@media screen and (max-width: 480px){.e-bigger .e-tab .e-tab-header .e-toolbar-item .e-icons.e-close-icon,.e-bigger .e-tab .e-tab-header .e-toolbar-item .e-close-icon:before,.e-tab.e-bigger .e-tab-header .e-toolbar-item .e-icons.e-close-icon,.e-tab.e-bigger .e-tab-header .e-toolbar-item .e-close-icon:before{font-size:12px}}.e-bigger .e-tab .e-tab-header .e-toolbar-item .e-icons.e-tab-icon,.e-tab.e-bigger .e-tab-header .e-toolbar-item .e-icons.e-tab-icon{height:24px;min-width:24px;width:24px;line-height:1}.e-bigger .e-tab .e-tab-header .e-toolbar-item .e-tab-icon,.e-bigger .e-tab .e-tab-header .e-toolbar-item .e-tab-icon:before,.e-tab.e-bigger .e-tab-header .e-toolbar-item .e-tab-icon,.e-tab.e-bigger .e-tab-header .e-toolbar-item .e-tab-icon:before{font-size:20px}.e-bigger .e-tab .e-tab-header .e-toolbar-item.e-icon .e-tab-wrap,.e-tab.e-bigger .e-tab-header .e-toolbar-item.e-icon .e-tab-wrap{padding:0 24px}.e-bigger .e-tab .e-tab-header .e-toolbar-item .e-icon-right,.e-tab.e-bigger .e-tab-header .e-toolbar-item .e-icon-right{margin:0 0 0 12px}@media screen and (max-width: 480px){.e-bigger .e-tab .e-tab-header .e-toolbar-item .e-icon-right,.e-tab.e-bigger .e-tab-header .e-toolbar-item .e-icon-right{margin:0}}.e-bigger .e-tab .e-tab-header .e-toolbar-item .e-icon-left+.e-tab-text,.e-tab.e-bigger .e-tab-header .e-toolbar-item .e-icon-left+.e-tab-text{margin:0 0 0 12px}@media screen and (max-width: 480px){.e-bigger .e-tab .e-tab-header .e-toolbar-item .e-icon-left+.e-tab-text,.e-tab.e-bigger .e-tab-header .e-toolbar-item .e-icon-left+.e-tab-text{margin:0 0 0 14px}}.e-bigger .e-tab .e-tab-header .e-toolbar-item.e-itop,.e-bigger .e-tab .e-tab-header .e-toolbar-item.e-ibottom,.e-tab.e-bigger .e-tab-header .e-toolbar-item.e-itop,.e-tab.e-bigger .e-tab-header .e-toolbar-item.e-ibottom,.e-bigger .e-tab .e-tab-header .e-toolbar-item.e-itop .e-tab-wrap,.e-bigger .e-tab .e-tab-header .e-toolbar-item.e-ibottom .e-tab-wrap,.e-tab.e-bigger .e-tab-header .e-toolbar-item.e-itop .e-tab-wrap,.e-tab.e-bigger .e-tab-header .e-toolbar-item.e-ibottom .e-tab-wrap{height:72px}.e-bigger .e-tab .e-tab-header .e-toolbar-item.e-itop .e-tab-wrap:focus .e-text-wrap,.e-bigger .e-tab .e-tab-header .e-toolbar-item.e-ibottom .e-tab-wrap:focus .e-text-wrap,.e-tab.e-bigger .e-tab-header .e-toolbar-item.e-itop .e-tab-wrap:focus .e-text-wrap,.e-tab.e-bigger .e-tab-header .e-toolbar-item.e-ibottom .e-tab-wrap:focus .e-text-wrap{height:auto}.e-bigger .e-tab .e-tab-header .e-toolbar-item.e-itop.e-active .e-tab-wrap,.e-bigger .e-tab .e-tab-header .e-toolbar-item.e-ibottom.e-active .e-tab-wrap,.e-tab.e-bigger .e-tab-header .e-toolbar-item.e-itop.e-active .e-tab-wrap,.e-tab.e-bigger .e-tab-header .e-toolbar-item.e-ibottom.e-active .e-tab-wrap{height:72px}.e-bigger .e-tab .e-tab-header .e-toolbar-item.e-itop.e-active .e-tab-wrap:focus .e-text-wrap,.e-bigger .e-tab .e-tab-header .e-toolbar-item.e-ibottom.e-active .e-tab-wrap:focus .e-text-wrap,.e-tab.e-bigger .e-tab-header .e-toolbar-item.e-itop.e-active .e-tab-wrap:focus .e-text-wrap,.e-tab.e-bigger .e-tab-header .e-toolbar-item.e-ibottom.e-active .e-tab-wrap:focus .e-text-wrap{height:auto}.e-bigger .e-tab .e-tab-header .e-toolbar-item.e-itop .e-close-icon,.e-bigger .e-tab .e-tab-header .e-toolbar-item.e-ibottom .e-close-icon,.e-tab.e-bigger .e-tab-header .e-toolbar-item.e-itop .e-close-icon,.e-tab.e-bigger .e-tab-header .e-toolbar-item.e-ibottom .e-close-icon{right:24px}.e-bigger .e-tab .e-tab-header .e-toolbar-item.e-itop .e-tab-text,.e-tab.e-bigger .e-tab-header .e-toolbar-item.e-itop .e-tab-text{margin:10px 0 0}.e-bigger .e-tab .e-tab-header .e-toolbar-item.e-ibottom .e-tab-text,.e-tab.e-bigger .e-tab-header .e-toolbar-item.e-ibottom .e-tab-text{margin:0 0 10px}.e-bigger .e-tab .e-tab-header.e-close-show .e-toolbar-item.e-itop .e-text-wrap,.e-bigger .e-tab .e-tab-header.e-close-show .e-toolbar-item.e-ibottom .e-text-wrap,.e-tab.e-bigger .e-tab-header.e-close-show .e-toolbar-item.e-itop .e-text-wrap,.e-tab.e-bigger .e-tab-header.e-close-show .e-toolbar-item.e-ibottom .e-text-wrap{margin-right:22px}.e-bigger .e-tab .e-tab-header .e-toolbar-pop .e-toolbar-item,.e-tab.e-bigger .e-tab-header .e-toolbar-pop .e-toolbar-item{height:48px;min-height:48px}.e-bigger .e-tab .e-tab-header .e-toolbar-pop .e-toolbar-item .e-tab-wrap,.e-tab.e-bigger .e-tab-header .e-toolbar-pop .e-toolbar-item .e-tab-wrap{height:48px;padding:0 16px}@media screen and (max-width: 480px){.e-bigger .e-tab .e-tab-header .e-toolbar-pop .e-toolbar-item .e-tab-wrap,.e-tab.e-bigger .e-tab-header .e-toolbar-pop .e-toolbar-item .e-tab-wrap{padding:0 16px}}.e-bigger .e-tab .e-tab-header .e-toolbar-pop .e-toolbar-item .e-text-wrap,.e-tab.e-bigger .e-tab-header .e-toolbar-pop .e-toolbar-item .e-text-wrap{height:48px}.e-bigger .e-tab .e-tab-header .e-toolbar-pop .e-toolbar-item .e-tab-text+.e-close-icon[style="display:block"],.e-tab.e-bigger .e-tab-header .e-toolbar-pop .e-toolbar-item .e-tab-text+.e-close-icon[style="display:block"]{padding-right:12px}@media screen and (max-width: 480px){.e-bigger .e-tab .e-tab-header .e-toolbar-pop .e-toolbar-item .e-tab-text+.e-close-icon[style="display:block"],.e-tab.e-bigger .e-tab-header .e-toolbar-pop .e-toolbar-item .e-tab-text+.e-close-icon[style="display:block"]{padding-right:0}}.e-bigger .e-tab .e-tab-header .e-toolbar-pop .e-toolbar-item .e-close-icon,.e-tab.e-bigger .e-tab-header .e-toolbar-pop .e-toolbar-item .e-close-icon{margin:0 0 0 8px}.e-bigger .e-tab .e-tab-header .e-toolbar-pop .e-toolbar-item .e-close-icon:before,.e-tab.e-bigger .e-tab-header .e-toolbar-pop .e-toolbar-item .e-close-icon:before{top:0}.e-bigger .e-tab .e-tab-header .e-toolbar-pop .e-toolbar-item.e-itop .e-close-icon,.e-bigger .e-tab .e-tab-header .e-toolbar-pop .e-toolbar-item.e-ibottom .e-close-icon,.e-tab.e-bigger .e-tab-header .e-toolbar-pop .e-toolbar-item.e-itop .e-close-icon,.e-tab.e-bigger .e-tab-header .e-toolbar-pop .e-toolbar-item.e-ibottom .e-close-icon{right:18px}.e-bigger .e-tab .e-tab-header .e-toolbar-pop .e-toolbar-item.e-itop:not(.e-separator),.e-bigger .e-tab .e-tab-header .e-toolbar-pop .e-toolbar-item.e-ibottom:not(.e-separator),.e-tab.e-bigger .e-tab-header .e-toolbar-pop .e-toolbar-item.e-itop:not(.e-separator),.e-tab.e-bigger .e-tab-header .e-toolbar-pop .e-toolbar-item.e-ibottom:not(.e-separator){min-height:48px}@media screen and (max-width: 480px){.e-bigger .e-tab .e-tab-header .e-toolbar-pop .e-toolbar-item.e-itop:not(.e-separator),.e-bigger .e-tab .e-tab-header .e-toolbar-pop .e-toolbar-item.e-ibottom:not(.e-separator),.e-tab.e-bigger .e-tab-header .e-toolbar-pop .e-toolbar-item.e-itop:not(.e-separator),.e-tab.e-bigger .e-tab-header .e-toolbar-pop .e-toolbar-item.e-ibottom:not(.e-separator){min-height:48px}}.e-bigger .e-tab .e-tab-header .e-toolbar-pop .e-toolbar-item.e-itop,.e-bigger .e-tab .e-tab-header .e-toolbar-pop .e-toolbar-item.e-itop .e-tab-wrap,.e-bigger .e-tab .e-tab-header .e-toolbar-pop .e-toolbar-item.e-ibottom,.e-bigger .e-tab .e-tab-header .e-toolbar-pop .e-toolbar-item.e-ibottom .e-tab-wrap,.e-tab.e-bigger .e-tab-header .e-toolbar-pop .e-toolbar-item.e-itop,.e-tab.e-bigger .e-tab-header .e-toolbar-pop .e-toolbar-item.e-itop .e-tab-wrap,.e-tab.e-bigger .e-tab-header .e-toolbar-pop .e-toolbar-item.e-ibottom,.e-tab.e-bigger .e-tab-header .e-toolbar-pop .e-toolbar-item.e-ibottom .e-tab-wrap{height:48px}@media screen and (max-width: 480px){.e-bigger .e-tab .e-tab-header .e-toolbar-pop .e-toolbar-item.e-itop,.e-bigger .e-tab .e-tab-header .e-toolbar-pop .e-toolbar-item.e-itop .e-tab-wrap,.e-bigger .e-tab .e-tab-header .e-toolbar-pop .e-toolbar-item.e-ibottom,.e-bigger .e-tab .e-tab-header .e-toolbar-pop .e-toolbar-item.e-ibottom .e-tab-wrap,.e-tab.e-bigger .e-tab-header .e-toolbar-pop .e-toolbar-item.e-itop,.e-tab.e-bigger .e-tab-header .e-toolbar-pop .e-toolbar-item.e-itop .e-tab-wrap,.e-tab.e-bigger .e-tab-header .e-toolbar-pop .e-toolbar-item.e-ibottom,.e-tab.e-bigger .e-tab-header .e-toolbar-pop .e-toolbar-item.e-ibottom .e-tab-wrap{height:48px}}.e-bigger .e-tab .e-tab-header .e-toolbar-pop .e-toolbar-item.e-itop .e-tab-text,.e-bigger .e-tab .e-tab-header .e-toolbar-pop .e-toolbar-item.e-ibottom .e-tab-text,.e-tab.e-bigger .e-tab-header .e-toolbar-pop .e-toolbar-item.e-itop .e-tab-text,.e-tab.e-bigger .e-tab-header .e-toolbar-pop .e-toolbar-item.e-ibottom .e-tab-text{margin:0;padding-left:0;padding-right:12px}@media screen and (max-width: 480px){.e-bigger .e-tab .e-tab-header .e-toolbar-pop .e-toolbar-item.e-itop .e-tab-text,.e-bigger .e-tab .e-tab-header .e-toolbar-pop .e-toolbar-item.e-ibottom .e-tab-text,.e-tab.e-bigger .e-tab-header .e-toolbar-pop .e-toolbar-item.e-itop .e-tab-text,.e-tab.e-bigger .e-tab-header .e-toolbar-pop .e-toolbar-item.e-ibottom .e-tab-text{margin:0;padding-left:0;padding-right:0}}.e-bigger .e-tab .e-tab-header .e-scroll-nav,.e-tab.e-bigger .e-tab-header .e-scroll-nav{height:48px;min-height:48px;padding:0 12px}@media screen and (max-width: 480px){.e-bigger .e-tab .e-tab-header .e-scroll-nav,.e-tab.e-bigger .e-tab-header .e-scroll-nav{padding:0 12px}}.e-bigger .e-tab .e-tab-header .e-scroll-nav.e-scroll-right-nav,.e-tab.e-bigger .e-tab-header .e-scroll-nav.e-scroll-right-nav,.e-bigger .e-tab .e-tab-header .e-scroll-nav.e-scroll-left-nav,.e-tab.e-bigger .e-tab-header .e-scroll-nav.e-scroll-left-nav{padding:0 12px}.e-bigger .e-tab .e-tab-header .e-scroll-nav .e-nav-arrow,.e-tab.e-bigger .e-tab-header .e-scroll-nav .e-nav-arrow{font-size:12px;height:24px;line-height:24px;width:24px}@media screen and (max-width: 480px){.e-bigger .e-tab .e-tab-header .e-scroll-nav .e-nav-arrow,.e-tab.e-bigger .e-tab-header .e-scroll-nav .e-nav-arrow{font-size:12px;height:24px;line-height:24px;width:24px}}.e-bigger .e-tab .e-tab-header .e-scroll-nav .e-nav-left-arrow:before,.e-bigger .e-tab .e-tab-header .e-scroll-nav .e-nav-right-arrow:before,.e-tab.e-bigger .e-tab-header .e-scroll-nav .e-nav-left-arrow:before,.e-tab.e-bigger .e-tab-header .e-scroll-nav .e-nav-right-arrow:before{font-size:12px;line-height:24px;top:0;vertical-align:initial}.e-bigger .e-tab .e-tab-header .e-hor-nav,.e-tab.e-bigger .e-tab-header .e-hor-nav{height:48px;min-height:48px;padding:0 12px}@media screen and (max-width: 480px){.e-bigger .e-tab .e-tab-header .e-hor-nav,.e-tab.e-bigger .e-tab-header .e-hor-nav{padding:0 12px}}.e-bigger .e-tab .e-tab-header .e-hor-nav .e-popup-up-icon,.e-bigger .e-tab .e-tab-header .e-hor-nav .e-popup-down-icon,.e-tab.e-bigger .e-tab-header .e-hor-nav .e-popup-up-icon,.e-tab.e-bigger .e-tab-header .e-hor-nav .e-popup-down-icon{font-size:12px;height:24px;line-height:24px;width:24px}@media screen and (max-width: 480px){.e-bigger .e-tab .e-tab-header .e-hor-nav .e-popup-up-icon,.e-bigger .e-tab .e-tab-header .e-hor-nav .e-popup-down-icon,.e-tab.e-bigger .e-tab-header .e-hor-nav .e-popup-up-icon,.e-tab.e-bigger .e-tab-header .e-hor-nav .e-popup-down-icon{font-size:12px;height:24px;line-height:24px;width:24px}}.e-bigger .e-tab .e-tab-header .e-hor-nav .e-popup-up-icon:before,.e-bigger .e-tab .e-tab-header .e-hor-nav .e-popup-down-icon:before,.e-tab.e-bigger .e-tab-header .e-hor-nav .e-popup-up-icon:before,.e-tab.e-bigger .e-tab-header .e-hor-nav .e-popup-down-icon:before{font-size:12px;line-height:24px;top:0;vertical-align:initial}@media screen and (max-width: 480px){.e-bigger .e-tab .e-tab-header .e-hor-nav .e-popup-up-icon:before,.e-bigger .e-tab .e-tab-header .e-hor-nav .e-popup-down-icon:before,.e-tab.e-bigger .e-tab-header .e-hor-nav .e-popup-up-icon:before,.e-tab.e-bigger .e-tab-header .e-hor-nav .e-popup-down-icon:before{font-size:16px}}.e-bigger .e-tab .e-tab-header .e-hor-nav .e-popup-up-icon:hover,.e-bigger .e-tab .e-tab-header .e-hor-nav .e-popup-down-icon:hover,.e-tab.e-bigger .e-tab-header .e-hor-nav .e-popup-up-icon:hover,.e-tab.e-bigger .e-tab-header .e-hor-nav .e-popup-down-icon:hover{line-height:24px}.e-bigger .e-tab .e-tab-header .e-hor-nav .e-popup-up-icon:hover:before,.e-bigger .e-tab .e-tab-header .e-hor-nav .e-popup-down-icon:hover:before,.e-tab.e-bigger .e-tab-header .e-hor-nav .e-popup-up-icon:hover:before,.e-tab.e-bigger .e-tab-header .e-hor-nav .e-popup-down-icon:hover:before{line-height:24px;top:0}.e-bigger .e-tab .e-tab-header .e-hor-nav:focus .e-popup-up-icon,.e-bigger .e-tab .e-tab-header .e-hor-nav:focus .e-popup-down-icon,.e-tab.e-bigger .e-tab-header .e-hor-nav:focus .e-popup-up-icon,.e-tab.e-bigger .e-tab-header .e-hor-nav:focus .e-popup-down-icon{line-height:24px}.e-bigger .e-tab .e-tab-header .e-hor-nav:focus .e-popup-up-icon:before,.e-bigger .e-tab .e-tab-header .e-hor-nav:focus .e-popup-down-icon:before,.e-tab.e-bigger .e-tab-header .e-hor-nav:focus .e-popup-up-icon:before,.e-tab.e-bigger .e-tab-header .e-hor-nav:focus .e-popup-down-icon:before{line-height:24px;top:0}.e-bigger .e-tab .e-tab-header .e-hor-nav:focus .e-popup-up-icon:hover,.e-bigger .e-tab .e-tab-header .e-hor-nav:focus .e-popup-down-icon:hover,.e-tab.e-bigger .e-tab-header .e-hor-nav:focus .e-popup-up-icon:hover,.e-tab.e-bigger .e-tab-header .e-hor-nav:focus .e-popup-down-icon:hover{line-height:24px;top:0}.e-bigger .e-tab .e-tab-header .e-hor-nav.e-ie-align .e-popup-up-icon,.e-bigger .e-tab .e-tab-header .e-hor-nav.e-ie-align .e-popup-down-icon,.e-bigger .e-tab .e-tab-header .e-scroll-nav.e-ie-align .e-popup-up-icon,.e-bigger .e-tab .e-tab-header .e-scroll-nav.e-ie-align .e-popup-down-icon,.e-tab.e-bigger .e-tab-header .e-hor-nav.e-ie-align .e-popup-up-icon,.e-tab.e-bigger .e-tab-header .e-hor-nav.e-ie-align .e-popup-down-icon,.e-tab.e-bigger .e-tab-header .e-scroll-nav.e-ie-align .e-popup-up-icon,.e-tab.e-bigger .e-tab-header .e-scroll-nav.e-ie-align .e-popup-down-icon,.e-bigger .e-tab .e-tab-header .e-hor-nav.e-ie-align .e-nav-left-arrow,.e-bigger .e-tab .e-tab-header .e-hor-nav.e-ie-align .e-nav-right-arrow,.e-bigger .e-tab .e-tab-header .e-scroll-nav.e-ie-align .e-nav-left-arrow,.e-bigger .e-tab .e-tab-header .e-scroll-nav.e-ie-align .e-nav-right-arrow,.e-tab.e-bigger .e-tab-header .e-hor-nav.e-ie-align .e-nav-left-arrow,.e-tab.e-bigger .e-tab-header .e-hor-nav.e-ie-align .e-nav-right-arrow,.e-tab.e-bigger .e-tab-header .e-scroll-nav.e-ie-align .e-nav-left-arrow,.e-tab.e-bigger .e-tab-header .e-scroll-nav.e-ie-align .e-nav-right-arrow{line-height:15px}.e-bigger .e-tab .e-tab-header.e-horizontal-bottom .e-toolbar-items:not(.e-tbar-pos) .e-toolbar-item:last-child.e-active,.e-tab.e-bigger .e-tab-header.e-horizontal-bottom .e-toolbar-items:not(.e-tbar-pos) .e-toolbar-item:last-child.e-active{margin:0}.e-bigger .e-tab .e-tab-header.e-horizontal-bottom .e-toolbar-item.e-active,.e-tab.e-bigger .e-tab-header.e-horizontal-bottom .e-toolbar-item.e-active{margin:0;padding-bottom:0}@media screen and (max-width: 480px){.e-bigger .e-tab .e-tab-header.e-horizontal-bottom .e-toolbar-item.e-active,.e-tab.e-bigger .e-tab-header.e-horizontal-bottom .e-toolbar-item.e-active{margin:0}}.e-bigger .e-tab .e-tab-header.e-horizontal-bottom .e-toolbar-item.e-active .e-tab-text,.e-tab.e-bigger .e-tab-header.e-horizontal-bottom .e-toolbar-item.e-active .e-tab-text{padding-top:0}.e-bigger .e-tab .e-tab-header.e-horizontal-bottom .e-toolbar-item.e-active .e-close-icon:before,.e-tab.e-bigger .e-tab-header.e-horizontal-bottom .e-toolbar-item.e-active .e-close-icon:before{top:0}.e-bigger .e-tab .e-tab-header.e-horizontal-bottom .e-toolbar-item.e-active.e-itop .e-close-icon:before,.e-bigger .e-tab .e-tab-header.e-horizontal-bottom .e-toolbar-item.e-active.e-ibottom .e-close-icon:before,.e-tab.e-bigger .e-tab-header.e-horizontal-bottom .e-toolbar-item.e-active.e-itop .e-close-icon:before,.e-tab.e-bigger .e-tab-header.e-horizontal-bottom .e-toolbar-item.e-active.e-ibottom .e-close-icon:before{top:0}.e-bigger .e-tab .e-tab-header.e-horizontal-bottom .e-toolbar-item.e-active:last-child,.e-tab.e-bigger .e-tab-header.e-horizontal-bottom .e-toolbar-item.e-active:last-child{margin:0;padding-bottom:0}@media screen and (max-width: 480px){.e-bigger .e-tab .e-tab-header.e-horizontal-bottom .e-toolbar-item.e-active:last-child,.e-tab.e-bigger .e-tab-header.e-horizontal-bottom .e-toolbar-item.e-active:last-child{margin:0}}.e-bigger .e-tab .e-tab-header.e-horizontal-bottom .e-toolbar-item.e-active:last-child .e-tab-text,.e-tab.e-bigger .e-tab-header.e-horizontal-bottom .e-toolbar-item.e-active:last-child .e-tab-text{padding-top:0}.e-bigger .e-tab .e-tab-header.e-horizontal-bottom .e-toolbar-item.e-active:last-child .e-close-icon:before,.e-tab.e-bigger .e-tab-header.e-horizontal-bottom .e-toolbar-item.e-active:last-child .e-close-icon:before{top:0}.e-bigger .e-tab .e-tab-header.e-horizontal-bottom .e-toolbar-item.e-itop,.e-bigger .e-tab .e-tab-header.e-horizontal-bottom .e-toolbar-item.e-ibottom,.e-tab.e-bigger .e-tab-header.e-horizontal-bottom .e-toolbar-item.e-itop,.e-tab.e-bigger .e-tab-header.e-horizontal-bottom .e-toolbar-item.e-ibottom{padding-bottom:0;padding-top:0}.e-bigger .e-tab .e-tab-header.e-horizontal-bottom .e-toolbar-item.e-ileft.e-active .e-text-wrap,.e-tab.e-bigger .e-tab-header.e-horizontal-bottom .e-toolbar-item.e-ileft.e-active .e-text-wrap{margin:0}.e-bigger .e-tab .e-tab-header.e-horizontal-bottom .e-toolbar-item.e-active .e-text-wrap,.e-tab.e-bigger .e-tab-header.e-horizontal-bottom .e-toolbar-item.e-active .e-text-wrap{height:48px;padding:0}.e-bigger .e-tab .e-tab-header.e-horizontal-bottom .e-toolbar-item.e-itop.e-active .e-text-wrap,.e-bigger .e-tab .e-tab-header.e-horizontal-bottom .e-toolbar-item.e-ibottom.e-active .e-text-wrap,.e-tab.e-bigger .e-tab-header.e-horizontal-bottom .e-toolbar-item.e-itop.e-active .e-text-wrap,.e-tab.e-bigger .e-tab-header.e-horizontal-bottom .e-toolbar-item.e-ibottom.e-active .e-text-wrap{height:initial}.e-bigger .e-tab .e-tab-header.e-horizontal-bottom .e-toolbar-item.e-ileft.e-active,.e-tab.e-bigger .e-tab-header.e-horizontal-bottom .e-toolbar-item.e-ileft.e-active{height:48px}.e-bigger .e-tab .e-tab-header.e-vertical,.e-tab.e-bigger .e-tab-header.e-vertical{max-width:150px}.e-bigger .e-tab .e-tab-header.e-vertical[style*="overflow: hidden"]:before,.e-tab.e-bigger .e-tab-header.e-vertical[style*="overflow: hidden"]:before{bottom:23px;top:23px}@media screen and (max-width: 480px){.e-bigger .e-tab .e-tab-header.e-vertical[style*="overflow: hidden"]:before,.e-tab.e-bigger .e-tab-header.e-vertical[style*="overflow: hidden"]:before{bottom:0;top:0}}.e-bigger .e-tab .e-tab-header.e-vertical .e-toolbar-items,.e-tab.e-bigger .e-tab-header.e-vertical .e-toolbar-items{height:inherit}.e-bigger .e-tab .e-tab-header.e-vertical .e-toolbar-items:not(.e-tbar-pos) .e-toolbar-item:last-child,.e-tab.e-bigger .e-tab-header.e-vertical .e-toolbar-items:not(.e-tbar-pos) .e-toolbar-item:last-child{margin:0}.e-bigger .e-tab .e-tab-header.e-vertical .e-toolbar-items.e-vscroll:not(.e-scroll-device),.e-tab.e-bigger .e-tab-header.e-vertical .e-toolbar-items.e-vscroll:not(.e-scroll-device){padding:24px 0}.e-bigger .e-tab .e-tab-header.e-vertical .e-toolbar-item .e-tab-wrap,.e-tab.e-bigger .e-tab-header.e-vertical .e-toolbar-item .e-tab-wrap{padding:0 24px}.e-bigger .e-tab .e-tab-header.e-vertical .e-toolbar-item.e-itop .e-close-icon,.e-bigger .e-tab .e-tab-header.e-vertical .e-toolbar-item.e-ibottom .e-close-icon,.e-tab.e-bigger .e-tab-header.e-vertical .e-toolbar-item.e-itop .e-close-icon,.e-tab.e-bigger .e-tab-header.e-vertical .e-toolbar-item.e-ibottom .e-close-icon{right:-24px}.e-bigger .e-tab .e-tab-header.e-vertical .e-toolbar-item.e-ileft.e-icon,.e-tab.e-bigger .e-tab-header.e-vertical .e-toolbar-item.e-ileft.e-icon{min-height:38px;min-width:auto}.e-bigger .e-tab .e-tab-header.e-vertical .e-scroll-nav,.e-tab.e-bigger .e-tab-header.e-vertical .e-scroll-nav{height:24px;min-height:24px}.e-bigger .e-tab .e-tab-header.e-vertical .e-scroll-nav .e-nav-arrow,.e-tab.e-bigger .e-tab-header.e-vertical .e-scroll-nav .e-nav-arrow{font-size:12px;height:24px;line-height:24px;width:24px}.e-bigger .e-tab .e-tab-header.e-vertical .e-hor-nav,.e-tab.e-bigger .e-tab-header.e-vertical .e-hor-nav{padding:0 24px}.e-bigger .e-tab .e-tab-header.e-vertical .e-hor-nav .e-popup-up-icon:before,.e-bigger .e-tab .e-tab-header.e-vertical .e-hor-nav .e-popup-down-icon:before,.e-tab.e-bigger .e-tab-header.e-vertical .e-hor-nav .e-popup-up-icon:before,.e-tab.e-bigger .e-tab-header.e-vertical .e-hor-nav .e-popup-down-icon:before{line-height:46px}.e-bigger .e-tab .e-tab-header.e-vertical .e-hor-nav .e-popup-up-icon:after,.e-bigger .e-tab .e-tab-header.e-vertical .e-hor-nav .e-popup-down-icon:after,.e-tab.e-bigger .e-tab-header.e-vertical .e-hor-nav .e-popup-up-icon:after,.e-tab.e-bigger .e-tab-header.e-vertical .e-hor-nav .e-popup-down-icon:after{font-size:14px;line-height:46px;margin:0 0 0 10px}.e-bigger .e-tab .e-tab-header.e-vertical.e-toolpop .e-toolbar-items,.e-tab.e-bigger .e-tab-header.e-vertical.e-toolpop .e-toolbar-items{height:auto}.e-bigger .e-tab.e-vertical-icon>.e-tab-header,.e-tab.e-bigger.e-vertical-icon>.e-tab-header{height:72px;min-height:72px}.e-bigger .e-tab.e-vertical-icon>.e-tab-header>.e-toolbar-items,.e-tab.e-bigger.e-vertical-icon>.e-tab-header>.e-toolbar-items{height:72px}.e-bigger .e-tab.e-vertical-icon>.e-tab-header .e-scroll-nav,.e-tab.e-bigger.e-vertical-icon>.e-tab-header .e-scroll-nav{height:72px}.e-bigger .e-tab.e-vertical-icon>.e-tab-header .e-hor-nav,.e-tab.e-bigger.e-vertical-icon>.e-tab-header .e-hor-nav{height:72px}@media screen and (max-width: 480px){.e-bigger .e-tab.e-vertical-icon>.e-tab-header .e-hor-nav .e-popup-up-icon:before,.e-bigger .e-tab.e-vertical-icon>.e-tab-header .e-hor-nav .e-popup-down-icon:before,.e-tab.e-bigger.e-vertical-icon>.e-tab-header .e-hor-nav .e-popup-up-icon:before,.e-tab.e-bigger.e-vertical-icon>.e-tab-header .e-hor-nav .e-popup-down-icon:before{font-size:12px}}.e-bigger .e-tab.e-vertical-icon.e-vertical-tab .e-tab-header.e-vertical .e-toolbar-items,.e-tab.e-bigger.e-vertical-icon.e-vertical-tab .e-tab-header.e-vertical .e-toolbar-items{height:inherit}.e-bigger .e-tab.e-vertical-icon.e-vertical-tab .e-tab-header.e-vertical .e-scroll-nav,.e-tab.e-bigger.e-vertical-icon.e-vertical-tab .e-tab-header.e-vertical .e-scroll-nav{height:24px}.e-bigger .e-tab.e-focused .e-tab-header .e-toolbar-item .e-tab-wrap:focus,.e-tab.e-bigger.e-focused .e-tab-header .e-toolbar-item .e-tab-wrap:focus{height:48px}.e-bigger .e-tab.e-focused .e-tab-header .e-toolbar-item .e-tab-wrap:focus .e-text-wrap,.e-tab.e-bigger.e-focused .e-tab-header .e-toolbar-item .e-tab-wrap:focus .e-text-wrap{height:48px}.e-bigger .e-tab.e-focused .e-tab-header .e-toolbar-item.e-itop .e-tab-wrap:focus,.e-bigger .e-tab.e-focused .e-tab-header .e-toolbar-item.e-ibottom .e-tab-wrap:focus,.e-tab.e-bigger.e-focused .e-tab-header .e-toolbar-item.e-itop .e-tab-wrap:focus,.e-tab.e-bigger.e-focused .e-tab-header .e-toolbar-item.e-ibottom .e-tab-wrap:focus{height:72px}.e-bigger .e-tab.e-focused .e-tab-header .e-toolbar-item.e-itop .e-tab-wrap:focus .e-text-wrap,.e-bigger .e-tab.e-focused .e-tab-header .e-toolbar-item.e-ibottom .e-tab-wrap:focus .e-text-wrap,.e-tab.e-bigger.e-focused .e-tab-header .e-toolbar-item.e-itop .e-tab-wrap:focus .e-text-wrap,.e-tab.e-bigger.e-focused .e-tab-header .e-toolbar-item.e-ibottom .e-tab-wrap:focus .e-text-wrap{height:auto}.e-bigger .e-tab.e-focused .e-tab-header .e-toolbar-item.e-itop.e-active .e-tab-wrap:focus .e-text-wrap,.e-bigger .e-tab.e-focused .e-tab-header .e-toolbar-item.e-ibottom.e-active .e-tab-wrap:focus .e-text-wrap,.e-tab.e-bigger.e-focused .e-tab-header .e-toolbar-item.e-itop.e-active .e-tab-wrap:focus .e-text-wrap,.e-tab.e-bigger.e-focused .e-tab-header .e-toolbar-item.e-ibottom.e-active .e-tab-wrap:focus .e-text-wrap{height:auto}.e-bigger .e-tab.e-focused .e-tab-header .e-toolbar-pop .e-toolbar-item .e-tab-wrap:focus,.e-tab.e-bigger.e-focused .e-tab-header .e-toolbar-pop .e-toolbar-item .e-tab-wrap:focus{height:48px}.e-bigger .e-tab.e-focused .e-tab-header .e-toolbar-pop .e-toolbar-item .e-tab-wrap:focus .e-text-wrap,.e-tab.e-bigger.e-focused .e-tab-header .e-toolbar-pop .e-toolbar-item .e-tab-wrap:focus .e-text-wrap{height:48px}.e-bigger .e-tab.e-focused .e-tab-header .e-toolbar-pop .e-toolbar-item.e-itop .e-tab-wrap:focus,.e-bigger .e-tab.e-focused .e-tab-header .e-toolbar-pop .e-toolbar-item.e-ibottom .e-tab-wrap:focus,.e-tab.e-bigger.e-focused .e-tab-header .e-toolbar-pop .e-toolbar-item.e-itop .e-tab-wrap:focus,.e-tab.e-bigger.e-focused .e-tab-header .e-toolbar-pop .e-toolbar-item.e-ibottom .e-tab-wrap:focus{height:48px}.e-bigger .e-tab.e-focused .e-tab-header.e-horizontal-bottom .e-toolbar-item.e-active .e-tab-wrap:focus .e-text-wrap,.e-tab.e-bigger.e-focused .e-tab-header.e-horizontal-bottom .e-toolbar-item.e-active .e-tab-wrap:focus .e-text-wrap{height:48px;padding:0}.e-bigger .e-tab.e-focused .e-tab-header.e-horizontal-bottom .e-toolbar-item.e-active.e-ileft,.e-tab.e-bigger.e-focused .e-tab-header.e-horizontal-bottom .e-toolbar-item.e-active.e-ileft{height:48px}.e-bigger .e-tab.e-ie .e-tab-header .e-hor-nav.e-ie-align .e-popup-up-icon,.e-bigger .e-tab.e-ie .e-tab-header .e-hor-nav.e-ie-align .e-popup-down-icon,.e-bigger .e-tab.e-ie .e-tab-header .e-scroll-nav.e-ie-align .e-popup-up-icon,.e-bigger .e-tab.e-ie .e-tab-header .e-scroll-nav.e-ie-align .e-popup-down-icon,.e-tab.e-bigger.e-ie .e-tab-header .e-hor-nav.e-ie-align .e-popup-up-icon,.e-tab.e-bigger.e-ie .e-tab-header .e-hor-nav.e-ie-align .e-popup-down-icon,.e-tab.e-bigger.e-ie .e-tab-header .e-scroll-nav.e-ie-align .e-popup-up-icon,.e-tab.e-bigger.e-ie .e-tab-header .e-scroll-nav.e-ie-align .e-popup-down-icon,.e-bigger .e-tab.e-ie .e-tab-header .e-hor-nav.e-ie-align .e-nav-left-arrow,.e-bigger .e-tab.e-ie .e-tab-header .e-hor-nav.e-ie-align .e-nav-right-arrow,.e-bigger .e-tab.e-ie .e-tab-header .e-scroll-nav.e-ie-align .e-nav-left-arrow,.e-bigger .e-tab.e-ie .e-tab-header .e-scroll-nav.e-ie-align .e-nav-right-arrow,.e-tab.e-bigger.e-ie .e-tab-header .e-hor-nav.e-ie-align .e-nav-left-arrow,.e-tab.e-bigger.e-ie .e-tab-header .e-hor-nav.e-ie-align .e-nav-right-arrow,.e-tab.e-bigger.e-ie .e-tab-header .e-scroll-nav.e-ie-align .e-nav-left-arrow,.e-tab.e-bigger.e-ie .e-tab-header .e-scroll-nav.e-ie-align .e-nav-right-arrow,.e-bigger .e-tab.e-edge .e-tab-header .e-hor-nav.e-ie-align .e-popup-up-icon,.e-bigger .e-tab.e-edge .e-tab-header .e-hor-nav.e-ie-align .e-popup-down-icon,.e-bigger .e-tab.e-edge .e-tab-header .e-scroll-nav.e-ie-align .e-popup-up-icon,.e-bigger .e-tab.e-edge .e-tab-header .e-scroll-nav.e-ie-align .e-popup-down-icon,.e-tab.e-bigger.e-edge .e-tab-header .e-hor-nav.e-ie-align .e-popup-up-icon,.e-tab.e-bigger.e-edge .e-tab-header .e-hor-nav.e-ie-align .e-popup-down-icon,.e-tab.e-bigger.e-edge .e-tab-header .e-scroll-nav.e-ie-align .e-popup-up-icon,.e-tab.e-bigger.e-edge .e-tab-header .e-scroll-nav.e-ie-align .e-popup-down-icon{line-height:15px}.e-bigger .e-tab.e-edge .e-tab-header .e-hor-nav.e-ie-align .e-nav-left-arrow,.e-bigger .e-tab.e-edge .e-tab-header .e-hor-nav.e-ie-align .e-nav-right-arrow,.e-bigger .e-tab.e-edge .e-tab-header .e-scroll-nav.e-ie-align .e-nav-left-arrow,.e-bigger .e-tab.e-edge .e-tab-header .e-scroll-nav.e-ie-align .e-nav-right-arrow,.e-tab.e-bigger.e-edge .e-tab-header .e-hor-nav.e-ie-align .e-nav-left-arrow,.e-tab.e-bigger.e-edge .e-tab-header .e-hor-nav.e-ie-align .e-nav-right-arrow,.e-tab.e-bigger.e-edge .e-tab-header .e-scroll-nav.e-ie-align .e-nav-left-arrow,.e-tab.e-bigger.e-edge .e-tab-header .e-scroll-nav.e-ie-align .e-nav-right-arrow{line-height:13px}.e-bigger .e-tab.e-safari .e-tab-header .e-close-icon:before,.e-tab.e-bigger.e-safari .e-tab-header .e-close-icon:before{top:0}.e-bigger .e-tab.e-safari .e-tab-header .e-hor-nav .e-popup-up-icon:before,.e-bigger .e-tab.e-safari .e-tab-header .e-hor-nav .e-popup-down-icon:before,.e-bigger .e-tab.e-safari .e-tab-header .e-scroll-nav .e-popup-up-icon:before,.e-bigger .e-tab.e-safari .e-tab-header .e-scroll-nav .e-popup-down-icon:before,.e-tab.e-bigger.e-safari .e-tab-header .e-hor-nav .e-popup-up-icon:before,.e-tab.e-bigger.e-safari .e-tab-header .e-hor-nav .e-popup-down-icon:before,.e-tab.e-bigger.e-safari .e-tab-header .e-scroll-nav .e-popup-up-icon:before,.e-tab.e-bigger.e-safari .e-tab-header .e-scroll-nav .e-popup-down-icon:before{top:0}.e-bigger .e-tab.e-safari .e-tab-header .e-hor-nav .e-nav-left-arrow:before,.e-bigger .e-tab.e-safari .e-tab-header .e-hor-nav .e-nav-right-arrow:before,.e-bigger .e-tab.e-safari .e-tab-header .e-scroll-nav .e-nav-left-arrow:before,.e-bigger .e-tab.e-safari .e-tab-header .e-scroll-nav .e-nav-right-arrow:before,.e-tab.e-bigger.e-safari .e-tab-header .e-hor-nav .e-nav-left-arrow:before,.e-tab.e-bigger.e-safari .e-tab-header .e-hor-nav .e-nav-right-arrow:before,.e-tab.e-bigger.e-safari .e-tab-header .e-scroll-nav .e-nav-left-arrow:before,.e-tab.e-bigger.e-safari .e-tab-header .e-scroll-nav .e-nav-right-arrow:before{top:0}.e-bigger .e-tab.e-rtl .e-tab-header.e-horizontal-bottom .e-toolbar-items:not(.e-tbar-pos) .e-toolbar-item:not(.e-separator),.e-tab.e-bigger.e-rtl .e-tab-header.e-horizontal-bottom .e-toolbar-items:not(.e-tbar-pos) .e-toolbar-item:not(.e-separator){margin:0}.e-bigger .e-tab.e-rtl .e-tab-header.e-horizontal-bottom .e-toolbar-items:not(.e-tbar-pos) .e-toolbar-item:not(.e-separator).e-active,.e-tab.e-bigger.e-rtl .e-tab-header.e-horizontal-bottom .e-toolbar-items:not(.e-tbar-pos) .e-toolbar-item:not(.e-separator).e-active{margin:0}.e-bigger .e-tab.e-fill .e-tab-header,.e-tab.e-bigger.e-fill .e-tab-header{height:46px;min-height:46px}@media screen and (max-width: 480px){.e-bigger .e-tab.e-fill .e-tab-header,.e-tab.e-bigger.e-fill .e-tab-header{height:46px;min-height:46px}}.e-bigger .e-tab.e-fill .e-tab-header .e-toolbar-items,.e-tab.e-bigger.e-fill .e-tab-header .e-toolbar-items{height:auto;min-height:46px}@media screen and (max-width: 480px){.e-bigger .e-tab.e-fill .e-tab-header .e-toolbar-items,.e-tab.e-bigger.e-fill .e-tab-header .e-toolbar-items{min-height:46px}}.e-bigger .e-tab.e-fill .e-tab-header .e-toolbar-items:not(.e-tbar-pos) .e-toolbar-item:first-child,.e-bigger .e-tab.e-fill .e-tab-header .e-toolbar-items:not(.e-tbar-pos) .e-toolbar-item:last-child,.e-tab.e-bigger.e-fill .e-tab-header .e-toolbar-items:not(.e-tbar-pos) .e-toolbar-item:first-child,.e-tab.e-bigger.e-fill .e-tab-header .e-toolbar-items:not(.e-tbar-pos) .e-toolbar-item:last-child{margin:0;padding:0}.e-bigger .e-tab.e-fill .e-tab-header .e-toolbar-item:not(.e-separator),.e-tab.e-bigger.e-fill .e-tab-header .e-toolbar-item:not(.e-separator){height:46px;margin:0;min-height:46px;padding:0}@media screen and (max-width: 480px){.e-bigger .e-tab.e-fill .e-tab-header .e-toolbar-item:not(.e-separator),.e-tab.e-bigger.e-fill .e-tab-header .e-toolbar-item:not(.e-separator){height:46px;min-height:46px}}.e-bigger .e-tab.e-fill .e-tab-header .e-toolbar-item:not(.e-separator).e-itop,.e-bigger .e-tab.e-fill .e-tab-header .e-toolbar-item:not(.e-separator).e-ibottom,.e-tab.e-bigger.e-fill .e-tab-header .e-toolbar-item:not(.e-separator).e-itop,.e-tab.e-bigger.e-fill .e-tab-header .e-toolbar-item:not(.e-separator).e-ibottom{height:70px;min-height:70px}.e-bigger .e-tab.e-fill .e-tab-header .e-toolbar-item .e-tab-wrap,.e-tab.e-bigger.e-fill .e-tab-header .e-toolbar-item .e-tab-wrap{height:46px;padding:0 24px}@media screen and (max-width: 480px){.e-bigger .e-tab.e-fill .e-tab-header .e-toolbar-item .e-tab-wrap,.e-tab.e-bigger.e-fill .e-tab-header .e-toolbar-item .e-tab-wrap{height:46px;padding:0 24px}}.e-bigger .e-tab.e-fill .e-tab-header .e-toolbar-item .e-text-wrap,.e-tab.e-bigger.e-fill .e-tab-header .e-toolbar-item .e-text-wrap{height:46px}@media screen and (max-width: 480px){.e-bigger .e-tab.e-fill .e-tab-header .e-toolbar-item .e-text-wrap,.e-tab.e-bigger.e-fill .e-tab-header .e-toolbar-item .e-text-wrap{height:46px}}.e-bigger .e-tab.e-fill .e-tab-header .e-toolbar-item.e-active,.e-tab.e-bigger.e-fill .e-tab-header .e-toolbar-item.e-active{padding:0}.e-bigger .e-tab.e-fill .e-tab-header .e-toolbar-item.e-active .e-tab-wrap,.e-tab.e-bigger.e-fill .e-tab-header .e-toolbar-item.e-active .e-tab-wrap{margin-bottom:0}.e-bigger .e-tab.e-fill .e-tab-header .e-toolbar-item.e-active .e-text-wrap,.e-tab.e-bigger.e-fill .e-tab-header .e-toolbar-item.e-active .e-text-wrap{height:46px}@media screen and (max-width: 480px){.e-bigger .e-tab.e-fill .e-tab-header .e-toolbar-item.e-active .e-text-wrap,.e-tab.e-bigger.e-fill .e-tab-header .e-toolbar-item.e-active .e-text-wrap{height:46px}}.e-bigger .e-tab.e-fill .e-tab-header .e-toolbar-item.e-active.e-ileft .e-text-wrap,.e-bigger .e-tab.e-fill .e-tab-header .e-toolbar-item.e-active.e-iright .e-text-wrap,.e-tab.e-bigger.e-fill .e-tab-header .e-toolbar-item.e-active.e-ileft .e-text-wrap,.e-tab.e-bigger.e-fill .e-tab-header .e-toolbar-item.e-active.e-iright .e-text-wrap{height:46px}@media screen and (max-width: 480px){.e-bigger .e-tab.e-fill .e-tab-header .e-toolbar-item.e-active.e-ileft .e-text-wrap,.e-bigger .e-tab.e-fill .e-tab-header .e-toolbar-item.e-active.e-iright .e-text-wrap,.e-tab.e-bigger.e-fill .e-tab-header .e-toolbar-item.e-active.e-ileft .e-text-wrap,.e-tab.e-bigger.e-fill .e-tab-header .e-toolbar-item.e-active.e-iright .e-text-wrap{height:46px}}.e-bigger .e-tab.e-fill .e-tab-header .e-toolbar-item.e-itop .e-tab-wrap,.e-bigger .e-tab.e-fill .e-tab-header .e-toolbar-item.e-ibottom .e-tab-wrap,.e-tab.e-bigger.e-fill .e-tab-header .e-toolbar-item.e-itop .e-tab-wrap,.e-tab.e-bigger.e-fill .e-tab-header .e-toolbar-item.e-ibottom .e-tab-wrap{height:70px}.e-bigger .e-tab.e-fill .e-tab-header .e-toolbar-pop .e-toolbar-item.e-itop:not(.e-separator),.e-bigger .e-tab.e-fill .e-tab-header .e-toolbar-pop .e-toolbar-item.e-ibottom:not(.e-separator),.e-tab.e-bigger.e-fill .e-tab-header .e-toolbar-pop .e-toolbar-item.e-itop:not(.e-separator),.e-tab.e-bigger.e-fill .e-tab-header .e-toolbar-pop .e-toolbar-item.e-ibottom:not(.e-separator){height:auto}.e-bigger .e-tab.e-fill .e-tab-header.e-vertical .e-toolbar-items .e-toolbar-item .e-tab-wrap,.e-tab.e-bigger.e-fill .e-tab-header.e-vertical .e-toolbar-items .e-toolbar-item .e-tab-wrap{padding:0 24px}.e-bigger .e-tab.e-fill .e-tab-header.e-horizontal-bottom .e-toolbar-item.e-active .e-text-wrap,.e-tab.e-bigger.e-fill .e-tab-header.e-horizontal-bottom .e-toolbar-item.e-active .e-text-wrap{height:46px}.e-bigger .e-tab.e-fill .e-tab-header.e-horizontal-bottom .e-toolbar-item.e-itop .e-text-wrap,.e-bigger .e-tab.e-fill .e-tab-header.e-horizontal-bottom .e-toolbar-item.e-ibottom .e-text-wrap,.e-tab.e-bigger.e-fill .e-tab-header.e-horizontal-bottom .e-toolbar-item.e-itop .e-text-wrap,.e-tab.e-bigger.e-fill .e-tab-header.e-horizontal-bottom .e-toolbar-item.e-ibottom .e-text-wrap{height:auto}.e-bigger .e-tab.e-fill .e-tab-header.e-horizontal-bottom .e-toolbar-item.e-itop .e-tab-wrap:focus .e-text-wrap,.e-bigger .e-tab.e-fill .e-tab-header.e-horizontal-bottom .e-toolbar-item.e-ibottom .e-tab-wrap:focus .e-text-wrap,.e-tab.e-bigger.e-fill .e-tab-header.e-horizontal-bottom .e-toolbar-item.e-itop .e-tab-wrap:focus .e-text-wrap,.e-tab.e-bigger.e-fill .e-tab-header.e-horizontal-bottom .e-toolbar-item.e-ibottom .e-tab-wrap:focus .e-text-wrap{height:50px}.e-bigger .e-tab.e-fill.e-focused .e-tab-header .e-toolbar-item .e-tab-wrap:focus,.e-tab.e-bigger.e-fill.e-focused .e-tab-header .e-toolbar-item .e-tab-wrap:focus{height:46px}.e-bigger .e-tab.e-fill.e-focused .e-tab-header .e-toolbar-item .e-tab-wrap:focus .e-text-wrap,.e-tab.e-bigger.e-fill.e-focused .e-tab-header .e-toolbar-item .e-tab-wrap:focus .e-text-wrap{height:46px}.e-bigger .e-tab.e-fill.e-focused .e-tab-header .e-toolbar-item.e-active .e-tab-wrap:focus .e-text-wrap,.e-tab.e-bigger.e-fill.e-focused .e-tab-header .e-toolbar-item.e-active .e-tab-wrap:focus .e-text-wrap{height:46px}.e-bigger .e-tab.e-fill.e-focused .e-tab-header .e-toolbar-item.e-itop .e-tab-wrap:focus,.e-bigger .e-tab.e-fill.e-focused .e-tab-header .e-toolbar-item.e-ibottom .e-tab-wrap:focus,.e-tab.e-bigger.e-fill.e-focused .e-tab-header .e-toolbar-item.e-itop .e-tab-wrap:focus,.e-tab.e-bigger.e-fill.e-focused .e-tab-header .e-toolbar-item.e-ibottom .e-tab-wrap:focus{height:70px}.e-bigger .e-tab.e-fill.e-focused .e-tab-header .e-toolbar-item.e-itop .e-tab-wrap:focus .e-text-wrap,.e-bigger .e-tab.e-fill.e-focused .e-tab-header .e-toolbar-item.e-ibottom .e-tab-wrap:focus .e-text-wrap,.e-tab.e-bigger.e-fill.e-focused .e-tab-header .e-toolbar-item.e-itop .e-tab-wrap:focus .e-text-wrap,.e-tab.e-bigger.e-fill.e-focused .e-tab-header .e-toolbar-item.e-ibottom .e-tab-wrap:focus .e-text-wrap{height:auto}@media screen and (max-width: 480px){.e-bigger .e-tab.e-fill.e-focused .e-tab-header .e-toolbar-item.e-itop .e-tab-wrap:focus .e-text-wrap,.e-bigger .e-tab.e-fill.e-focused .e-tab-header .e-toolbar-item.e-ibottom .e-tab-wrap:focus .e-text-wrap,.e-tab.e-bigger.e-fill.e-focused .e-tab-header .e-toolbar-item.e-itop .e-tab-wrap:focus .e-text-wrap,.e-tab.e-bigger.e-fill.e-focused .e-tab-header .e-toolbar-item.e-ibottom .e-tab-wrap:focus .e-text-wrap{height:auto}}.e-bigger .e-tab.e-fill.e-rtl .e-tab-header .e-toolbar-item:not(.e-separator),.e-tab.e-bigger.e-fill.e-rtl .e-tab-header .e-toolbar-item:not(.e-separator){margin:0}.e-bigger .e-tab.e-fill.e-vertical-icon>.e-tab-header,.e-tab.e-bigger.e-fill.e-vertical-icon>.e-tab-header{height:70px;min-height:70px}.e-bigger .e-tab.e-background .e-tab-header .e-toolbar-items:not(.e-tbar-pos) .e-toolbar-item:first-child,.e-bigger .e-tab.e-background .e-tab-header .e-toolbar-items:not(.e-tbar-pos) .e-toolbar-item:last-child,.e-tab.e-bigger.e-background .e-tab-header .e-toolbar-items:not(.e-tbar-pos) .e-toolbar-item:first-child,.e-tab.e-bigger.e-background .e-tab-header .e-toolbar-items:not(.e-tbar-pos) .e-toolbar-item:last-child{margin:0;padding:0}.e-bigger .e-tab.e-background .e-tab-header .e-toolbar-item:not(.e-separator),.e-tab.e-bigger.e-background .e-tab-header .e-toolbar-item:not(.e-separator){padding:0}.e-bigger .e-tab.e-background .e-tab-header .e-toolbar-item .e-tab-wrap,.e-tab.e-bigger.e-background .e-tab-header .e-toolbar-item .e-tab-wrap{padding:0 24px}@media screen and (max-width: 480px){.e-bigger .e-tab.e-background .e-tab-header .e-toolbar-item .e-tab-wrap,.e-tab.e-bigger.e-background .e-tab-header .e-toolbar-item .e-tab-wrap{padding:0 24px}}.e-bigger .e-tab.e-background .e-tab-header .e-toolbar-item.e-active,.e-tab.e-bigger.e-background .e-tab-header .e-toolbar-item.e-active{padding:0}.e-bigger .e-tab.e-background .e-tab-header .e-toolbar-item.e-active .e-tab-wrap,.e-tab.e-bigger.e-background .e-tab-header .e-toolbar-item.e-active .e-tab-wrap{margin-bottom:0}.e-bigger .e-tab.e-background .e-tab-header.e-vertical .e-toolbar-items .e-toolbar-item .e-tab-wrap,.e-tab.e-bigger.e-background .e-tab-header.e-vertical .e-toolbar-items .e-toolbar-item .e-tab-wrap{padding:0 24px}.e-bigger .e-tab.e-background.e-rtl .e-tab-header .e-toolbar-item:not(.e-separator),.e-tab.e-bigger.e-background.e-rtl .e-tab-header .e-toolbar-item:not(.e-separator){margin:0}.e-bigger .e-tab.e-rtl .e-tab-header .e-toolbar-items:not(.e-tbar-pos) .e-toolbar-item:first-child,.e-bigger .e-tab.e-rtl .e-tab-header .e-toolbar-items:not(.e-tbar-pos) .e-toolbar-item:last-child,.e-tab.e-bigger.e-rtl .e-tab-header .e-toolbar-items:not(.e-tbar-pos) .e-toolbar-item:first-child,.e-tab.e-bigger.e-rtl .e-tab-header .e-toolbar-items:not(.e-tbar-pos) .e-toolbar-item:last-child{margin:0}.e-bigger .e-tab.e-rtl .e-tab-header .e-toolbar-item:not(.e-separator),.e-tab.e-bigger.e-rtl .e-tab-header .e-toolbar-item:not(.e-separator){margin:0}.e-bigger .e-tab.e-rtl .e-tab-header .e-toolbar-item:not(.e-separator) .e-icon-right,.e-tab.e-bigger.e-rtl .e-tab-header .e-toolbar-item:not(.e-separator) .e-icon-right{margin:0}.e-bigger .e-tab.e-rtl .e-tab-header .e-toolbar-item:not(.e-separator) .e-icon-left+.e-tab-text,.e-tab.e-bigger.e-rtl .e-tab-header .e-toolbar-item:not(.e-separator) .e-icon-left+.e-tab-text{margin:0 12px 0 0}@media screen and (max-width: 480px){.e-bigger .e-tab.e-rtl .e-tab-header .e-toolbar-item:not(.e-separator) .e-icon-left+.e-tab-text,.e-tab.e-bigger.e-rtl .e-tab-header .e-toolbar-item:not(.e-separator) .e-icon-left+.e-tab-text{margin:0 14px 0 0}}.e-bigger .e-tab.e-rtl .e-tab-header .e-toolbar-item:not(.e-separator) .e-icons.e-close-icon,.e-tab.e-bigger.e-rtl .e-tab-header .e-toolbar-item:not(.e-separator) .e-icons.e-close-icon{margin:0 12px 0 0}@media screen and (max-width: 480px){.e-bigger .e-tab.e-rtl .e-tab-header .e-toolbar-item:not(.e-separator) .e-icons.e-close-icon,.e-tab.e-bigger.e-rtl .e-tab-header .e-toolbar-item:not(.e-separator) .e-icons.e-close-icon{margin:0 14px 0 0}}.e-bigger .e-tab.e-rtl .e-tab-header .e-toolbar-item:not(.e-separator).e-itop .e-close-icon,.e-bigger .e-tab.e-rtl .e-tab-header .e-toolbar-item:not(.e-separator).e-ibottom .e-close-icon,.e-tab.e-bigger.e-rtl .e-tab-header .e-toolbar-item:not(.e-separator).e-itop .e-close-icon,.e-tab.e-bigger.e-rtl .e-tab-header .e-toolbar-item:not(.e-separator).e-ibottom .e-close-icon{left:24px;right:auto}.e-bigger .e-tab.e-rtl .e-tab-header.e-close-show .e-toolbar-item.e-itop .e-text-wrap,.e-bigger .e-tab.e-rtl .e-tab-header.e-close-show .e-toolbar-item.e-ibottom .e-text-wrap,.e-tab.e-bigger.e-rtl .e-tab-header.e-close-show .e-toolbar-item.e-itop .e-text-wrap,.e-tab.e-bigger.e-rtl .e-tab-header.e-close-show .e-toolbar-item.e-ibottom .e-text-wrap{margin-left:22px;margin-right:0}.e-bigger .e-tab.e-rtl .e-tab-header .e-toolbar-pop .e-toolbar-item,.e-tab.e-bigger.e-rtl .e-tab-header .e-toolbar-pop .e-toolbar-item{margin:0}.e-bigger .e-tab.e-rtl .e-tab-header .e-toolbar-pop .e-toolbar-item .e-tab-text,.e-tab.e-bigger.e-rtl .e-tab-header .e-toolbar-pop .e-toolbar-item .e-tab-text{padding-left:12px;padding-right:0}@media screen and (max-width: 480px){.e-bigger .e-tab.e-rtl .e-tab-header .e-toolbar-pop .e-toolbar-item .e-tab-text,.e-tab.e-bigger.e-rtl .e-tab-header .e-toolbar-pop .e-toolbar-item .e-tab-text{padding-left:0}}.e-bigger .e-tab.e-rtl .e-tab-header .e-toolbar-pop .e-toolbar-item .e-icons.e-close-icon,.e-tab.e-bigger.e-rtl .e-tab-header .e-toolbar-pop .e-toolbar-item .e-icons.e-close-icon{margin:0}.e-bigger .e-tab.e-rtl .e-tab-header .e-toolbar-pop .e-toolbar-item.e-itop .e-close-icon,.e-bigger .e-tab.e-rtl .e-tab-header .e-toolbar-pop .e-toolbar-item.e-ibottom .e-close-icon,.e-tab.e-bigger.e-rtl .e-tab-header .e-toolbar-pop .e-toolbar-item.e-itop .e-close-icon,.e-tab.e-bigger.e-rtl .e-tab-header .e-toolbar-pop .e-toolbar-item.e-ibottom .e-close-icon{left:18px;right:auto}.e-bigger .e-tab.e-rtl .e-tab-header .e-toolbar-pop .e-toolbar-item.e-itop .e-tab-text,.e-bigger .e-tab.e-rtl .e-tab-header .e-toolbar-pop .e-toolbar-item.e-ibottom .e-tab-text,.e-tab.e-bigger.e-rtl .e-tab-header .e-toolbar-pop .e-toolbar-item.e-itop .e-tab-text,.e-tab.e-bigger.e-rtl .e-tab-header .e-toolbar-pop .e-toolbar-item.e-ibottom .e-tab-text{margin:0;padding-left:12px;padding-right:0}@media screen and (max-width: 480px){.e-bigger .e-tab.e-rtl .e-tab-header .e-toolbar-pop .e-toolbar-item.e-itop .e-tab-text,.e-bigger .e-tab.e-rtl .e-tab-header .e-toolbar-pop .e-toolbar-item.e-ibottom .e-tab-text,.e-tab.e-bigger.e-rtl .e-tab-header .e-toolbar-pop .e-toolbar-item.e-itop .e-tab-text,.e-tab.e-bigger.e-rtl .e-tab-header .e-toolbar-pop .e-toolbar-item.e-ibottom .e-tab-text{margin:0;padding-left:0;padding-right:0}}.e-bigger .e-tab.e-rtl .e-tab-header .e-hor-nav,.e-bigger .e-tab.e-rtl .e-tab-header .e-scroll-right-nav,.e-tab.e-bigger.e-rtl .e-tab-header .e-hor-nav,.e-tab.e-bigger.e-rtl .e-tab-header .e-scroll-right-nav,.e-bigger .e-tab.e-rtl .e-tab-header .e-scroll-left-nav,.e-tab.e-bigger.e-rtl .e-tab-header .e-scroll-left-nav{padding:0 12px}.e-bigger .e-tab.e-rtl .e-tab-header.e-vertical .e-toolbar-item:not(.e-separator),.e-tab.e-bigger.e-rtl .e-tab-header.e-vertical .e-toolbar-item:not(.e-separator){margin:0}.e-bigger .e-tab.e-rtl .e-tab-header.e-vertical .e-toolbar-item.e-itop .e-close-icon,.e-bigger .e-tab.e-rtl .e-tab-header.e-vertical .e-toolbar-item.e-ibottom .e-close-icon,.e-tab.e-bigger.e-rtl .e-tab-header.e-vertical .e-toolbar-item.e-itop .e-close-icon,.e-tab.e-bigger.e-rtl .e-tab-header.e-vertical .e-toolbar-item.e-ibottom .e-close-icon{left:-24px}.e-bigger .e-tab.e-rtl .e-tab-header.e-vertical .e-hor-nav,.e-tab.e-bigger.e-rtl .e-tab-header.e-vertical .e-hor-nav{padding:0 24px}.e-bigger .e-tab.e-rtl .e-tab-header.e-vertical .e-popup-up-icon:after,.e-bigger .e-tab.e-rtl .e-tab-header.e-vertical .e-popup-down-icon:after,.e-tab.e-bigger.e-rtl .e-tab-header.e-vertical .e-popup-up-icon:after,.e-tab.e-bigger.e-rtl .e-tab-header.e-vertical .e-popup-down-icon:after{margin:0 10px 0 0}.e-bigger .e-tab-clone-element:not(.e-separator){height:48px;margin:0;min-height:48px;min-width:auto;padding:0}@media screen and (max-width: 480px){.e-bigger .e-tab-clone-element:not(.e-separator){margin:0}}.e-bigger .e-tab-clone-element:not(.e-separator).e-itop,.e-bigger .e-tab-clone-element:not(.e-separator).e-ibottom{height:72px;min-height:72px}.e-bigger .e-tab-clone-element .e-tab-wrap{height:48px;padding:0 24px}@media screen and (max-width: 480px){.e-bigger .e-tab-clone-element .e-tab-wrap{padding:0 12px}}.e-bigger .e-tab-clone-element .e-text-wrap{height:48px}.e-bigger .e-tab-clone-element .e-tab-text{font-size:14px;align-self:auto}.e-bigger .e-tab-clone-element .e-icons.e-close-icon{cursor:pointer;margin:0 0 0 12px}@media screen and (max-width: 480px){.e-bigger .e-tab-clone-element .e-icons.e-close-icon{margin:0 0 0 14px}}.e-bigger .e-tab-clone-element .e-icons.e-close-icon,.e-bigger .e-tab-clone-element .e-close-icon:before{font-size:10px}@media screen and (max-width: 480px){.e-bigger .e-tab-clone-element .e-icons.e-close-icon,.e-bigger .e-tab-clone-element .e-close-icon:before{font-size:12px}}.e-bigger .e-tab-clone-element .e-icons.e-tab-icon{height:24px;min-width:24px;width:24px;line-height:1}.e-bigger .e-tab-clone-element .e-tab-icon,.e-bigger .e-tab-clone-element .e-tab-icon:before{font-size:20px}.e-bigger .e-tab-clone-element.e-icon .e-tab-wrap{padding:0 24px}.e-bigger .e-tab-clone-element .e-icon-right{margin:0 0 0 12px}@media screen and (max-width: 480px){.e-bigger .e-tab-clone-element .e-icon-right{margin:0}}.e-bigger .e-tab-clone-element .e-icon-left+.e-tab-text{margin:0 0 0 12px}@media screen and (max-width: 480px){.e-bigger .e-tab-clone-element .e-icon-left+.e-tab-text{margin:0 0 0 14px}}.e-bigger .e-tab-clone-element.e-itop,.e-bigger .e-tab-clone-element.e-ibottom,.e-bigger .e-tab-clone-element.e-itop .e-tab-wrap,.e-bigger .e-tab-clone-element.e-ibottom .e-tab-wrap{height:72px}.e-bigger .e-tab-clone-element.e-itop .e-tab-wrap:focus .e-text-wrap,.e-bigger .e-tab-clone-element.e-ibottom .e-tab-wrap:focus .e-text-wrap{height:auto}.e-bigger .e-tab-clone-element.e-itop.e-active .e-tab-wrap,.e-bigger .e-tab-clone-element.e-ibottom.e-active .e-tab-wrap{height:72px}.e-bigger .e-tab-clone-element.e-itop.e-active .e-tab-wrap:focus .e-text-wrap,.e-bigger .e-tab-clone-element.e-ibottom.e-active .e-tab-wrap:focus .e-text-wrap{height:auto}.e-bigger .e-tab-clone-element.e-itop .e-close-icon,.e-bigger .e-tab-clone-element.e-ibottom .e-close-icon{right:24px}.e-bigger .e-tab-clone-element.e-itop .e-tab-text{margin:10px 0 0}.e-bigger .e-tab-clone-element.e-ibottom .e-tab-text{margin:0 0 10px}/*! TreeView icons */.e-treeview .e-list-item div.e-icons:not(.e-icons-spinner).e-icon-expandable:before,.e-treeview .e-list-item div.e-icons:not(.e-icons-spinner).e-icon-collapsible:before{content:"\e22f"}.e-treeview .e-sibling:before{content:""}.e-treeview .e-popup .e-icons:before{content:"\e930"}.e-treeview.e-drag-item .e-icons.e-drop-in:before{content:"\e22c"}.e-treeview.e-drag-item .e-icons.e-drop-out:before{content:"\e22b"}.e-treeview.e-drag-item .e-icons.e-drop-next:before{content:"\e22d"}.e-treeview.e-drag-item .e-icons.e-no-drop:before{content:"\e22a"}@keyframes rotation{0%{transform:rotate(0)}to{transform:rotate(359deg)}}.e-treeview{display:block;overflow:hidden;position:relative;white-space:nowrap}.e-treeview.e-virtualization{overflow:auto}.e-treeview.e-virtualization .e-virtual-mask{display:block;margin-bottom:20px}.e-treeview.e-virtualization .e-ul{overflow:unset}.e-treeview>.e-ul{-webkit-overflow-scrolling:touch;overflow:auto}.e-treeview.e-text-wrap .e-list-text{white-space:normal;word-break:break-word}.e-treeview.e-text-wrap.e-ie-wrap .e-list-text{word-break:break-all}.e-treeview.e-text-wrap .e-editing .e-list-text,.e-treeview.e-text-wrap .e-editing .e-list-text .e-input-group{max-width:calc(100% - 2px)}.e-treeview.e-text-wrap .e-checkbox-wrapper+.e-list-text{max-width:calc(100% - 22px)}.e-treeview.e-text-wrap .e-checkbox-wrapper+.e-list-icon+.e-list-text,.e-treeview.e-text-wrap .e-checkbox-wrapper+.e-list-img+.e-list-text{max-width:calc(100% - 59px)}.e-treeview.e-text-wrap .e-checkbox-wrapper+.e-list-icon+.e-list-img+.e-list-text{max-width:calc(100% - 87px)}.e-treeview.e-text-wrap .e-list-icon+.e-list-text,.e-treeview.e-text-wrap .e-list-img+.e-list-text{max-width:calc(100% - 29px)}.e-treeview.e-text-wrap .e-list-icon+.e-list-img+.e-list-text{max-width:calc(100% - 57px)}.e-treeview .e-ul{margin:0;padding:0 0 0 24px}.e-treeview .e-node-collapsed .e-list-item .e-fullrow,.e-treeview .e-display-none{display:none}.e-treeview .e-list-item{list-style:none;padding:2px 0}.e-treeview .e-list-item .e-ul{margin:2px 0 -2px;padding:0 0 0 24px}.e-treeview .e-list-item.e-disable>.e-text-content,.e-treeview .e-list-item.e-disable>.e-fullrow{-ms-touch-action:none;opacity:.5;pointer-events:none;touch-action:none}.e-treeview .e-list-item div.e-icons.interaction{-webkit-transition:-webkit-transform .3s ease-in-out;border-radius:15px;transition:transform .3s ease-in-out}.e-treeview .e-list-item .e-icons.e-icon-collapsible{transform:rotate(90deg)}.e-treeview .e-list-item .e-icons.e-icons-spinner:before{content:none}.e-treeview .e-icons .e-spinner-pane{position:relative}.e-treeview .e-icons .e-treeview-spinner{position:absolute}.e-treeview .e-icons-spinner{position:relative}.e-treeview .e-text-content{-webkit-user-select:none;user-select:none;border:1px solid;cursor:pointer;margin:0;padding:0 0 0 24px}.e-treeview .e-text-content+.e-sibling{margin-top:-1px}.e-treeview .e-fullrow{-webkit-user-select:none;user-select:none;border:1px solid;box-sizing:border-box;cursor:pointer;height:32px;left:0;overflow:hidden;position:absolute;width:100%}.e-treeview .e-checkbox-wrapper{margin:0 0 0 5px;pointer-events:all;position:relative}.e-treeview .e-checkbox-wrapper+.e-list-icon,.e-treeview .e-checkbox-wrapper+.e-list-img{margin:0 0 0 12px}.e-treeview .e-checkbox-wrapper+.e-list-text{padding:0 10px}.e-treeview .e-checkbox-wrapper .e-ripple-container{height:32px;inset:-7px;width:32px}.e-treeview .e-list-text{box-sizing:border-box;display:inline-block;line-height:30px;margin:0;min-height:30px;padding:0 5px;text-decoration:none;vertical-align:middle}.e-treeview .e-list-text .e-input-group{height:30px;margin-bottom:0;min-width:150px;vertical-align:bottom}.e-treeview .e-list-icon,.e-treeview .e-list-img{display:inline-block;height:18px;margin:0 0 0 5px;vertical-align:middle;width:18px}.e-treeview .e-list-icon+.e-list-icon,.e-treeview .e-list-icon+.e-list-img,.e-treeview .e-list-img+.e-list-icon,.e-treeview .e-list-img+.e-list-img{margin:0 0 0 10px}.e-treeview .e-list-icon+.e-list-text,.e-treeview .e-list-img+.e-list-text{padding:0 10px}.e-treeview .e-icon-collapsible,.e-treeview .e-icon-expandable{display:inline-block;height:24px;margin:0 0 0 -24px;vertical-align:middle;width:24px}.e-treeview .e-icon-collapsible:before,.e-treeview .e-icon-expandable:before{display:inline-block;padding:7px}.e-treeview .e-load{animation:rotation .5s infinite linear}.e-treeview .e-sibling{border-radius:10px;height:6px;margin-top:-5px;width:6px}.e-treeview .e-sibling:before{left:6px;top:3px;height:1px;width:144px}.e-treeview .e-sibling,.e-treeview .e-sibling:before{position:absolute;z-index:2}.e-treeview .e-popup{-webkit-user-select:none;user-select:none;font-weight:400;position:absolute;z-index:99999}.e-treeview .e-popup .e-content{border-radius:4px;border-style:solid;border-width:1px;font-size:14px;padding:4px}.e-treeview .e-popup .e-icons{border:1px solid transparent;cursor:pointer;display:inline-block;height:26px;line-height:18px;padding:4px;width:26px}.e-treeview .e-popup .e-downtail:before,.e-treeview .e-popup .e-downtail:after{border:10px solid transparent;content:"";height:0;left:8px;position:absolute;width:0}.e-treeview .e-popup .e-downtail:after{bottom:-18px}.e-treeview.e-fullrow-wrap .e-text-content{pointer-events:none;position:relative}.e-treeview.e-fullrow-wrap .e-icon-collapsible,.e-treeview.e-fullrow-wrap .e-icon-expandable,.e-treeview.e-fullrow-wrap .e-input,.e-treeview.e-fullrow-wrap .e-list-url{pointer-events:auto}.e-treeview .e-navigable .e-text-content{align-items:center;display:flex}.e-treeview .e-navigable .e-list-url{padding:0;width:100%}.e-treeview .e-navigable .e-checkbox-wrapper+.e-list-url .e-anchor-wrap{padding:0 0 0 10px}.e-treeview .e-navigable .e-checkbox-wrapper+.e-list-url .e-anchor-wrap .e-list-icon,.e-treeview .e-navigable .e-checkbox-wrapper+.e-list-url .e-anchor-wrap .e-list-img{margin:0 10px 0 2px}.e-treeview .e-navigable .e-checkbox-wrapper+.e-list-url .e-anchor-wrap .e-list-icon+.e-list-img{margin:0 10px 0 0}.e-treeview .e-navigable .e-anchor-wrap{padding:0 0 0 5px}.e-treeview .e-navigable .e-list-icon,.e-treeview .e-navigable .e-list-img{margin:0 10px 0 0}.e-treeview.e-drag-item{overflow:visible;z-index:10000}.e-treeview.e-drag-item .e-text-content{float:left}.e-treeview.e-drag-item .e-icon-collapsible:before,.e-treeview.e-drag-item .e-icon-expandable:before{font-size:12px;padding:6px}.e-treeview.e-drag-item .e-drop-count{border:1px solid;border-radius:15px;box-sizing:content-box;font-size:13px;line-height:normal;min-width:12px;padding:3px 5px 4px;margin-left:-12px;position:absolute;text-align:center;top:-10px}.e-treeview.e-dragging .e-text-content,.e-treeview.e-dragging .e-fullrow{cursor:default}.e-treeview.e-rtl .e-navigable .e-checkbox-wrapper+.e-list-url .e-anchor-wrap{padding:0 10px 0 0}.e-treeview.e-rtl .e-navigable .e-checkbox-wrapper+.e-list-url .e-anchor-wrap .e-list-icon,.e-treeview.e-rtl .e-navigable .e-checkbox-wrapper+.e-list-url .e-anchor-wrap .e-list-img{margin:0 2px 0 10px}.e-treeview.e-rtl .e-navigable .e-checkbox-wrapper+.e-list-url .e-anchor-wrap .e-list-icon+.e-list-img{margin:0 0 0 10px}.e-treeview.e-rtl .e-navigable .e-anchor-wrap{padding:0 5px 0 0}.e-treeview.e-rtl .e-navigable .e-list-icon,.e-treeview.e-rtl .e-navigable .e-list-img,.e-treeview.e-rtl .e-navigable .e-list-icon+.e-list-img{margin:0 0 0 10px}.e-treeview.e-rtl .e-ul,.e-treeview.e-rtl .e-list-item .e-ul,.e-treeview.e-rtl .e-text-content{padding:0 24px 0 0}.e-treeview.e-rtl .e-checkbox-wrapper{margin:0 5px 0 0}.e-treeview.e-rtl .e-checkbox-wrapper+.e-list-icon,.e-treeview.e-rtl .e-checkbox-wrapper+.e-list-img{margin:0 12px 0 0}.e-treeview.e-rtl .e-list-icon,.e-treeview.e-rtl .e-list-img{margin:0 5px 0 0}.e-treeview.e-rtl .e-list-icon+.e-list-icon,.e-treeview.e-rtl .e-list-icon+.e-list-img,.e-treeview.e-rtl .e-list-img+.e-list-icon,.e-treeview.e-rtl .e-list-img+.e-list-img{margin:0 10px 0 0}.e-treeview.e-rtl .e-icon-collapsible,.e-treeview.e-rtl .e-icon-expandable{margin:0 -24px 0 0}.e-treeview.e-rtl .e-sibling:before{right:6px;top:3px}.e-treeview.e-rtl.e-drag-item .e-icons.e-drop-next{transform:rotate(180deg)}.e-treeview.e-rtl.e-drag-item .e-text-content{float:right}.e-treeview.e-rtl.e-drag-item .e-drop-count{margin-right:-12px}.e-treeview.e-rtl div.e-icons{transform:rotate(180deg)}.e-treeview.e-disabled .e-fullrow,.e-treeview.e-disabled .e-icons,.e-treeview.e-disabled .e-text-content,.e-treeview.e-disabled .e-list-img,.e-treeview.e-disabled .e-list-icon{cursor:auto}.e-treeview.e-disabled .e-list-url{cursor:default;pointer-events:none}.e-treeview.e-interaction.e-fullrow-wrap .e-text-content{pointer-events:auto}.e-treeview{-webkit-tap-highlight-color:transparent}.e-treeview .e-text-content,.e-treeview .e-fullrow{border-color:transparent}.e-treeview .e-list-text{color:#000000de;font-size:13px}.e-treeview .e-list-icon,.e-treeview .e-list-img{font-size:18px}.e-treeview .e-icon-collapsible,.e-treeview .e-icon-expandable{color:#0000008a}.e-treeview .e-icon-collapsible:before,.e-treeview .e-icon-expandable:before{font-size:10px}.e-treeview .e-list-item.e-hover,.e-treeview .e-list-item.e-node-focus{background:transparent}.e-treeview .e-list-item.e-hover>.e-fullrow,.e-treeview .e-list-item.e-node-focus>.e-fullrow{background-color:#f5f5f5;border-color:#f5f5f5}.e-treeview .e-list-item.e-hover>.e-text-content,.e-treeview .e-list-item.e-node-focus>.e-text-content{color:#000000de}.e-treeview .e-list-item.e-hover>.e-text-content .e-list-text,.e-treeview .e-list-item.e-node-focus>.e-text-content .e-list-text{color:#000000de}.e-treeview .e-list-item.e-hover>.e-text-content .e-icon-collapsible,.e-treeview .e-list-item.e-hover>.e-text-content .e-icon-expandable,.e-treeview .e-list-item.e-node-focus>.e-text-content .e-icon-collapsible,.e-treeview .e-list-item.e-node-focus>.e-text-content .e-icon-expandable{color:#0000008a}.e-treeview .e-list-item.e-active{background:transparent}.e-treeview .e-list-item.e-active>.e-fullrow{background-color:#eee;border-color:#eee}.e-treeview .e-list-item.e-active.e-animation-active>.e-fullrow{background-color:transparent;border-color:transparent}.e-treeview .e-list-item.e-active.e-animation-active>.e-text-content{color:#000000de}.e-treeview .e-list-item.e-active.e-animation-active>.e-text-content .e-list-text{color:#000000de}.e-treeview .e-list-item.e-active>.e-text-content{color:#e3165b}.e-treeview .e-list-item.e-active>.e-text-content .e-list-text{color:#e3165b}.e-treeview .e-list-item.e-active>.e-text-content .e-icon-collapsible,.e-treeview .e-list-item.e-active>.e-text-content .e-icon-expandable{color:#0000008a}.e-treeview .e-list-item.e-active.e-hover>.e-fullrow,.e-treeview .e-list-item.e-active.e-node-focus>.e-fullrow{background-color:#e0e0e0;border-color:#e0e0e0}.e-treeview .e-list-item.e-active.e-hover>.e-text-content,.e-treeview .e-list-item.e-active.e-node-focus>.e-text-content{color:#e3165b}.e-treeview .e-list-item.e-active.e-hover>.e-text-content .e-list-text,.e-treeview .e-list-item.e-active.e-node-focus>.e-text-content .e-list-text{color:#e3165b}.e-treeview .e-list-item.e-active.e-hover>.e-text-content .e-icon-collapsible,.e-treeview .e-list-item.e-active.e-hover>.e-text-content .e-icon-expandable,.e-treeview .e-list-item.e-active.e-node-focus>.e-text-content .e-icon-collapsible,.e-treeview .e-list-item.e-active.e-node-focus>.e-text-content .e-icon-expandable{color:#0000008a}.e-treeview .e-list-item.e-editing.e-active>.e-fullrow,.e-treeview .e-list-item.e-editing.e-hover>.e-fullrow,.e-treeview .e-list-item.e-editing.e-node-focus>.e-fullrow{background-color:transparent;border-color:transparent}.e-treeview .e-list-item.e-editing.e-active>.e-text-content,.e-treeview .e-list-item.e-editing.e-hover>.e-text-content,.e-treeview .e-list-item.e-editing.e-node-focus>.e-text-content{color:#000000de}.e-treeview .e-list-item.e-editing.e-active>.e-text-content .e-list-text,.e-treeview .e-list-item.e-editing.e-hover>.e-text-content .e-list-text,.e-treeview .e-list-item.e-editing.e-node-focus>.e-text-content .e-list-text{color:#000000de}.e-treeview .e-list-item.e-editing.e-active>.e-text-content .e-icon-collapsible,.e-treeview .e-list-item.e-editing.e-active>.e-text-content .e-icon-expandable,.e-treeview .e-list-item.e-editing.e-hover>.e-text-content .e-icon-collapsible,.e-treeview .e-list-item.e-editing.e-hover>.e-text-content .e-icon-expandable,.e-treeview .e-list-item.e-editing.e-node-focus>.e-text-content .e-icon-collapsible,.e-treeview .e-list-item.e-editing.e-node-focus>.e-text-content .e-icon-expandable{color:#0000008a}.e-treeview .e-list-item.e-disable>.e-text-content,.e-treeview .e-list-item.e-disable>.e-fullrow{color:#0000008a}.e-treeview .e-list-item.e-disable>.e-text-content>.e-icon-collapsible,.e-treeview .e-list-item.e-disable>.e-text-content>.e-icon-expandable{color:#000000de}.e-treeview .e-sibling{background:#e3165b}.e-treeview .e-sibling:before{background:#0000008a}.e-treeview .e-popup .e-content{background-color:#fff;border-color:#eee}.e-treeview .e-popup.e-select .e-icons{border-color:#eee}.e-treeview .e-popup .e-downtail:before{border-top-color:#eee}.e-treeview .e-popup .e-downtail:after{border-top-color:#fff}.e-treeview:not(.e-fullrow-wrap) .e-list-item.e-hover>.e-text-content,.e-treeview:not(.e-fullrow-wrap) .e-list-item.e-node-focus>.e-text-content{background-color:#f5f5f5;border-color:#f5f5f5}.e-treeview:not(.e-fullrow-wrap) .e-list-item.e-active>.e-text-content{background-color:#eee;border-color:#eee}.e-treeview:not(.e-fullrow-wrap) .e-list-item.e-active.e-hover>.e-text-content,.e-treeview:not(.e-fullrow-wrap) .e-list-item.e-active.e-node-focus>.e-text-content{background-color:#e0e0e0;border-color:#e0e0e0}.e-treeview:not(.e-fullrow-wrap) .e-list-item.e-editing.e-active>.e-text-content,.e-treeview:not(.e-fullrow-wrap) .e-list-item.e-editing.e-hover>.e-text-content,.e-treeview:not(.e-fullrow-wrap) .e-list-item.e-editing.e-node-focus>.e-text-content{background-color:transparent;border-color:transparent}.e-treeview.e-fullrow-wrap .e-text-content{border-color:transparent}.e-treeview.e-drag-item{background-color:#eee;font-family:Roboto,Segoe UI,GeezaPro,"DejaVu Serif","sans-serif",-apple-system,BlinkMacSystemFont}.e-treeview.e-drag-item .e-icon-collapsible:before,.e-treeview.e-drag-item .e-icon-expandable:before{font-size:12px}.e-treeview.e-drag-item .e-list-text,.e-treeview.e-drag-item .e-icons{color:#0000008a}.e-treeview.e-drag-item .e-drop-count{background-color:#e3165b;border-color:#fff;color:#fff}.e-treeview.e-drag-item.e-rtl .e-sibling{background:#e3165b}.e-bigger .e-treeview .e-navigable .e-list-text,.e-treeview.e-bigger .e-navigable .e-list-text{padding:0;width:100%}.e-bigger .e-treeview .e-navigable .e-checkbox-wrapper+.e-list-text,.e-treeview.e-bigger .e-navigable .e-checkbox-wrapper+.e-list-text{padding:0}.e-bigger .e-treeview .e-navigable .e-checkbox-wrapper+.e-list-url .e-anchor-wrap .e-list-icon,.e-bigger .e-treeview .e-navigable .e-checkbox-wrapper+.e-list-url .e-anchor-wrap .e-list-img,.e-treeview.e-bigger .e-navigable .e-checkbox-wrapper+.e-list-url .e-anchor-wrap .e-list-icon,.e-treeview.e-bigger .e-navigable .e-checkbox-wrapper+.e-list-url .e-anchor-wrap .e-list-img{margin:0 10px 0 6px}.e-bigger .e-treeview .e-navigable .e-anchor-wrap,.e-treeview.e-bigger .e-navigable .e-anchor-wrap{padding:0 0 0 10px}.e-bigger .e-treeview .e-navigable .e-list-icon,.e-bigger .e-treeview .e-navigable .e-list-img,.e-bigger .e-treeview .e-navigable .e-list-icon+.e-list-img,.e-treeview.e-bigger .e-navigable .e-list-icon,.e-treeview.e-bigger .e-navigable .e-list-img,.e-treeview.e-bigger .e-navigable .e-list-icon+.e-list-img{margin:0 10px 0 0}.e-bigger .e-treeview .e-fullrow,.e-treeview.e-bigger .e-fullrow{height:40px}.e-bigger .e-treeview.e-text-wrap .e-checkbox-wrapper+.e-list-text,.e-treeview.e-bigger.e-text-wrap .e-checkbox-wrapper+.e-list-text{max-width:calc(100% - 29px)}.e-bigger .e-treeview.e-text-wrap .e-checkbox-wrapper+.e-list-icon+.e-list-text,.e-bigger .e-treeview.e-text-wrap .e-checkbox-wrapper+.e-list-img+.e-list-text,.e-treeview.e-bigger.e-text-wrap .e-checkbox-wrapper+.e-list-icon+.e-list-text,.e-treeview.e-bigger.e-text-wrap .e-checkbox-wrapper+.e-list-img+.e-list-text{max-width:calc(100% - 70px)}.e-bigger .e-treeview.e-text-wrap .e-checkbox-wrapper+.e-list-icon+.e-list-img+.e-list-text,.e-treeview.e-bigger.e-text-wrap .e-checkbox-wrapper+.e-list-icon+.e-list-img+.e-list-text{max-width:calc(100% - 98px)}.e-bigger .e-treeview.e-text-wrap .e-list-icon+.e-list-text,.e-bigger .e-treeview.e-text-wrap .e-list-img+.e-list-text,.e-treeview.e-bigger.e-text-wrap .e-list-icon+.e-list-text,.e-treeview.e-bigger.e-text-wrap .e-list-img+.e-list-text{max-width:calc(100% - 34px)}.e-bigger .e-treeview.e-text-wrap .e-list-icon+.e-list-img+.e-list-text,.e-treeview.e-bigger.e-text-wrap .e-list-icon+.e-list-img+.e-list-text{max-width:calc(100% - 62px)}.e-bigger .e-treeview .e-list-text,.e-treeview.e-bigger .e-list-text{line-height:38px;min-height:38px;padding:0 10px}.e-bigger .e-treeview .e-list-text .e-input-group,.e-treeview.e-bigger .e-list-text .e-input-group{height:38px}.e-bigger .e-treeview .e-checkbox-wrapper,.e-treeview.e-bigger .e-checkbox-wrapper{margin:0 0 0 10px}.e-bigger .e-treeview .e-checkbox-wrapper+.e-list-icon,.e-bigger .e-treeview .e-checkbox-wrapper+.e-list-img,.e-treeview.e-bigger .e-checkbox-wrapper+.e-list-icon,.e-treeview.e-bigger .e-checkbox-wrapper+.e-list-img{margin:0 0 0 16px}.e-bigger .e-treeview .e-list-icon,.e-bigger .e-treeview .e-list-img,.e-treeview.e-bigger .e-list-icon,.e-treeview.e-bigger .e-list-img{margin:0 0 0 10px}.e-bigger .e-treeview .e-list-icon+.e-list-icon,.e-bigger .e-treeview .e-list-icon+.e-list-img,.e-bigger .e-treeview .e-list-img+.e-list-icon,.e-bigger .e-treeview .e-list-img+.e-list-img,.e-treeview.e-bigger .e-list-icon+.e-list-icon,.e-treeview.e-bigger .e-list-icon+.e-list-img,.e-treeview.e-bigger .e-list-img+.e-list-icon,.e-treeview.e-bigger .e-list-img+.e-list-img{margin:0 0 0 10px}.e-bigger .e-treeview .e-icon-collapsible:before,.e-bigger .e-treeview .e-icon-expandable:before,.e-treeview.e-bigger .e-icon-collapsible:before,.e-treeview.e-bigger .e-icon-expandable:before{padding:6px}.e-bigger .e-treeview.e-rtl .e-navigable .e-checkbox-wrapper+.e-list-url .e-anchor-wrap .e-list-icon,.e-bigger .e-treeview.e-rtl .e-navigable .e-checkbox-wrapper+.e-list-url .e-anchor-wrap .e-list-img,.e-treeview.e-bigger.e-rtl .e-navigable .e-checkbox-wrapper+.e-list-url .e-anchor-wrap .e-list-icon,.e-treeview.e-bigger.e-rtl .e-navigable .e-checkbox-wrapper+.e-list-url .e-anchor-wrap .e-list-img{margin:0 6px 0 10px}.e-bigger .e-treeview.e-rtl .e-navigable .e-anchor-wrap,.e-treeview.e-bigger.e-rtl .e-navigable .e-anchor-wrap{padding:0 10px 0 0}.e-bigger .e-treeview.e-rtl .e-navigable .e-list-icon,.e-bigger .e-treeview.e-rtl .e-navigable .e-list-img,.e-bigger .e-treeview.e-rtl .e-navigable .e-list-icon+.e-list-img,.e-treeview.e-bigger.e-rtl .e-navigable .e-list-icon,.e-treeview.e-bigger.e-rtl .e-navigable .e-list-img,.e-treeview.e-bigger.e-rtl .e-navigable .e-list-icon+.e-list-img{margin:0 0 0 10px}.e-bigger .e-treeview.e-rtl .e-checkbox-wrapper,.e-treeview.e-bigger.e-rtl .e-checkbox-wrapper{margin:0 10px 0 0}.e-bigger .e-treeview.e-rtl .e-checkbox-wrapper+.e-list-icon,.e-bigger .e-treeview.e-rtl .e-checkbox-wrapper+.e-list-img,.e-treeview.e-bigger.e-rtl .e-checkbox-wrapper+.e-list-icon,.e-treeview.e-bigger.e-rtl .e-checkbox-wrapper+.e-list-img{margin:0 16px 0 0}.e-bigger .e-treeview.e-rtl .e-list-icon,.e-bigger .e-treeview.e-rtl .e-list-img,.e-treeview.e-bigger.e-rtl .e-list-icon,.e-treeview.e-bigger.e-rtl .e-list-img{margin:0 10px 0 0}.e-bigger .e-treeview.e-rtl .e-list-icon+.e-list-icon,.e-bigger .e-treeview.e-rtl .e-list-icon+.e-list-img,.e-bigger .e-treeview.e-rtl .e-list-img+.e-list-icon,.e-bigger .e-treeview.e-rtl .e-list-img+.e-list-img,.e-treeview.e-bigger.e-rtl .e-list-icon+.e-list-icon,.e-treeview.e-bigger.e-rtl .e-list-icon+.e-list-img,.e-treeview.e-bigger.e-rtl .e-list-img+.e-list-icon,.e-treeview.e-bigger.e-rtl .e-list-img+.e-list-img{margin:0 10px 0 0}.e-bigger .e-treeview .e-list-text,.e-treeview.e-bigger .e-list-text{font-size:14px}.e-bigger .e-treeview .e-icon-collapsible:before,.e-bigger .e-treeview .e-icon-expandable:before,.e-treeview.e-bigger .e-icon-collapsible:before,.e-treeview.e-bigger .e-icon-expandable:before{font-size:12px}/*! Material theme definition's *//*! component's theme wise override definitions and variables */ejs-sidebar{display:none}.e-sidebar-display{display:block}.e-sidebar{-webkit-tap-highlight-color:transparent;background:#fff;height:100%;overflow:auto;position:fixed;top:0;transition:none;vertical-align:middle;visibility:hidden;will-change:transform}.e-sidebar.e-right.e-open,.e-sidebar.e-left.e-open{transform:translate(0);transition:transform .5s ease;visibility:visible}.e-sidebar.e-right.e-close,.e-sidebar.e-left.e-close{box-shadow:none;visibility:hidden}.e-sidebar.e-right.e-close{transform:translate(100%)}.e-sidebar.e-left.e-close{transform:translate(-100%)}.e-sidebar.e-left.e-transition.e-close,.e-sidebar.e-right.e-transition.e-close,.e-sidebar.e-right.e-close{transition:transform .5s ease,visibility .5s}.e-sidebar.e-right{border-left:1px solid rgba(0,0,0,.12);left:auto;right:0;top:0}.e-sidebar.e-left{border-right:1px solid rgba(0,0,0,.12);left:0;right:auto;top:0}.e-sidebar.e-left.e-close.e-dock,.e-sidebar.e-right.e-close.e-dock{transform:translate(0);transition:width .5s ease,visibility .5s;visibility:visible}.e-sidebar.e-left.e-open.e-dock.e-blazor-dock,.e-sidebar.e-right.e-open.e-dock.e-blazor-dock{transition:width .5s ease,visibility .5s}.e-sidebar.e-left.e-open.e-disable-animation,.e-sidebar.e-right.e-open.e-disable-animation,.e-sidebar.e-right.e-close.e-disable-animation,.e-sidebar.e-left.e-close.e-disable-animation{transition:none}.e-sidebar.e-visibility{visibility:hidden}.e-sidebar.e-over{box-shadow:0 0 16px #0000002e}.e-sidebarcontainer.e-sidebar.e-over,.e-sidebarcontainer.e-sidebar.e-auto,.e-sidebarcontainer.e-sidebar.e-push,.e-sidebarcontainer.e-sidebar.e-slide+div{transition:margin .5s ease,transform .5s ease}.e-sidebarcontainer.e-left.e-open.e-auto+div{margin-right:0;transform:translate(0);margin-left:var(--sidebar-width)}.e-sidebarcontainer.e-left.e-close.e-auto+div{margin-right:0;transform:translate(0);margin-left:0}.e-sidebarcontainer.e-right.e-open.e-auto+div{margin-left:0;transform:translate(0);margin-right:var(--sidebar-width)}.e-sidebarcontainer.e-right.e-close.e-auto+div{margin-right:0;transform:translate(0);margin-left:0}.e-sidebarcontainer.e-left.e-open.e-push+div{margin-right:0;transform:translate(0);margin-left:var(--sidebar-width)}.e-sidebarcontainer.e-left.e-close.e-push+div{margin-right:0;transform:translate(0);margin-left:0}.e-sidebarcontainer.e-right.e-open.e-push+div{margin-left:0;transform:translate(0);margin-right:var(--sidebar-width)}.e-sidebarcontainer.e-right.e-close.e-push+div{margin-right:0;transform:translate(0);margin-left:0}.e-sidebarcontainer.e-left.e-open.e-slide+div{margin-left:0;transform:translate(var(--sidebar-width))}.e-sidebarcontainer.e-left.e-close.e-slide+div{margin-left:0;transform:translate(0)}.e-sidebarcontainer.e-right.e-open.e-slide+div{margin-right:0;margin-left:0;transform:translate(calc(-1 * var(--sidebar-width)))}.e-sidebarcontainer.e-right.e-close.e-slide+div{margin-right:0;margin-left:0;transform:translate(0)}.e-sidebar-absolute{position:absolute}.e-sidebar-context{overflow-x:hidden;position:relative}.e-backdrop,.e-sidebar-overlay{background-color:#0009;height:100%;left:0;pointer-events:auto;top:0;z-index:999}.e-backdrop{opacity:.5;width:auto}.e-sidebar-overlay{opacity:.5;position:fixed;width:100%}.e-content-animation{transition:margin .5s ease,transform .5s ease}.e-content-animation.e-overlay{box-sizing:border-box;overflow:auto;-webkit-user-select:none;user-select:none}.e-disable-interaction{pointer-events:none;touch-action:none}.e-sidebar-overflow{overflow-x:hidden}.e-content-placeholder.e-sidebar.e-placeholder-sidebar{left:0;position:fixed;right:auto;top:0;visibility:visible}.e-menu-wrapper ul.e-vertical .e-menu-item .e-caret:before,.e-menu-container ul.e-vertical .e-menu-item .e-caret:before{content:"\e956"}.e-menu-wrapper ul .e-menu-item .e-caret:before,.e-menu-container ul .e-menu-item .e-caret:before{content:"\e94d"}.e-menu-wrapper .e-ul .e-menu-item .e-caret:before,.e-menu-container .e-ul .e-menu-item .e-caret:before{content:"\e956"}.e-menu-wrapper.e-hamburger .e-menu-header .e-menu-icon:before,.e-menu-container.e-hamburger .e-menu-header .e-menu-icon:before{content:"\e99a"}.e-menu-wrapper.e-hamburger.e-close-icon .e-menu-header .e-menu-icon:before,.e-menu-container.e-hamburger.e-close-icon .e-menu-header .e-menu-icon:before{content:"\eb36"}.e-menu-wrapper.e-hamburger .e-vertical .e-menu-item .e-caret:before,.e-menu-wrapper.e-hamburger .e-menu-item .e-caret:before,.e-menu-container.e-hamburger .e-vertical .e-menu-item .e-caret:before,.e-menu-container.e-hamburger .e-menu-item .e-caret:before{content:"\e94d"}.e-menu-wrapper.e-rtl.e-hamburger ul.e-ul .e-caret:before,.e-menu-container.e-rtl.e-hamburger ul.e-ul .e-caret:before{content:"\e94d"}.e-menu-wrapper .e-menu-hscroll.e-hscroll .e-nav-left-arrow:before,.e-menu-wrapper .e-menu-hscroll.e-hscroll .e-nav-right-arrow:before,.e-menu-container .e-menu-hscroll.e-hscroll .e-nav-left-arrow:before,.e-menu-container .e-menu-hscroll.e-hscroll .e-nav-right-arrow:before{content:"\e956"}.e-menu-wrapper .e-menu-vscroll.e-vscroll .e-nav-up-arrow:before,.e-menu-wrapper .e-menu-vscroll.e-vscroll .e-nav-down-arrow:before,.e-menu-container .e-menu-vscroll.e-vscroll .e-nav-up-arrow:before,.e-menu-container .e-menu-vscroll.e-vscroll .e-nav-down-arrow:before{content:"\e94d"}.e-rtl.e-menu-wrapper ul.e-vertical .e-caret:before,.e-rtl.e-menu-wrapper ul.e-ul .e-caret:before,.e-rtl.e-menu-container ul.e-vertical .e-caret:before,.e-rtl.e-menu-container ul.e-ul .e-caret:before,.e-bigger .e-rtl.e-menu-wrapper ul.e-vertical .e-caret:before,.e-bigger .e-rtl.e-menu-wrapper ul.e-ul .e-caret:before,.e-bigger.e-rtl.e-menu-wrapper ul.e-vertical .e-caret:before,.e-bigger.e-rtl.e-menu-wrapper ul.e-ul .e-caret:before,.e-bigger .e-rtl.e-menu-container ul.e-vertical .e-caret:before,.e-bigger .e-rtl.e-menu-container ul.e-ul .e-caret:before,.e-bigger.e-rtl.e-menu-container ul.e-vertical .e-caret:before,.e-bigger.e-rtl.e-menu-container ul.e-ul .e-caret:before{content:"\e937"}.e-bigger .e-rtl.e-menu-wrapper.e-hamburger ul.e-ul .e-caret:before,.e-bigger.e-rtl.e-menu-wrapper.e-hamburger ul.e-ul .e-caret:before,.e-bigger .e-rtl.e-menu-container.e-hamburger ul.e-ul .e-caret:before,.e-bigger.e-rtl.e-menu-container.e-hamburger ul.e-ul .e-caret:before{content:"\e94d"}.e-menu-wrapper,.e-menu-container{border:none;border-radius:0;display:inline-block;line-height:0}.e-menu-wrapper .e-menu-vscroll,.e-menu-container .e-menu-vscroll{height:inherit}.e-menu-wrapper ul,.e-menu-container ul{font-weight:400;list-style-image:none;list-style-position:outside;list-style-type:none;margin:0;overflow:hidden;-webkit-user-select:none;user-select:none;font-size:13px;padding:0;text-align:left;white-space:nowrap}.e-menu-wrapper ul.e-ul,.e-menu-wrapper ul.e-ul *,.e-menu-container ul.e-ul,.e-menu-container ul.e-ul *{box-sizing:border-box}.e-menu-wrapper ul.e-ul:focus,.e-menu-wrapper ul.e-ul *:focus,.e-menu-container ul.e-ul:focus,.e-menu-container ul.e-ul *:focus{outline:none}.e-menu-wrapper ul.e-vertical,.e-menu-container ul.e-vertical{min-width:120px}.e-menu-wrapper ul.e-vertical .e-menu-item,.e-menu-container ul.e-vertical .e-menu-item{display:list-item}.e-menu-wrapper ul.e-vertical .e-separator,.e-menu-container ul.e-vertical .e-separator{border-bottom-style:solid;border-bottom-width:1px;height:auto}.e-menu-wrapper ul.e-menu,.e-menu-container ul.e-menu{display:inline-block}.e-menu-wrapper ul.e-menu:not(.e-vertical),.e-menu-container ul.e-menu:not(.e-vertical){padding:0}.e-menu-wrapper ul.e-menu:not(.e-vertical) .e-separator,.e-menu-container ul.e-menu:not(.e-vertical) .e-separator{border-right-style:solid;border-right-width:1px;padding:0}.e-menu-wrapper ul.e-menu .e-menu-item .e-menu-icon,.e-menu-container ul.e-menu .e-menu-item .e-menu-icon{width:24px}.e-menu-wrapper ul .e-menu-item,.e-menu-container ul .e-menu-item{cursor:pointer;position:relative;display:inline-flex;height:42px;line-height:42px;padding:0 12px;vertical-align:top;white-space:nowrap}.e-menu-wrapper ul .e-menu-item.e-menu-hide,.e-menu-container ul .e-menu-item.e-menu-hide{display:none}.e-menu-wrapper ul .e-menu-item.e-menu-header,.e-menu-container ul .e-menu-item.e-menu-header{border-bottom-style:solid;border-bottom-width:1px}.e-menu-wrapper ul .e-menu-item .e-menu-url,.e-menu-container ul .e-menu-item .e-menu-url{text-decoration:none}.e-menu-wrapper ul .e-menu-item .e-menu-icon,.e-menu-container ul .e-menu-item .e-menu-icon{display:inline-block;vertical-align:middle}.e-menu-wrapper ul .e-menu-item.e-separator,.e-menu-container ul .e-menu-item.e-separator{cursor:auto;line-height:normal;pointer-events:none}.e-menu-wrapper ul .e-menu-item .e-menu-icon,.e-menu-container ul .e-menu-item .e-menu-icon{font-size:14px;height:auto;line-height:42px;margin-right:8px;text-align:center;margin-bottom:4px}.e-menu-wrapper ul .e-menu-item .e-caret,.e-menu-container ul .e-menu-item .e-caret{font-size:10px;height:auto;line-height:42px;position:absolute;right:12px;top:0;width:auto}.e-menu-wrapper ul .e-menu-item.e-menu-caret-icon,.e-menu-container ul .e-menu-item.e-menu-caret-icon{padding-right:30px}.e-menu-wrapper ul .e-menu-item.e-disabled,.e-menu-container ul .e-menu-item.e-disabled{cursor:auto;opacity:.38;pointer-events:none}.e-menu-wrapper .e-ul,.e-menu-container .e-ul{font-size:14px;padding:0;min-width:120px}.e-menu-wrapper .e-ul .e-menu-item,.e-menu-container .e-ul .e-menu-item{height:36px;line-height:36px;padding:0 16px;display:list-item}.e-menu-wrapper .e-ul .e-menu-item .e-menu-url,.e-menu-container .e-ul .e-menu-item .e-menu-url{display:inline-block;min-width:120px}.e-menu-wrapper .e-ul .e-menu-item .e-menu-icon,.e-menu-container .e-ul .e-menu-item .e-menu-icon{font-size:14px;line-height:36px;margin-right:10px;width:1em}.e-menu-wrapper .e-ul .e-menu-item .e-caret,.e-menu-container .e-ul .e-menu-item .e-caret{line-height:36px;margin-left:16px;margin-right:0;position:absolute;right:8px}.e-menu-wrapper .e-ul .e-menu-item.e-menu-caret-icon,.e-menu-container .e-ul .e-menu-item.e-menu-caret-icon{padding-right:36px}.e-menu-wrapper .e-ul .e-menu-item.e-separator,.e-menu-container .e-ul .e-menu-item.e-separator{border-bottom-style:solid;border-bottom-width:1px;height:auto;margin:8px 0}.e-menu-wrapper .e-ul .e-menu-item .e-caret,.e-menu-container .e-ul .e-menu-item .e-caret{font-size:11px}.e-menu-wrapper.e-menu-icon-right .e-menu-header .e-menu-icon,.e-menu-container.e-menu-icon-right .e-menu-header .e-menu-icon{float:right}.e-menu-wrapper.e-menu-icon-right .e-menu-header .e-menu-title,.e-menu-container.e-menu-icon-right .e-menu-header .e-menu-title{padding:0 16px}.e-menu-wrapper .e-menu-header,.e-menu-container .e-menu-header{display:none;font-family:Roboto,Segoe UI,GeezaPro,"DejaVu Serif","sans-serif",-apple-system,BlinkMacSystemFont;font-size:14px;font-weight:400;height:42px;line-height:42px;text-align:left;white-space:nowrap}.e-menu-wrapper .e-menu-header .e-menu-title,.e-menu-wrapper .e-menu-header .e-menu-icon,.e-menu-container .e-menu-header .e-menu-title,.e-menu-container .e-menu-header .e-menu-icon{display:inline-block;line-height:inherit}.e-menu-wrapper .e-menu-header .e-menu-icon,.e-menu-container .e-menu-header .e-menu-icon{cursor:pointer;float:left;outline:none;padding:0 16px}.e-menu-wrapper .e-menu-hscroll.e-hscroll:not(.e-scroll-device),.e-menu-container .e-menu-hscroll.e-hscroll:not(.e-scroll-device){padding:0 30px}.e-menu-wrapper .e-menu-hscroll.e-hscroll:not(.e-scroll-device) .e-scroll-nav,.e-menu-container .e-menu-hscroll.e-hscroll:not(.e-scroll-device) .e-scroll-nav{width:30px}.e-menu-wrapper .e-menu-hscroll.e-hscroll:not(.e-scroll-device) .e-scroll-nav:focus,.e-menu-wrapper .e-menu-hscroll.e-hscroll:not(.e-scroll-device) .e-scroll-nav:hover,.e-menu-container .e-menu-hscroll.e-hscroll:not(.e-scroll-device) .e-scroll-nav:focus,.e-menu-container .e-menu-hscroll.e-hscroll:not(.e-scroll-device) .e-scroll-nav:hover{border:0}.e-menu-wrapper .e-menu-hscroll.e-hscroll:not(.e-scroll-device) .e-scroll-nav.e-scroll-right-nav,.e-menu-container .e-menu-hscroll.e-hscroll:not(.e-scroll-device) .e-scroll-nav.e-scroll-right-nav{border-left:none}.e-menu-wrapper .e-menu-hscroll.e-hscroll:not(.e-scroll-device) .e-scroll-nav.e-scroll-left-nav,.e-menu-container .e-menu-hscroll.e-hscroll:not(.e-scroll-device) .e-scroll-nav.e-scroll-left-nav{border-right:none}.e-menu-wrapper .e-menu-hscroll.e-hscroll:not(.e-scroll-device) .e-hscroll-bar,.e-menu-container .e-menu-hscroll.e-hscroll:not(.e-scroll-device) .e-hscroll-bar{overflow-y:hidden}.e-menu-wrapper .e-scroll-nav .e-nav-arrow,.e-menu-container .e-scroll-nav .e-nav-arrow{font-size:10px}.e-menu-wrapper .e-scroll-nav .e-nav-arrow.e-nav-left-arrow,.e-menu-wrapper .e-scroll-nav .e-nav-arrow.e-nav-up-arrow,.e-menu-container .e-scroll-nav .e-nav-arrow.e-nav-left-arrow,.e-menu-container .e-scroll-nav .e-nav-arrow.e-nav-up-arrow{transform:rotate(180deg)}.e-menu-wrapper.e-rtl .e-scroll-nav .e-nav-arrow.e-nav-left-arrow,.e-menu-container.e-rtl .e-scroll-nav .e-nav-arrow.e-nav-left-arrow{transform:rotate(0)}.e-menu-wrapper.e-rtl .e-scroll-nav .e-nav-arrow.e-nav-right-arrow,.e-menu-container.e-rtl .e-scroll-nav .e-nav-arrow.e-nav-right-arrow{transform:rotate(180deg)}.e-menu-wrapper.e-popup.e-menu-popup,.e-menu-container.e-popup.e-menu-popup{border:none;box-shadow:0 5px 5px -3px #0003,0 8px 10px 1px #00000024,0 3px 14px 2px #0000001f;overflow:hidden;position:absolute}.e-menu-wrapper .e-menu-vscroll.e-vscroll:not(.e-scroll-device),.e-menu-container .e-menu-vscroll.e-vscroll:not(.e-scroll-device){padding:16px 0}.e-menu-wrapper .e-menu-vscroll.e-vscroll.e-scroll-device .e-scroll-nav.e-scroll-down-nav,.e-menu-container .e-menu-vscroll.e-vscroll.e-scroll-device .e-scroll-nav.e-scroll-down-nav{transform:none;width:100%}.e-menu-wrapper .e-menu-vscroll.e-vscroll.e-scroll-device .e-scroll-nav.e-scroll-down-nav .e-nav-down-arrow,.e-menu-container .e-menu-vscroll.e-vscroll.e-scroll-device .e-scroll-nav.e-scroll-down-nav .e-nav-down-arrow{transform:none}.e-menu-wrapper .e-menu-vscroll.e-vscroll .e-vscroll-bar,.e-menu-container .e-menu-vscroll.e-vscroll .e-vscroll-bar{height:100%;width:inherit}.e-menu-wrapper .e-menu-vscroll.e-vscroll .e-vscroll-bar .e-vscroll-content,.e-menu-container .e-menu-vscroll.e-vscroll .e-vscroll-bar .e-vscroll-content{width:inherit}.e-menu-wrapper .e-menu-vscroll.e-vscroll .e-scroll-nav,.e-menu-container .e-menu-vscroll.e-vscroll .e-scroll-nav{height:16px}.e-menu-wrapper.e-scrollable,.e-menu-container.e-scrollable{display:block}.e-menu-wrapper.e-scrollable .e-menu,.e-menu-container.e-scrollable .e-menu{display:block;overflow:auto}.e-menu-wrapper.e-contextmenu-container,.e-menu-container.e-contextmenu-container{height:1px}.e-menu-wrapper.e-contextmenu-container .e-menu-vscroll ul.e-ul,.e-menu-container.e-contextmenu-container .e-menu-vscroll ul.e-ul{width:inherit}.e-menu-wrapper.e-contextmenu-container .e-menu-vscroll,.e-menu-container.e-contextmenu-container .e-menu-vscroll{border:none;box-shadow:0 5px 5px -3px #0003,0 8px 10px 1px #00000024,0 3px 14px 2px #0000001f}.e-menu-container:not(.e-hamburger):not(.e-rtl) .e-menu.e-vertical .e-blankicon{padding-left:44px}.e-rtl.e-menu-wrapper ul .e-menu-item,.e-rtl.e-menu-container ul .e-menu-item{text-align:right}.e-rtl.e-menu-wrapper ul .e-menu-item .e-menu-icon,.e-rtl.e-menu-container ul .e-menu-item .e-menu-icon{margin-right:0}.e-rtl.e-menu-wrapper ul .e-menu-item .e-caret,.e-rtl.e-menu-container ul .e-menu-item .e-caret{margin-left:0;margin-right:16px;right:auto}.e-rtl.e-menu-wrapper ul .e-menu-item .e-menu-icon,.e-rtl.e-menu-container ul .e-menu-item .e-menu-icon{margin-left:8px}.e-rtl.e-menu-wrapper ul .e-menu-item .e-caret,.e-rtl.e-menu-container ul .e-menu-item .e-caret{left:12px}.e-rtl.e-menu-wrapper ul .e-menu-item.e-menu-caret-icon,.e-rtl.e-menu-container ul .e-menu-item.e-menu-caret-icon{padding-left:30px;padding-right:12px}.e-rtl.e-menu-wrapper ul.e-ul .e-menu-item .e-menu-icon,.e-rtl.e-menu-container ul.e-ul .e-menu-item .e-menu-icon{margin-left:10px}.e-rtl.e-menu-wrapper ul.e-ul .e-menu-item .e-caret,.e-rtl.e-menu-container ul.e-ul .e-menu-item .e-caret{left:8px}.e-rtl.e-menu-wrapper ul.e-ul .e-menu-item.e-menu-caret-icon,.e-rtl.e-menu-container ul.e-ul .e-menu-item.e-menu-caret-icon{padding-left:36px;padding-right:16px}.e-rtl.e-menu-wrapper ul.e-ul .e-menu-item.e-blankicon,.e-rtl.e-menu-container ul.e-ul .e-menu-item.e-blankicon{padding-left:16px}.e-rtl.e-menu-wrapper ul.e-ul .e-menu-item.e-blankicon.e-menu-caret-icon,.e-rtl.e-menu-container ul.e-ul .e-menu-item.e-blankicon.e-menu-caret-icon{padding-left:36px}.e-rtl.e-menu-container:not(.e-hamburger) .e-menu.e-vertical .e-blankicon{padding-right:44px}.e-menu-wrapper.e-hamburger,.e-menu-container.e-hamburger{border:0;display:block;position:relative}.e-menu-wrapper.e-hamburger .e-menu-header:not(.e-vertical),.e-menu-container.e-hamburger .e-menu-header:not(.e-vertical){border:none;display:block}.e-menu-wrapper.e-hamburger .e-popup.e-menu-popup,.e-menu-container.e-hamburger .e-popup.e-menu-popup{border:0;border-radius:0;box-shadow:none;display:block;position:relative;width:100%}.e-menu-wrapper.e-hamburger ul.e-menu,.e-menu-container.e-hamburger ul.e-menu{border:none;overflow-y:auto;width:100%}.e-menu-wrapper.e-hamburger ul.e-menu.e-menu-parent.e-hide-menu,.e-menu-container.e-hamburger ul.e-menu.e-menu-parent.e-hide-menu{display:none}.e-menu-wrapper.e-hamburger ul.e-menu .e-menu-item,.e-menu-container.e-hamburger ul.e-menu .e-menu-item{text-indent:12px}.e-menu-wrapper.e-hamburger ul.e-menu .e-menu-item.e-blankicon,.e-menu-container.e-hamburger ul.e-menu .e-menu-item.e-blankicon{text-indent:34px}.e-menu-wrapper.e-hamburger ul.e-menu .e-menu-item .e-menu-icon,.e-menu-container.e-hamburger ul.e-menu .e-menu-item .e-menu-icon{display:inline;text-indent:0}.e-menu-wrapper.e-hamburger ul.e-menu .e-menu-item.e-menu-hide,.e-menu-container.e-hamburger ul.e-menu .e-menu-item.e-menu-hide{display:none}.e-menu-wrapper.e-hamburger ul.e-menu .e-menu-item[aria-expanded=true] .e-caret,.e-menu-container.e-hamburger ul.e-menu .e-menu-item[aria-expanded=true] .e-caret{transition:transform .3s ease-in-out;transform:rotate(-180deg);text-indent:0}.e-menu-wrapper.e-hamburger ul.e-menu .e-menu-item[aria-expanded=false] .e-caret,.e-menu-container.e-hamburger ul.e-menu .e-menu-item[aria-expanded=false] .e-caret{transition:transform .3s ease-in-out;transform:rotate(0);text-indent:0}.e-menu-wrapper.e-hamburger ul.e-menu:not(.e-vertical),.e-menu-container.e-hamburger ul.e-menu:not(.e-vertical){border-top:0;display:block;padding:0;position:absolute}.e-menu-wrapper.e-hamburger ul.e-ul,.e-menu-container.e-hamburger ul.e-ul{font-size:13px;padding:0}.e-menu-wrapper.e-hamburger ul.e-ul .e-menu-item,.e-menu-container.e-hamburger ul.e-ul .e-menu-item{line-height:42px;text-indent:inherit}.e-menu-wrapper.e-hamburger ul.e-ul .e-menu-item.e-blankicon,.e-menu-container.e-hamburger ul.e-ul .e-menu-item.e-blankicon{padding:0;text-indent:inherit}.e-menu-wrapper.e-hamburger ul.e-ul .e-menu-item .e-caret,.e-menu-container.e-hamburger ul.e-ul .e-menu-item .e-caret{font-size:10px;right:12px}.e-menu-wrapper.e-hamburger ul .e-menu-item,.e-menu-container.e-hamburger ul .e-menu-item{display:list-item;height:auto;padding:0}.e-menu-wrapper.e-hamburger ul .e-menu-item.e-menu-caret-icon,.e-menu-wrapper.e-hamburger ul .e-menu-item.e-blankicon,.e-menu-container.e-hamburger ul .e-menu-item.e-menu-caret-icon,.e-menu-container.e-hamburger ul .e-menu-item.e-blankicon{padding:0}.e-menu-wrapper.e-hamburger ul .e-menu-item .e-menu-url,.e-menu-container.e-hamburger ul .e-menu-item .e-menu-url{display:inline-block;min-width:120px;text-indent:0;width:100%}.e-menu-wrapper.e-hamburger ul .e-menu-item.e-separator,.e-menu-container.e-hamburger ul .e-menu-item.e-separator{border-bottom-style:solid;border-bottom-width:1px;height:auto}.e-rtl.e-menu-wrapper.e-hamburger ul .e-menu-item .e-menu-caret-icon,.e-rtl.e-menu-container.e-hamburger ul .e-menu-item .e-menu-caret-icon{padding-left:0;padding-right:0}.e-rtl.e-menu-wrapper.e-hamburger ul .e-menu-item .e-menu-icon,.e-rtl.e-menu-container.e-hamburger ul .e-menu-item .e-menu-icon{margin-left:0;text-indent:inherit}.e-rtl.e-menu-wrapper.e-hamburger ul .e-menu-item .e-caret,.e-rtl.e-menu-container.e-hamburger ul .e-menu-item .e-caret{left:12px;right:auto}.e-menu-container .e-vscroll ul{position:relative}.e-menu-wrapper,.e-menu-container{background:#fafafa}.e-menu-wrapper .e-menu,.e-menu-container .e-menu{background:inherit;color:#000000de}.e-menu-wrapper .e-menu.e-menu:not(.e-vertical) .e-separator,.e-menu-container .e-menu.e-menu:not(.e-vertical) .e-separator{border-right-color:#0000001f}.e-menu-wrapper .e-menu .e-menu-item .e-caret,.e-menu-container .e-menu .e-menu-item .e-caret,.e-menu-wrapper .e-menu .e-menu-item .e-menu-icon,.e-menu-container .e-menu .e-menu-item .e-menu-icon{color:#0000008a}.e-menu-wrapper .e-menu .e-menu-item.e-menu-header,.e-menu-container .e-menu .e-menu-item.e-menu-header{border-bottom-color:#0000001f}.e-menu-wrapper .e-menu .e-menu-item .e-menu-url,.e-menu-container .e-menu .e-menu-item .e-menu-url{color:#000000de}.e-menu-wrapper .e-menu .e-menu-item.e-focused,.e-menu-container .e-menu .e-menu-item.e-focused{color:initial;outline:0 solid rgba(0,0,0,.12);outline-offset:0;background:#eee}.e-menu-wrapper .e-menu .e-menu-item.e-focused .e-caret,.e-menu-container .e-menu .e-menu-item.e-focused .e-caret,.e-menu-wrapper .e-menu .e-menu-item.e-focused .e-menu-icon,.e-menu-container .e-menu .e-menu-item.e-focused .e-menu-icon{color:#0000008a}.e-menu-wrapper .e-menu .e-menu-item.e-selected,.e-menu-wrapper .e-menu .e-menu-item.e-active-item,.e-menu-container .e-menu .e-menu-item.e-selected,.e-menu-container .e-menu .e-menu-item.e-active-item{color:#000000de;outline:0 solid #e0e0e0;outline-offset:0;background:#e0e0e0}.e-menu-wrapper .e-menu .e-menu-item.e-selected .e-caret,.e-menu-wrapper .e-menu .e-menu-item.e-active-item .e-caret,.e-menu-container .e-menu .e-menu-item.e-selected .e-caret,.e-menu-container .e-menu .e-menu-item.e-active-item .e-caret,.e-menu-wrapper .e-menu .e-menu-item.e-selected .e-menu-icon,.e-menu-wrapper .e-menu .e-menu-item.e-active-item .e-menu-icon,.e-menu-container .e-menu .e-menu-item.e-selected .e-menu-icon,.e-menu-container .e-menu .e-menu-item.e-active-item .e-menu-icon{color:#0000008a}.e-menu-wrapper .e-menu .e-menu-item.e-separator,.e-menu-container .e-menu .e-menu-item.e-separator{border-bottom-color:#0000001f}.e-menu-wrapper .e-menu .e-disabled,.e-menu-container .e-menu .e-disabled{color:#00000061;opacity:1}.e-menu-wrapper .e-menu .e-disabled .e-menu-icon,.e-menu-container .e-menu .e-disabled .e-menu-icon,.e-menu-wrapper .e-menu .e-disabled .e-caret,.e-menu-container .e-menu .e-disabled .e-caret,.e-menu-wrapper .e-menu .e-disabled .e-menu-url,.e-menu-container .e-menu .e-disabled .e-menu-url{color:#00000061}.e-menu-wrapper .e-ul,.e-menu-container .e-ul{background:inherit;color:#000000de}.e-menu-wrapper .e-ul .e-menu-item .e-menu-url,.e-menu-container .e-ul .e-menu-item .e-menu-url{color:#000000de}.e-menu-wrapper .e-ul .e-menu-item.e-focused,.e-menu-container .e-ul .e-menu-item.e-focused{background-color:#eee;color:#000000de;outline:0 solid rgba(0,0,0,.12);outline-offset:0}.e-menu-wrapper .e-ul .e-menu-item.e-selected,.e-menu-wrapper .e-ul .e-menu-item.e-active-item,.e-menu-container .e-ul .e-menu-item.e-selected,.e-menu-container .e-ul .e-menu-item.e-active-item{background-color:#eee;color:#000000de;outline:0 solid #eee;outline-offset:0}.e-menu-wrapper .e-ul .e-menu-item.e-separator,.e-menu-container .e-ul .e-menu-item.e-separator{border-bottom-color:#0000001f}.e-menu-wrapper.e-menu-popup,.e-menu-container.e-menu-popup{background:#fff}.e-menu-wrapper.e-menu-popup.e-sfcontextmenu .e-menu-vscroll,.e-menu-container.e-menu-popup.e-sfcontextmenu .e-menu-vscroll{background:inherit}.e-menu-wrapper .e-menu-hscroll.e-hscroll .e-scroll-nav,.e-menu-container .e-menu-hscroll.e-hscroll .e-scroll-nav{background:#fafafa}.e-menu-wrapper .e-menu-hscroll.e-hscroll .e-scroll-nav .e-nav-arrow.e-icons,.e-menu-container .e-menu-hscroll.e-hscroll .e-scroll-nav .e-nav-arrow.e-icons{color:#0000008a}.e-menu-wrapper .e-menu-hscroll.e-hscroll .e-scroll-nav:hover,.e-menu-container .e-menu-hscroll.e-hscroll .e-scroll-nav:hover{background:#eee}.e-menu-wrapper .e-menu-hscroll.e-hscroll .e-scroll-nav:focus,.e-menu-container .e-menu-hscroll.e-hscroll .e-scroll-nav:focus{background:#eee}.e-menu-wrapper .e-menu-hscroll.e-hscroll .e-scroll-nav:active,.e-menu-container .e-menu-hscroll.e-hscroll .e-scroll-nav:active{background:#eee}.e-menu-wrapper.e-menu-popup .e-menu-vscroll.e-vscroll .e-scroll-nav,.e-menu-container.e-menu-popup .e-menu-vscroll.e-vscroll .e-scroll-nav{background:#fff;border-color:#0000001f}.e-menu-wrapper.e-menu-popup .e-menu-vscroll.e-vscroll .e-scroll-nav .e-icons,.e-menu-container.e-menu-popup .e-menu-vscroll.e-vscroll .e-scroll-nav .e-icons{color:#000000de}.e-menu-wrapper.e-menu-popup .e-menu-vscroll.e-vscroll .e-scroll-nav:hover,.e-menu-wrapper.e-menu-popup .e-menu-vscroll.e-vscroll .e-scroll-nav:focus,.e-menu-container.e-menu-popup .e-menu-vscroll.e-vscroll .e-scroll-nav:hover,.e-menu-container.e-menu-popup .e-menu-vscroll.e-vscroll .e-scroll-nav:focus{background:#eee}.e-menu-wrapper.e-menu-popup .e-menu-vscroll.e-vscroll .e-scroll-nav:active,.e-menu-container.e-menu-popup .e-menu-vscroll.e-vscroll .e-scroll-nav:active{background:#eee}.e-menu-wrapper.e-inherit,.e-menu-container.e-inherit{border:0}.e-menu-wrapper.e-inherit .e-menu,.e-menu-wrapper.e-inherit .e-menu .e-menu-item .e-menu-icon,.e-menu-wrapper.e-inherit .e-menu .e-menu-item .e-caret,.e-menu-container.e-inherit .e-menu,.e-menu-container.e-inherit .e-menu .e-menu-item .e-menu-icon,.e-menu-container.e-inherit .e-menu .e-menu-item .e-caret{color:inherit}.e-menu-wrapper.e-inherit .e-menu,.e-menu-container.e-inherit .e-menu{background:inherit}.e-menu-wrapper.e-inherit .e-menu .e-menu-item.e-selected,.e-menu-wrapper.e-inherit .e-menu .e-menu-item.e-active-item,.e-menu-wrapper.e-inherit .e-menu .e-menu-item.e-focused,.e-menu-container.e-inherit .e-menu .e-menu-item.e-selected,.e-menu-container.e-inherit .e-menu .e-menu-item.e-active-item,.e-menu-container.e-inherit .e-menu .e-menu-item.e-focused{background:#0000000e;color:inherit}.e-menu-wrapper.e-hamburger .e-menu-header,.e-menu-container.e-hamburger .e-menu-header,.e-menu-wrapper.e-hamburger .e-menu-header .e-menu-icon,.e-menu-container.e-hamburger .e-menu-header .e-menu-icon,.e-menu-wrapper.e-hamburger ul,.e-menu-container.e-hamburger ul{color:#000000de}.e-bigger .e-menu-wrapper ul,.e-bigger.e-menu-wrapper ul,.e-bigger .e-menu-container ul,.e-bigger.e-menu-container ul{font-size:14px}.e-bigger .e-menu-wrapper ul.e-menu .e-menu-item,.e-bigger.e-menu-wrapper ul.e-menu .e-menu-item,.e-bigger .e-menu-container ul.e-menu .e-menu-item,.e-bigger.e-menu-container ul.e-menu .e-menu-item{line-height:56px;padding:0 16px;height:56px}.e-bigger .e-menu-wrapper ul.e-menu .e-menu-item .e-menu-icon,.e-bigger.e-menu-wrapper ul.e-menu .e-menu-item .e-menu-icon,.e-bigger .e-menu-container ul.e-menu .e-menu-item .e-menu-icon,.e-bigger.e-menu-container ul.e-menu .e-menu-item .e-menu-icon{font-size:16px;line-height:56px;margin-right:10px}.e-bigger .e-menu-wrapper ul.e-menu .e-menu-item .e-caret,.e-bigger.e-menu-wrapper ul.e-menu .e-menu-item .e-caret,.e-bigger .e-menu-container ul.e-menu .e-menu-item .e-caret,.e-bigger.e-menu-container ul.e-menu .e-menu-item .e-caret{font-size:12px;line-height:56px;right:16px}.e-bigger .e-menu-wrapper ul.e-menu .e-menu-item.e-separator,.e-bigger.e-menu-wrapper ul.e-menu .e-menu-item.e-separator,.e-bigger .e-menu-container ul.e-menu .e-menu-item.e-separator,.e-bigger.e-menu-container ul.e-menu .e-menu-item.e-separator{padding:0}.e-bigger .e-menu-wrapper ul.e-menu:not(.e-vertical),.e-bigger.e-menu-wrapper ul.e-menu:not(.e-vertical),.e-bigger .e-menu-container ul.e-menu:not(.e-vertical),.e-bigger.e-menu-container ul.e-menu:not(.e-vertical){padding:0}.e-bigger .e-menu-wrapper ul.e-menu.e-vertical .e-menu-item.e-separator,.e-bigger.e-menu-wrapper ul.e-menu.e-vertical .e-menu-item.e-separator,.e-bigger .e-menu-container ul.e-menu.e-vertical .e-menu-item.e-separator,.e-bigger.e-menu-container ul.e-menu.e-vertical .e-menu-item.e-separator{height:auto;line-height:normal}.e-bigger .e-menu-wrapper ul.e-ul,.e-bigger.e-menu-wrapper ul.e-ul,.e-bigger .e-menu-container ul.e-ul,.e-bigger.e-menu-container ul.e-ul{font-size:15px;padding:8px 0;white-space:nowrap;min-width:112px}.e-bigger .e-menu-wrapper ul.e-ul .e-menu-item,.e-bigger.e-menu-wrapper ul.e-ul .e-menu-item,.e-bigger .e-menu-container ul.e-ul .e-menu-item,.e-bigger.e-menu-container ul.e-ul .e-menu-item{height:48px;line-height:48px;padding:0 16px}.e-bigger .e-menu-wrapper ul.e-ul .e-menu-item .e-menu-icon,.e-bigger.e-menu-wrapper ul.e-ul .e-menu-item .e-menu-icon,.e-bigger .e-menu-container ul.e-ul .e-menu-item .e-menu-icon,.e-bigger.e-menu-container ul.e-ul .e-menu-item .e-menu-icon{font-size:16px;line-height:48px}.e-bigger .e-menu-wrapper ul.e-ul .e-menu-item .e-caret,.e-bigger.e-menu-wrapper ul.e-ul .e-menu-item .e-caret,.e-bigger .e-menu-container ul.e-ul .e-menu-item .e-caret,.e-bigger.e-menu-container ul.e-ul .e-menu-item .e-caret{line-height:48px}.e-bigger .e-menu-wrapper ul.e-ul .e-menu-item.e-separator,.e-bigger.e-menu-wrapper ul.e-ul .e-menu-item.e-separator,.e-bigger .e-menu-container ul.e-ul .e-menu-item.e-separator,.e-bigger.e-menu-container ul.e-ul .e-menu-item.e-separator{height:auto;line-height:normal}.e-bigger .e-menu-wrapper ul.e-ul .e-menu-item .e-caret,.e-bigger.e-menu-wrapper ul.e-ul .e-menu-item .e-caret,.e-bigger .e-menu-container ul.e-ul .e-menu-item .e-caret,.e-bigger.e-menu-container ul.e-ul .e-menu-item .e-caret{font-size:12px;right:8px}.e-bigger .e-menu-wrapper ul.e-ul .e-menu-item.e-menu-caret-icon,.e-bigger.e-menu-wrapper ul.e-ul .e-menu-item.e-menu-caret-icon,.e-bigger .e-menu-container ul.e-ul .e-menu-item.e-menu-caret-icon,.e-bigger.e-menu-container ul.e-ul .e-menu-item.e-menu-caret-icon{padding-right:36px}.e-bigger .e-menu-wrapper ul.e-ul .e-menu-item .e-menu-icon,.e-bigger.e-menu-wrapper ul.e-ul .e-menu-item .e-menu-icon,.e-bigger .e-menu-container ul.e-ul .e-menu-item .e-menu-icon,.e-bigger.e-menu-container ul.e-ul .e-menu-item .e-menu-icon{margin-right:10px}.e-bigger .e-menu-container:not(.e-hamburger):not(.e-rtl) .e-menu.e-vertical .e-blankicon,.e-bigger.e-menu-container:not(.e-hamburger):not(.e-rtl) .e-menu.e-vertical .e-blankicon{padding-left:50px}.e-bigger .e-menu-wrapper .e-menu-hscroll.e-hscroll:not(.e-scroll-device),.e-bigger.e-menu-wrapper .e-menu-hscroll.e-hscroll:not(.e-scroll-device),.e-bigger .e-menu-container .e-menu-hscroll.e-hscroll:not(.e-scroll-device),.e-bigger.e-menu-container .e-menu-hscroll.e-hscroll:not(.e-scroll-device){padding:0 36px}.e-bigger .e-menu-wrapper .e-menu-hscroll.e-hscroll:not(.e-scroll-device) .e-scroll-nav,.e-bigger.e-menu-wrapper .e-menu-hscroll.e-hscroll:not(.e-scroll-device) .e-scroll-nav,.e-bigger .e-menu-container .e-menu-hscroll.e-hscroll:not(.e-scroll-device) .e-scroll-nav,.e-bigger.e-menu-container .e-menu-hscroll.e-hscroll:not(.e-scroll-device) .e-scroll-nav{width:36px}.e-bigger .e-menu-wrapper .e-menu-vscroll.e-vscroll:not(.e-scroll-device),.e-bigger.e-menu-wrapper .e-menu-vscroll.e-vscroll:not(.e-scroll-device),.e-bigger .e-menu-container .e-menu-vscroll.e-vscroll:not(.e-scroll-device),.e-bigger.e-menu-container .e-menu-vscroll.e-vscroll:not(.e-scroll-device){padding:24px 0}.e-bigger .e-menu-wrapper .e-menu-vscroll.e-vscroll .e-scroll-nav,.e-bigger.e-menu-wrapper .e-menu-vscroll.e-vscroll .e-scroll-nav,.e-bigger .e-menu-container .e-menu-vscroll.e-vscroll .e-scroll-nav,.e-bigger.e-menu-container .e-menu-vscroll.e-vscroll .e-scroll-nav{height:24px}.e-bigger .e-menu-wrapper.e-menu-popup,.e-bigger.e-menu-wrapper.e-menu-popup,.e-bigger .e-menu-container.e-menu-popup,.e-bigger.e-menu-container.e-menu-popup{box-shadow:0 5px 5px -3px #0003,0 8px 10px 1px #00000024,0 3px 14px 2px #0000001f}.e-bigger .e-menu-wrapper .e-scroll-nav .e-icons,.e-bigger.e-menu-wrapper .e-scroll-nav .e-icons,.e-bigger .e-menu-container .e-scroll-nav .e-icons,.e-bigger.e-menu-container .e-scroll-nav .e-icons{font-size:12px}.e-bigger .e-rtl.e-menu-wrapper ul .e-menu-item,.e-bigger.e-rtl.e-menu-wrapper ul .e-menu-item,.e-bigger .e-rtl.e-menu-container ul .e-menu-item,.e-bigger.e-rtl.e-menu-container ul .e-menu-item{text-align:right}.e-bigger .e-rtl.e-menu-wrapper ul .e-menu-item .e-menu-icon,.e-bigger.e-rtl.e-menu-wrapper ul .e-menu-item .e-menu-icon,.e-bigger .e-rtl.e-menu-container ul .e-menu-item .e-menu-icon,.e-bigger.e-rtl.e-menu-container ul .e-menu-item .e-menu-icon{margin-left:10px;margin-right:0}.e-bigger .e-rtl.e-menu-wrapper ul .e-menu-item .e-caret,.e-bigger.e-rtl.e-menu-wrapper ul .e-menu-item .e-caret,.e-bigger .e-rtl.e-menu-container ul .e-menu-item .e-caret,.e-bigger.e-rtl.e-menu-container ul .e-menu-item .e-caret{left:16px;margin-left:0;right:auto}.e-bigger .e-rtl.e-menu-wrapper ul .e-menu-item.e-menu-caret-icon,.e-bigger.e-rtl.e-menu-wrapper ul .e-menu-item.e-menu-caret-icon,.e-bigger .e-rtl.e-menu-container ul .e-menu-item.e-menu-caret-icon,.e-bigger.e-rtl.e-menu-container ul .e-menu-item.e-menu-caret-icon{padding-left:36px;padding-right:16px}.e-bigger .e-rtl.e-menu-wrapper ul.e-ul .e-menu-item .e-menu-icon,.e-bigger.e-rtl.e-menu-wrapper ul.e-ul .e-menu-item .e-menu-icon,.e-bigger .e-rtl.e-menu-container ul.e-ul .e-menu-item .e-menu-icon,.e-bigger.e-rtl.e-menu-container ul.e-ul .e-menu-item .e-menu-icon{margin-left:10px}.e-bigger .e-rtl.e-menu-wrapper ul.e-ul .e-menu-item .e-caret,.e-bigger.e-rtl.e-menu-wrapper ul.e-ul .e-menu-item .e-caret,.e-bigger .e-rtl.e-menu-container ul.e-ul .e-menu-item .e-caret,.e-bigger.e-rtl.e-menu-container ul.e-ul .e-menu-item .e-caret{left:8px}.e-bigger .e-rtl.e-menu-wrapper ul.e-ul .e-menu-item.e-menu-caret-icon,.e-bigger.e-rtl.e-menu-wrapper ul.e-ul .e-menu-item.e-menu-caret-icon,.e-bigger .e-rtl.e-menu-container ul.e-ul .e-menu-item.e-menu-caret-icon,.e-bigger.e-rtl.e-menu-container ul.e-ul .e-menu-item.e-menu-caret-icon{padding-left:36px;padding-right:16px}.e-bigger .e-rtl.e-menu-wrapper ul.e-ul .e-menu-item.e-blankicon,.e-bigger.e-rtl.e-menu-wrapper ul.e-ul .e-menu-item.e-blankicon,.e-bigger .e-rtl.e-menu-container ul.e-ul .e-menu-item.e-blankicon,.e-bigger.e-rtl.e-menu-container ul.e-ul .e-menu-item.e-blankicon{padding-left:16px}.e-bigger .e-rtl.e-menu-wrapper ul.e-ul .e-menu-item.e-blankicon.e-menu-caret-icon,.e-bigger.e-rtl.e-menu-wrapper ul.e-ul .e-menu-item.e-blankicon.e-menu-caret-icon,.e-bigger .e-rtl.e-menu-container ul.e-ul .e-menu-item.e-blankicon.e-menu-caret-icon,.e-bigger.e-rtl.e-menu-container ul.e-ul .e-menu-item.e-blankicon.e-menu-caret-icon{padding-left:36px}.e-bigger .e-rtl.e-menu-container:not(.e-hamburger) .e-menu.e-vertical .e-blankicon,.e-bigger.e-rtl.e-menu-container:not(.e-hamburger) .e-menu.e-vertical .e-blankicon{padding-right:50px}.e-bigger .e-menu-wrapper.e-hamburger ul .e-ul,.e-bigger.e-menu-wrapper.e-hamburger ul .e-ul,.e-bigger .e-menu-container.e-hamburger ul .e-ul,.e-bigger.e-menu-container.e-hamburger ul .e-ul{max-width:100%}.e-bigger .e-menu-wrapper.e-hamburger ul .e-ul .e-menu-item,.e-bigger.e-menu-wrapper.e-hamburger ul .e-ul .e-menu-item,.e-bigger .e-menu-container.e-hamburger ul .e-ul .e-menu-item,.e-bigger.e-menu-container.e-hamburger ul .e-ul .e-menu-item{height:auto;line-height:56px;padding:0}.e-bigger .e-menu-wrapper.e-hamburger .e-menu-header,.e-bigger.e-menu-wrapper.e-hamburger .e-menu-header,.e-bigger .e-menu-container.e-hamburger .e-menu-header,.e-bigger.e-menu-container.e-hamburger .e-menu-header{font-size:16px;height:56px;line-height:56px}.e-bigger .e-menu-wrapper.e-hamburger ul.e-menu .e-menu-item,.e-bigger.e-menu-wrapper.e-hamburger ul.e-menu .e-menu-item,.e-bigger .e-menu-container.e-hamburger ul.e-menu .e-menu-item,.e-bigger.e-menu-container.e-hamburger ul.e-menu .e-menu-item{text-indent:16px}.e-bigger .e-menu-wrapper.e-hamburger ul.e-menu .e-menu-item.e-blankicon,.e-bigger.e-menu-wrapper.e-hamburger ul.e-menu .e-menu-item.e-blankicon,.e-bigger .e-menu-container.e-hamburger ul.e-menu .e-menu-item.e-blankicon,.e-bigger.e-menu-container.e-hamburger ul.e-menu .e-menu-item.e-blankicon{text-indent:42px}.e-bigger .e-menu-wrapper.e-hamburger ul.e-menu .e-ul,.e-bigger.e-menu-wrapper.e-hamburger ul.e-menu .e-ul,.e-bigger .e-menu-container.e-hamburger ul.e-menu .e-ul,.e-bigger.e-menu-container.e-hamburger ul.e-menu .e-ul{font-size:14px}.e-bigger .e-menu-wrapper.e-hamburger ul.e-menu .e-ul .e-menu-item,.e-bigger.e-menu-wrapper.e-hamburger ul.e-menu .e-ul .e-menu-item,.e-bigger .e-menu-container.e-hamburger ul.e-menu .e-ul .e-menu-item,.e-bigger.e-menu-container.e-hamburger ul.e-menu .e-ul .e-menu-item{text-indent:inherit}.e-bigger .e-menu-wrapper.e-hamburger ul.e-menu .e-ul .e-menu-item.e-menu-caret-icon,.e-bigger.e-menu-wrapper.e-hamburger ul.e-menu .e-ul .e-menu-item.e-menu-caret-icon,.e-bigger .e-menu-container.e-hamburger ul.e-menu .e-ul .e-menu-item.e-menu-caret-icon,.e-bigger.e-menu-container.e-hamburger ul.e-menu .e-ul .e-menu-item.e-menu-caret-icon{padding-right:0!important}.e-bigger .e-menu-wrapper.e-hamburger ul.e-menu .e-ul .e-menu-item .e-caret,.e-bigger.e-menu-wrapper.e-hamburger ul.e-menu .e-ul .e-menu-item .e-caret,.e-bigger .e-menu-container.e-hamburger ul.e-menu .e-ul .e-menu-item .e-caret,.e-bigger.e-menu-container.e-hamburger ul.e-menu .e-ul .e-menu-item .e-caret{font-size:12px;right:16px}.e-bigger .e-rtl.e-menu-wrapper.e-hamburger ul.e-menu .e-menu-item,.e-bigger.e-rtl.e-menu-wrapper.e-hamburger ul.e-menu .e-menu-item,.e-bigger .e-rtl.e-menu-container.e-hamburger ul.e-menu .e-menu-item,.e-bigger.e-rtl.e-menu-container.e-hamburger ul.e-menu .e-menu-item{padding:0;text-indent:16px}.e-bigger .e-rtl.e-menu-wrapper.e-hamburger ul.e-menu .e-menu-item.e-blankicon,.e-bigger.e-rtl.e-menu-wrapper.e-hamburger ul.e-menu .e-menu-item.e-blankicon,.e-bigger .e-rtl.e-menu-container.e-hamburger ul.e-menu .e-menu-item.e-blankicon,.e-bigger.e-rtl.e-menu-container.e-hamburger ul.e-menu .e-menu-item.e-blankicon{text-indent:42px}.e-bigger .e-rtl.e-menu-wrapper.e-hamburger ul.e-menu .e-menu-item .e-menu-icon,.e-bigger.e-rtl.e-menu-wrapper.e-hamburger ul.e-menu .e-menu-item .e-menu-icon,.e-bigger .e-rtl.e-menu-container.e-hamburger ul.e-menu .e-menu-item .e-menu-icon,.e-bigger.e-rtl.e-menu-container.e-hamburger ul.e-menu .e-menu-item .e-menu-icon{margin-left:0;text-indent:inherit}.e-bigger .e-rtl.e-menu-wrapper.e-hamburger ul.e-menu .e-menu-item.e-menu-caret-icon,.e-bigger.e-rtl.e-menu-wrapper.e-hamburger ul.e-menu .e-menu-item.e-menu-caret-icon,.e-bigger .e-rtl.e-menu-container.e-hamburger ul.e-menu .e-menu-item.e-menu-caret-icon,.e-bigger.e-rtl.e-menu-container.e-hamburger ul.e-menu .e-menu-item.e-menu-caret-icon{padding-left:0;padding-right:0}.e-bigger .e-rtl.e-menu-wrapper.e-hamburger ul.e-menu .e-menu-item .e-caret,.e-bigger.e-rtl.e-menu-wrapper.e-hamburger ul.e-menu .e-menu-item .e-caret,.e-bigger .e-rtl.e-menu-container.e-hamburger ul.e-menu .e-menu-item .e-caret,.e-bigger.e-rtl.e-menu-container.e-hamburger ul.e-menu .e-menu-item .e-caret{left:12px;right:auto}.e-bigger .e-rtl.e-menu-wrapper.e-hamburger ul.e-menu .e-ul .e-menu-item,.e-bigger.e-rtl.e-menu-wrapper.e-hamburger ul.e-menu .e-ul .e-menu-item,.e-bigger .e-rtl.e-menu-container.e-hamburger ul.e-menu .e-ul .e-menu-item,.e-bigger.e-rtl.e-menu-container.e-hamburger ul.e-menu .e-ul .e-menu-item{text-indent:inherit}.e-bigger .e-menu-wrapper:not(.e-hamburger) ul.e-ul .e-menu-item:not(.e-separator),.e-bigger .e-menu-container:not(.e-hamburger) ul.e-ul .e-menu-item:not(.e-separator){height:48px}.e-bigger .e-menu-wrapper:not(.e-hamburger) ul .e-menu-item.e-menu-caret-icon,.e-bigger .e-menu-container:not(.e-hamburger) ul .e-menu-item.e-menu-caret-icon{padding-right:36px}.e-bigger .e-menu-wrapper.e-hamburger ul.e-menu .e-menu-item,.e-bigger .e-menu-container.e-hamburger ul.e-menu .e-menu-item{padding:0!important;height:auto!important}.e-breadcrumb .e-breadcrumb-collapsed:before,.e-breadcrumb .e-breadcrumb-menu:before{content:"\eb04"}.e-breadcrumb .e-home{margin-top:-1px}.e-breadcrumb .e-home:before{content:"\e92b"}.e-bigger .e-breadcrumb .e-home,.e-bigger.e-breadcrumb .e-home{margin-top:0}.e-breadcrumb{display:block}.e-breadcrumb.e-breadcrumb-wrap-mode{display:flex}.e-breadcrumb .e-breadcrumb-first-ol{align-items:flex-start;flex-shrink:0;padding-right:0}.e-breadcrumb .e-breadcrumb-wrapped-ol{flex-wrap:wrap;overflow:hidden;padding-left:0}.e-breadcrumb.e-breadcrumb-scroll-mode{line-height:26px;overflow:auto}.e-breadcrumb ol{align-items:center;display:inline-flex;line-height:normal;margin:0;padding:0}.e-breadcrumb li{list-style-type:none;white-space:nowrap}.e-breadcrumb .e-breadcrumb-item{align-items:center;display:flex;flex-shrink:0}.e-breadcrumb .e-breadcrumb-item .e-breadcrumb-text{padding:4px 8px}.e-breadcrumb .e-breadcrumb-item .e-breadcrumb-text{align-items:center;display:flex;font-size:14px}.e-breadcrumb .e-breadcrumb-item .e-breadcrumb-text .e-anchor-wrap{align-items:inherit;display:inherit}.e-breadcrumb .e-breadcrumb-item a.e-breadcrumb-text{cursor:pointer;text-decoration:none}.e-breadcrumb .e-breadcrumb-item a.e-breadcrumb-text:hover{text-decoration:underline}.e-breadcrumb .e-breadcrumb-item a.e-breadcrumb-text:focus{text-decoration:underline}.e-breadcrumb .e-breadcrumb-item a.e-breadcrumb-text:active{text-decoration:underline}.e-breadcrumb .e-breadcrumb-item span.e-breadcrumb-text{cursor:default}.e-breadcrumb .e-breadcrumb-item .e-breadcrumb-icon{font-size:14px;padding-right:8px}.e-breadcrumb .e-breadcrumb-item .e-breadcrumb-icon:hover{text-decoration:none}.e-breadcrumb .e-breadcrumb-item .e-breadcrumb-icon:before{display:inline-block;text-decoration:none}.e-breadcrumb .e-breadcrumb-item.e-icon-item .e-breadcrumb-icon{padding:2px 0}.e-breadcrumb .e-breadcrumb-item.e-disabled{opacity:1;pointer-events:none}.e-breadcrumb .e-breadcrumb-separator{display:flex;font-size:14px;padding:4px 3px}.e-breadcrumb .e-breadcrumb-separator+.e-breadcrumb-separator{margin-left:-4px;padding-left:0}.e-breadcrumb.e-rtl .e-breadcrumb-separator+.e-breadcrumb-separator{margin-left:0;margin-right:-4px;padding-left:3px;padding-right:0}.e-breadcrumb .e-breadcrumb-collapsed,.e-breadcrumb .e-breadcrumb-menu{cursor:pointer;font-size:16px;padding:4px;vertical-align:bottom}.e-breadcrumb .e-breadcrumb-menu{display:inline-block}.e-breadcrumb .e-breadcrumb-item-wrapper{display:flex}.e-breadcrumb.e-icon-right .e-breadcrumb-icon,.e-breadcrumb .e-icon-right .e-breadcrumb-icon,.e-breadcrumb.e-rtl .e-breadcrumb-icon{padding-left:8px;padding-right:0}.e-breadcrumb.e-rtl.e-icon-right .e-breadcrumb-icon,.e-breadcrumb.e-rtl .e-icon-right .e-breadcrumb-icon{padding-left:0;padding-right:8px}.e-breadcrumb.e-disabled{opacity:1}.e-breadcrumb.e-disabled .e-breadcrumb-item,.e-breadcrumb.e-disabled .e-breadcrumb-separator,.e-breadcrumb.e-disabled .e-breadcrumb-collapsed,.e-breadcrumb.e-disabled .e-breadcrumb-menu{pointer-events:none}.e-breadcrumb-popup{border:none;border-radius:0;box-shadow:0 5px 5px -3px #0003,0 8px 10px 1px #00000024,0 3px 14px 2px #0000001f;position:absolute}.e-breadcrumb-popup ul{margin:0;padding:0}.e-breadcrumb-popup .e-breadcrumb-item{list-style-type:none;white-space:nowrap}.e-breadcrumb-popup .e-breadcrumb-item .e-breadcrumb-text{align-items:center;display:flex;font-size:14px;height:36px;line-height:36px;padding:0 16px;width:100%}.e-breadcrumb-popup .e-breadcrumb-item .e-breadcrumb-text .e-anchor-wrap{align-items:inherit;display:inherit;width:inherit}.e-breadcrumb-popup .e-breadcrumb-item .e-breadcrumb-icon{font-size:14px;padding-right:8px}.e-breadcrumb-popup .e-breadcrumb-item.e-icon-item .e-breadcrumb-icon{padding:0}.e-breadcrumb-popup .e-breadcrumb-item a.e-breadcrumb-text{text-decoration:none}.e-breadcrumb-popup.e-icon-right .e-breadcrumb-icon,.e-breadcrumb-popup .e-icon-right .e-breadcrumb-icon,.e-breadcrumb-popup.e-rtl .e-breadcrumb-icon{padding-left:8px;padding-right:0}.e-breadcrumb-popup.e-icon-right .e-breadcrumb-icon,.e-breadcrumb-popup .e-icon-right .e-breadcrumb-icon{display:flex;flex-grow:1;justify-content:flex-end}.e-breadcrumb-popup.e-rtl.e-icon-right .e-breadcrumb-icon,.e-breadcrumb-popup.e-rtl .e-icon-right .e-breadcrumb-icon{padding-left:0;padding-right:8px}.e-breadcrumb .e-breadcrumb-item .e-breadcrumb-text{color:#000000a6}.e-breadcrumb .e-breadcrumb-item .e-breadcrumb-text:hover,.e-breadcrumb .e-breadcrumb-item .e-breadcrumb-text:focus{color:#000000de}.e-breadcrumb .e-breadcrumb-item .e-breadcrumb-text:active{color:#000000de}.e-breadcrumb .e-breadcrumb-item.e-icon-item:hover{background:#f5f5f5;color:#000000de}.e-breadcrumb .e-breadcrumb-item.e-icon-item:active{background:#eee;color:#000000de}.e-breadcrumb .e-breadcrumb-item.e-icon-item .e-breadcrumb-text:focus{background:#f5f5f5;color:#000000de}.e-breadcrumb .e-breadcrumb-item[data-active-item] .e-breadcrumb-text{color:#000000de;font-weight:500}.e-breadcrumb .e-breadcrumb-item .e-breadcrumb-icon,.e-breadcrumb .e-breadcrumb-separator,.e-breadcrumb .e-breadcrumb-collapsed,.e-breadcrumb .e-breadcrumb-menu{color:#0000008a}.e-breadcrumb .e-breadcrumb-collapsed:hover,.e-breadcrumb .e-breadcrumb-menu:hover{background:#f5f5f5;color:#000000de}.e-breadcrumb .e-breadcrumb-collapsed:active,.e-breadcrumb .e-breadcrumb-menu:active{background:#eee;color:#000000de}.e-breadcrumb .e-breadcrumb-collapsed:focus,.e-breadcrumb .e-breadcrumb-menu:focus{background:#f5f5f5;color:#000000de}.e-breadcrumb.e-disabled .e-breadcrumb-item .e-breadcrumb-text,.e-breadcrumb .e-disabled.e-breadcrumb-item .e-breadcrumb-text,.e-breadcrumb.e-disabled .e-breadcrumb-separator,.e-breadcrumb.e-disabled .e-breadcrumb-item .e-breadcrumb-text .e-breadcrumb-icon,.e-breadcrumb .e-disabled.e-breadcrumb-item .e-breadcrumb-text .e-breadcrumb-icon,.e-breadcrumb.e-disabled .e-breadcrumb-separator .e-breadcrumb-icon{color:#00000042}.e-breadcrumb-popup{background:#fff}.e-breadcrumb-popup .e-breadcrumb-text{color:#616161}.e-breadcrumb-popup .e-breadcrumb-text:hover{background:#eee;color:#000000de}.e-breadcrumb-popup .e-breadcrumb-item .e-breadcrumb-text:focus{background:#eee;color:#000000de}.e-bigger.e-breadcrumb .e-breadcrumb-item .e-breadcrumb-text,.e-bigger .e-breadcrumb .e-breadcrumb-item .e-breadcrumb-text{padding:4px 12px}.e-bigger.e-breadcrumb .e-breadcrumb-item .e-breadcrumb-text,.e-bigger .e-breadcrumb .e-breadcrumb-item .e-breadcrumb-text{font-size:16px}.e-bigger.e-breadcrumb .e-breadcrumb-item .e-breadcrumb-text .e-breadcrumb-icon,.e-bigger .e-breadcrumb .e-breadcrumb-item .e-breadcrumb-text .e-breadcrumb-icon{font-size:16px;padding-right:8px}.e-bigger.e-breadcrumb .e-breadcrumb-item.e-icon-item .e-breadcrumb-text .e-breadcrumb-icon,.e-bigger .e-breadcrumb .e-breadcrumb-item.e-icon-item .e-breadcrumb-text .e-breadcrumb-icon{padding:2px 0}.e-bigger.e-breadcrumb .e-breadcrumb-separator,.e-bigger .e-breadcrumb .e-breadcrumb-separator{font-size:16px;padding:4px 5px}.e-bigger.e-breadcrumb .e-breadcrumb-separator+.e-breadcrumb-separator,.e-bigger .e-breadcrumb .e-breadcrumb-separator+.e-breadcrumb-separator{padding-left:0}.e-bigger.e-breadcrumb.e-rtl .e-breadcrumb-separator+.e-breadcrumb-separator,.e-bigger .e-breadcrumb.e-rtl .e-breadcrumb-separator+.e-breadcrumb-separator{padding-left:5px}.e-bigger.e-breadcrumb .e-breadcrumb-collapsed,.e-bigger.e-breadcrumb .e-breadcrumb-menu,.e-bigger .e-breadcrumb .e-breadcrumb-collapsed,.e-bigger .e-breadcrumb .e-breadcrumb-menu{font-size:18px;padding:5px}.e-bigger.e-breadcrumb.e-icon-right .e-breadcrumb-text .e-breadcrumb-icon,.e-bigger.e-breadcrumb .e-icon-right .e-breadcrumb-text .e-breadcrumb-icon,.e-bigger.e-breadcrumb.e-rtl .e-breadcrumb-text .e-breadcrumb-icon,.e-bigger .e-breadcrumb.e-icon-right .e-breadcrumb-text .e-breadcrumb-icon,.e-bigger .e-breadcrumb .e-icon-right .e-breadcrumb-text .e-breadcrumb-icon,.e-bigger .e-breadcrumb.e-rtl .e-breadcrumb-text .e-breadcrumb-icon{padding-left:8px;padding-right:0}.e-bigger.e-breadcrumb.e-rtl .e-icon-right .e-breadcrumb-text .e-breadcrumb-icon,.e-bigger .e-breadcrumb.e-rtl .e-icon-right .e-breadcrumb-text .e-breadcrumb-icon{padding-left:0;padding-right:8px}.e-bigger.e-breadcrumb-popup .e-breadcrumb-text,.e-bigger .e-breadcrumb-popup .e-breadcrumb-text{font-size:16px;height:48px;line-height:48px}.e-bigger.e-breadcrumb-popup .e-breadcrumb-text .e-breadcrumb-icon,.e-bigger .e-breadcrumb-popup .e-breadcrumb-text .e-breadcrumb-icon{font-size:16px;padding-right:8px}.e-bigger.e-breadcrumb-popup .e-icon-item .e-breadcrumb-text .e-breadcrumb-icon,.e-bigger .e-breadcrumb-popup .e-icon-item .e-breadcrumb-text .e-breadcrumb-icon{padding:0}.e-bigger.e-breadcrumb-popup.e-icon-right .e-breadcrumb-icon,.e-bigger.e-breadcrumb-popup .e-icon-right .e-breadcrumb-icon,.e-bigger.e-breadcrumb-popup.e-rtl .e-breadcrumb-icon,.e-bigger .e-breadcrumb-popup.e-icon-right .e-breadcrumb-icon,.e-bigger .e-breadcrumb-popup .e-icon-right .e-breadcrumb-icon,.e-bigger .e-breadcrumb-popup.e-rtl .e-breadcrumb-icon{padding-left:8px;padding-right:0}.e-bigger.e-breadcrumb-popup.e-rtl.e-icon-right .e-breadcrumb-icon,.e-bigger.e-breadcrumb-popup.e-rtl .e-icon-right .e-breadcrumb-icon,.e-bigger .e-breadcrumb-popup.e-rtl.e-icon-right .e-breadcrumb-icon,.e-bigger .e-breadcrumb-popup.e-rtl .e-icon-right .e-breadcrumb-icon{padding-left:0;padding-right:8px}.e-appbar{display:flex;width:100%;height:48px;flex-shrink:0;flex-direction:row;position:relative;align-items:center;padding:8px;overflow:hidden;font-size:14px}.e-appbar>div:first-child{display:flex;align-items:center;width:100%;height:100%}.e-appbar.e-sticky{position:sticky;top:0;z-index:1000}.e-appbar.e-prominent{height:94px;align-items:flex-start}.e-appbar.e-prominent>div:first-child{align-items:flex-start}.e-appbar.e-dense{height:40px}.e-appbar.e-horizontal-bottom{position:absolute;bottom:0;right:0;left:0}.e-appbar.e-horizontal-bottom.e-sticky{position:fixed;top:auto;max-width:inherit;left:auto;right:auto}.e-appbar .e-appbar-separator{height:24px}.e-appbar .e-appbar-spacer{flex-grow:1}.e-appbar .e-btn,.e-appbar .e-css.e-btn{border-image:unset}.e-inherit.e-menu-wrapper.e-scrollable .e-menu,.e-inherit.e-menu-container.e-scrollable .e-menu{overflow:hidden}.e-appbar{box-shadow:0 2px 4px #0000001a,0 2px 6px #00000029}.e-appbar.e-light{background:#fff;color:#000;border:none;border-color:#fff}.e-appbar.e-light .e-appbar-separator{border-left:1px solid #000}.e-appbar.e-light .e-btn.e-inherit:hover,.e-appbar.e-light .e-btn.e-inherit:focus,.e-appbar.e-light .e-btn.e-inherit:active,.e-appbar.e-light .e-btn.e-inherit.e-active,.e-appbar.e-light .e-css.e-btn.e-inherit:hover,.e-appbar.e-light .e-css.e-btn.e-inherit:focus,.e-appbar.e-light .e-css.e-btn.e-inherit:active,.e-appbar.e-light .e-css.e-btn.e-inherit.e-active,.e-appbar.e-light .e-dropdown-btn.e-inherit:hover,.e-appbar.e-light .e-dropdown-btn.e-inherit:focus,.e-appbar.e-light .e-dropdown-btn.e-inherit:active,.e-appbar.e-light .e-dropdown-btn.e-inherit.e-active,.e-appbar.e-light .e-dropdown-btn.e-btn.e-inherit:hover,.e-appbar.e-light .e-dropdown-btn.e-btn.e-inherit:focus,.e-appbar.e-light .e-dropdown-btn.e-btn.e-inherit:active,.e-appbar.e-light .e-dropdown-btn.e-btn.e-inherit.e-active{background:#0000000e}.e-appbar.e-light .e-menu-wrapper.e-inherit,.e-appbar.e-light .e-menu-container.e-inherit{background:#fff;color:#000;box-shadow:none;border-color:#fff}.e-appbar.e-light .e-menu-wrapper.e-inherit .e-menu .e-menu-item.e-selected,.e-appbar.e-light .e-menu-wrapper.e-inherit .e-menu .e-menu-item.e-focused,.e-appbar.e-light .e-menu-container.e-inherit .e-menu .e-menu-item.e-selected,.e-appbar.e-light .e-menu-container.e-inherit .e-menu .e-menu-item.e-focused{background:#0000000e}.e-appbar.e-dark{background:#212121;color:#fff;border-color:#212121}.e-appbar.e-dark .e-appbar-separator{border-left:1px solid #fff}.e-appbar.e-dark .e-btn.e-inherit:hover,.e-appbar.e-dark .e-btn.e-inherit:focus,.e-appbar.e-dark .e-btn.e-inherit:active,.e-appbar.e-dark .e-btn.e-inherit.e-active,.e-appbar.e-dark .e-css.e-btn.e-inherit:hover,.e-appbar.e-dark .e-css.e-btn.e-inherit:focus,.e-appbar.e-dark .e-css.e-btn.e-inherit:active,.e-appbar.e-dark .e-css.e-btn.e-inherit.e-active,.e-appbar.e-dark .e-dropdown-btn.e-inherit:hover,.e-appbar.e-dark .e-dropdown-btn.e-inherit:focus,.e-appbar.e-dark .e-dropdown-btn.e-inherit:active,.e-appbar.e-dark .e-dropdown-btn.e-inherit.e-active,.e-appbar.e-dark .e-dropdown-btn.e-btn.e-inherit:hover,.e-appbar.e-dark .e-dropdown-btn.e-btn.e-inherit:focus,.e-appbar.e-dark .e-dropdown-btn.e-btn.e-inherit:active,.e-appbar.e-dark .e-dropdown-btn.e-btn.e-inherit.e-active{background:#ffffff14}.e-appbar.e-dark .e-menu-wrapper.e-inherit,.e-appbar.e-dark .e-menu-container.e-inherit{background:#212121;color:#fff;border-color:#212121;box-shadow:none}.e-appbar.e-dark .e-menu-wrapper.e-inherit .e-menu .e-menu-item.e-selected,.e-appbar.e-dark .e-menu-wrapper.e-inherit .e-menu .e-menu-item.e-focused,.e-appbar.e-dark .e-menu-container.e-inherit .e-menu .e-menu-item.e-selected,.e-appbar.e-dark .e-menu-container.e-inherit .e-menu .e-menu-item.e-focused{background:#ffffff14}.e-appbar.e-primary{background:#3f51b5;color:#fff;border-color:#3f51b5}.e-appbar.e-primary .e-appbar-separator{border-left:1px solid #fff}.e-appbar.e-primary .e-menu-wrapper.e-inherit,.e-appbar.e-primary .e-menu-container.e-inherit{background:#3f51b5;color:#fff;border-color:#3f51b5;box-shadow:none}.e-appbar.e-inherit{background:inherit;color:inherit;border-color:inherit;border:1px solid}.e-appbar.e-inherit .e-appbar-separator{border-left:1px solid}.e-appbar.e-inherit .e-menu-wrapper.e-inherit,.e-appbar.e-inherit .e-menu-container.e-inherit{background:inherit;color:inherit;border-color:inherit;box-shadow:none}.e-appbar.e-horizontal-bottom{box-shadow:0 -2px 3px #0000001a,0 -2px 6px #0003}.e-light.e-inherit.e-input-group,.e-light.e-inherit.e-input-group.e-control-wrapper,.e-light.e-inherit.e-float-input,.e-light.e-inherit.e-float-input.e-input-group,.e-light.e-inherit.e-float-input.e-control-wrapper,.e-light.e-inherit.e-float-input.e-input-group.e-control-wrapper,.e-light.e-inherit.e-input-group:not(.e-disabled) .e-input-group-icon:hover,.e-light.e-inherit.e-input-group.e-control-wrapper:not(.e-disabled) .e-input-group-icon:hover{background:#fff;color:#000}.e-dark.e-inherit.e-input-group,.e-dark.e-inherit.e-input-group.e-control-wrapper,.e-dark.e-inherit.e-float-input,.e-dark.e-inherit.e-float-input.e-input-group,.e-dark.e-inherit.e-float-input.e-control-wrapper,.e-dark.e-inherit.e-float-input.e-input-group.e-control-wrapper,.e-dark.e-inherit.e-input-group:not(.e-disabled) .e-input-group-icon:hover,.e-dark.e-inherit.e-input-group.e-control-wrapper:not(.e-disabled) .e-input-group-icon:hover{background:#212121;color:#fff}.e-primary.e-inherit.e-input-group,.e-primary.e-inherit.e-input-group.e-control-wrapper,.e-primary.e-inherit.e-float-input,.e-primary.e-inherit.e-float-input.e-input-group,.e-primary.e-inherit.e-float-input.e-control-wrapper,.e-primary.e-inherit.e-float-input.e-input-group.e-control-wrapper,.e-primary.e-inherit.e-input-group:not(.e-disabled) .e-input-group-icon:hover,.e-primary.e-inherit.e-input-group.e-control-wrapper:not(.e-disabled) .e-input-group-icon:hover{background:#3f51b5;color:#fff}.e-inherit.e-input-group,.e-inherit.e-input-group.e-control-wrapper,.e-inherit.e-float-input,.e-inherit.e-float-input.e-input-group,.e-inherit.e-float-input.e-control-wrapper,.e-inherit.e-float-input.e-input-group.e-control-wrapper,.e-inherit.e-input-group:not(.e-disabled) .e-input-group-icon:hover,.e-inherit.e-input-group.e-control-wrapper:not(.e-disabled) .e-input-group-icon:hover{color:inherit;background:#0000000e}.e-inherit.e-input-group.e-input-focus:not(.e-success):not(.e-warning):not(.e-error),.e-inherit.e-input-group.e-control-wrapper.e-input-focus:not(.e-success):not(.e-warning):not(.e-error),.e-inherit.e-input-group:not(.e-disabled):active:not(.e-success):not(.e-warning):not(.e-error),.e-inherit.e-input-group.e-control-wrapper:not(.e-disabled):active:not(.e-success):not(.e-warning):not(.e-error){box-shadow:none}.e-inherit.e-input-group.e-control-wrapper .e-searchinput::placeholder{color:inherit;opacity:.8}.e-inherit.e-input-group .e-input-group-icon,.e-inherit.e-input-group.e-control-wrapper .e-input-group-icon{border:none;color:inherit}.e-inherit.e-input-group .e-clear-icon,.e-inherit.e-input-group.e-control-wrapper .e-clear-icon{color:inherit}.e-bigger .e-appbar,.e-appbar.e-bigger{height:56px;font-size:14px}.e-bigger .e-appbar.e-dense,.e-appbar.e-bigger.e-dense{height:48px}.e-bigger .e-appbar.e-prominent,.e-appbar.e-bigger.e-prominent{height:112px}.e-step-indicator:before{content:"\e99e"}.e-stepper{position:relative}.e-stepper .e-step-selected .e-text,.e-stepper .e-step-selected .e-label{font-weight:600}.e-stepper.e-linear .e-step-container{pointer-events:none}.e-stepper.e-linear .e-previous:not(.e-step-disabled),.e-stepper.e-linear .e-next:not(.e-step-disabled),.e-stepper.e-linear .e-step-selected:not(.e-step-disabled),.e-stepper.e-linear .e-previous:not(.e-step-disabled)+li{pointer-events:auto}.e-stepper.e-stepper-readonly,.e-stepper .e-step-disabled{cursor:default;pointer-events:none}.e-stepper.e-step-type-indicator .e-step-container:not(.e-step-item.e-step-label.e-step-text) .e-icons.e-step-indicator{font-size:32px;border-radius:9999px}.e-stepper.e-step-type-indicator .e-step-content,.e-stepper.e-step-type-label .e-step-content{padding:0 8px}.e-stepper .e-step-container:has(.e-tooltip-wrap.e-stepper-tooltip),.e-stepper.e-vertical.e-label-after .e-step-item.e-step-label:has(.e-tooltip-wrap.e-stepper-tooltip),.e-stepper.e-vertical.e-label-before .e-step-item.e-step-label:has(.e-tooltip-wrap.e-stepper-tooltip){position:relative}.e-stepper.e-horizontal .e-step-item.e-step-label:has(.e-tooltip-wrap.e-stepper-tooltip){position:unset}.e-stepper .e-tooltip-wrap.e-stepper-tooltip{display:none;justify-content:center;left:50%;top:-8px;transform:translate(-50%,-100%)}.e-stepper .e-tooltip-wrap.e-stepper-tooltip.e-show-tooltip{display:inline-flex}.e-stepper .e-tooltip-wrap.e-stepper-tooltip .e-tip-content{width:max-content}.e-stepper .e-tooltip-wrap.e-stepper-tooltip .e-arrow-tip.e-tip-bottom{left:50%;top:100%;transform:translate(-50%)}.e-stepper .e-tooltip-wrap.e-stepper-tooltip .e-arrow-tip-inner.e-tip-bottom{top:-6px}.e-stepper .e-step-item.e-step-label .e-tooltip-wrap.e-stepper-tooltip{left:unset;top:0;transform:translateY(-135%)}.e-stepper.e-step-type-indicator .e-tooltip-wrap.e-stepper-tooltip{transform:translate(-50%,-115%)}.e-stepper .e-stepper-steps{display:flex;padding:0;margin:0;justify-content:space-between;position:relative;align-items:flex-start}.e-stepper .e-stepper-steps .e-step-container,.e-stepper .e-stepper-steps .e-step,.e-stepper .e-stepper-steps .e-step-valid.e-step-text.e-step-text-only .e-step-text-container,.e-stepper .e-stepper-steps .e-step-error.e-step-text.e-step-text-only .e-step-text-container,.e-stepper .e-stepper-steps .e-step-label-container{display:flex;align-items:center;justify-content:center}.e-stepper .e-step-container{max-width:var(--max-width);list-style-type:none;cursor:pointer;text-align:center}.e-stepper .e-step-container .e-step-label-container,.e-stepper .e-step-container .e-step-text-container{max-width:clamp(100%,10em,100%);white-space:nowrap;font-size:14px}.e-stepper .e-step-container .e-step-label-optional{font-size:12px;flex-basis:100%}.e-stepper .e-step-container .e-step-optional-container{display:flex;flex-direction:column}.e-stepper .e-step-container .e-step-content{font-size:16px;line-height:0}.e-stepper .e-step-container .e-indicator{font-size:16px}.e-stepper .e-step-container:not(.e-step-text-only)>.e-step-text-container{padding:0 8px}.e-stepper .e-step-container.e-step-text-only .e-step-text-container,.e-stepper .e-step-container.e-step-label-only .e-step-label-container{padding:0 6px;padding-block:5px}.e-stepper .e-step-container.e-step-text-only.e-step-error .e-step-text-container,.e-stepper .e-step-container.e-step-text-only.e-step-valid .e-step-text-container,.e-stepper .e-step-container.e-step-label-only.e-step-error .e-step-label-container,.e-stepper .e-step-container.e-step-label-only.e-step-valid .e-step-label-container{flex-direction:column}.e-stepper .e-step-container.e-step-text-only.e-step-error .e-step-text-container .e-step-validation-icon,.e-stepper .e-step-container.e-step-text-only.e-step-valid .e-step-text-container .e-step-validation-icon,.e-stepper .e-step-container.e-step-label-only.e-step-error .e-step-label-container .e-step-validation-icon,.e-stepper .e-step-container.e-step-label-only.e-step-valid .e-step-label-container .e-step-validation-icon{position:relative;top:.25em}.e-stepper .e-step-container .e-step,.e-stepper .e-step-container .e-indicator{border-radius:9999px;min-width:32px;min-height:32px}.e-stepper .e-step-notstarted:not(.e-step-disabled) .e-step,.e-stepper .e-step-notstarted:not(.e-step-disabled) .e-indicator{border:2px solid}.e-stepper.e-horizontal{display:block}.e-stepper.e-horizontal .e-stepper-steps{flex-direction:row}.e-stepper.e-horizontal.e-label-before:has(.e-step-item.e-step-label:not(.e-step-text)) .e-stepper-progressbar,.e-stepper.e-horizontal.e-label-after:has(.e-step-item.e-step-label:not(.e-step-text)) .e-stepper-progressbar{margin-left:var(--progress-left-position);top:var(--progress-top-position);width:var(--progress-bar-width)}.e-stepper.e-horizontal.e-label-before.e-rtl:has(.e-step-item.e-step-label:not(.e-step-text)) .e-stepper-progressbar,.e-stepper.e-horizontal.e-label-after.e-rtl:has(.e-step-item.e-step-label:not(.e-step-text)) .e-stepper-progressbar{margin-right:var(--progress-left-position);margin-left:unset}.e-stepper.e-horizontal .e-step-item.e-step-label{gap:1em;flex-direction:column}.e-stepper.e-horizontal .e-step-item.e-step-label .e-step-label-container{position:relative}.e-stepper.e-horizontal .e-step-item.e-step-label .e-step-label-container.e-label-before,.e-stepper.e-horizontal.e-label-start .e-step-text-container{order:-1}.e-stepper.e-horizontal .e-step-item.e-step-text:not(.e-step-label) .e-step-label-optional{position:absolute;top:2.5em;margin-left:2.5em}.e-stepper.e-horizontal.e-label-start .e-step-item.e-step-text:not(.e-step-label) .e-step-label-optional,.e-stepper.e-horizontal.e-rtl .e-step-item.e-step-text:not(.e-step-label) .e-step-label-optional{margin-right:2.5em;margin-left:unset}.e-stepper.e-horizontal.e-label-start.e-rtl .e-step-item.e-step-text:not(.e-step-label) .e-step-label-optional{margin-right:unset;margin-left:2.5em}.e-stepper.e-horizontal.e-label-before .e-stepper-steps:has(.e-step-label-optional){align-items:flex-end}.e-stepper.e-horizontal.e-label-before .e-stepper-steps .e-step-label-container.e-label-before:has(.e-step-label-optional){flex-direction:column;gap:.5em}.e-stepper.e-horizontal .e-text,.e-stepper.e-horizontal .e-label,.e-stepper.e-horizontal .e-step-label-optional{text-overflow:ellipsis;overflow:hidden}.e-stepper.e-horizontal .e-step-text.e-step-text-only:has(.e-step-label-optional),.e-stepper.e-horizontal .e-step-label.e-step-label-only:has(.e-step-label-optional),.e-stepper.e-horizontal .e-step-item:not(.e-step-text):not(.e-step-label):has(.e-step-label-optional),.e-stepper.e-horizontal .e-step-container:not(.e-step-item):not(.e-step-text):not(.e-step-label):has(.e-step-label-optional),.e-stepper.e-horizontal .e-step-label-container.e-label-after:has(.e-step-label-optional),.e-stepper.e-horizontal.e-step-type-indicator .e-step-container{flex-wrap:wrap}.e-stepper.e-horizontal .e-step-item:not(.e-step-label):not(.e-step-text) .e-step-label-optional{margin-top:.5em}.e-stepper.e-horizontal.e-label-after .e-step-item.e-step-label:not(.e-step-text) .e-step-label-optional{margin-top:.2em}.e-stepper.e-vertical{min-height:inherit;display:inline-block}.e-stepper.e-vertical .e-step-label.e-step-label-only,.e-stepper.e-vertical .e-step-template{position:relative}.e-stepper.e-vertical:not(.e-label-top):not(.e-label-bottom) .e-step-label-optional{position:absolute}.e-stepper.e-vertical:not(.e-label-bottom):not(.e-label-top) .e-step-item.e-step-text:not(.e-step-label) .e-step-label-optional{margin-top:3em;margin-left:4em}.e-stepper.e-vertical.e-rtl:not(.e-label-bottom):not(.e-label-top) .e-step-item.e-step-text:not(.e-step-label) .e-step-label-optional{margin-left:unset;margin-right:4em}.e-stepper.e-vertical .e-stepper-steps{flex-direction:column;min-height:inherit;float:left;align-items:start;margin:0;justify-content:space-between}.e-stepper.e-vertical.e-rtl .e-stepper-steps{float:right}.e-stepper.e-vertical .e-stepper-steps:has(.e-step-item:not(.e-step-text):not(.e-step-label)),.e-stepper.e-vertical .e-stepper-steps:has(.e-step-text.e-step-text-only),.e-stepper.e-vertical .e-stepper-steps:has(.e-step-label.e-step-label-only),.e-stepper.e-vertical.e-label-after .e-stepper-steps:has(.e-step-label.e-step-text:not(.e-step-item)),.e-stepper.e-vertical.e-step-type-indicator .e-stepper-steps{align-items:center}.e-stepper.e-vertical .e-step-item.e-step-text:not(.e-step-label) .e-step-text-container,.e-stepper.e-vertical .e-step-item.e-step-label:not(.e-step-text) .e-step-label-container.e-label-after{margin-left:10px}.e-stepper.e-vertical.e-rtl .e-step-item.e-step-text:not(.e-step-label) .e-step-text-container,.e-stepper.e-vertical.e-rtl .e-step-item.e-step-label:not(.e-step-text) .e-step-label-container.e-label-after{margin-left:unset;margin-right:10px}.e-stepper.e-vertical .e-step-item:not(.e-step-label):not(.e-step-text):has(.e-step-label-optional),.e-stepper.e-vertical.e-label-before .e-step-label-container.e-label-before:has(.e-step-label-optional),.e-stepper.e-vertical .e-step-text-only.e-step-text:has(.e-step-label-optional),.e-stepper.e-vertical .e-step-label-only.e-step-label:has(.e-step-label-optional){flex-direction:column}.e-stepper.e-vertical .e-step-item:not(.e-step-label):not(.e-step-text):has(.e-step-label-optional) .e-step-label-optional,.e-stepper.e-vertical.e-label-before .e-step-label-container.e-label-before:has(.e-step-label-optional) .e-step-label-optional,.e-stepper.e-vertical .e-step-text-only.e-step-text:has(.e-step-label-optional) .e-step-label-optional,.e-stepper.e-vertical .e-step-label-only.e-step-label:has(.e-step-label-optional) .e-step-label-optional{position:unset}.e-stepper.e-vertical .e-step-item:not(.e-step-label):not(.e-step-text):has(.e-step-label-optional),.e-stepper.e-vertical.e-label-before .e-step-label-container.e-label-before:has(.e-step-label-optional){gap:.5em}.e-stepper.e-vertical.e-label-before .e-step-item.e-step-label .e-step-label-container.e-label-after:has(.e-step-label-optional),.e-stepper.e-vertical.e-label-after .e-step-item.e-step-label .e-step-label-container.e-label-after:has(.e-step-label-optional){flex-direction:column}.e-stepper.e-vertical.e-label-before .e-step-item.e-step-label .e-step-label-container.e-label-after:has(.e-step-label-optional) .e-label,.e-stepper.e-vertical.e-label-after .e-step-item.e-step-label .e-step-label-container.e-label-after:has(.e-step-label-optional) .e-label{line-height:2em}.e-stepper.e-vertical.e-label-before .e-step-item.e-step-label .e-step-label-optional,.e-stepper.e-vertical.e-label-after .e-step-item.e-step-label .e-step-label-optional{position:unset}.e-stepper.e-vertical .e-step-container.e-step-label.e-step-text:not(.e-step-item) .e-step-label-container.e-label-after{position:absolute}.e-stepper.e-vertical .e-step-container.e-step-label.e-step-text:not(.e-step-item) .e-step-label-container.e-label-after .e-step-label-optional{left:0}.e-stepper.e-vertical .e-step-container .e-step-label-container.e-label-after .e-step-label-optional{font-size:12px}.e-stepper.e-vertical .e-step-container .e-step-label-container.e-label-before .e-label{width:var(--label-width)}.e-stepper.e-vertical .e-step-container:not(.e-step-text-only) .e-step-text-container{border:none;border-radius:unset;padding:6px 0}.e-stepper.e-vertical .e-step-container.e-step-text-only .e-step-text-container,.e-stepper.e-vertical .e-step-container.e-step-label-only .e-step-label-container{position:unset}.e-stepper.e-vertical.e-label-top .e-step-label-optional{padding-bottom:6px}.e-stepper.e-vertical.e-label-top .e-stepper-steps,.e-stepper.e-vertical.e-label-bottom .e-stepper-steps{align-items:center}.e-stepper.e-vertical.e-label-top .e-stepper-steps .e-step-container,.e-stepper.e-vertical.e-label-bottom .e-stepper-steps .e-step-container{flex-direction:column}.e-stepper.e-vertical.e-label-top .e-stepper-steps .e-step-container .e-step-text-container,.e-stepper.e-vertical.e-label-bottom .e-stepper-steps .e-step-container .e-step-text-container{margin-left:0}.e-stepper.e-vertical.e-label-top .e-step-container .e-step-label-optional,.e-stepper.e-vertical.e-label-top .e-step-container .e-step-text-container{order:-1}.e-stepper .e-stepper-progressbar{height:1.6px;position:absolute;top:var(--progress-top-position);width:100%}.e-stepper .e-stepper-progressbar>.e-progressbar-value{height:100%;width:var(--progress-value);transition-property:width;transition-duration:var(--duration);transition-delay:var(--delay)}.e-stepper.e-vertical .e-stepper-progressbar{min-height:inherit;width:1.6px;top:0;left:var(--progress-position)}.e-stepper.e-vertical .e-stepper-progressbar>.e-progressbar-value{width:100%;height:var(--progress-value);transition-property:height}.e-stepper.e-vertical.e-rtl .e-stepper-progressbar{right:var(--progress-position);left:unset}.e-stepper:not(.e-steps-focus):not(.e-step-type-label):not(.e-step-type-indicator) .e-step-container .e-indicator,.e-stepper .e-step-focus .e-indicator{z-index:0}.e-stepper .e-step-template.e-step-focus{outline:2px solid}.e-tooltip-wrap.e-stepper-tooltip.e-step-inprogress-tip .e-arrow-tip.e-tip-bottom{top:90%!important}.e-small.e-stepper.e-step-type-indicator .e-step-container:not(.e-step-item.e-step-label.e-step-text) .e-icons.e-step-indicator,.e-small .e-stepper.e-step-type-indicator .e-step-container:not(.e-step-item.e-step-label.e-step-text) .e-icons.e-step-indicator{font-size:28px}.e-small.e-stepper.e-step-type-indicator .e-step-container:not(.e-step-item.e-step-label.e-step-text).e-step-notstarted .e-icons.e-step-indicator,.e-small .e-stepper.e-step-type-indicator .e-step-container:not(.e-step-item.e-step-label.e-step-text).e-step-notstarted .e-icons.e-step-indicator{width:28px;height:28px}.e-small.e-stepper .e-step-container .e-step,.e-small.e-stepper .e-step-container .e-indicator,.e-small .e-stepper .e-step-container .e-step,.e-small .e-stepper .e-step-container .e-indicator{min-width:28px;min-height:28px}.e-small.e-stepper .e-step-container .e-indicator,.e-small .e-stepper .e-step-container .e-indicator{font-size:14px}.e-small.e-stepper .e-step-container .e-step-text-container,.e-small.e-stepper .e-step-container .e-step-label-container,.e-small .e-stepper .e-step-container .e-step-text-container,.e-small .e-stepper .e-step-container .e-step-label-container{font-size:12px}.e-small.e-stepper .e-step-container .e-step-content,.e-small .e-stepper .e-step-container .e-step-content{font-size:14px}.e-small.e-stepper .e-step-container .e-step-label-optional,.e-small .e-stepper .e-step-container .e-step-label-optional,.e-small.e-stepper.e-vertical .e-step-label-container.e-label-after .e-step-label-optional,.e-small .e-stepper.e-vertical .e-step-label-container.e-label-after .e-step-label-optional{font-size:10px}.e-stepper .e-step-notstarted:not(.e-step-disabled) .e-step,.e-stepper .e-step-notstarted:not(.e-step-disabled) .e-indicator,.e-stepper .e-step-notstarted .e-icons.e-step-indicator{border-color:#bdbdbd}.e-stepper .e-step-label-optional{color:#424242}.e-stepper .e-step,.e-stepper .e-indicator{color:#000;background:#fff}.e-stepper .e-step-indicator{color:transparent}.e-stepper .e-step-completed .e-step,.e-stepper .e-step-inprogress .e-step,.e-stepper .e-step-completed .e-indicator,.e-stepper .e-step-inprogress .e-indicator,.e-stepper .e-step-completed .e-step-indicator,.e-stepper .e-step-inprogress .e-step-indicator{background:#3f51b5;color:#fff}.e-stepper .e-step-selected .e-indicator{background:#3f51b5}.e-stepper .e-step-valid .e-indicator{background:#4d831e;color:#fff}.e-stepper .e-step-error .e-indicator{background:#e51b0d;color:#fff}.e-stepper .e-step-error .e-text,.e-stepper .e-step-error .e-label{color:#e51b0d}.e-stepper .e-step-valid:not(.e-step-notstarted) .e-indicator:hover,.e-stepper .e-step-error .e-indicator:hover{color:#000}.e-stepper .e-step-valid.e-step-text-only .e-step-validation-icon,.e-stepper .e-step-valid.e-step-label-only .e-step-validation-icon{color:#4d831e}.e-stepper .e-step-error.e-step-text-only .e-step-validation-icon,.e-stepper .e-step-error.e-step-label-only .e-step-validation-icon{color:#f44336}.e-stepper .e-text,.e-stepper .e-label{color:#000}.e-stepper .e-step-selected:not(.e-step-error) .e-text,.e-stepper .e-step-selected:not(.e-step-error) .e-label,.e-stepper .e-step-completed:not(.e-step-error) .e-text,.e-stepper .e-step-completed:not(.e-step-error) .e-label{color:#3f51b5}.e-stepper .e-step-label:not(.e-step-item) .e-step-label-container{background-color:#fff}.e-stepper .e-step-text-container{background-color:#fff;border-color:transparent}.e-stepper .e-step-disabled .e-indicator{background:#e0e0e0;color:#757575}.e-stepper .e-step-disabled .e-text,.e-stepper .e-step-disabled .e-label,.e-stepper .e-step-disabled .e-step-validation-icon{color:#9e9e9e}.e-stepper.e-vertical .e-step-text-only.e-step-text .e-step-label-optional,.e-stepper.e-vertical .e-step-label-only.e-step-label .e-step-label-optional,.e-stepper.e-vertical .e-step-item:not(.e-step-text):not(.e-step-label) .e-step-label-optional,.e-stepper.e-vertical.e-label-top .e-step-label-optional,.e-stepper.e-vertical.e-label-bottom .e-step-label-optional{background-color:#fff}.e-stepper .e-stepper-progressbar{background-color:#bdbdbd}.e-stepper .e-stepper-progressbar>.e-progressbar-value{background-color:#3f51b5}.e-stepper:not(.e-steps-focus) .e-step-selected .e-step{box-shadow:0 0 0 2px #fff,0 0 0 4px #3f51b5,0 0 0 8px #fff}.e-stepper .e-step-focus .e-step,.e-stepper .e-step-label-only.e-step-focus .e-label,.e-stepper .e-step-text-only.e-step-focus .e-text,.e-stepper .e-step-template.e-step-focus,.e-stepper:not(.e-steps-focus) :focus-visible .e-step,.e-stepper:not(.e-steps-focus) .e-step-text-only:focus-visible .e-text,.e-stepper:not(.e-steps-focus) .e-step-label-only:focus-visible .e-label{box-shadow:0 0 0 2px #fff,0 0 0 4px #000,0 0 0 8px #fff}.e-stepper:not(.e-steps-focus) .e-step-valid.e-step-selected .e-step,.e-stepper .e-step-valid.e-step-focus .e-step,.e-stepper .e-step-valid.e-step-label-only.e-step-focus .e-label,.e-stepper .e-step-valid.e-step-text-only.e-step-focus .e-text,.e-stepper .e-step-valid.e-step-template.e-step-focus{box-shadow:0 0 0 2px #fff,0 0 0 4px #4d831e,0 0 0 8px #fff}.e-stepper:not(.e-steps-focus) .e-step-error.e-step-selected .e-step,.e-stepper .e-step-error.e-step-focus .e-step,.e-stepper .e-step-error.e-step-label-only.e-step-focus .e-label,.e-stepper .e-step-error.e-step-text-only.e-step-focus .e-text,.e-stepper .e-step-error.e-step-template.e-step-focus{box-shadow:0 0 0 2px #fff,0 0 0 4px #e51b0d,0 0 0 8px #fff}.e-stepper .e-step-container:not(.e-step-focus).e-step-notstarted .e-step,.e-stepper .e-step-container:not(.e-step-focus).e-step-completed .e-step,.e-stepper.e-steps-focus .e-step-container:not(.e-step-focus).e-step-selected .e-step{box-shadow:0 0 0 8px #fff}.e-stepper .e-step-notstarted:not(.e-step-disabled) .e-step:hover,.e-stepper .e-step-notstarted:not(.e-step-disabled) .e-indicator:hover{border-color:#bdbdbd}.e-stepper .e-step-notstarted:not(.e-step-disabled) .e-step:active,.e-stepper .e-step-notstarted:not(.e-step-disabled) .e-indicator:active{border-color:#bdbdbd}.e-stepper:not(.e-step-type-label) .e-indicator:hover,.e-stepper:not(.e-step-type-label) .e-step:hover{color:#fff;background:#32408f}.e-stepper:not(.e-step-type-label) .e-step-notstarted .e-indicator:hover,.e-stepper:not(.e-step-type-label) .e-step-notstarted .e-step:hover{color:#000}.e-stepper:not(.e-step-type-label) .e-step-selected .e-indicator:active,.e-stepper:not(.e-step-type-label) .e-step-selected .e-step:active{background:#2b387c}.e-stepper:not(.e-step-type-label) .e-step-valid.e-step-selected .e-indicator:active,.e-stepper:not(.e-step-type-label) .e-step-valid.e-step-selected .e-step:active{background:#4d831e}.e-stepper:not(.e-step-type-label) .e-step-error.e-step-selected .e-indicator:active,.e-stepper:not(.e-step-type-label) .e-step-error.e-step-selected .e-step:active{background:#e51b0d}.e-stepper:not(.e-step-type-label) .e-step-notstarted .e-indicator:hover,.e-stepper:not(.e-step-type-label) .e-step-notstarted .e-step:hover{background:#9e9e9e}.e-stepper:not(.e-step-type-label) .e-step-notstarted .e-indicator:active,.e-stepper:not(.e-step-type-label) .e-step-notstarted .e-step:active{background:#757575}.e-stepper:not(.e-step-type-label) .e-step-valid .e-indicator:hover,.e-stepper:not(.e-step-type-label) .e-step-valid .e-step:hover{color:#fff;background:#4d831e}.e-stepper:not(.e-step-type-label) .e-step-error .e-indicator:hover,.e-stepper:not(.e-step-type-label) .e-step-error .e-step:hover{color:#fff;background:#e51b0d}.e-bigger.e-stepper.e-step-type-indicator .e-step-container:not(.e-step-item.e-step-label.e-step-text) .e-icons.e-step-indicator,.e-bigger .e-stepper.e-step-type-indicator .e-step-container:not(.e-step-item.e-step-label.e-step-text) .e-icons.e-step-indicator{font-size:40px}.e-bigger.e-stepper.e-step-type-indicator .e-step-container:not(.e-step-item.e-step-label.e-step-text).e-step-notstarted .e-icons.e-step-indicator,.e-bigger .e-stepper.e-step-type-indicator .e-step-container:not(.e-step-item.e-step-label.e-step-text).e-step-notstarted .e-icons.e-step-indicator{width:40px;height:40px}.e-bigger.e-stepper .e-step-container .e-step,.e-bigger.e-stepper .e-step-container .e-indicator,.e-bigger .e-stepper .e-step-container .e-step,.e-bigger .e-stepper .e-step-container .e-indicator{min-width:40px;min-height:40px}.e-bigger.e-stepper .e-step-container .e-indicator,.e-bigger .e-stepper .e-step-container .e-indicator{font-size:18px}.e-bigger.e-stepper .e-step-container .e-step-text-container,.e-bigger.e-stepper .e-step-container .e-step-label-container,.e-bigger .e-stepper .e-step-container .e-step-text-container,.e-bigger .e-stepper .e-step-container .e-step-label-container{font-size:16px}.e-bigger.e-stepper .e-step-container .e-step-content,.e-bigger .e-stepper .e-step-container .e-step-content{font-size:18px}.e-bigger.e-stepper .e-step-container .e-step-label-optional,.e-bigger .e-stepper .e-step-container .e-step-label-optional,.e-bigger.e-stepper.e-vertical .e-step-label-container.e-label-after .e-step-label-optional,.e-bigger .e-stepper.e-vertical .e-step-label-container.e-label-after .e-step-label-optional{font-size:14px}.e-bigger.e-small.e-stepper.e-step-type-indicator .e-step-container:not(.e-step-item.e-step-label.e-step-text) .e-icons.e-step-indicator,.e-bigger.e-small .e-stepper.e-step-type-indicator .e-step-container:not(.e-step-item.e-step-label.e-step-text) .e-icons.e-step-indicator,.e-bigger .e-small.e-stepper.e-step-type-indicator .e-step-container:not(.e-step-item.e-step-label.e-step-text) .e-icons.e-step-indicator,.e-small .e-bigger.e-stepper.e-step-type-indicator .e-step-container:not(.e-step-item.e-step-label.e-step-text) .e-icons.e-step-indicator{font-size:36px}.e-bigger.e-small.e-stepper.e-step-type-indicator .e-step-container:not(.e-step-item.e-step-label.e-step-text).e-step-notstarted .e-icons.e-step-indicator,.e-bigger.e-small .e-stepper.e-step-type-indicator .e-step-container:not(.e-step-item.e-step-label.e-step-text).e-step-notstarted .e-icons.e-step-indicator,.e-bigger .e-small.e-stepper.e-step-type-indicator .e-step-container:not(.e-step-item.e-step-label.e-step-text).e-step-notstarted .e-icons.e-step-indicator,.e-small .e-bigger.e-stepper.e-step-type-indicator .e-step-container:not(.e-step-item.e-step-label.e-step-text).e-step-notstarted .e-icons.e-step-indicator{width:36px;height:36px}.e-bigger.e-small.e-stepper .e-step-container .e-step,.e-bigger.e-small.e-stepper .e-step-container .e-indicator,.e-bigger.e-small .e-stepper .e-step-container .e-step,.e-bigger.e-small .e-stepper .e-step-container .e-indicator,.e-bigger .e-small.e-stepper .e-step-container .e-step,.e-bigger .e-small.e-stepper .e-step-container .e-indicator,.e-small .e-bigger.e-stepper .e-step-container .e-step,.e-small .e-bigger.e-stepper .e-step-container .e-indicator{min-width:36px;min-height:36px}.e-bigger.e-small.e-stepper .e-step-container .e-indicator,.e-bigger.e-small .e-stepper .e-step-container .e-indicator,.e-bigger .e-small.e-stepper .e-step-container .e-indicator,.e-small .e-bigger.e-stepper .e-step-container .e-indicator{font-size:16px}.e-bigger.e-small.e-stepper .e-step-container .e-step-text-container,.e-bigger.e-small.e-stepper .e-step-container .e-step-label-container,.e-bigger.e-small .e-stepper .e-step-container .e-step-text-container,.e-bigger.e-small .e-stepper .e-step-container .e-step-label-container,.e-bigger .e-small.e-stepper .e-step-container .e-step-text-container,.e-bigger .e-small.e-stepper .e-step-container .e-step-label-container,.e-small .e-bigger.e-stepper .e-step-container .e-step-text-container,.e-small .e-bigger.e-stepper .e-step-container .e-step-label-container{font-size:14px}.e-bigger.e-small.e-stepper .e-step-container .e-step-content,.e-bigger.e-small .e-stepper .e-step-container .e-step-content,.e-bigger .e-small.e-stepper .e-step-container .e-step-content,.e-small .e-bigger.e-stepper .e-step-container .e-step-content{font-size:16px}.e-bigger.e-small.e-stepper .e-step-container .e-step-label-optional,.e-bigger.e-small .e-stepper .e-step-container .e-step-label-optional,.e-bigger .e-small.e-stepper .e-step-container .e-step-label-optional,.e-small .e-bigger.e-stepper .e-step-container .e-step-label-optional,.e-bigger.e-small.e-stepper.e-vertical .e-step-label-container.e-label-after .e-step-label-optional,.e-bigger.e-small .e-stepper.e-vertical .e-step-label-container.e-label-after .e-step-label-optional,.e-bigger .e-small.e-stepper.e-vertical .e-step-label-container.e-label-after .e-step-label-optional,.e-small .e-bigger.e-stepper.e-vertical .e-step-label-container.e-label-after .e-step-label-optional{font-size:12px}.e-dialog .e-icon-dlg-close:before{content:"\e7fc";position:relative}.e-dialog .e-icon-dlg-close,.e-dialog .e-icon-dlg-close:active,.e-dialog .e-icon-dlg-close:hover{opacity:initial}.e-dialog .e-south-east:before,.e-dialog .e-south-west:before,.e-dialog .e-north-east:before,.e-dialog .e-north-west:before{content:"\eb05"}.e-dialog{border:none;border-radius:2px;flex-direction:column;width:100%}.e-dialog.e-popup{width:100%}.e-dialog.e-dlg-resizable{padding-bottom:15px;touch-action:none}.e-dialog .e-dlg-header-content{border-radius:1px 1px 0 0;line-height:30px}.e-dialog .e-dlg-header-content+.e-dlg-content{padding-top:0}.e-dialog .e-btn .e-btn-icon.e-icon-dlg-close{font-size:12px;width:auto}.e-dialog .e-dlg-header{display:block;font-size:18px;font-weight:400;overflow:hidden;text-overflow:ellipsis;-webkit-user-select:none;user-select:none;vertical-align:top;white-space:nowrap;width:80%}.e-dialog .e-dlg-header.e-hide{display:none}.e-dialog .e-dlg-modal{position:fixed}.e-dialog .e-scroll-disabled{overflow:hidden!important}.e-dialog .e-dlg-content{display:block;flex:1 1 auto;font-size:13px;font-weight:400;line-height:normal;overflow:auto;overflow-x:hidden}.e-dialog .e-dlg-content.e-hide{display:none}.e-dialog .e-footer-content{border-bottom-left-radius:0;border-bottom-right-radius:0;border-top:none;bottom:0;display:block;right:0;width:100%}.e-dialog .e-footer-content.e-hide{display:none}.e-dialog .e-footer-content{text-align:right}.e-dialog .e-resize-handle{height:15px;position:absolute;width:15px}.e-dialog .e-resize-handle.e-south-east{bottom:0;cursor:nwse-resize;right:0}.e-dialog .e-resize-handle.e-south-west{bottom:0;cursor:nesw-resize;left:0;transform:rotate(90deg)}.e-dialog .e-resize-handle.e-north-east{cursor:nesw-resize;right:0;top:0;transform:rotate(-90deg)}.e-dialog .e-resize-handle.e-north-west{cursor:nwse-resize;left:0;top:0;transform:rotate(180deg)}.e-dialog .e-south,.e-dialog .e-north,.e-dialog .e-east,.e-dialog .e-west{background-color:transparent;background-repeat:repeat;overflow:visible;position:absolute}.e-dialog .e-east,.e-dialog .e-west{cursor:ew-resize}.e-dialog .e-south,.e-dialog .e-north{cursor:ns-resize}.e-dialog.e-blazor-hidden{left:0;position:absolute}.e-dialog .e-dlg-header-content{border-bottom:none;padding:18px}.e-dialog .e-dlg-content{padding:18px}.e-dialog .e-footer-content{padding:8px}.e-dialog .e-footer-content .e-btn{margin-left:6px}.e-alert-dialog .e-footer-content{border-top:none}.e-rtl .e-footer-content .e-btn{margin-right:6px}.e-dialog.e-draggable>.e-dlg-header-content{cursor:move}.e-dialog.e-device.e-draggable.e-popup-open{touch-action:none}.e-dialog{max-height:98%;max-width:100%;min-width:240px;position:absolute}.e-rtl .e-footer-content .e-btn{margin-left:0}.e-rtl .e-footer-content{text-align:left}.e-dialog.e-rtl .e-dlg-header-content .e-btn.e-dlg-closeicon-btn{float:left;left:0;right:0}.e-dialog .e-dlg-header-content .e-btn.e-dlg-closeicon-btn{background-color:transparent;border-color:transparent;border-radius:50%;bottom:0;float:right;height:30px;left:0;position:relative;width:30px}.e-rtl.e-dialog .e-resize-handle.e-south-west{bottom:0;cursor:sw-resize;direction:ltr;left:0;text-align:initial;transform:rotate(90deg)}.e-dlg-target.e-scroll-disabled{overflow:hidden!important}.e-dlg-overlay{height:100%;left:0;opacity:.5;position:fixed;top:0;transition:opacity .15s linear;width:100%}.e-dlg-overlay.e-fade{opacity:0}.e-dlg-overflow-hidden{overflow:auto}.e-dlg-fullscreen{height:100%!important;left:0!important;width:100%!important}.e-popup.e-popup-open.e-dialog{display:inline-flex}.e-dlg-container{align-items:flex-start;display:none;height:100%;left:0;position:fixed;top:0;width:100%}.e-dlg-center-center{-webkit-align-items:center;-webkit-justify-content:center;align-items:center;justify-content:center}.e-dlg-left-center{-webkit-align-items:center;-webkit-justify-content:flex-start;align-items:center;justify-content:flex-start}.e-dlg-right-center{-webkit-align-items:center;-webkit-justify-content:flex-end;align-items:center;justify-content:flex-end}.e-dlg-left-top{-webkit-align-items:flex-start;-webkit-justify-content:flex-start;align-items:flex-start;justify-content:flex-start}.e-dlg-right-top{-webkit-align-items:flex-start;-webkit-justify-content:flex-end;align-items:flex-start;justify-content:flex-end}.e-dlg-center-top{align-items:center;flex-direction:column}.e-dlg-left-bottom{-webkit-align-items:flex-end;-webkit-justify-content:flex-start;align-items:flex-end;justify-content:flex-start}.e-dlg-right-bottom{-webkit-align-items:flex-end;-webkit-justify-content:flex-end;align-items:flex-end;justify-content:flex-end}.e-dlg-center-bottom{-webkit-align-items:center;-webkit-justify-content:flex-end;align-items:center;flex-direction:column;justify-content:flex-end}.e-dialog .e-btn.e-dlg-closeicon-btn:hover,.e-dialog .e-btn.e-dlg-closeicon-btn:focus,.e-dialog .e-btn.e-dlg-closeicon-btn:active{background-color:#e0e0e0;border-color:transparent;box-shadow:0 0 0 transparent}.e-dialog .e-btn.e-dlg-closeicon-btn:active{background-color:#e0e0e0}.e-content-placeholder.e-dialog.e-placeholder-dialog{background-size:400px 210px;min-height:210px}@media (min-width: 768px){.e-alert-dialog.e-dialog.e-popup,.e-confirm-dialog.e-dialog.e-popup{margin:30px;width:600px}}@media (max-width: 768px){.e-alert-dialog.e-dialog.e-popup,.e-confirm-dialog.e-dialog.e-popup{margin:30px;width:auto}}@media (max-width: 768px){.e-prompt-dialog.e-dialog.e-popup{margin:30px;width:auto}}@media (min-width: 768px){.e-prompt-dialog.e-dialog.e-popup{margin:30px;width:600px}}.e-dlg-ref-element{display:none}.e-dialog .e-footer-content{box-sizing:border-box}.e-dialog{background-color:#fff;box-shadow:0 11px 15px -7px #0003,0 24px 38px 3px #00000024,0 9px 46px 8px #0000001f}.e-dlg-overlay{background-color:#383838}.e-footer-content{background-color:#fff}.e-dlg-header,.e-dlg-header *{color:#000000de;font-size:18px;font-weight:400}.e-dlg-content{color:#000000de}.e-device .e-dlg-content{font-size:14px}.e-dlg-header-content,.e-dlg-content{background-color:#fff}.e-icon-dlg-close,.e-dialog .e-btn.e-dlg-closeicon-btn:hover span{color:#000}.e-dialog .e-btn.e-dlg-closeicon-btn:active span,.e-dialog .e-btn.e-dlg-closeicon-btn:focus span{border-radius:50%;color:#000;opacity:1}.e-icon-dlg-close:active{border-radius:50%;color:#000;opacity:1}.e-icon-dlg-close:hover{color:#000}.e-dlg-header-content .e-dlg-closeicon-btn:hover,.e-dlg-header-content .e-dlg-closeicon-btn:active{background-color:transparent}.e-south-east{color:#000}.e-rtl .e-south-east{color:transparent}.e-rtl .e-south-west{color:#000}.e-south-west,.e-north-east,.e-north-west{color:transparent}.e-bigger.e-dialog .e-dlg-header-content,*.e-bigger .e-dialog .e-dlg-header-content{padding:24px 24px 20px}.e-bigger.e-dialog .e-dlg-header,*.e-bigger .e-dialog .e-dlg-header{font-size:18px}.e-bigger.e-dialog .e-dlg-content,*.e-bigger .e-dialog .e-dlg-content{font-size:13px;padding:24px}.e-bigger.e-dialog .e-footer-content,*.e-bigger .e-dialog .e-footer-content{padding:8px}.e-bigger.e-dialog .e-footer-content .e-btn,*.e-bigger .e-dialog .e-footer-content .e-btn{margin-left:8px}.e-bigger.e-dialog .e-dlg-header-content .e-btn.e-dlg-closeicon-btn,*.e-bigger .e-dialog .e-dlg-header-content .e-btn.e-dlg-closeicon-btn{bottom:3px;left:3px;height:36px;width:36px}.e-bigger.e-dialog .e-btn .e-btn-icon.e-icon-dlg-close,*.e-bigger .e-dialog .e-btn .e-btn-icon.e-icon-dlg-close{font-size:12px;width:auto}.e-bigger.e-rtl .e-footer-content .e-btn,.e-bigger .e-rtl .e-footer-content .e-btn{margin-left:0;margin-right:8px}.e-bigger .e-dlg-header-content+.e-dlg-content{padding-top:0}.e-bigger .e-content-placeholder.e-dialog.e-placeholder-dialog,.e-bigger.e-content-placeholder.e-dialog.e-placeholder-dialog{background-size:400px 220px;min-height:220px}/*! popup layout */.e-popup{height:auto;position:absolute;width:auto;z-index:1000}.e-popup.e-popup-open{display:block}.e-popup.e-popup-close{display:none}.e-tooltip-close:before{content:"\e7e9";font-size:16px}.e-arrow-tip-inner.e-tip-right:before{content:"\e848"}.e-arrow-tip-inner.e-tip-top:before{content:"\e918"}.e-arrow-tip-inner.e-tip-bottom:before{content:"\e919"}.e-arrow-tip-inner.e-tip-left:before{content:"\e84b"}.e-tooltip-popup-container{position:relative}.e-tooltip-wrap{max-width:350px;min-width:30px;padding:0;position:absolute;visibility:visible}.e-tooltip-wrap .e-arrow-tip{overflow:hidden;position:absolute}.e-tooltip-wrap .e-arrow-tip.e-tip-bottom{height:8px;left:50%;top:100%;width:16px}.e-tooltip-wrap .e-arrow-tip.e-tip-top{height:8px;left:50%;top:-9px;width:16px}.e-tooltip-wrap .e-arrow-tip.e-tip-left{height:16px;left:-9px;top:48%;width:8px}.e-tooltip-wrap .e-arrow-tip.e-tip-right{height:16px;left:100%;top:50%;width:8px}.e-tooltip-wrap .e-tooltip-close{cursor:pointer;float:right;position:absolute;right:-9px;top:-9px;z-index:inherit}.e-tooltip-wrap .e-tip-content{background-color:inherit;height:100%;line-height:16px;overflow-wrap:break-word;overflow-x:hidden;padding:3px 6px;position:relative;white-space:normal;width:100%;word-break:break-word;z-index:1}.e-tooltip-wrap{border-radius:2px;filter:none;opacity:.9}.e-tooltip-wrap.e-popup{background-color:#616161;border:1px solid #616161}.e-tooltip-wrap .e-arrow-tip-outer{height:0;left:0;position:absolute;top:0;width:0}.e-tooltip-wrap .e-arrow-tip-outer.e-tip-bottom{border-left:8px solid transparent;border-right:8px solid transparent;border-top:8px solid #616161}.e-tooltip-wrap .e-arrow-tip-outer.e-tip-top{border-bottom:8px solid #616161;border-left:8px solid transparent;border-right:8px solid transparent}.e-tooltip-wrap .e-arrow-tip-outer.e-tip-left{border-bottom:8px solid transparent;border-right:8px solid #616161;border-top:8px solid transparent}.e-tooltip-wrap .e-arrow-tip-outer.e-tip-right{border-bottom:8px solid transparent;border-left:8px solid #616161;border-top:8px solid transparent}.e-tooltip-wrap .e-arrow-tip-inner{height:0;position:absolute;width:0;z-index:10}.e-tooltip-wrap .e-arrow-tip-inner.e-tip-right,.e-tooltip-wrap .e-arrow-tip-inner.e-tip-left,.e-tooltip-wrap .e-arrow-tip-inner.e-tip-bottom,.e-tooltip-wrap .e-arrow-tip-inner.e-tip-top{color:#616161;font-family:e-icons;font-size:16px;font-style:normal;font-variant:normal;font-weight:400;line-height:1;text-transform:none}.e-tooltip-wrap .e-arrow-tip-inner.e-tip-bottom,.e-tooltip-wrap .e-arrow-tip-inner.e-tip-top{right:16px}.e-tooltip-wrap .e-arrow-tip-inner.e-tip-right,.e-tooltip-wrap .e-arrow-tip-inner.e-tip-left{bottom:16px}.e-tooltip-wrap .e-tooltip-close{background-color:#fff;border-color:transparent;border-radius:8px;color:#616161}.e-tooltip-wrap .e-tooltip-close:hover{background-color:#fff;color:#616161}.e-tooltip-wrap .e-tip-content{border-radius:inherit;color:#fff;font-family:Roboto,Segoe UI,GeezaPro,"DejaVu Serif","sans-serif",-apple-system,BlinkMacSystemFont;font-size:11px}.e-bigger .e-tooltip-wrap .e-tip-content,.e-tooltip-wrap.e-bigger .e-tip-content{line-height:20px;padding:5px 8px}.e-bigger .e-tooltip-wrap .e-tip-content,.e-tooltip-wrap.e-bigger .e-tip-content{font-size:14px}.e-spinner-pane{align-items:center;display:inline-flex;height:100%;justify-content:center;left:0;position:absolute;text-align:center;top:0;-webkit-user-select:none;user-select:none;vertical-align:middle;width:100%;z-index:1000}.e-spinner-pane:after{content:"Material";display:none}.e-spinner-pane.e-spin-left .e-spinner-inner{-webkit-transform:translateX(0%) translateY(-50%);left:0;padding-left:10px;transform:translate(0) translateY(-50%)}.e-spinner-pane.e-spin-right .e-spinner-inner{-webkit-transform:translateX(-100%) translateY(-50%);left:100%;padding-right:10px;transform:translate(-100%) translateY(-50%)}.e-spinner-pane.e-spin-center .e-spinner-inner{-webkit-transform:translateX(-50%) translateY(-50%);left:50%;transform:translate(-50%) translateY(-50%)}.e-spinner-pane.e-spin-hide{display:none}.e-spinner-pane.e-spin-show{display:inline-flex}.e-spinner-pane .e-spinner-inner{-webkit-transform:translateX(-50%) translateY(-50%);left:50%;margin:0;position:absolute;text-align:center;top:50%;transform:translate(-50%) translateY(-50%);z-index:1000}.e-spinner-pane .e-spinner-inner .e-spin-label{font-family:Roboto,Segoe UI;font-size:13px;margin-top:16px;text-align:center}.e-spinner-pane .e-spinner-inner .e-spin-material,.e-spinner-pane .e-spinner-inner .e-spin-material3{animation:material-spinner-rotate 1.56863s linear infinite;display:block;margin:0 auto}.e-spinner-pane .e-spinner-inner .e-spin-material .e-path-circle,.e-spinner-pane .e-spinner-inner .e-spin-material3 .e-path-circle{fill:none;stroke-linecap:square}.e-spinner-pane .e-spinner-inner .e-spin-bootstrap4{animation:material-spinner-rotate .75s linear infinite;border-radius:50%;display:block;margin:0 auto}.e-spinner-pane .e-spinner-inner .e-spin-bootstrap4 .e-path-circle{fill:none;stroke-linecap:square;stroke-width:4}.e-spinner-pane .e-spinner-inner .e-spin-fluent,.e-spinner-pane .e-spinner-inner .e-spin-fluent2,.e-spinner-pane .e-spinner-inner .e-spin-fabric{animation:fabric-spinner-rotate 1.3s infinite cubic-bezier(.53,.21,.29,.67);display:block;margin:0 auto;overflow:visible}.e-spinner-pane .e-spinner-inner .e-spin-fluent .e-path-arc,.e-spinner-pane .e-spinner-inner .e-spin-fluent .e-path-circle,.e-spinner-pane .e-spinner-inner .e-spin-fluent2 .e-path-arc,.e-spinner-pane .e-spinner-inner .e-spin-fluent2 .e-path-circle,.e-spinner-pane .e-spinner-inner .e-spin-fabric .e-path-arc,.e-spinner-pane .e-spinner-inner .e-spin-fabric .e-path-circle{fill:none;stroke-width:1.5}.e-spinner-pane .e-spinner-inner .e-spin-tailwind{animation:fabric-spinner-rotate 1.3s infinite cubic-bezier(.21,.21,.21,.21);display:block;margin:0 auto;overflow:visible}.e-spinner-pane .e-spinner-inner .e-spin-tailwind .e-path-arc,.e-spinner-pane .e-spinner-inner .e-spin-tailwind .e-path-circle{fill:none;stroke-width:4.5}.e-spinner-pane .e-spinner-inner .e-spin-bootstrap5,.e-spinner-pane .e-spinner-inner .e-spin-bootstrap5v3{animation:material-spinner-rotate .75s linear infinite;border-radius:50%;display:block;margin:0 auto}.e-spinner-pane .e-spinner-inner .e-spin-bootstrap5 .e-path-circle,.e-spinner-pane .e-spinner-inner .e-spin-bootstrap5v3 .e-path-circle{fill:none;stroke-linecap:square;stroke-width:4}.e-spinner-pane .e-spinner-inner .e-spin-bootstrap{display:block;margin:0 auto}.e-spinner-pane .e-spinner-inner .e-spin-high-contrast{animation:fabric-spinner-rotate 1.3s infinite cubic-bezier(.53,.21,.29,.67);display:block;margin:0 auto;overflow:visible}.e-spinner-pane .e-spinner-inner .e-spin-high-contrast .e-path-arc,.e-spinner-pane .e-spinner-inner .e-spin-high-contrast .e-path-circle{fill:none;stroke-width:1.5}.e-spinner-pane{background-color:transparent}.e-spinner-pane.e-spin-overlay{background-color:#0006}.e-spinner-pane.e-spin-overlay .e-spinner-inner .e-spin-label{color:#fff}.e-spinner-pane.e-spin-overlay .e-spinner-inner .e-spin-bootstrap{fill:#e3165b;stroke:#e3165b}.e-spinner-pane .e-spinner-inner .e-spin-label{color:#000000de}.e-spinner-pane .e-spinner-inner .e-spin-fluent .e-path-circle,.e-spinner-pane .e-spinner-inner .e-spin-fluent2 .e-path-circle,.e-spinner-pane .e-spinner-inner .e-spin-fabric .e-path-circle{stroke:#e3165b66}.e-spinner-pane .e-spinner-inner .e-spin-fluent .e-path-arc,.e-spinner-pane .e-spinner-inner .e-spin-fluent2 .e-path-arc,.e-spinner-pane .e-spinner-inner .e-spin-fabric .e-path-arc{stroke:#e3165b}.e-spinner-pane .e-spinner-inner .e-spin-tailwind .e-path-circle{stroke:#e3165b66}.e-spinner-pane .e-spinner-inner .e-spin-tailwind .e-path-arc,.e-spinner-pane .e-spinner-inner .e-spin-bootstrap5,.e-spinner-pane .e-spinner-inner .e-spin-bootstrap5v3{stroke:#e3165b}.e-spinner-pane .e-spinner-inner .e-spin-high-contrast .e-path-circle{stroke:#e3165b66}.e-spinner-pane .e-spinner-inner .e-spin-high-contrast .e-path-arc,.e-spinner-pane .e-spinner-inner .e-spin-material,.e-spinner-pane .e-spinner-inner .e-spin-material3,.e-spinner-pane .e-spinner-inner .e-spin-bootstrap4{stroke:#e3165b}.e-spinner-pane .e-spinner-inner .e-spin-bootstrap{fill:#e3165b;stroke:#e3165b}.e-dropdownbase .e-list-item .e-list-icon{padding:0 16px 0 0}.e-small .e-dropdownbase .e-list-item .e-list-icon{padding:0 12px 0 0}.e-dropdownbase{display:block;height:100%;min-height:36px;position:relative;width:100%}.e-dropdownbase .e-list-parent{margin:0;padding:0}.e-dropdownbase .e-list-group-item,.e-dropdownbase .e-fixed-head{cursor:default}.e-dropdownbase .e-list-item{cursor:pointer;overflow:hidden;position:relative;text-overflow:ellipsis;vertical-align:middle;white-space:nowrap;width:100%}.e-dropdownbase .e-list-item .e-list-icon{font-size:16px;vertical-align:middle}.e-dropdownbase .e-fixed-head{position:absolute;top:0}.e-dropdownbase.e-content{overflow:auto;position:relative}.e-popup.e-ddl .e-dropdownbase.e-nodata,.e-popup.e-mention .e-dropdownbase.e-nodata{color:#000;cursor:default;font-family:inherit;font-size:14px;padding:14px 16px;text-align:center}.e-mention.e-popup{background:#fff;border:0;box-shadow:0 2px 3px 1px #00000036;margin-top:2px;position:absolute}.e-mention .e-dropdownbase .e-list-item .e-highlight{display:inline;font-weight:700;vertical-align:baseline}.e-mention .e-mention-chip,.e-mention .e-mention-chip:hover{background:#eee;border-radius:2px;border:none;color:#e3165b;cursor:default}.e-mention.e-editable-element{border:2px solid #e0e0e0;height:auto;min-height:120px;width:100%}.e-form-mirror-div{white-space:pre-wrap}.e-rtl .e-dropdownbase.e-dd-group .e-list-item{padding-right:2em}.e-dropdownbase.e-dd-group .e-list-item{padding-left:2em;text-indent:0}.e-small .e-dropdownbase.e-dd-group .e-list-item{padding-left:2em}.e-popup.e-multi-select-list-wrapper.e-multiselect-group .e-dropdownbase.e-dd-group .e-list-group-item{text-indent:0}.e-popup.e-multi-select-list-wrapper.e-multiselect-group .e-dropdownbase.e-dd-group .e-list-group-item{cursor:pointer;font-weight:400;overflow:hidden;position:relative;text-overflow:ellipsis;vertical-align:middle;white-space:nowrap;width:100%}.e-rtl.e-multiselect-group .e-dropdownbase.e-dd-group .e-list-item{padding-right:2em}.e-rtl .e-dropdownbase .e-list-item,.e-small.e-rtl .e-dropdownbase .e-list-item,.e-small .e-rtl .e-dropdownbase .e-list-item,.e-rtl .e-small .e-dropdownbase .e-list-item{padding-left:16px;padding-right:0}.e-dropdownbase{border-color:#e0e0e0}.e-dropdownbase .e-list-item{-webkit-tap-highlight-color:transparent;border-bottom:0;border-color:#fff;color:#000000de;font-family:inherit;font-size:13px;line-height:36px;min-height:36px;padding-right:16px;text-indent:16px;background-color:#fff}.e-dropdownbase .e-list-group-item,.e-fixed-head{border-color:#fff;color:#0000008a;font-family:inherit;font-size:13px;font-weight:600;line-height:36px;min-height:36px;padding-left:16px;padding-right:16px;overflow:hidden;text-overflow:ellipsis;background-color:#fff}.e-dropdownbase .e-list-item.e-active,.e-dropdownbase .e-list-item.e-active.e-hover{background-color:#eee;border-color:#fff;color:#e3165b}.e-dropdownbase .e-list-item.e-hover{background-color:#eee;border-color:#fff;color:#000000de}.e-dropdownbase .e-list-item:last-child{border-bottom:0}.e-dropdownbase .e-list-item.e-item-focus{background-color:#eee}.e-multi-column.e-ddl.e-popup.e-popup-open table{border-collapse:collapse;table-layout:fixed;width:100%}.e-multi-column.e-ddl.e-popup.e-popup-open th,.e-multi-column.e-ddl.e-popup.e-popup-open td{display:table-cell;overflow:hidden;padding-right:16px;text-indent:10px;text-overflow:ellipsis}.e-multi-column.e-ddl.e-popup.e-popup-open th{line-height:36px;text-align:left}.e-multi-column.e-ddl.e-popup.e-popup-open .e-ddl-header{background-color:#fff;border-color:#e0e0e0;border-style:solid;border-width:0 0 1px 0;color:#0000008a;font-family:inherit;font-size:13px;font-weight:600;text-indent:10px}.e-multi-column.e-ddl.e-popup.e-popup-open .e-dropdownbase .e-list-item{padding-right:0}.e-multi-column.e-ddl.e-popup.e-popup-open.e-scroller .e-ddl-header{padding-right:16px}.e-multi-column.e-ddl.e-popup.e-popup-open .e-ddl-header,.e-multi-column.e-ddl.e-popup.e-popup-open.e-ddl-device .e-ddl-header{padding-right:0}.e-multi-column.e-ddl.e-popup.e-popup-open .e-text-center{text-align:center}.e-multi-column.e-ddl.e-popup.e-popup-open .e-text-right{text-align:right}.e-multi-column.e-ddl.e-popup.e-popup-open .e-text-left{text-align:left}.e-small .e-dropdownbase .e-list-item,.e-dropdownbase.e-small .e-list-item{color:#000;line-height:26px;min-height:26px;text-indent:12px}.e-small .e-dropdownbase .e-list-group-item,.e-small .e-dropdownbase .e-fixed-head,.e-dropdownbase.e-small .e-list-group-item,.e-dropdownbase.e-small .e-fixed-head{font-size:13px;line-height:26px;min-height:26px;padding-left:16px}.e-small .e-dropdownbase .e-list-item .e-list-icon,.e-dropdownbase.e-small .e-list-item .e-list-icon{font-size:14px}.e-ddl.e-popup.e-multiselect-group .e-list-group-item{background-color:#fff;border-bottom:0;border-color:#fff;color:#000000de;font-family:inherit;text-indent:16px;font-size:13px;padding-right:16px}.e-ddl.e-popup.e-multiselect-group .e-list-group-item.e-item-focus{background-color:#eee}.e-ddl.e-popup.e-multiselect-group .e-list-group-item.e-active,.e-ddl.e-popup.e-multiselect-group .e-list-group-item.e-active.e-hover{background-color:#eee;border-color:#fff;color:#e3165b}.e-ddl.e-popup.e-multiselect-group .e-list-group-item.e-hover{background-color:#eee;border-color:#fff;color:#000000de}.e-selectall-parent.e-item-focus{background-color:#eee}.e-bigger .e-dropdownbase,.e-dropdownbase.e-bigger{min-height:45px}.e-bigger .e-dropdownbase .e-list-item,.e-dropdownbase.e-bigger .e-list-item,.e-bigger .e-dropdownbase .e-list-group-item,.e-bigger .e-dropdownbase .e-fixed-head,.e-dropdownbase.e-bigger .e-list-group-item,.e-dropdownbase.e-bigger .e-fixed-head{line-height:48px;text-indent:16px}.e-bigger .e-dropdownbase .e-list-item .e-list-icon,.e-dropdownbase.e-bigger .e-list-item .e-list-icon{font-size:20px}.e-bigger .e-dropdownbase.e-dd-group .e-list-item,.e-small.e-bigger .e-dropdownbase.e-dd-group .e-list-item{padding-left:2em}.e-small.e-bigger.e-rtl .e-dropdownbase .e-list-item,.e-small.e-bigger .e-rtl .e-dropdownbase .e-list-item,.e-rtl .e-small.e-bigger .e-dropdownbase .e-list-item,.e-small .e-rtl.e-bigger .e-dropdownbase .e-list-item,.e-bigger .e-rtl.e-small .e-dropdownbase .e-list-item{padding-left:16px;padding-right:0}.e-bigger .e-dropdownbase .e-list-group-item,.e-bigger .e-dropdownbase .e-fixed-head{font-size:14px;padding-left:16px}.e-bigger.e-small .e-dropdownbase .e-list-group-item,.e-bigger.e-small .e-dropdownbase .e-fixed-head,.e-dropdownbase.e-bigger.e-small .e-list-group-item,.e-dropdownbase.e-bigger.e-small .e-fixed-head{font-size:13px}.e-bigger.e-small .e-dropdownbase .e-list-item,.e-dropdownbase.e-small.e-bigger .e-list-item{color:#000;line-height:40px;min-height:40px;text-indent:16px}.e-bigger.e-small .e-dropdownbase .e-list-group-item,.e-bigger.e-small .e-dropdownbase .e-fixed-head,.e-dropdownbase.e-small.e-bigger .e-list-group-item,.e-dropdownbase.e-small.e-bigger .e-fixed-head{line-height:40px;min-height:40px;padding-left:16px}.e-bigger.e-small .e-dropdownbase .e-list-item .e-list-icon,.e-dropdownbase.e-small.e-bigger .e-list-item .e-list-icon{font-size:18px}.e-bigger.e-small .e-dropdownbase .e-list-item .e-list-icon{padding:0 16px 0 0}.e-ddl .e-search-icon:before{content:"\e993"}.e-ddl .e-back-icon:before{content:"\e977"}.e-ddl.e-input-group.e-control-wrapper .e-ddl-icon:before{content:"\e969";font-family:e-icons}.e-popup.e-wide-popup.e-ddl-device.e-popup-close{display:block;visibility:hidden}.e-popup-full-page{inset:0;margin:0;overflow:hidden;padding:0}.e-popup-full-page .e-popup-full-page.e-ddl.e-popup.e-ddl-device-filter{margin:0}.e-ddl.e-control-wrapper .e-ddl-disable-icon{position:relative}.e-ddl.e-control-wrapper .e-ddl-disable-icon:before{content:""}.e-ddl-device-filter .e-filter-parent{background-color:#f5f5f5}.e-ddl input.e-input::-webkit-contacts-auto-fill-button{display:none;pointer-events:none;position:absolute;right:0;visibility:hidden}.e-filter-parent{border:0;border-top-width:0;box-shadow:0 1.5px 5px -2px #0000004d;display:block;padding:0}.e-ddl.e-input-group:not(.e-disabled){cursor:pointer}.e-ddl.e-popup.e-ddl-device-filter .e-input-group.e-input-focus:before,.e-ddl.e-popup.e-ddl-device-filter .e-input-group.e-input-focus:after{width:0}.e-ddl.e-popup{background:#fff;position:absolute}.e-ddl.e-popup .e-search-icon{margin:0;opacity:.57;padding:12px 8px 8px}.e-ddl.e-popup .e-filter-parent .e-back-icon{padding:0 8px}.e-ddl.e-popup.e-rtl .e-filter-parent .e-input-group.e-control-wrapper .e-input-filter,.e-ddl.e-popup .e-filter-parent .e-input-filter,.e-ddl.e-popup .e-filter-parent .e-input-filter:focus,.e-ddl.e-popup .e-filter-parent .e-input-group.e-input-focus .e-input-filter,.e-ddl.e-popup .e-filter-parent .e-input-group.e-control-wrapper.e-input-focus .e-input-filter{padding:8px 16px}.e-ddl.e-popup .e-input-group{margin-bottom:0}.e-ddl.e-popup .e-ddl-footer,.e-ddl.e-popup .e-ddl-header{cursor:default}.e-ddl.e-input-group .e-ddl-hidden,.e-ddl.e-float-input .e-ddl-hidden{-webkit-appearance:initial;border:0;height:0;padding:0;visibility:hidden;width:0}.e-ddl.e-input-group,.e-ddl.e-input-group.e-input-focus:focus{outline:none}.e-dropdownbase .e-list-item .e-highlight{display:inline;font-weight:700;vertical-align:baseline}.e-ddl.e-input-group input[readonly]~.e-clear-icon:not(.e-clear-icon-hide),.e-float-input input[readonly]~.e-clear-icon:not(.e-clear-icon-hide),.e-float-input.e-input-group input[readonly]~.e-clear-icon:not(.e-clear-icon-hide){opacity:1}.e-dropdownlist.e-input:not(:valid):first-child~.e-clear-icon,.e-input-group input.e-dropdownlist.e-input:not(:valid):first-child~.e-clear-icon,.e-input-group.e-control-wrapper input.e-dropdownlist.e-input:not(:valid):first-child~.e-clear-icon,.e-float-input input.e-dropdownlist:not(:valid):first-child~.e-clear-icon,.e-float-input.e-control-wrapper input.e-dropdownlist:not(:valid):first-child~.e-clear-icon,.e-float-input.e-input-group input.e-dropdownlist:not(:valid):first-child~.e-clear-icon,.e-float-input.e-input-group.e-control-wrapper input.e-dropdownlist:not(:valid):first-child~.e-clear-icon{display:flex}.e-dropdownlist.e-input:not(:valid):first-child~.e-clear-icon.e-clear-icon-hide,.e-input-group input.e-dropdownlist.e-input:not(:valid):first-child~.e-clear-icon.e-clear-icon-hide,.e-input-group.e-control-wrapper input.e-dropdownlist.e-input:not(:valid):first-child~.e-clear-icon.e-clear-icon-hide,.e-float-input input.e-dropdownlist:not(:valid):first-child~.e-clear-icon.e-clear-icon-hide,.e-float-input.e-control-wrapper input.e-dropdownlist:not(:valid):first-child~.e-clear-icon.e-clear-icon-hide,.e-float-input.e-input-group input.e-dropdownlist:not(:valid):first-child~.e-clear-icon.e-clear-icon-hide,.e-float-input.e-input-group.e-control-wrapper input.e-dropdownlist:not(:valid):first-child~.e-clear-icon.e-clear-icon-hide{display:none}.e-input-group.e-static-clear input.e-dropdownlist.e-input:not(:valid):first-child~.e-clear-icon.e-clear-icon-hide,.e-input-group.e-static-clear.e-control-wrapper input.e-dropdownlist.e-input:not(:valid):first-child~.e-clear-icon.e-clear-icon-hide,.e-float-input.e-static-clear input.e-dropdownlist:not(:valid):first-child~.e-clear-icon.e-clear-icon-hide,.e-float-input.e-static-clear.e-control-wrapper input.e-dropdownlist:not(:valid):first-child~.e-clear-icon.e-clear-icon-hide,.e-float-input.e-static-clear.e-input-group input.e-dropdownlist:not(:valid):first-child~.e-clear-icon.e-clear-icon-hide,.e-float-input.e-static-clear.e-input-group.e-control-wrapper input.e-dropdownlist:not(:valid):first-child~.e-clear-icon.e-clear-icon-hide{cursor:pointer;display:flex}.e-ddl.e-input-group .e-input-value,.e-ddl.e-input-group .e-input-value:focus{font-family:inherit;font-size:14px;height:auto;margin:0;outline:none;width:100%;overflow:hidden}.e-ddl.e-input-group input[readonly].e-input,.e-ddl.e-input-group input[readonly],.e-ddl.e-input-group .e-dropdownlist{pointer-events:none}.e-ddl.e-popup.e-popup-open .e-list-item.e-disabled{opacity:.7;pointer-events:none}ejs-autocomplete,ejs-combobox,ejs-dropdownlist{display:block}.e-small .e-ddl.e-popup .e-list-item,.e-input-group.e-ddl.e-small .e-list-item,.e-small .e-ddl.e-popup .e-list-group-item,.e-input-group.e-ddl.e-small .e-list-group-item,.e-small.e-ddl.e-popup .e-list-item,.e-small.e-ddl.e-popup .e-list-group-item{font-size:12px}.e-content-placeholder.e-ddl.e-placeholder-ddl,.e-content-placeholder.e-autocomplete.e-placeholder-autocomplete,.e-content-placeholder.e-combobox.e-placeholder-combobox{background-size:300px 33px;min-height:33px}.e-popup{border-color:#e0e0e0}.e-float-input.e-input-group.e-ddl.e-control.e-icon-anim>.e-float-text,.e-float-input.e-input-focus.e-input-group.e-ddl.e-control.e-keyboard>.e-float-text{color:#e3165b}.e-ddl.e-popup .e-filter-parent .e-input-group input.e-input-filter{border-color:transparent;background:none}.e-bigger .e-input-group.e-ddl .e-input-filter,.e-bigger .e-input-group.e-ddl .e-input-filter:focus{margin-left:-20px}.e-bigger .e-ddl.e-popup .e-list-item,.e-bigger .e-ddl.e-popup .e-list-group-item{font-size:14px}.e-bigger .e-ddl.e-popup .e-input-group{padding:4px 0}.e-bigger.e-ddl.e-popup .e-list-item,.e-bigger.e-ddl.e-popup .e-list-group-item{font-size:14px}.e-bigger.e-ddl.e-popup .e-input-group{padding:4px 0}.e-bigger.e-small .e-ddl.e-popup .e-list-item,.e-bigger .e-input-group.e-ddl.e-small .e-list-item,.e-bigger.e-small .e-ddl.e-popup .e-list-group-item,.e-bigger .e-input-group.e-ddl.e-small .e-list-group-item,.e-bigger.e-small.e-ddl.e-popup .e-list-item,.e-bigger.e-small.e-ddl.e-popup .e-list-group-item{font-size:13px}.e-bigger .e-content-placeholder.e-ddl.e-placeholder-ddl,.e-bigger.e-content-placeholder.e-ddl.e-placeholder-ddl,.e-bigger .e-content-placeholder.e-autocomplete.e-placeholder-autocomplete,.e-bigger.e-content-placeholder.e-autocomplete.e-placeholder-autocomplete,.e-bigger .e-content-placeholder.e-combobox.e-placeholder-combobox,.e-bigger.e-content-placeholder.e-combobox.e-placeholder-combobox{background-size:300px 40px;min-height:40px}.e-bigger .e-popup.e-ddl-device-filter .e-input-group.e-input-focus:not(.e-success):not(.e-warning):not(.e-error){border-color:#e0e0e0}.e-bigger .e-popup.e-ddl-device-filter{margin-top:0}.e-bigger .e-ddl-device .e-input-group,.e-bigger .e-ddl-device .e-input-group.e-input-focus:not(.e-success):not(.e-warning):not(.e-error){background:#f5f5f5;border-width:0;box-shadow:none;margin-bottom:0}.e-bigger .e-ddl-device .e-input-group .e-back-icon,.e-bigger .e-ddl-device .e-input-group input.e-input,.e-bigger .e-ddl-device .e-input-group .e-clear-icon{background-color:#f5f5f5}.e-bigger .e-popup.e-ddl:not(.e-ddl-device) .e-input-group .e-clear-icon,.e-bigger.e-popup.e-ddl:not(.e-ddl-device) .e-input-group .e-clear-icon{min-height:16px;min-width:16px}.e-bigger .e-popup.e-ddl:not(.e-ddl-device) .e-filter-parent .e-input-filter,.e-bigger.e-popup.e-ddl:not(.e-ddl-device) .e-filter-parent .e-input-filter{padding:8px 16px 8px 0}.e-bigger.e-small .e-popup.e-ddl:not(.e-ddl-device) .e-input-group .e-clear-icon,.e-bigger.e-small.e-popup.e-ddl:not(.e-ddl-device) .e-input-group .e-clear-icon,.e-bigger .e-popup.e-ddl:not(.e-ddl-device) .e-input-group.e-small .e-clear-icon,.e-bigger.e-popup.e-ddl:not(.e-ddl-device) .e-input-group.e-small .e-clear-icon,.e-small .e-popup.e-ddl:not(.e-ddl-device) .e-input-group.e-bigger .e-clear-icon,.e-small.e-popup.e-ddl:not(.e-ddl-device) .e-input-group.e-bigger .e-clear-icon,.e-popup.e-ddl:not(.e-ddl-device) .e-input-group.e-bigger.e-small .e-clear-icon{min-height:18px;min-width:18px}.e-bigger.e-small .e-popup.e-ddl:not(.e-ddl-device) .e-filter-parent .e-input-group .e-input-filter,.e-bigger.e-small.e-popup.e-ddl:not(.e-ddl-device) .e-filter-parent .e-input-group .e-input-filter,.e-bigger .e-popup.e-ddl:not(.e-ddl-device) .e-filter-parent .e-input-group.e-small .e-input-filter,.e-bigger.e-popup.e-ddl:not(.e-ddl-device) .e-filter-parent .e-input-group.e-small .e-input-filter,.e-small .e-popup.e-ddl:not(.e-ddl-device) .e-filter-parent .e-input-group.e-bigger .e-input-filter,.e-small.e-popup.e-ddl:not(.e-ddl-device) .e-filter-parent .e-input-group.e-bigger .e-input-filter,.e-popup.e-ddl:not(.e-ddl-device) .e-filter-parent .e-input-group.e-bigger.e-small .e-input-filter{padding:8px 16px}/*! TreeView's material theme wise override definitions and variables */.e-ddt .e-ddt-icon:before{content:"\e969"}.e-ddt .e-chips-close:before{content:"\e7e9"}.e-ddt{cursor:pointer;outline:none}.e-ddt .e-ddt-icon:before{transform:rotate(0);transition:transform .3s ease}.e-ddt.e-icon-anim .e-ddt-icon:before{transform:rotate(180deg);transition:transform .3s ease}.e-ddt .e-ddt-hidden{border:0;height:0;visibility:hidden;width:0}.e-ddt.e-input-group.e-control-wrapper .e-clear-icon,.e-ddt.e-float-input.e-control-wrapper .e-clear-icon{box-sizing:content-box;min-height:22px}.e-ddt.e-input-group.e-control-wrapper .e-input-group-icon.e-ddt-icon,.e-ddt.e-float-input.e-control-wrapper .e-input-group-icon.e-ddt-icon{border:0}.e-ddt.e-input-group.e-control-wrapper .e-icon-hide,.e-ddt.e-float-input.e-control-wrapper .e-icon-hide{display:none}.e-ddt.e-input-group.e-control-wrapper.e-show-chip .e-clear-icon,.e-ddt.e-input-group.e-control-wrapper.e-show-text .e-clear-icon,.e-ddt.e-float-input.e-control-wrapper.e-show-chip .e-clear-icon,.e-ddt.e-float-input.e-control-wrapper.e-show-text .e-clear-icon{bottom:0;position:absolute;right:0}.e-ddt.e-input-group.e-control-wrapper.e-show-chip.e-show-dd-icon .e-clear-icon,.e-ddt.e-input-group.e-control-wrapper.e-show-text.e-show-dd-icon .e-clear-icon,.e-ddt.e-float-input.e-control-wrapper.e-show-chip.e-show-dd-icon .e-clear-icon,.e-ddt.e-float-input.e-control-wrapper.e-show-text.e-show-dd-icon .e-clear-icon{right:18px}.e-ddt.e-input-group.e-control-wrapper.e-show-chip .e-ddt-icon,.e-ddt.e-input-group.e-control-wrapper.e-show-text .e-ddt-icon,.e-ddt.e-float-input.e-control-wrapper.e-show-chip .e-ddt-icon,.e-ddt.e-float-input.e-control-wrapper.e-show-text .e-ddt-icon{bottom:2px;position:absolute;right:0}.e-ddt.e-input-group.e-control-wrapper.e-show-chip.e-input-focus input.e-dropdowntree.e-chip-input,.e-ddt.e-input-group.e-control-wrapper.e-show-chip input.e-dropdowntree.e-chip-input,.e-ddt.e-input-group.e-control-wrapper.e-show-text.e-input-focus input.e-dropdowntree.e-chip-input,.e-ddt.e-input-group.e-control-wrapper.e-show-text input.e-dropdowntree.e-chip-input,.e-ddt.e-float-input.e-control-wrapper.e-show-chip.e-input-focus input.e-dropdowntree.e-chip-input,.e-ddt.e-float-input.e-control-wrapper.e-show-chip input.e-dropdowntree.e-chip-input,.e-ddt.e-float-input.e-control-wrapper.e-show-text.e-input-focus input.e-dropdowntree.e-chip-input,.e-ddt.e-float-input.e-control-wrapper.e-show-text input.e-dropdowntree.e-chip-input{padding-left:0;padding-right:0}.e-ddt.e-input-group.e-control-wrapper.e-valid-input:hover:not(.e-disabled) .e-clear-icon,.e-ddt.e-float-input.e-control-wrapper.e-valid-input:hover:not(.e-disabled) .e-clear-icon{display:flex}.e-ddt .e-chips-wrapper{width:100%}.e-ddt.e-show-chip .e-chips-close{min-height:16px;min-width:16px;line-height:16px;text-align:center}.e-ddt.e-show-chip .e-chips-close:before{font-size:16px}.e-ddt.e-show-chip .e-chips{align-items:center;border-radius:16px;box-sizing:border-box;display:inline-flex;float:left;height:24px;margin:3px 1px;max-width:calc(100% - 2px);overflow:hidden;padding:0 4px;text-overflow:ellipsis;white-space:nowrap}.e-ddt.e-show-chip .e-chips>.e-chipcontent{max-width:100%;overflow:hidden;padding:0 4px;text-indent:0;text-overflow:ellipsis;white-space:nowrap}.e-ddt.e-outline .e-overflow.e-show-text{padding:10px 12px 9px}.e-ddt.e-outline .e-overflow.e-total-count{padding:10px 12px}.e-ddt.e-outline.e-input-group.e-control-wrapper.e-show-dd-icon .e-clear-icon,.e-ddt.e-outline.e-float-input.e-control-wrapper.e-show-dd-icon .e-clear-icon{right:30px}.e-ddt.e-outline.e-input-group.e-control-wrapper:not(.e-show-chip).e-show-dd-icon.e-input-focus .e-clear-icon,.e-ddt.e-outline.e-float-input.e-control-wrapper:not(.e-show-chip).e-show-dd-icon.e-input-focus .e-clear-icon{min-height:20px}.e-ddt.e-outline.e-show-chip .e-overflow,.e-ddt.e-outline.e-show-chip .e-chips-wrapper{padding:4px 12px}.e-ddt.e-filled.e-float-input.e-control-wrapper .e-overflow.e-show-text{line-height:21px;padding:14px 2px 5px 0}.e-ddt.e-filled.e-float-input.e-control-wrapper .e-overflow .e-remain.e-wrap-count{padding-top:10px}.e-ddt.e-filled.e-float-input.e-control-wrapper:not(.e-show-chip) .e-ddt-icon,.e-ddt.e-filled.e-float-input.e-control-wrapper:not(.e-show-chip).e-show-dd-icon .e-clear-icon{padding-top:8px}.e-ddt.e-filled.e-float-input.e-control-wrapper.e-show-chip .e-ddt-icon,.e-ddt.e-filled.e-float-input.e-control-wrapper.e-show-text .e-ddt-icon{bottom:6px;right:10px}.e-ddt.e-filled.e-float-input.e-control-wrapper.e-show-chip .e-clear-icon,.e-ddt.e-filled.e-float-input.e-control-wrapper.e-show-text .e-clear-icon{bottom:5px;right:38px}.e-ddt.e-filled.e-float-input.e-control-wrapper.e-show-chip:not(.e-show-dd-icon) .e-clear-icon,.e-ddt.e-filled.e-float-input.e-control-wrapper.e-show-text:not(.e-show-dd-icon) .e-clear-icon{bottom:9px;right:10px}.e-ddt.e-filled.e-float-input.e-control-wrapper.e-show-chip .e-chips-wrapper,.e-ddt.e-filled.e-float-input.e-control-wrapper.e-show-chip .e-overflow{padding-top:8px}.e-ddt.e-filled.e-float-input.e-control-wrapper.e-show-chip .e-chips-wrapper .e-chips,.e-ddt.e-filled.e-float-input.e-control-wrapper.e-show-chip .e-overflow .e-chips{height:18px}.e-ddt.e-filled.e-float-input.e-control-wrapper.e-show-chip .e-chips-wrapper .e-chips>.e-chipcontent,.e-ddt.e-filled.e-float-input.e-control-wrapper.e-show-chip .e-overflow .e-chips>.e-chipcontent{font-size:12px;padding:0 4px 0 0}.e-ddt.e-filled.e-float-input.e-control-wrapper.e-show-chip .e-chips-wrapper .e-chips-close:before,.e-ddt.e-filled.e-float-input.e-control-wrapper.e-show-chip .e-overflow .e-chips-close:before{font-size:12px;height:12px;width:12px}.e-ddt.e-filled .e-chips-wrapper .e-chips,.e-ddt.e-filled .e-overflow .e-chips{margin-top:8px;padding:0 8px}.e-ddt.e-filled.e-input-group.e-control-wrapper:not(.e-float-input) .e-overflow.e-show-text{line-height:39px;padding:0}.e-ddt.e-filled.e-input-group.e-control-wrapper:not(.e-float-input) .e-overflow .e-remain.e-wrap-count{line-height:39px;padding-top:0}.e-ddt.e-filled.e-input-group.e-control-wrapper:not(.e-float-input).e-show-chip .e-chips-wrapper .e-chips,.e-ddt.e-filled.e-input-group.e-control-wrapper:not(.e-float-input).e-show-chip .e-overflow .e-chips{height:28px;margin-top:8px;padding:0 8px}.e-ddt.e-filled.e-input-group.e-control-wrapper:not(.e-float-input).e-show-chip .e-chips-wrapper .e-chips>.e-chipcontent,.e-ddt.e-filled.e-input-group.e-control-wrapper:not(.e-float-input).e-show-chip .e-overflow .e-chips>.e-chipcontent{font-size:13px;padding:0 8px 0 0}.e-ddt.e-filled.e-input-group.e-control-wrapper:not(.e-float-input).e-show-chip .e-chips-wrapper .e-chips-close:before,.e-ddt.e-filled.e-input-group.e-control-wrapper:not(.e-float-input).e-show-chip .e-overflow .e-chips-close:before{font-size:14px;height:12px;width:12px}.e-ddt.e-filled.e-input-group.e-control-wrapper:not(.e-float-input).e-show-dd-icon.e-show-text .e-ddt-icon,.e-ddt.e-filled.e-input-group.e-control-wrapper:not(.e-float-input).e-show-dd-icon.e-show-chip .e-ddt-icon{bottom:10px;right:10px}.e-ddt.e-filled.e-input-group.e-control-wrapper:not(.e-float-input) .e-clear-icon{bottom:9px;right:38px}.e-ddt.e-filled.e-input-group.e-control-wrapper:not(.e-float-input):not(.e-show-dd-icon) .e-clear-icon{bottom:9px;right:10px}.e-ddt .e-overflow{white-space:nowrap}.e-ddt .e-overflow.e-show-text{padding:6px 0 0}.e-ddt .e-overflow.e-total-count{box-sizing:border-box;display:inline-block;overflow:hidden;text-overflow:ellipsis}.e-ddt .e-overflow.e-total-count .e-remain{padding:0 16px 0 0}.e-ddt .e-overflow.e-wrap-count{padding-top:6px}.e-ddt .e-overflow .e-remain{cursor:pointer;display:inline-block;font-size:13px;padding:0 0 0 16px}.e-ddt .e-overflow .e-remain.e-wrap-count{padding-top:6px}.e-ddt.e-show-chip .e-overflow.e-total-count .e-remain{padding:6px 0 0}.e-ddt.e-show-dd-icon .e-chips-wrapper .e-chips:last-child{margin-right:18px;max-width:calc(100% - 19px)}.e-ddt.e-show-clear .e-chips-wrapper .e-chips:last-child{margin-right:26px;max-width:calc(100% - 27px)}.e-ddt.e-show-clear.e-show-dd-icon .e-chips-wrapper .e-chips:last-child{margin-right:45px;max-width:calc(100% - 45px)}.e-ddt input[readonly],.e-ddt .e-dropdowntree,.e-ddt input[readonly].e-input{pointer-events:none}.e-ddt input[readonly].e-chip-input,.e-ddt .e-dropdowntree.e-chip-input,.e-ddt input[readonly].e-input.e-chip-input{width:0;visibility:hidden}.e-ddt.e-popup{box-shadow:0 5px 5px -3px #0003,0 8px 10px #00000024,0 3px 14px #0000001f;position:absolute}.e-ddt.e-popup .e-selectall-parent{border-bottom:1px solid;cursor:pointer;display:block;line-height:36px;overflow:hidden;position:relative;text-indent:38px;white-space:nowrap;width:100%}.e-ddt.e-popup .e-selectall-parent.e-hide-selectall{display:none}.e-ddt.e-popup .e-selectall-parent .e-checkbox-wrapper{position:relative;text-indent:0}.e-ddt.e-popup .e-selectall-parent .e-all-text{font-family:inherit;font-size:14px;margin:10px}.e-ddt.e-popup .e-filter-wrap{border-top-width:0;display:block;padding:0;border:0}.e-ddt.e-popup .e-filter-wrap .e-input,.e-ddt.e-popup .e-filter-wrap .e-input:focus{padding:8px 16px}.e-ddt.e-popup .e-filter-wrap .e-input-group{margin-bottom:0}.e-ddt.e-popup .e-filter-wrap .e-input-group .e-clear-icon{margin:6px 6px 5px;min-height:12px;min-width:12px;padding:6px}.e-ddt.e-popup .e-filter-wrap .e-input-group:not(.e-disabled):not(.e-float-icon-left):before,.e-ddt.e-popup .e-filter-wrap .e-input-group:not(.e-disabled):not(.e-float-icon-left):after,.e-ddt.e-popup .e-filter-wrap .e-input-group.e-control-wrapper:not(.e-disabled):not(.e-float-icon-left):before,.e-ddt.e-popup .e-filter-wrap .e-input-group.e-control-wrapper:not(.e-disabled):not(.e-float-icon-left):after{bottom:-1px;height:1px}.e-ddt.e-popup .e-popup-content{overflow:auto;position:relative}.e-ddt.e-popup .e-popup-content .e-ddt-nodata{display:none}.e-ddt.e-popup .e-popup-content.e-no-data{cursor:default;font-family:inherit;font-size:14px;text-align:center;padding:14px 16px}.e-ddt.e-popup .e-popup-content.e-no-data .e-treeview{display:none}.e-ddt.e-popup .e-popup-content.e-no-data .e-ddt-nodata{display:block}.e-ddt.e-popup .e-treeview{display:inline-table;width:100%}.e-ddt.e-popup .e-treeview .e-list-item{padding:0}.e-ddt.e-popup .e-treeview .e-list-item .e-ul{margin:0;padding:0 0 0 14px}.e-ddt.e-popup .e-treeview .e-fullrow{height:36px}.e-ddt.e-popup .e-treeview>.e-ul{overflow:hidden;padding:0 8px}.e-ddt.e-popup .e-treeview.e-fullrow-wrap .e-text-content{padding-bottom:2px;padding-top:2px}.e-ddt.e-popup .e-ddt-footer,.e-ddt.e-popup .e-ddt-header{cursor:default}.e-ddt.e-rtl.e-show-chip .e-chips{float:right}.e-ddt.e-rtl.e-show-chip .e-overflow .e-remain,.e-ddt.e-rtl.e-show-text .e-overflow .e-remain{padding:0 16px 0 0}.e-ddt.e-rtl.e-show-chip .e-overflow .e-remain.e-wrap-count,.e-ddt.e-rtl.e-show-text .e-overflow .e-remain.e-wrap-count{padding-top:6px}.e-ddt.e-rtl.e-show-chip .e-overflow.e-wrap-count,.e-ddt.e-rtl.e-show-text .e-overflow.e-wrap-count{position:absolute;right:auto}.e-ddt.e-rtl.e-show-text .e-overflow.e-total-count .e-remain{padding:0 0 0 16px}.e-ddt.e-rtl.e-show-chip .e-overflow.e-total-count .e-remain{padding:6px 0 0}.e-ddt.e-rtl.e-outline.e-input-group.e-control-wrapper.e-show-dd-icon .e-clear-icon,.e-ddt.e-rtl.e-outline.e-input-group.e-control-wrapper.e-show-dd-icon.e-show-text .e-clear-icon,.e-ddt.e-rtl.e-outline.e-input-group.e-control-wrapper.e-show-dd-icon.e-show-chip .e-clear-icon,.e-ddt.e-rtl.e-outline.e-float-input.e-control-wrapper.e-show-dd-icon .e-clear-icon,.e-ddt.e-rtl.e-outline.e-float-input.e-control-wrapper.e-show-dd-icon.e-show-text .e-clear-icon,.e-ddt.e-rtl.e-outline.e-float-input.e-control-wrapper.e-show-dd-icon.e-show-chip .e-clear-icon{left:30px}.e-ddt.e-rtl.e-filled.e-float-input.e-control-wrapper .e-overflow.e-show-text{padding:14px 0 5px 2px}.e-ddt.e-rtl.e-filled.e-float-input.e-control-wrapper.e-show-chip .e-ddt-icon,.e-ddt.e-rtl.e-filled.e-float-input.e-control-wrapper.e-show-text .e-ddt-icon{left:10px;right:auto}.e-ddt.e-rtl.e-filled.e-float-input.e-control-wrapper.e-show-chip.e-show-dd-icon .e-clear-icon,.e-ddt.e-rtl.e-filled.e-float-input.e-control-wrapper.e-show-text.e-show-dd-icon .e-clear-icon{left:38px;right:auto}.e-ddt.e-rtl.e-filled.e-float-input.e-control-wrapper.e-show-chip:not(.e-show-dd-icon) .e-clear-icon,.e-ddt.e-rtl.e-filled.e-float-input.e-control-wrapper.e-show-text:not(.e-show-dd-icon) .e-clear-icon{left:10px;right:auto}.e-ddt.e-rtl.e-filled.e-float-input.e-control-wrapper.e-show-chip .e-chips-wrapper .e-chips>.e-chipcontent,.e-ddt.e-rtl.e-filled.e-float-input.e-control-wrapper.e-show-chip .e-overflow .e-chips>.e-chipcontent{padding:0 0 0 4px}.e-ddt.e-rtl.e-filled.e-input-group.e-control-wrapper:not(.e-float-input).e-show-chip .e-chips-wrapper .e-chips>.e-chipcontent,.e-ddt.e-rtl.e-filled.e-input-group.e-control-wrapper:not(.e-float-input).e-show-chip .e-overflow .e-chips>.e-chipcontent{padding:0 0 0 8px}.e-ddt.e-rtl.e-filled.e-input-group.e-control-wrapper:not(.e-float-input).e-show-dd-icon.e-show-text .e-ddt-icon,.e-ddt.e-rtl.e-filled.e-input-group.e-control-wrapper:not(.e-float-input).e-show-dd-icon.e-show-chip .e-ddt-icon{left:10px;right:auto}.e-ddt.e-rtl.e-filled.e-input-group.e-control-wrapper:not(.e-float-input).e-show-dd-icon .e-clear-icon{left:38px;right:auto}.e-ddt.e-rtl.e-filled.e-input-group.e-control-wrapper:not(.e-float-input):not(.e-show-dd-icon) .e-clear-icon{left:10px;right:auto}.e-ddt.e-rtl.e-show-dd-icon .e-chips-wrapper .e-chips:last-child{margin-right:1px;margin-left:18px}.e-ddt.e-rtl.e-show-clear .e-chips-wrapper .e-chips:last-child{margin-right:1px;margin-left:26px}.e-ddt.e-rtl.e-show-clear.e-show-dd-icon .e-chips-wrapper .e-chips:last-child{margin-right:1px;margin-left:45px}.e-ddt.e-rtl.e-input-group.e-control-wrapper.e-show-chip .e-clear-icon,.e-ddt.e-rtl.e-input-group.e-control-wrapper.e-show-chip .e-ddt-icon,.e-ddt.e-rtl.e-input-group.e-control-wrapper.e-show-text .e-clear-icon,.e-ddt.e-rtl.e-input-group.e-control-wrapper.e-show-text .e-ddt-icon,.e-ddt.e-rtl.e-float-input.e-control-wrapper.e-show-chip .e-clear-icon,.e-ddt.e-rtl.e-float-input.e-control-wrapper.e-show-chip .e-ddt-icon,.e-ddt.e-rtl.e-float-input.e-control-wrapper.e-show-text .e-clear-icon,.e-ddt.e-rtl.e-float-input.e-control-wrapper.e-show-text .e-ddt-icon{left:0;right:auto}.e-ddt.e-rtl.e-input-group.e-control-wrapper.e-show-chip.e-show-dd-icon .e-clear-icon,.e-ddt.e-rtl.e-input-group.e-control-wrapper.e-show-text.e-show-dd-icon .e-clear-icon,.e-ddt.e-rtl.e-float-input.e-control-wrapper.e-show-chip.e-show-dd-icon .e-clear-icon,.e-ddt.e-rtl.e-float-input.e-control-wrapper.e-show-text.e-show-dd-icon .e-clear-icon{left:18px}.e-ddt.e-rtl.e-popup .e-treeview .e-list-item .e-ul{padding:0 14px 0 0}.e-ddt-icon-hide{display:none}.e-ddt .e-chips{background-color:#eee}.e-ddt .e-chips .e-chips-close:before{color:#0000008a}.e-ddt .e-chips>.e-chipcontent{color:#000000de}.e-ddt.e-filled .e-chips{background-color:#cecece}.e-ddt .e-overflow .e-remain{color:#0000008a}.e-ddt.e-popup{background:#fff;border-color:transparent}.e-ddt.e-popup .e-popup-content.e-no-data{color:#000}.e-ddt.e-popup .e-selectall-parent{border-bottom-color:#0000001f}.e-ddt.e-popup .e-selectall-parent:focus{background:#f5f5f5}.e-ddt.e-popup .e-selectall-parent .e-all-text{color:#000000de}.e-bigger .e-ddt .e-chips,.e-ddt.e-bigger .e-chips{height:31px}.e-bigger .e-ddt.e-input-group.e-control-wrapper.e-show-chip.e-show-dd-icon .e-clear-icon,.e-bigger .e-ddt.e-input-group.e-control-wrapper.e-show-text.e-show-dd-icon .e-clear-icon,.e-bigger .e-ddt.e-float-input.e-control-wrapper.e-show-chip.e-show-dd-icon .e-clear-icon,.e-bigger .e-ddt.e-float-input.e-control-wrapper.e-show-text.e-show-dd-icon .e-clear-icon,.e-ddt.e-bigger.e-input-group.e-control-wrapper.e-show-chip.e-show-dd-icon .e-clear-icon,.e-ddt.e-bigger.e-input-group.e-control-wrapper.e-show-text.e-show-dd-icon .e-clear-icon,.e-ddt.e-bigger.e-float-input.e-control-wrapper.e-show-chip.e-show-dd-icon .e-clear-icon,.e-ddt.e-bigger.e-float-input.e-control-wrapper.e-show-text.e-show-dd-icon .e-clear-icon{right:20px}.e-bigger .e-ddt.e-input-group.e-control-wrapper.e-show-chip .e-ddt-icon,.e-bigger .e-ddt.e-input-group.e-control-wrapper.e-show-text .e-ddt-icon,.e-bigger .e-ddt.e-float-input.e-control-wrapper.e-show-chip .e-ddt-icon,.e-bigger .e-ddt.e-float-input.e-control-wrapper.e-show-text .e-ddt-icon,.e-ddt.e-bigger.e-input-group.e-control-wrapper.e-show-chip .e-ddt-icon,.e-ddt.e-bigger.e-input-group.e-control-wrapper.e-show-text .e-ddt-icon,.e-ddt.e-bigger.e-float-input.e-control-wrapper.e-show-chip .e-ddt-icon,.e-ddt.e-bigger.e-float-input.e-control-wrapper.e-show-text .e-ddt-icon{bottom:3px}.e-bigger .e-ddt.e-input-group.e-control-wrapper .e-clear-icon,.e-bigger .e-ddt.e-float-input.e-control-wrapper .e-clear-icon,.e-ddt.e-bigger.e-input-group.e-control-wrapper .e-clear-icon,.e-ddt.e-bigger.e-float-input.e-control-wrapper .e-clear-icon{min-height:26px}.e-bigger .e-ddt .e-overflow.e-show-text,.e-ddt.e-bigger .e-overflow.e-show-text{padding:8px 0 0}.e-bigger .e-ddt.e-outline .e-overflow.e-show-text,.e-bigger .e-ddt.e-outline .e-overflow.e-total-count,.e-ddt.e-bigger.e-outline .e-overflow.e-show-text,.e-ddt.e-bigger.e-outline .e-overflow.e-total-count{padding:15px 16px}.e-bigger .e-ddt.e-outline.e-input-group.e-control-wrapper.e-show-dd-icon .e-clear-icon,.e-bigger .e-ddt.e-outline.e-float-input.e-control-wrapper.e-show-dd-icon .e-clear-icon,.e-ddt.e-bigger.e-outline.e-input-group.e-control-wrapper.e-show-dd-icon .e-clear-icon,.e-ddt.e-bigger.e-outline.e-float-input.e-control-wrapper.e-show-dd-icon .e-clear-icon{right:36px}.e-bigger .e-ddt.e-outline.e-show-chip .e-overflow,.e-ddt.e-bigger.e-outline.e-show-chip .e-overflow{padding:8px 15px}.e-bigger .e-ddt.e-outline.e-show-chip .e-overflow.e-total-count .e-remain,.e-ddt.e-bigger.e-outline.e-show-chip .e-overflow.e-total-count .e-remain,.e-bigger .e-ddt.e-outline.e-show-chip .e-overflow .e-remain.e-wrap-count,.e-ddt.e-bigger.e-outline.e-show-chip .e-overflow .e-remain.e-wrap-count{padding-top:10px}.e-bigger .e-ddt.e-outline.e-show-chip .e-chips-wrapper,.e-ddt.e-bigger.e-outline.e-show-chip .e-chips-wrapper{padding:8px 15px}.e-bigger .e-ddt.e-filled.e-float-input.e-control-wrapper .e-overflow.e-show-text,.e-ddt.e-bigger.e-filled.e-float-input.e-control-wrapper .e-overflow.e-show-text{line-height:30px;padding:19px 12px 0 0}.e-bigger .e-ddt.e-filled.e-float-input.e-control-wrapper .e-overflow .e-remain.e-wrap-count,.e-ddt.e-bigger.e-filled.e-float-input.e-control-wrapper .e-overflow .e-remain.e-wrap-count{padding-top:14px}.e-bigger .e-ddt.e-filled.e-float-input.e-control-wrapper:not(.e-show-chip) .e-ddt-icon,.e-bigger .e-ddt.e-filled.e-float-input.e-control-wrapper:not(.e-show-chip).e-show-dd-icon .e-clear-icon,.e-ddt.e-bigger.e-filled.e-float-input.e-control-wrapper:not(.e-show-chip) .e-ddt-icon,.e-ddt.e-bigger.e-filled.e-float-input.e-control-wrapper:not(.e-show-chip).e-show-dd-icon .e-clear-icon{padding-top:8px}.e-bigger .e-ddt.e-filled.e-float-input.e-control-wrapper.e-show-chip .e-ddt-icon,.e-bigger .e-ddt.e-filled.e-float-input.e-control-wrapper.e-show-text .e-ddt-icon,.e-ddt.e-bigger.e-filled.e-float-input.e-control-wrapper.e-show-chip .e-ddt-icon,.e-ddt.e-bigger.e-filled.e-float-input.e-control-wrapper.e-show-text .e-ddt-icon{bottom:12px;right:12px}.e-bigger .e-ddt.e-filled.e-float-input.e-control-wrapper.e-show-chip .e-clear-icon,.e-bigger .e-ddt.e-filled.e-float-input.e-control-wrapper.e-show-text .e-clear-icon,.e-ddt.e-bigger.e-filled.e-float-input.e-control-wrapper.e-show-chip .e-clear-icon,.e-ddt.e-bigger.e-filled.e-float-input.e-control-wrapper.e-show-text .e-clear-icon{bottom:11px;right:44px}.e-bigger .e-ddt.e-filled.e-float-input.e-control-wrapper.e-show-chip:not(.e-show-dd-icon) .e-clear-icon,.e-bigger .e-ddt.e-filled.e-float-input.e-control-wrapper.e-show-text:not(.e-show-dd-icon) .e-clear-icon,.e-ddt.e-bigger.e-filled.e-float-input.e-control-wrapper.e-show-chip:not(.e-show-dd-icon) .e-clear-icon,.e-ddt.e-bigger.e-filled.e-float-input.e-control-wrapper.e-show-text:not(.e-show-dd-icon) .e-clear-icon{bottom:14px;right:12px}.e-bigger .e-ddt.e-filled .e-chips-wrapper .e-chips,.e-bigger .e-ddt.e-filled .e-overflow .e-chips,.e-ddt.e-bigger.e-filled .e-chips-wrapper .e-chips,.e-ddt.e-bigger.e-filled .e-overflow .e-chips{margin-top:8px;padding:0 8px}.e-bigger .e-ddt.e-filled.e-float-input.e-control-wrapper.e-show-chip .e-chips-wrapper,.e-bigger .e-ddt.e-filled.e-float-input.e-control-wrapper.e-show-chip .e-overflow,.e-ddt.e-bigger.e-filled.e-float-input.e-control-wrapper.e-show-chip .e-chips-wrapper,.e-ddt.e-bigger.e-filled.e-float-input.e-control-wrapper.e-show-chip .e-overflow{padding-top:19px}.e-bigger .e-ddt.e-filled.e-float-input.e-control-wrapper.e-show-chip .e-chips-wrapper .e-chips,.e-bigger .e-ddt.e-filled.e-float-input.e-control-wrapper.e-show-chip .e-overflow .e-chips,.e-ddt.e-bigger.e-filled.e-float-input.e-control-wrapper.e-show-chip .e-chips-wrapper .e-chips,.e-ddt.e-bigger.e-filled.e-float-input.e-control-wrapper.e-show-chip .e-overflow .e-chips{height:24px}.e-bigger .e-ddt.e-filled.e-float-input.e-control-wrapper.e-show-chip .e-chips-wrapper .e-chips>.e-chipcontent,.e-bigger .e-ddt.e-filled.e-float-input.e-control-wrapper.e-show-chip .e-overflow .e-chips>.e-chipcontent,.e-ddt.e-bigger.e-filled.e-float-input.e-control-wrapper.e-show-chip .e-chips-wrapper .e-chips>.e-chipcontent,.e-ddt.e-bigger.e-filled.e-float-input.e-control-wrapper.e-show-chip .e-overflow .e-chips>.e-chipcontent{font-size:13px}.e-bigger .e-ddt.e-filled.e-float-input.e-control-wrapper.e-show-chip .e-chips-wrapper .e-chips-close:before,.e-bigger .e-ddt.e-filled.e-float-input.e-control-wrapper.e-show-chip .e-overflow .e-chips-close:before,.e-ddt.e-bigger.e-filled.e-float-input.e-control-wrapper.e-show-chip .e-chips-wrapper .e-chips-close:before,.e-ddt.e-bigger.e-filled.e-float-input.e-control-wrapper.e-show-chip .e-overflow .e-chips-close:before{font-size:14px;height:14px;width:14px}.e-bigger .e-ddt.e-filled.e-input-group.e-control-wrapper:not(.e-float-input) .e-overflow.e-show-text,.e-ddt.e-bigger.e-filled.e-input-group.e-control-wrapper:not(.e-float-input) .e-overflow.e-show-text{line-height:55px}.e-bigger .e-ddt.e-filled.e-input-group.e-control-wrapper:not(.e-float-input) .e-overflow .e-remain.e-wrap-count,.e-ddt.e-bigger.e-filled.e-input-group.e-control-wrapper:not(.e-float-input) .e-overflow .e-remain.e-wrap-count{line-height:55px;padding-top:0}.e-bigger .e-ddt.e-filled.e-input-group.e-control-wrapper:not(.e-float-input).e-show-chip .e-chips-wrapper .e-chips,.e-bigger .e-ddt.e-filled.e-input-group.e-control-wrapper:not(.e-float-input).e-show-chip .e-overflow .e-chips,.e-ddt.e-bigger.e-filled.e-input-group.e-control-wrapper:not(.e-float-input).e-show-chip .e-chips-wrapper .e-chips,.e-ddt.e-bigger.e-filled.e-input-group.e-control-wrapper:not(.e-float-input).e-show-chip .e-overflow .e-chips{height:32px;padding:0 12px}.e-bigger .e-ddt.e-filled.e-input-group.e-control-wrapper:not(.e-float-input).e-show-chip .e-chips-wrapper .e-chips>.e-chipcontent,.e-bigger .e-ddt.e-filled.e-input-group.e-control-wrapper:not(.e-float-input).e-show-chip .e-overflow .e-chips>.e-chipcontent,.e-ddt.e-bigger.e-filled.e-input-group.e-control-wrapper:not(.e-float-input).e-show-chip .e-chips-wrapper .e-chips>.e-chipcontent,.e-ddt.e-bigger.e-filled.e-input-group.e-control-wrapper:not(.e-float-input).e-show-chip .e-overflow .e-chips>.e-chipcontent{font-size:14px}.e-bigger .e-ddt.e-filled.e-input-group.e-control-wrapper:not(.e-float-input).e-show-chip .e-chips-wrapper .e-chips-close:before,.e-bigger .e-ddt.e-filled.e-input-group.e-control-wrapper:not(.e-float-input).e-show-chip .e-overflow .e-chips-close:before,.e-ddt.e-bigger.e-filled.e-input-group.e-control-wrapper:not(.e-float-input).e-show-chip .e-chips-wrapper .e-chips-close:before,.e-ddt.e-bigger.e-filled.e-input-group.e-control-wrapper:not(.e-float-input).e-show-chip .e-overflow .e-chips-close:before{font-size:16px;height:16px;width:16px}.e-bigger .e-ddt.e-filled.e-input-group.e-control-wrapper:not(.e-float-input).e-show-dd-icon.e-show-text .e-ddt-icon,.e-bigger .e-ddt.e-filled.e-input-group.e-control-wrapper:not(.e-float-input).e-show-dd-icon.e-show-text:not(.e-show-dd-icon) .e-clear-icon,.e-bigger .e-ddt.e-filled.e-input-group.e-control-wrapper:not(.e-float-input).e-show-dd-icon.e-show-chip .e-ddt-icon,.e-bigger .e-ddt.e-filled.e-input-group.e-control-wrapper:not(.e-float-input).e-show-dd-icon.e-show-chip:not(.e-show-dd-icon) .e-clear-icon,.e-ddt.e-bigger.e-filled.e-input-group.e-control-wrapper:not(.e-float-input).e-show-dd-icon.e-show-text .e-ddt-icon,.e-ddt.e-bigger.e-filled.e-input-group.e-control-wrapper:not(.e-float-input).e-show-dd-icon.e-show-text:not(.e-show-dd-icon) .e-clear-icon,.e-ddt.e-bigger.e-filled.e-input-group.e-control-wrapper:not(.e-float-input).e-show-dd-icon.e-show-chip .e-ddt-icon,.e-ddt.e-bigger.e-filled.e-input-group.e-control-wrapper:not(.e-float-input).e-show-dd-icon.e-show-chip:not(.e-show-dd-icon) .e-clear-icon{bottom:16px;right:12px}.e-bigger .e-ddt.e-filled.e-input-group.e-control-wrapper:not(.e-float-input) .e-clear-icon,.e-ddt.e-bigger.e-filled.e-input-group.e-control-wrapper:not(.e-float-input) .e-clear-icon{bottom:15px;right:44px}.e-bigger .e-ddt.e-show-dd-icon .e-chips-wrapper .e-chips:last-child,.e-ddt.e-bigger.e-show-dd-icon .e-chips-wrapper .e-chips:last-child{margin-right:20px;max-width:calc(100% - 21px)}.e-bigger .e-ddt.e-show-clear .e-chips-wrapper .e-chips:last-child,.e-ddt.e-bigger.e-show-clear .e-chips-wrapper .e-chips:last-child{margin-right:32px;max-width:calc(100% - 33px)}.e-bigger .e-ddt.e-show-clear.e-show-dd-icon .e-chips-wrapper .e-chips:last-child,.e-ddt.e-bigger.e-show-clear.e-show-dd-icon .e-chips-wrapper .e-chips:last-child{margin-right:52px;max-width:calc(100% - 53px)}.e-bigger .e-ddt.e-popup .e-selectall-parent,.e-ddt.e-bigger.e-popup .e-selectall-parent{text-indent:43px}.e-bigger .e-ddt.e-popup .e-treeview .e-fullrow,.e-ddt.e-bigger.e-popup .e-treeview .e-fullrow{height:44px}.e-bigger .e-ddt.e-rtl.e-outline.e-input-group.e-control-wrapper.e-show-dd-icon .e-clear-icon,.e-bigger .e-ddt.e-rtl.e-outline.e-input-group.e-control-wrapper.e-show-dd-icon.e-show-text .e-clear-icon,.e-bigger .e-ddt.e-rtl.e-outline.e-input-group.e-control-wrapper.e-show-dd-icon.e-show-chip .e-clear-icon,.e-bigger .e-ddt.e-rtl.e-outline.e-float-input.e-control-wrapper.e-show-dd-icon .e-clear-icon,.e-bigger .e-ddt.e-rtl.e-outline.e-float-input.e-control-wrapper.e-show-dd-icon.e-show-text .e-clear-icon,.e-bigger .e-ddt.e-rtl.e-outline.e-float-input.e-control-wrapper.e-show-dd-icon.e-show-chip .e-clear-icon,.e-ddt.e-bigger.e-rtl.e-outline.e-input-group.e-control-wrapper.e-show-dd-icon .e-clear-icon,.e-ddt.e-bigger.e-rtl.e-outline.e-input-group.e-control-wrapper.e-show-dd-icon.e-show-text .e-clear-icon,.e-ddt.e-bigger.e-rtl.e-outline.e-input-group.e-control-wrapper.e-show-dd-icon.e-show-chip .e-clear-icon,.e-ddt.e-bigger.e-rtl.e-outline.e-float-input.e-control-wrapper.e-show-dd-icon .e-clear-icon,.e-ddt.e-bigger.e-rtl.e-outline.e-float-input.e-control-wrapper.e-show-dd-icon.e-show-text .e-clear-icon,.e-ddt.e-bigger.e-rtl.e-outline.e-float-input.e-control-wrapper.e-show-dd-icon.e-show-chip .e-clear-icon{left:36px}.e-bigger .e-ddt.e-rtl.e-filled.e-float-input.e-control-wrapper .e-overflow.e-show-text,.e-ddt.e-bigger.e-rtl.e-filled.e-float-input.e-control-wrapper .e-overflow.e-show-text{padding:19px 0 0 12px}.e-bigger .e-ddt.e-rtl.e-filled.e-float-input.e-control-wrapper.e-show-chip .e-ddt-icon,.e-bigger .e-ddt.e-rtl.e-filled.e-float-input.e-control-wrapper.e-show-chip:not(.e-show-dd-icon) .e-clear-icon,.e-bigger .e-ddt.e-rtl.e-filled.e-float-input.e-control-wrapper.e-show-text .e-ddt-icon,.e-bigger .e-ddt.e-rtl.e-filled.e-float-input.e-control-wrapper.e-show-text:not(.e-show-dd-icon) .e-clear-icon,.e-ddt.e-bigger.e-rtl.e-filled.e-float-input.e-control-wrapper.e-show-chip .e-ddt-icon,.e-ddt.e-bigger.e-rtl.e-filled.e-float-input.e-control-wrapper.e-show-chip:not(.e-show-dd-icon) .e-clear-icon,.e-ddt.e-bigger.e-rtl.e-filled.e-float-input.e-control-wrapper.e-show-text .e-ddt-icon,.e-ddt.e-bigger.e-rtl.e-filled.e-float-input.e-control-wrapper.e-show-text:not(.e-show-dd-icon) .e-clear-icon{left:12px;right:auto}.e-bigger .e-ddt.e-rtl.e-filled.e-float-input.e-control-wrapper.e-show-chip.e-show-dd-icon .e-clear-icon,.e-bigger .e-ddt.e-rtl.e-filled.e-float-input.e-control-wrapper.e-show-text.e-show-dd-icon .e-clear-icon,.e-ddt.e-bigger.e-rtl.e-filled.e-float-input.e-control-wrapper.e-show-chip.e-show-dd-icon .e-clear-icon,.e-ddt.e-bigger.e-rtl.e-filled.e-float-input.e-control-wrapper.e-show-text.e-show-dd-icon .e-clear-icon{left:44px;right:auto}.e-bigger .e-ddt.e-rtl.e-filled.e-input-group.e-control-wrapper:not(.e-float-input).e-show-dd-icon:not(.e-input-focus) .e-ddt-icon,.e-bigger .e-ddt.e-rtl.e-filled.e-input-group.e-control-wrapper:not(.e-float-input).e-show-dd-icon:not(.e-input-focus):not(.e-show-dd-icon) .e-clear-icon,.e-bigger .e-ddt.e-rtl.e-filled.e-input-group.e-control-wrapper:not(.e-float-input).e-show-dd-icon.e-show-chip .e-ddt-icon,.e-bigger .e-ddt.e-rtl.e-filled.e-input-group.e-control-wrapper:not(.e-float-input).e-show-dd-icon.e-show-chip:not(.e-show-dd-icon) .e-clear-icon,.e-ddt.e-bigger.e-rtl.e-filled.e-input-group.e-control-wrapper:not(.e-float-input).e-show-dd-icon:not(.e-input-focus) .e-ddt-icon,.e-ddt.e-bigger.e-rtl.e-filled.e-input-group.e-control-wrapper:not(.e-float-input).e-show-dd-icon:not(.e-input-focus):not(.e-show-dd-icon) .e-clear-icon,.e-ddt.e-bigger.e-rtl.e-filled.e-input-group.e-control-wrapper:not(.e-float-input).e-show-dd-icon.e-show-chip .e-ddt-icon,.e-ddt.e-bigger.e-rtl.e-filled.e-input-group.e-control-wrapper:not(.e-float-input).e-show-dd-icon.e-show-chip:not(.e-show-dd-icon) .e-clear-icon{left:12px;right:auto}.e-bigger .e-ddt.e-rtl.e-filled.e-input-group.e-control-wrapper:not(.e-float-input) .e-clear-icon,.e-ddt.e-bigger.e-rtl.e-filled.e-input-group.e-control-wrapper:not(.e-float-input) .e-clear-icon{left:44px;right:auto}.e-bigger .e-ddt.e-rtl.e-show-dd-icon .e-chips-wrapper .e-chips:last-child,.e-ddt.e-bigger.e-rtl.e-show-dd-icon .e-chips-wrapper .e-chips:last-child{margin-right:1px;margin-left:20px}.e-bigger .e-ddt.e-rtl.e-show-clear .e-chips-wrapper .e-chips:last-child,.e-ddt.e-bigger.e-rtl.e-show-clear .e-chips-wrapper .e-chips:last-child{margin-right:1px;margin-left:32px}.e-bigger .e-ddt.e-rtl.e-show-clear.e-show-dd-icon .e-chips-wrapper .e-chips:last-child,.e-ddt.e-bigger.e-rtl.e-show-clear.e-show-dd-icon .e-chips-wrapper .e-chips:last-child{margin-right:52px;margin-left:1px}.e-bigger .e-ddt.e-rtl.e-show-chip.e-input-group.e-show-dd-icon .e-clear-icon,.e-bigger .e-ddt.e-rtl.e-show-text.e-input-group.e-show-dd-icon .e-clear-icon,.e-ddt.e-bigger.e-rtl.e-show-chip.e-input-group.e-show-dd-icon .e-clear-icon,.e-ddt.e-bigger.e-rtl.e-show-text.e-input-group.e-show-dd-icon .e-clear-icon{left:20px;right:auto}.e-multiselect.e-input-group.e-checkbox .e-multi-select-wrapper input[type=text]{padding:1px 0}.e-small .e-multiselect.e-input-group.e-checkbox .e-multi-select-wrapper input[type=text],.e-small.e-multiselect.e-input-group.e-checkbox .e-multi-select-wrapper input[type=text]{padding:0}.e-multiselect.e-input-group .e-multi-select-wrapper .e-multiselect-box input[type=text],.e-multiselect.e-input-group.e-input-focus .e-multi-select-wrapper .e-searcher:not(.e-zero-size) input[type=text]{padding:0}.e-multiselect.e-input-group .e-ddl-icon:before{content:"\e969";font-family:e-icons}.e-multi-select-wrapper .e-chips .e-chips-close:before{content:"\e7e9";cursor:pointer;left:0;position:relative;top:0}.e-multi-select-wrapper .e-close-hooker:before{content:"\e7a7";cursor:pointer;left:6px;position:relative;top:6px}.e-multiselect.e-input-group .e-ddl-disable-icon:before{content:""}.e-multiselect.e-outline .e-multi-select-wrapper .e-chips-close.e-close-hooker{height:38px;margin-top:-38px;right:18px;top:100%;width:32px}.e-multiselect.e-filled .e-multi-select-wrapper .e-chips-close.e-close-hooker{height:38px;margin-top:-35px;right:18px;top:100%;width:32px}.e-multiselect.e-outline .e-multi-select-wrapper.e-down-icon .e-chips-close.e-close-hooker,.e-multiselect.e-filled .e-multi-select-wrapper.e-down-icon .e-chips-close.e-close-hooker{right:30px}.e-small.e-multiselect.e-outline .e-multi-select-wrapper .e-chips-close.e-close-hooker,.e-small .e-multiselect.e-outline .e-multi-select-wrapper .e-chips-close.e-close-hooker{height:34px;margin-top:-35px;right:16px;top:100%;width:14px}.e-small.e-multiselect.e-outline .e-multi-select-wrapper.e-down-icon .e-chips-close.e-close-hooker,.e-small .e-multiselect.e-outline .e-multi-select-wrapper.e-down-icon .e-chips-close.e-close-hooker,.e-small.e-multiselect.e-filled .e-multi-select-wrapper.e-down-icon .e-chips-close.e-close-hooker,.e-small .e-multiselect.e-filled .e-multi-select-wrapper.e-down-icon .e-chips-close.e-close-hooker{right:48px}.e-rtl.e-multiselect.e-outline .e-multi-select-wrapper .e-chips-close.e-close-hooker,.e-rtl .e-multiselect.e-outline .e-multi-select-wrapper .e-chips-close.e-close-hooker,.e-rtl.e-multiselect.e-filled .e-multi-select-wrapper.e-down-icon .e-chips-close.e-close-hooker,.e-rtl .e-multiselect.e-filled .e-multi-select-wrapper.e-down-icon .e-chips-close.e-close-hooker{left:52px;right:auto}.e-rtl.e-small.e-multiselect.e-outline .e-multi-select-wrapper .e-chips-close.e-close-hooker,.e-rtl.e-small .e-multiselect.e-outline .e-multi-select-wrapper .e-chips-close.e-close-hooker,.e-rtl .e-small.e-multiselect.e-outline .e-multi-select-wrapper .e-chips-close.e-close-hooker,.e-rtl .e-small .e-multiselect.e-outline .e-multi-select-wrapper .e-chips-close.e-close-hooker,.e-small .e-rtl.e-multiselect.e-outline .e-multi-select-wrapper .e-chips-close.e-close-hooker,.e-small .e-rtl .e-multiselect.e-outline .e-multi-select-wrapper.e-down-icon .e-chips-close.e-close-hooker,.e-rtl.e-small.e-multiselect.e-filled .e-multi-select-wrapper.e-down-icon .e-chips-close.e-close-hooker,.e-rtl.e-small .e-multiselect.e-filled .e-multi-select-wrapper.e-down-icon .e-chips-close.e-close-hooker,.e-rtl .e-small.e-multiselect.e-filled .e-multi-select-wrapper.e-down-icon .e-chips-close.e-close-hooker,.e-rtl .e-small .e-multiselect.e-filled .e-multi-select-wrapper.e-down-icon .e-chips-close.e-close-hooker,.e-small .e-rtl.e-multiselect.e-filled .e-multi-select-wrapper.e-down-icon .e-chips-close.e-close-hooker,.e-small .e-rtl .e-multiselect.e-filled .e-multi-select-wrapper.e-down-icon .e-chips-close.e-close-hooker{left:48px;right:auto}.e-multiselect.e-outline .e-multi-select-wrapper .e-close-hooker:before{content:"\e208";font-size:16px;height:16px;margin-top:-8px;top:50%}.e-small.e-multiselect.e-outline .e-multi-select-wrapper .e-close-hooker:before,.e-small .e-multiselect.e-outline .e-multi-select-wrapper .e-close-hooker:before{content:"\e208";font-size:14px;height:14px;margin-top:-7px;top:50%}.e-multiselect.e-outline .e-multi-select-wrapper .e-chips .e-chips-close:before{font-size:14px}.e-small .e-multiselect.e-outline .e-multi-select-wrapper .e-chips .e-chips-close:before,.e-small.e-multiselect.e-outline .e-multi-select-wrapper .e-chips .e-chips-close:before{font-size:13px}.e-multiselect.e-input-group.e-outline .e-multi-select-wrapper .e-input-group-icon.e-ddl-icon,.e-multiselect.e-outline.e-input-group.e-control-wrapper .e-multi-select-wrapper .e-input-group-icon.e-ddl-icon{margin:7px 12px 9px 0}.e-multiselect.e-input-group.e-outline.e-small .e-multi-select-wrapper .e-input-group-icon.e-ddl-icon,.e-multiselect.e-input-group.e-outline.e-control-wrapper.e-small .e-multi-select-wrapper .e-input-group-icon.e-ddl-icon,.e-small .e-multiselect.e-input-group.e-outline .e-multi-select-wrapper .e-input-group-icon.e-ddl-icon,.e-small .e-multiselect.e-input-group.e-outline.e-control-wrapper .e-multi-select-wrapper .e-input-group-icon.e-ddl-icon{margin:6px 10px 8px 0}.e-rtl.e-multiselect.e-input-group.e-outline .e-multi-select-wrapper .e-input-group-icon.e-ddl-icon,.e-rtl.e-multiselect.e-outline.e-input-group.e-control-wrapper .e-multi-select-wrapper .e-input-group-icon.e-ddl-icon,.e-rtl .e-multiselect.e-input-group.e-outline .e-multi-select-wrapper .e-input-group-icon.e-ddl-icon,.e-rtl .e-multiselect.e-outline.e-input-group.e-control-wrapper .e-multi-select-wrapper .e-input-group-icon.e-ddl-icon{margin:7px 0 9px 12px}.e-rtl.e-multiselect.e-input-group.e-outline.e-small .e-multi-select-wrapper .e-input-group-icon.e-ddl-icon,.e-rtl.e-multiselect.e-input-group.e-outline.e-control-wrapper.e-small .e-multi-select-wrapper .e-input-group-icon.e-ddl-icon,.e-small .e-rtl.e-multiselect.e-input-group.e-outline .e-multi-select-wrapper .e-input-group-icon.e-ddl-icon,.e-small .e-rtl.e-multiselect.e-input-group.e-outline.e-control-wrapper .e-multi-select-wrapper .e-input-group-icon.e-ddl-icon,.e-rtl .e-multiselect.e-input-group.e-outline.e-small .e-multi-select-wrapper .e-input-group-icon.e-ddl-icon,.e-rtl .e-multiselect.e-input-group.e-outline.e-control-wrapper.e-small .e-multi-select-wrapper .e-input-group-icon.e-ddl-icon,.e-rtl.e-small .e-multiselect.e-input-group.e-outline .e-multi-select-wrapper .e-input-group-icon.e-ddl-icon,.e-rtl.e-small .e-multiselect.e-input-group.e-outline.e-control-wrapper .e-multi-select-wrapper .e-input-group-icon.e-ddl-icon{margin:6px 0 8px 10px}.e-filled .e-multi-select-wrapper .e-chips-close.e-close-hooker,.e-filled.e-multiselect .e-down-icon .e-chips-close.e-close-hooker{height:20px;margin-top:-33px;right:18px;width:20px}.e-filled.e-float-input .e-multi-select-wrapper .e-chips-close.e-close-hooker,.e-filled.e-float-input.e-multiselect .e-down-icon .e-chips-close.e-close-hooker{margin-top:-32px}.e-small.e-filled .e-multi-select-wrapper .e-chips-close.e-close-hooker,.e-small .e-filled .e-multi-select-wrapper .e-chips-close.e-close-hooker{height:18px;margin:-29px 0 8px;width:18px}.e-small.e-filled.e-float-input .e-multi-select-wrapper .e-chips-close.e-close-hooker,.e-small .e-filled.e-float-input.e-multiselect .e-down-icon .e-chips-close.e-close-hooker{margin-top:-26px}.e-filled.e-multiselect:not(.e-float-input) .e-multi-select-wrapper .e-chips:not(.e-mob-chip) .e-chips-close{height:14px;width:14px}.e-small.e-filled.e-multiselect.e-float-input .e-multi-select-wrapper .e-chips:not(.e-mob-chip) .e-chips-close,.e-small .e-filled.e-multiselect.e-float-input .e-multi-select-wrapper .e-chips:not(.e-mob-chip) .e-chips-close{height:10px;width:10px}.e-multiselect.e-filled.e-float-input .e-multi-select-wrapper .e-chips .e-chips-close:before,.e-small.e-filled.e-multiselect:not(.e-float-input) .e-multi-select-wrapper .e-chips .e-chips-close:before,.e-small .e-filled.e-multiselect:not(.e-float-input) .e-multi-select-wrapper .e-chips .e-chips-close:before{font-size:12px;height:12px;width:12px}.e-small.e-multiselect.e-filled.e-float-input .e-multi-select-wrapper .e-chips .e-chips-close:before,.e-small .e-multiselect.e-filled.e-float-input .e-multi-select-wrapper .e-chips .e-chips-close:before{font-size:10px;height:10px;width:10px}.e-multiselect.e-filled:not(.e-float-input) .e-multi-select-wrapper .e-chips .e-chips-close:before{font-size:14px;height:14px;width:14px}.e-filled .e-multi-select-wrapper .e-chips-close.e-close-hooker:before{content:"\e208";font-size:16px;height:16px;padding:0;text-align:center;vertical-align:middle;width:16px}.e-small.e-filled .e-multi-select-wrapper .e-chips-close.e-close-hooker:before,.e-small .e-filled .e-multi-select-wrapper .e-chips-close.e-close-hooker:before{font-size:14px;height:14px;width:14px}.e-rtl.e-multiselect.e-filled .e-multi-select-wrapper .e-chips-close.e-close-hooker,.e-rtl .e-multiselect.e-filled .e-multi-select-wrapper .e-chips-close.e-close-hooker{left:10px;right:auto}.e-small.e-rtl.e-multiselect.e-filled .e-multi-select-wrapper .e-chips-close.e-close-hooker,.e-rtl .e-small.e-multiselect.e-filled .e-multi-select-wrapper .e-chips-close.e-close-hooker,.e-small .e-rtl.e-multiselect.e-filled .e-multi-select-wrapper .e-chips-close.e-close-hooker,.e-rtl.e-small .e-multiselect.e-filled .e-multi-select-wrapper .e-chips-close.e-close-hooker{left:6px;right:auto}.e-multiselect.e-input-group.e-filled .e-multi-select-wrapper .e-input-group-icon.e-ddl-icon,.e-multiselect.e-filled.e-input-group.e-control-wrapper .e-multi-select-wrapper .e-input-group-icon.e-ddl-icon{margin:10px 0 9px}.e-multiselect.e-filled.e-input-group.e-float-input.e-control-wrapper .e-multi-select-wrapper .e-input-group-icon.e-ddl-icon{margin:0 8px 8px 0;padding:0}.e-small.e-multiselect.e-input-group.e-filled .e-multi-select-wrapper .e-input-group-icon.e-ddl-icon,.e-small .e-multiselect.e-filled.e-input-group.e-control-wrapper .e-multi-select-wrapper .e-input-group-icon.e-ddl-icon{height:18px;margin:7px 0 2px;width:18px}.e-small.e-multiselect.e-input-group.e-float-input.e-filled .e-multi-select-wrapper .e-input-group-icon.e-ddl-icon,.e-small .e-multiselect.e-filled.e-input-group.e-float-input.e-control-wrapper .e-multi-select-wrapper .e-input-group-icon.e-ddl-icon{margin:0 12px 4px 0}.e-multiselect.e-input-group.e-filled .e-multi-select-wrapper .e-input-group-icon.e-ddl-icon:before,.e-multiselect.e-filled.e-input-group.e-control-wrapper .e-multi-select-wrapper .e-input-group-icon.e-ddl-icon:before{font-size:16px;height:16px;width:16px}.e-small.e-multiselect.e-input-group.e-filled .e-multi-select-wrapper .e-input-group-icon.e-ddl-icon:before,.e-small .e-multiselect.e-filled.e-input-group.e-control-wrapper .e-multi-select-wrapper .e-input-group-icon.e-ddl-icon:before{font-size:14px;height:14px;width:14px}.e-multiselect.e-outline .e-multi-select-wrapper .e-close-hooker.e-ddl-disable-icon:before,.e-small.e-multiselect.e-outline .e-multi-select-wrapper .e-close-hooker.e-ddl-disable-icon:before,.e-small .e-multiselect.e-outline .e-multi-select-wrapper .e-close-hooker.e-ddl-disable-icon:before{content:""}.e-multi-select-wrapper{box-sizing:border-box;cursor:text;line-height:normal;min-height:30px;padding:0 32px 0 0;position:relative;-webkit-user-select:none;user-select:none;width:100%}.e-multi-select-wrapper.e-delimiter .e-searcher,.e-multi-select-wrapper.e-delimiter .e-multi-searcher{height:27px;vertical-align:middle}.e-multi-select-wrapper.e-delimiter .e-searcher .e-dropdownbase,.e-multi-select-wrapper.e-delimiter .e-multi-searcher .e-dropdownbase{height:100%;min-height:100%}.e-multi-select-wrapper .e-delim-view{white-space:nowrap}.e-multi-select-wrapper .e-delim-view.e-delim-values.e-delim-overflow,.e-multi-select-wrapper .e-delim-view.e-delim-values.e-delim-total{box-sizing:border-box;display:inline-block;overflow:hidden;text-overflow:ellipsis}.e-multi-select-wrapper .e-chips.e-mob-chip.e-chip-selected .e-chips-close:before{color:#fff;font-size:16px;left:12px;top:0}.e-multi-select-wrapper .e-chips.e-mob-chip.e-chip-selected .e-chipcontent{background-color:#3f51b5;color:#fff;padding:12px 4px 11px 0}.e-multi-select-wrapper .e-searcher.e-zero-size:not(.e-multiselect-box),.e-multi-select-wrapper .e-multi-searcher.e-zero-size:not(.e-multiselect-box){width:0}.e-multi-select-wrapper .e-searcher.e-zero-size:not(.e-multiselect-box) input[type=text],.e-multi-select-wrapper .e-multi-searcher.e-zero-size:not(.e-multiselect-box) input[type=text]{height:1px;min-height:1px}.e-multi-select-wrapper .e-chips.e-mob-chip>.e-chipcontent{max-width:100%}.e-multiselect.e-control-container .e-multi-select-wrapper .e-multi-searcher,.e-multiselect.e-control-container.e-input-group .e-multi-select-wrapper .e-multi-searcher{display:flex;float:left;width:auto}.e-multiselect.e-control-container .e-multi-select-wrapper.e-delimiter .e-multi-searcher,.e-multiselect.e-control-container.e-input-group .e-multi-select-wrapper.e-delimiter .e-multi-searcher{display:inline-flex;float:none}.e-multiselect.e-control-container .e-multi-select-wrapper .e-multi-searcher.e-zero-size:not(.e-multiselect-box),.e-multiselect.e-control-container.e-input-group .e-multi-select-wrapper .e-multi-searcher.e-zero-size:not(.e-multiselect-box){width:0}.e-multiselect.e-control-container .e-multi-select-wrapper .e-delim-values.e-delim-hide,.e-multiselect.e-control-container .e-multi-select-wrapper .e-delim-view.e-delim-values.e-delim-hide,.e-multiselect.e-control-container .e-multi-select-wrapper .e-chips-collection.e-delim-hide,.e-multiselect.e-control-container.e-input-group .e-multi-select-wrapper .e-delim-values.e-delim-hide,.e-multiselect.e-control-container.e-input-group .e-multi-select-wrapper .e-delim-view.e-delim-values.e-delim-hide,.e-multiselect.e-control-container.e-input-group .e-multi-select-wrapper .e-chips-collection.e-delim-hide{display:none}.e-multiselect.e-control-container .e-multi-select-wrapper.e-down-icon,.e-multiselect.e-control-container.e-input-group .e-multi-select-wrapper.e-down-icon{padding:0 48px 0 0}.e-multiselect.e-control-container .e-multi-select-wrapper .e-delim-values,.e-multiselect.e-control-container.e-input-group .e-multi-select-wrapper .e-delim-values{align-items:center;display:inline;max-width:100%;word-break:break-word}.e-multiselect.e-control-container .e-multi-select-wrapper .e-clear-icon,.e-multiselect.e-control-container .e-multi-select-wrapper .e-ddl-icon,.e-multiselect.e-control-container.e-input-group .e-multi-select-wrapper .e-clear-icon,.e-multiselect.e-control-container.e-input-group .e-multi-select-wrapper .e-ddl-icon{align-items:center;cursor:pointer;display:none;flex-direction:row;margin-top:-2.5em;outline:0;padding:0;position:absolute;right:5px;top:100%}.e-multiselect.e-control-container :not(.e-disabled).e-multi-select-wrapper:hover .e-clear-icon,.e-multiselect.e-control-container .e-multi-select-wrapper .e-ddl-icon,.e-multiselect.e-control-container.e-input-group :not(.e-disabled).e-multi-select-wrapper:hover .e-clear-icon,.e-multiselect.e-control-container.e-input-group .e-multi-select-wrapper .e-ddl-icon{display:flex}.e-multiselect.e-control-container .e-multi-select-wrapper .e-ddl-icon,.e-multiselect.e-control-container.e-input-group .e-multi-select-wrapper .e-ddl-icon{margin-right:0;margin-top:-2.1em;right:0}.e-multiselect.e-control-container .e-multi-select-wrapper.e-delimiter,.e-multiselect.e-control-container.e-input-group .e-multi-select-wrapper.e-delimiter{top:-1px}.e-multiselect.e-control-container .e-multi-select-wrapper .e-clear-icon,.e-multiselect.e-control-container.e-input-group .e-multi-select-wrapper .e-clear-icon{font-size:10px;height:24px;width:24px}.e-multiselect.e-control-container.e-rtl .e-multi-select-wrapper .e-multi-searcher,.e-multiselect.e-control-container.e-input-group.e-rtl .e-multi-select-wrapper .e-multi-searcher{float:right}.e-multiselect.e-control-container.e-rtl .e-multi-select-wrapper .e-clear-icon,.e-multiselect.e-control-container.e-rtl .e-multi-select-wrapper .e-ddl-icon,.e-multiselect.e-control-container.e-input-group.e-rtl .e-multi-select-wrapper .e-clear-icon,.e-multiselect.e-control-container.e-input-group.e-rtl .e-multi-select-wrapper .e-ddl-icon{left:0;right:auto}.e-multiselect.e-control-container.e-rtl .e-multi-select-wrapper.e-down-icon,.e-multiselect.e-control-container.e-input-group.e-rtl .e-multi-select-wrapper.e-down-icon{padding:0 0 0 48px}.e-popup.e-multi-select-list-wrapper .e-list-item.e-disabled,.e-popup.e-multi-select-list-wrapper.e-multiselect-group.e-checkbox .e-list-group-item.e-disabled{opacity:.7;pointer-events:none}.e-multiselect.e-input-group,.e-multiselect.e-float-input{word-wrap:initial}.e-multiselect.e-input-group .e-searcher .e-label-top,.e-multiselect.e-input-group .e-multi-searcher .e-label-top{top:15px}.e-multi-select-wrapper.e-close-icon-hide{padding-right:0}.e-multi-select-wrapper .e-chips-collection{cursor:default;display:block}.e-multiselect.e-input-group.e-control-wrapper:not(.e-control-container) .e-multi-select-wrapper.e-down-icon .e-chips-collection{margin-right:30px}.e-multi-select-wrapper .e-multi-hidden{border:0;height:0;position:absolute;visibility:hidden;width:0}.e-multi-select-wrapper .e-chips{align-items:center;display:inline-flex;float:left;margin:0 8px 6px 0;max-width:100%;overflow:hidden;padding:0 4px 0 8px;text-overflow:ellipsis;white-space:nowrap}.e-multi-select-wrapper .e-chips>.e-chipcontent{max-width:100%;overflow:hidden;padding:0 4px 0 0;text-indent:0;text-overflow:ellipsis;white-space:nowrap}.e-multi-select-wrapper.e-delimiter .e-searcher{display:inline-block;float:none}.e-multi-select-wrapper .e-mob-chip.e-chips>.e-chipcontent{padding:8px 4px 8px 0}.e-multiselect.e-rtl .e-multi-select-wrapper .e-mob-chip.e-chips>.e-chipcontent{padding:8px 0 8px 4px}.e-multi-select-wrapper .e-chips-close{align-self:center;display:flex;float:right;font-family:e-icons;height:16px;margin:0;width:16px}.e-rtl .e-multi-select-wrapper .e-chips-close{margin:0}.e-multi-select-wrapper .e-mob-chip.e-chips .e-chips-close{margin:3px 0 0}.e-multi-select-wrapper .e-chips-close.e-close-hooker{cursor:default;font-size:10px;height:24px;margin-top:-2.5em;position:absolute;right:5px;width:24px;top:100%}.e-multiselect .e-down-icon .e-chips-close.e-close-hooker,.e-small.e-multiselect .e-down-icon .e-chips-close.e-close-hooker,.e-multiselect.e-input-group.e-control-container .e-multi-select-wrapper.e-down-icon .e-clear-icon{right:22px}.e-multiselect.e-input-group.e-control-container.e-rtl .e-multi-select-wrapper.e-down-icon .e-clear-icon{left:22px;right:auto}.e-multi-select-wrapper input[type=text]{background:none;border:0;font-family:inherit;font-size:13px;font-weight:400;height:28px;min-height:28px;outline:none;padding:4px 0;text-indent:0}.e-multiselect.e-filled .e-multi-select-wrapper input[type=text]{background:none;border:0;color:inherit;font-family:inherit;font-size:14px;font-weight:400;height:28px;min-height:28px;outline:none;padding:0;text-indent:0}.e-rtl.e-multiselect.e-filled .e-multi-select-wrapper input[type=text]{padding:5px}.e-multi-select-wrapper input[type=text]::-ms-clear{display:none}.e-multi-select-wrapper .e-searcher{display:block;float:left;width:auto}.e-multiselect .e-multi-select-wrapper.e-down-icon .e-searcher.e-search-custom-width{width:calc(100% - 32px)}.e-small .e-multiselect .e-multi-select-wrapper.e-down-icon .e-searcher.e-search-custom-width,.e-small.e-multiselect .e-multi-select-wrapper.e-down-icon .e-searcher.e-search-custom-width{width:calc(100% - 30px)}.e-multiselect.e-outline .e-multi-select-wrapper.e-down-icon .e-searcher.e-search-custom-width{width:calc(100% - 32px)}.e-small.e-multiselect.e-outline .e-multi-select-wrapper.e-down-icon .e-searcher.e-search-custom-width,.e-small .e-multiselect.e-outline .e-multi-select-wrapper.e-down-icon .e-searcher.e-search-custom-width{width:calc(100% - 30px)}.e-multi-select-wrapper .e-delim-values{font-family:inherit;font-size:14px;line-height:28px;max-width:100%;padding-left:0;padding-right:6px;vertical-align:middle}.e-multi-select-list-wrapper .e-hide-listitem,.e-multi-select-list-wrapper .e-hide-group-header{display:none}.e-multi-select-wrapper .e-delim-values .e-remain{color:#0000008a;cursor:pointer;display:inline-block;font-size:13px;padding-left:16px}.e-multiselect.e-disabled .e-multi-select-wrapper,.e-multiselect.e-disabled .e-multi-select-wrapper .e-chips .e-chips-close:before{cursor:not-allowed}.e-multi-select-wrapper .e-chips.e-mob-chip.e-chip-selected .e-chips-close{height:40px;left:0;margin:0 0 0 auto;position:relative;top:0;width:40px}.e-multi-select-wrapper .e-chips.e-mob-chip.e-chip-selected{align-self:center;box-shadow:0 2px 3px 1px #00000036;display:inline-flex;padding:0 0 0 16px;width:92%}.e-multi-select-wrapper .e-ddl-disable-icon:before{content:""}.e-multiselect.e-rtl .e-multi-select-wrapper.e-delimiter .e-searcher{float:none}.e-multiselect.e-rtl .e-multi-select-wrapper.e-close-icon-hide{padding-left:0}.e-multiselect.e-rtl .e-multi-select-wrapper{padding:0 2px 0 32px}.e-multiselect.e-rtl .e-multi-select-wrapper .e-chips.e-mob-chip.e-chip-selected .e-chips-close:before{left:-12px}.e-multiselect.e-rtl .e-multi-select-wrapper .e-chips.e-mob-chip.e-chip-selected .e-chips-close{margin:0 auto 0 0}.e-multiselect.e-rtl .e-multi-select-wrapper .e-searcher{float:right}.e-multiselect.e-rtl .e-multi-select-wrapper .e-chips{float:right;margin:0 0 8px 8px;padding:0 8px 0 4px}.e-multiselect.e-rtl .e-multi-select-wrapper .e-chips .e-chipcontent{padding:5px 4px}.e-multiselect.e-rtl .e-multi-select-wrapper .e-chips .e-chips-close{float:left}.e-multiselect.e-rtl .e-multi-select-wrapper .e-chips .e-chips-close:before{left:0}.e-multiselect.e-rtl .e-multi-select-wrapper .e-chips.e-mob-chip{padding:0 4px 0 8px}.e-multiselect.e-rtl .e-multi-select-wrapper .e-chips.e-mob-chip .e-chipcontent{padding:8px 4px}.e-multiselect.e-rtl .e-multi-select-wrapper .e-chips.e-mob-chip.e-chip-selected{padding:0 8px 0 4px}.e-multiselect.e-rtl .e-multi-select-wrapper .e-chips.e-mob-chip.e-chip-selected .e-chipcontent{padding:12px 4px}.e-multiselect.e-rtl .e-multi-select-wrapper .e-chips-close.e-close-hooker{left:22px;position:absolute;right:auto}.e-multiselect.e-rtl .e-multi-select-wrapper .e-close-hooker:before{left:-4px}.e-multiselect.e-rtl .e-multi-select-wrapper .e-delim-values .e-remain{padding-right:16px}.e-multiselect.e-rtl .e-down-icon .e-chips-close.e-close-hooker{left:19px}.e-multiselect.e-rtl .e-multi-select-wrapper.e-down-icon .e-close-hooker:before{left:-7px}.e-popup.e-multi-select-list-wrapper .e-list-item .e-checkbox-wrapper{bottom:1px;margin-right:10px;position:relative;text-indent:0;vertical-align:middle}.e-popup.e-multi-select-list-wrapper.e-multiselect-group:not(.e-rtl) .e-list-item .e-checkbox-wrapper{padding-left:14px}.e-popup.e-multi-select-list-wrapper.e-multiselect-group.e-rtl .e-list-item .e-checkbox-wrapper{padding-right:25px}.e-popup.e-multi-select-list-wrapper.e-multiselect-group .e-list-group-item .e-checkbox-wrapper{bottom:1px;margin-right:10px;position:relative;text-indent:0;vertical-align:middle}.e-popup.e-multi-select-list-wrapper.e-rtl .e-list-item .e-checkbox-wrapper,.e-popup.e-multi-select-list-wrapper.e-multiselect-group.e-rtl .e-list-group-item .e-checkbox-wrapper{margin-left:12px;margin-right:0}.e-popup.e-multi-select-list-wrapper.e-rtl .e-list-item,.e-popup.e-multi-select-list-wrapper.e-rtl .e-dropdownbase.e-rtl.e-dd-group .e-list-item{padding-right:0}.e-multi-select-list-wrapper .e-selectall-parent{cursor:pointer;display:block;line-height:36px;overflow:hidden;text-overflow:ellipsis;padding-right:16px;position:relative;text-indent:17px;white-space:nowrap;width:100%}.e-rtl .e-multi-select-list-wrapper .e-selectall-parent,.e-multi-select-list-wrapper.e-rtl .e-selectall-parent{padding-left:16px;padding-right:0}.e-multi-select-list-wrapper .e-selectall-parent .e-all-text{color:#000000de;font-family:inherit;font-size:14px}.e-multi-select-list-wrapper .e-selectall-parent .e-checkbox-wrapper{bottom:1px;margin-right:10px;position:relative;text-indent:0;vertical-align:middle}.e-multi-select-list-wrapper.e-rtl .e-selectall-parent .e-checkbox-wrapper{margin-left:12px;margin-right:0}.e-multiselect .e-input-group-icon.e-ddl-icon{float:right;margin-top:6px}.e-multiselect.e-rtl .e-input-group-icon.e-ddl-icon{float:left}.e-multiselect .e-ddl-icon:before{transform:rotate(0);transition:transform .3s ease}.e-multiselect.e-icon-anim .e-ddl-icon:before{transform:rotate(180deg);transition:transform .3s ease}.e-multiselect.e-checkbox .e-multi-select-wrapper,.e-multiselect .e-multi-select-wrapper.e-down-icon{padding:0}.e-ddl.e-popup.e-multi-select-list-wrapper .e-filter-parent .e-input-filter,.e-ddl.e-popup.e-multi-select-list-wrapper .e-filter-parent .e-input-group.e-input-focus .e-input-filter{padding:8px}.e-ddl.e-popup.e-multi-select-list-wrapper .e-filter-parent .e-input-group:not(.e-control-container) .e-clear-icon{padding-left:8px;padding-right:8px}.e-ddl.e-popup.e-multi-select-list-wrapper .e-filter-parent .e-back-icon{padding:0 8px}.e-checkbox .e-multi-select-wrapper .e-delim-values .e-remain{line-height:20px;padding-left:10px}.e-popup.e-multi-select-list-wrapper .e-list-item.e-disable .e-checkbox-wrapper .e-frame,.e-popup.e-multi-select-list-wrapper .e-list-group-item.e-disable .e-checkbox-wrapper .e-frame{opacity:.3}.e-popup.e-multi-select-list-wrapper .e-list-item.e-disable,.e-popup.e-multi-select-list-wrapper.e-multiselect-group.e-checkbox .e-list-group-item.e-disable{opacity:.7}.e-multi-select-wrapper input[readonly=true],.e-multiselect.e-checkbox .e-multi-select-wrapper .e-searcher{pointer-events:none}ejs-multiselect{display:block}.e-small.e-multi-select-list-wrapper .e-selectall-parent,.e-small .e-multi-select-list-wrapper .e-selectall-parent{line-height:26px}.e-small .e-multi-select-wrapper .e-chips-close{height:14px;width:14px}.e-small .e-multi-select-wrapper{min-height:24px}.e-small .e-multi-select-wrapper input[type=text]{height:26px;min-height:26px}.e-small .e-multi-select-wrapper .e-delim-values{font-size:12px;line-height:26px}.e-small .e-multi-select-wrapper .e-chips-close.e-close-hooker,.e-small .e-multiselect.e-control-container .e-multi-select-wrapper .e-clear-icon{margin-top:-2.5em}.e-small.e-multiselect.e-control-container .e-multi-select-wrapper .e-ddl-icon,.e-small.e-multiselect.e-control-container.e-input-group .e-multi-select-wrapper .e-ddl-icon{margin-top:-1.8em}.e-content-placeholder.e-multiselect.e-placeholder-multiselect{background-size:300px 33px;min-height:33px}.e-multiselect.e-outline .e-multi-select-wrapper input[type=text]{color:inherit;font-size:inherit;min-height:34px;padding:8px 12px 9px}.e-multiselect.e-outline.e-input-focus .e-multi-select-wrapper input[type=text]{padding:8px 12px 9px}.e-small.e-multiselect.e-outline .e-multi-select-wrapper input[type=text],.e-small .e-multiselect.e-outline .e-multi-select-wrapper input[type=text]{font-size:inherit;min-height:30px;padding:7px 10px}.e-small.e-multiselect.e-outline.e-input-focus .e-multi-select-wrapper input[type=text],.e-small .e-multiselect.e-outline.e-input-focus .e-multi-select-wrapper input[type=text]{padding:7px 10px}.e-small .e-multiselect.e-outline .e-multi-select-wrapper,.e-small.e-multiselect.e-outline .e-multi-select-wrapper{min-height:30px;padding:3px 38px 1px 0}.e-multiselect.e-outline .e-multi-select-wrapper{min-height:34px;padding:3px 38px 1px 0}.e-outline.e-multiselect.e-checkbox .e-multi-select-wrapper,.e-multiselect.e-outline .e-multi-select-wrapper.e-down-icon{padding-right:0}.e-rtl.e-outline.e-multiselect.e-checkbox .e-multi-select-wrapper,.e-rtl.e-multiselect.e-outline .e-multi-select-wrapper.e-down-icon,.e-rtl .e-outline.e-multiselect.e-checkbox .e-multi-select-wrapper,.e-rtl .e-multiselect.e-outline .e-multi-select-wrapper.e-down-icon,.e-rtl.e-small.e-outline.e-multiselect.e-checkbox .e-multi-select-wrapper,.e-rtl.e-small.e-multiselect.e-outline .e-multi-select-wrapper.e-down-icon,.e-small .e-rtl.e-outline.e-multiselect.e-checkbox .e-multi-select-wrapper,.e-small .e-rtl.e-multiselect.e-outline .e-multi-select-wrapper.e-down-icon,.e-rtl .e-small.e-outline.e-multiselect.e-checkbox .e-multi-select-wrapper,.e-rtl .e-small.e-multiselect.e-outline .e-multi-select-wrapper.e-down-icon{padding-left:0}.e-rtl .e-multiselect.e-outline .e-multi-select-wrapper,.e-rtl.e-multiselect.e-outline .e-multi-select-wrapper,.e-rtl .e-small.e-multiselect.e-outline .e-multi-select-wrapper,.e-rtl.e-small .e-multiselect.e-outline .e-multi-select-wrapper,.e-rtl.e-small.e-multiselect.e-outline .e-multi-select-wrapper{padding:3px 0 1px 38px}.e-rtl .e-multiselect.e-outline .e-multi-select-wrapper.e-close-icon-hide,.e-rtl.e-multiselect.e-outline .e-multi-select-wrapper.e-close-icon-hide,.e-rtl .e-small.e-multiselect.e-outline .e-multi-select-wrapper.e-close-icon-hide,.e-rtl.e-small .e-multiselect.e-outline .e-multi-select-wrapper.e-close-icon-hide,.e-rtl.e-small.e-multiselect.e-outline .e-multi-select-wrapper.e-close-icon-hide{padding-left:0}.e-multiselect.e-outline .e-multi-select-wrapper.e-close-icon-hide,.e-small.e-multiselect.e-outline .e-multi-select-wrapper.e-close-icon-hide,.e-small .e-multiselect.e-outline .e-multi-select-wrapper.e-close-icon-hide{padding-right:0}.e-multiselect.e-outline .e-multi-select-wrapper.e-delimiter .e-searcher{height:34px}.e-small.e-multiselect.e-outline .e-multi-select-wrapper.e-delimiter .e-searcher,.e-small .e-multiselect.e-outline .e-multi-select-wrapper.e-delimiter .e-searcher{height:30px}.e-multiselect.e-outline .e-multi-select-wrapper .e-delim-values{font-size:14px;line-height:34px;padding:0 0 0 12px}.e-small.e-multiselect.e-outline .e-multi-select-wrapper .e-delim-values,.e-small .e-multiselect.e-outline .e-multi-select-wrapper .e-delim-values{font-size:13px;line-height:30px;padding:0 0 0 8px}.e-rtl.e-multiselect.e-outline .e-multi-select-wrapper .e-delim-values{padding:0 12px 0 0}.e-rtl.e-small.e-multiselect.e-outline .e-multi-select-wrapper .e-delim-values,.e-rtl.e-small .e-multiselect.e-outline .e-multi-select-wrapper .e-delim-values,.e-rtl .e-small.e-multiselect.e-outline .e-multi-select-wrapper .e-delim-values,.e-small .e-rtl.e-multiselect.e-outline .e-multi-select-wrapper .e-delim-values,.e-small .e-rtl .e-multiselect.e-outline .e-multi-select-wrapper .e-delim-values,.e-rtl .e-small .e-multiselect.e-outline .e-multi-select-wrapper .e-delim-values{padding:0 8px 0 0}.e-multiselect.e-outline .e-multi-select-wrapper .e-chips{height:26px;margin:4px 0 4px 8px;padding:0 8px}.e-rtl .e-multiselect.e-outline .e-multi-select-wrapper .e-chips,.e-rtl.e-multiselect.e-outline .e-multi-select-wrapper .e-chips{margin:4px 8px 4px 0}.e-small.e-multiselect.e-outline .e-multi-select-wrapper .e-chips,.e-small .e-multiselect.e-outline .e-multi-select-wrapper .e-chips{height:24px;padding:0 8px}.e-multiselect.e-outline .e-multi-select-wrapper .e-chips>.e-chipcontent{padding:0 8px 0 0}.e-rtl.e-multiselect.e-outline .e-multi-select-wrapper .e-chips>.e-chipcontent,.e-rtl .e-multiselect.e-outline .e-multi-select-wrapper .e-chips>.e-chipcontent{padding:0 0 0 8px}.e-multiselect.e-outline .e-multi-select-wrapper .e-chips>.e-chipcontent{font-size:13px}.e-small.e-multiselect.e-outline .e-multi-select-wrapper .e-chips>.e-chipcontent,.e-small .e-multiselect.e-outline .e-multi-select-wrapper .e-chips>.e-chipcontent{font-size:12px}.e-multiselect.e-outline .e-multi-select-wrapper .e-chips-close.e-close-hooker,.e-multiselect.e-control-container .e-multi-select-wrapper .e-clear-icon{align-items:normal}.e-multiselect.e-filled .e-multi-select-wrapper .e-delim-values .e-remain,.e-multiselect.e-outline .e-multi-select-wrapper .e-delim-values .e-remain{font-size:14px}.e-small.e-multiselect.e-filled .e-multi-select-wrapper .e-delim-values .e-remain,.e-small .e-multiselect.e-filled .e-multi-select-wrapper .e-delim-values .e-remain,.e-small.e-multiselect.e-outline .e-multi-select-wrapper .e-delim-values .e-remain,.e-small .e-multiselect.e-outline .e-multi-select-wrapper .e-delim-values .e-remain{font-size:13px}.e-filled.e-multiselect:not(.e-float-input) .e-multi-select-wrapper{padding:0 12px 0 8px}.e-multiselect.e-filled.e-input-group.e-control-wrapper{padding:0}.e-filled.e-float-input .e-multi-select-wrapper{padding:11px 12px 0}.e-small.e-filled.e-float-input .e-multi-select-wrapper,.e-small .e-filled.e-float-input .e-multi-select-wrapper{padding:12px 12px 0 8px}.e-rtl.e-multiselect.e-filled.e-input-group.e-control-wrapper,.e-rtl.e-multiselect.e-filled.e-float-input.e-control-wrapper{padding:0}.e-multiselect.e-filled:not(.e-float-input) .e-multi-select-wrapper input[type=text]{min-height:39px;padding-right:10px}.e-small.e-multiselect.e-filled:not(.e-float-input) .e-multi-select-wrapper input[type=text],.e-small .e-multiselect.e-filled:not(.e-float-input) .e-multi-select-wrapper input[type=text]{min-height:32px}.e-small.e-multiselect.e-filled.e-float-input .e-multi-select-wrapper input[type=text],.e-small .e-multiselect.e-filled.e-float-input .e-multi-select-wrapper input[type=text]{height:22px;min-height:22px;padding:2px}.e-filled.e-multiselect:not(.e-float-input) .e-multi-select-wrapper.e-delimiter .e-searcher{height:39px}.e-small.e-filled.e-multiselect:not(.e-float-input) .e-multi-select-wrapper.e-delimiter .e-searcher,.e-small .e-filled.e-multiselect:not(.e-float-input) .e-multi-select-wrapper.e-delimiter .e-searcher{height:32px}.e-small.e-filled.e-multiselect.e-float-input .e-multi-select-wrapper.e-delimiter .e-searcher,.e-small .e-filled.e-multiselect.e-float-input .e-multi-select-wrapper.e-delimiter .e-searcher{height:22px}.e-multiselect.e-filled.e-float-input .e-searcher .e-dropdownbase{min-height:28px}.e-multiselect.e-filled:not(.e-float-input) .e-multi-select-wrapper .e-delim-values{font-size:13px;line-height:39px}.e-multiselect.e-filled.e-float-input .e-multi-select-wrapper .e-delim-values{font-size:14px;line-height:28px}.e-small.e-multiselect.e-filled:not(.e-float-input) .e-multi-select-wrapper .e-delim-values,.e-small .e-multiselect.e-filled:not(.e-float-input) .e-multi-select-wrapper .e-delim-values,.e-small.e-multiselect.e-filled.e-float-input .e-multi-select-wrapper .e-delim-values,.e-small .e-multiselect.e-filled.e-float-input .e-multi-select-wrapper .e-delim-values{font-size:13px;line-height:32px}.e-small.e-multiselect.e-filled.e-float-input .e-multi-select-wrapper .e-delim-values,.e-small .e-multiselect.e-filled.e-float-input .e-multi-select-wrapper .e-delim-values{line-height:22px}.e-filled:not(.e-float-input) .e-multi-select-wrapper .e-chips{height:28px}.e-small.e-filled:not(.e-float-input) .e-multi-select-wrapper .e-chips,.e-small .e-filled:not(.e-float-input) .e-multi-select-wrapper .e-chips,.e-multiselect.e-filled.e-float-input .e-multi-select-wrapper.e-mob-wrapper .e-chips.e-mob-chip{height:24px}.e-filled.e-float-input .e-multi-select-wrapper .e-chips{height:18px}.e-filled.e-float-input .e-multi-select-wrapper .e-chips,.e-filled:not(.e-float-input) .e-multi-select-wrapper .e-chips{margin:8px 8px 0 0;padding:0 8px}.e-rtl.e-filled.e-float-input .e-multi-select-wrapper .e-chips,.e-rtl.e-filled:not(.e-float-input) .e-multi-select-wrapper .e-chips{margin:8px 0 0 8px;padding:0 8px}.e-small .e-filled .e-multi-select-wrapper .e-chips,.e-small.e-filled .e-multi-select-wrapper .e-chips{height:16px;margin:4px 4px 0 0;padding-right:8px}.e.rtl.e-small .e-filled.e-float-input .e-multi-select-wrapper .e-chips,.e-rtl.e-small.e-filled.e-float-input .e-multi-select-wrapper .e-chips{margin:4px 0 0 4px}.e-filled.e-multiselect.e-float-input .e-multi-select-wrapper .e-chips:not(.e-mob-chip) .e-chips-close{height:12px;width:12px}.e-filled.e-multiselect:not(.e-float-input) .e-multi-select-wrapper .e-chips>.e-chipcontent{font-size:13px;padding:0 8px 0 0}.e-small.e-filled.e-multiselect .e-multi-select-wrapper .e-chips>.e-chipcontent,.e-small .e-filled.e-multiselect .e-multi-select-wrapper .e-chips>.e-chipcontent{font-size:12px}.e-filled.e-float-input.e-multiselect .e-multi-select-wrapper .e-chips>.e-chipcontent{font-size:12px;padding:0 4px 0 0}.e-rtl.e-filled.e-multiselect .e-multi-select-wrapper .e-chips>.e-chipcontent{padding:0 0 0 4px}.e-small.e-filled.e-float-input.e-multiselect .e-multi-select-wrapper .e-chips>.e-chipcontent,.e-small .e-filled.e-float-input.e-multiselect .e-multi-select-wrapper .e-chips>.e-chipcontent{font-size:10px}.e-filled.e-multiselect.e-float-input .e-multi-select-wrapper.e-mob-wrapper .e-chips>.e-chipcontent{font-size:13px;padding-right:4px}.e-filled.e-multi-select-wrapper .e-chips-close.e-close-hooker,.e-multiselect.e-control-container .e-filled.e-multi-select-wrapper .e-clear-icon{height:38px;margin-top:-38px;right:12px;top:100%;width:16px}.e-multiselect.e-control-wrapper.e-input-group.e-readonly .e-clear-icon,.e-outline.e-multiselect.e-control-wrapper.e-input-group.e-readonly .e-clear-icon,.e-filled.e-multiselect.e-control-wrapper.e-input-group.e-readonly .e-clear-icon,.e-multiselect.e-readonly.e-control-wrapper.e-input-group.e-control-container :not(.e-disabled).e-multi-select-wrapper:hover .e-clear-icon,.e-multiselect.e-readonly.e-control-wrapper.e-input-group.e-control-container.e-input-group :not(.e-disabled).e-multi-select-wrapper:hover .e-clear-icon{display:none}.e-multiselect.e-input-group.e-control-wrapper .e-input-group-icon{margin-right:0}.e-multiselect.e-control-container.e-input-group.e-disabled .e-input-group-icon.e-ddl-icon.e-icons,.e-multiselect.e-control-container.e-input-group.e-disabled .e-clear-icon{cursor:not-allowed}.e-multiselect.e-control-wrapper.e-control-container.e-input-group.e-checkbox .e-multi-select-wrapper.e-down-icon,.e-multiselect.e-control-wrapper.e-control-container.e-input-group.e-checkbox .e-multi-select-wrapper.e-down-icon .e-multi-searcher .e-dropdownbase.e-control.e-multiselect.e-lib{cursor:pointer}.e-multi-select-wrapper .e-chips.e-chip-selected .e-chips-close:before{color:#fff}.e-multi-select-wrapper .e-chips.e-chip-selected{background-color:#757575}.e-multiselect:not(.e-disabled) .e-multi-select-wrapper .e-chips.e-chip-selected:hover{background-color:#757575}.e-multiselect{box-sizing:border-box}.e-multi-select-wrapper .e-chips>.e-chipcontent{-webkit-text-fill-color:rgba(0,0,0,.87);color:#000000de;font-family:inherit;font-size:13px}.e-multi-select-wrapper .e-chips.e-chip-selected>.e-chipcontent{color:#fff}.e-multi-select-wrapper .e-chips.e-chip-selected>.e-chipcontent:hover{color:#fff}.e-multi-select-wrapper .e-chips{background-color:#eee;border-radius:16px;height:24px}.e-multiselect:not(.e-disabled) .e-multi-select-wrapper .e-chips:hover{background-color:#eee}.e-multi-select-wrapper .e-chips>.e-chipcontent:hover{color:#000000de}.e-multi-select-wrapper .e-chips .e-chips-close:before{-webkit-text-fill-color:rgba(0,0,0,.54);color:#0000008a;font-size:16px}.e-multi-select-wrapper .e-chips.e-mob-chip.e-chip-selected{background-color:#3f51b5;border-radius:2px;color:#fff;height:40px;line-height:40px}.e-multi-select-wrapper .e-chips.e-mob-chip.e-chip-selected .e-chipcontent{color:#fff}.e-multi-select-wrapper .e-chips.e-mob-chip{height:28px}.e-popup.e-multi-select-list-wrapper{box-shadow:0 5px 5px -3px #0003,0 8px 10px 1px #00000024,0 3px 14px 2px #0000001f;box-sizing:content-box;overflow:initial}.e-popup.e-multi-select-list-wrapper .e-list-item.e-active{border-bottom:1px solid transparent;border-left:1px solid #e0e0e0;border-right:1px solid #e0e0e0;border-top:1px solid #fff}.e-popup.e-multi-select-list-wrapper.e-checkbox .e-list-item.e-active,.e-popup.e-multi-select-list-wrapper.e-multiselect-group.e-checkbox .e-list-group-item.e-active{background-color:transparent;border-color:transparent;color:#000000de}.e-popup.e-multi-select-list-wrapper.e-checkbox .e-list-item.e-active.e-item-focus,.e-popup.e-multi-select-list-wrapper.e-multiselect-group.e-checkbox .e-list-group-item.e-active.e-item-focus{color:#000000de}.e-popup.e-multi-select-list-wrapper.e-checkbox .e-list-item.e-active.e-hover,.e-popup.e-multi-select-list-wrapper.e-multiselect-group.e-checkbox .e-list-group-item.e-active.e-hover{background-color:#eee}.e-popup.e-multi-select-list-wrapper .e-list-item.e-active:first-child{border-bottom:1px solid transparent;border-top:1px solid transparent}.e-popup.e-multi-select-list-wrapper .e-list-item.e-active:last-child{border-bottom:1px solid transparent}.e-popup.e-multi-select-list-wrapper .e-list-item.e-active.e-item-focus+li.e-active{border-top:1px solid transparent}.e-popup.e-multi-select-list-wrapper .e-list-item.e-active.e-item-focus,.e-popup.e-multi-select-list-wrapper.e-multiselect-group .e-list-group-item.e-active.e-item-focus{background-color:#e0e0e0;box-shadow:none;color:#e3165b;border:1px solid transparent}.e-popup.e-multi-select-list-wrapper .e-list-item,.e-popup.e-multi-select-list-wrapper.e-multiselect-group .e-list-group-item{border:1px solid transparent}.e-multi-select-wrapper input.e-dropdownbase:-moz-placeholder{color:#0000006b}.e-multi-select-wrapper input.e-dropdownbase::-moz-placeholder{color:#0000006b}.e-multi-select-wrapper input.e-dropdownbase:-ms-input-placeholder{color:#0000006b}.e-multi-select-wrapper input.e-dropdownbase::-webkit-input-placeholder{color:#0000006b}.e-ul.e-reorder,.e-multi-select-list-wrapper .e-selectall-parent{border-bottom:1px solid rgba(0,0,0,.12)}.e-multi-select-wrapper .e-delim-values{-webkit-text-fill-color:rgba(0,0,0,.87);color:#000000de}.e-multi-select-wrapper .e-chips-close.e-close-hooker{color:#000}.e-small .e-multi-select-wrapper .e-chips{height:20px}.e-small .e-multi-select-wrapper .e-chips>.e-chipcontent{font-size:12px}.e-small .e-multi-select-wrapper .e-chips .e-chips-close:before{font-size:14px}.e-small .e-multi-select-wrapper .e-close-hooker:before{left:6px}.e-multiselect.e-outline .e-multi-select-wrapper .e-chips{background-color:#e0e0e0}.e-multiselect.e-filled .e-multi-select-wrapper .e-chips{background-color:#cecece}.e-multiselect.e-outline .e-multi-select-wrapper .e-chips:hover{background-color:#d6d6d6}.e-multiselect.e-filled .e-multi-select-wrapper .e-chips:hover{background-color:#cecece}.e-multiselect.e-outline .e-multi-select-wrapper .e-chips.e-chip-selected,.e-multiselect.e-filled .e-multi-select-wrapper .e-chips.e-chip-selected,.e-multiselect.e-outline .e-multi-select-wrapper .e-chips.e-chip-selected:hover,.e-multiselect.e-filled .e-multi-select-wrapper .e-chips.e-chip-selected:hover{background-color:#c7c7c7}.e-multiselect.e-outline .e-multi-select-wrapper .e-chips.e-chip-selected>.e-chipcontent,.e-multiselect.e-filled .e-multi-select-wrapper .e-chips.e-chip-selected>.e-chipcontent{color:#000000de}.e-multiselect.e-outline .e-multi-select-wrapper .e-chips.e-chip-selected>.e-chipcontent:hover,.e-multiselect.e-filled .e-multi-select-wrapper .e-chips.e-chip-selected>.e-chipcontent:hover{color:#000000de}.e-multiselect.e-outline .e-multi-select-wrapper .e-chips-close.e-close-hooker,.e-multiselect.e-filled .e-multi-select-wrapper .e-chips-close.e-close-hooker{color:#0000008a}.e-multiselect.e-outline .e-multi-select-wrapper .e-chips-close.e-close-hooker:hover,.e-multiselect.e-filled .e-multi-select-wrapper .e-chips-close.e-close-hooker:hover{color:#000000de}.e-multiselect.e-outline .e-multi-select-wrapper .e-chips.e-chip-selected .e-chips-close:before,.e-multiselect.e-filled .e-multi-select-wrapper .e-chips.e-chip-selected .e-chips-close:before{color:#0000008a}.e-multiselect.e-filled .e-multi-select-wrapper .e-chips.e-mob-chip.e-chip-selected .e-chips-close:before,.e-multiselect.e-outline .e-multi-select-wrapper .e-chips.e-mob-chip.e-chip-selected .e-chips-close:before{color:#fff}.e-multiselect.e-outline:not(.e-disabled) .e-multi-select-wrapper .e-chips:not(.e-chip-selected) .e-chips-close:hover:before,.e-multiselect.e-filled:not(.e-disabled) .e-multi-select-wrapper .e-chips:not(.e-chip-selected) .e-chips-close:hover:before{color:#000000de}.e-multiselect.e-outline .e-multi-select-wrapper .e-delim-values .e-remain,.e-multiselect.e-filled .e-multi-select-wrapper .e-delim-values .e-remain{color:#0009}.e-multiselect.e-outline.e-disabled .e-multi-select-wrapper .e-delim-values,.e-multiselect.e-outline.e-disabled .e-multi-select-wrapper .e-delim-values .e-remain,.e-multiselect.e-outline.e-disabled .e-multi-select-wrapper .e-chips>.e-chipcontent,.e-multiselect.e-outline.e-disabled .e-multi-select-wrapper .e-chips .e-chips-close:before,.e-multiselect.e-outline.e-disabled .e-multi-select-wrapper .e-chips-close.e-close-hooker{color:#00000061}.e-multiselect.e-disabled .e-multi-select-wrapper .e-delim-values{-webkit-text-fill-color:rgba(0,0,0,.42);color:#0000006b}.e-multiselect.e-outline.e-disabled .e-multi-select-wrapper .e-chips{background-color:#f5f5f5}.e-multiselect.e-filled .e-multi-select-wrapper.e-mob-wrapper .e-chips.e-mob-chip.e-chip-selected,.e-multiselect.e-outline .e-multi-select-wrapper .e-chips.e-mob-chip.e-chip-selected{background-color:#3f51b5;border-radius:4px;box-sizing:border-box;color:#fff;height:40px;line-height:40px;margin-left:0;margin-right:0;width:100%}.e-multiselect.e-filled .e-multi-select-wrapper .e-chips.e-mob-chip.e-chip-selected .e-chips-close,.e-multiselect.e-outline .e-multi-select-wrapper .e-chips.e-mob-chip.e-chip-selected .e-chips-close{width:33px}.e-multiselect.e-filled .e-multi-select-wrapper .e-chips.e-mob-chip.e-chip-selected .e-chipcontent,.e-multiselect.e-outline .e-multi-select-wrapper .e-chips.e-mob-chip.e-chip-selected .e-chipcontent{color:#fff}.e-bigger .e-multiselect.e-control-container.e-input-group .e-multi-select-wrapper .e-ddl-icon,.e-bigger.e-multiselect.e-control-container.e-input-group .e-multi-select-wrapper .e-ddl-icon{margin-top:-2.5em}.e-bigger .e-multi-select-wrapper{min-height:37px}.e-bigger .e-multi-select-wrapper .e-chips{margin:0 8px 6px 0}.e-bigger .e-multi-select-wrapper .e-chips>.e-chipcontent{padding:8px 4px 8px 0}.e-bigger .e-multiselect.e-rtl .e-multi-select-wrapper .e-chips>.e-chipcontent{padding:8px 0 8px 4px}.e-bigger .e-multi-select-wrapper .e-chips-close.e-close-hooker,.e-bigger .e-multiselect.e-control-container .e-multi-select-wrapper .e-clear-icon,.e-bigger.e-multiselect.e-control-container .e-multi-select-wrapper .e-clear-icon{margin-top:-3em}.e-bigger .e-multi-select-wrapper input[type=text],.e-multi-select-wrapper.e-mob-wrapper input[type=text]{height:28px;min-height:28px}.e-bigger .e-multi-select-wrapper input[type=text]{height:34px;min-height:34px}.e-bigger .e-multiselect .e-multi-select-wrapper.e-down-icon .e-searcher.e-search-custom-width,.e-bigger.e-multiselect .e-multi-select-wrapper.e-down-icon .e-searcher.e-search-custom-width{width:calc(100% - 38px)}.e-bigger.e-small .e-multiselect .e-multi-select-wrapper.e-down-icon .e-searcher.e-search-custom-width,.e-bigger.e-small.e-multiselect .e-multi-select-wrapper.e-down-icon .e-searcher.e-search-custom-width,.e-bigger .e-small.e-multiselect .e-multi-select-wrapper.e-down-icon .e-searcher.e-search-custom-width,.e-small .e-bigger.e-multiselect .e-multi-select-wrapper.e-down-icon .e-searcher.e-search-custom-width,.e-bigger.e-small.e-multiselect.e-outline .e-multi-select-wrapper.e-down-icon .e-searcher.e-search-custom-width,.e-bigger.e-small .e-multiselect.e-outline .e-multi-select-wrapper.e-down-icon .e-searcher.e-search-custom-width,.e-bigger .e-small.e-multiselect.e-outline .e-multi-select-wrapper.e-down-icon .e-searcher.e-search-custom-width,.e-small .e-bigger.e-multiselect.e-outline .e-multi-select-wrapper.e-down-icon .e-searcher.e-search-custom-width{width:calc(100% - 32px)}.e-bigger .e-multi-select-wrapper .e-delim-values{line-height:34px;padding-left:0}.e-bigger .e-popup.e-multi-select-list-wrapper.e-multiselect-group.e-rtl .e-list-item .e-checkbox-wrapper{padding-right:25px}.e-bigger .e-popup.e-multi-select-list-wrapper .e-list-item .e-checkbox-wrapper,.e-bigger.e-popup.e-multi-select-list-wrapper .e-list-item .e-checkbox-wrapper,.e-bigger .e-popup.e-multi-select-list-wrapper.e-multiselect-group .e-list-group-item .e-checkbox-wrapper,.e-bigger.e-popup.e-multi-select-list-wrapper.e-multiselect-group .e-list-group-item .e-checkbox-wrapper{bottom:1px;margin-right:12px}.e-bigger .e-popup.e-multi-select-list-wrapper.e-multiselect-group .e-dropdownbase.e-dd-group .e-list-group-item{padding-left:16px}.e-bigger .e-popup.e-multi-select-list-wrapper.e-multiselect-group:not(.e-rtl) .e-dropdownbase.e-dd-group .e-list-item .e-checkbox-wrapper{padding-left:14px}.e-bigger.e-multi-select-list-wrapper .e-selectall-parent,.e-bigger .e-multi-select-list-wrapper .e-selectall-parent{font-size:13px;line-height:48px;text-indent:17px}.e-bigger.e-multi-select-list-wrapper .e-selectall-parent .e-checkbox-wrapper,.e-bigger .e-multi-select-list-wrapper .e-selectall-parent .e-checkbox-wrapper{bottom:1px;margin-right:12px}.e-bigger .e-ddl.e-popup.e-multi-select-list-wrapper .e-filter-parent .e-input-filter,.e-bigger .e-ddl.e-popup.e-multi-select-list-wrapper .e-filter-parent .e-input-group.e-input-focus{padding:4px 0}.e-bigger .e-ddl.e-popup.e-multi-select-list-wrapper .e-filter-parent .e-input-group:not(.e-control-container) .e-clear-icon{padding-left:8px;padding-right:8px}.e-bigger .e-checkbox .e-multi-select-wrapper .e-delim-values{line-height:34px}.e-bigger.e-small.e-multi-select-list-wrapper .e-selectall-parent,.e-bigger.e-small .e-multi-select-list-wrapper .e-selectall-parent{line-height:40px}.e-bigger.e-small.e-multiselect.e-control-container .e-multi-select-wrapper .e-ddl-icon,.e-bigger.e-small.e-multiselect.e-control-container.e-input-group .e-multi-select-wrapper .e-ddl-icon{margin-top:-2em}.e-bigger.e-small .e-multi-select-wrapper .e-chips-close{height:16px;width:16px}.e-bigger.e-small .e-multi-select-wrapper{min-height:28px}.e-bigger.e-small .e-multi-select-wrapper input[type=text]{height:28px;min-height:28px}.e-small.e-bigger .e-multi-select-wrapper .e-delim-values{font-size:13px;line-height:28px}.e-bigger.e-small .e-multi-select-wrapper .e-chips-close.e-close-hooker,.e-bigger.e-small .e-multiselect.e-control-container .e-multi-select-wrapper .e-clear-icon{margin-top:-2.5em;right:5px}.e-bigger .e-content-placeholder.e-multiselect.e-placeholder-multiselect,.e-bigger.e-content-placeholder.e-multiselect.e-placeholder-multiselect{background-size:300px 40px;min-height:40px}.e-bigger.e-small.e-multiselect.e-outline .e-multi-select-wrapper input[type=text],.e-bigger.e-small .e-multiselect.e-outline .e-multi-select-wrapper input[type=text],.e-bigger .e-small.e-multiselect.e-outline .e-multi-select-wrapper input[type=text],.e-small .e-bigger.e-multiselect.e-outline .e-multi-select-wrapper input[type=text]{font-size:inherit;min-height:34px;padding:8px 12px 9px}.e-bigger.e-small.e-multiselect.e-outline.e-input-focus .e-multi-select-wrapper input[type=text],.e-bigger.e-small .e-multiselect.e-outline.e-input-focus .e-multi-select-wrapper input[type=text],.e-bigger .e-small.e-multiselect.e-outline.e-input-focus .e-multi-select-wrapper input[type=text],.e-small .e-bigger.e-multiselect.e-outline.e-input-focus .e-multi-select-wrapper input[type=text]{padding:8px 12px 9px}.e-bigger.e-multiselect.e-outline .e-multi-select-wrapper input[type=text],.e-bigger .e-multiselect.e-outline .e-multi-select-wrapper input[type=text]{font-size:inherit;min-height:40px}.e-bigger .e-multiselect.e-outline .e-multi-select-wrapper,.e-bigger.e-multiselect.e-outline .e-multi-select-wrapper{min-height:40px;padding:7px 42px 7px 0}.e-bigger .e-small.e-multiselect.e-outline .e-multi-select-wrapper,.e-bigger.e-small .e-multiselect.e-outline .e-multi-select-wrapper,.e-bigger.e-small.e-multiselect.e-outline .e-multi-select-wrapper,.e-small .e-bigger.e-multiselect.e-outline .e-multi-select-wrapper,.e-small.e-bigger .e-multiselect.e-outline .e-multi-select-wrapper{min-height:34px;padding:3px 38px 1px 0}.e-bigger.e-outline.e-multiselect.e-checkbox .e-multi-select-wrapper,.e-bigger.e-multiselect.e-outline .e-multi-select-wrapper.e-down-icon,.e-bigger .e-outline.e-multiselect.e-checkbox .e-multi-select-wrapper,.e-bigger .e-multiselect.e-outline .e-multi-select-wrapper.e-down-icon{padding-right:0}.e-rtl.e-bigger.e-outline.e-multiselect.e-checkbox .e-multi-select-wrapper,.e-rtl.e-bigger.e-multiselect.e-outline .e-multi-select-wrapper.e-down-icon,.e-bigger .e-rtl.e-outline.e-multiselect.e-checkbox .e-multi-select-wrapper,.e-bigger .e-rtl.e-multiselect.e-outline .e-multi-select-wrapper.e-down-icon,.e-rtl .e-bigger.e-outline.e-multiselect.e-checkbox .e-multi-select-wrapper,.e-rtl .e-bigger.e-multiselect.e-outline .e-multi-select-wrapper.e-down-icon,.e-rtl.e-bigger .e-small.e-multiselect.e-outline.e-checkbox .e-multi-select-wrapper,.e-rtl.e-small .e-bigger.e-multiselect.e-outline.e-checkbox .e-multi-select-wrapper,.e-rtl .e-bigger .e-small.e-multiselect.e-outline.e-checkbox .e-multi-select-wrapper,.e-rtl .e-small .e-bigger.e-multiselect.e-outline.e-checkbox .e-multi-select-wrapper,.e-rtl.e-small.e-bigger .e-multiselect.e-outline.e-checkbox .e-multi-select-wrapper,.e-rtl.e-small.e-bigger.e-multiselect.e-outline.e-checkbox .e-multi-select-wrapper,.e-rtl.e-bigger .e-small.e-multiselect.e-outline .e-multi-select-wrapper.e-down-icon,.e-rtl.e-small .e-bigger.e-multiselect.e-outline .e-multi-select-wrapper.e-down-icon,.e-rtl .e-bigger .e-small.e-multiselect.e-outline .e-multi-select-wrapper.e-down-icon,.e-rtl .e-small .e-bigger.e-multiselect.e-outline .e-multi-select-wrapper.e-down-icon,.e-rtl.e-small.e-bigger .e-multiselect.e-outline .e-multi-select-wrapper.e-down-icon,.e-rtl.e-small.e-bigger.e-multiselect.e-outline .e-multi-select-wrapper.e-down-icon{padding-left:0}.e-rtl.e-bigger .e-small.e-multiselect.e-outline .e-multi-select-wrapper,.e-rtl.e-small .e-bigger.e-multiselect.e-outline .e-multi-select-wrapper,.e-rtl .e-bigger .e-small.e-multiselect.e-outline .e-multi-select-wrapper,.e-rtl .e-small .e-bigger.e-multiselect.e-outline .e-multi-select-wrapper,.e-rtl.e-small.e-bigger .e-multiselect.e-outline .e-multi-select-wrapper,.e-rtl.e-small.e-bigger.e-multiselect.e-outline .e-multi-select-wrapper{padding:3px 0 1px 38px}.e-rtl .e-bigger.e-multiselect.e-outline .e-multi-select-wrapper,.e-rtl.e-bigger .e-multiselect.e-outline .e-multi-select-wrapper,.e-rtl.e-bigger.e-multiselect.e-outline .e-multi-select-wrapper{padding:7px 0 7px 42px}.e-rtl.e-bigger .e-small.e-multiselect.e-outline .e-multi-select-wrapper.e-close-icon-hide,.e-rtl.e-small .e-bigger.e-multiselect.e-outline .e-multi-select-wrapper.e-close-icon-hide,.e-rtl .e-bigger .e-small.e-multiselect.e-outline .e-multi-select-wrapper.e-close-icon-hide,.e-rtl .e-small .e-bigger.e-multiselect.e-outline .e-multi-select-wrapper.e-close-icon-hide,.e-rtl.e-small.e-bigger .e-multiselect.e-outline .e-multi-select-wrapper.e-close-icon-hide,.e-rtl.e-small.e-bigger.e-multiselect.e-outline .e-multi-select-wrapper.e-close-icon-hide,.e-rtl .e-bigger.e-multiselect.e-outline .e-multi-select-wrapper.e-close-icon-hide,.e-rtl.e-bigger .e-multiselect.e-outline .e-multi-select-wrapper.e-close-icon-hide,.e-rtl.e-bigger.e-multiselect.e-outline .e-multi-select-wrapper.e-close-icon-hide{padding-left:0}.e-bigger .e-small.e-multiselect.e-outline .e-multi-select-wrapper.e-close-icon-hide,.e-small .e-bigger.e-multiselect.e-outline .e-multi-select-wrapper.e-close-icon-hide,.e-small.e-bigger .e-multiselect.e-outline .e-multi-select-wrapper.e-close-icon-hide,.e-small.e-bigger.e-multiselect.e-outline .e-multi-select-wrapper.e-close-icon-hide,.e-bigger .e-multiselect.e-outline .e-multi-select-wrapper.e-close-icon-hide,.e-bigger.e-multiselect.e-outline .e-multi-select-wrapper.e-close-icon-hide{padding-right:0}.e-bigger.e-multiselect.e-outline .e-multi-select-wrapper.e-delimiter .e-searcher,.e-bigger .e-multiselect.e-outline .e-multi-select-wrapper.e-delimiter .e-searcher{height:40px}.e-bigger.e-small.e-multiselect.e-outline .e-multi-select-wrapper.e-delimiter .e-searcher,.e-bigger.e-small .e-multiselect.e-outline .e-multi-select-wrapper.e-delimiter .e-searcher,.e-bigger .e-small.e-multiselect.e-outline .e-multi-select-wrapper.e-delimiter .e-searcher,.e-small .e-bigger.e-multiselect.e-outline .e-multi-select-wrapper.e-delimiter .e-searcher{height:34px}.e-bigger.e-multiselect.e-outline .e-multi-select-wrapper .e-delim-values,.e-bigger .e-multiselect.e-outline .e-multi-select-wrapper .e-delim-values{font-size:16px;line-height:40px;padding:0 0 0 16px}.e-bigger.e-small.e-multiselect.e-outline .e-multi-select-wrapper .e-delim-values,.e-bigger.e-small .e-multiselect.e-outline .e-multi-select-wrapper .e-delim-values,.e-bigger .e-small.e-multiselect.e-outline .e-multi-select-wrapper .e-delim-values,.e-small .e-bigger.e-multiselect.e-outline .e-multi-select-wrapper .e-delim-values{font-size:14px;line-height:34px;padding:0 0 0 12px}.e-rtl.e-bigger.e-multiselect.e-outline .e-multi-select-wrapper .e-delim-values,.e-rtl.e-bigger .e-multiselect.e-outline .e-multi-select-wrapper .e-delim-values,.e-rtl .e-bigger.e-multiselect.e-outline .e-multi-select-wrapper .e-delim-values,.e-bigger .e-rtl.e-multiselect.e-outline .e-multi-select-wrapper .e-delim-values,.e-bigger .e-rtl .e-multiselect.e-outline .e-multi-select-wrapper .e-delim-values,.e-rtl .e-bigger .e-multiselect.e-outline .e-multi-select-wrapper .e-delim-values{padding:0 16px 0 0}.e-rtl.e-bigger.e-small.e-multiselect.e-outline .e-multi-select-wrapper .e-delim-values,.e-rtl.e-bigger.e-small .e-multiselect.e-outline .e-multi-select-wrapper .e-delim-values,.e-rtl .e-bigger.e-small.e-multiselect.e-outline .e-multi-select-wrapper .e-delim-values,.e-bigger.e-small .e-rtl.e-multiselect.e-outline .e-multi-select-wrapper .e-delim-values,.e-rtl.e-bigger .e-small.e-multiselect.e-outline .e-multi-select-wrapper .e-delim-values,.e-rtl .e-bigger .e-small.e-multiselect.e-outline .e-multi-select-wrapper .e-delim-values,.e-bigger .e-rtl.e-small.e-multiselect.e-outline .e-multi-select-wrapper .e-delim-values,.e-bigger .e-rtl .e-small.e-multiselect.e-outline .e-multi-select-wrapper .e-delim-values,.e-rtl.e-small .e-bigger.e-multiselect.e-outline .e-multi-select-wrapper .e-delim-values,.e-rtl .e-small .e-bigger.e-multiselect.e-outline .e-multi-select-wrapper .e-delim-values,.e-small .e-rtl .e-bigger.e-multiselect.e-outline .e-multi-select-wrapper .e-delim-values,.e-small .e-rtl.e-bigger.e-multiselect.e-outline .e-multi-select-wrapper .e-delim-values{padding:0 12px 0 0}.e-bigger.e-multiselect.e-outline .e-multi-select-wrapper .e-chips,.e-bigger .e-multiselect.e-outline .e-multi-select-wrapper .e-chips{height:32px;padding:0 12px}.e-bigger.e-small.e-multiselect.e-outline .e-multi-select-wrapper .e-chips,.e-bigger.e-small .e-multiselect.e-outline .e-multi-select-wrapper .e-chips,.e-bigger .e-small.e-multiselect.e-outline .e-multi-select-wrapper .e-chips,.e-small .e-bigger.e-multiselect.e-outline .e-multi-select-wrapper .e-chips{height:26px;padding:0 8px}.e-bigger.e-small.e-multiselect.e-outline .e-multi-select-wrapper .e-chips>.e-chipcontent,.e-bigger.e-small .e-multiselect.e-outline .e-multi-select-wrapper .e-chips>.e-chipcontent,.e-bigger .e-small.e-multiselect.e-outline .e-multi-select-wrapper .e-chips>.e-chipcontent,.e-small .e-bigger.e-multiselect.e-outline .e-multi-select-wrapper .e-chips>.e-chipcontent{font-size:13px}.e-bigger.e-multiselect.e-outline .e-multi-select-wrapper .e-chips>.e-chipcontent,.e-bigger .e-multiselect.e-outline .e-multi-select-wrapper .e-chips>.e-chipcontent{font-size:14px}.e-bigger.e-multiselect.e-filled .e-multi-select-wrapper .e-delim-values .e-remain,.e-bigger .e-multiselect.e-filled .e-multi-select-wrapper .e-delim-values .e-remain,.e-bigger.e-multiselect.e-outline .e-multi-select-wrapper .e-delim-values .e-remain,.e-bigger .e-multiselect.e-outline .e-multi-select-wrapper .e-delim-values .e-remain{font-size:16px}.e-bigger.e-small.e-multiselect.e-filled .e-multi-select-wrapper .e-delim-values .e-remain,.e-bigger.e-small .e-multiselect.e-filled .e-multi-select-wrapper .e-delim-values .e-remain,.e-bigger .e-small.e-multiselect.e-filled .e-multi-select-wrapper .e-delim-values .e-remain,.e-small .e-bigger.e-multiselect.e-filled .e-multi-select-wrapper .e-delim-values .e-remain,.e-bigger.e-small.e-multiselect.e-outline .e-multi-select-wrapper .e-delim-values .e-remain,.e-bigger.e-small .e-multiselect.e-outline .e-multi-select-wrapper .e-delim-values .e-remain,.e-bigger .e-small.e-multiselect.e-outline .e-multi-select-wrapper .e-delim-values .e-remain,.e-small .e-bigger.e-multiselect.e-outline .e-multi-select-wrapper .e-delim-values .e-remain{font-size:14px}.e-small.e-filled:not(.e-bigger).e-multiselect:not(.e-float-input) .e-multi-select-wrapper,.e-small .e-filled:not(.e-bigger).e-multiselect:not(.e-float-input) .e-multi-select-wrapper{padding:3px 12px 0 4px}.e-bigger.e-small.e-multiselect.e-filled.e-input-group.e-control-wrapper,.e-bigger.e-small .e-multiselect.e-filled.e-input-group.e-control-wrapper,.e-bigger .e-small.e-multiselect.e-filled.e-input-group.e-control-wrapper,.e-small .e-bigger.e-multiselect.e-filled.e-input-group.e-control-wrapper{padding:0}.e-bigger.e-small.e-filled.e-float-input .e-multi-select-wrapper,.e-bigger.e-small .e-filled.e-float-input .e-multi-select-wrapper,.e-bigger .e-small.e-filled.e-float-input .e-multi-select-wrapper,.e-small .e-bigger.e-filled.e-float-input .e-multi-select-wrapper{padding:11px 12px 0}.e-bigger.e-filled.e-float-input .e-multi-select-wrapper,.e-bigger .e-filled.e-float-input .e-multi-select-wrapper{padding:19px 12px 0 16px}.e-bigger:not(.e-small).e-filled.e-multiselect:not(.e-float-input) .e-multi-select-wrapper{padding-top:3px}.e-bigger.e-small.e-multiselect.e-filled:not(.e-float-input) .e-multi-select-wrapper input[type=text],.e-bigger.e-small .e-multiselect.e-filled:not(.e-float-input) .e-multi-select-wrapper input[type=text],.e-bigger .e-small.e-multiselect.e-filled:not(.e-float-input) .e-multi-select-wrapper input[type=text],.e-small .e-bigger.e-multiselect.e-filled:not(.e-float-input) .e-multi-select-wrapper input[type=text]{min-height:39px;padding-right:10px}.e-bigger.e-multiselect.e-filled:not(.e-float-input) .e-multi-select-wrapper input[type=text],.e-bigger .e-multiselect.e-filled:not(.e-float-input) .e-multi-select-wrapper input[type=text]{min-height:52px}.e-bigger.e-multiselect.e-filled.e-float-input .e-multi-select-wrapper input[type=text],.e-bigger .e-multiselect.e-filled.e-float-input .e-multi-select-wrapper input[type=text]{min-height:36px}.e-bigger.e-filled:not(.e-small).e-multiselect:not(.e-float-input) .e-multi-select-wrapper.e-delimiter .e-searcher,.e-bigger .e-filled:not(.e-small).e-multiselect:not(.e-float-input) .e-multi-select-wrapper.e-delimiter .e-searcher{height:52px}.e-bigger.e-filled.e-multiselect.e-float-input .e-multi-select-wrapper.e-delimiter .e-searcher,.e-bigger .e-filled.e-multiselect.e-float-input .e-multi-select-wrapper.e-delimiter .e-searcher{height:36px}.e-bigger.e-small.e-filled.e-multiselect.e-float-input .e-multi-select-wrapper.e-delimiter .e-searcher,.e-bigger.e-small .e-filled.e-multiselect.e-float-input .e-multi-select-wrapper.e-delimiter .e-searcher .e-bigger .e-small.e-filled.e-multiselect.e-float-input .e-multi-select-wrapper.e-delimiter .e-searcher,.e-small .e-bigger.e-filled.e-multiselect.e-float-input .e-multi-select-wrapper.e-delimiter .e-searcher{height:28px}.e-bigger.e-multiselect.e-filled.e-float-input .e-multi-select-wrapper.e-delimiter input[type=text],.e-bigger .e-multiselect.e-filled.e-float-input .e-multi-select-wrapper.e-delimiter input[type=text]{padding:5px 0}.e-bigger.e-small.e-multiselect.e-filled.e-float-input .e-searcher .e-dropdownbase,.e-bigger.e-small .e-multiselect.e-filled.e-float-input .e-searcher .e-dropdownbase,.e-bigger .e-small.e-multiselect.e-filled.e-float-input .e-searcher .e-dropdownbase,.e-small .e-bigger.e-multiselect.e-filled.e-float-input .e-searcher .e-dropdownbase{min-height:28px}.e-small.e-bigger.e-multiselect.e-filled:not(.e-float-input) .e-multi-select-wrapper .e-delim-values,.e-small.e-bigger .e-multiselect.e-filled:not(.e-float-input) .e-multi-select-wrapper .e-delim-values,.e-small .e-bigger.e-multiselect.e-filled:not(.e-float-input) .e-multi-select-wrapper .e-delim-values,.e-bigger .e-small.e-multiselect.e-filled:not(.e-float-input) .e-multi-select-wrapper .e-delim-values{font-size:13px;line-height:39px}.e-small.e-bigger.e-multiselect.e-filled.e-float-input .e-multi-select-wrapper .e-delim-values,.e-small.e-bigger .e-multiselect.e-filled.e-float-input .e-multi-select-wrapper .e-delim-values,.e-small .e-bigger.e-multiselect.e-filled.e-float-input .e-multi-select-wrapper .e-delim-values,.e-bigger .e-small.e-multiselect.e-filled.e-float-input .e-multi-select-wrapper .e-delim-values{font-size:14px;line-height:28px}.e-bigger.e-multiselect.e-filled:not(.e-float-input) .e-multi-select-wrapper .e-delim-values,.e-bigger .e-multiselect.e-filled:not(.e-float-input) .e-multi-select-wrapper .e-delim-values,.e-bigger.e-multiselect.e-filled.e-float-input .e-multi-select-wrapper .e-delim-values,.e-bigger .e-multiselect.e-filled.e-float-input .e-multi-select-wrapper .e-delim-values{font-size:16px;line-height:52px}.e-bigger.e-multiselect.e-filled.e-float-input .e-multi-select-wrapper .e-delim-values,.e-bigger .e-multiselect.e-filled.e-float-input .e-multi-select-wrapper .e-delim-values{line-height:36px}.e-bigger.e-small.e-filled.e-multiselect:not(.e-float-input) .e-multi-select-wrapper .e-chips,.e-bigger.e-small .e-filled.e-multiselect:not(.e-float-input) .e-multi-select-wrapper .e-chips,.e-bigger .e-small.e-filled.e-multiselect:not(.e-float-input) .e-multi-select-wrapper .e-chips,.e-small .e-bigger.e-filled.e-multiselect:not(.e-float-input) .e-multi-select-wrapper .e-chips{height:28px}.e-bigger.e-multiselect.e-filled.e-float-input .e-multi-select-wrapper .e-chips,.e-bigger .e-multiselect.e-filled.e-float-input .e-multi-select-wrapper .e-chips{height:24px}.e-bigger.e-multiselect.e-filled:not(.e-float-input) .e-multi-select-wrapper .e-chips,.e-bigger .e-multiselect.e-filled:not(.e-float-input) .e-multi-select-wrapper .e-chips{height:32px}.e-bigger.e-small.e-filled.e-float-input .e-multi-select-wrapper .e-chips,.e-bigger.e-small .e-filled.e-float-input .e-multi-select-wrapper .e-chips,.e-bigger .e-small.e-filled.e-float-input .e-multi-select-wrapper .e-chips,.e-small .e-bigger.e-filled.e-float-input .e-multi-select-wrapper .e-chips{height:18px}.e-bigger.e-small.e-filled.e-float-input .e-multi-select-wrapper .e-chips,.e-bigger.e-small .e-filled.e-float-input .e-multi-select-wrapper .e-chips,.e-bigger .e-small.e-filled.e-float-input .e-multi-select-wrapper .e-chips,.e-small .e-bigger.e-filled.e-float-input .e-multi-select-wrapper .e-chips,.e-bigger.e-small.e-filled:not(.e-float-input) .e-multi-select-wrapper .e-chips,.e-bigger.e-small .e-filled:not(.e-float-input) .e-multi-select-wrapper .e-chips,.e-bigger .e-small.e-filled:not(.e-float-input) .e-multi-select-wrapper .e-chips,.e-small .e-bigger.e-filled:not(.e-float-input) .e-multi-select-wrapper .e-chips{margin:8px 8px 0 0;padding:0 8px}.e-rtl.e-bigger.e-small.e-filled.e-float-input .e-multi-select-wrapper .e-chips,.e-rtl.e-bigger.e-small .e-filled.e-float-input .e-multi-select-wrapper .e-chips,.e-rtl.e-bigger .e-small.e-filled.e-float-input .e-multi-select-wrapper .e-chips,.e-rtl.e-small .e-bigger.e-filled.e-float-input .e-multi-select-wrapper .e-chips,.e-rtl.e-bigger.e-small.e-filled:not(.e-float-input) .e-multi-select-wrapper .e-chips,.e-rtl.e-bigger.e-small .e-filled:not(.e-float-input) .e-multi-select-wrapper .e-chips,.e-rtl.e-bigger .e-small.e-filled:not(.e-float-input) .e-multi-select-wrapper .e-chips,.e-rtl.e-small .e-bigger.e-filled:not(.e-float-input) .e-multi-select-wrapper .e-chips{margin:8px 0 0 8px;padding:0 8px}.e-bigger.e-small.e-filled.e-float-input .e-multi-select-wrapper .e-chips,.e-bigger.e-small .e-filled.e-float-input .e-multi-select-wrapper .e-chips,.e-bigger .e-small.e-filled.e-float-input .e-multi-select-wrapper .e-chips,.e-small .e-bigger.e-filled.e-float-input .e-multi-select-wrapper .e-chips{padding-left:8px}.e-small.e-filled:not(.e-bigger).e-multiselect:not(.e-float-input) .e-multi-select-wrapper .e-chips:not(.e-mob-chip) .e-chips-close,.e-small .e-filled:not(.e-bigger).e-multiselect:not(.e-float-input) .e-multi-select-wrapper .e-chips:not(.e-mob-chip) .e-chips-close,.e-bigger.e-small.e-filled.e-multiselect.e-float-input .e-multi-select-wrapper .e-chips:not(.e-mob-chip) .e-chips-close,.e-bigger.e-small .e-filled.e-multiselect.e-float-input .e-multi-select-wrapper .e-chips:not(.e-mob-chip) .e-chips-close,.e-bigger .e-small.e-filled.e-multiselect.e-float-input .e-multi-select-wrapper .e-chips:not(.e-mob-chip) .e-chips-close,.e-small .e-bigger.e-filled.e-multiselect.e-float-input .e-multi-select-wrapper .e-chips:not(.e-mob-chip) .e-chips-close{height:12px;width:12px}.e-bigger.e-small.e-filled.e-multiselect:not(.e-float-input) .e-multi-select-wrapper .e-chips>.e-chipcontent,.e-bigger.e-small .e-filled.e-multiselect:not(.e-float-input) .e-multi-select-wrapper .e-chips>.e-chipcontent,.e-bigger .e-small.e-filled.e-multiselect:not(.e-float-input) .e-multi-select-wrapper .e-chips>.e-chipcontent,.e-small .e-bigger.e-filled.e-multiselect:not(.e-float-input) .e-multi-select-wrapper .e-chips>.e-chipcontent{font-size:13px;padding:0 8px 0 0}.e-bigger.e-small.e-filled.e-float-input.e-multiselect .e-multi-select-wrapper .e-chips>.e-chipcontent,.e-bigger.e-small .e-filled.e-float-input.e-multiselect .e-multi-select-wrapper .e-chips>.e-chipcontent,.e-bigger .e-small.e-filled.e-float-input.e-multiselect .e-multi-select-wrapper .e-chips>.e-chipcontent,.e-small .e-bigger.e-filled.e-float-input.e-multiselect .e-multi-select-wrapper .e-chips>.e-chipcontent{font-size:12px;padding:0 4px 0 0}.e-rtl.e-bigger.e-small.e-filled.e-multiselect .e-multi-select-wrapper .e-chips>.e-chipcontent,.e-rtl.e-bigger.e-small .e-filled.e-multiselect .e-multi-select-wrapper .e-chips>.e-chipcontent,.e-rtl.e-bigger .e-small.e-filled.e-multiselect .e-multi-select-wrapper .e-chips>.e-chipcontent,.e-rtl.e-small .e-bigger.e-filled.e-multiselect .e-multi-select-wrapper .e-chips>.e-chipcontent{padding:0 0 0 4px}.e-bigger.e-filled.e-float-input.e-multiselect .e-multi-select-wrapper .e-chips>.e-chipcontent,.e-bigger .e-filled.e-float-input.e-multiselect .e-multi-select-wrapper .e-chips>.e-chipcontent{font-size:13px}.e-bigger.e-filled.e-multiselect:not(.e-float-input) .e-multi-select-wrapper .e-chips>.e-chipcontent,.e-bigger .e-filled.e-multiselect:not(.e-float-input) .e-multi-select-wrapper .e-chips>.e-chipcontent{font-size:14px}.e-rtl.e-bigger.e-filled .e-multi-select-wrapper .e-chips,.e-rtl.e-bigger .e-filled .e-multi-select-wrapper .e-chips,.e-rtl.e-bigger.e-filled.e-float-input .e-multi-select-wrapper .e-chips,.e-rtl.e-bigger .e-filled.e-float-input .e-multi-select-wrapper .e-chips,.e-bigger.e-filled .e-multi-select-wrapper .e-chips,.e-bigger .e-filled .e-multi-select-wrapper .e-chips{padding:0 12px}.e-bigger.e-filled.e-float-input .e-multi-select-wrapper .e-chips,.e-bigger .e-filled.e-float-input .e-multi-select-wrapper .e-chips{padding-right:8px}.e-bigger.e-small .e-multi-select-wrapper .e-chips .e-chips-close:before{font-size:16px}.e-bigger.e-small .e-multi-select-wrapper .e-chips{height:22px}.e-bigger.e-small .e-multi-select-wrapper .e-chips>.e-chipcontent{font-size:13px}.e-small.e-bigger .e-multi-select-wrapper .e-close-hooker:before{left:6px}.e-bigger .e-multi-select-wrapper .e-chips{height:28px}.e-bigger.e-small.e-multiselect.e-outline .e-multi-select-wrapper .e-chips-close.e-close-hooker,.e-bigger.e-small .e-multiselect.e-outline .e-multi-select-wrapper .e-chips-close.e-close-hooker,.e-bigger .e-small.e-multiselect.e-outline .e-multi-select-wrapper .e-chips-close.e-close-hooker,.e-small .e-bigger.e-multiselect.e-outline .e-multi-select-wrapper .e-chips-close.e-close-hooker{height:38px;margin-top:-55px;right:12px;top:100%;width:18px}.e-bigger.e-small.e-multiselect.e-outline .e-multi-select-wrapper.e-down-icon .e-chips-close.e-close-hooker,.e-bigger.e-small .e-multiselect.e-outline .e-multi-select-wrapper.e-down-icon .e-chips-close.e-close-hooker,.e-bigger .e-small.e-multiselect.e-outline .e-multi-select-wrapper.e-down-icon .e-chips-close.e-close-hooker,.e-small .e-bigger.e-multiselect.e-outline .e-multi-select-wrapper.e-down-icon .e-chips-close.e-close-hooker,.e-bigger.e-small.e-multiselect.e-filled .e-multi-select-wrapper.e-down-icon .e-chips-close.e-close-hooker,.e-bigger.e-small .e-multiselect.e-filled .e-multi-select-wrapper.e-down-icon .e-chips-close.e-close-hooker,.e-bigger .e-small.e-multiselect.e-filled .e-multi-select-wrapper.e-down-icon .e-chips-close.e-close-hooker,.e-small .e-bigger.e-multiselect.e-filled .e-multi-select-wrapper.e-down-icon .e-chips-close.e-close-hooker{right:48px}.e-bigger.e-multiselect.e-outline .e-multi-select-wrapper .e-chips-close.e-close-hooker,.e-bigger .e-multiselect.e-outline .e-multi-select-wrapper .e-chips-close.e-close-hooker{height:54px;margin-top:-55px;right:16px;top:100%;width:20px}.e-bigger.e-multiselect.e-outline .e-multi-select-wrapper.e-down-icon .e-chips-close.e-close-hooker,.e-bigger .e-multiselect.e-outline .e-multi-select-wrapper.e-down-icon .e-chips-close.e-close-hooker{right:60px}.e-rtl.e-bigger.e-small.e-multiselect.e-outline .e-multi-select-wrapper .e-chips-close.e-close-hooker,.e-rtl.e-bigger.e-small .e-multiselect.e-outline .e-multi-select-wrapper .e-chips-close.e-close-hooker,.e-rtl .e-bigger.e-small.e-multiselect.e-outline .e-multi-select-wrapper .e-chips-close.e-close-hooker,.e-bigger.e-small .e-rtl.e-multiselect.e-outline .e-multi-select-wrapper .e-chips-close.e-close-hooker,.e-rtl.e-bigger .e-small.e-multiselect.e-outline .e-multi-select-wrapper .e-chips-close.e-close-hooker,.e-rtl .e-bigger .e-small.e-multiselect.e-outline .e-multi-select-wrapper .e-chips-close.e-close-hooker,.e-bigger .e-rtl.e-small.e-multiselect.e-outline .e-multi-select-wrapper .e-chips-close.e-close-hooker,.e-bigger .e-rtl .e-small.e-multiselect.e-outline .e-multi-select-wrapper .e-chips-close.e-close-hooker,.e-rtl.e-small .e-bigger.e-multiselect.e-outline .e-multi-select-wrapper .e-chips-close.e-close-hooker,.e-rtl .e-small .e-bigger.e-multiselect.e-outline .e-multi-select-wrapper .e-chips-close.e-close-hooker,.e-small .e-rtl .e-bigger.e-multiselect.e-outline .e-multi-select-wrapper .e-chips-close.e-close-hooker,.e-small .e-rtl.e-bigger.e-multiselect.e-outline .e-multi-select-wrapper .e-chips-close.e-close-hooker,.e-rtl.e-bigger.e-small.e-multiselect.e-filled .e-multi-select-wrapper.e-down-icon .e-chips-close.e-close-hooker,.e-rtl.e-bigger.e-small .e-multiselect.e-filled .e-multi-select-wrapper.e-down-icon .e-chips-close.e-close-hooker,.e-rtl .e-bigger.e-small.e-multiselect.e-filled .e-multi-select-wrapper.e-down-icon .e-chips-close.e-close-hooker,.e-bigger.e-small .e-rtl.e-multiselect.e-filled .e-multi-select-wrapper.e-down-icon .e-chips-close.e-close-hooker,.e-rtl.e-bigger .e-small.e-multiselect.e-filled .e-multi-select-wrapper.e-down-icon .e-chips-close.e-close-hooker,.e-rtl .e-bigger .e-small.e-multiselect.e-filled .e-multi-select-wrapper.e-down-icon .e-chips-close.e-close-hooker,.e-bigger .e-rtl.e-small.e-multiselect.e-filled .e-multi-select-wrapper.e-down-icon .e-chips-close.e-close-hooker,.e-bigger .e-rtl .e-small.e-multiselect.e-filled .e-multi-select-wrapper.e-down-icon .e-chips-close.e-close-hooker,.e-rtl.e-small .e-bigger.e-multiselect.e-filled .e-multi-select-wrapper.e-down-icon .e-chips-close.e-close-hooker,.e-rtl .e-small .e-bigger.e-multiselect.e-filled .e-multi-select-wrapper.e-down-icon .e-chips-close.e-close-hooker,.e-small .e-rtl .e-bigger.e-multiselect.e-filled .e-multi-select-wrapper.e-down-icon .e-chips-close.e-close-hooker,.e-small .e-rtl.e-bigger.e-multiselect.e-filled .e-multi-select-wrapper.e-down-icon .e-chips-close.e-close-hooker{left:48px;right:auto}.e-rtl.e-bigger.e-multiselect.e-outline .e-multi-select-wrapper .e-chips-close.e-close-hooker,.e-rtl.e-bigger .e-multiselect.e-outline .e-multi-select-wrapper .e-chips-close.e-close-hooker,.e-rtl .e-bigger.e-multiselect.e-outline .e-multi-select-wrapper .e-chips-close.e-close-hooker,.e-rtl .e-bigger .e-multiselect.e-outline .e-multi-select-wrapper .e-chips-close.e-close-hooker,.e-bigger .e-rtl.e-multiselect.e-outline .e-multi-select-wrapper .e-chips-close.e-close-hooker,.e-bigger .e-rtl .e-multiselect.e-outline .e-multi-select-wrapper .e-chips-close.e-close-hooker,.e-rtl.e-bigger.e-multiselect.e-filled .e-multi-select-wrapper.e-down-icon .e-chips-close.e-close-hooker,.e-rtl.e-bigger .e-multiselect.e-filled .e-multi-select-wrapper.e-down-icon .e-chips-close.e-close-hooker,.e-rtl .e-bigger.e-multiselect.e-filled .e-multi-select-wrapper.e-down-icon .e-chips-close.e-close-hooker,.e-rtl .e-bigger .e-multiselect.e-filled .e-multi-select-wrapper.e-down-icon .e-chips-close.e-close-hooker,.e-bigger .e-rtl.e-multiselect.e-filled .e-multi-select-wrapper.e-down-icon .e-chips-close.e-close-hooker,.e-bigger .e-rtl .e-multiselect.e-filled .e-multi-select-wrapper.e-down-icon .e-chips-close.e-close-hooker{left:60px;right:auto}.e-bigger.e-multiselect.e-outline .e-multi-select-wrapper .e-close-hooker:before,.e-bigger .e-multiselect.e-outline .e-multi-select-wrapper .e-close-hooker:before{content:"\e208";font-size:20px;height:20px;left:0;margin-top:-10px;top:50%}.e-bigger.e-small.e-multiselect.e-outline .e-multi-select-wrapper .e-close-hooker:before,.e-bigger.e-small .e-multiselect.e-outline .e-multi-select-wrapper .e-close-hooker:before,.e-bigger .e-small.e-multiselect.e-outline .e-multi-select-wrapper .e-close-hooker:before,.e-small .e-bigger.e-multiselect.e-outline .e-multi-select-wrapper .e-close-hooker:before{content:"\e208";font-size:18px;height:18px;left:0;margin-top:-9px;top:50%}.e-bigger .e-multiselect.e-outline .e-multi-select-wrapper .e-chips .e-chips-close:before,.e-bigger.e-multiselect.e-outline .e-multi-select-wrapper .e-chips .e-chips-close:before{font-size:16px}.e-bigger.e-small .e-multiselect.e-outline .e-multi-select-wrapper .e-chips .e-chips-close:before,.e-bigger.e-small.e-multiselect.e-outline .e-multi-select-wrapper .e-chips .e-chips-close:before,.e-bigger .e-small.e-multiselect.e-outline .e-multi-select-wrapper .e-chips .e-chips-close:before,.e-small .e-bigger.e-multiselect.e-outline .e-multi-select-wrapper .e-chips .e-chips-close:before{font-size:14px}.e-multiselect.e-input-group.e-outline.e-bigger .e-multi-select-wrapper .e-input-group-icon.e-ddl-icon,.e-bigger .e-multiselect.e-input-group.e-outline .e-multi-select-wrapper .e-input-group-icon.e-ddl-icon,.e-multiselect.e-input-group.e-outline.e-control-wrapper.e-bigger .e-multi-select-wrapper .e-input-group-icon.e-ddl-icon,.e-bigger .e-multiselect.e-input-group.e-outline.e-control-wrapper .e-multi-select-wrapper .e-input-group-icon.e-ddl-icon{margin:10px 16px 10px 0}.e-multiselect.e-input-group.e-outline.e-small.e-bigger .e-multi-select-wrapper .e-input-group-icon.e-ddl-icon,.e-bigger.e-small .e-multiselect.e-input-group.e-outline .e-multi-select-wrapper .e-input-group-icon.e-ddl-icon,.e-multiselect.e-input-group.e-outline.e-control-wrapper.e-small.e-bigger .e-multi-select-wrapper .e-input-group-icon.e-ddl-icon,.e-small.e-bigger .e-multiselect.e-input-group.e-outline.e-control-wrapper .e-multi-select-wrapper .e-input-group-icon.e-ddl-icon,.e-bigger .e-multiselect.e-input-group.e-outline.e-small .e-multi-select-wrapper .e-input-group-icon.e-ddl-icon,.e-bigger .e-multiselect.e-input-group.e-outline.e-control-wrapper.e-small .e-multi-select-wrapper .e-input-group-icon.e-ddl-icon,.e-small .e-multiselect.e-input-group.e-outline.e-bigger .e-multi-select-wrapper .e-input-group-icon.e-ddl-icon,.e-small .e-multiselect.e-input-group.e-outline.e-control-wrapper.e-bigger .e-multi-select-wrapper .e-input-group-icon.e-ddl-icon{margin:6px 12px 8px 0}.e-rtl.e-multiselect.e-input-group.e-outline.e-bigger .e-multi-select-wrapper .e-input-group-icon.e-ddl-icon,.e-bigger .e-rtl.e-multiselect.e-input-group.e-outline .e-multi-select-wrapper .e-input-group-icon.e-ddl-icon,.e-rtl.e-multiselect.e-input-group.e-outline.e-control-wrapper.e-bigger .e-multi-select-wrapper .e-input-group-icon.e-ddl-icon,.e-bigger .e-rtl.e-multiselect.e-input-group.e-outline.e-control-wrapper .e-multi-select-wrapper .e-input-group-icon.e-ddl-icon,.e-rtl .e-multiselect.e-input-group.e-outline.e-bigger .e-multi-select-wrapper .e-input-group-icon.e-ddl-icon,.e-bigger.e-rtl .e-multiselect.e-input-group.e-outline .e-multi-select-wrapper .e-input-group-icon.e-ddl-icon,.e-rtl .e-multiselect.e-input-group.e-outline.e-control-wrapper.e-bigger .e-multi-select-wrapper .e-input-group-icon.e-ddl-icon,.e-bigger.e-rtl .e-multiselect.e-input-group.e-outline.e-control-wrapper .e-multi-select-wrapper .e-input-group-icon.e-ddl-icon{margin:10px 0 10px 16px}.e-rtl.e-multiselect.e-input-group.e-outline.e-small.e-bigger .e-multi-select-wrapper .e-input-group-icon.e-ddl-icon,.e-bigger.e-small .e-rtl.e-multiselect.e-input-group.e-outline .e-multi-select-wrapper .e-input-group-icon.e-ddl-icon,.e-rtl.e-multiselect.e-input-group.e-outline.e-control-wrapper.e-small.e-bigger .e-multi-select-wrapper .e-input-group-icon.e-ddl-icon,.e-small.e-bigger .e-rtl.e-multiselect.e-input-group.e-outline.e-control-wrapper .e-multi-select-wrapper .e-input-group-icon.e-ddl-icon,.e-bigger .e-rtl.e-multiselect.e-input-group.e-outline.e-small .e-multi-select-wrapper .e-input-group-icon.e-ddl-icon,.e-bigger .e-rtl.e-multiselect.e-input-group.e-outline.e-control-wrapper.e-small .e-multi-select-wrapper .e-input-group-icon.e-ddl-icon,.e-small .e-rtl.e-multiselect.e-input-group.e-outline.e-bigger .e-multi-select-wrapper .e-input-group-icon.e-ddl-icon,.e-small .e-rtl.e-multiselect.e-input-group.e-outline.e-control-wrapper.e-bigger .e-multi-select-wrapper .e-input-group-icon.e-ddl-icon,.e-rtl .e-multiselect.e-input-group.e-outline.e-small.e-bigger .e-multi-select-wrapper .e-input-group-icon.e-ddl-icon,.e-rtl.e-bigger.e-small .e-multiselect.e-input-group.e-outline .e-multi-select-wrapper .e-input-group-icon.e-ddl-icon,.e-rtl .e-multiselect.e-input-group.e-outline.e-control-wrapper.e-small.e-bigger .e-multi-select-wrapper .e-input-group-icon.e-ddl-icon,.e-rtl.e-small.e-bigger .e-multiselect.e-input-group.e-outline.e-control-wrapper .e-multi-select-wrapper .e-input-group-icon.e-ddl-icon,.e-rtl.e-bigger .e-multiselect.e-input-group.e-outline.e-small .e-multi-select-wrapper .e-input-group-icon.e-ddl-icon,.e-rtl.e-bigger .e-multiselect.e-input-group.e-outline.e-control-wrapper.e-small .e-multi-select-wrapper .e-input-group-icon.e-ddl-icon,.e-rtl.e-small .e-multiselect.e-input-group.e-outline.e-bigger .e-multi-select-wrapper .e-input-group-icon.e-ddl-icon,.e-rtl.e-small .e-multiselect.e-input-group.e-outline.e-control-wrapper.e-bigger .e-multi-select-wrapper .e-input-group-icon.e-ddl-icon{margin:6px 0 8px 12px}.e-bigger.e-small.e-filled .e-multi-select-wrapper .e-chips-close.e-close-hooker,.e-bigger.e-small .e-filled .e-multi-select-wrapper .e-chips-close.e-close-hooker,.e-bigger .e-small.e-filled .e-multi-select-wrapper .e-chips-close.e-close-hooker,.e-small .e-bigger.e-filled .e-multi-select-wrapper .e-chips-close.e-close-hooker{height:20px;margin-top:-33px;right:18px;width:20px}.e-bigger.e-small.e-filled.e-multiselect .e-down-icon .e-chips-close.e-close-hooker,.e-bigger.e-small .e-filled.e-multiselect .e-down-icon .e-chips-close.e-close-hooker,.e-bigger .e-small.e-filled.e-multiselect .e-down-icon .e-chips-close.e-close-hooker,.e-small .e-bigger.e-filled.e-multiselect .e-down-icon .e-chips-close.e-close-hooker{height:20px;margin-top:-35px;right:45px;width:20px}.e-bigger.e-small.e-filled.e-float-input .e-multi-select-wrapper .e-chips-close.e-close-hooker,.e-bigger.e-small .e-filled.e-float-input .e-multi-select-wrapper .e-chips-close.e-close-hooker,.e-bigger .e-small.e-filled.e-float-input .e-multi-select-wrapper .e-chips-close.e-close-hooker,.e-small .e-bigger.e-filled.e-float-input .e-multi-select-wrapper .e-chips-close.e-close-hooker,.e-bigger.e-small.e-filled.e-float-input.e-multiselect .e-down-icon .e-chips-close.e-close-hooker,.e-bigger.e-small .e-filled.e-float-input.e-multiselect .e-down-icon .e-chips-close.e-close-hooker,.e-bigger .e-small.e-filled.e-float-input.e-multiselect .e-down-icon .e-chips-close.e-close-hooker,.e-small .e-bigger.e-filled.e-float-input.e-multiselect .e-down-icon .e-chips-close.e-close-hooker{margin-top:-32px}.e-bigger.e-filled .e-multi-select-wrapper .e-chips-close.e-close-hooker,.e-bigger .e-filled .e-multi-select-wrapper .e-chips-close.e-close-hooker{height:24px;width:24px}.e-bigger.e-filled.e-float-input .e-multi-select-wrapper .e-chips-close.e-close-hooker,.e-bigger .e-filled.e-float-input.e-multiselect .e-down-icon .e-chips-close.e-close-hooker{margin-top:-40px}.e-bigger.e-small.e-filled.e-float-input.e-multiselect .e-down-icon .e-chips-close.e-close-hooker,.e-bigger.e-small .e-filled.e-float-input.e-multiselect .e-down-icon .e-chips-close.e-close-hooker,.e-bigger .e-small.e-filled.e-float-input.e-multiselect .e-down-icon .e-chips-close.e-close-hooker,.e-small .e-bigger.e-filled.e-float-input.e-multiselect .e-down-icon .e-chips-close.e-close-hooker,.e-bigger.e-small.e-filled.e-float-input .e-multi-select-wrapper .e-chips-close.e-close-hooker,.e-bigger.e-small .e-filled.e-float-input .e-multi-select-wrapper .e-chips-close.e-close-hooker,.e-bigger .e-small.e-filled.e-float-input .e-multi-select-wrapper .e-chips-close.e-close-hooker,.e-small .e-bigger.e-filled.e-float-input .e-multi-select-wrapper .e-chips-close.e-close-hooker{margin-top:-32px;right:40px}.e-bigger.e-filled .e-multi-select-wrapper .e-chips-close.e-close-hooker,.e-bigger .e-filled.e-multiselect .e-down-icon .e-chips-close.e-close-hooker{margin-top:-44px}.e-bigger.e-filled.e-multiselect.e-float-input .e-multi-select-wrapper .e-chips:not(.e-mob-chip) .e-chips-close,.e-bigger .e-filled.e-multiselect.e-float-input .e-multi-select-wrapper .e-chips:not(.e-mob-chip) .e-chips-close,.e-filled.e-multiselect:not(.e-float-input) .e-multi-select-wrapper .e-chips:not(.e-mob-chip) .e-chips-close{height:14px;width:14px}.e-bigger.e-filled.e-multiselect:not(.e-float-input) .e-multi-select-wrapper .e-chips:not(.e-mob-chip) .e-chips-close,.e-bigger .e-filled.e-multiselect:not(.e-float-input) .e-multi-select-wrapper .e-chips:not(.e-mob-chip) .e-chips-close{height:16px;width:16px}.e-bigger.e-small.e-multiselect.e-filled.e-float-input .e-multi-select-wrapper .e-chips .e-chips-close:before,.e-bigger.e-small .e-multiselect.e-filled.e-float-input .e-multi-select-wrapper .e-chips .e-chips-close:before,.e-bigger .e-small.e-multiselect.e-filled.e-float-input .e-multi-select-wrapper .e-chips .e-chips-close:before,.e-small.e-bigger.e-multiselect.e-filled.e-float-input .e-multi-select-wrapper .e-chips .e-chips-close:before{font-size:12px;height:12px;width:12px}.e-bigger.e-filled.e-float-input .e-multi-select-wrapper .e-chips .e-chips-close:before,.e-bigger .e-filled.e-float-input .e-multi-select-wrapper .e-chips .e-chips-close:before,.e-bigger.e-small.e-multiselect.e-filled:not(.e-float-input) .e-multi-select-wrapper .e-chips .e-chips-close:before,.e-bigger.e-small .e-multiselect.e-filled:not(.e-float-input) .e-multi-select-wrapper .e-chips .e-chips-close:before,.e-bigger .e-small.e-multiselect.e-filled:not(.e-float-input) .e-multi-select-wrapper .e-chips .e-chips-close:before,.e-small .e-bigger.e-multiselect.e-filled:not(.e-float-input) .e-multi-select-wrapper .e-chips .e-chips-close:before{font-size:14px;height:14px;width:14px}.e-bigger.e-filled .e-multi-select-wrapper .e-chips-close.e-close-hooker:before,.e-bigger .e-filled .e-multi-select-wrapper .e-chips-close.e-close-hooker:before{font-size:20px;height:20px;width:20px}.e-bigger.e-small.e-rtl.e-multiselect.e-filled .e-multi-select-wrapper .e-chips-close.e-close-hooker,.e-bigger.e-small .e-rtl .e-multiselect.e-filled .e-multi-select-wrapper .e-chips-close.e-close-hooker{left:10px;right:auto}.e-bigger.e-rtl.e-multiselect.e-filled .e-multi-select-wrapper .e-chips-close.e-close-hooker,.e-rtl .e-bigger.e-multiselect.e-filled .e-multi-select-wrapper .e-chips-close.e-close-hooker,.e-bigger .e-rtl.e-multiselect.e-filled .e-multi-select-wrapper .e-chips-close.e-close-hooker,.e-rtl.e-bigger .e-multiselect.e-filled .e-multi-select-wrapper .e-chips-close.e-close-hooker{left:12px;right:auto}.e-bigger.e-multiselect.e-input-group.e-filled .e-multi-select-wrapper .e-input-group-icon.e-ddl-icon,.e-bigger .e-multiselect.e-filled.e-input-group.e-control-wrapper .e-multi-select-wrapper .e-input-group-icon.e-ddl-icon{height:24px;margin:12px -4px 8px -1px;padding:0;width:24px}.e-bigger.e-multiselect.e-input-group.e-filled.e-float-input .e-multi-select-wrapper .e-input-group-icon.e-ddl-icon,.e-bigger .e-multiselect.e-filled.e-input-group.e-control-wrapper.e-float-input .e-multi-select-wrapper .e-input-group-icon.e-ddl-icon{margin:0}.e-bigger.e-small.e-multiselect.e-input-group.e-float-input.e-filled .e-multi-select-wrapper .e-input-group-icon.e-ddl-icon,.e-bigger.e-small .e-multiselect.e-input-group.e-float-input.e-filled .e-multi-select-wrapper .e-input-group-icon.e-ddl-icon,.e-bigger .e-small.e-multiselect.e-input-group.e-float-input.e-filled .e-multi-select-wrapper .e-input-group-icon.e-ddl-icon,.e-small .e-bigger.e-multiselect.e-input-group.e-float-input.e-filled .e-multi-select-wrapper .e-input-group-icon.e-ddl-icon{height:20px;margin:0 0 8px;padding:0;width:20px}.e-bigger.e-multiselect.e-input-group.e-filled .e-multi-select-wrapper .e-input-group-icon.e-ddl-icon:before,.e-bigger .e-multiselect.e-filled.e-input-group.e-control-wrapper .e-multi-select-wrapper .e-input-group-icon.e-ddl-icon:before{font-size:20px;height:20px;width:20px}.e-bigger.e-small.e-multiselect.e-filled.e-input-group.e-control-wrapper .e-multi-select-wrapper .e-input-group-icon.e-ddl-icon:before,.e-bigger .e-small .e-multiselect.e-filled.e-input-group.e-control-wrapper .e-multi-select-wrapper .e-input-group-icon.e-ddl-icon:before,.e-small.e-bigger.e-multiselect.e-filled.e-input-group.e-control-wrapper .e-multi-select-wrapper .e-input-group-icon.e-ddl-icon:before,.e-small .e-bigger.e-multiselect.e-filled.e-input-group.e-control-wrapper .e-multi-select-wrapper .e-input-group-icon.e-ddl-icon:before{font-size:18px;height:18px;width:18px}.e-bigger.e-small.e-multiselect.e-filled.e-input-group.e-control-wrapper:not(.e-float-input) .e-multi-select-wrapper .e-input-group-icon.e-ddl-icon,.e-bigger .e-small .e-multiselect.e-filled.e-input-group.e-control-wrapper:not(.e-float-input) .e-multi-select-wrapper .e-input-group-icon.e-ddl-icon,.e-small.e-bigger.e-multiselect.e-filled.e-input-group.e-control-wrapper:not(.e-float-input) .e-multi-select-wrapper .e-input-group-icon.e-ddl-icon,.e-small .e-bigger.e-multiselect.e-filled.e-input-group.e-control-wrapper:not(.e-float-input) .e-multi-select-wrapper .e-input-group-icon.e-ddl-icon{height:24px;margin:7px -4px 8px -1px;padding:0;width:24px}.e-small.e-bigger.e-multiselect.e-outline .e-multi-select-wrapper .e-close-hooker.e-ddl-disable-icon:before,.e-small.e-bigger .e-multiselect.e-outline .e-multi-select-wrapper .e-close-hooker.e-ddl-disable-icon:before,.e-small .e-bigger.e-multiselect.e-outline .e-multi-select-wrapper .e-close-hooker.e-ddl-disable-icon:before,.e-bigger.e-small.e-multiselect.e-outline .e-multi-select-wrapper .e-close-hooker.e-ddl-disable-icon:before,.e-bigger.e-small .e-multiselect.e-outline .e-multi-select-wrapper .e-close-hooker.e-ddl-disable-icon:before,.e-bigger .e-small.e-multiselect.e-outline .e-multi-select-wrapper .e-close-hooker.e-ddl-disable-icon:before,.e-bigger.e-multiselect.e-outline .e-multi-select-wrapper .e-close-hooker.e-ddl-disable-icon:before,.e-bigger .e-multiselect.e-outline .e-multi-select-wrapper .e-close-hooker.e-ddl-disable-icon:before{content:""}.e-listbox-tool .e-moveup:before{content:"\e651"}.e-listbox-tool .e-movedown:before{content:"\e652"}.e-listbox-tool .e-moveto:before{content:"\e653"}.e-listbox-tool .e-movefrom:before{content:"\e654"}.e-listbox-tool .e-moveallto:before{content:"\e655"}.e-listbox-tool .e-moveallfrom:before{content:"\e656"}.e-listbox-wrapper,.e-listbox-container,.e-listboxtool-wrapper{-webkit-overflow-scrolling:touch;box-sizing:border-box;cursor:pointer;display:block;position:relative;-webkit-user-select:none;user-select:none;width:100%}.e-listbox-wrapper *,.e-listbox-container *,.e-listboxtool-wrapper *{box-sizing:border-box}.e-listbox-wrapper.e-listboxtool-container .e-list-wrap,.e-listbox-container.e-listboxtool-container .e-list-wrap,.e-listboxtool-wrapper.e-listboxtool-container .e-list-wrap{width:86%!important}.e-listbox-wrapper .e-list-wrap:focus-visible,.e-listbox-wrapper:focus,.e-listbox-container .e-list-wrap:focus-visible,.e-listbox-container:focus,.e-listboxtool-wrapper .e-list-wrap:focus-visible,.e-listboxtool-wrapper:focus{outline:none}.e-listbox-wrapper.e-disabled,.e-listbox-container.e-disabled,.e-listboxtool-wrapper.e-disabled{cursor:default;pointer-events:none}.e-listbox-wrapper:not(.e-list-template) .e-list-nrt,.e-listbox-container:not(.e-list-template) .e-list-nrt,.e-listboxtool-wrapper:not(.e-list-template) .e-list-nrt{text-align:center}.e-listbox-wrapper .e-list-parent,.e-listbox-container .e-list-parent,.e-listboxtool-wrapper .e-list-parent{height:100%;min-height:36px}.e-listbox-wrapper .e-list-item,.e-listbox-container .e-list-item,.e-listboxtool-wrapper .e-list-item{border-bottom:0 solid;outline:none}.e-listbox-wrapper .e-list-item.e-disabled,.e-listbox-container .e-list-item.e-disabled,.e-listboxtool-wrapper .e-list-item.e-disabled{pointer-events:none}.e-listbox-wrapper .e-disable,.e-listbox-container .e-disable,.e-listboxtool-wrapper .e-disable{opacity:.7}.e-listbox-wrapper .e-list-parent,.e-listbox-container .e-list-parent,.e-listboxtool-wrapper .e-list-parent{margin:0;padding:0}.e-listbox-wrapper .e-list-header .e-text.header,.e-listbox-wrapper .e-list-header .e-headertemplate-text.nested-header,.e-listbox-container .e-list-header .e-text.header,.e-listbox-container .e-list-header .e-headertemplate-text.nested-header,.e-listboxtool-wrapper .e-list-header .e-text.header,.e-listboxtool-wrapper .e-list-header .e-headertemplate-text.nested-header{display:none}.e-listbox-wrapper .e-icon-back,.e-listbox-container .e-icon-back,.e-listboxtool-wrapper .e-icon-back{margin-top:2px}.e-listbox-wrapper .e-list-header,.e-listbox-container .e-list-header,.e-listboxtool-wrapper .e-list-header{align-items:center;border-bottom:1px solid;display:flex;font-weight:700;height:48px;padding:0 16px}.e-listbox-wrapper .e-has-header>.e-view,.e-listbox-container .e-has-header>.e-view,.e-listboxtool-wrapper .e-has-header>.e-view{top:45px}.e-listbox-wrapper .e-but-back,.e-listbox-container .e-but-back,.e-listboxtool-wrapper .e-but-back{cursor:pointer;padding-right:30px}.e-listbox-wrapper .e-list-group-item:first-child,.e-listbox-container .e-list-group-item:first-child,.e-listboxtool-wrapper .e-list-group-item:first-child{border:0;border-bottom:0 solid transparent}.e-listbox-wrapper .e-list-group-item,.e-listbox-container .e-list-group-item,.e-listboxtool-wrapper .e-list-group-item{border-bottom:0 solid transparent;border-top:1px solid;font-weight:600;height:36px;line-height:16px;padding:11px 16px}.e-listbox-wrapper .e-icon-collapsible,.e-listbox-container .e-icon-collapsible,.e-listboxtool-wrapper .e-icon-collapsible{cursor:pointer;font-size:12px;position:absolute;right:0%;top:50%;transform:translateY(-50%)}.e-listbox-wrapper .e-text-content,.e-listbox-container .e-text-content,.e-listboxtool-wrapper .e-text-content{height:100%;position:relative;vertical-align:middle}.e-listbox-wrapper .e-text-content *,.e-listbox-container .e-text-content *,.e-listboxtool-wrapper .e-text-content *{display:inline-block;vertical-align:middle}.e-listbox-wrapper .e-text-content.e-checkbox .e-list-text,.e-listbox-container .e-text-content.e-checkbox .e-list-text,.e-listboxtool-wrapper .e-text-content.e-checkbox .e-list-text{width:calc(100% - 40px)}.e-listbox-wrapper .e-text-content.e-checkbox.e-checkbox-left .e-list-icon+.e-list-text,.e-listbox-container .e-text-content.e-checkbox.e-checkbox-left .e-list-icon+.e-list-text,.e-listboxtool-wrapper .e-text-content.e-checkbox.e-checkbox-left .e-list-icon+.e-list-text{width:calc(100% - 90px)}.e-listbox-wrapper .e-text-content.e-checkbox.e-checkbox-right .e-list-icon+.e-list-text,.e-listbox-container .e-text-content.e-checkbox.e-checkbox-right .e-list-icon+.e-list-text,.e-listboxtool-wrapper .e-text-content.e-checkbox.e-checkbox-right .e-list-icon+.e-list-text{width:calc(100% - 80px)}.e-listbox-wrapper .e-list-item.e-checklist.e-has-child .e-text-content.e-checkbox.e-checkbox-right .e-list-icon+.e-list-text,.e-listbox-container .e-list-item.e-checklist.e-has-child .e-text-content.e-checkbox.e-checkbox-right .e-list-icon+.e-list-text,.e-listboxtool-wrapper .e-list-item.e-checklist.e-has-child .e-text-content.e-checkbox.e-checkbox-right .e-list-icon+.e-list-text{width:calc(100% - 92px)}.e-listbox-wrapper .e-checkbox .e-checkbox-left,.e-listbox-container .e-checkbox .e-checkbox-left,.e-listboxtool-wrapper .e-checkbox .e-checkbox-left{margin:-2px 10px 0 0}.e-listbox-wrapper .e-checkbox .e-checkbox-right,.e-listbox-container .e-checkbox .e-checkbox-right,.e-listboxtool-wrapper .e-checkbox .e-checkbox-right{margin:-2px 0 0 10px}.e-listbox-wrapper .e-list-text,.e-listbox-container .e-list-text,.e-listboxtool-wrapper .e-list-text{cursor:pointer;display:inline-block;overflow:hidden;text-overflow:ellipsis;vertical-align:top;white-space:nowrap;width:100%}.e-listbox-wrapper .e-list-icon+.e-list-text,.e-listbox-wrapper .e-icon-wrapper .e-list-text,.e-listbox-wrapper .e-icon-wrapper.e-text-content.e-checkbox .e-list-text,.e-listbox-container .e-list-icon+.e-list-text,.e-listbox-container .e-icon-wrapper .e-list-text,.e-listbox-container .e-icon-wrapper.e-text-content.e-checkbox .e-list-text,.e-listboxtool-wrapper .e-list-icon+.e-list-text,.e-listboxtool-wrapper .e-icon-wrapper .e-list-text,.e-listboxtool-wrapper .e-icon-wrapper.e-text-content.e-checkbox .e-list-text{width:calc(100% - 60px)}.e-listbox-wrapper .e-list-icon,.e-listbox-container .e-list-icon,.e-listboxtool-wrapper .e-list-icon{height:30px;margin-right:16px;width:30px}.e-listbox-wrapper .e-content,.e-listbox-container .e-content,.e-listboxtool-wrapper .e-content{overflow:hidden;position:relative}.e-listbox-wrapper .e-list-header .e-text,.e-listbox-container .e-list-header .e-text,.e-listboxtool-wrapper .e-list-header .e-text{cursor:pointer;text-indent:0}.e-listbox-wrapper .e-text .e-headertext,.e-listbox-container .e-text .e-headertext,.e-listboxtool-wrapper .e-text .e-headertext{display:inline-block;line-height:inherit}.e-listbox-wrapper.e-rtl,.e-listbox-container.e-rtl,.e-listboxtool-wrapper.e-rtl{direction:rtl}.e-listbox-wrapper.e-rtl .e-list-icon,.e-listbox-container.e-rtl .e-list-icon,.e-listboxtool-wrapper.e-rtl .e-list-icon{margin-left:16px;margin-right:0}.e-listbox-wrapper.e-rtl .e-icon-collapsible,.e-listbox-container.e-rtl .e-icon-collapsible,.e-listboxtool-wrapper.e-rtl .e-icon-collapsible{left:0%;right:initial;top:50%;transform:translateY(-50%) rotate(180deg)}.e-listbox-wrapper.e-rtl .e-list-header .e-text,.e-listbox-container.e-rtl .e-list-header .e-text,.e-listboxtool-wrapper.e-rtl .e-list-header .e-text{cursor:pointer}.e-listbox-wrapper.e-rtl .e-but-back,.e-listbox-container.e-rtl .e-but-back,.e-listboxtool-wrapper.e-rtl .e-but-back{transform:rotate(180deg)}.e-listbox-wrapper.e-rtl .e-icon-back,.e-listbox-container.e-rtl .e-icon-back,.e-listboxtool-wrapper.e-rtl .e-icon-back{margin-top:-2px}.e-listbox-wrapper.e-rtl .e-checkbox .e-checkbox-left,.e-listbox-wrapper.e-rtl .e-checkbox-wrapper,.e-listbox-container.e-rtl .e-checkbox .e-checkbox-left,.e-listbox-container.e-rtl .e-checkbox-wrapper,.e-listboxtool-wrapper.e-rtl .e-checkbox .e-checkbox-left,.e-listboxtool-wrapper.e-rtl .e-checkbox-wrapper{margin:-2px 0 0 10px}.e-listbox-wrapper.e-rtl .e-checkbox .e-checkbox-right,.e-listbox-container.e-rtl .e-checkbox .e-checkbox-right,.e-listboxtool-wrapper.e-rtl .e-checkbox .e-checkbox-right{margin:-2px 10px 0 0}.e-listbox-wrapper .e-checkbox-wrapper,.e-listbox-container .e-checkbox-wrapper,.e-listboxtool-wrapper .e-checkbox-wrapper{margin:-2px 10px 0 0;text-indent:0;vertical-align:middle}.e-listbox-wrapper.e-checkbox-right .e-checkbox-wrapper,.e-listbox-container.e-checkbox-right .e-checkbox-wrapper,.e-listboxtool-wrapper.e-checkbox-right .e-checkbox-wrapper{position:absolute;right:0;top:30%}.e-listbox-wrapper .e-input-group,.e-listbox-container .e-input-group,.e-listboxtool-wrapper .e-input-group{padding:4px 8px}.e-listbox-wrapper .e-input-focus,.e-listbox-container .e-input-focus,.e-listboxtool-wrapper .e-input-focus{padding:4px 4px 4px 8px}.e-listbox-wrapper .e-hidden-select,.e-listbox-container .e-hidden-select,.e-listboxtool-wrapper .e-hidden-select{height:1px;opacity:0;position:absolute;width:100%}.e-listbox-wrapper .e-placeholder,.e-listbox-container .e-placeholder,.e-listboxtool-wrapper .e-placeholder{background-color:#e3165b;display:block;height:1px}ejs-listbox{display:block}.e-listbox-wrapper:not(.e-listbox-container),.e-listbox-wrapper.e-filter-list .e-list-parent{overflow:auto}.e-listbox-wrapper.e-sortableclone,.e-listbox-container.e-sortableclone,.e-listboxtool-wrapper.e-sortableclone{border-width:0;overflow:visible}.e-listbox-wrapper.e-sortableclone .e-list-item,.e-listbox-container.e-sortableclone .e-list-item,.e-listboxtool-wrapper.e-sortableclone .e-list-item{list-style-type:none;height:38px!important}.e-listbox-wrapper.e-sortableclone .e-ripple,.e-listbox-container.e-sortableclone .e-ripple,.e-listboxtool-wrapper.e-sortableclone .e-ripple{overflow:visible}.e-listbox-wrapper.e-sortableclone .e-ripple .e-ripple-element,.e-listbox-container.e-sortableclone .e-ripple .e-ripple-element,.e-listboxtool-wrapper.e-sortableclone .e-ripple .e-ripple-element{display:none}.e-listbox-wrapper.e-sortableclone .e-list-badge,.e-listbox-container.e-sortableclone .e-list-badge,.e-listboxtool-wrapper.e-sortableclone .e-list-badge{align-items:center;background-color:#e3165b;border:1px solid #fff;border-radius:50%;color:#fff;display:flex;font-size:12px;height:22px;justify-content:center;position:absolute;right:-10px;top:-10px;width:22px}.e-listboxtool-wrapper.e-sortableclone{display:block}.e-listboxtool-wrapper,.e-listboxtool-container{cursor:pointer;display:flex}.e-listboxtool-wrapper *,.e-listboxtool-container *{box-sizing:border-box}.e-listboxtool-wrapper.e-disabled,.e-listboxtool-container.e-disabled{cursor:default;pointer-events:none}.e-listboxtool-wrapper .e-listbox-wrapper,.e-listboxtool-wrapper .e-list-wrap,.e-listboxtool-container .e-listbox-wrapper,.e-listboxtool-container .e-list-wrap{flex:1}.e-listboxtool-wrapper.e-right .e-listbox-tool,.e-listboxtool-container.e-right .e-listbox-tool{margin-left:15px}.e-listboxtool-wrapper.e-left .e-listbox-tool,.e-listboxtool-container.e-left .e-listbox-tool{margin-right:15px}.e-listboxtool-wrapper .e-listbox-tool,.e-listboxtool-container .e-listbox-tool{border:1px solid #e0e0e0;overflow:auto;padding:8px}.e-listboxtool-wrapper .e-listbox-tool .e-btn,.e-listboxtool-container .e-listbox-tool .e-btn{display:list-item;list-style-type:none;margin-bottom:10px}.e-listboxtool-wrapper.e-checkbox-right .e-checkbox-wrapper,.e-listboxtool-container.e-checkbox-right .e-checkbox-wrapper{position:absolute;right:0;top:30%}.e-rtl.e-listboxtool-wrapper.e-right .e-listbox-tool,.e-rtl.e-listboxtool-container.e-right .e-listbox-tool{margin-right:15px}.e-rtl.e-listboxtool-wrapper.e-left .e-listbox-tool,.e-rtl.e-listboxtool-container.e-left .e-listbox-tool{margin-left:15px}.e-listbox-wrapper:not(.e-list-template) .e-list-item,.e-listbox-wrapper .e-list-nrt,.e-listbox-wrapper .e-selectall-parent,.e-listbox-container:not(.e-list-template) .e-list-item,.e-listbox-container .e-list-nrt,.e-listbox-container .e-selectall-parent,.e-listboxtool-wrapper .e-listbox-wrapper:not(.e-list-template) .e-list-item,.e-listboxtool-wrapper .e-listbox-wrapper .e-list-nrt,.e-listboxtool-wrapper .e-listbox-wrapper .e-selectall-parent{height:36px;line-height:1;padding:11px 16px;position:relative}.e-small .e-listbox-wrapper.e-filter-list .e-list-parent,.e-small .e-listbox-container.e-filter-list .e-list-parent{height:calc(100% - 45px)!important}.e-listbox-container.e-filter-list .e-selectall-parent+.e-list-parent{height:calc(100% - 48px)!important}.e-listbox-wrapper.e-filter-list:not(.e-listbox-container) .e-list-parent{height:calc(100% - 48px)!important}.e-listbox-wrapper.e-filter-list:not(.e-listbox-container) .e-selectall-parent+.e-hidden-select+.e-listbox+.e-list-parent{height:calc(100% - 83px)!important}.e-listbox-wrapper,.e-listbox-container:not(.e-listboxtool-container):not(.e-sortableclone),.e-listboxtool-container.e-listbox-container .e-ul{border:1px solid #e0e0e0}.e-listbox-wrapper,.e-listbox-container,.e-listboxtool-wrapper{font-family:Roboto,Segoe UI,GeezaPro,"DejaVu Serif","sans-serif",-apple-system,BlinkMacSystemFont;font-size:15px}.e-listbox-wrapper .e-list-header,.e-listbox-container .e-list-header,.e-listboxtool-wrapper .e-list-header{background-color:#fff;border-color:#0000001f;color:#000000de;font-size:20px}.e-listbox-wrapper.e-filter-list .e-list-parent,.e-listbox-container.e-filter-list .e-list-parent,.e-listboxtool-wrapper.e-filter-list .e-list-parent{height:calc(100% - 48px)}.e-listbox-wrapper.e-filter-list .e-selectall-parent+.e-list-parent,.e-listbox-container.e-filter-list .e-selectall-parent+.e-list-parent,.e-listboxtool-wrapper.e-filter-list .e-selectall-parent+.e-list-parent{height:calc(100% - 36px)!important}.e-listbox-wrapper .e-selectall-parent+.e-list-parent,.e-listbox-container .e-selectall-parent+.e-list-parent,.e-listboxtool-wrapper .e-selectall-parent+.e-list-parent{height:calc(100% - 36px)!important}.e-listbox-wrapper .e-list-item,.e-listbox-container .e-list-item,.e-listboxtool-wrapper .e-list-item{background-color:#fff;border-bottom:0 solid transparent;border-left:0 solid transparent;border-right:0 solid transparent;border-top:0 solid transparent;color:#000000de}.e-listbox-wrapper .e-list-item:hover:not(.e-selected):not(.e-disabled),.e-listbox-wrapper .e-list-item:hover.e-selected.e-checklist:not(.e-disabled),.e-listbox-container .e-list-item:hover:not(.e-selected):not(.e-disabled),.e-listbox-container .e-list-item:hover.e-selected.e-checklist:not(.e-disabled),.e-listboxtool-wrapper .e-list-item:hover:not(.e-selected):not(.e-disabled),.e-listboxtool-wrapper .e-list-item:hover.e-selected.e-checklist:not(.e-disabled){background-color:#eee;border-color:transparent;color:#000000de}.e-listbox-wrapper .e-list-item.e-selected.e-checklist,.e-listbox-container .e-list-item.e-selected.e-checklist,.e-listboxtool-wrapper .e-list-item.e-selected.e-checklist{background-color:#fff;color:#000000de}.e-listbox-wrapper .e-list-item.e-focused,.e-listbox-wrapper .e-list-item.e-focused.e-selected.e-checklist,.e-listbox-wrapper .e-list-item.e-selected,.e-listbox-container .e-list-item.e-focused,.e-listbox-container .e-list-item.e-focused.e-selected.e-checklist,.e-listbox-container .e-list-item.e-selected,.e-listboxtool-wrapper .e-list-item.e-focused,.e-listboxtool-wrapper .e-list-item.e-focused.e-selected.e-checklist,.e-listboxtool-wrapper .e-list-item.e-selected{background-color:#f5f5f5;color:#000000de}.e-listbox-wrapper .e-list-item.e-focused .e-checkbox-wrapper .e-frame.e-check,.e-listbox-wrapper .e-list-item.e-focused .e-css.e-checkbox-wrapper .e-frame.e-check,.e-listbox-container .e-list-item.e-focused .e-checkbox-wrapper .e-frame.e-check,.e-listbox-container .e-list-item.e-focused .e-css.e-checkbox-wrapper .e-frame.e-check,.e-listboxtool-wrapper .e-list-item.e-focused .e-checkbox-wrapper .e-frame.e-check,.e-listboxtool-wrapper .e-list-item.e-focused .e-css.e-checkbox-wrapper .e-frame.e-check{background-color:#e3165b;border-color:transparent;color:#fff}.e-listbox-wrapper .e-list-group-item,.e-listbox-container .e-list-group-item,.e-listboxtool-wrapper .e-list-group-item{background-color:#fafafa;border-color:#0000001f;color:#0000008a;font-size:15px}.e-listbox-wrapper .e-selectall-parent,.e-listbox-container .e-selectall-parent,.e-listboxtool-wrapper .e-selectall-parent{background-color:#fff;border-bottom:1px solid rgba(0,0,0,.12);color:#000000de}.e-listbox-wrapper .e-sortableclone.e-ripple .e-ripple-element,.e-listbox-container .e-sortableclone.e-ripple .e-ripple-element,.e-listboxtool-wrapper .e-sortableclone.e-ripple .e-ripple-element{background-color:transparent}.e-listbox-wrapper.e-list-template .e-list-wrapper,.e-listbox-container.e-list-template .e-list-wrapper,.e-listboxtool-wrapper.e-list-template .e-list-wrapper{height:inherit;position:relative}.e-listbox-wrapper.e-list-template .e-list-wrapper:not(.e-list-multi-line),.e-listbox-container.e-list-template .e-list-wrapper:not(.e-list-multi-line),.e-listboxtool-wrapper.e-list-template .e-list-wrapper:not(.e-list-multi-line){padding:.2667em 1.0666em}.e-listbox-wrapper.e-list-template .e-list-wrapper.e-list-multi-line,.e-listbox-container.e-list-template .e-list-wrapper.e-list-multi-line,.e-listboxtool-wrapper.e-list-template .e-list-wrapper.e-list-multi-line{padding:1.0666em}.e-listbox-wrapper.e-list-template .e-list-wrapper.e-list-multi-line .e-list-item-header,.e-listbox-container.e-list-template .e-list-wrapper.e-list-multi-line .e-list-item-header,.e-listboxtool-wrapper.e-list-template .e-list-wrapper.e-list-multi-line .e-list-item-header{color:#000000de;display:block;font-size:15px;font-weight:500;margin:0;overflow:hidden;padding:.115em 0;text-overflow:ellipsis;white-space:nowrap}.e-listbox-wrapper.e-list-template .e-list-wrapper.e-list-multi-line .e-list-content,.e-listbox-container.e-list-template .e-list-wrapper.e-list-multi-line .e-list-content,.e-listboxtool-wrapper.e-list-template .e-list-wrapper.e-list-multi-line .e-list-content{color:#0000008a;display:block;font-size:13px;margin:0;padding:.115em 0;word-wrap:break-word}.e-listbox-wrapper.e-list-template .e-list-wrapper.e-list-multi-line .e-list-content:not(.e-text-overflow),.e-listbox-container.e-list-template .e-list-wrapper.e-list-multi-line .e-list-content:not(.e-text-overflow),.e-listboxtool-wrapper.e-list-template .e-list-wrapper.e-list-multi-line .e-list-content:not(.e-text-overflow){overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.e-listbox-wrapper.e-list-template .e-list-wrapper.e-list-avatar .e-avatar,.e-listbox-container.e-list-template .e-list-wrapper.e-list-avatar .e-avatar,.e-listboxtool-wrapper.e-list-template .e-list-wrapper.e-list-avatar .e-avatar{height:2.6667em;position:absolute;width:2.6667em;left:1.0667em}.e-listbox-wrapper.e-list-template .e-list-wrapper.e-list-avatar:not(.e-list-badge),.e-listbox-container.e-list-template .e-list-wrapper.e-list-avatar:not(.e-list-badge),.e-listboxtool-wrapper.e-list-template .e-list-wrapper.e-list-avatar:not(.e-list-badge){padding-left:4.8em;padding-right:1.0666em}.e-listbox-wrapper.e-list-template .e-list-wrapper.e-list-avatar-right:not(.e-list-badge),.e-listbox-container.e-list-template .e-list-wrapper.e-list-avatar-right:not(.e-list-badge),.e-listboxtool-wrapper.e-list-template .e-list-wrapper.e-list-avatar-right:not(.e-list-badge){padding-left:1.0666em;padding-right:4.8em}.e-listbox-wrapper.e-list-template .e-list-wrapper.e-list-avatar-right:not(.e-list-badge) .e-avatar,.e-listbox-container.e-list-template .e-list-wrapper.e-list-avatar-right:not(.e-list-badge) .e-avatar,.e-listboxtool-wrapper.e-list-template .e-list-wrapper.e-list-avatar-right:not(.e-list-badge) .e-avatar{height:2.6667em;left:1.0667em;position:absolute;width:2.6667em;right:1.0667em}.e-listbox-wrapper.e-list-template .e-list-wrapper.e-list-multi-line.e-list-avatar .e-avatar,.e-listbox-wrapper.e-list-template .e-list-wrapper.e-list-multi-line.e-list-avatar-right:not(.e-list-badge) .e-avatar,.e-listbox-container.e-list-template .e-list-wrapper.e-list-multi-line.e-list-avatar .e-avatar,.e-listbox-container.e-list-template .e-list-wrapper.e-list-multi-line.e-list-avatar-right:not(.e-list-badge) .e-avatar,.e-listboxtool-wrapper.e-list-template .e-list-wrapper.e-list-multi-line.e-list-avatar .e-avatar,.e-listboxtool-wrapper.e-list-template .e-list-wrapper.e-list-multi-line.e-list-avatar-right:not(.e-list-badge) .e-avatar{top:1.0666em}.e-listbox-wrapper.e-list-template .e-list-wrapper.e-list-badge .e-badge,.e-listbox-container.e-list-template .e-list-wrapper.e-list-badge .e-badge,.e-listboxtool-wrapper.e-list-template .e-list-wrapper.e-list-badge .e-badge{font-size:12px;height:1.6666em;line-height:1.8666em;padding:0;position:absolute;right:1.33em;top:50%;transform:translateY(-50%);width:2.5em}.e-listbox-wrapper.e-list-template .e-list-wrapper.e-list-badge.e-list-avatar,.e-listbox-container.e-list-template .e-list-wrapper.e-list-badge.e-list-avatar,.e-listboxtool-wrapper.e-list-template .e-list-wrapper.e-list-badge.e-list-avatar{padding-left:4.8em;padding-right:4.1333em}.e-listbox-wrapper.e-list-template .e-list-wrapper.e-list-badge:not(.e-list-avatar),.e-listbox-container.e-list-template .e-list-wrapper.e-list-badge:not(.e-list-avatar),.e-listboxtool-wrapper.e-list-template .e-list-wrapper.e-list-badge:not(.e-list-avatar){padding-left:1.0666em;padding-right:4.1333em}.e-listbox-wrapper.e-list-template .e-list-wrapper:not(.e-list-multi-line) .e-list-content,.e-listbox-container.e-list-template .e-list-wrapper:not(.e-list-multi-line) .e-list-content,.e-listboxtool-wrapper.e-list-template .e-list-wrapper:not(.e-list-multi-line) .e-list-content{display:block;margin:0;overflow:hidden;padding:.72em 0;text-overflow:ellipsis;white-space:nowrap}.e-listbox-wrapper.e-list-template .e-list-item.e-list-item:hover .e-list-item-header,.e-listbox-wrapper.e-list-template .e-list-item.e-list-item:hover .e-list-content,.e-listbox-container.e-list-template .e-list-item.e-list-item:hover .e-list-item-header,.e-listbox-container.e-list-template .e-list-item.e-list-item:hover .e-list-content,.e-listboxtool-wrapper.e-list-template .e-list-item.e-list-item:hover .e-list-item-header,.e-listboxtool-wrapper.e-list-template .e-list-item.e-list-item:hover .e-list-content,.e-listbox-wrapper.e-list-template .e-list-item.e-selected .e-list-item-header,.e-listbox-wrapper.e-list-template .e-list-item.e-selected .e-list-content,.e-listbox-container.e-list-template .e-list-item.e-selected .e-list-item-header,.e-listbox-container.e-list-template .e-list-item.e-selected .e-list-content,.e-listboxtool-wrapper.e-list-template .e-list-item.e-selected .e-list-item-header,.e-listboxtool-wrapper.e-list-template .e-list-item.e-selected .e-list-content{color:#000000de}.e-listbox-wrapper.e-rtl.e-list-template .e-list-wrapper.e-list-avatar .e-avatar,.e-listbox-container.e-rtl.e-list-template .e-list-wrapper.e-list-avatar .e-avatar,.e-listboxtool-wrapper.e-rtl.e-list-template .e-list-wrapper.e-list-avatar .e-avatar{left:inherit;right:1.0667em}.e-listbox-wrapper.e-rtl.e-list-template .e-list-wrapper.e-list-avatar:not(.e-list-badge),.e-listbox-container.e-rtl.e-list-template .e-list-wrapper.e-list-avatar:not(.e-list-badge),.e-listboxtool-wrapper.e-rtl.e-list-template .e-list-wrapper.e-list-avatar:not(.e-list-badge){padding-left:1.0666em;padding-right:4.8em}.e-listbox-wrapper.e-rtl.e-list-template .e-list-wrapper.e-list-avatar-right:not(.e-list-badge),.e-listbox-container.e-rtl.e-list-template .e-list-wrapper.e-list-avatar-right:not(.e-list-badge),.e-listboxtool-wrapper.e-rtl.e-list-template .e-list-wrapper.e-list-avatar-right:not(.e-list-badge){padding-left:4.8em;padding-right:1.0666em}.e-listbox-wrapper.e-rtl.e-list-template .e-list-wrapper.e-list-avatar-right:not(.e-list-badge) .e-avatar,.e-listbox-container.e-rtl.e-list-template .e-list-wrapper.e-list-avatar-right:not(.e-list-badge) .e-avatar,.e-listboxtool-wrapper.e-rtl.e-list-template .e-list-wrapper.e-list-avatar-right:not(.e-list-badge) .e-avatar{left:1.0667em;right:inherit}.e-listbox-wrapper.e-rtl.e-list-template .e-list-wrapper.e-list-badge .e-badge,.e-listbox-container.e-rtl.e-list-template .e-list-wrapper.e-list-badge .e-badge,.e-listboxtool-wrapper.e-rtl.e-list-template .e-list-wrapper.e-list-badge .e-badge{left:1.33em;right:inherit}.e-listbox-wrapper.e-rtl.e-list-template .e-list-wrapper.e-list-badge.e-list-avatar,.e-listbox-container.e-rtl.e-list-template .e-list-wrapper.e-list-badge.e-list-avatar,.e-listboxtool-wrapper.e-rtl.e-list-template .e-list-wrapper.e-list-badge.e-list-avatar{padding-left:4.1333em;padding-right:4.8em}.e-listbox-wrapper.e-rtl.e-list-template .e-list-wrapper.e-list-badge:not(.e-list-avatar),.e-listbox-container.e-rtl.e-list-template .e-list-wrapper.e-list-badge:not(.e-list-avatar),.e-listboxtool-wrapper.e-rtl.e-list-template .e-list-wrapper.e-list-badge:not(.e-list-avatar){padding-left:4.1333em;padding-right:1.0666em}.e-listbox-container.e-filter-list .e-list-parent,.e-listbox-container.e-filter-list .e-selectall-parent+.e-list-parent,.e-listbox-container .e-selectall-parent+.e-list-parent{height:100%}.e-listbox-container.e-filter-list .e-list-wrap{height:calc(100% - 43px)!important}.e-listbox-container.e-filter-list .e-selectall-parent+.e-list-wrap{height:calc(100% - 36px)!important}.e-listbox-container .e-selectall-parent+.e-list-wrap{height:calc(100% - 36px)!important}.e-bigger .e-listbox-wrapper.e-listboxtool-container .e-list-wrap,.e-listbox-wrapper.e-bigger.e-listboxtool-container .e-list-wrap,.e-bigger .e-listbox-container.e-listboxtool-container .e-list-wrap,.e-listbox-container.e-bigger.e-listboxtool-container .e-list-wrap{width:85%!important}.e-bigger .e-listbox-wrapper .e-list-item,.e-listbox-wrapper.e-bigger .e-list-item,.e-bigger .e-listbox-container .e-list-item,.e-listbox-container.e-bigger .e-list-item{border-bottom:0 solid transparent;border-left:0 solid transparent;border-right:0 solid transparent;border-top:0 solid transparent}.e-bigger .e-listbox-wrapper:not(.e-list-template) .e-list-item,.e-bigger .e-listbox-wrapper .e-selectall-parent,.e-bigger .e-listbox-wrapper .e-list-group-item,.e-bigger .e-listbox-wrapper .e-list-header,.e-listbox-wrapper.e-bigger:not(.e-list-template) .e-list-item,.e-listbox-wrapper.e-bigger .e-selectall-parent,.e-listbox-wrapper.e-bigger .e-list-group-item,.e-listbox-wrapper.e-bigger .e-list-header,.e-bigger .e-listbox-container:not(.e-list-template) .e-list-item,.e-bigger .e-listbox-container .e-selectall-parent,.e-bigger .e-listbox-container .e-list-group-item,.e-bigger .e-listbox-container .e-list-header,.e-listbox-container.e-bigger:not(.e-list-template) .e-list-item,.e-listbox-container.e-bigger .e-selectall-parent,.e-listbox-container.e-bigger .e-list-group-item,.e-listbox-container.e-bigger .e-list-header{padding:12px 16px}.e-bigger .e-listbox-wrapper:not(.e-list-template) .e-list-item,.e-bigger .e-listbox-wrapper .e-selectall-parent,.e-listbox-wrapper.e-bigger:not(.e-list-template) .e-list-item,.e-listbox-wrapper.e-bigger .e-selectall-parent,.e-bigger .e-listbox-container:not(.e-list-template) .e-list-item,.e-bigger .e-listbox-container .e-selectall-parent,.e-listbox-container.e-bigger:not(.e-list-template) .e-list-item,.e-listbox-container.e-bigger .e-selectall-parent{height:48px;line-height:1.6;position:relative}.e-bigger .e-listbox-wrapper .e-list-parent,.e-listbox-wrapper.e-bigger .e-list-parent,.e-bigger .e-listbox-container .e-list-parent,.e-listbox-container.e-bigger .e-list-parent{min-height:48px}.e-bigger .e-listbox-wrapper .e-text-content,.e-listbox-wrapper.e-bigger .e-text-content,.e-bigger .e-listbox-container .e-text-content,.e-listbox-container.e-bigger .e-text-content{font-size:15px}.e-bigger .e-listbox-wrapper .e-list-group-item,.e-listbox-wrapper.e-bigger .e-list-group-item,.e-bigger .e-listbox-container .e-list-group-item,.e-listbox-container.e-bigger .e-list-group-item{height:48px;line-height:25px}.e-bigger .e-listbox-wrapper .e-list-header,.e-listbox-wrapper.e-bigger .e-list-header,.e-bigger .e-listbox-container .e-list-header,.e-listbox-container.e-bigger .e-list-header{align-items:center;display:flex;font-weight:700;height:64px}.e-bigger .e-listbox-wrapper .e-list-header .e-text.header,.e-bigger .e-listbox-wrapper .e-list-header .e-headertemplate-text.nested-header,.e-listbox-wrapper.e-bigger .e-list-header .e-text.header,.e-listbox-wrapper.e-bigger .e-list-header .e-headertemplate-text.nested-header,.e-bigger .e-listbox-container .e-list-header .e-text.header,.e-bigger .e-listbox-container .e-list-header .e-headertemplate-text.nested-header,.e-listbox-container.e-bigger .e-list-header .e-text.header,.e-listbox-container.e-bigger .e-list-header .e-headertemplate-text.nested-header{display:none}.e-bigger .e-listbox-wrapper .e-list-header .e-text,.e-listbox-wrapper.e-bigger .e-list-header .e-text,.e-bigger .e-listbox-container .e-list-header .e-text,.e-listbox-container.e-bigger .e-list-header .e-text{font-size:20px}.e-bigger .e-listbox-wrapper.e-filter-list:not(.e-listbox-container) .e-list-parent{height:calc(100% - 55px)!important}.e-bigger .e-listbox-container.e-filter-list .e-list-wrap{height:calc(100% - 50px)!important}.e-bigger .e-listbox-container.e-filter-list .e-list-parent,.e-bigger .e-listbox-container .e-selectall-parent+.e-list-parent,.e-small.e-bigger .e-listbox-container.e-filter-list .e-list-parent,.e-bigger .e-listbox-container.e-filter-list .e-selectall-parent+.e-list-parent{height:100%}.e-bigger .e-listbox-wrapper.e-filter-list .e-selectall-parent+.e-list-parent,.e-bigger .e-listbox-container.e-filter-list .e-selectall-parent+.e-list-parent{height:calc(100% - 48px)!important}.e-bigger .e-listbox-wrapper .e-selectall-parent+.e-list-parent,.e-bigger .e-listbox-container .e-selectall-parent+.e-list-wrap{height:calc(100% - 48px)!important}.e-small.e-bigger .e-listbox-wrapper.e-filter-list .e-list-parent,.e-small.e-bigger .e-listbox-container.e-filter-list .e-list-wrap{height:calc(100% - 45px)!important}.e-bigger .e-listbox-wrapper.e-filter-list:not(.e-listbox-container) .e-selectall-parent+.e-hidden-select+.e-listbox+.e-list-parent{height:calc(100% - 103px)!important}.e-ddl.e-control-wrapper .e-ddl-icon:before{transform:rotate(0);transition:transform .3s ease}.e-ddl.e-control-wrapper.e-icon-anim .e-ddl-icon:before{transform:rotate(180deg);transition:transform .3s ease}.e-dropdownbase .e-list-item.e-active.e-hover{color:#e3165b}.e-input-group:not(.e-disabled) .e-control.e-dropdownlist~.e-ddl-icon:active,.e-input-group:not(.e-disabled) .e-control.e-dropdownlist~.e-ddl-icon:hover,.e-input-group:not(.e-disabled) .e-back-icon:active,.e-input-group:not(.e-disabled) .e-back-icon:hover,.e-popup.e-ddl .e-input-group:not(.e-disabled) .e-clear-icon:active,.e-popup.e-ddl .e-input-group:not(.e-disabled) .e-clear-icon:hover{background:transparent}.e-input-group .e-ddl-icon:not(:active):after{animation:none}.e-ddl.e-popup{border:0;box-shadow:0 5px 5px -3px #0003,0 8px 10px 1px #00000024,0 3px 14px 2px #0000001f;margin-top:2px}.e-popup.e-ddl .e-dropdownbase{min-height:26px}.e-popup.e-ddl:not(.e-ddl-device) .e-input-group .e-clear-icon{margin:6px 6px 5px;min-height:12px;min-width:12px;padding:6px}.e-input-group.e-ddl,.e-input-group.e-ddl .e-input,.e-input-group.e-ddl .e-ddl-icon{background:transparent}.e-ddl.e-ddl-device.e-ddl-device-filter .e-input-group:hover:not(.e-disabled):not(.e-float-icon-left),.e-ddl.e-ddl-device.e-ddl-device-filter .e-input-group.e-control-wrapper:hover:not(.e-disabled):not(.e-float-icon-left){border-bottom-width:0}.e-popup.e-ddl:not(.e-ddl-device) .e-input-group.e-small .e-clear-icon,.e-small .e-popup.e-ddl:not(.e-ddl-device) .e-input-group .e-clear-icon,.e-small.e-popup.e-ddl:not(.e-ddl-device) .e-input-group .e-clear-icon,.e-popup.e-ddl:not(.e-ddl-device) .e-input-group.e-input-focus.e-small .e-clear-icon,.e-small .e-popup.e-ddl:not(.e-ddl-device) .e-input-group.e-input-focus .e-clear-icon,.e-small.e-popup.e-ddl:not(.e-ddl-device) .e-input-group.e-input-focus .e-clear-icon{margin:0}.e-small .e-popup.e-ddl:not(.e-ddl-device) .e-filter-parent .e-input-group .e-input-filter,.e-small.e-popup.e-ddl:not(.e-ddl-device) .e-filter-parent .e-input-group .e-input-filter,.e-popup.e-ddl:not(.e-ddl-device) .e-filter-parent .e-input-group.e-small .e-input-filter,.e-small .e-popup.e-ddl:not(.e-ddl-device) .e-filter-parent .e-input-group.e-input-focus .e-input-filter,.e-small.e-popup.e-ddl:not(.e-ddl-device) .e-filter-parent .e-input-group.e-input-focus .e-input-filter,.e-popup.e-ddl:not(.e-ddl-device) .e-filter-parent .e-input-group.e-small.e-input-focus .e-input-filter{padding:5px 5px 5px 12px}.e-ddl.e-popup.e-outline .e-filter-parent{padding:4px 8px}.e-excelfilter .e-icon-filter:before{content:"\e7ee"}.e-excelfilter .e-excl-filter-icon:before{content:"\e251"}.e-excelfilter .e-excl-filter-icon.e-filtered:before{content:"\e248"}.e-excelfilter .e-search-icon:before{content:"\e993"}.e-excelfilter .e-chkcancel-icon:before{content:"\e7a7"}.e-excelfilter .e-sortascending:before{content:"\e734"}.e-excelfilter .e-sortdescending:before{content:"\e733"}/*! Excel-Filter layout */.sf-grid .e-excelfilter.e-dialog .e-dlg-content{padding-left:0;padding-right:0}.sf-grid .e-excelfilter .e-dlg-content{overflow:visible;padding:0}.sf-grid .e-excelfilter .e-searchcontainer{padding:4px 24px 18px 9px}.sf-grid .e-excelfilter.e-rtl .e-searchcontainer{padding:4px 0 18px 18px}.sf-grid .e-excelfilter.e-rtl .e-checkbox-wrapper .e-frame+.e-label{margin-left:0;margin-right:8px}.sf-grid .e-excelfilter .e-contextmenu-container.e-sfcontextmenu{display:inline-block;position:relative;width:100%}.sf-grid .e-excelfilter .e-contextmenu-container.e-sfcontextmenu .e-ul{position:absolute}.sf-grid .e-excelfilter .e-contextmenu-container.e-sfcontextmenu .e-ul .e-menu-item .e-menu-icon{height:26px;line-height:26px}.sf-grid .e-excelfilter .e-contextmenu-container.e-sfcontextmenu .e-ul .e-menu-item:not(.e-separator){height:36px;line-height:36px}.sf-grid .e-excelfilter .e-contextmenu-container.e-sfcontextmenu .e-ul .e-separator{height:auto}.sf-grid .e-excelfilter .e-contextmenu-container ul .e-menu-item .e-caret{margin-right:24px}.sf-grid .e-excelfilter .e-searchbox{padding-left:8px}.sf-grid-dlg.e-xlflmenu .e-xlfl-radiodiv{width:unset}.e-xlflmenu{min-height:295px}.e-xlflmenu .e-xlfl-dlgfields{font-size:17px}.e-xlflmenu .e-xlfl-fieldset{font-size:14px;padding-top:15px}.e-xlflmenu .e-xlfl-optr,.e-xlflmenu .e-xlfl-value,.e-xlflmenu .e-xlfl-radio,.e-xlflmenu .e-xlfl-mtcase{padding-top:12px}.e-xlflmenu .e-xlfl-optr:first-child{padding-right:12px}.e-xlflmenu .e-xlfl-table{border-spacing:0;table-layout:fixed;width:100%}.e-xlflmenu .e-radio+label .e-label{margin-top:0;padding-left:23px;padding-right:13px}.e-xlflmenu .e-checkbox-wrapper .e-frame+.e-label{margin-bottom:1px;margin-left:6px}.e-xlflmenu .e-checkbox-wrapper .e-frame{margin-bottom:1px}.e-xlflmenu .e-dlg-content{padding-bottom:6px}.e-xlflmenu .e-xlfl-radiodiv{width:117px}.e-xlflmenu .e-xlfl-matchcasediv{margin-left:0;margin-right:13px}.e-xlfl-radio-or,.e-xlfl-matchcasediv{margin-left:13px}.e-xlflmenu.e-rtl .e-xlfl-optr{padding-left:12px;padding-right:0}.e-xlflmenu.e-rtl .e-radio+label .e-label{padding-left:0;padding-right:25px}.e-xlflmenu.e-rtl .e-xlfl-radio-or{margin-left:0;margin-right:13px}.e-excelfilter .e-checkboxlist{height:200px;margin-top:5px;min-height:160px;overflow-y:auto}.e-excelfilter .e-checkboxfiltertext{width:150px;word-break:normal}.e-excelfilter .e-chk-hidden{-moz-appearance:none;height:1px;opacity:0;width:1px}.e-excelfilter .e-contextmenu-wrapper ul li,.e-excelfilter .e-contextmenu-container ul li{height:36px;line-height:36px}.e-excelfilter .e-contextmenu-wrapper ul .e-menu-item .e-caret{height:36px;line-height:36px}.e-excelfilter .e-contextmenu-wrapper ul,.e-excelfilter .e-contextmenu-container ul:not(.e-ul){border:0;border-radius:0;box-shadow:none;max-width:300px;padding-bottom:4px;position:static}.e-excelfilter .e-dlg-content{background-color:#fff;padding-top:0}.e-excelfilter .e-searchbox,.e-excelfilter .e-contextmenu-wrapper,.e-excelfilter .e-contextmenu-wrapper ul{display:block}.e-excelfilter .e-contextmenu-wrapper ul{padding-bottom:4px;position:static}.e-excelfilter .e-contextmenu-wrapper ul li .e-contextmenu-container ul li{height:36px;line-height:36px}.e-excelfilter .e-contextmenu-wrapper ul .e-menu-item .e-caret{height:36px;line-height:36px;margin-right:17px}.e-excelfilter .e-contextmenu-wrapper ul li .e-menu-icon,.e-excelfilter .e-contextmenu-container ul li .e-menu-icon{height:36px;line-height:36px;margin-right:12px}.e-excelfilter.e-rtl .e-contextmenu-wrapper ul li .e-menu-icon{margin-right:0}.e-excelfilter.e-rtl .e-contextmenu-wrapper ul .e-menu-item .e-caret{margin-left:17px}.e-excelfilter .e-footer-content{border-style:solid;border-width:1px 0 0}.e-excelfilter .e-excel-menu{z-index:1000}.e-excelfilter .e-xlsel{border:0 solid;position:absolute;-webkit-user-select:none;user-select:none}.e-excelfilter.e-dialog .e-dlg-content,.e-excelfilter .e-ftrchk,.e-excelfilter .e-searchbox{padding-left:9px}.e-excelfilter.e-rtl .e-dlg-content{padding-left:18px;padding-right:9px}.e-excelfilter.e-rtl .e-ftrchk,.e-excelfilter.e-rtl .e-searchbox{padding-left:0;padding-right:9px}.e-ftrchk{padding-bottom:9px;padding-top:9px}.e-excel-menu.e-contextmenu.e-menu-parent{max-height:298px;overflow-y:auto}/*! Excel-Filter theme */.e-excelfilter .e-footer-content{border-color:#0000001f;opacity:1}.e-excelfilter .e-filtered:before{color:#e3165b}.e-excelfilter .e-dlg-content{padding-bottom:0}li.e-separator.e-menu-item.e-excel-separator{margin-bottom:4px;margin-top:4px}.e-xlsel{background-color:#e3165b;border-color:#e3165b}/*! Excel-Filter bigger */.e-bigger .e-xlflmenu.e-rtl .e-radio+label .e-label{padding-left:0;padding-right:25px}.e-bigger .e-xlflmenu{min-height:396px}.e-bigger .e-xlflmenu .e-xlfl-table{border-spacing:0;width:100%}.e-bigger .e-xlflmenu .e-dlg-content{padding-bottom:8px}.e-bigger .e-xlflmenu .e-radio+label .e-label{padding-left:28px;padding-right:5px}.e-bigger .e-xlflmenu .e-checkbox-wrapper .e-frame+.e-label{margin-left:8px}.e-bigger .e-xlflmenu .e-xlfl-radiodiv{width:137px}.e-bigger .e-xlflmenu .e-xlfl-radio-or,.e-bigger .e-xlflmenu .e-xlfl-matchcasediv{margin-left:18px}.e-bigger .e-xlflmenu .e-xlfl-optr:first-child{padding-right:16px}.e-bigger .e-xlflmenu.e-rtl .e-xlfl-optr{padding-right:0}.e-bigger .e-xlflmenu .e-xlfl-dlgfields{font-size:18px}.e-bigger .e-xlflmenu .e-xlfl-fieldset{font-size:15px;padding-top:20px}.e-bigger .e-xlflmenu .e-xlfl-optr,.e-bigger .e-xlflmenu .e-xlfl-value,.e-bigger .e-xlflmenu .e-xlfl-radio,.e-bigger .e-xlflmenu .e-xlfl-mtcase{padding-top:16px}.e-bigger .e-excelfilter .e-xlflmenu,.e-excelfilter.e-bigger .e-xlflmenu{min-height:396px}.e-bigger .e-excelfilter .e-ftrchk,.e-excelfilter.e-bigger .e-ftrchk{padding-bottom:13px;padding-top:13px}.e-bigger .e-excelfilter .e-contextmenu-wrapper ul li,.e-bigger .e-excelfilter .e-contextmenu-container ul li,.e-excelfilter.e-bigger .e-contextmenu-wrapper ul li,.e-excelfilter.e-bigger .e-contextmenu-container ul li{height:48px;line-height:48px}.e-bigger .e-excelfilter .e-contextmenu-wrapper ul li .e-menu-icon,.e-bigger .e-excelfilter .e-contextmenu-container ul li .e-menu-icon,.e-excelfilter.e-bigger .e-contextmenu-wrapper ul li .e-menu-icon,.e-excelfilter.e-bigger .e-contextmenu-container ul li .e-menu-icon{height:48px;line-height:48px;margin-right:15px}.e-bigger .e-excelfilter .e-contextmenu-wrapper ul .e-menu-item .e-caret,.e-excelfilter.e-bigger .e-contextmenu-wrapper ul .e-menu-item .e-caret{height:48px;line-height:48px;margin-right:0}.e-bigger .e-excelfilter.e-dialog .e-dlg-content,.e-excelfilter.e-bigger.e-dialog .e-dlg-content{padding-left:11px}.e-bigger .e-excelfilter .e-ftrchk,.e-bigger .e-excelfilter .e-searchbox,.e-excelfilter.e-bigger .e-ftrchk,.e-excelfilter.e-bigger .e-searchbox{padding-left:13px}.e-bigger .e-excelfilter.e-rtl .e-contextmenu-wrapper ul li .e-menu-icon,.e-excelfilter.e-bigger.e-rtl .e-contextmenu-wrapper ul li .e-menu-icon{margin-right:0}.e-bigger .e-excelfilter.e-rtl .e-contextmenu-wrapper ul .e-menu-item .e-caret,.e-excelfilter.e-bigger.e-rtl .e-contextmenu-wrapper ul .e-menu-item .e-caret{margin-left:0}.e-bigger .e-excelfilter.e-rtl .e-dlg-content,.e-excelfilter.e-bigger.e-rtl .e-dlg-content{padding-left:24px;padding-right:11px}.e-bigger .e-excelfilter.e-rtl .e-ftrchk,.e-bigger .e-excelfilter.e-rtl .e-searchbox,.e-excelfilter.e-bigger.e-rtl .e-ftrchk,.e-excelfilter.e-bigger.e-rtl .e-searchbox{padding-left:0;padding-right:13px}.e-bigger .e-excel-menu.e-contextmenu.e-menu-parent{max-height:355px}@keyframes tbar-popup-shadow{0%{border-color:#ffffff80;box-shadow:0 0 #ffffff80}to{box-shadow:0 0 0 200px #ffffff1f}}.e-icon-check:before{content:"\e7ff"}.e-grid.e-rtl .e-icon-rowdragicon:before,.e-grid .e-icon-rowdragicon:before,.e-grid .e-group-animate .e-drag.e-icon-drag:before,.e-grid-menu.e-rtl .e-icon-rowdragicon:before,.e-grid-menu .e-icon-rowdragicon:before,.e-grid-menu .e-group-animate .e-drag.e-icon-drag:before{content:"\e330"}.e-grid .e-group-animate .e-nextgroup.e-icon-next:before,.e-grid-menu .e-group-animate .e-nextgroup.e-icon-next:before{content:"\ec07"}.e-grid .e-icon-autofit:before,.e-grid-menu .e-icon-autofit:before{content:"\e9d9"}.e-grid .e-icon-autofitall:before,.e-grid-menu .e-icon-autofitall:before{content:"\e9da"}.e-grid .e-icon-columnchooser:before,.e-grid-menu .e-icon-columnchooser:before{content:"\e9db"}.e-grid .e-icon-ascending:before,.e-grid-menu .e-icon-ascending:before{content:"\e840"}.e-grid .e-icon-descending:before,.e-grid-menu .e-icon-descending:before{content:"\e83f"}.e-grid .e-icon-hide:before,.e-grid-menu .e-icon-hide:before{content:"\e825"}.e-grid .e-ungroupbutton.e-icon-hide:before,.e-grid-menu .e-ungroupbutton.e-icon-hide:before{content:"\e917"}.e-grid .e-icon-rowselect:before,.e-grid-menu .e-icon-rowselect:before{content:"\e930"}.e-grid .e-icon-sortdirect:before,.e-grid-menu .e-icon-sortdirect:before{content:"\e890"}.e-grid .e-icon-gdownarrow:before,.e-grid-menu .e-icon-gdownarrow:before{content:"\e83d"}.e-grid .e-icon-grightarrow:before,.e-grid-menu .e-icon-grightarrow:before{content:"\e859"}.e-grid .e-icon-filter:before,.e-grid .e-icon-filter.e-filtered:before,.e-grid-menu .e-icon-filter:before,.e-grid-menu .e-icon-filter.e-filtered:before{content:"\e7ee"}.e-grid .e-excl-filter-icon:before,.e-grid .e-resfilter-icon:before,.e-grid-menu .e-excl-filter-icon:before,.e-grid-menu .e-resfilter-icon:before{content:"\e251"}.e-grid .e-ressort-icon:before,.e-grid-menu .e-ressort-icon:before{content:"\e612"}.e-grid .e-excl-filter-icon.e-filtered:before,.e-grid-menu .e-excl-filter-icon.e-filtered:before{content:"\e248"}.e-grid.e-rtl .e-icon-grightarrow:before,.e-grid-menu.e-rtl .e-icon-grightarrow:before{content:"\e854"}.e-grid .e-icon-group:before,.e-grid .e-icon-ungroup:before,.e-grid-menu .e-icon-group:before,.e-grid-menu .e-icon-ungroup:before{content:"\e926"}.e-grid .e-icon-reorderuparrow:before,.e-grid-menu .e-icon-reorderuparrow:before{content:"\e918"}.e-grid .e-icon-reorderdownarrow:before,.e-grid-menu .e-icon-reorderdownarrow:before{content:"\e919"}.e-grid .e-print:before,.e-grid-menu .e-print:before{content:"\e813"}.e-grid .e-add:before,.e-grid-menu .e-add:before{content:"\e7f9"}.e-grid .e-resback-icon:before,.e-grid-menu .e-resback-icon:before{content:"\e977"}.e-grid .e-wordexport:before,.e-grid-menu .e-wordexport:before{content:"\e7b0"}.e-grid .e-pdfexport:before,.e-grid-menu .e-pdfexport:before{content:"\e240"}.e-grid .e-csvexport:before,.e-grid-menu .e-csvexport:before{content:"\e241"}.e-grid .e-excelexport:before,.e-grid-menu .e-excelexport:before{content:"\e242"}.e-grid .e-edit:before,.e-grid-menu .e-edit:before{content:"\e81e"}.e-grid .e-responsivetoolbaritems-btn:before,.e-grid .e-columnmenu:before,.e-grid .e-columnmenu.e-filtered:before,.e-grid-menu .e-responsivetoolbaritems-btn:before,.e-grid-menu .e-columnmenu:before,.e-grid-menu .e-columnmenu.e-filtered:before{content:"\e984"}.e-grid .e-delete:before,.e-grid-menu .e-delete:before{content:"\e84e"}.e-grid .e-copy:before,.e-grid-menu .e-copy:before{content:"\e70a"}.e-grid .e-save:before,.e-grid-menu .e-save:before{content:"\e98e"}.e-grid .e-update:before,.e-grid-menu .e-update:before{content:"\e735"}.e-grid .e-columnchooserdiv:before,.e-grid-menu .e-columnchooserdiv:before{content:"\e714"}.e-grid .e-columnchooser:before,.e-grid-menu .e-columnchooser:before{content:"\e21e"}.e-grid .e-columnchooser-btn:before,.e-grid-menu .e-columnchooser-btn:before{content:"\e969"}.e-grid .e-cc-icon:before,.e-grid-menu .e-cc-icon:before{content:"\e82e"}.e-grid .e-ccsearch-icon:before,.e-grid .e-search-icon:before,.e-grid-menu .e-ccsearch-icon:before,.e-grid-menu .e-search-icon:before,.e-grid-popup .e-ccsearch-icon:before,.e-grid-popup .e-search-icon:before{content:"\e993"}.e-grid .e-ccsearch-icon.e-cc-cancel:before,.e-grid .e-chkcancel-icon:before,.e-grid-menu .e-ccsearch-icon.e-cc-cancel:before,.e-grid-menu .e-chkcancel-icon:before,.e-grid-popup .e-ccsearch-icon.e-cc-cancel:before,.e-grid-popup .e-chkcancel-icon:before{content:"\e7a7"}.e-grid .e-cancel-icon:before,.e-grid .e-cancel:before,.e-grid-menu .e-cancel-icon:before,.e-grid-menu .e-cancel:before,.e-grid-popup .e-cancel-icon:before,.e-grid-popup .e-cancel:before{content:"\e825"}.e-responsive-dialog .e-resfilterback:before{content:"\e977"}.e-responsive-dialog .e-filterset:before{content:"\e7ee"}.e-responsive-dialog .e-search-icon:before,.e-responsive-dialog .e-ccdlg span.e-ccsearch-icon:before{content:"\e993"}.e-responsive-dialog .e-chkcancel-icon:before,.e-responsive-dialog .e-ccdlg span.e-cc-cancel:before{content:"\e7a7"}.e-responsive-dialog .e-icon-filter-clear:before{content:"\e248"}.e-responsive-dialog .e-resfilter-icon.e-icons:before{content:"\e251"}.e-responsive-dialog .e-resascending-icon.e-icons:before{content:"\e840"}.e-responsive-dialog .e-resdescending-icon.e-icons:before{content:"\e83f"}.e-responsive-dialog .e-rescolumn-icon.e-icons:before{content:"\e9db"}.e-responsive-dialog .e-resautofit-icon.e-icons:before{content:"\e9d9"}.e-responsive-dialog .e-resautofitall-icon.e-icons:before{content:"\e9da"}.e-responsive-dialog .e-resgroup-icon.e-icons:before,.e-responsive-dialog .e-resungroup-icon.e-icons:before{content:"\e926"}.e-grid-toolbarmenu .e-responsivetoolbar-menu .e-menu-icon.e-print:before{content:"\e813"}.e-grid-toolbarmenu .e-responsivetoolbar-menu .e-menu-icon.e-pdfexport:before{content:"\e240"}.e-grid-toolbarmenu .e-responsivetoolbar-menu .e-menu-icon.e-excelexport:before{content:"\e242"}.e-grid-toolbarmenu .e-responsivetoolbar-menu .e-menu-icon.e-csvexport:before{content:"\e241"}.e-grid-toolbarmenu .e-responsivetoolbar-menu .e-menu-icon.e-columnchooser:before{content:"\e9db"}.e-row-responsive-filter .e-dlg-closeicon-btn .e-icon-dlg-close:before{content:"\e977"}/*! Grid layout */.e-disableuserselect{-webkit-user-select:none;user-select:none}/*! Blazor column menu custom css */.e-contextmenu-container.e-sfcontextmenu.e-hide-menu{visibility:hidden}.e-emptyicon{opacity:0}.e-device .e-flmenu-valuediv{padding:24px 0 0}.e-grid-popup{position:absolute}.e-grid .e-dialog.e-checkboxfilter,.e-grid .e-dialog.e-flmenu,.e-grid-popup .e-dialog.e-checkboxfilter,.e-grid-popup .e-dialog.e-flmenu{min-width:250px}.e-grid .e-dialog.e-checkboxfilter .e-dlg-content,.e-grid .e-dialog.e-flmenu .e-dlg-content,.e-grid-popup .e-dialog.e-checkboxfilter .e-dlg-content,.e-grid-popup .e-dialog.e-flmenu .e-dlg-content{border-radius:0}.e-grid [class^=e-],.e-grid-popup [class^=e-]{box-sizing:border-box}.e-grid .e-flmenu-valuediv,.e-grid-popup .e-flmenu-valuediv{padding:24px 0 0}.e-grid .e-dialog.e-checkboxfilter,.e-grid-popup .e-dialog.e-checkboxfilter{min-height:322px}.e-grid .e-checkboxfilter .e-searchbox,.e-grid-popup .e-checkboxfilter .e-searchbox{display:block}.e-grid .e-checkboxfilter .e-dlg-content,.e-grid-popup .e-checkboxfilter .e-dlg-content,.e-grid .e-checkboxfilter .e-ftrchk,.e-grid .e-checkboxfilter .e-searchbox,.e-grid-popup .e-checkboxfilter .e-ftrchk,.e-grid-popup .e-checkboxfilter .e-searchbox{padding-left:9px}.e-grid .e-checkboxfiltertext,.e-grid-popup .e-checkboxfiltertext{width:150px;word-break:normal}.e-grid .e-checkboxlist,.e-grid-popup .e-checkboxlist{height:200px;margin-top:5px;min-height:160px;overflow-y:auto}.e-grid .e-checkboxlist.e-checkbox-infinitescroll,.e-grid-popup .e-checkboxlist.e-checkbox-infinitescroll{border-top-style:solid;border-top-color:#0000001f;border-top-width:1px;margin-top:0;overflow-x:auto}.e-grid .e-checkboxlist.e-checkbox-infinitescroll .e-checkbox-wrapper .e-label.e-checkboxfiltertext,.e-grid-popup .e-checkboxlist.e-checkbox-infinitescroll .e-checkbox-wrapper .e-label.e-checkboxfiltertext{white-space:nowrap}.e-grid.e-rtl .e-checkboxfilter .e-dlg-content,.e-grid-popup.e-rtl .e-checkboxfilter .e-dlg-content{padding-left:18px;padding-right:9px}.e-grid.e-rtl .e-checkboxfilter .e-ftrchk,.e-grid.e-rtl .e-checkboxfilter .e-searchbox,.e-grid-popup.e-rtl .e-checkboxfilter .e-ftrchk,.e-grid-popup.e-rtl .e-checkboxfilter .e-searchbox{padding-left:0;padding-right:9px}.e-grid.e-rtl .e-searchclear,.e-grid-popup.e-rtl .e-searchclear,.e-grid.e-rtl .e-cc-searchdiv span.e-ccsearch-icon.e-icons,.e-grid-popup.e-rtl .e-cc-searchdiv span.e-ccsearch-icon.e-icons{float:left}.e-grid .e-searchclear,.e-grid-popup .e-searchclear{float:right}.e-grid .e-checkfltrnmdiv,.e-grid-popup .e-checkfltrnmdiv{height:60px;padding:23px;text-align:center}.e-grid .e-checkboxlist>span,.e-grid-popup .e-checkboxlist>span{padding-left:9px}.e-grid .e-chk-hidden,.e-grid-popup .e-chk-hidden{-moz-appearance:none;height:1px;opacity:0;width:1px}.e-grid .e-checkselect,.e-grid .e-checkselectall,.e-grid-popup .e-checkselect,.e-grid-popup .e-checkselectall{margin:0;opacity:0;position:absolute;width:0}.e-grid .e-ftrchk,.e-grid-popup .e-ftrchk{padding-bottom:9px;padding-top:9px}.e-grid .e-ccdlg.e-sticky,.e-grid-popup .e-ccdlg.e-sticky{position:fixed;z-index:10}.e-grid .e-ccdlg .e-dlg-content,.e-grid-popup .e-ccdlg .e-dlg-content{margin:20px 0 0;padding:16px 18px 13px 9px;overflow:visible}.e-grid .e-ccdlg .e-checkbox-wrapper.e-control.e-keyboard,.e-grid-popup .e-ccdlg .e-checkbox-wrapper.e-control.e-keyboard{padding-left:9px}.e-grid .e-ccdlg .e-main-div,.e-grid-popup .e-ccdlg .e-main-div{box-sizing:border-box;position:relative}.e-grid .e-ccdlg .e-ccul-ele,.e-grid-popup .e-ccdlg .e-ccul-ele{margin:13px 0;padding:0}.e-grid .e-ccdlg .e-checkbox-infinitescroll .e-ccul-ele,.e-grid-popup .e-ccdlg .e-checkbox-infinitescroll .e-ccul-ele{margin:0}.e-grid .e-ccdlg li.e-cclist,.e-grid-popup .e-ccdlg li.e-cclist{padding:9px 0}.e-grid .e-ccdlg .e-checkbox-wrapper .e-frame,.e-grid-popup .e-ccdlg .e-checkbox-wrapper .e-frame{margin-left:0}.e-grid .e-ccdlg label.e-cc,.e-grid-popup .e-ccdlg label.e-cc{margin:0}.e-grid .e-ccdlg .e-footer-content,.e-grid-popup .e-ccdlg .e-footer-content{border-style:solid;border-width:1px 0 0}.e-grid .e-ccdlg .e-cc-contentdiv,.e-grid-popup .e-ccdlg .e-cc-contentdiv{height:196px;overflow-y:auto}.e-grid .e-ccdlg .e-cc-contentdiv.e-checkbox-infinitescroll,.e-grid-popup .e-ccdlg .e-cc-contentdiv.e-checkbox-infinitescroll{border-top-style:solid;border-top-width:1px;border-top-color:#0000001f}.e-grid .e-ccdlg .e-cc-searchdiv,.e-grid-popup .e-ccdlg .e-cc-searchdiv{border-style:solid;border-width:0 0 2px;left:4px;opacity:.6;position:absolute;right:0;top:-46px}.e-grid .e-ccdlg .e-cc-searchdiv span.e-ccsearch-icon.e-icons,.e-grid-popup .e-ccdlg .e-cc-searchdiv span.e-ccsearch-icon.e-icons{float:right;opacity:.6;padding:5px 2px}.e-grid .e-ccdlg .e-cc-searchdiv span.e-ccsearch-icon.e-cc-cancel,.e-grid-popup .e-ccdlg .e-cc-searchdiv span.e-ccsearch-icon.e-cc-cancel{font-size:11px;padding:5px 2px 6px}.e-grid .e-ccdlg .e-cc-searchdiv.e-input-focus,.e-grid-popup .e-ccdlg .e-cc-searchdiv.e-input-focus,.e-grid .e-ccdlg .e-cc-searchdiv.e-input-focus span.e-ccsearch-icon.e-icons,.e-grid-popup .e-ccdlg .e-cc-searchdiv.e-input-focus span.e-ccsearch-icon.e-icons{opacity:1}.e-grid .e-ccdlg .e-innerdiv.e-ccnmdiv,.e-grid-popup .e-ccdlg .e-innerdiv.e-ccnmdiv{height:60px;padding:23px;text-align:center}.e-grid .e-ccdlg .e-cc-lab-name,.e-grid .e-ccdlg .e-checkbox-wrapper .e-label,.e-grid-popup .e-ccdlg .e-cc-lab-name,.e-grid-popup .e-ccdlg .e-checkbox-wrapper .e-label{text-overflow:ellipsis}.e-grid .e-ccdlg .e-cc-chbox,.e-grid-popup .e-ccdlg .e-cc-chbox{margin:3px;vertical-align:middle}.e-grid .e-ccdlg .e-cc-lab-name,.e-grid-popup .e-ccdlg .e-cc-lab-name{padding:7px;vertical-align:middle}.e-grid .e-ccdlg .e-cc.e-input,.e-grid .e-ccdlg .e-cc.e-input:focus,.e-grid-popup .e-ccdlg .e-cc.e-input,.e-grid-popup .e-ccdlg .e-cc.e-input:focus{border:0;padding-bottom:8px;padding-top:4px;padding-left:4px}.e-grid .e-mask.e-skeleton,.e-grid-popup .e-mask.e-skeleton{display:inline-block;height:10px;width:80%}.e-grid .e-mask.e-mask-group-intent,.e-grid-popup .e-mask.e-mask-group-intent{margin-left:7px;width:16px}.e-grid .e-mask.e-mask-detail-intent,.e-grid-popup .e-mask.e-mask-detail-intent{width:16px}.e-grid .e-mask.e-mask-checkbox-intent,.e-grid-popup .e-mask.e-mask-checkbox-intent{margin-left:3px;margin-right:16px;width:20px}.e-grid .e-mask.e-mask-checkbox-filter-intent,.e-grid-popup .e-mask.e-mask-checkbox-filter-intent{width:13px}.e-grid .e-mask.e-mask-checkbox-filter-span-intent,.e-grid-popup .e-mask.e-mask-checkbox-filter-span-intent{margin-left:8px}.e-grid .e-mask.e-mask-drag-intent,.e-grid-popup .e-mask.e-mask-drag-intent{margin-left:12px;width:12px}.e-grid{border-style:none solid solid;border-width:1px;border-radius:0;display:block;font-family:Roboto,Segoe UI,GeezaPro,"DejaVu Serif","sans-serif",-apple-system,BlinkMacSystemFont;font-size:13px;height:auto;position:relative}.e-grid .e-noselect,.e-grid .e-gridheader .e-headercell,.e-grid .e-gridheader .e-detailheadercell,.e-grid .e-gridheader{-webkit-user-select:none;user-select:none}.e-grid .e-groupdroparea.e-sticky,.e-grid .e-toolbar.e-sticky,.e-grid .e-gridheader.e-sticky{position:sticky;z-index:10}.e-grid .e-gridheader.e-sticky .e-headercontent .e-reorderuparrow,.e-grid .e-gridheader.e-sticky .e-headercontent .e-reorderdownarrow{position:fixed;z-index:10}.e-grid .e-groupdroparea.e-sticky{opacity:1}.e-grid .e-gridheader .e-firstrow-dragborder,.e-grid.e-rtl .e-gridheader .e-firstrow-dragborder,.e-grid .e-gridcontent .e-lastrow-dragborder,.e-grid.e-rtl .e-gridcontent .e-lastrow-dragborder{bottom:0;background-color:#e3165b;height:2px;position:absolute;z-index:5}.e-grid .e-frozenrow-border{background-color:#e3165b;height:2px;position:relative;z-index:5}.e-grid .e-frozenrow-border.e-frozenrow-empty{height:0}.e-grid.e-top-shadow .e-frozenrow-border{height:4px;margin-top:-4px;background-color:transparent!important;clip-path:inset(0 0 -15px 0);box-shadow:0 4px 8px #0000001f}.e-grid .e-dropitemscount{border:1px solid #fff;border-radius:17px;box-sizing:border-box;font-size:12px;line-height:normal;padding:3px 7px 4px;margin-left:-8px;min-width:12px;position:absolute;text-align:center;top:-10px;z-index:5}.e-grid.e-rtl .e-dropitemscount{left:-6px!important}.e-grid.e-rtl .e-toolbar .e-toolbar-item.e-search-wrapper .e-sicon.e-clear-icon{margin:0;padding:4px 0 4px 6px}.e-grid.e-verticallines .e-cloneproperties.e-draganddrop .e-rowdragdrop,.e-grid.e-bothlines .e-cloneproperties.e-draganddrop .e-rowdragdrop{border-top:1px solid #e0e0e0;border-right:1px solid #e0e0e0;border-bottom:0}.e-grid .e-gridcontent tr.e-row:first-child .e-rowcell.e-dragborder,.e-grid .e-gridcontent .e-rowcell.e-dragborder,.e-grid .e-gridcontent .e-rowdragdrop.e-dragborder,.e-grid .e-gridcontent .e-detailrowcollapse.e-dragborder,.e-grid .e-gridcontent .e-detailrowexpand.e-dragborder,.e-grid .e-gridheader tr.e-row:first-child .e-rowcell.e-dragborder,.e-grid .e-gridheader .e-rowcell.e-dragborder,.e-grid .e-gridheader .e-rowdragdrop.e-dragborder,.e-grid .e-gridheader .e-detailrowcollapse.e-dragborder,.e-grid .e-gridheader .e-detailrowexpand.e-dragborder,.e-grid.e-rtl .e-gridcontent tr.e-row:first-child .e-rowcell.e-dragborder,.e-grid.e-rtl .e-gridcontent .e-rowcell.e-dragborder,.e-grid.e-rtl .e-gridcontent .e-rowdragdrop.e-dragborder,.e-grid.e-rtl .e-gridcontent .e-detailrowcollapse.e-dragborder,.e-grid.e-rtl .e-gridcontent .e-detailrowexpand.e-dragborder,.e-grid.e-rtl .e-gridheader tr.e-row:first-child .e-rowcell.e-dragborder,.e-grid.e-rtl .e-gridheader .e-rowcell.e-dragborder,.e-grid.e-rtl .e-gridheader .e-rowdragdrop.e-dragborder,.e-grid.e-rtl .e-gridheader .e-detailrowcollapse.e-dragborder,.e-grid.e-rtl .e-gridheader .e-detailrowexpand.e-dragborder{z-index:5;box-shadow:0 2px #e3165b}.e-grid .e-gridcontent tr.e-row:first-child .e-rowcell.e-dragborder.e-leftfreeze,.e-grid .e-gridcontent tr.e-row:first-child .e-rowcell.e-dragborder.e-rightfreeze,.e-grid .e-gridcontent tr.e-row:first-child .e-rowcell.e-dragborder.e-fixedfreeze,.e-grid .e-gridcontent .e-rowcell.e-dragborder.e-leftfreeze,.e-grid .e-gridcontent .e-rowcell.e-dragborder.e-rightfreeze,.e-grid .e-gridcontent .e-rowdragdrop.e-dragborder.e-leftfreeze,.e-grid .e-gridcontent .e-rowdragdrop.e-dragborder.e-rightfreeze,.e-grid .e-gridcontent .e-rowdragdrop.e-dragborder.e-fixedfreeze,.e-grid .e-gridcontent .e-detailrowcollapse.e-dragborder.e-leftfreeze,.e-grid .e-gridcontent .e-detailrowcollapse.e-dragborder.e-rightfreeze,.e-grid .e-gridcontent .e-detailrowcollapse.e-dragborder.e-fixedfreeze,.e-grid .e-gridcontent .e-detailrowexpand.e-dragborder.e-leftfreeze,.e-grid .e-gridcontent .e-detailrowexpand.e-dragborder.e-rightfreeze,.e-grid .e-gridcontent .e-detailrowexpand.e-dragborder.e-fixedfreeze,.e-grid .e-gridheader tr.e-row:first-child .e-rowcell.e-dragborder.e-leftfreeze,.e-grid .e-gridheader tr.e-row:first-child .e-rowcell.e-dragborder.e-rightfreeze,.e-grid .e-gridheader tr.e-row:first-child .e-rowcell.e-dragborder.e-fixedfreeze,.e-grid .e-gridheader .e-rowcell.e-dragborder.e-leftfreeze,.e-grid .e-gridheader .e-rowcell.e-dragborder.e-rightfreeze,.e-grid .e-gridheader .e-rowdragdrop.e-dragborder.e-leftfreeze,.e-grid .e-gridheader .e-rowdragdrop.e-dragborder.e-rightfreeze,.e-grid .e-gridheader .e-rowdragdrop.e-dragborder.e-fixedfreeze,.e-grid .e-gridheader .e-detailrowcollapse.e-dragborder.e-leftfreeze,.e-grid .e-gridheader .e-detailrowcollapse.e-dragborder.e-rightfreeze,.e-grid .e-gridheader .e-detailrowcollapse.e-dragborder.e-fixedfreeze,.e-grid .e-gridheader .e-detailrowexpand.e-dragborder.e-leftfreeze,.e-grid .e-gridheader .e-detailrowexpand.e-dragborder.e-rightfreeze,.e-grid .e-gridheader .e-detailrowexpand.e-dragborder.e-fixedfreeze,.e-grid.e-rtl .e-gridcontent tr.e-row:first-child .e-rowcell.e-dragborder.e-leftfreeze,.e-grid.e-rtl .e-gridcontent tr.e-row:first-child .e-rowcell.e-dragborder.e-rightfreeze,.e-grid.e-rtl .e-gridcontent tr.e-row:first-child .e-rowcell.e-dragborder.e-fixedfreeze,.e-grid.e-rtl .e-gridcontent .e-rowcell.e-dragborder.e-leftfreeze,.e-grid.e-rtl .e-gridcontent .e-rowcell.e-dragborder.e-rightfreeze,.e-grid.e-rtl .e-gridcontent .e-rowdragdrop.e-dragborder.e-leftfreeze,.e-grid.e-rtl .e-gridcontent .e-rowdragdrop.e-dragborder.e-rightfreeze,.e-grid.e-rtl .e-gridcontent .e-rowdragdrop.e-dragborder.e-fixedfreeze,.e-grid.e-rtl .e-gridcontent .e-detailrowcollapse.e-dragborder.e-leftfreeze,.e-grid.e-rtl .e-gridcontent .e-detailrowcollapse.e-dragborder.e-rightfreeze,.e-grid.e-rtl .e-gridcontent .e-detailrowcollapse.e-dragborder.e-fixedfreeze,.e-grid.e-rtl .e-gridcontent .e-detailrowexpand.e-dragborder.e-leftfreeze,.e-grid.e-rtl .e-gridcontent .e-detailrowexpand.e-dragborder.e-rightfreeze,.e-grid.e-rtl .e-gridcontent .e-detailrowexpand.e-dragborder.e-fixedfreeze,.e-grid.e-rtl .e-gridheader tr.e-row:first-child .e-rowcell.e-dragborder.e-leftfreeze,.e-grid.e-rtl .e-gridheader tr.e-row:first-child .e-rowcell.e-dragborder.e-rightfreeze,.e-grid.e-rtl .e-gridheader tr.e-row:first-child .e-rowcell.e-dragborder.e-fixedfreeze,.e-grid.e-rtl .e-gridheader .e-rowcell.e-dragborder.e-leftfreeze,.e-grid.e-rtl .e-gridheader .e-rowcell.e-dragborder.e-rightfreeze,.e-grid.e-rtl .e-gridheader .e-rowdragdrop.e-dragborder.e-leftfreeze,.e-grid.e-rtl .e-gridheader .e-rowdragdrop.e-dragborder.e-rightfreeze,.e-grid.e-rtl .e-gridheader .e-rowdragdrop.e-dragborder.e-fixedfreeze,.e-grid.e-rtl .e-gridheader .e-detailrowcollapse.e-dragborder.e-leftfreeze,.e-grid.e-rtl .e-gridheader .e-detailrowcollapse.e-dragborder.e-rightfreeze,.e-grid.e-rtl .e-gridheader .e-detailrowcollapse.e-dragborder.e-fixedfreeze,.e-grid.e-rtl .e-gridheader .e-detailrowexpand.e-dragborder.e-leftfreeze,.e-grid.e-rtl .e-gridheader .e-detailrowexpand.e-dragborder.e-rightfreeze,.e-grid.e-rtl .e-gridheader .e-detailrowexpand.e-dragborder.e-fixedfreeze{z-index:6}.e-grid .e-gridcontent .e-rowcell.e-dragtop,.e-grid .e-gridcontent .e-rowdragdrop.e-dragtop,.e-grid .e-gridcontent .e-rowcell.e-dragtop.e-dragright,.e-grid .e-gridheader .e-rowcell.e-dragtop,.e-grid .e-gridheader .e-rowdragdrop.e-dragtop,.e-grid .e-gridheader .e-rowcell.e-dragtop.e-dragright,.e-grid.e-rtl .e-gridcontent .e-rowcell.e-dragtop,.e-grid.e-rtl .e-gridcontent .e-rowdragdrop.e-dragtop,.e-grid.e-rtl .e-gridcontent .e-rowcell.e-dragtop.e-dragright,.e-grid.e-rtl .e-gridheader .e-rowcell.e-dragtop,.e-grid.e-rtl .e-gridheader .e-rowdragdrop.e-dragtop,.e-grid.e-rtl .e-gridheader .e-rowcell.e-dragtop.e-dragright{border-top:1px dashed #e3165b}.e-grid .e-gridcontent .e-rowdragdrop.e-dragtop.e-dragleft,.e-grid .e-gridcontent .e-rowdragdrop.e-dragleft,.e-grid .e-gridcontent .e-rowdragdrop.e-dragbottom.e-dragleft,.e-grid .e-gridheader .e-rowdragdrop.e-dragtop.e-dragleft,.e-grid .e-gridheader .e-rowdragdrop.e-dragleft,.e-grid .e-gridheader .e-rowdragdrop.e-dragbottom.e-dragleft,.e-grid.e-rtl .e-gridcontent .e-rowdragdrop.e-dragtop.e-dragleft,.e-grid.e-rtl .e-gridcontent .e-rowdragdrop.e-dragleft,.e-grid.e-rtl .e-gridcontent .e-rowdragdrop.e-dragbottom.e-dragleft,.e-grid.e-rtl .e-gridheader .e-rowdragdrop.e-dragtop.e-dragleft,.e-grid.e-rtl .e-gridheader .e-rowdragdrop.e-dragleft,.e-grid.e-rtl .e-gridheader .e-rowdragdrop.e-dragbottom.e-dragleft{border-left:1px dashed #e3165b}.e-grid .e-gridcontent .e-rowcell.e-dragright,.e-grid .e-gridheader .e-rowcell.e-dragright,.e-grid.e-rtl .e-gridcontent .e-rowcell.e-dragright,.e-grid.e-rtl .e-gridheader .e-rowcell.e-dragright{border-right:1px dashed #e3165b}.e-grid .e-gridcontent .e-rowcell.e-dragbottom,.e-grid .e-gridcontent .e-rowcell.e-lastrowcell.e-dragbottom,.e-grid .e-gridcontent .e-rowcell.e-dragtop.e-dragbottom,.e-grid .e-gridcontent .e-rowdragdrop.e-dragbottom,.e-grid .e-gridheader .e-rowcell.e-dragbottom,.e-grid .e-gridheader .e-rowcell.e-lastrowcell.e-dragbottom,.e-grid .e-gridheader .e-rowcell.e-dragtop.e-dragbottom,.e-grid .e-gridheader .e-rowdragdrop.e-dragbottom,.e-grid.e-rtl .e-gridcontent .e-rowcell.e-dragbottom,.e-grid.e-rtl .e-gridcontent .e-rowcell.e-lastrowcell.e-dragbottom,.e-grid.e-rtl .e-gridcontent .e-rowcell.e-dragtop.e-dragbottom,.e-grid.e-rtl .e-gridcontent .e-rowdragdrop.e-dragbottom,.e-grid.e-rtl .e-gridheader .e-rowcell.e-dragbottom,.e-grid.e-rtl .e-gridheader .e-rowcell.e-lastrowcell.e-dragbottom,.e-grid.e-rtl .e-gridheader .e-rowcell.e-dragtop.e-dragbottom,.e-grid.e-rtl .e-gridheader .e-rowdragdrop.e-dragbottom{border-bottom:1px dashed #e3165b}.e-grid .e-gridcontent tr.e-row:first-child .e-rowcell.e-dragborder:not(.e-leftfreeze,.e-rightfreeze,.e-fixedfreeze),.e-grid .e-gridcontent .e-rowcell.e-dragborder:not(.e-leftfreeze,.e-rightfreeze,.e-fixedfreeze),.e-grid .e-gridcontent .e-rowdragdrop.e-dragborder:not(.e-leftfreeze,.e-rightfreeze,.e-fixedfreeze),.e-grid .e-gridcontent .e-detailrowcollapse.e-dragborder:not(.e-leftfreeze,.e-rightfreeze,.e-fixedfreeze),.e-grid .e-gridcontent .e-detailrowexpand.e-dragborder:not(.e-leftfreeze,.e-rightfreeze,.e-fixedfreeze),.e-grid .e-gridheader tr.e-row:first-child .e-rowcell.e-dragborder:not(.e-leftfreeze,.e-rightfreeze,.e-fixedfreeze),.e-grid .e-gridheader .e-rowcell.e-dragborder:not(.e-leftfreeze,.e-rightfreeze,.e-fixedfreeze),.e-grid .e-gridheader .e-rowdragdrop.e-dragborder:not(.e-leftfreeze,.e-rightfreeze,.e-fixedfreeze),.e-grid .e-gridheader .e-detailrowcollapse.e-dragborder:not(.e-leftfreeze,.e-rightfreeze,.e-fixedfreeze),.e-grid .e-gridheader .e-detailrowexpand.e-dragborder:not(.e-leftfreeze,.e-rightfreeze,.e-fixedfreeze),.e-grid.e-rtl .e-gridcontent tr.e-row:first-child .e-rowcell.e-dragborder:not(.e-leftfreeze,.e-rightfreeze,.e-fixedfreeze),.e-grid.e-rtl .e-gridcontent .e-rowcell.e-dragborder:not(.e-leftfreeze,.e-rightfreeze,.e-fixedfreeze),.e-grid.e-rtl .e-gridcontent .e-rowdragdrop.e-dragborder:not(.e-leftfreeze,.e-rightfreeze,.e-fixedfreeze),.e-grid.e-rtl .e-gridcontent .e-detailrowcollapse.e-dragborder:not(.e-leftfreeze,.e-rightfreeze,.e-fixedfreeze),.e-grid.e-rtl .e-gridcontent .e-detailrowexpand.e-dragborder:not(.e-leftfreeze,.e-rightfreeze,.e-fixedfreeze),.e-grid.e-rtl .e-gridheader tr.e-row:first-child .e-rowcell.e-dragborder:not(.e-leftfreeze,.e-rightfreeze,.e-fixedfreeze),.e-grid.e-rtl .e-gridheader .e-rowcell.e-dragborder:not(.e-leftfreeze,.e-rightfreeze,.e-fixedfreeze),.e-grid.e-rtl .e-gridheader .e-rowdragdrop.e-dragborder:not(.e-leftfreeze,.e-rightfreeze,.e-fixedfreeze),.e-grid.e-rtl .e-gridheader .e-detailrowcollapse.e-dragborder:not(.e-leftfreeze,.e-rightfreeze,.e-fixedfreeze),.e-grid.e-rtl .e-gridheader .e-detailrowexpand.e-dragborder:not(.e-leftfreeze,.e-rightfreeze,.e-fixedfreeze){position:relative}.e-grid .e-gridheader thead .e-icons:not(.e-check):not(.e-stop){font-size:10px}.e-grid .e-row .e-icon-rowdragicon:before{display:block;text-indent:10px;color:#000;opacity:.54}.e-grid .e-row .e-icon-rowdragicon:before,.e-grid .e-row .e-icon-rowdragmoveicon:before{font-size:12px;font-weight:700}.e-grid .e-row .e-icon-rowdragmoveicon{padding-left:10px}.e-grid .e-draganddrop .e-rowcell,.e-grid.e-rtl .e-draganddrop .e-rowcell{padding-left:6px;padding-right:6px}.e-grid .e-gridcontent .e-rowdragdrop,.e-grid .e-gridheader .e-rowdragdrop{border-style:solid;border-width:1px 0 0 0;border-color:#e0e0e0}.e-grid .e-gridcontent .e-rowdragdrop.e-lastrowcell,.e-grid .e-gridcontent .e-recordpluscollapse.e-lastrowcell,.e-grid .e-gridcontent .e-indentcell.e-lastrowcell,.e-grid .e-gridcontent .e-groupcaption.e-lastrowcell{border-bottom-width:1px}.e-grid .e-gridcontent .e-groupcaptionrow .e-lastrowcell.e-recordplusexpand~td.e-lastrowcell.e-groupcaption,.e-grid .e-gridcontent .e-groupcaptionrow .e-lastrowcell.e-recordplusexpand~td.e-lastrowcell.e-summarycell{border-bottom-width:0}.e-grid .e-cloneproperties.e-draganddrop .e-row .e-icon-rowdragicon:before{position:relative;left:-5px}.e-grid .e-icon-rowdragicon{font-size:10px;text-indent:12px}.e-grid .e-toolbar{border-bottom:0;border-left:0;border-right:0;border-top:1px solid #e0e0e0;border-radius:0}.e-grid .e-toolbar .e-toolbar-item.e-search-wrapper .e-sicon.e-clear-icon{padding:0;min-width:18px;margin-right:8px}.e-grid .e-toolbar .e-toolbar-item.e-search-wrapper .e-sicon.e-clear-icon:before{font-size:12px}.e-grid .e-toolbar-items .e-input-group-icon.e-icons.e-sicon:hover:not(.e-clear-icon),.e-grid .e-toolbar-items .e-input-group-icon.e-icons.e-sicon:active:not(.e-clear-icon),.e-grid .e-toolbar-items .e-input-group-icon.e-icons.e-sicon:focus:not(.e-clear-icon){background:none;box-shadow:none}.e-grid .e-toolbar-items .e-input-group-icon.e-icons.e-sicon:not(.e-clear-icon){border:none}.e-grid:not(.sf-grid) .e-res-toolbar .e-toolbar-items .e-search-wrapper .e-search-icon{padding:6px 9px}.e-grid .e-res-toolbar{border-bottom:1px solid;border-bottom-color:#e0e0e0}.e-grid .e-res-toolbar .e-toolbar-items{min-height:initial}.e-grid .e-res-toolbar .e-toolbar-items .e-tbar-btn:hover,.e-grid .e-res-toolbar .e-toolbar-items .e-tbar-btn:active,.e-grid .e-res-toolbar .e-toolbar-items .e-tbar-btn:focus,.e-grid .e-res-toolbar .e-toolbar-items .e-search-icon:hover,.e-grid .e-res-toolbar .e-toolbar-items .e-search-icon:active,.e-grid .e-res-toolbar .e-toolbar-items .e-search-icon:focus,.e-grid .e-res-toolbar .e-toolbar-items .e-sicon.e-clear-icon:hover,.e-grid .e-res-toolbar .e-toolbar-items .e-sicon.e-clear-icon:active,.e-grid .e-res-toolbar .e-toolbar-items .e-sicon.e-clear-icon:focus{background:none}.e-grid .e-res-toolbar .e-toolbar-items .e-icons{color:#000}.e-grid .e-res-toolbar .e-toolbar-items .e-toolbar-left .e-toolbar-item .e-tbar-btn .e-resfilter-icon{font-size:22px}.e-grid .e-res-toolbar .e-toolbar-items .e-responsive-right{width:calc(100% - 50px)}.e-grid .e-res-toolbar .e-toolbar-items .e-responsive-right.e-search-wrapper{width:auto}.e-grid .e-res-toolbar .e-toolbar-items .e-responsive-right .e-search-wrapper .e-input-group:before,.e-grid .e-res-toolbar .e-toolbar-items .e-responsive-right .e-search-wrapper .e-input-group:after{background:none}.e-grid .e-res-toolbar .e-toolbar-items .e-toolbar-right:not(.e-responsive-right) .e-search-wrapper:not(.e-responsive-right){min-width:40px}.e-grid .e-res-toolbar .e-toolbar-items .e-toolbar-right .e-search-wrapper{padding-left:18px;padding-right:0}.e-grid .e-res-toolbar .e-toolbar-items .e-toolbar-right .e-search-wrapper .e-search-icon{font-size:18px;margin-top:0;padding:6px 9px}.e-grid .e-res-toolbar .e-toolbar-items .e-toolbar-right .e-search-wrapper .e-input-group{border:0;opacity:1;padding:0 9px 0 6px;width:100%}.e-grid .e-res-toolbar .e-toolbar-items .e-toolbar-right .e-search-wrapper .e-input-group .e-input{margin-top:0}.e-grid .e-res-toolbar .e-toolbar-items .e-toolbar-right .e-search-wrapper .e-input-group .e-search-icon{margin-top:7px;padding-left:0}.e-grid .e-res-toolbar .e-toolbar-items .e-toolbar-right .e-search-wrapper:has(.e-input-group){width:100%}.e-grid .e-res-toolbar .e-toolbar-items .e-responsive-right .e-search-wrapper{padding-left:0}.e-grid.e-rtl .e-res-toolbar .e-toolbar-items .e-responsive-right .e-search-wrapper{padding-left:26px}.e-grid.e-rtl .e-res-toolbar .e-toolbar-items .e-responsive-right .e-search-wrapper .e-sicon.e-clear-icon{margin:14px 0 5px 8px}.e-grid .e-toolbar-items .e-toolbar-item.e-search-wrapper{padding-bottom:6px;padding-top:1px}.e-grid .e-toolbar-items .e-toolbar-item.e-search-wrapper .e-search:focus{opacity:1}.e-grid .e-toolbar-items .e-toolbar-item.e-search-wrapper .e-search::placeholder{color:#0000006b}.e-grid .e-toolbar-items .e-toolbar-item.e-search-wrapper .e-search{margin-bottom:0;opacity:1;width:230px}.e-grid .e-toolbar-items .e-toolbar-item.e-search-wrapper .e-search.e-input-focus{opacity:1}.e-grid .e-toolbar-items .e-toolbar-item.e-search-wrapper .e-search .e-search-icon{min-width:18px}.e-grid .e-group-animator .e-groupheadercell,.e-grid .e-group-animator .e-groupheadercell:hover{margin:12px 0;border-bottom-width:1px}.e-grid .e-groupdroparea.e-group-animate.e-grouped{height:54px;padding:0 12px;border-bottom-width:0}.e-grid.e-rtl .e-group-animator{float:right}.e-grid.e-rtl .e-group-animate .e-groupheadercell,.e-grid.e-rtl .e-group-animate .e-groupheadercell:hover{margin-right:0;margin-left:0}.e-grid.e-rtl .e-group-animate.e-groupdroparea .e-nextgroup{transform:rotate(180deg);margin-top:16px}.e-grid .e-group-animate.e-groupdroparea .e-nextgroup{margin-top:9px}.e-grid .e-group-animate span.e-nextgroup.e-icons.e-icon-next{display:inline-block;line-height:32px;float:left;height:24px;padding:0;vertical-align:middle}.e-grid .e-groupdroparea.e-group-animate .e-drag.e-icon-drag{font-size:11px;line-height:25px;display:inline-block;height:24px;padding:0;vertical-align:middle}.e-grid .e-group-animate .e-icon-drag.e-icons{margin-left:0}.e-grid .e-group-animate .e-drag.e-icon-drag:before{opacity:.7}.e-grid .e-groupdroparea.e-group-animate span.e-drag.e-icons.e-icon-drag{cursor:move}.e-grid .e-groupdroparea.e-grouped{padding:9px 0 10px}.e-grid.e-default .e-gridheader.e-stackedfilter .e-grouptopleftcell{border-top:0}.e-grid.e-default .e-gridheader.e-stackedfilter tr:first-child th.e-grouptopleftcell{border-bottom:1px solid}.e-grid.e-default .e-gridheader.e-stackedfilter tr:last-child th.e-grouptopleftcell{border-top:1px solid}.e-grid.e-default.e-horizontallines .e-gridheader.e-stackedfilter .e-grouptopleftcell{border-top:0}.e-grid.e-default.e-horizontallines .e-gridheader.e-stackedfilter tr:first-child th.e-grouptopleftcell{border-bottom:1px solid}.e-grid.e-default.e-horizontallines .e-gridheader.e-stackedfilter tr:last-child th.e-grouptopleftcell{border-top:1px solid}.e-grid.e-default.e-verticallines .e-gridheader.e-stackedfilter .e-grouptopleftcell{border-top:0}.e-grid.e-default.e-verticallines .e-gridheader.e-stackedfilter tr:last-child th.e-grouptopleftcell{border-top:0}.e-grid.e-default.e-hidelines .e-gridheader.e-stackedfilter tr:first-child th.e-grouptopleftcell{border-bottom:0}.e-grid.e-default.e-hidelines .e-gridheader.e-stackedfilter tr:last-child th.e-grouptopleftcell{border-top:0}.e-grid.e-default .e-grouptopleftcell,.e-grid.e-default .e-rowdragheader{border-top:1px solid}.e-grid.e-default .e-gridheader .e-headercell.e-firstheader,.e-grid.e-default.e-horizontallines .e-headercell.e-firstheader{border-left:1px solid}.e-grid.e-default.e-verticallines .e-grouptopleftcell,.e-grid.e-default.e-verticallines .e-rowdragheader,.e-grid.e-default.e-bothlines .e-grouptopleftcell,.e-grid.e-default.e-bothlines .e-rowdragheader,.e-grid.e-default.e-hidelines .e-grouptopleftcell,.e-grid.e-default.e-hidelines .e-rowdragheader,.e-grid.e-default.e-verticallines .e-detailrowcollapse,.e-grid.e-default.e-verticallines .e-detailrowexpand,.e-grid.e-default.e-verticallines .e-rowdragdrop,.e-grid.e-default.e-hidelines .e-detailrowcollapse,.e-grid.e-default.e-hidelines .e-detailrowexpand,.e-grid.e-default.e-hidelines .e-rowdragdrop{border-top-width:0}.e-grid.e-verticallines .e-firstchildrow .e-rowdragdropcell,.e-grid.e-bothlines .e-firstchildrow .e-rowdragdropcell{border-top-width:1px}.e-grid.e-default.e-horizontallines .e-grouptopleftcell{border-top:1px solid}.e-grid .e-gridheader .e-headercell .e-rhandler,.e-grid .e-gridheader .e-headercell .e-rsuppress{height:100%;position:absolute;right:0;top:0;width:4px}.e-grid .e-gridheader .e-headercell.e-leftfreeze.e-freezeleftborder .e-rhandler{border-right:0}.e-grid.e-default.e-hidelines .e-headercell.e-firstheader,.e-grid.e-rtl .e-gridheader .e-headercell.e-leftfreeze.e-freezeleftborder .e-rhandler{border-left:0}.e-grid.e-device .e-gridheader .e-headercell .e-rhandler{width:14px}.e-grid.e-rtl .e-gridheader .e-headercell .e-rhandler,.e-grid.e-rtl .e-gridheader .e-headercell .e-rsuppress{left:0;right:auto}.e-grid.e-resize-lines .e-gridheader th.e-headercell.e-lastcell .e-rhandler{border-right-width:0}.e-grid .e-rhelper{position:absolute;width:1px}.e-grid .e-rhelper,.e-grid .e-virtual-rhandler{z-index:5}.e-grid.e-device .e-ricon:before{border-bottom:6px solid transparent;border-top:6px solid transparent;content:"";display:block;height:0;position:absolute;width:20px;top:4px;border-right:6px solid;right:4px}.e-grid.e-device .e-ricon:after{border-bottom:6px solid transparent;border-top:6px solid transparent;content:"";display:block;height:0;position:absolute;width:20px;top:4px;left:4px;border-left:6px solid;z-index:3}.e-grid.e-rcursor,.e-grid .e-gridheader .e-stackedheadercell.e-rcursor,.e-grid .e-gridheader .e-rcursor{cursor:col-resize}.e-grid .e-disablepointer,.e-grid .e-defaultcur,.e-grid .e-headercell,.e-grid .e-headercell.e-stackedheadercell,.e-grid .e-headercell.e-defaultcursor,.e-grid.e-editing .e-gridheader .e-rcursor{cursor:default}.e-grid .e-table{border-collapse:separate;table-layout:fixed;width:100%}.e-grid .e-tableborder{border-right:1px solid}.e-grid .e-virtualtable{will-change:transform;z-index:1}.e-grid .e-headercelldiv{border:0 none;display:block;font-size:12px;font-weight:500;height:29px;line-height:30px;padding:0 .6em;margin:-7px;overflow:hidden;text-align:left;text-transform:none;-webkit-user-select:none;user-select:none}.e-grid .e-rightalign:not(.e-fltr-icon) .e-headercelldiv,.e-grid .e-leftalign:not(.e-fltr-icon) .e-headercelldiv,.e-grid .e-centeralign:not(.e-fltr-icon) .e-headercelldiv{padding:0 .6em}.e-grid .e-headercelldiv.e-headerchkcelldiv{overflow:visible}.e-grid .e-headercell.e-templatecell .e-headercelldiv{height:auto;min-height:29px}.e-grid .e-gridheader .e-headercontent .e-rightalign .e-headercelldiv.e-headerchkcelldiv,.e-grid .e-gridheader .e-headercontent .e-centeralign .e-headercelldiv.e-headerchkcelldiv{padding:0 .6em}.e-grid .e-gridheader .e-headercontent .e-reorderuparrow,.e-grid .e-gridheader .e-headercontent .e-reorderdownarrow,.e-grid .e-gridheader .e-headercontent .e-reorderuparrow-virtual,.e-grid .e-gridheader .e-headercontent .e-reorderdownarrow-virtual{font-size:8px;margin-left:-1px;margin-top:-4.5px;position:absolute;z-index:10}.e-grid .e-gridheader .e-headercontent .e-reorderuparrow{margin-top:-4.5px}.e-grid .e-gridheader .e-headercontent .e-reorderdownarrow{margin-top:4.5px}.e-grid .e-filtermenudiv:hover,.e-grid .e-headercell.e-mousepointer,.e-grid .e-headercell.e-stackedheadercell.e-mousepointer{cursor:pointer}.e-grid:not(.e-left-shadow,.e-right-shadow) .e-gridcontent tr:first-child td{border-top:0 none}.e-grid .e-gridcontent tr:first-child td.e-xlsel-top-border{border-top-width:2px}.e-grid .e-gridheader tr:first-child th{border-top:0 none}.e-grid .e-gridheader tr th:last-child.e-filterbarcell{padding-right:21px}.e-grid .e-gridheader tr th:last-child{padding-right:21px}.e-grid .e-gridheader tr th:first-child,.e-grid .e-gridheader tr th:first-child.e-filterbarcell{padding-left:21px}.e-grid .e-gridheader{border-bottom-style:solid;border-bottom-width:1px;border-top-style:solid;border-top-width:1px}.e-grid .e-frozenhdr{border-bottom-width:0}.e-grid.e-bothlines .e-filterbarcell,.e-grid.e-bothlines .e-filterbarcelldisabled{border-width:1px 0 0 1px;border-top-width:1px}.e-grid .e-headercell,.e-grid .e-detailheadercell{border-style:solid;border-width:0;font-size:12px;font-weight:500;height:42px;overflow:hidden;padding:0 21px;position:relative;text-align:left}.e-grid.e-device .e-headercell{padding:0 21px}.e-grid.e-device .e-headercell:first-child{padding:0 12px 0 16px}.e-grid.e-device .e-headercell:last-child{padding:0 16px 0 12px}.e-grid .e-rowcell{border-style:solid;border-width:1px 0 0 0;display:table-cell;font-size:13px;line-height:20px;padding:8px 21px;overflow:hidden;vertical-align:middle;white-space:nowrap;width:auto}.e-grid.e-left-shadow .e-leftfreeze.e-freezeleftborder.e-focused:not(.e-menu-item,.e-xlsel-top-border,.e-xlsel-left-border,.e-xlsel-bottom-border,.e-xlsel-right-border),.e-grid.e-rtl.e-left-shadow .e-leftfreeze.e-freezeleftborder.e-focused:not(.e-menu-item,.e-xlsel-top-border,.e-xlsel-left-border,.e-xlsel-bottom-border,.e-xlsel-right-border),.e-grid.e-rtl.e-default.e-left-shadow .e-leftfreeze.e-freezeleftborder.e-focused:not(.e-menu-item,.e-xlsel-top-border,.e-xlsel-left-border,.e-xlsel-bottom-border,.e-xlsel-right-border),.e-grid.e-wrap.e-left-shadow .e-leftfreeze.e-freezeleftborder.e-focused:not(.e-menu-item,.e-xlsel-top-border,.e-xlsel-left-border,.e-xlsel-bottom-border,.e-xlsel-right-border){line-height:18px;border-width:1.5px}.e-grid.e-right-shadow .e-rightfreeze.e-freezerightborder.e-focused:not(.e-menu-item,.e-xlsel-top-border,.e-xlsel-left-border,.e-xlsel-bottom-border,.e-xlsel-right-border),.e-grid.e-rtl.e-right-shadow .e-rightfreeze.e-freezerightborder.e-focused:not(.e-menu-item,.e-xlsel-top-border,.e-xlsel-left-border,.e-xlsel-bottom-border,.e-xlsel-right-border),.e-grid.e-rtl.e-default.e-right-shadow .e-rightfreeze.e-freezerightborder.e-focused:not(.e-menu-item,.e-xlsel-top-border,.e-xlsel-left-border,.e-xlsel-bottom-border,.e-xlsel-right-border),.e-grid.e-wrap.e-right-shadow .e-rightfreeze.e-freezerightborder.e-focused:not(.e-menu-item,.e-xlsel-top-border,.e-xlsel-left-border,.e-xlsel-bottom-border,.e-xlsel-right-border){line-height:18px;border-width:1.5px}.e-grid:not(.e-grid-min-height) .e-gridcontent .e-content tr.e-insertedrow .e-rowcell:empty,.e-grid .e-row.e-emptyrow{height:37px}.e-grid .e-editedrow .e-input-group input.e-input,.e-grid .e-editedrow .e-input-group.e-control-wrapper input.e-input,.e-grid .e-addedrow .e-input-group input.e-input,.e-grid .e-addedrow .e-input-group.e-control-wrapper input.e-input{min-height:unset}.e-grid:not(.e-grid-min-height) .e-gridcontent tr td:not(.e-indentcell):first-child:empty,.e-grid:not(.e-grid-min-height) .e-gridcontent tr.e-row .e-rowcell:empty{height:36px}.e-grid.e-afenabled .e-headercontent,.e-grid.e-enabledboxbdr .e-headercontent{position:relative}.e-grid .e-rowcell:first-child,.e-grid .e-summarycell:first-child{padding-left:21px}.e-grid .e-rowcell:last-child,.e-grid .e-summarycell:last-child{padding-right:21px}.e-grid .e-unboundcell,.e-grid .e-editedrow .e-normaledit .e-unboundcell,.e-grid .e-addedrow .e-normaledit .e-unboundcell{padding-bottom:4px;padding-top:4px}.e-grid .e-unboundcelldiv>button{margin:0 3.5px}.e-grid .e-unboundcelldiv{margin:0 -3.5px}.e-grid .e-summarycell{border-style:solid;border-width:1px 0 0;font-size:13px;font-weight:500;height:auto;line-height:18px;padding:8px 21px;white-space:normal;text-wrap:nowrap;text-overflow:ellipsis;overflow:hidden}.e-grid .e-summarycell.e-lastrowcell{border-bottom-width:1px}.e-grid .e-summarycontent .e-indentcell,.e-grid .e-summarycontent .e-detailindentcelltop{border-width:1px 0 0}.e-grid.e-device .e-rowcell,.e-grid.e-device .e-summarycell{padding:8px 12px}.e-grid.e-device .e-rowcell:first-child,.e-grid.e-device .e-summarycell:first-child{padding:8px 12px 8px 16px}.e-grid.e-device .e-rowcell:last-child,.e-grid.e-device .e-summarycell:last-child{padding:8px 16px 8px 12px}.e-grid td.e-rowcell.e-checkbox{padding:6px 21px}.e-grid td.e-rowcell.e-checkbox input[type=checkbox]{margin-top:5px}.e-grid.e-default .e-rowcell.e-lastrowcell:not(.e-xlsel-bottom-border),.e-grid.e-default .e-detailrowcollapse.e-lastrowcell{border-bottom-width:1px}.e-grid.e-default .e-detailrow .e-lastrowcell{border-bottom:1px solid;border-bottom-color:#e0e0e0}.e-grid.e-default .e-headercell,.e-grid.e-default .e-detailheadercell{border-width:0}.e-grid.e-default .e-stackedheadercell{border-width:0 0 1px 1px}.e-grid.e-default .e-stackedheadercell.e-leftfreeze.e-freezeleftborder{border-right-width:2px}.e-grid.e-default .e-stackedheadercell.e-rightfreeze.e-freezerightborder{border-left-width:2px}.e-grid.e-default .e-stackedheadercell.e-fixedfreeze.e-freezeleftborder{border-left-width:1px}.e-grid.e-default .e-stackedheadercell.e-fixedfreeze.e-freezerightborder{border-right-width:1px}.e-grid.e-default .e-gridheader th.e-firstcell.e-movablefirst{border-left-width:0}.e-grid.e-bothlines .e-rowcell.e-lastrowcell:not(.e-xlsel-bottom-border){border-bottom-width:1px}.e-grid.e-bothlines .e-rowcell{border-width:1px 0 0 1px}.e-grid:not(.sf-grid).e-gridheader table th[rowspan],.e-grid:not(.sf-grid).e-device .e-gridheader table th[rowspan]{padding-bottom:13px;vertical-align:bottom}.e-grid .e-emptyrow td{line-height:20px;padding:.7em}.e-grid.e-responsive .e-rowcell,.e-grid.e-responsive .e-headercelldiv{text-overflow:ellipsis;white-space:nowrap}.e-grid.e-responsive .e-rowcell.e-gridchkbox,.e-grid.e-responsive .e-rowcell.e-gridchkbox-cell,.e-grid.e-responsive .e-headercelldiv.e-headerchkcelldiv,.e-grid.e-responsive .e-rowcell.e-boolcell{text-overflow:clip}.e-grid .e-addedrow .e-rowcell.e-boolcell .e-frame.e-check{color:#fff}.e-grid [aria-selected]+tr .e-detailindentcell{border-top-style:solid;border-top-width:1px}.e-grid.e-default.e-verticallines tr th:first-child:not(.e-firstcell){border-left-width:0}.e-grid.e-default.e-verticallines .e-headercell,.e-grid.e-default.e-verticallines .e-detailheadercell{border-width:0 0 0 1px}.e-grid.e-default.e-verticallines .e-headercell.e-stackedheadercell{border-bottom:1px solid}.e-grid:not(.sf-grid).e-default.e-bothlines .e-headercell,.e-grid:not(.sf-grid).e-default.e-bothlines .e-detailheadercell{border-width:0 0 0 1px}.e-grid:not(.sf-grid).e-default.e-bothlines .e-headercell.e-grid-group-first-cell{border-left-width:0}.e-grid:not(.sf-grid,.e-rtl).e-default.e-bothlines .e-headercell.e-leftfreeze.e-freezeleftborder{border-right-width:2px}.e-grid:not(.sf-grid,.e-rtl).e-default.e-bothlines .e-headercell.e-rightfreeze.e-freezerightborder{border-left-width:2px}.e-grid:not(.sf-grid,.e-rtl).e-default.e-bothlines .e-headercell.e-fixedfreeze.e-freezerightborder{border-right-width:1px}.e-grid.e-rtl:not(.sf-grid).e-default.e-bothlines .e-headercell.e-leftfreeze.e-freezeleftborder{border-left-width:2px}.e-grid.e-rtl:not(.sf-grid).e-default.e-bothlines .e-headercell.e-rightfreeze.e-freezerightborder{border-right-width:2px}.e-grid.e-rtl:not(.sf-grid).e-default.e-bothlines .e-headercell.e-fixedfreeze.e-freezeleftborder{border-right-width:1px}.e-grid:not(.sf-grid).e-default:not(.e-verticallines):not(.e-bothlines) table th[rowspan]{border-width:0 0 0 1px}.e-grid:not(.sf-grid).e-default table th[rowspan].e-leftfreeze.e-freezeleftborder{border-right-width:2px}.e-grid:not(.sf-grid).e-default table th[rowspan].e-rightfreeze.e-freezerightborder{border-left-width:2px}.e-grid:not(.sf-grid).e-default table th[rowspan].e-fixedfreeze.e-freezeleftborder{border-left-width:1px}.e-grid:not(.sf-grid).e-default table th[rowspan].e-fixedfreeze.e-freezerightborder{border-right-width:1px}.e-grid tr th.e-firstcell{border-left-style:solid;border-left-width:1px}.e-grid.e-default tr th.e-detailheadercell:first-child{border-left-width:0}.e-grid.e-default:not(.e-rtl) tr td:first-child:not(.e-xlsel-left-border,.e-fixedfreeze.e-freezeleftborder,.e-rowcell-firstchild,.e-addfreezefirstchildborder),.e-grid.e-default:not(.e-rtl) tr th.e-headercell:first-child:not(.e-firstcell):not(.e-headercell.e-frozen-left-border),.e-grid.e-default:not(.e-rtl) tr th.e-filterbarcell:first-child:not(.e-filterbarcell.e-frozen-left-border){border-left-width:0}.e-grid:not(.e-rtl).e-verticallines .e-grouptopleftcell.e-lastgrouptopleftcell,.e-grid:not(.e-rtl).e-bothlines .e-grouptopleftcell.e-lastgrouptopleftcell{border-right-width:1px;border-right-style:solid}.e-grid .e-filterbarcell .e-filtertext::-webkit-search-cancel-button,.e-grid .e-search input::-webkit-search-cancel-button{display:none}.e-grid .e-filterbarcell .e-filtertext::-ms-clear,.e-grid .e-search input::-ms-clear{display:none}.e-grid .e-hiddenrow,.e-grid .e-hide,.e-grid .e-group-animator:last-child .e-nextgroup.e-icons.e-icon-next{display:none}.e-grid .e-rowcell,.e-grid .e-gridcontent,.e-grid .e-gridheader,.e-grid .e-headercontent,.e-grid .e-groupdroparea,.e-grid .e-gridfooter,.e-grid .e-summarycontent{overflow:hidden;vertical-align:middle}.e-grid .e-sortfilterdiv{float:right;height:10px;margin:-16px 10px;padding:3px;width:10px}.e-grid .e-gridheader .e-rightalign .e-sortfilterdiv{float:left;margin:-16px 5px}.e-grid .e-gridheader .e-sortfilter .e-rightalign.e-fltr-icon .e-headercelldiv,.e-grid .e-gridheader .e-sortfilter .e-fltr-icon .e-headercelldiv{margin:-7px 15px -7px -7px}.e-grid .e-gridheader .e-sortfilter .e-centeralign.e-headercell[aria-sort=none] .e-headercelldiv,.e-grid .e-gridheader .e-sortfilter .e-centeralign.e-headercell[aria-sort=none] .e-stackedheadercelldiv,.e-grid .e-gridheader .e-sortfilter .e-centeralign.e-headercell:not([aria-sort]) .e-headercelldiv,.e-grid .e-gridheader .e-sortfilter .e-centeralign.e-headercell:not([aria-sort]) .e-stackedheadercelldiv{padding-right:.6em}.e-grid .e-gridheader .e-sortfilter .e-rightalign .e-headercelldiv,.e-grid .e-gridheader .e-rightalign .e-stackedheadercelldiv{padding:0 .6em 0 1.9em}.e-grid .e-gridheader .e-sortfilter .e-headercelldiv,.e-grid .e-gridheader .e-stackedheadercelldiv{padding:0 1.8em 0 .6em}.e-grid.e-rtl .e-gridheader .e-sortfilter .e-centeralign.e-headercell[aria-sort=none] .e-headercelldiv,.e-grid.e-rtl .e-gridheader .e-sortfilter .e-centeralign.e-headercell[aria-sort=none] .e-stackedheadercelldiv,.e-grid.e-rtl .e-gridheader .e-sortfilter .e-centeralign.e-headercell:not([aria-sort]) .e-headercelldiv,.e-grid.e-rtl .e-gridheader .e-sortfilter .e-centeralign.e-headercell:not([aria-sort]) .e-stackedheadercelldiv{padding-left:.6em}.e-grid .e-gridheader .e-headercell .e-headercelldiv.e-headerchkcelldiv{padding:0 1.8em 0 .6em}.e-grid.e-rtl .e-gridheader .e-headercell .e-headercelldiv.e-headerchkcelldiv{padding:0 .6em 0 .55em}.e-grid .e-filtermenudiv{float:right;margin:-18px -7px;padding:6px;text-align:right}.e-grid.e-print-grid-layout .e-pager,.e-grid.e-print-grid-layout .e-filterbar,.e-grid.e-print-grid-layout .e-icons:not(.e-frame),.e-grid.e-print-grid-layout .e-grouptopleftcell,.e-grid.e-print-grid-layout .e-recordpluscollapse,.e-grid.e-print-grid-layout .e-indentcell,.e-grid.e-print-grid-layout .e-recordplusexpand{display:none}.e-grid.e-print-grid-layout .e-indentcell.e-detailindentcelltop{display:table-cell}.e-grid.e-print-grid-layout .e-content{overflow-y:hidden}.e-grid.e-print-grid-layout .e-grouptext{width:auto}.e-grid.e-print-grid-layout .e-detailcell{padding:.8em .6em}.e-grid.e-print-grid{left:-1000px;top:-1000px}.e-grid .e-flbldcontent{padding:18px 18px 0}.e-grid .e-flblbtn{width:110px}.e-grid .e-sortnumber{border-radius:65%;display:inline-block;float:right;text-align:center;font-size:9px;height:15px;line-height:16px;margin:7px 5px 0 2px;width:15px}.e-grid .e-gridheader .e-fltr-icon .e-sortnumber{margin:7px 5px 0 2px}.e-grid .e-gridheader .e-rightalign.e-fltr-icon .e-sortnumber{float:left;margin:7px 2px 0 10px}.e-grid .e-gridheader .e-rightalign .e-sortnumber{float:left;margin:7px 2px 0 5px}.e-grid .e-gridheader .e-fltr-icon .e-sortfilterdiv{margin:-16px 24px}.e-grid .e-gridheader .e-rightalign.e-fltr-icon .e-sortfilterdiv{margin:-16px 5px}.e-grid.e-wrap .e-gridheader .e-rightalign .e-sortnumber{margin:1px 2px 0 15px}.e-grid.e-wrap .e-gridheader .e-sortnumber{margin:2px -5px 0 2px}.e-grid.e-wrap .e-gridheader .e-sortfilterdiv{margin:-9px 10px}.e-grid .e-columnmenu{position:absolute;right:23px;float:right;margin:-18.5px -18px;padding:6px}.e-grid.e-wrap .e-columnmenu,.e-grid.e-wrap .e-grid.e-rtl .e-columnmenu{line-height:14px}.e-grid.e-rtl .e-columnmenu{left:5px;right:auto;margin:-18px -18px -18px 3px}.e-grid .e-detailrowcollapse,.e-grid .e-detailrowexpand,.e-grid .e-rowdragdropcell{border-style:solid;border-width:1px 0 0 0}.e-grid .e-detailrowcollapse,.e-grid .e-detailrowexpand{cursor:pointer}.e-grid .e-detailindentcell{border-right-style:solid;border-right-width:1px}.e-grid .e-detailcell{border-top-style:solid;border-top-width:1px;padding:.3em;font-weight:400;text-align:left}.e-grid th.e-detailcell .e-rowcell,.e-grid th.e-detailcell .e-gridpager{text-align:left}.e-grid th.e-detailcell .e-rtl .e-rowcell,.e-grid th.e-detailcell .e-rtl .e-gridpager,.e-grid.e-rtl th.e-detailcell .e-rowcell,.e-grid.e-rtl th.e-detailcell .e-gridpager{text-align:right}.e-grid.e-verticallines .e-rowcell,.e-grid.e-verticallines .e-filterbarcell{border-width:0 0 0 1px}.e-grid.e-verticallines .e-rowcell.e-grid-group-first-cell,.e-grid.e-verticallines .e-headercell.e-grid-group-first-cell,.e-grid.e-bothlines .e-rowcell.e-grid-group-first-cell,.e-grid.e-bothlines .e-headercell.e-grid-group-first-cell{border-left-width:0}.e-grid.e-hidelines .e-rowcell,.e-grid.e-hidelines .e-headercell,.e-grid.e-hidelines .e-detailheadercell,.e-grid.e-hidelines tr th.e-firstcell,.e-grid.e-hidelines .e-filterbarcell,.e-grid.e-horizontallines .e-headercell,.e-grid.e-horizontallines .e-detailheadercell{border-width:0}.e-grid.e-horizontallines .e-headercell.e-stackedheadercell{border-width:0 0 1px 1px}.e-grid.e-horizontallines .e-rowcell,.e-grid.e-horizontallines .e-filterbarcell{border-width:1px 0 0}.e-grid.e-horizontallines .e-rowcell.e-lastrowcell:not(.e-xlsel-bottom-border),.e-grid.e-verticallines .e-rowcell.e-lastrowcell:not(.e-xlsel-bottom-border),.e-grid.e-hidelines .e-rowcell.e-lastrowcell:not(.e-xlsel-bottom-border){border-bottom-width:1px}.e-grid.e-horizontallines .e-detailrowvisible,.e-grid.e-verticallines .e-detailrowvisible,.e-grid.e-hidelines .e-detailrowvisible,.e-grid.e-bothlines .e-detailrowvisible{border-left-width:0}.e-grid.e-verticallines .e-firstchildrow .e-rowcell,.e-grid.e-verticallines .e-firstchildrow .e-detailrowcollapse,.e-grid.e-verticallines .e-firstchildrow .e-detailrowexpand,.e-grid.e-hidelines .e-firstchildrow .e-rowcell,.e-grid.e-hidelines .e-firstchildrow .e-detailrowcollapse,.e-grid.e-hidelines .e-firstchildrow .e-detailrowexpand{border-top-width:1px}.e-grid .e-filterbarcell .e-icons:before{display:block;margin:0 auto}.e-grid .e-filterbarcell,.e-grid .e-filterbarcelldisabled{border-collapse:collapse;border-style:solid;border-width:1px 0 0;cursor:default;height:42px;overflow:hidden;padding:0 21px;vertical-align:middle}.e-grid .e-rowdragheader{border-color:#e0e0e0;border-style:1px;border-width:1px 0 0}.e-grid .e-filterbarcell input{border-radius:0;border-style:solid;border-width:0 0 2px 0;font-size:13px;font-weight:400;height:26px;padding-right:24px;text-indent:0;width:100%}.e-grid.e-device .e-filterbarcell{padding:8px 12px}.e-grid.e-device .e-filterbarcell:first-child{padding:8px 12px 8px 16px}.e-grid.e-device .e-filterbarcell:last-child{padding:8px 16px 8px 12px}.e-grid .e-searchclear,.e-grid.e-rtl .e-searchclear,.e-grid .e-grid-relative{position:relative}.e-grid .e-searchclear{float:right}.e-grid.e-rtl .e-searchclear{float:left}.e-grid .e-checkselect,.e-grid .e-checkselectall{margin:0;opacity:0;position:absolute;width:0}.e-grid .e-rowcell .e-checkbox-wrapper,.e-grid .e-rowcell .e-css.e-checkbox-wrapper{-webkit-user-select:auto;height:20px;line-height:20px;position:relative;top:0;user-select:auto}.e-grid .e-filterdiv,.e-grid .e-fltrtempdiv{padding:0;position:relative;text-align:center;width:100%}.e-grid .e-pager{border-bottom:transparent;border-left:transparent;border-right:transparent}.e-grid .e-gridpopup{font-weight:400;position:absolute;-webkit-user-select:none;user-select:none;z-index:99999}.e-grid .e-gridpopup .e-content{border-radius:4px;border-style:solid;border-width:1px;font-size:14px;padding:4px}.e-grid .e-gridpopup span{border:1px solid transparent;cursor:pointer;display:inline-block;height:26px;padding:4px;width:26px}.e-grid .e-gridpopup .e-tail:before,.e-grid .e-gridpopup .e-tail:after{border:10px solid transparent;content:"";height:0;left:8px;position:absolute;width:0}.e-grid .e-gridpopup .e-downtail:after{top:34px}.e-grid .e-gridpopup .e-uptail:after{top:-17px}.e-grid .e-gridpopup .e-uptail:before{top:-19px}.e-grid .e-gridpopup .e-sortdirect,.e-grid .e-gridpopup .e-rowselect{line-height:18px;text-indent:7%}.e-grid .e-footerpadding{padding-left:0;padding-right:14px}.e-grid .e-footerpadding .e-lastsummarycell{border-left:none;border-right:1px solid}.e-grid.e-rtl .e-footerpadding{padding-left:14px;padding-right:0}.e-grid.e-rtl .e-footerpadding tr.e-summaryrow td.e-lastsummarycell:last-child{border-right:none;border-left:1px solid #e0e0e0}.e-grid .e-cloneproperties{border-style:solid;border-width:1px;font-size:12px;font-weight:500;box-shadow:0 0;opacity:1;overflow:hidden;padding:4px 5px;text-align:center;-webkit-user-select:none;user-select:none;vertical-align:middle;white-space:nowrap;z-index:10}.e-grid .e-cloneproperties .e-draganddrop{border-spacing:0;font-size:12px;font-weight:400;overflow:visible}.e-grid .e-cloneproperties.e-headerclone table,.e-grid .e-cloneproperties.e-draganddrop table{border-spacing:0}.e-grid .e-notallowedcur{cursor:not-allowed}.e-grid .e-grabcur{cursor:grabbing}.e-grid .e-headerclone{border-radius:12px;font-weight:500;line-height:29px}.e-grid .e-draganddrop{border-width:0 1px 1px;font-weight:400;padding:0}.e-grid .e-draganddrop .e-rowcell{opacity:.95}.e-grid.e-default .e-gridheader th.e-firstcell,.e-grid.e-default .e-gridheader th.e-laststackcell:not(:has(.e-rhandler.e-rcursor)){border-left-style:solid;border-left-width:1px}.e-grid.e-default.e-verticallines .e-gridheader th.e-firstcell.e-grid-group-first-cell{border-left-width:0}.e-grid:not(.sf-grid).e-bothlines .e-gridheader th.e-stackedheadercell{border-bottom-style:solid;border-bottom-width:1px;border-left-style:solid;border-left-width:1px}.e-grid.e-default.e-hidelines .e-gridheader th.e-firstcell{border-left-width:0}.e-grid td.e-active{font-weight:400}.e-grid:not(.e-row-responsive) .e-gridcontent tr.e-row:first-child td.e-cellselectionbackground:not(.e-gridchkbox-cell),.e-grid td.e-cellselectionbackground{font-weight:400}.e-grid .e-groupdroparea{height:auto;line-height:normal;min-height:48px}.e-grid .e-griddragarea{border:1px solid;opacity:.6;position:absolute}.e-grid .e-gdclone{border-radius:13px;padding:2px}.e-grid .e-content{-webkit-overflow-scrolling:touch;overflow-x:auto;overflow-y:scroll;position:relative}.e-grid.e-ungroupdrag .e-columnheader,.e-grid.e-ungroupdrag .e-groupdroparea{cursor:not-allowed}.e-grid.e-ungroupdrag .e-gridcontent{cursor:default}.e-grid.e-rowdrag .e-columnheader,.e-grid.e-rowdrag .e-groupdroparea{cursor:not-allowed}.e-grid.e-rowdrag .e-gridcontent{cursor:default}.e-grid .e-groupdroparea{cursor:default;border-style:solid none;border-width:1px 0 0;font-size:14px;font-weight:lighter;border-top-width:1px;opacity:.87;padding:14px 24px;text-align:left;text-indent:1pt;-webkit-user-select:none;user-select:none;width:100%}.e-grid .e-grouptext{display:inline-block;margin-right:6px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;width:auto}.e-grid .e-grid-icon{float:left}.e-grid .e-groupheadercell,.e-grid .e-groupheadercell:hover{border:0;border-collapse:collapse;border-radius:12px;cursor:pointer;font-size:13px;font-weight:400;height:24px;margin:3px 0 0 18px;overflow:hidden;padding:0 6px 0 9px;vertical-align:middle}.e-grid .e-groupheadercell:hover{border:0;padding:0 6px 0 9px}.e-grid .e-groupheadercell span{display:inline-block;float:left;height:24px;line-height:26px;padding:0;vertical-align:middle}.e-grid .e-groupheadercell .e-grouptext{line-height:24px}.e-grid .e-groupheadercell .e-ungroupbutton{font-size:13px;line-height:26px}.e-grid .e-groupheadercell .e-cancel{padding-right:10px}.e-grid .e-groupheadercell .e-icons:before{display:inline}.e-grid.e-device .e-groupheadercell span{line-height:26px}.e-grid.e-device .e-groupheadercell .e-ungroupbutton{line-height:25px}.e-grid.e-device .e-groupheadercell .e-groupsort{margin-top:0}.e-grid .e-groupsort,.e-grid .e-ungroupbutton,.e-grid .e-toggleungroup{font-size:10px;margin-left:6px}.e-grid .e-groupsort{margin-right:0;margin-top:0}.e-grid span.e-ungroupbutton.e-icons{margin-left:6px;margin-top:0;padding-top:0;padding-right:0}.e-grid .e-grptogglebtn{padding:7px}.e-grid .e-icon-gdownarrow{font-size:11px;padding:14px 9px 12px;text-decoration:none}.e-grid .e-icon-grightarrow{font-size:10px;padding:14px 9px 14px 10px;text-decoration:none}.e-grid .e-recordplusexpand{padding-top:5px}.e-grid .e-indentcell{border-style:solid;border-width:0 1px 0 0}.e-grid .e-indentcell.e-indentcelltop,.e-grid .e-indentcell.e-detailindentcelltop{border-width:1px 0 0}.e-grid .e-recordplusexpand,.e-grid .e-recordpluscollapse{border-style:solid;border-width:1px 0 0;cursor:pointer}.e-grid .e-groupcaption{border-style:solid;border-width:1px 0 0;display:table-cell;font-size:12px;line-height:20px;padding:.7em;overflow:hidden;text-overflow:ellipsis;vertical-align:middle;white-space:nowrap;width:auto}.e-grid .e-virtualtable .e-groupcaption{line-height:20px;padding:8px 21px}.e-grid .e-autofill{border:1px solid;height:8px;position:absolute;-webkit-user-select:none;user-select:none;width:8px}.e-grid .e-headercontent{border-style:solid;border-width:0}.e-grid .e-stackedheadercell{border-width:0 0 1px 1px;white-space:nowrap}.e-grid .e-toolbar .e-tbar-btn.e-btn .e-btn-icon.e-icons.e-columnchooser-btn{font-size:9px}.e-grid .e-toolbar .e-toolbar-items .e-toolbar-right .e-cc-toolbar .e-tbar-btn .e-columnchooser-btn{margin-top:1px}.e-grid .e-toolbar-item.e-cc.e-ccdiv.e-cc-toolbar{margin-top:0;padding:3px 0 0}.e-grid .e-edit-dialog{min-height:350px}.e-grid .e-edit-dialog .e-dlg-content{position:relative}.e-grid .e-griderror label{display:inline!important}.e-grid .e-tooltip-wrap.e-griderror{z-index:1000}.e-grid .e-tooltip-wrap.e-griderror .e-arrow-tip.e-tip-top{left:44%;top:-8px}.e-grid .e-normaledit{border-top:0;padding:0}.e-grid .e-normaledit .e-rowcell{padding-bottom:0;padding-top:0}.e-grid.e-device .e-normaledit .e-rowcell{padding-bottom:4px;padding-top:4px}.e-grid .e-gridcontent .e-normaledit .e-rowcell.e-lastrowadded{border-bottom:1px solid #e0e0e0;border-top:0 none #e0e0e0}.e-grid .e-gridcontent table tbody .e-normaledit .e-rowcell{border-top:1px solid}.e-grid:not(.e-row-responsive,.e-left-shadow,.e-right-shadow) .e-gridcontent tr.e-row:first-child .e-rowcell:not(.e-xlsel-top-border){border-top:0}.e-grid.e-device .e-editedbatchcell.e-rowcell,.e-grid .e-editedbatchcell.e-rowcell,.e-grid.e-device .e-gridcontent .e-normaledit .e-rowcell{padding-bottom:0;padding-top:0}.e-grid .e-editedbatchcell,.e-grid td.e-boolcell{padding-left:21px;padding-right:21px}.e-grid td.e-boolcell input{margin:3px 3px 3px 4px}.e-grid td.e-boolcell.e-rowcell{padding-bottom:5px;padding-top:5px}.e-grid .e-dialog .e-gridform .e-rowcell{border:0;padding:0}.e-grid .e-row .e-input-group .e-input.e-field,.e-grid .e-row .e-input-focus .e-input.e-field{font-family:Roboto,Segoe UI,GeezaPro,"DejaVu Serif","sans-serif",-apple-system,BlinkMacSystemFont;font-size:13px;padding-bottom:6px;padding-top:9px}.e-grid .e-row .e-input-group{margin-bottom:2px;margin-top:0;vertical-align:middle}.e-grid .e-defaultcell.e-ralign,.e-grid .e-editedrow .e-defaultcell.e-ralign,.e-grid .e-defaultcell.e-ralign:focus,.e-grid .e-editedrow .e-defaultcell.e-ralign:focus{padding-right:10px}.e-grid .e-dlg-content .e-defaultcell.e-ralign,.e-grid .e-dlg-content .e-defaultcell.e-ralign:focus{padding-right:0}.e-grid .e-columnchooserdiv{float:right;margin:-12px}.e-grid .e-rowcell .e-frozen-default-cursor,.e-grid .e-gridheader .e-headercell .e-frozen-default-cursor,.e-grid .e-gridheader .e-filterbarcell .e-frozen-default-cursor{border-left:2px solid;border-right:0}.e-grid .e-tooltip-wrap.e-griderror.e-unfreeze{z-index:1}.e-grid.e-lib .e-leftfreeze,.e-grid.e-lib.e-grid .e-headercell.e-leftfreeze,.e-grid.e-lib.e-grid .e-headercell.e-rightfreeze,.e-grid.e-lib .e-rightfreeze,.e-grid .e-leftfreeze,.e-grid .e-rightfreeze{position:sticky;z-index:2}.e-grid.e-lib .e-fixedfreeze,.e-grid.e-lib.e-grid .e-headercell.e-fixedfreeze,.e-grid .e-fixedfreeze{position:sticky;z-index:3}.e-grid .e-xlsel-top-border,.e-grid.e-rtl.e-default .e-rowcell.e-xlsel-top-border{border-top-width:2px;line-height:18px}.e-grid .e-xlsel-left-border,.e-grid .e-fixedfreeze.e-freezeleftborder.e-xlsel-left-border,.e-grid.e-rtl.e-default .e-rowcell.e-xlsel-left-border,.e-grid.e-rtl.e-default .e-rowcell.e-fixedfreeze.e-freezeleftborder.e-xlsel-left-border{border-left-width:2px}.e-grid .e-xlsel-right-border,.e-grid .e-fixedfreeze.e-freezerightborder.e-xlsel-right-border,.e-grid.e-rtl.e-default .e-rowcell.e-xlsel-right-border,.e-grid.e-rtl.e-default .e-rowcell.e-fixedfreeze.e-freezerightborder.e-xlsel-right-border{border-right-width:2px}.e-grid.e-wrap .e-xlsel-bottom-border.e-xlsel-top-border,.e-grid.e-rtl.e-wrap .e-xlsel-bottom-border.e-xlsel-top-border{line-height:16px}.e-grid.e-wrap .e-xlsel-bottom-border,.e-grid.e-rtl.e-wrap .e-xlsel-bottom-border{line-height:14px}.e-grid .e-xlsel-bottom-border.e-xlsel-top-border,.e-grid.e-rtl.e-default .e-rowcell.e-xlsel-bottom-border.e-xlsel-top-border{line-height:16px}.e-grid .e-xlsel-bottom-border,.e-grid.e-rtl.e-default .e-rowcell.e-xlsel-bottom-border{border-bottom-width:2px;line-height:18px}.e-grid .e-virtual-content.e-content{overflow-x:hidden}.e-grid.e-lib.e-default .e-headercell.e-leftfreeze.e-freezeleftborder,.e-grid.e-lib .e-leftfreeze.e-freezeleftborder,.e-grid .e-leftfreeze.e-freezeleftborder{border-right-width:2px}.e-grid.e-rtl.e-right-shadow .e-rightfreeze.e-freezerightborder:not(.e-dragborder),.e-grid.e-left-shadow .e-leftfreeze.e-freezeleftborder:not(.e-dragborder){clip-path:inset(0 -15px 0 0);box-shadow:4px 0 8px #0000001f}.e-grid.e-rtl.e-right-shadow .e-rightfreeze.e-freezerightborder:not(.e-xlsel-right-border),.e-grid.e-left-shadow .e-leftfreeze.e-freezeleftborder:not(.e-xlsel-right-border){border-right-color:transparent}.e-grid.e-rtl.e-right-shadow .e-rightfreeze.e-freezerightborder.e-dragborder,.e-grid.e-left-shadow .e-leftfreeze.e-freezeleftborder.e-dragborder{box-shadow:0 2px #e3165b,4px 0 8px #0000001f}.e-grid.e-right-shadow .e-rightfreeze.e-freezerightborder:not(.e-dragborder),.e-grid.e-rtl.e-left-shadow .e-leftfreeze.e-freezeleftborder:not(.e-dragborder){clip-path:inset(0 0 0 -15px);box-shadow:-4px 0 8px #0000001f}.e-grid.e-right-shadow:not(.e-rtl) .e-rightfreeze.e-freezerightborder:not(.e-xlsel-left-border),.e-grid.e-rtl.e-left-shadow .e-leftfreeze.e-freezeleftborder:not(.e-xlsel-left-border){border-left-color:transparent}.e-grid.e-right-shadow .e-rightfreeze.e-freezerightborder.e-dragborder,.e-grid.e-rtl.e-left-shadow .e-leftfreeze.e-freezeleftborder.e-dragborder{box-shadow:0 2px #e3165b,-4px 0 8px #0000001f}.e-grid.e-lib.e-default .e-headercell.e-rightfreeze.e-freezerightborder,.e-grid.e-lib .e-rightfreeze.e-freezerightborder,.e-grid .e-rightfreeze.e-freezerightborder{border-left-width:2px}.e-grid.e-lib.e-default:not(.e-rtl) .e-headercell.e-fixedfreeze.e-freezeleftborder:not(.e-removefreezeleftborder),.e-grid.e-lib:not(.e-rtl) .e-fixedfreeze.e-freezeleftborder:not(.e-removefreezeleftborder),.e-grid:not(.e-rtl) .e-fixedfreeze.e-freezeleftborder:not(.e-removefreezeleftborder){border-left-width:1px}.e-grid.e-lib.e-default:not(.e-rtl) .e-headercell.e-fixedfreeze.e-freezerightborder:not(.e-removefreezerightborder),.e-grid.e-lib:not(.e-rtl) .e-fixedfreeze.e-freezerightborder:not(.e-removefreezerightborder),.e-grid:not(.e-rtl) .e-fixedfreeze.e-freezerightborder:not(.e-removefreezerightborder){border-right-width:1px}.e-grid .e-content.e-mac-safari::-webkit-scrollbar{width:7px}.e-grid .e-content.e-mac-safari::-webkit-scrollbar-thumb{background-color:#00000080;border-radius:4px}.e-grid .e-movablescrollbar{flex:1;overflow:hidden;overflow-x:scroll}.e-grid .e-columnchooser:before{line-height:1.9}.e-grid .e-toolbar .e-ccdiv{margin-top:-1px;padding:0 10px}.e-grid .e-toolbar .e-ccdiv .e-columnchooser.e-cctbn-icon{font-size:15px;vertical-align:middle}.e-grid.e-rtl .e-tableborder{border-left:1px solid;border-right:0}.e-grid.e-rtl.e-lib.e-default .e-headercell.e-leftfreeze.e-freezeleftborder,.e-grid.e-rtl.e-lib .e-leftfreeze.e-freezeleftborder,.e-grid.e-rtl .e-leftfreeze.e-freezeleftborder{border-left-width:2px}.e-grid.e-rtl.e-lib.e-default .e-headercell.e-rightfreeze.e-freezerightborder,.e-grid.e-rtl.e-lib .e-rightfreeze.e-freezerightborder,.e-grid.e-rtl .e-rightfreeze.e-freezerightborder{border-right-width:2px}.e-grid.e-rtl.e-lib.e-default .e-headercell.e-fixedfreeze.e-freezeleftborder:not(.e-removefreezerightborder),.e-grid.e-rtl.e-lib .e-fixedfreeze.e-freezeleftborder:not(.e-removefreezerightborder),.e-grid.e-rtl .e-fixedfreeze.e-freezeleftborder:not(.e-removefreezerightborder){border-right-width:1px}.e-grid.e-rtl.e-lib.e-default .e-headercell.e-fixedfreeze.e-freezerightborder:not(.e-removefreezeleftborder),.e-grid.e-rtl.e-lib .e-fixedfreeze.e-freezerightborder:not(.e-removefreezeleftborder),.e-grid.e-rtl .e-fixedfreeze.e-freezerightborder:not(.e-removefreezeleftborder){border-left-width:1px}.e-grid.e-rtl .e-headercell,.e-grid.e-rtl .e-detailheadercell{border-width:0;text-align:right}.e-grid.e-rtl .e-headercell.e-fltr-icon .e-headercelldiv,.e-grid.e-rtl .e-headercell.e-fltr-icon .e-headercelldiv.e-headerchkcelldiv,.e-grid.e-rtl .e-detailheadercell.e-fltr-icon .e-headercelldiv,.e-grid.e-rtl .e-detailheadercell.e-fltr-icon .e-headercelldiv.e-headerchkcelldiv{padding:0 .6em 0 1.8em;text-align:right}.e-grid.e-rtl .e-headercell.e-fltr-icon .e-headercelldiv .e-sortnumber,.e-grid.e-rtl .e-headercell.e-fltr-icon .e-headercelldiv.e-headerchkcelldiv .e-sortnumber,.e-grid.e-rtl .e-detailheadercell.e-fltr-icon .e-headercelldiv .e-sortnumber,.e-grid.e-rtl .e-detailheadercell.e-fltr-icon .e-headercelldiv.e-headerchkcelldiv .e-sortnumber{float:left;margin:7px 0 0 5px}.e-grid.e-rtl .e-headercell .e-headercelldiv,.e-grid.e-rtl .e-headercell .e-headercelldiv.e-headerchkcelldiv,.e-grid.e-rtl .e-detailheadercell .e-headercelldiv,.e-grid.e-rtl .e-detailheadercell .e-headercelldiv.e-headerchkcelldiv{padding:0 .6em 0 1.8em;text-align:right}.e-grid.e-rtl .e-headercell .e-headercelldiv .e-sortnumber,.e-grid.e-rtl .e-headercell .e-headercelldiv.e-headerchkcelldiv .e-sortnumber,.e-grid.e-rtl .e-detailheadercell .e-headercelldiv .e-sortnumber,.e-grid.e-rtl .e-detailheadercell .e-headercelldiv.e-headerchkcelldiv .e-sortnumber{float:left;margin:7px 0 0 5px}.e-grid.e-rtl .e-headercell .e-filterbarcell input,.e-grid.e-rtl .e-detailheadercell .e-filterbarcell input{border-width:0 0 2px 0}.e-grid.e-rtl .e-headercell .e-sortfilterdiv,.e-grid.e-rtl .e-detailheadercell .e-sortfilterdiv{float:left;margin:-16px 10px}.e-grid.e-rtl .e-headercell.e-leftalign.e-headercell.e-fltr-icon .e-headercelldiv,.e-grid.e-rtl .e-detailheadercell.e-leftalign.e-headercell.e-fltr-icon .e-headercelldiv{margin-left:10px}.e-grid.e-rtl .e-headercell.e-leftalign.e-headercell.e-fltr-icon .e-headercelldiv .e-sortnumber,.e-grid.e-rtl .e-detailheadercell.e-leftalign.e-headercell.e-fltr-icon .e-headercelldiv .e-sortnumber{margin:6px -4px 0 0}.e-grid.e-rtl .e-headercell.e-leftalign.e-headercell.e-fltr-icon .e-filtermenudiv,.e-grid.e-rtl .e-detailheadercell.e-leftalign.e-headercell.e-fltr-icon .e-filtermenudiv{margin-left:-5px}.e-grid.e-rtl .e-headercell.e-leftalign .e-sortfilterdiv,.e-grid.e-rtl .e-detailheadercell.e-leftalign .e-sortfilterdiv{float:right;margin:-16px 3px}.e-grid.e-rtl .e-headercell.e-leftalign .e-headercelldiv,.e-grid.e-rtl .e-detailheadercell.e-leftalign .e-headercelldiv{padding:0 25px 0 .7em}.e-grid.e-rtl .e-headercell.e-leftalign .e-headercelldiv .e-sortnumber,.e-grid.e-rtl .e-detailheadercell.e-leftalign .e-headercelldiv .e-sortnumber{float:right;margin:6px 2px 0 0}.e-grid.e-rtl .e-headercell.e-fltr-icon.e-rightalign .e-sortnumber,.e-grid.e-rtl .e-detailheadercell.e-fltr-icon.e-rightalign .e-sortnumber,.e-grid.e-rtl .e-headercell.e-rightalign .e-sortnumber,.e-grid.e-rtl .e-detailheadercell.e-rightalign .e-sortnumber{float:left;margin:7px 0 0 5px}.e-grid.e-rtl .e-rowcell:first-child,.e-grid.e-rtl .e-summarycell:first-child{padding-right:21px}.e-grid.e-rtl .e-rowcell:last-child,.e-grid.e-rtl .e-summarycell:last-child{padding-left:21px}.e-grid.e-rtl.e-wrap .e-columnheader .e-rightalign .e-sortnumber,.e-grid.e-rtl.e-wrap .e-columnheader .e-sortnumber{margin:3px 5px 0 2px}.e-grid.e-rtl.e-wrap .e-columnheader .e-fltr-icon .e-sortfilterdiv{margin:-17px 4px}.e-grid.e-rtl.e-wrap .e-columnheader .e-fltr-icon.e-rightalign .e-sortfilterdiv{margin:-17px 5px}.e-grid.e-rtl .e-gridheader .e-fltr-icon .e-sortfilterdiv,.e-grid.e-rtl .e-gridheader .e-rightalign.e-fltr-icon .e-sortfilterdiv{margin:-16px 0 0 11px}.e-grid.e-rtl .e-gridheader .e-sortfilter .e-rightalign.e-fltr-icon .e-headercelldiv,.e-grid.e-rtl .e-gridheader .e-sortfilter .e-fltr-icon .e-headercelldiv{margin:-7px}.e-grid.e-rtl .e-gridheader .e-rightalign .e-sortfilterdiv{margin:-16px 10px}.e-grid.e-rtl.e-wrap .e-columnheader .e-rightalign.e-fltr-icon .e-headercelldiv,.e-grid.e-rtl .e-columnheader.e-wrap .e-rightalign.e-fltr-icon .e-headercelldiv{height:auto;margin-bottom:2px;margin-top:0}.e-grid.e-rtl.e-verticallines .e-grouptopleftcell,.e-grid.e-rtl.e-bothlines .e-grouptopleftcell,.e-grid.e-rtl.e-hidelines .e-grouptopleftcell{border-top:0}.e-grid.e-rtl .e-grouptopleftcell{border-top:1px solid}.e-grid.e-rtl .e-grouptopleftcell span.e-grouptext{margin-left:3px;margin-right:0}.e-grid.e-rtl .e-grouptopleftcell span{float:right;margin:0}.e-grid.e-rtl .e-groupheadercell span{float:right;padding:0}.e-grid.e-rtl.e-horizontallines .e-grouptopleftcell{border-top:1px solid}.e-grid.e-rtl .e-rowcell{border-width:1px 0 0 0}.e-grid.e-rtl .e-stackedheadercell.e-leftfreeze.e-freezeleftborder,.e-grid.e-rtl .e-rowcell.e-leftfreeze.e-freezeleftborder{border-left-width:2px}.e-grid.e-rtl .e-stackedheadercell.e-rightfreeze.e-freezerightborder,.e-grid.e-rtl .e-rowcell.e-rightfreeze.e-freezerightborder{border-right-width:2px}.e-grid.e-rtl .e-stackedheadercell.e-fixedfreeze.e-freezeleftborder,.e-grid.e-rtl .e-rowcell.e-fixedfreeze.e-freezeleftborder:not(.e-xlsel-right-border,.e-removefreezerightborder){border-right-width:1px}.e-grid.e-rtl .e-stackedheadercell.e-fixedfreeze.e-freezerightborder,.e-grid.e-rtl .e-rowcell.e-fixedfreeze.e-freezerightborder:not(.e-xlsel-left-border,.e-removefreezeleftborder){border-left-width:1px}.e-grid.e-rtl .e-summarycell.e-rightfreeze.e-freezerightborder,.e-grid.e-rtl .e-summarycell.e-fixedfreeze.e-freezeleftborder{border-left-width:0}.e-grid.e-rtl .e-summarycell.e-leftfreeze.e-freezeleftborder,.e-grid.e-rtl .e-summarycell.e-fixedfreeze.e-freezerightborder{border-right-width:0}.e-grid.e-rtl .e-filterbarcell,.e-grid.e-rtl .e-filterbarcelldisabled{border-width:1px 0 0}.e-grid.e-rtl .e-lastrowcell{border-width:1px 1px 1px 0}.e-grid.e-rtl .e-cloneproperties{border-width:1px 1px 2px}.e-grid.e-rtl tr td:first-child,.e-grid.e-rtl tr th:first-child{border-left-width:0}.e-grid.e-rtl.e-default.e-bothlines tr td:first-child:not(.e-summarycell,.e-freezeleftborder),.e-grid.e-rtl.e-default.e-bothlines tr th:first-child{border-left-width:1px}.e-grid.e-rtl.e-default.e-bothlines tr td:first-child.e-detailrowcollapse,.e-grid.e-rtl.e-default.e-bothlines tr td:first-child.e-detailrowexpand{border-left-width:0}.e-grid.e-rtl.e-default tr td:last-child:not(.e-xlsel-left-border,.e-rowcell-lastchild,.e-addfreezefirstchildborder),.e-grid.e-rtl.e-default .e-gridheader table tr th:last-child:not(.e-firstcell){border-left:0}.e-grid.e-rtl.e-default.e-verticallines tr th:last-child{border-left:1px solid}.e-grid.e-rtl.e-default .e-gridheader tr th:last-child,.e-grid.e-rtl.e-default .e-gridheader tr th:first-child{padding-left:21px;padding-right:21px}.e-grid.e-rtl.e-default th:first-child .e-grid.e-rtl.e-default .e-headercell,.e-grid.e-rtl.e-default .e-detailheadercell{border-width:0}.e-grid.e-rtl.e-default .e-rowcell{border-width:1px 0 0 0}.e-grid.e-rtl.e-default.e-verticallines .e-headercell,.e-grid.e-rtl.e-default.e-verticallines .e-rowcell,.e-grid.e-rtl.e-default.e-verticallines .e-filterbarcell,.e-grid.e-rtl.e-default.e-verticallines .e-detailheadercell,.e-grid.e-rtl.e-default.e-verticallines .e-gridheader th.e-firstcell{border-width:0 0 0 1px}.e-grid.e-rtl.e-default.e-verticallines tr th:first-child:not(.e-firstcell){border-left-width:1px}.e-grid.e-rtl.e-default.e-verticallines .e-gridheader .e-headercell.e-firstheader{border-right:0}.e-grid.e-rtl.e-default.e-verticallines .e-gridheader .e-headercell.e-firstheader,.e-grid.e-rtl.e-default.e-verticallines .e-gridheader th.e-grouptopleftcell.e-lastgrouptopleftcell{border-left:1px solid}.e-grid.e-rtl.e-default.e-verticallines .e-headercell.e-stackedheadercell{border-bottom:1px solid}.e-grid.e-rtl.e-default .e-stackedheadercell,.e-grid.e-rtl.e-default.e-horizontallines .e-stackedheadercell{border-width:0 1px 1px 0}.e-grid.e-rtl.e-default .e-gridheader th.e-firstcell,.e-grid.e-rtl.e-default.e-horizontallines .e-gridheader th.e-firstcell{border-left-width:0;border-right-width:1px}.e-grid.e-rtl.e-default.e-bothlines .e-gridheader th.e-firstcell{border-left-width:1px;border-right-width:0}.e-grid.e-rtl.e-default .e-gridheader .e-headercell.e-firstheader,.e-grid.e-rtl.e-default.e-horizontallines .e-headercell.e-firstheader{border-left:0}.e-grid.e-rtl.e-default.e-hidelines .e-gridheader th.e-firstcell{border-left:0;border-right:0}.e-grid.e-rtl.e-default .e-gridheader .e-headercell.e-firstheader,.e-grid.e-rtl.e-default.e-horizontallines .e-gridheader .e-headercell.e-firstheader{border-right:1px solid}.e-grid.e-rtl.e-default .e-detailcell,.e-grid.e-rtl.e-default.e-bothlines .e-detailcell{border-right-style:solid;border-right-width:1px;text-align:right}.e-grid.e-rtl .e-groupsort,.e-grid.e-rtl .e-ungroupbutton,.e-grid.e-rtl .e-toggleungroup{margin-left:0;margin-right:6px}.e-grid.e-rtl span.e-ungroupbutton.e-icons{margin-left:0;margin-right:6px;padding-top:0}.e-grid.e-rtl:not(.sf-grid).e-default.e-bothlines .e-headercell,.e-grid.e-rtl:not(.sf-grid).e-default.e-bothlines .e-detailheadercell{border-width:0 0 0 1px}.e-grid.e-rtl.e-default.e-bothlines .e-dragheadercell,.e-grid.e-rtl.e-default.e-bothlines .e-rowdragheader,.e-grid.e-rtl.e-default.e-bothlines .e-cloneproperties.e-draganddrop td.e-rowdragdrop{border-left:1px solid #e0e0e0;padding-left:3px}.e-grid.e-rtl.e-default.e-bothlines .e-gridheader .e-headercell.e-firstheader,.e-grid.e-rtl.e-default.e-bothlines .e-gridheader th.e-grouptopleftcell.e-lastgrouptopleftcell{border-left:1px solid;border-right:0}.e-grid.e-rtl .e-cloneproperties.e-draganddrop .e-row .e-icon-rowdragicon:before{left:4px;position:relative}.e-grid.e-rtl:not(.sf-grid).e-bothlines .e-gridheader th.e-stackedheadercell{border-bottom-style:solid;border-bottom-width:1px}.e-grid.e-rtl.e-bothlines .e-filterbarcell,.e-grid.e-rtl.e-bothlines .e-filterbarcelldisabled{border-width:1px 0 0 1px;border-top-width:1px}.e-grid.e-rtl.e-bothlines .e-rowcell,.e-grid.e-rtl.e-bothlines .e-rowcell.e-lastrowcell,.e-grid.e-rtl.e-verticallines .e-rowcell,.e-grid.e-rtl.e-verticallines .e-filterbarcell{border-width:1px 0 0 1px}.e-grid.e-rtl.e-hidelines .e-rowcell,.e-grid.e-rtl.e-hidelines .e-headercell,.e-grid.e-rtl.e-hidelines .e-detailheadercell,.e-grid.e-rtl.e-hidelines .e-filterbarcell{border-width:0}.e-grid.e-rtl.e-horizontallines .e-rowcell,.e-grid.e-rtl.e-horizontallines .e-filterbarcell{border-width:1px 0 0}.e-grid.e-rtl.e-horizontallines .e-rowcell.e-lastrowcell:not(.e-xlsel-bottom-border),.e-grid.e-rtl.e-verticallines .e-rowcell.e-lastrowcell:not(.e-xlsel-bottom-border),.e-grid.e-rtl.e-hidelines .e-rowcell.e-lastrowcell:not(.e-xlsel-bottom-border){border-bottom-width:1px}.e-grid.e-rtl.e-verticallines .e-firstchildrow .e-rowcell,.e-grid.e-rtl.e-hidelines .e-firstchildrow .e-rowcell{border-top-width:1px}.e-grid.e-rtl .e-groupheadercell .e-icons:before{display:inline-block}.e-grid.e-rtl .e-groupheadercell .e-cancel{padding-left:23px;padding-right:0;padding-top:2px}.e-grid.e-rtl .e-groupheadercell,.e-grid.e-rtl .e-groupheadercell:hover{float:right;margin-left:10px;margin-right:18px;padding:0 9px 0 6px}.e-grid.e-rtl .e-groupdroparea{text-align:right}.e-grid.e-rtl .e-ungroupbutton{float:left}.e-grid.e-rtl .e-gridcontent table tr:not(.e-summaryrow) td.e-indentcell{border-style:solid;border-width:0 0 0 1px}.e-grid.e-rtl .e-defaultcell.e-ralign,.e-grid.e-rtl .e-row .e-input.e-defaultcell.e-ralign,.e-grid.e-rtl .e-defaultcell.e-ralign:focus,.e-grid.e-rtl .e-editedrow .e-defaultcell.e-ralign:focus{padding-left:10px}.e-grid.e-rtl .e-detailindentcell{border-left-style:solid;border-left-width:1px;border-right-width:0}.e-grid.e-rtl .e-filtermenudiv{float:left;margin:-18px 0 -18px -11px;padding:6px}.e-grid:not(.sf-grid).e-rtl.e-default:not(.e-verticallines):not(.e-bothlines) table th[rowspan]{border-width:0 1px 0 0}.e-grid:not(.sf-grid).e-rtl.e-default table th[rowspan].e-leftfreeze.e-freezeleftborder{border-left-width:2px}.e-grid:not(.sf-grid).e-rtl.e-default table th[rowspan].e-rightfreeze.e-freezerightborder{border-right-width:2px}.e-grid:not(.sf-grid).e-rtl.e-default table th[rowspan].e-fixedfreeze.e-freezeleftborder{border-right-width:1px}.e-grid:not(.sf-grid).e-rtl.e-default table th[rowspan].e-fixedfreeze.e-freezerightborder{border-left-width:1px}.e-grid.e-wrap .e-rowcell,.e-grid.e-wrap .e-columnheader .e-stackedheadercelldiv,.e-grid.e-wrap .e-columnheader .e-headercelldiv,.e-grid.e-wrap .e-columnheader .e-headercell.e-fltr-icon .e-headercelldiv{height:Auto;line-height:18px;overflow-wrap:break-word;text-overflow:clip;white-space:normal;word-wrap:break-word}.e-grid.e-wrap .e-cloneproperties.e-draganddrop.e-grid .e-rowcell{white-space:nowrap}.e-grid.e-wrap .e-stackedheader .e-columnheader .e-stackedheadercelldiv,.e-grid.e-wrap .e-stackedheader .e-columnheader .e-headercelldiv{max-height:36px}.e-grid.e-wrap .e-checkbox-wrapper{vertical-align:middle}.e-grid.e-wrap .e-columnheader .e-headercelldiv,.e-grid.e-wrap .e-columnheader .e-headercell.e-fltr-icon .e-headercelldiv{margin-bottom:2px;margin-top:0}.e-grid.e-wrap .e-columnheader .e-filtermenudiv,.e-grid.e-wrap .e-columnheader .e-sortfilterdiv .e-filtermenudiv{line-height:14px;margin:-24px -5px -12px 8px}.e-grid.e-wrap .e-columnheader .e-sortfilterdiv{margin:-18px 10px}.e-grid.e-wrap .e-columnheader .e-rightalign .e-sortfilterdiv{margin:-18px 5px}.e-grid.e-wrap .e-columnheader .e-fltr-icon .e-sortfilterdiv{margin:-20px 18px}.e-grid.e-wrap .e-columnheader .e-fltr-icon.e-rightalign .e-sortfilterdiv{margin:-20px 14px}.e-grid.e-wrap .e-columnheader .e-icon-group:before{display:inline-block}.e-grid.e-wrap.e-rtl .e-columnheader .e-filtermenudiv,.e-grid.e-wrap.e-rtl .e-columnheader .e-sortfilterdiv .e-filtermenudiv{margin:-22px 0 -18px -15px}.e-grid .e-columnheader.e-wrap .e-headercelldiv,.e-grid .e-columnheader.e-wrap .e-headercell.e-fltr-icon .e-headercelldiv{margin-bottom:2px;margin-top:0}.e-grid .e-columnheader.e-wrap .e-filtermenudiv,.e-grid .e-columnheader.e-wrap .e-sortfilterdiv .e-filtermenudiv{line-height:14px}.e-grid .e-columnheader.e-wrap .e-headercelldiv,.e-grid .e-columnheader.e-wrap .e-headercell.e-fltr-icon .e-headercelldiv,.e-grid .e-columnheader.e-wrap .e-stackedheadercelldiv{height:Auto;line-height:18px;overflow-wrap:break-word;text-overflow:clip;white-space:normal;word-wrap:break-word}.e-grid .e-columnheader.e-wrap .e-sortfilterdiv{margin:-18px 10px}.e-grid .e-columnheader.e-wrap .e-rightalign .e-sortfilterdiv{margin:-18px 5px}.e-grid .e-columnheader.e-wrap .e-fltr-icon .e-sortfilterdiv{margin:-20px 18px}.e-grid .e-columnheader.e-wrap .e-fltr-icon.e-rightalign .e-sortfilterdiv{margin:-20px 14px}.e-grid .e-columnheader.e-wrap .e-icon-group:before{display:inline-block}.e-grid .e-gridcontent.e-wrap .e-rowcell{height:Auto;line-height:18px;overflow-wrap:break-word;text-overflow:clip;white-space:normal;word-wrap:break-word}.e-grid .e-stackedheadercelldiv{overflow:hidden;text-overflow:ellipsis}.e-grid.e-responsive .e-rowcell.e-gridclip,.e-grid.e-responsive .e-gridclip .e-headercelldiv,.e-grid.e-responsive .e-gridclip .e-stackedheadercelldiv{text-overflow:clip}.e-grid .e-clipboard{cursor:default;height:1px;left:-1000px;overflow:hidden;position:fixed;resize:none;top:-1000px;width:1px}.e-grid.e-resize-lines th.e-headercell.e-stackedheadercell:not(.e-freezerightborder,.e-freezeleftborder),.e-grid.e-resize-lines th.e-headercell.e-firstcell:not(.e-freezerightborder,.e-freezeleftborder),.e-grid.e-resize-lines.e-rtl th.e-headercell.e-stackedheadercell:not(.e-freezerightborder,.e-freezeleftborder),.e-grid.e-resize-lines.e-rtl th.e-headercell.e-firstcell:not(.e-freezerightborder,.e-freezeleftborder){border-left:0;border-right:0;border-top:0}.e-grid.e-resize-lines tr.e-columnheader th:last-child.e-stackedheadercell .e-rhandler.e-rcursor :not(.e-laststackcell,.e-freezerightborder,.e-freezeleftborder),.e-grid.e-resize-lines.e-rtl tr.e-columnheader th:last-child.e-stackedheadercell .e-rhandler.e-rcursor :not(.e-laststackcell,.e-freezerightborder,.e-freezeleftborder){border-right:0}.e-grid:not(.sf-grid).e-resize-lines.e-default table th[rowspan]:not(.e-freezerightborder,.e-freezeleftborder),.e-grid:not(.sf-grid).e-resize-lines.e-rtl.e-default table th[rowspan]:not(.e-freezerightborder,.e-freezeleftborder){border-left:0}.e-grid.e-resize-lines.e-rtl tr.e-columnheader th:last-child.e-stackedheadercell .e-rhandler.e-rcursor,.e-grid.e-resize-lines.e-rtl tr.e-columnheader th.e-lastcell .e-rhandler.e-rcursor,.e-grid.e-resize-lines.e-rtl tr.e-columnheader th.e-laststackcell .e-rhandler.e-rcursor{border-left:0}.e-grid.e-resize-lines tr.e-columnheader th:last-child.e-stackedheadercell .e-rhandler.e-rcursor,.e-grid.e-resize-lines tr.e-columnheader th.e-lastcell .e-rhandler.e-rcursor,.e-grid.e-resize-lines tr.e-columnheader th.e-laststackcell .e-rhandler.e-rcursor{border-right:0}.e-grid:not(.sf-grid).e-resize-lines.e-rtl.e-default table th[rowspan]{border-right:0}.e-grid.sf-grid span.e-ungroupbutton.e-icons{margin-left:6px}.e-grid.sf-grid .e-rowdragdrop{border-width:1px 0 0 0;border-color:#e0e0e0}.e-grid.sf-grid .e-rowcell.e-frozen-right-border,.e-grid.sf-grid .e-headercell.e-frozen-right-border,.e-grid.sf-grid .e-filterbarcell.e-frozen-right-border{border-right:2px solid rgba(227,22,91,.6)}.e-grid.sf-grid .e-rowcell.e-frozen-left-border,.e-grid.sf-grid .e-headercell.e-frozen-left-border,.e-grid.sf-grid .e-filterbarcell.e-frozen-left-border{border-left:2px solid rgba(227,22,91,.6)}.e-grid.sf-grid .e-rowcell.e-freezeline,.e-grid.sf-grid .e-gridheader .e-filterbarcell.e-freezeline{position:relative}.e-grid.sf-grid .e-rowcell .e-frozen-right-cursor,.e-grid.sf-grid .e-rowcell .e-frozen-fixedright-cursor,.e-grid.sf-grid .e-rowcell .e-frozen-left-cursor,.e-grid.sf-grid .e-rowcell .e-frozen-fixedleft-cursor{cursor:move;height:100%;position:absolute;top:0;width:4px}.e-grid.sf-grid .e-rowcell .e-frozen-left-cursor,.e-grid.sf-grid .e-rowcell .e-frozen-fixedright-cursor{right:0}.e-grid.sf-grid .e-rowcell .e-frozen-right-cursor,.e-grid.sf-grid .e-rowcell .e-frozen-fixedleft-cursor{left:0}.e-grid.sf-grid .e-rowcell .e-frozen-left-cursor.e-frozen-resize-cursor{right:3px}.e-grid.sf-grid .e-gridheader .e-headercell .e-frozen-right-cursor,.e-grid.sf-grid .e-gridheader .e-headercell .e-frozen-fixedright-cursor,.e-grid.sf-grid .e-gridheader .e-headercell .e-frozen-left-cursor,.e-grid.sf-grid .e-gridheader .e-headercell .e-frozen-fixedleft-cursor{cursor:move;height:100%;position:absolute;top:0;width:4px}.e-grid.sf-grid .e-gridheader .e-headercell .e-frozen-left-cursor,.e-grid.sf-grid .e-gridheader .e-headercell .e-frozen-fixedright-cursor{right:0}.e-grid.sf-grid .e-gridheader .e-headercell .e-frozen-right-cursor,.e-grid.sf-grid .e-gridheader .e-headercell .e-frozen-fixedleft-cursor{left:0}.e-grid.sf-grid .e-gridheader .e-headercell .e-frozen-left-cursor.e-frozen-resize-cursor{right:3px}.e-grid.sf-grid .e-gridheader .e-headercell .e-frozen-right-cursor.e-frozen-resize-cursor:not(.e-frozen-default-cursor){left:3px}.e-grid.sf-grid .e-gridheader .e-filterbarcell .e-frozen-right-cursor,.e-grid.sf-grid .e-gridheader .e-filterbarcell .e-frozen-fixedright-cursor,.e-grid.sf-grid .e-gridheader .e-filterbarcell .e-frozen-left-cursor,.e-grid.sf-grid .e-gridheader .e-filterbarcell .e-frozen-fixedleft-cursor{cursor:move;height:100%;position:absolute;top:0;width:4px}.e-grid.sf-grid .e-gridheader .e-filterbarcell .e-frozen-fixedright-cursor,.e-grid.sf-grid .e-gridheader .e-filterbarcell .e-frozen-left-cursor{right:0}.e-grid.sf-grid .e-gridheader .e-filterbarcell .e-frozen-right-cursor,.e-grid.sf-grid .e-gridheader .e-filterbarcell .e-frozen-fixedleft-cursor{left:0}.e-grid.sf-grid .e-gridheader .e-filterbarcell .e-frozen-left-cursor.e-frozen-resize-cursor{right:3px}.e-grid.sf-grid .e-gridheader .e-filterbarcell .e-frozen-right-cursor.e-frozen-resize-cursor:not(.e-frozen-default-cursor){left:3px}.e-grid.sf-grid .e-frozen-helper{border-left:2px solid rgba(227,22,91,.6);cursor:move;position:absolute;z-index:2}.e-grid.sf-grid .e-content.e-freezeline-moving{-webkit-user-select:none;user-select:none}.e-grid.sf-grid .e-gridheader .e-headercontent .e-reorderuparrow,.e-grid.sf-grid .e-gridheader .e-headercontent .e-reorderuparrow-virtual{margin-top:1px}.e-grid.sf-grid .e-gridheader .e-headercontent .e-reorderdownarrow,.e-grid.sf-grid .e-gridheader .e-headercontent .e-reorderdownarrow-virtual{margin-top:-1px}.e-grid.sf-grid .e-masked-cell.e-rowcell .e-virtualcell{background-color:#0000001a;display:inline-block;height:10px;width:80%}.e-grid.sf-grid .e-gridcontent .e-content{overflow-y:auto}.e-grid.sf-grid .e-gridcontent .e-content.e-yscroll{overflow-y:scroll}.e-grid.sf-grid .e-gridcontent .e-content.e-noscroll{overflow-y:hidden}.e-grid.sf-grid .e-gridcontent .e-content,.e-grid.sf-grid .e-detailrowcollapse.e-dragborder,.e-grid.sf-grid .e-detailrowexpand.e-dragborder{position:relative}.e-grid.sf-grid .e-label.e-fltrcheck,.e-grid.sf-grid .e-label.e-choosercheck{width:0}.e-grid.sf-grid .e-checkboxlist .e-fltrcheck,.e-grid.sf-grid .e-cc-contentdiv .e-choosercheck{white-space:nowrap}.e-grid.sf-grid .e-filterdiv .e-multiselect.e-input-group:not(.e-rtl),.e-grid.sf-grid .e-fltrtempdiv .e-multiselect.e-input-group:not(.e-rtl){text-align:left}.e-grid.sf-grid.e-default table th:not([rowspan="1"]):not(.e-detailcell,.e-detailindentcell,.e-stackedheadercell,.e-detailheadercell,.e-rowdragheader){border-width:0 0 0 1px}.e-grid.sf-grid .e-gridheader table th:not([rowspan="1"]),.e-grid.sf-grid .e-device .e-gridheader table th:not([rowspan="1"]){padding-bottom:13px;vertical-align:bottom}.e-grid.sf-grid.e-rtl.e-default table th:not([rowspan="1"]).e-rightfreeze.e-freezerightborder,.e-grid.sf-grid.e-default table th:not([rowspan="1"]).e-leftfreeze.e-freezeleftborder{border-right-width:2px}.e-grid.sf-grid.e-rtl.e-default table th:not([rowspan="1"]).e-leftfreeze.e-freezeleftborder,.e-grid.sf-grid.e-default table th:not([rowspan="1"]).e-rightfreeze.e-freezerightborder{border-left-width:2px}.e-grid.sf-grid.e-rtl.e-default table th:not([rowspan="1"]).e-fixedfreeze.e-freezerightborder,.e-grid.sf-grid.e-default table th:not([rowspan="1"]).e-fixedfreeze.e-freezeleftborder{border-left-width:1px}.e-grid.sf-grid.e-rtl.e-default table th:not([rowspan="1"]).e-fixedfreeze.e-freezeleftborder,.e-grid.sf-grid.e-default table th:not([rowspan="1"]).e-fixedfreeze.e-freezerightborder{border-right-width:1px}.e-grid.sf-grid.e-rtl.e-default table th:not([rowspan="1"]):not(.e-detailcell,.e-detailindentcell,.e-stackedheadercell,.e-detailheadercell,.e-rowdragheader){border-width:0 1px 0 0}.e-grid.sf-grid.e-resize-lines.e-default table th:not([rowspan="1"]):not(.e-freezerightborder,.e-freezeleftborder),.e-grid.sf-grid.e-resize-lines.e-rtl.e-default table th:not([rowspan="1"]):not(.e-freezerightborder,.e-freezeleftborder){border-left:0}.e-grid.sf-grid.e-resize-lines.e-rtl.e-default table th:not([rowspan="1"]){border-right:0}.e-grid.sf-grid.e-rtl.e-bothlines .e-gridheader th.e-stackedheadercell{border-bottom-style:solid;border-bottom-width:1px}.e-grid.sf-grid.e-rtl.e-default.e-bothlines .e-headercell,.e-grid.sf-grid.e-rtl.e-default.e-bothlines .e-detailheadercell{border-width:0 0 0 1px}.e-grid.sf-grid.e-resize-lines th.e-headercell.e-stackedheadercell:not(.e-freezerightborder,.e-freezeleftborder),.e-grid.sf-grid.e-resize-lines th.e-headercell.e-firstcell:not(.e-freezerightborder,.e-freezeleftborder),.e-grid.sf-grid.e-resize-lines.e-rtl th.e-headercell.e-stackedheadercell:not(.e-freezerightborder,.e-freezeleftborder),.e-grid.sf-grid.e-resize-lines.e-rtl th.e-headercell.e-firstcell:not(.e-freezerightborder,.e-freezeleftborder){border-left:0;border-right:0;border-top:0}.e-grid.sf-grid.e-default.e-bothlines .e-headercell,.e-grid.sf-grid.e-default.e-bothlines .e-detailheadercell{border-width:0 0 0 1px}.e-grid.sf-grid.e-default.e-bothlines .e-headercell.e-leftfreeze.e-freezeleftborder,.e-grid.sf-grid.e-default.e-verticallines .e-headercell.e-leftfreeze.e-freezeleftborder{border-right-width:2px}.e-grid.sf-grid.e-default.e-bothlines .e-headercell.e-rightfreeze.e-freezerightborder,.e-grid.sf-grid.e-default.e-verticallines .e-headercell.e-rightfreeze.e-freezerightborder{border-left-width:2px}.e-grid.sf-grid.e-bothlines .e-gridheader th.e-stackedheadercell{border-bottom-style:solid;border-bottom-width:1px;border-left-style:solid;border-left-width:1px}.e-grid-min-height .e-rowcell,.e-grid-min-height .e-icon-grightarrow,.e-grid-min-height .e-icon-gdownarrow{line-height:0;padding-bottom:0;padding-top:0}.e-grid-min-height .e-gridheader .e-headercell,.e-grid-min-height .e-gridheader .e-detailheadercell,.e-grid-min-height .e-gridheader .e-headercell:not(.e-fltr-icon,.e-sort-icon) .e-headercelldiv{height:auto}.e-grid-min-height .e-gridcontent .e-groupcaption{line-height:normal;padding:0 .7em}.e-grid-min-height .e-summarycell{line-height:normal;padding:0 8px}.e-grid-min-height .e-grid-height .e-rowcell{line-height:20px;padding:8px 21px}.e-grid-min-height .e-grid-height .e-gridheader .e-headercell,.e-grid-min-height .e-grid-height .e-gridheader .e-detailheadercell,.e-grid-min-height .e-grid-height .e-gridheader .e-headercell .e-headercelldiv{height:29px}.e-grid-min-height .e-grid-height .e-gridcontent .e-groupcaption{line-height:20px;padding:0 .7em}.e-grid-min-height .e-grid-height .e-summarycell{line-height:18px;padding:8px 21px}.e-device.e-grid-min-height .e-grid-height .e-rowcell{padding:8px 12px}.e-device.e-grid-min-height .e-grid-height .e-rowcell:first-child{padding:8px 12px 8px 16px}.e-device.e-grid-min-height .e-grid-height .e-rowcell:last-child{padding:8px 16px 8px 12px}.e-device.e-grid-min-height .e-rowcell,.e-device.e-grid-min-height .e-rowcell:first-child,.e-device.e-grid-min-height .e-rowcell:last-child{padding-bottom:0;padding-top:0}.e-rtl .e-grid .e-headercell,.e-rtl .e-grid .e-detailheadercell,.e-rtl .e-grid .e-headercelldiv,.e-rtl .e-grid .e-headercelldiv.e-headerchkcelldiv{text-align:right}.e-edit-dialog .e-gridform .e-table{border-collapse:separate;border-spacing:11px;width:100%}.e-edit-dialog .e-dlg-content{position:relative}.e-grid-toolbarmenu .e-responsivetoolbar-menu .e-menu-item.e-focused{background-color:transparent!important}.e-ddl.e-popup.e-popup-flmenu .e-dropdownbase,.e-ddl.e-popup.e-popup-flbar .e-dropdownbase{max-height:298px!important}@-moz-document url-prefix(){.e-grid-min-height .e-rowcell,.e-grid-min-height .e-icon-grightarrow,.e-grid-min-height .e-icon-gdownarrow{line-height:normal}}.e-grid .e-icons:not(.e-btn-icon,.e-check),.e-grid-popup .e-icons:not(.e-btn-icon,.e-check){color:#000}.e-grid .e-ftrchk.e-chkfocus,.e-grid .e-menu-item.e-menufocus,.e-grid li.e-cclist.e-colfocus,.e-grid-popup .e-ftrchk.e-chkfocus,.e-grid-popup .e-menu-item.e-menufocus,.e-grid-popup li.e-cclist.e-colfocus{background-color:#eee}.e-grid .e-ccdlg .e-footer-content,.e-grid-popup .e-ccdlg .e-footer-content{border-color:#0000001f;opacity:1}.e-grid .e-ccdlg .e-cc-searchdiv,.e-grid-popup .e-ccdlg .e-cc-searchdiv{border-color:#212121}.e-grid .e-ccdlg .e-cc-searchdiv.e-input-focus,.e-grid-popup .e-ccdlg .e-cc-searchdiv.e-input-focus{border-color:#ff4081}/*! Grid theme */.e-grid{border-color:#e0e0e0}.e-grid .e-content{background-color:#fff}.e-grid .e-gridpopup span:hover,.e-grid .e-gridpopup .e-spanclicked{color:#000}.e-grid .e-unboundcelldiv .e-icons:not(.e-btn-icon){color:#000}.e-grid .e-table{background-color:#fff}.e-grid .e-focused:not(.e-menu-item):not(.e-editedbatchcell){box-shadow:0 0 0 1px #9e9e9e inset}.e-grid .e-addedrow .e-normaledit .e-rowcell.e-focused{box-shadow:none}.e-grid.e-left-shadow .e-leftfreeze.e-freezeleftborder.e-focused:not(.e-menu-item,.e-xlsel-top-border,.e-xlsel-left-border,.e-xlsel-bottom-border,.e-xlsel-right-border),.e-grid.e-right-shadow .e-rightfreeze.e-freezerightborder.e-focused:not(.e-menu-item,.e-xlsel-top-border,.e-xlsel-left-border,.e-xlsel-bottom-border,.e-xlsel-right-border){border-color:#9e9e9e}.e-grid .e-gridheader .e-icons:not(.e-icon-hide):not(.e-check):not(.e-stop):not(.e-icon-reorderuparrow):not(.e-icon-reorderdownarrow){color:#212121}.e-grid .e-gridheader .e-headercontent .e-icon-reorderuparrow,.e-grid .e-gridheader .e-headercontent .e-icon-reorderdownarrow{color:#212121}.e-grid .e-groupdroparea .e-icons{color:#fff}.e-grid.e-rtl .e-tableborder,.e-grid tr th.e-firstcell{border-left-color:#e0e0e0}.e-grid tr th.e-firstcell,.e-grid .e-tableborder{border-right-color:#e0e0e0}.e-grid .e-xlselaf,.e-grid .e-autofill{background-color:#e3165b}.e-grid .e-autofill,.e-grid .e-xlselaf,.e-grid .e-xlsel{border-color:#e3165b;z-index:1}.e-grid .e-autofill.e-freeze-autofill{z-index:5}.e-grid .e-xlsel{background-color:transparent;border-style:solid;pointer-events:none;position:absolute}.e-grid .e-xlselaf{position:absolute;z-index:3}.e-grid .e-gridcontent tr.e-row:first-child .e-rowcell.e-dragborder,.e-grid .e-gridcontent .e-rowcell.e-dragborder,.e-grid .e-gridcontent .e-groupcaption.e-dragborder,.e-grid .e-gridcontent .e-summarycell.e-dragborder,.e-grid .e-gridcontent .e-rowdragdrop.e-dragborder,.e-grid .e-gridheader thead tr th.e-firstrowdragborder,.e-grid.e-rtl .e-gridcontent tr.e-row:first-child .e-rowcell.e-dragborder,.e-grid.e-rtl .e-gridcontent .e-rowcell.e-dragborder,.e-grid.e-rtl .e-gridcontent .e-rowdragdrop.e-dragborder{box-shadow:0 2px #e3165b;z-index:5}.e-grid .e-gridcontent tr.e-row:first-child .e-rowcell.e-dragborder.e-fixedfreeze,.e-grid .e-gridcontent .e-rowcell.e-dragborder.e-fixedfreeze,.e-grid .e-gridcontent .e-groupcaption.e-dragborder.e-fixedfreeze,.e-grid .e-gridcontent .e-summarycell.e-dragborder.e-fixedfreeze,.e-grid .e-gridcontent .e-rowdragdrop.e-dragborder.e-fixedfreeze,.e-grid .e-gridcontent tr.e-row:first-child .e-rowcell.e-dragborder.e-rightfreeze,.e-grid .e-gridcontent .e-rowcell.e-dragborder.e-rightfreeze,.e-grid .e-gridcontent .e-groupcaption.e-dragborder.e-rightfreeze,.e-grid .e-gridcontent .e-summarycell.e-dragborder.e-rightfreeze,.e-grid .e-gridcontent .e-rowdragdrop.e-dragborder.e-rightfreeze,.e-grid .e-gridcontent .tr.e-row:first-child .e-rowcell.e-dragborder.e-leftfreeze,.e-grid .e-gridcontent .e-rowcell.e-dragborder.e-leftfreeze,.e-grid .e-gridcontent .e-groupcaption.e-dragborder.e-leftfreeze,.e-grid .e-gridcontent .e-summarycell.e-dragborder.e-leftfreeze,.e-grid .e-gridcontent .e-rowdragdrop.e-dragborder.e-leftfreeze,.e-grid.e-rtl .e-gridcontent tr.e-row:first-child .e-rowcell.e-dragborder.e-fixedfreeze,.e-grid.e-rtl .e-gridcontent .e-rowcell.e-dragborder.e-fixedfreeze,.e-grid.e-rtl .e-gridcontent .e-rowdragdrop.e-dragborder.e-fixedfreeze,.e-grid.e-rtl .e-gridcontent tr.e-row:first-child .e-rowcell.e-dragborder.e-rightfreeze,.e-grid.e-rtl .e-gridcontent .e-rowcell.e-dragborder.e-rightfreeze,.e-grid.e-rtl .e-gridcontent .e-rowdragdrop.e-dragborder.e-rightfreeze,.e-grid.e-rtl .e-gridcontent tr.e-row:first-child .e-rowcell.e-dragborder.e-leftfreeze,.e-grid.e-rtl .e-gridcontent .e-rowcell.e-dragborder.e-leftfreeze,.e-grid.e-rtl .e-gridcontent .e-rowdragdrop.e-dragborder.e-leftfreeze,.e-grid .e-gridheader thead tr th.e-firstrowdragborder.e-leftfreeze,.e-grid .e-gridheader thead tr th.e-firstrowdragborder.e-rightfreeze,.e-grid .e-gridheader thead tr th.e-firstrowdragborder.e-fixedfreeze{z-index:6}.e-grid .e-gridcontent tr.e-row:first-child .e-rowcell.e-dragborder:not(.e-leftfreeze,.e-rightfreeze,.e-fixedfreeze),.e-grid .e-gridcontent .e-rowcell.e-dragborder:not(.e-leftfreeze,.e-rightfreeze,.e-fixedfreeze),.e-grid .e-gridcontent .e-groupcaption.e-dragborder:not(.e-leftfreeze,.e-rightfreeze,.e-fixedfreeze),.e-grid .e-gridcontent .e-summarycell.e-dragborder:not(.e-leftfreeze,.e-rightfreeze,.e-fixedfreeze),.e-grid .e-gridcontent .e-rowdragdrop.e-dragborder:not(.e-leftfreeze,.e-rightfreeze,.e-fixedfreeze),.e-grid .e-gridheader thead tr th.e-firstrowdragborder:not(.e-leftfreeze,.e-rightfreeze,.e-fixedfreeze),.e-grid.e-rtl .e-gridcontent tr.e-row:first-child .e-rowcell.e-dragborder:not(.e-leftfreeze,.e-rightfreeze,.e-fixedfreeze),.e-grid.e-rtl .e-gridcontent .e-rowcell.e-dragborder:not(.e-leftfreeze,.e-rightfreeze,.e-fixedfreeze),.e-grid.e-rtl .e-gridcontent .e-rowdragdrop.e-dragborder:not(.e-leftfreeze,.e-rightfreeze,.e-fixedfreeze){position:relative}.e-grid .e-gridheader{background-color:#fff;color:#0000008a;border-bottom-color:#e0e0e0;border-top-color:#e0e0e0}.e-grid .e-gridcontent tr:first-child td{border-top-color:transparent}.e-grid .e-gridcontent tr:first-child td.e-xlsel-top-border{border-top-color:#e3165b}.e-grid th.e-headercell[aria-sort=ascending]:not(.e-columnselection) .e-headertext,.e-grid th.e-headercell[aria-sort=descending]:not(.e-columnselection) .e-headertext,.e-grid th.e-headercell[aria-sort=ascending] .e-sortfilterdiv,.e-grid th.e-headercell[aria-sort=descending] .e-sortfilterdiv{color:#000;opacity:1}.e-grid .e-verticallines tr th,.e-grid .e-grouptopleftcell,.e-grid .e-rowdragheader,.e-grid .e-gridpopup .e-content,.e-grid .e-filterbarcell,.e-grid .e-filterbarcelldisabled,.e-grid.e-default .e-grouptopleftcell,.e-grid.e-default .e-rowdragheader,.e-grid .e-headercell,.e-grid .e-summarycell,.e-grid .e-detailheadercell,.e-grid [aria-selected]+tr .e-detailindentcell,.e-grid.e-default .e-gridheader .e-headercell.e-firstheader,.e-grid.e-default.e-horizontallines .e-headercell.e-firstheader,.e-grid .e-filterbarcell input,.e-grid .e-headercontent,.e-grid.e-default.e-verticallines .e-headercell.e-stackedheadercell,.e-grid.e-default.e-horizontallines .e-grouptopleftcell,.e-grid.e-default .e-gridheader.e-stackedfilter tr:last-child th.e-grouptopleftcell,.e-grid.e-default.e-horizontallines .e-gridheader.e-stackedfilter tr:last-child th.e-grouptopleftcell,.e-grid.e-default .e-gridheader.e-stackedfilter tr:first-child th.e-grouptopleftcell,.e-grid.e-default.e-horizontallines .e-gridheader.e-stackedfilter tr:first-child th.e-grouptopleftcell{border-color:#e0e0e0}.e-grid .e-headercell,.e-grid .e-detailheadercell,.e-grid .e-gridcontent{background-color:#fff}.e-grid .e-gridfooter,.e-grid .e-gridfooter .e-leftfreeze,.e-grid .e-gridfooter .e-rightfreeze,.e-grid .e-gridfooter .e-fixedfreeze{background-color:#f6f6f6}.e-grid .e-rowcell:not(.e-editedbatchcell):not(.e-updatedtd),.e-grid .e-detailrowcollapse:not(.e-editedbatchcell):not(.e-updatedtd),.e-grid .e-detailrowexpand:not(.e-editedbatchcell):not(.e-updatedtd),.e-grid .e-gridcontent .e-rowdragdrop:not(.e-editedbatchcell):not(.e-updatedtd),.e-grid .e-gridheader .e-rowdragdrop:not(.e-editedbatchcell):not(.e-updatedtd),.e-grid .e-emptyrow:not(.e-editedbatchcell):not(.e-updatedtd){color:#000000de}.e-grid .e-summaryrow .e-summarycell,.e-grid .e-summaryrow .e-templatecell,.e-grid .e-summarycontent .e-indentcell,.e-grid .e-indentcell.e-detailindentcelltop,.e-grid .e-groupfooterrow.e-summaryrow .e-indentcell.e-indentcelltop{background-color:#f6f6f6;border-color:#e0e0e0;color:#0000008a}.e-grid .e-rowcell,.e-grid .e-groupcaption,.e-grid .e-indentcell,.e-grid .e-recordplusexpand,.e-grid .e-recordpluscollapse,.e-grid .e-rowdragdropcell,.e-grid .e-detailrowcollapse,.e-grid .e-detailrowexpand,.e-grid .e-detailindentcell,.e-grid .e-detailcell,.e-grid .e-emptyrow.e-show-added-row .e-lastrowcell{border-color:#e0e0e0}.e-grid .e-xlsel-bottom-border{border-bottom-color:#e3165b}.e-grid .e-xlsel-right-border,.e-grid.e-lib:not(.e-rtl) .e-filterbarcell.e-fixedfreeze.e-freezerightborder,.e-grid:not(.e-rtl) .e-filterbarcell.e-fixedfreeze.e-freezerightborder,.e-grid.e-lib:not(.e-rtl) .e-fixedfreeze.e-freezerightborder:not(.e-removefreezerightborder),.e-grid:not(.e-rtl) .e-fixedfreeze.e-freezerightborder:not(.e-removefreezerightborder),.e-grid.e-lib .e-leftfreeze.e-freezeleftborder,.e-grid .e-leftfreeze.e-freezeleftborder,.e-grid.e-rtl .e-rightfreeze.e-freezerightborder,.e-grid.e-rtl .e-filterbarcell.e-fixedfreeze.e-freezeleftborder,.e-grid.e-rtl .e-fixedfreeze.e-freezeleftborder:not(.e-removefreezerightborder){border-right-color:#e3165b}.e-grid .e-rowcell .e-frozen-default-cursor,.e-grid .e-gridheader .e-headercell .e-frozen-default-cursor,.e-grid .e-gridheader .e-filterbarcell .e-frozen-default-cursor,.e-grid.e-rtl .e-leftfreeze.e-freezeleftborder,.e-grid.e-rtl .e-filterbarcell.e-fixedfreeze.e-freezerightborder,.e-grid.e-rtl .e-fixedfreeze.e-freezerightborder:not(.e-removefreezeleftborder),.e-grid.e-lib:not(.e-rtl) .e-rightfreeze.e-freezerightborder,.e-grid:not(.e-rtl) .e-rightfreeze.e-freezerightborder,.e-grid.e-lib:not(.e-rtl) .e-filterbarcell.e-fixedfreeze.e-freezeleftborder,.e-grid:not(.e-rtl) .e-filterbarcell.e-fixedfreeze.e-freezeleftborder,.e-grid.e-lib:not(.e-rtl) .e-fixedfreeze.e-freezeleftborder:not(.e-removefreezeleftborder),.e-grid:not(.e-rtl) .e-fixedfreeze.e-freezeleftborder:not(.e-removefreezeleftborder),.e-grid .e-xlsel-left-border{border-left-color:#e3165b}.e-grid .e-xlsel-top-border{border-top-color:#e3165b}.e-grid .e-leftfreeze:not(.e-summarycell,.e-indentcell,.e-updatedtd,.e-selectionbackground,.e-columnselection,.e-groupcaption,.e-cellselectionbackground,.e-active),.e-grid .e-rightfreeze:not(.e-summarycell,.e-updatedtd,.e-selectionbackground,.e-columnselection,.e-groupcaption,.e-cellselectionbackground,.e-active),.e-grid .e-fixedfreeze:not(.e-summarycell,.e-selectionbackground,.e-updatedtd,.e-columnselection,.e-groupcaption,.e-cellselectionbackground,.e-active){background-color:#fff}.e-grid .e-gridcontent .e-groupcaptionrow .e-leftfreeze.e-groupcaption,.e-grid .e-gridcontent .e-groupcaptionrow .e-leftfreeze.e-recordplusexpand,.e-grid .e-gridcontent .e-groupcaptionrow .e-leftfreeze.e-recordpluscollapse,.e-grid .e-gridcontent .e-groupcaptionrow .e-leftfreeze.ee-indentcell{background-color:#fafafa}.e-grid.e-gridhover .e-frozenhover:not(.e-cellselectionbackground):not(.e-active):not(.e-updatedtd):not(.e-indentcell),.e-grid.e-gridhover .e-row tr:not(.e-disable-gridhover):not(.e-editedrow):not(.e-detailrow):hover .e-rowcell:not(.e-cellselectionbackground):not(.e-active):not(.e-updatedtd):not(.e-indentcell),.e-grid.e-gridhover:not(.e-rowdrag) .e-row:not(.e-disable-gridhover):not(.e-editedrow):not(.e-detailrow):hover .e-rowcell:not(.e-cellselectionbackground):not(.e-active):not(.e-updatedtd):not(.e-indentcell),.e-grid.e-gridhover .e-row:not(.e-disable-gridhover):not(.e-detailrow):hover .e-detailrowcollapse:not(.e-cellselectionbackground):not(.e-active):not(.e-updatedtd):not(.e-indentcell),.e-grid.e-gridhover:not(.e-rowdrag) .e-row:not(.e-disable-gridhover):not(.e-detailrow):hover .e-rowdragdrop:not(.e-cellselectionbackground):not(.e-active):not(.e-updatedtd):not(.e-indentcell),.e-grid.e-rtl .e-gridhover .e-row:not(.e-disable-gridhover):not(.e-detailrow):hover .e-rowdragdrop:not(.e-cellselectionbackground):not(.e-active):not(.e-updatedtd):not(.e-indentcell),.e-grid.e-gridhover .e-row.e-addedrow:not(.e-disable-gridhover):not(.e-detailrow):hover .e-dragindentcell:not(.e-cellselectionbackground):not(.e-active):not(.e-updatedtd):not(.e-indentcell),.e-grid.e-gridhover .e-row:not(.e-disable-gridhover):not(.e-detailrow):hover .e-detailrowexpand:not(.e-cellselectionbackground):not(.e-active):not(.e-updatedtd):not(.e-indentcell){background-color:#eee;color:#000}.e-grid .e-row:hover .e-rowdragdrop{cursor:move}.e-grid .e-notallowedcur .e-row:hover .e-rowdragdrop{cursor:not-allowed}.e-grid .e-sortnumber{background-color:#bbbdc0;color:#000}.e-grid.e-gridhover .e-frozenhover{color:#000}.e-grid .e-col-menu.e-filter-popup{box-shadow:0 8px 10px #0000003d}.e-grid td.e-active,.e-grid td.e-active .e-icon-rowdragicon:before{color:#000}.e-grid td.e-active,.e-grid .e-columnselection{background:#e0e0e0}.e-grid td.e-cellselectionbackground{background:#e0e0e0;color:#000}.e-grid .e-filterbarcell,.e-grid .e-filterbarcelldisabled{background-color:#fff;background-image:none}.e-grid .e-filtered:before{color:#e3165b}.e-grid .e-gridpopup .e-content{background-color:#fff}.e-grid .e-gridpopup .e-downtail:after{border-top-color:#fff}.e-grid .e-gridpopup .e-uptail:after{border-bottom-color:#fff}.e-grid .e-cloneproperties{background-color:#eee;border-color:#e0e0e0;color:#0000008a}.e-grid .e-rhelper{background-color:#000;cursor:col-resize;opacity:.87}.e-grid.e-device .e-rcursor:before{border-right-color:#000;opacity:.87}.e-grid.e-device .e-rcursor:after{border-left-color:#000;opacity:.87}.e-grid.e-resize-lines .e-headercell .e-rhandler,.e-grid.e-resize-lines .e-headercell .e-rsuppress{border-right:1px solid #e0e0e0}.e-grid.e-resize-lines .e-focused .e-rhandler,.e-grid.e-resize-lines .e-focused .e-rsuppress{border:0 none}.e-grid.e-resize-lines .e-headercell.e-stackedheadercell:not(.e-freezerightborder,.e-freezeleftborder){border-bottom:1px solid #e0e0e0;border-right:1px solid #e0e0e0}.e-grid.e-rtl.e-resize-lines .e-headercell.e-stackedheadercell,.e-grid.e-rtl.e-resize-lines .e-headercell .e-rhandler,.e-grid.e-rtl.e-resize-lines .e-headercell .e-rsuppress{border-left:1px solid #e0e0e0;border-right-width:0}.e-grid.e-rtl.e-resize-lines .e-focused .e-rhandler,.e-grid.e-rtl.e-resize-lines .e-focused .e-rsuppress{border:0 none}.e-grid .e-cloneproperties.e-draganddrop{box-shadow:0 3px 8px #00000042;opacity:.95;overflow:visible}.e-grid .e-row .e-dragstartrow:before,.e-grid .e-row .e-selectionbackground .e-dragstartrow:before{color:#e3165b}.e-grid .e-griddragarea{background-color:#eee;border-color:#eee;color:#000}.e-grid .e-groupdroparea{background-color:#e8eaf6;border-top-color:#e0e0e0;color:#000}.e-grid .e-groupdroparea.e-hover{background-color:#c5cae9}.e-grid .e-groupdroparea.e-grouped{background-color:#7986cb}.e-grid .e-groupheadercell{background-color:#3f51b5;border-color:#e0e0e0;border-radius:12px;color:#fff}.e-grid .e-groupheadercell:hover{background-color:#3f51b5;border-color:#000}.e-grid .e-ungroupbutton:hover{color:#fff;opacity:1}.e-grid .e-ungroupbutton{opacity:.7}.e-grid .e-summarycell{color:#0000008a}.e-grid .e-summarycell,.e-grid .e-groupcaption,.e-grid .e-indentcell,.e-grid .e-recordplusexpand,.e-grid .e-recordpluscollapse{background-color:#fafafa;color:#000}.e-grid .e-rowdragheader,.e-grid .e-grouptopleftcell{background-color:#fff}.e-grid .e-gridpopup .e-uptail:before,.e-grid .e-gridpopup .e-uptail,.e-grid .e-stackedheadercell{border-bottom-color:#e0e0e0}.e-grid td.e-updatedtd{background-color:#d7f9c7;color:#000}.e-grid .e-gridpopup .e-downtail:before,.e-grid .e-gridpopup .e-downtail,.e-grid .e-gridcontent table tbody .e-normaledit .e-rowcell{border-top-color:#e0e0e0}.e-grid.e-resize-lines .e-filterbarcell,.e-grid.e-rtl.e-resize-lines .e-filterbarcell,.e-grid .e-gridcontent table tbody tr:not(:first-child) .e-normaledit .e-dragindentcell,.e-grid .e-gridcontent table tbody tr:not(:first-child) .e-normaledit .e-detailrowcollapse,.e-grid .e-gridheader table tbody .e-normaledit .e-dragindentcell,.e-grid .e-gridheader table tbody .e-normaledit .e-detailrowcollapse{border-top:1px solid #e0e0e0}.e-grid .e-gridcontent table tbody tr:first-child .e-normaledit .e-dragindentcell{border-top:0 solid #e0e0e0}.e-grid .e-detailrow .e-grid.e-default .e-normaledit .e-lastrowcell{border-bottom:0}.e-grid .e-cloneproperties.e-draganddrop .e-rowcell{color:#000}.e-grid .e-cloneproperties.e-draganddrop .e-rowcell.e-focused{box-shadow:none}.e-grid .e-cloneproperties.e-draganddrop table,.e-grid .e-cloneproperties.e-draganddrop table .e-selectionbackground{background-color:#eee;height:30px}.e-grid.e-rtl .e-verticallines tr th:first-child:not(.e-firstcell),.e-grid.e-rtl.e-default .e-gridheader .e-headercell.e-firstheader,.e-grid.e-rtl.e-default.e-horizontallines .e-headercell.e-firstheader,.e-grid.e-rtl.e-default.e-verticallines .e-gridheader .e-headercell.e-firstheader,.e-grid.e-rtl.e-default.e-verticallines .e-headercell.e-stackedheadercell,.e-grid.e-rtl.e-default.e-verticallines tr th:last-child,.e-grid.e-rtl.e-default.e-verticallines .e-gridheader th.e-grouptopleftcell,.e-grid.e-rtl.e-default.e-verticallines .e-gridheader th.e-grouptopleftcell.e-lastgrouptopleftcell,.e-grid.e-rtl.e-default.e-bothlines .e-gridheader .e-headercell.e-firstheader,.e-grid.e-rtl.e-default.e-bothlines .e-gridheader th.e-grouptopleftcell.e-lastgrouptopleftcell{border-color:#e0e0e0}.e-grid.e-rtl .e-filterbardropdown{margin-left:15px}.e-grid.sf-grid .e-gridfooter .e-summarycontent{border-right:0 #e0e0e0 solid}.e-grid.sf-grid .e-ccheck.e-colfocus,.e-spreadsheet .e-ftrchk.e-chkfocus{background-color:#eee}.e-tooltip-wrap.e-griderror,.e-control.e-tooltip-wrap.e-popup.e-griderror{background-color:#fcdbe4;border-color:#fcdbe4}.e-tooltip-wrap.e-griderror .e-arrow-tip-inner.e-tip-top,.e-tooltip-wrap.e-griderror .e-arrow-tip-outer.e-tip-top{border-bottom:8px solid #fcdbe4;color:#fcdbe4}.e-tooltip-wrap.e-griderror .e-arrow-tip-outer.e-tip-bottom,.e-tooltip-wrap.e-griderror .e-arrow-tip-inner.e-tip-bottom{border-top:8px solid #fcdbe4;color:#fcdbe4}.e-tooltip-wrap.e-griderror .e-tip-content,.e-tooltip-wrap.e-griderror .e-tip-content label{color:#f44336}.e-dropitemscount{background-color:#e3165b;color:#fff}.e-filterbaroperator.e-dropdownlist{position:absolute}.e-filterbardropdown:not(.e-rtl){margin-right:15px}.e-headercontent .e-filterbar .e-filterbarcell .e-fltrinputdiv .e-input-group .e-filterbardropdown{border:transparent}.e-headercontent .e-filterbar .e-filterbarcell .e-fltrinputdiv .e-input-group .e-filterbardropdown:active,.e-headercontent .e-filterbar .e-filterbarcell .e-fltrinputdiv .e-input-group .e-filterbardropdown.e-input-focus{box-shadow:none}/*! Grid bigger */.e-bigger .e-grid .e-dialog.e-checkboxfilter,.e-bigger .e-grid .e-dialog.e-flmenu,.e-grid-popup.e-bigger .e-dialog.e-checkboxfilter,.e-grid-popup.e-bigger .e-dialog.e-flmenu,.e-bigger .e-grid-popup .e-dialog.e-checkboxfilter,.e-bigger .e-grid-popup .e-dialog.e-flmenu{min-width:260px}.e-bigger .e-grid .e-dialog.e-checkboxfilter,.e-grid-popup.e-bigger .e-dialog.e-checkboxfilter,.e-bigger .e-grid-popup .e-dialog.e-checkboxfilter{min-height:352px}.e-bigger .e-grid .e-flmenu-valuediv,.e-grid-popup.e-bigger .e-flmenu-valuediv,.e-bigger .e-grid-popup .e-flmenu-valuediv{padding:24px 0 0}.e-bigger .e-grid .e-checkboxfilter .e-dlg-content,.e-grid-popup.e-bigger .e-checkboxfilter .e-dlg-content,.e-bigger .e-grid-popup .e-checkboxfilter .e-dlg-content{padding-left:11px}.e-bigger .e-grid .e-checkboxfilter .e-ftrchk,.e-bigger .e-grid .e-checkboxfilter .e-searchbox,.e-grid-popup.e-bigger .e-checkboxfilter .e-ftrchk,.e-grid-popup.e-bigger .e-checkboxfilter .e-searchbox,.e-bigger .e-grid-popup .e-checkboxfilter .e-ftrchk,.e-bigger .e-grid-popup .e-checkboxfilter .e-searchbox{padding-left:13px}.e-bigger .e-grid.e-rtl .e-checkboxfilter .e-dlg-content,.e-grid-popup.e-bigger.e-rtl .e-checkboxfilter .e-dlg-content,.e-bigger .e-grid-popup.e-rtl .e-checkboxfilter .e-dlg-content{padding-left:24px;padding-right:11px}.e-bigger .e-grid.e-rtl .e-checkboxfilter .e-ftrchk,.e-bigger .e-grid.e-rtl .e-checkboxfilter .e-searchbox,.e-grid-popup.e-bigger.e-rtl .e-checkboxfilter .e-ftrchk,.e-grid-popup.e-bigger.e-rtl .e-checkboxfilter .e-searchbox,.e-bigger .e-grid-popup.e-rtl .e-checkboxfilter .e-ftrchk,.e-bigger .e-grid-popup.e-rtl .e-checkboxfilter .e-searchbox{padding-left:0;padding-right:13px}.e-bigger .e-grid .e-ccdlg .e-dlg-content,.e-grid-popup.e-bigger .e-ccdlg .e-dlg-content,.e-bigger .e-grid-popup .e-ccdlg .e-dlg-content{margin:20px 0 0;padding:17px 24px 5px 12px}.e-bigger .e-grid .e-ccdlg .e-ccul-ele,.e-grid-popup.e-bigger .e-ccdlg .e-ccul-ele,.e-bigger .e-grid-popup .e-ccdlg .e-ccul-ele{padding:0}.e-bigger .e-grid .e-ccdlg .e-cc-searchdiv,.e-grid-popup.e-bigger .e-ccdlg .e-cc-searchdiv,.e-bigger .e-grid-popup .e-ccdlg .e-cc-searchdiv{padding-left:6px}.e-bigger .e-grid .e-ccdlg .e-checkbox-wrapper.e-control.e-keyboard,.e-grid-popup.e-bigger .e-ccdlg .e-checkbox-wrapper.e-control.e-keyboard,.e-bigger .e-grid-popup .e-ccdlg .e-checkbox-wrapper.e-control.e-keyboard{padding-left:12px}.e-bigger .e-grid .e-ccdlg li.e-cclist,.e-grid-popup.e-bigger .e-ccdlg li.e-cclist,.e-bigger .e-grid-popup .e-ccdlg li.e-cclist{padding:11px 0}.e-bigger .e-grid .e-ccdlg .e-toolbar .e-ccdiv,.e-grid-popup.e-bigger .e-ccdlg .e-toolbar .e-ccdiv,.e-bigger .e-grid-popup .e-ccdlg .e-toolbar .e-ccdiv{margin-top:0}.e-bigger .e-grid .e-ccdlg .e-cc-searchdiv,.e-grid-popup.e-bigger .e-ccdlg .e-cc-searchdiv,.e-bigger .e-grid-popup .e-ccdlg .e-cc-searchdiv{padding-left:0;padding-right:6px}.e-bigger .e-grid,.e-grid.e-bigger{font-size:13px}.e-bigger .e-grid .e-gridheader thead .e-icons:not(.e-check):not(.e-stop),.e-grid.e-bigger .e-gridheader thead .e-icons:not(.e-check):not(.e-stop){font-size:10px}.e-bigger .e-grid .e-row .e-icon-rowdragicon:before,.e-grid.e-bigger .e-row .e-icon-rowdragicon:before{font-size:10px}.e-bigger .e-grid .e-res-toolbar .e-toolbar-items .e-toolbar-item.e-search-wrapper.e-responsive-right,.e-grid.e-bigger .e-res-toolbar .e-toolbar-items .e-toolbar-item.e-search-wrapper.e-responsive-right{padding-right:5px}.e-bigger .e-grid .e-res-toolbar .e-toolbar-items .e-toolbar-right .e-search-wrapper .e-input-group,.e-grid.e-bigger .e-res-toolbar .e-toolbar-items .e-toolbar-right .e-search-wrapper .e-input-group{width:100%}.e-bigger .e-grid .e-res-toolbar .e-toolbar-items .e-toolbar-item.e-search-wrapper,.e-grid.e-bigger .e-res-toolbar .e-toolbar-items .e-toolbar-item.e-search-wrapper{padding:5px 6px}.e-bigger .e-grid .e-res-toolbar .e-toolbar-items .e-toolbar-item.e-search-wrapper .e-input.e-search,.e-grid.e-bigger .e-res-toolbar .e-toolbar-items .e-toolbar-item.e-search-wrapper .e-input.e-search{width:100%}.e-bigger .e-grid .e-res-toolbar .e-toolbar-items .e-toolbar-item.e-search-wrapper .e-input-group-icon.e-icons.e-sicon.e-clear-icon,.e-grid.e-bigger .e-res-toolbar .e-toolbar-items .e-toolbar-item.e-search-wrapper .e-input-group-icon.e-icons.e-sicon.e-clear-icon{margin:13px 14px 5px 0}.e-bigger .e-grid .e-res-toolbar .e-toolbar-items .e-toolbar-item.e-search-wrapper .e-sicon.e-clear-icon:before,.e-grid.e-bigger .e-res-toolbar .e-toolbar-items .e-toolbar-item.e-search-wrapper .e-sicon.e-clear-icon:before{font-size:17px}.e-bigger .e-grid .e-res-toolbar .e-toolbar-items .e-toolbar-item.e-search-wrapper .e-search .e-search-icon,.e-grid.e-bigger .e-res-toolbar .e-toolbar-items .e-toolbar-item.e-search-wrapper .e-search .e-search-icon{padding-left:0}.e-bigger .e-grid .e-res-toolbar .e-toolbar-items .e-toolbar-item.e-search-wrapper:has(.e-input-group),.e-grid.e-bigger .e-res-toolbar .e-toolbar-items .e-toolbar-item.e-search-wrapper:has(.e-input-group){padding:5px}.e-bigger .e-grid .e-toolbar-items .e-toolbar-item.e-search-wrapper,.e-grid.e-bigger .e-toolbar-items .e-toolbar-item.e-search-wrapper{padding-bottom:8px;padding-top:2px}.e-bigger .e-grid .e-toolbar-items .e-toolbar-item.e-search-wrapper .e-search .e-search-icon,.e-grid.e-bigger .e-toolbar-items .e-toolbar-item.e-search-wrapper .e-search .e-search-icon{min-width:20px}.e-bigger .e-grid .e-toolbar .e-toolbar-item.e-search-wrapper .e-sicon.e-clear-icon,.e-grid.e-bigger .e-toolbar .e-toolbar-item.e-search-wrapper .e-sicon.e-clear-icon{min-width:20px;margin:0 8px 0 0;padding:0}.e-bigger .e-grid .e-toolbar .e-toolbar-item.e-search-wrapper .e-sicon.e-clear-icon:before,.e-grid.e-bigger .e-toolbar .e-toolbar-item.e-search-wrapper .e-sicon.e-clear-icon:before{font-size:12px}.e-bigger .e-grid.e-rtl .e-toolbar .e-toolbar-item.e-search-wrapper .e-sicon.e-clear-icon,.e-grid.e-bigger.e-rtl .e-toolbar .e-toolbar-item.e-search-wrapper .e-sicon.e-clear-icon{min-width:20px;margin:6px 0 5px 6px;padding:0}.e-bigger .e-grid .e-toolbar .e-toolbar-items .e-tbar-btn.e-btn .e-btn-icon.e-icons,.e-grid.e-bigger .e-toolbar .e-toolbar-items .e-tbar-btn.e-btn .e-btn-icon.e-icons{font-size:18px}.e-bigger .e-grid .e-headercell,.e-grid.e-bigger .e-headercell{height:56px;padding:0 28px}.e-bigger .e-grid .e-grid .e-gridheader .e-resizetable tr th:first-child,.e-grid.e-bigger .e-grid .e-gridheader .e-resizetable tr th:first-child{padding-left:28px}.e-bigger .e-grid .e-grid .e-gridheader .e-resizetable tr th:last-child,.e-grid.e-bigger .e-grid .e-gridheader .e-resizetable tr th:last-child{padding-right:28px}.e-bigger .e-grid.e-grid-autofit .e-headercell,.e-grid.e-bigger.e-grid-autofit .e-headercell{padding:0 28px}.e-bigger .e-grid .e-headercelldiv,.e-grid.e-bigger .e-headercelldiv{height:29px;line-height:30px}.e-bigger .e-grid .e-headercell,.e-bigger .e-grid .e-headercelldiv,.e-bigger .e-grid .e-detailheadercell,.e-grid.e-bigger .e-headercell,.e-grid.e-bigger .e-headercelldiv,.e-grid.e-bigger .e-detailheadercell{font-size:12px}.e-bigger .e-grid .e-icons:not(.e-check,.e-stop),.e-grid.e-bigger .e-icons:not(.e-check,.e-stop){font-size:14px}.e-bigger .e-grid .e-gridheader thead .e-icons,.e-grid.e-bigger .e-gridheader thead .e-icons{font-size:16px}.e-bigger .e-grid .e-icon-gdownarrow,.e-grid.e-bigger .e-icon-gdownarrow,.e-bigger .e-grid .e-icon-grightarrow,.e-grid.e-bigger .e-icon-grightarrow,.e-bigger .e-grid .e-toolbar .e-tbar-btn.e-btn .e-btn-icon.e-icons.e-columnchooser-btn,.e-grid.e-bigger .e-toolbar .e-tbar-btn.e-btn .e-btn-icon.e-icons.e-columnchooser-btn{font-size:12px}.e-bigger .e-grid .e-gridheader .e-fltr-icon .e-sortnumber,.e-grid.e-bigger .e-gridheader .e-fltr-icon .e-sortnumber{margin:7px 5px 0 2px}.e-bigger .e-grid .e-gridheader .e-rightalign.e-fltr-icon .e-sortfilterdiv,.e-grid.e-bigger .e-gridheader .e-rightalign.e-fltr-icon .e-sortfilterdiv{margin:-15px -4px}.e-bigger .e-grid .e-gridheader .e-rightalign .e-sortnumber,.e-grid.e-bigger .e-gridheader .e-rightalign .e-sortnumber{float:left;margin:7px 2px 0 5px}.e-bigger .e-grid .e-gridheader .e-rightalign .e-sortfilterdiv,.e-grid.e-bigger .e-gridheader .e-rightalign .e-sortfilterdiv{margin:-16px 4px}.e-bigger .e-grid .e-gridheader .e-rightalign.e-fltr-icon .e-sortnumber,.e-grid.e-bigger .e-gridheader .e-rightalign.e-fltr-icon .e-sortnumber{float:left;margin:7px 2px 0 5px}.e-bigger .e-grid .e-gridheader .e-columnheader.e-wrap .e-sortfilterdiv,.e-grid.e-bigger .e-gridheader .e-columnheader.e-wrap .e-sortfilterdiv{margin:-20px 8px}.e-bigger .e-grid .e-gridheader .e-columnheader.e-wrap .e-rightalign .e-sortfilterdiv .e-wrap .e-rightalign .e-sortfilterdiv,.e-grid.e-bigger .e-gridheader .e-columnheader.e-wrap .e-rightalign .e-sortfilterdiv .e-wrap .e-rightalign .e-sortfilterdiv{margin:-19px 2px -20px}.e-bigger .e-grid .e-gridheader .e-columnheader.e-wrap .e-fltr-icon .e-sortfilterdiv .e-wrap .e-fltr-icon .e-sortfilterdiv,.e-grid.e-bigger .e-gridheader .e-columnheader.e-wrap .e-fltr-icon .e-sortfilterdiv .e-wrap .e-fltr-icon .e-sortfilterdiv{margin:-19px 18px -10px}.e-bigger .e-grid .e-gridheader .e-fltr-icon .e-sortfilterdiv,.e-grid.e-bigger .e-gridheader .e-fltr-icon .e-sortfilterdiv{margin:-15px 24px}.e-bigger .e-grid .e-gridheader tr th:last-child,.e-grid.e-bigger .e-gridheader tr th:last-child{padding-right:28px}.e-bigger .e-grid .e-gridheader tr th:first-child.e-filterbarcell,.e-bigger .e-grid .e-gridheader tr th:last-child.e-filterbarcell,.e-grid.e-bigger .e-gridheader tr th:first-child.e-filterbarcell,.e-grid.e-bigger .e-gridheader tr th:last-child.e-filterbarcell{padding-left:21px}.e-bigger .e-grid .e-gridheader tr th:first-child,.e-grid.e-bigger .e-gridheader tr th:first-child{padding-left:28px}.e-bigger .e-grid.e-wrap .e-columnheader .e-sortfilterdiv,.e-grid.e-bigger.e-wrap .e-columnheader .e-sortfilterdiv{margin:-20px 8px}.e-bigger .e-grid.e-wrap .e-columnheader .e-fltr-icon .e-sortfilterdiv,.e-grid.e-bigger.e-wrap .e-columnheader .e-fltr-icon .e-sortfilterdiv{margin:-19px 18px -10px}.e-bigger .e-grid.e-wrap .e-columnheader .e-fltr-icon.e-rightalign .e-sortfilterdiv,.e-grid.e-bigger.e-wrap .e-columnheader .e-fltr-icon.e-rightalign .e-sortfilterdiv{margin:-19px 2px -20px}.e-bigger .e-grid.e-wrap .e-columnheader .e-fltr-icon .e-sortnumber,.e-grid.e-bigger.e-wrap .e-columnheader .e-fltr-icon .e-sortnumber{margin:2px 2px 0 5px}.e-bigger .e-grid.e-wrap.e-rtl .e-headercell.e-fltr-icon .e-headercelldiv .e-sortnumber,.e-grid.e-bigger.e-wrap.e-rtl .e-headercell.e-fltr-icon .e-headercelldiv .e-sortnumber{margin:0 0 0 10px}.e-bigger .e-grid.e-wrap.e-rtl .e-columnheader .e-fltr-icon .e-sortfilterdiv,.e-grid.e-bigger.e-wrap.e-rtl .e-columnheader .e-fltr-icon .e-sortfilterdiv{margin:-21px 4px -14px 16px}.e-bigger .e-grid.e-wrap.e-rtl .e-columnheader .e-fltr-icon.e-rightalign .e-sortfilterdiv,.e-grid.e-bigger.e-wrap.e-rtl .e-columnheader .e-fltr-icon.e-rightalign .e-sortfilterdiv{margin:-20px 4px -14px 16px}.e-bigger .e-grid .e-headercelldiv,.e-grid.e-bigger .e-headercelldiv{font-size:12px}.e-bigger .e-grid .e-rowcell,.e-bigger .e-grid .e-summarycell,.e-bigger .e-grid .e-groupcaption,.e-grid.e-bigger .e-rowcell,.e-grid.e-bigger .e-summarycell,.e-grid.e-bigger .e-groupcaption{font-size:13px;padding:11px 28px}.e-bigger .e-grid .e-summarycell.e-lastrowcell,.e-grid.e-bigger .e-summarycell.e-lastrowcell{border-bottom-width:1px}.e-bigger .e-grid .e-rowcell:first-child,.e-bigger .e-grid .e-summarycell:first-child,.e-grid.e-bigger .e-rowcell:first-child,.e-grid.e-bigger .e-summarycell:first-child{padding-left:28px}.e-bigger .e-grid .e-rowcell:last-child,.e-bigger .e-grid .e-summarycell:last-child,.e-grid.e-bigger .e-rowcell:last-child,.e-grid.e-bigger .e-summarycell:last-child{padding-right:28px}.e-bigger .e-grid .e-filterbarcell,.e-bigger .e-grid .e-filterbarcelldisabled,.e-grid.e-bigger .e-filterbarcell,.e-grid.e-bigger .e-filterbarcelldisabled{height:56px;padding:0 28px}.e-bigger .e-grid .e-filterbarcell input,.e-grid.e-bigger .e-filterbarcell input{height:26px}.e-bigger .e-grid .e-ftrchk,.e-grid.e-bigger .e-ftrchk{padding-bottom:13px;padding-top:13px}.e-bigger .e-grid .e-columnmenu,.e-grid.e-bigger .e-columnmenu{bottom:31px;top:35px}.e-bigger .e-grid.e-device.e-noselect,.e-grid.e-bigger.e-device.e-noselect{-webkit-user-select:none;user-select:none}.e-bigger .e-grid .e-filtermenudiv,.e-grid.e-bigger .e-filtermenudiv{margin:-18px -7px}.e-bigger .e-grid.e-wrap .e-filtermenudiv,.e-grid.e-bigger.e-wrap .e-filtermenudiv{margin:-25px -2px -12px 8px}.e-bigger .e-grid .e-sortfilterdiv,.e-grid.e-bigger .e-sortfilterdiv{margin:-17px 8px}.e-bigger .e-grid.e-rtl .e-gridheader .e-headercell .e-headercelldiv.e-headerchkcelldiv,.e-grid.e-bigger.e-rtl .e-gridheader .e-headercell .e-headercelldiv.e-headerchkcelldiv{padding:0 .6em 0 1.15em}.e-bigger .e-grid .e-wrap .e-sortfilterdiv,.e-grid.e-bigger .e-wrap .e-sortfilterdiv{margin:-20px 8px}.e-bigger .e-grid .e-gridheader .e-columnheader.e-wrap .e-rightalign.e-fltr-icon .e-sortfilterdiv,.e-bigger .e-grid .e-wrap .e-rightalign.e-fltr-icon .e-sortfilterdiv,.e-grid.e-bigger .e-gridheader .e-columnheader.e-wrap .e-rightalign.e-fltr-icon .e-sortfilterdiv,.e-grid.e-bigger .e-wrap .e-rightalign.e-fltr-icon .e-sortfilterdiv{margin:-12px 2px}.e-bigger .e-grid.e-wrap .e-rowcell,.e-bigger .e-grid.e-wrap .e-columnheader .e-stackedheadercelldiv,.e-bigger .e-grid.e-wrap .e-columnheader .e-headercelldiv,.e-grid.e-bigger.e-wrap .e-rowcell,.e-grid.e-bigger.e-wrap .e-columnheader .e-stackedheadercelldiv,.e-grid.e-bigger.e-wrap .e-columnheader .e-headercelldiv{line-height:18px}.e-bigger .e-grid .e-sortnumber,.e-grid.e-bigger .e-sortnumber{border-radius:65%;display:inline-block;float:right;text-align:center;font-size:9px;height:15px;line-height:16px;margin:7px 5px 0 2px;width:15px}.e-bigger .e-grid.e-rtl .e-headercell.e-fltr-icon .e-headercelldiv .e-sortnumber,.e-grid.e-bigger.e-rtl .e-headercell.e-fltr-icon .e-headercelldiv .e-sortnumber{margin:6px 0 0 10px}.e-bigger .e-grid.e-rtl .e-headercell .e-sortfilterdiv,.e-bigger .e-grid.e-rtl .e-detailheadercell .e-sortfilterdiv,.e-grid.e-bigger.e-rtl .e-headercell .e-sortfilterdiv,.e-grid.e-bigger.e-rtl .e-detailheadercell .e-sortfilterdiv{margin:-17px 10px}.e-bigger .e-grid.e-rtl .e-filtermenudiv,.e-grid.e-bigger.e-rtl .e-filtermenudiv,.e-bigger .e-grid.e-rtl .e-rightalign .e-filtermenudiv,.e-grid.e-bigger.e-rtl .e-rightalign .e-filtermenudiv{margin:-20px 0 -18px -11px}.e-bigger .e-grid.e-rtl.e-wrap .e-filtermenudiv,.e-grid.e-bigger.e-rtl.e-wrap .e-filtermenudiv{margin:-25px 4px -14px -6px}.e-bigger .e-grid.e-rtl.e-wrap .e-rightalign .e-filtermenudiv,.e-grid.e-bigger.e-rtl.e-wrap .e-rightalign .e-filtermenudiv{margin:-25px 4px -14px -8px}.e-bigger .e-grid.e-rtl .e-headercell .e-headercelldiv .e-sortnumber,.e-bigger .e-grid.e-rtl .e-detailheadercell .e-headercelldiv .e-sortnumber,.e-grid.e-bigger.e-rtl .e-headercell .e-headercelldiv .e-sortnumber,.e-grid.e-bigger.e-rtl .e-detailheadercell .e-headercelldiv .e-sortnumber,.e-bigger .e-grid.e-rtl .e-headercell.e-rightalign .e-headercelldiv .e-sortnumber,.e-bigger .e-grid.e-rtl .e-detailheadercell.e-rightalign .e-headercelldiv .e-sortnumber,.e-grid.e-bigger.e-rtl .e-headercell.e-rightalign .e-headercelldiv .e-sortnumber,.e-grid.e-bigger.e-rtl .e-detailheadercell.e-rightalign .e-headercelldiv .e-sortnumber{margin:6px 0 0 10px}.e-bigger .e-grid.e-rtl .e-gridheader .e-rightalign .e-sortfilterdiv,.e-grid.e-bigger.e-rtl .e-gridheader .e-rightalign .e-sortfilterdiv{margin:-17px 10px}.e-bigger .e-grid.e-rtl .e-gridheader .e-fltr-icon .e-sortfilterdiv,.e-grid.e-bigger.e-rtl .e-gridheader .e-fltr-icon .e-sortfilterdiv{margin:-17px 30px 0 14px}.e-bigger .e-grid.e-rtl .e-gridheader .e-rightalign.e-fltr-icon .e-sortfilterdiv,.e-grid.e-bigger.e-rtl .e-gridheader .e-rightalign.e-fltr-icon .e-sortfilterdiv{margin:-17px 14px}.e-bigger .e-grid.e-rtl .e-groupsort,.e-bigger .e-grid.e-rtl .e-ungroupbutton,.e-bigger .e-grid.e-rtl .e-toggleungroup,.e-grid.e-bigger.e-rtl .e-groupsort,.e-grid.e-bigger.e-rtl .e-ungroupbutton,.e-grid.e-bigger.e-rtl .e-toggleungroup{margin-left:0}.e-bigger .e-grid.e-rtl .e-groupheadercell,.e-bigger .e-grid.e-rtl .e-groupheadercell:hover,.e-grid.e-bigger.e-rtl .e-groupheadercell,.e-grid.e-bigger.e-rtl .e-groupheadercell:hover{margin:3px 24px 0 0;padding:0 12px 0 8px}.e-bigger .e-grid.e-rtl .e-device .e-groupheadercell,.e-grid.e-bigger.e-rtl .e-device .e-groupheadercell{padding:0 12px 0 8px}.e-bigger .e-grid.e-rtl span.e-ungroupbutton.e-icons,.e-grid.e-bigger.e-rtl span.e-ungroupbutton.e-icons{margin-left:0;margin-right:6px;margin-top:0;padding-left:0}.e-bigger .e-grid.e-rtl .e-headercell .e-frozen-right-cursor,.e-bigger .e-grid.e-rtl .e-headercell .e-frozen-fixedleft-cursor,.e-bigger .e-grid.e-rtl .e-headercell .e-frozen-left-cursor,.e-bigger .e-grid.e-rtl .e-headercell .e-frozen-fixedright-cursor,.e-grid.e-bigger.e-rtl .e-headercell .e-frozen-right-cursor,.e-grid.e-bigger.e-rtl .e-headercell .e-frozen-fixedleft-cursor,.e-grid.e-bigger.e-rtl .e-headercell .e-frozen-left-cursor,.e-grid.e-bigger.e-rtl .e-headercell .e-frozen-fixedright-cursor{left:0}.e-bigger .e-grid.e-rtl .e-headercell .e-frozen-right-cursor.e-frozen-resize-cursor:not(.e-frozen-default-cursor),.e-bigger .e-grid.e-rtl .e-headercell .e-frozen-left-cursor.e-frozn-resize-cursor,.e-grid.e-bigger.e-rtl .e-headercell .e-frozen-right-cursor.e-frozen-resize-cursor:not(.e-frozen-default-cursor),.e-grid.e-bigger.e-rtl .e-headercell .e-frozen-left-cursor.e-frozn-resize-cursor{left:3px}.e-bigger .e-grid.e-rtl .e-filterbarcell .e-frozen-fixedright-cursor,.e-bigger .e-grid.e-rtl .e-filterbarcell .e-frozen-left-cursor,.e-bigger .e-grid.e-rtl .e-filterbarcell .e-frozen-fixedleft-cursor,.e-bigger .e-grid.e-rtl .e-filterbarcell .e-frozen-right-cursor,.e-grid.e-bigger.e-rtl .e-filterbarcell .e-frozen-fixedright-cursor,.e-grid.e-bigger.e-rtl .e-filterbarcell .e-frozen-left-cursor,.e-grid.e-bigger.e-rtl .e-filterbarcell .e-frozen-fixedleft-cursor,.e-grid.e-bigger.e-rtl .e-filterbarcell .e-frozen-right-cursor{left:0}.e-bigger .e-grid.e-rtl .e-filterbarcell .e-frozen-right-cursor.e-frozen-resize-cursor:not(.e-frozen-default-cursor),.e-bigger .e-grid.e-rtl .e-filterbarcell .e-frozen-left-cursor.e-frozen-resize-cursor,.e-grid.e-bigger.e-rtl .e-filterbarcell .e-frozen-right-cursor.e-frozen-resize-cursor:not(.e-frozen-default-cursor),.e-grid.e-bigger.e-rtl .e-filterbarcell .e-frozen-left-cursor.e-frozen-resize-cursor{left:3px}.e-bigger .e-grid .e-rowcell,.e-bigger .e-grid .e-summarycell,.e-bigger .e-grid .e-emptyrow td,.e-bigger .e-grid:not(.e-grid-min-height) .e-gridcontent tr td:not(.e-indentcell):first-child:empty,.e-bigger .e-grid:not(.e-grid-min-height) .e-gridcontent tr.e-row .e-rowcell:empty,.e-grid.e-bigger .e-rowcell,.e-grid.e-bigger .e-summarycell,.e-grid.e-bigger .e-emptyrow td,.e-grid.e-bigger:not(.e-grid-min-height) .e-gridcontent tr td:not(.e-indentcell):first-child:empty,.e-grid.e-bigger:not(.e-grid-min-height) .e-gridcontent tr.e-row .e-rowcell:empty{line-height:27px}.e-bigger .e-grid .e-xlsel-bottom-border.e-xlsel-top-border,.e-grid.e-bigger .e-xlsel-bottom-border.e-xlsel-top-border{line-height:23px}.e-bigger .e-grid .e-xlsel-bottom-border,.e-grid.e-bigger .e-xlsel-bottom-border{line-height:25px}.e-bigger .e-grid .e-filterbarcell input,.e-grid.e-bigger .e-filterbarcell input{font-size:13px}.e-bigger .e-grid .e-groupdroparea,.e-grid.e-bigger .e-groupdroparea{font-size:19px;min-height:64px;padding:22px 24px}.e-bigger .e-grid .e-cloneproperties,.e-grid.e-bigger .e-cloneproperties{padding:4px 5px}.e-bigger .e-grid .e-cloneproperties.e-draganddrop,.e-grid.e-bigger .e-cloneproperties.e-draganddrop{padding:0}.e-bigger .e-grid .e-headerclone,.e-grid.e-bigger .e-headerclone{font-size:12px}.e-bigger .e-grid .e-dropitemscount,.e-grid.e-bigger .e-dropitemscount{font-size:14px}.e-bigger .e-grid .e-groupdroparea.e-grouped,.e-grid.e-bigger .e-groupdroparea.e-grouped{padding:11px 0 12px}.e-bigger .e-grid:not(.e-grid-min-height) .e-gridcontent tr td:not(.e-indentcell):first-child:empty,.e-bigger .e-grid:not(.e-grid-min-height) .e-gridcontent tr.e-row .e-rowcell:empty,.e-grid.e-bigger:not(.e-grid-min-height) .e-gridcontent tr td:not(.e-indentcell):first-child:empty,.e-grid.e-bigger:not(.e-grid-min-height) .e-gridcontent tr.e-row .e-rowcell:empty{height:49px}.e-bigger .e-grid.e-bigger .e-columnmenu,.e-grid.e-bigger.e-bigger .e-columnmenu{bottom:16px;margin:-18.5px -18px}.e-bigger .e-grid .e-columnmenu,.e-grid.e-bigger .e-columnmenu{right:23px}.e-bigger .e-grid .e-groupheadercell,.e-bigger .e-grid .e-groupheadercell:hover,.e-grid.e-bigger .e-groupheadercell,.e-grid.e-bigger .e-groupheadercell:hover{border-radius:16px;height:32px;margin:4px 0 0 24px;padding:0 8px 0 12px;font-size:13px}.e-bigger .e-grid .e-groupheadercell:hover,.e-grid.e-bigger .e-groupheadercell:hover{padding:0 8px 0 12px}.e-bigger .e-grid .e-gdclone,.e-grid.e-bigger .e-gdclone{border-radius:17px;padding:6px}.e-bigger .e-grid .e-groupheadercell span,.e-grid.e-bigger .e-groupheadercell span{height:32px;line-height:32px;padding:0}.e-bigger .e-grid .e-groupheadercell .e-ungroupbutton,.e-grid.e-bigger .e-groupheadercell .e-ungroupbutton{font-size:16px}.e-bigger .e-grid .e-groupheadercell .e-grouptext,.e-grid.e-bigger .e-groupheadercell .e-grouptext{line-height:32px}.e-bigger .e-grid .e-row .e-input-group .e-input.e-field,.e-bigger .e-grid .e-row .e-input-focus .e-input.e-field,.e-grid.e-bigger .e-row .e-input-group .e-input.e-field,.e-grid.e-bigger .e-row .e-input-focus .e-input.e-field{font-family:Roboto,Segoe UI,GeezaPro,"DejaVu Serif","sans-serif",-apple-system,BlinkMacSystemFont;font-size:13px;padding-bottom:9px;padding-top:13px}.e-bigger .e-grid .e-row .e-input-group,.e-grid.e-bigger .e-row .e-input-group{margin-bottom:5px;vertical-align:middle}.e-bigger .e-grid.e-device .e-filterbarcell,.e-grid.e-bigger.e-device .e-filterbarcell{padding:8px 12px}.e-bigger .e-grid.e-device .e-filterbarcell:first-child,.e-grid.e-bigger.e-device .e-filterbarcell:first-child{padding:8px 12px 8px 16px}.e-bigger .e-grid.e-device .e-filterbarcell:last-child,.e-grid.e-bigger.e-device .e-filterbarcell:last-child{padding:8px 16px 8px 12px}.e-bigger .e-grid.e-device .e-groupheadercell .e-ungroupbutton,.e-grid.e-bigger.e-device .e-groupheadercell .e-ungroupbutton{line-height:30px}.e-bigger .e-grid.e-device .e-columnmenu,.e-grid.e-bigger.e-device .e-columnmenu{margin:-18px}.e-bigger .e-grid.e-device .e-groupheadercell,.e-grid.e-bigger.e-device .e-groupheadercell{padding:0 8px 0 12px}.e-bigger .e-grid.e-device .e-groupheadercell span,.e-grid.e-bigger.e-device .e-groupheadercell span{line-height:30px;padding:0}.e-bigger .e-grid.e-device .e-headercell,.e-grid.e-bigger.e-device .e-headercell{padding:0 21px}.e-bigger .e-grid.e-device .e-headercell:first-child,.e-grid.e-bigger.e-device .e-headercell:first-child{padding:0 12px 0 16px}.e-bigger .e-grid.e-device .e-headercell:last-child,.e-grid.e-bigger.e-device .e-headercell:last-child{padding:0 16px 0 12px}.e-bigger .e-grid.e-device .e-rowcell,.e-bigger .e-grid.e-device .e-summarycell,.e-grid.e-bigger.e-device .e-rowcell,.e-grid.e-bigger.e-device .e-summarycell{padding:8px 12px}.e-bigger .e-grid.e-device .e-row .e-input-group .e-input.e-field,.e-bigger .e-grid.e-device .e-row .e-input-focus .e-input.e-field,.e-grid.e-bigger.e-device .e-row .e-input-group .e-input.e-field,.e-grid.e-bigger.e-device .e-row .e-input-focus .e-input.e-field{padding-bottom:5px;padding-top:5px}.e-bigger .e-grid.e-device .e-normaledit .e-rowcell,.e-bigger .e-grid.e-device .e-editedbatchcell.e-rowcell,.e-grid.e-bigger.e-device .e-normaledit .e-rowcell,.e-grid.e-bigger.e-device .e-editedbatchcell.e-rowcell{padding-bottom:0;padding-top:0}.e-bigger .e-grid.e-device span.e-ungroupbutton.e-icons,.e-grid.e-bigger.e-device span.e-ungroupbutton.e-icons,.e-bigger .e-grid.e-device span.e-groupsort.e-icons,.e-grid.e-bigger.e-device span.e-groupsort.e-icons{margin-top:0}.e-bigger .e-grid:not(.e-row-responsive).e-device .e-rowcell:first-child,.e-bigger .e-grid:not(.e-row-responsive).e-device .e-summarycell:first-child,.e-grid.e-bigger:not(.e-row-responsive).e-device .e-rowcell:first-child,.e-grid.e-bigger:not(.e-row-responsive).e-device .e-summarycell:first-child{padding:8px 12px 8px 16px}.e-bigger .e-grid:not(.e-row-responsive).e-device .e-rowcell:last-child,.e-bigger .e-grid:not(.e-row-responsive).e-device .e-summarycell:last-child,.e-grid.e-bigger:not(.e-row-responsive).e-device .e-rowcell:last-child,.e-grid.e-bigger:not(.e-row-responsive).e-device .e-summarycell:last-child{padding:8px 16px 8px 12px}.e-bigger .e-grid .e-unboundcell,.e-bigger .e-grid .e-editedrow .e-normaledit .e-unboundcell,.e-bigger .e-grid .e-addedrow .e-normaledit .e-unboundcell,.e-grid.e-bigger .e-unboundcell,.e-grid.e-bigger .e-editedrow .e-normaledit .e-unboundcell,.e-grid.e-bigger .e-addedrow .e-normaledit .e-unboundcell{padding-bottom:6px;padding-top:6px}.e-bigger .e-grid .e-grouptext,.e-grid.e-bigger .e-grouptext{margin-right:8px;width:76px}.e-bigger .e-grid .e-groupsort,.e-bigger .e-grid span.e-ungroupbutton,.e-bigger .e-grid .e-toggleungroup,.e-grid.e-bigger .e-groupsort,.e-grid.e-bigger span.e-ungroupbutton,.e-grid.e-bigger .e-toggleungroup{margin-left:8px;margin-top:0}.e-bigger .e-grid span.e-ungroupbutton.e-icons,.e-grid.e-bigger span.e-ungroupbutton.e-icons{font-size:16px;margin-left:0;padding-top:0;margin-top:0;margin-right:0;padding-right:0}.e-bigger .e-grid span.e-groupsort.e-icons,.e-grid.e-bigger span.e-groupsort.e-icons{margin-right:0;margin-top:0}.e-bigger .e-grid .e-groupcaption,.e-grid.e-bigger .e-groupcaption{line-height:32px}.e-bigger .e-grid .e-rowcell.e-frozen-right-border,.e-bigger .e-grid .e-headercell.e-frozen-right-border,.e-bigger .e-grid .e-filterbarcell.e-frozen-right-border,.e-grid.e-bigger .e-rowcell.e-frozen-right-border,.e-grid.e-bigger .e-headercell.e-frozen-right-border,.e-grid.e-bigger .e-filterbarcell.e-frozen-right-border{border-right:2px solid rgba(227,22,91,.6)}.e-bigger .e-grid .e-rowcell.e-frozen-left-border,.e-bigger .e-grid .e-headercell.e-frozen-left-border,.e-bigger .e-grid .e-filterbarcell.e-frozen-left-border,.e-grid.e-bigger .e-rowcell.e-frozen-left-border,.e-grid.e-bigger .e-headercell.e-frozen-left-border,.e-grid.e-bigger .e-filterbarcell.e-frozen-left-border{border-left:2px solid rgba(227,22,91,.6)}.e-bigger .e-grid .e-rowcell.e-freezeline,.e-bigger .e-grid .e-gridheader .e-filterbarcell.e-freezeline,.e-grid.e-bigger .e-rowcell.e-freezeline,.e-grid.e-bigger .e-gridheader .e-filterbarcell.e-freezeline{position:relative}.e-bigger .e-grid .e-rowcell .e-frozen-right-cursor,.e-bigger .e-grid .e-rowcell .e-frozen-fixedright-cursor,.e-bigger .e-grid .e-rowcell .e-frozen-left-cursor,.e-bigger .e-grid .e-rowcell .e-frozen-fixedleft-cursor,.e-bigger .e-grid .e-gridheader .e-headercell .e-frozen-right-cursor,.e-bigger .e-grid .e-gridheader .e-headercell .e-frozen-fixedright-cursor,.e-bigger .e-grid .e-gridheader .e-headercell .e-frozen-left-cursor,.e-bigger .e-grid .e-gridheader .e-headercell .e-frozen-fixedleft-cursor,.e-bigger .e-grid .e-gridheader .e-filterbarcell .e-frozen-right-cursor,.e-bigger .e-grid .e-gridheader .e-filterbarcell .e-frozen-fixedright-cursor,.e-bigger .e-grid .e-gridheader .e-filterbarcell .e-frozen-left-cursor,.e-bigger .e-grid .e-gridheader .e-filterbarcell .e-frozen-fixedleft-cursor,.e-grid.e-bigger .e-rowcell .e-frozen-right-cursor,.e-grid.e-bigger .e-rowcell .e-frozen-fixedright-cursor,.e-grid.e-bigger .e-rowcell .e-frozen-left-cursor,.e-grid.e-bigger .e-rowcell .e-frozen-fixedleft-cursor,.e-grid.e-bigger .e-gridheader .e-headercell .e-frozen-right-cursor,.e-grid.e-bigger .e-gridheader .e-headercell .e-frozen-fixedright-cursor,.e-grid.e-bigger .e-gridheader .e-headercell .e-frozen-left-cursor,.e-grid.e-bigger .e-gridheader .e-headercell .e-frozen-fixedleft-cursor,.e-grid.e-bigger .e-gridheader .e-filterbarcell .e-frozen-right-cursor,.e-grid.e-bigger .e-gridheader .e-filterbarcell .e-frozen-fixedright-cursor,.e-grid.e-bigger .e-gridheader .e-filterbarcell .e-frozen-left-cursor,.e-grid.e-bigger .e-gridheader .e-filterbarcell .e-frozen-fixedleft-cursor{cursor:move;height:100%;position:absolute;top:0;width:4px}.e-bigger .e-grid .e-rowcell .e-frozen-left-cursor,.e-bigger .e-grid .e-rowcell .e-frozen-fixedright-cursor,.e-bigger .e-grid .e-rowcell .e-frozen-right-cursor,.e-bigger .e-grid .e-rowcell .e-frozen-fixedleft-cursor,.e-grid.e-bigger .e-rowcell .e-frozen-left-cursor,.e-grid.e-bigger .e-rowcell .e-frozen-fixedright-cursor,.e-grid.e-bigger .e-rowcell .e-frozen-right-cursor,.e-grid.e-bigger .e-rowcell .e-frozen-fixedleft-cursor{left:0}.e-bigger .e-grid .e-rowcell .e-frozen-left-cursor.e-frozen-resize-cursor,.e-grid.e-bigger .e-rowcell .e-frozen-left-cursor.e-frozen-resize-cursor{left:3px}.e-bigger .e-grid .e-frozen-helper,.e-grid.e-bigger .e-frozen-helper{border-left:2px solid rgba(227,22,91,.6);cursor:move;position:absolute;z-index:2}.e-bigger .e-grid .e-content.e-freezeline-moving,.e-grid.e-bigger .e-content.e-freezeline-moving{-webkit-user-select:none;user-select:none}.e-bigger .e-grid .e-normaledit .e-rowcell,.e-bigger .e-grid .e-editedbatchcell.e-rowcell,.e-grid.e-bigger .e-normaledit .e-rowcell,.e-grid.e-bigger .e-editedbatchcell.e-rowcell{padding-bottom:0;padding-top:0}.e-bigger .e-grid:not(.sf-grid) .e-gridheader table th[rowspan],.e-bigger .e-grid:not(.sf-grid).e-device .e-gridheader table th[rowspan],.e-grid:not(.sf-grid).e-bigger .e-gridheader table th[rowspan],.e-grid:not(.sf-grid).e-bigger.e-device .e-gridheader table th[rowspan]{padding-bottom:20px}.e-bigger .e-grid .e-gridcontent .e-groupcaptionrow .e-lastrowcell.e-recordplusexpand~td.e-lastrowcell.e-groupcaption,.e-bigger .e-grid .e-gridcontent .e-groupcaptionrow .e-lastrowcell.e-recordplusexpand~td.e-lastrowcell.e-summarycell,.e-grid.e-bigger .e-gridcontent .e-groupcaptionrow .e-lastrowcell.e-recordplusexpand~td.e-lastrowcell.e-groupcaption,.e-grid.e-bigger .e-gridcontent .e-groupcaptionrow .e-lastrowcell.e-recordplusexpand~td.e-lastrowcell.e-summarycell{border-bottom-width:0}.e-grid.e-bigger .e-res-toolbar .e-toolbar-items .e-tbar-btn:hover{background:none}.e-grid.e-bigger .e-res-toolbar .e-toolbar-items .e-responsive-right .e-search-wrapper .e-sicon.e-clear-icon{margin:14px 8px 5px 0}.e-grid.e-bigger .e-res-toolbar .e-toolbar-items .e-responsive-right .e-search-wrapper .e-sicon.e-clear-icon:before{font-size:18px}.e-bigger .e-grid .e-group-animator .e-groupheadercell,.e-bigger .e-grid .e-group-animator .e-groupheadercell:hover{margin:15px 0;border-bottom-width:1px}.e-bigger .e-grid .e-group-animate.e-groupdroparea .e-nextgroup{margin-top:15px}.e-grid.sf-grid .e-bigger .e-grid.sf-grid.e-grid.sf-grid .e-gridheader table th:not([rowspan="1"]),.e-grid.sf-grid .e-bigger .e-grid.sf-grid.e-grid.sf-grid.e-device .e-gridheader table th:not([rowspan="1"]),.e-grid.sf-grid .e-grid.sf-grid.e-grid.sf-grid.e-bigger .e-gridheader table th:not([rowspan="1"]),.e-grid.sf-grid .e-grid.sf-grid.e-grid.sf-grid.e-bigger.e-device .e-gridheader table th:not([rowspan="1"]){padding-bottom:20px}.e-bigger .e-grid.sf-grid .e-res-toolbar .e-toolbar-items .e-toolbar-item.e-search-wrapper:has(.e-input-group){padding-right:5px}.e-bigger .e-grid .e-gridheader .e-headercontent .e-reorderuparrow,.e-bigger .e-grid .e-gridheader .e-headercontent .e-reorderdownarrow,.e-bigger.e-grid .e-gridheader .e-headercontent .e-reorderuparrow,.e-bigger.e-grid .e-gridheader .e-headercontent .e-reorderdownarrow{font-size:8px}.e-bigger .e-grid .e-gridheader thead .e-icons,.e-bigger.e-grid .e-gridheader thead .e-icons{font-size:16px}.e-bigger .e-grid .e-columnmenu,.e-bigger.e-grid .e-columnmenu{margin:-18.5px -18px}.e-bigger .e-grid.e-rtl .e-columnmenu,.e-bigger.e-grid.e-rtl .e-columnmenu{margin:-19px -18px -18px 3px;right:auto}.e-bigger .e-grid.e-rtl.e-device .e-columnmenu,.e-bigger.e-grid.e-rtl.e-device .e-columnmenu{margin:-19px -18px -18px 3px}.e-bigger .e-grid.e-rtl .e-groupheadercell span,.e-bigger.e-grid.e-rtl .e-groupheadercell span,.e-bigger .e-grid.e-device.e-rtl .e-groupheadercell span,.e-bigger.e-grid.e-device.e-rtl .e-groupheadercell span{padding:0}.e-bigger .e-grid.e-grid-min-height .e-grid-height .e-rowcell{line-height:27px;padding:11px 28px}.e-bigger .e-grid.e-grid-min-height .e-grid-height .e-rowcell:first-child{line-height:28px;padding-left:28px}.e-bigger .e-grid.e-grid-min-height .e-grid-height .e-rowcell:last-child{line-height:28px;padding-right:28px}.e-bigger .e-grid.e-grid-min-height .e-rowcell,.e-bigger .e-grid.e-grid-min-height .e-rowcell:first-child,.e-bigger .e-grid.e-grid-min-height .e-rowcell:last-child{line-height:0;padding-bottom:0;padding-top:0}.e-bigger .e-wrap.e-grid-min-height .e-rowcell{line-height:18px}.e-bigger .e-wrap.e-grid-min-height:not(.e-grid-min-height) .e-gridcontent tr td:not(.e-indentcell):first-child:empty,.e-bigger .e-wrap.e-grid-min-height:not(.e-grid-min-height) .e-gridcontent tr.e-row .e-rowcell:empty{height:18px}.e-bigger .e-wrap.e-grid-min-height .e-grid-height .e-rowcell{line-height:18px}.e-bigger .e-wrap.e-grid-min-height .e-grid-height:not(.e-grid-min-height) .e-gridcontent tr td:not(.e-indentcell):first-child:empty,.e-bigger .e-wrap.e-grid-min-height .e-grid-height:not(.e-grid-min-height) .e-gridcontent tr.e-row .e-rowcell:empty{height:49px}.e-bigger .e-grid.e-row-responsive .e-toolbar .e-tbar-btn:hover,.e-bigger .e-grid.e-row-responsive .e-toolbar .e-tbar-btn:active,.e-bigger .e-grid.e-row-responsive .e-toolbar .e-tbar-btn:focus,.e-bigger.e-grid.e-row-responsive .e-toolbar .e-tbar-btn:hover,.e-bigger.e-grid.e-row-responsive .e-toolbar .e-tbar-btn:active,.e-bigger.e-grid.e-row-responsive .e-toolbar .e-tbar-btn:focus{background:none}.e-bigger .e-grid.e-row-responsive .e-toolbar .e-tbar-btn:hover .e-icons,.e-bigger .e-grid.e-row-responsive .e-toolbar .e-tbar-btn:active .e-icons,.e-bigger .e-grid.e-row-responsive .e-toolbar .e-tbar-btn:focus .e-icons,.e-bigger.e-grid.e-row-responsive .e-toolbar .e-tbar-btn:hover .e-icons,.e-bigger.e-grid.e-row-responsive .e-toolbar .e-tbar-btn:active .e-icons,.e-bigger.e-grid.e-row-responsive .e-toolbar .e-tbar-btn:focus .e-icons{padding-bottom:0}.e-bigger .e-grid.e-row-responsive .e-toolbar .e-search-icon,.e-bigger.e-grid.e-row-responsive .e-toolbar .e-search-icon{background:none}.e-bigger .e-grid.e-row-responsive .e-responsive-header,.e-bigger.e-grid.e-row-responsive .e-responsive-header{border-top:1px solid;border-top-color:#e0e0e0}.e-bigger .e-grid.e-row-responsive .e-gridcontent td:before,.e-bigger .e-grid.e-row-responsive .e-summarycontent td:before,.e-bigger.e-grid.e-row-responsive .e-gridcontent td:before,.e-bigger.e-grid.e-row-responsive .e-summarycontent td:before{content:attr(data-cell);font-weight:500;left:13px;padding-right:10px;position:absolute;top:6px;white-space:nowrap;text-overflow:ellipsis;overflow:hidden;width:45%}.e-bigger .e-grid.e-row-responsive .e-gridcontent .e-verticalwrap td:before,.e-bigger .e-grid.e-row-responsive .e-summarycontent .e-verticalwrap td:before,.e-bigger.e-grid.e-row-responsive .e-gridcontent .e-verticalwrap td:before,.e-bigger.e-grid.e-row-responsive .e-summarycontent .e-verticalwrap td:before{line-height:18px;white-space:normal;word-wrap:break-word}.e-bigger .e-grid.e-row-responsive .e-gridcontent td[data-cell],.e-bigger .e-grid.e-row-responsive .e-summarycontent td[data-cell],.e-bigger.e-grid.e-row-responsive .e-gridcontent td[data-cell],.e-bigger.e-grid.e-row-responsive .e-summarycontent td[data-cell]{padding-bottom:5px;padding-top:5px;padding-left:55%;position:relative}.e-bigger .e-grid.e-row-responsive .e-gridcontent .e-input,.e-bigger .e-grid.e-row-responsive .e-summarycontent .e-input,.e-bigger.e-grid.e-row-responsive .e-gridcontent .e-input,.e-bigger.e-grid.e-row-responsive .e-summarycontent .e-input{display:block}.e-bigger .e-grid.e-row-responsive .e-gridcontent td,.e-bigger .e-grid.e-row-responsive .e-summarycontent td,.e-bigger.e-grid.e-row-responsive .e-gridcontent td,.e-bigger.e-grid.e-row-responsive .e-summarycontent td{border:0}.e-bigger .e-grid.e-row-responsive .e-gridcontent .e-row,.e-bigger .e-grid.e-row-responsive .e-summarycontent .e-row,.e-bigger.e-grid.e-row-responsive .e-gridcontent .e-row,.e-bigger.e-grid.e-row-responsive .e-summarycontent .e-row{border-bottom:1px solid #e0e0e0}.e-bigger .e-grid.e-row-responsive .e-gridcontent .e-normaledit .e-rowcell,.e-bigger .e-grid.e-row-responsive .e-summarycontent .e-normaledit .e-rowcell,.e-bigger.e-grid.e-row-responsive .e-gridcontent .e-normaledit .e-rowcell,.e-bigger.e-grid.e-row-responsive .e-summarycontent .e-normaledit .e-rowcell{height:auto;padding-left:1%;padding-right:1%}.e-bigger .e-grid.e-row-responsive .e-gridcontent td.e-rowcell,.e-bigger .e-grid.e-row-responsive .e-summarycontent td.e-rowcell,.e-bigger.e-grid.e-row-responsive .e-gridcontent td.e-rowcell,.e-bigger.e-grid.e-row-responsive .e-summarycontent td.e-rowcell{border-bottom:0;border-bottom-color:#e0e0e0;height:auto}.e-bigger .e-grid.e-row-responsive .e-gridcontent .e-emptyrow td.e-lastrowcell,.e-bigger .e-grid.e-row-responsive .e-summarycontent .e-emptyrow td.e-lastrowcell,.e-bigger.e-grid.e-row-responsive .e-gridcontent .e-emptyrow td.e-lastrowcell,.e-bigger.e-grid.e-row-responsive .e-summarycontent .e-emptyrow td.e-lastrowcell{border-bottom:0}.e-bigger .e-grid.e-row-responsive .e-gridcontent .e-emptyrow.e-show-added-row td.e-lastrowcell,.e-bigger .e-grid.e-row-responsive .e-summarycontent .e-emptyrow.e-show-added-row td.e-lastrowcell,.e-bigger.e-grid.e-row-responsive .e-gridcontent .e-emptyrow.e-show-added-row td.e-lastrowcell,.e-bigger.e-grid.e-row-responsive .e-summarycontent .e-emptyrow.e-show-added-row td.e-lastrowcell{border-bottom:1px}.e-bigger .e-grid.e-row-responsive .e-gridcontent .e-normaledit :not(.e-responsive-editcell).e-rowcell,.e-bigger .e-grid.e-row-responsive .e-summarycontent .e-normaledit :not(.e-responsive-editcell).e-rowcell,.e-bigger.e-grid.e-row-responsive .e-gridcontent .e-normaledit :not(.e-responsive-editcell).e-rowcell,.e-bigger.e-grid.e-row-responsive .e-summarycontent .e-normaledit :not(.e-responsive-editcell).e-rowcell{border-top-width:0}.e-bigger .e-grid.e-row-responsive .e-gridcontent .e-normaledit .e-rowcell:before,.e-bigger .e-grid.e-row-responsive .e-summarycontent .e-normaledit .e-rowcell:before,.e-bigger.e-grid.e-row-responsive .e-gridcontent .e-normaledit .e-rowcell:before,.e-bigger.e-grid.e-row-responsive .e-summarycontent .e-normaledit .e-rowcell:before{bottom:6px;position:static}.e-bigger .e-grid.e-row-responsive .e-table,.e-bigger.e-grid.e-row-responsive .e-table{display:block}.e-bigger .e-grid.e-row-responsive .e-table tbody,.e-bigger .e-grid.e-row-responsive .e-table tr,.e-bigger .e-grid.e-row-responsive .e-table td:not(.e-hide),.e-bigger .e-grid.e-row-responsive .e-table tfoot,.e-bigger.e-grid.e-row-responsive .e-table tbody,.e-bigger.e-grid.e-row-responsive .e-table tr,.e-bigger.e-grid.e-row-responsive .e-table td:not(.e-hide),.e-bigger.e-grid.e-row-responsive .e-table tfoot{display:block}.e-bigger .e-grid.e-row-responsive>.e-gridheader,.e-bigger.e-grid.e-row-responsive>.e-gridheader{display:none}.e-bigger .e-grid.e-row-responsive .e-gridfooter,.e-bigger.e-grid.e-row-responsive .e-gridfooter{padding-right:0}.e-bigger .e-grid.e-row-responsive.e-hidelines .e-gridcontent .e-rowcell:last-child,.e-bigger.e-grid.e-row-responsive.e-hidelines .e-gridcontent .e-rowcell:last-child,.e-bigger.e-grid.e-row-responsive.e-verticallines .e-gridcontent .e-rowcell:last-child,.e-bigger .e-grid.e-row-responsive.e-verticallines .e-gridcontent .e-rowcell:last-child{border:0}.e-bigger .e-responsive-dialog.e-customfilter .e-responsivecoldiv,.e-bigger.e-responsive-dialog.e-customfilter .e-responsivecoldiv{cursor:pointer}.e-bigger .e-responsive-dialog .e-btn.e-ripple,.e-bigger.e-responsive-dialog .e-btn.e-ripple{overflow:initial}.e-bigger .e-responsive-dialog .columnmenudiv .e-responsiveascendingdiv .e-resascending-icon,.e-bigger .e-responsive-dialog .columnmenudiv .e-responsivedescendingdiv .e-resdescending-icon,.e-bigger .e-responsive-dialog .columnmenudiv .e-responsivegroupdiv .e-resgroup-icon,.e-bigger .e-responsive-dialog .columnmenudiv .e-responsiveungroupdiv .e-resungroup-icon,.e-bigger .e-responsive-dialog .columnmenudiv .e-responsiveautofitalldiv .e-resautofitall-icon,.e-bigger .e-responsive-dialog .columnmenudiv .e-responsiveautofitdiv .e-resautofit-icon,.e-bigger .e-responsive-dialog .columnmenudiv .e-responsivecolumndiv .e-rescolumn-icon,.e-bigger .e-responsive-dialog .columnmenudiv .e-responsivecoldiv .e-ressort-icon,.e-bigger .e-responsive-dialog .columnmenudiv .e-responsivefilterdiv .e-resfilter-icon,.e-bigger.e-responsive-dialog .columnmenudiv .e-responsiveascendingdiv .e-resascending-icon,.e-bigger.e-responsive-dialog .columnmenudiv .e-responsivedescendingdiv .e-resdescending-icon,.e-bigger.e-responsive-dialog .columnmenudiv .e-responsivegroupdiv .e-resgroup-icon,.e-bigger.e-responsive-dialog .columnmenudiv .e-responsiveungroupdiv .e-resungroup-icon,.e-bigger.e-responsive-dialog .columnmenudiv .e-responsiveautofitalldiv .e-resautofitall-icon,.e-bigger.e-responsive-dialog .columnmenudiv .e-responsiveautofitdiv .e-resautofit-icon,.e-bigger.e-responsive-dialog .columnmenudiv .e-responsivecolumndiv .e-rescolumn-icon,.e-bigger.e-responsive-dialog .columnmenudiv .e-responsivecoldiv .e-ressort-icon,.e-bigger.e-responsive-dialog .columnmenudiv .e-responsivefilterdiv .e-resfilter-icon{margin-top:0;position:absolute}.e-bigger .e-responsive-dialog .columnmenudiv .e-responsivecoldiv .e-res-header-text.e-rescolumn-menu,.e-bigger.e-responsive-dialog .columnmenudiv .e-responsivecoldiv .e-res-header-text.e-rescolumn-menu{margin-left:33px!important}.e-bigger .e-responsive-dialog .e-mainfilterdiv .e-ccdlg.e-cc.e-control.e-dialog,.e-bigger.e-responsive-dialog .e-mainfilterdiv .e-ccdlg.e-cc.e-control.e-dialog{left:0!important;max-height:100%!important;width:100%!important}.e-bigger .e-responsive-dialog .e-mainfilterdiv .e-ccdlg li.e-cclist,.e-bigger.e-responsive-dialog .e-mainfilterdiv .e-ccdlg li.e-cclist{padding:13px 0 13px 6px}.e-bigger .e-responsive-dialog .e-mainfilterdiv .e-ccdlg .e-main-div.e-cc,.e-bigger.e-responsive-dialog .e-mainfilterdiv .e-ccdlg .e-main-div.e-cc{height:100%}.e-bigger .e-responsive-dialog .e-mainfilterdiv .e-ccdlg .e-cc-contentdiv,.e-bigger.e-responsive-dialog .e-mainfilterdiv .e-ccdlg .e-cc-contentdiv{height:90%!important;min-height:160px;overflow-y:auto!important}.e-bigger .e-responsive-dialog .e-mainfilterdiv .e-ccdlg .e-dlg-content,.e-bigger.e-responsive-dialog .e-mainfilterdiv .e-ccdlg .e-dlg-content{padding:8px 16px 8px 8px;overflow-y:hidden}.e-bigger .e-responsive-dialog .e-mainfilterdiv .e-ccdlg .e-ccul-ele,.e-bigger.e-responsive-dialog .e-mainfilterdiv .e-ccdlg .e-ccul-ele{margin:13px 0;padding:0}.e-bigger .e-responsive-dialog .e-mainfilterdiv .e-ccdlg .e-chk-hidden,.e-bigger.e-responsive-dialog .e-mainfilterdiv .e-ccdlg .e-chk-hidden{-moz-appearance:none;height:1px;opacity:0;width:1px}.e-bigger .e-responsive-dialog .e-mainfilterdiv .e-cc-contentdiv,.e-bigger.e-responsive-dialog .e-mainfilterdiv .e-cc-contentdiv{height:90%!important;min-height:160px;overflow-y:auto!important}.e-bigger .e-responsive-dialog .e-mainfilterdiv .e-cc-searchBox,.e-bigger.e-responsive-dialog .e-mainfilterdiv .e-cc-searchBox{padding-left:8px}.e-bigger .e-responsive-dialog .e-mainfilterdiv .e-cc-searchBox .e-ccsearch-icon:hover,.e-bigger .e-responsive-dialog .e-mainfilterdiv .e-cc-searchBox .e-cc-cancel:hover,.e-bigger.e-responsive-dialog .e-mainfilterdiv .e-cc-searchBox .e-ccsearch-icon:hover,.e-bigger.e-responsive-dialog .e-mainfilterdiv .e-cc-searchBox .e-cc-cancel:hover{background:none}.e-bigger .e-responsive-dialog .e-mainfilterdiv .e-ccsearch-icon,.e-bigger .e-responsive-dialog .e-mainfilterdiv .e-cc-cancel,.e-bigger .e-responsive-dialog .e-mainfilterdiv .e-search-icon,.e-bigger .e-responsive-dialog .e-mainfilterdiv .e-chkcancel-icon,.e-bigger.e-responsive-dialog .e-mainfilterdiv .e-ccsearch-icon,.e-bigger.e-responsive-dialog .e-mainfilterdiv .e-cc-cancel,.e-bigger.e-responsive-dialog .e-mainfilterdiv .e-search-icon,.e-bigger.e-responsive-dialog .e-mainfilterdiv .e-chkcancel-icon{font-size:20px;font-size:16px}.e-bigger .e-responsive-dialog .e-dlg-header-content,.e-bigger.e-responsive-dialog .e-dlg-header-content{background:#fff;border-bottom:1px solid;border-bottom-color:#e0e0e0;padding:16px;width:100%;border-radius:0}.e-bigger .e-responsive-dialog .e-dlg-header-content .e-btn,.e-bigger.e-responsive-dialog .e-dlg-header-content .e-btn{background:none;box-shadow:none;outline:none;position:initial}.e-bigger .e-responsive-dialog .e-dlg-header-content .e-btn.e-dlg-closeicon-btn,.e-bigger.e-responsive-dialog .e-dlg-header-content .e-btn.e-dlg-closeicon-btn{background-color:transparent}.e-bigger .e-responsive-dialog .e-dlg-header-content .e-btn .e-btn-icon,.e-bigger.e-responsive-dialog .e-dlg-header-content .e-btn .e-btn-icon{color:#000;font-size:14px;margin-top:0}.e-bigger .e-responsive-dialog .e-dlg-header-content .e-btn:hover .e-btn-icon,.e-bigger .e-responsive-dialog .e-dlg-header-content .e-btn:focus .e-btn-icon,.e-bigger.e-responsive-dialog .e-dlg-header-content .e-btn:hover .e-btn-icon,.e-bigger.e-responsive-dialog .e-dlg-header-content .e-btn:focus .e-btn-icon{color:#000}.e-bigger .e-responsive-dialog .e-dlg-header-content .e-btn.e-dlg-closeicon-btn,.e-bigger.e-responsive-dialog .e-dlg-header-content .e-btn.e-dlg-closeicon-btn{float:left;padding-left:0!important;padding-right:40px!important}.e-bigger .e-responsive-dialog .e-dlg-header-content .e-dlg-header,.e-bigger.e-responsive-dialog .e-dlg-header-content .e-dlg-header{width:auto}.e-bigger .e-responsive-dialog .e-dlg-header-content .e-dlg-header .e-res-custom-element,.e-bigger.e-responsive-dialog .e-dlg-header-content .e-dlg-header .e-res-custom-element{display:flex}.e-bigger .e-responsive-dialog .e-dlg-header-content .e-dlg-header .e-res-custom-element .e-dlg-custom-header,.e-bigger.e-responsive-dialog .e-dlg-header-content .e-dlg-header .e-res-custom-element .e-dlg-custom-header{padding-top:5px;width:100%;overflow:hidden;text-overflow:ellipsis;font-weight:500}.e-bigger .e-responsive-dialog .e-dlg-header-content .e-dlg-header .e-res-custom-element .e-res-filter-clear-btn,.e-bigger.e-responsive-dialog .e-dlg-header-content .e-dlg-header .e-res-custom-element .e-res-filter-clear-btn{color:#e3165b;margin-top:3px;padding:0}.e-bigger .e-responsive-dialog .e-dlg-header-content .e-dlg-header .e-res-custom-element .e-res-filter-clear-btn .e-icon-filter-clear,.e-bigger.e-responsive-dialog .e-dlg-header-content .e-dlg-header .e-res-custom-element .e-res-filter-clear-btn .e-icon-filter-clear{font-size:18px}.e-bigger .e-responsive-dialog .e-dlg-header-content .e-dlg-header .e-res-custom-element .e-res-sort-clear-btn,.e-bigger.e-responsive-dialog .e-dlg-header-content .e-dlg-header .e-res-custom-element .e-res-sort-clear-btn{color:#e3165b;font-size:15px;font-weight:500;padding-top:5px}.e-bigger .e-responsive-dialog .e-dlg-header-content .e-dlg-header .e-res-custom-element .e-res-apply-btn,.e-bigger.e-responsive-dialog .e-dlg-header-content .e-dlg-header .e-res-custom-element .e-res-apply-btn{font-size:15px;font-weight:500;padding:4px 0 0 20px}.e-bigger .e-responsive-dialog .e-dlg-header-content .e-dlg-header .e-res-custom-element .e-res-apply-btn:disabled,.e-bigger.e-responsive-dialog .e-dlg-header-content .e-dlg-header .e-res-custom-element .e-res-apply-btn:disabled{color:#0000001f}.e-bigger .e-responsive-dialog .e-dlg-header-content .e-dlg-header .e-res-custom-element .e-btn,.e-bigger.e-responsive-dialog .e-dlg-header-content .e-dlg-header .e-res-custom-element .e-btn{color:#e3165b;background:none;border:0}.e-bigger .e-responsive-dialog .e-dlg-header-content .e-res-back-btn,.e-bigger.e-responsive-dialog .e-dlg-header-content .e-res-back-btn{background:none;padding-left:0;box-shadow:none}.e-bigger .e-responsive-dialog.e-rtl .e-dlg-header-content .e-res-back-btn,.e-bigger.e-responsive-dialog.e-rtl .e-dlg-header-content .e-res-back-btn{padding-left:15px;padding-right:0}.e-bigger .e-responsive-dialog .e-dlg-content,.e-bigger.e-responsive-dialog .e-dlg-content{padding:0 16px 16px}.e-bigger .e-responsive-dialog .e-dlg-content .e-checkfltrnmdiv,.e-bigger .e-responsive-dialog .e-dlg-content .e-ccnmdiv,.e-bigger.e-responsive-dialog .e-dlg-content .e-checkfltrnmdiv,.e-bigger.e-responsive-dialog .e-dlg-content .e-ccnmdiv{text-align:center;padding-top:40px}.e-bigger .e-responsive-dialog .e-dlg-content .e-filtersetdiv,.e-bigger.e-responsive-dialog .e-dlg-content .e-filtersetdiv{float:right;margin-right:1%;margin-top:1%}.e-bigger .e-responsive-dialog .e-dlg-content .e-filtersetdiv .e-filterset,.e-bigger.e-responsive-dialog .e-dlg-content .e-filtersetdiv .e-filterset{color:#e3165b}.e-bigger .e-responsive-dialog .e-dlg-content .e-dialog,.e-bigger.e-responsive-dialog .e-dlg-content .e-dialog{box-shadow:none}.e-bigger .e-responsive-dialog .e-dlg-content .e-excelfilter,.e-bigger.e-responsive-dialog .e-dlg-content .e-excelfilter{border:transparent}.e-bigger .e-responsive-dialog .e-dlg-content .e-excelfilter .e-dlg-content,.e-bigger.e-responsive-dialog .e-dlg-content .e-excelfilter .e-dlg-content{background-color:#fff;padding:8px 16px 8px 8px}.e-bigger .e-responsive-dialog .e-dlg-content .e-excelfilter .e-checkboxlist>span,.e-bigger.e-responsive-dialog .e-dlg-content .e-excelfilter .e-checkboxlist>span{padding-left:9px}.e-bigger .e-responsive-dialog .e-dlg-content .e-ccdlg,.e-bigger.e-responsive-dialog .e-dlg-content .e-ccdlg,.e-bigger .e-responsive-dialog .e-dlg-content .e-xlflmenu,.e-bigger.e-responsive-dialog .e-dlg-content .e-xlflmenu{border:transparent}.e-bigger .e-responsive-dialog .e-dlg-content .e-xlflmenu .e-dlg-content,.e-bigger.e-responsive-dialog .e-dlg-content .e-xlflmenu .e-dlg-content{padding:16px}.e-bigger .e-responsive-dialog .e-dlg-content .e-ressortbutton-parent,.e-bigger.e-responsive-dialog .e-dlg-content .e-ressortbutton-parent{float:right;margin-top:-9px}.e-bigger .e-responsive-dialog .e-dlg-content .e-ressortbutton-parent .e-ressortbutton,.e-bigger.e-responsive-dialog .e-dlg-content .e-ressortbutton-parent .e-ressortbutton{background:none;width:120px}.e-bigger .e-responsive-dialog .e-dlg-content .e-responsivecoldiv,.e-bigger.e-responsive-dialog .e-dlg-content .e-responsivecoldiv{font-size:16px;margin-bottom:26px;margin-top:26px;width:100%}.e-bigger .e-responsive-dialog .e-dlg-content .e-mainfilterdiv .e-dialog,.e-bigger.e-responsive-dialog .e-dlg-content .e-mainfilterdiv .e-dialog{bottom:0;box-shadow:none;width:100%}.e-bigger .e-responsive-dialog .e-dlg-content .e-mainfilterdiv .e-dialog .e-contextmenu-wrapper ul,.e-bigger.e-responsive-dialog .e-dlg-content .e-mainfilterdiv .e-dialog .e-contextmenu-wrapper ul{background-color:#fff;max-width:100%}.e-bigger .e-responsive-dialog .e-dlg-content .e-mainfilterdiv .e-dialog .e-contextmenu-wrapper ul li,.e-bigger.e-responsive-dialog .e-dlg-content .e-mainfilterdiv .e-dialog .e-contextmenu-wrapper ul li{color:#000000de}.e-bigger .e-responsive-dialog .e-dlg-content .e-mainfilterdiv .e-dialog .e-contextmenu-wrapper ul .e-submenu.e-selected,.e-bigger.e-responsive-dialog .e-dlg-content .e-mainfilterdiv .e-dialog .e-contextmenu-wrapper ul .e-submenu.e-selected{background-color:#fff}.e-bigger .e-responsive-dialog .e-dlg-content .e-mainfilterdiv .e-dialog .e-contextmenu-wrapper ul .e-submenu,.e-bigger.e-responsive-dialog .e-dlg-content .e-mainfilterdiv .e-dialog .e-contextmenu-wrapper ul .e-submenu{padding:0}.e-bigger .e-responsive-dialog .e-dlg-content .e-mainfilterdiv .e-dialog .e-contextmenu-wrapper ul .e-submenu .e-menu-icon,.e-bigger.e-responsive-dialog .e-dlg-content .e-mainfilterdiv .e-dialog .e-contextmenu-wrapper ul .e-submenu .e-menu-icon{margin-right:4px;margin-left:15px}.e-bigger .e-responsive-dialog .e-dlg-content .e-mainfilterdiv .e-dialog .e-contextmenu-wrapper ul .e-submenu .e-caret,.e-bigger.e-responsive-dialog .e-dlg-content .e-mainfilterdiv .e-dialog .e-contextmenu-wrapper ul .e-submenu .e-caret{padding:0 8px 0 0}.e-bigger .e-responsive-dialog .e-dlg-content .e-mainfilterdiv .e-dialog .e-searchcontainer,.e-bigger.e-responsive-dialog .e-dlg-content .e-mainfilterdiv .e-dialog .e-searchcontainer{height:88%}.e-bigger .e-responsive-dialog .e-dlg-content .e-mainfilterdiv .e-dialog .e-searchcontainer .e-searchbox,.e-bigger.e-responsive-dialog .e-dlg-content .e-mainfilterdiv .e-dialog .e-searchcontainer .e-searchbox{padding-left:10px}.e-bigger .e-responsive-dialog .e-dlg-content .e-mainfilterdiv .e-dialog .e-searchcontainer .e-searchbox .e-search-icon:focus,.e-bigger .e-responsive-dialog .e-dlg-content .e-mainfilterdiv .e-dialog .e-searchcontainer .e-searchbox .e-search-icon:active,.e-bigger .e-responsive-dialog .e-dlg-content .e-mainfilterdiv .e-dialog .e-searchcontainer .e-searchbox .e-search-icon:hover,.e-bigger .e-responsive-dialog .e-dlg-content .e-mainfilterdiv .e-dialog .e-searchcontainer .e-searchbox .e-chkcancel-icon:focus,.e-bigger .e-responsive-dialog .e-dlg-content .e-mainfilterdiv .e-dialog .e-searchcontainer .e-searchbox .e-chkcancel-icon:active,.e-bigger .e-responsive-dialog .e-dlg-content .e-mainfilterdiv .e-dialog .e-searchcontainer .e-searchbox .e-chkcancel-icon:hover,.e-bigger.e-responsive-dialog .e-dlg-content .e-mainfilterdiv .e-dialog .e-searchcontainer .e-searchbox .e-search-icon:focus,.e-bigger.e-responsive-dialog .e-dlg-content .e-mainfilterdiv .e-dialog .e-searchcontainer .e-searchbox .e-search-icon:active,.e-bigger.e-responsive-dialog .e-dlg-content .e-mainfilterdiv .e-dialog .e-searchcontainer .e-searchbox .e-search-icon:hover,.e-bigger.e-responsive-dialog .e-dlg-content .e-mainfilterdiv .e-dialog .e-searchcontainer .e-searchbox .e-chkcancel-icon:focus,.e-bigger.e-responsive-dialog .e-dlg-content .e-mainfilterdiv .e-dialog .e-searchcontainer .e-searchbox .e-chkcancel-icon:active,.e-bigger.e-responsive-dialog .e-dlg-content .e-mainfilterdiv .e-dialog .e-searchcontainer .e-searchbox .e-chkcancel-icon:hover{background:none}.e-bigger .e-responsive-dialog .e-dlg-content .e-mainfilterdiv .e-dialog .e-searchcontainer .e-spinner,.e-bigger.e-responsive-dialog .e-dlg-content .e-mainfilterdiv .e-dialog .e-searchcontainer .e-spinner{height:100%}.e-bigger .e-responsive-dialog .e-dlg-content .e-mainfilterdiv .e-dialog .e-searchcontainer .e-spinner .e-chk-hidden,.e-bigger.e-responsive-dialog .e-dlg-content .e-mainfilterdiv .e-dialog .e-searchcontainer .e-spinner .e-chk-hidden{-moz-appearance:none;height:1px;opacity:0;width:1px}.e-bigger .e-responsive-dialog .e-dlg-content .e-mainfilterdiv .e-dialog .e-searchcontainer .e-spinner .e-checkboxlist,.e-bigger.e-responsive-dialog .e-dlg-content .e-mainfilterdiv .e-dialog .e-searchcontainer .e-spinner .e-checkboxlist{height:100%;min-height:160px;overflow-y:auto}.e-bigger .e-responsive-dialog .e-dlg-content .e-mainfilterdiv .e-dialog .e-searchcontainer .e-spinner .e-checkboxlist.e-checkbox-infinitescroll,.e-bigger.e-responsive-dialog .e-dlg-content .e-mainfilterdiv .e-dialog .e-searchcontainer .e-spinner .e-checkboxlist.e-checkbox-infinitescroll{border-top-style:solid;border-top-color:#0000001f;border-top-width:1px;margin-top:0;overflow-x:hidden}.e-bigger .e-responsive-dialog .e-dlg-content .e-mainfilterdiv .e-dialog .e-searchcontainer .e-spinner .e-checkboxlist .e-ftrchk,.e-bigger.e-responsive-dialog .e-dlg-content .e-mainfilterdiv .e-dialog .e-searchcontainer .e-spinner .e-checkboxlist .e-ftrchk{padding-bottom:13px;padding-top:13px}.e-bigger .e-responsive-dialog .e-dlg-content .e-mainfilterdiv .e-dialog .e-searchcontainer .e-ftrchk .e-chk-hidden,.e-bigger.e-responsive-dialog .e-dlg-content .e-mainfilterdiv .e-dialog .e-searchcontainer .e-ftrchk .e-chk-hidden{-moz-appearance:none;height:1px;opacity:0;width:1px}.e-bigger .e-responsive-dialog .e-dlg-content .e-mainfilterdiv .e-dialog .e-searchcontainer .e-ftrchk .e-mask.e-skeleton,.e-bigger.e-responsive-dialog .e-dlg-content .e-mainfilterdiv .e-dialog .e-searchcontainer .e-ftrchk .e-mask.e-skeleton{display:inline-block;height:10px;width:80%}.e-bigger .e-responsive-dialog .e-dlg-content .e-mainfilterdiv .e-dialog .e-searchcontainer .e-ftrchk .e-mask.e-mask-checkbox-filter-intent,.e-bigger.e-responsive-dialog .e-dlg-content .e-mainfilterdiv .e-dialog .e-searchcontainer .e-ftrchk .e-mask.e-mask-checkbox-filter-intent{width:13px}.e-bigger .e-responsive-dialog .e-dlg-content .e-mainfilterdiv .e-dialog .e-searchcontainer .e-ftrchk .e-mask.e-mask-checkbox-filter-span-intent,.e-bigger.e-responsive-dialog .e-dlg-content .e-mainfilterdiv .e-dialog .e-searchcontainer .e-ftrchk .e-mask.e-mask-checkbox-filter-span-intent{margin-left:8px}.e-bigger .e-responsive-dialog .e-dlg-content .e-checkboxfilter .e-dlg-content,.e-bigger.e-responsive-dialog .e-dlg-content .e-checkboxfilter .e-dlg-content{padding:8px}.e-bigger .e-responsive-dialog .e-dlg-content .e-checkboxfilter .e-dlg-content .e-searchcontainer,.e-bigger.e-responsive-dialog .e-dlg-content .e-checkboxfilter .e-dlg-content .e-searchcontainer{padding-left:8px;margin-right:7px}.e-bigger .e-responsive-dialog .e-dlg-content .e-checkboxfilter .e-dlg-content .e-searchcontainer .e-searchbox,.e-bigger.e-responsive-dialog .e-dlg-content .e-checkboxfilter .e-dlg-content .e-searchcontainer .e-searchbox{padding-left:0}.e-bigger .e-responsive-dialog .e-dlg-content .e-checkboxfilter .e-dlg-content .e-searchcontainer .e-ftrchk.e-infinitescroll,.e-bigger .e-responsive-dialog .e-dlg-content .e-checkboxfilter .e-dlg-content .e-searchcontainer .e-spinner .e-checkboxlist,.e-bigger.e-responsive-dialog .e-dlg-content .e-checkboxfilter .e-dlg-content .e-searchcontainer .e-ftrchk.e-infinitescroll,.e-bigger.e-responsive-dialog .e-dlg-content .e-checkboxfilter .e-dlg-content .e-searchcontainer .e-spinner .e-checkboxlist{margin-left:-7px}.e-bigger .e-responsive-dialog .e-res-contextmenu-wrapper .e-contextmenu,.e-bigger.e-responsive-dialog .e-res-contextmenu-wrapper .e-contextmenu{background-color:#fff;border:transparent;box-shadow:none;margin-top:23px;max-width:100%;min-width:100%;overflow-y:auto;padding:0 16px 16px}.e-bigger .e-responsive-dialog .e-res-contextmenu-wrapper .e-contextmenu .e-menu-item,.e-bigger.e-responsive-dialog .e-res-contextmenu-wrapper .e-contextmenu .e-menu-item{padding:0}.e-bigger .e-responsive-dialog .e-res-contextmenu-wrapper .e-contextmenu .e-menu-item.e-focused,.e-bigger.e-responsive-dialog .e-res-contextmenu-wrapper .e-contextmenu .e-menu-item.e-focused{background-color:transparent}.e-bigger .e-responsive-dialog .e-defaultcell.e-ralign,.e-bigger .e-responsive-dialog .e-editedrow .e-defaultcell.e-ralign,.e-bigger .e-responsive-dialog .e-insertedrow .e-defaultcell.e-ralign,.e-bigger .e-responsive-dialog .e-defaultcell.e-ralign:focus,.e-bigger .e-responsive-dialog .e-insertedrow .e-defaultcell.e-ralign:focus .e-bigger .e-responsive-dialog .e-editedrow .e-defaultcell.e-ralign:focus,.e-bigger.e-responsive-dialog .e-defaultcell.e-ralign,.e-bigger.e-responsive-dialog .e-editedrow .e-defaultcell.e-ralign,.e-bigger.e-responsive-dialog .e-insertedrow .e-defaultcell.e-ralign,.e-bigger.e-responsive-dialog .e-defaultcell.e-ralign:focus,.e-bigger .e-responsive-dialog .e-insertedrow .e-defaultcell.e-ralign:focus .e-bigger.e-responsive-dialog .e-editedrow .e-defaultcell.e-ralign:focus,.e-bigger.e-responsive-dialog .e-insertedrow .e-defaultcell.e-ralign:focus .e-bigger .e-responsive-dialog .e-editedrow .e-defaultcell.e-ralign:focus,.e-bigger.e-responsive-dialog .e-insertedrow .e-defaultcell.e-ralign:focus .e-bigger.e-responsive-dialog .e-editedrow .e-defaultcell.e-ralign:focus{padding-right:10px}.e-bigger .e-responsive-dialog.e-ressortdiv .e-dlg-header-content .e-dlg-header .e-res-custom-element .e-res-apply-btn,.e-bigger.e-responsive-dialog.e-ressortdiv .e-dlg-header-content .e-dlg-header .e-res-custom-element .e-res-apply-btn{padding-top:2px}.e-bigger .e-responsive-dialog.e-rtl .e-btn.e-dlg-closeicon-btn,.e-bigger.e-responsive-dialog.e-rtl .e-btn.e-dlg-closeicon-btn{float:right;padding-left:40px!important;padding-right:0!important}.e-bigger .e-responsive-dialog.e-rtl .e-res-apply-btn,.e-bigger.e-responsive-dialog.e-rtl .e-res-apply-btn{padding-left:0;padding-right:20px}.e-bigger .e-responsive-dialog.e-rtl .e-ressortbutton-parent,.e-bigger.e-responsive-dialog.e-rtl .e-ressortbutton-parent{float:left}.e-bigger .e-responsive-dialog.e-rtl .columnmenudiv .e-responsivecoldiv .e-res-header-text.e-rescolumn-menu,.e-bigger.e-responsive-dialog.e-rtl .columnmenudiv .e-responsivecoldiv .e-res-header-text.e-rescolumn-menu{margin-right:33px}@-moz-document url-prefix(){.e-bigger .e-grid.e-grid-min-height .e-rowcell,.e-bigger .e-grid.e-grid-min-height .e-rowcell:first-child,.e-bigger .e-grid.e-grid-min-height .e-rowcell:last-child{line-height:normal}}.e-signature.e-control{border:1px solid}.e-signature.e-control{background-color:#fff;border:1px solid;border-color:#e0e0e0}.e-float-input .e-clear-icon:before,.e-float-input.e-control-wrapper .e-clear-icon:before{content:"\e932";font-family:e-icons}.e-input-group .e-clear-icon:before,.e-input-group.e-control-wrapper .e-clear-icon:before{content:"\e932";font-family:e-icons}.e-filled.e-float-input .e-clear-icon:before,.e-filled.e-float-input.e-control-wrapper .e-clear-icon:before{content:"\e208";font-family:e-icons}.e-filled.e-input-group .e-clear-icon:before,.e-filled.e-input-group.e-control-wrapper .e-clear-icon:before{content:"\e208";font-family:e-icons}.e-outline.e-float-input .e-clear-icon:before,.e-outline.e-float-input.e-control-wrapper .e-clear-icon:before{content:"\e208";font-family:e-icons}.e-outline.e-input-group .e-clear-icon:before,.e-outline.e-input-group.e-control-wrapper .e-clear-icon:before{content:"\e208";font-family:e-icons}/*! input layout */.e-input-group,.e-input-group.e-control-wrapper{display:table;line-height:1.4;margin-bottom:4px}input.e-input,.e-input-group input.e-input,.e-input-group.e-control-wrapper input.e-input,textarea.e-input,.e-input-group textarea.e-input,.e-input-group.e-control-wrapper textarea.e-input{border:0 solid;border-width:0 0 1px 0;height:auto;line-height:inherit;margin:0 0 4px;outline:none;padding:4px 0;text-indent:0;width:100%}input.e-input,textarea.e-input,.e-input-group,.e-input-group.e-control-wrapper,.e-input-group.e-disabled,.e-input-group.e-control-wrapper.e-disabled{font-family:Roboto,Segoe UI,GeezaPro,"DejaVu Serif","sans-serif",-apple-system,BlinkMacSystemFont;font-size:13px;font-weight:400}.e-input-group input.e-input,.e-input-group.e-control-wrapper input.e-input,.e-input-group textarea.e-input,.e-input-group.e-control-wrapper textarea.e-input,.e-input-group.e-small .e-input,.e-input-group.e-small.e-control-wrapper .e-input,.e-small .e-input-group .e-input,.e-small .e-input-group.e-control-wrapper .e-input{font:inherit}input.e-input,.e-input-group input.e-input,.e-input-group input,.e-input-group.e-control-wrapper input.e-input,.e-input-group.e-control-wrapper input,.e-float-input input,.e-float-input.e-input-group input,.e-float-input.e-control-wrapper input,.e-float-input.e-control-wrapper.e-input-group input,input.e-input:focus,.e-input-group input.e-input:focus,.e-input-group input:focus,.e-input-group.e-control-wrapper input.e-input:focus,.e-input-group.e-control-wrapper input:focus,.e-float-input input:focus,.e-float-input.e-input-group input:focus,.e-float-input.e-control-wrapper input:focus,.e-float-input.e-control-wrapper.e-input-group input:focus,.e-input-group.e-input-focus input.e-input,.e-input-group.e-input-focus input,.e-input-group.e-control-wrapper.e-input-focus input.e-input,.e-input-group.e-control-wrapper.e-input-focus input,.e-float-input.e-input-focus input,.e-float-input.e-input-group.e-input-focus input,.e-float-input.e-control-wrapper.e-input-focus input,.e-float-input.e-control-wrapper.e-input-group.e-input-focus input{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}input.e-input,.e-input-group input.e-input,.e-input-group input,.e-input-group.e-control-wrapper input.e-input,.e-input-group.e-control-wrapper input,.e-float-input input,.e-float-input.e-input-group input,.e-float-input.e-control-wrapper input,.e-float-input.e-control-wrapper.e-input-group input,.e-input-group,.e-input-group.e-control-wrapper,.e-float-input,.e-float-input.e-control-wrapper,.e-input.e-corner,.e-input-group.e-corner.e-rtl input.e-input:only-child,.e-input-group.e-control-wrapper.e-corner.e-rtl input.e-input:only-child,.e-input-group.e-input-focus.e-corner,.e-input-group.e-control-wrapper.e-input-focus.e-corner,textarea.e-input,.e-input-group textarea.e-input,.e-input-group textarea,.e-input-group.e-control-wrapper textarea.e-input,.e-input-group.e-control-wrapper textarea,.e-float-input textarea,.e-float-input.e-input-group textarea,.e-float-input.e-control-wrapper textarea,.e-float-input.e-control-wrapper.e-input-group textarea{border-radius:0}.e-input:focus{border-width:0 0 2px 0;padding-bottom:4px}.e-input.e-small:focus{border-width:0 0 2px 0;padding-bottom:4px}.e-input:focus{padding-bottom:3px}.e-input.e-small:focus{padding-bottom:3px}.e-input-group input.e-input:focus,.e-input-group.e-control-wrapper input.e-input:focus,.e-input-group textarea.e-input:focus,.e-input-group.e-control-wrapper textarea.e-input:focus,.e-input-group.e-input-focus input.e-input,.e-input-group.e-control-wrapper.e-input-focus input.e-input{padding:4px 0}.e-input-group textarea.e-input:focus,.e-input-group.e-control-wrapper textarea.e-input:focus{padding:4px 0}.e-input-group .e-input-group-icon,.e-input-group.e-control-wrapper .e-input-group-icon{align-items:center;border:0 solid;border-width:0;box-sizing:content-box;cursor:pointer;flex-direction:column;font-size:12px;justify-content:center;line-height:1;min-height:18px;min-width:18px;padding:0;text-align:center}.e-input-group.e-float-icon-left>.e-input-group-icon,.e-float-input.e-input-group.e-float-icon-left>.e-input-group-icon,.e-input-group.e-control-wrapper.e-float-icon-left>.e-input-group-icon,.e-float-input.e-input-group.e-control-wrapper.e-float-icon-left>.e-input-group-icon{font-size:20px;margin:0;min-height:30px;min-width:30px;padding:0}.e-input-group.e-small.e-float-icon-left>.e-input-group-icon,.e-input-group.e-float-icon-left>.e-input-group-icon.e-small,.e-input-group.e-control-wrapper.e-small.e-float-icon-left>.e-input-group-icon,.e-input-group.e-control-wrapper.e-float-icon-left>.e-input-group-icon.e-small,.e-small .e-input-group.e-float-icon-left>.e-input-group-icon,.e-small .e-input-group.e-control-wrapper.e-float-icon-left>.e-input-group-icon,.e-float-input.e-input-group.e-small.e-float-icon-left>.e-input-group-icon,.e-float-input.e-input-group.e-float-icon-left>.e-input-group-icon.e-small,.e-small .e-float-input.e-input-group.e-float-icon-left>.e-input-group-icon,.e-float-input.e-control-wrapper.e-input-group.e-small.e-float-icon-left>.e-input-group-icon,.e-float-input.e-control-wrapper.e-input-group.e-float-icon-left>.e-input-group-icon.e-small,.e-small .e-float-input.e-control-wrapper.e-input-group.e-float-icon-left>.e-input-group-icon{font-size:20px;margin:0;min-height:28px;min-width:28px;padding:0}.e-input-group.e-float-icon-left:not(.e-disabled)>.e-input-group-icon:active,.e-input-group.e-control-wrapper.e-float-icon-left:not(.e-disabled)>.e-input-group-icon:active{background:transparent}.e-input-group.e-float-icon-left>.e-input-group-icon,.e-input-group.e-control-wrapper.e-float-icon-left>.e-input-group-icon{cursor:auto}.e-input[disabled],.e-input-group .e-input[disabled],.e-input-group.e-control-wrapper .e-input[disabled],.e-input-group.e-disabled,.e-input-group.e-disabled input,.e-input-group.e-disabled input.e-input,.e-input-group.e-disabled textarea,.e-input-group.e-disabled textarea.e-input,.e-input-group.e-control-wrapper.e-disabled,.e-input-group.e-control-wrapper.e-disabled input,.e-input-group.e-control-wrapper.e-disabled input.e-input,.e-input-group.e-control-wrapper.e-disabled textarea,.e-input-group.e-control-wrapper.e-disabled textarea.e-input,.e-float-input.e-disabled input,.e-float-input.e-disabled textarea,.e-float-input input[disabled],.e-float-input input.e-disabled,.e-float-input textarea[disabled],.e-float-input textarea.e-disabled,.e-float-input.e-control-wrapper.e-disabled input,.e-float-input.e-control-wrapper.e-disabled textarea,.e-float-input.e-control-wrapper input[disabled],.e-float-input.e-control-wrapper input.e-disabled,.e-float-input.e-control-wrapper textarea[disabled],.e-float-input.e-control-wrapper textarea.e-disabled,.e-input-group.e-disabled span,.e-input-group.e-control-wrapper.e-disabled span,.e-input-group.e-disabled input.e-input:not(:valid):first-child~.e-clear-icon,.e-input-group.e-control-wrapper.e-disabled input.e-input:not(:valid):first-child~.e-clear-icon,.e-float-input.e-disabled input:not(:valid):first-child~.e-clear-icon,.e-float-input.e-input-group.e-disabled input:not(:valid):first-child~.e-clear-icon,.e-float-input.e-input-group.e-control-wrapper.e-disabled input:not(:valid):first-child~.e-clear-icon,.e-float-input.e-control-wrapper.e-disabled input:not(:valid):first-child~.e-clear-icon,.e-input-group.e-disabled .e-clear-icon.e-clear-icon-hide,.e-input-group.e-control-wrapper.e-disabled .e-clear-icon.e-clear-icon-hide{cursor:not-allowed}.e-input[disabled],.e-input-group.e-disabled,.e-input-group.e-control-wrapper.e-disabled,.e-float-input.e-disabled,.e-float-input input[disabled],.e-float-input input.e-disabled,.e-float-input.e-disabled input,.e-float-input.e-control-wrapper.e-disabled,.e-float-input.e-control-wrapper input[disabled],.e-float-input.e-control-wrapper input.e-disabled,.e-float-input.e-control-wrapper.e-disabled input,.e-float-input textarea[disabled],.e-float-input textarea.e-disabled,.e-float-input.e-disabled textarea,.e-float-input.e-control-wrapper textarea[disabled],.e-float-input.e-control-wrapper textarea.e-disabled,.e-float-input.e-control-wrapper.e-disabled textarea{filter:alpha(opacity=100);opacity:1}.e-input.e-rtl,.e-input-group.e-rtl,.e-input-group.e-control-wrapper.e-rtl,.e-float-input.e-rtl,.e-float-input.e-control-wrapper.e-rtl{direction:rtl}.e-input-group,.e-input-group.e-control-wrapper,.e-float-custom-tag.e-input-group,.e-float-custom-tag.e-input-group.e-control-wrapper,.e-input-custom-tag,.e-input-custom-tag.e-input-group,.e-input-custom-tag.e-input-group.e-control-wrapper{display:inline-flex;vertical-align:middle}.e-float-input:not(.e-input-group),.e-float-input.e-control-wrapper:not(.e-input-group),.e-float-custom-tag,.e-float-custom-tag.e-control-wrapper{display:inline-block}.e-input-group .e-input-group-icon,.e-input-group.e-control-wrapper .e-input-group-icon{display:flex}.e-input-group .e-input-group-icon:first-child,.e-input-group.e-control-wrapper .e-input-group-icon:first-child{border-left-width:0}.e-input-group .e-input-group-icon,.e-input-group.e-control-wrapper .e-input-group-icon{white-space:nowrap}.e-input-group .e-input-group-icon:not(:last-child),.e-input-group.e-control-wrapper .e-input-group-icon:not(:last-child){border-right-width:0}.e-input+.e-input-group-icon,.e-input-group .e-input+.e-input-group-icon,.e-input-group.e-control-wrapper .e-input+.e-input-group-icon{border-left-width:0}.e-input-group.e-corner .e-input:first-child,.e-input-group.e-corner .e-input-group-icon:first-child,.e-input-group.e-control-wrapper.e-corner .e-input:first-child,.e-input-group.e-control-wrapper.e-corner .e-input-group-icon:first-child{border-bottom-left-radius:0;border-top-left-radius:0}.e-input-group.e-corner .e-input:last-child,.e-input-group.e-corner .e-input-group-icon:last-child,.e-input-group.e-control-wrapper.e-corner .e-input:last-child,.e-input-group.e-control-wrapper.e-corner .e-input-group-icon:last-child{border-bottom-right-radius:0;border-top-right-radius:0}.e-input-group.e-rtl .e-input-group-icon:first-child,.e-input-group.e-control-wrapper.e-rtl .e-input-group-icon:first-child{border-left-width:0;border-right-width:0}.e-input-group.e-rtl .e-input-group-icon:last-child,.e-input-group.e-control-wrapper.e-rtl .e-input-group-icon:last-child{border-left-width:0;border-right-width:0}.e-input-group.e-rtl .e-input-group-icon:not(:last-child),.e-input-group.e-control-wrapper.e-rtl .e-input-group-icon:not(:last-child){border-left-width:0}.e-input-group.e-rtl .e-input-group-icon+.e-input,.e-input-group.e-control-wrapper.e-rtl .e-input-group-icon+.e-input{border-right-width:0}input.e-input.e-small,textarea.e-input.e-small,.e-small input.e-input,.e-small textarea.e-input,.e-input-group.e-small,.e-small .e-input-group,.e-input-group.e-control-wrapper.e-small,.e-small .e-input-group.e-control-wrapper,.e-input-group.e-small.e-disabled,.e-small .e-input-group.e-disabled,.e-input-group.e-control-wrapper.e-small.e-disabled,.e-small .e-input-group.e-control-wrapper.e-disabled{font-size:12px}.e-input.e-small,.e-input-group.e-small .e-input,.e-input-group.e-control-wrapper.e-small .e-input{line-height:inherit;padding:4px 0}.e-input-group.e-small .e-input:focus,.e-input-group.e-control-wrapper.e-small .e-input:focus,.e-input-group.e-small.e-input-focus .e-input,.e-input-group.e-control-wrapper.e-small.e-input-focus .e-input{padding:4px 0}.e-input-group.e-small .e-input-group-icon,.e-input-group.e-control-wrapper.e-small .e-input-group-icon,.e-small .e-input-group .e-input-group-icon,.e-small .e-input-group.e-control-wrapper .e-input-group-icon{font-size:12px;min-height:16px;min-width:16px;padding:0}label.e-float-text,.e-float-input label.e-float-text,.e-float-input.e-control-wrapper label.e-float-text,.e-float-input:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-float-input.e-control-wrapper:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom{font-size:13px;font-style:normal;font-weight:400;left:0;overflow:hidden;padding-left:0;pointer-events:none;position:absolute;text-overflow:ellipsis;top:-11px;transform:translate3d(0,16px,0) scale(1);transform-origin:left top;transition:.25s cubic-bezier(.25,.8,.25,1);-webkit-user-select:none;user-select:none;white-space:nowrap;width:100%}label.e-float-text,.e-float-input label.e-float-text,.e-float-input.e-control-wrapper label.e-float-text,.e-float-input:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-float-input.e-control-wrapper:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom{top:-11px}label.e-float-text,.e-float-input label.e-float-text,.e-float-input.e-control-wrapper label.e-float-text,.e-float-input:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-float-input.e-small:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small .e-float-input:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-float-input.e-control-wrapper:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-float-input.e-control-wrapper.e-small:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small .e-float-input.e-control-wrapper:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom{content:"";font-style:normal}.e-float-input.e-small label.e-float-text,.e-float-input.e-small:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small .e-float-input:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-float-input.e-control-wrapper.e-small label.e-float-text,.e-float-input.e-control-wrapper.e-small:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small .e-float-input.e-control-wrapper:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom{font-size:12px;top:-11px}.e-float-input .e-input-in-wrap label.e-float-text,.e-float-input:not(.e-input-focus) .e-input-in-wrap input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-float-input.e-control-wrapper .e-input-in-wrap label.e-float-text,.e-float-input.e-control-wrapper:not(.e-input-focus) .e-input-in-wrap input:not(:focus):valid~label.e-float-text.e-label-bottom{top:-11px}.e-float-input input:focus~label.e-float-text,.e-float-input input:valid~label.e-float-text,.e-float-input input~label.e-label-top.e-float-text,.e-float-input input[readonly]~label.e-label-top.e-float-text,.e-float-input input[disabled]~label.e-label-top.e-float-text,.e-float-input input label.e-float-text.e-label-top,.e-float-input.e-control-wrapper input:focus~label.e-float-text,.e-float-input.e-control-wrapper input:valid~label.e-float-text,.e-float-input.e-control-wrapper input~label.e-label-top.e-float-text,.e-float-input.e-control-wrapper input[readonly]~label.e-label-top.e-float-text,.e-float-input.e-control-wrapper input[disabled]~label.e-label-top.e-float-text,.e-float-input.e-control-wrapper input label.e-float-text.e-label-top,.e-float-input.e-control-wrapper.e-input-focus input~label.e-float-text,.e-float-input.e-input-focus input~label.e-float-text{font-size:13px;top:-9px;transform:translate3d(0,-6px,0) scale(.92)}.e-float-input.e-small input:focus~label.e-float-text,.e-float-input.e-small input:valid~label.e-float-text,.e-float-input.e-small input~label.e-label-top.e-float-text,.e-float-input.e-small input[readonly]~label.e-label-top.e-float-text,.e-float-input.e-small input[disabled]~label.e-label-top.e-float-text,.e-float-input.e-small input label.e-float-text.e-label-top,.e-small .e-float-input input:focus~label.e-float-text,.e-small .e-float-input input:valid~label.e-float-text,.e-small .e-float-input input~label.e-label-top.e-float-text,.e-small .e-float-input input[readonly]~label.e-label-top.e-float-text,.e-small .e-float-input input[disabled]~label.e-label-top.e-float-text,.e-small .e-float-input input label.e-float-text.e-label-top,.e-float-input.e-control-wrapper.e-small input:focus~label.e-float-text,.e-float-input.e-control-wrapper.e-small input:valid~label.e-float-text,.e-float-input.e-control-wrapper.e-small input~label.e-label-top.e-float-text,.e-float-input.e-control-wrapper.e-small input[readonly]~label.e-label-top.e-float-text,.e-float-input.e-control-wrapper.e-small input[disabled]~label.e-label-top.e-float-text,.e-float-input.e-control-wrapper.e-small input label.e-float-text.e-label-top,.e-small .e-float-input.e-control-wrapper input:focus~label.e-float-text,.e-small .e-float-input.e-control-wrapper input:valid~label.e-float-text,.e-small .e-float-input.e-control-wrapper input~label.e-label-top.e-float-text,.e-small .e-float-input.e-control-wrapper input[readonly]~label.e-label-top.e-float-text,.e-small .e-float-input.e-control-wrapper input[disabled]~label.e-label-top.e-float-text,.e-small .e-float-input.e-control-wrapper input label.e-float-text.e-label-top{font-size:13px;top:-9px;transform:translate3d(0,-6px,0) scale(.92)}.e-float-input .e-input-in-wrap input:focus~label.e-float-text,.e-float-input .e-input-in-wrap input:valid~label.e-float-text,.e-float-input .e-input-in-wrap input~label.e-label-top.e-float-text,.e-float-input .e-input-in-wrap input[readonly]~label.e-label-top.e-float-text,.e-float-input .e-input-in-wrap input[disabled]~label.e-label-top.e-float-text,.e-float-input .e-input-in-wrap input label.e-float-text.e-label-top,.e-float-input.e-control-wrapper .e-input-in-wrap input:focus~label.e-float-text,.e-float-input.e-control-wrapper .e-input-in-wrap input:valid~label.e-float-text,.e-float-input.e-control-wrapper .e-input-in-wrap input~label.e-label-top.e-float-text,.e-float-input.e-control-wrapper .e-input-in-wrap input[readonly]~label.e-label-top.e-float-text,.e-float-input.e-control-wrapper .e-input-in-wrap input[disabled]~label.e-label-top.e-float-text,.e-float-input.e-control-wrapper .e-input-in-wrap input label.e-float-text.e-label-top{top:-9px}.e-float-input.e-small input:focus~label.e-float-text,.e-float-input.e-small input:valid~label.e-float-text,.e-float-input.e-small input~label.e-label-top.e-float-text,.e-small .e-float-input input~label.e-label-top.e-float-text,.e-float-input.e-small input[readonly]~label.e-label-top.e-float-text,.e-float-input.e-small input[disabled]~label.e-label-top.e-float-text,.e-float-input.e-control-wrapper.e-small input:focus~label.e-float-text,.e-float-input.e-control-wrapper.e-small input:valid~label.e-float-text,.e-float-input.e-control-wrapper.e-small input~label.e-label-top.e-float-text,.e-small .e-float-input.e-control-wrapper input~label.e-label-top.e-float-text,.e-float-input.e-control-wrapper.e-small input[readonly]~label.e-label-top.e-float-text,.e-float-input.e-control-wrapper.e-small input[disabled]~label.e-label-top.e-float-text,.e-float-input.e-small.e-input-focus input-group-animation~label.e-float-text,.e-float-input.e-control-wrapper.e-small.e-input-focus input~label.e-float-text{font-size:12px;top:-8px}.e-float-input.e-small .e-input-in-wrap input:focus~label.e-float-text,.e-float-input.e-small .e-input-in-wrap input:valid~label.e-float-text,.e-float-input.e-small .e-input-in-wrap input~label.e-label-top.e-float-text,.e-small .e-float-input .e-input-in-wrap input~label.e-label-top.e-float-text,.e-float-input.e-small .e-input-in-wrap input[readonly]~label.e-label-top.e-float-text,.e-float-input.e-small .e-input-in-wrap input[disabled]~label.e-label-top.e-float-text,.e-float-input.e-control-wrapper.e-small .e-input-in-wrap input:focus~label.e-float-text,.e-float-input.e-control-wrapper.e-small .e-input-in-wrap input:valid~label.e-float-text,.e-float-input.e-control-wrapper.e-small .e-input-in-wrap input~label.e-label-top.e-float-text,.e-small .e-float-input.e-control-wrapper .e-input-in-wrap input~label.e-label-top.e-float-text,.e-float-input.e-control-wrapper.e-small .e-input-in-wrap input[readonly]~label.e-label-top.e-float-text,.e-float-input.e-control-wrapper.e-small .e-input-in-wrap input[disabled]~label.e-label-top.e-float-text{top:-7px}.e-float-input,.e-float-input.e-control-wrapper{line-height:1.4;margin-bottom:4px;margin-top:16px;padding-top:0;position:relative;width:100%}.e-float-input.e-small,.e-float-input.e-control-wrapper.e-small,.e-small .e-float-input.e-control-wrapper{line-height:1.35;margin-bottom:4px;margin-top:16px;padding-top:0}.e-input-group.e-small,.e-input-group.e-control-wrapper.e-small,.e-small .e-input-group,.e-small .e-input-group.e-control-wrapper{line-height:normal}.e-float-input.e-no-float-label,.e-float-input.e-small.e-no-float-label,.e-small .e-float-input.e-no-float-label,.e-float-input.e-control-wrapper.e-no-float-label,.e-float-input.e-control-wrapper.e-small.e-no-float-label,.e-small .e-float-input.e-control-wrapper.e-no-float-label{margin-top:0}.e-float-input,.e-float-input.e-control-wrapper,.e-float-input.e-disabled,.e-float-input.e-control-wrapper.e-disabled,.e-float-input.e-input-group.e-disabled,.e-float-input.e-input-group.e-control-wrapper.e-disabled{font-family:Roboto,Segoe UI,GeezaPro,"DejaVu Serif","sans-serif",-apple-system,BlinkMacSystemFont;font-size:13px;font-weight:400}.e-float-input input,.e-float-input textarea,.e-float-input.e-control-wrapper input,.e-float-input.e-control-wrapper textarea{border:0 solid;border-width:0 0 1px 0;display:block;font:inherit;width:100%}.e-float-input input,.e-float-input.e-control-wrapper input{min-width:0;padding:4px 0}.e-float-input input,.e-input-group input,.e-float-input.e-control-wrapper input,.e-input-group.e-control-wrapper input,.e-float-input textarea,.e-input-group textarea,.e-float-input.e-control-wrapper textarea,.e-input-group.e-control-wrapper textarea{text-indent:0}.e-float-input.e-small.e-disabled,.e-small .e-float-input.e-disabled,.e-float-input.e-control-wrapper.e-small.e-disabled,.e-small .e-float-input.e-control-wrapper.e-disabled,.e-float-input.e-input-group.e-small.e-disabled,.e-small .e-float-input.e-input-group.e-disabled,.e-float-input.e-input-group.e-control-wrapper.e-small.e-disabled,.e-small .e-float-input.e-input-group.e-control-wrapper.e-disabled,.e-float-input.e-small,.e-small .e-float-input,.e-float-input.e-control-wrapper.e-small,.e-small .e-float-input.e-control-wrapper{font-size:12px}.e-float-input.e-small input,.e-float-input.e-control-wrapper.e-small input{font:inherit;line-height:inherit;padding:4px 0}.e-float-input input:focus,.e-float-input.e-control-wrapper input:focus,.e-float-input textarea:focus,.e-float-input.e-control-wrapper textarea:focus,.e-float-input.e-input-focus input,.e-float-input.e-control-wrapper.e-input-focus input,.e-input-group.e-control-container.valid.modified,.e-input-group.e-control-container.invalid,.e-float-input.e-control-container.valid.modified,.e-float-input.e-control-container.invalid{outline:none}label.e-float-text,.e-float-input label.e-float-text,.e-float-input.e-control-wrapper label.e-float-text{font-family:inherit}.e-float-input input:valid~label.e-float-text,.e-float-input input:focus~label.e-float-text,.e-float-input input:valid~label.e-float-text.e-label-top,.e-float-input input~label.e-float-text.e-label-top,.e-float-input .e-input-in-wrap input:valid~label.e-float-text,.e-float-input .e-input-in-wrap input:valid~label.e-float-text.e-label-top,.e-float-input .e-input-in-wrap input~label.e-float-text.e-label-top,.e-float-input.e-control-wrapper input:valid~label.e-float-text,.e-float-input.e-control-wrapper input:focus~label.e-float-text,.e-float-input.e-control-wrapper input:valid~label.e-float-text.e-label-top,.e-float-input.e-control-wrapper input~label.e-float-text.e-label-top,.e-float-input.e-control-wrapper .e-input-in-wrap input:valid~label.e-float-text,.e-float-input.e-control-wrapper .e-input-in-wrap input:valid~label.e-float-text.e-label-top,.e-float-input.e-control-wrapper .e-input-in-wrap input~label.e-float-text.e-label-top,.e-float-input.e-input-focus input~label.e-float-text,.e-float-input.e-control-wrapper.e-input-focus input~label.e-float-text,.e-float-input textarea:valid~label.e-float-text,.e-float-input textarea:focus~label.e-float-text,.e-float-input textarea:valid~label.e-float-text.e-label-top,.e-float-input textarea~label.e-float-text.e-label-top,.e-float-input.e-control-wrapper textarea:valid~label.e-float-text,.e-float-input.e-control-wrapper textarea:focus~label.e-float-text,.e-float-input.e-control-wrapper textarea:valid~label.e-float-text.e-label-top,.e-float-input.e-control-wrapper textarea~label.e-float-text.e-label-top{-webkit-user-select:text;user-select:text}.e-float-input.e-outline.e-float-icon-left:not(.e-rtl) .e-input-in-wrap input~label.e-float-text.e-label-top{left:-34px;width:auto}.e-float-input.e-outline.e-float-icon-left.e-rtl .e-input-in-wrap input~label.e-float-text.e-label-top{right:-34px;width:auto}label.e-float-text,.e-float-input label.e-float-text,.e-float-input.e-control-wrapper label.e-float-text,.e-float-input:not(.e-error):not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-float-input.e-control-wrapper:not(.e-error):not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-float-input.e-small:not(.e-error):not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small .e-float-input:not(.e-error):not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-float-input.e-control-wrapper.e-small:not(.e-error):not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small .e-float-input.e-control-wrapper:not(.e-error):not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-float-input:not(.e-error) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-float-input.e-control-wrapper:not(.e-error) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-float-input.e-small:not(.e-error) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small .e-float-input:not(.e-error) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-float-input.e-control-wrapper.e-small:not(.e-error) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small .e-float-input.e-control-wrapper:not(.e-error) textarea:not(:focus):valid~label.e-float-text.e-label-bottom{font-weight:400}.e-float-input:not(.e-input-group) .e-float-line:before,.e-float-input:not(.e-input-group) .e-float-line:after,.e-float-input.e-control-wrapper:not(.e-input-group) .e-float-line:before,.e-float-input.e-control-wrapper:not(.e-input-group) .e-float-line:after{bottom:0;content:"";height:2px;position:absolute;transition:.2s ease;width:0}.e-float-input:not(.e-input-group) .e-float-line:before,.e-float-input.e-control-wrapper:not(.e-input-group) .e-float-line:before{left:50%}.e-float-input:not(.e-input-group) .e-float-line:after,.e-float-input.e-control-wrapper:not(.e-input-group) .e-float-line:after{right:50%}.e-float-input:not(.e-input-group) input:focus~.e-float-line:before,.e-float-input:not(.e-input-group) textarea:focus~.e-float-line:before,.e-float-input:not(.e-input-group) input:focus~.e-float-line:after,.e-float-input:not(.e-input-group) textarea:focus~.e-float-line:after,.e-float-input.e-control-wrapper:not(.e-input-group) input:focus~.e-float-line:before,.e-float-input.e-control-wrapper:not(.e-input-group) textarea:focus~.e-float-line:before,.e-float-input.e-control-wrapper:not(.e-input-group) input:focus~.e-float-line:after,.e-float-input.e-control-wrapper:not(.e-input-group) textarea:focus~.e-float-line:after,.e-float-input:not(.e-input-group).e-input-focus input~.e-float-line:before,.e-float-input:not(.e-input-group).e-input-focus input~.e-float-line:after,.e-float-input.e-control-wrapper:not(.e-input-group).e-input-focus input~.e-float-line:before,.e-float-input.e-control-wrapper:not(.e-input-group).e-input-focus input~.e-float-line:after{width:50%}.e-float-input .e-float-line,.e-float-input.e-control-wrapper .e-float-line{display:block;position:relative;width:100%}.e-float-input.e-rtl label.e-float-text,.e-float-input.e-control-wrapper.e-rtl label.e-float-text,.e-rtl .e-float-input label.e-float-text,.e-rtl .e-float-input.e-control-wrapper label.e-float-text,.e-rtl label.e-float-text,.e-rtl.e-float-input:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-rtl .e-float-input:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-rtl.e-float-input.e-control-wrapper:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-rtl .e-float-input.e-control-wrapper:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-rtl.e-float-input textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-rtl.e-float-input.e-control-wrapper textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-rtl .e-float-input textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-rtl .e-float-input.e-control-wrapper textarea:not(:focus):valid~label.e-float-text.e-label-bottom{right:0;transform-origin:right top}.e-float-input.e-rtl:not(.e-input-focus) label.e-float-text.e-label-bottom,.e-rtl .e-float-input:not(.e-input-focus) label.e-float-text.e-label-bottom,.e-float-input.e-rtl.e-control-wrapper:not(.e-input-focus) label.e-float-text.e-label-bottom,.e-rtl .e-float-input.e-control-wrapper:not(.e-input-focus) label.e-float-text.e-label-bottom,.e-float-input.e-rtl input:not(:focus):not(:valid) label.e-float-text,.e-float-input.e-rtl input:not(:focus):not(:valid) label.e-float-text.e-label-bottom,.e-rtl .e-float-input input:not(:focus):not(:valid) label.e-float-text,.e-rtl .e-float-input input:not(:focus):not(:valid) label.e-float-text.e-label-bottom,.e-float-input.e-control-wrapper.e-rtl input:not(:focus):not(:valid) label.e-float-text,.e-rtl .e-float-input.e-control-wrapper input:not(:focus):not(:valid) label.e-float-text,.e-float-input.e-rtl.e-control-wrapper input:not(:focus):not(:valid) label.e-float-text.e-label-bottom,.e-rtl .e-float-input.e-control-wrapper input:not(:focus):not(:valid) label.e-float-text.e-label-bottom,.e-float-input.e-rtl.e-small:not(.e-input-focus) label.e-float-text.e-label-bottom,.e-float-input.e-rtl.e-control-wrapper.e-small:not(.e-input-focus) label.e-float-text.e-label-bottom,.e-rtl .e-float-input.e-small:not(.e-input-focus) label.e-float-text.e-label-bottom,.e-rtl .e-float-input.e-control-wrapper.e-small:not(.e-input-focus) label.e-float-text.e-label-bottom,.e-small .e-float-input.e-rtl:not(.e-input-focus) label.e-float-text.e-label-bottom,.e-small .e-float-input.e-rtl.e-control-wrapper:not(.e-input-focus) label.e-float-text.e-label-bottom,.e-small.e-rtl .e-float-input:not(.e-input-focus) label.e-float-text.e-label-bottom,.e-small.e-rtl .e-float-input.e-control-wrapper:not(.e-input-focus) label.e-float-text.e-label-bottom,.e-float-input.e-small.e-rtl input:not(:focus):not(:valid) label.e-float-text,.e-float-input.e-rtl.e-small input:not(:focus):not(:valid) label.e-float-text.e-label-bottom,.e-rtl .e-float-input.e-small input:not(:focus):not(:valid) label.e-float-text,.e-rtl .e-float-input.e-small input:not(:focus):not(:valid) label.e-float-text.e-label-bottom,.e-small .e-float-input.e-rtl input:not(:focus):not(:valid) label.e-float-text,.e-small .e-float-input.e-rtl input:not(:focus):not(:valid) label.e-float-text.e-label-bottom,.e-small.e-rtl .e-float-input input:not(:focus):not(:valid) label.e-float-text,.e-small.e-rtl .e-float-input input:not(:focus):not(:valid) label.e-float-text.e-label-bottom,.e-float-input.e-control-wrapper.e-small.e-rtl input:not(:focus):not(:valid) label.e-float-text,.e-float-input.e-control-wrapper.e-rtl.e-small input:not(:focus):not(:valid) label.e-float-text.e-label-bottom,.e-rtl .e-float-input.e-control-wrapper.e-small input:not(:focus):not(:valid) label.e-float-text,.e-rtl .e-float-input.e-control-wrapper.e-small input:not(:focus):not(:valid) label.e-float-text.e-label-bottom,.e-small .e-float-input.e-control-wrapper.e-rtl input:not(:focus):not(:valid) label.e-float-text,.e-small .e-float-input.e-control-wrapper.e-rtl input:not(:focus):not(:valid) label.e-float-text.e-label-bottom,.e-small.e-rtl .e-float-input.e-control-wrapper input:not(:focus):not(:valid) label.e-float-text,.e-small.e-rtl .e-float-input.e-control-wrapper input:not(:focus):not(:valid) label.e-float-text.e-label-bottom{padding-right:0}.e-input-group.e-corner.e-rtl .e-input:first-child,.e-input-group.e-corner.e-rtl .e-input-group-icon:first-child,.e-input-group.e-control-wrapper.e-corner.e-rtl .e-input:first-child,.e-input-group.e-control-wrapper.e-corner.e-rtl .e-input-group-icon:first-child{border-radius:0}.e-input-group.e-corner.e-rtl .e-input:last-child,.e-input-group.e-corner.e-rtl .e-input-group-icon:last-child,.e-input-group.e-control-wrapper.e-corner.e-rtl .e-input:last-child,.e-input-group.e-control-wrapper.e-corner.e-rtl .e-input-group-icon:last-child{border-radius:0}.e-input-group.e-warning:before,.e-input-group.e-control-wrapper.e-warning:before{content:""}.e-float-input input[disabled],.e-float-input input.e-disabled,.e-float-input.e-control-wrapper input[disabled],.e-float-input.e-control-wrapper input.e-disabled{background:transparent;background-image:none;cursor:not-allowed}.e-input-group.e-rtl .e-input:not(:first-child):focus,.e-input-group.e-control-wrapper.e-rtl .e-input:not(:first-child):focus{border-right-width:0}.e-input-group input.e-input,.e-input-group.e-control-wrapper input.e-input{min-width:0;width:100%}.e-input-group input.e-input,.e-input-group textarea.e-input,.e-input-group input.e-input:hover:not(.e-success):not(.e-warning):not(.e-error):not([disabled]):not(:focus),.e-input-group textarea.e-input:hover:not(.e-success):not(.e-warning):not(.e-error):not([disabled]),.e-input-group.e-control-wrapper input.e-input,.e-input-group.e-control-wrapper textarea.e-input,.e-input-group.e-control-wrapper input.e-input:hover:not(.e-success):not(.e-warning):not(.e-error):not([disabled]):not(:focus),.e-input-group.e-control-wrapper textarea.e-input:hover:not(.e-success):not(.e-warning):not(.e-error):not([disabled]){border:0 solid;border-width:0}.e-input-group input.e-input,.e-input-group textarea.e-input,.e-input-group.e-control-wrapper input.e-input,.e-input-group.e-control-wrapper textarea.e-input,.e-float-input input.e-input,.e-float-input.e-control-wrapper input.e-input{margin-bottom:0}.e-input-group:not(.e-float-icon-left):not(.e-float-input):before,.e-input-group:not(.e-float-icon-left):not(.e-float-input):after,.e-input-group.e-float-icon-left:not(.e-float-input) .e-input-in-wrap:before,.e-input-group.e-float-icon-left:not(.e-float-input) .e-input-in-wrap:after,.e-input-group.e-control-wrapper:not(.e-float-icon-left):not(.e-float-input):before,.e-input-group.e-control-wrapper:not(.e-float-icon-left):not(.e-float-input):after,.e-input-group.e-control-wrapper.e-float-icon-left:not(.e-float-input) .e-input-in-wrap:before,.e-input-group.e-control-wrapper.e-float-icon-left:not(.e-float-input) .e-input-in-wrap:after,.e-float-input.e-input-group:not(.e-float-icon-left) .e-float-line:before,.e-float-input.e-input-group:not(.e-float-icon-left) .e-float-line:after,.e-float-input.e-input-group.e-float-icon-left .e-input-in-wrap .e-float-line:before,.e-float-input.e-input-group.e-float-icon-left .e-input-in-wrap .e-float-line:after,.e-float-input.e-control-wrapper.e-input-group:not(.e-float-icon-left) .e-float-line:before,.e-float-input.e-control-wrapper.e-input-group:not(.e-float-icon-left) .e-float-line:after,.e-float-input.e-control-wrapper.e-input-group.e-float-icon-left .e-input-in-wrap .e-float-line:before,.e-float-input.e-control-wrapper.e-input-group.e-float-icon-left .e-input-in-wrap .e-float-line:after,.e-filled.e-float-input.e-input-group.e-float-icon-left .e-float-line:before,.e-filled.e-float-input.e-input-group.e-float-icon-left .e-float-line:after,.e-filled.e-float-input.e-control-wrapper.e-input-group.e-float-icon-left .e-float-line:before,.e-filled.e-float-input.e-control-wrapper.e-input-group.e-float-icon-left .e-float-line:after{-moz-transition:.2s cubic-bezier(.4,0,.4,1);bottom:0;content:"";height:2px;position:absolute;transition:.2s cubic-bezier(.4,0,.4,1);width:0}.e-input-group:not(.e-float-icon-left):not(.e-float-input):before,.e-input-group.e-float-icon-left .e-input-in-wrap:not(.e-float-input):before,.e-input-group.e-control-wrapper:not(.e-float-icon-left):not(.e-float-input):before,.e-input-group.e-control-wrapper.e-float-icon-left .e-input-in-wrap:not(.e-float-input):before,.e-float-input.e-input-group:not(.e-float-icon-left) .e-float-line:before,.e-float-input.e-input-group.e-float-icon-left .e-input-in-wrap .e-float-line:before,.e-float-input.e-control-wrapper.e-input-group:not(.e-float-icon-left) .e-float-line:before,.e-float-input.e-control-wrapper.e-input-group.e-float-icon-left .e-input-in-wrap .e-float-line:before,.e-filled.e-input-group.e-float-icon-left:before,.e-filled.e-input-group.e-control-wrapper.e-float-icon-left:before,.e-filled.e-float-input.e-input-group.e-float-icon-left .e-float-line:before,.e-filled.e-float-input.e-control-wrapper.e-input-group.e-float-icon-left .e-float-line:before{left:50%}.e-input-group:not(.e-float-icon-left):not(.e-float-input).e-input-focus:before,.e-input-group:not(.e-float-icon-left):not(.e-float-input).e-input-focus:after,.e-input-group.e-float-icon-left:not(.e-float-input).e-input-focus .e-input-in-wrap:before,.e-input-group.e-float-icon-left:not(.e-float-input).e-input-focus .e-input-in-wrap:after,.e-input-group.e-control-wrapper:not(.e-float-icon-left):not(.e-float-input).e-input-focus:before,.e-input-group.e-control-wrapper:not(.e-float-icon-left):not(.e-float-input).e-input-focus:after,.e-input-group.e-control-wrapper.e-float-icon-left:not(.e-float-input).e-input-focus .e-input-in-wrap:before,.e-input-group.e-control-wrapper.e-float-icon-left:not(.e-float-input).e-input-focus .e-input-in-wrap:after,.e-float-input.e-input-group:not(.e-float-icon-left).e-input-focus .e-float-line:before,.e-float-input.e-input-group:not(.e-float-icon-left).e-input-focus .e-float-line:after,.e-float-input.e-input-group.e-float-icon-left.e-input-focus .e-input-in-wrap .e-float-line:before,.e-float-input.e-input-group.e-float-icon-left.e-input-focus .e-input-in-wrap .e-float-line:after,.e-float-input.e-control-wrapper.e-input-group:not(.e-float-icon-left).e-input-focus .e-float-line:before,.e-float-input.e-control-wrapper.e-input-group:not(.e-float-icon-left).e-input-focus .e-float-line:after,.e-float-input.e-control-wrapper.e-input-group.e-float-icon-left.e-input-focus .e-input-in-wrap .e-float-line:before,.e-float-input.e-control-wrapper.e-input-group.e-float-icon-left.e-input-focus .e-input-in-wrap .e-float-line:after,.e-filled.e-float-input.e-input-group.e-float-icon-left.e-input-focus .e-float-line:before,.e-filled.e-float-input.e-input-group.e-float-icon-left.e-input-focus .e-float-line:after,.e-filled.e-float-input.e-control-wrapper.e-input-group.e-float-icon-left.e-input-focus .e-float-line:before,.e-filled.e-float-input.e-control-wrapper.e-input-group.e-float-icon-left.e-input-focus .e-float-line:after{width:50%}.e-input-group:not(.e-float-icon-left):not(.e-float-input):after,.e-input-group.e-float-icon-left:not(.e-float-input) .e-input-in-wrap:after,.e-input-group.e-control-wrapper:not(.e-float-icon-left):not(.e-float-input):after,.e-input-group.e-control-wrapper.e-float-icon-left:not(.e-float-input) .e-input-in-wrap:after,.e-float-input.e-input-group:not(.e-float-icon-left) .e-float-line:after,.e-float-input.e-input-group.e-float-icon-left .e-input-in-wrap .e-float-line:after,.e-float-input.e-control-wrapper.e-input-group:not(.e-float-icon-left) .e-float-line:after,.e-float-input.e-control-wrapper.e-input-group.e-float-icon-left .e-input-in-wrap .e-float-line:after,.e-filled.e-input-group.e-float-icon-left:not(.e-float-input):after,.e-filled.e-input-group.e-control-wrapper.e-float-icon-left:not(.e-float-input):after,.e-filled.e-float-input.e-input-group.e-float-icon-left .e-float-line:after,.e-filled.e-float-input.e-control-wrapper.e-input-group.e-float-icon-left .e-float-line:after{right:50%}.e-input-group,.e-input-group.e-control-wrapper{position:relative;width:100%}.e-input-group .e-input-group-icon:hover,.e-input-group.e-rtl.e-corner .e-input-group-icon:hover,.e-input-group.e-control-wrapper .e-input-group-icon:hover,.e-input-group.e-control-wrapper.e-rtl.e-corner .e-input-group-icon:hover{border-radius:2px}.e-input.e-small,.e-input-group.e-small,.e-input-group.e-control-wrapper.e-small{margin-bottom:4px}.e-input-group .e-input-group-icon,.e-input-group.e-control-wrapper .e-input-group-icon{margin-bottom:4px;margin-right:4px;margin-top:4px}.e-float-input.e-input-group .e-input-group-icon,.e-float-input.e-control-wrapper.e-input-group .e-input-group-icon{margin-top:2px}.e-input-group.e-small .e-input-group-icon,.e-input-group.e-control-wrapper.e-small .e-input-group-icon,.e-small .e-input-group .e-input-group-icon,.e-small .e-input-group.e-control-wrapper .e-input-group-icon{margin-bottom:4px;margin-right:4px;margin-top:4px}.e-float-input.e-input-group.e-small .e-input-group-icon,.e-small .e-float-input.e-input-group .e-input-group-icon,.e-float-input.e-control-wrapper.e-input-group.e-small .e-input-group-icon,.e-small .e-float-input.e-control-wrapper.e-input-group .e-input-group-icon{margin-top:4px}.e-input-group .e-input-group-icon:last-child,.e-input-group.e-control-wrapper .e-input-group-icon:last-child,.e-input-group.e-small .e-input-group-icon:last-child,.e-input-group.e-control-wrapper.e-small .e-input-group-icon:last-child{margin-right:0}.e-input-group.e-input-focus:not(.e-float-icon-left):not(.e-success):not(.e-warning):not(.e-error),.e-input-group.e-control-wrapper.e-input-focus:not(.e-float-icon-left):not(.e-success):not(.e-warning):not(.e-error){border-style:solid;border-width:0 0 1px 0}.e-input-group.e-input-focus:not(.e-float-icon-left):not(.e-success):not(.e-warning):not(.e-error),.e-input-group.e-input-focus:not(.e-float-icon-left).e-success:not(.e-warning):not(.e-error),.e-input-group.e-input-focus:not(.e-float-icon-left).e-warning:not(.e-success):not(.e-error),.e-input-group.e-input-focus:not(.e-float-icon-left).e-error:not(.e-success):not(.e-warning),.e-float-input.e-input-group.e-input-focus:not(.e-float-icon-left):not(.e-success):not(.e-warning):not(.e-error),.e-float-input.e-input-group.e-input-focus:not(.e-float-icon-left).e-success:not(.e-warning):not(.e-error),.e-float-input.e-input-group.e-input-focus:not(.e-float-icon-left):not(.e-success).e-warning:not(.e-error),.e-float-input.e-input-group.e-input-focus:not(.e-float-icon-left):not(.e-success):not(.e-warning).e-error,.e-float-input.e-input-focus:not(.e-input-group):not(.e-float-icon-left):not(.e-success):not(.e-warning):not(.e-error) input,.e-float-input.e-input-focus:not(.e-input-group):not(.e-float-icon-left).e-success:not(.e-warning):not(.e-error) input,.e-float-input.e-input-focus:not(.e-input-group):not(.e-float-icon-left):not(.e-success).e-warning:not(.e-error) input,.e-float-input.e-input-focus:not(.e-input-group):not(.e-float-icon-left):not(.e-success):not(.e-warning).e-error input,.e-input-group.e-float-icon-left.e-input-focus:not(.e-success):not(.e-warning):not(.e-error) .e-input-in-wrap,.e-input-group.e-control-wrapper.e-input-focus:not(.e-float-icon-left):not(.e-success):not(.e-warning):not(.e-error),.e-input-group.e-control-wrapper.e-input-focus:not(.e-float-icon-left).e-success:not(.e-warning):not(.e-error),.e-input-group.e-control-wrapper.e-input-focus:not(.e-float-icon-left).e-warning:not(.e-success):not(.e-error),.e-input-group.e-control-wrapper.e-input-focus:not(.e-float-icon-left).e-error:not(.e-success):not(.e-warning),.e-float-input.e-control-wrapper.e-input-group.e-input-focus:not(.e-float-icon-left):not(.e-success):not(.e-warning):not(.e-error),.e-float-input.e-control-wrapper.e-input-group.e-input-focus:not(.e-float-icon-left).e-success:not(.e-warning):not(.e-error),.e-float-input.e-control-wrapper.e-input-group.e-input-focus:not(.e-float-icon-left):not(.e-success).e-warning:not(.e-error),.e-float-input.e-control-wrapper.e-input-group.e-input-focus:not(.e-float-icon-left):not(.e-success):not(.e-warning).e-error,.e-float-input.e-control-wrapper.e-input-focus:not(.e-input-group):not(.e-float-icon-left):not(.e-success):not(.e-warning):not(.e-error) input,.e-float-input.e-control-wrapper.e-input-focus:not(.e-input-group):not(.e-float-icon-left).e-success:not(.e-warning):not(.e-error) input,.e-float-input.e-control-wrapper.e-input-focus:not(.e-input-group):not(.e-float-icon-left):not(.e-success).e-warning:not(.e-error) input,.e-float-input.e-control-wrapper.e-input-focus:not(.e-input-group):not(.e-float-icon-left):not(.e-success):not(.e-warning).e-error input,.e-input-group.e-control-wrapper.e-float-icon-left.e-input-focus:not(.e-success):not(.e-warning):not(.e-error) .e-input-in-wrap{border-style:solid;border-width:0 0 1px 0}.e-input-group:not(.e-float-icon-left),.e-input-group.e-control-wrapper:not(.e-float-icon-left),.e-filled.e-input-group.e-float-icon-left,.e-filled.e-input-group.e-control-wrapper.e-float-icon-left{border-bottom:1px solid}.e-input-group:not(.e-float-icon-left),.e-input-group.e-success:not(.e-float-icon-left),.e-input-group.e-warning:not(.e-float-icon-left),.e-input-group.e-error:not(.e-float-icon-left),.e-input-group.e-control-wrapper:not(.e-float-icon-left),.e-input-group.e-control-wrapper.e-success:not(.e-float-icon-left),.e-input-group.e-control-wrapper.e-warning:not(.e-float-icon-left),.e-input-group.e-control-wrapper.e-error:not(.e-float-icon-left){border:1px solid;border-width:0 0 1px 0}.e-input-group.e-rtl.e-input-focus:not(.e-success):not(.e-warning):not(.e-error) .e-input:not(:first-child):focus,.e-input-group.e-control-wrapper.e-rtl.e-input-focus:not(.e-success):not(.e-warning):not(.e-error) .e-input:not(:first-child):focus{border-right-width:0}.e-input-group:not(.e-success):not(.e-warning):not(.e-error):not(.e-float-icon-left).e-disabled,.e-input-group.e-float-icon-left:not(.e-success):not(.e-warning):not(.e-error).e-disabled .e-input-in-wrap,.e-input-group.e-control-wrapper:not(.e-success):not(.e-warning):not(.e-error):not(.e-float-icon-left).e-disabled,.e-input-group.e-control-wrapper.e-float-icon-left:not(.e-success):not(.e-warning):not(.e-error).e-disabled .e-input-in-wrap{background:transparent;background-image:linear-gradient(90deg,rgba(0,0,0,.42) 0,rgba(0,0,0,.42) 33%,transparent 0);background-position:bottom -1px left 0;background-repeat:repeat-x;background-size:4px 1px;border-bottom-color:transparent;color:#0000006b}.e-input-group .e-input-group-icon,.e-input-group.e-control-wrapper .e-input-group-icon{position:relative}.e-input-group:not(.e-filled) .e-input-group-icon:after,.e-input-group.e-control-wrapper:not(.e-filled) .e-input-group-icon:after{background:#bdbdbd;border-radius:100%;content:"";display:block;height:50%;left:25%;opacity:.75;position:absolute;top:25%;transform:scale(0);width:50%}.e-input-group .e-input-group-icon.e-input-btn-ripple:after,.e-input-group.e-control-wrapper .e-input-group-icon.e-input-btn-ripple:after{animation:e-input-ripple .45s linear}input.e-input::-ms-clear,.e-float-input input::-ms-clear,.e-float-input.e-control-wrapper input::-ms-clear,.e-input:not(:valid):not(.e-control):first-child~.e-clear-icon,.e-input-group input:not(.e-control).e-input:not(:valid):first-child~.e-clear-icon,.e-input-group.e-control-wrapper input.e-input:not(:valid):not(.e-control):first-child~.e-clear-icon,.e-float-input input:not(:valid):not(.e-control):first-child~.e-clear-icon,.e-float-input.e-control-wrapper input:not(:valid):not(.e-control):first-child~.e-clear-icon,.e-float-input.e-input-group input:not(:valid):not(.e-control):first-child~.e-clear-icon,.e-float-input.e-input-group.e-control-wrapper input:not(:valid):not(.e-control):first-child~.e-clear-icon{display:none}.e-input-group .e-clear-icon.e-clear-icon-hide,.e-input-group.e-control-wrapper .e-clear-icon.e-clear-icon-hide,.e-float-input.e-control-wrapper.e-hidden,.e-input-group.e-control-wrapper.e-hidden{display:none}input.e-input[type=search]::-webkit-search-decoration,input.e-input[type=search]::-webkit-search-cancel-button,input.e-input[type=search]::-webkit-search-results-button,input.e-input[type=search]::-webkit-search-results-decoration,.e-float-input input[type=search]::-webkit-search-decoration,.e-float-input input[type=search]::-webkit-search-cancel-button,.e-float-input input[type=search]::-webkit-search-results-button,.e-float-input input[type=search]::-webkit-search-results-decoration,.e-float-input.e-control-wrapper input[type=search]::-webkit-search-decoration,.e-float-input.e-control-wrapper input[type=search]::-webkit-search-cancel-button,.e-float-input.e-control-wrapper input[type=search]::-webkit-search-results-button,.e-float-input.e-control-wrapper input[type=search]::-webkit-search-results-decoration{-webkit-appearance:none}.e-float-input.e-input-group .e-float-line,.e-float-input.e-input-group.e-control-wrapper .e-float-line,.e-float-input.e-control-wrapper.e-input-group .e-float-line,.e-float-input.e-control-wrapper.e-input-group.e-control-wrapper .e-float-line{bottom:-1px;position:absolute}.e-float-input.e-input-group input,.e-float-input.e-input-group textarea,.e-float-input.e-input-group.e-control-wrapper input,.e-float-input.e-input-group.e-control-wrapper textarea{border:0}.e-float-input.e-input-group .e-float-line,.e-float-input.e-input-group .e-float-text,.e-float-input.e-input-group.e-control-wrapper .e-float-line,.e-float-input.e-input-group.e-control-wrapper .e-float-text{right:0}input.e-input::-webkit-input-placeholder,input.e-input:-moz-placeholder,input.e-input:-ms-input-placeholder,input.e-input::-moz-placeholder,textarea.e-input::-webkit-input-placeholder,textarea.e-input:-moz-placeholder,textarea.e-input:-ms-input-placeholder,textarea.e-input::-moz-placeholder,textarea.e-input::-webkit-textarea-placeholder,textarea.e-input:-ms-textarea-placeholder{font-size:13px;font-style:normal}.e-small input.e-input::-webkit-input-placeholder,input.e-small.e-input::-webkit-input-placeholder,.e-small input.e-input:-moz-placeholder,input.e-small.e-input:-moz-placeholder,.e-small input.e-input:-ms-input-placeholder,input.e-small.e-input:-ms-input-placeholder,.e-small input.e-input::-moz-placeholder,input.e-small.e-input::-moz-placeholder,.e-small textarea.e-input::-webkit-input-placeholder,textarea.e-small.e-input::-webkit-input-placeholder,.e-small textarea.e-input:-moz-placeholder,textarea.e-small.e-input:-moz-placeholder,.e-small textarea.e-input:-ms-input-placeholder,textarea.e-small.e-input:-ms-input-placeholder,.e-small textarea.e-input::-moz-placeholder,textarea.e-small.e-input::-moz-placeholder,.e-small textarea.e-input::-webkit-textarea-placeholder,textarea.e-small.e-input::-webkit-textarea-placeholder{font-size:12px;font-style:normal}input.e-input:-moz-placeholder,textarea.e-input:-moz-placeholder,.e-input-group input.e-input:-moz-placeholder,.e-input-group textarea.e-input:-moz-placeholder,.e-input-group.e-control-wrapper input.e-input:-moz-placeholder,.e-input-group.e-control-wrapper textarea.e-input:-moz-placeholder,input.e-input::-moz-placeholder,textarea.e-input::-moz-placeholder,input.e-input::-webkit-input-placeholder,textarea.e-input::-webkit-input-placeholder{font-style:normal;-webkit-user-select:none;user-select:none}input.e-input:-ms-input-placeholder,textarea.e-input:-ms-input-placeholder{font-style:normal}input.e-input,.e-input-group input,.e-input-group.e-control-wrapper input,.e-input-group input.e-input,.e-input-group.e-control-wrapper input.e-input{box-sizing:content-box;content:""}.e-float-input:not(.e-input-group) input,.e-float-input.e-control-wrapper:not(.e-input-group) input{box-sizing:content-box;content:""}.e-control input.e-input,.e-control .e-input-group input,.e-control .e-input-group input.e-input,.e-control .e-input-group.e-control-wrapper input,.e-control .e-input-group.e-control-wrapper input.e-input,.e-control .e-float-input input,.e-control .e-float-input.e-control-wrapper input,.e-control.e-input-group input,.e-control.e-input-group input.e-input,.e-control.e-input-group.e-control-wrapper input,.e-control.e-input-group.e-control-wrapper input.e-input,.e-control.e-float-input input,.e-control.e-float-input.e-control-wrapper input{box-sizing:content-box}input.e-input.e-small,.e-input-group.e-small input,.e-input-group.e-small input.e-input,.e-small .e-input-group input,.e-small .e-input-group input.e-input,.e-input-group.e-control-wrapper.e-small input,.e-input-group.e-control-wrapper.e-small input.e-input,.e-small .e-input-group.e-control-wrapper input,.e-small .e-input-group.e-control-wrapper input.e-input,.e-float-input.e-small input,.e-float-input.e-small input.e-input,.e-small .e-float-input input,.e-small .e-float-input input.e-input,.e-float-input.e-control-wrapper.e-small input,.e-float-input.e-control-wrapper.e-small input.e-input,.e-small .e-float-input.e-control-wrapper input,.e-small .e-float-input.e-control-wrapper input.e-input{box-sizing:content-box;content:""}.e-float-input.e-small:not(.e-input-group) input,.e-float-input.e-small:not(.e-input-group) input.e-input,.e-small .e-float-input:not(.e-input-group) input,.e-small .e-float-input:not(.e-input-group) input.e-input .e-float-input.e-control-wrapper.e-small:not(.e-input-group) input,.e-float-input.e-control-wrapper.e-small:not(.e-input-group) input.e-input,.e-small .e-float-input.e-control-wrapper:not(.e-input-group) input,.e-small .e-float-input.e-control-wrapper:not(.e-input-group) input.e-input{box-sizing:content-box;content:""}textarea.e-input,.e-input-group textarea,.e-input-group.e-control-wrapper textarea,.e-float-input textarea,.e-float-input.e-control-wrapper textarea,textarea.e-input.e-small,.e-input-group.e-small textarea,.e-input-group.e-small textarea.e-input,.e-small .e-input-group textarea,.e-small .e-input-group textarea.e-input,.e-input-group.e-control-wrapper.e-small textarea,.e-input-group.e-control-wrapper.e-small textarea.e-input,.e-small .e-input-group.e-control-wrapper textarea,.e-small .e-input-group.e-control-wrapper textarea.e-input,.e-float-input.e-small textarea,.e-float-input.e-small textarea.e-input,.e-small .e-float-input textarea,.e-small .e-float-input textarea.e-input,.e-float-input.e-control-wrapper.e-small textarea,.e-float-input.e-control-wrapper.e-small textarea.e-input,.e-small .e-float-input.e-control-wrapper textarea,.e-small .e-float-input.e-control-wrapper textarea.e-input{box-sizing:content-box;content:""}input.e-input.e-small,.e-input-group input.e-input.e-small,.e-input-group.e-control-wrapper input.e-input.e-small,.e-input-group.e-small .e-input,.e-input-group.e-control-wrapper.e-small .e-input,.e-small input.e-input,.e-small .e-input-group .e-input,.e-small .e-input-group.e-control-wrapper .e-input,.e-float-input.e-small input,.e-float-input input.e-small,.e-small .e-float-input input,.e-float-input.e-control-wrapper.e-small input,.e-float-input.e-control-wrapper input.e-small,.e-small .e-float-input.e-control-wrapper input,textarea.e-input.e-small,.e-input-group textarea.e-input.e-small,.e-input-group.e-control-wrapper input.e-input-group textarea.e-input.e-small,.e-float-input.e-small textarea,.e-float-input textarea.e-small,.e-small .e-float-input textarea,.e-float-input.e-control-wrapper.e-small textarea,.e-float-input.e-control-wrapper textarea.e-small,.e-small .e-float-input.e-control-wrapper textarea{text-indent:0}input.e-input,.e-input-group input.e-input,.e-input-group input,.e-input-group.e-control-wrapper input.e-input,.e-input-group.e-control-wrapper input,.e-float-input input.e-input,.e-float-input input,.e-float-input.e-control-wrapper input.e-input,.e-float-input.e-control-wrapper input,.e-input-group input.e-input:focus,.e-input-group.e-control-wrapper input.e-input:focus,.e-float-input.e-control-wrapper input:focus,.e-float-input input:focus,.e-input-group.e-input-focus input.e-input,.e-input-group.e-control-wrapper.e-input-focus input.e-input,.e-float-input.e-control-wrapper.e-input-focus input,.e-float-input.e-input-focus input{padding-left:0;text-indent:0}textarea.e-input,.e-input-group textarea.e-input,.e-input-group textarea,.e-input-group.e-control-wrapper textarea.e-input,.e-input-group.e-control-wrapper textarea,.e-float-input textarea.e-input,.e-float-input textarea,.e-float-input.e-control-wrapper textarea.e-input,.e-float-input.e-control-wrapper textarea,.e-input-group textarea.e-input:focus,.e-input-group.e-control-wrapper textarea.e-input:focus,.e-float-input.e-control-wrapper textarea:focus,.e-float-input textarea:focus{padding-left:0;text-indent:0}input.e-input.e-rtl,.e-input-group.e-rtl input.e-input,.e-input-group.e-control-container.e-rtl input.e-control,.e-input-group.e-control-wrapper.e-rtl input.e-input,.e-float-input.e-rtl input,.e-float-input.e-control-wrapper.e-rtl input,.e-rtl .e-input-group input.e-input,.e-rtl .e-input-group.e-control-wrapper input.e-input,.e-rtl .e-float-input input,.e-rtl .e-float-input.e-control-wrapper input,.e-input-group.e-rtl input.e-input:focus,.e-input-group.e-control-wrapper.e-rtl input.e-input:focus,.e-float-input.e-rtl input:focus,.e-float-input.e-control-wrapper.e-rtl input:focus,.e-rtl .e-input-group input.e-input:focus,.e-rtl .e-input-group.e-control-wrapper input.e-input:focus,.e-rtl .e-float-input input:focus,.e-rtl .e-float-input.e-control-wrapper input:focus,.e-input-group.e-rtl.e-input-focus input.e-input,.e-input-group.e-control-wrapper.e-rtl.e-input-focus input.e-input,.e-rtl .e-input-group.e-input-focus input.e-input,.e-rtl .e-input-group.e-control-wrapper.e-input-focus input.e-input,.e-float-input.e-rtl.e-input-focus input,.e-float-input.e-control-wrapper.e-rtl.e-input-focus input,.e-rtl .e-float-input.e-input-focus input,.e-rtl .e-float-input.e-control-wrapper.e-input-focus input{padding-left:0;padding-right:0;text-indent:0}textarea.e-input.e-rtl,.e-input-group:not(.e-outline).e-rtl textarea.e-input,.e-input-group:not(.e-outline).e-control-wrapper.e-rtl textarea.e-input,.e-float-input:not(.e-outline).e-rtl textarea,.e-float-input:not(.e-outline).e-control-wrapper.e-rtl textarea,.e-rtl .e-input-group:not(.e-outline) textarea.e-input,.e-rtl .e-input-group:not(.e-outline).e-control-wrapper textarea.e-input,.e-rtl .e-float-input:not(.e-outline) textarea,.e-rtl .e-float-input:not(.e-outline).e-control-wrapper textarea,.e-input-group:not(.e-outline).e-rtl textarea.e-input:focus,.e-input-group:not(.e-outline).e-control-wrapper.e-rtl textarea.e-input:focus,.e-float-input:not(.e-outline).e-rtl textarea:focus,.e-float-input:not(.e-outline).e-control-wrapper.e-rtl textarea:focus,.e-rtl .e-input-group:not(.e-outline) textarea.e-input:focus,.e-rtl .e-input-group:not(.e-outline).e-control-wrapper textarea.e-input:focus,.e-rtl .e-float-input:not(.e-outline) textarea:focus,.e-rtl .e-float-input:not(.e-outline).e-control-wrapper textarea:focus{padding-right:0;text-indent:0}input.e-input.e-small,.e-small input.e-input,.e-input-group.e-small input.e-input,.e-input-group.e-control-wrapper.e-small input.e-input,.e-float-input.e-small input,.e-float-input.e-control-wrapper input.e-small,.e-input-group input.e-input.e-small,.e-input-group.e-control-wrapper input.e-input.e-small,.e-small .e-float-input input,.e-small .e-float-input.e-control-wrapper input,.e-small .e-input-group input.e-input,.e-small .e-input-group.e-control-wrapper input.e-input,.e-input-group.e-small input.e-input:focus,.e-input-group.e-control-wrapper.e-small input.e-input:focus,.e-float-input.e-small input:focus,.e-float-input.e-control-wrapper.e-small input:focus,.e-small .e-input-group.e-control-wrapper input.e-input:focus,.e-small .e-input-group input.e-input:focus,.e-small .e-float-input input:focus,.e-small .e-float-input.e-control-wrapper input:focus,.e-input-group.e-small.e-input-focus input.e-input,.e-input-group.e-control-wrapper.e-small.e-input-focus input.e-input,.e-small .e-input-group.e-control-wrapper.e-input-focus input.e-input,.e-small .e-input-group.e-input-focus input.e-input,.e-float-input.e-small.e-input-focus input,.e-float-input.e-control-wrapper.e-input-focus.e-small input,.e-small .e-float-input.e-input-focus input,.e-small .e-float-input.e-control-wrapper.e-input-focus input,textarea.e-input.e-small,.e-small textarea.e-input,.e-input-group.e-small textarea.e-input,.e-input-group.e-control-wrapper.e-small textarea.e-input,.e-float-input.e-control-wrapper.e-small textarea,.e-float-input.e-control-wrapper textarea.e-small,.e-float-input.e-small textarea,.e-float-input textarea.e-small,.e-input-group textarea.e-input.e-small,.e-input-group.e-control-wrapper textarea.e-input.e-small,.e-small .e-float-input.e-control-wrapper textarea,.e-small .e-float-input textarea,.e-small .e-input-group textarea.e-input,.e-small .e-input-group.e-control-wrapper textarea.e-input,.e-input-group.e-small textarea.e-input:focus,.e-input-group.e-control-wrapper.e-small textarea.e-input:focus,.e-float-input.e-small textarea:focus,.e-float-input.e-control-wrapper.e-small textarea:focus,.e-small .e-input-group textarea.e-input:focus,.e-small .e-input-group.e-control-wrapper textarea.e-input:focus,.e-small .e-float-input.e-control-wrapper textarea:focus,.e-small .e-float-input textarea:focus{padding-left:0;text-indent:0}.e-rtl input.e-input.e-small,input.e-input.e-small.e-rtl,.e-small.e-rtl input.e-input,.e-small input.e-input.e-rtl,.e-float-input.e-control-wrapper.e-small.e-rtl input,.e-float-input.e-small.e-rtl input,.e-input-group.e-small.e-rtl input.e-input,.e-input-group.e-control-wrapper.e-small.e-rtl input.e-input,.e-rtl .e-float-input.e-small input,.e-rtl .e-float-input.e-control-wrapper.e-small input,.e-rtl .e-input-group.e-small input.e-input,.e-rtl .e-input-group.e-control-wrapper.e-small input.e-input,.e-float-input.e-rtl input.e-small,.e-float-input.e-control-wrapper.e-rtl input.e-small,.e-input-group.e-rtl input.e-input.e-small,.e-input-group.e-control-wrapper.e-rtl input.e-input.e-small,.e-rtl .e-float-input input.e-small,.e-rtl .e-float-input.e-control-wrapper input.e-small,.e-rtl .e-input-group input.e-input.e-small,.e-rtl .e-input-group.e-control-wrapper input.e-input.e-small,.e-small .e-float-input.e-rtl input,.e-small .e-float-input.e-control-wrapper.e-rtl input,.e-small .e-input-group.e-rtl input.e-input,.e-small .e-input-group.e-control-wrapper.e-rtl input.e-input,.e-small.e-rtl .e-float-input.e-control-wrapper input,.e-small.e-rtl .e-float-input input,.e-small.e-rtl .e-input-group.e-control-wrapper input.e-input,.e-small.e-rtl .e-input-group input.e-input,.e-small.e-rtl .e-input-group.e-control-wrapper input.e-input:focus,.e-small.e-rtl .e-input-group input.e-input:focus,.e-small.e-rtl .e-float-input.e-control-wrapper input:focus,.e-small.e-rtl .e-float-input input:focus,.e-small .e-input-group.e-control-wrapper.e-rtl input.e-input:focus,.e-small .e-input-group.e-rtl input.e-input:focus,.e-small .e-float-input.e-control-wrapper.e-rtl input:focus,.e-small .e-float-input.e-rtl input:focus,.e-small.e-rtl .e-input-group.e-control-wrapper.e-input-focus input.e-input,.e-small.e-rtl .e-input-group.e-input-focus input.e-input,.e-small .e-input-group.e-control-wrapper.e-rtl.e-input-focus input.e-input,.e-small .e-input-group.e-rtl.e-input-focus input.e-input,.e-small.e-rtl .e-float-input.e-control-wrapper.e-input-focus input,.e-small.e-rtl .e-float-input.e-input-focus input,.e-small .e-float-input.e-control-wrapper.e-rtl.e-input-focus input,.e-small .e-float-input.e-rtl.e-input-focus input{padding-left:0;padding-right:0;text-indent:0}.e-rtl textarea.e-input.e-small,textarea.e-input.e-small.e-rtl,.e-small.e-rtl textarea.e-input,.e-small textarea.e-input.e-rtl,.e-float-input:not(.e-outline).e-small.e-rtl textarea,.e-float-input:not(.e-outline).e-control-wrapper.e-small.e-rtl textarea,.e-input-group:not(.e-outline).e-small.e-rtl textarea.e-input,.e-input-group:not(.e-outline).e-control-wrapper.e-small.e-rtl textarea.e-input,.e-rtl .e-float-input:not(.e-outline).e-control-wrapper.e-small textarea,.e-rtl .e-float-input:not(.e-outline).e-small textarea,.e-rtl .e-input-group:not(.e-outline).e-small textarea.e-input,.e-rtl .e-input-group:not(.e-outline).e-control-wrapper.e-small textarea.e-input,.e-float-input:not(.e-outline).e-control-wrapper.e-rtl textarea.e-small,.e-float-input:not(.e-outline).e-rtl textarea.e-small,.e-input-group:not(.e-outline).e-rtl textarea.e-input.e-small,.e-input-group:not(.e-outline).e-control-wrapper.e-rtl textarea.e-input.e-small,.e-rtl .e-float-input:not(.e-outline).e-control-wrapper textarea.e-small,.e-rtl .e-float-input:not(.e-outline) textarea.e-small,.e-rtl .e-input-group:not(.e-outline) textarea.e-input.e-small,.e-rtl .e-input-group:not(.e-outline).e-control-wrapper textarea.e-input.e-small,.e-small .e-float-input:not(.e-outline).e-control-wrapper.e-rtl textarea,.e-small .e-float-input:not(.e-outline).e-rtl textarea,.e-small .e-input-group:not(.e-outline).e-rtl textarea.e-input,.e-small .e-input-group:not(.e-outline).e-control-wrapper.e-rtl textarea.e-input,.e-small.e-rtl .e-float-input:not(.e-outline).e-control-wrapper textarea,.e-small.e-rtl .e-float-input:not(.e-outline) textarea,.e-small.e-rtl .e-input-group:not(.e-outline) textarea.e-input,.e-small.e-rtl .e-input-group:not(.e-outline).e-control-wrapper textarea.e-input,.e-small.e-rtl .e-input-group:not(.e-outline) textarea.e-input:focus,.e-small.e-rtl .e-input-group:not(.e-outline).e-control-wrapper textarea.e-input:focus,.e-small.e-rtl .e-float-input:not(.e-outline).e-control-wrapper textarea:focus,.e-small.e-rtl .e-float-input:not(.e-outline) textarea:focus,.e-small .e-input-group:not(.e-outline).e-rtl textarea.e-input:focus,.e-small .e-input-group:not(.e-outline).e-control-wrapper.e-rtl textarea.e-input:focus,.e-small .e-float-input:not(.e-outline).e-control-wrapper.e-rtl textarea:focus,.e-small .e-float-input:not(.e-outline).e-rtl textarea:focus{padding-right:0;text-indent:0}.e-float-input .e-clear-icon,.e-float-input.e-control-wrapper .e-clear-icon,.e-input-group .e-clear-icon,.e-input-group.e-control-wrapper .e-clear-icon{background:transparent;border:0;cursor:pointer;display:flex;flex-direction:column;justify-content:center;line-height:1;min-width:24px;outline:none;padding:0;text-align:center}.e-float-input .e-clear-icon:before,.e-float-input.e-control-wrapper .e-clear-icon:before,.e-input-group .e-clear-icon:before,.e-input-group.e-control-wrapper .e-clear-icon:before{font-size:12px;padding:0;text-align:center;vertical-align:middle}.e-float-input.e-static-clear .e-clear-icon.e-clear-icon-hide,.e-float-input.e-control-wrapper.e-static-clear .e-clear-icon.e-clear-icon-hide,.e-input-group.e-static-clear .e-clear-icon.e-clear-icon-hide,.e-input-group.e-control-wrapper.e-static-clear .e-clear-icon.e-clear-icon-hide{cursor:pointer;display:flex}.e-float-input.e-small .e-clear-icon:before,.e-float-input.e-control-wrapper.e-small .e-clear-icon:before,.e-input-group.e-small .e-clear-icon:before,.e-input-group.e-control-wrapper.e-small .e-clear-icon:before,.e-float-input.e-control-wrapper input.e-small:first-child~.e-clear-icon:before,.e-small .e-float-input.e-control-wrapper .e-clear-icon:before,.e-float-input input.e-small:first-child~.e-clear-icon:before,.e-small .e-float-input .e-clear-icon:before,.e-small .e-input-group .e-clear-icon:before,.e-small .e-input-group.e-control-wrapper .e-clear-icon:before{font-size:10px}.e-input-group.e-static-clear .e-clear-icon.e-clear-icon-hide,.e-input-group.e-control-wrapper.e-static-clear .e-clear-icon.e-clear-icon-hide{cursor:pointer}.e-float-input.e-control-wrapper input[readonly]:first-child~.e-clear-icon,.e-float-input.e-control-wrapper.e-input-group input[readonly]:first-child~.e-clear-icon,.e-float-input input[readonly]:first-child~.e-clear-icon,.e-float-input.e-input-group input[readonly]:first-child~.e-clear-icon,.e-input-group input[readonly]:first-child~.e-clear-icon.e-clear-icon-hide,.e-float-input.e-input-group.e-control-wrapper input[readonly]:first-child~.e-clear-icon,.e-input-group.e-control-wrapper input[readonly]:first-child .e-clear-icon.e-clear-icon-hide{cursor:auto}.e-input-group .e-clear-icon,.e-input-group.e-control-wrapper .e-clear-icon{min-height:18px;min-width:18px;padding:4px}.e-float-input.e-input-group .e-clear-icon,.e-float-input.e-input-group.e-control-wrapper .e-clear-icon{padding-right:4px;padding-top:4px}.e-input-group.e-small .e-clear-icon,.e-input-group .e-clear-icon.e-small,.e-input-group.e-control-wrapper.e-small .e-clear-icon,.e-input-group.e-control-wrapper .e-clear-icon.e-small{min-height:20px;min-width:20px;padding-bottom:5px;padding-right:8px;padding-top:6px}.e-input-group.e-small .e-clear-icon,.e-input-group .e-clear-icon.e-small,.e-small .e-input-group .e-clear-icon,.e-input-group.e-control-wrapper.e-small .e-clear-icon,.e-input-group.e-control-wrapper .e-clear-icon.e-small,.e-small .e-input-group.e-control-wrapper .e-clear-icon{min-height:16px;min-width:16px;padding-bottom:4px;padding-right:4px;padding-top:4px}.e-input-group.e-float-input.e-small .e-clear-icon,.e-input-group.e-float-input .e-clear-icon.e-small,.e-small .e-input-group.e-float-input .e-clear-icon,.e-input-group.e-control-wrapper.e-float-input.e-small .e-clear-icon,.e-input-group.e-control-wrapper.e-float-input .e-clear-icon.e-small,.e-small .e-input-group.e-control-wrapper.e-float-input .e-clear-icon,.e-input-group.e-float-input.e-control-wrapper.e-small .e-clear-icon,.e-input-group.e-float-input.e-control-wrapper .e-clear-icon.e-small,.e-small .e-input-group.e-float-input.e-control-wrapper .e-clear-icon{padding-right:4px;padding-top:4px}.e-input:not(:valid),.e-input:valid,.e-float-input.e-control-wrapper input:not(:valid),.e-float-input.e-control-wrapper input:valid,.e-float-input input:not(:valid),.e-float-input input:valid,.e-input-group input:not(:valid),.e-input-group input:valid,.e-input-group.e-control-wrapper input:not(:valid),.e-input-group.e-control-wrapper input:valid,.e-float-input.e-control-wrapper textarea:not(:valid),.e-float-input.e-control-wrapper textarea:valid,.e-float-input textarea:not(:valid),.e-float-input textarea:valid,.e-input-group.e-control-wrapper textarea:not(:valid),.e-input-group.e-control-wrapper textarea:valid,.e-input-group textarea:not(:valid),.e-input-group textarea:valid{box-shadow:none}.e-input-group .e-input-in-wrap,.e-input-group.e-control-wrapper .e-input-in-wrap,.e-float-input .e-input-in-wrap,.e-float-input.e-control-wrapper .e-input-in-wrap{width:100%}.e-float-input .e-input-in-wrap label.e-float-text,.e-float-input.e-control-wrapper .e-input-in-wrap label.e-float-text{right:0}.e-input-group .e-input-in-wrap,.e-input-group.e-control-wrapper .e-input-in-wrap,.e-float-input .e-input-in-wrap,.e-float-input.e-control-wrapper .e-input-in-wrap{display:flex;position:relative;width:100%}.e-float-input.e-float-icon-left .e-input-in-wrap,.e-float-input.e-control-wrapper.e-float-icon-left .e-input-in-wrap,.e-input-group.e-float-icon-left .e-input-in-wrap,.e-input-group.e-control-wrapper.e-float-icon-left .e-input-in-wrap{border:1px solid;border-width:0 0 1px 0;margin-left:8px}.e-rtl .e-float-input.e-float-icon-left .e-input-in-wrap,.e-rtl .e-float-input.e-control-wrapper.e-float-icon-left .e-input-in-wrap,.e-rtl .e-input-group.e-float-icon-left .e-input-in-wrap,.e-rtl .e-input-group.e-control-wrapper.e-float-icon-left .e-input-in-wrap .e-float-input.e-control-wrapper.e-float-icon-left.e-rtl .e-input-in-wrap,.e-float-input.e-float-icon-left.e-rtl .e-input-in-wrap,.e-input-group.e-float-icon-left.e-rtl .e-input-in-wrap,.e-input-group.e-control-wrapper.e-float-icon-left.e-rtl .e-input-in-wrap{margin-left:0;margin-right:8px}.e-float-input label.e-float-text.e-label-bottom,.e-float-input:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-float-input.e-control-wrapper label.e-float-text.e-label-bottom,.e-float-input.e-control-wrapper:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom{transform:translate3d(0,16px,0) scale(1)}.e-float-input textarea:focus~label.e-float-text,.e-float-input textarea:valid~label.e-float-text,.e-float-input textarea~label.e-label-top.e-float-text,.e-float-input textarea[readonly]~label.e-label-top.e-float-text,.e-float-input textarea[disabled]~label.e-label-top.e-float-text,.e-float-input textarea label.e-float-text.e-label-top,.e-float-input.e-control-wrapper textarea:focus~label.e-float-text,.e-float-input.e-control-wrapper textarea:valid~label.e-float-text,.e-float-input.e-control-wrapper textarea~label.e-label-top.e-float-text,.e-float-input.e-control-wrapper textarea[readonly]~label.e-label-top.e-float-text,.e-float-input.e-control-wrapper textarea[disabled]~label.e-label-top.e-float-text,.e-float-input.e-control-wrapper textarea label.e-float-text.e-label-top{font-size:13px;top:-22px;transform:translate3d(0,6px,0) scale(.92)}.e-float-input.e-small textarea:focus~label.e-float-text,.e-float-input.e-small textarea:valid~label.e-float-text,.e-float-input.e-small textarea~label.e-label-top.e-float-text,.e-small .e-float-input textarea~label.e-label-top.e-float-text,.e-float-input.e-control-wrapper.e-small textarea:focus~label.e-float-text,.e-float-input.e-control-wrapper.e-small textarea:valid~label.e-float-text,.e-float-input.e-control-wrapper.e-small textarea~label.e-label-top.e-float-text,.e-small .e-float-input.e-control-wrapper textarea~label.e-label-top.e-float-text{font-size:12px;top:-21px}.e-float-input textarea~.e-float-text,.e-float-input.e-control-wrapper textarea~.e-float-text{top:-11px}.e-float-input.e-small textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small .e-float-input textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-float-input.e-control-wrapper.e-small textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small .e-float-input.e-control-wrapper textarea:not(:focus):valid~label.e-float-text.e-label-bottom{font-size:12px;top:-11px}.e-float-input.e-small textarea~label.e-float-text,.e-float-input textarea~label.e-float-text.e-small,.e-float-input textarea.e-small~label.e-float-text,.e-small .e-float-input textarea~label.e-float-text,.e-float-input.e-control-wrapper.e-small textarea~label.e-float-text,.e-float-input.e-control-wrapper textarea~label.e-float-text.e-small,.e-float-input.e-control-wrapper textarea.e-small~label.e-float-text,.e-small .e-float-input.e-control-wrapper textarea~label.e-float-text{font-size:12px;top:-11px}.e-input-group.e-small:not(.e-float-input) .e-input,.e-small .e-input-group:not(.e-float-input) .e-input,.e-input-group.e-control-wrapper.e-small:not(.e-float-input) .e-input,.e-small .e-input-group.e-control-wrapper:not(.e-float-input) .e-input,.e-float-input.e-small input,.e-small .e-float-input input,.e-float-input.e-input-group.e-small input,.e-small .e-float-input.e-input-group input,.e-float-input.e-input-group.e-control-wrapper.e-small input,.e-small .e-float-input.e-input-group.e-control-wrapper input,.e-float-input.e-control-wrapper.e-small input,.e-small .e-float-input.e-control-wrapper input,.e-float-input.e-control-wrapper.e-input-group.e-small input,.e-small .e-float-input.e-control-wrapper.e-input-group input{min-height:16px}.e-input-group input.e-input,.e-float-input.e-input-group input,.e-input-group.e-control-wrapper input.e-input,.e-float-input.e-input-group.e-control-wrapper input,.e-float-input input,.e-float-input.e-control-wrapper input{min-height:22px}.e-input-group:hover:not(.e-disabled):not(.e-success):not(.e-warning):not(.e-error):not(.e-float-icon-left),.e-input-group.e-control-wrapper:hover:not(.e-disabled):not(.e-success):not(.e-warning):not(.e-error):not(.e-float-icon-left),.e-float-input:hover:not(.e-disabled):not(.e-success):not(.e-warning):not(.e-error):not(.e-float-icon-left),.e-float-input:hover:not(.e-input-group):not(.e-disabled):not(.e-success):not(.e-warning):not(.e-error) input:not([disabled]),.e-float-input:hover:not(.e-input-group):not(.e-disabled):not(.e-success):not(.e-warning):not(.e-error) textarea:not([disabled]),.e-float-input.e-control-wrapper:hover:not(.e-disabled):not(.e-success):not(.e-warning):not(.e-error):not(.e-float-icon-left),.e-float-input.e-control-wrapper:hover:not(.e-input-group):not(.e-disabled):not(.e-success):not(.e-warning):not(.e-error) input:not([disabled]),.e-float-input.e-control-wrapper:hover:not(.e-input-group):not(.e-disabled):not(.e-success):not(.e-warning):not(.e-error) textarea:not([disabled]){border-bottom-width:1px}.e-input-group.e-float-icon-left:not(.e-disabled):not(.e-input-focus) .e-input-in-wrap:hover,.e-input-group.e-control-wrapper.e-float-icon-left:not(.e-disabled):not(.e-input-focus) .e-input-in-wrap:hover,.e-float-input.e-float-icon-left:not(.e-disabled):not(.e-input-focus) .e-input-in-wrap:hover,.e-float-input.e-control-wrapper.e-float-icon-left:not(.e-disabled):not(.e-input-focus) .e-input-in-wrap:hover{border-bottom-width:1px}.e-input-group:not(.e-disabled):not(.e-float-icon-left):before,.e-input-group:not(.e-disabled):not(.e-float-icon-left):after,.e-input-group.e-float-icon-left:not(.e-disabled) .e-input-in-wrap:before,.e-input-group.e-float-icon-left:not(.e-disabled) .e-input-in-wrap:after,.e-input-group.e-control-wrapper:not(.e-disabled):not(.e-float-icon-left):before,.e-input-group.e-control-wrapper:not(.e-disabled):not(.e-float-icon-left):after,.e-input-group.e-control-wrapper.e-float-icon-left:not(.e-disabled) .e-input-in-wrap:before,.e-input-group.e-control-wrapper.e-float-icon-left:not(.e-disabled) .e-input-in-wrap:after{bottom:-2px}.e-input-group.e-input-focus:not(.e-float-icon-left):not(.e-success):not(.e-warning):not(.e-error),.e-input-group.e-control-wrapper.e-input-focus:not(.e-float-icon-left):not(.e-success):not(.e-warning):not(.e-error),.e-float-input.e-input-group.e-input-focus:not(.e-float-icon-left):not(.e-success):not(.e-warning):not(.e-error),.e-float-input.e-input-group.e-input-focus:not(.e-float-icon-left).e-success:not(.e-warning):not(.e-error),.e-float-input.e-input-group.e-input-focus:not(.e-float-icon-left):not(.e-success).e-warning:not(.e-error),.e-float-input.e-input-group.e-input-focus:not(.e-float-icon-left):not(.e-success):not(.e-warning).e-error,.e-float-input.e-control-wrapper.e-input-group.e-input-focus:not(.e-float-icon-left):not(.e-success):not(.e-warning):not(.e-error),.e-float-input.e-control-wrapper.e-input-group.e-input-focus:not(.e-float-icon-left).e-success:not(.e-warning):not(.e-error),.e-float-input.e-control-wrapper.e-input-group.e-input-focus:not(.e-float-icon-left):not(.e-success).e-warning:not(.e-error),.e-float-input.e-control-wrapper.e-input-group.e-input-focus:not(.e-float-icon-left):not(.e-success):not(.e-warning).e-error,.e-float-input.e-control-wrapper.e-input-focus:not(.e-input-group):not(.e-float-icon-left):not(.e-disabled):not(.e-success):not(.e-warning):not(.e-error) input,.e-float-input.e-control-wrapper.e-input-focus:not(.e-input-group):not(.e-float-icon-left):not(.e-disabled).e-success:not(.e-warning):not(.e-error) input,.e-float-input.e-control-wrapper.e-input-focus:not(.e-input-group):not(.e-float-icon-left):not(.e-disabled):not(.e-success).e-warning:not(.e-error) input,.e-float-input.e-control-wrapper.e-input-focus:not(.e-input-group):not(.e-float-icon-left):not(.e-disabled):not(.e-success):not(.e-warning).e-error input,.e-float-input.e-control-wrapper.e-input-focus:not(.e-input-group):not(.e-float-icon-left):not(.e-disabled):not(.e-success):not(.e-warning):not(.e-error) textarea,.e-float-input.e-control-wrapper.e-input-focus:not(.e-input-group):not(.e-float-icon-left):not(.e-disabled).e-success:not(.e-warning):not(.e-error) textarea,.e-float-input.e-control-wrapper.e-input-focus:not(.e-input-group):not(.e-float-icon-left):not(.e-disabled):not(.e-success).e-warning:not(.e-error) textarea,.e-float-input.e-control-wrapper.e-input-focus:not(.e-input-group):not(.e-float-icon-left):not(.e-disabled):not(.e-success):not(.e-warning).e-error textarea,.e-float-input.e-input-focus:not(.e-input-group):not(.e-float-icon-left):not(.e-disabled):not(.e-success):not(.e-warning):not(.e-error) input,.e-float-input.e-input-focus:not(.e-input-group):not(.e-float-icon-left):not(.e-disabled).e-success:not(.e-warning):not(.e-error) input,.e-float-input.e-input-focus:not(.e-input-group):not(.e-float-icon-left):not(.e-disabled):not(.e-success).e-warning:not(.e-error) input,.e-float-input.e-input-focus:not(.e-input-group):not(.e-float-icon-left):not(.e-disabled):not(.e-success):not(.e-warning).e-error input,.e-float-input.e-input-focus:not(.e-input-group):not(.e-float-icon-left):not(.e-disabled):not(.e-success):not(.e-warning):not(.e-error) textarea,.e-float-input.e-input-focus:not(.e-input-group):not(.e-float-icon-left):not(.e-disabled).e-success:not(.e-warning):not(.e-error) textarea,.e-float-input.e-input-focus:not(.e-input-group):not(.e-float-icon-left):not(.e-disabled):not(.e-success).e-warning:not(.e-error) textarea,.e-float-input.e-input-focus:not(.e-input-group):not(.e-float-icon-left):not(.e-disabled):not(.e-success):not(.e-warning).e-error textarea,.e-input-group.e-input-focus:not(.e-float-icon-left).e-success:not(.e-warning):not(.e-error),.e-input-group.e-input-focus:not(.e-float-icon-left).e-warning:not(.e-success):not(.e-error),.e-input-group.e-control-wrapper.e-input-focus:not(.e-float-icon-left).e-success:not(.e-warning):not(.e-error),.e-input-group.e-control-wrapper.e-input-focus:not(.e-float-icon-left).e-warning:not(.e-success):not(.e-error),.e-input-group.e-input-focus:not(.e-float-icon-left).e-error:not(.e-success):not(.e-warning),.e-input-group.e-float-icon-left.e-input-focus:not(.e-success):not(.e-warning):not(.e-error) .e-input-in-wrap,.e-input-group.e-float-icon-left.e-input-focus.e-success:not(.e-warning):not(.e-error) .e-input-in-wrap,.e-input-group.e-float-icon-left.e-input-focus.e-warning:not(.e-success):not(.e-error) .e-input-in-wrap,.e-input-group.e-float-icon-left.e-input-focus.e-error:not(.e-success):not(.e-warning) .e-input-in-wrap{border-style:solid;border-width:0 0 1px}.e-float-input:not(.e-outline) input:-webkit-autofill~label.e-float-text,.e-float-input.e-control-wrapper.e-autofill:not(.e-outline) input:-webkit-autofill~label.e-float-text,.e-float-input.e-control-wrapper.e-autofill:not(.e-input-focus):not(.e-outline) input:not(:focus):valid:-webkit-autofill~label.e-float-text.e-label-bottom{font-size:13px;top:-9px;transform:translate3d(0,-6px,0) scale(.92);-webkit-user-select:text;user-select:text}.e-small .e-float-input:not(.e-outline) input:-webkit-autofill~label.e-float-text,.e-small.e-float-input:not(.e-outline) input:-webkit-autofill~label.e-float-text,.e-small .e-float-input.e-control-wrapper.e-autofill:not(.e-outline) input:-webkit-autofill~label.e-float-text,.e-small.e-float-input.e-control-wrapper.e-autofill:not(.e-outline) input:-webkit-autofill~label.e-float-text,.e-small .e-float-input.e-control-wrapper.e-autofill:not(.e-input-focus):not(.e-outline) input:not(:focus):valid:-webkit-autofill~label.e-float-text.e-label-bottom,.e-small.e-float-input.e-control-wrapper.e-autofill:not(.e-input-focus):not(.e-outline) input:not(:focus):valid:-webkit-autofill~label.e-float-text.e-label-bottom{font-size:12px;top:-8px;transform:translate3d(0,-6px,0) scale(.92);-webkit-user-select:text;user-select:text}.e-float-input textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-float-input.e-control-wrapper textarea:not(:focus):valid~label.e-float-text.e-label-bottom{transform:translate3d(0,16px,0) scale(1)}.e-float-input textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-float-input.e-control-wrapper textarea:not(:focus):valid~label.e-float-text.e-label-bottom{font-size:13px;font-style:normal;font-weight:400;left:0;overflow:hidden;padding-left:0;pointer-events:none;position:absolute;text-overflow:ellipsis;top:-11px;transform:translate3d(0,16px,0) scale(1);transform-origin:left top;transition:.25s cubic-bezier(.25,.8,.25,1);-webkit-user-select:none;user-select:none;white-space:nowrap;width:100%}.e-float-input textarea:-webkit-autofill~label.e-float-text,.e-float-input.e-control-wrapper.e-autofill textarea:-webkit-autofill~label.e-float-text,.e-float-input.e-control-wrapper.e-autofill textarea:not(:focus):valid:-webkit-autofill~label.e-float-text.e-label-bottom{font-size:13px;top:-9px;transform:translate3d(0,-6px,0) scale(.92);-webkit-user-select:text;user-select:text}.e-small .e-float-input textarea:-webkit-autofill~label.e-float-text,.e-small.e-float-input textarea:-webkit-autofill~label.e-float-text,.e-small .e-float-input.e-control-wrapper.e-autofill textarea:-webkit-autofill~label.e-float-text,.e-small.e-float-input.e-control-wrapper.e-autofill textarea:-webkit-autofill~label.e-float-text,.e-small .e-float-input.e-control-wrapper.e-autofill textarea:not(:focus):valid:-webkit-autofill~label.e-float-text.e-label-bottom,.e-small.e-float-input.e-control-wrapper.e-autofill textarea:not(:focus):valid:-webkit-autofill~label.e-float-text.e-label-bottom{font-size:12px;top:-8px;transform:translate3d(0,-6px,0) scale(.92);-webkit-user-select:text;user-select:text}.e-float-input.e-small textarea:focus~label.e-float-text,.e-float-input.e-small textarea:valid~label.e-float-text,.e-float-input.e-small textarea~label.e-label-top.e-float-text,.e-float-input.e-small textarea[readonly]~label.e-label-top.e-float-text,.e-float-input.e-small textarea[disabled]~label.e-label-top.e-float-text,.e-float-input.e-small textarea label.e-float-text.e-label-top,.e-small .e-float-input textarea:focus~label.e-float-text,.e-small .e-float-input textarea:valid~label.e-float-text,.e-small .e-float-input textarea~label.e-label-top.e-float-text,.e-small .e-float-input textarea[readonly]~label.e-label-top.e-float-text,.e-small .e-float-input textarea[disabled]~label.e-label-top.e-float-text,.e-small .e-float-input textarea label.e-float-text.e-label-top,.e-float-input.e-control-wrapper.e-small textarea:focus~label.e-float-text,.e-float-input.e-control-wrapper.e-small textarea:valid~label.e-float-text,.e-float-input.e-control-wrapper.e-small textarea~label.e-label-top.e-float-text,.e-float-input.e-control-wrapper.e-small textarea[readonly]~label.e-label-top.e-float-text,.e-float-input.e-control-wrapper.e-small textarea[disabled]~label.e-label-top.e-float-text,.e-float-input.e-control-wrapper.e-small textarea label.e-float-text.e-label-top,.e-small .e-float-input.e-control-wrapper textarea:focus~label.e-float-text,.e-small .e-float-input.e-control-wrapper textarea:valid~label.e-float-text,.e-small .e-float-input.e-control-wrapper textarea~label.e-label-top.e-float-text,.e-small .e-float-input.e-control-wrapper textarea[readonly]~label.e-label-top.e-float-text,.e-small .e-float-input.e-control-wrapper textarea[disabled]~label.e-label-top.e-float-text,.e-small .e-float-input.e-control-wrapper textarea label.e-float-text.e-label-top{transform:translate3d(0,6px,0) scale(.86)}.e-float-input textarea[disabled],.e-float-input textarea.e-disabled,.e-float-input.e-control-wrapper textarea[disabled],.e-float-input.e-control-wrapper textarea.e-disabled{background:transparent;background-image:none;cursor:not-allowed}textarea.e-input,.e-input-group textarea,.e-input-group textarea.e-input,.e-input-group.e-input-focus textarea,.e-input-group.e-input-focus textarea.e-input,.e-input-group.e-control-wrapper textarea,.e-input-group.e-control-wrapper.e-input-focus textarea,.e-input-group.e-control-wrapper textarea.e-input,.e-input-group.e-control-wrapper.e-input-focus textarea.e-input,.e-float-input textarea,.e-float-input.e-control-wrapper textarea{line-height:1.5;min-height:15px;min-width:0;padding:4px 0;resize:vertical}.e-input-group.e-small textarea,.e-input-group.e-small textarea.e-input,.e-input-group textarea.e-small,.e-input-group textarea.e-input.e-small,.e-input-group.e-control-wrapper.e-small textarea,.e-input-group.e-control-wrapper.e-small textarea.e-input,.e-small .e-input-group textarea,.e-small .e-input-group textarea.e-input,.e-float-input.e-small textarea,.e-float-input textarea.e-small,.e-float-input.e-control-wrapper.e-small textarea,.e-float-input.e-control-wrapper textarea.e-small,.e-small .e-float-input textarea,.e-small .e-float-input.e-control-wrapper textarea,.e-input-group.e-input-focus.e-small textarea,.e-input-group.e-input-focus.e-small textarea.e-input,.e-input-group.e-input-focus textarea.e-small,.e-input-group.e-input-focus textarea.e-input.e-small,.e-input-group.e-control-wrapper.e-input-focus.e-small textarea,.e-input-group.e-control-wrapper.e-input-focus.e-small textarea.e-input,.e-small .e-input-group.e-input-focus textarea,.e-small .e-input-group.e-input-focus textarea.e-input{font:inherit;min-height:14px;padding:4px 0}.e-input-group.e-small textarea:focus,.e-input-group.e-small textarea.e-input:focus,.e-input-group textarea.e-small:focus,.e-input-group textarea.e-input.e-small:focus,.e-input-group.e-control-wrapper.e-small textarea:focus,.e-input-group.e-control-wrapper.e-small textarea.e-input:focus,.e-small .e-input-group textarea:focus,.e-small .e-input-group textarea.e-input:focus,.e-float-input.e-small textarea:focus,.e-float-input textarea.e-small:focus,.e-float-input.e-control-wrapper.e-small textarea:focus,.e-float-input.e-control-wrapper textarea.e-small:focus,.e-small .e-float-input textarea:focus,.e-small .e-float-input.e-control-wrapper textarea:focus{padding:4px 0}input.e-input.e-small,textarea.e-input.e-small,.e-small input.e-input,.e-small textarea.e-input{min-height:16px}input.e-input,textarea.e-input{min-height:19px}textarea.e-outline.e-input,.e-outline.e-input-group textarea.e-input,.e-outline.e-input-group textarea,.e-outline.e-input-group.e-control-wrapper textarea.e-input,.e-outline.e-input-group.e-control-wrapper textarea,.e-outline.e-float-input textarea.e-input,.e-outline.e-float-input textarea,.e-outline.e-float-input.e-control-wrapper textarea.e-input,.e-outline.e-float-input.e-control-wrapper textarea{width:calc(100% - 1px)}.e-outline.e-float-input.e-control-wrapper.e-numeric label.e-float-text.e-label-bottom span.e-float-text-content.e-float-text-overflow{width:calc(100% - 80px)}.e-outline.e-float-input.e-control-wrapper.e-numeric label.e-float-text.e-label-top span.e-float-text-content.e-float-text-overflow,.e-outline.e-float-input.e-control-wrapper label.e-float-text.e-label-top span.e-float-text-content.e-float-text-overflow,.e-outline.e-float-input.e-control-wrapper label.e-float-text.e-label-bottom span.e-float-text-content.e-float-text-overflow,.e-outline.e-float-input.e-control-wrapper.e-static-clear label.e-float-text.e-label-top span.e-float-text-content.e-float-text-overflow,.e-outline.e-float-input.e-control-wrapper.e-numeric.e-static-clear label.e-float-text.e-label-top span.e-float-text-content.e-float-text-overflow{overflow:hidden;text-overflow:ellipsis;width:100%}.e-outline.e-float-input.e-control-wrapper.e-static-clear label.e-float-text.e-label-bottom span.e-float-text-content.e-float-text-overflow,.e-outline.e-float-input.e-control-wrapper label.e-float-text.e-label-bottom span.e-float-text-content.e-float-text-overflow.e-icon{width:calc(100% - 45px)}.e-outline.e-float-input.e-control-wrapper.e-static-clear label.e-float-text.e-label-bottom span.e-float-text-content.e-float-text-overflow.e-icon{width:calc(100% - 75px)}.e-outline.e-float-input.e-control-wrapper.e-numeric.e-static-clear label.e-float-text.e-label-bottom span.e-float-text-content.e-float-text-overflow{width:calc(100% - 110px)}.e-outline.e-float-input.e-input-group:not(.e-float-icon-left).e-input-focus .e-float-line:before,.e-outline.e-float-input.e-input-group:not(.e-float-icon-left).e-input-focus .e-float-line:after,.e-outline.e-float-input.e-input-group.e-float-icon-left.e-input-focus .e-input-in-wrap .e-float-line:before,.e-outline.e-float-input.e-input-group.e-float-icon-left.e-input-focus .e-input-in-wrap .e-float-line:after,.e-outline.e-float-input.e-control-wrapper.e-input-group:not(.e-float-icon-left).e-input-focus .e-float-line:before,.e-outline.e-float-input.e-control-wrapper.e-input-group:not(.e-float-icon-left).e-input-focus .e-float-line:after,.e-outline.e-float-input.e-control-wrapper.e-input-group.e-float-icon-left.e-input-focus .e-input-in-wrap .e-float-line:before,.e-outline.e-float-input.e-control-wrapper.e-input-group.e-float-icon-left.e-input-focus .e-input-in-wrap .e-float-line:after{width:0%}.e-outline.e-input-group.e-control-wrapper,.e-outline.e-input-group,.e-outline.e-input-group:not(.e-float-icon-left),.e-outline.e-float-input,.e-outline.e-float-input.e-control-wrapper,.e-outline.e-input-group.e-success:not(.e-float-icon-left),.e-outline.e-input-group.e-warning:not(.e-float-icon-left),.e-outline.e-input-group.e-error:not(.e-float-icon-left),.e-outline.e-input-group.e-control-wrapper:not(.e-float-icon-left),.e-outline.e-input-group.e-control-wrapper.e-success:not(.e-float-icon-left),.e-outline.e-input-group.e-control-wrapper.e-warning:not(.e-float-icon-left),.e-outline.e-input-group.e-control-wrapper.e-error:not(.e-float-icon-left){border:1px solid rgba(0,0,0,.24);border-radius:4px;border-width:1px;fill:transparent;transition:border .2s,box-shadow .2s}.e-outline.e-float-input,.e-outline.e-float-input.e-control-wrapper{margin-top:0}.e-outline.e-float-input.e-valid-input:not(.e-success):not(.e-error):not(.e-warning):not(.e-float-icon-left),.e-outline.e-float-input.e-valid-input:hover:not(.e-success):not(.e-error):not(.e-warning):not(.e-float-icon-left),.e-outline.e-float-input.e-valid-input.e-control-wrapper:hover:not(.e-success):not(.e-error):not(.e-warning):not(.e-float-icon-left),.e-outline.e-float-input.e-valid-input.e-control-wrapper:not(.e-success):not(.e-error):not(.e-warning):not(.e-float-icon-left),.e-outline.e-float-input.e-valid-input.e-control-wrapper:hover:not(.e-success):not(.e-error):not(.e-warning):not(.e-float-icon-left):not(.e-disabled),.e-outline.e-float-input.e-valid-input.e-control-wrapper:not(.e-success):not(.e-error):not(.e-warning):not(.e-float-icon-left):not(.e-disabled),.e-outline.e-float-input.e-input-group.e-valid-input:not(.e-success):not(.e-error):not(.e-warning):not(.e-float-icon-left),.e-outline.e-float-input.e-input-group.e-valid-input:hover:not(.e-success):not(.e-error):not(.e-warning):not(.e-float-icon-left),.e-outline.e-float-input.e-input-group.e-control-wrapper.e-valid-input:not(.e-success):not(.e-error):not(.e-warning):not(.e-float-icon-left),.e-outline.e-float-input.e-input-group.e-control-wrapper.e-valid-input:hover:not(.e-success):not(.e-error):not(.e-warning):not(.e-float-icon-left),.e-outline.e-float-input.e-valid-input.e-success:not(.e-error):not(.e-warning):not(.e-float-icon-left),.e-outline.e-float-input.e-valid-input.e-success:hover:not(.e-error):not(.e-warning):not(.e-float-icon-left),.e-outline.e-float-input.e-input-group.e-valid-input.e-success:not(.e-error):not(.e-warning):not(.e-float-icon-left),.e-outline.e-float-input.e-input-group.e-valid-input.e-success:hover:not(.e-error):not(.e-warning):not(.e-float-icon-left),.e-outline.e-float-input.e-control-wrapper.e-valid-input.e-success:not(.e-error):not(.e-warning):not(.e-float-icon-left),.e-outline.e-float-input.e-control-wrapper.e-valid-input.e-success:hover:not(.e-error):not(.e-warning):not(.e-float-icon-left),.e-outline.e-float-input.e-valid-input.e-error:not(.e-success):not(.e-warning):not(.e-float-icon-left),.e-outline.e-float-input.e-valid-input.e-error:hover:not(.e-success):not(.e-warning):not(.e-float-icon-left),.e-outline.e-float-input.e-input-group.e-valid-input.e-error:not(.e-success):not(.e-warning):not(.e-float-icon-left),.e-outline.e-float-input.e-input-group.e-valid-input.e-error:hover:not(.e-success):not(.e-warning):not(.e-float-icon-left),.e-outline.e-float-input.e-control-wrapper.e-valid-input.e-error:not(.e-success):not(.e-warning):not(.e-float-icon-left),.e-outline.e-float-input.e-control-wrapper.e-valid-input.e-error:hover:not(.e-success):not(.e-warning):not(.e-float-icon-left),.e-outline.e-float-input.e-valid-input.e-warning:not(.e-success):not(.e-error):not(.e-float-icon-left),.e-outline.e-float-input.e-valid-input.e-warning:hover:not(.e-success):not(.e-error):not(.e-float-icon-left),.e-outline.e-float-input.e-input-group.e-valid-input.e-warning:not(.e-success):not(.e-error):not(.e-float-icon-left),.e-outline.e-float-input.e-input-group.e-valid-input.e-warning:hover:not(.e-success):not(.e-error):not(.e-float-icon-left),.e-outline.e-float-input.e-control-wrapper.e-valid-input.e-warning:not(.e-success):not(.e-error):not(.e-float-icon-left),.e-outline.e-float-input.e-control-wrapper.e-valid-input.e-warning:hover:not(.e-success):not(.e-error):not(.e-float-icon-left),.e-outline.e-float-input.e-input-group.e-valid-input.e-float-icon-left:hover:not(.e-input-focus):not(.e-success):not(.e-warning):not(.e-error):not(.e-disabled),.e-outline.e-float-input.e-input-group.e-valid-input.e-control-wrapper.e-float-icon-left:hover:not(.e-input-focus):not(.e-success):not(.e-warning):not(.e-error):not(.e-disabled),.e-outline.e-float-input.e-valid-input.e-float-icon-left:hover:not(.e-input-focus):not(.e-success):not(.e-warning):not(.e-error):not(.e-disabled),.e-outline.e-float-input.e-valid-input.e-control-wrapper.e-float-icon-left:not(.e-input-focus):hover:not(.e-success):not(.e-warning):not(.e-error):not(.e-disabled),.e-outline.e-float-input.e-control-wrapper.e-valid-input.e-float-icon-left:not(.e-warning):not(.e-success):not(.e-error){border-top-color:transparent}.e-outline.e-input-group,.e-outline .e-input-group,.e-outline .e-input-group.e-control-wrapper,.e-outline.e-float-input,.e-outline.e-float-input.e-control-wrapper{font-size:14px}.e-outline.e-input-group.e-input-focus:not(.e-float-icon-left):not(.e-success):not(.e-warning):not(.e-error),.e-outline.e-input-group.e-control-wrapper.e-input-focus:not(.e-float-icon-left):not(.e-success):not(.e-warning):not(.e-error),.e-outline.e-float-input.e-input-group.e-input-focus:not(.e-float-icon-left):not(.e-success):not(.e-warning):not(.e-error),.e-outline.e-float-input.e-input-group.e-input-focus:not(.e-float-icon-left).e-success:not(.e-warning):not(.e-error),.e-outline.e-float-input.e-input-group.e-input-focus:not(.e-float-icon-left):not(.e-success).e-warning:not(.e-error),.e-outline.e-float-input.e-input-group.e-input-focus:not(.e-float-icon-left):not(.e-success):not(.e-warning).e-error,.e-outline.e-float-input.e-control-wrapper.e-input-group.e-input-focus:not(.e-float-icon-left):not(.e-success):not(.e-warning):not(.e-error),.e-outline.e-float-input.e-control-wrapper.e-input-group.e-input-focus:not(.e-float-icon-left).e-success:not(.e-warning):not(.e-error),.e-outline.e-float-input.e-control-wrapper.e-input-group.e-input-focus:not(.e-float-icon-left):not(.e-success).e-warning:not(.e-error),.e-outline.e-float-input.e-control-wrapper.e-input-group.e-input-focus:not(.e-float-icon-left):not(.e-success):not(.e-warning).e-error,.e-outline.e-float-input.e-control-wrapper.e-input-focus:not(.e-input-group):not(.e-float-icon-left):not(.e-disabled):not(.e-success):not(.e-warning):not(.e-error),.e-outline.e-float-input.e-control-wrapper.e-input-focus:not(.e-input-group):not(.e-float-icon-left):not(.e-disabled).e-success:not(.e-warning):not(.e-error),.e-outline.e-float-input.e-control-wrapper.e-input-focus:not(.e-input-group):not(.e-float-icon-left):not(.e-disabled):not(.e-success).e-warning:not(.e-error),.e-outline.e-float-input.e-control-wrapper.e-input-focus:not(.e-input-group):not(.e-float-icon-left):not(.e-disabled):not(.e-success):not(.e-warning).e-error,.e-outline.e-float-input.e-input-focus:not(.e-input-group):not(.e-float-icon-left):not(.e-disabled):not(.e-success):not(.e-warning):not(.e-error),.e-outline.e-float-input.e-input-focus:not(.e-input-group):not(.e-float-icon-left):not(.e-disabled).e-success:not(.e-warning):not(.e-error),.e-outline.e-float-input.e-input-focus:not(.e-input-group):not(.e-float-icon-left):not(.e-disabled):not(.e-success).e-warning:not(.e-error),.e-outline.e-float-input.e-input-focus:not(.e-input-group):not(.e-float-icon-left):not(.e-disabled):not(.e-success):not(.e-warning).e-error,.e-outline.e-input-group.e-input-focus:not(.e-float-icon-left).e-success:not(.e-warning):not(.e-error),.e-outline.e-input-group.e-input-focus:not(.e-float-icon-left).e-warning:not(.e-success):not(.e-error),.e-outline.e-input-group.e-control-wrapper.e-input-focus:not(.e-float-icon-left).e-success:not(.e-warning):not(.e-error),.e-outline.e-input-group.e-control-wrapper.e-input-focus:not(.e-float-icon-left).e-warning:not(.e-success):not(.e-error),.e-outline.e-input-group.e-input-focus:not(.e-float-icon-left).e-error:not(.e-success):not(.e-warning),.e-outline.e-input-group.e-float-icon-left.e-input-focus:not(.e-success):not(.e-warning):not(.e-error),.e-outline.e-input-group.e-float-icon-left.e-input-focus.e-success:not(.e-warning):not(.e-error),.e-outline.e-input-group.e-float-icon-left.e-input-focus.e-warning:not(.e-success):not(.e-error),.e-outline.e-input-group.e-float-icon-left.e-input-focus.e-error:not(.e-success):not(.e-warning){border-width:1px}input.e-outline.e-input,.e-outline.e-input-group input.e-input,.e-outline.e-input-group input,.e-outline.e-input-group.e-control-wrapper input.e-input,.e-outline.e-input-group.e-control-wrapper input,.e-outline.e-float-input input.e-input,.e-outline.e-float-input input,.e-outline.e-float-input.e-control-wrapper input.e-input,.e-outline.e-float-input.e-control-wrapper input,.e-outline.e-input-group:not(.e-float-icon-left) input.e-input:focus,.e-outline.e-input-group.e-control-wrapper:not(.e-float-icon-left) input.e-input:focus,.e-outline.e-float-input.e-control-wrapper:not(.e-float-icon-left) input:focus,.e-outline.e-float-input:not(.e-float-icon-left) input:focus,.e-outline.e-float-input.e-control-wrapper:not(.e-float-icon-left).e-input-focus input,.e-outline.e-float-input:not(.e-float-icon-left).e-input-focus input,.e-outline.e-input-group:not(.e-float-icon-left).e-input-focus input.e-input,.e-outline.e-input-group.e-control-wrapper:not(.e-float-icon-left).e-input-focus input.e-input{box-sizing:border-box;padding:10px 12px 9px}textarea.e-outline.e-input,.e-outline.e-input-group textarea.e-input,.e-outline.e-input-group textarea,.e-outline.e-input-group.e-control-wrapper textarea.e-input,.e-outline.e-input-group.e-control-wrapper textarea,.e-outline.e-float-input textarea.e-input,.e-outline.e-float-input textarea,.e-outline.e-float-input.e-control-wrapper textarea.e-input,.e-outline.e-float-input.e-control-wrapper textarea,.e-outline.e-input-group:not(.e-float-icon-left) textarea.e-input:focus,.e-outline.e-input-group.e-control-wrapper:not(.e-float-icon-left) textarea.e-input:focus{box-sizing:border-box;margin:8px 0 1px;padding:0 12px 12px}.e-outline.e-input-group input.e-input,.e-outline.e-float-input.e-input-group input,.e-outline.e-input-group.e-control-wrapper input.e-input,.e-outline.e-float-input.e-input-group.e-control-wrapper input,.e-outline.e-float-input input,.e-outline.e-float-input.e-control-wrapper input{box-sizing:border-box;min-height:38px}.e-outline.e-input-group:not(.e-float-icon-left):not(.e-float-input):before,.e-outline.e-input-group:not(.e-float-icon-left):not(.e-float-input):after,.e-outline.e-input-group.e-float-icon-left:not(.e-float-input) .e-input-in-wrap:before,.e-outline.e-input-group.e-float-icon-left:not(.e-float-input) .e-input-in-wrap:after,.e-outline.e-input-group.e-control-wrapper:not(.e-float-icon-left):not(.e-float-input):before,.e-outline.e-input-group.e-control-wrapper:not(.e-float-icon-left):not(.e-float-input):after,.e-outline.e-input-group.e-control-wrapper.e-float-icon-left:not(.e-float-input) .e-input-in-wrap:before,.e-outline.e-input-group.e-control-wrapper.e-float-icon-left:not(.e-float-input) .e-input-in-wrap:after,.e-outline.e-float-input:not(.e-input-group) .e-float-line:before,.e-outline.e-float-input:not(.e-input-group) .e-float-line:after,.e-outline.e-float-input.e-control-wrapper:not(.e-input-group) .e-float-line:before,.e-outline.e-float-input.e-control-wrapper:not(.e-input-group) .e-float-line:after{content:none}.e-outline.e-input-group.e-input-focus:hover:not(.e-success):not(.e-warning):not(.e-error):not(.e-disabled):not(.e-float-icon-left),.e-outline.e-input-group.e-input-focus.e-control-wrapper:hover:not(.e-success):not(.e-warning):not(.e-error):not(.e-disabled):not(.e-float-icon-left),.e-outline.e-float-input.e-input-focus.e-control-wrapper:hover:not(.e-success):not(.e-warning):not(.e-error):not(.e-disabled):not(.e-float-icon-left),.e-outline.e-float-input.e-input-focus:hover:not(.e-success):not(.e-warning):not(.e-error):not(.e-disabled):not(.e-float-icon-left),.e-outline.e-float-input.e-input-focus:hover:not(.e-input-group):not(.e-success):not(.e-warning):not(.e-error):not(.e-disabled),.e-outline.e-float-input.e-input-focus.e-control-wrapper:hover:not(.e-input-group):not(.e-success):not(.e-warning):not(.e-error):not(.e-disabled),.e-outline.e-input-group.e-input-focus:not(.e-success):not(.e-warning):not(.e-error):not(.e-disabled),.e-outline.e-input-group.e-control-wrapper.e-input-focus:not(.e-success):not(.e-warning):not(.e-error):not(.e-disabled),.e-outline.e-float-input.e-input-focus:not(.e-success):not(.e-warning):not(.e-error):not(.e-disabled),.e-outline.e-float-input.e-control-wrapper.e-input-focus:not(.e-success):not(.e-warning):not(.e-error):not(.e-disabled){border-color:#e3165b;box-shadow:inset 1px 1px #e3165b,inset -1px 0 #e3165b,inset 0 -1px #e3165b}.e-outline.e-float-input.e-float-icon-left .e-input-in-wrap,.e-outline.e-float-input.e-control-wrapper.e-float-icon-left .e-input-in-wrap,.e-outline.e-input-group.e-float-icon-left .e-input-in-wrap,.e-outline.e-input-group.e-control-wrapper.e-float-icon-left .e-input-in-wrap{border:0;border-width:0;margin-left:0}.e-outline.e-input-group.e-float-icon-left>.e-input-group-icon,.e-outline.e-float-input.e-input-group.e-float-icon-left>.e-input-group-icon,.e-outline.e-input-group.e-control-wrapper.e-float-icon-left>.e-input-group-icon,.e-outline.e-float-input.e-input-group.e-control-wrapper.e-float-icon-left>.e-input-group-icon{margin-left:4px;margin-right:0}.e-outline.e-input-group.e-rtl.e-float-icon-left>.e-input-group-icon,.e-outline.e-float-input.e-rtl.e-input-group.e-float-icon-left>.e-input-group-icon,.e-outline.e-input-group.e-rtl.e-control-wrapper.e-float-icon-left>.e-input-group-icon,.e-outline.e-float-input.e-input-group.e-rtl.e-control-wrapper.e-float-icon-left>.e-input-group-icon{margin-right:4px;margin-left:0}.e-outline.e-float-input .e-clear-icon,.e-outline.e-float-input.e-control-wrapper .e-clear-icon,.e-outline.e-input-group .e-clear-icon,.e-outline.e-input-group.e-control-wrapper .e-clear-icon{font-size:16px;padding:9px 12px 9px 0}.e-outline.e-input-group.e-float-icon-left .e-input,.e-outline.e-float-input.e-input-group.e-float-icon-left .e-input,.e-outline.e-input-group.e-control-wrapper.e-float-icon-left .e-input,.e-outline.e-float-input.e-input-group.e-control-wrapper.e-float-icon-left .e-input{padding-left:0}.e-outline.e-input-group .e-input-group-icon,.e-outline.e-input-group.e-control-wrapper .e-input-group-icon{font-size:16px;margin:9px 12px 9px 0}.e-outline.e-input-group.e-prepend .e-input-group-icon,.e-outline.e-input-group.e-prepend.e-control-wrapper .e-input-group-icon{font-size:16px;margin:9px 0 9px 12px}.e-outline.e-float-input.e-input-focus:not(.e-input-group):not(.e-float-icon-left):not(.e-success):not(.e-warning):not(.e-error) input,.e-outline.e-float-input.e-input-focus:not(.e-input-group):not(.e-float-icon-left).e-success:not(.e-warning):not(.e-error) input,.e-outline.e-float-input.e-input-focus:not(.e-input-group):not(.e-float-icon-left):not(.e-success).e-warning:not(.e-error) input,.e-outline.e-float-input.e-input-focus:not(.e-input-group):not(.e-float-icon-left):not(.e-success):not(.e-warning).e-error input,.e-outline.e-float-input.e-input-focus:not(.e-input-group):not(.e-float-icon-left):not(.e-disabled):not(.e-success):not(.e-warning):not(.e-error) textarea,.e-outline.e-float-input.e-input-focus:not(.e-input-group):not(.e-float-icon-left):not(.e-disabled).e-success:not(.e-warning):not(.e-error) textarea,.e-outline.e-float-input.e-input-focus:not(.e-input-group):not(.e-float-icon-left):not(.e-disabled):not(.e-success).e-warning:not(.e-error) textarea,.e-outline.e-float-input.e-input-focus:not(.e-input-group):not(.e-float-icon-left):not(.e-disabled):not(.e-success):not(.e-warning).e-error textarea,.e-outline.e-input-group.e-float-icon-left.e-input-focus:not(.e-success):not(.e-warning):not(.e-error) .e-input-in-wrap,.e-outline.e-float-input.e-control-wrapper.e-input-focus:not(.e-input-group):not(.e-float-icon-left):not(.e-success):not(.e-warning):not(.e-error) input,.e-outline.e-float-input.e-control-wrapper.e-input-focus:not(.e-input-group):not(.e-float-icon-left).e-success:not(.e-warning):not(.e-error) input,.e-outline.e-float-input.e-control-wrapper.e-input-focus:not(.e-input-group):not(.e-float-icon-left):not(.e-success).e-warning:not(.e-error) input,.e-outline.e-float-input.e-control-wrapper.e-input-focus:not(.e-input-group):not(.e-float-icon-left):not(.e-success):not(.e-warning).e-error input,.e-outline.e-input-group.e-control-wrapper.e-float-icon-left.e-input-focus:not(.e-success):not(.e-warning):not(.e-error) .e-input-in-wrap{border:0}.e-outline.e-input-group .e-input-group-icon+.e-input-group-icon:last-child,.e-outline.e-input-group.e-small .e-input-group-icon+.e-input-group-icon:last-child,.e-outline.e-input-group.e-control-wrapper .e-input-group-icon+.e-input-group-icon:last-child,.e-outline.e-input-group.e-control-wrapper.e-small .e-input-group-icon+.e-input-group-icon:last-child{margin-left:0}.e-outline.e-input-group.e-small:not(.e-float-input) .e-input,.e-small .e-outline.e-input-group:not(.e-float-input) .e-input,.e-outline.e-input-group.e-control-wrapper.e-small:not(.e-float-input) .e-input,.e-small .e-outline.e-input-group.e-control-wrapper:not(.e-float-input) .e-input,.e-outline.e-float-input.e-small input,.e-small .e-outline.e-float-input input,.e-outline.e-float-input.e-input-group.e-small input,.e-small .e-outline.e-float-input.e-input-group input,.e-outline.e-float-input.e-input-group.e-control-wrapper.e-small input,.e-small .e-outline.e-float-input.e-input-group.e-control-wrapper input,.e-outline.e-float-input.e-control-wrapper.e-small input,.e-small .e-outline.e-float-input.e-control-wrapper input,.e-outline.e-float-input.e-control-wrapper.e-input-group.e-small input,.e-small .e-outline.e-float-input.e-control-wrapper.e-input-group input{box-sizing:border-box;min-height:34px}.e-outline.e-float-input.e-small input:focus~label.e-float-text,.e-outline.e-float-input.e-small input:valid~label.e-float-text,.e-outline.e-float-input.e-small input~label.e-label-top.e-float-text,.e-small .e-outline.e-float-input input~label.e-label-top.e-float-text,.e-outline.e-float-input.e-small input[readonly]~label.e-label-top.e-float-text,.e-outline.e-float-input.e-small input[disabled]~label.e-label-top.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-small input:focus~label.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-small input:valid~label.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-small input~label.e-label-top.e-float-text,.e-small .e-outline.e-float-input.e-control-wrapper input~label.e-label-top.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-small input[readonly]~label.e-label-top.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-small input[disabled]~label.e-label-top.e-float-text,.e-outline.e-float-input.e-small textarea:focus~label.e-float-text,.e-outline.e-float-input.e-small textarea:valid~label.e-float-text,.e-outline.e-float-input.e-small textarea~label.e-label-top.e-float-text,.e-small .e-outline.e-float-input textarea~label.e-label-top.e-float-text,.e-outline.e-float-input.e-small textarea[readonly]~label.e-label-top.e-float-text,.e-outline.e-float-input.e-small textarea[disabled]~label.e-label-top.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-small textarea:focus~label.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-small textarea:valid~label.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-small textarea~label.e-label-top.e-float-text,.e-small .e-outline.e-float-input.e-control-wrapper textarea~label.e-label-top.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-small textarea[readonly]~label.e-label-top.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-small textarea[disabled]~label.e-label-top.e-float-text,.e-outline.e-float-input.e-small.e-input-focus input~label.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-small.e-input-focus input~label.e-float-text{font-size:11px}.e-outline.e-input-group,.e-outline.e-input-group.e-control-wrapper,.e-outline.e-float-input,.e-outline.e-float-input.e-control-wrapper{font-size:14px}.e-outline.e-input-group.e-small,.e-small .e-outline.e-input-group,.e-outline.e-input-group.e-control-wrapper.e-small,.e-small .e-outline.e-input-group.e-control-wrapper,.e-outline.e-float-input.e-small,.e-small .e-outline.e-float-input,.e-outline.e-float-input.e-control-wrapper.e-small,.e-small .e-outline.e-float-input.e-control-wrapper{font-size:13px}input.e-input.e-small.e-outline,.e-small input.e-input.e-outline,.e-input-group.e-small.e-outline input.e-input,.e-outline.e-input-group.e-control-wrapper.e-small input.e-input,.e-outline.e-float-input.e-small input,.e-outline.e-float-input.e-control-wrapper input.e-small,.e-outline.e-input-group input.e-input.e-small,.e-outline.e-input-group.e-control-wrapper input.e-input.e-small,.e-small .e-outline.e-float-input input,.e-small .e-outline.e-float-input.e-control-wrapper input,.e-small .e-outline.e-input-group input.e-input,.e-small .e-outline.e-input-group.e-control-wrapper input.e-input,.e-outline.e-input-group.e-small input.e-input:focus,.e-outline.e-input-group.e-control-wrapper.e-small input.e-input:focus,.e-outline.e-float-input.e-small input:focus,.e-outline.e-float-input.e-control-wrapper.e-small input:focus,.e-small .e-outline.e-input-group.e-control-wrapper input.e-input:focus,.e-small .e-outline.e-input-group input.e-input:focus,.e-small .e-outline.e-float-input input:focus,.e-small .e-outline.e-float-input.e-control-wrapper input:focus,.e-outline.e-float-input.e-small.e-input-focus input,.e-outline.e-float-input.e-control-wrapper.e-small.e-input-focus input,.e-small .e-outline.e-float-input.e-input-focus input,.e-small .e-outline.e-float-input.e-control-wrapper.e-input-focus input,.e-outline.e-input-group.e-small.e-input-focus input.e-input,.e-outline.e-input-group.e-control-wrapper.e-small.e-input-focus input.e-input,.e-small .e-outline.e-input-group.e-control-wrapper.e-input-focus input.e-input,.e-small .e-outline.e-input-group.e-input-focus input.e-input{padding:7px 10px}textarea.e-input.e-small.e-outline,.e-small textarea.e-input.e-outline,.e-input-group.e-small.e-outline textarea.e-input,.e-outline.e-input-group.e-control-wrapper.e-small textarea.e-input,.e-outline.e-float-input.e-control-wrapper textarea.e-small,.e-outline.e-float-input.e-small textarea,.e-outline.e-input-group textarea.e-input.e-small,.e-outline.e-input-group.e-control-wrapper textarea.e-input.e-small,.e-small .e-outline.e-float-input textarea,.e-small .e-outline.e-float-input.e-control-wrapper textarea,.e-small .e-outline.e-input-group textarea.e-input,.e-small .e-outline.e-input-group.e-control-wrapper textarea.e-input,.e-outline.e-input-group.e-small textarea.e-input:focus,.e-outline.e-input-group.e-control-wrapper.e-small textarea.e-input:focus,.e-outline.e-float-input.e-small textarea:focus,.e-outline.e-float-input.e-control-wrapper.e-small textarea:focus,.e-small .e-outline.e-input-group.e-control-wrapper textarea.e-input:focus,.e-small .e-outline.e-input-group textarea.e-input:focus,.e-small .e-outline.e-float-input textarea:focus,.e-small .e-outline.e-float-input.e-control-wrapper textarea:focus{box-sizing:border-box;margin:8px 0 1px;padding:0 10px 10px}.e-outline.e-input-group.e-small.e-float-icon-left>.e-input-group-icon,.e-outline.e-input-group.e-float-icon-left>.e-input-group-icon.e-small,.e-outline.e-input-group.e-control-wrapper.e-small.e-float-icon-left>.e-input-group-icon,.e-outline.e-input-group.e-control-wrapper.e-float-icon-left>.e-input-group-icon.e-small,.e-small .e-outline.e-input-group.e-float-icon-left>.e-input-group-icon,.e-small .e-outline.e-input-group.e-control-wrapper.e-float-icon-left>.e-input-group-icon,.e-outline.e-float-input.e-input-group.e-small.e-float-icon-left>.e-input-group-icon,.e-outline.e-float-input.e-input-group.e-float-icon-left>.e-input-group-icon.e-small,.e-small .e-outline.e-float-input.e-input-group.e-float-icon-left>.e-input-group-icon,.e-outline.e-float-input.e-control-wrapper.e-input-group.e-small.e-float-icon-left>.e-input-group-icon,.e-outline.e-float-input.e-control-wrapper.e-input-group.e-float-icon-left>.e-input-group-icon.e-small,.e-small .e-outline.e-float-input.e-control-wrapper.e-input-group.e-float-icon-left>.e-input-group-icon{margin-left:0;margin-right:6px}.e-outline.e-input-group.e-small .e-input-group-icon,.e-outline.e-input-group.e-control-wrapper.e-small .e-input-group-icon,.e-small .e-outline.e-input-group .e-input-group-icon,.e-small .e-outline.e-input-group.e-control-wrapper .e-input-group-icon{margin-left:0;margin-right:10px}.e-outline.e-input-group.e-prepend.e-small .e-input-group-icon,.e-outline.e-input-group.e-prepend.e-control-wrapper.e-small .e-input-group-icon,.e-small .e-outline.e-input-group.e-prepend .e-input-group-icon,.e-small .e-outline.e-input-group.e-prepend.e-control-wrapper .e-input-group-icon,.e-rtl.e-outline.e-input-group.e-small .e-input-group-icon,.e-rtl .e-outline.e-input-group.e-small .e-input-group-icon,.e-rtl.e-outline.e-input-group.e-control-wrapper.e-small .e-input-group-icon,.e-rtl .e-outline.e-input-group.e-control-wrapper.e-small .e-input-group-icon,.e-small .e-rtl.e-outline.e-input-group .e-input-group-icon,.e-rtl.e-small .e-outline.e-input-group .e-input-group-icon,.e-small .e-rtl.e-outline.e-input-group.e-control-wrapper .e-input-group-icon .e-rtl.e-small .e-outline.e-input-group.e-control-wrapper .e-input-group-icon,.e-rtl.e-outline.e-input-group.e-small .e-input-group-icon+.e-input-group-icon:last-child,.e-rtl .e-outline.e-input-group.e-small .e-input-group-icon+.e-input-group-icon:last-child,.e-rtl .e-outline.e-input-group.e-control-wrapper.e-small .e-input-group-icon+.e-input-group-icon:last-child,.e-rtl.e-outline.e-input-group.e-control-wrapper.e-small .e-input-group-icon+.e-input-group-icon:last-child{margin-left:10px;margin-right:0}.e-outline.e-input-group.e-small .e-clear-icon,.e-outline.e-input-group .e-clear-icon.e-small,.e-small .e-outline.e-input-group .e-clear-icon,.e-outline.e-input-group.e-control-wrapper.e-small .e-clear-icon,.e-outline.e-input-group.e-control-wrapper .e-clear-icon.e-small,.e-small .e-outline.e-input-group.e-control-wrapper .e-clear-icon{font-size:14px;padding:7px 10px 7px 0}.e-outline.e-float-input.e-input-group.e-small .e-input-group-icon,.e-small .e-outline.e-float-input.e-input-group .e-input-group-icon,.e-outline.e-float-input.e-control-wrapper.e-input-group.e-small .e-input-group-icon,.e-small .e-outline.e-float-input.e-control-wrapper.e-input-group .e-input-group-icon{margin-top:9px}.e-outline.e-float-input input,.e-outline.e-float-input textarea,.e-outline.e-float-input.e-control-wrapper input,.e-outline.e-float-input.e-control-wrapper textarea{border:0;border-width:0}.e-outline label.e-float-text,.e-outline.e-float-input label.e-float-text,.e-outline.e-float-input.e-control-wrapper label.e-float-text,.e-outline.e-float-input:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-outline.e-float-input.e-control-wrapper:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-outline.e-float-input.e-small:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small .e-outline.e-float-input:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-outline.e-float-input.e-control-wrapper.e-small:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small .e-outline.e-float-input.e-control-wrapper:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-outline.e-float-input textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-outline.e-float-input.e-control-wrapper textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-outline.e-float-input.e-small textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small .e-outline.e-float-input textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-outline.e-float-input.e-control-wrapper.e-small textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small .e-outline.e-float-input.e-control-wrapper textarea:not(:focus):valid~label.e-float-text.e-label-bottom{box-sizing:border-box;display:flex;left:0;line-height:13px;position:absolute;top:-7px;transform:translateZ(0) scale(1);transition:color .2s,font-size .2s,line-height .2s}.e-outline.e-float-input.e-small:not(.e-error):not(.e-valid-input):not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small .e-outline.e-float-input:not(.e-error):not(.e-valid-input):not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-outline.e-float-input.e-control-wrapper.e-small:not(.e-error):not(.e-valid-input):not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small .e-outline.e-float-input.e-control-wrapper:not(.e-error):not(.e-valid-input):not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small.e-outline:not(.e-valid-input):not(.e-valid-input):not(.e-input-focus) input:not(:focus):not(:valid)~label.e-float-text,.e-small.e-outline.e-float-input:not(.e-valid-input):not(.e-input-focus) input:not(:focus):not(:valid):not(.e-valid-input)~label.e-float-text,.e-small.e-outline.e-float-input.e-control-wrapper:not(.e-valid-input):not(.e-input-focus) input:not(:focus):not(:valid):not(.e-valid-input)~label.e-float-text{line-height:46px}.e-outline.e-float-input.e-small:not(.e-error):not(.e-valid-input):not(.e-input-focus) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small .e-outline.e-float-input:not(.e-error):not(.e-valid-input):not(.e-input-focus) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-outline.e-float-input.e-control-wrapper.e-small:not(.e-error):not(.e-valid-input):not(.e-input-focus) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small .e-outline.e-float-input.e-control-wrapper:not(.e-error):not(.e-valid-input):not(.e-input-focus) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small.e-outline.e-float-input:not(.e-valid-input):not(.e-input-focus) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small.e-outline.e-float-input.e-control-wrapper:not(.e-valid-input):not(.e-input-focus) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small.e-outline.e-float-input:not(.e-valid-input):not(.e-input-focus) textarea:valid~label.e-float-text.e-label-bottom,.e-small.e-outline.e-float-input.e-control-wrapper:not(.e-valid-input):not(.e-input-focus) textarea:valid~label.e-float-text.e-label-bottom,.e-small .e-outline.e-float-input:not(.e-valid-input):not(.e-input-focus) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small .e-outline.e-float-input.e-control-wrapper:not(.e-valid-input):not(.e-input-focus) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small .e-outline.e-float-input:not(.e-valid-input):not(.e-input-focus) textarea:valid~label.e-float-text.e-label-bottom,.e-small .e-outline.e-float-input.e-control-wrapper:not(.e-valid-input):not(.e-input-focus) textarea:valid~label.e-float-text.e-label-bottom,.e-small.e-outline:not(.e-valid-input):not(.e-valid-input):not(.e-input-focus) textarea:not(:focus):not(:valid)~label.e-float-text,.e-small.e-outline.e-float-input:not(.e-valid-input):not(.e-input-focus) textarea:not(:focus):not(:valid):not(.e-valid-input)~label.e-float-text,.e-small.e-outline.e-float-input.e-control-wrapper:not(.e-valid-input):not(.e-input-focus) textarea:not(:focus):not(:valid):not(.e-valid-input)~label.e-float-text,.e-outline.e-float-input.e-small:not(.e-error):not(.e-valid-input) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small .e-outline.e-float-input:not(.e-error):not(.e-valid-input) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-outline.e-float-input.e-control-wrapper.e-small:not(.e-error):not(.e-valid-input) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small .e-outline.e-float-input.e-control-wrapper:not(.e-error):not(.e-valid-input) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small.e-outline:not(.e-valid-input):not(.e-valid-input) textarea:not(:focus):not(:valid)~label.e-float-text,.e-small.e-outline.e-float-input:not(.e-valid-input) textarea:not(:focus):not(:valid):not(.e-valid-input)~label.e-float-text,.e-small.e-outline.e-float-input.e-control-wrapper:not(.e-valid-input) textarea:not(:focus):not(:valid):not(.e-valid-input)~label.e-float-text{line-height:60px}.e-outline.e-float-input:not(.e-valid-input):not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-outline.e-float-input.e-control-wrapper:not(.e-valid-input):not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-outline.e-float-input:not(.e-valid-input):not(.e-input-focus) input:valid~label.e-float-text.e-label-bottom,.e-outline.e-float-input.e-control-wrapper:not(.e-valid-input):not(.e-input-focus) input:valid~label.e-float-text.e-label-bottom,.e-outline:not(.e-valid-input):not(.e-valid-input):not(.e-input-focus) input:not(:focus):not(:valid)~label.e-float-text,.e-outline.e-float-input:not(.e-valid-input):not(.e-input-focus) input:not(:focus):not(:valid):not(.e-valid-input)~label.e-float-text,.e-outline.e-float-input.e-control-wrapper:not(.e-valid-input):not(.e-input-focus) input:not(:focus):not(:valid):not(.e-valid-input)~label.e-float-text{line-height:54px}.e-outline.e-float-input:not(.e-valid-input):not(.e-input-focus) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-outline.e-float-input.e-control-wrapper:not(.e-valid-input):not(.e-input-focus) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-outline.e-float-input:not(.e-valid-input):not(.e-input-focus) textarea:valid~label.e-float-text.e-label-bottom,.e-outline.e-float-input.e-control-wrapper:not(.e-valid-input):not(.e-input-focus) textarea:valid~label.e-float-text.e-label-bottom,.e-outline:not(.e-valid-input):not(.e-valid-input):not(.e-input-focus) textarea:not(:focus):not(:valid)~label.e-float-text,.e-outline.e-float-input:not(.e-valid-input):not(.e-input-focus) textarea:not(:focus):not(:valid):not(.e-valid-input)~label.e-float-text,.e-outline.e-float-input.e-control-wrapper:not(.e-valid-input):not(.e-input-focus) textarea:not(:focus):not(:valid):not(.e-valid-input)~label.e-float-text,.e-outline.e-float-input:not(.e-error):not(.e-valid-input) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-outline.e-float-input.e-control-wrapper:not(.e-error):not(.e-valid-input) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-outline:not(.e-valid-input):not(.e-valid-input) textarea:not(:focus):not(:valid)~label.e-float-text,.e-outline.e-float-input:not(.e-valid-input) textarea:not(:focus):not(:valid):not(.e-valid-input)~label.e-float-text,.e-outline.e-float-input.e-control-wrapper:not(.e-valid-input) textarea:not(:focus):not(:valid):not(.e-valid-input)~label.e-float-text{line-height:50px}.e-outline label.e-float-text:before,.e-outline label.e-float-text:after,.e-outline.e-float-input label.e-float-text:before,.e-outline.e-float-input label.e-float-text:after,.e-outline.e-float-input.e-control-wrapper label.e-float-text:before,.e-outline.e-float-input.e-control-wrapper label.e-float-text:after{border-top:solid 2px;border-top-color:transparent;box-shadow:inset 0 1px transparent;box-sizing:border-box;content:" ";display:block;height:8px;margin-top:6px;min-width:9px;pointer-events:none;position:relative;transition:border-color .1s,box-shadow .2s}.e-outline.e-float-icon-left label.e-float-text:before,.e-outline.e-float-icon-left label.e-float-text:after,.e-outline.e-float-input.e-float-icon-left label.e-float-text:before,.e-outline.e-float-input.e-float-icon-left label.e-float-text:after,.e-outline.e-float-input.e-control-wrapper.e-float-icon-left label.e-float-text:before,.e-outline.e-float-input.e-control-wrapper.e-float-icon-left label.e-float-text:after{transition:none}.e-small.e-outline label.e-float-text:before,.e-small.e-outline label.e-float-text:after,.e-small.e-outline.e-float-input label.e-float-text:before,.e-small.e-outline.e-float-input label.e-float-text:after,.e-small.e-outline.e-float-input.e-control-wrapper label.e-float-text:before,.e-small.e-outline.e-float-input.e-control-wrapper label.e-float-text:after,.e-small .e-outline label.e-float-text:before,.e-small .e-outline label.e-float-text:after,.e-small .e-outline.e-float-input label.e-float-text:before,.e-small .e-outline.e-float-input label.e-float-text:after,.e-small .e-outline.e-float-input.e-control-wrapper label.e-float-text:before,.e-small .e-outline.e-float-input.e-control-wrapper label.e-float-text:after{min-width:7px}.e-outline.e-valid-input:not(.e-input-focus) label.e-float-text:before,.e-outline.e-valid-input:not(.e-input-focus) label.e-float-text:after,.e-outline.e-float-input.e-valid-input:not(.e-input-focus) label.e-float-text:before,.e-outline.e-float-input.e-valid-input:not(.e-input-focus) label.e-float-text:after,.e-outline.e-float-input.e-control-wrapper.e-valid-input:not(.e-input-focus) label.e-float-text:before,.e-outline.e-float-input.e-control-wrapper.e-valid-input:not(.e-input-focus) label.e-float-text:after{border-top-color:#0000003d;border-width:1px}.e-outline.e-valid-input.e-success:not(.e-error):not(.e-warning):not(.e-input-focus) label.e-float-text:before,.e-outline.e-valid-input.e-success:not(.e-error):not(.e-warning):not(.e-input-focus) label.e-float-text:after,.e-outline.e-float-input.e-valid-input.e-success:not(.e-error):not(.e-warning):not(.e-input-focus) label.e-float-text:before,.e-outline.e-float-input.e-valid-input.e-success:not(.e-error):not(.e-warning):not(.e-input-focus) label.e-float-text:after,.e-outline.e-float-input.e-control-wrapper.e-valid-input.e-success:not(.e-error):not(.e-warning):not(.e-input-focus) label.e-float-text:before,.e-outline.e-float-input.e-control-wrapper.e-valid-input.e-success:not(.e-error):not(.e-warning):not(.e-input-focus) label.e-float-text:after{border-top-color:#22b24b}.e-outline.e-success.e-input-focus:not(.e-error):not(.e-warning) label.e-float-text:before,.e-outline.e-success.e-input-focus:not(.e-error):not(.e-warning) label.e-float-text:after,.e-outline.e-float-input.e-success.e-input-focus:not(.e-error):not(.e-warning) label.e-float-text:before,.e-outline.e-float-input.e-success.e-input-focus:not(.e-error):not(.e-warning) label.e-float-text:after,.e-outline.e-float-input.e-control-wrapper.e-success.e-input-focus:not(.e-error):not(.e-warning) label.e-float-text:before,.e-outline.e-float-input.e-control-wrapper.e-success.e-input-focus:not(.e-error):not(.e-warning) label.e-float-text:after{border-color:#22b24b}.e-outline.e-valid-input.e-error:not(.e-success):not(.e-warning):not(.e-input-focus) label.e-float-text:before,.e-outline.e-valid-input.e-error:not(.e-success):not(.e-warning):not(.e-input-focus) label.e-float-text:after,.e-outline.e-float-input.e-valid-input.e-error:not(.e-success):not(.e-warning):not(.e-input-focus) label.e-float-text:before,.e-outline.e-float-input.e-valid-input.e-error:not(.e-success):not(.e-warning):not(.e-input-focus) label.e-float-text:after,.e-outline.e-float-input.e-control-wrapper.e-valid-input.e-error:not(.e-success):not(.e-warning):not(.e-input-focus) label.e-float-text:before,.e-outline.e-float-input.e-control-wrapper.e-valid-input.e-error:not(.e-success):not(.e-warning):not(.e-input-focus) label.e-float-text:after{border-top-color:#f44336}.e-outline.e-error.e-input-focus:not(.e-success):not(.e-warning) label.e-float-text:before,.e-outline.e-error.e-input-focus:not(.e-success):not(.e-warning) label.e-float-text:after,.e-outline.e-float-input.e-error.e-input-focus:not(.e-success):not(.e-warning) label.e-float-text:before,.e-outline.e-float-input.e-error.e-input-focus:not(.e-success):not(.e-warning) label.e-float-text:after,.e-outline.e-float-input.e-control-wrapper.e-error.e-input-focus:not(.e-success):not(.e-warning) label.e-float-text:before,.e-outline.e-float-input.e-control-wrapper.e-error.e-input-focus:not(.e-success):not(.e-warning) label.e-float-text:after{border-color:#f44336}.e-outline.e-valid-input.e-warning:not(.e-success):not(.e-error):not(.e-input-focus) label.e-float-text:before,.e-outline.e-valid-input.e-warning:not(.e-success):not(.e-error):not(.e-input-focus) label.e-float-text:after,.e-outline.e-float-input.e-valid-input.e-warning:not(.e-success):not(.e-error):not(.e-input-focus) label.e-float-text:before,.e-outline.e-float-input.e-valid-input.e-warning:not(.e-success):not(.e-error):not(.e-input-focus) label.e-float-text:after,.e-outline.e-float-input.e-control-wrapper.e-valid-input.e-warning:not(.e-success):not(.e-error):not(.e-input-focus) label.e-float-text:before,.e-outline.e-float-input.e-control-wrapper.e-valid-input.e-warning:not(.e-success):not(.e-error):not(.e-input-focus) label.e-float-text:after{border-top-color:#ffca1c}.e-outline.e-warning.e-input-focus:not(.e-success):not(.e-error) label.e-float-text:before,.e-outline.e-warning.e-input-focus:not(.e-success):not(.e-error) label.e-float-text:after,.e-outline.e-float-input.e-warning.e-input-focus:not(.e-success):not(.e-error) label.e-float-text:before,.e-outline.e-float-input.e-warning.e-input-focus:not(.e-success):not(.e-error) label.e-float-text:after,.e-outline.e-float-input.e-control-wrapper.e-warning.e-input-focus:not(.e-success):not(.e-error) label.e-float-text:before,.e-outline.e-float-input.e-control-wrapper.e-warning.e-input-focus:not(.e-success):not(.e-error) label.e-float-text:after{border-color:#ffca1c}.e-outline label.e-float-text:before,.e-outline.e-float-input label.e-float-text:before,.e-outline.e-float-input.e-control-wrapper label.e-float-text:before{border-left:solid 1px transparent;border-radius:4px 0;left:-1px;margin-right:4px}.e-rtl.e-outline label.e-float-text:before,.e-rtl.e-outline.e-float-input label.e-float-text:before,.e-rtl.e-outline.e-float-input.e-control-wrapper label.e-float-text:before{border-left:0;border-radius:0 4px;left:5px}.e-rtl.e-outline label.e-float-text:after,.e-rtl.e-outline.e-float-input label.e-float-text:after,.e-rtl.e-outline.e-float-input.e-control-wrapper label.e-float-text:after{border-radius:5px 0;border-right:0;left:-6px}.e-outline label.e-float-text:after,.e-outline.e-float-input label.e-float-text:after,.e-outline.e-float-input.e-control-wrapper label.e-float-text:after{border-radius:0 5px;border-right:solid 1px transparent;flex-grow:1;left:2px;margin-left:4px}.e-outline.e-input-focus label.e-float-text:before,.e-outline.e-input-focus label.e-float-text:after,.e-outline.e-float-input.e-input-focus label.e-float-text:before,.e-outline.e-float-input.e-input-focus label.e-float-text:after,.e-outline.e-float-input.e-control-wrapper.e-input-focus label.e-float-text:before,.e-outline.e-float-input.e-control-wrapper.e-input-focus label.e-float-text:after{border-top-color:#e3165b}.e-outline.e-float-input.e-input-focus:not(.e-error):not(.e-success):not(.e-warning):not(.e-disabled),.e-outline.e-float-input.e-input-focus:not(.e-error):not(.e-success):not(.e-warning):not(.e-disabled):not(.e-float-icon-left),.e-outline.e-float-input.e-input-group.e-input-focus:not(.e-error):not(.e-success):not(.e-warning):not(.e-disabled):not(.e-float-icon-left),.e-outline.e-float-input.e-input-group.e-input-focus:not(.e-error):not(.e-success):not(.e-warning):not(.e-disabled),.e-outline.e-float-input.e-control-wrapper.e-input-focus:not(.e-error):not(.e-success):not(.e-warning):not(.e-disabled):not(.e-float-icon-left),.e-outline.e-float-input.e-control-wrapper.e-input-focus:not(.e-error):not(.e-success):not(.e-warning):not(.e-disabled),.e-outline.e-float-input.e-input-focus:hover:not(.e-error):not(.e-success):not(.e-warning):not(.e-disabled),.e-outline.e-float-input.e-input-group.e-input-focus:hover:not(.e-error):not(.e-success):not(.e-warning):not(.e-disabled),.e-outline.e-float-input.e-control-wrapper.e-input-focus:hover:not(.e-error):not(.e-success):not(.e-warning):not(.e-disabled),.e-outline.e-float-input.e-input-focus:hover:not(.e-error):not(.e-success):not(.e-warning):not(.e-disabled):not(.e-float-icon-left),.e-outline.e-float-input.e-input-group.e-input-focus:hover:not(.e-error):not(.e-success):not(.e-warning):not(.e-disabled):not(.e-float-icon-left),.e-outline.e-float-input.e-control-wrapper.e-input-focus:hover:not(.e-error):not(.e-success):not(.e-warning):not(.e-disabled):not(.e-float-icon-left){border-top-color:transparent;box-shadow:inset 1px 0 #e3165b,inset -1px 0 #e3165b,inset 0 -1px #e3165b}.e-outline.e-float-input input:focus~label.e-float-text,.e-outline.e-float-input input:valid~label.e-float-text,.e-outline.e-float-input input~label.e-label-top.e-float-text,.e-outline.e-float-input input[readonly]~label.e-label-top.e-float-text,.e-outline.e-float-input input[disabled]~label.e-label-top.e-float-text,.e-outline.e-float-input input label.e-float-text.e-label-top,.e-outline.e-float-input.e-control-wrapper input:focus~label.e-float-text,.e-outline.e-float-input.e-control-wrapper input:valid~label.e-float-text,.e-outline.e-float-input.e-control-wrapper input~label.e-label-top.e-float-text,.e-outline.e-float-input.e-control-wrapper input[readonly]~label.e-label-top.e-float-text,.e-outline.e-float-input.e-control-wrapper input[disabled]~label.e-label-top.e-float-text,.e-outline.e-float-input.e-control-wrapper input label.e-float-text.e-label-top,.e-outline.e-float-input textarea:focus~label.e-float-text,.e-outline.e-float-input textarea:valid~label.e-float-text,.e-outline.e-float-input textarea~label.e-label-top.e-float-text,.e-outline.e-float-input textarea[readonly]~label.e-label-top.e-float-text,.e-outline.e-float-input textarea[disabled]~label.e-label-top.e-float-text,.e-outline.e-float-input textarea label.e-float-text.e-label-top,.e-outline.e-float-input.e-control-wrapper textarea:focus~label.e-float-text,.e-outline.e-float-input.e-control-wrapper textarea:valid~label.e-float-text,.e-outline.e-float-input.e-control-wrapper textarea~label.e-label-top.e-float-text,.e-outline.e-float-input.e-control-wrapper textarea[readonly]~label.e-label-top.e-float-text,.e-outline.e-float-input.e-control-wrapper textarea[disabled]~label.e-label-top.e-float-text,.e-outline.e-float-input.e-control-wrapper textarea label.e-float-text.e-label-top,.e-outline.e-float-input.e-input-focus input~label.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-input-focus input~label.e-float-text{font-size:12px;top:-7px;transform:translateZ(0) scale(1)}.e-outline.e-float-input.e-rtl .e-clear-icon,.e-rtl .e-outline.e-float-input .e-clear-icon,.e-outline.e-float-input.e-control-wrapper.e-rtl .e-clear-icon,e-rtl .e-outline.e-float-input.e-control-wrapper .e-clear-icon,.e-outline.e-input-group.e-rtl .e-clear-icon,.e-rtl .e-outline.e-input-group .e-clear-icon,.e-outline.e-input-group.e-control-wrapper.e-rtl .e-clear-icon,.e-rtl .e-outline.e-input-group.e-control-wrapper.e-rtl .e-clear-icon{padding-left:12px;padding-right:0}.e-rtl .e-outline.e-input-group .e-input-group-icon+.e-input-group-icon:last-child,.e-rtl.e-outline.e-input-group .e-input-group-icon+.e-input-group-icon:last-child,.e-rtl.e-outline.e-input-group.e-small .e-input-group-icon+.e-input-group-icon:last-child,.e-rtl .e-outline.e-input-group.e-small .e-input-group-icon+.e-input-group-icon:last-child,.e-rtl .e-outline.e-input-group.e-control-wrapper .e-input-group-icon+.e-input-group-icon:last-child,.e-rtl.e-outline.e-input-group.e-control-wrapper .e-input-group-icon+.e-input-group-icon:last-child,.e-rtl .e-outline.e-input-group.e-control-wrapper.e-small .e-input-group-icon+.e-input-group-icon:last-child,.e-rtl.e-outline.e-input-group.e-control-wrapper.e-small .e-input-group-icon+.e-input-group-icon:last-child,.e-outline.e-float-input.e-rtl.e-float-icon-left .e-input-in-wrap,.e-outline.e-float-input.e-rtl.e-control-wrapper.e-float-icon-left .e-input-in-wrap,.e-outline.e-input-group.e-rtl.e-float-icon-left .e-input-in-wrap,.e-outline.e-input-group.e-rtl.e-control-wrapper.e-float-icon-left .e-input-in-wrap{margin-right:0}.e-rtl .e-outline.e-input-group .e-input-group-icon+.e-input-group-icon:last-child,.e-rtl.e-outline.e-input-group .e-input-group-icon+.e-input-group-icon:last-child{margin-left:12px}.e-rtl.e-outline.e-input-group .e-input-group-icon,.e-rtl .e-outline.e-input-group .e-input-group-icon,.e-rtl.e-outline.e-input-group.e-control-wrapper .e-input-group-icon .e-rtl .e-outline.e-input-group.e-control-wrapper .e-input-group-icon{margin-left:12px;margin-right:0}.e-rtl.e-outline.e-input-group.e-small .e-clear-icon,.e-rtl .e-outline.e-input-group.e-small .e-clear-icon,.e-rtl.e-outline.e-input-group .e-clear-icon.e-small,.e-rtl .e-outline.e-input-group .e-clear-icon.e-small,.e-rtl.e-small .e-outline.e-input-group .e-clear-icon,.e-small .e-rtl.e-outline.e-input-group .e-clear-icon,.e-rtl.e-outline.e-input-group.e-control-wrapper.e-small .e-clear-icon,.e-rtl .e-outline.e-input-group.e-control-wrapper.e-small .e-clear-icon,.e-rtl .e-outline.e-input-group.e-control-wrapper .e-clear-icon.e-small,.e-small .e-rtl.e-outline.e-input-group.e-control-wrapper .e-clear-icon .e-rtl.e-small .e-outline.e-input-group.e-control-wrapper .e-clear-icon{padding-left:10px;padding-right:0}.e-rtl .e-outline.e-input-group .e-input-group-icon+.e-input-group-icon:last-child,.e-rtl.e-outline.e-input-group .e-input-group-icon+.e-input-group-icon:last-child,.e-rtl .e-outline.e-input-group.e-control-wrapper .e-input-group-icon+.e-input-group-icon:last-child,.e-rtl.e-outline.e-input-group.e-control-wrapper .e-input-group-icon+.e-input-group-icon:last-child{margin-left:12px;margin-right:0}.e-outline.e-float-input textarea:focus~label.e-float-text,.e-outline.e-float-input textarea:valid~label.e-float-text,.e-outline.e-float-input textarea~label.e-label-top.e-float-text,.e-outline.e-float-input textarea[readonly]~label.e-label-top.e-float-text,.e-outline.e-float-input textarea[disabled]~label.e-label-top.e-float-text,.e-outline.e-float-input textarea label.e-float-text.e-label-top,.e-outline.e-float-input.e-control-wrapper textarea:focus~label.e-float-text,.e-outline.e-float-input.e-control-wrapper textarea:valid~label.e-float-text,.e-outline.e-float-input.e-control-wrapper textarea~label.e-label-top.e-float-text,.e-outline.e-float-input.e-control-wrapper textarea[readonly]~label.e-label-top.e-float-text,.e-outline.e-float-input.e-control-wrapper textarea[disabled]~label.e-label-top.e-float-text,.e-outline.e-float-input.e-control-wrapper textarea label.e-float-text.e-label-top{top:-7px;transform:translateZ(0) scale(1)}.e-outline textarea,textarea.e-outline,.e-outline.e-float-input textarea,.e-outline.e-float-input.e-control-wrapper textarea,.e-outline.e-float-input.e-input-group textarea{box-sizing:border-box}.e-outline.e-float-input.e-valid-input:not(.e-input-focus) input:valid~label.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-valid-input:not(.e-input-focus) input:focus~label.e-float-text,.e-outline.e-float-input.e-valid-input:not(.e-input-focus) textarea:valid~label.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-valid-input:not(.e-input-focus) textarea:focus~label.e-float-text{color:#0009}.e-rtl.e-outline.e-float-input.e-small textarea~label.e-float-text,.e-rtl.e-outline.e-float-input textarea~label.e-float-text.e-small,.e-rtl.e-outline.e-float-input textarea.e-small~label.e-float-text,.e-small .e-rtl.e-outline.e-float-input textarea~label.e-float-text,.e-rtl.e-outline.e-float-input.e-control-wrapper.e-small textarea~label.e-float-text,.e-rtl.e-outline.e-float-input.e-control-wrapper textarea~label.e-float-text.e-small,.e-rtl.e-outline.e-float-input.e-control-wrapper textarea.e-small~label.e-float-text,.e-small .e-rtl.e-outline.e-float-input.e-control-wrapper textarea~label.e-float-text{top:-7px}.e-outline.e-float-input.e-small .e-clear-icon:before,.e-outline.e-float-input.e-control-wrapper.e-small .e-clear-icon:before,.e-outline.e-input-group.e-small .e-clear-icon:before,.e-outline.e-input-group.e-control-wrapper.e-small .e-clear-icon:before,.e-outline.e-float-input.e-control-wrapper input.e-small:first-child~.e-clear-icon:before,.e-outline.e-small .e-float-input.e-control-wrapper .e-clear-icon:before,.e-outline.e-float-input input.e-small:first-child~.e-clear-icon:before,.e-outline.e-small .e-float-input .e-clear-icon:before,.e-outline.e-small .e-input-group .e-clear-icon:before,.e-outline.e-small .e-input-group.e-control-wrapper .e-clear-icon:before{font-size:14px}.e-outline.e-float-input .e-clear-icon:before,.e-outline.e-float-input.e-control-wrapper .e-clear-icon:before,.e-outline.e-input-group .e-clear-icon:before,.e-outline.e-input-group.e-control-wrapper .e-clear-icon:before{font-size:16px}.e-outline.e-float-input textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-outline.e-float-input.e-control-wrapper textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-outline label.e-float-text,.e-outline.e-float-input label.e-float-text,.e-outline.e-float-input.e-control-wrapper label.e-float-text,.e-outline.e-float-input:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-outline.e-float-input.e-control-wrapper:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-outline.e-float-input textarea:-webkit-autofill~label.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-autofill textarea:-webkit-autofill~label.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-autofill textarea:not(:focus):valid:-webkit-autofill~label.e-float-text.e-label-bottom{font-size:14px}.e-outline.e-float-input.e-small textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small .e-outline.e-float-input textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-outline.e-float-input.e-control-wrapper.e-small textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small .e-outline.e-float-input.e-control-wrapper textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small .e-outline.e-float-input textarea:-webkit-autofill~label.e-float-text,.e-small.e-outline.e-float-input textarea:-webkit-autofill~label.e-float-text,.e-small .e-outline.e-float-input.e-control-wrapper.e-autofill textarea:-webkit-autofill~label.e-float-text,.e-small.e-outline.e-float-input.e-control-wrapper.e-autofill textarea:-webkit-autofill~label.e-float-text,.e-small .e-outline.e-float-input.e-control-wrapper.e-autofill textarea:not(:focus):valid:-webkit-autofill~label.e-float-text.e-label-bottom,.e-small.e-outline.e-float-input.e-control-wrapper.e-autofill textarea:not(:focus):valid:-webkit-autofill~label.e-float-text.e-label-bottom,.e-outline.e-float-input.e-small label.e-float-text,.e-outline.e-float-input.e-small:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small .e-outline.e-float-input:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-outline.e-float-input.e-control-wrapper.e-small label.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-small:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small .e-outline.e-float-input.e-control-wrapper:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-outline.e-float-input.e-small textarea~label.e-float-text,.e-outline.e-float-input textarea~label.e-float-text.e-small,.e-outline.e-float-input textarea.e-small~label.e-float-text,.e-small .e-outline.e-float-input textarea~label.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-small textarea~label.e-float-text,.e-outline.e-float-input.e-control-wrapper textarea~label.e-float-text.e-small,.e-outline.e-float-input.e-control-wrapper textarea.e-small~label.e-float-text,.e-small .e-outline.e-float-input.e-control-wrapper textarea~label.e-float-text{font-size:13px}.e-outline.e-float-input input:-webkit-autofill~label.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-autofill input:-webkit-autofill~label.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-autofill:not(.e-input-focus) input:not(:focus):valid:-webkit-autofill~label.e-float-text.e-label-bottom{animation-name:slideTopUp}.e-small .e-outline.e-float-input input:-webkit-autofill~label.e-float-text,.e-small.e-outline.e-float-input input:-webkit-autofill~label.e-float-text,.e-small .e-outline.e-float-input.e-control-wrapper.e-autofill input:-webkit-autofill~label.e-float-text,.e-small.e-outline.e-float-input.e-control-wrapper.e-autofill input:-webkit-autofill~label.e-float-text,.e-small .e-outline.e-float-input.e-control-wrapper.e-autofill:not(.e-input-focus) input:not(:focus):valid:-webkit-autofill~label.e-float-text.e-label-bottom,.e-small.e-outline.e-float-input.e-control-wrapper.e-autofill:not(.e-input-focus) input:not(:focus):valid:-webkit-autofill~label.e-float-text.e-label-bottom{animation-name:slideTopUp}.e-filled.e-input-group,.e-filled.e-input-group.e-control-wrapper,.e-filled.e-float-input,.e-filled.e-float-input.e-control-wrapper{line-height:1}.e-filled input.e-input,.e-filled.e-input-group input,.e-filled.e-input-group.e-control-wrapper input,.e-filled.e-input-group input.e-input,.e-filled.e-input-group.e-control-wrapper input.e-input,.e-filled.e-float-input:not(.e-input-group) input,.e-filled.e-float-input.e-control-wrapper:not(.e-input-group) input,.e-control .e-filled input.e-input,.e-control .e-filled.e-input-group input,.e-control .e-filled.e-input-group input.e-input,.e-control .e-filled.e-input-group.e-control-wrapper input,.e-control .e-filled.e-input-group.e-control-wrapper input.e-input,.e-control .e-filled.e-float-input input,.e-control .e-filled.e-float-input.e-control-wrapper input,.e-control.e-filled.e-input-group input,.e-control.e-filled.e-input-group input.e-input,.e-control.e-filled.e-input-group.e-control-wrapper input,.e-control.e-filled.e-input-group.e-control-wrapper input.e-input,.e-control.e-filled.e-float-input input,.e-control.e-filled.e-float-input.e-control-wrapper input,.e-filled input.e-input.e-small,.e-filled.e-input-group.e-small input,.e-filled.e-input-group.e-small input.e-input,.e-small .e-filled.e-input-group input,.e-small .e-filled.e-input-group input.e-input,.e-filled.e-input-group.e-control-wrapper.e-small input,.e-filled.e-input-group.e-control-wrapper.e-small input.e-input,.e-small .e-filled.e-input-group.e-control-wrapper input,.e-small .e-filled.e-input-group.e-control-wrapper input.e-input,.e-filled.e-float-input.e-small input,.e-filled.e-float-input.e-small input.e-input,.e-small .e-filled.e-float-input input,.e-small .e-filled.e-float-input input.e-input,.e-filled.e-float-input.e-control-wrapper.e-small input,.e-filled.e-float-input.e-control-wrapper.e-small input.e-input,.e-small .e-filled.e-float-input.e-control-wrapper input,.e-small .e-filled.e-float-input.e-control-wrapper input.e-input,.e-filled.e-float-input.e-small:not(.e-input-group) input,.e-filled.e-float-input.e-small:not(.e-input-group) input.e-input,.e-small .e-filled.e-float-input:not(.e-input-group) input,.e-small .e-filled.e-float-input:not(.e-input-group) input.e-input .e-filled.e-float-input.e-control-wrapper.e-small:not(.e-input-group) input,.e-filled.e-float-input.e-control-wrapper.e-small:not(.e-input-group) input.e-input,.e-small .e-filled.e-float-input.e-control-wrapper:not(.e-input-group) input,.e-small .e-filled.e-float-input.e-control-wrapper:not(.e-input-group) input.e-input,.e-filled textarea.e-input,.e-filled.e-input-group textarea,.e-filled.e-input-group.e-control-wrapper textarea,.e-filled.e-float-input textarea,.e-filled.e-float-input.e-control-wrapper textarea,.e-filled textarea.e-input.e-small,.e-filled.e-input-group.e-small textarea,.e-filled.e-input-group.e-small textarea.e-input,.e-small .e-filled.e-input-group textarea,.e-small .e-filled.e-input-group textarea.e-input,.e-filled.e-input-group.e-control-wrapper.e-small textarea,.e-filled.e-input-group.e-control-wrapper.e-small textarea.e-input,.e-small .e-filled.e-input-group.e-control-wrapper textarea,.e-small .e-filled.e-input-group.e-control-wrapper textarea.e-input,.e-filled.e-float-input.e-small textarea,.e-filled.e-float-input.e-small textarea.e-input,.e-small .e-filled.e-float-input textarea,.e-small .e-filled.e-float-input textarea.e-input,.e-filled.e-float-input.e-control-wrapper.e-small textarea,.e-filled.e-float-input.e-control-wrapper.e-small textarea.e-input,.e-small .e-filled.e-float-input.e-control-wrapper textarea,.e-small .e-filled.e-float-input.e-control-wrapper textarea.e-input{box-sizing:border-box}.e-filled.e-float-input input,.e-filled.e-float-input textarea,.e-filled.e-float-input.e-control-wrapper input,.e-filled.e-float-input.e-control-wrapper textarea{border:0 solid;border-width:0}.e-filled.e-float-input:hover:not(.e-input-group):not(.e-disabled) input:not([disabled]),.e-filled.e-float-input:hover:not(.e-input-group):not(.e-disabled) textarea:not([disabled]),.e-filled.e-float-input.e-control-wrapper:hover:not(.e-input-group):not(.e-disabled) input:not([disabled]),.e-filled.e-float-input.e-control-wrapper:hover:not(.e-input-group):not(.e-disabled) textarea:not([disabled]),.e-filled.e-input-group.e-float-icon-left:not(.e-disabled):not(.e-input-focus) .e-input-in-wrap:hover,.e-filled.e-input-group.e-control-wrapper.e-float-icon-left:not(.e-disabled):not(.e-input-focus) .e-input-in-wrap:hover,.e-filled.e-float-input.e-float-icon-left:not(.e-disabled):not(.e-input-focus) .e-input-in-wrap:hover,.e-filled.e-float-input.e-control-wrapper.e-float-icon-left:not(.e-disabled):not(.e-input-focus) .e-input-in-wrap:hover{border-bottom-width:0}.e-filled.e-float-input.e-control-wrapper.e-input-focus:not(.e-input-group):not(.e-float-icon-left):not(.e-disabled):not(.e-success):not(.e-warning):not(.e-error) input,.e-filled.e-float-input.e-control-wrapper.e-input-focus:not(.e-input-group):not(.e-float-icon-left):not(.e-disabled).e-success:not(.e-warning):not(.e-error) input,.e-filled.e-float-input.e-control-wrapper.e-input-focus:not(.e-input-group):not(.e-float-icon-left):not(.e-disabled):not(.e-success).e-warning:not(.e-error) input,.e-filled.e-float-input.e-control-wrapper.e-input-focus:not(.e-input-group):not(.e-float-icon-left):not(.e-disabled):not(.e-success):not(.e-warning).e-error input,.e-filled.e-float-input.e-control-wrapper.e-input-focus:not(.e-input-group):not(.e-float-icon-left):not(.e-disabled):not(.e-success):not(.e-warning):not(.e-error) textarea,.e-filled.e-float-input.e-control-wrapper.e-input-focus:not(.e-input-group):not(.e-float-icon-left):not(.e-disabled).e-success:not(.e-warning):not(.e-error) textarea,.e-filled.e-float-input.e-control-wrapper.e-input-focus:not(.e-input-group):not(.e-float-icon-left):not(.e-disabled):not(.e-success).e-warning:not(.e-error) textarea,.e-filled.e-float-input.e-control-wrapper.e-input-focus:not(.e-input-group):not(.e-float-icon-left):not(.e-disabled):not(.e-success):not(.e-warning).e-error textarea,.e-filled.e-float-input.e-input-focus:not(.e-input-group):not(.e-float-icon-left):not(.e-disabled):not(.e-success):not(.e-warning):not(.e-error) input,.e-filled.e-float-input.e-input-focus:not(.e-input-group):not(.e-float-icon-left):not(.e-disabled).e-success:not(.e-warning):not(.e-error) input,.e-filled.e-float-input.e-input-focus:not(.e-input-group):not(.e-float-icon-left):not(.e-disabled):not(.e-success).e-warning:not(.e-error) input,.e-filled.e-float-input.e-input-focus:not(.e-input-group):not(.e-float-icon-left):not(.e-disabled):not(.e-success):not(.e-warning).e-error input,.e-filled.e-float-input.e-input-focus:not(.e-input-group):not(.e-float-icon-left):not(.e-disabled):not(.e-success):not(.e-warning):not(.e-error) textarea,.e-filled.e-float-input.e-input-focus:not(.e-input-group):not(.e-float-icon-left):not(.e-disabled).e-success:not(.e-warning):not(.e-error) textarea,.e-filled.e-float-input.e-input-focus:not(.e-input-group):not(.e-float-icon-left):not(.e-disabled):not(.e-success).e-warning:not(.e-error) textarea,.e-filled.e-float-input.e-input-focus:not(.e-input-group):not(.e-float-icon-left):not(.e-disabled):not(.e-success):not(.e-warning).e-error textarea,.e-filled.e-float-input.e-input-focus:not(.e-input-group):not(.e-float-icon-left):not(.e-success):not(.e-warning):not(.e-error) input,.e-filled.e-float-input.e-input-focus:not(.e-input-group):not(.e-float-icon-left).e-success:not(.e-warning):not(.e-error) input,.e-filled.e-float-input.e-input-focus:not(.e-input-group):not(.e-float-icon-left):not(.e-success).e-warning:not(.e-error) input,.e-filled.e-float-input.e-input-focus:not(.e-input-group):not(.e-float-icon-left):not(.e-success):not(.e-warning).e-error input,.e-filled.e-float-input.e-control-wrapper.e-input-focus:not(.e-input-group):not(.e-float-icon-left):not(.e-success):not(.e-warning):not(.e-error) input,.e-filled.e-float-input.e-control-wrapper.e-input-focus:not(.e-input-group):not(.e-float-icon-left).e-success:not(.e-warning):not(.e-error) input,.e-filled.e-float-input.e-control-wrapper.e-input-focus:not(.e-input-group):not(.e-float-icon-left):not(.e-success).e-warning:not(.e-error) input,.e-filled.e-float-input.e-control-wrapper.e-input-focus:not(.e-input-group):not(.e-float-icon-left):not(.e-success):not(.e-warning).e-error input{border-width:0}.e-filled.e-input-group,.e-filled.e-input-group.e-control-wrapper{border-radius:4px 4px 0 0;padding:0 10px 0 12px}.e-filled.e-input-group.e-small,.e-filled.e-input-group.e-control-wrapper.e-small,.e-small .e-filled.e-input-group.e-control-wrapper{margin-top:0;padding:0 6px 0 8px}.e-filled.e-float-input,.e-filled.e-float-input.e-control-wrapper{border:1px solid;border-radius:4px 4px 0 0;border-width:0 0 1px 0;margin-top:0;padding:0 10px 0 12px}.e-filled.e-float-input.e-small,.e-filled.e-float-input.e-control-wrapper.e-small,.e-small .e-filled.e-float-input.e-control-wrapper{margin-top:0;padding:0 6px 0 8px}.e-rtl.e-filled.e-input-group,.e-rtl.e-filled.e-input-group.e-control-wrapper,.e-rtl .e-filled.e-input-group,.e-rtl .e-filled.e-input-group.e-control-wrapper{padding:0 12px 0 10px}.e-rtl.e-filled.e-input-group.e-small,.e-rtl.e-filled.e-input-group.e-control-wrapper.e-small,.e-small .e-rtl.e-filled.e-input-group.e-control-wrapper,.e-rtl .e-filled.e-input-group.e-small,.e-rtl .e-filled.e-input-group.e-control-wrapper.e-small,.e-small.e-rtl .e-filled.e-input-group.e-control-wrapper{padding:0 8px 0 6px}.e-rtl.e-filled.e-float-input,.e-rtl.e-filled.e-float-input.e-control-wrapper,.e-rtl .e-filled.e-float-input,.e-rtl .e-filled.e-float-input.e-control-wrapper{padding:0 12px 0 10px}.e-rtl.e-filled.e-float-input.e-small,.e-rtl.e-filled.e-float-input.e-control-wrapper.e-small,.e-small .e-rtl.e-filled.e-float-input.e-control-wrapper,.e-rtl .e-filled.e-float-input.e-small,.e-rtl .e-filled.e-float-input.e-control-wrapper.e-small,.e-small.e-rtl .e-filled.e-float-input.e-control-wrapper{padding:0 8px 0 6px}.e-filled input.e-input,.e-filled.e-input-group input.e-input,.e-filled.e-input-group.e-control-wrapper input.e-input,.e-filled textarea.e-input,.e-filled.e-input-group textarea.e-input,.e-filled.e-input-group.e-control-wrapper textarea.e-input,.e-filled.e-input-group input.e-input:focus,.e-filled.e-input-group.e-control-wrapper input.e-input:focus,.e-filled.e-input-group textarea.e-input:focus,.e-filled.e-input-group.e-control-wrapper textarea.e-input:focus,.e-filled.e-input-group.e-input-focus input.e-input,.e-filled.e-input-group.e-control-wrapper.e-input-focus input.e-input{padding:10px 2px 10px 0}.e-filled .e-input:focus{padding-bottom:10px}.e-filled .e-input.e-small:focus{padding-bottom:7px}.e-filled .e-input.e-small,.e-filled.e-input-group.e-small .e-input,.e-filled.e-input-group.e-control-wrapper.e-small .e-input,.e-filled.e-input-group.e-small .e-input:focus,.e-filled.e-input-group.e-control-wrapper.e-small .e-input:focus,.e-filled.e-input-group.e-small.e-input-focus .e-input,.e-filled.e-input-group.e-control-wrapper.e-small.e-input-focus .e-input{padding:7px 2px 7px 0}.e-filled.e-float-input input,.e-filled.e-float-input.e-control-wrapper input{padding:14px 2px 5px 0}.e-filled.e-float-input.e-small input,.e-filled.e-float-input.e-control-wrapper.e-small input{padding:12px 2px 4px 0}.e-filled input.e-input.e-rtl,.e-filled.e-input-group.e-rtl input.e-input,.e-filled.e-input-group.e-control-wrapper.e-rtl input.e-input,.e-rtl .e-filled.e-input-group input.e-input,.e-rtl .e-filled.e-input-group.e-control-wrapper input.e-input,.e-filled.e-input-group.e-rtl input.e-input:focus,.e-filled.e-input-group.e-control-wrapper.e-rtl input.e-input:focus,.e-rtl .e-filled.e-input-group input.e-input:focus,.e-rtl .e-filled.e-input-group.e-control-wrapper input.e-input:focus,.e-filled.e-input-group.e-rtl.e-input-focus input.e-input,.e-filled.e-input-group.e-control-wrapper.e-rtl.e-input-focus input.e-input,.e-rtl .e-filled.e-input-group.e-input-focus input.e-input,.e-rtl .e-filled.e-input-group.e-control-wrapper.e-input-focus input.e-input{padding:10px 0 10px 2px;text-indent:0}.e-filled.e-float-input.e-rtl input,.e-filled.e-float-input.e-control-wrapper.e-rtl input,.e-rtl .e-filled.e-float-input input,.e-rtl .e-filled.e-float-input.e-control-wrapper input,.e-filled.e-float-input.e-rtl input:focus,.e-filled.e-float-input.e-control-wrapper.e-rtl input:focus,.e-rtl .e-filled.e-float-input input:focus,.e-rtl .e-filled.e-float-input.e-control-wrapper input:focus,.e-filled.e-float-input.e-rtl.e-input-focus input,.e-filled.e-float-input.e-control-wrapper.e-rtl.e-input-focus input,.e-rtl .e-filled.e-float-input.e-input-focus input,.e-rtl .e-filled.e-float-input.e-control-wrapper.e-input-focus input{padding:14px 0 5px 2px;text-indent:0}.e-rtl .e-filled input.e-input.e-small,.e-filled input.e-input.e-small.e-rtl,.e-small.e-rtl .e-filled input.e-input,.e-small .e-filled input.e-input.e-rtl,.e-filled.e-input-group.e-small.e-rtl input.e-input,.e-filled.e-input-group.e-control-wrapper.e-small.e-rtl input.e-input,.e-rtl .e-filled.e-input-group.e-small input.e-input,.e-rtl .e-filled.e-input-group.e-control-wrapper.e-small input.e-input,.e-filled.e-input-group.e-rtl input.e-input.e-small,.e-filled.e-input-group.e-control-wrapper.e-rtl input.e-input.e-small,.e-rtl .e-filled.e-input-group input.e-input.e-small,.e-rtl .e-filled.e-input-group.e-control-wrapper input.e-input.e-small,.e-small .e-filled.e-input-group.e-rtl input.e-input,.e-small .e-filled.e-input-group.e-control-wrapper.e-rtl input.e-input,.e-small.e-rtl .e-filled.e-input-group.e-control-wrapper input.e-input,.e-small.e-rtl .e-filled.e-input-group input.e-input,.e-small.e-rtl .e-filled.e-input-group.e-control-wrapper input.e-input:focus,.e-small.e-rtl .e-filled.e-input-group input.e-input:focus,.e-small .e-filled.e-input-group.e-control-wrapper.e-rtl input.e-input:focus,.e-small .e-filled.e-input-group.e-rtl input.e-input:focus,.e-small.e-rtl .e-filled.e-input-group.e-control-wrapper.e-input-focus input.e-input,.e-small.e-rtl .e-filled.e-input-group.e-input-focus input.e-input,.e-small .e-filled.e-input-group.e-control-wrapper.e-rtl.e-input-focus input.e-input,.e-small .e-filled.e-input-group.e-rtl.e-input-focus input.e-input{padding:7px 0 7px 2px;text-indent:0}.e-filled.e-float-input.e-control-wrapper.e-small.e-rtl input,.e-filled.e-float-input.e-small.e-rtl input,.e-rtl .e-filled.e-float-input.e-small input,.e-rtl .e-filled.e-float-input.e-control-wrapper.e-small input,.e-filled.e-float-input.e-rtl input.e-small,.e-filled.e-float-input.e-control-wrapper.e-rtl input.e-small,.e-rtl .e-filled.e-float-input input.e-small,.e-rtl .e-filled.e-float-input.e-control-wrapper input.e-small,.e-small .e-filled.e-float-input.e-rtl input,.e-small .e-filled.e-float-input.e-control-wrapper.e-rtl input,.e-small.e-rtl .e-filled.e-float-input.e-control-wrapper input,.e-small.e-rtl .e-filled.e-float-input input,.e-small.e-rtl .e-filled.e-float-input.e-control-wrapper input:focus,.e-small.e-rtl .e-filled.e-float-input input:focus,.e-small .e-filled.e-float-input.e-control-wrapper.e-rtl input:focus,.e-small .e-filled.e-float-input.e-rtl input:focus,.e-small.e-rtl .e-filled.e-float-input.e-control-wrapper.e-input-focus input,.e-small.e-rtl .e-filled.e-float-input.e-input-focus input,.e-small .e-filled.e-float-input.e-control-wrapper.e-rtl.e-input-focus input,.e-small .e-filled.e-float-input.e-rtl.e-input-focus input{padding:12px 0 4px 2px;text-indent:0}.e-filled.e-float-input,.e-filled.e-float-input.e-control-wrapper,.e-filled.e-float-input.e-disabled,.e-filled.e-float-input.e-control-wrapper.e-disabled,.e-filled.e-float-input.e-input-group.e-disabled,.e-filled.e-float-input.e-input-group.e-control-wrapper.e-disabled{font-size:14px}.e-filled.e-float-input.e-small,.e-small .e-filled.e-float-input,.e-filled.e-float-input.e-control-wrapper.e-small,.e-small .e-filled.e-float-input.e-control-wrapper,.e-filled.e-float-input.e-small.e-disabled,.e-small .e-filled.e-float-input.e-disabled,.e-filled.e-float-input.e-control-wrapper.e-small.e-disabled,.e-small .e-filled.e-float-input.e-control-wrapper.e-disabled,.e-filled.e-float-input.e-input-group.e-small.e-disabled,.e-small .e-filled.e-float-input.e-input-group.e-disabled,.e-filled.e-float-input.e-input-group.e-control-wrapper.e-small.e-disabled,.e-small .e-filled.e-float-input.e-input-group.e-control-wrapper.e-disabled{font-size:13px}.e-filled.e-input-group.e-small:not(.e-float-input) .e-input,.e-small .e-filled.e-input-group:not(.e-float-input) .e-input,.e-filled.e-input-group.e-control-wrapper.e-small:not(.e-float-input) .e-input,.e-small .e-filled.e-input-group.e-control-wrapper:not(.e-float-input) .e-input{min-height:35px}.e-filled.e-float-input.e-small input,.e-small .e-filled.e-float-input input,.e-filled.e-float-input.e-input-group.e-small input,.e-small .e-filled.e-float-input.e-input-group input,.e-filled.e-float-input.e-input-group.e-control-wrapper.e-small input,.e-small .e-filled.e-float-input.e-input-group.e-control-wrapper input,.e-filled.e-float-input.e-control-wrapper.e-small input,.e-small .e-filled.e-float-input.e-control-wrapper input,.e-filled.e-float-input.e-control-wrapper.e-input-group.e-small input,.e-small .e-filled.e-float-input.e-control-wrapper.e-input-group input{min-height:35px}.e-filled.e-input-group input.e-input,.e-filled.e-input-group.e-control-wrapper input.e-input,.e-filled.e-input-group:not(.e-float-input) input.e-input,.e-filled.e-input-group:not(.e-float-input).e-control-wrapper input.e-input{min-height:39px}.e-float-input.e-filled.e-input-group.e-control-wrapper input,.e-float-input.e-filled input,.e-float-input.e-filled.e-control-wrapper input{min-height:39px}.e-filled label.e-float-text,.e-filled.e-float-input label.e-float-text,.e-filled.e-float-input.e-control-wrapper label.e-float-text,.e-filled.e-float-input:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-filled.e-float-input.e-control-wrapper:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom{font-size:14px;left:12px;letter-spacing:.009375em;line-height:1.15;padding-left:0;pointer-events:none;right:auto;top:12px;transform:none;transition:transform .15s cubic-bezier(.4,0,.2,1),color .15s cubic-bezier(.4,0,.2,1);width:100%}.e-filled.e-float-input textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-filled.e-float-input.e-control-wrapper textarea:not(:focus):valid~label.e-float-text.e-label-bottom{font-size:14px;padding-left:0;top:12px;transform:none;width:100%}.e-filled.e-float-input input:focus~label.e-float-text,.e-filled.e-float-input input:valid~label.e-float-text,.e-filled.e-float-input input~label.e-label-top.e-float-text,.e-filled.e-float-input input[readonly]~label.e-label-top.e-float-text,.e-filled.e-float-input input[disabled]~label.e-label-top.e-float-text,.e-filled.e-float-input input label.e-float-text.e-label-top,.e-filled.e-float-input.e-control-wrapper input:focus~label.e-float-text,.e-filled.e-float-input.e-control-wrapper input:valid~label.e-float-text,.e-filled.e-float-input.e-control-wrapper input~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper input[readonly]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper input[disabled]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper input label.e-float-text.e-label-top,.e-filled.e-float-input.e-input-focus input~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-input-focus input~label.e-float-text{font-size:14px;top:12px;transform:translateY(-50%) scale(.75)}.e-filled.e-float-input textarea:focus~label.e-float-text,.e-filled.e-float-input textarea:valid~label.e-float-text,.e-filled.e-float-input textarea~label.e-label-top.e-float-text,.e-filled.e-float-input textarea[readonly]~label.e-label-top.e-float-text,.e-filled.e-float-input textarea[disabled]~label.e-label-top.e-float-text,.e-filled.e-float-input textarea label.e-float-text.e-label-top,.e-filled.e-float-input.e-control-wrapper textarea:focus~label.e-float-text,.e-filled.e-float-input.e-control-wrapper textarea:valid~label.e-float-text,.e-filled.e-float-input.e-control-wrapper textarea~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper textarea[readonly]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper textarea[disabled]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper textarea label.e-float-text.e-label-top{font-size:14px;top:12px;transform:translateY(-50%) scale(.75)}.e-filled.e-float-input input:-webkit-autofill~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-autofill input:-webkit-autofill~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-autofill:not(.e-input-focus) input:not(:focus):valid:-webkit-autofill~label.e-float-text.e-label-bottom,.e-filled.e-float-input textarea:-webkit-autofill~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-autofill textarea:-webkit-autofill~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-autofill textarea:not(:focus):valid:-webkit-autofill~label.e-float-text.e-label-bottom{font-size:14px;top:12px;transform:translateY(-50%) scale(.75);-webkit-user-select:text;user-select:text}.e-filled.e-float-input.e-small input:focus~label.e-float-text,.e-filled.e-float-input.e-small input:valid~label.e-float-text,.e-filled.e-float-input.e-small input~label.e-label-top.e-float-text,.e-small .e-filled.e-float-input input~label.e-label-top.e-float-text,.e-filled.e-float-input.e-small input[readonly]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-small input[disabled]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small input:focus~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small input:valid~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small input~label.e-label-top.e-float-text,.e-small .e-filled.e-float-input.e-control-wrapper input~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small input[readonly]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small input[disabled]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-small.e-input-focus input~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small.e-input-focus input~label.e-float-text,.e-filled.e-float-input.e-small textarea:focus~label.e-float-text,.e-filled.e-float-input.e-small textarea:valid~label.e-float-text,.e-filled.e-float-input.e-small textarea~label.e-label-top.e-float-text,.e-small .e-filled.e-float-input textarea~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small textarea:focus~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small textarea:valid~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small textarea~label.e-label-top.e-float-text,.e-small .e-filled.e-float-input.e-control-wrapper textarea~label.e-label-top.e-float-text{font-size:13px;top:10px}.e-small .e-filled.e-float-input input:-webkit-autofill~label.e-float-text,.e-small.e-filled.e-float-input input:-webkit-autofill~label.e-float-text,.e-small .e-filled.e-float-input.e-control-wrapper.e-autofill input:-webkit-autofill~label.e-float-text,.e-small.e-filled.e-float-input.e-control-wrapper.e-autofill input:-webkit-autofill~label.e-float-text,.e-small .e-filled.e-float-input.e-control-wrapper.e-autofill:not(.e-input-focus) input:not(:focus):valid:-webkit-autofill~label.e-float-text.e-label-bottom,.e-small.e-filled.e-float-input.e-control-wrapper.e-autofill:not(.e-input-focus) input:not(:focus):valid:-webkit-autofill~label.e-float-text.e-label-bottom,.e-small .e-filled.e-float-input textarea:-webkit-autofill~label.e-float-text,.e-small.e-filled.e-float-input textarea:-webkit-autofill~label.e-float-text,.e-small .e-filled.e-float-input.e-control-wrapper.e-autofill textarea:-webkit-autofill~label.e-float-text,.e-small.e-filled.e-float-input.e-control-wrapper.e-autofill textarea:-webkit-autofill~label.e-float-text,.e-small .e-filled.e-float-input.e-control-wrapper.e-autofill textarea:not(:focus):valid:-webkit-autofill~label.e-float-text.e-label-bottom,.e-small.e-filled.e-float-input.e-control-wrapper.e-autofill textarea:not(:focus):valid:-webkit-autofill~label.e-float-text.e-label-bottom{font-size:13px;top:10px;transform:translateY(-50%) scale(.75);-webkit-user-select:text;user-select:text}.e-filled.e-float-input.e-small label.e-float-text,.e-filled.e-float-input.e-small:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small .e-filled.e-float-input:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-filled.e-float-input.e-control-wrapper.e-small label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small .e-filled.e-float-input.e-control-wrapper:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-filled.e-float-input.e-small textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small .e-filled.e-float-input textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-filled.e-float-input.e-control-wrapper.e-small textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small .e-filled.e-float-input.e-control-wrapper textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-filled.e-float-input.e-small textarea~label.e-float-text,.e-filled.e-float-input textarea~label.e-float-text.e-small,.e-filled.e-float-input textarea.e-small~label.e-float-text,.e-small .e-filled.e-float-input textarea~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small textarea~label.e-float-text,.e-filled.e-float-input.e-control-wrapper textarea~label.e-float-text.e-small,.e-filled.e-float-input.e-control-wrapper textarea.e-small~label.e-float-text,.e-small .e-filled.e-float-input.e-control-wrapper textarea~label.e-float-text{font-size:13px;top:10px}.e-filled.e-float-input label.e-float-text,.e-filled.e-float-input label.e-float-text.e-label-bottom,.e-filled.e-float-input.e-control-wrapper label.e-float-text,.e-filled.e-float-input.e-control-wrapper label.e-float-text.e-label-bottom,.e-filled.e-float-input:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-filled.e-float-input.e-control-wrapper:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-filled.e-float-input:not(.e-input-focus) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-filled.e-float-input.e-control-wrapper:not(.e-input-focus) textarea:not(:focus):valid~label.e-float-text.e-label-bottom{left:12px}.e-filled.e-float-input.e-rtl label.e-float-text,.e-filled.e-float-input.e-rtl label.e-float-text.e-label-bottom,.e-rtl .e-filled.e-float-input label.e-float-text .e-filled.e-float-input.e-control-wrapper.e-rtl label.e-float-text,.e-filled.e-float-input.e-rtl.e-control-wrapper label.e-float-text.e-label-bottom,.e-rtl .e-filled.e-float-input.e-control-wrapper label.e-float-text,.e-filled.e-float-input.e-rtl:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-filled.e-float-input.e-control-wrapper.e-rtl:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-rtl .e-filled.e-float-input:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-rtl .e-filled.e-float-input.e-control-wrapper:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-filled.e-float-input.e-rtl:not(.e-input-focus) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-filled.e-float-input.e-control-wrapper.e-rtl:not(.e-input-focus) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-rtl .e-filled.e-float-input:not(.e-input-focus) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-rtl .e-filled.e-float-input.e-control-wrapper:not(.e-input-focus) textarea:not(:focus):valid~label.e-float-text.e-label-bottom{right:12px}.e-filled.e-float-input.e-small label.e-float-text,.e-filled.e-float-input.e-small label.e-float-text.e-label-bottom,.e-filled.e-float-input.e-control-wrapper.e-small label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small label.e-float-text.e-label-bottom,.e-filled.e-float-input.e-small:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-filled.e-float-input.e-control-wrapper.e-small:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small .e-filled.e-float-input label.e-float-text.e-label-bottom,.e-small .e-filled.e-float-input.e-control-wrapper label.e-float-text,.e-small .e-filled.e-float-input.e-control-wrapper label.e-float-text.e-label-bottom,.e-small .e-filled.e-float-input:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small .e-filled.e-float-input.e-control-wrapper:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-filled.e-float-input.e-small:not(.e-input-focus) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-filled.e-float-input.e-control-wrapper.e-small:not(.e-input-focus) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small .e-filled.e-float-input:not(.e-input-focus) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small .e-filled.e-float-input.e-control-wrapper:not(.e-input-focus) textarea:not(:focus):valid~label.e-float-text.e-label-bottom{left:8px}.e-filled.e-float-input.e-small.e-rtl label.e-float-text,.e-filled.e-float-input.e-rtl.e-small label.e-float-text.e-label-bottom,.e-rtl .e-filled.e-float-input.e-small label.e-float-text .e-filled.e-float-input.e-control-wrapper.e-rtl.e-small label.e-float-text,.e-filled.e-float-input.e-rtl.e-control-wrapper.e-small label.e-float-text.e-label-bottom,.e-rtl .e-filled.e-float-input.e-control-wrapper.e-small label.e-float-text,.e-small .e-filled.e-float-input.e-rtl label.e-float-text,.e-small .e-filled.e-float-input.e-rtl label.e-float-text.e-label-bottom,.e-rtl.e-small .e-filled.e-float-input label.e-float-text .e-small .e-filled.e-float-input.e-control-wrapper.e-rtl label.e-float-text,.e-small .e-filled.e-float-input.e-rtl.e-control-wrapper label.e-float-text.e-label-bottom,.e-rtl.e-small .e-filled.e-float-input.e-control-wrapper label.e-float-text,.e-small.e-filled.e-float-input.e-rtl:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small.e-filled.e-float-input.e-control-wrapper.e-rtl:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-rtl .e-small.e-filled.e-float-input:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-rtl .e-small.e-filled.e-float-input.e-control-wrapper:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small .e-filled.e-float-input.e-rtl:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small .e-filled.e-float-input.e-control-wrapper.e-rtl:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-rtl.e-small .e-filled.e-float-input:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-rtl.e-small .e-filled.e-float-input.e-control-wrapper:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small.e-filled.e-float-input.e-rtl:not(.e-input-focus) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small.e-filled.e-float-input.e-control-wrapper.e-rtl:not(.e-input-focus) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-rtl .e-small.e-filled.e-float-input:not(.e-input-focus) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-rtl .e-small.e-filled.e-float-input.e-control-wrapper:not(.e-input-focus) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small .e-filled.e-float-input.e-rtl:not(.e-input-focus) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small .e-filled.e-float-input.e-control-wrapper.e-rtl:not(.e-input-focus) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-rtl.e-small .e-filled.e-float-input:not(.e-input-focus) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-rtl.e-small .e-filled.e-float-input.e-control-wrapper:not(.e-input-focus) textarea:not(:focus):valid~label.e-float-text.e-label-bottom{right:8px}.e-filled.e-float-input .e-float-line,.e-float-input.e-filled.e-control-wrapper .e-float-line{bottom:-1px;position:absolute}.e-float-input.e-filled .e-float-line,.e-float-input.e-filled .e-float-text,.e-float-input.e-filled.e-control-wrapper .e-float-line,.e-float-input.e-filled.e-control-wrapper .e-float-text,.e-filled.e-float-input.e-rtl .e-input-in-wrap label.e-float-text,.e-filled.e-float-input.e-rtl .e-input-in-wrap label.e-float-text.e-label-bottom,.e-rtl .e-filled.e-float-input .e-input-in-wrap label.e-float-text .e-filled.e-float-input.e-control-wrapper.e-rtl .e-input-in-wrap label.e-float-text,.e-filled.e-float-input.e-rtl.e-control-wrapper .e-input-in-wrap label.e-float-text.e-label-bottom,.e-rtl .e-filled.e-float-input.e-control-wrapper .e-input-in-wrap label.e-float-text,.e-filled.e-float-input.e-rtl:not(.e-input-focus) .e-input-in-wrap input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-filled.e-float-input.e-control-wrapper.e-rtl:not(.e-input-focus) .e-input-in-wrap input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-rtl .e-filled.e-float-input:not(.e-input-focus) .e-input-in-wrap input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-rtl .e-filled.e-float-input.e-control-wrapper:not(.e-input-focus) .e-input-in-wrap input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-filled.e-float-input.e-small.e-rtl .e-input-in-wrap label.e-float-text,.e-filled.e-float-input.e-rtl.e-small .e-input-in-wrap label.e-float-text.e-label-bottom,.e-rtl .e-filled.e-float-input.e-small .e-input-in-wrap label.e-float-text .e-filled.e-float-input.e-control-wrapper.e-rtl.e-small .e-input-in-wrap label.e-float-text,.e-filled.e-float-input.e-rtl.e-control-wrapper.e-small .e-input-in-wrap label.e-float-text.e-label-bottom,.e-rtl .e-filled.e-float-input.e-control-wrapper.e-small .e-input-in-wrap label.e-float-text,.e-small .e-filled.e-float-input.e-rtl .e-input-in-wrap label.e-float-text,.e-small .e-filled.e-float-input.e-rtl .e-input-in-wrap label.e-float-text.e-label-bottom,.e-rtl.e-small .e-filled.e-float-input .e-input-in-wrap label.e-float-text .e-small .e-filled.e-float-input.e-control-wrapper.e-rtl .e-input-in-wrap label.e-float-text,.e-small .e-filled.e-float-input.e-rtl.e-control-wrapper .e-input-in-wrap label.e-float-text.e-label-bottom,.e-rtl.e-small .e-filled.e-float-input.e-control-wrapper .e-input-in-wrap label.e-float-text,.e-small.e-filled.e-float-input.e-rtl:not(.e-input-focus) .e-input-in-wrap input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small.e-filled.e-float-input.e-control-wrapper.e-rtl:not(.e-input-focus) .e-input-in-wrap input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-rtl .e-small.e-filled.e-float-input:not(.e-input-focus) .e-input-in-wrap input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-rtl .e-small.e-filled.e-float-input.e-control-wrapper:not(.e-input-focus) .e-input-in-wrap input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small .e-filled.e-float-input.e-rtl:not(.e-input-focus) .e-input-in-wrap input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small .e-filled.e-float-input.e-control-wrapper.e-rtl:not(.e-input-focus) .e-input-in-wrap input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-rtl.e-small .e-filled.e-float-input:not(.e-input-focus) .e-input-in-wrap input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-rtl.e-small .e-filled.e-float-input.e-control-wrapper:not(.e-input-focus) .e-input-in-wrap input:not(:focus):valid~label.e-float-text.e-label-bottom{right:0}.e-filled.e-input-group:not(.e-disabled):not(.e-float-icon-left):before,.e-filled.e-filled.e-input-group:not(.e-disabled):not(.e-float-icon-left):after,.e-filled.e-input-group.e-control-wrapper:not(.e-disabled):not(.e-float-icon-left):before,.e-filled.e-input-group.e-control-wrapper:not(.e-disabled):not(.e-float-icon-left):after{bottom:-1px}.e-filled.e-input-group .e-input-group-icon,.e-filled.e-input-group.e-control-wrapper .e-input-group-icon,.e-filled.e-input-group.e-small .e-input-group-icon,.e-filled.e-input-group.e-control-wrapper.e-small .e-input-group-icon,.e-small .e-filled.e-input-group .e-input-group-icon,.e-small .e-filled.e-input-group.e-control-wrapper .e-input-group-icon{font-size:16px;margin-bottom:0;margin-top:0;min-height:20px;min-width:20px;padding:0 0 0 8px}.e-rtl.e-filled.e-input-group .e-input-group-icon,.e-rtl.e-filled.e-input-group.e-control-wrapper .e-input-group-icon,.e-rtl.e-filled.e-input-group.e-small .e-input-group-icon,.e-rtl.e-filled.e-input-group.e-control-wrapper.e-small .e-input-group-icon,.e-small .e-rtl.e-filled.e-input-group .e-input-group-icon,.e-small .e-rtl.e-filled.e-input-group.e-control-wrapper .e-input-group-icon,.e-rtl .e-filled.e-input-group .e-input-group-icon,.e-rtl .e-filled.e-input-group.e-control-wrapper .e-input-group-icon,.e-rtl .e-filled.e-input-group.e-small .e-input-group-icon,.e-rtl .e-filled.e-input-group.e-control-wrapper.e-small .e-input-group-icon,.e-small.e-rtl .e-filled.e-input-group .e-input-group-icon,.e-small.e-rtl .e-filled.e-input-group.e-control-wrapper .e-input-group-icon,.e-rtl.e-filled.e-float-input.e-input-group .e-input-group-icon,.e-rtl.e-filled.e-float-input.e-control-wrapper.e-input-group .e-input-group-icon,.e-rtl.e-filled.e-float-input.e-input-group.e-small .e-input-group-icon,.e-small .e-rtl.e-filled.e-float-input.e-input-group .e-input-group-icon,.e-rtl.e-filled.e-float-input.e-control-wrapper.e-input-group.e-small .e-input-group-icon,.e-small .e-rtl.e-filled.e-float-input.e-control-wrapper.e-input-group .e-input-group-icon,.e-rtl .e-filled.e-float-input.e-input-group .e-input-group-icon,.e-rtl .e-filled.e-float-input.e-control-wrapper.e-input-group .e-input-group-icon,.e-rtl .e-filled.e-float-input.e-input-group.e-small .e-input-group-icon,.e-small.e-rtl .e-filled.e-float-input.e-input-group .e-input-group-icon,.e-rtl .e-filled.e-float-input.e-control-wrapper.e-input-group.e-small .e-input-group-icon,.e-small.e-rtl .e-filled.e-float-input.e-control-wrapper.e-input-group .e-input-group-icon{padding:0 8px 0 0}.e-filled.e-input-group.e-small .e-input-group-icon,.e-filled.e-input-group.e-control-wrapper.e-small .e-input-group-icon,.e-small .e-filled.e-input-group .e-input-group-icon,.e-small .e-filled.e-input-group.e-control-wrapper .e-input-group-icon{font-size:14px;min-height:18px;min-width:18px;padding:0 0 0 4px}.e-rtl.e-filled.e-input-group.e-small .e-input-group-icon,.e-rtl.e-filled.e-input-group.e-control-wrapper.e-small .e-input-group-icon,.e-small .e-rtl.e-filled.e-input-group .e-input-group-icon,.e-small .e-rtl.e-filled.e-input-group.e-control-wrapper .e-input-group-icon,.e-rtl .e-filled.e-input-group.e-small .e-input-group-icon,.e-rtl .e-filled.e-input-group.e-control-wrapper.e-small .e-input-group-icon,.e-small.e-rtl .e-filled.e-input-group .e-input-group-icon,.e-small.e-rtl .e-filled.e-input-group.e-control-wrapper .e-input-group-icon,.e-rtl.e-filled.e-float-input.e-input-group.e-small .e-input-group-icon,.e-small .e-rtl.e-filled.e-float-input.e-input-group .e-input-group-icon,.e-rtl.e-filled.e-float-input.e-control-wrapper.e-input-group.e-small .e-input-group-icon,.e-small .e-rtl.e-filled.e-float-input.e-control-wrapper.e-input-group .e-input-group-icon,.e-rtl .e-filled.e-float-input.e-input-group.e-small .e-input-group-icon,.e-small.e-rtl .e-filled.e-float-input.e-input-group .e-input-group-icon,.e-rtl .e-filled.e-float-input.e-control-wrapper.e-input-group.e-small .e-input-group-icon,.e-small.e-rtl .e-filled.e-float-input.e-control-wrapper.e-input-group .e-input-group-icon{padding:0 4px 0 0}.e-filled.e-float-input.e-input-group .e-input-group-icon,.e-filled.e-float-input.e-control-wrapper.e-input-group .e-input-group-icon,.e-filled.e-float-input.e-input-group.e-small .e-input-group-icon,.e-small .e-filled.e-float-input.e-input-group .e-input-group-icon,.e-filled.e-float-input.e-control-wrapper.e-input-group.e-small .e-input-group-icon,.e-small .e-filled.e-float-input.e-control-wrapper.e-input-group .e-input-group-icon{font-size:16px;margin-bottom:0;margin-top:0;padding:8px}.e-filled.e-float-input.e-input-group.e-small .e-input-group-icon,.e-small .e-filled.e-float-input.e-input-group .e-input-group-icon,.e-filled.e-float-input.e-control-wrapper.e-input-group.e-small .e-input-group-icon,.e-small .e-filled.e-float-input.e-control-wrapper.e-input-group .e-input-group-icon{font-size:14px;padding:0 0 0 4px}.e-filled.e-float-input .e-clear-icon,.e-filled.e-float-input.e-control-wrapper .e-clear-icon,.e-filled.e-input-group .e-clear-icon,.e-filled.e-input-group.e-control-wrapper .e-clear-icon{font-size:16px;padding:0 0 0 8px}.e-filled.e-input-group .e-clear-icon,.e-filled.e-input-group.e-control-wrapper .e-clear-icon{min-height:20px;min-width:20px;padding:0 0 0 8px}.e-filled.e-float-input.e-input-group .e-clear-icon,.e-filled.e-float-input.e-input-group.e-control-wrapper .e-clear-icon{padding:0 0 0 8px}.e-filled.e-input-group.e-small .e-clear-icon,.e-filled.e-input-group .e-clear-icon.e-small,.e-small .e-filled.e-input-group .e-clear-icon,.e-filled.e-input-group.e-control-wrapper.e-small .e-clear-icon,.e-filled.e-input-group.e-control-wrapper .e-clear-icon.e-small,.e-small .e-filled.e-input-group.e-control-wrapper .e-clear-icon{font-size:14px;min-height:18px;min-width:18px;padding:0 0 0 4px}.e-filled.e-input-group.e-float-input.e-small .e-clear-icon,.e-filled.e-input-group.e-float-input .e-clear-icon.e-small,.e-small .e-filled.e-input-group.e-float-input .e-clear-icon,.e-filled.e-input-group.e-control-wrapper.e-float-input.e-small .e-clear-icon,.e-filled.e-input-group.e-control-wrapper.e-float-input .e-clear-icon.e-small,.e-small .e-filled.e-input-group.e-control-wrapper.e-float-input .e-clear-icon,.e-filled.e-input-group.e-float-input.e-control-wrapper.e-small .e-clear-icon,.e-filled.e-input-group.e-float-input.e-control-wrapper .e-clear-icon.e-small,.e-small .e-filled.e-input-group.e-float-input.e-control-wrapper .e-clear-icon{padding:0 0 0 4px}.e-rtl.e-filled.e-input-group .e-clear-icon,.e-rtl.e-filled.e-input-group.e-control-wrapper .e-clear-icon,.e-rtl.e-filled.e-input-group.e-control-wrapper.e-small .e-clear-icon,.e-small .e-rtl.e-filled.e-input-group .e-clear-icon,.e-small .e-rtl.e-filled.e-input-group.e-control-wrapper .e-clear-icon,.e-rtl .e-filled.e-input-group .e-clear-icon,.e-rtl .e-filled.e-input-group.e-control-wrapper .e-clear-icon,.e-rtl .e-filled.e-input-group.e-small .e-clear-icon,.e-rtl .e-filled.e-input-group.e-control-wrapper.e-small .e-clear-icon,.e-small.e-rtl .e-filled.e-input-group .e-clear-icon,.e-small.e-rtl .e-filled.e-input-group.e-control-wrapper .e-clear-icon,.e-rtl.e-filled.e-float-input.e-input-group .e-clear-icon,.e-rtl.e-filled.e-float-input.e-control-wrapper.e-input-group .e-clear-icon,.e-rtl.e-filled.e-float-input.e-input-group.e-small .e-clear-icon,.e-small .e-rtl.e-filled.e-float-input.e-input-group .e-clear-icon,.e-rtl.e-filled.e-float-input.e-control-wrapper.e-input-group.e-small .e-clear-icon,.e-small .e-rtl.e-filled.e-float-input.e-control-wrapper.e-input-group .e-clear-icon,.e-rtl .e-filled.e-float-input.e-input-group .e-clear-icon,.e-rtl .e-filled.e-float-input.e-control-wrapper.e-input-group .e-clear-icon,.e-rtl .e-filled.e-float-input.e-input-group.e-small .e-clear-icon,.e-small.e-rtl .e-filled.e-float-input.e-input-group .e-clear-icon,.e-rtl .e-filled.e-float-input.e-control-wrapper.e-input-group.e-small .e-clear-icon,.e-small.e-rtl .e-filled.e-float-input.e-control-wrapper.e-input-group .e-clear-icon{padding:0 8px 0 0}.e-rtl.e-filled.e-input-group.e-small .e-clear-icon,.e-rtl.e-filled.e-input-group.e-control-wrapper.e-small .e-clear-icon,.e-small .e-rtl.e-filled.e-input-group .e-clear-icon,.e-small .e-rtl.e-filled.e-input-group.e-control-wrapper .e-clear-icon,.e-rtl .e-filled.e-input-group.e-small .e-clear-icon,.e-rtl .e-filled.e-input-group.e-control-wrapper.e-small .e-clear-icon,.e-small.e-rtl .e-filled.e-input-group .e-clear-icon,.e-small.e-rtl .e-filled.e-input-group.e-control-wrapper .e-clear-icon,.e-rtl.e-filled.e-float-input.e-input-group.e-small .e-clear-icon,.e-small .e-rtl.e-filled.e-float-input.e-input-group .e-clear-icon,.e-rtl.e-filled.e-float-input.e-control-wrapper.e-input-group.e-small .e-clear-icon,.e-small .e-rtl.e-filled.e-float-input.e-control-wrapper.e-input-group .e-clear-icon,.e-rtl .e-filled.e-float-input.e-input-group.e-small .e-clear-icon,.e-small.e-rtl .e-filled.e-float-input.e-input-group .e-clear-icon,.e-rtl .e-filled.e-float-input.e-control-wrapper.e-input-group.e-small .e-clear-icon,.e-small.e-rtl .e-filled.e-float-input.e-control-wrapper.e-input-group .e-clear-icon{padding:0 4px 0 0}.e-filled.e-float-input .e-clear-icon:before,.e-filled.e-float-input.e-control-wrapper .e-clear-icon:before,.e-filled.e-input-group .e-clear-icon:before,.e-filled.e-input-group.e-control-wrapper .e-clear-icon:before{font-size:16px}.e-filled.e-float-input.e-small .e-clear-icon:before,.e-filled.e-float-input.e-control-wrapper.e-small .e-clear-icon:before,.e-filled.e-input-group.e-small .e-clear-icon:before,.e-filled.e-input-group.e-control-wrapper.e-small .e-clear-icon:before,.e-filled.e-float-input.e-control-wrapper input.e-small:first-child~.e-clear-icon:before,.e-small .e-filled.e-float-input.e-control-wrapper .e-clear-icon:before,.e-filled.e-float-input input.e-small:first-child~.e-clear-icon:before,.e-small .e-filled.e-float-input .e-clear-icon:before,.e-small .e-filled.e-input-group .e-clear-icon:before,.e-small .e-filled.e-input-group.e-control-wrapper .e-clear-icon:before{font-size:14px}.e-filled.e-float-input .e-input-in-wrap input:focus~label.e-float-text,.e-filled.e-float-input .e-input-in-wrap input:valid~label.e-float-text,.e-filled.e-float-input .e-input-in-wrap input~label.e-label-top.e-float-text,.e-filled.e-float-input .e-input-in-wrap input[readonly]~label.e-label-top.e-float-text,.e-filled.e-float-input .e-input-in-wrap input[disabled]~label.e-label-top.e-float-text,.e-filled.e-float-input .e-input-in-wrap input label.e-float-text.e-label-top,.e-filled.e-float-input.e-control-wrapper .e-input-in-wrap input:focus~label.e-float-text,.e-filled.e-float-input.e-control-wrapper .e-input-in-wrap input:valid~label.e-float-text,.e-filled.e-float-input.e-control-wrapper .e-input-in-wrap input~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper .e-input-in-wrap input[readonly]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper .e-input-in-wrap input[disabled]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper .e-input-in-wrap input label.e-float-text.e-label-top{top:12px}.e-filled.e-float-input.e-small .e-input-in-wrap input:focus~label.e-float-text,.e-filled.e-float-input.e-small .e-input-in-wrap input:valid~label.e-float-text,.e-filled.e-float-input.e-small .e-input-in-wrap input~label.e-label-top.e-float-text,.e-small .e-filled.e-float-input .e-input-in-wrap input~label.e-label-top.e-float-text,.e-filled.e-float-input.e-small .e-input-in-wrap input[readonly]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-small .e-input-in-wrap input[disabled]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small .e-input-in-wrap input:focus~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small .e-input-in-wrap input:valid~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small .e-input-in-wrap input~label.e-label-top.e-float-text,.e-small .e-filled.e-float-input.e-control-wrapper .e-input-in-wrap input~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small .e-input-in-wrap input[readonly]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small .e-input-in-wrap input[disabled]~label.e-label-top.e-float-text{top:10px}.e-filled.e-input-group.e-float-icon-left.e-input-focus:not(.e-success):not(.e-warning):not(.e-error) .e-input-in-wrap,.e-filled.e-input-group.e-float-icon-left.e-input-focus.e-success:not(.e-warning):not(.e-error) .e-input-in-wrap,.e-filled.e-input-group.e-float-icon-left.e-input-focus.e-warning:not(.e-success):not(.e-error) .e-input-in-wrap,.e-filled.e-input-group.e-float-icon-left.e-input-focus.e-error:not(.e-success):not(.e-warning) .e-input-in-wrap,.e-filled.e-input-group.e-control-wrapper.e-float-icon-left.e-input-focus:not(.e-success):not(.e-warning):not(.e-error) .e-input-in-wrap,.e-filled.e-input-group.e-control-wrapper.e-float-icon-left.e-input-focus.e-success:not(.e-warning):not(.e-error) .e-input-in-wrap,.e-filled.e-input-group.e-control-wrapper.e-float-icon-left.e-input-focus.e-warning:not(.e-success):not(.e-error) .e-input-in-wrap,.e-filled.e-input-group.e-control-wrapper.e-float-icon-left.e-input-focus.e-error:not(.e-success):not(.e-warning) .e-input-in-wrap{border-style:none;border-width:0}.e-filled.e-float-input .e-input-in-wrap label.e-float-text,.e-filled.e-float-input:not(.e-input-focus) .e-input-in-wrap input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-filled.e-float-input.e-control-wrapper .e-input-in-wrap label.e-float-text,.e-filled.e-float-input.e-control-wrapper:not(.e-input-focus) .e-input-in-wrap input:not(:focus):valid~label.e-float-text.e-label-bottom{top:12px}.e-filled.e-float-input.e-small .e-input-in-wrap label.e-float-text,.e-small .e-filled.e-float-input .e-input-in-wrap label.e-float-text,.e-filled.e-float-input.e-small:not(.e-input-focus) .e-input-in-wrap input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small .e-filled.e-float-input:not(.e-input-focus) .e-input-in-wrap input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-filled.e-float-input.e-control-wrapper.e-small .e-input-in-wrap label.e-float-text,.e-small .e-filled.e-float-input.e-control-wrapper .e-input-in-wrap label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small:not(.e-input-focus) .e-input-in-wrap input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small .e-filled.e-float-input.e-control-wrapper:not(.e-input-focus) .e-input-in-wrap input:not(:focus):valid~label.e-float-text.e-label-bottom{top:10px}.e-filled.e-input-group:not(.e-float-input).e-float-icon-left>.e-input-group-icon,.e-filled.e-input-group:not(.e-float-input).e-control-wrapper.e-float-icon-left>.e-input-group-icon{font-size:16px;margin:0;min-height:20px;min-width:20px;padding:0}.e-filled.e-input-group:not(.e-float-input).e-small.e-float-icon-left>.e-input-group-icon,.e-filled.e-input-group:not(.e-float-input).e-float-icon-left>.e-input-group-icon.e-small,.e-filled.e-input-group:not(.e-float-input).e-control-wrapper.e-small.e-float-icon-left>.e-input-group-icon,.e-filled.e-input-group:not(.e-float-input).e-control-wrapper.e-float-icon-left>.e-input-group-icon.e-small,.e-small .e-filled.e-input-group:not(.e-float-input).e-float-icon-left>.e-input-group-icon,.e-small .e-filled.e-input-group:not(.e-float-input).e-control-wrapper.e-float-icon-left>.e-input-group-icon{font-size:14px;margin:0;min-height:18px;min-width:18px;padding:0}.e-filled.e-input-group.e-float-icon-left>.e-input-group-icon,.e-filled.e-float-input.e-input-group.e-float-icon-left>.e-input-group-icon,.e-filled.e-input-group.e-control-wrapper.e-float-icon-left>.e-input-group-icon,.e-filled.e-float-input.e-input-group.e-control-wrapper.e-float-icon-left>.e-input-group-icon{margin:0;min-height:20px;min-width:20px;padding:0}.e-filled.e-input-group.e-small.e-float-icon-left>.e-input-group-icon,.e-filled.e-input-group.e-float-icon-left>.e-input-group-icon.e-small,.e-filled.e-input-group.e-control-wrapper.e-small.e-float-icon-left>.e-input-group-icon,.e-filled.e-input-group.e-control-wrapper.e-float-icon-left>.e-input-group-icon.e-small,.e-small .e-filled.e-input-group.e-float-icon-left>.e-input-group-icon,.e-small .e-filled.e-input-group.e-control-wrapper.e-float-icon-left>.e-input-group-icon,.e-filled.e-float-input.e-input-group.e-small.e-float-icon-left>.e-input-group-icon,.e-filled.e-float-input.e-input-group.e-float-icon-left>.e-input-group-icon.e-small,.e-small .e-filled.e-float-input.e-input-group.e-float-icon-left>.e-input-group-icon,.e-filled.e-float-input.e-control-wrapper.e-input-group.e-small.e-float-icon-left>.e-input-group-icon,.e-filled.e-float-input.e-control-wrapper.e-input-group.e-float-icon-left>.e-input-group-icon.e-small,.e-small .e-filled.e-float-input.e-control-wrapper.e-input-group.e-float-icon-left>.e-input-group-icon{margin:0;min-height:18px;min-width:18px;padding:0}.e-filled.e-float-input .e-input-in-wrap label.e-float-text,.e-filled.e-float-input .e-input-in-wrap label.e-float-text.e-label-bottom,.e-filled.e-float-input.e-control-wrapper .e-input-in-wrap label.e-float-text,.e-filled.e-float-input.e-control-wrapper .e-input-in-wrap label.e-float-text.e-label-bottom,.e-filled.e-float-input:not(.e-input-focus) .e-input-in-wrap input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-filled.e-float-input.e-control-wrapper:not(.e-input-focus) .e-input-in-wrap input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-filled.e-float-input.e-small .e-input-in-wrap label.e-float-text,.e-filled.e-float-input.e-small .e-input-in-wrap label.e-float-text.e-label-bottom,.e-filled.e-float-input.e-control-wrapper.e-small .e-input-in-wrap label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small .e-input-in-wrap label.e-float-text.e-label-bottom,.e-filled.e-float-input.e-small:not(.e-input-focus) .e-input-in-wrap input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small .e-filled.e-float-input .e-input-in-wrap label.e-float-text.e-label-bottom,.e-small .e-filled.e-float-input.e-control-wrapper .e-input-in-wrap label.e-float-text,.e-small .e-filled.e-float-input.e-control-wrapper .e-input-in-wrap label.e-float-text.e-label-bottom,.e-small .e-filled.e-float-input:not(.e-input-focus) .e-input-in-wrap input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small .e-filled.e-float-input.e-control-wrapper:not(.e-input-focus) .e-input-in-wrap input:not(:focus):valid~label.e-float-text.e-label-bottom{left:0}.e-filled.e-input-group .e-input-group-icon:last-child,.e-filled.e-input-group.e-small .e-input-group-icon:last-child,.e-small .e-filled.e-input-group .e-input-group-icon:last-child,.e-filled.e-input-group.e-control-wrapper .e-input-group-icon:last-child,.e-filled.e-input-group.e-small.e-control-wrapper .e-input-group-icon:last-child,.e-small .e-filled.e-input-group.e-control-wrapper .e-input-group-icon:last-child,.e-filled.e-input-group .e-input-group-icon,.e-filled.e-input-group.e-control-wrapper .e-input-group-icon,.e-filled.e-input-group.e-small .e-input-group-icon,.e-filled.e-input-group.e-control-wrapper.e-small .e-input-group-icon,.e-small .e-filled.e-input-group .e-input-group-icon,.e-small .e-filled.e-input-group.e-control-wrapper .e-input-group-icon{margin-right:0}.e-filled.e-input-group.e-rtl .e-input-group-icon:last-child,.e-filled.e-input-group.e-small.e-rtl .e-input-group-icon:last-child,.e-small .e-filled.e-input-group.e-rtl .e-input-group-icon:last-child,.e-filled.e-input-group.e-control-wrapper.e-rtl .e-input-group-icon:last-child,.e-filled.e-input-group.e-small.e-control-wrapper.e-rtl .e-input-group-icon:last-child,.e-small .e-filled.e-input-group.e-control-wrapper.e-rtl .e-input-group-icon:last-child,.e-rtl .e-filled.e-input-group .e-input-group-icon:last-child,.e-rtl .e-filled.e-input-group.e-small .e-input-group-icon:last-child,.e-rtl.e-small .e-filled.e-input-group .e-input-group-icon:last-child,.e-rtl .e-filled.e-input-group.e-control-wrapper .e-input-group-icon:last-child,.e-rtl .e-filled.e-input-group.e-small.e-control-wrapper .e-input-group-icon:last-child,.e-rtl.e-small .e-filled.e-input-group.e-control-wrapper .e-input-group-icon:last-child{margin-left:0}.e-filled.e-rtl.e-input-group .e-input-group-icon,.e-filled.e-rtl.e-input-group.e-control-wrapper .e-input-group-icon,.e-rtl .e-filled.e-input-group .e-input-group-icon,.e-rtl .e-filled.e-input-group.e-control-wrapper .e-input-group-icon,.e-filled.e-input-group.e-small.e-rtl .e-input-group-icon,.e-filled.e-input-group.e-control-wrapper.e-small.e-rtl .e-input-group-icon,.e-small .e-filled.e-input-group.e-rtl .e-input-group-icon,.e-small .e-filled.e-input-group.e-control-wrapper.e-rtl .e-input-group-icon,.e-rtl .e-filled.e-input-group.e-small .e-input-group-icon,.e-rtl .e-filled.e-input-group.e-control-wrapper.e-small .e-input-group-icon,.e-rtl.e-small .e-filled.e-input-group .e-input-group-icon,.e-rtl.e-small .e-filled.e-input-group.e-control-wrapper .e-input-group-icon{margin-left:0;margin-right:0}.e-filled textarea.e-input,.e-filled.e-input-group.e-multi-line-input textarea,.e-filled.e-input-group.e-control-wrapper.e-multi-line-input textarea,.e-filled.e-float-input.e-multi-line-input textarea,.e-filled.e-float-input.e-control-wrapper.e-multi-line-input textarea{box-sizing:border-box}.e-filled textarea.e-input,.e-filled.e-input-group textarea,.e-filled.e-input-group textarea.e-input,.e-filled.e-input-group.e-input-focus textarea,.e-filled.e-input-group.e-input-focus textarea.e-input,.e-filled.e-input-group.e-control-wrapper textarea,.e-filled.e-input-group.e-control-wrapper.e-input-focus textarea,.e-filled.e-input-group.e-control-wrapper textarea.e-input,.e-filled.e-input-group.e-control-wrapper.e-input-focus textarea.e-input{padding:0 12px 9px}.e-filled.e-float-input textarea,.e-filled.e-float-input.e-control-wrapper textarea{padding:0 12px 5px}.e-filled.e-input-group.e-small textarea,.e-filled.e-input-group.e-small textarea.e-input,.e-filled.e-input-group textarea.e-small,.e-filled.e-input-group textarea.e-input.e-small,.e-filled.e-input-group.e-control-wrapper.e-small textarea,.e-filled.e-input-group.e-control-wrapper.e-small textarea.e-input,.e-small .e-filled.e-input-group textarea,.e-small .e-filled.e-input-group textarea.e-input,.e-filled.e-input-group.e-input-focus.e-small textarea,.e-filled.e-input-group.e-input-focus.e-small textarea.e-input,.e-filled.e-input-group.e-input-focus textarea.e-small,.e-filled.e-input-group.e-input-focus textarea.e-input.e-small,.e-filled.e-input-group.e-control-wrapper.e-input-focus.e-small textarea,.e-filled.e-input-group.e-control-wrapper.e-input-focus.e-small textarea.e-input,.e-small .e-filled.e-input-group.e-input-focus textarea,.e-small .e-filled.e-input-group.e-input-focus textarea.e-input{padding:0 8px 7px}.e-filled.e-float-input.e-small textarea,.e-filled.e-float-input textarea.e-small,.e-filled.e-float-input.e-control-wrapper.e-small textarea,.e-filled.e-float-input.e-control-wrapper textarea.e-small,.e-small .e-filled.e-float-input textarea,.e-small .e-filled.e-float-input.e-control-wrapper textarea{padding:0 8px 4px}.e-filled.e-input-group.e-multi-line-input,.e-filled.e-input-group.e-control-wrapper.e-multi-line-input{padding:10px 0 0}.e-filled.e-input-group.e-small.e-multi-line-input,.e-filled.e-input-group.e-control-wrapper.e-small.e-multi-line-input,.e-small .e-filled.e-input-group.e-control-wrapper.e-multi-line-input{padding:7px 0 0}.e-filled.e-float-input.e-multi-line-input,.e-filled.e-float-input.e-control-wrapper.e-multi-line-input{padding:14px 0 0}.e-filled.e-float-input.e-small.e-multi-line-input,.e-filled.e-float-input.e-control-wrapper.e-small.e-multi-line-input,.e-small .e-filled.e-float-input.e-control-wrapper.e-multi-line-input{padding:12px 0 0}.e-filled textarea.e-input.e-rtl,.e-filled.e-input-group.e-multi-line-input.e-rtl textarea.e-input,.e-filled.e-input-group.e-multi-line-input.e-control-wrapper.e-rtl textarea.e-input,.e-rtl .e-filled.e-input-group.e-multi-line-input textarea.e-input,.e-rtl .e-filled.e-input-group.e-multi-line-input.e-control-wrapper textarea.e-input,.e-filled.e-input-group.e-multi-line-input.e-rtl textarea.e-input:focus,.e-filled.e-input-group.e-multi-line-input.e-control-wrapper.e-rtl textarea.e-input:focus,.e-rtl .e-filled.e-input-group.e-multi-line-input textarea.e-input:focus,.e-rtl .e-filled.e-input-group.e-multi-line-input.e-control-wrapper textarea.e-input:focus{padding:0 12px 9px;text-indent:0}.e-filled.e-float-input.e-multi-line-input.e-rtl textarea,.e-filled.e-float-input.e-multi-line-input.e-control-wrapper.e-rtl textarea,.e-rtl .e-filled.e-float-input.e-multi-line-input textarea,.e-rtl .e-filled.e-float-input.e-multi-line-input.e-control-wrapper textarea,.e-filled.e-float-input.e-multi-line-input.e-rtl textarea:focus,.e-filled.e-float-input.e-multi-line-input.e-control-wrapper.e-rtl textarea:focus,.e-rtl .e-filled.e-float-input.e-multi-line-input textarea:focus,.e-rtl .e-filled.e-float-input.e-multi-line-input.e-control-wrapper textarea:focus{padding:0 12px 5px;text-indent:0}.e-rtl .e-filled textarea.e-input.e-small,.e-filled textarea.e-input.e-small.e-rtl,.e-small.e-rtl .e-filled textarea.e-input,.e-small .e-filled textarea.e-input.e-rtl,.e-filled.e-input-group.e-multi-line-input.e-small.e-rtl textarea.e-input,.e-filled.e-input-group.e-multi-line-input.e-control-wrapper.e-small.e-rtl textarea.e-input,.e-rtl .e-filled.e-input-group.e-multi-line-input.e-small textarea.e-input,.e-rtl .e-filled.e-input-group.e-multi-line-input.e-control-wrapper.e-small textarea.e-input,.e-filled.e-input-group.e-multi-line-input.e-rtl textarea.e-input.e-small,.e-filled.e-input-group.e-multi-line-input.e-control-wrapper.e-rtl textarea.e-input.e-small,.e-rtl .e-filled.e-input-group.e-multi-line-input textarea.e-input.e-small,.e-rtl .e-filled.e-input-group.e-multi-line-input.e-control-wrapper textarea.e-input.e-small,.e-small .e-filled.e-input-group.e-multi-line-input.e-rtl textarea.e-input,.e-small .e-filled.e-input-group.e-multi-line-input.e-control-wrapper.e-rtl textarea.e-input,.e-small.e-rtl .e-filled.e-input-group.e-multi-line-input.e-control-wrapper textarea.e-input,.e-small.e-rtl .e-filled.e-input-group.e-multi-line-input textarea.e-input,.e-small.e-rtl .e-filled.e-input-group.e-multi-line-input.e-control-wrapper textarea.e-input:focus,.e-small.e-rtl .e-filled.e-input-group.e-multi-line-input textarea.e-input:focus,.e-small .e-filled.e-input-group.e-multi-line-input.e-control-wrapper.e-rtl textarea.e-input:focus,.e-small .e-filled.e-input-group.e-multi-line-input.e-rtl textarea.e-input:focus{padding:0 8px 7px;text-indent:0}.e-filled.e-float-input.e-multi-line-input.e-control-wrapper.e-small.e-rtl textarea,.e-filled.e-float-input.e-multi-line-input.e-small.e-rtl textarea,.e-rtl .e-filled.e-float-input.e-multi-line-input.e-small textarea,.e-rtl .e-filled.e-float-input.e-multi-line-input.e-control-wrapper.e-small textarea,.e-filled.e-float-input.e-multi-line-input.e-rtl textarea.e-small,.e-filled.e-float-input.e-multi-line-input.e-control-wrapper.e-rtl textarea.e-small,.e-rtl .e-filled.e-float-input.e-multi-line-input textarea.e-small,.e-rtl .e-filled.e-float-input.e-multi-line-input.e-control-wrapper textarea.e-small,.e-small .e-filled.e-float-input.e-multi-line-input.e-rtl textarea,.e-small .e-filled.e-float-input.e-multi-line-input.e-control-wrapper.e-rtl textarea,.e-small.e-rtl .e-filled.e-float-input.e-multi-line-input.e-control-wrapper textarea,.e-small.e-rtl .e-filled.e-float-input.e-multi-line-input textarea,.e-small.e-rtl .e-filled.e-float-input.e-multi-line-input.e-control-wrapper textarea:focus,.e-small.e-rtl .e-filled.e-float-input.e-multi-line-input textarea:focus,.e-small .e-filled.e-float-input.e-multi-line-input.e-control-wrapper.e-rtl textarea:focus,.e-small .e-filled.e-float-input.e-multi-line-input.e-rtl textarea:focus{padding:0 8px 4px;text-indent:0}.e-filled.e-float-input.e-float-icon-left .e-input-in-wrap,.e-filled.e-float-input.e-control-wrapper.e-float-icon-left .e-input-in-wrap,.e-filled.e-input-group.e-float-icon-left .e-input-in-wrap,.e-filled.e-input-group.e-control-wrapper.e-float-icon-left .e-input-in-wrap{border:1px solid;border-width:0;margin-left:8px}.e-rtl .e-filled.e-float-input.e-float-icon-left .e-input-in-wrap,.e-rtl .e-filled.e-float-input.e-control-wrapper.e-float-icon-left .e-input-in-wrap,.e-rtl .e-filled.e-input-group.e-float-icon-left .e-input-in-wrap,.e-rtl .e-filled.e-input-group.e-control-wrapper.e-float-icon-left .e-input-in-wrap .e-filled.e-float-input.e-control-wrapper.e-float-icon-left.e-rtl .e-input-in-wrap,.e-filled.e-float-input.e-float-icon-left.e-rtl .e-input-in-wrap,.e-filled.e-input-group.e-float-icon-left.e-rtl .e-input-in-wrap,.e-filled.e-input-group.e-control-wrapper.e-float-icon-left.e-rtl .e-input-in-wrap{margin-left:0;margin-right:8px}.e-filled.e-float-input.e-float-icon-left.e-small .e-input-in-wrap,.e-filled.e-float-input.e-control-wrapper.e-float-icon-left.e-small .e-input-in-wrap,.e-filled.e-input-group.e-float-icon-left.e-small .e-input-in-wrap,.e-filled.e-input-group.e-control-wrapper.e-float-icon-left.e-small .e-input-in-wrap,.e-small .e-filled.e-float-input.e-float-icon-left .e-input-in-wrap,.e-small .e-filled.e-float-input.e-control-wrapper.e-float-icon-left .e-input-in-wrap,.e-small .e-filled.e-input-group.e-float-icon-left .e-input-in-wrap,.e-small .e-filled.e-input-group.e-control-wrapper.e-float-icon-left .e-input-in-wrap{margin-left:4px}.e-rtl.e-small .e-filled.e-float-input.e-float-icon-left .e-input-in-wrap,.e-rtl.e-small .e-filled.e-float-input.e-control-wrapper.e-float-icon-left .e-input-in-wrap,.e-rtl.e-small .e-filled.e-input-group.e-float-icon-left .e-input-in-wrap,.e-rtl.e-small .e-filled.e-input-group.e-control-wrapper.e-float-icon-left .e-input-in-wrap,.e-rtl .e-small.e-filled.e-float-input.e-float-icon-left .e-input-in-wrap,.e-rtl .e-small.e-filled.e-float-input.e-control-wrapper.e-float-icon-left .e-input-in-wrap,.e-rtl .e-small.e-filled.e-input-group.e-float-icon-left .e-input-in-wrap,.e-rtl .e-small.e-filled.e-input-group.e-control-wrapper.e-float-icon-left .e-input-in-wrap,.e-small.e-filled.e-float-input.e-control-wrapper.e-float-icon-left.e-rtl .e-input-in-wrap,.e-small.e-filled.e-float-input.e-float-icon-left.e-rtl .e-input-in-wrap,.e-small.e-filled.e-input-group.e-float-icon-left.e-rtl .e-input-in-wrap,.e-small.e-filled.e-input-group.e-control-wrapper.e-float-icon-left.e-rtl .e-input-in-wrap,.e-small .e-filled.e-float-input.e-control-wrapper.e-float-icon-left.e-rtl .e-input-in-wrap,.e-small .e-filled.e-float-input.e-float-icon-left.e-rtl .e-input-in-wrap,.e-small .e-filled.e-input-group.e-float-icon-left.e-rtl .e-input-in-wrap,.e-small .e-filled.e-input-group.e-control-wrapper.e-float-icon-left.e-rtl .e-input-in-wrap{margin-left:0;margin-right:4px}.e-filled.e-input-group.e-float-icon-left:not(.e-float-input):before,.e-filled.e-input-group.e-float-icon-left:not(.e-float-input):after,.e-filled.e-input-group.e-control-wrapper.e-float-icon-left:not(.e-float-input):before,.e-filled.e-input-group.e-control-wrapper.e-float-icon-left:not(.e-float-input):after{-moz-transition:.2s cubic-bezier(.4,0,.4,1);content:"";height:2px;position:absolute;transition:.2s cubic-bezier(.4,0,.4,1);width:0;bottom:-1px}.e-filled.e-input-group.e-float-icon-left:not(.e-float-input).e-input-focus:before,.e-filled.e-input-group.e-float-icon-left:not(.e-float-input).e-input-focus:after,.e-filled.e-input-group.e-control-wrapper.e-float-icon-left:not(.e-float-input).e-input-focus:before,.e-filled.e-input-group.e-control-wrapper.e-float-icon-left:not(.e-float-input).e-input-focus:after{width:50%;bottom:-1px}.e-filled.e-input-group.e-float-icon-left:not(.e-float-input).e-input-focus .e-input-in-wrap:before,.e-filled.e-input-group.e-float-icon-left:not(.e-float-input).e-input-focus .e-input-in-wrap:after,.e-filled.e-input-group.e-control-wrapper.e-float-icon-left:not(.e-float-input).e-input-focus .e-input-in-wrap:before,.e-filled.e-input-group.e-control-wrapper.e-float-icon-left:not(.e-float-input).e-input-focus .e-input-in-wrap:after{width:0}.e-filled.e-input-group.e-float-icon-left,.e-filled.e-input-group.e-success.e-float-icon-left,.e-filled.e-input-group.e-warning.e-float-icon-left,.e-filled.e-input-group.e-error.e-float-icon-left,.e-filled.e-input-group.e-control-wrapper.e-float-icon-left,.e-filled.e-input-group.e-control-wrapper.e-success.e-float-icon-left,.e-filled.e-input-group.e-control-wrapper.e-warning.e-float-icon-left,.e-filled.e-input-group.e-control-wrapper.e-error.e-float-icon-left{border:1px solid;border-width:0 0 1px 0}.e-input-group.e-control-container.e-control-wrapper.e-float-input.e-prepend.e-append:not(.e-outline) .e-input-in-wrap,.e-input-group.e-control-container.e-control-wrapper.e-float-input.e-prepend:not(.e-outline) .e-input-in-wrap{border-bottom:1px solid;border-bottom-color:#0000006b}.e-error.e-input-group.e-control-container.e-control-wrapper.e-float-input.e-prepend.e-append .e-input-in-wrap,.e-error.e-input-group.e-control-container.e-control-wrapper.e-float-input.e-prepend .e-input-in-wrap{border-bottom:1px solid;border-bottom-color:#f44336}.e-success.e-input-group.e-control-container.e-control-wrapper.e-float-input.e-prepend.e-append .e-input-in-wrap,.e-success.e-input-group.e-control-container.e-control-wrapper.e-float-input.e-prepend .e-input-in-wrap{border-bottom:1px solid;border-bottom-color:#22b24b}.e-input-group:not(.e-outline).e-prepend.e-input-focus:not(.e-float-icon-left):not(.e-success):not(.e-warning):not(.e-error),.e-input-group:not(.e-outline).e-control-wrapper.e-prepend.e-input-focus:not(.e-float-icon-left):not(.e-success):not(.e-warning):not(.e-error),.e-float-input:not(.e-outline).e-input-group.e-prepend.e-input-focus:not(.e-float-icon-left):not(.e-success):not(.e-warning):not(.e-error),.e-float-input:not(.e-outline).e-input-group.e-prepend.e-input-focus:not(.e-float-icon-left).e-success:not(.e-warning):not(.e-error),.e-float-input:not(.e-outline).e-input-group.e-prepend.e-input-focus:not(.e-float-icon-left):not(.e-success).e-warning:not(.e-error),.e-float-input:not(.e-outline).e-input-group.e-prepend.e-input-focus:not(.e-float-icon-left):not(.e-success):not(.e-warning).e-error,.e-float-input:not(.e-outline).e-control-wrapper.e-input-group.e-prepend.e-input-focus:not(.e-float-icon-left):not(.e-success):not(.e-warning):not(.e-error),.e-float-input:not(.e-outline).e-control-wrapper.e-input-group.e-prepend.e-input-focus:not(.e-float-icon-left).e-success:not(.e-warning):not(.e-error),.e-float-input:not(.e-outline).e-control-wrapper.e-input-group.e-prepend.e-input-focus:not(.e-float-icon-left):not(.e-success).e-warning:not(.e-error),.e-float-input:not(.e-outline).e-control-wrapper.e-input-group.e-prepend.e-input-focus:not(.e-float-icon-left):not(.e-success):not(.e-warning).e-error,.e-float-input:not(.e-outline).e-control-wrapper.e-prepend.e-input-focus:not(.e-input-group):not(.e-float-icon-left):not(.e-disabled):not(.e-success):not(.e-warning):not(.e-error) input,.e-float-input:not(.e-outline).e-control-wrapper.e-prepend.e-input-focus:not(.e-input-group):not(.e-float-icon-left):not(.e-disabled).e-success:not(.e-warning):not(.e-error) input,.e-float-input:not(.e-outline).e-control-wrapper.e-prepend.e-input-focus:not(.e-input-group):not(.e-float-icon-left):not(.e-disabled):not(.e-success).e-warning:not(.e-error) input,.e-float-input:not(.e-outline).e-control-wrapper.e-prepend.e-input-focus:not(.e-input-group):not(.e-float-icon-left):not(.e-disabled):not(.e-success):not(.e-warning).e-error input,.e-float-input:not(.e-outline).e-control-wrapper.e-prepend.e-input-focus:not(.e-input-group):not(.e-float-icon-left):not(.e-disabled):not(.e-success):not(.e-warning):not(.e-error) textarea,.e-float-input:not(.e-outline).e-control-wrapper.e-prepend.e-input-focus:not(.e-input-group):not(.e-float-icon-left):not(.e-disabled).e-success:not(.e-warning):not(.e-error) textarea,.e-float-input:not(.e-outline).e-control-wrapper.e-prepend.e-input-focus:not(.e-input-group):not(.e-float-icon-left):not(.e-disabled):not(.e-success).e-warning:not(.e-error) textarea,.e-float-input:not(.e-outline).e-control-wrapper.e-prepend.e-input-focus:not(.e-input-group):not(.e-float-icon-left):not(.e-disabled):not(.e-success):not(.e-warning).e-error textarea,.e-float-input:not(.e-outline).e-prepend.e-input-focus:not(.e-input-group):not(.e-float-icon-left):not(.e-disabled):not(.e-success):not(.e-warning):not(.e-error) input,.e-float-input:not(.e-outline).e-prepend.e-input-focus:not(.e-input-group):not(.e-float-icon-left):not(.e-disabled).e-success:not(.e-warning):not(.e-error) input,.e-float-input:not(.e-outline).e-prepend.e-input-focus:not(.e-input-group):not(.e-float-icon-left):not(.e-disabled):not(.e-success).e-warning:not(.e-error) input,.e-float-input:not(.e-outline).e-prepend.e-input-focus:not(.e-input-group):not(.e-float-icon-left):not(.e-disabled):not(.e-success):not(.e-warning).e-error input,.e-float-input:not(.e-outline).e-prepend.e-input-focus:not(.e-input-group):not(.e-float-icon-left):not(.e-disabled):not(.e-success):not(.e-warning):not(.e-error) textarea,.e-float-input:not(.e-outline).e-prepend.e-input-focus:not(.e-input-group):not(.e-float-icon-left):not(.e-disabled).e-success:not(.e-warning):not(.e-error) textarea,.e-float-input:not(.e-outline).e-prepend.e-input-focus:not(.e-input-group):not(.e-float-icon-left):not(.e-disabled):not(.e-success).e-warning:not(.e-error) textarea,.e-float-input:not(.e-outline).e-prepend.e-input-focus:not(.e-input-group):not(.e-float-icon-left):not(.e-disabled):not(.e-success):not(.e-warning).e-error textarea,.e-input-group:not(.e-outline).e-prepend.e-input-focus:not(.e-float-icon-left).e-success:not(.e-warning):not(.e-error),.e-input-group:not(.e-outline).e-prepend.e-input-focus:not(.e-float-icon-left).e-warning:not(.e-success):not(.e-error),.e-input-group:not(.e-outline).e-control-wrapper.e-prepend.e-input-focus:not(.e-float-icon-left).e-success:not(.e-warning):not(.e-error),.e-input-group:not(.e-outline).e-control-wrapper.e-prepend.e-input-focus:not(.e-float-icon-left).e-warning:not(.e-success):not(.e-error),.e-input-group:not(.e-outline).e-prepend.e-input-focus:not(.e-float-icon-left).e-error:not(.e-success):not(.e-warning),.e-input-group:not(.e-outline).e-float-icon-left.e-prepend.e-input-focus:not(.e-success):not(.e-warning):not(.e-error) .e-input-in-wrap,.e-input-group:not(.e-outline).e-float-icon-left.e-prepend.e-input-focus.e-success:not(.e-warning):not(.e-error) .e-input-in-wrap,.e-input-group:not(.e-outline).e-float-icon-left.e-prepend.e-input-focus.e-warning:not(.e-success):not(.e-error) .e-input-in-wrap,.e-input-group:not(.e-outline).e-float-icon-left.e-prepend.e-input-focus.e-error:not(.e-success):not(.e-warning) .e-input-in-wrap,.e-input-group:not(.e-outline).e-prepend:not(.e-float-icon-left),.e-input-group:not(.e-outline).e-prepend.e-success:not(.e-float-icon-left),.e-input-group:not(.e-outline).e-prepend.e-warning:not(.e-float-icon-left),.e-input-group:not(.e-outline).e-prepend.e-error:not(.e-float-icon-left),.e-input-group:not(.e-outline).e-control-wrapper.e-prepend:not(.e-float-icon-left),.e-input-group:not(.e-outline).e-control-wrapper.e-prepend.e-success:not(.e-float-icon-left),.e-input-group:not(.e-outline).e-control-wrapper.e-prepend.e-warning:not(.e-float-icon-left),.e-input-group:not(.e-outline).e-control-wrapper.e-prepend.e-error:not(.e-float-icon-left),.e-input-group:not(.e-outline).e-prepend:hover:not(.e-disabled):not(.e-float-icon-left),.e-input-group:not(.e-outline).e-control-wrapper.e-prepend:hover:not(.e-disabled):not(.e-float-icon-left),.e-float-input:not(.e-outline).e-prepend:hover:not(.e-disabled):not(.e-float-icon-left),.e-float-input:not(.e-outline).e-prepend:hover:not(.e-input-group):not(.e-disabled) input:not([disabled]),.e-float-input:not(.e-outline).e-prepend:hover:not(.e-input-group):not(.e-disabled) textarea:not([disabled]),.e-float-input:not(.e-outline).e-control-wrapper.e-prepend:hover:not(.e-disabled):not(.e-float-icon-left),.e-float-input:not(.e-outline).e-control-wrapper.e-prepend:hover:not(.e-input-group):not(.e-disabled) input:not([disabled]),.e-float-input:not(.e-outline).e-control-wrapper.e-prepend:hover:not(.e-input-group):not(.e-disabled) textarea:not([disabled]){border-bottom:transparent}/*! input theme */input.e-input,.e-input-group input.e-input,.e-input-group.e-control-wrapper input.e-input,.e-input-group textarea.e-input,.e-input-group.e-control-wrapper textarea.e-input,textarea.e-input,.e-float-input input,.e-float-input.e-control-wrapper input,.e-float-input textarea,.e-float-input.e-control-wrapper textarea{background:transparent;border-color:#0000006b;color:#000000de}.e-input-group,.e-input-group.e-control-wrapper,.e-float-input,.e-float-input.e-input-group,.e-float-input.e-control-wrapper,.e-float-input.e-input-group.e-control-wrapper{background:transparent;color:#000000de}.e-input-group .e-input-group-icon,.e-input-group.e-control-wrapper .e-input-group-icon{background:transparent;border-color:#0000006b;color:#0000008a}.e-input-group.e-disabled .e-input-group-icon,.e-input-group.e-control-wrapper.e-disabled .e-input-group-icon,.e-float-input.e-disabled .e-clear-icon,.e-float-input.e-control-wrapper.e-disabled .e-clear-icon,.e-input-group.e-disabled .e-clear-icon,.e-input-group.e-control-wrapper.e-disabled .e-clear-icon{color:#00000042}.e-input[disabled],.e-input-group .e-input[disabled],.e-input-group.e-control-wrapper .e-input[disabled],.e-input-group.e-disabled,.e-input-group.e-control-wrapper.e-disabled,.e-float-input input[disabled],.e-float-input.e-control-wrapper input[disabled],.e-float-input textarea[disabled],.e-float-input.e-control-wrapper textarea[disabled],.e-float-input.e-disabled,.e-float-input.e-control-wrapper.e-disabled{-webkit-text-fill-color:rgba(0,0,0,.42);background:transparent;color:#0000006b;background-image:linear-gradient(90deg,rgba(0,0,0,.42) 0,rgba(0,0,0,.42) 33%,transparent 0);background-position:bottom -1px left 0;background-repeat:repeat-x;background-size:4px 1px;border-bottom-color:transparent}.e-input-group input.e-input,.e-input-group.e-control-wrapper input.e-input,.e-float-input input,.e-float-input.e-control-wrapper input,.e-input-group textarea.e-input,.e-input-group.e-control-wrapper textarea.e-input,.e-float-input textarea,.e-float-input.e-control-wrapper textarea,.e-input-group .e-input[disabled],.e-input-group.e-control-wrapper .e-input[disabled],.e-input-group.e-disabled input.e-input,.e-input-group.e-control-wrapper.e-disabled input.e-input,.e-input-group.e-disabled textarea.e-input,.e-input-group.e-control-wrapper.e-disabled textarea.e-input,.e-input-group .e-input[readonly],.e-input-group.e-control-wrapper .e-input[readonly],.e-float-input input[readonly],.e-float-input.e-control-wrapper input[readonly],.e-float-input textarea[readonly],.e-float-input.e-control-wrapper textarea[readonly]{background:none;color:inherit}.e-float-input.e-disabled input,.e-float-input.e-control-wrapper.e-disabled input,.e-float-input.e-disabled textarea,.e-float-input.e-control-wrapper.e-disabled textarea,.e-float-input input[disabled],.e-float-input.e-control-wrapper input[disabled],.e-float-input textarea[disabled],.e-float-input.e-control-wrapper textarea[disabled]{color:inherit}/*! Added color to textbox for disbaled state */.e-float-input:not(.e-disabled) input[disabled],.e-float-input.e-control-wrapper:not(.e-disabled) input[disabled],.e-float-input:not(.e-disabled) textarea[disabled],.e-float-input.e-control-wrapper:not(.e-disabled) textarea[disabled]{-webkit-text-fill-color:rgba(0,0,0,.42);color:#0000006b}.e-input-group.e-disabled .e-input-group-icon,.e-input-group.e-control-wrapper.e-disabled .e-input-group-icon{background:transparent;border-color:#0000006b}.e-input-group:not(.e-disabled) .e-input-group-icon:hover,.e-input-group.e-control-wrapper:not(.e-disabled) .e-input-group-icon:hover{color:#0000008a}.e-input-group.e-disabled .e-input-group-icon:hover,.e-input-group.e-control-wrapper.e-disabled .e-input-group-icon:hover{background:transparent}.e-input.e-success,.e-input.e-success:focus,.e-input-group.e-success input.e-input,.e-input-group.e-control-wrapper.e-success input.e-input,.e-input-group.e-success .e-input-group-icon,.e-input-group.e-control-wrapper.e-success .e-input-group-icon,.e-input-group.e-success textarea.e-input,.e-input-group.e-control-wrapper.e-success textarea.e-input{border-color:#22b24b}.e-input.e-warning,.e-input.e-warning:focus,.e-input-group.e-warning input.e-input,.e-input-group.e-control-wrapper.e-warning input.e-input,.e-input-group.e-warning .e-input-group-icon,.e-input-group.e-control-wrapper.e-warning .e-input-group-icon,.e-input-group.e-warning textarea.e-input,.e-input-group.e-control-wrapper.e-warning textarea.e-input{border-color:#ffca1c}.e-input.e-error,.e-input.e-error:focus,.e-input-group.e-error input.e-input,.e-input-group.e-control-wrapper.e-error input.e-input,.e-input-group.e-control-wrapper.e-error .e-input-group-icon,.e-input-group.e-error .e-input-group-icon,.e-input-group.e-error textarea.e-input,.e-input-group.e-control-wrapper.e-error textarea.e-input{border-color:#f44336}label.e-float-text,.e-float-input:not(.e-error):not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-float-input.e-control-wrapper:not(.e-error):not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-float-input.e-small:not(.e-error):not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-float-input.e-control-wrapper.e-small:not(.e-error):not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small .e-float-input:not(.e-error):not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small .e-float-input.e-control-wrapper:not(.e-error):not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom{color:#0000006b}.e-float-input.e-error label.e-float-text,.e-float-input.e-control-wrapper.e-error label.e-float-text,.e-float-input.e-error input:focus~label.e-float-text,.e-float-input.e-control-wrapper.e-error input:focus~label.e-float-text,.e-float-input.e-error.e-input-focus input~label.e-float-text,.e-float-input.e-control-wrapper.e-error.e-input-focus input~label.e-float-text,.e-float-input.e-error textarea:focus~label.e-float-text,.e-float-input.e-control-wrapper.e-error textarea:focus~label.e-float-text{color:#f44336}.e-float-input input,.e-float-input textarea,.e-float-input.e-control-wrapper input,.e-float-input.e-control-wrapper textarea,.e-input-group,.e-input-group.e-control-wrapper{border-bottom-color:#0000006b}.e-float-input.e-success input,.e-float-input.e-success textarea,.e-float-input.e-control-wrapper.e-success input,.e-float-input.e-control-wrapper.e-success textarea{border-bottom-color:#22b24b}.e-float-input.e-warning input,.e-float-input.e-control-wrapper.e-warning input,.e-float-input.e-warning textarea,.e-float-input.e-control-wrapper.e-warning textarea{border-bottom-color:#ffca1c}.e-float-input.e-error input,.e-float-input.e-control-wrapper.e-error input,.e-float-input.e-error textarea,.e-float-input.e-control-wrapper.e-error textarea{border-bottom-color:#f44336}.e-float-input:not(.e-input-group) .e-float-line:before,.e-float-input:not(.e-input-group) .e-float-line:after,.e-float-input.e-control-wrapper:not(.e-input-group) .e-float-line:before,.e-float-input.e-control-wrapper:not(.e-input-group) .e-float-line:after{background:#e3165b}.e-float-input.e-success:not(.e-input-group) .e-float-line:before,.e-float-input.e-success:not(.e-input-group) .e-float-line:after,.e-float-input.e-control-wrapper.e-success:not(.e-input-group) .e-float-line:before,.e-float-input.e-control-wrapper.e-success:not(.e-input-group) .e-float-line:after{background:#22b24b}.e-float-input.e-warning:not(.e-input-group) .e-float-line:before,.e-float-input.e-warning:not(.e-input-group) .e-float-line:after,.e-float-input.e-control-wrapper.e-warning:not(.e-input-group) .e-float-line:before,.e-float-input.e-control-wrapper.e-warning:not(.e-input-group) .e-float-line:after{background:#ffca1c}input.e-input:-moz-placeholder,textarea.e-input:-moz-placeholder,input.e-input::-moz-placeholder,textarea.e-input::-moz-placeholder,.e-input-group input.e-input:-moz-placeholder,.e-input-group.e-control-wrapper input.e-input:-moz-placeholder,.e-input-group textarea.e-input:-moz-placeholder,.e-input-group.e-control-wrapper textarea.e-input:-moz-placeholder,.e-input-group input.e-input::-moz-placeholder,.e-input-group.e-control-wrapper input.e-input::-moz-placeholder,.e-input-group textarea.e-input::-moz-placeholder,.e-input-group.e-control-wrapper textarea.e-input::-moz-placeholder{color:#0000006b}input.e-input::-webkit-input-placeholder,textarea.e-input::-webkit-input-placeholder,.e-input-group input.e-input::-webkit-input-placeholder,.e-input-group textarea.e-input::-webkit-input-placeholder,.e-input-group.e-control-wrapper input.e-input::-webkit-input-placeholder,.e-input-group.e-control-wrapper textarea.e-input::-webkit-input-placeholder{color:#0000006b}input.e-input:-ms-input-placeholder,textarea.e-input:-ms-input-placeholder,.e-input-group input.e-input:-ms-input-placeholder,.e-input-group.e-control-wrapper input.e-input:-ms-input-placeholder,.e-input-group.e-control-wrapper textarea.e-input:-ms-input-placeholder,.e-input-group textarea.e-input:-ms-input-placeholder{color:#0000006b}.e-float-input:not(.e-error):not(.e-input-focus):not(.e-disabled) input:not(:focus):not(:valid)~label.e-float-text:not(.e-label-top),.e-float-input:not(.e-error):not(.e-input-focus) textarea:not(:focus):not(:valid)~label.e-float-text:not(.e-label-top),.e-float-input.e-control-wrapper:not(.e-error):not(.e-input-focus):not(.e-disabled) input:not(:focus):not(:valid)~label.e-float-text:not(.e-label-top),.e-float-input:not(.e-input-focus):not(.e-disabled) textarea:not(:focus):not(:valid)~label.e-float-text:not(.e-label-top),.e-float-input:not(.e-input-focus) textarea:not(:focus):not(:valid)~label.e-float-text:not(.e-label-top),.e-float-input.e-control-wrapper:not(.e-input-focus):not(.e-disabled) textarea:not(:focus):not(:valid)~label.e-float-text:not(.e-label-top){color:#0000006b}.e-float-input.e-error:not(.e-input-group) .e-float-line:before,.e-float-input.e-error:not(.e-input-group) .e-float-line:after,.e-float-input.e-control-wrapper.e-error:not(.e-input-group) .e-float-line:before,.e-float-input.e-control-wrapper.e-error:not(.e-input-group) .e-float-line:after{background:#f44336}.e-input-group:not(.e-disabled) .e-input-group-icon:active,.e-input-group.e-control-wrapper:not(.e-disabled) .e-input-group-icon:active{background:transparent;color:#0000008a}input.e-input::selection,textarea.e-input::selection,.e-input-group input.e-input::selection,.e-input-group.e-control-wrapper input.e-input::selection,.e-float-input input::selection,.e-float-input.e-control-wrapper input::selection,.e-input-group textarea.e-input::selection,.e-input-group.e-control-wrapper textarea.e-input::selection,.e-float-input textarea::selection,.e-float-input.e-control-wrapper textarea::selection,.e-float-input.e-small textarea::selection{background:#e3165b;color:#fff}.e-input-group:not(.e-float-icon-left):not(.e-float-input):before,.e-input-group:not(.e-float-icon-left):not(.e-float-input):after,.e-input-group.e-float-icon-left:not(.e-float-input) .e-input-in-wrap:before,.e-input-group.e-float-icon-left:not(.e-float-input) .e-input-in-wrap:after,.e-input-group.e-control-wrapper:not(.e-float-icon-left):not(.e-float-input):before,.e-input-group.e-control-wrapper:not(.e-float-icon-left):not(.e-float-input):after,.e-input-group.e-control-wrapper.e-float-icon-left:not(.e-float-input) .e-input-in-wrap:before,.e-input-group.e-control-wrapper.e-float-icon-left:not(.e-float-input) .e-input-in-wrap:after,.e-float-input.e-input-group:not(.e-float-icon-left) .e-float-line:before,.e-float-input.e-input-group:not(.e-float-icon-left) .e-float-line:after,.e-float-input.e-input-group.e-float-icon-left .e-input-in-wrap .e-float-line:before,.e-float-input.e-input-group.e-float-icon-left .e-input-in-wrap .e-float-line:after,.e-float-input.e-control-wrapper.e-input-group:not(.e-float-icon-left) .e-float-line:before,.e-float-input.e-control-wrapper.e-input-group:not(.e-float-icon-left) .e-float-line:after,.e-float-input.e-control-wrapper.e-input-group.e-float-icon-left .e-input-in-wrap .e-float-line:before,.e-float-input.e-control-wrapper.e-input-group.e-float-icon-left .e-input-in-wrap .e-float-line:after,.e-filled.e-input-group.e-float-icon-left:not(.e-float-input):before,.e-filled.e-input-group.e-float-icon-left:not(.e-float-input):after,.e-filled.e-input-group.e-control-wrapper.e-float-icon-left:not(.e-float-input):before,.e-filled.e-input-group.e-control-wrapper.e-float-icon-left:not(.e-float-input):after,.e-filled.e-float-input.e-input-group.e-float-icon-left .e-float-line:before,.e-filled.e-float-input.e-input-group.e-float-icon-left .e-float-line:after,.e-filled.e-float-input.e-control-wrapper.e-input-group.e-float-icon-left .e-float-line:before,.e-filled.e-float-input.e-control-wrapper.e-input-group.e-float-icon-left .e-float-line:after{background:#e3165b}.e-input-group:not(.e-float-icon-left):not(.e-float-input).e-success:before,.e-input-group:not(.e-float-icon-left):not(.e-float-input).e-success:after,.e-input-group.e-float-icon-left.e-success:not(.e-float-input) .e-input-in-wrap:before,.e-input-group.e-float-icon-left.e-success:not(.e-float-input) .e-input-in-wrap:after,.e-input-group.e-control-wrapper:not(.e-float-icon-left):not(.e-float-input).e-success:before,.e-input-group.e-control-wrapper:not(.e-float-icon-left):not(.e-float-input).e-success:after,.e-input-group.e-control-wrapper.e-float-icon-left.e-success:not(.e-float-input) .e-input-in-wrap:before,.e-input-group.e-control-wrapper.e-float-icon-left.e-success:not(.e-float-input) .e-input-in-wrap:after,.e-float-input.e-input-group:not(.e-float-icon-left).e-success .e-float-line:before,.e-float-input.e-input-group:not(.e-float-icon-left).e-success .e-float-line:after,.e-float-input.e-input-group.e-float-icon-left.e-success .e-input-in-wrap .e-float-line:before,.e-float-input.e-input-group.e-float-icon-left.e-success .e-input-in-wrap .e-float-line:after,.e-float-input.e-control-wrapper.e-input-group:not(.e-float-icon-left).e-success .e-float-line:before,.e-float-input.e-control-wrapper.e-input-group:not(.e-float-icon-left).e-success .e-float-line:after,.e-float-input.e-control-wrapper.e-input-group.e-float-icon-left.e-success .e-input-in-wrap .e-float-line:before,.e-float-input.e-control-wrapper.e-input-group.e-float-icon-left.e-success .e-input-in-wrap .e-float-line:after,.e-float-input.e-input-group.e-control-wrapper:not(.e-float-icon-left).e-success .e-float-line:before,.e-float-input.e-input-group.e-control-wrapper:not(.e-float-icon-left).e-success .e-float-line:after,.e-float-input.e-input-group.e-control-wrapper.e-float-icon-left.e-success .e-input-in-wrap .e-float-line:before,.e-float-input.e-input-group.e-control-wrapper.e-float-icon-left.e-success .e-input-in-wrap .e-float-line:after,.e-filled.e-input-group.e-float-icon-left.e-success:not(.e-float-input):before,.e-filled.e-input-group.e-float-icon-left.e-success:not(.e-float-input):after,.e-filled.e-input-group.e-control-wrapper.e-float-icon-left.e-success:not(.e-float-input):before,.e-filled.e-input-group.e-control-wrapper.e-float-icon-left.e-success:not(.e-float-input):after,.e-filled.e-float-input.e-input-group.e-float-icon-left.e-success .e-float-line:before,.e-filled.e-float-input.e-input-group.e-float-icon-left.e-success .e-float-line:after,.e-filled.e-float-input.e-control-wrapper.e-input-group.e-float-icon-left.e-success .e-float-line:before,.e-filled.e-float-input.e-control-wrapper.e-input-group.e-float-icon-left.e-success .e-float-line:after,.e-filled.e-float-input.e-input-group.e-control-wrapper.e-float-icon-left.e-success .e-float-line:before,.e-filled.e-float-input.e-input-group.e-control-wrapper.e-float-icon-left.e-success .e-float-line:after{background:#22b24b}.e-input-group:not(.e-float-icon-left).e-warning:not(.e-float-input):before,.e-input-group:not(.e-float-icon-left).e-warning:not(.e-float-input):after,.e-input-group.e-float-icon-left.e-warning:not(.e-float-input) .e-input-in-wrap:before,.e-input-group.e-float-icon-left.e-warning:not(.e-float-input) .e-input-in-wrap:after,.e-input-group.e-control-wrapper:not(.e-float-icon-left).e-warning:not(.e-float-input):before,.e-input-group.e-control-wrapper:not(.e-float-icon-left).e-warning:not(.e-float-input):after,.e-input-group.e-control-wrapper.e-float-icon-left.e-warning:not(.e-float-input) .e-input-in-wrap:before,.e-input-group.e-control-wrapper.e-float-icon-left.e-warning:not(.e-float-input) .e-input-in-wrap:after,.e-float-input.e-input-group:not(.e-float-icon-left).e-warning .e-float-line:before,.e-float-input.e-input-group:not(.e-float-icon-left).e-warning .e-float-line:after,.e-float-input.e-control-wrapper.e-input-group.e-float-icon-left.e-warning .e-input-in-wrap .e-float-line:before,.e-float-input.e-control-wrapper.e-input-group.e-float-icon-left.e-warning .e-input-in-wrap .e-float-line:after,.e-filled.e-input-group.e-float-icon-left.e-warning:not(.e-float-input):before,.e-filled.e-input-group.e-float-icon-left.e-warning:not(.e-float-input):after,.e-filled.e-input-group.e-control-wrapper.e-float-icon-left.e-warning:not(.e-float-input):before,.e-filled.e-input-group.e-control-wrapper.e-float-icon-left.e-warning:not(.e-float-input):after,.e-filled.e-float-input.e-control-wrapper.e-input-group.e-float-icon-left.e-warning .e-float-line:before,.e-filled.e-float-input.e-control-wrapper.e-input-group.e-float-icon-left.e-warning .e-float-line:after{background:#ffca1c}.e-input-group:not(.e-float-icon-left).e-error:not(.e-float-input):before,.e-input-group:not(.e-float-icon-left).e-error:not(.e-float-input):after,.e-input-group.e-float-icon-left.e-error:not(.e-float-input) .e-input-in-wrap:before,.e-input-group.e-float-icon-left.e-error:not(.e-float-input) .e-input-in-wrap:after,.e-input-group.e-control-wrapper:not(.e-float-icon-left).e-error:not(.e-float-input):before,.e-input-group.e-control-wrapper:not(.e-float-icon-left).e-error:not(.e-float-input):after,.e-input-group.e-control-wrapper.e-float-icon-left.e-error:not(.e-float-input) .e-input-in-wrap:before,.e-input-group.e-control-wrapper.e-float-icon-left.e-error:not(.e-float-input) .e-input-in-wrap:after,.e-float-input.e-input-group:not(.e-float-icon-left).e-error .e-float-line:before,.e-float-input.e-input-group:not(.e-float-icon-left).e-error .e-float-line:after,.e-float-input.e-input-group.e-float-icon-left.e-error .e-input-in-wrap .e-float-line:before,.e-float-input.e-input-group.e-float-icon-left.e-error .e-input-in-wrap .e-float-line:after,.e-float-input.e-input-group.e-control-wrapper:not(.e-float-icon-left).e-error .e-float-line:before,.e-float-input.e-input-group.e-control-wrapper:not(.e-float-icon-left).e-error .e-float-line:after,.e-float-input.e-input-group.e-control-wrapper.e-float-icon-left.e-error .e-input-in-wrap .e-float-line:before,.e-float-input.e-input-group.e-control-wrapper.e-float-icon-left.e-error .e-input-in-wrap .e-float-line:after,.e-filled.e-input-group.e-float-icon-left.e-error:not(.e-float-input):before,.e-filled.e-input-group.e-float-icon-left.e-error:not(.e-float-input):after,.e-filled.e-input-group.e-control-wrapper.e-float-icon-left.e-error:not(.e-float-input):before,.e-filled.e-input-group.e-control-wrapper.e-float-icon-left.e-error:not(.e-float-input):after,.e-filled.e-float-input.e-input-group.e-float-icon-left.e-error .e-float-line:before,.e-filled.e-float-input.e-input-group.e-float-icon-left.e-error .e-float-line:after,.e-filled.e-float-input.e-input-group.e-control-wrapper.e-float-icon-left.e-error .e-float-line:before,.e-filled.e-float-input.e-input-group.e-control-wrapper.e-float-icon-left.e-error .e-float-line:after{background:#f44336}.e-input-group.e-success .e-input-group-icon,.e-input-group.e-control-wrapper.e-success .e-input-group-icon,.e-input-group.e-warning .e-input-group-icon,.e-input-group.e-control-wrapper.e-warning .e-input-group-icon,.e-input-group.e-error .e-input-group-icon,.e-input-group.e-control-wrapper.e-error .e-input-group-icon{color:#0000008a}.e-input-group.e-success:not(.e-disabled):not(:active) .e-input-group-icon:hover,.e-input-group.e-control-wrapper.e-success:not(.e-disabled):not(:active) .e-input-group-icon:hover,.e-input-group.e-warning:not(.e-disabled):not(:active) .e-input-group-icon:hover,.e-input-group.e-control-wrapper.e-warning:not(.e-disabled):not(:active) .e-input-group-icon:hover,.e-input-group.e-error:not(.e-disabled):not(:active) .e-input-group-icon:hover,.e-input-group.e-control-wrapper.e-error:not(.e-disabled):not(:active) .e-input-group-icon:hover{color:#0000008a}.e-input-group.e-success:not(.e-disabled) .e-input-group-icon:active,.e-input-group.e-control-wrapper.e-success:not(.e-disabled) .e-input-group-icon:active,.e-input-group.e-warning:not(.e-disabled) .e-input-group-icon:active,.e-input-group.e-control-wrapper.e-warning:not(.e-disabled) .e-input-group-icon:active,.e-input-group.e-error:not(.e-disabled) .e-input-group-icon:active,.e-input-group.e-control-wrapper.e-error:not(.e-disabled) .e-input-group-icon:active{color:#0000008a}.e-input-group input.e-input,.e-input-group.e-control-wrapper input.e-input,.e-input-group textarea.e-input,.e-input-group.e-control-wrapper textarea.e-input,.e-input-group.e-input-focus:not(.e-success):not(.e-warning):not(.e-error) .e-input:focus,.e-input-group.e-control-wrapper.e-input-focus:not(.e-success):not(.e-warning):not(.e-error) .e-input:focus,.e-input-group.e-input-focus:not(.e-success):not(.e-warning):not(.e-error) .e-input,.e-input-group.e-control-wrapper.e-input-focus:not(.e-success):not(.e-warning):not(.e-error) .e-input{border-color:#0000006b}.e-input:focus:not(.e-success):not(.e-warning):not(.e-error),.e-float-input:not(.e-success):not(.e-warning):not(.e-error):not(.e-input-group) input:focus,.e-float-input:not(.e-success):not(.e-warning):not(.e-error):not(.e-input-group) textarea:focus,.e-float-input.e-control-wrapper:not(.e-success):not(.e-warning):not(.e-error):not(.e-input-group) input:focus,.e-float-input.e-control-wrapper:not(.e-success):not(.e-warning):not(.e-error):not(.e-input-group) textarea:focus,.e-float-input:not(.e-success):not(.e-warning):not(.e-error):not(.e-input-group).e-input-focus input,.e-float-input.e-control-wrapper:not(.e-success):not(.e-warning):not(.e-error):not(.e-input-group).e-input-focus input{border-color:#e3165b}.e-input-group:not(.e-success):not(.e-warning):not(.e-error) input.e-input:focus,.e-input-group.e-control-wrapper:not(.e-success):not(.e-warning):not(.e-error) input.e-input:focus,.e-input-group:not(.e-success):not(.e-warning):not(.e-error).e-input-focus input.e-input,.e-input-group.e-control-wrapper:not(.e-success):not(.e-warning):not(.e-error).e-input-focus input.e-input,.e-input-group:not(.e-success):not(.e-warning):not(.e-error) textarea.e-input:focus,.e-input-group.e-control-wrapper:not(.e-success):not(.e-warning):not(.e-error) textarea.e-input:focus{border-color:transparent}.e-input-group.e-input-focus:not(.e-success):not(.e-warning):not(.e-error):not(.e-float-icon-left),.e-input-group.e-control-wrapper.e-input-focus:not(.e-success):not(.e-warning):not(.e-error):not(.e-float-icon-left),.e-input-group.e-input-focus:hover:not(.e-success):not(.e-warning):not(.e-error):not(.e-disabled):not(.e-float-icon-left),.e-input-group.e-control-wrapper.e-input-focus:hover:not(.e-success):not(.e-warning):not(.e-error):not(.e-disabled):not(.e-float-icon-left),.e-float-input.e-input-focus:hover:not(.e-success):not(.e-warning):not(.e-error):not(.e-disabled):not(.e-float-icon-left),.e-float-input.e-control-wrapper.e-input-focus:hover:not(.e-success):not(.e-warning):not(.e-error):not(.e-disabled):not(.e-float-icon-left),.e-input-group.e-input-focus.e-float-icon-left:not(.e-success):not(.e-warning):not(.e-error):not(.e-disabled) .e-input-in-wrap:hover,.e-input-group.e-control-wrapper.e-input-focus.e-float-icon-left:not(.e-success):not(.e-warning):not(.e-error):not(.e-disabled) .e-input-in-wrap:hover,.e-float-input.e-input-focus.e-float-icon-left:not(.e-success):not(.e-warning):not(.e-error):not(.e-disabled) .e-input-in-wrap:hover,.e-float-input.e-input-focus:hover:not(.e-input-group):not(.e-success):not(.e-warning):not(.e-error):not(.e-disabled) input:not([disabled]),.e-float-input.e-input-focus:hover:not(.e-input-group):not(.e-success):not(.e-warning):not(.e-error):not(.e-disabled) textarea:not([disabled]),.e-float-input.e-control-wrapper.e-input-focus.e-float-icon-left:not(.e-success):not(.e-warning):not(.e-error):not(.e-disabled) .e-input-in-wrap:hover,.e-float-input.e-control-wrapper.e-input-focus:hover:not(.e-input-group):not(.e-success):not(.e-warning):not(.e-error):not(.e-disabled) input:not([disabled]),.e-float-input.e-control-wrapper.e-input-focus:hover:not(.e-input-group):not(.e-success):not(.e-warning):not(.e-error):not(.e-disabled) textarea:not([disabled]){border-color:#0000006b}.e-input-group.e-input-focus:not(.e-success):not(.e-warning):not(.e-error) .e-input:first-child:focus,.e-input-group.e-input-focus.e-rtl:not(.e-success):not(.e-warning):not(.e-error) span:last-child.e-input-group-icon,.e-input-group.e-control-wrapper.e-input-focus:not(.e-success):not(.e-warning):not(.e-error) .e-input:first-child:focus,.e-input-group.e-control-wrapper.e-input-focus.e-rtl:not(.e-success):not(.e-warning):not(.e-error) span:last-child.e-input-group-icon{border-color:transparent}.e-input-group.e-input-focus.e-rtl:not(.e-success):not(.e-warning):not(.e-error) span.e-input-group-icon,.e-input-group.e-input-focus.e-rtl:not(.e-success):not(.e-warning):not(.e-error) span:first-child.e-input-group-icon,.e-input-focus.e-rtl:not(.e-success):not(.e-warning):not(.e-error) .e-input:first-child:focus,.e-input-focus:not(.e-success):not(.e-warning):not(.e-error) .e-input:last-child:focus,.e-input-group.e-input-focus:not(.e-success):not(.e-warning):not(.e-error) span.e-input-group-icon,.e-input-group.e-control-wrapper.e-input-focus.e-rtl:not(.e-success):not(.e-warning):not(.e-error) span.e-input-group-icon,.e-input-group.e-control-wrapper.e-input-focus.e-rtl:not(.e-success):not(.e-warning):not(.e-error) span:first-child.e-input-group-icon,.e-input-focus.e-control-wrapper.e-rtl:not(.e-success):not(.e-warning):not(.e-error) .e-input:first-child:focus,.e-input-focus.e-control-wrapper:not(.e-success):not(.e-warning):not(.e-error) .e-input:last-child:focus,.e-input-group.e-control-wrapper.e-input-focus:not(.e-success):not(.e-warning):not(.e-error) span.e-input-group-icon{border-color:transparent}.e-input-group.e-input-focus:not(.e-success):not(.e-warning):not(.e-error) span:first-child.e-input-group-icon,.e-input-group.e-input-focus.e-rtl:not(.e-success):not(.e-warning):not(.e-error) .e-input:last-child:focus,.e-input-group.e-control-wrapper.e-input-focus:not(.e-success):not(.e-warning):not(.e-error) span:first-child.e-input-group-icon,.e-input-group.e-control-wrapper.e-input-focus.e-rtl:not(.e-success):not(.e-warning):not(.e-error) .e-input:last-child:focus{border-color:transparent}.e-input-group:not(.e-success):not(.e-warning):not(.e-error):not(.e-float-icon-left),.e-input-group.e-float-icon-left:not(.e-success):not(.e-warning):not(.e-error) .e-input-in-wrap,.e-input-group.e-control-wrapper:not(.e-success):not(.e-warning):not(.e-error):not(.e-float-icon-left),.e-input-group.e-control-wrapper.e-float-icon-left:not(.e-success):not(.e-warning):not(.e-error) .e-input-in-wrap,.e-float-input.e-float-icon-left:not(.e-success):not(.e-warning):not(.e-error) .e-input-in-wrap,.e-float-input.e-control-wrapper.e-float-icon-left:not(.e-success):not(.e-warning):not(.e-error) .e-input-in-wrap{border-color:#0000006b}.e-input-group.e-input-focus:not(.e-success):not(.e-warning):not(.e-error):not(.e-float-icon-left) .e-input:focus,.e-input-group.e-float-icon-left.e-input-focus:not(.e-success):not(.e-warning):not(.e-error) .e-input:focus,.e-input-group.e-control-wrapper.e-input-focus:not(.e-success):not(.e-warning):not(.e-error):not(.e-float-icon-left) .e-input:focus,.e-input-group.e-control-wrapper.e-float-icon-left.e-input-focus:not(.e-success):not(.e-warning):not(.e-error) .e-input:focus,.e-input-group.e-input-focus:not(.e-success):not(.e-warning):not(.e-error):not(.e-float-icon-left) .e-input,.e-input-group.e-float-icon-left.e-input-focus:not(.e-success):not(.e-warning):not(.e-error) .e-input,.e-input-group.e-control-wrapper.e-input-focus:not(.e-success):not(.e-warning):not(.e-error):not(.e-float-icon-left) .e-input,.e-input-group.e-control-wrapper.e-float-icon-left.e-input-focus:not(.e-success):not(.e-warning):not(.e-error) .e-input{border-bottom-color:transparent;border-top-color:transparent}.e-input-group.e-success,.e-input-group.e-control-wrapper.e-success,.e-float-icon-left.e-input-group.e-success,.e-float-icon-left.e-control-wrapper.e-input-group.e-success,.e-input-group.e-warning,.e-input-group.e-control-wrapper.e-warning,.e-float-icon-left.e-input-group.e-warning,.e-float-icon-left.e-input-group.e-control-wrapper.e-warning,.e-input-group.e-error,.e-input-group.e-control-wrapper.e-error,.e-float-icon-left.e-input-group.e-error,.e-float-icon-left.e-input-group.e-control-wrapper.e-error,.e-input-group.e-float-icon-left,.e-input-group.e-control-wrapper.e-float-icon-left{border-color:transparent}.e-input-group.e-success,.e-input-group.e-control-wrapper.e-success,.e-input-group.e-success:not(.e-float-icon-left),.e-input-group.e-control-wrapper.e-success:not(.e-float-icon-left){border-bottom-color:#22b24b}.e-input-group.e-float-icon-left.e-success .e-input-in-wrap,.e-input-group.e-control-wrapper.e-float-icon-left.e-success .e-input-in-wrap{border-bottom-color:#22b24b}.e-input-group.e-warning,.e-input-group.e-control-wrapper.e-warning,.e-input-group.e-warning:not(.e-float-icon-left),.e-input-group.e-control-wrapper.e-warning:not(.e-float-icon-left){border-bottom-color:#ffca1c}.e-input-group.e-float-icon-left.e-warning .e-input-in-wrap,.e-input-group.e-control-wrapper.e-float-icon-left.e-warning .e-input-in-wrap{border-bottom-color:#ffca1c}.e-input-group.e-error,.e-input-group.e-control-wrapper.e-error,.e-input-group.e-error:not(.e-float-icon-left),.e-input-group.e-control-wrapper.e-error:not(.e-float-icon-left){border-bottom-color:#f44336}.e-input-group.e-float-icon-left.e-error .e-input-in-wrap,.e-input-group.e-control-wrapper.e-float-icon-left.e-error .e-input-in-wrap{border-bottom-color:#f44336}.e-float-input .e-clear-icon,.e-float-input.e-control-wrapper .e-clear-icon,.e-input-group .e-clear-icon,.e-input-group.e-control-wrapper .e-clear-icon,.e-float-input .e-clear-icon:hover,.e-float-input.e-control-wrapper .e-clear-icon:hover,.e-input-group .e-clear-icon:hover,.e-input-group.e-control-wrapper .e-clear-icon:hover{color:#0000008a}.e-float-input.e-input-focus .e-input:focus,.e-float-input.e-control-wrapper.e-input-focus .e-input:focus{border-bottom-color:transparent;border-top-color:transparent}.e-float-input:not(.e-error) input:focus~label.e-float-text,.e-float-input:not(.e-error) input:valid~label.e-float-text,.e-float-input:not(.e-error) input~label.e-label-top.e-float-text,.e-float-input:not(.e-error) input[readonly]~label.e-label-top.e-float-text,.e-float-input:not(.e-error) input[disabled]~label.e-label-top.e-float-text,.e-float-input:not(.e-error) input label.e-float-text.e-label-top,.e-float-input:not(.e-error).e-input-focus input~label.e-float-text,.e-float-input.e-small:not(.e-error) input:focus~label.e-float-text,.e-float-input.e-small:not(.e-error) input:valid~label.e-float-text,.e-float-input.e-small:not(.e-error) input~label.e-label-top.e-float-text,.e-float-input.e-small:not(.e-error) input[readonly]~label.e-float-text,.e-float-input.e-small:not(.e-error) input[disabled]~label.e-float-text,.e-small .e-float-input:not(.e-error) input:focus~label.e-float-text,.e-small .e-float-input:not(.e-error) input:valid~label.e-float-text,.e-small .e-float-input:not(.e-error) input~label.e-label-top.e-float-text,.e-small .e-float-input:not(.e-error) input[readonly]~label.e-float-text.e-label-top,.e-small .e-float-input:not(.e-error) input[disabled]~label.e-float-text.e-label-top,.e-float-input.e-small:not(.e-error).e-input-focus input~label.e-float-text,.e-small .e-float-input:not(.e-error).e-input-focus input~label.e-float-text,.e-float-input.e-control-wrapper.e-small:not(.e-error) input:focus~label.e-float-text,.e-float-input.e-control-wrapper.e-small:not(.e-error) input:valid~label.e-float-text,.e-float-input.e-control-wrapper.e-small:not(.e-error) input~label.e-label-top.e-float-text,.e-float-input.e-control-wrapper.e-small:not(.e-error) input[readonly]~label.e-float-text,.e-float-input.e-control-wrapper.e-small:not(.e-error) input[disabled]~label.e-float-text,.e-small .e-float-input.e-control-wrapper:not(.e-error) input:focus~label.e-float-text,.e-small .e-float-input.e-control-wrapper:not(.e-error) input:valid~label.e-float-text,.e-small .e-float-input.e-control-wrapper:not(.e-error) input~label.e-label-top.e-float-text,.e-small .e-float-input.e-control-wrapper:not(.e-error) input[readonly]~label.e-float-text.e-label-top,.e-small .e-float-input.e-control-wrapper:not(.e-error) input[disabled]~label.e-float-text.e-label-top,.e-float-input.e-control-wrapper.e-small:not(.e-error).e-input-focus input~label.e-float-text,.e-small .e-float-input.e-control-wrapper:not(.e-error).e-input-focus input~label.e-float-text,.e-float-input:not(.e-error) textarea:focus~label.e-float-text,.e-float-input:not(.e-error) textarea:valid~label.e-float-text,.e-float-input:not(.e-error) textarea~label.e-label-top.e-float-text,.e-float-input:not(.e-error) textarea[readonly]~label.e-label-top.e-float-text,.e-float-input:not(.e-error) textarea[disabled]~label.e-label-top.e-float-text,.e-float-input:not(.e-error) textarea label.e-float-text.e-label-top,.e-float-input.e-small:not(.e-error) textarea:focus~label.e-float-text,.e-float-input.e-small:not(.e-error) textarea:valid~label.e-float-text,.e-float-input.e-small:not(.e-error) textarea~label.e-label-top.e-float-text,.e-float-input.e-small:not(.e-error) textarea[readonly]~label.e-float-text,.e-float-input.e-small:not(.e-error) textarea[disabled]~label.e-float-text,.e-small .e-float-input:not(.e-error) textarea:focus~label.e-float-text,.e-small .e-float-input:not(.e-error) textarea:valid~label.e-float-text,.e-small .e-float-input:not(.e-error) textarea~label.e-label-top.e-float-text,.e-small .e-float-input:not(.e-error) textarea[readonly]~label.e-float-text.e-label-top,.e-small .e-float-input:not(.e-error) textarea[disabled]~label.e-float-text.e-label-top,.e-float-input:not(.e-error):not(.e-input-focus) input:not(:focus):-webkit-autofill~label.e-float-text,.e-small .e-float-input:not(.e-error):not(.e-input-focus) input:not(:focus):-webkit-autofill~label.e-float-text,.e-small.e-float-input:not(.e-error):not(.e-input-focus) input:not(:focus):-webkit-autofill~label.e-float-text,.e-float-input.e-control-wrapper.e-autofill:not(.e-error):not(.e-input-focus) input:not(:focus):-webkit-autofill~label.e-float-text,.e-small .e-float-input.e-control-wrapper.e-autofill:not(.e-error):not(.e-input-focus) input:not(:focus):-webkit-autofill~label.e-float-text,.e-small.e-float-input.e-control-wrapper.e-autofill:not(.e-error):not(.e-input-focus) input:not(:focus):-webkit-autofill~label.e-float-text,.e-float-input:not(.e-error) textarea:not(:focus):-webkit-autofill~label.e-float-text,.e-small .e-float-input:not(.e-error) textarea:not(:focus):-webkit-autofill~label.e-float-text,.e-small.e-float-input:not(.e-error) textarea:not(:focus):-webkit-autofill~label.e-float-text,.e-float-input.e-control-wrapper.e-autofill:not(.e-error) textarea:not(:focus):-webkit-autofill~label.e-float-text,.e-small .e-float-input.e-control-wrapper.e-autofill:not(.e-error) textarea:not(:focus):-webkit-autofill~label.e-float-text,.e-small.e-float-input.e-control-wrapper.e-autofill:not(.e-error) textarea:not(:focus):-webkit-autofill~label.e-float-text{color:#0000008a}.e-float-input.e-control-wrapper:not(.e-error) input:focus~label.e-float-text,.e-float-input.e-control-wrapper:not(.e-error) input:valid~label.e-float-text,.e-float-input.e-control-wrapper:not(.e-error) input~label.e-label-top.e-float-text,.e-float-input.e-control-wrapper:not(.e-error) input[readonly]~label.e-label-top.e-float-text,.e-float-input.e-control-wrapper:not(.e-error) input[disabled]~label.e-label-top.e-float-text,.e-float-input .e-control-wrapper:not(.e-error) input label.e-float-text.e-label-top,.e-float-input.e-control-wrapper:not(.e-error).e-input-focus input~label.e-float-text,.e-float-input.e-control-wrapper:not(.e-error) textarea:focus~label.e-float-text,.e-float-input.e-control-wrapper:not(.e-error) textarea:valid~label.e-float-text,.e-float-input.e-control-wrapper:not(.e-error) textarea~label.e-label-top.e-float-text,.e-float-input.e-control-wrapper:not(.e-error) textarea[readonly]~label.e-label-top.e-float-text,.e-float-input.e-control-wrapper:not(.e-error) textarea[disabled]~label.e-label-top.e-float-text,.e-float-input.e-control-wrapper:not(.e-error) textarea label.e-float-text.e-label-top{color:#0000008a}.e-float-input:not(.e-error) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-float-input.e-control-wrapper:not(.e-error) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-float-input.e-small:not(.e-error) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-float-input.e-control-wrapper.e-small:not(.e-error) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small .e-float-input:not(.e-error) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small .e-float-input.e-control-wrapper:not(.e-error) textarea:not(:focus):valid~label.e-float-text.e-label-bottom{color:#0000006b}.e-float-input.e-control-wrapper.e-small:not(.e-error) textarea:focus~label.e-float-text,.e-float-input.e-control-wrapper.e-small:not(.e-error) textarea:valid~label.e-float-text,.e-float-input.e-control-wrapper.e-small:not(.e-error) textarea~label.e-label-top.e-float-text,.e-float-input.e-control-wrapper.e-small:not(.e-error) textarea[readonly]~label.e-float-text,.e-float-input.e-control-wrapper.e-small:not(.e-error) textarea[disabled]~label.e-float-text,.e-small .e-float-input.e-control-wrapper:not(.e-error) textarea:focus~label.e-float-text,.e-small .e-float-input.e-control-wrapper:not(.e-error) textarea:valid~label.e-float-text,.e-small .e-float-input.e-control-wrapper:not(.e-error) textarea~label.e-label-top.e-float-text,.e-small .e-float-input.e-control-wrapper:not(.e-error) textarea[readonly]~label.e-float-text.e-label-top,.e-small .e-float-input.e-control-wrapper:not(.e-error) textarea[disabled]~label.e-float-text.e-label-top{color:#0000008a}.e-float-input.e-input-group.e-disabled .e-float-text,.e-float-input.e-input-group.e-disabled .e-float-text.e-label-top,.e-float-input input[disabled]~label.e-float-text,.e-float-input input[disabled]~label.e-label-top.e-float-text,.e-float-input.e-disabled label.e-float-text,.e-float-input.e-disabled label.e-float-text.e-label-top,.e-float-input:not(.e-error) input[disabled]~label.e-float-text,.e-float-input:not(.e-error) input[disabled]~label.e-label-top.e-float-text,.e-float-input.e-small:not(.e-error) input[disabled]~label.e-float-text,.e-float-input.e-small:not(.e-error) input[disabled]~label.e-float-text.e-label-top,.e-float-input textarea[disabled]~label.e-float-text,.e-float-input textarea[disabled]~label.e-label-top.e-float-text,.e-float-input:not(.e-error) textarea[disabled]~label.e-float-text,.e-float-input:not(.e-error) textarea[disabled]~label.e-label-top.e-float-text,.e-float-input.e-small:not(.e-error) textarea[disabled]~label.e-float-text,.e-float-input.e-small:not(.e-error) textarea[disabled]~label.e-float-text.e-label-top,.e-float-input.e-control-wrapper.e-input-group.e-disabled .e-float-text,.e-float-input.e-control-wrapper.e-input-group.e-disabled .e-float-text.e-label-top,.e-float-input.e-control-wrapper.e-disabled input[disabled]~label.e-float-text,.e-float-input.e-control-wrapper.e-disabled input[disabled]~label.e-label-top.e-float-text,.e-float-input.e-control-wrapper input[disabled]~label.e-float-text,.e-float-input.e-control-wrapper input[disabled]~label.e-label-top.e-float-text,.e-float-input.e-control-wrapper.e-disabled label.e-float-text,.e-float-input.e-control-wrapper.e-disabled label.e-float-text.e-label-top,.e-float-input.e-control-wrapper:not(.e-error) input[disabled]~label.e-float-text,.e-float-input.e-control-wrapper:not(.e-error) input[disabled]~label.e-label-top.e-float-text,.e-float-input.e-control-wrapper.e-small:not(.e-error) input[disabled]~label.e-float-text,.e-float-input.e-control-wrapper.e-small:not(.e-error) input[disabled]~label.e-float-text.e-label-top,.e-float-input.e-control-wrapper.e-disabled:not(.e-error) input[disabled]~label.e-float-text,.e-float-input.e-control-wrapper.e-disabled:not(.e-error) input[disabled]~label.e-label-top.e-float-text,.e-float-input.e-control-wrapper.e-disabled.e-small:not(.e-error) input[disabled]~label.e-float-text,.e-float-input.e-control-wrapper.e-disabled.e-small:not(.e-error) input[disabled]~label.e-float-text.e-label-top,.e-float-input.e-control-wrapper.e-disabled textarea[disabled]~label.e-float-text,.e-float-input.e-control-wrapper.e-disabled textarea[disabled]~label.e-label-top.e-float-text,.e-float-input.e-control-wrapper textarea[disabled]~label.e-float-text,.e-float-input.e-control-wrapper textarea[disabled]~label.e-label-top.e-float-text,.e-float-input.e-control-wrapper:not(.e-error) textarea[disabled]~label.e-float-text,.e-float-input.e-control-wrapper:not(.e-error) textarea[disabled]~label.e-label-top.e-float-text,.e-float-input.e-control-wrapper.e-small:not(.e-error) textarea[disabled]~label.e-float-text,.e-float-input.e-control-wrapper.e-small:not(.e-error) textarea[disabled]~label.e-float-text.e-label-top,.e-float-input.e-control-wrapper.e-disabled:not(.e-error) textarea[disabled]~label.e-float-text,.e-float-input.e-control-wrapper.e-disabled:not(.e-error) textarea[disabled]~label.e-label-top.e-float-text,.e-float-input.e-control-wrapper.e-disabled.e-small:not(.e-error) textarea[disabled]~label.e-float-text,.e-float-input.e-control-wrapper.e-disabled.e-small:not(.e-error) textarea[disabled]~label.e-float-text.e-label-top{color:#0000006b}.e-float-input:not(.e-error) input:focus~label.e-float-text,.e-float-input.e-small:not(.e-error) input:focus~label.e-float-text,.e-small .e-float-input:not(.e-error) input:focus~label.e-float-text,.e-float-input:not(.e-error) input[readonly]:focus~label.e-label-top.e-float-text,.e-float-input.e-control-wrapper:not(.e-error) input[readonly]:focus~label.e-label-top.e-float-text,.e-float-input.e-small:not(.e-error) input[readonly]:focus~label.e-float-text,.e-small .e-float-input:not(.e-error) input[readonly]:focus~label.e-float-text.e-label-top,.e-float-input.e-control-wrapper.e-small:not(.e-error) input[readonly]:focus~label.e-float-text,.e-small .e-float-input.e-control-wrapper:not(.e-error) input[readonly]:focus~label.e-float-text.e-label-top,.e-float-input:not(.e-error).e-input-focus input[readonly]~label.e-label-top.e-float-text,.e-float-input.e-control-wrapper:not(.e-error).e-input-focus input[readonly]~label.e-label-top.e-float-text,.e-float-input.e-small:not(.e-error).e-input-focus input[readonly]~label.e-float-text,.e-small .e-float-input:not(.e-error).e-input-focus input[readonly]~label.e-float-text.e-label-top,.e-float-input.e-control-wrapper.e-small:not(.e-error).e-input-focus input[readonly]~label.e-float-text,.e-small .e-float-input.e-control-wrapper:not(.e-error).e-input-focus input[readonly]~label.e-float-text.e-label-top,.e-float-input:not(.e-error) textarea[readonly]:focus~label.e-label-top.e-float-text,.e-float-input.e-control-wrapper:not(.e-error) textarea[readonly]:focus~label.e-label-top.e-float-text,.e-float-input.e-small:not(.e-error) textarea[readonly]:focus~label.e-float-text,.e-small .e-float-input:not(.e-error) textarea[readonly]:focus~label.e-float-text.e-label-top,.e-small .e-float-input.e-control-wrapper:not(.e-error) textarea[readonly]:focus~label.e-float-text.e-label-top,.e-float-input:not(.e-error).e-input-focus textarea[readonly]~label.e-label-top.e-float-text,.e-float-input.e-control-wrapper:not(.e-error).e-input-focus textarea[readonly]~label.e-label-top.e-float-text,.e-float-input.e-small:not(.e-error).e-input-focus textarea[readonly]~label.e-float-text,.e-small .e-float-input:not(.e-error).e-input-focus textarea[readonly]~label.e-float-text.e-label-top,.e-small .e-float-input.e-control-wrapper:not(.e-error).e-input-focus textarea[readonly]~label.e-float-text.e-label-top,.e-float-input:not(.e-error) textarea:focus~label.e-float-text,.e-float-input.e-small:not(.e-error) textarea:focus~label.e-float-text,.e-small .e-float-input:not(.e-error) textarea:focus~label.e-float-text,.e-float-input.e-control-wrapper:not(.e-error) input:focus~label.e-float-text,.e-float-input.e-control-wrapper.e-small:not(.e-error) input:focus~label.e-float-text,.e-small .e-float-input.e-control-wrapper:not(.e-error) input:focus~label.e-float-text,.e-float-input.e-control-wrapper:not(.e-error) textarea:focus~label.e-float-text,.e-float-input.e-control-wrapper.e-small:not(.e-error) textarea:focus~label.e-float-text,.e-small .e-float-input.e-control-wrapper:not(.e-error) textarea:focus~label.e-float-text,.e-float-input:not(.e-error).e-input-focus input~label.e-float-text,.e-float-input.e-small:not(.e-error).e-input-focus input~label.e-float-text,.e-small .e-float-input:not(.e-error).e-input-focus input~label.e-float-text,.e-float-input.e-control-wrapper:not(.e-error).e-input-focus input~label.e-float-text,.e-float-input.e-control-wrapper.e-small:not(.e-error).e-input-focus input~label.e-float-text,.e-small .e-float-input.e-control-wrapper:not(.e-error).e-input-focus input~label.e-float-text{color:#e3165b}.e-input-group:hover:not(.e-success):not(.e-warning):not(.e-error):not(.e-disabled):not(.e-float-icon-left),.e-input-group.e-control-wrapper:hover:not(.e-success):not(.e-warning):not(.e-error):not(.e-disabled):not(.e-float-icon-left),.e-float-input.e-control-wrapper:hover:not(.e-success):not(.e-warning):not(.e-error):not(.e-disabled):not(.e-float-icon-left),.e-float-input:hover:not(.e-success):not(.e-warning):not(.e-error):not(.e-disabled):not(.e-float-icon-left),.e-input-group.e-float-icon-left:not(.e-success):not(.e-warning):not(.e-error):not(.e-disabled) .e-input-in-wrap:hover,.e-input-group.e-control-wrapper.e-float-icon-left:not(.e-success):not(.e-warning):not(.e-error):not(.e-disabled) .e-input-in-wrap:hover,.e-float-input.e-float-icon-left:not(.e-success):not(.e-warning):not(.e-error):not(.e-disabled) .e-input-in-wrap:hover,.e-float-input.e-control-wrapper.e-float-icon-left:not(.e-success):not(.e-warning):not(.e-error):not(.e-disabled) .e-input-in-wrap:hover,.e-float-input:hover:not(.e-input-group):not(.e-success):not(.e-warning):not(.e-error):not(.e-disabled) input:not([disabled]),.e-float-input:hover:not(.e-input-group):not(.e-success):not(.e-warning):not(.e-error):not(.e-disabled) textarea:not([disabled]),.e-float-input.e-control-wrapper:hover:not(.e-input-group):not(.e-success):not(.e-warning):not(.e-error):not(.e-disabled) input:not([disabled]),.e-float-input.e-control-wrapper:hover:not(.e-input-group):not(.e-success):not(.e-warning):not(.e-error):not(.e-disabled) textarea:not([disabled]){border-color:#0000006b}.e-input-group.e-input-focus:not(.e-float-icon-left):not(.e-success):not(.e-warning):not(.e-error),.e-input-group.e-control-wrapper.e-input-focus:not(.e-float-icon-left):not(.e-success):not(.e-warning):not(.e-error),.e-float-input.e-input-focus:not(.e-float-icon-left):not(.e-success):not(.e-warning):not(.e-error),.e-float-input.e-control-wrapper.e-input-focus:not(.e-float-icon-left):not(.e-success):not(.e-warning):not(.e-error),.e-input-group.e-float-icon-left.e-input-focus:not(.e-success):not(.e-warning):not(.e-error) .e-input-in-wrap,.e-input-group.e-control-wrapper.e-float-icon-left.e-input-focus:not(.e-success):not(.e-warning):not(.e-error) .e-input-in-wrap,.e-input-group.e-input-focus:hover:not(.e-success):not(.e-warning):not(.e-error):not(.e-disabled):not(.e-float-icon-left),.e-input-group.e-control-wrapper.e-input-focus:hover:not(.e-success):not(.e-warning):not(.e-error):not(.e-disabled):not(.e-float-icon-left),.e-float-input.e-input-focus:hover:not(.e-success):not(.e-warning):not(.e-error):not(.e-disabled):not(.e-float-icon-left),.e-float-input.e-control-wrapper.e-input-focus:hover:not(.e-success):not(.e-warning):not(.e-error):not(.e-disabled):not(.e-float-icon-left),.e-input-group.e-input-focus.e-float-icon-left:not(.e-success):not(.e-warning):not(.e-error):not(.e-disabled) .e-input-in-wrap:hover,.e-input-group.e-control-wrapper.e-input-focus.e-float-icon-left:not(.e-success):not(.e-warning):not(.e-error):not(.e-disabled) .e-input-in-wrap:hover,.e-float-input.e-input-focus.e-float-icon-left:not(.e-success):not(.e-warning):not(.e-error):not(.e-disabled) .e-input-in-wrap:hover,.e-float-input.e-input-focus:hover:not(.e-input-group):not(.e-success):not(.e-warning):not(.e-error):not(.e-disabled) input:not([disabled]),.e-float-input.e-input-focus:hover:not(.e-input-group):not(.e-success):not(.e-warning):not(.e-error):not(.e-disabled) textarea:not([disabled]),.e-float-input.e-control-wrapper.e-input-focus.e-float-icon-left:not(.e-success):not(.e-warning):not(.e-error):not(.e-disabled) .e-input-in-wrap:hover,.e-float-input.e-control-wrapper.e-input-focus:hover:not(.e-input-group):not(.e-success):not(.e-warning):not(.e-error):not(.e-disabled) input:not([disabled]),.e-float-input.e-control-wrapper.e-input-focus:hover:not(.e-input-group):not(.e-success):not(.e-warning):not(.e-error):not(.e-disabled) textarea:not([disabled]){border-color:#0000006b}.e-outline.e-input-group,.e-outline.e-input-group.e-control-wrapper,.e-outline.e-float-input,.e-outline.e-float-input.e-input-group,.e-outline.e-float-input.e-control-wrapper,.e-outline.e-float-input.e-input-group.e-control-wrapper{color:#000000de}.e-outline.e-input-group.e-disabled,.e-outline.e-input-group.e-control-wrapper.e-disabled,.e-outline.e-float-input.e-disabled,.e-outline.e-float-input.e-input-group.e-disabled,.e-outline.e-float-input.e-control-wrapper.e-disabled,.e-outline.e-float-input.e-input-group.e-control-wrapper.e-disabled{color:#00000061}.e-outline.e-input-group:hover:not(.e-input-focus):not(.e-success):not(.e-warning):not(.e-error):not(.e-disabled),.e-outline.e-input-group.e-control-wrapper:hover:not(.e-input-focus):not(.e-success):not(.e-warning):not(.e-error):not(.e-disabled),.e-outline.e-float-input.e-control-wrapper:hover:not(.e-input-focus):not(.e-success):not(.e-warning):not(.e-error):not(.e-disabled),.e-outline.e-input-group.e-float-icon-left:hover:not(.e-input-focus):not(.e-success):not(.e-warning):not(.e-error):not(.e-disabled),.e-outline.e-input-group.e-control-wrapper.e-float-icon-left:hover:not(.e-input-focus):not(.e-success):not(.e-warning):not(.e-error):not(.e-disabled),.e-outline.e-float-input.e-float-icon-left:hover:not(.e-input-focus):not(.e-success):not(.e-warning):not(.e-error):not(.e-disabled),.e-outline.e-float-input.e-control-wrapper.e-float-icon-left:not(.e-input-focus):hover:not(.e-success):not(.e-warning):not(.e-error):not(.e-disabled),.e-outline.e-float-input:hover:not(.e-input-focus):not(.e-input-group):not(.e-success):not(.e-warning):not(.e-error):not(.e-disabled){border-color:#000000de;color:#000000de}.e-outline.e-input-group.e-valid-input:hover:not(.e-input-focus):not(.e-success):not(.e-warning):not(.e-error):not(.e-disabled) label.e-float-text:before,.e-outline.e-input-group.e-valid-input:hover:not(.e-input-focus):not(.e-success):not(.e-warning):not(.e-error):not(.e-disabled) label.e-float-text:after,.e-outline.e-input-group.e-control-wrapper.e-valid-input:hover:not(.e-input-focus):not(.e-success):not(.e-warning):not(.e-error):not(.e-disabled) label.e-float-text:before,.e-outline.e-input-group.e-control-wrapper.e-valid-input:hover:not(.e-input-focus):not(.e-success):not(.e-warning):not(.e-error):not(.e-disabled) label.e-float-text:after,.e-outline.e-float-input.e-control-wrapper.e-valid-input:hover:not(.e-input-focus):not(.e-success):not(.e-warning):not(.e-error):not(.e-disabled) label.e-float-text:before,.e-outline.e-float-input.e-control-wrapper.e-valid-input:hover:not(.e-input-focus):not(.e-success):not(.e-warning):not(.e-error):not(.e-disabled) label.e-float-text:after,.e-outline.e-input-group.e-float-icon-left.e-valid-input:hover:not(.e-input-focus):not(.e-success):not(.e-warning):not(.e-error):not(.e-disabled) label.e-float-text:before,.e-outline.e-input-group.e-float-icon-left.e-valid-input:hover:not(.e-input-focus):not(.e-success):not(.e-warning):not(.e-error):not(.e-disabled) label.e-float-text:after,.e-outline.e-input-group.e-control-wrapper.e-float-icon-left.e-valid-input:hover:not(.e-input-focus):not(.e-success):not(.e-warning):not(.e-error):not(.e-disabled) label.e-float-text:before,.e-outline.e-input-group.e-control-wrapper.e-float-icon-left.e-valid-input:hover:not(.e-input-focus):not(.e-success):not(.e-warning):not(.e-error):not(.e-disabled) label.e-float-text:after,.e-outline.e-float-input.e-float-icon-left:hover.e-valid-input:not(.e-input-focus):not(.e-success):not(.e-warning):not(.e-error):not(.e-disabled) label.e-float-text:before,.e-outline.e-float-input.e-float-icon-left:hover.e-valid-input:not(.e-input-focus):not(.e-success):not(.e-warning):not(.e-error):not(.e-disabled) label.e-float-text:after,.e-outline.e-float-input.e-control-wrapper.e-float-icon-left.e-valid-input:not(.e-input-focus):hover:not(.e-success):not(.e-warning):not(.e-error):not(.e-disabled) label.e-float-text:before,.e-outline.e-float-input.e-control-wrapper.e-float-icon-left.e-valid-input:not(.e-input-focus):hover:not(.e-success):not(.e-warning):not(.e-error):not(.e-disabled) label.e-float-text:after,.e-outline.e-float-input:hover.e-valid-input:not(.e-input-focus):not(.e-input-group):not(.e-success):not(.e-warning):not(.e-error):not(.e-disabled) label.e-float-text:before,.e-outline.e-float-input:hover.e-valid-input:not(.e-input-focus):not(.e-input-group):not(.e-success):not(.e-warning):not(.e-error):not(.e-disabled) label.e-float-text:after{border-color:#000000de}.e-outline.e-input-group.e-input-focus:not(.e-success):not(.e-warning):not(.e-error),.e-outline.e-input-group.e-control-wrapper.e-input-focus:not(.e-success):not(.e-warning):not(.e-error){border-color:#e3165b;box-shadow:inset 1px 1px #e3165b,inset -1px 0 #e3165b,inset 0 -1px #e3165b}.e-outline.e-input-group:not(.e-input-focus),.e-outline.e-input-group:not(.e-success):not(.e-warning):not(.e-error):not(.e-float-icon-left):not(.e-input-focus),.e-outline.e-input-group.e-control-wrapper:not(.e-success):not(.e-warning):not(.e-error):not(.e-float-icon-left):not(.e-input-focus),.e-outline.e-input-group.e-float-icon-left:not(.e-input-focus),.e-outline.e-input-group.e-control-wrapper.e-float-icon-left:not(.e-input-focus){border-color:#0000003d}.e-outline.e-input-group.e-error,.e-outline.e-input-group.e-control-wrapper.e-error,.e-outline.e-input-group.e-error:not(.e-float-icon-left),.e-outline.e-input-group.e-control-wrapper.e-error:not(.e-float-icon-left),.e-outline.e-float-input.e-error,.e-outline.e-float-input.e-input-group.e-error,.e-outline.e-float-input.e-control-wrapper.e-error,.e-outline.e-float-input.e-input-group.e-control-wrapper.e-error{border-color:#f44336}.e-outline.e-float-input.e-success.e-input-focus,.e-outline.e-float-input.e-control-wrapper.e-success.e-input-focus,.e-outline.e-float-input.e-input-group.e-success.e-input-focus,.e-outline.e-float-input.e-input-group.e-control-wrapper.e-success.e-input-focus,.e-outline.e-float-input.e-input-group.e-success.e-input-focus:not(.e-float-icon-left),.e-outline.e-float-input.e-input-group.e-control-wrapper.e-success.e-input-focus:not(.e-float-icon-left),.e-outline.e-float-input.e-warning.e-input-focus,.e-outline.e-float-input.e-control-wrapper.e-warning.e-input-focus,.e-outline.e-float-input.e-input-group.e-warning.e-input-focus,.e-outline.e-float-input.e-input-group.e-control-wrapper.e-warning.e-input-focus,.e-outline.e-float-input.e-input-group.e-warning.e-input-focus:not(.e-float-icon-left),.e-outline.e-float-input.e-input-group.e-control-wrapper.e-warning.e-input-focus:not(.e-float-icon-left),.e-outline.e-float-input.e-error.e-input-focus,.e-outline.e-float-input.e-control-wrapper.e-error.e-input-focus,.e-outline.e-float-input.e-input-group.e-error.e-input-focus,.e-outline.e-float-input.e-input-group.e-control-wrapper.e-error.e-input-focus,.e-outline.e-float-input.e-input-group.e-error.e-input-focus:not(.e-float-icon-left),.e-outline.e-float-input.e-input-group.e-control-wrapper.e-error.e-input-focus:not(.e-float-icon-left),.e-outline.e-float-input.e-input-group.e-disabled.e-valid-input:not(.e-input-focus),.e-outline.e-float-input.e-input-group.e-disabled.e-valid-input:not(.e-success):not(.e-warning):not(.e-error):not(.e-float-icon-left):not(.e-input-focus),.e-outline.e-float-input.e-input-group.e-control-wrapper.e-disabled.e-valid-input:not(.e-success):not(.e-warning):not(.e-error):not(.e-float-icon-left):not(.e-input-focus){border-top-color:transparent}.e-outline.e-input-group.e-success,.e-outline.e-input-group.e-control-wrapper.e-success,.e-outline.e-input-group.e-success:not(.e-float-icon-left),.e-outline.e-input-group.e-control-wrapper.e-success:not(.e-float-icon-left),.e-outline.e-float-input.e-success,.e-outline.e-float-input.e-input-group.e-success,.e-outline.e-float-input.e-control-wrapper.e-success,.e-outline.e-float-input.e-input-group.e-control-wrapper.e-success{border-color:#22b24b}.e-outline.e-input-group.e-warning,.e-outline.e-input-group.e-control-wrapper.e-warning,.e-outline.e-input-group.e-warning:not(.e-float-icon-left),.e-outline.e-input-group.e-control-wrapper.e-warning:not(.e-float-icon-left),.e-outline.e-float-input.e-warning,.e-outline.e-float-input.e-input-group.e-warning,.e-outline.e-float-input.e-control-wrapper.e-warning,.e-outline.e-float-input.e-input-group.e-control-wrapper.e-warning{border-color:#ffca1c}.e-outline.e-input-group.e-input-focus.e-error:not(.e-success):not(.e-warning),.e-outline.e-input-group.e-control-wrapper.e-input-focus.e-error:not(.e-success):not(.e-warning){box-shadow:inset 1px 1px #f44336,inset -1px 0 #f44336,inset 0 -1px #f44336}.e-outline.e-input-group.e-input-focus.e-success:not(.e-error):not(.e-warning),.e-outline.e-input-group.e-control-wrapper.e-input-focus.e-success:not(.e-error):not(.e-warning){box-shadow:inset 1px 1px #22b24b,inset -1px 0 #22b24b,inset 0 -1px #22b24b}.e-outline.e-input-group.e-input-focus.e-warning:not(.e-error):not(.e-success),.e-outline.e-input-group.e-control-wrapper.e-input-focus.e-warning:not(.e-error):not(.e-success){box-shadow:inset 1px 1px #ffca1c,inset -1px 0 #ffca1c,inset 0 -1px #ffca1c}.e-outline.e-float-input.e-input-focus.e-error:not(.e-success):not(.e-warning),.e-outline.e-float-input.e-control-wrapper.e-input-focus.e-error:not(.e-success):not(.e-warning),.e-outline.e-float-input.e-input-group.e-input-focus.e-error:not(.e-success):not(.e-warning),.e-outline.e-float-input.e-input-group.e-control-wrapper.e-input-focus.e-error:not(.e-success):not(.e-warning){box-shadow:inset 1px 0 #f44336,inset -1px 0 #f44336,inset 0 -1px #f44336}.e-outline.e-float-input.e-input-focus.e-success:not(.e-error):not(.e-warning),.e-outline.e-float-input.e-control-wrapper.e-input-focus.e-success:not(.e-error):not(.e-warning),.e-outline.e-float-input.e-input-group.e-input-focus.e-success:not(.e-error):not(.e-warning),.e-outline.e-float-input.e-input-group.e-control-wrapper.e-input-focus.e-success:not(.e-error):not(.e-warning){box-shadow:inset 1px 0 #22b24b,inset -1px 0 #22b24b,inset 0 -1px #22b24b}.e-outline.e-float-input.e-input-focus.e-warning:not(.e-error):not(.e-success),.e-outline.e-float-input.e-control-wrapper.e-input-focus.e-warning:not(.e-error):not(.e-success),.e-outline.e-float-input.e-input-group.e-input-focus.e-warning:not(.e-error):not(.e-success),.e-outline.e-float-input.e-input-group.e-control-wrapper.e-input-focus.e-warning:not(.e-error):not(.e-success){box-shadow:inset 1px 0 #ffca1c,inset -1px 0 #ffca1c,inset 0 -1px #ffca1c}.e-outline.e-input-group.e-disabled:not(.e-input-focus),.e-outline.e-input-group.e-disabled:not(.e-success):not(.e-warning):not(.e-error):not(.e-float-icon-left):not(.e-input-focus),.e-outline.e-input-group.e-control-wrapper.e-disabled:not(.e-success):not(.e-warning):not(.e-error):not(.e-float-icon-left):not(.e-input-focus),.e-outline.e-input-group.e-disabled.e-float-icon-left:not(.e-input-focus),.e-outline.e-input-group.e-disabled.e-control-wrapper.e-float-icon-left:not(.e-input-focus),.e-outline.e-float-input.e-input-group.e-disabled.e-valid-input:not(.e-input-focus) label.e-float-text:before,.e-outline.e-float-input.e-input-group.e-disabled.e-valid-input:not(.e-input-focus) label.e-float-text:after,.e-outline.e-float-input.e-input-group.e-disabled.e-valid-input:not(.e-success):not(.e-warning):not(.e-error):not(.e-float-icon-left):not(.e-input-focus) label.e-float-text:before,.e-outline.e-float-input.e-input-group.e-disabled.e-valid-input:not(.e-success):not(.e-warning):not(.e-error):not(.e-float-icon-left):not(.e-input-focus) label.e-float-text:after,.e-outline.e-float-input.e-input-group.e-control-wrapper.e-disabled.e-valid-input:not(.e-success):not(.e-warning):not(.e-error):not(.e-float-icon-left):not(.e-input-focus) label.e-float-text:before,.e-outline.e-float-input.e-input-group.e-control-wrapper.e-disabled.e-valid-input:not(.e-success):not(.e-warning):not(.e-error):not(.e-float-icon-left):not(.e-input-focus) label.e-float-text:after,.e-outline.e-disabled.e-valid-input:not(.e-input-focus) label.e-float-text:before,.e-outline.e-disabled.e-valid-input:not(.e-input-focus) label.e-float-text:after,.e-outline.e-disabled.e-float-input.e-valid-input:not(.e-input-focus) label.e-float-text:before,.e-outline.e-disabled.e-float-input.e-valid-input:not(.e-input-focus) label.e-float-text:after,.e-outline.e-disabled.e-float-input.e-control-wrapper.e-valid-input:not(.e-input-focus) label.e-float-text:before,.e-outline.e-disabled.e-float-input.e-control-wrapper.e-valid-input:not(.e-input-focus) label.e-float-text:after{border-color:#0000000f}.e-outline.e-float-input.e-success.e-input-focus input:focus~label.e-float-text,.e-outline.e-float-input.e-input-group.e-success.e-valid-input label.e-float-text.e-label-top,.e-outline.e-float-input.e-small.e-success.e-input-focus input:focus~label.e-float-text,.e-small .e-outline.e-float-input.e-success input:focus~label.e-float-text,.e-outline.e-float-input.e-success textarea:focus~label.e-float-text,.e-outline.e-float-input.e-small.e-success textarea:focus~label.e-float-text,.e-small .e-outline.e-float-input.e-success textarea:focus~label.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-success input:focus~label.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-small.e-success input:focus~label.e-float-text,.e-small .e-outline.e-float-input.e-control-wrapper.e-success input:focus~label.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-success textarea:focus~label.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-small.e-success textarea:focus~label.e-float-text,.e-small .e-outline.e-float-input.e-control-wrapper.e-success textarea:focus~label.e-float-text,.e-outline.e-float-input.e-success label.e-float-text.e-label-top,.e-outline.e-float-input.e-input-group.e-success label.e-float-text.e-label-top,.e-outline.e-float-input.e-control-wrapper.e-success label.e-float-text.e-label-top,.e-outline.e-float-input.e-valid-input.e-success:not(.e-input-focus) input:valid~label.e-float-text.e-label-top,.e-outline.e-float-input.e-control-wrapper.e-valid-input.e-success:not(.e-input-focus) input:focus~label.e-float-text.e-label-top,.e-outline.e-float-input.e-valid-input.e-success:not(.e-input-focus) textarea:valid~label.e-float-text.e-label-top,.e-outline.e-float-input.e-control-wrapper.e-valid-input.e-success:not(.e-input-focus) textarea:focus~label.e-float-text.e-label-top,.e-outline.e-float-input.e-success.e-input-focus input~label.e-float-text,.e-outline.e-float-input.e-small.e-success.e-input-focus input~label.e-float-text,.e-small .e-outline.e-float-input.e-success.e-input-focus input~label.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-success.e-input-focus input~label.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-small.e-success.e-input-focus input~label.e-float-text,.e-small .e-outline.e-float-input.e-control-wrapper.e-success.e-input-focus input~label.e-float-text{color:#22b24b}.e-outline.e-float-input.e-error.e-input-focus input:focus~label.e-float-text,.e-outline.e-float-input.e-input-group.e-error.e-valid-input label.e-label-top.e-float-text,.e-outline.e-float-input.e-small.e-error.e-input-focus input:focus~label.e-float-text,.e-small .e-outline.e-float-input.e-error input:focus~label.e-float-text,.e-outline.e-float-input.e-error textarea:focus~label.e-float-text,.e-outline.e-float-input.e-small.e-error textarea:focus~label.e-float-text,.e-small .e-outline.e-float-input.e-error textarea:focus~label.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-error input:focus~label.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-small.e-error input:focus~label.e-float-text,.e-small .e-outline.e-float-input.e-control-wrapper.e-error input:focus~label.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-error textarea:focus~label.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-small.e-error textarea:focus~label.e-float-text,.e-small .e-outline.e-float-input.e-control-wrapper.e-error textarea:focus~label.e-float-text,.e-outline.e-float-input.e-error label.e-float-text.e-label-top,.e-outline.e-float-input.e-input-group.e-error label.e-float-text.e-label-top,.e-outline.e-float-input.e-control-wrapper.e-error label.e-float-text.e-label-top,.e-outline.e-float-input.e-valid-input.e-error:not(.e-input-focus) input:valid~label.e-float-text.e-label-top,.e-outline.e-float-input.e-control-wrapper.e-valid-input.e-error:not(.e-input-focus) input:focus~label.e-float-text.e-label-top,.e-outline.e-float-input.e-valid-input.e-error:not(.e-input-focus) textarea:valid~label.e-float-text.e-label-top,.e-outline.e-float-input.e-control-wrapper.e-valid-input.e-error:not(.e-input-focus) textarea:focus~label.e-float-text.e-label-top,.e-outline.e-float-input.e-error.e-input-focus input~label.e-float-text,.e-outline.e-float-input.e-small.e-error.e-input-focus input~label.e-float-text,.e-small .e-outline.e-float-input.e-error.e-input-focus input~label.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-error.e-input-focus input~label.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-small.e-error.e-input-focus input~label.e-float-text,.e-small .e-outline.e-float-input.e-control-wrapper.e-error.e-input-focus input~label.e-float-text{color:#f44336}.e-outline.e-float-input.e-warning.e-input-focus input:focus~label.e-float-text,.e-outline.e-float-input.e-input-group.e-warning.e-valid-input label.e-label-top.e-float-text,.e-outline.e-float-input.e-small.e-warning.e-input-focus input:focus~label.e-float-text,.e-small .e-outline.e-float-input.e-warning input:focus~label.e-float-text,.e-outline.e-float-input.e-warning textarea:focus~label.e-float-text,.e-outline.e-float-input.e-small.e-warning textarea:focus~label.e-float-text,.e-small .e-outline.e-float-input.e-warning textarea:focus~label.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-warning input:focus~label.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-small.e-warning input:focus~label.e-float-text,.e-small .e-outline.e-float-input.e-control-wrapper.e-warning input:focus~label.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-warning textarea:focus~label.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-small.e-warning textarea:focus~label.e-float-text,.e-small .e-outline.e-float-input.e-control-wrapper.e-warning textarea:focus~label.e-float-text,.e-outline.e-float-input.e-warning label.e-float-text.e-label-top,.e-outline.e-float-input.e-input-group.e-warning label.e-float-text.e-label-top,.e-outline.e-float-input.e-control-wrapper.e-warning label.e-float-text.e-label-top,.e-outline.e-float-input.e-valid-input.e-warning:not(.e-input-focus) input:valid~label.e-float-text.e-label-top,.e-outline.e-float-input.e-control-wrapper.e-valid-input.e-warning:not(.e-input-focus) input:focus~label.e-float-text.e-label-top,.e-outline.e-float-input.e-valid-input.e-warning:not(.e-input-focus) textarea:valid~label.e-float-text.e-label-top,.e-outline.e-float-input.e-control-wrapper.e-valid-input.e-warning:not(.e-input-focus) textarea:focus~label.e-float-text.e-label-top,.e-outline.e-float-input.e-warning.e-input-focus input~label.e-float-text,.e-outline.e-float-input.e-small.e-warning.e-input-focus input~label.e-float-text,.e-small .e-outline.e-float-input.e-warning.e-input-focus input~label.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-warning.e-input-focus input~label.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-small.e-warning.e-input-focus input~label.e-float-text,.e-small .e-outline.e-float-input.e-control-wrapper.e-warning.e-input-focus input~label.e-float-text{color:#ffca1c}.e-outline.e-float-input.e-input-group.e-valid-input.e-input-focus label.e-label-top,.e-outline.e-float-input.e-input-group.e-input-focus label.e-label-top,.e-outline.e-float-input.e-control-wrapper.e-input-group.e-valid-input.e-input-focus label.e-label-top,.e-outline.e-float-input.e-control-wrapper.e-input-group.e-input-focus label.e-label-top{color:#e3165b}.e-outline.e-input[disabled],.e-outline.e-input-group .e-input[disabled],.e-outline.e-input-group.e-control-wrapper .e-input[disabled],.e-outline.e-input-group.e-disabled,.e-outline.e-input-group.e-control-wrapper.e-disabled,.e-outline.e-float-input input[disabled],.e-outline.e-float-input.e-control-wrapper input[disabled],.e-outline.e-float-input textarea[disabled],.e-outline.e-float-input.e-control-wrapper textarea[disabled],.e-outline.e-float-input.e-disabled,.e-outline.e-float-input.e-control-wrapper.e-disabled,.e-outline.e-input-group:not(.e-success):not(.e-warning):not(.e-error):not(.e-float-icon-left).e-disabled,.e-outline.e-input-group.e-float-icon-left:not(.e-success):not(.e-warning):not(.e-error).e-disabled .e-input-in-wrap,.e-outline.e-input-group.e-control-wrapper:not(.e-success):not(.e-warning):not(.e-error):not(.e-float-icon-left).e-disabled,.e-outline.e-input-group.e-control-wrapper.e-float-icon-left:not(.e-success):not(.e-warning):not(.e-error).e-disabled .e-input-in-wrap{background-image:none;border-bottom-color:#0000000f;border-color:#0000000f}.e-outline.e-float-input.e-input-group.e-disabled .e-float-text,.e-outline.e-float-input.e-input-group.e-disabled .e-float-text.e-label-top,.e-outline.e-float-input input[disabled]~label.e-float-text,.e-outline.e-float-input input[disabled]~label.e-label-top.e-float-text,.e-outline.e-float-input.e-disabled label.e-float-text,.e-outline.e-float-input.e-disabled label.e-float-text.e-label-top,.e-outline.e-float-input:not(.e-error) input[disabled]~label.e-float-text,.e-outline.e-float-input:not(.e-error) input[disabled]~label.e-label-top.e-float-text,.e-outline.e-float-input.e-small:not(.e-error) input[disabled]~label.e-float-text,.e-outline.e-float-input.e-small:not(.e-error) input[disabled]~label.e-float-text.e-label-top,.e-outline.e-float-input textarea[disabled]~label.e-float-text,.e-outline.e-float-input textarea[disabled]~label.e-label-top.e-float-text,.e-outline.e-float-input:not(.e-error) textarea[disabled]~label.e-float-text,.e-outline.e-float-input:not(.e-error) textarea[disabled]~label.e-label-top.e-float-text,.e-outline.e-float-input.e-small:not(.e-error) textarea[disabled]~label.e-float-text,.e-outline.e-float-input.e-small:not(.e-error) textarea[disabled]~label.e-float-text.e-label-top,.e-outline.e-float-input.e-control-wrapper.e-input-group.e-disabled .e-float-text,.e-outline.e-float-input.e-control-wrapper.e-input-group.e-disabled .e-float-text.e-label-top,.e-outline.e-float-input.e-control-wrapper.e-disabled input[disabled]~label.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-disabled input[disabled]~label.e-label-top.e-float-text,.e-outline.e-float-input.e-control-wrapper input[disabled]~label.e-float-text,.e-outline.e-float-input.e-control-wrapper input[disabled]~label.e-label-top.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-disabled label.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-disabled label.e-float-text.e-label-top,.e-outline.e-float-input.e-control-wrapper:not(.e-error) input[disabled]~label.e-float-text,.e-outline.e-float-input.e-control-wrapper:not(.e-error) input[disabled]~label.e-label-top.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-small:not(.e-error) input[disabled]~label.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-small:not(.e-error) input[disabled]~label.e-float-text.e-label-top,.e-outline.e-float-input.e-control-wrapper.e-disabled:not(.e-error) input[disabled]~label.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-disabled:not(.e-error) input[disabled]~label.e-label-top.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-disabled.e-small:not(.e-error) input[disabled]~label.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-disabled.e-small:not(.e-error) input[disabled]~label.e-float-text.e-label-top,.e-outline.e-float-input.e-control-wrapper.e-disabled textarea[disabled]~label.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-disabled textarea[disabled]~label.e-label-top.e-float-text,.e-outline.e-float-input.e-control-wrapper textarea[disabled]~label.e-float-text,.e-outline.e-float-input.e-control-wrapper textarea[disabled]~label.e-label-top.e-float-text,.e-outline.e-float-input.e-control-wrapper:not(.e-error) textarea[disabled]~label.e-float-text,.e-outline.e-float-input.e-control-wrapper:not(.e-error) textarea[disabled]~label.e-label-top.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-small:not(.e-error) textarea[disabled]~label.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-small:not(.e-error) textarea[disabled]~label.e-float-text.e-label-top,.e-outline.e-float-input.e-control-wrapper.e-disabled:not(.e-error) textarea[disabled]~label.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-disabled:not(.e-error) textarea[disabled]~label.e-label-top.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-disabled.e-small:not(.e-error) textarea[disabled]~label.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-disabled.e-small:not(.e-error) textarea[disabled]~label.e-float-text.e-label-top{color:#00000061}.e-outline.e-input-group.e-disabled .e-input-group-icon,.e-outline.e-input-group.e-control-wrapper.e-disabled .e-input-group-icon{color:#00000061}.e-outline.e-float-input:not(.e-disabled) .e-clear-icon:hover,.e-outline.e-float-input.e-control-wrapper:not(.e-disabled) .e-clear-icon:hover,.e-outline.e-input-group:not(.e-disabled) .e-clear-icon:hover,.e-outline.e-input-group.e-control-wrapper:not(.e-disabled) .e-clear-icon:hover{color:#000000de}.e-outline.e-float-input:not(.e-disabled) .e-clear-icon:active,.e-outline.e-float-input.e-control-wrapper:not(.e-disabled) .e-clear-icon:active,.e-outline.e-input-group:not(.e-disabled) .e-clear-icon:active,.e-outline.e-input-group.e-control-wrapper:not(.e-disabled) .e-clear-icon:active{color:#000000de}.e-filled.e-input-group,.e-filled.e-input-group.e-control-wrapper,.e-filled.e-float-input,.e-filled.e-float-input.e-input-group,.e-filled.e-float-input.e-control-wrapper,.e-filled.e-float-input.e-input-group.e-control-wrapper{background:#f5f5f5;transition:opacity 15ms linear,background-color 15ms linear}.e-filled.e-input-group:hover,.e-filled.e-input-group.e-control-wrapper:hover,.e-filled.e-float-input:hover,.e-filled.e-float-input.e-input-group:hover,.e-filled.e-float-input.e-control-wrapper:hover,.e-filled.e-float-input.e-input-group.e-control-wrapper:hover{background:#ececec;transition:opacity 15ms linear,background-color 15ms linear}.e-filled.e-input-group.e-input-focus,.e-filled.e-input-group.e-control-wrapper.e-input-focus,.e-filled.e-float-input.e-input-focus,.e-filled.e-float-input.e-input-group.e-input-focus,.e-filled.e-float-input.e-control-wrapper.e-input-focus,.e-filled.e-float-input.e-input-group.e-control-wrapper.e-input-focus,.e-filled.e-input-group:hover.e-input-focus,.e-filled.e-input-group:hover.e-control-wrapper.e-input-focus,.e-filled.e-float-input:hover.e-input-focus,.e-filled.e-float-input:hover.e-input-group.e-input-focus,.e-filled.e-float-input:hover.e-control-wrapper.e-input-focus,.e-filled.e-float-input:hover.e-input-group.e-control-wrapper.e-input-focus{background:#dcdcdc;transition:opacity 15ms linear,background-color 15ms linear}.e-filled.e-input-group:hover:not(.e-success):not(.e-warning):not(.e-error):not(.e-disabled):not(.e-float-icon-left),.e-filled.e-input-group.e-control-wrapper:hover:not(.e-success):not(.e-warning):not(.e-error):not(.e-disabled):not(.e-float-icon-left),.e-filled.e-float-input.e-control-wrapper:hover:not(.e-success):not(.e-warning):not(.e-error):not(.e-disabled):not(.e-float-icon-left),.e-filled.e-float-input:hover:not(.e-success):not(.e-warning):not(.e-error):not(.e-disabled):not(.e-float-icon-left),.e-filled.e-float-input:hover:not(.e-input-group):not(.e-success):not(.e-warning):not(.e-error):not(.e-disabled),.e-filled.e-float-input.e-control-wrapper:hover:not(.e-input-group):not(.e-success):not(.e-warning):not(.e-error):not(.e-disabled),.e-filled.e-input-group.e-input-focus:hover:not(.e-success):not(.e-warning):not(.e-error):not(.e-disabled):not(.e-float-icon-left),.e-filled.e-input-group.e-control-wrapper.e-input-focus:hover:not(.e-success):not(.e-warning):not(.e-error):not(.e-disabled):not(.e-float-icon-left),.e-filled.e-float-input.e-input-focus:hover:not(.e-success):not(.e-warning):not(.e-error):not(.e-disabled):not(.e-float-icon-left),.e-filled.e-float-input.e-control-wrapper.e-input-focus:hover:not(.e-success):not(.e-warning):not(.e-error):not(.e-disabled):not(.e-float-icon-left),.e-filled.e-float-input.e-input-focus:hover:not(.e-input-group):not(.e-success):not(.e-warning):not(.e-error):not(.e-disabled),.e-filled.e-float-input.e-control-wrapper.e-input-focus:hover:not(.e-input-group):not(.e-success):not(.e-warning):not(.e-error):not(.e-disabled),.e-filled.e-input-group:hover:not(.e-success):not(.e-warning):not(.e-error):not(.e-disabled).e-float-icon-left,.e-filled.e-input-group.e-control-wrapper:hover:not(.e-success):not(.e-warning):not(.e-error):not(.e-disabled).e-float-icon-left,.e-filled.e-float-input.e-control-wrapper:hover:not(.e-success):not(.e-warning):not(.e-error):not(.e-disabled).e-float-icon-left,.e-filled.e-float-input:hover:not(.e-success):not(.e-warning):not(.e-error):not(.e-disabled).e-float-icon-left,.e-filled.e-input-group.e-input-focus:hover:not(.e-success):not(.e-warning):not(.e-error):not(.e-disabled).e-float-icon-left,.e-filled.e-input-group.e-control-wrapper.e-input-focus:hover:not(.e-success):not(.e-warning):not(.e-error):not(.e-disabled).e-float-icon-left,.e-filled.e-float-input.e-input-focus:hover:not(.e-success):not(.e-warning):not(.e-error):not(.e-disabled).e-float-icon-left,.e-filled.e-float-input.e-control-wrapper.e-input-focus:hover:not(.e-success):not(.e-warning):not(.e-error):not(.e-disabled).e-float-icon-left{border-color:#000000de}.e-filled.e-input-group.e-float-icon-left:not(.e-success):not(.e-warning):not(.e-error),.e-filled.e-input-group.e-control-wrapper.e-float-icon-left:not(.e-success):not(.e-warning):not(.e-error),.e-filled.e-float-input:not(.e-success):not(.e-warning):not(.e-error),.e-filled.e-float-input.e-control-wrapper:not(.e-success):not(.e-warning):not(.e-error){border-color:#0000006b}.e-filled.e-float-input.e-success,.e-filled.e-float-input.e-control-wrapper.e-success,.e-filled.e-input-group.e-float-icon-left.e-success,.e-filled.e-input-group.e-float-icon-left.e-control-wrapper.e-success{border-bottom-color:#22b24b}.e-filled.e-float-input.e-warning,.e-filled.e-float-input.e-control-wrapper.e-warning,.e-filled.e-input-group.e-float-icon-left.e-warning,.e-filled.e-input-group.e-float-icon-left.e-control-wrapper.e-warning{border-bottom-color:#ffca1c}.e-filled.e-float-input.e-error,.e-filled.e-float-input.e-control-wrapper.e-error,.e-filled.e-input-group.e-float-icon-left.e-error,.e-filled.e-input-group.e-float-icon-left.e-control-wrapper.e-error{border-bottom-color:#f44336}.e-filled label.e-float-text,.e-filled.e-float-input:not(.e-error):not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-filled.e-float-input.e-control-wrapper:not(.e-error):not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-filled.e-float-input.e-small:not(.e-error):not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-filled.e-float-input.e-control-wrapper.e-small:not(.e-error):not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small .e-filled.e-float-input:not(.e-error):not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small .e-filled.e-float-input.e-control-wrapper:not(.e-error):not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-filled.e-float-input:not(.e-error) input:focus~label.e-float-text,.e-filled.e-float-input:not(.e-error) input:valid~label.e-float-text,.e-filled.e-float-input:not(.e-error) input~label.e-label-top.e-float-text,.e-filled.e-float-input:not(.e-error) input[readonly]~label.e-label-top.e-float-text,.e-filled.e-float-input:not(.e-error) input[disabled]~label.e-label-top.e-float-text,.e-filled.e-float-input:not(.e-error) input label.e-float-text.e-label-top,.e-filled.e-float-input:not(.e-error).e-input-focus input~label.e-float-text,.e-input-group.e-filled textarea.e-input:-ms-input-placeholder,input.e-filled.e-input::-webkit-input-placeholder,.e-input-group.e-filled.e-control-wrapper input.e-input::-webkit-input-placeholder,.e-input-group.e-filled input.e-input::-webkit-input-placeholder,textarea.e-filled.e-input::-webkit-input-placeholder,.e-input-group.e-filled textarea.e-input::-webkit-input-placeholder,.e-input-group.e-filled.e-control-wrapper textarea.e-input::-webkit-input-placeholder,.e-filled.e-float-input:not(.e-error):not(.e-input-focus) input:not(:focus):-webkit-autofill~label.e-float-text,.e-small .e-filled.e-float-input:not(.e-error):not(.e-input-focus) input:not(:focus):-webkit-autofill~label.e-float-text,.e-small.e-filled.e-float-input:not(.e-error):not(.e-input-focus) input:not(:focus):-webkit-autofill~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-autofill:not(.e-error):not(.e-input-focus) input:not(:focus):-webkit-autofill~label.e-float-text,.e-small .e-filled.e-float-input.e-control-wrapper.e-autofill:not(.e-error):not(.e-input-focus) input:not(:focus):-webkit-autofill~label.e-float-text,.e-small.e-filled.e-float-input.e-control-wrapper.e-autofill:not(.e-error):not(.e-input-focus) input:not(:focus):-webkit-autofill~label.e-float-text,.e-filled.e-float-input:not(.e-error) textarea:not(:focus):-webkit-autofill~label.e-float-text,.e-small .e-filled.e-float-input:not(.e-error) textarea:not(:focus):-webkit-autofill~label.e-float-text,.e-small.e-filled.e-float-input:not(.e-error) textarea:not(:focus):-webkit-autofill~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-autofill:not(.e-error) textarea:not(:focus):-webkit-autofill~label.e-float-text,.e-small .e-filled.e-float-input.e-control-wrapper.e-autofill:not(.e-error) textarea:not(:focus):-webkit-autofill~label.e-float-text,.e-small.e-filled.e-float-input.e-control-wrapper.e-autofill:not(.e-error) textarea:not(:focus):-webkit-autofill~label.e-float-text,input.e-filled.e-input:-moz-placeholder,.e-input-group.e-filled input.e-input:-moz-placeholder,.e-input-group.e-filled.e-control-wrapper input.e-input:-moz-placeholder,textarea.e-filled.e-input:-moz-placeholder,.e-input-group.e-filled textarea.e-input:-moz-placeholder,.e-input-group.e-filled.e-control-wrapper textarea.e-input:-moz-placeholder,input.e-filled.e-input::-moz-placeholder,.e-input-group.e-filled input.e-input::-moz-placeholder,.e-input-group.e-filled.e-control-wrapper input.e-input::-moz-placeholder,textarea.e-filled.e-input::-moz-placeholder,.e-input-group.e-filled textarea.e-input::-moz-placeholder,.e-input-group.e-filled.e-control-wrapper textarea.e-input::-moz-placeholder,input.e-filled.e-input:-ms-input-placeholder,.e-input-group.e-filled input.e-input:-ms-input-placeholder,.e-input-group.e-filled.e-control-wrapper input.e-input:-ms-input-placeholder,textarea.e-filled.e-input:-ms-input-placeholder,.e-input-group.e-filled.e-control-wrapper textarea.e-input:-ms-input-placeholder{color:#0009}.e-filled.e-float-input.e-error label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-error label.e-float-text,.e-filled.e-float-input.e-error input:focus~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-error input:focus~label.e-float-text,.e-filled.e-float-input.e-error textarea:focus~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-error textarea:focus~label.e-float-text,.e-filled.e-float-input.e-error.e-input-focus input~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-error.e-input-focus input~label.e-float-text{color:#f44336}.e-filled.e-float-input.e-success label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-success label.e-float-text,.e-filled.e-float-input.e-success input:focus~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-success input:focus~label.e-float-text,.e-filled.e-float-input.e-success textarea:focus~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-success textarea:focus~label.e-float-text,.e-filled.e-float-input.e-success.e-input-focus input~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-success.e-input-focus input~label.e-float-text,.e-filled.e-float-input.e-success input:valid~label.e-float-text,.e-filled.e-float-input.e-success input~label.e-label-top.e-float-text,.e-filled.e-float-input.e-success input[readonly]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-success input[disabled]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-success input label.e-float-text.e-label-top,.e-filled.e-float-input.e-control-wrapper.e-success input:valid~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-success input~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-success input[readonly]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-success input[disabled]~label.e-label-top.e-float-text,.e-filled.e-float-input .e-control-wrapper.e-success input label.e-float-text.e-label-top,.e-filled.e-float-input.e-small.e-success input:focus~label.e-float-text,.e-filled.e-float-input.e-small.e-success input:valid~label.e-float-text,.e-filled.e-float-input.e-small.e-success input~label.e-label-top.e-float-text,.e-filled.e-float-input.e-small.e-success input[readonly]~label.e-float-text,.e-filled.e-float-input.e-small.e-success input[disabled]~label.e-float-text,.e-small .e-filled.e-float-input.e-success input:focus~label.e-float-text,.e-small .e-filled.e-float-input.e-success input:valid~label.e-float-text,.e-small .e-filled.e-float-input.e-success input~label.e-label-top.e-float-text,.e-small .e-filled.e-float-input.e-success input[readonly]~label.e-float-text.e-label-top,.e-small .e-filled.e-float-input.e-success input[disabled]~label.e-float-text.e-label-top,.e-filled.e-float-input.e-small.e-success.e-input-focus input~label.e-float-text,.e-small .e-filled.e-float-input.e-success.e-input-focus input~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small.e-success input:focus~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small.e-success input:valid~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small.e-success input~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small.e-success input[readonly]~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small.e-success input[disabled]~label.e-float-text,.e-small .e-filled.e-float-input.e-control-wrapper.e-success input:focus~label.e-float-text,.e-small .e-filled.e-float-input.e-control-wrapper.e-success input:valid~label.e-float-text,.e-small .e-filled.e-float-input.e-control-wrapper.e-success input~label.e-label-top.e-float-text,.e-small .e-filled.e-float-input.e-control-wrapper.e-success input[readonly]~label.e-float-text.e-label-top,.e-small .e-filled.e-float-input.e-control-wrapper.e-success input[disabled]~label.e-float-text.e-label-top,.e-filled.e-float-input.e-control-wrapper.e-small.e-success.e-input-focus input~label.e-float-text,.e-small .e-filled.e-float-input.e-control-wrapper.e-success.e-input-focus input~label.e-float-text{color:#22b24b}.e-filled.e-float-input.e-warning label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-warning label.e-float-text,.e-filled.e-float-input.e-warning input:focus~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-warning input:focus~label.e-float-text,.e-filled.e-float-input.e-warning textarea:focus~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-warning textarea:focus~label.e-float-text,.e-filled.e-float-input.e-warning.e-input-focus input~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-warning.e-input-focus input~label.e-float-text,.e-filled.e-float-input.e-warning input:valid~label.e-float-text,.e-filled.e-float-input.e-warning input~label.e-label-top.e-float-text,.e-filled.e-float-input.e-warning input[readonly]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-warning input[disabled]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-warning input label.e-float-text.e-label-top,.e-filled.e-float-input.e-control-wrapper.e-warning input:valid~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-warning input~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-warning input[readonly]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-warning input[disabled]~label.e-label-top.e-float-text,.e-filled.e-float-input .e-control-wrapper.e-warning input label.e-float-text.e-label-top,.e-filled.e-float-input.e-small.e-warning input:focus~label.e-float-text,.e-filled.e-float-input.e-small.e-warning input:valid~label.e-float-text,.e-filled.e-float-input.e-small.e-warning input~label.e-label-top.e-float-text,.e-filled.e-float-input.e-small.e-warning input[readonly]~label.e-float-text,.e-filled.e-float-input.e-small.e-warning input[disabled]~label.e-float-text,.e-small .e-filled.e-float-input.e-warning input:focus~label.e-float-text,.e-small .e-filled.e-float-input.e-warning input:valid~label.e-float-text,.e-small .e-filled.e-float-input.e-warning input~label.e-label-top.e-float-text,.e-small .e-filled.e-float-input.e-warning input[readonly]~label.e-float-text.e-label-top,.e-small .e-filled.e-float-input.e-warning input[disabled]~label.e-float-text.e-label-top,.e-filled.e-float-input.e-small.e-warning.e-input-focus input~label.e-float-text,.e-small .e-filled.e-float-input.e-warning.e-input-focus input~label.e-float-text{color:#ffca1c}.e-filled.e-float-input:not(.e-error) input:focus~label.e-float-text,.e-filled.e-float-input:not(.e-error) input:valid~label.e-float-text,.e-filled.e-float-input:not(.e-error) input~label.e-label-top.e-float-text,.e-filled.e-float-input:not(.e-error) input[readonly]~label.e-label-top.e-float-text,.e-filled.e-float-input:not(.e-error) input[disabled]~label.e-label-top.e-float-text,.e-filled.e-float-input:not(.e-error) input label.e-float-text.e-label-top,.e-filled.e-float-input:not(.e-error).e-input-focus input~label.e-float-text,.e-filled.e-float-input.e-control-wrapper:not(.e-error) input:focus~label.e-float-text,.e-filled.e-float-input.e-control-wrapper:not(.e-error) input:valid~label.e-float-text,.e-filled.e-float-input.e-control-wrapper:not(.e-error) input~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper:not(.e-error) input[readonly]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper:not(.e-error) input[disabled]~label.e-label-top.e-float-text,.e-filled.e-float-input .e-control-wrapper:not(.e-error) input label.e-float-text.e-label-top,.e-filled.e-float-input.e-control-wrapper:not(.e-error).e-input-focus input~label.e-float-text,.e-filled.e-float-input.e-small:not(.e-error) input:focus~label.e-float-text,.e-filled.e-float-input.e-small:not(.e-error) input:valid~label.e-float-text,.e-filled.e-float-input.e-small:not(.e-error) input~label.e-label-top.e-float-text,.e-filled.e-float-input.e-small:not(.e-error) input[readonly]~label.e-float-text,.e-filled.e-float-input.e-small:not(.e-error) input[disabled]~label.e-float-text,.e-small .e-filled.e-float-input:not(.e-error) input:focus~label.e-float-text,.e-small .e-filled.e-float-input:not(.e-error) input:valid~label.e-float-text,.e-small .e-filled.e-float-input:not(.e-error) input~label.e-label-top.e-float-text,.e-small .e-filled.e-float-input:not(.e-error) input[readonly]~label.e-float-text.e-label-top,.e-small .e-filled.e-float-input:not(.e-error) input[disabled]~label.e-float-text.e-label-top,.e-filled.e-float-input.e-small:not(.e-error).e-input-focus input~label.e-float-text,.e-small .e-filled.e-float-input:not(.e-error).e-input-focus input~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small:not(.e-error) input:focus~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small:not(.e-error) input:valid~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small:not(.e-error) input~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small:not(.e-error) input[readonly]~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small:not(.e-error) input[disabled]~label.e-float-text,.e-small .e-filled.e-float-input.e-control-wrapper:not(.e-error) input:focus~label.e-float-text,.e-small .e-filled.e-float-input.e-control-wrapper:not(.e-error) input:valid~label.e-float-text,.e-small .e-filled.e-float-input.e-control-wrapper:not(.e-error) input~label.e-label-top.e-float-text,.e-small .e-filled.e-float-input.e-control-wrapper:not(.e-error) input[readonly]~label.e-float-text.e-label-top,.e-small .e-filled.e-float-input.e-control-wrapper:not(.e-error) input[disabled]~label.e-float-text.e-label-top,.e-filled.e-float-input.e-control-wrapper.e-small:not(.e-error).e-input-focus input~label.e-float-text,.e-small .e-filled.e-float-input.e-control-wrapper:not(.e-error).e-input-focus input~label.e-float-text,.e-filled.e-float-input:not(.e-error) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-filled.e-float-input.e-control-wrapper:not(.e-error) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-filled.e-float-input.e-small:not(.e-error) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-filled.e-float-input.e-control-wrapper.e-small:not(.e-error) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small .e-filled.e-float-input:not(.e-error) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small .e-filled.e-float-input.e-control-wrapper:not(.e-error) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-filled.e-float-input:not(.e-input-focus):not(.e-disabled) textarea:not(:focus):not(:valid)~label.e-float-text:not(.e-label-top),.e-filled.e-float-input:not(.e-input-focus) textarea:not(:focus):not(:valid)~label.e-float-text:not(.e-label-top),.e-filled.e-float-input.e-control-wrapper:not(.e-input-focus):not(.e-disabled) textarea:not(:focus):not(:valid)~label.e-float-text:not(.e-label-top),.e-filled.e-float-input:not(.e-error) textarea:focus~label.e-float-text,.e-filled.e-float-input:not(.e-error) textarea:valid~label.e-float-text,.e-filled.e-float-input:not(.e-error) textarea~label.e-label-top.e-float-text,.e-filled.e-float-input:not(.e-error) textarea[readonly]~label.e-label-top.e-float-text,.e-filled.e-float-input:not(.e-error) textarea[disabled]~label.e-label-top.e-float-text,.e-filled.e-float-input:not(.e-error) textarea label.e-float-text.e-label-top,.e-filled.e-float-input.e-control-wrapper:not(.e-error) textarea:focus~label.e-float-text,.e-filled.e-float-input.e-control-wrapper:not(.e-error) textarea:valid~label.e-float-text,.e-filled.e-float-input.e-control-wrapper:not(.e-error) textarea~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper:not(.e-error) textarea[readonly]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper:not(.e-error) textarea[disabled]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper:not(.e-error) textarea label.e-float-text.e-label-top,.e-filled.e-float-input.e-small:not(.e-error) textarea:focus~label.e-float-text,.e-filled.e-float-input.e-small:not(.e-error) textarea:valid~label.e-float-text,.e-filled.e-float-input.e-small:not(.e-error) textarea~label.e-label-top.e-float-text,.e-filled.e-float-input.e-small:not(.e-error) textarea[readonly]~label.e-float-text,.e-filled.e-float-input.e-small:not(.e-error) textarea[disabled]~label.e-float-text,.e-small .e-filled.e-float-input:not(.e-error) textarea:focus~label.e-float-text,.e-small .e-filled.e-float-input:not(.e-error) textarea:valid~label.e-float-text,.e-small .e-filled.e-float-input:not(.e-error) textarea~label.e-label-top.e-float-text,.e-small .e-filled.e-float-input:not(.e-error) textarea[readonly]~label.e-float-text.e-label-top,.e-small .e-filled.e-float-input:not(.e-error) textarea[disabled]~label.e-float-text.e-label-top,.e-filled.e-float-input.e-control-wrapper.e-small:not(.e-error) textarea:focus~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small:not(.e-error) textarea:valid~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small:not(.e-error) textarea~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small:not(.e-error) textarea[readonly]~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small:not(.e-error) textarea[disabled]~label.e-float-text,.e-small .e-filled.e-float-input.e-control-wrapper:not(.e-error) textarea:focus~label.e-float-text,.e-small .e-filled.e-float-input.e-control-wrapper:not(.e-error) textarea:valid~label.e-float-text,.e-small .e-filled.e-float-input.e-control-wrapper:not(.e-error) textarea~label.e-label-top.e-float-text,.e-small .e-filled.e-float-input.e-control-wrapper:not(.e-error) textarea[readonly]~label.e-float-text.e-label-top,.e-small .e-filled.e-float-input.e-control-wrapper:not(.e-error) textarea[disabled]~label.e-float-text.e-label-top{color:#0009}.e-filled.e-float-input:not(.e-error) input:focus~label.e-float-text,.e-filled.e-float-input.e-small:not(.e-error) input:focus~label.e-float-text,.e-small .e-filled.e-float-input:not(.e-error) input:focus~label.e-float-text,.e-filled.e-float-input:not(.e-error) input[readonly]:focus~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper:not(.e-error) input[readonly]:focus~label.e-label-top.e-float-text,.e-filled.e-float-input.e-small:not(.e-error) input[readonly]:focus~label.e-float-text,.e-small .e-filled.e-float-input:not(.e-error) input[readonly]:focus~label.e-float-text.e-label-top,.e-filled.e-float-input.e-control-wrapper.e-small:not(.e-error) input[readonly]:focus~label.e-float-text,.e-small .e-float-input.e-control-wrapper:not(.e-error) input[readonly]:focus~label.e-float-text.e-label-top,.e-filled.e-float-input:not(.e-error).e-input-focus input[readonly]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper:not(.e-error).e-input-focus input[readonly]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-small:not(.e-error).e-input-focus input[readonly]~label.e-float-text,.e-small .e-filled.e-float-input:not(.e-error).e-input-focus input[readonly]~label.e-float-text.e-label-top,.e-filled.e-float-input.e-control-wrapper.e-small:not(.e-error).e-input-focus input[readonly]~label.e-float-text,.e-small .e-filled.e-float-input.e-control-wrapper:not(.e-error).e-input-focus input[readonly]~label.e-float-text.e-label-top,.e-filled.e-float-input:not(.e-error) textarea[readonly]:focus~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper:not(.e-error) textarea[readonly]:focus~label.e-label-top.e-float-text,.e-filled.e-float-input.e-small:not(.e-error) textarea[readonly]:focus~label.e-float-text,.e-small .e-filled.e-float-input:not(.e-error) textarea[readonly]:focus~label.e-float-text.e-label-top,.e-small .e-filled.e-float-input.e-control-wrapper:not(.e-error) textarea[readonly]:focus~label.e-float-text.e-label-top,.e-filled.e-float-input:not(.e-error).e-input-focus textarea[readonly]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper:not(.e-error).e-input-focus textarea[readonly]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-small:not(.e-error).e-input-focus textarea[readonly]~label.e-float-text,.e-small .e-filled.e-float-input:not(.e-error).e-input-focus textarea[readonly]~label.e-float-text.e-label-top,.e-small .e-filled.e-float-input.e-control-wrapper:not(.e-error).e-input-focus textarea[readonly]~label.e-float-text.e-label-top,.e-filled.e-float-input:not(.e-error) textarea:focus~label.e-float-text,.e-filled.e-float-input.e-small:not(.e-error) textarea:focus~label.e-float-text,.e-small .e-filled.e-float-input:not(.e-error) textarea:focus~label.e-float-text,.e-filled.e-float-input.e-control-wrapper:not(.e-error) input:focus~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small:not(.e-error) input:focus~label.e-float-text,.e-small .e-filled.e-float-input.e-control-wrapper:not(.e-error) input:focus~label.e-float-text,.e-filled.e-float-input.e-control-wrapper:not(.e-error) textarea:focus~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small:not(.e-error) textarea:focus~label.e-float-text,.e-small .e-filled.e-float-input.e-control-wrapper:not(.e-error) textarea:focus~label.e-float-text,.e-filled.e-float-input:not(.e-error).e-input-focus input~label.e-float-text,.e-filled.e-float-input.e-small:not(.e-error).e-input-focus input~label.e-float-text,.e-small .e-filled.e-float-input:not(.e-error).e-input-focus input~label.e-float-text,.e-filled.e-float-input.e-control-wrapper:not(.e-error).e-input-focus input~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small:not(.e-error).e-input-focus input~label.e-float-text,.e-small .e-filled.e-float-input.e-control-wrapper:not(.e-error).e-input-focus input~label.e-float-text{color:#e3165b}.e-filled.e-float-input:not(.e-disabled) .e-clear-icon:hover,.e-filled.e-float-input.e-control-wrapper:not(.e-disabled) .e-clear-icon:hover,.e-filled.e-input-group:not(.e-disabled) .e-clear-icon:hover,.e-filled.e-input-group.e-control-wrapper:not(.e-disabled) .e-clear-icon:hover{color:#000000de}.e-filled.e-float-input:not(.e-disabled) .e-clear-icon:active,.e-filled.e-float-input.e-control-wrapper:not(.e-disabled) .e-clear-icon:active,.e-filled.e-input-group:not(.e-disabled) .e-clear-icon:active,.e-filled.e-input-group.e-control-wrapper:not(.e-disabled) .e-clear-icon:active{color:#000000de}.e-filled.e-input[disabled],.e-input-group.e-filled .e-input[disabled],.e-input-group.e-filled.e-control-wrapper .e-input[disabled],.e-input-group.e-filled.e-disabled,.e-input-group.e-filled.e-control-wrapper.e-disabled,.e-filled.e-float-input input[disabled],.e-filled.e-float-input.e-control-wrapper input[disabled],.e-filled.e-float-input textarea[disabled],.e-filled.e-float-input.e-control-wrapper textarea[disabled],.e-filled.e-float-input.e-disabled,.e-filled.e-float-input.e-control-wrapper.e-disabled{background:#fafafa;background-image:none;background-position:initial;background-repeat:no-repeat;background-size:0;border-color:#0000000f;color:#00000061}.e-filled.e-float-input.e-disabled:not(.e-success):not(.e-warning):not(.e-error),.e-filled.e-float-input.e-control-wrapper.e-disabled:not(.e-success):not(.e-warning):not(.e-error){border-color:#0000000f}.e-filled.e-input-group:not(.e-success):not(.e-warning):not(.e-error):not(.e-float-icon-left).e-disabled,.e-filled.e-input-group.e-float-icon-left:not(.e-success):not(.e-warning):not(.e-error).e-disabled .e-input-in-wrap,.e-filled.e-input-group.e-control-wrapper:not(.e-success):not(.e-warning):not(.e-error):not(.e-float-icon-left).e-disabled,.e-filled.e-input-group.e-control-wrapper.e-float-icon-left:not(.e-success):not(.e-warning):not(.e-error).e-disabled .e-input-in-wrap{background:#fafafa;background-image:none;background-position:initial;background-repeat:no-repeat;background-size:0;border-color:#0000000f;color:#00000061}.e-filled.e-float-input.e-input-group.e-disabled .e-float-text,.e-filled.e-float-input.e-input-group.e-disabled .e-float-text.e-label-top,.e-filled.e-float-input input[disabled]~label.e-float-text,.e-filled.e-float-input input[disabled]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-disabled label.e-float-text,.e-filled.e-float-input.e-disabled label.e-float-text.e-label-top,.e-filled.e-float-input:not(.e-error) input[disabled]~label.e-float-text,.e-filled.e-float-input:not(.e-error) input[disabled]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-small:not(.e-error) input[disabled]~label.e-float-text,.e-filled.e-float-input.e-small:not(.e-error) input[disabled]~label.e-float-text.e-label-top,.e-filled.e-float-input textarea[disabled]~label.e-float-text,.e-filled.e-float-input textarea[disabled]~label.e-label-top.e-float-text,.e-filled.e-float-input:not(.e-error) textarea[disabled]~label.e-float-text,.e-filled.e-float-input:not(.e-error) textarea[disabled]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-small:not(.e-error) textarea[disabled]~label.e-float-text,.e-filled.e-float-input.e-small:not(.e-error) textarea[disabled]~label.e-float-text.e-label-top,.e-filled.e-float-input.e-control-wrapper.e-input-group.e-disabled .e-float-text,.e-filled.e-float-input.e-control-wrapper.e-input-group.e-disabled .e-float-text.e-label-top,.e-filled.e-float-input.e-control-wrapper.e-disabled input[disabled]~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-disabled input[disabled]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper input[disabled]~label.e-float-text,.e-filled.e-float-input.e-control-wrapper input[disabled]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-disabled label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-disabled label.e-float-text.e-label-top,.e-filled.e-float-input.e-control-wrapper:not(.e-error) input[disabled]~label.e-float-text,.e-filled.e-float-input.e-control-wrapper:not(.e-error) input[disabled]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small:not(.e-error) input[disabled]~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small:not(.e-error) input[disabled]~label.e-float-text.e-label-top,.e-filled.e-float-input.e-control-wrapper.e-disabled:not(.e-error) input[disabled]~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-disabled:not(.e-error) input[disabled]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-disabled.e-small:not(.e-error) input[disabled]~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-disabled.e-small:not(.e-error) input[disabled]~label.e-float-text.e-label-top,.e-filled.e-float-input.e-control-wrapper.e-disabled textarea[disabled]~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-disabled textarea[disabled]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper textarea[disabled]~label.e-float-text,.e-filled.e-float-input.e-control-wrapper textarea[disabled]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper:not(.e-error) textarea[disabled]~label.e-float-text,.e-filled.e-float-input.e-control-wrapper:not(.e-error) textarea[disabled]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small:not(.e-error) textarea[disabled]~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small:not(.e-error) textarea[disabled]~label.e-float-text.e-label-top,.e-filled.e-float-input.e-control-wrapper.e-disabled:not(.e-error) textarea[disabled]~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-disabled:not(.e-error) textarea[disabled]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-disabled.e-small:not(.e-error) textarea[disabled]~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-disabled.e-small:not(.e-error) textarea[disabled]~label.e-float-text.e-label-top,input.e-filled.e-disabled.e-input:-moz-placeholder,.e-input-group.e-filled.e-disabled input.e-input:-moz-placeholder,.e-input-group.e-filled.e-disabled.e-control-wrapper input.e-input:-moz-placeholder,textarea.e-filled.e-disabled.e-input:-moz-placeholder,.e-input-group.e-filled.e-disabled textarea.e-input:-moz-placeholder,.e-input-group.e-filled.e-disabled.e-control-wrapper textarea.e-input:-moz-placeholder,input.e-filled.e-disabled.e-input::-moz-placeholder,.e-input-group.e-filled.e-disabled input.e-input::-moz-placeholder,.e-input-group.e-filled.e-disabled.e-control-wrapper input.e-input::-moz-placeholder,textarea.e-filled.e-disabled.e-input::-moz-placeholder,.e-input-group.e-filled.e-disabled textarea.e-input::-moz-placeholder,.e-input-group.e-filled.e-disabled.e-control-wrapper textarea.e-input::-moz-placeholder,input.e-filled.e-disabled.e-input:-ms-input-placeholder,.e-input-group.e-filled.e-disabled input.e-input:-ms-input-placeholder,.e-input-group.e-filled.e-disabled.e-control-wrapper input.e-input:-ms-input-placeholder,textarea.e-filled.e-disabled.e-input:-ms-input-placeholder,.e-input-group.e-filled.e-disabled.e-control-wrapper textarea.e-input:-ms-input-placeholder,.e-input-group.e-filled.e-disabled textarea.e-input:-ms-input-placeholder,input.e-filled.e-disabled.e-input::-webkit-input-placeholder,.e-input-group.e-filled.e-disabled.e-control-wrapper input.e-input::-webkit-input-placeholder,.e-input-group.e-filled.e-disabled input.e-input::-webkit-input-placeholder,textarea.e-filled.e-disabled.e-input::-webkit-input-placeholder,.e-input-group.e-filled.e-disabled textarea.e-input::-webkit-input-placeholder,.e-input-group.e-filled.e-disabled.e-control-wrapper textarea.e-input::-webkit-input-placeholder,.e-filled.e-float-input.e-disabled .e-clear-icon,.e-filled.e-float-input.e-control-wrapper.e-disabled .e-clear-icon,.e-input-group.e-filled.e-disabled .e-clear-icon,.e-input-group.e-filled.e-control-wrapper.e-disabled .e-clear-icon,.e-input-group.e-filled.e-disabled .e-input-group-icon,.e-input-group.e-filled.e-control-wrapper.e-disabled .e-input-group-icon,.e-filled.e-float-input:not(.e-disabled) input[disabled],.e-filled.e-float-input.e-control-wrapper:not(.e-disabled) input[disabled],.e-filled.e-float-input:not(.e-disabled) textarea[disabled],.e-filled.e-float-input.e-control-wrapper:not(.e-disabled) textarea[disabled]{color:#00000061}.e-filled.e-float-input.e-success textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-filled.e-float-input.e-control-wrapper.e-success textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-filled.e-float-input.e-small.e-success textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-filled.e-float-input.e-control-wrapper.e-small.e-success textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small .e-filled.e-float-input.e-success textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small .e-filled.e-float-input.e-control-wrapper.e-success textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-filled.e-float-input.e-success textarea:focus~label.e-float-text,.e-filled.e-float-input.e-success textarea:valid~label.e-float-text,.e-filled.e-float-input.e-success textarea~label.e-label-top.e-float-text,.e-filled.e-float-input.e-success textarea[readonly]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-success textarea[disabled]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-success textarea label.e-float-text.e-label-top,.e-filled.e-float-input.e-control-wrapper.e-success textarea:focus~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-success textarea:valid~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-success textarea~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-success textarea[readonly]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-success textarea[disabled]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-success textarea label.e-float-text.e-label-top,.e-filled.e-float-input.e-small.e-success textarea:focus~label.e-float-text,.e-filled.e-float-input.e-small.e-success textarea:valid~label.e-float-text,.e-filled.e-float-input.e-small.e-success textarea~label.e-label-top.e-float-text,.e-filled.e-float-input.e-small.e-success textarea[readonly]~label.e-float-text,.e-filled.e-float-input.e-small.e-success textarea[disabled]~label.e-float-text,.e-small .e-filled.e-float-input.e-success textarea:focus~label.e-float-text,.e-small .e-filled.e-float-input.e-success textarea:valid~label.e-float-text,.e-small .e-filled.e-float-input.e-success textarea~label.e-label-top.e-float-text,.e-small .e-filled.e-float-input.e-success textarea[readonly]~label.e-float-text.e-label-top,.e-small .e-filled.e-float-input.e-success textarea[disabled]~label.e-float-text.e-label-top,.e-filled.e-float-input.e-control-wrapper.e-small.e-success textarea:focus~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small.e-success textarea:valid~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small.e-success textarea~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small.e-success textarea[readonly]~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small.e-success textarea[disabled]~label.e-float-text,.e-small .e-filled.e-float-input.e-control-wrapper.e-success textarea:focus~label.e-float-text,.e-small .e-filled.e-float-input.e-control-wrapper.e-success textarea:valid~label.e-float-text,.e-small .e-filled.e-float-input.e-control-wrapper.e-success textarea~label.e-label-top.e-float-text,.e-small .e-filled.e-float-input.e-control-wrapper.e-success textarea[readonly]~label.e-float-text.e-label-top,.e-small .e-filled.e-float-input.e-control-wrapper.e-success textarea[disabled]~label.e-float-text.e-label-top,.e-filled.e-float-input.e-success input:focus~label.e-float-text,.e-filled.e-float-input.e-small.e-success input:focus~label.e-float-text,.e-small .e-filled.e-float-input.e-success input:focus~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-success input:focus~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small.e-success input:focus~label.e-float-text,.e-small .e-filled.e-float-input.e-control-wrapper.e-success input:focus~label.e-float-text,.e-filled.e-float-input.e-success.e-input-focus input~label.e-float-text,.e-filled.e-float-input.e-small.e-success.e-input-focus input~label.e-float-text,.e-small .e-filled.e-float-input.e-success.e-input-focus input~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-success.e-input-focus input~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small.e-success.e-input-focus input~label.e-float-text,.e-small .e-filled.e-float-input.e-control-wrapper.e-success.e-input-focus input~label.e-float-text,.e-filled.e-float-input.e-success:not(.e-input-focus) input:not(:focus):-webkit-autofill~label.e-float-text,.e-small .e-filled.e-float-input.e-success:not(.e-input-focus) input:not(:focus):-webkit-autofill~label.e-float-text,.e-small.e-filled.e-float-input.e-success:not(.e-input-focus) input:not(:focus):-webkit-autofill~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-autofill.e-success:not(.e-input-focus) input:not(:focus):-webkit-autofill~label.e-float-text,.e-small .e-filled.e-float-input.e-control-wrapper.e-autofill.e-success:not(.e-input-focus) input:not(:focus):-webkit-autofill~label.e-float-text,.e-small.e-filled.e-float-input.e-control-wrapper.e-autofill.e-success:not(.e-input-focus) input:not(:focus):-webkit-autofill~label.e-float-text,.e-filled.e-float-input.e-success textarea:not(:focus):-webkit-autofill~label.e-float-text,.e-small .e-filled.e-float-input.e-success textarea:not(:focus):-webkit-autofill~label.e-float-text,.e-small.e-filled.e-float-input.e-success textarea:not(:focus):-webkit-autofill~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-autofill.e-success textarea:not(:focus):-webkit-autofill~label.e-float-text,.e-small .e-filled.e-float-input.e-control-wrapper.e-autofill.e-success textarea:not(:focus):-webkit-autofill~label.e-float-text,.e-small.e-filled.e-float-input.e-control-wrapper.e-autofill.e-success textarea:not(:focus):-webkit-autofill~label.e-float-text{color:#22b24b}.e-filled.e-float-input.e-control-wrapper.e-small.e-warning input:focus~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small.e-warning input:valid~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small.e-warning input~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small.e-warning input[readonly]~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small.e-warning input[disabled]~label.e-float-text,.e-small .e-filled.e-float-input.e-control-wrapper.e-warning input:focus~label.e-float-text,.e-small .e-filled.e-float-input.e-control-wrapper.e-warning input:valid~label.e-float-text,.e-small .e-filled.e-float-input.e-control-wrapper.e-warning input~label.e-label-top.e-float-text,.e-small .e-filled.e-float-input.e-control-wrapper.e-warning input[readonly]~label.e-float-text.e-label-top,.e-small .e-filled.e-float-input.e-control-wrapper.e-warning input[disabled]~label.e-float-text.e-label-top,.e-filled.e-float-input.e-control-wrapper.e-small.e-warning.e-input-focus input~label.e-float-text,.e-small .e-filled.e-float-input.e-control-wrapper.e-warning.e-input-focus input~label.e-float-text,.e-filled.e-float-input.e-warning textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-filled.e-float-input.e-control-wrapper.e-warning textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-filled.e-float-input.e-small.e-warning textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-filled.e-float-input.e-control-wrapper.e-small.e-warning textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small .e-filled.e-float-input.e-warning textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small .e-filled.e-float-input.e-control-wrapper.e-warning textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-filled.e-float-input.e-warning textarea:focus~label.e-float-text,.e-filled.e-float-input.e-warning textarea:valid~label.e-float-text,.e-filled.e-float-input.e-warning textarea~label.e-label-top.e-float-text,.e-filled.e-float-input.e-warning textarea[readonly]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-warning textarea[disabled]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-warning textarea label.e-float-text.e-label-top,.e-filled.e-float-input.e-control-wrapper.e-warning textarea:focus~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-warning textarea:valid~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-warning textarea~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-warning textarea[readonly]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-warning textarea[disabled]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-warning textarea label.e-float-text.e-label-top,.e-filled.e-float-input.e-small.e-warning textarea:focus~label.e-float-text,.e-filled.e-float-input.e-small.e-warning textarea:valid~label.e-float-text,.e-filled.e-float-input.e-small.e-warning textarea~label.e-label-top.e-float-text,.e-filled.e-float-input.e-small.e-warning textarea[readonly]~label.e-float-text,.e-filled.e-float-input.e-small.e-warning textarea[disabled]~label.e-float-text,.e-small .e-filled.e-float-input.e-warning textarea:focus~label.e-float-text,.e-small .e-filled.e-float-input.e-warning textarea:valid~label.e-float-text,.e-small .e-filled.e-float-input.e-warning textarea~label.e-label-top.e-float-text,.e-small .e-filled.e-float-input.e-warning textarea[readonly]~label.e-float-text.e-label-top,.e-small .e-filled.e-float-input.e-warning textarea[disabled]~label.e-float-text.e-label-top,.e-filled.e-float-input.e-control-wrapper.e-small.e-warning textarea:focus~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small.e-warning textarea:valid~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small.e-warning textarea~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small.e-warning textarea[readonly]~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small.e-warning textarea[disabled]~label.e-float-text,.e-small .e-filled.e-float-input.e-control-wrapper.e-warning textarea:focus~label.e-float-text,.e-small .e-filled.e-float-input.e-control-wrapper.e-warning textarea:valid~label.e-float-text,.e-small .e-filled.e-float-input.e-control-wrapper.e-warning textarea~label.e-label-top.e-float-text,.e-small .e-filled.e-float-input.e-control-wrapper.e-warning textarea[readonly]~label.e-float-text.e-label-top,.e-small .e-filled.e-float-input.e-control-wrapper.e-warning textarea[disabled]~label.e-float-text.e-label-top,.e-filled.e-float-input.e-warning input:focus~label.e-float-text,.e-filled.e-float-input.e-small.e-warning input:focus~label.e-float-text,.e-small .e-filled.e-float-input.e-warning input:focus~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-warning input:focus~label.e-float-text,.e-filled.e-float-input.e-warning.e-input-focus input~label.e-float-text,.e-filled.e-float-input.e-small.e-warning.e-input-focus input~label.e-float-text,.e-small .e-filled.e-float-input.e-warning.e-input-focus input~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-warning.e-input-focus inputs~label.e-float-text,.e-filled.e-float-input.e-warning:not(.e-input-focus) input:not(:focus):-webkit-autofill~label.e-float-text,.e-small .e-filled.e-float-input.e-warning:not(.e-input-focus) input:not(:focus):-webkit-autofill~label.e-float-text,.e-small.e-filled.e-float-input.e-warning:not(.e-input-focus) input:not(:focus):-webkit-autofill~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-autofill.e-warning:not(.e-input-focus) input:not(:focus):-webkit-autofill~label.e-float-text,.e-small .e-filled.e-float-input.e-control-wrapper.e-autofill.e-warning:not(.e-input-focus) input:not(:focus):-webkit-autofill~label.e-float-text,.e-small.e-filled.e-float-input.e-control-wrapper.e-autofill.e-warning:not(.e-input-focus) input:not(:focus):-webkit-autofill~label.e-float-text,.e-filled.e-float-input.e-warning textarea:not(:focus):-webkit-autofill~label.e-float-text,.e-small .e-filled.e-float-input.e-warning textarea:not(:focus):-webkit-autofill~label.e-float-text,.e-small.e-filled.e-float-input.e-warning textarea:not(:focus):-webkit-autofill~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-autofill.e-warning textarea:not(:focus):-webkit-autofill~label.e-float-text,.e-small .e-filled.e-float-input.e-control-wrapper.e-autofill.e-warning textarea:not(:focus):-webkit-autofill~label.e-float-text,.e-small.e-filled.e-float-input.e-control-wrapper.e-autofill.e-warning textarea:not(:focus):-webkit-autofill~label.e-float-text{color:#ffca1c}.e-input-group.e-bigger .e-input,.e-input-group.e-bigger.e-control-wrapper .e-input,.e-bigger .e-input-group .e-input,.e-bigger .e-input-group.e-control-wrapper .e-input{font:inherit}.e-input.e-bigger:focus,.e-bigger .e-input:focus{padding-bottom:5px}.e-input.e-bigger:focus,.e-bigger .e-input:focus{padding-bottom:4px}input.e-input.e-bigger,textarea.e-input.e-bigger,.e-bigger input.e-input,.e-bigger textarea.e-input,.e-input-group.e-bigger,.e-bigger .e-input-group,.e-input-group.e-control-wrapper.e-bigger,.e-bigger .e-input-group.e-control-wrapper{font-size:14px}input.e-input.e-bigger,textarea.e-input.e-bigger,.e-input-group.e-bigger .e-input,.e-input-group.e-bigger.e-control-wrapper .e-input,.e-bigger input.e-input,.e-bigger textarea.e-input,.e-bigger .e-input-group .e-input,.e-bigger .e-input-group.e-control-wrapper .e-input{line-height:inherit;margin-bottom:8px;padding:5px 0}.e-input-group.e-bigger .e-input:focus,.e-bigger .e-input-group .e-input:focus,.e-input-group.e-control-wrapper.e-bigger .e-input:focus,.e-bigger .e-input-group.e-control-wrapper .e-input:focus,.e-input-group.e-bigger.e-input-focus .e-input,.e-bigger .e-input-group.e-input-focus .e-input,.e-input-group.e-control-wrapper.e-bigger.e-input-focus .e-input,.e-bigger .e-input-group.e-control-wrapper.e-input-focus .e-input{padding:5px 0}.e-input-group.e-bigger .e-input-group-icon,.e-input-group .e-input-group-icon.e-bigger,.e-bigger .e-input-group .e-input-group-icon,.e-input-group.e-control-wrapper.e-bigger .e-input-group-icon,.e-input-group.e-control-wrapper .e-input-group-icon.e-bigger,.e-bigger .e-input-group.e-control-wrapper .e-input-group-icon{min-height:20px;min-width:20px}.e-input-group.e-bigger .e-input-group-icon,.e-input-group .e-input-group-icon.e-bigger,.e-bigger .e-input-group .e-input-group-icon,.e-input-group.e-control-wrapper.e-bigger .e-input-group-icon,.e-input-group.e-control-wrapper .e-input-group-icon.e-bigger,.e-bigger .e-input-group.e-control-wrapper .e-input-group-icon{font-size:12px;padding:0}.e-input-group.e-bigger.e-float-icon-left>.e-input-group-icon,.e-input-group.e-float-icon-left>.e-input-group-icon.e-bigger,.e-bigger .e-input-group.e-float-icon-left>.e-input-group-icon,.e-float-input.e-input-group.e-bigger.e-float-icon-left>.e-input-group-icon,.e-float-input.e-input-group.e-float-icon-left>.e-input-group-icon.e-bigger,.e-bigger .e-float-input.e-input-group.e-float-icon-left>.e-input-group-icon,.e-input-group.e-control-wrapper.e-bigger.e-float-icon-left>.e-input-group-icon,.e-input-group.e-control-wrapper.e-float-icon-left>.e-input-group-icon.e-bigger,.e-bigger .e-input-group.e-control-wrapper.e-float-icon-left>.e-input-group-icon,.e-float-input.e-input-group.e-control-wrapper.e-bigger.e-float-icon-left>.e-input-group-icon,.e-float-input.e-input-group.e-control-wrapper.e-float-icon-left>.e-input-group-icon.e-bigger,.e-bigger .e-float-input.e-input-group.e-control-wrapper.e-float-icon-left>.e-input-group-icon{font-size:20px;margin:0;min-height:32px;min-width:32px;padding:0}.e-input.e-small.e-bigger:focus,.e-bigger .e-input.e-small:focus{padding-bottom:4px}.e-input.e-small.e-bigger:focus,.e-bigger .e-input.e-small:focus{padding-bottom:3px}.e-input-group.e-small.e-bigger.e-float-icon-left>.e-input-group-icon,.e-input-group.e-small.e-float-icon-left>.e-input-group-icon.e-bigger,.e-bigger .e-input-group.e-small.e-float-icon-left>.e-input-group-icon,.e-float-input.e-input-group.e-small.e-bigger.e-float-icon-left>.e-input-group-icon,.e-float-input.e-input-group.e-small.e-float-icon-left>.e-input-group-icon.e-bigger,.e-bigger .e-input-group.e-float-input.e-small.e-float-icon-left>.e-input-group-icon,.e-input-group.e-control-wrapper.e-small.e-bigger.e-float-icon-left>.e-input-group-icon,.e-input-group.e-control-wrapper.e-small.e-float-icon-left>.e-input-group-icon.e-bigger,.e-bigger .e-input-group.e-control-wrapper.e-small.e-float-icon-left>.e-input-group-icon,.e-float-input.e-control-wrapper.e-input-group.e-small.e-bigger.e-float-icon-left>.e-input-group-icon,.e-float-input.e-control-wrapper.e-input-group.e-small.e-float-icon-left>.e-input-group-icon.e-bigger,.e-bigger .e-input-group.e-control-wrapper.e-float-input.e-small.e-float-icon-left>.e-input-group-icon{font-size:20px;margin:0;min-height:30px;min-width:30px;padding:0}.e-input.e-small.e-bigger,.e-input-group.e-small.e-bigger,.e-small.e-bigger .e-input-group,.e-input-group.e-control-wrapper.e-small.e-bigger,.e-small.e-bigger .e-input-group.e-control-wrapper,.e-bigger .e-input.e-small,.e-small .e-input.e-bigger,.e-bigger .e-input-group.e-small,.e-bigger .e-input-group.e-control-wrapper.e-small,.e-small .e-input-group.e-bigger,.e-small .e-input-group.e-control-wrapper.e-bigger,.e-input-group.e-small.e-bigger.e-disabled,.e-small.e-bigger .e-input-group.e-disabled,.e-input-group.e-control-wrapper.e-small.e-bigger.e-disabled,.e-small.e-bigger .e-input-group.e-control-wrapper.e-disabled,.e-bigger .e-input.e-small.e-disabled,.e-small .e-input.e-bigger.e-disabled,.e-bigger .e-input-group.e-small.e-disabled,.e-bigger .e-input-group.e-control-wrapper.e-small.e-disabled,.e-small .e-input-group.e-bigger.e-disabled,.e-small .e-input-group.e-control-wrapper.e-bigger.e-disabled{font-size:13px}.e-input-group.e-small.e-bigger .e-input,.e-input-group.e-small .e-input.e-bigger,.e-input-group.e-control-wrapper.e-small.e-bigger .e-input,.e-input-group.e-control-wrapper.e-small .e-input.e-bigger,.e-bigger .e-input-group.e-small .e-input,.e-bigger .e-input-group.e-control-wrapper.e-small .e-input{font:inherit;padding:4px 0}.e-input-group.e-small.e-bigger .e-input:focus,.e-input-group.e-small .e-input.e-bigger:focus,.e-bigger .e-input-group.e-small .e-input:focus,.e-input-group.e-control-wrapper.e-small.e-bigger .e-input:focus,.e-input-group.e-control-wrapper.e-small .e-input.e-bigger:focus,.e-bigger .e-input-group.e-control-wrapper.e-small .e-input:focus,.e-input-group.e-small.e-bigger.e-input-focus .e-input,.e-input-group.e-small.e-input-focus .e-input.e-bigger,.e-bigger .e-input-group.e-small.e-input-focus .e-input,.e-input-group.e-control-wrapper.e-small.e-bigger.e-input-focus .e-input,.e-input-group.e-control-wrapper.e-small.e-input-focus .e-input.e-bigger,.e-bigger .e-input-group.e-control-wrapper.e-small.e-input-focus .e-input,.e-input.e-small.e-bigger,.e-bigger .e-input.e-small,.e-small .e-input.e-bigger{padding:4px 0}.e-input-group.e-small.e-bigger .e-input-group-icon,.e-input-group.e-small .e-input-group-icon.e-bigger,.e-input-group.e-control-wrapper.e-small.e-bigger .e-input-group-icon,.e-input-group.e-control-wrapper.e-small .e-input-group-icon.e-bigger,.e-small.e-bigger .e-input-group .e-input-group-icon,.e-small.e-bigger .e-input-group.e-control-wrapper .e-input-group-icon,.e-bigger .e-input-group.e-small .e-input-group-icon,.e-bigger .e-input-group.e-control-wrapper.e-small .e-input-group-icon{font-size:12px;min-height:18px;min-width:18px;padding:0}.e-float-input.e-bigger label.e-float-text,.e-float-input label.e-float-text.e-bigger,.e-float-input input.e-bigger~label.e-float-text,.e-bigger .e-float-input label.e-float-text,.e-float-input.e-bigger:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger .e-float-input:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-float-input.e-control-wrapper.e-bigger label.e-float-text,.e-float-input.e-control-wrapper label.e-float-text.e-bigger,.e-float-input.e-control-wrapper input.e-bigger~label.e-float-text,.e-bigger .e-float-input.e-control-wrapper label.e-float-text,.e-float-input.e-control-wrapper.e-bigger:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger .e-float-input.e-control-wrapper:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom{font-size:14px;top:-8px}.e-float-input.e-bigger:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger .e-float-input:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger .e-float-input.e-small:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small .e-float-input.e-bigger:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-float-input.e-bigger.e-small:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger.e-small .e-float-input:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-float-input.e-control-wrapper.e-bigger:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger .e-float-input.e-control-wrapper:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger .e-float-input.e-control-wrapper.e-small:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small .e-float-input.e-control-wrapper.e-bigger:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-float-input.e-control-wrapper.e-bigger.e-small:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger.e-small .e-float-input.e-control-wrapper:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom{content:"";font-style:normal}.e-float-input.e-small.e-bigger label.e-float-text,.e-bigger .e-float-input.e-small label.e-float-text,.e-bigger .e-float-input.e-small:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small .e-float-input.e-bigger:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-float-input.e-bigger.e-small:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger.e-small .e-float-input:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-float-input.e-control-wrapper.e-small.e-bigger label.e-float-text,.e-bigger .e-float-input.e-control-wrapper.e-small label.e-float-text,.e-bigger .e-float-input.e-control-wrapper.e-small:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small .e-float-input.e-control-wrapper.e-bigger:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-float-input.e-control-wrapper.e-bigger.e-small:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger.e-small .e-float-input.e-control-wrapper:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom{font-size:13px;top:-9px;font-style:normal}.e-float-input.e-bigger .e-input-in-wrap label.e-float-text,.e-float-input .e-input-in-wrap label.e-float-text.e-bigger,.e-float-input .e-input-in-wrap input.e-bigger~label.e-float-text,.e-bigger .e-float-input .e-input-in-wrap label.e-float-text,.e-float-input.e-bigger:not(.e-input-focus) .e-input-in-wrap input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger .e-float-input:not(.e-input-focus) .e-input-in-wrap input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-float-input.e-control-wrapper.e-bigger .e-input-in-wrap label.e-float-text,.e-float-input.e-control-wrapper .e-input-in-wrap label.e-float-text.e-bigger,.e-float-input.e-control-wrapper .e-input-in-wrap input.e-bigger~label.e-float-text,.e-bigger.e-float-input.e-control-wrapper .e-input-in-wrap label.e-float-text,.e-float-input.e-control-wrapper.e-bigger:not(.e-input-focus) .e-input-in-wrap input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger.e-float-input.e-control-wrapper:not(.e-input-focus) .e-input-in-wrap input:not(:focus):valid~label.e-float-text.e-label-bottom{top:-8px}.e-float-input.e-bigger.e-input-focus input~label.e-float-text,.e-bigger .e-float-input.e-input-focus input~label.e-float-text,.e-float-input.e-control-wrapper.e-bigger.e-input-focus input~label.e-float-text,.e-bigger .e-float-input.e-control-wrapper.e-input-focus input~label.e-float-text{font-size:13px;top:-9px;transform:translate3d(0,-6px,0) scale(.92)}.e-float-input.e-bigger input:focus~label.e-float-text,.e-float-input.e-bigger input:valid~label.e-float-text,.e-float-input.e-bigger input~label.e-label-top.e-float-text,.e-float-input.e-bigger input[readonly]~label.e-label-top.e-float-text,.e-float-input.e-bigger input[disabled]~label.e-label-top.e-float-text,.e-float-input.e-bigger input label.e-float-text.e-label-top,.e-bigger .e-float-input input:focus~label.e-float-text,.e-bigger .e-float-input input:valid~label.e-float-text,.e-bigger .e-float-input input~label.e-label-top.e-float-text,.e-bigger .e-float-input input[readonly]~label.e-label-top.e-float-text,.e-bigger .e-float-input input[disabled]~label.e-label-top.e-float-text,.e-bigger .e-float-input input label.e-float-text.e-label-top,.e-float-input.e-control-wrapper.e-bigger input:focus~label.e-float-text,.e-float-input.e-control-wrapper.e-bigger input:valid~label.e-float-text,.e-float-input.e-control-wrapper.e-bigger input~label.e-label-top.e-float-text,.e-float-input.e-control-wrapper.e-bigger input[readonly]~label.e-label-top.e-float-text,.e-float-input.e-control-wrapper.e-bigger input[disabled]~label.e-label-top.e-float-text,.e-float-input.e-control-wrapper.e-bigger input label.e-float-text.e-label-top,.e-bigger .e-float-input.e-control-wrapper input:focus~label.e-float-text,.e-bigger .e-float-input.e-control-wrapper input:valid~label.e-float-text,.e-bigger .e-float-input.e-control-wrapper input~label.e-label-top.e-float-text,.e-bigger .e-float-input.e-control-wrapper input[readonly]~label.e-label-top.e-float-text,.e-bigger .e-float-input.e-control-wrapper input[disabled]~label.e-label-top.e-float-text,.e-bigger .e-float-input.e-control-wrapper input label.e-float-text.e-label-top,.e-float-input.e-bigger.e-input-focus input~label.e-float-text,.e-bigger .e-float-input.e-input-focus input~label.e-float-text,.e-float-input.e-control-wrapper.e-bigger.e-input-focus input~label.e-float-text,.e-bigger .e-float-input.e-control-wrapper.e-input-focus input~label.e-float-text{transform:translate3d(0,-6px,0) scale(.86)}.e-float-input.e-bigger.e-small input:focus~label.e-float-text,.e-float-input.e-bigger.e-small input:valid~label.e-float-text,.e-float-input.e-bigger.e-small input~label.e-label-top.e-float-text,.e-float-input.e-bigger.e-small input[readonly]~label.e-label-top.e-float-text,.e-float-input.e-bigger.e-small input[disabled]~label.e-label-top.e-float-text,.e-float-input.e-bigger.e-small input label.e-float-text.e-label-top,.e-bigger .e-float-input.e-small input:focus~label.e-float-text,.e-bigger .e-float-input.e-small input:valid~label.e-float-text,.e-bigger .e-float-input.e-small input~label.e-label-top.e-float-text,.e-bigger .e-float-input.e-small input[readonly]~label.e-label-top.e-float-text,.e-bigger .e-float-input.e-small input[disabled]~label.e-label-top.e-float-text,.e-bigger .e-float-input.e-small input label.e-float-text.e-label-top,.e-small .e-float-input.e-bigger input:focus~label.e-float-text,.e-small .e-float-input.e-bigger input:valid~label.e-float-text,.e-small .e-float-input.e-bigger input~label.e-label-top.e-float-text,.e-small .e-float-input.e-bigger input[readonly]~label.e-label-top.e-float-text,.e-small .e-float-input.e-bigger input[disabled]~label.e-label-top.e-float-text,.e-small .e-float-input.e-bigger input label.e-float-text.e-label-top,.e-float-input.e-control-wrapper.e-bigger.e-small input:focus~label.e-float-text,.e-float-input.e-control-wrapper.e-bigger.e-small input:valid~label.e-float-text,.e-float-input.e-control-wrapper.e-bigger.e-small input~label.e-label-top.e-float-text,.e-float-input.e-control-wrapper.e-bigger.e-small input[readonly]~label.e-label-top.e-float-text,.e-float-input.e-control-wrapper.e-bigger.e-small input[disabled]~label.e-label-top.e-float-text,.e-float-input.e-control-wrapper.e-bigger.e-small input label.e-float-text.e-label-top,.e-bigger .e-float-input.e-control-wrapper.e-small input:focus~label.e-float-text,.e-bigger .e-float-input.e-control-wrapper.e-small input:valid~label.e-float-text,.e-bigger .e-float-input.e-control-wrapper.e-small input~label.e-label-top.e-float-text,.e-bigger .e-float-input.e-control-wrapper.e-small input[readonly]~label.e-label-top.e-float-text,.e-bigger .e-float-input.e-control-wrapper.e-small input[disabled]~label.e-label-top.e-float-text,.e-bigger .e-float-input.e-control-wrapper.e-small input label.e-float-text.e-label-top,.e-small .e-float-input.e-control-wrapper.e-bigger input:focus~label.e-float-text,.e-small .e-float-input.e-control-wrapper.e-bigger input:valid~label.e-float-text,.e-small .e-float-input.e-control-wrapper.e-bigger input~label.e-label-top.e-float-text,.e-small .e-float-input.e-control-wrapper.e-bigger input[readonly]~label.e-label-top.e-float-text,.e-small .e-float-input.e-control-wrapper.e-bigger input[disabled]~label.e-label-top.e-float-text,.e-small .e-float-input.e-control-wrapper.e-bigger input label.e-float-text.e-label-top,.e-float-input.e-bigger.e-small.e-input-focus input~label.e-float-text,.e-bigger .e-float-input.e-small.e-input-focus input-group-animation~label.e-float-text,.e-small .e-float-input.e-bigger.e-input-focus input~label.e-float-text,.e-float-input.e-control-wrapper.e-bigger.e-small.e-input-focus input~label.e-float-text,.e-bigger .e-float-input.e-control-wrapper.e-small.e-input-focus input~label.e-float-text,.e-small .e-float-input.e-control-wrapper.e-bigger.e-input-focus input~label.e-float-text{transform:translate3d(0,-6px,0) scale(.92)}.e-float-input.e-bigger input:focus~label.e-float-text,.e-float-input.e-bigger input:valid~label.e-float-text,.e-float-input.e-bigger input~label.e-label-top.e-float-text,.e-float-input.e-bigger input[readonly]~label.e-label-top.e-float-text,.e-float-input.e-bigger input[disabled]~label.e-label-top.e-float-text,.e-bigger .e-float-input input:focus~label.e-float-text,.e-bigger .e-float-input input:valid~label.e-float-text,.e-bigger .e-float-input input~label.e-label-top.e-float-text,.e-bigger .e-float-input input[readonly]~label.e-label-top.e-float-text,.e-bigger .e-float-input input[disabled]~label.e-label-top.e-float-text,.e-float-input.e-control-wrapper.e-bigger input:focus~label.e-float-text,.e-float-input.e-control-wrapper.e-bigger input:valid~label.e-float-text,.e-float-input.e-control-wrapper.e-bigger input~label.e-label-top.e-float-text,.e-float-input.e-control-wrapper.e-bigger input[readonly]~label.e-label-top.e-float-text,.e-float-input.e-control-wrapper.e-bigger input[disabled]~label.e-label-top.e-float-text,.e-bigger .e-float-input.e-control-wrapper input:focus~label.e-float-text,.e-bigger .e-float-input.e-control-wrapper input:valid~label.e-float-text,.e-bigger .e-float-input.e-control-wrapper input~label.e-label-top.e-float-text,.e-bigger .e-float-input.e-control-wrapper input[readonly]~label.e-label-top.e-float-text,.e-bigger .e-float-input.e-control-wrapper input[disabled]~label.e-label-top.e-float-text,.e-float-input.e-bigger.e-input-focus input~label.e-float-text,.e-bigger .e-float-input.e-input-focus input~label.e-float-text,.e-float-input.e-control-wrapper.e-bigger.e-input-focus input~label.e-float-text,.e-bigger .e-float-input.e-control-wrapper.e-input-focus input~label.e-float-text{font-size:14px;top:-9px}.e-float-input.e-bigger .e-input-in-wrap input:focus~label.e-float-text,.e-float-input.e-bigger .e-input-in-wrap input:valid~label.e-float-text,.e-float-input.e-bigger .e-input-in-wrap input~label.e-label-top.e-float-text,.e-float-input.e-bigger .e-input-in-wrap input[readonly]~label.e-label-top.e-float-text,.e-float-input.e-bigger .e-input-in-wrap input[disabled]~label.e-label-top.e-float-text,.e-bigger .e-float-input .e-input-in-wrap input:focus~label.e-float-text,.e-bigger .e-float-input .e-input-in-wrap input:valid~label.e-float-text,.e-bigger .e-float-input .e-input-in-wrap input~label.e-label-top.e-float-text,.e-bigger .e-float-input .e-input-in-wrap input[readonly]~label.e-label-top.e-float-text,.e-bigger .e-float-input .e-input-in-wrap input[disabled]~label.e-label-top.e-float-text,.e-float-input.e-control-wrapper.e-bigger .e-input-in-wrap input:focus~label.e-float-text,.e-float-input.e-control-wrapper.e-bigger .e-input-in-wrap input:valid~label.e-float-text,.e-float-input.e-control-wrapper.e-bigger .e-input-in-wrap input~label.e-label-top.e-float-text,.e-float-input.e-control-wrapper.e-bigger .e-input-in-wrap input[readonly]~label.e-label-top.e-float-text,.e-float-input.e-control-wrapper.e-bigger .e-input-in-wrap input[disabled]~label.e-label-top.e-float-text,.e-bigger .e-float-input.e-control-wrapper .e-input-in-wrap input:focus~label.e-float-text,.e-bigger .e-float-input.e-control-wrapper .e-input-in-wrap input:valid~label.e-float-text,.e-bigger .e-float-input.e-control-wrapper .e-input-in-wrap input~label.e-label-top.e-float-text,.e-bigger .e-float-input.e-control-wrapper .e-input-in-wrap input[readonly]~label.e-label-top.e-float-text,.e-bigger .e-float-input.e-control-wrapper .e-input-in-wrap input[disabled]~label.e-label-top.e-float-text{top:-7px}.e-float-input.e-small.e-bigger input:focus~label.e-float-text,.e-float-input.e-small.e-bigger input:valid~label.e-float-text,.e-float-input.e-small.e-bigger input~label.e-label-top.e-float-text,.e-float-input.e-small.e-bigger input[readonly]~label.e-float-text,.e-float-input.e-small.e-bigger input[disabled]~label.e-float-text,.e-bigger .e-float-input.e-small input:focus~label.e-float-text,.e-bigger .e-float-input.e-small input:valid~label.e-float-text,.e-bigger .e-float-input.e-small input~label.e-label-top.e-float-text,.e-bigger .e-float-input.e-small input[readonly]~label.e-float-text,.e-bigger .e-float-input.e-small input[disabled]~label.e-float-text,.e-bigger.e-small .e-float-input.e-control-wrapper input:focus~label.e-float-text,.e-bigger.e-small .e-float-input.e-control-wrapper input:valid~label.e-float-text,.e-bigger.e-small .e-float-input.e-control-wrapper input~label.e-label-top.e-float-text,.e-bigger.e-small .e-float-input.e-control-wrapper input[readonly]~label.e-float-text,.e-bigger.e-small .e-float-input.e-control-wrapper input[disabled]~label.e-float-text,.e-float-input.e-control-wrapper.e-small.e-bigger input:focus~label.e-float-text,.e-float-input.e-control-wrapper.e-small.e-bigger input:valid~label.e-float-text,.e-float-input.e-control-wrapper.e-small.e-bigger input~label.e-label-top.e-float-text,.e-float-input.e-control-wrapper.e-small.e-bigger input[readonly]~label.e-float-text,.e-float-input.e-control-wrapper.e-small.e-bigger input[disabled]~label.e-float-text,.e-bigger .e-float-input.e-control-wrapper.e-small input:focus~label.e-float-text,.e-bigger .e-float-input.e-control-wrapper.e-small input:valid~label.e-float-text,.e-bigger .e-float-input.e-control-wrapper.e-small input~label.e-label-top.e-float-text,.e-bigger .e-float-input.e-control-wrapper.e-small input[readonly]~label.e-float-text,.e-bigger .e-float-input.e-control-wrapper.e-small input[disabled]~label.e-float-text,.e-float-input.e-small.e-bigger.e-input-focus input~label.e-float-text,.e-bigger .e-float-input.e-small.e-input-focus input~label.e-float-text,.e-float-input.e-control-wrapper.e-small.e-bigger.e-input-focus input~label.e-float-text,.e-bigger .e-float-input.e-control-wrapper.e-small.e-input-focus input~label.e-float-text{font-size:13px;top:-7px}.e-float-input.e-small.e-bigger .e-input-in-wrap input:focus~label.e-float-text,.e-float-input.e-small.e-bigger .e-input-in-wrap input:valid~label.e-float-text,.e-float-input.e-small.e-bigger .e-input-in-wrap input~label.e-label-top.e-float-text,.e-float-input.e-small.e-bigger .e-input-in-wrap input[readonly]~label.e-float-text,.e-float-input.e-small.e-bigger .e-input-in-wrap input[disabled]~label.e-float-text,.e-bigger .e-float-input.e-small .e-input-in-wrap input:focus~label.e-float-text,.e-bigger .e-float-input.e-small .e-input-in-wrap input:valid~label.e-float-text,.e-bigger .e-float-input.e-small .e-input-in-wrap input~label.e-label-top.e-float-text,.e-bigger .e-float-input.e-small .e-input-in-wrap input[readonly]~label.e-float-text,.e-bigger .e-float-input.e-small .e-input-in-wrap input[disabled]~label.e-float-text,.e-float-input.e-control-wrapper.e-small.e-bigger .e-input-in-wrap input:focus~label.e-float-text,.e-float-input.e-control-wrapper.e-small.e-bigger .e-input-in-wrap input:valid~label.e-float-text,.e-float-input.e-control-wrapper.e-small.e-bigger .e-input-in-wrap input~label.e-label-top.e-float-text,.e-float-input.e-control-wrapper.e-small.e-bigger .e-input-in-wrap input[readonly]~label.e-float-text,.e-float-input.e-control-wrapper.e-small.e-bigger .e-input-in-wrap input[disabled]~label.e-float-text,.e-bigger .e-float-input.e-control-wrapper.e-small .e-input-in-wrap input:focus~label.e-float-text,.e-bigger .e-float-input.e-control-wrapper.e-small .e-input-in-wrap input:valid~label.e-float-text,.e-bigger .e-float-input.e-control-wrapper.e-small .e-input-in-wrap input~label.e-label-top.e-float-text,.e-bigger .e-float-input.e-control-wrapper.e-small .e-input-in-wrap input[readonly]~label.e-float-text,.e-bigger .e-float-input.e-control-wrapper.e-small .e-input-in-wrap input[disabled]~label.e-float-text,.e-float-input.e-small .e-input-in-wrap label.e-float-text,.e-small .e-float-input .e-input-in-wrap label.e-float-text,.e-float-input.e-small:not(.e-input-focus) .e-input-in-wrap input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small .e-float-input:not(.e-input-focus) .e-input-in-wrap input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-float-input.e-control-wrapper.e-small .e-input-in-wrap label.e-float-text,.e-small .e-float-input.e-control-wrapper .e-input-in-wrap label.e-float-text,.e-float-input.e-control-wrapper.e-small:not(.e-input-focus) .e-input-in-wrap input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small .e-float-input.e-control-wrapper:not(.e-input-focus) .e-input-in-wrap input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-float-input.e-small.e-bigger .e-input-in-wrap label.e-float-text,.e-bigger .e-float-input.e-small .e-input-in-wrap label.e-float-text,.e-bigger .e-float-input.e-small:not(.e-input-focus) .e-input-in-wrap input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small .e-float-input.e-bigger:not(.e-input-focus) .e-input-in-wrap input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-float-input.e-bigger.e-small:not(.e-input-focus) .e-input-in-wrap input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger.e-small .e-float-input:not(.e-input-focus) .e-input-in-wrap input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-float-input.e-control-wrapper.e-small.e-bigger .e-input-in-wrap label.e-float-text,.e-bigger .e-float-input.e-control-wrapper.e-small .e-input-in-wrap label.e-float-text,.e-bigger .e-float-input.e-control-wrapper.e-small:not(.e-input-focus) .e-input-in-wrap input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small .e-float-input.e-control-wrapper.e-bigger:not(.e-input-focus) .e-input-in-wrap input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-float-input.e-control-wrapper.e-bigger.e-small:not(.e-input-focus) .e-input-in-wrap input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger.e-small .e-float-input.e-control-wrapper:not(.e-input-focus) .e-input-in-wrap input:not(:focus):valid~label.e-float-text.e-label-bottom{top:-10px}.e-float-input.e-bigger,.e-bigger .e-float-input,.e-float-input.e-control-wrapper.e-bigger,.e-bigger .e-float-input.e-control-wrapper{line-height:1.5;margin-bottom:8px;margin-top:17px;padding-top:0;position:relative;width:100%}.e-float-input.e-small.e-bigger,.e-bigger.e-small .e-float-input.e-small,.e-bigger .e-float-input.e-small,.e-small .e-float-input.e-bigger,.e-float-input.e-control-wrapper.e-small.e-bigger,.e-bigger.e-small .e-float-input.e-control-wrapper.e-small,.e-bigger .e-float-input.e-control-wrapper.e-small,.e-small .e-float-input.e-control-wrapper.e-bigger{line-height:1.4;margin-bottom:4px;margin-top:17px;padding-top:0}.e-input-group.e-bigger,.e-bigger .e-input-group,.e-input-group.e-control-wrapper.e-bigger,.e-bigger .e-input-group.e-control-wrapper{line-height:1.5}.e-input-group.e-small.e-bigger,.e-bigger.e-small .e-input-group.e-small,.e-bigger .e-input-group.e-small,.e-small .e-input-group.e-bigger,.e-input-group.e-control-wrapper.e-small.e-bigger,.e-bigger.e-small .e-input-group.e-control-wrapper.e-small,.e-bigger .e-input-group.e-control-wrapper.e-small,.e-small .e-input-group.e-control-wrapper.e-bigger{line-height:normal}.e-float-input.e-bigger.e-no-float-label,.e-bigger .e-float-input.e-no-float-label,.e-float-input.e-small.e-bigger.e-no-float-label,.e-bigger .e-float-input.e-small.e-no-float-label,.e-small .e-float-input.e-bigger.e-no-float-label,.e-float-input.e-control-wrapper.e-bigger.e-no-float-label,.e-bigger .e-float-input.e-control-wrapper.e-no-float-label,.e-float-input.e-control-wrapper.e-small.e-bigger.e-no-float-label,.e-bigger .e-float-input.e-control-wrapper.e-small.e-no-float-label,.e-small .e-float-input.e-control-wrapper.e-bigger.e-no-float-label{margin-top:0}.e-float-input.e-bigger.e-disabled,.e-bigger .e-float-input.e-disabled,.e-float-input.e-control-wrapper.e-bigger.e-disabled,.e-bigger .e-float-input.e-control-wrapper.e-disabled,.e-float-input.e-input-group.e-bigger.e-disabled,.e-bigger .e-float-input.e-input-group.e-disabled,.e-float-input.e-input-group.e-control-wrapper.e-bigger.e-disabled,.e-bigger .e-float-input.e-input-group.e-control-wrapper.e-disabled,.e-float-input.e-bigger,.e-bigger .e-float-input,.e-float-input.e-control-wrapper.e-bigger,.e-bigger .e-float-input.e-control-wrapper{font-size:14px}.e-float-input.e-bigger input,.e-float-input input.e-bigger,.e-bigger .e-float-input input,.e-float-input.e-control-wrapper.e-bigger input,.e-float-input.e-control-wrapper input.e-bigger,.e-bigger .e-float-input.e-control-wrapper input{font:inherit;line-height:inherit;padding:5px 0}.e-float-input.e-small.e-bigger.e-disabled,.e-small.e-bigger .e-float-input.e-disabled,.e-bigger .e-float-input.e-small.e-disabled,.e-small .e-float-input.e-bigger.e-disabled,.e-float-input.e-control-wrapper.e-small.e-bigger.e-disabled,.e-small.e-bigger .e-float-input.e-control-wrapper.e-disabled,.e-bigger .e-float-input.e-control-wrapper.e-small.e-disabled,.e-small .e-float-input.e-control-wrapper.e-bigger.e-disabled,.e-float-input.e-input-group.e-small.e-bigger.e-disabled,.e-small.e-bigger .e-float-input.e-input-group.e-disabled,.e-bigger .e-float-input.e-input-group.e-small.e-disabled,.e-small .e-float-input.e-input-group.e-bigger.e-disabled,.e-float-input.e-input-group.e-control-wrapper.e-small.e-bigger.e-disabled,.e-small.e-bigger .e-float-input.e-input-group.e-control-wrapper.e-disabled,.e-bigger .e-float-input.e-input-group.e-control-wrapper.e-small.e-disabled,.e-small .e-float-input.e-input-group.e-control-wrapper.e-bigger.e-disabled,.e-float-input.e-small.e-bigger,.e-small.e-bigger .e-float-input,.e-bigger .e-float-input.e-small,.e-small .e-float-input.e-bigger,.e-float-input.e-control-wrapper.e-small.e-bigger,.e-small.e-bigger .e-float-input.e-control-wrapper,.e-bigger .e-float-input.e-control-wrapper.e-small,.e-small .e-float-input.e-control-wrapper.e-bigger{font-size:13px}.e-float-input.e-small.e-bigger input,.e-float-input.e-small input.e-bigger,.e-bigger .e-float-input.e-small input,.e-float-input.e-control-wrapper.e-small.e-bigger input,.e-float-input.e-control-wrapper.e-small input.e-bigger,.e-bigger .e-float-input.e-control-wrapper.e-small input{font:inherit;line-height:inherit;padding:4px 0}.e-bigger .e-float-input.e-outline.e-float-icon-left:not(.e-rtl) .e-input-in-wrap input~label.e-float-text.e-label-top{left:-40px;width:auto}.e-bigger .e-float-input.e-outline.e-float-icon-left.e-rtl .e-input-in-wrap input~label.e-float-text.e-label-top{right:-40px;width:auto}.e-float-input.e-bigger:not(.e-error):not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-float-input.e-bigger.e-control-wrapper:not(.e-error):not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger .e-float-input:not(.e-error):not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-float-input.e-small.e-bigger:not(.e-error):not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger .e-float-input.e-small:not(.e-error):not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-float-input.e-control-wrapper.e-bigger:not(.e-error):not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger .e-float-input.e-control-wrapper:not(.e-error):not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-float-input.e-control-wrapper.e-small.e-bigger:not(.e-error):not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger .e-float-input.e-control-wrapper.e-small:not(.e-error):not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-float-input.e-bigger:not(.e-error) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-float-input.e-bigger.e-control-wrapper:not(.e-error) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger .e-float-input:not(.e-error) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-float-input.e-small.e-bigger:not(.e-error) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger .e-float-input.e-small:not(.e-error) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-float-input.e-control-wrapper.e-bigger:not(.e-error) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger .e-float-input.e-control-wrapper:not(.e-error) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-float-input.e-control-wrapper.e-small.e-bigger:not(.e-error) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger .e-float-input.e-control-wrapper.e-small:not(.e-error) textarea:not(:focus):valid~label.e-float-text.e-label-bottom{font-weight:400}.e-float-input.e-rtl.e-bigger:not(.e-input-focus) label.e-float-text.e-label-bottom,.e-float-input.e-rtl.e-control-wrapper.e-bigger:not(.e-input-focus) label.e-float-text.e-label-bottom,.e-rtl .e-float-input.e-bigger:not(.e-input-focus) label.e-float-text.e-label-bottom,.e-rtl .e-float-input.e-control-wrapper.e-bigger:not(.e-input-focus) label.e-float-text.e-label-bottom,.e-bigger .e-float-input.e-rtl:not(.e-input-focus) label.e-float-text.e-label-bottom,.e-bigger .e-float-input.e-rtl.e-control-wrapper:not(.e-input-focus) label.e-float-text.e-label-bottom,.e-bigger.e-rtl .e-float-input:not(.e-input-focus) label.e-float-text.e-label-bottom,.e-bigger.e-rtl .e-float-input.e-control-wrapper:not(.e-input-focus) label.e-float-text.e-label-bottom,.e-float-input.e-bigger.e-rtl input:not(:focus):not(:valid) label.e-float-text,.e-float-input.e-rtl.e-bigger input:not(:focus):not(:valid) label.e-float-text.e-label-bottom,.e-rtl .e-float-input.e-bigger input:not(:focus):not(:valid) label.e-float-text,.e-rtl .e-float-input.e-bigger input:not(:focus):not(:valid) label.e-float-text.e-label-bottom,.e-bigger .e-float-input.e-rtl input:not(:focus):not(:valid) label.e-float-text,.e-bigger .e-float-input.e-rtl input:not(:focus):not(:valid) label.e-float-text.e-label-bottom,.e-bigger.e-rtl .e-float-input input:not(:focus):not(:valid) label.e-float-text,.e-bigger.e-rtl .e-float-input input:not(:focus):not(:valid) label.e-float-text.e-label-bottom,.e-float-input.e-control-wrapper.e-bigger.e-rtl input:not(:focus):not(:valid) label.e-float-text,.e-float-input.e-control-wrapper.e-rtl.e-bigger input:not(:focus):not(:valid) label.e-float-text.e-label-bottom,.e-rtl .e-float-input.e-control-wrapper.e-bigger input:not(:focus):not(:valid) label.e-float-text,.e-rtl .e-float-input.e-control-wrapper.e-bigger input:not(:focus):not(:valid) label.e-float-text.e-label-bottom,.e-bigger .e-float-input.e-control-wrapper.e-rtl input:not(:focus):not(:valid) label.e-float-text,.e-bigger .e-float-input.e-control-wrapper.e-rtl input:not(:focus):not(:valid) label.e-float-text.e-label-bottom,.e-bigger.e-rtl .e-float-input.e-control-wrapper input:not(:focus):not(:valid) label.e-float-text,.e-bigger.e-rtl .e-float-input.e-control-wrapper input:not(:focus):not(:valid) label.e-float-text.e-label-bottom,.e-float-input.e-rtl.e-bigger.e-small:not(.e-input-focus) label.e-float-text.e-label-bottom,.e-float-input.e-rtl.e-control-wrapper.e-bigger.e-small:not(.e-input-focus) label.e-float-text.e-label-bottom,.e-rtl .e-float-input.e-bigger.e-small:not(.e-input-focus) label.e-float-text.e-label-bottom,.e-rtl .e-float-input.e-control-wrapper.e-bigger.e-small:not(.e-input-focus) label.e-float-text.e-label-bottom,.e-bigger.e-small .e-float-input.e-rtl:not(.e-input-focus) label.e-float-text.e-label-bottom,.e-bigger.e-small .e-float-input.e-rtl.e-control-wrapper:not(.e-input-focus) label.e-float-text.e-label-bottom,.e-bigger.e-small.e-rtl .e-float-input:not(.e-input-focus) label.e-float-text.e-label-bottom,.e-bigger.e-small.e-rtl .e-float-input.e-control-wrapper:not(.e-input-focus) label.e-float-text.e-label-bottom,.e-float-input.e-bigger.e-small.e-rtl input:not(:focus):not(:valid) label.e-float-text,.e-float-input.e-rtl.e-bigger.e-small input:not(:focus):not(:valid) label.e-float-text.e-label-bottom,.e-rtl .e-float-input.e-bigger.e-small input:not(:focus):not(:valid) label.e-float-text,.e-rtl .e-float-input.e-bigger.e-small input:not(:focus):not(:valid) label.e-float-text.e-label-bottom,.e-bigger.e-small .e-float-input.e-rtl input:not(:focus):not(:valid) label.e-float-text,.e-bigger.e-small .e-float-input.e-rtl input:not(:focus):not(:valid) label.e-float-text.e-label-bottom,.e-bigger.e-small.e-rtl .e-float-input input:not(:focus):not(:valid) label.e-float-text,.e-bigger.e-small.e-rtl .e-float-input input:not(:focus):not(:valid) label.e-float-text.e-label-bottom,.e-float-input.e-control-wrapper.e-bigger.e-small.e-rtl input:not(:focus):not(:valid) label.e-float-text,.e-float-input.e-control-wrapper.e-rtl.e-bigger.e-small input:not(:focus):not(:valid) label.e-float-text.e-label-bottom,.e-rtl .e-float-input.e-control-wrapper.e-bigger.e-small input:not(:focus):not(:valid) label.e-float-text,.e-rtl .e-float-input.e-control-wrapper.e-bigger.e-small input:not(:focus):not(:valid) label.e-float-text.e-label-bottom,.e-bigger.e-small .e-float-input.e-control-wrapper.e-rtl input:not(:focus):not(:valid) label.e-float-text,.e-bigger.e-small .e-float-input.e-control-wrapper.e-rtl input:not(:focus):not(:valid) label.e-float-text.e-label-bottom,.e-bigger.e-small.e-rtl .e-float-input.e-control-wrapper input:not(:focus):not(:valid) label.e-float-text,.e-bigger.e-small.e-rtl .e-float-input.e-control-wrapper input:not(:focus):not(:valid) label.e-float-text.e-label-bottom{padding-right:0}.e-input-group.e-bigger .e-input,.e-input-group.e-control-wrapper.e-bigger .e-input,.e-bigger .e-input-group .e-input,.e-bigger .e-input-group.e-control-wrapper .e-input,.e-float-input.e-bigger .e-input,.e-bigger .e-float-input .e-input,.e-float-input.e-control-wrapper.e-bigger .e-input,.e-bigger .e-float-input.e-control-wrapper .e-input{margin-bottom:0}.e-input.e-small.e-bigger,.e-input-group.e-small.e-bigger,.e-input-group.e-control-wrapper.e-small.e-bigger,.e-bigger .e-input.e-small,.e-bigger .e-input-group.e-small,.e-bigger .e-input-group.e-control-wrapper.e-small{line-height:inherit;margin-bottom:4px}.e-input-group.e-bigger .e-input-group-icon,.e-input-group .e-input-group-icon.e-bigger,.e-input-group.e-control-wrapper.e-bigger .e-input-group-icon,.e-input-group.e-control-wrapper .e-input-group-icon.e-bigger,.e-bigger .e-input-group .e-input-group-icon,.e-bigger .e-input-group.e-control-wrapper .e-input-group-icon{margin-bottom:5px;margin-right:8px;margin-top:6px}.e-float-input.e-input-group.e-bigger .e-input-group-icon,.e-float-input.e-input-group .e-input-group-icon.e-bigger,.e-bigger .e-float-input.e-input-group .e-input-group-icon,.e-float-input.e-control-wrapper.e-input-group.e-bigger .e-input-group-icon,.e-float-input.e-control-wrapper.e-input-group .e-input-group-icon.e-bigger,.e-bigger .e-float-input.e-control-wrapper.e-input-group .e-input-group-icon{margin-top:6px}.e-input-group.e-small.e-bigger .e-input-group-icon,.e-input-group.e-small .e-input-group-icon.e-bigger,.e-input-group.e-control-wrapper.e-small.e-bigger .e-input-group-icon,.e-input-group.e-control-wrapper.e-small .e-input-group-icon.e-bigger,.e-small .e-bigger.e-input-group .e-input-group-icon,.e-small .e-bigger.e-input-group.e-control-wrapper .e-input-group-icon,.e-bigger .e-input-group.e-small .e-input-group-icon,.e-bigger .e-input-group.e-control-wrapper.e-small .e-input-group-icon{margin-bottom:4px;margin-right:4px;margin-top:4px}.e-float-input.e-input-group.e-small.e-bigger .e-input-group-icon,.e-float-input.e-input-group.e-small .e-input-group-icon.e-bigger,.e-bigger .e-float-input.e-input-group.e-small .e-input-group-icon,.e-float-input.e-control-wrapper.e-input-group.e-small.e-bigger .e-input-group-icon,.e-float-input.e-control-wrapper.e-input-group.e-small .e-input-group-icon.e-bigger,.e-bigger .e-float-input.e-control-wrapper.e-input-group.e-small .e-input-group-icon{margin-top:4px}.e-input-group.e-bigger .e-input-group-icon:last-child,.e-input-group .e-input-group-icon.e-bigger:last-child,.e-bigger .e-input-group .e-input-group-icon:last-child,.e-input-group.e-small.e-bigger .e-input-group-icon:last-child,.e-input-group.e-small .e-input-group-icon.e-bigger:last-child,.e-input-group.e-control-wrapper.e-bigger .e-input-group-icon:last-child,.e-input-group.e-control-wrapper .e-input-group-icon.e-bigger:last-child,.e-input-group.e-control-wrapper.e-small.e-bigger .e-input-group-icon:last-child,.e-input-group.e-control-wrapper.e-small .e-input-group-icon.e-bigger:last-child,.e-bigger .e-input-group.e-control-wrapper.e-small .e-input-group-icon:last-child,.e-bigger .e-input-group.e-small .e-input-group-icon:last-child{margin-right:0}.e-bigger input.e-input::-webkit-input-placeholder,input.e-bigger.e-input::-webkit-input-placeholder,.e-bigger input.e-input:-moz-placeholder,input.e-bigger.e-input:-moz-placeholder,.e-bigger input.e-input:-ms-input-placeholder,input.e-bigger.e-input:-ms-input-placeholder,.e-bigger input.e-input::-moz-placeholder,input.e-bigger.e-input::-moz-placeholder,.e-bigger textarea.e-input::-webkit-input-placeholder,textarea.e-bigger.e-input::-webkit-input-placeholder,.e-bigger textarea.e-input:-moz-placeholder,textarea.e-bigger.e-input:-moz-placeholder,.e-bigger textarea.e-input:-ms-input-placeholder,textarea.e-bigger.e-input:-ms-input-placeholder,.e-bigger textarea.e-input::-moz-placeholder,textarea.e-bigger.e-input::-moz-placeholder,.e-bigger textarea.e-input::-webkit-textarea-placeholder,textarea.e-bigger.e-input::-webkit-textarea-placeholder,.e-bigger textarea.e-input:-ms-textarea-placeholder,textarea.e-bigger.e-input:-ms-textarea-placeholder{font-size:14px;font-style:normal}.e-bigger input.e-small.e-input::-webkit-input-placeholder,.e-small input.e-bigger.e-input::-webkit-input-placeholder,.e-bigger input.e-small.e-input:-moz-placeholder,.e-small input.e-bigger.e-input:-moz-placeholder,.e-bigger input.e-small.e-input:-ms-input-placeholder,.e-small input.e-bigger.e-input:-ms-input-placeholder,.e-bigger input.e-small.e-input::-moz-placeholder,.e-small input.e-bigger.e-input::-moz-placeholder,.e-bigger textarea.e-small.e-input::-webkit-input-placeholder,.e-small textarea.e-bigger.e-input::-webkit-input-placeholder,.e-bigger textarea.e-small.e-input:-moz-placeholder,.e-small textarea.e-bigger.e-input:-moz-placeholder,.e-bigger intextareaput.e-small.e-input:-ms-input-placeholder,.e-small textarea.e-bigger.e-input:-ms-input-placeholder,.e-bigger textarea.e-small.e-input::-moz-placeholder,.e-small textarea.e-bigger.e-input::-moz-placeholder,.e-bigger textarea.e-small.e-input::-webkit-textarea-placeholder,.e-small textarea.e-bigger.e-input::-webkit-textarea-placeholder,.e-bigger textarea.e-small.e-input:-ms-input-placeholder{font-size:13px;font-style:normal}input.e-input.e-bigger,.e-bigger input.e-input,.e-input-group.e-bigger input,.e-input-group.e-bigger input.e-input,.e-input-group.e-control-wrapper.e-bigger input,.e-input-group.e-control-wrapper.e-bigger input.e-input,.e-bigger .e-input-group input,.e-bigger .e-input-group input.e-input,.e-bigger .e-input-group.e-control-wrapper input,.e-bigger .e-input-group.e-control-wrapper input.e-input,.e-float-input.e-bigger input,.e-float-input.e-bigger input.e-input,.e-bigger .e-float-input input,.e-bigger .e-float-input input.e-input,.e-float-input.e-control-wrapper.e-bigger input,.e-float-input.e-control-wrapper.e-bigger input.e-input,.e-bigger .e-float-input.e-control-wrapper input,.e-bigger .e-float-input.e-control-wrapper input.e-input{box-sizing:content-box;content:""}.e-float-input.e-bigger:not(.e-input-group) input,.e-float-input.e-bigger:not(.e-input-group) input.e-input,.e-bigger .e-float-input:not(.e-input-group) input,.e-bigger .e-float-input:not(.e-input-group) input.e-input,.e-float-input.e-control-wrapper.e-bigger:not(.e-input-group) input,.e-float-input.e-control-wrapper.e-bigger:not(.e-input-group) input.e-input,.e-bigger .e-float-input.e-control-wrapper:not(.e-input-group) input,.e-bigger .e-float-input.e-control-wrapper:not(.e-input-group) input.e-input{box-sizing:content-box;content:""}input.e-input.e-small.e-bigger,.e-input-group.e-bigger.e-small input,.e-input-group.e-bigger.e-small input.e-input,.e-bigger.e-small .e-input-group input,.e-bigger.e-small .e-input-group input.e-input,.e-input-group.e-control-wrapper.e-bigger.e-small input,.e-input-group.e-control-wrapper.e-bigger.e-small input.e-input,.e-bigger.e-small .e-input-group.e-control-wrapper input,.e-bigger.e-small .e-input-group.e-control-wrapper input.e-input,.e-float-input.e-bigger.e-small input,.e-float-input.e-bigger.e-small input.e-input,.e-bigger.e-small .e-float-input input,.e-bigger.e-small .e-float-input input.e-input,.e-float-input.e-control-wrapper.e-bigger.e-small input,.e-float-input.e-control-wrapper.e-bigger.e-small input.e-input,.e-bigger.e-small .e-float-input.e-control-wrapper input,.e-bigger.e-small .e-float-input.e-control-wrapper input.e-input{box-sizing:content-box;content:""}.e-float-input.e-bigger.e-small:not(.e-input-group) input,.e-float-input.e-bigger.e-small:not(.e-input-group) input.e-input,.e-bigger.e-small .e-float-input:not(.e-input-group) input,.e-bigger.e-small .e-float-input:not(.e-input-group) input.e-input,.e-float-input.e-control-wrapper.e-bigger.e-small:not(.e-input-group) input,.e-float-input.e-control-wrapper.e-bigger.e-small:not(.e-input-group) input.e-input,.e-bigger.e-small .e-float-input.e-control-wrapper:not(.e-input-group) input,.e-bigger.e-small .e-float-input.e-control-wrapper:not(.e-input-group) input.e-input{box-sizing:content-box;content:""}.e-input-group textarea.e-input.e-bigger,.e-input-group.e-control-wrapper textarea.e-input.e-bigger,textarea.e-input.e-bigger,.e-input-group.e-bigger textarea,.e-input-group.e-bigger textarea.e-input,.e-bigger .e-input-group textarea,.e-bigger .e-input-group textarea.e-input,.e-input-group.e-control-wrapper.e-bigger textarea,.e-input-group.e-control-wrapper.e-bigger textarea.e-input,.e-bigger .e-input-group.e-control-wrapper textarea,.e-bigger .e-input-group.e-control-wrapper textarea.e-input,.e-float-input.e-bigger textarea,.e-float-input.e-bigger textarea.e-input,.e-bigger .e-float-input textarea,.e-bigger .e-float-input textarea.e-input,.e-float-input.e-control-wrapper.e-bigger textarea,.e-float-input.e-control-wrapper.e-bigger textarea.e-input,.e-bigger .e-float-input.e-control-wrapper textarea,.e-bigger .e-float-input.e-control-wrapper textarea.e-input,textarea.e-input.e-small.e-bigger,.e-input-group.e-bigger.e-small textarea,.e-input-group.e-bigger.e-small textarea.e-input,.e-bigger.e-small .e-input-group textarea,.e-bigger.e-small .e-input-group textarea.e-input,.e-input-group.e-control-wrapper.e-bigger.e-small textarea,.e-input-group.e-control-wrapper.e-bigger.e-small textarea.e-input,.e-bigger.e-small .e-input-group.e-control-wrapper textarea,.e-bigger.e-small .e-input-group.e-control-wrapper textarea.e-input,.e-float-input.e-bigger.e-small textarea,.e-float-input.e-bigger.e-small textarea.e-input,.e-bigger.e-small .e-float-input textarea,.e-bigger.e-small .e-float-input textarea.e-input,.e-float-input.e-control-wrapper.e-bigger.e-small textarea,.e-float-input.e-control-wrapper.e-bigger.e-small textarea.e-input,.e-bigger.e-small .e-float-input.e-control-wrapper textarea,.e-bigger.e-small .e-float-input.e-control-wrapper textarea.e-input{box-sizing:content-box;content:""}input.e-input.e-bigger,.e-input-group input.e-input.e-bigger,.e-input-group.e-control-wrapper input.e-input.e-bigger,.e-input-group.e-bigger .e-input,.e-input-group.e-control-wrapper.e-bigger .e-input,.e-bigger input.e-input,.e-bigger .e-input-group .e-input,.e-bigger .e-input-group.e-control-wrapper .e-input,.e-float-input.e-bigger input,.e-float-input input.e-bigger,.e-bigger .e-float-input input,.e-float-input.e-control-wrapper.e-bigger input,.e-float-input.e-control-wrapper input.e-bigger,.e-bigger .e-float-input.e-control-wrapper input{text-indent:0}input.e-input.e-bigger,.e-bigger input.e-input,.e-input-group.e-bigger input.e-input,.e-input-group.e-control-wrapper.e-bigger input.e-input,.e-float-input.e-control-wrapper.e-bigger input,.e-float-input.e-control-wrapper input.e-bigger,.e-float-input.e-bigger input,.e-float-input input.e-bigger,.e-input-group input.e-input.e-bigger,.e-input-group.e-control-wrapper input.e-input.e-bigger,.e-bigger .e-float-input.e-control-wrapper input,.e-bigger .e-float-input input,.e-bigger .e-input-group.e-control-wrapper input.e-input,.e-bigger .e-input-group input.e-input,.e-input-group.e-bigger input.e-input:focus,.e-input-group.e-control-wrapper.e-bigger input.e-input:focus,.e-float-input.e-control-wrapper.e-bigger input:focus,.e-float-input.e-bigger input:focus,.e-bigger .e-input-group input.e-input:focus,.e-bigger .e-input-group.e-control-wrapper input.e-input:focus,.e-bigger .e-float-input.e-control-wrapper input:focus,.e-bigger .e-float-input input:focus,.e-input-group.e-bigger.e-input-focus input.e-input,.e-input-group.e-control-wrapper.e-bigger.e-input-focus input.e-input,.e-bigger .e-input-group.e-input-focus input.e-input,.e-bigger .e-input-group.e-control-wrapper.e-input-focus input.e-input,.e-float-input.e-control-wrapper.e-bigger.e-input-focus input,.e-float-input.e-bigger.e-input-focus input,.e-bigger .e-float-input.e-control-wrapper.e-input-focus input,.e-bigger .e-float-input.e-input-focus input{padding-left:0;text-indent:0}.e-rtl input.e-input.e-bigger,input.e-input.e-bigger.e-rtl,.e-bigger.e-rtl input.e-input,.e-bigger input.e-input.e-rtl,.e-float-input.e-control-wrapper.e-bigger.e-rtl input,.e-float-input.e-bigger.e-rtl input,.e-input-group.e-bigger.e-rtl input.e-input,.e-input-group.e-control-wrapper.e-bigger.e-rtl input.e-input,.e-rtl .e-float-input.e-control-wrapper.e-bigger input,.e-rtl .e-float-input.e-bigger input,.e-rtl .e-input-group.e-bigger input.e-input,.e-rtl .e-input-group.e-control-wrapper.e-bigger input.e-input,.e-float-input.e-control-wrapper.e-rtl input.e-bigger,.e-float-input.e-rtl input.e-bigger,.e-input-group.e-rtl input.e-input.e-bigger,.e-input-group.e-control-wrapper.e-rtl input.e-input.e-bigger,.e-rtl .e-float-input.e-control-wrapper input.e-bigger,.e-rtl .e-float-input input.e-bigger,.e-rtl .e-input-group input.e-input.e-bigger,.e-rtl .e-input-group.e-control-wrapper input.e-input.e-bigger,.e-bigger .e-float-input.e-control-wrapper.e-rtl input,.e-bigger .e-float-input.e-rtl input,.e-bigger .e-input-group.e-rtl input.e-input,.e-bigger .e-input-group.e-control-wrapper.e-rtl input.e-input,.e-bigger.e-rtl .e-float-input.e-control-wrapper input,.e-bigger.e-rtl .e-float-input input,.e-bigger.e-rtl .e-input-group input.e-input,.e-bigger.e-rtl .e-input-group.e-control-wrapper input.e-input,.e-bigger.e-rtl .e-input-group input.e-input:focus,.e-bigger.e-rtl .e-input-group.e-control-wrapper input.e-input:focus,.e-bigger.e-rtl .e-float-input.e-control-wrapper input:focus,.e-bigger.e-rtl .e-float-input input:focus,.e-bigger .e-input-group.e-rtl input.e-input:focus,.e-bigger .e-input-group.e-control-wrapper.e-rtl input.e-input:focus,.e-bigger .e-float-input.e-rtl input:focus,.e-bigger .e-float-input.e-control-wrapper.e-rtl input:focus,.e-bigger.e-rtl .e-input-group.e-input-focus input.e-input,.e-bigger.e-rtl .e-input-group.e-control-wrapper.e-input-focus input.e-input,.e-bigger .e-input-group.e-rtl.e-input-focus input.e-input,.e-bigger .e-input-group.e-control-wrapper.e-rtl.e-input-focus input.e-input,.e-bigger.e-rtl .e-float-input.e-control-wrapper.e-input-focus input,.e-bigger.e-rtl .e-float-input.e-input-focus input,.e-bigger .e-float-input.e-rtl.e-input-focus input,.e-bigger .e-float-input.e-control-wrapper.e-rtl.e-input-focus input{padding-left:0;padding-right:0;text-indent:0}textarea.e-input.e-bigger,.e-bigger textarea.e-input,.e-input-group.e-bigger textarea.e-input,.e-input-group.e-control-wrapper.e-bigger textarea.e-input,.e-float-input.e-control-wrapper.e-bigger textarea,.e-float-input.e-control-wrapper textarea.e-bigger,.e-float-input.e-bigger textarea,.e-float-input textarea.e-bigger,.e-input-group textarea.e-input.e-bigger,.e-input-group.e-control-wrapper textarea.e-input.e-bigger,.e-bigger .e-float-input.e-control-wrapper textarea,.e-bigger .e-float-input textarea,.e-bigger .e-input-group textarea.e-input,.e-bigger .e-input-group.e-control-wrapper textarea.e-input,.e-input-group.e-bigger textarea.e-input:focus,.e-input-group.e-control-wrapper.e-bigger textarea.e-input:focus,.e-float-input.e-control-wrapper.e-bigger textarea:focus,.e-float-input.e-bigger textarea:focus,.e-bigger .e-input-group textarea.e-input:focus,.e-bigger .e-input-group.e-control-wrapper textarea.e-input:focus,.e-bigger .e-float-input.e-control-wrapper textarea:focus,.e-bigger .e-float-input textarea:focus{padding-left:0;text-indent:0}.e-rtl textarea.e-input.e-bigger,textarea.e-input.e-bigger.e-rtl,.e-bigger.e-rtl textarea.e-input,.e-bigger textarea.e-input.e-rtl,.e-float-input.e-control-wrapper:not(.e-outline).e-bigger.e-rtl textarea,.e-float-input:not(.e-outline).e-bigger.e-rtl textarea,.e-input-group:not(.e-outline).e-bigger.e-rtl textarea.e-input,.e-input-group:not(.e-outline).e-control-wrapper.e-bigger.e-rtl textarea.e-input,.e-rtl .e-float-input:not(.e-outline).e-control-wrapper.e-bigger textarea,.e-rtl .e-float-input:not(.e-outline).e-bigger textarea,.e-rtl .e-input-group:not(.e-outline).e-bigger textarea.e-input,.e-rtl .e-input-group:not(.e-outline).e-control-wrapper.e-bigger textarea.e-input,.e-float-input:not(.e-outline).e-rtl textarea.e-bigger,.e-float-input:not(.e-outline).e-control-wrapper.e-rtl textarea.e-bigger,.e-input-group:not(.e-outline).e-rtl textarea.e-input.e-bigger,.e-input-group:not(.e-outline).e-control-wrapper.e-rtl textarea.e-input.e-bigger,.e-rtl .e-float-input:not(.e-outline) textarea.e-bigger,.e-rtl .e-float-input:not(.e-outline).e-control-wrapper textarea.e-bigger,.e-rtl .e-input-group:not(.e-outline) textarea.e-input.e-bigger,.e-rtl .e-input-group:not(.e-outline).e-control-wrapper textarea.e-input.e-bigger,.e-bigger .e-float-input:not(.e-outline).e-rtl textarea,.e-bigger .e-float-input:not(.e-outline).e-control-wrapper.e-rtl textarea,.e-bigger .e-input-group:not(.e-outline).e-rtl textarea.e-input,.e-bigger .e-input-group:not(.e-outline).e-control-wrapper.e-rtl textarea.e-input,.e-bigger.e-rtl .e-float-input:not(.e-outline) textarea,.e-bigger.e-rtl .e-float-input:not(.e-outline).e-control-wrapper textarea,.e-bigger.e-rtl .e-input-group:not(.e-outline) textarea.e-input,.e-bigger.e-rtl .e-input-group:not(.e-outline).e-control-wrapper textarea.e-input,.e-bigger.e-rtl .e-input-group:not(.e-outline) textarea.e-input:focus,.e-bigger.e-rtl .e-input-group:not(.e-outline).e-control-wrapper textarea.e-input:focus,.e-bigger.e-rtl .e-float-input:not(.e-outline) textarea:focus,.e-bigger.e-rtl .e-float-input:not(.e-outline).e-control-wrapper textarea:focus,.e-bigger .e-input-group:not(.e-outline).e-rtl textarea.e-input:focus,.e-bigger .e-input-group:not(.e-outline).e-control-wrapper.e-rtl textarea.e-input:focus,.e-bigger .e-float-input:not(.e-outline).e-rtl textarea:focus,.e-bigger .e-float-input:not(.e-outline).e-control-wrapper.e-rtl textarea:focus{padding-right:0;text-indent:0}input.e-input.e-bigger.e-small,.e-bigger input.e-input.e-small,.e-input-group.e-small.e-bigger input.e-input,.e-input-group.e-control-wrapper.e-small.e-bigger input.e-input,.e-input-group.e-small input.e-input.e-bigger,.e-input-group.e-control-wrapper.e-small input.e-input.e-bigger,.e-bigger .e-input-group.e-small input.e-input,.e-bigger .e-input-group.e-control-wrapper.e-small input.e-input,.e-float-input.e-small.e-bigger input,.e-float-input.e-small input.e-bigger,.e-bigger .e-float-input.e-small input,.e-float-input.e-control-wrapper.e-small.e-bigger input,.e-float-input.e-control-wrapper.e-small input.e-bigger,.e-bigger .e-float-input.e-control-wrapper.e-small input,.e-bigger .e-input-group.e-small input.e-input:focus,.e-bigger .e-input-group.e-control-wrapper.e-small input.e-input:focus,.e-bigger .e-float-input.e-control-wrapper.e-small input:focus,.e-bigger .e-float-input.e-small input:focus,.e-small .e-input-group.e-bigger input.e-input:focus,.e-small .e-input-group.e-control-wrapper.e-bigger input.e-input:focus,.e-small .e-float-input.e-control-wrapper.e-bigger input:focus,.e-small .e-float-input.e-bigger input:focus,.e-input-group.e-bigger.e-small input.e-input:focus,.e-input-group.e-control-wrapper.e-bigger.e-small input.e-input:focus,.e-float-input.e-control-wrapper.e-bigger.e-small input:focus,.e-float-input.e-bigger.e-small input:focus,.e-bigger .e-input-group.e-small.e-input-focus input.e-input,.e-bigger .e-input-group.e-control-wrapper.e-small.e-input-focus input.e-input,.e-small .e-input-group.e-bigger.e-input-focus input.e-input,.e-small .e-input-group.e-control-wrapper.e-bigger.e-input-focus input.e-input,.e-input-group.e-bigger.e-small.e-input-focus input.e-input,.e-input-group.e-control-wrapper.e-bigger.e-small.e-input-focus input.e-input,.e-bigger .e-float-input.e-control-wrapper.e-small.e-input-focus input,.e-bigger .e-float-input.e-small.e-input-focus input,.e-small .e-float-input.e-control-wrapper.e-bigger.e-input-focus input,.e-small .e-float-input.e-bigger.e-input-focus input,.e-float-input.e-control-wrapper.e-bigger.e-small.e-input-focus input,.e-float-input.e-bigger.e-small.e-input-focus input,textarea.e-input.e-bigger.e-small,.e-bigger textarea.e-input.e-small,.e-input-group.e-small.e-bigger textarea.e-input,.e-input-group.e-control-wrapper.e-small.e-bigger textarea.e-input,.e-input-group.e-small textarea.e-input.e-bigger,.e-input-group.e-control-wrapper.e-small textarea.e-input.e-bigger,.e-bigger .e-input-group.e-small textarea.e-input,.e-bigger .e-input-group.e-control-wrapper.e-small textarea.e-input,.e-float-input.e-small.e-bigger textarea,.e-float-input.e-small textarea.e-bigger,.e-bigger .e-float-input.e-small textarea,.e-float-input.e-control-wrapper.e-small.e-bigger textarea,.e-float-input.e-control-wrapper.e-small textarea.e-bigger,.e-bigger .e-float-input.e-control-wrapper.e-small textarea,.e-bigger .e-input-group.e-small textarea.e-input:focus,.e-bigger .e-input-group.e-control-wrapper.e-small textarea.e-input:focus,.e-bigger .e-float-input.e-control-wrapper.e-small textarea:focus,.e-bigger .e-float-input.e-small textarea:focus,.e-small .e-input-group.e-bigger textarea.e-input:focus,.e-small .e-input-group.e-control-wrapper.e-bigger textarea.e-input:focus,.e-small .e-float-input.e-control-wrapper.e-bigger textarea:focus,.e-small .e-float-input.e-bigger textarea:focus,.e-input-group.e-bigger.e-small textarea.e-input:focus,.e-input-group.e-control-wrapper.e-bigger.e-small textarea.e-input:focus,.e-float-input.e-control-wrapper.e-bigger.e-small textarea:focus,.e-float-input.e-bigger.e-small textarea:focus{padding-left:0;text-indent:0}.e-bigger input.e-input.e-small.e-rtl,.e-input-group.e-small.e-bigger.e-rtl input.e-input,.e-input-group.e-control-wrapper.e-small.e-bigger.e-rtl input.e-input,.e-input-group.e-small.e-rtl input.e-input.e-bigger,.e-input-group.e-control-wrapper.e-small.e-rtl input.e-input.e-bigger,.e-bigger .e-input-group.e-small.e-rtl input.e-input,.e-bigger .e-input-group.e-control-wrapper.e-small.e-rtl input.e-input,.e-float-input.e-small.e-bigger.e-rtl input,.e-float-input.e-small.e-rtl input.e-bigger,.e-bigger .e-float-input.e-small.e-rtl input,.e-float-input.e-control-wrapper.e-small.e-bigger.e-rtl input,.e-float-input.e-control-wrapper.e-small.e-rtl input.e-bigger,.e-bigger .e-float-input.e-control-wrapper.e-small.e-rtl input,.e-bigger.e-rtl input.e-input.e-small,.e-rtl .e-input-group.e-small.e-bigger input.e-input,.e-rtl .e-input-group.e-control-wrapper.e-small.e-bigger input.e-input,.e-rtl .e-input-group.e-small input.e-input.e-bigger,.e-rtl .e-input-group.e-control-wrapper.e-small input.e-input.e-bigger,.e-bigger.e-rtl .e-input-group.e-small input.e-input,.e-bigger.e-rtl .e-input-group.e-control-wrapper.e-small input.e-input,.e-rtl .e-float-input.e-control-wrapper.e-small.e-bigger input,.e-rtl .e-float-input.e-control-wrapper.e-small input.e-bigger,.e-bigger.e-rtl .e-float-input.e-control-wrapper.e-small input,.e-rtl .e-float-input.e-small.e-bigger input,.e-rtl .e-float-input.e-small input.e-bigger,.e-bigger.e-rtl .e-float-input.e-small input,.e-bigger .e-input-group.e-small.e-rtl input.e-input:focus,.e-bigger .e-input-group.e-control-wrapper.e-small.e-rtl input.e-input:focus,.e-bigger .e-float-input.e-control-wrapper.e-small.e-rtl input:focus,.e-bigger .e-float-input.e-small.e-rtl input:focus,.e-small .e-input-group.e-bigger.e-rtl input.e-input:focus,.e-small .e-input-group.e-control-wrapper.e-bigger.e-rtl input.e-input:focus,.e-small .e-float-input.e-control-wrapper.e-bigger.e-rtl input:focus,.e-small .e-float-input.e-bigger.e-rtl input:focus,.e-input-group.e-bigger.e-small.e-rtl input.e-input:focus,.e-input-group.e-control-wrapper.e-bigger.e-small.e-rtl input.e-input:focus,.e-float-input.e-control-wrapper.e-bigger.e-small.e-rtl input:focus,.e-float-input.e-bigger.e-small.e-rtl input:focus,.e-bigger.e-rtl .e-input-group.e-small input.e-input:focus,.e-bigger.e-rtl .e-input-group.e-control-wrapper.e-small input.e-input:focus,.e-bigger.e-rtl .e-float-input.e-control-wrapper.e-small input:focus,.e-bigger.e-rtl .e-float-input.e-small input:focus,.e-small.e-rtl .e-input-group.e-bigger input.e-input:focus,.e-small.e-rtl .e-input-group.e-control-wrapper.e-bigger input.e-input:focus,.e-small.e-rtl .e-float-input.e-control-wrapper.e-bigger input:focus,.e-small.e-rtl .e-float-input.e-bigger input:focus,.e-rtl .e-input-group.e-bigger.e-small input.e-input:focus,.e-rtl .e-input-group.e-control-wrapper.e-bigger.e-small input.e-input:focus,.e-rtl .e-float-input.e-control-wrapper.e-bigger.e-small input:focus,.e-rtl .e-float-input.e-bigger.e-small input:focus,.e-bigger .e-float-input.e-control-wrapper.e-small.e-rtl.e-input-focus input,.e-bigger .e-float-input.e-small.e-rtl.e-input-focus input,.e-small .e-float-input.e-control-wrapper.e-bigger.e-rtl.e-input-focus input,.e-small .e-float-input.e-bigger.e-rtl.e-input-focus input,.e-float-input.e-control-wrapper.e-bigger.e-small.e-rtl.e-input-focus input,.e-float-input.e-bigger.e-small.e-rtl.e-input-focus input,.e-bigger.e-rtl .e-float-input.e-control-wrapper.e-small.e-input-focus input,.e-bigger.e-rtl .e-float-input.e-small.e-input-focus input,.e-small.e-rtl .e-float-input.e-control-wrapper.e-bigger.e-input-focus input,.e-small.e-rtl .e-float-input.e-bigger.e-input-focus input,.e-rtl .e-float-input.e-control-wrapper.e-bigger.e-small.e-input-focus input,.e-rtl .e-float-input.e-bigger.e-small.e-input-focus input,.e-bigger .e-input-group.e-small.e-rtl.e-input-focus input.e-input,.e-bigger .e-input-group.e-control-wrapper.e-small.e-rtl.e-input-focus input.e-input,.e-small .e-input-group.e-bigger.e-rtl.e-input-focus input.e-input,.e-small .e-input-group.e-control-wrapper.e-bigger.e-rtl.e-input-focus input.e-input,.e-input-group.e-bigger.e-small.e-rtl.e-input-focus input.e-input,.e-input-group.e-control-wrapper.e-bigger.e-small.e-rtl.e-input-focus input.e-input,.e-bigger.e-rtl .e-input-group.e-small.e-input-focus input.e-input,.e-bigger.e-rtl .e-input-group.e-control-wrapper.e-small.e-input-focus input.e-input,.e-small.e-rtl .e-input-group.e-bigger.e-input-focus input.e-input,.e-small.e-rtl .e-input-group.e-control-wrapper.e-bigger.e-input-focus input.e-input,.e-rtl .e-input-group.e-bigger.e-small.e-input-focus input.e-input,.e-rtl .e-input-group.e-control-wrapper.e-bigger.e-small.e-input-focus input.e-input{padding-left:0;padding-right:0;text-indent:0}.e-bigger textarea.e-input.e-small.e-rtl,.e-input-group:not(.e-outline).e-small.e-bigger.e-rtl textarea.e-input,.e-input-group:not(.e-outline).e-control-wrapper.e-small.e-bigger.e-rtl textarea.e-input,.e-input-group:not(.e-outline).e-small.e-rtl textarea.e-input.e-bigger,.e-input-group:not(.e-outline).e-control-wrapper.e-small.e-rtl textarea.e-input.e-bigger,.e-bigger .e-input-group:not(.e-outline).e-small.e-rtl textarea.e-input,.e-bigger .e-input-group:not(.e-outline).e-control-wrapper.e-small.e-rtl textarea.e-input,.e-float-input:not(.e-outline).e-small.e-bigger.e-rtl textarea,.e-float-input:not(.e-outline).e-small.e-rtl textarea.e-bigger,.e-bigger .e-float-input:not(.e-outline).e-small.e-rtl textarea,.e-float-input:not(.e-outline).e-control-wrapper.e-small.e-bigger.e-rtl textarea,.e-float-input:not(.e-outline).e-control-wrapper.e-small.e-rtl textarea.e-bigger,.e-bigger .e-float-input:not(.e-outline).e-control-wrapper.e-small.e-rtl textarea,.e-bigger.e-rtl textarea.e-input.e-small,.e-rtl .e-input-group:not(.e-outline).e-small.e-bigger textarea.e-input,.e-rtl .e-input-group:not(.e-outline).e-control-wrapper.e-small.e-bigger textarea.e-input,.e-rtl .e-input-group:not(.e-outline).e-small textarea.e-input.e-bigger,.e-rtl .e-input-group:not(.e-outline).e-control-wrapper.e-small textarea.e-input.e-bigger,.e-bigger.e-rtl .e-input-group:not(.e-outline).e-small textarea.e-input,.e-bigger.e-rtl .e-input-group:not(.e-outline).e-control-wrapper.e-small textarea.e-input,.e-rtl .e-float-input:not(.e-outline).e-control-wrapper.e-small.e-bigger textarea,.e-rtl .e-float-input:not(.e-outline).e-small textarea.e-bigger,.e-bigger.e-rtl .e-float-input:not(.e-outline).e-control-wrapper.e-small textarea,.e-bigger.e-rtl .e-float-input:not(.e-outline).e-small textarea,.e-bigger.e-rtl .e-float-input:not(.e-outline).e-small.e-control-wrapper textarea,.e-bigger .e-input-group:not(.e-outline).e-small.e-rtl textarea.e-input:focus,.e-bigger .e-input-group:not(.e-outline).e-control-wrapper.e-small.e-rtl textarea.e-input:focus,.e-bigger .e-float-input:not(.e-outline).e-control-wrapper.e-small.e-rtl textarea:focus,.e-bigger .e-float-input:not(.e-outline).e-small.e-rtl textarea:focus,.e-small .e-input-group:not(.e-outline).e-bigger.e-rtl textarea.e-input:focus,.e-small .e-input-group:not(.e-outline).e-control-wrapper.e-bigger.e-rtl textarea.e-input:focus,.e-small .e-float-input:not(.e-outline).e-control-wrapper.e-bigger.e-rtl textarea:focus,.e-small .e-float-input:not(.e-outline).e-bigger.e-rtl textarea:focus,.e-input-group:not(.e-outline).e-bigger.e-small.e-rtl textarea.e-input:focus,.e-input-group:not(.e-outline).e-control-wrapper.e-bigger.e-small.e-rtl textarea.e-input:focus,.e-float-input:not(.e-outline).e-control-wrapper.e-bigger.e-small.e-rtl textarea:focus,.e-float-input:not(.e-outline).e-bigger.e-small.e-rtl textarea:focus,.e-bigger.e-rtl .e-input-group:not(.e-outline).e-small textarea.e-input:focus,.e-bigger.e-rtl .e-input-group:not(.e-outline).e-control-wrapper.e-small textarea.e-input:focus,.e-bigger.e-rtl .e-float-input:not(.e-outline).e-control-wrapper.e-small textarea:focus,.e-bigger.e-rtl .e-float-input:not(.e-outline).e-small textarea:focus,.e-small.e-rtl .e-input-group:not(.e-outline).e-bigger textarea.e-input:focus,.e-small.e-rtl .e-input-group:not(.e-outline).e-control-wrapper.e-bigger textarea.e-input:focus,.e-small.e-rtl .e-float-input:not(.e-outline).e-control-wrapper.e-bigger textarea:focus,.e-small.e-rtl .e-float-input:not(.e-outline).e-bigger textarea:focus,.e-rtl .e-input-group:not(.e-outline).e-bigger.e-small textarea.e-input:focus,.e-rtl .e-input-group:not(.e-outline).e-control-wrapper.e-bigger.e-small textarea.e-input:focus,.e-rtl .e-float-input:not(.e-outline).e-control-wrapper.e-bigger.e-small textarea:focus,.e-rtl .e-float-input:not(.e-outline).e-bigger.e-small textarea:focus{padding-right:0;text-indent:0}.e-float-input.e-small.e-bigger .e-clear-icon,.e-float-input.e-control-wrapper.e-small.e-bigger .e-clear-icon,.e-input-group.e-small.e-bigger .e-clear-icon,.e-input-group.e-control-wrapper.e-small.e-bigger .e-clear-icon,.e-small .e-input-group.e-bigger input:first-child~.e-clear-icon,.e-small .e-input-group.e-control-wrapper.e-bigger input:first-child~.e-clear-icon,.e-bigger .e-input-group.e-small input:first-child~.e-clear-icon,.e-bigger .e-input-group.e-control-wrapper.e-small input:first-child~.e-clear-icon,.e-small .e-float-input.e-control-wrapper.e-bigger input:first-child~.e-clear-icon,.e-small .e-float-input.e-bigger input:first-child~.e-clear-icon,.e-bigger .e-float-input.e-control-wrapper.e-small input:first-child~.e-clear-icon,.e-bigger .e-float-input.e-small input:first-child~.e-clear-icon{padding-bottom:0}.e-float-input.e-bigger .e-clear-icon:before,.e-float-input.e-control-wrapper.e-bigger .e-clear-icon:before,.e-input-group.e-bigger .e-clear-icon:before,.e-input-group.e-control-wrapper.e-bigger .e-clear-icon:before,.e-float-input.e-control-wrapper input.e-bigger:first-child~.e-clear-icon:before,.e-bigger .e-float-input.e-control-wrapper .e-clear-icon:before,.e-float-input input.e-bigger:first-child~.e-clear-icon:before,.e-bigger .e-float-input .e-clear-icon:before,.e-bigger .e-input-group .e-clear-icon:before,.e-bigger .e-input-group.e-control-wrapper .e-clear-icon:before{font-size:12px}.e-float-input.e-small.e-bigger .e-clear-icon:before,.e-float-input.e-control-wrapper.e-small.e-bigger .e-clear-icon:before,.e-input-group.e-small.e-bigger .e-clear-icon:before,.e-input-group.e-control-wrapper.e-small.e-bigger .e-clear-icon:before,.e-small.e-bigger .e-float-input .e-clear-icon:before,.e-small.e-bigger .e-float-input.e-control-wrapper .e-clear-icon:before,.e-small.e-bigger .e-input-group .e-clear-icon:before,.e-small.e-bigger .e-input-group.e-control-wrapper .e-clear-icon:before,.e-small .e-input-group.e-bigger input:first-child~.e-clear-icon:before,.e-small .e-input-group.e-control-wrapper.e-bigger input:first-child~.e-clear-icon:before,.e-bigger .e-input-group.e-small input:first-child~.e-clear-icon:before,.e-bigger .e-input-group.e-control-wrapper.e-small input:first-child~.e-clear-icon:before,.e-small .e-float-input.e-control-wrapper.e-bigger input:first-child~.e-clear-icon:before,.e-small .e-float-input.e-bigger input:first-child~.e-clear-icon:before,.e-bigger .e-float-input.e-control-wrapper.e-small input:first-child~.e-clear-icon:before,.e-bigger .e-float-input.e-small input:first-child~.e-clear-icon:before{font-size:12px}.e-input-group.e-bigger .e-clear-icon,.e-input-group.e-control-wrapper.e-bigger .e-clear-icon,.e-input-group .e-clear-icon.e-bigger,.e-input-group.e-control-wrapper .e-clear-icon.e-bigger,.e-bigger .e-input-group .e-clear-icon,.e-bigger .e-input-group.e-control-wrapper .e-clear-icon{min-width:20px;min-height:20px;padding-bottom:5px;padding-right:8px;padding-top:6px}.e-input-group.e-float-input.e-bigger .e-clear-icon,.e-input-group.e-float-input .e-clear-icon.e-bigger,.e-bigger .e-input-group.e-float-input .e-clear-icon,.e-input-group.e-control-wrapper.e-float-input.e-bigger .e-clear-icon,.e-input-group.e-control-wrapper.e-float-input .e-clear-icon.e-bigger,.e-bigger .e-input-group.e-control-wrapper.e-float-input .e-clear-icon{padding-right:8px;padding-top:6px}.e-small.e-bigger .e-input-group .e-clear-icon,.e-small.e-bigger .e-input-group.e-control-wrapper .e-clear-icon{min-height:20px;min-width:20px;padding-bottom:5px;padding-right:8px;padding-top:6px}.e-input-group.e-small.e-bigger .e-clear-icon,.e-input-group.e-small .e-clear-icon.e-bigger,.e-bigger .e-input-group.e-small .e-clear-icon,.e-input-group.e-control-wrapper.e-small.e-bigger .e-clear-icon,.e-input-group.e-control-wrapper.e-small .e-clear-icon.e-bigger,.e-bigger .e-input-group.e-control-wrapper.e-small .e-clear-icon{min-height:18px;min-width:18px;padding-bottom:4px;padding-right:4px;padding-top:4px}.e-input-group.e-float-input.e-small.e-bigger .e-clear-icon,.e-input-group.e-float-input.e-small .e-clear-icon.e-bigger,.e-bigger .e-input-group.e-float-input.e-small .e-clear-icon,.e-input-group.e-control-wrapper.e-float-input.e-small.e-bigger .e-clear-icon,.e-input-group.e-control-wrapper.e-float-input.e-small .e-clear-icon.e-bigger,.e-bigger .e-input-group.e-control-wrapper.e-float-input.e-small .e-clear-icon,.e-input-group.e-float-input.e-control-wrapper.e-small.e-bigger .e-clear-icon,.e-input-group.e-float-input.e-control-wrapper.e-small .e-clear-icon.e-bigger,.e-bigger .e-input-group.e-float-input.e-control-wrapper.e-small .e-clear-icon{padding-right:4px;padding-top:4px}.e-float-input.e-bigger textarea:focus~label.e-float-text,.e-float-input.e-bigger textarea:valid~label.e-float-text,.e-float-input.e-bigger textarea~label.e-label-top.e-float-text,.e-bigger .e-float-input textarea:focus~label.e-float-text,.e-bigger .e-float-input textarea:valid~label.e-float-text,.e-bigger .e-float-input textarea~label.e-label-top.e-float-text,.e-float-input.e-control-wrapper.e-bigger textarea:focus~label.e-float-text,.e-float-input.e-control-wrapper.e-bigger textarea:valid~label.e-float-text,.e-float-input.e-control-wrapper.e-bigger textarea~label.e-label-top.e-float-text,.e-bigger .e-float-input.e-control-wrapper textarea:focus~label.e-float-text,.e-bigger .e-float-input.e-control-wrapper textarea:valid~label.e-float-text,.e-bigger .e-float-input.e-control-wrapper textarea~label.e-label-top.e-float-text{font-size:14px;top:-20px}.e-float-input.e-small.e-bigger textarea:focus~label.e-float-text,.e-float-input.e-small.e-bigger textarea:valid~label.e-float-text,.e-float-input.e-small.e-bigger textarea~label.e-label-top.e-float-text,.e-bigger .e-float-input.e-small textarea:focus~label.e-float-text,.e-bigger .e-float-input.e-small textarea:valid~label.e-float-text,.e-bigger .e-float-input.e-small textarea~label.e-label-top.e-float-text,.e-float-input.e-control-wrapper.e-small.e-bigger textarea:focus~label.e-float-text,.e-float-input.e-control-wrapper.e-small.e-bigger textarea:valid~label.e-float-text,.e-float-input.e-control-wrapper.e-small.e-bigger textarea~label.e-label-top.e-float-text,.e-bigger .e-float-input.e-control-wrapper.e-small textarea:focus~label.e-float-text,.e-bigger .e-float-input.e-control-wrapper.e-small textarea:valid~label.e-float-text,.e-bigger .e-float-input.e-control-wrapper.e-small textarea~label.e-label-top.e-float-text{font-size:13px;top:-20px}.e-float-input.e-bigger textarea~label.e-float-text,.e-float-input textarea~label.e-float-text.e-bigger,.e-float-input textarea.e-bigger~label.e-float-text,.e-bigger .e-float-input textarea~label.e-float-text,.e-float-input.e-bigger textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger .e-float-input textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-float-input.e-control-wrapper.e-bigger textarea~label.e-float-text,.e-float-input.e-control-wrapper textarea~label.e-float-text.e-bigger,.e-float-input.e-control-wrapper textarea.e-bigger~label.e-float-text,.e-bigger .e-float-input.e-control-wrapper textarea~label.e-float-text,.e-float-input.e-control-wrapper.e-bigger textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger .e-float-input.e-control-wrapper textarea:not(:focus):valid~label.e-float-text.e-label-bottom{font-size:14px;top:-8px}.e-input-group.e-bigger:not(.e-float-input) .e-input,.e-bigger .e-input-group:not(.e-float-input) .e-input,.e-input-group.e-control-wrapper.e-bigger:not(.e-float-input) .e-input,.e-bigger .e-input-group.e-control-wrapper:not(.e-float-input) .e-input,.e-float-input.e-bigger input,.e-bigger .e-float-input input,.e-float-input.e-input-group.e-bigger input,.e-bigger .e-float-input.e-input-group input,.e-float-input.e-input-group.e-control-wrapper.e-bigger input,.e-bigger .e-float-input.e-input-group.e-control-wrapper input,.e-float-input.e-control-wrapper.e-bigger input,.e-bigger .e-float-input.e-control-wrapper input,.e-float-input.e-control-wrapper.e-input-group.e-bigger input,.e-bigger .e-float-input.e-control-wrapper.e-input-group input{min-height:27px}.e-input-group.e-bigger.e-small:not(.e-float-input) .e-input,.e-bigger .e-input-group.e-small:not(.e-float-input) .e-input .e-small .e-input-group.e-bigger:not(.e-float-input) .e-input,.e-input-group.e-control-wrapper.e-bigger.e-small:not(.e-float-input) .e-input,.e-bigger .e-input-group.e-control-wrapper.e-small:not(.e-float-input) .e-input .e-small .e-input-group.e-control-wrapper.e-bigger:not(.e-float-input) .e-input,.e-float-input.e-bigger.e-small input,.e-bigger .e-float-input.e-small input,.e-small .e-float-input.e-bigger input,.e-float-input.e-input-group.e-bigger.e-small input,.e-bigger .e-float-input.e-input-group.e-small input,.e-small .e-float-input.e-input-group.e-bigger input,.e-float-input.e-input-group.e-control-wrapper.e-bigger.e-small input,.e-bigger .e-float-input.e-input-group.e-control-wrapper.e-small input,.e-small .e-float-input.e-input-group.e-control-wrapper.e-bigger input,.e-float-input.e-control-wrapper.e-bigger.e-small input,.e-bigger .e-float-input.e-control-wrapper.e-small input,.e-small .e-float-input.e-control-wrapper.e-bigger input,.e-float-input.e-control-wrapper.e-input-group.e-bigger.e-small input,.e-bigger .e-float-input.e-control-wrapper.e-input-group.e-small input,.e-small .e-float-input.e-control-wrapper.e-input-group.e-bigger input{min-height:28px}.e-bigger .e-float-input:not(.e-outline) input:-webkit-autofill~label.e-float-text,.e-bigger.e-float-input:not(.e-outline) input:-webkit-autofill~label.e-float-text,.e-bigger .e-float-input.e-control-wrapper.e-autofill:not(.e-outline) input:-webkit-autofill~label.e-float-text,.e-bigger.e-float-input.e-control-wrapper.e-autofill:not(.e-outline) input:-webkit-autofill~label.e-float-text,.e-bigger .e-float-input.e-control-wrapper.e-autofill:not(.e-input-focus):not(.e-outline) input:not(:focus):valid:-webkit-autofill~label.e-float-text.e-label-bottom,.e-bigger.e-float-input.e-control-wrapper.e-autofill:not(.e-input-focus):not(.e-outline) input:not(:focus):valid:-webkit-autofill~label.e-float-text.e-label-bottom{font-size:14px;top:-8px;transform:translate3d(0,-6px,0) scale(.86);-webkit-user-select:text;user-select:text}.e-bigger .e-float-input.e-small:not(.e-outline) input:-webkit-autofill~label.e-float-text,.e-bigger.e-small .e-float-input:not(.e-outline) input:-webkit-autofill~label.e-float-text,.e-float-input.e-bigger.e-small:not(.e-outline) input:-webkit-autofill~label.e-float-text,.e-bigger .e-float-input.e-small.e-control-wrapper.e-autofill:not(.e-outline) input:-webkit-autofill~label.e-float-text,.e-bigger.e-small .e-float-input.e-control-wrapper.e-autofill:not(.e-outline) input:-webkit-autofill~label.e-float-text,.e-float-input.e-bigger.e-small.e-control-wrapper.e-autofill:not(.e-outline) input:-webkit-autofill~label.e-float-text,.e-small.e-bigger .e-float-input.e-control-wrapper.e-autofill:not(.e-input-focus):not(.e-outline) input:not(:focus):valid:-webkit-autofill~label.e-float-text.e-label-bottom,.e-small.e-bigger.e-float-input.e-control-wrapper.e-autofill:not(.e-input-focus):not(.e-outline) input:not(:focus):valid:-webkit-autofill~label.e-float-text.e-label-bottom,.e-bigger .e-small.e-float-input.e-control-wrapper.e-autofill:not(.e-input-focus):not(.e-outline) input:not(:focus):valid:-webkit-autofill~label.e-float-text.e-label-bottom,.e-small .e-bigger.e-float-input.e-control-wrapper.e-autofill:not(.e-input-focus):not(.e-outline) input:not(:focus):valid:-webkit-autofill~label.e-float-text.e-label-bottom{font-size:13px;top:-10px;transform:translate3d(0,-6px,0) scale(.92);-webkit-user-select:text;user-select:text}.e-bigger .e-float-input.e-small textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small .e-float-input.e-bigger textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-float-input.e-bigger.e-small textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger.e-small .e-float-input textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger .e-float-input.e-control-wrapper.e-small textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small .e-float-input.e-control-wrapper.e-bigger textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-float-input.e-control-wrapper.e-bigger.e-small textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger.e-small .e-float-input.e-control-wrapper textarea:not(:focus):valid~label.e-float-text.e-label-bottom{font-size:13px;top:-10px;font-style:normal}.e-float-input.e-bigger.e-small textarea:focus~label.e-float-text,.e-float-input.e-bigger.e-small textarea:valid~label.e-float-text,.e-float-input.e-bigger.e-small textarea~label.e-label-top.e-float-text,.e-float-input.e-bigger.e-small textarea[readonly]~label.e-label-top.e-float-text,.e-float-input.e-bigger.e-small textarea[disabled]~label.e-label-top.e-float-text,.e-float-input.e-bigger.e-small textarea label.e-float-text.e-label-top,.e-bigger .e-float-input.e-small textarea:focus~label.e-float-text,.e-bigger .e-float-input.e-small textarea:valid~label.e-float-text,.e-bigger .e-float-input.e-small textarea~label.e-label-top.e-float-text,.e-bigger .e-float-input.e-small textarea[readonly]~label.e-label-top.e-float-text,.e-bigger .e-float-input.e-small textarea[disabled]~label.e-label-top.e-float-text,.e-bigger .e-float-input.e-small textarea label.e-float-text.e-label-top,.e-small .e-float-input.e-bigger textarea:focus~label.e-float-text,.e-small .e-float-input.e-bigger textarea:valid~label.e-float-text,.e-small .e-float-input.e-bigger textarea~label.e-label-top.e-float-text,.e-small .e-float-input.e-bigger textarea[readonly]~label.e-label-top.e-float-text,.e-small .e-float-input.e-bigger textarea[disabled]~label.e-label-top.e-float-text,.e-small .e-float-input.e-bigger textarea label.e-float-text.e-label-top,.e-float-input.e-control-wrapper.e-bigger.e-small textarea:focus~label.e-float-text,.e-float-input.e-control-wrapper.e-bigger.e-small textarea:valid~label.e-float-text,.e-float-input.e-control-wrapper.e-bigger.e-small textarea~label.e-label-top.e-float-text,.e-float-input.e-control-wrapper.e-bigger.e-small textarea[readonly]~label.e-label-top.e-float-text,.e-float-input.e-control-wrapper.e-bigger.e-small textarea[disabled]~label.e-label-top.e-float-text,.e-float-input.e-control-wrapper.e-bigger.e-small textarea label.e-float-text.e-label-top,.e-bigger .e-float-input.e-control-wrapper.e-small textarea:focus~label.e-float-text,.e-bigger .e-float-input.e-control-wrapper.e-small textarea:valid~label.e-float-text,.e-bigger .e-float-input.e-control-wrapper.e-small textarea~label.e-label-top.e-float-text,.e-bigger .e-float-input.e-control-wrapper.e-small textarea[readonly]~label.e-label-top.e-float-text,.e-bigger .e-float-input.e-control-wrapper.e-small textarea[disabled]~label.e-label-top.e-float-text,.e-bigger .e-float-input.e-control-wrapper.e-small textarea label.e-float-text.e-label-top,.e-small .e-float-input.e-control-wrapper.e-bigger textarea:focus~label.e-float-text,.e-small .e-float-input.e-control-wrapper.e-bigger textarea:valid~label.e-float-text,.e-small .e-float-input.e-control-wrapper.e-bigger textarea~label.e-label-top.e-float-text,.e-small .e-float-input.e-control-wrapper.e-bigger textarea[readonly]~label.e-label-top.e-float-text,.e-small .e-float-input.e-control-wrapper.e-bigger textarea[disabled]~label.e-label-top.e-float-text,.e-small .e-float-input.e-control-wrapper.e-bigger textarea label.e-float-text.e-label-top{transform:translate3d(0,6px,0) scale(.92)}.e-bigger .e-float-input.e-small textarea:-webkit-autofill~label.e-float-text,.e-bigger.e-small .e-float-input textarea:-webkit-autofill~label.e-float-text,.e-float-input.e-bigger.e-small textarea:-webkit-autofill~label.e-float-text,.e-bigger .e-float-input.e-small.e-control-wrapper.e-autofill textarea:-webkit-autofill~label.e-float-text,.e-bigger.e-small .e-float-input.e-control-wrapper.e-autofill textarea:-webkit-autofill~label.e-float-text,.e-float-input.e-bigger.e-small.e-control-wrapper.e-autofill textarea:-webkit-autofill~label.e-float-text,.e-small.e-bigger .e-float-input.e-control-wrapper.e-autofill textarea:not(:focus):valid:-webkit-autofill~label.e-float-text.e-label-bottom,.e-small.e-bigger.e-float-input.e-control-wrapper.e-autofill textarea:not(:focus):valid:-webkit-autofill~label.e-float-text.e-label-bottom,.e-bigger .e-small.e-float-input.e-control-wrapper.e-autofill textarea:not(:focus):valid:-webkit-autofill~label.e-float-text.e-label-bottom,.e-small .e-bigger.e-float-input.e-control-wrapper.e-autofill textarea:not(:focus):valid:-webkit-autofill~label.e-float-text.e-label-bottom{font-size:13px;top:-10px;transform:translate3d(0,-6px,0) scale(.92);-webkit-user-select:text;user-select:text}.e-bigger .e-float-input textarea:-webkit-autofill~label.e-float-text,.e-bigger.e-float-input textarea:-webkit-autofill~label.e-float-text,.e-bigger .e-float-input.e-control-wrapper.e-autofill textarea:-webkit-autofill~label.e-float-text,.e-bigger.e-float-input.e-control-wrapper.e-autofill textarea:-webkit-autofill~label.e-float-text,.e-bigger .e-float-input.e-control-wrapper.e-autofill textarea:not(:focus):valid:-webkit-autofill~label.e-float-text.e-label-bottom,.e-bigger.e-float-input.e-control-wrapper.e-autofill textarea:not(:focus):valid:-webkit-autofill~label.e-float-text.e-label-bottom{font-size:14px;top:-8px;transform:translate3d(0,-6px,0) scale(.86);-webkit-user-select:text;user-select:text}.e-float-input.e-bigger textarea:focus~label.e-float-text,.e-float-input.e-bigger textarea:valid~label.e-float-text,.e-float-input.e-bigger textarea~label.e-label-top.e-float-text,.e-float-input.e-bigger textarea[readonly]~label.e-label-top.e-float-text,.e-float-input.e-bigger textarea[disabled]~label.e-label-top.e-float-text,.e-float-input.e-bigger textarea label.e-float-text.e-label-top,.e-bigger .e-float-input textarea:focus~label.e-float-text,.e-bigger .e-float-input textarea:valid~label.e-float-text,.e-bigger .e-float-input textarea~label.e-label-top.e-float-text,.e-bigger .e-float-input textarea[readonly]~label.e-label-top.e-float-text,.e-bigger .e-float-input textarea[disabled]~label.e-label-top.e-float-text,.e-bigger .e-float-input textarea label.e-float-text.e-label-top,.e-float-input.e-control-wrapper.e-bigger textarea:focus~label.e-float-text,.e-float-input.e-control-wrapper.e-bigger textarea:valid~label.e-float-text,.e-float-input.e-control-wrapper.e-bigger textarea~label.e-label-top.e-float-text,.e-float-input.e-control-wrapper.e-bigger textarea[readonly]~label.e-label-top.e-float-text,.e-float-input.e-control-wrapper.e-bigger textarea[disabled]~label.e-label-top.e-float-text,.e-float-input.e-control-wrapper.e-bigger textarea label.e-float-text.e-label-top,.e-bigger .e-float-input.e-control-wrapper textarea:focus~label.e-float-text,.e-bigger .e-float-input.e-control-wrapper textarea:valid~label.e-float-text,.e-bigger .e-float-input.e-control-wrapper textarea~label.e-label-top.e-float-text,.e-bigger .e-float-input.e-control-wrapper textarea[readonly]~label.e-label-top.e-float-text,.e-bigger .e-float-input.e-control-wrapper textarea[disabled]~label.e-label-top.e-float-text,.e-bigger .e-float-input.e-control-wrapper textarea label.e-float-text.e-label-top{transform:translate3d(0,6px,0) scale(.86)}.e-float-input.e-small.e-bigger textarea:focus~label.e-float-text,.e-float-input.e-small.e-bigger textarea:valid~label.e-float-text,.e-float-input.e-small.e-bigger textarea~label.e-label-top.e-float-text,.e-float-input.e-small.e-bigger textarea[readonly]~label.e-label-top.e-float-text,.e-float-input.e-small.e-bigger textarea[disabled]~label.e-label-top.e-float-text,.e-float-input.e-small.e-bigger textarea label.e-float-text.e-label-top,.e-bigger.e-small .e-float-input textarea:focus~label.e-float-text,.e-bigger.e-small .e-float-input textarea:valid~label.e-float-text,.e-bigger.e-small .e-float-input textarea~label.e-label-top.e-float-text,.e-bigger.e-small .e-float-input textarea[readonly]~label.e-label-top.e-float-text,.e-bigger.e-small .e-float-input textarea[disabled]~label.e-label-top.e-float-text,.e-bigger.e-small .e-float-input textarea label.e-float-text.e-label-top,.e-float-input.e-control-wrapper.e-bigger.e-small textarea:focus~label.e-float-text,.e-float-input.e-control-wrapper.e-bigger.e-small textarea:valid~label.e-float-text,.e-float-input.e-control-wrapper.e-bigger.e-small textarea~label.e-label-top.e-float-text,.e-float-input.e-control-wrapper.e-bigger.e-small textarea[readonly]~label.e-label-top.e-float-text,.e-float-input.e-control-wrapper.e-bigger.e-small textarea[disabled]~label.e-label-top.e-float-text,.e-float-input.e-control-wrapper.e-bigger.e-small textarea label.e-float-text.e-label-top,.e-small.e-bigger .e-float-input.e-control-wrapper textarea:focus~label.e-float-text,.e-small.e-bigger .e-float-input.e-control-wrapper textarea:valid~label.e-float-text,.e-small.e-bigger .e-float-input.e-control-wrapper textarea~label.e-label-top.e-float-text,.e-small.e-bigger .e-float-input.e-control-wrapper textarea[readonly]~label.e-label-top.e-float-text,.e-small.e-bigger .e-float-input.e-control-wrapper textarea[disabled]~label.e-label-top.e-float-text,.e-small.e-bigger .e-float-input.e-control-wrapper textarea label.e-float-text.e-label-top{transform:translate3d(0,6px,0) scale(.86)}.e-input-group.e-bigger textarea,.e-input-group.e-bigger textarea.e-input,.e-input-group textarea.e-bigger,.e-input-group textarea.e-input.e-bigger,.e-input-group.e-control-wrapper.e-bigger textarea,.e-input-group.e-control-wrapper.e-bigger textarea.e-input,.e-input-group.e-control-wrapper textarea.e-bigger,.e-input-group.e-control-wrapper textarea.e-input.e-bigger,.e-bigger .e-input-group textarea,.e-bigger .e-input-group textarea.e-input,.e-bigger .e-input-group.e-control-wrapper textarea,.e-bigger .e-input-group.e-control-wrapper textarea.e-input,.e-float-input.e-bigger textarea,.e-float-input textarea.e-bigger,.e-float-input.e-control-wrapper.e-bigger textarea,.e-float-input.e-control-wrapper textarea.e-bigger,.e-bigger .e-float-input textarea,.e-bigger .e-float-input.e-control-wrapper textarea{font:inherit;line-height:1.2;min-height:17px;padding:5px 0}.e-input-group.e-input-focus.e-bigger textarea,.e-input-group.e-input-focus.e-bigger textarea.e-input,.e-input-group.e-input-focus textarea.e-bigger,.e-input-group.e-input-focus textarea.e-input.e-bigger,.e-input-group.e-control-wrapper.e-input-focus.e-bigger textarea,.e-input-group.e-control-wrapper.e-input-focus.e-bigger textarea.e-input,.e-input-group.e-control-wrapper.e-input-focus textarea.e-bigger,.e-input-group.e-control-wrapper.e-input-focus textarea.e-input.e-bigger,.e-bigger .e-input-group.e-input-focus textarea,.e-bigger .e-input-group.e-control-wrapper.e-input-focus textarea,.e-bigger .e-input-group.e-control-wrapper.e-input-focus textarea.e-input,.e-input-group.e-control-wrapper textarea.e-bigger:focus,.e-input-group.e-control-wrapper textarea.e-input.e-bigger:focus,.e-bigger .e-input-group.e-control-wrapper textarea:focus,.e-bigger .e-input-group.e-control-wrapper.e-input-focus textarea:focus,.e-bigger .e-input-group.e-control-wrapper textarea.e-input:focus{font:inherit;line-height:1.2;min-height:17px;padding:5px 0}.e-input-group.e-small.e-bigger textarea.e-input,.e-input-group.e-small textarea.e-input.e-bigger,.e-input-group textarea.e-input.e-bigger.e-small,.e-input-group.e-bigger textarea.e-small,.e-input-group.e-control-wrapper.e-small.e-bigger textarea.e-input,.e-input-group.e-control-wrapper.e-small textarea.e-input.e-bigger,.e-bigger.e-small .e-input-group textarea.e-input,.e-bigger.e-small .e-input-group.e-control-wrapper textarea.e-input,.e-bigger .input-group textarea.e-small,.e-bigger .e-input-group.e-small textarea.e-input,.e-bigger .e-input-group.e-control-wrapper.e-small textarea.e-input,.e-bigger .e-small.e-input-group.e-control-wrapper textarea.e-input,.e-small .input-group textarea.e-bigger,.e-small .e-input-group.e-bigger textarea.e-input,.e-small .e-input-group.e-control-wrapper textarea.e-input.e-bigger,.e-small .e-input-group.e-control-wrapper.e-input-focus textarea.e-input.e-bigger,.e-float-input textarea.e-bigger.e-small,.e-float-input.e-small.e-bigger textarea,.e-float-input.e-small textarea.e-bigger,.e-float-input.e-bigger textarea.e-small,.e-bigger .e-float-input.e-small textarea,.e-bigger.e-small .e-float-input textarea,.e-bigger .float-input textarea.e-small,.e-small .e-float-input.e-bigger textarea,.e-small .float-input textarea.e-bigger,.e-small .e-float-input.e-control-wrapper textarea.e-bigger,.e-float-input.e-control-wrapper.e-small.e-bigger textarea,.e-float-input.e-control-wrapper.e-small textarea.e-bigger,.e-bigger .e-float-input.e-control-wrapper.e-small textarea,.e-bigger.e-small .e-float-input.e-control-wrapper textarea,.e-bigger .e-small.e-float-input.e-control-wrapper textarea,.e-input-group.e-input-focus textarea.e-input.e-bigger.e-small,.e-input-group.e-input-focus.e-small.e-bigger textarea.e-input,.e-input-group.e-input-focus.e-small textarea.e-input.e-bigger,.e-input-group.e-input-focus.e-bigger textarea.e-small,.e-input-group.e-control-wrapper.e-input-focus.e-small.e-bigger textarea.e-input,.e-input-group.e-control-wrapper.e-input-focus.e-small textarea.e-input.e-bigger,.e-bigger.e-small .e-input-group.e-input-focus textarea.e-input,.e-bigger .e-input-group.e-control-wrapper.e-input-focus.e-small textarea.e-input,.e-bigger.e-small .e-input-group.e-control-wrapper.e-input-focus textarea.e-input,.e-bigger .e-small.e-input-group.e-control-wrapper.e-input-focus textarea.e-input,.e-small .e-input-group.e-control-wrapper.e-input-focus.e-bigger textarea.e-input{font:inherit;line-height:1.2;min-height:15px;padding:4px 0}.e-bigger input.e-input,.e-bigger textarea.e-input,input.e-input.e-bigger,textarea.e-input.e-bigger{min-height:23px}.e-bigger input.e-input.e-small,.e-bigger .e-small input.e-input,.e-bigger.e-small input.e-input,.e-small input.e-input.e-bigger,input.e-input.e-bigger.e-small,.e-small .e-bigger input.e-input{min-height:19px}input.e-input.e-bigger.e-outline,textarea.e-input.e-bigger.e-outline,.e-outline.e-bigger input.e-input,.e-outline.e-bigger textarea.e-input,.e-outline.e-input-group.e-bigger,.e-bigger .e-input-group.e-outline,.e-outline.e-input-group.e-control-wrapper.e-bigger,.e-bigger .e-outline.e-input-group.e-control-wrapper,.e-outline.e-input-group.e-bigger.e-disabled,.e-bigger .e-outline.e-input-group.e-disabled,.e-outline.e-input-group.e-control-wrapper.e-bigger.e-disabled,.e-bigger .e-outline.e-input-group.e-control-wrapper.e-disabled,.e-bigger .e-outline.e-input-group,.e-outline.e-float-input.e-bigger,.e-bigger .e-outline.e-float-input,.e-outline.e-float-input.e-control-wrapper.e-bigger,.e-bigger .e-outline.e-float-input.e-control-wrapper{font-size:16px}.e-outline.e-input-group.e-control-wrapper.e-bigger .e-input-group-icon,.e-bigger .e-outline.e-input-group.e-control-wrapper .e-input-group-icon,.e-outline.e-input-group.e-bigger.e-disabled .e-input-group-icon,.e-bigger .e-outline.e-input-group.e-disabled .e-input-group-icon,.e-outline.e-input-group.e-control-wrapper.e-bigger.e-disabled .e-input-group-icon,.e-bigger .e-outline.e-input-group.e-control-wrapper.e-disabled .e-input-group-icon{font-size:20px}.e-outline.e-input-group.e-bigger .e-input-group-icon+.e-input-group-icon:last-child,.e-outline.e-input-group .e-input-group-icon.e-bigger+.e-input-group-icon.e-bigger:last-child,.e-bigger .e-outline.e-input-group .e-input-group-icon+.e-input-group-icon:last-child,.e-outline.e-input-group.e-small.e-bigger .e-input-group-icon+.e-input-group-icon:last-child,.e-outline.e-input-group.e-small .e-input-group-icon.e-bigger+.e-input-group-icon.e-bigger:last-child,.e-outline.e-input-group.e-control-wrapper.e-bigger .e-input-group-icon+.e-input-group-icon:last-child,.e-outline.e-input-group.e-control-wrapper .e-input-group-icon.e-bigger+.e-input-group-icon.e-bigger:last-child,e-outline.e-input-group.e-control-wrapper.e-small.e-bigger .e-input-group-icon+.e-input-group-icon:last-child,.e-outline.e-input-group.e-control-wrapper.e-small .e-input-group-icon.e-bigger+.e-input-group-icon.e-bigger:last-child,.e-bigger .e-outline.e-input-group.e-control-wrapper.e-small .e-input-group-icon+.e-input-group-icon:last-child,.e-bigger .e-outline.e-input-group.e-small .e-input-group-icon+.e-input-group-icon:last-child{margin-left:0}.e-outline.e-float-input.e-bigger input:focus~label.e-float-text,.e-outline.e-float-input.e-bigger input:valid~label.e-float-text,.e-outline.e-float-input.e-bigger input~label.e-label-top.e-float-text,.e-bigger .e-outline.e-float-input input~label.e-label-top.e-float-text,.e-outline.e-float-input.e-bigger input[readonly]~label.e-label-top.e-float-text,.e-outline.e-float-input.e-bigger input[disabled]~label.e-label-top.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-bigger input:focus~label.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-bigger input:valid~label.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-bigger input~label.e-label-top.e-float-text,.e-bigger .e-outline.e-float-input.e-control-wrapper input~label.e-label-top.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-bigger input[readonly]~label.e-label-top.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-bigger input[disabled]~label.e-label-top.e-float-text,.e-outline.e-float-input.e-bigger textarea:focus~label.e-float-text,.e-outline.e-float-input.e-bigger textarea:valid~label.e-float-text,.e-outline.e-float-input.e-bigger textarea~label.e-label-top.e-float-text,.e-bigger .e-outline.e-float-input textarea~label.e-label-top.e-float-text,.e-outline.e-float-input.e-bigger textarea[readonly]~label.e-label-top.e-float-text,.e-outline.e-float-input.e-bigger textarea[disabled]~label.e-label-top.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-bigger textarea:focus~label.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-bigger textarea:valid~label.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-bigger textarea~label.e-label-top.e-float-text,.e-bigger .e-outline.e-float-input.e-control-wrapper textarea~label.e-label-top.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-bigger textarea[readonly]~label.e-label-top.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-bigger textarea[disabled]~label.e-label-top.e-float-text,.e-outline.e-float-input.e-bigger.e-input-focus input~label.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-bigger.e-input-focus input~label.e-float-text{font-size:12px}.e-outline.e-input-group.e-small.e-bigger,.e-small .e-outline.e-input-group.e-bigger,.e-bigger .e-outline.e-input-group.e-small,.e-bigger.e-small .e-outline.e-input-group,.e-outline.e-input-group.e-control-wrapper.e-small.e-bigger,.e-small .e-outline.e-input-group.e-control-wrapper.e-bigger,.e-bigger .e-outline.e-input-group.e-control-wrapper.e-small,.e-bigger.e-small .e-outline.e-input-group.e-control-wrapper,.e-outline.e-float-input.e-small.e-bigger,.e-small .e-outline.e-float-input.e-bigger,.e-bigger .e-outline.e-float-input.e-small,.e-bigger.e-small .e-outline.e-float-input,.e-outline.e-float-input.e-control-wrapper.e-small.e-bigger,.e-small .e-outline.e-float-input.e-control-wrapper.e-bigger,.e-bigger .e-outline.e-float-input.e-control-wrapper.e-small,.e-bigger.e-small .e-outline.e-float-input.e-control-wrapper{font-size:14px}.e-small.e-outline.e-float-input.e-bigger input:focus~label.e-float-text,.e-small.e-outline.e-float-input.e-bigger input:valid~label.e-float-text,.e-small.e-outline.e-float-input.e-bigger input~label.e-label-top.e-float-text,.e-bigger .e-small.e-outline.e-float-input input~label.e-label-top.e-float-text,.e-small.e-outline.e-float-input.e-bigger input[readonly]~label.e-label-top.e-float-text,.e-small.e-outline.e-float-input.e-bigger input[disabled]~label.e-label-top.e-float-text,.e-small.e-outline.e-float-input.e-control-wrapper.e-bigger input:focus~label.e-float-text,.e-small.e-outline.e-float-input.e-control-wrapper.e-bigger input:valid~label.e-float-text,.e-small.e-outline.e-float-input.e-control-wrapper.e-bigger input~label.e-label-top.e-float-text,.e-bigger .e-small.e-outline.e-float-input.e-control-wrapper input~label.e-label-top.e-float-text,.e-small.e-outline.e-float-input.e-control-wrapper.e-bigger input[readonly]~label.e-label-top.e-float-text,.e-small.e-outline.e-float-input.e-control-wrapper.e-bigger input[disabled]~label.e-label-top.e-float-text,.e-small .e-outline.e-float-input.e-bigger input:focus~label.e-float-text,.e-small .e-outline.e-float-input.e-bigger input:valid~label.e-float-text,.e-small .e-outline.e-float-input.e-bigger input~label.e-label-top.e-float-text,.e-small .e-bigger.e-outline.e-float-input input~label.e-label-top.e-float-text,.e-small .e-outline.e-float-input.e-bigger input[readonly]~label.e-label-top.e-float-text,.e-small .e-outline.e-float-input.e-bigger input[disabled]~label.e-label-top.e-float-text,.e-small .e-outline.e-float-input.e-control-wrapper.e-bigger input:focus~label.e-float-text,.e-small .e-outline.e-float-input.e-control-wrapper.e-bigger input:valid~label.e-float-text,.e-small .e-outline.e-float-input.e-control-wrapper.e-bigger input~label.e-label-top.e-float-text,.e-small .e-bigger.e-outline.e-float-input.e-control-wrapper input~label.e-label-top.e-float-text,.e-small .e-outline.e-float-input.e-control-wrapper.e-bigger input[readonly]~label.e-label-top.e-float-text,.e-small .e-outline.e-float-input.e-control-wrapper.e-bigger input[disabled]~label.e-label-top.e-float-text,.e-bigger .e-outline.e-float-input.e-bigger input:focus~label.e-float-text,.e-bigger .e-outline.e-float-input.e-bigger input:valid~label.e-float-text,.e-bigger .e-outline.e-float-input.e-bigger input~label.e-label-top.e-float-text,.e-bigger .e-outline.e-float-input.e-bigger input[readonly]~label.e-label-top.e-float-text,.e-bigger .e-outline.e-float-input.e-bigger input[disabled]~label.e-label-top.e-float-text,.e-bigger .e-outline.e-float-input.e-control-wrapper.e-bigger input:focus~label.e-float-text,.e-bigger .e-outline.e-float-input.e-control-wrapper.e-bigger input:valid~label.e-float-text,.e-bigger .e-outline.e-float-input.e-control-wrapper.e-bigger input~label.e-label-top.e-float-text,.e-bigger .e-outline.e-float-input.e-control-wrapper.e-bigger input[readonly]~label.e-label-top.e-float-text,.e-bigger .e-outline.e-float-input.e-control-wrapper.e-bigger input[disabled]~label.e-label-top.e-float-text,.e-small.e-outline.e-float-input.e-bigger textarea:focus~label.e-float-text,.e-small.e-outline.e-float-input.e-bigger textarea:valid~label.e-float-text,.e-small.e-outline.e-float-input.e-bigger textarea~label.e-label-top.e-float-text,.e-bigger .e-small.e-outline.e-float-input textarea~label.e-label-top.e-float-text,.e-small.e-outline.e-float-input.e-bigger textarea[readonly]~label.e-label-top.e-float-text,.e-small.e-outline.e-float-input.e-bigger textarea[disabled]~label.e-label-top.e-float-text,.e-small.e-outline.e-float-input.e-control-wrapper.e-bigger textarea:focus~label.e-float-text,.e-small.e-outline.e-float-input.e-control-wrapper.e-bigger textarea:valid~label.e-float-text,.e-small.e-outline.e-float-input.e-control-wrapper.e-bigger textarea~label.e-label-top.e-float-text,.e-bigger .e-small.e-outline.e-float-input.e-control-wrapper textarea~label.e-label-top.e-float-text,.e-small.e-outline.e-float-input.e-control-wrapper.e-bigger textarea[readonly]~label.e-label-top.e-float-text,.e-small.e-outline.e-float-input.e-control-wrapper.e-bigger textarea[disabled]~label.e-label-top.e-float-text,.e-small .e-outline.e-float-input.e-bigger textarea:focus~label.e-float-text,.e-small .e-outline.e-float-input.e-bigger textarea:valid~label.e-float-text,.e-small .e-outline.e-float-input.e-bigger textarea~label.e-label-top.e-float-text,.e-small .e-bigger.e-outline.e-float-input textarea~label.e-label-top.e-float-text,.e-small .e-outline.e-float-input.e-bigger textarea[readonly]~label.e-label-top.e-float-text,.e-small .e-outline.e-float-input.e-bigger textarea[disabled]~label.e-label-top.e-float-text,.e-small .e-outline.e-float-input.e-control-wrapper.e-bigger textarea:focus~label.e-float-text,.e-small .e-outline.e-float-input.e-control-wrapper.e-bigger textarea:valid~label.e-float-text,.e-small .e-outline.e-float-input.e-control-wrapper.e-bigger textarea~label.e-label-top.e-float-text,.e-small .e-bigger.e-outline.e-float-input.e-control-wrapper textarea~label.e-label-top.e-float-text,.e-small .e-outline.e-float-input.e-control-wrapper.e-bigger textarea[readonly]~label.e-label-top.e-float-text,.e-small .e-outline.e-float-input.e-control-wrapper.e-bigger textarea[disabled]~label.e-label-top.e-float-text,.e-bigger .e-outline.e-float-input.e-bigger textarea:focus~label.e-float-text,.e-bigger .e-outline.e-float-input.e-bigger textarea:valid~label.e-float-text,.e-bigger .e-outline.e-float-input.e-bigger textarea~label.e-label-top.e-float-text,.e-bigger .e-outline.e-float-input.e-bigger textarea[readonly]~label.e-label-top.e-float-text,.e-bigger .e-outline.e-float-input.e-bigger textarea[disabled]~label.e-label-top.e-float-text,.e-bigger .e-outline.e-float-input.e-control-wrapper.e-bigger textarea:focus~label.e-float-text,.e-bigger .e-outline.e-float-input.e-control-wrapper.e-bigger textarea:valid~label.e-float-text,.e-bigger .e-outline.e-float-input.e-control-wrapper.e-bigger textarea~label.e-label-top.e-float-text,.e-bigger .e-outline.e-float-input.e-control-wrapper.e-bigger textarea[readonly]~label.e-label-top.e-float-text,.e-bigger .e-outline.e-float-input.e-control-wrapper.e-bigger textarea[disabled]~label.e-label-top.e-float-text,.e-small.e-outline.e-float-input.e-bigger.e-input-focus input~label.e-float-text,.e-small.e-outline.e-float-input.e-control-wrapper.e-bigger.e-input-focus input~label.e-float-text,.e-small .e-outline.e-float-input.e-bigger.e-input-focus input~label.e-float-text,.e-small .e-outline.e-float-input.e-control-wrapper.e-bigger.e-input-focus input~label.e-float-text,.e-bigger .e-outline.e-float-input.e-bigger.e-input-focus input~label.e-float-text,.e-bigger .e-outline.e-float-input.e-control-wrapper.e-bigger.e-input-focus input~label.e-float-text,.e-outline.e-float-input.e-small.e-bigger input:focus~label.e-float-text,.e-outline.e-float-input.e-small.e-bigger input:valid~label.e-float-text,.e-outline.e-float-input.e-small.e-bigger input~label.e-label-top.e-float-text,.e-outline.e-float-input.e-small.e-bigger input[readonly]~label.e-float-text,.e-outline.e-float-input.e-small.e-bigger input[disabled]~label.e-float-text,.e-bigger .e-outline.e-float-input.e-small input:focus~label.e-float-text,.e-bigger .e-outline.e-float-input.e-small input:valid~label.e-float-text,.e-bigger .e-outline.e-float-input.e-small input~label.e-label-top.e-float-text,.e-bigger .e-outline.e-float-input.e-small input[readonly]~label.e-float-text,.e-bigger .e-outline.e-float-input.e-small input[disabled]~label.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-small.e-bigger input:focus~label.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-small.e-bigger input:valid~label.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-small.e-bigger input~label.e-label-top.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-small.e-bigger input[readonly]~label.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-small.e-bigger input[disabled]~label.e-float-text,.e-bigger .e-outline.e-float-input.e-control-wrapper.e-small input:focus~label.e-float-text,.e-bigger .e-outline.e-float-input.e-control-wrapper.e-small input:valid~label.e-float-text,.e-bigger .e-outline.e-float-input.e-control-wrapper.e-small input~label.e-label-top.e-float-text,.e-bigger .e-outline.e-float-input.e-control-wrapper.e-small input[readonly]~label.e-float-text,.e-bigger .e-outline.e-float-input.e-control-wrapper.e-small input[disabled]~label.e-float-text,.e-outline.e-float-input.e-small.e-bigger textarea:focus~label.e-float-text,.e-outline.e-float-input.e-small.e-bigger textarea:valid~label.e-float-text,.e-outline.e-float-input.e-small.e-bigger textarea~label.e-label-top.e-float-text,.e-outline.e-float-input.e-small.e-bigger textarea[readonly]~label.e-float-text,.e-outline.e-float-input.e-small.e-bigger textarea[disabled]~label.e-float-text,.e-bigger .e-outline.e-float-input.e-small textarea:focus~label.e-float-text,.e-bigger .e-outline.e-float-input.e-small textarea:valid~label.e-float-text,.e-bigger .e-outline.e-float-input.e-small textarea~label.e-label-top.e-float-text,.e-bigger .e-outline.e-float-input.e-small textarea[readonly]~label.e-float-text,.e-bigger .e-outline.e-float-input.e-small textarea[disabled]~label.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-small.e-bigger textarea:focus~label.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-small.e-bigger textarea:valid~label.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-small.e-bigger textarea~label.e-label-top.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-small.e-bigger textarea[readonly]~label.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-small.e-bigger textarea[disabled]~label.e-float-text,.e-bigger .e-outline.e-float-input.e-control-wrapper.e-small textarea:focus~label.e-float-text,.e-bigger .e-outline.e-float-input.e-control-wrapper.e-small textarea:valid~label.e-float-text,.e-bigger .e-outline.e-float-input.e-control-wrapper.e-small textarea~label.e-label-top.e-float-text,.e-bigger .e-outline.e-float-input.e-control-wrapper.e-small textarea[readonly]~label.e-float-text,.e-bigger .e-outline.e-float-input.e-control-wrapper.e-small textarea[disabled]~label.e-float-text,.e-outline.e-float-input.e-small.e-bigger.e-input-focus input~label.e-float-text,.e-bigger .e-outline.e-float-input.e-small.e-input-focus input~label.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-small.e-bigger.e-input-focus input~label.e-float-text,.e-bigger .e-outline.e-float-input.e-control-wrapper.e-small.e-input-focus input~label.e-float-text{font-size:12px}.e-outline.e-input-group.e-bigger:not(.e-float-input) .e-input,.e-bigger .e-outline.e-input-group:not(.e-float-input) .e-input,.e-outline.e-input-group.e-control-wrapper.e-bigger:not(.e-float-input) .e-input,.e-bigger .e-outline.e-input-group.e-control-wrapper:not(.e-float-input) .e-input,.e-outline.e-float-input.e-bigger input,.e-bigger .e-outline.e-float-input input,.e-outline.e-float-input.e-input-group.e-bigger input,.e-bigger .e-outline.e-float-input.e-input-group input,.e-outline.e-float-input.e-input-group.e-control-wrapper.e-bigger input,.e-bigger .e-outline.e-float-input.e-input-group.e-control-wrapper input,.e-outline.e-float-input.e-control-wrapper.e-bigger input,.e-bigger .e-outline.e-float-input.e-control-wrapper input,.e-outline.e-float-input.e-control-wrapper.e-input-group.e-bigger input,.e-bigger .e-outline.e-float-input.e-control-wrapper.e-input-group input{box-sizing:border-box;min-height:54px}.e-outline.e-input-group.e-bigger .e-clear-icon,.e-outline.e-input-group.e-control-wrapper.e-bigger .e-clear-icon,.e-outline.e-input-group .e-clear-icon.e-bigger,.e-outline.e-input-group.e-control-wrapper .e-clear-icon.e-bigger,.e-bigger .e-outline.e-input-group .e-clear-icon,.e-bigger .e-outline.e-input-group.e-control-wrapper .e-clear-icon{font-size:20px;padding:15px 16px 15px 0}.e-outline.e-input-group.e-bigger.e-float-icon-left>.e-input-group-icon,.e-outline.e-input-group.e-float-icon-left>.e-input-group-icon.e-bigger,.e-bigger .e-outline.e-input-group.e-float-icon-left>.e-input-group-icon,.e-outline.e-float-input.e-input-group.e-bigger.e-float-icon-left>.e-input-group-icon,.e-outline.e-float-input.e-input-group.e-float-icon-left>.e-input-group-icon.e-bigger,.e-bigger .e-outline.e-float-input.e-input-group.e-float-icon-left>.e-input-group-icon,.e-outline.e-input-group.e-control-wrapper.e-bigger.e-float-icon-left>.e-input-group-icon,.e-outline.e-input-group.e-control-wrapper.e-float-icon-left>.e-input-group-icon.e-bigger,.e-bigger .e-outline.e-input-group.e-control-wrapper.e-float-icon-left>.e-input-group-icon,.e-outline.e-float-input.e-input-group.e-control-wrapper.e-bigger.e-float-icon-left>.e-input-group-icon,.e-outline.e-float-input.e-input-group.e-control-wrapper.e-float-icon-left>.e-input-group-icon.e-bigger,.e-bigger .e-outline.e-float-input.e-input-group.e-control-wrapper.e-float-icon-left>.e-input-group-icon{margin-left:8px;margin-right:0}.e-outline.e-input-group.e-rtl.e-bigger.e-float-icon-left>.e-input-group-icon,.e-outline.e-input-group.e-rtl.e-float-icon-left>.e-input-group-icon.e-bigger,.e-bigger .e-outline.e-input-group.e-rtl.e-float-icon-left>.e-input-group-icon,.e-outline.e-float-input.e-input-group.e-rtl.e-bigger.e-float-icon-left>.e-input-group-icon,.e-outline.e-float-input.e-input-group.e-rtl.e-float-icon-left>.e-input-group-icon.e-bigger,.e-bigger .e-outline.e-float-input.e-input-group.e-rtl.e-float-icon-left>.e-input-group-icon,.e-outline.e-input-group.e-rtl.e-control-wrapper.e-bigger.e-float-icon-left>.e-input-group-icon,.e-outline.e-input-group.e-rtl.e-control-wrapper.e-float-icon-left>.e-input-group-icon.e-bigger,.e-bigger .e-outline.e-input-group.e-rtl.e-control-wrapper.e-float-icon-left>.e-input-group-icon,.e-outline.e-float-input.e-input-group.e-rtl.e-control-wrapper.e-bigger.e-float-icon-left>.e-input-group-icon,.e-outline.e-float-input.e-input-group.e-rtl.e-control-wrapper.e-float-icon-left>.e-input-group-icon.e-bigger,.e-bigger .e-outline.e-float-input.e-input-group.e-rtl.e-control-wrapper.e-float-icon-left>.e-input-group-icon{margin-left:0;margin-right:8px}.e-outline.e-input-group.e-bigger .e-input-group-icon,.e-outline.e-input-group .e-input-group-icon.e-bigger,.e-bigger .e-outline.e-input-group .e-input-group-icon,.e-outline.e-input-group.e-control-wrapper.e-bigger .e-input-group-icon,.e-outline.e-input-group.e-control-wrapper .e-input-group-icon.e-bigger,.e-bigger .e-outline.e-input-group.e-control-wrapper .e-input-group-icon{margin:15px 16px 15px 0}.e-outline.e-input-group.e-prepend.e-bigger .e-input-group-icon,.e-outline.e-input-group.e-prepend .e-input-group-icon.e-bigger,.e-bigger .e-outline.e-input-group.e-prepend .e-input-group-icon,.e-outline.e-input-group.e-prepend.e-control-wrapper.e-bigger .e-input-group-icon,.e-outline.e-input-group.e-prepend.e-control-wrapper .e-input-group-icon.e-bigger,.e-bigger .e-outline.e-input-group.e-prepend.e-control-wrapper .e-input-group-icon{margin:15px 0 15px 16px}input.e-input.e-bigger.e-outline,.e-bigger input.e-input.e-outline,.e-outline.e-input-group.e-bigger:not(.e-float-icon-left) input.e-input,.e-outline.e-input-group.e-control-wrapper.e-bigger:not(.e-float-icon-left) input.e-input,.e-outline.e-float-input.e-control-wrapper.e-bigger:not(.e-float-icon-left) input,.e-outline.e-float-input.e-control-wrapper:not(.e-float-icon-left) input.e-bigger,.e-outline.e-float-input.e-bigger:not(.e-float-icon-left) input,.e-outline.e-float-input:not(.e-float-icon-left) input.e-bigger,.e-outline.e-input-group:not(.e-float-icon-left) input.e-input.e-bigger,.e-outline.e-input-group.e-control-wrapper:not(.e-float-icon-left) input.e-input.e-bigger,.e-bigger .e-outline.e-float-input.e-control-wrapper:not(.e-float-icon-left) input,.e-bigger .e-outline.e-float-input:not(.e-float-icon-left) input,.e-bigger .e-outline.e-input-group.e-control-wrapper:not(.e-float-icon-left) input.e-input,.e-bigger .e-outline.e-input-group:not(.e-float-icon-left) input.e-input,.e-outline.e-input-group.e-bigger:not(.e-float-icon-left) input.e-input:focus,.e-outline.e-input-group.e-control-wrapper.e-bigger:not(.e-float-icon-left) input.e-input:focus,.e-outline.e-float-input.e-control-wrapper.e-bigger:not(.e-float-icon-left) input:focus,.e-outline.e-float-input.e-bigger.e-float-input:not(.e-float-icon-left) input:focus,.e-bigger .e-outline.e-input-group.e-float-input:not(.e-float-icon-left) input.e-input:focus,.e-bigger .e-outline.e-input-group.e-control-wrapper.e-float-input:not(.e-float-icon-left) input.e-input:focus,.e-bigger .e-outline.e-float-input.e-control-wrapper.e-float-input:not(.e-float-icon-left) input:focus,.e-bigger .e-outline.e-float-input:not(.e-float-icon-left) input:focus,.e-outline.e-float-input.e-control-wrapper.e-bigger:not(.e-float-icon-left).e-input-focus input,.e-outline.e-float-input.e-bigger.e-float-input:not(.e-float-icon-left).e-input-focus input,.e-bigger .e-outline.e-float-input.e-control-wrapper.e-float-input:not(.e-float-icon-left).e-input-focus input,.e-bigger .e-outline.e-float-input:not(.e-float-icon-left).e-input-focus input,.e-outline.e-input-group.e-bigger:not(.e-float-icon-left).e-input-focus input.e-input,.e-outline.e-input-group.e-control-wrapper.e-bigger:not(.e-float-icon-left).e-input-focus input.e-input,.e-bigger .e-outline.e-input-group.e-float-input:not(.e-float-icon-left).e-input-focus input.e-input,.e-bigger .e-outline.e-input-group.e-control-wrapper.e-float-input:not(.e-float-icon-left).e-input-focus input.e-input{padding:15px 16px}textarea.e-input.e-bigger.e-outline,.e-bigger textarea.e-input.e-outline,.e-outline.e-input-group.e-bigger:not(.e-float-icon-left) textarea.e-input,.e-outline.e-input-group.e-control-wrapper.e-bigger:not(.e-float-icon-left) textarea.e-input,.e-outline.e-float-input.e-control-wrapper.e-bigger:not(.e-float-icon-left) textarea,.e-outline.e-float-input.e-control-wrapper:not(.e-float-icon-left) textarea.e-bigger,.e-outline.e-float-input.e-bigger:not(.e-float-icon-left) textarea,.e-outline.e-float-input:not(.e-float-icon-left) textarea.e-bigger,.e-outline.e-input-group:not(.e-float-icon-left) textarea.e-input.e-bigger,.e-outline.e-input-group.e-control-wrapper:not(.e-float-icon-left) textarea.e-input.e-bigger,.e-bigger .e-outline.e-float-input.e-control-wrapper:not(.e-float-icon-left) textarea,.e-bigger .e-outline.e-float-input:not(.e-float-icon-left) textarea,.e-bigger .e-outline.e-input-group.e-control-wrapper:not(.e-float-icon-left) textarea.e-input,.e-bigger .e-outline.e-input-group:not(.e-float-icon-left) textarea.e-input,.e-outline.e-input-group.e-bigger:not(.e-float-icon-left) textarea.e-input:focus,.e-outline.e-input-group.e-control-wrapper.e-bigger:not(.e-float-icon-left) textarea.e-input:focus,.e-outline.e-float-input.e-control-wrapper.e-bigger:not(.e-float-icon-left) textarea:focus,.e-outline.e-float-input.e-bigger.e-float-input:not(.e-float-icon-left) textarea:focus,.e-bigger .e-outline.e-input-group.e-float-input:not(.e-float-icon-left) textarea.e-input:focus,.e-bigger .e-outline.e-input-group.e-control-wrapper.e-float-input:not(.e-float-icon-left) textarea.e-input:focus,.e-bigger .e-outline.e-float-input.e-control-wrapper.e-float-input:not(.e-float-icon-left) textarea:focus,.e-bigger .e-outline.e-float-input:not(.e-float-icon-left) textarea:focus{margin:8px 0 1px;padding:0 16px 16px}.e-outline.e-input-group.e-bigger.e-small:not(.e-float-input) .e-input,.e-bigger .e-outline.e-input-group.e-small:not(.e-float-input) .e-input .e-small .e-input-group.e-bigger:not(.e-float-input) .e-input,.e-outline.e-input-group.e-control-wrapper.e-bigger.e-small:not(.e-float-input) .e-input,.e-bigger .e-outline.e-input-group.e-control-wrapper.e-small:not(.e-float-input) .e-input,.e-small .e-outline.e-input-group.e-control-wrapper.e-bigger:not(.e-float-input) .e-input,.e-outline.e-float-input.e-bigger.e-small input,.e-bigger .e-outline.e-float-input.e-small input,.e-small .e-outline.e-float-input.e-bigger input,.e-outline.e-float-input.e-input-group.e-bigger.e-small input,.e-bigger .e-outline.e-float-input.e-input-group.e-small input,.e-small .e-outline.e-float-input.e-input-group.e-bigger input,.e-outline.e-float-input.e-input-group.e-control-wrapper.e-bigger.e-small input,.e-bigger .e-outline.e-float-input.e-input-group.e-control-wrapper.e-small input,.e-small .e-outline.e-float-input.e-input-group.e-control-wrapper.e-bigger input,.e-outline.e-float-input.e-control-wrapper.e-bigger.e-small input,.e-bigger .e-outline.e-float-input.e-control-wrapper.e-small input,.e-small .e-outline.e-float-input.e-control-wrapper.e-bigger input,.e-outline.e-float-input.e-control-wrapper.e-input-group.e-bigger.e-small input,.e-bigger .e-outline.e-float-input.e-control-wrapper.e-input-group.e-small input,.e-small .e-outline.e-float-input.e-control-wrapper.e-input-group.e-bigger input{box-sizing:border-box;min-height:38px}input.e-input.e-bigger.e-small.e-outline,.e-bigger input.e-input.e-small.e-outline,.e-outline.e-input-group.e-small.e-bigger:not(.e-float-icon-left) input.e-input,.e-outline.e-input-group.e-control-wrapper.e-small.e-bigger:not(.e-float-icon-left) input.e-input,.e-outline.e-input-group.e-small:not(.e-float-icon-left) input.e-input.e-bigger,.e-outline.e-input-group.e-control-wrapper.e-small:not(.e-float-icon-left) input.e-input.e-bigger,.e-bigger .e-outline.e-input-group.e-small:not(.e-float-icon-left) input.e-input,.e-bigger .e-outline.e-input-group.e-control-wrapper.e-small:not(.e-float-icon-left) input.e-input,.e-outline.e-float-input.e-small.e-bigger:not(.e-float-icon-left) input,.e-outline.e-float-input.e-small:not(.e-float-icon-left) input.e-bigger,.e-bigger .e-outline.e-float-input.e-small:not(.e-float-icon-left) input,.e-outline.e-float-input.e-control-wrapper.e-small.e-bigger:not(.e-float-icon-left) input,.e-outline.e-float-input.e-control-wrapper.e-small:not(.e-float-icon-left) input.e-bigger,.e-bigger .e-outline.e-float-input.e-control-wrapper.e-small:not(.e-float-icon-left) input,.e-bigger .e-outline.e-input-group.e-small:not(.e-float-icon-left) input.e-input:focus,.e-bigger .e-outline.e-input-group.e-control-wrapper.e-small:not(.e-float-icon-left) input.e-input:focus,.e-bigger .e-outline.e-float-input.e-control-wrapper.e-small:not(.e-float-icon-left) input:focus,.e-bigger .e-outline.e-float-input.e-small:not(.e-float-icon-left) input:focus,.e-small .e-outline.e-input-group.e-bigger:not(.e-float-icon-left) input.e-input:focus,.e-small .e-outline.e-input-group.e-control-wrapper.e-bigger:not(.e-float-icon-left) input.e-input:focus,.e-small .e-outline.e-float-input.e-control-wrapper.e-bigger:not(.e-float-icon-left) input:focus,.e-small .e-outline.e-float-input.e-bigger:not(.e-float-icon-left) input:focus,.e-outline.e-input-group.e-bigger.e-small:not(.e-float-icon-left) input.e-input:focus,.e-outline.e-input-group.e-control-wrapper.e-bigger.e-small:not(.e-float-icon-left) input.e-input:focus,.e-outline.e-float-input.e-control-wrapper.e-bigger.e-small:not(.e-float-icon-left) input:focus,.e-outline.e-float-input.e-bigger.e-small:not(.e-float-icon-left) input:focus,.e-bigger .e-outline.e-float-input.e-control-wrapper.e-small:not(.e-float-icon-left).e-input-focus input,.e-bigger .e-outline.e-float-input.e-small:not(.e-float-icon-left).e-input-focus input,.e-small .e-outline.e-float-input.e-control-wrapper.e-bigger:not(.e-float-icon-left).e-input-focus input,.e-small .e-outline.e-float-input.e-bigger:not(.e-float-icon-left).e-input-focus input,.e-outline.e-float-input.e-control-wrapper.e-bigger.e-small:not(.e-float-icon-left).e-input-focus input,.e-outline.e-float-input.e-bigger.e-small:not(.e-float-icon-left).e-input-focus input,.e-bigger .e-outline.e-input-group.e-small:not(.e-float-icon-left).e-input-focus input.e-input,.e-bigger .e-outline.e-input-group.e-control-wrapper.e-small:not(.e-float-icon-left).e-input-focus input.e-input,.e-small .e-outline.e-input-group.e-bigger:not(.e-float-icon-left).e-input-focus input.e-input,.e-small .e-outline.e-input-group.e-control-wrapper.e-bigger:not(.e-float-icon-left).e-input-focus input.e-input,.e-outline.e-input-group.e-bigger.e-small:not(.e-float-icon-left).e-input-focus input.e-input,.e-outline.e-input-group.e-control-wrapper.e-bigger.e-small:not(.e-float-icon-left).e-input-focus input.e-input{padding:10px 12px 9px}textarea.e-input.e-bigger.e-small.e-outline,.e-bigger textarea.e-input.e-small.e-outline,.e-outline.e-input-group.e-small.e-bigger:not(.e-float-icon-left) textarea.e-input,.e-outline.e-input-group.e-control-wrapper.e-small.e-bigger:not(.e-float-icon-left) textarea.e-input,.e-outline.e-input-group.e-small:not(.e-float-icon-left) textarea.e-input.e-bigger,.e-outline.e-input-group.e-control-wrapper.e-small:not(.e-float-icon-left) textarea.e-input.e-bigger,.e-bigger .e-outline.e-input-group.e-small:not(.e-float-icon-left) textarea.e-input,.e-bigger .e-outline.e-input-group.e-control-wrapper.e-small:not(.e-float-icon-left) textarea.e-input,.e-outline.e-float-input.e-small.e-bigger:not(.e-float-icon-left) textarea,.e-outline.e-float-input.e-small:not(.e-float-icon-left) textarea.e-bigger,.e-bigger .e-outline.e-float-input.e-small:not(.e-float-icon-left) textarea,.e-outline.e-float-input.e-control-wrapper.e-small.e-bigger:not(.e-float-icon-left) textarea,.e-outline.e-float-input.e-control-wrapper.e-small:not(.e-float-icon-left) textarea.e-bigger,.e-bigger .e-outline.e-float-input.e-control-wrapper.e-small:not(.e-float-icon-left) textarea,.e-bigger .e-outline.e-input-group.e-small:not(.e-float-icon-left) textarea.e-input:focus,.e-bigger .e-outline.e-input-group.e-control-wrapper.e-small:not(.e-float-icon-left) textarea.e-input:focus,.e-bigger .e-outline.e-float-input.e-control-wrapper.e-small:not(.e-float-icon-left) textarea:focus,.e-bigger .e-outline.e-float-input.e-small:not(.e-float-icon-left) textarea:focus,.e-small .e-outline.e-input-group.e-bigger:not(.e-float-icon-left) textarea.e-input:focus,.e-small .e-outline.e-input-group.e-control-wrapper.e-bigger:not(.e-float-icon-left) textarea.e-input:focus,.e-small .e-outline.e-float-input.e-control-wrapper.e-bigger:not(.e-float-icon-left) textarea:focus,.e-small .e-outline.e-float-input.e-bigger:not(.e-float-icon-left) textarea:focus,.e-outline.e-input-group.e-bigger.e-small:not(.e-float-icon-left) textarea.e-input:focus,.e-outline.e-input-group.e-control-wrapper.e-bigger.e-small:not(.e-float-icon-left) textarea.e-input:focus,.e-outline.e-float-input.e-control-wrapper.e-bigger.e-small:not(.e-float-icon-left) textarea:focus,.e-outline.e-float-input.e-bigger.e-small:not(.e-float-icon-left) textarea:focus{box-sizing:border-box;margin:8px 0 1px;padding:0 12px 12px}.e-outline.e-input-group.e-small.e-bigger .e-clear-icon,.e-outline.e-input-group.e-small .e-clear-icon.e-bigger,.e-bigger .e-outline.e-input-group.e-small .e-clear-icon,.e-outline.e-input-group.e-control-wrapper.e-small.e-bigger .e-clear-icon,.e-outline.e-input-group.e-control-wrapper.e-small .e-clear-icon.e-bigger,.e-bigger .e-outline.e-input-group.e-control-wrapper.e-small .e-clear-icon{font-size:18px;padding:9px 12px 9px 0}.e-outline.e-input-group.e-small.e-bigger.e-float-icon-left>.e-input-group-icon,.e-outline.e-input-group.e-small.e-float-icon-left>.e-input-group-icon.e-bigger,.e-bigger .e-outline.e-input-group.e-small.e-float-icon-left>.e-input-group-icon,.e-outline.e-float-input.e-input-group.e-small.e-bigger.e-float-icon-left>.e-input-group-icon,.e-outline.e-float-input.e-input-group.e-small.e-float-icon-left>.e-input-group-icon.e-bigger,.e-bigger .e-outline.e-input-group.e-float-input.e-small.e-float-icon-left>.e-input-group-icon,.e-outline.e-input-group.e-control-wrapper.e-small.e-bigger.e-float-icon-left>.e-input-group-icon,.e-outline.e-input-group.e-control-wrapper.e-small.e-float-icon-left>.e-input-group-icon.e-bigger,.e-bigger .e-outline.e-input-group.e-control-wrapper.e-small.e-float-icon-left>.e-input-group-icon,.e-outline.e-float-input.e-control-wrapper.e-input-group.e-small.e-bigger.e-float-icon-left>.e-input-group-icon,.e-outline.e-float-input.e-control-wrapper.e-input-group.e-small.e-float-icon-left>.e-input-group-icon.e-bigger,.e-bigger .e-outline.e-input-group.e-control-wrapper.e-float-input.e-small.e-float-icon-left>.e-input-group-icon{margin-left:0;margin-right:8px}.e-outline.e-input-group.e-small.e-bigger .e-input-group-icon,.e-outline.e-input-group.e-small .e-input-group-icon.e-bigger,.e-outline.e-input-group.e-control-wrapper.e-small.e-bigger .e-input-group-icon,.e-outline.e-input-group.e-control-wrapper.e-small .e-input-group-icon.e-bigger,.e-bigger .e-outline.e-input-group.e-small .e-input-group-icon,.e-bigger .e-outline.e-input-group.e-control-wrapper.e-small .e-input-group-icon{margin:9px 12px 9px 0}.e-outline.e-input-group.e-prepend.e-small.e-bigger .e-input-group-icon,.e-outline.e-input-group.e-prepend.e-small .e-input-group-icon.e-bigger,.e-outline.e-input-group.e-prepend.e-control-wrapper.e-small.e-bigger .e-input-group-icon,.e-outline.e-input-group.e-prepend.e-control-wrapper.e-small .e-input-group-icon.e-bigger,.e-bigger .e-outline.e-input-group.e-prepend.e-small .e-input-group-icon,.e-bigger .e-outline.e-input-group.e-prepend.e-control-wrapper.e-small .e-input-group-icon{margin:9px 0 9px 12px}.e-outline.e-float-input.e-bigger:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-outline.e-float-input.e-bigger.e-control-wrapper:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger .e-outline.e-float-input:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-outline.e-float-input.e-small.e-bigger:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger .e-outline.e-float-input.e-small:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-outline.e-float-input.e-control-wrapper.e-bigger:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger .e-outline.e-float-input.e-control-wrapper:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-outline.e-float-input.e-control-wrapper.e-small.e-bigger:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger .e-outline.e-float-input.e-control-wrapper.e-small:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-outline.e-float-input.e-bigger textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-outline.e-float-input.e-bigger.e-control-wrapper textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger .e-outline.e-float-input textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-outline.e-float-input.e-small.e-bigger textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger .e-outline.e-float-input.e-small textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-outline.e-float-input.e-control-wrapper.e-bigger textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger .e-outline.e-float-input.e-control-wrapper textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-outline.e-float-input.e-control-wrapper.e-small.e-bigger textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger .e-outline.e-float-input.e-control-wrapper.e-small textarea:not(:focus):valid~label.e-float-text.e-label-bottom{box-sizing:border-box;display:flex;left:0;line-height:13px;position:absolute;top:-7px;transform:translateZ(0) scale(1);transition:color .2s,font-size .2s,line-height .2s}.e-outline.e-float-input.e-bigger:not(.e-error):not(.e-valid-input):not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-outline.e-float-input.e-bigger.e-control-wrapper:not(.e-error):not(.e-valid-input):not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger .e-outline.e-float-input:not(.e-error):not(.e-valid-input):not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger.e-outline.e-float-input:not(.e-error):not(.e-valid-input):not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-outline.e-float-input.e-control-wrapper.e-bigger:not(.e-error):not(.e-valid-input):not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger .e-outline.e-float-input.e-control-wrapper:not(.e-error):not(.e-valid-input):not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger.e-outline.e-float-input.e-control-wrapper:not(.e-error):not(.e-valid-input):not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger.e-outline:not(.e-valid-input):not(.e-valid-input):not(.e-input-focus) input:not(:focus):not(:valid)~label.e-float-text,.e-bigger .e-outline:not(.e-valid-input):not(.e-valid-input):not(.e-input-focus) input:not(:focus):not(:valid)~label.e-float-text,.e-bigger.e-outline.e-float-input:not(.e-valid-input):not(.e-input-focus) input:not(:focus):not(:valid):not(.e-valid-input)~label.e-float-text,.e-bigger .e-outline.e-float-input:not(.e-valid-input):not(.e-input-focus) input:not(:focus):not(:valid):not(.e-valid-input)~label.e-float-text,.e-bigger.e-outline.e-float-input.e-control-wrapper:not(.e-valid-input):not(.e-input-focus) input:not(:focus):not(:valid):not(.e-valid-input)~label.e-float-text,.e-bigger .e-outline.e-float-input.e-control-wrapper:not(.e-valid-input):not(.e-input-focus) input:not(:focus):not(:valid):not(.e-valid-input)~label.e-float-text{line-height:70px}.e-outline.e-float-input.e-bigger:not(.e-error):not(.e-valid-input):not(.e-input-focus) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-outline.e-float-input.e-bigger.e-control-wrapper:not(.e-error):not(.e-valid-input):not(.e-input-focus) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger .e-outline.e-float-input:not(.e-error):not(.e-valid-input):not(.e-input-focus) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger.e-outline.e-float-input:not(.e-error):not(.e-valid-input):not(.e-input-focus) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-outline.e-float-input.e-control-wrapper.e-bigger:not(.e-error):not(.e-valid-input):not(.e-input-focus) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger .e-outline.e-float-input.e-control-wrapper:not(.e-error):not(.e-valid-input):not(.e-input-focus) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger.e-outline.e-float-input.e-control-wrapper:not(.e-error):not(.e-valid-input):not(.e-input-focus) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger.e-outline.e-float-input:not(.e-valid-input):not(.e-input-focus) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger.e-outline.e-float-input.e-control-wrapper:not(.e-valid-input):not(.e-input-focus) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger.e-outline.e-float-input:not(.e-valid-input):not(.e-input-focus) textarea:valid~label.e-float-text.e-label-bottom,.e-bigger.e-outline.e-float-input.e-control-wrapper:not(.e-valid-input):not(.e-input-focus) textarea:valid~label.e-float-text.e-label-bottom,.e-bigger .e-outline.e-float-input:not(.e-valid-input):not(.e-input-focus) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger .e-outline.e-float-input.e-control-wrapper:not(.e-valid-input):not(.e-input-focus) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger .e-outline.e-float-input:not(.e-valid-input):not(.e-input-focus) textarea:valid~label.e-float-text.e-label-bottom,.e-bigger .e-outline.e-float-input.e-control-wrapper:not(.e-valid-input):not(.e-input-focus) textarea:valid~label.e-float-text.e-label-bottom,.e-bigger.e-outline:not(.e-valid-input):not(.e-valid-input):not(.e-input-focus) textarea:not(:focus):not(:valid)~label.e-float-text,.e-bigger .e-outline:not(.e-valid-input):not(.e-valid-input):not(.e-input-focus) textarea:not(:focus):not(:valid)~label.e-float-text,.e-bigger.e-outline.e-float-input:not(.e-valid-input):not(.e-input-focus) textarea:not(:focus):not(:valid):not(.e-valid-input)~label.e-float-text,.e-bigger .e-outline.e-float-input:not(.e-valid-input):not(.e-input-focus) textarea:not(:focus):not(:valid):not(.e-valid-input)~label.e-float-text,.e-bigger.e-outline.e-float-input.e-control-wrapper:not(.e-valid-input):not(.e-input-focus) textarea:not(:focus):not(:valid):not(.e-valid-input)~label.e-float-text,.e-bigger .e-outline.e-float-input.e-control-wrapper:not(.e-valid-input):not(.e-input-focus) textarea:not(:focus):not(:valid):not(.e-valid-input)~label.e-float-text,.e-outline.e-float-input.e-bigger:not(.e-error):not(.e-valid-input) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-outline.e-float-input.e-bigger.e-control-wrapper:not(.e-error):not(.e-valid-input) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger .e-outline.e-float-input:not(.e-error):not(.e-valid-input) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger.e-outline.e-float-input:not(.e-error):not(.e-valid-input) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-outline.e-float-input.e-control-wrapper.e-bigger:not(.e-error):not(.e-valid-input) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger .e-outline.e-float-input.e-control-wrapper:not(.e-error):not(.e-valid-input) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger.e-outline.e-float-input.e-control-wrapper:not(.e-error):not(.e-valid-input) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger.e-outline:not(.e-valid-input):not(.e-valid-input) textarea:not(:focus):not(:valid)~label.e-float-text,.e-bigger .e-outline:not(.e-valid-input):not(.e-valid-input) textarea:not(:focus):not(:valid)~label.e-float-text,.e-bigger.e-outline.e-float-input:not(.e-valid-input) textarea:not(:focus):not(:valid):not(.e-valid-input)~label.e-float-text,.e-bigger .e-outline.e-float-input:not(.e-valid-input) textarea:not(:focus):not(:valid):not(.e-valid-input)~label.e-float-text,.e-bigger.e-outline.e-float-input.e-control-wrapper:not(.e-valid-input) textarea:not(:focus):not(:valid):not(.e-valid-input)~label.e-float-text,.e-bigger .e-outline.e-float-input.e-control-wrapper:not(.e-valid-input) textarea:not(:focus):not(:valid):not(.e-valid-input)~label.e-float-text{line-height:66px}.e-small.e-bigger.e-outline.e-float-input:not(.e-error):not(.e-valid-input):not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small.e-bigger.e-outline.e-float-input.e-control-wrapper:not(.e-error):not(.e-valid-input):not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small.e-bigger.e-outline:not(.e-valid-input):not(.e-valid-input):not(.e-input-focus) input:not(:focus):not(:valid)~label.e-float-text,.e-small.e-bigger.e-outline.e-float-input:not(.e-valid-input):not(.e-input-focus) input:not(:focus):not(:valid):not(.e-valid-input)~label.e-float-text,.e-small.e-bigger.e-outline.e-float-input.e-control-wrapper:not(.e-valid-input):not(.e-input-focus) input:not(:focus):not(:valid):not(.e-valid-input)~label.e-float-text,.e-small .e-bigger.e-outline.e-float-input:not(.e-error):not(.e-valid-input):not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small .e-bigger.e-outline.e-float-input.e-control-wrapper:not(.e-error):not(.e-valid-input):not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small .e-bigger.e-outline:not(.e-valid-input):not(.e-valid-input):not(.e-input-focus) input:not(:focus):not(:valid)~label.e-float-text,.e-small .e-bigger.e-outline.e-float-input:not(.e-valid-input):not(.e-input-focus) input:not(:focus):not(:valid):not(.e-valid-input)~label.e-float-text,.e-small .e-bigger.e-outline.e-float-input.e-control-wrapper:not(.e-valid-input):not(.e-input-focus) input:not(:focus):not(:valid):not(.e-valid-input)~label.e-float-text,.e-bigger .e-small.e-outline.e-float-input:not(.e-error):not(.e-valid-input):not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger .e-small.e-outline.e-float-input.e-control-wrapper:not(.e-error):not(.e-valid-input):not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger .e-small.e-outline:not(.e-valid-input):not(.e-valid-input):not(.e-input-focus) input:not(:focus):not(:valid)~label.e-float-text,.e-bigger .e-small.e-outline.e-float-input:not(.e-valid-input):not(.e-input-focus) input:not(:focus):not(:valid):not(.e-valid-input)~label.e-float-text,.e-bigger .e-small.e-outline.e-float-input.e-control-wrapper:not(.e-valid-input):not(.e-input-focus) input:not(:focus):not(:valid):not(.e-valid-input)~label.e-float-text,.e-outline.e-float-input.e-small.e-bigger:not(.e-error):not(.e-valid-input):not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger .e-outline.e-float-input.e-small:not(.e-error):not(.e-valid-input):not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-outline.e-float-input.e-control-wrapper.e-small.e-bigger:not(.e-error):not(.e-valid-input):not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger .e-outline.e-float-input.e-control-wrapper.e-small:not(.e-error):not(.e-valid-input):not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom{line-height:53px}.e-small.e-bigger.e-outline.e-float-input:not(.e-error):not(.e-valid-input):not(.e-input-focus) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small.e-bigger.e-outline.e-float-input.e-control-wrapper:not(.e-error):not(.e-valid-input):not(.e-input-focus) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small.e-bigger.e-outline:not(.e-valid-input):not(.e-valid-input):not(.e-input-focus) textarea:not(:focus):not(:valid)~label.e-float-text,.e-small.e-bigger.e-outline.e-float-input:not(.e-valid-input):not(.e-input-focus) textarea:not(:focus):not(:valid):not(.e-valid-input)~label.e-float-text,.e-small.e-bigger.e-outline.e-float-input.e-control-wrapper:not(.e-valid-input):not(.e-input-focus) textarea:not(:focus):not(:valid):not(.e-valid-input)~label.e-float-text,.e-small .e-bigger.e-outline.e-float-input:not(.e-error):not(.e-valid-input):not(.e-input-focus) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small .e-bigger.e-outline.e-float-input.e-control-wrapper:not(.e-error):not(.e-valid-input):not(.e-input-focus) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small .e-bigger.e-outline:not(.e-valid-input):not(.e-valid-input):not(.e-input-focus) textarea:not(:focus):not(:valid)~label.e-float-text,.e-small .e-bigger.e-outline.e-float-input:not(.e-valid-input):not(.e-input-focus) textarea:not(:focus):not(:valid):not(.e-valid-input)~label.e-float-text,.e-small .e-bigger.e-outline.e-float-input.e-control-wrapper:not(.e-valid-input):not(.e-input-focus) textarea:not(:focus):not(:valid):not(.e-valid-input)~label.e-float-text,.e-bigger .e-small.e-outline.e-float-input:not(.e-error):not(.e-valid-input):not(.e-input-focus) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger .e-small.e-outline.e-float-input.e-control-wrapper:not(.e-error):not(.e-valid-input):not(.e-input-focus) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger .e-small.e-outline:not(.e-valid-input):not(.e-valid-input):not(.e-input-focus) textarea:not(:focus):not(:valid)~label.e-float-text,.e-bigger .e-small.e-outline.e-float-input:not(.e-valid-input):not(.e-input-focus) textarea:not(:focus):not(:valid):not(.e-valid-input)~label.e-float-text,.e-bigger .e-small.e-outline.e-float-input.e-control-wrapper:not(.e-valid-input):not(.e-input-focus) textarea:not(:focus):not(:valid):not(.e-valid-input)~label.e-float-text,.e-outline.e-float-input.e-small.e-bigger:not(.e-error):not(.e-valid-input):not(.e-input-focus) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger .e-outline.e-float-input.e-small:not(.e-error):not(.e-valid-input):not(.e-input-focus) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-outline.e-float-input.e-control-wrapper.e-small.e-bigger:not(.e-error):not(.e-valid-input):not(.e-input-focus) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger .e-outline.e-float-input.e-control-wrapper.e-small:not(.e-error):not(.e-valid-input):not(.e-input-focus) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger.e-small.e-outline.e-float-input:not(.e-valid-input):not(.e-input-focus) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger.e-small.e-outline.e-float-input.e-control-wrapper:not(.e-valid-input):not(.e-input-focus) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger.e-small.e-outline.e-float-input:not(.e-valid-input):not(.e-input-focus) textarea:valid~label.e-float-text.e-label-bottom,.e-bigger.e-small.e-outline.e-float-input.e-control-wrapper:not(.e-valid-input):not(.e-input-focus) textarea:valid~label.e-float-text.e-label-bottom,.e-bigger.e-small .e-outline.e-float-input:not(.e-valid-input):not(.e-input-focus) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger.e-small .e-outline.e-float-input.e-control-wrapper:not(.e-valid-input):not(.e-input-focus) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger.e-small .e-outline.e-float-input:not(.e-valid-input):not(.e-input-focus) textarea:valid~label.e-float-text.e-label-bottom,.e-bigger.e-small .e-outline.e-float-input.e-control-wrapper:not(.e-valid-input):not(.e-input-focus) textarea:valid~label.e-float-text.e-label-bottom,.e-small.e-bigger.e-outline.e-float-input:not(.e-error):not(.e-valid-input) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small.e-bigger.e-outline.e-float-input.e-control-wrapper:not(.e-error):not(.e-valid-input) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small.e-bigger.e-outline:not(.e-valid-input):not(.e-valid-input) textarea:not(:focus):not(:valid)~label.e-float-text,.e-small.e-bigger.e-outline.e-float-input:not(.e-valid-input) textarea:not(:focus):not(:valid):not(.e-valid-input)~label.e-float-text,.e-small.e-bigger.e-outline.e-float-input.e-control-wrapper:not(.e-valid-input) textarea:not(:focus):not(:valid):not(.e-valid-input)~label.e-float-text,.e-small .e-bigger.e-outline.e-float-input:not(.e-error):not(.e-valid-input) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small .e-bigger.e-outline.e-float-input.e-control-wrapper:not(.e-error):not(.e-valid-input) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small .e-bigger.e-outline:not(.e-valid-input):not(.e-valid-input) textarea:not(:focus):not(:valid)~label.e-float-text,.e-small .e-bigger.e-outline.e-float-input:not(.e-valid-input) textarea:not(:focus):not(:valid):not(.e-valid-input)~label.e-float-text,.e-small .e-bigger.e-outline.e-float-input.e-control-wrapper:not(.e-valid-input) textarea:not(:focus):not(:valid):not(.e-valid-input)~label.e-float-text,.e-bigger .e-small.e-outline.e-float-input:not(.e-error):not(.e-valid-input) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger .e-small.e-outline.e-float-input.e-control-wrapper:not(.e-error):not(.e-valid-input) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger .e-small.e-outline:not(.e-valid-input):not(.e-valid-input) textarea:not(:focus):not(:valid)~label.e-float-text,.e-bigger .e-small.e-outline.e-float-input:not(.e-valid-input) textarea:not(:focus):not(:valid):not(.e-valid-input)~label.e-float-text,.e-bigger .e-small.e-outline.e-float-input.e-control-wrapper:not(.e-valid-input) textarea:not(:focus):not(:valid):not(.e-valid-input)~label.e-float-text,.e-outline.e-float-input.e-small.e-bigger:not(.e-error):not(.e-valid-input) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger .e-outline.e-float-input.e-small:not(.e-error):not(.e-valid-input) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-outline.e-float-input.e-control-wrapper.e-small.e-bigger:not(.e-error):not(.e-valid-input) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger .e-outline.e-float-input.e-control-wrapper.e-small:not(.e-error):not(.e-valid-input) textarea:not(:focus):valid~label.e-float-text.e-label-bottom{line-height:60px}.e-bigger.e-outline label.e-float-text:before,.e-bigger.e-outline label.e-float-text:after,.e-bigger.e-outline.e-float-input label.e-float-text:before,.e-bigger.e-outline.e-float-input label.e-float-text:after,.e-bigger.e-outline.e-float-input.e-control-wrapper label.e-float-text:before,.e-bigger.e-outline.e-float-input.e-control-wrapper label.e-float-text:after,.e-bigger .e-outline label.e-float-text:before,.e-bigger .e-outline label.e-float-text:after,.e-bigger .e-outline.e-float-input label.e-float-text:before,.e-bigger .e-outline.e-float-input label.e-float-text:after,.e-bigger .e-outline.e-float-input.e-control-wrapper label.e-float-text:before,.e-bigger .e-outline.e-float-input.e-control-wrapper label.e-float-text:after{min-width:13px}.e-bigger.e-small.e-outline label.e-float-text:before,.e-bigger.e-small.e-outline label.e-float-text:after,.e-bigger.e-small.e-outline.e-float-input label.e-float-text:before,.e-bigger.e-small.e-outline.e-float-input label.e-float-text:after,.e-bigger.e-small.e-outline.e-float-input.e-control-wrapper label.e-float-text:before,.e-bigger.e-small.e-outline.e-float-input.e-control-wrapper label.e-float-text:after,.e-bigger.e-small .e-outline label.e-float-text:before,.e-bigger.e-small .e-outline label.e-float-text:after,.e-bigger.e-small .e-outline.e-float-input label.e-float-text:before,.e-bigger.e-small .e-outline.e-float-input label.e-float-text:after,.e-bigger.e-small .e-outline.e-float-input.e-control-wrapper label.e-float-text:before,.e-bigger.e-small .e-outline.e-float-input.e-control-wrapper label.e-float-text:after{min-width:9px}.e-rtl .e-outline.e-input-group.e-bigger .e-input-group-icon+.e-input-group-icon:last-child,.e-rtl.e-outline.e-input-group.e-bigger .e-input-group-icon+.e-input-group-icon:last-child,.e-rtl .e-outline.e-input-group .e-input-group-icon.e-bigger+.e-input-group-icon.e-bigger:last-child,.e-rtl.e-outline.e-input-group .e-input-group-icon.e-bigger+.e-input-group-icon.e-bigger:last-child,.e-bigger .e-rtl.e-outline.e-input-group .e-input-group-icon+.e-input-group-icon:last-child,.e-bigger.e-rtl .e-outline.e-input-group .e-input-group-icon+.e-input-group-icon:last-child,.e-rtl.e-outline.e-input-group.e-small.e-bigger .e-input-group-icon+.e-input-group-icon:last-child,.e-rtl .e-outline.e-input-group.e-small.e-bigger .e-input-group-icon+.e-input-group-icon:last-child,.e-rtl.e-outline.e-input-group.e-small .e-input-group-icon.e-bigger+.e-input-group-icon.e-bigger:last-child,.e-rtl .e-outline.e-input-group.e-small .e-input-group-icon.e-bigger+.e-input-group-icon.e-bigger:last-child,.e-rtl.e-outline.e-input-group.e-control-wrapper.e-bigger .e-input-group-icon+.e-input-group-icon:last-child,.e-rtl .e-outline.e-input-group.e-control-wrapper.e-bigger .e-input-group-icon+.e-input-group-icon:last-child,.e-rtl.e-outline.e-input-group.e-control-wrapper .e-input-group-icon.e-bigger+.e-input-group-icon.e-bigger:last-child,.e-rtl .e-outline.e-input-group.e-control-wrapper .e-input-group-icon.e-bigger+.e-input-group-icon.e-bigger:last-child,.e-rtl.e-outline.e-input-group.e-control-wrapper.e-small.e-bigger .e-input-group-icon+.e-input-group-icon:last-child,.e-rtl .e-outline.e-input-group.e-control-wrapper.e-small.e-bigger .e-input-group-icon+.e-input-group-icon:last-child,.e-rtl.e-outline.e-input-group.e-control-wrapper.e-small .e-input-group-icon.e-bigger+.e-input-group-icon.e-bigger:last-child,.e-rtl .e-outline.e-input-group.e-control-wrapper.e-small .e-input-group-icon.e-bigger+.e-input-group-icon.e-bigger:last-child,.e-rtl.e-bigger .e-outline.e-input-group.e-control-wrapper.e-small .e-input-group-icon+.e-input-group-icon:last-child,.e-bigger .e-rtl.e-outline.e-input-group.e-control-wrapper.e-small .e-input-group-icon+.e-input-group-icon:last-child,.e-rtl.e-bigger .e-outline.e-input-group.e-small .e-input-group-icon+.e-input-group-icon:last-child .e-bigger .e-rtl.e-outline.e-input-group.e-small .e-input-group-icon+.e-input-group-icon:last-child{margin-right:0}.e-rtl.e-outline.e-input-group.e-bigger .e-clear-icon,.e-rtl.e-outline.e-input-group.e-control-wrapper.e-bigger .e-clear-icon,.e-rtl.e-outline.e-input-group .e-clear-icon.e-bigger,.e-rtl.e-outline.e-input-group.e-control-wrapper .e-clear-icon.e-bigger,.e-bigger .e-rtl.e-outline.e-input-group .e-clear-icon,.e-bigger .e-rtl.e-outline.e-input-group.e-control-wrapper .e-clear-icon .e-rtl .e-outline.e-input-group.e-bigger .e-clear-icon,.e-rtl .e-outline.e-input-group.e-control-wrapper.e-bigger .e-clear-icon,.e-rtl .e-outline.e-input-group .e-clear-icon.e-bigger,.e-rtl .e-outline.e-input-group.e-control-wrapper .e-clear-icon.e-bigger,.e-bigger.e-rtl .e-outline.e-input-group .e-clear-icon,.e-bigger.e-rtl .e-outline.e-input-group.e-control-wrapper .e-clear-icon{padding-left:16px;padding-right:0}.e-rtl.e-outline.e-input-group.e-bigger .e-input-group-icon,.e-rtl.e-outline.e-input-group .e-input-group-icon.e-bigger,.e-bigger .e-rtl.e-outline.e-input-group .e-input-group-icon,.e-rtl.e-outline.e-input-group.e-control-wrapper.e-bigger .e-input-group-icon,.e-rtl.e-outline.e-input-group.e-control-wrapper .e-input-group-icon.e-bigger,.e-bigger .e-rtl.e-outline.e-input-group.e-control-wrapper .e-input-group-icon,.e-rtl .e-outline.e-input-group.e-bigger .e-input-group-icon,.e-rtl .e-outline.e-input-group .e-input-group-icon.e-bigger,.e-bigger.e-rtl .e-outline.e-input-group .e-input-group-icon,.e-rtl .e-outline.e-input-group.e-control-wrapper.e-bigger .e-input-group-icon,.e-rtl .e-outline.e-input-group.e-control-wrapper .e-input-group-icon.e-bigger,.e-bigger.e-rtl .e-outline.e-input-group.e-control-wrapper .e-input-group-icon,.e-rtl .e-outline.e-input-group.e-bigger .e-input-group-icon+.e-input-group-icon:last-child,.e-rtl.e-outline.e-input-group.e-bigger .e-input-group-icon+.e-input-group-icon:last-child,.e-rtl .e-outline.e-input-group .e-input-group-icon.e-bigger+.e-input-group-icon.e-bigger:last-child,.e-rtl.e-outline.e-input-group .e-input-group-icon.e-bigger+.e-input-group-icon.e-bigger:last-child,.e-bigger .e-rtl.e-outline.e-input-group .e-input-group-icon+.e-input-group-icon:last-child,.e-bigger.e-rtl .e-outline.e-input-group .e-input-group-icon+.e-input-group-icon:last-child,.e-rtl.e-outline.e-input-group.e-control-wrapper.e-bigger .e-input-group-icon+.e-input-group-icon:last-child,.e-rtl .e-outline.e-input-group.e-control-wrapper.e-bigger .e-input-group-icon+.e-input-group-icon:last-child,.e-rtl.e-outline.e-input-group.e-control-wrapper .e-input-group-icon.e-bigger+.e-input-group-icon.e-bigger:last-child,.e-rtl .e-outline.e-input-group.e-control-wrapper .e-input-group-icon.e-bigger+.e-input-group-icon.e-bigger:last-child{margin-left:16px;margin-right:0}.e-rtl.e-outline.e-input-group.e-small.e-bigger .e-clear-icon,.e-rtl .e-outline.e-input-group.e-small.e-bigger .e-clear-icon,.e-rtl.e-outline.e-input-group.e-small .e-clear-icon.e-bigger,.e-rtl .e-outline.e-input-group.e-small .e-clear-icon.e-bigger,.e-rtl.e-outline.e-input-group.e-control-wrapper.e-small.e-bigger .e-clear-icon,.e-rtl .e-outline.e-input-group.e-control-wrapper.e-small.e-bigger .e-clear-icon,.e-rtl.e-outline.e-input-group.e-control-wrapper.e-small .e-clear-icon.e-bigger,.e-rtl .e-outline.e-input-group.e-control-wrapper.e-small .e-clear-icon.e-bigger,.e-bigger.e-rtl .e-outline.e-input-group.e-small .e-clear-icon,.e-bigger .e-rtl.e-outline.e-input-group.e-small .e-clear-icon,.e-bigger .e-rtl.e-outline.e-input-group.e-control-wrapper.e-small .e-clear-icon,.e-bigger.e-rtl .e-outline.e-input-group.e-control-wrapper.e-small .e-clear-icon{padding-left:12px;padding-right:0}.e-rtl.e-outline.e-input-group.e-small.e-bigger .e-input-group-icon+.e-input-group-icon:last-child,.e-rtl .e-outline.e-input-group.e-small.e-bigger .e-input-group-icon+.e-input-group-icon:last-child,.e-rtl.e-outline.e-input-group.e-small .e-input-group-icon.e-bigger+.e-input-group-icon.e-bigger:last-child,.e-rtl .e-outline.e-input-group.e-small .e-input-group-icon.e-bigger+.e-input-group-icon.e-bigger:last-child,.e-rtl.e-outline.e-input-group.e-control-wrapper.e-small.e-bigger .e-input-group-icon+.e-input-group-icon:last-child,.e-rtl .e-outline.e-input-group.e-control-wrapper.e-small.e-bigger .e-input-group-icon+.e-input-group-icon:last-child,.e-rtl.e-outline.e-input-group.e-control-wrapper.e-small .e-input-group-icon.e-bigger+.e-input-group-icon.e-bigger:last-child,.e-rtl .e-outline.e-input-group.e-control-wrapper.e-small .e-input-group-icon.e-bigger+.e-input-group-icon.e-bigger:last-child,.e-rtl.e-bigger .e-outline.e-input-group.e-control-wrapper.e-small .e-input-group-icon+.e-input-group-icon:last-child,.e-bigger .e-rtl.e-outline.e-input-group.e-control-wrapper.e-small .e-input-group-icon+.e-input-group-icon:last-child,.e-rtl.e-bigger .e-outline.e-input-group.e-small .e-input-group-icon+.e-input-group-icon:last-child .e-bigger,.e-rtl.e-outline.e-input-group.e-small.e-bigger .e-input-group-icon,.e-rtl .e-outline.e-input-group.e-small.e-bigger .e-input-group-icon,.e-rtl.e-outline.e-input-group.e-small .e-input-group-icon.e-bigger,.e-rtl .e-outline.e-input-group.e-small .e-input-group-icon.e-bigger,.e-rtl.e-outline.e-input-group.e-control-wrapper.e-small.e-bigger .e-input-group-icon,.e-rtl .e-outline.e-input-group.e-control-wrapper.e-small.e-bigger .e-input-group-icon,.e-rtl.e-outline.e-input-group.e-control-wrapper.e-small .e-input-group-icon.e-bigger,.e-rtl .e-outline.e-input-group.e-control-wrapper.e-small .e-input-group-icon.e-bigger,.e-bigger.e-rtl .e-outline.e-input-group.e-small .e-input-group-icon,.e-bigger .e-rtl.e-outline.e-input-group.e-small .e-input-group-icon,.e-bigger .e-rtl.e-outline.e-input-group.e-control-wrapper.e-small .e-input-group-icon,.e-bigger.e-rtl .e-outline.e-input-group.e-control-wrapper.e-small .e-input-group-icon{margin-left:12px;margin-right:0}.e-outline.e-float-input.e-small.e-bigger label.e-float-text,.e-bigger .e-small .e-outline.e-float-input label.e-float-text,.e-bigger .e-outline.e-float-input.e-small label.e-float-text,.e-outline.e-float-input.e-bigger.e-small input:focus~label.e-float-text,.e-outline.e-float-input.e-bigger.e-small input:valid~label.e-float-text,.e-outline.e-float-input.e-bigger.e-small input~label.e-label-top.e-float-text,.e-outline.e-float-input.e-bigger.e-small input[readonly]~label.e-label-top.e-float-text,.e-outline.e-float-input.e-bigger.e-small input[disabled]~label.e-label-top.e-float-text,.e-outline.e-float-input.e-bigger.e-small input label.e-float-text.e-label-top,.e-bigger .e-outline.e-float-input.e-small input:focus~label.e-float-text,.e-bigger .e-outline.e-float-input.e-small input:valid~label.e-float-text,.e-bigger .e-outline.e-float-input.e-small input~label.e-label-top.e-float-text,.e-bigger .e-outline.e-float-input.e-small input[readonly]~label.e-label-top.e-float-text,.e-bigger .e-outline.e-float-input.e-small input[disabled]~label.e-label-top.e-float-text,.e-bigger .e-outline.e-float-input.e-small input label.e-float-text.e-label-top,.e-small .e-outline.e-float-input.e-bigger input:focus~label.e-float-text,.e-small .e-outline.e-float-input.e-bigger input:valid~label.e-float-text,.e-small .e-outline.e-float-input.e-bigger input~label.e-label-top.e-float-text,.e-small .e-outline.e-float-input.e-bigger input[readonly]~label.e-label-top.e-float-text,.e-small .e-outline.e-float-input.e-bigger input[disabled]~label.e-label-top.e-float-text,.e-small .e-outline.e-float-input.e-bigger input label.e-float-text.e-label-top,.e-outline.e-float-input.e-control-wrapper.e-bigger.e-small input:focus~label.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-bigger.e-small input:valid~label.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-bigger.e-small input~label.e-label-top.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-bigger.e-small input[readonly]~label.e-label-top.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-bigger.e-small input[disabled]~label.e-label-top.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-bigger.e-small input label.e-float-text.e-label-top,.e-bigger .e-outline.e-float-input.e-control-wrapper.e-small input:focus~label.e-float-text,.e-bigger .e-outline.e-float-input.e-control-wrapper.e-small input:valid~label.e-float-text,.e-bigger .e-outline.e-float-input.e-control-wrapper.e-small input~label.e-label-top.e-float-text,.e-bigger .e-outline.e-float-input.e-control-wrapper.e-small input[readonly]~label.e-label-top.e-float-text,.e-bigger .e-outline.e-float-input.e-control-wrapper.e-small input[disabled]~label.e-label-top.e-float-text,.e-bigger .e-outline.e-float-input.e-control-wrapper.e-small input label.e-float-text.e-label-top,.e-small .e-outline.e-float-input.e-control-wrapper.e-bigger input:focus~label.e-float-text,.e-small .e-outline.e-float-input.e-control-wrapper.e-bigger input:valid~label.e-float-text,.e-small .e-outline.e-float-input.e-control-wrapper.e-bigger input~label.e-label-top.e-float-text,.e-small .e-outline.e-float-input.e-control-wrapper.e-bigger input[readonly]~label.e-label-top.e-float-text,.e-small .e-outline.e-float-input.e-control-wrapper.e-bigger input[disabled]~label.e-label-top.e-float-text,.e-small .e-outline.e-float-input.e-control-wrapper.e-bigger input label.e-float-text.e-label-top,.e-outline.e-float-input.e-bigger.e-small textarea:focus~label.e-float-text,.e-outline.e-float-input.e-bigger.e-small textarea:valid~label.e-float-text,.e-outline.e-float-input.e-bigger.e-small textarea~label.e-label-top.e-float-text,.e-outline.e-float-input.e-bigger.e-small textarea[readonly]~label.e-label-top.e-float-text,.e-outline.e-float-input.e-bigger.e-small textarea[disabled]~label.e-label-top.e-float-text,.e-outline.e-float-input.e-bigger.e-small textarea label.e-float-text.e-label-top,.e-bigger .e-outline.e-float-input.e-small textarea:focus~label.e-float-text,.e-bigger .e-outline.e-float-input.e-small textarea:valid~label.e-float-text,.e-bigger .e-outline.e-float-input.e-small textarea~label.e-label-top.e-float-text,.e-bigger .e-outline.e-float-input.e-small textarea[readonly]~label.e-label-top.e-float-text,.e-bigger .e-outline.e-float-input.e-small textarea[disabled]~label.e-label-top.e-float-text,.e-bigger .e-outline.e-float-input.e-small textarea label.e-float-text.e-label-top,.e-small .e-outline.e-float-input.e-bigger textarea:focus~label.e-float-text,.e-small .e-outline.e-float-input.e-bigger textarea:valid~label.e-float-text,.e-small .e-outline.e-float-input.e-bigger textarea~label.e-label-top.e-float-text,.e-small .e-outline.e-float-input.e-bigger textarea[readonly]~label.e-label-top.e-float-text,.e-small .e-outline.e-float-input.e-bigger textarea[disabled]~label.e-label-top.e-float-text,.e-small .e-outline.e-float-input.e-bigger textarea label.e-float-text.e-label-top,.e-outline.e-float-input.e-control-wrapper.e-bigger.e-small textarea:focus~label.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-bigger.e-small textarea:valid~label.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-bigger.e-small textarea~label.e-label-top.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-bigger.e-small textarea[readonly]~label.e-label-top.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-bigger.e-small textarea[disabled]~label.e-label-top.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-bigger.e-small textarea label.e-float-text.e-label-top,.e-bigger .e-outline.e-float-input.e-control-wrapper.e-small textarea:focus~label.e-float-text,.e-bigger .e-outline.e-float-input.e-control-wrapper.e-small textarea:valid~label.e-float-text,.e-bigger .e-outline.e-float-input.e-control-wrapper.e-small textarea~label.e-label-top.e-float-text,.e-bigger .e-outline.e-float-input.e-control-wrapper.e-small textarea[readonly]~label.e-label-top.e-float-text,.e-bigger .e-outline.e-float-input.e-control-wrapper.e-small textarea[disabled]~label.e-label-top.e-float-text,.e-bigger .e-outline.e-float-input.e-control-wrapper.e-small textarea label.e-float-text.e-label-top,.e-small .e-outline.e-float-input.e-control-wrapper.e-bigger textarea:focus~label.e-float-text,.e-small .e-outline.e-float-input.e-control-wrapper.e-bigger textarea:valid~label.e-float-text,.e-small .e-outline.e-float-input.e-control-wrapper.e-bigger textarea~label.e-label-top.e-float-text,.e-small .e-outline.e-float-input.e-control-wrapper.e-bigger textarea[readonly]~label.e-label-top.e-float-text,.e-small .e-outline.e-float-input.e-control-wrapper.e-bigger textarea[disabled]~label.e-label-top.e-float-text,.e-small .e-outline.e-float-input.e-control-wrapper.e-bigger textarea label.e-float-text.e-label-top,.e-outline.e-float-input.e-bigger.e-small.e-input-focus input~label.e-float-text,.e-bigger .e-outline.e-float-input.e-small.e-input-focus input~label.e-float-text,.e-small .e-outline.e-float-input.e-bigger.e-input-focus input~label.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-bigger.e-small.e-input-focus input~label.e-float-text,.e-bigger .e-outline.e-float-input.e-control-wrapper.e-small.e-input-focus input~label.e-float-text,.e-small .e-outline.e-float-input.e-control-wrapper.e-bigger.e-input-focus input~label.e-float-text{top:-7px;transform:translateZ(0) scale(1)}.e-outline.e-float-input.e-bigger .e-clear-icon:before,.e-outline.e-float-input.e-control-wrapper.e-bigger .e-clear-icon:before,.e-outline.e-input-group.e-bigger .e-clear-icon:before,.e-outline.e-input-group.e-control-wrapper.e-bigger .e-clear-icon:before,.e-outline.e-float-input.e-control-wrapper input.e-bigger:first-child~.e-clear-icon:before,.e-outline.e-bigger .e-float-input.e-control-wrapper .e-clear-icon:before,.e-outline.e-float-input input.e-bigger:first-child~.e-clear-icon:before,.e-outline.e-bigger .e-float-input .e-clear-icon:before,.e-outline.e-bigger .e-input-group .e-clear-icon:before,.e-outline.e-bigger .e-input-group.e-control-wrapper .e-clear-icon:before{font-size:20px}.e-outline.e-float-input.e-small.e-bigger .e-clear-icon:before,.e-outline.e-float-input.e-control-wrapper.e-small.e-bigger .e-clear-icon:before,.e-outline.e-input-group.e-small.e-bigger .e-clear-icon:before,.e-outline.e-input-group.e-control-wrapper.e-small.e-bigger .e-clear-icon:before,.e-outline.e-small .e-input-group.e-bigger input:first-child~.e-clear-icon:before,.e-outline.e-small .e-input-group.e-control-wrapper.e-bigger input:first-child~.e-clear-icon:before,.e-outline.e-bigger .e-input-group.e-small input:first-child~.e-clear-icon:before,.e-outline.e-bigger .e-input-group.e-control-wrapper.e-small input:first-child~.e-clear-icon:before,.e-outline.e-small .e-float-input.e-control-wrapper.e-bigger input:first-child~.e-clear-icon:before,.e-outline.e-small .e-float-input.e-bigger input:first-child~.e-clear-icon:before,.e-outline.e-bigger .e-float-input.e-control-wrapper.e-small input:first-child~.e-clear-icon:before,.e-outline.e-bigger .e-float-input.e-small input:first-child~.e-clear-icon:before{font-size:18px}.e-outline.e-float-input.e-bigger textarea~label.e-float-text,.e-outline.e-float-input textarea~label.e-float-text.e-bigger,.e-outline.e-float-input textarea.e-bigger~label.e-float-text,.e-bigger .e-outline.e-float-input textarea~label.e-float-text,.e-outline.e-float-input.e-bigger textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger .e-outline.e-float-input textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-outline.e-float-input.e-control-wrapper.e-bigger textarea~label.e-float-text,.e-outline.e-float-input.e-control-wrapper textarea~label.e-float-text.e-bigger,.e-outline.e-float-input.e-control-wrapper textarea.e-bigger~label.e-float-text,.e-bigger .e-outline.e-float-input.e-control-wrapper textarea~label.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-bigger textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger .e-outline.e-float-input.e-control-wrapper textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger .e-outline.e-float-input textarea:-webkit-autofill~label.e-float-text,.e-bigger.e-outline.e-float-input textarea:-webkit-autofill~label.e-float-text,.e-bigger .e-outline.e-float-input.e-control-wrapper.e-autofill textarea:-webkit-autofill~label.e-float-text,.e-bigger.e-outline.e-float-input.e-control-wrapper.e-autofill textarea:-webkit-autofill~label.e-float-text,.e-bigger .e-outline.e-float-input.e-control-wrapper.e-autofill textarea:not(:focus):valid:-webkit-autofill~label.e-float-text.e-label-bottom,.e-bigger.e-outline.e-float-input.e-control-wrapper.e-autofill textarea:not(:focus):valid:-webkit-autofill~label.e-float-text.e-label-bottom,.e-outline.e-float-input.e-bigger label.e-float-text,.e-outline.e-float-input label.e-float-text.e-bigger,.e-outline.e-float-input input.e-bigger~label.e-float-text,.e-bigger .e-outline.e-float-input label.e-float-text,.e-outline.e-float-input.e-bigger:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger .e-outline.e-float-input:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-outline.e-float-input.e-control-wrapper.e-bigger label.e-float-text,.e-outline.e-float-input.e-control-wrapper label.e-float-text.e-bigger,.e-outline.e-float-input.e-control-wrapper input.e-bigger~label.e-float-text,.e-bigger .e-outline.e-float-input.e-control-wrapper label.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-bigger:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger .e-outline.e-float-input.e-control-wrapper:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom{font-size:16px}.e-bigger .e-outline.e-float-input.e-small textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small .e-outline.e-float-input.e-bigger textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-outline.e-float-input.e-bigger.e-small textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger.e-small .e-outline.e-float-input textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger .e-outline.e-float-input.e-control-wrapper.e-small textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small .e-outline.e-float-input.e-control-wrapper.e-bigger textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-outline.e-float-input.e-control-wrapper.e-bigger.e-small textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger.e-small .e-outline.e-float-input.e-control-wrapper textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger .e-outline.e-float-input.e-small textarea:-webkit-autofill~label.e-float-text,.e-bigger.e-small .e-outline.e-float-input textarea:-webkit-autofill~label.e-float-text,.e-outline.e-float-input.e-bigger.e-small textarea:-webkit-autofill~label.e-float-text,.e-bigger .e-outline.e-float-input.e-small.e-control-wrapper.e-autofill textarea:-webkit-autofill~label.e-float-text,.e-bigger.e-small .e-outline.e-float-input.e-control-wrapper.e-autofill textarea:-webkit-autofill~label.e-float-text,.e-outline.e-float-input.e-bigger.e-small.e-control-wrapper.e-autofill textarea:-webkit-autofill~label.e-float-text,.e-small.e-bigger .e-outline.e-float-input.e-control-wrapper.e-autofill textarea:not(:focus):valid:-webkit-autofill~label.e-float-text.e-label-bottom,.e-small.e-bigger.e-outline.e-float-input.e-control-wrapper.e-autofill textarea:not(:focus):valid:-webkit-autofill~label.e-float-text.e-label-bottom,.e-bigger .e-small.e-outline.e-float-input.e-control-wrapper.e-autofill textarea:not(:focus):valid:-webkit-autofill~label.e-float-text.e-label-bottom,.e-small .e-bigger.e-outline.e-float-input.e-control-wrapper.e-autofill textarea:not(:focus):valid:-webkit-autofill~label.e-float-text.e-label-bottom,.e-outline.e-float-input.e-small.e-bigger label.e-float-text,.e-bigger .e-outline.e-float-input.e-small label.e-float-text,.e-bigger .e-outline.e-float-input.e-small:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small .e-outline.e-float-input.e-bigger:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-outline.e-float-input.e-bigger.e-small:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger.e-small .e-outline.e-float-input:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-outline.e-float-input.e-control-wrapper.e-small.e-bigger label.e-float-text,.e-bigger .e-outline.e-float-input.e-control-wrapper.e-small label.e-float-text,.e-bigger .e-outline.e-float-input.e-control-wrapper.e-small:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small .e-outline.e-float-input.e-control-wrapper.e-bigger:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-outline.e-float-input.e-control-wrapper.e-bigger.e-small:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger.e-small .e-outline.e-float-input.e-control-wrapper:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom{font-size:14px}.e-bigger .e-outline.e-float-input input:-webkit-autofill~label.e-float-text,.e-bigger.e-outline.e-float-input input:-webkit-autofill~label.e-float-text,.e-bigger .e-outline.e-float-input.e-control-wrapper.e-autofill input:-webkit-autofill~label.e-float-text,.e-bigger.e-outline.e-float-input.e-control-wrapper.e-autofill input:-webkit-autofill~label.e-float-text,.e-bigger .e-outline.e-float-input.e-control-wrapper.e-autofill:not(.e-input-focus) input:not(:focus):valid:-webkit-autofill~label.e-float-text.e-label-bottom,.e-bigger.e-outline.e-float-input.e-control-wrapper.e-autofill:not(.e-input-focus) input:not(:focus):valid:-webkit-autofill~label.e-float-text.e-label-bottom{animation-name:slideTopUp}.e-bigger .e-outline.e-float-input.e-small input:-webkit-autofill~label.e-float-text,.e-bigger.e-small .e-outline.e-float-input input:-webkit-autofill~label.e-float-text,.e-outline.e-float-input.e-bigger.e-small input:-webkit-autofill~label.e-float-text,.e-bigger .e-outline.e-float-input.e-small.e-control-wrapper.e-autofill input:-webkit-autofill~label.e-float-text,.e-bigger.e-small .e-outline.e-float-input.e-control-wrapper.e-autofill input:-webkit-autofill~label.e-float-text,.e-outline.e-float-input.e-bigger.e-small.e-control-wrapper.e-autofill input:-webkit-autofill~label.e-float-text,.e-small.e-bigger .e-outline.e-float-input.e-control-wrapper.e-autofill:not(.e-input-focus) input:not(:focus):valid:-webkit-autofill~label.e-float-text.e-label-bottom,.e-small.e-bigger.e-outline.e-float-input.e-control-wrapper.e-autofill:not(.e-input-focus) input:not(:focus):valid:-webkit-autofill~label.e-float-text.e-label-bottom,.e-bigger .e-small.e-outline.e-float-input.e-control-wrapper.e-autofill:not(.e-input-focus) input:not(:focus):valid:-webkit-autofill~label.e-float-text.e-label-bottom,.e-small .e-bigger.e-outline.e-float-input.e-control-wrapper.e-autofill:not(.e-input-focus) input:not(:focus):valid:-webkit-autofill~label.e-float-text.e-label-bottom{animation-name:slideTopUp}.e-filled input.e-input.e-bigger,.e-filled.e-input-group.e-bigger input,.e-filled.e-input-group.e-bigger input.e-input,.e-filled.e-input-group.e-control-wrapper.e-bigger input,.e-filled.e-input-group.e-control-wrapper.e-bigger input.e-input,.e-bigger .e-filled.e-input-group input,.e-bigger .e-filled.e-input-group input.e-input,.e-bigger .e-filled.e-input-group.e-control-wrapper input,.e-bigger .e-filled.e-input-group.e-control-wrapper input.e-input,.e-filled.e-float-input.e-bigger input,.e-filled.e-float-input.e-bigger input.e-input,.e-bigger .e-filled.e-float-input input,.e-bigger .e-filled.e-float-input input.e-input,.e-filled.e-float-input.e-control-wrapper.e-bigger input,.e-filled.e-float-input.e-control-wrapper.e-bigger input.e-input,.e-bigger .e-filled.e-float-input.e-control-wrapper input,.e-bigger .e-filled.e-float-input.e-control-wrapper input.e-input,.e-filled.e-float-input.e-bigger:not(.e-input-group) input,.e-filled.e-float-input.e-bigger:not(.e-input-group) input.e-input,.e-bigger .e-filled.e-float-input:not(.e-input-group) input,.e-bigger .e-filled.e-float-input:not(.e-input-group) input.e-input,.e-filled.e-float-input.e-control-wrapper.e-bigger:not(.e-input-group) input,.e-filled.e-float-input.e-control-wrapper.e-bigger:not(.e-input-group) input.e-input,.e-bigger .e-filled.e-float-input.e-control-wrapper:not(.e-input-group) input,.e-bigger .e-filled.e-float-input.e-control-wrapper:not(.e-input-group) input.e-input,.e-filled input.e-input.e-small.e-bigger,.e-filled.e-input-group.e-bigger.e-small input,.e-filled.e-input-group.e-bigger.e-small input.e-input,.e-bigger.e-small .e-filled.e-input-group input,.e-bigger.e-small .e-filled.e-input-group input.e-input,.e-filled.e-input-group.e-control-wrapper.e-bigger.e-small input,.e-filled.e-input-group.e-control-wrapper.e-bigger.e-small input.e-input,.e-bigger.e-small .e-filled.e-input-group.e-control-wrapper input,.e-bigger.e-small .e-filled.e-input-group.e-control-wrapper input.e-input,.e-filled.e-float-input.e-bigger.e-small input,.e-filled.e-float-input.e-bigger.e-small input.e-input,.e-bigger.e-small .e-filled.e-float-input input,.e-bigger.e-small .e-filled.e-float-input input.e-input,.e-filled.e-float-input.e-control-wrapper.e-bigger.e-small input,.e-filled.e-float-input.e-control-wrapper.e-bigger.e-small input.e-input,.e-bigger.e-small .e-filled.e-float-input.e-control-wrapper input,.e-bigger.e-small .e-filled.e-float-input.e-control-wrapper input.e-input,.e-filled.e-float-input.e-bigger.e-small:not(.e-input-group) input,.e-filled.e-float-input.e-bigger.e-small:not(.e-input-group) input.e-input,.e-bigger.e-small .e-filled.e-float-input:not(.e-input-group) input,.e-bigger.e-small .e-filled.e-float-input:not(.e-input-group) input.e-input,.e-filled.e-float-input.e-control-wrapper.e-bigger.e-small:not(.e-input-group) input,.e-filled.e-float-input.e-control-wrapper.e-bigger.e-small:not(.e-input-group) input.e-input,.e-bigger.e-small .e-filled.e-float-input.e-control-wrapper:not(.e-input-group) input,.e-bigger.e-small .e-filled.e-float-input.e-control-wrapper:not(.e-input-group) input.e-input,.e-filled.e-input-group textarea.e-input.e-bigger,.e-filled.e-input-group.e-control-wrapper textarea.e-input.e-bigger,.e-filled textarea.e-input.e-bigger,.e-filled.e-input-group.e-bigger textarea,.e-filled.e-input-group.e-bigger textarea.e-input,.e-bigger .e-filled.e-input-group textarea,.e-bigger .e-filled.e-input-group textarea.e-input,.e-filled.e-input-group.e-control-wrapper.e-bigger textarea,.e-filled.e-input-group.e-control-wrapper.e-bigger textarea.e-input,.e-bigger .e-filled.e-input-group.e-control-wrapper textarea,.e-bigger .e-filled.e-input-group.e-control-wrapper textarea.e-input,.e-filled.e-float-input.e-bigger textarea,.e-filled.e-float-input.e-bigger textarea.e-input,.e-bigger .e-filled.e-float-input textarea,.e-bigger .e-filled.e-float-input textarea.e-input,.e-filled.e-float-input.e-control-wrapper.e-bigger textarea,.e-filled.e-float-input.e-control-wrapper.e-bigger textarea.e-input,.e-bigger .e-filled.e-float-input.e-control-wrapper textarea,.e-bigger .e-filled.e-float-input.e-control-wrapper textarea.e-input,.e-filled textarea.e-input.e-small.e-bigger,.e-filled.e-input-group.e-bigger.e-small textarea,.e-filled.e-input-group.e-bigger.e-small textarea.e-input,.e-bigger.e-small .e-filled.e-input-group textarea,.e-bigger.e-small .e-filled.e-input-group textarea.e-input,.e-filled.e-input-group.e-control-wrapper.e-bigger.e-small textarea,.e-filled.e-input-group.e-control-wrapper.e-bigger.e-small textarea.e-input,.e-bigger.e-small .e-filled.e-input-group.e-control-wrapper textarea,.e-bigger.e-small .e-filled.e-input-group.e-control-wrapper textarea.e-input,.e-filled.e-float-input.e-bigger.e-small textarea,.e-filled.e-float-input.e-bigger.e-small textarea.e-input,.e-bigger.e-small .e-filled.e-float-input textarea,.e-bigger.e-small .e-filled.e-float-input textarea.e-input,.e-filled.e-float-input.e-control-wrapper.e-bigger.e-small textarea,.e-filled.e-float-input.e-control-wrapper.e-bigger.e-small textarea.e-input,.e-bigger.e-small .e-filled.e-float-input.e-control-wrapper textarea,.e-bigger.e-small .e-filled.e-float-input.e-control-wrapper textarea.e-input{box-sizing:border-box}.e-filled.e-input-group.e-bigger,.e-bigger .e-filled.e-input-group,.e-filled.e-input-group.e-control-wrapper.e-bigger,.e-bigger .e-filled.e-input-group.e-control-wrapper{margin-top:0;padding:0 12px 0 16px}.e-filled.e-input-group.e-small.e-bigger,.e-bigger.e-small .e-filled.e-input-group.e-small,.e-bigger .e-filled.e-input-group.e-small,.e-small .e-filled.e-input-group.e-bigger,.e-filled.e-input-group.e-control-wrapper.e-small.e-bigger,.e-bigger.e-small .e-filled.e-input-group.e-control-wrapper.e-small,.e-bigger .e-filled.e-input-group.e-control-wrapper.e-small,.e-small .e-filled.e-input-group.e-control-wrapper.e-bigger{margin-top:0;padding:0 10px 0 12px}.e-filled.e-float-input.e-bigger,.e-bigger .e-filled.e-float-input,.e-filled.e-float-input.e-control-wrapper.e-bigger,.e-bigger .e-filled.e-float-input.e-control-wrapper{margin-top:0;padding:0 12px 0 16px}.e-filled.e-float-input.e-small.e-bigger,.e-bigger.e-small .e-filled.e-float-input.e-small,.e-bigger .e-filled.e-float-input.e-small,.e-small .e-filled.e-float-input.e-bigger,.e-filled.e-float-input.e-control-wrapper.e-small.e-bigger,.e-bigger.e-small .e-filled.e-float-input.e-control-wrapper.e-small,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-small,.e-small .e-filled.e-float-input.e-control-wrapper.e-bigger{margin-top:0;padding:0 10px 0 12px}.e-rtl.e-filled.e-input-group.e-bigger,.e-bigger .e-rtl.e-filled.e-input-group,.e-rtl.e-filled.e-input-group.e-control-wrapper.e-bigger,.e-bigger .e-rtl.e-filled.e-input-group.e-control-wrapper,.e-rtl .e-filled.e-input-group.e-bigger,.e-bigger.e-rtl .e-filled.e-input-group,.e-rtl .e-filled.e-input-group.e-control-wrapper.e-bigger,.e-bigger.e-rtl .e-filled.e-input-group.e-control-wrapper{padding:0 16px 0 12px}.e-rtl.e-filled.e-input-group.e-small.e-bigger,.e-bigger.e-small .e-rtl.e-filled.e-input-group.e-small,.e-bigger .e-rtl.e-filled.e-input-group.e-small,.e-small .e-rtl.e-filled.e-input-group.e-bigger,.e-rtl.e-filled.e-input-group.e-control-wrapper.e-small.e-bigger,.e-bigger.e-small .e-rtl.e-filled.e-input-group.e-control-wrapper.e-small,.e-bigger .e-rtl.e-filled.e-input-group.e-control-wrapper.e-small,.e-small .e-rtl.e-filled.e-input-group.e-control-wrapper.e-bigger,.e-rtl .e-filled.e-input-group.e-small.e-bigger,.e-bigger.e-small.e-rtl .e-filled.e-input-group.e-small,.e-bigger.e-rtl .e-filled.e-input-group.e-small,.e-small.e-rtl .e-filled.e-input-group.e-bigger,.e-rtl .e-filled.e-input-group.e-control-wrapper.e-small.e-bigger,.e-bigger.e-small.e-rtl .e-filled.e-input-group.e-control-wrapper.e-small,.e-bigger.e-rtl .e-filled.e-input-group.e-control-wrapper.e-small,.e-small.e-rtl .e-filled.e-input-group.e-control-wrapper.e-bigger{padding:0 12px 0 10px}.e-rtl.e-filled.e-float-input.e-bigger,.e-bigger .e-rtl.e-filled.e-float-input,.e-rtl.e-filled.e-float-input.e-control-wrapper.e-bigger,.e-bigger .e-rtl.e-filled.e-float-input.e-control-wrapper,.e-rtl .e-filled.e-float-input.e-bigger,.e-bigger.e-rtl .e-filled.e-float-input,.e-rtl .e-filled.e-float-input.e-control-wrapper.e-bigger,.e-bigger.e-rtl .e-filled.e-float-input.e-control-wrapper{padding:0 16px 0 12px}.e-rtl.e-filled.e-float-input.e-small.e-bigger,.e-bigger.e-small .e-rtl.e-filled.e-float-input.e-small,.e-bigger .e-rtl.e-filled.e-float-input.e-small,.e-small .e-rtl.e-filled.e-float-input.e-bigger,.e-rtl.e-filled.e-float-input.e-control-wrapper.e-small.e-bigger,.e-bigger.e-small .e-rtl.e-filled.e-float-input.e-control-wrapper.e-small,.e-bigger .e-rtl.e-filled.e-float-input.e-control-wrapper.e-small,.e-small .e-rtl.e-filled.e-float-input.e-control-wrapper.e-bigger,.e-rtl .e-filled.e-float-input.e-small.e-bigger,.e-bigger.e-small.e-rtl .e-filled.e-float-input.e-small,.e-bigger.e-rtl .e-filled.e-float-input.e-small,.e-small.e-rtl .e-filled.e-float-input.e-bigger,.e-rtl .e-filled.e-float-input.e-control-wrapper.e-small.e-bigger,.e-bigger.e-small.e-rtl .e-filled.e-float-input.e-control-wrapper.e-small,.e-bigger.e-rtl .e-filled.e-float-input.e-control-wrapper.e-small,.e-small.e-rtl .e-filled.e-float-input.e-control-wrapper.e-bigger{padding:0 12px 0 10px}.e-filled input.e-input.e-bigger,.e-filled textarea.e-input.e-bigger,.e-filled.e-input-group.e-bigger .e-input,.e-filled.e-input-group.e-bigger.e-control-wrapper .e-input,.e-bigger .e-filled input.e-input,.e-bigger .e-filled textarea.e-input,.e-bigger .e-filled.e-input-group .e-input,.e-bigger .e-filled.e-input-group.e-control-wrapper .e-input,.e-filled.e-input-group.e-bigger .e-input:focus,.e-bigger .e-filled.e-input-group .e-input:focus,.e-filled.e-input-group.e-control-wrapper.e-bigger .e-input:focus,.e-bigger .e-filled.e-input-group.e-control-wrapper .e-input:focus,.e-filled.e-input-group.e-bigger.e-input-focus .e-input,.e-bigger .e-filled.e-input-group.e-input-focus .e-input,.e-filled.e-input-group.e-control-wrapper.e-bigger.e-input-focus .e-input,.e-bigger .e-filled.e-input-group.e-control-wrapper.e-input-focus .e-input{padding:16px 4px 16px 0}.e-filled .e-input.e-bigger:focus,.e-bigger .e-filled .e-input:focus{padding-bottom:16px}.e-filled .e-input.e-small.e-bigger:focus,.e-bigger .e-filled .e-input.e-small:focus{padding-bottom:10px}.e-filled .e-input.e-small.e-bigger,.e-bigger .e-filled .e-input.e-small,.e-small .e-filled .e-input.e-bigger,.e-filled.e-input-group.e-small.e-bigger .e-input,.e-filled.e-input-group.e-small .e-input.e-bigger,.e-filled.e-input-group.e-control-wrapper.e-small.e-bigger .e-input,.e-filled.e-input-group.e-control-wrapper.e-small .e-input.e-bigger,.e-bigger .e-filled.e-input-group.e-small .e-input,.e-bigger .e-filled.e-input-group.e-control-wrapper.e-small .e-input,.e-filled.e-input-group.e-small.e-bigger .e-input:focus,.e-filled.e-input-group.e-small .e-input.e-bigger:focus,.e-bigger .e-filled.e-input-group.e-small .e-input:focus,.e-filled.e-input-group.e-control-wrapper.e-small.e-bigger .e-input:focus,.e-filled.e-input-group.e-control-wrapper.e-small .e-input.e-bigger:focus,.e-bigger .e-filled.e-input-group.e-control-wrapper.e-small .e-input:focus,.e-filled.e-input-group.e-small.e-bigger.e-input-focus .e-input,.e-filled.e-input-group.e-small.e-input-focus .e-input.e-bigger,.e-bigger .e-filled.e-input-group.e-small.e-input-focus .e-input,.e-filled.e-input-group.e-control-wrapper.e-small.e-bigger.e-input-focus .e-input,.e-filled.e-input-group.e-control-wrapper.e-small.e-input-focus .e-input.e-bigger,.e-bigger .e-filled.e-input-group.e-control-wrapper.e-small.e-input-focus .e-input{padding:10px 2px 10px 0}.e-filled.e-float-input.e-bigger input,.e-filled.e-float-input input.e-bigger,.e-bigger .e-filled.e-float-input input,.e-filled.e-float-input.e-control-wrapper.e-bigger input,.e-filled.e-float-input.e-control-wrapper input.e-bigger,.e-bigger .e-filled.e-float-input.e-control-wrapper input{padding:20px 4px 6px 0}.e-filled.e-float-input.e-small.e-bigger input,.e-filled.e-float-input.e-small input.e-bigger,.e-bigger .e-filled.e-float-input.e-small input,.e-filled.e-float-input.e-control-wrapper.e-small.e-bigger input,.e-filled.e-float-input.e-control-wrapper.e-small input.e-bigger,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-small input{padding:14px 2px 5px 0}.e-rtl .e-filled input.e-input.e-bigger,.e-filled input.e-input.e-bigger.e-rtl,.e-bigger.e-rtl .e-filled input.e-input,.e-bigger .e-filled input.e-input.e-rtl,.e-filled.e-input-group.e-bigger.e-rtl input.e-input,.e-filled.e-input-group.e-control-wrapper.e-bigger.e-rtl input.e-input,.e-rtl .e-filled.e-input-group.e-bigger input.e-input,.e-rtl .e-filled.e-input-group.e-control-wrapper.e-bigger input.e-input,.e-filled.e-input-group.e-rtl input.e-input.e-bigger,.e-filled.e-input-group.e-control-wrapper.e-rtl input.e-input.e-bigger,.e-rtl .e-filled.e-input-group input.e-input.e-bigger,.e-rtl .e-filled.e-input-group.e-control-wrapper input.e-input.e-bigger,.e-bigger .e-filled.e-input-group.e-rtl input.e-input,.e-bigger .e-filled.e-input-group.e-control-wrapper.e-rtl input.e-input,.e-bigger.e-rtl .e-filled.e-input-group input.e-input,.e-bigger.e-rtl .e-filled.e-input-group.e-control-wrapper input.e-input,.e-bigger.e-rtl .e-filled.e-input-group input.e-input:focus,.e-bigger.e-rtl .e-filled.e-input-group.e-control-wrapper input.e-input:focus,.e-bigger .e-filled.e-input-group.e-rtl input.e-input:focus,.e-bigger .e-filled.e-input-group.e-control-wrapper.e-rtl input.e-input:focus,.e-bigger.e-rtl .e-filled.e-input-group.e-input-focus input.e-input,.e-bigger.e-rtl .e-filled.e-input-group.e-control-wrapper.e-input-focus input.e-input,.e-bigger .e-filled.e-input-group.e-rtl.e-input-focus input.e-input,.e-bigger .e-filled.e-input-group.e-control-wrapper.e-rtl.e-input-focus input.e-input{padding:16px 0 16px 4px;text-indent:0}.e-filled.e-float-input.e-control-wrapper.e-bigger.e-rtl input,.e-filled.e-float-input.e-bigger.e-rtl input,.e-rtl .e-filled.e-float-input.e-control-wrapper.e-bigger input,.e-rtl .e-filled.e-float-input.e-bigger input,.e-filled.e-float-input.e-control-wrapper.e-rtl input.e-bigger,.e-filled.e-float-input.e-rtl input.e-bigger,.e-rtl .e-filled.e-float-input.e-control-wrapper input.e-bigger,.e-rtl .e-filled.e-float-input input.e-bigger,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-rtl input,.e-bigger .e-filled.e-float-input.e-rtl input,.e-bigger.e-rtl .e-filled.e-float-input.e-control-wrapper input,.e-bigger.e-rtl .e-filled.e-float-input input,.e-bigger.e-rtl .e-filled.e-float-input.e-control-wrapper input:focus,.e-bigger.e-rtl .e-filled.e-float-input input:focus,.e-bigger .e-filled.e-float-input.e-rtl input:focus,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-rtl input:focus,.e-bigger.e-rtl .e-filled.e-float-input.e-control-wrapper.e-input-focus input,.e-bigger.e-rtl .e-filled.e-float-input.e-input-focus input,.e-bigger .e-filled.e-float-input.e-rtl.e-input-focus input{padding:20px 0 6px 4px;text-indent:0}.e-bigger .e-filled input.e-input.e-small.e-rtl,.e-filled.e-input-group.e-small.e-bigger.e-rtl input.e-input,.e-filled.e-input-group.e-control-wrapper.e-small.e-bigger.e-rtl input.e-input,.e-filled.e-input-group.e-small.e-rtl input.e-input.e-bigger,.e-filled.e-input-group.e-control-wrapper.e-small.e-rtl input.e-input.e-bigger,.e-bigger .e-filled.e-input-group.e-small.e-rtl input.e-input,.e-bigger .e-filled.e-input-group.e-control-wrapper.e-small.e-rtl input.e-input,.e-bigger.e-rtl input.e-input.e-small,.e-rtl .e-filled.e-input-group.e-small.e-bigger input.e-input,.e-rtl .e-filled.e-input-group.e-control-wrapper.e-small.e-bigger input.e-input,.e-rtl .e-filled.e-input-group.e-small input.e-input.e-bigger,.e-rtl .e-filled.e-input-group.e-control-wrapper.e-small input.e-input.e-bigger,.e-bigger.e-rtl .e-filled.e-input-group.e-small input.e-input,.e-bigger.e-rtl .e-filled.e-input-group.e-control-wrapper.e-small input.e-input,.e-bigger .e-filled.e-input-group.e-small.e-rtl input.e-input:focus,.e-bigger .e-filled.e-input-group.e-control-wrapper.e-small.e-rtl input.e-input:focus,.e-small .e-filled.e-input-group.e-bigger.e-rtl input.e-input:focus,.e-small .e-filled.e-input-group.e-control-wrapper.e-bigger.e-rtl input.e-input:focus,.e-filled.e-input-group.e-bigger.e-small.e-rtl input.e-input:focus,.e-filled.e-input-group.e-control-wrapper.e-bigger.e-small.e-rtl input.e-input:focus,.e-bigger.e-rtl .e-filled.e-input-group.e-small input.e-input:focus,.e-bigger.e-rtl .e-filled.e-input-group.e-control-wrapper.e-small input.e-input:focus,.e-small.e-rtl .e-filled.e-input-group.e-bigger input.e-input:focus,.e-small.e-rtl .e-filled.e-input-group.e-control-wrapper.e-bigger input.e-input:focus,.e-rtl .e-filled.e-input-group.e-bigger.e-small input.e-input:focus,.e-rtl .e-filled.e-input-group.e-control-wrapper.e-bigger.e-small input.e-input:focus,.e-bigger .e-filled.e-input-group.e-small.e-rtl.e-input-focus input.e-input,.e-bigger .e-filled.e-input-group.e-control-wrapper.e-small.e-rtl.e-input-focus input.e-input,.e-small .e-filled.e-input-group.e-bigger.e-rtl.e-input-focus input.e-input,.e-small .e-filled.e-input-group.e-control-wrapper.e-bigger.e-rtl.e-input-focus input.e-input,.e-filled.e-input-group.e-bigger.e-small.e-rtl.e-input-focus input.e-input,.e-filled.e-input-group.e-control-wrapper.e-bigger.e-small.e-rtl.e-input-focus input.e-input,.e-bigger.e-rtl .e-filled.e-input-group.e-small.e-input-focus input.e-input,.e-bigger.e-rtl .e-filled.e-input-group.e-control-wrapper.e-small.e-input-focus input.e-input,.e-small.e-rtl .e-filled.e-input-group.e-bigger.e-input-focus input.e-input,.e-small.e-rtl .e-filled.e-input-group.e-control-wrapper.e-bigger.e-input-focus input.e-input,.e-rtl .e-filled.e-input-group.e-bigger.e-small.e-input-focus input.e-input,.e-rtl .e-filled.e-input-group.e-control-wrapper.e-bigger.e-small.e-input-focus input.e-input{padding:10px 0 10px 2px;text-indent:0}.e-filled.e-float-input.e-small.e-bigger.e-rtl input,.e-filled.e-float-input.e-small.e-rtl input.e-bigger,.e-bigger .e-filled.e-float-input.e-small.e-rtl input,.e-filled.e-float-input.e-control-wrapper.e-small.e-bigger.e-rtl input,.e-filled.e-float-input.e-control-wrapper.e-small.e-rtl input.e-bigger,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-small.e-rtl input,.e-rtl .e-filled.e-float-input.e-control-wrapper.e-small.e-bigger input,.e-rtl .e-filled.e-float-input.e-control-wrapper.e-small input.e-bigger,.e-bigger.e-rtl .e-filled.e-float-input.e-control-wrapper.e-small input,.e-rtl .e-filled.e-float-input.e-small.e-bigger input,.e-rtl .e-filled.e-float-input.e-small input.e-bigger,.e-bigger.e-rtl .e-filled.e-float-input.e-small input,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-small.e-rtl input:focus,.e-bigger .e-filled.e-float-input.e-small.e-rtl input:focus,.e-small .e-filled.e-float-input.e-control-wrapper.e-bigger.e-rtl input:focus,.e-small .e-filled.e-float-input.e-bigger.e-rtl input:focus,.e-filled.e-float-input.e-control-wrapper.e-bigger.e-small.e-rtl input:focus,.e-filled.e-float-input.e-bigger.e-small.e-rtl input:focus,.e-bigger.e-rtl .e-filled.e-float-input.e-control-wrapper.e-small input:focus,.e-bigger.e-rtl .e-filled.e-float-input.e-small input:focus,.e-small.e-rtl .e-filled.e-float-input.e-control-wrapper.e-bigger input:focus,.e-small.e-rtl .e-filled.e-float-input.e-bigger input:focus,.e-rtl .e-filled.e-float-input.e-control-wrapper.e-bigger.e-small input:focus,.e-rtl .e-filled.e-float-input.e-bigger.e-small input:focus,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-small.e-rtl.e-input-focus input,.e-bigger .e-filled.e-float-input.e-small.e-rtl.e-input-focus input,.e-small .e-filled.e-float-input.e-control-wrapper.e-bigger.e-rtl.e-input-focus input,.e-small .e-filled.e-float-input.e-bigger.e-rtl.e-input-focus input,.e-filled.e-float-input.e-control-wrapper.e-bigger.e-small.e-rtl.e-input-focus input,.e-filled.e-float-input.e-bigger.e-small.e-rtl.e-input-focus input,.e-bigger.e-rtl .e-filled.e-float-input.e-control-wrapper.e-small.e-input-focus input,.e-bigger.e-rtl .e-filled.e-float-input.e-small.e-input-focus input,.e-small.e-rtl .e-filled.e-float-input.e-control-wrapper.e-bigger.e-input-focus input,.e-small.e-rtl .e-filled.e-float-input.e-bigger.e-input-focus input,.e-rtl .e-filled.e-float-input.e-control-wrapper.e-bigger.e-small.e-input-focus input,.e-rtl .e-filled.e-float-input.e-bigger.e-small.e-input-focus input{padding:14px 0 5px 2px;text-indent:0}.e-filled.e-float-input.e-bigger,.e-bigger .e-filled.e-float-input,.e-filled.e-float-input.e-control-wrapper.e-bigger,.e-bigger .e-filled.e-float-input.e-control-wrapper,.e-filled.e-float-input.e-bigger.e-disabled,.e-bigger .e-filled.e-float-input.e-disabled,.e-filled.e-float-input.e-control-wrapper.e-bigger.e-disabled,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-disabled,.e-filled.e-float-input.e-input-group.e-bigger.e-disabled,.e-bigger .e-filled.e-float-input.e-input-group.e-disabled,.e-filled.e-float-input.e-input-group.e-control-wrapper.e-bigger.e-disabled,.e-bigger .e-filled.e-float-input.e-input-group.e-control-wrapper.e-disabled{font-size:16px}.e-filled.e-float-input.e-small.e-bigger,.e-small.e-bigger .e-filled.e-float-input,.e-bigger .e-filled.e-float-input.e-small,.e-small .e-filled.e-float-input.e-bigger,.e-filled.e-float-input.e-control-wrapper.e-small.e-bigger,.e-small.e-bigger .e-filled.e-float-input.e-control-wrapper,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-small,.e-small .e-filled.e-float-input.e-control-wrapper.e-bigger,.e-filled.e-float-input.e-small.e-bigger.e-disabled,.e-small.e-bigger .e-filled.e-float-input.e-disabled,.e-bigger .e-filled.e-float-input.e-small.e-disabled,.e-small .e-filled.e-float-input.e-bigger.e-disabled,.e-filled.e-float-input.e-control-wrapper.e-small.e-bigger.e-disabled,.e-small.e-bigger .e-filled.e-float-input.e-control-wrapper.e-disabled,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-small.e-disabled,.e-small .e-filled.e-float-input.e-control-wrapper.e-bigger.e-disabled,.e-filled.e-float-input.e-input-group.e-small.e-bigger.e-disabled,.e-small.e-bigger .e-filled.e-float-input.e-input-group.e-disabled,.e-bigger .e-filled.e-float-input.e-input-group.e-small.e-disabled,.e-small .e-filled.e-float-input.e-input-group.e-bigger.e-disabled,.e-filled.e-float-input.e-input-group.e-control-wrapper.e-small.e-bigger.e-disabled,.e-small.e-bigger .e-filled.e-float-input.e-input-group.e-control-wrapper.e-disabled,.e-bigger .e-filled.e-float-input.e-input-group.e-control-wrapper.e-small.e-disabled,.e-small .e-filled.e-float-input.e-input-group.e-control-wrapper.e-bigger.e-disabled{font-size:14px}.e-filled.e-input-group.e-bigger:not(.e-float-input) .e-input,.e-bigger .e-filled.e-input-group:not(.e-float-input) .e-input,.e-filled.e-input-group.e-control-wrapper.e-bigger:not(.e-float-input) .e-input,.e-bigger .e-filled.e-input-group.e-control-wrapper:not(.e-float-input) .e-input{min-height:55px}.e-filled.e-float-input.e-bigger input,.e-bigger .e-filled.e-float-input input,.e-filled.e-float-input.e-input-group.e-bigger input,.e-bigger .e-filled.e-float-input.e-input-group input,.e-filled.e-float-input.e-input-group.e-control-wrapper.e-bigger input,.e-bigger .e-filled.e-float-input.e-input-group.e-control-wrapper input,.e-filled.e-float-input.e-control-wrapper.e-bigger input,.e-bigger .e-filled.e-float-input.e-control-wrapper input,.e-filled.e-float-input.e-control-wrapper.e-input-group.e-bigger input,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-input-group input{min-height:55px}.e-filled.e-input-group.e-bigger.e-small:not(.e-float-input) .e-input,.e-bigger .e-filled.e-input-group.e-small:not(.e-float-input) .e-input .e-small .e-filled.e-input-group.e-bigger:not(.e-float-input) .e-input,.e-filled.e-input-group.e-control-wrapper.e-bigger.e-small:not(.e-float-input) .e-input,.e-bigger .e-filled.e-input-group.e-control-wrapper.e-small:not(.e-float-input) .e-input .e-small .e-filled.e-input-group.e-control-wrapper.e-bigger:not(.e-float-input) .e-input{min-height:39px}.e-float-input.e-bigger.e-small.e-filled input,.e-bigger .e-float-input.e-filled.e-small input,.e-small .e-float-input.e-filled.e-bigger input,.e-float-input.e-filled.e-input-group.e-bigger.e-small input,.e-bigger .e-float-input.e-filled.e-input-group.e-small input,.e-small .e-float-input.e-filled.e-input-group.e-bigger input,.e-float-input.e-filled.e-input-group.e-control-wrapper.e-bigger.e-small input,.e-bigger .e-float-input.e-filled.e-input-group.e-control-wrapper.e-small input,.e-small .e-float-input.e-filled.e-input-group.e-control-wrapper.e-bigger input,.e-float-input.e-filled.e-control-wrapper.e-bigger.e-small input,.e-bigger .e-float-input.e-filled.e-control-wrapper.e-small input,.e-small .e-float-input.e-filled.e-control-wrapper.e-bigger input,.e-float-input.e-control-wrapper.e-filled.e-input-group.e-bigger.e-small input,.e-bigger .e-float-input.e-control-wrapper.e-filled.e-input-group.e-small input,.e-small .e-float-input.e-control-wrapper.e-filled.e-input-group.e-bigger input{min-height:39px}.e-filled.e-float-input.e-bigger input:focus~label.e-float-text,.e-filled.e-float-input.e-bigger input:valid~label.e-float-text,.e-filled.e-float-input.e-bigger input~label.e-label-top.e-float-text,.e-filled.e-float-input.e-bigger input[readonly]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-bigger input[disabled]~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input input:focus~label.e-float-text,.e-bigger .e-filled.e-float-input input:valid~label.e-float-text,.e-bigger .e-filled.e-float-input input~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input input[readonly]~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input input[disabled]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-bigger input:focus~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-bigger input:valid~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-bigger input~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-bigger input[readonly]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-bigger input[disabled]~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper input:focus~label.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper input:valid~label.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper input~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper input[readonly]~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper input[disabled]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-bigger.e-input-focus input~label.e-float-text,.e-bigger .e-filled.e-float-input.e-input-focus input~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-bigger.e-input-focus input~label.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-input-focus input~label.e-float-text,.e-filled.e-float-input.e-bigger textarea:focus~label.e-float-text,.e-filled.e-float-input.e-bigger textarea:valid~label.e-float-text,.e-filled.e-float-input.e-bigger textarea~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input textarea:focus~label.e-float-text,.e-bigger .e-filled.e-float-input textarea:valid~label.e-float-text,.e-bigger .e-filled.e-float-input textarea~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-bigger textarea:focus~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-bigger textarea:valid~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-bigger textarea~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper textarea:focus~label.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper textarea:valid~label.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper textarea~label.e-label-top.e-float-text{font-size:16px;top:18px}.e-bigger .e-filled.e-float-input input:-webkit-autofill~label.e-float-text,.e-bigger.e-filled.e-float-input input:-webkit-autofill~label.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-autofill input:-webkit-autofill~label.e-float-text,.e-bigger.e-filled.e-float-input.e-control-wrapper.e-autofill input:-webkit-autofill~label.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-autofill:not(.e-input-focus) input:not(:focus):valid:-webkit-autofill~label.e-float-text.e-label-bottom,.e-bigger.e-filled.e-float-input.e-control-wrapper.e-autofill:not(.e-input-focus) input:not(:focus):valid:-webkit-autofill~label.e-float-text.e-label-bottom,.e-bigger .e-filled.e-float-input textarea:-webkit-autofill~label.e-float-text,.e-bigger.e-filled.e-float-input textarea:-webkit-autofill~label.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-autofill textarea:-webkit-autofill~label.e-float-text,.e-bigger.e-filled.e-float-input.e-control-wrapper.e-autofill textarea:-webkit-autofill~label.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-autofill textarea:not(:focus):valid:-webkit-autofill~label.e-float-text.e-label-bottom,.e-bigger.e-filled.e-float-input.e-control-wrapper.e-autofill textarea:not(:focus):valid:-webkit-autofill~label.e-float-text.e-label-bottom{font-size:16px;top:18px;transform:translateY(-50%) scale(.75);-webkit-user-select:text;user-select:text}.e-filled.e-float-input.e-small.e-bigger input:focus~label.e-float-text,.e-filled.e-float-input.e-small.e-bigger input:valid~label.e-float-text,.e-filled.e-float-input.e-small.e-bigger input~label.e-label-top.e-float-text,.e-filled.e-float-input.e-small.e-bigger input[readonly]~label.e-float-text,.e-filled.e-float-input.e-small.e-bigger input[disabled]~label.e-float-text,.e-bigger .e-filled.e-float-input.e-small input:focus~label.e-float-text,.e-bigger .e-filled.e-float-input.e-small input:valid~label.e-float-text,.e-bigger .e-filled.e-float-input.e-small input~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input.e-small input[readonly]~label.e-float-text,.e-bigger .e-filled.e-float-input.e-small input[disabled]~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small.e-bigger input:focus~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small.e-bigger input:valid~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small.e-bigger input~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small.e-bigger input[readonly]~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small.e-bigger input[disabled]~label.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-small input:focus~label.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-small input:valid~label.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-small input~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-small input[readonly]~label.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-small input[disabled]~label.e-float-text,.e-filled.e-float-input.e-small.e-bigger.e-input-focus input~label.e-float-text,.e-bigger .e-filled.e-float-input.e-small.e-input-focus input~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small.e-bigger.e-input-focus input~label.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-small.e-input-focus input~label.e-float-text,.e-filled.e-float-input.e-small.e-bigger textarea:focus~label.e-float-text,.e-filled.e-float-input.e-small.e-bigger textarea:valid~label.e-float-text,.e-filled.e-float-input.e-small.e-bigger textarea~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input.e-small textarea:focus~label.e-float-text,.e-bigger .e-filled.e-float-input.e-small textarea:valid~label.e-float-text,.e-bigger .e-filled.e-float-input.e-small textarea~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small.e-bigger textarea:focus~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small.e-bigger textarea:valid~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small.e-bigger textarea~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-small textarea:focus~label.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-small textarea:valid~label.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-small textarea~label.e-label-top.e-float-text{font-size:14px;top:12px}.e-bigger .e-filled.e-float-input.e-small input:-webkit-autofill~label.e-float-text,.e-bigger.e-small .e-filled.e-float-input input:-webkit-autofill~label.e-float-text,.e-filled.e-float-input.e-bigger.e-small input:-webkit-autofill~label.e-float-text,.e-bigger .e-filled.e-float-input.e-small.e-control-wrapper.e-autofill input:-webkit-autofill~label.e-float-text,.e-bigger.e-small .e-filled.e-float-input.e-control-wrapper.e-autofill input:-webkit-autofill~label.e-float-text,.e-filled.e-float-input.e-bigger.e-small.e-control-wrapper.e-autofill input:-webkit-autofill~label.e-float-text,.e-small.e-bigger .e-filled.e-float-input.e-control-wrapper.e-autofill:not(.e-input-focus) input:not(:focus):valid:-webkit-autofill~label.e-float-text.e-label-bottom,.e-small.e-bigger.e-filled.e-float-input.e-control-wrapper.e-autofill:not(.e-input-focus) input:not(:focus):valid:-webkit-autofill~label.e-float-text.e-label-bottom,.e-bigger .e-small.e-filled.e-float-input.e-control-wrapper.e-autofill:not(.e-input-focus) input:not(:focus):valid:-webkit-autofill~label.e-float-text.e-label-bottom,.e-small .e-bigger.e-filled.e-float-input.e-control-wrapper.e-autofill:not(.e-input-focus) input:not(:focus):valid:-webkit-autofill~label.e-float-text.e-label-bottom,.e-bigger .e-filled.e-float-input.e-small textarea:-webkit-autofill~label.e-float-text,.e-bigger.e-small .e-filled.e-float-input textarea:-webkit-autofill~label.e-float-text,.e-filled.e-float-input.e-bigger.e-small textarea:-webkit-autofill~label.e-float-text,.e-bigger .e-filled.e-float-input.e-small.e-control-wrapper.e-autofill textarea:-webkit-autofill~label.e-float-text,.e-bigger.e-small .e-filled.e-float-input.e-control-wrapper.e-autofill textarea:-webkit-autofill~label.e-float-text,.e-filled.e-float-input.e-bigger.e-small.e-control-wrapper.e-autofill textarea:-webkit-autofill~label.e-float-text,.e-small.e-bigger .e-filled.e-float-input.e-control-wrapper.e-autofill textarea:not(:focus):valid:-webkit-autofill~label.e-float-text.e-label-bottom,.e-small.e-bigger.e-filled.e-float-input.e-control-wrapper.e-autofill textarea:not(:focus):valid:-webkit-autofill~label.e-float-text.e-label-bottom,.e-bigger .e-small.e-filled.e-float-input.e-control-wrapper.e-autofill textarea:not(:focus):valid:-webkit-autofill~label.e-float-text.e-label-bottom,.e-small .e-bigger.e-filled.e-float-input.e-control-wrapper.e-autofill textarea:not(:focus):valid:-webkit-autofill~label.e-float-text.e-label-bottom{font-size:14px;top:12px;transform:translateY(-50%) scale(.75);-webkit-user-select:text;user-select:text}.e-filled.e-float-input.e-bigger label.e-float-text,.e-filled.e-float-input label.e-float-text.e-bigger,.e-filled.e-float-input input.e-bigger~label.e-float-text,.e-bigger .e-filled.e-float-input label.e-float-text,.e-filled.e-float-input.e-bigger:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger .e-filled.e-float-input:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-filled.e-float-input.e-control-wrapper.e-bigger label.e-float-text,.e-filled.e-float-input.e-control-wrapper label.e-float-text.e-bigger,.e-filled.e-float-input.e-control-wrapper input.e-bigger~label.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-bigger:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger .e-filled.e-float-input.e-control-wrapper:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-filled.e-float-input.e-bigger textarea~label.e-float-text,.e-filled.e-float-input textarea~label.e-float-text.e-bigger,.e-filled.e-float-input textarea.e-bigger~label.e-float-text,.e-bigger .e-filled.e-float-input textarea~label.e-float-text,.e-filled.e-float-input.e-bigger textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger .e-filled.e-float-input textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-filled.e-float-input.e-control-wrapper.e-bigger textarea~label.e-float-text,.e-filled.e-float-input.e-control-wrapper textarea~label.e-float-text.e-bigger,.e-filled.e-float-input.e-control-wrapper textarea.e-bigger~label.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper textarea~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-bigger textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger .e-filled.e-float-input.e-control-wrapper textarea:not(:focus):valid~label.e-float-text.e-label-bottom{font-size:16px;top:18px}.e-filled.e-float-input.e-small.e-bigger label.e-float-text,.e-bigger .e-filled.e-float-input.e-small label.e-float-text,.e-bigger .e-filled.e-float-input.e-small:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small .e-filled.e-float-input.e-bigger:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-filled.e-float-input.e-bigger.e-small:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger.e-small .e-filled.e-float-input:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-filled.e-float-input.e-control-wrapper.e-small.e-bigger label.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-small label.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-small:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small .e-filled.e-float-input.e-control-wrapper.e-bigger:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-filled.e-float-input.e-control-wrapper.e-bigger.e-small:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger.e-small .e-filled.e-float-input.e-control-wrapper:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom{font-size:14px;top:12px;transform:none}.e-filled.e-float-input.e-bigger.e-small input:focus~label.e-float-text,.e-filled.e-float-input.e-bigger.e-small input:valid~label.e-float-text,.e-filled.e-float-input.e-bigger.e-small input~label.e-label-top.e-float-text,.e-filled.e-float-input.e-bigger.e-small input[readonly]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-bigger.e-small input[disabled]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-bigger.e-small input label.e-float-text.e-label-top,.e-bigger .e-filled.e-float-input.e-small input:focus~label.e-float-text,.e-bigger .e-filled.e-float-input.e-small input:valid~label.e-float-text,.e-bigger .e-filled.e-float-input.e-small input~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input.e-small input[readonly]~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input.e-small input[disabled]~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input.e-small input label.e-float-text.e-label-top,.e-small .e-filled.e-float-input.e-bigger input:focus~label.e-float-text,.e-small .e-filled.e-float-input.e-bigger input:valid~label.e-float-text,.e-small .e-filled.e-float-input.e-bigger input~label.e-label-top.e-float-text,.e-small .e-filled.e-float-input.e-bigger input[readonly]~label.e-label-top.e-float-text,.e-small .e-filled.e-float-input.e-bigger input[disabled]~label.e-label-top.e-float-text,.e-small .e-filled.e-float-input.e-bigger input label.e-float-text.e-label-top,.e-filled.e-float-input.e-control-wrapper.e-bigger.e-small input:focus~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-bigger.e-small input:valid~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-bigger.e-small input~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-bigger.e-small input[readonly]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-bigger.e-small input[disabled]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-bigger.e-small input label.e-float-text.e-label-top,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-small input:focus~label.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-small input:valid~label.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-small input~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-small input[readonly]~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-small input[disabled]~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-small input label.e-float-text.e-label-top,.e-small .e-filled.e-float-input.e-control-wrapper.e-bigger input:focus~label.e-float-text,.e-small .e-filled.e-float-input.e-control-wrapper.e-bigger input:valid~label.e-float-text,.e-small .e-filled.e-float-input.e-control-wrapper.e-bigger input~label.e-label-top.e-float-text,.e-small .e-filled.e-float-input.e-control-wrapper.e-bigger input[readonly]~label.e-label-top.e-float-text,.e-small .e-filled.e-float-input.e-control-wrapper.e-bigger input[disabled]~label.e-label-top.e-float-text,.e-small .e-filled.e-float-input.e-control-wrapper.e-bigger input label.e-float-text.e-label-top,.e-filled.e-float-input.e-bigger.e-small.e-input-focus input~label.e-float-text,.e-bigger .e-filled.e-float-input.e-small.e-input-focus input~label.e-float-text,.e-small .e-filled.e-float-input.e-bigger.e-input-focus input~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-bigger.e-small.e-input-focus input~label.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-small.e-input-focus input~label.e-float-text,.e-small .e-filled.e-float-input.e-control-wrapper.e-bigger.e-input-focus input~label.e-float-text,.e-float-input.e-filled.e-bigger.e-small textarea:focus~label.e-float-text,.e-filled.e-float-input.e-bigger.e-small textarea:valid~label.e-float-text,.e-filled.e-float-input.e-bigger.e-small textarea~label.e-label-top.e-float-text,.e-filled.e-float-input.e-bigger.e-small textarea[readonly]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-bigger.e-small textarea[disabled]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-bigger.e-small textarea label.e-float-text.e-label-top,.e-bigger .e-filled.e-float-input.e-small textarea:focus~label.e-float-text,.e-bigger .e-filled.e-float-input.e-small textarea:valid~label.e-float-text,.e-bigger .e-filled.e-float-input.e-small textarea~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input.e-small textarea[readonly]~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input.e-small textarea[disabled]~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input.e-small textarea label.e-float-text.e-label-top,.e-small .e-filled.e-float-input.e-bigger textarea:focus~label.e-float-text,.e-small .e-filled.e-float-input.e-bigger textarea:valid~label.e-float-text,.e-small .e-filled.e-float-input.e-bigger textarea~label.e-label-top.e-float-text,.e-small .e-filled.e-float-input.e-bigger textarea[readonly]~label.e-label-top.e-float-text,.e-small .e-filled.e-float-input.e-bigger textarea[disabled]~label.e-label-top.e-float-text,.e-small .e-filled.e-float-input.e-bigger textarea label.e-float-text.e-label-top,.e-filled.e-float-input.e-control-wrapper.e-bigger.e-small textarea:focus~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-bigger.e-small textarea:valid~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-bigger.e-small textarea~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-bigger.e-small textarea[readonly]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-bigger.e-small textarea[disabled]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-bigger.e-small textarea label.e-float-text.e-label-top,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-small textarea:focus~label.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-small textarea:valid~label.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-small textarea~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-small textarea[readonly]~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-small textarea[disabled]~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-small textarea label.e-float-text.e-label-top,.e-small .e-filled.e-float-input.e-control-wrapper.e-bigger textarea:focus~label.e-float-text,.e-small .e-filled.e-float-input.e-control-wrapper.e-bigger textarea:valid~label.e-float-text,.e-small .e-filled.e-float-input.e-control-wrapper.e-bigger textarea~label.e-label-top.e-float-text,.e-small .e-filled.e-float-input.e-control-wrapper.e-bigger textarea[readonly]~label.e-label-top.e-float-text,.e-small .e-filled.e-float-input.e-control-wrapper.e-bigger textarea[disabled]~label.e-label-top.e-float-text,.e-small .e-filled.e-float-input.e-control-wrapper.e-bigger textarea label.e-float-text.e-label-top{transform:translateY(-50%) scale(.75)}.e-bigger .e-filled.e-float-input.e-small textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small .e-filled.e-float-input.e-bigger textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-filled.e-float-input.e-bigger.e-small textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger.e-small .e-filled.e-float-input textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-small textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small .e-filled.e-float-input.e-control-wrapper.e-bigger textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-filled.e-float-input.e-control-wrapper.e-bigger.e-small textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger.e-small .e-filled.e-float-input.e-control-wrapper textarea:not(:focus):valid~label.e-float-text.e-label-bottom{font-size:14px;top:12px}.e-filled.e-float-input.e-bigger label.e-float-text,.e-filled.e-float-input.e-bigger label.e-float-text.e-label-bottom,.e-filled.e-float-input.e-control-wrapper.e-bigger label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-bigger label.e-float-text.e-label-bottom,.e-filled.e-float-input.e-bigger:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-filled.e-float-input.e-control-wrapper.e-bigger:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger .e-filled.e-float-input label.e-float-text,.e-bigger .e-filled.e-float-input label.e-float-text.e-label-bottom,.e-bigger .e-filled.e-float-input.e-control-wrapper label.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper label.e-float-text.e-label-bottom,.e-bigger .e-filled.e-float-input:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger .e-filled.e-float-input.e-control-wrapper:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-filled.e-float-input.e-bigger:not(.e-input-focus) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-filled.e-float-input.e-control-wrapper.e-bigger:not(.e-input-focus) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger .e-filled.e-float-input:not(.e-input-focus) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger .e-filled.e-float-input.e-control-wrapper:not(.e-input-focus) textarea:not(:focus):valid~label.e-float-text.e-label-bottom{left:16px}.e-filled.e-float-input.e-bigger.e-rtl label.e-float-text,.e-filled.e-float-input.e-rtl.e-bigger label.e-float-text.e-label-bottom,.e-rtl .e-filled.e-float-input.e-bigger label.e-float-text .e-filled.e-float-input.e-control-wrapper.e-rtl.e-bigger label.e-float-text,.e-filled.e-float-input.e-rtl.e-control-wrapper.e-bigger label.e-float-text.e-label-bottom,.e-rtl .e-filled.e-float-input.e-control-wrapper.e-bigger label.e-float-text,.e-bigger .e-filled.e-float-input.e-rtl label.e-float-text,.e-bigger .e-filled.e-float-input.e-rtl label.e-float-text.e-label-bottom,.e-rtl.e-bigger .e-filled.e-float-input label.e-float-text .e-bigger .e-filled.e-float-input.e-control-wrapper.e-rtl label.e-float-text,.e-bigger .e-filled.e-float-input.e-rtl.e-control-wrapper label.e-float-text.e-label-bottom,.e-rtl.e-bigger .e-filled.e-float-input.e-control-wrapper label.e-float-text,.e-bigger.e-filled.e-float-input.e-rtl:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger.e-filled.e-float-input.e-control-wrapper.e-rtl:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-rtl .e-bigger.e-filled.e-float-input:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-rtl .e-bigger.e-filled.e-float-input.e-control-wrapper:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger .e-filled.e-float-input.e-rtl:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-rtl:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-rtl.e-bigger .e-filled.e-float-input:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-rtl.e-bigger .e-filled.e-float-input.e-control-wrapper:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger.e-filled.e-float-input.e-rtl:not(.e-input-focus) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger.e-filled.e-float-input.e-control-wrapper.e-rtl:not(.e-input-focus) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-rtl .e-bigger.e-filled.e-float-input:not(.e-input-focus) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-rtl .e-bigger.e-filled.e-float-input.e-control-wrapper:not(.e-input-focus) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger .e-filled.e-float-input.e-rtl:not(.e-input-focus) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-rtl:not(.e-input-focus) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-rtl.e-bigger .e-filled.e-float-input:not(.e-input-focus) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-rtl.e-bigger .e-filled.e-float-input.e-control-wrapper:not(.e-input-focus) textarea:not(:focus):valid~label.e-float-text.e-label-bottom{right:16px}.e-small .e-filled.e-float-input.e-bigger label.e-float-text{left:8px}.e-filled.e-float-input.e-small.e-bigger label.e-float-text,.e-filled.e-float-input.e-small.e-bigger label.e-float-text.e-label-bottom,.e-filled.e-float-input.e-control-wrapper.e-small.e-bigger label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small.e-bigger label.e-float-text.e-label-bottom,.e-filled.e-float-input.e-small.e-bigger:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-filled.e-float-input.e-control-wrapper.e-small.e-bigger:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small.e-bigger .e-filled.e-float-input label.e-float-text,.e-small.e-bigger .e-filled.e-float-input label.e-float-text.e-label-bottom,.e-small.e-bigger .e-filled.e-float-input.e-control-wrapper label.e-float-text,.e-small.e-bigger .e-filled.e-float-input.e-control-wrapper label.e-float-text.e-label-bottom,.e-small.e-bigger .e-filled.e-float-input:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small.e-bigger .e-filled.e-float-input.e-control-wrapper:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-filled.e-float-input.e-small.e-bigger:not(.e-input-focus) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-filled.e-float-input.e-control-wrapper.e-small.e-bigger:not(.e-input-focus) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small.e-bigger .e-filled.e-float-input:not(.e-input-focus) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small.e-bigger .e-filled.e-float-input.e-control-wrapper:not(.e-input-focus) textarea:not(:focus):valid~label.e-float-text.e-label-bottom{left:12px}.e-filled.e-float-input.e-small.e-bigger.e-rtl label.e-float-text,.e-filled.e-float-input.e-rtl.e-small.e-bigger label.e-float-text.e-label-bottom,.e-rtl .e-filled.e-float-input.e-small.e-bigger label.e-float-text .e-filled.e-float-input.e-control-wrapper.e-rtl.e-small.e-bigger label.e-float-text,.e-filled.e-float-input.e-rtl.e-control-wrapper.e-small.e-bigger label.e-float-text.e-label-bottom,.e-rtl .e-filled.e-float-input.e-control-wrapper.e-small.e-bigger label.e-float-text,.e-small.e-bigger .e-filled.e-float-input.e-rtl label.e-float-text,.e-small.e-bigger .e-filled.e-float-input.e-rtl label.e-float-text.e-label-bottom,.e-rtl.e-small.e-bigger .e-filled.e-float-input label.e-float-text .e-small.e-bigger .e-filled.e-float-input.e-control-wrapper.e-rtl label.e-float-text,.e-small.e-bigger .e-filled.e-float-input.e-rtl.e-control-wrapper label.e-float-text.e-label-bottom,.e-rtl.e-small.e-bigger .e-filled.e-float-input.e-control-wrapper label.e-float-text,.e-small.e-bigger.e-filled.e-float-input.e-rtl:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small.e-bigger.e-filled.e-float-input.e-control-wrapper.e-rtl:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-rtl .e-small.e-bigger.e-filled.e-float-input:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-rtl .e-small.e-bigger.e-filled.e-float-input.e-control-wrapper:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small .e-bigger.e-filled.e-float-input.e-rtl:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small .e-bigger.e-filled.e-float-input.e-control-wrapper.e-rtl:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger .e-small.e-filled.e-float-input.e-rtl:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger .e-small.e-filled.e-float-input.e-control-wrapper.e-rtl:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-rtl.e-small.e-bigger .e-filled.e-float-input:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-rtl.e-small.e-bigger .e-filled.e-float-input.e-control-wrapper:not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small.e-bigger.e-filled.e-float-input.e-rtl:not(.e-input-focus) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small.e-bigger.e-filled.e-float-input.e-control-wrapper.e-rtl:not(.e-input-focus) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-rtl .e-small.e-bigger.e-filled.e-float-input:not(.e-input-focus) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-rtl .e-small.e-bigger.e-filled.e-float-input.e-control-wrapper:not(.e-input-focus) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small .e-bigger.e-filled.e-float-input.e-rtl:not(.e-input-focus) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small .e-bigger.e-filled.e-float-input.e-control-wrapper.e-rtl:not(.e-input-focus) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger .e-small.e-filled.e-float-input.e-rtl:not(.e-input-focus) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger .e-small.e-filled.e-float-input.e-control-wrapper.e-rtl:not(.e-input-focus) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-rtl.e-small.e-bigger .e-filled.e-float-input:not(.e-input-focus) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-rtl.e-small.e-bigger .e-filled.e-float-input.e-control-wrapper:not(.e-input-focus) textarea:not(:focus):valid~label.e-float-text.e-label-bottom{right:12px}.e-filled.e-float-input.e-bigger.e-rtl .e-input-in-wrap label.e-float-text,.e-filled.e-float-input.e-rtl.e-bigger .e-input-in-wrap label.e-float-text.e-label-bottom,.e-rtl .e-filled.e-float-input.e-bigger .e-input-in-wrap label.e-float-text .e-filled.e-float-input.e-control-wrapper.e-rtl.e-bigger .e-input-in-wrap label.e-float-text,.e-filled.e-float-input.e-rtl.e-control-wrapper.e-bigger .e-input-in-wrap label.e-float-text.e-label-bottom,.e-rtl .e-filled.e-float-input.e-control-wrapper.e-bigger .e-input-in-wrap label.e-float-text,.e-bigger .e-filled.e-float-input.e-rtl .e-input-in-wrap label.e-float-text,.e-bigger .e-filled.e-float-input.e-rtl .e-input-in-wrap label.e-float-text.e-label-bottom,.e-rtl.e-bigger .e-filled.e-float-input .e-input-in-wrap label.e-float-text .e-bigger .e-filled.e-float-input.e-control-wrapper.e-rtl .e-input-in-wrap label.e-float-text,.e-bigger .e-filled.e-float-input.e-rtl.e-control-wrapper .e-input-in-wrap label.e-float-text.e-label-bottom,.e-rtl.e-bigger .e-filled.e-float-input.e-control-wrapper .e-input-in-wrap label.e-float-text,.e-bigger.e-filled.e-float-input.e-rtl:not(.e-input-focus) .e-input-in-wrap input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger.e-filled.e-float-input.e-control-wrapper.e-rtl:not(.e-input-focus) .e-input-in-wrap input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-rtl .e-bigger.e-filled.e-float-input:not(.e-input-focus) .e-input-in-wrap input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-rtl .e-bigger.e-filled.e-float-input.e-control-wrapper:not(.e-input-focus) .e-input-in-wrap input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger .e-filled.e-float-input.e-rtl:not(.e-input-focus) .e-input-in-wrap input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-rtl:not(.e-input-focus) .e-input-in-wrap input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-rtl.e-bigger .e-filled.e-float-input:not(.e-input-focus) .e-input-in-wrap input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-rtl.e-bigger .e-filled.e-float-input.e-control-wrapper:not(.e-input-focus) .e-input-in-wrap input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-filled.e-float-input.e-small.e-bigger.e-rtl .e-input-in-wrap label.e-float-text,.e-filled.e-float-input.e-rtl.e-small.e-bigger .e-input-in-wrap label.e-float-text.e-label-bottom,.e-rtl .e-filled.e-float-input.e-small.e-bigger .e-input-in-wrap label.e-float-text .e-filled.e-float-input.e-control-wrapper.e-rtl.e-small.e-bigger .e-input-in-wrap label.e-float-text,.e-filled.e-float-input.e-rtl.e-control-wrapper.e-small.e-bigger .e-input-in-wrap label.e-float-text.e-label-bottom,.e-rtl .e-filled.e-float-input.e-control-wrapper.e-small.e-bigger .e-input-in-wrap label.e-float-text,.e-small.e-bigger .e-filled.e-float-input.e-rtl .e-input-in-wrap label.e-float-text,.e-small.e-bigger .e-filled.e-float-input.e-rtl .e-input-in-wrap label.e-float-text.e-label-bottom,.e-rtl.e-small.e-bigger .e-filled.e-float-input .e-input-in-wrap label.e-float-text .e-small.e-bigger .e-filled.e-float-input.e-control-wrapper.e-rtl .e-input-in-wrap label.e-float-text,.e-small.e-bigger .e-filled.e-float-input.e-rtl.e-control-wrapper .e-input-in-wrap label.e-float-text.e-label-bottom,.e-rtl.e-small.e-bigger .e-filled.e-float-input.e-control-wrapper .e-input-in-wrap label.e-float-text,.e-small.e-bigger.e-filled.e-float-input.e-rtl:not(.e-input-focus) .e-input-in-wrap input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small.e-bigger.e-filled.e-float-input.e-control-wrapper.e-rtl:not(.e-input-focus) .e-input-in-wrap input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-rtl .e-small.e-bigger.e-filled.e-float-input:not(.e-input-focus) .e-input-in-wrap input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-rtl .e-small.e-bigger.e-filled.e-float-input.e-control-wrapper:not(.e-input-focus) .e-input-in-wrap input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small .e-bigger.e-filled.e-float-input.e-rtl:not(.e-input-focus) .e-input-in-wrap input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small .e-bigger.e-filled.e-float-input.e-control-wrapper.e-rtl:not(.e-input-focus) .e-input-in-wrap input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger .e-small.e-filled.e-float-input.e-rtl:not(.e-input-focus) .e-input-in-wrap input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger .e-small.e-filled.e-float-input.e-control-wrapper.e-rtl:not(.e-input-focus) .e-input-in-wrap input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-rtl.e-small.e-bigger .e-filled.e-float-input:not(.e-input-focus) .e-input-in-wrap input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-rtl.e-small.e-bigger .e-filled.e-float-input.e-control-wrapper:not(.e-input-focus) .e-input-in-wrap input:not(:focus):valid~label.e-float-text.e-label-bottom{right:0}.e-filled.e-input-group.e-bigger .e-input-group-icon,.e-filled.e-input-group .e-input-group-icon.e-bigger,.e-filled.e-input-group.e-control-wrapper.e-bigger .e-input-group-icon,.e-filled.e-input-group.e-control-wrapper .e-input-group-icon.e-bigger,.e-bigger .e-filled.e-input-group .e-input-group-icon,.e-bigger .e-filled.e-input-group.e-control-wrapper .e-input-group-icon,.e-filled.e-input-group.e-small.e-bigger .e-input-group-icon,.e-filled.e-input-group.e-small .e-input-group-icon.e-bigger,.e-filled.e-input-group.e-control-wrapper.e-small.e-bigger .e-input-group-icon,.e-filled.e-input-group.e-control-wrapper.e-small .e-input-group-icon.e-bigger,.e-bigger .e-filled.e-input-group.e-small .e-input-group-icon,.e-bigger .e-filled.e-input-group.e-control-wrapper.e-small .e-input-group-icon{font-size:16px;margin-bottom:0;margin-top:0;min-height:20px;min-width:20px;padding:0 0 0 8px}.e-rtl.e-filled.e-input-group.e-bigger .e-input-group-icon,.e-rtl.e-filled.e-input-group .e-input-group-icon.e-bigger,.e-rtl.e-filled.e-input-group.e-control-wrapper.e-bigger .e-input-group-icon,.e-rtl.e-filled.e-input-group.e-control-wrapper .e-input-group-icon.e-bigger,.e-bigger .e-rtl.e-filled.e-input-group .e-input-group-icon,.e-bigger .e-rtl.e-filled.e-input-group.e-control-wrapper .e-input-group-icon,.e-rtl.e-filled.e-input-group.e-small.e-bigger .e-input-group-icon,.e-rtl.e-filled.e-input-group.e-small .e-input-group-icon.e-bigger,.e-rtl.e-filled.e-input-group.e-control-wrapper.e-small.e-bigger .e-input-group-icon,.e-rtl.e-filled.e-input-group.e-control-wrapper.e-small .e-input-group-icon.e-bigger,.e-bigger .e-rtl.e-filled.e-input-group.e-small .e-input-group-icon,.e-bigger .e-rtl.e-filled.e-input-group.e-control-wrapper.e-small .e-input-group-icon,.e-rtl .e-filled.e-input-group.e-bigger .e-input-group-icon,.e-rtl .e-filled.e-input-group .e-input-group-icon.e-bigger,.e-rtl .e-filled.e-input-group.e-control-wrapper.e-bigger .e-input-group-icon,.e-rtl .e-filled.e-input-group.e-control-wrapper .e-input-group-icon.e-bigger,.e-bigger.e-rtl .e-filled.e-input-group .e-input-group-icon,.e-bigger.e-rtl .e-filled.e-input-group.e-control-wrapper .e-input-group-icon,.e-rtl .e-filled.e-input-group.e-small.e-bigger .e-input-group-icon,.e-rtl .e-filled.e-input-group.e-small .e-input-group-icon.e-bigger,.e-rtl .e-filled.e-input-group.e-control-wrapper.e-small.e-bigger .e-input-group-icon,.e-rtl .e-filled.e-input-group.e-control-wrapper.e-small .e-input-group-icon.e-bigger,.e-bigger.e-rtl .e-filled.e-input-group.e-small .e-input-group-icon,.e-bigger.e-rtl .e-filled.e-input-group.e-control-wrapper.e-small .e-input-group-icon,.e-rtl.e-filled.e-float-input.e-input-group.e-bigger .e-input-group-icon,.e-rtl.e-filled.e-float-input.e-input-group .e-input-group-icon.e-bigger,.e-bigger .e-rtl.e-filled.e-float-input.e-input-group .e-input-group-icon,.e-rtl.e-filled.e-float-input.e-control-wrapper.e-input-group.e-bigger .e-input-group-icon,.e-rtl.e-filled.e-float-input.e-control-wrapper.e-input-group .e-input-group-icon.e-bigger,.e-bigger .e-rtl.e-filled.e-float-input.e-control-wrapper.e-input-group .e-input-group-icon,.e-rtl.e-filled.e-float-input.e-input-group.e-small.e-bigger .e-input-group-icon,.e-rtl.e-filled.e-float-input.e-input-group.e-small .e-input-group-icon.e-bigger,.e-bigger .e-rtl.e-filled.e-float-input.e-input-group.e-small .e-input-group-icon,.e-rtl.e-filled.e-float-input.e-control-wrapper.e-input-group.e-small.e-bigger .e-input-group-icon,.e-rtl.e-filled.e-float-input.e-control-wrapper.e-input-group.e-small .e-input-group-icon.e-bigger,.e-bigger .e-rtl.e-filled.e-float-input.e-control-wrapper.e-input-group.e-small .e-input-group-icon,.e-rtl .e-filled.e-float-input.e-input-group.e-bigger .e-input-group-icon,.e-rtl .e-filled.e-float-input.e-input-group .e-input-group-icon.e-bigger,.e-bigger.e-rtl .e-filled.e-float-input.e-input-group .e-input-group-icon,.e-rtl .e-filled.e-float-input.e-control-wrapper.e-input-group.e-bigger .e-input-group-icon,.e-rtl .e-filled.e-float-input.e-control-wrapper.e-input-group .e-input-group-icon.e-bigger,.e-bigger.e-rtl .e-filled.e-float-input.e-control-wrapper.e-input-group .e-input-group-icon,.e-rtl .e-filled.e-float-input.e-input-group.e-small.e-bigger .e-input-group-icon,.e-rtl .e-filled.e-float-input.e-input-group.e-small .e-input-group-icon.e-bigger,.e-bigger.e-rtl .e-filled.e-float-input.e-input-group.e-small .e-input-group-icon,.e-rtl .e-filled.e-float-input.e-control-wrapper.e-input-group.e-small.e-bigger .e-input-group-icon,.e-rtl .e-filled.e-float-input.e-control-wrapper.e-input-group.e-small .e-input-group-icon.e-bigger,.e-bigger.e-rtl .e-filled.e-float-input.e-control-wrapper.e-input-group.e-small .e-input-group-icon{padding:0 8px 0 0}.e-filled.e-input-group.e-bigger .e-input-group-icon,.e-filled.e-input-group .e-input-group-icon.e-bigger,.e-filled.e-input-group.e-control-wrapper.e-bigger .e-input-group-icon,.e-filled.e-input-group.e-control-wrapper .e-input-group-icon.e-bigger,.e-bigger .e-filled.e-input-group .e-input-group-icon,.e-bigger .e-filled.e-input-group.e-control-wrapper .e-input-group-icon{font-size:20px;min-height:24px;min-width:24px;padding:0 0 0 8px}.e-filled.e-input-group.e-small.e-bigger .e-input-group-icon,.e-filled.e-input-group.e-small .e-input-group-icon.e-bigger,.e-filled.e-input-group.e-control-wrapper.e-small.e-bigger .e-input-group-icon,.e-filled.e-input-group.e-control-wrapper.e-small .e-input-group-icon.e-bigger,.e-bigger .e-filled.e-input-group.e-small .e-input-group-icon,.e-bigger .e-filled.e-input-group.e-control-wrapper.e-small .e-input-group-icon{font-size:18px;min-height:20px;min-width:20px;padding:0 0 0 8px}.e-filled.e-float-input.e-input-group.e-bigger .e-input-group-icon,.e-filled.e-float-input.e-input-group .e-input-group-icon.e-bigger,.e-bigger .e-filled.e-float-input.e-input-group .e-input-group-icon,.e-filled.e-float-input.e-control-wrapper.e-input-group.e-bigger .e-input-group-icon,.e-filled.e-float-input.e-control-wrapper.e-input-group .e-input-group-icon.e-bigger,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-input-group .e-input-group-icon,.e-filled.e-float-input.e-input-group.e-small.e-bigger .e-input-group-icon,.e-filled.e-float-input.e-input-group.e-small .e-input-group-icon.e-bigger,.e-bigger .e-filled.e-float-input.e-input-group.e-small .e-input-group-icon,.e-filled.e-float-input.e-control-wrapper.e-input-group.e-small.e-bigger .e-input-group-icon,.e-filled.e-float-input.e-control-wrapper.e-input-group.e-small .e-input-group-icon.e-bigger,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-input-group.e-small .e-input-group-icon{font-size:16px;margin-bottom:0;margin-top:0;padding:8px}.e-filled.e-float-input.e-input-group.e-bigger .e-input-group-icon,.e-filled.e-float-input.e-input-group .e-input-group-icon.e-bigger,.e-bigger .e-filled.e-float-input.e-input-group .e-input-group-icon,.e-filled.e-float-input.e-control-wrapper.e-input-group.e-bigger .e-input-group-icon,.e-filled.e-float-input.e-control-wrapper.e-input-group .e-input-group-icon.e-bigger,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-input-group .e-input-group-icon{font-size:20px;padding:0 0 0 8px}.e-filled.e-float-input.e-input-group.e-small.e-bigger .e-input-group-icon,.e-filled.e-float-input.e-input-group.e-small .e-input-group-icon.e-bigger,.e-bigger .e-filled.e-float-input.e-input-group.e-small .e-input-group-icon,.e-filled.e-float-input.e-control-wrapper.e-input-group.e-small.e-bigger .e-input-group-icon,.e-filled.e-float-input.e-control-wrapper.e-input-group.e-small .e-input-group-icon.e-bigger,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-input-group.e-small .e-input-group-icon{font-size:18px;padding:0 0 0 8px}.e-filled.e-input-group.e-bigger .e-clear-icon,.e-filled.e-input-group.e-control-wrapper.e-bigger .e-clear-icon,.e-filled.e-input-group .e-clear-icon.e-bigger,.e-filled.e-input-group.e-control-wrapper .e-clear-icon.e-bigger,.e-bigger .e-filled.e-input-group .e-clear-icon,.e-bigger .e-filled.e-input-group.e-control-wrapper .e-clear-icon{font-size:20px;min-height:24px;min-width:24px;padding:0 0 0 8px}.e-filled.e-input-group.e-float-input.e-bigger .e-clear-icon,.e-filled.e-input-group.e-float-input .e-clear-icon.e-bigger,.e-bigger .e-filled.e-input-group.e-float-input .e-clear-icon,.e-filled.e-input-group.e-control-wrapper.e-float-input.e-bigger .e-clear-icon,.e-filled.e-input-group.e-control-wrapper.e-float-input .e-clear-icon.e-bigger,.e-bigger .e-filled.e-input-group.e-control-wrapper.e-float-input .e-clear-icon{padding:0 0 0 8px}.e-filled.e-input-group.e-small.e-bigger .e-clear-icon,.e-filled.e-input-group.e-small .e-clear-icon.e-bigger,.e-bigger .e-filled.e-input-group.e-small .e-clear-icon,.e-filled.e-input-group.e-control-wrapper.e-small.e-bigger .e-clear-icon,.e-filled.e-input-group.e-control-wrapper.e-small .e-clear-icon.e-bigger,.e-bigger .e-filled.e-input-group.e-control-wrapper.e-small .e-clear-icon{font-size:18px;min-height:20px;min-width:20px;padding:0 0 0 8px}.e-filled.e-input-group.e-float-input.e-small.e-bigger .e-clear-icon,.e-filled.e-input-group.e-float-input.e-small .e-clear-icon.e-bigger,.e-bigger .e-filled.e-input-group.e-float-input.e-small .e-clear-icon,.e-filled.e-input-group.e-control-wrapper.e-float-input.e-small.e-bigger .e-clear-icon,.e-filled.e-input-group.e-control-wrapper.e-float-input.e-small .e-clear-icon.e-bigger,.e-bigger .e-filled.e-input-group.e-control-wrapper.e-float-input.e-small .e-clear-icon,.e-filled.e-input-group.e-float-input.e-control-wrapper.e-small.e-bigger .e-clear-icon,.e-filled.e-input-group.e-float-input.e-control-wrapper.e-small .e-clear-icon.e-bigger,.e-bigger .e-filled.e-input-group.e-float-input.e-control-wrapper.e-small .e-clear-icon{padding:0 0 0 8px}.e-rtl.e-filled.e-input-group.e-bigger .e-clear-icon,.e-rtl.e-filled.e-input-group .e-clear-icon.e-bigger,.e-rtl.e-filled.e-input-group.e-control-wrapper.e-bigger .e-clear-icon,.e-rtl.e-filled.e-input-group.e-control-wrapper .e-clear-icon.e-bigger,.e-bigger .e-rtl.e-filled.e-input-group .e-clear-icon,.e-bigger .e-rtl.e-filled.e-input-group.e-control-wrapper .e-clear-icon,.e-rtl.e-filled.e-input-group.e-small.e-bigger .e-clear-icon,.e-rtl.e-filled.e-input-group.e-small .e-clear-icon.e-bigger,.e-rtl.e-filled.e-input-group.e-control-wrapper.e-small.e-bigger .e-clear-icon,.e-rtl.e-filled.e-input-group.e-control-wrapper.e-small .e-clear-icon.e-bigger,.e-bigger .e-rtl.e-filled.e-input-group.e-small .e-clear-icon,.e-bigger .e-rtl.e-filled.e-input-group.e-control-wrapper.e-small .e-clear-icon,.e-rtl.e-filled.e-input-group.e-small .e-clear-icon,.e-rtl .e-filled.e-input-group.e-bigger .e-clear-icon,.e-rtl .e-filled.e-input-group .e-clear-icon.e-bigger,.e-rtl .e-filled.e-input-group.e-control-wrapper.e-bigger .e-clear-icon,.e-rtl .e-filled.e-input-group.e-control-wrapper .e-clear-icon.e-bigger,.e-bigger.e-rtl .e-filled.e-input-group .e-clear-icon,.e-bigger.e-rtl .e-filled.e-input-group.e-control-wrapper .e-clear-icon,.e-rtl .e-filled.e-input-group.e-small.e-bigger .e-clear-icon,.e-rtl .e-filled.e-input-group.e-small .e-clear-icon.e-bigger,.e-rtl .e-filled.e-input-group.e-control-wrapper.e-small.e-bigger .e-clear-icon,.e-rtl .e-filled.e-input-group.e-control-wrapper.e-small .e-clear-icon.e-bigger,.e-bigger.e-rtl .e-filled.e-input-group.e-small .e-clear-icon,.e-bigger.e-rtl .e-filled.e-input-group.e-control-wrapper.e-small .e-clear-icon,.e-rtl.e-filled.e-float-input.e-input-group.e-bigger .e-clear-icon,.e-rtl.e-filled.e-float-input.e-input-group .e-clear-icon.e-bigger,.e-bigger .e-rtl.e-filled.e-float-input.e-input-group .e-clear-icon,.e-rtl.e-filled.e-float-input.e-control-wrapper.e-input-group.e-bigger .e-clear-icon,.e-rtl.e-filled.e-float-input.e-control-wrapper.e-input-group .e-clear-icon.e-bigger,.e-bigger .e-rtl.e-filled.e-float-input.e-control-wrapper.e-input-group .e-clear-icon,.e-rtl.e-filled.e-float-input.e-input-group.e-small.e-bigger .e-clear-icon,.e-rtl.e-filled.e-float-input.e-input-group.e-small .e-clear-icon.e-bigger,.e-bigger .e-rtl.e-filled.e-float-input.e-input-group.e-small .e-clear-icon,.e-rtl.e-filled.e-float-input.e-control-wrapper.e-input-group.e-small.e-bigger .e-clear-icon,.e-rtl.e-filled.e-float-input.e-control-wrapper.e-input-group.e-small .e-clear-icon.e-bigger,.e-bigger .e-rtl.e-filled.e-float-input.e-control-wrapper.e-input-group.e-small .e-clear-icon,.e-rtl .e-filled.e-float-input.e-input-group.e-bigger .e-clear-icon,.e-rtl .e-filled.e-float-input.e-input-group .e-clear-icon.e-bigger,.e-bigger.e-rtl .e-filled.e-float-input.e-input-group .e-clear-icon,.e-rtl .e-filled.e-float-input.e-control-wrapper.e-input-group.e-bigger .e-clear-icon,.e-rtl .e-filled.e-float-input.e-control-wrapper.e-input-group .e-clear-icon.e-bigger,.e-bigger.e-rtl .e-filled.e-float-input.e-control-wrapper.e-input-group .e-clear-icon,.e-rtl .e-filled.e-float-input.e-input-group.e-small.e-bigger .e-clear-icon,.e-rtl .e-filled.e-float-input.e-input-group.e-small .e-clear-icon.e-bigger,.e-bigger.e-rtl .e-filled.e-float-input.e-input-group.e-small .e-clear-icon,.e-rtl .e-filled.e-float-input.e-control-wrapper.e-input-group.e-small.e-bigger .e-clear-icon,.e-rtl .e-filled.e-float-input.e-control-wrapper.e-input-group.e-small .e-clear-icon.e-bigger,.e-bigger.e-rtl .e-filled.e-float-input.e-control-wrapper.e-input-group.e-small .e-clear-icon{padding:0 8px 0 0}.e-filled.e-float-input.e-bigger .e-clear-icon:before,.e-filled.e-float-input.e-control-wrapper.e-bigger .e-clear-icon:before,.e-filled.e-input-group.e-bigger .e-clear-icon:before,.e-filled.e-input-group.e-control-wrapper.e-bigger .e-clear-icon:before,.e-filled.e-float-input.e-control-wrapper input.e-bigger:first-child~.e-clear-icon:before,.e-bigger .e-filled.e-float-input.e-control-wrapper .e-clear-icon:before,.e-filled.e-float-input input.e-bigger:first-child~.e-clear-icon:before,.e-bigger .e-filled.e-float-input .e-clear-icon:before,.e-bigger .e-filled.e-input-group .e-clear-icon:before,.e-bigger .e-filled.e-input-group.e-control-wrapper .e-clear-icon:before{font-size:20px}.e-filled.e-float-input.e-small.e-bigger .e-clear-icon:before,.e-filled.e-float-input.e-control-wrapper.e-small.e-bigger .e-clear-icon:before,.e-filled.e-input-group.e-small.e-bigger .e-clear-icon:before,.e-filled.e-input-group.e-control-wrapper.e-small.e-bigger .e-clear-icon:before,.e-small .e-filled.e-input-group.e-bigger input:first-child~.e-clear-icon:before,.e-small .e-filled.e-input-group.e-control-wrapper.e-bigger input:first-child~.e-clear-icon:before,.e-bigger .e-filled.e-input-group.e-small input:first-child~.e-clear-icon:before,.e-bigger .e-filled.e-input-group.e-control-wrapper.e-small input:first-child~.e-clear-icon:before,.e-small .e-filled.e-float-input.e-control-wrapper.e-bigger input:first-child~.e-clear-icon:before,.e-small .e-filled.e-float-input.e-bigger input:first-child~.e-clear-icon:before,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-small input:first-child~.e-clear-icon:before,.e-bigger .e-filled.e-float-input.e-small input:first-child~.e-clear-icon:before{font-size:18px}.e-filled.e-float-input.e-bigger .e-input-in-wrap input:focus~label.e-float-text,.e-filled.e-float-input.e-bigger .e-input-in-wrap input:valid~label.e-float-text,.e-filled.e-float-input.e-bigger .e-input-in-wrap input~label.e-label-top.e-float-text,.e-filled.e-float-input.e-bigger .e-input-in-wrap input[readonly]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-bigger .e-input-in-wrap input[disabled]~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input .e-input-in-wrap input:focus~label.e-float-text,.e-bigger .e-filled.e-float-input .e-input-in-wrap input:valid~label.e-float-text,.e-bigger .e-filled.e-float-input .e-input-in-wrap input~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input .e-input-in-wrap input[readonly]~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input .e-input-in-wrap input[disabled]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-bigger .e-input-in-wrap input:focus~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-bigger .e-input-in-wrap input:valid~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-bigger .e-input-in-wrap input~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-bigger .e-input-in-wrap input[readonly]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-bigger .e-input-in-wrap input[disabled]~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper .e-input-in-wrap input:focus~label.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper .e-input-in-wrap input:valid~label.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper .e-input-in-wrap input~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper .e-input-in-wrap input[readonly]~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper .e-input-in-wrap input[disabled]~label.e-label-top.e-float-text{top:18px}.e-filled.e-float-input.e-small.e-bigger .e-input-in-wrap input:focus~label.e-float-text,.e-filled.e-float-input.e-small.e-bigger .e-input-in-wrap input:valid~label.e-float-text,.e-filled.e-float-input.e-small.e-bigger .e-input-in-wrap input~label.e-label-top.e-float-text,.e-filled.e-float-input.e-small.e-bigger .e-input-in-wrap input[readonly]~label.e-float-text,.e-filled.e-float-input.e-small.e-bigger .e-input-in-wrap input[disabled]~label.e-float-text,.e-bigger .e-filled.e-float-input.e-small .e-input-in-wrap input:focus~label.e-float-text,.e-bigger .e-filled.e-float-input.e-small .e-input-in-wrap input:valid~label.e-float-text,.e-bigger .e-filled.e-float-input.e-small .e-input-in-wrap input~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input.e-small .e-input-in-wrap input[readonly]~label.e-float-text,.e-bigger .e-filled.e-float-input.e-small .e-input-in-wrap input[disabled]~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small.e-bigger .e-input-in-wrap input:focus~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small.e-bigger .e-input-in-wrap input:valid~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small.e-bigger .e-input-in-wrap input~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small.e-bigger .e-input-in-wrap input[readonly]~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small.e-bigger .e-input-in-wrap input[disabled]~label.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-small .e-input-in-wrap input:focus~label.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-small .e-input-in-wrap input:valid~label.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-small .e-input-in-wrap input~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-small .e-input-in-wrap input[readonly]~label.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-small .e-input-in-wrap input[disabled]~label.e-float-text{top:12px}.e-filled.e-float-input.e-bigger .e-input-in-wrap label.e-float-text,.e-filled.e-float-input .e-input-in-wrap label.e-float-text.e-bigger,.e-filled.e-float-input .e-input-in-wrap input.e-bigger~label.e-float-text,.e-bigger .e-filled.e-float-input .e-input-in-wrap label.e-float-text,.e-filled.e-float-input.e-bigger:not(.e-input-focus) .e-input-in-wrap input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger .e-filled.e-float-input:not(.e-input-focus) .e-input-in-wrap input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-filled.e-float-input.e-control-wrapper.e-bigger .e-input-in-wrap label.e-float-text,.e-filled.e-float-input.e-control-wrapper .e-input-in-wrap label.e-float-text.e-bigger,.e-filled.e-float-input.e-control-wrapper .e-input-in-wrap input.e-bigger~label.e-float-text,.e-bigger.e-filled.e-float-input.e-control-wrapper .e-input-in-wrap label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-bigger:not(.e-input-focus) .e-input-in-wrap input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger.e-filled.e-float-input.e-control-wrapper:not(.e-input-focus) .e-input-in-wrap input:not(:focus):valid~label.e-float-text.e-label-bottom{top:18px}.e-filled.e-float-input.e-small.e-bigger .e-input-in-wrap label.e-float-text,.e-bigger .e-filled.e-float-input.e-small .e-input-in-wrap label.e-float-text,.e-bigger .e-filled.e-float-input.e-small:not(.e-input-focus) .e-input-in-wrap input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small .e-filled.e-float-input.e-bigger:not(.e-input-focus) .e-input-in-wrap input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-filled.e-float-input.e-bigger.e-small:not(.e-input-focus) .e-input-in-wrap input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger.e-small .e-filled.e-float-input:not(.e-input-focus) .e-input-in-wrap input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-filled.e-float-input.e-control-wrapper.e-small.e-bigger .e-input-in-wrap label.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-small .e-input-in-wrap label.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-small:not(.e-input-focus) .e-input-in-wrap input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small .e-filled.e-float-input.e-control-wrapper.e-bigger:not(.e-input-focus) .e-input-in-wrap input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-filled.e-float-input.e-control-wrapper.e-bigger.e-small:not(.e-input-focus) .e-input-in-wrap input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger.e-small .e-filled.e-float-input.e-control-wrapper:not(.e-input-focus) .e-input-in-wrap input:not(:focus):valid~label.e-float-text.e-label-bottom{top:12px}.e-filled.e-input-group:not(.e-float-input).e-bigger.e-float-icon-left>.e-input-group-icon,.e-filled.e-input-group:not(.e-float-input).e-float-icon-left>.e-input-group-icon.e-bigger,.e-bigger .e-filled.e-input-group:not(.e-float-input).e-float-icon-left>.e-input-group-icon,.e-filled.e-input-group:not(.e-float-input).e-control-wrapper.e-bigger.e-float-icon-left>.e-input-group-icon,.e-filled.e-input-group:not(.e-float-input).e-control-wrapper.e-float-icon-left>.e-input-group-icon.e-bigger,.e-bigger .e-filled.e-input-group:not(.e-float-input).e-control-wrapper.e-float-icon-left>.e-input-group-icon{font-size:20px;margin:0;min-height:24px;min-width:24px;padding:0}.e-filled.e-input-group:not(.e-float-input).e-small.e-bigger.e-float-icon-left>.e-input-group-icon,.e-filled.e-input-group:not(.e-float-input).e-small.e-float-icon-left>.e-input-group-icon.e-bigger,.e-bigger .e-filled.e-input-group:not(.e-float-input).e-small.e-float-icon-left>.e-input-group-icon,.e-filled.e-input-group.e-control-wrapper:not(.e-float-input).e-small.e-bigger.e-float-icon-left>.e-input-group-icon,.e-filled.e-input-group.e-control-wrapper:not(.e-float-input).e-small.e-float-icon-left>.e-input-group-icon.e-bigger,.e-bigger .e-filled.e-input-group.e-control-wrapper:not(.e-float-input).e-small.e-float-icon-left>.e-input-group-icon{font-size:18px;margin:0;min-height:20px;min-width:20px;padding:0}.e-filled.e-input-group.e-bigger.e-float-icon-left>.e-input-group-icon,.e-filled.e-input-group.e-float-icon-left>.e-input-group-icon.e-bigger,.e-bigger .e-filled.e-input-group.e-float-icon-left>.e-input-group-icon,.e-filled.e-float-input.e-input-group.e-bigger.e-float-icon-left>.e-input-group-icon,.e-filled.e-float-input.e-input-group.e-float-icon-left>.e-input-group-icon.e-bigger,.e-bigger .e-filled.e-float-input.e-input-group.e-float-icon-left>.e-input-group-icon,.e-filled.e-input-group.e-control-wrapper.e-bigger.e-float-icon-left>.e-input-group-icon,.e-filled.e-input-group.e-control-wrapper.e-float-icon-left>.e-input-group-icon.e-bigger,.e-bigger .e-filled.e-input-group.e-control-wrapper.e-float-icon-left>.e-input-group-icon,.e-filled.e-float-input.e-input-group.e-control-wrapper.e-bigger.e-float-icon-left>.e-input-group-icon,.e-filled.e-float-input.e-input-group.e-control-wrapper.e-float-icon-left>.e-input-group-icon.e-bigger,.e-bigger .e-filled.e-float-input.e-input-group.e-control-wrapper.e-float-icon-left>.e-input-group-icon{margin:0;min-height:24px;min-width:24px;padding:0}.e-filled.e-input-group.e-small.e-bigger.e-float-icon-left>.e-input-group-icon,.e-filled.e-input-group.e-small.e-float-icon-left>.e-input-group-icon.e-bigger,.e-bigger .e-filled.e-input-group.e-small.e-float-icon-left>.e-input-group-icon,.e-filled.e-float-input.e-input-group.e-small.e-bigger.e-float-icon-left>.e-input-group-icon,.e-filled.e-float-input.e-input-group.e-small.e-float-icon-left>.e-input-group-icon.e-bigger,.e-bigger .e-filled.e-input-group.e-float-input.e-small.e-float-icon-left>.e-input-group-icon,.e-filled.e-input-group.e-control-wrapper.e-small.e-bigger.e-float-icon-left>.e-input-group-icon,.e-filled.e-input-group.e-control-wrapper.e-small.e-float-icon-left>.e-input-group-icon.e-bigger,.e-bigger .e-filled.e-input-group.e-control-wrapper.e-small.e-float-icon-left>.e-input-group-icon,.e-filled.e-float-input.e-control-wrapper.e-input-group.e-small.e-bigger.e-float-icon-left>.e-input-group-icon,.e-filled.e-float-input.e-control-wrapper.e-input-group.e-small.e-float-icon-left>.e-input-group-icon.e-bigger,.e-bigger .e-filled.e-input-group.e-control-wrapper.e-float-input.e-small.e-float-icon-left>.e-input-group-icon{margin:0;min-height:20px;min-width:20px;padding:0}.e-filled.e-float-input.e-bigger .e-input-in-wrap label.e-float-text,.e-filled.e-float-input.e-bigger .e-input-in-wrap label.e-float-text.e-label-bottom,.e-filled.e-float-input.e-control-wrapper.e-bigger .e-input-in-wrap label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-bigger .e-input-in-wrap label.e-float-text.e-label-bottom,.e-filled.e-float-input.e-bigger:not(.e-input-focus) .e-input-in-wrap input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-filled.e-float-input.e-control-wrapper.e-bigger:not(.e-input-focus) .e-input-in-wrap input:not(:focus):valid~label.e-float-text.e-label-bottom .e-bigger .e-filled.e-float-input .e-input-in-wrap label.e-float-text,.e-bigger .e-filled.e-float-input .e-input-in-wrap label.e-float-text.e-label-bottom,.e-bigger .e-filled.e-float-input.e-control-wrapper .e-input-in-wrap label.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper .e-input-in-wrap label.e-float-text.e-label-bottom,.e-bigger .e-filled.e-float-input:not(.e-input-focus) .e-input-in-wrap input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger .e-filled.e-float-input.e-control-wrapper:not(.e-input-focus) .e-input-in-wrap input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-filled.e-float-input.e-small.e-bigger .e-input-in-wrap label.e-float-text,.e-filled.e-float-input.e-small.e-bigger .e-input-in-wrap label.e-float-text.e-label-bottom,.e-filled.e-float-input.e-control-wrapper.e-small.e-bigger .e-input-in-wrap label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small.e-bigger .e-input-in-wrap label.e-float-text.e-label-bottom,.e-filled.e-float-input.e-small.e-bigger:not(.e-input-focus) .e-input-in-wrap input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-filled.e-float-input.e-control-wrapper.e-small.e-bigger:not(.e-input-focus) .e-input-in-wrap input:not(:focus):valid~label.e-float-text.e-label-bottom .e-small.e-bigger .e-filled.e-float-input .e-input-in-wrap label.e-float-text,.e-small.e-bigger .e-filled.e-float-input .e-input-in-wrap label.e-float-text.e-label-bottom,.e-filled.e-float-input.e-control-wrapper.e-small:not(.e-input-focus) .e-input-in-wrap input:not(:focus):valid~label.e-float-text.e-label-bottom .e-small .e-filled.e-float-input.e-bigger .e-input-in-wrap label.e-float-text,.e-small.e-bigger .e-filled.e-float-input.e-control-wrapper .e-input-in-wrap label.e-float-text,.e-small.e-bigger .e-filled.e-float-input.e-control-wrapper .e-input-in-wrap label.e-float-text.e-label-bottom,.e-small.e-bigger .e-filled.e-float-input:not(.e-input-focus) .e-input-in-wrap input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-small.e-bigger .e-filled.e-float-input.e-control-wrapper:not(.e-input-focus) .e-input-in-wrap input:not(:focus):valid~label.e-float-text.e-label-bottom{left:0}.e-filled.e-input-group.e-bigger .e-input-group-icon:last-child,.e-bigger .e-filled.e-input-group .e-input-group-icon:last-child,.e-filled.e-input-group.e-small.e-bigger .e-input-group-icon:last-child,.e-small.e-bigger .e-filled.e-input-group .e-input-group-icon:last-child,.e-bigger .e-filled.e-input-group.e-small .e-input-group-icon:last-child,.e-small .e-filled.e-input-group.e-bigger .e-input-group-icon:last-child,.e-filled.e-input-group.e-bigger.e-control-wrapper .e-input-group-icon:last-child,.e-bigger .e-filled.e-input-group.e-control-wrapper .e-input-group-icon:last-child,.e-filled.e-input-group.e-small.e-bigger.e-control-wrapper .e-input-group-icon:last-child,.e-small.e-bigger .e-filled.e-input-group.e-control-wrapper .e-input-group-icon:last-child,.e-bigger .e-filled.e-input-group.e-small.e-control-wrapper .e-input-group-icon:last-child,.e-small .e-filled.e-input-group.e-bigger.e-control-wrapper .e-input-group-icon:last-child,.e-filled.e-input-group.e-small.e-bigger .e-input-group-icon,.e-filled.e-input-group.e-control-wrapper.e-small.e-bigger .e-input-group-icon,.e-small.e-bigger .e-filled.e-input-group .e-input-group-icon,.e-small.e-bigger .e-filled.e-input-group.e-control-wrapper .e-input-group-icon{margin-right:0}.e-filled.e-input-group.e-bigger.e-rtl .e-input-group-icon:last-child,.e-bigger .e-filled.e-input-group.e-rtl .e-input-group-icon:last-child,.e-filled.e-input-group.e-small.e-bigger.e-rtl .e-input-group-icon:last-child,.e-small.e-bigger .e-filled.e-input-group.e-rtl .e-input-group-icon:last-child,.e-bigger .e-filled.e-input-group.e-small.e-rtl .e-input-group-icon:last-child,.e-small .e-filled.e-input-group.e-bigger.e-rtl .e-input-group-icon:last-child,.e-filled.e-input-group.e-bigger.e-control-wrapper.e-rtl .e-input-group-icon:last-child,.e-bigger .e-filled.e-input-group.e-control-wrapper.e-rtl .e-input-group-icon:last-child,.e-filled.e-input-group.e-small.e-bigger.e-control-wrapper.e-rtl .e-input-group-icon:last-child,.e-small.e-bigger .e-filled.e-input-group.e-control-wrapper.e-rtl .e-input-group-icon:last-child,.e-bigger .e-filled.e-input-group.e-small.e-control-wrapper.e-rtl .e-input-group-icon:last-child,.e-small .e-filled.e-input-group.e-bigger.e-control-wrapper.e-rtl .e-input-group-icon:last-child,.e-rtl .e-filled.e-input-group.e-bigger .e-input-group-icon:last-child,.e-rtl.e-bigger .e-filled.e-input-group .e-input-group-icon:last-child,.e-rtl .e-filled.e-input-group.e-small.e-bigger .e-input-group-icon:last-child,.e-rtl.e-small.e-bigger .e-filled.e-input-group .e-input-group-icon:last-child,.e-rtl.e-bigger .e-filled.e-input-group.e-small .e-input-group-icon:last-child,.e-rtl.e-small .e-filled.e-input-group.e-bigger .e-input-group-icon:last-child,.e-rtl .e-filled.e-input-group.e-bigger.e-control-wrapper .e-input-group-icon:last-child,.e-rtl.e-bigger .e-filled.e-input-group.e-control-wrapper .e-input-group-icon:last-child,.e-rtl .e-filled.e-input-group.e-small.e-bigger.e-control-wrapper .e-input-group-icon:last-child,.e-rtl.e-small.e-bigger .e-filled.e-input-group.e-control-wrapper .e-input-group-icon:last-child,.e-rtl.e-bigger .e-filled.e-input-group.e-small.e-control-wrapper .e-input-group-icon:last-child,.e-rtl.e-small .e-filled.e-input-group.e-bigger.e-control-wrapper .e-input-group-icon:last-child{margin-left:0}.e-filled.e-rtl.e-input-group.e-small.e-bigger .e-input-group-icon,.e-filled.e-rtl.e-input-group.e-control-wrapper.e-small.e-bigger .e-input-group-icon,.e-small.e-bigger .e-rtl.e-filled.e-input-group .e-input-group-icon,.e-small.e-bigger .e-rtl.e-filled.e-input-group.e-control-wrapper .e-input-group-icon,.e-rtl .e-filled.e-input-group.e-small.e-bigger .e-input-group-icon,.e-rtl .e-filled.e-input-group.e-control-wrapper.e-small.e-bigger .e-input-group-icon,.e-rtl.e-small.e-bigger .e-filled.e-input-group .e-input-group-icon,.e-rtl.e-small.e-bigger .e-filled.e-input-group.e-control-wrapper .e-input-group-icon{margin-left:0;margin-right:0}.e-filled.e-input-group.e-bigger textarea,.e-filled.e-input-group.e-bigger textarea.e-input,.e-filled.e-input-group textarea.e-bigger,.e-filled.e-input-group textarea.e-input.e-bigger,.e-filled.e-input-group.e-control-wrapper.e-bigger textarea,.e-filled.e-input-group.e-control-wrapper.e-bigger textarea.e-input,.e-filled.e-input-group.e-control-wrapper textarea.e-bigger,.e-filled.e-input-group.e-control-wrapper textarea.e-input.e-bigger,.e-bigger .e-filled.e-input-group textarea,.e-bigger .e-filled.e-input-group textarea.e-input,.e-bigger .e-filled.e-input-group.e-control-wrapper textarea,.e-bigger .e-filled.e-input-group.e-control-wrapper textarea.e-input,.e-filled.e-input-group.e-input-focus.e-bigger textarea,.e-filled.e-input-group.e-input-focus.e-bigger textarea.e-input,.e-filled.e-input-group.e-input-focus textarea.e-bigger,.e-filled.e-input-group.e-input-focus textarea.e-input.e-bigger,.e-filled.e-input-group.e-control-wrapper.e-input-focus.e-bigger textarea,.e-filled.e-input-group.e-control-wrapper.e-input-focus.e-bigger textarea.e-input,.e-filled.e-input-group.e-control-wrapper.e-input-focus textarea.e-bigger,.e-filled.e-input-group.e-control-wrapper.e-input-focus textarea.e-input.e-bigger,.e-bigger .e-filled.e-input-group.e-input-focus textarea,.e-bigger .e-filled.e-input-group.e-control-wrapper.e-input-focus textarea,.e-bigger .e-filled.e-input-group.e-control-wrapper.e-input-focus textarea.e-input,.e-filled.e-float-input.e-bigger textarea,.e-filled.e-float-input textarea.e-bigger,.e-filled.e-float-input.e-control-wrapper.e-bigger textarea,.e-filled.e-float-input.e-control-wrapper textarea.e-bigger,.e-bigger .e-filled.e-float-input textarea,.e-bigger .e-filled.e-float-input.e-control-wrapper textarea{padding:0 16px 8px}.e-filled.e-input-group.e-small.e-bigger textarea.e-input,.e-filled.e-input-group.e-small textarea.e-input.e-bigger,.e-filled.e-input-group textarea.e-input.e-bigger.e-small,.e-filled.e-input-group.e-bigger textarea.e-small,.e-filled.e-input-group.e-control-wrapper.e-small.e-bigger textarea.e-input,.e-filled.e-input-group.e-control-wrapper.e-small textarea.e-input.e-bigger,.e-bigger.e-small .e-filled.e-input-group textarea.e-input,.e-bigger.e-small .e-filled.e-input-group.e-control-wrapper textarea.e-input,.e-bigger .input-group textarea.e-small,.e-bigger .e-filled.e-input-group.e-small textarea.e-input,.e-bigger .e-filled.e-input-group.e-control-wrapper.e-small textarea.e-input,.e-bigger .e-small.e-filled.e-input-group.e-control-wrapper textarea.e-input,.e-small .input-group textarea.e-bigger,.e-small .e-filled.e-input-group.e-bigger textarea.e-input,.e-small .e-filled.e-input-group.e-control-wrapper textarea.e-input.e-bigger,.e-small .e-filled.e-input-group.e-control-wrapper.e-input-focus textarea.e-input.e-bigger,.e-filled.e-input-group.e-input-focus textarea.e-input.e-bigger.e-small,.e-filled.e-input-group.e-input-focus.e-small.e-bigger textarea.e-input,.e-filled.e-input-group.e-input-focus.e-small textarea.e-input.e-bigger,.e-filled.e-input-group.e-input-focus.e-bigger textarea.e-small,.e-filled.e-input-group.e-control-wrapper.e-input-focus.e-small.e-bigger textarea.e-input,.e-filled.e-input-group.e-control-wrapper.e-input-focus.e-small textarea.e-input.e-bigger,.e-bigger.e-small .e-filled.e-input-group.e-input-focus textarea.e-input,.e-bigger .e-filled.e-input-group.e-control-wrapper.e-input-focus.e-small textarea.e-input,.e-bigger.e-small .e-filled.e-input-group.e-control-wrapper.e-input-focus textarea.e-input,.e-bigger .e-small.e-filled.e-input-group.e-control-wrapper.e-input-focus textarea.e-input{padding:0 12px 10px}.e-filled.e-float-input textarea.e-bigger.e-small,.e-filled.e-float-input.e-small.e-bigger textarea,.e-filled.e-float-input.e-small textarea.e-bigger,.e-filled.e-float-input.e-bigger textarea.e-small,.e-bigger .e-filled.e-float-input.e-small textarea,.e-bigger.e-small .e-filled.e-float-input textarea,.e-bigger .e-float-input textarea.e-small,.e-small .e-filled.e-float-input.e-bigger textarea,.e-small .float-input textarea.e-bigger,.e-small .e-filled.e-float-input.e-control-wrapper textarea.e-bigger,.e-filled.e-float-input.e-control-wrapper.e-small.e-bigger textarea,.e-filled.e-float-input.e-control-wrapper.e-small textarea.e-bigger,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-small textarea,.e-bigger.e-small .e-filled.e-float-input.e-control-wrapper textarea,.e-bigger .e-small.e-filled.e-float-input.e-control-wrapper textarea{padding:0 12px 5px}.e-filled.e-input-group.e-multi-line-input.e-bigger,.e-bigger .e-filled.e-input-group.e-multi-line-input,.e-filled.e-input-group.e-control-wrapper.e-bigger.e-multi-line-input,.e-bigger .e-filled.e-input-group.e-control-wrapper.e-multi-line-input{padding:16px 0 0}.e-filled.e-input-group.e-small.e-bigger.e-multi-line-input,.e-bigger.e-small .e-filled.e-input-group.e-small.e-multi-line-input,.e-bigger .e-filled.e-input-group.e-small.e-multi-line-input,.e-small .e-filled.e-input-group.e-bigger.e-multi-line-input,.e-filled.e-input-group.e-control-wrapper.e-small.e-bigger.e-multi-line-input,.e-bigger.e-small .e-filled.e-input-group.e-control-wrapper.e-small.e-multi-line-input,.e-bigger .e-filled.e-input-group.e-control-wrapper.e-small.e-multi-line-input,.e-small .e-filled.e-input-group.e-control-wrapper.e-bigger.e-multi-line-input{padding:10px 0 0}.e-filled.e-float-input.e-bigger.e-multi-line-input,.e-bigger .e-filled.e-float-input.e-multi-line-input,.e-filled.e-float-input.e-control-wrapper.e-bigger.e-multi-line-input,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-multi-line-input{padding:20px 0 0}.e-filled.e-float-input.e-small.e-bigger.e-multi-line-input,.e-bigger.e-small .e-filled.e-float-input.e-small.e-multi-line-input,.e-bigger .e-filled.e-float-input.e-small.e-multi-line-input,.e-small .e-filled.e-float-input.e-bigger.e-multi-line-input,.e-filled.e-float-input.e-control-wrapper.e-small.e-bigger.e-multi-line-input,.e-bigger.e-small .e-filled.e-float-input.e-control-wrapper.e-small.e-multi-line-input,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-small.e-multi-line-input,.e-small .e-filled.e-float-input.e-control-wrapper.e-bigger.e-multi-line-input{padding:14px 0 0}.e-rtl .e-filled textarea.e-input.e-bigger,.e-filled textarea.e-input.e-bigger.e-rtl,.e-bigger.e-rtl .e-filled textarea.e-input,.e-bigger .e-filled textarea.e-input.e-rtl,.e-filled.e-input-group.e-multi-line-input.e-bigger.e-rtl textarea.e-input,.e-filled.e-input-group.e-multi-line-input.e-control-wrapper.e-bigger.e-rtl textarea.e-input,.e-rtl .e-filled.e-input-group.e-multi-line-input.e-bigger textarea.e-input,.e-rtl .e-filled.e-input-group.e-multi-line-input.e-control-wrapper.e-bigger textarea.e-input,.e-filled.e-input-group.e-multi-line-input.e-rtl textarea.e-input.e-bigger,.e-filled.e-input-group.e-multi-line-input.e-control-wrapper.e-rtl textarea.e-input.e-bigger,.e-rtl .e-filled.e-input-group.e-multi-line-input textarea.e-input.e-bigger,.e-rtl .e-filled.e-input-group.e-multi-line-input.e-control-wrapper textarea.e-input.e-bigger,.e-bigger .e-filled.e-input-group.e-multi-line-input.e-rtl textarea.e-input,.e-bigger .e-filled.e-input-group.e-multi-line-input.e-control-wrapper.e-rtl textarea.e-input,.e-bigger.e-rtl .e-filled.e-input-group.e-multi-line-input textarea.e-input,.e-bigger.e-rtl .e-filled.e-input-group.e-multi-line-input.e-control-wrapper textarea.e-input,.e-bigger.e-rtl .e-filled.e-input-group.e-multi-line-input textarea.e-input:focus,.e-bigger.e-rtl .e-filled.e-input-group.e-multi-line-input.e-control-wrapper textarea.e-input:focus,.e-bigger .e-filled.e-input-group.e-multi-line-input.e-rtl textarea.e-input:focus,.e-bigger .e-filled.e-input-group.e-multi-line-input.e-control-wrapper.e-rtl textarea.e-input:focus{padding:0 16px 8px;text-indent:0}.e-filled.e-float-input.e-multi-line-input.e-control-wrapper.e-bigger.e-rtl textarea,.e-filled.e-float-input.e-multi-line-input.e-bigger.e-rtl textarea,.e-rtl .e-filled.e-float-input.e-multi-line-input.e-control-wrapper.e-bigger textarea,.e-rtl .e-filled.e-float-input.e-multi-line-input.e-bigger textarea,.e-filled.e-float-input.e-multi-line-input.e-control-wrapper.e-rtl textarea.e-bigger,.e-filled.e-float-input.e-multi-line-input.e-rtl textarea.e-bigger,.e-rtl .e-filled.e-float-input.e-multi-line-input.e-control-wrapper textarea.e-bigger,.e-rtl .e-filled.e-float-input.e-multi-line-input textarea.e-bigger,.e-bigger .e-filled.e-float-input.e-multi-line-input.e-control-wrapper.e-rtl textarea,.e-bigger .e-filled.e-float-input.e-multi-line-input.e-rtl textarea,.e-bigger.e-rtl .e-filled.e-float-input.e-multi-line-input.e-control-wrapper textarea,.e-bigger.e-rtl .e-filled.e-float-input.e-multi-line-input textarea,.e-bigger.e-rtl .e-filled.e-float-input.e-multi-line-input.e-control-wrapper textarea:focus,.e-bigger.e-rtl .e-filled.e-float-input.e-multi-line-input textarea:focus,.e-bigger .e-filled.e-float-input.e-multi-line-input.e-rtl textarea:focus,.e-bigger .e-filled.e-float-input.e-multi-line-input.e-control-wrapper.e-rtl textarea:focus{padding:0 16px 8px;text-indent:0}.e-bigger .e-filled textarea.e-input.e-small.e-rtl,.e-filled.e-input-group.e-multi-line-input.e-small.e-bigger.e-rtl textarea.e-input,.e-filled.e-input-group.e-multi-line-input.e-control-wrapper.e-small.e-bigger.e-rtl textarea.e-input,.e-filled.e-input-group.e-multi-line-input.e-small.e-rtl textarea.e-input.e-bigger,.e-filled.e-input-group.e-multi-line-input.e-control-wrapper.e-small.e-rtl textarea.e-input.e-bigger,.e-bigger .e-filled.e-input-group.e-multi-line-input.e-small.e-rtl textarea.e-input,.e-bigger .e-filled.e-input-group.e-multi-line-input.e-control-wrapper.e-small.e-rtl textarea.e-input,.e-bigger.e-rtl textarea.e-input.e-small,.e-rtl .e-filled.e-input-group.e-multi-line-input.e-small.e-bigger textarea.e-input,.e-rtl .e-filled.e-input-group.e-multi-line-input.e-control-wrapper.e-small.e-bigger textarea.e-input,.e-rtl .e-filled.e-input-group.e-multi-line-input.e-small textarea.e-input.e-bigger,.e-rtl .e-filled.e-input-group.e-multi-line-input.e-control-wrapper.e-small textarea.e-input.e-bigger,.e-bigger.e-rtl .e-filled.e-input-group.e-multi-line-input.e-small textarea.e-input,.e-bigger.e-rtl .e-filled.e-input-group.e-multi-line-input.e-control-wrapper.e-small textarea.e-input,.e-bigger .e-filled.e-input-group.e-multi-line-input.e-small.e-rtl textarea.e-input:focus,.e-bigger .e-filled.e-input-group.e-multi-line-input.e-control-wrapper.e-small.e-rtl textarea.e-input:focus,.e-small .e-filled.e-input-group.e-multi-line-input.e-bigger.e-rtl textarea.e-input:focus,.e-small .e-filled.e-input-group.e-multi-line-input.e-control-wrapper.e-bigger.e-rtl textarea.e-input:focus,.e-filled.e-input-group.e-multi-line-input.e-bigger.e-small.e-rtl textarea.e-input:focus,.e-filled.e-input-group.e-multi-line-input.e-control-wrapper.e-bigger.e-small.e-rtl textarea.e-input:focus,.e-bigger.e-rtl .e-filled.e-input-group.e-multi-line-input.e-small textarea.e-input:focus,.e-bigger.e-rtl .e-filled.e-input-group.e-multi-line-input.e-control-wrapper.e-small textarea.e-input:focus,.e-small.e-rtl .e-filled.e-input-group.e-multi-line-input.e-bigger textarea.e-input:focus,.e-small.e-rtl .e-filled.e-input-group.e-multi-line-input.e-control-wrapper.e-bigger textarea.e-input:focus,.e-rtl .e-filled.e-input-group.e-multi-line-input.e-bigger.e-small textarea.e-input:focus,.e-rtl .e-filled.e-input-group.e-multi-line-input.e-control-wrapper.e-bigger.e-small textarea.e-input:focus{padding:0 12px 10px;text-indent:0}.e-filled.e-float-input.e-multi-line-input.e-small.e-bigger.e-rtl textarea,.e-filled.e-float-input.e-multi-line-input.e-small.e-rtl textarea.e-bigger,.e-bigger .e-filled.e-float-input.e-multi-line-input.e-small.e-rtl textarea,.e-filled.e-float-input.e-multi-line-input.e-control-wrapper.e-small.e-bigger.e-rtl textarea,.e-filled.e-float-input.e-multi-line-input.e-control-wrapper.e-small.e-rtl textarea.e-bigger,.e-bigger .e-filled.e-float-input.e-multi-line-input.e-control-wrapper.e-small.e-rtl textarea,.e-rtl .e-filled.e-float-input.e-multi-line-input.e-control-wrapper.e-small.e-bigger textarea,.e-rtl .e-filled.e-float-input.e-multi-line-input.e-control-wrapper.e-small textarea.e-bigger,.e-bigger.e-rtl .e-filled.e-float-input.e-multi-line-input.e-control-wrapper.e-small textarea,.e-rtl .e-filled.e-float-input.e-multi-line-input.e-small.e-bigger textarea,.e-rtl .e-filled.e-float-input.e-multi-line-input.e-small textarea.e-bigger,.e-bigger.e-rtl .e-filled.e-float-input.e-multi-line-input.e-small textarea,.e-bigger .e-filled.e-float-input.e-multi-line-input.e-control-wrapper.e-small.e-rtl textarea:focus,.e-bigger .e-filled.e-float-input.e-multi-line-input.e-small.e-rtl textarea:focus,.e-small .e-filled.e-float-input.e-multi-line-input.e-control-wrapper.e-bigger.e-rtl textarea:focus,.e-small .e-filled.e-float-input.e-multi-line-input.e-bigger.e-rtl textarea:focus,.e-filled.e-float-input.e-multi-line-input.e-control-wrapper.e-bigger.e-small.e-rtl textarea:focus,.e-filled.e-float-input.e-multi-line-input.e-bigger.e-small.e-rtl textarea:focus,.e-bigger.e-rtl .e-filled.e-float-input.e-multi-line-input.e-control-wrapper.e-small textarea:focus,.e-bigger.e-rtl .e-filled.e-float-input.e-multi-line-input.e-small textarea:focus,.e-small.e-rtl .e-filled.e-float-input.e-multi-line-input.e-control-wrapper.e-bigger textarea:focus,.e-small.e-rtl .e-filled.e-float-input.e-multi-line-input.e-bigger textarea:focus,.e-rtl .e-filled.e-float-input.e-multi-line-input.e-control-wrapper.e-bigger.e-small textarea:focus,.e-rtl .e-filled.e-float-input.e-multi-line-input.e-bigger.e-small textarea:focus{padding:0 12px 5px;text-indent:0}.e-filled.e-float-input.e-float-icon-left.e-bigger.e-small .e-input-in-wrap,.e-filled.e-float-input.e-control-wrapper.e-float-icon-left.e-bigger.e-small .e-input-in-wrap,.e-filled.e-input-group.e-float-icon-left.e-bigger.e-small .e-input-in-wrap,.e-filled.e-input-group.e-control-wrapper.e-float-icon-left.e-bigger.e-small .e-input-in-wrap,.e-bigger.e-small .e-filled.e-float-input.e-float-icon-left .e-input-in-wrap,.e-bigger.e-small .e-filled.e-float-input.e-control-wrapper.e-float-icon-left .e-input-in-wrap,.e-bigger.e-small .e-filled.e-input-group.e-float-icon-left .e-input-in-wrap,.e-bigger.e-small .e-filled.e-input-group.e-control-wrapper.e-float-icon-left .e-input-in-wrap{border:1px solid;border-width:0;margin-left:8px}.e-rtl.e-bigger.e-small .e-filled.e-float-input.e-float-icon-left .e-input-in-wrap,.e-rtl.e-bigger.e-small .e-filled.e-float-input.e-control-wrapper.e-float-icon-left .e-input-in-wrap,.e-rtl.e-bigger.e-small .e-filled.e-input-group.e-float-icon-left .e-input-in-wrap,.e-rtl.e-bigger.e-small .e-filled.e-input-group.e-control-wrapper.e-float-icon-left .e-input-in-wrap,.e-rtl .e-bigger.e-small.e-filled.e-float-input.e-float-icon-left .e-input-in-wrap,.e-rtl .e-bigger.e-small.e-filled.e-float-input.e-control-wrapper.e-float-icon-left .e-input-in-wrap,.e-rtl .e-bigger.e-small.e-filled.e-input-group.e-float-icon-left .e-input-in-wrap,.e-rtl .e-bigger.e-small.e-filled.e-input-group.e-control-wrapper.e-float-icon-left .e-input-in-wrap,.e-bigger.e-small.e-filled.e-float-input.e-control-wrapper.e-float-icon-left.e-rtl .e-input-in-wrap,.e-bigger.e-small.e-filled.e-float-input.e-float-icon-left.e-rtl .e-input-in-wrap,.e-bigger.e-small.e-filled.e-input-group.e-float-icon-left.e-rtl .e-input-in-wrap,.e-bigger.e-small.e-filled.e-input-group.e-control-wrapper.e-float-icon-left.e-rtl .e-input-in-wrap,.e-bigger.e-small .e-filled.e-float-input.e-control-wrapper.e-float-icon-left.e-rtl .e-input-in-wrap,.e-bigger.e-small .e-filled.e-float-input.e-float-icon-left.e-rtl .e-input-in-wrap,.e-bigger.e-small .e-filled.e-input-group.e-float-icon-left.e-rtl .e-input-in-wrap,.e-bigger.e-small .e-filled.e-input-group.e-control-wrapper.e-float-icon-left.e-rtl .e-input-in-wrap{margin-left:0;margin-right:8px}.e-float-input.e-bigger:not(.e-error):not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-float-input.e-control-wrapper.e-bigger:not(.e-error):not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger .e-float-input:not(.e-error):not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger .e-float-input.e-control-wrapper:not(.e-error):not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-float-input.e-small.e-bigger:not(.e-error):not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-float-input.e-control-wrapper.e-small.e-bigger:not(.e-error):not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger .e-float-input.e-small:not(.e-error):not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger .e-float-input.e-control-wrapper.e-small:not(.e-error):not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom{color:#0000006b}.e-float-input.e-bigger:not(.e-error) input:focus~label.e-float-text,.e-float-input.e-bigger:not(.e-error) input:valid~label.e-float-text,.e-float-input.e-bigger:not(.e-error) input~label.e-label-top.e-float-text,.e-float-input.e-bigger:not(.e-error) input[readonly]~label.e-label-top.e-float-text,.e-float-input.e-bigger:not(.e-error) input[disabled]~label.e-label-top.e-float-text,.e-bigger .e-float-input:not(.e-error) input:focus~label.e-float-text,.e-bigger .e-float-input:not(.e-error) input:valid~label.e-float-text,.e-bigger .e-float-input:not(.e-error) input~label.e-label-top.e-float-text,.e-bigger .e-float-input:not(.e-error) input[readonly]~label.e-label-top.e-float-text,.e-bigger .e-float-input:not(.e-error) input[disabled]~label.e-label-top.e-float-text,.e-float-input.e-bigger:not(.e-error).e-input-focus input~label.e-float-text,.e-bigger .e-float-input:not(.e-error).e-input-focus input~label.e-float-text,.e-float-input.e-small.e-bigger:not(.e-error) input:focus~label.e-float-text,.e-float-input.e-small.e-bigger:not(.e-error) input:valid~label.e-float-text,.e-float-input.e-small.e-bigger:not(.e-error) input~label.e-label-top.e-float-text,.e-float-input.e-small.e-bigger:not(.e-error) input[readonly]~label.e-label-top.e-float-text,.e-float-input.e-small.e-bigger:not(.e-error) input[disabled]~label.e-label-top.e-float-text,.e-bigger .e-float-input.e-small:not(.e-error) input:focus~label.e-float-text,.e-bigger .e-float-input.e-small:not(.e-error) input:valid~label.e-float-text,.e-bigger .e-float-input.e-small:not(.e-error) input~label.e-label-top.e-float-text,.e-bigger .e-float-input.e-small:not(.e-error) input[readonly]~label.e-label-top.e-float-text,.e-bigger .e-float-input.e-small:not(.e-error) input[disabled]~label.e-label-top.e-float-text,.e-float-input.e-small.e-bigger:not(.e-error).e-input-focus input~label.e-float-text,.e-bigger .e-float-input.e-small:not(.e-error).e-input-focus input~label.e-float-text,.e-float-input.e-control-wrapper.e-small.e-bigger:not(.e-error) input:focus~label.e-float-text,.e-float-input.e-control-wrapper.e-small.e-bigger:not(.e-error) input:valid~label.e-float-text,.e-float-input.e-control-wrapper.e-small.e-bigger:not(.e-error) input~label.e-label-top.e-float-text,.e-float-input.e-control-wrapper.e-small.e-bigger:not(.e-error) input[readonly]~label.e-label-top.e-float-text,.e-float-input.e-control-wrapper.e-small.e-bigger:not(.e-error) input[disabled]~label.e-label-top.e-float-text,.e-bigger .e-float-input.e-control-wrapper.e-small:not(.e-error) input:focus~label.e-float-text,.e-bigger .e-float-input.e-control-wrapper.e-small:not(.e-error) input:valid~label.e-float-text,.e-bigger .e-float-input.e-control-wrapper.e-small:not(.e-error) input~label.e-label-top.e-float-text,.e-bigger .e-float-input.e-control-wrapper.e-small:not(.e-error) input[readonly]~label.e-label-top.e-float-text,.e-bigger .e-float-input.e-control-wrapper.e-small:not(.e-error) input[disabled]~label.e-label-top.e-float-text,.e-float-input.e-control-wrapper.e-small.e-bigger:not(.e-error).e-input-focus input~label.e-float-text,.e-bigger .e-float-input.e-control-wrapper.e-small:not(.e-error).e-input-focus input~label.e-float-text,.e-float-input.e-bigger:not(.e-error) textarea:focus~label.e-float-text,.e-float-input.e-bigger:not(.e-error) textarea:valid~label.e-float-text,.e-float-input.e-bigger:not(.e-error) textarea~label.e-label-top.e-float-text,.e-float-input.e-bigger:not(.e-error) textarea[readonly]~label.e-label-top.e-float-text,.e-float-input.e-bigger:not(.e-error) textarea[disabled]~label.e-label-top.e-float-text,.e-bigger .e-float-input:not(.e-error) textarea:focus~label.e-float-text,.e-bigger .e-float-input:not(.e-error) textarea:valid~label.e-float-text,.e-bigger .e-float-input:not(.e-error) textarea~label.e-label-top.e-float-text,.e-bigger .e-float-input:not(.e-error) textarea[readonly]~label.e-label-top.e-float-text,.e-bigger .e-float-input:not(.e-error) textarea[disabled]~label.e-label-top.e-float-text,.e-float-input.e-small.e-bigger:not(.e-error) textarea:focus~label.e-float-text,.e-float-input.e-small.e-bigger:not(.e-error) textarea:valid~label.e-float-text,.e-float-input.e-small.e-bigger:not(.e-error) textarea~label.e-label-top.e-float-text,.e-float-input.e-small.e-bigger:not(.e-error) textarea[readonly]~label.e-label-top.e-float-text,.e-float-input.e-small.e-bigger:not(.e-error) textarea[disabled]~label.e-label-top.e-float-text,.e-bigger .e-float-input.e-small:not(.e-error) textarea:focus~label.e-float-text,.e-bigger .e-float-input.e-small:not(.e-error) textarea:valid~label.e-float-text,.e-bigger .e-float-input.e-small:not(.e-error) textarea~label.e-label-top.e-float-text,.e-bigger .e-float-input.e-small:not(.e-error) textarea[readonly]~label.e-label-top.e-float-text,.e-bigger .e-float-input.e-small:not(.e-error) textarea[disabled]~label.e-label-top.e-float-text,.e-bigger .e-float-input:not(.e-error):not(.e-input-focus) input:not(:focus):-webkit-autofill~label.e-float-text,.e-bigger.e-float-input:not(.e-error):not(.e-input-focus) input:not(:focus):-webkit-autofill~label.e-float-text,.e-bigger .e-float-input.e-small:not(.e-error):not(.e-input-focus) input:not(:focus):-webkit-autofill~label.e-float-text,.e-bigger.e-small .e-float-input:not(.e-error):not(.e-input-focus) input:not(:focus):-webkit-autofill~label.e-float-text,.e-float-input.e-bigger.e-small:not(.e-error):not(.e-input-focus) input:not(:focus):-webkit-autofill~label.e-float-text,.e-bigger .e-float-input.e-control-wrapper.e-autofill:not(.e-error):not(.e-input-focus) input:not(:focus):-webkit-autofill~label.e-float-text,.e-bigger.e-float-input.e-control-wrapper.e-autofill:not(.e-error):not(.e-input-focus) input:not(:focus):-webkit-autofill~label.e-float-text,.e-bigger .e-float-input.e-small.e-control-wrapper.e-autofill:not(.e-error):not(.e-input-focus) input:not(:focus):-webkit-autofill~label.e-float-text,.e-bigger.e-small .e-float-input.e-control-wrapper.e-autofill:not(.e-error):not(.e-input-focus) input:not(:focus):-webkit-autofill~label.e-float-text,.e-float-input.e-bigger.e-small.e-control-wrapper.e-autofill:not(.e-error):not(.e-input-focus) input:not(:focus):-webkit-autofill~label.e-float-text,.e-bigger .e-float-input:not(.e-error) textarea:not(:focus):-webkit-autofill~label.e-float-text,.e-bigger.e-float-input:not(.e-error) textarea:not(:focus):-webkit-autofill~label.e-float-text,.e-bigger .e-float-input.e-small:not(.e-error) textarea:not(:focus):-webkit-autofill~label.e-float-text,.e-bigger.e-small .e-float-input:not(.e-error) textarea:not(:focus):-webkit-autofill~label.e-float-text,.e-float-input.e-bigger.e-small:not(.e-error) textarea:not(:focus):-webkit-autofill~label.e-float-text,.e-bigger .e-float-input.e-control-wrapper.e-autofill:not(.e-error) textarea:not(:focus):-webkit-autofill~label.e-float-text,.e-bigger.e-float-input.e-control-wrapper.e-autofill:not(.e-error) textarea:not(:focus):-webkit-autofill~label.e-float-text,.e-bigger .e-float-input.e-small.e-control-wrapper.e-autofill:not(.e-error) textarea:not(:focus):-webkit-autofill~label.e-float-text,.e-bigger.e-small .e-float-input.e-control-wrapper.e-autofill:not(.e-error) textarea:not(:focus):-webkit-autofill~label.e-float-text,.e-float-input.e-bigger.e-small.e-control-wrapper.e-autofill:not(.e-error) textarea:not(:focus):-webkit-autofill~label.e-float-text{color:#0000008a}.e-float-input.e-control-wrapper.e-bigger:not(.e-error) input:focus~label.e-float-text,.e-float-input.e-control-wrapper.e-bigger:not(.e-error) input:valid~label.e-float-text,.e-float-input.e-control-wrapper.e-bigger:not(.e-error) input~label.e-label-top.e-float-text,.e-float-input.e-control-wrapper.e-bigger:not(.e-error) input[readonly]~label.e-label-top.e-float-text,.e-float-input.e-control-wrapper.e-bigger:not(.e-error) input[disabled]~label.e-label-top.e-float-text,.e-bigger .e-float-input.e-control-wrapper:not(.e-error) input:focus~label.e-float-text,.e-bigger .e-float-input.e-control-wrapper:not(.e-error) input:valid~label.e-float-text,.e-bigger .e-float-input.e-control-wrapper:not(.e-error) input~label.e-label-top.e-float-text,.e-bigger .e-float-input.e-control-wrapper:not(.e-error) input[readonly]~label.e-label-top.e-float-text,.e-bigger .e-float-input.e-control-wrapper:not(.e-error) input[disabled]~label.e-label-top.e-float-text,.e-float-input.e-control-wrapper.e-bigger:not(.e-error).e-input-focus input~label.e-float-text,.e-bigger .e-float-input.e-control-wrapper:not(.e-error).e-input-focus input~label.e-float-text,.e-float-input.e-control-wrapper.e-bigger:not(.e-error) textarea:focus~label.e-float-text,.e-float-input.e-control-wrapper.e-bigger:not(.e-error) textarea:valid~label.e-float-text,.e-float-input.e-control-wrapper.e-bigger:not(.e-error) textarea~label.e-label-top.e-float-text,.e-float-input.e-control-wrapper.e-bigger:not(.e-error) textarea[readonly]~label.e-label-top.e-float-text,.e-float-input.e-control-wrapper.e-bigger:not(.e-error) textarea[disabled]~label.e-label-top.e-float-text,.e-bigger .e-float-input.e-control-wrapper:not(.e-error) textarea:focus~label.e-float-text,.e-bigger .e-float-input.e-control-wrapper:not(.e-error) textarea:valid~label.e-float-text,.e-bigger .e-float-input.e-control-wrapper:not(.e-error) textarea~label.e-label-top.e-float-text,.e-bigger .e-float-input.e-control-wrapper:not(.e-error) textarea[readonly]~label.e-label-top.e-float-text,.e-bigger .e-float-input.e-control-wrapper:not(.e-error) textarea[disabled]~label.e-label-top.e-float-text{color:#0000008a}.e-float-input.e-bigger:not(.e-error) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-float-input.e-control-wrapper.e-bigger:not(.e-error) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger .e-float-input:not(.e-error) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger .e-float-input.e-control-wrapper:not(.e-error) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-float-input.e-small.e-bigger:not(.e-error) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-float-input.e-control-wrapper.e-small.e-bigger:not(.e-error) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger .e-float-input.e-small:not(.e-error) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger .e-float-input.e-control-wrapper.e-small:not(.e-error) textarea:not(:focus):valid~label.e-float-text.e-label-bottom{color:#0000006b}.e-float-input.e-control-wrapper.e-small.e-bigger:not(.e-error) textarea:focus~label.e-float-text,.e-float-input.e-control-wrapper.e-small.e-bigger:not(.e-error) textarea:valid~label.e-float-text,.e-float-input.e-control-wrapper.e-small.e-bigger:not(.e-error) textarea~label.e-label-top.e-float-text,.e-float-input.e-control-wrapper.e-small.e-bigger:not(.e-error) textarea[readonly]~label.e-label-top.e-float-text,.e-float-input.e-control-wrapper.e-small.e-bigger:not(.e-error) textarea[disabled]~label.e-label-top.e-float-text,.e-bigger .e-float-input.e-control-wrapper.e-small:not(.e-error) textarea:focus~label.e-float-text,.e-bigger .e-float-input.e-control-wrapper.e-small:not(.e-error) textarea:valid~label.e-float-text,.e-bigger .e-float-input.e-control-wrapper.e-small:not(.e-error) textarea~label.e-label-top.e-float-text,.e-bigger .e-float-input.e-control-wrapper.e-small:not(.e-error) textarea[readonly]~label.e-label-top.e-float-text,.e-bigger .e-float-input.e-control-wrapper.e-small:not(.e-error) textarea[disabled]~label.e-label-top.e-float-text{color:#0000008a}.e-float-input.e-bigger:not(.e-error) input[disabled]~label.e-float-text,.e-float-input.e-bigger:not(.e-error) input[disabled]~label.e-float-text.e-label-top,.e-float-input.e-small.e-bigger:not(.e-error) input[disabled]~label.e-float-text,.e-float-input.e-small.e-bigger:not(.e-error) input[disabled]~label.e-float-text.e-label-top,.e-float-input.e-bigger:not(.e-error) textarea[disabled]~label.e-float-text,.e-float-input.e-bigger:not(.e-error) textarea[disabled]~label.e-float-text.e-label-top,.e-float-input.e-small.e-bigger:not(.e-error) textarea[disabled]~label.e-float-text,.e-float-input.e-small.e-bigger:not(.e-error) textarea[disabled]~label.e-float-text.e-label-top,.e-float-input.e-control-wrapper.e-bigger:not(.e-error) input[disabled]~label.e-float-text,.e-float-input.e-control-wrapper.e-bigger:not(.e-error) input[disabled]~label.e-float-text.e-label-top,.e-float-input.e-control-wrapper.e-small.e-bigger:not(.e-error) input[disabled]~label.e-float-text,.e-float-input.e-control-wrapper.e-small.e-bigger:not(.e-error) input[disabled]~label.e-float-text.e-label-top,.e-float-input.e-control-wrapper.e-disabled.e-bigger:not(.e-error) input[disabled]~label.e-float-text,.e-float-input.e-control-wrapper.e-disabled.e-bigger:not(.e-error) input[disabled]~label.e-float-text.e-label-top,.e-float-input.e-control-wrapper.e-disabled.e-small.e-bigger:not(.e-error) input[disabled]~label.e-float-text,.e-float-input.e-control-wrapper.e-disabled.e-small.e-bigger:not(.e-error) input[disabled]~label.e-float-text.e-label-top,.e-float-input.e-control-wrapper.e-bigger:not(.e-error) textarea[disabled]~label.e-float-text,.e-float-input.e-control-wrapper.e-bigger:not(.e-error) textarea[disabled]~label.e-float-text.e-label-top,.e-float-input.e-control-wrapper.e-small.e-bigger:not(.e-error) textarea[disabled]~label.e-float-text,.e-float-input.e-control-wrapper.e-small.e-bigger:not(.e-error) textarea[disabled]~label.e-float-text.e-label-top,.e-float-input.e-control-wrapper.e-disabled.e-bigger:not(.e-error) textarea[disabled]~label.e-float-text,.e-float-input.e-control-wrapper.e-disabled.e-bigger:not(.e-error) textarea[disabled]~label.e-float-text.e-label-top,.e-float-input.e-control-wrapper.e-disabled.e-small.e-bigger:not(.e-error) textarea[disabled]~label.e-float-text,.e-float-input.e-control-wrapper.e-disabled.e-small.e-bigger:not(.e-error) textarea[disabled]~label.e-float-text.e-label-top{color:#0000006b}.e-float-input.e-bigger:not(.e-error) input:focus~label.e-float-text,.e-bigger .e-float-input:not(.e-error) input:focus~label.e-float-text,.e-float-input.e-bigger:not(.e-error) input[readonly]:focus~label.e-label-top.e-float-text,.e-bigger .e-float-input:not(.e-error) input[readonly]:focus~label.e-label-top.e-float-text,.e-float-input.e-control-wrapper.e-bigger:not(.e-error) input[readonly]:focus~label.e-label-top.e-float-text,.e-bigger .e-float-input.e-control-wrapper:not(.e-error) input[readonly]:focus~label.e-label-top.e-float-text,.e-float-input.e-small.e-bigger:not(.e-error) input[readonly]:focus~label.e-label-top.e-float-text,.e-bigger .e-float-input.e-small:not(.e-error) input[readonly]:focus~label.e-label-top.e-float-text,.e-float-input.e-control-wrapper.e-small.e-bigger:not(.e-error) input[readonly]:focus~label.e-label-top.e-float-text,.e-bigger .e-float-input.e-control-wrapper.e-small:not(.e-error) input[readonly]:focus~label.e-label-top.e-float-text,.e-float-input.e-bigger:not(.e-error).e-input-focus input[readonly]~label.e-label-top.e-float-text,.e-bigger .e-float-input:not(.e-error).e-input-focus input[readonly]~label.e-label-top.e-float-text,.e-float-input.e-control-wrapper.e-bigger:not(.e-error).e-input-focus input[readonly]~label.e-label-top.e-float-text,.e-bigger .e-float-input.e-control-wrapper:not(.e-error).e-input-focus input[readonly]~label.e-label-top.e-float-text,.e-float-input.e-small.e-bigger:not(.e-error).e-input-focus input[readonly]~label.e-label-top.e-float-text,.e-bigger .e-float-input.e-small:not(.e-error).e-input-focus input[readonly]~label.e-label-top.e-float-text,.e-float-input.e-control-wrapper.e-small.e-bigger:not(.e-error).e-input-focus input[readonly]~label.e-label-top.e-float-text,.e-bigger .e-float-input.e-control-wrapper.e-small:not(.e-error).e-input-focus input[readonly]~label.e-label-top.e-float-text,.e-float-input.e-bigger:not(.e-error) textarea[readonly]:focus~label.e-label-top.e-float-text,.e-bigger .e-float-input:not(.e-error) textarea[readonly]:focus~label.e-label-top.e-float-text,.e-float-input.e-control-wrapper.e-bigger:not(.e-error) textarea[readonly]:focus~label.e-label-top.e-float-text,.e-bigger .e-float-input.e-control-wrapper:not(.e-error) textarea[readonly]:focus~label.e-label-top.e-float-text,.e-float-input.e-small.e-bigger:not(.e-error) textarea[readonly]:focus~label.e-label-top.e-float-text,.e-bigger .e-float-input.e-small:not(.e-error) textarea[readonly]:focus~label.e-label-top.e-float-text .e-float-input.e-control-wrapper.e-small:not(.e-error) textarea[readonly]:focus~label.e-float-text,.e-float-input.e-control-wrapper.e-small.e-bigger:not(.e-error) textarea[readonly]:focus~label.e-label-top.e-float-text,.e-bigger .e-float-input.e-control-wrapper.e-small:not(.e-error) textarea[readonly]:focus~label.e-label-top.e-float-text,.e-float-input.e-bigger:not(.e-error).e-input-focus textarea[readonly]~label.e-label-top.e-float-text,.e-bigger .e-float-input:not(.e-error).e-input-focus textarea[readonly]~label.e-label-top.e-float-text,.e-float-input.e-control-wrapper.e-bigger:not(.e-error).e-input-focus textarea[readonly]~label.e-label-top.e-float-text,.e-bigger .e-float-input.e-control-wrapper:not(.e-error).e-input-focus textarea[readonly]~label.e-label-top.e-float-text,.e-float-input.e-small.e-bigger:not(.e-error).e-input-focus textarea[readonly]~label.e-label-top.e-float-text,.e-bigger .e-float-input.e-small:not(.e-error).e-input-focus textarea[readonly]~label.e-label-top.e-float-text .e-float-input.e-control-wrapper.e-small:not(.e-error).e-input-focus textarea[readonly]~label.e-float-text,.e-float-input.e-control-wrapper.e-small.e-bigger:not(.e-error).e-input-focus textarea[readonly]~label.e-label-top.e-float-text,.e-bigger .e-float-input.e-control-wrapper.e-small:not(.e-error).e-input-focus textarea[readonly]~label.e-label-top.e-float-text,.e-float-input.e-small.e-bigger:not(.e-error) input:focus~label.e-float-text,.e-bigger .e-float-input.e-small:not(.e-error) input:focus~label.e-float-text,.e-float-input.e-bigger:not(.e-error) textarea:focus~label.e-float-text,.e-bigger .e-float-input:not(.e-error) textarea:focus~label.e-float-text,.e-float-input.e-small.e-bigger:not(.e-error) textarea:focus~label.e-float-text,.e-bigger .e-float-input.e-small:not(.e-error) textarea:focus~label.e-float-text,.e-float-input.e-control-wrapper.e-bigger:not(.e-error) input:focus~label.e-float-text,.e-bigger .e-float-input.e-control-wrapper:not(.e-error) input:focus~label.e-float-text,.e-float-input.e-control-wrapper.e-small.e-bigger:not(.e-error) input:focus~label.e-float-text,.e-bigger .e-float-input.e-control-wrapper.e-small:not(.e-error) input:focus~label.e-float-text,.e-float-input.e-control-wrapper.e-bigger:not(.e-error) textarea:focus~label.e-float-text,.e-bigger .e-float-input.e-control-wrapper:not(.e-error) textarea:focus~label.e-float-text,.e-float-input.e-control-wrapper.e-small.e-bigger:not(.e-error) textarea:focus~label.e-float-text,.e-bigger .e-float-input.e-control-wrapper.e-small:not(.e-error) textarea:focus~label.e-float-text,.e-float-input.e-bigger:not(.e-error).e-input-focus input~label.e-float-text,.e-bigger .e-float-input:not(.e-error).e-input-focus input~label.e-float-text,.e-float-input.e-small.e-bigger:not(.e-error).e-input-focus input~label.e-float-text,.e-bigger .e-float-input.e-small:not(.e-error).e-input-focus input~label.e-float-text,.e-float-input.e-control-wrapper.e-bigger:not(.e-error).e-input-focus input~label.e-float-text,.e-bigger .e-float-input.e-control-wrapper:not(.e-error).e-input-focus input~label.e-float-text,.e-float-input.e-control-wrapper.e-small.e-bigger:not(.e-error).e-input-focus input~label.e-float-text,.e-bigger .e-float-input.e-control-wrapper.e-small:not(.e-error).e-input-focus input~label.e-float-text{color:#e3165b}.e-outline.e-float-input.e-bigger.e-success.e-input-focus input:focus~label.e-float-text,.e-bigger .e-outline.e-float-input.e-success.e-input-focus input:focus~label.e-float-text,.e-outline.e-float-input.e-small.e-bigger.e-success input:focus~label.e-float-text,.e-bigger .e-outline.e-float-input.e-small:not(.e-success) input:focus~label.e-float-text,.e-outline.e-float-input.e-bigger.e-success textarea:focus~label.e-float-text,.e-bigger .e-outline.e-float-input.e-success textarea:focus~label.e-float-text,.e-outline.e-float-input.e-small.e-bigger.e-success textarea:focus~label.e-float-text,.e-bigger .e-outline.e-float-input.e-small.e-success textarea:focus~label.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-bigger.e-success input:focus~label.e-float-text,.e-bigger .e-outline.e-float-input.e-control-wrapper.e-success input:focus~label.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-small.e-bigger.e-success input:focus~label.e-float-text,.e-bigger .e-outline.e-float-input.e-control-wrapper.e-small.e-success input:focus~label.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-bigger.e-success textarea:focus~label.e-float-text,.e-bigger .e-outline.e-float-input.e-control-wrapper.e-success textarea:focus~label.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-small.e-bigger.e-success textarea:focus~label.e-float-text,.e-bigger .e-outline.e-float-input.e-control-wrapper.e-small.e-success textarea:focus~label.e-float-text,.e-outline.e-float-input.e-bigger.e-success.e-input-focus input~label.e-float-text,.e-bigger .e-outline.e-float-input.e-success.e-input-focus input~label.e-float-text,.e-outline.e-float-input.e-small.e-bigger.e-success.e-input-focus input~label.e-float-text,.e-bigger .e-outline.e-float-input.e-small:not(.e-success).e-input-focus input~label.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-bigger.e-success.e-input-focus input~label.e-float-text,.e-bigger .e-outline.e-float-input.e-control-wrapper.e-success.e-input-focus input~label.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-small.e-bigger.e-success.e-input-focus input~label.e-float-text,.e-bigger .e-outline.e-float-input.e-control-wrapper.e-small.e-success.e-input-focus input~label.e-float-text{color:#22b24b}.e-outline.e-float-input.e-bigger.e-error.e-input-focus input:focus~label.e-float-text,.e-bigger .e-outline.e-float-input.e-error.e-input-focus input:focus~label.e-float-text,.e-outline.e-float-input.e-small.e-bigger.e-error input:focus~label.e-float-text,.e-bigger .e-outline.e-float-input.e-small:not(.e-error) input:focus~label.e-float-text,.e-outline.e-float-input.e-bigger.e-error textarea:focus~label.e-float-text,.e-bigger .e-outline.e-float-input.e-error textarea:focus~label.e-float-text,.e-outline.e-float-input.e-small.e-bigger.e-error textarea:focus~label.e-float-text,.e-bigger .e-outline.e-float-input.e-small.e-error textarea:focus~label.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-bigger.e-error input:focus~label.e-float-text,.e-bigger .e-outline.e-float-input.e-control-wrapper.e-error input:focus~label.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-small.e-bigger.e-error input:focus~label.e-float-text,.e-bigger .e-outline.e-float-input.e-control-wrapper.e-small.e-error input:focus~label.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-bigger.e-error textarea:focus~label.e-float-text,.e-bigger .e-outline.e-float-input.e-control-wrapper.e-error textarea:focus~label.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-small.e-bigger.e-error textarea:focus~label.e-float-text,.e-bigger .e-outline.e-float-input.e-control-wrapper.e-small.e-error textarea:focus~label.e-float-text,.e-outline.e-float-input.e-bigger.e-error.e-input-focus input~label.e-float-text,.e-bigger .e-outline.e-float-input.e-error.e-input-focus input~label.e-float-text,.e-outline.e-float-input.e-small.e-bigger.e-error.e-input-focus input~label.e-float-text,.e-bigger .e-outline.e-float-input.e-small:not(.e-error).e-input-focus input~label.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-bigger.e-error.e-input-focus input~label.e-float-text,.e-bigger .e-outline.e-float-input.e-control-wrapper.e-error.e-input-focus input~label.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-small.e-bigger.e-error.e-input-focus input~label.e-float-text,.e-bigger .e-outline.e-float-input.e-control-wrapper.e-small.e-error.e-input-focus input~label.e-float-text{color:#f44336}.e-outline.e-float-input.e-bigger.e-warning.e-input-focus input:focus~label.e-float-text,.e-bigger .e-outline.e-float-input.e-warning.e-input-focus input:focus~label.e-float-text,.e-outline.e-float-input.e-small.e-bigger.e-warning input:focus~label.e-float-text,.e-bigger .e-outline.e-float-input.e-small:not(.e-warning) input:focus~label.e-float-text,.e-outline.e-float-input.e-bigger.e-warning textarea:focus~label.e-float-text,.e-bigger .e-outline.e-float-input.e-warning textarea:focus~label.e-float-text,.e-outline.e-float-input.e-small.e-bigger.e-warning textarea:focus~label.e-float-text,.e-bigger .e-outline.e-float-input.e-small.e-warning textarea:focus~label.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-bigger.e-warning input:focus~label.e-float-text,.e-bigger .e-outline.e-float-input.e-control-wrapper.e-warning input:focus~label.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-small.e-bigger.e-warning input:focus~label.e-float-text,.e-bigger .e-outline.e-float-input.e-control-wrapper.e-small.e-warning input:focus~label.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-bigger.e-warning textarea:focus~label.e-float-text,.e-bigger .e-outline.e-float-input.e-control-wrapper.e-warning textarea:focus~label.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-small.e-bigger.e-warning textarea:focus~label.e-float-text,.e-bigger .e-outline.e-float-input.e-control-wrapper.e-small.e-warning textarea:focus~label.e-float-text,.e-outline.e-float-input.e-bigger.e-warning.e-input-focus input~label.e-float-text,.e-bigger .e-outline.e-float-input.e-warning.e-input-focus input~label.e-float-text,.e-outline.e-float-input.e-small.e-bigger.e-warning.e-input-focus input~label.e-float-text,.e-bigger .e-outline.e-float-input.e-small:not(.e-warning).e-input-focus input~label.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-bigger.e-warning.e-input-focus input~label.e-float-text,.e-bigger .e-outline.e-float-input.e-control-wrapper.e-warning.e-input-focus input~label.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-small.e-bigger.e-warning.e-input-focus input~label.e-float-text,.e-bigger .e-outline.e-float-input.e-control-wrapper.e-small.e-warning.e-input-focus input~label.e-float-text{color:#ffca1c}.e-outline.e-float-input.e-bigger:not(.e-error) input[disabled]~label.e-float-text,.e-outline.e-float-input.e-bigger:not(.e-error) input[disabled]~label.e-float-text.e-label-top,.e-outline.e-float-input.e-small.e-bigger:not(.e-error) input[disabled]~label.e-float-text,.e-outline.e-float-input.e-small.e-bigger:not(.e-error) input[disabled]~label.e-float-text.e-label-top,.e-outline.e-float-input.e-bigger:not(.e-error) textarea[disabled]~label.e-float-text,.e-outline.e-float-input.e-bigger:not(.e-error) textarea[disabled]~label.e-float-text.e-label-top,.e-outline.e-float-input.e-small.e-bigger:not(.e-error) textarea[disabled]~label.e-float-text,.e-outline.e-float-input.e-small.e-bigger:not(.e-error) textarea[disabled]~label.e-float-text.e-label-top,.e-outline.e-float-input.e-control-wrapper.e-bigger:not(.e-error) input[disabled]~label.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-bigger:not(.e-error) input[disabled]~label.e-float-text.e-label-top,.e-outline.e-float-input.e-control-wrapper.e-small.e-bigger:not(.e-error) input[disabled]~label.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-small.e-bigger:not(.e-error) input[disabled]~label.e-float-text.e-label-top,.e-outline.e-float-input.e-control-wrapper.e-disabled.e-bigger:not(.e-error) input[disabled]~label.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-disabled.e-bigger:not(.e-error) input[disabled]~label.e-float-text.e-label-top,.e-outline.e-float-input.e-control-wrapper.e-disabled.e-small.e-bigger:not(.e-error) input[disabled]~label.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-disabled.e-small.e-bigger:not(.e-error) input[disabled]~label.e-float-text.e-label-top,.e-outline.e-float-input.e-control-wrapper.e-bigger:not(.e-error) textarea[disabled]~label.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-bigger:not(.e-error) textarea[disabled]~label.e-float-text.e-label-top,.e-outline.e-float-input.e-control-wrapper.e-small.e-bigger:not(.e-error) textarea[disabled]~label.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-small.e-bigger:not(.e-error) textarea[disabled]~label.e-float-text.e-label-top,.e-outline.e-float-input.e-control-wrapper.e-disabled.e-bigger:not(.e-error) textarea[disabled]~label.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-disabled.e-bigger:not(.e-error) textarea[disabled]~label.e-float-text.e-label-top,.e-outline.e-float-input.e-control-wrapper.e-disabled.e-small.e-bigger:not(.e-error) textarea[disabled]~label.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-disabled.e-small.e-bigger:not(.e-error) textarea[disabled]~label.e-float-text.e-label-top{color:#00000061}.e-filled.e-float-input.e-bigger:not(.e-error):not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-filled.e-float-input.e-control-wrapper.e-bigger:not(.e-error):not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger .e-filled.e-float-input:not(.e-error):not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger .e-filled.e-float-input.e-control-wrapper:not(.e-error):not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-filled.e-float-input.e-small.e-bigger:not(.e-error):not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-filled.e-float-input.e-control-wrapper.e-small.e-bigger:not(.e-error):not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger .e-filled.e-float-input.e-small:not(.e-error):not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-small:not(.e-error):not(.e-input-focus) input:not(:focus):valid~label.e-float-text.e-label-bottom,.e-filled.e-float-input.e-bigger:not(.e-error) input:focus~label.e-float-text,.e-filled.e-float-input.e-bigger:not(.e-error) input:valid~label.e-float-text,.e-filled.e-float-input.e-bigger:not(.e-error) input~label.e-label-top.e-float-text,.e-filled.e-float-input.e-bigger:not(.e-error) input[readonly]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-bigger:not(.e-error) input[disabled]~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input:not(.e-error) input:focus~label.e-float-text,.e-bigger .e-filled.e-float-input:not(.e-error) input:valid~label.e-float-text,.e-bigger .e-filled.e-float-input:not(.e-error) input~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input:not(.e-error) input[readonly]~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input:not(.e-error) input[disabled]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-bigger:not(.e-error).e-input-focus input~label.e-float-text,.e-bigger .e-filled.e-float-input:not(.e-error).e-input-focus input~label.e-float-text,.e-bigger .e-filled.e-float-input:not(.e-error):not(.e-input-focus) input:not(:focus):-webkit-autofill~label.e-float-text,.e-bigger.e-filled.e-float-input:not(.e-error):not(.e-input-focus) input:not(:focus):-webkit-autofill~label.e-float-text,.e-bigger .e-filled.e-float-input.e-small:not(.e-error):not(.e-input-focus) input:not(:focus):-webkit-autofill~label.e-float-text,.e-bigger.e-small .e-filled.e-float-input:not(.e-error):not(.e-input-focus) input:not(:focus):-webkit-autofill~label.e-float-text,.e-filled.e-float-input.e-bigger.e-small:not(.e-error):not(.e-input-focus) input:not(:focus):-webkit-autofill~label.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-autofill:not(.e-error):not(.e-input-focus) input:not(:focus):-webkit-autofill~label.e-float-text,.e-bigger.e-filled.e-float-input.e-control-wrapper.e-autofill:not(.e-error):not(.e-input-focus) input:not(:focus):-webkit-autofill~label.e-float-text,.e-bigger .e-filled.e-float-input.e-small.e-control-wrapper.e-autofill:not(.e-error):not(.e-input-focus) input:not(:focus):-webkit-autofill~label.e-float-text,.e-bigger.e-small .e-filled.e-float-input.e-control-wrapper.e-autofill:not(.e-error):not(.e-input-focus) input:not(:focus):-webkit-autofill~label.e-float-text,.e-filled.e-float-input.e-bigger.e-small.e-control-wrapper.e-autofill:not(.e-error):not(.e-input-focus) input:not(:focus):-webkit-autofill~label.e-float-text,.e-bigger .e-filled.e-float-input:not(.e-error) textarea:not(:focus):-webkit-autofill~label.e-float-text,.e-bigger.e-filled.e-float-input:not(.e-error) textarea:not(:focus):-webkit-autofill~label.e-float-text,.e-bigger .e-filled.e-float-input.e-small:not(.e-error) textarea:not(:focus):-webkit-autofill~label.e-float-text,.e-bigger.e-small .e-filled.e-float-input:not(.e-error) textarea:not(:focus):-webkit-autofill~label.e-float-text,.e-filled.e-float-input.e-bigger.e-small:not(.e-error) textarea:not(:focus):-webkit-autofill~label.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-autofill:not(.e-error) textarea:not(:focus):-webkit-autofill~label.e-float-text,.e-bigger.e-filled.e-float-input.e-control-wrapper.e-autofill:not(.e-error) textarea:not(:focus):-webkit-autofill~label.e-float-text,.e-bigger .e-filled.e-float-input.e-small.e-control-wrapper.e-autofill:not(.e-error) textarea:not(:focus):-webkit-autofill~label.e-float-text,.e-bigger.e-small .e-filled.e-float-input.e-control-wrapper.e-autofill:not(.e-error) textarea:not(:focus):-webkit-autofill~label.e-float-text,.e-filled.e-bigger.e-small.e-control-wrapper.e-autofill:not(.e-error) textarea:not(:focus):-webkit-autofill~label.e-float-text{color:#0009}.e-filled.e-float-input.e-bigger.e-success input:focus~label.e-float-text,.e-filled.e-float-input.e-bigger.e-success input:valid~label.e-float-text,.e-filled.e-float-input.e-bigger.e-success input~label.e-label-top.e-float-text,.e-filled.e-float-input.e-bigger.e-success input[readonly]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-bigger.e-success input[disabled]~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input.e-success input:focus~label.e-float-text,.e-bigger .e-filled.e-float-input.e-success input:valid~label.e-float-text,.e-bigger .e-filled.e-float-input.e-success input~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input.e-success input[readonly]~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input.e-success input[disabled]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-bigger.e-success.e-input-focus input~label.e-float-text,.e-bigger .e-filled.e-float-input.e-success.e-input-focus input~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-bigger.e-success input:focus~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-bigger.e-success input:valid~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-bigger.e-success input~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-bigger.e-success input[readonly]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-bigger.e-success input[disabled]~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-success input:focus~label.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-success input:valid~label.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-success input~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-success input[readonly]~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-success input[disabled]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-bigger.e-success.e-input-focus input~label.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-success.e-input-focus input~label.e-float-text,.e-filled.e-float-input.e-small.e-bigger.e-success input:focus~label.e-float-text,.e-filled.e-float-input.e-small.e-bigger.e-success input:valid~label.e-float-text,.e-filled.e-float-input.e-small.e-bigger.e-success input~label.e-label-top.e-float-text,.e-filled.e-float-input.e-small.e-bigger.e-success input[readonly]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-small.e-bigger.e-success input[disabled]~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input.e-small.e-success input:focus~label.e-float-text,.e-bigger .e-filled.e-float-input.e-small.e-success input:valid~label.e-float-text,.e-bigger .e-filled.e-float-input.e-small.e-success input~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input.e-small.e-success input[readonly]~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input.e-small.e-success input[disabled]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-small.e-bigger.e-success.e-input-focus input~label.e-float-text,.e-bigger .e-filled.e-float-input.e-small.e-success.e-input-focus input~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small.e-bigger.e-success input:focus~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small.e-bigger.e-success input:valid~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small.e-bigger.e-success input~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small.e-bigger.e-success input[readonly]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small.e-bigger.e-success input[disabled]~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-small.e-success input:focus~label.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-small.e-success input:valid~label.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-small.e-success input~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-small.e-success input[readonly]~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-small.e-success input[disabled]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small.e-bigger.e-success.e-input-focus input~label.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-small.e-success.e-input-focus input~label.e-float-text{color:#22b24b}.e-filled.e-float-input.e-bigger.e-warning input:focus~label.e-float-text,.e-filled.e-float-input.e-bigger.e-warning input:valid~label.e-float-text,.e-filled.e-float-input.e-bigger.e-warning input~label.e-label-top.e-float-text,.e-filled.e-float-input.e-bigger.e-warning input[readonly]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-bigger.e-warning input[disabled]~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input.e-warning input:focus~label.e-float-text,.e-bigger .e-filled.e-float-input.e-warning input:valid~label.e-float-text,.e-bigger .e-filled.e-float-input.e-warning input~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input.e-warning input[readonly]~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input.e-warning input[disabled]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-bigger.e-warning.e-input-focus input~label.e-float-text,.e-bigger .e-filled.e-float-input.e-warning.e-input-focus input~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-bigger.e-warning input:focus~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-bigger.e-warning input:valid~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-bigger.e-warning input~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-bigger.e-warning input[readonly]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-bigger.e-warning input[disabled]~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-warning input:focus~label.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-warning input:valid~label.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-warning input~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-warning input[readonly]~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-warning input[disabled]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-bigger.e-warning.e-input-focus input~label.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-warning.e-input-focus input~label.e-float-text,.e-filled.e-float-input.e-small.e-bigger.e-warning input:focus~label.e-float-text,.e-filled.e-float-input.e-small.e-bigger.e-warning input:valid~label.e-float-text,.e-filled.e-float-input.e-small.e-bigger.e-warning input~label.e-label-top.e-float-text,.e-filled.e-float-input.e-small.e-bigger.e-warning input[readonly]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-small.e-bigger.e-warning input[disabled]~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input.e-small.e-warning input:focus~label.e-float-text,.e-bigger .e-filled.e-float-input.e-small.e-warning input:valid~label.e-float-text,.e-bigger .e-filled.e-float-input.e-small.e-warning input~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input.e-small.e-warning input[readonly]~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input.e-small.e-warning input[disabled]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-small.e-bigger.e-warning.e-input-focus input~label.e-float-text,.e-bigger .e-filled.e-float-input.e-small.e-warning.e-input-focus input~label.e-float-text{color:#ffca1c}.e-filled.e-float-input.e-bigger:not(.e-error) input:focus~label.e-float-text,.e-filled.e-float-input.e-bigger:not(.e-error) input:valid~label.e-float-text,.e-filled.e-float-input.e-bigger:not(.e-error) input~label.e-label-top.e-float-text,.e-filled.e-float-input.e-bigger:not(.e-error) input[readonly]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-bigger:not(.e-error) input[disabled]~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input:not(.e-error) input:focus~label.e-float-text,.e-bigger .e-filled.e-float-input:not(.e-error) input:valid~label.e-float-text,.e-bigger .e-filled.e-float-input:not(.e-error) input~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input:not(.e-error) input[readonly]~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input:not(.e-error) input[disabled]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-bigger:not(.e-error).e-input-focus input~label.e-float-text,.e-bigger .e-filled.e-float-input:not(.e-error).e-input-focus input~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-bigger:not(.e-error) input:focus~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-bigger:not(.e-error) input:valid~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-bigger:not(.e-error) input~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-bigger:not(.e-error) input[readonly]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-bigger:not(.e-error) input[disabled]~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper:not(.e-error) input:focus~label.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper:not(.e-error) input:valid~label.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper:not(.e-error) input~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper:not(.e-error) input[readonly]~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper:not(.e-error) input[disabled]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-bigger:not(.e-error).e-input-focus input~label.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper:not(.e-error).e-input-focus input~label.e-float-text,.e-filled.e-float-input.e-small.e-bigger:not(.e-error) input:focus~label.e-float-text,.e-filled.e-float-input.e-small.e-bigger:not(.e-error) input:valid~label.e-float-text,.e-filled.e-float-input.e-small.e-bigger:not(.e-error) input~label.e-label-top.e-float-text,.e-filled.e-float-input.e-small.e-bigger:not(.e-error) input[readonly]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-small.e-bigger:not(.e-error) input[disabled]~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input.e-small:not(.e-error) input:focus~label.e-float-text,.e-bigger .e-filled.e-float-input.e-small:not(.e-error) input:valid~label.e-float-text,.e-bigger .e-filled.e-float-input.e-small:not(.e-error) input~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input.e-small:not(.e-error) input[readonly]~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input.e-small:not(.e-error) input[disabled]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-small.e-bigger:not(.e-error).e-input-focus input~label.e-float-text,.e-bigger .e-filled.e-float-input.e-small:not(.e-error).e-input-focus input~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small.e-bigger:not(.e-error) input:focus~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small.e-bigger:not(.e-error) input:valid~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small.e-bigger:not(.e-error) input~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small.e-bigger:not(.e-error) input[readonly]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small.e-bigger:not(.e-error) input[disabled]~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-small:not(.e-error) input:focus~label.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-small:not(.e-error) input:valid~label.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-small:not(.e-error) input~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-small:not(.e-error) input[readonly]~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-small:not(.e-error) input[disabled]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small.e-bigger:not(.e-error).e-input-focus input~label.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-small:not(.e-error).e-input-focus input~label.e-float-text,.e-filled.e-float-input.e-bigger:not(.e-error) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-filled.e-float-input.e-control-wrapper.e-bigger:not(.e-error) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger .e-filled.e-float-input:not(.e-error) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger .e-filled.e-float-input.e-control-wrapper:not(.e-error) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-filled.e-float-input.e-small.e-bigger:not(.e-error) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-filled.e-float-input.e-control-wrapper.e-small.e-bigger:not(.e-error) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger .e-filled.e-float-input.e-small:not(.e-error) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-small:not(.e-error) textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-filled.e-float-input.e-bigger:not(.e-error) textarea:focus~label.e-float-text,.e-filled.e-float-input.e-bigger:not(.e-error) textarea:valid~label.e-float-text,.e-filled.e-float-input.e-bigger:not(.e-error) textarea~label.e-label-top.e-float-text,.e-filled.e-float-input.e-bigger:not(.e-error) textarea[readonly]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-bigger:not(.e-error) textarea[disabled]~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input:not(.e-error) textarea:focus~label.e-float-text,.e-bigger .e-filled.e-float-input:not(.e-error) textarea:valid~label.e-float-text,.e-bigger .e-filled.e-float-input:not(.e-error) textarea~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input:not(.e-error) textarea[readonly]~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input:not(.e-error) textarea[disabled]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-bigger:not(.e-error) textarea:focus~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-bigger:not(.e-error) textarea:valid~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-bigger:not(.e-error) textarea~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-bigger:not(.e-error) textarea[readonly]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-bigger:not(.e-error) textarea[disabled]~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper:not(.e-error) textarea:focus~label.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper:not(.e-error) textarea:valid~label.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper:not(.e-error) textarea~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper:not(.e-error) textarea[readonly]~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper:not(.e-error) textarea[disabled]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-small.e-bigger:not(.e-error) textarea:focus~label.e-float-text,.e-filled.e-float-input.e-small.e-bigger:not(.e-error) textarea:valid~label.e-float-text,.e-filled.e-float-input.e-small.e-bigger:not(.e-error) textarea~label.e-label-top.e-float-text,.e-filled.e-float-input.e-small.e-bigger:not(.e-error) textarea[readonly]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-small.e-bigger:not(.e-error) textarea[disabled]~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input.e-small:not(.e-error) textarea:focus~label.e-float-text,.e-bigger .e-filled.e-float-input.e-small:not(.e-error) textarea:valid~label.e-float-text,.e-bigger .e-filled.e-float-input.e-small:not(.e-error) textarea~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input.e-small:not(.e-error) textarea[readonly]~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input.e-small:not(.e-error) textarea[disabled]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small.e-bigger:not(.e-error) textarea:focus~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small.e-bigger:not(.e-error) textarea:valid~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small.e-bigger:not(.e-error) textarea~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small.e-bigger:not(.e-error) textarea[readonly]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small.e-bigger:not(.e-error) textarea[disabled]~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-small:not(.e-error) textarea:focus~label.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-small:not(.e-error) textarea:valid~label.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-small:not(.e-error) textarea~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-small:not(.e-error) textarea[readonly]~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-small:not(.e-error) textarea[disabled]~label.e-label-top.e-float-text{color:#0009}.e-filled.e-float-input.e-bigger:not(.e-error) input:focus~label.e-float-text,.e-bigger .e-filled.e-float-input:not(.e-error) input:focus~label.e-float-text,.e-filled.e-float-input.e-small.e-bigger:not(.e-error) input:focus~label.e-float-text,.e-bigger .e-filled.e-float-input.e-small:not(.e-error) input:focus~label.e-float-text,.e-filled.e-float-input.e-bigger:not(.e-error) input[readonly]:focus~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input:not(.e-error) input[readonly]:focus~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-bigger:not(.e-error) input[readonly]:focus~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper:not(.e-error) input[readonly]:focus~label.e-label-top.e-float-text,.e-filled.e-float-input.e-small.e-bigger:not(.e-error) input[readonly]:focus~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input.e-small:not(.e-error) input[readonly]:focus~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small.e-bigger:not(.e-error) input[readonly]:focus~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-small:not(.e-error) input[readonly]:focus~label.e-label-top.e-float-text,.e-filled.e-float-input.e-bigger:not(.e-error).e-input-focus input[readonly]~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input:not(.e-error).e-input-focus input[readonly]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-bigger:not(.e-error).e-input-focus input[readonly]~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper:not(.e-error).e-input-focus input[readonly]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-small.e-bigger:not(.e-error).e-input-focus input[readonly]~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input.e-small:not(.e-error).e-input-focus input[readonly]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small.e-bigger:not(.e-error).e-input-focus input[readonly]~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-small:not(.e-error).e-input-focus input[readonly]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-bigger:not(.e-error) textarea[readonly]:focus~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input:not(.e-error) textarea[readonly]:focus~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-bigger:not(.e-error) textarea[readonly]:focus~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper:not(.e-error) textarea[readonly]:focus~label.e-label-top.e-float-text,.e-filled.e-float-input.e-small.e-bigger:not(.e-error) textarea[readonly]:focus~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input.e-small:not(.e-error) textarea[readonly]:focus~label.e-label-top.e-float-text .e-filled.e-float-input.e-control-wrapper.e-small:not(.e-error) textarea[readonly]:focus~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small.e-bigger:not(.e-error) textarea[readonly]:focus~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-small:not(.e-error) textarea[readonly]:focus~label.e-label-top.e-float-text,.e-filled.e-float-input.e-bigger:not(.e-error).e-input-focus textarea[readonly]~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input:not(.e-error).e-input-focus textarea[readonly]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-bigger:not(.e-error).e-input-focus textarea[readonly]~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper:not(.e-error).e-input-focus textarea[readonly]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-small.e-bigger:not(.e-error).e-input-focus textarea[readonly]~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input.e-small:not(.e-error).e-input-focus textarea[readonly]~label.e-label-top.e-float-text .e-filled.e-float-input.e-control-wrapper.e-small:not(.e-error).e-input-focus textarea[readonly]~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small.e-bigger:not(.e-error).e-input-focus textarea[readonly]~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-small:not(.e-error).e-input-focus textarea[readonly]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-bigger:not(.e-error) textarea:focus~label.e-float-text,.e-bigger .e-filled.e-float-input:not(.e-error) textarea:focus~label.e-float-text,.e-filled.e-float-input.e-small.e-bigger:not(.e-error) textarea:focus~label.e-float-text,.e-bigger .e-filled.e-float-input.e-small:not(.e-error) textarea:focus~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-bigger:not(.e-error) input:focus~label.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper:not(.e-error) input:focus~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small.e-bigger:not(.e-error) input:focus~label.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-small:not(.e-error) input:focus~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-bigger:not(.e-error) textarea:focus~label.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper:not(.e-error) textarea:focus~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small.e-bigger:not(.e-error) textarea:focus~label.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-small:not(.e-error) textarea:focus~label.e-float-text,.e-filled.e-float-input.e-bigger:not(.e-error).e-input-focus input~label.e-float-text,.e-bigger .e-filled.e-float-input:not(.e-error).e-input-focus input~label.e-float-text,.e-filled.e-float-input.e-small.e-bigger:not(.e-error).e-input-focus input~label.e-float-text,.e-bigger .e-filled.e-float-input.e-small:not(.e-error).e-input-focus input~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-bigger:not(.e-error).e-input-focus input~label.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper:not(.e-error).e-input-focus input~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small.e-bigger:not(.e-error).e-input-focus input~label.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-small:not(.e-error).e-input-focus input~label.e-float-text{color:#e3165b}.e-filled.e-float-input.e-bigger:not(.e-error) input[disabled]~label.e-float-text,.e-filled.e-float-input.e-bigger:not(.e-error) input[disabled]~label.e-float-text.e-label-top,.e-filled.e-float-input.e-small.e-bigger:not(.e-error) input[disabled]~label.e-float-text,.e-filled.e-float-input.e-small.e-bigger:not(.e-error) input[disabled]~label.e-float-text.e-label-top,.e-filled.e-float-input.e-bigger:not(.e-error) textarea[disabled]~label.e-float-text,.e-filled.e-float-input.e-bigger:not(.e-error) textarea[disabled]~label.e-float-text.e-label-top,.e-filled.e-float-input.e-small.e-bigger:not(.e-error) textarea[disabled]~label.e-float-text,.e-filled.e-float-input.e-small.e-bigger:not(.e-error) textarea[disabled]~label.e-float-text.e-label-top,.e-filled.e-float-input.e-control-wrapper.e-bigger:not(.e-error) input[disabled]~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-bigger:not(.e-error) input[disabled]~label.e-float-text.e-label-top,.e-filled.e-float-input.e-control-wrapper.e-small.e-bigger:not(.e-error) input[disabled]~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small.e-bigger:not(.e-error) input[disabled]~label.e-float-text.e-label-top,.e-filled.e-float-input.e-control-wrapper.e-disabled.e-bigger:not(.e-error) input[disabled]~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-disabled.e-bigger:not(.e-error) input[disabled]~label.e-float-text.e-label-top,.e-filled.e-float-input.e-control-wrapper.e-disabled.e-small.e-bigger:not(.e-error) input[disabled]~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-disabled.e-small.e-bigger:not(.e-error) input[disabled]~label.e-float-text.e-label-top,.e-filled.e-float-input.e-control-wrapper.e-bigger:not(.e-error) textarea[disabled]~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-bigger:not(.e-error) textarea[disabled]~label.e-float-text.e-label-top,.e-filled.e-float-input.e-control-wrapper.e-small.e-bigger:not(.e-error) textarea[disabled]~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small.e-bigger:not(.e-error) textarea[disabled]~label.e-float-text.e-label-top,.e-filled.e-float-input.e-control-wrapper.e-disabled.e-bigger:not(.e-error) textarea[disabled]~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-disabled.e-bigger:not(.e-error) textarea[disabled]~label.e-float-text.e-label-top,.e-filled.e-float-input.e-control-wrapper.e-disabled.e-small.e-bigger:not(.e-error) textarea[disabled]~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-disabled.e-small.e-bigger:not(.e-error) textarea[disabled]~label.e-float-text.e-label-top{color:#00000061}.e-filled.e-float-input.e-bigger.e-success textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-filled.e-float-input.e-control-wrapper.e-bigger.e-success textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger .e-filled.e-float-input.e-success textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-success textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-filled.e-float-input.e-small.e-bigger.e-success textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-filled.e-float-input.e-control-wrapper.e-small.e-bigger.e-success textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger .e-filled.e-float-input.e-small.e-success textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-small.e-success textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-filled.e-float-input.e-bigger.e-success textarea:focus~label.e-float-text,.e-filled.e-float-input.e-bigger.e-success textarea:valid~label.e-float-text,.e-filled.e-float-input.e-bigger.e-success textarea~label.e-label-top.e-float-text,.e-filled.e-float-input.e-bigger.e-success textarea[readonly]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-bigger.e-success textarea[disabled]~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input.e-success textarea:focus~label.e-float-text,.e-bigger .e-filled.e-float-input.e-success textarea:valid~label.e-float-text,.e-bigger .e-filled.e-float-input.e-success textarea~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input.e-success textarea[readonly]~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input.e-success textarea[disabled]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-bigger.e-success textarea:focus~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-bigger.e-success textarea:valid~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-bigger.e-success textarea~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-bigger.e-success textarea[readonly]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-bigger.e-success textarea[disabled]~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-success textarea:focus~label.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-success textarea:valid~label.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-success textarea~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-success textarea[readonly]~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-success textarea[disabled]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-small.e-bigger.e-success textarea:focus~label.e-float-text,.e-filled.e-float-input.e-small.e-bigger.e-success textarea:valid~label.e-float-text,.e-filled.e-float-input.e-small.e-bigger.e-success textarea~label.e-label-top.e-float-text,.e-filled.e-float-input.e-small.e-bigger.e-success textarea[readonly]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-small.e-bigger.e-success textarea[disabled]~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input.e-small.e-success textarea:focus~label.e-float-text,.e-bigger .e-filled.e-float-input.e-small.e-success textarea:valid~label.e-float-text,.e-bigger .e-filled.e-float-input.e-small.e-success textarea~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input.e-small.e-success textarea[readonly]~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input.e-small.e-success textarea[disabled]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small.e-bigger.e-success textarea:focus~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small.e-bigger.e-success textarea:valid~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small.e-bigger.e-success textarea~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small.e-bigger.e-success textarea[readonly]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small.e-bigger.e-success textarea[disabled]~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-small.e-success textarea:focus~label.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-small.e-success textarea:valid~label.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-small.e-success textarea~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-small.e-success textarea[readonly]~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-small.e-success textarea[disabled]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-bigger.e-success input:focus~label.e-float-text,.e-bigger .e-filled.e-float-input.e-success input:focus~label.e-float-text,.e-filled.e-float-input.e-small.e-bigger.e-success input:focus~label.e-float-text,.e-bigger .e-filled.e-float-input.e-small.e-success input:focus~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-bigger.e-success input:focus~label.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-success input:focus~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small.e-bigger.e-success input:focus~label.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-small.e-success input:focus~label.e-float-text,.e-filled.e-float-input.e-bigger.e-success.e-input-focus input~label.e-float-text,.e-bigger .e-filled.e-float-input.e-success.e-input-focus input~label.e-float-text,.e-filled.e-float-input.e-small.e-bigger.e-success.e-input-focus input~label.e-float-text,.e-bigger .e-filled.e-float-input.e-small.e-success.e-input-focus input~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-bigger.e-success.e-input-focus input~label.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-success.e-input-focus input~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small.e-bigger.e-success.e-input-focus input~label.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-small.e-success.e-input-focus input~label.e-float-text,.e-bigger .e-filled.e-float-input.e-success:not(.e-input-focus) input:not(:focus):-webkit-autofill~label.e-float-text,.e-bigger.e-filled.e-float-input.e-success:not(.e-input-focus) input:not(:focus):-webkit-autofill~label.e-float-text,.e-bigger .e-filled.e-float-input.e-small.e-success:not(.e-input-focus) input:not(:focus):-webkit-autofill~label.e-float-text,.e-bigger.e-small .e-filled.e-float-input.e-success:not(.e-input-focus) input:not(:focus):-webkit-autofill~label.e-float-text,.e-filled.e-float-input.e-bigger.e-small.e-success:not(.e-input-focus) input:not(:focus):-webkit-autofill~label.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-autofill.e-success:not(.e-input-focus) input:not(:focus):-webkit-autofill~label.e-float-text,.e-bigger.e-filled.e-float-input.e-control-wrapper.e-autofill.e-success:not(.e-input-focus) input:not(:focus):-webkit-autofill~label.e-float-text,.e-bigger .e-filled.e-float-input.e-small.e-control-wrapper.e-autofill.e-success:not(.e-input-focus) input:not(:focus):-webkit-autofill~label.e-float-text,.e-bigger.e-small .e-filled.e-float-input.e-control-wrapper.e-autofill.e-success:not(.e-input-focus) input:not(:focus):-webkit-autofill~label.e-float-text,.e-filled.e-float-input.e-bigger.e-small.e-control-wrapper.e-autofill.e-success:not(.e-input-focus) input:not(:focus):-webkit-autofill~label.e-float-text,.e-bigger .e-filled.e-float-input.e-success textarea:not(:focus):-webkit-autofill~label.e-float-text,.e-bigger.e-filled.e-float-input.e-success textarea:not(:focus):-webkit-autofill~label.e-float-text,.e-bigger .e-filled.e-float-input.e-small.e-success textarea:not(:focus):-webkit-autofill~label.e-float-text,.e-bigger.e-small .e-filled.e-float-input.e-success textarea:not(:focus):-webkit-autofill~label.e-float-text,.e-filled.e-float-input.e-bigger.e-small.e-success textarea:not(:focus):-webkit-autofill~label.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-autofill.e-success textarea:not(:focus):-webkit-autofill~label.e-float-text,.e-bigger.e-filled.e-float-input.e-control-wrapper.e-autofill.e-success textarea:not(:focus):-webkit-autofill~label.e-float-text,.e-bigger .e-filled.e-float-input.e-small.e-control-wrapper.e-autofill.e-success textarea:not(:focus):-webkit-autofill~label.e-float-text,.e-bigger.e-small .e-filled.e-float-input.e-control-wrapper.e-autofill.e-success textarea:not(:focus):-webkit-autofill~label.e-float-text,.e-filled.e-bigger.e-small.e-control-wrapper.e-autofill.e-success textarea:not(:focus):-webkit-autofill~label.e-float-text{color:#22b24b}.e-filled.e-float-input.e-control-wrapper.e-small.e-bigger.e-warning input:focus~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small.e-bigger.e-warning input:valid~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small.e-bigger.e-warning input~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small.e-bigger.e-warning input[readonly]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small.e-bigger.e-warning input[disabled]~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-small.e-warning input:focus~label.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-small.e-warning input:valid~label.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-small.e-warning input~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-small.e-warning input[readonly]~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-small.e-warning input[disabled]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small.e-bigger.e-warning.e-input-focus input~label.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-small.e-warning.e-input-focus input~label.e-float-text,.e-filled.e-float-input.e-bigger.e-warning textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-filled.e-float-input.e-control-wrapper.e-bigger.e-warning textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger .e-filled.e-float-input.e-warning textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-warning textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-filled.e-float-input.e-small.e-bigger.e-warning textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-filled.e-float-input.e-control-wrapper.e-small.e-bigger.e-warning textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger .e-filled.e-float-input.e-small.e-warning textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-small.e-warning textarea:not(:focus):valid~label.e-float-text.e-label-bottom,.e-filled.e-float-input.e-bigger.e-warning textarea:focus~label.e-float-text,.e-filled.e-float-input.e-bigger.e-warning textarea:valid~label.e-float-text,.e-filled.e-float-input.e-bigger.e-warning textarea~label.e-label-top.e-float-text,.e-filled.e-float-input.e-bigger.e-warning textarea[readonly]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-bigger.e-warning textarea[disabled]~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input.e-warning textarea:focus~label.e-float-text,.e-bigger .e-filled.e-float-input.e-warning textarea:valid~label.e-float-text,.e-bigger .e-filled.e-float-input.e-warning textarea~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input.e-warning textarea[readonly]~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input.e-warning textarea[disabled]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-bigger.e-warning textarea:focus~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-bigger.e-warning textarea:valid~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-bigger.e-warning textarea~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-bigger.e-warning textarea[readonly]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-bigger.e-warning textarea[disabled]~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-warning textarea:focus~label.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-warning textarea:valid~label.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-warning textarea~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-warning textarea[readonly]~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-warning textarea[disabled]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-small.e-bigger.e-warning textarea:focus~label.e-float-text,.e-filled.e-float-input.e-small.e-bigger.e-warning textarea:valid~label.e-float-text,.e-filled.e-float-input.e-small.e-bigger.e-warning textarea~label.e-label-top.e-float-text,.e-filled.e-float-input.e-small.e-bigger.e-warning textarea[readonly]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-small.e-bigger.e-warning textarea[disabled]~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input.e-small.e-warning textarea:focus~label.e-float-text,.e-bigger .e-filled.e-float-input.e-small.e-warning textarea:valid~label.e-float-text,.e-bigger .e-filled.e-float-input.e-small.e-warning textarea~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input.e-small.e-warning textarea[readonly]~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input.e-small.e-warning textarea[disabled]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small.e-bigger.e-warning textarea:focus~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small.e-bigger.e-warning textarea:valid~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small.e-bigger.e-warning textarea~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small.e-bigger.e-warning textarea[readonly]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-small.e-bigger.e-warning textarea[disabled]~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-small.e-warning textarea:focus~label.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-small.e-warning textarea:valid~label.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-small.e-warning textarea~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-small.e-warning textarea[readonly]~label.e-label-top.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-small.e-warning textarea[disabled]~label.e-label-top.e-float-text,.e-filled.e-float-input.e-bigger.e-warning input:focus~label.e-float-text,.e-bigger .e-filled.e-float-input.e-warning input:focus~label.e-float-text,.e-filled.e-float-input.e-small.e-bigger.e-warning input:focus~label.e-float-text,.e-bigger .e-filled.e-float-input.e-small.e-warning input:focus~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-bigger.e-warning input:focus~label.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-warning input:focus~label.e-float-text,.e-filled.e-float-input.e-bigger.e-warning.e-input-focus input~label.e-float-text,.e-bigger .e-filled.e-float-input.e-warning.e-input-focus input~label.e-float-text,.e-filled.e-float-input.e-small.e-bigger.e-warning.e-input-focus input~label.e-float-text,.e-bigger .e-filled.e-float-input.e-small.e-warning.e-input-focus input~label.e-float-text,.e-filled.e-float-input.e-control-wrapper.e-bigger.e-warning.e-input-focus input~label.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-warning.e-input-focus input~label.e-float-text,.e-bigger .e-filled.e-float-input.e-warning:not(.e-input-focus) input:not(:focus):-webkit-autofill~label.e-float-text,.e-bigger.e-filled.e-float-input.e-warning:not(.e-input-focus) input:not(:focus):-webkit-autofill~label.e-float-text,.e-bigger .e-filled.e-float-input.e-small.e-warning:not(.e-input-focus) input:not(:focus):-webkit-autofill~label.e-float-text,.e-bigger.e-small .e-filled.e-float-input.e-warning:not(.e-input-focus) input:not(:focus):-webkit-autofill~label.e-float-text,.e-filled.e-float-input.e-bigger.e-small.e-warning:not(.e-input-focus) input:not(:focus):-webkit-autofill~label.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-autofill.e-warning:not(.e-input-focus) input:not(:focus):-webkit-autofill~label.e-float-text,.e-bigger.e-filled.e-float-input.e-control-wrapper.e-autofill.e-warning:not(.e-input-focus) input:not(:focus):-webkit-autofill~label.e-float-text,.e-bigger .e-filled.e-float-input.e-small.e-control-wrapper.e-autofill.e-warning:not(.e-input-focus) input:not(:focus):-webkit-autofill~label.e-float-text,.e-bigger.e-small .e-filled.e-float-input.e-control-wrapper.e-autofill.e-warning:not(.e-input-focus) input:not(:focus):-webkit-autofill~label.e-float-text,.e-filled.e-float-input.e-bigger.e-small.e-control-wrapper.e-autofill.e-warning:not(.e-input-focus) input:not(:focus):-webkit-autofill~label.e-float-text,.e-bigger .e-filled.e-float-input.e-warning textarea:not(:focus):-webkit-autofill~label.e-float-text,.e-bigger.e-filled.e-float-input.e-warning textarea:not(:focus):-webkit-autofill~label.e-float-text,.e-bigger .e-filled.e-float-input.e-small.e-warning textarea:not(:focus):-webkit-autofill~label.e-float-text,.e-bigger.e-small .e-filled.e-float-input.e-warning textarea:not(:focus):-webkit-autofill~label.e-float-text,.e-filled.e-float-input.e-bigger.e-small.e-warning textarea:not(:focus):-webkit-autofill~label.e-float-text,.e-bigger .e-filled.e-float-input.e-control-wrapper.e-autofill.e-warning textarea:not(:focus):-webkit-autofill~label.e-float-text,.e-bigger.e-filled.e-float-input.e-control-wrapper.e-autofill.e-warning textarea:not(:focus):-webkit-autofill~label.e-float-text,.e-bigger .e-filled.e-float-input.e-small.e-control-wrapper.e-autofill.e-warning textarea:not(:focus):-webkit-autofill~label.e-float-text,.e-bigger.e-small .e-filled.e-float-input.e-control-wrapper.e-autofill.e-warning textarea:not(:focus):-webkit-autofill~label.e-float-text,.e-filled.e-bigger.e-small.e-control-wrapper.e-autofill.e-warning textarea:not(:focus):-webkit-autofill~label.e-float-text{color:#ffca1c}.e-outline.e-float-input.e-bigger input:focus~label.e-float-text,.e-outline.e-float-input.e-bigger input:valid~label.e-float-text,.e-outline.e-float-input.e-bigger input~label.e-label-top.e-float-text,.e-outline.e-float-input.e-bigger input[readonly]~label.e-label-top.e-float-text,.e-outline.e-float-input.e-bigger input[disabled]~label.e-label-top.e-float-text,.e-outline.e-float-input.e-bigger input label.e-float-text.e-label-top,.e-bigger .e-outline.e-float-input input:focus~label.e-float-text,.e-bigger .e-outline.e-float-input input:valid~label.e-float-text,.e-bigger .e-outline.e-float-input input~label.e-label-top.e-float-text,.e-bigger .e-outline.e-float-input input[readonly]~label.e-label-top.e-float-text,.e-bigger .e-outline.e-float-input input[disabled]~label.e-label-top.e-float-text,.e-bigger .e-outline.e-float-input input label.e-float-text.e-label-top,.e-bigger .e-outline.e-float-input.e-control-wrapper input:focus~label.e-float-text,.e-bigger .e-outline.e-float-input.e-control-wrapper input:valid~label.e-float-text,.e-bigger .e-outline.e-float-input.e-control-wrapper input~label.e-label-top.e-float-text,.e-bigger .e-outline.e-float-input.e-control-wrapper input[readonly]~label.e-label-top.e-float-text,.e-bigger .e-outline.e-float-input.e-control-wrapper input[disabled]~label.e-label-top.e-float-text,.e-bigger .e-outline.e-float-input.e-control-wrapper input label.e-float-text.e-label-top,.e-outline.e-float-input.e-control-wrapper.e-bigger input:focus~label.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-bigger input:valid~label.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-bigger input~label.e-label-top.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-bigger input[readonly]~label.e-label-top.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-bigger input[disabled]~label.e-label-top.e-float-text,.e-outline.e-float-input.e-control-wrappe.e-bigger input label.e-float-text.e-label-top,.e-outline.e-float-input.e-bigger textarea:focus~label.e-float-text,.e-outline.e-float-input.e-bigger textarea:valid~label.e-float-text,.e-outline.e-float-input.e-bigger textarea~label.e-label-top.e-float-text,.e-outline.e-float-input.e-bigger textarea[readonly]~label.e-label-top.e-float-text,.e-outline.e-float-input.e-bigger textarea[disabled]~label.e-label-top.e-float-text,.e-outline.e-float-input.e-bigger textarea label.e-float-text.e-label-top,.e-bigger .e-outline.e-float-input textarea:focus~label.e-float-text,.e-bigger .e-outline.e-float-input textarea:valid~label.e-float-text,.e-bigger .e-outline.e-float-input textarea~label.e-label-top.e-float-text,.e-bigger .e-outline.e-float-input textarea[readonly]~label.e-label-top.e-float-text,.e-bigger .e-outline.e-float-input textarea[disabled]~label.e-label-top.e-float-text,.e-bigger .e-outline.e-float-input textarea label.e-float-text.e-label-top,.e-outline.e-float-input.e-control-wrapper.e-bigger textarea:focus~label.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-bigger textarea:valid~label.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-bigger textarea~label.e-label-top.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-bigger textarea[readonly]~label.e-label-top.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-bigger textarea[disabled]~label.e-label-top.e-float-text,.e-outline.e-float-input.e-control-wrapper.e-bigger textarea label.e-float-text.e-label-top,.e-bigger .e-outline.e-float-input.e-control-wrapper textarea:focus~label.e-float-text,.e-bigger .e-outline.e-float-input.e-control-wrapper textarea:valid~label.e-float-text,.e-bigger .e-outline.e-float-input.e-control-wrapper textarea~label.e-label-top.e-float-text,.e-bigger .e-outline.e-float-input.e-control-wrapper textarea[readonly]~label.e-label-top.e-float-text,.e-bigger .e-outline.e-float-input.e-control-wrapper textarea[disabled]~label.e-label-top.e-float-text,.e-bigger .e-outline.e-float-input.e-control-wrapper textarea label.e-float-text.e-label-top,.e-outline.e-float-input.e-input-focus.e-bigger input~label.e-float-text,.e-bigger .e-outline.e-float-input.e-control-wrapper.e-input-focus input~label.e-float-text{top:-7px;transform:translateZ(0) scale(1)}.e-input-group-icon.e-spin-up:before{content:"\e834";font-family:e-icons}.e-input-group-icon.e-spin-down:before{content:"\e83d";font-family:e-icons}.e-numeric-container{width:100%}.e-content-placeholder.e-numeric.e-placeholder-numeric{background-size:300px 33px;min-height:33px}.e-float-input.e-input-group.e-control-wrapper.e-numeric .e-numeric-hidden,.e-input-group.e-control-wrapper.e-numeric .e-numeric-hidden,.e-float-input.e-control-wrapper.e-numeric .e-numeric-hidden,.e-float-input.e-input-group.e-control-wrapper.e-numeric.e-input-focus .e-numeric-hidden,.e-input-group.e-control-wrapper.e-numeric.e-input-focus .e-numeric-hidden,.e-float-input.e-control-wrapper.e-numeric.e-input-focus .e-numeric-hidden{border:0;height:0;margin:0;padding:0;text-indent:0;visibility:hidden;width:0}.e-numeric.e-control-wrapper.e-input-group .e-input-group-icon{font-size:12px}.e-bigger.e-content-placeholder.e-numeric.e-placeholder-numeric,.e-bigger .e-content-placeholder.e-numeric.e-placeholder-numeric{background-size:300px 40px;min-height:40px}.e-bigger .e-control-wrapper.e-numeric.e-input-group .e-input-group-icon,.e-bigger.e-control-wrapper.e-numeric.e-input-group .e-input-group-icon{font-size:12px}/*! maskedtextbox layout */.e-control-wrapper.e-mask .e-maskedtextbox{font-family:Arial,Roboto,Segoe UI,GeezaPro,"DejaVu Serif","sans-serif",-apple-system,BlinkMacSystemFont;font-size:12.5px}.e-content-placeholder.e-mask.e-placeholder-mask{background-size:300px 33px;min-height:33px}/*! maskedtextbox theme */.e-control-wrapper.e-mask.e-error .e-maskedtextbox,.e-utility-mask.e-error{color:#f44336}.e-bigger .e-control-wrapper.e-mask .e-maskedtextbox,.e-control-wrapper.e-mask.e-bigger .e-maskedtextbox{font-size:13px}.e-bigger .e-content-placeholder.e-mask.e-placeholder-mask,.e-bigger.e-content-placeholder.e-mask.e-placeholder-mask{background-size:300px 40px;min-height:40px}.e-control-wrapper.e-slider-container{-moz-user-select:none;-ms-user-select:none;-webkit-tap-highlight-color:transparent;-webkit-touch-callout:none;-webkit-user-select:none;box-sizing:border-box;display:inline-block;height:18px;line-height:normal;outline:none;position:relative;user-select:none}.e-control-wrapper.e-slider-container.e-material-slider .e-slider .e-handle.e-material-handle{cursor:default;transition:transform .4s cubic-bezier(.25,.8,.25,1);z-index:3}.e-control-wrapper.e-slider-container.e-material-slider .e-slider .e-handle.e-tab-handle:after,.e-control-wrapper.e-slider-container.e-material-slider .e-slider .e-handle.e-handle-start.e-tab-handle:after{background-color:transparent}.e-control-wrapper.e-slider-container:hover .e-scale .e-tick,.e-control-wrapper.e-slider-container:active .e-scale .e-tick{visibility:visible}.e-control-wrapper.e-slider-container:after{content:"material";display:none}.e-control-wrapper.e-slider-container .e-slider{box-sizing:border-box;cursor:default;display:block;outline:0 none;padding:0;position:relative}.e-control-wrapper.e-slider-container .e-slider .e-handle{border-radius:50%;box-sizing:border-box;height:12px;width:12px;outline:none;position:absolute;touch-action:none;transition:left .3s ease-out,right .3s ease-out,bottom .3s ease-out,transform .3s ease-out;z-index:10;cursor:grab}.e-control-wrapper.e-slider-container .e-slider .e-handle.e-large-thumb-size{transform:scale(1.5)}.e-control-wrapper.e-slider-container .e-slider .e-handle.e-handle-active{cursor:grabbing}.e-control-wrapper.e-slider-container .e-slider .e-handle.e-handle-start{background-color:#fff;border:2px solid rgba(0,0,0,.26)}.e-control-wrapper.e-slider-container .e-slider .e-handle:after{-moz-box-sizing:content-box;-webkit-box-sizing:content-box;transform:scale(0);border:0 solid;border-radius:50%;box-sizing:content-box;content:"";height:32px;width:32px;position:absolute;top:calc(50% - 16px);left:calc(50% - 16px);opacity:.26;transition:transform .4s cubic-bezier(.25,.8,.25,1);z-index:-1}.e-control-wrapper.e-slider-container .e-slider .e-handle.e-tab-handle.e-handle-start:after{background-color:#e0e0e0;opacity:.38}.e-control-wrapper.e-slider-container .e-slider .e-handle.e-tab-handle:after{transform:scale(1);background-color:#e3165b}.e-control-wrapper.e-slider-container.e-rtl.e-horizontal .e-slider .e-handle{margin:0 -6px 0 0;top:calc(50% - 6px)}.e-control-wrapper.e-slider-container.e-rtl.e-horizontal .e-scale.e-h-scale .e-tick.e-first-tick{background-position-x:right}.e-control-wrapper.e-slider-container.e-rtl.e-horizontal .e-scale.e-h-scale .e-tick.e-last-tick{background-position-x:left}.e-control-wrapper.e-slider-container.e-rtl.e-vertical{direction:ltr}.e-control-wrapper.e-slider-container.e-disabled.e-material-slider .e-slider .e-handle.e-handle-first{background-color:#757575}.e-control-wrapper.e-slider-container.e-disabled:hover .e-scale .e-tick{visibility:hidden}.e-control-wrapper.e-slider-container.e-disabled .e-slider .e-range{background:#00000042}.e-control-wrapper.e-slider-container.e-disabled .e-slider .e-handle{background:#757575;transform:scale(.5)!important}.e-control-wrapper.e-slider-container.e-disabled .e-slider .e-handle.e-handle-first{background-color:#757575;border:0}.e-control-wrapper.e-slider-container.e-disabled .e-slider .e-handle:after{transform:scale(1);background:transparent;border:7px solid #fff;border-radius:50%;box-sizing:border-box;content:"";height:26px;width:26px;position:absolute;top:calc(50% - 13px);left:calc(50% - 13px);opacity:1;transition:none;z-index:-1}.e-control-wrapper.e-slider-container.e-disabled .e-btn,.e-control-wrapper.e-slider-container.e-disabled .e-slider .e-handle{cursor:default}.e-control-wrapper.e-slider-container.e-disabled .e-slider .e-handle.e-handle-disable{display:block}.e-control-wrapper.e-slider-container.e-horizontal{height:48px;width:100%}.e-control-wrapper.e-slider-container.e-horizontal .e-first-button{left:0;margin-top:-9px;top:50%}.e-control-wrapper.e-slider-container.e-horizontal .e-first-button .e-button-icon{background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADAAAAAwCAMAAABg3Am1AAAAkFBMVEUAAAD////////////////////////+/v7////+/v7////////+/v7+/v7////////+/v7+/v7+/v7////+/v7+/v7+/v7+/v7////+/v7+/v7+/v7+/v7+/v7+/v7+/v7+/v7+/v7+/v7+/v7+/v7+/v7+/v7+/v7+/v7+/v7+/v7+/v7+/v7+/v7+/v7///8G+5iqAAAAL3RSTlMABAgMEBQYHCAkKDA0ODxETFRYYGRsdHyAh4uTm6Onr7O/w8fL09ff4+fr7/P3+/6nVicAAADJSURBVHgBldJHdoNgAANhQUjvPTHuxbgAuv/t/J5O8I82Wn27UfGaVmjvBwvsdmEDUH33JuBxYwNQ/48m4LWzAbie2QR8nkzA/coGoPodTMDzzgagae1ykHAASDgAJBwAEk4xSDgAJBwAEg4ACacYJBwAEg4ACYeAjyMEaqYQSC97CFT/DQxID2sIpK8zBLqZQyC9dRDoajIyID1tIVD10zMg3S0ZSF4IJC8GkhcDyQuB5MVA8kIgeTGQvBhIXggkLwaSFwLJK3cBRvanB71ijlkAAAAASUVORK5CYII=);background-repeat:no-repeat;background-size:cover;display:inline-block;height:7px;width:7px;position:absolute;top:calc(50% - 3.6px);left:calc(50% - 4.6px)}.e-control-wrapper.e-slider-container.e-horizontal .e-second-button{right:0;margin-top:-9px;top:50%}.e-control-wrapper.e-slider-container.e-horizontal .e-second-button .e-button-icon{background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADAAAAAwCAMAAABg3Am1AAAAkFBMVEUAAAD////////////////////////+/v7////////+/v7+/v7+/v7////////+/v7////+/v7+/v7+/v7+/v7+/v7////////+/v7+/v7+/v7+/v7+/v7+/v7+/v7+/v7+/v7+/v7+/v7+/v7+/v7+/v7+/v7+/v7+/v7+/v7+/v7+/v7+/v7+/v7+/v7///9VYKa9AAAAL3RSTlMABAgMEBQYHCAoLDQ4PEBMUFhcZGx0eICDi5Obn6ers7vDx8vP19vf4+fr7/P3++LF0fAAAADNSURBVHgBldNHbsNAGEPhkZSi9F4S915k6d3/dga8Jgjw7bkYzPeXS5ObkkX3EQ5gcRcO6H/qbACbp3AAo6twwOEtHMCsDQecvqpsAKuHcMDw12QD2L2EA/C8EFleiCwvRJYXIssLmeGFzPBCZnghM7yQGV7IDC9Eglc26D6zwfS2JIP9a/To4b8pyWD9GH1c/11FNOZthO/4nvEeX5dksH2OTnT4rUsyWN4Xk4cj8nBEHo7IwxF5OCIPR+ThiDwckYcj8nBEHo5Iw5GdAVm8p9sPUXNKAAAAAElFTkSuQmCC);background-repeat:no-repeat;background-size:cover;display:inline-block;height:7px;width:7px;position:absolute;top:calc(50% - 3.6px);left:calc(50% - 2.6px)}.e-control-wrapper.e-slider-container.e-horizontal.e-slider-btn{padding:0 30px}.e-control-wrapper.e-slider-container.e-horizontal .e-slider{height:32px;width:100%;position:relative;top:calc(50% - 16px)}.e-control-wrapper.e-slider-container.e-horizontal .e-slider-track{height:2px;width:100%;left:0;position:absolute;overflow:hidden;background:#00000042;top:calc(50% - 1px)}.e-control-wrapper.e-slider-container.e-horizontal .e-handle{margin-left:-6px;top:calc(50% - 6px)}.e-control-wrapper.e-slider-container.e-horizontal.e-scale-both .e-range{height:2px}.e-control-wrapper.e-slider-container.e-horizontal .e-range{height:2px;top:calc(50% - 1px);top:calc(50% - 2px)}.e-control-wrapper.e-slider-container.e-horizontal .e-limits{background-color:#00000042;position:absolute;height:2px;top:calc(50% - 1px)}.e-control-wrapper.e-slider-container.e-vertical{height:inherit;width:48px;padding:38px 0}.e-control-wrapper.e-slider-container.e-vertical .e-slider{height:100%;width:32px;left:calc(50% - 16px);position:relative}.e-control-wrapper.e-slider-container.e-vertical .e-slider-track{background:#00000042;bottom:0;height:100%;position:absolute;overflow:hidden;width:2px;left:calc(50% - 1px)}.e-control-wrapper.e-slider-container.e-vertical.e-small-size.e-slider-btn{height:100%;padding:30px 0}.e-control-wrapper.e-slider-container.e-vertical.e-small-size.e-slider-btn .e-slider{height:100%;width:2px}.e-control-wrapper.e-slider-container.e-vertical .e-first-button{bottom:0;margin-right:-9px;right:50%}.e-control-wrapper.e-slider-container.e-vertical .e-first-button .e-button-icon{background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAMAAABEpIrGAAAAjVBMVEUAAAD////////////////////////+/v7////+/v7////////+/v7////////+/v7+/v7+/v7+/v7////+/v7+/v7+/v7+/v7+/v7+/v7+/v7+/v7+/v7+/v7+/v7+/v7+/v7+/v7+/v7+/v7+/v7+/v7+/v7+/v7+/v7+/v7+/v7+/v7+/v7+/v7////1kjJ6AAAALnRSTlMABAgMEBQYHCAkKDA4QERITFRcYGRodHyDj5OXn6Ons7e7v8vP09ff5+vv8/f7zZvJMAAAAItJREFUeAHdyVcagjAQBsAfUVTAXsTeSTRm7388i/kUQjYHYF4H9bAUXjuEV/KQEdC98f9I8dLXxJngY879CsbG/ccARuPsetHCT1tWXyUoSDXZRiiZ2p/Bsi7/HrbgVPw8REUk/n+P4ZAoMvQATmMyFmBk39+CExzefwnBauZEsgOPWOkevIYz1NEToo45F58KJy0AAAAASUVORK5CYII=);background-repeat:no-repeat;background-size:cover;display:inline-block;height:8px;width:8px;position:absolute;top:calc(50% - 2.7px);left:calc(50% - 3.8px)}.e-control-wrapper.e-slider-container.e-vertical .e-second-button{top:0;margin-right:-9px;right:50%}.e-control-wrapper.e-slider-container.e-vertical .e-second-button .e-button-icon{background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAMAAABEpIrGAAAAjVBMVEUAAAD////////////////////////////////+/v7////+/v7+/v7////////+/v7+/v7////+/v7////+/v7+/v7////+/v7+/v7+/v7+/v7+/v7+/v7+/v7+/v7+/v7+/v7+/v7+/v7+/v7+/v7+/v7+/v7+/v7+/v7+/v7+/v7+/v7+/v7+/v7////wrNfvAAAALnRSTlMABAgMEBQYICgsMDQ4QERITFBcYGhseHyDi5Obn6Ort7u/x8/X29/j5+vv8/f77y3LJgAAAI1JREFUeAHdyVeagjAUBtCbYQTsXewFENGYf//LsyB8kORmAZzXQ600mLrfz2XX9X8xcO0Qb4+3s2B/ia8N9yOFwtz+wR0/z77tvQSVm0+mI2piYXyEhp3+E2gWzQ8lNGpY//8UhjygijjBIvGotIbVofwZGFHxPQmGGn/ez8B6hETiAofUo1XmtKVWeAEhzjgqqZr/lwAAAABJRU5ErkJggg==);background-repeat:no-repeat;background-size:cover;display:inline-block;height:8px;width:8px;position:absolute;top:calc(50% - 4.7px);left:calc(50% - 3.8px)}.e-control-wrapper.e-slider-container.e-vertical.e-scale-both .e-slider .e-handle{margin-bottom:-6px}.e-control-wrapper.e-slider-container.e-vertical .e-slider .e-handle{margin-bottom:-6px;left:calc(50% - 6px)}.e-control-wrapper.e-slider-container.e-vertical .e-slider .e-range{width:2px;left:calc(50% - 1px)}.e-control-wrapper.e-slider-container.e-vertical .e-slider .e-limits{background-color:#00000042;position:absolute;width:2px;left:calc(50% - 1px)}.e-control-wrapper.e-slider-container .e-range{border-radius:2px;position:absolute;transition:left .3s ease-out,right .3s ease-out,bottom .3s ease-out,width .3s ease-out,height .3s ease-out}.e-control-wrapper.e-slider-container .e-range.e-drag-horizontal,.e-control-wrapper.e-slider-container .e-range.e-drag-vertical{cursor:pointer}.e-control-wrapper.e-slider-container .e-tick-before.e-scale.e-h-scale .e-tick{height:7px;top:5px;background-position:bottom}.e-control-wrapper.e-slider-container .e-tick-before.e-scale.e-h-scale .e-large{height:10px;top:5px}.e-control-wrapper.e-slider-container .e-tick-before.e-scale.e-v-scale .e-tick{background-position:right;width:50%;left:1px}.e-control-wrapper.e-slider-container .e-tick-after.e-scale.e-h-scale .e-tick{height:7px;top:10px;background-position-x:center}.e-control-wrapper.e-slider-container .e-tick-after.e-scale.e-h-scale .e-large{height:10px;top:13px}.e-control-wrapper.e-slider-container .e-tick-after.e-scale.e-v-scale .e-tick{background-position:left;width:50%;left:calc(50% - 1px)}.e-control-wrapper.e-slider-container .e-tick-both.e-scale.e-h-scale .e-tick{background-position:center;height:12px}.e-control-wrapper.e-slider-container .e-tick-both.e-scale.e-h-scale .e-large{height:20px;top:4px}.e-control-wrapper.e-slider-container .e-tick-both.e-scale.e-v-scale .e-tick{background-position:center;width:100%}.e-control-wrapper.e-slider-container .e-tick-both.e-scale.e-v-scale .e-large{width:100%}.e-control-wrapper.e-slider-container .e-scale{box-sizing:content-box;font-family:Roboto,Segoe UI,GeezaPro,"DejaVu Serif","sans-serif",-apple-system,BlinkMacSystemFont;height:28px;width:100%;line-height:normal;list-style:none outside none;margin:0;outline:0 none;padding:0;position:absolute;top:calc(50% - 14px);z-index:1}.e-control-wrapper.e-slider-container .e-scale .e-tick{background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAIAAAACCAYAAABytg0kAAAACXBIWXMAAAsSAAALEgHS3X78AAAAFElEQVQI12NkYGAIZ2BgYGBigAIABPgAW+yfXroAAAAASUVORK5CYII=);cursor:default;outline:none;position:relative;-webkit-user-select:none;user-select:none}.e-control-wrapper.e-slider-container .e-scale .e-tick .e-tick-value{color:#000;font-family:Roboto,Segoe UI,GeezaPro,"DejaVu Serif","sans-serif",-apple-system,BlinkMacSystemFont;font-size:10px;outline:none;position:absolute;-webkit-user-select:none;user-select:none;white-space:nowrap}.e-control-wrapper.e-slider-container .e-scale.e-v-scale{height:100%;width:28px;left:calc(50% - 14px);top:0}.e-control-wrapper.e-slider-container .e-scale.e-v-scale .e-tick{background-repeat:no-repeat}.e-control-wrapper.e-slider-container .e-scale.e-v-scale .e-tick.e-first-tick{background-position-y:top}.e-control-wrapper.e-slider-container .e-scale.e-v-scale .e-tick.e-last-tick{background-position-y:bottom}.e-control-wrapper.e-slider-container .e-scale.e-h-scale .e-tick{display:inline-block;background-repeat:repeat-y}.e-control-wrapper.e-slider-container .e-scale.e-h-scale .e-tick .e-tick-value.e-tick-before,.e-control-wrapper.e-slider-container .e-scale.e-h-scale .e-tick .e-tick-value.e-tick-both:first-child{top:-18px}.e-control-wrapper.e-slider-container .e-scale.e-h-scale .e-tick .e-tick-value.e-tick-after,.e-control-wrapper.e-slider-container .e-scale.e-h-scale .e-tick .e-tick-value.e-tick-both{bottom:-20px}.e-control-wrapper.e-slider-container .e-scale.e-h-scale .e-tick.e-first-tick{background-position-x:left}.e-control-wrapper.e-slider-container .e-scale.e-h-scale .e-tick.e-last-tick{background-position-x:right}.e-control-wrapper.e-slider-container .e-scale .e-tick{visibility:hidden}.e-control-wrapper.e-slider-container .e-scale .e-tick .e-tick-value{visibility:visible}.e-control-wrapper.e-slider-container .e-scale.e-v-scale .e-tick .e-tick-value.e-tick-before{right:26px}.e-control-wrapper.e-slider-container .e-scale.e-v-scale .e-tick .e-tick-value.e-tick-after{left:27px}.e-control-wrapper.e-slider-container .e-scale.e-v-scale .e-tick .e-tick-value.e-tick-both{right:41px}.e-control-wrapper.e-slider-container .e-scale.e-v-scale .e-tick .e-tick-value.e-tick-both:first-child{left:39px}.e-slider-tooltip.e-tooltip-wrap.e-popup{background-color:#e3165b;border:0;border-radius:8px;cursor:grab;opacity:1}.e-slider-tooltip.e-tooltip-wrap.e-popup.e-popup.e-popup-close{display:block;opacity:0}.e-slider-tooltip.e-tooltip-wrap.e-popup.e-material-tooltip-start{background-color:#00000042}.e-slider-tooltip.e-tooltip-wrap.e-popup.e-material-tooltip-start .e-arrow-tip-inner{color:#000;opacity:0}.e-slider-tooltip.e-tooltip-wrap.e-popup.e-material-tooltip-start .e-arrow-tip-outer.e-tip-bottom{border-top-color:#00000042}.e-slider-tooltip.e-tooltip-wrap.e-popup.e-material-tooltip-start .e-arrow-tip-outer.e-tip-top{border-bottom-color:#00000042}.e-slider-tooltip.e-tooltip-wrap.e-popup.e-material-tooltip-start .e-arrow-tip-outer.e-tip-right{border-left-color:#00000042}.e-slider-tooltip.e-tooltip-wrap.e-popup.e-material-tooltip-start .e-arrow-tip-outer.e-tip-left{border-right-color:#00000042}.e-slider-tooltip.e-tooltip-wrap.e-popup.e-tooltip-active{cursor:grabbing}.e-slider-tooltip.e-tooltip-wrap.e-popup .e-arrow-tip{visibility:visible}.e-slider-tooltip.e-tooltip-wrap.e-popup .e-tip-content{background-color:transparent;height:16px;width:100%;overflow:hidden;padding:0 8px;text-align:center;top:calc(50% - 8px);position:relative;line-height:16px}.e-slider-tooltip.e-tooltip-wrap.e-popup .e-tip-content.e-material-tooltip-show{color:#fff}.e-slider-tooltip.e-tooltip-wrap.e-popup .e-tip-content.e-material-tooltip-hide{color:transparent}.e-slider-tooltip.e-tooltip-wrap.e-popup .e-arrow-tip-inner{color:#e3165b}.e-slider-tooltip.e-tooltip-wrap.e-popup .e-arrow-tip-outer.e-tip-bottom{border-top-color:#e3165b}.e-slider-tooltip.e-tooltip-wrap.e-popup .e-arrow-tip-outer.e-tip-top{border-bottom-color:#e3165b}.e-slider-tooltip.e-tooltip-wrap.e-popup .e-arrow-tip-outer.e-tip-right{border-left-color:#e3165b}.e-slider-tooltip.e-tooltip-wrap.e-popup .e-arrow-tip-outer.e-tip-left{border-right-color:#e3165b}.e-slider-tooltip.e-tooltip-wrap.e-popup.e-tooltip-wrap.e-popup.e-material-default{background-color:#e3165b;border:0;border-radius:50% 50% 0%;cursor:grab;opacity:1}.e-slider-tooltip.e-tooltip-wrap.e-popup.e-tooltip-wrap.e-popup.e-material-default.e-material-tooltip-start{background-color:#00000042}.e-slider-tooltip.e-tooltip-wrap.e-popup.e-tooltip-wrap.e-popup.e-material-default.e-tooltip-active{cursor:grabbing}.e-slider-tooltip.e-tooltip-wrap.e-popup.e-tooltip-wrap.e-popup.e-material-default .e-arrow-tip{visibility:hidden}.e-slider-tooltip.e-tooltip-wrap.e-popup.e-tooltip-wrap.e-popup.e-material-default.e-slider-horizontal-before{transform:rotate(45deg)}.e-slider-tooltip.e-tooltip-wrap.e-popup.e-tooltip-wrap.e-popup.e-material-default.e-slider-horizontal-before .e-tip-content{transform:rotate(-45deg)}.e-slider-tooltip.e-tooltip-wrap.e-popup.e-tooltip-wrap.e-popup.e-material-default.e-slider-horizontal-after{transform:rotate(225deg)}.e-slider-tooltip.e-tooltip-wrap.e-popup.e-tooltip-wrap.e-popup.e-material-default.e-slider-horizontal-after .e-tip-content{transform:rotate(-225deg)}.e-slider-tooltip.e-tooltip-wrap.e-popup.e-tooltip-wrap.e-popup.e-material-default.e-slider-vertical-before{transform:rotate(-45deg)}.e-slider-tooltip.e-tooltip-wrap.e-popup.e-tooltip-wrap.e-popup.e-material-default.e-slider-vertical-before .e-tip-content{transform:rotate(45deg)}.e-slider-tooltip.e-tooltip-wrap.e-popup.e-tooltip-wrap.e-popup.e-material-default.e-slider-vertical-after{transform:rotate(-225deg)}.e-slider-tooltip.e-tooltip-wrap.e-popup.e-tooltip-wrap.e-popup.e-material-default.e-slider-vertical-after .e-tip-content{transform:rotate(225deg)}.e-slider-tooltip.e-tooltip-wrap.e-popup.e-tooltip-wrap.e-popup.e-material-default .e-tip-content{background-color:transparent;height:16px;width:100%;overflow:hidden;padding:0;text-align:center;top:calc(50% - 8px)}.e-slider-tooltip.e-tooltip-wrap.e-popup.e-tooltip-wrap.e-popup.e-material-default .e-tip-content.e-material-tooltip-show{color:#fff}.e-slider-tooltip.e-tooltip-wrap.e-popup.e-tooltip-wrap.e-popup.e-material-default .e-tip-content.e-material-tooltip-hide{color:transparent}.e-slider-horizantal-color{height:100%;top:0;position:absolute}.e-slider-vertical-color{position:absolute;width:100%;left:-1px}.e-slider-hover .e-scale .e-tick{visibility:visible}.e-control-wrapper.e-slider-container.e-material-slider .e-slider .e-handle.e-handle-first,.e-control-wrapper.e-slider-container.e-material-slider .e-slider .e-handle.e-handle-second{background:transparent;border-color:transparent}.e-control-wrapper.e-slider-container .e-slider-button{background-color:#0000008a;border:1px solid transparent;box-sizing:border-box;cursor:pointer;outline:none;position:absolute;height:18px;width:18px;border-radius:50%;padding:0}.e-control-wrapper.e-slider-container .e-slider .e-range{background-color:#e3165b}.e-control-wrapper.e-slider-container .e-slider .e-handle{background-color:#e3165b;border-color:#e3165b}.e-control-wrapper.e-slider-container .e-slider .e-handle.e-material-tooltip{background-color:transparent;border-color:transparent}.e-control-wrapper.e-slider-container.e-slider-hover .e-slider-track{background-color:#00000042}.e-control-wrapper.e-slider-container.e-slider-hover .e-range{background-color:#e3165b}.e-control-wrapper.e-slider-container.e-slider-hover .e-handle{border-color:#e3165b}.e-bigger.e-slider-tooltip.e-tooltip-wrap.e-popup .e-tip-content{font-size:11px;line-height:16px}.e-bigger .e-control-wrapper.e-slider-container .e-scale .e-tick .e-tick-value,.e-control-wrapper.e-slider-container.e-bigger .e-scale .e-tick .e-tick-value{font-size:12px}.e-content-placeholder.e-textbox.e-placeholder-textbox{background-size:300px 33px;min-height:33px}.e-input-group.e-input-focus.e-multi-line-input textarea.e-textbox{padding-right:30px}.e-input-group.e-input-focus.e-rtl.e-multi-line-input textarea.e-textbox{padding-left:30px}.e-bigger .e-content-placeholder.e-textbox.e-placeholder-textbox,.e-bigger.e-content-placeholder.e-textbox.e-placeholder-textbox{background-size:300px 40px;min-height:40px}.e-bigger .e-input-group.e-input-focus.e-multi-line-input textarea.e-textbox{padding-right:32px}.e-bigger .e-input-group.e-input-focus.e-rtl.e-multi-line-input textarea.e-textbox{padding-left:32px}.e-input-group.e-multi-line-input.e-auto-width{width:auto}.e-input-group.e-multi-line-input textarea.e-resize-x{resize:horizontal}.e-input-group.e-multi-line-input textarea.e-resize-y{resize:vertical}.e-input-group.e-multi-line-input textarea.e-resize-xy{resize:both}.e-input-group.e-multi-line-input textarea.e-textarea.e-resize-none{resize:none}.e-float-input .e-clear-icon:hover,.e-float-input.e-control-wrapper .e-clear-icon:hover,.e-input-group .e-clear-icon:hover,.e-input-group.e-control-wrapper .e-clear-icon:hover{background:none;border:none}.e-float-input:not(.e-disabled) .e-clear-icon:hover,.e-float-input.e-control-wrapper:not(.e-disabled) .e-clear-icon:hover,.e-input-group:not(.e-disabled) .e-clear-icon:hover,.e-input-group.e-control-wrapper:not(.e-disabled) .e-clear-icon:hover{background:none}@keyframes material-spinner-rotate{0%{transform:rotate(0)}to{transform:rotate(360deg)}}@keyframes fabric-spinner-rotate{0%{transform:rotate(0)}to{transform:rotate(360deg)}}.e-upload .e-upload-files .e-file-remove-btn.e-icons:before{content:"\e945"}.e-upload .e-upload-files .e-icons.e-file-pause-btn:before{content:"\e326"}.e-upload .e-upload-files .e-icons.e-file-reload-btn:before{content:"\e99d"}.e-upload .e-upload-files .e-icons.e-file-play-btn:before{content:"\e324"}.e-upload .e-upload-files .e-file-delete-btn.e-icons:before{content:"\e94a"}.e-upload .e-upload-files .e-file-abort-btn.e-icons:before{content:"\e974"}.e-upload .e-upload-files .e-icons.e-msie:before{position:relative;right:10px}.e-upload .e-upload-files .e-icons.e-file-abort-icon.e-msie:before{right:12px}.e-upload{width:100%}.e-upload.e-control-wrapper{font-family:Roboto,Segoe UI,GeezaPro,"DejaVu Serif","sans-serif",-apple-system,BlinkMacSystemFont}.e-upload .e-hidden-file-input{border:0;height:0;margin:0;outline:none;padding:0;text-indent:0;visibility:hidden;width:0}.e-upload .e-file-select-wrap{padding:16px 0 16px 12px}.e-upload .e-file-select-wrap .e-file-select,.e-upload .e-file-select-wrap .e-file-select .e-uploader{display:inline-block;width:0}.e-upload .e-file-select-wrap .e-file-select .e-uploader{opacity:0}.e-upload .e-file-select-wrap .e-file-drop{font-family:inherit;font-size:14px;margin-left:12px}.e-upload.e-form-upload .e-upload-files .e-upload-file-list{min-height:35px;padding-bottom:12px;padding-top:8px}.e-upload.e-form-upload .e-upload-files .e-upload-file-list .e-file-container{top:0}.e-upload.e-form-upload .e-upload-files .e-upload-file-list .e-file-container .e-hidden-input{display:none}.e-upload.e-form-upload .e-upload-files .e-upload-file-list .e-file-container .e-file-name,.e-upload.e-form-upload .e-upload-files .e-upload-file-list .e-file-container .e-file-type{line-height:1.5;padding-top:4px}.e-upload.e-form-upload .e-upload-files .e-upload-file-list .e-file-container .e-file-name.e-error,.e-upload.e-form-upload .e-upload-files .e-upload-file-list .e-file-container .e-file-type.e-error,.e-upload.e-form-upload .e-upload-files .e-upload-file-list .e-file-container .e-file-status.e-error{color:#f44336}.e-upload.e-form-upload .e-upload-files .e-upload-file-list .e-file-container .e-file-status,.e-upload.e-form-upload .e-upload-files .e-upload-file-list .e-file-container .e-file-information{color:#0000008a;display:block;font-size:11px;line-height:1.5;padding-bottom:0;padding-top:4px;position:relative}.e-upload.e-form-upload .e-upload-files .e-upload-file-list.e-file-invalid,.e-upload.e-form-upload .e-upload-files .e-upload-file-list.e-file-invalid .e-file-name,.e-upload.e-form-upload .e-upload-files .e-upload-file-list.e-file-invalid .e-file-type,.e-upload.e-form-upload .e-upload-files .e-upload-file-list.e-file-invalid .e-file-status{color:#f44336}.e-upload.e-form-upload .e-upload-files .e-file-remove-btn.e-icons,.e-upload.e-form-upload .e-upload-files .e-file-delete-btn.e-icons,.e-upload.e-form-upload .e-upload-files .e-file-abort-btn.e-icons,.e-upload.e-form-upload .e-upload-files .e-file-reload-btn.e-icons,.e-upload.e-form-upload .e-upload-files .e-file-play-btn.e-icons,.e-upload.e-form-upload .e-upload-files .e-file-pause-btn.e-icons{box-sizing:border-box;top:32px}.e-upload.e-form-upload .e-upload-files .e-file-remove-btn.e-icons.e-disabled,.e-upload.e-form-upload .e-upload-files .e-file-delete-btn.e-icons.e-disabled{color:#00000061;cursor:not-allowed;opacity:.4;pointer-events:none}.e-upload .e-upload-files{list-style-type:none;margin:0;padding:0}.e-upload .e-upload-files .e-icons:focus{outline:none}.e-upload .e-upload-files .e-upload-file-list{font-family:inherit;font-size:14px;height:100%;line-height:normal;min-height:90px;position:relative}.e-upload .e-upload-files .e-upload-file-list .e-file-container{display:block;height:100%;margin-left:12px;margin-right:90px;min-height:35px;position:relative;top:3px}.e-upload .e-upload-files .e-upload-file-list .e-file-container .e-file-name{float:left;font-family:inherit;font-size:14px;max-width:75%;overflow:hidden;padding-top:12px;position:relative;text-overflow:ellipsis;top:0;white-space:nowrap}.e-upload .e-upload-files .e-upload-file-list .e-file-container .e-file-name:before{content:attr(data-tail);float:right}.e-upload .e-upload-files .e-upload-file-list .e-file-container .e-file-type{display:block;font-family:inherit;font-size:14px;padding-top:12px}.e-upload .e-upload-files .e-upload-file-list .e-file-container .e-file-type.e-hidden{visibility:hidden}.e-upload .e-upload-files .e-upload-file-list .e-file-container .e-file-size{display:block;font-size:11px;padding:8px 0}.e-upload .e-upload-files .e-upload-file-list .e-file-container .e-file-status,.e-upload .e-upload-files .e-upload-file-list .e-file-container .e-file-information{display:block;font-family:inherit;font-size:11px;padding-bottom:12px}.e-upload .e-upload-files .e-upload-file-list .e-file-container .e-file-status.e-upload-progress,.e-upload .e-upload-files .e-upload-file-list .e-file-container .e-file-information.e-upload-progress{display:none}.e-upload .e-upload-files .e-upload-file-list .e-file-container .e-upload-progress-wrap{display:block;height:8px;padding-bottom:6px;padding-top:6px;position:absolute;width:98%}.e-upload .e-upload-files .e-upload-file-list .e-file-container .e-upload-progress-wrap .e-progress-inner-wrap{border-radius:0;display:block;height:2px;width:100%}.e-upload .e-upload-files .e-upload-file-list .e-file-container .e-upload-progress-wrap .e-progress-inner-wrap .e-upload-progress-bar{border-radius:0;display:inherit;height:2px}.e-upload .e-upload-files .e-upload-file-list .e-file-container .e-upload-progress-wrap .e-progress-bar-text{float:right;font-family:inherit;font-size:11px;position:relative;right:6px;top:-27px}.e-upload .e-upload-files .e-file-remove-btn.e-icons,.e-upload .e-upload-files .e-file-delete-btn.e-icons,.e-upload .e-upload-files .e-file-abort-btn.e-icons,.e-upload .e-upload-files .e-file-pause-btn.e-icons,.e-upload .e-upload-files .e-file-play-btn.e-icons,.e-upload .e-upload-files .e-file-reload-btn.e-icons{align-items:center;box-sizing:border-box;cursor:pointer;display:inline-flex;font-size:11px;height:18px;justify-content:center;margin:-18px 12px 0;padding:18px;position:absolute;right:0;top:50%;vertical-align:middle;width:18px}.e-upload .e-upload-files .e-file-remove-btn.e-icons.e-upload-progress,.e-upload .e-upload-files .e-file-delete-btn.e-icons.e-upload-progress,.e-upload .e-upload-files .e-file-abort-btn.e-icons.e-upload-progress,.e-upload .e-upload-files .e-file-pause-btn.e-icons.e-upload-progress,.e-upload .e-upload-files .e-file-play-btn.e-icons.e-upload-progress,.e-upload .e-upload-files .e-file-reload-btn.e-icons.e-upload-progress{cursor:default}.e-upload .e-upload-files .e-file-remove-btn.e-icons.e-disabled,.e-upload .e-upload-files .e-file-delete-btn.e-icons.e-disabled{color:#00000061;cursor:not-allowed;opacity:.4;pointer-events:none}.e-upload .e-upload-files .e-file-remove-btn.e-msie.e-icons,.e-upload .e-upload-files .e-file-delete-btn.e-msie.e-icons,.e-upload .e-upload-files .e-file-abort-btn.e-msie.e-icons,.e-upload .e-upload-files .e-file-pause-btn.e-msie.e-icons,.e-upload .e-upload-files .e-file-play-btn.e-msie.e-icons,.e-upload .e-upload-files .e-file-reload-btn.e-msie.e-icons{padding:18px 13px 18px 23px}.e-upload .e-upload-files .e-file-pause-btn.e-icons,.e-upload .e-upload-files .e-file-play-btn.e-icons,.e-upload .e-upload-files .e-file-reload-btn.e-icons{right:36px}.e-upload .e-upload-files .e-file-remove-btn.e-icons:not(.e-upload-progress):hover,.e-upload .e-upload-files .e-file-delete-btn.e-icons:not(.e-upload-progress):hover,.e-upload .e-upload-files .e-file-pause-btn.e-icons:not(.e-upload-progress):hover,.e-upload .e-upload-files .e-file-play-btn.e-icons:not(.e-upload-progress):hover,.e-upload .e-upload-files .e-file-reload-btn.e-icons:hover,.e-upload .e-upload-files .e-file-abort-btn.e-icons:not(.e-disabled):hover,.e-upload .e-upload-files .e-clear-icon-focus{background-color:#0000001f;border-color:transparent;border-radius:50%;box-shadow:0 0 0 transparent}.e-upload .e-upload-files .e-file-remove-btn.e-icons:not(.e-upload-progress):focus,.e-upload .e-upload-files .e-file-delete-btn.e-icons:not(.e-upload-progress):focus,.e-upload .e-upload-files .e-file-pause-btn.e-icons:not(.e-upload-progress):focus,.e-upload .e-upload-files .e-file-play-btn.e-icons:not(.e-upload-progress):focus,.e-upload .e-upload-files .e-file-reload-btn.e-icons:focus,.e-upload .e-upload-files .e-file-abort-btn.e-icons:not(.e-disabled):focus,.e-upload .e-upload-files .e-clear-icon-focus{border-radius:50%}.e-upload .e-upload-files .e-file-delete-btn.e-icons{font-size:11px;opacity:1}.e-upload .e-upload-files .e-file-abort-btn.e-icons{font-size:15px;opacity:1}.e-upload .e-file-select-wrap .e-btn,.e-upload .e-upload-actions .e-btn{font-family:inherit}.e-upload .e-upload-actions{position:relative;text-align:right}.e-upload .e-upload-actions .e-file-upload-btn,.e-upload .e-upload-actions .e-file-clear-btn{margin:12px}.e-upload.e-rtl .e-file-select-wrap{padding:16px 12px 16px 0}.e-upload.e-rtl .e-file-select-wrap .e-control.e-btn{margin-right:10px}.e-upload.e-rtl .e-file-select-wrap .e-file-drop{margin-left:60px;margin-right:12px;position:relative}.e-upload.e-rtl .e-upload-actions{text-align:left}.e-upload.e-rtl .e-upload-files .e-upload-file-list .e-file-container{height:100%;margin-left:60px;margin-right:12px;position:relative}.e-upload.e-rtl .e-upload-files .e-upload-file-list .e-file-container .e-rtl-container{direction:ltr;float:right;width:100%}.e-upload.e-rtl .e-upload-files .e-upload-file-list .e-file-container .e-file-type,.e-upload.e-rtl .e-upload-files .e-upload-file-list .e-file-container .e-file-name{float:right}.e-upload.e-rtl .e-upload-files .e-upload-file-list .e-file-container .e-file-size{direction:ltr;float:right;position:relative;text-align:right;width:100%}.e-upload.e-rtl .e-upload-files .e-upload-file-list .e-file-container .e-upload-progress-wrap{float:right;position:initial;top:46px;width:89%}.e-upload.e-rtl .e-upload-files .e-upload-file-list .e-file-container .e-upload-progress-wrap .e-progress-bar-text{float:left;right:-8px;top:-25px}.e-upload.e-rtl .e-upload-files .e-upload-file-list .e-file-remove-btn.e-icons,.e-upload.e-rtl .e-upload-files .e-upload-file-list .e-file-delete-btn.e-icons,.e-upload.e-rtl .e-upload-files .e-upload-file-list .e-file-abort-btn.e-icons,.e-upload.e-rtl .e-upload-files .e-upload-file-list .e-file-reload-btn.e-icons,.e-upload.e-rtl .e-upload-files .e-upload-file-list .e-file-pause-btn.e-icons,.e-upload.e-rtl .e-upload-files .e-upload-file-list .e-file-play-btn.e-icons{left:0;margin-left:12px;margin-right:12px;right:auto;top:50%}.e-upload.e-rtl .e-upload-files .e-upload-file-list .e-file-reload-btn.e-icons{left:36px;right:auto}.e-upload.e-rtl .e-upload-files .e-upload-file-list .e-file-play-btn.e-icons,.e-upload.e-rtl .e-upload-files .e-upload-file-list .e-file-reload-btn.e-icons,.e-upload.e-rtl .e-upload-files .e-upload-file-list .e-file-pause-btn.e-icons{left:36px}.e-upload.e-disabled .e-file-drop,.e-upload.e-disabled .e-upload-files .e-upload-file-list .e-file-container .e-file-name,.e-upload.e-disabled .e-upload-files .e-upload-file-list .e-file-container .e-file-type,.e-upload.e-disabled .e-upload-files .e-upload-file-list .e-file-container .e-file-size,.e-upload.e-disabled .e-upload-files .e-upload-file-list .e-file-container .e-file-status,.e-upload.e-disabled .e-upload-files .e-upload-file-list .e-file-container .e-file-information{color:#00000061}.e-upload .e-content-placeholder.e-upload.e-placeholder-upload{background-size:400px 65px;min-height:65px}.e-small .e-upload .e-file-select-wrap{padding:16px 0 16px 12px}.e-small .e-upload .e-file-select-wrap .e-file-drop{font-size:13px;margin-left:12px}.e-small .e-upload .e-upload-files .e-upload-file-list{min-height:76px}.e-small .e-upload .e-upload-files .e-upload-file-list .e-file-container .e-file-name{font-size:12px;padding-top:10px}.e-small .e-upload .e-upload-files .e-upload-file-list .e-file-container .e-file-size{font-size:11px;padding:5px 0}.e-small .e-upload .e-upload-files .e-upload-file-list .e-file-container .e-file-type{font-size:12px;padding-top:10px}.e-small .e-upload .e-upload-files .e-upload-file-list .e-file-container .e-file-status,.e-small .e-upload .e-upload-files .e-upload-file-list .e-file-container .e-file-information{padding-bottom:10px}.e-small .e-upload .e-upload-files .e-upload-file-list .e-file-container .e-upload-progress-wrap{padding-bottom:3px;padding-top:3px}.e-small .e-upload .e-upload-files .e-file-remove-btn.e-icons,.e-small .e-upload .e-upload-files .e-file-delete-btn.e-icons,.e-small .e-upload .e-upload-files .e-file-abort-btn.e-icons,.e-small .e-upload .e-upload-files .e-file-reload-btn.e-icons,.e-small .e-upload .e-upload-files .e-file-play-btn.e-icons,.e-small .e-upload .e-upload-files .e-file-pause-btn.e-icons{font-size:10px;height:24px;padding:12px;width:24px}.e-small .e-upload .e-upload-files .e-file-remove-btn.e-icons.e-disabled,.e-small .e-upload .e-upload-files .e-file-delete-btn.e-icons.e-disabled{color:#00000061;cursor:not-allowed;opacity:.4;pointer-events:none}.e-small .e-upload.e-rtl .e-file-select-wrap{padding:16px 12px 16px 0}.e-small .e-upload.e-form-upload .e-upload-files .e-upload-file-list{min-height:35px;padding-bottom:10px;padding-top:6px}.e-small .e-upload.e-form-upload .e-upload-files .e-upload-file-list .e-file-container{top:0}.e-small .e-upload.e-form-upload .e-upload-files .e-upload-file-list .e-file-container .e-hidden-input{display:none}.e-small .e-upload.e-form-upload .e-upload-files .e-upload-file-list .e-file-container .e-file-name,.e-small .e-upload.e-form-upload .e-upload-files .e-upload-file-list .e-file-container .e-file-type{line-height:1.5;padding-top:4px}.e-small .e-upload.e-form-upload .e-upload-files .e-upload-file-list .e-file-container .e-file-name.e-error,.e-small .e-upload.e-form-upload .e-upload-files .e-upload-file-list .e-file-container .e-file-type.e-error,.e-small .e-upload.e-form-upload .e-upload-files .e-upload-file-list .e-file-container .e-file-status.e-error{color:#f44336}.e-small .e-upload.e-form-upload .e-upload-files .e-upload-file-list .e-file-container .e-file-status,.e-small .e-upload.e-form-upload .e-upload-files .e-upload-file-list .e-file-container .e-file-information{color:#0000008a;display:block;font-size:11px;line-height:1.5;padding-bottom:0;padding-top:4px;position:relative}.e-small .e-upload.e-form-upload .e-upload-files .e-upload-file-list.e-file-invalid,.e-small .e-upload.e-form-upload .e-upload-files .e-upload-file-list.e-file-invalid .e-file-name,.e-small .e-upload.e-form-upload .e-upload-files .e-upload-file-list.e-file-invalid .e-file-type,.e-small .e-upload.e-form-upload .e-upload-files .e-upload-file-list.e-file-invalid .e-file-status{color:#f44336}.e-small .e-upload.e-form-upload .e-upload-files .e-file-remove-btn.e-icons,.e-small .e-upload.e-form-upload .e-upload-files .e-file-delete-btn.e-icons,.e-small .e-upload.e-form-upload .e-upload-files .e-file-abort-btn.e-icons,.e-small .e-upload.e-form-upload .e-upload-files .e-file-reload-btn.e-icons,.e-small .e-upload.e-form-upload .e-upload-files .e-file-play-btn.e-icons,.e-small .e-upload.e-form-upload .e-upload-files .e-file-pause-btn.e-icons{box-sizing:border-box;top:34px}.e-small .e-upload.e-form-upload .e-upload-files .e-file-remove-btn.e-icons.e-disabled,.e-small .e-upload.e-form-upload .e-upload-files .e-file-delete-btn.e-icons.e-disabled{color:#00000061;cursor:not-allowed;opacity:.4;pointer-events:none}.e-upload{border:1px solid rgba(0,0,0,.12)}.e-upload .e-file-drop{color:#000000de;vertical-align:middle}.e-upload .e-upload-files{border-top:1px solid rgba(0,0,0,.12)}.e-upload .e-upload-files .e-upload-file-list{border-bottom:1px solid rgba(0,0,0,.12)}.e-upload .e-upload-files .e-upload-file-list .e-file-container .e-file-name,.e-upload .e-upload-files .e-upload-file-list .e-file-container .e-file-type{color:#000000de}.e-upload .e-upload-files .e-upload-file-list .e-file-container .e-file-size{color:#0000008a}.e-upload .e-upload-files .e-upload-file-list .e-file-container .e-file-status,.e-upload .e-upload-files .e-upload-file-list .e-file-container .e-file-information{color:#000000de}.e-upload .e-upload-files .e-upload-file-list .e-file-container .e-file-status.e-upload-success{color:#22b24b}.e-upload .e-upload-files .e-upload-file-list .e-file-container .e-file-status.e-upload-fails,.e-upload .e-upload-files .e-upload-file-list .e-file-container .e-file-status.e-validation-fails{color:#f44336}.e-upload .e-upload-files .e-upload-file-list .e-file-container .e-progress-inner-wrap{background-color:#e0e0e0}.e-upload .e-upload-files .e-upload-file-list .e-file-container .e-progress-inner-wrap .e-upload-progress-bar.e-upload-progress{background:#e3165b}.e-upload .e-upload-files .e-upload-file-list .e-file-container .e-progress-inner-wrap .e-upload-progress-bar.e-upload-success{background:#22b24b}.e-upload .e-upload-files .e-upload-file-list .e-file-container .e-progress-inner-wrap .e-upload-progress-bar.e-upload-failed{background:#f44336}.e-upload .e-upload-files .e-upload-file-list .e-file-container .e-progress-bar-text{color:#000000de}.e-upload .e-upload-files .e-file-remove-btn.e-icons,.e-upload .e-upload-files .e-file-delete-btn.e-icons,.e-upload .e-upload-files .e-file-reload-btn.e-icons,.e-upload .e-upload-files .e-file-abort-btn.e-icons,.e-upload .e-upload-files .e-file-pause-btn.e-icons,.e-upload .e-upload-files .e-file-play-btn.e-icons,.e-upload .e-upload-files .e-file-remove-btn.e-icons:hover,.e-upload .e-upload-files .e-file-delete-btn.e-icons:hover,.e-upload .e-upload-files .e-file-reload-btn.e-icons:hover,.e-upload .e-upload-files .e-file-abort-btn.e-icons:hover,.e-upload .e-upload-files .e-file-pause-btn.e-icons:hover,.e-upload .e-upload-files .e-file-play-btn.e-icons:hover{color:#000}.e-upload .e-upload-files .e-file-remove-btn.e-icons:not(.e-upload-progress):focus,.e-upload .e-upload-files .e-file-delete-btn.e-icons:not(.e-upload-progress):focus,.e-upload .e-upload-files .e-file-pause-btn.e-icons:not(.e-upload-progress):focus,.e-upload .e-upload-files .e-file-play-btn.e-icons:not(.e-upload-progress):focus,.e-upload .e-upload-files .e-file-reload-btn.e-icons:focus,.e-upload .e-upload-files .e-file-abort-btn.e-icons:not(.e-disabled):focus,.e-upload .e-upload-files .e-clear-icon-focus{background-color:#0000001f;border-color:transparent;box-shadow:0 0 0 transparent}.e-bigger .e-upload{width:100%}.e-bigger .e-upload .e-file-select-wrap{padding:20px 0 20px 16px}.e-bigger .e-upload .e-file-select-wrap .e-file-drop{font-size:15px;margin-left:16px}.e-bigger .e-upload .e-upload-files .e-upload-file-list{font-size:15px;line-height:normal;min-height:100px}.e-bigger .e-upload .e-upload-files .e-upload-file-list .e-file-container{margin-left:16px;top:0}.e-bigger .e-upload .e-upload-files .e-upload-file-list .e-file-container .e-file-name{font-size:15px;padding-top:16px}.e-bigger .e-upload .e-upload-files .e-upload-file-list .e-file-container .e-file-size{font-size:12px;padding:10px 0}.e-bigger .e-upload .e-upload-files .e-upload-file-list .e-file-container .e-file-type{font-size:15px;padding-top:16px;top:initial}.e-bigger .e-upload .e-upload-files .e-upload-file-list .e-file-container .e-file-status,.e-bigger .e-upload .e-upload-files .e-upload-file-list .e-file-container .e-file-information{font-size:12px;padding-bottom:16px}.e-bigger .e-upload .e-upload-files .e-upload-file-list .e-file-container .e-upload-progress-wrap{height:10px}.e-bigger .e-upload .e-upload-files .e-upload-file-list .e-file-container .e-upload-progress-wrap .e-progress-inner-wrap{height:3px;width:98%}.e-bigger .e-upload .e-upload-files .e-upload-file-list .e-file-container .e-upload-progress-wrap .e-progress-inner-wrap .e-upload-progress-bar{height:3px}.e-bigger .e-upload .e-upload-files .e-upload-file-list .e-file-container .e-upload-progress-wrap .e-progress-bar-text{font-size:11px;right:10px;top:-33px}.e-bigger .e-upload .e-upload-files .e-file-remove-btn.e-icons,.e-bigger .e-upload .e-upload-files .e-file-delete-btn.e-icons,.e-bigger .e-upload .e-upload-files .e-file-abort-btn.e-icons,.e-bigger .e-upload .e-upload-files .e-file-reload-btn.e-icons,.e-bigger .e-upload .e-upload-files .e-file-play-btn.e-icons,.e-bigger .e-upload .e-upload-files .e-file-pause-btn.e-icons{box-sizing:border-box;font-size:12px;height:18px;margin:-24px 16px 16px;padding:20px;top:50%;width:18px}.e-bigger .e-upload .e-upload-files .e-file-remove-btn.e-icons.e-disabled,.e-bigger .e-upload .e-upload-files .e-file-delete-btn.e-icons.e-disabled{color:#00000061;cursor:not-allowed;opacity:.4;pointer-events:none}.e-bigger .e-upload .e-upload-files .e-file-remove-btn.e-msie.e-icons,.e-bigger .e-upload .e-upload-files .e-file-delete-btn.e-msie.e-icons,.e-bigger .e-upload .e-upload-files .e-file-abort-btn.e-msie.e-icons,.e-bigger .e-upload .e-upload-files .e-file-reload-btn.e-msie.e-icons,.e-bigger .e-upload .e-upload-files .e-file-play-btn.e-msie.e-icons,.e-bigger .e-upload .e-upload-files .e-file-pause-btn.e-msie.e-icons{padding:20px 17px 20px 26px}.e-bigger .e-upload .e-upload-files .e-file-play-btn.e-icons,.e-bigger .e-upload .e-upload-files .e-file-reload-btn.e-icons,.e-bigger .e-upload .e-upload-files .e-file-pause-btn.e-icons{right:45px}.e-bigger .e-upload .e-upload-files .e-file-delete-btn.e-icons{font-size:13px}.e-bigger .e-upload .e-upload-files .e-file-abort-btn.e-icons{font-size:18px}.e-bigger .e-upload .e-upload-actions .e-btn{margin-left:16px}.e-bigger .e-upload .e-upload-actions .e-file-upload-btn,.e-bigger .e-upload .e-upload-actions .e-file-clear-btn{margin:15px}.e-bigger .e-upload.e-rtl .e-file-select-wrap{padding:20px 16px 20px 0}.e-bigger .e-upload.e-rtl .e-file-select-wrap .e-control.e-btn{margin-right:0}.e-bigger .e-upload.e-rtl .e-file-select-wrap .e-file-drop{margin-right:16px}.e-bigger .e-upload.e-rtl .e-upload-files .e-upload-file-list .e-file-container{margin-left:60px;margin-right:16px}.e-bigger .e-upload.e-rtl .e-upload-files .e-upload-file-list .e-file-container .e-file-status,.e-bigger .e-upload.e-rtl .e-upload-files .e-upload-file-list .e-file-container .e-file-information{top:54px}.e-bigger .e-upload.e-rtl .e-upload-files .e-upload-file-list .e-file-container .e-upload-progress-wrap .e-progress-bar-text{left:10px;right:initial}.e-bigger .e-upload.e-rtl .e-upload-files .e-upload-file-list .e-file-remove-btn.e-icons,.e-bigger .e-upload.e-rtl .e-upload-files .e-upload-file-list .e-file-delete-btn.e-icons,.e-bigger .e-upload.e-rtl .e-upload-files .e-upload-file-list .e-file-abort-btn.e-icons,.e-bigger .e-upload.e-rtl .e-upload-files .e-upload-file-list .e-file-reload-btn.e-icons,.e-bigger .e-upload.e-rtl .e-upload-files .e-upload-file-list .e-file-play-btn.e-icons,.e-bigger .e-upload.e-rtl .e-upload-files .e-upload-file-list .e-file-pause-btn.e-icons{box-sizing:border-box;left:0;margin-left:16px;margin-right:16px;padding:20px;top:50%}.e-bigger .e-upload.e-rtl .e-upload-files .e-upload-file-list .e-file-remove-btn.e-icons.e-disabled,.e-bigger .e-upload.e-rtl .e-upload-files .e-upload-file-list .e-file-delete-btn.e-icons.e-disabled{color:#00000061;cursor:not-allowed;opacity:.4;pointer-events:none}.e-bigger .e-upload.e-rtl .e-upload-files .e-upload-file-list .e-file-remove-btn.e-msie.e-icons,.e-bigger .e-upload.e-rtl .e-upload-files .e-upload-file-list .e-file-delete-btn.e-msie.e-icons,.e-bigger .e-upload.e-rtl .e-upload-files .e-upload-file-list .e-file-abort-btn.e-msie.e-icons,.e-bigger .e-upload.e-rtl .e-upload-files .e-upload-file-list .e-file-reload-btn.e-msie.e-icons,.e-bigger .e-upload.e-rtl .e-upload-files .e-upload-file-list .e-file-play-btn.e-msie.e-icons,.e-bigger .e-upload.e-rtl .e-upload-files .e-upload-file-list .e-file-pause-btn.e-msie.e-icons{padding:20px 17px 20px 26px}.e-bigger .e-upload.e-rtl .e-upload-files .e-upload-file-list .e-file-play-btn.e-icons,.e-bigger .e-upload.e-rtl .e-upload-files .e-upload-file-list .e-file-reload-btn.e-icons,.e-bigger .e-upload.e-rtl .e-upload-files .e-upload-file-list .e-file-pause-btn.e-icons{left:41px}.e-bigger .e-upload.e-form-upload .e-upload-files .e-upload-file-list{min-height:35px;padding-bottom:16px;padding-top:12px}.e-bigger .e-upload.e-form-upload .e-upload-files .e-upload-file-list .e-file-container{top:0}.e-bigger .e-upload.e-form-upload .e-upload-files .e-upload-file-list .e-file-container .e-hidden-input{display:none}.e-bigger .e-upload.e-form-upload .e-upload-files .e-upload-file-list .e-file-container .e-file-name,.e-bigger .e-upload.e-form-upload .e-upload-files .e-upload-file-list .e-file-container .e-file-type{line-height:1.5;padding-top:4px}.e-bigger .e-upload.e-form-upload .e-upload-files .e-upload-file-list .e-file-container .e-file-name.e-error,.e-bigger .e-upload.e-form-upload .e-upload-files .e-upload-file-list .e-file-container .e-file-type.e-error,.e-bigger .e-upload.e-form-upload .e-upload-files .e-upload-file-list .e-file-container .e-file-status.e-error{color:#f44336}.e-bigger .e-upload.e-form-upload .e-upload-files .e-upload-file-list .e-file-container .e-file-status,.e-bigger .e-upload.e-form-upload .e-upload-files .e-upload-file-list .e-file-container .e-file-information{color:#0000008a;display:block;font-size:12px;line-height:1.5;padding-bottom:0;padding-top:4px;position:relative}.e-bigger .e-upload.e-form-upload .e-upload-files .e-upload-file-list.e-file-invalid,.e-bigger .e-upload.e-form-upload .e-upload-files .e-upload-file-list.e-file-invalid .e-file-name,.e-bigger .e-upload.e-form-upload .e-upload-files .e-upload-file-list.e-file-invalid .e-file-type,.e-bigger .e-upload.e-form-upload .e-upload-files .e-upload-file-list.e-file-invalid .e-file-status{color:#f44336}.e-bigger .e-upload.e-form-upload .e-upload-files .e-file-remove-btn.e-icons,.e-bigger .e-upload.e-form-upload .e-upload-files .e-file-delete-btn.e-icons,.e-bigger .e-upload.e-form-upload .e-upload-files .e-file-abort-btn.e-icons,.e-bigger .e-upload.e-form-upload .e-upload-files .e-file-reload-btn.e-icons,.e-bigger .e-upload.e-form-upload .e-upload-files .e-file-play-btn.e-icons,.e-bigger .e-upload.e-form-upload .e-upload-files .e-file-pause-btn.e-icons{box-sizing:border-box;top:42px}.e-bigger .e-upload.e-form-upload .e-upload-files .e-file-remove-btn.e-icons.e-disabled,.e-bigger .e-upload.e-form-upload .e-upload-files .e-file-delete-btn.e-icons.e-disabled{color:#00000061;cursor:not-allowed;opacity:.4;pointer-events:none}.e-bigger.e-small .e-upload{width:100%}.e-bigger.e-small .e-upload.e-control-wrapper{font-family:Roboto,Segoe UI,GeezaPro,"DejaVu Serif","sans-serif",-apple-system,BlinkMacSystemFont}.e-bigger.e-small .e-upload .e-hidden-file-input{border:0;height:0;margin:0;outline:none;padding:0;text-indent:0;visibility:hidden;width:0}.e-bigger.e-small .e-upload .e-file-select-wrap{padding:16px 0 16px 12px}.e-bigger.e-small .e-upload .e-file-select-wrap .e-file-select,.e-bigger.e-small .e-upload .e-file-select-wrap .e-file-select .e-uploader{display:inline-block;width:0}.e-bigger.e-small .e-upload .e-file-select-wrap .e-file-select .e-uploader{opacity:0}.e-bigger.e-small .e-upload .e-file-select-wrap .e-file-drop{font-family:inherit;font-size:14px;margin-left:12px}.e-bigger.e-small .e-upload.e-form-upload .e-upload-files .e-upload-file-list{min-height:35px;padding-bottom:12px;padding-top:8px}.e-bigger.e-small .e-upload.e-form-upload .e-upload-files .e-upload-file-list .e-file-container{top:0}.e-bigger.e-small .e-upload.e-form-upload .e-upload-files .e-upload-file-list .e-file-container .e-hidden-input{display:none}.e-bigger.e-small .e-upload.e-form-upload .e-upload-files .e-upload-file-list .e-file-container .e-file-name,.e-bigger.e-small .e-upload.e-form-upload .e-upload-files .e-upload-file-list .e-file-container .e-file-type{line-height:1.5;padding-top:4px}.e-bigger.e-small .e-upload.e-form-upload .e-upload-files .e-upload-file-list .e-file-container .e-file-name.e-error,.e-bigger.e-small .e-upload.e-form-upload .e-upload-files .e-upload-file-list .e-file-container .e-file-type.e-error,.e-bigger.e-small .e-upload.e-form-upload .e-upload-files .e-upload-file-list .e-file-container .e-file-status.e-error{color:#f44336}.e-bigger.e-small .e-upload.e-form-upload .e-upload-files .e-upload-file-list .e-file-container .e-file-status,.e-bigger.e-small .e-upload.e-form-upload .e-upload-files .e-upload-file-list .e-file-container .e-file-information{color:#0000008a;display:block;font-size:11px;line-height:1.5;padding-bottom:0;padding-top:4px;position:relative}.e-bigger.e-small .e-upload.e-form-upload .e-upload-files .e-upload-file-list.e-file-invalid,.e-bigger.e-small .e-upload.e-form-upload .e-upload-files .e-upload-file-list.e-file-invalid .e-file-name,.e-bigger.e-small .e-upload.e-form-upload .e-upload-files .e-upload-file-list.e-file-invalid .e-file-type,.e-bigger.e-small .e-upload.e-form-upload .e-upload-files .e-upload-file-list.e-file-invalid .e-file-status{color:#f44336}.e-bigger.e-small .e-upload.e-form-upload .e-upload-files .e-file-remove-btn.e-icons,.e-bigger.e-small .e-upload.e-form-upload .e-upload-files .e-file-delete-btn.e-icons,.e-bigger.e-small .e-upload.e-form-upload .e-upload-files .e-file-abort-btn.e-icons,.e-bigger.e-small .e-upload.e-form-upload .e-upload-files .e-file-reload-btn.e-icons,.e-bigger.e-small .e-upload.e-form-upload .e-upload-files .e-file-play-btn.e-icons,.e-bigger.e-small .e-upload.e-form-upload .e-upload-files .e-file-pause-btn.e-icons{box-sizing:border-box;top:32px}.e-bigger.e-small .e-upload.e-form-upload .e-upload-files .e-file-remove-btn.e-icons.e-disabled,.e-bigger.e-small .e-upload.e-form-upload .e-upload-files .e-file-delete-btn.e-icons.e-disabled{color:#00000061;cursor:not-allowed;opacity:.4;pointer-events:none}.e-bigger.e-small .e-upload .e-upload-files{list-style-type:none;margin:0;padding:0}.e-bigger.e-small .e-upload .e-upload-files .e-icons:focus{outline:none}.e-bigger.e-small .e-upload .e-upload-files .e-upload-file-list{font-family:inherit;font-size:14px;height:100%;line-height:normal;min-height:90px;position:relative}.e-bigger.e-small .e-upload .e-upload-files .e-upload-file-list .e-file-container{display:block;height:100%;margin-left:12px;margin-right:90px;min-height:35px;position:relative;top:3px}.e-bigger.e-small .e-upload .e-upload-files .e-upload-file-list .e-file-container .e-file-name{float:left;font-family:inherit;font-size:14px;max-width:75%;overflow:hidden;padding-top:12px;position:relative;text-overflow:ellipsis;top:0;white-space:nowrap}.e-bigger.e-small .e-upload .e-upload-files .e-upload-file-list .e-file-container .e-file-name:before{content:attr(data-tail);float:right}.e-bigger.e-small .e-upload .e-upload-files .e-upload-file-list .e-file-container .e-file-type{display:block;font-family:inherit;font-size:14px;padding-top:12px}.e-bigger.e-small .e-upload .e-upload-files .e-upload-file-list .e-file-container .e-file-type.e-hidden{visibility:hidden}.e-bigger.e-small .e-upload .e-upload-files .e-upload-file-list .e-file-container .e-file-size{display:block;font-size:11px;padding:8px 0}.e-bigger.e-small .e-upload .e-upload-files .e-upload-file-list .e-file-container .e-file-status,.e-bigger.e-small .e-upload .e-upload-files .e-upload-file-list .e-file-container .e-file-information{display:block;font-family:inherit;font-size:11px;padding-bottom:12px}.e-bigger.e-small .e-upload .e-upload-files .e-upload-file-list .e-file-container .e-file-status.e-upload-progress,.e-bigger.e-small .e-upload .e-upload-files .e-upload-file-list .e-file-container .e-file-information.e-upload-progress{display:none}.e-bigger.e-small .e-upload .e-upload-files .e-upload-file-list .e-file-container .e-upload-progress-wrap{display:block;height:8px;padding-bottom:6px;padding-top:6px;position:absolute;width:98%}.e-bigger.e-small .e-upload .e-upload-files .e-upload-file-list .e-file-container .e-upload-progress-wrap .e-progress-inner-wrap{border-radius:0;display:block;height:2px;width:100%}.e-bigger.e-small .e-upload .e-upload-files .e-upload-file-list .e-file-container .e-upload-progress-wrap .e-progress-inner-wrap .e-upload-progress-bar{border-radius:0;display:inherit;height:2px}.e-bigger.e-small .e-upload .e-upload-files .e-upload-file-list .e-file-container .e-upload-progress-wrap .e-progress-bar-text{float:right;font-family:inherit;font-size:11px;position:relative;right:6px;top:-27px}.e-bigger.e-small .e-upload .e-upload-files .e-file-remove-btn.e-icons,.e-bigger.e-small .e-upload .e-upload-files .e-file-delete-btn.e-icons,.e-bigger.e-small .e-upload .e-upload-files .e-file-abort-btn.e-icons,.e-bigger.e-small .e-upload .e-upload-files .e-file-pause-btn.e-icons,.e-bigger.e-small .e-upload .e-upload-files .e-file-play-btn.e-icons,.e-bigger.e-small .e-upload .e-upload-files .e-file-reload-btn.e-icons{align-items:center;box-sizing:border-box;cursor:pointer;display:inline-flex;font-size:11px;height:18px;justify-content:center;margin:-18px 12px 0;padding:18px;position:absolute;right:0;top:50%;vertical-align:middle;width:18px}.e-bigger.e-small .e-upload .e-upload-files .e-file-remove-btn.e-icons.e-upload-progress,.e-bigger.e-small .e-upload .e-upload-files .e-file-delete-btn.e-icons.e-upload-progress,.e-bigger.e-small .e-upload .e-upload-files .e-file-abort-btn.e-icons.e-upload-progress,.e-bigger.e-small .e-upload .e-upload-files .e-file-pause-btn.e-icons.e-upload-progress,.e-bigger.e-small .e-upload .e-upload-files .e-file-play-btn.e-icons.e-upload-progress,.e-bigger.e-small .e-upload .e-upload-files .e-file-reload-btn.e-icons.e-upload-progress{cursor:default}.e-bigger.e-small .e-upload .e-upload-files .e-file-remove-btn.e-icons.e-disabled,.e-bigger.e-small .e-upload .e-upload-files .e-file-delete-btn.e-icons.e-disabled{color:#00000061;cursor:not-allowed;opacity:.4;pointer-events:none}.e-bigger.e-small .e-upload .e-upload-files .e-file-remove-btn.e-msie.e-icons,.e-bigger.e-small .e-upload .e-upload-files .e-file-delete-btn.e-msie.e-icons,.e-bigger.e-small .e-upload .e-upload-files .e-file-abort-btn.e-msie.e-icons,.e-bigger.e-small .e-upload .e-upload-files .e-file-pause-btn.e-msie.e-icons,.e-bigger.e-small .e-upload .e-upload-files .e-file-play-btn.e-msie.e-icons,.e-bigger.e-small .e-upload .e-upload-files .e-file-reload-btn.e-msie.e-icons{padding:18px 13px 18px 23px}.e-bigger.e-small .e-upload .e-upload-files .e-file-pause-btn.e-icons,.e-bigger.e-small .e-upload .e-upload-files .e-file-play-btn.e-icons,.e-bigger.e-small .e-upload .e-upload-files .e-file-reload-btn.e-icons{right:36px}.e-bigger.e-small .e-upload .e-upload-files .e-file-remove-btn.e-icons:not(.e-upload-progress):hover,.e-bigger.e-small .e-upload .e-upload-files .e-file-delete-btn.e-icons:not(.e-upload-progress):hover,.e-bigger.e-small .e-upload .e-upload-files .e-file-pause-btn.e-icons:not(.e-upload-progress):hover,.e-bigger.e-small .e-upload .e-upload-files .e-file-play-btn.e-icons:not(.e-upload-progress):hover,.e-bigger.e-small .e-upload .e-upload-files .e-file-reload-btn.e-icons:hover,.e-bigger.e-small .e-upload .e-upload-files .e-file-abort-btn.e-icons:not(.e-disabled):hover,.e-bigger.e-small .e-upload .e-upload-files .e-clear-icon-focus{background-color:#0000001f;border-color:transparent;border-radius:50%;box-shadow:0 0 0 transparent}.e-bigger.e-small .e-upload .e-upload-files .e-file-remove-btn.e-icons:not(.e-upload-progress):focus,.e-bigger.e-small .e-upload .e-upload-files .e-file-delete-btn.e-icons:not(.e-upload-progress):focus,.e-bigger.e-small .e-upload .e-upload-files .e-file-pause-btn.e-icons:not(.e-upload-progress):focus,.e-bigger.e-small .e-upload .e-upload-files .e-file-play-btn.e-icons:not(.e-upload-progress):focus,.e-bigger.e-small .e-upload .e-upload-files .e-file-reload-btn.e-icons:focus,.e-bigger.e-small .e-upload .e-upload-files .e-file-abort-btn.e-icons:not(.e-disabled):focus,.e-bigger.e-small .e-upload .e-upload-files .e-clear-icon-focus{border-radius:50%}.e-bigger.e-small .e-upload .e-upload-files .e-file-delete-btn.e-icons{font-size:11px;opacity:1}.e-bigger.e-small .e-upload .e-upload-files .e-file-abort-btn.e-icons{font-size:15px;opacity:1}.e-bigger.e-small .e-upload .e-file-select-wrap .e-btn,.e-bigger.e-small .e-upload .e-upload-actions .e-btn{font-family:inherit}.e-bigger.e-small .e-upload .e-upload-actions{position:relative;text-align:right}.e-bigger.e-small .e-upload .e-upload-actions .e-file-upload-btn,.e-bigger.e-small .e-upload .e-upload-actions .e-file-clear-btn{margin:12px}.e-bigger.e-small .e-upload.e-rtl .e-file-select-wrap{padding:16px 12px 16px 0}.e-bigger.e-small .e-upload.e-rtl .e-file-select-wrap .e-control.e-btn{margin-right:10px}.e-bigger.e-small .e-upload.e-rtl .e-file-select-wrap .e-file-drop{margin-left:60px;margin-right:12px;position:relative}.e-bigger.e-small .e-upload.e-rtl .e-upload-actions{text-align:left}.e-bigger.e-small .e-upload.e-rtl .e-upload-files .e-upload-file-list .e-file-container{height:100%;margin-left:60px;margin-right:12px;position:relative}.e-bigger.e-small .e-upload.e-rtl .e-upload-files .e-upload-file-list .e-file-container .e-rtl-container{direction:ltr;float:right;width:100%}.e-bigger.e-small .e-upload.e-rtl .e-upload-files .e-upload-file-list .e-file-container .e-file-type,.e-bigger.e-small .e-upload.e-rtl .e-upload-files .e-upload-file-list .e-file-container .e-file-name{float:right}.e-bigger.e-small .e-upload.e-rtl .e-upload-files .e-upload-file-list .e-file-container .e-file-size{direction:ltr;float:right;position:relative;text-align:right;width:100%}.e-bigger.e-small .e-upload.e-rtl .e-upload-files .e-upload-file-list .e-file-container .e-upload-progress-wrap{float:right;position:initial;top:46px;width:89%}.e-bigger.e-small .e-upload.e-rtl .e-upload-files .e-upload-file-list .e-file-container .e-upload-progress-wrap .e-progress-bar-text{float:left;right:-8px;top:-25px}.e-bigger.e-small .e-upload.e-rtl .e-upload-files .e-upload-file-list .e-file-remove-btn.e-icons,.e-bigger.e-small .e-upload.e-rtl .e-upload-files .e-upload-file-list .e-file-delete-btn.e-icons,.e-bigger.e-small .e-upload.e-rtl .e-upload-files .e-upload-file-list .e-file-abort-btn.e-icons,.e-bigger.e-small .e-upload.e-rtl .e-upload-files .e-upload-file-list .e-file-reload-btn.e-icons,.e-bigger.e-small .e-upload.e-rtl .e-upload-files .e-upload-file-list .e-file-pause-btn.e-icons,.e-bigger.e-small .e-upload.e-rtl .e-upload-files .e-upload-file-list .e-file-play-btn.e-icons{left:0;margin-left:12px;margin-right:12px;right:auto;top:50%}.e-bigger.e-small .e-upload.e-rtl .e-upload-files .e-upload-file-list .e-file-reload-btn.e-icons{left:36px;right:auto}.e-bigger.e-small .e-upload.e-rtl .e-upload-files .e-upload-file-list .e-file-play-btn.e-icons,.e-bigger.e-small .e-upload.e-rtl .e-upload-files .e-upload-file-list .e-file-reload-btn.e-icons,.e-bigger.e-small .e-upload.e-rtl .e-upload-files .e-upload-file-list .e-file-pause-btn.e-icons{left:36px}.e-bigger.e-small .e-upload.e-disabled .e-file-drop,.e-bigger.e-small .e-upload.e-disabled .e-upload-files .e-upload-file-list .e-file-container .e-file-name,.e-bigger.e-small .e-upload.e-disabled .e-upload-files .e-upload-file-list .e-file-container .e-file-type,.e-bigger.e-small .e-upload.e-disabled .e-upload-files .e-upload-file-list .e-file-container .e-file-size,.e-bigger.e-small .e-upload.e-disabled .e-upload-files .e-upload-file-list .e-file-container .e-file-status,.e-bigger.e-small .e-upload.e-disabled .e-upload-files .e-upload-file-list .e-file-container .e-file-information{color:#00000061}.e-bigger.e-small .e-upload .e-content-placeholder.e-upload.e-placeholder-upload{background-size:400px 65px;min-height:65px}.e-bigger.e-small .e-upload .e-bigger .e-content-placeholder.e-upload.e-placeholder-upload,.e-bigger.e-small .e-upload .e-bigger.e-content-placeholder.e-upload.e-placeholder-upload{background-size:400px 80px;min-height:80px}.e-container .e-value-switch-btn:before{content:"\e430"}.e-colorpicker-wrapper,.e-colorpicker-container{display:inline-block;line-height:0;outline:none;-webkit-user-select:none;user-select:none}.e-colorpicker-wrapper .e-colorpicker,.e-colorpicker-container .e-colorpicker{height:1px;opacity:0;position:absolute;width:1px}.e-colorpicker-wrapper .e-split-btn-wrapper .e-split-colorpicker.e-split-btn,.e-colorpicker-container .e-split-btn-wrapper .e-split-colorpicker.e-split-btn{font-family:initial;line-height:14px;padding:0 4px}.e-colorpicker-wrapper .e-split-btn-wrapper .e-split-colorpicker.e-split-btn .e-selected-color,.e-colorpicker-container .e-split-btn-wrapper .e-split-colorpicker.e-split-btn .e-selected-color{background:transparent url(data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0iVVRGLTgiPz4KPHN2ZyB3aWR0aD0iNnB4IiBoZWlnaHQ9IjZweCIgdmlld0JveD0iMCAwIDYgNiIgdmVyc2lvbj0iMS4xIiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHhtbG5zOnhsaW5rPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5L3hsaW5rIj4KICAgIDwhLS0gR2VuZXJhdG9yOiBTa2V0Y2ggNTAgKDU0OTgzKSAtIGh0dHA6Ly93d3cuYm9oZW1pYW5jb2RpbmcuY29tL3NrZXRjaCAtLT4KICAgIDx0aXRsZT5Hcm91cCA5PC90aXRsZT4KICAgIDxkZXNjPkNyZWF0ZWQgd2l0aCBTa2V0Y2guPC9kZXNjPgogICAgPGRlZnM+PC9kZWZzPgogICAgPGcgaWQ9IlBhZ2UtMSIgc3Ryb2tlPSJub25lIiBzdHJva2Utd2lkdGg9IjEiIGZpbGw9Im5vbmUiIGZpbGwtcnVsZT0iZXZlbm9kZCI+CiAgICAgICAgPGcgaWQ9Ikdyb3VwLTkiPgogICAgICAgICAgICA8cmVjdCBpZD0iUmVjdGFuZ2xlLTExIiBmaWxsPSIjRTBFMEUwIiB4PSIwIiB5PSIwIiB3aWR0aD0iMyIgaGVpZ2h0PSIzIj48L3JlY3Q+CiAgICAgICAgICAgIDxyZWN0IGlkPSJSZWN0YW5nbGUtMTEtQ29weS0yIiBmaWxsPSIjRkZGRkZGIiB4PSIwIiB5PSIzIiB3aWR0aD0iMyIgaGVpZ2h0PSIzIj48L3JlY3Q+CiAgICAgICAgICAgIDxyZWN0IGlkPSJSZWN0YW5nbGUtMTEtQ29weSIgZmlsbD0iI0ZGRkZGRiIgeD0iMyIgeT0iMCIgd2lkdGg9IjMiIGhlaWdodD0iMyI+PC9yZWN0PgogICAgICAgICAgICA8cmVjdCBpZD0iUmVjdGFuZ2xlLTExLUNvcHktMyIgZmlsbD0iI0UwRTBFMCIgeD0iMyIgeT0iMyIgd2lkdGg9IjMiIGhlaWdodD0iMyI+PC9yZWN0PgogICAgICAgIDwvZz4KICAgIDwvZz4KPC9zdmc+);background-size:8px;border-radius:2px;height:18px;margin-top:0;position:relative;width:18px}.e-colorpicker-wrapper .e-split-btn-wrapper .e-split-colorpicker.e-split-btn .e-selected-color .e-split-preview,.e-colorpicker-container .e-split-btn-wrapper .e-split-colorpicker.e-split-btn .e-selected-color .e-split-preview{border-radius:2px}.e-colorpicker-wrapper .e-split-btn-wrapper.e-rtl .e-split-colorpicker.e-split-btn,.e-colorpicker-container .e-split-btn-wrapper.e-rtl .e-split-colorpicker.e-split-btn{padding:0 4px}.e-colorpicker-wrapper *,.e-colorpicker-container *{box-sizing:border-box}.e-colorpicker-wrapper.e-disabled .e-palette .e-tile,.e-colorpicker-container.e-disabled .e-palette .e-tile{cursor:default}.e-colorpicker-wrapper.e-disabled .e-palette .e-tile:hover,.e-colorpicker-container.e-disabled .e-palette .e-tile:hover{border:0;box-shadow:none}.e-colorpicker-wrapper.e-disabled .e-palette .e-tile.e-selected,.e-colorpicker-container.e-disabled .e-palette .e-tile.e-selected{border:0}.e-colorpicker-wrapper.e-disabled .e-container .e-handler,.e-colorpicker-wrapper.e-disabled .e-container .e-preview-container,.e-colorpicker-wrapper.e-disabled .e-container .e-slider-preview .e-colorpicker-slider .e-hue-slider,.e-colorpicker-wrapper.e-disabled .e-container .e-slider-preview .e-colorpicker-slider .e-opacity-slider,.e-colorpicker-wrapper.e-disabled .e-container .e-slider-preview .e-colorpicker-slider .e-slider-container .e-handle,.e-colorpicker-container.e-disabled .e-container .e-handler,.e-colorpicker-container.e-disabled .e-container .e-preview-container,.e-colorpicker-container.e-disabled .e-container .e-slider-preview .e-colorpicker-slider .e-hue-slider,.e-colorpicker-container.e-disabled .e-container .e-slider-preview .e-colorpicker-slider .e-opacity-slider,.e-colorpicker-container.e-disabled .e-container .e-slider-preview .e-colorpicker-slider .e-slider-container .e-handle{cursor:default}.e-colorpicker-wrapper.e-disabled .e-container .e-hsv-container,.e-colorpicker-container.e-disabled .e-container .e-hsv-container{pointer-events:none}.e-colorpicker-popup:not(.e-split-btn-wrapper):not(.e-dropdown-btn){line-height:0}.e-colorpicker.e-modal,.e-colorpicker.e-hsv-model{-webkit-overflow-scrolling:touch;height:100%;left:0;position:fixed;top:0;width:100%}.e-colorpicker.e-modal{background-color:#0009;opacity:.5;pointer-events:auto}.e-colorpicker.e-hsv-model{background-color:transparent}.sf-colorpicker .e-switch-ctrl-btn .e-ctrl-btn{position:relative}.e-show-value .sf-colorpicker.e-color-palette .e-selected-value,.e-show-value .sf-colorpicker.e-color-palette .e-switch-ctrl-btn{width:270px}.e-dropdown-popup.e-transparent .e-container{display:none}body.e-colorpicker-overflow{overflow:visible}.e-container{border:0;border-radius:0;display:inline-block;line-height:0;outline:none;-webkit-user-select:none;user-select:none;box-shadow:0 5px 5px -3px #0003,0 8px 10px 1px #00000024,0 3px 14px 2px #0000001f}.e-container.e-color-picker{width:270px}.e-container.e-color-picker .e-mode-switch-btn{background:transparent url(data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0iVVRGLTgiPz4KPHN2ZyB3aWR0aD0iMjRweCIgaGVpZ2h0PSIyNHB4IiB2aWV3Qm94PSIwIDAgMjQgMjQiIHZlcnNpb249IjEuMSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIiB4bWxuczp4bGluaz0iaHR0cDovL3d3dy53My5vcmcvMTk5OS94bGluayI+CiAgICA8IS0tIEdlbmVyYXRvcjogU2tldGNoIDUwLjIgKDU1MDQ3KSAtIGh0dHA6Ly93d3cuYm9oZW1pYW5jb2RpbmcuY29tL3NrZXRjaCAtLT4KICAgIDx0aXRsZT5Hcm91cCA0IENvcHk8L3RpdGxlPgogICAgPGRlc2M+Q3JlYXRlZCB3aXRoIFNrZXRjaC48L2Rlc2M+CiAgICA8ZGVmcz48L2RlZnM+CiAgICA8ZyBpZD0iUGFnZS0xIiBzdHJva2U9Im5vbmUiIHN0cm9rZS13aWR0aD0iMSIgZmlsbD0ibm9uZSIgZmlsbC1ydWxlPSJldmVub2RkIj4KICAgICAgICA8ZyBpZD0iQXJ0Ym9hcmQiPgogICAgICAgICAgICA8ZyBpZD0iR3JvdXAtNC1Db3B5IiB0cmFuc2Zvcm09InRyYW5zbGF0ZSgwLjAwMDAwMCwgMC4wMDAwMDApIj4KICAgICAgICAgICAgICAgIDxyZWN0IGlkPSJSZWN0YW5nbGUtMjUtQ29weS04IiBmaWxsPSIjNDU5NkNFIiB4PSIwIiB5PSIwIiB3aWR0aD0iMTIiIGhlaWdodD0iMTIiPjwvcmVjdD4KICAgICAgICAgICAgICAgIDxyZWN0IGlkPSJSZWN0YW5nbGUtMjUtQ29weS05IiBmaWxsPSIjNUNDMTVCIiB4PSIwIiB5PSIxMiIgd2lkdGg9IjEyIiBoZWlnaHQ9IjEyIj48L3JlY3Q+CiAgICAgICAgICAgICAgICA8cmVjdCBpZD0iUmVjdGFuZ2xlLTI1LUNvcHktMTAiIGZpbGw9IiNGQkQ1MDYiIHg9IjEyIiB5PSIwIiB3aWR0aD0iMTIiIGhlaWdodD0iMTIiPjwvcmVjdD4KICAgICAgICAgICAgICAgIDxyZWN0IGlkPSJSZWN0YW5nbGUtMjUtQ29weS0xMSIgZmlsbD0iI0VDNEU0MyIgeD0iMTIiIHk9IjEyIiB3aWR0aD0iMTIiIGhlaWdodD0iMTIiPjwvcmVjdD4KICAgICAgICAgICAgPC9nPgogICAgICAgIDwvZz4KICAgIDwvZz4KPC9zdmc+) no-repeat 100% 100%}.e-container.e-color-palette{width:auto}.e-container.e-color-palette .e-mode-switch-btn{background:transparent url(data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0iVVRGLTgiIHN0YW5kYWxvbmU9Im5vIj8+CjwhRE9DVFlQRSBzdmcgUFVCTElDICItLy9XM0MvL0RURCBTVkcgMS4xLy9FTiIgImh0dHA6Ly93d3cudzMub3JnL0dyYXBoaWNzL1NWRy8xLjEvRFREL3N2ZzExLmR0ZCI+Cjxzdmcgd2lkdGg9IjEwMCUiIGhlaWdodD0iMTAwJSIgdmlld0JveD0iMCAwIDE4IDE4IiB2ZXJzaW9uPSIxLjEiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgeG1sbnM6eGxpbms9Imh0dHA6Ly93d3cudzMub3JnLzE5OTkveGxpbmsiIHhtbDpzcGFjZT0icHJlc2VydmUiIHhtbG5zOnNlcmlmPSJodHRwOi8vd3d3LnNlcmlmLmNvbS8iIHN0eWxlPSJmaWxsLXJ1bGU6ZXZlbm9kZDtjbGlwLXJ1bGU6ZXZlbm9kZDtzdHJva2UtbGluZWpvaW46cm91bmQ7c3Ryb2tlLW1pdGVybGltaXQ6MS40MTQyMTsiPgogICAgPGcgdHJhbnNmb3JtPSJtYXRyaXgoMSwwLDAsLTEsMCwxOCkiPgogICAgICAgIDxyZWN0IHg9IjAiIHk9IjAiIHdpZHRoPSIxOCIgaGVpZ2h0PSIxOCIgc3R5bGU9ImZpbGw6dXJsKCNfTGluZWFyMSk7Ii8+CiAgICA8L2c+CiAgICA8ZyB0cmFuc2Zvcm09Im1hdHJpeCgxLDAsMCwtMSwwLDE4KSI+CiAgICAgICAgPHJlY3QgeD0iMCIgeT0iMCIgd2lkdGg9IjE4IiBoZWlnaHQ9IjE4IiBzdHlsZT0iZmlsbDp1cmwoI19MaW5lYXIyKTsiLz4KICAgIDwvZz4KICAgIDxnIHRyYW5zZm9ybT0ibWF0cml4KDEsMCwwLC0xLDAsMTgpIj4KICAgICAgICA8Y2xpcFBhdGggaWQ9Il9jbGlwMyI+CiAgICAgICAgICAgIDxyZWN0IHg9IjAiIHk9IjAiIHdpZHRoPSIxOCIgaGVpZ2h0PSIxOCIvPgogICAgICAgIDwvY2xpcFBhdGg+CiAgICAgICAgPGcgY2xpcC1wYXRoPSJ1cmwoI19jbGlwMykiPgogICAgICAgICAgICA8ZyB0cmFuc2Zvcm09Im1hdHJpeCgxLDAsMCwtMSwtMCwxOCkiPgogICAgICAgICAgICA8L2c+CiAgICAgICAgPC9nPgogICAgPC9nPgogICAgPGcgdHJhbnNmb3JtPSJtYXRyaXgoMSwwLDAsLTEsMCwxOCkiPgogICAgICAgIDxjbGlwUGF0aCBpZD0iX2NsaXA0Ij4KICAgICAgICAgICAgPHJlY3QgeD0iMCIgeT0iMCIgd2lkdGg9IjE4IiBoZWlnaHQ9IjE4Ii8+CiAgICAgICAgPC9jbGlwUGF0aD4KICAgICAgICA8ZyBjbGlwLXBhdGg9InVybCgjX2NsaXA0KSI+CiAgICAgICAgICAgIDxnIHRyYW5zZm9ybT0ibWF0cml4KDEsMCwwLC0xLC0wLDE4KSI+CiAgICAgICAgICAgICAgICA8dXNlIHhsaW5rOmhyZWY9IiNfSW1hZ2U1IiB4PSIwIiB5PSIwIiB3aWR0aD0iMThweCIgaGVpZ2h0PSIxOHB4Ii8+CiAgICAgICAgICAgIDwvZz4KICAgICAgICA8L2c+CiAgICA8L2c+CiAgICA8ZyB0cmFuc2Zvcm09Im1hdHJpeCgxLDAsMCwtMSwwLDE4KSI+CiAgICAgICAgPGNsaXBQYXRoIGlkPSJfY2xpcDYiPgogICAgICAgICAgICA8cmVjdCB4PSIwIiB5PSIwIiB3aWR0aD0iMTgiIGhlaWdodD0iMTgiLz4KICAgICAgICA8L2NsaXBQYXRoPgogICAgICAgIDxnIGNsaXAtcGF0aD0idXJsKCNfY2xpcDYpIj4KICAgICAgICAgICAgPGcgdHJhbnNmb3JtPSJtYXRyaXgoMSwwLDAsLTEsLTAsMTgpIj4KICAgICAgICAgICAgPC9nPgogICAgICAgIDwvZz4KICAgIDwvZz4KICAgIDxkZWZzPgogICAgICAgIDxsaW5lYXJHcmFkaWVudCBpZD0iX0xpbmVhcjEiIHgxPSIwIiB5MT0iMCIgeDI9IjEiIHkyPSIwIiBncmFkaWVudFVuaXRzPSJ1c2VyU3BhY2VPblVzZSIgZ3JhZGllbnRUcmFuc2Zvcm09Im1hdHJpeCg2LjI3MDE5ZS0xNCwtMTAyNCwtMTAyNCwtNi4yNzAxOWUtMTQsMCwxOCkiPjxzdG9wIG9mZnNldD0iMCIgc3R5bGU9InN0b3AtY29sb3I6cmdiKDAsMTgyLDI1NSk7c3RvcC1vcGFjaXR5OjAiLz48c3RvcCBvZmZzZXQ9IjEiIHN0eWxlPSJzdG9wLWNvbG9yOmJsYWNrO3N0b3Atb3BhY2l0eTowIi8+PC9saW5lYXJHcmFkaWVudD4KICAgICAgICA8bGluZWFyR3JhZGllbnQgaWQ9Il9MaW5lYXIyIiB4MT0iMCIgeTE9IjAiIHgyPSIxIiB5Mj0iMCIgZ3JhZGllbnRVbml0cz0idXNlclNwYWNlT25Vc2UiIGdyYWRpZW50VHJhbnNmb3JtPSJtYXRyaXgoMS4xMDIxOGUtMTUsLTE4LC0xOCwtMS4xMDIxOGUtMTUsMTgsMTgpIj48c3RvcCBvZmZzZXQ9IjAiIHN0eWxlPSJzdG9wLWNvbG9yOnJnYigwLDE4MiwyNTUpO3N0b3Atb3BhY2l0eToxIi8+PHN0b3Agb2Zmc2V0PSIxIiBzdHlsZT0ic3RvcC1jb2xvcjpibGFjaztzdG9wLW9wYWNpdHk6MSIvPjwvbGluZWFyR3JhZGllbnQ+CiAgICAgICAgPGltYWdlIGlkPSJfSW1hZ2U1IiB3aWR0aD0iMThweCIgaGVpZ2h0PSIxOHB4IiB4bGluazpocmVmPSJkYXRhOmltYWdlL3BuZztiYXNlNjQsaVZCT1J3MEtHZ29BQUFBTlNVaEVVZ0FBQUJJQUFBQVNDQVlBQUFCV3pvNVhBQUFBQ1hCSVdYTUFBQTdFQUFBT3hBR1ZLdzRiQUFBQmUwbEVRVlE0alcyUjIyNGNNUXhER2NBbyt2OC8yU0lYZE9wTk5iSXVWaDlrZXp6SlBoaWlTT3JNQXZ2eTBBanlBSGVBSEdBSHlDUDE4dTQ3ZVl6ZTlBS2xhaDlCZ0F5WG5tVUxjQStRYmQ3cWp4OWdnVkxGUWRiVDlBQlpYNlZkWHpNLy9MVmZqbE11dy9xQWR2QUMzZmR2bVE1UVpVbUErZ1ZUWDZWZDh3Sjk3NWRLbkdYek1VZnBpVGYzdXpkQi93Z2tsaVZ4a0U1dFdSSkxiNGMvNlplamZvTE5NdFJaeXYyWk4zZFNCYXREVlFGWGxQcDRnTlZBb3FPa1F4dW8yY3Iybk5Wd2lnSnVnQ2xnaWxMclgxQ2Jod3BXdmUwa3NtVTUzUXh3SGM4QU01UjZIQnRBUUUzQVlqa25WREpyb2tDM1BIYlBPZlpTano4SjRMWU9XRFIzVlJBblBOeUE3dm1tZGs5UWQ1VGo0dzBzRzRqYjBPbXBUa0FmMHpiZDExN3FCSjBOeEx3MGl5RGNnZGlPcG80K0lCMElINkQzMXdTMEJqb1ozQ1QvMHBpSGNla0ppTmgwdmxMZmZnOUF3OGs4Z3RoZXYyczh6MHA5L1FVNlQ3Z2JFTWhnbGhIcDdjZDQzbm5CajU4ekhVZERiMk1URit6TC9oOXIveU91c0ZQS093QUFBQUJKUlU1RXJrSmdnZz09Ii8+CiAgICA8L2RlZnM+Cjwvc3ZnPgo=) no-repeat 100% 100%}.e-container .e-custom-palette{width:auto}.e-container .e-custom-palette .e-palette{padding:10px}.e-container .e-custom-palette.e-palette-group{height:270px;overflow-y:scroll}.e-container .e-palette{border-bottom:0;display:table;line-height:0;outline:none;-webkit-user-select:none;user-select:none}.e-container .e-palette .e-row{display:table-row;white-space:nowrap}.e-container .e-palette .e-tile{border:.5px solid transparent;box-sizing:border-box;cursor:pointer;display:inline-block;height:27px;text-align:center;vertical-align:middle;width:27px}.e-container .e-palette .e-tile.e-selected{outline:#000 .5px solid;position:relative}.e-container .e-palette .e-tile:hover{box-shadow:2px 2px 7px 2px #0000004d;position:relative}.e-container .e-palette .e-tile.e-nocolor-item{background:transparent url(data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0iVVRGLTgiPz4KPHN2ZyB3aWR0aD0iNnB4IiBoZWlnaHQ9IjZweCIgdmlld0JveD0iMCAwIDYgNiIgdmVyc2lvbj0iMS4xIiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHhtbG5zOnhsaW5rPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5L3hsaW5rIj4KICAgIDwhLS0gR2VuZXJhdG9yOiBTa2V0Y2ggNTAgKDU0OTgzKSAtIGh0dHA6Ly93d3cuYm9oZW1pYW5jb2RpbmcuY29tL3NrZXRjaCAtLT4KICAgIDx0aXRsZT5Hcm91cCA5PC90aXRsZT4KICAgIDxkZXNjPkNyZWF0ZWQgd2l0aCBTa2V0Y2guPC9kZXNjPgogICAgPGRlZnM+PC9kZWZzPgogICAgPGcgaWQ9IlBhZ2UtMSIgc3Ryb2tlPSJub25lIiBzdHJva2Utd2lkdGg9IjEiIGZpbGw9Im5vbmUiIGZpbGwtcnVsZT0iZXZlbm9kZCI+CiAgICAgICAgPGcgaWQ9Ikdyb3VwLTkiPgogICAgICAgICAgICA8cmVjdCBpZD0iUmVjdGFuZ2xlLTExIiBmaWxsPSIjRTBFMEUwIiB4PSIwIiB5PSIwIiB3aWR0aD0iMyIgaGVpZ2h0PSIzIj48L3JlY3Q+CiAgICAgICAgICAgIDxyZWN0IGlkPSJSZWN0YW5nbGUtMTEtQ29weS0yIiBmaWxsPSIjRkZGRkZGIiB4PSIwIiB5PSIzIiB3aWR0aD0iMyIgaGVpZ2h0PSIzIj48L3JlY3Q+CiAgICAgICAgICAgIDxyZWN0IGlkPSJSZWN0YW5nbGUtMTEtQ29weSIgZmlsbD0iI0ZGRkZGRiIgeD0iMyIgeT0iMCIgd2lkdGg9IjMiIGhlaWdodD0iMyI+PC9yZWN0PgogICAgICAgICAgICA8cmVjdCBpZD0iUmVjdGFuZ2xlLTExLUNvcHktMyIgZmlsbD0iI0UwRTBFMCIgeD0iMyIgeT0iMyIgd2lkdGg9IjMiIGhlaWdodD0iMyI+PC9yZWN0PgogICAgICAgIDwvZz4KICAgIDwvZz4KPC9zdmc+);background-size:8px}.e-container .e-hsv-container{border-bottom:0;position:relative;touch-action:none}.e-container .e-hsv-container .e-hsv-color{background:linear-gradient(to bottom,#0000 0,#000),linear-gradient(to right,#fff 0,#fff0);height:170px}.e-container .e-hsv-container .e-handler{border:1px solid #fff;border-radius:6px;box-shadow:0 0 3px #000000b3,inset 0 0 2px #000000b3;cursor:pointer;display:inline-block;height:8px;margin-left:-4px;margin-top:-4px;position:absolute;touch-action:none;-webkit-user-select:none;user-select:none;width:8px}.e-container .e-slider-preview{display:inline-block;width:100%;padding:10px 16px}.e-container .e-slider-preview .e-colorpicker-slider{display:inline-block;width:82.34%}.e-container .e-slider-preview .e-colorpicker-slider .e-slider-container{height:18px}.e-container .e-slider-preview .e-colorpicker-slider .e-slider-container .e-slider{height:18px;top:calc(50% - 9px)}.e-container .e-slider-preview .e-colorpicker-slider .e-slider-container .e-slider-track{height:6px!important;top:calc(50% - 3px);border-radius:0}.e-container .e-slider-preview .e-colorpicker-slider .e-slider-container .e-handle{border-radius:6px;cursor:pointer;height:14px;top:calc(50% - 7px);width:14px}.e-container .e-slider-preview .e-colorpicker-slider .e-slider-container .e-handle.e-handle-active{cursor:pointer}.e-container .e-slider-preview .e-colorpicker-slider .e-slider-container .e-handle.e-large-thumb-size{transform:scale(1)}.e-container .e-slider-preview .e-colorpicker-slider .e-hue-slider .e-slider-track{background:linear-gradient(to right,red 0,#ff0 16%,#0f0,#0ff,#00f,#f0f 84%,#ff0004)}.e-container .e-slider-preview .e-colorpicker-slider .e-opacity-slider .e-slider-track{background:transparent url(data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0iVVRGLTgiPz4KPHN2ZyB3aWR0aD0iNnB4IiBoZWlnaHQ9IjZweCIgdmlld0JveD0iMCAwIDYgNiIgdmVyc2lvbj0iMS4xIiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHhtbG5zOnhsaW5rPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5L3hsaW5rIj4KICAgIDwhLS0gR2VuZXJhdG9yOiBTa2V0Y2ggNTAgKDU0OTgzKSAtIGh0dHA6Ly93d3cuYm9oZW1pYW5jb2RpbmcuY29tL3NrZXRjaCAtLT4KICAgIDx0aXRsZT5Hcm91cCA5PC90aXRsZT4KICAgIDxkZXNjPkNyZWF0ZWQgd2l0aCBTa2V0Y2guPC9kZXNjPgogICAgPGRlZnM+PC9kZWZzPgogICAgPGcgaWQ9IlBhZ2UtMSIgc3Ryb2tlPSJub25lIiBzdHJva2Utd2lkdGg9IjEiIGZpbGw9Im5vbmUiIGZpbGwtcnVsZT0iZXZlbm9kZCI+CiAgICAgICAgPGcgaWQ9Ikdyb3VwLTkiPgogICAgICAgICAgICA8cmVjdCBpZD0iUmVjdGFuZ2xlLTExIiBmaWxsPSIjRTBFMEUwIiB4PSIwIiB5PSIwIiB3aWR0aD0iMyIgaGVpZ2h0PSIzIj48L3JlY3Q+CiAgICAgICAgICAgIDxyZWN0IGlkPSJSZWN0YW5nbGUtMTEtQ29weS0yIiBmaWxsPSIjRkZGRkZGIiB4PSIwIiB5PSIzIiB3aWR0aD0iMyIgaGVpZ2h0PSIzIj48L3JlY3Q+CiAgICAgICAgICAgIDxyZWN0IGlkPSJSZWN0YW5nbGUtMTEtQ29weSIgZmlsbD0iI0ZGRkZGRiIgeD0iMyIgeT0iMCIgd2lkdGg9IjMiIGhlaWdodD0iMyI+PC9yZWN0PgogICAgICAgICAgICA8cmVjdCBpZD0iUmVjdGFuZ2xlLTExLUNvcHktMyIgZmlsbD0iI0UwRTBFMCIgeD0iMyIgeT0iMyIgd2lkdGg9IjMiIGhlaWdodD0iMyI+PC9yZWN0PgogICAgICAgIDwvZz4KICAgIDwvZz4KPC9zdmc+);border:0;z-index:0}.e-container .e-slider-preview .e-colorpicker-slider .e-opacity-slider .e-opacity-empty-track{background-size:contain;border:0;height:6px;position:absolute;top:calc(50% - 3px);width:100%;z-index:1}.e-container .e-slider-preview .e-colorpicker-slider .e-slider.e-hue-slider .e-handle,.e-container .e-slider-preview .e-colorpicker-slider .e-slider.e-hue-slider .e-handle-start,.e-container .e-slider-preview .e-colorpicker-slider .e-slider.e-opacity-slider .e-handle,.e-container .e-slider-preview .e-colorpicker-slider .e-slider.e-opacity-slider .e-handle-start{box-shadow:0 1px 2px #0000004d}.e-container .e-slider-preview .e-preview-container{background:transparent url(data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0iVVRGLTgiPz4KPHN2ZyB3aWR0aD0iNnB4IiBoZWlnaHQ9IjZweCIgdmlld0JveD0iMCAwIDYgNiIgdmVyc2lvbj0iMS4xIiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHhtbG5zOnhsaW5rPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5L3hsaW5rIj4KICAgIDwhLS0gR2VuZXJhdG9yOiBTa2V0Y2ggNTAgKDU0OTgzKSAtIGh0dHA6Ly93d3cuYm9oZW1pYW5jb2RpbmcuY29tL3NrZXRjaCAtLT4KICAgIDx0aXRsZT5Hcm91cCA5PC90aXRsZT4KICAgIDxkZXNjPkNyZWF0ZWQgd2l0aCBTa2V0Y2guPC9kZXNjPgogICAgPGRlZnM+PC9kZWZzPgogICAgPGcgaWQ9IlBhZ2UtMSIgc3Ryb2tlPSJub25lIiBzdHJva2Utd2lkdGg9IjEiIGZpbGw9Im5vbmUiIGZpbGwtcnVsZT0iZXZlbm9kZCI+CiAgICAgICAgPGcgaWQ9Ikdyb3VwLTkiPgogICAgICAgICAgICA8cmVjdCBpZD0iUmVjdGFuZ2xlLTExIiBmaWxsPSIjRTBFMEUwIiB4PSIwIiB5PSIwIiB3aWR0aD0iMyIgaGVpZ2h0PSIzIj48L3JlY3Q+CiAgICAgICAgICAgIDxyZWN0IGlkPSJSZWN0YW5nbGUtMTEtQ29weS0yIiBmaWxsPSIjRkZGRkZGIiB4PSIwIiB5PSIzIiB3aWR0aD0iMyIgaGVpZ2h0PSIzIj48L3JlY3Q+CiAgICAgICAgICAgIDxyZWN0IGlkPSJSZWN0YW5nbGUtMTEtQ29weSIgZmlsbD0iI0ZGRkZGRiIgeD0iMyIgeT0iMCIgd2lkdGg9IjMiIGhlaWdodD0iMyI+PC9yZWN0PgogICAgICAgICAgICA8cmVjdCBpZD0iUmVjdGFuZ2xlLTExLUNvcHktMyIgZmlsbD0iI0UwRTBFMCIgeD0iMyIgeT0iMyIgd2lkdGg9IjMiIGhlaWdodD0iMyI+PC9yZWN0PgogICAgICAgIDwvZz4KICAgIDwvZz4KPC9zdmc+);background-size:10px;border:1px solid #e0e0e0;cursor:pointer;display:inline-block;height:32px;margin-left:4.205%;position:relative;top:-2px;width:13.45%}.e-container .e-slider-preview .e-preview-container .e-preview{display:block;height:16px;position:absolute;width:100%}.e-container .e-slider-preview .e-preview-container .e-preview.e-current{border-bottom:1px solid #e0e0e0;top:0}.e-container .e-slider-preview .e-preview-container .e-preview.e-previous{height:14px;top:16px}.e-container .e-selected-value{align-items:center;display:flex;padding:0 16px 16px;-webkit-user-select:none;user-select:none;width:100%}.e-container .e-selected-value .e-input-container .e-float-input input{padding-left:0;text-align:center}.e-container .e-selected-value .e-input-container .e-numeric-hidden{display:none}.e-container .e-selected-value .e-value-switch-btn{font-family:e-icons;margin-top:0;padding:2px 3px;font-size:16px;line-height:16px}.e-container .e-input-container{display:inline-block;width:89.8%}.e-container .e-input-container .e-float-input{display:inline-block;margin-right:3.75%;vertical-align:baseline}.e-container .e-input-container .e-float-input:first-child{width:33%}.e-container .e-input-container .e-float-input:first-child input{height:auto}.e-container .e-input-container .e-float-input.e-numeric{height:auto;width:12%}.e-container .e-input-container .e-float-input.e-numeric input{height:auto}.e-container .e-input-container .e-float-input .e-float-text{text-align:center}.e-container .e-switch-ctrl-btn{display:inline-block;padding:0 16px 16px;white-space:nowrap;width:100%}.e-container .e-switch-ctrl-btn .e-ctrl-btn{float:right;text-align:right;white-space:nowrap;width:89.913%}.e-container .e-switch-ctrl-btn .e-ctrl-btn .e-btn{max-width:50%;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.e-container .e-switch-ctrl-btn .e-ctrl-btn .e-btn.e-cancel{margin-left:0}.e-container .e-switch-ctrl-btn .e-mode-switch-btn{background-origin:border-box;background-position:center;background-size:cover;float:left;margin-top:0;overflow:hidden;white-space:nowrap}.e-container .e-switch-ctrl-btn .e-mode-switch-btn:focus{box-shadow:0 0 2px 3px #0003}.e-container .e-value-switch-btn,.e-container .e-mode-switch-btn{background-color:transparent;border-color:transparent;position:relative;width:10.09%;height:24px}.e-container.e-color-picker .e-value-switch-btn:focus,.e-container.e-color-picker .e-value-switch-btn:hover,.e-container.e-color-picker .e-value-switch-btn:active{border-color:transparent;box-shadow:none;outline:none}.e-container.e-color-picker .e-value-switch-btn:focus{outline:none}.e-container.e-color-palette .e-palette+.e-selected-value,.e-container.e-color-palette .e-palette-group+.e-selected-value{padding:16px}.e-container.e-color-palette .e-palette+.e-switch-ctrl-btn,.e-container.e-color-palette .e-palette-group+.e-switch-ctrl-btn{padding:23px 16px 16px}.e-container.e-color-palette .e-clr-pal-rec-wpr{padding:0}.e-container.e-color-palette .e-clr-pal-rec-wpr .e-recent-clr-span{display:block;font-weight:600;font-size:14px;height:36px;padding:7px 16px;line-height:22px;color:#000}.e-container.e-color-palette .e-clr-pal-rec-wpr .e-palette.e-recent-palette{padding:9px 10.5px}.e-container.e-color-palette .e-clr-pal-rec-wpr .e-palette.e-recent-palette .e-tile{height:18px!important;width:18px!important;margin:0 3.5px;border:.5px solid #eee}.e-container.e-color-palette .e-clr-pal-rec-wpr .e-palette.e-recent-palette .e-tile:hover{border:.5px solid transparent!important}.sf-colorpicker.e-container .e-input-container .e-float-input{float:left;margin-left:-1px}.e-hide-opacity .e-container .e-slider-preview .e-colorpicker-slider{vertical-align:super}.e-hide-opacity .e-container .e-slider-preview .e-preview-container{top:0}.e-hide-opacity .e-container .e-float-input:first-child{width:36%}.e-hide-opacity .e-container .e-float-input.e-numeric{width:16.3%}.e-hide-hex-value .e-container .e-float-input.e-numeric{width:21.25%}.e-hide-hex-value.e-hide-opacity .e-container .e-float-input.e-numeric{width:29.59%}.e-hide-valueswitcher .e-container .e-input-container{width:100%}.e-hide-valueswitcher .e-container .e-float-input:first-child{width:33%}.e-hide-valueswitcher .e-container .e-float-input.e-numeric{width:13%}.e-hide-valueswitcher .e-container .e-float-input:last-child{margin-right:0}.e-hide-valueswitcher.e-hide-opacity .e-container .e-float-input:first-child{width:36%}.e-hide-valueswitcher.e-hide-opacity .e-container .e-float-input.e-numeric{width:17.58%}.e-hide-valueswitcher.e-hide-hex-value .e-container .e-float-input.e-numeric{width:22.18%}.e-hide-valueswitcher.e-hide-hex-value.e-hide-opacity .e-container .e-float-input.e-numeric{width:30.82%}.e-rtl .e-container .e-hsv-container .e-hsv-color{background:linear-gradient(to bottom,#0000 0,#000),linear-gradient(to left,#fff 0,#fff0)}.e-rtl .e-container .e-slider-preview .e-hue-slider .e-slider-track{background:linear-gradient(to left,red 0,#ff0 16%,#0f0,#0ff,#00f,#f0f 84%,#ff0004)}.e-rtl .e-container .e-slider-preview .e-preview-container{margin-left:0;margin-right:4.205%}.e-rtl .e-container .e-selected-value .e-float-input{margin-left:3.75%;margin-right:0}.e-rtl .e-container .e-selected-value .e-float-input input{padding-right:0}.e-rtl .e-container .e-selected-value .e-value-switch-btn{transform:rotate(180deg)}.e-rtl .e-container .e-switch-ctrl-btn .e-mode-switch-btn{float:right}.e-rtl .e-container .e-switch-ctrl-btn .e-ctrl-btn{float:left;text-align:left}.e-rtl .e-container .e-switch-ctrl-btn .e-ctrl-btn .e-cancel{margin-left:0;margin-right:0}.e-rtl .e-container.sf-colorpicker .e-selected-value .e-input-container .e-float-input{float:right;margin-right:-1px}.e-rtl.e-hide-valueswitcher .e-container .e-float-input:last-child{margin-left:0}.e-hide-switchable-value .e-container .e-input-container .e-float-input:first-child{width:100%}.e-popup.e-tooltip-wrap.e-color-picker-tooltip{border-radius:50% 50% 0%;box-shadow:0 1px 2px #0000004d;cursor:pointer;min-width:26px;transform:translateY(18px) rotate(45deg) scale(.01);transition:transform .4s cubic-bezier(.25,.8,.25,1)}.e-popup.e-tooltip-wrap.e-color-picker-tooltip .e-tip-content{background:transparent url(data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0iVVRGLTgiPz4KPHN2ZyB3aWR0aD0iNnB4IiBoZWlnaHQ9IjZweCIgdmlld0JveD0iMCAwIDYgNiIgdmVyc2lvbj0iMS4xIiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHhtbG5zOnhsaW5rPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5L3hsaW5rIj4KICAgIDwhLS0gR2VuZXJhdG9yOiBTa2V0Y2ggNTAgKDU0OTgzKSAtIGh0dHA6Ly93d3cuYm9oZW1pYW5jb2RpbmcuY29tL3NrZXRjaCAtLT4KICAgIDx0aXRsZT5Hcm91cCA5PC90aXRsZT4KICAgIDxkZXNjPkNyZWF0ZWQgd2l0aCBTa2V0Y2guPC9kZXNjPgogICAgPGRlZnM+PC9kZWZzPgogICAgPGcgaWQ9IlBhZ2UtMSIgc3Ryb2tlPSJub25lIiBzdHJva2Utd2lkdGg9IjEiIGZpbGw9Im5vbmUiIGZpbGwtcnVsZT0iZXZlbm9kZCI+CiAgICAgICAgPGcgaWQ9Ikdyb3VwLTkiPgogICAgICAgICAgICA8cmVjdCBpZD0iUmVjdGFuZ2xlLTExIiBmaWxsPSIjRTBFMEUwIiB4PSIwIiB5PSIwIiB3aWR0aD0iMyIgaGVpZ2h0PSIzIj48L3JlY3Q+CiAgICAgICAgICAgIDxyZWN0IGlkPSJSZWN0YW5nbGUtMTEtQ29weS0yIiBmaWxsPSIjRkZGRkZGIiB4PSIwIiB5PSIzIiB3aWR0aD0iMyIgaGVpZ2h0PSIzIj48L3JlY3Q+CiAgICAgICAgICAgIDxyZWN0IGlkPSJSZWN0YW5nbGUtMTEtQ29weSIgZmlsbD0iI0ZGRkZGRiIgeD0iMyIgeT0iMCIgd2lkdGg9IjMiIGhlaWdodD0iMyI+PC9yZWN0PgogICAgICAgICAgICA8cmVjdCBpZD0iUmVjdGFuZ2xlLTExLUNvcHktMyIgZmlsbD0iI0UwRTBFMCIgeD0iMyIgeT0iMyIgd2lkdGg9IjMiIGhlaWdodD0iMyI+PC9yZWN0PgogICAgICAgIDwvZz4KICAgIDwvZz4KPC9zdmc+);background-size:8px;border-radius:50%;height:24px;position:relative;transform:rotate(45deg);width:24px}.e-split-preview,.e-tip-transparent{height:100%;left:0;position:absolute;top:0;width:100%}.e-container.e-color-palette .e-clr-pal-rec-wpr+.e-switch-ctrl-btn{padding-top:12px}.e-container{background-color:#fff}.e-container .e-palette .e-tile:hover,.e-container .e-palette .e-tile.e-selected{border-color:#eee}.e-container .e-handler.e-hide-handler,.e-container .e-handle.e-hide-handler{background-color:transparent;border-color:transparent;box-shadow:none}.e-container .e-control-wrapper.e-slider-container .e-slider.e-hue-slider .e-handle:not(.e-tab-handle),.e-container .e-control-wrapper.e-slider-container .e-slider.e-opacity-slider .e-handle:not(.e-tab-handle){background-color:#fff;border-color:#fff}.e-container .e-control-wrapper.e-slider-container .e-slider.e-hue-slider .e-handle:not(.e-tab-handle).e-handle-start:not(.e-tab-handle),.e-container .e-control-wrapper.e-slider-container .e-slider.e-opacity-slider .e-handle:not(.e-tab-handle).e-handle-start:not(.e-tab-handle){background-color:#fff;border-color:#fff}.e-container .e-control-wrapper.e-slider-container .e-slider.e-hue-slider .e-handle.e-tab-handle,.e-container .e-control-wrapper.e-slider-container .e-slider.e-opacity-slider .e-handle.e-tab-handle{background-color:#fff;border-color:#fff;box-shadow:0 1px 2px #0000004d}.e-colorpicker-wrapper.e-disabled .e-value-switch-btn,.e-colorpicker-wrapper.e-disabled .e-mode-switch-btn,.e-colorpicker-container.e-disabled .e-value-switch-btn,.e-colorpicker-container.e-disabled .e-mode-switch-btn{color:#00000042}.e-colorpicker-wrapper.e-disabled .e-value-switch-btn:focus,.e-colorpicker-wrapper.e-disabled .e-mode-switch-btn:focus,.e-colorpicker-container.e-disabled .e-value-switch-btn:focus,.e-colorpicker-container.e-disabled .e-mode-switch-btn:focus{background-color:transparent;color:#00000042;outline:none;outline-offset:unset}.e-colorpicker-wrapper.e-disabled .e-value-switch-btn:active,.e-colorpicker-wrapper.e-disabled .e-mode-switch-btn:active,.e-colorpicker-container.e-disabled .e-value-switch-btn:active,.e-colorpicker-container.e-disabled .e-mode-switch-btn:active{background-color:transparent;color:#00000042}.e-colorpicker-wrapper .e-icon-btn:disabled,.e-colorpicker-wrapper .e-icon-btn.e-disabled,.e-colorpicker-container .e-icon-btn:disabled,.e-colorpicker-container .e-icon-btn.e-disabled{background-color:transparent;box-shadow:none;color:#0000001f}.e-popup.e-tooltip-wrap.e-color-picker-tooltip{background-color:#fff;border-color:#fff}.e-bigger .e-colorpicker-wrapper .e-split-btn-wrapper .e-split-colorpicker.e-split-btn,.e-bigger.e-colorpicker-wrapper .e-split-btn-wrapper .e-split-colorpicker.e-split-btn,.e-bigger .e-colorpicker-container .e-split-btn-wrapper .e-split-colorpicker.e-split-btn,.e-bigger.e-colorpicker-container .e-split-btn-wrapper .e-split-colorpicker.e-split-btn{line-height:18px;padding:0 6px}.e-bigger .e-colorpicker-wrapper .e-split-btn-wrapper .e-split-colorpicker.e-split-btn .e-selected-color,.e-bigger.e-colorpicker-wrapper .e-split-btn-wrapper .e-split-colorpicker.e-split-btn .e-selected-color,.e-bigger .e-colorpicker-container .e-split-btn-wrapper .e-split-colorpicker.e-split-btn .e-selected-color,.e-bigger.e-colorpicker-container .e-split-btn-wrapper .e-split-colorpicker.e-split-btn .e-selected-color{height:22px;width:22px}.e-bigger .e-colorpicker-wrapper .e-split-btn-wrapper.e-rtl .e-split-colorpicker.e-split-btn,.e-bigger.e-colorpicker-wrapper .e-split-btn-wrapper.e-rtl .e-split-colorpicker.e-split-btn,.e-bigger .e-colorpicker-container .e-split-btn-wrapper.e-rtl .e-split-colorpicker.e-split-btn,.e-bigger.e-colorpicker-container .e-split-btn-wrapper.e-rtl .e-split-colorpicker.e-split-btn{padding:0 6px}.e-bigger .e-colorpicker-wrapper .e-colorpicker-popup:not(.e-split-btn-wrapper):not(.e-dropdown-btn),.e-bigger.e-colorpicker-wrapper .e-colorpicker-popup:not(.e-split-btn-wrapper):not(.e-dropdown-btn),.e-bigger .e-colorpicker-container .e-colorpicker-popup:not(.e-split-btn-wrapper):not(.e-dropdown-btn),.e-bigger.e-colorpicker-container .e-colorpicker-popup:not(.e-split-btn-wrapper):not(.e-dropdown-btn){line-height:0}.e-bigger .e-container .e-switch-ctrl-btn .e-ctrl-btn{margin:2px 0}.e-bigger .e-container.e-color-picker{width:290px}@media only screen and (max-width: 600px){.e-bigger .e-container.e-color-picker{width:100%!important}.e-bigger .e-container.e-colorpicker-popup{width:calc(100% - 20px)!important}}.e-bigger .e-container .e-palette .e-tile{height:29px;width:29px}.e-bigger .e-container .e-hsv-container .e-hsv-color{height:180px}.e-bigger .e-container .e-custom-palette.e-palette-group{height:290px}.e-bigger .e-container .e-slider-preview{padding:8px 16px}.e-bigger .e-container .e-slider-preview .e-preview-container{margin-left:4.657%;vertical-align:super;width:12.408%;top:0}@media only screen and (max-width: 600px){.e-bigger .e-container .e-slider-preview .e-preview-container{margin-left:4.6%!important}}.e-bigger .e-container .e-slider-preview .e-colorpicker-slider{width:82.944%}.e-bigger .e-container .e-slider-preview .e-colorpicker-slider .e-slider-container{height:20px}.e-bigger .e-container .e-slider-preview .e-colorpicker-slider .e-slider-container .e-handle{border-radius:8px;height:16px;top:calc(50% - 8px);width:16px}.e-bigger .e-container .e-slider-preview .e-switch-ctrl-btn .e-ctrl-btn{width:90.6%}.e-bigger .e-container.e-color-palette .e-palette+.e-switch-ctrl-btn{padding:25px 16px 16px}.e-bigger .e-container.e-color-palette .e-clr-pal-rec-wpr{padding:0}.e-bigger .e-container.e-color-palette .e-clr-pal-rec-wpr .e-recent-clr-span{display:block;font-size:16px;height:46px;padding:10px 16px;line-height:24px}.e-bigger .e-container.e-color-palette .e-clr-pal-rec-wpr .e-palette.e-recent-palette{padding:11px 10.5px 12px}.e-bigger .e-container.e-color-palette .e-clr-pal-rec-wpr .e-palette.e-recent-palette .e-tile{height:22px!important;width:22px!important;margin:0 2.5px}.e-bigger .e-container .e-input-container{width:90.7%}.e-bigger .e-container .e-input-container .e-float-input{margin-right:3.425%}.e-bigger .e-container .e-input-container .e-float-input:first-child{width:33.5%}.e-bigger .e-container .e-input-container .e-float-input:first-child input{height:auto}.e-bigger .e-container .e-input-container .e-float-input.e-numeric{height:auto;width:12.34%}.e-bigger .e-container .e-input-container .e-float-input.e-numeric input{height:auto}.e-bigger .e-container .e-css.e-value-switch-btn,.e-bigger .e-container .e-mode-switch-btn{padding:2px 3px;width:9.306%;font-size:18px;line-height:18px}.e-bigger .e-container .e-mode-switch-btn{margin-top:5px}.e-bigger .e-container.sf-colorpicker .e-input-container .e-float-input{margin-right:calc(3.425% - 2.38px)}.e-bigger .e-hide-opacity .e-container .e-slider-preview,.e-bigger.e-hide-opacity .e-container .e-slider-preview{padding:8px 16px}.e-bigger .e-hide-opacity .e-container .e-slider-preview .e-preview-container,.e-bigger.e-hide-opacity .e-container .e-slider-preview .e-preview-container{vertical-align:initial}.e-bigger .e-hide-opacity .e-container .e-float-input:first-child,.e-bigger.e-hide-opacity .e-container .e-float-input:first-child{width:36%}.e-bigger .e-hide-opacity .e-container .e-float-input.e-numeric,.e-bigger.e-hide-opacity .e-container .e-float-input.e-numeric{width:16.76%}.e-bigger.e-hide-hex-value .e-container .e-float-input.e-numeric,.e-bigger .e-hide-hex-value .e-container .e-float-input.e-numeric{width:21.58%}.e-bigger.e-hide-hex-value.e-hide-opacity .e-container .e-float-input.e-numeric,.e-bigger .e-hide-hex-value.e-hide-opacity .e-container .e-float-input.e-numeric{width:29.59%}.e-bigger.e-hide-valueswitcher .e-container .e-input-container,.e-bigger .e-hide-valueswitcher .e-container .e-input-container{width:100%}.e-bigger.e-hide-valueswitcher .e-container .e-float-input:last-child,.e-bigger .e-hide-valueswitcher .e-container .e-float-input:last-child{margin-right:0}.e-bigger.e-hide-valueswitcher .e-container .e-float-input.e-numeric,.e-bigger .e-hide-valueswitcher .e-container .e-float-input.e-numeric{width:13.2%}.e-bigger.e-hide-valueswitcher.e-hide-opacity .e-container .e-float-input:first-child,.e-bigger .e-hide-valueswitcher.e-hide-opacity .e-container .e-float-input:first-child{width:36%}.e-bigger.e-hide-valueswitcher.e-hide-opacity .e-container .e-float-input.e-numeric,.e-bigger .e-hide-valueswitcher.e-hide-opacity .e-container .e-float-input.e-numeric{width:17.9%}.e-bigger.e-hide-valueswitcher.e-hide-hex-value .e-container .e-float-input.e-numeric,.e-bigger.e-hide-valueswitcher .e-hide-hex-value .e-container .e-float-input.e-numeric,.e-bigger .e-hide-valueswitcher.e-hide-hex-value .e-container .e-float-input.e-numeric,.e-bigger .e-hide-valueswitcher .e-hide-hex-value .e-container .e-float-input.e-numeric{width:21.58%}.e-bigger.e-hide-valueswitcher.e-hide-hex-value.e-hide-opacity .e-container .e-float-input.e-numeric,.e-bigger.e-hide-valueswitcher .e-hide-hex-value.e-hide-opacity .e-container .e-float-input.e-numeric,.e-bigger .e-hide-valueswitcher.e-hide-hex-value.e-hide-opacity .e-container .e-float-input.e-numeric,.e-bigger .e-hide-valueswitcher .e-hide-hex-value.e-hide-opacity .e-container .e-float-input.e-numeric{width:31%}.e-bigger .e-rtl .e-container .e-slider-preview .e-preview-container,.e-bigger.e-rtl .e-container .e-slider-preview .e-preview-container{margin-left:0;margin-right:4.657%}.e-bigger .e-rtl .e-container .e-selected-value .e-float-input,.e-bigger.e-rtl .e-container .e-selected-value .e-float-input{margin-left:3.425%;margin-right:0}.e-bigger .e-rtl .e-container.sf-colorpicker .e-selected-value .e-input-container .e-float-input,.e-bigger.e-rtl .e-container.sf-colorpicker .e-selected-value .e-input-container .e-float-input{margin-left:calc(3.425% - 2.38px)}.e-bigger .e-rtl.e-hide-valueswitcher .e-container .e-float-input:last-child,.e-bigger.e-rtl.e-hide-valueswitcher .e-container .e-float-input:last-child{margin-left:0}.e-bigger.e-hide-switchable-value .e-container .e-input-container .e-float-input:first-child,.e-bigger .e-hide-switchable-value .e-container .e-input-container .e-float-input:first-child{width:100%}.e-bigger .e-popup.e-tooltip-wrap.e-color-picker-tooltip,.e-bigger.e-popup.e-tooltip-wrap.e-color-picker-tooltip{min-width:32px}.e-bigger .e-popup.e-tooltip-wrap.e-color-picker-tooltip .e-tip-content,.e-bigger.e-popup.e-tooltip-wrap.e-color-picker-tooltip .e-tip-content{height:30px;width:30px}.e-rating-container{display:inline-flex;flex-wrap:wrap;justify-content:center;align-items:center;min-width:max-content}.e-rating-container .e-rating{display:none}.e-rating-container .e-rating-item-list{display:inline-flex;padding:0;margin:4px}.e-rating-container .e-rating-item-list:focus-visible:not(:hover) .e-rating-focus:not(:has(svg)),.e-rating-container .e-rating-item-list:focus-visible:not(:hover) .e-rating-focus .e-rating-item:has(svg){outline:1px solid}.e-rating-container .e-rating-item-list:focus-visible{outline:none}.e-rating-container.e-rating-readonly{cursor:default;pointer-events:none}.e-rating-container .e-rating-item-container{cursor:pointer;font-size:20px;padding:4px;display:block;min-width:calc(1em + 8px);min-height:calc(1em + 8px);position:relative}.e-rating-container .e-rating-item-container:has(svg){line-height:13px}.e-rating-container .e-rating-item-container .e-rating-item{display:block}.e-rating-container.e-rating-animation.e-touch-select:not(.e-disabled) .e-rating-item-container.e-rating-focus .e-rating-item,.e-rating-container.e-rating-animation:not(.e-disabled,.e-rating-touch) .e-rating-item-container:hover .e-rating-item{transition:transform .15s cubic-bezier(.4,0,.2,1) 0ms;transform:scale(1.4);pointer-events:none}.e-rating-container.e-disabled{cursor:default;pointer-events:none}.e-rating-container.e-rating-hidden{display:none}.e-rating-container .e-reset{cursor:pointer;margin:auto 2px 6px;font-size:16px;padding:2px}.e-rating-container .e-reset.e-disabled{cursor:default}.e-rating-container .e-reset:focus-visible{outline:1px solid;border-radius:0}.e-rating-container .e-rating-label{font-size:12px;line-height:18px}.e-rating-container .e-rating-label.e-label-right,.e-rating-container .e-rating-label.e-label-left{min-width:50px}.e-rating-container .e-rating-label.e-label-bottom,.e-rating-container .e-rating-label.e-label-top{flex-basis:100%;width:0;text-align:center}.e-rating-container .e-rating-label.e-label-right{text-align:left;margin:auto 8px}.e-rating-container .e-rating-label.e-label-left{text-align:right;margin:auto 4px}.e-rating-container .e-rating-label.e-label-top,.e-rating-container .e-rating-label.e-label-bottom{margin:4px 0}.e-rating-container.e-rtl .e-rating-label.e-label-right{text-align:right}.e-rating-container.e-rtl .e-rating-label.e-label-left{text-align:left}.e-rating-container .e-tooltip-wrap.e-rating-tooltip{display:none;justify-content:center;left:50%;top:-8px;transform:translate(-50%,-100%)}.e-rating-container .e-tooltip-wrap.e-rating-tooltip.e-show-tooltip{display:inline-flex}.e-rating-container .e-tooltip-wrap.e-rating-tooltip .e-tip-content{width:max-content}.e-rating-container .e-tooltip-wrap.e-rating-tooltip .e-arrow-tip.e-tip-bottom{left:50%;top:100%;transform:translate(-50%)}.e-rating-container .e-tooltip-wrap.e-rating-tooltip .e-arrow-tip-inner.e-tip-bottom{top:-6px}.e-rating-tooltip .e-tip-content{text-align:center}.e-small.e-rating-container .e-rating-item-container,.e-small .e-rating-container .e-rating-item-container{font-size:16px}.e-small.e-rating-container .e-rating-item-container:has(svg),.e-small .e-rating-container .e-rating-item-container:has(svg){line-height:9px}.e-small.e-rating-container .e-rating-label,.e-small .e-rating-container .e-rating-label{font-size:10px;line-height:16px}.e-small.e-rating-container .e-reset,.e-small .e-rating-container .e-reset{font-size:12px}.e-rating-container .e-rating-item-list:focus-visible:not(:hover) .e-rating-focus:not(:has(svg)),.e-rating-container .e-rating-item-list:focus-visible:not(:hover) .e-rating-focus .e-rating-item:has(svg){outline-color:#3f51b5;border-radius:0}.e-rating-container .e-reset{color:#424242}.e-rating-container .e-reset:hover{color:#212121}.e-rating-container .e-reset.e-disabled{color:#9e9e9e;opacity:1}.e-rating-container .e-rating-item-container .e-rating-icon{-webkit-text-fill-color:transparent;-webkit-text-stroke:1px #9e9e9e;background:none}.e-rating-container .e-rating-item-container.e-rating-selected .e-rating-icon,.e-rating-container .e-rating-item-container.e-rating-intermediate .e-rating-icon{background:linear-gradient(to right,#212121 var(--rating-value),transparent var(--rating-value));background-clip:text;-webkit-background-clip:text;-webkit-text-stroke:1px #212121}.e-rating-container .e-rating-item-container.e-selected-value .e-rating-icon{-webkit-text-stroke:1px #3f51b5}.e-rating-container .e-rating-item-list:hover .e-rating-item-container.e-rating-selected .e-rating-icon,.e-rating-container .e-rating-item-list:hover .e-rating-item-container.e-rating-intermediate .e-rating-icon{background:linear-gradient(to right,#3f51b5 var(--rating-value),transparent var(--rating-value));background-clip:text;-webkit-background-clip:text;-webkit-text-stroke:1px #3f51b5}.e-rating-container .e-rating-item-list .e-rating-item-container.e-rating-selected:active .e-rating-icon,.e-rating-container .e-rating-item-list .e-rating-item-container.e-rating-intermediate:active .e-rating-icon{background:linear-gradient(to right,#7986cb var(--rating-value),transparent var(--rating-value));background-clip:text;-webkit-background-clip:text;-webkit-text-stroke:1px #7986cb}.e-rating-container.e-rtl .e-rating-item-container.e-rating-selected .e-rating-icon,.e-rating-container.e-rtl .e-rating-item-container.e-rating-intermediate .e-rating-icon{background:linear-gradient(to left,#212121 var(--rating-value),transparent var(--rating-value));background-clip:text;-webkit-background-clip:text}.e-rating-container.e-rtl .e-rating-item-list:hover .e-rating-item-container.e-rating-selected .e-rating-icon,.e-rating-container.e-rtl .e-rating-item-list:hover .e-rating-item-container.e-rating-intermediate .e-rating-icon{background:linear-gradient(to left,#3f51b5 var(--rating-value),transparent var(--rating-value));background-clip:text;-webkit-background-clip:text}.e-rating-container.e-rtl .e-rating-item-list .e-rating-item-container.e-rating-selected:active .e-rating-icon,.e-rating-container.e-rtl .e-rating-item-list .e-rating-item-container.e-rating-intermediate:active .e-rating-icon{background:linear-gradient(to left,#7986cb var(--rating-value),transparent var(--rating-value));background-clip:text;-webkit-background-clip:text}.e-rating-container.e-disabled{opacity:1}.e-rating-container.e-disabled .e-rating-item-container .e-rating-icon{-webkit-text-stroke:1px #9e9e9e}.e-rating-container.e-disabled .e-rating-item-container.e-rating-selected .e-rating-icon,.e-rating-container.e-disabled .e-rating-item-container.e-rating-intermediate .e-rating-icon{background:linear-gradient(to right,#9e9e9e var(--rating-value),transparent var(--rating-value));background-clip:text;-webkit-background-clip:text;-webkit-text-stroke:1px #9e9e9e}.e-rating-container.e-disabled.e-rtl .e-rating-item-container .e-rating-icon,.e-rating-container.e-disabled.e-rtl .e-rating-item-container.e-rating-selected .e-rating-icon,.e-rating-container.e-disabled.e-rtl .e-rating-item-container.e-rating-intermediate .e-rating-icon{background:linear-gradient(to left,#9e9e9e var(--rating-value),transparent var(--rating-value));background-clip:text;-webkit-background-clip:text}.e-bigger.e-rating-container .e-rating-item-container,.e-bigger .e-rating-container .e-rating-item-container{font-size:32px}.e-bigger.e-rating-container .e-rating-item-container:has(svg),.e-bigger .e-rating-container .e-rating-item-container:has(svg){line-height:21px}.e-bigger.e-rating-container .e-rating-label,.e-bigger .e-rating-container .e-rating-label{font-size:14px;line-height:22px}.e-bigger.e-rating-container .e-reset,.e-bigger .e-rating-container .e-reset{font-size:28px}.e-bigger.e-small.e-rating-container .e-rating-item-container,.e-bigger.e-small .e-rating-container .e-rating-item-container,.e-bigger .e-small.e-rating-container .e-rating-item-container,.e-small .e-bigger.e-rating-container .e-rating-item-container{font-size:24px}.e-bigger.e-small.e-rating-container .e-rating-item-container:has(svg),.e-bigger.e-small .e-rating-container .e-rating-item-container:has(svg),.e-bigger .e-small.e-rating-container .e-rating-item-container:has(svg),.e-small .e-bigger.e-rating-container .e-rating-item-container:has(svg){line-height:17px}.e-bigger.e-small.e-rating-container .e-rating-label,.e-bigger.e-small .e-rating-container .e-rating-label,.e-bigger .e-small.e-rating-container .e-rating-label,.e-small .e-bigger.e-rating-container .e-rating-label{font-size:12px;line-height:18px}.e-bigger.e-small.e-rating-container .e-reset,.e-bigger.e-small .e-rating-container .e-reset,.e-bigger .e-small.e-rating-container .e-reset,.e-small .e-bigger.e-rating-container .e-reset{font-size:20px}/*! Form material theme wise override definitions and variables *//*! data-form layout */.e-data-form .e-form-label{font-size:12px;margin-bottom:4px;font-weight:400}.e-data-form .e-form-layout{display:grid}.e-data-form .e-grid-col-2{grid-template-columns:repeat(2,minmax(0,1fr))}.e-data-form .e-grid-col-3{grid-template-columns:repeat(3,minmax(0,1fr))}.e-data-form .e-grid-col-4{grid-template-columns:repeat(4,minmax(0,1fr))}.e-data-form .e-grid-col-5{grid-template-columns:repeat(5,minmax(0,1fr))}.e-data-form .e-grid-col-6{grid-template-columns:repeat(6,minmax(0,1fr))}.e-data-form .e-grid-col-7{grid-template-columns:repeat(7,minmax(0,1fr))}.e-data-form .e-grid-col-8{grid-template-columns:repeat(8,minmax(0,1fr))}.e-data-form .e-grid-col-9{grid-template-columns:repeat(9,minmax(0,1fr))}.e-data-form .e-grid-col-10{grid-template-columns:repeat(10,minmax(0,1fr))}.e-data-form .e-grid-col-11{grid-template-columns:repeat(11,minmax(0,1fr))}.e-data-form .e-grid-col-12{grid-template-columns:repeat(12,minmax(0,1fr))}.e-data-form .e-colspan-1{grid-column:span 1/span 1}.e-data-form .e-colspan-2{grid-column:span 2/span 2}.e-data-form .e-colspan-3{grid-column:span 3/span 3}.e-data-form .e-colspan-4{grid-column:span 4/span 4}.e-data-form .e-colspan-5{grid-column:span 5/span 5}.e-data-form .e-colspan-6{grid-column:span 6/span 6}.e-data-form .e-colspan-7{grid-column:span 7/span 7}.e-data-form .e-colspan-8{grid-column:span 8/span 8}.e-data-form .e-colspan-9{grid-column:span 9/span 9}.e-data-form .e-colspan-10{grid-column:span 10/span 10}.e-data-form .e-colspan-11{grid-column:span 11/span 11}.e-data-form .e-colspan-12{grid-column:span 12/span 12}.e-data-form .e-label-position-left .e-form-item-wrapper{flex:1 1 auto;max-width:calc(75% - 12px)}.e-data-form .e-label-position-left .e-form-label{margin-right:12px;width:25%;text-align:end;flex-direction:column;align-items:flex-end;justify-content:flex-start}.e-data-form .e-label-position-left .validation-message{display:flex}.e-data-form .e-form-group{border:none;padding:0;margin:20px 0 0}.e-data-form .e-form-group .e-group-title{position:relative;display:inline-block;padding-bottom:8px;margin-bottom:4px;font-size:16px}.e-data-form .e-form-group .e-group-title:after{content:"";position:absolute;bottom:0;left:0;width:100%;height:1px;border-bottom:1px solid #c4c7c5}.e-data-form .e-label-position-top{display:flex;flex-direction:column;margin-top:20px}.e-data-form .e-label-position-top .e-label-right{display:flex;align-items:center}.e-data-form .e-label-position-top .e-label-right .e-switch-wrapper+.e-form-label{margin-top:3px;margin-left:5px}.e-data-form .e-label-position-top .e-label-right .e-checkbox-wrapper+.e-form-label{margin-top:6px}.e-data-form .e-label-position-left{display:flex;text-align:center;margin-top:20px}.e-data-form .e-button-left{justify-content:flex-start}.e-data-form .e-button-right{justify-content:flex-end}.e-data-form .e-button-center{justify-content:center}.e-data-form .e-button-left,.e-data-form .e-button-right,.e-data-form .e-button-center,.e-data-form .e-button-stretch{margin-top:24px;display:flex;gap:10px}.e-data-form .e-button-left .e-btn,.e-data-form .e-button-right .e-btn,.e-data-form .e-button-center .e-btn,.e-data-form .e-button-stretch .e-btn{border-radius:20px;padding:7px 16px}.e-data-form .e-button-stretch .e-btn{width:100%}.e-data-form>:first-child.e-form-layout{margin-top:0}/*! data-form theme */.e-data-form .e-form-label,.e-data-form .e-group-title{color:#0000008a}.e-data-form .validation-message{color:#ba160a;font-size:12px;font-style:italic}.e-tooltip-wrap.e-popup.e-error-tooltip{background-color:#fde1df;border:#fde1df}.e-tooltip-wrap.e-popup.e-error-tooltip .e-tip-content .validation-message{color:#ba160a}.e-tooltip-wrap.e-popup.e-error-tooltip .e-arrow-tip .e-arrow-tip-outer.e-tip-top,.e-tooltip-wrap.e-popup.e-error-tooltip .e-arrow-tip .e-arrow-tip-inner.e-tip-top{border-bottom-color:#fde1df;color:#fde1df}.e-otpinput{display:flex;justify-content:center;align-items:center;gap:14px;flex-direction:row}.e-otpinput:has(.e-otp-separator):not(:empty){gap:6px}.e-otpinput .e-otp-input-field{min-width:32px;min-height:32px;text-align:center;padding:0;font-size:14px;font-weight:400;line-height:22px;border:none}.e-otpinput .e-otp-input-fieldinput[type=password],.e-otpinput .e-otp-input-field[type=password]{font-size:18px}.e-otpinput .e-otp-input-field.e-input.e-otp-input-focus:focus{padding-bottom:0}.e-otpinput.e-outline .e-otp-input-field{border-radius:4px}.e-otpinput.e-underlined .e-otp-input-field{border-radius:0}.e-otpinput.e-filled .e-otp-input-field{border-radius:4px 4px 0 0;padding:0}.e-otpinput .e-otp-separator{font-size:14px;font-weight:400;line-height:22px}.e-otpinput input[type=number]::-webkit-inner-spin-button,.e-otpinput [type=number]::-webkit-outer-spin-button{-webkit-appearance:none;margin:0}.e-otpinput input[type=number]{-moz-appearance:textfield}.e-small.e-otpinput,.e-small .e-otpinput{gap:8px}.e-small.e-otpinput:has(.e-otp-separator):not(:empty),.e-small .e-otpinput:has(.e-otp-separator):not(:empty){gap:4px}.e-small.e-otpinput .e-otp-input-field,.e-small .e-otpinput .e-otp-input-field{min-width:26px;min-height:26px;font-size:12px;line-height:18px;padding:0}.e-small.e-otpinput .e-otp-input-fieldinput[type=password],.e-small.e-otpinput .e-otp-input-field[type=password],.e-small .e-otpinput .e-otp-input-fieldinput[type=password],.e-small .e-otpinput .e-otp-input-field[type=password]{font-size:18px}.e-small.e-otpinput .e-otp-input-field.e-input.e-otp-input-focus:focus,.e-small .e-otpinput .e-otp-input-field.e-input.e-otp-input-focus:focus{padding-bottom:0}.e-small.e-otpinput .e-otp-separator,.e-small .e-otpinput .e-otp-separator{font-size:12px;line-height:18px}.e-small.e-otpinput.e-filled .e-otp-input-field,.e-small .e-otpinput.e-filled .e-otp-input-field{padding:0}.e-otpinput .e-otp-input-field{color:#000000de;background:transparent}.e-otpinput .e-otp-separator{color:#bdbdbd}.e-otpinput.e-outline .e-otp-input-field{border:1px solid #bdbdbd}.e-otpinput.e-outline .e-otp-input-field,.e-otpinput.e-underlined .e-otp-input-field,.e-otpinput.e-filled .e-otp-input-field{border-bottom:2px solid #bdbdbd}.e-otpinput.e-outline .e-otp-input-field:disabled,.e-otpinput.e-underlined .e-otp-input-field:disabled,.e-otpinput.e-filled .e-otp-input-field:disabled{border-color:#e0e0e0;color:#00000061;background:transparent}.e-otpinput.e-filled .e-otp-input-field{background:#f5f5f5}.e-otpinput.e-underlined .e-otp-input-field{background:transparent}.e-otpinput.e-error.e-outline .e-otp-input-field,.e-otpinput.e-error.e-outline .e-otp-input-field.e-otp-input-focus,.e-otpinput.e-error.e-underlined .e-otp-input-field,.e-otpinput.e-error.e-underlined .e-otp-input-field.e-otp-input-focus,.e-otpinput.e-error.e-filled .e-otp-input-field,.e-otpinput.e-error.e-filled .e-otp-input-field.e-otp-input-focus{border-color:#f44336}.e-otpinput.e-success.e-outline .e-otp-input-field,.e-otpinput.e-success.e-outline .e-otp-input-field.e-otp-input-focus,.e-otpinput.e-success.e-underlined .e-otp-input-field,.e-otpinput.e-success.e-underlined .e-otp-input-field.e-otp-input-focus,.e-otpinput.e-success.e-filled .e-otp-input-field,.e-otpinput.e-success.e-filled .e-otp-input-field.e-otp-input-focus{border-color:#4d831e}.e-otpinput.e-warning.e-outline .e-otp-input-field,.e-otpinput.e-warning.e-outline .e-otp-input-field.e-otp-input-focus,.e-otpinput.e-warning.e-underlined .e-otp-input-field,.e-otpinput.e-warning.e-underlined .e-otp-input-field.e-otp-input-focus,.e-otpinput.e-warning.e-filled .e-otp-input-field,.e-otpinput.e-warning.e-filled .e-otp-input-field.e-otp-input-focus{border-color:#c15601}.e-bigger.e-otpinput,.e-bigger .e-otpinput{gap:16px}.e-bigger.e-otpinput:has(.e-otp-separator):not(:empty),.e-bigger .e-otpinput:has(.e-otp-separator):not(:empty){gap:8px}.e-bigger.e-otpinput .e-otp-input-field,.e-bigger .e-otpinput .e-otp-input-field{min-width:40px;min-height:40px;font-size:16px;line-height:24px;padding:0}.e-bigger.e-otpinput .e-otp-input-fieldinput[type=password],.e-bigger.e-otpinput .e-otp-input-field[type=password],.e-bigger .e-otpinput .e-otp-input-fieldinput[type=password],.e-bigger .e-otpinput .e-otp-input-field[type=password]{font-size:20px}.e-bigger.e-otpinput .e-otp-input-field.e-input.e-otp-input-focus:focus,.e-bigger .e-otpinput .e-otp-input-field.e-input.e-otp-input-focus:focus{padding-bottom:0}.e-bigger.e-otpinput .e-otp-separator,.e-bigger .e-otpinput .e-otp-separator{font-size:16px;line-height:24px}.e-bigger.e-otpinput.e-filled .e-otp-input-field,.e-bigger .e-otpinput.e-filled .e-otp-input-field{padding:0}.e-bigger.e-small.e-otpinput,.e-bigger.e-small .e-otpinput,.e-bigger .e-small.e-otpinput,.e-small .e-bigger.e-otpinput{gap:16px}.e-bigger.e-small.e-otpinput:has(.e-otp-separator):not(:empty),.e-bigger.e-small .e-otpinput:has(.e-otp-separator):not(:empty),.e-bigger .e-small.e-otpinput:has(.e-otp-separator):not(:empty),.e-small .e-bigger.e-otpinput:has(.e-otp-separator):not(:empty){gap:6px}.e-bigger.e-small.e-otpinput .e-otp-input-field,.e-bigger.e-small .e-otpinput .e-otp-input-field,.e-bigger .e-small.e-otpinput .e-otp-input-field,.e-small .e-bigger.e-otpinput .e-otp-input-field{min-width:36px;min-height:36px;font-size:16px;line-height:24px;padding:0}.e-bigger.e-small.e-otpinput .e-otp-input-fieldinput[type=password],.e-bigger.e-small.e-otpinput .e-otp-input-field[type=password],.e-bigger.e-small .e-otpinput .e-otp-input-fieldinput[type=password],.e-bigger.e-small .e-otpinput .e-otp-input-field[type=password],.e-bigger .e-small.e-otpinput .e-otp-input-fieldinput[type=password],.e-bigger .e-small.e-otpinput .e-otp-input-field[type=password],.e-small .e-bigger.e-otpinput .e-otp-input-fieldinput[type=password],.e-small .e-bigger.e-otpinput .e-otp-input-field[type=password]{font-size:20px}.e-bigger.e-small.e-otpinput .e-otp-input-field.e-input.e-otp-input-focus:focus,.e-bigger.e-small .e-otpinput .e-otp-input-field.e-input.e-otp-input-focus:focus,.e-bigger .e-small.e-otpinput .e-otp-input-field.e-input.e-otp-input-focus:focus,.e-small .e-bigger.e-otpinput .e-otp-input-field.e-input.e-otp-input-focus:focus{padding-bottom:0}.e-bigger.e-small.e-otpinput .e-otp-separator,.e-bigger.e-small .e-otpinput .e-otp-separator,.e-bigger .e-small.e-otpinput .e-otp-separator,.e-small .e-bigger.e-otpinput .e-otp-separator{font-size:16px;line-height:24px}.e-bigger.e-small.e-otpinput.e-filled .e-otp-input-field,.e-bigger.e-small .e-otpinput.e-filled .e-otp-input-field,.e-bigger .e-small.e-otpinput.e-filled .e-otp-input-field,.e-small .e-bigger.e-otpinput.e-filled .e-otp-input-field{padding:0}.smart-textarea-suggestion-overlay{display:none;position:absolute;padding:.25rem .75rem;border-radius:.3rem;cursor:pointer;-webkit-user-select:none;user-select:none;margin-right:.5rem}.smart-textarea-suggestion-overlay.smart-textarea-suggestion-overlay-visible{display:block}.smart-textarea-caret{position:absolute;width:.8px;display:none;animation:caret-blink 1.025s step-end infinite}@keyframes caret-blink{0%,to{opacity:1}50%{opacity:0}}.smart-textarea-suggestion-overlay{background-color:#fff;color:#000;box-shadow:0 1.25px 4px #0006}[data-suggestion-visible]::selection{color:#999!important;background:none!important}.smart-textarea-caret{background:red}/*! calendar material theme variables */.e-calendar .e-header .e-date-icon-prev:before{content:"\e910"}.e-calendar .e-header .e-date-icon-next:before{content:"\e916"}/*! calendar layout */ejs-calendar{display:block}.e-calendar.e-disabled .e-header .e-prev,.e-calendar.e-disabled .e-header .e-next,.e-calendar.e-disabled .e-header .e-title{cursor:default;pointer-events:none;touch-action:none}.e-calendar.e-disabled .e-content td,.e-calendar.e-disabled .e-btn.e-today{pointer-events:none;touch-action:none}.e-calendar{-webkit-tap-highlight-color:transparent;border-radius:2px;display:block;overflow:auto;-webkit-user-select:none;user-select:none}.e-calendar.e-rtl .e-header .e-title{float:right;text-align:right}.e-calendar.e-rtl .e-header .e-icon-container{float:left}.e-calendar .e-header{background:none;display:table;font-weight:500;position:relative;text-align:center;width:100%}.e-calendar .e-header button{background:transparent;border:0;margin-right:0;padding:0;text-decoration:none}.e-calendar .e-header span{cursor:pointer;display:inline-block;font-size:15px;font-weight:500;line-height:16px;padding:10px;vertical-align:middle}.e-calendar .e-header span.e-disabled{cursor:default}.e-calendar .e-week-header{padding:0}.e-calendar th{cursor:default;font-size:13px;font-weight:400;text-align:center}.e-calendar .e-content span.e-day{border-radius:0;cursor:pointer;display:inline-block;font-size:13px;overflow:hidden;padding:0;text-align:center;text-decoration:none;vertical-align:middle}.e-calendar .e-content th,.e-calendar .e-content td{box-sizing:border-box}.e-calendar .e-content td.e-disabled{opacity:.35;pointer-events:none;touch-action:none}.e-calendar .e-content td.e-disabled.e-today{opacity:1}.e-calendar .e-content td.e-disabled.e-today span.e-day{box-shadow:inset 1px 0 #e3165b,inset 0 1px #e3165b,inset -1px 0 #e3165b,inset 0 -1px #e3165b;color:#ccc}.e-calendar .e-content td{cursor:pointer;padding:2px;text-align:center}.e-calendar .e-content td.e-week-number{color:#000000de;font-size:12px;font-style:italic;font-weight:500}.e-calendar .e-content td.e-overlay{background:none;width:initial}.e-calendar .e-content table{border-collapse:separate;border-spacing:0;border-width:0;float:left;margin:0;outline:0;padding:0 10px 10px;table-layout:fixed;width:100%}.e-calendar .e-content td.e-other-month>span.e-day,.e-calendar .e-content td.e-other-year>span.e-day{display:none;font-weight:400}.e-calendar .e-content tr.e-month-hide{display:none;font-weight:400}.e-calendar .e-content tr.e-month-hide,.e-calendar .e-content td.e-other-month,.e-calendar .e-content td.e-other-year,.e-calendar .e-content td.e-other-month.e-disabled,.e-calendar .e-content td.e-other-year.e-disabled{pointer-events:none;touch-action:none}.e-calendar .e-content td.e-week-number:hover span.e-day,.e-calendar .e-content td.e-week-number:hover{background-color:#fff;cursor:default}.e-calendar .e-header .e-prev,.e-calendar .e-header .e-next{border-radius:50%;display:inline-block;font-size:14px;vertical-align:middle}.e-calendar .e-header .e-title{cursor:pointer;display:inline-block;float:left;font-size:14px;font-weight:500;text-align:left;padding:0 5px;border:none;border-radius:4px}.e-calendar .e-header .e-title{margin-left:5px}.e-calendar .e-header .e-prev:hover,.e-calendar .e-header .e-next:hover{cursor:pointer}.e-calendar .e-header .e-prev.e-overlay,.e-calendar .e-header .e-next.e-overlay{background:none}.e-calendar .e-header.e-decade .e-title,.e-calendar .e-header.e-year .e-title{margin-left:5px}.e-calendar .e-header.e-decade .e-title{cursor:default}.e-calendar .e-header .e-icon-container{display:inline-block;float:right;padding-top:0}.e-calendar .e-footer-container{text-transform:uppercase}.e-calendar{border-spacing:0;max-width:246px;min-width:240px;padding:0}.e-calendar.e-calendar-day-header-lg{max-width:100%;min-width:540px}.e-calendar.e-week-number{min-width:262px}.e-calendar.e-week{max-width:246px;min-width:240px}.e-calendar .e-header .e-title{line-height:40px}.e-calendar.e-rtl .e-header .e-title{text-align:right;text-indent:4px}.e-calendar .e-header{height:40px}.e-calendar .e-header.e-month,.e-calendar .e-header.e-year,.e-calendar .e-header.e-decade{padding:10px 10px 0}.e-calendar th{font-weight:400;height:30px;text-transform:none}.e-calendar .e-content .e-selected,.e-calendar .e-content .e-state-hover{border-radius:0}.e-calendar .e-content span.e-day{border:none;font-size:13px;font-weight:400;height:30px;line-height:30px;width:30px}.e-calendar .e-content.e-month td.e-today span.e-day{line-height:30px}.e-calendar .e-content.e-year table,.e-calendar .e-content.e-decade table{border-spacing:0;padding:10px}.e-calendar .e-content.e-month td{height:30px;padding:2px}.e-calendar .e-content .tfooter>tr>td{height:36px;line-height:36px}.e-calendar .e-content.e-year td,.e-calendar .e-content.e-decade td{height:45px;padding:6px}.e-calendar .e-content.e-year td>span.e-day,.e-calendar .e-content.e-decade td>span.e-day{font-weight:400;height:45px;line-height:45px;width:45px}.e-calendar .e-header .e-icon-container .e-prev,.e-calendar .e-header .e-icon-container .e-next{height:36px;width:36px}.e-calendar .e-footer-container{background-color:#fff;border-top:none;cursor:default;display:flex;flex-direction:row;justify-content:flex-end;padding:0 10px 10px;text-align:center;width:100%}.e-small.e-calendar,.e-small .e-calendar{max-width:246px;min-width:240px;padding:0;min-height:220px}.e-small.e-calendar.e-calendar-day-header-lg,.e-small .e-calendar.e-calendar-day-header-lg{max-width:100%;min-width:540px}.e-small.e-calendar .e-content span.e-day,.e-small .e-calendar .e-content span.e-day{font-size:12px;height:24px;line-height:24px;width:24px}.e-small.e-calendar .e-content.e-month td.e-today span.e-day,.e-small .e-calendar .e-content.e-month td.e-today span.e-day{line-height:22px}.e-small.e-calendar .e-content.e-month td,.e-small .e-calendar .e-content.e-month td{height:24px}.e-small.e-calendar .e-header,.e-small .e-calendar .e-header{height:32px}.e-small.e-calendar .e-header button span,.e-small .e-calendar .e-header button span{font-size:12px;padding:6px;line-height:14px}.e-small.e-calendar .e-header .e-title,.e-small .e-calendar .e-header .e-title{font-size:13px;line-height:32px}.e-small.e-calendar .e-header .e-icon-container .e-prev,.e-small.e-calendar .e-header .e-icon-container .e-next,.e-small .e-calendar .e-header .e-icon-container .e-prev,.e-small .e-calendar .e-header .e-icon-container .e-next{height:28px;width:28px}.e-small.e-calendar th,.e-small .e-calendar th{font-size:12px;height:24px}.e-calendar .e-btn.e-today.e-flat.e-disabled,.e-calendar .e-btn.e-today.e-flat.e-disabled:hover,.e-calendar .e-btn.e-today.e-flat.e-disabled:active,.e-calendar .e-btn.e-today.e-flat.e-disabled:focus,.e-calendar .e-btn.e-today.e-flat.e-disabled:hover:active{background:transparent;border-color:transparent;box-shadow:none;color:#00000042;cursor:default;opacity:.35;outline:none;pointer-events:none;touch-action:none}.e-content-placeholder.e-calendar.e-placeholder-calendar{background-size:250px 336px;min-height:336px}.e-calendar{background-color:#fff;border:1px solid rgba(0,0,0,.12);box-shadow:none}.e-calendar .e-date-icon-prev,.e-calendar .e-date-icon-next{color:#0000008a}.e-calendar th{border-bottom:0;color:#0000008a}.e-calendar .e-header{border-bottom:0}.e-calendar .e-header a span{border:none;color:#000000bf}.e-calendar .e-header .e-title{color:#000000bf}.e-calendar .e-header .e-title:hover{background:none;cursor:pointer;text-decoration:none}.e-calendar .e-header .e-title:focus{box-shadow:0 0 0 1px #212121;background:none;text-decoration:none}.e-calendar .e-header .e-title:active{box-shadow:none;background:#fff;text-decoration:none}.e-calendar .e-header .e-prev:hover>span,.e-calendar .e-header .e-next:hover>span{border:none;color:#000000bf;cursor:pointer}.e-calendar .e-header .e-prev:hover,.e-calendar .e-header .e-next:hover{background:none}.e-calendar .e-header .e-prev:focus,.e-calendar .e-header .e-next:focus{box-shadow:0 0 0 1px #212121}.e-calendar .e-header .e-prev:active,.e-calendar .e-header .e-next:active{background:#fff;color:#fff}.e-calendar .e-header button.e-prev:active span,.e-calendar .e-header button.e-next:active span{border:none;color:#000000bf}.e-calendar .e-header.e-decade .e-title{color:#000000de;cursor:default}.e-calendar .e-header .e-next.e-disabled span,.e-calendar .e-header .e-prev.e-disabled span{color:#000000de;font-weight:400}.e-calendar .e-header .e-next.e-disabled,.e-calendar .e-header .e-prev.e-disabled{opacity:.35}.e-calendar .e-content.e-decade tr:first-child .e-cell:first-child span.e-day,.e-calendar .e-content.e-decade tr:last-child .e-cell:last-child span.e-day{color:#00000061}.e-calendar .e-content.e-decade tr:first-child .e-cell:first-child.e-selected span.e-day,.e-calendar .e-content.e-decade tr:last-child .e-cell:last-child.e-selected span.e-day{color:#fff}.e-calendar .e-content.e-decade tr:first-child .e-cell.e-disabled:first-child span.e-day,.e-calendar .e-content.e-decade tr:last-child .e-cell.e-disabled:last-child span.e-day{color:#000000de}.e-calendar .e-content.e-year td.e-selected:hover span.e-day,.e-calendar .e-content.e-decade td.e-selected:hover span.e-day{background-color:#e3165b}.e-calendar .e-content.e-year td>span.e-day,.e-calendar .e-content.e-decade td>span.e-day{background:#fff}.e-calendar .e-content .e-week-number span{color:#0000008a}.e-calendar .e-content td.e-focused-date span.e-day,.e-calendar .e-content td.e-focused-date:hover span.e-day,.e-calendar .e-content td.e-focused-date:focus span.e-day{background:#eee;border:none;border-radius:50%;box-shadow:none}.e-calendar .e-content td.e-focused-date:hover span.e-day{background-color:#eee;border:none;border-radius:50%;color:#000000de}.e-calendar .e-content td.e-today span.e-day,.e-calendar .e-content td.e-focused-date.e-today span.e-day{background:none;border:1px solid #e3165b;border-radius:50%;box-shadow:none;color:#e3165b}.e-calendar .e-content td.e-focused-date.e-today span.e-day{background:#eee;border:1px solid #e3165b;box-shadow:none;color:#e3165b}.e-calendar .e-content td.e-today:focus span.e-day,.e-calendar .e-content td.e-focused-date.e-today:focus span.e-day{background-color:#eee;border:none;border-radius:50%;color:#e3165b}.e-calendar .e-content td.e-today:hover span.e-day,.e-calendar .e-content td.e-focused-date.e-today:hover span.e-day,.e-calendar .e-content td.e-focused-date.e-today:focus span.e-day{background-color:#eee;border:1px solid #e3165b;color:#e3165b}.e-calendar .e-content td.e-today.e-selected span.e-day{background-color:#e3165b;border:1px solid #e3165b;box-shadow:inset 0 0 0 2px #fff;color:#fff}.e-calendar .e-content td.e-today.e-selected:hover span.e-day,.e-calendar .e-content td.e-selected:hover span.e-day,.e-calendar .e-content td.e-selected.e-focused-date span.e-day{background:#b51148;color:#fff}.e-calendar .e-content span{color:#000000de}.e-calendar .e-content .e-disabled span.e-day:hover{background:none;border:0;color:#000000de}.e-calendar .e-content .e-other-month:hover span.e-day,.e-calendar .e-content .e-other-month span.e-day,.e-calendar .e-content .e-other-month.e-today span.e-day{color:#00000061}.e-calendar .e-content .e-other-month.e-today:hover span.e-day{background-color:#eee;color:#00000061}.e-calendar .e-content thead{background:none;border-bottom:0}.e-calendar .e-content td:hover span.e-day,.e-calendar .e-content td:focus span.e-day{background-color:#eee;border:none;border-radius:50%;color:#000000de}.e-calendar .e-content td:focus span.e-day{background-color:#eee;color:#000000de;border:none;border-radius:50%}.e-calendar .e-content td.e-disabled span.e-day,.e-calendar .e-content td.e-disabled:hover span.e-day,.e-calendar .e-content td.e-disabled:focus span.e-day{background:none;border:none;color:#000000de}.e-calendar .e-content td.e-selected span.e-day{background-color:#e3165b;color:#fff;border:none;border-radius:50%}.e-calendar .e-content .e-footer{color:#e3165b}.e-calendar.e-device .e-prev:hover,.e-calendar.e-device .e-next:hover,.e-calendar.e-device .e-prev:active,.e-calendar.e-device .e-next:active,.e-calendar.e-device .e-prev:focus,.e-calendar.e-device .e-next:focus{background:none}.e-calendar.e-device button.e-prev:active span,.e-calendar.e-device button.e-next:active span{color:#0000008a}.e-small.e-calendar .e-header .e-title,.e-small .e-calendar .e-header .e-title{color:#000000de}.e-calendar .e-zoomin{animation:animatezoom .3s}@keyframes animatezoom{0%{transform:scale(0)}to{transform:scale(1)}}.e-calendar .e-calendar-content-table .e-cell.e-focused-cell span.e-day{box-shadow:0 0 0 1px #212121;border-radius:50%}.e-bigger.e-calendar,*.e-bigger .e-calendar{max-width:296px;min-width:296px;padding:0}.e-bigger.e-calendar.e-calendar-day-header-lg,*.e-bigger .e-calendar.e-calendar-day-header-lg{max-width:100%;min-width:540px}.e-bigger.e-calendar.e-week,*.e-bigger .e-calendar.e-week{max-width:296px;min-width:296px}.e-bigger.e-calendar.e-week-number,*.e-bigger .e-calendar.e-week-number{min-width:320px}.e-bigger.e-calendar .e-header .e-title,*.e-bigger .e-calendar .e-header .e-title{font-size:16px;line-height:48px;width:60%}.e-bigger.e-calendar.e-rtl .e-header .e-title,*.e-bigger .e-calendar.e-rtl .e-header .e-title{line-height:48px;text-indent:6px}.e-bigger.e-calendar .e-header,*.e-bigger .e-calendar .e-header{height:48px;padding:10px 10px 0 16px}.e-bigger.e-calendar .e-header button,*.e-bigger .e-calendar .e-header button{margin-right:0}.e-bigger.e-calendar .e-header button span,*.e-bigger .e-calendar .e-header button span{font-size:16px;padding:15px}.e-bigger.e-calendar .e-header.e-year,.e-bigger.e-calendar .e-header.e-decade,*.e-bigger .e-calendar .e-header.e-year,*.e-bigger .e-calendar .e-header.e-decade{padding:10px 10px 0 16px}.e-bigger.e-calendar th,*.e-bigger .e-calendar th{font-size:14px;height:36px;text-transform:none}.e-bigger.e-calendar .e-content.e-year span.e-day,*.e-bigger .e-calendar .e-content.e-year span.e-day{font-size:13px;font-weight:400}.e-bigger.e-calendar .e-content.e-month table,*.e-bigger .e-calendar .e-content.e-month table,.e-bigger.e-calendar .e-content.e-year table,.e-bigger.e-calendar .e-content.e-decade table,*.e-bigger .e-calendar .e-content.e-year table,*.e-bigger .e-calendar .e-content.e-decade table{padding:0 10px 10px}.e-bigger.e-calendar .e-content .e-selected,.e-bigger.e-calendar .e-content .e-state-hover,*.e-bigger .e-calendar .e-content .e-selected,*.e-bigger .e-calendar .e-content .e-state-hover{border-radius:0}.e-bigger.e-calendar .e-content span.e-day,*.e-bigger .e-calendar .e-content span.e-day{font-size:13px;height:36px;line-height:36px;width:36px}.e-bigger.e-calendar .e-content.e-month td.e-today span.e-day,*.e-bigger .e-calendar .e-content.e-month td.e-today span.e-day{line-height:34px}.e-bigger.e-calendar .e-content.e-month td,*.e-bigger .e-calendar .e-content.e-month td{height:2px;padding:2px}.e-bigger.e-calendar .e-content.e-year td,.e-bigger.e-calendar .e-content.e-decade td,*.e-bigger .e-calendar .e-content.e-year td,*.e-bigger .e-calendar .e-content.e-decade td{height:60px;padding:2px}.e-bigger.e-calendar .e-content.e-year td>span.e-day,.e-bigger.e-calendar .e-content.e-decade td>span.e-day,*.e-bigger .e-calendar .e-content.e-year td>span.e-day,*.e-bigger .e-calendar .e-content.e-decade td>span.e-day{height:60px;line-height:60px;width:60px}.e-bigger.e-calendar .e-header .e-icon-container .e-prev,.e-bigger.e-calendar .e-header .e-icon-container .e-next,*.e-bigger .e-calendar .e-header .e-icon-container .e-prev,*.e-bigger .e-calendar .e-header .e-icon-container .e-next{height:48px;width:48px}.e-bigger.e-calendar .e-footer-container,*.e-bigger .e-calendar .e-footer-container{border-top:none;padding:0 10px 10px}.e-bigger .e-content-placeholder.e-calendar.e-placeholder-calendar,.e-bigger.e-content-placeholder.e-calendar.e-placeholder-calendar{background-size:300px 392px;min-height:392px}.e-bigger.e-small .e-calendar{background-color:#fff;border:1px solid rgba(0,0,0,.12);box-shadow:none}.e-bigger.e-small .e-calendar .e-date-icon-prev,.e-bigger.e-small .e-calendar .e-date-icon-next{color:#0000008a}.e-bigger.e-small .e-calendar th{border-bottom:0;color:#0000008a}.e-bigger.e-small .e-calendar .e-header{border-bottom:0}.e-bigger.e-small .e-calendar .e-header a span{border:none;color:#000000bf}.e-bigger.e-small .e-calendar .e-header .e-title{color:#000000bf}.e-bigger.e-small .e-calendar .e-header .e-title:hover{background:none;cursor:pointer;text-decoration:none}.e-bigger.e-small .e-calendar .e-header .e-title:focus{box-shadow:0 0 0 1px #212121;background:none;text-decoration:none}.e-bigger.e-small .e-calendar .e-header .e-title:active{box-shadow:none;background:#fff;text-decoration:none}.e-bigger.e-small .e-calendar .e-header .e-prev:hover>span,.e-bigger.e-small .e-calendar .e-header .e-next:hover>span{border:none;color:#000000bf;cursor:pointer}.e-bigger.e-small .e-calendar .e-header .e-prev:hover,.e-bigger.e-small .e-calendar .e-header .e-next:hover{background:none}.e-bigger.e-small .e-calendar .e-header .e-prev:focus,.e-bigger.e-small .e-calendar .e-header .e-next:focus{box-shadow:0 0 0 1px #212121}.e-bigger.e-small .e-calendar .e-header .e-prev:active,.e-bigger.e-small .e-calendar .e-header .e-next:active{background:#fff;color:#fff}.e-bigger.e-small .e-calendar .e-header button.e-prev:active span,.e-bigger.e-small .e-calendar .e-header button.e-next:active span{border:none;color:#000000bf}.e-bigger.e-small .e-calendar .e-header.e-decade .e-title{color:#000000de;cursor:default}.e-bigger.e-small .e-calendar .e-header .e-next.e-disabled span,.e-bigger.e-small .e-calendar .e-header .e-prev.e-disabled span{color:#000000de;font-weight:400}.e-bigger.e-small .e-calendar .e-header .e-next.e-disabled,.e-bigger.e-small .e-calendar .e-header .e-prev.e-disabled{opacity:.35}.e-bigger.e-small .e-calendar .e-content.e-decade tr:first-child .e-cell:first-child span.e-day,.e-bigger.e-small .e-calendar .e-content.e-decade tr:last-child .e-cell:last-child span.e-day{color:#00000061}.e-bigger.e-small .e-calendar .e-content.e-decade tr:first-child .e-cell:first-child.e-selected span.e-day,.e-bigger.e-small .e-calendar .e-content.e-decade tr:last-child .e-cell:last-child.e-selected span.e-day{color:#fff}.e-bigger.e-small .e-calendar .e-content.e-decade tr:first-child .e-cell.e-disabled:first-child span.e-day,.e-bigger.e-small .e-calendar .e-content.e-decade tr:last-child .e-cell.e-disabled:last-child span.e-day{color:#000000de}.e-bigger.e-small .e-calendar .e-content.e-year td.e-selected:hover span.e-day,.e-bigger.e-small .e-calendar .e-content.e-decade td.e-selected:hover span.e-day{background-color:#e3165b}.e-bigger.e-small .e-calendar .e-content.e-year td>span.e-day,.e-bigger.e-small .e-calendar .e-content.e-decade td>span.e-day{background:#fff}.e-bigger.e-small .e-calendar .e-content .e-week-number span{color:#0000008a}.e-bigger.e-small .e-calendar .e-content td.e-focused-date span.e-day,.e-bigger.e-small .e-calendar .e-content td.e-focused-date:hover span.e-day,.e-bigger.e-small .e-calendar .e-content td.e-focused-date:focus span.e-day{background:#eee;border:none;border-radius:50%;box-shadow:none}.e-bigger.e-small .e-calendar .e-content td.e-focused-date:hover span.e-day{background-color:#eee;border:none;border-radius:50%;color:#000000de}.e-bigger.e-small .e-calendar .e-content td.e-today span.e-day,.e-bigger.e-small .e-calendar .e-content td.e-focused-date.e-today span.e-day{background:none;border:1px solid #e3165b;border-radius:50%;box-shadow:none;color:#e3165b}.e-bigger.e-small .e-calendar .e-content td.e-focused-date.e-today span.e-day{background:#eee;border:1px solid #e3165b;box-shadow:none;color:#e3165b}.e-bigger.e-small .e-calendar .e-content td.e-today:focus span.e-day,.e-bigger.e-small .e-calendar .e-content td.e-focused-date.e-today:focus span.e-day{background-color:#eee;border:none;border-radius:50%;color:#e3165b}.e-bigger.e-small .e-calendar .e-content td.e-today:hover span.e-day,.e-bigger.e-small .e-calendar .e-content td.e-focused-date.e-today:hover span.e-day,.e-bigger.e-small .e-calendar .e-content td.e-focused-date.e-today:focus span.e-day{background-color:#eee;border:1px solid #e3165b;color:#e3165b}.e-bigger.e-small .e-calendar .e-content td.e-today.e-selected span.e-day{background-color:#e3165b;border:1px solid #e3165b;box-shadow:inset 0 0 0 2px #fff;color:#fff}.e-bigger.e-small .e-calendar .e-content td.e-today.e-selected:hover span.e-day,.e-bigger.e-small .e-calendar .e-content td.e-selected:hover span.e-day,.e-bigger.e-small .e-calendar .e-content td.e-selected.e-focused-date span.e-day{background-color:#b51148;color:#fff}.e-bigger.e-small .e-calendar .e-content span{color:#000000de}.e-bigger.e-small .e-calendar .e-content .e-disabled span.e-day:hover{background:none;border:0;color:#000000de}.e-bigger.e-small .e-calendar .e-content .e-other-month:hover span.e-day,.e-bigger.e-small .e-calendar .e-content .e-other-month span.e-day,.e-bigger.e-small .e-calendar .e-content .e-other-month.e-today span.e-day{color:#00000061}.e-bigger.e-small .e-calendar .e-content .e-other-month.e-today:hover span.e-day{background-color:#eee;color:#00000061}.e-bigger.e-small .e-calendar .e-content thead{background:none;border-bottom:0}.e-bigger.e-small .e-calendar .e-content td:hover span.e-day,.e-bigger.e-small .e-calendar .e-content td:focus span.e-day{background-color:#eee;border:none;border-radius:50%;color:#000000de}.e-bigger.e-small .e-calendar .e-content td:focus span.e-day{background-color:#eee;color:#000000de;border:none;border-radius:50%}.e-bigger.e-small .e-calendar .e-content td.e-disabled span.e-day,.e-bigger.e-small .e-calendar .e-content td.e-disabled:hover span.e-day,.e-bigger.e-small .e-calendar .e-content td.e-disabled:focus span.e-day{background:none;border:none;color:#000000de}.e-bigger.e-small .e-calendar .e-content td.e-selected span.e-day{background-color:#e3165b;color:#fff;border:none;border-radius:50%}.e-bigger.e-small .e-calendar .e-content .e-footer{color:#e3165b}.e-bigger.e-small .e-calendar.e-device .e-prev:hover,.e-bigger.e-small .e-calendar.e-device .e-next:hover,.e-bigger.e-small .e-calendar.e-device .e-prev:active,.e-bigger.e-small .e-calendar.e-device .e-next:active,.e-bigger.e-small .e-calendar.e-device .e-prev:focus,.e-bigger.e-small .e-calendar.e-device .e-next:focus{background:none}.e-bigger.e-small .e-calendar.e-device button.e-prev:active span,.e-bigger.e-small .e-calendar.e-device button.e-next:active span{color:#0000008a}.e-bigger.e-small .e-calendar{-webkit-tap-highlight-color:transparent;border-radius:2px;display:block;overflow:auto;-webkit-user-select:none;user-select:none}.e-bigger.e-small .e-calendar.e-rtl .e-header .e-title{float:right;text-align:right}.e-bigger.e-small .e-calendar.e-rtl .e-header .e-icon-container{float:left}.e-bigger.e-small .e-calendar .e-header{background:none;display:table;font-weight:500;position:relative;text-align:center;width:100%}.e-bigger.e-small .e-calendar .e-header button{background:transparent;border:0;margin-right:0;padding:0;text-decoration:none}.e-bigger.e-small .e-calendar .e-header span{cursor:pointer;display:inline-block;font-size:15px;font-weight:500;line-height:16px;padding:10px;vertical-align:middle}.e-bigger.e-small .e-calendar .e-header span.e-disabled{cursor:default}.e-bigger.e-small .e-calendar .e-week-header{padding:0}.e-bigger.e-small .e-calendar th{cursor:default;font-size:13px;font-weight:400;text-align:center}.e-bigger.e-small .e-calendar .e-content span.e-day{border-radius:0;cursor:pointer;display:inline-block;font-size:13px;overflow:hidden;padding:0;text-align:center;text-decoration:none;vertical-align:middle}.e-bigger.e-small .e-calendar .e-content th,.e-bigger.e-small .e-calendar .e-content td{box-sizing:border-box}.e-bigger.e-small .e-calendar .e-content td.e-disabled{opacity:.35;pointer-events:none;touch-action:none}.e-bigger.e-small .e-calendar .e-content td.e-disabled.e-today{opacity:1}.e-bigger.e-small .e-calendar .e-content td.e-disabled.e-today span.e-day{box-shadow:inset 1px 0 #e3165b,inset 0 1px #e3165b,inset -1px 0 #e3165b,inset 0 -1px #e3165b;color:#ccc}.e-bigger.e-small .e-calendar .e-content td{cursor:pointer;padding:2px;text-align:center}.e-bigger.e-small .e-calendar .e-content td.e-week-number{color:#000000de;font-size:12px;font-style:italic;font-weight:500}.e-bigger.e-small .e-calendar .e-content td.e-overlay{background:none;width:initial}.e-bigger.e-small .e-calendar .e-content table{border-collapse:separate;border-spacing:0;border-width:0;float:left;margin:0;outline:0;padding:0 10px 10px;table-layout:fixed;width:100%}.e-bigger.e-small .e-calendar .e-content td.e-other-month>span.e-day,.e-bigger.e-small .e-calendar .e-content td.e-other-year>span.e-day{display:none;font-weight:400}.e-bigger.e-small .e-calendar .e-content tr.e-month-hide{display:none;font-weight:400}.e-bigger.e-small .e-calendar .e-content tr.e-month-hide,.e-bigger.e-small .e-calendar .e-content td.e-other-month,.e-bigger.e-small .e-calendar .e-content td.e-other-year,.e-bigger.e-small .e-calendar .e-content td.e-other-month.e-disabled,.e-bigger.e-small .e-calendar .e-content td.e-other-year.e-disabled{pointer-events:none;touch-action:none}.e-bigger.e-small .e-calendar .e-content td.e-week-number:hover span.e-day,.e-bigger.e-small .e-calendar .e-content td.e-week-number:hover{background-color:#fff;cursor:default}.e-bigger.e-small .e-calendar .e-header .e-prev,.e-bigger.e-small .e-calendar .e-header .e-next{border-radius:50%;display:inline-block;font-size:14px;vertical-align:middle}.e-bigger.e-small .e-calendar .e-header .e-title{cursor:pointer;display:inline-block;float:left;font-size:14px;font-weight:500;text-align:left;padding:0 5px;border:none;border-radius:4px}.e-bigger.e-small .e-calendar .e-header .e-title{margin-left:5px}.e-bigger.e-small .e-calendar .e-header .e-prev:hover,.e-bigger.e-small .e-calendar .e-header .e-next:hover{cursor:pointer}.e-bigger.e-small .e-calendar .e-header .e-prev.e-overlay,.e-bigger.e-small .e-calendar .e-header .e-next.e-overlay{background:none}.e-bigger.e-small .e-calendar .e-header.e-decade .e-title,.e-bigger.e-small .e-calendar .e-header.e-year .e-title{margin-left:5px}.e-bigger.e-small .e-calendar .e-header.e-decade .e-title{cursor:default}.e-bigger.e-small .e-calendar .e-header .e-icon-container{display:inline-block;float:right;padding-top:0}.e-bigger.e-small .e-calendar .e-footer-container{text-transform:uppercase}.e-bigger.e-small .e-calendar{border-spacing:0;max-width:246px;min-width:240px;padding:0}.e-bigger.e-small .e-calendar.e-calendar-day-header-lg{max-width:100%;min-width:540px}.e-bigger.e-small .e-calendar.e-week-number{min-width:262px}.e-bigger.e-small .e-calendar.e-week{max-width:246px;min-width:240px}.e-bigger.e-small .e-calendar .e-header .e-title{line-height:40px}.e-bigger.e-small .e-calendar.e-rtl .e-header .e-title{text-align:right;text-indent:4px}.e-bigger.e-small .e-calendar .e-header{height:40px}.e-bigger.e-small .e-calendar .e-header.e-month,.e-bigger.e-small .e-calendar .e-header.e-year,.e-bigger.e-small .e-calendar .e-header.e-decade{padding:10px 10px 0}.e-bigger.e-small .e-calendar th{font-weight:400;height:30px;text-transform:none}.e-bigger.e-small .e-calendar .e-content .e-selected,.e-bigger.e-small .e-calendar .e-content .e-state-hover{border-radius:0}.e-bigger.e-small .e-calendar .e-content span.e-day{border:none;font-size:13px;font-weight:400;height:30px;line-height:30px;width:30px}.e-bigger.e-small .e-calendar .e-content.e-month td.e-today span.e-day{line-height:30px}.e-bigger.e-small .e-calendar .e-content.e-year table,.e-bigger.e-small .e-calendar .e-content.e-decade table{border-spacing:0;padding:10px}.e-bigger.e-small .e-calendar .e-content.e-month td{height:30px;padding:2px}.e-bigger.e-small .e-calendar .e-content .tfooter>tr>td{height:36px;line-height:36px}.e-bigger.e-small .e-calendar .e-content.e-year td,.e-bigger.e-small .e-calendar .e-content.e-decade td{height:45px;padding:6px}.e-bigger.e-small .e-calendar .e-content.e-year td>span.e-day,.e-bigger.e-small .e-calendar .e-content.e-decade td>span.e-day{font-weight:400;height:45px;line-height:45px;width:45px}.e-bigger.e-small .e-calendar .e-header .e-icon-container .e-prev,.e-bigger.e-small .e-calendar .e-header .e-icon-container .e-next{height:36px;width:36px}.e-bigger.e-small .e-calendar .e-footer-container{background-color:#fff;border-top:none;cursor:default;display:flex;flex-direction:row;justify-content:flex-end;padding:0 10px 10px;text-align:center;width:100%}.e-small.e-bigger.e-calendar .e-content.e-year span.e-day,.e-small.e-bigger .e-calendar .e-content.e-year span.e-day{font-size:13px}.e-small.e-bigger.e-calendar .e-content.e-month table,.e-small.e-bigger .e-calendar .e-content.e-month table{padding:0 10px 10px}@keyframes e-input-ripple{to{opacity:0;transform:scale(4)}}@keyframes slideTopUp{0%{transform:translateZ(0) scale(1)}to{transform:translateZ(0) scale(1)}}.e-time-wrapper .e-time-icon.e-icons:before,*.e-control-wrapper.e-time-wrapper .e-time-icon.e-icons:before{content:"\e20c"}.e-time-wrapper.e-outline .e-input-group-icon.e-time-icon,.e-time-wrapper.e-control-wrapper.e-outline .e-input-group-icon.e-time-icon{min-height:0;min-width:20px}.e-small .e-time-wrapper.e-outline .e-input-group-icon.e-time-icon,.e-time-wrapper.e-control-wrapper.e-small.e-outline .e-input-group-icon.e-time-icon,.e-small .e-time-wrapper.e-control-wrapper.e-outline .e-input-group-icon.e-time-icon{min-height:0;min-width:18px}.e-timepicker-mob-popup-wrap .e-timepicker.e-popup-expand .e-model-header .e-popup-close:before,.e-datetimepicker.e-popup-expand .e-model-header .e-popup-close:before{content:"\e932";font-family:e-icons}.e-input-group.e-control-wrapper.e-time-wrapper.e-non-edit.e-input-focus .e-input:focus~.e-clear-icon,.e-float-input.e-control-wrapper.e-input-group.e-time-wrapper.e-non-edit.e-input-focus input:focus~.e-clear-icon{display:flex}.e-time-wrapper,*.e-control-wrapper.e-time-wrapper{-webkit-tap-highlight-color:transparent}.e-time-wrapper .e-time-icon.e-icons,*.e-control-wrapper.e-time-wrapper .e-time-icon.e-icons{font-size:16px;min-height:20px;min-width:20px}.e-time-wrapper .e-time-icon.e-icons.e-disabled,*.e-control-wrapper.e-time-wrapper .e-time-icon.e-icons.e-disabled{pointer-events:none}.e-time-wrapper span,*.e-control-wrapper.e-time-wrapper span{cursor:pointer}.e-timepicker.e-time-modal{background-color:#0009;height:100%;left:0;opacity:.5;pointer-events:auto;position:fixed;top:0;width:100%;z-index:999}.e-timepicker.e-popup{border-style:solid;border-width:1px;overflow:auto}.e-timepicker.e-popup .e-content{position:relative}.e-timepicker.e-popup .e-list-parent.e-ul{margin:0;padding:0}.e-timepicker.e-popup .e-list-parent.e-ul .e-list-item{cursor:default;font-size:13px;overflow:hidden;position:relative;text-overflow:ellipsis;vertical-align:middle;white-space:nowrap;width:100%}.e-timepicker.e-popup .e-list-parent.e-ul .e-list-item.e-hover{cursor:pointer}.e-timepicker.e-popup .e-list-parent.e-ul .e-list-item{line-height:36px;text-indent:16px}.e-small .e-timepicker.e-popup .e-list-parent.e-ul .e-list-item,*.e-small.e-timepicker.e-popup .e-list-parent.e-ul .e-list-item{font-size:12px;line-height:26px;text-indent:12px}.e-small .e-time-wrapper .e-time-icon.e-icons,*.e-small.e-time-wrapper .e-time-icon.e-icons,*.e-small .e-control-wrapper.e-time-wrapper .e-time-icon.e-icons,*.e-control-wrapper.e-small.e-time-wrapper .e-time-icon.e-icons{font-size:14px}.e-content-placeholder.e-timepicker.e-placeholder-timepicker{background-size:250px 33px;min-height:33px}.e-time-overflow{overflow:hidden}.e-timepicker-mob-popup-wrap{align-items:center;display:flex;flex-direction:column;height:100%;justify-content:center;left:0;max-height:100%;position:fixed;top:0;width:100%;z-index:1002}.e-timepicker-mob-popup-wrap .e-timepicker.e-popup.e-lib.e-control.e-popup-open{left:0!important;position:relative;top:0!important}.e-timepicker-mob-popup-wrap .e-popup-expand.e-timepicker.e-popup,.e-datetimepicker.e-popup-expand.e-timepicker.e-popup,.e-timepicker-mob-popup-wrap .e-popup-expand.e-datetimepicker.e-popup,.e-datetimepicker.e-popup-expand.e-popup{border-radius:0}.e-timepicker-mob-popup-wrap .e-popup-expand .e-model-header,.e-datetimepicker.e-popup-expand .e-model-header{height:10%;padding:2.5vh 2.5vw 2.5vh 1.5vw;display:flex;align-items:center;font-size:2vh;border-bottom:none}.e-timepicker-mob-popup-wrap .e-popup-expand .e-model-header .e-popup-close,.e-datetimepicker.e-popup-expand .e-model-header .e-popup-close{float:left;padding:1vh 2vw}.e-timepicker-mob-popup-wrap .e-popup-expand .e-model-header .e-model-title,.e-datetimepicker.e-popup-expand .e-model-header .e-model-title{padding:1vh 2vw;text-transform:uppercase;font-weight:500}.e-timepicker-mob-popup-wrap .e-popup-expand .e-model-header .e-btn.e-popup-close,.e-datetimepicker.e-popup-expand .e-model-header .e-btn.e-popup-close{font-size:2vh}.e-timepicker-mob-popup-wrap .e-popup-expand .e-content,.e-datetimepicker.e-popup-expand .e-content{height:90%;overflow:auto}.e-timepicker-mob-popup-wrap .e-popup-expand .e-content .e-list-parent.e-ul .e-list-item,.e-datetimepicker.e-popup-expand .e-content .e-list-parent.e-ul .e-list-item{padding:1vh 0;line-height:5vh}@media (max-device-width: 768px){.e-timepicker-mob-popup-wrap .e-popup-expand .e-content .e-list-parent.e-ul .e-list-item,.e-datetimepicker.e-popup-expand .e-content .e-list-parent.e-ul .e-list-item{font-size:14px}}@media (min-device-width: 768px){.e-timepicker-mob-popup-wrap .e-popup-expand .e-content .e-list-parent.e-ul .e-list-item,.e-datetimepicker.e-popup-expand .e-content .e-list-parent.e-ul .e-list-item{font-size:24px}}@media screen and (orientation: landscape){.e-timepicker-mob-popup-wrap .e-popup-expand .e-model-header,.e-datetimepicker.e-popup-expand .e-model-header{height:15%;font-size:2vw}.e-timepicker-mob-popup-wrap .e-popup-expand .e-model-header .e-popup-close,.e-datetimepicker.e-popup-expand .e-model-header .e-popup-close,.e-timepicker-mob-popup-wrap .e-popup-expand .e-model-header .e-model-title,.e-datetimepicker.e-popup-expand .e-model-header .e-model-title{padding:1vh 1vw}.e-timepicker-mob-popup-wrap .e-popup-expand .e-model-header .e-btn.e-popup-close,.e-datetimepicker.e-popup-expand .e-model-header .e-btn.e-popup-close{font-size:2vw}.e-timepicker-mob-popup-wrap .e-popup-expand .e-content,.e-datetimepicker.e-popup-expand .e-content{height:85%}.e-timepicker-mob-popup-wrap .e-popup-expand .e-content .e-list-parent.e-ul .e-list-item,.e-datetimepicker.e-popup-expand .e-content .e-list-parent.e-ul .e-list-item{padding:1vh 0;line-height:10vh}}.e-time-wrapper .e-input-group-icon.e-icons.e-active{color:#e3165b}.e-time-wrapper.e-input-group:not(.e-disabled) .e-input-group-icon.e-active:active{color:#e3165b}.e-timepicker.e-popup{background-color:#fff;border:none;border-radius:2px;box-shadow:0 5px 5px -3px #0003,0 8px 10px 1px #00000024,0 3px 14px 2px #0000001f}.e-timepicker.e-popup .e-list-parent.e-ul{background-color:#fff}.e-timepicker.e-popup .e-list-parent.e-ul li.e-list-item{border:none;color:#000000de}.e-timepicker.e-popup .e-list-parent.e-ul .e-list-item.e-disabled{color:#00000061;opacity:1;pointer-events:none;touch-action:none}.e-timepicker.e-popup .e-list-parent.e-ul .e-list-item.e-hover,.e-timepicker.e-popup .e-list-parent.e-ul .e-list-item.e-navigation,.e-timepicker.e-popup .e-list-parent.e-ul .e-list-item:focus{background-color:#eee;border:none;color:#000}.e-timepicker.e-popup .e-list-parent.e-ul .e-list-item.e-active,.e-timepicker.e-popup .e-list-parent.e-ul .e-list-item.e-active.e-hover{background-color:#eee;color:#e3165b}.e-small .e-timepicker.e-popup .e-list-parent.e-ul .e-list-item,*.e-small.e-timepicker.e-popup .e-list-parent.e-ul .e-list-item{color:#000}.e-timepicker-mob-popup-wrap .e-timepicker.e-popup-expand .e-model-header,.e-datetimepicker.e-popup-expand .e-model-header{background-color:#3f51b5;color:#fff}.e-timepicker-mob-popup-wrap .e-timepicker.e-popup-expand .e-model-header .e-popup-close,.e-datetimepicker.e-popup-expand .e-model-header .e-popup-close{color:#fff;font-weight:500}.e-bigger .e-time-wrapper .e-time-icon.e-icons,*.e-bigger.e-time-wrapper .e-time-icon.e-icons,*.e-bigger .e-control-wrapper .e-time-wrapper .e-time-icon.e-icons,*.e-control-wrapper.e-bigger.e-time-wrapper .e-time-icon.e-icons{font-size:18px;min-height:22px;min-width:22px}.e-bigger .e-timepicker.e-popup .e-list-parent.e-ul,*.e-bigger.e-timepicker.e-popup .e-list-parent.e-ul{padding:0}.e-bigger .e-timepicker.e-popup .e-list-parent.e-ul .e-list-item,*.e-bigger.e-timepicker.e-popup .e-list-parent.e-ul .e-list-item{font-size:14px;line-height:48px;text-indent:16px}.e-bigger .e-content-placeholder.e-timepicker.e-placeholder-timepicker,.e-bigger.e-content-placeholder.e-timepicker.e-placeholder-timepicker{background-size:250px 40px;min-height:40px}.e-small.e-bigger .e-timepicker.e-popup .e-list-parent.e-ul .e-list-item,*.e-small.e-bigger.e-timepicker.e-popup .e-list-parent.e-ul .e-list-item{font-size:13px;line-height:40px;text-indent:16px}.e-small.e-bigger .e-time-wrapper .e-time-icon.e-icons,*.e-small.e-bigger.e-time-wrapper .e-time-icon.e-icons,*.e-small.e-bigger .e-control-wrapper.e-time-wrapper .e-time-icon.e-icons,*.e-control-wrapper.e-small.e-bigger.e-time-wrapper .e-time-icon.e-icons{font-size:18px}.e-bigger.e-small .e-timepicker.e-popup .e-list-parent.e-ul .e-list-item,*.e-bigger.e-small.e-timepicker.e-popup .e-list-parent.e-ul .e-list-item{color:#000}.e-bigger .e-time-wrapper.e-outline .e-input-group-icon.e-time-icon,.e-time-wrapper.e-control-wrapper.e-bigger.e-outline .e-input-group-icon.e-time-icon,.e-bigger .e-time-wrapper.e-control-wrapper.e-outline .e-input-group-icon.e-time-icon{min-height:0;min-width:24px}.e-bigger.e-small .e-outline.e-time-wrapper .e-input-group-icon.e-time-icon,.e-bigger.e-small.e-outline.e-time-wrapper .e-input-group-icon.e-time-icon,.e-time-wrapper.e-control-wrapper.e-bigger.e-small.e-outline .e-input-group-icon.e-time-icon,.e-bigger.e-small .e-time-wrapper.e-control-wrapper.e-outline .e-input-group-icon.e-time-icon{min-height:0;min-width:20px}.e-input-group-icon.e-date-icon,*.e-control-wrapper .e-input-group-icon.e-date-icon{font-size:16px;margin:0 0 4px;min-height:24px;min-width:24px;outline:none}.e-input-group-icon.e-date-icon:before,*.e-control-wrapper .e-input-group-icon.e-date-icon:before{content:"\e901";font-family:e-icons}.e-input-group-icon.e-date-icon:focus,*.e-control-wrapper .e-input-group-icon.e-date-icon:focus{background:#eee;border-radius:50%}.e-small .e-input-group-icon.e-date-icon,*.e-control-wrapper.e-small .e-input-group-icon.e-date-icon,*.e-small .e-control-wrapper .e-input-group-icon.e-date-icon{font-size:14px}.e-date-wrapper.e-outline .e-input-group-icon.e-date-icon,.e-date-wrapper.e-control-wrapper.e-outline .e-input-group-icon.e-date-icon{min-height:0;min-width:20px}.e-small .e-date-wrapper.e-outline .e-input-group-icon.e-date-icon,.e-date-wrapper.e-control-wrapper.e-small.e-outline .e-input-group-icon.e-date-icon,.e-small .e-date-wrapper.e-control-wrapper.e-outline .e-input-group-icon.e-date-icon{min-height:0;min-width:18px}.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand .e-model-header .e-popup-close:before{content:"\e932";font-family:e-icons}.e-input-group.e-control-wrapper.e-date-wrapper.e-non-edit.e-input-focus .e-input:focus~.e-clear-icon,.e-float-input.e-control-wrapper.e-input-group.e-date-wrapper.e-non-edit.e-input-focus input:focus~.e-clear-icon{display:flex}.e-date-wrapper:not(.e-filled) .e-date-icon.e-icons{box-sizing:border-box}.e-datepicker .e-calendar .e-content table tbody tr.e-month-hide:last-child{display:none}.e-datepicker.e-popup-wrapper{border-radius:0;overflow-y:hidden;pointer-events:auto}.e-datepicker.e-date-modal{background-color:#0009;height:100%;left:0;opacity:.5;pointer-events:auto;position:fixed;top:0;width:100%;z-index:999}.e-datepicker .e-model-header{background-color:#e3165b;color:#fff;cursor:default;display:block;padding:10px 10px 10px 15px}.e-datepicker .e-model-header .e-model-year{font-size:14px;font-weight:500;line-height:32px;margin:0}.e-datepicker .e-model-month,.e-datepicker .e-model-day{font-size:20px;font-weight:500;line-height:32px;margin:0}.e-date-overflow{overflow:hidden!important}.e-datepick-mob-popup-wrap{align-items:center;display:flex;flex-direction:column;height:100%;justify-content:center;left:0;max-height:100%;position:fixed;top:0;width:100%;z-index:1002}.e-datepick-mob-popup-wrap .e-datepicker.e-popup-wrapper.e-lib.e-popup.e-control.e-popup-open{position:relative;top:0!important;left:0!important}.e-datepick-mob-popup-wrap .e-datepicker.e-popup-wrapper.e-popup-expand.e-lib.e-popup.e-control.e-popup-open{min-width:100%;min-height:100%}.e-content-placeholder.e-datepicker.e-placeholder-datepicker{background-size:250px 33px;min-height:33px}@media screen and (orientation: landscape){.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand .e-calendar .e-content.e-month td.e-today span.e-day{line-height:64px}}.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand{border-radius:0}.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand .e-model-header.e-blazor-device{height:15vh}.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand .e-model-header.e-blazor-device .e-popup-close{float:right}.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand .e-model-header{height:20vh;padding:2vh 6vw}.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand .e-model-header .e-day-wrapper{margin:12vh 0 0}.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand .e-model-header .e-popup-close{color:inherit;float:left;font-size:18px}@media (min-device-width: 768px){.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand .e-model-header .e-popup-close{font-size:24px}}.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand .e-model-header .e-btn.e-flat.e-popup-close{background:transparent;border-color:transparent;box-shadow:none;font-weight:400;padding:0}.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand .e-model-header .e-today.e-flat.e-primary{color:inherit;float:right}@media (min-device-width: 768px){.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand .e-model-header .e-today.e-flat.e-primary{font-size:24px}}.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand .e-model-month,.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand .e-model-day{font-size:5vw;line-height:6vw}.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand .e-calendar{min-width:100%;min-height:100%;height:100%}.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand .e-calendar .e-header.e-month,.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand .e-calendar .e-header.e-year,.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand .e-calendar .e-header.e-decade{height:10vh;border-style:none;border-width:0;border-color:#0000001f;padding:2vh 2vw;line-height:5vh}.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand .e-calendar .e-header.e-month .e-title,.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand .e-calendar .e-header.e-year .e-title,.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand .e-calendar .e-header.e-decade .e-title{position:inherit;line-height:inherit;margin-left:5vw;text-align:left;vertical-align:middle;width:60vw}@media (min-device-width: 768px){.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand .e-calendar .e-header.e-month .e-title,.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand .e-calendar .e-header.e-year .e-title,.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand .e-calendar .e-header.e-decade .e-title{font-size:24px}}.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand .e-calendar .e-header.e-month .e-prev,.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand .e-calendar .e-header.e-year .e-prev,.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand .e-calendar .e-header.e-decade .e-prev{margin-right:0;vertical-align:inherit;height:35px;width:35px}@media (min-device-width: 768px){.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand .e-calendar .e-header.e-month .e-prev,.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand .e-calendar .e-header.e-year .e-prev,.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand .e-calendar .e-header.e-decade .e-prev{height:55px;width:55px}}.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand .e-calendar .e-header.e-month .e-prev .e-icons,.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand .e-calendar .e-header.e-year .e-prev .e-icons,.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand .e-calendar .e-header.e-decade .e-prev .e-icons{vertical-align:inherit}@media (min-device-width: 768px){.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand .e-calendar .e-header.e-month .e-prev .e-icons,.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand .e-calendar .e-header.e-year .e-prev .e-icons,.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand .e-calendar .e-header.e-decade .e-prev .e-icons{font-size:24px}}.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand .e-calendar .e-header.e-month .e-next,.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand .e-calendar .e-header.e-year .e-next,.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand .e-calendar .e-header.e-decade .e-next{margin-right:0;vertical-align:inherit;height:35px;width:35px}@media (min-device-width: 768px){.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand .e-calendar .e-header.e-month .e-next,.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand .e-calendar .e-header.e-year .e-next,.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand .e-calendar .e-header.e-decade .e-next{height:55px;width:55px}}.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand .e-calendar .e-header.e-month .e-next .e-icons,.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand .e-calendar .e-header.e-year .e-next .e-icons,.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand .e-calendar .e-header.e-decade .e-next .e-icons{vertical-align:inherit}@media (min-device-width: 768px){.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand .e-calendar .e-header.e-month .e-next .e-icons,.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand .e-calendar .e-header.e-year .e-next .e-icons,.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand .e-calendar .e-header.e-decade .e-next .e-icons{font-size:24px}}.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand .e-calendar .e-header.e-month .e-icon-container,.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand .e-calendar .e-header.e-year .e-icon-container,.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand .e-calendar .e-header.e-decade .e-icon-container{float:right}@media (min-device-width: 768px){.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand .e-calendar th{font-size:24px;height:48px}}@media (min-device-width: 768px){.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand .e-calendar .e-content span.e-day{font-size:24px;height:64px;width:64px;line-height:64px}}.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand .e-calendar-cell-container{height:79vh}.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand .e-footer-container{display:none}.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand .e-content.e-month,.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand .e-content.e-month table{height:69vh}@media screen and (orientation: landscape){.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand .e-model-header.e-blazor-device{height:25vh}.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand .e-model-header.e-blazor-device .e-popup-close{float:right}.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand .e-calendar-cell-container .e-content.e-month,.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand .e-calendar-cell-container .e-content.e-year,.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand .e-calendar-cell-container .e-content.e-decade{overflow-y:auto}}@media screen and (orientation: landscape) and (max-height: 600px){.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand .e-calendar-cell-container .e-content.e-month,.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand .e-calendar-cell-container .e-content.e-year,.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand .e-calendar-cell-container .e-content.e-decade{height:50vh}}@media screen and (orientation: landscape) and (min-height: 600px){.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand .e-calendar-cell-container .e-content.e-month,.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand .e-calendar-cell-container .e-content.e-year,.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand .e-calendar-cell-container .e-content.e-decade{height:60vh}}@media screen and (orientation: landscape) and (min-height: 600px){.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand .e-calendar-cell-container .e-content.e-month table,.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand .e-calendar-cell-container .e-content.e-year table,.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand .e-calendar-cell-container .e-content.e-decade table{height:60vh}}@media screen and (orientation: landscape) and (min-height: 600px){.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand .e-calendar-cell-container .e-footer-container{padding:10px 0;height:10%;font-size:24px}}@media screen and (orientation: landscape){.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand .e-model-header{width:100%}}@media screen and (orientation: landscape) and (max-height: 600px){.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand .e-model-header{height:30vh}}@media screen and (orientation: landscape) and (min-height: 600px){.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand .e-model-header{height:25vh}}@media screen and (orientation: landscape){.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand .e-model-header .e-popup-close{float:left}.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand .e-model-header .e-day-wrapper{margin:12vh 0 0}.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand .e-model-header .e-model-month,.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand .e-model-header .e-model-day{font-size:4vw}.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand .e-calendar .e-header.e-month .e-prev,.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand .e-calendar .e-header.e-year .e-prev,.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand .e-calendar .e-header.e-decade .e-prev{margin-right:0}}@media screen and (orientation: landscape) and (max-height: 600px){.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand .e-calendar .e-header.e-month .e-title,.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand .e-calendar .e-header.e-year .e-title,.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand .e-calendar .e-header.e-decade .e-title{line-height:12vh}}@media screen and (orientation: landscape) and (min-height: 600px){.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand .e-calendar .e-header.e-month .e-title,.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand .e-calendar .e-header.e-year .e-title,.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand .e-calendar .e-header.e-decade .e-title{line-height:inherit}}@media screen and (orientation: landscape){.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand .e-content.e-month,.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand .e-content.e-year,.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand .e-content.e-decade{overflow-y:auto}}@media screen and (orientation: landscape) and (max-height: 600px){.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand .e-content.e-month,.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand .e-content.e-year,.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand .e-content.e-decade{height:60vh}}@media screen and (orientation: landscape) and (min-height: 600px){.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand .e-content.e-month,.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand .e-content.e-year,.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand .e-content.e-decade{height:65vh}}@media screen and (orientation: landscape){.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand .e-calendar{display:block;max-width:100%;overflow:visible}.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand .e-calendar-cell-container{height:70%;width:100%}.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand .e-calendar.e-device .e-month table tbody{display:table-row-group}}@media screen and (orientation: landscape) and (max-height: 600px){.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand .e-content.e-month table,.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand .e-content.e-decade table,.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand .e-content.e-year table{height:69vh}}@media screen and (orientation: landscape) and (min-height: 600px){.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand .e-content.e-month table,.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand .e-content.e-decade table,.e-datepick-mob-popup-wrap .e-datepicker.e-popup-expand .e-content.e-year table{height:65vh}}.e-datepicker.e-popup-wrapper,.e-small.e-datepicker.e-popup-wrapper{border:none;box-shadow:0 5px 5px -3px #0003,0 8px 10px 1px #00000024,0 3px 14px 2px #0000001f}.e-datepicker .e-calendar,.e-small.e-datepicker .e-calendar{background-color:#fff;border:none}*.e-input-group.e-date-wrapper.e-dateinput-active:active:not(.e-success):not(.e-warning):not(.e-error){border:none}.e-date-wrapper span.e-input-group-icon.e-date-icon.e-icons.e-active{color:#e3165b}.e-bigger .e-content-placeholder.e-datepicker.e-placeholder-datepicker,.e-bigger.e-content-placeholder.e-datepicker.e-placeholder-datepicker{background-size:250px 40px;min-height:40px}.e-bigger.e-datepicker.e-popup-wrapper,.e-bigger.e-small.e-datepicker.e-popup-wrapper{border:none;box-shadow:0 5px 5px -3px #0003,0 8px 10px 1px #00000024,0 3px 14px 2px #0000001f}.e-bigger.e-datepicker .e-calendar,.e-bigger.e-small.e-datepicker .e-calendar{background-color:#fff;border:none}.e-bigger .e-input-group-icon.e-date-icon,*.e-control-wrapper.e-bigger .e-input-group-icon.e-date-icon,*.e-bigger .e-control-wrapper .e-input-group-icon.e-date-icon{font-size:18px;margin:5px 0 6px;min-height:26px;min-width:26px}.e-small.e-bigger .e-input-group-icon.e-date-icon,*.e-control-wrapper.e-small.e-bigger .e-input-group-icon.e-date-icon,*.e-small.e-bigger .e-control-wrapper .e-input-group-icon.e-date-icon{font-size:18px}.e-bigger .e-date-wrapper.e-outline .e-input-group-icon.e-date-icon,.e-date-wrapper.e-control-wrapper.e-bigger.e-outline .e-input-group-icon.e-date-icon,.e-bigger .e-date-wrapper.e-control-wrapper.e-outline .e-input-group-icon.e-date-icon{min-height:0;min-width:24px}.e-bigger.e-small .e-outline.e-date-wrapper .e-input-group-icon.e-date-icon,.e-bigger.e-small.e-outline.e-date-wrapper .e-input-group-icon.e-date-icon,.e-date-wrapper.e-control-wrapper.e-bigger.e-small.e-outline .e-input-group-icon.e-date-icon,.e-bigger.e-small .e-date-wrapper.e-control-wrapper.e-outline .e-input-group-icon.e-date-icon{min-height:0;min-width:20px}.e-input-group-icon.e-range-icon,*.e-control-wrapper .e-input-group-icon.e-range-icon{font-size:16px;margin:0 0 4px;min-height:24px;min-width:24px;outline:none}.e-input-group-icon.e-range-icon:before,*.e-control-wrapper .e-input-group-icon.e-range-icon:before{content:"\e245";font-family:e-icons}.e-input-group-icon.e-range-icon:focus,*.e-control-wrapper .e-input-group-icon.e-range-icon:focus{background:#eee;border-radius:50%}.e-daterangepicker .e-calendar .e-header .e-date-icon-next:before{content:"\e913"}.e-daterangepicker .e-calendar .e-header .e-date-icon-prev:before{content:"\e921"}.e-daterangepicker .e-change-icon:before{content:"\e85f"}.e-daterangepicker .e-calendar.e-rtl .e-header .e-date-icon-next:before{content:"\e921"}.e-daterangepicker .e-calendar.e-rtl .e-header .e-date-icon-prev:before{content:"\e913"}.e-daterangepicker.e-rtl .e-start-end .e-change-icon:before{content:"\e85b"}.e-small .e-input-group-icon.e-range-icon,*.e-control-wrapper.e-small .e-input-group-icon.e-range-icon,*.e-small .e-control-wrapper .e-input-group-icon.e-range-icon{font-size:14px}.e-date-range-wrapper.e-outline .e-input-group-icon.e-range-icon,.e-date-range-wrapper.e-control-wrapper.e-outline .e-input-group-icon.e-range-icon{min-height:0;min-width:20px}.e-small .e-date-range-wrapper.e-outline .e-input-group-icon.e-range-icon,.e-date-range-wrapper.e-control-wrapper.e-small.e-outline .e-input-group-icon.e-range-icon,.e-small .e-date-range-wrapper.e-control-wrapper.e-outline .e-input-group-icon.e-range-icon{min-height:0;min-width:18px}.e-daterangepick-mob-popup-wrap .e-daterangepicker.e-popup-expand .e-range-header .e-popup-close:before,.e-daterangepick-mob-popup-wrap .e-daterangepicker.e-popup-expand .e-model-header .e-popup-close:before{content:"\e932";font-family:e-icons}.e-daterangepick-mob-popup-wrap .e-daterangepicker.e-popup-expand .e-range-header .e-apply:before,.e-daterangepick-mob-popup-wrap .e-daterangepicker.e-popup-expand .e-model-header .e-apply:before{content:"\e7ff";font-family:e-icons}.e-input-group.e-control-wrapper.e-date-range-wrapper.e-non-edit.e-input-focus .e-input:focus~.e-clear-icon,.e-float-input.e-control-wrapper.e-input-group.e-date-range-wrapper.e-non-edit.e-input-focus input:focus~.e-clear-icon{display:flex}.e-float-input.e-input-group.e-control-wrapper.e-date-range-wrapper .e-daterange-hidden,.e-input-group.e-control-wrapper.e-date-range-wrapper .e-daterange-hidden,.e-float-input.e-control-wrapper.e-date-range-wrapper .e-daterange-hidden,.e-float-input.e-input-group.e-control-wrapper.e-date-range-wrapper.e-input-focus .e-daterange-hidden,.e-input-group.e-control-wrapper.e-date-range-wrapper.e-input-focus .e-daterange-hidden,.e-float-input.e-control-wrapper.e-date-range-wrapper.e-input-focus .e-daterange-hidden{border:0;height:0;margin:0;padding:0;text-indent:0;visibility:hidden;width:0}.e-daterangepicker.e-popup{border:none;border-radius:0;box-shadow:0 5px 5px -3px #0003,0 8px 10px 1px #00000024,0 3px 14px 2px #0000001f;max-height:500px;max-width:730px}.e-daterangepicker.e-popup.e-daterange-day-header-lg{max-width:100%}.e-daterangepicker.e-popup.e-preset-wrapper{min-width:625px}.e-daterangepicker.e-popup.e-preset-wrapper .e-presets{max-height:none}.e-daterangepicker.e-popup .e-range-header{background:#fff;padding:16px 16px 0;width:auto}.e-daterangepicker.e-popup .e-range-header .e-start-label,.e-daterangepicker.e-popup .e-range-header .e-end-label{cursor:default;display:inline-block;font-size:18px;overflow:hidden;text-align:center;text-decoration:none;text-overflow:ellipsis;-webkit-user-select:none;user-select:none;white-space:nowrap;width:48%}.e-daterangepicker.e-popup .e-range-header .e-change-icon{font-size:15px;font-weight:500;text-align:center;width:4%}.e-daterangepicker.e-popup .e-range-header .e-day-span{direction:ltr;font-size:13px;height:14px;margin:0 0 15px;text-align:center;-webkit-user-select:none;user-select:none;width:100%}.e-daterangepicker.e-popup .e-range-header .e-start-end{align-items:center;display:flex;height:35px}.e-daterangepicker.e-popup .e-separator{height:1px;margin:0}.e-daterangepicker.e-popup .e-calendar{border:none;margin:0;padding:0}.e-daterangepicker.e-popup .e-calendar .e-content table{padding:0 10px 10px}.e-daterangepicker.e-popup .e-calendar .e-header .e-title{cursor:pointer;line-height:36px;width:auto;float:none;font-weight:400;margin-left:0}.e-daterangepicker.e-popup .e-calendar .e-header.e-month,.e-daterangepicker.e-popup .e-calendar .e-header.e-year,.e-daterangepicker.e-popup .e-calendar .e-header.e-decade{padding:10px 5px 0}.e-daterangepicker.e-popup .e-calendar .e-header .e-next{float:right}.e-daterangepicker.e-popup .e-calendar .e-header .e-prev{float:left}.e-daterangepicker.e-popup .e-calendar .e-header .e-next,.e-daterangepicker.e-popup .e-calendar .e-header .e-prev{height:36px;width:36px}.e-daterangepicker.e-popup .e-calendar .e-header .e-next span,.e-daterangepicker.e-popup .e-calendar .e-header .e-prev span{padding:10px}.e-daterangepicker.e-popup .e-calendar .e-start-date.e-selected.e-range-hover{border-radius:50% 0 0 50%}.e-daterangepicker.e-popup .e-calendar .e-end-date.e-selected.e-range-hover{border-radius:0 50% 50% 0}.e-daterangepicker.e-popup .e-calendar .e-end-date.e-selected.e-range-hover span.e-day,.e-daterangepicker.e-popup .e-calendar .e-start-date.e-selected.e-range-hover span.e-day{border:none}.e-daterangepicker.e-popup .e-footer{align-items:center;border-top:1px solid rgba(0,0,0,.12);clear:both;display:flex;flex-direction:row-reverse;height:48px}.e-daterangepicker.e-popup .e-footer .e-btn{font-weight:500;height:27px;line-height:27px;overflow:hidden;padding:0 16px;text-overflow:ellipsis}.e-daterangepicker.e-popup .e-footer .e-btn.e-apply{margin:0 8px}.e-daterangepicker.e-popup .e-date-range-container{float:left}.e-daterangepicker.e-popup .e-date-range-container.e-range-border{border-right:1px solid rgba(0,0,0,.12)}.e-daterangepicker.e-popup .e-calendar-container{display:flex}.e-daterangepicker.e-popup .e-calendar-container .e-left-container,.e-daterangepicker.e-popup .e-calendar-container .e-right-container{float:left}.e-daterangepicker.e-popup .e-calendar-container .e-left-container{border-right:1px solid rgba(0,0,0,.12)}.e-daterangepicker.e-popup .e-presets{max-height:192px;overflow:auto;width:auto}.e-daterangepicker.e-popup .e-presets .e-list-item{border-radius:0;cursor:pointer;line-height:48px;overflow:hidden;padding:0 24px;white-space:nowrap;text-overflow:ellipsis}.e-daterangepicker.e-popup .e-presets .e-list-parent{margin:0;max-width:160px;padding:0}.e-daterangepicker.e-popup .e-presets .e-text-content{line-height:47px}.e-daterangepicker.e-popup .e-presets .e-ul li.e-list-item{font-size:13px;height:36px;line-height:36px}.e-daterangepicker.e-popup .e-hide-range{display:none}.e-daterangepicker.e-rtl .e-date-range-container{float:right}.e-daterangepicker.e-rtl .e-date-range-container.e-range-border,.e-daterangepicker.e-rtl .e-date-range-container .e-left-container{border-left:1px solid rgba(0,0,0,.12);border-right:0}.e-daterangepicker.e-rtl .e-date-range-container .e-calendar .e-next{float:left}.e-daterangepicker.e-rtl .e-date-range-container .e-calendar .e-prev{float:right}.e-daterangepicker.e-rtl .e-date-range-container .e-calendar .e-start-date.e-selected.e-range-hover{border-radius:0 50% 50% 0}.e-daterangepicker.e-rtl .e-date-range-container .e-calendar .e-end-date.e-selected.e-range-hover{border-radius:50% 0 0 50%}.e-daterangepicker.e-rtl .e-footer{flex-direction:row;justify-content:flex-end}.e-daterangepicker.e-rtl .e-footer .e-btn.e-cancel{margin:0 8px}.e-daterangepicker.e-rtl .e-footer .e-btn.e-apply{margin-left:0}.e-small .e-daterangepicker.e-popup .e-range-header,*.e-small.e-daterangepicker.e-popup .e-range-header{margin:10px 10px 0}.e-small .e-daterangepicker.e-popup .e-range-header .e-start-label,.e-small .e-daterangepicker.e-popup .e-range-header .e-end-label,*.e-small.e-daterangepicker.e-popup .e-range-header .e-start-label,*.e-small.e-daterangepicker.e-popup .e-range-header .e-end-label{font-size:16px}.e-small .e-daterangepicker.e-popup .e-range-header .e-change-icon,*.e-small.e-daterangepicker.e-popup .e-range-header .e-change-icon{font-size:12px}.e-small .e-daterangepicker.e-popup .e-range-header .e-start-end,*.e-small.e-daterangepicker.e-popup .e-range-header .e-start-end{height:32px}.e-small .e-daterangepicker.e-popup .e-range-header .e-day-span,*.e-small.e-daterangepicker.e-popup .e-range-header .e-day-span{font-size:12px;margin:0 0 10px}.e-small .e-daterangepicker.e-popup .e-range-header .e-separator,*.e-small.e-daterangepicker.e-popup .e-range-header .e-separator{margin:0 10px}.e-small .e-daterangepicker.e-popup .e-footer .e-btn.e-apply,*.e-small.e-daterangepicker.e-popup .e-footer .e-btn.e-apply{margin:10px 10px 10px 8px}.e-small .e-daterangepicker.e-popup.e-preset-wrapper .e-presets .e-list-parent.e-ul .e-list-item,*.e-small.e-daterangepicker.e-popup.e-preset-wrapper .e-presets .e-list-parent.e-ul .e-list-item{font-size:12px;height:26px;line-height:26px}.e-range-overflow{overflow:hidden}.e-daterangepick-mob-popup-wrap{align-items:center;display:flex;flex-direction:column;height:100%;justify-content:center;left:0;max-height:100%;position:fixed;top:0;width:100%;z-index:1002}.e-daterangepick-mob-popup-wrap .e-daterangepicker.e-popup.e-control.e-lib.e-device.e-popup-open{position:relative;top:0!important;left:0!important}.e-daterangepick-mob-popup-wrap .e-daterangepicker.e-popup.e-popup-expand.e-control.e-lib.e-device.e-popup-open{min-height:100%;min-width:100%;height:100%;width:100%}.e-content-placeholder.e-daterangepicker.e-placeholder-daterangepicker{background-size:250px 33px;min-height:33px}.e-daterangepick-mob-popup-wrap .e-daterangepicker.e-popup.e-popup-expand .e-date-range-container{min-height:100%;min-width:100%;height:100%;width:100%}.e-daterangepick-mob-popup-wrap .e-daterangepicker.e-popup.e-popup-expand .e-date-range-container .e-range-header{height:20vh;padding:2vh 2vw;margin:0;color:#000000de}@media (max-device-width: 768px){.e-daterangepick-mob-popup-wrap .e-daterangepicker.e-popup.e-popup-expand .e-date-range-container .e-range-header .e-model-header-wrapper{font-size:16px}}@media (min-device-width: 768px){.e-daterangepick-mob-popup-wrap .e-daterangepicker.e-popup.e-popup-expand .e-date-range-container .e-range-header .e-model-header-wrapper{font-size:18px}}.e-daterangepick-mob-popup-wrap .e-daterangepicker.e-popup.e-popup-expand .e-date-range-container .e-range-header .e-model-header-wrapper .e-apply{float:right}.e-daterangepick-mob-popup-wrap .e-daterangepicker.e-popup.e-popup-expand .e-date-range-container .e-range-header .e-start-end{margin:3vh 0 0}.e-daterangepick-mob-popup-wrap .e-daterangepicker.e-popup.e-popup-expand .e-date-range-container .e-calendar{min-width:100%;width:100%;padding:0;overflow:unset}@media (max-height: 600px){.e-daterangepick-mob-popup-wrap .e-daterangepicker.e-popup.e-popup-expand .e-date-range-container .e-calendar{min-height:100%;height:100%}}@media (min-height: 600px){.e-daterangepick-mob-popup-wrap .e-daterangepicker.e-popup.e-popup-expand .e-date-range-container .e-calendar{min-height:80vh;height:80vh}}.e-daterangepick-mob-popup-wrap .e-daterangepicker.e-popup.e-popup-expand .e-date-range-container .e-calendar .e-header.e-month,.e-daterangepick-mob-popup-wrap .e-daterangepicker.e-popup.e-popup-expand .e-date-range-container .e-calendar .e-header.e-year,.e-daterangepick-mob-popup-wrap .e-daterangepicker.e-popup.e-popup-expand .e-date-range-container .e-calendar .e-header.e-decade{height:10vh;border-style:solid;border-width:0 0 1px 0;border-color:#0000001f;padding:2vh 2vw;line-height:5vh}.e-daterangepick-mob-popup-wrap .e-daterangepicker.e-popup.e-popup-expand .e-date-range-container .e-calendar .e-header.e-month .e-prev,.e-daterangepick-mob-popup-wrap .e-daterangepicker.e-popup.e-popup-expand .e-date-range-container .e-calendar .e-header.e-year .e-prev,.e-daterangepick-mob-popup-wrap .e-daterangepicker.e-popup.e-popup-expand .e-date-range-container .e-calendar .e-header.e-decade .e-prev{height:36px;width:36px}@media (min-device-width: 768px){.e-daterangepick-mob-popup-wrap .e-daterangepicker.e-popup.e-popup-expand .e-date-range-container .e-calendar .e-header.e-month .e-prev span,.e-daterangepick-mob-popup-wrap .e-daterangepicker.e-popup.e-popup-expand .e-date-range-container .e-calendar .e-header.e-year .e-prev span,.e-daterangepick-mob-popup-wrap .e-daterangepicker.e-popup.e-popup-expand .e-date-range-container .e-calendar .e-header.e-decade .e-prev span{font-size:18px;padding:11px}}.e-daterangepick-mob-popup-wrap .e-daterangepicker.e-popup.e-popup-expand .e-date-range-container .e-calendar .e-header.e-month .e-next,.e-daterangepick-mob-popup-wrap .e-daterangepicker.e-popup.e-popup-expand .e-date-range-container .e-calendar .e-header.e-year .e-next,.e-daterangepick-mob-popup-wrap .e-daterangepicker.e-popup.e-popup-expand .e-date-range-container .e-calendar .e-header.e-decade .e-next{height:36px;width:36px}.e-daterangepick-mob-popup-wrap .e-daterangepicker.e-popup.e-popup-expand .e-date-range-container .e-calendar .e-header.e-month .e-next span,.e-daterangepick-mob-popup-wrap .e-daterangepicker.e-popup.e-popup-expand .e-date-range-container .e-calendar .e-header.e-year .e-next span,.e-daterangepick-mob-popup-wrap .e-daterangepicker.e-popup.e-popup-expand .e-date-range-container .e-calendar .e-header.e-decade .e-next span{padding:10px;line-height:1}@media (min-device-width: 768px){.e-daterangepick-mob-popup-wrap .e-daterangepicker.e-popup.e-popup-expand .e-date-range-container .e-calendar .e-header.e-month .e-next span,.e-daterangepick-mob-popup-wrap .e-daterangepicker.e-popup.e-popup-expand .e-date-range-container .e-calendar .e-header.e-year .e-next span,.e-daterangepick-mob-popup-wrap .e-daterangepicker.e-popup.e-popup-expand .e-date-range-container .e-calendar .e-header.e-decade .e-next span{font-size:18px}}@media (max-height: 600px){.e-daterangepick-mob-popup-wrap .e-daterangepicker.e-popup.e-popup-expand .e-date-range-container .e-calendar .e-header.e-month .e-title,.e-daterangepick-mob-popup-wrap .e-daterangepicker.e-popup.e-popup-expand .e-date-range-container .e-calendar .e-header.e-year .e-title,.e-daterangepick-mob-popup-wrap .e-daterangepicker.e-popup.e-popup-expand .e-date-range-container .e-calendar .e-header.e-decade .e-title{line-height:8vh}}@media (min-height: 600px){.e-daterangepick-mob-popup-wrap .e-daterangepicker.e-popup.e-popup-expand .e-date-range-container .e-calendar .e-header.e-month .e-title,.e-daterangepick-mob-popup-wrap .e-daterangepicker.e-popup.e-popup-expand .e-date-range-container .e-calendar .e-header.e-year .e-title,.e-daterangepick-mob-popup-wrap .e-daterangepicker.e-popup.e-popup-expand .e-date-range-container .e-calendar .e-header.e-decade .e-title{line-height:inherit}}@media (min-device-width: 768px){.e-daterangepick-mob-popup-wrap .e-daterangepicker.e-popup.e-popup-expand .e-date-range-container .e-calendar .e-header.e-month .e-title,.e-daterangepick-mob-popup-wrap .e-daterangepicker.e-popup.e-popup-expand .e-date-range-container .e-calendar .e-header.e-year .e-title,.e-daterangepick-mob-popup-wrap .e-daterangepicker.e-popup.e-popup-expand .e-date-range-container .e-calendar .e-header.e-decade .e-title{font-size:18px}}@media (min-device-width: 768px){.e-daterangepick-mob-popup-wrap .e-daterangepicker.e-popup.e-popup-expand .e-date-range-container .e-calendar th{font-size:18px;height:48px}}@media (min-device-width: 768px){.e-daterangepick-mob-popup-wrap .e-daterangepicker.e-popup.e-popup-expand .e-date-range-container .e-calendar .e-content span.e-day{font-size:18px;height:64px;width:64px;line-height:64px}}.e-daterangepick-mob-popup-wrap .e-daterangepicker.e-popup.e-popup-expand .e-date-range-container .e-calendar .e-start-date.e-selected.e-range-hover,.e-daterangepick-mob-popup-wrap .e-daterangepicker.e-popup.e-popup-expand .e-date-range-container .e-calendar .e-end-date.e-selected.e-range-hover{border-radius:0}.e-daterangepick-mob-popup-wrap .e-daterangepicker.e-popup.e-popup-expand .e-calendar-holder{height:100%}@media (max-height: 600px){.e-daterangepick-mob-popup-wrap .e-daterangepicker.e-popup.e-popup-expand .e-calendar-holder .e-calendar-container{min-height:78vh;height:78vh}}@media (max-height: 600px){.e-daterangepick-mob-popup-wrap .e-daterangepicker.e-popup.e-popup-expand .e-calendar-holder .e-calendar-container .e-calendar{min-height:78vh;height:78vh}}@media (max-height: 600px){.e-daterangepick-mob-popup-wrap .e-daterangepicker.e-popup.e-popup-expand .e-calendar-container{min-height:100%;height:100%}}@media (min-height: 600px){.e-daterangepick-mob-popup-wrap .e-daterangepicker.e-popup.e-popup-expand .e-calendar-container{min-height:80vh;height:80vh}}.e-daterangepick-mob-popup-wrap .e-daterangepicker.e-popup.e-popup-expand .e-separator{margin:0}.e-daterangepick-mob-popup-wrap .e-daterangepicker.e-popup.e-popup-expand .e-content.e-month{height:69vh}.e-daterangepick-mob-popup-wrap .e-daterangepicker.e-popup.e-popup-expand .e-content.e-month table{padding:0 2vw;height:69vh;border-spacing:unset}.e-daterangepick-mob-popup-wrap .e-daterangepicker.e-popup.e-popup-expand .e-footer{display:none}.e-daterangepick-mob-popup-wrap .e-daterangepicker.e-popup.e-popup-expand .e-presets{max-height:90%;height:90%}.e-daterangepick-mob-popup-wrap .e-daterangepicker.e-popup.e-popup-expand .e-presets ul{height:100%}.e-daterangepick-mob-popup-wrap .e-daterangepicker.e-popup.e-popup-expand .e-presets ul li.e-list-item{font-size:16px}@media (min-device-width: 768px){.e-daterangepick-mob-popup-wrap .e-daterangepicker.e-popup.e-popup-expand .e-presets ul li.e-list-item{font-size:18px}}.e-daterangepick-mob-popup-wrap .e-daterangepicker.e-popup.e-popup-expand .e-range-mob-popup-wrap{position:relative;height:100%}.e-daterangepick-mob-popup-wrap .e-daterangepicker.e-popup.e-popup-expand .e-range-mob-popup-wrap .e-model-header{height:10%;padding:2.5vh 2.5vw 2.5vh 0;display:flex;align-items:center;font-size:3vh;border-bottom:none}@media (min-device-width: 768px){.e-daterangepick-mob-popup-wrap .e-daterangepicker.e-popup.e-popup-expand .e-range-mob-popup-wrap .e-model-header{font-size:18px}}.e-daterangepick-mob-popup-wrap .e-daterangepicker.e-popup.e-popup-expand .e-range-mob-popup-wrap .e-model-header .e-popup-close{float:left;padding:1vh 2vw}.e-daterangepick-mob-popup-wrap .e-daterangepicker.e-popup.e-popup-expand .e-range-mob-popup-wrap .e-model-header .e-model-title{padding:1vh 2vw;text-transform:uppercase}@media screen and (orientation: landscape){.e-daterangepick-mob-popup-wrap .e-daterangepicker.e-popup.e-popup-expand .e-date-range-container .e-range-header .e-model-header-wrapper .e-btn{padding:0}}@media screen and (orientation: landscape) and (min-device-width: 768px){.e-daterangepick-mob-popup-wrap .e-daterangepicker.e-popup.e-popup-expand .e-date-range-container .e-range-header .e-model-header-wrapper .e-btn{font-size:18px}}@media screen and (orientation: landscape) and (min-height: 600px){.e-daterangepick-mob-popup-wrap .e-daterangepicker.e-popup.e-popup-expand .e-calendar-holder .e-calendar-container{min-height:70vh;height:70vh}}@media screen and (orientation: landscape) and (max-height: 600px){.e-daterangepick-mob-popup-wrap .e-daterangepicker.e-popup.e-popup-expand .e-calendar-holder .e-calendar-container{min-height:65%;height:65%}}@media screen and (orientation: landscape) and (min-height: 600px){.e-daterangepick-mob-popup-wrap .e-daterangepicker.e-popup.e-popup-expand .e-calendar-holder .e-calendar-container .e-calendar{min-height:70vh;height:70vh}}@media screen and (orientation: landscape) and (max-height: 600px){.e-daterangepick-mob-popup-wrap .e-daterangepicker.e-popup.e-popup-expand .e-calendar-holder .e-calendar-container .e-content.e-month,.e-daterangepick-mob-popup-wrap .e-daterangepicker.e-popup.e-popup-expand .e-calendar-holder .e-calendar-container .e-content.e-year,.e-daterangepick-mob-popup-wrap .e-daterangepicker.e-popup.e-popup-expand .e-calendar-holder .e-calendar-container .e-content.e-decade{height:50vh}}@media screen and (orientation: landscape){.e-daterangepick-mob-popup-wrap .e-daterangepicker.e-popup.e-popup-expand .e-presets{max-height:85%;height:85%}.e-daterangepick-mob-popup-wrap .e-daterangepicker.e-popup.e-popup-expand .e-range-mob-popup-wrap .e-model-header{height:15%;font-size:18px}.e-daterangepick-mob-popup-wrap .e-daterangepicker.e-popup.e-popup-expand .e-range-mob-popup-wrap .e-model-header .e-popup-close,.e-daterangepick-mob-popup-wrap .e-daterangepicker.e-popup.e-popup-expand .e-range-mob-popup-wrap .e-model-header .e-model-title{padding:1vh 1vw}.e-daterangepick-mob-popup-wrap .e-daterangepicker.e-popup.e-popup-expand .e-date-range-container .e-range-header{width:100%}}@media screen and (orientation: landscape) and (max-height: 600px){.e-daterangepick-mob-popup-wrap .e-daterangepicker.e-popup.e-popup-expand .e-date-range-container .e-range-header{height:27vh}}@media screen and (orientation: landscape) and (min-height: 600px){.e-daterangepick-mob-popup-wrap .e-daterangepicker.e-popup.e-popup-expand .e-date-range-container .e-range-header{height:25vh}}@media screen and (orientation: landscape){.e-daterangepick-mob-popup-wrap .e-daterangepicker.e-popup.e-popup-expand .e-date-range-container .e-range-header .e-start-end{margin:0;height:28px}}@media screen and (orientation: landscape) and (min-height: 600px){.e-daterangepick-mob-popup-wrap .e-daterangepicker.e-popup.e-popup-expand .e-date-range-container .e-range-header .e-start-end{margin:5vh 0 0}}@media screen and (orientation: landscape){.e-daterangepick-mob-popup-wrap .e-daterangepicker.e-popup.e-popup-expand .e-date-range-container .e-range-header .e-day-span{margin:8px 0;font-size:16px}}@media screen and (orientation: landscape) and (min-height: 600px){.e-daterangepick-mob-popup-wrap .e-daterangepicker.e-popup.e-popup-expand .e-calendar-container{min-height:75vh;height:75vh}}@media screen and (orientation: landscape){.e-daterangepick-mob-popup-wrap .e-daterangepicker.e-popup.e-popup-expand .e-content.e-month,.e-daterangepick-mob-popup-wrap .e-daterangepicker.e-popup.e-popup-expand .e-content.e-year,.e-daterangepick-mob-popup-wrap .e-daterangepicker.e-popup.e-popup-expand .e-content.e-decade{overflow-y:auto}}@media screen and (orientation: landscape) and (max-height: 600px){.e-daterangepick-mob-popup-wrap .e-daterangepicker.e-popup.e-popup-expand .e-content.e-month,.e-daterangepick-mob-popup-wrap .e-daterangepicker.e-popup.e-popup-expand .e-content.e-year,.e-daterangepick-mob-popup-wrap .e-daterangepicker.e-popup.e-popup-expand .e-content.e-decade{height:60vh}}@media screen and (orientation: landscape) and (min-height: 600px){.e-daterangepick-mob-popup-wrap .e-daterangepicker.e-popup.e-popup-expand .e-content.e-month,.e-daterangepick-mob-popup-wrap .e-daterangepicker.e-popup.e-popup-expand .e-content.e-year,.e-daterangepick-mob-popup-wrap .e-daterangepicker.e-popup.e-popup-expand .e-content.e-decade{height:65vh}}@media screen and (orientation: landscape){.e-daterangepick-mob-popup-wrap .e-daterangepicker.e-popup.e-popup-expand .e-content.e-month table,.e-daterangepick-mob-popup-wrap .e-daterangepicker.e-popup.e-popup-expand .e-content.e-year table,.e-daterangepick-mob-popup-wrap .e-daterangepicker.e-popup.e-popup-expand .e-content.e-decade table{display:table;border-spacing:unset}}@media screen and (orientation: landscape) and (min-height: 600px){.e-daterangepick-mob-popup-wrap .e-daterangepicker.e-popup.e-popup-expand .e-content.e-month table,.e-daterangepick-mob-popup-wrap .e-daterangepicker.e-popup.e-popup-expand .e-content.e-year table,.e-daterangepick-mob-popup-wrap .e-daterangepicker.e-popup.e-popup-expand .e-content.e-decade table{height:65vh}}.e-outline.e-float-input.e-control-wrapper label.e-float-text.e-label-bottom span.e-float-text-content.e-float-text-overflow.e-date-time-icon{width:calc(100% - 80px)}.e-outline.e-float-input.e-static-clear.e-control-wrapper label.e-float-text.e-label-bottom span.e-float-text-content.e-float-text-overflow.e-date-time-icon{width:calc(100% - 110px)}.e-date-range-wrapper .e-input-group-icon.e-icons.e-active{color:#e3165b}.e-date-range-wrapper.e-input-group:not(.e-disabled) .e-input-group-icon.e-active:active{color:#e3165b}.e-daterangepicker.e-popup{background:#fff}.e-daterangepicker.e-popup .e-calendar{background-color:#fff}.e-daterangepicker.e-popup .e-calendar .e-header .e-title,.e-daterangepicker.e-popup .e-calendar .e-header .e-title:hover{color:#000000de;text-decoration:none}.e-daterangepicker.e-popup .e-calendar .e-content .e-range-hover{background-color:#eee;color:#000000de}.e-daterangepicker.e-popup .e-calendar .e-content.e-month .e-today.e-range-hover span{background-color:#eee;border:1px solid #e3165b;color:#e3165b}.e-daterangepicker.e-popup .e-calendar .e-content .e-range-hover span{background:#eee;border:none;color:#000000de}.e-daterangepicker.e-popup .e-calendar .e-range-hover:not(.e-selected):hover span.e-day,.e-daterangepicker.e-popup .e-calendar .e-range-hover.e-focused-date:not(.e-selected) span.e-day,.e-daterangepicker.e-popup .e-calendar .e-range-hover.e-focused-date.e-today span.e-day{background-color:#c8c8c8;border:none;color:#000000de}.e-daterangepicker.e-popup .e-calendar .e-range-hover.e-today:hover span.e-day,.e-daterangepicker.e-popup .e-calendar .e-range-hover.e-focused-date.e-today span.e-day,.e-daterangepicker.e-popup .e-calendar .e-range-hover.e-start-date.e-selected.e-today span.e-day,.e-daterangepicker.e-popup .e-calendar .e-range-hover.e-end-date.e-selected.e-today span.e-day,.e-daterangepicker.e-popup .e-calendar .e-range-hover.e-selected.e-today:hover span.e-day{border:1px solid #e3165b}.e-daterangepicker.e-popup .e-calendar .e-content .e-other-month.e-range-hover,.e-daterangepicker.e-popup .e-calendar .e-content .e-other-month.e-today.e-range-hover span,.e-daterangepicker.e-popup .e-calendar .e-content .e-other-month.e-range-hover span,.e-daterangepicker.e-popup .e-calendar .e-content .e-other-month.e-range-hover:hover span.e-day,.e-daterangepicker.e-popup .e-calendar .e-content .e-other-month.e-selected,.e-daterangepicker.e-popup .e-calendar .e-content .e-other-month.e-selected span{background-color:#fff;border:none;color:#00000061}.e-daterangepicker.e-popup .e-calendar .e-end-date.e-selected.e-range-hover span.e-day,.e-daterangepicker.e-popup .e-calendar .e-start-date.e-selected.e-range-hover span.e-day,.e-daterangepicker.e-popup .e-calendar .e-start-date.e-selected.e-range-hover.e-today span.e-day{background-color:#e3165b;color:#fff}.e-daterangepicker.e-popup .e-calendar .e-other-month.e-selected span{color:#fff}.e-daterangepicker.e-popup .e-presets{background-color:#fff;color:#000}.e-daterangepicker.e-popup .e-presets .e-list-item.e-active{background-color:#fff;color:#e3165b}.e-daterangepicker.e-popup .e-presets .e-list-item.e-hover{background-color:#eee;color:#000000de}.e-daterangepicker.e-popup .e-start-label,.e-daterangepicker.e-popup .e-end-label{color:#000000de}.e-daterangepicker.e-popup .e-change-icon{color:#000000bd}.e-daterangepicker.e-popup .e-day-span{color:#0000008a}.e-daterangepicker.e-popup .e-separator{background-color:#0000001f}.e-daterangepicker.e-popup .e-footer{background-color:#fff}.e-daterangepick-mob-popup-wrap .e-daterangepicker.e-popup.e-popup-expand .e-model-header{background-color:#3f51b5;color:#fff}.e-daterangepick-mob-popup-wrap .e-daterangepicker.e-popup.e-popup-expand .e-model-header .e-popup-close{color:#fff}.e-bigger .e-daterangepicker.e-range-modal,*.e-device.e-daterangepicker.e-range-modal{background-color:#0009;height:100%;left:0;opacity:.5;pointer-events:auto;position:fixed;top:0;width:100%;z-index:999}.e-bigger .e-daterangepicker.e-popup,*.e-bigger.e-daterangepicker.e-popup,*.e-device.e-daterangepicker.e-popup{background-color:#fff}.e-bigger .e-daterangepicker.e-popup.e-preset-wrapper,*.e-bigger.e-daterangepicker.e-popup.e-preset-wrapper,*.e-device.e-daterangepicker.e-popup.e-preset-wrapper{max-width:770px;min-width:auto}.e-bigger .e-daterangepicker.e-popup.e-preset-wrapper .e-presets,*.e-bigger.e-daterangepicker.e-popup.e-preset-wrapper .e-presets,*.e-device.e-daterangepicker.e-popup.e-preset-wrapper .e-presets{max-height:none}.e-bigger .e-daterangepicker.e-popup .e-range-header,*.e-bigger.e-daterangepicker.e-popup .e-range-header,*.e-device.e-daterangepicker.e-popup .e-range-header{width:auto}.e-bigger .e-daterangepicker.e-popup .e-range-header .e-start-end,*.e-bigger.e-daterangepicker.e-popup .e-range-header .e-start-end,*.e-device.e-daterangepicker.e-popup .e-range-header .e-start-end{align-items:center;cursor:pointer;display:flex;height:36px;justify-content:center;-webkit-user-select:none;user-select:none;width:100%}.e-bigger .e-daterangepicker.e-popup .e-range-header .e-start-end .e-start-btn,.e-bigger .e-daterangepicker.e-popup .e-range-header .e-start-end .e-end-btn,*.e-bigger.e-daterangepicker.e-popup .e-range-header .e-start-end .e-start-btn,*.e-bigger.e-daterangepicker.e-popup .e-range-header .e-start-end .e-end-btn,*.e-device.e-daterangepicker.e-popup .e-range-header .e-start-end .e-start-btn,*.e-device.e-daterangepicker.e-popup .e-range-header .e-start-end .e-end-btn{border:1px solid #3f51b5;box-shadow:none;font-size:14px;font-weight:500;height:36px;line-height:34px;max-width:116px;overflow:hidden;padding:1px 6px;text-overflow:ellipsis;width:50%}.e-bigger .e-daterangepicker.e-popup .e-range-header .e-start-end .e-end-btn,*.e-bigger.e-daterangepicker.e-popup .e-range-header .e-start-end .e-end-btn,*.e-device.e-daterangepicker.e-popup .e-range-header .e-start-end .e-end-btn{border-left:0;border-radius:0 2px 2px 0}.e-bigger .e-daterangepicker.e-popup .e-range-header .e-start-end .e-start-btn,*.e-bigger.e-daterangepicker.e-popup .e-range-header .e-start-end .e-start-btn,*.e-device.e-daterangepicker.e-popup .e-range-header .e-start-end .e-start-btn{border-radius:2px 0 0 2px}.e-bigger .e-daterangepicker.e-popup .e-range-header .e-start-end .e-start-btn:hover,.e-bigger .e-daterangepicker.e-popup .e-range-header .e-start-end .e-end-btn:hover:not([disabled]),*.e-bigger.e-daterangepicker.e-popup .e-range-header .e-start-end .e-start-btn:hover,*.e-bigger.e-daterangepicker.e-popup .e-range-header .e-start-end .e-end-btn:hover:not([disabled]),*.e-device.e-daterangepicker.e-popup .e-range-header .e-start-end .e-start-btn:hover,*.e-device.e-daterangepicker.e-popup .e-range-header .e-start-end .e-end-btn:hover:not([disabled]){box-shadow:none}.e-bigger .e-daterangepicker.e-popup .e-range-header .e-start-end .e-start-btn.e-active,.e-bigger .e-daterangepicker.e-popup .e-range-header .e-start-end .e-start-btn.e-active:active,.e-bigger .e-daterangepicker.e-popup .e-range-header .e-start-end .e-end-btn.e-active,.e-bigger .e-daterangepicker.e-popup .e-range-header .e-start-end .e-end-btn.e-active:active:not([disabled]),.e-bigger .e-daterangepicker.e-popup .e-range-header .e-start-end .e-start-btn.e-active:hover,.e-bigger .e-daterangepicker.e-popup .e-range-header .e-start-end .e-end-btn.e-active:hover,*.e-bigger.e-daterangepicker.e-popup .e-range-header .e-start-end .e-start-btn.e-active,*.e-bigger.e-daterangepicker.e-popup .e-range-header .e-start-end .e-start-btn.e-active:active,*.e-bigger.e-daterangepicker.e-popup .e-range-header .e-start-end .e-end-btn.e-active,*.e-bigger.e-daterangepicker.e-popup .e-range-header .e-start-end .e-end-btn.e-active:active:not([disabled]),*.e-bigger.e-daterangepicker.e-popup .e-range-header .e-start-end .e-start-btn.e-active:hover,*.e-bigger.e-daterangepicker.e-popup .e-range-header .e-start-end .e-end-btn.e-active:hover,*.e-device.e-daterangepicker.e-popup .e-range-header .e-start-end .e-start-btn.e-active,*.e-device.e-daterangepicker.e-popup .e-range-header .e-start-end .e-start-btn.e-active:active,*.e-device.e-daterangepicker.e-popup .e-range-header .e-start-end .e-end-btn.e-active,*.e-device.e-daterangepicker.e-popup .e-range-header .e-start-end .e-end-btn.e-active:active:not([disabled]),*.e-device.e-daterangepicker.e-popup .e-range-header .e-start-end .e-start-btn.e-active:hover,*.e-device.e-daterangepicker.e-popup .e-range-header .e-start-end .e-end-btn.e-active:hover{box-shadow:none}.e-bigger .e-daterangepicker.e-popup .e-range-header .e-start-end .e-start-btn,.e-bigger .e-daterangepicker.e-popup .e-range-header .e-start-end .e-end-btn,*.e-bigger.e-daterangepicker.e-popup .e-range-header .e-start-end .e-start-btn,*.e-bigger.e-daterangepicker.e-popup .e-range-header .e-start-end .e-end-btn,*.e-device.e-daterangepicker.e-popup .e-range-header .e-start-end .e-start-btn,*.e-device.e-daterangepicker.e-popup .e-range-header .e-start-end .e-end-btn{max-width:141px}.e-bigger .e-daterangepicker.e-popup .e-presets,*.e-bigger.e-daterangepicker.e-popup .e-presets,*.e-device.e-daterangepicker.e-popup .e-presets{max-height:240px}.e-bigger .e-daterangepicker.e-popup .e-presets.e-preset-wrapper,*.e-bigger.e-daterangepicker.e-popup .e-presets.e-preset-wrapper,*.e-device.e-daterangepicker.e-popup .e-presets.e-preset-wrapper{max-height:none}.e-bigger .e-daterangepicker.e-popup .e-presets ul,*.e-bigger.e-daterangepicker.e-popup .e-presets ul,*.e-device.e-daterangepicker.e-popup .e-presets ul{max-width:none}.e-bigger .e-daterangepicker.e-popup .e-presets ul li.e-list-item,*.e-bigger.e-daterangepicker.e-popup .e-presets ul li.e-list-item,*.e-device.e-daterangepicker.e-popup .e-presets ul li.e-list-item{font-size:14px;height:48px;line-height:48px;padding:0 16px}.e-bigger .e-daterangepicker .e-calendar,*.e-bigger.e-daterangepicker .e-calendar,*.e-device.e-daterangepicker .e-calendar{max-width:296px;padding:0}.e-bigger .e-daterangepicker .e-calendar .e-content table,*.e-bigger.e-daterangepicker .e-calendar .e-content table,*.e-device.e-daterangepicker .e-calendar .e-content table{padding:0 15px 15px}.e-bigger .e-daterangepicker .e-calendar .e-header .e-next,.e-bigger .e-daterangepicker .e-calendar .e-header .e-prev,*.e-bigger.e-daterangepicker .e-calendar .e-header .e-next,*.e-bigger.e-daterangepicker .e-calendar .e-header .e-prev,*.e-device.e-daterangepicker .e-calendar .e-header .e-next,*.e-device.e-daterangepicker .e-calendar .e-header .e-prev{height:48px;width:48px}.e-bigger .e-daterangepicker .e-calendar .e-header .e-next span,.e-bigger .e-daterangepicker .e-calendar .e-header .e-prev span,*.e-bigger.e-daterangepicker .e-calendar .e-header .e-next span,*.e-bigger.e-daterangepicker .e-calendar .e-header .e-prev span,*.e-device.e-daterangepicker .e-calendar .e-header .e-next span,*.e-device.e-daterangepicker .e-calendar .e-header .e-prev span{padding:15px}.e-bigger .e-daterangepicker .e-calendar .e-header .e-title,*.e-bigger.e-daterangepicker .e-calendar .e-header .e-title,*.e-device.e-daterangepicker .e-calendar .e-header .e-title{cursor:pointer;line-height:48px}.e-bigger .e-daterangepicker .e-calendar .e-header.e-month,.e-bigger .e-daterangepicker .e-calendar .e-header.e-year,.e-bigger .e-daterangepicker .e-calendar .e-header.e-decade,*.e-bigger.e-daterangepicker .e-calendar .e-header.e-month,*.e-bigger.e-daterangepicker .e-calendar .e-header.e-year,*.e-bigger.e-daterangepicker .e-calendar .e-header.e-decade,*.e-device.e-daterangepicker .e-calendar .e-header.e-month,*.e-device.e-daterangepicker .e-calendar .e-header.e-year,*.e-device.e-daterangepicker .e-calendar .e-header.e-decade{padding:10px 5px 0}.e-bigger .e-daterangepicker .e-footer,*.e-bigger.e-daterangepicker .e-footer,*.e-device.e-daterangepicker .e-footer{height:58px}.e-bigger .e-daterangepicker .e-footer .e-btn,*.e-bigger.e-daterangepicker .e-footer .e-btn,*.e-device.e-daterangepicker .e-footer .e-btn{height:36px;line-height:36px;overflow:hidden}.e-bigger .e-daterangepicker .e-footer .e-btn.e-apply,*.e-bigger.e-daterangepicker .e-footer .e-btn.e-apply,*.e-device.e-daterangepicker .e-footer .e-btn.e-apply{margin:0 8px}.e-bigger .e-daterangepicker.e-rtl.e-popup .e-range-header .e-start-end .e-end-btn,*.e-bigger.e-daterangepicker.e-rtl.e-popup .e-range-header .e-start-end .e-end-btn,*.e-device.e-daterangepicker.e-rtl.e-popup .e-range-header .e-start-end .e-end-btn{border:1px solid #3f51b5;border-radius:2px 0 0 2px;border-right:0}.e-bigger .e-daterangepicker.e-rtl.e-popup .e-range-header .e-start-end .e-start-btn,*.e-bigger.e-daterangepicker.e-rtl.e-popup .e-range-header .e-start-end .e-start-btn,*.e-device.e-daterangepicker.e-rtl.e-popup .e-range-header .e-start-end .e-start-btn{border-radius:0 2px 2px 0}.e-bigger .e-daterangepicker.e-rtl.e-popup .e-footer.e-btn.e-cancel,*.e-bigger.e-daterangepicker.e-rtl.e-popup .e-footer.e-btn.e-cancel,*.e-device.e-daterangepicker.e-rtl.e-popup .e-footer.e-btn.e-cancel{margin:0 8px}.e-bigger .e-daterangepicker.e-rtl.e-popup .e-footer .e-btn.e-apply,*.e-bigger.e-daterangepicker.e-rtl.e-popup .e-footer .e-btn.e-apply,*.e-device.e-daterangepicker.e-rtl.e-popup .e-footer .e-btn.e-apply{margin-left:0}.e-bigger .e-daterangepicker.e-device.e-popup,*.e-bigger.e-daterangepicker.e-device.e-popup,*.e-device.e-daterangepicker.e-device.e-popup{max-width:298px}.e-bigger .e-daterangepicker.e-device.e-popup .e-range-header,*.e-bigger.e-daterangepicker.e-device.e-popup .e-range-header,*.e-device.e-daterangepicker.e-device.e-popup .e-range-header{margin:20px 16px 0;padding:0}.e-bigger .e-daterangepicker.e-device.e-popup .e-range-header .e-day-span,*.e-bigger.e-daterangepicker.e-device.e-popup .e-range-header .e-day-span,*.e-device.e-daterangepicker.e-device.e-popup .e-range-header .e-day-span{margin:10px 0}.e-bigger .e-content-placeholder.e-daterangepicker.e-placeholder-daterangepicker,.e-bigger.e-content-placeholder.e-daterangepicker.e-placeholder-daterangepicker{background-size:250px 40px;min-height:40px}.e-bigger .e-daterangepicker,*.e-bigger.e-daterangepicker,*.e-device.e-daterangepicker{background-color:initial;padding:0}.e-bigger .e-daterangepicker .e-calendar th,*.e-bigger.e-daterangepicker .e-calendar th,*.e-device.e-daterangepicker .e-calendar th{color:#00000061}.e-bigger .e-daterangepicker .e-start-btn,.e-bigger .e-daterangepicker .e-end-btn,*.e-bigger.e-daterangepicker .e-start-btn,*.e-bigger.e-daterangepicker .e-end-btn,*.e-device.e-daterangepicker .e-start-btn,*.e-device.e-daterangepicker .e-end-btn{background:#fff}.e-bigger .e-daterangepicker .e-start-btn.e-active,.e-bigger .e-daterangepicker .e-start-btn.e-active:active,.e-bigger .e-daterangepicker .e-end-btn.e-active,.e-bigger .e-daterangepicker .e-end-btn.e-active:active:not([disabled]),.e-bigger .e-daterangepicker .e-start-btn.e-active:hover,.e-bigger .e-daterangepicker .e-end-btn.e-active:hover,*.e-bigger.e-daterangepicker .e-start-btn.e-active,*.e-bigger.e-daterangepicker .e-start-btn.e-active:active,*.e-bigger.e-daterangepicker .e-end-btn.e-active,*.e-bigger.e-daterangepicker .e-end-btn.e-active:active:not([disabled]),*.e-bigger.e-daterangepicker .e-start-btn.e-active:hover,*.e-bigger.e-daterangepicker .e-end-btn.e-active:hover,*.e-device.e-daterangepicker .e-start-btn.e-active,*.e-device.e-daterangepicker .e-start-btn.e-active:active,*.e-device.e-daterangepicker .e-end-btn.e-active,*.e-device.e-daterangepicker .e-end-btn.e-active:active:not([disabled]),*.e-device.e-daterangepicker .e-start-btn.e-active:hover,*.e-device.e-daterangepicker .e-end-btn.e-active:hover{background:#3f51b5;color:#fff}.e-bigger.e-small .e-daterangepicker.e-popup{border:none;border-radius:0;box-shadow:0 5px 5px -3px #0003,0 8px 10px 1px #00000024,0 3px 14px 2px #0000001f;max-height:500px;max-width:730px}.e-bigger.e-small .e-daterangepicker.e-popup.e-daterange-day-header-lg{max-width:100%}.e-bigger.e-small .e-daterangepicker.e-popup.e-preset-wrapper{min-width:625px}.e-bigger.e-small .e-daterangepicker.e-popup.e-preset-wrapper .e-presets{max-height:none}.e-bigger.e-small .e-daterangepicker.e-popup .e-range-header{background:#fff;padding:16px 16px 0;width:auto}.e-bigger.e-small .e-daterangepicker.e-popup .e-range-header .e-start-label,.e-bigger.e-small .e-daterangepicker.e-popup .e-range-header .e-end-label{cursor:default;display:inline-block;font-size:18px;overflow:hidden;text-align:center;text-decoration:none;text-overflow:ellipsis;-webkit-user-select:none;user-select:none;white-space:nowrap;width:48%}.e-bigger.e-small .e-daterangepicker.e-popup .e-range-header .e-change-icon{font-size:15px;font-weight:500;text-align:center;width:4%}.e-bigger.e-small .e-daterangepicker.e-popup .e-range-header .e-day-span{direction:ltr;font-size:13px;height:14px;margin:0 0 15px;text-align:center;-webkit-user-select:none;user-select:none;width:100%}.e-bigger.e-small .e-daterangepicker.e-popup .e-range-header .e-start-end{align-items:center;display:flex;height:35px}.e-bigger.e-small .e-daterangepicker.e-popup .e-separator{height:1px;margin:0}.e-bigger.e-small .e-daterangepicker.e-popup .e-calendar{border:none;margin:0;padding:0}.e-bigger.e-small .e-daterangepicker.e-popup .e-calendar .e-content table{padding:0 10px 10px}.e-bigger.e-small .e-daterangepicker.e-popup .e-calendar .e-header .e-title{cursor:pointer;line-height:36px;width:auto;float:none;font-weight:400;margin-left:0}.e-bigger.e-small .e-daterangepicker.e-popup .e-calendar .e-header.e-month,.e-bigger.e-small .e-daterangepicker.e-popup .e-calendar .e-header.e-year,.e-bigger.e-small .e-daterangepicker.e-popup .e-calendar .e-header.e-decade{padding:10px 5px 0}.e-bigger.e-small .e-daterangepicker.e-popup .e-calendar .e-header .e-next{float:right}.e-bigger.e-small .e-daterangepicker.e-popup .e-calendar .e-header .e-prev{float:left}.e-bigger.e-small .e-daterangepicker.e-popup .e-calendar .e-header .e-next,.e-bigger.e-small .e-daterangepicker.e-popup .e-calendar .e-header .e-prev{height:36px;width:36px}.e-bigger.e-small .e-daterangepicker.e-popup .e-calendar .e-header .e-next span,.e-bigger.e-small .e-daterangepicker.e-popup .e-calendar .e-header .e-prev span{padding:10px}.e-bigger.e-small .e-daterangepicker.e-popup .e-calendar .e-start-date.e-selected.e-range-hover{border-radius:50% 0 0 50%}.e-bigger.e-small .e-daterangepicker.e-popup .e-calendar .e-end-date.e-selected.e-range-hover{border-radius:0 50% 50% 0}.e-bigger.e-small .e-daterangepicker.e-popup .e-calendar .e-end-date.e-selected.e-range-hover span.e-day,.e-bigger.e-small .e-daterangepicker.e-popup .e-calendar .e-start-date.e-selected.e-range-hover span.e-day{border:none}.e-bigger.e-small .e-daterangepicker.e-popup .e-footer{align-items:center;border-top:1px solid rgba(0,0,0,.12);clear:both;display:flex;flex-direction:row-reverse;height:48px}.e-bigger.e-small .e-daterangepicker.e-popup .e-footer .e-btn{font-weight:500;height:27px;line-height:27px;overflow:hidden;padding:0 16px;text-overflow:ellipsis}.e-bigger.e-small .e-daterangepicker.e-popup .e-footer .e-btn.e-apply{margin:0 8px}.e-bigger.e-small .e-daterangepicker.e-popup .e-date-range-container{float:left}.e-bigger.e-small .e-daterangepicker.e-popup .e-date-range-container.e-range-border{border-right:1px solid rgba(0,0,0,.12)}.e-bigger.e-small .e-daterangepicker.e-popup .e-calendar-container{display:flex}.e-bigger.e-small .e-daterangepicker.e-popup .e-calendar-container .e-left-container,.e-bigger.e-small .e-daterangepicker.e-popup .e-calendar-container .e-right-container{float:left}.e-bigger.e-small .e-daterangepicker.e-popup .e-calendar-container .e-left-container{border-right:1px solid rgba(0,0,0,.12)}.e-bigger.e-small .e-daterangepicker.e-popup .e-presets{max-height:192px;overflow:auto;width:auto}.e-bigger.e-small .e-daterangepicker.e-popup .e-presets .e-list-item{border-radius:0;cursor:pointer;line-height:48px;overflow:hidden;padding:0 24px;white-space:nowrap;text-overflow:ellipsis}.e-bigger.e-small .e-daterangepicker.e-popup .e-presets .e-list-parent{margin:0;max-width:160px;padding:0}.e-bigger.e-small .e-daterangepicker.e-popup .e-presets .e-text-content{line-height:47px}.e-bigger.e-small .e-daterangepicker.e-popup .e-presets .e-ul li.e-list-item{font-size:13px;height:36px;line-height:36px}.e-bigger.e-small .e-daterangepicker.e-popup .e-hide-range{display:none}.e-bigger.e-small .e-daterangepicker.e-rtl .e-date-range-container{float:right}.e-bigger.e-small .e-daterangepicker.e-rtl .e-date-range-container.e-range-border,.e-bigger.e-small .e-daterangepicker.e-rtl .e-date-range-container .e-left-container{border-left:1px solid rgba(0,0,0,.12);border-right:0}.e-bigger.e-small .e-daterangepicker.e-rtl .e-date-range-container .e-calendar .e-next{float:left}.e-bigger.e-small .e-daterangepicker.e-rtl .e-date-range-container .e-calendar .e-prev{float:right}.e-bigger.e-small .e-daterangepicker.e-rtl .e-date-range-container .e-calendar .e-start-date.e-selected.e-range-hover{border-radius:0 50% 50% 0}.e-bigger.e-small .e-daterangepicker.e-rtl .e-date-range-container .e-calendar .e-end-date.e-selected.e-range-hover{border-radius:50% 0 0 50%}.e-bigger.e-small .e-daterangepicker.e-rtl .e-footer{flex-direction:row;justify-content:flex-end}.e-bigger.e-small .e-daterangepicker.e-rtl .e-footer .e-btn.e-cancel{margin:0 8px}.e-bigger.e-small .e-daterangepicker.e-rtl .e-footer .e-btn.e-apply{margin-left:0}.e-bigger.e-small .e-daterangepicker .e-calendar{max-width:246px}.e-bigger.e-small .e-daterangepicker.e-popup,.e-bigger.e-small.e-daterangepicker.e-popup{background:#fff}.e-bigger.e-small .e-daterangepicker.e-popup .e-calendar,.e-bigger.e-small.e-daterangepicker.e-popup .e-calendar{background-color:#fff}.e-bigger.e-small .e-daterangepicker.e-popup .e-calendar .e-header .e-title,.e-bigger.e-small .e-daterangepicker.e-popup .e-calendar .e-header .e-title:hover,.e-bigger.e-small.e-daterangepicker.e-popup .e-calendar .e-header .e-title,.e-bigger.e-small.e-daterangepicker.e-popup .e-calendar .e-header .e-title:hover{color:#000000de;text-decoration:none}.e-bigger.e-small .e-daterangepicker.e-popup .e-calendar .e-content .e-range-hover,.e-bigger.e-small.e-daterangepicker.e-popup .e-calendar .e-content .e-range-hover{background-color:#eee;color:#000000de}.e-bigger.e-small .e-daterangepicker.e-popup .e-calendar .e-content.e-month .e-today.e-range-hover span,.e-bigger.e-small.e-daterangepicker.e-popup .e-calendar .e-content.e-month .e-today.e-range-hover span{background-color:#eee;border:1px solid #e3165b;color:#e3165b}.e-bigger.e-small .e-daterangepicker.e-popup .e-calendar .e-content .e-range-hover span,.e-bigger.e-small.e-daterangepicker.e-popup .e-calendar .e-content .e-range-hover span{background:#eee;border:none;color:#000000de}.e-bigger.e-small .e-daterangepicker.e-popup .e-calendar .e-range-hover:not(.e-selected):hover span.e-day,.e-bigger.e-small .e-daterangepicker.e-popup .e-calendar .e-range-hover.e-focused-date:not(.e-selected) span.e-day,.e-bigger.e-small .e-daterangepicker.e-popup .e-calendar .e-range-hover.e-focused-date.e-today span.e-day,.e-bigger.e-small.e-daterangepicker.e-popup .e-calendar .e-range-hover:not(.e-selected):hover span.e-day,.e-bigger.e-small.e-daterangepicker.e-popup .e-calendar .e-range-hover.e-focused-date:not(.e-selected) span.e-day,.e-bigger.e-small.e-daterangepicker.e-popup .e-calendar .e-range-hover.e-focused-date.e-today span.e-day{background-color:#c8c8c8;border:none;color:#000000de}.e-bigger.e-small .e-daterangepicker.e-popup .e-calendar .e-range-hover.e-today:hover span.e-day,.e-bigger.e-small .e-daterangepicker.e-popup .e-calendar .e-range-hover.e-focused-date.e-today span.e-day,.e-bigger.e-small .e-daterangepicker.e-popup .e-calendar .e-range-hover.e-start-date.e-selected.e-today span.e-day,.e-bigger.e-small .e-daterangepicker.e-popup .e-calendar .e-range-hover.e-end-date.e-selected.e-today span.e-day,.e-bigger.e-small.e-daterangepicker.e-popup .e-calendar .e-range-hover.e-today:hover span.e-day,.e-bigger.e-small.e-daterangepicker.e-popup .e-calendar .e-range-hover.e-focused-date.e-today span.e-day,.e-bigger.e-small.e-daterangepicker.e-popup .e-calendar .e-range-hover.e-start-date.e-selected.e-today span.e-day,.e-bigger.e-small.e-daterangepicker.e-popup .e-calendar .e-range-hover.e-end-date.e-selected.e-today span.e-day,.e-bigger.e-small .e-daterangepicker.e-popup .e-calendar .e-range-hover.e-selected.e-today:hover span.e-day,.e-bigger.e-small.e-daterangepicker.e-popup .e-calendar .e-range-hover.e-selected.e-today:hover span.e-day{border:1px solid #e3165b}.e-bigger.e-small .e-daterangepicker.e-popup .e-calendar .e-content .e-other-month.e-range-hover,.e-bigger.e-small .e-daterangepicker.e-popup .e-calendar .e-content .e-other-month.e-today.e-range-hover span,.e-bigger.e-small .e-daterangepicker.e-popup .e-calendar .e-content .e-other-month.e-range-hover span,.e-bigger.e-small .e-daterangepicker.e-popup .e-calendar .e-content .e-other-month.e-range-hover:hover span.e-day,.e-bigger.e-small .e-daterangepicker.e-popup .e-calendar .e-content .e-other-month.e-selected,.e-bigger.e-small .e-daterangepicker.e-popup .e-calendar .e-content .e-other-month.e-selected span,.e-bigger.e-small.e-daterangepicker.e-popup .e-calendar .e-content .e-other-month.e-range-hover,.e-bigger.e-small.e-daterangepicker.e-popup .e-calendar .e-content .e-other-month.e-today.e-range-hover span,.e-bigger.e-small.e-daterangepicker.e-popup .e-calendar .e-content .e-other-month.e-range-hover span,.e-bigger.e-small.e-daterangepicker.e-popup .e-calendar .e-content .e-other-month.e-range-hover:hover span.e-day,.e-bigger.e-small.e-daterangepicker.e-popup .e-calendar .e-content .e-other-month.e-selected,.e-bigger.e-small.e-daterangepicker.e-popup .e-calendar .e-content .e-other-month.e-selected span{background-color:#fff;border:none;color:#00000061}.e-bigger.e-small .e-daterangepicker.e-popup .e-calendar .e-end-date.e-selected.e-range-hover span.e-day,.e-bigger.e-small .e-daterangepicker.e-popup .e-calendar .e-start-date.e-selected.e-range-hover span.e-day,.e-bigger.e-small.e-daterangepicker.e-popup .e-calendar .e-end-date.e-selected.e-range-hover span.e-day,.e-bigger.e-small.e-daterangepicker.e-popup .e-calendar .e-start-date.e-selected.e-range-hover span.e-day,.e-bigger.e-small .e-daterangepicker.e-popup .e-calendar .e-start-date.e-selected.e-range-hover.e-today span.e-day,.e-bigger.e-small.e-daterangepicker.e-popup .e-calendar .e-start-date.e-selected.e-range-hover.e-today span.e-day{background-color:#e3165b;color:#fff}.e-bigger.e-small .e-daterangepicker.e-popup .e-calendar .e-other-month.e-selected span,.e-bigger.e-small.e-daterangepicker.e-popup .e-calendar .e-other-month.e-selected span{color:#fff}.e-bigger.e-small .e-daterangepicker.e-popup .e-presets,.e-bigger.e-small.e-daterangepicker.e-popup .e-presets{background-color:#fff;color:#000}.e-bigger.e-small .e-daterangepicker.e-popup .e-presets .e-list-item.e-active,.e-bigger.e-small.e-daterangepicker.e-popup .e-presets .e-list-item.e-active{background-color:#fff;color:#e3165b}.e-bigger.e-small .e-daterangepicker.e-popup .e-presets .e-list-item.e-hover,.e-bigger.e-small.e-daterangepicker.e-popup .e-presets .e-list-item.e-hover{background-color:#eee;color:#000000de}.e-bigger.e-small .e-daterangepicker.e-popup .e-start-label,.e-bigger.e-small .e-daterangepicker.e-popup .e-end-label,.e-bigger.e-small.e-daterangepicker.e-popup .e-start-label,.e-bigger.e-small.e-daterangepicker.e-popup .e-end-label{color:#000000de}.e-bigger.e-small .e-daterangepicker.e-popup .e-change-icon,.e-bigger.e-small.e-daterangepicker.e-popup .e-change-icon{color:#000000bd}.e-bigger.e-small .e-daterangepicker.e-popup .e-day-span,.e-bigger.e-small.e-daterangepicker.e-popup .e-day-span{color:#0000008a}.e-bigger.e-small .e-daterangepicker.e-popup .e-separator,.e-bigger.e-small.e-daterangepicker.e-popup .e-separator{background-color:#0000001f}.e-bigger.e-small .e-daterangepicker.e-popup .e-footer,.e-bigger.e-small.e-daterangepicker.e-popup .e-footer{background-color:#fff}.e-bigger .e-input-group-icon.e-range-icon,.e-bigger.e-control-wrapper .e-input-group-icon.e-range-icon,.e-bigger .e-control-wrapper .e-input-group-icon.e-range-icon{font-size:18px;margin:0 0 2px;min-height:24px;min-width:24px;outline:none}.e-small.e-bigger .e-input-group-icon.e-range-icon,*.e-control-wrapper.e-small.e-bigger .e-input-group-icon.e-range-icon,*.e-small.e-bigger .e-control-wrapper .e-input-group-icon.e-range-icon{font-size:18px}.e-bigger .e-date-range-wrapper.e-outline .e-input-group-icon.e-range-icon,.e-date-range-wrapper.e-control-wrapper.e-bigger.e-outline .e-input-group-icon.e-range-icon,.e-bigger .e-date-range-wrapper.e-control-wrapper.e-outline .e-input-group-icon.e-range-icon{min-height:0;min-width:24px}.e-bigger.e-small .e-outline.e-date-range-wrapper .e-input-group-icon.e-range-icon,.e-bigger.e-small.e-outline.e-date-range-wrapper .e-input-group-icon.e-range-icon,.e-date-range-wrapper.e-control-wrapper.e-bigger.e-small.e-outline .e-input-group-icon.e-range-icon,.e-bigger.e-small .e-date-range-wrapper.e-control-wrapper.e-outline .e-input-group-icon.e-range-icon{min-height:0;min-width:20px}/*! component icons */.e-datetime-wrapper .e-time-icon.e-icons:before{content:"\e20c";font-family:e-icons}.e-datetime-wrapper.e-outline .e-input-group-icon.e-date-icon,.e-datetime-wrapper.e-control-wrapper.e-outline .e-input-group-icon.e-date-icon,.e-datetime-wrapper.e-outline .e-input-group-icon.e-time-icon,.e-datetime-wrapper.e-control-wrapper.e-outline .e-input-group-icon.e-time-icon{min-height:0;min-width:20px}.e-small .e-datetime-wrapper.e-outline .e-input-group-icon.e-date-icon,.e-datetime-wrapper.e-control-wrapper.e-small.e-outline .e-input-group-icon.e-date-icon,.e-small .e-datetime-wrapper.e-control-wrapper.e-outline .e-input-group-icon.e-date-icon,.e-small .e-datetime-wrapper.e-outline .e-input-group-icon.e-time-icon,.e-datetime-wrapper.e-control-wrapper.e-small.e-outline .e-input-group-icon.e-time-icon,.e-small .e-datetime-wrapper.e-control-wrapper.e-outline .e-input-group-icon.e-time-icon{min-height:0;min-width:18px}.e-datetime-wrapper.e-filled .e-input-group-icon.e-time-icon,.e-datetime-wrapper.e-control-wrapper.e-filled .e-input-group-icon.e-time-icon,.e-rtl.e-datetime-wrapper.e-filled .e-input-group-icon.e-time-icon,.e-rtl.e-datetime-wrapper.e-control-wrapper.e-filled .e-input-group-icon.e-time-icon,.e-rtl .e-datetime-wrapper.e-filled .e-input-group-icon.e-time-icon,.e-rtl .e-datetime-wrapper.e-control-wrapper.e-filled .e-input-group-icon.e-time-icon{margin:0}.e-input-group.e-control-wrapper.e-datetime-wrapper.e-non-edit.e-input-focus .e-input:focus~.e-clear-icon,.e-float-input.e-control-wrapper.e-input-group.e-datetime-wrapper.e-non-edit.e-input-focus input:focus~.e-clear-icon{display:flex}.e-datetime-wrapper{-webkit-tap-highlight-color:transparent}.e-datetime-wrapper .e-time-icon.e-icons:before{font-size:16px}.e-datetime-wrapper.e-control-wrapper{box-sizing:border-box}.e-datetime-wrapper .e-time-icon.e-icons.e-disabled,.e-datetime-wrapper .e-date-icon.e-icons.e-disabled{pointer-events:none}.e-datetime-wrapper .e-clear-icon{box-sizing:content-box}.e-datetime-wrapper span{cursor:pointer}.e-datetime-wrapper .e-input-group-icon.e-date-icon,.e-datetime-wrapper .e-input-group-icon.e-time-icon{font-size:16px;margin:0 0 4px;min-height:24px;min-width:24px;outline:none}.e-datetime-wrapper .e-input-group-icon.e-time-icon{border:0;border-style:none;margin:0 0 4px 6px}.e-datetime-wrapper:not(.e-outline).e-rtl .e-input-group-icon.e-time-icon{margin:0 6px 4px 0}.e-datetime-mob-popup-wrap{align-items:center;display:flex;flex-direction:column;height:100%;justify-content:center;left:0;max-height:100%;position:fixed;top:0;width:100%;z-index:1002}.e-datetime-mob-popup-wrap .e-datetimepicker.e-popup.e-lib.e-control.e-popup-open{left:0!important;position:relative;top:0!important}.e-datetimepicker.e-time-modal{background-color:#0009;height:100%;left:0;opacity:.5;pointer-events:auto;position:fixed;top:0;width:100%;z-index:999}.e-datetimepicker.e-popup{border-style:solid;border-width:1px;overflow:auto}.e-datetimepicker.e-popup .e-content{position:relative}.e-datetimepicker.e-popup .e-list-parent.e-ul{margin:0;padding:8px 0}.e-datetimepicker.e-popup .e-list-parent.e-ul .e-list-item{color:#000000de;cursor:default;font-size:13px;overflow:hidden;position:relative;text-overflow:ellipsis;vertical-align:middle;white-space:nowrap;width:100%}.e-datetimepicker.e-popup .e-list-parent.e-ul .e-list-item.e-hover{cursor:pointer}.e-datetimepicker.e-popup .e-list-parent.e-ul .e-list-item{line-height:36px;text-indent:16px}.e-small .e-datetimepicker.e-popup .e-list-parent.e-ul .e-list-item,*.e-small.e-datetimepicker.e-popup .e-list-parent.e-ul .e-list-item{font-size:12px;line-height:26px;text-indent:12px}.e-small.e-datetime-wrapper .e-time-icon.e-icons:before,*.e-small .e-datetime-wrapper .e-time-icon.e-icons:before{font-size:14px}.e-content-placeholder.e-datetimepicker.e-placeholder-datetimepicker{background-size:250px 33px;min-height:33px}.e-datetimepicker.e-popup-expand.e-popup{position:fixed}.e-datetimepicker.e-popup-expand.e-popup .e-datetime-mob-popup-wrap{position:relative;width:100%}/*! datetimepicker theme */.e-datetime-wrapper .e-input-group-icon.e-icons.e-active{color:#e3165b}.e-datetime-wrapper.e-input-group:not(.e-disabled) .e-input-group-icon.e-active:active{color:#e3165b}.e-datetimepicker.e-popup{border:none;border-radius:2px;box-shadow:0 5px 5px -3px #0003,0 8px 10px 1px #00000024,0 3px 14px 2px #0000001f}.e-datetimepicker.e-popup .e-list-parent.e-ul{background-color:#fff}.e-datetimepicker.e-popup .e-list-parent.e-ul li.e-list-item{border:none;color:#000000de}.e-datetimepicker.e-popup .e-list-parent.e-ul .e-list-item.e-hover,.e-datetimepicker.e-popup .e-list-parent.e-ul .e-list-item.e-navigation,.e-datetimepicker.e-popup .e-list-parent.e-ul .e-list-item:focus{background-color:#eee;border:none;color:#000}.e-datetimepicker.e-popup .e-list-parent.e-ul .e-list-item.e-active,.e-datetimepicker.e-popup .e-list-parent.e-ul .e-list-item.e-active.e-hover{background-color:#eee;color:#e3165b}.e-bigger.e-datetime-wrapper .e-time-icon.e-icons:before,*.e-bigger .e-datetime-wrapper .e-time-icon.e-icons:before{font-size:18px}.e-bigger.e-datetime-wrapper .e-input-group-icon.e-time-icon,*.e-bigger .e-datetime-wrapper .e-input-group-icon.e-time-icon{margin:5px 0 6px 8px;min-height:26px;min-width:26px}.e-bigger.e-datetime-wrapper:not(.e-outline).e-rtl .e-input-group-icon.e-time-icon,*.e-bigger .e-datetime-wrapper:not(.e-outline).e-rtl .e-input-group-icon.e-time-icon{margin:5px 8px 6px 0}.e-bigger .e-datetimepicker.e-popup .e-list-parent.e-ul,*.e-bigger.e-datetimepicker.e-popup .e-list-parent.e-ul{padding:8px 0}.e-bigger .e-datetimepicker.e-popup .e-list-parent.e-ul .e-list-item,*.e-bigger.e-datetimepicker.e-popup .e-list-parent.e-ul .e-list-item{font-size:14px;line-height:48px;text-indent:16px}.e-bigger .e-content-placeholder.e-datetimepicker.e-placeholder-datetimepicker,.e-bigger.e-content-placeholder.e-datetimepicker.e-placeholder-datetimepicker{background-size:250px 40px;min-height:40px}.e-small.e-bigger.e-datetime-wrapper .e-time-icon.e-icons:before,*.e-small.e-bigger .e-datetime-wrapper .e-time-icon.e-icons:before{font-size:18px}.e-small.e-bigger .e-datetimepicker.e-popup .e-list-parent.e-ul .e-list-item,*.e-small.e-bigger.e-datetimepicker.e-popup .e-list-parent.e-ul .e-list-item{font-size:13px;line-height:40px;text-indent:16px}.e-bigger .e-datetime-wrapper.e-outline .e-input-group-icon.e-date-icon,.e-datetime-wrapper.e-control-wrapper.e-bigger.e-outline .e-input-group-icon.e-date-icon,.e-bigger .e-datetime-wrapper.e-control-wrapper.e-outline .e-input-group-icon.e-date-icon,.e-bigger .e-datetime-wrapper.e-outline .e-input-group-icon.e-time-icon,.e-datetime-wrapper.e-control-wrapper.e-bigger.e-outline .e-input-group-icon.e-time-icon,.e-bigger .e-datetime-wrapper.e-control-wrapper.e-outline .e-input-group-icon.e-time-icon{min-height:0;min-width:24px}.e-bigger.e-small .e-outline.e-datetime-wrapper .e-input-group-icon.e-date-icon,.e-bigger.e-small.e-outline.e-datetime-wrapper .e-input-group-icon.e-date-icon,.e-datetime-wrapper.e-control-wrapper.e-bigger.e-small.e-outline .e-input-group-icon.e-date-icon,.e-bigger.e-small .e-datetime-wrapper.e-control-wrapper.e-outline .e-input-group-icon.e-date-icon,.e-bigger.e-small .e-outline.e-datetime-wrapper .e-input-group-icon.e-time-icon,.e-bigger.e-small.e-outline.e-datetime-wrapper .e-input-group-icon.e-time-icon,.e-datetime-wrapper.e-control-wrapper.e-bigger.e-small.e-outline .e-input-group-icon.e-time-icon,.e-bigger.e-small .e-datetime-wrapper.e-control-wrapper.e-outline .e-input-group-icon.e-time-icon{min-height:0;min-width:20px} diff --git a/ej2-angular/treemap/getting-started.md b/ej2-angular/treemap/getting-started.md index c6b771c6d9..a38c1cc20a 100644 --- a/ej2-angular/treemap/getting-started.md +++ b/ej2-angular/treemap/getting-started.md @@ -10,7 +10,9 @@ domainurl: ##DomainURL## # Getting started with Angular Treemap component -This section explains you the steps required to create a TreeMap control and demonstrate the basic usage of the TreeMap control. +This section explains the steps required to create a TreeMap control and demonstrates the basic usage of the TreeMap component. + +{% youtube "https://www.youtube.com/watch?v=1AvAKz1EPc8" %} ## Setup Angular Environment diff --git a/ej2-angular/treemap/layout.md b/ej2-angular/treemap/layout.md index 860d84e695..c7fdfb2e46 100644 --- a/ej2-angular/treemap/layout.md +++ b/ej2-angular/treemap/layout.md @@ -10,13 +10,17 @@ domainurl: ##DomainURL## # Layout in Angular Treemap component +This section explains how to customize the appearance of the TreeMap component. The below video demonstrates the same. + +{% youtube "https://www.youtube.com/watch?v=phfdhfoRnpM" %} + Determine the visual representation of nodes belonging to all the TreeMap levels using the [`layoutType`](https://ej2.syncfusion.com/angular/documentation/api/treemap/#layouttype) property. ## Types of layout The available layout types are, -* Squarfied +* Squarified * SliceAndDiceVertical * SliceAndDiceHorizontal * SliceAndDiceAuto @@ -83,4 +87,4 @@ The `SliceAndDiceAuto` layout creates rectangles with high aspect ratio and disp {% endhighlight %} {% endtabs %} -{% previewsample "page.domainurl/samples/treemap/getting-started/treemap-cs26" %} \ No newline at end of file +{% previewsample "page.domainurl/samples/treemap/getting-started/treemap-cs26" %}